Re: [csswg-drafts] [css-ui-4] Authors should have access to accent-color value to use in their code (#5900)

> I guess it can't be an env variable: such variables are evaluated independently of where you are in the tree, and thus would always return the UA's default accent color, which we cannot share for fingerprinting reasons (see in #6158). If we want the local accent-color, as set by the author, we need something context sensitive, so that wouldn't be an env variable, but something more like the `currentColor` keyword.

This brings up a more general point: Do we need something like `env()` that *is* context-sensitive?

> So, fwiw. WebKit does expose the OS accent color via `-webkit-focus-ring-color`.
> 
> Gecko has `-moz-accent-color` for the Firefox UI but we don't expose it to websites. I think I agree with @frivoal that making a more magic keyword for this seems overkill.

I think the fact that UAs are making up their own keywords for this indicates that there's a need for it.

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


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

Received on Monday, 26 April 2021 13:38:48 UTC