ttolbel UI

Component

Rating

A row of stars that fill on hover and click, with optional half-star precision, read-only or interactive.

The primitive

rating.tsx
<NativeRating value={value} onValueChange={setValue} />

Example

A read-only rating summarizing feedback left after a completed transaction, no interactivity since the score is already final.

How was this transaction?
rating-example.tsx
<NativeRating value={5} readOnly />

Capabilities

PropTypeDescription
valuerequirednumber
onValueChange(value: number) => void
maxnumber
sizenumber
readOnlyboolean
allowHalfboolean
classNamestring