-
-
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
Not filling up more than 5 stars #61
Comments
Hi @Parez ! I have to update the docs with this information. I hope it helps. best, |
HI @BioPhoton, Thanks for providing us a beautiful star rating application. I am using star rating in my application but maximum no of stars getting selected is only 5. I have checked it by overriding the var in css-star-rating.css variable file and also by creating the same var in styles.scss file. Though I am just updating a single variable maxNumOfStars. Any Help is Appreciated. Regards |
Same problem here. Hope this can be resolved. |
Did you try to do it like this? https://github.com/BioPhoton/angular-star-rating/wiki/Customizing-Styles |
Thanks for your answer @BioPhoton this is how my code looks like. I'm using Angular 5 btw $maxNumOfStars: 10;
@import "~angular-star-rating/assets/scss/star-rating"; <star-rating-comp
[id]="'album-rating'"
[starType]="'svg'"
[rating]="2.63"
[staticColor]="'ok'"
[hoverEnabled]="true"
[size]="'large'"
[step]="0.5"
[showHalfStars]="true"
[numOfStars]="10"
[readOnly]="false"
[rating]="3">
</star-rating-comp> |
Hmm, try to import from css-star-rating |
I don't know what import you mean exactly. The scss should be loaded correctly since the stars are all displayed, only the behaviour is odd at times. EDIT: I guess you meant your other repo BioPhoton/css-star-rating and link to the star-rating.scss there? EDIT2: I copied the scss files to a local folder and imported them like this: $maxNumOfStars: 10;
// @import "~angular-star-rating/assets/scss/star-rating";
@import "./star-rating/scss/star-rating"; Still the same behaviour. |
Did it work with the other import path? |
Sadly it didn't. I edited my previous comment before with more info. |
Strange... The color override works. Will check it... |
Thanks mate! |
Having the same issue, any updates about it? |
Tried the css override. Having same trouble as others. Any rating value over 5 are not fully filled to that value. Did bit of experimenting. Went into |
I'm having the same issue. It seems to be happening when using an NgFor or some iterations. If you use the component outside any iterations it works okay. EDIT: Well, apparently sometimes the change detection doesn't go as planned and the |
@BioPhoton I've placed a Pull Request with a fix for this bug, you can check it out here |
THX @todorivanov for investing time and energy into this bug!! <3 |
@BioPhoton Any news on it? |
Should be fixed in the latest version. I set the default number if start to 13. More stars can be accomplished by editing the css-star-rating lib |
Issue is still not resolved for hovering stars. css-star-rating does not mark maxNumOfStars as default, so setting the variable before importing the library does not work as expected. I have submitted a PR to css-star-rating to remedy this. |
I'm submitting a...
Current behavior
When I make an input [rating]="some value greater than 5" [numOfStars]="10" only 5 stars are getting filled.
Expected behavior
All stars up to the value should be filled, obviously.
Minimal reproduction of the problem with instructions
Environment
The text was updated successfully, but these errors were encountered: