Options
All
  • Public
  • Public/Protected
  • All
Menu

Class TransactionHandler

Hierarchy

  • TransactionHandler

Index

Constructors

constructor

Properties

active

active: boolean = false

handler

handler: Handler

redo

redo: DebouncedFunc<(Anonymous function)> = throttle(() => {const redo = this.redos.pop();if (!redo) {return;}this.undos.push({type: 'undo',json: JSON.stringify(this.state),});this.replay(redo);}, 100)

Redo transaction

redos

state

state: FabricObject[] = []

undo

undo: DebouncedFunc<(Anonymous function)> = throttle(() => {const undo = this.undos.pop();if (!undo) {return;}this.redos.push({type: 'redo',json: JSON.stringify(this.state),});this.replay(undo);}, 100)

Undo transaction

undos

Methods

initialize

  • initialize(): void

replay

save

  • save(type: TransactionType, canvasJSON?: any, _isWorkarea?: boolean): void

Generated using TypeDoc