var K=u=>(e,t)=>e[`node${u}`]===t[`node${u}`],ku=K("Name"),Lu=K("Type"),Tu=K("Value");function iu(u,e){if(u.attributes.length===0&&e.attributes.length===0)return[];let t=[],r=new Map,i=new Map;for(let n of u.attributes)r.set(n.name,n.value);for(let n of e.attributes){let D=r.get(n.name);n.value===D?r.delete(n.name):(typeof D<"u"&&r.delete(n.name),i.set(n.name,n.value))}for(let n of r.keys())t.push({type:5,name:n});for(let[n,D]of i.entries())t.push({type:4,name:n,value:D});return t}function V(u,e=!0){let t=`${u.localName}`;for(let{name:r,value:i}of u.attributes)e&&r.startsWith("data-")||(t+=`[${r}=${i}]`);return t+=u.innerHTML,t}function z(u){switch(u.tagName){case"BASE":case"TITLE":return u.localName;case"META":{if(u.hasAttribute("name"))return`meta[name="${u.getAttribute("name")}"]`;if(u.hasAttribute("property"))return`meta[name="${u.getAttribute("property")}"]`;break}case"LINK":{if(u.hasAttribute("rel")&&u.hasAttribute("href"))return`link[rel="${u.getAttribute("rel")}"][href="${u.getAttribute("href")}"]`;if(u.hasAttribute("href"))return`link[href="${u.getAttribute("href")}"]`;break}}return V(u)}function Ru(u){let[e,t=""]=u.split("?");return`${e}?t=${Date.now()}&${t.replace(/t=\d+/g,"")}`}function w(u){if(u.nodeType===1&&u.hasAttribute("data-persist"))return u;if(u.nodeType===1&&u.localName==="script"){let e=document.createElement("script");for(let{name:t,value:r}of u.attributes)t==="src"&&(r=Ru(r)),e.setAttribute(t,r);return e.innerHTML=u.innerHTML,e}return u.cloneNode(!0)}function Uu(u,e){if(u.children.length===0&&e.children.length===0)return[];let t=[],r=new Map,i=new Map,n=new Map;for(let D of u.children)r.set(z(D),D);for(let D of e.children){let s=z(D),a=r.get(s);a?V(D,!1)!==V(a,!1)&&i.set(s,w(D)):n.set(s,w(D)),r.delete(s)}for(let D of u.childNodes){if(D.nodeType===1){let s=z(D);if(r.has(s)){t.push({type:1});continue}else if(i.has(s)){let a=i.get(s);t.push({type:3,attributes:iu(D,a),children:Du(D,a)});continue}}t.push(void 0)}for(let D of n.values())t.push({type:0,node:w(D)});return t}function Du(u,e){let t=[],r=Math.max(u.childNodes.length,e.childNodes.length);for(let i=0;iJ(r,s,D[a])));return}}}function Z(u,e){let t=U(u,e);return J(u,t)}var De=Object.hasOwnProperty;var cu,_,fu,Wu,B,lu,_u,pu,Q,W,L,du,uu,X,Y,Mu,Eu={},N=[],Nu=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,$=Array.isArray;function g(u,e){for(var t in e)u[t]=e[t];return u}function eu(u){u&&u.parentNode&&u.parentNode.removeChild(u)}function G(u,e,t,r,i){var n={type:u,props:e,key:t,ref:r,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:i??++fu,__i:-1,__u:0};return i==null&&_.vnode!=null&&_.vnode(n),n}function x(u){return u.children}function M(u,e){this.props=u,this.context=e}function b(u,e){if(e==null)return u.__?b(u.__,u.__i+1):null;for(var t;ee&&B.sort(pu),u=B.shift(),e=B.length,ju(u)}finally{B.length=j.__r=0}}function Cu(u,e,t,r,i,n,D,s,a,l,c){var E,o,F,p,A,h,d,f=r&&r.__k||N,C=e.length;for(a=$u(t,e,f,a,C),E=0;E0?D=u.__k[n]=G(D.type,D.props,D.key,D.ref?D.ref:null,D.__v):u.__k[n]=D,a=n+o,D.__=u,D.__b=u.__b+1,s=null,(l=D.__i=Hu(D,t,a,E))!=-1&&(E--,(s=t[l])&&(s.__u|=2)),s==null||s.__v==null?(l==-1&&(i>c?o--:ia?o--:o++,D.__u|=4))):u.__k[n]=null;if(E)for(n=0;n(c?1:0)){for(i=t-1,n=t+1;i>=0||n=0?i--:n++])!=null&&(2&l.__u)==0&&s==l.key&&a==l.type)return D}return-1}function au(u,e,t){e[0]=="-"?u.setProperty(e,t??""):u[e]=t==null?"":typeof t!="number"||Nu.test(e)?t:t+"px"}function P(u,e,t,r,i){var n,D;u:if(e=="style")if(typeof t=="string")u.style.cssText=t;else{if(typeof r=="string"&&(u.style.cssText=r=""),r)for(e in r)t&&e in t||au(u.style,e,"");if(t)for(e in t)r&&t[e]==r[e]||au(u.style,e,t[e])}else if(e[0]=="o"&&e[1]=="n")n=e!=(e=e.replace(du,"$1")),D=e.toLowerCase(),e=D in u||e=="onFocusOut"||e=="onFocusIn"?D.slice(2):e.slice(2),u.l||(u.l={}),u.l[e+n]=t,t?r?t[L]=r[L]:(t[L]=uu,u.addEventListener(e,n?Y:X,n)):u.removeEventListener(e,n?Y:X,n);else{if(i=="http://www.w3.org/2000/svg")e=e.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(e!="width"&&e!="height"&&e!="href"&&e!="list"&&e!="form"&&e!="tabIndex"&&e!="download"&&e!="rowSpan"&&e!="colSpan"&&e!="role"&&e!="popover"&&e in u)try{u[e]=t??"";break u}catch{}typeof t=="function"||(t==null||t===!1&&e[4]!="-"?u.removeAttribute(e):u.setAttribute(e,e=="popover"&&t==1?"":t))}}function Fu(u){return function(e){if(this.l){var t=this.l[e.type+u];if(e[W]==null)e[W]=uu++;else if(e[W]0?u:$(u)?u.map(Bu):u.constructor!==void 0?null:g({},u)}function Ou(u,e,t,r,i,n,D,s,a){var l,c,E,o,F,p,A,h=t.props||Eu,d=e.props,f=e.type;if(f=="svg"?i="http://www.w3.org/2000/svg":f=="math"?i="http://www.w3.org/1998/Math/MathML":i||(i="http://www.w3.org/1999/xhtml"),n!=null){for(l=0;l{let r=new URL(u.getAttribute(e),t);u.setAttribute(e,r.pathname+r.hash)};function wu(u,e){u.querySelectorAll('[href=""], [href^="./"], [href^="../"]').forEach(t=>{yu(t,"href",e)}),u.querySelectorAll('[src=""], [src^="./"], [src^="../"]').forEach(t=>{yu(t,"src",e)})}var Vu=//;async function bu(u){let e=await fetch(`${u}`);if(!e.headers.get("content-type")?.startsWith("text/html"))return e;let t=await e.clone().text(),[r,i]=t.match(Vu)??[];return i?fetch(`${new URL(i,u)}`):e}var Ku=1,T=document.createElement("route-announcer"),Ju=u=>u?.nodeType===Ku,Zu=u=>{try{let e=new URL(u);if(window.location.origin===e.origin)return!0}catch{}return!1},Qu=u=>{let e=u.origin===window.location.origin,t=u.pathname===window.location.pathname;return e&&t},xu=({target:u})=>{if(!Ju(u)||u.attributes.getNamedItem("target")?.value==="_blank")return;let e=u.closest("a");if(!e||"routerIgnore"in e.dataset)return;let{href:t}=e;if(Zu(t))return{url:new URL(t),scroll:"routerNoscroll"in e.dataset?!1:void 0}};function Su(u){let e=new CustomEvent("nav",{detail:{url:u}});document.dispatchEvent(e)}var ru=new Set;window.addCleanup=u=>ru.add(u);function Gu(){document.querySelector(".navigation-progress")?.remove();let u=document.createElement("div");u.className="navigation-progress",u.style.width="0",document.body.prepend(u),setTimeout(()=>{u.style.width="80%"},100)}function Xu(){let u=document.querySelector(".navigation-progress");u&&u.remove()}var I=!1,nu;async function Yu(u,e=!1){I=!0,Gu(),nu=nu||new DOMParser;let t=await bu(u).then(a=>{if(a.headers.get("content-type")?.startsWith("text/html"))return a.text();window.location.assign(u)}).catch(()=>{window.location.assign(u)});if(!t)return;let r=new CustomEvent("prenav",{detail:{}});document.dispatchEvent(r),ru.forEach(a=>a()),ru.clear();let i=nu.parseFromString(t,"text/html");wu(i,u);let n=i.querySelector("title")?.textContent;if(n)document.title=n;else{let a=document.querySelector("h1");n=a?.innerText??a?.textContent??u.pathname}T.textContent!==n&&(T.textContent=n),T.dataset.persist="",i.body.appendChild(T),document.querySelector(".navigation-progress")?.remove(),Z(document.body,i.body),e||(u.hash?document.getElementById(decodeURIComponent(u.hash.substring(1)))?.scrollIntoView():window.scrollTo({top:0})),document.head.querySelectorAll(":not([data-persist])").forEach(a=>a.remove()),i.head.querySelectorAll(":not([data-persist])").forEach(a=>document.head.appendChild(a)),e||history.pushState({},"",u),Su(H(window)),delete T.dataset.persist}async function O(u,e=!1){if(!I){I=!0;try{await Yu(u,e)}catch(t){console.error(t),window.location.assign(u)}finally{Xu(),I=!1}}}window.spaNavigate=O;function ue(){return typeof window<"u"&&(window.addEventListener("click",async u=>{let{url:e}=xu(u)??{};if(!(!e||u.ctrlKey||u.metaKey)){if(u.preventDefault(),Qu(e)&&e.hash){document.getElementById(decodeURIComponent(e.hash.substring(1)))?.scrollIntoView(),history.pushState({},"",e);return}O(e,!1)}}),window.addEventListener("popstate",u=>{let{url:e}=xu(u)??{};window.location.hash&&window.location.pathname===e?.pathname||O(new URL(window.location.toString()),!0)})),new class{go(e){let t=new URL(e,window.location.toString());return O(t,!1)}back(){return window.history.back()}forward(){return window.history.forward()}}}ue();Su(H(window));if(!customElements.get("route-announcer")){let u={"aria-live":"assertive","aria-atomic":"true",style:"position: absolute; left: 0; top: 0; clip: rect(0 0 0 0); clip-path: inset(50%); overflow: hidden; white-space: nowrap; width: 1px; height: 1px"};customElements.define("route-announcer",class extends HTMLElement{constructor(){super()}connectedCallback(){for(let[t,r]of Object.entries(u))this.setAttribute(t,r)}})}