<ax-rating> is a star-rating input. It implements ControlValueAccessor (works with
[(ngModel)] / formControlName) and exposes a two-way [(value)]. The host is a single
WAI-ARIA slider (or img when readonly), so screen readers announce
aria-valuenow / valuemax and keyboard users can adjust it without per-star tab stops.
import { AxRatingComponent } from ' @axisui-ng/forms ' ;
< ax-rating [(value)] = " score " [max] = " 5 " ariaLabel = " Overall quality " />
<!-- half-steps + amber stars -->
< ax-rating [(value)] = " score " allowHalf variant = " warning " />
< ax-rating [value] = " 4 " readonly variant = " warning " />
< ax-rating formControlName = " rating " ariaLabel = " Rating " />
Option Values Default Notes variant'default' | 'warning' | 'muted''default'Filled-star colour (text-primary / text-warning / text-muted-foreground). size'sm' | 'md' | 'lg''md'Star pixel size 16 / 20 / 24 and inter-star gap.
< ax-rating [(value)] = " score " variant = " warning " size = " lg " allowHalf />
Input Type Default Notes valuemodel<number>0Two-way; also driven by forms via CVA. maxnumber5Number of stars. allowHalfbooleanfalseEnables 0.5 increments (pointer + keyboard). readonlybooleanfalseDisplay-only; exposes role="img". disabledbooleanfalseAlso set by setDisabledState from a form. variant'default' | 'warning' | 'muted''default'Filled-star colour. size'sm' | 'md' | 'lg''md'Star pixel size (16 / 20 / 24). ariaLabelstring'Rating'Accessible name.
Key Action → / ↑Increase by one step (0.5 when allowHalf) ← / ↓Decrease by one step HomeSet to 0 EndSet to max
Interactive: role="slider", aria-valuemin/now/max, aria-valuetext (e.g. "3 of 5"), tabindex="0".
readonly: role="img" with aria-readonly; not in the tab order.
disabled: aria-disabled="true"; not focusable.
Stars are decorative (<ax-icon aria-hidden>); they never receive their own tab stop.
Interactive examples live in Storybook under Forms / Rating . Run pnpm storybook to explore them.