Skip to content

Commit a0e67f4

Browse files
committed
Make abspos static position be the flex container, per discussion with alexmog and tabatkins.
1 parent 81381de commit a0e67f4

4 files changed

Lines changed: 38 additions & 87 deletions

File tree

css3-flexbox/Overview.html

Lines changed: 20 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -382,19 +382,16 @@ <h2 class="no-num no-toc" id=table>Table of contents</h2>
382382

383383
<li><a href="#flex-items"><span class=secno>4. </span> Flex Items</a>
384384
<ul class=toc>
385-
<li><a href="#abspos-items"><span class=secno>4.1. </span> Out-of-flow
386-
Items</a>
387-
388-
<li><a href="#item-margins"><span class=secno>4.2. </span> Flex Item
385+
<li><a href="#item-margins"><span class=secno>4.1. </span> Flex Item
389386
Margins</a>
390387

391-
<li><a href="#painting"><span class=secno>4.3. </span> Flex Item
388+
<li><a href="#painting"><span class=secno>4.2. </span> Flex Item
392389
Painting</a>
393390

394-
<li><a href="#visibility-collapse"><span class=secno>4.4. </span>
391+
<li><a href="#visibility-collapse"><span class=secno>4.3. </span>
395392
Collapsed Items</a>
396393

397-
<li><a href="#min-size-auto"><span class=secno>4.5. </span> Implied
394+
<li><a href="#min-size-auto"><span class=secno>4.4. </span> Implied
398395
Minimum Size of Flex Items</a>
399396
</ul>
400397

@@ -980,49 +977,25 @@ <h2 id=flex-items><span class=secno>4. </span> Flex Items</h2>
980977
ruby) or otherwise mangle the box tree (e.g. run-ins). It is intended that
981978
flex item determination run after these operations.
982979

983-
<h3 id=abspos-items><span class=secno>4.1. </span> Out-of-flow Items</h3>
984-
985-
<p> Absolutely positioned children of a flex container are not themselves
986-
<a href="#flex-item"><i>flex items</i></a>, but they leave behind
987-
"placeholders" in their hypothetical normal-flow position in the box tree.
988-
These placeholders are anonymous inline boxes with a width, height, and
989-
line-height of ‘<code class=css>0</code>’, and they become flex items.
990-
991-
992-
<div class=example>
993-
<pre>&lt;div style="display:flex">
994-
&lt;!-- flex item: zero-width zero-height abspos placeholder
995-
The principal box containing "abspos" is out-of-flow, and not a flex item. -->
996-
&lt;div style="position: absolute">abspos&lt;/span>
997-
&lt;/div></pre>
998-
</div>
980+
<p id=abspos-items> The <a
981+
href="http://www.w3.org/TR/CSS21/visudet.html#abs-non-replaced-width">hypothetical
982+
box</a> used to calculate the <i>static position</i> <a href="#CSS21"
983+
rel=biblioentry>[CSS21]<!--{{!CSS21}}--></a> of an absolutely-positioned
984+
flex item corresponds to the content-box of the flex container. (This
985+
effectively defines the <i>static position</i> as the head start
986+
content-box corner of the flex container.) As in block layout, the
987+
absolutely-positioned box has no effect on the layout of surrounding
988+
content.
999989

1000-
<p> The <i>static position</i> of an absolutely positioned child of a flex
1001-
container (the position when the ‘<code
1002-
class=property>top</code>’/‘<code
1003-
class=property>right</code>’/‘<code
1004-
class=property>bottom</code>’/‘<code class=property>left</code>
1005-
properties are ‘<a href="#align-self-auto"><code
1006-
class=css>auto</code></a>’), then, is the final position of its
1007-
corresponding placeholder, after flex layout has been performed.
1008-
1009-
<p class=note> Note: In most cases, this means that absolutely-positioned
1010-
items have no effect on flex layout. However, when the flex container has
1011-
<code class=css>justify-content: space-between</code>’ or ‘<code
1012-
class=css>justify-content: space-around</code>’, the anonymous flex
1013-
items wrapping a placeholder will cause there to be two packing spaces
1014-
where there would otherwise be only one, possibly resulting in increased
1015-
space between two "real" items.
1016-
1017-
<h3 id=item-margins><span class=secno>4.2. </span> Flex Item Margins</h3>
990+
<h3 id=item-margins><span class=secno>4.1. </span> Flex Item Margins</h3>
1018991

1019992
<p> The margins of adjacent <a href="#flex-item"><i>flex items</i></a> do
1020993
not collapse. Auto margins absorb extra space in the corresponding
1021994
dimension and can be used for alignment and to push adjacent flex items
1022995
apart; see <a href="#auto-margins">Aligning with ‘<code
1023996
class=css>auto</code>’ margins</a>.
1024997

1025-
<h3 id=painting><span class=secno>4.3. </span> Flex Item Painting</h3>
998+
<h3 id=painting><span class=secno>4.2. </span> Flex Item Painting</h3>
1026999

10271000
<p> <a href="#flex-item"><i>Flex items</i></a> paint exactly the same as
10281001
block-level elements in the normal flow, except that ‘<code
@@ -1034,7 +1007,7 @@ <h3 id=painting><span class=secno>4.3. </span> Flex Item Painting</h3>
10341007
<p class=note> Note: Descendants that are positioned outside a flex item
10351008
still participate in any stacking context established by the flex item.
10361009

1037-
<h3 id=visibility-collapse><span class=secno>4.4. </span> Collapsed Items</h3>
1010+
<h3 id=visibility-collapse><span class=secno>4.3. </span> Collapsed Items</h3>
10381011

10391012
<p> Specifying ‘<code class=css>visibility:collapse</code>’ on a flex
10401013
item causes it to become a <dfn id=collapsed-flex-item
@@ -1162,7 +1135,7 @@ <h3 id=visibility-collapse><span class=secno>4.4. </span> Collapsed Items</h3>
11621135
class=css>visibility: collapse</code>’ is still recommended for dynamic
11631136
cases.)
11641137

1165-
<h3 id=min-size-auto><span class=secno>4.5. </span> Implied Minimum Size of
1138+
<h3 id=min-size-auto><span class=secno>4.4. </span> Implied Minimum Size of
11661139
Flex Items</h3>
11671140

11681141
<p> To provide a more reasonable default minimum size for flex items, this
@@ -4109,10 +4082,10 @@ <h2 class=no-num id=index>Index</h2>
41094082
title="''center''"><strong>8.2.</strong></a>
41104083

41114084
<li>collapsed, <a href="#collapsed-flex-item"
4112-
title=collapsed><strong>4.4.</strong></a>
4085+
title=collapsed><strong>4.3.</strong></a>
41134086

41144087
<li>collapsed flex item, <a href="#collapsed-flex-item"
4115-
title="collapsed flex item"><strong>4.4.</strong></a>
4088+
title="collapsed flex item"><strong>4.3.</strong></a>
41164089

41174090
<li><a href="#flex-flow-column"><code class=css>column</code></a>’,
41184091
<a href="#flex-flow-column" title="''column''"><strong>5.1.</strong></a>
@@ -4262,7 +4235,7 @@ <h2 class=no-num id=index>Index</h2>
42624235
title=main-start><strong>2.</strong></a>
42634236

42644237
<li>min-width/height:auto, <a href="#min-auto"
4265-
title="min-width/height:auto"><strong>4.5.</strong></a>
4238+
title="min-width/height:auto"><strong>4.4.</strong></a>
42664239

42674240
<li>multi-line, <a href="#multi-line"
42684241
title=multi-line><strong>6.</strong></a>

css3-flexbox/Overview.src.html

Lines changed: 8 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -659,35 +659,14 @@ <h2 id='flex-items'>
659659
Future display types may generate anonymous containers (e.g. ruby) or otherwise mangle the box tree (e.g. run-ins).
660660
It is intended that flex item determination run after these operations.
661661

662-
<h3 id='abspos-items'>
663-
Out-of-flow Items</h3>
664-
665-
<p>
666-
Absolutely positioned children of a flex container are not themselves <i>flex items</i>,
667-
but they leave behind "placeholders" in their hypothetical normal-flow position in the box tree.
668-
These placeholders are anonymous inline boxes with a width, height, and line-height of ''0'',
669-
and they become flex items.
670-
671-
<div class="example">
672-
<pre>&lt;div style="display:flex">
673-
&lt;!-- flex item: zero-width zero-height abspos placeholder
674-
The principal box containing "abspos" is out-of-flow, and not a flex item. -->
675-
&lt;div style="position: absolute">abspos&lt;/span>
676-
&lt;/div></pre>
677-
</div>
678-
679-
<p>
680-
The <i>static position</i> of an absolutely positioned child of a flex container
681-
(the position when the 'top'/'right'/'bottom'/'left' properties are ''auto''), then,
682-
is the final position of its corresponding placeholder, after flex layout has been performed.
683-
684-
<p class='note'>
685-
Note: In most cases,
686-
this means that absolutely-positioned items have no effect on flex layout.
687-
However, when the flex container has ''justify-content: space-between'' or ''justify-content: space-around'',
688-
the anonymous flex items wrapping a placeholder will cause there to be two packing spaces
689-
where there would otherwise be only one,
690-
possibly resulting in increased space between two "real" items.
662+
<p id='abspos-items'>
663+
The <a href="http://www.w3.org/TR/CSS21/visudet.html#abs-non-replaced-width">hypothetical box</a> used to calculate the <i>static position</i> [[!CSS21]]
664+
of an absolutely-positioned flex item corresponds to
665+
the content-box of the flex container.
666+
(This effectively defines the <i>static position</i> as
667+
the head start content-box corner of the flex container.)
668+
As in block layout, the absolutely-positioned box has no effect
669+
on the layout of surrounding content.
691670

692671
<h3 id='item-margins'>
693672
Flex Item Margins</h3>
@@ -698,7 +677,6 @@ <h3 id='item-margins'>
698677
and to push adjacent flex items apart;
699678
see <a href="#auto-margins">Aligning with ''auto'' margins</a>.
700679

701-
702680
<h3 id='painting'>
703681
Flex Item Painting</h3>
704682

css3-flexbox/issues-lc-2012.html

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -177,24 +177,24 @@ <h1>CSS Flexible Box Layout Level 3 Disposition of Comments for 2012-06-12 LCWD<
177177
Comment: <a href="http://lists.w3.org/Archives/Public/www-style/2012Jul/0190.html">http://lists.w3.org/Archives/Public/www-style/2012Jul/0190.html</a>
178178
Closed: Accepted
179179
</pre>
180-
<pre class="open" id="issue-17">
180+
<pre class="a open" id="issue-17">
181181
Issue 17. <a href="#issue-17">#</a>
182182
Summary: Does 'order' affect abspos placeholders?
183183
From: 呂康豪 (Kang-Hao Lu)
184-
Comment: http://lists.w3.org/Archives/Public/www-style/2012Jul/0167.html
185-
Open
184+
Comment: <a href="http://lists.w3.org/Archives/Public/www-style/2012Jul/0167.html">http://lists.w3.org/Archives/Public/www-style/2012Jul/0167.html</a>
185+
Closed: Accepted
186186
</pre>
187-
<pre class="r" id="issue-18">
188-
Issue 18. <a href="issue-18">#</a>
187+
<pre class="a open" id="issue-18">
188+
Issue 18. <a href="#issue-18">#</a>
189189
Summary: Absolutely-positioned flex items should not affect layout in flex container
190190
From: John Hax
191191
Comment: <a href="http://lists.w3.org/Archives/Public/www-style/2012Jul/0258.html">http://lists.w3.org/Archives/Public/www-style/2012Jul/0258.html</a>
192192
Response: <a href="http://lists.w3.org/Archives/Public/www-style/2012Jul/0262.html">http://lists.w3.org/Archives/Public/www-style/2012Jul/0262.html</a>
193193
Comment: <a href="http://lists.w3.org/Archives/Public/www-style/2012Jul/0419.html">http://lists.w3.org/Archives/Public/www-style/2012Jul/0419.html</a>
194-
Closed: Rejected
194+
Closed: Accepted
195195
</pre>
196196
<pre class="a" id="issue-19">
197-
Issue 19. <a href="issue-19">#</a>
197+
Issue 19. <a href="#issue-19">#</a>
198198
Summary: Flexbox needs examples with different writing modes
199199
From: i18nWG
200200
Comment: <a href="http://lists.w3.org/Archives/Public/www-style/2012Jul/0269.html">http://lists.w3.org/Archives/Public/www-style/2012Jul/0269.html</a>
@@ -204,15 +204,15 @@ <h1>CSS Flexible Box Layout Level 3 Disposition of Comments for 2012-06-12 LCWD<
204204
Closed: Accepted
205205
</pre>
206206
<pre class="a" id="issue-20">
207-
Issue 20. <a href="issue-20">#</a>
207+
Issue 20. <a href="#issue-20">#</a>
208208
Summary: Baseline determination underdefined
209209
From: i18nWG
210210
Comment: <a href="http://lists.w3.org/Archives/Public/www-style/2012Jul/0271.html">http://lists.w3.org/Archives/Public/www-style/2012Jul/0271.html</a>
211211
Response: <a href="http://lists.w3.org/Archives/Public/www-style/2012Jul/0274.html">http://lists.w3.org/Archives/Public/www-style/2012Jul/0274.html</a>
212212
Closed: Accepted
213213
</pre>
214214
<pre class="a" id="issue-21">
215-
Issue 21. <a href="issue-21">#</a>
215+
Issue 21. <a href="#issue-21">#</a>
216216
Summary: Tables as flex items underdefined
217217
From: fantasai
218218
Comment: <a href="http://lists.w3.org/Archives/Public/www-style/2012Jul/0385.html">http://lists.w3.org/Archives/Public/www-style/2012Jul/0385.html</a>

css3-flexbox/issues-lc-2012.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ From: John Hax
137137
Comment: http://lists.w3.org/Archives/Public/www-style/2012Jul/0258.html
138138
Response: http://lists.w3.org/Archives/Public/www-style/2012Jul/0262.html
139139
Comment: http://lists.w3.org/Archives/Public/www-style/2012Jul/0419.html
140-
Closed: Rejected
140+
Closed: Accepted
141141
----
142142
Issue 19.
143143
Summary: Flexbox needs examples with different writing modes

0 commit comments

Comments
 (0)