@@ -163,6 +163,9 @@ The following syntax strings are supported:
163
163
:: <<number>> values
164
164
: "<percentage>"
165
165
:: Any valid <<percentage>> value
166
+ : "<length-percentage>"
167
+ :: Any valid <<length>> or <<percentage>> value, any valid <<calc()>>
168
+ expression combining <<length>> and <<percentage>> components.
166
169
: "<custom-ident>"
167
170
:: Any valid <<custom-ident>> value
168
171
: Any string, the contents of which matches the <<ident>> production
@@ -175,6 +178,12 @@ The following syntax strings are supported:
175
178
: "*"
176
179
:: Any valid token stream
177
180
181
+ Note: [[css3-values]] maintains a distinction between properties that accept
182
+ only a length, and properties that accept both a length and a percentage,
183
+ however the distinction doesn't currently cleanly line up with the productions.
184
+ Accordingly, this specification introduces the length-percentage production
185
+ for the purpose of cleanly specifying this distinction.
186
+
178
187
Regardless of the syntax specified, all custom properties will accept
179
188
<a>CSS-wide keywords</a> as well as ''revert'' , and process these values
180
189
appropriately.
@@ -188,8 +197,13 @@ For example, the following are all valid syntax strings.
188
197
: <code> "<length>"</code>
189
198
:: accepts length values
190
199
: <code> "<length> | <percentage>"</code>
191
- :: accepts lengths, or percentages, or length calc expressions, but not
192
- calc expressions containing a combination of length and percent values.
200
+ :: accepts lengths, percentages, percentage calc expressions, and length calc
201
+ expressions, but not calc expressions containing a combination of length
202
+ and percentage values.
203
+ : <code> "<length-percentage>"</code>
204
+ :: accepts all values that <code> "<length> | <percentage>"</code> would
205
+ accept, as well as calc expresssions containing a combination of both length
206
+ and percentage values.
193
207
: <code> "big | bigger | BIGGER"</code>
194
208
:: accepts the string "big", or the string "bigger", or the string "BIGGER".
195
209
: <code> "<'background-color' >"</code>
0 commit comments