Skip to content

Commit 6ee32fe

Browse files
committed
[css-grid-1][css-grid-2] Revert changes for w3c#3648, see w3c#3648 (comment)
1 parent 33a9e68 commit 6ee32fe

File tree

2 files changed

+28
-78
lines changed

2 files changed

+28
-78
lines changed

css-grid-1/Overview.bs

+14-39
Original file line numberDiff line numberDiff line change
@@ -4178,8 +4178,7 @@ Resolve Intrinsic Track Sizes</h3>
41784178
<li id="track-size-intrinsic-min">
41794179
<strong>For intrinsic minimums:</strong>
41804180
First [=distribute extra space=]
4181-
to <a>base sizes</a> of all tracks,
4182-
preferring those with
4181+
to <a>base sizes</a> of tracks with
41834182
an <a lt="intrinsic sizing function">intrinsic</a> <a>min track sizing function</a>,
41844183
to accommodate these items’ <a>minimum contributions</a>.
41854184

@@ -4198,8 +4197,7 @@ Resolve Intrinsic Track Sizes</h3>
41984197
<li id="track-size-content-min">
41994198
<strong>For content-based minimums:</strong>
42004199
Next continue to [=distribute extra space=]
4201-
to the [=base sizes=] of all tracks,
4202-
preferring those with
4200+
to the [=base sizes=] of tracks with
42034201
a <a>min track sizing function</a> of ''min-content'' or ''max-content'',
42044202
to accommodate these items' <a>min-content contributions</a>.
42054203

@@ -4208,16 +4206,14 @@ Resolve Intrinsic Track Sizes</h3>
42084206
Next, if the grid container is being sized
42094207
under a <a>max-content constraint</a>,
42104208
continue to [=distribute extra space=]
4211-
to the [=base sizes=] of all tracks,
4212-
preferring those with
4209+
to the [=base sizes=] of tracks with
42134210
a <a>min track sizing function</a> of
42144211
''grid-template-columns/auto'' or ''max-content'',
42154212
to accommodate these items' <a>limited max-content contributions</a>.
42164213

42174214
In all cases,
42184215
continue to [=distribute extra space=]
4219-
to the [=base sizes=] of all tracks,
4220-
preferring those with
4216+
to the [=base sizes=] of tracks with
42214217
a <a>min track sizing function</a> of ''max-content'',
42224218
to accommodate these items' <a>max-content contributions</a>.
42234219

@@ -4338,10 +4334,6 @@ Distributing Extra Space Across Spanned Tracks</h4>
43384334
* which tracks to affect (the |affected track|s).
43394335
* what intrinsic size contributions are being accommodated (the |size contribution|s)
43404336
of which grid items spanning those tracks (the |item|s).
4341-
* optionally, a preferred subset of the |affected tracks| (the |preferred track|s),
4342-
indicating a |track preference| (even if the subset is empty);
4343-
if no |track preference|,
4344-
the |preferred track|s default to all |affected track|s.
43454337

43464338
<ol>
43474339
<li>
@@ -4367,11 +4359,10 @@ Distributing Extra Space Across Spanned Tracks</h4>
43674359
<pre><var>space</var> = max(0, <var>size contribution</var> - ∑<var>track-sizes</var>)</pre>
43684360

43694361
<li>
4370-
<strong>Distribute |space| to |preferred track|s up to limits:</strong>
4362+
<strong>Distribute |space| up to limits:</strong>
43714363

4372-
If the item spans any |preferred track|s,
4373-
find the |item-incurred increase| for each such track by:
4374-
distributing the space equally among these tracks,
4364+
Find the |item-incurred increase| for each |affected track| by:
4365+
distributing the |space| equally among these tracks,
43754366
freezing a track’s |item-incurred increase|
43764367
as its |affected size| + |item-incurred increase|
43774368
reaches its |limit|
@@ -4383,45 +4374,29 @@ Distributing Extra Space Across Spanned Tracks</h4>
43834374
the |limit| is infinity if it is marked as [=infinitely growable=],
43844375
and equal to the [=growth limit=] otherwise.
43854376

4386-
Note: If the affected size was a <a>growth limit</a>
4377+
Note: If the |affected size| was a <a>growth limit</a>
43874378
and the track is not marked [=infinitely growable=],
43884379
then each |item-incurred increase| will be zero.
43894380

4390-
<li>
4391-
<strong>Distribute |space| to non-preferred tracks up to limits:</strong>
4392-
4393-
If extra |space| remains at this point
4394-
and the item spans any non-preferred |affected track|s,
4395-
then continue distributing |space| as defined in the previous step
4396-
to these |affected track|s,
4397-
skipping any tracks with a [=min-content=] [=max track sizing function=]
4398-
when accommodating [=max-content contributions=].
4399-
4400-
Note: This step only affects [=base sizes=],
4401-
because this algorithm is never invoked on [=growth limits=]
4402-
with any non-preferred |affected tracks|.
4403-
44044381
<li>
44054382
<strong>Distribute |space| beyond limits:</strong>
44064383

44074384
If extra |space| remains at this point,
4408-
unfreeze the |preferred track|s (if any)
4409-
or else the |affected track|s (if there was no |track preference|),
4410-
then continue to distribute |space| to the |item-incurred increase| of…
4385+
unfreeze and continue to distribute |space| to the |item-incurred increase| of…
44114386

44124387
<ul>
44134388
<li>
44144389
when <a href=#track-size-intrinsic-min>accommodating minimum contributions</a>
44154390
or <a href=#track-size-content-min>accommodating min-content contributions</a>:
4416-
any unfrozen |affected track| that happens to also have an intrinsic <a>max track sizing function</a>;
4417-
if there are no such tracks, then all unfrozen |affected track|s.
4391+
any |affected track| that happens to also have an intrinsic <a>max track sizing function</a>;
4392+
if there are no such tracks, then all |affected track|s.
44184393
<li>
44194394
when <a href=#track-size-max-content-min>accommodating max-content contributions</a>:
4420-
any unfrozen |affected track| that happens to also have a ''max-content'' <a>max track sizing function</a>;
4421-
if there are no such tracks, then all unfrozen |affected track|s.
4395+
any |affected track| that happens to also have a ''max-content'' <a>max track sizing function</a>;
4396+
if there are no such tracks, then all |affected track|s.
44224397
<li>
44234398
when handling any intrinsic <a>growth limit</a>:
4424-
all unfrozen |affected track|s.
4399+
all |affected track|s.
44254400
</ul>
44264401

44274402
For this purpose,

css-grid-2/Overview.bs

+14-39
Original file line numberDiff line numberDiff line change
@@ -4865,8 +4865,7 @@ Resolve Intrinsic Track Sizes</h3>
48654865
<li id="track-size-intrinsic-min">
48664866
<strong>For intrinsic minimums:</strong>
48674867
First [=distribute extra space=]
4868-
to <a>base sizes</a> of all tracks,
4869-
preferring those with
4868+
to <a>base sizes</a> of tracks with
48704869
an <a lt="intrinsic sizing function">intrinsic</a> <a>min track sizing function</a>,
48714870
to accommodate these items’ <a>minimum contributions</a>.
48724871

@@ -4885,8 +4884,7 @@ Resolve Intrinsic Track Sizes</h3>
48854884
<li id="track-size-content-min">
48864885
<strong>For content-based minimums:</strong>
48874886
Next continue to [=distribute extra space=]
4888-
to the [=base sizes=] of all tracks,
4889-
preferring those with
4887+
to the [=base sizes=] of tracks with
48904888
a <a>min track sizing function</a> of ''min-content'' or ''max-content'',
48914889
to accommodate these items' <a>min-content contributions</a>.
48924890

@@ -4895,16 +4893,14 @@ Resolve Intrinsic Track Sizes</h3>
48954893
Next, if the grid container is being sized
48964894
under a <a>max-content constraint</a>,
48974895
continue to [=distribute extra space=]
4898-
to the [=base sizes=] of all tracks,
4899-
preferring those with
4896+
to the [=base sizes=] of tracks with
49004897
a <a>min track sizing function</a> of
49014898
''grid-template-columns/auto'' or ''max-content'',
49024899
to accommodate these items' <a>limited max-content contributions</a>.
49034900

49044901
In all cases,
49054902
continue to [=distribute extra space=]
4906-
to the [=base sizes=] of all tracks,
4907-
preferring those with
4903+
to the [=base sizes=] of tracks with
49084904
a <a>min track sizing function</a> of ''max-content'',
49094905
to accommodate these items' <a>max-content contributions</a>.
49104906

@@ -5025,10 +5021,6 @@ Distributing Extra Space Across Spanned Tracks</h4>
50255021
* which tracks to affect (the |affected track|s).
50265022
* what intrinsic size contributions are being accommodated (the |size contribution|s)
50275023
of which grid items spanning those tracks (the |item|s).
5028-
* optionally, a preferred subset of the |affected tracks| (the |preferred track|s),
5029-
indicating a |track preference| (even if the subset is empty);
5030-
if no |track preference|,
5031-
the |preferred track|s default to all |affected track|s.
50325024

50335025
<ol>
50345026
<li>
@@ -5054,11 +5046,10 @@ Distributing Extra Space Across Spanned Tracks</h4>
50545046
<pre><var>space</var> = max(0, <var>size contribution</var> - ∑<var>track-sizes</var>)</pre>
50555047

50565048
<li>
5057-
<strong>Distribute |space| to |preferred track|s up to limits:</strong>
5049+
<strong>Distribute |space| up to limits:</strong>
50585050

5059-
If the item spans any |preferred track|s,
5060-
find the |item-incurred increase| for each such track by:
5061-
distributing the space equally among these tracks,
5051+
Find the |item-incurred increase| for each |affected track| by:
5052+
distributing the |space| equally among these tracks,
50625053
freezing a track’s |item-incurred increase|
50635054
as its |affected size| + |item-incurred increase|
50645055
reaches its |limit|
@@ -5070,45 +5061,29 @@ Distributing Extra Space Across Spanned Tracks</h4>
50705061
the |limit| is infinity if it is marked as [=infinitely growable=],
50715062
and equal to the [=growth limit=] otherwise.
50725063

5073-
Note: If the affected size was a <a>growth limit</a>
5064+
Note: If the |affected size| was a <a>growth limit</a>
50745065
and the track is not marked [=infinitely growable=],
50755066
then each |item-incurred increase| will be zero.
50765067

5077-
<li>
5078-
<strong>Distribute |space| to non-preferred tracks up to limits:</strong>
5079-
5080-
If extra |space| remains at this point
5081-
and the item spans any non-preferred |affected track|s,
5082-
then continue distributing |space| as defined in the previous step
5083-
to these |affected track|s,
5084-
skipping any tracks with a [=min-content=] [=max track sizing function=]
5085-
when accommodating [=max-content contributions=].
5086-
5087-
Note: This step only affects [=base sizes=],
5088-
because this algorithm is never invoked on [=growth limits=]
5089-
with any non-preferred |affected track|s.
5090-
50915068
<li>
50925069
<strong>Distribute |space| beyond limits:</strong>
50935070

50945071
If extra |space| remains at this point,
5095-
unfreeze the |preferred track|s (if any)
5096-
or else the |affected track|s (if there was no |track preference|),
5097-
then continue to distribute |space| to the |item-incurred increase| of…
5072+
unfreeze and continue to distribute |space| to the |item-incurred increase| of…
50985073

50995074
<ul>
51005075
<li>
51015076
when <a href=#track-size-intrinsic-min>accommodating minimum contributions</a>
51025077
or <a href=#track-size-content-min>accommodating min-content contributions</a>:
5103-
any unfrozen |affected track| that happens to also have an intrinsic <a>max track sizing function</a>;
5104-
if there are no such tracks, then all unfrozen |affected track|s.
5078+
any |affected track| that happens to also have an intrinsic <a>max track sizing function</a>;
5079+
if there are no such tracks, then all |affected track|s.
51055080
<li>
51065081
when <a href=#track-size-max-content-min>accommodating max-content contributions</a>:
5107-
any unfrozen |affected track| that happens to also have a ''max-content'' <a>max track sizing function</a>;
5108-
if there are no such tracks, then all unfrozen |affected track|s.
5082+
any |affected track| that happens to also have a ''max-content'' <a>max track sizing function</a>;
5083+
if there are no such tracks, then all |affected track|s.
51095084
<li>
51105085
when handling any intrinsic <a>growth limit</a>:
5111-
all unfrozen |affected track|s.
5086+
all |affected track|s.
51125087
</ul>
51135088

51145089
For this purpose,

0 commit comments

Comments
 (0)