[css-properties-values-api] Compute <color>
Categories
(Core :: CSS Parsing and Computation, defect)
Tracking
()
People
(Reporter: fredw, Assigned: fredw)
References
(Blocks 1 open bug)
Details
From https://drafts.css-houdini.org/css-properties-values-api-1/#registered-custom-property:
For "<color>" values, the value is computed by resolving color values.
I'm not sure exactly what it means, but there is a section here in the css-color spec:
https://drafts.csswg.org/css-color-4/#resolving-color-values
In particular I noticed that many WPT tests are currently failing because tests expect "named colors" to be serialized as sRGB color, which seems to be what the spec suggests:
If the sRGB color was explicitly specified by the author as a named color, or as a system color, the specified value is that named or system color, converted to ASCII lowercase. The computed and used value is the corresponding sRGB color, paired with the specified alpha channel (after clamping to [0.0, 1.0]) and defaulting to opaque if unspecified).
Otherwise, the specified, computed and used value is the corresponding sRGB color, paired with the specified alpha channel (after clamping to [0.0, 1.0]) and defaulting to opaque if unspecified).
Assignee | ||
Updated•1 year ago
|
Description
•