import React from 'react'; import { type ComposableProps } from '../../../lib/slot'; export interface RateProps extends Omit, 'onChange'> { /** * Current value (controlled) */ value?: number; /** * Default value (uncontrolled) * @default 0 */ defaultValue?: number; /** * Total count of stars * @default 5 */ count?: number; /** * Allow half star * @default false */ allowHalf?: boolean; /** * Allow clearing by clicking again * @default true */ allowClear?: boolean; /** * Disabled state * @default false */ disabled?: boolean; /** * Read-only state * @default false */ readOnly?: boolean; /** * Custom character */ character?: React.ReactNode | ((props: { index: number; }) => React.ReactNode); /** * Tooltips for each star */ tooltips?: string[]; /** * Size of stars * @default 'md' */ size?: 'sm' | 'md' | 'lg' | 'xl'; /** * Active color */ activeColor?: string; /** * Inactive color */ inactiveColor?: string; /** * Change handler */ onChange?: (value: number) => void; /** * Hover change handler */ onHoverChange?: (value: number) => void; /** * Rate content (for composable API) */ children?: React.ReactNode; } /** * Rate Component * * A star rating component for displaying and collecting ratings. * Supports both composable API (recommended) and declarative API (deprecated). * * @public * * @example * ```tsx * // Composable API (recommended) * * {Array.from({ length: 5 }, (_, i) => ( * * * * ))} * * * // Declarative API (deprecated) * * ``` * * @remarks * - Composable API provides maximum flexibility and control * - All sub-components (RateItem, RateIcon) support `asChild` * - Supports half stars, custom characters, and tooltips * - Declarative API is deprecated but still functional for backward compatibility * - Uses FT Design System tokens: var(--warning) for active, var(--border-primary) for inactive */ export declare const Rate: React.ForwardRefExoticComponent>; //# sourceMappingURL=Rate.d.ts.map