IFFDAYIFFDAYDesign
Controls

Stars

Ratings in half stars, and StarRating, a rating input that works from the keyboard.

import { Stars, StarRating } from '@iffday/ui';

Display

Ratings are stored in half stars: steps runs from 1 to 10, so 7 is three and a half stars. Full stars are brand red and empty ones light grey; size sets the star size, 14px by default. A screen reader reads 3.5 stars.

Rating

StarRating is a radio group: the left half of each star is a half star and the right half a whole one, and the arrow keys move half a star at a time. The rating under a film page’s poster is this component, 30px by default.

3.5 stars

Props

Read-only stars for a rating in half-star steps (1–10 steps = ½–5 stars).

PropTypeDefault
steps*number | null | undefined
sizenumber14

Half-star rating input. A Base UI radio group carries keyboard, focus and screen-reader semantics; each star has a left (half) and right (whole) hit area.

PropTypeDefault
value*number | null
onValueChange*(steps: number) => void
disabledboolean
sizenumber30
labelstring