import type { ReactNode } from 'react'; /** * Peek's Select (2026-08-28), verbatim, plus what Ship added: an option may * carry a `leading` node — an avatar beside a person's name — shown in the * trigger and in the list. On Base UI's `Select` since stage 4 of the * migration (2026-09-07). * * A button that shows the choice and opens a listbox under it. **Under it: * Base UI would rather lay the list over the trigger so the chosen option's * text covers the trigger's, the way macOS does — `alignItemWithTrigger` is * off, because every Select in both apps opens below one today (Katerina, * D24).** * * What the port deleted: `createPortal`, the whole `onKeyDown` switch, the * outside-click, resize and scroll listeners, the `aria-activedescendant` * bookkeeping, the `scrollIntoView` that kept the highlight visible, and * `fit.ts` — the pure geometry this component grew and then shared with the * Menu shell. Floating UI does the fitting; `--available-height` is where the * old 288px cap now meets the room the screen actually has. * * What it gained, and none of it was written here: **typeahead** — type the * first letters of an option and the list jumps to it — a listbox whose * highlight is managed rather than counted, and a value that can be part of a * form. * * Two sizes. `disabled` explains nothing by itself; `disabledReason` says * why, as Button's does: the select looks disabled, will not open, stays * reachable by Tab, and shows the reason on hover and on keyboard focus. */ export interface SelectOption { value: string; label: string; /** Drawn before the label, 16px — an Avatar, an icon. */ leading?: ReactNode; } export interface SelectProps { value: string; onChange: (value: string) => void; options: SelectOption[]; size?: 'default' | 'small'; ariaLabel?: string; /** Set by a `Field` with `required`; a caller inside one owes nothing. */ 'aria-required'?: boolean | 'true' | 'false'; placeholder?: string; disabled?: boolean; /** * Why it cannot be changed right now (UIG-14, Katerina, 19 September). It * looks disabled and will not open, but Tab still reaches it, and the reason * shows as its tooltip — a native disabled button cannot be focused, so it * could never say why. Takes the place of wrapping it in `WithTooltip`. * Given with `disabled`, the reason wins, as on `Button`. */ disabledReason?: string; className?: string; } export declare function Select({ value, onChange, options, size, ariaLabel, placeholder, disabled, disabledReason, className, ...aria }: SelectProps): import("react").JSX.Element; //# sourceMappingURL=Select.d.ts.map