Rating

Buttons

An accessible animated rating component with star icons, half-star support, custom icons, hover states, and spring animations.

Loading preview...
Customize
Size:
Value
3
Max
5
Allow Half
Read Only

Props

PropTypeDefaultDescription
valuenumber0Current rating value.
onChange(value: number) => voidundefinedCallback when the rating changes.
maxnumber5Maximum rating value (number of stars).
allowHalfbooleanfalseWhether to allow half-star ratings.
readOnlybooleanfalseMakes the rating read-only.
size'sm' | 'md' | 'lg''md'Size variant of the stars.
iconReact.ReactNodeundefinedCustom icon to replace the default star.
classNamestring''Additional CSS classes.