import React from 'react'; export type SegmentedControlSize = 'sm' | 'md' | 'lg'; export interface SegmentedControlProps { /** * The accessible name of the group. Required: "List, Board, Calendar" means * nothing until something says they are views. */ label: string; /** Show `label` above the control, as a form field does. Hidden by default. */ showLabel?: boolean; /** Controlled selected value. Pass `onChange` with it. */ value?: string; /** * Uncontrolled starting value. One option should always be selected — a * segmented control with nothing chosen reads as broken, not as "no choice". */ defaultValue?: string; onChange?: (value: string) => void; size?: SegmentedControlSize; /** Stretch to the container, with equal-width segments. */ isFullWidth?: boolean; isDisabled?: boolean; /** Submitted with a form under this name. */ name?: string; /** `SegmentedControlItem` elements. Two to five of them. */ children?: React.ReactNode; className?: string; } export interface SegmentedControlItemProps { /** The value this segment selects. */ value: string; /** Icon before the label. `aria-hidden` is applied for you. */ icon?: React.ReactNode; /** * Required when the segment has no visible text — an icon-only segment is * otherwise announced as an unnamed radio button. */ 'aria-label'?: string; isDisabled?: boolean; children?: React.ReactNode; className?: string; } /** * SegmentedControl — pick one of a few options, and see all of them. * * NOT TABS, ALTHOUGH IT LOOKS LIKE THE PILL TYPE, and the difference is the * contract. Tabs switch between panels: `tablist`, `tab`, `tabpanel`, and each * tab controls a region. This sets a VALUE — a view mode, a time range, a * unit — and controls no panel. It is a `radiogroup`, so it has one tab stop, * arrow keys move and select, and it submits with a form like any radio. * * Built from real radio inputs, visually hidden, not from buttons with * `aria-pressed`. A row of toggle buttons is a tab stop per option and no * mutual exclusion that assistive tech can announce; radios give "2 of 3, * selected" for free. * * The look is Tabs' pill track, token for token, so the two cannot drift * apart visually — which is exactly why the intent file spends its words on * when to use which. */ export declare const SegmentedControl: React.ForwardRefExoticComponent>; export declare const SegmentedControlItem: React.ForwardRefExoticComponent>; //# sourceMappingURL=SegmentedControl.d.ts.map