-
Notifications
You must be signed in to change notification settings - Fork 756
Description
So we're busy adding interpolation syntax through <color-interpolation-method> tokens to all CSS features that need interpolation. So far we have it in color-mix() and gradients. There is still no syntax to set interpolation color space for transitions & animations yet. We could add transition-interpolation: [ auto | <color-interpolation-method> ]# and animation-interpolation: [ auto | <color-interpolation-method> ]# properties (and corresponding tokens in shorthands), but I was wondering: what if we have an (inherited) property to set default interpolation space across an entire subtree?
Something like
color-interpolation: auto | <color-interpolation-method>
This would allow authors to set this at the root of a subtree and get their preferred interpolation method as a default across gradients, color-mix(), transitions, animations, even SVG.
This would also allow us to remove the mandatory <color-interpolation-method> token from color-mix().
Caveat: There is this old SVG color-interpolation property but I believe it's not really used/implemented. If it turns out that it is, we can include the existing sRGB and linearRGB as legacy aliases of in srgb and in srgb-linear.