- From: Guillaume via GitHub <sysbot+gh@w3.org>
- Date: Thu, 02 Nov 2023 07:22:28 +0000
- To: public-css-archive@w3.org
cdoublev has just created a new issue for https://github.com/w3c/csswg-drafts: == [css-images-4] Restriction on `<percentage>` values in `stripes()` == `<percentage>` is currently restricted to `[0,100]` in [`stripes()`](https://drafts.csswg.org/css-images-4/#funcdef-stripes) otherwise the function is invalid: > `<color-stripe> = <color> && [ <length-percentage> | <flex> ]?` > > - **`<percentage [0,100]>`**: [...] Only values between `0%` and `100%` (inclusive) are valid. > - **`<length [0,∞]>`** : [...] Negative length values are invalid. I agree with https://github.com/w3c/csswg-drafts/pull/9516#discussion_r1379437798 that values outside this range are meaningless. But then I am not sure why they make sense in `<alpha-value>` or `<brightness()>` (for example), which produce different animating behaviors (because `<alpha-value>` is clamped at parse time). However my main concern is `<length-percentage>` expanding to `<length [0,∞]> | <percentage [0,100]>`, which is not great for grammar driven parser, therefore I suggest this change: ```diff - <color-stripe> = <color> && [ <length-percentage> | <flex> ]? + <color-stripe> = <color> && [ <length [0,∞]> | <percentage [0,100]> | <flex> ]? ``` Note that `<length-percentage [0,]>` is not problematic because `[0,]` can be "inherited" during expansion. Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/9551 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Thursday, 2 November 2023 07:22:30 UTC