Re: [csswg-drafts] [css-color-5] `light-dark()` should resolve at used value time, not computed value time (#13836)

Speaking as an author... For the BBC.co.uk website, I plan on moving us to using CSS variables + `light-dark()` for our pages that support both light and dark colour schemes. And I will be reliant on it resolving at used value time.

Until I read this issue, I wasn't aware registering the properties would change that behaviour, so I will have to avoid registering them. If I wanted to register the properties, I guess I'd have to start using `if()` instead. [Or would `if()` have the same issue?](https://drafts.csswg.org/css-conditional-values-1/#condition-computed-value)

> Is this desirable?

I think the current behaviour is **not desirable** and confusing, unexpected and un-intuitive for authors. Lea puts it really well: "the problem is exactly around this being a footgun that folks can run into without realizing. People see typing the property as a universally Good Thing™, not a tradeoff to be evaluated."


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


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

Received on Tuesday, 12 May 2026 14:21:56 UTC