/// import { UseListItemRootSlotProps } from '../useList'; export interface SelectOption { value: Value; label: React.ReactNode; disabled?: boolean; ref: React.RefObject; id?: string; } export interface UseOptionParameters { disabled: boolean; id?: string; label: string | React.ReactNode; rootRef?: React.Ref; value: Value; } export interface UseOptionReturnValue { /** * If `true`, the option is selected. */ selected: boolean; /** * If `true`, the option is highlighted. */ highlighted: boolean; index: number; /** * Resolver for the root slot's props. * @param externalProps props for the root slot * @returns props that should be spread on the root slot */ getRootProps: >(externalProps?: ExternalProps) => UseOptionRootSlotProps; /** * Ref to the root slot DOM node. */ rootRef: React.RefCallback | null; } export type UseOptionRootSlotProps = {}> = UseListItemRootSlotProps & { ref?: React.RefCallback | null; } & ExternalProps;