-
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
Using variables as selector, issue in inheritance #1817
Comments
Variable values are included into selector "as is", without further analysis. So, list placed into a variable can not be used the way you would like. You can avoid selectors list repetition if you rearrange your less like this:
it compiles into:
|
matthew-dean
added a commit
to matthew-dean/less.js
that referenced
this issue
Jun 3, 2018
matthew-dean
added a commit
that referenced
this issue
Jun 16, 2018
matthew-dean
added a commit
that referenced
this issue
Jun 25, 2018
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi everybody, thank for your great work!
I'm using LESS on a projet where we have one color by master page, so all the children page use 1 different color for a lot of background, hover, color, border... depending of it parent.
I can't simply use a class .background-color for all my elements to colorize for example, for several reasons.
I wanted to create one variable with all the selectors to colorize, for example :
And after that, using my page parent class name :
But the issue is that the output should be :
And in fact, it's :
To summarize :
And
Should output the same CSS, but only the first is correct :
The second output :
Do you have any idea about this?
The text was updated successfully, but these errors were encountered: