Module

DOM.Classy.Event

Package
purescript-dom-classy
Repository
garyb/purescript-dom-classy

#type_ Source

type_ :: forall e. IsEvent e => e -> EventType

The event type.

#target Source

target :: forall e. IsEvent e => e -> Node

The element that was the source of the event.

#currentTarget Source

currentTarget :: forall e. IsEvent e => e -> Node

The element that the event listener was added to.

#eventPhase Source

eventPhase :: forall e. IsEvent e => Partial => e -> EventPhase

Indicates which phase of the event flow that is currently being processed for the event.

#eventPhaseIndex Source

eventPhaseIndex :: forall e. IsEvent e => e -> Int

The integer value for the current event phase.

#stopPropagation Source

stopPropagation :: forall eff e. IsEvent e => e -> Eff (dom :: DOM | eff) Unit

Prevents the event from bubbling up to futher event listeners. Other event listeners on the current target will still fire.

#stopImmediatePropagation Source

stopImmediatePropagation :: forall eff e. IsEvent e => e -> Eff (dom :: DOM | eff) Unit

Prevents all other listeners for the event from being called. This includes event listeners added to the current target after the current listener.

#bubbles Source

bubbles :: forall e. IsEvent e => e -> Boolean

Indicates whether the event will bubble up through the DOM or not.

#cancelable Source

cancelable :: forall e. IsEvent e => e -> Boolean

Indicates whether the event can be cancelled.

#preventDefault Source

preventDefault :: forall eff e. IsEvent e => e -> Eff (dom :: DOM | eff) Unit

Cancels the event if it can be cancelled.

#defaultPrevented Source

defaultPrevented :: forall e. IsEvent e => e -> Boolean

Indicates whether preventDefault was called on the event.

#timeStamp Source

timeStamp :: forall e. IsEvent e => e -> Number

The time in milliseconds between 01/01/1970 and when the event was dispatched.