import { InputProps } from '../input';
import { InputValue } from '../input';
import { PopupProps } from '../popup';
import { SelectInputProps } from '../select-input';
import { TagInputProps } from '../tag-input';
import { TagProps } from '../tag';
import { SelectInputValueChangeContext } from '../select-input';
import { PopupVisibleChangeContext } from '../popup';
import { TNode, SizeEnum, TScroll } from '../common';
export interface TdSelectProps<T extends SelectOption = SelectOption> {
    autoWidth?: boolean;
    bordered?: boolean;
    borderless?: boolean;
    clearable?: boolean;
    collapsedItems?: TNode<{
        value: T[];
        collapsedSelectedItems: T[];
        count: number;
    }>;
    creatable?: boolean;
    disabled?: boolean;
    empty?: string | TNode;
    filter?: (filterWords: string, option: T) => boolean | Promise<boolean>;
    filterable?: boolean;
    inputProps?: InputProps;
    inputValue?: InputValue;
    defaultInputValue?: InputValue;
    keys?: SelectKeysType;
    loading?: boolean;
    loadingText?: string | TNode;
    max?: number;
    minCollapsedNum?: number;
    multiple?: boolean;
    options?: Array<T>;
    panelBottomContent?: string | TNode;
    panelTopContent?: string | TNode;
    placeholder?: string;
    popupProps?: PopupProps;
    popupVisible?: boolean;
    prefixIcon?: TNode;
    readonly?: boolean;
    reserveKeyword?: boolean;
    scroll?: TScroll;
    selectInputProps?: SelectInputProps;
    showArrow?: boolean;
    size?: SizeEnum;
    status?: 'default' | 'success' | 'warning' | 'error';
    tagInputProps?: TagInputProps;
    tagProps?: TagProps;
    tips?: string | TNode;
    value?: SelectValue;
    defaultValue?: SelectValue;
    valueDisplay?: string | TNode<{
        value: SelectValue;
        onClose: (index: number, item?: any) => void;
    }>;
    valueType?: 'value' | 'object';
    onBlur?: (context: {
        value: SelectValue;
        e: FocusEvent | KeyboardEvent;
    }) => void;
    onChange?: (value: SelectValue, context: {
        trigger: SelectValueChangeTrigger;
        e?: MouseEvent | KeyboardEvent;
    }) => void;
    onClear?: (context: {
        e: MouseEvent;
    }) => void;
    onCreate?: (value: string | number) => void;
    onEnter?: (context: {
        inputValue: string;
        e: KeyboardEvent;
        value: SelectValue;
    }) => void;
    onFocus?: (context: {
        value: SelectValue;
        e: FocusEvent | KeyboardEvent;
    }) => void;
    onInputChange?: (value: InputValue, context?: SelectInputValueChangeContext) => void;
    onPopupVisibleChange?: (visible: boolean, context: PopupVisibleChangeContext) => void;
    onRemove?: (options: SelectRemoveContext<T>) => void;
    onSearch?: (filterWords: string) => void;
    onVisibleChange?: (visible: boolean) => void;
}
export interface TdOptionProps {
    content?: string | TNode;
    default?: string | TNode;
    disabled?: boolean;
    label?: string;
    value?: string | number;
}
export interface TdOptionGroupProps {
    divider?: boolean;
    label?: string;
}
export interface SelectKeysType {
    value?: string;
    label?: string;
}
export declare type SelectValue<T extends SelectOption = SelectOption> = string | number | T | Array<SelectValue<T>>;
export declare type SelectValueChangeTrigger = 'clear' | 'tag-remove' | 'backspace' | 'check' | 'uncheck';
export interface SelectRemoveContext<T> {
    value: string | number;
    data: T;
    e: MouseEvent | KeyboardEvent;
}
export declare type SelectOption = TdOptionProps | SelectOptionGroup;
export interface SelectOptionGroup extends TdOptionGroupProps {
    group: string;
    children: Array<TdOptionProps>;
}
