An issue in the css-env spec says:
ISSUE 3. Define the full set of places env() can be used.
- Should be able to replace any subset of MQ syntax, for example.
This made me think if we could define custom environment variables and use them in @media queries, would there still be a need for @custom-media or would it become redundant.
That could look something like the following:
@env --narrow-window: (max-width: 30em);
@media env(--narrow-window) {
/* ... */
}
(The syntax could be different, of course, as the syntax for custom environment variables hasn’t yet been decided.)