markstream-vue 0.0.3-beta.1 → 0.0.3-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +279 -6
- package/README.zh-CN.md +287 -15
- package/dist/exports-CzGTWeP_.js +5323 -0
- package/dist/exports-Dt9os3zH.cjs +246 -0
- package/dist/exports.js +1 -1
- package/dist/{index-DGTqKnzM.js → index-BJRqEAxf.js} +409 -383
- package/dist/index-BOMIs5jY.cjs +22 -0
- package/dist/{index-ClFlwUOZ.cjs → index-DVzzMFW2.cjs} +1 -1
- package/dist/{index-BZqRC51k.js → index-DWSDjapj.js} +1 -1
- package/dist/{index-D-TkURzk.js → index-DoGGVWiX.js} +1 -1
- package/dist/{index-Cn5LHgOE.cjs → index-W52qnVsg.cjs} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.css +1 -1
- package/dist/index.d.ts +44 -27
- package/dist/index.js +64 -63
- package/dist/index.tailwind.css +1 -1
- package/dist/index4.js +1 -1
- package/dist/tailwind.ts +0 -0
- package/package.json +14 -5
- package/dist/exports-ByrWvfQh.cjs +0 -246
- package/dist/exports-CuW10Rlw.js +0 -4909
- package/dist/index-CapyHsmU.cjs +0 -22
|
@@ -0,0 +1,246 @@
|
|
|
1
|
+
"use strict";var Ao=Object.create;var Dn=Object.defineProperty,jo=Object.defineProperties,Ho=Object.getOwnPropertyDescriptor,Po=Object.getOwnPropertyDescriptors,Fo=Object.getOwnPropertyNames,Qn=Object.getOwnPropertySymbols,Ko=Object.getPrototypeOf,to=Object.prototype.hasOwnProperty,Oo=Object.prototype.propertyIsEnumerable;var eo=(t,o,n)=>o in t?Dn(t,o,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[o]=n,q=(t,o)=>{for(var n in o||(o={}))to.call(o,n)&&eo(t,n,o[n]);if(Qn)for(var n of Qn(o))Oo.call(o,n)&&eo(t,n,o[n]);return t},ht=(t,o)=>jo(t,Po(o));var Wo=(t,o,n,i)=>{if(o&&typeof o=="object"||typeof o=="function")for(let a of Fo(o))!to.call(t,a)&&a!==n&&Dn(t,a,{get:()=>o[a],enumerable:!(i=Ho(o,a))||i.enumerable});return t};var Wt=(t,o,n)=>(n=t!=null?Ao(Ko(t)):{},Wo(o||!t||!t.__esModule?Dn(n,"default",{value:t,enumerable:!0}):n,t));var $=(t,o,n)=>new Promise((i,a)=>{var m=g=>{try{f(n.next(g))}catch(p){a(p)}},u=g=>{try{f(n.throw(g))}catch(p){a(p)}},f=g=>g.done?i(g.value):Promise.resolve(g.value).then(m,u);f((n=n.apply(t,o)).next())});const An=require("stream-markdown-parser"),e=require("vue"),Xt=require("@floating-ui/dom");var Rn=typeof document!="undefined"?document.currentScript:null;const Xo=["cite"],Uo=e.defineComponent({__name:"BlockquoteNode",props:{node:{},indexKey:{},typewriter:{type:Boolean},customId:{}},emits:["copy"],setup(t){const o=t;return(n,i)=>(e.openBlock(),e.createElementBlock("blockquote",{class:"blockquote",dir:"auto",cite:t.node.cite},[e.withMemo([o.node.children],()=>e.createVNode(e.unref(ze),{"index-key":`blockquote-${o.indexKey}`,nodes:o.node.children||[],"custom-id":o.customId,typewriter:o.typewriter,onCopy:i[0]||(i[0]=a=>n.$emit("copy",a))},null,8,["index-key","nodes","custom-id","typewriter"]),i,1)],8,Xo))}}),H=(t,o)=>{const n=t.__vccOpts||t;for(const[i,a]of o)n[i]=a;return n},Yt=H(Uo,[["__scopeId","data-v-eeadc8a3"]]);Yt.install=t=>{t.component(Yt.__name,Yt)};const Yo={class:"checkbox-node"},qo=["checked"],Zo=e.defineComponent({__name:"CheckboxNode",props:{node:{}},setup(t){return(o,n)=>(e.openBlock(),e.createElementBlock("span",Yo,[e.createElementVNode("input",{type:"checkbox",checked:t.node.checked,disabled:"",class:"checkbox-input"},null,8,qo)]))}}),Qe=H(Zo,[["__scopeId","data-v-8dc6c46f"]]);Qe.install=t=>{t.component(Qe.__name,Qe)};const Go={class:"definition-list"},Jo={class:"definition-term"},Qo={class:"definition-desc"},er=e.defineComponent({__name:"DefinitionListNode",props:{node:{},indexKey:{},typewriter:{type:Boolean},customId:{}},emits:["copy"],setup(t){const o=t;return(n,i)=>(e.openBlock(),e.createElementBlock("dl",Go,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.node.items,(a,m)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:m},[e.createElementVNode("dt",Jo,[e.createVNode(e.unref(ze),{"index-key":`definition-term-${o.indexKey}-${m}`,nodes:a.term,"custom-id":o.customId,typewriter:o.typewriter,onCopy:i[0]||(i[0]=u=>n.$emit("copy",u))},null,8,["index-key","nodes","custom-id","typewriter"])]),e.createElementVNode("dd",Qo,[e.createVNode(e.unref(ze),{"index-key":`definition-desc-${o.indexKey}-${m}`,nodes:a.definition,"custom-id":o.customId,typewriter:o.typewriter,onCopy:i[1]||(i[1]=u=>n.$emit("copy",u))},null,8,["index-key","nodes","custom-id","typewriter"])])],64))),128))]))}}),qt=H(er,[["__scopeId","data-v-f88691d6"]]);qt.install=t=>{t.component(qt.__name,qt)};const tr={class:"emoji-node"},nr=e.defineComponent({__name:"EmojiNode",props:{node:{}},setup(t){return(o,n)=>(e.openBlock(),e.createElementBlock("span",tr,e.toDisplayString(t.node.name),1))}}),xe=H(nr,[["__scopeId","data-v-de55dc97"]]);xe.install=t=>{t.component(xe.__name,xe)};const pn="__global__",Vt={};function or(t,o){typeof t=="string"?Vt[t]=o||{}:Vt[pn]=t||{}}function et(t){return t?Vt[t]||Vt[pn]||{}:Vt[pn]||{}}function rr(t){if(t===pn)throw new Error("removeCustomComponents: use clearGlobalCustomComponents() to clear the global mapping");delete Vt[t]}function ar(){delete Vt[pn]}const lr=["id"],ir=["title"],sr=e.defineComponent({__name:"FootnoteReferenceNode",props:{node:{}},setup(t){const n=`#footnote-${t.node.id}`;function i(){if(typeof document=="undefined")return;const a=document.querySelector(n);a?a.scrollIntoView({behavior:"smooth"}):console.warn(`Element with href: ${n} not found`)}return(a,m)=>(e.openBlock(),e.createElementBlock("sup",{id:`fnref-${t.node.id}`,class:"footnote-reference",onClick:i},[e.createElementVNode("span",{href:n,title:`查看脚注 ${t.node.id}`,class:"footnote-link cursor-pointer"},"["+e.toDisplayString(t.node.id)+"]",9,ir)],8,lr))}}),be=H(sr,[["__scopeId","data-v-01af0fee"]]);be.install=t=>{t.component(be.__name,be)};const cr={class:"inline text-[85%] px-1 py-0.5 rounded font-mono bg-secondary whitespace-normal break-words max-w-full before:content-[''] after:content-['']"},Be=e.defineComponent({__name:"InlineCodeNode",props:{node:{}},setup(t){return(o,n)=>(e.openBlock(),e.createElementBlock("code",cr,e.toDisplayString(t.node.code),1))}});Be.install=t=>{t.component(Be.__name,Be)};const ur=["id"],dr=e.defineComponent({__name:"Tooltip",props:{visible:{type:Boolean},anchorEl:{},content:{},placement:{},offset:{},originX:{},originY:{},id:{},isDark:{type:[Boolean,null]}},setup(t){const o=t,n=e.computed(()=>{if(o.isDark!==void 0&&o.isDark!==null)return!!o.isDark;if(typeof document!="undefined")try{if(document.documentElement.classList.contains("dark")||window!=null&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches)return!0}catch(g){}return!1}),i=e.ref(null),a=e.ref({transform:"translate3d(0px, 0px, 0px)",left:"0px",top:"0px"}),m=e.ref(!1);let u=null;function f(){return $(this,null,function*(){var x,B;if(!o.anchorEl||!i.value)return;const g=[Xt.offset((x=o.offset)!=null?x:8),Xt.flip(),Xt.shift({padding:8})],{x:p,y:k}=yield Xt.computePosition(o.anchorEl,i.value,{placement:(B=o.placement)!=null?B:"top",middleware:g,strategy:"fixed"});a.value.transform=`translate3d(${Math.round(p)}px, ${Math.round(k)}px, 0)`,a.value.left="0px",a.value.top="0px"})}return e.watch(()=>o.visible,g=>$(null,null,function*(){if(g)if(m.value=!1,yield e.nextTick(),o.anchorEl&&i.value)try{const p=o.anchorEl.getBoundingClientRect();yield f();const k=a.value.transform;if(o.originX!=null&&o.originY!=null){const x=Math.abs(Number(o.originX)-p.left),B=Math.abs(Number(o.originY)-p.top);Math.hypot(x,B)>120?(a.value.transform=`translate3d(${Math.round(o.originX)}px, ${Math.round(o.originY)}px, 0)`,yield e.nextTick(),m.value=!0,yield e.nextTick(),a.value.transform=k):m.value=!0}else m.value=!0;u=Xt.autoUpdate(o.anchorEl,i.value,f)}catch(p){yield f(),m.value=!0,u=Xt.autoUpdate(o.anchorEl,i.value,f)}else m.value=!0;else m.value=!1,u&&(u(),u=null)})),e.watch([()=>o.anchorEl,()=>o.placement,()=>o.content],()=>$(null,null,function*(){o.visible&&o.anchorEl&&i.value&&(yield e.nextTick(),yield f())})),e.onBeforeUnmount(()=>{u&&u()}),(g,p)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"tooltip",appear:""},{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",{id:o.id,ref_key:"tooltip",ref:i,style:e.normalizeStyle({position:"fixed",left:a.value.left,top:a.value.top,transform:a.value.transform}),class:e.normalizeClass(["z-[9999] inline-block text-base py-2 px-3 rounded-md shadow-md whitespace-nowrap pointer-events-none tooltip-element border",[n.value?"bg-gray-900 text-white border-gray-700 border is-dark":"bg-white text-gray-900 border-gray-200 border"]]),role:"tooltip"},e.toDisplayString(t.content),15,ur),[[e.vShow,t.visible&&m.value]])]),_:1})]))}}),mr=H(dr,[["__scopeId","data-v-993f63aa"]]),Kn=e.ref(!1),mo=e.ref(""),fo=e.ref("top"),mn=e.ref(null),hn=e.ref(null),On=e.ref(null),Wn=e.ref(null),po=e.ref(null);let Mn=null,Cn=null;function ho(){Mn&&(clearTimeout(Mn),Mn=null),Cn&&(clearTimeout(Cn),Cn=null)}let no=!1;function fr(){if(no||typeof document=="undefined")return;no=!0;const t=document.createElement("div");t.setAttribute("data-singleton-tooltip","1"),document.body.appendChild(t);const o={setup(){return()=>{var n;return e.h(mr,{visible:Kn.value,"anchor-el":mn.value,content:mo.value,placement:fo.value,id:hn.value,originX:On.value,originY:Wn.value,isDark:(n=po.value)!=null?n:void 0})}}};e.createApp(o).mount(t)}function on(t,o,n="top",i=!1,a,m){if(!t)return;fr(),ho();const u=()=>{var f,g;hn.value=`tooltip-${Date.now()}-${Math.floor(Math.random()*1e3)}`,mn.value=t,mo.value=o,fo.value=n,On.value=(f=a==null?void 0:a.x)!=null?f:null,Wn.value=(g=a==null?void 0:a.y)!=null?g:null,po.value=typeof m=="boolean"?m:null,Kn.value=!0;try{t.setAttribute("aria-describedby",hn.value)}catch(p){}};i?u():Mn=setTimeout(u,80)}function Tn(t=!1){ho();const o=()=>{if(mn.value&&hn.value)try{mn.value.removeAttribute("aria-describedby")}catch(n){}Kn.value=!1,mn.value=null,hn.value=null,On.value=null,Wn.value=null};t?o():Cn=setTimeout(o,120)}function pr(t){return(t.split(".").pop()||t).replace(/[_-]/g," ").replace(/([A-Z])/g," $1").replace(/\s+/g," ").replace(/\b\w/g,n=>n.toUpperCase()).trim()}const vo={"common.copy":"Copy","common.copySuccess":"Copied","common.decrease":"Decrease","common.reset":"Reset","common.increase":"Increase","common.expand":"Expand","common.collapse":"Collapse","common.preview":"Preview","common.source":"Source","common.export":"Export","common.open":"Open","common.zoomIn":"Zoom in","common.zoomOut":"Zoom out","common.resetZoom":"Reset zoom","image.loadError":"Image failed to load","image.loading":"Loading image..."};function hr(t){Object.assign(vo,t)}function _n(){try{const o=globalThis.$vueI18nUse||null;if(o&&typeof o=="function")try{const n=o();if(n&&typeof n.t=="function")return{t:n.t.bind(n)}}catch(n){}}catch(o){}const t=o=>{var n;return(n=vo[o])!=null?n:pr(o)};return $(null,null,function*(){try{const o=yield import("vue-i18n"),n=o.useI18n||o.default&&o.default.useI18n;if(n&&typeof n=="function")try{const i=n();if(i&&typeof i.t=="function")try{globalThis.$vueI18nUse=()=>i}catch(a){}}catch(i){}}catch(o){}}),{t}}const go=Symbol("ViewportPriority");function vr(t,o){const n=typeof window!="undefined"&&typeof document!="undefined",i=typeof o=="boolean"?e.ref(o):o;let a=null,m=null;const u=new WeakMap;function f(p){var B,S,V;if(a||!n)return a;if(typeof IntersectionObserver=="undefined")return null;const k=(B=t==null?void 0:t(p!=null?p:null))!=null?B:null,x=m||{};return a=new IntersectionObserver(R=>{for(const O of R){const b=u.get(O.target);if(!b)continue;if(O.isIntersecting||O.intersectionRatio>0){if(!b.visible.value){b.visible.value=!0;try{b.resolve()}catch(ie){}}a==null||a.unobserve(O.target),u.delete(O.target)}}},{root:k,rootMargin:(S=x.rootMargin)!=null?S:"300px",threshold:(V=x.threshold)!=null?V:0}),a}const g=(p,k)=>{const x=e.ref(!1);let B=!1,S;const V=new Promise(b=>{S=()=>{B||(B=!0,b())}}),R=()=>{try{a==null||a.unobserve(p)}catch(b){}u.delete(p)};if(!n||!i.value)return x.value=!0,S(),{isVisible:x,whenVisible:V,destroy:R};!m&&k&&(m=q({},k));const O=f(p);return O?(u.set(p,{resolve:S,visible:x}),O.observe(p),{isVisible:x,whenVisible:V,destroy:R}):(x.value=!0,S(),{isVisible:x,whenVisible:V,destroy:R})};return e.provide(go,g),g}function Sn(){const t=e.inject(go,void 0);if(t)return t;const o=new WeakMap;let n=null;const i=()=>n||(typeof window=="undefined"||typeof IntersectionObserver=="undefined"?null:(n=new IntersectionObserver(m=>{for(const u of m){const f=o.get(u.target);if(!f)continue;if(u.isIntersecting||u.intersectionRatio>0){if(!f.visible.value){f.visible.value=!0;try{f.resolve()}catch(p){}}n==null||n.unobserve(u.target),o.delete(u.target)}}},{root:null,rootMargin:"300px",threshold:0}),n));return m=>{const u=e.ref(!1);let f=!1,g;const p=new Promise(B=>{g=()=>{f||(f=!0,B())}}),k=()=>{try{n==null||n.unobserve(m)}catch(B){}o.delete(m)},x=i();return x?(o.set(m,{resolve:g,visible:u}),x.observe(m),{isVisible:u,whenVisible:p,destroy:k}):(u.value=!0,g(),{isVisible:u,whenVisible:p,destroy:k})}}const gr={class:"relative inline-block"},wr=["src","alt","title","loading","tabindex","aria-label"],kr={class:"text-sm whitespace-nowrap"},yr={key:1,class:"text-sm text-gray-500"},xr={key:"error",class:"px-4 py-2 bg-gray-100 flex items-center justify-center rounded-lg gap-2 text-red-500"},br={class:"text-sm whitespace-nowrap"},Br={key:0,class:"mt-2 text-sm text-gray-500 italic"},Mr=e.defineComponent({__name:"ImageNode",props:{node:{},fallbackSrc:{default:""},showCaption:{type:Boolean,default:!1},lazy:{type:Boolean,default:!0},svgMinHeight:{default:"12rem"},usePlaceholder:{type:Boolean,default:!0}},emits:["load","error","click"],setup(t,{emit:o}){const n=t,i=o,a=e.ref(!1),m=e.ref(!1),u=e.ref(!1),f=e.ref(null),g=Sn(),p=e.ref(null),k=e.ref(typeof window=="undefined");typeof window!="undefined"&&e.watch(()=>f.value,Z=>{var j;if((j=p.value)==null||j.destroy(),p.value=null,!Z){k.value=!1;return}const ie=g(Z,{rootMargin:"400px"});p.value=ie,k.value=ie.isVisible.value,ie.whenVisible.then(()=>{k.value=!0})},{immediate:!0}),e.onBeforeUnmount(()=>{var Z;(Z=p.value)==null||Z.destroy(),p.value=null});const x=e.computed(()=>m.value&&n.fallbackSrc?n.fallbackSrc:n.node.src),B=e.computed(()=>!n.lazy||k.value),S=e.computed(()=>/\.svg(?:\?|$)/i.test(x.value));function V(){n.fallbackSrc&&!u.value?(u.value=!0,m.value=!0):(m.value=!0,i("error",n.node.src))}function R(){a.value=!0,m.value=!1,i("load",x.value)}function O(Z){Z.preventDefault(),!(!a.value||m.value)&&i("click",[Z,x.value])}const{t:b}=_n();return e.watch(x,()=>{a.value=!1,m.value=!1}),(Z,ie)=>(e.openBlock(),e.createElementBlock("figure",{ref_key:"figureRef",ref:f,class:"text-center my-8"},[e.createElementVNode("div",gr,[e.createVNode(e.Transition,{name:"img-switch",mode:"out-in"},{default:e.withCtx(()=>{var j,Y,I,P,je;return[!t.node.loading&&!m.value&&B.value?(e.openBlock(),e.createElementBlock("img",{key:"image",src:x.value,alt:String((Y=(j=n.node.alt)!=null?j:n.node.title)!=null?Y:""),title:String((P=(I=n.node.title)!=null?I:n.node.alt)!=null?P:""),class:e.normalizeClass(["max-w-96 h-auto rounded-lg transition-opacity duration-200 ease-in-out",{"opacity-0":!a.value,"opacity-100":a.value,"cursor-pointer":a.value}]),style:e.normalizeStyle(S.value?{minHeight:n.svgMinHeight,width:"100%",height:"auto",objectFit:"contain"}:void 0),loading:n.lazy?"lazy":"eager",decoding:"async",tabindex:a.value?0:-1,"aria-label":(je=n.node.alt)!=null?je:e.unref(b)("image.preview"),onError:V,onLoad:R,onClick:O},null,46,wr)):m.value?!t.node.loading&&!n.fallbackSrc?(e.openBlock(),e.createElementBlock("div",xr,[e.renderSlot(Z.$slots,"error",{node:n.node,displaySrc:x.value,imageLoaded:a.value,hasError:m.value,fallbackSrc:n.fallbackSrc,lazy:n.lazy,isSvg:S.value},()=>[ie[1]||(ie[1]=e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24"},[e.createElementVNode("path",{fill:"currentColor",d:"M2 2h20v10h-2V4H4v9.586l5-5L14.414 14L13 15.414l-4-4l-5 5V20h8v2H2zm13.547 5a1 1 0 1 0 0 2a1 1 0 0 0 0-2m-3 1a3 3 0 1 1 6 0a3 3 0 0 1-6 0m3.625 6.757L19 17.586l2.828-2.829l1.415 1.415L20.414 19l2.829 2.828l-1.415 1.415L19 20.414l-2.828 2.829l-1.415-1.415L17.586 19l-2.829-2.828z"})],-1)),e.createElementVNode("span",br,e.toDisplayString(e.unref(b)("image.loadError")),1)],!0)])):e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:"placeholder",class:"placeholder-layer max-w-96 inline-flex items-center justify-center gap-2",style:e.normalizeStyle(S.value?{minHeight:n.svgMinHeight,width:"100%"}:{minHeight:"6rem"})},[n.usePlaceholder?e.renderSlot(Z.$slots,"placeholder",{key:0,node:n.node,displaySrc:x.value,imageLoaded:a.value,hasError:m.value,fallbackSrc:n.fallbackSrc,lazy:n.lazy,isSvg:S.value},()=>[ie[0]||(ie[0]=e.createElementVNode("div",{class:"w-4 h-4 rounded-full border-2 border-solid border-current border-t-transparent animate-spin","aria-hidden":"true"},null,-1)),e.createElementVNode("span",kr,e.toDisplayString(e.unref(b)("image.loading")),1)],!0):(e.openBlock(),e.createElementBlock("span",yr,e.toDisplayString(t.node.raw),1))],4))]}),_:3})]),n.showCaption&&n.node.alt?(e.openBlock(),e.createElementBlock("figcaption",Br,e.toDisplayString(n.node.alt),1)):e.createCommentVNode("",!0)],512))}}),wt=H(Mr,[["__scopeId","data-v-7ca79b66"]]);wt.install=t=>{t.component(wt.__name,wt)};let dn=null,En=!1,Xn=wo;function wo(){return $(null,null,function*(){const t=yield import("katex");return yield import("katex/contrib/mhchem"),t})}function Cr(){dn=null,En=!1}function Un(t){Xn=t,Cr()}function Er(t){Un(t!=null?t:wo)}function Nr(){Un(null)}function Yn(){return typeof Xn=="function"}function In(){return $(this,null,function*(){if(dn)return dn;if(En)return null;const t=Xn;if(!t)return En=!0,null;try{const o=yield t();if(o)return dn=o,dn}catch(o){}return En=!0,null})}const zn=e.shallowRef(!1);let oo=null;function ko(){return oo||(oo=In().then(t=>{zn.value=!!t}).catch(()=>{zn.value=!1})),e.readonly(zn)}const Tr=e.defineComponent({__name:"TextNode",props:{node:{}},emits:["copy"],setup(t){const o=ko();return(n,i)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass([[e.unref(o)&&t.node.center?"text-node-center":""],"whitespace-pre-wrap break-words text-node"])},e.toDisplayString(t.node.content),3))}}),ue=H(Tr,[["__scopeId","data-v-56f30838"]]);ue.install=t=>{t.component(ue.__name,ue)};const st=e.defineAsyncComponent(()=>$(null,null,function*(){var o,n;if(typeof globalThis!="undefined"&&typeof globalThis.process!="undefined"&&((n=(o=globalThis.process)==null?void 0:o.env)==null?void 0:n.NODE_ENV)==="test")return i=>{var a,m;return e.h(ue,ht(q({},i),{node:ht(q({},i.node),{content:(m=i.node.raw)!=null?m:`$${(a=i.node.content)!=null?a:""}$`})}))};try{if(yield In())return(yield Promise.resolve().then(()=>require("./index-W52qnVsg.cjs"))).default}catch(i){console.warn('[markstream-vue] Optional peer dependencies for MathInlineNode are missing. Falling back to text rendering. To enable full math rendering features, please install "katex".',i)}return i=>{var a,m;return e.h(ue,ht(q({},i),{node:ht(q({},i.node),{content:(m=i.node.raw)!=null?m:`$${(a=i.node.content)!=null?a:""}$`})}))}})),_r=e.defineAsyncComponent(()=>$(null,null,function*(){try{if(yield In())return(yield Promise.resolve().then(()=>require("./index-DVzzMFW2.cjs"))).default}catch(t){console.warn('[markstream-vue] Optional peer dependencies for MathBlockNode are missing. Falling back to text rendering. To enable full math rendering features, please install "katex".',t)}return t=>{var o,n;return e.h(ue,ht(q({},t),{node:ht(q({},t.node),{content:(n=t.node.raw)!=null?n:`$$${(o=t.node.content)!=null?o:""}$$`})}))}})),Me=e.defineComponent({__name:"ReferenceNode",props:{node:{},messageId:{},threadId:{}},emits:["click","mouseEnter","mouseLeave"],setup(t){return(o,n)=>(e.openBlock(),e.createElementBlock("span",{class:"reference-node cursor-pointer bg-accent text-xs rounded-md px-1.5 mx-0.5 hover:bg-secondary",role:"button",tabindex:"0",onClick:n[0]||(n[0]=i=>o.$emit("click",i,t.node.id,t.messageId,t.threadId)),onMouseenter:n[1]||(n[1]=i=>o.$emit("mouseEnter",i,t.node.id,t.messageId,t.threadId)),onMouseleave:n[2]||(n[2]=i=>o.$emit("mouseLeave",i,t.node.id,t.messageId,t.threadId))},e.toDisplayString(t.node.id),33))}});Me.install=t=>{t.component(Me.__name,Me)};const Sr={class:"superscript-node"},Ir={key:1},$r=e.defineComponent({__name:"SuperscriptNode",props:{node:{},customId:{},indexKey:{}},setup(t){const o=t,n=et(o.customId),i=q({text:ue,inline_code:Be,link:Ne,strong:Ce,emphasis:Ae,footnote_reference:be,strikethrough:Ee,highlight:De,insert:Le,subscript:Ve,emoji:xe,math_inline:st,reference:Me},n);return(a,m)=>(e.openBlock(),e.createElementBlock("sup",Sr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.node.children,(u,f)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:`${t.indexKey||"superscript"}-${f}`},[i[u.type]?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i[u.type]),{key:0,node:u,"custom-id":o.customId,"index-key":`${t.indexKey||"superscript"}-${f}`},null,8,["node","custom-id","index-key"])):(e.openBlock(),e.createElementBlock("span",Ir,e.toDisplayString(u.content||u.raw),1))],64))),128))]))}}),$e=H($r,[["__scopeId","data-v-9ae5549f"]]);$e.install=t=>{t.component($e.__name,$e)};const Vr={class:"subscript-node"},Lr={key:1},Dr=e.defineComponent({__name:"SubscriptNode",props:{node:{},customId:{},indexKey:{}},setup(t){const o=t,n=et(o.customId),i=q({text:ue,inline_code:Be,link:Ne,strong:Ce,emphasis:Ae,footnote_reference:be,strikethrough:Ee,highlight:De,insert:Le,superscript:$e,emoji:xe,math_inline:st,reference:Me},n);return(a,m)=>(e.openBlock(),e.createElementBlock("sub",Vr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.node.children,(u,f)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:`${t.indexKey||"subscript"}-${f}`},[i[u.type]?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i[u.type]),{key:0,node:u,"custom-id":o.customId,"index-key":`${t.indexKey||"subscript"}-${f}`},null,8,["node","custom-id","index-key"])):(e.openBlock(),e.createElementBlock("span",Lr,e.toDisplayString(u.content||u.raw),1))],64))),128))]))}}),Ve=H(Dr,[["__scopeId","data-v-37438707"]]);Ve.install=t=>{t.component(Ve.__name,Ve)};const Rr={class:"strong-node"},zr=e.defineComponent({__name:"StrongNode",props:{node:{},customId:{},indexKey:{}},setup(t){const o=t,n=et(o.customId),i=q({text:ue,inline_code:Be,link:Ne,emphasis:Ae,strikethrough:Ee,highlight:De,insert:Le,subscript:Ve,superscript:$e,emoji:xe,footnote_reference:be,math_inline:st,reference:Me},n);return(a,m)=>(e.openBlock(),e.createElementBlock("strong",Rr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.node.children,(u,f)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i[u.type]),{key:`${t.indexKey||"strong"}-${f}`,"index-key":`${t.indexKey||"strong"}-${f}`,node:u,"custom-id":o.customId},null,8,["index-key","node","custom-id"]))),128))]))}}),Ce=H(zr,[["__scopeId","data-v-3f61dca6"]]);Ce.install=t=>{t.component(Ce.__name,Ce)};const Ar={class:"strikethrough-node"},jr=e.defineComponent({__name:"StrikethroughNode",props:{node:{},customId:{},indexKey:{}},setup(t){const o=t,n=et(o.customId),i=q({text:ue,inline_code:Be,link:Ne,strong:Ce,emphasis:Ae,highlight:De,insert:Le,subscript:Ve,superscript:$e,emoji:xe,footnote_reference:be,math_inline:st,reference:Me},n);return(a,m)=>(e.openBlock(),e.createElementBlock("del",Ar,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.node.children,(u,f)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i[u.type]),{key:`${t.indexKey||"strikethrough"}-${f}`,node:u,"custom-id":o.customId,"index-key":`${t.indexKey||"strikethrough"}-${f}`},null,8,["node","custom-id","index-key"]))),128))]))}}),Ee=H(jr,[["__scopeId","data-v-8236f64d"]]);Ee.install=t=>{t.component(Ee.__name,Ee)};const Hr=["href","title","aria-label","aria-hidden"],Pr=["aria-hidden"],Fr={class:"link-text-wrapper relative inline-flex"},Kr={class:"leading-[normal] link-text"},Or={class:"leading-[normal] link-text"},Wr=e.defineComponent({__name:"LinkNode",props:{node:{},indexKey:{},customId:{},showTooltip:{type:Boolean,default:!0},color:{},underlineHeight:{},underlineBottom:{},animationDuration:{},animationOpacity:{},animationTiming:{},animationIteration:{}},setup(t){const o=t,n=e.computed(()=>{var p,k,x,B,S,V;const g=o.underlineBottom!==void 0?typeof o.underlineBottom=="number"?`${o.underlineBottom}px`:String(o.underlineBottom):"-3px";return{"--link-color":(p=o.color)!=null?p:"#0366d6","--underline-height":`${(k=o.underlineHeight)!=null?k:2}px`,"--underline-bottom":g,"--underline-opacity":String((x=o.animationOpacity)!=null?x:.9),"--underline-duration":`${(B=o.animationDuration)!=null?B:.8}s`,"--underline-timing":(S=o.animationTiming)!=null?S:"linear","--underline-iteration":typeof o.animationIteration=="number"?String(o.animationIteration):(V=o.animationIteration)!=null?V:"infinite"}}),i={text:ue,strong:Ce,strikethrough:Ee,emphasis:Ae,image:wt},a=e.useAttrs();function m(g){var B,S,V;if(!o.showTooltip)return;const p=g,k=(p==null?void 0:p.clientX)!=null&&(p==null?void 0:p.clientY)!=null?{x:p.clientX,y:p.clientY}:void 0,x=((B=o.node)==null?void 0:B.title)||((S=o.node)==null?void 0:S.href)||((V=o.node)==null?void 0:V.text)||"";on(g.currentTarget,x,"top",!1,k)}function u(){o.showTooltip&&Tn()}const f=e.computed(()=>{var g,p;return String((p=(g=o.node.title)!=null?g:o.node.href)!=null?p:"")});return(g,p)=>t.node.loading?(e.openBlock(),e.createElementBlock("span",e.mergeProps({key:1,class:"link-loading inline-flex items-baseline gap-1.5","aria-hidden":t.node.loading?"false":"true"},e.unref(a),{style:n.value}),[e.createElementVNode("span",Fr,[e.createElementVNode("span",Kr,[e.createElementVNode("span",Or,e.toDisplayString(t.node.text),1)]),p[1]||(p[1]=e.createElementVNode("span",{class:"underline-anim","aria-hidden":"true"},null,-1))])],16,Pr)):(e.openBlock(),e.createElementBlock("a",e.mergeProps({key:0,class:"link-node",href:t.node.href,title:t.showTooltip?"":f.value,"aria-label":`Link: ${f.value}`,"aria-hidden":t.node.loading?"true":"false",target:"_blank",rel:"noopener noreferrer"},e.unref(a),{style:n.value,onMouseenter:p[0]||(p[0]=k=>m(k)),onMouseleave:u}),[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.node.children,(k,x)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i[k.type]),{key:`${t.indexKey||"emphasis"}-${x}`,node:k,"custom-id":o.customId,"index-key":`${t.indexKey||"link-text"}-${x}`},null,8,["node","custom-id","index-key"]))),128))],16,Hr))}}),Ne=H(Wr,[["__scopeId","data-v-80b69735"]]);Ne.install=t=>{t.component(Ne.__name,Ne)};const Xr={class:"insert-node"},Ur=e.defineComponent({__name:"InsertNode",props:{node:{},customId:{},indexKey:{}},setup(t){const o=t,n=et(o.customId),i=q({text:ue,inline_code:Be,link:Ne,strong:Ce,emphasis:Ae,strikethrough:Ee,highlight:De,subscript:Ve,superscript:$e,emoji:xe,footnote_reference:be,math_inline:st,reference:Me},n);return(a,m)=>(e.openBlock(),e.createElementBlock("ins",Xr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.node.children,(u,f)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i[u.type]),{key:`${t.indexKey||"insert"}-${f}`,node:u,"custom-id":o.customId,"index-key":`${t.indexKey||"insert"}-${f}`},null,8,["node","custom-id","index-key"]))),128))]))}}),Le=H(Ur,[["__scopeId","data-v-0b4b6459"]]);Le.install=t=>{t.component(Le.__name,Le)};const Yr={class:"highlight-node"},qr=e.defineComponent({__name:"HighlightNode",props:{node:{},customId:{},indexKey:{}},setup(t){const o=t,n=et(o.customId),i=q({text:ue,inline_code:Be,link:Ne,strong:Ce,emphasis:Ae,strikethrough:Ee,insert:Le,subscript:Ve,superscript:$e,emoji:xe,footnote_reference:be,math_inline:st,reference:Me},n);return(a,m)=>(e.openBlock(),e.createElementBlock("mark",Yr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.node.children,(u,f)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i[u.type]),{key:`${t.indexKey||"highlight"}-${f}`,node:u,"custom-id":o.customId,"index-key":`${t.indexKey||"highlight"}-${f}`},null,8,["node","custom-id","index-key"]))),128))]))}}),De=H(qr,[["__scopeId","data-v-fbe5e4f2"]]);De.install=t=>{t.component(De.__name,De)};const Zr={class:"emphasis-node"},Gr=e.defineComponent({__name:"EmphasisNode",props:{node:{},customId:{},indexKey:{}},setup(t){const o=t,n=et(o.customId),i=q({text:ue,inline_code:Be,link:Ne,strong:Ce,strikethrough:Ee,highlight:De,insert:Le,subscript:Ve,superscript:$e,emoji:xe,footnote_reference:be,math_inline:st,reference:Me},n);return(a,m)=>(e.openBlock(),e.createElementBlock("em",Zr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.node.children,(u,f)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i[u.type]),{key:`${t.indexKey||"emphasis"}-${f}`,node:u,"custom-id":o.customId,"index-key":`${t.indexKey||"emphasis"}-${f}`},null,8,["node","custom-id","index-key"]))),128))]))}}),Ae=H(Gr,[["__scopeId","data-v-8723e015"]]);Ae.install=t=>{t.component(Ae.__name,Ae)};const Jr=["href","title"],Qr=e.defineComponent({__name:"FootnoteAnchorNode",props:{node:{}},setup(t){const o=t;function n(i){var u;if(i.preventDefault(),typeof document=="undefined")return;const a=`fnref-${String((u=o.node.id)!=null?u:"")}`,m=document.getElementById(a);m&&m.scrollIntoView({behavior:"smooth"})}return(i,a)=>(e.openBlock(),e.createElementBlock("a",{class:"footnote-anchor text-sm text-[#0366d6] hover:underline cursor-pointer",href:`#fnref-${t.node.id}`,title:`返回引用 ${t.node.id}`,onClick:n}," ↩︎ ",8,Jr))}}),Lt=H(Qr,[["__scopeId","data-v-4756ce0d"]]);Lt.install=t=>{t.component(Lt.__name,Lt)};const ea=["id"],ta={class:"flex-1"},Zt=e.defineComponent({__name:"FootnoteNode",props:{node:{},indexKey:{},typewriter:{type:Boolean},customId:{}},emits:["copy"],setup(t){const o=t;return(n,i)=>(e.openBlock(),e.createElementBlock("div",{id:`fnref--${t.node.id}`,class:"flex mt-2 mb-2 text-sm leading-relaxed border-t border-[#eaecef] pt-2"},[e.createElementVNode("div",ta,[e.withMemo([o.node.children],()=>e.createVNode(e.unref(ze),{"index-key":`footnote-${o.indexKey}`,nodes:o.node.children,"custom-id":o.customId,typewriter:o.typewriter,onCopy:i[0]||(i[0]=a=>n.$emit("copy",a))},null,8,["index-key","nodes","custom-id","typewriter"]),i,1)])],8,ea))}});Zt.install=t=>{t.component(Zt.__name,Zt)};const na={class:"hard-break"},oa=e.defineComponent({__name:"HardBreakNode",props:{node:{}},setup(t){return(o,n)=>(e.openBlock(),e.createElementBlock("br",na))}}),yt=H(oa,[["__scopeId","data-v-50c58f70"]]);yt.install=t=>{t.component(yt.__name,yt)};const ra=e.defineComponent({__name:"HeadingNode",props:{node:{},customId:{},indexKey:{}},setup(t){const o=t,n=et(o.customId),i=q({text:ue,inline_code:Be,link:Ne,image:wt,strong:Ce,emphasis:Ae,strikethrough:Ee,highlight:De,insert:Le,subscript:Ve,superscript:$e,emoji:xe,checkbox:Qe,checkbox_input:Qe,footnote_reference:be,hardbreak:yt,math_inline:st,reference:Me},n);return(a,m)=>e.withMemo([t.node.children],()=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(`h${t.node.level}`),{class:e.normalizeClass(["heading-node",[`heading-${t.node.level}`]]),dir:"auto"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.node.children,(u,f,g,p)=>{const k=[u];if(p&&p.key===`${t.indexKey||"heading"}-${f}`&&e.isMemoSame(p,k))return p;const x=(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i[u.type]),{key:`${t.indexKey||"heading"}-${f}`,"custom-id":o.customId,node:u,"index-key":`${t.indexKey||"heading"}-${f}`},null,8,["custom-id","node","index-key"]));return x.memo=k,x},m,0),128))]),_:1},8,["class"])),m,2)}}),jn=H(ra,[["__scopeId","data-v-e3e7e2ce"]]),$n=jn;$n.install=t=>{t.component(jn.__name,jn)};const aa=e.defineComponent({__name:"ListItemNode",props:{item:{},indexKey:{},value:{},customId:{},typewriter:{type:Boolean}},emits:["copy"],setup(t){const o=t,n=e.computed(()=>o.value==null?{}:{value:o.value});return(i,a)=>(e.openBlock(),e.createElementBlock("li",e.mergeProps({class:"list-item pl-1.5 my-2",dir:"auto"},n.value),[e.withMemo([o.item.children],()=>e.createVNode(e.unref(ze),{"index-key":`list-item-${o.indexKey}`,nodes:o.item.children,"custom-id":o.customId,typewriter:o.typewriter,"batch-rendering":!1,onCopy:a[0]||(a[0]=m=>i.$emit("copy",m))},null,8,["index-key","nodes","custom-id","typewriter"]),a,1)],16))}}),Gt=H(aa,[["__scopeId","data-v-7a618746"]]);Gt.install=t=>{t.component(Gt.__name,Gt)};const la=e.defineComponent({__name:"ListNode",props:{node:{},customId:{},indexKey:{},typewriter:{type:Boolean}},emits:["copy"],setup(t){return(o,n)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.node.ordered?"ol":"ul"),{class:e.normalizeClass(["list-node",{"list-decimal":t.node.ordered,"list-disc":!t.node.ordered}])},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.node.items,(i,a,m,u)=>{var p;const f=[i];if(u&&u.key===`${t.indexKey||"list"}-${a}`&&e.isMemoSame(u,f))return u;const g=(e.openBlock(),e.createBlock(e.unref(Gt),{key:`${t.indexKey||"list"}-${a}`,item:i,"custom-id":t.customId,"index-key":`${t.indexKey||"list"}-${a}`,typewriter:t.typewriter,value:t.node.ordered?((p=t.node.start)!=null?p:1)+a:void 0,onCopy:n[0]||(n[0]=k=>o.$emit("copy",k))},null,8,["item","custom-id","index-key","typewriter","value"]));return g.memo=f,g},n,1),128))]),_:1},8,["class"]))}}),Jt=H(la,[["__scopeId","data-v-79057d57"]]);Jt.install=t=>{t.component(Jt.__name,Jt)};const ia="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%20width='16'%20height='16'%3e%3cpath%20fill='none'%20stroke='%23ca9ee6'%20stroke-linecap='round'%20stroke-linejoin='round'%20d='M1.5%202.5c0%206%202.25%205.75%204%207%20.83.67%201.17%202%201%204h3c-.17-2%20.17-3.33%201-4%201.75-1.25%204-1%204-7C12%202.5%2010%203%208%207%206%203%204%202.5%201.5%202.5'%20/%3e%3c/svg%3e";function yo(t){try{if(typeof globalThis!="undefined"&&typeof globalThis.requestAnimationFrame=="function")return globalThis.requestAnimationFrame(t)}catch(o){}return globalThis.setTimeout(t,0)}const qn=()=>import("mermaid");let Ut=null,Zn=qn;function sa(){Ut=null}function Gn(t){Zn=t,sa()}function ca(t){Gn(t!=null?t:qn)}function ua(){Gn(null)}function xo(){return typeof Zn=="function"}function da(t){if(!t)return t;const o=t&&t.default?t.default:t;if(o&&(typeof o.render=="function"||typeof o.parse=="function"||typeof o.initialize=="function"))return o;if(o&&o.mermaidAPI&&(typeof o.mermaidAPI.render=="function"||typeof o.mermaidAPI.parse=="function")){const n=o.mermaidAPI;return ht(q({},o),{render:n.render.bind(n),parse:n.parse?n.parse.bind(n):void 0,initialize:i=>typeof o.initialize=="function"?o.initialize(i):n.initialize?n.initialize(i):void 0})}return t.mermaid&&typeof t.mermaid.render=="function"?t.mermaid:o}function ma(t){if(t)try{const o=t==null?void 0:t.initialize;t.initialize=n=>{const i=q({suppressErrorRendering:!0},n||{});if(typeof o=="function")return o.call(t,i);if(t!=null&&t.mermaidAPI&&typeof t.mermaidAPI.initialize=="function")return t.mermaidAPI.initialize(i)}}catch(o){}}function fa(){return $(this,null,function*(){if(Ut)return Ut;const t=Zn;if(!t)return null;let o;try{o=yield t()}catch(n){throw t===qn?new Error('Optional dependency "mermaid" is not installed. Please install it to enable mermaid diagrams.'):n}return o?(Ut=da(o),ma(Ut),Ut):null})}let pe=null,xt=null;const ce=new Map,pa=5;let Nn=pa,Hn=!1;function ha(t){Hn=!!t}function va(t){Number.isFinite(t)&&t>0&&(Nn=Math.floor(t))}function ga(){return{inFlight:ce.size,max:Nn}}const bo="WORKER_BUSY",Bo="MERMAID_DISABLED";function wa(t){pe=t,xt=null;const o=t;pe.onmessage=n=>{if(pe!==o)return;const{id:i,ok:a,result:m,error:u}=n.data,f=ce.get(i);f&&(a===!1||u?f.reject(new Error(u||"Unknown error")):f.resolve(m))},pe.onerror=n=>{var i,a;if(pe===o){if(ce.size===0){(i=console.debug)==null||i.call(console,"[mermaidWorkerClient] Worker error (no pending):",(n==null?void 0:n.message)||n);return}try{Hn?console.error("[mermaidWorkerClient] Worker error:",(n==null?void 0:n.message)||n):(a=console.debug)==null||a.call(console,"[mermaidWorkerClient] Worker error:",(n==null?void 0:n.message)||n)}catch(m){}for(const[m,u]of ce.entries())u.reject(new Error(`Worker error: ${n.message}`));ce.clear()}},pe.onmessageerror=n=>{var i,a;if(pe===o){if(ce.size===0){(i=console.debug)==null||i.call(console,"[mermaidWorkerClient] Worker messageerror (no pending):",n);return}try{Hn?console.error("[mermaidWorkerClient] Worker messageerror:",n):(a=console.debug)==null||a.call(console,"[mermaidWorkerClient] Worker messageerror:",n)}catch(m){}for(const[m,u]of ce.entries())u.reject(new Error("Worker messageerror"));ce.clear()}}}function ka(){var t;if(pe)try{for(const[o,n]of ce.entries())n.reject(new Error("Worker cleared"));ce.clear(),(t=pe.terminate)==null||t.call(pe)}catch(o){}pe=null,xt=null}function ya(){return pe||(xt=new Error("[mermaidWorkerClient] No worker instance set. Please inject a Worker via setMermaidWorker()."),xt.name="WorkerInitError",xt.code="WORKER_INIT_ERROR",null)}function Mo(t,o,n=1400){if(!xo()){const a=new Error("Mermaid rendering disabled");return a.name="MermaidDisabled",a.code=Bo,Promise.reject(a)}if(xt)return Promise.reject(xt);const i=ya();if(!i)return Promise.reject(xt);if(ce.size>=Nn){const a=new Error("Worker busy");return a.name="WorkerBusy",a.code=bo,a.inFlight=ce.size,a.max=Nn,Promise.reject(a)}return new Promise((a,m)=>{const u=Math.random().toString(36).slice(2);let f=!1,g;const p=()=>{f||(f=!0,g!=null&&globalThis.clearTimeout(g),ce.delete(u))},k={resolve:x=>{p(),a(x)},reject:x=>{p(),m(x)}};ce.set(u,k);try{i.postMessage({id:u,action:t,payload:o})}catch(x){ce.delete(u),m(x);return}g=globalThis.setTimeout(()=>{const x=new Error("Worker call timed out");x.name="WorkerTimeout",x.code="WORKER_TIMEOUT";const B=ce.get(u);B&&B.reject(x)},n)})}function Co(t,o,n=1400){return $(this,null,function*(){try{return yield Mo("canParse",{code:t,theme:o},n)}catch(i){return Promise.reject(i)}})}function Eo(t,o,n=1400){return $(this,null,function*(){try{return yield Mo("findPrefix",{code:t,theme:o},n)}catch(i){return Promise.reject(i)}})}function Pn(){if(pe)try{for(const[t,o]of ce.entries())o.reject(new Error("Worker terminated"));ce.clear(),pe.terminate()}finally{pe=null}}const xa={key:0},ba={key:1,class:"flex items-center space-x-2 overflow-hidden"},Ba=["src"],Ma={key:2},Ca={class:"flex items-center space-x-1"},Ea={class:"flex items-center space-x-1"},Na={key:4},Ta={key:5,class:"flex items-center space-x-1"},_a=["aria-pressed"],Sa={key:0,xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},Ia={key:1,xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},$a=["disabled"],Va=["disabled"],La={key:0,xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"0.75rem",height:"0.75rem",viewBox:"0 0 24 24"},Da={key:1,xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"0.75rem",height:"0.75rem",viewBox:"0 0 24 24"},Ra={key:1,class:"relative"},za={key:0,class:"absolute top-2 right-2 z-10 rounded-lg"},Aa={class:"flex items-center gap-2 backdrop-blur rounded-lg"},ja={class:"absolute top-6 right-6 z-50 flex items-center gap-2"},Ha=300,Pa=500,Fa=3,Ka=e.defineComponent({__name:"MermaidBlockNode",props:{node:{},maxHeight:{default:"500px"},loading:{type:Boolean,default:!0},isDark:{type:Boolean},workerTimeoutMs:{default:1400},parseTimeoutMs:{default:1800},renderTimeoutMs:{default:2500},fullRenderTimeoutMs:{default:4e3},showHeader:{type:Boolean,default:!0},showModeToggle:{type:Boolean,default:!0},showCopyButton:{type:Boolean,default:!0},showExportButton:{type:Boolean,default:!0},showFullscreenButton:{type:Boolean,default:!0},showCollapseButton:{type:Boolean,default:!0},showZoomControls:{type:Boolean,default:!0},enableWheelZoom:{type:Boolean,default:!1},isStrict:{type:Boolean,default:!1}},emits:["copy","export","openModal","toggleMode"],setup(t,{emit:o}){var It,cn;const n=t,i=o,a={USE_PROFILES:{svg:!0},FORBID_TAGS:["script"],FORBID_ATTR:[/^on/i],ADD_TAGS:["style"],ADD_ATTR:["style"],SAFE_FOR_TEMPLATES:!0},m=e.ref(!1),u=e.computed(()=>n.isStrict?"strict":"loose"),f=e.computed(()=>({startOnLoad:!1,securityLevel:u.value,dompurifyConfig:u.value==="strict"?a:void 0,flowchart:u.value==="strict"?{htmlLabels:!1}:void 0}));function g(l){return l.replace(/["']\s*javascript:/gi,"#").replace(/\bjavascript:/gi,"#").replace(/["']\s*vbscript:/gi,"#").replace(/\bvbscript:/gi,"#").replace(/\bdata:text\/html/gi,"#")}const p=[/javascript:/i,/expression\s*\(/i,/url\s*\(\s*javascript:/i,/@import/i],k=/^(?:https?:|mailto:|tel:|#|\/|data:image\/(?:png|gif|jpe?g|webp);)/i;function x(l){if(!l)return"";const r=l.trim();return k.test(r)?r:""}function B(l){const r=new Set(["script"]),c=[l,...Array.from(l.querySelectorAll("*"))];for(const w of c){if(r.has(w.tagName.toLowerCase())){w.remove();continue}const N=Array.from(w.attributes);for(const E of N){const A=E.name;if(/^on/i.test(A)){w.removeAttribute(A);continue}if(A==="style"&&E.value){const L=E.value;if(p.some(ae=>ae.test(L))){w.removeAttribute(A);continue}}if((A==="href"||A==="xlink:href")&&E.value){const L=x(E.value);if(!L){w.removeAttribute(A);continue}L!==E.value&&w.setAttribute(A,L)}}}}function S(l){if(typeof window=="undefined"||typeof DOMParser=="undefined"||!l)return null;const r=g(l),w=new DOMParser().parseFromString(r,"image/svg+xml").documentElement;if(!w||w.nodeName.toLowerCase()!=="svg")return null;const N=w;return B(N),N}function V(l,r){if(!l)return"";try{l.replaceChildren()}catch(w){l.innerHTML=""}const c=S(r);return c?(l.appendChild(c),l.innerHTML):""}function R(l){if(l)try{l.replaceChildren()}catch(r){l.innerHTML=""}}function O(l,r){if(!l)return"";if(u.value==="strict")return V(l,r);try{l.replaceChildren()}catch(c){l.innerHTML=""}if(r)try{l.insertAdjacentHTML("afterbegin",r)}catch(c){l.innerHTML=r}return l.innerHTML}const{t:b}=_n();function Z(){return $(this,null,function*(){try{const l=yield fa();return m.value=!!l,l}catch(l){throw m.value=!1,l}})}typeof window!="undefined"&&$(null,null,function*(){var l;try{const r=yield Z();if(!r)return;(l=r==null?void 0:r.initialize)==null||l.call(r,q({},f.value))}catch(r){m.value=!1,console.warn("[markstream-vue] Failed to initialize mermaid renderer. Call enableMermaid() to configure a loader.",r)}});const ie=e.ref(!1),j=e.ref(!1),Y=e.ref(),I=e.ref(),P=e.ref(),je=e.ref(null),Re=Sn(),se=e.ref(null),F=e.ref(typeof window=="undefined"),Te=e.ref(),G=e.computed(()=>n.node.code.replace(/\]::([^:])/g,"]:::$1").replace(/:::subgraphNode$/gm,"::subgraphNode"));function ct(l,r=G.value){const c=r,N=`%%{init: {"theme": "${l==="dark"?"dark":"default"}"}}%%
|
|
2
|
+
`;return c.trim().startsWith("%%{")?c:N+c}const _=e.ref(1),K=e.ref(0),D=e.ref(0),ee=e.ref(!1),Xe=e.ref({x:0,y:0}),J=e.ref(!1),Ue=e.ref(!1),ne=e.ref(!1),he=e.ref(null),tt=e.ref(0),ut=e.ref(!1);let _e=null,Ye=null,nt=0;const kt=(It=globalThis.requestIdleCallback)!=null?It:((l,r)=>setTimeout(()=>l({didTimeout:!0}),16)),de=v(()=>{kt(()=>{sn()},{timeout:500})},Ha);function He(){Ye!=null&&(globalThis.clearTimeout(Ye),Ye=null)}function Q(l=600){if(typeof globalThis=="undefined")return;const r=Math.max(0,l);He();const c=()=>{if(Ye=null,n.loading||ne.value||!F.value){const w=Math.min(1200,Math.max(300,r*1.2));Q(w);return}de()};Ye=globalThis.setTimeout(c,r)}const U=e.ref("360px");let ge=null;const W=e.ref(!1),qe=e.ref(!1),Se=e.ref({}),Bt=e.ref(null),dt=e.ref(""),Mt=e.ref(0);let me=null;const h=e.ref(!1),y=e.ref({zoom:1,translateX:0,translateY:0,containerHeight:"360px"}),M=e.computed(()=>n.enableWheelZoom?{wheel:Oe}:{}),z=e.computed(()=>{var l,r,c,w;return{worker:(l=n.workerTimeoutMs)!=null?l:1400,parse:(r=n.parseTimeoutMs)!=null?r:1800,render:(c=n.renderTimeoutMs)!=null?c:2500,fullRender:(w=n.fullRenderTimeoutMs)!=null?w:4e3}}),fe=(cn=globalThis.cancelIdleCallback)!=null?cn:(l=>clearTimeout(l));let mt=null,jt=null,Pe=!1,Fe=800,we=null,Ke=0,ft=!0;typeof window!="undefined"&&e.watch(()=>Y.value,l=>{var c;if((c=se.value)==null||c.destroy(),se.value=null,!l){F.value=!1;return}const r=Re(l,{rootMargin:"400px"});se.value=r,F.value=r.isVisible.value,r.whenVisible.then(()=>{F.value=!0})},{immediate:!0}),e.onBeforeUnmount(()=>{var l;(l=se.value)==null||l.destroy(),se.value=null});function Ct(l,r){const c=r==null?void 0:r.timeoutMs,w=r==null?void 0:r.signal;if(w!=null&&w.aborted)return Promise.reject(new DOMException("Aborted","AbortError"));let N=null,E=!1,A=null;return new Promise((L,ae)=>{const le=()=>{N!=null&&clearTimeout(N),A&&w&&w.removeEventListener("abort",A)};c&&c>0&&(N=globalThis.setTimeout(()=>{E||(E=!0,le(),ae(new Error("Operation timed out")))},c)),w&&(A=()=>{E||(E=!0,le(),ae(new DOMException("Aborted","AbortError")))},w.addEventListener("abort",A)),l().then(Ot=>{E||(E=!0,le(),L(Ot))}).catch(Ot=>{E||(E=!0,le(),ae(Ot))})})}function ot(l){if(typeof document=="undefined"||!I.value)return;const r=document.createElement("div");r.className="text-red-500 p-4",r.textContent="Failed to render diagram: ";const c=document.createElement("span");c.textContent=l instanceof Error?l.message:"Unknown error",r.appendChild(c),R(I.value),I.value.appendChild(r),U.value="360px",h.value=!0,lt()}function Vn(l){const r=typeof l=="string"?l:typeof(l==null?void 0:l.message)=="string"?l.message:"";return typeof r=="string"&&/timed out/i.test(r)}function gn(l){const r=l;return!r||r.disabled}function oe(l,r,c="top"){if(gn(l.currentTarget))return;const w=l,N=(w==null?void 0:w.clientX)!=null&&(w==null?void 0:w.clientY)!=null?{x:w.clientX,y:w.clientY}:void 0;on(l.currentTarget,r,c,!1,N,n.isDark)}function te(){Tn()}function wn(l){if(gn(l.currentTarget))return;const r=ie.value?b("common.copied")||"Copied":b("common.copy")||"Copy",c=l,w=(c==null?void 0:c.clientX)!=null&&(c==null?void 0:c.clientY)!=null?{x:c.clientX,y:c.clientY}:void 0;on(l.currentTarget,r,"top",!1,w,n.isDark)}function rn(l,r){const w=`%%{init: {"theme": "${r==="dark"?"dark":"default"}"}}%%
|
|
3
|
+
`;return l.trimStart().startsWith("%%{")?l:w+l}function kn(){return ft&&!J.value&&!W.value&&!h.value}function yn(l){const r=l.split(/\r?\n/);for(;r.length>0;){const w=r[r.length-1].trimEnd();if(w===""){r.pop();continue}if(/^[-=~>|<\s]+$/.test(w.trim())||/(?:--|==|~~|->|<-|-\||-\)|-x|o-|\|-|\.-)\s*$/.test(w)||/[-|><]$/.test(w)||/(?:graph|flowchart|sequenceDiagram|classDiagram|stateDiagram|erDiagram|gantt)\s*$/i.test(w)){r.pop();continue}break}return r.join(`
|
|
4
|
+
`)}function xn(l,r,c){return $(this,null,function*(){var L,ae;const w=yield Z();if(!w)return;const N=w,E=rn(l,r);if(typeof N.parse=="function")return yield Ct(()=>N.parse(E),{timeoutMs:(L=c==null?void 0:c.timeoutMs)!=null?L:z.value.parse,signal:c==null?void 0:c.signal}),!0;const A=`mermaid-parse-${Math.random().toString(36).slice(2,9)}`;return yield Ct(()=>w.render(A,E),{timeoutMs:(ae=c==null?void 0:c.timeoutMs)!=null?ae:z.value.render,signal:c==null?void 0:c.signal}),!0})}function Et(l,r,c){return $(this,null,function*(){var w;try{return yield Co(l,r,(w=c==null?void 0:c.timeoutMs)!=null?w:z.value.worker)}catch(N){return yield xn(l,r,c)}})}function Ln(l,r,c){return $(this,null,function*(){var N;try{if(yield Et(l,r,c))return{fullOk:!0,prefixOk:!1}}catch(E){if((E==null?void 0:E.name)==="AbortError")throw E}let w=yn(l);if(w&&w.trim()&&w!==l)try{try{const A=yield Eo(l,r,(N=c==null?void 0:c.timeoutMs)!=null?N:z.value.worker);A&&A.trim()&&(w=A)}catch(A){}if(yield Et(w,r,c))return{fullOk:!1,prefixOk:!0,prefix:w}}catch(E){if((E==null?void 0:E.name)==="AbortError")throw E}return{fullOk:!1,prefixOk:!1}})}const Ht=e.computed(()=>J.value||ne.value||j.value);function an(l){if(!Y.value||!I.value)return;const r=I.value.querySelector("svg");if(!r)return;let c=0,w=0;const N=r.getAttribute("viewBox"),E=r.getAttribute("width"),A=r.getAttribute("height");if(N){const L=N.split(" ");L.length===4&&(c=Number.parseFloat(L[2]),w=Number.parseFloat(L[3]))}if((!c||!w)&&E&&A&&(c=Number.parseFloat(E),w=Number.parseFloat(A)),Number.isNaN(c)||Number.isNaN(w)||c<=0||w<=0)try{const L=r.getBBox();L&&L.width>0&&L.height>0&&(c=L.width,w=L.height)}catch(L){console.error("Failed to get SVG BBox:",L);return}if(c>0&&w>0){const L=w/c;let le=(l!=null?l:Y.value.clientWidth)*L;le>w&&(le=w),U.value=`${le}px`}}const Ze=e.ref(!1),Pt=e.computed(()=>({transform:`translate(${K.value}px, ${D.value}px) scale(${_.value})`}));function ln(l){l.key==="Escape"&&Ze.value&&d()}function s(){if(Ze.value=!0,typeof document!="undefined")try{document.body.style.overflow="hidden"}catch(l){}if(typeof window!="undefined")try{window.addEventListener("keydown",ln)}catch(l){}e.nextTick(()=>{if(Y.value&&P.value){const l=Y.value.cloneNode(!0);l.classList.add("fullscreen");const r=l.querySelector("[data-mermaid-wrapper]");r&&(je.value=r,r.style.transform=Pt.value.transform),R(P.value),P.value.appendChild(l)}})}function d(){if(Ze.value=!1,P.value&&R(P.value),je.value=null,typeof document!="undefined")try{document.body.style.overflow=""}catch(l){}if(typeof window!="undefined")try{window.removeEventListener("keydown",ln)}catch(l){}}function v(l,r){let c=null;return(...w)=>{c&&clearTimeout(c),c=setTimeout(()=>l(...w),r)}}function T(){if(!J.value||!m.value)return;const l=G.value.length;l!==tt.value&&(ut.value=!0,tt.value=l,_e&&clearTimeout(_e),_e=setTimeout(()=>{ut.value&&J.value&&G.value.trim()&&(ut.value=!1,Ft("preview"))},Pa))}e.watch(Pt,l=>{Ze.value&&je.value&&(je.value.style.transform=l.transform)},{immediate:!0});function C(){_.value<3&&(_.value+=.1)}function X(){_.value>.5&&(_.value-=.1)}function ke(){_.value=1,K.value=0,D.value=0}function ve(l){ee.value=!0,l instanceof MouseEvent?Xe.value={x:l.clientX-K.value,y:l.clientY-D.value}:Xe.value={x:l.touches[0].clientX-K.value,y:l.touches[0].clientY-D.value}}function ye(l){if(!ee.value)return;let r,c;l instanceof MouseEvent?(r=l.clientX,c=l.clientY):(r=l.touches[0].clientX,c=l.touches[0].clientY),K.value=r-Xe.value.x,D.value=c-Xe.value.y}function re(){ee.value=!1}function Oe(l){if(n.enableWheelZoom&&(l.ctrlKey||l.metaKey)){if(l.preventDefault(),!Y.value)return;const r=Y.value.getBoundingClientRect(),c=l.clientX-r.left,w=l.clientY-r.top,N=r.width/2,E=r.height/2,A=c-N,L=w-E,ae=(A-K.value)/_.value,le=(L-D.value)/_.value,zo=-l.deltaY*.01,Bn=Math.min(Math.max(_.value+zo,.5),3);Bn!==_.value&&(K.value=A-ae*Bn,D.value=L-le*Bn,_.value=Bn)}}function Nt(){return $(this,null,function*(){try{typeof navigator!="undefined"&&navigator.clipboard&&typeof navigator.clipboard.writeText=="function"&&(yield navigator.clipboard.writeText(G.value)),ie.value=!0,i("copy",G.value),setTimeout(()=>{ie.value=!1},1e3)}catch(l){console.error("Failed to copy:",l)}})}function pt(l,r=null){return $(this,null,function*(){try{const c=r!=null?r:new XMLSerializer().serializeToString(l),w=new Blob([c],{type:"image/svg+xml;charset=utf-8"}),N=URL.createObjectURL(w);if(typeof document!="undefined"){const E=document.createElement("a");E.href=N,E.download=`mermaid-diagram-${Date.now()}.svg`;try{document.body.appendChild(E),E.click(),document.body.removeChild(E)}catch(A){}URL.revokeObjectURL(N)}}catch(c){console.error("Failed to export SVG:",c)}})}function rt(){var w;const l=(w=I.value)==null?void 0:w.querySelector("svg");if(!l){console.error("SVG element not found");return}const r=new XMLSerializer().serializeToString(l),c={payload:{type:"export"},defaultPrevented:!1,preventDefault(){this.defaultPrevented=!0},svgElement:l,svgString:r};i("export",c),c.defaultPrevented||pt(l,r)}function Tt(){var w,N;const l=(N=(w=I.value)==null?void 0:w.querySelector("svg"))!=null?N:null,r=l?new XMLSerializer().serializeToString(l):null,c={payload:{type:"open-modal"},defaultPrevented:!1,preventDefault(){this.defaultPrevented=!0},svgElement:l,svgString:r};i("openModal",c),c.defaultPrevented||s()}function _t(l){const r={payload:{type:"toggle-mode",target:l},defaultPrevented:!1,preventDefault(){this.defaultPrevented=!0}};i("toggleMode",l,r),r.defaultPrevented||Ft(l)}function Ft(l){return $(this,null,function*(){const r=Te.value;if(!r){Ue.value=!0,J.value=l==="source";return}const c=r.getBoundingClientRect().height;r.style.height=`${c}px`,r.style.overflow="hidden",Ue.value=!0,J.value=l==="source",yield e.nextTick();const w=r.scrollHeight;r.style.transition="height 180ms ease",r.offsetHeight,r.style.height=`${w}px`;const N=()=>{r.style.transition="",r.style.height="",r.style.overflow="",r.removeEventListener("transitionend",E)};function E(){N()}r.addEventListener("transitionend",E),setTimeout(()=>N(),220)})}function at(){return $(this,null,function*(){if(ne.value)return he.value;if(!I.value&&(yield e.nextTick(),!I.value)){console.warn("Mermaid container not ready");return}return ne.value=!0,he.value=$(null,null,function*(){var l;I.value&&(I.value.style.opacity="0");try{const r=yield Z();if(!r)return;const c=`mermaid-${Date.now()}-${Math.random().toString(36).substring(2,11)}`;!W.value&&!qe.value&&((l=r.initialize)==null||l.call(r,ht(q({},f.value),{dompurifyConfig:q({},a)})));const w=n.isDark?"dark":"light",N=ct(w),E=yield Ct(()=>r.render(c,N),{timeoutMs:z.value.fullRender}),A=E==null?void 0:E.svg;if(I.value){const L=O(I.value,A);!W.value&&!qe.value&&(an(),W.value=!0,y.value={zoom:_.value,translateX:K.value,translateY:D.value,containerHeight:U.value});const ae=n.isDark?"dark":"light";L&&(Se.value[ae]=L),qe.value&&(qe.value=!1),h.value=!1,nt=0,He()}}catch(r){const c=Vn(r),w=nt+1;if(c&&w<=Fa){nt=w;const N=Math.min(1200,600*w);Q(N)}else nt=0,He(),console.error("Failed to render mermaid diagram:",r),n.loading===!1&&ot(r)}finally{yield e.nextTick(),I.value&&(I.value.style.opacity="1"),ne.value=!1,he.value=null}}),he.value})}function bn(l){return $(this,null,function*(){if(kn()&&!(!I.value&&(yield e.nextTick(),!I.value))&&!ne.value){ne.value=!0;try{const r=yield Z();if(!r)return;const c=`mermaid-partial-${Date.now()}-${Math.random().toString(36).slice(2,9)}`,w=n.isDark?"dark":"light",N=yn(l),E=N&&N.trim()?N:l,A=rn(E,w);I.value&&(I.value.style.opacity="0");const L=yield Ct(()=>r.render(c,A),{timeoutMs:z.value.render}),ae=L==null?void 0:L.svg;I.value&&ae&&(O(I.value,ae),an())}catch(r){}finally{yield e.nextTick(),I.value&&(I.value.style.opacity="1"),ne.value=!1}}})}function sn(){return $(this,null,function*(){var L,ae;const l=Date.now(),r=++Mt.value;me&&me.abort(),me=new AbortController;const c=me.signal,w=n.isDark?"dark":"light",N=G.value,E=N.replace(/\s+/g,"");if(!N.trim()){I.value&&R(I.value),Bt.value=null,dt.value="",h.value=!1;return}if(E===dt.value)return;try{const le=yield Ln(N,w,{signal:c,timeoutMs:z.value.worker});if(le.fullOk){yield at(),Mt.value===r&&(Bt.value=(ae=(L=I.value)==null?void 0:L.innerHTML)!=null?ae:null,dt.value=E,h.value=!1);return}const Ot=Ke&&l<=Ke;if(le.prefixOk&&le.prefix&&kn()&&!Ot){yield bn(le.prefix);return}}catch(le){if((le==null?void 0:le.name)==="AbortError")return}if(Mt.value!==r||h.value)return;const A=Se.value[w];A&&I.value&&O(I.value,A)})}function lt(){Pe&&(Pe=!1,Fe=800,ft=!1,we&&(we.abort(),we=null),mt&&(globalThis.clearTimeout(mt),mt=null),jt&&(fe(jt),jt=null),Ke=Date.now())}function St(){if(lt(),me){try{me.abort()}catch(l){}me=null}if(we){try{we.abort()}catch(l){}we=null}Pn(),He(),nt=0}function Kt(l=800){Pe&&(mt&&globalThis.clearTimeout(mt),mt=globalThis.setTimeout(()=>{jt=kt(()=>$(null,null,function*(){if(!Pe)return;if(J.value||W.value){lt();return}const r=n.isDark?"dark":"light",c=G.value;if(!c.trim()){Kt(Fe);return}we&&we.abort(),we=new AbortController;try{if((yield Et(c,r,{signal:we.signal,timeoutMs:z.value.worker}))&&(yield at(),W.value)){lt();return}}catch(w){}Fe=Math.min(Math.floor(Fe*1.5),4e3),Kt(Fe)}),{timeout:500})},l))}function Ge(){Pe||J.value||W.value||(Pe=!0,Ke=0,ft=!0,Kt(500))}e.watch(()=>G.value,()=>{W.value=!1,Se.value={},de(),!J.value&&m.value&&Ge(),T()}),e.watch(()=>n.isDark,()=>$(null,null,function*(){if(!W.value||h.value)return;const l=n.isDark?"dark":"light",r=Se.value[l];if(r){I.value&&O(I.value,r);return}const c={zoom:_.value,translateX:K.value,translateY:D.value,containerHeight:U.value},w=_.value!==1||K.value!==0||D.value!==0;qe.value=!0,w&&(_.value=1,K.value=0,D.value=0,yield e.nextTick()),yield at(),w&&(yield e.nextTick(),_.value=c.zoom,K.value=c.translateX,D.value=c.translateY,U.value=c.containerHeight,y.value=c)})),e.watch(()=>J.value,l=>$(null,null,function*(){if(l)lt(),W.value&&(y.value={zoom:_.value,translateX:K.value,translateY:D.value,containerHeight:U.value});else{if(h.value)return;const r=n.isDark?"dark":"light";if(W.value&&Se.value[r]){yield e.nextTick(),I.value&&O(I.value,Se.value[r]),_.value=y.value.zoom,K.value=y.value.translateX,D.value=y.value.translateY,U.value=y.value.containerHeight;return}if(yield e.nextTick(),!m.value)return;yield sn(),Ge()}})),e.watch(()=>n.loading,(l,r)=>$(null,null,function*(){if(r===!0&&l===!1){const c=G.value.trim();if(!c)return St();const w=n.isDark?"dark":"light",N=c.replace(/\s+/g,"");if(W.value&&N===dt.value){yield e.nextTick(),I.value&&!I.value.querySelector("svg")&&Se.value[w]&&O(I.value,Se.value[w]),St();return}try{yield Et(c,w,{timeoutMs:z.value.worker}),yield at(),dt.value=N,h.value=!1,St()}catch(E){St(),ot(E)}}})),e.watch(Y,l=>{ge&&ge.disconnect(),l&&!W.value&&!qe.value&&(ge=new ResizeObserver(r=>{r&&r.length>0&&!W.value&&!qe.value&&yo(()=>{const c=r[0].contentRect.width;an(c)})}),ge.observe(l))},{immediate:!0}),e.onMounted(()=>$(null,null,function*(){yield e.nextTick(),Ue.value||(J.value=!m.value),F.value&&(de(),tt.value=G.value.length)})),e.watch(()=>m.value,l=>{Ue.value||(J.value=!l)}),e.watch(()=>F.value,l=>{l&&(W.value||(de(),tt.value=G.value.length),!n.loading&&!W.value&&de())},{immediate:!1}),e.onUnmounted(()=>{_e&&clearTimeout(_e),ge&&ge.disconnect(),me&&(me.abort(),me=null),Pn(),lt(),He()}),e.watch(()=>j.value,l=>$(null,null,function*(){l?(lt(),me&&me.abort()):W.value||(yield e.nextTick(),de(),J.value||Ge())}),{immediate:!1});const Je=e.computed(()=>n.isDark?"mermaid-action-btn p-2 text-xs rounded text-gray-400 hover:bg-gray-700 hover:text-gray-200":"mermaid-action-btn p-2 text-xs rounded text-gray-600 hover:bg-gray-200 hover:text-gray-700");return(l,r)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["my-4 rounded-lg border overflow-hidden shadow-sm",[n.isDark?"border-gray-700/30":"border-gray-200",{"is-rendering":n.loading}]])},[n.showHeader?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["mermaid-block-header flex justify-between items-center px-4 py-2.5 border-b",n.isDark?"bg-gray-800 border-gray-700/30":"bg-gray-50 border-gray-200"])},[l.$slots["header-left"]?(e.openBlock(),e.createElementBlock("div",xa,[e.renderSlot(l.$slots,"header-left",{},void 0,!0)])):(e.openBlock(),e.createElementBlock("div",ba,[e.createElementVNode("img",{src:e.unref(ia),class:"w-4 h-4 my-0",alt:"Mermaid"},null,8,Ba),e.createElementVNode("span",{class:e.normalizeClass(["text-sm font-medium font-mono truncate",n.isDark?"text-gray-400":"text-gray-600"])},"Mermaid",2)])),l.$slots["header-center"]?(e.openBlock(),e.createElementBlock("div",Ma,[e.renderSlot(l.$slots,"header-center",{},void 0,!0)])):n.showModeToggle&&m.value?(e.openBlock(),e.createElementBlock("div",{key:3,class:e.normalizeClass(["flex items-center space-x-1 rounded-md p-0.5",n.isDark?"bg-gray-700":"bg-gray-100"])},[e.createElementVNode("button",{class:e.normalizeClass(["px-2.5 py-1 text-xs rounded transition-colors",[J.value?n.isDark?"text-gray-400 hover:text-gray-200":"text-gray-500 hover:text-gray-700":n.isDark?"bg-gray-600 text-gray-200 shadow-sm":"bg-white text-gray-700 shadow-sm"]]),onClick:r[0]||(r[0]=()=>_t("preview")),onMouseenter:r[1]||(r[1]=c=>oe(c,e.unref(b)("common.preview")||"Preview")),onFocus:r[2]||(r[2]=c=>oe(c,e.unref(b)("common.preview")||"Preview")),onMouseleave:te,onBlur:te},[e.createElementVNode("div",Ca,[r[21]||(r[21]=e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},[e.createElementVNode("g",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2"},[e.createElementVNode("path",{d:"M2.062 12.348a1 1 0 0 1 0-.696a10.75 10.75 0 0 1 19.876 0a1 1 0 0 1 0 .696a10.75 10.75 0 0 1-19.876 0"}),e.createElementVNode("circle",{cx:"12",cy:"12",r:"3"})])],-1)),e.createElementVNode("span",null,e.toDisplayString(e.unref(b)("common.preview")||"Preview"),1)])],34),e.createElementVNode("button",{class:e.normalizeClass(["px-2.5 py-1 text-xs rounded transition-colors",[J.value?n.isDark?"bg-gray-600 text-gray-200 shadow-sm":"bg-white text-gray-700 shadow-sm":n.isDark?"text-gray-400 hover:text-gray-200":"text-gray-500 hover:text-gray-700"]]),onClick:r[3]||(r[3]=()=>_t("source")),onMouseenter:r[4]||(r[4]=c=>oe(c,e.unref(b)("common.source")||"Source")),onFocus:r[5]||(r[5]=c=>oe(c,e.unref(b)("common.source")||"Source")),onMouseleave:te,onBlur:te},[e.createElementVNode("div",Ea,[r[22]||(r[22]=e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},[e.createElementVNode("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m16 18l6-6l-6-6M8 6l-6 6l6 6"})],-1)),e.createElementVNode("span",null,e.toDisplayString(e.unref(b)("common.source")||"Source"),1)])],34)],2)):e.createCommentVNode("",!0),l.$slots["header-right"]?(e.openBlock(),e.createElementBlock("div",Na,[e.renderSlot(l.$slots,"header-right",{},void 0,!0)])):(e.openBlock(),e.createElementBlock("div",Ta,[n.showCollapseButton?(e.openBlock(),e.createElementBlock("button",{key:0,class:e.normalizeClass(Je.value),"aria-pressed":j.value,onClick:r[6]||(r[6]=c=>j.value=!j.value),onMouseenter:r[7]||(r[7]=c=>oe(c,j.value?e.unref(b)("common.expand")||"Expand":e.unref(b)("common.collapse")||"Collapse")),onFocus:r[8]||(r[8]=c=>oe(c,j.value?e.unref(b)("common.expand")||"Expand":e.unref(b)("common.collapse")||"Collapse")),onMouseleave:te,onBlur:te},[(e.openBlock(),e.createElementBlock("svg",{style:e.normalizeStyle({rotate:j.value?"0deg":"90deg"}),xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},[...r[23]||(r[23]=[e.createElementVNode("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m9 18l6-6l-6-6"},null,-1)])],4))],42,_a)):e.createCommentVNode("",!0),n.showCopyButton?(e.openBlock(),e.createElementBlock("button",{key:1,class:e.normalizeClass(Je.value),onClick:Nt,onMouseenter:r[9]||(r[9]=c=>wn(c)),onFocus:r[10]||(r[10]=c=>wn(c)),onMouseleave:te,onBlur:te},[ie.value?(e.openBlock(),e.createElementBlock("svg",Ia,[...r[25]||(r[25]=[e.createElementVNode("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M20 6L9 17l-5-5"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",Sa,[...r[24]||(r[24]=[e.createElementVNode("g",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2"},[e.createElementVNode("rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2"}),e.createElementVNode("path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"})],-1)])]))],34)):e.createCommentVNode("",!0),n.showExportButton&&m.value?(e.openBlock(),e.createElementBlock("button",{key:2,class:e.normalizeClass(`${Je.value} ${Ht.value?"opacity-50 cursor-not-allowed":""}`),disabled:Ht.value,onClick:rt,onMouseenter:r[11]||(r[11]=c=>oe(c,e.unref(b)("common.export")||"Export")),onFocus:r[12]||(r[12]=c=>oe(c,e.unref(b)("common.export")||"Export")),onMouseleave:te,onBlur:te},[...r[26]||(r[26]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},[e.createElementVNode("g",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2"},[e.createElementVNode("path",{d:"M12 15V3m9 12v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"}),e.createElementVNode("path",{d:"m7 10l5 5l5-5"})])],-1)])],42,$a)):e.createCommentVNode("",!0),n.showFullscreenButton&&m.value?(e.openBlock(),e.createElementBlock("button",{key:3,class:e.normalizeClass(`${Je.value} ${Ht.value?"opacity-50 cursor-not-allowed":""}`),disabled:Ht.value,onClick:Tt,onMouseenter:r[13]||(r[13]=c=>oe(c,Ze.value?e.unref(b)("common.minimize")||"Minimize":e.unref(b)("common.open")||"Open")),onFocus:r[14]||(r[14]=c=>oe(c,Ze.value?e.unref(b)("common.minimize")||"Minimize":e.unref(b)("common.open")||"Open")),onMouseleave:te,onBlur:te},[Ze.value?(e.openBlock(),e.createElementBlock("svg",Da,[...r[28]||(r[28]=[e.createElementVNode("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m14 10l7-7m-1 7h-6V4M3 21l7-7m-6 0h6v6"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",La,[...r[27]||(r[27]=[e.createElementVNode("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M15 3h6v6m0-6l-7 7M3 21l7-7m-1 7H3v-6"},null,-1)])]))],42,Va)):e.createCommentVNode("",!0)]))],2)):e.createCommentVNode("",!0),e.withDirectives(e.createElementVNode("div",{ref_key:"modeContainerRef",ref:Te},[J.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["p-4",n.isDark?"bg-gray-900":"bg-gray-50"])},[e.createElementVNode("pre",{class:e.normalizeClass(["text-sm font-mono whitespace-pre-wrap",n.isDark?"text-gray-300":"text-gray-700"])},e.toDisplayString(G.value),3)],2)):(e.openBlock(),e.createElementBlock("div",Ra,[n.showZoomControls?(e.openBlock(),e.createElementBlock("div",za,[e.createElementVNode("div",Aa,[e.createElementVNode("button",{class:e.normalizeClass(["p-2 text-xs rounded transition-colors",[n.isDark?"text-gray-400 hover:bg-gray-700":"text-gray-600 hover:bg-gray-200"]]),onClick:C,onMouseenter:r[15]||(r[15]=c=>oe(c,e.unref(b)("common.zoomIn")||"Zoom in")),onFocus:r[16]||(r[16]=c=>oe(c,e.unref(b)("common.zoomIn")||"Zoom in")),onMouseleave:te,onBlur:te},[...r[29]||(r[29]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},[e.createElementVNode("g",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2"},[e.createElementVNode("circle",{cx:"11",cy:"11",r:"8"}),e.createElementVNode("path",{d:"m21 21l-4.35-4.35M11 8v6m-3-3h6"})])],-1)])],34),e.createElementVNode("button",{class:e.normalizeClass(["p-2 text-xs rounded transition-colors",[n.isDark?"text-gray-400 hover:bg-gray-700":"text-gray-600 hover:bg-gray-200"]]),onClick:X,onMouseenter:r[17]||(r[17]=c=>oe(c,e.unref(b)("common.zoomOut")||"Zoom out")),onFocus:r[18]||(r[18]=c=>oe(c,e.unref(b)("common.zoomOut")||"Zoom out")),onMouseleave:te,onBlur:te},[...r[30]||(r[30]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},[e.createElementVNode("g",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2"},[e.createElementVNode("circle",{cx:"11",cy:"11",r:"8"}),e.createElementVNode("path",{d:"m21 21l-4.35-4.35M8 11h6"})])],-1)])],34),e.createElementVNode("button",{class:e.normalizeClass(["p-2 text-xs rounded transition-colors",[n.isDark?"text-gray-400 hover:bg-gray-700":"text-gray-600 hover:bg-gray-200"]]),onClick:ke,onMouseenter:r[19]||(r[19]=c=>oe(c,e.unref(b)("common.resetZoom")||"Reset zoom")),onFocus:r[20]||(r[20]=c=>oe(c,e.unref(b)("common.resetZoom")||"Reset zoom")),onMouseleave:te,onBlur:te},e.toDisplayString(Math.round(_.value*100))+"% ",35)])])):e.createCommentVNode("",!0),e.createElementVNode("div",e.mergeProps({ref_key:"mermaidContainer",ref:Y,class:["min-h-[360px] relative transition-all duration-100 overflow-hidden block",n.isDark?"bg-gray-900":"bg-gray-50"],style:{height:U.value}},e.toHandlers(M.value,!0),{onMousedown:ve,onMousemove:ye,onMouseup:re,onMouseleave:re,onTouchstartPassive:ve,onTouchmovePassive:ye,onTouchendPassive:re}),[e.createElementVNode("div",{"data-mermaid-wrapper":"",class:e.normalizeClass(["absolute inset-0 cursor-grab",{"cursor-grabbing":ee.value}]),style:e.normalizeStyle(Pt.value)},[e.createElementVNode("div",{ref_key:"mermaidContent",ref:I,class:"_mermaid w-full text-center flex items-center justify-center min-h-full"},null,512)],6)],16),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mermaid-dialog",appear:""},{default:e.withCtx(()=>[Ze.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"fixed inset-0 z-50 flex items-center justify-center bg-black/70 p-4",onClick:e.withModifiers(d,["self"])},[e.createElementVNode("div",{class:e.normalizeClass(["dialog-panel relative w-full h-full max-w-full max-h-full rounded shadow-lg overflow-hidden",n.isDark?"bg-gray-900":"bg-white"])},[e.createElementVNode("div",ja,[e.createElementVNode("button",{class:e.normalizeClass(["p-2 text-xs rounded transition-colors",[n.isDark?"text-gray-400 hover:bg-gray-700":"text-gray-600 hover:bg-gray-200"]]),onClick:C},[...r[31]||(r[31]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},[e.createElementVNode("g",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2"},[e.createElementVNode("circle",{cx:"11",cy:"11",r:"8"}),e.createElementVNode("path",{d:"m21 21l-4.35-4.35M11 8v6m-3-3h6"})])],-1)])],2),e.createElementVNode("button",{class:e.normalizeClass(["p-2 text-xs rounded transition-colors",[n.isDark?"text-gray-400 hover:bg-gray-700":"text-gray-600 hover:bg-gray-200"]]),onClick:X},[...r[32]||(r[32]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},[e.createElementVNode("g",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2"},[e.createElementVNode("circle",{cx:"11",cy:"11",r:"8"}),e.createElementVNode("path",{d:"m21 21l-4.35-4.35M8 11h6"})])],-1)])],2),e.createElementVNode("button",{class:e.normalizeClass(["p-2 text-xs rounded transition-colors",[n.isDark?"text-gray-400 hover:bg-gray-700":"text-gray-600 hover:bg-gray-200"]]),onClick:ke},e.toDisplayString(Math.round(_.value*100))+"% ",3),e.createElementVNode("button",{class:e.normalizeClass(["inline-flex items-center justify-center p-2 rounded transition-colors",[n.isDark?"text-gray-400 hover:bg-gray-700":"text-gray-600 hover:bg-gray-200"]]),onClick:d},[...r[33]||(r[33]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},[e.createElementVNode("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M18 6L6 18M6 6l12 12"})],-1)])],2)]),e.createElementVNode("div",e.mergeProps({ref_key:"modalContent",ref:P,class:"w-full h-full flex items-center justify-center p-4 overflow-hidden"},e.toHandlers(M.value,!0),{onMousedown:ve,onMousemove:ye,onMouseup:re,onMouseleave:re,onTouchstartPassive:ve,onTouchmovePassive:ye,onTouchendPassive:re}),null,16)],2)])):e.createCommentVNode("",!0)]),_:1})]))]))],512),[[e.vShow,!j.value]])],2))}}),Dt=H(Ka,[["__scopeId","data-v-3636e700"]]);Dt.install=t=>{t.component(Dt.__name,Dt)};const Oa=e.defineComponent({__name:"HtmlInlineNode",props:{node:{}},setup(t){const o=t,n=e.ref(null),i=typeof window!="undefined";function a(){if(!i||!n.value)return;const u=n.value;u.innerHTML="";const f=document.createElement("template");f.innerHTML=o.node.content,u.appendChild(f.content.cloneNode(!0))}function m(){if(!n.value)return;const u=n.value;u.innerHTML="",u.textContent=o.node.content}return e.onMounted(()=>{o.node.loading?m():a()}),e.watch(()=>[o.node.content,o.node.loading],()=>{o.node.loading?m():a()}),e.onBeforeUnmount(()=>{n.value&&(n.value.innerHTML="")}),(u,f)=>(e.openBlock(),e.createElementBlock("span",{ref_key:"containerRef",ref:n,class:e.normalizeClass(["html-inline-node",{"html-inline-node--loading":o.node.loading}])},null,2))}}),Rt=H(Oa,[["__scopeId","data-v-ce01f326"]]);Rt.install=t=>{t.component(Rt.__name,Rt)};const Wa={dir:"auto",class:"paragraph-node"},Xa=e.defineComponent({__name:"ParagraphNode",props:{node:{},customId:{},indexKey:{}},setup(t){const o=t,n=et(o.customId),i=q({inline_code:Be,image:wt,link:Ne,hardbreak:yt,emphasis:Ae,strong:Ce,strikethrough:Ee,highlight:De,insert:Le,subscript:Ve,superscript:$e,html_inline:Rt,emoji:xe,checkbox:Qe,math_inline:st,checkbox_input:Qe,reference:Me,footnote_anchor:Lt,footnote_reference:be},n),a=ko();return(m,u)=>(e.openBlock(),e.createElementBlock("p",Wa,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.node.children,(f,g)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:`${t.indexKey||"paragraph"}-${g}`},[f.type!=="text"?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i[f.type]),{key:0,node:f,"index-key":`${t.indexKey}-${g}`,"custom-id":o.customId},null,8,["node","index-key","custom-id"])):(e.openBlock(),e.createElementBlock("span",{key:1,class:e.normalizeClass([[e.unref(a)&&f.center?"text-node-center":""],"whitespace-pre-wrap break-words text-node"])},e.toDisplayString(f.content),3))],64))),128))]))}}),Qt=H(Xa,[["__scopeId","data-v-0117537a"]]);Qt.install=t=>{t.component(Qt.__name,Qt)};const Ua=["aria-busy","aria-label","data-language"],Ya=["textContent"],zt=e.defineComponent({__name:"PreCodeNode",props:{node:{}},setup(t){const o=t,n=e.computed(()=>{var g,p,k;const m=String((p=(g=o.node)==null?void 0:g.language)!=null?p:"");return String((k=String(m).split(/\s+/g)[0])!=null?k:"").toLowerCase().replace(/[^\w-]/g,"")||"plaintext"}),i=e.computed(()=>`language-${n.value}`),a=e.computed(()=>{const m=n.value;return m?`Code block: ${m}`:"Code block"});return(m,u)=>(e.openBlock(),e.createElementBlock("pre",{class:e.normalizeClass([i.value]),"aria-busy":t.node.loading===!0,"aria-label":a.value,"data-language":n.value,tabindex:"0"},[e.createElementVNode("code",{translate:"no",textContent:e.toDisplayString(t.node.code)},null,8,Ya)],10,Ua))}});zt.install=t=>{t.component(zt.__name,zt)};const qa={class:"table-node-wrapper"},Za=["aria-busy"],Ga={class:"border-[var(--table-border,#cbd5e1)]"},Ja={class:"border-b"},Qa={key:0,class:"table-node__loading",role:"status","aria-live":"polite"},el=e.defineComponent({__name:"TableNode",props:{node:{},indexKey:{},isDark:{type:Boolean},typewriter:{type:Boolean},customId:{}},emits:["copy"],setup(t){const o=t,n=e.computed(()=>{var u,f,g,p;return(p=(g=(f=(u=o.node)==null?void 0:u.header)==null?void 0:f.cells)==null?void 0:g.length)!=null?p:0}),i=e.computed(()=>{const u=n.value||1,f=Math.floor(100/u);return Array.from({length:u}).map((g,p)=>p===u-1?`${100-f*(u-1)}%`:`${f}%`)}),a=e.computed(()=>{var u;return(u=o.node.loading)!=null?u:!1}),m=e.computed(()=>{var u;return(u=o.node.rows)!=null?u:[]});return(u,f)=>(e.openBlock(),e.createElementBlock("div",qa,[e.createElementVNode("table",{class:e.normalizeClass(["w-full my-8 text-sm table-fixed table-node",{"table-node--loading":a.value}]),"aria-busy":a.value},[e.createElementVNode("colgroup",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(g,p)=>(e.openBlock(),e.createElementBlock("col",{key:`col-${p}`,style:e.normalizeStyle({width:g})},null,4))),128))]),e.createElementVNode("thead",Ga,[e.createElementVNode("tr",Ja,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.node.header.cells,(g,p)=>(e.openBlock(),e.createElementBlock("th",{key:`header-${p}`,dir:"auto",class:e.normalizeClass(["font-semibold p-[calc(4/7*1em)] overflow-x-auto",[g.align==="right"?"text-right":g.align==="center"?"text-center":"text-left"]])},[e.createVNode(e.unref(ze),{nodes:g.children,"index-key":`table-th-${o.indexKey}`,"custom-id":o.customId,typewriter:o.typewriter,onCopy:f[0]||(f[0]=k=>u.$emit("copy",k))},null,8,["nodes","index-key","custom-id","typewriter"])],2))),128))])]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(g,p)=>(e.openBlock(),e.createElementBlock("tr",{key:`row-${p}`,class:e.normalizeClass(["border-[var(--table-border,#cbd5e1)]",[p<m.value.length-1?"border-b":""]])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.cells,(k,x)=>(e.openBlock(),e.createElementBlock("td",{key:`cell-${p}-${x}`,class:e.normalizeClass(["p-[calc(4/7*1em)] overflow-x-auto",[k.align==="right"?"text-right":k.align==="center"?"text-center":"text-left"]]),dir:"auto"},[e.createVNode(e.unref(ze),{nodes:k.children,"index-key":`table-td-${o.indexKey}`,"custom-id":o.customId,typewriter:o.typewriter,onCopy:f[1]||(f[1]=B=>u.$emit("copy",B))},null,8,["nodes","index-key","custom-id","typewriter"])],2))),128))],2))),128))])],10,Za),e.createVNode(e.Transition,{name:"table-node-fade"},{default:e.withCtx(()=>[a.value?(e.openBlock(),e.createElementBlock("div",Qa,[e.renderSlot(u.$slots,"loading",{isLoading:a.value},()=>[f[2]||(f[2]=e.createElementVNode("span",{class:"table-node__spinner animate-spin","aria-hidden":"true"},null,-1)),f[3]||(f[3]=e.createElementVNode("span",{class:"sr-only"},"Loading",-1))],!0)])):e.createCommentVNode("",!0)]),_:3})]))}}),en=H(el,[["__scopeId","data-v-a874491c"]]);en.install=t=>{t.component(en.__name,en)};const tl={},nl={class:"hr-node"};function ol(t,o){return e.openBlock(),e.createElementBlock("hr",nl)}const tn=H(tl,[["render",ol],["__scopeId","data-v-639cbad9"]]);tn.install=t=>{t.component(tn.__name,tn)};const rl={key:1,class:"html-block-node__placeholder"},al=e.defineComponent({__name:"HtmlBlockNode",props:{node:{}},setup(t){const o=t,n=e.computed(()=>{const p=o.node.attrs;if(p){if(Array.isArray(p)){const k={};for(const x of p){if(!x||x.length<2)continue;const[B,S]=x;B!=null&&(k[String(B)]=S==null?"":String(S))}return k}return p}}),i=e.ref(null),a=e.ref(typeof window=="undefined"),m=e.ref(o.node.content),u=Sn(),f=e.ref(null),g=!!o.node.loading;return typeof window!="undefined"?(e.watch(i,p=>{var x,B;if((B=(x=f.value)==null?void 0:x.destroy)==null||B.call(x),f.value=null,!g){a.value=!0,m.value=o.node.content;return}if(!p){a.value=!1;return}const k=u(p,{rootMargin:"400px"});f.value=k,a.value=k.isVisible.value,k.whenVisible.then(()=>{a.value=!0})},{immediate:!0}),e.watch(()=>o.node.content,p=>{(!g||a.value)&&(m.value=p)})):a.value=!0,e.onBeforeUnmount(()=>{var p,k;(k=(p=f.value)==null?void 0:p.destroy)==null||k.call(p),f.value=null}),(p,k)=>(e.openBlock(),e.createElementBlock("div",e.mergeProps({ref_key:"htmlRef",ref:i,class:"html-block-node"},n.value),[a.value?e.withMemo([m.value],()=>(e.openBlock(),e.createElementBlock("div",{key:0,innerHTML:m.value},null,8,["innerHTML"])),k,0):(e.openBlock(),e.createElementBlock("div",rl,[e.renderSlot(p.$slots,"placeholder",{node:t.node},()=>[k[1]||(k[1]=e.createElementVNode("span",{class:"html-block-node__placeholder-bar"},null,-1)),k[2]||(k[2]=e.createElementVNode("span",{class:"html-block-node__placeholder-bar w-4/5"},null,-1)),k[3]||(k[3]=e.createElementVNode("span",{class:"html-block-node__placeholder-bar w-2/3"},null,-1))],!0)]))],16))}}),ll=H(al,[["__scopeId","data-v-ed22b926"]]),il={class:"unknown-node"},ro=e.defineComponent({__name:"FallbackComponent",props:{node:{}},setup(t){return(o,n)=>(e.openBlock(),e.createElementBlock("div",il,e.toDisplayString(t.node.raw),1))}}),sl=["data-node-index","data-node-type"],cl=900,ul=640,dl=200,ml=1800,fl=e.defineComponent({__name:"NodeRenderer",props:{content:{},nodes:{},parseOptions:{},customMarkdownIt:{},viewportPriority:{type:Boolean},codeBlockStream:{type:Boolean,default:!0},codeBlockDarkTheme:{},codeBlockLightTheme:{},codeBlockMonacoOptions:{},renderCodeBlocksAsPre:{type:Boolean},codeBlockMinWidth:{},codeBlockMaxWidth:{},codeBlockProps:{},themes:{},isDark:{type:Boolean},customId:{},indexKey:{},typewriter:{type:Boolean,default:!0},batchRendering:{type:Boolean,default:!0},initialRenderBatchSize:{default:40},renderBatchSize:{default:80},renderBatchDelay:{default:16},renderBatchBudgetMs:{default:6},renderBatchIdleTimeoutMs:{default:120},deferNodesUntilVisible:{type:Boolean,default:!0},maxLiveNodes:{default:320},liveNodeBuffer:{default:60}},emits:["copy","handleArtifactClick","click","mouseover","mouseout"],setup(t,{emit:o}){var Ze,Pt,ln;const n=t,i=o,a=e.ref(),m=e.ref(!1),u=/auto|scroll|overlay/i;function f(s){if(typeof window=="undefined")return null;const d=s!=null?s:a.value;if(!d)return null;const v=d.ownerDocument||document,T=v.scrollingElement||v.documentElement;let C=d;for(;C&&!(C===v.body||C===T);){const X=window.getComputedStyle(C),ke=(X.overflowY||"").toLowerCase(),ve=(X.overflow||"").toLowerCase();if(u.test(ke)||u.test(ve))return C;C=C.parentElement}return null}const g=An.getMarkdown(),p=e.computed(()=>n.customMarkdownIt?n.customMarkdownIt(g):g),k=e.computed(()=>{var s;if((s=n.nodes)!=null&&s.length)return e.markRaw(n.nodes.slice());if(n.content){const d=An.parseMarkdownToStructure(n.content,p.value,n.parseOptions);return e.markRaw(d)}return[]}),x=e.computed(()=>{var s;return Math.max(1,(s=n.maxLiveNodes)!=null?s:320)}),B=e.computed(()=>{var s;return((s=n.maxLiveNodes)!=null?s:0)<=0?!1:k.value.length>x.value}),S=e.computed(()=>!(n.viewportPriority===!1||m.value||n.deferNodesUntilVisible===!1||B.value||k.value.length>cl)),V=vr(s=>{var d;return f((d=s!=null?s:a.value)!=null?d:null)},S),R=typeof window!="undefined",O=R&&typeof window.requestAnimationFrame=="function"?window.requestAnimationFrame.bind(window):null,b=R&&typeof window.cancelAnimationFrame=="function"?window.cancelAnimationFrame.bind(window):null,Z=typeof globalThis!="undefined"&&typeof globalThis.process!="undefined"&&((Pt=(Ze=globalThis.process)==null?void 0:Ze.env)==null?void 0:Pt.NODE_ENV)==="test",ie=R&&typeof window.requestIdleCallback=="function",j=e.computed(()=>{var d;const s=Math.trunc((d=n.renderBatchSize)!=null?d:80);return Number.isFinite(s)?Math.max(0,s):0}),Y=e.computed(()=>{var d;const s=Math.trunc((d=n.initialRenderBatchSize)!=null?d:j.value);return Number.isFinite(s)?Math.max(0,s):j.value}),I=e.computed(()=>n.batchRendering!==!1&&j.value>0&&R&&!Z),P=e.ref(0),je=e.ref({key:n.indexKey,total:0}),Re=e.ref(Math.max(1,j.value||1)),se=e.reactive({}),F=new Map,Te=new Map,G=new Map,ct=e.ref(null);let _=null,K=null;const D=e.computed(()=>!1),ee=e.computed(()=>{var s;return I.value&&((s=n.maxLiveNodes)!=null?s:0)<=0}),Xe=e.ref({batchSize:j.value,initial:Y.value,delay:(ln=n.renderBatchDelay)!=null?ln:16,enabled:ee.value}),J=e.computed(()=>!!V&&(D.value||B.value)),Ue=e.computed(()=>{var s;return Math.max(0,(s=n.liveNodeBuffer)!=null?s:60)}),ne=e.ref(0),he=e.reactive({start:0,end:0}),tt=new Map,ut=e.computed(()=>{if(!B.value)return k.value.length;const s=Ue.value,d=Math.max(he.end+s,Y.value),v=Math.min(k.value.length,d);return Math.max(P.value,v)});function _e(s){var T,C,X;const d=f((T=a.value)!=null?T:null);if(d)return d;const v=(X=(C=a.value)==null?void 0:C.ownerDocument)!=null?X:typeof document!="undefined"?document:null;return(v==null?void 0:v.scrollingElement)||(v==null?void 0:v.documentElement)||null}function Ye(){_&&(_(),_=null),ct.value=null}function nt(){if(!R||!B.value)return;const s=_e();if(!s||ct.value===s)return;Ye();const d=()=>de();s.addEventListener("scroll",d,{passive:!0}),ct.value=s,_=()=>{s.removeEventListener("scroll",d)}}function kt(){var d,v,T;if(!K)return;const s=(T=(v=(d=a.value)==null?void 0:d.ownerDocument)==null?void 0:v.defaultView)!=null?T:typeof window!="undefined"?window:null;K.viaTimeout?s?s.clearTimeout(K.id):clearTimeout(K.id):b==null||b(K.id),K=null}function de(s={}){var v,T,C;if(!B.value)return;if(!R){He(!0);return}if(s.immediate){kt(),He(!0);return}if(K)return;const d=()=>{K=null,He()};if(O)K={id:O(d),viaTimeout:!1};else{const X=(C=(T=(v=a.value)==null?void 0:v.ownerDocument)==null?void 0:T.defaultView)!=null?C:typeof window!="undefined"?window:null;K={id:X?X.setTimeout(d,16):setTimeout(d,16),viaTimeout:!0}}}function He(s=!1){var pt,rt,Tt,_t,Ft,at,bn,sn,lt,St,Kt;if(!B.value)return;const d=ct.value||_e();if(!d)return;const v=d.ownerDocument||((pt=a.value)==null?void 0:pt.ownerDocument)||document,T=(v==null?void 0:v.defaultView)||(typeof window!="undefined"?window:null),C=d===(v==null?void 0:v.documentElement)||d===(v==null?void 0:v.body),X=C?null:d.getBoundingClientRect(),ke=C?0:X.top,ve=C?(Tt=(rt=T==null?void 0:T.innerHeight)!=null?rt:d.clientHeight)!=null?Tt:0:X.bottom,ye=Array.from(G.entries()).sort((Ge,Je)=>Ge[0]-Je[0]);let re=null,Oe=null;for(const[Ge,Je]of ye){if(!Je)continue;const It=Je.getBoundingClientRect();It.bottom<=ke||It.top>=ve||(re==null&&(re=Ge),Oe=Ge)}if(re==null||Oe==null){const Ge=a.value;if(!Ge)return;const Je=C?{top:0}:d.getBoundingClientRect(),It=Ge.getBoundingClientRect(),cn=C?(bn=(at=(_t=v==null?void 0:v.documentElement)==null?void 0:_t.scrollTop)!=null?at:(Ft=v==null?void 0:v.body)==null?void 0:Ft.scrollTop)!=null?bn:0:d.scrollTop,l=It.top-(C?0:Je.top)+cn,r=Math.max(0,cn-l),c=C?(Kt=(St=(lt=T==null?void 0:T.innerHeight)!=null?lt:(sn=v==null?void 0:v.documentElement)==null?void 0:sn.clientHeight)!=null?St:d.clientHeight)!=null?Kt:0:d.clientHeight,w=r+Math.max(0,c)*.5,N=h(w);ne.value=Q(N,0,Math.max(0,k.value.length-1));return}const Nt=Math.round((re+Oe)/2);!s&&Math.abs(Nt-ne.value)<=1||(ne.value=Q(Nt,0,Math.max(0,k.value.length-1)))}function Q(s,d,v){return Math.min(Math.max(s,d),v)}function U(){const s=k.value.length;if(!B.value||s===0){he.start=0,he.end=s;return}const d=Math.min(x.value,s),v=Ue.value,T=Q(ne.value-v,0,Math.max(0,s-d));he.start=T,he.end=Math.min(s,T+d)}const ge=e.reactive({}),W=e.reactive({total:0,count:0});function qe(s,d){if(!Number.isFinite(d)||d<=0)return;const v=ge[s];ge[s]=d,v?W.total+=d-v:(W.total+=d,W.count++)}const Se=e.computed(()=>W.count>0?Math.max(12,W.total/W.count):32);function Bt(s,d){var T;if(s>=d)return 0;let v=0;for(let C=s;C<d;C++)v+=(T=ge[C])!=null?T:Se.value;return v}const dt=e.computed(()=>{if(!B.value)return k.value.map((T,C)=>({node:T,index:C}));const s=k.value.length,d=Q(he.start,0,s),v=Q(he.end,d,s);return k.value.slice(d,v).map((T,C)=>({node:T,index:d+C}))}),Mt=e.computed(()=>B.value?Bt(0,Math.min(he.start,k.value.length)):0),me=e.computed(()=>{if(!B.value)return 0;const s=k.value.length,d=Math.min(he.end,s);return Bt(d,s)});function h(s){var T;if(s<=0)return 0;let d=s;const v=k.value;for(let C=0;C<v.length;C++){const X=(T=ge[C])!=null?T:Se.value;if(d<=X)return C;d-=X}return Math.max(0,v.length-1)}function y(s){if(F.size&&B.value)for(const[d,v]of F)d>=s&&(v.destroy(),F.delete(d),D.value&&delete se[d],ot(d),G.delete(d))}function M(s,d){D.value&&(se[s]=d),d&&(B.value?de():ne.value=Q(s,0,Math.max(0,k.value.length-1)))}function z(s){return ee.value&&s>=P.value?!1:!D.value||s<Y.value?!0:se[s]===!0}function fe(s){const d=F.get(s);d&&(d.destroy(),F.delete(s)),ot(s)}function mt(s,d){if(d?G.set(s,d):G.delete(s),d||ot(s),!J.value||!V){fe(s),d?M(s,!0):D.value&&delete se[s];return}if(!B.value&&D.value&&!m.value&&F.size>=ul&&(gn(),!J.value||!V)){fe(s),d?M(s,!0):D.value&&delete se[s];return}if(s<Y.value&&!B.value){fe(s),M(s,!0);return}if(!d){fe(s),D.value&&delete se[s];return}fe(s);const v=V(d,{rootMargin:"400px"});v&&(F.set(s,v),M(s,v.isVisible.value),D.value&&Vn(s),v.whenVisible.then(()=>{ot(s),M(s,!0)}).catch(()=>{}).finally(()=>{F.get(s)===v&&F.delete(s);try{v.destroy()}catch(T){}}),B.value&&de())}function jt(s,d){if(!d){tt.delete(s);return}tt.set(s,d),queueMicrotask(()=>{qe(s,d.offsetHeight)})}let Pe=null,Fe=null,we=!1,Ke=null,ft=null;function Ct(){R&&(Pe!=null&&(b==null||b(Pe),Pe=null),Fe!=null&&(window.clearTimeout(Fe),Fe=null),ft!=null&&typeof window.cancelIdleCallback=="function"&&(window.cancelIdleCallback(ft),ft=null),we=!1,Ke=null)}function ot(s){if(!R)return;const d=Te.get(s);d!=null&&(window.clearTimeout(d),Te.delete(s))}function Vn(s){if(!R||!D.value)return;ot(s);const d=window.setTimeout(()=>{Te.delete(s),M(s,!0)},ml);Te.set(s,d)}function gn(s){if(!m.value){m.value=!0;for(const d of F.values())d.destroy();if(F.clear(),R)for(const d of Te.values())window.clearTimeout(d);Te.clear();for(const d of Object.keys(se))delete se[d]}}function oe(s,d={}){var ke,ve;if(!ee.value)return;const v=ut.value;if(P.value>=v)return;const T=Math.max(1,s),C=ye=>{var rt;Pe=null,Fe=null,ft=null,we=!1;const re=Ke!=null?Ke:T;Ke=null;const Oe=Math.max(2,(rt=n.renderBatchBudgetMs)!=null?rt:6),Nt=Tt=>{const _t=typeof performance!="undefined"?performance.now():Date.now();P.value=Math.min(v,P.value+Math.max(1,Tt)),y(P.value);const at=(typeof performance!="undefined"?performance.now():Date.now())-_t;return wn(at),at};let pt=re;for(;Nt(pt),!(P.value>=v||!ye||(typeof ye.timeRemaining=="function"?ye.timeRemaining():0)<=Oe*.5);)pt=Math.max(1,Math.round(Re.value));P.value<v&&te()};if(!R||d.immediate){C();return}const X=Math.max(0,(ke=n.renderBatchDelay)!=null?ke:16);if(Ke=Ke!=null?Math.max(Ke,T):T,!we){if(we=!0,!Z&&ie&&window.requestIdleCallback){const ye=Math.max(0,(ve=n.renderBatchIdleTimeoutMs)!=null?ve:120);ft=window.requestIdleCallback(re=>{C(re)},{timeout:ye});return}if(!O||Z){Fe=window.setTimeout(()=>C(),X);return}Pe=O(()=>{if(X===0){C();return}Fe=window.setTimeout(()=>C(),X)})}}function te(){if(!ee.value)return;const s=I.value?Math.max(1,Math.round(Re.value)):Math.max(1,j.value);oe(s)}function wn(s){var C;if(!ee.value)return;const d=Math.max(2,(C=n.renderBatchBudgetMs)!=null?C:6),v=Math.max(1,j.value||1),T=Math.max(1,Math.floor(v/4));s>d*1.2?Re.value=Math.max(T,Math.floor(Re.value*.7)):s<d*.5&&Re.value<v&&(Re.value=Math.min(v,Math.ceil(Re.value*1.2)))}e.watch([()=>k.value,()=>k.value.length,()=>ee.value,()=>j.value,()=>Y.value,()=>n.renderBatchDelay,()=>n.indexKey],()=>{var rt;const d=k.value.length,v=je.value,T=n.indexKey,C=T!==void 0&&T!==v.key,X=d!==v.total,ke=C||X;je.value={key:T,total:d};const ve=Xe.value,ye=(rt=n.renderBatchDelay)!=null?rt:16,re=ve.batchSize!==j.value||ve.initial!==Y.value||ve.delay!==ye||ve.enabled!==ee.value;Xe.value={batchSize:j.value,initial:Y.value,delay:ye,enabled:ee.value},(ke||re||!ee.value)&&Ct(),(ke||re)&&(Re.value=Math.max(1,j.value||1)),ke&&B.value&&de({immediate:!0});const Oe=ut.value;if(!d){P.value=0,y(0);return}if(!ee.value){P.value=Oe,y(P.value);return}C||v.total===0||re?P.value=Math.min(Oe,Y.value):P.value=Math.min(P.value,Oe);const pt=Math.max(1,Y.value||j.value||d);P.value<Oe?oe(pt,{immediate:!R}):y(P.value)},{immediate:!0}),e.watch(()=>B.value,s=>{if(!s){Ye(),kt();return}nt(),de({immediate:!0})},{immediate:!0}),e.watch(()=>a.value,()=>{B.value&&(nt(),de({immediate:!0}))}),e.watch(()=>k.value.length,()=>{B.value&&de({immediate:!0})}),e.watch(()=>D.value,s=>{if(!s){for(const d of F.values())d.destroy();F.clear();for(const d of Array.from(Te.keys()))ot(d);for(const d of Object.keys(se))delete se[d];for(const[d,v]of G)v&&M(d,!0);return}for(const[d,v]of G)mt(d,v)},{immediate:!1}),e.watch([()=>n.viewportPriority,()=>k.value.length],([s,d])=>{if(s===!1){m.value=!1;return}m.value&&d<=dl&&(m.value=!1)}),e.watch(()=>P.value,()=>{B.value&&de({immediate:!0})}),e.watch([ne,x,Ue,()=>k.value.length,B],()=>{U()},{immediate:!0}),e.watch(()=>ut.value,(s,d)=>{ee.value&&(typeof d=="number"&&s<=d||s>P.value&&te())}),e.onBeforeUnmount(()=>{Ct();for(const s of F.values())s.destroy();F.clear();for(const s of Array.from(Te.keys()))ot(s);Ye(),kt()});const rn=e.defineAsyncComponent(()=>$(null,null,function*(){try{return(yield Promise.resolve().then(()=>require("./index-BOMIs5jY.cjs"))).default}catch(s){return console.warn('[markstream-vue] Optional peer dependencies for CodeBlockNode are missing. Falling back to inline-code rendering (no Monaco). To enable full code block features, please install "stream-monaco".',s),zt}})),kn=e.computed(()=>n.renderCodeBlocksAsPre?zt:rn),yn={text:ue,paragraph:Qt,heading:$n,code_block:rn,list:Jt,blockquote:Yt,table:en,definition_list:qt,footnote:Zt,footnote_reference:be,footnote_anchor:Lt,admonition:nn,hardbreak:yt,link:Ne,image:wt,thematic_break:tn,math_inline:st,math_block:_r,strong:Ce,emphasis:Ae,strikethrough:Ee,highlight:De,insert:Le,subscript:Ve,superscript:$e,emoji:xe,checkbox:Qe,checkbox_input:Qe,inline_code:Be,html_inline:Rt,reference:Me,html_block:ll};function xn(s){var T;if(!s)return ro;const d=et(n.customId),v=d[String(s.type)];if(s.type==="code_block"){if(String((T=s.language)!=null?T:"").trim().toLowerCase()==="mermaid")return d.mermaid||Dt;if(v)return v;const X=d.code_block;return X||kn.value}return v||yn[String(s.type)]||ro}function Et(s){var d;return(s==null?void 0:s.type)==="code_block"&&String((d=s.language)!=null?d:"").trim().toLowerCase()==="mermaid"?{}:s.type==="code_block"?q({stream:n.codeBlockStream,darkTheme:n.codeBlockDarkTheme,lightTheme:n.codeBlockLightTheme,monacoOptions:n.codeBlockMonacoOptions,themes:n.themes,minWidth:n.codeBlockMinWidth,maxWidth:n.codeBlockMaxWidth},n.codeBlockProps||{}):{typewriter:n.typewriter}}function Ln(s){i("click",s)}function Ht(s){var v;(v=s.target)!=null&&v.closest("[data-node-index]")&&i("mouseover",s)}function an(s){var v;(v=s.target)!=null&&v.closest("[data-node-index]")&&i("mouseout",s)}return(s,d)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:a,class:"markdown-renderer",onClick:Ln,onMouseover:Ht,onMouseout:an},[B.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"node-spacer",style:e.normalizeStyle({height:`${Mt.value}px`}),"aria-hidden":"true"},null,4)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(dt.value,v=>{var T;return e.openBlock(),e.createElementBlock("div",{key:v.index,ref_for:!0,ref:C=>mt(v.index,C),class:"node-slot","data-node-index":v.index,"data-node-type":v.node.type},[z(v.index)?(e.openBlock(),e.createElementBlock("div",{key:0,ref_for:!0,ref:C=>jt(v.index,C),class:"node-content"},[v.node.type!=="code_block"&&n.typewriter!==!1?(e.openBlock(),e.createBlock(e.Transition,{key:0,name:"typewriter",appear:""},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(xn(v.node)),e.mergeProps({node:v.node,loading:v.node.loading,"index-key":`${t.indexKey||"markdown-renderer"}-${v.index}`},{ref_for:!0},Et(v.node),{"custom-id":n.customId,"is-dark":n.isDark,onCopy:d[0]||(d[0]=C=>i("copy",C)),onHandleArtifactClick:d[1]||(d[1]=C=>i("handleArtifactClick",C))}),null,16,["node","loading","index-key","custom-id","is-dark"]))]),_:2},1024)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(xn(v.node)),e.mergeProps({key:1,node:v.node,loading:v.node.loading,"index-key":`${t.indexKey||"markdown-renderer"}-${v.index}`},{ref_for:!0},Et(v.node),{"custom-id":n.customId,"is-dark":n.isDark,onCopy:d[2]||(d[2]=C=>i("copy",C)),onHandleArtifactClick:d[3]||(d[3]=C=>i("handleArtifactClick",C))}),null,16,["node","loading","index-key","custom-id","is-dark"]))],512)):(e.openBlock(),e.createElementBlock("div",{key:1,class:"node-placeholder",style:e.normalizeStyle({height:`${(T=ge[v.index])!=null?T:Se.value}px`})},null,4))],8,sl)}),128)),B.value?(e.openBlock(),e.createElementBlock("div",{key:1,class:"node-spacer",style:e.normalizeStyle({height:`${me.value}px`}),"aria-hidden":"true"},null,4)):e.createCommentVNode("",!0)],544))}}),ze=H(fl,[["__scopeId","data-v-33b6808c"]]);ze.install=t=>{var n,i;const o=(i=(n=ze.__name)!=null?n:ze.name)!=null?i:"NodeRenderer";t.component(o,ze)};const pl={key:0,class:"admonition-icon"},hl={class:"admonition-title"},vl=["aria-expanded","aria-controls","title"],gl={key:0},wl={key:1},kl=["id"],yl=e.defineComponent({__name:"AdmonitionNode",props:{node:{},indexKey:{},isDark:{type:Boolean},typewriter:{type:Boolean},customId:{}},emits:["copy"],setup(t,{emit:o}){var p;const n=t,i=o,a={note:"ℹ️",info:"ℹ️",tip:"💡",warning:"⚠️",danger:"❗",error:"⛔",caution:"⚠️"},m=e.computed(()=>{if(n.node.title&&n.node.title.trim().length)return n.node.title;const k=n.node.kind||"note";return k.charAt(0).toUpperCase()+k.slice(1)}),u=e.ref(n.node.collapsible?!((p=n.node.open)==null||p):!1);function f(){n.node.collapsible&&(u.value=!u.value)}const g=`admonition-${Math.random().toString(36).slice(2,9)}`;return(k,x)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["admonition",[`admonition-${n.node.kind}`,n.isDark?"is-dark":""]])},[e.createElementVNode("div",{id:g,class:"admonition-header"},[a[n.node.kind]?(e.openBlock(),e.createElementBlock("span",pl,e.toDisplayString(a[n.node.kind]),1)):e.createCommentVNode("",!0),e.createElementVNode("span",hl,e.toDisplayString(m.value),1),n.node.collapsible?(e.openBlock(),e.createElementBlock("button",{key:1,class:"admonition-toggle","aria-expanded":!u.value,"aria-controls":`${g}-content`,title:u.value?"Expand":"Collapse",onClick:f},[u.value?(e.openBlock(),e.createElementBlock("span",gl,"▶")):(e.openBlock(),e.createElementBlock("span",wl,"▼"))],8,vl)):e.createCommentVNode("",!0)]),e.withDirectives(e.createElementVNode("div",{id:`${g}-content`,class:"admonition-content","aria-labelledby":g},[e.withMemo([n.node.children],()=>e.createVNode(e.unref(ze),{"index-key":`admonition-${t.indexKey}`,nodes:n.node.children,"custom-id":n.customId,typewriter:n.typewriter,onCopy:x[0]||(x[0]=B=>i("copy",B))},null,8,["index-key","nodes","custom-id","typewriter"]),x,1)],8,kl),[[e.vShow,!u.value]])],2))}}),nn=H(yl,[["__scopeId","data-v-5e95c2b7"]]);nn.install=t=>{t.component(nn.__name,nn)};let ao=!1;function xl(t){return $(this,null,function*(){if(!ao)return ao=!0,t.preloadMonacoWorkers()})}let un=null,lo=!1;function bl(){return $(this,null,function*(){if(un)return un;if(lo)return null;try{return un=yield import("stream-monaco"),yield xl(un),un}catch(t){return lo=!0,null}})}const Bl='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32" width="16" height="16"><!-- Icon from VSCode Icons by Roberto Huertas - https://github.com/vscode-icons/vscode-icons/blob/master/LICENSE --><path fill="#0f23c3" d="M24.554 20.075c.209.27 1.356.961 1.37 1.246a7 7 0 0 0-1.4-.324a17 17 0 0 1-1.412-.48a9.2 9.2 0 0 1-2.375-1.3A3.15 3.15 0 0 1 19.3 16.75a1.72 1.72 0 0 1 1.767-1.822a3.6 3.6 0 0 1 1.593.321c.146.066 1.31.606 1.256.809a5.5 5.5 0 0 0-1.41-.112c-.649.244-.4.828-.168 1.311a8 8 0 0 0 1.078 1.554c.164.194.884 1.271 1.138 1.264"/><path fill="#1a1978" d="M24.141 16.276c.128-.59.819-1.384 1.344-.773a4.2 4.2 0 0 1 .578 1.918c.12.656.2 1.327.261 1.982c.038.379.34 1.794.123 2.075a23 23 0 0 1-2.922-2.838a3.76 3.76 0 0 1-.925-1.7c-.1-1.073.879-.73 1.541-.664"/><path fill="#0f23c3" d="M26.3 17.781c.141-.732-.406-2.592-1.067-2.949a.06.06 0 0 0 .044-.007c-.156-.444-1.359 1.116-1.228 1.174c-.316-.138.774-1.984.988-2.16c.7-.578 1.372-.086 1.845.543a6.04 6.04 0 0 1 .733 4.434a4.5 4.5 0 0 1-.421 1.312c-.1.22-.45 1.1-.682 1.174a14.8 14.8 0 0 0-.212-3.521"/><path fill="#d2d2d2" d="M3.687 8.4c.179-.188-.041-1.527.324-1.548c.262-.015.553 1.741.627 1.968a9.2 9.2 0 0 0 1.127 2.329a7.53 7.53 0 0 0 4.016 2.978a4.55 4.55 0 0 0 2.366.2c.931-.208 1.82-.577 2.757-.765c1.35-.27 3.342-.352 4.438.647c.7.641.376.76.043 1.421a2.44 2.44 0 0 0 .178 2.562c.235.342 1.033.827.675 1.094c-.567.424-1.277-.452-1.636-.776c-1.4-1.264-2.711-1.313-4.492-1.074a9 9 0 0 1-4.883-.708A9.47 9.47 0 0 1 3.687 8.4M19.941 30a3.6 3.6 0 0 1-2.325-.817c.469-.092 1.021.025 1.508-.044a9.7 9.7 0 0 0 1.754-.43a10.5 10.5 0 0 0 3.022-1.554a6.55 6.55 0 0 0 2.757-5.214c.149-.088.316 1.034.319 1.091a5.8 5.8 0 0 1-.19 1.727a6.9 6.9 0 0 1-1.423 2.774A7.3 7.3 0 0 1 19.941 30"/><path fill="#d2d2d2" d="M18.962 19.109a5.8 5.8 0 0 1-2.05.859a13.4 13.4 0 0 1-2.224.549a8.86 8.86 0 0 1-4.435-.51a9.94 9.94 0 0 1-3.849-2.4c-.352-.367-2.104-2.417-1.548-3.05c.248-.282.875.846 1 .992a5 5 0 0 0 1.357 1.11a10.9 10.9 0 0 0 4.035 1.456a6.7 6.7 0 0 0 2.34-.094a13 13 0 0 1 1.694-.485a4 4 0 0 1 2.113.457c.344.17 1.523.743 1.567 1.116m9.351-4.031a19.3 19.3 0 0 1-.453 3.774c-.176-.242.016-1.47 0-1.792a6 6 0 0 0-.384-2.087a4.9 4.9 0 0 0-1.376-1.661a15 15 0 0 1-1.27-1.536c-1.837-2.382-3.245-5.211-2.9-8.3c.034-.308.069-1.448.411-1.445c.152 0 .266 1.561.29 1.718a12.5 12.5 0 0 0 1.224 4.116c.67 1.222 1.947 2.023 2.825 3.1a6.58 6.58 0 0 1 1.633 4.113M15.7 26.935a10.85 10.85 0 0 0 6.436-.687a6.94 6.94 0 0 0 4.278-4.418c.319.2-.048 1.529-.128 1.781a5.7 5.7 0 0 1-1.01 1.813a8.9 8.9 0 0 1-3.257 2.514c-1.703.772-5.662 1.652-6.319-1.003"/><path fill="#d2d2d2" d="M19.151 19.376c.367 2.107-2.957 3.124-4.478 3.213c-1.859.11-4.929-.292-6.06-2.031c-.673-1.035.781-.09 1.188.058a8.7 8.7 0 0 0 3.06.5a11.6 11.6 0 0 0 3.305-.5a14 14 0 0 0 1.533-.576c.301-.132 1.124-.691 1.452-.664m4.991 4.084c.4-.945-1.883-1.578-2.445-1.858a4.9 4.9 0 0 1-1.315-.867c-.181-.181-.872-.92-.807-1.219a5 5 0 0 1 1.087-.175a6 6 0 0 1 .855.588a10 10 0 0 0 .964.5a16 16 0 0 0 2.119.771c.308.09 1.549.208 1.727.428c-.04.296-1.97 2.021-2.185 1.832"/><path fill="#d2d2d2" d="M26.1 22.172c.265.43-1.08 1.831-1.363 2.105a9.3 9.3 0 0 1-2.566 1.728a7.8 7.8 0 0 1-2.56.753c-.679.058-1.966-.124-2.141-.979a7 7 0 0 1 1.177-.086c.462-.059.921-.149 1.376-.246a13 13 0 0 0 2.184-.645a11.5 11.5 0 0 0 2.084-1.11a11 11 0 0 0 1.078-.822c.105-.089.617-.702.731-.698m-7.342-10.207c-.1-1.308 2.612-1.3 3.271-1.092a5.98 5.98 0 0 1 2.982 2.475c-1.082.8-2.449.094-3.3-.654a4.3 4.3 0 0 0-1.481-1.029c-.809-.265-.818.094-1.472.3"/><path fill="#d2d2d2" d="M25.783 13.341c-.444-.029-.316.071-.647-.212c-.358-.307-.614-.795-.945-1.141c-.534-.558-1.242-.895-1.723-1.485a7.27 7.27 0 0 1-1.624-4.848c.018-1.489.407.187.551.675a12.3 12.3 0 0 0 1.126 2.708a46 46 0 0 0 3.4 4.321c-.039.002-.097-.021-.138-.018m-5.715 1.415c.033-.625-.911-.792-1.211-1.42c-.164-.343-.211-.569.029-.7c.082-.045.383.012.5-.02c.271-.076.335-.273.581-.4a1.193 1.193 0 0 1 1.633 1.021a1.82 1.82 0 0 1-1.532 1.519"/><path fill="#d2d2d2" d="M20.5 14.745a1.93 1.93 0 0 0 1.323-1.7c.524.139.928.658 1.521.771a2.6 2.6 0 0 0 1.029-.017c.207-.045.54-.274.721-.259c-.033.163-.464.546-.565.717a4.2 4.2 0 0 0-.388.9c-.229.741-.061.739-.709.311a4.3 4.3 0 0 0-1.957-.72c-.266-.026-.881.019-.975-.003m-.595 5.989a2.01 2.01 0 0 1-1.4 1.712c-.205.091-2.018.733-2.032.348c-.007-.2 1.624-.954 1.809-1.11a3.4 3.4 0 0 0 .867-1.071c.055-.112.232-.925.271-.943c.224-.106.488.93.485 1.064m-8.532-8.202a10.6 10.6 0 0 1 3.71-.914a10.3 10.3 0 0 1 1.865.024c.366.039 1.469.054 1.74.343a.255.255 0 0 1-.273.173c-.037.077.251.371.3.425c-.034.034-1.445-.4-1.572-.424a10.6 10.6 0 0 0-2.282-.134a16 16 0 0 0-1.841.194a6.2 6.2 0 0 1-1.647.313m11.139-1.801a1.89 1.89 0 0 1-1.517-.6c-.247-.349-.737-1.692-.385-2.021c.209-.2.384.662.484.846a11 11 0 0 0 1.418 1.775m5.276 8.469a19 19 0 0 1-.749 3.313c-.173-.077-.275-.778-.562-.95a4.1 4.1 0 0 0 .76-1.154c.152-.302.303-1.046.551-1.209m-7.807-7.357c-.132.268-.932 1.1-1.118.481c-.107-.356.876-.841 1.118-.481m-.747.45c.228.006.012-.248.012-.266c-.001-.043-.368.266-.012.266"/></svg>',Ml=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
5
|
+
<path fill="none" stroke="#c6d0f5" stroke-linecap="round" stroke-linejoin="round" d="M14.4561802 11.3673353C13.0276218 14.1261537 11.8858593 15.5 10.8437759 15.5 10.3588459 15.5 9.88231005 15.3491298 9.41749082 15.0543006 8.74000639 14.6241577 7.8668418 14.6059458 7.17068967 15.0074382 6.60881451 15.3319356 6.07177167 15.5 5.56305868 15.5 4.02887542 15.5 1.5 10.9491129 1.5 8.45090396 1.5 5.78581061 2.95006811 3.551507 5.15647301 3.551507 6.19383481 3.551507 7.09007204 4.20001691 7.84308619 4.497206 8.16210316 4.62512517 8.52255587 4.61592787 8.83410596 4.47192 9.44477141 4.18872223 10.2497236 3.551507 11.2503615 3.551507 12.4715175 3.551507 13.5338865 4.33779342 14.4184071 5.47479877 14.5532906 5.64778615 14.5172013 5.89341518 14.3377895 6.02349446 13.3500923 6.736546 12.8746057 7.53893969 12.8746057 8.45090396 12.8746057 9.36404821 13.3502672 10.1652619 14.3377895 10.8793249 14.4946576 10.992887 14.5445377 11.1984946 14.4561802 11.3673353ZM8.5 3C8.5 3 8.3468635 1.3936039 10 1" />
|
|
6
|
+
</svg>
|
|
7
|
+
`,Cl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
8
|
+
<rect width="8" height="13.001" x="4" y="1.499" fill="none" stroke="#c6d0f5" stroke-linecap="round" stroke-linejoin="round" rx="2.286" ry="2.286" />
|
|
9
|
+
<path fill="none" stroke="#c6d0f5" stroke-linecap="round" stroke-linejoin="round" d="M 4,4.500025 H 1.5 M 4,7.9999993 H 1.5 M 4,11.499973 H 1.5 m 13,-6.999948 H 12 m 2.5,3.4999743 H 12 m 2.5,3.4999737 H 12" />
|
|
10
|
+
</svg>
|
|
11
|
+
`,El=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
12
|
+
<path fill="none" stroke="#8caaee" stroke-linecap="round" stroke-linejoin="round" d="m 4.0559072,12.951629 c 2.7459832,2.734744 7.1981158,2.734744 9.9441188,0 l -1.789955,-1.782586 c -1.75742,1.750224 -4.6067879,1.750224 -6.3642294,0 -1.7574416,-1.7502236 -1.7574416,-4.587893 0,-6.338097 1.7574415,-1.750224 4.6068094,-1.750224 6.3642294,0 l 0.894977,-0.8912929 0.894978,-0.891293 c -2.746003,-2.73472867 -7.1981359,-2.73472867 -9.944119,0 -2.7459858,2.7347089 -2.7459858,7.1685599 2e-7,9.9032689 z" clip-rule="evenodd" />
|
|
13
|
+
</svg>
|
|
14
|
+
`,Nl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
15
|
+
<g fill="none" stroke-linecap="round" stroke-linejoin="round">
|
|
16
|
+
<path stroke="#a6d189" d="M14.17 10.03A6.5 6.5 0 011.81 6.02" />
|
|
17
|
+
<path stroke="#8caaee" d="M1.87 5.85A6.5 6.5 0 0114.22 9.9" />
|
|
18
|
+
<path stroke="#a6d189" d="M6.36 4.9a3.5 3.5 0 103.41 6.12" />
|
|
19
|
+
<path stroke="#8caaee" d="M9.77 11.02a3.5 3.5 0 00-3.03-6.29" />
|
|
20
|
+
<path stroke="#c6d0f5" d="M8 7.5s-1.66 2.48-1.5 3.65" />
|
|
21
|
+
<path stroke="#c6d0f5" d="M1.81 6.02C2.47 5 3.83 4.49 5 4.46c4.06 0 3 5.56 5.03 6.86 1.21.52 3.5-.21 4.15-1.32" />
|
|
22
|
+
</g>
|
|
23
|
+
</svg>
|
|
24
|
+
`,Tl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
25
|
+
<path fill="none" stroke="#8caaee" stroke-linecap="round" stroke-linejoin="round" d="M6.74 2.24c.32-1.32 2.2-1.32 2.52 0a1.3 1.3 0 001.93.8c1.15-.7 2.48.62 1.77 1.77a1.3 1.3 0 00.8 1.93c1.32.32 1.32 2.2 0 2.52a1.3 1.3 0 00-.8 1.93c.7 1.15-.62 2.48-1.77 1.77a1.3 1.3 0 00-1.93.8c-.32 1.32-2.2 1.32-2.52 0a1.3 1.3 0 00-1.93-.8c-1.15.7-2.48-.62-1.77-1.77a1.3 1.3 0 00-.8-1.93c-1.32-.32-1.32-2.2 0-2.52a1.3 1.3 0 00.8-1.93c-.7-1.15.62-2.48 1.77-1.77a1.3 1.3 0 001.93-.8M10 6.5a2.5 2.5 0 100 3" />
|
|
26
|
+
</svg>
|
|
27
|
+
`,_l=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
28
|
+
<path fill="none" stroke="#8caaee" stroke-linecap="round" stroke-linejoin="round" d="m 2.5559121,12.951629 c 2.7459832,2.734744 7.1981158,2.734744 9.9441189,0 l -1.789955,-1.782586 c -1.7574201,1.750224 -4.606788,1.750224 -6.3642295,0 -1.7574416,-1.7502236 -1.7574416,-4.587893 0,-6.338097 1.7574415,-1.750224 4.6068094,-1.750224 6.3642295,0 l 0.894977,-0.8912929 0.894978,-0.891293 c -2.7460031,-2.73472867 -7.198136,-2.73472867 -9.9441191,0 -2.74598585,2.7347089 -2.74598585,7.1685599 2e-7,9.9032689 z" clip-rule="evenodd" />
|
|
29
|
+
<path fill="none" stroke="#8caaee" stroke-linecap="round" stroke-linejoin="round" d="M7.5 6v4M5.513524 7.9999996H9.51304M13.486476 5.9999996v4M11.5 7.9999992h3.999516" />
|
|
30
|
+
</svg>
|
|
31
|
+
`,Sl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
32
|
+
<path fill="none" stroke="#c6d0f5" stroke-linecap="round" stroke-linejoin="round" d="m 15.4712,10.050637 -5.433601,5.433968 c -0.015,0.01505 -0.04554,0.01505 -0.09055,0.01505 L 2.536327,13.517264 c -0.015,0 -0.04501,-0.01505 -0.06055,-0.06072 L 0.50026325,6.0396501 a 0.21432208,0.21495127 0 0 1 0.015,-0.090817 L 5.9483283,0.5154023 c 0.015,-0.0150465 0.04501,-0.0150465 0.09055,-0.0150465 l 7.4101857,1.997972 c 0.015,0 0.04501,0.015046 0.06055,0.060724 l 1.977121,7.4158186 c 0.03001,0.03063 0.01608,0.060724 -0.01554,0.07577 M 8.2121063,4.1480782 0.93801425,6.1154197 q -0.0225,0 0,0.04514 L 6.2655263,11.50371 c 0.015,0.01505 0.015,0 0.04501,0 l 1.962119,-7.2803988 c -0.03054,-0.075233 -0.06055,-0.075233 -0.06055,-0.075233" />
|
|
33
|
+
</svg>
|
|
34
|
+
`,Il=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
35
|
+
<path fill="none" stroke="#8caaee" d="m 6.665625,1.0107144 c 0.54375,0.090628 0.9125,0.6062693 0.821875,1.1500367 L 7.18125,3.9983098 h 2.971875 L 10.5125,1.8326156 c 0.09063,-0.5437673 0.60625,-0.9125291 1.15,-0.8219012 0.54375,0.090628 0.9125,0.6062693 0.821875,1.1500367 L 12.18125,3.9983098 H 14 c 0.553125,0 1,0.4468892 1,1.0000319 0,0.5531426 -0.446875,1.0000319 -1,1.0000319 H 11.846875 L 11.18125,9.9985013 H 13 c 0.553125,0 1,0.4468897 1,1.0000317 0,0.553143 -0.446875,1.000032 -1,1.000032 H 10.846875 L 10.4875,14.164259 c -0.09063,0.543768 -0.60625,0.912529 -1.15,0.821902 -0.54375,-0.09063 -0.9125,-0.60627 -0.821875,-1.150037 l 0.30625,-1.834434 h -2.975 L 5.4875,14.167384 c -0.090625,0.543768 -0.60625,0.91253 -1.15,0.821902 C 3.79375,14.898658 3.425,14.383016 3.515625,13.839249 L 3.81875,11.998565 H 2 c -0.553125,0 -1,-0.446889 -1,-1.000032 C 1,10.445391 1.446875,9.9985013 2,9.9985013 H 4.153125 L 4.81875,5.9983736 H 3 c -0.553125,0 -1,-0.4468893 -1,-1.0000319 C 2,4.445199 2.446875,3.9983098 3,3.9983098 H 5.153125 L 5.5125,1.8326156 C 5.603125,1.2888483 6.11875,0.9200865 6.6625,1.0107144 Z M 6.846875,5.9983736 6.18125,9.9985013 H 9.153125 L 9.81875,5.9983736 Z" />
|
|
36
|
+
</svg>
|
|
37
|
+
`,$l=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
38
|
+
<g fill="none" stroke="#ca9ee6" stroke-linecap="round" stroke-linejoin="round">
|
|
39
|
+
<path d="m4 1.5h8c1.38 0 2.5 1.12 2.5 2.5v8c0 1.38-1.12 2.5-2.5 2.5h-8c-1.38 0-2.5-1.12-2.5-2.5v-8c0-1.38 1.12-2.5 2.5-2.5z" />
|
|
40
|
+
<path stroke-width=".814" d="m 10.240861,11.529149 c 0,0.58011 0.437448,1.039154 0.96002,1.035371 l 0.451635,-0.0032 c 0.522572,-0.0036 0.949379,-0.451477 0.949379,-1.032848 0,-0.581372 -0.426807,-1.065638 -0.949379,-1.065638 l -0.451635,3.4e-5 c -0.522572,3.9e-5 -0.949379,-0.4855273 -0.949379,-1.0656374 0,-0.5801104 0.426807,-1.0378931 0.949379,-1.0378931 l 0.451635,2.825e-4 c 0.522572,3.267e-4 0.951743,0.4577827 0.951743,1.0378931 M 6.8003972,11.529149 c 0,0.58011 0.4374474,1.039154 0.9600196,1.035371 l 0.46464,-0.0032 c 0.5225722,-0.0035 0.9363738,-0.451477 0.9363738,-1.031587 0,-0.580111 -0.4090724,-1.065638 -0.9316446,-1.065638 l -0.4693692,3.4e-5 c -0.5225722,3.8e-5 -0.949379,-0.4855272 -0.949379,-1.0656373 0,-0.5801104 0.4268068,-1.0378931 0.949379,-1.0378931 h 0.4516348 c 0.5225722,0 0.9635665,0.4577827 0.9635665,1.0378931 M 3.4072246,11.529149 c 0,0.58011 0.4374474,1.051765 0.9600196,1.051765 H 4.818879 c 0.5225722,0 0.949379,-0.456521 0.949379,-1.037893 m 0.01129,-2.1312747 c 0,-0.5801103 -0.4374474,-1.037893 -0.9600196,-1.037893 L 4.3678939,8.3741358 C 3.8453217,8.3744624 3.4078743,8.8420074 3.4078743,9.4233788 v 2.1186642" />
|
|
41
|
+
</g>
|
|
42
|
+
</svg>
|
|
43
|
+
`,Vl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
44
|
+
<g fill="none" stroke="#85c1dc" stroke-linecap="round" stroke-linejoin="round">
|
|
45
|
+
<path d="M7 14.5h4.5v-3h3V7L9.17 1.64c-.28-.29-.8-.47-1.17-.29L3.5 3.5 1.35 8c-.18.37 0 .88.3 1.17z" />
|
|
46
|
+
<path d="M3.5 11V3.5H11m-7.5 0 8 8" />
|
|
47
|
+
</g>
|
|
48
|
+
</svg>
|
|
49
|
+
`,Ll='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32" width="16" height="16"><!-- Icon from VSCode Icons by Roberto Huertas - https://github.com/vscode-icons/vscode-icons/blob/master/LICENSE --><defs><linearGradient id="SVGMV3iTbAN" x1="185.455" x2="181.955" y1="1601.641" y2="1630.224" gradientTransform="translate(-62.523 -666.646)scale(.427)" gradientUnits="userSpaceOnUse"><stop offset="0" stop-color="#fff"/><stop offset="1" stop-color="#fff" stop-opacity="0"/></linearGradient><linearGradient id="SVGniw2Mvsa" x1="176.136" x2="172.636" y1="1600.5" y2="1629.083" href="#SVGMV3iTbAN"/></defs><path fill="#b03931" d="m3.978 15.462l-.009-6.953a.59.59 0 0 1 .531-.562h.076l6.074-.009a15.7 15.7 0 0 1 6.067.95a8.9 8.9 0 0 1 2.244 1.359a4.47 4.47 0 0 1 2.946-1.083a4.11 4.11 0 0 1 4.276 3.92A4.11 4.11 0 0 1 21.907 17c-.089 0-.177-.008-.265-.012a7 7 0 0 1-.232.953a85 85 0 0 1 8.59 2.6V2H2v13.4q.992.02 1.978.062m22.8-7.944a1.32 1.32 0 0 1 1.374 1.259a1.379 1.379 0 0 1-2.747 0a1.32 1.32 0 0 1 1.375-1.26Z"/><path fill="#b03931" d="M17.861 15.787a4.11 4.11 0 0 0-1.748-3.458a5.8 5.8 0 0 0-1.508-.822a7.4 7.4 0 0 0-1.629-.438a22 22 0 0 0-2.588-.1H7.769l.006 4.737a89 89 0 0 1 9.91 1.408a5 5 0 0 0 .176-1.327m3.132 3.192a7.9 7.9 0 0 1-2.128 2.582a9.7 9.7 0 0 1-3.256 1.71a11.6 11.6 0 0 1-1.971.472h-.015a32 32 0 0 1-3.326.111l-5.625.022a.616.616 0 0 1-.686-.681l-.01-7.734Q2.992 15.42 2 15.4V30h28v-9.456a85 85 0 0 0-8.59-2.6a7 7 0 0 1-.417 1.035"/><path fill="url(#SVGMV3iTbAN)" d="M20.993 18.979a7.9 7.9 0 0 1-2.128 2.582a9.7 9.7 0 0 1-3.256 1.71a11.6 11.6 0 0 1-1.971.472h-.015a32 32 0 0 1-3.326.111l-5.625.022a.616.616 0 0 1-.686-.681l-.01-7.734Q2.992 15.42 2 15.4V30h28v-9.456a85 85 0 0 0-8.59-2.6a7 7 0 0 1-.417 1.035" opacity=".3"/><path fill="#b03931" d="M10.477 20.835a16 16 0 0 0 2.877-.2a7.6 7.6 0 0 0 1.628-.5a5.6 5.6 0 0 0 1.187-.748a4.46 4.46 0 0 0 1.518-2.271a89 89 0 0 0-9.91-1.408l.006 5.133Z"/><path fill="url(#SVGniw2Mvsa)" d="M10.477 20.835a16 16 0 0 0 2.877-.2a7.6 7.6 0 0 0 1.628-.5a5.6 5.6 0 0 0 1.187-.748a4.46 4.46 0 0 0 1.518-2.271a89 89 0 0 0-9.91-1.408l.006 5.133Z" opacity=".3"/><path fill="#fff" d="M20.383 11.746a7 7 0 0 1 1.36 4.148a6.6 6.6 0 0 1-.1 1.1c.088 0 .176.012.265.012a4.11 4.11 0 0 0 4.276-3.92a4.11 4.11 0 0 0-4.276-3.92a4.47 4.47 0 0 0-2.946 1.083a8 8 0 0 1 1.421 1.497"/><ellipse cx="26.78" cy="8.777" fill="#fff" rx="1.374" ry="1.259"/><path fill="#fff" d="m4.673 23.877l5.625-.022a32 32 0 0 0 3.326-.111h.015a11.5 11.5 0 0 0 1.971-.472a9.7 9.7 0 0 0 3.256-1.71a7.9 7.9 0 0 0 2.128-2.582a7 7 0 0 0 .417-1.034a7 7 0 0 0 .332-2.051a7 7 0 0 0-1.36-4.148a8 8 0 0 0-1.421-1.5a8.9 8.9 0 0 0-2.244-1.359a15.7 15.7 0 0 0-6.067-.95l-6.074.009h-.076a.59.59 0 0 0-.532.562l.009 6.952l.01 7.734a.616.616 0 0 0 .685.682m3.1-12.908h2.619a22 22 0 0 1 2.588.1a7.4 7.4 0 0 1 1.629.438a5.8 5.8 0 0 1 1.508.822a4.12 4.12 0 0 1 1.748 3.458a5 5 0 0 1-.175 1.327a4.46 4.46 0 0 1-1.518 2.271a5.6 5.6 0 0 1-1.187.748a7.7 7.7 0 0 1-1.628.5a16 16 0 0 1-2.877.2H7.786L7.78 15.7Z"/></svg>',Dl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
50
|
+
<path fill="none" stroke="#8caaee" stroke-linecap="round" stroke-linejoin="round" d="M.5 8.5H11l.75-.5a5.35 5.35 0 010-3.5c1 .6 1 1.88 1.74 2 .77-.09 1.23.01 2 .52 0 0-.97 1.77-2.5 1.98-1.93 3.65-4.5 5.5-6.98 5.5C0 14.5.5 8.5.5 8.5m1 0v-2m0 0h8m-6 2v-4m0 0h4m-2-2h2m-2 6v-6m2 6v-6m2 6v-2" />
|
|
51
|
+
</svg>
|
|
52
|
+
`,Rl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
53
|
+
<path fill="none" stroke="#ca9ee6" stroke-linecap="round" stroke-linejoin="round" d="M8.03 14.5C5 14.5 3.5 12.49 3.5 10.01c0-2.82 2.25-7.02 4.62-8.48a.24.24 0 01.24 0c.08.04.12.12.11.2-.13 1.25.22 2.5.98 3.54.3.43.63.8 1.02 1.27.54.66.94 1.03 1.52 2.08l.01.02c.33.56.5 1.2.5 1.84 0 2.03-1.69 4.02-4.47 4.02" />
|
|
54
|
+
</svg>
|
|
55
|
+
`,zl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
56
|
+
<g fill="none" stroke="#e78284" stroke-linecap="round" stroke-linejoin="round">
|
|
57
|
+
<path d="M6.5 5.5c0-1.25 1-2 2-2s2 .75 2 2z" />
|
|
58
|
+
<path d="M13.5 13c.47-.57 1.12-1.24 1.5-2l-2.25-1.25c-.74 1.36-1.76 2.75-3.25 2.75-2.1 0-3-2.3-3-5h8c.05-1.61-.31-3.45-1-4.5M3 13c-1.08-1.3-1.5-3-1.5-5S2.1 4.24 3 3" />
|
|
59
|
+
</g>
|
|
60
|
+
</svg>
|
|
61
|
+
`,Al=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
62
|
+
<path fill="none" stroke="#ca9ee6" stroke-linecap="round" stroke-linejoin="round" d="M7.5 14.5v-1l-1-1v-3h2l1 2h1v-6h-1l-1 2h-2v-4h5l1 3h1v-5h-11v1l1 1v9l-1 1.25v.75z" />
|
|
63
|
+
</svg>
|
|
64
|
+
`,jl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
65
|
+
<path fill="none" stroke="#85c1dc" stroke-linecap="round" stroke-linejoin="round" d="m15.48 8.06-4.85.48m4.85-.48a4.98 4.98 0 01-4.54 5.42 5 5 0 112.95-8.66l-1.7 1.84a2.5 2.5 0 00-4.18 2.06c.05.57.3 1.1.69 1.51.25.27 1 .83 1.78.82.8-.02 1.58-.25 2.07-.81 0 0 .8-.96.68-1.88M2.5 8.5l-2 .01m1.5 2h1.5m-2-3.99 2-.02" />
|
|
66
|
+
</svg>
|
|
67
|
+
`,Hl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
68
|
+
<g fill="none" stroke="#85c1dc" stroke-linecap="round" stroke-linejoin="round">
|
|
69
|
+
<path d="M11.68 5.38c.4.19.54.68 1.53 3.25 1 2.57-.92 4.07-.92 4.07s-6.73 2.47-6.73 1.63c-.18-.92-1.92-2.08-1.92-2.08s-.52-.63.06-.75c5.89-1.27 6.96-.61 7.3-2" />
|
|
70
|
+
<path d="M7.38 10.63C2.62 10.88 2.48 8.08 2.5 8 3.6 4.6 9.24.91 10.8 1.58 14.07 3.04 9.2 8.96 7 8.5c-4.02-.83 1.5-4 1.5-4" />
|
|
71
|
+
</g>
|
|
72
|
+
</svg>
|
|
73
|
+
`,Pl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
74
|
+
<path fill="none" stroke="#ca9ee6" stroke-linecap="round" stroke-linejoin="round" d="M12.5 4.5h3m-1.5 3h1.5m-10 6 2.5-5-2.5-5H8l5.6 10h-2.53l-1.52-2.92L8 13.5zm-5 0 2.5-5-2.5-5H3l2.5 5-2.5 5z" />
|
|
75
|
+
</svg>
|
|
76
|
+
`,Fl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
77
|
+
<g fill="none" stroke-linecap="round" stroke-linejoin="round">
|
|
78
|
+
<path stroke="#ef9f76" d="M1.5 1.5h13L13 13l-5 2-5-2z" />
|
|
79
|
+
<path stroke="#c6d0f5" d="M11 4.5H5l.25 3h5.5l-.25 3-2.5 1-2.5-1-.08-1" />
|
|
80
|
+
</g>
|
|
81
|
+
</svg>
|
|
82
|
+
`,Kl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
83
|
+
<g fill="none" stroke-linecap="round" stroke-linejoin="round">
|
|
84
|
+
<path stroke="#c6d0f5" d="M10.73 8.41c.57 3 1.59 5.83 2.77 7.09-6.63-3.45-9.76-1.75-10.5 0-.66-3.4-.54-5.74.09-7.78" />
|
|
85
|
+
<path stroke="#e78284" d="M8.5 7c.63.34 1.82 1.07 2.24 1.41-.54-2.9-.64-5.96-.74-7.91-2.13.58-5.73 1.98-6.9 7.22.52-.69 1.72-1.05 2.4-1.22" />
|
|
86
|
+
<path stroke="#e78284" d="M5.5 7A1.5 1.5 0 007 8.5 1.5 1.5 0 008.5 7 1.5 1.5 0 007 5.5 1.5 1.5 0 005.5 7" />
|
|
87
|
+
</g>
|
|
88
|
+
</svg>
|
|
89
|
+
`,Ol=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
90
|
+
<g fill="none" stroke="#99d1db" stroke-linecap="round" stroke-linejoin="round">
|
|
91
|
+
<path d="M8 10.8c4.14 0 7.5-1.25 7.5-2.8S12.14 5.2 8 5.2.5 6.45.5 8s3.36 2.8 7.5 2.8" />
|
|
92
|
+
<path d="M5.52 9.4c2.07 3.5 4.86 5.72 6.23 4.95 1.37-.78.8-4.24-1.27-7.75C8.41 3.1 5.62.88 4.25 1.65c-1.37.78-.8 4.24 1.27 7.75" />
|
|
93
|
+
<path d="M5.52 6.6c-2.07 3.5-2.64 6.97-1.27 7.75 1.37.77 4.16-1.45 6.23-4.95s2.64-6.97 1.27-7.75C10.38.88 7.59 3.1 5.52 6.6" />
|
|
94
|
+
<path d="M8.5 8a.5.5 0 01-.5.5.5.5 0 01-.5-.5.5.5 0 01.5-.5.5.5 0 01.5.5" />
|
|
95
|
+
</g>
|
|
96
|
+
</svg>
|
|
97
|
+
`,Wl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
98
|
+
<g fill="none" stroke="#e5c890" stroke-linecap="round" stroke-linejoin="round">
|
|
99
|
+
<path d="M4.5 11c0 .828427.6715729 1.5 1.5 1.5.8284271 0 1.5-.671573 1.5-1.5V7.5M12.5 8.75C12.5 8.05964406 11.9627417 7.5 11.3 7.5L10.7 7.5C10.0372583 7.5 9.5 8.05964406 9.5 8.75 9.5 9.44035594 10.0372583 10 10.7 10L11.3 10C11.9627417 10 12.5 10.5596441 12.5 11.25 12.5 11.9403559 11.9627417 12.5 11.3 12.5L10.7 12.5C10.0372583 12.5 9.5 11.9403559 9.5 11.25" />
|
|
100
|
+
<path d="m 4,1.5 h 8 c 1.385,0 2.5,1.115 2.5,2.5 v 8 c 0,1.385 -1.115,2.5 -2.5,2.5 H 4 C 2.615,14.5 1.5,13.385 1.5,12 V 4 C 1.5,2.615 2.615,1.5 4,1.5 Z" />
|
|
101
|
+
</g>
|
|
102
|
+
</svg>
|
|
103
|
+
`,Xl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
104
|
+
<path fill="none" stroke="#e5c890" stroke-linecap="round" stroke-linejoin="round" d="M4.5 2.5H4c-.75 0-1.5.75-1.5 1.5v2c0 1.1-1 2-1.83 2 .83 0 1.83.9 1.83 2v2c0 .75.75 1.5 1.5 1.5h.5m7-11h.5c.75 0 1.5.75 1.5 1.5v2c0 1.1 1 2 1.83 2-.83 0-1.83.9-1.83 2v2c0 .74-.75 1.5-1.5 1.5h-.5m-6.5-3a.5.5 0 100-1 .5.5 0 000 1m3 0a.5.5 0 100-1 .5.5 0 000 1m3 0a.5.5 0 100-1 .5.5 0 000 1" />
|
|
105
|
+
</svg>
|
|
106
|
+
`,Ul=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
107
|
+
<g fill="none" stroke-linecap="round" stroke-linejoin="round">
|
|
108
|
+
<path stroke="#a6d189" d="M10.5 5a2.5 2.5 0 11-5 0 2.5 2.5 0 015 0" />
|
|
109
|
+
<path stroke="#e78284" d="M6.5 11a2.5 2.5 0 11-5 0 2.5 2.5 0 015 0" />
|
|
110
|
+
<path stroke="#ca9ee6" d="M14.5 11a2.5 2.5 0 11-5 0 2.5 2.5 0 015 0" />
|
|
111
|
+
</g>
|
|
112
|
+
</svg>
|
|
113
|
+
`,Yl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
114
|
+
<g fill="none" stroke-linecap="round" stroke-linejoin="round">
|
|
115
|
+
<path stroke="#ca9ee6" d="M2.5 13.5h11L8 8" />
|
|
116
|
+
<path stroke="#ef9f76" d="M8.03 2.5h5.47l-8 8" />
|
|
117
|
+
<path stroke="#e78284" d="M2.5 13.5V8" />
|
|
118
|
+
<path stroke="#85c1dc" d="M8 2.5H2.5V8l3-2.5" />
|
|
119
|
+
</g>
|
|
120
|
+
</svg>
|
|
121
|
+
`,ql=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
122
|
+
<g fill="none" stroke="#e78284" stroke-linecap="round" stroke-linejoin="round">
|
|
123
|
+
<path d="M.5 5.06v6.07C.5 12.41.82 13 2.27 13h5.6c1.04 0 1.63-.51 1.63-1.62 0-.85-.2-1.88-1.5-1.88h-.36C6.4 9.5 6 8.77 6 7.75 6 6.81 6.8 6 7.49 6h2.68" />
|
|
124
|
+
<path d="M3.5 10.5V4.99C3.5 3.89 3.62 3 5 3h9c.97 0 1.5.99 1.5 1.63.12 1.55-.98 1.62-2.1 2.16-.58.26-1.4.52-1.4.98V11" />
|
|
125
|
+
</g>
|
|
126
|
+
</svg>
|
|
127
|
+
`,Zl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
128
|
+
<g fill="none" stroke-linecap="round" stroke-linejoin="round">
|
|
129
|
+
<path stroke="#c6d0f5" d="M10.5 7A1.5 1.5 0 019 8.5 1.5 1.5 0 017.5 7 1.5 1.5 0 019 5.5 1.5 1.5 0 0110.5 7" />
|
|
130
|
+
<path stroke="#8caaee" d="M7 2.5a6.5 6.5 0 100 13 6.5 6.5 0 000-13m7-2a1.5 1.5 0 100 3 1.5 1.5 0 000-3" />
|
|
131
|
+
</g>
|
|
132
|
+
</svg>
|
|
133
|
+
`,Gl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
134
|
+
<path fill="none" stroke="#85c1dc" stroke-linecap="round" stroke-linejoin="round" d="m9.25 8.25 2.25 2.25 2.25-2.25M3.5 11V5.5l2.04 3 1.96-3V11m4-.5V5M1.65 2.5h12.7c.59 0 1.15.49 1.15 1v9c0 .51-.56 1-1.15 1H1.65c-.59 0-1.15-.49-1.15-1V3.58c0-.5.56-1.08 1.15-1.08" />
|
|
135
|
+
</svg>
|
|
136
|
+
`,Jl=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
137
|
+
<g fill="none" stroke-linecap="round" stroke-linejoin="round">
|
|
138
|
+
<path stroke="#85c1dc" d="M4 11 .5 8.5 5 7q.78-1.77 1.89-1.89c.74-.07 1.94-1.28 3.61-3.61M5 7l1.5 1.5" />
|
|
139
|
+
<path stroke="#ef9f76" d="m15.5 12.5-5-11C8.5 6.83 6.33 10 4 11c1.67-.33 2.67.83 3 3.5 3.5-1.5 3.5-3.5 5-4s1.5 1.5 3.5 2" />
|
|
140
|
+
</g>
|
|
141
|
+
</svg>
|
|
142
|
+
`,Ql=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
143
|
+
<path fill="none" stroke="#ca9ee6" stroke-linecap="round" stroke-linejoin="round" d="M1.5 2.5c0 6 2.25 5.75 4 7 .83.67 1.17 2 1 4h3c-.17-2 .17-3.33 1-4 1.75-1.25 4-1 4-7C12 2.5 10 3 8 7 6 3 4 2.5 1.5 2.5" />
|
|
144
|
+
</svg>
|
|
145
|
+
`,ei=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
146
|
+
<path fill="none" stroke="#e5c890" stroke-linecap="round" stroke-linejoin="round" d="M1 7 .5 4.5l1.01.67c.28-.27.47-.48 1.18-.85l.56-1.82L4.5 3.84c.77-.18 1.53-.36 2.4-.33L8 1.5l1.1 2.01c.87-.03 1.63.15 2.4.33l1.25-1.34.56 1.82c.7.37.9.58 1.18.85l1.01-.67L15 7m-1.5 1C13 6.5 11 5.5 8 5.5S3 6.5 2.5 8m11.5.75L13.5 8l-1 1.5-1.5.5-3-1.5L5 10l-1.5-.5-1-1.5-.5.75L1 7l1.25 3.75C3 12.75 6 13.5 8 13.5s5-.75 5.75-2.75L15 7z" />
|
|
147
|
+
</svg>
|
|
148
|
+
`,ti='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32" width="16" height="16"><!-- Icon from VSCode Icons by Roberto Huertas - https://github.com/vscode-icons/vscode-icons/blob/master/LICENSE --><path fill="#c2c2c2" d="M11.29 15.976a8.9 8.9 0 0 0 1.039 4.557a4.82 4.82 0 0 0 5.579 2.13a3.79 3.79 0 0 0 2.734-3.181c.095-.535.1-.54.1-.54c1.537.222 4.014.582 5.55.8l-.1.389A9.96 9.96 0 0 1 23.8 24.9a8.35 8.35 0 0 1-4.747 2.378a12.93 12.93 0 0 1-7.322-.725a8.98 8.98 0 0 1-5.106-5.524A14.35 14.35 0 0 1 6.642 10.9a9.32 9.32 0 0 1 7.929-6.24a11.8 11.8 0 0 1 5.9.491a8.47 8.47 0 0 1 5.456 6.1c.083.311.1.369.1.369c-1.709.311-3.821.705-5.518 1.075c-.323-1.695-1.122-3.029-2.831-3.445a4.656 4.656 0 0 0-5.853 3.158a9 9 0 0 0-.341 1.273a11 11 0 0 0-.194 2.295"/><path fill="#c2c2c2" d="M2.033 30V2h5.934v2.227H4.723v23.546h3.244V30zm27.934-.001h-5.934v-2.228h3.244V4.226h-3.244V1.999h5.934z"/></svg>',ni='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32" width="16" height="16"><!-- Icon from VSCode Icons by Roberto Huertas - https://github.com/vscode-icons/vscode-icons/blob/master/LICENSE --><path fill="#c2c2c2" d="M19.5 24.833a11.24 11.24 0 0 1-5.13 1.009a8.37 8.37 0 0 1-6.492-2.576A9.75 9.75 0 0 1 5.512 16.4a10.4 10.4 0 0 1 2.659-7.406a9.02 9.02 0 0 1 6.9-2.841a12.2 12.2 0 0 1 4.43.7v4.129a7.5 7.5 0 0 0-4.108-1.142a5.28 5.28 0 0 0-4.075 1.685A6.48 6.48 0 0 0 9.766 16.1a6.37 6.37 0 0 0 1.464 4.4a5.02 5.02 0 0 0 3.941 1.639a8.03 8.03 0 0 0 4.329-1.223Z"/><path fill="#c2c2c2" d="M16.572 15.081V13.24h1.841v1.841h1.84v1.84h-1.84v1.841h-1.841v-1.841h-1.839V15.08zm6.44 0V13.24h1.841v1.841h1.84v1.84h-1.84v1.841h-1.841v-1.841h-1.839V15.08zM2.035 30V2.001h5.933v2.227H4.725v23.545h3.243V30z"/><path fill="#c2c2c2" d="M29.965 29.999h-5.933v-2.228h3.243V4.227h-3.243V2h5.933z"/></svg>',oi=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
149
|
+
<g fill="none" stroke="#ef9f76" stroke-linecap="round" stroke-linejoin="round">
|
|
150
|
+
<path d="M1.5 8V3c0-.83.67-1.5 1.5-1.5h10c.83 0 1.5.67 1.5 1.5v10c0 .83-.67 1.5-1.5 1.5H9" />
|
|
151
|
+
<path d="m1.5 8 1.14-2.3q.09-.21.36-.24a.8.8 0 01.44.13c.18.12.23.53.28.64.06.1.64 1.23.85 1.23.2 0 .71-1.47.71-1.47s.37-.49.72-.49.55.32.67.49c.12.16.24 1.76.46 2.01s1.32.87 1.67.73c.34-.13.53-.4.63-.73.1-.34-.14-.75 0-1a1.1 1.1 0 011.02-.55c.56.03 2.05.56 2.05 1.05q0 .75-1.5.75c-.48 1.33.28 2.22-3 2.25l1 4" />
|
|
152
|
+
<path d="m4.5 14.5 1.5-4 1 4zm-2 0 1.5-4-1.5-.5-1 1.54V14l1 .49Z" />
|
|
153
|
+
</g>
|
|
154
|
+
</svg>
|
|
155
|
+
`,ri=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
156
|
+
<path fill="none" stroke="#8caaee" stroke-linecap="round" stroke-linejoin="round" d="M12.5 14.5v-3.34c-1-.66-1-1.35-1-2.66m-3 1 .02 2.53.98 2.47m-4-5v5m9 0V9.23s.17-1.73-1-1.73c0-1.5-.5-6-2.5-6S8.75 4.25 8.75 4.25A3.67 3.67 0 006.5 7.12v-3.5c0-.63-.85-1.32-1.5-1.32-.92 0-1.33.59-1.5 1.2H2.25c-.42.11-.75.59-.75 1 0 .5.28 1 .75 1h1.22l.02 3c.01.75.51 1 1.51 1h4.5" />
|
|
157
|
+
</svg>
|
|
158
|
+
`,ai=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
159
|
+
<path fill="none" stroke="#8caaee" stroke-linecap="round" stroke-linejoin="round" d="M0.5,12.5 L0.5,13.24 C0.5,14 1.27360724,14.5 2,14.5 C2.9375516,14.5 3.5,14 3.5,13.2445661 L3.5,6.00089968 C3.5,4.28551107 4.99401107,2.52263547 7.14960413,2.5 C9.49387886,2.5 11,4.0579782 11,5.5 C11.1657296,8.48962302 9.57820404,9.63684469 7.49621582,10.5 L7.49621582,14.5 L15.4979764,14.5 L15.4979764,9 C15.5394484,8.36478228 14.9387379,7.15595371 14.1308258,6.5 C13.1942239,5.80827275 12.0584852,5.50253264 11,5.5 M11.5,14.5 L11.5,11.5 M6,6.5 C6.27614237,6.5 6.5,6.27614237 6.5,6 C6.5,5.72385763 6.27614237,5.5 6,5.5 C5.72385763,5.5 5.5,5.72385763 5.5,6 C5.5,6.27614237 5.72385763,6.5 6,6.5 Z" />
|
|
160
|
+
</svg>
|
|
161
|
+
`,li=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
162
|
+
<path fill="none" stroke="#ef9f76" stroke-linecap="round" stroke-linejoin="round" d="M4.5 13.5c-.33.33-.5.67-.5 1s.17.67.5 1c.17-.67.5-1 1-1s.83.33 1 1c.33-.33.5-.83.5-1.5h2c0 .67.17 1.17.5 1.5.17-.67.5-1 1-1s.83.33 1 1c.33-.33.5-.67.5-1s-.17-.67-.5-1l1-1 1.25 1.25c0-2.75 1-2.75 1-5.75a7.1 7.1 0 00-2-5.25A3.64 3.64 0 0113 .5c-1.17 0-2 .42-2.5 1.25A3.08 3.08 0 008 .5c-1 0-1.83.42-2.5 1.25C5 .92 4.17.5 3 .5c.5.83.58 1.58.25 2.25a7.1 7.1 0 00-2 5.25c0 3 1 3 1 5.75L3.5 12.5zm6-5a2 2 0 100-4 2 2 0 000 4m-5 0a2 2 0 100-4 2 2 0 000 4M7 8l1 2.5L9 8m1.5-1.5" />
|
|
163
|
+
</svg>
|
|
164
|
+
`,ii=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
165
|
+
<g fill="none" stroke-linecap="round" stroke-linejoin="round">
|
|
166
|
+
<path stroke="#8caaee" d="M8.5 5.5h-3m6 0V3c0-.8-.7-1.5-1.5-1.5H7c-.8 0-1.5.7-1.5 1.5v2.5H3c-.8 0-1.5.7-1.5 1.5v2c0 .8.7 1.5 1.48 1.5" />
|
|
167
|
+
<path stroke="#e5c890" d="M10.5 10.5h-3m-3 0V13c0 .8.7 1.5 1.5 1.5h3c.8 0 1.5-.7 1.5-1.5v-2.5H13c.8 0 1.5-.7 1.5-1.5V7c0-.8-.7-1.5-1.48-1.5H11.5c0 1.5 0 2-1 2h-2" />
|
|
168
|
+
<path stroke="#8caaee" d="M2.98 10.5H4.5c0-1.5 0-2 1-2h2M7.5 3.5v0" />
|
|
169
|
+
<path stroke="#e5c890" d="m 8.5,12.5 v 0" />
|
|
170
|
+
</g>
|
|
171
|
+
</svg>
|
|
172
|
+
`,si=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
173
|
+
<g fill="none" stroke-linecap="round" stroke-linejoin="round">
|
|
174
|
+
<path stroke="#838ba7" d="M13.5 9.5c.63-.7 1-1.54 1-2.43 0-2.52-2.91-4.57-6.5-4.57S1.5 4.55 1.5 7.07c0 1.9 1.65 3.53 4 4.22" />
|
|
175
|
+
<path stroke="#8caaee" d="M10.5 9.5c.4 0 .86.34 1 .7l1 3.3m-5 0v-8h3.05c.95 0 1.95 1 1.95 2s-1 2-1.95 2H7.5Z" />
|
|
176
|
+
</g>
|
|
177
|
+
</svg>
|
|
178
|
+
`,ci=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
179
|
+
<path fill="none" stroke="#e78284" stroke-linecap="round" stroke-linejoin="round" d="M1.5 9.06v2.5c.02.86.36 1.61.9 2.15 1.76 1.76 5.71.65 8.84-2.47 3.12-3.13 4.23-7.08 2.47-8.84a3.1 3.1 0 00-2.15-.9h-2.5M14.5 4l-.25 10.25L4 14.5m4.39-6.11c2.34-2.35 3.29-5.2 2.12-6.37S6.49 1.8 4.14 4.14C1.8 6.5.85 9.34 2.02 10.51s4.02.22 6.37-2.12M5.5 14.5l.25-3.75L11 11l-.25-5.25 3.75-.25" />
|
|
180
|
+
</svg>
|
|
181
|
+
`,ui=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
182
|
+
<g fill="none" stroke="#ef9f76" stroke-linecap="round" stroke-linejoin="round">
|
|
183
|
+
<path d="M15.5 9.5Q8 13.505.5 9.5l1-1-1-2 2-.5V4.5h2l.5-2 1.5 1 1.5-2 1.5 2 1.5-1 .5 2h2V6l2 .5-1 2z" />
|
|
184
|
+
<path d="M6.5 7.5a1 1 0 01-1 1 1 1 0 01-1-1 1 1 0 011-1 1 1 0 011 1m5 0a1 1 0 01-1 1 1 1 0 01-1-1 1 1 0 011-1 1 1 0 011 1M4 11.02c-.67.37-1.5.98-1.5 2.23s1.22 1.22 2 1.25v-2M12 11c.67.37 1.5 1 1.5 2.25s-1.22 1.22-2 1.25v-2" />
|
|
185
|
+
</g>
|
|
186
|
+
</svg>
|
|
187
|
+
`,di=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
188
|
+
<path fill="none" stroke="#f4b8e4" stroke-linecap="round" stroke-linejoin="round" d="M6.75 6.38c1.85 1.07 3.35.74 4.83-.2 1.5-.95 2.7-2.78 1.3-4.15-.7-.68-3.25-.8-5.62.19-2.36.99-4.59 3.02-4.74 4.11-.31 2.19 3.15 2.88 3.64 4.23s.28 1.98-.2 2.83c-.5.85-1.96 1.62-2.8.68-.83-.95 1.67-2.75 2.98-3.25 1.3-.5 3.1-.4 3.69.25.58.64-.07 1.79-.03 1.79" />
|
|
189
|
+
</svg>
|
|
190
|
+
`,mi=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
191
|
+
<path fill="none" stroke="#e78284" stroke-linecap="round" stroke-linejoin="round" d="m2.5 2.48 11-.98v3.04l-11 1zm0 5 11-.98v3.04l-11 1zm0 5 11-.98v3.04l-11 1z" />
|
|
192
|
+
</svg>
|
|
193
|
+
`,fi=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
194
|
+
<g fill="none" stroke="#8caaee" stroke-linecap="round" stroke-linejoin="round">
|
|
195
|
+
<path d="M2 15.5c-.7 0-1.5-.8-1.5-1.5V5c0-.7.8-1.5 1.5-1.5h9c.7 0 1.5.8 1.5 1.5v9c0 .7-.8 1.5-1.5 1.5z" />
|
|
196
|
+
<path d="m1.2 3.8 3.04-2.5S5.17.5 5.7.5h8.4c.66 0 1.4.73 1.4 1.4v7.73a2.7 2.7 0 01-.7 1.75l-2.68 3.51M3 8.5l3 2-3 2m4 0h2" />
|
|
197
|
+
</g>
|
|
198
|
+
</svg>
|
|
199
|
+
`,pi=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
200
|
+
<path fill="none" stroke="#ca9ee6" stroke-linecap="round" stroke-linejoin="round" d="m3 11.5 2.5 4 2.5-4 2.5 4 2.5-4-2.5-4-2.5 4m2.5 4h-5m7.5-4H3m10-7-2.5-4-2.5 4-2.5-4-2.5 4 2.5 4 2.5-4M5.5.5h5M3 4.5h10" />
|
|
201
|
+
</svg>
|
|
202
|
+
`,hi=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
203
|
+
<path fill="none" stroke="#e5c890" stroke-linecap="round" stroke-linejoin="round" d="M8 6.5c3.59 0 6.5-1.4 6.5-2.68S11.59 1.5 8 1.5 1.5 2.54 1.5 3.82 4.41 6.5 8 6.5M14.5 8c0 .83-1.24 1.79-3.25 2.2s-4.49.41-6.5 0S1.5 8.83 1.5 8m13 4.18c0 .83-1.24 1.6-3.25 2-2.01.42-4.49.42-6.5 0-2.01-.4-3.25-1.17-3.25-2m0-8.3v8.3m13-8.3v8.3" />
|
|
204
|
+
</svg>
|
|
205
|
+
`,vi='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="16" height="16"><!-- Icon from Lucide by Lucide Contributors - https://github.com/lucide-icons/lucide/blob/main/LICENSE --><g fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><path d="m10 9l-3 3l3 3m4 0l3-3l-3-3"/><rect width="18" height="18" x="3" y="3" rx="2"/></g></svg>',gi=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
206
|
+
<path fill="none" stroke="#ef9f76" stroke-linecap="round" stroke-linejoin="round" d="m4.54 10 6.92-4m-6.92 4a1.5 1.5 0 10-2.6 1.5 1.5 1.5 0 002.6-1.5M8 4v8m0-8a1.5 1.5 0 100-3 1.5 1.5 0 000 3M4.54 6l6.92 4M4.54 6a1.5 1.5 0 10-2.6-1.5A1.5 1.5 0 004.54 6M8 12a1.5 1.5 0 100 3 1.5 1.5 0 000-3m3.46-2a1.5 1.5 0 102.6 1.5 1.5 1.5 0 00-2.6-1.5m0-4a1.5 1.5 0 102.6-1.5 1.5 1.5 0 00-2.6 1.5" />
|
|
207
|
+
</svg>
|
|
208
|
+
`,wi=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
209
|
+
<path fill="none" stroke="#ef9f76" stroke-linecap="round" stroke-linejoin="round" d="M14.34 10.2c.34-1.08 1.1-5.07-4.45-8.62a.48.48 0 00-.6.07.44.44 0 00-.02.6c.03.02 2.07 2.5 1.34 5.34-1.26-.86-6.24-4.81-6.24-4.81L7.25 7.5 1.9 4.05S5.68 8.7 8 10.45c-1.12.4-3.56.82-6.78-1.18a.48.48 0 00-.58.06.44.44 0 00-.08.56c.11.18 2.7 4.36 8.14 4.36 1.5 0 2.37-.42 3.08-.77.43-.2.77-.37 1.14-.37.93 0 1.54.92 1.54.93.1.14.27.22.44.21a.46.46 0 00.4-.28c.67-1.55-.49-3.2-.96-3.78h0Z" />
|
|
210
|
+
</svg>
|
|
211
|
+
`,ki=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
212
|
+
<path fill="none" stroke="#ca9ee6" stroke-linecap="round" stroke-linejoin="round" d="m1.5 6 8 4.25 4-2.25m-12-2V1.5l8 4.25 4-2.25V8m-4-2.25v8.75M5.53 3.82 5.5 12.5l4 2" />
|
|
213
|
+
</svg>
|
|
214
|
+
`,yi=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
215
|
+
<g fill="none" stroke="#c6d0f5" stroke-linecap="round" stroke-linejoin="round">
|
|
216
|
+
<path d="M13.5 6.5v6a2 2 0 01-2 2h-7a2 2 0 01-2-2v-9c0-1.1.9-2 2-2h4.01" />
|
|
217
|
+
<path d="m8.5 1.5 5 5h-4a1 1 0 01-1-1zm-3 10h5m-5-3h5m-5-3h1" />
|
|
218
|
+
</g>
|
|
219
|
+
</svg>
|
|
220
|
+
`,xi=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
221
|
+
<g fill="none" stroke="#8caaee" stroke-linecap="round" stroke-linejoin="round">
|
|
222
|
+
<path d="M8 11.3c4.14 0 7.5-1.28 7.5-2.86S12.14 5.58 8 5.58.5 6.86.5 8.44s3.36 2.87 7.5 2.87Z" />
|
|
223
|
+
<path d="M5.52 9.87c2.07 3.6 4.86 5.86 6.23 5.07 1.37-.8.8-4.34-1.27-7.93S5.62 1.16 4.25 1.95s-.8 4.34 1.27 7.92" />
|
|
224
|
+
<path d="M5.52 7.01c-2.07 3.59-2.64 7.14-1.27 7.93s4.16-1.48 6.23-5.07c2.07-3.58 2.64-7.13 1.27-7.92-1.37-.8-4.16 1.47-6.23 5.06" />
|
|
225
|
+
<path d="M8.5 8.44a.5.5 0 01-.5.5.5.5 0 01-.5-.5.5.5 0 01.5-.5.5.5 0 01.5.5" />
|
|
226
|
+
</g>
|
|
227
|
+
</svg>
|
|
228
|
+
`,bi=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
229
|
+
<g fill="none" stroke="#8caaee" stroke-linecap="round" stroke-linejoin="round">
|
|
230
|
+
<path d="M4 1.5h8A2.5 2.5 0 0114.5 4v8a2.5 2.5 0 01-2.5 2.5H4A2.5 2.5 0 011.5 12V4A2.5 2.5 0 014 1.5" />
|
|
231
|
+
<path d="M12.5 8.75c0-.69-.54-1.25-1.2-1.25h-.6c-.66 0-1.2.56-1.2 1.25S10.04 10 10.7 10h.6c.66 0 1.2.56 1.2 1.25s-.54 1.25-1.2 1.25h-.6c-.66 0-1.2-.56-1.2-1.25m-3-3.75v5M5 7.5h3" />
|
|
232
|
+
</g>
|
|
233
|
+
</svg>
|
|
234
|
+
`,Bi='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32" width="16" height="16"><!-- Icon from VSCode Icons by Roberto Huertas - https://github.com/vscode-icons/vscode-icons/blob/master/LICENSE --><path fill="#00519a" d="M6.67 7.836L9 18.915l2.336-11.079H16l-4.664 16.328H6.672L2 7.836Zm11.661 0h7.6a4.08 4.08 0 0 1 2.9 1.749a3.8 3.8 0 0 1 .571 2.04a4 4 0 0 1-.571 2.034a4.1 4.1 0 0 1-2.341 1.763a4.1 4.1 0 0 1 2.929 1.756a3.8 3.8 0 0 1 .58 2.1a4.66 4.66 0 0 1-.579 2.546a5.05 5.05 0 0 1-3.5 2.338h-7.589ZM23 14.252h1.166a1.754 1.754 0 0 0 0-3.5H23Zm0 7h1.39a2.047 2.047 0 0 0 0-4.089H23Z"/></svg>',Mi=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
235
|
+
<g fill="none" stroke="#a6d189" stroke-linecap="round" stroke-linejoin="round">
|
|
236
|
+
<path d="M1 1.5h5.44L8 4.56 9.56 1.5H15l-6.99 13z" />
|
|
237
|
+
<path d="M12.05 1.73 8 9.28 3.95 1.73" />
|
|
238
|
+
</g>
|
|
239
|
+
</svg>
|
|
240
|
+
`,Ci=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
241
|
+
<path fill="none" stroke="#ef9f76" stroke-linecap="round" stroke-linejoin="round" d="M4.5 4.5 1 8 4.5 11.5M11.5 4.5 15 8 11.5 11.5M9.5 2 6.5 14" />
|
|
242
|
+
</svg>
|
|
243
|
+
`,Ei=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16">
|
|
244
|
+
<path fill="none" stroke="#e78284" stroke-linecap="round" stroke-linejoin="round" d="M2.5 1.5h3l3 4 3-4h3l-9 13h-3L7 8z" />
|
|
245
|
+
</svg>
|
|
246
|
+
`;let Fn=null;function No(t){Fn=t!=null?t:null}const Ni={"":"",javascript:"javascript",js:"javascript",mjs:"javascript",cjs:"javascript",typescript:"typescript",ts:"typescript",jsx:"jsx",tsx:"tsx",golang:"go",py:"python",rb:"ruby",sh:"shell",bash:"shell",zsh:"shell",shellscript:"shell",bat:"shell",batch:"shell",ps1:"powershell",plaintext:"plain",text:"plain","c++":"cpp","c#":"csharp","objective-c":"objectivec","objective-c++":"objectivecpp",yml:"yaml",md:"markdown",rs:"rust",kt:"kotlin"};function Ti(t){if(!t)return"";const o=t.trim();if(!o)return"";const[n]=o.split(/\s+/),[i]=n.split(":");return i.toLowerCase()}function Jn(t){var n;const o=Ti(t);return(n=Ni[o])!=null?n:o}function _i(t){const o=Jn(t);if(!o)return"plaintext";switch(o){case"plain":return"plaintext";case"jsx":return"javascript";case"tsx":return"typescript";default:return o}}function To(t){if(Fn){const n=Fn(t);if(n!=null&&n!=="")return n}switch(Jn(t)){case"javascript":case"js":return Wl;case"typescript":case"ts":return bi;case"jsx":return Ol;case"tsx":return xi;case"html":return Fl;case"css":return $l;case"scss":return di;case"json":return Xl;case"python":case"py":return ii;case"ruby":case"rb":return ci;case"go":case"golang":return jl;case"r":return si;case"java":return Kl;case"kotlin":case"kt":return Yl;case"c":return El;case"cpp":case"c++":return _l;case"cs":case"csharp":return Il;case"php":return ai;case"scala":return mi;case"shell":case"sh":case"bash":case"zsh":case"powershell":case"ps1":case"bat":case"batch":case"shellscript":return fi;case"sql":return hi;case"yaml":case"yml":return Ei;case"markdown":case"md":return Gl;case"xml":return Ci;case"rust":case"rs":return ui;case"swift":return wi;case"perl":return ri;case"lua":return Zl;case"haskell":return Pl;case"erlang":return zl;case"clojure":return Nl;case"vue":return Mi;case"svg":return gi;case"mermaid":return Ql;case"dart":return Vl;case"assembly":return Cl;case"dockerfile":return Dl;case"fortran":return Al;case"lisp":return ql;case"ocaml":return oi;case"prolog":return li;case"groovy":return Hl;case"matlab":return Jl;case"cobol":return Tl;case"ada":return Bl;case"julia":return Ul;case"elixir":return Rl;case"vb.net":return Bi;case"nim":return ei;case"crystal":return Sl;case"d":return Ll;case"applescript":return Ml;case"solidity":return pi;case"objectivec":return ti;case"objectivecpp":return ni;case"terraform":return ki;case"plain":case"text":case"":return yi;default:return vi}}const _o={js:"JavaScript",javascript:"JavaScript",ts:"TypeScript",jsx:"JSX",tsx:"TSX",html:"HTML",css:"CSS",scss:"SCSS",json:"JSON",py:"Python",python:"Python",rb:"Ruby",go:"Go",java:"Java",c:"C",cpp:"C++",cs:"C#",php:"PHP",sh:"Shell",bash:"Bash",sql:"SQL",yaml:"YAML",md:"Markdown","":"Plain Text",plain:"Plain Text"},Si={key:0,class:"code-block-header flex justify-between items-center px-4 py-2.5 border-b border-gray-400/5",style:{color:"var(--vscode-editor-foreground)","background-color":"var(--vscode-editor-background)"}},Ii={class:"flex items-center space-x-2"},$i=["innerHTML"],Vi={class:"text-sm font-medium font-mono"},Li={class:"flex items-center space-x-2"},Di=["aria-pressed"],Ri=["disabled"],zi=["disabled"],Ai=["disabled"],ji=["aria-label"],Hi={key:0,xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},Pi={key:1,xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},Fi=["aria-pressed"],Ki={key:0,xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"0.75rem",height:"0.75rem",viewBox:"0 0 24 24"},Oi={key:1,xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"0.75rem",height:"0.75rem",viewBox:"0 0 24 24"},Wi=["aria-label"],Xi=["innerHTML"],Ui={class:"code-loading-placeholder"},io=10,so=36,co=1,Yi=e.defineComponent({__name:"MarkdownCodeBlockNode",props:{node:{},loading:{type:Boolean,default:!0},stream:{type:Boolean,default:!0},darkTheme:{default:"vitesse-dark"},lightTheme:{default:"vitesse-light"},isDark:{type:Boolean,default:!1},isShowPreview:{type:Boolean,default:!0},enableFontSizeControl:{type:Boolean,default:!0},minWidth:{default:void 0},maxWidth:{default:void 0},themes:{},showHeader:{type:Boolean,default:!0},showCopyButton:{type:Boolean,default:!0},showExpandButton:{type:Boolean,default:!0},showPreviewButton:{type:Boolean,default:!0},showFontSizeButtons:{type:Boolean,default:!0}},emits:["previewCode","copy"],setup(t,{emit:o}){var me;const n=t,i=o,{t:a}=_n(),m=e.ref(String((me=n.node.language)!=null?me:"")),u=e.ref(!1),f=e.ref(!1),g=e.ref(!1),p=e.ref(null),k=e.ref(null),x=e.ref(""),B=e.ref(!1);let S;const V=e.ref(!0),R=e.ref(0),O=e.ref(14),b=e.ref(O.value),Z=e.computed(()=>{const h=O.value,y=b.value;return typeof h=="number"&&Number.isFinite(h)&&h>0&&typeof y=="number"&&Number.isFinite(y)&&y>0}),ie=e.computed(()=>{const h=m.value.trim().toLowerCase();return _o[h]||h.charAt(0).toUpperCase()+h.slice(1)}),j=e.computed(()=>m.value.trim().toLowerCase()==="mermaid"),Y=e.computed(()=>{const h=m.value.trim().toLowerCase();return To(h.split(":")[0])}),I=e.computed(()=>{const h=m.value.trim().toLowerCase();return n.isShowPreview&&(h==="html"||h==="svg")}),P=e.computed(()=>{const h={},y=fe=>{if(fe!=null)return typeof fe=="number"?`${fe}px`:String(fe)},M=y(n.minWidth),z=y(n.maxWidth);return M&&(h.minWidth=M),z&&(h.maxWidth=z),h}),je=e.computed(()=>({fontSize:`${b.value}px`}));function Re(){return n.isDark?n.darkTheme:n.lightTheme}function se(h){return h.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function F(h){if(S==null||S.disconnect(),S=void 0,!h){x.value="",B.value=!1;return}x.value=`<pre class="shiki shiki-fallback"><code>${se(h)}</code></pre>`,B.value=!1}function Te(){x.value="",B.value=!0}function G(){var y;const h=k.value;return h?h.childNodes.length>0?!0:!!((y=h.textContent)!=null&&y.trim().length):!1}function ct(){return $(this,null,function*(){if(yield e.nextTick(),G()){Te();return}const h=k.value;h&&(S==null||S.disconnect(),S=new MutationObserver(()=>{G()&&(Te(),S==null||S.disconnect(),S=void 0)}),S.observe(h,{childList:!0,subtree:!0}))})}let _,K,D,ee=()=>{},Xe;const J=new Set,Ue=new Set,ne=typeof{url:typeof document=="undefined"?require("url").pathToFileURL(__filename).href:Rn&&Rn.tagName.toUpperCase()==="SCRIPT"&&Rn.src||new URL("exports-Dt9os3zH.cjs",document.baseURI).href}!="undefined"&&!1;function he(h,y=!1){var fe;const[M]=String(h!=null?h:"").split(":"),z=(fe=M==null?void 0:M.trim().toLowerCase())!=null?fe:"";return z?!Xe||Xe.has(z)?z:(y&&ne&&!J.has(z)&&(J.add(z),console.warn(`[MarkdownCodeBlockNode] Language "${z}" not preloaded in stream-markdown; falling back to plaintext.`)),"plaintext"):"plaintext"}function tt(h,y){return $(this,null,function*(){if(!_)return;const M=he(y,!!(h&&h.length));try{yield _.updateCode(h,M)}catch(z){M!=="plaintext"?(ne&&!Ue.has(M)&&(Ue.add(M),console.warn(`[MarkdownCodeBlockNode] Failed to render language "${M}", retrying as plaintext.`,z)),yield _.updateCode(h,"plaintext")):ne&&console.warn("[MarkdownCodeBlockNode] Failed to render code block even as plaintext.",z)}})}function ut(){return $(this,null,function*(){if(!K)try{const h=yield import("stream-markdown");K=h.createShikiStreamRenderer,D=h.registerHighlight,ee=h.disposeHighlighter;const y=Array.isArray(h.defaultLanguages)?h.defaultLanguages:void 0;Xe=y?new Set(y.map(M=>M.toLowerCase())):void 0,D==null||D({themes:n.themes})}catch(h){console.warn("[MarkdownCodeBlockNode] stream-markdown not available:",h)}})}function _e(){return $(this,null,function*(){if(j.value){ee(),_==null||_.dispose(),_=void 0,B.value=!1;return}if(yield ut(),!p.value||!k.value){F(n.node.code);return}if(D==null||D({themes:n.themes}),!_&&K&&(_=K(k.value,{theme:Re()}),B.value=!0),!_){F(n.node.code);return}if(n.stream===!1&&n.loading){F(n.node.code);return}F(n.node.code),yield tt(n.node.code,m.value),yield ct()})}_e(),e.onMounted(()=>{_e()}),e.watch(()=>n.themes,()=>$(null,null,function*(){D&&D({themes:n.themes})})),e.watch(()=>n.loading,h=>{h||_e()}),e.watch(()=>[n.node.code,n.node.language],M=>$(null,[M],function*([h,y]){if(y!==m.value&&(m.value=y.trim()),!p.value||!k.value){F(h);return}if(j.value){ee(),_==null||_.dispose();return}_||(F(h),yield _e()),!(!_||!h)&&(n.stream===!1&&n.loading||(F(h),yield tt(h,y),yield ct()))}));const Ye=e.watch(()=>[n.darkTheme,n.lightTheme],()=>$(null,null,function*(){if(!(!p.value||!k.value)){if(j.value)return ee(),_==null||_.dispose(),Ye();_||(yield _e()),_==null||_.setTheme(Re())}}));e.watch(()=>n.node.code,()=>$(null,null,function*(){if(f.value||!V.value)return;yield e.nextTick();const h=p.value;h&&h.scrollHeight>h.clientHeight&&(h.scrollTop=h.scrollHeight)}));function nt(h,y=50){return h.scrollHeight-h.scrollTop-h.clientHeight<=y}function kt(){const h=p.value;if(!h||f.value)return;const y=h.scrollTop;y<R.value?V.value=!1:nt(h)&&(V.value=!0),R.value=y}function de(){return $(this,null,function*(){try{typeof navigator!="undefined"&&navigator.clipboard&&typeof navigator.clipboard.writeText=="function"&&(yield navigator.clipboard.writeText(n.node.code)),u.value=!0,i("copy",n.node.code),setTimeout(()=>{u.value=!1},1e3)}catch(h){console.error("Copy failed:",h)}})}function He(h){const y=h;return!y||y.disabled}function Q(h,y,M="top"){if(He(h.currentTarget))return;const z=h,fe=(z==null?void 0:z.clientX)!=null&&(z==null?void 0:z.clientY)!=null?{x:z.clientX,y:z.clientY}:void 0;on(h.currentTarget,y,M,!1,fe,n.isDark)}function U(){Tn()}function ge(h){if(He(h.currentTarget))return;const y=u.value?a("common.copied")||"Copied":a("common.copy")||"Copy",M=h,z=(M==null?void 0:M.clientX)!=null&&(M==null?void 0:M.clientY)!=null?{x:M.clientX,y:M.clientY}:void 0;on(h.currentTarget,y,"top",!1,z,n.isDark)}function W(){f.value=!f.value;const h=p.value;h&&(f.value?(h.style.maxHeight="none",h.style.overflow="visible"):(h.style.maxHeight="500px",h.style.overflow="auto",V.value=!0,e.nextTick(()=>{h.scrollHeight>h.clientHeight&&(h.scrollTop=h.scrollHeight)})))}function qe(){g.value=!g.value}function Se(){const h=Math.min(so,b.value+co);b.value=h}function Bt(){const h=Math.max(io,b.value-co);b.value=h}function dt(){b.value=O.value}function Mt(){if(!I.value)return;const h=(m.value||n.node.language).toLowerCase(),y=h==="html"?"text/html":"image/svg+xml",M=h==="html"?"HTML Preview":"SVG Preview";i("previewCode",{type:y,content:n.node.code,title:M})}return(h,y)=>j.value?(e.openBlock(),e.createBlock(e.unref(Dt),{key:0,node:t.node,"is-dark":n.isDark,loading:n.loading},null,8,["node","is-dark","loading"])):(e.openBlock(),e.createElementBlock("div",{key:1,style:e.normalizeStyle(P.value),class:e.normalizeClass(["code-block-container my-4 rounded-lg border overflow-hidden shadow-sm",[n.isDark?"border-gray-700/30 bg-gray-900":"border-gray-200 bg-white",n.isDark?"is-dark":""]])},[n.showHeader?(e.openBlock(),e.createElementBlock("div",Si,[e.renderSlot(h.$slots,"header-left",{},()=>[e.createElementVNode("div",Ii,[e.createElementVNode("span",{class:"icon-slot h-4 w-4 flex-shrink-0",innerHTML:Y.value},null,8,$i),e.createElementVNode("span",Vi,e.toDisplayString(ie.value),1)])],!0),e.renderSlot(h.$slots,"header-right",{},()=>[e.createElementVNode("div",Li,[e.createElementVNode("button",{type:"button",class:"code-action-btn p-2 text-xs rounded-md transition-colors hover:bg-[var(--vscode-editor-selectionBackground)]","aria-pressed":g.value,onClick:qe,onMouseenter:y[0]||(y[0]=M=>Q(M,g.value?e.unref(a)("common.expand")||"Expand":e.unref(a)("common.collapse")||"Collapse")),onFocus:y[1]||(y[1]=M=>Q(M,g.value?e.unref(a)("common.expand")||"Expand":e.unref(a)("common.collapse")||"Collapse")),onMouseleave:U,onBlur:U},[(e.openBlock(),e.createElementBlock("svg",{style:e.normalizeStyle({rotate:g.value?"0deg":"90deg"}),xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},[...y[17]||(y[17]=[e.createElementVNode("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m9 18l6-6l-6-6"},null,-1)])],4))],40,Di),n.showFontSizeButtons&&n.enableFontSizeControl?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("button",{type:"button",class:"code-action-btn p-2 text-xs rounded-md transition-colors hover:bg-[var(--vscode-editor-selectionBackground)]",disabled:Number.isFinite(b.value)?b.value<=io:!1,onClick:y[2]||(y[2]=M=>Bt()),onMouseenter:y[3]||(y[3]=M=>Q(M,e.unref(a)("common.decrease")||"Decrease")),onFocus:y[4]||(y[4]=M=>Q(M,e.unref(a)("common.decrease")||"Decrease")),onMouseleave:U,onBlur:U},[...y[18]||(y[18]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},[e.createElementVNode("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M5 12h14"})],-1)])],40,Ri),e.createElementVNode("button",{type:"button",class:"code-action-btn p-2 text-xs rounded-md transition-colors hover:bg-[var(--vscode-editor-selectionBackground)]",disabled:!Z.value||b.value===O.value,onClick:y[5]||(y[5]=M=>dt()),onMouseenter:y[6]||(y[6]=M=>Q(M,e.unref(a)("common.reset")||"Reset")),onFocus:y[7]||(y[7]=M=>Q(M,e.unref(a)("common.reset")||"Reset")),onMouseleave:U,onBlur:U},[...y[19]||(y[19]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},[e.createElementVNode("g",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2"},[e.createElementVNode("path",{d:"M3 12a9 9 0 1 0 9-9a9.75 9.75 0 0 0-6.74 2.74L3 8"}),e.createElementVNode("path",{d:"M3 3v5h5"})])],-1)])],40,zi),e.createElementVNode("button",{type:"button",class:"code-action-btn p-2 text-xs rounded-md transition-colors hover:bg-[var(--vscode-editor-selectionBackground)]",disabled:Number.isFinite(b.value)?b.value>=so:!1,onClick:y[8]||(y[8]=M=>Se()),onMouseenter:y[9]||(y[9]=M=>Q(M,e.unref(a)("common.increase")||"Increase")),onFocus:y[10]||(y[10]=M=>Q(M,e.unref(a)("common.increase")||"Increase")),onMouseleave:U,onBlur:U},[...y[20]||(y[20]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},[e.createElementVNode("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M5 12h14m-7-7v14"})],-1)])],40,Ai)],64)):e.createCommentVNode("",!0),n.showCopyButton?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"code-action-btn p-2 text-xs rounded-md transition-colors hover:bg-[var(--vscode-editor-selectionBackground)]","aria-label":u.value?e.unref(a)("common.copied")||"Copied":e.unref(a)("common.copy")||"Copy",onClick:de,onMouseenter:y[11]||(y[11]=M=>ge(M)),onFocus:y[12]||(y[12]=M=>ge(M)),onMouseleave:U,onBlur:U},[u.value?(e.openBlock(),e.createElementBlock("svg",Pi,[...y[22]||(y[22]=[e.createElementVNode("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M20 6L9 17l-5-5"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",Hi,[...y[21]||(y[21]=[e.createElementVNode("g",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2"},[e.createElementVNode("rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2"}),e.createElementVNode("path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"})],-1)])]))],40,ji)):e.createCommentVNode("",!0),n.showExpandButton?(e.openBlock(),e.createElementBlock("button",{key:2,type:"button",class:"code-action-btn p-2 text-xs rounded-md transition-colors hover:bg-[var(--vscode-editor-selectionBackground)]","aria-pressed":f.value,onClick:W,onMouseenter:y[13]||(y[13]=M=>Q(M,f.value?e.unref(a)("common.collapse")||"Collapse":e.unref(a)("common.expand")||"Expand")),onFocus:y[14]||(y[14]=M=>Q(M,f.value?e.unref(a)("common.collapse")||"Collapse":e.unref(a)("common.expand")||"Expand")),onMouseleave:U,onBlur:U},[f.value?(e.openBlock(),e.createElementBlock("svg",Ki,[...y[23]||(y[23]=[e.createElementVNode("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M15 3h6v6m0-6l-7 7M3 21l7-7m-1 7H3v-6"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",Oi,[...y[24]||(y[24]=[e.createElementVNode("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m14 10l7-7m-1 7h-6V4M3 21l7-7m-6 0h6v6"},null,-1)])]))],40,Fi)):e.createCommentVNode("",!0),I.value&&n.showPreviewButton?(e.openBlock(),e.createElementBlock("button",{key:3,type:"button",class:"code-action-btn p-2 text-xs rounded-md transition-colors hover:bg-[var(--vscode-editor-selectionBackground)]","aria-label":e.unref(a)("common.preview")||"Preview",onClick:Mt,onMouseenter:y[15]||(y[15]=M=>Q(M,e.unref(a)("common.preview")||"Preview")),onFocus:y[16]||(y[16]=M=>Q(M,e.unref(a)("common.preview")||"Preview")),onMouseleave:U,onBlur:U},[...y[25]||(y[25]=[e.createElementVNode("svg",{"data-v-3d59cc65":"",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",class:"w-3 h-3"},[e.createElementVNode("g",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2"},[e.createElementVNode("path",{d:"M2.062 12.348a1 1 0 0 1 0-.696a10.75 10.75 0 0 1 19.876 0a1 1 0 0 1 0 .696a10.75 10.75 0 0 1-19.876 0"}),e.createElementVNode("circle",{cx:"12",cy:"12",r:"3"})])],-1)])],40,Wi)):e.createCommentVNode("",!0)])],!0)])):e.createCommentVNode("",!0),e.withDirectives(e.createElementVNode("div",{ref_key:"codeBlockContent",ref:p,class:"code-block-content",style:e.normalizeStyle(je.value),onScroll:kt},[e.createElementVNode("div",{ref_key:"rendererTarget",ref:k,class:"code-block-render"},null,512),B.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:"code-fallback-plain",innerHTML:x.value},null,8,Xi))],36),[[e.vShow,!g.value&&(t.stream?!0:!t.loading)]]),e.withDirectives(e.createElementVNode("div",Ui,[e.renderSlot(h.$slots,"loading",{loading:t.loading,stream:t.stream},()=>[y[26]||(y[26]=e.createElementVNode("div",{class:"loading-skeleton"},[e.createElementVNode("div",{class:"skeleton-line"}),e.createElementVNode("div",{class:"skeleton-line"}),e.createElementVNode("div",{class:"skeleton-line short"})],-1))],!0)],512),[[e.vShow,!t.stream&&t.loading]])],6))}}),fn=H(Yi,[["__scopeId","data-v-34bf55f7"]]);fn.install=t=>{t.component(fn.__name,fn)};let We=null,bt=null,uo=!1;const Ie=new Map,vt=new Map,So=200;let At=5;const $t=new Set;function vn(){if(Ie.size<At&&$t.size){const t=Array.from($t);$t.clear();for(const o of t)try{o()}catch(n){}}}let it=null;function qi(t){We=t,bt=null,We.onmessage=o=>{const{id:n,html:i,error:a}=o.data,m=Ie.get(n);if(m)if(Ie.delete(n),clearTimeout(m.timeoutId),vn(),a)m.reject(new Error(a));else{const{content:u,displayMode:f}=o.data;if(u){const g=`${f?"d":"i"}:${u}`;if(vt.set(g,i),vt.size>So){const p=vt.keys().next().value;vt.delete(p)}}m.resolve(i)}},We.onerror=o=>{console.error("[katexWorkerClient] Worker error:",o);for(const[n,i]of Ie.entries())clearTimeout(i.timeoutId),i.reject(new Error(`Worker error: ${o.message}`));Ie.clear(),vn()}}function Zi(){var t;We&&((t=We.terminate)==null||t.call(We)),We=null,bt=null}function Gi(){return We||(bt=new Error("[katexWorkerClient] No worker instance set. Please inject a Worker via setKaTeXWorker()."),bt.name="WorkerInitError",bt.code="WORKER_INIT_ERROR",null)}function Ji(t){uo=!!t,We&&We.postMessage({type:"init",debug:uo})}function Io(t,o=!0,n=2e3,i){return $(this,null,function*(){const a=performance.now();if(!Yn()){const g=new Error("KaTeX rendering disabled");return g.name="KaTeXDisabled",g.code="KATEX_DISABLED",Promise.reject(g)}if(bt)return Promise.reject(bt);const m=`${o?"d":"i"}:${t}`,u=vt.get(m);if(u)return it&&it.recordRender({type:"cache-hit",duration:performance.now()-a,formulaLength:t.length,timestamp:Date.now(),success:!0}),Promise.resolve(u);const f=Gi();if(!f)return Promise.reject(bt);if(Ie.size>=At){const g=new Error("Worker busy");return g.name="WorkerBusy",g.code="WORKER_BUSY",g.busy=!0,g.inFlight=Ie.size,g.max=At,it&&it.recordRender({type:"worker",duration:performance.now()-a,formulaLength:t.length,timestamp:Date.now(),success:!1,error:"busy"}),Promise.reject(g)}return new Promise((g,p)=>{if(i!=null&&i.aborted){const b=new Error("Aborted");b.name="AbortError",p(b);return}const k=Math.random().toString(36).slice(2),x=globalThis.setTimeout(()=>{Ie.delete(k);const b=new Error("Worker render timed out");b.name="WorkerTimeout",b.code="WORKER_TIMEOUT",it&&it.recordRender({type:"worker",duration:performance.now()-a,formulaLength:t.length,timestamp:Date.now(),success:!1,error:"timeout"}),p(b),vn()},n),B=()=>{globalThis.clearTimeout(x),Ie.has(k)&&Ie.delete(k);const b=new Error("Aborted");b.name="AbortError",p(b),vn()};i&&i.addEventListener("abort",B,{once:!0});const S=g,V=p,R=b=>{it&&it.recordRender({type:"worker",duration:performance.now()-a,formulaLength:t.length,timestamp:Date.now(),success:!0}),S(b)},O=b=>{it&&it.recordRender({type:"worker",duration:performance.now()-a,formulaLength:t.length,timestamp:Date.now(),success:!1,error:(b==null?void 0:b.message)||String(b)}),V(b)};Ie.set(k,{resolve:R,reject:O,timeoutId:x}),f.postMessage({id:k,content:t,displayMode:o})})})}function Qi(t,o=!0,n){const i=`${o?"d":"i"}:${t}`;if(vt.set(i,n),vt.size>So){const a=vt.keys().next().value;vt.delete(a)}}function es(){return{inFlight:Ie.size,max:At}}function ts(t){Number.isFinite(t)&&t>0&&(At=Math.floor(t))}const $o="WORKER_BUSY";function ns(){return Ie.size>=At}function Vo(t=2e3,o){return Ie.size<At?Promise.resolve():new Promise((n,i)=>{let a=!1,m;const u=()=>{a||(a=!0,m&&globalThis.clearTimeout(m),$t.delete(u),n())};if($t.add(u),m=globalThis.setTimeout(()=>{if(a)return;a=!0,$t.delete(u);const f=new Error("Wait for worker slot timed out");f.name="WorkerBusyTimeout",f.code="WORKER_BUSY_TIMEOUT",i(f)},t),queueMicrotask(()=>vn()),o){const f=()=>{if(a)return;a=!0,m&&globalThis.clearTimeout(m),$t.delete(u);const g=new Error("Aborted");g.name="AbortError",i(g)};o.aborted?f():o.addEventListener("abort",f,{once:!0})}})}const gt={timeout:2e3,waitTimeout:1500,backoffMs:30,maxRetries:1};function os(t){t.timeout!=null&&(gt.timeout=Math.max(0,Math.floor(t.timeout))),t.waitTimeout!=null&&(gt.waitTimeout=Math.max(0,Math.floor(t.waitTimeout))),t.backoffMs!=null&&(gt.backoffMs=Math.max(0,Math.floor(t.backoffMs))),t.maxRetries!=null&&(gt.maxRetries=Math.max(0,Math.floor(t.maxRetries)))}function rs(){return q({},gt)}function as(i){return $(this,arguments,function*(t,o=!0,n={}){var k,x,B,S;if(!Yn()){const V=new Error("KaTeX rendering disabled");throw V.name="KaTeXDisabled",V.code="KATEX_DISABLED",V}const a=(k=n.timeout)!=null?k:gt.timeout,m=(x=n.waitTimeout)!=null?x:gt.waitTimeout,u=(B=n.backoffMs)!=null?B:gt.backoffMs,f=(S=n.maxRetries)!=null?S:gt.maxRetries,g=n.signal;let p=0;for(;;){if(g!=null&&g.aborted){const V=new Error("Aborted");throw V.name="AbortError",V}try{return yield Io(t,o,a,g)}catch(V){if((V==null?void 0:V.code)!==$o||p>=f)throw V;if(p++,yield Vo(m,g).catch(()=>{}),g!=null&&g.aborted){const R=new Error("Aborted");throw R.name="AbortError",R}u>0&&(yield new Promise(R=>globalThis.setTimeout(R,u*p)))}}})}const Lo=e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./index-BOMIs5jY.cjs"))),Do=e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./index-DVzzMFW2.cjs"))),Ro=e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./index-W52qnVsg.cjs"))),ls={AdmonitionNode:nn,BlockquoteNode:Yt,CheckboxNode:Qe,CodeBlockNode:Lo,DefinitionListNode:qt,EmojiNode:xe,FootnoteNode:Zt,FootnoteReferenceNode:be,FootnoteAnchorNode:Lt,HardBreakNode:yt,HeadingNode:$n,HtmlInlineNode:Rt,HighlightNode:De,ImageNode:wt,InlineCodeNode:Be,PreCodeNode:zt,InsertNode:Le,LinkNode:Ne,ListItemNode:Gt,ListNode:Jt,MathBlockNode:Do,MathInlineNode:Ro,MermaidBlockNode:Dt,ParagraphNode:Qt,StrikethroughNode:Ee,StrongNode:Ce,SubscriptNode:Ve,SuperscriptNode:$e,TableNode:en,TextNode:ue,ThematicBreakNode:tn,ReferenceNode:Me,MarkdownCodeBlockNode:fn},is={install(t,o){Object.entries(ls).forEach(([n,i])=>{t.component(n,i)}),o!=null&&o.getLanguageIcon&&No(o.getLanguageIcon),o!=null&&o.mathOptions&&An.setDefaultMathOptions(o.mathOptions)}};exports.AdmonitionNode=nn;exports.BlockquoteNode=Yt;exports.CheckboxNode=Qe;exports.CodeBlockNode=Lo;exports.DefinitionListNode=qt;exports.EmojiNode=xe;exports.FootnoteAnchorNode=Lt;exports.FootnoteReferenceNode=be;exports.HardBreakNode=yt;exports.HighlightNode=De;exports.HtmlInlineNode=Rt;exports.ImageNode=wt;exports.InsertNode=Le;exports.LinkNode=Ne;exports.ListItemNode=Gt;exports.ListNode=Jt;exports.MERMAID_DISABLED_CODE=Bo;exports.MERMAID_WORKER_BUSY_CODE=bo;exports.MarkdownCodeBlockNode=fn;exports.MathBlockNode=Do;exports.MathInlineNode=Ro;exports.MermaidBlockNode=Dt;exports.NodeRenderer=ze;exports.ParagraphNode=Qt;exports.StrikethroughNode=Ee;exports.StrongNode=Ce;exports.SubscriptNode=Ve;exports.SuperscriptNode=$e;exports.TableNode=en;exports.TextNode=ue;exports.ThematicBreakNode=tn;exports.VueRendererMarkdown=is;exports.WORKER_BUSY_CODE=$o;exports._HeadingNode=$n;exports._export_sfc=H;exports._sfc_main=zt;exports._sfc_main$1=Zt;exports._sfc_main$2=Be;exports._sfc_main$3=Me;exports.canParseOffthread=Co;exports.clearGlobalCustomComponents=ar;exports.clearKaTeXWorker=Zi;exports.clearMermaidWorker=ka;exports.disableKatex=Nr;exports.disableMermaid=ua;exports.enableKatex=Er;exports.enableMermaid=ca;exports.findPrefixOffthread=Eo;exports.getCustomNodeComponents=et;exports.getKaTeXBackpressureDefaults=rs;exports.getKaTeXWorkerLoad=es;exports.getKatex=In;exports.getLanguageIcon=To;exports.getMermaidWorkerLoad=ga;exports.getUseMonaco=bl;exports.hideTooltip=Tn;exports.isKaTeXWorkerBusy=ns;exports.isKatexEnabled=Yn;exports.isMermaidEnabled=xo;exports.languageMap=_o;exports.normalizeLanguageIdentifier=Jn;exports.removeCustomComponents=rr;exports.renderKaTeXInWorker=Io;exports.renderKaTeXWithBackpressure=as;exports.resolveMonacoLanguageId=_i;exports.safeRaf=yo;exports.setCustomComponents=or;exports.setDefaultI18nMap=hr;exports.setKaTeXBackpressureDefaults=os;exports.setKaTeXCache=Qi;exports.setKaTeXWorker=qi;exports.setKaTeXWorkerDebug=Ji;exports.setKaTeXWorkerMaxConcurrency=ts;exports.setKatexLoader=Un;exports.setLanguageIconResolver=No;exports.setMermaidLoader=Gn;exports.setMermaidWorker=wa;exports.setMermaidWorkerClientDebug=ha;exports.setMermaidWorkerMaxConcurrency=va;exports.showTooltipForAnchor=on;exports.terminateWorker=Pn;exports.useSafeI18n=_n;exports.useViewportPriority=Sn;exports.waitForKaTeXWorkerSlot=Vo;
|