import type { ColumnDef, DataType, ObjectSetTableConfig, SortDirection, TableCellIndex } from '../../types.js';
interface TableState<T extends DataType = DataType> {
    dispatch?: React.Dispatch<TableAction<T>>;
    defaultData: T[];
    columns: ColumnDef[];
    data: T[];
    allowRowSelection: boolean;
    showRowNumbers: boolean;
    selectedRowIndexes: number[];
    lastSelectedRowIndex: number | null;
    selectedCellIndex: TableCellIndex | null;
    isCellEditMode: boolean;
    sortState: {
        columnIndex: number;
        direction: SortDirection;
    } | null;
}
type TableAction<T extends DataType = DataType> = {
    type: 'SET_DISPATCH';
    payload: React.Dispatch<TableAction<T>>;
} | {
    type: 'SET_COLUMNS';
    payload: ColumnDef[];
} | {
    type: 'SET_DATA';
    payload: T[];
} | {
    type: 'UPDATE_COLUMN';
    payload: {
        index: number;
        column: Partial<ColumnDef>;
    };
} | {
    type: 'TOGGLE_SELECTED_ROW';
    payload: {
        index: number;
        clearOtherSelections?: boolean;
    };
} | {
    type: 'TOGGLE_SELECT_ALL_ROWS';
    payload: {
        totalRows?: number;
    };
} | {
    type: 'SELECT_ALL_ROWS';
    payload: {
        totalRows?: number;
    };
} | {
    type: 'SELECT_ROW_RANGE';
    payload: {
        from: number;
        to: number;
    };
} | {
    type: 'SELECT_CELL';
    payload: TableCellIndex | null;
} | {
    type: 'ENTER_CELL_EDIT_MODE';
    payload: TableCellIndex;
} | {
    type: 'SORT_COLUMN';
    payload: {
        columnIndex: number;
        direction: SortDirection | null;
        tableConfig: ObjectSetTableConfig<T>;
    };
};
declare const tableReducer: <T extends DataType>(state: TableState<T>, action: TableAction<T>) => TableState<T>;
export { tableReducer };
export type { TableAction, TableState };
//# sourceMappingURL=table-reducer.d.ts.map