import _toConsumableArray from '@babel/runtime/helpers/toConsumableArray';
import 'core-js/modules/es.array.filter.js';
import 'core-js/modules/es.object.to-string.js';

var getKeyboardFoucusableElements = function getKeyboardFoucusableElements() {
  var element = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : document;
  return _toConsumableArray(element.querySelectorAll('a[href], button, input, textarea, select, details,[tabindex]:not([tabindex="-1"])')).filter(function (el) {
    return !el.hasAttribute('disabled') && !el.getAttribute('aria-hidden');
  });
};

export { getKeyboardFoucusableElements };
