Module

Web.Event.Class.EventTargetOp

Package
purescript-web-chain
Repository
david-sledge/purescript-web-chain

Type classes of convenience.

#EventOptions Source

type EventOptions = { bubbles :: Boolean, cancelable :: Boolean, composed :: Boolean }

#allOff Source

allOff :: forall m t. Bind m => MonadEffect m => EventTargetOp t => t -> m t

Removes all event handler functions from an event target. The target is returned.

#allOffM Source

allOffM :: forall m t. Bind m => MonadEffect m => EventTargetOp t => m t -> m t

Removes all event handler functions from an event target. The target is returned.

#EventTargetOp Source

class EventTargetOp et  where

Members

Instances

#getAllListeners Source

getAllListeners :: forall a m t. MonadEffect m => EventTargetOp t => t -> m (Array (ListenerDetails a))

#off Source

off :: forall a m t. MonadEffect m => EventTargetOp t => String -> (Event -> Effect a) -> t -> m t

Removes an event handler function from an event target. The target is returned.

#offM Source

offM :: forall a m t. MonadEffect m => EventTargetOp t => String -> (Event -> Effect a) -> m t -> m t

Removes an event handler function from an event target. The target is returned.

#offOptions Source

offOptions :: forall a m t. MonadEffect m => EventTargetOp t => String -> (Event -> Effect a) -> ListenerOptions -> t -> m t

Removes an event handler function from an event target. The target is returned.

#offOptionsM Source

offOptionsM :: forall a m t. MonadEffect m => EventTargetOp t => String -> (Event -> Effect a) -> ListenerOptions -> m t -> m t

Removes an event handler function from an event target. The target is returned.

#on Source

on :: forall a m t. MonadEffect m => EventTargetOp t => String -> (Event -> Effect a) -> t -> m t

Attach an event handler function to the event target. The target is returned.

#onM Source

onM :: forall a m t. MonadEffect m => EventTargetOp t => String -> (Event -> Effect a) -> m t -> m t

Attach an event handler function to the event target. The target is returned.

#onOptions Source

onOptions :: forall a m t. MonadEffect m => EventTargetOp t => String -> (Event -> Effect a) -> ListenerOptions -> t -> m t

Attach an event handler function to the event target. The target is returned.

#onOptionsM Source

onOptionsM :: forall a m t. MonadEffect m => EventTargetOp t => String -> (Event -> Effect a) -> ListenerOptions -> m t -> m t

#registerListener Source

registerListener :: forall a m t. MonadEffect m => EventTargetOp t => String -> (Event -> Effect a) -> ListenerOptions -> t -> m Unit

Attach an event handler function to the event target. The target is returned.

#trigger Source

trigger :: forall t m. EventTargetOp t => MonadEffect m => String -> t -> m t

Triggers the event handlers tied to the event type to the event target. The target is returned.

#triggerM Source

triggerM :: forall t m. EventTargetOp t => MonadEffect m => String -> m t -> m t

Triggers the event handlers tied to the event type to the event target. The target is returned.

#triggerOptions Source

triggerOptions :: forall t m. EventTargetOp t => MonadEffect m => String -> EventOptions -> t -> m t

Triggers the event handlers tied to the event type to the event target. The target is returned.

#triggerOptionsM Source

triggerOptionsM :: forall t m. EventTargetOp t => MonadEffect m => String -> EventOptions -> m t -> m t

Triggers the event handlers tied to the event type to the event target. The target is returned.

#typeOff Source

typeOff :: forall t m. MonadEffect m => EventTargetOp t => String -> t -> m t

Removes all event handler functions of the given type from an event target. The target is returned.

#typeOffM Source

typeOffM :: forall m t. Bind m => MonadEffect m => EventTargetOp t => String -> m t -> m t

Removes all event handler functions of the given type from an event target. The target is returned.

#typeOffOptions Source

typeOffOptions :: forall t m. MonadEffect m => EventTargetOp t => String -> ListenerOptions -> t -> m t

Removes all event handler functions of the given type from an event target. The target is returned.

#typeOffOptionsM Source

typeOffOptionsM :: forall t m. MonadEffect m => EventTargetOp t => String -> ListenerOptions -> m t -> m t

Removes all event handler functions of the given type from an event target. The target is returned.

#unregisterListener Source

unregisterListener :: forall a m t. MonadEffect m => EventTargetOp t => ListenerDetails a -> t -> m Boolean