Copyright | (C) 2016-2025 David M. Johnson |
---|---|
License | BSD3-style (see the file LICENSE) |
Maintainer | David M. Johnson <code@dmj.io> |
Stability | experimental |
Portability | non-portable |
Safe Haskell | None |
Language | Haskell2010 |
Miso.Html.Event
Description
Synopsis
- onClick :: action -> Attribute action
- onClickWith :: (DOMRef -> action) -> Attribute action
- onClickWithOptions :: Options -> action -> Attribute action
- onDoubleClick :: action -> Attribute action
- onDoubleClickWith :: (DOMRef -> action) -> Attribute action
- onDoubleClickWithOptions :: Options -> action -> Attribute action
- onMouseDown :: action -> Attribute action
- onMouseUp :: action -> Attribute action
- onMouseEnter :: action -> Attribute action
- onMouseLeave :: action -> Attribute action
- onMouseOver :: action -> Attribute action
- onMouseOut :: action -> Attribute action
- onContextMenuWithOptions :: Options -> action -> Attribute action
- onKeyDown :: (KeyCode -> action) -> Attribute action
- onKeyDownWithInfo :: (KeyInfo -> action) -> Attribute action
- onKeyPress :: (KeyCode -> action) -> Attribute action
- onKeyUp :: (KeyCode -> action) -> Attribute action
- onInput :: (MisoString -> action) -> Attribute action
- onChange :: (MisoString -> action) -> Attribute action
- onChangeWith :: (MisoString -> DOMRef -> action) -> Attribute action
- onChecked :: (Checked -> action) -> Attribute action
- onSubmit :: action -> Attribute action
- onBlur :: action -> Attribute action
- onFocus :: action -> Attribute action
- onDrag :: action -> Attribute action
- onDragWithOptions :: Options -> action -> Attribute action
- onDragLeave :: action -> Attribute action
- onDragLeaveWithOptions :: Options -> action -> Attribute action
- onDragEnter :: action -> Attribute action
- onDragEnterWithOptions :: Options -> action -> Attribute action
- onDragEnd :: action -> Attribute action
- onDragEndWithOptions :: Options -> action -> Attribute action
- onDragStart :: action -> Attribute action
- onDragStartWithOptions :: Options -> action -> Attribute action
- onDragOver :: action -> Attribute action
- onDragOverWithOptions :: Options -> action -> Attribute action
- onDrop :: Options -> action -> Attribute action
- onDropWithOptions :: Options -> action -> Attribute action
- onSelect :: (MisoString -> action) -> Attribute action
- onPointerDown :: (PointerEvent -> action) -> Attribute action
- onPointerUp :: (PointerEvent -> action) -> Attribute action
- onPointerEnter :: (PointerEvent -> action) -> Attribute action
- onPointerLeave :: (PointerEvent -> action) -> Attribute action
- onPointerOver :: (PointerEvent -> action) -> Attribute action
- onPointerOut :: (PointerEvent -> action) -> Attribute action
- onPointerCancel :: (PointerEvent -> action) -> Attribute action
- onPointerMove :: (PointerEvent -> action) -> Attribute action
- onAbort :: action -> Attribute action
- onAbortWith :: (Media -> action) -> Attribute action
- onCanPlay :: action -> Attribute action
- onCanPlayWith :: (Media -> action) -> Attribute action
- onCanPlayThrough :: action -> Attribute action
- onCanPlayThroughWith :: (Media -> action) -> Attribute action
- onDurationChange :: action -> Attribute action
- onDurationChangeWith :: (Media -> action) -> Attribute action
- onEmptied :: action -> Attribute action
- onEmptiedWith :: (Media -> action) -> Attribute action
- onEnded :: action -> Attribute action
- onEndedWith :: (Media -> action) -> Attribute action
- onError :: action -> Attribute action
- onErrorWith :: (Media -> action) -> Attribute action
- onLoadedData :: action -> Attribute action
- onLoadedDataWith :: (Media -> action) -> Attribute action
- onLoadedMetadata :: action -> Attribute action
- onLoadedMetadataWith :: (Media -> action) -> Attribute action
- onLoadStart :: action -> Attribute action
- onLoadStartWith :: (Media -> action) -> Attribute action
- onPause :: action -> Attribute action
- onPauseWith :: (Media -> action) -> Attribute action
- onPlay :: action -> Attribute action
- onPlayWith :: (Media -> action) -> Attribute action
- onPlaying :: action -> Attribute action
- onPlayingWith :: (Media -> action) -> Attribute action
- onProgress :: action -> Attribute action
- onProgressWith :: (Media -> action) -> Attribute action
- onRateChange :: action -> Attribute action
- onRateChangeWith :: (Media -> action) -> Attribute action
- onSeeked :: action -> Attribute action
- onSeekedWith :: (Media -> action) -> Attribute action
- onSeeking :: action -> Attribute action
- onSeekingWith :: (Media -> action) -> Attribute action
- onStalled :: action -> Attribute action
- onStalledWith :: (Media -> action) -> Attribute action
- onSuspend :: action -> Attribute action
- onSuspendWith :: (Media -> action) -> Attribute action
- onTimeUpdate :: action -> Attribute action
- onTimeUpdateWith :: (Media -> action) -> Attribute action
- onVolumeChange :: action -> Attribute action
- onVolumeChangeWith :: (Media -> action) -> Attribute action
- onWaiting :: action -> Attribute action
- onWaitingWith :: (Media -> action) -> Attribute action
- onTouchStart :: action -> Attribute action
- onTouchStartWithOptions :: Options -> action -> Attribute action
- onTouchEnd :: action -> Attribute action
- onTouchEndWithOptions :: Options -> action -> Attribute action
- onTouchMove :: action -> Attribute action
- onTouchMoveWithOptions :: Options -> action -> Attribute action
- onTouchCancel :: action -> Attribute action
- onTouchCancelWithOptions :: Options -> action -> Attribute action
Mouse
onClickWith :: (DOMRef -> action) -> Attribute action Source #
https://developer.mozilla.org/en-US/docs/Web/Events/click
Like onClick
, but passes the DOM reference along (akin to getElementBydId
).
onClickWithOptions :: Options -> action -> Attribute action Source #
https://developer.mozilla.org/en-US/docs/Web/Events/click
Like onClick
, but passes the DOM reference along (akin to getElementBydId
).
onDoubleClick :: action -> Attribute action Source #
onDoubleClickWith :: (DOMRef -> action) -> Attribute action Source #
onDoubleClickWithOptions :: Options -> action -> Attribute action Source #
onMouseDown :: action -> Attribute action Source #
onMouseEnter :: action -> Attribute action Source #
onMouseLeave :: action -> Attribute action Source #
onMouseOver :: action -> Attribute action Source #
onMouseOut :: action -> Attribute action Source #
onContextMenuWithOptions :: Options -> action -> Attribute action Source #
https://developer.mozilla.org/en-US/docs/Web/Events/contextmenu
This can be used to disable right-click context menu from appearing
div_ [ onContextMenuWithOptions NoOp defaultOptions { preventDefault = False } ] [ ]
Since: 1.9.0.0
Keyboard
onKeyDownWithInfo :: (KeyInfo -> action) -> Attribute action Source #
onKeyPress :: (KeyCode -> action) -> Attribute action Source #
Form
onInput :: (MisoString -> action) -> Attribute action Source #
onChange :: (MisoString -> action) -> Attribute action Source #
onChangeWith :: (MisoString -> DOMRef -> action) -> Attribute action Source #
onSubmit :: action -> Attribute action Source #
https://developer.mozilla.org/en-US/docs/Web/Events/submit
Note: This has preventDefault
enabled by default.
Focus
Drag
onDragWithOptions :: Options -> action -> Attribute action Source #
onDragLeave :: action -> Attribute action Source #
onDragLeaveWithOptions :: Options -> action -> Attribute action Source #
onDragEnter :: action -> Attribute action Source #
onDragEnterWithOptions :: Options -> action -> Attribute action Source #
onDragEndWithOptions :: Options -> action -> Attribute action Source #
onDragStart :: action -> Attribute action Source #
onDragStartWithOptions :: Options -> action -> Attribute action Source #
onDragOver :: action -> Attribute action Source #
onDragOverWithOptions :: Options -> action -> Attribute action Source #
Drop
onDropWithOptions :: Options -> action -> Attribute action Source #
Select
onSelect :: (MisoString -> action) -> Attribute action Source #
Pointer
onPointerDown :: (PointerEvent -> action) -> Attribute action Source #
onPointerUp :: (PointerEvent -> action) -> Attribute action Source #
onPointerEnter :: (PointerEvent -> action) -> Attribute action Source #
onPointerLeave :: (PointerEvent -> action) -> Attribute action Source #
onPointerOver :: (PointerEvent -> action) -> Attribute action Source #
onPointerOut :: (PointerEvent -> action) -> Attribute action Source #
onPointerCancel :: (PointerEvent -> action) -> Attribute action Source #
onPointerMove :: (PointerEvent -> action) -> Attribute action Source #
Media
onAbortWith :: (Media -> action) -> Attribute action Source #
onCanPlayWith :: (Media -> action) -> Attribute action Source #
onCanPlayThrough :: action -> Attribute action Source #
onCanPlayThroughWith :: (Media -> action) -> Attribute action Source #
onDurationChange :: action -> Attribute action Source #
onDurationChangeWith :: (Media -> action) -> Attribute action Source #
onEmptiedWith :: (Media -> action) -> Attribute action Source #
onEndedWith :: (Media -> action) -> Attribute action Source #
onErrorWith :: (Media -> action) -> Attribute action Source #
onLoadedData :: action -> Attribute action Source #
onLoadedDataWith :: (Media -> action) -> Attribute action Source #
onLoadedMetadata :: action -> Attribute action Source #
onLoadedMetadataWith :: (Media -> action) -> Attribute action Source #
onLoadStart :: action -> Attribute action Source #
onLoadStartWith :: (Media -> action) -> Attribute action Source #
onPauseWith :: (Media -> action) -> Attribute action Source #
onPlayWith :: (Media -> action) -> Attribute action Source #
onPlayingWith :: (Media -> action) -> Attribute action Source #
onProgress :: action -> Attribute action Source #
onProgressWith :: (Media -> action) -> Attribute action Source #
onRateChange :: action -> Attribute action Source #
onRateChangeWith :: (Media -> action) -> Attribute action Source #
onSeekedWith :: (Media -> action) -> Attribute action Source #
onSeekingWith :: (Media -> action) -> Attribute action Source #
onStalledWith :: (Media -> action) -> Attribute action Source #
onSuspendWith :: (Media -> action) -> Attribute action Source #
onTimeUpdate :: action -> Attribute action Source #
onTimeUpdateWith :: (Media -> action) -> Attribute action Source #
onVolumeChange :: action -> Attribute action Source #
onVolumeChangeWith :: (Media -> action) -> Attribute action Source #
onWaitingWith :: (Media -> action) -> Attribute action Source #
Touch
onTouchStart :: action -> Attribute action Source #
onTouchStartWithOptions :: Options -> action -> Attribute action Source #
onTouchEnd :: action -> Attribute action Source #
onTouchEndWithOptions :: Options -> action -> Attribute action Source #
onTouchMove :: action -> Attribute action Source #
onTouchMoveWithOptions :: Options -> action -> Attribute action Source #
onTouchCancel :: action -> Attribute action Source #