,, , ,, , , , image/svg+xml , image/svg+xml , interact.js , image/svg+xml , ,, , ,

@interactjs / core/InteractEvent / InteractEvent

Class: InteractEvent<T, P>

core/InteractEvent.InteractEvent

Type parameters

NameType
Textends ActionName = never
Pextends EventPhase = EventPhase

Hierarchy

Table of contents

Properties

Methods

Properties

altKey

• altKey: boolean

Defined in

core/InteractEvent.ts:48


axes

• Optional axes: "x" | "y" | "xy"

Defined in

core/InteractEvent.ts:65


button

• button: number

Defined in

core/InteractEvent.ts:44


buttons

• buttons: number

Defined in

core/InteractEvent.ts:45


client

• client: Point

Defined in

core/InteractEvent.ts:51


clientX

• clientX: number

Defined in

core/InteractEvent.ts:25


clientX0

• clientX0: number

Defined in

core/InteractEvent.ts:59


clientY

• clientY: number

Defined in

core/InteractEvent.ts:26


clientY0

• clientY0: number

Defined in

core/InteractEvent.ts:60


ctrlKey

• ctrlKey: boolean

Defined in

core/InteractEvent.ts:46


currentTarget

• currentTarget: Element

Inherited from

BaseEvent.currentTarget

Defined in

core/InteractEvent.ts:40


delta

• delta: Point

Defined in

core/InteractEvent.ts:52


dragEnter

• Optional dragEnter: Element

Defined in

actions/drop/plugin.ts:137


dragLeave

• Optional dragLeave: Element

Defined in

actions/drop/plugin.ts:138


dropzone

• Optional dropzone: Interactable

Defined in

actions/drop/plugin.ts:136


dt

• dt: number

Defined in

core/InteractEvent.ts:57


duration

• duration: number

Defined in

core/InteractEvent.ts:58


dx

• dx: number

Defined in

core/InteractEvent.ts:28


dy

• dy: number

Defined in

core/InteractEvent.ts:29


immediatePropagationStopped

• immediatePropagationStopped: boolean = false

Inherited from

BaseEvent.immediatePropagationStopped

Defined in

core/BaseEvent.ts:13


interactable

• interactable: Interactable

Inherited from

BaseEvent.interactable

Defined in

core/BaseEvent.ts:9


interaction

• interaction: InteractionProxy<T>

Inherited from

BaseEvent.interaction

Defined in

core/BaseEvent.ts:40


metaKey

• metaKey: boolean

Defined in

core/InteractEvent.ts:49


modifiers

• Optional modifiers: { [key: string]: any; name: string }[]

Defined in

modifiers/base.ts:16


page

• page: Point

Defined in

core/InteractEvent.ts:50


pageX

• pageX: number

Defined in

core/InteractEvent.ts:22


pageY

• pageY: number

Defined in

core/InteractEvent.ts:23


propagationStopped

• propagationStopped: boolean = false

Inherited from

BaseEvent.propagationStopped

Defined in

core/BaseEvent.ts:14


rect

• rect: Required<Rect>

Defined in

core/InteractEvent.ts:53


relatedTarget

• relatedTarget: Element = null

Defined in

core/InteractEvent.ts:41


screenX

• Optional screenX: number

Defined in

core/InteractEvent.ts:42


screenY

• Optional screenY: number

Defined in

core/InteractEvent.ts:43


shiftKey

• shiftKey: boolean

Defined in

core/InteractEvent.ts:47


speed

• speed: number

Defined in

core/InteractEvent.ts:62


swipe

• swipe: Object

Type declaration

NameType
anglenumber
downboolean
leftboolean
rightboolean
speednumber
upboolean
velocity{ x: number = interaction.prevEvent.velocityX; y: number = interaction.prevEvent.velocityY }
velocity.xnumber
velocity.ynumber

Defined in

core/InteractEvent.ts:63


t0

• t0: number

Defined in

core/InteractEvent.ts:56


target

• target: Element

Inherited from

BaseEvent.target

Defined in

core/InteractEvent.ts:39


timeStamp

• timeStamp: number

Inherited from

BaseEvent.timeStamp

Defined in

core/BaseEvent.ts:12


type

• type: string

Inherited from

BaseEvent.type

Defined in

core/BaseEvent.ts:6


velocity

• velocity: Point

Defined in

core/InteractEvent.ts:61


velocityX

• velocityX: number

Defined in

core/InteractEvent.ts:31


velocityY

• velocityY: number

Defined in

core/InteractEvent.ts:32


x0

• x0: number

Defined in

core/InteractEvent.ts:54


y0

• y0: number

Defined in

core/InteractEvent.ts:55

Methods

getSwipe

â–¸ getSwipe(): Object

Returns

Object

NameType
anglenumber
downboolean
leftboolean
rightboolean
speednumber
upboolean
velocity{ x: number = interaction.prevEvent.velocityX; y: number = interaction.prevEvent.velocityY }
velocity.xnumber
velocity.ynumber

Defined in

core/InteractEvent.ts:145


preventDefault

â–¸ preventDefault(): void

Returns

void

Inherited from

BaseEvent.preventDefault

Defined in

core/InteractEvent.ts:179


stopImmediatePropagation

â–¸ stopImmediatePropagation(): void

Don’t call listeners on the remaining targets

Returns

void

Inherited from

BaseEvent.stopImmediatePropagation

Defined in

core/InteractEvent.ts:184


stopPropagation

â–¸ stopPropagation(): void

Don’t call any other listeners (even on the current target)

Returns

void

Inherited from

BaseEvent.stopPropagation

Defined in

core/InteractEvent.ts:191