Re: [csswg-drafts] [css-color][cssom] Serialization of specified <color> values (#1004)

What type of value you're observing depends on how you're querying it. Those bullet points talk about the value stages, and different APIs retrieve values at different stages of the pipeline.

So, are you asking about `el.style.color`, `getComputedStyle(el).color`, or something else?

> so I have to assume it is a component of a resolved value, which seems to be the only path to get green as the output instead of rgb(0, 255, 0)

I'm confused what you mean by this. The only way you'll get a color keyword is if the author specified one and you're retrieving the specified value; the bullet points in your quote make that clear. So I'm not sure how you conclude that the API you're querying is returning a resolved value, as that is defined to be either a computed or used value, and computed or used colors won't serialize as those named colors.

-- 
GitHub Notification of comment by tabatkins
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1004#issuecomment-1062371493 using your GitHub account


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

Received on Tuesday, 8 March 2022 23:25:58 UTC