import * as React from 'react'; import type { SegmentedLabeledOption as RcSegmentedLabeledOption, SegmentedProps as RCSegmentedProps, SegmentedValue as RcSegmentedValue, SegmentedRawOption } from '@rc-component/segmented'; import type { Orientation } from '../_util/hooks'; import type { GenerateSemantic } from '../_util/hooks/useMergeSemantic/semanticType'; import type { SizeType } from '../config-provider/SizeContext'; import type { TooltipProps } from '../tooltip'; export type { SegmentedValue } from '@rc-component/segmented'; export type SegmentedSemanticType = { classNames?: { root?: string; icon?: string; label?: string; item?: string; }; styles?: { root?: React.CSSProperties; icon?: React.CSSProperties; label?: React.CSSProperties; item?: React.CSSProperties; }; }; export type SegmentedSemanticAllType = GenerateSemantic; interface SegmentedLabeledOptionWithoutIcon extends RcSegmentedLabeledOption { label: RcSegmentedLabeledOption['label']; tooltip?: string | Omit; } interface SegmentedLabeledOptionWithIcon extends Omit, 'label'> { label?: RcSegmentedLabeledOption['label']; /** Set icon for Segmented item */ icon: React.ReactNode; tooltip?: string | Omit; } export type SegmentedLabeledOption = SegmentedLabeledOptionWithIcon | SegmentedLabeledOptionWithoutIcon; export type SegmentedOptions = (T | SegmentedLabeledOption)[]; export interface SegmentedProps extends Omit, 'size' | 'options' | 'itemRender' | 'styles' | 'classNames'> { rootClassName?: string; options: SegmentedOptions; /** Option to fit width to its parent's width */ block?: boolean; /** Option to control the display size */ size?: SizeType; vertical?: boolean; orientation?: Orientation; classNames?: SegmentedSemanticAllType['classNamesAndFn']; styles?: SegmentedSemanticAllType['stylesAndFn']; shape?: 'default' | 'round'; } declare const InternalSegmented: React.ForwardRefExoticComponent, "ref"> & React.RefAttributes>; declare const Segmented: ((props: SegmentedProps & React.RefAttributes) => ReturnType) & Pick; export default Segmented;