- From: Sam Weinig via GitHub <sysbot+gh@w3.org>
- Date: Tue, 03 Sep 2024 18:17:32 +0000
- To: public-css-archive@w3.org
weinig has just created a new issue for https://github.com/w3c/csswg-drafts: == [css-color] Eager evaluation of calc() for specified value serialization of non-rgb() colors == The CSS Color 4 spec currently only requires [eager evaluation of calc()](https://drafts.csswg.org/css-color-4/#resolving-sRGB-values) for rgb colors: > For historical reasons, when [calc()](https://drafts.csswg.org/css-values-4/#funcdef-calc) in sRGB colors resolves to a single value, the declared value serialises without the "calc(" ")" wrapper. This leaves all the other color types without this behavior, but currently, WPT seems to contradict that. For example, in the test for specified value serialization of lab(), the [following test](https://github.com/web-platform-tests/wpt/blob/04c1ea9987/css/css-color/parsing/color-valid-lab.html#L33) has this expectation [input, expected serialization]: ```css ["lab(calc(50 * 3) calc(0.5 - 1) calc(1.5) / calc(-0.5 + 1))", "lab(100 -0.5 1.5 / 0.5)"], ``` I think the spec makes sense, and is consistent with most other CSS properties, but before changing the tests, I wanted to verify my understanding was correct. @svgeesus @LeaVerou Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/10830 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Tuesday, 3 September 2024 18:17:32 UTC