import { type AriaAttributes, type ReactElement, type Ref } from "react";
import { type TextFieldProps } from "../form/TextField.js";
import { type ConfigurableComboboxMenuProps } from "../form/useCombobox.js";
import { type KeyboardMovementFocusChangeEventHandler } from "../movement/types.js";
import { type PropsWithRef, type TextExtractor } from "../types.js";
import { type AutocompleteCircularProgressProps } from "./AutocompleteCircularProgress.js";
import { type ConfigurableAutocompleteDropdownButtonProps } from "./AutocompleteDropdownButton.js";
import { type AutocompleteMenuLabel, type AutocompleteOptionsProps } from "./types.js";
/**
 * @since 6.0.0
 */
export interface AutocompleteProps<T> extends Omit<TextFieldProps, "value" | "defaultValue">, AutocompleteOptionsProps<T> {
    /** @defaultValue `"list"` */
    "aria-autocomplete"?: AriaAttributes["aria-autocomplete"];
    inputRef?: Ref<HTMLInputElement>;
    value?: string;
    defaultValue?: string;
    /**
     * An `aria-label` to pass to the `Menu` component that describes the list of
     * {@link options}. Either this or the {@link menuLabelledBy} are required for
     * accessibility.
     */
    menuLabel?: string;
    /**
     * An `aria-labelledby` to pass to the `Menu` component that describes the
     * list of {@link options}. Either this or the {@link menuLabel} are required
     * for accessibility.
     */
    menuLabelledBy?: string;
    /**
     * Any additional props that should be passed to the `Menu` component.
     */
    menuProps?: PropsWithRef<ConfigurableComboboxMenuProps & {
        id?: string;
    }, HTMLDivElement>;
    /**
     * This prop should only be used when `aria-autocomplete` is set to
     * `"inline"` or `"both"`.
     */
    onFocusChange?: KeyboardMovementFocusChangeEventHandler;
    /**
     * This can be used to add any custom styling, change the icon, change the
     * label, etc for the dropdown button.
     *
     * @example Simple Example
     * ```tsx
     * dropdownButtonProps={{
     *   "aria-label": "Open",
     *   className: styles.dropdownButton,
     *   icon: <MyCustomDropdownIcon />,
     * }}
     * ```
     */
    dropdownButtonProps?: ConfigurableAutocompleteDropdownButtonProps;
    /**
     * Set this to `true` to remove the {@link DropdownButton} from being rendered
     * after the input element.
     *
     * @defaultValue `false`
     */
    disableDropdownButton?: boolean;
    /**
     * Set this to `true` to disable a `<CircularProgress />` after the input and
     * before the `<DropdownButton />`.
     *
     * @defaultValue `false`
     */
    loading?: boolean;
    /**
     * @defaultValue `{ "aria-label": "Loading", ...loadingProps }`
     */
    loadingProps?: AutocompleteCircularProgressProps;
}
/**
 * @since 6.0.0
 */
export declare function Autocomplete<T extends string | {
    label: string;
}>(props: AutocompleteMenuLabel<Omit<AutocompleteProps<T>, "extractor">>): ReactElement;
/**
 * @since 6.0.0
 */
export declare function Autocomplete<T>(props: AutocompleteMenuLabel<AutocompleteProps<T> & {
    extractor: TextExtractor<T>;
}>): ReactElement;
