/// <reference types="lodash" />
import { Key, ReactNode } from 'react';
import { IReactionDisposer } from 'mobx';
import Group from 'choerodon-ui/dataset/data-set/Group';
import { Config, ConfigKeys, DefaultConfig } from '../../../lib/configure';
import { ConfigContextValue } from '../../../lib/config-provider/ConfigContext';
import { ColumnProps } from './Column';
import DataSet from '../data-set/DataSet';
import Record from '../data-set/Record';
import { RecordCachedType } from '../data-set/enum';
import { DragColumnAlign, ScrollPosition, TableAutoHeightType, TableColumnResizeTriggerType, TableColumnTooltip, TableHeightType, TableQueryBarType } from './enum';
import ColumnGroups from './ColumnGroups';
import Table, { expandIconProps, TableCustomized, TableGroup, TablePaginationConfig, TableProps, TableQueryBarHook } from './Table';
import { Size } from '../core/enum';
import TableEditor from './TableEditor';
import { HighlightRenderer, TagRendererProps } from '../field/FormField';
import VirtualRowMetaData from './VirtualRowMetaData';
import BatchRunner from '../_util/BatchRunner';
import ColumnGroup from './ColumnGroup';
export declare const SELECTION_KEY = "__selection-column__";
export declare const COMBOBAR_KEY = "__combo-column__";
export declare const ROW_NUMBER_KEY = "__row-number-column__";
export declare const DRAG_KEY = "__drag-column__";
export declare const EXPAND_KEY = "__expand-column__";
export declare const CUSTOMIZED_KEY = "__customized-column__";
export declare const AGGREGATION_EXPAND_CELL_KEY = "__aggregation-expand-cell__";
export declare const BODY_EXPANDED = "__body_expanded__";
export declare const VIRTUAL_ROOT_MARGIN = 50;
export declare type HeaderText = {
    name: string;
    label: string;
};
export declare function getIdList(store: TableStore): number[];
export declare function normalizeGroupColumns(tableStore: TableStore, columns: ColumnProps[] | undefined, children: ReactNode, aggregation?: boolean, customizedColumns?: {
    [key: string]: ColumnProps;
}): [ColumnProps[], ColumnProps[], ColumnProps[], boolean];
export default class TableStore {
    configContext: ConfigContextValue;
    node: Table;
    editors: Map<string, TableEditor>;
    customizedLoaded?: boolean;
    props: TableProps;
    customized: TableCustomized;
    tempCustomized: TableCustomized;
    loading?: boolean;
    leftOriginalColumns: ColumnProps[];
    originalColumns: ColumnProps[];
    rightOriginalColumns: ColumnProps[];
    hasAggregationColumn?: boolean;
    calcBodyHeight: number | undefined;
    width?: number;
    lastScrollTop: number;
    lastScrollLeft: number;
    lockColumnsBodyRowsHeight: any;
    lockColumnsFootRowsHeight: any;
    lockColumnsHeadRowsHeight: any;
    expandedRows: (string | number)[];
    hoverRow?: Record;
    rowClicked?: boolean;
    currentEditorName?: string;
    styledHidden?: boolean;
    customizedActiveKey: string[];
    mouseBatchChooseStartId: number;
    mouseBatchChooseEndId: number;
    mouseBatchChooseState: boolean;
    mouseBatchChooseIdList: number[];
    columnResizing?: boolean;
    scrollPosition: ScrollPosition;
    inBatchExpansion: boolean;
    performanceOn: boolean;
    comboBarStatus: boolean;
    lastSelected?: Record;
    activeEmptyCell?: HTMLTableCellElement;
    timing: {
        renderStart: number;
        renderEnd: number;
    };
    siblingHeihgt?: {
        before?: number;
        after?: number;
    };
    parentHeight?: number | undefined;
    parentPaddingTop?: number | undefined;
    screenHeight: number;
    headerHeight: number;
    footerHeight: number;
    headerFilter?: {
        fieldName?: string;
        filterText?: any;
        filter?: boolean | ((props: {
            record: Record;
            filterText?: string;
        }) => boolean);
    };
    nextRenderColIndex?: [number, number];
    prevRenderColIndex?: [number, number];
    get styleHeight(): string | number | undefined;
    get styleMaxHeight(): string | number | undefined;
    get styleMinHeight(): string | number | undefined;
    get computedHeight(): number | undefined;
    get otherHeight(): number;
    get height(): number | undefined;
    get totalHeight(): number;
    get bodyHeight(): number;
    get stickyLeft(): boolean;
    get stickyRight(): boolean;
    get performanceEnabled(): boolean;
    get dataSet(): DataSet;
    get prefixCls(): string | undefined;
    get customizable(): boolean | undefined;
    /**
     * board 组件个性化按钮 in buttons
     */
    get customizedBtn(): boolean | undefined;
    get aggregation(): boolean | undefined;
    get aggregationExpandType(): 'cell' | 'row' | 'column';
    get autoHeight(): {
        type: TableAutoHeightType;
        diff: number;
    } | undefined;
    get heightType(): TableHeightType;
    get originalHeightType(): TableHeightType;
    get virtualCell(): boolean | undefined;
    get isFixedRowHeight(): boolean;
    get propVirtual(): boolean | undefined;
    get virtual(): boolean | undefined;
    get columnBuffer(): number;
    get columnThreshold(): number;
    updateRenderZonePosition(): [number, number];
    get virtualColumnRange(): {
        left?: [number, number];
        center: [number, number];
        right?: [number, number];
    };
    isRenderRange(index: number, isGroup?: boolean): boolean;
    get blankVirtualCell(): {
        left: JSX.Element[];
        right: JSX.Element[];
    };
    get tableColumnResizeTransition(): boolean | undefined;
    actualRows: number | undefined;
    rowMetaData?: VirtualRowMetaData[] | undefined;
    lastMeasuredIndex: number;
    scrolling: boolean | undefined;
    cellVerticalSize: number | undefined;
    get virtualRowHeight(): number;
    get virtualEstimatedRows(): number;
    get virtualHeight(): number;
    get virtualVisibleStartIndex(): number;
    get virtualVisibleEndIndex(): number;
    get virtualStartIndex(): number;
    get virtualEndIndex(): number;
    get virtualTop(): number;
    get hidden(): boolean | undefined;
    get alwaysShowRowBox(): boolean;
    get keyboard(): boolean;
    get columnResizable(): boolean;
    get columnHideable(): boolean;
    /**
     * 表头支持编辑
     */
    get columnTitleEditable(): boolean;
    get heightChangeable(): boolean;
    get pagination(): TablePaginationConfig | false | undefined;
    get pageSizeChangeable(): boolean;
    get dragColumnAlign(): DragColumnAlign | undefined;
    get columnDraggable(): boolean;
    get rowDraggable(): boolean;
    get size(): Size;
    get rowHeight(): 'auto' | number;
    get headerRowHeight(): 'auto' | number;
    get footerRowHeight(): 'auto' | number;
    get autoFootHeight(): boolean;
    get emptyText(): ReactNode;
    get highLightRow(): boolean | string;
    get parityRow(): boolean;
    get showRemovedRow(): boolean;
    get autoFocus(): boolean;
    get selectedHighLightRow(): boolean;
    get editorNextKeyEnterDown(): boolean;
    get border(): boolean;
    get columnEditorBorder(): boolean;
    get queryBar(): TableQueryBarType | TableQueryBarHook | undefined;
    get expandIcon(): ((props: expandIconProps) => ReactNode) | undefined;
    get tableColumnResizeTrigger(): TableColumnResizeTriggerType;
    get currentEditRecord(): Record | undefined;
    set currentEditRecord(record: Record | undefined);
    showCachedSelection?: boolean;
    defaultRecordCachedType?: RecordCachedType;
    recordCachedType?: RecordCachedType;
    get computedRecordCachedType(): RecordCachedType | undefined;
    get isTree(): boolean;
    get editing(): boolean;
    get hasRowBox(): boolean;
    get useMouseBatchChoose(): boolean;
    get showCachedTips(): boolean;
    get showSelectionTips(): boolean;
    get overflowX(): boolean;
    get overflowY(): boolean;
    get hasRowGroups(): boolean;
    get headerTableGroups(): TableGroup[];
    customizedColumnHeader(): JSX.Element;
    get customizedColumn(): ColumnProps | undefined;
    get expandColumn(): ColumnProps | undefined;
    get rowNumberColumn(): ColumnProps | undefined;
    get selectionColumn(): ColumnProps | undefined;
    get comboQueryColumn(): ColumnProps | undefined;
    get draggableColumn(): ColumnProps | undefined;
    get leftColumns(): ColumnProps[];
    get rightColumns(): ColumnProps[];
    get columns(): ColumnProps[];
    get columnGroups(): ColumnGroups;
    get leftColumnGroups(): ColumnGroups;
    get rightColumnGroups(): ColumnGroups;
    get leafNamedColumns(): ColumnProps[];
    get hasEmptyWidthColumn(): boolean;
    get getLastEmptyWidthColumn(): ColumnProps | undefined;
    get hasCheckFieldColumn(): boolean;
    get hasFooter(): boolean;
    get isAnyColumnsLeftLock(): boolean;
    get isAnyColumnsRightLock(): boolean;
    get isAnyColumnsLock(): boolean;
    get isCombinedColumn(): boolean;
    groups: TableGroup[];
    groupedData: Group[];
    groupedDataWithHeader: Group[];
    get cachedDataInType(): Record[];
    get cachedData(): Record[];
    get currentData(): Record[];
    get treeFilter(): ((record: Record) => boolean) | undefined;
    get data(): Record[];
    get cachedIndeterminate(): boolean;
    get allCachedChecked(): boolean;
    get currentIndeterminate(): boolean;
    get allCurrentChecked(): boolean;
    get indeterminate(): boolean;
    get allChecked(): boolean;
    get expandIconAsCell(): boolean;
    get expandIconColumnIndex(): number;
    get inlineEdit(): boolean;
    checkAllCurrent(): void;
    unCheckAllCurrent(): void;
    checkAllCached(): void;
    unCheckAllCached(): void;
    private handleSelectAllChange;
    constructor(node: Table);
    isBuiltInColumn({ key }: ColumnProps): boolean | undefined;
    getColumnTooltip(column: ColumnProps): TableColumnTooltip | undefined;
    getColumnHeaders(): Promise<HeaderText[]>;
    getColumnTagRenderer(column: ColumnProps): ((props: TagRendererProps) => ReactNode) | undefined;
    showEditor(name: string): void;
    setLastScrollTop(lastScrollTop: number): void;
    setLastScrollLeft(lastScrollLeft: number): void;
    hideEditor(): void;
    changeMouseBatchChooseIdList(idList: number[]): void;
    showNextEditor(name: string, reserve: boolean): boolean;
    setProps(props: any): void;
    updateProps(props: any): void;
    groupReaction?: IReactionDisposer;
    disposeGroupReaction(): void;
    dispose(): void;
    initGroups(): void;
    initColumns(): void;
    isAggregationCellExpanded(record: Record, key: Key): boolean | undefined;
    setAggregationCellExpanded(record: Record, key: Key, expanded: boolean): void;
    get isBodyExpanded(): boolean;
    setBodyExpanded(isBodyExpanded: boolean): void;
    isGroupExpanded(group: Group): boolean;
    setGroupExpanded(group: Group, isExpanded: boolean): void;
    isRowExpanded(record: Record): boolean;
    /**
     *
     * @param record 想修改的record
     * @param expanded 设置是否展开
     * @param disHandler 设置是否需要触发展开事件
     */
    setRowExpanded(record: Record, expanded: boolean, disHandler?: boolean): void;
    isRowPending(record: Record): boolean;
    setRowPending(record: Record, pending: boolean): void;
    isRowLoaded(record: Record): boolean;
    setRowLoaded(record: Record, loaded: boolean): void;
    isRowHover(record: Record): boolean;
    get canTreeLoadData(): boolean;
    get cellHighlightRenderer(): HighlightRenderer;
    setRowHover(record: Record, hover: boolean): void;
    expandAll(): void;
    collapseAll(): void;
    onTreeNodeLoad({ record }: {
        record: Record;
    }): Promise<any>;
    renderSelectionBox({ record }: {
        record: any;
    }): ReactNode;
    renderRowNumber({ record, dataSet }: {
        record: any;
        dataSet: any;
    }): ReactNode;
    renderDragBox({ record }: {
        record: any;
    }): JSX.Element;
    findColumnGroup(indexOrKeyOrName: number | string): ColumnGroup | undefined;
    setColumnWidth(columnGroup: ColumnGroup, width: number, saveToCustomization?: boolean): void;
    changeCustomizedColumnValue(column: ColumnProps, value: object, saveToCustomization?: boolean): void;
    saveCustomized(customized?: TableCustomized | null): Promise<void>;
    saveCustomizedDebounce: import("lodash").DebouncedFunc<(customized?: TableCustomized | null | undefined) => Promise<void>>;
    openCustomizationModal(context: any): void;
    loadCustomized(): Promise<void>;
    handleAllPageSelectionMenuClick({ key }: {
        key: any;
    }): void;
    renderAllPageSelectionMenu(): JSX.Element;
    getConfig<T extends ConfigKeys>(key: T): T extends keyof DefaultConfig ? DefaultConfig[T] : Config[T];
    getProPrefixCls(suffixCls: string, customizePrefixCls?: string): string;
    private multipleSelectionRenderer;
    private getRelationSize;
    startScroll(): void;
    stopScroll: import("lodash").DebouncedFunc<(() => void) & import("mobx").IAction>;
    batchRunner?: BatchRunner;
    batchSetRowHeight(key: Key, callback: Function): void;
    isRowInView(index: number): boolean;
    alignEditor(): void;
    blurEditor(): void;
}
