Re: [csswg-drafts] [css-color-adjust-1][mediaqueries-5] Clearly define what 'light' and 'dark' mean (#3983)

I see this text in the spec, which is simultaneously precise and imprecise (my bold):

> Additionally, if the UA determines (**based on Lab lightness**), that the canvas color is clearly either dark or light (for some reasonable UA delineation of “dark” or “light”), then it must match the appropriate value of the prefers-color-scheme media query and express a corresponding user preference for color-scheme.

Now, since L=50 is defined to be exactly mid-way, visually, between light and black then basing this on CIE Lightness is a good start. But then the spec text veers off into untestable handwaving while still using an RFC2119 must. I don't see why. Here is some suggested wording that splits lightness into thirds: light, mid/no-preference, and dark:

> Additionally, if the UA determines,based on Lab lightness, that the canvas color is clearly either dark (L < 33%) or light (L >67%) , then it must match the appropriate value of the prefers-color-scheme media query and express a corresponding user preference for color-scheme.

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

Received on Wednesday, 12 February 2020 17:38:57 UTC