Skip to content

armgit / peach

Public Imported from GitHub
0

Peach: Local-first video metadata scraper and media manager.

1.0 KB
Raw Blame
import{i as e}from"./ui-element-tYNJ8-5H.js";const t=[`a[href]`,`button:not([disabled])`,`input:not([disabled])`,`select:not([disabled])`,`textarea:not([disabled])`,`audio[controls]`,`video[controls]`,`iframe`,`[contenteditable]:not([contenteditable="false"])`,`[tabindex]:not([tabindex="-1"])`].join(`,`);function n(e=document){let t=e.activeElement;for(;t?.shadowRoot?.activeElement;)t=t.shadowRoot.activeElement;return t}function r(e){let t=[],n=/* @__PURE__ */ new Set;return r(e),t;function r(e){for(let t of e.children)a(t)}function a(e){if(!n.has(e)){if(n.add(e),e instanceof HTMLElement&&i(e)&&t.push(e),e instanceof HTMLSlotElement){let t=e.assignedElements({flatten:!0});if(t.length>0)for(let e of t)a(e);else r(e);return}e.shadowRoot?r(e.shadowRoot):r(e)}}}function i(n){return!n.matches(t)||n.tabIndex<0||n.matches(`:disabled`)?!1:!e(n,e=>{if(e instanceof HTMLElement&&(e.hidden||e.hasAttribute(`inert`)||e.getAttribute(`aria-hidden`)===`true`))return!0},{composed:!0})}export{r as n,n as t};
//# sourceMappingURL=focus-Cg-_ddlb.js.map