- From: Emilio Cobos Álvarez via GitHub <sysbot+gh@w3.org>
- Date: Tue, 28 May 2024 22:27:32 +0000
- To: public-css-archive@w3.org
> Prevent AccentColor/AccentColorText from being used to draw to a canvas.
What mechanism do you plan to use for this exactly?
> Prevent getComputedStyle() from returning the actual system accent color. Should it return a fixed color or something else?
> Prevent interpolation when AccentColor/AccentColorText is used.
Two bits about these... At least in Gecko (I suspect in WebKit as well), we don't preserve the system color past the computed value phase (that's a whole thing, see https://github.com/w3c/csswg-drafts/issues/6773). Having to do that just for `AccentColor` / `AccentColorText` is rather annoying.
Re. the interpolation, not being able to interpolate `AccentColor` seems like a severe limitation, which no other color has aiui. I'm assuming that this would also apply to `color-mix()` and co, right?
In particular, consider something like a generic:
```
button {
color: var(--button-color);
background-color: var(--button-background);
&:hover {
button-background: color-mix(in srgb, var(--button-background) 80%, transparent);
}
}
```
It'd be extremely confusing if now having something like:
```
--button-color: accentcolortext;
--button-background: accentcolor;
```
Now didn't work at all and made the hover effect useless.
All-in-all, I'm still of the opinion that `AccentColor` shouldn't be special (or at least shouldn't be more special than any other system color, like e.g. `Highlight`).
--
GitHub Notification of comment by emilio
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/10372#issuecomment-2136205050 using your GitHub account
--
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Tuesday, 28 May 2024 22:27:33 UTC