import { ReactNode, SyntheticEvent } from 'react'; import { PickerText } from '../full-screen-picker/pickerCopy'; import { AutocompleteRenderOptionState, OptionLiProps } from './StyledSelectAutocomplete'; export interface SelectAutocompletePickerProps { open: boolean; dataTest: string; listboxId: string; title?: ReactNode; /** Plain-text field name: names the listbox, and the dialog when there is no `title`. */ name: string; text: PickerText; options: readonly T[]; multiple: boolean; /** Current value: the option (or `null`) with one choice, the chosen options with several. */ value: T | null | readonly T[]; /** The field may be emptied: not `disableClearable`, not read-only. */ clearable: boolean; isEqual: (a: T, b: T) => boolean; isOptionDisabled: (option: T) => boolean; getLabel: (option: T) => string; getOptionKey?: (option: T) => string | number; filterOptions?: (options: T[], state: { inputValue: string; }) => T[]; renderOptionRow: (props: OptionLiProps, option: T, state: AutocompleteRenderOptionState) => ReactNode; optionRowClassName: string; loading?: boolean; loadingText: ReactNode; noOptionsText: ReactNode; allowSelectAll?: boolean; selectAllLabel: string; /** * One choice: an option was chosen. The caller applies it, and closes when `close` is set — a tap * or Enter; Space chooses and keeps the picker open, as in the attached list. */ onSelect: (event: SyntheticEvent, option: T, close: boolean) => void; /** One choice: *Fjern valget*. The caller empties the field, closes and announces. */ onClear: (event: SyntheticEvent) => void; /** Several choices: *Ferdig*. The caller applies the draft (see `getDraftChanges`) and closes. */ onApply: (event: SyntheticEvent, draft: T[]) => void; /** Close button, Escape, Back: a cancel — nothing is applied. */ onCancel: () => void; } /** * The body of `StyledSelectAutocomplete` on a small viewport (ASMA-8468): its own search query * (the field's text is left alone), filtering, the 50-row cap, the keyboard, and the choice rules — * one choice closes on tap; several choices tick a draft that only *Ferdig* applies. The draft and * the clear-row visibility are taken at the moment it opens (REQ-011). * * @see asma-modules/_docs/frontend/plans/2026-10-19-11-04-plan-full-screen-select-picker-phones.md:218 — TASK-012..018 */ export declare function SelectAutocompletePicker({ open, dataTest, listboxId, title, name, text, options, multiple, value, clearable, isEqual, isOptionDisabled, getLabel, getOptionKey, filterOptions, renderOptionRow, optionRowClassName, loading, loadingText, noOptionsText, allowSelectAll, selectAllLabel, onSelect, onClear, onApply, onCancel, }: SelectAutocompletePickerProps): JSX.Element;