Interface ElementInternals

    interface ElementInternals {
        ariaAtomic: string;
        ariaAutoComplete: string;
        ariaBrailleLabel: string;
        ariaBrailleRoleDescription: string;
        ariaBusy: string;
        ariaChecked: string;
        ariaColCount: string;
        ariaColIndex: string;
        ariaColSpan: string;
        ariaCurrent: string;
        ariaDescription: string;
        ariaDisabled: string;
        ariaExpanded: string;
        ariaHasPopup: string;
        ariaHidden: string;
        ariaInvalid: string;
        ariaKeyShortcuts: string;
        ariaLabel: string;
        ariaLevel: string;
        ariaLive: string;
        ariaModal: string;
        ariaMultiLine: string;
        ariaMultiSelectable: string;
        ariaOrientation: string;
        ariaPlaceholder: string;
        ariaPosInSet: string;
        ariaPressed: string;
        ariaReadOnly: string;
        ariaRequired: string;
        ariaRoleDescription: string;
        ariaRowCount: string;
        ariaRowIndex: string;
        ariaRowSpan: string;
        ariaSelected: string;
        ariaSetSize: string;
        ariaSort: string;
        ariaValueMax: string;
        ariaValueMin: string;
        ariaValueNow: string;
        ariaValueText: string;
        form: HTMLFormElement;
        labels: NodeList;
        role: string;
        shadowRoot: ShadowRoot;
        states: CustomStateSet;
        validationMessage: string;
        validity: ValidityState;
        willValidate: boolean;
        checkValidity(): boolean;
        reportValidity(): boolean;
        setFormValue(value: string | FormData | File, state?: string | FormData | File): void;
        setValidity(flags?: ValidityStateFlags, message?: string, anchor?: HTMLElement): void;
    }
    Hierarchy

    Properties

    ariaAtomic: string
    ariaAutoComplete: string
    ariaBrailleLabel: string
    ariaBrailleRoleDescription: string
    ariaBusy: string
    ariaChecked: string
    ariaColCount: string
    ariaColIndex: string
    ariaColSpan: string
    ariaCurrent: string
    ariaDescription: string
    ariaDisabled: string
    ariaExpanded: string
    ariaHasPopup: string
    ariaHidden: string
    ariaInvalid: string
    ariaKeyShortcuts: string
    ariaLabel: string
    ariaLevel: string
    ariaLive: string
    ariaModal: string
    ariaMultiLine: string
    ariaMultiSelectable: string
    ariaOrientation: string
    ariaPlaceholder: string
    ariaPosInSet: string
    ariaPressed: string
    ariaReadOnly: string
    ariaRequired: string
    ariaRoleDescription: string
    ariaRowCount: string
    ariaRowIndex: string
    ariaRowSpan: string
    ariaSelected: string
    ariaSetSize: string
    ariaSort: string
    ariaValueMax: string
    ariaValueMin: string
    ariaValueNow: string
    ariaValueText: string

    Returns the form owner of internals's target element.

    MDN Reference

    labels: NodeList

    Returns a NodeList of all the label elements that internals's target element is associated with.

    MDN Reference

    role: string
    shadowRoot: ShadowRoot

    Returns the ShadowRoot for internals's target element, if the target element is a shadow host, or null otherwise.

    MDN Reference

    validationMessage: string

    Returns the error message that would be shown to the user if internals's target element was to be checked for validity.

    MDN Reference

    validity: ValidityState

    Returns the ValidityState object for internals's target element.

    MDN Reference

    willValidate: boolean

    Returns true if internals's target element will be validated when the form is submitted; false otherwise.

    MDN Reference

    Methods

    • Returns true if internals's target element has no validity problems; false otherwise. Fires an invalid event at the element in the latter case.

      MDN Reference

      Returns boolean

    • Returns true if internals's target element has no validity problems; otherwise, returns false, fires an invalid event at the element, and (if the event isn't canceled) reports the problem to the user.

      MDN Reference

      Returns boolean

    • Sets both the state and submission value of internals's target element to value.

      If value is null, the element won't participate in form submission.

      MDN Reference

      Parameters

      Returns void

    • Marks internals's target element as suffering from the constraints indicated by the flags argument, and sets the element's validation message to message. If anchor is specified, the user agent might use it to indicate problems with the constraints of internals's target element when the form owner is validated interactively or reportValidity() is called.

      MDN Reference

      Parameters

      Returns void