# FocusableElement

# Members

# container

Source code (opens new window)

focusableWrapper.container : HTMLElement

Parent for an focusable element.

# eventManager

Source code (opens new window)

focusableWrapper.eventManager : EventManager

Instance of EventManager.

# listenersCount

Source code (opens new window)

focusableWrapper.listenersCount : WeakSet

An object for tracking information about event listeners attached to the focusable element.

# mainElement

Source code (opens new window)

focusableWrapper.mainElement : HTMLElement

The main/operational focusable element.

# Methods

# focus

Source code (opens new window)

focusableWrapper.focus()

Set focus to the focusable element.

# getFocusableElement

Source code (opens new window)

focusableWrapper.getFocusableElement() ⇒ HTMLElement

Get currently set focusable element.

# setFocusableElement

Source code (opens new window)

focusableWrapper.setFocusableElement(element)

Switch to the main focusable element.

Param Type Description
element HTMLElement The DOM element.

# useSecondaryElement

Source code (opens new window)

focusableWrapper.useSecondaryElement()

Switch to the secondary focusable element. Used when no any main focusable element is provided.

Last Updated: Jul 8, 2021