const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["_astro/mermaid.core.se8BdSrF.js","_astro/preload-helper.BlTxHScW.js","_astro/_commonjsHelpers.CqkleIqs.js","_astro/transform.B1W4q_4U.js","_astro/marked.esm.BSGMMIyL.js"])))=>i.map(i=>d[i]);
import{_ as m}from"./preload-helper.BlTxHScW.js";let r=null,o=!1;function u(){return document.querySelectorAll("pre.mermaid:not([data-processed])").length>0}function c(){const t=document.documentElement.getAttribute("data-theme")||document.body?.getAttribute("data-theme");switch(t){case"default":case"dark":case"forest":case"neutral":case"base":case"null":return t;case"light":return"default";default:return"default"}}async function d(){const t=document.querySelectorAll("pre.mermaid:not([data-processed])");if(t.length!==0){if(!r){const{default:a}=await m(async()=>{const{default:e}=await import("./mermaid.core.se8BdSrF.js").then(n=>n.at);return{default:e}},__vite__mapDeps([0,1,2,3,4]));r=a}r.initialize({startOnLoad:!1,theme:c(),gitGraph:{mainBranchName:"main",showCommitLabel:!0,showBranches:!0,rotateCommitLabel:!0}});for(const a of t){const e=a;e.hasAttribute("data-diagram")||e.setAttribute("data-diagram",e.textContent||"");const n=e.getAttribute("data-diagram")||"",s="mermaid-"+Math.random().toString(36).slice(2,11);try{const{svg:i}=await r.render(s,n);e.innerHTML=i,e.setAttribute("data-processed","true")}catch(i){console.error("[mermaid-nav-fix] Error:",i),e.setAttribute("data-processed","true")}}window.dispatchEvent(new CustomEvent("mermaid:rendered")),!o&&r&&(new MutationObserver(()=>{document.querySelectorAll("pre.mermaid[data-processed]").forEach(e=>e.removeAttribute("data-processed")),d()}).observe(document.documentElement,{attributes:!0,attributeFilter:["data-theme"]}),o=!0)}}document.addEventListener("astro:after-swap",()=>{requestAnimationFrame(()=>{u()&&d()})});
