import React from 'react'; import { FilterAddProps } from '../../FilterAdd'; import { SearchPopperProps } from '../../SearchPopper'; import { BaseProps } from '../BaseFilter'; import { FilterContext } from '../FilterContext'; import { State } from './FilterSlot.Provider'; import { Styles } from './FilterSlot.style'; declare type FilterDictionary = State['appliedFilters']; export declare type Props = { hideAddButton?: boolean; defaultFilter?: string; disabled?: boolean; loading?: boolean; children: Array>>; appliedFilters?: FilterDictionary; initialAppliedFilters?: FilterDictionary; extraFilterAddEntries?: FilterAddProps['extraFilters']; onFilterAddSearch?: FilterAddProps['onSearch']; onFilterAddSelect?: (filterId: SearchPopperProps['options'][number]['id'], filterInitialValue: SearchPopperProps['options'][number]['initialValue'], evt: React.MouseEvent | React.KeyboardEvent) => void | boolean; onApply?: (f: FilterDictionary, ev?: React.SyntheticEvent) => void; onCancelQuery?: () => void; onResetAll?: () => void; applyDisabled?: boolean; onRemoveFilter?: (id: string) => void; onMenuOpen?: () => void; } & Styles; export default class FilterSlot extends React.PureComponent { static contextType: React.Context<{ handleSetTempValue: (id: K, tempValue: any) => void; handlePopperClose: () => void; handleRemoveFilter: (id: string) => void; handleChangeFilter: (id: K_1, value: any) => void; handleAddFilter: (id: K_2, initialValue: any) => void; handleRemoveAllFilters: () => void; handleChipFilterClick: (id: string) => (el: HTMLElement) => void; setState: (state: Partial>>) => void; tryOpenTipToApply: () => void; addChangeFilterListener: (callback: (id: string, isAdding: boolean, value: any) => void) => void; addRemoveFilterListener: (callback: (id: string) => void) => void; scrollbarsRef: React.RefObject<{}>; renderSplit: boolean; shouldOpenTipToApply: boolean; order: string[]; disabled: boolean; initialAppliedFilters: Partial>; appliedFilters: Partial>; shownFilters: Partial>; tempFilters: Partial>; anchorEl: HTMLElement; addChipRef: React.RefObject; openFilter: string; }>; context: React.ContextType; filterAddChipRef: React.RefObject; uniqueId: string; static defaultProps: { disabled: boolean; loading: boolean; applyDisabled: boolean; onApply: () => void; onResetAll: () => void; onFilterAddSearch: () => void; onFilterAddSelect: () => void; onRemoveFilter: () => void; onMenuOpen: () => void; }; constructor(props: Props, context: React.ContextType); statesAreEqual: () => boolean; canCancel: () => boolean; shouldDisableApply: () => boolean; componentWillReceiveProps(nextProps: Props): void; componentDidUpdate(): void; keyPressHandler: (event: KeyboardEvent) => void; handleRemoveAllFilters: () => void; handleCancel: () => void; handleApply: (ev?: React.SyntheticEvent) => void; handleUpdateScrollBar: ({ scrollWidth, clientWidth }: { scrollWidth: any; clientWidth: any; }) => void; orderMap: () => ({ props: { filterAddOption: { id: a }, }, }: { props: { filterAddOption: { id: any; }; }; }, { props: { filterAddOption: { id: b }, }, }: { props: { filterAddOption: { id: any; }; }; }) => number; private processChipOrderState; render(): JSX.Element; renderApplyButton(): JSX.Element; handleFilterAddSelect: (filterId: SearchPopperProps['options'][number]['id'], filterInitialValue: SearchPopperProps['options'][number]['initialValue'], evt: React.MouseEvent | React.KeyboardEvent) => void; handleMenuOpen: (event: HTMLDivElement) => void; renderFilterAdd(): JSX.Element; } export {}; //# sourceMappingURL=FilterSlot.d.ts.map