import { default as Cell } from '../../core/cell/Cell';
import { default as Module } from '../../core/Module';
import { default as Row } from '../../core/row/Row';

type HistoryActionType = 'cellEdit' | 'rowAdd' | 'rowDelete' | 'rowMove';
type HistoryAction = {
    component: Cell | Row;
    data: {
        after?: boolean;
        data?: any;
        index?: Row | false;
        newValue?: any;
        oldValue?: any;
        pos?: boolean;
        posFrom?: number | false;
        posTo?: number | false;
        to?: Row;
    };
    type: HistoryActionType;
};
type Undoer = (this: History, action: HistoryAction) => void;
type Redoer = (this: History, action: HistoryAction) => void;
export default class History extends Module {
    static readonly moduleName = "history";
    static readonly moduleExtensions: {
        keybindings: {
            actions: Record<string, (this: import('../../../../../../atoms/src/components/table/table.ts').KeybindingsModule, e: KeyboardEvent) => void>;
            bindings: Record<string, string[]>;
        };
    };
    static readonly undoers: Record<string, Undoer>;
    static readonly redoers: Record<string, Redoer>;
    history: HistoryAction[];
    index: number;
    constructor(table: any);
    initialize(): void;
    rowMoved(from: Row, to: Row, after: boolean): void;
    rowAdded(row: Row, data: any, pos: boolean, index: Row | false): void;
    rowDeleted(row: Row): void;
    cellUpdated(cell: Cell): void;
    clear(): void;
    action(type: HistoryActionType, component: Cell | Row, data: HistoryAction['data']): void;
    getHistoryUndoSize(): number;
    getHistoryRedoSize(): number;
    clearComponentHistory(component: Cell | Row): void;
    undo(): boolean;
    redo(): boolean;
    _rebindRow(oldRow: Row, newRow: Row): void;
}
export {};
