-
-
Notifications
You must be signed in to change notification settings - Fork 86
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
Contextualize CSS #74
Comments
I agree with @avBerenger, leak of styles is a big problem of CSS and we can to benefit of Angular scope. I can help if you want to move on. |
Hi @lfeh, I would really appreciate your help!! Regarding prefixes for css classes I already opened an issues: Let's continue there. Best, |
My propose is add the BioPhoton/css-star-rating as a dependencie of angular-star-rating and isolate it inside Angular. So, we can also provide a option using Do you agree? |
I'm submitting a...
Current behavior
This module is wrapping style to global scope, exactly as
css-star-rating
does.Globally appended classes:
.rating
,.star
,.star-container
,.center-all
,.label-value
.Expected behavior
However, angular introduced a very good practice that scope style to a component.
It would be great (to import) to attach SCSS styles to the component but not as global.
A very quick fix is to surround by the angular component name:
Probably the better way should be attaching the
css-star-rating
's style sheet to thengComponent
.Minimal reproduction of the problem with instructions
For instance, use
<div class="label-value">...</div>
anywhere in your application.Environment
The text was updated successfully, but these errors were encountered: