undoRedoStack.d.ts 930 B

12345678910111213141516171819202122232425262728293031
  1. import { CellRange } from "../interfaces/iRangeController";
  2. export interface CellValueChange {
  3. rowPinned?: string;
  4. rowIndex: number;
  5. columnId: string;
  6. oldValue: any;
  7. newValue: any;
  8. }
  9. export interface LastFocusedCell {
  10. rowPinned?: string;
  11. rowIndex: number;
  12. columnId: string;
  13. }
  14. export declare class UndoRedoAction {
  15. cellValueChanges: CellValueChange[];
  16. constructor(cellValueChanges: CellValueChange[]);
  17. }
  18. export declare class FillUndoRedoAction extends UndoRedoAction {
  19. initialRange: CellRange;
  20. finalRange: CellRange;
  21. constructor(cellValueChanges: CellValueChange[], initialRange: CellRange, finalRange: CellRange);
  22. }
  23. export declare class UndoRedoStack {
  24. private static DEFAULT_STACK_SIZE;
  25. private readonly maxStackSize;
  26. private actionStack;
  27. constructor(maxStackSize?: number);
  28. pop(): UndoRedoAction;
  29. push(item: UndoRedoAction): void;
  30. clear(): void;
  31. }