Interface HTMLOptGroupAttributes

Attributes for a HTMLOptGroupElement.

interface HTMLOptGroupAttributes {
    "aria-activedescendant"?: null | string;
    "aria-atomic"?: null | Booleanish;
    "aria-autocomplete"?: null | "none" | "inline" | "list" | "both";
    "aria-busy"?: null | Booleanish;
    "aria-checked"?: null | boolean | "true" | "false" | "mixed";
    "aria-colcount"?: null | number;
    "aria-colindex"?: null | number;
    "aria-colspan"?: null | number;
    "aria-controls"?: null | string;
    "aria-current"?:
        | null
        | Booleanish
        | "time"
        | "page"
        | "step"
        | "location"
        | "date";
    "aria-describedby"?: null
    | string;
    "aria-details"?: null | string;
    "aria-disabled"?: null | Booleanish;
    "aria-dropeffect"?:
        | null
        | "link"
        | "none"
        | "copy"
        | "execute"
        | "move"
        | "popup";
    "aria-errormessage"?: null
    | string;
    "aria-expanded"?: null | Booleanish;
    "aria-flowto"?: null | string;
    "aria-grabbed"?: null | Booleanish;
    "aria-haspopup"?:
        | null
        | Booleanish
        | "dialog"
        | "menu"
        | "listbox"
        | "tree"
        | "grid";
    "aria-hidden"?: null
    | Booleanish;
    "aria-invalid"?: null | Booleanish | "grammar" | "spelling";
    "aria-keyshortcuts"?: null | string;
    "aria-label"?: null | string;
    "aria-labelledby"?: null | string;
    "aria-level"?: null | number;
    "aria-live"?: null | "off" | "assertive" | "polite";
    "aria-modal"?: null | Booleanish;
    "aria-multiline"?: null | Booleanish;
    "aria-multiselectable"?: null | Booleanish;
    "aria-orientation"?: null | "horizontal" | "vertical";
    "aria-owns"?: null | string;
    "aria-placeholder"?: null | string;
    "aria-posinset"?: null | number;
    "aria-pressed"?: null | boolean | "true" | "false" | "mixed";
    "aria-readonly"?: null | Booleanish;
    "aria-relevant"?:
        | null
        | "text"
        | "additions"
        | "additions removals"
        | "additions text"
        | "all"
        | "removals"
        | "removals additions"
        | "removals text"
        | "text additions"
        | "text removals";
    "aria-required"?: null
    | Booleanish;
    "aria-roledescription"?: null | string;
    "aria-rowcount"?: null | number;
    "aria-rowindex"?: null | number;
    "aria-rowspan"?: null | number;
    "aria-selected"?: null | Booleanish;
    "aria-setsize"?: null | number;
    "aria-sort"?: null | "none" | "ascending" | "descending" | "other";
    "aria-valuemax"?: null | number;
    "aria-valuemin"?: null | number;
    "aria-valuenow"?: null | number;
    "aria-valuetext"?: null | string;
    inputmode?:
        | null
        | "search"
        | "text"
        | "none"
        | "email"
        | "tel"
        | "url"
        | "numeric"
        | "decimal";
    is?: null
    | string;
    onabort?: null | (this: GlobalEventHandlers, ev: UIEvent) => any;
    onanimationcancel?:
        | null
        | (this: GlobalEventHandlers, ev: AnimationEvent) => any;
    onanimationend?:
        | null
        | (this: GlobalEventHandlers, ev: AnimationEvent) => any;
    onanimationiteration?:
        | null
        | (this: GlobalEventHandlers, ev: AnimationEvent) => any;
    onanimationstart?:
        | null
        | (this: GlobalEventHandlers, ev: AnimationEvent) => any;
    onauxclick?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any;
    onbeforeinput?: null | (this: GlobalEventHandlers, ev: InputEvent) => any;
    onbeforetoggle?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onblur?: null | (this: GlobalEventHandlers, ev: FocusEvent) => any;
    oncancel?: null | (this: GlobalEventHandlers, ev: Event) => any;
    oncanplay?: null | (this: GlobalEventHandlers, ev: Event) => any;
    oncanplaythrough?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onchange?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onclick?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any;
    onclose?: null | (this: GlobalEventHandlers, ev: Event) => any;
    oncontextlost?: null | (this: GlobalEventHandlers, ev: Event) => any;
    oncontextmenu?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any;
    oncontextrestored?: null | (this: GlobalEventHandlers, ev: Event) => any;
    oncopy?: null | (this: GlobalEventHandlers, ev: ClipboardEvent) => any;
    oncuechange?: null | (this: GlobalEventHandlers, ev: Event) => any;
    oncut?: null | (this: GlobalEventHandlers, ev: ClipboardEvent) => any;
    ondblclick?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any;
    ondrag?: null | (this: GlobalEventHandlers, ev: DragEvent) => any;
    ondragend?: null | (this: GlobalEventHandlers, ev: DragEvent) => any;
    ondragenter?: null | (this: GlobalEventHandlers, ev: DragEvent) => any;
    ondragleave?: null | (this: GlobalEventHandlers, ev: DragEvent) => any;
    ondragover?: null | (this: GlobalEventHandlers, ev: DragEvent) => any;
    ondragstart?: null | (this: GlobalEventHandlers, ev: DragEvent) => any;
    ondrop?: null | (this: GlobalEventHandlers, ev: DragEvent) => any;
    ondurationchange?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onemptied?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onended?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onerror?: OnErrorEventHandler;
    onfocus?: null | (this: GlobalEventHandlers, ev: FocusEvent) => any;
    onformdata?: null | (this: GlobalEventHandlers, ev: FormDataEvent) => any;
    ongotpointercapture?:
        | null
        | (this: GlobalEventHandlers, ev: PointerEvent) => any;
    oninput?: null | (this: GlobalEventHandlers, ev: Event) => any;
    oninvalid?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onkeydown?: null | (this: GlobalEventHandlers, ev: KeyboardEvent) => any;
    onkeypress?: null | (this: GlobalEventHandlers, ev: KeyboardEvent) => any;
    onkeyup?: null | (this: GlobalEventHandlers, ev: KeyboardEvent) => any;
    onload?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onloadeddata?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onloadedmetadata?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onloadstart?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onlostpointercapture?:
        | null
        | (this: GlobalEventHandlers, ev: PointerEvent) => any;
    onmousedown?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any;
    onmouseenter?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any;
    onmouseleave?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any;
    onmousemove?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any;
    onmouseout?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any;
    onmouseover?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any;
    onmouseup?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any;
    onpaste?: null | (this: GlobalEventHandlers, ev: ClipboardEvent) => any;
    onpause?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onplay?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onplaying?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onpointercancel?:
        | null
        | (this: GlobalEventHandlers, ev: PointerEvent) => any;
    onpointerdown?: null | (this: GlobalEventHandlers, ev: PointerEvent) => any;
    onpointerenter?:
        | null
        | (this: GlobalEventHandlers, ev: PointerEvent) => any;
    onpointerleave?:
        | null
        | (this: GlobalEventHandlers, ev: PointerEvent) => any;
    onpointermove?: null | (this: GlobalEventHandlers, ev: PointerEvent) => any;
    onpointerout?: null | (this: GlobalEventHandlers, ev: PointerEvent) => any;
    onpointerover?: null | (this: GlobalEventHandlers, ev: PointerEvent) => any;
    onpointerup?: null | (this: GlobalEventHandlers, ev: PointerEvent) => any;
    onprogress?: null | (this: GlobalEventHandlers, ev: ProgressEvent) => any;
    onratechange?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onreset?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onresize?: null | (this: GlobalEventHandlers, ev: UIEvent) => any;
    onscroll?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onscrollend?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onsecuritypolicyviolation?:
        | null
        | (this: GlobalEventHandlers, ev: SecurityPolicyViolationEvent) => any;
    onseeked?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onseeking?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onselect?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onselectionchange?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onselectstart?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onslotchange?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onstalled?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onsubmit?: null | (this: GlobalEventHandlers, ev: SubmitEvent) => any;
    onsuspend?: null | (this: GlobalEventHandlers, ev: Event) => any;
    ontimeupdate?: null | (this: GlobalEventHandlers, ev: Event) => any;
    ontoggle?: null | (this: GlobalEventHandlers, ev: Event) => any;
    ontouchcancel?: null | (this: GlobalEventHandlers, ev: TouchEvent) => any;
    ontouchend?: null | (this: GlobalEventHandlers, ev: TouchEvent) => any;
    ontouchmove?: null | (this: GlobalEventHandlers, ev: TouchEvent) => any;
    ontouchstart?: null | (this: GlobalEventHandlers, ev: TouchEvent) => any;
    ontransitioncancel?:
        | null
        | (this: GlobalEventHandlers, ev: TransitionEvent) => any;
    ontransitionend?:
        | null
        | (this: GlobalEventHandlers, ev: TransitionEvent) => any;
    ontransitionrun?:
        | null
        | (this: GlobalEventHandlers, ev: TransitionEvent) => any;
    ontransitionstart?:
        | null
        | (this: GlobalEventHandlers, ev: TransitionEvent) => any;
    onvolumechange?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onwaiting?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onwebkitanimationend?: null | (this: GlobalEventHandlers, ev: Event) => any;
    onwebkitanimationiteration?:
        | null
        | (this: GlobalEventHandlers, ev: Event) => any;
    onwebkitanimationstart?:
        | null
        | (this: GlobalEventHandlers, ev: Event) => any;
    onwebkittransitionend?:
        | null
        | (this: GlobalEventHandlers, ev: Event) => any;
    onwheel?: null | (this: GlobalEventHandlers, ev: WheelEvent) => any;
}

Hierarchy (View Summary)

Properties

aria-activedescendant? aria-atomic? aria-autocomplete? aria-busy? aria-checked? aria-colcount? aria-colindex? aria-colspan? aria-controls? aria-current? aria-describedby? aria-details? aria-disabled? aria-dropeffect? aria-errormessage? aria-expanded? aria-flowto? aria-grabbed? aria-haspopup? aria-hidden? aria-invalid? aria-keyshortcuts? aria-label? aria-labelledby? aria-level? aria-live? aria-modal? aria-multiline? aria-multiselectable? aria-orientation? aria-owns? aria-placeholder? aria-posinset? aria-pressed? aria-readonly? aria-relevant? aria-required? aria-roledescription? aria-rowcount? aria-rowindex? aria-rowspan? aria-selected? aria-setsize? aria-sort? aria-valuemax? aria-valuemin? aria-valuenow? aria-valuetext? inputmode? is? onabort? onanimationcancel? onanimationend? onanimationiteration? onanimationstart? onauxclick? onbeforeinput? onbeforetoggle? onblur? oncancel? oncanplay? oncanplaythrough? onchange? onclick? onclose? oncontextlost? oncontextmenu? oncontextrestored? oncopy? oncuechange? oncut? ondblclick? ondrag? ondragend? ondragenter? ondragleave? ondragover? ondragstart? ondrop? ondurationchange? onemptied? onended? onerror? onfocus? onformdata? ongotpointercapture? oninput? oninvalid? onkeydown? onkeypress? onkeyup? onload? onloadeddata? onloadedmetadata? onloadstart? onlostpointercapture? onmousedown? onmouseenter? onmouseleave? onmousemove? onmouseout? onmouseover? onmouseup? onpaste? onpause? onplay? onplaying? onpointercancel? onpointerdown? onpointerenter? onpointerleave? onpointermove? onpointerout? onpointerover? onpointerup? onprogress? onratechange? onreset? onresize? onscroll? onscrollend? onsecuritypolicyviolation? onseeked? onseeking? onselect? onselectionchange? onselectstart? onslotchange? onstalled? onsubmit? onsuspend? ontimeupdate? ontoggle? ontouchcancel? ontouchend? ontouchmove? ontouchstart? ontransitioncancel? ontransitionend? ontransitionrun? ontransitionstart? onvolumechange? onwaiting? onwebkitanimationend? onwebkitanimationiteration? onwebkitanimationstart? onwebkittransitionend? onwheel?

Properties

"aria-activedescendant"?: null | string

Identifies the currently active element when DOM focus is on a composite widget, textbox, group, or application.

"aria-atomic"?: null | Booleanish

Indicates whether assistive technologies will present all, or only parts of, the changed region based on the change notifications defined by the aria-relevant attribute.

"aria-autocomplete"?: null | "none" | "inline" | "list" | "both"

Indicates whether inputting text could trigger display of one or more predictions of the user's intended value for an input and specifies how predictions would be presented if they are made.

"aria-busy"?: null | Booleanish

Indicates an element is being modified and that assistive technologies MAY want to wait until the modifications are complete before exposing them to the user.

"aria-checked"?: null | boolean | "true" | "false" | "mixed"

Indicates the current "checked" state of checkboxes, radio buttons, and other widgets. See aria-pressed and aria-selected.

"aria-colcount"?: null | number

Defines the total number of columns in a table, grid, or treegrid. See aria-colindex.

"aria-colindex"?: null | number

Defines an element's column index or position with respect to the total number of columns within a table, grid, or treegrid.

  • aria-colcount
  • aria-colspan.
"aria-colspan"?: null | number

Defines the number of columns spanned by a cell or gridcell within a table, grid, or treegrid.

  • aria-colindex
  • aria-rowspan.
"aria-controls"?: null | string

Identifies the element (or elements) whose contents or presence are controlled by the current element. See aria-owns.

"aria-current"?:
    | null
    | Booleanish
    | "time"
    | "page"
    | "step"
    | "location"
    | "date"

Indicates the element that represents the current item within a container or set of related elements.

"aria-describedby"?: null | string

Identifies the element (or elements) that describes the object. See aria-labelledby.

"aria-details"?: null | string

Identifies the element that provides a detailed, extended description for the object. See aria-describedby.

"aria-disabled"?: null | Booleanish

Indicates that the element is perceivable but disabled, so it is not editable or otherwise operable. See aria-hidden and aria-readonly.

"aria-dropeffect"?:
    | null
    | "link"
    | "none"
    | "copy"
    | "execute"
    | "move"
    | "popup"

Indicates what functions can be performed when a dragged object is released on the drop target.

in ARIA 1.1

"aria-errormessage"?: null | string

Identifies the element that provides an error message for the object.

  • aria-invalid
  • aria-describedby.
"aria-expanded"?: null | Booleanish

Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.

"aria-flowto"?: null | string

Identifies the next element (or elements) in an alternate reading order of content which, at the user's discretion, allows assistive technology to override the general default of reading in document source order.

"aria-grabbed"?: null | Booleanish

Indicates an element's "grabbed" state in a drag-and-drop operation.

in ARIA 1.1

"aria-haspopup"?:
    | null
    | Booleanish
    | "dialog"
    | "menu"
    | "listbox"
    | "tree"
    | "grid"

Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.

"aria-hidden"?: null | Booleanish

Indicates whether the element is exposed to an accessibility API. See aria-disabled.

"aria-invalid"?: null | Booleanish | "grammar" | "spelling"

Indicates the entered value does not conform to the format expected by the application. See aria-errormessage.

"aria-keyshortcuts"?: null | string

Indicates keyboard shortcuts that an author has implemented to activate or give focus to an element.

"aria-label"?: null | string

Defines a string value that labels the current element. See aria-labelledby.

"aria-labelledby"?: null | string

Identifies the element (or elements) that labels the current element. See aria-describedby.

"aria-level"?: null | number

Defines the hierarchical level of an element within a structure.

"aria-live"?: null | "off" | "assertive" | "polite"

Indicates that an element will be updated, and describes the types of updates the user agents, assistive technologies, and user can expect from the live region.

"aria-modal"?: null | Booleanish

Indicates whether an element is modal when displayed.

"aria-multiline"?: null | Booleanish

Indicates whether a text box accepts multiple lines of input or only a single line.

"aria-multiselectable"?: null | Booleanish

Indicates that the user may select more than one item from the current selectable descendants.

"aria-orientation"?: null | "horizontal" | "vertical"

Indicates whether the element's orientation is horizontal, vertical, or unknown/ambiguous.

"aria-owns"?: null | string

Identifies an element (or elements) in order to define a visual, functional, or contextual parent/child relationship between DOM elements where the DOM hierarchy cannot be used to represent the relationship. See aria-controls.

"aria-placeholder"?: null | string

Defines a short hint (a word or short phrase) intended to aid the user with data entry when the control has no value. A hint could be a sample value or a brief description of the expected format.

"aria-posinset"?: null | number

Defines an element's number or position in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM. See aria-setsize.

"aria-pressed"?: null | boolean | "true" | "false" | "mixed"

Indicates the current "pressed" state of toggle buttons. See aria-checked and aria-selected.

"aria-readonly"?: null | Booleanish

Indicates that the element is not editable, but is otherwise operable. See aria-disabled.

"aria-relevant"?:
    | null
    | "text"
    | "additions"
    | "additions removals"
    | "additions text"
    | "all"
    | "removals"
    | "removals additions"
    | "removals text"
    | "text additions"
    | "text removals"

Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified. See aria-atomic.

"aria-required"?: null | Booleanish

Indicates that user input is required on the element before a form may be submitted.

"aria-roledescription"?: null | string

Defines a human-readable, author-localized description for the role of an element.

"aria-rowcount"?: null | number

Defines the total number of rows in a table, grid, or treegrid. See aria-rowindex.

"aria-rowindex"?: null | number

Defines an element's row index or position with respect to the total number of rows within a table, grid, or treegrid. See aria-rowcount and aria-rowspan.

"aria-rowspan"?: null | number

Defines the number of rows spanned by a cell or gridcell within a table, grid, or treegrid. See aria-rowindex and aria-colspan.

"aria-selected"?: null | Booleanish

Indicates the current "selected" state of various widgets. See aria-checked and aria-pressed.

"aria-setsize"?: null | number

Defines the number of items in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM. See aria-posinset.

"aria-sort"?: null | "none" | "ascending" | "descending" | "other"

Indicates if items in a table or grid are sorted in ascending or descending order.

"aria-valuemax"?: null | number

Defines the maximum allowed value for a range widget.

"aria-valuemin"?: null | number

Defines the minimum allowed value for a range widget.

"aria-valuenow"?: null | number

Defines the current value for a range widget. See aria-valuetext.

"aria-valuetext"?: null | string

Defines the human-readable text alternative of aria-valuenow for a range widget.

inputmode?:
    | null
    | "search"
    | "text"
    | "none"
    | "email"
    | "tel"
    | "url"
    | "numeric"
    | "decimal"

Hints at the type of data that might be entered by the user while editing the element or its contents. See the specification for inputmode.

is?: null | string

Specify that a standard HTML element should behave like a defined custom built-in element. See the specification for is.

onabort?: null | (this: GlobalEventHandlers, ev: UIEvent) => any

Fires when the user aborts the download.

The event.

MDN Reference

onanimationcancel?:
    | null
    | (this: GlobalEventHandlers, ev: AnimationEvent) => any
onanimationend?: null | (this: GlobalEventHandlers, ev: AnimationEvent) => any
onanimationiteration?:
    | null
    | (this: GlobalEventHandlers, ev: AnimationEvent) => any
onanimationstart?: null | (this: GlobalEventHandlers, ev: AnimationEvent) => any
onauxclick?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any
onbeforeinput?: null | (this: GlobalEventHandlers, ev: InputEvent) => any
onbeforetoggle?: null | (this: GlobalEventHandlers, ev: Event) => any
onblur?: null | (this: GlobalEventHandlers, ev: FocusEvent) => any

Fires when the object loses the input focus.

The focus event.

MDN Reference

oncancel?: null | (this: GlobalEventHandlers, ev: Event) => any
oncanplay?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when playback is possible, but would require further buffering.

The event.

MDN Reference

oncanplaythrough?: null | (this: GlobalEventHandlers, ev: Event) => any
onchange?: null | (this: GlobalEventHandlers, ev: Event) => any

Fires when the contents of the object or selection have changed.

The event.

MDN Reference

onclick?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any

Fires when the user clicks the left mouse button on the object

The mouse event.

MDN Reference

onclose?: null | (this: GlobalEventHandlers, ev: Event) => any
oncontextlost?: null | (this: GlobalEventHandlers, ev: Event) => any
oncontextmenu?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any

Fires when the user clicks the right mouse button in the client area, opening the context menu.

The mouse event.

MDN Reference

oncontextrestored?: null | (this: GlobalEventHandlers, ev: Event) => any
oncopy?: null | (this: GlobalEventHandlers, ev: ClipboardEvent) => any
oncuechange?: null | (this: GlobalEventHandlers, ev: Event) => any
oncut?: null | (this: GlobalEventHandlers, ev: ClipboardEvent) => any
ondblclick?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any

Fires when the user double-clicks the object.

The mouse event.

MDN Reference

ondrag?: null | (this: GlobalEventHandlers, ev: DragEvent) => any

Fires on the source object continuously during a drag operation.

The event.

MDN Reference

ondragend?: null | (this: GlobalEventHandlers, ev: DragEvent) => any

Fires on the source object when the user releases the mouse at the close of a drag operation.

The event.

MDN Reference

ondragenter?: null | (this: GlobalEventHandlers, ev: DragEvent) => any

Fires on the target element when the user drags the object to a valid drop target.

The drag event.

MDN Reference

ondragleave?: null | (this: GlobalEventHandlers, ev: DragEvent) => any

Fires on the target object when the user moves the mouse out of a valid drop target during a drag operation.

The drag event.

MDN Reference

ondragover?: null | (this: GlobalEventHandlers, ev: DragEvent) => any

Fires on the target element continuously while the user drags the object over a valid drop target.

The event.

MDN Reference

ondragstart?: null | (this: GlobalEventHandlers, ev: DragEvent) => any

Fires on the source object when the user starts to drag a text selection or selected object.

The event.

MDN Reference

ondrop?: null | (this: GlobalEventHandlers, ev: DragEvent) => any
ondurationchange?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when the duration attribute is updated.

The event.

MDN Reference

onemptied?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when the media element is reset to its initial state.

The event.

MDN Reference

onended?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when the end of playback is reached.

The event

MDN Reference

onerror?: OnErrorEventHandler

Fires when an error occurs during object loading.

The event.

MDN Reference

onfocus?: null | (this: GlobalEventHandlers, ev: FocusEvent) => any

Fires when the object receives focus.

The event.

MDN Reference

onformdata?: null | (this: GlobalEventHandlers, ev: FormDataEvent) => any
ongotpointercapture?:
    | null
    | (this: GlobalEventHandlers, ev: PointerEvent) => any
oninput?: null | (this: GlobalEventHandlers, ev: Event) => any
oninvalid?: null | (this: GlobalEventHandlers, ev: Event) => any
onkeydown?: null | (this: GlobalEventHandlers, ev: KeyboardEvent) => any

Fires when the user presses a key.

The keyboard event

MDN Reference

onkeypress?: null | (this: GlobalEventHandlers, ev: KeyboardEvent) => any

Fires when the user presses an alphanumeric key.

The event.

MDN Reference

onkeyup?: null | (this: GlobalEventHandlers, ev: KeyboardEvent) => any

Fires when the user releases a key.

The keyboard event

MDN Reference

onload?: null | (this: GlobalEventHandlers, ev: Event) => any

Fires immediately after the browser loads the object.

The event.

MDN Reference

onloadeddata?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when media data is loaded at the current playback position.

The event.

MDN Reference

onloadedmetadata?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when the duration and dimensions of the media have been determined.

The event.

MDN Reference

onloadstart?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when Internet Explorer begins looking for media data.

The event.

MDN Reference

onlostpointercapture?:
    | null
    | (this: GlobalEventHandlers, ev: PointerEvent) => any
onmousedown?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any

Fires when the user clicks the object with either mouse button.

The mouse event.

MDN Reference

onmouseenter?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any
onmouseleave?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any
onmousemove?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any

Fires when the user moves the mouse over the object.

The mouse event.

MDN Reference

onmouseout?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any

Fires when the user moves the mouse pointer outside the boundaries of the object.

The mouse event.

MDN Reference

onmouseover?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any

Fires when the user moves the mouse pointer into the object.

The mouse event.

MDN Reference

onmouseup?: null | (this: GlobalEventHandlers, ev: MouseEvent) => any

Fires when the user releases a mouse button while the mouse is over the object.

The mouse event.

MDN Reference

onpaste?: null | (this: GlobalEventHandlers, ev: ClipboardEvent) => any
onpause?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when playback is paused.

The event.

MDN Reference

onplay?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when the play method is requested.

The event.

MDN Reference

onplaying?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when the audio or video has started playing.

The event.

MDN Reference

onpointercancel?: null | (this: GlobalEventHandlers, ev: PointerEvent) => any
onpointerdown?: null | (this: GlobalEventHandlers, ev: PointerEvent) => any
onpointerenter?: null | (this: GlobalEventHandlers, ev: PointerEvent) => any
onpointerleave?: null | (this: GlobalEventHandlers, ev: PointerEvent) => any
onpointermove?: null | (this: GlobalEventHandlers, ev: PointerEvent) => any
onpointerout?: null | (this: GlobalEventHandlers, ev: PointerEvent) => any
onpointerover?: null | (this: GlobalEventHandlers, ev: PointerEvent) => any
onpointerup?: null | (this: GlobalEventHandlers, ev: PointerEvent) => any
onprogress?: null | (this: GlobalEventHandlers, ev: ProgressEvent) => any

Occurs to indicate progress while downloading media data.

The event.

MDN Reference

onratechange?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when the playback rate is increased or decreased.

The event.

MDN Reference

onreset?: null | (this: GlobalEventHandlers, ev: Event) => any

Fires when the user resets a form.

The event.

MDN Reference

onresize?: null | (this: GlobalEventHandlers, ev: UIEvent) => any
onscroll?: null | (this: GlobalEventHandlers, ev: Event) => any

Fires when the user repositions the scroll box in the scroll bar on the object.

The event.

MDN Reference

onscrollend?: null | (this: GlobalEventHandlers, ev: Event) => any
onsecuritypolicyviolation?:
    | null
    | (this: GlobalEventHandlers, ev: SecurityPolicyViolationEvent) => any
onseeked?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when the seek operation ends.

The event.

MDN Reference

onseeking?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when the current playback position is moved.

The event.

MDN Reference

onselect?: null | (this: GlobalEventHandlers, ev: Event) => any

Fires when the current selection changes.

The event.

MDN Reference

onselectionchange?: null | (this: GlobalEventHandlers, ev: Event) => any
onselectstart?: null | (this: GlobalEventHandlers, ev: Event) => any
onslotchange?: null | (this: GlobalEventHandlers, ev: Event) => any
onstalled?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when the download has stopped.

The event.

MDN Reference

onsubmit?: null | (this: GlobalEventHandlers, ev: SubmitEvent) => any
onsuspend?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs if the load operation has been intentionally halted.

The event.

MDN Reference

ontimeupdate?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs to indicate the current playback position.

The event.

MDN Reference

ontoggle?: null | (this: GlobalEventHandlers, ev: Event) => any
ontouchcancel?: null | (this: GlobalEventHandlers, ev: TouchEvent) => any
ontouchend?: null | (this: GlobalEventHandlers, ev: TouchEvent) => any
ontouchmove?: null | (this: GlobalEventHandlers, ev: TouchEvent) => any
ontouchstart?: null | (this: GlobalEventHandlers, ev: TouchEvent) => any
ontransitioncancel?:
    | null
    | (this: GlobalEventHandlers, ev: TransitionEvent) => any
ontransitionend?: null | (this: GlobalEventHandlers, ev: TransitionEvent) => any
ontransitionrun?: null | (this: GlobalEventHandlers, ev: TransitionEvent) => any
ontransitionstart?:
    | null
    | (this: GlobalEventHandlers, ev: TransitionEvent) => any
onvolumechange?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when the volume is changed, or playback is muted or unmuted.

The event.

MDN Reference

onwaiting?: null | (this: GlobalEventHandlers, ev: Event) => any

Occurs when playback stops because the next frame of a video resource is not available.

The event.

MDN Reference

onwebkitanimationend?: null | (this: GlobalEventHandlers, ev: Event) => any

This is a legacy alias of onanimationend.

MDN Reference

onwebkitanimationiteration?:
    | null
    | (this: GlobalEventHandlers, ev: Event) => any

This is a legacy alias of onanimationiteration.

MDN Reference

onwebkitanimationstart?: null | (this: GlobalEventHandlers, ev: Event) => any

This is a legacy alias of onanimationstart.

MDN Reference

onwebkittransitionend?: null | (this: GlobalEventHandlers, ev: Event) => any

This is a legacy alias of ontransitionend.

MDN Reference

onwheel?: null | (this: GlobalEventHandlers, ev: WheelEvent) => any