- From: Sebastian Zartner via GitHub <noreply@w3.org>
- Date: Wed, 05 Nov 2025 08:36:20 +0000
- To: public-css-archive@w3.org
@bramus @cdoublev:
> > > We should do the same thing we resolved on for custom media queries
> >
> > What you resolved on does not seem very explicit. 😟
>
> Isn’t that detailed in [#12536 (comment)](https://github.com/w3c/csswg-drafts/issues/12536#issuecomment-3225776469)?
To me and obviously also @sorvell, that explanation was still somewhat vague. Therefore, I've [expressed my interpretation in the other issue](https://github.com/w3c/csswg-drafts/issues/12536#issuecomment-3489791970).
@emilio:
> > If multiple [@supports-condition](https://drafts.csswg.org/css-conditional-5/#at-ruledef-supports-condition) rules are defined with the same name, the last one in document order wins, and all preceding ones are ignored.
>
> That's not great. We should do the same thing we resolved on for custom media queries, see [#12536 (comment)](https://github.com/w3c/csswg-drafts/issues/12536#issuecomment-3204778132). Otherwise it requires multiple passes to update the active style.
I agree that we should do the same thing as for custom media queries.
@cdoublev:
> It would be great to clarify this:
>
> > Anything inside the block is evaluated to test whether the user agent supports the features used.
True, some more detailed explanation and examples may help here. My expectation is:
> Should these values evaluate to true?
>
> * `style { /* comment */ }`
It's valid even when there are no properties defined, so yes. And there is already an [example related to nesting in the spec](https://drafts.csswg.org/css-conditional-5/#at-ruledef-supports-condition:~:text=detect%20support%20for%20complex%20features%20such%20as%20nesting).
> * `style { oups; }`
`oups;` is not a valid declaration, so no. The spec should be clarified to say that _everything_ nested inside `@supports-condition` and must be recognized by the UA.
> * `style { @media --oups {} }`
As it stands here, `--oups` would be interpreted as a media type, which doesn't exist, so no.
If it were wrapped in parentheses, it'd be intrepted as custom media query. In that case, I'd argue we should apply the rules resolved on in #12536. So I'd say, only if the custom media query is defined at that point, it should evaluate to true.
> * `style { @media (oups) {} }`
`oups` is not a recognized media feature, so no.
> * `style { color: green; color: green; }`
No issue with repetition, so yes.
Sebastian
--
GitHub Notification of comment by SebastianZ
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/12622#issuecomment-3489940287 using your GitHub account
--
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Wednesday, 5 November 2025 08:36:21 UTC