Skip to content

Commit 0d0aee1

Browse files
committed
Replace some incorrect details about sizing a flexbox in the layout algorithm with placeholder issues.
1 parent f7d5b04 commit 0d0aee1

2 files changed

Lines changed: 15 additions & 14 deletions

File tree

css3-flexbox/Overview.html

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1875,15 +1875,17 @@ <h2 id=layout-algorithm><span class=secno>7. </span> Flexbox Layout
18751875
lines:</p>
18761876

18771877
<ol>
1878-
<li>Determine the flexbox's available space by finding the size of the
1879-
flexbox's parent's content box in the flexbox's main axis, and
1880-
subtracting the size of the flexbox's margins, borders, and padding in
1881-
the main axis.
1878+
<li>Determine the main size of the flexbox's content box.
1879+
<p class=issue>Fill in the details about how to do so when the width is
1880+
min/max/fit-content. This is complicated for multiline, especially for
1881+
&lsquo;<code class=css>flex-flow:column</code>&rsquo;!
18821882

18831883
<li>Collect as many consecutive flexbox items as possible, starting from
18841884
the first item, while keeping the sum of their main size smaller than
1885-
the flexbox's available space. The items so collected form a single
1886-
flexbox line.
1885+
the flexbox's available space. If a flexbox item is sized with a
1886+
flexible length, then for the purpose of this step, clamp the item's
1887+
size between its minimum and maximum main sizes. The items so collected
1888+
form a single flexbox line.
18871889

18881890
<li>Repeat the previous step, starting each time from the first flexbox
18891891
item not yet collected into a flexbox line, until all flexbox items
@@ -1894,11 +1896,8 @@ <h2 id=layout-algorithm><span class=secno>7. </span> Flexbox Layout
18941896
<p>Find the actual main size of the flexbox, per the standard rules for
18951897
blocks (for block flexboxes) or inline-blocks (for inline flexboxes).</p>
18961898

1897-
<p>The min-content, max-content, or fit-content size of a flexbox in the
1898-
main axis can be determined by, for each flexbox line, summing the
1899-
min-content, max-content, or fit-content (as appropriate) sizes in the
1900-
main axis of the flexbox items, and then returning the maximum of these
1901-
sums.</p>
1899+
<p class=issue>Address min/max/fix-content here as well. Perhaps just
1900+
combine this step with the previous?</p>
19021901

19031902
<li>For each flexbox line, <a
19041903
href="#resolve-the-flexible-lengths"><i>resolve the flexible

css3-flexbox/Overview.src.html

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -912,9 +912,11 @@ <h2 id='layout-algorithm'>
912912
<p>If the flexbox is multi-line, group the flexbox items into multiple lines:</p>
913913

914914
<ol>
915-
<li>Determine the flexbox's available space by finding the size of the flexbox's parent's content box in the flexbox's main axis, and subtracting the size of the flexbox's margins, borders, and padding in the main axis.</li>
915+
<li>Determine the main size of the flexbox's content box.
916916

917-
<li>Collect as many consecutive flexbox items as possible, starting from the first item, while keeping the sum of their main size smaller than the flexbox's available space. The items so collected form a single flexbox line.</li>
917+
<p class='issue'>Fill in the details about how to do so when the width is min/max/fit-content. This is complicated for multiline, especially for ''flex-flow:column''!</p></li>
918+
919+
<li>Collect as many consecutive flexbox items as possible, starting from the first item, while keeping the sum of their main size smaller than the flexbox's available space. If a flexbox item is sized with a flexible length, then for the purpose of this step, clamp the item's size between its minimum and maximum main sizes. The items so collected form a single flexbox line.</li>
918920

919921
<li>Repeat the previous step, starting each time from the first flexbox item not yet collected into a flexbox line, until all flexbox items have been collected into flexbox lines.</li>
920922
</ol>
@@ -923,7 +925,7 @@ <h2 id='layout-algorithm'>
923925
<li>
924926
<p>Find the actual main size of the flexbox, per the standard rules for blocks (for block flexboxes) or inline-blocks (for inline flexboxes).</p>
925927

926-
<p>The min-content, max-content, or fit-content size of a flexbox in the main axis can be determined by, for each flexbox line, summing the min-content, max-content, or fit-content (as appropriate) sizes in the main axis of the flexbox items, and then returning the maximum of these sums.</p>
928+
<p class='issue'>Address min/max/fix-content here as well. Perhaps just combine this step with the previous?</p>
927929
</li>
928930

929931
<li>For each flexbox line, <i>resolve the flexible lengths</i> of the items contained within it. All flexbox items now have a final main size. Update each item's hypothetical cross size based on this main size.</li>

0 commit comments

Comments
 (0)