ZoomTool
Table of contents
- children
 - id
 - initial
 - isLockable
 - _currentToolIdMask
 - _path
 - editor
 - enter
 - exit
 - handleEvent
 - info
 - onCancel
 - onComplete
 - onDoubleClick
 - onEnter
 - onExit
 - onInterrupt
 - onKeyDown
 - onKeyRepeat
 - onKeyUp
 - onLongPress
 - onMiddleClick
 - onPointerDown
 - onPointerMove
 - onPointerUp
 - onQuadrupleClick
 - onRightClick
 - onTick
 - onTripleClick
 - onWheel
 - parent
 - performanceTracker
 - shapeType
 - transition
 - type
 - Properties
 - Methods
 
Extends StateNode.
class ZoomTool extends StateNode {}
from 
StateNodeConstructs a new instance of the StateNode class
Parameters
Properties
static children: () => TLStateNodeConstructor[]
static id: string
static initial: string
static isLockable: boolean
from 
StateNodeeditor: Editor
from 
StateNodeenter: (info: any, from: string) => void
from 
StateNodeexit: (info: any, from: string) => void
from 
StateNodehandleEvent: (info: Exclude<TLEventInfo, TLPinchEventInfo>) => void
info: TLPointerEventInfo & {
  onInteractionEnd?: string | undefined
}
from 
StateNodeonCancel?: TLEventHandlers['onCancel']
from 
StateNodeonComplete?: TLEventHandlers['onComplete']
from 
StateNodeonDoubleClick?: TLEventHandlers['onDoubleClick']
onEnter: (
  info: TLPointerEventInfo & {
    onInteractionEnd: string
  }
) => void
onExit: () => void
onInterrupt: TLInterruptEvent
onKeyDown: TLKeyboardEvent | undefined
from 
StateNodeonKeyRepeat?: TLEventHandlers['onKeyRepeat']
onKeyUp: TLKeyboardEvent
from 
StateNodeonLongPress?: TLEventHandlers['onLongPress']
from 
StateNodeonMiddleClick?: TLEventHandlers['onMiddleClick']
from 
StateNodeonPointerDown?: TLEventHandlers['onPointerDown']
from 
StateNodeonPointerMove?: TLEventHandlers['onPointerMove']
from 
StateNodeonPointerUp?: TLEventHandlers['onPointerUp']
from 
StateNodeonQuadrupleClick?: TLEventHandlers['onQuadrupleClick']
from 
StateNodeonRightClick?: TLEventHandlers['onRightClick']
from 
StateNodeonTick?: TLEventHandlers['onTick']
from 
StateNodeonTripleClick?: TLEventHandlers['onTripleClick']
from 
StateNodeonWheel?: TLEventHandlers['onWheel']
from 
StateNodeparent: StateNode
from 
StateNodeperformanceTracker: PerformanceTracker
from 
StateNodeshapeType?: string
from 
StateNodeTransition to a new active child state node.
transition: (id: string, info?: any) => this
Example
parentState.transition('childStateA')
parentState.transition('childStateB', { myData: 4 })
Parameters
| Name | Description | 
|---|---|
  | The id of the child state node to transition to.  | 
  | Any data to pass to the   | 
from 
StateNodetype: 'branch' | 'leaf' | 'root'
Methods
from 
StateNodeThis node's current active child node, if any.
getCurrent(): StateNode | undefined
from 
StateNodegetCurrentToolIdMask(): string | undefined
from 
StateNodeWhether this node is active.
getIsActive(): boolean
from 
StateNodeThis node's path of active state nodes
getPath(): string
from 
StateNodesetCurrentToolIdMask(id: string | undefined): void
Parameters
| Name | Description | 
|---|---|
  |  | 
Returns
void

