-
Notifications
You must be signed in to change notification settings - Fork 756
Description
https://drafts.csswg.org/css-backgrounds-3/#propdef-background allows you to specify a background-clip value using one of the <box> bits in the syntax..
backgrounds-4 defines background-clip: text, which multiple browsers implement and ship from a long time ago. It is my intuition that if we allow to set background-clip in the background shorthand, we should also be able to set background-clip: text.
Firefox does this already: background: linear-gradient(red, blue) text parses as background-image: linear-gradient(..); background-clip: text; background-*: initial.
The system colors introduced in css-color-4 (#4091) include a Text value, which conflicts with background-clip: text in the background shorthand.
That means that the previous example will start parsing as background-color: text rather than background-clip: text, which is a significant behavior change.
So we have multiple options I guess:
- Make this behavior change (as I think Gecko is the only engine that supports
background-clip: texton the background shorthand as of now). This would be a bit unfortunate, but probably ok? - Rename the
textsystem color to something else, to prevent the naming conflict. - Something else I may be missing?