import { UiIconProps } from '../UiIcon';
export type UiAutocompleteOption = {
    /** Unique option value emitted through `v-model`. */
    value: string;
    /** Human-readable label used for filtering and default rendering. */
    label: string;
    /** Whether the option can be selected. */
    disabled?: boolean;
};
/**
 * Filterable select input for choosing one or many options.
 * @category Form Inputs
 * @useCases autocomplete, searchable select, multi select, command picker
 * @keywords autocomplete, combobox, select, search, filter, multi-select
 * @related UiSelect, UiTagsInput, UiListbox
 */
export type UiAutocompleteProps = {
    /**
     * The controlled value.
     * - Single-select: `string`
     * - Multi-select: `string[]`
     */
    modelValue?: string | string[];
    /** Initial uncontrolled value. Same shape as `modelValue`. */
    defaultValue?: string | string[];
    /** Options rendered in the dropdown. Omit when providing items through the default slot. */
    options?: UiAutocompleteOption[];
    /** Placeholder shown when no value or query is present. */
    placeholder?: string;
    /** Accessible label for the built-in autocomplete input. Falls back to `placeholder`. */
    ariaLabel?: string;
    /** Controlled query text. */
    inputValue?: string;
    /** Initial uncontrolled query text. */
    defaultInputValue?: string;
    /** Controlled popover open state. */
    open?: boolean;
    /** Whether the popover is open initially. */
    defaultOpen?: boolean;
    /** Whether multiple options can be selected. */
    multiple?: boolean;
    /** Whether the autocomplete is disabled. */
    disabled?: boolean;
    /** Whether the field is required in a form. */
    required?: boolean;
    /** Field name used for form submission. */
    name?: string;
    /** Reading direction. */
    dir?: 'ltr' | 'rtl';
    /** Text shown when filtering returns no options. */
    emptyText?: string;
    /** Optional leading icon name. */
    startIcon?: UiIconProps['name'];
    /** Whether to show the default right-side selected indicator. */
    showIndicator?: boolean;
};
export type UiAutocompleteEmits = {
    /** Emitted when the selected value changes. */
    'update:modelValue': [value: string | string[]];
    /** Emitted when the query text changes. */
    'update:inputValue': [value: string];
    /** Emitted when the popover open state changes. */
    'update:open': [value: boolean];
    /** Emitted when the input receives focus. */
    focus: [event: FocusEvent];
    /** Emitted when the input loses focus. */
    blur: [event: FocusEvent];
    /** Emitted when the input receives keyboard input. */
    keydown: [event: KeyboardEvent];
    /** Emitted when the raw input event fires. */
    input: [event: Event];
    /** Emitted when an option is selected. */
    select: [value: string | string[], event?: Event];
};
export type UiAutocompleteInputSlotProps = {
    /** Current query text. */
    value: string;
    /** Placeholder forwarded from the component. */
    placeholder?: string;
    /** Accessible label forwarded from the component. */
    ariaLabel: string;
    /** Whether the input should be disabled. */
    disabled: boolean;
    /** Selected raw values. */
    selectedValues: string[];
    /** Selected option objects, falling back to value-as-label for missing options. */
    selectedOptions: UiAutocompleteOption[];
    /** Comma-separated selected labels. */
    displayText: string;
    /** Whether the default UI would render selected labels instead of query text. */
    showSelectionDisplay: boolean;
    /** Current popover open state. */
    open: boolean;
    /** Imperatively update the query text. */
    setInputValue: (value: string) => void;
    /** Imperatively update the popover open state. */
    setOpen: (value: boolean) => void;
};
export type UiAutocompleteItemSlotProps = {
    /** Option being rendered. */
    option: UiAutocompleteOption;
    /** Whether this option is selected. */
    selected: boolean;
    /** Whether this option is disabled. */
    disabled: boolean;
};
/**
 * Props for externally supplied autocomplete items.
 */
export type UiAutocompleteItemProps = {
    /** Unique item value. */
    value: string;
    /** Whether the item is disabled. */
    disabled?: boolean;
    /** Text used for typeahead and selected-value display fallback. */
    textValue?: string;
};
