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

--br-font-size is not working on angular #103

Closed
smimar opened this issue Mar 7, 2023 · 3 comments
Closed

--br-font-size is not working on angular #103

smimar opened this issue Mar 7, 2023 · 3 comments

Comments

@smimar
Copy link

smimar commented Mar 7, 2023

Hi,
I am trying to make the size of the stars smaller but no matter what I do I can't get them smaller than their default size. I am using ionic/angular/capacitor combination.

.html
<bar-rating class="rating" [rate]="rating" [readOnly]="true" [max]="5" [theme]="'stars'">

.css
.rating{
style="--br-font-size:10px;"
}

@MurhafSousli
Copy link
Owner

You are using the stars theme which is based on a star image, font-size won't help with this theme! instead change the height and the width like the following:

.rating {
  ::ng-deep {
    .br-unit-inner {
      width: 10px;
      height: 10px;
    }
  }
}

If you want to change the star that changes with the font size, use the default theme, like in this stackblitz

@smimar
Copy link
Author

smimar commented Mar 10, 2023

Thanks

@MurhafSousli
Copy link
Owner

In version 5, you can use --br-font-size to change the size of the star

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