petals-ui
Version:
Front-end UI components foundation
17 lines (16 loc) • 552 B
TypeScript
import { NumberOrString } from '../../basic';
declare type OptionItem = {
label: string;
value: NumberOrString;
};
declare type Trigger = {
suggestions?: OptionItem[];
};
declare type Suggestion = {
options?: OptionItem[];
active?: number;
};
declare type SuggestionItem = string | OptionItem;
declare type FilterOption = (input: string, option: OptionItem) => boolean;
declare type ValidateSearch = (text: string, split: string) => boolean;
export { OptionItem, Trigger, Suggestion, SuggestionItem, FilterOption, ValidateSearch };