import { ValuesOf } from '../utils/typeUtils'; import { STARS_RATING_BAR_SIZES, STAR_VALUES } from './StarsRatingBar.constants'; export type starRatingBarSize = ValuesOf; export type starRatingBarValue = 0 | (typeof STAR_VALUES)[number]; export type StarsRatingBarProps = { /** Applies a data-hook HTML attribute that can be used in tests. */ dataHook?: string; /** Specifies a CSS class name to be appended to the component's root element. * @internal */ className?: string; /** Controls the size of the star rating bar. Interactive mode can be `large` or `medium`. The default value for the read only mode is `medium`. */ size?: starRatingBarSize; /** Specifies whether the rating bar is in read-only mode. */ readOnly?: boolean; /** Specifies the rate input value labels. */ labelValues?: Array; /** Specifies the rate caption value labels. Array must contain all 5 strings to display the rating labels. */ descriptionValues?: Array; /** Specifies the selected rate, from `0` to `5`. `0` indicates an undefined rating. */ value: number; /** Defines a handler that is called whenever rating changes. * ##### Signature: * function(rating: number) => void * * * `rating`: 1 | 2 | 3 | 4 | 5 * */ onChange?: (rating: number) => void; /** Specifies radio group name. */ name?: string; }; //# sourceMappingURL=StarsRatingBar.types.d.ts.map