-
Notifications
You must be signed in to change notification settings - Fork 192
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
multiple static media expressions, OR rule #102
Comments
I am doing shit with GitHub this morning. My apologies. I'll let @eduardoboucas have a look. :) |
For me the most readable (but unfortunately most breaking-changey) would be: @include media('xs' 'retina2x', 'some-other-expr' 'height>small') {
...
} So you'd have div {
border: 2px solid red, 1px dashed purple;
} |
I'm sorry for jump into the discussion, but... Why not |
We’ll likely use |
My vote is on |
Closing this. See #144 and include-media-or. |
I've started to use susy for my grids and didn't want to drop
include-media
forbreakpoint
.Turns out, it should be reasonably easy to make a mixin to use susy with your plugin (oddbird/susy#524).
What I stumbled over was a malfunctioning media rule when adding more than one static media expressions. Makes totally sense that it's not working since they exclude each other. It's still strange how they fail (3 min-width statements).
What I really wanted, was an OR rule.
First things first, the code:
im media-expressions:
my code:
output
what i really want
I know that it is far more feasible to just use breakpoints and do something like
@include media('>xs')
. But sometimes it's just convenient to combine media expressions with an OR rule. Especially when they're not min-width, max-width related. Is there a way to do that?The text was updated successfully, but these errors were encountered: