- From: Tab Atkins Jr. via GitHub <sysbot+gh@w3.org>
- Date: Tue, 06 Apr 2021 14:29:29 +0000
- To: public-css-archive@w3.org
tabatkins has just created a new issue for https://github.com/w3c/csswg-drafts: == [css-color-5] Is color-adjust() needed, now that we have relative color syntax? == Originally, [`color-adjust()`](https://drafts.csswg.org/css-color-5/#coloradjust) was the only way to modify a starting color in carefully specified ways. However, we've since added the [relative color syntax](https://drafts.csswg.org/css-color-5/#relative-colors), doing something very similar. In fact, as far as I can tell, relative color syntax *completely subsumes* color-adjust(). At least in the current grammar, color-adjust() can only adjust a single channel (tho there's a good chance we'll change that; see [Lea's comment](https://github.com/w3c/csswg-drafts/issues/6142#issuecomment-813678225)), and it can only do so as a % adjustment. Relative color syntax, on the other hand, can adjust all the channels at once, and can do arbitrarily complicated mathematical adjustments to them, including but definitely not limited to % adjustment. It also just seems a little easier to read, in my opinion: compare `color-adjust(lch, red h 20%)` vs `lch(from red l c calc(h * .2))`. I think at this point, addressing the issues with `color-adjust()` (allowing multiple channels, allowing more complex mathematical adjustment) would just be bringing it into alignment with relative color-syntax, not giving any additional features. Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6179 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Tuesday, 6 April 2021 14:29:31 UTC