Skip to content

Commit

Permalink
[css-grid] Improve wording for automin clamping. #6278 (comment)
Browse files Browse the repository at this point in the history
  • Loading branch information
fantasai committed Mar 14, 2022
1 parent c8966ce commit f839cbb
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 17 deletions.
19 changes: 10 additions & 9 deletions css-grid-1/Overview.bs
Original file line number Diff line number Diff line change
Expand Up @@ -1331,12 +1331,13 @@ Automatic Minimum Size of Grid Items</h3>
plus any intervening <a lt="fixed sizing function">fixed</a> <a>gutters</a>.

In all cases, the size suggestion is additionally clamped by the [=maximum size=] in the affected axis,
if it's definite.
if it's [=definite=].
If the item is a [[css-sizing-3#min-content-zero|compressible replaced element]],
the size suggestion is clamped
by both the [=maximum size=] and the [=preferred size=], whichever are definite,
with their indefinite percentages resolved for this purpose against zero
(and therefore considered definite).
and has a [=definite=] [=preferred size=] or [=maximum size=]
in the relevant axis,
the size suggestion is capped by those sizes;
for this purpose, any indefinite percentages in these sizes
are resolved against zero (and considered [=definite=]).

Note: The argument to ''fit-content()'' does <em>not</em> clamp
the [=content-based minimum size=] in the same way as a
Expand All @@ -1363,11 +1364,11 @@ Automatic Minimum Size of Grid Items</h3>
converted through the aspect ratio.
It is otherwise undefined.

If the item’s has a [=preferred size=] or [=maximum size=]
If the item has a [=definite=] [=preferred size=] or [=maximum size=]
in the relevant axis,
the [=transferred size suggestion=] is capped by those sizes,
resolving any indefinite percentages in these sizes
against zero for this purpose.
the [=transferred size suggestion=] is capped by those sizes;
for this purpose, any indefinite percentages in these sizes
are resolved against zero (and considered [=definite=]).

<dt><dfn>content size suggestion</dfn>
<dd>
Expand Down
17 changes: 9 additions & 8 deletions css-grid-2/Overview.bs
Original file line number Diff line number Diff line change
Expand Up @@ -1379,10 +1379,11 @@ Automatic Minimum Size of Grid Items</h3>
In all cases, the size suggestion is additionally clamped by the [=maximum size=] in the affected axis,
if it's definite.
If the item is a [[css-sizing-3#min-content-zero|compressible replaced element]],
the size suggestion is clamped
by both the [=maximum size=] and the [=preferred size=], whichever are definite,
with their indefinite percentages resolved for this purpose against zero
(and therefore considered definite).
and has a [=definite=] [=preferred size=] or [=maximum size=]
in the relevant axis,
the size suggestion is capped by those sizes;
for this purpose, any indefinite percentages in these sizes
are resolved against zero (and considered [=definite=]).

Note: The argument to ''fit-content()'' does <em>not</em> clamp
the [=content-based minimum size=] in the same way as a
Expand All @@ -1409,11 +1410,11 @@ Automatic Minimum Size of Grid Items</h3>
converted through the aspect ratio.
It is otherwise undefined.

If the item’s has a [=preferred size=] or [=maximum size=]
If the item has a [=definite=] [=preferred size=] or [=maximum size=]
in the relevant axis,
the [=transferred size suggestion=] is capped by those sizes,
resolving any indefinite percentages in these sizes
against zero for this purpose.
the [=transferred size suggestion=] is capped by those sizes;
for this purpose, any indefinite percentages in these sizes
are resolved against zero (and considered [=definite=]).

<dt><dfn>content size suggestion</dfn>
<dd>
Expand Down

0 comments on commit f839cbb

Please sign in to comment.