Skip to content

Commit 5dd9322

Browse files
committed
Huh, I never fixed the flex-order value back to <number> and 0. Also, tweaked the example's text.
1 parent cc32c89 commit 5dd9322

2 files changed

Lines changed: 49 additions & 34 deletions

File tree

css3-flexbox/Overview.html

Lines changed: 30 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -823,12 +823,12 @@ <h3 id=flex-order><span class=secno>3.2. </span> Display Order: the
823823
<tr>
824824
<th>Value:
825825

826-
<td>&lt;integer>
826+
<td>&lt;number>
827827

828828
<tr>
829829
<th>Initial:
830830

831-
<td>1
831+
<td>0
832832

833833
<tr>
834834
<th>Applies to:
@@ -864,25 +864,34 @@ <h3 id=flex-order><span class=secno>3.2. </span> Display Order: the
864864
<div class=example>
865865
<p>This example shows how ordinal groups might be used.</p>
866866

867-
<pre><code> div { display: flexbox; }
868-
#item1 { flex-order: 2; }
869-
#item3 { flex-order: 2; }
870-
#item4 { flex-order: 1; }
867+
<pre>
868+
div { display: flexbox; }
869+
#item1, #item3 { flex-order: 1; }
870+
#item4 { flex-order: 0; }
871871

872872
&lt;div>
873-
&lt;div id="item1">item1&lt;/div>
874-
&lt;div id="item2">item2&lt;/div>
875-
&lt;div id="item3">item3&lt;/div>
876-
&lt;div id="item4">item4&lt;/div>
877-
&lt;/div></code></pre>
878-
879-
<p>The first ordinal group, 1, contains item2 and item4. As item2 does not
880-
specify an ordinal group, it will default to 1. The elements will be
881-
displayed in document order, so item2 will be displayed before item4. The
882-
second ordinal group, 2, contains the remaining two items. The resulting
883-
display order will be:</p>
884-
885-
<pre><code>item2 item4 item1 item3</code></pre>
873+
&lt;button id="item1">One&lt;/button>
874+
&lt;button id="item2">Two&lt;/button>
875+
&lt;button id="item3">Three&lt;/button>
876+
&lt;button id="item4">Four&lt;/button>
877+
&lt;/div></pre>
878+
879+
<p>Items 2 and 4 are both in ordinal group 0 (item 2 defaults to
880+
&lsquo;<code class=css>0</code>&rsquo; because it doesn't specify one
881+
explicitly). This is the lowest ordinal group, so they'll be displayed
882+
first, and in document order, with Item 2 displayed before Item 4. The
883+
remaining items are both in ordinal group 1, so the resulting display
884+
order will be:</p>
885+
886+
<div style="border: medium solid green; display: inline-block;">
887+
<button>Two</button>
888+
889+
<button>Four</button>
890+
891+
<button>One</button>
892+
893+
<button>Three</button>
894+
</div>
886895
</div>
887896

888897
<p class=issue>Add a realistic example of tab reordering.
@@ -1790,9 +1799,9 @@ <h2 class=no-num id=property>Property index</h2>
17901799
<tr>
17911800
<th><a class=property href="#flex-order0">flex-order</a>
17921801

1793-
<td>&lt;integer>
1802+
<td>&lt;number>
17941803

1795-
<td>1
1804+
<td>0
17961805

17971806
<td>flexbox items
17981807

css3-flexbox/Overview.src.html

Lines changed: 19 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -347,10 +347,10 @@ <h3 id='flex-order'>
347347
<td><dfn>flex-order</dfn>
348348
<tr>
349349
<th>Value:
350-
<td>&lt;integer>
350+
<td>&lt;number>
351351
<tr>
352352
<th>Initial:
353-
<td>1
353+
<td>0
354354
<tr>
355355
<th>Applies to:
356356
<td><i>flexbox items</i></td>
@@ -371,21 +371,27 @@ <h3 id='flex-order'>
371371

372372
<div class=example>
373373
<p>This example shows how ordinal groups might be used.</p>
374-
<pre><code> div { display: flexbox; }
375-
#item1 { flex-order: 2; }
376-
#item3 { flex-order: 2; }
377-
#item4 { flex-order: 1; }
374+
375+
<pre>
376+
div { display: flexbox; }
377+
#item1, #item3 { flex-order: 1; }
378+
#item4 { flex-order: 0; }
378379

379380
&lt;div>
380-
&lt;div id="item1">item1&lt;/div>
381-
&lt;div id="item2">item2&lt;/div>
382-
&lt;div id="item3">item3&lt;/div>
383-
&lt;div id="item4">item4&lt;/div>
384-
&lt;/div></code></pre>
381+
&lt;button id="item1">One&lt;/button>
382+
&lt;button id="item2">Two&lt;/button>
383+
&lt;button id="item3">Three&lt;/button>
384+
&lt;button id="item4">Four&lt;/button>
385+
&lt;/div></pre>
385386

386-
<p>The first ordinal group, 1, contains item2 and item4. As item2 does not specify an ordinal group, it will default to 1. The elements will be displayed in document order, so item2 will be displayed before item4. The second ordinal group, 2, contains the remaining two items. The resulting display order will be:</p>
387+
<p>Items 2 and 4 are both in ordinal group 0 (item 2 defaults to ''0'' because it doesn't specify one explicitly). This is the lowest ordinal group, so they'll be displayed first, and in document order, with Item 2 displayed before Item 4. The remaining items are both in ordinal group 1, so the resulting display order will be:</p>
387388

388-
<pre><code>item2 item4 item1 item3</code></pre>
389+
<div style="border: medium solid green; display: inline-block;">
390+
<button>Two</button>
391+
<button>Four</button>
392+
<button>One</button>
393+
<button>Three</button>
394+
</div>
389395
</div>
390396

391397
<p class='issue'>Add a realistic example of tab reordering.</p>

0 commit comments

Comments
 (0)