import React from 'react'; import { InputOption } from './hooks/useData'; import { PickerToggleProps } from '../internals/Picker'; import type { Option, FormControlPickerProps } from '../internals/types'; import type { InputPickerLocale } from '../locales'; import type { SelectProps } from '../SelectPicker'; export type ValueType = any; export interface InputPickerProps extends FormControlPickerProps, Omit, 'renderValue'>, Pick { tabIndex?: number; /** Settings can create new options */ creatable?: boolean; /** Option to cache value when searching asynchronously */ cacheData?: InputOption[]; /** The `onBlur` attribute for the `input` element. */ onBlur?: React.FocusEventHandler; /** The `onFocus` attribute for the `input` element. */ onFocus?: React.FocusEventHandler; /** Called when the option is created */ onCreate?: (value: V, item: Option, event: React.SyntheticEvent) => void; /** * Customize whether to display "Create option" action with given textbox value * * By default, InputPicker hides "Create option" action when textbox value matches any filtered item's [valueKey] property * * @param searchKeyword Value of the textbox * @param filteredData The items filtered by the searchKeyword */ shouldDisplayCreateOption?: (searchKeyword: string, filteredData: InputOption[]) => boolean; renderValue?: (value: V, item: Option, selectedElement: React.ReactNode) => React.ReactNode; } /** * Single item selector with text box input. * * @see https://rsuitejs.com/components/input-picker */ declare const InputPicker: import("../internals/types").InternalRefForwardingComponent<"div", InputPickerProps, never> & Record; export default InputPicker;