You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: doc/parse/parser.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -161,7 +161,7 @@ A CSS rule definition must define:
161
161
- whether declarations cascade
162
162
- whether it applies to elements
163
163
164
-
The grammar may be extended depending on the context. CSS-wide keywords, arbitrary and whole value substitutions, are not part of a specific property grammar but are accepted for any property, and for descriptors in some contexts. Similarly, some numeric substitutions are only valid in contexts applying to an element.
164
+
The grammar may be extended depending on the context. Arbitrary and whole value substitutions are not part of a specific property grammar but are accepted for any property, and for descriptors in some contexts. Similarly, some numeric substitutions are only valid in contexts applying to an element.
165
165
166
166
`Element.style`, `Element.sizes`, `CanvasTextDrawingStyles.font`, `CSSFontFeatureValuesMap.set()`, etc, use parser entry points that take a grammar but no context. However, since CSS Syntax often requires validating values *"in the context"*, it is implicitly required, and the `grammar` argument can remain context-free. It cannot represent a style rule by default, since none of the above interfaces are associated to a style rule.
Copy file name to clipboardExpand all lines: doc/serialize/README.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -46,4 +46,4 @@ CSS values are currently represented either as a `List` or a plain object, with
46
46
> 4. Replace each component value in components with the result of invoking *serialize a CSS component value*.
47
47
> 5. Join the items of components into a single string, inserting `" "` (U+0020 SPACE) between each pair of items unless the second item is a `","` (U+002C COMMA). Return the result.
48
48
49
-
Step 3 is skipped since `<whitespace-token>`s are already removed from the representation of all productions but arbitrary ones (this could otherwise prevent validating a parent production like `<whole-value>`), which are represented with a `List` whose `separator` is an empty string.
49
+
Step 3 is skipped since leading and trailing `<whitespace-token>`s are already removed while consuming a list of component values and in the parse result, except for arbitrary substitution containing values, which are represented with a `List` whose `separator` is an empty string.
0 commit comments