UNPKG

991 BTypeScriptView Raw
1import { h } from 'preact';
2import { TCell } from '../../../types';
3import { PluginBaseComponent, PluginBaseProps } from '../../../plugin';
4export interface SearchConfig {
5 keyword?: string;
6 enabled?: boolean;
7 ignoreHiddenColumns?: boolean;
8 debounceTimeout?: number;
9 selector?: (cell: TCell, rowIndex: number, cellIndex: number) => string;
10 server?: {
11 url?: (prevUrl: string, keyword: string) => string;
12 body?: (prevBody: BodyInit, keyword: string) => BodyInit;
13 };
14}
15export declare class Search extends PluginBaseComponent<SearchConfig & PluginBaseProps<Search>> {
16 private readonly searchProcessor;
17 private readonly actions;
18 private readonly store;
19 private readonly storeUpdatedFn;
20 static defaultProps: {
21 debounceTimeout: number;
22 };
23 constructor(props: any, context: any);
24 componentWillUnmount(): void;
25 private storeUpdated;
26 private onChange;
27 render(): h.JSX.Element;
28}