-
Notifications
You must be signed in to change notification settings - Fork 753
Description
Based on comments in #10879, any value defined in CSS Values and Units should be valid in any context other than a property value, unless otherwise specified.
mix, random, tree couting functions, need an element, but are not explicitly disallowed in other contexts.
I would say they should be invalid in media queries and any descriptor value, and valid in the prelude of keyframe and @container rules. (It seems easier to find use cases in the prelude of keyframe rules.)
Perhaps defining the concept of element-dependent (substitution) value could help clarifying this: such value would be invalid in all contexts except those "associated" to an element, or that do not need to resolve its value (feature queries). var(), attr(), toggle(), <whole-value>, would be element-dependent subsitution values.
I do not know if any of these substitution functions should/can be valid in the HTML srcset attribute (to replace <length>), but invalid in the media attribute. I guess none is currently accepted, not even math functions.