- From: Miriam Suzanne via GitHub <noreply@w3.org>
- Date: Mon, 09 Jun 2025 17:50:48 +0000
- To: public-css-archive@w3.org
I think one of the blockers for custom-media is that it implies a need for custom-supports and custom-container and custom-scope and custom-whatever-else. A more 'generic' option that could be used across those different at-rules may be helpful in moving things forward.
In order for mixins to fill that space, we would need a way of 'slotting' styles into the mixin:
```css
@mixin --large-screen {
@media (width > 60em) {
@contents; /* something like this */
}
}
article {
@apply --large-screen {
/* styles here slot into the media query */
}
}
```
I don't know if that's better than custom environment variables, which could be used in the query:
```css
@media env(--large-screen) { /* styles… */ }
```
--
GitHub Notification of comment by mirisuzanne
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/9350#issuecomment-2956508680 using your GitHub account
--
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Monday, 9 June 2025 17:50:49 UTC