import { AdaptableColumn } from '../PredefinedConfig/Common/AdaptableColumn';
import { BaseContext, GridCell } from '../types';
/**
 * Options for configuring Quick Search
 */
export interface QuickSearchOptions<TData = any> {
    /**
     * Function enabling specific Columns to be excluded from Quick Search
     *
     * @defaultValue undefined
     */
    excludeColumnFromQuickSearch?: (column: AdaptableColumn<TData>) => boolean;
    /**
     * Value to use as placeholder in QuickSearch controls (e.g. in Dashboard)
     *
     * @defaultValue 'Search'
     * @gridInfoItem
     */
    quickSearchPlaceholder?: string;
    /**
     * Clears saved searches when AdapTable loads
     *
     * @defaultValue false
     * @gridInfoItem
     */
    clearQuickSearchOnStartUp?: boolean;
    /**
     * Filters the quick search results so only matching rows are displayed
     *
     * @defaultValue false
     * @gridInfoItem
     * @noCodeItem
     */
    filterResultsAfterQuickSearch?: boolean;
    /**
     * Include Aggregrated Columns in Group Rows when Quick Searching (highlight only)
     *
     * @defaultValue false
     * @gridInfoItem
     * @noCodeItem
     */
    runQuickSearchOnRowGroups?: boolean;
    /**
     * Include Pivot columns when Quick Searching (highlight only)
     *
     * @defaultValue true
     * @gridInfoItem
     * @noCodeItem
     */
    runQuickSearchOnPivotColumns?: boolean;
    /**
     * Run Quick Search using Case Sensitivity
     *
     * @defaultValue false
     * @gridInfoItem
     * @noCodeItem
     */
    runQuickSearchWithCaseSensitivity?: boolean;
    /**
     * Determines whether Quick Search is applied to a given cell
     *
     * @param quickSearchContext Context of the Quick Search and Cell
     */
    runBespokeQuickSearch?(quickSearchContext: QuickSearchContext): boolean;
}
/**
 * Context used when applying Quick Search in bespoke fashion
 */
export interface QuickSearchContext extends BaseContext {
    /**
     * Current Cell
     */
    gridCell: GridCell;
    /**
     * Current Quick Search Text
     */
    quickSearchValue: string;
}
