Skip to content

Commit fa780ef

Browse files
committed
Explicitly make all the HTML replaced elements always be flexbox items.
--HG-- extra : rebase_source : 79e59924bd774a6f345365cac61805f7409a3a48
1 parent 2f730e2 commit fa780ef

2 files changed

Lines changed: 40 additions & 13 deletions

File tree

css3-flexbox/Overview.html

Lines changed: 21 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,11 @@
3030

3131
<h1 id=head-box-flexible>CSS Flexible Box Layout Module</h1>
3232

33-
<h2 class="no-num no-toc" id=w3c-working>Editor's Draft, 10 May 2012</h2>
33+
<h2 class="no-num no-toc" id=w3c-working>Editor's Draft, 11 May 2012</h2>
3434

3535
<dl>
3636
<dt>This version:
37-
<!--<dd><a href="http://www.w3.org/TR/2012/ED-css3-flexbox-20120510/">http://www.w3.org/TR/2012/WD-css3-flexbox-20120510/</a>-->
37+
<!--<dd><a href="http://www.w3.org/TR/2012/ED-css3-flexbox-20120511/">http://www.w3.org/TR/2012/WD-css3-flexbox-20120511/</a>-->
3838

3939

4040
<dd><a
@@ -577,6 +577,15 @@ <h2 id=flex-items><span class=secno>4. </span> Flexbox Items</h2>
577577

578578
<li> An atomic inline-level child of a flexbox element
579579

580+
<li> An HTML <code>&lt;img></code>, <code>&lt;canvas></code>,
581+
<code>&lt;svg></code>, <code>&lt;math></code>, <code>&lt;audio></code>,
582+
<code>&lt;video></code>, <code>&lt;iframe></code>,
583+
<code>&lt;object></code>, or <code>&lt;embed></code> element. <span
584+
class=note>Note: In other words, any element that is "intended to be" a
585+
replaced element, even if it becomes non-replaced (like an
586+
<code>&lt;img></code> that doesn't load as is replaced by its alt
587+
text.)</span>
588+
580589
<li> An anonymous block element wrapped around a contiguous run of
581590
non-replaced inline child elements. However, if the contents of the
582591
anonymous block would be solely an anonymous inline containing only
@@ -2261,11 +2270,12 @@ <h3 id=line-sizing><span class=secno>9.2. </span> Line Length Determination</h3>
22612270
basis, that's the hypothetical size.
22622271

22632272
<li> Otherwise, if the flexbox's main-axis is parallel to the item's
2264-
inline-axis, lay out the item using its flex basis and the available
2265-
space, treating &lsquo;<code class=css>auto</code>&rsquo; as
2266-
&lsquo;<code class=css>max-content</code>&rsquo; unless the item's
2267-
writing mode is perpendicular to the flexbox's writing mode (in which
2268-
case <a
2273+
inline-axis, lay out the item using the available space and its flex
2274+
basis if the item is inflexible, or &lsquo;<code
2275+
class=css>auto</code>&rsquo; otherwise, treating &lsquo;<code
2276+
class=css>auto</code>&rsquo; as &lsquo;<code
2277+
class=css>max-content</code>&rsquo; unless the item's writing mode is
2278+
perpendicular to the flexbox's writing mode (in which case <a
22692279
href="http://www.w3.org/TR/css3-writing-modes/#orthogonal-flows">the
22702280
rules for a box in an orthogonal flow</a> <a href="#CSS3-WRITING-MODES"
22712281
rel=biblioentry>[CSS3-WRITING-MODES]<!--{{!CSS3-WRITING-MODES}}--></a>
@@ -2276,8 +2286,10 @@ <h3 id=line-sizing><span class=secno>9.2. </span> Line Length Determination</h3>
22762286
under that constraint instead. The hypothetical size is the item's
22772287
resulting measure.
22782288

2279-
<li> Otherwise, lay out the item using the available space, treating
2280-
&lsquo;<code class=css>auto</code>&rsquo; as &lsquo;<code
2289+
<li> Otherwise, lay out the item using the available space and its flex
2290+
basis if the item is inflexible, or &lsquo;<code
2291+
class=css>auto</code>&rsquo; otherwise, treating &lsquo;<code
2292+
class=css>auto</code>&rsquo; as &lsquo;<code
22812293
class=css>max-content</code>&rsquo; unless the item's writing mode is
22822294
perpendicular to the flexbox's writing mode (in which case <a
22832295
href="http://www.w3.org/TR/css3-writing-modes/#orthogonal-flows">the

css3-flexbox/Overview.src.html

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -270,6 +270,19 @@ <h2 id='flex-items'>
270270
<li>
271271
An atomic inline-level child of a flexbox element
272272

273+
<li>
274+
An HTML
275+
<code>&lt;img></code>,
276+
<code>&lt;canvas></code>,
277+
<code>&lt;svg></code>,
278+
<code>&lt;math></code>,
279+
<code>&lt;audio></code>,
280+
<code>&lt;video></code>,
281+
<code>&lt;iframe></code>,
282+
<code>&lt;object></code>,
283+
or <code>&lt;embed></code> element.
284+
<span class='note'>Note: In other words, any element that is "intended to be" a replaced element, even if it becomes non-replaced (like an <code>&lt;img></code> that doesn't load as is replaced by its alt text.)</span>
285+
273286
<li>
274287
An anonymous block element wrapped around a contiguous run of non-replaced inline child elements.
275288
However, if the contents of the anonymous block would be solely an anonymous inline containing only whitespace,
@@ -1496,8 +1509,9 @@ <h3 id='line-sizing'>
14961509
<li>
14971510
Otherwise,
14981511
if the flexbox's main-axis is parallel to the item's inline-axis,
1499-
lay out the item using its flex basis
1500-
and the available space,
1512+
lay out the item using the available space
1513+
and its flex basis if the item is inflexible,
1514+
or ''auto'' otherwise,
15011515
treating ''auto'' as ''max-content''
15021516
unless the item's writing mode is perpendicular to the flexbox's writing mode
15031517
(in which case <a href="http://www.w3.org/TR/css3-writing-modes/#orthogonal-flows">the rules for a box in an orthogonal flow</a> [[!CSS3-WRITING-MODES]] are in effect).
@@ -1508,8 +1522,9 @@ <h3 id='line-sizing'>
15081522

15091523
<li>
15101524
Otherwise,
1511-
lay out the item
1512-
using the available space,
1525+
lay out the item using the available space
1526+
and its flex basis if the item is inflexible,
1527+
or ''auto'' otherwise,
15131528
treating ''auto'' as ''max-content''
15141529
unless the item's writing mode is perpendicular to the flexbox's writing mode
15151530
(in which case <a href="http://www.w3.org/TR/css3-writing-modes/#orthogonal-flows">the rules for a box in an orthogonal flow</a> [[!CSS3-WRITING-MODES]] are in effect).

0 commit comments

Comments
 (0)