/*!
 * Custom elements for Nanopore-Digital Web applications
 */
let e;function o(o){if(!o)return;if(e)return void o.adoptedStyleSheets.push(e);const t=document.styleSheets;let n=null,c=null;const l=[];for(n of t){if(!(n instanceof CSSStyleSheet))continue;let e;try{if(e=n?.cssRules,!e)continue}catch(e){console.warn("Unable to access stylesheet:",n,e);continue}for(c of e)c instanceof CSSLayerBlockRule&&c.cssText.indexOf(".nano-toast-stack")>-1&&l.push(n),c instanceof CSSLayerBlockRule&&c.cssText.indexOf(".nano-theme")>-1&&l.push(n)}if(l.length){const t=new CSSStyleSheet;for(const e of l)for(const o of e.cssRules)t.insertRule(o.cssText);return e=t,void o.adoptedStyleSheets.push(t)}console.warn("No global stylesheet found")}export{o as a}