Ratings

August 7, 2019 ยท View on GitHub

Simple Rating Component for your next Angular Project. Very simple to setup and use and comes with a lot of customizations.

Features

  • Simple and Easy to Setup
  • Ease to use
  • Dependency on only the icons
  • Supports half-star rating
  • Supports Rating Mode and also Display only Mode

User Ratings Card

How to Use the Component

The component uses material icons and there are no other dependencies.

npm i material-icons

  1. Create a component in your project.
  2. Copy and paste the rating bar component codes into your newly created component

You can now start using it in any component of your project.

Customizations

FeatureDescriptionAttributeTypeDefault
No of StarsYou can change the total rating numbertotalnumber5
Display ModeStar Rating component can be used to just display the ratingreadonlybooleanfalse
Size of StarsThe size of the stars displayed can be changed to your needssizestring24px
Type of StarsThe component supports filled stars and hollow stars designtypefilled or hollowhollow
Rating ColorThe color for the filled StarsfilledColorstring#3db700
Rating ColorThe color for the empty StarsemptyColorstring#e0e0e0
Rating EventRating Emitted when user clicks on the ratingratednumbernil