import React, { ReactElement } from 'react'; import { IconProps } from '../icons/generated'; import { AriaFocusProps } from '../../types/common'; import { SegmentedControlSize } from './types'; import { TooltipProps } from '../tooltip'; export interface SegmentedControlOptionType { label?: string; value: string; icon?: ReactElement; disabled?: boolean; tooltipProps?: Pick; /** * IconOnly인 경우 노출됩니다. */ tooltip?: string; /** * disabled 상태일때 노출됩니다. * iconOnly인 경우 {tooltip} ({disabledTooltip}) 형태로 노출됩니다. */ disabledTooltip?: string; } export interface SegmentedControlProps extends Omit, 'defaultValue' | 'value' | 'onChange'>, AriaFocusProps { className?: string; defaultValue?: string; value?: string; size?: SegmentedControlSize; items: SegmentedControlOptionType[]; width?: 'fill' | 'auto'; disabled?: boolean; keyExtractor?: (item: SegmentedControlOptionType, index: number) => string | number; onChange?: (value: string) => void; } export interface SegmentedControlInstance { value?: string; focus: () => void; } export declare const SegmentedControl: React.ForwardRefExoticComponent>;