import React, { ChangeEventHandler, KeyboardEventHandler, MouseEventHandler } from 'react'; interface ISuggestion { text: string; href: string; anchorComponentProps?: Record; } interface ISuggestableTextInputProps { /** ID of the input */ id?: string; /** Name of the input */ name: string; /** Value of the input */ value?: string; /** Placeholder text to display when input is empty */ placeholder?: string; /** If true, sets input to disabled state */ isDisabled?: boolean; /** Add autofocus attribute to input */ autoFocus?: boolean; /** Add autocomplete attribute to input */ autoComplete?: string; /** The component context */ componentContext?: string; /** A list of suggestions */ suggestions: ISuggestion[]; /** A key for the component to determine if it needs to update the suggestions */ cacheKey: string; /** Handle request to update suggestions */ handleUpdateSuggestions?: ChangeEventHandler; /** Function passed to `onChange` prop */ handleChange?: ChangeEventHandler; /** Called when the input is changed */ onChange?: (value: string) => void; /** Handle blur event */ handleBlur?: (e: React.FocusEvent, value?: string | number) => void; /** Handle key down events */ handleKeyDown?: KeyboardEventHandler; /** Handle clear button events */ handleClear?: MouseEventHandler; } /** * This component is currently under testing. * It lacks certain functionality compared to TextInput and it hasn't gone through unit testing yet. * Please use TextInput if you don't need auto-suggest feature. * Use it at your own risk if you absolutely have to. */ declare const SuggestableTextInput: React.NamedExoticComponent; export { SuggestableTextInput };