|
29 | 29 |
|
30 | 30 | <h1 id=head-box-flexible>CSS Flexible Box Layout Module</h1> |
31 | 31 |
|
32 | | - <h2 class="no-num no-toc" id=w3c-working>Editor's Draft, 30 January 2012</h2> |
| 32 | + <h2 class="no-num no-toc" id=w3c-working>Editor's Draft, 31 January 2012</h2> |
33 | 33 |
|
34 | 34 | <dl> |
35 | 35 | <dt>This version: |
36 | | - <!--<dd><a href="http://www.w3.org/TR/2012/ED-css3-flexbox-20120130/">http://www.w3.org/TR/2012/ED-css3-flexbox-20120130/</a>--> |
| 36 | + <!--<dd><a href="http://www.w3.org/TR/2012/ED-css3-flexbox-20120131/">http://www.w3.org/TR/2012/ED-css3-flexbox-20120131/</a>--> |
37 | 37 |
|
38 | 38 |
|
39 | 39 | <dd><a |
@@ -1816,51 +1816,14 @@ <h2 id=layout-algorithm><span class=secno>7. </span> Flexbox Layout |
1816 | 1816 | this algorithm deals with the items. |
1817 | 1817 |
|
1818 | 1818 | <li> |
1819 | | - <p>Resolve the width and height of every flexbox item into an absolute |
1820 | | - length. If the width or height is already an absolute length (like |
1821 | | - ‘<code class=css>50px</code>’) or was transformed into an |
1822 | | - absolute length at computed-value time (like ‘<code |
1823 | | - class=css>10em</code>’), skip the rest of this step for that |
1824 | | - dimension.</p> |
1825 | | - |
1826 | | - <p>Otherwise, determining the size requires a layout to transform it into |
1827 | | - a pair of absolute lengths. For the purpose of this step:</p> |
1828 | | - |
1829 | | - <ul> |
1830 | | - <li>Treat <a href="#block-flexbox"><i>block flexboxes</i></a> as being |
1831 | | - ‘<code class=css>display:block</code>’ and <a |
1832 | | - href="#inline-flexbox"><i>inline flexboxes</i></a> as being |
1833 | | - ‘<code class=css>display:inline-block</code>’. |
1834 | | - |
1835 | | - <li>Treat the flexbox and every flexbox item as establishing a block |
1836 | | - formatting context. |
1837 | | - |
1838 | | - <li>If the main size of a flexbox item is flexible, treat it as the |
1839 | | - preferred size of the flexible length. <strong>Do not apply |
1840 | | - min/max-width/height constraints to the preferred widths/heights of |
1841 | | - flexible lengths - those constraints are handled elsewhere in this |
1842 | | - algorithm, and doing so will produce incorrect results.</strong> Do |
1843 | | - apply those constraints to non-flexible lengths, as normal. |
1844 | | - |
1845 | | - <li>If the main size of a flexbox item is ‘<code |
1846 | | - class=property>auto</code>’, or is being treated as ‘<code |
1847 | | - class=property>auto</code>’ due to the above step, treat it as |
1848 | | - ‘<code class=property>fit-content</code>’. <span |
1849 | | - class=note>IIRC, this is the name we expect to give to the "shrinkwrap" |
1850 | | - behavior.</span>. |
1851 | | - </ul> |
1852 | | - |
1853 | | - <p>For each flexbox item:</p> |
1854 | | - |
1855 | | - <ol> |
1856 | | - <li>Ignore all other flexbox items (do layout as if the flexbox had only |
1857 | | - a single child - the flexbox item in question). Using normal block |
1858 | | - layout (and the preceding additional assumptions), resolve the width |
1859 | | - and height of the flexbox item. |
1860 | | - </ol> |
1861 | | - |
1862 | | - <p>Each flexbox item now has a hypothetical width and hypothetical |
1863 | | - height.</p> |
| 1819 | + <p>Layout the flexbox items using the shrink-to-fit algorithm. If the |
| 1820 | + main size of a flexbox item is flexible, treat it as the preferred size |
| 1821 | + of that flexible length. <strong>Do not apply min/max-width/height |
| 1822 | + constraints to the preferred size of flexible lengths - those |
| 1823 | + constraints are handled elsewhere in this algorithm, and doing so will |
| 1824 | + produce incorrect results.</strong></p> |
| 1825 | + |
| 1826 | + <p>Each flexbox item now has a hypothetical main size.</p> |
1864 | 1827 |
|
1865 | 1828 | <li> |
1866 | 1829 | <p>If the flexbox is single-line, collect all the flexbox items into a |
|
0 commit comments