2019-08-22 13:55:52 +02:00
|
|
|
declare module 'react-datalist-input' {
|
|
|
|
|
|
|
|
import * as React from 'react';
|
|
|
|
|
|
|
|
export interface DataListInputItem {
|
|
|
|
key: string | number;
|
|
|
|
label: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface DataListInputProperties {
|
|
|
|
items: DataListInputItem[];
|
|
|
|
onSelect: (selectedItem: DataListInputItem) => void;
|
|
|
|
match?: (currentInput: string, item: DataListInputItem) => boolean;
|
|
|
|
placeholder?: string;
|
|
|
|
itemClassName?: string;
|
|
|
|
activeItemClassName?: string;
|
|
|
|
inputClassName?: string;
|
|
|
|
dropdownClassName?: string;
|
|
|
|
requiredInputLength?: number;
|
|
|
|
clearInputOnSelect?: boolean;
|
|
|
|
suppressReselect?: boolean;
|
|
|
|
dropDownLength?: number;
|
|
|
|
initialValue?: string;
|
2019-08-22 13:57:27 +02:00
|
|
|
onDropdownOpen?: () => void;
|
|
|
|
onDropdownClose?: () => void;
|
2019-08-28 08:45:52 +02:00
|
|
|
debounceTime?: number;
|
|
|
|
debounceLoader?: React.ReactNode;
|
2019-08-22 13:55:52 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
export default class DataListInput extends React.Component<DataListInputProperties> {
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|