Skip to content

Commit 7857d72

Browse files
committed
[css-values-4] Incorporated feedback regarding value and phrasing
1 parent 8e934e8 commit 7857d72

File tree

3 files changed

+17
-16
lines changed

3 files changed

+17
-16
lines changed

css-grid-1/Overview.bs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1496,7 +1496,7 @@ Explicit Track Sizing: the 'grid-template-rows' and 'grid-template-columns' prop
14961496
14971497
<dfn>&lt;track-size></dfn> = <<track-breadth>> | minmax( <<inflexible-breadth>> , <<track-breadth>> ) | fit-content( <<length-percentage [0,∞]>> )
14981498
<dfn>&lt;fixed-size></dfn> = <<fixed-breadth>> | minmax( <<fixed-breadth>> , <<track-breadth>> ) | minmax( <<inflexible-breadth>> , <<fixed-breadth>> )
1499-
<dfn>&lt;track-breadth></dfn> = <<length-percentage [0,∞]>> | <<fraction [0,∞]>> | min-content | max-content | auto
1499+
<dfn>&lt;track-breadth></dfn> = <<length-percentage [0,∞]>> | <<fraction>> | min-content | max-content | auto
15001500
<dfn>&lt;inflexible-breadth></dfn> = <<length-percentage [0,∞]>> | min-content | max-content | auto
15011501
<dfn>&lt;fixed-breadth></dfn> = <<length-percentage [0,∞]>>
15021502
<dfn>&lt;line-names></dfn> = '[' <<custom-ident>>* ']'
@@ -1525,7 +1525,7 @@ Track Sizes</h4>
15251525
and then resolve against that resulting <a>grid container</a> size
15261526
for the purpose of laying out the <a>grid</a> and its items.
15271527

1528-
<dt><dfn><<fraction [0,∞]>></dfn>
1528+
<dt><dfn><<fraction>></dfn>
15291529
<dd>
15301530
Specifies the track's <dfn dfn noexport>flex factor</dfn>.
15311531
Each <<fraction>>-sized track takes a share of the remaining space in proportion to its <a>flex factor</a>.
@@ -1858,7 +1858,7 @@ Flexible Tracks</h4>
18581858
which is then divided among the flex-sized rows and columns in proportion to their <a>flex factor</a>.
18591859

18601860
Each column or row's share of the <a>leftover space</a> can be computed as the column or row's
1861-
<code>&lt;flex> * &lt;leftover space> / &lt;sum of all <a>flex factors</a>&gt;</code>.
1861+
<code>&lt;fraction> * &lt;leftover space> / &lt;sum of all <a>flex factors</a>&gt;</code>.
18621862

18631863
When the available space is infinite
18641864
(which happens when the <a>grid container</a>’s width or height is <a>indefinite</a>),
@@ -4874,7 +4874,7 @@ Changes since the <a href="https://www.w3.org/TR/2020/CRD-css-grid-1-20201218/">
48744874
See [[#layout-algorithm]].
48754875
(<a href="https://github.com/w3c/csswg-drafts/issues/3418">Issue 3418</a>)
48764876
<li id="change-2020-fr-unit">
4877-
Moved the definition of <<fraction>> to [[css-values-4#fractions]],
4877+
Renamed <<flex>> to <<fraction>> and moved its definition to [[css-values-4#fractions]],
48784878
as other specs also make use of it.
48794879
(<a href="https://github.com/w3c/csswg-drafts/issues/8027">Issue 8027</a>)
48804880
</ul>

css-grid-2/Overview.bs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1591,7 +1591,7 @@ Explicit Track Sizing: the 'grid-template-rows' and 'grid-template-columns' prop
15911591
<dfn>&lt;line-name-list></dfn> = [ <<line-names>> | <<name-repeat>> ]+
15921592
<dfn>&lt;track-size></dfn> = <<track-breadth>> | minmax( <<inflexible-breadth>> , <<track-breadth>> ) | fit-content( <<length-percentage [0,∞]>> )
15931593
<dfn>&lt;fixed-size></dfn> = <<fixed-breadth>> | minmax( <<fixed-breadth>> , <<track-breadth>> ) | minmax( <<inflexible-breadth>> , <<fixed-breadth>> )
1594-
<dfn>&lt;track-breadth></dfn> = <<length-percentage [0,∞]>> | <<fraction [0,∞]>> | min-content | max-content | auto
1594+
<dfn>&lt;track-breadth></dfn> = <<length-percentage [0,∞]>> | <<fraction>> | min-content | max-content | auto
15951595
<dfn>&lt;inflexible-breadth></dfn> = <<length-percentage [0,∞]>> | min-content | max-content | auto
15961596
<dfn>&lt;fixed-breadth></dfn> = <<length-percentage [0,∞]>>
15971597
<dfn>&lt;line-names></dfn> = '[' <<custom-ident>>* ']'
@@ -1620,7 +1620,7 @@ Track Sizes</h4>
16201620
and then resolve against that resulting <a>grid container</a> size
16211621
for the purpose of laying out the <a>grid</a> and its items.
16221622

1623-
<dt><dfn><<fraction [0,∞]>></dfn>
1623+
<dt><dfn><<fraction>></dfn>
16241624
<dd>
16251625
A non-negative dimension with the unit ''fr'' specifying the track's <dfn dfn noexport>flex factor</dfn>.
16261626
Each <<fraction>>-sized track takes a share of the remaining space in proportion to its <a>flex factor</a>.
@@ -1959,7 +1959,7 @@ Flexible Tracks</h4>
19591959
which is then divided among the flex-sized rows and columns in proportion to their <a>flex factor</a>.
19601960

19611961
Each column or row's share of the <a>leftover space</a> can be computed as the column or row's
1962-
<code>&lt;flex> * &lt;leftover space> / &lt;sum of all <a>flex factors</a>&gt;</code>.
1962+
<code>&lt;fraction> * &lt;leftover space> / &lt;sum of all <a>flex factors</a>&gt;</code>.
19631963

19641964
When the available space is infinite
19651965
(which happens when the <a>grid container</a>’s width or height is <a>indefinite</a>),
@@ -5486,7 +5486,7 @@ Changes since the <a href="https://www.w3.org/TR/2020/CRD-css-grid-2-20201218/">
54865486
(<a href="https://github.com/w3c/csswg-drafts/issues/3418">Issue 3418</a>)
54875487

54885488
<li id="change-2020-fr-unit">
5489-
Moved the definition of <<fraction>> to [[css-values-4#fractions]],
5489+
Renamed <<flex>> to <<fraction>> and moved its definition to [[css-values-4#fractions]],
54905490
as other specs also make use of it.
54915491
(<a href="https://github.com/w3c/csswg-drafts/issues/8027">Issue 8027</a>)
54925492
</ul>

css-values-4/Overview.bs

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2860,19 +2860,24 @@ Combination of <<position>></h4>
28602860
<h3 id="fractions">
28612861
Flexible lengths: the <<fraction>> type</h3>
28622862

2863-
Fraction values are non-negative <<dimension>>s denoted by
2864-
<dfn id="flex-value">&lt;flex></dfn>.
2865-
The unit identifier is <dfn value for="<flex>" lt="fr|fr unit">fr</dfn>.
2863+
Fraction values are denoted by <dfn id="flex-value">&lt;fraction></dfn>,
2864+
and indicate a value that is some fraction of another reference value.
2865+
A fraction is a <<dimension>>.
2866+
Its unit identifier is <dfn value for="<flex>" lt="fr|fr unit">fr</dfn>.
28662867

28672868
These values specify
28682869
<dfn export lt="flexible length">flexible lengths</dfn>.
28692870
Each length defines a portion of a given space
28702871
which is specified by the context the type is used in.
28712872

2873+
The allowed range of <<fraction>>> values
2874+
<em>always</em> excludes negative values,
2875+
in addition to any explicit ranges that might be specified.
2876+
28722877
Note: <<fraction>> values are not <<length>>s
28732878
(nor are they compatible with <<length>>s, like some <<percentage>> values),
28742879
so they cannot be represented in or
2875-
combined with other unit typesin ''calc()'' expressions.
2880+
combined with other unit types in ''calc()'' expressions.
28762881

28772882
<details class=note>
28782883
<summary><<fraction>> values between 0fr and 1fr have a somewhat special behavior:
@@ -2911,10 +2916,6 @@ Flexible lengths: the <<fraction>> type</h3>
29112916
if fractions are added or removed.
29122917
</details>
29132918

2914-
Note: <<fraction>> values are not <<length>>s
2915-
(nor are they compatible with <<length>>s, like some <<percentage>> values),
2916-
so they cannot be represented in or combined with other unit types in ''calc()'' expressions.
2917-
29182919

29192920
<!--
29202921
████████ ██ ██ ██ ██ ██████ ██████

0 commit comments

Comments
 (0)