[csswg-drafts] [scroll-animations-1] Serialization of "scroll-offsets: none" for CSSScrollTimelineRule (#6617)

BorisChiou has just created a new issue for https://github.com/w3c/csswg-drafts:

== [scroll-animations-1] Serialization of "scroll-offsets: none" for CSSScrollTimelineRule ==
Based on the spec section of the serialization of CSSScrollTimelineRule for `scroll-offsets` descriptor [1]:
> If the scroll-offsets descriptor is missing, the empty string. Otherwise, the concatenation of the following:
> 1. The string "scrollOffsets:", followed by a SPACE (U+0020), followed by a LEFT SQUARE BRACKET (U+005B).
> 2. For each value in the list for the rule’s scroll-offsets descriptor:
>     1. The result of performing serializes a scroll timeline offset on the value.
>     2. If not the last value, A COMMA (U+002C), followed by a SPACE (U+0020).
> 3. A RIGHT SQUARE BRACKET (U+005D), followed by a SEMICOLON (U+003B), followed by a SPACE (U+0020).

So basically,
`@scroll-timeline test { scroll-offsets: 0%, 100%; }` is serialized as
`@scroll-timeline test { scroll-offsets: [0%, 100%]; }`

However, it seems this section doesn't mention `none` case. Obviously, I think we should also address the `none` case because it is the initial value and the users may specify `none` keyword (so it's not an empty string).
e.g.
`@scroll-timeline test { scroll-offsets: none; }` should serialized as
`@scroll-timeline test { scroll-offsets: none; }` (without left and right square brackets)?

Thanks.

[1] https://drafts.csswg.org/scroll-animations-1/#serialize-a-cssscrolltimelinerule

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6617 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 15 September 2021 22:19:06 UTC