-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
@media queries & mixins not parsed correctly #544
Comments
Your output is what I would expect. A curly braced selector creates a new variable context. Hence, I agree that there's some special cases or functions needed for media query syntax, but what you're expecting is contrary to how variable scoping currently works in LESS. |
this might be fixed with 1.3 ? Have you checked? |
Hey @agatronic, thanks for pointing this out. Cheers! |
Why is this issue closed? I have exactly the same problem with twitter bootstrap, when I try to "extend" the .container class, for example. It's confusing for me this behavior because, if I have this: .a {
padding-top: 10px;
}
(...)
//another scope
.a {
padding-left: 30px;
}
.b {
.a;
} then I get .b {
padding-top: 10px;
padding-left: 30px;
} Why media queries don't have the same behavior? |
@andreabreu98 I don't exactly get what you are saying. Are you saying that media queries should be grouped? If so.. there was a bug for that in #950 |
closing again due to lack of response. |
Hey guys,
I think that the syntax mentioned by @tylertate on issue #152 if implemented would solve this issue, but thought I'd raise that the following less does not parse correctly:
Input:
Expected result:
I'd expect that both the top-level .classone rules are copied, as well as the media specific rules for .classtwo. The generated result I expected looked something like...
Actual result:
The result for .classtwo lacks the @media declaration completely, and the following is what is generated:
The text was updated successfully, but these errors were encountered: