Rating
A row of stars that takes a score, or shows one to the half when it cannot change, on Radix Radio Group, named by the Label it points at.
Usage
Examples
Sizes
size sets the stars: sm 16px, base 20px (the default) or lg 24px.
Max
max sets how many stars there are, five by default, here beside ten.
Read only
readOnly, or a value with no onValueChange, only shows the score, halves included, as an image named 3.5 out of 5, beside one that takes a score as a rating does by default.
Disabled
disabled dims the stars and takes them out of the tab order, beside a rating as it is by default.
Invalid
error writes what is wrong under the stars, outlines the empty ones in the destructive colour and describes the rating to screen readers, beside one without an error.
API Reference
Rating
RatingProps · components/Rating/Rating.types.tsIt also takes the props of Radix RadioGroup.Root.