src/utils/TabManager.js
/**
   * Checks if passed element can be tabbed through.
   * @param {HTMLAnchorElement | HTMLInputElement | ElementContentEditable} element
   * @return {boolean|*}
   */
Checks if passed element can be tabbed through.
Checks if passed element can be tabbed through .
isTabbableElement(element) {
    if (!element.offsetParent) return false;
    const tabIndex = parseFloat(element.getAttribute('tabindex'));
    if (Number.isNaN(tabIndex)) {
      return this.isFocusableElement(element);
    }
    return tabIndex >= 0;
  }
isTabbableElement ( element ) { if ( ! element . offsetParent ) return false ; const tabIndex = parseFloat ( element . getAttribute ( 'tabindex' ) ) ; if ( Number . isNaN ( tabIndex ) ) { return this . isFocusableElement ( element ) ; } return tabIndex >= 0 ; }
Checks if passed element can be tabbed through.
Checks if passed element can be tabbed through .
// if element is hidden, it cant be tabbed or focused