(window.webpackJsonp=window.webpackJsonp||[]).push([[12],{855:function(e,t,o){"use strict";o.r(t),o.d(t,"register",(function(){return d})),o.d(t,"setFocusTrapTest",(function(){return l})),o.d(t,"unregister",(function(){return f}));var n=["text","search","url","password","tel"],r=["checkbox","radio"],i=void 0;function a(){for(var e=document.activeElement;e.shadowRoot;)e=e.shadowRoot.activeElement;return e}function c(e,t,o){var n={acceptNode:function(e){return e===t||e.shadowRoot||(o=e).matches("a[href], area[href], input, select, textarea, button, iframe, object, embed, [contenteditable], [tabindex], video[controls], audio[controls], summary")&&!o.disabled&&!/^-/.test(o.getAttribute("tabindex")||"")&&!o.hasAttribute("inert")&&(o.offsetWidth>0||o.offsetHeight>0)?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP;var o}},r="undefined"!=typeof ShadowRoot&&("polyfill"in ShadowRoot||!ShadowRoot.toString().includes("[native code]"))&&e instanceof ShadowRoot?function(e,t,o,n){var r=Array.prototype.slice.call(e.querySelectorAll("*")),i=r.indexOf(t);o?r=r.slice(i+1):(-1===i&&(i=r.length),(r=r.slice(0,i)).reverse());for(var a=0;a<r.length;a++){var c=r[a];if(c instanceof HTMLElement&&n.acceptNode(c)===NodeFilter.FILTER_ACCEPT)return c}}(e,t,o,n):function(e,t,o,n){var r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,n);return t&&(r.currentNode=t),o?r.nextNode():t?r.previousNode():r.lastChild()}(e,t,o,n);return r&&r.shadowRoot?c(r.shadowRoot,null,o):!r&&e.host?c(e.host.getRootNode(),e.host,o):r}function s(e,t){var o=a(),r="ArrowRight"===t;if(!function(e,t){var o,r,i,a=e.tagName,c="TEXTAREA"===a,s="INPUT"===a&&-1!==n.indexOf(e.getAttribute("type").toLowerCase()),u=e.hasAttribute("contenteditable");if(!c&&!s&&!u)return!1;if(u){var d=getSelection();o=d.anchorOffset,r=d.focusOffset,i=e.textContent.length}else o=e.selectionStart,r=e.selectionEnd,i=e.value.length;return!(!t&&o===r&&0===o||t&&o===r&&o===i)}(o,r)){var s=c(function(e){if(i)for(var t=e.parentElement;t;){if(i(t))return t;t=t.parentElement}}(o)||o.getRootNode(),o,r);s&&s!==o&&(s.focus(),e.preventDefault())}}function u(e){if(!(e.altKey||e.metaKey||e.ctrlKey)){var t=e.key;switch(t){case"ArrowLeft":case"ArrowRight":s(e,t);break;case"Enter":!function(e){var t=a();"INPUT"===t.tagName&&-1!==r.indexOf(t.getAttribute("type").toLowerCase())&&(t.click(),e.preventDefault())}(e)}}}function d(){addEventListener("keydown",u)}function f(){removeEventListener("keydown",u)}function l(e){i=e}}}]);
//# sourceMappingURL=arrow-key-navigation-a7f43c7fad3bd2e6a7ec.chunk.js.map