[csswg-drafts] [mediaqueries][editorial] Ambiguity regarding calculations in media feature values (#12729)

SebastianZ has just created a new issue for https://github.com/w3c/csswg-drafts:

== [mediaqueries][editorial] Ambiguity regarding calculations in media feature values ==
The current spec. text is a little unclear when it comes to calculations in media feature values.

https://drafts.csswg.org/mediaqueries-4/#:~:text=Media+features+only+accept+single+values says:

> There are, however, several important differences between properties and media features:
> …
> * Properties sometimes accept complex values, e.g., calculations that involve several other values. Media features only accept single values: one keyword, one number, etc.

While they only accept a single value, they do also allow calculations, i.e. `calc()`, `min()`, `max()`, etc.
Though the phrasing "calculations that involve several other values" indicates that (complex) calculations are disallowed.

So the text should be a bit clearer about that / provide a better example what's meant by a "complex value".

Plus, an example should be added showing how math functions like `calc()` _can_ be used within a media feature value.

Sebastian

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/12729 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Thursday, 4 September 2025 12:31:05 UTC