Skip to content

Commit 454fb25

Browse files
committed
[css-grid-1][editorial] Incorporate note about placement-before-sizing into the grid layout algorithm steps.
1 parent 600c743 commit 454fb25

File tree

2 files changed

+15
-10
lines changed

2 files changed

+15
-10
lines changed

css-grid-1/Overview.bs

+7-3
Original file line numberDiff line numberDiff line change
@@ -3782,21 +3782,25 @@ Grid Layout Algorithm</h2>
37823782
and lays out the [=grid items=]
37833783
which have been [=grid item placement algorithm|placed=] into its [=grid areas=].
37843784

3785-
1. First, find the size of the [=grid container=],
3785+
1. Run the [=Grid Item Placement Algorithm=]
3786+
to resolve the placement of all [=grid items=]
3787+
in the [=grid=].
3788+
3789+
2. Find the size of the [=grid container=],
37863790
per [[#intrinsic-sizes]].
37873791

37883792
Note: During this phase,
37893793
cyclic <<percentage>>s in track sizes are treated as ''grid-template-columns/auto''.
37903794

3791-
2. Given the resulting [=grid container=] size,
3795+
3. Given the resulting [=grid container=] size,
37923796
run the [=Grid Sizing Algorithm=]
37933797
to size the [=grid=].
37943798

37953799
Note: During this phase,
37963800
<<percentage>>s in track sizes are resolved
37973801
against the [=grid container=] size.
37983802

3799-
3. Lay out the [=grid items=] into their respective containing blocks.
3803+
4. Lay out the [=grid items=] into their respective containing blocks.
38003804
Each [=grid area's=] width and height
38013805
are considered [=definite=] for this purpose.
38023806

css-grid-2/Overview.bs

+8-7
Original file line numberDiff line numberDiff line change
@@ -4334,21 +4334,26 @@ Grid Layout Algorithm</h2>
43344334
and lays out the [=grid items=]
43354335
which have been [=grid item placement algorithm|placed=] into its [=grid areas=].
43364336

4337-
1. First, find the size of the [=grid container=],
4337+
1. Run the [=Grid Item Placement Algorithm=]
4338+
to resolve the placement of all [=grid items=]
4339+
(including [=subgrids=] and their sub-items)
4340+
in the [=grid=].
4341+
4342+
2. Find the size of the [=grid container=],
43384343
per [[#intrinsic-sizes]].
43394344

43404345
Note: During this phase,
43414346
cyclic <<percentage>>s in track sizes are treated as ''grid-template-columns/auto''.
43424347

4343-
2. Given the resulting [=grid container=] size,
4348+
3. Given the resulting [=grid container=] size,
43444349
run the [=Grid Sizing Algorithm=]
43454350
to size the [=grid=].
43464351

43474352
Note: During this phase,
43484353
<<percentage>>s in track sizes are resolved
43494354
against the [=grid container=] size.
43504355

4351-
3. Lay out the [=grid items=] into their respective containing blocks.
4356+
4. Lay out the [=grid items=] into their respective containing blocks.
43524357
Each [=grid area's=] width and height
43534358
are considered [=definite=] for this purpose.
43544359

@@ -4358,10 +4363,6 @@ Grid Layout Algorithm</h2>
43584363
the size of a grid item which is stretched
43594364
is also considered definite.
43604365

4361-
Note: Placement of all [=grid items=],
4362-
including [=subgrids=] and their sub-items,
4363-
occurs before sizing.
4364-
43654366

43664367
<h3 id="algo-grid-sizing" dfn export>
43674368
Grid Sizing Algorithm</h3>

0 commit comments

Comments
 (0)