/*! third party licenses: js/vendor.LICENSE.txt */ const p="modulepreload",y=function(l,o){return new URL(l,o).href},h={},v=function(l,o,a){let d=Promise.resolve();if(o&&o.length>0){const r=document.getElementsByTagName("link"),e=document.querySelector("meta[property=csp-nonce]"),f=e?.nonce||e?.getAttribute("nonce");d=Promise.allSettled(o.map(t=>{if(t=y(t,a),t in h)return;h[t]=!0;const s=t.endsWith(".css"),m=s?'[rel="stylesheet"]':"";if(a)for(let c=r.length-1;c>=0;c--){const i=r[c];if(i.href===t&&(!s||i.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${t}"]${m}`))return;const n=document.createElement("link");if(n.rel=s?"stylesheet":p,s||(n.as="script"),n.crossOrigin="",n.href=t,f&&n.setAttribute("nonce",f),document.head.appendChild(n),s)return new Promise((c,i)=>{n.addEventListener("load",c),n.addEventListener("error",()=>i(new Error(`Unable to preload CSS for ${t}`)))})}))}function u(r){const e=new Event("vite:preloadError",{cancelable:!0});if(e.payload=r,window.dispatchEvent(e),!e.defaultPrevented)throw r}return d.then(r=>{for(const e of r||[])e.status==="rejected"&&u(e.reason);return l().catch(u)})};export{v as _}; //# sourceMappingURL=preload-helper-CfzTJz-5.chunk.mjs.map