Skip to content
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

Referencing Parent Selectors: & #92

Open
vincentVDB opened this issue Sep 8, 2015 · 1 comment
Open

Referencing Parent Selectors: & #92

vincentVDB opened this issue Sep 8, 2015 · 1 comment

Comments

@vincentVDB
Copy link

& must appear at the beginning of a compound selector, but it can be followed by a suffix that will be added to the parent selector. For example:

#main {
  color: black;
  &-sidebar { border: 1px solid; }
}

'-sidebar' should have the same color as 'main'
colorization working properly for '&: hover'

an other mistake with '-on'

&-on {
  background-color: $myColor;
}

@alextegelid
Copy link

This also behaves different depending on wether the selector is followed by { or ,. See example images below.

image image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants