Rate
Preview
Section titled “Preview”Rating: 3 / 5
Installation
Section titled “Installation”npx skeci-ui add rateimport { Rate } from '@/components/ui/rate';
<Rate count={5} defaultValue={3} onChange={(value) => console.log(value)}/>Variants
Section titled “Variants”Sizes
Readonly & Disabled
Custom Count (10 stars)
| Prop | Type | Default | Description |
|---|---|---|---|
count | number | 5 | The total number of stars. |
value | number | — | The controlled value of the rating. |
defaultValue | number | 0 | The initial value when uncontrolled. |
onChange | (value: number) => void | — | Callback fired when the value changes. |
size | 'sm' | 'md' | 'lg' | 'md' | The size of the stars. |
disabled | boolean | false | Whether the component is non-interactive. |
readonly | boolean | false | If true, the rating can be displayed but not changed. |