Components / Inputs

Rating macrolite

A row of stars scoring out of max; readOnly only displays.

Built from
BoxIcon
Children
none
Loading the renderer…
Rating rendered by the React renderer on Web
Web React
Rating rendered by the SwiftUI renderer on iOS
iOS SwiftUI
Rating rendered by the Compose renderer on Android
Android Compose
Rating rendered by the gpui renderer on Desktop
Desktop gpui

View exponential-ui-rating, painted by each native renderer.

readOnly
size · sm
size · default
size · lg
PropTypeDefaultDescription
valuebindnumber0The score, 0 to max.
maxnumber5How many stars.
readOnlybooleanfalseDisplay only; no presses.
sizesm | default | lg"default"Star size.
NameKind
on.changeevent: runs an action
Role
group
Semantics
A group of star buttons: each labelled ratingStar ("3 of 5"), the chosen one aria-pressed; read-only stars leave the tree and the group is an img labelled ratingValue ($a11y).
KeysAction
Tab through the stars; EnterSpacerate
Recipe parts
Rating/rootRating/starRating/icon
Keyed by
sizereadOnlyfilled:hover:pressed:focus:disabled:checked:open:selected:invalid:dragover

Themes · Write a theme