Trait leptos_dom::ev::EventDescriptor

source ·
pub trait EventDescriptor: Clone {
    type EventType: FromWasmAbi;

    const BUBBLES: bool;

    // Required methods
    fn name(&self) -> Oco<'static, str>;
    fn event_delegation_key(&self) -> Oco<'static, str>;

    // Provided method
    fn options(&self) -> &Option<AddEventListenerOptions> { ... }
}
Expand description

A trait for converting types into web_sys events.

Required Associated Types§

Required Associated Constants§

source

const BUBBLES: bool

Indicates if this event bubbles. For example, click bubbles, but focus does not.

If this is true, then the event will be delegated globally, otherwise, event listeners will be directly attached to the element.

Required Methods§

source

fn name(&self) -> Oco<'static, str>

The name of the event, such as click or mouseover.

source

fn event_delegation_key(&self) -> Oco<'static, str>

The key used for event delegation.

Provided Methods§

source

fn options(&self) -> &Option<AddEventListenerOptions>

Return the options for this type. This is only used when you create a Custom event handler.

Object Safety§

This trait is not object safe.

Implementors§

source§

impl EventDescriptor for DOMContentLoaded

source§

impl EventDescriptor for abort

source§

impl EventDescriptor for afterprint

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for animationcancel

source§

impl EventDescriptor for animationend

source§

impl EventDescriptor for animationiteration

source§

impl EventDescriptor for animationstart

source§

impl EventDescriptor for auxclick

source§

impl EventDescriptor for beforeinput

source§

impl EventDescriptor for beforeprint

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for beforeunload

source§

impl EventDescriptor for blur

source§

impl EventDescriptor for canplay

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for canplaythrough

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for change

source§

impl EventDescriptor for click

source§

impl EventDescriptor for close

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for compositionend

source§

impl EventDescriptor for compositionstart

source§

impl EventDescriptor for compositionupdate

source§

impl EventDescriptor for contextmenu

source§

impl EventDescriptor for copy

source§

impl EventDescriptor for cuechange

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for cut

source§

impl EventDescriptor for dblclick

source§

impl EventDescriptor for devicemotion

source§

impl EventDescriptor for deviceorientation

source§

impl EventDescriptor for drag

source§

impl EventDescriptor for dragend

source§

impl EventDescriptor for dragenter

source§

impl EventDescriptor for dragleave

source§

impl EventDescriptor for dragover

source§

impl EventDescriptor for dragstart

source§

impl EventDescriptor for drop

source§

impl EventDescriptor for durationchange

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for emptied

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for ended

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for error

source§

impl EventDescriptor for focus

source§

impl EventDescriptor for focusin

source§

impl EventDescriptor for focusout

source§

impl EventDescriptor for formdata

source§

impl EventDescriptor for fullscreenchange

source§

impl EventDescriptor for fullscreenerror

source§

impl EventDescriptor for gamepadconnected

source§

impl EventDescriptor for gamepaddisconnected

source§

impl EventDescriptor for gotpointercapture

source§

impl EventDescriptor for hashchange

source§

impl EventDescriptor for input

source§

impl EventDescriptor for invalid

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for keydown

source§

impl EventDescriptor for keypress

source§

impl EventDescriptor for keyup

source§

impl EventDescriptor for languagechange

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for load

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for loadeddata

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for loadedmetadata

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for loadstart

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for lostpointercapture

source§

impl EventDescriptor for message

source§

impl EventDescriptor for messageerror

source§

impl EventDescriptor for mousedown

source§

impl EventDescriptor for mouseenter

source§

impl EventDescriptor for mouseleave

source§

impl EventDescriptor for mousemove

source§

impl EventDescriptor for mouseout

source§

impl EventDescriptor for mouseover

source§

impl EventDescriptor for mouseup

source§

impl EventDescriptor for offline

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for online

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for orientationchange

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for pagehide

source§

impl EventDescriptor for pageshow

source§

impl EventDescriptor for paste

source§

impl EventDescriptor for pause

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for play

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for playing

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for pointercancel

source§

impl EventDescriptor for pointerdown

source§

impl EventDescriptor for pointerenter

source§

impl EventDescriptor for pointerleave

source§

impl EventDescriptor for pointerlockchange

source§

impl EventDescriptor for pointerlockerror

source§

impl EventDescriptor for pointermove

source§

impl EventDescriptor for pointerout

source§

impl EventDescriptor for pointerover

source§

impl EventDescriptor for pointerup

source§

impl EventDescriptor for popstate

source§

impl EventDescriptor for progress

source§

impl EventDescriptor for ratechange

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for readystatechange

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for rejectionhandled

source§

impl EventDescriptor for reset

source§

impl EventDescriptor for resize

source§

impl EventDescriptor for scroll

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for scrollend

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for securitypolicyviolation

source§

impl EventDescriptor for seeked

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for seeking

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for select

source§

impl EventDescriptor for selectionchange

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for selectstart

source§

impl EventDescriptor for slotchange

source§

impl EventDescriptor for stalled

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for storage

source§

impl EventDescriptor for submit

source§

impl EventDescriptor for suspend

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for timeupdate

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for toggle

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for touchcancel

source§

impl EventDescriptor for touchend

source§

impl EventDescriptor for touchmove

source§

impl EventDescriptor for touchstart

source§

impl EventDescriptor for transitioncancel

source§

impl EventDescriptor for transitionend

source§

impl EventDescriptor for transitionrun

source§

impl EventDescriptor for transitionstart

source§

impl EventDescriptor for unhandledrejection

source§

impl EventDescriptor for unload

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for visibilitychange

source§

impl EventDescriptor for volumechange

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for waiting

§

type EventType = Event

source§

const BUBBLES: bool = false

source§

impl EventDescriptor for webkitanimationend

source§

impl EventDescriptor for webkitanimationiteration

source§

impl EventDescriptor for webkitanimationstart

source§

impl EventDescriptor for webkittransitionend

source§

impl EventDescriptor for wheel

source§

impl<E: FromWasmAbi> EventDescriptor for Custom<E>

§

type EventType = E

source§

const BUBBLES: bool = false

source§

impl<Ev: EventDescriptor> EventDescriptor for undelegated<Ev>