@limetech/lime-elements
Version:
1 lines • 559 B
JavaScript
import{a as t}from"./p-ZcW3uvZL.js";function r(r,n){return function(t,r,n){for(var e=-1,a=t.length,i=r.length,o={};++e<a;)n(o,t[e],e<i?r[e]:void 0);return o}(r||[],n||[],t)}const n='button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])',e=t=>{var r,e;if(!t||!0===(e=t).disabled||e.hasAttribute("disabled")||"true"===e.getAttribute("aria-disabled"))return!1;const a=null===(r=t.shadowRoot)||void 0===r?void 0:r.querySelector(n);if(a)return a.focus(),!0;const i=t.querySelector(n);return i?(i.focus(),!0):(t.focus(),!0)};export{e as f,r as z}