- From: Oliver Joseph Ash via GitHub <sysbot+gh@w3.org>
- Date: Fri, 21 Jun 2019 11:46:19 +0000
- To: public-css-archive@w3.org
Judging by https://github.com/w3c/csswg-drafts/issues/112#issuecomment-221672439, the idea would be to achieve something like this?
```
@when selector(.light) or (media(max-width: 499px) and selector(.lightOnMobileAndDarkOnDesktop)) {
  /* styles for light */
}
@when selector(.dark) or (media(min-width: 500px) and selector(.lightOnMobileAndDarkOnDesktop)) {
  /* styles for dark */
}
```
IIUC, that would be very nice. However one downside is it forces you to declare things at the same time, in this case `light`/`dark` must be defined along with `lightOnMobileAndDarkOnDesktop`. I would prefer to keep the selectors separate. /cc @tabatkins 
``` css
.light {}
.dark {}
.lightOnMobileAndDarkOnDesktop {
  /* compose classes inside here */
}
```
-- 
GitHub Notification of comment by OliverJAsh
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/4040#issuecomment-504396944 using your GitHub account
Received on Friday, 21 June 2019 11:46:21 UTC