const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/angular-html-CU67Zn6k.js","assets/html-GMplVEZG.js","assets/javascript-wDzz0qaB.js","assets/css-DPfMkruS.js","assets/angular-ts-BwZT4LLn.js","assets/scss-OYdSNvt2.js","assets/apl-dKokRX4l.js","assets/xml-sdJ4AIDG.js","assets/java-CylS5w8V.js","assets/json-Cp-IABpG.js","assets/astro-CbQHKStN.js","assets/typescript-BPQ3VLAy.js","assets/postcss-CXtECtnM.js","assets/tsx-COt5Ahok.js","assets/blade-DVc8C-J4.js","assets/html-derivative-BFtXZ54Q.js","assets/sql-BLtJtn59.js","assets/bsl-BO_Y6i37.js","assets/sdbl-DVxCFoDh.js","assets/cairo-KRGpt6FW.js","assets/python-B6aJPvgy.js","assets/cobol-nwyudZeR.js","assets/coffee-Ch7k5sss.js","assets/cpp-CofmeUqb.js","assets/regexp-CDVJQ6XC.js","assets/glsl-DplSGwfg.js","assets/c-BIGW1oBm.js","assets/crystal-tKQVLTB8.js","assets/shellscript-Yzrsuije.js","assets/edge-BkV0erSs.js","assets/elixir-CDX3lj18.js","assets/elm-DbKCFpqz.js","assets/erb-BOJIQeun.js","assets/ruby-BvKwtOVI.js","assets/haml-B8DHNrY2.js","assets/graphql-ChdNCCLP.js","assets/jsx-g9-lgVsj.js","assets/lua-BbnMAYS6.js","assets/yaml-Buea-lGh.js","assets/erlang-DsQrWhSR.js","assets/markdown-Cvjx9yec.js","assets/fortran-fixed-form-BZjJHVRy.js","assets/fortran-free-form-D22FLkUw.js","assets/fsharp-CXgrBDvD.js","assets/gdresource-B7Tvp0Sc.js","assets/gdshader-DkwncUOv.js","assets/gdscript-DTMYz4Jt.js","assets/git-commit-F4YmCXRG.js","assets/diff-D97Zzqfu.js","assets/git-rebase-r7XF79zn.js","assets/glimmer-js-Rg0-pVw9.js","assets/glimmer-ts-U6CK756n.js","assets/hack-CaT9iCJl.js","assets/handlebars-BL8al0AC.js","assets/http-jrhK8wxY.js","assets/hurl-irOxFIW8.js","assets/csv-fuZLfV_i.js","assets/hxml-Bvhsp5Yf.js","assets/haxe-CzTSHFRz.js","assets/jinja-4LBKfQ-Z.js","assets/jison-wvAkD_A8.js","assets/julia-C8NyazO9.js","assets/r-DiinP2Uv.js","assets/latex-BdAV_C_H.js","assets/tex-CxkMU7Pf.js","assets/liquid-DYVedYrR.js","assets/marko-CPi9NSCl.js","assets/less-B1dDrJ26.js","assets/mdc-DUICxH0z.js","assets/nginx-DknmC5AR.js","assets/nim-CVrawwO9.js","assets/perl-C0TMdlhV.js","assets/php-CDn_0X-4.js","assets/pug-CGlum2m_.js","assets/qml-3beO22l8.js","assets/razor-CE9lU5zL.js","assets/csharp-K5feNrxe.js","assets/rst-B0xPkSld.js","assets/cmake-D1j8_8rp.js","assets/sas-cz2c8ADy.js","assets/shaderlab-Dg9Lc6iA.js","assets/hlsl-D3lLCCz7.js","assets/shellsession-BADoaaVG.js","assets/soy-Brmx7dQM.js","assets/sparql-rVzFXLq3.js","assets/turtle-BsS91CYL.js","assets/stata-BH5u7GGu.js","assets/svelte-3Dk4HxPD.js","assets/templ-W15q3VgB.js","assets/go-Dn2_MT6a.js","assets/ts-tags-zn1MmPIZ.js","assets/twig-CO9l9SDP.js","assets/vue-DnHKYNfI.js","assets/vue-html-CChd_i61.js","assets/vue-vine-8moa0y9V.js","assets/stylus-BEDo0Tqx.js","assets/xsl-CtQFsRM5.js","assets/angular-html-6NEUuZou.js","assets/html-DBrZJmtb.js","assets/javascript-XPxc2APE.js","assets/css-BSK200cd.js","assets/angular-ts-BfBSdvnY.js","assets/scss-Dk05w39G.js","assets/apl-C-KxP0FL.js","assets/xml-DtyAt_xK.js","assets/java-B2AjWfgk.js","assets/json-CjLXzM_z.js","assets/astro-OEl6i-aI.js","assets/typescript-DttGkNCf.js","assets/postcss-BSGhOJ4k.js","assets/tsx-Dio8iE-N.js","assets/blade-CwZbp2Ca.js","assets/html-derivative-DgyNW28a.js","assets/sql-CKXjX23X.js","assets/bsl-C4qeDxuX.js","assets/sdbl-C5Q1usnU.js","assets/cairo-C_mOTUpN.js","assets/python-DgE28U1V.js","assets/cobol-Cg3yRVOY.js","assets/coffee-CSg58a7P.js","assets/cpp-C28rag7_.js","assets/regexp-BW_zLBm-.js","assets/glsl-Bk7TyU8J.js","assets/c-CyUOlKFr.js","assets/crystal-kLfOnxTY.js","assets/shellscript-CE-5zpiL.js","assets/edge-C9mkmEUa.js","assets/elixir-B1OcFvXE.js","assets/elm-BX_9EnK8.js","assets/erb-CjsbKF3w.js","assets/ruby-CHyTNJrF.js","assets/haml-C-C08OMF.js","assets/graphql-By4-2MiP.js","assets/jsx-BGEKFWBk.js","assets/lua-tkfysgZP.js","assets/yaml-B92AUxDB.js","assets/erlang-Dh270pQQ.js","assets/markdown-CKXSK5AY.js","assets/fortran-fixed-form-VBUom2Po.js","assets/fortran-free-form-xZZnushS.js","assets/fsharp-B6CigNpP.js","assets/gdresource-B57lXvxj.js","assets/gdshader-MbeiIFWW.js","assets/gdscript-etqGfJNh.js","assets/git-commit-BicZTByO.js","assets/diff-BlzBhZx2.js","assets/git-rebase-Bzlpfr7M.js","assets/glimmer-js-cZi37nA1.js","assets/glimmer-ts-BY3QTAW9.js","assets/hack-Ce3HFLQu.js","assets/handlebars-BFxKmXBZ.js","assets/http-D0p2QOuJ.js","assets/hurl-CeF7EoTQ.js","assets/csv-AZNL9t8Q.js","assets/hxml-B_SuSTPP.js","assets/haxe-n0Q_eay_.js","assets/jinja-DlBE7Xgz.js","assets/jison-DRGa8fbr.js","assets/julia-Bh5qjrIj.js","assets/r-BfG_C0qz.js","assets/latex-BuzO6rjU.js","assets/tex-DZ7Smwga.js","assets/liquid-DdraCjph.js","assets/marko-BsqRlKIY.js","assets/less-C76OjOdF.js","assets/mdc-BBM-UqJy.js","assets/nginx-XmDIhN78.js","assets/nim-Cm6-Nayq.js","assets/perl-Djxv1YJ9.js","assets/php-DEfiO3Bd.js","assets/pug-ClQUpJlV.js","assets/qml-BEkX6VoX.js","assets/razor-8rj0VRTp.js","assets/csharp-DFQpaWb6.js","assets/rst-8IYWyo0X.js","assets/cmake-Cv5ljclQ.js","assets/sas-BZeeyq_z.js","assets/shaderlab-DNkMdb2B.js","assets/hlsl-Pefxhtaj.js","assets/shellsession-BhddCRKA.js","assets/soy-C6ERzLIv.js","assets/sparql-CHK3vDkL.js","assets/turtle-whXsfw69.js","assets/stata-BJqnY-gO.js","assets/svelte-DmnhoTkn.js","assets/templ-CyHhV9jl.js","assets/go-BYCC9JQ2.js","assets/ts-tags-DMPjx__B.js","assets/twig-vsFUeHgy.js","assets/vue-BJuclMoA.js","assets/vue-html-CRAum25o.js","assets/vue-vine-CDS6dxm6.js","assets/stylus-CHekGIgu.js","assets/xsl-Btrj9DhN.js"])))=>i.map(i=>d[i]); (function(){const A=document.createElement("link").relList;if(A&&A.supports&&A.supports("modulepreload"))return;for(const n of document.querySelectorAll('link[rel="modulepreload"]'))r(n);new MutationObserver(n=>{for(const i of n)if(i.type==="childList")for(const o of i.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function t(n){const i={};return n.integrity&&(i.integrity=n.integrity),n.referrerPolicy&&(i.referrerPolicy=n.referrerPolicy),n.crossOrigin==="use-credentials"?i.credentials="include":n.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(n){if(n.ep)return;n.ep=!0;const i=t(n);fetch(n.href,i)}})();const Ix=!1,lx=(e,A)=>e===A,An=Symbol("solid-proxy"),mm=typeof Proxy=="function",gs=Symbol("solid-track"),Qs={equals:lx};let TQ=null,pm=vm;const yn=1,Bs=2,km={owned:null,cleanups:null,context:null,owner:null},DC={};var ke=null;let fC=null,cx=null,He=null,Wt=null,Xr=null,nE=0;function Si(e,A){const t=He,r=ke,n=e.length===0,i=A===void 0?r:A,o=n?km:{owned:null,cleanups:null,context:i?i.context:null,owner:i},g=n?e:()=>e(()=>fe(()=>WQ(o)));ke=o,He=null;try{return mn(g,!0)}finally{He=t,ke=r}}function gA(e,A){A=A?Object.assign({},Qs,A):Qs;const t={value:e,observers:null,observerSlots:null,comparator:A.equals||void 0},r=n=>(typeof n=="function"&&(n=n(t.value)),Nm(t,n));return[Mm.bind(t),r]}function ym(e,A,t){const r=fB(e,A,!0,yn);Yg(r)}function _A(e,A,t){const r=fB(e,A,!1,yn);Yg(r)}function tA(e,A,t){pm=mx;const r=fB(e,A,!1,yn);(!t||!t.render)&&(r.user=!0),Xr?Xr.push(r):Yg(r)}function S(e,A,t){t=t?Object.assign({},Qs,t):Qs;const r=fB(e,A,!0,0);return r.observers=null,r.observerSlots=null,r.comparator=t.equals||void 0,Yg(r),Mm.bind(r)}function ux(e){return e&&typeof e=="object"&&"then"in e}function Ji(e,A,t){let r,n,i;typeof A=="function"?(r=e,n=A,i=t||{}):(r=!0,n=e,i=A||{});let o=null,g=DC,Q=!1,B="initialValue"in i,a=typeof r=="function"&&S(r);const s=new Set,[C,E]=(i.storage||gA)(i.initialValue),[I,c]=gA(void 0),[u,h]=gA(void 0,{equals:!1}),[d,f]=gA(B?"ready":"unresolved");function m(v,O,W,AA){return o===v&&(o=null,AA!==void 0&&(B=!0),(v===g||O===g)&&i.onHydrated&&queueMicrotask(()=>i.onHydrated(AA,{value:O})),g=DC,k(O,W)),O}function k(v,O){mn(()=>{O===void 0&&E(()=>v),f(O!==void 0?"errored":B?"ready":"unresolved"),c(O);for(const W of s.keys())W.decrement();s.clear()},!1)}function N(){const v=Dx,O=C(),W=I();if(W!==void 0&&!o)throw W;return He&&He.user,O}function F(v=!0){if(v!==!1&&Q)return;Q=!1;const O=a?a():r;if(O==null||O===!1){m(o,fe(C));return}let W;const AA=g!==DC?g:fe(()=>{try{return n(O,{value:C(),refetching:v})}catch(kA){W=kA}});if(W!==void 0){m(o,void 0,Pa(W),O);return}else if(!ux(AA))return m(o,AA,void 0,O),AA;return o=AA,"v"in AA?(AA.s===1?m(o,AA.v,void 0,O):m(o,void 0,Pa(AA.v),O),AA):(Q=!0,queueMicrotask(()=>Q=!1),mn(()=>{f(B?"refreshing":"pending"),h()},!1),AA.then(kA=>m(AA,kA,void 0,O),kA=>m(AA,void 0,Pa(kA),O)))}Object.defineProperties(N,{state:{get:()=>d()},error:{get:()=>I()},loading:{get(){const v=d();return v==="pending"||v==="refreshing"}},latest:{get(){if(!B)return N();const v=I();if(v&&!o)throw v;return C()}}});let L=ke;return a?ym(()=>(L=ke,F(!1))):F(!1),[N,{refetch:v=>DB(L,()=>F(v)),mutate:E}]}function st(e){return mn(e,!1)}function fe(e){if(He===null)return e();const A=He;He=null;try{return e()}finally{He=A}}function be(e,A,t){const r=Array.isArray(e);let n,i=t&&t.defer;return o=>{let g;if(r){g=Array(e.length);for(let B=0;BA(g,n,o));return n=g,Q}}function et(e){tA(()=>fe(e))}function dA(e){return ke===null||(ke.cleanups===null?ke.cleanups=[e]:ke.cleanups.push(e)),e}function dx(e,A){TQ||(TQ=Symbol("error")),ke=fB(void 0,void 0,!0),ke.context={...ke.context,[TQ]:[A]};try{return e()}catch(t){wB(t)}finally{ke=ke.owner}}function OI(){return He}function iE(){return ke}function DB(e,A){const t=ke,r=He;ke=e,He=null;try{return mn(A,!0)}catch(n){wB(n)}finally{ke=t,He=r}}function hx(e){const A=He,t=ke;return Promise.resolve().then(()=>{He=A,ke=t;let r;return mn(e,!1),He=ke=null,r?r.done:void 0})}const[SnA,JnA]=gA(!1);function ye(e,A){const t=Symbol("context");return{id:t,Provider:px(t),defaultValue:e}}function pe(e){let A;return ke&&ke.context&&(A=ke.context[e.id])!==void 0?A:e.defaultValue}function ji(e){const A=S(e),t=S(()=>qI(A()));return t.toArray=()=>{const r=t();return Array.isArray(r)?r:r!=null?[r]:[]},t}let Dx;function Mm(){if(this.sources&&this.state)if(this.state===yn)Yg(this);else{const e=Wt;Wt=null,mn(()=>ss(this),!1),Wt=e}if(He){const e=this.observers?this.observers.length:0;He.sources?(He.sources.push(this),He.sourceSlots.push(e)):(He.sources=[this],He.sourceSlots=[e]),this.observers?(this.observers.push(He),this.observerSlots.push(He.sources.length-1)):(this.observers=[He],this.observerSlots=[He.sources.length-1])}return this.value}function Nm(e,A,t){let r=e.value;return(!e.comparator||!e.comparator(r,A))&&(e.value=A,e.observers&&e.observers.length&&mn(()=>{for(let n=0;n1e6)throw Wt=[],new Error},!1)),A}function Yg(e){if(!e.fn)return;WQ(e);const A=nE;fx(e,e.value,A)}function fx(e,A,t){let r;const n=ke,i=He;He=ke=e;try{r=e.fn(A)}catch(o){return e.pure&&(e.state=yn,e.owned&&e.owned.forEach(WQ),e.owned=null),e.updatedAt=t+1,wB(o)}finally{He=i,ke=n}(!e.updatedAt||e.updatedAt<=t)&&(e.updatedAt!=null&&"observers"in e?Nm(e,r):e.value=r,e.updatedAt=t)}function fB(e,A,t,r=yn,n){const i={fn:e,state:r,updatedAt:null,owned:null,sources:null,sourceSlots:null,cleanups:null,value:A,owner:ke,context:ke?ke.context:null,pure:t};return ke===null||ke!==km&&(ke.owned?ke.owned.push(i):ke.owned=[i]),i}function as(e){if(e.state===0)return;if(e.state===Bs)return ss(e);if(e.suspense&&fe(e.suspense.inFallback))return e.suspense.effects.push(e);const A=[e];for(;(e=e.owner)&&(!e.updatedAt||e.updatedAt=0;t--)if(e=A[t],e.state===yn)Yg(e);else if(e.state===Bs){const r=Wt;Wt=null,mn(()=>ss(e,A[0]),!1),Wt=r}}function mn(e,A){if(Wt)return e();let t=!1;A||(Wt=[]),Xr?t=!0:Xr=[],nE++;try{const r=e();return wx(t),r}catch(r){t||(Xr=null),Wt=null,wB(r)}}function wx(e){if(Wt&&(vm(Wt),Wt=null),e)return;const A=Xr;Xr=null,A.length&&mn(()=>pm(A),!1)}function vm(e){for(let A=0;A=0;A--)WQ(e.tOwned[A]);delete e.tOwned}if(e.owned){for(A=e.owned.length-1;A>=0;A--)WQ(e.owned[A]);e.owned=null}if(e.cleanups){for(A=e.cleanups.length-1;A>=0;A--)e.cleanups[A]();e.cleanups=null}e.state=0}function Pa(e){return e instanceof Error?e:new Error(typeof e=="string"?e:"Unknown error",{cause:e})}function Qh(e,A,t){try{for(const r of A)r(e)}catch(r){wB(r,t&&t.owner||null)}}function wB(e,A=ke){const t=TQ&&A&&A.context&&A.context[TQ],r=Pa(e);if(!t)throw r;Xr?Xr.push({fn(){Qh(r,t,A)},state:yn}):Qh(r,t,A)}function qI(e){if(typeof e=="function"&&!e.length)return qI(e());if(Array.isArray(e)){const A=[];for(let t=0;tn=fe(()=>(ke.context={...ke.context,[e]:r.value},ji(()=>r.children))),void 0),n}}const kx=Symbol("fallback");function Bh(e){for(let A=0;A1?[]:null;return dA(()=>Bh(i)),()=>{let Q=e()||[],B=Q.length,a,s;return Q[gs],fe(()=>{let E,I,c,u,h,d,f,m,k;if(B===0)o!==0&&(Bh(i),i=[],r=[],n=[],o=0,g&&(g=[])),t.fallback&&(r=[kx],n[0]=Si(N=>(i[0]=N,t.fallback())),o=1);else if(o===0){for(n=new Array(B),s=0;s=d&&m>=d&&r[f]===Q[m];f--,m--)c[m]=n[f],u[m]=i[f],g&&(h[m]=g[f]);for(E=new Map,I=new Array(m+1),s=m;s>=d;s--)k=Q[s],a=E.get(k),I[s]=a===void 0?-1:a,E.set(k,s);for(a=d;a<=f;a++)k=r[a],s=E.get(k),s!==void 0&&s!==-1?(c[s]=n[a],u[s]=i[a],g&&(h[s]=g[a]),s=I[s],E.set(k,s)):i[a]();for(s=d;se(A||{}))}function Ea(){return!0}const TI={get(e,A,t){return A===An?t:e.get(A)},has(e,A){return A===An?!0:e.has(A)},set:Ea,deleteProperty:Ea,getOwnPropertyDescriptor(e,A){return{configurable:!0,enumerable:!0,get(){return e.get(A)},set:Ea,deleteProperty:Ea}},ownKeys(e){return e.keys()}};function wC(e){return(e=typeof e=="function"?e():e)?e:{}}function Mx(){for(let e=0,A=this.length;e=0;g--){const Q=wC(e[g])[o];if(Q!==void 0)return Q}},has(o){for(let g=e.length-1;g>=0;g--)if(o in wC(e[g]))return!0;return!1},keys(){const o=[];for(let g=0;g=0;o--){const g=e[o];if(!g)continue;const Q=Object.getOwnPropertyNames(g);for(let B=Q.length-1;B>=0;B--){const a=Q[B];if(a==="__proto__"||a==="constructor")continue;const s=Object.getOwnPropertyDescriptor(g,a);if(!r[a])r[a]=s.get?{enumerable:!0,configurable:!0,get:Mx.bind(t[a]=[s.get.bind(g)])}:s.value!==void 0?s:void 0;else{const C=t[a];C&&(s.get?C.push(s.get.bind(g)):s.value!==void 0&&C.push(()=>s.value))}}}const n={},i=Object.keys(r);for(let o=i.length-1;o>=0;o--){const g=i[o],Q=r[g];Q&&Q.get?Object.defineProperty(n,g,Q):n[g]=Q?Q.value:void 0}return n}function eA(e,...A){const t=A.length;if(mm&&An in e){const n=t>1?A.flat():A[0],i=A.map(o=>new Proxy({get(g){return o.includes(g)?e[g]:void 0},has(g){return o.includes(g)&&g in e},keys(){return o.filter(g=>g in e)}},TI));return i.push(new Proxy({get(o){return n.includes(o)?void 0:e[o]},has(o){return n.includes(o)?!1:o in e},keys(){return Object.keys(e).filter(o=>!n.includes(o))}},TI)),i}const r=[];for(let n=0;n<=t;n++)r[n]={};for(const n of Object.getOwnPropertyNames(e)){let i=t;for(let Q=0;Q`Stale read from <${e}>.`;function Ke(e){const A="fallback"in e&&{fallback:()=>e.fallback};return S(yx(()=>e.each,e.children,A||void 0))}function Y(e){const A=e.keyed,t=S(()=>e.when,void 0,void 0),r=A?t:S(t,void 0,{equals:(n,i)=>!n==!i});return S(()=>{const n=r();if(n){const i=e.children;return typeof i=="function"&&i.length>0?fe(()=>i(A?n:()=>{if(!fe(r))throw Fm("Show");return t()})):i}return e.fallback},void 0,void 0)}function Je(e){const A=ji(()=>e.children),t=S(()=>{const r=A(),n=Array.isArray(r)?r:[r];let i=()=>{};for(let o=0;oB()?void 0:Q.when,void 0,void 0),s=Q.keyed?a:S(a,void 0,{equals:(C,E)=>!C==!E});i=()=>B()||(s()?[g,a,Q]:void 0)}return i});return S(()=>{const r=t()();if(!r)return e.fallback;const[n,i,o]=r,g=o.children;return typeof g=="function"&&g.length>0?fe(()=>g(o.keyed?i():()=>{if(fe(t)()?.[0]!==n)throw Fm("Match");return i()})):g},void 0,void 0)}function YA(e){return e}let Dg;function vx(){Dg&&[...Dg].forEach(e=>e())}function bx(e){let A;const[t,r]=gA(A,void 0);return Dg||(Dg=new Set),Dg.add(r),dA(()=>Dg.delete(r)),S(()=>{let n;if(n=t()){const i=e.fallback;return typeof i=="function"&&i.length?fe(()=>i(n,()=>r())):i}return dx(()=>e.children,r)},void 0,void 0)}const Fx=["allowfullscreen","async","alpha","autofocus","autoplay","checked","controls","default","disabled","formnovalidate","hidden","indeterminate","inert","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","seamless","selected","adauctionheaders","browsingtopics","credentialless","defaultchecked","defaultmuted","defaultselected","defer","disablepictureinpicture","disableremoteplayback","preservespitch","shadowrootclonable","shadowrootcustomelementregistry","shadowrootdelegatesfocus","shadowrootserializable","sharedstoragewritable"],xx=new Set(["className","value","readOnly","noValidate","formNoValidate","isMap","noModule","playsInline","adAuctionHeaders","allowFullscreen","browsingTopics","defaultChecked","defaultMuted","defaultSelected","disablePictureInPicture","disableRemotePlayback","preservesPitch","shadowRootClonable","shadowRootCustomElementRegistry","shadowRootDelegatesFocus","shadowRootSerializable","sharedStorageWritable",...Fx]),Gx=new Set(["innerHTML","textContent","innerText","children"]),Sx=Object.assign(Object.create(null),{className:"class",htmlFor:"for"}),Jx=Object.assign(Object.create(null),{class:"className",novalidate:{$:"noValidate",FORM:1},formnovalidate:{$:"formNoValidate",BUTTON:1,INPUT:1},ismap:{$:"isMap",IMG:1},nomodule:{$:"noModule",SCRIPT:1},playsinline:{$:"playsInline",VIDEO:1},readonly:{$:"readOnly",INPUT:1,TEXTAREA:1},adauctionheaders:{$:"adAuctionHeaders",IFRAME:1},allowfullscreen:{$:"allowFullscreen",IFRAME:1},browsingtopics:{$:"browsingTopics",IMG:1},defaultchecked:{$:"defaultChecked",INPUT:1},defaultmuted:{$:"defaultMuted",AUDIO:1,VIDEO:1},defaultselected:{$:"defaultSelected",OPTION:1},disablepictureinpicture:{$:"disablePictureInPicture",VIDEO:1},disableremoteplayback:{$:"disableRemotePlayback",AUDIO:1,VIDEO:1},preservespitch:{$:"preservesPitch",AUDIO:1,VIDEO:1},shadowrootclonable:{$:"shadowRootClonable",TEMPLATE:1},shadowrootdelegatesfocus:{$:"shadowRootDelegatesFocus",TEMPLATE:1},shadowrootserializable:{$:"shadowRootSerializable",TEMPLATE:1},sharedstoragewritable:{$:"sharedStorageWritable",IFRAME:1,IMG:1}});function Ux(e,A){const t=Jx[e];return typeof t=="object"?t[A]?t.$:void 0:t}const Kx=new Set(["beforeinput","click","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"]),Lx=new Set(["altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignObject","g","glyph","glyphRef","hkern","image","line","linearGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","set","stop","svg","switch","symbol","text","textPath","tref","tspan","use","view","vkern"]),Rx={xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace"},Ae=e=>S(()=>e());function Ox(e,A,t){let r=t.length,n=A.length,i=r,o=0,g=0,Q=A[n-1].nextSibling,B=null;for(;oa-g){const I=A[o];for(;g{n=i,A===document?e():M(A,e(),A.firstChild?null:void 0,t)},r.owner),()=>{n(),A.textContent=""}}function J(e,A,t,r){let n;const i=()=>{const g=r?document.createElementNS("http://www.w3.org/1998/Math/MathML","template"):document.createElement("template");return g.innerHTML=e,t?g.content.firstChild.firstChild:r?g.firstChild:g.content.firstChild},o=A?()=>fe(()=>document.importNode(n||(n=i()),!0)):()=>(n||(n=i())).cloneNode(!0);return o.cloneNode=o,o}function or(e,A=window.document){const t=A[ah]||(A[ah]=new Set);for(let r=0,n=e.length;rn.call(e,t[1],i))}else e.addEventListener(A,t,typeof t!="function"&&t)}function qe(e,A,t={}){const r=Object.keys(A||{}),n=Object.keys(t);let i,o;for(i=0,o=n.length;in.children=ZQ(e,A.children,n.children)),_A(()=>typeof A.ref=="function"&&Qt(A.ref,e)),_A(()=>Yx(e,A,t,!0,n,!0)),n}function Qt(e,A,t){return fe(()=>e(A,t))}function M(e,A,t,r){if(t!==void 0&&!r&&(r=[]),typeof A!="function")return ZQ(e,A,r,t);_A(n=>ZQ(e,A(),n,t),r)}function Yx(e,A,t,r,n={},i=!1){A||(A={});for(const o in n)if(!(o in A)){if(o==="children")continue;n[o]=Eh(e,o,null,n[o],t,i,A)}for(const o in A){if(o==="children")continue;const g=A[o];n[o]=Eh(e,o,g,n[o],t,i,A)}}function zx(e){return e.toLowerCase().replace(/-([a-z])/g,(A,t)=>t.toUpperCase())}function sh(e,A,t){const r=A.trim().split(/\s+/);for(let n=0,i=r.length;n-1&&Rx[A.split(":")[0]];C?Tx(e,C,A,t):ce(e,Sx[A]||A,t)}return t}function Px(e){let A=e.target;const t=`$$${e.type}`,r=e.target,n=e.currentTarget,i=Q=>Object.defineProperty(e,"target",{configurable:!0,value:Q}),o=()=>{const Q=A[t];if(Q&&!A.disabled){const B=A[`${t}Data`];if(B!==void 0?Q.call(A,B,e):Q.call(A,e),e.cancelBubble)return}return A.host&&typeof A.host!="string"&&!A.host._$host&&A.contains(e.target)&&i(A.host),!0},g=()=>{for(;o()&&(A=A._$host||A.parentNode||A.host););};if(Object.defineProperty(e,"currentTarget",{configurable:!0,get(){return A||document}}),e.composedPath){const Q=e.composedPath();i(Q[0]);for(let B=0;B{let g=A();for(;typeof g=="function";)g=g();t=ZQ(e,g,t,r)}),()=>t;if(Array.isArray(A)){const g=[],Q=t&&Array.isArray(t);if(HI(g,A,t,n))return _A(()=>t=ZQ(e,g,t,r,!0)),()=>t;if(g.length===0){if(t=tg(e,t,r),o)return t}else Q?t.length===0?Ch(e,g,r):Ox(e,t,g):(t&&tg(e),Ch(e,g));t=g}else if(A.nodeType){if(Array.isArray(t)){if(o)return t=tg(e,t,r,A);tg(e,t,null,A)}else t==null||t===""||!e.firstChild?e.appendChild(A):e.replaceChild(A,e.firstChild);t=A}}return t}function HI(e,A,t,r){let n=!1;for(let i=0,o=A.length;i=0;o--){const g=A[o];if(n!==g){const Q=g.parentNode===e;!i&&!o?Q?e.replaceChild(n,g):e.insertBefore(n,t):Q&&g.remove()}else i=!0}}else e.insertBefore(n,t);return[n]}const _x=!1,jx="http://www.w3.org/2000/svg";function xm(e,A=!1,t=void 0){return A?document.createElementNS(jx,e):document.createElement(e,{is:t})}function qo(e){const{useShadow:A}=e,t=document.createTextNode(""),r=()=>e.mount||document.body,n=iE();let i;return tA(()=>{i||(i=DB(n,()=>S(()=>e.children)));const o=r();if(o instanceof HTMLHeadElement){const[g,Q]=gA(!1),B=()=>Q(!0);Si(a=>M(o,()=>g()?a():i(),null)),dA(B)}else{const g=xm(e.isSVG?"g":"div",e.isSVG),Q=A&&g.attachShadow?g.attachShadow({mode:"open"}):g;Object.defineProperty(g,"_$host",{get(){return t.parentNode},configurable:!0}),M(Q,i),o.appendChild(g),e.ref&&e.ref(g),dA(()=>o.removeChild(g))}},void 0,{render:!0}),t}function Vx(e,A){const t=S(e);return S(()=>{const r=t();switch(typeof r){case"function":return fe(()=>r(A));case"string":const n=Lx.has(r),i=xm(r,n,fe(()=>A.is));return dt(i,A,n),i}})}function Mn(e){const[,A]=eA(e,["component"]);return Vx(()=>e.component,A)}function Gm(){let e=new Set;function A(n){return e.add(n),()=>e.delete(n)}let t=!1;function r(n,i){if(t)return!(t=!1);const o={to:n,options:i,defaultPrevented:!1,preventDefault:()=>o.defaultPrevented=!0};for(const g of e)g.listener({...o,from:g.location,retry:Q=>{Q&&(t=!0),g.navigate(n,{...i,resolve:!1})}});return!o.defaultPrevented}return{subscribe:A,confirm:r}}let YI;function yc(){(!window.history.state||window.history.state._depth==null)&&window.history.replaceState({...window.history.state,_depth:window.history.length-1},""),YI=window.history.state._depth}yc();function Wx(e){return{...e,_depth:window.history.state&&window.history.state._depth}}function Zx(e,A){let t=!1;return()=>{const r=YI;yc();const n=r==null?null:YI-r;if(t){t=!1;return}n&&A(n)?(t=!0,window.history.go(-n)):e()}}const Xx=/^(?:[a-z0-9]+:)?\/\//i,$x=/^\/+|(\/)\/+$/g,Sm="http://sr";function po(e,A=!1){const t=e.replace($x,"$1");return t?A||/^[?#]/.test(t)?t:"/"+t:""}function _a(e,A,t){if(Xx.test(A))return;const r=po(e),n=t&&po(t);let i="";return!n||A.startsWith("/")?i=r:n.toLowerCase().indexOf(r.toLowerCase())!==0?i=r+n:i=n,(i||"/")+po(A,!i)}function AG(e,A){if(e==null)throw new Error(A);return e}function eG(e,A){return po(e).replace(/\/*(\*.*)?$/g,"")+po(A)}function Jm(e){const A={};return e.searchParams.forEach((t,r)=>{r in A?Array.isArray(A[r])?A[r].push(t):A[r]=[A[r],t]:A[r]=t}),A}function tG(e,A,t){const[r,n]=e.split("/*",2),i=r.split("/").filter(Boolean),o=i.length;return g=>{const Q=g.split("/").filter(Boolean),B=Q.length-o;if(B<0||B>0&&n===void 0&&!A)return null;const a={path:o?"":"/",params:{}},s=C=>t===void 0?void 0:t[C];for(let C=0;Cr===e;return A===void 0?!0:typeof A=="string"?t(A):typeof A=="function"?A(e):Array.isArray(A)?A.some(t):A instanceof RegExp?A.test(e):!1}function rG(e){const[A,t]=e.pattern.split("/*",2),r=A.split("/").filter(Boolean);return r.reduce((n,i)=>n+(i.startsWith(":")?2:3),r.length-(t===void 0?0:1))}function Um(e){const A=new Map,t=iE();return new Proxy({},{get(r,n){return A.has(n)||DB(t,()=>A.set(n,S(()=>e()[n]))),A.get(n)()},getOwnPropertyDescriptor(){return{enumerable:!0,configurable:!0}},ownKeys(){return Reflect.ownKeys(e())},has(r,n){return n in e()}})}function Km(e){let A=/(\/?\:[^\/]+)\?/.exec(e);if(!A)return[e];let t=e.slice(0,A.index),r=e.slice(A.index+A[0].length);const n=[t,t+=A[1]];for(;A=/^(\/\:[^\/]+)\?/.exec(r);)n.push(t+=A[1]),r=r.slice(A[0].length);return Km(r).reduce((i,o)=>[...i,...n.map(g=>g+o)],[])}const nG=100,Lm=ye(),Mc=ye(),pB=()=>AG(pe(Lm)," and 'use' router primitives can be only used inside a Route."),iG=()=>pe(Mc)||pB().base,oG=e=>{const A=iG();return S(()=>A.resolvePath(e()))},gG=e=>{const A=pB();return S(()=>{const t=e();return t!==void 0?A.renderPath(t):t})},To=()=>pB().navigatorFactory(),Rm=()=>pB().location,Qn=()=>pB().params;function QG(e,A=""){const{component:t,preload:r,load:n,children:i,info:o}=e,g=!i||Array.isArray(i)&&!i.length,Q={key:e,component:t,preload:r||n,info:o};return Om(e.path).reduce((B,a)=>{for(const s of Km(a)){const C=eG(A,s);let E=g?C:C.split("/*",1)[0];E=E.split("/").map(I=>I.startsWith(":")||I.startsWith("*")?I:encodeURIComponent(I)).join("/"),B.push({...Q,originalPath:a,pattern:E,matcher:tG(E,!g,e.matchFilters)})}return B},[])}function BG(e,A=0){return{routes:e,score:rG(e[e.length-1])*1e4-A,matcher(t){const r=[];for(let n=e.length-1;n>=0;n--){const i=e[n],o=i.matcher(t);if(!o)return null;r.unshift({...o,route:i})}return r}}}function Om(e){return Array.isArray(e)?e:[e]}function qm(e,A="",t=[],r=[]){const n=Om(e);for(let i=0,o=n.length;io.score-i.score)}function pC(e,A){for(let t=0,r=e.length;t{const s=e();try{return new URL(s,r)}catch{return console.error(`Invalid path ${s}`),a}},r,{equals:(a,s)=>a.href===s.href}),i=S(()=>n().pathname),o=S(()=>n().search,!0),g=S(()=>n().hash),Q=()=>"",B=be(o,()=>Jm(n()));return{get pathname(){return i()},get search(){return o()},get hash(){return g()},get state(){return A()},get key(){return Q()},query:t?t(B):Um(B)}}let Io;function sG(){return Io}function EG(e,A,t,r={}){const{signal:[n,i],utils:o={}}=e,g=o.parsePath||(K=>K),Q=o.renderPath||(K=>K),B=o.beforeLeave||Gm(),a=_a("",r.base||"");if(a===void 0)throw new Error(`${a} is not a valid base path`);a&&!n().value&&i({value:a,replace:!0,scroll:!1});const[s,C]=gA(!1);let E;const I=(K,$)=>{$.value===c()&&$.state===h()||(E===void 0&&C(!0),Io=K,E=$,hx(()=>{E===$&&(u(E.value),d(E.state),vx(),k[1](P=>P.filter(SA=>SA.pending)))}).finally(()=>{E===$&&st(()=>{Io=void 0,K==="navigate"&&AA(E),C(!1),E=void 0})}))},[c,u]=gA(n().value),[h,d]=gA(n().state),f=aG(c,h,o.queryWrapper),m=[],k=gA([]),N=S(()=>typeof r.transformUrl=="function"?pC(A(),r.transformUrl(f.pathname)):pC(A(),f.pathname)),F=()=>{const K=N(),$={};for(let P=0;Pa,outlet:()=>null,resolvePath(K){return _a(a,K)}};return _A(be(n,K=>I("native",K),{defer:!0})),{base:v,location:f,params:L,isRouting:s,renderPath:Q,parsePath:g,navigatorFactory:W,matches:N,beforeLeave:B,preloadRoute:kA,singleFlight:r.singleFlight===void 0?!0:r.singleFlight,submissions:k};function O(K,$,P){fe(()=>{if(typeof $=="number"){$&&(o.go?o.go($):console.warn("Router integration does not support relative routing"));return}const SA=!$||$[0]==="?",{replace:fA,resolve:MA,scroll:mA,state:$A}={replace:!1,resolve:!SA,scroll:!0,...P},re=MA?K.resolvePath($):_a(SA&&f.pathname||"",$);if(re===void 0)throw new Error(`Path '${$}' is not a routable path`);if(m.length>=nG)throw new Error("Too many redirects");const de=c();(re!==de||$A!==h())&&(_x||B.confirm(re,P)&&(m.push({value:de,replace:fA,scroll:mA,state:h()}),I("navigate",{value:re,state:$A})))})}function W(K){return K=K||pe(Mc)||v,($,P)=>O(K,$,P)}function AA(K){const $=m[0];$&&(i({...K,replace:$.replace,scroll:$.scroll}),m.length=0)}function kA(K,$){const P=pC(A(),K.pathname),SA=Io;Io="preload";for(let fA in P){const{route:MA,params:mA}=P[fA];MA.component&&MA.component.preload&&MA.component.preload();const{preload:$A}=MA;$&&$A&&DB(t(),()=>$A({params:mA,location:{pathname:K.pathname,search:K.search,hash:K.hash,query:Jm(K),state:null,key:""},intent:"preload"}))}Io=SA}}function CG(e,A,t,r){const{base:n,location:i,params:o}=e,{pattern:g,component:Q,preload:B}=r().route,a=S(()=>r().path);Q&&Q.preload&&Q.preload();const s=B?B({params:o,location:i,intent:Io||"initial"}):void 0;return{parent:A,pattern:g,path:a,outlet:()=>Q?l(Q,{params:o,location:i,data:s,get children(){return t()}}):t(),resolvePath(E){return _a(n.path(),E,a())}}}const IG=e=>A=>{const{base:t}=A,r=ji(()=>A.children),n=S(()=>qm(r(),A.base||""));let i;const o=EG(e,n,()=>i,{base:t,singleFlight:A.singleFlight,transformUrl:A.transformUrl});return e.create&&e.create(o),l(Lm.Provider,{value:o,get children(){return l(lG,{routerState:o,get root(){return A.root},get preload(){return A.rootPreload||A.rootLoad},get children(){return[Ae(()=>(i=iE())&&null),l(cG,{routerState:o,get branches(){return n()}})]}})}})};function lG(e){const A=e.routerState.location,t=e.routerState.params,r=S(()=>e.preload&&fe(()=>{e.preload({params:t,location:A,intent:sG()||"initial"})}));return l(Y,{get when(){return e.root},keyed:!0,get fallback(){return e.children},children:n=>l(n,{params:t,location:A,get data(){return r()},get children(){return e.children}})})}function cG(e){const A=[];let t;const r=S(be(e.routerState.matches,(n,i,o)=>{let g=i&&n.length===i.length;const Q=[];for(let B=0,a=n.length;B{A[B]=E,Q[B]=CG(e.routerState,Q[B-1]||e.routerState.base,Ih(()=>r()[B+1]),()=>{const I=e.routerState.matches();return I[B]??I[0]})}))}return A.splice(n.length).forEach(B=>B()),o&&g?o:(t=Q[0],Q)}));return Ih(()=>r()&&t)()}const Ih=e=>()=>l(Y,{get when(){return e()},keyed:!0,children:A=>l(Mc.Provider,{value:A,get children(){return A.outlet()}})}),Ca=e=>{const A=ji(()=>e.children);return H(e,{get children(){return A()}})};function uG([e,A],t,r){return[e,r?n=>A(r(n)):A]}function dG(e){let A=!1;const t=n=>typeof n=="string"?{value:n}:n,r=uG(gA(t(e.get()),{equals:(n,i)=>n.value===i.value&&n.state===i.state}),void 0,n=>(!A&&e.set(n),n));return e.init&&dA(e.init((n=e.get())=>{A=!0,r[1](t(n)),A=!1})),IG({signal:r,create:e.create,utils:e.utils})}function hG(e,A,t){return e.addEventListener(A,t),()=>e.removeEventListener(A,t)}function DG(e,A){const t=e&&document.getElementById(e);t?t.scrollIntoView():A&&window.scrollTo(0,0)}const fG=new Map;function wG(e=!0,A=!1,t="/_server",r){return n=>{const i=n.base.path(),o=n.navigatorFactory(n.base);let g,Q;function B(c){return c.namespaceURI==="http://www.w3.org/2000/svg"}function a(c){if(c.defaultPrevented||c.button!==0||c.metaKey||c.altKey||c.ctrlKey||c.shiftKey)return;const u=c.composedPath().find(N=>N instanceof Node&&N.nodeName.toUpperCase()==="A");if(!u||A&&!u.hasAttribute("link"))return;const h=B(u),d=h?u.href.baseVal:u.href;if((h?u.target.baseVal:u.target)||!d&&!u.hasAttribute("state"))return;const m=(u.getAttribute("rel")||"").split(/\s+/);if(u.hasAttribute("download")||m&&m.includes("external"))return;const k=h?new URL(d,document.baseURI):new URL(d);if(!(k.origin!==window.location.origin||i&&k.pathname&&!k.pathname.toLowerCase().startsWith(i.toLowerCase())))return[u,k]}function s(c){const u=a(c);if(!u)return;const[h,d]=u,f=n.parsePath(d.pathname+d.search+d.hash),m=h.getAttribute("state");c.preventDefault(),o(f,{resolve:!1,replace:h.hasAttribute("replace"),scroll:!h.hasAttribute("noscroll"),state:m?JSON.parse(m):void 0})}function C(c){const u=a(c);if(!u)return;const[h,d]=u;r&&(d.pathname=r(d.pathname)),n.preloadRoute(d,h.getAttribute("preload")!=="false")}function E(c){clearTimeout(g);const u=a(c);if(!u)return Q=null;const[h,d]=u;Q!==h&&(r&&(d.pathname=r(d.pathname)),g=setTimeout(()=>{n.preloadRoute(d,h.getAttribute("preload")!=="false"),Q=h},20))}function I(c){if(c.defaultPrevented)return;let u=c.submitter&&c.submitter.hasAttribute("formaction")?c.submitter.getAttribute("formaction"):c.target.getAttribute("action");if(!u)return;if(!u.startsWith("https://action/")){const d=new URL(u,Sm);if(u=n.parsePath(d.pathname+d.search),!u.startsWith(t))return}if(c.target.method.toUpperCase()!=="POST")throw new Error("Only POST forms are supported for Actions");const h=fG.get(u);if(h){c.preventDefault();const d=new FormData(c.target,c.submitter);h.call({r:n,f:c.target},c.target.enctype==="multipart/form-data"?d:new URLSearchParams(d))}}or(["click","submit"]),document.addEventListener("click",s),e&&(document.addEventListener("mousemove",E,{passive:!0}),document.addEventListener("focusin",C,{passive:!0}),document.addEventListener("touchstart",C,{passive:!0})),document.addEventListener("submit",I),dA(()=>{document.removeEventListener("click",s),e&&(document.removeEventListener("mousemove",E),document.removeEventListener("focusin",C),document.removeEventListener("touchstart",C)),document.removeEventListener("submit",I)})}}function mG(e){const A=()=>{const r=window.location.pathname.replace(/^\/+/,"/")+window.location.search,n=window.history.state&&window.history.state._depth&&Object.keys(window.history.state).length===1?void 0:window.history.state;return{value:r+window.location.hash,state:n}},t=Gm();return dG({get:A,set({value:r,replace:n,scroll:i,state:o}){n?window.history.replaceState(Wx(o),"",r):window.history.pushState(o,"",r),DG(decodeURIComponent(window.location.hash.slice(1)),i),yc()},init:r=>hG(window,"popstate",Zx(r,n=>{if(n)return!t.confirm(n);{const i=A();return!t.confirm(i.value,{state:i.state})}})),create:wG(e.preload,e.explicitLinks,e.actionBase,e.transformUrl),utils:{go:r=>window.history.go(r),beforeLeave:t}})(e)}var pG=J("");function MQ(e){e=H({inactiveClass:"inactive",activeClass:"active"},e);const[,A]=eA(e,["href","state","class","activeClass","inactiveClass","end"]),t=oG(()=>e.href),r=gG(t),n=Rm(),i=S(()=>{const o=t();if(o===void 0)return[!1,!1];const g=po(o.split(/[?#]/,1)[0]).toLowerCase(),Q=decodeURI(po(n.pathname).toLowerCase());return[e.end?g===Q:Q.startsWith(g+"/")||Q===g,g===Q]});return(()=>{var o=pG();return dt(o,H(A,{get href(){return r()||e.href},get state(){return JSON.stringify(e.state)},get classList(){return{...e.class&&{[e.class]:!0},[e.inactiveClass]:!i()[0],[e.activeClass]:i()[0],...A.classList}},link:"",get"aria-current"(){return i()[1]?"page":void 0}}),!1,!1),o})()}function kG(e){const A=To(),t=Rm(),{href:r,state:n}=e,i=typeof r=="function"?r({navigate:A,location:t}):r;return A(i,{replace:!0,state:n}),null}const Es=Symbol("store-raw"),mg=Symbol("store-node"),qn=Symbol("store-has"),Tm=Symbol("store-self");function Hm(e){let A=e[An];if(!A&&(Object.defineProperty(e,An,{value:A=new Proxy(e,NG)}),!Array.isArray(e))){const t=Object.keys(e),r=Object.getOwnPropertyDescriptors(e);for(let n=0,i=t.length;ne[An][A]),t}function Ym(e){OI()&&XQ(Cs(e,mg),Tm)()}function MG(e){return Ym(e),Reflect.ownKeys(e)}const NG={get(e,A,t){if(A===Es)return e;if(A===An)return t;if(A===gs)return Ym(e),t;const r=Cs(e,mg),n=r[A];let i=n?n():e[A];if(A===mg||A===qn||A==="__proto__")return i;if(!n){const o=Object.getOwnPropertyDescriptor(e,A);OI()&&(typeof i!="function"||e.hasOwnProperty(A))&&!(o&&o.get)&&(i=XQ(r,A,i)())}return pn(i)?Hm(i):i},has(e,A){return A===Es||A===An||A===gs||A===mg||A===qn||A==="__proto__"?!0:(OI()&&XQ(Cs(e,qn),A)(),A in e)},set(){return!0},deleteProperty(){return!0},ownKeys:MG,getOwnPropertyDescriptor:yG};function Br(e,A,t,r=!1){if(!r&&e[A]===t)return;const n=e[A],i=e.length;t===void 0?(delete e[A],e[qn]&&e[qn][A]&&n!==void 0&&e[qn][A].$()):(e[A]=t,e[qn]&&e[qn][A]&&n===void 0&&e[qn][A].$());let o=Cs(e,mg),g;if((g=XQ(o,A,n))&&g.$(()=>t),Array.isArray(e)&&e.length!==i){for(let Q=e.length;Q1){r=A.shift();const o=typeof r,g=Array.isArray(e);if(Array.isArray(r)){for(let Q=0;Q1){NQ(e[r],A,[r].concat(t));return}n=e[r],t=[r].concat(t)}let i=A[0];typeof i=="function"&&(i=i(n,t),i===n)||r===void 0&&i==null||(i=vo(i),r===void 0||pn(n)&&pn(i)&&!Array.isArray(i)?zm(n,i):Br(e,r,i))}function xe(...[e,A]){const t=vo(e||{}),r=Array.isArray(t),n=Hm(t);function i(...o){st(()=>{r&&o.length===1?vG(t,o[0]):NQ(t,o)})}return[n,i]}const zI=Symbol("store-root");function Ig(e,A,t,r,n){const i=A[t];if(e===i)return;const o=Array.isArray(e);if(t!==zI&&(!pn(e)||!pn(i)||o!==Array.isArray(i)||n&&e[n]!==i[n])){Br(A,t,e);return}if(o){if(e.length&&i.length&&(!r||n&&e[0]&&e[0][n]!=null)){let B,a,s,C,E,I,c,u;for(s=0,C=Math.min(i.length,e.length);s=s&&E>=s&&(i[C]===e[E]||n&&i[C]&&e[E]&&i[C][n]&&i[C][n]===e[E][n]);C--,E--)h[E]=i[C];if(s>E||s>C){for(a=s;a<=E;a++)Br(i,a,e[a]);for(;ae.length&&Br(i,"length",e.length);return}for(c=new Array(E+1),a=E;a>=s;a--)I=e[a],u=n&&I?I[n]:I,B=d.get(u),c[a]=B===void 0?-1:B,d.set(u,a);for(B=s;B<=C;B++)I=i[B],u=n&&I?I[n]:I,a=d.get(u),a!==void 0&&a!==-1&&(h[a]=i[B],a=c[a],d.set(u,a));for(a=s;ae.length&&Br(i,"length",e.length);return}const g=Object.keys(e);for(let B=0,a=g.length;B{if(!pn(i)||!pn(n))return n;const o=Ig(n,{[zI]:i},zI,t,r);return o===void 0?i:o}}const Is=new WeakMap,Pm={get(e,A){if(A===Es)return e;const t=e[A];let r;return pn(t)?Is.get(t)||(Is.set(t,r=new Proxy(t,Pm)),r):t},set(e,A,t){return Br(e,A,vo(t)),!0},deleteProperty(e,A){return Br(e,A,void 0,!0),!0}};function Dt(e){return A=>{if(pn(A)){let t;(t=Is.get(A))||Is.set(A,t=new Proxy(A,Pm)),e(t)}return A}}const _m=ye(),bG=["title","meta"],lh=[],ch=["name","http-equiv","content","charset","media"].concat(["property"]),uh=(e,A)=>{const t=Object.fromEntries(Object.entries(e.props).filter(([r])=>A.includes(r)).sort());return(Object.hasOwn(t,"name")||Object.hasOwn(t,"property"))&&(t.name=t.name||t.property,delete t.property),e.tag+JSON.stringify(t)};function FG(){{const t=document.head.querySelectorAll("[data-sm]");Array.prototype.forEach.call(t,r=>r.parentNode.removeChild(r))}const e=new Map;function A(t){if(t.ref)return t.ref;let r=document.querySelector(`[data-sm="${t.id}"]`);return r?(r.tagName.toLowerCase()!==t.tag&&(r.parentNode&&r.parentNode.removeChild(r),r=document.createElement(t.tag)),r.removeAttribute("data-sm")):r=document.createElement(t.tag),r}return{addTag(t){if(bG.indexOf(t.tag)!==-1){const i=t.tag==="title"?lh:ch,o=uh(t,i);e.has(o)||e.set(o,[]);let g=e.get(o),Q=g.length;g=[...g,t],e.set(o,g);let B=A(t);t.ref=B,dt(B,t.props);let a=null;for(var r=Q-1;r>=0;r--)if(g[r]!=null){a=g[r];break}return B.parentNode!=document.head&&document.head.appendChild(B),a&&a.ref&&a.ref.parentNode&&document.head.removeChild(a.ref),Q}let n=A(t);return t.ref=n,dt(n,t.props),n.parentNode!=document.head&&document.head.appendChild(n),-1},removeTag(t,r){const n=t.tag==="title"?lh:ch,i=uh(t,n);if(t.ref){const o=e.get(i);if(o){if(t.ref.parentNode){t.ref.parentNode.removeChild(t.ref);for(let g=r-1;g>=0;g--)o[g]!=null&&document.head.appendChild(o[g].ref)}o[r]=null,e.set(i,o)}else t.ref.parentNode&&t.ref.parentNode.removeChild(t.ref)}}}}const xG=e=>{const A=FG();return l(_m.Provider,{value:A,get children(){return e.children}})},jm=(e,A,t)=>(GG({tag:e,props:A,setting:t,id:je(),get name(){return A.name||A.property}}),null);function GG(e){const A=pe(_m);if(!A)throw new Error(" should be in the tree");_A(()=>{const t=A.addTag(e);dA(()=>A.removeTag(e,t))})}const SG=e=>jm("style",e,{close:!0}),dh=e=>jm("link",e),hh="/assets/inter-FIwubZjA.woff2",Dh="/assets/BlexMonoNerdFontMono-Regular-DSJ7IWr2.woff2",JG="/assets/BlexMonoNerdFontMono-Medium-BvtJB5kd.woff2",UG="/assets/BlexMonoNerdFontMono-Bold-B8jzonSj.woff2",KG="/assets/CaskaydiaCoveNerdFontMono-Regular-C_H0OSLN.woff2",LG="/assets/CaskaydiaCoveNerdFontMono-Bold-CxABrWmj.woff2",RG="/assets/FiraCodeNerdFontMono-Regular-io3c92n9.woff2",OG="/assets/FiraCodeNerdFontMono-Bold-BjAeM3gJ.woff2",qG="/assets/HackNerdFontMono-Regular-IcpSchWC.woff2",TG="/assets/HackNerdFontMono-Bold-BNG4kp7w.woff2",HG="/assets/InconsolataNerdFontMono-Regular-CRHGEvh2.woff2",YG="/assets/InconsolataNerdFontMono-Bold-oTRjQesI.woff2",zG="/assets/IntoneMonoNerdFontMono-Regular-BwjBdmsJ.woff2",PG="/assets/IntoneMonoNerdFontMono-Bold-BL6LrHzx.woff2",_G="/assets/JetBrainsMonoNerdFontMono-Regular-QVq88ZfU.woff2",jG="/assets/JetBrainsMonoNerdFontMono-Bold-CU80ifuM.woff2",VG="/assets/MesloLGSNerdFontMono-Regular-j-nTZDWZ.woff2",WG="/assets/MesloLGSNerdFontMono-Bold-CrpVO3ec.woff2",ZG="/assets/RobotoMonoNerdFontMono-Regular-DvxS3QZC.woff2",XG="/assets/RobotoMonoNerdFontMono-Bold-DNxuDepp.woff2",$G="/assets/SauceCodeProNerdFontMono-Regular-Ba96Bdne.woff2",A3="/assets/SauceCodeProNerdFontMono-Bold-DloEeUVQ.woff2",e3="/assets/UbuntuMonoNerdFontMono-Regular-tdnXLyap.woff2",t3="/assets/UbuntuMonoNerdFontMono-Bold-wLXUURqB.woff2",r3=[{family:"JetBrains Mono Nerd Font",regular:_G,bold:jG},{family:"Fira Code Nerd Font",regular:RG,bold:OG},{family:"Cascadia Code Nerd Font",regular:KG,bold:LG},{family:"Hack Nerd Font",regular:qG,bold:TG},{family:"Source Code Pro Nerd Font",regular:$G,bold:A3},{family:"Inconsolata Nerd Font",regular:HG,bold:YG},{family:"Roboto Mono Nerd Font",regular:ZG,bold:XG},{family:"Ubuntu Mono Nerd Font",regular:e3,bold:t3},{family:"Intel One Mono Nerd Font",regular:zG,bold:PG},{family:"Meslo LGS Nerd Font",regular:VG,bold:WG}],n3=r3.map(e=>` @font-face { font-family: "${e.family}"; src: url("${e.regular}") format("woff2"); font-display: swap; font-style: normal; font-weight: 400; } @font-face { font-family: "${e.family}"; src: url("${e.bold}") format("woff2"); font-display: swap; font-style: normal; font-weight: 700; }`).join(""),i3=()=>[l(SG,{children:` @font-face { font-family: "Inter"; src: url("${hh}") format("woff2-variations"); font-display: swap; font-style: normal; font-weight: 100 900; } @font-face { font-family: "Inter Fallback"; src: local("Arial"); size-adjust: 100%; ascent-override: 97%; descent-override: 25%; line-gap-override: 1%; } @font-face { font-family: "IBM Plex Mono"; src: url("${Dh}") format("woff2"); font-display: swap; font-style: normal; font-weight: 400; } @font-face { font-family: "IBM Plex Mono"; src: url("${JG}") format("woff2"); font-display: swap; font-style: normal; font-weight: 500; } @font-face { font-family: "IBM Plex Mono"; src: url("${UG}") format("woff2"); font-display: swap; font-style: normal; font-weight: 700; } @font-face { font-family: "IBM Plex Mono Fallback"; src: local("Courier New"); size-adjust: 100%; ascent-override: 97%; descent-override: 25%; line-gap-override: 1%; } ${n3} `}),l(dh,{rel:"preload",href:hh,as:"font",type:"font/woff2",crossorigin:"anonymous"}),l(dh,{rel:"preload",href:Dh,as:"font",type:"font/woff2",crossorigin:"anonymous"})];function Nc(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var Ho=Nc();function Vm(e){Ho=e}var YQ={exec:()=>null};function Re(e,A=""){let t=typeof e=="string"?e:e.source,r={replace:(n,i)=>{let o=typeof i=="string"?i:i.source;return o=o.replace(er.caret,"$1"),t=t.replace(n,o),r},getRegex:()=>new RegExp(t,A)};return r}var o3=(()=>{try{return!!new RegExp("(?<=1)(?/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] +\S/,listReplaceTask:/^\[[ xX]\] +/,listTaskCheckbox:/\[[ xX]\]/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>new RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}#`),htmlBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}<(?:[a-z].*>|!--)`,"i")},g3=/^(?:[ \t]*(?:\n|$))+/,Q3=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,B3=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,kB=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,a3=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,vc=/(?:[*+-]|\d{1,9}[.)])/,Wm=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,Zm=Re(Wm).replace(/bull/g,vc).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),s3=Re(Wm).replace(/bull/g,vc).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),bc=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,E3=/^[^\n]+/,Fc=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,C3=Re(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",Fc).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),I3=Re(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,vc).getRegex(),oE="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",xc=/|$))/,l3=Re("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",xc).replace("tag",oE).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),Xm=Re(bc).replace("hr",kB).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",oE).getRegex(),c3=Re(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",Xm).getRegex(),Gc={blockquote:c3,code:Q3,def:C3,fences:B3,heading:a3,hr:kB,html:l3,lheading:Zm,list:I3,newline:g3,paragraph:Xm,table:YQ,text:E3},fh=Re("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",kB).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",oE).getRegex(),u3={...Gc,lheading:s3,table:fh,paragraph:Re(bc).replace("hr",kB).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",fh).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",oE).getRegex()},d3={...Gc,html:Re(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",xc).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:YQ,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:Re(bc).replace("hr",kB).replace("heading",` *#{1,6} *[^ ]`).replace("lheading",Zm).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},h3=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,D3=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,$m=/^( {2,}|\\)\n(?!\s*$)/,f3=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\`+)[^`]+\k(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",o3?"(?`+)[^`]+\k(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),tp=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,y3=Re(tp,"u").replace(/punct/g,gE).getRegex(),M3=Re(tp,"u").replace(/punct/g,ep).getRegex(),rp="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",N3=Re(rp,"gu").replace(/notPunctSpace/g,Ap).replace(/punctSpace/g,Sc).replace(/punct/g,gE).getRegex(),v3=Re(rp,"gu").replace(/notPunctSpace/g,p3).replace(/punctSpace/g,m3).replace(/punct/g,ep).getRegex(),b3=Re("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,Ap).replace(/punctSpace/g,Sc).replace(/punct/g,gE).getRegex(),F3=Re(/\\(punct)/,"gu").replace(/punct/g,gE).getRegex(),x3=Re(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),G3=Re(xc).replace("(?:-->|$)","-->").getRegex(),S3=Re("^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^").replace("comment",G3).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),ls=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/,J3=Re(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",ls).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),np=Re(/^!?\[(label)\]\[(ref)\]/).replace("label",ls).replace("ref",Fc).getRegex(),ip=Re(/^!?\[(ref)\](?:\[\])?/).replace("ref",Fc).getRegex(),U3=Re("reflink|nolink(?!\\()","g").replace("reflink",np).replace("nolink",ip).getRegex(),wh=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,Jc={_backpedal:YQ,anyPunctuation:F3,autolink:x3,blockSkip:k3,br:$m,code:D3,del:YQ,emStrongLDelim:y3,emStrongRDelimAst:N3,emStrongRDelimUnd:b3,escape:h3,link:J3,nolink:ip,punctuation:w3,reflink:np,reflinkSearch:U3,tag:S3,text:f3,url:YQ},K3={...Jc,link:Re(/^!?\[(label)\]\((.*?)\)/).replace("label",ls).getRegex(),reflink:Re(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",ls).getRegex()},PI={...Jc,emStrongRDelimAst:v3,emStrongLDelim:M3,url:Re(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol",wh).replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:Re(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\":">",'"':""","'":"'"},mh=e=>R3[e];function On(e,A){if(A){if(er.escapeTest.test(e))return e.replace(er.escapeReplace,mh)}else if(er.escapeTestNoEncode.test(e))return e.replace(er.escapeReplaceNoEncode,mh);return e}function ph(e){try{e=encodeURI(e).replace(er.percentDecode,"%")}catch{return null}return e}function kh(e,A){let t=e.replace(er.findPipe,(i,o,g)=>{let Q=!1,B=o;for(;--B>=0&&g[B]==="\\";)Q=!Q;return Q?"|":" |"}),r=t.split(er.splitPipe),n=0;if(r[0].trim()||r.shift(),r.length>0&&!r.at(-1)?.trim()&&r.pop(),A)if(r.length>A)r.splice(A);else for(;r.length0?-2:-1}function yh(e,A,t,r,n){let i=A.href,o=A.title||null,g=e[1].replace(n.other.outputLinkReplace,"$1");r.state.inLink=!0;let Q={type:e[0].charAt(0)==="!"?"image":"link",raw:t,href:i,title:o,text:g,tokens:r.inlineTokens(g)};return r.state.inLink=!1,Q}function q3(e,A,t){let r=e.match(t.other.indentCodeCompensation);if(r===null)return A;let n=r[1];return A.split(` `).map(i=>{let o=i.match(t.other.beginningSpace);if(o===null)return i;let[g]=o;return g.length>=n.length?i.slice(n.length):i}).join(` `)}var cs=class{options;rules;lexer;constructor(A){this.options=A||Ho}space(A){let t=this.rules.block.newline.exec(A);if(t&&t[0].length>0)return{type:"space",raw:t[0]}}code(A){let t=this.rules.block.code.exec(A);if(t){let r=t[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:t[0],codeBlockStyle:"indented",text:this.options.pedantic?r:uQ(r,` `)}}}fences(A){let t=this.rules.block.fences.exec(A);if(t){let r=t[0],n=q3(r,t[3]||"",this.rules);return{type:"code",raw:r,lang:t[2]?t[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):t[2],text:n}}}heading(A){let t=this.rules.block.heading.exec(A);if(t){let r=t[2].trim();if(this.rules.other.endingHash.test(r)){let n=uQ(r,"#");(this.options.pedantic||!n||this.rules.other.endingSpaceChar.test(n))&&(r=n.trim())}return{type:"heading",raw:t[0],depth:t[1].length,text:r,tokens:this.lexer.inline(r)}}}hr(A){let t=this.rules.block.hr.exec(A);if(t)return{type:"hr",raw:uQ(t[0],` `)}}blockquote(A){let t=this.rules.block.blockquote.exec(A);if(t){let r=uQ(t[0],` `).split(` `),n="",i="",o=[];for(;r.length>0;){let g=!1,Q=[],B;for(B=0;B1,i={type:"list",raw:"",ordered:n,start:n?+r.slice(0,-1):"",loose:!1,items:[]};r=n?`\\d{1,9}\\${r.slice(-1)}`:`\\${r}`,this.options.pedantic&&(r=n?r:"[*+-]");let o=this.rules.other.listItemRegex(r),g=!1;for(;A;){let B=!1,a="",s="";if(!(t=o.exec(A))||this.rules.block.hr.test(A))break;a=t[0],A=A.substring(a.length);let C=t[2].split(` `,1)[0].replace(this.rules.other.listReplaceTabs,u=>" ".repeat(3*u.length)),E=A.split(` `,1)[0],I=!C.trim(),c=0;if(this.options.pedantic?(c=2,s=C.trimStart()):I?c=t[1].length+1:(c=t[2].search(this.rules.other.nonSpaceChar),c=c>4?1:c,s=C.slice(c),c+=t[1].length),I&&this.rules.other.blankLine.test(E)&&(a+=E+` `,A=A.substring(E.length+1),B=!0),!B){let u=this.rules.other.nextBulletRegex(c),h=this.rules.other.hrRegex(c),d=this.rules.other.fencesBeginRegex(c),f=this.rules.other.headingBeginRegex(c),m=this.rules.other.htmlBeginRegex(c);for(;A;){let k=A.split(` `,1)[0],N;if(E=k,this.options.pedantic?(E=E.replace(this.rules.other.listReplaceNesting," "),N=E):N=E.replace(this.rules.other.tabCharGlobal," "),d.test(E)||f.test(E)||m.test(E)||u.test(E)||h.test(E))break;if(N.search(this.rules.other.nonSpaceChar)>=c||!E.trim())s+=` `+N.slice(c);else{if(I||C.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||d.test(C)||f.test(C)||h.test(C))break;s+=` `+E}!I&&!E.trim()&&(I=!0),a+=k+` `,A=A.substring(k.length+1),C=N.slice(c)}}i.loose||(g?i.loose=!0:this.rules.other.doubleBlankLine.test(a)&&(g=!0)),i.items.push({type:"list_item",raw:a,task:!!this.options.gfm&&this.rules.other.listIsTask.test(s),loose:!1,text:s,tokens:[]}),i.raw+=a}let Q=i.items.at(-1);if(Q)Q.raw=Q.raw.trimEnd(),Q.text=Q.text.trimEnd();else return;i.raw=i.raw.trimEnd();for(let B of i.items){if(this.lexer.state.top=!1,B.tokens=this.lexer.blockTokens(B.text,[]),B.task){if(B.text=B.text.replace(this.rules.other.listReplaceTask,""),B.tokens[0]?.type==="text"||B.tokens[0]?.type==="paragraph"){B.tokens[0].raw=B.tokens[0].raw.replace(this.rules.other.listReplaceTask,""),B.tokens[0].text=B.tokens[0].text.replace(this.rules.other.listReplaceTask,"");for(let s=this.lexer.inlineQueue.length-1;s>=0;s--)if(this.rules.other.listIsTask.test(this.lexer.inlineQueue[s].src)){this.lexer.inlineQueue[s].src=this.lexer.inlineQueue[s].src.replace(this.rules.other.listReplaceTask,"");break}}let a=this.rules.other.listTaskCheckbox.exec(B.raw);if(a){let s={type:"checkbox",raw:a[0]+" ",checked:a[0]!=="[ ]"};B.checked=s.checked,i.loose?B.tokens[0]&&["paragraph","text"].includes(B.tokens[0].type)&&"tokens"in B.tokens[0]&&B.tokens[0].tokens?(B.tokens[0].raw=s.raw+B.tokens[0].raw,B.tokens[0].text=s.raw+B.tokens[0].text,B.tokens[0].tokens.unshift(s)):B.tokens.unshift({type:"paragraph",raw:s.raw,text:s.raw,tokens:[s]}):B.tokens.unshift(s)}}if(!i.loose){let a=B.tokens.filter(C=>C.type==="space"),s=a.length>0&&a.some(C=>this.rules.other.anyLine.test(C.raw));i.loose=s}}if(i.loose)for(let B of i.items){B.loose=!0;for(let a of B.tokens)a.type==="text"&&(a.type="paragraph")}return i}}html(A){let t=this.rules.block.html.exec(A);if(t)return{type:"html",block:!0,raw:t[0],pre:t[1]==="pre"||t[1]==="script"||t[1]==="style",text:t[0]}}def(A){let t=this.rules.block.def.exec(A);if(t){let r=t[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),n=t[2]?t[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",i=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):t[3];return{type:"def",tag:r,raw:t[0],href:n,title:i}}}table(A){let t=this.rules.block.table.exec(A);if(!t||!this.rules.other.tableDelimiter.test(t[2]))return;let r=kh(t[1]),n=t[2].replace(this.rules.other.tableAlignChars,"").split("|"),i=t[3]?.trim()?t[3].replace(this.rules.other.tableRowBlankLine,"").split(` `):[],o={type:"table",raw:t[0],header:[],align:[],rows:[]};if(r.length===n.length){for(let g of n)this.rules.other.tableAlignRight.test(g)?o.align.push("right"):this.rules.other.tableAlignCenter.test(g)?o.align.push("center"):this.rules.other.tableAlignLeft.test(g)?o.align.push("left"):o.align.push(null);for(let g=0;g({text:Q,tokens:this.lexer.inline(Q),header:!1,align:o.align[B]})));return o}}lheading(A){let t=this.rules.block.lheading.exec(A);if(t)return{type:"heading",raw:t[0],depth:t[2].charAt(0)==="="?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(A){let t=this.rules.block.paragraph.exec(A);if(t){let r=t[1].charAt(t[1].length-1)===` `?t[1].slice(0,-1):t[1];return{type:"paragraph",raw:t[0],text:r,tokens:this.lexer.inline(r)}}}text(A){let t=this.rules.block.text.exec(A);if(t)return{type:"text",raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(A){let t=this.rules.inline.escape.exec(A);if(t)return{type:"escape",raw:t[0],text:t[1]}}tag(A){let t=this.rules.inline.tag.exec(A);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(A){let t=this.rules.inline.link.exec(A);if(t){let r=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(r)){if(!this.rules.other.endAngleBracket.test(r))return;let o=uQ(r.slice(0,-1),"\\");if((r.length-o.length)%2===0)return}else{let o=O3(t[2],"()");if(o===-2)return;if(o>-1){let g=(t[0].indexOf("!")===0?5:4)+t[1].length+o;t[2]=t[2].substring(0,o),t[0]=t[0].substring(0,g).trim(),t[3]=""}}let n=t[2],i="";if(this.options.pedantic){let o=this.rules.other.pedanticHrefTitle.exec(n);o&&(n=o[1],i=o[3])}else i=t[3]?t[3].slice(1,-1):"";return n=n.trim(),this.rules.other.startAngleBracket.test(n)&&(this.options.pedantic&&!this.rules.other.endAngleBracket.test(r)?n=n.slice(1):n=n.slice(1,-1)),yh(t,{href:n&&n.replace(this.rules.inline.anyPunctuation,"$1"),title:i&&i.replace(this.rules.inline.anyPunctuation,"$1")},t[0],this.lexer,this.rules)}}reflink(A,t){let r;if((r=this.rules.inline.reflink.exec(A))||(r=this.rules.inline.nolink.exec(A))){let n=(r[2]||r[1]).replace(this.rules.other.multipleSpaceGlobal," "),i=t[n.toLowerCase()];if(!i){let o=r[0].charAt(0);return{type:"text",raw:o,text:o}}return yh(r,i,r[0],this.lexer,this.rules)}}emStrong(A,t,r=""){let n=this.rules.inline.emStrongLDelim.exec(A);if(!(!n||n[3]&&r.match(this.rules.other.unicodeAlphaNumeric))&&(!(n[1]||n[2])||!r||this.rules.inline.punctuation.exec(r))){let i=[...n[0]].length-1,o,g,Q=i,B=0,a=n[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(a.lastIndex=0,t=t.slice(-1*A.length+i);(n=a.exec(t))!=null;){if(o=n[1]||n[2]||n[3]||n[4]||n[5]||n[6],!o)continue;if(g=[...o].length,n[3]||n[4]){Q+=g;continue}else if((n[5]||n[6])&&i%3&&!((i+g)%3)){B+=g;continue}if(Q-=g,Q>0)continue;g=Math.min(g,g+Q+B);let s=[...n[0]][0].length,C=A.slice(0,i+n.index+s+g);if(Math.min(i,g)%2){let I=C.slice(1,-1);return{type:"em",raw:C,text:I,tokens:this.lexer.inlineTokens(I)}}let E=C.slice(2,-2);return{type:"strong",raw:C,text:E,tokens:this.lexer.inlineTokens(E)}}}}codespan(A){let t=this.rules.inline.code.exec(A);if(t){let r=t[2].replace(this.rules.other.newLineCharGlobal," "),n=this.rules.other.nonSpaceChar.test(r),i=this.rules.other.startingSpaceChar.test(r)&&this.rules.other.endingSpaceChar.test(r);return n&&i&&(r=r.substring(1,r.length-1)),{type:"codespan",raw:t[0],text:r}}}br(A){let t=this.rules.inline.br.exec(A);if(t)return{type:"br",raw:t[0]}}del(A){let t=this.rules.inline.del.exec(A);if(t)return{type:"del",raw:t[0],text:t[2],tokens:this.lexer.inlineTokens(t[2])}}autolink(A){let t=this.rules.inline.autolink.exec(A);if(t){let r,n;return t[2]==="@"?(r=t[1],n="mailto:"+r):(r=t[1],n=r),{type:"link",raw:t[0],text:r,href:n,tokens:[{type:"text",raw:r,text:r}]}}}url(A){let t;if(t=this.rules.inline.url.exec(A)){let r,n;if(t[2]==="@")r=t[0],n="mailto:"+r;else{let i;do i=t[0],t[0]=this.rules.inline._backpedal.exec(t[0])?.[0]??"";while(i!==t[0]);r=t[0],t[1]==="www."?n="http://"+t[0]:n=t[0]}return{type:"link",raw:t[0],text:r,href:n,tokens:[{type:"text",raw:r,text:r}]}}}inlineText(A){let t=this.rules.inline.text.exec(A);if(t){let r=this.lexer.state.inRawBlock;return{type:"text",raw:t[0],text:t[0],escaped:r}}}},Pr=class _I{tokens;options;state;inlineQueue;tokenizer;constructor(A){this.tokens=[],this.tokens.links=Object.create(null),this.options=A||Ho,this.options.tokenizer=this.options.tokenizer||new cs,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let t={other:er,block:Ia.normal,inline:cQ.normal};this.options.pedantic?(t.block=Ia.pedantic,t.inline=cQ.pedantic):this.options.gfm&&(t.block=Ia.gfm,this.options.breaks?t.inline=cQ.breaks:t.inline=cQ.gfm),this.tokenizer.rules=t}static get rules(){return{block:Ia,inline:cQ}}static lex(A,t){return new _I(t).lex(A)}static lexInline(A,t){return new _I(t).inlineTokens(A)}lex(A){A=A.replace(er.carriageReturn,` `),this.blockTokens(A,this.tokens);for(let t=0;t(n=o.call({lexer:this},A,t))?(A=A.substring(n.raw.length),t.push(n),!0):!1))continue;if(n=this.tokenizer.space(A)){A=A.substring(n.raw.length);let o=t.at(-1);n.raw.length===1&&o!==void 0?o.raw+=` `:t.push(n);continue}if(n=this.tokenizer.code(A)){A=A.substring(n.raw.length);let o=t.at(-1);o?.type==="paragraph"||o?.type==="text"?(o.raw+=(o.raw.endsWith(` `)?"":` `)+n.raw,o.text+=` `+n.text,this.inlineQueue.at(-1).src=o.text):t.push(n);continue}if(n=this.tokenizer.fences(A)){A=A.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.heading(A)){A=A.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.hr(A)){A=A.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.blockquote(A)){A=A.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.list(A)){A=A.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.html(A)){A=A.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.def(A)){A=A.substring(n.raw.length);let o=t.at(-1);o?.type==="paragraph"||o?.type==="text"?(o.raw+=(o.raw.endsWith(` `)?"":` `)+n.raw,o.text+=` `+n.raw,this.inlineQueue.at(-1).src=o.text):this.tokens.links[n.tag]||(this.tokens.links[n.tag]={href:n.href,title:n.title},t.push(n));continue}if(n=this.tokenizer.table(A)){A=A.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.lheading(A)){A=A.substring(n.raw.length),t.push(n);continue}let i=A;if(this.options.extensions?.startBlock){let o=1/0,g=A.slice(1),Q;this.options.extensions.startBlock.forEach(B=>{Q=B.call({lexer:this},g),typeof Q=="number"&&Q>=0&&(o=Math.min(o,Q))}),o<1/0&&o>=0&&(i=A.substring(0,o+1))}if(this.state.top&&(n=this.tokenizer.paragraph(i))){let o=t.at(-1);r&&o?.type==="paragraph"?(o.raw+=(o.raw.endsWith(` `)?"":` `)+n.raw,o.text+=` `+n.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=o.text):t.push(n),r=i.length!==A.length,A=A.substring(n.raw.length);continue}if(n=this.tokenizer.text(A)){A=A.substring(n.raw.length);let o=t.at(-1);o?.type==="text"?(o.raw+=(o.raw.endsWith(` `)?"":` `)+n.raw,o.text+=` `+n.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=o.text):t.push(n);continue}if(A){let o="Infinite loop on byte: "+A.charCodeAt(0);if(this.options.silent){console.error(o);break}else throw new Error(o)}}return this.state.top=!0,t}inline(A,t=[]){return this.inlineQueue.push({src:A,tokens:t}),t}inlineTokens(A,t=[]){let r=A,n=null;if(this.tokens.links){let Q=Object.keys(this.tokens.links);if(Q.length>0)for(;(n=this.tokenizer.rules.inline.reflinkSearch.exec(r))!=null;)Q.includes(n[0].slice(n[0].lastIndexOf("[")+1,-1))&&(r=r.slice(0,n.index)+"["+"a".repeat(n[0].length-2)+"]"+r.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(n=this.tokenizer.rules.inline.anyPunctuation.exec(r))!=null;)r=r.slice(0,n.index)+"++"+r.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);let i;for(;(n=this.tokenizer.rules.inline.blockSkip.exec(r))!=null;)i=n[2]?n[2].length:0,r=r.slice(0,n.index+i)+"["+"a".repeat(n[0].length-i-2)+"]"+r.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);r=this.options.hooks?.emStrongMask?.call({lexer:this},r)??r;let o=!1,g="";for(;A;){o||(g=""),o=!1;let Q;if(this.options.extensions?.inline?.some(a=>(Q=a.call({lexer:this},A,t))?(A=A.substring(Q.raw.length),t.push(Q),!0):!1))continue;if(Q=this.tokenizer.escape(A)){A=A.substring(Q.raw.length),t.push(Q);continue}if(Q=this.tokenizer.tag(A)){A=A.substring(Q.raw.length),t.push(Q);continue}if(Q=this.tokenizer.link(A)){A=A.substring(Q.raw.length),t.push(Q);continue}if(Q=this.tokenizer.reflink(A,this.tokens.links)){A=A.substring(Q.raw.length);let a=t.at(-1);Q.type==="text"&&a?.type==="text"?(a.raw+=Q.raw,a.text+=Q.text):t.push(Q);continue}if(Q=this.tokenizer.emStrong(A,r,g)){A=A.substring(Q.raw.length),t.push(Q);continue}if(Q=this.tokenizer.codespan(A)){A=A.substring(Q.raw.length),t.push(Q);continue}if(Q=this.tokenizer.br(A)){A=A.substring(Q.raw.length),t.push(Q);continue}if(Q=this.tokenizer.del(A)){A=A.substring(Q.raw.length),t.push(Q);continue}if(Q=this.tokenizer.autolink(A)){A=A.substring(Q.raw.length),t.push(Q);continue}if(!this.state.inLink&&(Q=this.tokenizer.url(A))){A=A.substring(Q.raw.length),t.push(Q);continue}let B=A;if(this.options.extensions?.startInline){let a=1/0,s=A.slice(1),C;this.options.extensions.startInline.forEach(E=>{C=E.call({lexer:this},s),typeof C=="number"&&C>=0&&(a=Math.min(a,C))}),a<1/0&&a>=0&&(B=A.substring(0,a+1))}if(Q=this.tokenizer.inlineText(B)){A=A.substring(Q.raw.length),Q.raw.slice(-1)!=="_"&&(g=Q.raw.slice(-1)),o=!0;let a=t.at(-1);a?.type==="text"?(a.raw+=Q.raw,a.text+=Q.text):t.push(Q);continue}if(A){let a="Infinite loop on byte: "+A.charCodeAt(0);if(this.options.silent){console.error(a);break}else throw new Error(a)}}return t}},us=class{options;parser;constructor(A){this.options=A||Ho}space(A){return""}code({text:A,lang:t,escaped:r}){let n=(t||"").match(er.notSpaceStart)?.[0],i=A.replace(er.endingNewline,"")+` `;return n?'
'+(r?i:On(i,!0))+`
`:"
"+(r?i:On(i,!0))+`
`}blockquote({tokens:A}){return`
${this.parser.parse(A)}
`}html({text:A}){return A}def(A){return""}heading({tokens:A,depth:t}){return`${this.parser.parseInline(A)} `}hr(A){return`
`}list(A){let t=A.ordered,r=A.start,n="";for(let g=0;g `+n+" `}listitem(A){return`
  • ${this.parser.parse(A.tokens)}
  • `}checkbox({checked:A}){return" '}paragraph({tokens:A}){return`

    ${this.parser.parseInline(A)}

    `}table(A){let t="",r="";for(let i=0;i${n}`),` `+t+` `+n+`
    `}tablerow({text:A}){return` ${A} `}tablecell(A){let t=this.parser.parseInline(A.tokens),r=A.header?"th":"td";return(A.align?`<${r} align="${A.align}">`:`<${r}>`)+t+` `}strong({tokens:A}){return`${this.parser.parseInline(A)}`}em({tokens:A}){return`${this.parser.parseInline(A)}`}codespan({text:A}){return`${On(A,!0)}`}br(A){return"
    "}del({tokens:A}){return`${this.parser.parseInline(A)}`}link({href:A,title:t,tokens:r}){let n=this.parser.parseInline(r),i=ph(A);if(i===null)return n;A=i;let o='
    ",o}image({href:A,title:t,text:r,tokens:n}){n&&(r=this.parser.parseInline(n,this.parser.textRenderer));let i=ph(A);if(i===null)return On(r);A=i;let o=`${r}{let g=i[o].flat(1/0);r=r.concat(this.walkTokens(g,t))}):i.tokens&&(r=r.concat(this.walkTokens(i.tokens,t)))}}return r}use(...A){let t=this.defaults.extensions||{renderers:{},childTokens:{}};return A.forEach(r=>{let n={...r};if(n.async=this.defaults.async||n.async||!1,r.extensions&&(r.extensions.forEach(i=>{if(!i.name)throw new Error("extension name required");if("renderer"in i){let o=t.renderers[i.name];o?t.renderers[i.name]=function(...g){let Q=i.renderer.apply(this,g);return Q===!1&&(Q=o.apply(this,g)),Q}:t.renderers[i.name]=i.renderer}if("tokenizer"in i){if(!i.level||i.level!=="block"&&i.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let o=t[i.level];o?o.unshift(i.tokenizer):t[i.level]=[i.tokenizer],i.start&&(i.level==="block"?t.startBlock?t.startBlock.push(i.start):t.startBlock=[i.start]:i.level==="inline"&&(t.startInline?t.startInline.push(i.start):t.startInline=[i.start]))}"childTokens"in i&&i.childTokens&&(t.childTokens[i.name]=i.childTokens)}),n.extensions=t),r.renderer){let i=this.defaults.renderer||new us(this.defaults);for(let o in r.renderer){if(!(o in i))throw new Error(`renderer '${o}' does not exist`);if(["options","parser"].includes(o))continue;let g=o,Q=r.renderer[g],B=i[g];i[g]=(...a)=>{let s=Q.apply(i,a);return s===!1&&(s=B.apply(i,a)),s||""}}n.renderer=i}if(r.tokenizer){let i=this.defaults.tokenizer||new cs(this.defaults);for(let o in r.tokenizer){if(!(o in i))throw new Error(`tokenizer '${o}' does not exist`);if(["options","rules","lexer"].includes(o))continue;let g=o,Q=r.tokenizer[g],B=i[g];i[g]=(...a)=>{let s=Q.apply(i,a);return s===!1&&(s=B.apply(i,a)),s}}n.tokenizer=i}if(r.hooks){let i=this.defaults.hooks||new vQ;for(let o in r.hooks){if(!(o in i))throw new Error(`hook '${o}' does not exist`);if(["options","block"].includes(o))continue;let g=o,Q=r.hooks[g],B=i[g];vQ.passThroughHooks.has(o)?i[g]=a=>{if(this.defaults.async&&vQ.passThroughHooksRespectAsync.has(o))return(async()=>{let C=await Q.call(i,a);return B.call(i,C)})();let s=Q.call(i,a);return B.call(i,s)}:i[g]=(...a)=>{if(this.defaults.async)return(async()=>{let C=await Q.apply(i,a);return C===!1&&(C=await B.apply(i,a)),C})();let s=Q.apply(i,a);return s===!1&&(s=B.apply(i,a)),s}}n.hooks=i}if(r.walkTokens){let i=this.defaults.walkTokens,o=r.walkTokens;n.walkTokens=function(g){let Q=[];return Q.push(o.call(this,g)),i&&(Q=Q.concat(i.call(this,g))),Q}}this.defaults={...this.defaults,...n}}),this}setOptions(A){return this.defaults={...this.defaults,...A},this}lexer(A,t){return Pr.lex(A,t??this.defaults)}parser(A,t){return _r.parse(A,t??this.defaults)}parseMarkdown(A){return(t,r)=>{let n={...r},i={...this.defaults,...n},o=this.onError(!!i.silent,!!i.async);if(this.defaults.async===!0&&n.async===!1)return o(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof t>"u"||t===null)return o(new Error("marked(): input parameter is undefined or null"));if(typeof t!="string")return o(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected"));if(i.hooks&&(i.hooks.options=i,i.hooks.block=A),i.async)return(async()=>{let g=i.hooks?await i.hooks.preprocess(t):t,Q=await(i.hooks?await i.hooks.provideLexer():A?Pr.lex:Pr.lexInline)(g,i),B=i.hooks?await i.hooks.processAllTokens(Q):Q;i.walkTokens&&await Promise.all(this.walkTokens(B,i.walkTokens));let a=await(i.hooks?await i.hooks.provideParser():A?_r.parse:_r.parseInline)(B,i);return i.hooks?await i.hooks.postprocess(a):a})().catch(o);try{i.hooks&&(t=i.hooks.preprocess(t));let g=(i.hooks?i.hooks.provideLexer():A?Pr.lex:Pr.lexInline)(t,i);i.hooks&&(g=i.hooks.processAllTokens(g)),i.walkTokens&&this.walkTokens(g,i.walkTokens);let Q=(i.hooks?i.hooks.provideParser():A?_r.parse:_r.parseInline)(g,i);return i.hooks&&(Q=i.hooks.postprocess(Q)),Q}catch(g){return o(g)}}}onError(A,t){return r=>{if(r.message+=` Please report this to https://github.com/markedjs/marked.`,A){let n="

    An error occurred:

    "+On(r.message+"",!0)+"
    ";return t?Promise.resolve(n):n}if(t)return Promise.reject(r);throw r}}},bo=new T3;function Ye(e,A){return bo.parse(e,A)}Ye.options=Ye.setOptions=function(e){return bo.setOptions(e),Ye.defaults=bo.defaults,Vm(Ye.defaults),Ye};Ye.getDefaults=Nc;Ye.defaults=Ho;Ye.use=function(...e){return bo.use(...e),Ye.defaults=bo.defaults,Vm(Ye.defaults),Ye};Ye.walkTokens=function(e,A){return bo.walkTokens(e,A)};Ye.parseInline=bo.parseInline;Ye.Parser=_r;Ye.parser=_r.parse;Ye.Renderer=us;Ye.TextRenderer=Uc;Ye.Lexer=Pr;Ye.lexer=Pr.lex;Ye.Tokenizer=cs;Ye.Hooks=vQ;Ye.parse=Ye;Ye.options;Ye.setOptions;Ye.use;Ye.walkTokens;Ye.parseInline;_r.parse;Pr.lex;class ar{constructor(A,t,r){this.lexer=void 0,this.start=void 0,this.end=void 0,this.lexer=A,this.start=t,this.end=r}static range(A,t){return t?!A||!A.loc||!t.loc||A.loc.lexer!==t.loc.lexer?null:new ar(A.loc.lexer,A.loc.start,t.loc.end):A&&A.loc}}class fr{constructor(A,t){this.text=void 0,this.loc=void 0,this.noexpand=void 0,this.treatAsRelax=void 0,this.text=A,this.loc=t}range(A,t){return new fr(t,ar.range(this,A))}}class NA{constructor(A,t){this.name=void 0,this.position=void 0,this.length=void 0,this.rawMessage=void 0;var r="KaTeX parse error: "+A,n,i,o=t&&t.loc;if(o&&o.start<=o.end){var g=o.lexer.input;n=o.start,i=o.end,n===g.length?r+=" at end of input: ":r+=" at position "+(n+1)+": ";var Q=g.slice(n,i).replace(/[^]/g,"$&̲"),B;n>15?B="…"+g.slice(n-15,n):B=g.slice(0,n);var a;i+15":">","<":"<",'"':""","'":"'"},_3=/[&><"']/g;function j3(e){return String(e).replace(_3,A=>P3[A])}var op=function e(A){return A.type==="ordgroup"||A.type==="color"?A.body.length===1?e(A.body[0]):A:A.type==="font"?e(A.body):A},V3=function(A){var t=op(A);return t.type==="mathord"||t.type==="textord"||t.type==="atom"},W3=function(A){if(!A)throw new Error("Expected non-null, but got "+String(A));return A},Z3=function(A){var t=/^[\x00-\x20]*([^\\/#?]*?)(:|�*58|�*3a|&colon)/i.exec(A);return t?t[2]!==":"||!/^[a-zA-Z][a-zA-Z0-9+\-.]*$/.test(t[1])?null:t[1].toLowerCase():"_relative"},Le={deflt:H3,escape:j3,hyphenate:z3,getBaseElem:op,isCharacterBox:V3,protocolFromUrl:Z3},ja={displayMode:{type:"boolean",description:"Render math in display mode, which puts the math in display style (so \\int and \\sum are large, for example), and centers the math on the page on its own line.",cli:"-d, --display-mode"},output:{type:{enum:["htmlAndMathml","html","mathml"]},description:"Determines the markup language of the output.",cli:"-F, --format "},leqno:{type:"boolean",description:"Render display math in leqno style (left-justified tags)."},fleqn:{type:"boolean",description:"Render display math flush left."},throwOnError:{type:"boolean",default:!0,cli:"-t, --no-throw-on-error",cliDescription:"Render errors (in the color given by --error-color) instead of throwing a ParseError exception when encountering an error."},errorColor:{type:"string",default:"#cc0000",cli:"-c, --error-color ",cliDescription:"A color string given in the format 'rgb' or 'rrggbb' (no #). This option determines the color of errors rendered by the -t option.",cliProcessor:e=>"#"+e},macros:{type:"object",cli:"-m, --macro ",cliDescription:"Define custom macro of the form '\\foo:expansion' (use multiple -m arguments for multiple macros).",cliDefault:[],cliProcessor:(e,A)=>(A.push(e),A)},minRuleThickness:{type:"number",description:"Specifies a minimum thickness, in ems, for fraction lines, `\\sqrt` top lines, `{array}` vertical lines, `\\hline`, `\\hdashline`, `\\underline`, `\\overline`, and the borders of `\\fbox`, `\\boxed`, and `\\fcolorbox`.",processor:e=>Math.max(0,e),cli:"--min-rule-thickness ",cliProcessor:parseFloat},colorIsTextColor:{type:"boolean",description:"Makes \\color behave like LaTeX's 2-argument \\textcolor, instead of LaTeX's one-argument \\color mode change.",cli:"-b, --color-is-text-color"},strict:{type:[{enum:["warn","ignore","error"]},"boolean","function"],description:"Turn on strict / LaTeX faithfulness mode, which throws an error if the input uses features that are not supported by LaTeX.",cli:"-S, --strict",cliDefault:!1},trust:{type:["boolean","function"],description:"Trust the input, enabling all HTML features such as \\url.",cli:"-T, --trust"},maxSize:{type:"number",default:1/0,description:"If non-zero, all user-specified sizes, e.g. in \\rule{500em}{500em}, will be capped to maxSize ems. Otherwise, elements and spaces can be arbitrarily large",processor:e=>Math.max(0,e),cli:"-s, --max-size ",cliProcessor:parseInt},maxExpand:{type:"number",default:1e3,description:"Limit the number of macro expansions to the specified number, to prevent e.g. infinite macro loops. If set to Infinity, the macro expander will try to fully expand as in LaTeX.",processor:e=>Math.max(0,e),cli:"-e, --max-expand ",cliProcessor:e=>e==="Infinity"?1/0:parseInt(e)},globalGroup:{type:"boolean",cli:!1}};function X3(e){if(e.default)return e.default;var A=e.type,t=Array.isArray(A)?A[0]:A;if(typeof t!="string")return t.enum[0];switch(t){case"boolean":return!1;case"string":return"";case"number":return 0;case"object":return{}}}let Kc=class{constructor(A){this.displayMode=void 0,this.output=void 0,this.leqno=void 0,this.fleqn=void 0,this.throwOnError=void 0,this.errorColor=void 0,this.macros=void 0,this.minRuleThickness=void 0,this.colorIsTextColor=void 0,this.strict=void 0,this.trust=void 0,this.maxSize=void 0,this.maxExpand=void 0,this.globalGroup=void 0,A=A||{};for(var t in ja)if(ja.hasOwnProperty(t)){var r=ja[t];this[t]=A[t]!==void 0?r.processor?r.processor(A[t]):A[t]:X3(r)}}reportNonstrict(A,t,r){var n=this.strict;if(typeof n=="function"&&(n=n(A,t,r)),!(!n||n==="ignore")){if(n===!0||n==="error")throw new NA("LaTeX-incompatible input and strict mode is set to 'error': "+(t+" ["+A+"]"),r);n==="warn"?typeof console<"u"&&console.warn("LaTeX-incompatible input and strict mode is set to 'warn': "+(t+" ["+A+"]")):typeof console<"u"&&console.warn("LaTeX-incompatible input and strict mode is set to "+("unrecognized '"+n+"': "+t+" ["+A+"]"))}}useStrictBehavior(A,t,r){var n=this.strict;if(typeof n=="function")try{n=n(A,t,r)}catch{n="error"}return!n||n==="ignore"?!1:n===!0||n==="error"?!0:n==="warn"?(typeof console<"u"&&console.warn("LaTeX-incompatible input and strict mode is set to 'warn': "+(t+" ["+A+"]")),!1):(typeof console<"u"&&console.warn("LaTeX-incompatible input and strict mode is set to "+("unrecognized '"+n+"': "+t+" ["+A+"]")),!1)}isTrusted(A){if(A.url&&!A.protocol){var t=Le.protocolFromUrl(A.url);if(t==null)return!1;A.protocol=t}var r=typeof this.trust=="function"?this.trust(A):this.trust;return!!r}};class ci{constructor(A,t,r){this.id=void 0,this.size=void 0,this.cramped=void 0,this.id=A,this.size=t,this.cramped=r}sup(){return In[$3[this.id]]}sub(){return In[AS[this.id]]}fracNum(){return In[eS[this.id]]}fracDen(){return In[tS[this.id]]}cramp(){return In[rS[this.id]]}text(){return In[nS[this.id]]}isTight(){return this.size>=2}}var Lc=0,ds=1,pg=2,Wn=3,$Q=4,xr=5,Sg=6,tr=7,In=[new ci(Lc,0,!1),new ci(ds,0,!0),new ci(pg,1,!1),new ci(Wn,1,!0),new ci($Q,2,!1),new ci(xr,2,!0),new ci(Sg,3,!1),new ci(tr,3,!0)],$3=[$Q,xr,$Q,xr,Sg,tr,Sg,tr],AS=[xr,xr,xr,xr,tr,tr,tr,tr],eS=[pg,Wn,$Q,xr,Sg,tr,Sg,tr],tS=[Wn,Wn,xr,xr,tr,tr,tr,tr],rS=[ds,ds,Wn,Wn,xr,xr,tr,tr],nS=[Lc,ds,pg,Wn,pg,Wn,pg,Wn],oe={DISPLAY:In[Lc],TEXT:In[pg],SCRIPT:In[$Q],SCRIPTSCRIPT:In[Sg]},VI=[{name:"latin",blocks:[[256,591],[768,879]]},{name:"cyrillic",blocks:[[1024,1279]]},{name:"armenian",blocks:[[1328,1423]]},{name:"brahmic",blocks:[[2304,4255]]},{name:"georgian",blocks:[[4256,4351]]},{name:"cjk",blocks:[[12288,12543],[19968,40879],[65280,65376]]},{name:"hangul",blocks:[[44032,55215]]}];function iS(e){for(var A=0;A=n[0]&&e<=n[1])return t.name}return null}var Va=[];VI.forEach(e=>e.blocks.forEach(A=>Va.push(...A)));function gp(e){for(var A=0;A=Va[A]&&e<=Va[A+1])return!0;return!1}var rg=80,oS=function(A,t){return"M95,"+(622+A+t)+` c-2.7,0,-7.17,-2.7,-13.5,-8c-5.8,-5.3,-9.5,-10,-9.5,-14 c0,-2,0.3,-3.3,1,-4c1.3,-2.7,23.83,-20.7,67.5,-54 c44.2,-33.3,65.8,-50.3,66.5,-51c1.3,-1.3,3,-2,5,-2c4.7,0,8.7,3.3,12,10 s173,378,173,378c0.7,0,35.3,-71,104,-213c68.7,-142,137.5,-285,206.5,-429 c69,-144,104.5,-217.7,106.5,-221 l`+A/2.075+" -"+A+` c5.3,-9.3,12,-14,20,-14 H400000v`+(40+A)+`H845.2724 s-225.272,467,-225.272,467s-235,486,-235,486c-2.7,4.7,-9,7,-19,7 c-6,0,-10,-1,-12,-3s-194,-422,-194,-422s-65,47,-65,47z M`+(834+A)+" "+t+"h400000v"+(40+A)+"h-400000z"},gS=function(A,t){return"M263,"+(601+A+t)+`c0.7,0,18,39.7,52,119 c34,79.3,68.167,158.7,102.5,238c34.3,79.3,51.8,119.3,52.5,120 c340,-704.7,510.7,-1060.3,512,-1067 l`+A/2.084+" -"+A+` c4.7,-7.3,11,-11,19,-11 H40000v`+(40+A)+`H1012.3 s-271.3,567,-271.3,567c-38.7,80.7,-84,175,-136,283c-52,108,-89.167,185.3,-111.5,232 c-22.3,46.7,-33.8,70.3,-34.5,71c-4.7,4.7,-12.3,7,-23,7s-12,-1,-12,-1 s-109,-253,-109,-253c-72.7,-168,-109.3,-252,-110,-252c-10.7,8,-22,16.7,-34,26 c-22,17.3,-33.3,26,-34,26s-26,-26,-26,-26s76,-59,76,-59s76,-60,76,-60z M`+(1001+A)+" "+t+"h400000v"+(40+A)+"h-400000z"},QS=function(A,t){return"M983 "+(10+A+t)+` l`+A/3.13+" -"+A+` c4,-6.7,10,-10,18,-10 H400000v`+(40+A)+` H1013.1s-83.4,268,-264.1,840c-180.7,572,-277,876.3,-289,913c-4.7,4.7,-12.7,7,-24,7 s-12,0,-12,0c-1.3,-3.3,-3.7,-11.7,-7,-25c-35.3,-125.3,-106.7,-373.3,-214,-744 c-10,12,-21,25,-33,39s-32,39,-32,39c-6,-5.3,-15,-14,-27,-26s25,-30,25,-30 c26.7,-32.7,52,-63,76,-91s52,-60,52,-60s208,722,208,722 c56,-175.3,126.3,-397.3,211,-666c84.7,-268.7,153.8,-488.2,207.5,-658.5 c53.7,-170.3,84.5,-266.8,92.5,-289.5z M`+(1001+A)+" "+t+"h400000v"+(40+A)+"h-400000z"},BS=function(A,t){return"M424,"+(2398+A+t)+` c-1.3,-0.7,-38.5,-172,-111.5,-514c-73,-342,-109.8,-513.3,-110.5,-514 c0,-2,-10.7,14.3,-32,49c-4.7,7.3,-9.8,15.7,-15.5,25c-5.7,9.3,-9.8,16,-12.5,20 s-5,7,-5,7c-4,-3.3,-8.3,-7.7,-13,-13s-13,-13,-13,-13s76,-122,76,-122s77,-121,77,-121 s209,968,209,968c0,-2,84.7,-361.7,254,-1079c169.3,-717.3,254.7,-1077.7,256,-1081 l`+A/4.223+" -"+A+`c4,-6.7,10,-10,18,-10 H400000 v`+(40+A)+`H1014.6 s-87.3,378.7,-272.6,1166c-185.3,787.3,-279.3,1182.3,-282,1185 c-2,6,-10,9,-24,9 c-8,0,-12,-0.7,-12,-2z M`+(1001+A)+" "+t+` h400000v`+(40+A)+"h-400000z"},aS=function(A,t){return"M473,"+(2713+A+t)+` c339.3,-1799.3,509.3,-2700,510,-2702 l`+A/5.298+" -"+A+` c3.3,-7.3,9.3,-11,18,-11 H400000v`+(40+A)+`H1017.7 s-90.5,478,-276.2,1466c-185.7,988,-279.5,1483,-281.5,1485c-2,6,-10,9,-24,9 c-8,0,-12,-0.7,-12,-2c0,-1.3,-5.3,-32,-16,-92c-50.7,-293.3,-119.7,-693.3,-207,-1200 c0,-1.3,-5.3,8.7,-16,30c-10.7,21.3,-21.3,42.7,-32,64s-16,33,-16,33s-26,-26,-26,-26 s76,-153,76,-153s77,-151,77,-151c0.7,0.7,35.7,202,105,604c67.3,400.7,102,602.7,104, 606zM`+(1001+A)+" "+t+"h400000v"+(40+A)+"H1017.7z"},sS=function(A){var t=A/2;return"M400000 "+A+" H0 L"+t+" 0 l65 45 L145 "+(A-80)+" H400000z"},ES=function(A,t,r){var n=r-54-t-A;return"M702 "+(A+t)+"H400000"+(40+A)+` H742v`+n+`l-4 4-4 4c-.667.7 -2 1.5-4 2.5s-4.167 1.833-6.5 2.5-5.5 1-9.5 1 h-12l-28-84c-16.667-52-96.667 -294.333-240-727l-212 -643 -85 170 c-4-3.333-8.333-7.667-13 -13l-13-13l77-155 77-156c66 199.333 139 419.667 219 661 l218 661zM702 `+t+"H400000v"+(40+A)+"H742z"},CS=function(A,t,r){t=1e3*t;var n="";switch(A){case"sqrtMain":n=oS(t,rg);break;case"sqrtSize1":n=gS(t,rg);break;case"sqrtSize2":n=QS(t,rg);break;case"sqrtSize3":n=BS(t,rg);break;case"sqrtSize4":n=aS(t,rg);break;case"sqrtTall":n=ES(t,rg,r)}return n},IS=function(A,t){switch(A){case"⎜":return"M291 0 H417 V"+t+" H291z M291 0 H417 V"+t+" H291z";case"∣":return"M145 0 H188 V"+t+" H145z M145 0 H188 V"+t+" H145z";case"∥":return"M145 0 H188 V"+t+" H145z M145 0 H188 V"+t+" H145z"+("M367 0 H410 V"+t+" H367z M367 0 H410 V"+t+" H367z");case"⎟":return"M457 0 H583 V"+t+" H457z M457 0 H583 V"+t+" H457z";case"⎢":return"M319 0 H403 V"+t+" H319z M319 0 H403 V"+t+" H319z";case"⎥":return"M263 0 H347 V"+t+" H263z M263 0 H347 V"+t+" H263z";case"⎪":return"M384 0 H504 V"+t+" H384z M384 0 H504 V"+t+" H384z";case"⏐":return"M312 0 H355 V"+t+" H312z M312 0 H355 V"+t+" H312z";case"‖":return"M257 0 H300 V"+t+" H257z M257 0 H300 V"+t+" H257z"+("M478 0 H521 V"+t+" H478z M478 0 H521 V"+t+" H478z");default:return""}},Mh={doubleleftarrow:`M262 157 l10-10c34-36 62.7-77 86-123 3.3-8 5-13.3 5-16 0-5.3-6.7-8-20-8-7.3 0-12.2.5-14.5 1.5-2.3 1-4.8 4.5-7.5 10.5-49.3 97.3-121.7 169.3-217 216-28 14-57.3 25-88 33-6.7 2-11 3.8-13 5.5-2 1.7-3 4.2-3 7.5s1 5.8 3 7.5 c2 1.7 6.3 3.5 13 5.5 68 17.3 128.2 47.8 180.5 91.5 52.3 43.7 93.8 96.2 124.5 157.5 9.3 8 15.3 12.3 18 13h6c12-.7 18-4 18-10 0-2-1.7-7-5-15-23.3-46-52-87 -86-123l-10-10h399738v-40H218c328 0 0 0 0 0l-10-8c-26.7-20-65.7-43-117-69 2.7 -2 6-3.7 10-5 36.7-16 72.3-37.3 107-64l10-8h399782v-40z m8 0v40h399730v-40zm0 194v40h399730v-40z`,doublerightarrow:`M399738 392l -10 10c-34 36-62.7 77-86 123-3.3 8-5 13.3-5 16 0 5.3 6.7 8 20 8 7.3 0 12.2-.5 14.5-1.5 2.3-1 4.8-4.5 7.5-10.5 49.3-97.3 121.7-169.3 217-216 28-14 57.3-25 88 -33 6.7-2 11-3.8 13-5.5 2-1.7 3-4.2 3-7.5s-1-5.8-3-7.5c-2-1.7-6.3-3.5-13-5.5-68 -17.3-128.2-47.8-180.5-91.5-52.3-43.7-93.8-96.2-124.5-157.5-9.3-8-15.3-12.3-18 -13h-6c-12 .7-18 4-18 10 0 2 1.7 7 5 15 23.3 46 52 87 86 123l10 10H0v40h399782 c-328 0 0 0 0 0l10 8c26.7 20 65.7 43 117 69-2.7 2-6 3.7-10 5-36.7 16-72.3 37.3 -107 64l-10 8H0v40zM0 157v40h399730v-40zm0 194v40h399730v-40z`,leftarrow:`M400000 241H110l3-3c68.7-52.7 113.7-120 135-202 4-14.7 6-23 6-25 0-7.3-7-11-21-11-8 0-13.2.8-15.5 2.5-2.3 1.7-4.2 5.8 -5.5 12.5-1.3 4.7-2.7 10.3-4 17-12 48.7-34.8 92-68.5 130S65.3 228.3 18 247 c-10 4-16 7.7-18 11 0 8.7 6 14.3 18 17 47.3 18.7 87.8 47 121.5 85S196 441.3 208 490c.7 2 1.3 5 2 9s1.2 6.7 1.5 8c.3 1.3 1 3.3 2 6s2.2 4.5 3.5 5.5c1.3 1 3.3 1.8 6 2.5s6 1 10 1c14 0 21-3.7 21-11 0-2-2-10.3-6-25-20-79.3-65-146.7-135-202 l-3-3h399890zM100 241v40h399900v-40z`,leftbrace:`M6 548l-6-6v-35l6-11c56-104 135.3-181.3 238-232 57.3-28.7 117 -45 179-50h399577v120H403c-43.3 7-81 15-113 26-100.7 33-179.7 91-237 174-2.7 5-6 9-10 13-.7 1-7.3 1-20 1H6z`,leftbraceunder:`M0 6l6-6h17c12.688 0 19.313.3 20 1 4 4 7.313 8.3 10 13 35.313 51.3 80.813 93.8 136.5 127.5 55.688 33.7 117.188 55.8 184.5 66.5.688 0 2 .3 4 1 18.688 2.7 76 4.3 172 5h399450v120H429l-6-1c-124.688-8-235-61.7 -331-161C60.687 138.7 32.312 99.3 7 54L0 41V6z`,leftgroup:`M400000 80 H435C64 80 168.3 229.4 21 260c-5.9 1.2-18 0-18 0-2 0-3-1-3-3v-38C76 61 257 0 435 0h399565z`,leftgroupunder:`M400000 262 H435C64 262 168.3 112.6 21 82c-5.9-1.2-18 0-18 0-2 0-3 1-3 3v38c76 158 257 219 435 219h399565z`,leftharpoon:`M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3 -3.3 10.2-9.5 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5 -18.3 3-21-1.3-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7 -196 228-6.7 4.7-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40z`,leftharpoonplus:`M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3-3.3 10.2-9.5 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5-18.3 3-21-1.3 -4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7-196 228-6.7 4.7 -10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40zM0 435v40h400000v-40z m0 0v40h400000v-40z`,leftharpoondown:`M7 241c-4 4-6.333 8.667-7 14 0 5.333.667 9 2 11s5.333 5.333 12 10c90.667 54 156 130 196 228 3.333 10.667 6.333 16.333 9 17 2 .667 5 1 9 1h5c10.667 0 16.667-2 18-6 2-2.667 1-9.667-3-21-32-87.333-82.667-157.667 -152-211l-3-3h399907v-40zM93 281 H400000 v-40L7 241z`,leftharpoondownplus:`M7 435c-4 4-6.3 8.7-7 14 0 5.3.7 9 2 11s5.3 5.3 12 10c90.7 54 156 130 196 228 3.3 10.7 6.3 16.3 9 17 2 .7 5 1 9 1h5c10.7 0 16.7 -2 18-6 2-2.7 1-9.7-3-21-32-87.3-82.7-157.7-152-211l-3-3h399907v-40H7zm93 0 v40h399900v-40zM0 241v40h399900v-40zm0 0v40h399900v-40z`,lefthook:`M400000 281 H103s-33-11.2-61-33.5S0 197.3 0 164s14.2-61.2 42.5 -83.5C70.8 58.2 104 47 142 47 c16.7 0 25 6.7 25 20 0 12-8.7 18.7-26 20-40 3.3 -68.7 15.7-86 37-10 12-15 25.3-15 40 0 22.7 9.8 40.7 29.5 54 19.7 13.3 43.5 21 71.5 23h399859zM103 281v-40h399897v40z`,leftlinesegment:`M40 281 V428 H0 V94 H40 V241 H400000 v40z M40 281 V428 H0 V94 H40 V241 H400000 v40z`,leftmapsto:`M40 281 V448H0V74H40V241H400000v40z M40 281 V448H0V74H40V241H400000v40z`,leftToFrom:`M0 147h400000v40H0zm0 214c68 40 115.7 95.7 143 167h22c15.3 0 23 -.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69-70-101l-7-8h399905v-40H95l7-8 c28.7-32 52-65.7 70-101 10.7-23.3 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 265.3 68 321 0 361zm0-174v-40h399900v40zm100 154v40h399900v-40z`,longequal:`M0 50 h400000 v40H0z m0 194h40000v40H0z M0 50 h400000 v40H0z m0 194h40000v40H0z`,midbrace:`M200428 334 c-100.7-8.3-195.3-44-280-108-55.3-42-101.7-93-139-153l-9-14c-2.7 4-5.7 8.7-9 14 -53.3 86.7-123.7 153-211 199-66.7 36-137.3 56.3-212 62H0V214h199568c178.3-11.7 311.7-78.3 403-201 6-8 9.7-12 11-12 .7-.7 6.7-1 18-1s17.3.3 18 1c1.3 0 5 4 11 12 44.7 59.3 101.3 106.3 170 141s145.3 54.3 229 60h199572v120z`,midbraceunder:`M199572 214 c100.7 8.3 195.3 44 280 108 55.3 42 101.7 93 139 153l9 14c2.7-4 5.7-8.7 9-14 53.3-86.7 123.7-153 211-199 66.7-36 137.3-56.3 212-62h199568v120H200432c-178.3 11.7-311.7 78.3-403 201-6 8-9.7 12-11 12-.7.7-6.7 1-18 1s-17.3-.3-18-1c-1.3 0 -5-4-11-12-44.7-59.3-101.3-106.3-170-141s-145.3-54.3-229-60H0V214z`,oiintSize1:`M512.6 71.6c272.6 0 320.3 106.8 320.3 178.2 0 70.8-47.7 177.6 -320.3 177.6S193.1 320.6 193.1 249.8c0-71.4 46.9-178.2 319.5-178.2z m368.1 178.2c0-86.4-60.9-215.4-368.1-215.4-306.4 0-367.3 129-367.3 215.4 0 85.8 60.9 214.8 367.3 214.8 307.2 0 368.1-129 368.1-214.8z`,oiintSize2:`M757.8 100.1c384.7 0 451.1 137.6 451.1 230 0 91.3-66.4 228.8 -451.1 228.8-386.3 0-452.7-137.5-452.7-228.8 0-92.4 66.4-230 452.7-230z m502.4 230c0-111.2-82.4-277.2-502.4-277.2s-504 166-504 277.2 c0 110 84 276 504 276s502.4-166 502.4-276z`,oiiintSize1:`M681.4 71.6c408.9 0 480.5 106.8 480.5 178.2 0 70.8-71.6 177.6 -480.5 177.6S202.1 320.6 202.1 249.8c0-71.4 70.5-178.2 479.3-178.2z m525.8 178.2c0-86.4-86.8-215.4-525.7-215.4-437.9 0-524.7 129-524.7 215.4 0 85.8 86.8 214.8 524.7 214.8 438.9 0 525.7-129 525.7-214.8z`,oiiintSize2:`M1021.2 53c603.6 0 707.8 165.8 707.8 277.2 0 110-104.2 275.8 -707.8 275.8-606 0-710.2-165.8-710.2-275.8C311 218.8 415.2 53 1021.2 53z m770.4 277.1c0-131.2-126.4-327.6-770.5-327.6S248.4 198.9 248.4 330.1 c0 130 128.8 326.4 772.7 326.4s770.5-196.4 770.5-326.4z`,rightarrow:`M0 241v40h399891c-47.3 35.3-84 78-110 128 -16.7 32-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20 11 8 0 13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7 39-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85 -40.5-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5 -12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67 151.7 139 205zm0 0v40h399900v-40z`,rightbrace:`M400000 542l -6 6h-17c-12.7 0-19.3-.3-20-1-4-4-7.3-8.3-10-13-35.3-51.3-80.8-93.8-136.5-127.5 s-117.2-55.8-184.5-66.5c-.7 0-2-.3-4-1-18.7-2.7-76-4.3-172-5H0V214h399571l6 1 c124.7 8 235 61.7 331 161 31.3 33.3 59.7 72.7 85 118l7 13v35z`,rightbraceunder:`M399994 0l6 6v35l-6 11c-56 104-135.3 181.3-238 232-57.3 28.7-117 45-179 50H-300V214h399897c43.3-7 81-15 113-26 100.7-33 179.7-91 237 -174 2.7-5 6-9 10-13 .7-1 7.3-1 20-1h17z`,rightgroup:`M0 80h399565c371 0 266.7 149.4 414 180 5.9 1.2 18 0 18 0 2 0 3-1 3-3v-38c-76-158-257-219-435-219H0z`,rightgroupunder:`M0 262h399565c371 0 266.7-149.4 414-180 5.9-1.2 18 0 18 0 2 0 3 1 3 3v38c-76 158-257 219-435 219H0z`,rightharpoon:`M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3 -3.7-15.3-11-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2 -10.7 0-16.7 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58 69.2 92 94.5zm0 0v40h399900v-40z`,rightharpoonplus:`M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3-3.7-15.3-11 -18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2-10.7 0-16.7 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58 69.2 92 94.5z m0 0v40h399900v-40z m100 194v40h399900v-40zm0 0v40h399900v-40z`,rightharpoondown:`M399747 511c0 7.3 6.7 11 20 11 8 0 13-.8 15-2.5s4.7-6.8 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3 8.5-5.8 9.5 -7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3-64.7 57-92 95 -27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 241v40h399900v-40z`,rightharpoondownplus:`M399747 705c0 7.3 6.7 11 20 11 8 0 13-.8 15-2.5s4.7-6.8 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3 8.5-5.8 9.5-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3 -64.7 57-92 95-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 435v40h399900v-40z m0-194v40h400000v-40zm0 0v40h400000v-40z`,righthook:`M399859 241c-764 0 0 0 0 0 40-3.3 68.7-15.7 86-37 10-12 15-25.3 15-40 0-22.7-9.8-40.7-29.5-54-19.7-13.3-43.5-21-71.5-23-17.3-1.3-26-8-26-20 0 -13.3 8.7-20 26-20 38 0 71 11.2 99 33.5 0 0 7 5.6 21 16.7 14 11.2 21 33.5 21 66.8s-14 61.2-42 83.5c-28 22.3-61 33.5-99 33.5L0 241z M0 281v-40h399859v40z`,rightlinesegment:`M399960 241 V94 h40 V428 h-40 V281 H0 v-40z M399960 241 V94 h40 V428 h-40 V281 H0 v-40z`,rightToFrom:`M400000 167c-70.7-42-118-97.7-142-167h-23c-15.3 0-23 .3-23 1 0 1.3 5.3 13.7 16 37 18 35.3 41.3 69 70 101l7 8H0v40h399905l-7 8c-28.7 32 -52 65.7-70 101-10.7 23.3-16 35.7-16 37 0 .7 7.7 1 23 1h23c24-69.3 71.3-125 142 -167z M100 147v40h399900v-40zM0 341v40h399900v-40z`,twoheadleftarrow:`M0 167c68 40 115.7 95.7 143 167h22c15.3 0 23-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69 -70-101l-7-8h125l9 7c50.7 39.3 85 86 103 140h46c0-4.7-6.3-18.7-19-42-18-35.3 -40-67.3-66-96l-9-9h399716v-40H284l9-9c26-28.7 48-60.7 66-96 12.7-23.333 19 -37.333 19-42h-46c-18 54-52.3 100.7-103 140l-9 7H95l7-8c28.7-32 52-65.7 70-101 10.7-23.333 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 71.3 68 127 0 167z`,twoheadrightarrow:`M400000 167 c-68-40-115.7-95.7-143-167h-22c-15.3 0-23 .3-23 1 0 1.3 5.3 13.7 16 37 18 35.3 41.3 69 70 101l7 8h-125l-9-7c-50.7-39.3-85-86-103-140h-46c0 4.7 6.3 18.7 19 42 18 35.3 40 67.3 66 96l9 9H0v40h399716l-9 9c-26 28.7-48 60.7-66 96-12.7 23.333 -19 37.333-19 42h46c18-54 52.3-100.7 103-140l9-7h125l-7 8c-28.7 32-52 65.7-70 101-10.7 23.333-16 35.7-16 37 0 .7 7.7 1 23 1h22c27.3-71.3 75-127 143-167z`,tilde1:`M200 55.538c-77 0-168 73.953-177 73.953-3 0-7 -2.175-9-5.437L2 97c-1-2-2-4-2-6 0-4 2-7 5-9l20-12C116 12 171 0 207 0c86 0 114 68 191 68 78 0 168-68 177-68 4 0 7 2 9 5l12 19c1 2.175 2 4.35 2 6.525 0 4.35-2 7.613-5 9.788l-19 13.05c-92 63.077-116.937 75.308-183 76.128 -68.267.847-113-73.952-191-73.952z`,tilde2:`M344 55.266c-142 0-300.638 81.316-311.5 86.418 -8.01 3.762-22.5 10.91-23.5 5.562L1 120c-1-2-1-3-1-4 0-5 3-9 8-10l18.4-9C160.9 31.9 283 0 358 0c148 0 188 122 331 122s314-97 326-97c4 0 8 2 10 7l7 21.114 c1 2.14 1 3.21 1 4.28 0 5.347-3 9.626-7 10.696l-22.3 12.622C852.6 158.372 751 181.476 676 181.476c-149 0-189-126.21-332-126.21z`,tilde3:`M786 59C457 59 32 175.242 13 175.242c-6 0-10-3.457 -11-10.37L.15 138c-1-7 3-12 10-13l19.2-6.4C378.4 40.7 634.3 0 804.3 0c337 0 411.8 157 746.8 157 328 0 754-112 773-112 5 0 10 3 11 9l1 14.075c1 8.066-.697 16.595-6.697 17.492l-21.052 7.31c-367.9 98.146-609.15 122.696-778.15 122.696 -338 0-409-156.573-744-156.573z`,tilde4:`M786 58C457 58 32 177.487 13 177.487c-6 0-10-3.345 -11-10.035L.15 143c-1-7 3-12 10-13l22-6.7C381.2 35 637.15 0 807.15 0c337 0 409 177 744 177 328 0 754-127 773-127 5 0 10 3 11 9l1 14.794c1 7.805-3 13.38-9 14.495l-20.7 5.574c-366.85 99.79-607.3 139.372-776.3 139.372-338 0-409 -175.236-744-175.236z`,vec:`M377 20c0-5.333 1.833-10 5.5-14S391 0 397 0c4.667 0 8.667 1.667 12 5 3.333 2.667 6.667 9 10 19 6.667 24.667 20.333 43.667 41 57 7.333 4.667 11 10.667 11 18 0 6-1 10-3 12s-6.667 5-14 9c-28.667 14.667-53.667 35.667-75 63 -1.333 1.333-3.167 3.5-5.5 6.5s-4 4.833-5 5.5c-1 .667-2.5 1.333-4.5 2s-4.333 1 -7 1c-4.667 0-9.167-1.833-13.5-5.5S337 184 337 178c0-12.667 15.667-32.333 47-59 H213l-171-1c-8.667-6-13-12.333-13-19 0-4.667 4.333-11.333 13-20h359 c-16-25.333-24-45-24-59z`,widehat1:`M529 0h5l519 115c5 1 9 5 9 10 0 1-1 2-1 3l-4 22 c-1 5-5 9-11 9h-2L532 67 19 159h-2c-5 0-9-4-11-9l-5-22c-1-6 2-12 8-13z`,widehat2:`M1181 0h2l1171 176c6 0 10 5 10 11l-2 23c-1 6-5 10 -11 10h-1L1182 67 15 220h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`,widehat3:`M1181 0h2l1171 236c6 0 10 5 10 11l-2 23c-1 6-5 10 -11 10h-1L1182 67 15 280h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`,widehat4:`M1181 0h2l1171 296c6 0 10 5 10 11l-2 23c-1 6-5 10 -11 10h-1L1182 67 15 340h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`,widecheck1:`M529,159h5l519,-115c5,-1,9,-5,9,-10c0,-1,-1,-2,-1,-3l-4,-22c-1, -5,-5,-9,-11,-9h-2l-512,92l-513,-92h-2c-5,0,-9,4,-11,9l-5,22c-1,6,2,12,8,13z`,widecheck2:`M1181,220h2l1171,-176c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10, -11,-10h-1l-1168,153l-1167,-153h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`,widecheck3:`M1181,280h2l1171,-236c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10, -11,-10h-1l-1168,213l-1167,-213h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`,widecheck4:`M1181,340h2l1171,-296c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10, -11,-10h-1l-1168,273l-1167,-273h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`,baraboveleftarrow:`M400000 620h-399890l3 -3c68.7 -52.7 113.7 -120 135 -202 c4 -14.7 6 -23 6 -25c0 -7.3 -7 -11 -21 -11c-8 0 -13.2 0.8 -15.5 2.5 c-2.3 1.7 -4.2 5.8 -5.5 12.5c-1.3 4.7 -2.7 10.3 -4 17c-12 48.7 -34.8 92 -68.5 130 s-74.2 66.3 -121.5 85c-10 4 -16 7.7 -18 11c0 8.7 6 14.3 18 17c47.3 18.7 87.8 47 121.5 85s56.5 81.3 68.5 130c0.7 2 1.3 5 2 9s1.2 6.7 1.5 8c0.3 1.3 1 3.3 2 6 s2.2 4.5 3.5 5.5c1.3 1 3.3 1.8 6 2.5s6 1 10 1c14 0 21 -3.7 21 -11 c0 -2 -2 -10.3 -6 -25c-20 -79.3 -65 -146.7 -135 -202l-3 -3h399890z M100 620v40h399900v-40z M0 241v40h399900v-40zM0 241v40h399900v-40z`,rightarrowabovebar:`M0 241v40h399891c-47.3 35.3-84 78-110 128-16.7 32 -27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20 11 8 0 13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7 39 -84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85-40.5 -119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5 -12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67 151.7 139 205zm96 379h399894v40H0zm0 0h399904v40H0z`,baraboveshortleftharpoon:`M507,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11 c1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17 c2,0.7,5,1,9,1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21 c-32,-87.3,-82.7,-157.7,-152,-211c0,0,-3,-3,-3,-3l399351,0l0,-40 c-398570,0,-399437,0,-399437,0z M593 435 v40 H399500 v-40z M0 281 v-40 H399908 v40z M0 281 v-40 H399908 v40z`,rightharpoonaboveshortbar:`M0,241 l0,40c399126,0,399993,0,399993,0 c4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199, -231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6 c-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z M0 241 v40 H399908 v-40z M0 475 v-40 H399500 v40z M0 475 v-40 H399500 v40z`,shortbaraboveleftharpoon:`M7,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11 c1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17c2,0.7,5,1,9, 1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21c-32,-87.3,-82.7,-157.7, -152,-211c0,0,-3,-3,-3,-3l399907,0l0,-40c-399126,0,-399993,0,-399993,0z M93 435 v40 H400000 v-40z M500 241 v40 H400000 v-40z M500 241 v40 H400000 v-40z`,shortrightharpoonabovebar:`M53,241l0,40c398570,0,399437,0,399437,0 c4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199, -231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6 c-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z M500 241 v40 H399408 v-40z M500 435 v40 H400000 v-40z`},lS=function(A,t){switch(A){case"lbrack":return"M403 1759 V84 H666 V0 H319 V1759 v"+t+` v1759 h347 v-84 H403z M403 1759 V0 H319 V1759 v`+t+" v1759 h84z";case"rbrack":return"M347 1759 V0 H0 V84 H263 V1759 v"+t+` v1759 H0 v84 H347z M347 1759 V0 H263 V1759 v`+t+" v1759 h84z";case"vert":return"M145 15 v585 v"+t+` v585 c2.667,10,9.667,15,21,15 c10,0,16.667,-5,20,-15 v-585 v`+-t+` v-585 c-2.667,-10,-9.667,-15,-21,-15 c-10,0,-16.667,5,-20,15z M188 15 H145 v585 v`+t+" v585 h43z";case"doublevert":return"M145 15 v585 v"+t+` v585 c2.667,10,9.667,15,21,15 c10,0,16.667,-5,20,-15 v-585 v`+-t+` v-585 c-2.667,-10,-9.667,-15,-21,-15 c-10,0,-16.667,5,-20,15z M188 15 H145 v585 v`+t+` v585 h43z M367 15 v585 v`+t+` v585 c2.667,10,9.667,15,21,15 c10,0,16.667,-5,20,-15 v-585 v`+-t+` v-585 c-2.667,-10,-9.667,-15,-21,-15 c-10,0,-16.667,5,-20,15z M410 15 H367 v585 v`+t+" v585 h43z";case"lfloor":return"M319 602 V0 H403 V602 v"+t+` v1715 h263 v84 H319z MM319 602 V0 H403 V602 v`+t+" v1715 H319z";case"rfloor":return"M319 602 V0 H403 V602 v"+t+` v1799 H0 v-84 H319z MM319 602 V0 H403 V602 v`+t+" v1715 H319z";case"lceil":return"M403 1759 V84 H666 V0 H319 V1759 v"+t+` v602 h84z M403 1759 V0 H319 V1759 v`+t+" v602 h84z";case"rceil":return"M347 1759 V0 H0 V84 H263 V1759 v"+t+` v602 h84z M347 1759 V0 h-84 V1759 v`+t+" v602 h84z";case"lparen":return`M863,9c0,-2,-2,-5,-6,-9c0,0,-17,0,-17,0c-12.7,0,-19.3,0.3,-20,1 c-5.3,5.3,-10.3,11,-15,17c-242.7,294.7,-395.3,682,-458,1162c-21.3,163.3,-33.3,349, -36,557 l0,`+(t+84)+`c0.2,6,0,26,0,60c2,159.3,10,310.7,24,454c53.3,528,210, 949.7,470,1265c4.7,6,9.7,11.7,15,17c0.7,0.7,7,1,19,1c0,0,18,0,18,0c4,-4,6,-7,6,-9 c0,-2.7,-3.3,-8.7,-10,-18c-135.3,-192.7,-235.5,-414.3,-300.5,-665c-65,-250.7,-102.5, -544.7,-112.5,-882c-2,-104,-3,-167,-3,-189 l0,-`+(t+92)+`c0,-162.7,5.7,-314,17,-454c20.7,-272,63.7,-513,129,-723c65.3, -210,155.3,-396.3,270,-559c6.7,-9.3,10,-15.3,10,-18z`;case"rparen":return`M76,0c-16.7,0,-25,3,-25,9c0,2,2,6.3,6,13c21.3,28.7,42.3,60.3, 63,95c96.7,156.7,172.8,332.5,228.5,527.5c55.7,195,92.8,416.5,111.5,664.5 c11.3,139.3,17,290.7,17,454c0,28,1.7,43,3.3,45l0,`+(t+9)+` c-3,4,-3.3,16.7,-3.3,38c0,162,-5.7,313.7,-17,455c-18.7,248,-55.8,469.3,-111.5,664 c-55.7,194.7,-131.8,370.3,-228.5,527c-20.7,34.7,-41.7,66.3,-63,95c-2,3.3,-4,7,-6,11 c0,7.3,5.7,11,17,11c0,0,11,0,11,0c9.3,0,14.3,-0.3,15,-1c5.3,-5.3,10.3,-11,15,-17 c242.7,-294.7,395.3,-681.7,458,-1161c21.3,-164.7,33.3,-350.7,36,-558 l0,-`+(t+144)+`c-2,-159.3,-10,-310.7,-24,-454c-53.3,-528,-210,-949.7, -470,-1265c-4.7,-6,-9.7,-11.7,-15,-17c-0.7,-0.7,-6.7,-1,-18,-1z`;default:throw new Error("Unknown stretchy delimiter.")}};class yB{constructor(A){this.children=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,this.children=A,this.classes=[],this.height=0,this.depth=0,this.maxFontSize=0,this.style={}}hasClass(A){return this.classes.includes(A)}toNode(){for(var A=document.createDocumentFragment(),t=0;tt.toText();return this.children.map(A).join("")}}var un={"AMS-Regular":{32:[0,0,0,0,.25],65:[0,.68889,0,0,.72222],66:[0,.68889,0,0,.66667],67:[0,.68889,0,0,.72222],68:[0,.68889,0,0,.72222],69:[0,.68889,0,0,.66667],70:[0,.68889,0,0,.61111],71:[0,.68889,0,0,.77778],72:[0,.68889,0,0,.77778],73:[0,.68889,0,0,.38889],74:[.16667,.68889,0,0,.5],75:[0,.68889,0,0,.77778],76:[0,.68889,0,0,.66667],77:[0,.68889,0,0,.94445],78:[0,.68889,0,0,.72222],79:[.16667,.68889,0,0,.77778],80:[0,.68889,0,0,.61111],81:[.16667,.68889,0,0,.77778],82:[0,.68889,0,0,.72222],83:[0,.68889,0,0,.55556],84:[0,.68889,0,0,.66667],85:[0,.68889,0,0,.72222],86:[0,.68889,0,0,.72222],87:[0,.68889,0,0,1],88:[0,.68889,0,0,.72222],89:[0,.68889,0,0,.72222],90:[0,.68889,0,0,.66667],107:[0,.68889,0,0,.55556],160:[0,0,0,0,.25],165:[0,.675,.025,0,.75],174:[.15559,.69224,0,0,.94666],240:[0,.68889,0,0,.55556],295:[0,.68889,0,0,.54028],710:[0,.825,0,0,2.33334],732:[0,.9,0,0,2.33334],770:[0,.825,0,0,2.33334],771:[0,.9,0,0,2.33334],989:[.08167,.58167,0,0,.77778],1008:[0,.43056,.04028,0,.66667],8245:[0,.54986,0,0,.275],8463:[0,.68889,0,0,.54028],8487:[0,.68889,0,0,.72222],8498:[0,.68889,0,0,.55556],8502:[0,.68889,0,0,.66667],8503:[0,.68889,0,0,.44445],8504:[0,.68889,0,0,.66667],8513:[0,.68889,0,0,.63889],8592:[-.03598,.46402,0,0,.5],8594:[-.03598,.46402,0,0,.5],8602:[-.13313,.36687,0,0,1],8603:[-.13313,.36687,0,0,1],8606:[.01354,.52239,0,0,1],8608:[.01354,.52239,0,0,1],8610:[.01354,.52239,0,0,1.11111],8611:[.01354,.52239,0,0,1.11111],8619:[0,.54986,0,0,1],8620:[0,.54986,0,0,1],8621:[-.13313,.37788,0,0,1.38889],8622:[-.13313,.36687,0,0,1],8624:[0,.69224,0,0,.5],8625:[0,.69224,0,0,.5],8630:[0,.43056,0,0,1],8631:[0,.43056,0,0,1],8634:[.08198,.58198,0,0,.77778],8635:[.08198,.58198,0,0,.77778],8638:[.19444,.69224,0,0,.41667],8639:[.19444,.69224,0,0,.41667],8642:[.19444,.69224,0,0,.41667],8643:[.19444,.69224,0,0,.41667],8644:[.1808,.675,0,0,1],8646:[.1808,.675,0,0,1],8647:[.1808,.675,0,0,1],8648:[.19444,.69224,0,0,.83334],8649:[.1808,.675,0,0,1],8650:[.19444,.69224,0,0,.83334],8651:[.01354,.52239,0,0,1],8652:[.01354,.52239,0,0,1],8653:[-.13313,.36687,0,0,1],8654:[-.13313,.36687,0,0,1],8655:[-.13313,.36687,0,0,1],8666:[.13667,.63667,0,0,1],8667:[.13667,.63667,0,0,1],8669:[-.13313,.37788,0,0,1],8672:[-.064,.437,0,0,1.334],8674:[-.064,.437,0,0,1.334],8705:[0,.825,0,0,.5],8708:[0,.68889,0,0,.55556],8709:[.08167,.58167,0,0,.77778],8717:[0,.43056,0,0,.42917],8722:[-.03598,.46402,0,0,.5],8724:[.08198,.69224,0,0,.77778],8726:[.08167,.58167,0,0,.77778],8733:[0,.69224,0,0,.77778],8736:[0,.69224,0,0,.72222],8737:[0,.69224,0,0,.72222],8738:[.03517,.52239,0,0,.72222],8739:[.08167,.58167,0,0,.22222],8740:[.25142,.74111,0,0,.27778],8741:[.08167,.58167,0,0,.38889],8742:[.25142,.74111,0,0,.5],8756:[0,.69224,0,0,.66667],8757:[0,.69224,0,0,.66667],8764:[-.13313,.36687,0,0,.77778],8765:[-.13313,.37788,0,0,.77778],8769:[-.13313,.36687,0,0,.77778],8770:[-.03625,.46375,0,0,.77778],8774:[.30274,.79383,0,0,.77778],8776:[-.01688,.48312,0,0,.77778],8778:[.08167,.58167,0,0,.77778],8782:[.06062,.54986,0,0,.77778],8783:[.06062,.54986,0,0,.77778],8785:[.08198,.58198,0,0,.77778],8786:[.08198,.58198,0,0,.77778],8787:[.08198,.58198,0,0,.77778],8790:[0,.69224,0,0,.77778],8791:[.22958,.72958,0,0,.77778],8796:[.08198,.91667,0,0,.77778],8806:[.25583,.75583,0,0,.77778],8807:[.25583,.75583,0,0,.77778],8808:[.25142,.75726,0,0,.77778],8809:[.25142,.75726,0,0,.77778],8812:[.25583,.75583,0,0,.5],8814:[.20576,.70576,0,0,.77778],8815:[.20576,.70576,0,0,.77778],8816:[.30274,.79383,0,0,.77778],8817:[.30274,.79383,0,0,.77778],8818:[.22958,.72958,0,0,.77778],8819:[.22958,.72958,0,0,.77778],8822:[.1808,.675,0,0,.77778],8823:[.1808,.675,0,0,.77778],8828:[.13667,.63667,0,0,.77778],8829:[.13667,.63667,0,0,.77778],8830:[.22958,.72958,0,0,.77778],8831:[.22958,.72958,0,0,.77778],8832:[.20576,.70576,0,0,.77778],8833:[.20576,.70576,0,0,.77778],8840:[.30274,.79383,0,0,.77778],8841:[.30274,.79383,0,0,.77778],8842:[.13597,.63597,0,0,.77778],8843:[.13597,.63597,0,0,.77778],8847:[.03517,.54986,0,0,.77778],8848:[.03517,.54986,0,0,.77778],8858:[.08198,.58198,0,0,.77778],8859:[.08198,.58198,0,0,.77778],8861:[.08198,.58198,0,0,.77778],8862:[0,.675,0,0,.77778],8863:[0,.675,0,0,.77778],8864:[0,.675,0,0,.77778],8865:[0,.675,0,0,.77778],8872:[0,.69224,0,0,.61111],8873:[0,.69224,0,0,.72222],8874:[0,.69224,0,0,.88889],8876:[0,.68889,0,0,.61111],8877:[0,.68889,0,0,.61111],8878:[0,.68889,0,0,.72222],8879:[0,.68889,0,0,.72222],8882:[.03517,.54986,0,0,.77778],8883:[.03517,.54986,0,0,.77778],8884:[.13667,.63667,0,0,.77778],8885:[.13667,.63667,0,0,.77778],8888:[0,.54986,0,0,1.11111],8890:[.19444,.43056,0,0,.55556],8891:[.19444,.69224,0,0,.61111],8892:[.19444,.69224,0,0,.61111],8901:[0,.54986,0,0,.27778],8903:[.08167,.58167,0,0,.77778],8905:[.08167,.58167,0,0,.77778],8906:[.08167,.58167,0,0,.77778],8907:[0,.69224,0,0,.77778],8908:[0,.69224,0,0,.77778],8909:[-.03598,.46402,0,0,.77778],8910:[0,.54986,0,0,.76042],8911:[0,.54986,0,0,.76042],8912:[.03517,.54986,0,0,.77778],8913:[.03517,.54986,0,0,.77778],8914:[0,.54986,0,0,.66667],8915:[0,.54986,0,0,.66667],8916:[0,.69224,0,0,.66667],8918:[.0391,.5391,0,0,.77778],8919:[.0391,.5391,0,0,.77778],8920:[.03517,.54986,0,0,1.33334],8921:[.03517,.54986,0,0,1.33334],8922:[.38569,.88569,0,0,.77778],8923:[.38569,.88569,0,0,.77778],8926:[.13667,.63667,0,0,.77778],8927:[.13667,.63667,0,0,.77778],8928:[.30274,.79383,0,0,.77778],8929:[.30274,.79383,0,0,.77778],8934:[.23222,.74111,0,0,.77778],8935:[.23222,.74111,0,0,.77778],8936:[.23222,.74111,0,0,.77778],8937:[.23222,.74111,0,0,.77778],8938:[.20576,.70576,0,0,.77778],8939:[.20576,.70576,0,0,.77778],8940:[.30274,.79383,0,0,.77778],8941:[.30274,.79383,0,0,.77778],8994:[.19444,.69224,0,0,.77778],8995:[.19444,.69224,0,0,.77778],9416:[.15559,.69224,0,0,.90222],9484:[0,.69224,0,0,.5],9488:[0,.69224,0,0,.5],9492:[0,.37788,0,0,.5],9496:[0,.37788,0,0,.5],9585:[.19444,.68889,0,0,.88889],9586:[.19444,.74111,0,0,.88889],9632:[0,.675,0,0,.77778],9633:[0,.675,0,0,.77778],9650:[0,.54986,0,0,.72222],9651:[0,.54986,0,0,.72222],9654:[.03517,.54986,0,0,.77778],9660:[0,.54986,0,0,.72222],9661:[0,.54986,0,0,.72222],9664:[.03517,.54986,0,0,.77778],9674:[.11111,.69224,0,0,.66667],9733:[.19444,.69224,0,0,.94445],10003:[0,.69224,0,0,.83334],10016:[0,.69224,0,0,.83334],10731:[.11111,.69224,0,0,.66667],10846:[.19444,.75583,0,0,.61111],10877:[.13667,.63667,0,0,.77778],10878:[.13667,.63667,0,0,.77778],10885:[.25583,.75583,0,0,.77778],10886:[.25583,.75583,0,0,.77778],10887:[.13597,.63597,0,0,.77778],10888:[.13597,.63597,0,0,.77778],10889:[.26167,.75726,0,0,.77778],10890:[.26167,.75726,0,0,.77778],10891:[.48256,.98256,0,0,.77778],10892:[.48256,.98256,0,0,.77778],10901:[.13667,.63667,0,0,.77778],10902:[.13667,.63667,0,0,.77778],10933:[.25142,.75726,0,0,.77778],10934:[.25142,.75726,0,0,.77778],10935:[.26167,.75726,0,0,.77778],10936:[.26167,.75726,0,0,.77778],10937:[.26167,.75726,0,0,.77778],10938:[.26167,.75726,0,0,.77778],10949:[.25583,.75583,0,0,.77778],10950:[.25583,.75583,0,0,.77778],10955:[.28481,.79383,0,0,.77778],10956:[.28481,.79383,0,0,.77778],57350:[.08167,.58167,0,0,.22222],57351:[.08167,.58167,0,0,.38889],57352:[.08167,.58167,0,0,.77778],57353:[0,.43056,.04028,0,.66667],57356:[.25142,.75726,0,0,.77778],57357:[.25142,.75726,0,0,.77778],57358:[.41951,.91951,0,0,.77778],57359:[.30274,.79383,0,0,.77778],57360:[.30274,.79383,0,0,.77778],57361:[.41951,.91951,0,0,.77778],57366:[.25142,.75726,0,0,.77778],57367:[.25142,.75726,0,0,.77778],57368:[.25142,.75726,0,0,.77778],57369:[.25142,.75726,0,0,.77778],57370:[.13597,.63597,0,0,.77778],57371:[.13597,.63597,0,0,.77778]},"Caligraphic-Regular":{32:[0,0,0,0,.25],65:[0,.68333,0,.19445,.79847],66:[0,.68333,.03041,.13889,.65681],67:[0,.68333,.05834,.13889,.52653],68:[0,.68333,.02778,.08334,.77139],69:[0,.68333,.08944,.11111,.52778],70:[0,.68333,.09931,.11111,.71875],71:[.09722,.68333,.0593,.11111,.59487],72:[0,.68333,.00965,.11111,.84452],73:[0,.68333,.07382,0,.54452],74:[.09722,.68333,.18472,.16667,.67778],75:[0,.68333,.01445,.05556,.76195],76:[0,.68333,0,.13889,.68972],77:[0,.68333,0,.13889,1.2009],78:[0,.68333,.14736,.08334,.82049],79:[0,.68333,.02778,.11111,.79611],80:[0,.68333,.08222,.08334,.69556],81:[.09722,.68333,0,.11111,.81667],82:[0,.68333,0,.08334,.8475],83:[0,.68333,.075,.13889,.60556],84:[0,.68333,.25417,0,.54464],85:[0,.68333,.09931,.08334,.62583],86:[0,.68333,.08222,0,.61278],87:[0,.68333,.08222,.08334,.98778],88:[0,.68333,.14643,.13889,.7133],89:[.09722,.68333,.08222,.08334,.66834],90:[0,.68333,.07944,.13889,.72473],160:[0,0,0,0,.25]},"Fraktur-Regular":{32:[0,0,0,0,.25],33:[0,.69141,0,0,.29574],34:[0,.69141,0,0,.21471],38:[0,.69141,0,0,.73786],39:[0,.69141,0,0,.21201],40:[.24982,.74947,0,0,.38865],41:[.24982,.74947,0,0,.38865],42:[0,.62119,0,0,.27764],43:[.08319,.58283,0,0,.75623],44:[0,.10803,0,0,.27764],45:[.08319,.58283,0,0,.75623],46:[0,.10803,0,0,.27764],47:[.24982,.74947,0,0,.50181],48:[0,.47534,0,0,.50181],49:[0,.47534,0,0,.50181],50:[0,.47534,0,0,.50181],51:[.18906,.47534,0,0,.50181],52:[.18906,.47534,0,0,.50181],53:[.18906,.47534,0,0,.50181],54:[0,.69141,0,0,.50181],55:[.18906,.47534,0,0,.50181],56:[0,.69141,0,0,.50181],57:[.18906,.47534,0,0,.50181],58:[0,.47534,0,0,.21606],59:[.12604,.47534,0,0,.21606],61:[-.13099,.36866,0,0,.75623],63:[0,.69141,0,0,.36245],65:[0,.69141,0,0,.7176],66:[0,.69141,0,0,.88397],67:[0,.69141,0,0,.61254],68:[0,.69141,0,0,.83158],69:[0,.69141,0,0,.66278],70:[.12604,.69141,0,0,.61119],71:[0,.69141,0,0,.78539],72:[.06302,.69141,0,0,.7203],73:[0,.69141,0,0,.55448],74:[.12604,.69141,0,0,.55231],75:[0,.69141,0,0,.66845],76:[0,.69141,0,0,.66602],77:[0,.69141,0,0,1.04953],78:[0,.69141,0,0,.83212],79:[0,.69141,0,0,.82699],80:[.18906,.69141,0,0,.82753],81:[.03781,.69141,0,0,.82699],82:[0,.69141,0,0,.82807],83:[0,.69141,0,0,.82861],84:[0,.69141,0,0,.66899],85:[0,.69141,0,0,.64576],86:[0,.69141,0,0,.83131],87:[0,.69141,0,0,1.04602],88:[0,.69141,0,0,.71922],89:[.18906,.69141,0,0,.83293],90:[.12604,.69141,0,0,.60201],91:[.24982,.74947,0,0,.27764],93:[.24982,.74947,0,0,.27764],94:[0,.69141,0,0,.49965],97:[0,.47534,0,0,.50046],98:[0,.69141,0,0,.51315],99:[0,.47534,0,0,.38946],100:[0,.62119,0,0,.49857],101:[0,.47534,0,0,.40053],102:[.18906,.69141,0,0,.32626],103:[.18906,.47534,0,0,.5037],104:[.18906,.69141,0,0,.52126],105:[0,.69141,0,0,.27899],106:[0,.69141,0,0,.28088],107:[0,.69141,0,0,.38946],108:[0,.69141,0,0,.27953],109:[0,.47534,0,0,.76676],110:[0,.47534,0,0,.52666],111:[0,.47534,0,0,.48885],112:[.18906,.52396,0,0,.50046],113:[.18906,.47534,0,0,.48912],114:[0,.47534,0,0,.38919],115:[0,.47534,0,0,.44266],116:[0,.62119,0,0,.33301],117:[0,.47534,0,0,.5172],118:[0,.52396,0,0,.5118],119:[0,.52396,0,0,.77351],120:[.18906,.47534,0,0,.38865],121:[.18906,.47534,0,0,.49884],122:[.18906,.47534,0,0,.39054],160:[0,0,0,0,.25],8216:[0,.69141,0,0,.21471],8217:[0,.69141,0,0,.21471],58112:[0,.62119,0,0,.49749],58113:[0,.62119,0,0,.4983],58114:[.18906,.69141,0,0,.33328],58115:[.18906,.69141,0,0,.32923],58116:[.18906,.47534,0,0,.50343],58117:[0,.69141,0,0,.33301],58118:[0,.62119,0,0,.33409],58119:[0,.47534,0,0,.50073]},"Main-Bold":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.35],34:[0,.69444,0,0,.60278],35:[.19444,.69444,0,0,.95833],36:[.05556,.75,0,0,.575],37:[.05556,.75,0,0,.95833],38:[0,.69444,0,0,.89444],39:[0,.69444,0,0,.31944],40:[.25,.75,0,0,.44722],41:[.25,.75,0,0,.44722],42:[0,.75,0,0,.575],43:[.13333,.63333,0,0,.89444],44:[.19444,.15556,0,0,.31944],45:[0,.44444,0,0,.38333],46:[0,.15556,0,0,.31944],47:[.25,.75,0,0,.575],48:[0,.64444,0,0,.575],49:[0,.64444,0,0,.575],50:[0,.64444,0,0,.575],51:[0,.64444,0,0,.575],52:[0,.64444,0,0,.575],53:[0,.64444,0,0,.575],54:[0,.64444,0,0,.575],55:[0,.64444,0,0,.575],56:[0,.64444,0,0,.575],57:[0,.64444,0,0,.575],58:[0,.44444,0,0,.31944],59:[.19444,.44444,0,0,.31944],60:[.08556,.58556,0,0,.89444],61:[-.10889,.39111,0,0,.89444],62:[.08556,.58556,0,0,.89444],63:[0,.69444,0,0,.54305],64:[0,.69444,0,0,.89444],65:[0,.68611,0,0,.86944],66:[0,.68611,0,0,.81805],67:[0,.68611,0,0,.83055],68:[0,.68611,0,0,.88194],69:[0,.68611,0,0,.75555],70:[0,.68611,0,0,.72361],71:[0,.68611,0,0,.90416],72:[0,.68611,0,0,.9],73:[0,.68611,0,0,.43611],74:[0,.68611,0,0,.59444],75:[0,.68611,0,0,.90138],76:[0,.68611,0,0,.69166],77:[0,.68611,0,0,1.09166],78:[0,.68611,0,0,.9],79:[0,.68611,0,0,.86388],80:[0,.68611,0,0,.78611],81:[.19444,.68611,0,0,.86388],82:[0,.68611,0,0,.8625],83:[0,.68611,0,0,.63889],84:[0,.68611,0,0,.8],85:[0,.68611,0,0,.88472],86:[0,.68611,.01597,0,.86944],87:[0,.68611,.01597,0,1.18888],88:[0,.68611,0,0,.86944],89:[0,.68611,.02875,0,.86944],90:[0,.68611,0,0,.70277],91:[.25,.75,0,0,.31944],92:[.25,.75,0,0,.575],93:[.25,.75,0,0,.31944],94:[0,.69444,0,0,.575],95:[.31,.13444,.03194,0,.575],97:[0,.44444,0,0,.55902],98:[0,.69444,0,0,.63889],99:[0,.44444,0,0,.51111],100:[0,.69444,0,0,.63889],101:[0,.44444,0,0,.52708],102:[0,.69444,.10903,0,.35139],103:[.19444,.44444,.01597,0,.575],104:[0,.69444,0,0,.63889],105:[0,.69444,0,0,.31944],106:[.19444,.69444,0,0,.35139],107:[0,.69444,0,0,.60694],108:[0,.69444,0,0,.31944],109:[0,.44444,0,0,.95833],110:[0,.44444,0,0,.63889],111:[0,.44444,0,0,.575],112:[.19444,.44444,0,0,.63889],113:[.19444,.44444,0,0,.60694],114:[0,.44444,0,0,.47361],115:[0,.44444,0,0,.45361],116:[0,.63492,0,0,.44722],117:[0,.44444,0,0,.63889],118:[0,.44444,.01597,0,.60694],119:[0,.44444,.01597,0,.83055],120:[0,.44444,0,0,.60694],121:[.19444,.44444,.01597,0,.60694],122:[0,.44444,0,0,.51111],123:[.25,.75,0,0,.575],124:[.25,.75,0,0,.31944],125:[.25,.75,0,0,.575],126:[.35,.34444,0,0,.575],160:[0,0,0,0,.25],163:[0,.69444,0,0,.86853],168:[0,.69444,0,0,.575],172:[0,.44444,0,0,.76666],176:[0,.69444,0,0,.86944],177:[.13333,.63333,0,0,.89444],184:[.17014,0,0,0,.51111],198:[0,.68611,0,0,1.04166],215:[.13333,.63333,0,0,.89444],216:[.04861,.73472,0,0,.89444],223:[0,.69444,0,0,.59722],230:[0,.44444,0,0,.83055],247:[.13333,.63333,0,0,.89444],248:[.09722,.54167,0,0,.575],305:[0,.44444,0,0,.31944],338:[0,.68611,0,0,1.16944],339:[0,.44444,0,0,.89444],567:[.19444,.44444,0,0,.35139],710:[0,.69444,0,0,.575],711:[0,.63194,0,0,.575],713:[0,.59611,0,0,.575],714:[0,.69444,0,0,.575],715:[0,.69444,0,0,.575],728:[0,.69444,0,0,.575],729:[0,.69444,0,0,.31944],730:[0,.69444,0,0,.86944],732:[0,.69444,0,0,.575],733:[0,.69444,0,0,.575],915:[0,.68611,0,0,.69166],916:[0,.68611,0,0,.95833],920:[0,.68611,0,0,.89444],923:[0,.68611,0,0,.80555],926:[0,.68611,0,0,.76666],928:[0,.68611,0,0,.9],931:[0,.68611,0,0,.83055],933:[0,.68611,0,0,.89444],934:[0,.68611,0,0,.83055],936:[0,.68611,0,0,.89444],937:[0,.68611,0,0,.83055],8211:[0,.44444,.03194,0,.575],8212:[0,.44444,.03194,0,1.14999],8216:[0,.69444,0,0,.31944],8217:[0,.69444,0,0,.31944],8220:[0,.69444,0,0,.60278],8221:[0,.69444,0,0,.60278],8224:[.19444,.69444,0,0,.51111],8225:[.19444,.69444,0,0,.51111],8242:[0,.55556,0,0,.34444],8407:[0,.72444,.15486,0,.575],8463:[0,.69444,0,0,.66759],8465:[0,.69444,0,0,.83055],8467:[0,.69444,0,0,.47361],8472:[.19444,.44444,0,0,.74027],8476:[0,.69444,0,0,.83055],8501:[0,.69444,0,0,.70277],8592:[-.10889,.39111,0,0,1.14999],8593:[.19444,.69444,0,0,.575],8594:[-.10889,.39111,0,0,1.14999],8595:[.19444,.69444,0,0,.575],8596:[-.10889,.39111,0,0,1.14999],8597:[.25,.75,0,0,.575],8598:[.19444,.69444,0,0,1.14999],8599:[.19444,.69444,0,0,1.14999],8600:[.19444,.69444,0,0,1.14999],8601:[.19444,.69444,0,0,1.14999],8636:[-.10889,.39111,0,0,1.14999],8637:[-.10889,.39111,0,0,1.14999],8640:[-.10889,.39111,0,0,1.14999],8641:[-.10889,.39111,0,0,1.14999],8656:[-.10889,.39111,0,0,1.14999],8657:[.19444,.69444,0,0,.70277],8658:[-.10889,.39111,0,0,1.14999],8659:[.19444,.69444,0,0,.70277],8660:[-.10889,.39111,0,0,1.14999],8661:[.25,.75,0,0,.70277],8704:[0,.69444,0,0,.63889],8706:[0,.69444,.06389,0,.62847],8707:[0,.69444,0,0,.63889],8709:[.05556,.75,0,0,.575],8711:[0,.68611,0,0,.95833],8712:[.08556,.58556,0,0,.76666],8715:[.08556,.58556,0,0,.76666],8722:[.13333,.63333,0,0,.89444],8723:[.13333,.63333,0,0,.89444],8725:[.25,.75,0,0,.575],8726:[.25,.75,0,0,.575],8727:[-.02778,.47222,0,0,.575],8728:[-.02639,.47361,0,0,.575],8729:[-.02639,.47361,0,0,.575],8730:[.18,.82,0,0,.95833],8733:[0,.44444,0,0,.89444],8734:[0,.44444,0,0,1.14999],8736:[0,.69224,0,0,.72222],8739:[.25,.75,0,0,.31944],8741:[.25,.75,0,0,.575],8743:[0,.55556,0,0,.76666],8744:[0,.55556,0,0,.76666],8745:[0,.55556,0,0,.76666],8746:[0,.55556,0,0,.76666],8747:[.19444,.69444,.12778,0,.56875],8764:[-.10889,.39111,0,0,.89444],8768:[.19444,.69444,0,0,.31944],8771:[.00222,.50222,0,0,.89444],8773:[.027,.638,0,0,.894],8776:[.02444,.52444,0,0,.89444],8781:[.00222,.50222,0,0,.89444],8801:[.00222,.50222,0,0,.89444],8804:[.19667,.69667,0,0,.89444],8805:[.19667,.69667,0,0,.89444],8810:[.08556,.58556,0,0,1.14999],8811:[.08556,.58556,0,0,1.14999],8826:[.08556,.58556,0,0,.89444],8827:[.08556,.58556,0,0,.89444],8834:[.08556,.58556,0,0,.89444],8835:[.08556,.58556,0,0,.89444],8838:[.19667,.69667,0,0,.89444],8839:[.19667,.69667,0,0,.89444],8846:[0,.55556,0,0,.76666],8849:[.19667,.69667,0,0,.89444],8850:[.19667,.69667,0,0,.89444],8851:[0,.55556,0,0,.76666],8852:[0,.55556,0,0,.76666],8853:[.13333,.63333,0,0,.89444],8854:[.13333,.63333,0,0,.89444],8855:[.13333,.63333,0,0,.89444],8856:[.13333,.63333,0,0,.89444],8857:[.13333,.63333,0,0,.89444],8866:[0,.69444,0,0,.70277],8867:[0,.69444,0,0,.70277],8868:[0,.69444,0,0,.89444],8869:[0,.69444,0,0,.89444],8900:[-.02639,.47361,0,0,.575],8901:[-.02639,.47361,0,0,.31944],8902:[-.02778,.47222,0,0,.575],8968:[.25,.75,0,0,.51111],8969:[.25,.75,0,0,.51111],8970:[.25,.75,0,0,.51111],8971:[.25,.75,0,0,.51111],8994:[-.13889,.36111,0,0,1.14999],8995:[-.13889,.36111,0,0,1.14999],9651:[.19444,.69444,0,0,1.02222],9657:[-.02778,.47222,0,0,.575],9661:[.19444,.69444,0,0,1.02222],9667:[-.02778,.47222,0,0,.575],9711:[.19444,.69444,0,0,1.14999],9824:[.12963,.69444,0,0,.89444],9825:[.12963,.69444,0,0,.89444],9826:[.12963,.69444,0,0,.89444],9827:[.12963,.69444,0,0,.89444],9837:[0,.75,0,0,.44722],9838:[.19444,.69444,0,0,.44722],9839:[.19444,.69444,0,0,.44722],10216:[.25,.75,0,0,.44722],10217:[.25,.75,0,0,.44722],10815:[0,.68611,0,0,.9],10927:[.19667,.69667,0,0,.89444],10928:[.19667,.69667,0,0,.89444],57376:[.19444,.69444,0,0,0]},"Main-BoldItalic":{32:[0,0,0,0,.25],33:[0,.69444,.11417,0,.38611],34:[0,.69444,.07939,0,.62055],35:[.19444,.69444,.06833,0,.94444],37:[.05556,.75,.12861,0,.94444],38:[0,.69444,.08528,0,.88555],39:[0,.69444,.12945,0,.35555],40:[.25,.75,.15806,0,.47333],41:[.25,.75,.03306,0,.47333],42:[0,.75,.14333,0,.59111],43:[.10333,.60333,.03306,0,.88555],44:[.19444,.14722,0,0,.35555],45:[0,.44444,.02611,0,.41444],46:[0,.14722,0,0,.35555],47:[.25,.75,.15806,0,.59111],48:[0,.64444,.13167,0,.59111],49:[0,.64444,.13167,0,.59111],50:[0,.64444,.13167,0,.59111],51:[0,.64444,.13167,0,.59111],52:[.19444,.64444,.13167,0,.59111],53:[0,.64444,.13167,0,.59111],54:[0,.64444,.13167,0,.59111],55:[.19444,.64444,.13167,0,.59111],56:[0,.64444,.13167,0,.59111],57:[0,.64444,.13167,0,.59111],58:[0,.44444,.06695,0,.35555],59:[.19444,.44444,.06695,0,.35555],61:[-.10889,.39111,.06833,0,.88555],63:[0,.69444,.11472,0,.59111],64:[0,.69444,.09208,0,.88555],65:[0,.68611,0,0,.86555],66:[0,.68611,.0992,0,.81666],67:[0,.68611,.14208,0,.82666],68:[0,.68611,.09062,0,.87555],69:[0,.68611,.11431,0,.75666],70:[0,.68611,.12903,0,.72722],71:[0,.68611,.07347,0,.89527],72:[0,.68611,.17208,0,.8961],73:[0,.68611,.15681,0,.47166],74:[0,.68611,.145,0,.61055],75:[0,.68611,.14208,0,.89499],76:[0,.68611,0,0,.69777],77:[0,.68611,.17208,0,1.07277],78:[0,.68611,.17208,0,.8961],79:[0,.68611,.09062,0,.85499],80:[0,.68611,.0992,0,.78721],81:[.19444,.68611,.09062,0,.85499],82:[0,.68611,.02559,0,.85944],83:[0,.68611,.11264,0,.64999],84:[0,.68611,.12903,0,.7961],85:[0,.68611,.17208,0,.88083],86:[0,.68611,.18625,0,.86555],87:[0,.68611,.18625,0,1.15999],88:[0,.68611,.15681,0,.86555],89:[0,.68611,.19803,0,.86555],90:[0,.68611,.14208,0,.70888],91:[.25,.75,.1875,0,.35611],93:[.25,.75,.09972,0,.35611],94:[0,.69444,.06709,0,.59111],95:[.31,.13444,.09811,0,.59111],97:[0,.44444,.09426,0,.59111],98:[0,.69444,.07861,0,.53222],99:[0,.44444,.05222,0,.53222],100:[0,.69444,.10861,0,.59111],101:[0,.44444,.085,0,.53222],102:[.19444,.69444,.21778,0,.4],103:[.19444,.44444,.105,0,.53222],104:[0,.69444,.09426,0,.59111],105:[0,.69326,.11387,0,.35555],106:[.19444,.69326,.1672,0,.35555],107:[0,.69444,.11111,0,.53222],108:[0,.69444,.10861,0,.29666],109:[0,.44444,.09426,0,.94444],110:[0,.44444,.09426,0,.64999],111:[0,.44444,.07861,0,.59111],112:[.19444,.44444,.07861,0,.59111],113:[.19444,.44444,.105,0,.53222],114:[0,.44444,.11111,0,.50167],115:[0,.44444,.08167,0,.48694],116:[0,.63492,.09639,0,.385],117:[0,.44444,.09426,0,.62055],118:[0,.44444,.11111,0,.53222],119:[0,.44444,.11111,0,.76777],120:[0,.44444,.12583,0,.56055],121:[.19444,.44444,.105,0,.56166],122:[0,.44444,.13889,0,.49055],126:[.35,.34444,.11472,0,.59111],160:[0,0,0,0,.25],168:[0,.69444,.11473,0,.59111],176:[0,.69444,0,0,.94888],184:[.17014,0,0,0,.53222],198:[0,.68611,.11431,0,1.02277],216:[.04861,.73472,.09062,0,.88555],223:[.19444,.69444,.09736,0,.665],230:[0,.44444,.085,0,.82666],248:[.09722,.54167,.09458,0,.59111],305:[0,.44444,.09426,0,.35555],338:[0,.68611,.11431,0,1.14054],339:[0,.44444,.085,0,.82666],567:[.19444,.44444,.04611,0,.385],710:[0,.69444,.06709,0,.59111],711:[0,.63194,.08271,0,.59111],713:[0,.59444,.10444,0,.59111],714:[0,.69444,.08528,0,.59111],715:[0,.69444,0,0,.59111],728:[0,.69444,.10333,0,.59111],729:[0,.69444,.12945,0,.35555],730:[0,.69444,0,0,.94888],732:[0,.69444,.11472,0,.59111],733:[0,.69444,.11472,0,.59111],915:[0,.68611,.12903,0,.69777],916:[0,.68611,0,0,.94444],920:[0,.68611,.09062,0,.88555],923:[0,.68611,0,0,.80666],926:[0,.68611,.15092,0,.76777],928:[0,.68611,.17208,0,.8961],931:[0,.68611,.11431,0,.82666],933:[0,.68611,.10778,0,.88555],934:[0,.68611,.05632,0,.82666],936:[0,.68611,.10778,0,.88555],937:[0,.68611,.0992,0,.82666],8211:[0,.44444,.09811,0,.59111],8212:[0,.44444,.09811,0,1.18221],8216:[0,.69444,.12945,0,.35555],8217:[0,.69444,.12945,0,.35555],8220:[0,.69444,.16772,0,.62055],8221:[0,.69444,.07939,0,.62055]},"Main-Italic":{32:[0,0,0,0,.25],33:[0,.69444,.12417,0,.30667],34:[0,.69444,.06961,0,.51444],35:[.19444,.69444,.06616,0,.81777],37:[.05556,.75,.13639,0,.81777],38:[0,.69444,.09694,0,.76666],39:[0,.69444,.12417,0,.30667],40:[.25,.75,.16194,0,.40889],41:[.25,.75,.03694,0,.40889],42:[0,.75,.14917,0,.51111],43:[.05667,.56167,.03694,0,.76666],44:[.19444,.10556,0,0,.30667],45:[0,.43056,.02826,0,.35778],46:[0,.10556,0,0,.30667],47:[.25,.75,.16194,0,.51111],48:[0,.64444,.13556,0,.51111],49:[0,.64444,.13556,0,.51111],50:[0,.64444,.13556,0,.51111],51:[0,.64444,.13556,0,.51111],52:[.19444,.64444,.13556,0,.51111],53:[0,.64444,.13556,0,.51111],54:[0,.64444,.13556,0,.51111],55:[.19444,.64444,.13556,0,.51111],56:[0,.64444,.13556,0,.51111],57:[0,.64444,.13556,0,.51111],58:[0,.43056,.0582,0,.30667],59:[.19444,.43056,.0582,0,.30667],61:[-.13313,.36687,.06616,0,.76666],63:[0,.69444,.1225,0,.51111],64:[0,.69444,.09597,0,.76666],65:[0,.68333,0,0,.74333],66:[0,.68333,.10257,0,.70389],67:[0,.68333,.14528,0,.71555],68:[0,.68333,.09403,0,.755],69:[0,.68333,.12028,0,.67833],70:[0,.68333,.13305,0,.65277],71:[0,.68333,.08722,0,.77361],72:[0,.68333,.16389,0,.74333],73:[0,.68333,.15806,0,.38555],74:[0,.68333,.14028,0,.525],75:[0,.68333,.14528,0,.76888],76:[0,.68333,0,0,.62722],77:[0,.68333,.16389,0,.89666],78:[0,.68333,.16389,0,.74333],79:[0,.68333,.09403,0,.76666],80:[0,.68333,.10257,0,.67833],81:[.19444,.68333,.09403,0,.76666],82:[0,.68333,.03868,0,.72944],83:[0,.68333,.11972,0,.56222],84:[0,.68333,.13305,0,.71555],85:[0,.68333,.16389,0,.74333],86:[0,.68333,.18361,0,.74333],87:[0,.68333,.18361,0,.99888],88:[0,.68333,.15806,0,.74333],89:[0,.68333,.19383,0,.74333],90:[0,.68333,.14528,0,.61333],91:[.25,.75,.1875,0,.30667],93:[.25,.75,.10528,0,.30667],94:[0,.69444,.06646,0,.51111],95:[.31,.12056,.09208,0,.51111],97:[0,.43056,.07671,0,.51111],98:[0,.69444,.06312,0,.46],99:[0,.43056,.05653,0,.46],100:[0,.69444,.10333,0,.51111],101:[0,.43056,.07514,0,.46],102:[.19444,.69444,.21194,0,.30667],103:[.19444,.43056,.08847,0,.46],104:[0,.69444,.07671,0,.51111],105:[0,.65536,.1019,0,.30667],106:[.19444,.65536,.14467,0,.30667],107:[0,.69444,.10764,0,.46],108:[0,.69444,.10333,0,.25555],109:[0,.43056,.07671,0,.81777],110:[0,.43056,.07671,0,.56222],111:[0,.43056,.06312,0,.51111],112:[.19444,.43056,.06312,0,.51111],113:[.19444,.43056,.08847,0,.46],114:[0,.43056,.10764,0,.42166],115:[0,.43056,.08208,0,.40889],116:[0,.61508,.09486,0,.33222],117:[0,.43056,.07671,0,.53666],118:[0,.43056,.10764,0,.46],119:[0,.43056,.10764,0,.66444],120:[0,.43056,.12042,0,.46389],121:[.19444,.43056,.08847,0,.48555],122:[0,.43056,.12292,0,.40889],126:[.35,.31786,.11585,0,.51111],160:[0,0,0,0,.25],168:[0,.66786,.10474,0,.51111],176:[0,.69444,0,0,.83129],184:[.17014,0,0,0,.46],198:[0,.68333,.12028,0,.88277],216:[.04861,.73194,.09403,0,.76666],223:[.19444,.69444,.10514,0,.53666],230:[0,.43056,.07514,0,.71555],248:[.09722,.52778,.09194,0,.51111],338:[0,.68333,.12028,0,.98499],339:[0,.43056,.07514,0,.71555],710:[0,.69444,.06646,0,.51111],711:[0,.62847,.08295,0,.51111],713:[0,.56167,.10333,0,.51111],714:[0,.69444,.09694,0,.51111],715:[0,.69444,0,0,.51111],728:[0,.69444,.10806,0,.51111],729:[0,.66786,.11752,0,.30667],730:[0,.69444,0,0,.83129],732:[0,.66786,.11585,0,.51111],733:[0,.69444,.1225,0,.51111],915:[0,.68333,.13305,0,.62722],916:[0,.68333,0,0,.81777],920:[0,.68333,.09403,0,.76666],923:[0,.68333,0,0,.69222],926:[0,.68333,.15294,0,.66444],928:[0,.68333,.16389,0,.74333],931:[0,.68333,.12028,0,.71555],933:[0,.68333,.11111,0,.76666],934:[0,.68333,.05986,0,.71555],936:[0,.68333,.11111,0,.76666],937:[0,.68333,.10257,0,.71555],8211:[0,.43056,.09208,0,.51111],8212:[0,.43056,.09208,0,1.02222],8216:[0,.69444,.12417,0,.30667],8217:[0,.69444,.12417,0,.30667],8220:[0,.69444,.1685,0,.51444],8221:[0,.69444,.06961,0,.51444],8463:[0,.68889,0,0,.54028]},"Main-Regular":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.27778],34:[0,.69444,0,0,.5],35:[.19444,.69444,0,0,.83334],36:[.05556,.75,0,0,.5],37:[.05556,.75,0,0,.83334],38:[0,.69444,0,0,.77778],39:[0,.69444,0,0,.27778],40:[.25,.75,0,0,.38889],41:[.25,.75,0,0,.38889],42:[0,.75,0,0,.5],43:[.08333,.58333,0,0,.77778],44:[.19444,.10556,0,0,.27778],45:[0,.43056,0,0,.33333],46:[0,.10556,0,0,.27778],47:[.25,.75,0,0,.5],48:[0,.64444,0,0,.5],49:[0,.64444,0,0,.5],50:[0,.64444,0,0,.5],51:[0,.64444,0,0,.5],52:[0,.64444,0,0,.5],53:[0,.64444,0,0,.5],54:[0,.64444,0,0,.5],55:[0,.64444,0,0,.5],56:[0,.64444,0,0,.5],57:[0,.64444,0,0,.5],58:[0,.43056,0,0,.27778],59:[.19444,.43056,0,0,.27778],60:[.0391,.5391,0,0,.77778],61:[-.13313,.36687,0,0,.77778],62:[.0391,.5391,0,0,.77778],63:[0,.69444,0,0,.47222],64:[0,.69444,0,0,.77778],65:[0,.68333,0,0,.75],66:[0,.68333,0,0,.70834],67:[0,.68333,0,0,.72222],68:[0,.68333,0,0,.76389],69:[0,.68333,0,0,.68056],70:[0,.68333,0,0,.65278],71:[0,.68333,0,0,.78472],72:[0,.68333,0,0,.75],73:[0,.68333,0,0,.36111],74:[0,.68333,0,0,.51389],75:[0,.68333,0,0,.77778],76:[0,.68333,0,0,.625],77:[0,.68333,0,0,.91667],78:[0,.68333,0,0,.75],79:[0,.68333,0,0,.77778],80:[0,.68333,0,0,.68056],81:[.19444,.68333,0,0,.77778],82:[0,.68333,0,0,.73611],83:[0,.68333,0,0,.55556],84:[0,.68333,0,0,.72222],85:[0,.68333,0,0,.75],86:[0,.68333,.01389,0,.75],87:[0,.68333,.01389,0,1.02778],88:[0,.68333,0,0,.75],89:[0,.68333,.025,0,.75],90:[0,.68333,0,0,.61111],91:[.25,.75,0,0,.27778],92:[.25,.75,0,0,.5],93:[.25,.75,0,0,.27778],94:[0,.69444,0,0,.5],95:[.31,.12056,.02778,0,.5],97:[0,.43056,0,0,.5],98:[0,.69444,0,0,.55556],99:[0,.43056,0,0,.44445],100:[0,.69444,0,0,.55556],101:[0,.43056,0,0,.44445],102:[0,.69444,.07778,0,.30556],103:[.19444,.43056,.01389,0,.5],104:[0,.69444,0,0,.55556],105:[0,.66786,0,0,.27778],106:[.19444,.66786,0,0,.30556],107:[0,.69444,0,0,.52778],108:[0,.69444,0,0,.27778],109:[0,.43056,0,0,.83334],110:[0,.43056,0,0,.55556],111:[0,.43056,0,0,.5],112:[.19444,.43056,0,0,.55556],113:[.19444,.43056,0,0,.52778],114:[0,.43056,0,0,.39167],115:[0,.43056,0,0,.39445],116:[0,.61508,0,0,.38889],117:[0,.43056,0,0,.55556],118:[0,.43056,.01389,0,.52778],119:[0,.43056,.01389,0,.72222],120:[0,.43056,0,0,.52778],121:[.19444,.43056,.01389,0,.52778],122:[0,.43056,0,0,.44445],123:[.25,.75,0,0,.5],124:[.25,.75,0,0,.27778],125:[.25,.75,0,0,.5],126:[.35,.31786,0,0,.5],160:[0,0,0,0,.25],163:[0,.69444,0,0,.76909],167:[.19444,.69444,0,0,.44445],168:[0,.66786,0,0,.5],172:[0,.43056,0,0,.66667],176:[0,.69444,0,0,.75],177:[.08333,.58333,0,0,.77778],182:[.19444,.69444,0,0,.61111],184:[.17014,0,0,0,.44445],198:[0,.68333,0,0,.90278],215:[.08333,.58333,0,0,.77778],216:[.04861,.73194,0,0,.77778],223:[0,.69444,0,0,.5],230:[0,.43056,0,0,.72222],247:[.08333,.58333,0,0,.77778],248:[.09722,.52778,0,0,.5],305:[0,.43056,0,0,.27778],338:[0,.68333,0,0,1.01389],339:[0,.43056,0,0,.77778],567:[.19444,.43056,0,0,.30556],710:[0,.69444,0,0,.5],711:[0,.62847,0,0,.5],713:[0,.56778,0,0,.5],714:[0,.69444,0,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,0,0,.5],729:[0,.66786,0,0,.27778],730:[0,.69444,0,0,.75],732:[0,.66786,0,0,.5],733:[0,.69444,0,0,.5],915:[0,.68333,0,0,.625],916:[0,.68333,0,0,.83334],920:[0,.68333,0,0,.77778],923:[0,.68333,0,0,.69445],926:[0,.68333,0,0,.66667],928:[0,.68333,0,0,.75],931:[0,.68333,0,0,.72222],933:[0,.68333,0,0,.77778],934:[0,.68333,0,0,.72222],936:[0,.68333,0,0,.77778],937:[0,.68333,0,0,.72222],8211:[0,.43056,.02778,0,.5],8212:[0,.43056,.02778,0,1],8216:[0,.69444,0,0,.27778],8217:[0,.69444,0,0,.27778],8220:[0,.69444,0,0,.5],8221:[0,.69444,0,0,.5],8224:[.19444,.69444,0,0,.44445],8225:[.19444,.69444,0,0,.44445],8230:[0,.123,0,0,1.172],8242:[0,.55556,0,0,.275],8407:[0,.71444,.15382,0,.5],8463:[0,.68889,0,0,.54028],8465:[0,.69444,0,0,.72222],8467:[0,.69444,0,.11111,.41667],8472:[.19444,.43056,0,.11111,.63646],8476:[0,.69444,0,0,.72222],8501:[0,.69444,0,0,.61111],8592:[-.13313,.36687,0,0,1],8593:[.19444,.69444,0,0,.5],8594:[-.13313,.36687,0,0,1],8595:[.19444,.69444,0,0,.5],8596:[-.13313,.36687,0,0,1],8597:[.25,.75,0,0,.5],8598:[.19444,.69444,0,0,1],8599:[.19444,.69444,0,0,1],8600:[.19444,.69444,0,0,1],8601:[.19444,.69444,0,0,1],8614:[.011,.511,0,0,1],8617:[.011,.511,0,0,1.126],8618:[.011,.511,0,0,1.126],8636:[-.13313,.36687,0,0,1],8637:[-.13313,.36687,0,0,1],8640:[-.13313,.36687,0,0,1],8641:[-.13313,.36687,0,0,1],8652:[.011,.671,0,0,1],8656:[-.13313,.36687,0,0,1],8657:[.19444,.69444,0,0,.61111],8658:[-.13313,.36687,0,0,1],8659:[.19444,.69444,0,0,.61111],8660:[-.13313,.36687,0,0,1],8661:[.25,.75,0,0,.61111],8704:[0,.69444,0,0,.55556],8706:[0,.69444,.05556,.08334,.5309],8707:[0,.69444,0,0,.55556],8709:[.05556,.75,0,0,.5],8711:[0,.68333,0,0,.83334],8712:[.0391,.5391,0,0,.66667],8715:[.0391,.5391,0,0,.66667],8722:[.08333,.58333,0,0,.77778],8723:[.08333,.58333,0,0,.77778],8725:[.25,.75,0,0,.5],8726:[.25,.75,0,0,.5],8727:[-.03472,.46528,0,0,.5],8728:[-.05555,.44445,0,0,.5],8729:[-.05555,.44445,0,0,.5],8730:[.2,.8,0,0,.83334],8733:[0,.43056,0,0,.77778],8734:[0,.43056,0,0,1],8736:[0,.69224,0,0,.72222],8739:[.25,.75,0,0,.27778],8741:[.25,.75,0,0,.5],8743:[0,.55556,0,0,.66667],8744:[0,.55556,0,0,.66667],8745:[0,.55556,0,0,.66667],8746:[0,.55556,0,0,.66667],8747:[.19444,.69444,.11111,0,.41667],8764:[-.13313,.36687,0,0,.77778],8768:[.19444,.69444,0,0,.27778],8771:[-.03625,.46375,0,0,.77778],8773:[-.022,.589,0,0,.778],8776:[-.01688,.48312,0,0,.77778],8781:[-.03625,.46375,0,0,.77778],8784:[-.133,.673,0,0,.778],8801:[-.03625,.46375,0,0,.77778],8804:[.13597,.63597,0,0,.77778],8805:[.13597,.63597,0,0,.77778],8810:[.0391,.5391,0,0,1],8811:[.0391,.5391,0,0,1],8826:[.0391,.5391,0,0,.77778],8827:[.0391,.5391,0,0,.77778],8834:[.0391,.5391,0,0,.77778],8835:[.0391,.5391,0,0,.77778],8838:[.13597,.63597,0,0,.77778],8839:[.13597,.63597,0,0,.77778],8846:[0,.55556,0,0,.66667],8849:[.13597,.63597,0,0,.77778],8850:[.13597,.63597,0,0,.77778],8851:[0,.55556,0,0,.66667],8852:[0,.55556,0,0,.66667],8853:[.08333,.58333,0,0,.77778],8854:[.08333,.58333,0,0,.77778],8855:[.08333,.58333,0,0,.77778],8856:[.08333,.58333,0,0,.77778],8857:[.08333,.58333,0,0,.77778],8866:[0,.69444,0,0,.61111],8867:[0,.69444,0,0,.61111],8868:[0,.69444,0,0,.77778],8869:[0,.69444,0,0,.77778],8872:[.249,.75,0,0,.867],8900:[-.05555,.44445,0,0,.5],8901:[-.05555,.44445,0,0,.27778],8902:[-.03472,.46528,0,0,.5],8904:[.005,.505,0,0,.9],8942:[.03,.903,0,0,.278],8943:[-.19,.313,0,0,1.172],8945:[-.1,.823,0,0,1.282],8968:[.25,.75,0,0,.44445],8969:[.25,.75,0,0,.44445],8970:[.25,.75,0,0,.44445],8971:[.25,.75,0,0,.44445],8994:[-.14236,.35764,0,0,1],8995:[-.14236,.35764,0,0,1],9136:[.244,.744,0,0,.412],9137:[.244,.745,0,0,.412],9651:[.19444,.69444,0,0,.88889],9657:[-.03472,.46528,0,0,.5],9661:[.19444,.69444,0,0,.88889],9667:[-.03472,.46528,0,0,.5],9711:[.19444,.69444,0,0,1],9824:[.12963,.69444,0,0,.77778],9825:[.12963,.69444,0,0,.77778],9826:[.12963,.69444,0,0,.77778],9827:[.12963,.69444,0,0,.77778],9837:[0,.75,0,0,.38889],9838:[.19444,.69444,0,0,.38889],9839:[.19444,.69444,0,0,.38889],10216:[.25,.75,0,0,.38889],10217:[.25,.75,0,0,.38889],10222:[.244,.744,0,0,.412],10223:[.244,.745,0,0,.412],10229:[.011,.511,0,0,1.609],10230:[.011,.511,0,0,1.638],10231:[.011,.511,0,0,1.859],10232:[.024,.525,0,0,1.609],10233:[.024,.525,0,0,1.638],10234:[.024,.525,0,0,1.858],10236:[.011,.511,0,0,1.638],10815:[0,.68333,0,0,.75],10927:[.13597,.63597,0,0,.77778],10928:[.13597,.63597,0,0,.77778],57376:[.19444,.69444,0,0,0]},"Math-BoldItalic":{32:[0,0,0,0,.25],48:[0,.44444,0,0,.575],49:[0,.44444,0,0,.575],50:[0,.44444,0,0,.575],51:[.19444,.44444,0,0,.575],52:[.19444,.44444,0,0,.575],53:[.19444,.44444,0,0,.575],54:[0,.64444,0,0,.575],55:[.19444,.44444,0,0,.575],56:[0,.64444,0,0,.575],57:[.19444,.44444,0,0,.575],65:[0,.68611,0,0,.86944],66:[0,.68611,.04835,0,.8664],67:[0,.68611,.06979,0,.81694],68:[0,.68611,.03194,0,.93812],69:[0,.68611,.05451,0,.81007],70:[0,.68611,.15972,0,.68889],71:[0,.68611,0,0,.88673],72:[0,.68611,.08229,0,.98229],73:[0,.68611,.07778,0,.51111],74:[0,.68611,.10069,0,.63125],75:[0,.68611,.06979,0,.97118],76:[0,.68611,0,0,.75555],77:[0,.68611,.11424,0,1.14201],78:[0,.68611,.11424,0,.95034],79:[0,.68611,.03194,0,.83666],80:[0,.68611,.15972,0,.72309],81:[.19444,.68611,0,0,.86861],82:[0,.68611,.00421,0,.87235],83:[0,.68611,.05382,0,.69271],84:[0,.68611,.15972,0,.63663],85:[0,.68611,.11424,0,.80027],86:[0,.68611,.25555,0,.67778],87:[0,.68611,.15972,0,1.09305],88:[0,.68611,.07778,0,.94722],89:[0,.68611,.25555,0,.67458],90:[0,.68611,.06979,0,.77257],97:[0,.44444,0,0,.63287],98:[0,.69444,0,0,.52083],99:[0,.44444,0,0,.51342],100:[0,.69444,0,0,.60972],101:[0,.44444,0,0,.55361],102:[.19444,.69444,.11042,0,.56806],103:[.19444,.44444,.03704,0,.5449],104:[0,.69444,0,0,.66759],105:[0,.69326,0,0,.4048],106:[.19444,.69326,.0622,0,.47083],107:[0,.69444,.01852,0,.6037],108:[0,.69444,.0088,0,.34815],109:[0,.44444,0,0,1.0324],110:[0,.44444,0,0,.71296],111:[0,.44444,0,0,.58472],112:[.19444,.44444,0,0,.60092],113:[.19444,.44444,.03704,0,.54213],114:[0,.44444,.03194,0,.5287],115:[0,.44444,0,0,.53125],116:[0,.63492,0,0,.41528],117:[0,.44444,0,0,.68102],118:[0,.44444,.03704,0,.56666],119:[0,.44444,.02778,0,.83148],120:[0,.44444,0,0,.65903],121:[.19444,.44444,.03704,0,.59028],122:[0,.44444,.04213,0,.55509],160:[0,0,0,0,.25],915:[0,.68611,.15972,0,.65694],916:[0,.68611,0,0,.95833],920:[0,.68611,.03194,0,.86722],923:[0,.68611,0,0,.80555],926:[0,.68611,.07458,0,.84125],928:[0,.68611,.08229,0,.98229],931:[0,.68611,.05451,0,.88507],933:[0,.68611,.15972,0,.67083],934:[0,.68611,0,0,.76666],936:[0,.68611,.11653,0,.71402],937:[0,.68611,.04835,0,.8789],945:[0,.44444,0,0,.76064],946:[.19444,.69444,.03403,0,.65972],947:[.19444,.44444,.06389,0,.59003],948:[0,.69444,.03819,0,.52222],949:[0,.44444,0,0,.52882],950:[.19444,.69444,.06215,0,.50833],951:[.19444,.44444,.03704,0,.6],952:[0,.69444,.03194,0,.5618],953:[0,.44444,0,0,.41204],954:[0,.44444,0,0,.66759],955:[0,.69444,0,0,.67083],956:[.19444,.44444,0,0,.70787],957:[0,.44444,.06898,0,.57685],958:[.19444,.69444,.03021,0,.50833],959:[0,.44444,0,0,.58472],960:[0,.44444,.03704,0,.68241],961:[.19444,.44444,0,0,.6118],962:[.09722,.44444,.07917,0,.42361],963:[0,.44444,.03704,0,.68588],964:[0,.44444,.13472,0,.52083],965:[0,.44444,.03704,0,.63055],966:[.19444,.44444,0,0,.74722],967:[.19444,.44444,0,0,.71805],968:[.19444,.69444,.03704,0,.75833],969:[0,.44444,.03704,0,.71782],977:[0,.69444,0,0,.69155],981:[.19444,.69444,0,0,.7125],982:[0,.44444,.03194,0,.975],1009:[.19444,.44444,0,0,.6118],1013:[0,.44444,0,0,.48333],57649:[0,.44444,0,0,.39352],57911:[.19444,.44444,0,0,.43889]},"Math-Italic":{32:[0,0,0,0,.25],48:[0,.43056,0,0,.5],49:[0,.43056,0,0,.5],50:[0,.43056,0,0,.5],51:[.19444,.43056,0,0,.5],52:[.19444,.43056,0,0,.5],53:[.19444,.43056,0,0,.5],54:[0,.64444,0,0,.5],55:[.19444,.43056,0,0,.5],56:[0,.64444,0,0,.5],57:[.19444,.43056,0,0,.5],65:[0,.68333,0,.13889,.75],66:[0,.68333,.05017,.08334,.75851],67:[0,.68333,.07153,.08334,.71472],68:[0,.68333,.02778,.05556,.82792],69:[0,.68333,.05764,.08334,.7382],70:[0,.68333,.13889,.08334,.64306],71:[0,.68333,0,.08334,.78625],72:[0,.68333,.08125,.05556,.83125],73:[0,.68333,.07847,.11111,.43958],74:[0,.68333,.09618,.16667,.55451],75:[0,.68333,.07153,.05556,.84931],76:[0,.68333,0,.02778,.68056],77:[0,.68333,.10903,.08334,.97014],78:[0,.68333,.10903,.08334,.80347],79:[0,.68333,.02778,.08334,.76278],80:[0,.68333,.13889,.08334,.64201],81:[.19444,.68333,0,.08334,.79056],82:[0,.68333,.00773,.08334,.75929],83:[0,.68333,.05764,.08334,.6132],84:[0,.68333,.13889,.08334,.58438],85:[0,.68333,.10903,.02778,.68278],86:[0,.68333,.22222,0,.58333],87:[0,.68333,.13889,0,.94445],88:[0,.68333,.07847,.08334,.82847],89:[0,.68333,.22222,0,.58056],90:[0,.68333,.07153,.08334,.68264],97:[0,.43056,0,0,.52859],98:[0,.69444,0,0,.42917],99:[0,.43056,0,.05556,.43276],100:[0,.69444,0,.16667,.52049],101:[0,.43056,0,.05556,.46563],102:[.19444,.69444,.10764,.16667,.48959],103:[.19444,.43056,.03588,.02778,.47697],104:[0,.69444,0,0,.57616],105:[0,.65952,0,0,.34451],106:[.19444,.65952,.05724,0,.41181],107:[0,.69444,.03148,0,.5206],108:[0,.69444,.01968,.08334,.29838],109:[0,.43056,0,0,.87801],110:[0,.43056,0,0,.60023],111:[0,.43056,0,.05556,.48472],112:[.19444,.43056,0,.08334,.50313],113:[.19444,.43056,.03588,.08334,.44641],114:[0,.43056,.02778,.05556,.45116],115:[0,.43056,0,.05556,.46875],116:[0,.61508,0,.08334,.36111],117:[0,.43056,0,.02778,.57246],118:[0,.43056,.03588,.02778,.48472],119:[0,.43056,.02691,.08334,.71592],120:[0,.43056,0,.02778,.57153],121:[.19444,.43056,.03588,.05556,.49028],122:[0,.43056,.04398,.05556,.46505],160:[0,0,0,0,.25],915:[0,.68333,.13889,.08334,.61528],916:[0,.68333,0,.16667,.83334],920:[0,.68333,.02778,.08334,.76278],923:[0,.68333,0,.16667,.69445],926:[0,.68333,.07569,.08334,.74236],928:[0,.68333,.08125,.05556,.83125],931:[0,.68333,.05764,.08334,.77986],933:[0,.68333,.13889,.05556,.58333],934:[0,.68333,0,.08334,.66667],936:[0,.68333,.11,.05556,.61222],937:[0,.68333,.05017,.08334,.7724],945:[0,.43056,.0037,.02778,.6397],946:[.19444,.69444,.05278,.08334,.56563],947:[.19444,.43056,.05556,0,.51773],948:[0,.69444,.03785,.05556,.44444],949:[0,.43056,0,.08334,.46632],950:[.19444,.69444,.07378,.08334,.4375],951:[.19444,.43056,.03588,.05556,.49653],952:[0,.69444,.02778,.08334,.46944],953:[0,.43056,0,.05556,.35394],954:[0,.43056,0,0,.57616],955:[0,.69444,0,0,.58334],956:[.19444,.43056,0,.02778,.60255],957:[0,.43056,.06366,.02778,.49398],958:[.19444,.69444,.04601,.11111,.4375],959:[0,.43056,0,.05556,.48472],960:[0,.43056,.03588,0,.57003],961:[.19444,.43056,0,.08334,.51702],962:[.09722,.43056,.07986,.08334,.36285],963:[0,.43056,.03588,0,.57141],964:[0,.43056,.1132,.02778,.43715],965:[0,.43056,.03588,.02778,.54028],966:[.19444,.43056,0,.08334,.65417],967:[.19444,.43056,0,.05556,.62569],968:[.19444,.69444,.03588,.11111,.65139],969:[0,.43056,.03588,0,.62245],977:[0,.69444,0,.08334,.59144],981:[.19444,.69444,0,.08334,.59583],982:[0,.43056,.02778,0,.82813],1009:[.19444,.43056,0,.08334,.51702],1013:[0,.43056,0,.05556,.4059],57649:[0,.43056,0,.02778,.32246],57911:[.19444,.43056,0,.08334,.38403]},"SansSerif-Bold":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.36667],34:[0,.69444,0,0,.55834],35:[.19444,.69444,0,0,.91667],36:[.05556,.75,0,0,.55],37:[.05556,.75,0,0,1.02912],38:[0,.69444,0,0,.83056],39:[0,.69444,0,0,.30556],40:[.25,.75,0,0,.42778],41:[.25,.75,0,0,.42778],42:[0,.75,0,0,.55],43:[.11667,.61667,0,0,.85556],44:[.10556,.13056,0,0,.30556],45:[0,.45833,0,0,.36667],46:[0,.13056,0,0,.30556],47:[.25,.75,0,0,.55],48:[0,.69444,0,0,.55],49:[0,.69444,0,0,.55],50:[0,.69444,0,0,.55],51:[0,.69444,0,0,.55],52:[0,.69444,0,0,.55],53:[0,.69444,0,0,.55],54:[0,.69444,0,0,.55],55:[0,.69444,0,0,.55],56:[0,.69444,0,0,.55],57:[0,.69444,0,0,.55],58:[0,.45833,0,0,.30556],59:[.10556,.45833,0,0,.30556],61:[-.09375,.40625,0,0,.85556],63:[0,.69444,0,0,.51945],64:[0,.69444,0,0,.73334],65:[0,.69444,0,0,.73334],66:[0,.69444,0,0,.73334],67:[0,.69444,0,0,.70278],68:[0,.69444,0,0,.79445],69:[0,.69444,0,0,.64167],70:[0,.69444,0,0,.61111],71:[0,.69444,0,0,.73334],72:[0,.69444,0,0,.79445],73:[0,.69444,0,0,.33056],74:[0,.69444,0,0,.51945],75:[0,.69444,0,0,.76389],76:[0,.69444,0,0,.58056],77:[0,.69444,0,0,.97778],78:[0,.69444,0,0,.79445],79:[0,.69444,0,0,.79445],80:[0,.69444,0,0,.70278],81:[.10556,.69444,0,0,.79445],82:[0,.69444,0,0,.70278],83:[0,.69444,0,0,.61111],84:[0,.69444,0,0,.73334],85:[0,.69444,0,0,.76389],86:[0,.69444,.01528,0,.73334],87:[0,.69444,.01528,0,1.03889],88:[0,.69444,0,0,.73334],89:[0,.69444,.0275,0,.73334],90:[0,.69444,0,0,.67223],91:[.25,.75,0,0,.34306],93:[.25,.75,0,0,.34306],94:[0,.69444,0,0,.55],95:[.35,.10833,.03056,0,.55],97:[0,.45833,0,0,.525],98:[0,.69444,0,0,.56111],99:[0,.45833,0,0,.48889],100:[0,.69444,0,0,.56111],101:[0,.45833,0,0,.51111],102:[0,.69444,.07639,0,.33611],103:[.19444,.45833,.01528,0,.55],104:[0,.69444,0,0,.56111],105:[0,.69444,0,0,.25556],106:[.19444,.69444,0,0,.28611],107:[0,.69444,0,0,.53056],108:[0,.69444,0,0,.25556],109:[0,.45833,0,0,.86667],110:[0,.45833,0,0,.56111],111:[0,.45833,0,0,.55],112:[.19444,.45833,0,0,.56111],113:[.19444,.45833,0,0,.56111],114:[0,.45833,.01528,0,.37222],115:[0,.45833,0,0,.42167],116:[0,.58929,0,0,.40417],117:[0,.45833,0,0,.56111],118:[0,.45833,.01528,0,.5],119:[0,.45833,.01528,0,.74445],120:[0,.45833,0,0,.5],121:[.19444,.45833,.01528,0,.5],122:[0,.45833,0,0,.47639],126:[.35,.34444,0,0,.55],160:[0,0,0,0,.25],168:[0,.69444,0,0,.55],176:[0,.69444,0,0,.73334],180:[0,.69444,0,0,.55],184:[.17014,0,0,0,.48889],305:[0,.45833,0,0,.25556],567:[.19444,.45833,0,0,.28611],710:[0,.69444,0,0,.55],711:[0,.63542,0,0,.55],713:[0,.63778,0,0,.55],728:[0,.69444,0,0,.55],729:[0,.69444,0,0,.30556],730:[0,.69444,0,0,.73334],732:[0,.69444,0,0,.55],733:[0,.69444,0,0,.55],915:[0,.69444,0,0,.58056],916:[0,.69444,0,0,.91667],920:[0,.69444,0,0,.85556],923:[0,.69444,0,0,.67223],926:[0,.69444,0,0,.73334],928:[0,.69444,0,0,.79445],931:[0,.69444,0,0,.79445],933:[0,.69444,0,0,.85556],934:[0,.69444,0,0,.79445],936:[0,.69444,0,0,.85556],937:[0,.69444,0,0,.79445],8211:[0,.45833,.03056,0,.55],8212:[0,.45833,.03056,0,1.10001],8216:[0,.69444,0,0,.30556],8217:[0,.69444,0,0,.30556],8220:[0,.69444,0,0,.55834],8221:[0,.69444,0,0,.55834]},"SansSerif-Italic":{32:[0,0,0,0,.25],33:[0,.69444,.05733,0,.31945],34:[0,.69444,.00316,0,.5],35:[.19444,.69444,.05087,0,.83334],36:[.05556,.75,.11156,0,.5],37:[.05556,.75,.03126,0,.83334],38:[0,.69444,.03058,0,.75834],39:[0,.69444,.07816,0,.27778],40:[.25,.75,.13164,0,.38889],41:[.25,.75,.02536,0,.38889],42:[0,.75,.11775,0,.5],43:[.08333,.58333,.02536,0,.77778],44:[.125,.08333,0,0,.27778],45:[0,.44444,.01946,0,.33333],46:[0,.08333,0,0,.27778],47:[.25,.75,.13164,0,.5],48:[0,.65556,.11156,0,.5],49:[0,.65556,.11156,0,.5],50:[0,.65556,.11156,0,.5],51:[0,.65556,.11156,0,.5],52:[0,.65556,.11156,0,.5],53:[0,.65556,.11156,0,.5],54:[0,.65556,.11156,0,.5],55:[0,.65556,.11156,0,.5],56:[0,.65556,.11156,0,.5],57:[0,.65556,.11156,0,.5],58:[0,.44444,.02502,0,.27778],59:[.125,.44444,.02502,0,.27778],61:[-.13,.37,.05087,0,.77778],63:[0,.69444,.11809,0,.47222],64:[0,.69444,.07555,0,.66667],65:[0,.69444,0,0,.66667],66:[0,.69444,.08293,0,.66667],67:[0,.69444,.11983,0,.63889],68:[0,.69444,.07555,0,.72223],69:[0,.69444,.11983,0,.59722],70:[0,.69444,.13372,0,.56945],71:[0,.69444,.11983,0,.66667],72:[0,.69444,.08094,0,.70834],73:[0,.69444,.13372,0,.27778],74:[0,.69444,.08094,0,.47222],75:[0,.69444,.11983,0,.69445],76:[0,.69444,0,0,.54167],77:[0,.69444,.08094,0,.875],78:[0,.69444,.08094,0,.70834],79:[0,.69444,.07555,0,.73611],80:[0,.69444,.08293,0,.63889],81:[.125,.69444,.07555,0,.73611],82:[0,.69444,.08293,0,.64584],83:[0,.69444,.09205,0,.55556],84:[0,.69444,.13372,0,.68056],85:[0,.69444,.08094,0,.6875],86:[0,.69444,.1615,0,.66667],87:[0,.69444,.1615,0,.94445],88:[0,.69444,.13372,0,.66667],89:[0,.69444,.17261,0,.66667],90:[0,.69444,.11983,0,.61111],91:[.25,.75,.15942,0,.28889],93:[.25,.75,.08719,0,.28889],94:[0,.69444,.0799,0,.5],95:[.35,.09444,.08616,0,.5],97:[0,.44444,.00981,0,.48056],98:[0,.69444,.03057,0,.51667],99:[0,.44444,.08336,0,.44445],100:[0,.69444,.09483,0,.51667],101:[0,.44444,.06778,0,.44445],102:[0,.69444,.21705,0,.30556],103:[.19444,.44444,.10836,0,.5],104:[0,.69444,.01778,0,.51667],105:[0,.67937,.09718,0,.23889],106:[.19444,.67937,.09162,0,.26667],107:[0,.69444,.08336,0,.48889],108:[0,.69444,.09483,0,.23889],109:[0,.44444,.01778,0,.79445],110:[0,.44444,.01778,0,.51667],111:[0,.44444,.06613,0,.5],112:[.19444,.44444,.0389,0,.51667],113:[.19444,.44444,.04169,0,.51667],114:[0,.44444,.10836,0,.34167],115:[0,.44444,.0778,0,.38333],116:[0,.57143,.07225,0,.36111],117:[0,.44444,.04169,0,.51667],118:[0,.44444,.10836,0,.46111],119:[0,.44444,.10836,0,.68334],120:[0,.44444,.09169,0,.46111],121:[.19444,.44444,.10836,0,.46111],122:[0,.44444,.08752,0,.43472],126:[.35,.32659,.08826,0,.5],160:[0,0,0,0,.25],168:[0,.67937,.06385,0,.5],176:[0,.69444,0,0,.73752],184:[.17014,0,0,0,.44445],305:[0,.44444,.04169,0,.23889],567:[.19444,.44444,.04169,0,.26667],710:[0,.69444,.0799,0,.5],711:[0,.63194,.08432,0,.5],713:[0,.60889,.08776,0,.5],714:[0,.69444,.09205,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,.09483,0,.5],729:[0,.67937,.07774,0,.27778],730:[0,.69444,0,0,.73752],732:[0,.67659,.08826,0,.5],733:[0,.69444,.09205,0,.5],915:[0,.69444,.13372,0,.54167],916:[0,.69444,0,0,.83334],920:[0,.69444,.07555,0,.77778],923:[0,.69444,0,0,.61111],926:[0,.69444,.12816,0,.66667],928:[0,.69444,.08094,0,.70834],931:[0,.69444,.11983,0,.72222],933:[0,.69444,.09031,0,.77778],934:[0,.69444,.04603,0,.72222],936:[0,.69444,.09031,0,.77778],937:[0,.69444,.08293,0,.72222],8211:[0,.44444,.08616,0,.5],8212:[0,.44444,.08616,0,1],8216:[0,.69444,.07816,0,.27778],8217:[0,.69444,.07816,0,.27778],8220:[0,.69444,.14205,0,.5],8221:[0,.69444,.00316,0,.5]},"SansSerif-Regular":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.31945],34:[0,.69444,0,0,.5],35:[.19444,.69444,0,0,.83334],36:[.05556,.75,0,0,.5],37:[.05556,.75,0,0,.83334],38:[0,.69444,0,0,.75834],39:[0,.69444,0,0,.27778],40:[.25,.75,0,0,.38889],41:[.25,.75,0,0,.38889],42:[0,.75,0,0,.5],43:[.08333,.58333,0,0,.77778],44:[.125,.08333,0,0,.27778],45:[0,.44444,0,0,.33333],46:[0,.08333,0,0,.27778],47:[.25,.75,0,0,.5],48:[0,.65556,0,0,.5],49:[0,.65556,0,0,.5],50:[0,.65556,0,0,.5],51:[0,.65556,0,0,.5],52:[0,.65556,0,0,.5],53:[0,.65556,0,0,.5],54:[0,.65556,0,0,.5],55:[0,.65556,0,0,.5],56:[0,.65556,0,0,.5],57:[0,.65556,0,0,.5],58:[0,.44444,0,0,.27778],59:[.125,.44444,0,0,.27778],61:[-.13,.37,0,0,.77778],63:[0,.69444,0,0,.47222],64:[0,.69444,0,0,.66667],65:[0,.69444,0,0,.66667],66:[0,.69444,0,0,.66667],67:[0,.69444,0,0,.63889],68:[0,.69444,0,0,.72223],69:[0,.69444,0,0,.59722],70:[0,.69444,0,0,.56945],71:[0,.69444,0,0,.66667],72:[0,.69444,0,0,.70834],73:[0,.69444,0,0,.27778],74:[0,.69444,0,0,.47222],75:[0,.69444,0,0,.69445],76:[0,.69444,0,0,.54167],77:[0,.69444,0,0,.875],78:[0,.69444,0,0,.70834],79:[0,.69444,0,0,.73611],80:[0,.69444,0,0,.63889],81:[.125,.69444,0,0,.73611],82:[0,.69444,0,0,.64584],83:[0,.69444,0,0,.55556],84:[0,.69444,0,0,.68056],85:[0,.69444,0,0,.6875],86:[0,.69444,.01389,0,.66667],87:[0,.69444,.01389,0,.94445],88:[0,.69444,0,0,.66667],89:[0,.69444,.025,0,.66667],90:[0,.69444,0,0,.61111],91:[.25,.75,0,0,.28889],93:[.25,.75,0,0,.28889],94:[0,.69444,0,0,.5],95:[.35,.09444,.02778,0,.5],97:[0,.44444,0,0,.48056],98:[0,.69444,0,0,.51667],99:[0,.44444,0,0,.44445],100:[0,.69444,0,0,.51667],101:[0,.44444,0,0,.44445],102:[0,.69444,.06944,0,.30556],103:[.19444,.44444,.01389,0,.5],104:[0,.69444,0,0,.51667],105:[0,.67937,0,0,.23889],106:[.19444,.67937,0,0,.26667],107:[0,.69444,0,0,.48889],108:[0,.69444,0,0,.23889],109:[0,.44444,0,0,.79445],110:[0,.44444,0,0,.51667],111:[0,.44444,0,0,.5],112:[.19444,.44444,0,0,.51667],113:[.19444,.44444,0,0,.51667],114:[0,.44444,.01389,0,.34167],115:[0,.44444,0,0,.38333],116:[0,.57143,0,0,.36111],117:[0,.44444,0,0,.51667],118:[0,.44444,.01389,0,.46111],119:[0,.44444,.01389,0,.68334],120:[0,.44444,0,0,.46111],121:[.19444,.44444,.01389,0,.46111],122:[0,.44444,0,0,.43472],126:[.35,.32659,0,0,.5],160:[0,0,0,0,.25],168:[0,.67937,0,0,.5],176:[0,.69444,0,0,.66667],184:[.17014,0,0,0,.44445],305:[0,.44444,0,0,.23889],567:[.19444,.44444,0,0,.26667],710:[0,.69444,0,0,.5],711:[0,.63194,0,0,.5],713:[0,.60889,0,0,.5],714:[0,.69444,0,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,0,0,.5],729:[0,.67937,0,0,.27778],730:[0,.69444,0,0,.66667],732:[0,.67659,0,0,.5],733:[0,.69444,0,0,.5],915:[0,.69444,0,0,.54167],916:[0,.69444,0,0,.83334],920:[0,.69444,0,0,.77778],923:[0,.69444,0,0,.61111],926:[0,.69444,0,0,.66667],928:[0,.69444,0,0,.70834],931:[0,.69444,0,0,.72222],933:[0,.69444,0,0,.77778],934:[0,.69444,0,0,.72222],936:[0,.69444,0,0,.77778],937:[0,.69444,0,0,.72222],8211:[0,.44444,.02778,0,.5],8212:[0,.44444,.02778,0,1],8216:[0,.69444,0,0,.27778],8217:[0,.69444,0,0,.27778],8220:[0,.69444,0,0,.5],8221:[0,.69444,0,0,.5]},"Script-Regular":{32:[0,0,0,0,.25],65:[0,.7,.22925,0,.80253],66:[0,.7,.04087,0,.90757],67:[0,.7,.1689,0,.66619],68:[0,.7,.09371,0,.77443],69:[0,.7,.18583,0,.56162],70:[0,.7,.13634,0,.89544],71:[0,.7,.17322,0,.60961],72:[0,.7,.29694,0,.96919],73:[0,.7,.19189,0,.80907],74:[.27778,.7,.19189,0,1.05159],75:[0,.7,.31259,0,.91364],76:[0,.7,.19189,0,.87373],77:[0,.7,.15981,0,1.08031],78:[0,.7,.3525,0,.9015],79:[0,.7,.08078,0,.73787],80:[0,.7,.08078,0,1.01262],81:[0,.7,.03305,0,.88282],82:[0,.7,.06259,0,.85],83:[0,.7,.19189,0,.86767],84:[0,.7,.29087,0,.74697],85:[0,.7,.25815,0,.79996],86:[0,.7,.27523,0,.62204],87:[0,.7,.27523,0,.80532],88:[0,.7,.26006,0,.94445],89:[0,.7,.2939,0,.70961],90:[0,.7,.24037,0,.8212],160:[0,0,0,0,.25]},"Size1-Regular":{32:[0,0,0,0,.25],40:[.35001,.85,0,0,.45834],41:[.35001,.85,0,0,.45834],47:[.35001,.85,0,0,.57778],91:[.35001,.85,0,0,.41667],92:[.35001,.85,0,0,.57778],93:[.35001,.85,0,0,.41667],123:[.35001,.85,0,0,.58334],125:[.35001,.85,0,0,.58334],160:[0,0,0,0,.25],710:[0,.72222,0,0,.55556],732:[0,.72222,0,0,.55556],770:[0,.72222,0,0,.55556],771:[0,.72222,0,0,.55556],8214:[-99e-5,.601,0,0,.77778],8593:[1e-5,.6,0,0,.66667],8595:[1e-5,.6,0,0,.66667],8657:[1e-5,.6,0,0,.77778],8659:[1e-5,.6,0,0,.77778],8719:[.25001,.75,0,0,.94445],8720:[.25001,.75,0,0,.94445],8721:[.25001,.75,0,0,1.05556],8730:[.35001,.85,0,0,1],8739:[-.00599,.606,0,0,.33333],8741:[-.00599,.606,0,0,.55556],8747:[.30612,.805,.19445,0,.47222],8748:[.306,.805,.19445,0,.47222],8749:[.306,.805,.19445,0,.47222],8750:[.30612,.805,.19445,0,.47222],8896:[.25001,.75,0,0,.83334],8897:[.25001,.75,0,0,.83334],8898:[.25001,.75,0,0,.83334],8899:[.25001,.75,0,0,.83334],8968:[.35001,.85,0,0,.47222],8969:[.35001,.85,0,0,.47222],8970:[.35001,.85,0,0,.47222],8971:[.35001,.85,0,0,.47222],9168:[-99e-5,.601,0,0,.66667],10216:[.35001,.85,0,0,.47222],10217:[.35001,.85,0,0,.47222],10752:[.25001,.75,0,0,1.11111],10753:[.25001,.75,0,0,1.11111],10754:[.25001,.75,0,0,1.11111],10756:[.25001,.75,0,0,.83334],10758:[.25001,.75,0,0,.83334]},"Size2-Regular":{32:[0,0,0,0,.25],40:[.65002,1.15,0,0,.59722],41:[.65002,1.15,0,0,.59722],47:[.65002,1.15,0,0,.81111],91:[.65002,1.15,0,0,.47222],92:[.65002,1.15,0,0,.81111],93:[.65002,1.15,0,0,.47222],123:[.65002,1.15,0,0,.66667],125:[.65002,1.15,0,0,.66667],160:[0,0,0,0,.25],710:[0,.75,0,0,1],732:[0,.75,0,0,1],770:[0,.75,0,0,1],771:[0,.75,0,0,1],8719:[.55001,1.05,0,0,1.27778],8720:[.55001,1.05,0,0,1.27778],8721:[.55001,1.05,0,0,1.44445],8730:[.65002,1.15,0,0,1],8747:[.86225,1.36,.44445,0,.55556],8748:[.862,1.36,.44445,0,.55556],8749:[.862,1.36,.44445,0,.55556],8750:[.86225,1.36,.44445,0,.55556],8896:[.55001,1.05,0,0,1.11111],8897:[.55001,1.05,0,0,1.11111],8898:[.55001,1.05,0,0,1.11111],8899:[.55001,1.05,0,0,1.11111],8968:[.65002,1.15,0,0,.52778],8969:[.65002,1.15,0,0,.52778],8970:[.65002,1.15,0,0,.52778],8971:[.65002,1.15,0,0,.52778],10216:[.65002,1.15,0,0,.61111],10217:[.65002,1.15,0,0,.61111],10752:[.55001,1.05,0,0,1.51112],10753:[.55001,1.05,0,0,1.51112],10754:[.55001,1.05,0,0,1.51112],10756:[.55001,1.05,0,0,1.11111],10758:[.55001,1.05,0,0,1.11111]},"Size3-Regular":{32:[0,0,0,0,.25],40:[.95003,1.45,0,0,.73611],41:[.95003,1.45,0,0,.73611],47:[.95003,1.45,0,0,1.04445],91:[.95003,1.45,0,0,.52778],92:[.95003,1.45,0,0,1.04445],93:[.95003,1.45,0,0,.52778],123:[.95003,1.45,0,0,.75],125:[.95003,1.45,0,0,.75],160:[0,0,0,0,.25],710:[0,.75,0,0,1.44445],732:[0,.75,0,0,1.44445],770:[0,.75,0,0,1.44445],771:[0,.75,0,0,1.44445],8730:[.95003,1.45,0,0,1],8968:[.95003,1.45,0,0,.58334],8969:[.95003,1.45,0,0,.58334],8970:[.95003,1.45,0,0,.58334],8971:[.95003,1.45,0,0,.58334],10216:[.95003,1.45,0,0,.75],10217:[.95003,1.45,0,0,.75]},"Size4-Regular":{32:[0,0,0,0,.25],40:[1.25003,1.75,0,0,.79167],41:[1.25003,1.75,0,0,.79167],47:[1.25003,1.75,0,0,1.27778],91:[1.25003,1.75,0,0,.58334],92:[1.25003,1.75,0,0,1.27778],93:[1.25003,1.75,0,0,.58334],123:[1.25003,1.75,0,0,.80556],125:[1.25003,1.75,0,0,.80556],160:[0,0,0,0,.25],710:[0,.825,0,0,1.8889],732:[0,.825,0,0,1.8889],770:[0,.825,0,0,1.8889],771:[0,.825,0,0,1.8889],8730:[1.25003,1.75,0,0,1],8968:[1.25003,1.75,0,0,.63889],8969:[1.25003,1.75,0,0,.63889],8970:[1.25003,1.75,0,0,.63889],8971:[1.25003,1.75,0,0,.63889],9115:[.64502,1.155,0,0,.875],9116:[1e-5,.6,0,0,.875],9117:[.64502,1.155,0,0,.875],9118:[.64502,1.155,0,0,.875],9119:[1e-5,.6,0,0,.875],9120:[.64502,1.155,0,0,.875],9121:[.64502,1.155,0,0,.66667],9122:[-99e-5,.601,0,0,.66667],9123:[.64502,1.155,0,0,.66667],9124:[.64502,1.155,0,0,.66667],9125:[-99e-5,.601,0,0,.66667],9126:[.64502,1.155,0,0,.66667],9127:[1e-5,.9,0,0,.88889],9128:[.65002,1.15,0,0,.88889],9129:[.90001,0,0,0,.88889],9130:[0,.3,0,0,.88889],9131:[1e-5,.9,0,0,.88889],9132:[.65002,1.15,0,0,.88889],9133:[.90001,0,0,0,.88889],9143:[.88502,.915,0,0,1.05556],10216:[1.25003,1.75,0,0,.80556],10217:[1.25003,1.75,0,0,.80556],57344:[-.00499,.605,0,0,1.05556],57345:[-.00499,.605,0,0,1.05556],57680:[0,.12,0,0,.45],57681:[0,.12,0,0,.45],57682:[0,.12,0,0,.45],57683:[0,.12,0,0,.45]},"Typewriter-Regular":{32:[0,0,0,0,.525],33:[0,.61111,0,0,.525],34:[0,.61111,0,0,.525],35:[0,.61111,0,0,.525],36:[.08333,.69444,0,0,.525],37:[.08333,.69444,0,0,.525],38:[0,.61111,0,0,.525],39:[0,.61111,0,0,.525],40:[.08333,.69444,0,0,.525],41:[.08333,.69444,0,0,.525],42:[0,.52083,0,0,.525],43:[-.08056,.53055,0,0,.525],44:[.13889,.125,0,0,.525],45:[-.08056,.53055,0,0,.525],46:[0,.125,0,0,.525],47:[.08333,.69444,0,0,.525],48:[0,.61111,0,0,.525],49:[0,.61111,0,0,.525],50:[0,.61111,0,0,.525],51:[0,.61111,0,0,.525],52:[0,.61111,0,0,.525],53:[0,.61111,0,0,.525],54:[0,.61111,0,0,.525],55:[0,.61111,0,0,.525],56:[0,.61111,0,0,.525],57:[0,.61111,0,0,.525],58:[0,.43056,0,0,.525],59:[.13889,.43056,0,0,.525],60:[-.05556,.55556,0,0,.525],61:[-.19549,.41562,0,0,.525],62:[-.05556,.55556,0,0,.525],63:[0,.61111,0,0,.525],64:[0,.61111,0,0,.525],65:[0,.61111,0,0,.525],66:[0,.61111,0,0,.525],67:[0,.61111,0,0,.525],68:[0,.61111,0,0,.525],69:[0,.61111,0,0,.525],70:[0,.61111,0,0,.525],71:[0,.61111,0,0,.525],72:[0,.61111,0,0,.525],73:[0,.61111,0,0,.525],74:[0,.61111,0,0,.525],75:[0,.61111,0,0,.525],76:[0,.61111,0,0,.525],77:[0,.61111,0,0,.525],78:[0,.61111,0,0,.525],79:[0,.61111,0,0,.525],80:[0,.61111,0,0,.525],81:[.13889,.61111,0,0,.525],82:[0,.61111,0,0,.525],83:[0,.61111,0,0,.525],84:[0,.61111,0,0,.525],85:[0,.61111,0,0,.525],86:[0,.61111,0,0,.525],87:[0,.61111,0,0,.525],88:[0,.61111,0,0,.525],89:[0,.61111,0,0,.525],90:[0,.61111,0,0,.525],91:[.08333,.69444,0,0,.525],92:[.08333,.69444,0,0,.525],93:[.08333,.69444,0,0,.525],94:[0,.61111,0,0,.525],95:[.09514,0,0,0,.525],96:[0,.61111,0,0,.525],97:[0,.43056,0,0,.525],98:[0,.61111,0,0,.525],99:[0,.43056,0,0,.525],100:[0,.61111,0,0,.525],101:[0,.43056,0,0,.525],102:[0,.61111,0,0,.525],103:[.22222,.43056,0,0,.525],104:[0,.61111,0,0,.525],105:[0,.61111,0,0,.525],106:[.22222,.61111,0,0,.525],107:[0,.61111,0,0,.525],108:[0,.61111,0,0,.525],109:[0,.43056,0,0,.525],110:[0,.43056,0,0,.525],111:[0,.43056,0,0,.525],112:[.22222,.43056,0,0,.525],113:[.22222,.43056,0,0,.525],114:[0,.43056,0,0,.525],115:[0,.43056,0,0,.525],116:[0,.55358,0,0,.525],117:[0,.43056,0,0,.525],118:[0,.43056,0,0,.525],119:[0,.43056,0,0,.525],120:[0,.43056,0,0,.525],121:[.22222,.43056,0,0,.525],122:[0,.43056,0,0,.525],123:[.08333,.69444,0,0,.525],124:[.08333,.69444,0,0,.525],125:[.08333,.69444,0,0,.525],126:[0,.61111,0,0,.525],127:[0,.61111,0,0,.525],160:[0,0,0,0,.525],176:[0,.61111,0,0,.525],184:[.19445,0,0,0,.525],305:[0,.43056,0,0,.525],567:[.22222,.43056,0,0,.525],711:[0,.56597,0,0,.525],713:[0,.56555,0,0,.525],714:[0,.61111,0,0,.525],715:[0,.61111,0,0,.525],728:[0,.61111,0,0,.525],730:[0,.61111,0,0,.525],770:[0,.61111,0,0,.525],771:[0,.61111,0,0,.525],776:[0,.61111,0,0,.525],915:[0,.61111,0,0,.525],916:[0,.61111,0,0,.525],920:[0,.61111,0,0,.525],923:[0,.61111,0,0,.525],926:[0,.61111,0,0,.525],928:[0,.61111,0,0,.525],931:[0,.61111,0,0,.525],933:[0,.61111,0,0,.525],934:[0,.61111,0,0,.525],936:[0,.61111,0,0,.525],937:[0,.61111,0,0,.525],8216:[0,.61111,0,0,.525],8217:[0,.61111,0,0,.525],8242:[0,.61111,0,0,.525],9251:[.11111,.21944,0,0,.525]}},la={slant:[.25,.25,.25],space:[0,0,0],stretch:[0,0,0],shrink:[0,0,0],xHeight:[.431,.431,.431],quad:[1,1.171,1.472],extraSpace:[0,0,0],num1:[.677,.732,.925],num2:[.394,.384,.387],num3:[.444,.471,.504],denom1:[.686,.752,1.025],denom2:[.345,.344,.532],sup1:[.413,.503,.504],sup2:[.363,.431,.404],sup3:[.289,.286,.294],sub1:[.15,.143,.2],sub2:[.247,.286,.4],supDrop:[.386,.353,.494],subDrop:[.05,.071,.1],delim1:[2.39,1.7,1.98],delim2:[1.01,1.157,1.42],axisHeight:[.25,.25,.25],defaultRuleThickness:[.04,.049,.049],bigOpSpacing1:[.111,.111,.111],bigOpSpacing2:[.166,.166,.166],bigOpSpacing3:[.2,.2,.2],bigOpSpacing4:[.6,.611,.611],bigOpSpacing5:[.1,.143,.143],sqrtRuleThickness:[.04,.04,.04],ptPerEm:[10,10,10],doubleRuleSep:[.2,.2,.2],arrayRuleWidth:[.04,.04,.04],fboxsep:[.3,.3,.3],fboxrule:[.04,.04,.04]},Nh={Å:"A",Ð:"D",Þ:"o",å:"a",ð:"d",þ:"o",А:"A",Б:"B",В:"B",Г:"F",Д:"A",Е:"E",Ж:"K",З:"3",И:"N",Й:"N",К:"K",Л:"N",М:"M",Н:"H",О:"O",П:"N",Р:"P",С:"C",Т:"T",У:"y",Ф:"O",Х:"X",Ц:"U",Ч:"h",Ш:"W",Щ:"W",Ъ:"B",Ы:"X",Ь:"B",Э:"3",Ю:"X",Я:"R",а:"a",б:"b",в:"a",г:"r",д:"y",е:"e",ж:"m",з:"e",и:"n",й:"n",к:"n",л:"n",м:"m",н:"n",о:"o",п:"n",р:"p",с:"c",т:"o",у:"y",ф:"b",х:"x",ц:"n",ч:"n",ш:"w",щ:"w",ъ:"a",ы:"m",ь:"a",э:"e",ю:"m",я:"r"};function cS(e,A){un[e]=A}function Rc(e,A,t){if(!un[A])throw new Error("Font metrics not found for font: "+A+".");var r=e.charCodeAt(0),n=un[A][r];if(!n&&e[0]in Nh&&(r=Nh[e[0]].charCodeAt(0),n=un[A][r]),!n&&t==="text"&&gp(r)&&(n=un[A][77]),n)return{depth:n[0],height:n[1],italic:n[2],skew:n[3],width:n[4]}}var kC={};function uS(e){var A;if(e>=5?A=0:e>=3?A=1:A=2,!kC[A]){var t=kC[A]={cssEmPerMu:la.quad[A]/18};for(var r in la)la.hasOwnProperty(r)&&(t[r]=la[r][A])}return kC[A]}var dS=[[1,1,1],[2,1,1],[3,1,1],[4,2,1],[5,2,1],[6,3,1],[7,4,2],[8,6,3],[9,7,6],[10,8,7],[11,10,9]],vh=[.5,.6,.7,.8,.9,1,1.2,1.44,1.728,2.074,2.488],bh=function(A,t){return t.size<2?A:dS[A-1][t.size-1]};class Tn{constructor(A){this.style=void 0,this.color=void 0,this.size=void 0,this.textSize=void 0,this.phantom=void 0,this.font=void 0,this.fontFamily=void 0,this.fontWeight=void 0,this.fontShape=void 0,this.sizeMultiplier=void 0,this.maxSize=void 0,this.minRuleThickness=void 0,this._fontMetrics=void 0,this.style=A.style,this.color=A.color,this.size=A.size||Tn.BASESIZE,this.textSize=A.textSize||this.size,this.phantom=!!A.phantom,this.font=A.font||"",this.fontFamily=A.fontFamily||"",this.fontWeight=A.fontWeight||"",this.fontShape=A.fontShape||"",this.sizeMultiplier=vh[this.size-1],this.maxSize=A.maxSize,this.minRuleThickness=A.minRuleThickness,this._fontMetrics=void 0}extend(A){var t={style:this.style,size:this.size,textSize:this.textSize,color:this.color,phantom:this.phantom,font:this.font,fontFamily:this.fontFamily,fontWeight:this.fontWeight,fontShape:this.fontShape,maxSize:this.maxSize,minRuleThickness:this.minRuleThickness};for(var r in A)A.hasOwnProperty(r)&&(t[r]=A[r]);return new Tn(t)}havingStyle(A){return this.style===A?this:this.extend({style:A,size:bh(this.textSize,A)})}havingCrampedStyle(){return this.havingStyle(this.style.cramp())}havingSize(A){return this.size===A&&this.textSize===A?this:this.extend({style:this.style.text(),size:A,textSize:A,sizeMultiplier:vh[A-1]})}havingBaseStyle(A){A=A||this.style.text();var t=bh(Tn.BASESIZE,A);return this.size===t&&this.textSize===Tn.BASESIZE&&this.style===A?this:this.extend({style:A,size:t})}havingBaseSizing(){var A;switch(this.style.id){case 4:case 5:A=3;break;case 6:case 7:A=1;break;default:A=6}return this.extend({style:this.style.text(),size:A})}withColor(A){return this.extend({color:A})}withPhantom(){return this.extend({phantom:!0})}withFont(A){return this.extend({font:A})}withTextFontFamily(A){return this.extend({fontFamily:A,font:""})}withTextFontWeight(A){return this.extend({fontWeight:A,font:""})}withTextFontShape(A){return this.extend({fontShape:A,font:""})}sizingClasses(A){return A.size!==this.size?["sizing","reset-size"+A.size,"size"+this.size]:[]}baseSizingClasses(){return this.size!==Tn.BASESIZE?["sizing","reset-size"+this.size,"size"+Tn.BASESIZE]:[]}fontMetrics(){return this._fontMetrics||(this._fontMetrics=uS(this.size)),this._fontMetrics}getColor(){return this.phantom?"transparent":this.color}}Tn.BASESIZE=6;var WI={pt:1,mm:7227/2540,cm:7227/254,in:72.27,bp:803/800,pc:12,dd:1238/1157,cc:14856/1157,nd:685/642,nc:1370/107,sp:1/65536,px:803/800},hS={ex:!0,em:!0,mu:!0},Qp=function(A){return typeof A!="string"&&(A=A.unit),A in WI||A in hS||A==="ex"},gt=function(A,t){var r;if(A.unit in WI)r=WI[A.unit]/t.fontMetrics().ptPerEm/t.sizeMultiplier;else if(A.unit==="mu")r=t.fontMetrics().cssEmPerMu;else{var n;if(t.style.isTight()?n=t.havingStyle(t.style.text()):n=t,A.unit==="ex")r=n.fontMetrics().xHeight;else if(A.unit==="em")r=n.fontMetrics().quad;else throw new NA("Invalid unit: '"+A.unit+"'");n!==t&&(r*=n.sizeMultiplier/t.sizeMultiplier)}return Math.min(A.number*r,t.maxSize)},UA=function(A){return+A.toFixed(4)+"em"},Ri=function(A){return A.filter(t=>t).join(" ")},Bp=function(A,t,r){if(this.classes=A||[],this.attributes={},this.height=0,this.depth=0,this.maxFontSize=0,this.style=r||{},t){t.style.isTight()&&this.classes.push("mtight");var n=t.getColor();n&&(this.style.color=n)}},ap=function(A){var t=document.createElement(A);t.className=Ri(this.classes);for(var r in this.style)this.style.hasOwnProperty(r)&&(t.style[r]=this.style[r]);for(var n in this.attributes)this.attributes.hasOwnProperty(n)&&t.setAttribute(n,this.attributes[n]);for(var i=0;i/=\x00-\x1f]/,sp=function(A){var t="<"+A;this.classes.length&&(t+=' class="'+Le.escape(Ri(this.classes))+'"');var r="";for(var n in this.style)this.style.hasOwnProperty(n)&&(r+=Le.hyphenate(n)+":"+this.style[n]+";");r&&(t+=' style="'+Le.escape(r)+'"');for(var i in this.attributes)if(this.attributes.hasOwnProperty(i)){if(DS.test(i))throw new NA("Invalid attribute name '"+i+"'");t+=" "+i+'="'+Le.escape(this.attributes[i])+'"'}t+=">";for(var o=0;o",t};class MB{constructor(A,t,r,n){this.children=void 0,this.attributes=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.width=void 0,this.maxFontSize=void 0,this.style=void 0,Bp.call(this,A,r,n),this.children=t||[]}setAttribute(A,t){this.attributes[A]=t}hasClass(A){return this.classes.includes(A)}toNode(){return ap.call(this,"span")}toMarkup(){return sp.call(this,"span")}}class Oc{constructor(A,t,r,n){this.children=void 0,this.attributes=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,Bp.call(this,t,n),this.children=r||[],this.setAttribute("href",A)}setAttribute(A,t){this.attributes[A]=t}hasClass(A){return this.classes.includes(A)}toNode(){return ap.call(this,"a")}toMarkup(){return sp.call(this,"a")}}class fS{constructor(A,t,r){this.src=void 0,this.alt=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,this.alt=t,this.src=A,this.classes=["mord"],this.style=r}hasClass(A){return this.classes.includes(A)}toNode(){var A=document.createElement("img");A.src=this.src,A.alt=this.alt,A.className="mord";for(var t in this.style)this.style.hasOwnProperty(t)&&(A.style[t]=this.style[t]);return A}toMarkup(){var A=''+Le.escape(this.alt)+'0&&(t=document.createElement("span"),t.style.marginRight=UA(this.italic)),this.classes.length>0&&(t=t||document.createElement("span"),t.className=Ri(this.classes));for(var r in this.style)this.style.hasOwnProperty(r)&&(t=t||document.createElement("span"),t.style[r]=this.style[r]);return t?(t.appendChild(A),t):A}toMarkup(){var A=!1,t="0&&(r+="margin-right:"+this.italic+"em;");for(var n in this.style)this.style.hasOwnProperty(n)&&(r+=Le.hyphenate(n)+":"+this.style[n]+";");r&&(A=!0,t+=' style="'+Le.escape(r)+'"');var i=Le.escape(this.text);return A?(t+=">",t+=i,t+="",t):i}}class ei{constructor(A,t){this.children=void 0,this.attributes=void 0,this.children=A||[],this.attributes=t||{}}toNode(){var A="http://www.w3.org/2000/svg",t=document.createElementNS(A,"svg");for(var r in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,r)&&t.setAttribute(r,this.attributes[r]);for(var n=0;n':''}}class ZI{constructor(A){this.attributes=void 0,this.attributes=A||{}}toNode(){var A="http://www.w3.org/2000/svg",t=document.createElementNS(A,"line");for(var r in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,r)&&t.setAttribute(r,this.attributes[r]);return t}toMarkup(){var A=" but got "+String(e)+".")}var pS={bin:1,close:1,inner:1,open:1,punct:1,rel:1},kS={"accent-token":1,mathord:1,"op-token":1,spacing:1,textord:1},Ze={math:{},text:{}};function D(e,A,t,r,n,i){Ze[e][n]={font:A,group:t,replace:r},i&&r&&(Ze[e][r]=Ze[e][n])}var w="math",DA="text",y="main",G="ams",nt="accent-token",ZA="bin",gr="close",zg="inner",ie="mathord",mt="op-token",pr="open",QE="punct",U="rel",Qi="spacing",T="textord";D(w,y,U,"≡","\\equiv",!0);D(w,y,U,"≺","\\prec",!0);D(w,y,U,"≻","\\succ",!0);D(w,y,U,"∼","\\sim",!0);D(w,y,U,"⊥","\\perp");D(w,y,U,"⪯","\\preceq",!0);D(w,y,U,"⪰","\\succeq",!0);D(w,y,U,"≃","\\simeq",!0);D(w,y,U,"∣","\\mid",!0);D(w,y,U,"≪","\\ll",!0);D(w,y,U,"≫","\\gg",!0);D(w,y,U,"≍","\\asymp",!0);D(w,y,U,"∥","\\parallel");D(w,y,U,"⋈","\\bowtie",!0);D(w,y,U,"⌣","\\smile",!0);D(w,y,U,"⊑","\\sqsubseteq",!0);D(w,y,U,"⊒","\\sqsupseteq",!0);D(w,y,U,"≐","\\doteq",!0);D(w,y,U,"⌢","\\frown",!0);D(w,y,U,"∋","\\ni",!0);D(w,y,U,"∝","\\propto",!0);D(w,y,U,"⊢","\\vdash",!0);D(w,y,U,"⊣","\\dashv",!0);D(w,y,U,"∋","\\owns");D(w,y,QE,".","\\ldotp");D(w,y,QE,"⋅","\\cdotp");D(w,y,T,"#","\\#");D(DA,y,T,"#","\\#");D(w,y,T,"&","\\&");D(DA,y,T,"&","\\&");D(w,y,T,"ℵ","\\aleph",!0);D(w,y,T,"∀","\\forall",!0);D(w,y,T,"ℏ","\\hbar",!0);D(w,y,T,"∃","\\exists",!0);D(w,y,T,"∇","\\nabla",!0);D(w,y,T,"♭","\\flat",!0);D(w,y,T,"ℓ","\\ell",!0);D(w,y,T,"♮","\\natural",!0);D(w,y,T,"♣","\\clubsuit",!0);D(w,y,T,"℘","\\wp",!0);D(w,y,T,"♯","\\sharp",!0);D(w,y,T,"♢","\\diamondsuit",!0);D(w,y,T,"ℜ","\\Re",!0);D(w,y,T,"♡","\\heartsuit",!0);D(w,y,T,"ℑ","\\Im",!0);D(w,y,T,"♠","\\spadesuit",!0);D(w,y,T,"§","\\S",!0);D(DA,y,T,"§","\\S");D(w,y,T,"¶","\\P",!0);D(DA,y,T,"¶","\\P");D(w,y,T,"†","\\dag");D(DA,y,T,"†","\\dag");D(DA,y,T,"†","\\textdagger");D(w,y,T,"‡","\\ddag");D(DA,y,T,"‡","\\ddag");D(DA,y,T,"‡","\\textdaggerdbl");D(w,y,gr,"⎱","\\rmoustache",!0);D(w,y,pr,"⎰","\\lmoustache",!0);D(w,y,gr,"⟯","\\rgroup",!0);D(w,y,pr,"⟮","\\lgroup",!0);D(w,y,ZA,"∓","\\mp",!0);D(w,y,ZA,"⊖","\\ominus",!0);D(w,y,ZA,"⊎","\\uplus",!0);D(w,y,ZA,"⊓","\\sqcap",!0);D(w,y,ZA,"∗","\\ast");D(w,y,ZA,"⊔","\\sqcup",!0);D(w,y,ZA,"◯","\\bigcirc",!0);D(w,y,ZA,"∙","\\bullet",!0);D(w,y,ZA,"‡","\\ddagger");D(w,y,ZA,"≀","\\wr",!0);D(w,y,ZA,"⨿","\\amalg");D(w,y,ZA,"&","\\And");D(w,y,U,"⟵","\\longleftarrow",!0);D(w,y,U,"⇐","\\Leftarrow",!0);D(w,y,U,"⟸","\\Longleftarrow",!0);D(w,y,U,"⟶","\\longrightarrow",!0);D(w,y,U,"⇒","\\Rightarrow",!0);D(w,y,U,"⟹","\\Longrightarrow",!0);D(w,y,U,"↔","\\leftrightarrow",!0);D(w,y,U,"⟷","\\longleftrightarrow",!0);D(w,y,U,"⇔","\\Leftrightarrow",!0);D(w,y,U,"⟺","\\Longleftrightarrow",!0);D(w,y,U,"↦","\\mapsto",!0);D(w,y,U,"⟼","\\longmapsto",!0);D(w,y,U,"↗","\\nearrow",!0);D(w,y,U,"↩","\\hookleftarrow",!0);D(w,y,U,"↪","\\hookrightarrow",!0);D(w,y,U,"↘","\\searrow",!0);D(w,y,U,"↼","\\leftharpoonup",!0);D(w,y,U,"⇀","\\rightharpoonup",!0);D(w,y,U,"↙","\\swarrow",!0);D(w,y,U,"↽","\\leftharpoondown",!0);D(w,y,U,"⇁","\\rightharpoondown",!0);D(w,y,U,"↖","\\nwarrow",!0);D(w,y,U,"⇌","\\rightleftharpoons",!0);D(w,G,U,"≮","\\nless",!0);D(w,G,U,"","\\@nleqslant");D(w,G,U,"","\\@nleqq");D(w,G,U,"⪇","\\lneq",!0);D(w,G,U,"≨","\\lneqq",!0);D(w,G,U,"","\\@lvertneqq");D(w,G,U,"⋦","\\lnsim",!0);D(w,G,U,"⪉","\\lnapprox",!0);D(w,G,U,"⊀","\\nprec",!0);D(w,G,U,"⋠","\\npreceq",!0);D(w,G,U,"⋨","\\precnsim",!0);D(w,G,U,"⪹","\\precnapprox",!0);D(w,G,U,"≁","\\nsim",!0);D(w,G,U,"","\\@nshortmid");D(w,G,U,"∤","\\nmid",!0);D(w,G,U,"⊬","\\nvdash",!0);D(w,G,U,"⊭","\\nvDash",!0);D(w,G,U,"⋪","\\ntriangleleft");D(w,G,U,"⋬","\\ntrianglelefteq",!0);D(w,G,U,"⊊","\\subsetneq",!0);D(w,G,U,"","\\@varsubsetneq");D(w,G,U,"⫋","\\subsetneqq",!0);D(w,G,U,"","\\@varsubsetneqq");D(w,G,U,"≯","\\ngtr",!0);D(w,G,U,"","\\@ngeqslant");D(w,G,U,"","\\@ngeqq");D(w,G,U,"⪈","\\gneq",!0);D(w,G,U,"≩","\\gneqq",!0);D(w,G,U,"","\\@gvertneqq");D(w,G,U,"⋧","\\gnsim",!0);D(w,G,U,"⪊","\\gnapprox",!0);D(w,G,U,"⊁","\\nsucc",!0);D(w,G,U,"⋡","\\nsucceq",!0);D(w,G,U,"⋩","\\succnsim",!0);D(w,G,U,"⪺","\\succnapprox",!0);D(w,G,U,"≆","\\ncong",!0);D(w,G,U,"","\\@nshortparallel");D(w,G,U,"∦","\\nparallel",!0);D(w,G,U,"⊯","\\nVDash",!0);D(w,G,U,"⋫","\\ntriangleright");D(w,G,U,"⋭","\\ntrianglerighteq",!0);D(w,G,U,"","\\@nsupseteqq");D(w,G,U,"⊋","\\supsetneq",!0);D(w,G,U,"","\\@varsupsetneq");D(w,G,U,"⫌","\\supsetneqq",!0);D(w,G,U,"","\\@varsupsetneqq");D(w,G,U,"⊮","\\nVdash",!0);D(w,G,U,"⪵","\\precneqq",!0);D(w,G,U,"⪶","\\succneqq",!0);D(w,G,U,"","\\@nsubseteqq");D(w,G,ZA,"⊴","\\unlhd");D(w,G,ZA,"⊵","\\unrhd");D(w,G,U,"↚","\\nleftarrow",!0);D(w,G,U,"↛","\\nrightarrow",!0);D(w,G,U,"⇍","\\nLeftarrow",!0);D(w,G,U,"⇏","\\nRightarrow",!0);D(w,G,U,"↮","\\nleftrightarrow",!0);D(w,G,U,"⇎","\\nLeftrightarrow",!0);D(w,G,U,"△","\\vartriangle");D(w,G,T,"ℏ","\\hslash");D(w,G,T,"▽","\\triangledown");D(w,G,T,"◊","\\lozenge");D(w,G,T,"Ⓢ","\\circledS");D(w,G,T,"®","\\circledR");D(DA,G,T,"®","\\circledR");D(w,G,T,"∡","\\measuredangle",!0);D(w,G,T,"∄","\\nexists");D(w,G,T,"℧","\\mho");D(w,G,T,"Ⅎ","\\Finv",!0);D(w,G,T,"⅁","\\Game",!0);D(w,G,T,"‵","\\backprime");D(w,G,T,"▲","\\blacktriangle");D(w,G,T,"▼","\\blacktriangledown");D(w,G,T,"■","\\blacksquare");D(w,G,T,"⧫","\\blacklozenge");D(w,G,T,"★","\\bigstar");D(w,G,T,"∢","\\sphericalangle",!0);D(w,G,T,"∁","\\complement",!0);D(w,G,T,"ð","\\eth",!0);D(DA,y,T,"ð","ð");D(w,G,T,"╱","\\diagup");D(w,G,T,"╲","\\diagdown");D(w,G,T,"□","\\square");D(w,G,T,"□","\\Box");D(w,G,T,"◊","\\Diamond");D(w,G,T,"¥","\\yen",!0);D(DA,G,T,"¥","\\yen",!0);D(w,G,T,"✓","\\checkmark",!0);D(DA,G,T,"✓","\\checkmark");D(w,G,T,"ℶ","\\beth",!0);D(w,G,T,"ℸ","\\daleth",!0);D(w,G,T,"ℷ","\\gimel",!0);D(w,G,T,"ϝ","\\digamma",!0);D(w,G,T,"ϰ","\\varkappa");D(w,G,pr,"┌","\\@ulcorner",!0);D(w,G,gr,"┐","\\@urcorner",!0);D(w,G,pr,"└","\\@llcorner",!0);D(w,G,gr,"┘","\\@lrcorner",!0);D(w,G,U,"≦","\\leqq",!0);D(w,G,U,"⩽","\\leqslant",!0);D(w,G,U,"⪕","\\eqslantless",!0);D(w,G,U,"≲","\\lesssim",!0);D(w,G,U,"⪅","\\lessapprox",!0);D(w,G,U,"≊","\\approxeq",!0);D(w,G,ZA,"⋖","\\lessdot");D(w,G,U,"⋘","\\lll",!0);D(w,G,U,"≶","\\lessgtr",!0);D(w,G,U,"⋚","\\lesseqgtr",!0);D(w,G,U,"⪋","\\lesseqqgtr",!0);D(w,G,U,"≑","\\doteqdot");D(w,G,U,"≓","\\risingdotseq",!0);D(w,G,U,"≒","\\fallingdotseq",!0);D(w,G,U,"∽","\\backsim",!0);D(w,G,U,"⋍","\\backsimeq",!0);D(w,G,U,"⫅","\\subseteqq",!0);D(w,G,U,"⋐","\\Subset",!0);D(w,G,U,"⊏","\\sqsubset",!0);D(w,G,U,"≼","\\preccurlyeq",!0);D(w,G,U,"⋞","\\curlyeqprec",!0);D(w,G,U,"≾","\\precsim",!0);D(w,G,U,"⪷","\\precapprox",!0);D(w,G,U,"⊲","\\vartriangleleft");D(w,G,U,"⊴","\\trianglelefteq");D(w,G,U,"⊨","\\vDash",!0);D(w,G,U,"⊪","\\Vvdash",!0);D(w,G,U,"⌣","\\smallsmile");D(w,G,U,"⌢","\\smallfrown");D(w,G,U,"≏","\\bumpeq",!0);D(w,G,U,"≎","\\Bumpeq",!0);D(w,G,U,"≧","\\geqq",!0);D(w,G,U,"⩾","\\geqslant",!0);D(w,G,U,"⪖","\\eqslantgtr",!0);D(w,G,U,"≳","\\gtrsim",!0);D(w,G,U,"⪆","\\gtrapprox",!0);D(w,G,ZA,"⋗","\\gtrdot");D(w,G,U,"⋙","\\ggg",!0);D(w,G,U,"≷","\\gtrless",!0);D(w,G,U,"⋛","\\gtreqless",!0);D(w,G,U,"⪌","\\gtreqqless",!0);D(w,G,U,"≖","\\eqcirc",!0);D(w,G,U,"≗","\\circeq",!0);D(w,G,U,"≜","\\triangleq",!0);D(w,G,U,"∼","\\thicksim");D(w,G,U,"≈","\\thickapprox");D(w,G,U,"⫆","\\supseteqq",!0);D(w,G,U,"⋑","\\Supset",!0);D(w,G,U,"⊐","\\sqsupset",!0);D(w,G,U,"≽","\\succcurlyeq",!0);D(w,G,U,"⋟","\\curlyeqsucc",!0);D(w,G,U,"≿","\\succsim",!0);D(w,G,U,"⪸","\\succapprox",!0);D(w,G,U,"⊳","\\vartriangleright");D(w,G,U,"⊵","\\trianglerighteq");D(w,G,U,"⊩","\\Vdash",!0);D(w,G,U,"∣","\\shortmid");D(w,G,U,"∥","\\shortparallel");D(w,G,U,"≬","\\between",!0);D(w,G,U,"⋔","\\pitchfork",!0);D(w,G,U,"∝","\\varpropto");D(w,G,U,"◀","\\blacktriangleleft");D(w,G,U,"∴","\\therefore",!0);D(w,G,U,"∍","\\backepsilon");D(w,G,U,"▶","\\blacktriangleright");D(w,G,U,"∵","\\because",!0);D(w,G,U,"⋘","\\llless");D(w,G,U,"⋙","\\gggtr");D(w,G,ZA,"⊲","\\lhd");D(w,G,ZA,"⊳","\\rhd");D(w,G,U,"≂","\\eqsim",!0);D(w,y,U,"⋈","\\Join");D(w,G,U,"≑","\\Doteq",!0);D(w,G,ZA,"∔","\\dotplus",!0);D(w,G,ZA,"∖","\\smallsetminus");D(w,G,ZA,"⋒","\\Cap",!0);D(w,G,ZA,"⋓","\\Cup",!0);D(w,G,ZA,"⩞","\\doublebarwedge",!0);D(w,G,ZA,"⊟","\\boxminus",!0);D(w,G,ZA,"⊞","\\boxplus",!0);D(w,G,ZA,"⋇","\\divideontimes",!0);D(w,G,ZA,"⋉","\\ltimes",!0);D(w,G,ZA,"⋊","\\rtimes",!0);D(w,G,ZA,"⋋","\\leftthreetimes",!0);D(w,G,ZA,"⋌","\\rightthreetimes",!0);D(w,G,ZA,"⋏","\\curlywedge",!0);D(w,G,ZA,"⋎","\\curlyvee",!0);D(w,G,ZA,"⊝","\\circleddash",!0);D(w,G,ZA,"⊛","\\circledast",!0);D(w,G,ZA,"⋅","\\centerdot");D(w,G,ZA,"⊺","\\intercal",!0);D(w,G,ZA,"⋒","\\doublecap");D(w,G,ZA,"⋓","\\doublecup");D(w,G,ZA,"⊠","\\boxtimes",!0);D(w,G,U,"⇢","\\dashrightarrow",!0);D(w,G,U,"⇠","\\dashleftarrow",!0);D(w,G,U,"⇇","\\leftleftarrows",!0);D(w,G,U,"⇆","\\leftrightarrows",!0);D(w,G,U,"⇚","\\Lleftarrow",!0);D(w,G,U,"↞","\\twoheadleftarrow",!0);D(w,G,U,"↢","\\leftarrowtail",!0);D(w,G,U,"↫","\\looparrowleft",!0);D(w,G,U,"⇋","\\leftrightharpoons",!0);D(w,G,U,"↶","\\curvearrowleft",!0);D(w,G,U,"↺","\\circlearrowleft",!0);D(w,G,U,"↰","\\Lsh",!0);D(w,G,U,"⇈","\\upuparrows",!0);D(w,G,U,"↿","\\upharpoonleft",!0);D(w,G,U,"⇃","\\downharpoonleft",!0);D(w,y,U,"⊶","\\origof",!0);D(w,y,U,"⊷","\\imageof",!0);D(w,G,U,"⊸","\\multimap",!0);D(w,G,U,"↭","\\leftrightsquigarrow",!0);D(w,G,U,"⇉","\\rightrightarrows",!0);D(w,G,U,"⇄","\\rightleftarrows",!0);D(w,G,U,"↠","\\twoheadrightarrow",!0);D(w,G,U,"↣","\\rightarrowtail",!0);D(w,G,U,"↬","\\looparrowright",!0);D(w,G,U,"↷","\\curvearrowright",!0);D(w,G,U,"↻","\\circlearrowright",!0);D(w,G,U,"↱","\\Rsh",!0);D(w,G,U,"⇊","\\downdownarrows",!0);D(w,G,U,"↾","\\upharpoonright",!0);D(w,G,U,"⇂","\\downharpoonright",!0);D(w,G,U,"⇝","\\rightsquigarrow",!0);D(w,G,U,"⇝","\\leadsto");D(w,G,U,"⇛","\\Rrightarrow",!0);D(w,G,U,"↾","\\restriction");D(w,y,T,"‘","`");D(w,y,T,"$","\\$");D(DA,y,T,"$","\\$");D(DA,y,T,"$","\\textdollar");D(w,y,T,"%","\\%");D(DA,y,T,"%","\\%");D(w,y,T,"_","\\_");D(DA,y,T,"_","\\_");D(DA,y,T,"_","\\textunderscore");D(w,y,T,"∠","\\angle",!0);D(w,y,T,"∞","\\infty",!0);D(w,y,T,"′","\\prime");D(w,y,T,"△","\\triangle");D(w,y,T,"Γ","\\Gamma",!0);D(w,y,T,"Δ","\\Delta",!0);D(w,y,T,"Θ","\\Theta",!0);D(w,y,T,"Λ","\\Lambda",!0);D(w,y,T,"Ξ","\\Xi",!0);D(w,y,T,"Π","\\Pi",!0);D(w,y,T,"Σ","\\Sigma",!0);D(w,y,T,"Υ","\\Upsilon",!0);D(w,y,T,"Φ","\\Phi",!0);D(w,y,T,"Ψ","\\Psi",!0);D(w,y,T,"Ω","\\Omega",!0);D(w,y,T,"A","Α");D(w,y,T,"B","Β");D(w,y,T,"E","Ε");D(w,y,T,"Z","Ζ");D(w,y,T,"H","Η");D(w,y,T,"I","Ι");D(w,y,T,"K","Κ");D(w,y,T,"M","Μ");D(w,y,T,"N","Ν");D(w,y,T,"O","Ο");D(w,y,T,"P","Ρ");D(w,y,T,"T","Τ");D(w,y,T,"X","Χ");D(w,y,T,"¬","\\neg",!0);D(w,y,T,"¬","\\lnot");D(w,y,T,"⊤","\\top");D(w,y,T,"⊥","\\bot");D(w,y,T,"∅","\\emptyset");D(w,G,T,"∅","\\varnothing");D(w,y,ie,"α","\\alpha",!0);D(w,y,ie,"β","\\beta",!0);D(w,y,ie,"γ","\\gamma",!0);D(w,y,ie,"δ","\\delta",!0);D(w,y,ie,"ϵ","\\epsilon",!0);D(w,y,ie,"ζ","\\zeta",!0);D(w,y,ie,"η","\\eta",!0);D(w,y,ie,"θ","\\theta",!0);D(w,y,ie,"ι","\\iota",!0);D(w,y,ie,"κ","\\kappa",!0);D(w,y,ie,"λ","\\lambda",!0);D(w,y,ie,"μ","\\mu",!0);D(w,y,ie,"ν","\\nu",!0);D(w,y,ie,"ξ","\\xi",!0);D(w,y,ie,"ο","\\omicron",!0);D(w,y,ie,"π","\\pi",!0);D(w,y,ie,"ρ","\\rho",!0);D(w,y,ie,"σ","\\sigma",!0);D(w,y,ie,"τ","\\tau",!0);D(w,y,ie,"υ","\\upsilon",!0);D(w,y,ie,"ϕ","\\phi",!0);D(w,y,ie,"χ","\\chi",!0);D(w,y,ie,"ψ","\\psi",!0);D(w,y,ie,"ω","\\omega",!0);D(w,y,ie,"ε","\\varepsilon",!0);D(w,y,ie,"ϑ","\\vartheta",!0);D(w,y,ie,"ϖ","\\varpi",!0);D(w,y,ie,"ϱ","\\varrho",!0);D(w,y,ie,"ς","\\varsigma",!0);D(w,y,ie,"φ","\\varphi",!0);D(w,y,ZA,"∗","*",!0);D(w,y,ZA,"+","+");D(w,y,ZA,"−","-",!0);D(w,y,ZA,"⋅","\\cdot",!0);D(w,y,ZA,"∘","\\circ",!0);D(w,y,ZA,"÷","\\div",!0);D(w,y,ZA,"±","\\pm",!0);D(w,y,ZA,"×","\\times",!0);D(w,y,ZA,"∩","\\cap",!0);D(w,y,ZA,"∪","\\cup",!0);D(w,y,ZA,"∖","\\setminus",!0);D(w,y,ZA,"∧","\\land");D(w,y,ZA,"∨","\\lor");D(w,y,ZA,"∧","\\wedge",!0);D(w,y,ZA,"∨","\\vee",!0);D(w,y,T,"√","\\surd");D(w,y,pr,"⟨","\\langle",!0);D(w,y,pr,"∣","\\lvert");D(w,y,pr,"∥","\\lVert");D(w,y,gr,"?","?");D(w,y,gr,"!","!");D(w,y,gr,"⟩","\\rangle",!0);D(w,y,gr,"∣","\\rvert");D(w,y,gr,"∥","\\rVert");D(w,y,U,"=","=");D(w,y,U,":",":");D(w,y,U,"≈","\\approx",!0);D(w,y,U,"≅","\\cong",!0);D(w,y,U,"≥","\\ge");D(w,y,U,"≥","\\geq",!0);D(w,y,U,"←","\\gets");D(w,y,U,">","\\gt",!0);D(w,y,U,"∈","\\in",!0);D(w,y,U,"","\\@not");D(w,y,U,"⊂","\\subset",!0);D(w,y,U,"⊃","\\supset",!0);D(w,y,U,"⊆","\\subseteq",!0);D(w,y,U,"⊇","\\supseteq",!0);D(w,G,U,"⊈","\\nsubseteq",!0);D(w,G,U,"⊉","\\nsupseteq",!0);D(w,y,U,"⊨","\\models");D(w,y,U,"←","\\leftarrow",!0);D(w,y,U,"≤","\\le");D(w,y,U,"≤","\\leq",!0);D(w,y,U,"<","\\lt",!0);D(w,y,U,"→","\\rightarrow",!0);D(w,y,U,"→","\\to");D(w,G,U,"≱","\\ngeq",!0);D(w,G,U,"≰","\\nleq",!0);D(w,y,Qi," ","\\ ");D(w,y,Qi," ","\\space");D(w,y,Qi," ","\\nobreakspace");D(DA,y,Qi," ","\\ ");D(DA,y,Qi," "," ");D(DA,y,Qi," ","\\space");D(DA,y,Qi," ","\\nobreakspace");D(w,y,Qi,null,"\\nobreak");D(w,y,Qi,null,"\\allowbreak");D(w,y,QE,",",",");D(w,y,QE,";",";");D(w,G,ZA,"⊼","\\barwedge",!0);D(w,G,ZA,"⊻","\\veebar",!0);D(w,y,ZA,"⊙","\\odot",!0);D(w,y,ZA,"⊕","\\oplus",!0);D(w,y,ZA,"⊗","\\otimes",!0);D(w,y,T,"∂","\\partial",!0);D(w,y,ZA,"⊘","\\oslash",!0);D(w,G,ZA,"⊚","\\circledcirc",!0);D(w,G,ZA,"⊡","\\boxdot",!0);D(w,y,ZA,"△","\\bigtriangleup");D(w,y,ZA,"▽","\\bigtriangledown");D(w,y,ZA,"†","\\dagger");D(w,y,ZA,"⋄","\\diamond");D(w,y,ZA,"⋆","\\star");D(w,y,ZA,"◃","\\triangleleft");D(w,y,ZA,"▹","\\triangleright");D(w,y,pr,"{","\\{");D(DA,y,T,"{","\\{");D(DA,y,T,"{","\\textbraceleft");D(w,y,gr,"}","\\}");D(DA,y,T,"}","\\}");D(DA,y,T,"}","\\textbraceright");D(w,y,pr,"{","\\lbrace");D(w,y,gr,"}","\\rbrace");D(w,y,pr,"[","\\lbrack",!0);D(DA,y,T,"[","\\lbrack",!0);D(w,y,gr,"]","\\rbrack",!0);D(DA,y,T,"]","\\rbrack",!0);D(w,y,pr,"(","\\lparen",!0);D(w,y,gr,")","\\rparen",!0);D(DA,y,T,"<","\\textless",!0);D(DA,y,T,">","\\textgreater",!0);D(w,y,pr,"⌊","\\lfloor",!0);D(w,y,gr,"⌋","\\rfloor",!0);D(w,y,pr,"⌈","\\lceil",!0);D(w,y,gr,"⌉","\\rceil",!0);D(w,y,T,"\\","\\backslash");D(w,y,T,"∣","|");D(w,y,T,"∣","\\vert");D(DA,y,T,"|","\\textbar",!0);D(w,y,T,"∥","\\|");D(w,y,T,"∥","\\Vert");D(DA,y,T,"∥","\\textbardbl");D(DA,y,T,"~","\\textasciitilde");D(DA,y,T,"\\","\\textbackslash");D(DA,y,T,"^","\\textasciicircum");D(w,y,U,"↑","\\uparrow",!0);D(w,y,U,"⇑","\\Uparrow",!0);D(w,y,U,"↓","\\downarrow",!0);D(w,y,U,"⇓","\\Downarrow",!0);D(w,y,U,"↕","\\updownarrow",!0);D(w,y,U,"⇕","\\Updownarrow",!0);D(w,y,mt,"∐","\\coprod");D(w,y,mt,"⋁","\\bigvee");D(w,y,mt,"⋀","\\bigwedge");D(w,y,mt,"⨄","\\biguplus");D(w,y,mt,"⋂","\\bigcap");D(w,y,mt,"⋃","\\bigcup");D(w,y,mt,"∫","\\int");D(w,y,mt,"∫","\\intop");D(w,y,mt,"∬","\\iint");D(w,y,mt,"∭","\\iiint");D(w,y,mt,"∏","\\prod");D(w,y,mt,"∑","\\sum");D(w,y,mt,"⨂","\\bigotimes");D(w,y,mt,"⨁","\\bigoplus");D(w,y,mt,"⨀","\\bigodot");D(w,y,mt,"∮","\\oint");D(w,y,mt,"∯","\\oiint");D(w,y,mt,"∰","\\oiiint");D(w,y,mt,"⨆","\\bigsqcup");D(w,y,mt,"∫","\\smallint");D(DA,y,zg,"…","\\textellipsis");D(w,y,zg,"…","\\mathellipsis");D(DA,y,zg,"…","\\ldots",!0);D(w,y,zg,"…","\\ldots",!0);D(w,y,zg,"⋯","\\@cdots",!0);D(w,y,zg,"⋱","\\ddots",!0);D(w,y,T,"⋮","\\varvdots");D(DA,y,T,"⋮","\\varvdots");D(w,y,nt,"ˊ","\\acute");D(w,y,nt,"ˋ","\\grave");D(w,y,nt,"¨","\\ddot");D(w,y,nt,"~","\\tilde");D(w,y,nt,"ˉ","\\bar");D(w,y,nt,"˘","\\breve");D(w,y,nt,"ˇ","\\check");D(w,y,nt,"^","\\hat");D(w,y,nt,"⃗","\\vec");D(w,y,nt,"˙","\\dot");D(w,y,nt,"˚","\\mathring");D(w,y,ie,"","\\@imath");D(w,y,ie,"","\\@jmath");D(w,y,T,"ı","ı");D(w,y,T,"ȷ","ȷ");D(DA,y,T,"ı","\\i",!0);D(DA,y,T,"ȷ","\\j",!0);D(DA,y,T,"ß","\\ss",!0);D(DA,y,T,"æ","\\ae",!0);D(DA,y,T,"œ","\\oe",!0);D(DA,y,T,"ø","\\o",!0);D(DA,y,T,"Æ","\\AE",!0);D(DA,y,T,"Œ","\\OE",!0);D(DA,y,T,"Ø","\\O",!0);D(DA,y,nt,"ˊ","\\'");D(DA,y,nt,"ˋ","\\`");D(DA,y,nt,"ˆ","\\^");D(DA,y,nt,"˜","\\~");D(DA,y,nt,"ˉ","\\=");D(DA,y,nt,"˘","\\u");D(DA,y,nt,"˙","\\.");D(DA,y,nt,"¸","\\c");D(DA,y,nt,"˚","\\r");D(DA,y,nt,"ˇ","\\v");D(DA,y,nt,"¨",'\\"');D(DA,y,nt,"˝","\\H");D(DA,y,nt,"◯","\\textcircled");var Ep={"--":!0,"---":!0,"``":!0,"''":!0};D(DA,y,T,"–","--",!0);D(DA,y,T,"–","\\textendash");D(DA,y,T,"—","---",!0);D(DA,y,T,"—","\\textemdash");D(DA,y,T,"‘","`",!0);D(DA,y,T,"‘","\\textquoteleft");D(DA,y,T,"’","'",!0);D(DA,y,T,"’","\\textquoteright");D(DA,y,T,"“","``",!0);D(DA,y,T,"“","\\textquotedblleft");D(DA,y,T,"”","''",!0);D(DA,y,T,"”","\\textquotedblright");D(w,y,T,"°","\\degree",!0);D(DA,y,T,"°","\\degree");D(DA,y,T,"°","\\textdegree",!0);D(w,y,T,"£","\\pounds");D(w,y,T,"£","\\mathsterling",!0);D(DA,y,T,"£","\\pounds");D(DA,y,T,"£","\\textsterling",!0);D(w,G,T,"✠","\\maltese");D(DA,G,T,"✠","\\maltese");var xh='0123456789/@."';for(var yC=0;yC0)return zr(i,B,n,t,o.concat(a));if(Q){var s,C;if(Q==="boldsymbol"){var E=NS(i,n,t,o,r);s=E.fontName,C=[E.fontClass]}else g?(s=lp[Q].fontName,C=[Q]):(s=ha(Q,t.fontWeight,t.fontShape),C=[Q,t.fontWeight,t.fontShape]);if(BE(i,s,n).metrics)return zr(i,s,n,t,o.concat(C));if(Ep.hasOwnProperty(i)&&s.slice(0,10)==="Typewriter"){for(var I=[],c=0;c{if(Ri(e.classes)!==Ri(A.classes)||e.skew!==A.skew||e.maxFontSize!==A.maxFontSize)return!1;if(e.classes.length===1){var t=e.classes[0];if(t==="mbin"||t==="mord")return!1}for(var r in e.style)if(e.style.hasOwnProperty(r)&&e.style[r]!==A.style[r])return!1;for(var n in A.style)if(A.style.hasOwnProperty(n)&&e.style[n]!==A.style[n])return!1;return!0},FS=e=>{for(var A=0;At&&(t=o.height),o.depth>r&&(r=o.depth),o.maxFontSize>n&&(n=o.maxFontSize)}A.height=t,A.depth=r,A.maxFontSize=n},Qr=function(A,t,r,n){var i=new MB(A,t,r,n);return qc(i),i},Cp=(e,A,t,r)=>new MB(e,A,t,r),xS=function(A,t,r){var n=Qr([A],[],t);return n.height=Math.max(r||t.fontMetrics().defaultRuleThickness,t.minRuleThickness),n.style.borderBottomWidth=UA(n.height),n.maxFontSize=1,n},GS=function(A,t,r,n){var i=new Oc(A,t,r,n);return qc(i),i},Ip=function(A){var t=new yB(A);return qc(t),t},SS=function(A,t){return A instanceof yB?Qr([],[A],t):A},JS=function(A){if(A.positionType==="individualShift"){for(var t=A.children,r=[t[0]],n=-t[0].shift-t[0].elem.depth,i=n,o=1;o{var t=Qr(["mspace"],[],A),r=gt(e,A);return t.style.marginRight=UA(r),t},ha=function(A,t,r){var n="";switch(A){case"amsrm":n="AMS";break;case"textrm":n="Main";break;case"textsf":n="SansSerif";break;case"texttt":n="Typewriter";break;default:n=A}var i;return t==="textbf"&&r==="textit"?i="BoldItalic":t==="textbf"?i="Bold":t==="textit"?i="Italic":i="Regular",n+"-"+i},lp={mathbf:{variant:"bold",fontName:"Main-Bold"},mathrm:{variant:"normal",fontName:"Main-Regular"},textit:{variant:"italic",fontName:"Main-Italic"},mathit:{variant:"italic",fontName:"Main-Italic"},mathnormal:{variant:"italic",fontName:"Math-Italic"},mathsfit:{variant:"sans-serif-italic",fontName:"SansSerif-Italic"},mathbb:{variant:"double-struck",fontName:"AMS-Regular"},mathcal:{variant:"script",fontName:"Caligraphic-Regular"},mathfrak:{variant:"fraktur",fontName:"Fraktur-Regular"},mathscr:{variant:"script",fontName:"Script-Regular"},mathsf:{variant:"sans-serif",fontName:"SansSerif-Regular"},mathtt:{variant:"monospace",fontName:"Typewriter-Regular"}},cp={vec:["vec",.471,.714],oiintSize1:["oiintSize1",.957,.499],oiintSize2:["oiintSize2",1.472,.659],oiiintSize1:["oiiintSize1",1.304,.499],oiiintSize2:["oiiintSize2",1.98,.659]},LS=function(A,t){var[r,n,i]=cp[A],o=new Oi(r),g=new ei([o],{width:UA(n),height:UA(i),style:"width:"+UA(n),viewBox:"0 0 "+1e3*n+" "+1e3*i,preserveAspectRatio:"xMinYMin"}),Q=Cp(["overlay"],[g],t);return Q.height=i,Q.style.height=UA(i),Q.style.width=UA(n),Q},X={fontMap:lp,makeSymbol:zr,mathsym:MS,makeSpan:Qr,makeSvgSpan:Cp,makeLineSpan:xS,makeAnchor:GS,makeFragment:Ip,wrapFragment:SS,makeVList:US,makeOrd:vS,makeGlue:KS,staticSvg:LS,svgData:cp,tryCombineChars:FS},it={number:3,unit:"mu"},oo={number:4,unit:"mu"},Un={number:5,unit:"mu"},RS={mord:{mop:it,mbin:oo,mrel:Un,minner:it},mop:{mord:it,mop:it,mrel:Un,minner:it},mbin:{mord:oo,mop:oo,mopen:oo,minner:oo},mrel:{mord:Un,mop:Un,mopen:Un,minner:Un},mopen:{},mclose:{mop:it,mbin:oo,mrel:Un,minner:it},mpunct:{mord:it,mop:it,mrel:Un,mopen:it,mclose:it,mpunct:it,minner:it},minner:{mord:it,mop:it,mbin:oo,mrel:Un,mopen:it,mpunct:it,minner:it}},OS={mord:{mop:it},mop:{mord:it,mop:it},mbin:{},mrel:{},mopen:{},mclose:{mop:it},mpunct:{},minner:{mop:it}},up={},Ds={},fs={};function zA(e){for(var{type:A,names:t,props:r,handler:n,htmlBuilder:i,mathmlBuilder:o}=e,g={type:A,numArgs:r.numArgs,argTypes:r.argTypes,allowedInArgument:!!r.allowedInArgument,allowedInText:!!r.allowedInText,allowedInMath:r.allowedInMath===void 0?!0:r.allowedInMath,numOptionalArgs:r.numOptionalArgs||0,infix:!!r.infix,primitive:!!r.primitive,handler:n},Q=0;Q{var u=c.classes[0],h=I.classes[0];u==="mbin"&&TS.includes(h)?c.classes[0]="mord":h==="mbin"&&qS.includes(u)&&(I.classes[0]="mord")},{node:s},C,E),Kh(i,(I,c)=>{var u=$I(c),h=$I(I),d=u&&h?I.hasClass("mtight")?OS[u][h]:RS[u][h]:null;if(d)return X.makeGlue(d,B)},{node:s},C,E),i},Kh=function e(A,t,r,n,i){n&&A.push(n);for(var o=0;oC=>{A.splice(s+1,0,C),o++})(o)}n&&A.pop()},dp=function(A){return A instanceof yB||A instanceof Oc||A instanceof MB&&A.hasClass("enclosing")?A:null},zS=function e(A,t){var r=dp(A);if(r){var n=r.children;if(n.length){if(t==="right")return e(n[n.length-1],"right");if(t==="left")return e(n[0],"left")}}return A},$I=function(A,t){return A?(t&&(A=zS(A,t)),YS[A.classes[0]]||null):null},AB=function(A,t){var r=["nulldelimiter"].concat(A.baseSizingClasses());return ti(t.concat(r))},Ue=function(A,t,r){if(!A)return ti();if(Ds[A.type]){var n=Ds[A.type](A,t);if(r&&t.size!==r.size){n=ti(t.sizingClasses(r),[n],t);var i=t.sizeMultiplier/r.sizeMultiplier;n.height*=i,n.depth*=i}return n}else throw new NA("Got group of unknown type: '"+A.type+"'")};function Da(e,A){var t=ti(["base"],e,A),r=ti(["strut"]);return r.style.height=UA(t.height+t.depth),t.depth&&(r.style.verticalAlign=UA(-t.depth)),t.children.unshift(r),t}function Al(e,A){var t=null;e.length===1&&e[0].type==="tag"&&(t=e[0].tag,e=e[0].body);var r=Ft(e,A,"root"),n;r.length===2&&r[1].hasClass("tag")&&(n=r.pop());for(var i=[],o=[],g=0;g0&&(i.push(Da(o,A)),o=[]),i.push(r[g]));o.length>0&&i.push(Da(o,A));var B;t?(B=Da(Ft(t,A,!0)),B.classes=["tag"],i.push(B)):n&&i.push(n);var a=ti(["katex-html"],i);if(a.setAttribute("aria-hidden","true"),B){var s=B.children[0];s.style.height=UA(a.height+a.depth),a.depth&&(s.style.verticalAlign=UA(-a.depth))}return a}function hp(e){return new yB(e)}class dr{constructor(A,t,r){this.type=void 0,this.attributes=void 0,this.children=void 0,this.classes=void 0,this.type=A,this.attributes={},this.children=t||[],this.classes=r||[]}setAttribute(A,t){this.attributes[A]=t}getAttribute(A){return this.attributes[A]}toNode(){var A=document.createElementNS("http://www.w3.org/1998/Math/MathML",this.type);for(var t in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,t)&&A.setAttribute(t,this.attributes[t]);this.classes.length>0&&(A.className=Ri(this.classes));for(var r=0;r0&&(A+=' class ="'+Le.escape(Ri(this.classes))+'"'),A+=">";for(var r=0;r",A}toText(){return this.children.map(A=>A.toText()).join("")}}class dn{constructor(A){this.text=void 0,this.text=A}toNode(){return document.createTextNode(this.text)}toMarkup(){return Le.escape(this.toText())}toText(){return this.text}}class PS{constructor(A){this.width=void 0,this.character=void 0,this.width=A,A>=.05555&&A<=.05556?this.character=" ":A>=.1666&&A<=.1667?this.character=" ":A>=.2222&&A<=.2223?this.character=" ":A>=.2777&&A<=.2778?this.character="  ":A>=-.05556&&A<=-.05555?this.character=" ⁣":A>=-.1667&&A<=-.1666?this.character=" ⁣":A>=-.2223&&A<=-.2222?this.character=" ⁣":A>=-.2778&&A<=-.2777?this.character=" ⁣":this.character=null}toNode(){if(this.character)return document.createTextNode(this.character);var A=document.createElementNS("http://www.w3.org/1998/Math/MathML","mspace");return A.setAttribute("width",UA(this.width)),A}toMarkup(){return this.character?""+this.character+"":''}toText(){return this.character?this.character:" "}}var pA={MathNode:dr,TextNode:dn,SpaceNode:PS,newDocumentFragment:hp},Kr=function(A,t,r){return Ze[t][A]&&Ze[t][A].replace&&A.charCodeAt(0)!==55349&&!(Ep.hasOwnProperty(A)&&r&&(r.fontFamily&&r.fontFamily.slice(4,6)==="tt"||r.font&&r.font.slice(4,6)==="tt"))&&(A=Ze[t][A].replace),new pA.TextNode(A)},Tc=function(A){return A.length===1?A[0]:new pA.MathNode("mrow",A)},Hc=function(A,t){if(t.fontFamily==="texttt")return"monospace";if(t.fontFamily==="textsf")return t.fontShape==="textit"&&t.fontWeight==="textbf"?"sans-serif-bold-italic":t.fontShape==="textit"?"sans-serif-italic":t.fontWeight==="textbf"?"bold-sans-serif":"sans-serif";if(t.fontShape==="textit"&&t.fontWeight==="textbf")return"bold-italic";if(t.fontShape==="textit")return"italic";if(t.fontWeight==="textbf")return"bold";var r=t.font;if(!r||r==="mathnormal")return null;var n=A.mode;if(r==="mathit")return"italic";if(r==="boldsymbol")return A.type==="textord"?"bold":"bold-italic";if(r==="mathbf")return"bold";if(r==="mathbb")return"double-struck";if(r==="mathsfit")return"sans-serif-italic";if(r==="mathfrak")return"fraktur";if(r==="mathscr"||r==="mathcal")return"script";if(r==="mathsf")return"sans-serif";if(r==="mathtt")return"monospace";var i=A.text;if(["\\imath","\\jmath"].includes(i))return null;Ze[n][i]&&Ze[n][i].replace&&(i=Ze[n][i].replace);var o=X.fontMap[r].fontName;return Rc(i,o,n)?X.fontMap[r].variant:null};function bC(e){if(!e)return!1;if(e.type==="mi"&&e.children.length===1){var A=e.children[0];return A instanceof dn&&A.text==="."}else if(e.type==="mo"&&e.children.length===1&&e.getAttribute("separator")==="true"&&e.getAttribute("lspace")==="0em"&&e.getAttribute("rspace")==="0em"){var t=e.children[0];return t instanceof dn&&t.text===","}else return!1}var sr=function(A,t,r){if(A.length===1){var n=Ve(A[0],t);return r&&n instanceof dr&&n.type==="mo"&&(n.setAttribute("lspace","0em"),n.setAttribute("rspace","0em")),[n]}for(var i=[],o,g=0;g=1&&(o.type==="mn"||bC(o))){var B=Q.children[0];B instanceof dr&&B.type==="mn"&&(B.children=[...o.children,...B.children],i.pop())}else if(o.type==="mi"&&o.children.length===1){var a=o.children[0];if(a instanceof dn&&a.text==="̸"&&(Q.type==="mo"||Q.type==="mi"||Q.type==="mn")){var s=Q.children[0];s instanceof dn&&s.text.length>0&&(s.text=s.text.slice(0,1)+"̸"+s.text.slice(1),i.pop())}}}i.push(Q),o=Q}return i},qi=function(A,t,r){return Tc(sr(A,t,r))},Ve=function(A,t){if(!A)return new pA.MathNode("mrow");if(fs[A.type]){var r=fs[A.type](A,t);return r}else throw new NA("Got group of unknown type: '"+A.type+"'")};function Lh(e,A,t,r,n){var i=sr(e,t),o;i.length===1&&i[0]instanceof dr&&["mrow","mtable"].includes(i[0].type)?o=i[0]:o=new pA.MathNode("mrow",i);var g=new pA.MathNode("annotation",[new pA.TextNode(A)]);g.setAttribute("encoding","application/x-tex");var Q=new pA.MathNode("semantics",[o,g]),B=new pA.MathNode("math",[Q]);B.setAttribute("xmlns","http://www.w3.org/1998/Math/MathML"),r&&B.setAttribute("display","block");var a=n?"katex":"katex-mathml";return X.makeSpan([a],[B])}var Dp=function(A){return new Tn({style:A.displayMode?oe.DISPLAY:oe.TEXT,maxSize:A.maxSize,minRuleThickness:A.minRuleThickness})},fp=function(A,t){if(t.displayMode){var r=["katex-display"];t.leqno&&r.push("leqno"),t.fleqn&&r.push("fleqn"),A=X.makeSpan(r,[A])}return A},_S=function(A,t,r){var n=Dp(r),i;if(r.output==="mathml")return Lh(A,t,n,r.displayMode,!0);if(r.output==="html"){var o=Al(A,n);i=X.makeSpan(["katex"],[o])}else{var g=Lh(A,t,n,r.displayMode,!1),Q=Al(A,n);i=X.makeSpan(["katex"],[g,Q])}return fp(i,r)},jS=function(A,t,r){var n=Dp(r),i=Al(A,n),o=X.makeSpan(["katex"],[i]);return fp(o,r)},VS={widehat:"^",widecheck:"ˇ",widetilde:"~",utilde:"~",overleftarrow:"←",underleftarrow:"←",xleftarrow:"←",overrightarrow:"→",underrightarrow:"→",xrightarrow:"→",underbrace:"⏟",overbrace:"⏞",overgroup:"⏠",undergroup:"⏡",overleftrightarrow:"↔",underleftrightarrow:"↔",xleftrightarrow:"↔",Overrightarrow:"⇒",xRightarrow:"⇒",overleftharpoon:"↼",xleftharpoonup:"↼",overrightharpoon:"⇀",xrightharpoonup:"⇀",xLeftarrow:"⇐",xLeftrightarrow:"⇔",xhookleftarrow:"↩",xhookrightarrow:"↪",xmapsto:"↦",xrightharpoondown:"⇁",xleftharpoondown:"↽",xrightleftharpoons:"⇌",xleftrightharpoons:"⇋",xtwoheadleftarrow:"↞",xtwoheadrightarrow:"↠",xlongequal:"=",xtofrom:"⇄",xrightleftarrows:"⇄",xrightequilibrium:"⇌",xleftequilibrium:"⇋","\\cdrightarrow":"→","\\cdleftarrow":"←","\\cdlongequal":"="},WS=function(A){var t=new pA.MathNode("mo",[new pA.TextNode(VS[A.replace(/^\\/,"")])]);return t.setAttribute("stretchy","true"),t},ZS={overrightarrow:[["rightarrow"],.888,522,"xMaxYMin"],overleftarrow:[["leftarrow"],.888,522,"xMinYMin"],underrightarrow:[["rightarrow"],.888,522,"xMaxYMin"],underleftarrow:[["leftarrow"],.888,522,"xMinYMin"],xrightarrow:[["rightarrow"],1.469,522,"xMaxYMin"],"\\cdrightarrow":[["rightarrow"],3,522,"xMaxYMin"],xleftarrow:[["leftarrow"],1.469,522,"xMinYMin"],"\\cdleftarrow":[["leftarrow"],3,522,"xMinYMin"],Overrightarrow:[["doublerightarrow"],.888,560,"xMaxYMin"],xRightarrow:[["doublerightarrow"],1.526,560,"xMaxYMin"],xLeftarrow:[["doubleleftarrow"],1.526,560,"xMinYMin"],overleftharpoon:[["leftharpoon"],.888,522,"xMinYMin"],xleftharpoonup:[["leftharpoon"],.888,522,"xMinYMin"],xleftharpoondown:[["leftharpoondown"],.888,522,"xMinYMin"],overrightharpoon:[["rightharpoon"],.888,522,"xMaxYMin"],xrightharpoonup:[["rightharpoon"],.888,522,"xMaxYMin"],xrightharpoondown:[["rightharpoondown"],.888,522,"xMaxYMin"],xlongequal:[["longequal"],.888,334,"xMinYMin"],"\\cdlongequal":[["longequal"],3,334,"xMinYMin"],xtwoheadleftarrow:[["twoheadleftarrow"],.888,334,"xMinYMin"],xtwoheadrightarrow:[["twoheadrightarrow"],.888,334,"xMaxYMin"],overleftrightarrow:[["leftarrow","rightarrow"],.888,522],overbrace:[["leftbrace","midbrace","rightbrace"],1.6,548],underbrace:[["leftbraceunder","midbraceunder","rightbraceunder"],1.6,548],underleftrightarrow:[["leftarrow","rightarrow"],.888,522],xleftrightarrow:[["leftarrow","rightarrow"],1.75,522],xLeftrightarrow:[["doubleleftarrow","doublerightarrow"],1.75,560],xrightleftharpoons:[["leftharpoondownplus","rightharpoonplus"],1.75,716],xleftrightharpoons:[["leftharpoonplus","rightharpoondownplus"],1.75,716],xhookleftarrow:[["leftarrow","righthook"],1.08,522],xhookrightarrow:[["lefthook","rightarrow"],1.08,522],overlinesegment:[["leftlinesegment","rightlinesegment"],.888,522],underlinesegment:[["leftlinesegment","rightlinesegment"],.888,522],overgroup:[["leftgroup","rightgroup"],.888,342],undergroup:[["leftgroupunder","rightgroupunder"],.888,342],xmapsto:[["leftmapsto","rightarrow"],1.5,522],xtofrom:[["leftToFrom","rightToFrom"],1.75,528],xrightleftarrows:[["baraboveleftarrow","rightarrowabovebar"],1.75,901],xrightequilibrium:[["baraboveshortleftharpoon","rightharpoonaboveshortbar"],1.75,716],xleftequilibrium:[["shortbaraboveleftharpoon","shortrightharpoonabovebar"],1.75,716]},XS=function(A){return A.type==="ordgroup"?A.body.length:1},$S=function(A,t){function r(){var g=4e5,Q=A.label.slice(1);if(["widehat","widecheck","widetilde","utilde"].includes(Q)){var B=A,a=XS(B.base),s,C,E;if(a>5)Q==="widehat"||Q==="widecheck"?(s=420,g=2364,E=.42,C=Q+"4"):(s=312,g=2340,E=.34,C="tilde4");else{var I=[1,1,2,2,3,3][a];Q==="widehat"||Q==="widecheck"?(g=[0,1062,2364,2364,2364][I],s=[0,239,300,360,420][I],E=[0,.24,.3,.3,.36,.42][I],C=Q+I):(g=[0,600,1033,2339,2340][I],s=[0,260,286,306,312][I],E=[0,.26,.286,.3,.306,.34][I],C="tilde"+I)}var c=new Oi(C),u=new ei([c],{width:"100%",height:UA(E),viewBox:"0 0 "+g+" "+s,preserveAspectRatio:"none"});return{span:X.makeSvgSpan([],[u],t),minWidth:0,height:E}}else{var h=[],d=ZS[Q],[f,m,k]=d,N=k/1e3,F=f.length,L,v;if(F===1){var O=d[3];L=["hide-tail"],v=[O]}else if(F===2)L=["halfarrow-left","halfarrow-right"],v=["xMinYMin","xMaxYMin"];else if(F===3)L=["brace-left","brace-center","brace-right"],v=["xMinYMin","xMidYMin","xMaxYMin"];else throw new Error(`Correct katexImagesData or update code here to support `+F+" children.");for(var W=0;W0&&(n.style.minWidth=UA(i)),n},AJ=function(A,t,r,n,i){var o,g=A.height+A.depth+r+n;if(/fbox|color|angl/.test(t)){if(o=X.makeSpan(["stretchy",t],[],i),t==="fbox"){var Q=i.color&&i.getColor();Q&&(o.style.borderColor=Q)}}else{var B=[];/^[bx]cancel$/.test(t)&&B.push(new ZI({x1:"0",y1:"0",x2:"100%",y2:"100%","stroke-width":"0.046em"})),/^x?cancel$/.test(t)&&B.push(new ZI({x1:"0",y1:"100%",x2:"100%",y2:"0","stroke-width":"0.046em"}));var a=new ei(B,{width:"100%",height:UA(g)});o=X.makeSvgSpan([],[a],i)}return o.height=g,o.style.height=UA(g),o},ri={encloseSpan:AJ,mathMLnode:WS,svgSpan:$S};function De(e,A){if(!e||e.type!==A)throw new Error("Expected node of type "+A+", but got "+(e?"node of type "+e.type:String(e)));return e}function Yc(e){var A=aE(e);if(!A)throw new Error("Expected node of symbol group type, but got "+(e?"node of type "+e.type:String(e)));return A}function aE(e){return e&&(e.type==="atom"||kS.hasOwnProperty(e.type))?e:null}var zc=(e,A)=>{var t,r,n;e&&e.type==="supsub"?(r=De(e.base,"accent"),t=r.base,e.base=t,n=mS(Ue(e,A)),e.base=r):(r=De(e,"accent"),t=r.base);var i=Ue(t,A.havingCrampedStyle()),o=r.isShifty&&Le.isCharacterBox(t),g=0;if(o){var Q=Le.getBaseElem(t),B=Ue(Q,A.havingCrampedStyle());g=Fh(B).skew}var a=r.label==="\\c",s=a?i.height+i.depth:Math.min(i.height,A.fontMetrics().xHeight),C;if(r.isStretchy)C=ri.svgSpan(r,A),C=X.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:i},{type:"elem",elem:C,wrapperClasses:["svg-align"],wrapperStyle:g>0?{width:"calc(100% - "+UA(2*g)+")",marginLeft:UA(2*g)}:void 0}]},A);else{var E,I;r.label==="\\vec"?(E=X.staticSvg("vec",A),I=X.svgData.vec[1]):(E=X.makeOrd({mode:r.mode,text:r.label},A,"textord"),E=Fh(E),E.italic=0,I=E.width,a&&(s+=E.depth)),C=X.makeSpan(["accent-body"],[E]);var c=r.label==="\\textcircled";c&&(C.classes.push("accent-full"),s=i.height);var u=g;c||(u-=I/2),C.style.left=UA(u),r.label==="\\textcircled"&&(C.style.top=".2em"),C=X.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:i},{type:"kern",size:-s},{type:"elem",elem:C}]},A)}var h=X.makeSpan(["mord","accent"],[C],A);return n?(n.children[0]=h,n.height=Math.max(h.height,n.height),n.classes[0]="mord",n):h},wp=(e,A)=>{var t=e.isStretchy?ri.mathMLnode(e.label):new pA.MathNode("mo",[Kr(e.label,e.mode)]),r=new pA.MathNode("mover",[Ve(e.base,A),t]);return r.setAttribute("accent","true"),r},eJ=new RegExp(["\\acute","\\grave","\\ddot","\\tilde","\\bar","\\breve","\\check","\\hat","\\vec","\\dot","\\mathring"].map(e=>"\\"+e).join("|"));zA({type:"accent",names:["\\acute","\\grave","\\ddot","\\tilde","\\bar","\\breve","\\check","\\hat","\\vec","\\dot","\\mathring","\\widecheck","\\widehat","\\widetilde","\\overrightarrow","\\overleftarrow","\\Overrightarrow","\\overleftrightarrow","\\overgroup","\\overlinesegment","\\overleftharpoon","\\overrightharpoon"],props:{numArgs:1},handler:(e,A)=>{var t=ws(A[0]),r=!eJ.test(e.funcName),n=!r||e.funcName==="\\widehat"||e.funcName==="\\widetilde"||e.funcName==="\\widecheck";return{type:"accent",mode:e.parser.mode,label:e.funcName,isStretchy:r,isShifty:n,base:t}},htmlBuilder:zc,mathmlBuilder:wp});zA({type:"accent",names:["\\'","\\`","\\^","\\~","\\=","\\u","\\.",'\\"',"\\c","\\r","\\H","\\v","\\textcircled"],props:{numArgs:1,allowedInText:!0,allowedInMath:!0,argTypes:["primitive"]},handler:(e,A)=>{var t=A[0],r=e.parser.mode;return r==="math"&&(e.parser.settings.reportNonstrict("mathVsTextAccents","LaTeX's accent "+e.funcName+" works only in text mode"),r="text"),{type:"accent",mode:r,label:e.funcName,isStretchy:!1,isShifty:!0,base:t}},htmlBuilder:zc,mathmlBuilder:wp});zA({type:"accentUnder",names:["\\underleftarrow","\\underrightarrow","\\underleftrightarrow","\\undergroup","\\underlinesegment","\\utilde"],props:{numArgs:1},handler:(e,A)=>{var{parser:t,funcName:r}=e,n=A[0];return{type:"accentUnder",mode:t.mode,label:r,base:n}},htmlBuilder:(e,A)=>{var t=Ue(e.base,A),r=ri.svgSpan(e,A),n=e.label==="\\utilde"?.12:0,i=X.makeVList({positionType:"top",positionData:t.height,children:[{type:"elem",elem:r,wrapperClasses:["svg-align"]},{type:"kern",size:n},{type:"elem",elem:t}]},A);return X.makeSpan(["mord","accentunder"],[i],A)},mathmlBuilder:(e,A)=>{var t=ri.mathMLnode(e.label),r=new pA.MathNode("munder",[Ve(e.base,A),t]);return r.setAttribute("accentunder","true"),r}});var fa=e=>{var A=new pA.MathNode("mpadded",e?[e]:[]);return A.setAttribute("width","+0.6em"),A.setAttribute("lspace","0.3em"),A};zA({type:"xArrow",names:["\\xleftarrow","\\xrightarrow","\\xLeftarrow","\\xRightarrow","\\xleftrightarrow","\\xLeftrightarrow","\\xhookleftarrow","\\xhookrightarrow","\\xmapsto","\\xrightharpoondown","\\xrightharpoonup","\\xleftharpoondown","\\xleftharpoonup","\\xrightleftharpoons","\\xleftrightharpoons","\\xlongequal","\\xtwoheadrightarrow","\\xtwoheadleftarrow","\\xtofrom","\\xrightleftarrows","\\xrightequilibrium","\\xleftequilibrium","\\\\cdrightarrow","\\\\cdleftarrow","\\\\cdlongequal"],props:{numArgs:1,numOptionalArgs:1},handler(e,A,t){var{parser:r,funcName:n}=e;return{type:"xArrow",mode:r.mode,label:n,body:A[0],below:t[0]}},htmlBuilder(e,A){var t=A.style,r=A.havingStyle(t.sup()),n=X.wrapFragment(Ue(e.body,r,A),A),i=e.label.slice(0,2)==="\\x"?"x":"cd";n.classes.push(i+"-arrow-pad");var o;e.below&&(r=A.havingStyle(t.sub()),o=X.wrapFragment(Ue(e.below,r,A),A),o.classes.push(i+"-arrow-pad"));var g=ri.svgSpan(e,A),Q=-A.fontMetrics().axisHeight+.5*g.height,B=-A.fontMetrics().axisHeight-.5*g.height-.111;(n.depth>.25||e.label==="\\xleftequilibrium")&&(B-=n.depth);var a;if(o){var s=-A.fontMetrics().axisHeight+o.height+.5*g.height+.111;a=X.makeVList({positionType:"individualShift",children:[{type:"elem",elem:n,shift:B},{type:"elem",elem:g,shift:Q},{type:"elem",elem:o,shift:s}]},A)}else a=X.makeVList({positionType:"individualShift",children:[{type:"elem",elem:n,shift:B},{type:"elem",elem:g,shift:Q}]},A);return a.children[0].children[0].children[1].classes.push("svg-align"),X.makeSpan(["mrel","x-arrow"],[a],A)},mathmlBuilder(e,A){var t=ri.mathMLnode(e.label);t.setAttribute("minsize",e.label.charAt(0)==="x"?"1.75em":"3.0em");var r;if(e.body){var n=fa(Ve(e.body,A));if(e.below){var i=fa(Ve(e.below,A));r=new pA.MathNode("munderover",[t,i,n])}else r=new pA.MathNode("mover",[t,n])}else if(e.below){var o=fa(Ve(e.below,A));r=new pA.MathNode("munder",[t,o])}else r=fa(),r=new pA.MathNode("mover",[t,r]);return r}});var tJ=X.makeSpan;function mp(e,A){var t=Ft(e.body,A,!0);return tJ([e.mclass],t,A)}function pp(e,A){var t,r=sr(e.body,A);return e.mclass==="minner"?t=new pA.MathNode("mpadded",r):e.mclass==="mord"?e.isCharacterBox?(t=r[0],t.type="mi"):t=new pA.MathNode("mi",r):(e.isCharacterBox?(t=r[0],t.type="mo"):t=new pA.MathNode("mo",r),e.mclass==="mbin"?(t.attributes.lspace="0.22em",t.attributes.rspace="0.22em"):e.mclass==="mpunct"?(t.attributes.lspace="0em",t.attributes.rspace="0.17em"):e.mclass==="mopen"||e.mclass==="mclose"?(t.attributes.lspace="0em",t.attributes.rspace="0em"):e.mclass==="minner"&&(t.attributes.lspace="0.0556em",t.attributes.width="+0.1111em")),t}zA({type:"mclass",names:["\\mathord","\\mathbin","\\mathrel","\\mathopen","\\mathclose","\\mathpunct","\\mathinner"],props:{numArgs:1,primitive:!0},handler(e,A){var{parser:t,funcName:r}=e,n=A[0];return{type:"mclass",mode:t.mode,mclass:"m"+r.slice(5),body:ct(n),isCharacterBox:Le.isCharacterBox(n)}},htmlBuilder:mp,mathmlBuilder:pp});var sE=e=>{var A=e.type==="ordgroup"&&e.body.length?e.body[0]:e;return A.type==="atom"&&(A.family==="bin"||A.family==="rel")?"m"+A.family:"mord"};zA({type:"mclass",names:["\\@binrel"],props:{numArgs:2},handler(e,A){var{parser:t}=e;return{type:"mclass",mode:t.mode,mclass:sE(A[0]),body:ct(A[1]),isCharacterBox:Le.isCharacterBox(A[1])}}});zA({type:"mclass",names:["\\stackrel","\\overset","\\underset"],props:{numArgs:2},handler(e,A){var{parser:t,funcName:r}=e,n=A[1],i=A[0],o;r!=="\\stackrel"?o=sE(n):o="mrel";var g={type:"op",mode:n.mode,limits:!0,alwaysHandleSupSub:!0,parentIsSupSub:!1,symbol:!1,suppressBaseShift:r!=="\\stackrel",body:ct(n)},Q={type:"supsub",mode:i.mode,base:g,sup:r==="\\underset"?null:i,sub:r==="\\underset"?i:null};return{type:"mclass",mode:t.mode,mclass:o,body:[Q],isCharacterBox:Le.isCharacterBox(Q)}},htmlBuilder:mp,mathmlBuilder:pp});zA({type:"pmb",names:["\\pmb"],props:{numArgs:1,allowedInText:!0},handler(e,A){var{parser:t}=e;return{type:"pmb",mode:t.mode,mclass:sE(A[0]),body:ct(A[0])}},htmlBuilder(e,A){var t=Ft(e.body,A,!0),r=X.makeSpan([e.mclass],t,A);return r.style.textShadow="0.02em 0.01em 0.04px",r},mathmlBuilder(e,A){var t=sr(e.body,A),r=new pA.MathNode("mstyle",t);return r.setAttribute("style","text-shadow: 0.02em 0.01em 0.04px"),r}});var rJ={">":"\\\\cdrightarrow","<":"\\\\cdleftarrow","=":"\\\\cdlongequal",A:"\\uparrow",V:"\\downarrow","|":"\\Vert",".":"no arrow"},Rh=()=>({type:"styling",body:[],mode:"math",style:"display"}),Oh=e=>e.type==="textord"&&e.text==="@",nJ=(e,A)=>(e.type==="mathord"||e.type==="atom")&&e.text===A;function iJ(e,A,t){var r=rJ[e];switch(r){case"\\\\cdrightarrow":case"\\\\cdleftarrow":return t.callFunction(r,[A[0]],[A[1]]);case"\\uparrow":case"\\downarrow":{var n=t.callFunction("\\\\cdleft",[A[0]],[]),i={type:"atom",text:r,mode:"math",family:"rel"},o=t.callFunction("\\Big",[i],[]),g=t.callFunction("\\\\cdright",[A[1]],[]),Q={type:"ordgroup",mode:"math",body:[n,o,g]};return t.callFunction("\\\\cdparent",[Q],[])}case"\\\\cdlongequal":return t.callFunction("\\\\cdlongequal",[],[]);case"\\Vert":{var B={type:"textord",text:"\\Vert",mode:"math"};return t.callFunction("\\Big",[B],[])}default:return{type:"textord",text:" ",mode:"math"}}}function oJ(e){var A=[];for(e.gullet.beginGroup(),e.gullet.macros.set("\\cr","\\\\\\relax"),e.gullet.beginGroup();;){A.push(e.parseExpression(!1,"\\\\")),e.gullet.endGroup(),e.gullet.beginGroup();var t=e.fetch().text;if(t==="&"||t==="\\\\")e.consume();else if(t==="\\end"){A[A.length-1].length===0&&A.pop();break}else throw new NA("Expected \\\\ or \\cr or \\end",e.nextToken)}for(var r=[],n=[r],i=0;i-1))if("<>AV".indexOf(B)>-1)for(var s=0;s<2;s++){for(var C=!0,E=Q+1;EAV=|." after @',o[Q]);var I=iJ(B,a,e),c={type:"styling",body:[I],mode:"math",style:"display"};r.push(c),g=Rh()}i%2===0?r.push(g):r.shift(),r=[],n.push(r)}e.gullet.endGroup(),e.gullet.endGroup();var u=new Array(n[0].length).fill({type:"align",align:"c",pregap:.25,postgap:.25});return{type:"array",mode:"math",body:n,arraystretch:1,addJot:!0,rowGaps:[null],cols:u,colSeparationType:"CD",hLinesBeforeRow:new Array(n.length+1).fill([])}}zA({type:"cdlabel",names:["\\\\cdleft","\\\\cdright"],props:{numArgs:1},handler(e,A){var{parser:t,funcName:r}=e;return{type:"cdlabel",mode:t.mode,side:r.slice(4),label:A[0]}},htmlBuilder(e,A){var t=A.havingStyle(A.style.sup()),r=X.wrapFragment(Ue(e.label,t,A),A);return r.classes.push("cd-label-"+e.side),r.style.bottom=UA(.8-r.depth),r.height=0,r.depth=0,r},mathmlBuilder(e,A){var t=new pA.MathNode("mrow",[Ve(e.label,A)]);return t=new pA.MathNode("mpadded",[t]),t.setAttribute("width","0"),e.side==="left"&&t.setAttribute("lspace","-1width"),t.setAttribute("voffset","0.7em"),t=new pA.MathNode("mstyle",[t]),t.setAttribute("displaystyle","false"),t.setAttribute("scriptlevel","1"),t}});zA({type:"cdlabelparent",names:["\\\\cdparent"],props:{numArgs:1},handler(e,A){var{parser:t}=e;return{type:"cdlabelparent",mode:t.mode,fragment:A[0]}},htmlBuilder(e,A){var t=X.wrapFragment(Ue(e.fragment,A),A);return t.classes.push("cd-vert-arrow"),t},mathmlBuilder(e,A){return new pA.MathNode("mrow",[Ve(e.fragment,A)])}});zA({type:"textord",names:["\\@char"],props:{numArgs:1,allowedInText:!0},handler(e,A){for(var{parser:t}=e,r=De(A[0],"ordgroup"),n=r.body,i="",o=0;o=1114111)throw new NA("\\@char with invalid code point "+i);return Q<=65535?B=String.fromCharCode(Q):(Q-=65536,B=String.fromCharCode((Q>>10)+55296,(Q&1023)+56320)),{type:"textord",mode:t.mode,text:B}}});var kp=(e,A)=>{var t=Ft(e.body,A.withColor(e.color),!1);return X.makeFragment(t)},yp=(e,A)=>{var t=sr(e.body,A.withColor(e.color)),r=new pA.MathNode("mstyle",t);return r.setAttribute("mathcolor",e.color),r};zA({type:"color",names:["\\textcolor"],props:{numArgs:2,allowedInText:!0,argTypes:["color","original"]},handler(e,A){var{parser:t}=e,r=De(A[0],"color-token").color,n=A[1];return{type:"color",mode:t.mode,color:r,body:ct(n)}},htmlBuilder:kp,mathmlBuilder:yp});zA({type:"color",names:["\\color"],props:{numArgs:1,allowedInText:!0,argTypes:["color"]},handler(e,A){var{parser:t,breakOnTokenText:r}=e,n=De(A[0],"color-token").color;t.gullet.macros.set("\\current@color",n);var i=t.parseExpression(!0,r);return{type:"color",mode:t.mode,color:n,body:i}},htmlBuilder:kp,mathmlBuilder:yp});zA({type:"cr",names:["\\\\"],props:{numArgs:0,numOptionalArgs:0,allowedInText:!0},handler(e,A,t){var{parser:r}=e,n=r.gullet.future().text==="["?r.parseSizeGroup(!0):null,i=!r.settings.displayMode||!r.settings.useStrictBehavior("newLineInDisplayMode","In LaTeX, \\\\ or \\newline does nothing in display mode");return{type:"cr",mode:r.mode,newLine:i,size:n&&De(n,"size").value}},htmlBuilder(e,A){var t=X.makeSpan(["mspace"],[],A);return e.newLine&&(t.classes.push("newline"),e.size&&(t.style.marginTop=UA(gt(e.size,A)))),t},mathmlBuilder(e,A){var t=new pA.MathNode("mspace");return e.newLine&&(t.setAttribute("linebreak","newline"),e.size&&t.setAttribute("height",UA(gt(e.size,A)))),t}});var el={"\\global":"\\global","\\long":"\\\\globallong","\\\\globallong":"\\\\globallong","\\def":"\\gdef","\\gdef":"\\gdef","\\edef":"\\xdef","\\xdef":"\\xdef","\\let":"\\\\globallet","\\futurelet":"\\\\globalfuture"},Mp=e=>{var A=e.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(A))throw new NA("Expected a control sequence",e);return A},gJ=e=>{var A=e.gullet.popToken();return A.text==="="&&(A=e.gullet.popToken(),A.text===" "&&(A=e.gullet.popToken())),A},Np=(e,A,t,r)=>{var n=e.gullet.macros.get(t.text);n==null&&(t.noexpand=!0,n={tokens:[t],numArgs:0,unexpandable:!e.gullet.isExpandable(t.text)}),e.gullet.macros.set(A,n,r)};zA({type:"internal",names:["\\global","\\long","\\\\globallong"],props:{numArgs:0,allowedInText:!0},handler(e){var{parser:A,funcName:t}=e;A.consumeSpaces();var r=A.fetch();if(el[r.text])return(t==="\\global"||t==="\\\\globallong")&&(r.text=el[r.text]),De(A.parseFunction(),"internal");throw new NA("Invalid token after macro prefix",r)}});zA({type:"internal",names:["\\def","\\gdef","\\edef","\\xdef"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(e){var{parser:A,funcName:t}=e,r=A.gullet.popToken(),n=r.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(n))throw new NA("Expected a control sequence",r);for(var i=0,o,g=[[]];A.gullet.future().text!=="{";)if(r=A.gullet.popToken(),r.text==="#"){if(A.gullet.future().text==="{"){o=A.gullet.future(),g[i].push("{");break}if(r=A.gullet.popToken(),!/^[1-9]$/.test(r.text))throw new NA('Invalid argument number "'+r.text+'"');if(parseInt(r.text)!==i+1)throw new NA('Argument number "'+r.text+'" out of order');i++,g.push([])}else{if(r.text==="EOF")throw new NA("Expected a macro definition");g[i].push(r.text)}var{tokens:Q}=A.gullet.consumeArg();return o&&Q.unshift(o),(t==="\\edef"||t==="\\xdef")&&(Q=A.gullet.expandTokens(Q),Q.reverse()),A.gullet.macros.set(n,{tokens:Q,numArgs:i,delimiters:g},t===el[t]),{type:"internal",mode:A.mode}}});zA({type:"internal",names:["\\let","\\\\globallet"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(e){var{parser:A,funcName:t}=e,r=Mp(A.gullet.popToken());A.gullet.consumeSpaces();var n=gJ(A);return Np(A,r,n,t==="\\\\globallet"),{type:"internal",mode:A.mode}}});zA({type:"internal",names:["\\futurelet","\\\\globalfuture"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(e){var{parser:A,funcName:t}=e,r=Mp(A.gullet.popToken()),n=A.gullet.popToken(),i=A.gullet.popToken();return Np(A,r,i,t==="\\\\globalfuture"),A.gullet.pushToken(i),A.gullet.pushToken(n),{type:"internal",mode:A.mode}}});var bQ=function(A,t,r){var n=Ze.math[A]&&Ze.math[A].replace,i=Rc(n||A,t,r);if(!i)throw new Error("Unsupported symbol "+A+" and font size "+t+".");return i},Pc=function(A,t,r,n){var i=r.havingBaseStyle(t),o=X.makeSpan(n.concat(i.sizingClasses(r)),[A],r),g=i.sizeMultiplier/r.sizeMultiplier;return o.height*=g,o.depth*=g,o.maxFontSize=i.sizeMultiplier,o},vp=function(A,t,r){var n=t.havingBaseStyle(r),i=(1-t.sizeMultiplier/n.sizeMultiplier)*t.fontMetrics().axisHeight;A.classes.push("delimcenter"),A.style.top=UA(i),A.height-=i,A.depth+=i},QJ=function(A,t,r,n,i,o){var g=X.makeSymbol(A,"Main-Regular",i,n),Q=Pc(g,t,n,o);return r&&vp(Q,n,t),Q},BJ=function(A,t,r,n){return X.makeSymbol(A,"Size"+t+"-Regular",r,n)},bp=function(A,t,r,n,i,o){var g=BJ(A,t,i,n),Q=Pc(X.makeSpan(["delimsizing","size"+t],[g],n),oe.TEXT,n,o);return r&&vp(Q,n,oe.TEXT),Q},FC=function(A,t,r){var n;t==="Size1-Regular"?n="delim-size1":n="delim-size4";var i=X.makeSpan(["delimsizinginner",n],[X.makeSpan([],[X.makeSymbol(A,t,r)])]);return{type:"elem",elem:i}},xC=function(A,t,r){var n=un["Size4-Regular"][A.charCodeAt(0)]?un["Size4-Regular"][A.charCodeAt(0)][4]:un["Size1-Regular"][A.charCodeAt(0)][4],i=new Oi("inner",IS(A,Math.round(1e3*t))),o=new ei([i],{width:UA(n),height:UA(t),style:"width:"+UA(n),viewBox:"0 0 "+1e3*n+" "+Math.round(1e3*t),preserveAspectRatio:"xMinYMin"}),g=X.makeSvgSpan([],[o],r);return g.height=t,g.style.height=UA(t),g.style.width=UA(n),{type:"elem",elem:g}},tl=.008,wa={type:"kern",size:-1*tl},aJ=["|","\\lvert","\\rvert","\\vert"],sJ=["\\|","\\lVert","\\rVert","\\Vert"],Fp=function(A,t,r,n,i,o){var g,Q,B,a,s="",C=0;g=B=a=A,Q=null;var E="Size1-Regular";A==="\\uparrow"?B=a="⏐":A==="\\Uparrow"?B=a="‖":A==="\\downarrow"?g=B="⏐":A==="\\Downarrow"?g=B="‖":A==="\\updownarrow"?(g="\\uparrow",B="⏐",a="\\downarrow"):A==="\\Updownarrow"?(g="\\Uparrow",B="‖",a="\\Downarrow"):aJ.includes(A)?(B="∣",s="vert",C=333):sJ.includes(A)?(B="∥",s="doublevert",C=556):A==="["||A==="\\lbrack"?(g="⎡",B="⎢",a="⎣",E="Size4-Regular",s="lbrack",C=667):A==="]"||A==="\\rbrack"?(g="⎤",B="⎥",a="⎦",E="Size4-Regular",s="rbrack",C=667):A==="\\lfloor"||A==="⌊"?(B=g="⎢",a="⎣",E="Size4-Regular",s="lfloor",C=667):A==="\\lceil"||A==="⌈"?(g="⎡",B=a="⎢",E="Size4-Regular",s="lceil",C=667):A==="\\rfloor"||A==="⌋"?(B=g="⎥",a="⎦",E="Size4-Regular",s="rfloor",C=667):A==="\\rceil"||A==="⌉"?(g="⎤",B=a="⎥",E="Size4-Regular",s="rceil",C=667):A==="("||A==="\\lparen"?(g="⎛",B="⎜",a="⎝",E="Size4-Regular",s="lparen",C=875):A===")"||A==="\\rparen"?(g="⎞",B="⎟",a="⎠",E="Size4-Regular",s="rparen",C=875):A==="\\{"||A==="\\lbrace"?(g="⎧",Q="⎨",a="⎩",B="⎪",E="Size4-Regular"):A==="\\}"||A==="\\rbrace"?(g="⎫",Q="⎬",a="⎭",B="⎪",E="Size4-Regular"):A==="\\lgroup"||A==="⟮"?(g="⎧",a="⎩",B="⎪",E="Size4-Regular"):A==="\\rgroup"||A==="⟯"?(g="⎫",a="⎭",B="⎪",E="Size4-Regular"):A==="\\lmoustache"||A==="⎰"?(g="⎧",a="⎭",B="⎪",E="Size4-Regular"):(A==="\\rmoustache"||A==="⎱")&&(g="⎫",a="⎩",B="⎪",E="Size4-Regular");var I=bQ(g,E,i),c=I.height+I.depth,u=bQ(B,E,i),h=u.height+u.depth,d=bQ(a,E,i),f=d.height+d.depth,m=0,k=1;if(Q!==null){var N=bQ(Q,E,i);m=N.height+N.depth,k=2}var F=c+f+m,L=Math.max(0,Math.ceil((t-F)/(k*h))),v=F+L*k*h,O=n.fontMetrics().axisHeight;r&&(O*=n.sizeMultiplier);var W=v/2-O,AA=[];if(s.length>0){var kA=v-c-f,K=Math.round(v*1e3),$=lS(s,Math.round(kA*1e3)),P=new Oi(s,$),SA=(C/1e3).toFixed(3)+"em",fA=(K/1e3).toFixed(3)+"em",MA=new ei([P],{width:SA,height:fA,viewBox:"0 0 "+C+" "+K}),mA=X.makeSvgSpan([],[MA],n);mA.height=K/1e3,mA.style.width=SA,mA.style.height=fA,AA.push({type:"elem",elem:mA})}else{if(AA.push(FC(a,E,i)),AA.push(wa),Q===null){var $A=v-c-f+2*tl;AA.push(xC(B,$A,n))}else{var re=(v-c-f-m)/2+2*tl;AA.push(xC(B,re,n)),AA.push(wa),AA.push(FC(Q,E,i)),AA.push(wa),AA.push(xC(B,re,n))}AA.push(wa),AA.push(FC(g,E,i))}var de=n.havingBaseStyle(oe.TEXT),z=X.makeVList({positionType:"bottom",positionData:W,children:AA},de);return Pc(X.makeSpan(["delimsizing","mult"],[z],de),oe.TEXT,n,o)},GC=80,SC=.08,JC=function(A,t,r,n,i){var o=CS(A,n,r),g=new Oi(A,o),Q=new ei([g],{width:"400em",height:UA(t),viewBox:"0 0 400000 "+r,preserveAspectRatio:"xMinYMin slice"});return X.makeSvgSpan(["hide-tail"],[Q],i)},EJ=function(A,t){var r=t.havingBaseSizing(),n=Jp("\\surd",A*r.sizeMultiplier,Sp,r),i=r.sizeMultiplier,o=Math.max(0,t.minRuleThickness-t.fontMetrics().sqrtRuleThickness),g,Q=0,B=0,a=0,s;return n.type==="small"?(a=1e3+1e3*o+GC,A<1?i=1:A<1.4&&(i=.7),Q=(1+o+SC)/i,B=(1+o)/i,g=JC("sqrtMain",Q,a,o,t),g.style.minWidth="0.853em",s=.833/i):n.type==="large"?(a=(1e3+GC)*zQ[n.size],B=(zQ[n.size]+o)/i,Q=(zQ[n.size]+o+SC)/i,g=JC("sqrtSize"+n.size,Q,a,o,t),g.style.minWidth="1.02em",s=1/i):(Q=A+o+SC,B=A+o,a=Math.floor(1e3*A+o)+GC,g=JC("sqrtTall",Q,a,o,t),g.style.minWidth="0.742em",s=1.056),g.height=B,g.style.height=UA(Q),{span:g,advanceWidth:s,ruleWidth:(t.fontMetrics().sqrtRuleThickness+o)*i}},xp=["(","\\lparen",")","\\rparen","[","\\lbrack","]","\\rbrack","\\{","\\lbrace","\\}","\\rbrace","\\lfloor","\\rfloor","⌊","⌋","\\lceil","\\rceil","⌈","⌉","\\surd"],CJ=["\\uparrow","\\downarrow","\\updownarrow","\\Uparrow","\\Downarrow","\\Updownarrow","|","\\|","\\vert","\\Vert","\\lvert","\\rvert","\\lVert","\\rVert","\\lgroup","\\rgroup","⟮","⟯","\\lmoustache","\\rmoustache","⎰","⎱"],Gp=["<",">","\\langle","\\rangle","/","\\backslash","\\lt","\\gt"],zQ=[0,1.2,1.8,2.4,3],IJ=function(A,t,r,n,i){if(A==="<"||A==="\\lt"||A==="⟨"?A="\\langle":(A===">"||A==="\\gt"||A==="⟩")&&(A="\\rangle"),xp.includes(A)||Gp.includes(A))return bp(A,t,!1,r,n,i);if(CJ.includes(A))return Fp(A,zQ[t],!1,r,n,i);throw new NA("Illegal delimiter: '"+A+"'")},lJ=[{type:"small",style:oe.SCRIPTSCRIPT},{type:"small",style:oe.SCRIPT},{type:"small",style:oe.TEXT},{type:"large",size:1},{type:"large",size:2},{type:"large",size:3},{type:"large",size:4}],cJ=[{type:"small",style:oe.SCRIPTSCRIPT},{type:"small",style:oe.SCRIPT},{type:"small",style:oe.TEXT},{type:"stack"}],Sp=[{type:"small",style:oe.SCRIPTSCRIPT},{type:"small",style:oe.SCRIPT},{type:"small",style:oe.TEXT},{type:"large",size:1},{type:"large",size:2},{type:"large",size:3},{type:"large",size:4},{type:"stack"}],uJ=function(A){if(A.type==="small")return"Main-Regular";if(A.type==="large")return"Size"+A.size+"-Regular";if(A.type==="stack")return"Size4-Regular";throw new Error("Add support for delim type '"+A.type+"' here.")},Jp=function(A,t,r,n){for(var i=Math.min(2,3-n.style.size),o=i;ot)return r[o]}return r[r.length-1]},Up=function(A,t,r,n,i,o){A==="<"||A==="\\lt"||A==="⟨"?A="\\langle":(A===">"||A==="\\gt"||A==="⟩")&&(A="\\rangle");var g;Gp.includes(A)?g=lJ:xp.includes(A)?g=Sp:g=cJ;var Q=Jp(A,t,g,n);return Q.type==="small"?QJ(A,Q.style,r,n,i,o):Q.type==="large"?bp(A,Q.size,r,n,i,o):Fp(A,t,r,n,i,o)},dJ=function(A,t,r,n,i,o){var g=n.fontMetrics().axisHeight*n.sizeMultiplier,Q=901,B=5/n.fontMetrics().ptPerEm,a=Math.max(t-g,r+g),s=Math.max(a/500*Q,2*a-B);return Up(A,s,!0,n,i,o)},Zn={sqrtImage:EJ,sizedDelim:IJ,sizeToMaxHeight:zQ,customSizedDelim:Up,leftRightDelim:dJ},qh={"\\bigl":{mclass:"mopen",size:1},"\\Bigl":{mclass:"mopen",size:2},"\\biggl":{mclass:"mopen",size:3},"\\Biggl":{mclass:"mopen",size:4},"\\bigr":{mclass:"mclose",size:1},"\\Bigr":{mclass:"mclose",size:2},"\\biggr":{mclass:"mclose",size:3},"\\Biggr":{mclass:"mclose",size:4},"\\bigm":{mclass:"mrel",size:1},"\\Bigm":{mclass:"mrel",size:2},"\\biggm":{mclass:"mrel",size:3},"\\Biggm":{mclass:"mrel",size:4},"\\big":{mclass:"mord",size:1},"\\Big":{mclass:"mord",size:2},"\\bigg":{mclass:"mord",size:3},"\\Bigg":{mclass:"mord",size:4}},hJ=["(","\\lparen",")","\\rparen","[","\\lbrack","]","\\rbrack","\\{","\\lbrace","\\}","\\rbrace","\\lfloor","\\rfloor","⌊","⌋","\\lceil","\\rceil","⌈","⌉","<",">","\\langle","⟨","\\rangle","⟩","\\lt","\\gt","\\lvert","\\rvert","\\lVert","\\rVert","\\lgroup","\\rgroup","⟮","⟯","\\lmoustache","\\rmoustache","⎰","⎱","/","\\backslash","|","\\vert","\\|","\\Vert","\\uparrow","\\Uparrow","\\downarrow","\\Downarrow","\\updownarrow","\\Updownarrow","."];function EE(e,A){var t=aE(e);if(t&&hJ.includes(t.text))return t;throw t?new NA("Invalid delimiter '"+t.text+"' after '"+A.funcName+"'",e):new NA("Invalid delimiter type '"+e.type+"'",e)}zA({type:"delimsizing",names:["\\bigl","\\Bigl","\\biggl","\\Biggl","\\bigr","\\Bigr","\\biggr","\\Biggr","\\bigm","\\Bigm","\\biggm","\\Biggm","\\big","\\Big","\\bigg","\\Bigg"],props:{numArgs:1,argTypes:["primitive"]},handler:(e,A)=>{var t=EE(A[0],e);return{type:"delimsizing",mode:e.parser.mode,size:qh[e.funcName].size,mclass:qh[e.funcName].mclass,delim:t.text}},htmlBuilder:(e,A)=>e.delim==="."?X.makeSpan([e.mclass]):Zn.sizedDelim(e.delim,e.size,A,e.mode,[e.mclass]),mathmlBuilder:e=>{var A=[];e.delim!=="."&&A.push(Kr(e.delim,e.mode));var t=new pA.MathNode("mo",A);e.mclass==="mopen"||e.mclass==="mclose"?t.setAttribute("fence","true"):t.setAttribute("fence","false"),t.setAttribute("stretchy","true");var r=UA(Zn.sizeToMaxHeight[e.size]);return t.setAttribute("minsize",r),t.setAttribute("maxsize",r),t}});function Th(e){if(!e.body)throw new Error("Bug: The leftright ParseNode wasn't fully parsed.")}zA({type:"leftright-right",names:["\\right"],props:{numArgs:1,primitive:!0},handler:(e,A)=>{var t=e.parser.gullet.macros.get("\\current@color");if(t&&typeof t!="string")throw new NA("\\current@color set to non-string in \\right");return{type:"leftright-right",mode:e.parser.mode,delim:EE(A[0],e).text,color:t}}});zA({type:"leftright",names:["\\left"],props:{numArgs:1,primitive:!0},handler:(e,A)=>{var t=EE(A[0],e),r=e.parser;++r.leftrightDepth;var n=r.parseExpression(!1);--r.leftrightDepth,r.expect("\\right",!1);var i=De(r.parseFunction(),"leftright-right");return{type:"leftright",mode:r.mode,body:n,left:t.text,right:i.delim,rightColor:i.color}},htmlBuilder:(e,A)=>{Th(e);for(var t=Ft(e.body,A,!0,["mopen","mclose"]),r=0,n=0,i=!1,o=0;o{Th(e);var t=sr(e.body,A);if(e.left!=="."){var r=new pA.MathNode("mo",[Kr(e.left,e.mode)]);r.setAttribute("fence","true"),t.unshift(r)}if(e.right!=="."){var n=new pA.MathNode("mo",[Kr(e.right,e.mode)]);n.setAttribute("fence","true"),e.rightColor&&n.setAttribute("mathcolor",e.rightColor),t.push(n)}return Tc(t)}});zA({type:"middle",names:["\\middle"],props:{numArgs:1,primitive:!0},handler:(e,A)=>{var t=EE(A[0],e);if(!e.parser.leftrightDepth)throw new NA("\\middle without preceding \\left",t);return{type:"middle",mode:e.parser.mode,delim:t.text}},htmlBuilder:(e,A)=>{var t;if(e.delim===".")t=AB(A,[]);else{t=Zn.sizedDelim(e.delim,1,A,e.mode,[]);var r={delim:e.delim,options:A};t.isMiddle=r}return t},mathmlBuilder:(e,A)=>{var t=e.delim==="\\vert"||e.delim==="|"?Kr("|","text"):Kr(e.delim,e.mode),r=new pA.MathNode("mo",[t]);return r.setAttribute("fence","true"),r.setAttribute("lspace","0.05em"),r.setAttribute("rspace","0.05em"),r}});var _c=(e,A)=>{var t=X.wrapFragment(Ue(e.body,A),A),r=e.label.slice(1),n=A.sizeMultiplier,i,o=0,g=Le.isCharacterBox(e.body);if(r==="sout")i=X.makeSpan(["stretchy","sout"]),i.height=A.fontMetrics().defaultRuleThickness/n,o=-.5*A.fontMetrics().xHeight;else if(r==="phase"){var Q=gt({number:.6,unit:"pt"},A),B=gt({number:.35,unit:"ex"},A),a=A.havingBaseSizing();n=n/a.sizeMultiplier;var s=t.height+t.depth+Q+B;t.style.paddingLeft=UA(s/2+Q);var C=Math.floor(1e3*s*n),E=sS(C),I=new ei([new Oi("phase",E)],{width:"400em",height:UA(C/1e3),viewBox:"0 0 400000 "+C,preserveAspectRatio:"xMinYMin slice"});i=X.makeSvgSpan(["hide-tail"],[I],A),i.style.height=UA(s),o=t.depth+Q+B}else{/cancel/.test(r)?g||t.classes.push("cancel-pad"):r==="angl"?t.classes.push("anglpad"):t.classes.push("boxpad");var c=0,u=0,h=0;/box/.test(r)?(h=Math.max(A.fontMetrics().fboxrule,A.minRuleThickness),c=A.fontMetrics().fboxsep+(r==="colorbox"?0:h),u=c):r==="angl"?(h=Math.max(A.fontMetrics().defaultRuleThickness,A.minRuleThickness),c=4*h,u=Math.max(0,.25-t.depth)):(c=g?.2:0,u=c),i=ri.encloseSpan(t,r,c,u,A),/fbox|boxed|fcolorbox/.test(r)?(i.style.borderStyle="solid",i.style.borderWidth=UA(h)):r==="angl"&&h!==.049&&(i.style.borderTopWidth=UA(h),i.style.borderRightWidth=UA(h)),o=t.depth+u,e.backgroundColor&&(i.style.backgroundColor=e.backgroundColor,e.borderColor&&(i.style.borderColor=e.borderColor))}var d;if(e.backgroundColor)d=X.makeVList({positionType:"individualShift",children:[{type:"elem",elem:i,shift:o},{type:"elem",elem:t,shift:0}]},A);else{var f=/cancel|phase/.test(r)?["svg-align"]:[];d=X.makeVList({positionType:"individualShift",children:[{type:"elem",elem:t,shift:0},{type:"elem",elem:i,shift:o,wrapperClasses:f}]},A)}return/cancel/.test(r)&&(d.height=t.height,d.depth=t.depth),/cancel/.test(r)&&!g?X.makeSpan(["mord","cancel-lap"],[d],A):X.makeSpan(["mord"],[d],A)},jc=(e,A)=>{var t=0,r=new pA.MathNode(e.label.indexOf("colorbox")>-1?"mpadded":"menclose",[Ve(e.body,A)]);switch(e.label){case"\\cancel":r.setAttribute("notation","updiagonalstrike");break;case"\\bcancel":r.setAttribute("notation","downdiagonalstrike");break;case"\\phase":r.setAttribute("notation","phasorangle");break;case"\\sout":r.setAttribute("notation","horizontalstrike");break;case"\\fbox":r.setAttribute("notation","box");break;case"\\angl":r.setAttribute("notation","actuarial");break;case"\\fcolorbox":case"\\colorbox":if(t=A.fontMetrics().fboxsep*A.fontMetrics().ptPerEm,r.setAttribute("width","+"+2*t+"pt"),r.setAttribute("height","+"+2*t+"pt"),r.setAttribute("lspace",t+"pt"),r.setAttribute("voffset",t+"pt"),e.label==="\\fcolorbox"){var n=Math.max(A.fontMetrics().fboxrule,A.minRuleThickness);r.setAttribute("style","border: "+n+"em solid "+String(e.borderColor))}break;case"\\xcancel":r.setAttribute("notation","updiagonalstrike downdiagonalstrike");break}return e.backgroundColor&&r.setAttribute("mathbackground",e.backgroundColor),r};zA({type:"enclose",names:["\\colorbox"],props:{numArgs:2,allowedInText:!0,argTypes:["color","text"]},handler(e,A,t){var{parser:r,funcName:n}=e,i=De(A[0],"color-token").color,o=A[1];return{type:"enclose",mode:r.mode,label:n,backgroundColor:i,body:o}},htmlBuilder:_c,mathmlBuilder:jc});zA({type:"enclose",names:["\\fcolorbox"],props:{numArgs:3,allowedInText:!0,argTypes:["color","color","text"]},handler(e,A,t){var{parser:r,funcName:n}=e,i=De(A[0],"color-token").color,o=De(A[1],"color-token").color,g=A[2];return{type:"enclose",mode:r.mode,label:n,backgroundColor:o,borderColor:i,body:g}},htmlBuilder:_c,mathmlBuilder:jc});zA({type:"enclose",names:["\\fbox"],props:{numArgs:1,argTypes:["hbox"],allowedInText:!0},handler(e,A){var{parser:t}=e;return{type:"enclose",mode:t.mode,label:"\\fbox",body:A[0]}}});zA({type:"enclose",names:["\\cancel","\\bcancel","\\xcancel","\\sout","\\phase"],props:{numArgs:1},handler(e,A){var{parser:t,funcName:r}=e,n=A[0];return{type:"enclose",mode:t.mode,label:r,body:n}},htmlBuilder:_c,mathmlBuilder:jc});zA({type:"enclose",names:["\\angl"],props:{numArgs:1,argTypes:["hbox"],allowedInText:!1},handler(e,A){var{parser:t}=e;return{type:"enclose",mode:t.mode,label:"\\angl",body:A[0]}}});var Kp={};function Nn(e){for(var{type:A,names:t,props:r,handler:n,htmlBuilder:i,mathmlBuilder:o}=e,g={type:A,numArgs:r.numArgs||0,allowedInText:!1,numOptionalArgs:0,handler:n},Q=0;Q{var A=e.parser.settings;if(!A.displayMode)throw new NA("{"+e.envName+"} can be used only in display mode.")};function Vc(e){if(e.indexOf("ed")===-1)return e.indexOf("*")===-1}function Vi(e,A,t){var{hskipBeforeAndAfter:r,addJot:n,cols:i,arraystretch:o,colSeparationType:g,autoTag:Q,singleRow:B,emptySingleRow:a,maxNumCols:s,leqno:C}=A;if(e.gullet.beginGroup(),B||e.gullet.macros.set("\\cr","\\\\\\relax"),!o){var E=e.gullet.expandMacroAsText("\\arraystretch");if(E==null)o=1;else if(o=parseFloat(E),!o||o<0)throw new NA("Invalid \\arraystretch: "+E)}e.gullet.beginGroup();var I=[],c=[I],u=[],h=[],d=Q!=null?[]:void 0;function f(){Q&&e.gullet.macros.set("\\@eqnsw","1",!0)}function m(){d&&(e.gullet.macros.get("\\df@tag")?(d.push(e.subparse([new fr("\\df@tag")])),e.gullet.macros.set("\\df@tag",void 0,!0)):d.push(!!Q&&e.gullet.macros.get("\\@eqnsw")==="1"))}for(f(),h.push(Hh(e));;){var k=e.parseExpression(!1,B?"\\end":"\\\\");e.gullet.endGroup(),e.gullet.beginGroup(),k={type:"ordgroup",mode:e.mode,body:k},t&&(k={type:"styling",mode:e.mode,style:t,body:[k]}),I.push(k);var N=e.fetch().text;if(N==="&"){if(s&&I.length===s){if(B||g)throw new NA("Too many tab characters: &",e.nextToken);e.settings.reportNonstrict("textEnv","Too few columns specified in the {array} column argument.")}e.consume()}else if(N==="\\end"){m(),I.length===1&&k.type==="styling"&&k.body[0].body.length===0&&(c.length>1||!a)&&c.pop(),h.length0&&(f+=.25),B.push({pos:f,isDashed:EA[BA]})}for(m(o[0]),r=0;r0&&(W+=d,FEA))for(r=0;r=g)){var rA=void 0;(n>0||A.hskipBeforeAndAfter)&&(rA=Le.deflt(re.pregap,C),rA!==0&&($=X.makeSpan(["arraycolsep"],[]),$.style.width=UA(rA),K.push($)));var V=[];for(r=0;r0){for(var yA=X.makeLineSpan("hline",t,a),PA=X.makeLineSpan("hdashline",t,a),Z=[{type:"elem",elem:Q,shift:0}];B.length>0;){var x=B.pop(),j=x.pos-AA;x.isDashed?Z.push({type:"elem",elem:PA,shift:j}):Z.push({type:"elem",elem:yA,shift:j})}Q=X.makeVList({positionType:"individualShift",children:Z},t)}if(SA.length===0)return X.makeSpan(["mord"],[Q],t);var nA=X.makeVList({positionType:"individualShift",children:SA},t);return nA=X.makeSpan(["tag"],[nA],t),X.makeFragment([Q,nA])},DJ={c:"center ",l:"left ",r:"right "},bn=function(A,t){for(var r=[],n=new pA.MathNode("mtd",[],["mtr-glue"]),i=new pA.MathNode("mtd",[],["mml-eqn-num"]),o=0;o0){var I=A.cols,c="",u=!1,h=0,d=I.length;I[0].type==="separator"&&(C+="top ",h=1),I[I.length-1].type==="separator"&&(C+="bottom ",d-=1);for(var f=h;f0?"left ":"",C+=L[L.length-1].length>0?"right ":"";for(var v=1;v-1?"alignat":"align",i=A.envName==="split",o=Vi(A.parser,{cols:r,addJot:!0,autoTag:i?void 0:Vc(A.envName),emptySingleRow:!0,colSeparationType:n,maxNumCols:i?2:void 0,leqno:A.parser.settings.leqno},"display"),g,Q=0,B={type:"ordgroup",mode:A.mode,body:[]};if(t[0]&&t[0].type==="ordgroup"){for(var a="",s=0;s0&&E&&(u=1),r[I]={type:"align",align:c,pregap:u,postgap:0}}return o.colSeparationType=E?"align":"alignat",o};Nn({type:"array",names:["array","darray"],props:{numArgs:1},handler(e,A){var t=aE(A[0]),r=t?[A[0]]:De(A[0],"ordgroup").body,n=r.map(function(o){var g=Yc(o),Q=g.text;if("lcr".indexOf(Q)!==-1)return{type:"align",align:Q};if(Q==="|")return{type:"separator",separator:"|"};if(Q===":")return{type:"separator",separator:":"};throw new NA("Unknown column alignment: "+Q,o)}),i={cols:n,hskipBeforeAndAfter:!0,maxNumCols:n.length};return Vi(e.parser,i,Wc(e.envName))},htmlBuilder:vn,mathmlBuilder:bn});Nn({type:"array",names:["matrix","pmatrix","bmatrix","Bmatrix","vmatrix","Vmatrix","matrix*","pmatrix*","bmatrix*","Bmatrix*","vmatrix*","Vmatrix*"],props:{numArgs:0},handler(e){var A={matrix:null,pmatrix:["(",")"],bmatrix:["[","]"],Bmatrix:["\\{","\\}"],vmatrix:["|","|"],Vmatrix:["\\Vert","\\Vert"]}[e.envName.replace("*","")],t="c",r={hskipBeforeAndAfter:!1,cols:[{type:"align",align:t}]};if(e.envName.charAt(e.envName.length-1)==="*"){var n=e.parser;if(n.consumeSpaces(),n.fetch().text==="["){if(n.consume(),n.consumeSpaces(),t=n.fetch().text,"lcr".indexOf(t)===-1)throw new NA("Expected l or c or r",n.nextToken);n.consume(),n.consumeSpaces(),n.expect("]"),n.consume(),r.cols=[{type:"align",align:t}]}}var i=Vi(e.parser,r,Wc(e.envName)),o=Math.max(0,...i.body.map(g=>g.length));return i.cols=new Array(o).fill({type:"align",align:t}),A?{type:"leftright",mode:e.mode,body:[i],left:A[0],right:A[1],rightColor:void 0}:i},htmlBuilder:vn,mathmlBuilder:bn});Nn({type:"array",names:["smallmatrix"],props:{numArgs:0},handler(e){var A={arraystretch:.5},t=Vi(e.parser,A,"script");return t.colSeparationType="small",t},htmlBuilder:vn,mathmlBuilder:bn});Nn({type:"array",names:["subarray"],props:{numArgs:1},handler(e,A){var t=aE(A[0]),r=t?[A[0]]:De(A[0],"ordgroup").body,n=r.map(function(o){var g=Yc(o),Q=g.text;if("lc".indexOf(Q)!==-1)return{type:"align",align:Q};throw new NA("Unknown column alignment: "+Q,o)});if(n.length>1)throw new NA("{subarray} can contain only one column");var i={cols:n,hskipBeforeAndAfter:!1,arraystretch:.5};if(i=Vi(e.parser,i,"script"),i.body.length>0&&i.body[0].length>1)throw new NA("{subarray} can contain only one column");return i},htmlBuilder:vn,mathmlBuilder:bn});Nn({type:"array",names:["cases","dcases","rcases","drcases"],props:{numArgs:0},handler(e){var A={arraystretch:1.2,cols:[{type:"align",align:"l",pregap:0,postgap:1},{type:"align",align:"l",pregap:0,postgap:0}]},t=Vi(e.parser,A,Wc(e.envName));return{type:"leftright",mode:e.mode,body:[t],left:e.envName.indexOf("r")>-1?".":"\\{",right:e.envName.indexOf("r")>-1?"\\}":".",rightColor:void 0}},htmlBuilder:vn,mathmlBuilder:bn});Nn({type:"array",names:["align","align*","aligned","split"],props:{numArgs:0},handler:Rp,htmlBuilder:vn,mathmlBuilder:bn});Nn({type:"array",names:["gathered","gather","gather*"],props:{numArgs:0},handler(e){["gather","gather*"].includes(e.envName)&&CE(e);var A={cols:[{type:"align",align:"c"}],addJot:!0,colSeparationType:"gather",autoTag:Vc(e.envName),emptySingleRow:!0,leqno:e.parser.settings.leqno};return Vi(e.parser,A,"display")},htmlBuilder:vn,mathmlBuilder:bn});Nn({type:"array",names:["alignat","alignat*","alignedat"],props:{numArgs:1},handler:Rp,htmlBuilder:vn,mathmlBuilder:bn});Nn({type:"array",names:["equation","equation*"],props:{numArgs:0},handler(e){CE(e);var A={autoTag:Vc(e.envName),emptySingleRow:!0,singleRow:!0,maxNumCols:1,leqno:e.parser.settings.leqno};return Vi(e.parser,A,"display")},htmlBuilder:vn,mathmlBuilder:bn});Nn({type:"array",names:["CD"],props:{numArgs:0},handler(e){return CE(e),oJ(e.parser)},htmlBuilder:vn,mathmlBuilder:bn});b("\\nonumber","\\gdef\\@eqnsw{0}");b("\\notag","\\nonumber");zA({type:"text",names:["\\hline","\\hdashline"],props:{numArgs:0,allowedInText:!0,allowedInMath:!0},handler(e,A){throw new NA(e.funcName+" valid only within array environment")}});var Yh=Kp;zA({type:"environment",names:["\\begin","\\end"],props:{numArgs:1,argTypes:["text"]},handler(e,A){var{parser:t,funcName:r}=e,n=A[0];if(n.type!=="ordgroup")throw new NA("Invalid environment name",n);for(var i="",o=0;o{var t=e.font,r=A.withFont(t);return Ue(e.body,r)},qp=(e,A)=>{var t=e.font,r=A.withFont(t);return Ve(e.body,r)},zh={"\\Bbb":"\\mathbb","\\bold":"\\mathbf","\\frak":"\\mathfrak","\\bm":"\\boldsymbol"};zA({type:"font",names:["\\mathrm","\\mathit","\\mathbf","\\mathnormal","\\mathsfit","\\mathbb","\\mathcal","\\mathfrak","\\mathscr","\\mathsf","\\mathtt","\\Bbb","\\bold","\\frak"],props:{numArgs:1,allowedInArgument:!0},handler:(e,A)=>{var{parser:t,funcName:r}=e,n=ws(A[0]),i=r;return i in zh&&(i=zh[i]),{type:"font",mode:t.mode,font:i.slice(1),body:n}},htmlBuilder:Op,mathmlBuilder:qp});zA({type:"mclass",names:["\\boldsymbol","\\bm"],props:{numArgs:1},handler:(e,A)=>{var{parser:t}=e,r=A[0],n=Le.isCharacterBox(r);return{type:"mclass",mode:t.mode,mclass:sE(r),body:[{type:"font",mode:t.mode,font:"boldsymbol",body:r}],isCharacterBox:n}}});zA({type:"font",names:["\\rm","\\sf","\\tt","\\bf","\\it","\\cal"],props:{numArgs:0,allowedInText:!0},handler:(e,A)=>{var{parser:t,funcName:r,breakOnTokenText:n}=e,{mode:i}=t,o=t.parseExpression(!0,n),g="math"+r.slice(1);return{type:"font",mode:i,font:g,body:{type:"ordgroup",mode:t.mode,body:o}}},htmlBuilder:Op,mathmlBuilder:qp});var Tp=(e,A)=>{var t=A;return e==="display"?t=t.id>=oe.SCRIPT.id?t.text():oe.DISPLAY:e==="text"&&t.size===oe.DISPLAY.size?t=oe.TEXT:e==="script"?t=oe.SCRIPT:e==="scriptscript"&&(t=oe.SCRIPTSCRIPT),t},Zc=(e,A)=>{var t=Tp(e.size,A.style),r=t.fracNum(),n=t.fracDen(),i;i=A.havingStyle(r);var o=Ue(e.numer,i,A);if(e.continued){var g=8.5/A.fontMetrics().ptPerEm,Q=3.5/A.fontMetrics().ptPerEm;o.height=o.height0?I=3*C:I=7*C,c=A.fontMetrics().denom1):(s>0?(E=A.fontMetrics().num2,I=C):(E=A.fontMetrics().num3,I=3*C),c=A.fontMetrics().denom2);var u;if(a){var d=A.fontMetrics().axisHeight;E-o.depth-(d+.5*s){var t=new pA.MathNode("mfrac",[Ve(e.numer,A),Ve(e.denom,A)]);if(!e.hasBarLine)t.setAttribute("linethickness","0px");else if(e.barSize){var r=gt(e.barSize,A);t.setAttribute("linethickness",UA(r))}var n=Tp(e.size,A.style);if(n.size!==A.style.size){t=new pA.MathNode("mstyle",[t]);var i=n.size===oe.DISPLAY.size?"true":"false";t.setAttribute("displaystyle",i),t.setAttribute("scriptlevel","0")}if(e.leftDelim!=null||e.rightDelim!=null){var o=[];if(e.leftDelim!=null){var g=new pA.MathNode("mo",[new pA.TextNode(e.leftDelim.replace("\\",""))]);g.setAttribute("fence","true"),o.push(g)}if(o.push(t),e.rightDelim!=null){var Q=new pA.MathNode("mo",[new pA.TextNode(e.rightDelim.replace("\\",""))]);Q.setAttribute("fence","true"),o.push(Q)}return Tc(o)}return t};zA({type:"genfrac",names:["\\dfrac","\\frac","\\tfrac","\\dbinom","\\binom","\\tbinom","\\\\atopfrac","\\\\bracefrac","\\\\brackfrac"],props:{numArgs:2,allowedInArgument:!0},handler:(e,A)=>{var{parser:t,funcName:r}=e,n=A[0],i=A[1],o,g=null,Q=null,B="auto";switch(r){case"\\dfrac":case"\\frac":case"\\tfrac":o=!0;break;case"\\\\atopfrac":o=!1;break;case"\\dbinom":case"\\binom":case"\\tbinom":o=!1,g="(",Q=")";break;case"\\\\bracefrac":o=!1,g="\\{",Q="\\}";break;case"\\\\brackfrac":o=!1,g="[",Q="]";break;default:throw new Error("Unrecognized genfrac command")}switch(r){case"\\dfrac":case"\\dbinom":B="display";break;case"\\tfrac":case"\\tbinom":B="text";break}return{type:"genfrac",mode:t.mode,continued:!1,numer:n,denom:i,hasBarLine:o,leftDelim:g,rightDelim:Q,size:B,barSize:null}},htmlBuilder:Zc,mathmlBuilder:Xc});zA({type:"genfrac",names:["\\cfrac"],props:{numArgs:2},handler:(e,A)=>{var{parser:t,funcName:r}=e,n=A[0],i=A[1];return{type:"genfrac",mode:t.mode,continued:!0,numer:n,denom:i,hasBarLine:!0,leftDelim:null,rightDelim:null,size:"display",barSize:null}}});zA({type:"infix",names:["\\over","\\choose","\\atop","\\brace","\\brack"],props:{numArgs:0,infix:!0},handler(e){var{parser:A,funcName:t,token:r}=e,n;switch(t){case"\\over":n="\\frac";break;case"\\choose":n="\\binom";break;case"\\atop":n="\\\\atopfrac";break;case"\\brace":n="\\\\bracefrac";break;case"\\brack":n="\\\\brackfrac";break;default:throw new Error("Unrecognized infix genfrac command")}return{type:"infix",mode:A.mode,replaceWith:n,token:r}}});var Ph=["display","text","script","scriptscript"],_h=function(A){var t=null;return A.length>0&&(t=A,t=t==="."?null:t),t};zA({type:"genfrac",names:["\\genfrac"],props:{numArgs:6,allowedInArgument:!0,argTypes:["math","math","size","text","math","math"]},handler(e,A){var{parser:t}=e,r=A[4],n=A[5],i=ws(A[0]),o=i.type==="atom"&&i.family==="open"?_h(i.text):null,g=ws(A[1]),Q=g.type==="atom"&&g.family==="close"?_h(g.text):null,B=De(A[2],"size"),a,s=null;B.isBlank?a=!0:(s=B.value,a=s.number>0);var C="auto",E=A[3];if(E.type==="ordgroup"){if(E.body.length>0){var I=De(E.body[0],"textord");C=Ph[Number(I.text)]}}else E=De(E,"textord"),C=Ph[Number(E.text)];return{type:"genfrac",mode:t.mode,numer:r,denom:n,continued:!1,hasBarLine:a,barSize:s,leftDelim:o,rightDelim:Q,size:C}},htmlBuilder:Zc,mathmlBuilder:Xc});zA({type:"infix",names:["\\above"],props:{numArgs:1,argTypes:["size"],infix:!0},handler(e,A){var{parser:t,funcName:r,token:n}=e;return{type:"infix",mode:t.mode,replaceWith:"\\\\abovefrac",size:De(A[0],"size").value,token:n}}});zA({type:"genfrac",names:["\\\\abovefrac"],props:{numArgs:3,argTypes:["math","size","math"]},handler:(e,A)=>{var{parser:t,funcName:r}=e,n=A[0],i=W3(De(A[1],"infix").size),o=A[2],g=i.number>0;return{type:"genfrac",mode:t.mode,numer:n,denom:o,continued:!1,hasBarLine:g,barSize:i,leftDelim:null,rightDelim:null,size:"auto"}},htmlBuilder:Zc,mathmlBuilder:Xc});var Hp=(e,A)=>{var t=A.style,r,n;e.type==="supsub"?(r=e.sup?Ue(e.sup,A.havingStyle(t.sup()),A):Ue(e.sub,A.havingStyle(t.sub()),A),n=De(e.base,"horizBrace")):n=De(e,"horizBrace");var i=Ue(n.base,A.havingBaseStyle(oe.DISPLAY)),o=ri.svgSpan(n,A),g;if(n.isOver?(g=X.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:i},{type:"kern",size:.1},{type:"elem",elem:o}]},A),g.children[0].children[0].children[1].classes.push("svg-align")):(g=X.makeVList({positionType:"bottom",positionData:i.depth+.1+o.height,children:[{type:"elem",elem:o},{type:"kern",size:.1},{type:"elem",elem:i}]},A),g.children[0].children[0].children[0].classes.push("svg-align")),r){var Q=X.makeSpan(["mord",n.isOver?"mover":"munder"],[g],A);n.isOver?g=X.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:Q},{type:"kern",size:.2},{type:"elem",elem:r}]},A):g=X.makeVList({positionType:"bottom",positionData:Q.depth+.2+r.height+r.depth,children:[{type:"elem",elem:r},{type:"kern",size:.2},{type:"elem",elem:Q}]},A)}return X.makeSpan(["mord",n.isOver?"mover":"munder"],[g],A)},fJ=(e,A)=>{var t=ri.mathMLnode(e.label);return new pA.MathNode(e.isOver?"mover":"munder",[Ve(e.base,A),t])};zA({type:"horizBrace",names:["\\overbrace","\\underbrace"],props:{numArgs:1},handler(e,A){var{parser:t,funcName:r}=e;return{type:"horizBrace",mode:t.mode,label:r,isOver:/^\\over/.test(r),base:A[0]}},htmlBuilder:Hp,mathmlBuilder:fJ});zA({type:"href",names:["\\href"],props:{numArgs:2,argTypes:["url","original"],allowedInText:!0},handler:(e,A)=>{var{parser:t}=e,r=A[1],n=De(A[0],"url").url;return t.settings.isTrusted({command:"\\href",url:n})?{type:"href",mode:t.mode,href:n,body:ct(r)}:t.formatUnsupportedCmd("\\href")},htmlBuilder:(e,A)=>{var t=Ft(e.body,A,!1);return X.makeAnchor(e.href,[],t,A)},mathmlBuilder:(e,A)=>{var t=qi(e.body,A);return t instanceof dr||(t=new dr("mrow",[t])),t.setAttribute("href",e.href),t}});zA({type:"href",names:["\\url"],props:{numArgs:1,argTypes:["url"],allowedInText:!0},handler:(e,A)=>{var{parser:t}=e,r=De(A[0],"url").url;if(!t.settings.isTrusted({command:"\\url",url:r}))return t.formatUnsupportedCmd("\\url");for(var n=[],i=0;i{var{parser:t,funcName:r,token:n}=e,i=De(A[0],"raw").string,o=A[1];t.settings.strict&&t.settings.reportNonstrict("htmlExtension","HTML extension is disabled on strict mode");var g,Q={};switch(r){case"\\htmlClass":Q.class=i,g={command:"\\htmlClass",class:i};break;case"\\htmlId":Q.id=i,g={command:"\\htmlId",id:i};break;case"\\htmlStyle":Q.style=i,g={command:"\\htmlStyle",style:i};break;case"\\htmlData":{for(var B=i.split(","),a=0;a{var t=Ft(e.body,A,!1),r=["enclosing"];e.attributes.class&&r.push(...e.attributes.class.trim().split(/\s+/));var n=X.makeSpan(r,t,A);for(var i in e.attributes)i!=="class"&&e.attributes.hasOwnProperty(i)&&n.setAttribute(i,e.attributes[i]);return n},mathmlBuilder:(e,A)=>qi(e.body,A)});zA({type:"htmlmathml",names:["\\html@mathml"],props:{numArgs:2,allowedInText:!0},handler:(e,A)=>{var{parser:t}=e;return{type:"htmlmathml",mode:t.mode,html:ct(A[0]),mathml:ct(A[1])}},htmlBuilder:(e,A)=>{var t=Ft(e.html,A,!1);return X.makeFragment(t)},mathmlBuilder:(e,A)=>qi(e.mathml,A)});var UC=function(A){if(/^[-+]? *(\d+(\.\d*)?|\.\d+)$/.test(A))return{number:+A,unit:"bp"};var t=/([-+]?) *(\d+(?:\.\d*)?|\.\d+) *([a-z]{2})/.exec(A);if(!t)throw new NA("Invalid size: '"+A+"' in \\includegraphics");var r={number:+(t[1]+t[2]),unit:t[3]};if(!Qp(r))throw new NA("Invalid unit: '"+r.unit+"' in \\includegraphics.");return r};zA({type:"includegraphics",names:["\\includegraphics"],props:{numArgs:1,numOptionalArgs:1,argTypes:["raw","url"],allowedInText:!1},handler:(e,A,t)=>{var{parser:r}=e,n={number:0,unit:"em"},i={number:.9,unit:"em"},o={number:0,unit:"em"},g="";if(t[0])for(var Q=De(t[0],"raw").string,B=Q.split(","),a=0;a{var t=gt(e.height,A),r=0;e.totalheight.number>0&&(r=gt(e.totalheight,A)-t);var n=0;e.width.number>0&&(n=gt(e.width,A));var i={height:UA(t+r)};n>0&&(i.width=UA(n)),r>0&&(i.verticalAlign=UA(-r));var o=new fS(e.src,e.alt,i);return o.height=t,o.depth=r,o},mathmlBuilder:(e,A)=>{var t=new pA.MathNode("mglyph",[]);t.setAttribute("alt",e.alt);var r=gt(e.height,A),n=0;if(e.totalheight.number>0&&(n=gt(e.totalheight,A)-r,t.setAttribute("valign",UA(-n))),t.setAttribute("height",UA(r+n)),e.width.number>0){var i=gt(e.width,A);t.setAttribute("width",UA(i))}return t.setAttribute("src",e.src),t}});zA({type:"kern",names:["\\kern","\\mkern","\\hskip","\\mskip"],props:{numArgs:1,argTypes:["size"],primitive:!0,allowedInText:!0},handler(e,A){var{parser:t,funcName:r}=e,n=De(A[0],"size");if(t.settings.strict){var i=r[1]==="m",o=n.value.unit==="mu";i?(o||t.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+r+" supports only mu units, "+("not "+n.value.unit+" units")),t.mode!=="math"&&t.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+r+" works only in math mode")):o&&t.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+r+" doesn't support mu units")}return{type:"kern",mode:t.mode,dimension:n.value}},htmlBuilder(e,A){return X.makeGlue(e.dimension,A)},mathmlBuilder(e,A){var t=gt(e.dimension,A);return new pA.SpaceNode(t)}});zA({type:"lap",names:["\\mathllap","\\mathrlap","\\mathclap"],props:{numArgs:1,allowedInText:!0},handler:(e,A)=>{var{parser:t,funcName:r}=e,n=A[0];return{type:"lap",mode:t.mode,alignment:r.slice(5),body:n}},htmlBuilder:(e,A)=>{var t;e.alignment==="clap"?(t=X.makeSpan([],[Ue(e.body,A)]),t=X.makeSpan(["inner"],[t],A)):t=X.makeSpan(["inner"],[Ue(e.body,A)]);var r=X.makeSpan(["fix"],[]),n=X.makeSpan([e.alignment],[t,r],A),i=X.makeSpan(["strut"]);return i.style.height=UA(n.height+n.depth),n.depth&&(i.style.verticalAlign=UA(-n.depth)),n.children.unshift(i),n=X.makeSpan(["thinbox"],[n],A),X.makeSpan(["mord","vbox"],[n],A)},mathmlBuilder:(e,A)=>{var t=new pA.MathNode("mpadded",[Ve(e.body,A)]);if(e.alignment!=="rlap"){var r=e.alignment==="llap"?"-1":"-0.5";t.setAttribute("lspace",r+"width")}return t.setAttribute("width","0px"),t}});zA({type:"styling",names:["\\(","$"],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler(e,A){var{funcName:t,parser:r}=e,n=r.mode;r.switchMode("math");var i=t==="\\("?"\\)":"$",o=r.parseExpression(!1,i);return r.expect(i),r.switchMode(n),{type:"styling",mode:r.mode,style:"text",body:o}}});zA({type:"text",names:["\\)","\\]"],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler(e,A){throw new NA("Mismatched "+e.funcName)}});var jh=(e,A)=>{switch(A.style.size){case oe.DISPLAY.size:return e.display;case oe.TEXT.size:return e.text;case oe.SCRIPT.size:return e.script;case oe.SCRIPTSCRIPT.size:return e.scriptscript;default:return e.text}};zA({type:"mathchoice",names:["\\mathchoice"],props:{numArgs:4,primitive:!0},handler:(e,A)=>{var{parser:t}=e;return{type:"mathchoice",mode:t.mode,display:ct(A[0]),text:ct(A[1]),script:ct(A[2]),scriptscript:ct(A[3])}},htmlBuilder:(e,A)=>{var t=jh(e,A),r=Ft(t,A,!1);return X.makeFragment(r)},mathmlBuilder:(e,A)=>{var t=jh(e,A);return qi(t,A)}});var Yp=(e,A,t,r,n,i,o)=>{e=X.makeSpan([],[e]);var g=t&&Le.isCharacterBox(t),Q,B;if(A){var a=Ue(A,r.havingStyle(n.sup()),r);B={elem:a,kern:Math.max(r.fontMetrics().bigOpSpacing1,r.fontMetrics().bigOpSpacing3-a.depth)}}if(t){var s=Ue(t,r.havingStyle(n.sub()),r);Q={elem:s,kern:Math.max(r.fontMetrics().bigOpSpacing2,r.fontMetrics().bigOpSpacing4-s.height)}}var C;if(B&&Q){var E=r.fontMetrics().bigOpSpacing5+Q.elem.height+Q.elem.depth+Q.kern+e.depth+o;C=X.makeVList({positionType:"bottom",positionData:E,children:[{type:"kern",size:r.fontMetrics().bigOpSpacing5},{type:"elem",elem:Q.elem,marginLeft:UA(-i)},{type:"kern",size:Q.kern},{type:"elem",elem:e},{type:"kern",size:B.kern},{type:"elem",elem:B.elem,marginLeft:UA(i)},{type:"kern",size:r.fontMetrics().bigOpSpacing5}]},r)}else if(Q){var I=e.height-o;C=X.makeVList({positionType:"top",positionData:I,children:[{type:"kern",size:r.fontMetrics().bigOpSpacing5},{type:"elem",elem:Q.elem,marginLeft:UA(-i)},{type:"kern",size:Q.kern},{type:"elem",elem:e}]},r)}else if(B){var c=e.depth+o;C=X.makeVList({positionType:"bottom",positionData:c,children:[{type:"elem",elem:e},{type:"kern",size:B.kern},{type:"elem",elem:B.elem,marginLeft:UA(i)},{type:"kern",size:r.fontMetrics().bigOpSpacing5}]},r)}else return e;var u=[C];if(Q&&i!==0&&!g){var h=X.makeSpan(["mspace"],[],r);h.style.marginRight=UA(i),u.unshift(h)}return X.makeSpan(["mop","op-limits"],u,r)},zp=["\\smallint"],Pg=(e,A)=>{var t,r,n=!1,i;e.type==="supsub"?(t=e.sup,r=e.sub,i=De(e.base,"op"),n=!0):i=De(e,"op");var o=A.style,g=!1;o.size===oe.DISPLAY.size&&i.symbol&&!zp.includes(i.name)&&(g=!0);var Q;if(i.symbol){var B=g?"Size2-Regular":"Size1-Regular",a="";if((i.name==="\\oiint"||i.name==="\\oiiint")&&(a=i.name.slice(1),i.name=a==="oiint"?"\\iint":"\\iiint"),Q=X.makeSymbol(i.name,B,"math",A,["mop","op-symbol",g?"large-op":"small-op"]),a.length>0){var s=Q.italic,C=X.staticSvg(a+"Size"+(g?"2":"1"),A);Q=X.makeVList({positionType:"individualShift",children:[{type:"elem",elem:Q,shift:0},{type:"elem",elem:C,shift:g?.08:0}]},A),i.name="\\"+a,Q.classes.unshift("mop"),Q.italic=s}}else if(i.body){var E=Ft(i.body,A,!0);E.length===1&&E[0]instanceof Ur?(Q=E[0],Q.classes[0]="mop"):Q=X.makeSpan(["mop"],E,A)}else{for(var I=[],c=1;c{var t;if(e.symbol)t=new dr("mo",[Kr(e.name,e.mode)]),zp.includes(e.name)&&t.setAttribute("largeop","false");else if(e.body)t=new dr("mo",sr(e.body,A));else{t=new dr("mi",[new dn(e.name.slice(1))]);var r=new dr("mo",[Kr("⁡","text")]);e.parentIsSupSub?t=new dr("mrow",[t,r]):t=hp([t,r])}return t},wJ={"∏":"\\prod","∐":"\\coprod","∑":"\\sum","⋀":"\\bigwedge","⋁":"\\bigvee","⋂":"\\bigcap","⋃":"\\bigcup","⨀":"\\bigodot","⨁":"\\bigoplus","⨂":"\\bigotimes","⨄":"\\biguplus","⨆":"\\bigsqcup"};zA({type:"op",names:["\\coprod","\\bigvee","\\bigwedge","\\biguplus","\\bigcap","\\bigcup","\\intop","\\prod","\\sum","\\bigotimes","\\bigoplus","\\bigodot","\\bigsqcup","\\smallint","∏","∐","∑","⋀","⋁","⋂","⋃","⨀","⨁","⨂","⨄","⨆"],props:{numArgs:0},handler:(e,A)=>{var{parser:t,funcName:r}=e,n=r;return n.length===1&&(n=wJ[n]),{type:"op",mode:t.mode,limits:!0,parentIsSupSub:!1,symbol:!0,name:n}},htmlBuilder:Pg,mathmlBuilder:NB});zA({type:"op",names:["\\mathop"],props:{numArgs:1,primitive:!0},handler:(e,A)=>{var{parser:t}=e,r=A[0];return{type:"op",mode:t.mode,limits:!1,parentIsSupSub:!1,symbol:!1,body:ct(r)}},htmlBuilder:Pg,mathmlBuilder:NB});var mJ={"∫":"\\int","∬":"\\iint","∭":"\\iiint","∮":"\\oint","∯":"\\oiint","∰":"\\oiiint"};zA({type:"op",names:["\\arcsin","\\arccos","\\arctan","\\arctg","\\arcctg","\\arg","\\ch","\\cos","\\cosec","\\cosh","\\cot","\\cotg","\\coth","\\csc","\\ctg","\\cth","\\deg","\\dim","\\exp","\\hom","\\ker","\\lg","\\ln","\\log","\\sec","\\sin","\\sinh","\\sh","\\tan","\\tanh","\\tg","\\th"],props:{numArgs:0},handler(e){var{parser:A,funcName:t}=e;return{type:"op",mode:A.mode,limits:!1,parentIsSupSub:!1,symbol:!1,name:t}},htmlBuilder:Pg,mathmlBuilder:NB});zA({type:"op",names:["\\det","\\gcd","\\inf","\\lim","\\max","\\min","\\Pr","\\sup"],props:{numArgs:0},handler(e){var{parser:A,funcName:t}=e;return{type:"op",mode:A.mode,limits:!0,parentIsSupSub:!1,symbol:!1,name:t}},htmlBuilder:Pg,mathmlBuilder:NB});zA({type:"op",names:["\\int","\\iint","\\iiint","\\oint","\\oiint","\\oiiint","∫","∬","∭","∮","∯","∰"],props:{numArgs:0,allowedInArgument:!0},handler(e){var{parser:A,funcName:t}=e,r=t;return r.length===1&&(r=mJ[r]),{type:"op",mode:A.mode,limits:!1,parentIsSupSub:!1,symbol:!0,name:r}},htmlBuilder:Pg,mathmlBuilder:NB});var Pp=(e,A)=>{var t,r,n=!1,i;e.type==="supsub"?(t=e.sup,r=e.sub,i=De(e.base,"operatorname"),n=!0):i=De(e,"operatorname");var o;if(i.body.length>0){for(var g=i.body.map(s=>{var C=s.text;return typeof C=="string"?{type:"textord",mode:s.mode,text:C}:s}),Q=Ft(g,A.withFont("mathrm"),!0),B=0;B{for(var t=sr(e.body,A.withFont("mathrm")),r=!0,n=0;na.toText()).join("");t=[new pA.TextNode(g)]}var Q=new pA.MathNode("mi",t);Q.setAttribute("mathvariant","normal");var B=new pA.MathNode("mo",[Kr("⁡","text")]);return e.parentIsSupSub?new pA.MathNode("mrow",[Q,B]):pA.newDocumentFragment([Q,B])};zA({type:"operatorname",names:["\\operatorname@","\\operatornamewithlimits"],props:{numArgs:1},handler:(e,A)=>{var{parser:t,funcName:r}=e,n=A[0];return{type:"operatorname",mode:t.mode,body:ct(n),alwaysHandleSupSub:r==="\\operatornamewithlimits",limits:!1,parentIsSupSub:!1}},htmlBuilder:Pp,mathmlBuilder:pJ});b("\\operatorname","\\@ifstar\\operatornamewithlimits\\operatorname@");Yo({type:"ordgroup",htmlBuilder(e,A){return e.semisimple?X.makeFragment(Ft(e.body,A,!1)):X.makeSpan(["mord"],Ft(e.body,A,!0),A)},mathmlBuilder(e,A){return qi(e.body,A,!0)}});zA({type:"overline",names:["\\overline"],props:{numArgs:1},handler(e,A){var{parser:t}=e,r=A[0];return{type:"overline",mode:t.mode,body:r}},htmlBuilder(e,A){var t=Ue(e.body,A.havingCrampedStyle()),r=X.makeLineSpan("overline-line",A),n=A.fontMetrics().defaultRuleThickness,i=X.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:t},{type:"kern",size:3*n},{type:"elem",elem:r},{type:"kern",size:n}]},A);return X.makeSpan(["mord","overline"],[i],A)},mathmlBuilder(e,A){var t=new pA.MathNode("mo",[new pA.TextNode("‾")]);t.setAttribute("stretchy","true");var r=new pA.MathNode("mover",[Ve(e.body,A),t]);return r.setAttribute("accent","true"),r}});zA({type:"phantom",names:["\\phantom"],props:{numArgs:1,allowedInText:!0},handler:(e,A)=>{var{parser:t}=e,r=A[0];return{type:"phantom",mode:t.mode,body:ct(r)}},htmlBuilder:(e,A)=>{var t=Ft(e.body,A.withPhantom(),!1);return X.makeFragment(t)},mathmlBuilder:(e,A)=>{var t=sr(e.body,A);return new pA.MathNode("mphantom",t)}});zA({type:"hphantom",names:["\\hphantom"],props:{numArgs:1,allowedInText:!0},handler:(e,A)=>{var{parser:t}=e,r=A[0];return{type:"hphantom",mode:t.mode,body:r}},htmlBuilder:(e,A)=>{var t=X.makeSpan([],[Ue(e.body,A.withPhantom())]);if(t.height=0,t.depth=0,t.children)for(var r=0;r{var t=sr(ct(e.body),A),r=new pA.MathNode("mphantom",t),n=new pA.MathNode("mpadded",[r]);return n.setAttribute("height","0px"),n.setAttribute("depth","0px"),n}});zA({type:"vphantom",names:["\\vphantom"],props:{numArgs:1,allowedInText:!0},handler:(e,A)=>{var{parser:t}=e,r=A[0];return{type:"vphantom",mode:t.mode,body:r}},htmlBuilder:(e,A)=>{var t=X.makeSpan(["inner"],[Ue(e.body,A.withPhantom())]),r=X.makeSpan(["fix"],[]);return X.makeSpan(["mord","rlap"],[t,r],A)},mathmlBuilder:(e,A)=>{var t=sr(ct(e.body),A),r=new pA.MathNode("mphantom",t),n=new pA.MathNode("mpadded",[r]);return n.setAttribute("width","0px"),n}});zA({type:"raisebox",names:["\\raisebox"],props:{numArgs:2,argTypes:["size","hbox"],allowedInText:!0},handler(e,A){var{parser:t}=e,r=De(A[0],"size").value,n=A[1];return{type:"raisebox",mode:t.mode,dy:r,body:n}},htmlBuilder(e,A){var t=Ue(e.body,A),r=gt(e.dy,A);return X.makeVList({positionType:"shift",positionData:-r,children:[{type:"elem",elem:t}]},A)},mathmlBuilder(e,A){var t=new pA.MathNode("mpadded",[Ve(e.body,A)]),r=e.dy.number+e.dy.unit;return t.setAttribute("voffset",r),t}});zA({type:"internal",names:["\\relax"],props:{numArgs:0,allowedInText:!0,allowedInArgument:!0},handler(e){var{parser:A}=e;return{type:"internal",mode:A.mode}}});zA({type:"rule",names:["\\rule"],props:{numArgs:2,numOptionalArgs:1,allowedInText:!0,allowedInMath:!0,argTypes:["size","size","size"]},handler(e,A,t){var{parser:r}=e,n=t[0],i=De(A[0],"size"),o=De(A[1],"size");return{type:"rule",mode:r.mode,shift:n&&De(n,"size").value,width:i.value,height:o.value}},htmlBuilder(e,A){var t=X.makeSpan(["mord","rule"],[],A),r=gt(e.width,A),n=gt(e.height,A),i=e.shift?gt(e.shift,A):0;return t.style.borderRightWidth=UA(r),t.style.borderTopWidth=UA(n),t.style.bottom=UA(i),t.width=r,t.height=n+i,t.depth=-i,t.maxFontSize=n*1.125*A.sizeMultiplier,t},mathmlBuilder(e,A){var t=gt(e.width,A),r=gt(e.height,A),n=e.shift?gt(e.shift,A):0,i=A.color&&A.getColor()||"black",o=new pA.MathNode("mspace");o.setAttribute("mathbackground",i),o.setAttribute("width",UA(t)),o.setAttribute("height",UA(r));var g=new pA.MathNode("mpadded",[o]);return n>=0?g.setAttribute("height",UA(n)):(g.setAttribute("height",UA(n)),g.setAttribute("depth",UA(-n))),g.setAttribute("voffset",UA(n)),g}});function _p(e,A,t){for(var r=Ft(e,A,!1),n=A.sizeMultiplier/t.sizeMultiplier,i=0;i{var t=A.havingSize(e.size);return _p(e.body,t,A)};zA({type:"sizing",names:Vh,props:{numArgs:0,allowedInText:!0},handler:(e,A)=>{var{breakOnTokenText:t,funcName:r,parser:n}=e,i=n.parseExpression(!1,t);return{type:"sizing",mode:n.mode,size:Vh.indexOf(r)+1,body:i}},htmlBuilder:kJ,mathmlBuilder:(e,A)=>{var t=A.havingSize(e.size),r=sr(e.body,t),n=new pA.MathNode("mstyle",r);return n.setAttribute("mathsize",UA(t.sizeMultiplier)),n}});zA({type:"smash",names:["\\smash"],props:{numArgs:1,numOptionalArgs:1,allowedInText:!0},handler:(e,A,t)=>{var{parser:r}=e,n=!1,i=!1,o=t[0]&&De(t[0],"ordgroup");if(o)for(var g="",Q=0;Q{var t=X.makeSpan([],[Ue(e.body,A)]);if(!e.smashHeight&&!e.smashDepth)return t;if(e.smashHeight&&(t.height=0,t.children))for(var r=0;r{var t=new pA.MathNode("mpadded",[Ve(e.body,A)]);return e.smashHeight&&t.setAttribute("height","0px"),e.smashDepth&&t.setAttribute("depth","0px"),t}});zA({type:"sqrt",names:["\\sqrt"],props:{numArgs:1,numOptionalArgs:1},handler(e,A,t){var{parser:r}=e,n=t[0],i=A[0];return{type:"sqrt",mode:r.mode,body:i,index:n}},htmlBuilder(e,A){var t=Ue(e.body,A.havingCrampedStyle());t.height===0&&(t.height=A.fontMetrics().xHeight),t=X.wrapFragment(t,A);var r=A.fontMetrics(),n=r.defaultRuleThickness,i=n;A.style.idt.height+t.depth+o&&(o=(o+s-t.height-t.depth)/2);var C=Q.height-t.height-o-B;t.style.paddingLeft=UA(a);var E=X.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:t,wrapperClasses:["svg-align"]},{type:"kern",size:-(t.height+C)},{type:"elem",elem:Q},{type:"kern",size:B}]},A);if(e.index){var I=A.havingStyle(oe.SCRIPTSCRIPT),c=Ue(e.index,I,A),u=.6*(E.height-E.depth),h=X.makeVList({positionType:"shift",positionData:-u,children:[{type:"elem",elem:c}]},A),d=X.makeSpan(["root"],[h]);return X.makeSpan(["mord","sqrt"],[d,E],A)}else return X.makeSpan(["mord","sqrt"],[E],A)},mathmlBuilder(e,A){var{body:t,index:r}=e;return r?new pA.MathNode("mroot",[Ve(t,A),Ve(r,A)]):new pA.MathNode("msqrt",[Ve(t,A)])}});var Wh={display:oe.DISPLAY,text:oe.TEXT,script:oe.SCRIPT,scriptscript:oe.SCRIPTSCRIPT};zA({type:"styling",names:["\\displaystyle","\\textstyle","\\scriptstyle","\\scriptscriptstyle"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(e,A){var{breakOnTokenText:t,funcName:r,parser:n}=e,i=n.parseExpression(!0,t),o=r.slice(1,r.length-5);return{type:"styling",mode:n.mode,style:o,body:i}},htmlBuilder(e,A){var t=Wh[e.style],r=A.havingStyle(t).withFont("");return _p(e.body,r,A)},mathmlBuilder(e,A){var t=Wh[e.style],r=A.havingStyle(t),n=sr(e.body,r),i=new pA.MathNode("mstyle",n),o={display:["0","true"],text:["0","false"],script:["1","false"],scriptscript:["2","false"]},g=o[e.style];return i.setAttribute("scriptlevel",g[0]),i.setAttribute("displaystyle",g[1]),i}});var yJ=function(A,t){var r=A.base;if(r)if(r.type==="op"){var n=r.limits&&(t.style.size===oe.DISPLAY.size||r.alwaysHandleSupSub);return n?Pg:null}else if(r.type==="operatorname"){var i=r.alwaysHandleSupSub&&(t.style.size===oe.DISPLAY.size||r.limits);return i?Pp:null}else{if(r.type==="accent")return Le.isCharacterBox(r.base)?zc:null;if(r.type==="horizBrace"){var o=!A.sub;return o===r.isOver?Hp:null}else return null}else return null};Yo({type:"supsub",htmlBuilder(e,A){var t=yJ(e,A);if(t)return t(e,A);var{base:r,sup:n,sub:i}=e,o=Ue(r,A),g,Q,B=A.fontMetrics(),a=0,s=0,C=r&&Le.isCharacterBox(r);if(n){var E=A.havingStyle(A.style.sup());g=Ue(n,E,A),C||(a=o.height-E.fontMetrics().supDrop*E.sizeMultiplier/A.sizeMultiplier)}if(i){var I=A.havingStyle(A.style.sub());Q=Ue(i,I,A),C||(s=o.depth+I.fontMetrics().subDrop*I.sizeMultiplier/A.sizeMultiplier)}var c;A.style===oe.DISPLAY?c=B.sup1:A.style.cramped?c=B.sup3:c=B.sup2;var u=A.sizeMultiplier,h=UA(.5/B.ptPerEm/u),d=null;if(Q){var f=e.base&&e.base.type==="op"&&e.base.name&&(e.base.name==="\\oiint"||e.base.name==="\\oiiint");(o instanceof Ur||f)&&(d=UA(-o.italic))}var m;if(g&&Q){a=Math.max(a,c,g.depth+.25*B.xHeight),s=Math.max(s,B.sub2);var k=B.defaultRuleThickness,N=4*k;if(a-g.depth-(Q.height-s)0&&(a+=F,s-=F)}var L=[{type:"elem",elem:Q,shift:s,marginRight:h,marginLeft:d},{type:"elem",elem:g,shift:-a,marginRight:h}];m=X.makeVList({positionType:"individualShift",children:L},A)}else if(Q){s=Math.max(s,B.sub1,Q.height-.8*B.xHeight);var v=[{type:"elem",elem:Q,marginLeft:d,marginRight:h}];m=X.makeVList({positionType:"shift",positionData:s,children:v},A)}else if(g)a=Math.max(a,c,g.depth+.25*B.xHeight),m=X.makeVList({positionType:"shift",positionData:-a,children:[{type:"elem",elem:g,marginRight:h}]},A);else throw new Error("supsub must have either sup or sub.");var O=$I(o,"right")||"mord";return X.makeSpan([O],[o,X.makeSpan(["msupsub"],[m])],A)},mathmlBuilder(e,A){var t=!1,r,n;e.base&&e.base.type==="horizBrace"&&(n=!!e.sup,n===e.base.isOver&&(t=!0,r=e.base.isOver)),e.base&&(e.base.type==="op"||e.base.type==="operatorname")&&(e.base.parentIsSupSub=!0);var i=[Ve(e.base,A)];e.sub&&i.push(Ve(e.sub,A)),e.sup&&i.push(Ve(e.sup,A));var o;if(t)o=r?"mover":"munder";else if(e.sub)if(e.sup){var B=e.base;B&&B.type==="op"&&B.limits&&A.style===oe.DISPLAY||B&&B.type==="operatorname"&&B.alwaysHandleSupSub&&(A.style===oe.DISPLAY||B.limits)?o="munderover":o="msubsup"}else{var Q=e.base;Q&&Q.type==="op"&&Q.limits&&(A.style===oe.DISPLAY||Q.alwaysHandleSupSub)||Q&&Q.type==="operatorname"&&Q.alwaysHandleSupSub&&(Q.limits||A.style===oe.DISPLAY)?o="munder":o="msub"}else{var g=e.base;g&&g.type==="op"&&g.limits&&(A.style===oe.DISPLAY||g.alwaysHandleSupSub)||g&&g.type==="operatorname"&&g.alwaysHandleSupSub&&(g.limits||A.style===oe.DISPLAY)?o="mover":o="msup"}return new pA.MathNode(o,i)}});Yo({type:"atom",htmlBuilder(e,A){return X.mathsym(e.text,e.mode,A,["m"+e.family])},mathmlBuilder(e,A){var t=new pA.MathNode("mo",[Kr(e.text,e.mode)]);if(e.family==="bin"){var r=Hc(e,A);r==="bold-italic"&&t.setAttribute("mathvariant",r)}else e.family==="punct"?t.setAttribute("separator","true"):(e.family==="open"||e.family==="close")&&t.setAttribute("stretchy","false");return t}});var jp={mi:"italic",mn:"normal",mtext:"normal"};Yo({type:"mathord",htmlBuilder(e,A){return X.makeOrd(e,A,"mathord")},mathmlBuilder(e,A){var t=new pA.MathNode("mi",[Kr(e.text,e.mode,A)]),r=Hc(e,A)||"italic";return r!==jp[t.type]&&t.setAttribute("mathvariant",r),t}});Yo({type:"textord",htmlBuilder(e,A){return X.makeOrd(e,A,"textord")},mathmlBuilder(e,A){var t=Kr(e.text,e.mode,A),r=Hc(e,A)||"normal",n;return e.mode==="text"?n=new pA.MathNode("mtext",[t]):/[0-9]/.test(e.text)?n=new pA.MathNode("mn",[t]):e.text==="\\prime"?n=new pA.MathNode("mo",[t]):n=new pA.MathNode("mi",[t]),r!==jp[n.type]&&n.setAttribute("mathvariant",r),n}});var KC={"\\nobreak":"nobreak","\\allowbreak":"allowbreak"},LC={" ":{},"\\ ":{},"~":{className:"nobreak"},"\\space":{},"\\nobreakspace":{className:"nobreak"}};Yo({type:"spacing",htmlBuilder(e,A){if(LC.hasOwnProperty(e.text)){var t=LC[e.text].className||"";if(e.mode==="text"){var r=X.makeOrd(e,A,"textord");return r.classes.push(t),r}else return X.makeSpan(["mspace",t],[X.mathsym(e.text,e.mode,A)],A)}else{if(KC.hasOwnProperty(e.text))return X.makeSpan(["mspace",KC[e.text]],[],A);throw new NA('Unknown type of space "'+e.text+'"')}},mathmlBuilder(e,A){var t;if(LC.hasOwnProperty(e.text))t=new pA.MathNode("mtext",[new pA.TextNode(" ")]);else{if(KC.hasOwnProperty(e.text))return new pA.MathNode("mspace");throw new NA('Unknown type of space "'+e.text+'"')}return t}});var Zh=()=>{var e=new pA.MathNode("mtd",[]);return e.setAttribute("width","50%"),e};Yo({type:"tag",mathmlBuilder(e,A){var t=new pA.MathNode("mtable",[new pA.MathNode("mtr",[Zh(),new pA.MathNode("mtd",[qi(e.body,A)]),Zh(),new pA.MathNode("mtd",[qi(e.tag,A)])])]);return t.setAttribute("width","100%"),t}});var Xh={"\\text":void 0,"\\textrm":"textrm","\\textsf":"textsf","\\texttt":"texttt","\\textnormal":"textrm"},$h={"\\textbf":"textbf","\\textmd":"textmd"},MJ={"\\textit":"textit","\\textup":"textup"},AD=(e,A)=>{var t=e.font;if(t){if(Xh[t])return A.withTextFontFamily(Xh[t]);if($h[t])return A.withTextFontWeight($h[t]);if(t==="\\emph")return A.fontShape==="textit"?A.withTextFontShape("textup"):A.withTextFontShape("textit")}else return A;return A.withTextFontShape(MJ[t])};zA({type:"text",names:["\\text","\\textrm","\\textsf","\\texttt","\\textnormal","\\textbf","\\textmd","\\textit","\\textup","\\emph"],props:{numArgs:1,argTypes:["text"],allowedInArgument:!0,allowedInText:!0},handler(e,A){var{parser:t,funcName:r}=e,n=A[0];return{type:"text",mode:t.mode,body:ct(n),font:r}},htmlBuilder(e,A){var t=AD(e,A),r=Ft(e.body,t,!0);return X.makeSpan(["mord","text"],r,t)},mathmlBuilder(e,A){var t=AD(e,A);return qi(e.body,t)}});zA({type:"underline",names:["\\underline"],props:{numArgs:1,allowedInText:!0},handler(e,A){var{parser:t}=e;return{type:"underline",mode:t.mode,body:A[0]}},htmlBuilder(e,A){var t=Ue(e.body,A),r=X.makeLineSpan("underline-line",A),n=A.fontMetrics().defaultRuleThickness,i=X.makeVList({positionType:"top",positionData:t.height,children:[{type:"kern",size:n},{type:"elem",elem:r},{type:"kern",size:3*n},{type:"elem",elem:t}]},A);return X.makeSpan(["mord","underline"],[i],A)},mathmlBuilder(e,A){var t=new pA.MathNode("mo",[new pA.TextNode("‾")]);t.setAttribute("stretchy","true");var r=new pA.MathNode("munder",[Ve(e.body,A),t]);return r.setAttribute("accentunder","true"),r}});zA({type:"vcenter",names:["\\vcenter"],props:{numArgs:1,argTypes:["original"],allowedInText:!1},handler(e,A){var{parser:t}=e;return{type:"vcenter",mode:t.mode,body:A[0]}},htmlBuilder(e,A){var t=Ue(e.body,A),r=A.fontMetrics().axisHeight,n=.5*(t.height-r-(t.depth+r));return X.makeVList({positionType:"shift",positionData:n,children:[{type:"elem",elem:t}]},A)},mathmlBuilder(e,A){return new pA.MathNode("mpadded",[Ve(e.body,A)],["vcenter"])}});zA({type:"verb",names:["\\verb"],props:{numArgs:0,allowedInText:!0},handler(e,A,t){throw new NA("\\verb ended by end of line instead of matching delimiter")},htmlBuilder(e,A){for(var t=eD(e),r=[],n=A.havingStyle(A.style.text()),i=0;ie.body.replace(/ /g,e.star?"␣":" "),xi=up,Vp=`[ \r ]`,NJ="\\\\[a-zA-Z@]+",vJ="\\\\[^\uD800-\uDFFF]",bJ="("+NJ+")"+Vp+"*",FJ=`\\\\( |[ \r ]+ ?)[ \r ]*`,rl="[̀-ͯ]",xJ=new RegExp(rl+"+$"),GJ="("+Vp+"+)|"+(FJ+"|")+"([!-\\[\\]-‧‪-퟿豈-￿]"+(rl+"*")+"|[\uD800-\uDBFF][\uDC00-\uDFFF]"+(rl+"*")+"|\\\\verb\\*([^]).*?\\4|\\\\verb([^*a-zA-Z]).*?\\5"+("|"+bJ)+("|"+vJ+")");class tD{constructor(A,t){this.input=void 0,this.settings=void 0,this.tokenRegex=void 0,this.catcodes=void 0,this.input=A,this.settings=t,this.tokenRegex=new RegExp(GJ,"g"),this.catcodes={"%":14,"~":13}}setCatcode(A,t){this.catcodes[A]=t}lex(){var A=this.input,t=this.tokenRegex.lastIndex;if(t===A.length)return new fr("EOF",new ar(this,t,t));var r=this.tokenRegex.exec(A);if(r===null||r.index!==t)throw new NA("Unexpected character: '"+A[t]+"'",new fr(A[t],new ar(this,t,t+1)));var n=r[6]||r[3]||(r[2]?"\\ ":" ");if(this.catcodes[n]===14){var i=A.indexOf(` `,this.tokenRegex.lastIndex);return i===-1?(this.tokenRegex.lastIndex=A.length,this.settings.reportNonstrict("commentAtEnd","% comment has no terminating newline; LaTeX would fail because of commenting the end of math mode (e.g. $)")):this.tokenRegex.lastIndex=i+1,this.lex()}return new fr(n,new ar(this,t,this.tokenRegex.lastIndex))}}class SJ{constructor(A,t){A===void 0&&(A={}),t===void 0&&(t={}),this.current=void 0,this.builtins=void 0,this.undefStack=void 0,this.current=t,this.builtins=A,this.undefStack=[]}beginGroup(){this.undefStack.push({})}endGroup(){if(this.undefStack.length===0)throw new NA("Unbalanced namespace destruction: attempt to pop global namespace; please report this as a bug");var A=this.undefStack.pop();for(var t in A)A.hasOwnProperty(t)&&(A[t]==null?delete this.current[t]:this.current[t]=A[t])}endGroups(){for(;this.undefStack.length>0;)this.endGroup()}has(A){return this.current.hasOwnProperty(A)||this.builtins.hasOwnProperty(A)}get(A){return this.current.hasOwnProperty(A)?this.current[A]:this.builtins[A]}set(A,t,r){if(r===void 0&&(r=!1),r){for(var n=0;n0&&(this.undefStack[this.undefStack.length-1][A]=t)}else{var i=this.undefStack[this.undefStack.length-1];i&&!i.hasOwnProperty(A)&&(i[A]=this.current[A])}t==null?delete this.current[A]:this.current[A]=t}}var JJ=Lp;b("\\noexpand",function(e){var A=e.popToken();return e.isExpandable(A.text)&&(A.noexpand=!0,A.treatAsRelax=!0),{tokens:[A],numArgs:0}});b("\\expandafter",function(e){var A=e.popToken();return e.expandOnce(!0),{tokens:[A],numArgs:0}});b("\\@firstoftwo",function(e){var A=e.consumeArgs(2);return{tokens:A[0],numArgs:0}});b("\\@secondoftwo",function(e){var A=e.consumeArgs(2);return{tokens:A[1],numArgs:0}});b("\\@ifnextchar",function(e){var A=e.consumeArgs(3);e.consumeSpaces();var t=e.future();return A[0].length===1&&A[0][0].text===t.text?{tokens:A[1],numArgs:0}:{tokens:A[2],numArgs:0}});b("\\@ifstar","\\@ifnextchar *{\\@firstoftwo{#1}}");b("\\TextOrMath",function(e){var A=e.consumeArgs(2);return e.mode==="text"?{tokens:A[0],numArgs:0}:{tokens:A[1],numArgs:0}});var rD={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,a:10,A:10,b:11,B:11,c:12,C:12,d:13,D:13,e:14,E:14,f:15,F:15};b("\\char",function(e){var A=e.popToken(),t,r="";if(A.text==="'")t=8,A=e.popToken();else if(A.text==='"')t=16,A=e.popToken();else if(A.text==="`")if(A=e.popToken(),A.text[0]==="\\")r=A.text.charCodeAt(1);else{if(A.text==="EOF")throw new NA("\\char` missing argument");r=A.text.charCodeAt(0)}else t=10;if(t){if(r=rD[A.text],r==null||r>=t)throw new NA("Invalid base-"+t+" digit "+A.text);for(var n;(n=rD[e.future().text])!=null&&n{var n=e.consumeArg().tokens;if(n.length!==1)throw new NA("\\newcommand's first argument must be a macro name");var i=n[0].text,o=e.isDefined(i);if(o&&!A)throw new NA("\\newcommand{"+i+"} attempting to redefine "+(i+"; use \\renewcommand"));if(!o&&!t)throw new NA("\\renewcommand{"+i+"} when command "+i+" does not yet exist; use \\newcommand");var g=0;if(n=e.consumeArg().tokens,n.length===1&&n[0].text==="["){for(var Q="",B=e.expandNextToken();B.text!=="]"&&B.text!=="EOF";)Q+=B.text,B=e.expandNextToken();if(!Q.match(/^\s*[0-9]+\s*$/))throw new NA("Invalid number of arguments: "+Q);g=parseInt(Q),n=e.consumeArg().tokens}return o&&r||e.macros.set(i,{tokens:n,numArgs:g}),""};b("\\newcommand",e=>$c(e,!1,!0,!1));b("\\renewcommand",e=>$c(e,!0,!1,!1));b("\\providecommand",e=>$c(e,!0,!0,!0));b("\\message",e=>{var A=e.consumeArgs(1)[0];return console.log(A.reverse().map(t=>t.text).join("")),""});b("\\errmessage",e=>{var A=e.consumeArgs(1)[0];return console.error(A.reverse().map(t=>t.text).join("")),""});b("\\show",e=>{var A=e.popToken(),t=A.text;return console.log(A,e.macros.get(t),xi[t],Ze.math[t],Ze.text[t]),""});b("\\bgroup","{");b("\\egroup","}");b("~","\\nobreakspace");b("\\lq","`");b("\\rq","'");b("\\aa","\\r a");b("\\AA","\\r A");b("\\textcopyright","\\html@mathml{\\textcircled{c}}{\\char`©}");b("\\copyright","\\TextOrMath{\\textcopyright}{\\text{\\textcopyright}}");b("\\textregistered","\\html@mathml{\\textcircled{\\scriptsize R}}{\\char`®}");b("ℬ","\\mathscr{B}");b("ℰ","\\mathscr{E}");b("ℱ","\\mathscr{F}");b("ℋ","\\mathscr{H}");b("ℐ","\\mathscr{I}");b("ℒ","\\mathscr{L}");b("ℳ","\\mathscr{M}");b("ℛ","\\mathscr{R}");b("ℭ","\\mathfrak{C}");b("ℌ","\\mathfrak{H}");b("ℨ","\\mathfrak{Z}");b("\\Bbbk","\\Bbb{k}");b("·","\\cdotp");b("\\llap","\\mathllap{\\textrm{#1}}");b("\\rlap","\\mathrlap{\\textrm{#1}}");b("\\clap","\\mathclap{\\textrm{#1}}");b("\\mathstrut","\\vphantom{(}");b("\\underbar","\\underline{\\text{#1}}");b("\\not",'\\html@mathml{\\mathrel{\\mathrlap\\@not}}{\\char"338}');b("\\neq","\\html@mathml{\\mathrel{\\not=}}{\\mathrel{\\char`≠}}");b("\\ne","\\neq");b("≠","\\neq");b("\\notin","\\html@mathml{\\mathrel{{\\in}\\mathllap{/\\mskip1mu}}}{\\mathrel{\\char`∉}}");b("∉","\\notin");b("≘","\\html@mathml{\\mathrel{=\\kern{-1em}\\raisebox{0.4em}{$\\scriptsize\\frown$}}}{\\mathrel{\\char`≘}}");b("≙","\\html@mathml{\\stackrel{\\tiny\\wedge}{=}}{\\mathrel{\\char`≘}}");b("≚","\\html@mathml{\\stackrel{\\tiny\\vee}{=}}{\\mathrel{\\char`≚}}");b("≛","\\html@mathml{\\stackrel{\\scriptsize\\star}{=}}{\\mathrel{\\char`≛}}");b("≝","\\html@mathml{\\stackrel{\\tiny\\mathrm{def}}{=}}{\\mathrel{\\char`≝}}");b("≞","\\html@mathml{\\stackrel{\\tiny\\mathrm{m}}{=}}{\\mathrel{\\char`≞}}");b("≟","\\html@mathml{\\stackrel{\\tiny?}{=}}{\\mathrel{\\char`≟}}");b("⟂","\\perp");b("‼","\\mathclose{!\\mkern-0.8mu!}");b("∌","\\notni");b("⌜","\\ulcorner");b("⌝","\\urcorner");b("⌞","\\llcorner");b("⌟","\\lrcorner");b("©","\\copyright");b("®","\\textregistered");b("️","\\textregistered");b("\\ulcorner",'\\html@mathml{\\@ulcorner}{\\mathop{\\char"231c}}');b("\\urcorner",'\\html@mathml{\\@urcorner}{\\mathop{\\char"231d}}');b("\\llcorner",'\\html@mathml{\\@llcorner}{\\mathop{\\char"231e}}');b("\\lrcorner",'\\html@mathml{\\@lrcorner}{\\mathop{\\char"231f}}');b("\\vdots","{\\varvdots\\rule{0pt}{15pt}}");b("⋮","\\vdots");b("\\varGamma","\\mathit{\\Gamma}");b("\\varDelta","\\mathit{\\Delta}");b("\\varTheta","\\mathit{\\Theta}");b("\\varLambda","\\mathit{\\Lambda}");b("\\varXi","\\mathit{\\Xi}");b("\\varPi","\\mathit{\\Pi}");b("\\varSigma","\\mathit{\\Sigma}");b("\\varUpsilon","\\mathit{\\Upsilon}");b("\\varPhi","\\mathit{\\Phi}");b("\\varPsi","\\mathit{\\Psi}");b("\\varOmega","\\mathit{\\Omega}");b("\\substack","\\begin{subarray}{c}#1\\end{subarray}");b("\\colon","\\nobreak\\mskip2mu\\mathpunct{}\\mathchoice{\\mkern-3mu}{\\mkern-3mu}{}{}{:}\\mskip6mu\\relax");b("\\boxed","\\fbox{$\\displaystyle{#1}$}");b("\\iff","\\DOTSB\\;\\Longleftrightarrow\\;");b("\\implies","\\DOTSB\\;\\Longrightarrow\\;");b("\\impliedby","\\DOTSB\\;\\Longleftarrow\\;");b("\\dddot","{\\overset{\\raisebox{-0.1ex}{\\normalsize ...}}{#1}}");b("\\ddddot","{\\overset{\\raisebox{-0.1ex}{\\normalsize ....}}{#1}}");var nD={",":"\\dotsc","\\not":"\\dotsb","+":"\\dotsb","=":"\\dotsb","<":"\\dotsb",">":"\\dotsb","-":"\\dotsb","*":"\\dotsb",":":"\\dotsb","\\DOTSB":"\\dotsb","\\coprod":"\\dotsb","\\bigvee":"\\dotsb","\\bigwedge":"\\dotsb","\\biguplus":"\\dotsb","\\bigcap":"\\dotsb","\\bigcup":"\\dotsb","\\prod":"\\dotsb","\\sum":"\\dotsb","\\bigotimes":"\\dotsb","\\bigoplus":"\\dotsb","\\bigodot":"\\dotsb","\\bigsqcup":"\\dotsb","\\And":"\\dotsb","\\longrightarrow":"\\dotsb","\\Longrightarrow":"\\dotsb","\\longleftarrow":"\\dotsb","\\Longleftarrow":"\\dotsb","\\longleftrightarrow":"\\dotsb","\\Longleftrightarrow":"\\dotsb","\\mapsto":"\\dotsb","\\longmapsto":"\\dotsb","\\hookrightarrow":"\\dotsb","\\doteq":"\\dotsb","\\mathbin":"\\dotsb","\\mathrel":"\\dotsb","\\relbar":"\\dotsb","\\Relbar":"\\dotsb","\\xrightarrow":"\\dotsb","\\xleftarrow":"\\dotsb","\\DOTSI":"\\dotsi","\\int":"\\dotsi","\\oint":"\\dotsi","\\iint":"\\dotsi","\\iiint":"\\dotsi","\\iiiint":"\\dotsi","\\idotsint":"\\dotsi","\\DOTSX":"\\dotsx"};b("\\dots",function(e){var A="\\dotso",t=e.expandAfterFuture().text;return t in nD?A=nD[t]:(t.slice(0,4)==="\\not"||t in Ze.math&&["bin","rel"].includes(Ze.math[t].group))&&(A="\\dotsb"),A});var Au={")":!0,"]":!0,"\\rbrack":!0,"\\}":!0,"\\rbrace":!0,"\\rangle":!0,"\\rceil":!0,"\\rfloor":!0,"\\rgroup":!0,"\\rmoustache":!0,"\\right":!0,"\\bigr":!0,"\\biggr":!0,"\\Bigr":!0,"\\Biggr":!0,$:!0,";":!0,".":!0,",":!0};b("\\dotso",function(e){var A=e.future().text;return A in Au?"\\ldots\\,":"\\ldots"});b("\\dotsc",function(e){var A=e.future().text;return A in Au&&A!==","?"\\ldots\\,":"\\ldots"});b("\\cdots",function(e){var A=e.future().text;return A in Au?"\\@cdots\\,":"\\@cdots"});b("\\dotsb","\\cdots");b("\\dotsm","\\cdots");b("\\dotsi","\\!\\cdots");b("\\dotsx","\\ldots\\,");b("\\DOTSI","\\relax");b("\\DOTSB","\\relax");b("\\DOTSX","\\relax");b("\\tmspace","\\TextOrMath{\\kern#1#3}{\\mskip#1#2}\\relax");b("\\,","\\tmspace+{3mu}{.1667em}");b("\\thinspace","\\,");b("\\>","\\mskip{4mu}");b("\\:","\\tmspace+{4mu}{.2222em}");b("\\medspace","\\:");b("\\;","\\tmspace+{5mu}{.2777em}");b("\\thickspace","\\;");b("\\!","\\tmspace-{3mu}{.1667em}");b("\\negthinspace","\\!");b("\\negmedspace","\\tmspace-{4mu}{.2222em}");b("\\negthickspace","\\tmspace-{5mu}{.277em}");b("\\enspace","\\kern.5em ");b("\\enskip","\\hskip.5em\\relax");b("\\quad","\\hskip1em\\relax");b("\\qquad","\\hskip2em\\relax");b("\\tag","\\@ifstar\\tag@literal\\tag@paren");b("\\tag@paren","\\tag@literal{({#1})}");b("\\tag@literal",e=>{if(e.macros.get("\\df@tag"))throw new NA("Multiple \\tag");return"\\gdef\\df@tag{\\text{#1}}"});b("\\bmod","\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}\\mathbin{\\rm mod}\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}");b("\\pod","\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern8mu}{\\mkern8mu}{\\mkern8mu}(#1)");b("\\pmod","\\pod{{\\rm mod}\\mkern6mu#1}");b("\\mod","\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern12mu}{\\mkern12mu}{\\mkern12mu}{\\rm mod}\\,\\,#1");b("\\newline","\\\\\\relax");b("\\TeX","\\textrm{\\html@mathml{T\\kern-.1667em\\raisebox{-.5ex}{E}\\kern-.125emX}{TeX}}");var Wp=UA(un["Main-Regular"][84][1]-.7*un["Main-Regular"][65][1]);b("\\LaTeX","\\textrm{\\html@mathml{"+("L\\kern-.36em\\raisebox{"+Wp+"}{\\scriptstyle A}")+"\\kern-.15em\\TeX}{LaTeX}}");b("\\KaTeX","\\textrm{\\html@mathml{"+("K\\kern-.17em\\raisebox{"+Wp+"}{\\scriptstyle A}")+"\\kern-.15em\\TeX}{KaTeX}}");b("\\hspace","\\@ifstar\\@hspacer\\@hspace");b("\\@hspace","\\hskip #1\\relax");b("\\@hspacer","\\rule{0pt}{0pt}\\hskip #1\\relax");b("\\ordinarycolon",":");b("\\vcentcolon","\\mathrel{\\mathop\\ordinarycolon}");b("\\dblcolon",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-.9mu}\\vcentcolon}}{\\mathop{\\char"2237}}');b("\\coloneqq",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2254}}');b("\\Coloneqq",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2237\\char"3d}}');b("\\coloneq",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"3a\\char"2212}}');b("\\Coloneq",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"2237\\char"2212}}');b("\\eqqcolon",'\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2255}}');b("\\Eqqcolon",'\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"3d\\char"2237}}');b("\\eqcolon",'\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2239}}');b("\\Eqcolon",'\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"2212\\char"2237}}');b("\\colonapprox",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"3a\\char"2248}}');b("\\Colonapprox",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"2237\\char"2248}}');b("\\colonsim",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"3a\\char"223c}}');b("\\Colonsim",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"2237\\char"223c}}');b("∷","\\dblcolon");b("∹","\\eqcolon");b("≔","\\coloneqq");b("≕","\\eqqcolon");b("⩴","\\Coloneqq");b("\\ratio","\\vcentcolon");b("\\coloncolon","\\dblcolon");b("\\colonequals","\\coloneqq");b("\\coloncolonequals","\\Coloneqq");b("\\equalscolon","\\eqqcolon");b("\\equalscoloncolon","\\Eqqcolon");b("\\colonminus","\\coloneq");b("\\coloncolonminus","\\Coloneq");b("\\minuscolon","\\eqcolon");b("\\minuscoloncolon","\\Eqcolon");b("\\coloncolonapprox","\\Colonapprox");b("\\coloncolonsim","\\Colonsim");b("\\simcolon","\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\vcentcolon}");b("\\simcoloncolon","\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\dblcolon}");b("\\approxcolon","\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\vcentcolon}");b("\\approxcoloncolon","\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\dblcolon}");b("\\notni","\\html@mathml{\\not\\ni}{\\mathrel{\\char`∌}}");b("\\limsup","\\DOTSB\\operatorname*{lim\\,sup}");b("\\liminf","\\DOTSB\\operatorname*{lim\\,inf}");b("\\injlim","\\DOTSB\\operatorname*{inj\\,lim}");b("\\projlim","\\DOTSB\\operatorname*{proj\\,lim}");b("\\varlimsup","\\DOTSB\\operatorname*{\\overline{lim}}");b("\\varliminf","\\DOTSB\\operatorname*{\\underline{lim}}");b("\\varinjlim","\\DOTSB\\operatorname*{\\underrightarrow{lim}}");b("\\varprojlim","\\DOTSB\\operatorname*{\\underleftarrow{lim}}");b("\\gvertneqq","\\html@mathml{\\@gvertneqq}{≩}");b("\\lvertneqq","\\html@mathml{\\@lvertneqq}{≨}");b("\\ngeqq","\\html@mathml{\\@ngeqq}{≱}");b("\\ngeqslant","\\html@mathml{\\@ngeqslant}{≱}");b("\\nleqq","\\html@mathml{\\@nleqq}{≰}");b("\\nleqslant","\\html@mathml{\\@nleqslant}{≰}");b("\\nshortmid","\\html@mathml{\\@nshortmid}{∤}");b("\\nshortparallel","\\html@mathml{\\@nshortparallel}{∦}");b("\\nsubseteqq","\\html@mathml{\\@nsubseteqq}{⊈}");b("\\nsupseteqq","\\html@mathml{\\@nsupseteqq}{⊉}");b("\\varsubsetneq","\\html@mathml{\\@varsubsetneq}{⊊}");b("\\varsubsetneqq","\\html@mathml{\\@varsubsetneqq}{⫋}");b("\\varsupsetneq","\\html@mathml{\\@varsupsetneq}{⊋}");b("\\varsupsetneqq","\\html@mathml{\\@varsupsetneqq}{⫌}");b("\\imath","\\html@mathml{\\@imath}{ı}");b("\\jmath","\\html@mathml{\\@jmath}{ȷ}");b("\\llbracket","\\html@mathml{\\mathopen{[\\mkern-3.2mu[}}{\\mathopen{\\char`⟦}}");b("\\rrbracket","\\html@mathml{\\mathclose{]\\mkern-3.2mu]}}{\\mathclose{\\char`⟧}}");b("⟦","\\llbracket");b("⟧","\\rrbracket");b("\\lBrace","\\html@mathml{\\mathopen{\\{\\mkern-3.2mu[}}{\\mathopen{\\char`⦃}}");b("\\rBrace","\\html@mathml{\\mathclose{]\\mkern-3.2mu\\}}}{\\mathclose{\\char`⦄}}");b("⦃","\\lBrace");b("⦄","\\rBrace");b("\\minuso","\\mathbin{\\html@mathml{{\\mathrlap{\\mathchoice{\\kern{0.145em}}{\\kern{0.145em}}{\\kern{0.1015em}}{\\kern{0.0725em}}\\circ}{-}}}{\\char`⦵}}");b("⦵","\\minuso");b("\\darr","\\downarrow");b("\\dArr","\\Downarrow");b("\\Darr","\\Downarrow");b("\\lang","\\langle");b("\\rang","\\rangle");b("\\uarr","\\uparrow");b("\\uArr","\\Uparrow");b("\\Uarr","\\Uparrow");b("\\N","\\mathbb{N}");b("\\R","\\mathbb{R}");b("\\Z","\\mathbb{Z}");b("\\alef","\\aleph");b("\\alefsym","\\aleph");b("\\Alpha","\\mathrm{A}");b("\\Beta","\\mathrm{B}");b("\\bull","\\bullet");b("\\Chi","\\mathrm{X}");b("\\clubs","\\clubsuit");b("\\cnums","\\mathbb{C}");b("\\Complex","\\mathbb{C}");b("\\Dagger","\\ddagger");b("\\diamonds","\\diamondsuit");b("\\empty","\\emptyset");b("\\Epsilon","\\mathrm{E}");b("\\Eta","\\mathrm{H}");b("\\exist","\\exists");b("\\harr","\\leftrightarrow");b("\\hArr","\\Leftrightarrow");b("\\Harr","\\Leftrightarrow");b("\\hearts","\\heartsuit");b("\\image","\\Im");b("\\infin","\\infty");b("\\Iota","\\mathrm{I}");b("\\isin","\\in");b("\\Kappa","\\mathrm{K}");b("\\larr","\\leftarrow");b("\\lArr","\\Leftarrow");b("\\Larr","\\Leftarrow");b("\\lrarr","\\leftrightarrow");b("\\lrArr","\\Leftrightarrow");b("\\Lrarr","\\Leftrightarrow");b("\\Mu","\\mathrm{M}");b("\\natnums","\\mathbb{N}");b("\\Nu","\\mathrm{N}");b("\\Omicron","\\mathrm{O}");b("\\plusmn","\\pm");b("\\rarr","\\rightarrow");b("\\rArr","\\Rightarrow");b("\\Rarr","\\Rightarrow");b("\\real","\\Re");b("\\reals","\\mathbb{R}");b("\\Reals","\\mathbb{R}");b("\\Rho","\\mathrm{P}");b("\\sdot","\\cdot");b("\\sect","\\S");b("\\spades","\\spadesuit");b("\\sub","\\subset");b("\\sube","\\subseteq");b("\\supe","\\supseteq");b("\\Tau","\\mathrm{T}");b("\\thetasym","\\vartheta");b("\\weierp","\\wp");b("\\Zeta","\\mathrm{Z}");b("\\argmin","\\DOTSB\\operatorname*{arg\\,min}");b("\\argmax","\\DOTSB\\operatorname*{arg\\,max}");b("\\plim","\\DOTSB\\mathop{\\operatorname{plim}}\\limits");b("\\bra","\\mathinner{\\langle{#1}|}");b("\\ket","\\mathinner{|{#1}\\rangle}");b("\\braket","\\mathinner{\\langle{#1}\\rangle}");b("\\Bra","\\left\\langle#1\\right|");b("\\Ket","\\left|#1\\right\\rangle");var Zp=e=>A=>{var t=A.consumeArg().tokens,r=A.consumeArg().tokens,n=A.consumeArg().tokens,i=A.consumeArg().tokens,o=A.macros.get("|"),g=A.macros.get("\\|");A.macros.beginGroup();var Q=s=>C=>{e&&(C.macros.set("|",o),n.length&&C.macros.set("\\|",g));var E=s;if(!s&&n.length){var I=C.future();I.text==="|"&&(C.popToken(),E=!0)}return{tokens:E?n:r,numArgs:0}};A.macros.set("|",Q(!1)),n.length&&A.macros.set("\\|",Q(!0));var B=A.consumeArg().tokens,a=A.expandTokens([...i,...B,...t]);return A.macros.endGroup(),{tokens:a.reverse(),numArgs:0}};b("\\bra@ket",Zp(!1));b("\\bra@set",Zp(!0));b("\\Braket","\\bra@ket{\\left\\langle}{\\,\\middle\\vert\\,}{\\,\\middle\\vert\\,}{\\right\\rangle}");b("\\Set","\\bra@set{\\left\\{\\:}{\\;\\middle\\vert\\;}{\\;\\middle\\Vert\\;}{\\:\\right\\}}");b("\\set","\\bra@set{\\{\\,}{\\mid}{}{\\,\\}}");b("\\angln","{\\angl n}");b("\\blue","\\textcolor{##6495ed}{#1}");b("\\orange","\\textcolor{##ffa500}{#1}");b("\\pink","\\textcolor{##ff00af}{#1}");b("\\red","\\textcolor{##df0030}{#1}");b("\\green","\\textcolor{##28ae7b}{#1}");b("\\gray","\\textcolor{gray}{#1}");b("\\purple","\\textcolor{##9d38bd}{#1}");b("\\blueA","\\textcolor{##ccfaff}{#1}");b("\\blueB","\\textcolor{##80f6ff}{#1}");b("\\blueC","\\textcolor{##63d9ea}{#1}");b("\\blueD","\\textcolor{##11accd}{#1}");b("\\blueE","\\textcolor{##0c7f99}{#1}");b("\\tealA","\\textcolor{##94fff5}{#1}");b("\\tealB","\\textcolor{##26edd5}{#1}");b("\\tealC","\\textcolor{##01d1c1}{#1}");b("\\tealD","\\textcolor{##01a995}{#1}");b("\\tealE","\\textcolor{##208170}{#1}");b("\\greenA","\\textcolor{##b6ffb0}{#1}");b("\\greenB","\\textcolor{##8af281}{#1}");b("\\greenC","\\textcolor{##74cf70}{#1}");b("\\greenD","\\textcolor{##1fab54}{#1}");b("\\greenE","\\textcolor{##0d923f}{#1}");b("\\goldA","\\textcolor{##ffd0a9}{#1}");b("\\goldB","\\textcolor{##ffbb71}{#1}");b("\\goldC","\\textcolor{##ff9c39}{#1}");b("\\goldD","\\textcolor{##e07d10}{#1}");b("\\goldE","\\textcolor{##a75a05}{#1}");b("\\redA","\\textcolor{##fca9a9}{#1}");b("\\redB","\\textcolor{##ff8482}{#1}");b("\\redC","\\textcolor{##f9685d}{#1}");b("\\redD","\\textcolor{##e84d39}{#1}");b("\\redE","\\textcolor{##bc2612}{#1}");b("\\maroonA","\\textcolor{##ffbde0}{#1}");b("\\maroonB","\\textcolor{##ff92c6}{#1}");b("\\maroonC","\\textcolor{##ed5fa6}{#1}");b("\\maroonD","\\textcolor{##ca337c}{#1}");b("\\maroonE","\\textcolor{##9e034e}{#1}");b("\\purpleA","\\textcolor{##ddd7ff}{#1}");b("\\purpleB","\\textcolor{##c6b9fc}{#1}");b("\\purpleC","\\textcolor{##aa87ff}{#1}");b("\\purpleD","\\textcolor{##7854ab}{#1}");b("\\purpleE","\\textcolor{##543b78}{#1}");b("\\mintA","\\textcolor{##f5f9e8}{#1}");b("\\mintB","\\textcolor{##edf2df}{#1}");b("\\mintC","\\textcolor{##e0e5cc}{#1}");b("\\grayA","\\textcolor{##f6f7f7}{#1}");b("\\grayB","\\textcolor{##f0f1f2}{#1}");b("\\grayC","\\textcolor{##e3e5e6}{#1}");b("\\grayD","\\textcolor{##d6d8da}{#1}");b("\\grayE","\\textcolor{##babec2}{#1}");b("\\grayF","\\textcolor{##888d93}{#1}");b("\\grayG","\\textcolor{##626569}{#1}");b("\\grayH","\\textcolor{##3b3e40}{#1}");b("\\grayI","\\textcolor{##21242c}{#1}");b("\\kaBlue","\\textcolor{##314453}{#1}");b("\\kaGreen","\\textcolor{##71B307}{#1}");var Xp={"^":!0,_:!0,"\\limits":!0,"\\nolimits":!0};class UJ{constructor(A,t,r){this.settings=void 0,this.expansionCount=void 0,this.lexer=void 0,this.macros=void 0,this.stack=void 0,this.mode=void 0,this.settings=t,this.expansionCount=0,this.feed(A),this.macros=new SJ(JJ,t.macros),this.mode=r,this.stack=[]}feed(A){this.lexer=new tD(A,this.settings)}switchMode(A){this.mode=A}beginGroup(){this.macros.beginGroup()}endGroup(){this.macros.endGroup()}endGroups(){this.macros.endGroups()}future(){return this.stack.length===0&&this.pushToken(this.lexer.lex()),this.stack[this.stack.length-1]}popToken(){return this.future(),this.stack.pop()}pushToken(A){this.stack.push(A)}pushTokens(A){this.stack.push(...A)}scanArgument(A){var t,r,n;if(A){if(this.consumeSpaces(),this.future().text!=="[")return null;t=this.popToken(),{tokens:n,end:r}=this.consumeArg(["]"])}else({tokens:n,start:t,end:r}=this.consumeArg());return this.pushToken(new fr("EOF",r.loc)),this.pushTokens(n),new fr("",ar.range(t,r))}consumeSpaces(){for(;;){var A=this.future();if(A.text===" ")this.stack.pop();else break}}consumeArg(A){var t=[],r=A&&A.length>0;r||this.consumeSpaces();var n=this.future(),i,o=0,g=0;do{if(i=this.popToken(),t.push(i),i.text==="{")++o;else if(i.text==="}"){if(--o,o===-1)throw new NA("Extra }",i)}else if(i.text==="EOF")throw new NA("Unexpected end of input in a macro argument, expected '"+(A&&r?A[g]:"}")+"'",i);if(A&&r)if((o===0||o===1&&A[g]==="{")&&i.text===A[g]){if(++g,g===A.length){t.splice(-g,g);break}}else g=0}while(o!==0||r);return n.text==="{"&&t[t.length-1].text==="}"&&(t.pop(),t.shift()),t.reverse(),{tokens:t,start:n,end:i}}consumeArgs(A,t){if(t){if(t.length!==A+1)throw new NA("The length of delimiters doesn't match the number of args!");for(var r=t[0],n=0;nthis.settings.maxExpand)throw new NA("Too many expansions: infinite loop or need to increase maxExpand setting")}expandOnce(A){var t=this.popToken(),r=t.text,n=t.noexpand?null:this._getExpansion(r);if(n==null||A&&n.unexpandable){if(A&&n==null&&r[0]==="\\"&&!this.isDefined(r))throw new NA("Undefined control sequence: "+r);return this.pushToken(t),!1}this.countExpansion(1);var i=n.tokens,o=this.consumeArgs(n.numArgs,n.delimiters);if(n.numArgs){i=i.slice();for(var g=i.length-1;g>=0;--g){var Q=i[g];if(Q.text==="#"){if(g===0)throw new NA("Incomplete placeholder at end of macro body",Q);if(Q=i[--g],Q.text==="#")i.splice(g+1,1);else if(/^[1-9]$/.test(Q.text))i.splice(g,2,...o[+Q.text-1]);else throw new NA("Not a valid argument number",Q)}}}return this.pushTokens(i),i.length}expandAfterFuture(){return this.expandOnce(),this.future()}expandNextToken(){for(;;)if(this.expandOnce()===!1){var A=this.stack.pop();return A.treatAsRelax&&(A.text="\\relax"),A}throw new Error}expandMacro(A){return this.macros.has(A)?this.expandTokens([new fr(A)]):void 0}expandTokens(A){var t=[],r=this.stack.length;for(this.pushTokens(A);this.stack.length>r;)if(this.expandOnce(!0)===!1){var n=this.stack.pop();n.treatAsRelax&&(n.noexpand=!1,n.treatAsRelax=!1),t.push(n)}return this.countExpansion(t.length),t}expandMacroAsText(A){var t=this.expandMacro(A);return t&&t.map(r=>r.text).join("")}_getExpansion(A){var t=this.macros.get(A);if(t==null)return t;if(A.length===1){var r=this.lexer.catcodes[A];if(r!=null&&r!==13)return}var n=typeof t=="function"?t(this):t;if(typeof n=="string"){var i=0;if(n.indexOf("#")!==-1)for(var o=n.replace(/##/g,"");o.indexOf("#"+(i+1))!==-1;)++i;for(var g=new tD(n,this.settings),Q=[],B=g.lex();B.text!=="EOF";)Q.push(B),B=g.lex();Q.reverse();var a={tokens:Q,numArgs:i};return a}return n}isDefined(A){return this.macros.has(A)||xi.hasOwnProperty(A)||Ze.math.hasOwnProperty(A)||Ze.text.hasOwnProperty(A)||Xp.hasOwnProperty(A)}isExpandable(A){var t=this.macros.get(A);return t!=null?typeof t=="string"||typeof t=="function"||!t.unexpandable:xi.hasOwnProperty(A)&&!xi[A].primitive}}var iD=/^[₊₋₌₍₎₀₁₂₃₄₅₆₇₈₉ₐₑₕᵢⱼₖₗₘₙₒₚᵣₛₜᵤᵥₓᵦᵧᵨᵩᵪ]/,ma=Object.freeze({"₊":"+","₋":"-","₌":"=","₍":"(","₎":")","₀":"0","₁":"1","₂":"2","₃":"3","₄":"4","₅":"5","₆":"6","₇":"7","₈":"8","₉":"9","ₐ":"a","ₑ":"e","ₕ":"h","ᵢ":"i","ⱼ":"j","ₖ":"k","ₗ":"l","ₘ":"m","ₙ":"n","ₒ":"o","ₚ":"p","ᵣ":"r","ₛ":"s","ₜ":"t","ᵤ":"u","ᵥ":"v","ₓ":"x","ᵦ":"β","ᵧ":"γ","ᵨ":"ρ","ᵩ":"ϕ","ᵪ":"χ","⁺":"+","⁻":"-","⁼":"=","⁽":"(","⁾":")","⁰":"0","¹":"1","²":"2","³":"3","⁴":"4","⁵":"5","⁶":"6","⁷":"7","⁸":"8","⁹":"9","ᴬ":"A","ᴮ":"B","ᴰ":"D","ᴱ":"E","ᴳ":"G","ᴴ":"H","ᴵ":"I","ᴶ":"J","ᴷ":"K","ᴸ":"L","ᴹ":"M","ᴺ":"N","ᴼ":"O","ᴾ":"P","ᴿ":"R","ᵀ":"T","ᵁ":"U","ⱽ":"V","ᵂ":"W","ᵃ":"a","ᵇ":"b","ᶜ":"c","ᵈ":"d","ᵉ":"e","ᶠ":"f","ᵍ":"g",ʰ:"h","ⁱ":"i",ʲ:"j","ᵏ":"k",ˡ:"l","ᵐ":"m",ⁿ:"n","ᵒ":"o","ᵖ":"p",ʳ:"r",ˢ:"s","ᵗ":"t","ᵘ":"u","ᵛ":"v",ʷ:"w",ˣ:"x",ʸ:"y","ᶻ":"z","ᵝ":"β","ᵞ":"γ","ᵟ":"δ","ᵠ":"ϕ","ᵡ":"χ","ᶿ":"θ"}),RC={"́":{text:"\\'",math:"\\acute"},"̀":{text:"\\`",math:"\\grave"},"̈":{text:'\\"',math:"\\ddot"},"̃":{text:"\\~",math:"\\tilde"},"̄":{text:"\\=",math:"\\bar"},"̆":{text:"\\u",math:"\\breve"},"̌":{text:"\\v",math:"\\check"},"̂":{text:"\\^",math:"\\hat"},"̇":{text:"\\.",math:"\\dot"},"̊":{text:"\\r",math:"\\mathring"},"̋":{text:"\\H"},"̧":{text:"\\c"}},oD={á:"á",à:"à",ä:"ä",ǟ:"ǟ",ã:"ã",ā:"ā",ă:"ă",ắ:"ắ",ằ:"ằ",ẵ:"ẵ",ǎ:"ǎ",â:"â",ấ:"ấ",ầ:"ầ",ẫ:"ẫ",ȧ:"ȧ",ǡ:"ǡ",å:"å",ǻ:"ǻ",ḃ:"ḃ",ć:"ć",ḉ:"ḉ",č:"č",ĉ:"ĉ",ċ:"ċ",ç:"ç",ď:"ď",ḋ:"ḋ",ḑ:"ḑ",é:"é",è:"è",ë:"ë",ẽ:"ẽ",ē:"ē",ḗ:"ḗ",ḕ:"ḕ",ĕ:"ĕ",ḝ:"ḝ",ě:"ě",ê:"ê",ế:"ế",ề:"ề",ễ:"ễ",ė:"ė",ȩ:"ȩ",ḟ:"ḟ",ǵ:"ǵ",ḡ:"ḡ",ğ:"ğ",ǧ:"ǧ",ĝ:"ĝ",ġ:"ġ",ģ:"ģ",ḧ:"ḧ",ȟ:"ȟ",ĥ:"ĥ",ḣ:"ḣ",ḩ:"ḩ",í:"í",ì:"ì",ï:"ï",ḯ:"ḯ",ĩ:"ĩ",ī:"ī",ĭ:"ĭ",ǐ:"ǐ",î:"î",ǰ:"ǰ",ĵ:"ĵ",ḱ:"ḱ",ǩ:"ǩ",ķ:"ķ",ĺ:"ĺ",ľ:"ľ",ļ:"ļ",ḿ:"ḿ",ṁ:"ṁ",ń:"ń",ǹ:"ǹ",ñ:"ñ",ň:"ň",ṅ:"ṅ",ņ:"ņ",ó:"ó",ò:"ò",ö:"ö",ȫ:"ȫ",õ:"õ",ṍ:"ṍ",ṏ:"ṏ",ȭ:"ȭ",ō:"ō",ṓ:"ṓ",ṑ:"ṑ",ŏ:"ŏ",ǒ:"ǒ",ô:"ô",ố:"ố",ồ:"ồ",ỗ:"ỗ",ȯ:"ȯ",ȱ:"ȱ",ő:"ő",ṕ:"ṕ",ṗ:"ṗ",ŕ:"ŕ",ř:"ř",ṙ:"ṙ",ŗ:"ŗ",ś:"ś",ṥ:"ṥ",š:"š",ṧ:"ṧ",ŝ:"ŝ",ṡ:"ṡ",ş:"ş",ẗ:"ẗ",ť:"ť",ṫ:"ṫ",ţ:"ţ",ú:"ú",ù:"ù",ü:"ü",ǘ:"ǘ",ǜ:"ǜ",ǖ:"ǖ",ǚ:"ǚ",ũ:"ũ",ṹ:"ṹ",ū:"ū",ṻ:"ṻ",ŭ:"ŭ",ǔ:"ǔ",û:"û",ů:"ů",ű:"ű",ṽ:"ṽ",ẃ:"ẃ",ẁ:"ẁ",ẅ:"ẅ",ŵ:"ŵ",ẇ:"ẇ",ẘ:"ẘ",ẍ:"ẍ",ẋ:"ẋ",ý:"ý",ỳ:"ỳ",ÿ:"ÿ",ỹ:"ỹ",ȳ:"ȳ",ŷ:"ŷ",ẏ:"ẏ",ẙ:"ẙ",ź:"ź",ž:"ž",ẑ:"ẑ",ż:"ż",Á:"Á",À:"À",Ä:"Ä",Ǟ:"Ǟ",Ã:"Ã",Ā:"Ā",Ă:"Ă",Ắ:"Ắ",Ằ:"Ằ",Ẵ:"Ẵ",Ǎ:"Ǎ",Â:"Â",Ấ:"Ấ",Ầ:"Ầ",Ẫ:"Ẫ",Ȧ:"Ȧ",Ǡ:"Ǡ",Å:"Å",Ǻ:"Ǻ",Ḃ:"Ḃ",Ć:"Ć",Ḉ:"Ḉ",Č:"Č",Ĉ:"Ĉ",Ċ:"Ċ",Ç:"Ç",Ď:"Ď",Ḋ:"Ḋ",Ḑ:"Ḑ",É:"É",È:"È",Ë:"Ë",Ẽ:"Ẽ",Ē:"Ē",Ḗ:"Ḗ",Ḕ:"Ḕ",Ĕ:"Ĕ",Ḝ:"Ḝ",Ě:"Ě",Ê:"Ê",Ế:"Ế",Ề:"Ề",Ễ:"Ễ",Ė:"Ė",Ȩ:"Ȩ",Ḟ:"Ḟ",Ǵ:"Ǵ",Ḡ:"Ḡ",Ğ:"Ğ",Ǧ:"Ǧ",Ĝ:"Ĝ",Ġ:"Ġ",Ģ:"Ģ",Ḧ:"Ḧ",Ȟ:"Ȟ",Ĥ:"Ĥ",Ḣ:"Ḣ",Ḩ:"Ḩ",Í:"Í",Ì:"Ì",Ï:"Ï",Ḯ:"Ḯ",Ĩ:"Ĩ",Ī:"Ī",Ĭ:"Ĭ",Ǐ:"Ǐ",Î:"Î",İ:"İ",Ĵ:"Ĵ",Ḱ:"Ḱ",Ǩ:"Ǩ",Ķ:"Ķ",Ĺ:"Ĺ",Ľ:"Ľ",Ļ:"Ļ",Ḿ:"Ḿ",Ṁ:"Ṁ",Ń:"Ń",Ǹ:"Ǹ",Ñ:"Ñ",Ň:"Ň",Ṅ:"Ṅ",Ņ:"Ņ",Ó:"Ó",Ò:"Ò",Ö:"Ö",Ȫ:"Ȫ",Õ:"Õ",Ṍ:"Ṍ",Ṏ:"Ṏ",Ȭ:"Ȭ",Ō:"Ō",Ṓ:"Ṓ",Ṑ:"Ṑ",Ŏ:"Ŏ",Ǒ:"Ǒ",Ô:"Ô",Ố:"Ố",Ồ:"Ồ",Ỗ:"Ỗ",Ȯ:"Ȯ",Ȱ:"Ȱ",Ő:"Ő",Ṕ:"Ṕ",Ṗ:"Ṗ",Ŕ:"Ŕ",Ř:"Ř",Ṙ:"Ṙ",Ŗ:"Ŗ",Ś:"Ś",Ṥ:"Ṥ",Š:"Š",Ṧ:"Ṧ",Ŝ:"Ŝ",Ṡ:"Ṡ",Ş:"Ş",Ť:"Ť",Ṫ:"Ṫ",Ţ:"Ţ",Ú:"Ú",Ù:"Ù",Ü:"Ü",Ǘ:"Ǘ",Ǜ:"Ǜ",Ǖ:"Ǖ",Ǚ:"Ǚ",Ũ:"Ũ",Ṹ:"Ṹ",Ū:"Ū",Ṻ:"Ṻ",Ŭ:"Ŭ",Ǔ:"Ǔ",Û:"Û",Ů:"Ů",Ű:"Ű",Ṽ:"Ṽ",Ẃ:"Ẃ",Ẁ:"Ẁ",Ẅ:"Ẅ",Ŵ:"Ŵ",Ẇ:"Ẇ",Ẍ:"Ẍ",Ẋ:"Ẋ",Ý:"Ý",Ỳ:"Ỳ",Ÿ:"Ÿ",Ỹ:"Ỹ",Ȳ:"Ȳ",Ŷ:"Ŷ",Ẏ:"Ẏ",Ź:"Ź",Ž:"Ž",Ẑ:"Ẑ",Ż:"Ż",ά:"ά",ὰ:"ὰ",ᾱ:"ᾱ",ᾰ:"ᾰ",έ:"έ",ὲ:"ὲ",ή:"ή",ὴ:"ὴ",ί:"ί",ὶ:"ὶ",ϊ:"ϊ",ΐ:"ΐ",ῒ:"ῒ",ῑ:"ῑ",ῐ:"ῐ",ό:"ό",ὸ:"ὸ",ύ:"ύ",ὺ:"ὺ",ϋ:"ϋ",ΰ:"ΰ",ῢ:"ῢ",ῡ:"ῡ",ῠ:"ῠ",ώ:"ώ",ὼ:"ὼ",Ύ:"Ύ",Ὺ:"Ὺ",Ϋ:"Ϋ",Ῡ:"Ῡ",Ῠ:"Ῠ",Ώ:"Ώ",Ὼ:"Ὼ"};class IE{constructor(A,t){this.mode=void 0,this.gullet=void 0,this.settings=void 0,this.leftrightDepth=void 0,this.nextToken=void 0,this.mode="math",this.gullet=new UJ(A,t,this.mode),this.settings=t,this.leftrightDepth=0}expect(A,t){if(t===void 0&&(t=!0),this.fetch().text!==A)throw new NA("Expected '"+A+"', got '"+this.fetch().text+"'",this.fetch());t&&this.consume()}consume(){this.nextToken=null}fetch(){return this.nextToken==null&&(this.nextToken=this.gullet.expandNextToken()),this.nextToken}switchMode(A){this.mode=A,this.gullet.switchMode(A)}parse(){this.settings.globalGroup||this.gullet.beginGroup(),this.settings.colorIsTextColor&&this.gullet.macros.set("\\color","\\textcolor");try{var A=this.parseExpression(!1);return this.expect("EOF"),this.settings.globalGroup||this.gullet.endGroup(),A}finally{this.gullet.endGroups()}}subparse(A){var t=this.nextToken;this.consume(),this.gullet.pushToken(new fr("}")),this.gullet.pushTokens(A);var r=this.parseExpression(!1);return this.expect("}"),this.nextToken=t,r}parseExpression(A,t){for(var r=[];;){this.mode==="math"&&this.consumeSpaces();var n=this.fetch();if(IE.endOfExpression.indexOf(n.text)!==-1||t&&n.text===t||A&&xi[n.text]&&xi[n.text].infix)break;var i=this.parseAtom(t);if(i){if(i.type==="internal")continue}else break;r.push(i)}return this.mode==="text"&&this.formLigatures(r),this.handleInfixNodes(r)}handleInfixNodes(A){for(var t=-1,r,n=0;n=0&&this.settings.reportNonstrict("unicodeTextInMathMode",'Latin-1/Unicode text character "'+t[0]+'" used in math mode',A);var g=Ze[this.mode][t].group,Q=ar.range(A),B;if(pS.hasOwnProperty(g)){var a=g;B={type:"atom",mode:this.mode,family:a,loc:Q,text:t}}else B={type:g,mode:this.mode,loc:Q,text:t};o=B}else if(t.charCodeAt(0)>=128)this.settings.strict&&(gp(t.charCodeAt(0))?this.mode==="math"&&this.settings.reportNonstrict("unicodeTextInMathMode",'Unicode text character "'+t[0]+'" used in math mode',A):this.settings.reportNonstrict("unknownSymbol",'Unrecognized Unicode character "'+t[0]+'"'+(" ("+t.charCodeAt(0)+")"),A)),o={type:"textord",mode:"text",loc:ar.range(A),text:t};else return null;if(this.consume(),i)for(var s=0;sTJ.renderToString(t.text,{...e,displayMode:t.displayMode})+(A?` `:"")}function _J(e,A){const t=e&&e.nonStandard,r=t?YJ:HJ;return{name:"inlineKatex",level:"inline",start(n){let i,o=n;for(;o;){if(i=o.indexOf("$"),i===-1)return;if((t?i>-1:i===0||o.charAt(i-1)===" ")&&o.substring(i).match(r))return i;o=o.substring(i+1).replace(/^\$+/,"")}},tokenizer(n,i){const o=n.match(r);if(o)return{type:"inlineKatex",raw:o[0],text:o[2].trim(),displayMode:o[1].length===2}},renderer:A}}function jJ(e,A){return{name:"blockKatex",level:"block",tokenizer(t,r){const n=t.match(zJ);if(n)return{type:"blockKatex",raw:n[0],text:n[2].trim(),displayMode:n[1].length===2}},renderer:A}}function VJ(e={}){const{highlight:A,container:t}=e;return{async:!0,async walkTokens(r){var n;if(r.type!=="code"||typeof A!="function")return;const[i="text",...o]=((n=r.lang)==null?void 0:n.split(" "))??[],{text:g}=r,Q=await A(g,i,o),B=t?t.replace("%l",String(i).toUpperCase()).replace("%s",Q).replace("%t",g):Q;Object.assign(r,{type:"html",block:!0,text:`${B} `})}}}const WJ="modulepreload",ZJ=function(e){return"/"+e},QD={},p=function(A,t,r){let n=Promise.resolve();if(t&&t.length>0){let B=function(a){return Promise.all(a.map(s=>Promise.resolve(s).then(C=>({status:"fulfilled",value:C}),C=>({status:"rejected",reason:C}))))};var o=B;document.getElementsByTagName("link");const g=document.querySelector("meta[property=csp-nonce]"),Q=g?.nonce||g?.getAttribute("nonce");n=B(t.map(a=>{if(a=ZJ(a),a in QD)return;QD[a]=!0;const s=a.endsWith(".css"),C=s?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${a}"]${C}`))return;const E=document.createElement("link");if(E.rel=s?"stylesheet":WJ,s||(E.as="script"),E.crossOrigin="",E.href=a,Q&&E.setAttribute("nonce",Q),document.head.appendChild(E),s)return new Promise((I,c)=>{E.addEventListener("load",I),E.addEventListener("error",()=>c(new Error(`Unable to preload CSS for ${a}`)))})}))}function i(g){const Q=new Event("vite:preloadError",{cancelable:!0});if(Q.payload=g,window.dispatchEvent(Q),!Q.defaultPrevented)throw g}return n.then(g=>{for(const Q of g||[])Q.status==="rejected"&&i(Q.reason);return A().catch(i)})};function XJ(e){return ru(e)}function ru(e){return Array.isArray(e)?$J(e):e instanceof RegExp?e:typeof e=="object"?AU(e):e}function $J(e){let A=[];for(let t=0,r=e.length;t{for(let r in t)e[r]=t[r]}),e}function tk(e){const A=~e.lastIndexOf("/")||~e.lastIndexOf("\\");return A===0?e:~A===e.length-1?tk(e.substring(0,e.length-1)):e.substr(~A+1)}var OC=/\$(\d+)|\${(\d+):\/(downcase|upcase)}/g,pa=class{static hasCaptures(e){return e===null?!1:(OC.lastIndex=0,OC.test(e))}static replaceCaptures(e,A,t){return e.replace(OC,(r,n,i,o)=>{let g=t[parseInt(n||i,10)];if(g){let Q=A.substring(g.start,g.end);for(;Q[0]===".";)Q=Q.substring(1);switch(o){case"downcase":return Q.toLowerCase();case"upcase":return Q.toUpperCase();default:return Q}}else return r})}};function rk(e,A){return eA?1:0}function nk(e,A){if(e===null&&A===null)return 0;if(!e)return-1;if(!A)return 1;let t=e.length,r=A.length;if(t===r){for(let n=0;nthis._root.match(e));getColorMap(){return this._colorMap.getColorMap()}getDefaults(){return this._defaults}match(e){if(e===null)return this._defaults;const A=e.scopeName,r=this._cachedMatchRoot.get(A).find(n=>eU(e.parent,n.parentScopes));return r?new gk(r.fontStyle,r.foreground,r.background):null}},qC=class Wa{constructor(A,t){this.parent=A,this.scopeName=t}static push(A,t){for(const r of t)A=new Wa(A,r);return A}static from(...A){let t=null;for(let r=0;r"){if(t===A.length-1)return!1;r=A[++t],n=!0}for(;e&&!tU(e.scopeName,r);){if(n)return!1;e=e.parent}if(!e)return!1;e=e.parent}return!0}function tU(e,A){return A===e||e.startsWith(A)&&e[A.length]==="."}var gk=class{constructor(e,A,t){this.fontStyle=e,this.foregroundId=A,this.backgroundId=t}};function rU(e){if(!e)return[];if(!e.settings||!Array.isArray(e.settings))return[];let A=e.settings,t=[],r=0;for(let n=0,i=A.length;n1&&(u=I.slice(0,I.length-1),u.reverse()),t[r++]=new nU(c,u,n,Q,B,a)}}return t}var nU=class{constructor(e,A,t,r,n,i){this.scope=e,this.parentScopes=A,this.index=t,this.fontStyle=r,this.foreground=n,this.background=i}},_t=(e=>(e[e.NotSet=-1]="NotSet",e[e.None=0]="None",e[e.Italic=1]="Italic",e[e.Bold=2]="Bold",e[e.Underline=4]="Underline",e[e.Strikethrough=8]="Strikethrough",e))(_t||{});function iU(e,A){e.sort((Q,B)=>{let a=rk(Q.scope,B.scope);return a!==0||(a=nk(Q.parentScopes,B.parentScopes),a!==0)?a:Q.index-B.index});let t=0,r="#000000",n="#ffffff";for(;e.length>=1&&e[0].scope==="";){let Q=e.shift();Q.fontStyle!==-1&&(t=Q.fontStyle),Q.foreground!==null&&(r=Q.foreground),Q.background!==null&&(n=Q.background)}let i=new oU(A),o=new gk(t,i.getId(r),i.getId(n)),g=new QU(new nl(0,null,-1,0,0),[]);for(let Q=0,B=e.length;QA?console.log("how did this happen?"):this.scopeDepth=A,t!==-1&&(this.fontStyle=t),r!==0&&(this.foreground=r),n!==0&&(this.background=n)}},QU=class il{constructor(A,t=[],r={}){this._mainRule=A,this._children=r,this._rulesWithParentScopes=t}_rulesWithParentScopes;static _cmpBySpecificity(A,t){if(A.scopeDepth!==t.scopeDepth)return t.scopeDepth-A.scopeDepth;let r=0,n=0;for(;A.parentScopes[r]===">"&&r++,t.parentScopes[n]===">"&&n++,!(r>=A.parentScopes.length||n>=t.parentScopes.length);){const i=t.parentScopes[n].length-A.parentScopes[r].length;if(i!==0)return i;r++,n++}return t.parentScopes.length-A.parentScopes.length}match(A){if(A!==""){let r=A.indexOf("."),n,i;if(r===-1?(n=A,i=""):(n=A.substring(0,r),i=A.substring(r+1)),this._children.hasOwnProperty(n))return this._children[n].match(i)}const t=this._rulesWithParentScopes.concat(this._mainRule);return t.sort(il._cmpBySpecificity),t}insert(A,t,r,n,i,o){if(t===""){this._doInsertHere(A,r,n,i,o);return}let g=t.indexOf("."),Q,B;g===-1?(Q=t,B=""):(Q=t.substring(0,g),B=t.substring(g+1));let a;this._children.hasOwnProperty(Q)?a=this._children[Q]:(a=new il(this._mainRule.clone(),nl.cloneArr(this._rulesWithParentScopes)),this._children[Q]=a),a.insert(A+1,B,r,n,i,o)}_doInsertHere(A,t,r,n,i){if(t===null){this._mainRule.acceptOverwrite(A,r,n,i);return}for(let o=0,g=this._rulesWithParentScopes.length;o>>0}static getTokenType(A){return(A&768)>>>8}static containsBalancedBrackets(A){return(A&1024)!==0}static getFontStyle(A){return(A&30720)>>>11}static getForeground(A){return(A&16744448)>>>15}static getBackground(A){return(A&4278190080)>>>24}static set(A,t,r,n,i,o,g){let Q=vr.getLanguageId(A),B=vr.getTokenType(A),a=vr.containsBalancedBrackets(A)?1:0,s=vr.getFontStyle(A),C=vr.getForeground(A),E=vr.getBackground(A);return t!==0&&(Q=t),r!==8&&(B=r),n!==null&&(a=n?1:0),i!==-1&&(s=i),o!==0&&(C=o),g!==0&&(E=g),(Q<<0|B<<8|a<<10|s<<11|C<<15|E<<24)>>>0}};function ps(e,A){const t=[],r=BU(e);let n=r.next();for(;n!==null;){let Q=0;if(n.length===2&&n.charAt(1)===":"){switch(n.charAt(0)){case"R":Q=1;break;case"L":Q=-1;break;default:console.log(`Unknown priority ${n} in scope selector`)}n=r.next()}let B=o();if(t.push({matcher:B,priority:Q}),n!==",")break;n=r.next()}return t;function i(){if(n==="-"){n=r.next();const Q=i();return B=>!!Q&&!Q(B)}if(n==="("){n=r.next();const Q=g();return n===")"&&(n=r.next()),Q}if(aD(n)){const Q=[];do Q.push(n),n=r.next();while(aD(n));return B=>A(Q,B)}return null}function o(){const Q=[];let B=i();for(;B;)Q.push(B),B=i();return a=>Q.every(s=>s(a))}function g(){const Q=[];let B=o();for(;B&&(Q.push(B),n==="|"||n===",");){do n=r.next();while(n==="|"||n===",");B=o()}return a=>Q.some(s=>s(a))}}function aD(e){return!!e&&!!e.match(/[\w\.:]+/)}function BU(e){let A=/([LR]:|[\w\.:][\w\.:\-]*|[\,\|\-\(\)])/g,t=A.exec(e);return{next:()=>{if(!t)return null;const r=t[0];return t=A.exec(e),r}}}function Bk(e){typeof e.dispose=="function"&&e.dispose()}var eB=class{constructor(e){this.scopeName=e}toKey(){return this.scopeName}},aU=class{constructor(e,A){this.scopeName=e,this.ruleName=A}toKey(){return`${this.scopeName}#${this.ruleName}`}},sU=class{_references=[];_seenReferenceKeys=new Set;get references(){return this._references}visitedRule=new Set;add(e){const A=e.toKey();this._seenReferenceKeys.has(A)||(this._seenReferenceKeys.add(A),this._references.push(e))}},EU=class{constructor(e,A){this.repo=e,this.initialScopeName=A,this.seenFullScopeRequests.add(this.initialScopeName),this.Q=[new eB(this.initialScopeName)]}seenFullScopeRequests=new Set;seenPartialScopeRequests=new Set;Q;processQueue(){const e=this.Q;this.Q=[];const A=new sU;for(const t of e)CU(t,this.initialScopeName,this.repo,A);for(const t of A.references)if(t instanceof eB){if(this.seenFullScopeRequests.has(t.scopeName))continue;this.seenFullScopeRequests.add(t.scopeName),this.Q.push(t)}else{if(this.seenFullScopeRequests.has(t.scopeName)||this.seenPartialScopeRequests.has(t.toKey()))continue;this.seenPartialScopeRequests.add(t.toKey()),this.Q.push(t)}}};function CU(e,A,t,r){const n=t.lookup(e.scopeName);if(!n){if(e.scopeName===A)throw new Error(`No grammar provided for <${A}>`);return}const i=t.lookup(A);e instanceof eB?Za({baseGrammar:i,selfGrammar:n},r):ol(e.ruleName,{baseGrammar:i,selfGrammar:n,repository:n.repository},r);const o=t.injections(e.scopeName);if(o)for(const g of o)r.add(new eB(g))}function ol(e,A,t){if(A.repository&&A.repository[e]){const r=A.repository[e];ks([r],A,t)}}function Za(e,A){e.selfGrammar.patterns&&Array.isArray(e.selfGrammar.patterns)&&ks(e.selfGrammar.patterns,{...e,repository:e.selfGrammar.repository},A),e.selfGrammar.injections&&ks(Object.values(e.selfGrammar.injections),{...e,repository:e.selfGrammar.repository},A)}function ks(e,A,t){for(const r of e){if(t.visitedRule.has(r))continue;t.visitedRule.add(r);const n=r.repository?ek({},A.repository,r.repository):A.repository;Array.isArray(r.patterns)&&ks(r.patterns,{...A,repository:n},t);const i=r.include;if(!i)continue;const o=ak(i);switch(o.kind){case 0:Za({...A,selfGrammar:A.baseGrammar},t);break;case 1:Za(A,t);break;case 2:ol(o.ruleName,{...A,repository:n},t);break;case 3:case 4:const g=o.scopeName===A.selfGrammar.scopeName?A.selfGrammar:o.scopeName===A.baseGrammar.scopeName?A.baseGrammar:void 0;if(g){const Q={baseGrammar:A.baseGrammar,selfGrammar:g,repository:n};o.kind===4?ol(o.ruleName,Q,t):Za(Q,t)}else o.kind===4?t.add(new aU(o.scopeName,o.ruleName)):t.add(new eB(o.scopeName));break}}}var IU=class{kind=0},lU=class{kind=1},cU=class{constructor(e){this.ruleName=e}kind=2},uU=class{constructor(e){this.scopeName=e}kind=3},dU=class{constructor(e,A){this.scopeName=e,this.ruleName=A}kind=4};function ak(e){if(e==="$base")return new IU;if(e==="$self")return new lU;const A=e.indexOf("#");if(A===-1)return new uU(e);if(A===0)return new cU(e.substring(1));{const t=e.substring(0,A),r=e.substring(A+1);return new dU(t,r)}}var hU=/\\(\d+)/,sD=/\\(\d+)/g,DU=-1,sk=-2;var vB=class{$location;id;_nameIsCapturing;_name;_contentNameIsCapturing;_contentName;constructor(e,A,t,r){this.$location=e,this.id=A,this._name=t||null,this._nameIsCapturing=pa.hasCaptures(this._name),this._contentName=r||null,this._contentNameIsCapturing=pa.hasCaptures(this._contentName)}get debugName(){const e=this.$location?`${tk(this.$location.filename)}:${this.$location.line}`:"unknown";return`${this.constructor.name}#${this.id} @ ${e}`}getName(e,A){return!this._nameIsCapturing||this._name===null||e===null||A===null?this._name:pa.replaceCaptures(this._name,e,A)}getContentName(e,A){return!this._contentNameIsCapturing||this._contentName===null?this._contentName:pa.replaceCaptures(this._contentName,e,A)}},fU=class extends vB{retokenizeCapturedWithRuleId;constructor(e,A,t,r,n){super(e,A,t,r),this.retokenizeCapturedWithRuleId=n}dispose(){}collectPatterns(e,A){throw new Error("Not supported!")}compile(e,A){throw new Error("Not supported!")}compileAG(e,A,t,r){throw new Error("Not supported!")}},wU=class extends vB{_match;captures;_cachedCompiledPatterns;constructor(e,A,t,r,n){super(e,A,t,null),this._match=new tB(r,this.id),this.captures=n,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}get debugMatchRegExp(){return`${this._match.source}`}collectPatterns(e,A){A.push(this._match)}compile(e,A){return this._getCachedCompiledPatterns(e).compile(e)}compileAG(e,A,t,r){return this._getCachedCompiledPatterns(e).compileAG(e,t,r)}_getCachedCompiledPatterns(e){return this._cachedCompiledPatterns||(this._cachedCompiledPatterns=new rB,this.collectPatterns(e,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},ED=class extends vB{hasMissingPatterns;patterns;_cachedCompiledPatterns;constructor(e,A,t,r,n){super(e,A,t,r),this.patterns=n.patterns,this.hasMissingPatterns=n.hasMissingPatterns,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}collectPatterns(e,A){for(const t of this.patterns)e.getRule(t).collectPatterns(e,A)}compile(e,A){return this._getCachedCompiledPatterns(e).compile(e)}compileAG(e,A,t,r){return this._getCachedCompiledPatterns(e).compileAG(e,t,r)}_getCachedCompiledPatterns(e){return this._cachedCompiledPatterns||(this._cachedCompiledPatterns=new rB,this.collectPatterns(e,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},gl=class extends vB{_begin;beginCaptures;_end;endHasBackReferences;endCaptures;applyEndPatternLast;hasMissingPatterns;patterns;_cachedCompiledPatterns;constructor(e,A,t,r,n,i,o,g,Q,B){super(e,A,t,r),this._begin=new tB(n,this.id),this.beginCaptures=i,this._end=new tB(o||"￿",-1),this.endHasBackReferences=this._end.hasBackReferences,this.endCaptures=g,this.applyEndPatternLast=Q||!1,this.patterns=B.patterns,this.hasMissingPatterns=B.hasMissingPatterns,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}get debugBeginRegExp(){return`${this._begin.source}`}get debugEndRegExp(){return`${this._end.source}`}getEndWithResolvedBackReferences(e,A){return this._end.resolveBackReferences(e,A)}collectPatterns(e,A){A.push(this._begin)}compile(e,A){return this._getCachedCompiledPatterns(e,A).compile(e)}compileAG(e,A,t,r){return this._getCachedCompiledPatterns(e,A).compileAG(e,t,r)}_getCachedCompiledPatterns(e,A){if(!this._cachedCompiledPatterns){this._cachedCompiledPatterns=new rB;for(const t of this.patterns)e.getRule(t).collectPatterns(e,this._cachedCompiledPatterns);this.applyEndPatternLast?this._cachedCompiledPatterns.push(this._end.hasBackReferences?this._end.clone():this._end):this._cachedCompiledPatterns.unshift(this._end.hasBackReferences?this._end.clone():this._end)}return this._end.hasBackReferences&&(this.applyEndPatternLast?this._cachedCompiledPatterns.setSource(this._cachedCompiledPatterns.length()-1,A):this._cachedCompiledPatterns.setSource(0,A)),this._cachedCompiledPatterns}},ys=class extends vB{_begin;beginCaptures;whileCaptures;_while;whileHasBackReferences;hasMissingPatterns;patterns;_cachedCompiledPatterns;_cachedCompiledWhilePatterns;constructor(e,A,t,r,n,i,o,g,Q){super(e,A,t,r),this._begin=new tB(n,this.id),this.beginCaptures=i,this.whileCaptures=g,this._while=new tB(o,sk),this.whileHasBackReferences=this._while.hasBackReferences,this.patterns=Q.patterns,this.hasMissingPatterns=Q.hasMissingPatterns,this._cachedCompiledPatterns=null,this._cachedCompiledWhilePatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null),this._cachedCompiledWhilePatterns&&(this._cachedCompiledWhilePatterns.dispose(),this._cachedCompiledWhilePatterns=null)}get debugBeginRegExp(){return`${this._begin.source}`}get debugWhileRegExp(){return`${this._while.source}`}getWhileWithResolvedBackReferences(e,A){return this._while.resolveBackReferences(e,A)}collectPatterns(e,A){A.push(this._begin)}compile(e,A){return this._getCachedCompiledPatterns(e).compile(e)}compileAG(e,A,t,r){return this._getCachedCompiledPatterns(e).compileAG(e,t,r)}_getCachedCompiledPatterns(e){if(!this._cachedCompiledPatterns){this._cachedCompiledPatterns=new rB;for(const A of this.patterns)e.getRule(A).collectPatterns(e,this._cachedCompiledPatterns)}return this._cachedCompiledPatterns}compileWhile(e,A){return this._getCachedCompiledWhilePatterns(e,A).compile(e)}compileWhileAG(e,A,t,r){return this._getCachedCompiledWhilePatterns(e,A).compileAG(e,t,r)}_getCachedCompiledWhilePatterns(e,A){return this._cachedCompiledWhilePatterns||(this._cachedCompiledWhilePatterns=new rB,this._cachedCompiledWhilePatterns.push(this._while.hasBackReferences?this._while.clone():this._while)),this._while.hasBackReferences&&this._cachedCompiledWhilePatterns.setSource(0,A||"￿"),this._cachedCompiledWhilePatterns}},Ek=class zt{static createCaptureRule(A,t,r,n,i){return A.registerRule(o=>new fU(t,o,r,n,i))}static getCompiledRuleId(A,t,r){return A.id||t.registerRule(n=>{if(A.id=n,A.match)return new wU(A.$vscodeTextmateLocation,A.id,A.name,A.match,zt._compileCaptures(A.captures,t,r));if(typeof A.begin>"u"){A.repository&&(r=ek({},r,A.repository));let i=A.patterns;return typeof i>"u"&&A.include&&(i=[{include:A.include}]),new ED(A.$vscodeTextmateLocation,A.id,A.name,A.contentName,zt._compilePatterns(i,t,r))}return A.while?new ys(A.$vscodeTextmateLocation,A.id,A.name,A.contentName,A.begin,zt._compileCaptures(A.beginCaptures||A.captures,t,r),A.while,zt._compileCaptures(A.whileCaptures||A.captures,t,r),zt._compilePatterns(A.patterns,t,r)):new gl(A.$vscodeTextmateLocation,A.id,A.name,A.contentName,A.begin,zt._compileCaptures(A.beginCaptures||A.captures,t,r),A.end,zt._compileCaptures(A.endCaptures||A.captures,t,r),A.applyEndPatternLast,zt._compilePatterns(A.patterns,t,r))}),A.id}static _compileCaptures(A,t,r){let n=[];if(A){let i=0;for(const o in A){if(o==="$vscodeTextmateLocation")continue;const g=parseInt(o,10);g>i&&(i=g)}for(let o=0;o<=i;o++)n[o]=null;for(const o in A){if(o==="$vscodeTextmateLocation")continue;const g=parseInt(o,10);let Q=0;A[o].patterns&&(Q=zt.getCompiledRuleId(A[o],t,r)),n[g]=zt.createCaptureRule(t,A[o].$vscodeTextmateLocation,A[o].name,A[o].contentName,Q)}}return n}static _compilePatterns(A,t,r){let n=[];if(A)for(let i=0,o=A.length;iA.substring(n.start,n.end));return sD.lastIndex=0,this.source.replace(sD,(n,i)=>ik(r[parseInt(i,10)]||""))}_buildAnchorCache(){if(typeof this.source!="string")throw new Error("This method should only be called if the source is a string");let A=[],t=[],r=[],n=[],i,o,g,Q;for(i=0,o=this.source.length;it.source);this._cached=new CD(e,A,this._items.map(t=>t.ruleId))}return this._cached}compileAG(e,A,t){return this._hasAnchors?A?t?(this._anchorCache.A1_G1||(this._anchorCache.A1_G1=this._resolveAnchors(e,A,t)),this._anchorCache.A1_G1):(this._anchorCache.A1_G0||(this._anchorCache.A1_G0=this._resolveAnchors(e,A,t)),this._anchorCache.A1_G0):t?(this._anchorCache.A0_G1||(this._anchorCache.A0_G1=this._resolveAnchors(e,A,t)),this._anchorCache.A0_G1):(this._anchorCache.A0_G0||(this._anchorCache.A0_G0=this._resolveAnchors(e,A,t)),this._anchorCache.A0_G0):this.compile(e)}_resolveAnchors(e,A,t){let r=this._items.map(n=>n.resolveAnchors(A,t));return new CD(e,r,this._items.map(n=>n.ruleId))}},CD=class{constructor(e,A,t){this.regExps=A,this.rules=t,this.scanner=e.createOnigScanner(A)}scanner;dispose(){typeof this.scanner.dispose=="function"&&this.scanner.dispose()}toString(){const e=[];for(let A=0,t=this.rules.length;A{const t=this._scopeToLanguage(A),r=this._toStandardTokenType(A);return new TC(t,r)});_scopeToLanguage(A){return this._embeddedLanguagesMatcher.match(A)||0}_toStandardTokenType(A){const t=A.match(Ql.STANDARD_TOKEN_TYPE_REGEXP);if(!t)return 8;switch(t[1]){case"comment":return 1;case"string":return 2;case"regex":return 3;case"meta.embedded":return 0}throw new Error("Unexpected match for standard token type!")}static STANDARD_TOKEN_TYPE_REGEXP=/\b(comment|string|regex|meta\.embedded)\b/},pU=class{values;scopesRegExp;constructor(e){if(e.length===0)this.values=null,this.scopesRegExp=null;else{this.values=new Map(e);const A=e.map(([t,r])=>ik(t));A.sort(),A.reverse(),this.scopesRegExp=new RegExp(`^((${A.join(")|(")}))($|\\.)`,"")}}match(e){if(!this.scopesRegExp)return;const A=e.match(this.scopesRegExp);if(A)return this.values.get(A[1])}},ID=class{constructor(e,A){this.stack=e,this.stoppedEarly=A}};function Ik(e,A,t,r,n,i,o,g){const Q=A.content.length;let B=!1,a=-1;if(o){const E=kU(e,A,t,r,n,i);n=E.stack,r=E.linePos,t=E.isFirstLine,a=E.anchorPosition}const s=Date.now();for(;!B;){if(g!==0&&Date.now()-s>g)return new ID(n,!0);C()}return new ID(n,!1);function C(){const E=yU(e,A,t,r,n,a);if(!E){i.produce(n,Q),B=!0;return}const I=E.captureIndices,c=E.matchedRuleId,u=I&&I.length>0?I[0].end>r:!1;if(c===DU){const h=n.getRule(e);i.produce(n,I[0].start),n=n.withContentNameScopesList(n.nameScopesList),FQ(e,A,t,n,i,h.endCaptures,I),i.produce(n,I[0].end);const d=n;if(n=n.parent,a=d.getAnchorPos(),!u&&d.getEnterPos()===r){n=d,i.produce(n,Q),B=!0;return}}else{const h=e.getRule(c);i.produce(n,I[0].start);const d=n,f=h.getName(A.content,I),m=n.contentNameScopesList.pushAttributed(f,e);if(n=n.push(c,r,a,I[0].end===Q,null,m,m),h instanceof gl){const k=h;FQ(e,A,t,n,i,k.beginCaptures,I),i.produce(n,I[0].end),a=I[0].end;const N=k.getContentName(A.content,I),F=m.pushAttributed(N,e);if(n=n.withContentNameScopesList(F),k.endHasBackReferences&&(n=n.withEndRule(k.getEndWithResolvedBackReferences(A.content,I))),!u&&d.hasSameRuleAs(n)){n=n.pop(),i.produce(n,Q),B=!0;return}}else if(h instanceof ys){const k=h;FQ(e,A,t,n,i,k.beginCaptures,I),i.produce(n,I[0].end),a=I[0].end;const N=k.getContentName(A.content,I),F=m.pushAttributed(N,e);if(n=n.withContentNameScopesList(F),k.whileHasBackReferences&&(n=n.withEndRule(k.getWhileWithResolvedBackReferences(A.content,I))),!u&&d.hasSameRuleAs(n)){n=n.pop(),i.produce(n,Q),B=!0;return}}else if(FQ(e,A,t,n,i,h.captures,I),i.produce(n,I[0].end),n=n.pop(),!u){n=n.safePop(),i.produce(n,Q),B=!0;return}}I[0].end>r&&(r=I[0].end,t=!1)}}function kU(e,A,t,r,n,i){let o=n.beginRuleCapturedEOL?0:-1;const g=[];for(let Q=n;Q;Q=Q.pop()){const B=Q.getRule(e);B instanceof ys&&g.push({rule:B,stack:Q})}for(let Q=g.pop();Q;Q=g.pop()){const{ruleScanner:B,findOptions:a}=vU(Q.rule,e,Q.stack.endRule,t,r===o),s=B.findNextMatchSync(A,r,a);if(s){if(s.ruleId!==sk){n=Q.stack.pop();break}s.captureIndices&&s.captureIndices.length&&(i.produce(Q.stack,s.captureIndices[0].start),FQ(e,A,t,Q.stack,i,Q.rule.whileCaptures,s.captureIndices),i.produce(Q.stack,s.captureIndices[0].end),o=s.captureIndices[0].end,s.captureIndices[0].end>r&&(r=s.captureIndices[0].end,t=!1))}else{n=Q.stack.pop();break}}return{stack:n,linePos:r,anchorPosition:o,isFirstLine:t}}function yU(e,A,t,r,n,i){const o=MU(e,A,t,r,n,i),g=e.getInjections();if(g.length===0)return o;const Q=NU(g,e,A,t,r,n,i);if(!Q)return o;if(!o)return Q;const B=o.captureIndices[0].start,a=Q.captureIndices[0].start;return a=g)&&(g=f,Q=d.captureIndices,B=d.ruleId,a=I.priority,g===n))break}return Q?{priorityMatch:a===-1,captureIndices:Q,matchedRuleId:B}:null}function lk(e,A,t,r,n){return{ruleScanner:e.compileAG(A,t,r,n),findOptions:0}}function vU(e,A,t,r,n){return{ruleScanner:e.compileWhileAG(A,t,r,n),findOptions:0}}function FQ(e,A,t,r,n,i,o){if(i.length===0)return;const g=A.content,Q=Math.min(i.length,o.length),B=[],a=o[0].end;for(let s=0;sa)break;for(;B.length>0&&B[B.length-1].endPos<=E.start;)n.produceFromScopes(B[B.length-1].scopes,B[B.length-1].endPos),B.pop();if(B.length>0?n.produceFromScopes(B[B.length-1].scopes,E.start):n.produce(r,E.start),C.retokenizeCapturedWithRuleId){const c=C.getName(g,o),u=r.contentNameScopesList.pushAttributed(c,e),h=C.getContentName(g,o),d=u.pushAttributed(h,e),f=r.push(C.retokenizeCapturedWithRuleId,E.start,-1,!1,null,u,d),m=e.createOnigString(g.substring(0,E.end));Ik(e,m,t&&E.start===0,E.start,f,n,!1,0),Bk(m);continue}const I=C.getName(g,o);if(I!==null){const u=(B.length>0?B[B.length-1].scopes:r.contentNameScopesList).pushAttributed(I,e);B.push(new bU(u,E.end))}}for(;B.length>0;)n.produceFromScopes(B[B.length-1].scopes,B[B.length-1].endPos),B.pop()}var bU=class{scopes;endPos;constructor(e,A){this.scopes=e,this.endPos=A}};function FU(e,A,t,r,n,i,o,g){return new GU(e,A,t,r,n,i,o,g)}function lD(e,A,t,r,n){const i=ps(A,Ms),o=Ek.getCompiledRuleId(t,r,n.repository);for(const g of i)e.push({debugSelector:A,matcher:g.matcher,ruleId:o,grammar:n,priority:g.priority})}function Ms(e,A){if(A.length{for(let n=t;nt&&e.substr(0,t)===A&&e[t]==="."}var GU=class{constructor(e,A,t,r,n,i,o,g){if(this._rootScopeName=e,this.balancedBracketSelectors=i,this._onigLib=g,this._basicScopeAttributesProvider=new mU(t,r),this._rootId=-1,this._lastRuleId=0,this._ruleId2desc=[null],this._includedGrammars={},this._grammarRepository=o,this._grammar=cD(A,null),this._injections=null,this._tokenTypeMatchers=[],n)for(const Q of Object.keys(n)){const B=ps(Q,Ms);for(const a of B)this._tokenTypeMatchers.push({matcher:a.matcher,type:n[Q]})}}_rootId;_lastRuleId;_ruleId2desc;_includedGrammars;_grammarRepository;_grammar;_injections;_basicScopeAttributesProvider;_tokenTypeMatchers;get themeProvider(){return this._grammarRepository}dispose(){for(const e of this._ruleId2desc)e&&e.dispose()}createOnigScanner(e){return this._onigLib.createOnigScanner(e)}createOnigString(e){return this._onigLib.createOnigString(e)}getMetadataForScope(e){return this._basicScopeAttributesProvider.getBasicScopeAttributes(e)}_collectInjections(){const e={lookup:n=>n===this._rootScopeName?this._grammar:this.getExternalGrammar(n),injections:n=>this._grammarRepository.injections(n)},A=[],t=this._rootScopeName,r=e.lookup(t);if(r){const n=r.injections;if(n)for(let o in n)lD(A,o,n[o],this,r);const i=this._grammarRepository.injections(t);i&&i.forEach(o=>{const g=this.getExternalGrammar(o);if(g){const Q=g.injectionSelector;Q&&lD(A,Q,g,this,g)}})}return A.sort((n,i)=>n.priority-i.priority),A}getInjections(){return this._injections===null&&(this._injections=this._collectInjections()),this._injections}registerRule(e){const A=++this._lastRuleId,t=e(A);return this._ruleId2desc[A]=t,t}getRule(e){return this._ruleId2desc[e]}getExternalGrammar(e,A){if(this._includedGrammars[e])return this._includedGrammars[e];if(this._grammarRepository){const t=this._grammarRepository.lookup(e);if(t)return this._includedGrammars[e]=cD(t,A&&A.$base),this._includedGrammars[e]}}tokenizeLine(e,A,t=0){const r=this._tokenize(e,A,!1,t);return{tokens:r.lineTokens.getResult(r.ruleStack,r.lineLength),ruleStack:r.ruleStack,stoppedEarly:r.stoppedEarly}}tokenizeLine2(e,A,t=0){const r=this._tokenize(e,A,!0,t);return{tokens:r.lineTokens.getBinaryResult(r.ruleStack,r.lineLength),ruleStack:r.ruleStack,stoppedEarly:r.stoppedEarly}}_tokenize(e,A,t,r){this._rootId===-1&&(this._rootId=Ek.getCompiledRuleId(this._grammar.repository.$self,this,this._grammar.repository),this.getInjections());let n;if(!A||A===Bl.NULL){n=!0;const B=this._basicScopeAttributesProvider.getDefaultAttributes(),a=this.themeProvider.getDefaults(),s=Jg.set(0,B.languageId,B.tokenType,null,a.fontStyle,a.foregroundId,a.backgroundId),C=this.getRule(this._rootId).getName(null,null);let E;C?E=PQ.createRootAndLookUpScopeName(C,s,this):E=PQ.createRoot("unknown",s),A=new Bl(null,this._rootId,-1,-1,!1,null,E,E)}else n=!1,A.reset();e=e+` `;const i=this.createOnigString(e),o=i.content.length,g=new JU(t,e,this._tokenTypeMatchers,this.balancedBracketSelectors),Q=Ik(this,i,n,0,A,g,!0,r);return Bk(i),{lineLength:o,lineTokens:g,ruleStack:Q.stack,stoppedEarly:Q.stoppedEarly}}};function cD(e,A){return e=XJ(e),e.repository=e.repository||{},e.repository.$self={$vscodeTextmateLocation:e.$vscodeTextmateLocation,patterns:e.patterns,name:e.scopeName},e.repository.$base=A||e.repository.$self,e}var PQ=class En{constructor(A,t,r){this.parent=A,this.scopePath=t,this.tokenAttributes=r}static fromExtension(A,t){let r=A,n=A?.scopePath??null;for(const i of t)n=qC.push(n,i.scopeNames),r=new En(r,n,i.encodedTokenAttributes);return r}static createRoot(A,t){return new En(null,new qC(null,A),t)}static createRootAndLookUpScopeName(A,t,r){const n=r.getMetadataForScope(A),i=new qC(null,A),o=r.themeProvider.themeMatch(i),g=En.mergeAttributes(t,n,o);return new En(null,i,g)}get scopeName(){return this.scopePath.scopeName}toString(){return this.getScopeNames().join(" ")}equals(A){return En.equals(this,A)}static equals(A,t){do{if(A===t||!A&&!t)return!0;if(!A||!t||A.scopeName!==t.scopeName||A.tokenAttributes!==t.tokenAttributes)return!1;A=A.parent,t=t.parent}while(!0)}static mergeAttributes(A,t,r){let n=-1,i=0,o=0;return r!==null&&(n=r.fontStyle,i=r.foregroundId,o=r.backgroundId),Jg.set(A,t.languageId,t.tokenType,null,n,i,o)}pushAttributed(A,t){if(A===null)return this;if(A.indexOf(" ")===-1)return En._pushAttributed(this,A,t);const r=A.split(/ /g);let n=this;for(const i of r)n=En._pushAttributed(n,i,t);return n}static _pushAttributed(A,t,r){const n=r.getMetadataForScope(t),i=A.scopePath.push(t),o=r.themeProvider.themeMatch(i),g=En.mergeAttributes(A.tokenAttributes,n,o);return new En(A,i,g)}getScopeNames(){return this.scopePath.getSegments()}getExtensionIfDefined(A){const t=[];let r=this;for(;r&&r!==A;)t.push({encodedTokenAttributes:r.tokenAttributes,scopeNames:r.scopePath.getExtensionIfDefined(r.parent?.scopePath??null)}),r=r.parent;return r===A?t.reverse():void 0}},Bl=class so{constructor(A,t,r,n,i,o,g,Q){this.parent=A,this.ruleId=t,this.beginRuleCapturedEOL=i,this.endRule=o,this.nameScopesList=g,this.contentNameScopesList=Q,this.depth=this.parent?this.parent.depth+1:1,this._enterPos=r,this._anchorPos=n}_stackElementBrand=void 0;static NULL=new so(null,0,0,0,!1,null,null,null);_enterPos;_anchorPos;depth;equals(A){return A===null?!1:so._equals(this,A)}static _equals(A,t){return A===t?!0:this._structuralEquals(A,t)?PQ.equals(A.contentNameScopesList,t.contentNameScopesList):!1}static _structuralEquals(A,t){do{if(A===t||!A&&!t)return!0;if(!A||!t||A.depth!==t.depth||A.ruleId!==t.ruleId||A.endRule!==t.endRule)return!1;A=A.parent,t=t.parent}while(!0)}clone(){return this}static _reset(A){for(;A;)A._enterPos=-1,A._anchorPos=-1,A=A.parent}reset(){so._reset(this)}pop(){return this.parent}safePop(){return this.parent?this.parent:this}push(A,t,r,n,i,o,g){return new so(this,A,t,r,n,i,o,g)}getEnterPos(){return this._enterPos}getAnchorPos(){return this._anchorPos}getRule(A){return A.getRule(this.ruleId)}toString(){const A=[];return this._writeString(A,0),"["+A.join(",")+"]"}_writeString(A,t){return this.parent&&(t=this.parent._writeString(A,t)),A[t++]=`(${this.ruleId}, ${this.nameScopesList?.toString()}, ${this.contentNameScopesList?.toString()})`,t}withContentNameScopesList(A){return this.contentNameScopesList===A?this:this.parent.push(this.ruleId,this._enterPos,this._anchorPos,this.beginRuleCapturedEOL,this.endRule,this.nameScopesList,A)}withEndRule(A){return this.endRule===A?this:new so(this.parent,this.ruleId,this._enterPos,this._anchorPos,this.beginRuleCapturedEOL,A,this.nameScopesList,this.contentNameScopesList)}hasSameRuleAs(A){let t=this;for(;t&&t._enterPos===A._enterPos;){if(t.ruleId===A.ruleId)return!0;t=t.parent}return!1}toStateStackFrame(){return{ruleId:this.ruleId,beginRuleCapturedEOL:this.beginRuleCapturedEOL,endRule:this.endRule,nameScopesList:this.nameScopesList?.getExtensionIfDefined(this.parent?.nameScopesList??null)??[],contentNameScopesList:this.contentNameScopesList?.getExtensionIfDefined(this.nameScopesList)??[]}}static pushFrame(A,t){const r=PQ.fromExtension(A?.nameScopesList??null,t.nameScopesList);return new so(A,t.ruleId,t.enterPos??-1,t.anchorPos??-1,t.beginRuleCapturedEOL,t.endRule,r,PQ.fromExtension(r,t.contentNameScopesList))}},SU=class{balancedBracketScopes;unbalancedBracketScopes;allowAny=!1;constructor(e,A){this.balancedBracketScopes=e.flatMap(t=>t==="*"?(this.allowAny=!0,[]):ps(t,Ms).map(r=>r.matcher)),this.unbalancedBracketScopes=A.flatMap(t=>ps(t,Ms).map(r=>r.matcher))}get matchesAlways(){return this.allowAny&&this.unbalancedBracketScopes.length===0}get matchesNever(){return this.balancedBracketScopes.length===0&&!this.allowAny}match(e){for(const A of this.unbalancedBracketScopes)if(A(e))return!1;for(const A of this.balancedBracketScopes)if(A(e))return!0;return this.allowAny}},JU=class{constructor(e,A,t,r){this.balancedBracketSelectors=r,this._emitBinaryTokens=e,this._tokenTypeOverrides=t,this._lineText=null,this._tokens=[],this._binaryTokens=[],this._lastTokenEndIndex=0}_emitBinaryTokens;_lineText;_tokens;_binaryTokens;_lastTokenEndIndex;_tokenTypeOverrides;produce(e,A){this.produceFromScopes(e.contentNameScopesList,A)}produceFromScopes(e,A){if(this._lastTokenEndIndex>=A)return;if(this._emitBinaryTokens){let r=e?.tokenAttributes??0,n=!1;if(this.balancedBracketSelectors?.matchesAlways&&(n=!0),this._tokenTypeOverrides.length>0||this.balancedBracketSelectors&&!this.balancedBracketSelectors.matchesAlways&&!this.balancedBracketSelectors.matchesNever){const i=e?.getScopeNames()??[];for(const o of this._tokenTypeOverrides)o.matcher(i)&&(r=Jg.set(r,0,o.type,null,-1,0,0));this.balancedBracketSelectors&&(n=this.balancedBracketSelectors.match(i))}if(n&&(r=Jg.set(r,0,8,n,-1,0,0)),this._binaryTokens.length>0&&this._binaryTokens[this._binaryTokens.length-1]===r){this._lastTokenEndIndex=A;return}this._binaryTokens.push(this._lastTokenEndIndex),this._binaryTokens.push(r),this._lastTokenEndIndex=A;return}const t=e?.getScopeNames()??[];this._tokens.push({startIndex:this._lastTokenEndIndex,endIndex:A,scopes:t}),this._lastTokenEndIndex=A}getResult(e,A){return this._tokens.length>0&&this._tokens[this._tokens.length-1].startIndex===A-1&&this._tokens.pop(),this._tokens.length===0&&(this._lastTokenEndIndex=-1,this.produce(e,A),this._tokens[this._tokens.length-1].startIndex=0),this._tokens}getBinaryResult(e,A){this._binaryTokens.length>0&&this._binaryTokens[this._binaryTokens.length-2]===A-1&&(this._binaryTokens.pop(),this._binaryTokens.pop()),this._binaryTokens.length===0&&(this._lastTokenEndIndex=-1,this.produce(e,A),this._binaryTokens[this._binaryTokens.length-2]=0);const t=new Uint32Array(this._binaryTokens.length);for(let r=0,n=this._binaryTokens.length;r0;)o.Q.map(g=>this._loadSingleGrammar(g.scopeName)),o.processQueue();return this._grammarForScopeName(A,t,r,n,i)}_loadSingleGrammar(A){this._ensureGrammarCache.has(A)||(this._doLoadSingleGrammar(A),this._ensureGrammarCache.set(A,!0))}_doLoadSingleGrammar(A){const t=this._options.loadGrammar(A);if(t){const r=typeof this._options.getInjections=="function"?this._options.getInjections(A):void 0;this._syncRegistry.addGrammar(t,r)}}addGrammar(A,t=[],r=0,n=null){return this._syncRegistry.addGrammar(A,t),this._grammarForScopeName(A.scopeName,r,n)}_grammarForScopeName(A,t=0,r=null,n=null,i=null){return this._syncRegistry.grammarForScopeName(A,t,r,n,i)}},al=Bl.NULL;const LU=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"];class bB{constructor(A,t,r){this.normal=t,this.property=A,r&&(this.space=r)}}bB.prototype.normal={};bB.prototype.property={};bB.prototype.space=void 0;function ck(e,A){const t={},r={};for(const n of e)Object.assign(t,n.property),Object.assign(r,n.normal);return new bB(t,r,A)}function sl(e){return e.toLowerCase()}let Er=class{constructor(A,t){this.attribute=t,this.property=A}};Er.prototype.attribute="";Er.prototype.booleanish=!1;Er.prototype.boolean=!1;Er.prototype.commaOrSpaceSeparated=!1;Er.prototype.commaSeparated=!1;Er.prototype.defined=!1;Er.prototype.mustUseProperty=!1;Er.prototype.number=!1;Er.prototype.overloadedBoolean=!1;Er.prototype.property="";Er.prototype.spaceSeparated=!1;Er.prototype.space=void 0;let RU=0;const he=zo(),ht=zo(),El=zo(),bA=zo(),We=zo(),kg=zo(),Ir=zo();function zo(){return 2**++RU}const Cl=Object.freeze(Object.defineProperty({__proto__:null,boolean:he,booleanish:ht,commaOrSpaceSeparated:Ir,commaSeparated:kg,number:bA,overloadedBoolean:El,spaceSeparated:We},Symbol.toStringTag,{value:"Module"})),HC=Object.keys(Cl);class nu extends Er{constructor(A,t,r,n){let i=-1;if(super(A,t),uD(this,"space",n),typeof r=="number")for(;++i4&&t.slice(0,4)==="data"&&HU.test(A)){if(A.charAt(4)==="-"){const i=A.slice(5).replace(dD,PU);r="data"+i.charAt(0).toUpperCase()+i.slice(1)}else{const i=A.slice(4);if(!dD.test(i)){let o=i.replace(TU,zU);o.charAt(0)!=="-"&&(o="-"+o),A="data"+o}}n=nu}return new n(r,A)}function zU(e){return"-"+e.toLowerCase()}function PU(e){return e.charAt(1).toUpperCase()}const _U=ck([uk,OU,Dk,fk,wk],"html"),mk=ck([uk,qU,Dk,fk,wk],"svg"),hD={}.hasOwnProperty;function jU(e,A){const t=A||{};function r(n,...i){let o=r.invalid;const g=r.handlers;if(n&&hD.call(n,e)){const Q=String(n[e]);o=hD.call(g,Q)?g[Q]:r.unknown}if(o)return o.call(this,n,...i)}return r.handlers=t.handlers||{},r.invalid=t.invalid,r.unknown=t.unknown,r}const VU=/["&'<>`]/g,WU=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,ZU=/[\x01-\t\v\f\x0E-\x1F\x7F\x81\x8D\x8F\x90\x9D\xA0-\uFFFF]/g,XU=/[|\\{}()[\]^$+*?.]/g,DD=new WeakMap;function $U(e,A){if(e=e.replace(A.subset?AK(A.subset):VU,r),A.subset||A.escapeOnly)return e;return e.replace(WU,t).replace(ZU,r);function t(n,i,o){return A.format((n.charCodeAt(0)-55296)*1024+n.charCodeAt(1)-56320+65536,o.charCodeAt(i+2),A)}function r(n,i,o){return A.format(n.charCodeAt(0),o.charCodeAt(i+1),A)}}function AK(e){let A=DD.get(e);return A||(A=eK(e),DD.set(e,A)),A}function eK(e){const A=[];let t=-1;for(;++t",OElig:"Œ",oelig:"œ",Scaron:"Š",scaron:"š",Yuml:"Ÿ",circ:"ˆ",tilde:"˜",ensp:" ",emsp:" ",thinsp:" ",zwnj:"‌",zwj:"‍",lrm:"‎",rlm:"‏",ndash:"–",mdash:"—",lsquo:"‘",rsquo:"’",sbquo:"‚",ldquo:"“",rdquo:"”",bdquo:"„",dagger:"†",Dagger:"‡",permil:"‰",lsaquo:"‹",rsaquo:"›",euro:"€"},gK=["cent","copy","divide","gt","lt","not","para","times"],pk={}.hasOwnProperty,Il={};let ka;for(ka in YC)pk.call(YC,ka)&&(Il[YC[ka]]=ka);const QK=/[^\dA-Za-z]/;function BK(e,A,t,r){const n=String.fromCharCode(e);if(pk.call(Il,n)){const i=Il[n],o="&"+i;return t&&oK.includes(i)&&!gK.includes(i)&&(!r||A&&A!==61&&QK.test(String.fromCharCode(A)))?o:o+";"}return""}function aK(e,A,t){let r=rK(e,A,t.omitOptionalSemicolons),n;if((t.useNamedReferences||t.useShortestReferences)&&(n=BK(e,A,t.omitOptionalSemicolons,t.attribute)),(t.useShortestReferences||!n)&&t.useShortestReferences){const i=iK(e,A,t.omitOptionalSemicolons);i.length|^->||--!>|"],CK=["<",">"];function IK(e,A,t,r){return r.settings.bogusComments?"":"";function n(i){return yg(i,Object.assign({},r.settings.characterReferences,{subset:CK}))}}function lK(e,A,t,r){return""}function fD(e,A){const t=String(e);if(typeof A!="string")throw new TypeError("Expected character");let r=0,n=t.indexOf(A);for(;n!==-1;)r++,n=t.indexOf(A,n+A.length);return r}function cK(e,A){const t=A||{};return(e[e.length-1]===""?[...e,""]:e).join((t.padRight?" ":"")+","+(t.padLeft===!1?"":" ")).trim()}function uK(e){return e.join(" ").trim()}const dK=/[ \t\n\f\r]/g;function iu(e){return typeof e=="object"?e.type==="text"?wD(e.value):!1:wD(e)}function wD(e){return e.replace(dK,"")===""}const xt=yk(1),kk=yk(-1),hK=[];function yk(e){return A;function A(t,r,n){const i=t?t.children:hK;let o=(r||0)+e,g=i[o];if(!n)for(;g&&iu(g);)o+=e,g=i[o];return g}}const DK={}.hasOwnProperty;function Mk(e){return A;function A(t,r,n){return DK.call(e,t.tagName)&&e[t.tagName](t,r,n)}}const ou=Mk({body:wK,caption:zC,colgroup:zC,dd:yK,dt:kK,head:zC,html:fK,li:pK,optgroup:MK,option:NK,p:mK,rp:mD,rt:mD,tbody:bK,td:pD,tfoot:FK,th:pD,thead:vK,tr:xK});function zC(e,A,t){const r=xt(t,A,!0);return!r||r.type!=="comment"&&!(r.type==="text"&&iu(r.value.charAt(0)))}function fK(e,A,t){const r=xt(t,A);return!r||r.type!=="comment"}function wK(e,A,t){const r=xt(t,A);return!r||r.type!=="comment"}function mK(e,A,t){const r=xt(t,A);return r?r.type==="element"&&(r.tagName==="address"||r.tagName==="article"||r.tagName==="aside"||r.tagName==="blockquote"||r.tagName==="details"||r.tagName==="div"||r.tagName==="dl"||r.tagName==="fieldset"||r.tagName==="figcaption"||r.tagName==="figure"||r.tagName==="footer"||r.tagName==="form"||r.tagName==="h1"||r.tagName==="h2"||r.tagName==="h3"||r.tagName==="h4"||r.tagName==="h5"||r.tagName==="h6"||r.tagName==="header"||r.tagName==="hgroup"||r.tagName==="hr"||r.tagName==="main"||r.tagName==="menu"||r.tagName==="nav"||r.tagName==="ol"||r.tagName==="p"||r.tagName==="pre"||r.tagName==="section"||r.tagName==="table"||r.tagName==="ul"):!t||!(t.type==="element"&&(t.tagName==="a"||t.tagName==="audio"||t.tagName==="del"||t.tagName==="ins"||t.tagName==="map"||t.tagName==="noscript"||t.tagName==="video"))}function pK(e,A,t){const r=xt(t,A);return!r||r.type==="element"&&r.tagName==="li"}function kK(e,A,t){const r=xt(t,A);return!!(r&&r.type==="element"&&(r.tagName==="dt"||r.tagName==="dd"))}function yK(e,A,t){const r=xt(t,A);return!r||r.type==="element"&&(r.tagName==="dt"||r.tagName==="dd")}function mD(e,A,t){const r=xt(t,A);return!r||r.type==="element"&&(r.tagName==="rp"||r.tagName==="rt")}function MK(e,A,t){const r=xt(t,A);return!r||r.type==="element"&&r.tagName==="optgroup"}function NK(e,A,t){const r=xt(t,A);return!r||r.type==="element"&&(r.tagName==="option"||r.tagName==="optgroup")}function vK(e,A,t){const r=xt(t,A);return!!(r&&r.type==="element"&&(r.tagName==="tbody"||r.tagName==="tfoot"))}function bK(e,A,t){const r=xt(t,A);return!r||r.type==="element"&&(r.tagName==="tbody"||r.tagName==="tfoot")}function FK(e,A,t){return!xt(t,A)}function xK(e,A,t){const r=xt(t,A);return!r||r.type==="element"&&r.tagName==="tr"}function pD(e,A,t){const r=xt(t,A);return!r||r.type==="element"&&(r.tagName==="td"||r.tagName==="th")}const GK=Mk({body:UK,colgroup:KK,head:JK,html:SK,tbody:LK});function SK(e){const A=xt(e,-1);return!A||A.type!=="comment"}function JK(e){const A=new Set;for(const r of e.children)if(r.type==="element"&&(r.tagName==="base"||r.tagName==="title")){if(A.has(r.tagName))return!1;A.add(r.tagName)}const t=e.children[0];return!t||t.type==="element"}function UK(e){const A=xt(e,-1,!0);return!A||A.type!=="comment"&&!(A.type==="text"&&iu(A.value.charAt(0)))&&!(A.type==="element"&&(A.tagName==="meta"||A.tagName==="link"||A.tagName==="script"||A.tagName==="style"||A.tagName==="template"))}function KK(e,A,t){const r=kk(t,A),n=xt(e,-1,!0);return t&&r&&r.type==="element"&&r.tagName==="colgroup"&&ou(r,t.children.indexOf(r),t)?!1:!!(n&&n.type==="element"&&n.tagName==="col")}function LK(e,A,t){const r=kk(t,A),n=xt(e,-1);return t&&r&&r.type==="element"&&(r.tagName==="thead"||r.tagName==="tbody")&&ou(r,t.children.indexOf(r),t)?!1:!!(n&&n.type==="element"&&n.tagName==="tr")}const ya={name:[[` \f\r &/=>`.split(""),` \f\r "&'/=>\``.split("")],[`\0 \f\r "&'/<=>`.split(""),`\0 \f\r "&'/<=>\``.split("")]],unquoted:[[` \f\r &>`.split(""),`\0 \f\r "&'<=>\``.split("")],[`\0 \f\r "&'<=>\``.split(""),`\0 \f\r "&'<=>\``.split("")]],single:[["&'".split(""),"\"&'`".split("")],["\0&'".split(""),"\0\"&'`".split("")]],double:[['"&'.split(""),"\"&'`".split("")],['\0"&'.split(""),"\0\"&'`".split("")]]};function RK(e,A,t,r){const n=r.schema,i=n.space==="svg"?!1:r.settings.omitOptionalTags;let o=n.space==="svg"?r.settings.closeEmptyElements:r.settings.voids.includes(e.tagName.toLowerCase());const g=[];let Q;n.space==="html"&&e.tagName==="svg"&&(r.schema=mk);const B=OK(r,e.properties),a=r.all(n.space==="html"&&e.tagName==="template"?e.content:e);return r.schema=n,a&&(o=!1),(B||!i||!GK(e,A,t))&&(g.push("<",e.tagName,B?" "+B:""),o&&(n.space==="svg"||r.settings.closeSelfClosing)&&(Q=B.charAt(B.length-1),(!r.settings.tightSelfClosing||Q==="/"||Q&&Q!=='"'&&Q!=="'")&&g.push(" "),g.push("/")),g.push(">")),g.push(a),!o&&(!i||!ou(e,A,t))&&g.push(""),g.join("")}function OK(e,A){const t=[];let r=-1,n;if(A){for(n in A)if(A[n]!==null&&A[n]!==void 0){const i=qK(e,n,A[n]);i&&t.push(i)}}for(;++rfD(t,e.alternative)&&(o=e.alternative),g=o+yg(t,Object.assign({},e.settings.characterReferences,{subset:(o==="'"?ya.single:ya.double)[n][i],attribute:!0}))+o),Q+(g&&"="+g))}const TK=["<","&"];function Nk(e,A,t,r){return t&&t.type==="element"&&(t.tagName==="script"||t.tagName==="style")?e.value:yg(e.value,Object.assign({},r.settings.characterReferences,{subset:TK}))}function HK(e,A,t,r){return r.settings.allowDangerousHtml?e.value:Nk(e,A,t,r)}function YK(e,A,t,r){return r.all(e)}const zK=jU("type",{invalid:PK,unknown:_K,handlers:{comment:IK,doctype:lK,element:RK,raw:HK,root:YK,text:Nk}});function PK(e){throw new Error("Expected node, not `"+e+"`")}function _K(e){const A=e;throw new Error("Cannot compile unknown node `"+A.type+"`")}const jK={},VK={},WK=[];function Xn(e,A){const t=A||jK,r=t.quote||'"',n=r==='"'?"'":'"';if(r!=='"'&&r!=="'")throw new Error("Invalid quote `"+r+"`, expected `'` or `\"`");return{one:ZK,all:XK,settings:{omitOptionalTags:t.omitOptionalTags||!1,allowParseErrors:t.allowParseErrors||!1,allowDangerousCharacters:t.allowDangerousCharacters||!1,quoteSmart:t.quoteSmart||!1,preferUnquoted:t.preferUnquoted||!1,tightAttributes:t.tightAttributes||!1,upperDoctype:t.upperDoctype||!1,tightDoctype:t.tightDoctype||!1,bogusComments:t.bogusComments||!1,tightCommaSeparatedLists:t.tightCommaSeparatedLists||!1,tightSelfClosing:t.tightSelfClosing||!1,collapseEmptyAttributes:t.collapseEmptyAttributes||!1,allowDangerousHtml:t.allowDangerousHtml||!1,voids:t.voids||LU,characterReferences:t.characterReferences||VK,closeSelfClosing:t.closeSelfClosing||!1,closeEmptyElements:t.closeEmptyElements||!1},schema:t.space==="svg"?mk:_U,quote:r,alternative:n}.one(Array.isArray(e)?{type:"root",children:e}:e,void 0,void 0)}function ZK(e,A,t){return zK(e,A,t,this)}function XK(e){const A=[],t=e&&e.children||WK;let r=-1;for(;++rp(()=>import("./abap-BdImnpbu.js"),[])},{id:"actionscript-3",name:"ActionScript",import:()=>p(()=>import("./actionscript-3-CfeIJUat.js"),[])},{id:"ada",name:"Ada",import:()=>p(()=>import("./ada-bCR0ucgS.js"),[])},{id:"angular-html",name:"Angular HTML",import:()=>p(()=>import("./angular-html-CU67Zn6k.js").then(e=>e.f),__vite__mapDeps([0,1,2,3]))},{id:"angular-ts",name:"Angular TypeScript",import:()=>p(()=>import("./angular-ts-BwZT4LLn.js"),__vite__mapDeps([4,0,1,2,3,5]))},{id:"apache",name:"Apache Conf",import:()=>p(()=>import("./apache-Pmp26Uib.js"),[])},{id:"apex",name:"Apex",import:()=>p(()=>import("./apex-DDbsPZ6N.js"),[])},{id:"apl",name:"APL",import:()=>p(()=>import("./apl-dKokRX4l.js"),__vite__mapDeps([6,1,2,3,7,8,9]))},{id:"applescript",name:"AppleScript",import:()=>p(()=>import("./applescript-Co6uUVPk.js"),[])},{id:"ara",name:"Ara",import:()=>p(()=>import("./ara-BRHolxvo.js"),[])},{id:"asciidoc",name:"AsciiDoc",aliases:["adoc"],import:()=>p(()=>import("./asciidoc-Dv7Oe6Be.js"),[])},{id:"asm",name:"Assembly",import:()=>p(()=>import("./asm-D_Q5rh1f.js"),[])},{id:"astro",name:"Astro",import:()=>p(()=>import("./astro-CbQHKStN.js"),__vite__mapDeps([10,9,2,11,3,12,13]))},{id:"awk",name:"AWK",import:()=>p(()=>import("./awk-DMzUqQB5.js"),[])},{id:"ballerina",name:"Ballerina",import:()=>p(()=>import("./ballerina-BFfxhgS-.js"),[])},{id:"bat",name:"Batch File",aliases:["batch"],import:()=>p(()=>import("./bat-BkioyH1T.js"),[])},{id:"beancount",name:"Beancount",import:()=>p(()=>import("./beancount-k_qm7-4y.js"),[])},{id:"berry",name:"Berry",aliases:["be"],import:()=>p(()=>import("./berry-uYugtg8r.js"),[])},{id:"bibtex",name:"BibTeX",import:()=>p(()=>import("./bibtex-CHM0blh-.js"),[])},{id:"bicep",name:"Bicep",import:()=>p(()=>import("./bicep-Bmn6On1c.js"),[])},{id:"blade",name:"Blade",import:()=>p(()=>import("./blade-DVc8C-J4.js"),__vite__mapDeps([14,15,1,2,3,7,8,16,9]))},{id:"bsl",name:"1C (Enterprise)",aliases:["1c"],import:()=>p(()=>import("./bsl-BO_Y6i37.js"),__vite__mapDeps([17,18]))},{id:"c",name:"C",import:()=>p(()=>import("./c-BIGW1oBm.js"),[])},{id:"cadence",name:"Cadence",aliases:["cdc"],import:()=>p(()=>import("./cadence-Bv_4Rxtq.js"),[])},{id:"cairo",name:"Cairo",import:()=>p(()=>import("./cairo-KRGpt6FW.js"),__vite__mapDeps([19,20]))},{id:"clarity",name:"Clarity",import:()=>p(()=>import("./clarity-D53aC0YG.js"),[])},{id:"clojure",name:"Clojure",aliases:["clj"],import:()=>p(()=>import("./clojure-P80f7IUj.js"),[])},{id:"cmake",name:"CMake",import:()=>p(()=>import("./cmake-D1j8_8rp.js"),[])},{id:"cobol",name:"COBOL",import:()=>p(()=>import("./cobol-nwyudZeR.js"),__vite__mapDeps([21,1,2,3,8]))},{id:"codeowners",name:"CODEOWNERS",import:()=>p(()=>import("./codeowners-Bp6g37R7.js"),[])},{id:"codeql",name:"CodeQL",aliases:["ql"],import:()=>p(()=>import("./codeql-DsOJ9woJ.js"),[])},{id:"coffee",name:"CoffeeScript",aliases:["coffeescript"],import:()=>p(()=>import("./coffee-Ch7k5sss.js"),__vite__mapDeps([22,2]))},{id:"common-lisp",name:"Common Lisp",aliases:["lisp"],import:()=>p(()=>import("./common-lisp-Cg-RD9OK.js"),[])},{id:"coq",name:"Coq",import:()=>p(()=>import("./coq-DkFqJrB1.js"),[])},{id:"cpp",name:"C++",aliases:["c++"],import:()=>p(()=>import("./cpp-CofmeUqb.js"),__vite__mapDeps([23,24,25,26,16]))},{id:"crystal",name:"Crystal",import:()=>p(()=>import("./crystal-tKQVLTB8.js"),__vite__mapDeps([27,1,2,3,16,26,28]))},{id:"csharp",name:"C#",aliases:["c#","cs"],import:()=>p(()=>import("./csharp-K5feNrxe.js"),[])},{id:"css",name:"CSS",import:()=>p(()=>import("./css-DPfMkruS.js"),[])},{id:"csv",name:"CSV",import:()=>p(()=>import("./csv-fuZLfV_i.js"),[])},{id:"cue",name:"CUE",import:()=>p(()=>import("./cue-D82EKSYY.js"),[])},{id:"cypher",name:"Cypher",aliases:["cql"],import:()=>p(()=>import("./cypher-COkxafJQ.js"),[])},{id:"d",name:"D",import:()=>p(()=>import("./d-85-TOEBH.js"),[])},{id:"dart",name:"Dart",import:()=>p(()=>import("./dart-CF10PKvl.js"),[])},{id:"dax",name:"DAX",import:()=>p(()=>import("./dax-CEL-wOlO.js"),[])},{id:"desktop",name:"Desktop",import:()=>p(()=>import("./desktop-BmXAJ9_W.js"),[])},{id:"diff",name:"Diff",import:()=>p(()=>import("./diff-D97Zzqfu.js"),[])},{id:"docker",name:"Dockerfile",aliases:["dockerfile"],import:()=>p(()=>import("./docker-BcOcwvcX.js"),[])},{id:"dotenv",name:"dotEnv",import:()=>p(()=>import("./dotenv-Da5cRb03.js"),[])},{id:"dream-maker",name:"Dream Maker",import:()=>p(()=>import("./dream-maker-BtqSS_iP.js"),[])},{id:"edge",name:"Edge",import:()=>p(()=>import("./edge-BkV0erSs.js"),__vite__mapDeps([29,11,1,2,3,15]))},{id:"elixir",name:"Elixir",import:()=>p(()=>import("./elixir-CDX3lj18.js"),__vite__mapDeps([30,1,2,3]))},{id:"elm",name:"Elm",import:()=>p(()=>import("./elm-DbKCFpqz.js"),__vite__mapDeps([31,25,26]))},{id:"emacs-lisp",name:"Emacs Lisp",aliases:["elisp"],import:()=>p(()=>import("./emacs-lisp-C9XAeP06.js"),[])},{id:"erb",name:"ERB",import:()=>p(()=>import("./erb-BOJIQeun.js"),__vite__mapDeps([32,1,2,3,33,34,7,8,16,35,11,36,13,23,24,25,26,28,37,38]))},{id:"erlang",name:"Erlang",aliases:["erl"],import:()=>p(()=>import("./erlang-DsQrWhSR.js"),__vite__mapDeps([39,40]))},{id:"fennel",name:"Fennel",import:()=>p(()=>import("./fennel-BYunw83y.js"),[])},{id:"fish",name:"Fish",import:()=>p(()=>import("./fish-BvzEVeQv.js"),[])},{id:"fluent",name:"Fluent",aliases:["ftl"],import:()=>p(()=>import("./fluent-C4IJs8-o.js"),[])},{id:"fortran-fixed-form",name:"Fortran (Fixed Form)",aliases:["f","for","f77"],import:()=>p(()=>import("./fortran-fixed-form-BZjJHVRy.js"),__vite__mapDeps([41,42]))},{id:"fortran-free-form",name:"Fortran (Free Form)",aliases:["f90","f95","f03","f08","f18"],import:()=>p(()=>import("./fortran-free-form-D22FLkUw.js"),[])},{id:"fsharp",name:"F#",aliases:["f#","fs"],import:()=>p(()=>import("./fsharp-CXgrBDvD.js"),__vite__mapDeps([43,40]))},{id:"gdresource",name:"GDResource",import:()=>p(()=>import("./gdresource-B7Tvp0Sc.js"),__vite__mapDeps([44,45,46]))},{id:"gdscript",name:"GDScript",import:()=>p(()=>import("./gdscript-DTMYz4Jt.js"),[])},{id:"gdshader",name:"GDShader",import:()=>p(()=>import("./gdshader-DkwncUOv.js"),[])},{id:"genie",name:"Genie",import:()=>p(()=>import("./genie-D0YGMca9.js"),[])},{id:"gherkin",name:"Gherkin",import:()=>p(()=>import("./gherkin-DyxjwDmM.js"),[])},{id:"git-commit",name:"Git Commit Message",import:()=>p(()=>import("./git-commit-F4YmCXRG.js"),__vite__mapDeps([47,48]))},{id:"git-rebase",name:"Git Rebase Message",import:()=>p(()=>import("./git-rebase-r7XF79zn.js"),__vite__mapDeps([49,28]))},{id:"gleam",name:"Gleam",import:()=>p(()=>import("./gleam-BspZqrRM.js"),[])},{id:"glimmer-js",name:"Glimmer JS",aliases:["gjs"],import:()=>p(()=>import("./glimmer-js-Rg0-pVw9.js"),__vite__mapDeps([50,2,11,3,1]))},{id:"glimmer-ts",name:"Glimmer TS",aliases:["gts"],import:()=>p(()=>import("./glimmer-ts-U6CK756n.js"),__vite__mapDeps([51,11,3,2,1]))},{id:"glsl",name:"GLSL",import:()=>p(()=>import("./glsl-DplSGwfg.js"),__vite__mapDeps([25,26]))},{id:"gnuplot",name:"Gnuplot",import:()=>p(()=>import("./gnuplot-DdkO51Og.js"),[])},{id:"go",name:"Go",import:()=>p(()=>import("./go-Dn2_MT6a.js"),[])},{id:"graphql",name:"GraphQL",aliases:["gql"],import:()=>p(()=>import("./graphql-ChdNCCLP.js"),__vite__mapDeps([35,2,11,36,13]))},{id:"groovy",name:"Groovy",import:()=>p(()=>import("./groovy-gcz8RCvz.js"),[])},{id:"hack",name:"Hack",import:()=>p(()=>import("./hack-CaT9iCJl.js"),__vite__mapDeps([52,1,2,3,16]))},{id:"haml",name:"Ruby Haml",import:()=>p(()=>import("./haml-B8DHNrY2.js"),__vite__mapDeps([34,2,3]))},{id:"handlebars",name:"Handlebars",aliases:["hbs"],import:()=>p(()=>import("./handlebars-BL8al0AC.js"),__vite__mapDeps([53,1,2,3,38]))},{id:"haskell",name:"Haskell",aliases:["hs"],import:()=>p(()=>import("./haskell-Df6bDoY_.js"),[])},{id:"haxe",name:"Haxe",import:()=>p(()=>import("./haxe-CzTSHFRz.js"),[])},{id:"hcl",name:"HashiCorp HCL",import:()=>p(()=>import("./hcl-BWvSN4gD.js"),[])},{id:"hjson",name:"Hjson",import:()=>p(()=>import("./hjson-D5-asLiD.js"),[])},{id:"hlsl",name:"HLSL",import:()=>p(()=>import("./hlsl-D3lLCCz7.js"),[])},{id:"html",name:"HTML",import:()=>p(()=>import("./html-GMplVEZG.js"),__vite__mapDeps([1,2,3]))},{id:"html-derivative",name:"HTML (Derivative)",import:()=>p(()=>import("./html-derivative-BFtXZ54Q.js"),__vite__mapDeps([15,1,2,3]))},{id:"http",name:"HTTP",import:()=>p(()=>import("./http-jrhK8wxY.js"),__vite__mapDeps([54,28,9,7,8,35,2,11,36,13]))},{id:"hurl",name:"Hurl",import:()=>p(()=>import("./hurl-irOxFIW8.js"),__vite__mapDeps([55,35,2,11,36,13,7,8,56]))},{id:"hxml",name:"HXML",import:()=>p(()=>import("./hxml-Bvhsp5Yf.js"),__vite__mapDeps([57,58]))},{id:"hy",name:"Hy",import:()=>p(()=>import("./hy-DFXneXwc.js"),[])},{id:"imba",name:"Imba",import:()=>p(()=>import("./imba-DGztddWO.js"),[])},{id:"ini",name:"INI",aliases:["properties"],import:()=>p(()=>import("./ini-BEwlwnbL.js"),[])},{id:"java",name:"Java",import:()=>p(()=>import("./java-CylS5w8V.js"),[])},{id:"javascript",name:"JavaScript",aliases:["js","cjs","mjs"],import:()=>p(()=>import("./javascript-wDzz0qaB.js"),[])},{id:"jinja",name:"Jinja",import:()=>p(()=>import("./jinja-4LBKfQ-Z.js"),__vite__mapDeps([59,1,2,3]))},{id:"jison",name:"Jison",import:()=>p(()=>import("./jison-wvAkD_A8.js"),__vite__mapDeps([60,2]))},{id:"json",name:"JSON",import:()=>p(()=>import("./json-Cp-IABpG.js"),[])},{id:"json5",name:"JSON5",import:()=>p(()=>import("./json5-C9tS-k6U.js"),[])},{id:"jsonc",name:"JSON with Comments",import:()=>p(()=>import("./jsonc-Des-eS-w.js"),[])},{id:"jsonl",name:"JSON Lines",import:()=>p(()=>import("./jsonl-DcaNXYhu.js"),[])},{id:"jsonnet",name:"Jsonnet",import:()=>p(()=>import("./jsonnet-DFQXde-d.js"),[])},{id:"jssm",name:"JSSM",aliases:["fsl"],import:()=>p(()=>import("./jssm-C2t-YnRu.js"),[])},{id:"jsx",name:"JSX",import:()=>p(()=>import("./jsx-g9-lgVsj.js"),[])},{id:"julia",name:"Julia",aliases:["jl"],import:()=>p(()=>import("./julia-C8NyazO9.js"),__vite__mapDeps([61,23,24,25,26,16,20,2,62]))},{id:"kdl",name:"KDL",import:()=>p(()=>import("./kdl-DV7GczEv.js"),[])},{id:"kotlin",name:"Kotlin",aliases:["kt","kts"],import:()=>p(()=>import("./kotlin-BdnUsdx6.js"),[])},{id:"kusto",name:"Kusto",aliases:["kql"],import:()=>p(()=>import("./kusto-BvAqAH-y.js"),[])},{id:"latex",name:"LaTeX",import:()=>p(()=>import("./latex-BdAV_C_H.js"),__vite__mapDeps([63,64,62]))},{id:"lean",name:"Lean 4",aliases:["lean4"],import:()=>p(()=>import("./lean-Bc6EcWN3.js"),[])},{id:"less",name:"Less",import:()=>p(()=>import("./less-B1dDrJ26.js"),[])},{id:"liquid",name:"Liquid",import:()=>p(()=>import("./liquid-DYVedYrR.js"),__vite__mapDeps([65,1,2,3,9]))},{id:"llvm",name:"LLVM IR",import:()=>p(()=>import("./llvm-BtvRca6l.js"),[])},{id:"log",name:"Log file",import:()=>p(()=>import("./log-2UxHyX5q.js"),[])},{id:"logo",name:"Logo",import:()=>p(()=>import("./logo-BtOb2qkB.js"),[])},{id:"lua",name:"Lua",import:()=>p(()=>import("./lua-BbnMAYS6.js"),__vite__mapDeps([37,26]))},{id:"luau",name:"Luau",import:()=>p(()=>import("./luau-CXu1NL6O.js"),[])},{id:"make",name:"Makefile",aliases:["makefile"],import:()=>p(()=>import("./make-CHLpvVh8.js"),[])},{id:"markdown",name:"Markdown",aliases:["md"],import:()=>p(()=>import("./markdown-Cvjx9yec.js"),[])},{id:"marko",name:"Marko",import:()=>p(()=>import("./marko-CPi9NSCl.js"),__vite__mapDeps([66,3,67,5,11]))},{id:"matlab",name:"MATLAB",import:()=>p(()=>import("./matlab-D7o27uSR.js"),[])},{id:"mdc",name:"MDC",import:()=>p(()=>import("./mdc-DUICxH0z.js"),__vite__mapDeps([68,40,38,15,1,2,3]))},{id:"mdx",name:"MDX",import:()=>p(()=>import("./mdx-Cmh6b_Ma.js"),[])},{id:"mermaid",name:"Mermaid",aliases:["mmd"],import:()=>p(()=>import("./mermaid-DKYwYmdq.js"),[])},{id:"mipsasm",name:"MIPS Assembly",aliases:["mips"],import:()=>p(()=>import("./mipsasm-CKIfxQSi.js"),[])},{id:"mojo",name:"Mojo",import:()=>p(()=>import("./mojo-1DNp92w6.js"),[])},{id:"move",name:"Move",import:()=>p(()=>import("./move-Bu9oaDYs.js"),[])},{id:"narrat",name:"Narrat Language",aliases:["nar"],import:()=>p(()=>import("./narrat-DRg8JJMk.js"),[])},{id:"nextflow",name:"Nextflow",aliases:["nf"],import:()=>p(()=>import("./nextflow-BrzmwbiE.js"),[])},{id:"nginx",name:"Nginx",import:()=>p(()=>import("./nginx-DknmC5AR.js"),__vite__mapDeps([69,37,26]))},{id:"nim",name:"Nim",import:()=>p(()=>import("./nim-CVrawwO9.js"),__vite__mapDeps([70,26,1,2,3,7,8,25,40]))},{id:"nix",name:"Nix",import:()=>p(()=>import("./nix-c8nO5XWb.js"),[])},{id:"nushell",name:"nushell",aliases:["nu"],import:()=>p(()=>import("./nushell-C-sUppwS.js"),[])},{id:"objective-c",name:"Objective-C",aliases:["objc"],import:()=>p(()=>import("./objective-c-DXmwc3jG.js"),[])},{id:"objective-cpp",name:"Objective-C++",import:()=>p(()=>import("./objective-cpp-CLxacb5B.js"),[])},{id:"ocaml",name:"OCaml",import:()=>p(()=>import("./ocaml-C0hk2d4L.js"),[])},{id:"openscad",name:"OpenSCAD",aliases:["scad"],import:()=>p(()=>import("./openscad-C4EeE6gA.js"),[])},{id:"pascal",name:"Pascal",import:()=>p(()=>import("./pascal-D93ZcfNL.js"),[])},{id:"perl",name:"Perl",import:()=>p(()=>import("./perl-C0TMdlhV.js"),__vite__mapDeps([71,1,2,3,7,8,16]))},{id:"php",name:"PHP",import:()=>p(()=>import("./php-CDn_0X-4.js"),__vite__mapDeps([72,1,2,3,7,8,16,9]))},{id:"pkl",name:"Pkl",import:()=>p(()=>import("./pkl-u5AG7uiY.js"),[])},{id:"plsql",name:"PL/SQL",import:()=>p(()=>import("./plsql-ChMvpjG-.js"),[])},{id:"po",name:"Gettext PO",aliases:["pot","potx"],import:()=>p(()=>import("./po-BTJTHyun.js"),[])},{id:"polar",name:"Polar",import:()=>p(()=>import("./polar-C0HS_06l.js"),[])},{id:"postcss",name:"PostCSS",import:()=>p(()=>import("./postcss-CXtECtnM.js"),[])},{id:"powerquery",name:"PowerQuery",import:()=>p(()=>import("./powerquery-CEu0bR-o.js"),[])},{id:"powershell",name:"PowerShell",aliases:["ps","ps1"],import:()=>p(()=>import("./powershell-Dpen1YoG.js"),[])},{id:"prisma",name:"Prisma",import:()=>p(()=>import("./prisma-Dd19v3D-.js"),[])},{id:"prolog",name:"Prolog",import:()=>p(()=>import("./prolog-CbFg5uaA.js"),[])},{id:"proto",name:"Protocol Buffer 3",aliases:["protobuf"],import:()=>p(()=>import("./proto-DyJlTyXw.js"),[])},{id:"pug",name:"Pug",aliases:["jade"],import:()=>p(()=>import("./pug-CGlum2m_.js"),__vite__mapDeps([73,2,3,1]))},{id:"puppet",name:"Puppet",import:()=>p(()=>import("./puppet-BMWR74SV.js"),[])},{id:"purescript",name:"PureScript",import:()=>p(()=>import("./purescript-CklMAg4u.js"),[])},{id:"python",name:"Python",aliases:["py"],import:()=>p(()=>import("./python-B6aJPvgy.js"),[])},{id:"qml",name:"QML",import:()=>p(()=>import("./qml-3beO22l8.js"),__vite__mapDeps([74,2]))},{id:"qmldir",name:"QML Directory",import:()=>p(()=>import("./qmldir-C8lEn-DE.js"),[])},{id:"qss",name:"Qt Style Sheets",import:()=>p(()=>import("./qss-IeuSbFQv.js"),[])},{id:"r",name:"R",import:()=>p(()=>import("./r-DiinP2Uv.js"),[])},{id:"racket",name:"Racket",import:()=>p(()=>import("./racket-BqYA7rlc.js"),[])},{id:"raku",name:"Raku",aliases:["perl6"],import:()=>p(()=>import("./raku-DXvB9xmW.js"),[])},{id:"razor",name:"ASP.NET Razor",import:()=>p(()=>import("./razor-CE9lU5zL.js"),__vite__mapDeps([75,1,2,3,76]))},{id:"reg",name:"Windows Registry Script",import:()=>p(()=>import("./reg-C-SQnVFl.js"),[])},{id:"regexp",name:"RegExp",aliases:["regex"],import:()=>p(()=>import("./regexp-CDVJQ6XC.js"),[])},{id:"rel",name:"Rel",import:()=>p(()=>import("./rel-C3B-1QV4.js"),[])},{id:"riscv",name:"RISC-V",import:()=>p(()=>import("./riscv-BM1_JUlF.js"),[])},{id:"rosmsg",name:"ROS Interface",import:()=>p(()=>import("./rosmsg-BJDFO7_C.js"),[])},{id:"rst",name:"reStructuredText",import:()=>p(()=>import("./rst-B0xPkSld.js"),__vite__mapDeps([77,15,1,2,3,23,24,25,26,16,20,28,38,78,33,34,7,8,35,11,36,13,37]))},{id:"ruby",name:"Ruby",aliases:["rb"],import:()=>p(()=>import("./ruby-BvKwtOVI.js"),__vite__mapDeps([33,1,2,3,34,7,8,16,35,11,36,13,23,24,25,26,28,37,38]))},{id:"rust",name:"Rust",aliases:["rs"],import:()=>p(()=>import("./rust-B1yitclQ.js"),[])},{id:"sas",name:"SAS",import:()=>p(()=>import("./sas-cz2c8ADy.js"),__vite__mapDeps([79,16]))},{id:"sass",name:"Sass",import:()=>p(()=>import("./sass-Cj5Yp3dK.js"),[])},{id:"scala",name:"Scala",import:()=>p(()=>import("./scala-C151Ov-r.js"),[])},{id:"scheme",name:"Scheme",import:()=>p(()=>import("./scheme-C98Dy4si.js"),[])},{id:"scss",name:"SCSS",import:()=>p(()=>import("./scss-OYdSNvt2.js"),__vite__mapDeps([5,3]))},{id:"sdbl",name:"1C (Query)",aliases:["1c-query"],import:()=>p(()=>import("./sdbl-DVxCFoDh.js"),[])},{id:"shaderlab",name:"ShaderLab",aliases:["shader"],import:()=>p(()=>import("./shaderlab-Dg9Lc6iA.js"),__vite__mapDeps([80,81]))},{id:"shellscript",name:"Shell",aliases:["bash","sh","shell","zsh"],import:()=>p(()=>import("./shellscript-Yzrsuije.js"),[])},{id:"shellsession",name:"Shell Session",aliases:["console"],import:()=>p(()=>import("./shellsession-BADoaaVG.js"),__vite__mapDeps([82,28]))},{id:"smalltalk",name:"Smalltalk",import:()=>p(()=>import("./smalltalk-BERRCDM3.js"),[])},{id:"solidity",name:"Solidity",import:()=>p(()=>import("./solidity-rGO070M0.js"),[])},{id:"soy",name:"Closure Templates",aliases:["closure-templates"],import:()=>p(()=>import("./soy-Brmx7dQM.js"),__vite__mapDeps([83,1,2,3]))},{id:"sparql",name:"SPARQL",import:()=>p(()=>import("./sparql-rVzFXLq3.js"),__vite__mapDeps([84,85]))},{id:"splunk",name:"Splunk Query Language",aliases:["spl"],import:()=>p(()=>import("./splunk-BtCnVYZw.js"),[])},{id:"sql",name:"SQL",import:()=>p(()=>import("./sql-BLtJtn59.js"),[])},{id:"ssh-config",name:"SSH Config",import:()=>p(()=>import("./ssh-config-_ykCGR6B.js"),[])},{id:"stata",name:"Stata",import:()=>p(()=>import("./stata-BH5u7GGu.js"),__vite__mapDeps([86,16]))},{id:"stylus",name:"Stylus",aliases:["styl"],import:()=>p(()=>import("./stylus-BEDo0Tqx.js"),[])},{id:"svelte",name:"Svelte",import:()=>p(()=>import("./svelte-3Dk4HxPD.js"),__vite__mapDeps([87,2,11,3,12]))},{id:"swift",name:"Swift",import:()=>p(()=>import("./swift-Dg5xB15N.js"),[])},{id:"system-verilog",name:"SystemVerilog",import:()=>p(()=>import("./system-verilog-CnnmHF94.js"),[])},{id:"systemd",name:"Systemd Units",import:()=>p(()=>import("./systemd-4A_iFExJ.js"),[])},{id:"talonscript",name:"TalonScript",aliases:["talon"],import:()=>p(()=>import("./talonscript-CkByrt1z.js"),[])},{id:"tasl",name:"Tasl",import:()=>p(()=>import("./tasl-QIJgUcNo.js"),[])},{id:"tcl",name:"Tcl",import:()=>p(()=>import("./tcl-dwOrl1Do.js"),[])},{id:"templ",name:"Templ",import:()=>p(()=>import("./templ-W15q3VgB.js"),__vite__mapDeps([88,89,2,3]))},{id:"terraform",name:"Terraform",aliases:["tf","tfvars"],import:()=>p(()=>import("./terraform-BETggiCN.js"),[])},{id:"tex",name:"TeX",import:()=>p(()=>import("./tex-CxkMU7Pf.js"),__vite__mapDeps([64,62]))},{id:"toml",name:"TOML",import:()=>p(()=>import("./toml-vGWfd6FD.js"),[])},{id:"ts-tags",name:"TypeScript with Tags",aliases:["lit"],import:()=>p(()=>import("./ts-tags-zn1MmPIZ.js"),__vite__mapDeps([90,11,3,2,25,26,1,16,7,8]))},{id:"tsv",name:"TSV",import:()=>p(()=>import("./tsv-B_m7g4N7.js"),[])},{id:"tsx",name:"TSX",import:()=>p(()=>import("./tsx-COt5Ahok.js"),[])},{id:"turtle",name:"Turtle",import:()=>p(()=>import("./turtle-BsS91CYL.js"),[])},{id:"twig",name:"Twig",import:()=>p(()=>import("./twig-CO9l9SDP.js"),__vite__mapDeps([91,3,2,5,72,1,7,8,16,9,20,33,34,35,11,36,13,23,24,25,26,28,37,38]))},{id:"typescript",name:"TypeScript",aliases:["ts","cts","mts"],import:()=>p(()=>import("./typescript-BPQ3VLAy.js"),[])},{id:"typespec",name:"TypeSpec",aliases:["tsp"],import:()=>p(()=>import("./typespec-BGHnOYBU.js"),[])},{id:"typst",name:"Typst",aliases:["typ"],import:()=>p(()=>import("./typst-DHCkPAjA.js"),[])},{id:"v",name:"V",import:()=>p(()=>import("./v-BcVCzyr7.js"),[])},{id:"vala",name:"Vala",import:()=>p(()=>import("./vala-CsfeWuGM.js"),[])},{id:"vb",name:"Visual Basic",aliases:["cmd"],import:()=>p(()=>import("./vb-D17OF-Vu.js"),[])},{id:"verilog",name:"Verilog",import:()=>p(()=>import("./verilog-BQ8w6xss.js"),[])},{id:"vhdl",name:"VHDL",import:()=>p(()=>import("./vhdl-CeAyd5Ju.js"),[])},{id:"viml",name:"Vim Script",aliases:["vim","vimscript"],import:()=>p(()=>import("./viml-CJc9bBzg.js"),[])},{id:"vue",name:"Vue",import:()=>p(()=>import("./vue-DnHKYNfI.js"),__vite__mapDeps([92,3,2,11,9,15,1]))},{id:"vue-html",name:"Vue HTML",import:()=>p(()=>import("./vue-html-CChd_i61.js"),__vite__mapDeps([93,92,3,2,11,9,15,1]))},{id:"vue-vine",name:"Vue Vine",import:()=>p(()=>import("./vue-vine-8moa0y9V.js"),__vite__mapDeps([94,3,5,67,95,12,92,2,11,9,15,1]))},{id:"vyper",name:"Vyper",aliases:["vy"],import:()=>p(()=>import("./vyper-CDx5xZoG.js"),[])},{id:"wasm",name:"WebAssembly",import:()=>p(()=>import("./wasm-MzD3tlZU.js"),[])},{id:"wenyan",name:"Wenyan",aliases:["文言"],import:()=>p(()=>import("./wenyan-BV7otONQ.js"),[])},{id:"wgsl",name:"WGSL",import:()=>p(()=>import("./wgsl-Dx-B1_4e.js"),[])},{id:"wikitext",name:"Wikitext",aliases:["mediawiki","wiki"],import:()=>p(()=>import("./wikitext-BhOHFoWU.js"),[])},{id:"wit",name:"WebAssembly Interface Types",import:()=>p(()=>import("./wit-5i3qLPDT.js"),[])},{id:"wolfram",name:"Wolfram",aliases:["wl"],import:()=>p(()=>import("./wolfram-lXgVvXCa.js"),[])},{id:"xml",name:"XML",import:()=>p(()=>import("./xml-sdJ4AIDG.js"),__vite__mapDeps([7,8]))},{id:"xsl",name:"XSL",import:()=>p(()=>import("./xsl-CtQFsRM5.js"),__vite__mapDeps([96,7,8]))},{id:"yaml",name:"YAML",aliases:["yml"],import:()=>p(()=>import("./yaml-Buea-lGh.js"),[])},{id:"zenscript",name:"ZenScript",import:()=>p(()=>import("./zenscript-DVFEvuxE.js"),[])},{id:"zig",name:"Zig",import:()=>p(()=>import("./zig-VOosw3JB.js"),[])}],$K=Object.fromEntries(vk.map(e=>[e.id,e.import])),AL=Object.fromEntries(vk.flatMap(e=>e.aliases?.map(A=>[A,e.import])||[])),eL={...$K,...AL};function jg(e){if([...e].length!==1)throw new Error(`Expected "${e}" to be a single code point`);return e.codePointAt(0)}function tL(e,A,t){return e.has(A)||e.set(A,t),e.get(A)}const gu=new Set(["alnum","alpha","ascii","blank","cntrl","digit","graph","lower","print","punct","space","upper","word","xdigit"]),Lt=String.raw;function Vg(e,A){if(e==null)throw new Error(A??"Value expected");return e}const bk=Lt`\[\^?`,Fk=`c.? | C(?:-.?)?|${Lt`[pP]\{(?:\^?[-\x20_]*[A-Za-z][-\x20\w]*\})?`}|${Lt`x[89A-Fa-f]\p{AHex}(?:\\x[89A-Fa-f]\p{AHex})*`}|${Lt`u(?:\p{AHex}{4})? | x\{[^\}]*\}? | x\p{AHex}{0,2}`}|${Lt`o\{[^\}]*\}?`}|${Lt`\d{1,3}`}`,Qu=/[?*+][?+]?|\{(?:\d+(?:,\d*)?|,\d+)\}\??/,Ma=new RegExp(Lt` \\ (?: ${Fk} | [gk]<[^>]*>? | [gk]'[^']*'? | . ) | \( (?: \? (?: [:=!>({] | <[=!] | <[^>]*> | '[^']*' | ~\|? | #(?:[^)\\]|\\.?)* | [^:)]*[:)] )? | \*[^\)]*\)? )? | (?:${Qu.source})+ | ${bk} | . `.replace(/\s+/g,""),"gsu"),PC=new RegExp(Lt` \\ (?: ${Fk} | . ) | \[:(?:\^?\p{Alpha}+|\^):\] | ${bk} | && | . `.replace(/\s+/g,""),"gsu");function rL(e,A={}){const t={flags:"",...A,rules:{captureGroup:!1,singleline:!1,...A.rules}};if(typeof e!="string")throw new Error("String expected as pattern");const r=wL(t.flags),n=[r.extended],i={captureGroup:t.rules.captureGroup,getCurrentModX(){return n.at(-1)},numOpenGroups:0,popModX(){n.pop()},pushModX(s){n.push(s)},replaceCurrentModX(s){n[n.length-1]=s},singleline:t.rules.singleline};let o=[],g;for(Ma.lastIndex=0;g=Ma.exec(e);){const s=nL(i,e,g[0],Ma.lastIndex);s.tokens?o.push(...s.tokens):s.token&&o.push(s.token),s.lastIndex!==void 0&&(Ma.lastIndex=s.lastIndex)}const Q=[];let B=0;o.filter(s=>s.type==="GroupOpen").forEach(s=>{s.kind==="capturing"?s.number=++B:s.raw==="("&&Q.push(s)}),B||Q.forEach((s,C)=>{s.kind="capturing",s.number=C+1});const a=B||Q.length;return{tokens:o.map(s=>s.type==="EscapedNumber"?pL(s,a):s).flat(),flags:r}}function nL(e,A,t,r){const[n,i]=t;if(t==="["||t==="[^"){const o=iL(A,t,r);return{tokens:o.tokens,lastIndex:o.lastIndex}}if(n==="\\"){if("AbBGyYzZ".includes(i))return{token:kD(t,t)};if(/^\\g[<']/.test(t)){if(!/^\\g(?:<[^>]+>|'[^']+')$/.test(t))throw new Error(`Invalid group name "${t}"`);return{token:lL(t)}}if(/^\\k[<']/.test(t)){if(!/^\\k(?:<[^>]+>|'[^']+')$/.test(t))throw new Error(`Invalid group name "${t}"`);return{token:Gk(t)}}if(i==="K")return{token:Sk("keep",t)};if(i==="N"||i==="R")return{token:uo("newline",t,{negate:i==="N"})};if(i==="O")return{token:uo("any",t)};if(i==="X")return{token:uo("text_segment",t)};const o=xk(t,{inCharClass:!1});return Array.isArray(o)?{tokens:o}:{token:o}}if(n==="("){if(i==="*")return{token:hL(t)};if(t==="(?{")throw new Error(`Unsupported callout "${t}"`);if(t.startsWith("(?#")){if(A[r]!==")")throw new Error('Unclosed comment group "(?#"');return{lastIndex:r+1}}if(/^\(\?[-imx]+[:)]$/.test(t))return{token:dL(t,e)};if(e.pushModX(e.getCurrentModX()),e.numOpenGroups++,t==="("&&!e.captureGroup||t==="(?:")return{token:lg("group",t)};if(t==="(?>")return{token:lg("atomic",t)};if(t==="(?="||t==="(?!"||t==="(?<="||t==="(?")||t.startsWith("(?'")&&t.endsWith("'"))return{token:lg("capturing",t,{...t!=="("&&{name:t.slice(3,-1)}})};if(t.startsWith("(?~")){if(t==="(?~|")throw new Error(`Unsupported absence function kind "${t}"`);return{token:lg("absence_repeater",t)}}throw t==="(?("?new Error(`Unsupported conditional "${t}"`):new Error(`Invalid or unsupported group option "${t}"`)}if(t===")"){if(e.popModX(),e.numOpenGroups--,e.numOpenGroups<0)throw new Error('Unmatched ")"');return{token:EL(t)}}if(e.getCurrentModX()){if(t==="#"){const o=A.indexOf(` `,r);return{lastIndex:o===-1?A.length:o}}if(/^\s$/.test(t)){const o=/\s+/y;return o.lastIndex=r,{lastIndex:o.exec(A)?o.lastIndex:r}}}if(t===".")return{token:uo("dot",t)};if(t==="^"||t==="$"){const o=e.singleline?{"^":Lt`\A`,$:Lt`\Z`}[t]:t;return{token:kD(o,t)}}return t==="|"?{token:gL(t)}:Qu.test(t)?{tokens:kL(t)}:{token:Yn(jg(t),t)}}function iL(e,A,t){const r=[yD(A[1]==="^",A)];let n=1,i;for(PC.lastIndex=t;i=PC.exec(e);){const o=i[0];if(o[0]==="["&&o[1]!==":")n++,r.push(yD(o[1]==="^",o));else if(o==="]"){if(r.at(-1).type==="CharacterClassOpen")r.push(Yn(93,o));else if(n--,r.push(QL(o)),!n)break}else{const g=oL(o);Array.isArray(g)?r.push(...g):r.push(g)}}return{tokens:r,lastIndex:PC.lastIndex||e.length}}function oL(e){if(e[0]==="\\")return xk(e,{inCharClass:!0});if(e[0]==="["){const A=/\[:(?\^?)(?[a-z]+):\]/.exec(e);if(!A||!gu.has(A.groups.name))throw new Error(`Invalid POSIX class "${e}"`);return uo("posix",e,{value:A.groups.name,negate:!!A.groups.negate})}return e==="-"?BL(e):e==="&&"?aL(e):Yn(jg(e),e)}function xk(e,{inCharClass:A}){const t=e[1];if(t==="c"||t==="C")return uL(e);if("dDhHsSwW".includes(t))return DL(e);if(e.startsWith(Lt`\o{`))throw new Error(`Incomplete, invalid, or unsupported octal code point "${e}"`);if(/^\\[pP]\{/.test(e)){if(e.length===3)throw new Error(`Incomplete or invalid Unicode property "${e}"`);return fL(e)}if(/^\\x[89A-Fa-f]\p{AHex}/u.test(e))try{const r=e.split(/\\x/).slice(1).map(o=>parseInt(o,16)),n=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}).decode(new Uint8Array(r)),i=new TextEncoder;return[...n].map(o=>{const g=[...i.encode(o)].map(Q=>`\\x${Q.toString(16)}`).join("");return Yn(jg(o),g)})}catch{throw new Error(`Multibyte code "${e}" incomplete or invalid in Oniguruma`)}if(t==="u"||t==="x")return Yn(mL(e),e);if(MD.has(t))return Yn(MD.get(t),e);if(/\d/.test(t))return sL(A,e);if(e==="\\")throw new Error(Lt`Incomplete escape "\"`);if(t==="M")throw new Error(`Unsupported meta "${e}"`);if([...e].length===2)return Yn(e.codePointAt(1),e);throw new Error(`Unexpected escape "${e}"`)}function gL(e){return{type:"Alternator",raw:e}}function kD(e,A){return{type:"Assertion",kind:e,raw:A}}function Gk(e){return{type:"Backreference",raw:e}}function Yn(e,A){return{type:"Character",value:e,raw:A}}function QL(e){return{type:"CharacterClassClose",raw:e}}function BL(e){return{type:"CharacterClassHyphen",raw:e}}function aL(e){return{type:"CharacterClassIntersector",raw:e}}function yD(e,A){return{type:"CharacterClassOpen",negate:e,raw:A}}function uo(e,A,t={}){return{type:"CharacterSet",kind:e,...t,raw:A}}function Sk(e,A,t={}){return e==="keep"?{type:"Directive",kind:e,raw:A}:{type:"Directive",kind:e,flags:Vg(t.flags),raw:A}}function sL(e,A){return{type:"EscapedNumber",inCharClass:e,raw:A}}function EL(e){return{type:"GroupClose",raw:e}}function lg(e,A,t={}){return{type:"GroupOpen",kind:e,...t,raw:A}}function CL(e,A,t,r){return{type:"NamedCallout",kind:e,tag:A,arguments:t,raw:r}}function IL(e,A,t,r){return{type:"Quantifier",kind:e,min:A,max:t,raw:r}}function lL(e){return{type:"Subroutine",raw:e}}const cL=new Set(["COUNT","CMP","ERROR","FAIL","MAX","MISMATCH","SKIP","TOTAL_COUNT"]),MD=new Map([["a",7],["b",8],["e",27],["f",12],["n",10],["r",13],["t",9],["v",11]]);function uL(e){const A=e[1]==="c"?e[2]:e[3];if(!A||!/[A-Za-z]/.test(A))throw new Error(`Unsupported control character "${e}"`);return Yn(jg(A.toUpperCase())-64,e)}function dL(e,A){let{on:t,off:r}=/^\(\?(?[imx]*)(?:-(?[-imx]*))?/.exec(e).groups;r??="";const n=(A.getCurrentModX()||t.includes("x"))&&!r.includes("x"),i=vD(t),o=vD(r),g={};if(i&&(g.enable=i),o&&(g.disable=o),e.endsWith(")"))return A.replaceCurrentModX(n),Sk("flags",e,{flags:g});if(e.endsWith(":"))return A.pushModX(n),A.numOpenGroups++,lg("group",e,{...(i||o)&&{flags:g}});throw new Error(`Unexpected flag modifier "${e}"`)}function hL(e){const A=/\(\*(?[A-Za-z_]\w*)?(?:\[(?(?:[A-Za-z_]\w*)?)\])?(?:\{(?[^}]*)\})?\)/.exec(e);if(!A)throw new Error(`Incomplete or invalid named callout "${e}"`);const{name:t,tag:r,args:n}=A.groups;if(!t)throw new Error(`Invalid named callout "${e}"`);if(r==="")throw new Error(`Named callout tag with empty value not allowed "${e}"`);const i=n?n.split(",").filter(a=>a!=="").map(a=>/^[+-]?\d+$/.test(a)?+a:a):[],[o,g,Q]=i,B=cL.has(t)?t.toLowerCase():"custom";switch(B){case"fail":case"mismatch":case"skip":if(i.length>0)throw new Error(`Named callout arguments not allowed "${i}"`);break;case"error":if(i.length>1)throw new Error(`Named callout allows only one argument "${i}"`);if(typeof o=="string")throw new Error(`Named callout argument must be a number "${o}"`);break;case"max":if(!i.length||i.length>2)throw new Error(`Named callout must have one or two arguments "${i}"`);if(typeof o=="string"&&!/^[A-Za-z_]\w*$/.test(o))throw new Error(`Named callout argument one must be a tag or number "${o}"`);if(i.length===2&&(typeof g=="number"||!/^[<>X]$/.test(g)))throw new Error(`Named callout optional argument two must be '<', '>', or 'X' "${g}"`);break;case"count":case"total_count":if(i.length>1)throw new Error(`Named callout allows only one argument "${i}"`);if(i.length===1&&(typeof o=="number"||!/^[<>X]$/.test(o)))throw new Error(`Named callout optional argument must be '<', '>', or 'X' "${o}"`);break;case"cmp":if(i.length!==3)throw new Error(`Named callout must have three arguments "${i}"`);if(typeof o=="string"&&!/^[A-Za-z_]\w*$/.test(o))throw new Error(`Named callout argument one must be a tag or number "${o}"`);if(typeof g=="number"||!/^(?:[<>!=]=|[<>])$/.test(g))throw new Error(`Named callout argument two must be '==', '!=', '>', '<', '>=', or '<=' "${g}"`);if(typeof Q=="string"&&!/^[A-Za-z_]\w*$/.test(Q))throw new Error(`Named callout argument three must be a tag or number "${Q}"`);break;case"custom":throw new Error(`Undefined callout name "${t}"`);default:throw new Error(`Unexpected named callout kind "${B}"`)}return CL(B,r??null,n?.split(",")??null,e)}function ND(e){let A=null,t,r;if(e[0]==="{"){const{minStr:n,maxStr:i}=/^\{(?\d*)(?:,(?\d*))?/.exec(e).groups,o=1e5;if(+n>o||i&&+i>o)throw new Error("Quantifier value unsupported in Oniguruma");if(t=+n,r=i===void 0?+n:i===""?1/0:+i,t>r&&(A="possessive",[t,r]=[r,t]),e.endsWith("?")){if(A==="possessive")throw new Error('Unsupported possessive interval quantifier chain with "?"');A="lazy"}else A||(A="greedy")}else t=e[0]==="+"?1:0,r=e[0]==="?"?1:1/0,A=e[1]==="+"?"possessive":e[1]==="?"?"lazy":"greedy";return IL(A,t,r,e)}function DL(e){const A=e[1].toLowerCase();return uo({d:"digit",h:"hex",s:"space",w:"word"}[A],e,{negate:e[1]!==A})}function fL(e){const{p:A,neg:t,value:r}=/^\\(?

    [pP])\{(?\^?)(?[^}]+)/.exec(e).groups;return uo("property",e,{value:r,negate:A==="P"&&!t||A==="p"&&!!t})}function vD(e){const A={};return e.includes("i")&&(A.ignoreCase=!0),e.includes("m")&&(A.dotAll=!0),e.includes("x")&&(A.extended=!0),Object.keys(A).length?A:null}function wL(e){const A={ignoreCase:!1,dotAll:!1,extended:!1,digitIsAscii:!1,posixIsAscii:!1,spaceIsAscii:!1,wordIsAscii:!1,textSegmentMode:null};for(let t=0;t\p{AHex}+)/u.exec(e).groups.hex:e.slice(2);return parseInt(A,16)}function pL(e,A){const{raw:t,inCharClass:r}=e,n=t.slice(1);if(!r&&(n!=="0"&&n.length===1||n[0]!=="0"&&+n<=A))return[Gk(t)];const i=[],o=n.match(/^[0-7]+|\d/g);for(let g=0;g127)throw new Error(Lt`Octal encoded byte above 177 unsupported "${t}"`)}else B=jg(Q);i.push(Yn(B,(g===0?"\\":"")+Q))}return i}function kL(e){const A=[],t=new RegExp(Qu,"gy");let r;for(;r=t.exec(e);){const n=r[0];if(n[0]==="{"){const i=/^\{(?\d+),(?\d+)\}\??$/.exec(n);if(i){const{min:o,max:g}=i.groups;if(+o>+g&&n.endsWith("?")){t.lastIndex--,A.push(ND(n.slice(0,-1)));continue}}}A.push(ND(n))}return A}function Jk(e,A){if(!Array.isArray(e.body))throw new Error("Expected node with body array");if(e.body.length!==1)return!1;const t=e.body[0];return!A||Object.keys(A).every(r=>A[r]===t[r])}function yL(e){return ML.has(e.type)}const ML=new Set(["AbsenceFunction","Backreference","CapturingGroup","Character","CharacterClass","CharacterSet","Group","Quantifier","Subroutine"]);function Uk(e,A={}){const t={flags:"",normalizeUnknownPropertyNames:!1,skipBackrefValidation:!1,skipLookbehindValidation:!1,skipPropertyNameValidation:!1,unicodePropertyMap:null,...A,rules:{captureGroup:!1,singleline:!1,...A.rules}},r=rL(e,{flags:t.flags,rules:{captureGroup:t.rules.captureGroup,singleline:t.rules.singleline}}),n=(C,E)=>{const I=r.tokens[i.nextIndex];switch(i.parent=C,i.nextIndex++,I.type){case"Alternator":return Fo();case"Assertion":return NL(I);case"Backreference":return vL(I,i);case"Character":return lE(I.value,{useLastValid:!!E.isCheckingRangeEnd});case"CharacterClassHyphen":return bL(I,i,E);case"CharacterClassOpen":return FL(I,i,E);case"CharacterSet":return xL(I,i);case"Directive":return LL(I.kind,{flags:I.flags});case"GroupOpen":return GL(I,i,E);case"NamedCallout":return OL(I.kind,I.tag,I.arguments);case"Quantifier":return SL(I,i);case"Subroutine":return JL(I,i);default:throw new Error(`Unexpected token type "${I.type}"`)}},i={capturingGroups:[],hasNumberedRef:!1,namedGroupsByName:new Map,nextIndex:0,normalizeUnknownPropertyNames:t.normalizeUnknownPropertyNames,parent:null,skipBackrefValidation:t.skipBackrefValidation,skipLookbehindValidation:t.skipLookbehindValidation,skipPropertyNameValidation:t.skipPropertyNameValidation,subroutines:[],tokens:r.tokens,unicodePropertyMap:t.unicodePropertyMap,walk:n},o=TL(RL(r.flags));let g=o.body[0];for(;i.nextIndexQ.length)throw new Error("Subroutine uses a group number that's not defined");C&&(Q[C-1].isSubroutined=!0)}else if(a.has(C)){if(a.get(C).length>1)throw new Error(Lt`Subroutine uses a duplicate group name "\g<${C}>"`);a.get(C)[0].isSubroutined=!0}else throw new Error(Lt`Subroutine uses a group name that's not defined "\g<${C}>"`);return o}function NL({kind:e}){return ll(Vg({"^":"line_start",$:"line_end","\\A":"string_start","\\b":"word_boundary","\\B":"word_boundary","\\G":"search_start","\\y":"text_segment_boundary","\\Y":"text_segment_boundary","\\z":"string_end","\\Z":"string_end_newline"}[e],`Unexpected assertion kind "${e}"`),{negate:e===Lt`\B`||e===Lt`\Y`})}function vL({raw:e},A){const t=/^\\k[<']/.test(e),r=t?e.slice(3,-1):e.slice(1),n=(i,o=!1)=>{const g=A.capturingGroups.length;let Q=!1;if(i>g)if(A.skipBackrefValidation)Q=!0;else throw new Error(`Not enough capturing groups defined to the left "${e}"`);return A.hasNumberedRef=!0,cl(o?g+1-i:i,{orphan:Q})};if(t){const i=/^(?-?)0*(?[1-9]\d*)$/.exec(r);if(i)return n(+i.groups.num,!!i.groups.sign);if(/[-+]/.test(r))throw new Error(`Invalid backref name "${e}"`);if(!A.namedGroupsByName.has(r))throw new Error(`Group name not defined to the left "${e}"`);return cl(r)}return n(+r)}function bL(e,A,t){const{tokens:r,walk:n}=A,i=A.parent,o=i.body.at(-1),g=r[A.nextIndex];if(!t.isCheckingRangeEnd&&o&&o.type!=="CharacterClass"&&o.type!=="CharacterClassRange"&&g&&g.type!=="CharacterClassOpen"&&g.type!=="CharacterClassClose"&&g.type!=="CharacterClassIntersector"){const Q=n(i,{...t,isCheckingRangeEnd:!0});if(o.type==="Character"&&Q.type==="Character")return i.body.pop(),KL(o,Q);throw new Error("Invalid character class range")}return lE(jg("-"))}function FL({negate:e},A,t){const{tokens:r,walk:n}=A,i=r[A.nextIndex],o=[Xa()];let g=xD(i);for(;g.type!=="CharacterClassClose";){if(g.type==="CharacterClassIntersector")o.push(Xa()),A.nextIndex++;else{const B=o.at(-1);B.body.push(n(B,t))}g=xD(r[A.nextIndex],i)}const Q=Xa({negate:e});return o.length===1?Q.body=o[0].body:(Q.kind="intersection",Q.body=o.map(B=>B.body.length===1?B.body[0]:B)),A.nextIndex++,Q}function xL({kind:e,negate:A,value:t},r){const{normalizeUnknownPropertyNames:n,skipPropertyNameValidation:i,unicodePropertyMap:o}=r;if(e==="property"){const g=cE(t);if(gu.has(g)&&!o?.has(g))e="posix",t=g;else return cg(t,{negate:A,normalizeUnknownPropertyNames:n,skipPropertyNameValidation:i,unicodePropertyMap:o})}return e==="posix"?qL(t,{negate:A}):ul(e,{negate:A})}function GL(e,A,t){const{tokens:r,capturingGroups:n,namedGroupsByName:i,skipLookbehindValidation:o,walk:g}=A,Q=HL(e),B=Q.type==="AbsenceFunction",a=FD(Q),s=a&&Q.negate;if(Q.type==="CapturingGroup"&&(n.push(Q),Q.name&&tL(i,Q.name,[]).push(Q)),B&&t.isInAbsenceFunction)throw new Error("Nested absence function not supported by Oniguruma");let C=GD(r[A.nextIndex]);for(;C.type!=="GroupClose";){if(C.type==="Alternator")Q.body.push(Fo()),A.nextIndex++;else{const E=Q.body.at(-1),I=g(E,{...t,isInAbsenceFunction:t.isInAbsenceFunction||B,isInLookbehind:t.isInLookbehind||a,isInNegLookbehind:t.isInNegLookbehind||s});if(E.body.push(I),(a||t.isInLookbehind)&&!o){const c="Lookbehind includes a pattern not allowed by Oniguruma";if(s||t.isInNegLookbehind){if(bD(I)||I.type==="CapturingGroup")throw new Error(c)}else if(bD(I)||FD(I)&&I.negate)throw new Error(c)}}C=GD(r[A.nextIndex])}return A.nextIndex++,Q}function SL({kind:e,min:A,max:t},r){const n=r.parent,i=n.body.at(-1);if(!i||!yL(i))throw new Error("Quantifier requires a repeatable token");const o=Lk(e,A,t,i);return n.body.pop(),o}function JL({raw:e},A){const{capturingGroups:t,subroutines:r}=A;let n=e.slice(3,-1);const i=/^(?[-+]?)0*(?[1-9]\d*)$/.exec(n);if(i){const g=+i.groups.num,Q=t.length;if(A.hasNumberedRef=!0,n={"":g,"+":Q+g,"-":Q+1-g}[i.groups.sign],n<1)throw new Error("Invalid subroutine number")}else n==="0"&&(n=0);const o=Rk(n);return r.push(o),o}function UL(e,A){return{type:"AbsenceFunction",kind:e,body:FB(A?.body)}}function Fo(e){return{type:"Alternative",body:Ok(e?.body)}}function ll(e,A){const t={type:"Assertion",kind:e};return(e==="word_boundary"||e==="text_segment_boundary")&&(t.negate=!!A?.negate),t}function cl(e,A){const t=!!A?.orphan;return{type:"Backreference",ref:e,...t&&{orphan:t}}}function Kk(e,A){const t={name:void 0,isSubroutined:!1,...A};if(t.name!==void 0&&!YL(t.name))throw new Error(`Group name "${t.name}" invalid in Oniguruma`);return{type:"CapturingGroup",number:e,...t.name&&{name:t.name},...t.isSubroutined&&{isSubroutined:t.isSubroutined},body:FB(A?.body)}}function lE(e,A){const t={useLastValid:!1,...A};if(e>1114111){const r=e.toString(16);if(t.useLastValid)e=1114111;else throw e>1310719?new Error(`Invalid code point out of range "\\x{${r}}"`):new Error(`Invalid code point out of range in JS "\\x{${r}}"`)}return{type:"Character",value:e}}function Xa(e){const A={kind:"union",negate:!1,...e};return{type:"CharacterClass",kind:A.kind,negate:A.negate,body:Ok(e?.body)}}function KL(e,A){if(A.valuet)throw new Error("Invalid reversed quantifier range");return{type:"Quantifier",kind:e,min:A,max:t,body:r}}function TL(e,A){return{type:"Regex",body:FB(A?.body),flags:e}}function Rk(e){return{type:"Subroutine",ref:e}}function cg(e,A){const t={negate:!1,normalizeUnknownPropertyNames:!1,skipPropertyNameValidation:!1,unicodePropertyMap:null,...A};let r=t.unicodePropertyMap?.get(cE(e));if(!r){if(t.normalizeUnknownPropertyNames)r=zL(e);else if(t.unicodePropertyMap&&!t.skipPropertyNameValidation)throw new Error(Lt`Invalid Unicode property "\p{${e}}"`)}return{type:"CharacterSet",kind:"property",value:r??e,negate:t.negate}}function HL({flags:e,kind:A,name:t,negate:r,number:n}){switch(A){case"absence_repeater":return UL("repeater");case"atomic":return jr({atomic:!0});case"capturing":return Kk(n,{name:t});case"group":return jr({flags:e});case"lookahead":case"lookbehind":return lo({behind:A==="lookbehind",negate:r});default:throw new Error(`Unexpected group kind "${A}"`)}}function FB(e){if(e===void 0)e=[Fo()];else if(!Array.isArray(e)||!e.length||!e.every(A=>A.type==="Alternative"))throw new Error("Invalid body; expected array of one or more Alternative nodes");return e}function Ok(e){if(e===void 0)e=[];else if(!Array.isArray(e)||!e.every(A=>!!A.type))throw new Error("Invalid body; expected array of nodes");return e}function bD(e){return e.type==="LookaroundAssertion"&&e.kind==="lookahead"}function FD(e){return e.type==="LookaroundAssertion"&&e.kind==="lookbehind"}function YL(e){return/^[\p{Alpha}\p{Pc}][^)]*$/u.test(e)}function zL(e){return e.trim().replace(/[- _]+/g,"_").replace(/[A-Z][a-z]+(?=[A-Z])/g,"$&_").replace(/[A-Za-z]+/g,A=>A[0].toUpperCase()+A.slice(1).toLowerCase())}function cE(e){return e.replace(/[- _]+/g,"").toLowerCase()}function xD(e,A){return Vg(e,`${A?.type==="Character"&&A.value===93?"Empty":"Unclosed"} character class`)}function GD(e){return Vg(e,"Unclosed group")}function _Q(e,A,t=null){function r(i,o){for(let g=0;gA-Za-z\-]|<[=!]|\(DEFINE\))`;function _L(e,A){for(let t=0;t=A&&e[t]++}function jL(e,A,t,r){return e.slice(0,A)+r+e.slice(A+t.length)}const Gr=Object.freeze({DEFAULT:"DEFAULT",CHAR_CLASS:"CHAR_CLASS"});function Bu(e,A,t,r){const n=new RegExp(String.raw`${A}|(?<$skip>\[\^?|\\?.)`,"gsu"),i=[!1];let o=0,g="";for(const Q of e.matchAll(n)){const{0:B,groups:{$skip:a}}=Q;if(!a&&(!r||r===Gr.DEFAULT==!o)){t instanceof Function?g+=t(Q,{context:o?Gr.CHAR_CLASS:Gr.DEFAULT,negated:i[i.length-1]}):g+=t;continue}B[0]==="["?(o++,i.push(B[1]==="^")):B==="]"&&o&&(o--,i.pop()),g+=B}return g}function qk(e,A,t,r){Bu(e,A,t,r)}function VL(e,A,t=0,r){if(!new RegExp(A,"su").test(e))return null;const n=new RegExp(`${A}|(?<$skip>\\\\?.)`,"gsu");n.lastIndex=t;let i=0,o;for(;o=n.exec(e);){const{0:g,groups:{$skip:Q}}=o;if(!Q&&(!r||r===Gr.DEFAULT==!i))return o;g==="["?i++:g==="]"&&i&&i--,n.lastIndex==o.index&&n.lastIndex++}return null}function va(e,A,t){return!!VL(e,A,0,t)}function WL(e,A){const t=/\\?./gsu;t.lastIndex=A;let r=e.length,n=0,i=1,o;for(;o=t.exec(e);){const[g]=o;if(g==="[")n++;else if(n)g==="]"&&n--;else if(g==="(")i++;else if(g===")"&&(i--,!i)){r=o.index;break}}return e.slice(A,r)}const SD=new RegExp(String.raw`(?${PL})|(?\((?:\?<[^>]+>)?)|\\?.`,"gsu");function ZL(e,A){const t=A?.hiddenCaptures??[];let r=A?.captureTransfers??new Map;if(!/\(\?>/.test(e))return{pattern:e,captureTransfers:r,hiddenCaptures:t};const n="(?>",i="(?:(?=(",o=[0],g=[];let Q=0,B=0,a=NaN,s;do{s=!1;let C=0,E=0,I=!1,c;for(SD.lastIndex=Number.isNaN(a)?0:a+i.length;c=SD.exec(e);){const{0:u,index:h,groups:{capturingStart:d,noncapturingStart:f}}=c;if(u==="[")C++;else if(C)u==="]"&&C--;else if(u===n&&!I)a=h,I=!0;else if(I&&f)E++;else if(d)I?E++:(Q++,o.push(Q+B));else if(u===")"&&I){if(!E){B++;const m=Q+B;if(e=`${e.slice(0,a)}${i}${e.slice(a+n.length,h)}))<$$${m}>)${e.slice(h+1)}`,s=!0,g.push(m),_L(t,m),r.size){const k=new Map;r.forEach((N,F)=>{k.set(F>=m?F+1:F,N.map(L=>L>=m?L+1:L))}),r=k}break}E--}}}while(s);return t.push(...g),e=Bu(e,String.raw`\\(?[1-9]\d*)|<\$\$(?\d+)>`,({0:C,groups:{backrefNum:E,wrappedBackrefNum:I}})=>{if(E){const c=+E;if(c>o.length-1)throw new Error(`Backref "${C}" greater than number of captures`);return`\\${o[c]}`}return`\\${I}`},Gr.DEFAULT),{pattern:e,captureTransfers:r,hiddenCaptures:t}}const Tk=String.raw`(?:[?*+]|\{\d+(?:,\d*)?\})`,_C=new RegExp(String.raw` \\(?: \d+ | c[A-Za-z] | [gk]<[^>]+> | [pPu]\{[^\}]+\} | u[A-Fa-f\d]{4} | x[A-Fa-f\d]{2} ) | \((?: \? (?: [:=!>] | <(?:[=!]|[^>]+>) | [A-Za-z\-]+: | \(DEFINE\) ))? | (?${Tk})(?[?+]?)(?[?*+\{]?) | \\?. `.replace(/\s+/g,""),"gsu");function XL(e){if(!new RegExp(`${Tk}\\+`).test(e))return{pattern:e};const A=[];let t=null,r=null,n="",i=0,o;for(_C.lastIndex=0;o=_C.exec(e);){const{0:g,index:Q,groups:{qBase:B,qMod:a,invalidQ:s}}=o;if(g==="[")i||(r=Q),i++;else if(g==="]")i?i--:r=null;else if(!i)if(a==="+"&&n&&!n.startsWith("(")){if(s)throw new Error(`Invalid quantifier "${g}"`);let C=-1;if(/^\{\d+\}$/.test(B))e=jL(e,Q+B.length,a,"");else{if(n===")"||n==="]"){const E=n===")"?t:r;if(E===null)throw new Error(`Invalid unmatched "${n}"`);e=`${e.slice(0,E)}(?>${e.slice(E,Q)}${B})${e.slice(Q+g.length)}`}else e=`${e.slice(0,Q-n.length)}(?>${n}${B})${e.slice(Q+g.length)}`;C+=4}_C.lastIndex+=C}else g[0]==="("?A.push(Q):g===")"&&(t=A.length?A.pop():null);n=g}return{pattern:e}}const Fr=String.raw,$L=Fr`\\g<(?[^>&]+)&R=(?[^>]+)>`,dl=Fr`\(\?R=(?[^\)]+)\)|${$L}`,uE=Fr`\(\?<(?![=!])(?[^>]+)>`,Hk=Fr`${uE}|(?\()(?!\?)`,go=new RegExp(Fr`${uE}|${dl}|\(\?|\\?.`,"gsu"),jC="Cannot use multiple overlapping recursions";function AR(e,A){const{hiddenCaptures:t,mode:r}={hiddenCaptures:[],mode:"plugin",...A};let n=A?.captureTransfers??new Map;if(!new RegExp(dl,"su").test(e))return{pattern:e,captureTransfers:n,hiddenCaptures:t};if(r==="plugin"&&va(e,Fr`\(\?\(DEFINE\)`,Gr.DEFAULT))throw new Error("DEFINE groups cannot be used with recursion");const i=[],o=va(e,Fr`\\[1-9]`,Gr.DEFAULT),g=new Map,Q=[];let B=!1,a=0,s=0,C;for(go.lastIndex=0;C=go.exec(e);){const{0:E,groups:{captureName:I,rDepth:c,gRNameOrNum:u,gRDepth:h}}=C;if(E==="[")a++;else if(a)E==="]"&&a--;else if(c){if(JD(c),B)throw new Error(jC);if(o)throw new Error(`${r==="external"?"Backrefs":"Numbered backrefs"} cannot be used with global recursion`);const d=e.slice(0,C.index),f=e.slice(go.lastIndex);if(va(f,dl,Gr.DEFAULT))throw new Error(jC);const m=+c-1;e=UD(d,f,m,!1,t,i,s),n=LD(n,d,m,i.length,0,s);break}else if(u){JD(h);let d=!1;for(const AA of Q)if(AA.name===u||AA.num===+u){if(d=!0,AA.hasRecursedWithin)throw new Error(jC);break}if(!d)throw new Error(Fr`Recursive \g cannot be used outside the referenced group "${r==="external"?u:Fr`\g<${u}&R=${h}>`}"`);const f=g.get(u),m=WL(e,f);if(o&&va(m,Fr`${uE}|\((?!\?)`,Gr.DEFAULT))throw new Error(`${r==="external"?"Backrefs":"Numbered backrefs"} cannot be used with recursion of capturing groups`);const k=e.slice(f,C.index),N=m.slice(k.length+E.length),F=i.length,L=+h-1,v=UD(k,N,L,!0,t,i,s);n=LD(n,k,L,i.length-F,F,s);const O=e.slice(0,f),W=e.slice(f+m.length);e=`${O}${v}${W}`,go.lastIndex+=v.length-E.length-k.length-N.length,Q.forEach(AA=>AA.hasRecursedWithin=!0),B=!0}else if(I)s++,g.set(String(s),go.lastIndex),g.set(I,go.lastIndex),Q.push({num:s,name:I});else if(E[0]==="("){const d=E==="(";d&&(s++,g.set(String(s),go.lastIndex)),Q.push(d?{num:s}:{})}else E===")"&&Q.pop()}return t.push(...i),{pattern:e,captureTransfers:n,hiddenCaptures:t}}function JD(e){const A=`Max depth must be integer between 2 and 100; used ${e}`;if(!/^[1-9]\d*$/.test(e))throw new Error(A);if(e=+e,e<2||e>100)throw new Error(A)}function UD(e,A,t,r,n,i,o){const g=new Set;r&&qk(e+A,uE,({groups:{captureName:B}})=>{g.add(B)},Gr.DEFAULT);const Q=[t,r?g:null,n,i,o];return`${e}${KD(`(?:${e}`,"forward",...Q)}(?:)${KD(`${A})`,"backward",...Q)}${A}`}function KD(e,A,t,r,n,i,o){const Q=a=>A==="forward"?a+2:t-a+2-1;let B="";for(let a=0;a[^>]+)>`,({0:C,groups:{captureName:E,unnamed:I,backref:c}})=>{if(c&&r&&!r.has(c))return C;const u=`_$${s}`;if(I||E){const h=o+i.length+1;return i.push(h),eR(n,h),I?C:`(?<${E}${u}>`}return Fr`\k<${c}${u}>`},Gr.DEFAULT)}return B}function eR(e,A){for(let t=0;t=A&&e[t]++}function LD(e,A,t,r,n,i){if(e.size&&r){let o=0;qk(A,Hk,()=>o++,Gr.DEFAULT);const g=i-o+n,Q=new Map;return e.forEach((B,a)=>{const s=(r-o*t)/t,C=o*t,E=a>g+o?a+r:a,I=[];for(const c of B)if(c<=g)I.push(c);else if(c>g+o+s)I.push(c+r);else if(c<=g+o)for(let u=0;u<=t;u++)I.push(c+o*u);else for(let u=0;u<=t;u++)I.push(c+C+s*u);Q.set(E,I)}),Q}return e}var Mt=String.fromCodePoint,le=String.raw,$n={flagGroups:(()=>{try{new RegExp("(?i:)")}catch{return!1}return!0})(),unicodeSets:(()=>{try{new RegExp("[[]]","v")}catch{return!1}return!0})()};$n.bugFlagVLiteralHyphenIsRange=$n.unicodeSets?(()=>{try{new RegExp(le`[\d\-a]`,"v")}catch{return!0}return!1})():!1;$n.bugNestedClassIgnoresNegation=$n.unicodeSets&&new RegExp("[[^a]]","v").test("a");function Ns(e,{enable:A,disable:t}){return{dotAll:!t?.dotAll&&!!(A?.dotAll||e.dotAll),ignoreCase:!t?.ignoreCase&&!!(A?.ignoreCase||e.ignoreCase)}}function nB(e,A,t){return e.has(A)||e.set(A,t),e.get(A)}function hl(e,A){return RD[e]>=RD[A]}function tR(e,A){if(e==null)throw new Error(A??"Value expected");return e}var RD={ES2025:2025,ES2024:2024,ES2018:2018},rR={auto:"auto",ES2025:"ES2025",ES2024:"ES2024",ES2018:"ES2018"};function Yk(e={}){if({}.toString.call(e)!=="[object Object]")throw new Error("Unexpected options");if(e.target!==void 0&&!rR[e.target])throw new Error(`Unexpected target "${e.target}"`);const A={accuracy:"default",avoidSubclass:!1,flags:"",global:!1,hasIndices:!1,lazyCompileLength:1/0,target:"auto",verbose:!1,...e,rules:{allowOrphanBackrefs:!1,asciiWordBoundaries:!1,captureGroup:!1,recursionLimit:20,singleline:!1,...e.rules}};return A.target==="auto"&&(A.target=$n.flagGroups?"ES2025":$n.unicodeSets?"ES2024":"ES2018"),A}var nR="[ -\r ]",iR=new Set([Mt(304),Mt(305)]),Kn=le`[\p{L}\p{M}\p{N}\p{Pc}]`;function zk(e){if(iR.has(e))return[e];const A=new Set,t=e.toLowerCase(),r=t.toUpperCase(),n=QR.get(t),i=oR.get(t),o=gR.get(t);return[...r].length===1&&A.add(r),o&&A.add(o),n&&A.add(n),A.add(t),i&&A.add(i),[...A]}var au=new Map(`C Other Cc Control cntrl Cf Format Cn Unassigned Co Private_Use Cs Surrogate L Letter LC Cased_Letter Ll Lowercase_Letter Lm Modifier_Letter Lo Other_Letter Lt Titlecase_Letter Lu Uppercase_Letter M Mark Combining_Mark Mc Spacing_Mark Me Enclosing_Mark Mn Nonspacing_Mark N Number Nd Decimal_Number digit Nl Letter_Number No Other_Number P Punctuation punct Pc Connector_Punctuation Pd Dash_Punctuation Pe Close_Punctuation Pf Final_Punctuation Pi Initial_Punctuation Po Other_Punctuation Ps Open_Punctuation S Symbol Sc Currency_Symbol Sk Modifier_Symbol Sm Math_Symbol So Other_Symbol Z Separator Zl Line_Separator Zp Paragraph_Separator Zs Space_Separator ASCII ASCII_Hex_Digit AHex Alphabetic Alpha Any Assigned Bidi_Control Bidi_C Bidi_Mirrored Bidi_M Case_Ignorable CI Cased Changes_When_Casefolded CWCF Changes_When_Casemapped CWCM Changes_When_Lowercased CWL Changes_When_NFKC_Casefolded CWKCF Changes_When_Titlecased CWT Changes_When_Uppercased CWU Dash Default_Ignorable_Code_Point DI Deprecated Dep Diacritic Dia Emoji Emoji_Component EComp Emoji_Modifier EMod Emoji_Modifier_Base EBase Emoji_Presentation EPres Extended_Pictographic ExtPict Extender Ext Grapheme_Base Gr_Base Grapheme_Extend Gr_Ext Hex_Digit Hex IDS_Binary_Operator IDSB IDS_Trinary_Operator IDST ID_Continue IDC ID_Start IDS Ideographic Ideo Join_Control Join_C Logical_Order_Exception LOE Lowercase Lower Math Noncharacter_Code_Point NChar Pattern_Syntax Pat_Syn Pattern_White_Space Pat_WS Quotation_Mark QMark Radical Regional_Indicator RI Sentence_Terminal STerm Soft_Dotted SD Terminal_Punctuation Term Unified_Ideograph UIdeo Uppercase Upper Variation_Selector VS White_Space space XID_Continue XIDC XID_Start XIDS`.split(/\s/).map(e=>[cE(e),e])),oR=new Map([["s",Mt(383)],[Mt(383),"s"]]),gR=new Map([[Mt(223),Mt(7838)],[Mt(107),Mt(8490)],[Mt(229),Mt(8491)],[Mt(969),Mt(8486)]]),QR=new Map([mi(453),mi(456),mi(459),mi(498),...VC(8072,8079),...VC(8088,8095),...VC(8104,8111),mi(8124),mi(8140),mi(8188)]),BR=new Map([["alnum",le`[\p{Alpha}\p{Nd}]`],["alpha",le`\p{Alpha}`],["ascii",le`\p{ASCII}`],["blank",le`[\p{Zs}\t]`],["cntrl",le`\p{Cc}`],["digit",le`\p{Nd}`],["graph",le`[\P{space}&&\P{Cc}&&\P{Cn}&&\P{Cs}]`],["lower",le`\p{Lower}`],["print",le`[[\P{space}&&\P{Cc}&&\P{Cn}&&\P{Cs}]\p{Zs}]`],["punct",le`[\p{P}\p{S}]`],["space",le`\p{space}`],["upper",le`\p{Upper}`],["word",le`[\p{Alpha}\p{M}\p{Nd}\p{Pc}]`],["xdigit",le`\p{AHex}`]]);function aR(e,A){const t=[];for(let r=e;r<=A;r++)t.push(r);return t}function mi(e){const A=Mt(e);return[A.toLowerCase(),A]}function VC(e,A){return aR(e,A).map(t=>mi(t))}var Pk=new Set(["Lower","Lowercase","Upper","Uppercase","Ll","Lowercase_Letter","Lt","Titlecase_Letter","Lu","Uppercase_Letter"]);function sR(e,A){const t={accuracy:"default",asciiWordBoundaries:!1,avoidSubclass:!1,bestEffortTarget:"ES2025",...A};_k(e);const r={accuracy:t.accuracy,asciiWordBoundaries:t.asciiWordBoundaries,avoidSubclass:t.avoidSubclass,flagDirectivesByAlt:new Map,jsGroupNameMap:new Map,minTargetEs2024:hl(t.bestEffortTarget,"ES2024"),passedLookbehind:!1,strategy:null,subroutineRefMap:new Map,supportedGNodes:new Set,digitIsAscii:e.flags.digitIsAscii,spaceIsAscii:e.flags.spaceIsAscii,wordIsAscii:e.flags.wordIsAscii};_Q(e,ER,r);const n={dotAll:e.flags.dotAll,ignoreCase:e.flags.ignoreCase},i={currentFlags:n,prevFlags:null,globalFlags:n,groupOriginByCopy:new Map,groupsByName:new Map,multiplexCapturesToLeftByRef:new Map,openRefs:new Map,reffedNodesByReferencer:new Map,subroutineRefMap:r.subroutineRefMap};_Q(e,CR,i);const o={groupsByName:i.groupsByName,highestOrphanBackref:0,numCapturesToLeft:0,reffedNodesByReferencer:i.reffedNodesByReferencer};return _Q(e,IR,o),e._originMap=i.groupOriginByCopy,e._strategy=r.strategy,e}var ER={AbsenceFunction({node:e,parent:A,replaceWith:t}){const{body:r,kind:n}=e;if(n==="repeater"){const i=jr();i.body[0].body.push(lo({negate:!0,body:r}),cg("Any"));const o=jr();o.body[0].body.push(Lk("greedy",0,1/0,i)),t(lt(o,A),{traverse:!0})}else throw new Error('Unsupported absence function "(?~|"')},Alternative:{enter({node:e,parent:A,key:t},{flagDirectivesByAlt:r}){const n=e.body.filter(i=>i.kind==="flags");for(let i=t+1;i\r\n|${n?le`\p{RGI_Emoji}`:C}|\P{M}\p{M}*)`,{skipPropertyNameValidation:!0}),A))}else if(Q==="hex")t(pi(cg("AHex",{negate:B}),A));else if(Q==="newline")t(lt(Ln(B?`[^ ]`:`(?>\r ?|[ \v\f…\u2028\u2029])`),A));else if(Q==="posix")if(!n&&(a==="graph"||a==="print")){if(r==="strict")throw new Error(`POSIX class "${a}" requires min target ES2024 or non-strict accuracy`);let s={graph:"!-~",print:" -~"}[a];B&&(s=`\0-${Mt(s.codePointAt(0)-1)}${Mt(s.codePointAt(2)+1)}-􏿿`),t(lt(Ln(`[${s}]`),A))}else t(lt(XC(Ln(BR.get(a)),B),A));else if(Q==="property")au.has(cE(a))||(e.key="sc");else if(Q==="space")t(pi(cg("space",{negate:B}),A));else if(Q==="word")t(lt(XC(Ln(Kn),B),A));else throw new Error(`Unexpected character set kind "${Q}"`)},Directive({node:e,parent:A,root:t,remove:r,replaceWith:n,removeAllPrevSiblings:i,removeAllNextSiblings:o}){const{kind:g,flags:Q}=e;if(g==="flags")if(!Q.enable&&!Q.disable)r();else{const B=jr({flags:Q});B.body[0].body=o(),n(lt(B,A),{traverse:!0})}else if(g==="keep"){const B=t.body[0],s=t.body.length===1&&Jk(B,{type:"Group"})&&B.body[0].body.length===1?B.body[0]:t;if(A.parent!==s||s.body.length>1)throw new Error(le`Uses "\K" in a way that's unsupported`);const C=lo({behind:!0});C.body[0].body=i(),n(lt(C,A))}else throw new Error(`Unexpected directive kind "${g}"`)},Flags({node:e,parent:A}){if(e.posixIsAscii)throw new Error('Unsupported flag "P"');if(e.textSegmentMode==="word")throw new Error('Unsupported flag "y{w}"');["digitIsAscii","extended","posixIsAscii","spaceIsAscii","wordIsAscii","textSegmentMode"].forEach(t=>delete e[t]),Object.assign(e,{global:!1,hasIndices:!1,multiline:!1,sticky:e.sticky??!1}),A.options={disable:{x:!0,n:!0},force:{v:!0}}},Group({node:e}){if(!e.flags)return;const{enable:A,disable:t}=e.flags;A?.extended&&delete A.extended,t?.extended&&delete t.extended,A?.dotAll&&t?.dotAll&&delete A.dotAll,A?.ignoreCase&&t?.ignoreCase&&delete A.ignoreCase,A&&!Object.keys(A).length&&delete e.flags.enable,t&&!Object.keys(t).length&&delete e.flags.disable,!e.flags.enable&&!e.flags.disable&&delete e.flags},LookaroundAssertion({node:e},A){const{kind:t}=e;t==="lookbehind"&&(A.passedLookbehind=!0)},NamedCallout({node:e,parent:A,replaceWith:t}){const{kind:r}=e;if(r==="fail")t(lt(lo({negate:!0}),A));else throw new Error(`Unsupported named callout "(*${r.toUpperCase()}"`)},Quantifier({node:e}){if(e.body.type==="Quantifier"){const A=jr();A.body[0].body.push(e.body),e.body=lt(A,e)}},Regex:{enter({node:e},{supportedGNodes:A}){const t=[];let r=!1,n=!1;for(const i of e.body)if(i.body.length===1&&i.body[0].kind==="search_start")i.body.pop();else{const o=Zk(i.body);o?(r=!0,Array.isArray(o)?t.push(...o):t.push(o)):n=!0}r&&!n&&t.forEach(i=>A.add(i))},exit(e,{accuracy:A,passedLookbehind:t,strategy:r}){if(A==="strict"&&t&&r)throw new Error(le`Uses "\G" in a way that requires non-strict accuracy`)}},Subroutine({node:e},{jsGroupNameMap:A}){let{ref:t}=e;typeof t=="string"&&!ZC(t)&&(t=WC(t,A),e.ref=t)}},CR={Backreference({node:e},{multiplexCapturesToLeftByRef:A,reffedNodesByReferencer:t}){const{orphan:r,ref:n}=e;r||t.set(e,[...A.get(n).map(({node:i})=>i)])},CapturingGroup:{enter({node:e,parent:A,replaceWith:t,skip:r},{groupOriginByCopy:n,groupsByName:i,multiplexCapturesToLeftByRef:o,openRefs:g,reffedNodesByReferencer:Q}){const B=n.get(e);if(B&&g.has(e.number)){const s=pi(OD(e.number),A);Q.set(s,g.get(e.number)),t(s);return}g.set(e.number,e),o.set(e.number,[]),e.name&&nB(o,e.name,[]);const a=o.get(e.name??e.number);for(let s=0;sC.type==="Group"&&!!C.flags)),s=a?Ns(r.globalFlags,a):r.globalFlags;lR(s,r.currentFlags)||(B=jr({flags:dR(s)}),B.body[0].body.push(Q))}t(lt(B,A),{traverse:!g})}},IR={Backreference({node:e,parent:A,replaceWith:t},r){if(e.orphan){r.highestOrphanBackref=Math.max(r.highestOrphanBackref,e.ref);return}const i=r.reffedNodesByReferencer.get(e).filter(o=>cR(o,e));if(!i.length)t(lt(lo({negate:!0}),A));else if(i.length>1){const o=jr({atomic:!0,body:i.reverse().map(g=>Fo({body:[cl(g.number)]}))});t(lt(o,A))}else e.ref=i[0].number},CapturingGroup({node:e},A){e.number=++A.numCapturesToLeft,e.name&&A.groupsByName.get(e.name).get(e).hasDuplicateNameToRemove&&delete e.name},Regex:{exit({node:e},A){const t=Math.max(A.highestOrphanBackref-A.numCapturesToLeft,0);for(let r=0;r{A.forEach(n=>{r.enable?.[n]&&(delete t.disable[n],t.enable[n]=!0),r.disable?.[n]&&(t.disable[n]=!0)})}),Object.keys(t.enable).length||delete t.enable,Object.keys(t.disable).length||delete t.disable,t.enable||t.disable?t:null}function dR({dotAll:e,ignoreCase:A}){const t={};return(e||A)&&(t.enable={},e&&(t.enable.dotAll=!0),A&&(t.enable.ignoreCase=!0)),(!e||!A)&&(t.disable={},!e&&(t.disable.dotAll=!0),!A&&(t.disable.ignoreCase=!0)),t}function Wk(e){if(!e)throw new Error("Node expected");const{body:A}=e;return Array.isArray(A)?A:A?[A]:null}function Zk(e){const A=e.find(t=>t.kind==="search_start"||fR(t,{negate:!1})||!hR(t));if(!A)return null;if(A.kind==="search_start")return A;if(A.type==="LookaroundAssertion")return A.body[0].body[0];if(A.type==="CapturingGroup"||A.type==="Group"){const t=[];for(const r of A.body){const n=Zk(r.body);if(!n)return null;Array.isArray(n)?t.push(...n):t.push(n)}return t}return null}function Xk(e,A){const t=Wk(e)??[];for(const r of t)if(r===A||Xk(r,A))return!0;return!1}function hR({type:e}){return e==="Assertion"||e==="Directive"||e==="LookaroundAssertion"}function DR(e){const A=["Character","CharacterClass","CharacterSet"];return A.includes(e.type)||e.type==="Quantifier"&&e.min&&A.includes(e.body.type)}function fR(e,A){const t={negate:null,...A};return e.type==="LookaroundAssertion"&&(t.negate===null||e.negate===t.negate)&&e.body.length===1&&Jk(e.body[0],{type:"Assertion",kind:"search_start"})}function ZC(e){return/^[$_\p{IDS}][$\u200C\u200D\p{IDC}]*$/u.test(e)}function Ln(e,A){const r=Uk(e,{...A,unicodePropertyMap:au}).body;return r.length>1||r[0].body.length>1?jr({body:r}):r[0].body[0]}function XC(e,A){return e.negate=A,e}function pi(e,A){return e.parent=A,e}function lt(e,A){return _k(e),e.parent=A,e}function wR(e,A){const t=Yk(A),r=hl(t.target,"ES2024"),n=hl(t.target,"ES2025"),i=t.rules.recursionLimit;if(!Number.isInteger(i)||i<2||i>20)throw new Error("Invalid recursionLimit; use 2-20");let o=null,g=null;if(!n){const E=[e.flags.ignoreCase];_Q(e,mR,{getCurrentModI:()=>E.at(-1),popModI(){E.pop()},pushModI(I){E.push(I)},setHasCasedChar(){E.at(-1)?o=!0:g=!0}})}const Q={dotAll:e.flags.dotAll,ignoreCase:!!((e.flags.ignoreCase||o)&&!g)};let B=e;const a={accuracy:t.accuracy,appliedGlobalFlags:Q,captureMap:new Map,currentFlags:{dotAll:e.flags.dotAll,ignoreCase:e.flags.ignoreCase},inCharClass:!1,lastNode:B,originMap:e._originMap,recursionLimit:i,useAppliedIgnoreCase:!!(!n&&o&&g),useFlagMods:n,useFlagV:r,verbose:t.verbose};function s(E){return a.lastNode=B,B=E,tR(pR[E.type],`Unexpected node type "${E.type}"`)(E,a,s)}const C={pattern:e.body.map(s).join("|"),flags:s(e.flags),options:{...e.options}};return r||(delete C.options.force.v,C.options.disable.v=!0,C.options.unicodeSetsPlugin=null),C._captureTransfers=new Map,C._hiddenCaptures=[],a.captureMap.forEach((E,I)=>{E.hidden&&C._hiddenCaptures.push(I),E.transferTo&&nB(C._captureTransfers,E.transferTo,[]).push(I)}),C}var mR={"*":{enter({node:e},A){if(TD(e)){const t=A.getCurrentModI();A.pushModI(e.flags?Ns({ignoreCase:t},e.flags).ignoreCase:t)}},exit({node:e},A){TD(e)&&A.popModI()}},Backreference(e,A){A.setHasCasedChar()},Character({node:e},A){su(Mt(e.value))&&A.setHasCasedChar()},CharacterClassRange({node:e,skip:A},t){A(),$k(e,{firstOnly:!0}).length&&t.setHasCasedChar()},CharacterSet({node:e},A){e.kind==="property"&&Pk.has(e.value)&&A.setHasCasedChar()}},pR={Alternative({body:e},A,t){return e.map(t).join("")},Assertion({kind:e,negate:A}){if(e==="string_end")return"$";if(e==="string_start")return"^";if(e==="word_boundary")return A?le`\B`:le`\b`;throw new Error(`Unexpected assertion kind "${e}"`)},Backreference({ref:e},A){if(typeof e!="number")throw new Error("Unexpected named backref in transformed AST");if(!A.useFlagMods&&A.accuracy==="strict"&&A.currentFlags.ignoreCase&&!A.captureMap.get(e).ignoreCase)throw new Error("Use of case-insensitive backref to case-sensitive group requires target ES2025 or non-strict accuracy");return"\\"+e},CapturingGroup(e,A,t){const{body:r,name:n,number:i}=e,o={ignoreCase:A.currentFlags.ignoreCase},g=A.originMap.get(e);return g&&(o.hidden=!0,i>g.number&&(o.transferTo=g.number)),A.captureMap.set(i,o),`(${n?`?<${n}>`:""}${r.map(t).join("|")})`},Character({value:e},A){const t=Mt(e),r=ig(e,{escDigit:A.lastNode.type==="Backreference",inCharClass:A.inCharClass,useFlagV:A.useFlagV});if(r!==t)return r;if(A.useAppliedIgnoreCase&&A.currentFlags.ignoreCase&&su(t)){const n=zk(t);return A.inCharClass?n.join(""):n.length>1?`[${n.join("")}]`:n[0]}return t},CharacterClass(e,A,t){const{kind:r,negate:n,parent:i}=e;let{body:o}=e;if(r==="intersection"&&!A.useFlagV)throw new Error("Use of character class intersection requires min target ES2024");$n.bugFlagVLiteralHyphenIsRange&&A.useFlagV&&o.some(HD)&&(o=[lE(45),...o.filter(B=>!HD(B))]);const g=()=>`[${n?"^":""}${o.map(t).join(r==="intersection"?"&&":"")}]`;if(!A.inCharClass){if((!A.useFlagV||$n.bugNestedClassIgnoresNegation)&&!n){const a=o.filter(s=>s.type==="CharacterClass"&&s.kind==="union"&&s.negate);if(a.length){const s=jr(),C=s.body[0];return s.parent=i,C.parent=s,o=o.filter(E=>!a.includes(E)),e.body=o,o.length?(e.parent=C,C.body.push(e)):s.body.pop(),a.forEach(E=>{const I=Fo({body:[E]});E.parent=I,I.parent=s,s.body.push(I)}),t(s)}}A.inCharClass=!0;const B=g();return A.inCharClass=!1,B}const Q=o[0];if(r==="union"&&!n&&Q&&((!A.useFlagV||!A.verbose)&&i.kind==="union"&&!($n.bugFlagVLiteralHyphenIsRange&&A.useFlagV)||!A.verbose&&i.kind==="intersection"&&o.length===1&&Q.type!=="CharacterClassRange"))return o.map(t).join("");if(!A.useFlagV&&i.type==="CharacterClass")throw new Error("Uses nested character class in a way that requires min target ES2024");return g()},CharacterClassRange(e,A){const t=e.min.value,r=e.max.value,n={escDigit:!1,inCharClass:!0,useFlagV:A.useFlagV},i=ig(t,n),o=ig(r,n),g=new Set;if(A.useAppliedIgnoreCase&&A.currentFlags.ignoreCase){const Q=$k(e);vR(Q).forEach(a=>{g.add(Array.isArray(a)?`${ig(a[0],n)}-${ig(a[1],n)}`:ig(a,n))})}return`${i}-${o}${[...g].join("")}`},CharacterSet({kind:e,negate:A,value:t,key:r},n){if(e==="dot")return n.currentFlags.dotAll?n.appliedGlobalFlags.dotAll||n.useFlagMods?".":"[^]":le`[^\n]`;if(e==="digit")return A?le`\D`:le`\d`;if(e==="property"){if(n.useAppliedIgnoreCase&&n.currentFlags.ignoreCase&&Pk.has(t))throw new Error(`Unicode property "${t}" can't be case-insensitive when other chars have specific case`);return`${A?le`\P`:le`\p`}{${r?`${r}=`:""}${t}}`}if(e==="word")return A?le`\W`:le`\w`;throw new Error(`Unexpected character set kind "${e}"`)},Flags(e,A){return(A.appliedGlobalFlags.ignoreCase?"i":"")+(e.dotAll?"s":"")+(e.sticky?"y":"")},Group({atomic:e,body:A,flags:t,parent:r},n,i){const o=n.currentFlags;t&&(n.currentFlags=Ns(o,t));const g=A.map(i).join("|"),Q=!n.verbose&&A.length===1&&r.type!=="Quantifier"&&!e&&(!n.useFlagMods||!t)?g:`(?${bR(e,t,n.useFlagMods)}${g})`;return n.currentFlags=o,Q},LookaroundAssertion({body:e,kind:A,negate:t},r,n){return`(?${`${A==="lookahead"?"":"<"}${t?"!":"="}`}${e.map(n).join("|")})`},Quantifier(e,A,t){return t(e.body)+FR(e)},Subroutine({isRecursive:e,ref:A},t){if(!e)throw new Error("Unexpected non-recursive subroutine in transformed AST");const r=t.recursionLimit;return A===0?`(?R=${r})`:le`\g<${A}&R=${r}>`}},kR=new Set(["$","(",")","*","+",".","?","[","\\","]","^","{","|","}"]),yR=new Set(["-","\\","]","^","["]),MR=new Set(["(",")","-","/","[","\\","]","^","{","|","}","!","#","$","%","&","*","+",",",".",":",";","<","=",">","?","@","`","~"]),qD=new Map([[9,le`\t`],[10,le`\n`],[11,le`\v`],[12,le`\f`],[13,le`\r`],[8232,le`\u2028`],[8233,le`\u2029`],[65279,le`\uFEFF`]]),NR=/^\p{Cased}$/u;function su(e){return NR.test(e)}function $k(e,A){const t=!!A?.firstOnly,r=e.min.value,n=e.max.value,i=[];if(r<65&&(n===65535||n>=131071)||r===65536&&n>=131071)return i;for(let o=r;o<=n;o++){const g=Mt(o);if(!su(g))continue;const Q=zk(g).filter(B=>{const a=B.codePointAt(0);return an});if(Q.length&&(i.push(...Q),t))break}return i}function ig(e,{escDigit:A,inCharClass:t,useFlagV:r}){if(qD.has(e))return qD.get(e);if(e<32||e>126&&e<160||e>262143||A&&xR(e))return e>255?`\\u{${e.toString(16).toUpperCase()}}`:`\\x${e.toString(16).toUpperCase().padStart(2,"0")}`;const n=t?r?MR:yR:kR,i=Mt(e);return(n.has(i)?"\\":"")+i}function vR(e){const A=e.map(n=>n.codePointAt(0)).sort((n,i)=>n-i),t=[];let r=null;for(let n=0;n";let r="";if(A&&t){const{enable:n,disable:i}=A;r=(n?.ignoreCase?"i":"")+(n?.dotAll?"s":"")+(i?"-":"")+(i?.ignoreCase?"i":"")+(i?.dotAll?"s":"")}return`${r}:`}function FR({kind:e,max:A,min:t}){let r;return!t&&A===1?r="?":!t&&A===1/0?r="*":t===1&&A===1/0?r="+":t===A?r=`{${t}}`:r=`{${t},${A===1/0?"":A}}`,r+{greedy:"",lazy:"?",possessive:"+"}[e]}function TD({type:e}){return e==="CapturingGroup"||e==="Group"||e==="LookaroundAssertion"}function xR(e){return e>47&&e<58}function HD({type:e,value:A}){return e==="Character"&&A===45}var GR=class Dl extends RegExp{#e=new Map;#A=null;#r;#t=null;#n=null;rawOptions={};get source(){return this.#r||"(?:)"}constructor(A,t,r){const n=!!r?.lazyCompile;if(A instanceof RegExp){if(r)throw new Error("Cannot provide options when copying a regexp");const i=A;super(i,t),this.#r=i.source,i instanceof Dl&&(this.#e=i.#e,this.#t=i.#t,this.#n=i.#n,this.rawOptions=i.rawOptions)}else{const i={hiddenCaptures:[],strategy:null,transfers:[],...r};super(n?"":A,t),this.#r=A,this.#e=JR(i.hiddenCaptures,i.transfers),this.#n=i.strategy,this.rawOptions=r??{}}n||(this.#A=this)}exec(A){if(!this.#A){const{lazyCompile:n,...i}=this.rawOptions;this.#A=new Dl(this.#r,this.flags,i)}const t=this.global||this.sticky,r=this.lastIndex;if(this.#n==="clip_search"&&t&&r){this.lastIndex=0;const n=this.#i(A.slice(r));return n&&(SR(n,r,A,this.hasIndices),this.lastIndex+=r),n}return this.#i(A)}#i(A){this.#A.lastIndex=this.lastIndex;const t=super.exec.call(this.#A,A);if(this.lastIndex=this.#A.lastIndex,!t||!this.#e.size)return t;const r=[...t];t.length=1;let n;this.hasIndices&&(n=[...t.indices],t.indices.length=1);const i=[0];for(let o=1;o{const g=i[o];g&&(i[o]=[g[0]+A,g[1]+A])})}}function JR(e,A){const t=new Map;for(const r of e)t.set(r,{hidden:!0});for(const[r,n]of A)for(const i of n)nB(t,i,{}).transferTo=r;return t}function UR(e){const A=/(?\((?:\?<(?![=!])(?[^>]+)>|(?!\?)))|\\?./gsu,t=new Map;let r=0,n=0,i;for(;i=A.exec(e);){const{0:o,groups:{capture:g,name:Q}}=i;o==="["?r++:r?o==="]"&&r--:g&&(n++,Q&&t.set(n,Q))}return t}function KR(e,A){const t=LR(e,A);return t.options?new GR(t.pattern,t.flags,t.options):new RegExp(t.pattern,t.flags)}function LR(e,A){const t=Yk(A),r=Uk(e,{flags:t.flags,normalizeUnknownPropertyNames:!0,rules:{captureGroup:t.rules.captureGroup,singleline:t.rules.singleline},skipBackrefValidation:t.rules.allowOrphanBackrefs,unicodePropertyMap:au}),n=sR(r,{accuracy:t.accuracy,asciiWordBoundaries:t.rules.asciiWordBoundaries,avoidSubclass:t.avoidSubclass,bestEffortTarget:t.target}),i=wR(n,t),o=AR(i.pattern,{captureTransfers:i._captureTransfers,hiddenCaptures:i._hiddenCaptures,mode:"external"}),g=XL(o.pattern),Q=ZL(g.pattern,{captureTransfers:o.captureTransfers,hiddenCaptures:o.hiddenCaptures}),B={pattern:Q.pattern,flags:`${t.hasIndices?"d":""}${t.global?"g":""}${i.flags}${i.options.disable.v?"u":"v"}`};if(t.avoidSubclass){if(t.lazyCompileLength!==1/0)throw new Error("Lazy compilation requires subclass")}else{const a=Q.hiddenCaptures.sort((I,c)=>I-c),s=Array.from(Q.captureTransfers),C=n._strategy,E=B.pattern.length>=t.lazyCompileLength;(a.length||s.length||C||E)&&(B.options={...a.length&&{hiddenCaptures:a},...s.length&&{transfers:s},...C&&{strategy:C},...E&&{lazyCompile:E}})}return B}function qt(e){const A=ye();return{provider:t=>{const r=e.init(t),n=S(()=>{const i=r.ready;return i===void 0||(typeof i=="function"?i():i)});return l(Y,{get when(){return n()},get children(){return l(A.Provider,{value:r,get children(){return t.children}})}})},use(){const t=pe(A);if(!t)throw new Error(`${e.name} context must be used within a context provider`);return t}}}const vs="diffs-container",RR=/(?=^From [a-f0-9]+ .+$)/m,$C=/(?=^diff --git)/gm,YD=/(?=^---\s+\S)/gm,OR=/(?=^@@ )/gm,qR=/^@@ -(\d+)(?:,(\d+))? \+(\d+)(?:,(\d+))? @@(?: (.*))?/m,fl=/(?<=\n)/,TR=/^(---|\+\+\+)\s+([^\t\r\n]+)/,HR=/^(---|\+\+\+)\s+[ab]\/([^\t\r\n]+)/,YR=/^diff --git (?:"a\/(.+?)"|a\/(.+?)) (?:"b\/(.+?)"|b\/(.+?))$/,zR=/^index (?:[0-9a-f]+)\.\.(?:[0-9a-f]+)(?: (\d+))?/,Eu="header-metadata",Vt={dark:"pierre-dark",light:"pierre-light"},Cu="data-unsafe-css";function PR(e,A){return e?.start===A?.start&&e?.end===A?.end&&e?.side===A?.side&&e?.endSide===A?.endSide}var Ay=class{pre;selectedRange=null;renderedSelectionRange;anchor;_queuedRender;constructor(e={}){this.options=e}setOptions(e){this.options={...this.options,...e},this.removeEventListeners(),this.options.enableLineSelection===!0&&this.attachEventListeners()}cleanUp(){this.removeEventListeners(),this._queuedRender!=null&&(cancelAnimationFrame(this._queuedRender),this._queuedRender=void 0),this.pre!=null&&delete this.pre.dataset.interactiveLineNumbers,this.pre=void 0}setup(e){this.setDirty(),this.pre!==e&&this.cleanUp(),this.pre=e;const{enableLineSelection:A=!1}=this.options;A?(this.pre.dataset.interactiveLineNumbers="",this.attachEventListeners()):(this.removeEventListeners(),delete this.pre.dataset.interactiveLineNumbers),this.setSelection(this.selectedRange)}setDirty(){this.renderedSelectionRange=void 0}isDirty(){return this.renderedSelectionRange===void 0}setSelection(e){const A=!(e===this.selectedRange||PR(e??void 0,this.selectedRange??void 0));!this.isDirty()&&!A||(this.selectedRange=e,this.renderSelection(),A&&this.notifySelectionChange())}getSelection(){return this.selectedRange}attachEventListeners(){this.pre!=null&&(this.removeEventListeners(),this.pre.addEventListener("mousedown",this.handleMouseDown))}removeEventListeners(){this.pre!=null&&(this.pre.removeEventListener("mousedown",this.handleMouseDown),document.removeEventListener("mousemove",this.handleMouseMove),document.removeEventListener("mouseup",this.handleMouseUp))}handleMouseDown=e=>{const A=e.button===0?this.getMouseEventDataForPath(e.composedPath(),"click"):void 0;if(A==null)return;e.preventDefault();const{lineNumber:t,eventSide:r,lineIndex:n}=A;if(e.shiftKey&&this.selectedRange!=null){const i=this.deriveRowRangeFromDOM(this.selectedRange,this.pre?.dataset.type==="split");if(i==null)return;const o=i.start<=i.end?n>=i.start:n<=i.end;this.anchor={line:o?this.selectedRange.start:this.selectedRange.end,side:(o?this.selectedRange.side:this.selectedRange.endSide??this.selectedRange.side)??"additions"},this.updateSelection(t,r),this.notifySelectionStart(this.selectedRange)}else{if(this.selectedRange?.start===t&&this.selectedRange?.end===t){this.updateSelection(null),this.notifySelectionEnd(null),this.notifySelectionChange();return}this.selectedRange=null,this.anchor={line:t,side:r},this.updateSelection(t,r),this.notifySelectionStart(this.selectedRange)}document.addEventListener("mousemove",this.handleMouseMove),document.addEventListener("mouseup",this.handleMouseUp)};handleMouseMove=e=>{const A=this.getMouseEventDataForPath(e.composedPath(),"move");if(A==null||this.anchor==null)return;const{lineNumber:t,eventSide:r}=A;this.updateSelection(t,r)};handleMouseUp=()=>{this.anchor=void 0,document.removeEventListener("mousemove",this.handleMouseMove),document.removeEventListener("mouseup",this.handleMouseUp),this.notifySelectionEnd(this.selectedRange),this.notifySelectionChange()};updateSelection(e,A){if(e==null)this.selectedRange=null;else{const t=this.anchor?.side??A;this.selectedRange={start:this.anchor?.line??e,end:e,side:t,endSide:t!==A?A:void 0}}this._queuedRender??=requestAnimationFrame(this.renderSelection)}renderSelection=()=>{if(this._queuedRender!=null&&(cancelAnimationFrame(this._queuedRender),this._queuedRender=void 0),this.pre==null||this.renderedSelectionRange===this.selectedRange)return;const e=this.pre.querySelectorAll("[data-selected-line]");for(const g of e)g.removeAttribute("data-selected-line");if(this.renderedSelectionRange=this.selectedRange,this.selectedRange==null)return;const A=this.pre.querySelectorAll("[data-code]");if(A.length===0)return;if(A.length>2)throw console.error(A),new Error("LineSelectionManager.applySelectionToDOM: Somehow there are more than 2 code elements...");const t=this.pre.dataset.type==="split",r=this.deriveRowRangeFromDOM(this.selectedRange,t);if(r==null)throw console.error({rowRange:r,selectedRange:this.selectedRange}),new Error("LineSelectionManager.renderSelection: No valid rowRange");const n=r.start===r.end,i=Math.min(r.start,r.end),o=Math.max(r.start,r.end);for(const g of A)for(const Q of g.children){if(!(Q instanceof HTMLElement))continue;const B=this.getLineIndex(Q,t);if((B??0)>o)break;if(B==null||BparseInt(r)).filter(r=>!Number.isNaN(r));if(A&&t.length===2)return t[1];if(!A)return t[0]}getLineSideFromElement(e){if(e.dataset.lineType==="change-deletion")return"deletions";if(e.dataset.lineType==="change-addition")return"additions";const A=e.closest("[data-code]");return A instanceof HTMLElement&&A.hasAttribute("data-deletions")?"deletions":"additions"}};function bs({enableLineSelection:e,onLineSelected:A,onLineSelectionStart:t,onLineSelectionEnd:r}){return{enableLineSelection:e,onLineSelected:A,onLineSelectionStart:t,onLineSelectionEnd:r}}function AI(e,A){return e==null?!1:A==="file"?e.type==="line":e.type==="diff-line"}function _R(e){return e?.type==="line-info"}var ey=class{hoveredLine;pre;hoverSlot;constructor(e,A){this.mode=e,this.options=A}setOptions(e){this.options=e}cleanUp(){this.pre?.removeEventListener("click",this.handleMouseClick),this.pre?.removeEventListener("mousemove",this.handleMouseMove),this.pre?.removeEventListener("mouseout",this.handleMouseLeave),delete this.pre?.dataset.interactiveLines,delete this.pre?.dataset.interactiveLineNumbers,this.pre=void 0}setup(e){const{__debugMouseEvents:A,onLineClick:t,onLineNumberClick:r,onLineEnter:n,onLineLeave:i,onHunkExpand:o,enableHoverUtility:g=!1}=this.options;if(this.cleanUp(),this.pre=e,g&&this.hoverSlot==null){this.hoverSlot=document.createElement("div"),this.hoverSlot.dataset.hoverSlot="";const Q=document.createElement("slot");Q.name="hover-slot",this.hoverSlot.appendChild(Q)}else!g&&this.hoverSlot!=null&&(this.hoverSlot.parentNode?.removeChild(this.hoverSlot),this.hoverSlot=void 0);(t!=null||r!=null||o!=null)&&(e.addEventListener("click",this.handleMouseClick),t!=null?e.dataset.interactiveLines="":r!=null&&(e.dataset.interactiveLineNumbers=""),Rt(A,"click","FileDiff.DEBUG.attachEventListeners: Attaching click events for:",(()=>{const Q=[];return(A==="both"||A==="click")&&(t!=null&&Q.push("onLineClick"),r!=null&&Q.push("onLineNumberClick"),o!=null&&Q.push("expandable hunk separators")),Q})())),(n!=null||i!=null||g)&&(e.addEventListener("mousemove",this.handleMouseMove),Rt(A,"move","FileDiff.DEBUG.attachEventListeners: Attaching mouse move event"),e.addEventListener("mouseleave",this.handleMouseLeave),Rt(A,"move","FileDiff.DEBUG.attachEventListeners: Attaching mouse leave event"))}getHoveredLine=()=>{if(this.hoveredLine!=null){if(this.mode==="diff"&&this.hoveredLine.type==="diff-line")return{lineNumber:this.hoveredLine.lineNumber,side:this.hoveredLine.annotationSide};if(this.mode==="file"&&this.hoveredLine.type==="line")return{lineNumber:this.hoveredLine.lineNumber}}};handleMouseClick=e=>{Rt(this.options.__debugMouseEvents,"click","FileDiff.DEBUG.handleMouseClick:",e),this.handleMouseEvent({eventType:"click",event:e})};handleMouseMove=e=>{Rt(this.options.__debugMouseEvents,"move","FileDiff.DEBUG.handleMouseMove:",e),this.handleMouseEvent({eventType:"move",event:e})};handleMouseLeave=e=>{const{__debugMouseEvents:A}=this.options;if(Rt(A,"move","FileDiff.DEBUG.handleMouseLeave: no event"),this.hoveredLine==null){Rt(A,"move","FileDiff.DEBUG.handleMouseLeave: returned early, no .hoveredLine");return}this.hoverSlot?.parentElement?.removeChild(this.hoverSlot),this.options.onLineLeave?.({...this.hoveredLine,event:e}),this.hoveredLine=void 0};handleMouseEvent({eventType:e,event:A}){const{__debugMouseEvents:t}=this.options,r=A.composedPath();Rt(t,e,"FileDiff.DEBUG.handleMouseEvent:",{eventType:e,composedPath:r});const n=this.getLineData(r);Rt(t,e,"FileDiff.DEBUG.handleMouseEvent: getLineData result:",n);const{onLineClick:i,onLineNumberClick:o,onLineEnter:g,onLineLeave:Q,onHunkExpand:B}=this.options;switch(e){case"move":if(AI(n,this.mode)&&this.hoveredLine?.lineElement===n.lineElement){Rt(t,"move","FileDiff.DEBUG.handleMouseEvent: switch, 'move', returned early because same line");break}this.hoveredLine!=null&&(Rt(t,"move","FileDiff.DEBUG.handleMouseEvent: switch, 'move', clearing an existing hovered line and firing onLineLeave"),this.hoverSlot?.parentElement?.removeChild(this.hoverSlot),Q?.({...this.hoveredLine,event:A}),this.hoveredLine=void 0),AI(n,this.mode)&&(Rt(t,"move","FileDiff.DEBUG.handleMouseEvent: switch, 'move', setting up a new hoveredLine and firing onLineEnter"),this.hoveredLine=n,this.hoverSlot!=null&&n.numberElement?.appendChild(this.hoverSlot),g?.({...this.hoveredLine,event:A}));break;case"click":if(Rt(t,"click","FileDiff.DEBUG.handleMouseEvent: switch, 'click', with data:",n),n==null)break;if(_R(n)&&B!=null){Rt(t,"click","FileDiff.DEBUG.handleMouseEvent: switch, 'click', expanding a hunk"),B(n.hunkIndex,n.direction);break}AI(n,this.mode)&&(o!=null&&n.numberColumn?(Rt(t,"click","FileDiff.DEBUG.handleMouseEvent: switch, 'click', firing 'onLineNumberClick'"),o({...n,event:A})):i!=null?(Rt(t,"click","FileDiff.DEBUG.handleMouseEvent: switch, 'click', firing 'onLineClick'"),i({...n,event:A})):Rt(t,"click","FileDiff.DEBUG.handleMouseEvent: switch, 'click', fell through, no event to fire"));break}}getLineData(e){let A=!1;const t=e.find(o=>o instanceof HTMLElement?(A=A||"columnNumber"in o.dataset,"line"in o.dataset||"expandIndex"in o.dataset):!1);if(!(t instanceof HTMLElement))return;if(t.dataset.expandIndex!=null){const o=parseInt(t.dataset.expandIndex);if(isNaN(o))return;let g;for(const Q of e)if(Q===t||Q instanceof HTMLElement&&(g=g??("expandUp"in Q.dataset?"up":void 0)??("expandDown"in Q.dataset?"down":void 0)??("expandBoth"in Q.dataset?"both":void 0),g!=null))break;return g!=null?{type:"line-info",hunkIndex:o,direction:g}:void 0}const r=parseInt(t.dataset.line??"");if(isNaN(r))return;const n=t.dataset.lineType;if(n!=="context"&&n!=="context-expanded"&&n!=="change-deletion"&&n!=="change-addition")return;const i=(()=>{const o=t.children[0];return o instanceof HTMLElement&&o.dataset.columnNumber!=null?o:void 0})();return this.mode==="file"?{type:"line",lineElement:t,lineNumber:r,numberElement:i,numberColumn:A}:{type:"diff-line",annotationSide:(()=>{if(n==="change-deletion")return"deletions";if(n==="change-addition")return"additions";const o=t.closest("[data-code]");return o instanceof HTMLElement&&"deletions"in o.dataset?"deletions":"additions"})(),lineType:n,lineElement:t,numberElement:i,lineNumber:r,numberColumn:A}}};function Rt(e="none",A,...t){switch(e){case"none":return;case"both":break;case"click":if(A!=="click")return;break;case"move":if(A!=="move")return;break}console.log(...t)}function Fs({onLineClick:e,onLineNumberClick:A,onLineEnter:t,onLineLeave:r,enableHoverUtility:n,__debugMouseEvents:i},o){return{onLineClick:e,onLineNumberClick:A,onLineEnter:t,onLineLeave:r,enableHoverUtility:n,__debugMouseEvents:i,onHunkExpand:o}}var ty=class{observedNodes=new Map;cleanUp(){this.resizeObserver?.disconnect(),this.observedNodes.clear()}resizeObserver;setup(e){this.cleanUp();const A=e.querySelectorAll('[data-line-annotation*=","]');this.resizeObserver??=new ResizeObserver(this.handleResizeObserver);const t=e.querySelectorAll("code");for(const n of t){let i=n.querySelector("[data-column-number]");i instanceof HTMLElement||(i=null);const o={type:"code",codeElement:n,numberElement:i,codeWidth:"auto",numberWidth:0};this.observedNodes.set(n,o),this.resizeObserver.observe(n),i!=null&&(this.observedNodes.set(i,o),this.resizeObserver.observe(i))}if(t.length<=1)return;const r=new Map;for(const n of A){if(!(n instanceof HTMLElement))continue;const{lineAnnotation:i=""}=n.dataset;if(!/^\d+,\d+$/.test(i)){console.error("DiffFileRenderer.setupResizeObserver: Invalid element or annotation",{lineAnnotation:i,element:n});continue}let o=r.get(i);o==null&&(o=[],r.set(i,o)),o.push(n)}for(const[n,i]of r){if(i.length!==2){console.error("DiffFileRenderer.setupResizeObserver: Bad Pair",n,i);continue}const[o,g]=i,Q=o.firstElementChild,B=g.firstElementChild;if(!(o instanceof HTMLElement)||!(g instanceof HTMLElement)||!(Q instanceof HTMLElement)||!(B instanceof HTMLElement))continue;const a={type:"annotations",column1:{container:o,child:Q,childHeight:0},column2:{container:g,child:B,childHeight:0},currentHeight:"auto"};this.observedNodes.set(Q,a),this.observedNodes.set(B,a),this.resizeObserver.observe(Q),this.resizeObserver.observe(B)}}handleResizeObserver=e=>{for(const A of e){const{target:t,borderBoxSize:r}=A;if(!(t instanceof HTMLElement)){console.error("FileDiff.handleResizeObserver: Invalid element for ResizeObserver",A);continue}const n=this.observedNodes.get(t);if(n==null){console.error("FileDiff.handleResizeObserver: Not a valid observed node",A);continue}const i=r[0];if(n.type==="annotations"){const o=(()=>{if(t===n.column1.child)return n.column1;if(t===n.column2.child)return n.column2})();if(o==null){console.error("FileDiff.handleResizeObserver: Couldn't find a column for",{item:n,target:t});continue}o.childHeight=i.blockSize;const g=Math.max(n.column1.childHeight,n.column2.childHeight);g!==n.currentHeight&&(n.currentHeight=Math.max(g,0),n.column1.container.style.setProperty("--diffs-annotation-min-height",`${n.currentHeight}px`),n.column2.container.style.setProperty("--diffs-annotation-min-height",`${n.currentHeight}px`))}else n.type==="code"&&(t===n.codeElement?i.inlineSize!==n.codeWidth&&(n.codeWidth=i.inlineSize,n.codeElement.style.setProperty("--diffs-column-content-width",`${Math.max(n.codeWidth-n.numberWidth,0)}px`),n.codeElement.style.setProperty("--diffs-column-width",`${n.codeWidth}px`)):t===n.numberElement&&i.inlineSize!==n.numberWidth&&(n.numberWidth=i.inlineSize,n.codeElement.style.setProperty("--diffs-column-number-width",`${n.numberWidth}px`),n.codeWidth!=="auto"&&n.codeElement.style.setProperty("--diffs-column-content-width",`${Math.max(n.codeWidth-n.numberWidth,0)}px`)))}}};const xo=new Map,eI=new Map,wl=new Set;function xs(e){for(const A of Array.isArray(e)?e:[e])if(!wl.has(A))return!1;return!0}function zD(e,A){e=Array.isArray(e)?e:[e];for(const t of e){if(wl.has(t.name))continue;let r=xo.get(t.name);r==null&&(r=t,xo.set(t.name,r)),wl.add(r.name),A.loadLanguageSync(r.data)}}function ry(){return typeof WorkerGlobalScope<"u"&&typeof self<"u"&&self instanceof WorkerGlobalScope}let wt=class extends Error{constructor(A){super(A),this.name="ShikiError"}};function Gs(e,A){const t=typeof e=="string"?{}:{...e.colorReplacements},r=typeof e=="string"?e:e.name;for(const[n,i]of Object.entries(A?.colorReplacements||{}))typeof i=="string"?t[n]=i:n===r&&Object.assign(t,i);return t}function Ui(e,A){return e&&(A?.[e?.toLowerCase()]||e)}function jR(e){return Array.isArray(e)?e:[e]}async function ny(e){return Promise.resolve(typeof e=="function"?e():e).then(A=>A.default||A)}function Iu(e){return!e||["plaintext","txt","text","plain"].includes(e)}function iy(e){return e==="ansi"||Iu(e)}function lu(e){return e==="none"}function oy(e){return lu(e)}function gy(e,A){if(!A)return e;e.properties||={},e.properties.class||=[],typeof e.properties.class=="string"&&(e.properties.class=e.properties.class.split(/\s+/g)),Array.isArray(e.properties.class)||(e.properties.class=[]);const t=Array.isArray(A)?A:A.split(/\s+/g);for(const r of t)r&&!e.properties.class.includes(r)&&e.properties.class.push(r);return e}function dE(e,A=!1){if(e.length===0)return[["",0]];const t=e.split(/(\r?\n)/g);let r=0;const n=[];for(let i=0;in);function t(n){if(n===e.length)return{line:A.length-1,character:A[A.length-1].length};let i=n,o=0;for(const g of A){if(it&&r.push({...e,content:e.content.slice(t,n),offset:e.offset+t}),t=n;return tr-n);return t.length?e.map(r=>r.flatMap(n=>{const i=t.filter(o=>n.offseto-n.offset).sort((o,g)=>o-g);return i.length?ZR(n,i):n})):e}function $R(e,A,t,r,n="css-vars"){const i={content:e.content,explanation:e.explanation,offset:e.offset},o=A.map(a=>Ss(e.variants[a])),g=new Set(o.flatMap(a=>Object.keys(a))),Q={},B=(a,s)=>{const C=s==="color"?"":s==="background-color"?"-bg":`-${s}`;return t+A[a]+(s==="color"?"":C)};return o.forEach((a,s)=>{for(const C of g){const E=a[C]||"inherit";if(s===0&&r&&WR.includes(C))if(r===cu&&o.length>1){const I=A.findIndex(d=>d==="light"),c=A.findIndex(d=>d==="dark");if(I===-1||c===-1)throw new wt('When using `defaultColor: "light-dark()"`, you must provide both `light` and `dark` themes');const u=o[I][C]||"inherit",h=o[c][C]||"inherit";Q[C]=`light-dark(${u}, ${h})`,n==="css-vars"&&(Q[B(s,C)]=E)}else Q[C]=E;else n==="css-vars"&&(Q[B(s,C)]=E)}}),i.htmlStyle=Q,i}function Ss(e){const A={};if(e.color&&(A.color=e.color),e.bgColor&&(A["background-color"]=e.bgColor),e.fontStyle){e.fontStyle&_t.Italic&&(A["font-style"]="italic"),e.fontStyle&_t.Bold&&(A["font-weight"]="bold");const t=[];e.fontStyle&_t.Underline&&t.push("underline"),e.fontStyle&_t.Strikethrough&&t.push("line-through"),t.length&&(A["text-decoration"]=t.join(" "))}return A}function ml(e){return typeof e=="string"?e:Object.entries(e).map(([A,t])=>`${A}:${t}`).join(";")}const Qy=new WeakMap;function hE(e,A){Qy.set(e,A)}function iB(e){return Qy.get(e)}class Wg{_stacks={};lang;get themes(){return Object.keys(this._stacks)}get theme(){return this.themes[0]}get _stack(){return this._stacks[this.theme]}static initial(A,t){return new Wg(Object.fromEntries(jR(t).map(r=>[r,al])),A)}constructor(...A){if(A.length===2){const[t,r]=A;this.lang=r,this._stacks=t}else{const[t,r,n]=A;this.lang=r,this._stacks={[n]:t}}}getInternalStack(A=this.theme){return this._stacks[A]}getScopes(A=this.theme){return AO(this._stacks[A])}toJSON(){return{lang:this.lang,theme:this.theme,themes:this.themes,scopes:this.getScopes()}}}function AO(e){const A=[],t=new Set;function r(n){if(t.has(n))return;t.add(n);const i=n?.nameScopesList?.scopeName;i&&A.push(i),n.parent&&r(n.parent)}return r(e),A}function eO(e,A){if(!(e instanceof Wg))throw new wt("Invalid grammar state");return e.getInternalStack(A)}function tO(){const e=new WeakMap;function A(t){if(!e.has(t.meta)){let r=function(o){if(typeof o=="number"){if(o<0||o>t.source.length)throw new wt(`Invalid decoration offset: ${o}. Code length: ${t.source.length}`);return{...n.indexToPos(o),offset:o}}else{const g=n.lines[o.line];if(g===void 0)throw new wt(`Invalid decoration position ${JSON.stringify(o)}. Lines length: ${n.lines.length}`);let Q=o.character;if(Q<0&&(Q=g.length+Q),Q<0||Q>g.length)throw new wt(`Invalid decoration position ${JSON.stringify(o)}. Line ${o.line} length: ${g.length}`);return{...o,character:Q,offset:n.posToIndex(o.line,Q)}}};const n=VR(t.source),i=(t.options.decorations||[]).map(o=>({...o,start:r(o.start),end:r(o.end)}));rO(i),e.set(t.meta,{decorations:i,converter:n,source:t.source})}return e.get(t.meta)}return{name:"shiki:decorations",tokens(t){if(!this.options.decorations?.length)return;const n=A(this).decorations.flatMap(o=>[o.start.offset,o.end.offset]);return XR(t,n)},code(t){if(!this.options.decorations?.length)return;const r=A(this),n=Array.from(t.children).filter(a=>a.type==="element"&&a.tagName==="span");if(n.length!==r.converter.lines.length)throw new wt(`Number of lines in code element (${n.length}) does not match the number of lines in the source (${r.converter.lines.length}). Failed to apply decorations.`);function i(a,s,C,E){const I=n[a];let c="",u=-1,h=-1;if(s===0&&(u=0),C===0&&(h=0),C===Number.POSITIVE_INFINITY&&(h=I.children.length),u===-1||h===-1)for(let f=0;fc);return a.tagName=s.tagName||"span",a.properties={...a.properties,...E,class:a.properties.class},s.properties?.class&&gy(a,s.properties.class),a=I(a,C)||a,a}const Q=[],B=r.decorations.sort((a,s)=>s.start.offset-a.start.offset||a.end.offset-s.end.offset);for(const a of B){const{start:s,end:C}=a;if(s.line===C.line)i(s.line,s.character,C.character,a);else if(s.lineo(E,a));i(C.line,0,C.character,a)}}Q.forEach(a=>a())}}}function rO(e){for(let A=0;At.end.offset)throw new wt(`Invalid decoration range: ${JSON.stringify(t.start)} - ${JSON.stringify(t.end)}`);for(let r=A+1;rNumber.parseInt(r));return t.length!==3||t.some(r=>Number.isNaN(r))?void 0:{type:"rgb",rgb:t}}else if(A==="5"){const t=e.shift();if(t)return{type:"table",index:Number(t)}}}function gO(e){const A=[];for(;e.length>0;){const t=e.shift();if(!t)continue;const r=Number.parseInt(t);if(!Number.isNaN(r))if(r===0)A.push({type:"resetAll"});else if(r<=9)tI[r]&&A.push({type:"setDecoration",value:tI[r]});else if(r<=29){const n=tI[r-20];n&&(A.push({type:"resetDecoration",value:n}),n==="dim"&&A.push({type:"resetDecoration",value:"bold"}))}else if(r<=37)A.push({type:"setForegroundColor",value:{type:"named",name:ho[r-30]}});else if(r===38){const n=PD(e);n&&A.push({type:"setForegroundColor",value:n})}else if(r===39)A.push({type:"resetForegroundColor"});else if(r<=47)A.push({type:"setBackgroundColor",value:{type:"named",name:ho[r-40]}});else if(r===48){const n=PD(e);n&&A.push({type:"setBackgroundColor",value:n})}else r===49?A.push({type:"resetBackgroundColor"}):r===53?A.push({type:"setDecoration",value:"overline"}):r===55?A.push({type:"resetDecoration",value:"overline"}):r>=90&&r<=97?A.push({type:"setForegroundColor",value:{type:"named",name:ho[r-90+8]}}):r>=100&&r<=107&&A.push({type:"setBackgroundColor",value:{type:"named",name:ho[r-100+8]}})}return A}function QO(){let e=null,A=null,t=new Set;return{parse(r){const n=[];let i=0;do{const o=oO(r,i),g=o.sequence?r.substring(i,o.startPosition):r.substring(i);if(g.length>0&&n.push({value:g,foreground:e,background:A,decorations:new Set(t)}),o.sequence){const Q=gO(o.sequence);for(const B of Q)B.type==="resetAll"?(e=null,A=null,t.clear()):B.type==="resetForegroundColor"?e=null:B.type==="resetBackgroundColor"?A=null:B.type==="resetDecoration"&&t.delete(B.value);for(const B of Q)B.type==="setForegroundColor"?e=B.value:B.type==="setBackgroundColor"?A=B.value:B.type==="setDecoration"&&t.add(B.value)}i=o.position}while(iMath.max(0,Math.min(Q,255)).toString(16).padStart(2,"0")).join("")}`}let r;function n(){if(r)return r;r=[];for(let B=0;B{const B=`terminal.ansi${Q[0].toUpperCase()}${Q.substring(1)}`,a=e.colors?.[B];return[Q,a||sO[Q]]})),o=aO(i),g=QO();return n.map(Q=>g.parse(Q[0]).map(B=>{let a,s;B.decorations.has("reverse")?(a=B.background?o.value(B.background):e.bg,s=B.foreground?o.value(B.foreground):e.fg):(a=B.foreground?o.value(B.foreground):e.fg,s=B.background?o.value(B.background):void 0),a=Ui(a,r),s=Ui(s,r),B.decorations.has("dim")&&(a=CO(a));let C=_t.None;return B.decorations.has("bold")&&(C|=_t.Bold),B.decorations.has("italic")&&(C|=_t.Italic),B.decorations.has("underline")&&(C|=_t.Underline),B.decorations.has("strikethrough")&&(C|=_t.Strikethrough),{content:B.value,offset:Q[1],color:a,bgColor:s,fontStyle:C}}))}function CO(e){const A=e.match(/#([0-9a-f]{3,8})/i);if(A){const r=A[1];if(r.length===8){const n=Math.round(Number.parseInt(r.slice(6,8),16)/2).toString(16).padStart(2,"0");return`#${r.slice(0,6)}${n}`}else{if(r.length===6)return`#${r}80`;if(r.length===4){const n=r[0],i=r[1],o=r[2],g=r[3],Q=Math.round(Number.parseInt(`${g}${g}`,16)/2).toString(16).padStart(2,"0");return`#${n}${n}${i}${i}${o}${o}${Q}`}else if(r.length===3){const n=r[0],i=r[1],o=r[2];return`#${n}${n}${i}${i}${o}${o}80`}}}const t=e.match(/var\((--[\w-]+-ansi-[\w-]+)\)/);return t?`var(${t[1]}-dim)`:e}function uu(e,A,t={}){const{theme:r=e.getLoadedThemes()[0]}=t,n=e.resolveLangAlias(t.lang||"text");if(Iu(n)||lu(r))return dE(A).map(Q=>[{content:Q[0],offset:Q[1]}]);const{theme:i,colorMap:o}=e.setTheme(r);if(n==="ansi")return EO(i,A,t);const g=e.getLanguage(t.lang||"text");if(t.grammarState){if(t.grammarState.lang!==g.name)throw new wt(`Grammar state language "${t.grammarState.lang}" does not match highlight language "${g.name}"`);if(!t.grammarState.themes.includes(i.name))throw new wt(`Grammar state themes "${t.grammarState.themes}" do not contain highlight theme "${i.name}"`)}return lO(A,g,i,o,t)}function IO(...e){if(e.length===2)return iB(e[1]);const[A,t,r={}]=e,{lang:n="text",theme:i=A.getLoadedThemes()[0]}=r;if(Iu(n)||lu(i))throw new wt("Plain language does not have grammar state");if(n==="ansi")throw new wt("ANSI language does not have grammar state");const{theme:o,colorMap:g}=A.setTheme(i),Q=A.getLanguage(n);return new Wg(Us(t,Q,o,g,r).stateStack,Q.name,o.name)}function lO(e,A,t,r,n){const i=Us(e,A,t,r,n),o=new Wg(Us(e,A,t,r,n).stateStack,A.name,t.name);return hE(i.tokens,o),i.tokens}function Us(e,A,t,r,n){const i=Gs(t,n),{tokenizeMaxLineLength:o=0,tokenizeTimeLimit:g=500}=n,Q=dE(e);let B=n.grammarState?eO(n.grammarState,t.name)??al:n.grammarContextCode!=null?Us(n.grammarContextCode,A,t,r,{...n,grammarState:void 0,grammarContextCode:void 0}).stateStack:al,a=[];const s=[];for(let C=0,E=Q.length;C0&&I.length>=o){a=[],s.push([{content:I,offset:c,color:"",fontStyle:0}]);continue}let u,h,d;n.includeExplanation&&(u=A.tokenizeLine(I,B,g),h=u.tokens,d=0);const f=A.tokenizeLine2(I,B,g),m=f.tokens.length/2;for(let k=0;kP.trim());break;case"object":$=K.scope;break;default:continue}AA.push({settings:K,selectors:$.map(P=>P.split(/ /))})}W.explanation=[];let kA=0;for(;N+kA({scopeName:A}))}function uO(e,A){const t=[];for(let r=0,n=A.length;r=0&&n>=0;)_D(e[r],t[n])&&(r-=1),n-=1;return r===-1}function hO(e,A,t){const r=[];for(const{selectors:n,settings:i}of e)for(const o of n)if(dO(o,A,t)){r.push(i);break}return r}function ay(e,A,t){const r=Object.entries(t.themes).filter(Q=>Q[1]).map(Q=>({color:Q[0],theme:Q[1]})),n=r.map(Q=>{const B=uu(e,A,{...t,theme:Q.theme}),a=iB(B),s=typeof Q.theme=="string"?Q.theme:Q.theme.name;return{tokens:B,state:a,theme:s}}),i=DO(...n.map(Q=>Q.tokens)),o=i[0].map((Q,B)=>Q.map((a,s)=>{const C={content:a.content,variants:{},offset:a.offset};return"includeExplanation"in t&&t.includeExplanation&&(C.explanation=a.explanation),i.forEach((E,I)=>{const{content:c,explanation:u,offset:h,...d}=E[B][s];C.variants[r[I].color]=d}),C})),g=n[0].state?new Wg(Object.fromEntries(n.map(Q=>[Q.theme,Q.state?.getInternalStack(Q.theme)])),n[0].state.lang):void 0;return g&&hE(o,g),o}function DO(...e){const A=e.map(()=>[]),t=e.length;for(let r=0;rQ[r]),i=A.map(()=>[]);A.forEach((Q,B)=>Q.push(i[B]));const o=n.map(()=>0),g=n.map(Q=>Q[0]);for(;g.every(Q=>Q);){const Q=Math.min(...g.map(B=>B.content.length));for(let B=0;Bh[1]).map(h=>({color:h[0],theme:h[1]})).sort((h,d)=>h.color===B?-1:d.color===B?1:0);if(C.length===0)throw new wt("`themes` option must not be empty");const E=ay(e,A,t);if(Q=iB(E),B&&cu!==B&&!C.find(h=>h.color===B))throw new wt(`\`themes\` option must contain the defaultColor key \`${B}\``);const I=C.map(h=>e.getTheme(h.theme)),c=C.map(h=>h.color);i=E.map(h=>h.map(d=>$R(d,c,a,B,s))),Q&&hE(i,Q);const u=C.map(h=>Gs(h.theme,t));n=jD(C,I,u,a,B,"fg",s),r=jD(C,I,u,a,B,"bg",s),o=`shiki-themes ${I.map(h=>h.name).join(" ")}`,g=B?void 0:[n,r].join(";")}else if("theme"in t){const B=Gs(t.theme,t);i=uu(e,A,t);const a=e.getTheme(t.theme);r=Ui(a.bg,B),n=Ui(a.fg,B),o=a.name,Q=iB(i)}else throw new wt("Invalid options, either `theme` or `themes` must be provided");return{tokens:i,fg:n,bg:r,themeName:o,rootStyle:g,grammarState:Q}}function jD(e,A,t,r,n,i,o){return e.map((g,Q)=>{const B=Ui(A[Q][i],t[Q])||"inherit",a=`${r+g.color}${i==="bg"?"-bg":""}:${B}`;if(Q===0&&n){if(n===cu&&e.length>1){const s=e.findIndex(c=>c.color==="light"),C=e.findIndex(c=>c.color==="dark");if(s===-1||C===-1)throw new wt('When using `defaultColor: "light-dark()"`, you must provide both `light` and `dark` themes');const E=Ui(A[s][i],t[s])||"inherit",I=Ui(A[C][i],t[C])||"inherit";return`light-dark(${E}, ${I});${a}`}return B}return o==="css-vars"?a:null}).filter(g=>!!g).join(";")}function Ls(e,A,t,r={meta:{},options:t,codeToHast:(n,i)=>Ls(e,n,i),codeToTokens:(n,i)=>Ks(e,n,i)}){let n=A;for(const I of Js(t))n=I.preprocess?.call(r,n,t)||n;let{tokens:i,fg:o,bg:g,themeName:Q,rootStyle:B,grammarState:a}=Ks(e,n,t);const{mergeWhitespaces:s=!0,mergeSameStyleTokens:C=!1}=t;s===!0?i=wO(i):s==="never"&&(i=mO(i)),C&&(i=pO(i));const E={...r,get source(){return n}};for(const I of Js(t))i=I.tokens?.call(E,i)||i;return fO(i,{...t,fg:o,bg:g,themeName:Q,rootStyle:t.rootStyle===!1?!1:t.rootStyle??B},E,a)}function fO(e,A,t,r=iB(e)){const n=Js(A),i=[],o={type:"root",children:[]},{structure:g="classic",tabindex:Q="0"}=A,B={class:`shiki ${A.themeName||""}`};A.rootStyle!==!1&&(A.rootStyle!=null?B.style=A.rootStyle:B.style=`background-color:${A.bg};color:${A.fg}`),Q!==!1&&Q!=null&&(B.tabindex=Q.toString());for(const[c,u]of Object.entries(A.meta||{}))c.startsWith("_")||(B[c]=u);let a={type:"element",tagName:"pre",properties:B,children:[]},s={type:"element",tagName:"code",properties:{},children:i};const C=[],E={...t,structure:g,addClassToHast:gy,get source(){return t.source},get tokens(){return e},get options(){return A},get root(){return o},get pre(){return a},get code(){return s},get lines(){return C}};if(e.forEach((c,u)=>{u&&(g==="inline"?o.children.push({type:"element",tagName:"br",properties:{},children:[]}):g==="classic"&&i.push({type:"text",value:` `}));let h={type:"element",tagName:"span",properties:{class:"line"},children:[]},d=0;for(const f of c){let m={type:"element",tagName:"span",properties:{...f.htmlAttrs},children:[{type:"text",value:f.content}]};const k=ml(f.htmlStyle||Ss(f));k&&(m.properties.style=k);for(const N of n)m=N?.span?.call(E,m,u+1,d,h,f)||m;g==="inline"?o.children.push(m):g==="classic"&&h.children.push(m),d+=f.content.length}if(g==="classic"){for(const f of n)h=f?.line?.call(E,h,u+1)||h;C.push(h),i.push(h)}else g==="inline"&&C.push(h)}),g==="classic"){for(const c of n)s=c?.code?.call(E,s)||s;a.children.push(s);for(const c of n)a=c?.pre?.call(E,a)||a;o.children.push(a)}else if(g==="inline"){const c=[];let u={type:"element",tagName:"span",properties:{class:"line"},children:[]};for(const f of o.children)f.type==="element"&&f.tagName==="br"?(c.push(u),u={type:"element",tagName:"span",properties:{class:"line"},children:[]}):(f.type==="element"||f.type==="text")&&u.children.push(f);c.push(u);let d={type:"element",tagName:"code",properties:{},children:c};for(const f of n)d=f?.code?.call(E,d)||d;o.children=[];for(let f=0;f0&&o.children.push({type:"element",tagName:"br",properties:{},children:[]});const m=d.children[f];m.type==="element"&&o.children.push(...m.children)}}let I=o;for(const c of n)I=c?.root?.call(E,I)||I;return r&&hE(I,r),I}function wO(e){return e.map(A=>{const t=[];let r="",n;return A.forEach((i,o)=>{const Q=!(i.fontStyle&&(i.fontStyle&_t.Underline||i.fontStyle&_t.Strikethrough));Q&&i.content.match(/^\s+$/)&&A[o+1]?(n===void 0&&(n=i.offset),r+=i.content):r?(Q?t.push({...i,offset:n,content:r+i.content}):t.push({content:r,offset:n},i),n=void 0,r=""):t.push(i)}),t})}function mO(e){return e.map(A=>A.flatMap(t=>{if(t.content.match(/^\s+$/))return t;const r=t.content.match(/^(\s*)(.*?)(\s*)$/);if(!r)return t;const[,n,i,o]=r;if(!n&&!o)return t;const g=[{...t,offset:t.offset+n.length,content:i}];return n&&g.unshift({content:n,offset:t.offset}),o&&g.push({content:o,offset:t.offset+n.length+i.length}),g}))}function pO(e){return e.map(A=>{const t=[];for(const r of A){if(t.length===0){t.push({...r});continue}const n=t[t.length-1],i=ml(n.htmlStyle||Ss(n)),o=ml(r.htmlStyle||Ss(r)),g=n.fontStyle&&(n.fontStyle&_t.Underline||n.fontStyle&_t.Strikethrough),Q=r.fontStyle&&(r.fontStyle&_t.Underline||r.fontStyle&_t.Strikethrough);!g&&!Q&&i===o?n.content+=r.content:t.push({...r})}return t})}const kO=Xn;function yO(e,A,t){const r={meta:{},options:t,codeToHast:(i,o)=>Ls(e,i,o),codeToTokens:(i,o)=>Ks(e,i,o)};let n=kO(Ls(e,A,t,r));for(const i of Js(t))n=i.postprocess?.call(r,n,t)||n;return n}const VD={light:"#333333",dark:"#bbbbbb"},WD={light:"#fffffe",dark:"#1e1e1e"},ZD="__shiki_resolved";function DE(e){if(e?.[ZD])return e;const A={...e};A.tokenColors&&!A.settings&&(A.settings=A.tokenColors,delete A.tokenColors),A.type||="dark",A.colorReplacements={...A.colorReplacements},A.settings||=[];let{bg:t,fg:r}=A;if(!t||!r){const g=A.settings?A.settings.find(Q=>!Q.name&&!Q.scope):void 0;g?.settings?.foreground&&(r=g.settings.foreground),g?.settings?.background&&(t=g.settings.background),!r&&A?.colors?.["editor.foreground"]&&(r=A.colors["editor.foreground"]),!t&&A?.colors?.["editor.background"]&&(t=A.colors["editor.background"]),r||(r=A.type==="light"?VD.light:VD.dark),t||(t=A.type==="light"?WD.light:WD.dark),A.fg=r,A.bg=t}A.settings[0]&&A.settings[0].settings&&!A.settings[0].scope||A.settings.unshift({settings:{foreground:A.fg,background:A.bg}});let n=0;const i=new Map;function o(g){if(i.has(g))return i.get(g);n+=1;const Q=`#${n.toString(16).padStart(8,"0").toLowerCase()}`;return A.colorReplacements?.[`#${Q}`]?o(g):(i.set(g,Q),Q)}A.settings=A.settings.map(g=>{const Q=g.settings?.foreground&&!g.settings.foreground.startsWith("#"),B=g.settings?.background&&!g.settings.background.startsWith("#");if(!Q&&!B)return g;const a={...g,settings:{...g.settings}};if(Q){const s=o(g.settings.foreground);A.colorReplacements[s]=g.settings.foreground,a.settings.foreground=s}if(B){const s=o(g.settings.background);A.colorReplacements[s]=g.settings.background,a.settings.background=s}return a});for(const g of Object.keys(A.colors||{}))if((g==="editor.foreground"||g==="editor.background"||g.startsWith("terminal.ansi"))&&!A.colors[g]?.startsWith("#")){const Q=o(A.colors[g]);A.colorReplacements[Q]=A.colors[g],A.colors[g]=Q}return Object.defineProperty(A,ZD,{enumerable:!1,writable:!1,value:!0}),A}async function sy(e){return Array.from(new Set((await Promise.all(e.filter(A=>!iy(A)).map(async A=>await ny(A).then(t=>Array.isArray(t)?t:[t])))).flat()))}async function Ey(e){return(await Promise.all(e.map(async t=>oy(t)?null:DE(await ny(t))))).filter(t=>!!t)}let MO=3;function NO(e,A=3){A>MO||console.trace(`[SHIKI DEPRECATE]: ${e}`)}let fg=class extends Error{constructor(A){super(A),this.name="ShikiError"}};function Cy(e,A){if(!A)return e;if(A[e]){const t=new Set([e]);for(;A[e];){if(e=A[e],t.has(e))throw new fg(`Circular alias \`${Array.from(t).join(" -> ")} -> ${e}\``);t.add(e)}}return e}class vO extends KU{constructor(A,t,r,n={}){super(A),this._resolver=A,this._themes=t,this._langs=r,this._alias=n,this._themes.map(i=>this.loadTheme(i)),this.loadLanguages(this._langs)}_resolvedThemes=new Map;_resolvedGrammars=new Map;_langMap=new Map;_langGraph=new Map;_textmateThemeCache=new WeakMap;_loadedThemesCache=null;_loadedLanguagesCache=null;getTheme(A){return typeof A=="string"?this._resolvedThemes.get(A):this.loadTheme(A)}loadTheme(A){const t=DE(A);return t.name&&(this._resolvedThemes.set(t.name,t),this._loadedThemesCache=null),t}getLoadedThemes(){return this._loadedThemesCache||(this._loadedThemesCache=[...this._resolvedThemes.keys()]),this._loadedThemesCache}setTheme(A){let t=this._textmateThemeCache.get(A);t||(t=ms.createFromRawTheme(A),this._textmateThemeCache.set(A,t)),this._syncRegistry.setTheme(t)}getGrammar(A){return A=Cy(A,this._alias),this._resolvedGrammars.get(A)}loadLanguage(A){if(this.getGrammar(A.name))return;const t=new Set([...this._langMap.values()].filter(i=>i.embeddedLangsLazy?.includes(A.name)));this._resolver.addLanguage(A);const r={balancedBracketSelectors:A.balancedBracketSelectors||["*"],unbalancedBracketSelectors:A.unbalancedBracketSelectors||[]};this._syncRegistry._rawGrammars.set(A.scopeName,A);const n=this.loadGrammarWithConfiguration(A.scopeName,1,r);if(n.name=A.name,this._resolvedGrammars.set(A.name,n),A.aliases&&A.aliases.forEach(i=>{this._alias[i]=A.name}),this._loadedLanguagesCache=null,t.size)for(const i of t)this._resolvedGrammars.delete(i.name),this._loadedLanguagesCache=null,this._syncRegistry?._injectionGrammars?.delete(i.scopeName),this._syncRegistry?._grammars?.delete(i.scopeName),this.loadLanguage(this._langMap.get(i.name))}dispose(){super.dispose(),this._resolvedThemes.clear(),this._resolvedGrammars.clear(),this._langMap.clear(),this._langGraph.clear(),this._loadedThemesCache=null}loadLanguages(A){for(const n of A)this.resolveEmbeddedLanguages(n);const t=Array.from(this._langGraph.entries()),r=t.filter(([n,i])=>!i);if(r.length){const n=t.filter(([i,o])=>o?(o.embeddedLanguages||o.embeddedLangs)?.some(Q=>r.map(([B])=>B).includes(Q)):!1).filter(i=>!r.includes(i));throw new fg(`Missing languages ${r.map(([i])=>`\`${i}\``).join(", ")}, required by ${n.map(([i])=>`\`${i}\``).join(", ")}`)}for(const[n,i]of t)this._resolver.addLanguage(i);for(const[n,i]of t)this.loadLanguage(i)}getLoadedLanguages(){return this._loadedLanguagesCache||(this._loadedLanguagesCache=[...new Set([...this._resolvedGrammars.keys(),...Object.keys(this._alias)])]),this._loadedLanguagesCache}resolveEmbeddedLanguages(A){this._langMap.set(A.name,A),this._langGraph.set(A.name,A);const t=A.embeddedLanguages??A.embeddedLangs;if(t)for(const r of t)this._langGraph.set(r,this._langMap.get(r))}}class bO{_langs=new Map;_scopeToLang=new Map;_injections=new Map;_onigLib;constructor(A,t){this._onigLib={createOnigScanner:r=>A.createScanner(r),createOnigString:r=>A.createString(r)},t.forEach(r=>this.addLanguage(r))}get onigLib(){return this._onigLib}getLangRegistration(A){return this._langs.get(A)}loadGrammar(A){return this._scopeToLang.get(A)}addLanguage(A){this._langs.set(A.name,A),A.aliases&&A.aliases.forEach(t=>{this._langs.set(t,A)}),this._scopeToLang.set(A.scopeName,A),A.injectTo&&A.injectTo.forEach(t=>{this._injections.get(t)||this._injections.set(t,[]),this._injections.get(t).push(A.scopeName)})}getInjections(A){const t=A.split(".");let r=[];for(let n=1;n<=t.length;n++){const i=t.slice(0,n).join(".");r=[...r,...this._injections.get(i)||[]]}return r}}let dQ=0;function FO(e){dQ+=1,e.warnings!==!1&&dQ>=10&&dQ%10===0&&console.warn(`[Shiki] ${dQ} instances have been created. Shiki is supposed to be used as a singleton, consider refactoring your code to cache your highlighter instance; Or call \`highlighter.dispose()\` to release unused instances.`);let A=!1;if(!e.engine)throw new fg("`engine` option is required for synchronous mode");const t=(e.langs||[]).flat(1),r=(e.themes||[]).flat(1).map(DE),n=new bO(e.engine,t),i=new vO(n,r,t,e.langAlias);let o;function g(f){return Cy(f,e.langAlias)}function Q(f){h();const m=i.getGrammar(typeof f=="string"?f:f.name);if(!m)throw new fg(`Language \`${f}\` not found, you may need to load it first`);return m}function B(f){if(f==="none")return{bg:"",fg:"",name:"none",settings:[],type:"dark"};h();const m=i.getTheme(f);if(!m)throw new fg(`Theme \`${f}\` not found, you may need to load it first`);return m}function a(f){h();const m=B(f);o!==f&&(i.setTheme(m),o=f);const k=i.getColorMap();return{theme:m,colorMap:k}}function s(){return h(),i.getLoadedThemes()}function C(){return h(),i.getLoadedLanguages()}function E(...f){h(),i.loadLanguages(f.flat(1))}async function I(...f){return E(await sy(f))}function c(...f){h();for(const m of f.flat(1))i.loadTheme(m)}async function u(...f){return h(),c(await Ey(f))}function h(){if(A)throw new fg("Shiki instance has been disposed")}function d(){A||(A=!0,i.dispose(),dQ-=1)}return{setTheme:a,getTheme:B,getLanguage:Q,getLoadedThemes:s,getLoadedLanguages:C,resolveLangAlias:g,loadLanguage:I,loadLanguageSync:E,loadTheme:u,loadThemeSync:c,dispose:d,[Symbol.dispose]:d}}async function xO(e){e.engine||NO("`engine` option is required. Use `createOnigurumaEngine` or `createJavaScriptRegexEngine` to create an engine.");const[A,t,r]=await Promise.all([Ey(e.themes||[]),sy(e.langs||[]),e.engine]);return FO({...e,themes:A,langs:t,engine:r})}async function GO(e){const A=await xO(e);return{getLastGrammarState:(...t)=>IO(A,...t),codeToTokensBase:(t,r)=>uu(A,t,r),codeToTokensWithThemes:(t,r)=>ay(A,t,r),codeToTokens:(t,r)=>Ks(A,t,r),codeToHast:(t,r)=>Ls(A,t,r),codeToHtml:(t,r)=>yO(A,t,r),getBundledLanguages:()=>({}),getBundledThemes:()=>({}),...A,getInternalContext:()=>A}}function SO(e){const A=e.langs,t=e.themes,r=e.engine;async function n(i){function o(s){if(typeof s=="string"){if(s=i.langAlias?.[s]||s,iy(s))return[];const C=A[s];if(!C)throw new wt(`Language \`${s}\` is not included in this bundle. You may want to load it from external source.`);return C}return s}function g(s){if(oy(s))return"none";if(typeof s=="string"){const C=t[s];if(!C)throw new wt(`Theme \`${s}\` is not included in this bundle. You may want to load it from external source.`);return C}return s}const Q=(i.themes??[]).map(s=>g(s)),B=(i.langs??[]).map(s=>o(s)),a=await GO({engine:i.engine??r(),...i,themes:Q,langs:B});return{...a,loadLanguage(...s){return a.loadLanguage(...s.map(o))},loadTheme(...s){return a.loadTheme(...s.map(g))},getBundledLanguages(){return A},getBundledThemes(){return t}}}return n}const Iy=[{id:"abap",name:"ABAP",import:()=>p(()=>import("./abap-BXYWi5l2.js"),[])},{id:"actionscript-3",name:"ActionScript",import:()=>p(()=>import("./actionscript-3-LjD3sNyx.js"),[])},{id:"ada",name:"Ada",import:()=>p(()=>import("./ada-DeReRNhg.js"),[])},{id:"angular-html",name:"Angular HTML",import:()=>p(()=>import("./angular-html-6NEUuZou.js").then(e=>e.f),__vite__mapDeps([97,98,99,100]))},{id:"angular-ts",name:"Angular TypeScript",import:()=>p(()=>import("./angular-ts-BfBSdvnY.js"),__vite__mapDeps([101,97,98,99,100,102]))},{id:"apache",name:"Apache Conf",import:()=>p(()=>import("./apache-CCUDgqAf.js"),[])},{id:"apex",name:"Apex",import:()=>p(()=>import("./apex-ynV6aGfE.js"),[])},{id:"apl",name:"APL",import:()=>p(()=>import("./apl-C-KxP0FL.js"),__vite__mapDeps([103,98,99,100,104,105,106]))},{id:"applescript",name:"AppleScript",import:()=>p(()=>import("./applescript-Dd26Nb5t.js"),[])},{id:"ara",name:"Ara",import:()=>p(()=>import("./ara-D6vCOKVX.js"),[])},{id:"asciidoc",name:"AsciiDoc",aliases:["adoc"],import:()=>p(()=>import("./asciidoc-DZ9uQOoP.js"),[])},{id:"asm",name:"Assembly",import:()=>p(()=>import("./asm-CbVMAfFB.js"),[])},{id:"astro",name:"Astro",import:()=>p(()=>import("./astro-OEl6i-aI.js"),__vite__mapDeps([107,106,99,108,100,109,110]))},{id:"awk",name:"AWK",import:()=>p(()=>import("./awk-UmR4Ublb.js"),[])},{id:"ballerina",name:"Ballerina",import:()=>p(()=>import("./ballerina-BMbY-1wP.js"),[])},{id:"bat",name:"Batch File",aliases:["batch"],import:()=>p(()=>import("./bat-Dcnh2ot_.js"),[])},{id:"beancount",name:"Beancount",import:()=>p(()=>import("./beancount-B92nBv9q.js"),[])},{id:"berry",name:"Berry",aliases:["be"],import:()=>p(()=>import("./berry-C9fz7p0n.js"),[])},{id:"bibtex",name:"BibTeX",import:()=>p(()=>import("./bibtex-DELXwv0g.js"),[])},{id:"bicep",name:"Bicep",import:()=>p(()=>import("./bicep-D2njIRU5.js"),[])},{id:"blade",name:"Blade",import:()=>p(()=>import("./blade-CwZbp2Ca.js"),__vite__mapDeps([111,112,98,99,100,104,105,113,106]))},{id:"bsl",name:"1C (Enterprise)",aliases:["1c"],import:()=>p(()=>import("./bsl-C4qeDxuX.js"),__vite__mapDeps([114,115]))},{id:"c",name:"C",import:()=>p(()=>import("./c-CyUOlKFr.js"),[])},{id:"cadence",name:"Cadence",aliases:["cdc"],import:()=>p(()=>import("./cadence-bIHbUj02.js"),[])},{id:"cairo",name:"Cairo",import:()=>p(()=>import("./cairo-C_mOTUpN.js"),__vite__mapDeps([116,117]))},{id:"clarity",name:"Clarity",import:()=>p(()=>import("./clarity-A4x-rz24.js"),[])},{id:"clojure",name:"Clojure",aliases:["clj"],import:()=>p(()=>import("./clojure-Bb2-3A0I.js"),[])},{id:"cmake",name:"CMake",import:()=>p(()=>import("./cmake-Cv5ljclQ.js"),[])},{id:"cobol",name:"COBOL",import:()=>p(()=>import("./cobol-Cg3yRVOY.js"),__vite__mapDeps([118,98,99,100,105]))},{id:"codeowners",name:"CODEOWNERS",import:()=>p(()=>import("./codeowners-CKT8dJip.js"),[])},{id:"codeql",name:"CodeQL",aliases:["ql"],import:()=>p(()=>import("./codeql-DXd8ggn3.js"),[])},{id:"coffee",name:"CoffeeScript",aliases:["coffeescript"],import:()=>p(()=>import("./coffee-CSg58a7P.js"),__vite__mapDeps([119,99]))},{id:"common-lisp",name:"Common Lisp",aliases:["lisp"],import:()=>p(()=>import("./common-lisp-v102bg8X.js"),[])},{id:"coq",name:"Coq",import:()=>p(()=>import("./coq-CxCehFeR.js"),[])},{id:"cpp",name:"C++",aliases:["c++"],import:()=>p(()=>import("./cpp-C28rag7_.js"),__vite__mapDeps([120,121,122,123,113]))},{id:"crystal",name:"Crystal",import:()=>p(()=>import("./crystal-kLfOnxTY.js"),__vite__mapDeps([124,98,99,100,113,123,125]))},{id:"csharp",name:"C#",aliases:["c#","cs"],import:()=>p(()=>import("./csharp-DFQpaWb6.js"),[])},{id:"css",name:"CSS",import:()=>p(()=>import("./css-BSK200cd.js"),[])},{id:"csv",name:"CSV",import:()=>p(()=>import("./csv-AZNL9t8Q.js"),[])},{id:"cue",name:"CUE",import:()=>p(()=>import("./cue-nzsbQn5T.js"),[])},{id:"cypher",name:"Cypher",aliases:["cql"],import:()=>p(()=>import("./cypher-BM7Pwunj.js"),[])},{id:"d",name:"D",import:()=>p(()=>import("./d-TG9YRPoI.js"),[])},{id:"dart",name:"Dart",import:()=>p(()=>import("./dart-DArdxSyj.js"),[])},{id:"dax",name:"DAX",import:()=>p(()=>import("./dax-B28Cho4e.js"),[])},{id:"desktop",name:"Desktop",import:()=>p(()=>import("./desktop-Z9LhWKWr.js"),[])},{id:"diff",name:"Diff",import:()=>p(()=>import("./diff-BlzBhZx2.js"),[])},{id:"docker",name:"Dockerfile",aliases:["dockerfile"],import:()=>p(()=>import("./docker-DIG_IqVK.js"),[])},{id:"dotenv",name:"dotEnv",import:()=>p(()=>import("./dotenv-Bf0GLMGc.js"),[])},{id:"dream-maker",name:"Dream Maker",import:()=>p(()=>import("./dream-maker-DBhfoDN-.js"),[])},{id:"edge",name:"Edge",import:()=>p(()=>import("./edge-C9mkmEUa.js"),__vite__mapDeps([126,108,98,99,100,112]))},{id:"elixir",name:"Elixir",import:()=>p(()=>import("./elixir-B1OcFvXE.js"),__vite__mapDeps([127,98,99,100]))},{id:"elm",name:"Elm",import:()=>p(()=>import("./elm-BX_9EnK8.js"),__vite__mapDeps([128,122,123]))},{id:"emacs-lisp",name:"Emacs Lisp",aliases:["elisp"],import:()=>p(()=>import("./emacs-lisp-fXIB3QbG.js"),[])},{id:"erb",name:"ERB",import:()=>p(()=>import("./erb-CjsbKF3w.js"),__vite__mapDeps([129,98,99,100,130,131,104,105,113,132,108,133,110,120,121,122,123,125,134,135]))},{id:"erlang",name:"Erlang",aliases:["erl"],import:()=>p(()=>import("./erlang-Dh270pQQ.js"),__vite__mapDeps([136,137]))},{id:"fennel",name:"Fennel",import:()=>p(()=>import("./fennel-CKW7gc4E.js"),[])},{id:"fish",name:"Fish",import:()=>p(()=>import("./fish-BiaFC76h.js"),[])},{id:"fluent",name:"Fluent",aliases:["ftl"],import:()=>p(()=>import("./fluent-C1VbA1FI.js"),[])},{id:"fortran-fixed-form",name:"Fortran (Fixed Form)",aliases:["f","for","f77"],import:()=>p(()=>import("./fortran-fixed-form-VBUom2Po.js"),__vite__mapDeps([138,139]))},{id:"fortran-free-form",name:"Fortran (Free Form)",aliases:["f90","f95","f03","f08","f18"],import:()=>p(()=>import("./fortran-free-form-xZZnushS.js"),[])},{id:"fsharp",name:"F#",aliases:["f#","fs"],import:()=>p(()=>import("./fsharp-B6CigNpP.js"),__vite__mapDeps([140,137]))},{id:"gdresource",name:"GDResource",import:()=>p(()=>import("./gdresource-B57lXvxj.js"),__vite__mapDeps([141,142,143]))},{id:"gdscript",name:"GDScript",import:()=>p(()=>import("./gdscript-etqGfJNh.js"),[])},{id:"gdshader",name:"GDShader",import:()=>p(()=>import("./gdshader-MbeiIFWW.js"),[])},{id:"genie",name:"Genie",import:()=>p(()=>import("./genie-CTXGoN_z.js"),[])},{id:"gherkin",name:"Gherkin",import:()=>p(()=>import("./gherkin-DQeIZrj7.js"),[])},{id:"git-commit",name:"Git Commit Message",import:()=>p(()=>import("./git-commit-BicZTByO.js"),__vite__mapDeps([144,145]))},{id:"git-rebase",name:"Git Rebase Message",import:()=>p(()=>import("./git-rebase-Bzlpfr7M.js"),__vite__mapDeps([146,125]))},{id:"gleam",name:"Gleam",import:()=>p(()=>import("./gleam-B-IqXlZK.js"),[])},{id:"glimmer-js",name:"Glimmer JS",aliases:["gjs"],import:()=>p(()=>import("./glimmer-js-cZi37nA1.js"),__vite__mapDeps([147,99,108,100,98]))},{id:"glimmer-ts",name:"Glimmer TS",aliases:["gts"],import:()=>p(()=>import("./glimmer-ts-BY3QTAW9.js"),__vite__mapDeps([148,108,100,99,98]))},{id:"glsl",name:"GLSL",import:()=>p(()=>import("./glsl-Bk7TyU8J.js"),__vite__mapDeps([122,123]))},{id:"gnuplot",name:"Gnuplot",import:()=>p(()=>import("./gnuplot-BBjkHhdK.js"),[])},{id:"go",name:"Go",import:()=>p(()=>import("./go-BYCC9JQ2.js"),[])},{id:"graphql",name:"GraphQL",aliases:["gql"],import:()=>p(()=>import("./graphql-By4-2MiP.js"),__vite__mapDeps([132,99,108,133,110]))},{id:"groovy",name:"Groovy",import:()=>p(()=>import("./groovy-DjMbfbx0.js"),[])},{id:"hack",name:"Hack",import:()=>p(()=>import("./hack-Ce3HFLQu.js"),__vite__mapDeps([149,98,99,100,113]))},{id:"haml",name:"Ruby Haml",import:()=>p(()=>import("./haml-C-C08OMF.js"),__vite__mapDeps([131,99,100]))},{id:"handlebars",name:"Handlebars",aliases:["hbs"],import:()=>p(()=>import("./handlebars-BFxKmXBZ.js"),__vite__mapDeps([150,98,99,100,135]))},{id:"haskell",name:"Haskell",aliases:["hs"],import:()=>p(()=>import("./haskell-DtebQ3Kv.js"),[])},{id:"haxe",name:"Haxe",import:()=>p(()=>import("./haxe-n0Q_eay_.js"),[])},{id:"hcl",name:"HashiCorp HCL",import:()=>p(()=>import("./hcl-shhv74hy.js"),[])},{id:"hjson",name:"Hjson",import:()=>p(()=>import("./hjson-BEMFYqr7.js"),[])},{id:"hlsl",name:"HLSL",import:()=>p(()=>import("./hlsl-Pefxhtaj.js"),[])},{id:"html",name:"HTML",import:()=>p(()=>import("./html-DBrZJmtb.js"),__vite__mapDeps([98,99,100]))},{id:"html-derivative",name:"HTML (Derivative)",import:()=>p(()=>import("./html-derivative-DgyNW28a.js"),__vite__mapDeps([112,98,99,100]))},{id:"http",name:"HTTP",import:()=>p(()=>import("./http-D0p2QOuJ.js"),__vite__mapDeps([151,125,106,104,105,132,99,108,133,110]))},{id:"hurl",name:"Hurl",import:()=>p(()=>import("./hurl-CeF7EoTQ.js"),__vite__mapDeps([152,132,99,108,133,110,104,105,153]))},{id:"hxml",name:"HXML",import:()=>p(()=>import("./hxml-B_SuSTPP.js"),__vite__mapDeps([154,155]))},{id:"hy",name:"Hy",import:()=>p(()=>import("./hy-CTpXmg0M.js"),[])},{id:"imba",name:"Imba",import:()=>p(()=>import("./imba-z_cUhu9e.js"),[])},{id:"ini",name:"INI",aliases:["properties"],import:()=>p(()=>import("./ini-DOGW4-0C.js"),[])},{id:"java",name:"Java",import:()=>p(()=>import("./java-B2AjWfgk.js"),[])},{id:"javascript",name:"JavaScript",aliases:["js","cjs","mjs"],import:()=>p(()=>import("./javascript-XPxc2APE.js"),[])},{id:"jinja",name:"Jinja",import:()=>p(()=>import("./jinja-DlBE7Xgz.js"),__vite__mapDeps([156,98,99,100]))},{id:"jison",name:"Jison",import:()=>p(()=>import("./jison-DRGa8fbr.js"),__vite__mapDeps([157,99]))},{id:"json",name:"JSON",import:()=>p(()=>import("./json-CjLXzM_z.js"),[])},{id:"json5",name:"JSON5",import:()=>p(()=>import("./json5-DE06a0U2.js"),[])},{id:"jsonc",name:"JSON with Comments",import:()=>p(()=>import("./jsonc-BYi4HS05.js"),[])},{id:"jsonl",name:"JSON Lines",import:()=>p(()=>import("./jsonl-CuhIcKDk.js"),[])},{id:"jsonnet",name:"Jsonnet",import:()=>p(()=>import("./jsonnet-DtQdHwK-.js"),[])},{id:"jssm",name:"JSSM",aliases:["fsl"],import:()=>p(()=>import("./jssm-BlhucWo7.js"),[])},{id:"jsx",name:"JSX",import:()=>p(()=>import("./jsx-BGEKFWBk.js"),[])},{id:"julia",name:"Julia",aliases:["jl"],import:()=>p(()=>import("./julia-Bh5qjrIj.js"),__vite__mapDeps([158,120,121,122,123,113,117,99,159]))},{id:"kdl",name:"KDL",import:()=>p(()=>import("./kdl-DJsF4U57.js"),[])},{id:"kotlin",name:"Kotlin",aliases:["kt","kts"],import:()=>p(()=>import("./kotlin-DwKqsDKK.js"),[])},{id:"kusto",name:"Kusto",aliases:["kql"],import:()=>p(()=>import("./kusto-w7PrLrBe.js"),[])},{id:"latex",name:"LaTeX",import:()=>p(()=>import("./latex-BuzO6rjU.js"),__vite__mapDeps([160,161,159]))},{id:"lean",name:"Lean 4",aliases:["lean4"],import:()=>p(()=>import("./lean-Dle5D8N4.js"),[])},{id:"less",name:"Less",import:()=>p(()=>import("./less-C76OjOdF.js"),[])},{id:"liquid",name:"Liquid",import:()=>p(()=>import("./liquid-DdraCjph.js"),__vite__mapDeps([162,98,99,100,106]))},{id:"llvm",name:"LLVM IR",import:()=>p(()=>import("./llvm-s1WuUfOe.js"),[])},{id:"log",name:"Log file",import:()=>p(()=>import("./log-CbW7hOWU.js"),[])},{id:"logo",name:"Logo",import:()=>p(()=>import("./logo-BbooMuDm.js"),[])},{id:"lua",name:"Lua",import:()=>p(()=>import("./lua-tkfysgZP.js"),__vite__mapDeps([134,123]))},{id:"luau",name:"Luau",import:()=>p(()=>import("./luau-CBwFb-vO.js"),[])},{id:"make",name:"Makefile",aliases:["makefile"],import:()=>p(()=>import("./make-s9FKP0VE.js"),[])},{id:"markdown",name:"Markdown",aliases:["md"],import:()=>p(()=>import("./markdown-CKXSK5AY.js"),[])},{id:"marko",name:"Marko",import:()=>p(()=>import("./marko-BsqRlKIY.js"),__vite__mapDeps([163,100,164,102,108]))},{id:"matlab",name:"MATLAB",import:()=>p(()=>import("./matlab-BQKM-LA_.js"),[])},{id:"mdc",name:"MDC",import:()=>p(()=>import("./mdc-BBM-UqJy.js"),__vite__mapDeps([165,137,135,112,98,99,100]))},{id:"mdx",name:"MDX",import:()=>p(()=>import("./mdx-BWRhHdFl.js"),[])},{id:"mermaid",name:"Mermaid",aliases:["mmd"],import:()=>p(()=>import("./mermaid-DrapLM8U.js"),[])},{id:"mipsasm",name:"MIPS Assembly",aliases:["mips"],import:()=>p(()=>import("./mipsasm-BElnB_7Q.js"),[])},{id:"mojo",name:"Mojo",import:()=>p(()=>import("./mojo-Dz6zCmiK.js"),[])},{id:"move",name:"Move",import:()=>p(()=>import("./move-Dvu4btzz.js"),[])},{id:"narrat",name:"Narrat Language",aliases:["nar"],import:()=>p(()=>import("./narrat-Cy2k80UN.js"),[])},{id:"nextflow",name:"Nextflow",aliases:["nf"],import:()=>p(()=>import("./nextflow-BO4ujnzu.js"),[])},{id:"nginx",name:"Nginx",import:()=>p(()=>import("./nginx-XmDIhN78.js"),__vite__mapDeps([166,134,123]))},{id:"nim",name:"Nim",import:()=>p(()=>import("./nim-Cm6-Nayq.js"),__vite__mapDeps([167,123,98,99,100,104,105,122,137]))},{id:"nix",name:"Nix",import:()=>p(()=>import("./nix-DcZRBjkC.js"),[])},{id:"nushell",name:"nushell",aliases:["nu"],import:()=>p(()=>import("./nushell-Dqv-0Q5X.js"),[])},{id:"objective-c",name:"Objective-C",aliases:["objc"],import:()=>p(()=>import("./objective-c-sgtl-PdD.js"),[])},{id:"objective-cpp",name:"Objective-C++",import:()=>p(()=>import("./objective-cpp-BTQ37cYs.js"),[])},{id:"ocaml",name:"OCaml",import:()=>p(()=>import("./ocaml-BvBP9Lm0.js"),[])},{id:"openscad",name:"OpenSCAD",aliases:["scad"],import:()=>p(()=>import("./openscad-Dmi2c_42.js"),[])},{id:"pascal",name:"Pascal",import:()=>p(()=>import("./pascal-DYjw0AuS.js"),[])},{id:"perl",name:"Perl",import:()=>p(()=>import("./perl-Djxv1YJ9.js"),__vite__mapDeps([168,98,99,100,104,105,113]))},{id:"php",name:"PHP",import:()=>p(()=>import("./php-DEfiO3Bd.js"),__vite__mapDeps([169,98,99,100,104,105,113,106]))},{id:"pkl",name:"Pkl",import:()=>p(()=>import("./pkl-Cij4Vm9z.js"),[])},{id:"plsql",name:"PL/SQL",import:()=>p(()=>import("./plsql-Bd6NdBJI.js"),[])},{id:"po",name:"Gettext PO",aliases:["pot","potx"],import:()=>p(()=>import("./po-CUhVi7la.js"),[])},{id:"polar",name:"Polar",import:()=>p(()=>import("./polar-B-qJ3AIy.js"),[])},{id:"postcss",name:"PostCSS",import:()=>p(()=>import("./postcss-BSGhOJ4k.js"),[])},{id:"powerquery",name:"PowerQuery",import:()=>p(()=>import("./powerquery-CC1XieQO.js"),[])},{id:"powershell",name:"PowerShell",aliases:["ps","ps1"],import:()=>p(()=>import("./powershell-DdRAnR4Z.js"),[])},{id:"prisma",name:"Prisma",import:()=>p(()=>import("./prisma-C0hJlfqX.js"),[])},{id:"prolog",name:"Prolog",import:()=>p(()=>import("./prolog-bSi0SE3D.js"),[])},{id:"proto",name:"Protocol Buffer 3",aliases:["protobuf"],import:()=>p(()=>import("./proto-DIGPV07t.js"),[])},{id:"pug",name:"Pug",aliases:["jade"],import:()=>p(()=>import("./pug-ClQUpJlV.js"),__vite__mapDeps([170,99,100,98]))},{id:"puppet",name:"Puppet",import:()=>p(()=>import("./puppet-ja2MI9-b.js"),[])},{id:"purescript",name:"PureScript",import:()=>p(()=>import("./purescript-CxgsQa43.js"),[])},{id:"python",name:"Python",aliases:["py"],import:()=>p(()=>import("./python-DgE28U1V.js"),[])},{id:"qml",name:"QML",import:()=>p(()=>import("./qml-BEkX6VoX.js"),__vite__mapDeps([171,99]))},{id:"qmldir",name:"QML Directory",import:()=>p(()=>import("./qmldir-DNYHzgow.js"),[])},{id:"qss",name:"Qt Style Sheets",import:()=>p(()=>import("./qss-BZsEMKxJ.js"),[])},{id:"r",name:"R",import:()=>p(()=>import("./r-BfG_C0qz.js"),[])},{id:"racket",name:"Racket",import:()=>p(()=>import("./racket-CzHBKLyy.js"),[])},{id:"raku",name:"Raku",aliases:["perl6"],import:()=>p(()=>import("./raku-CPccoUN1.js"),[])},{id:"razor",name:"ASP.NET Razor",import:()=>p(()=>import("./razor-8rj0VRTp.js"),__vite__mapDeps([172,98,99,100,173]))},{id:"reg",name:"Windows Registry Script",import:()=>p(()=>import("./reg-DkqHJyC0.js"),[])},{id:"regexp",name:"RegExp",aliases:["regex"],import:()=>p(()=>import("./regexp-BW_zLBm-.js"),[])},{id:"rel",name:"Rel",import:()=>p(()=>import("./rel-BIqKdwke.js"),[])},{id:"riscv",name:"RISC-V",import:()=>p(()=>import("./riscv-s6spwTFp.js"),[])},{id:"rosmsg",name:"ROS Interface",import:()=>p(()=>import("./rosmsg-TcL_zzr8.js"),[])},{id:"rst",name:"reStructuredText",import:()=>p(()=>import("./rst-8IYWyo0X.js"),__vite__mapDeps([174,112,98,99,100,120,121,122,123,113,117,125,135,175,130,131,104,105,132,108,133,110,134]))},{id:"ruby",name:"Ruby",aliases:["rb"],import:()=>p(()=>import("./ruby-CHyTNJrF.js"),__vite__mapDeps([130,98,99,100,131,104,105,113,132,108,133,110,120,121,122,123,125,134,135]))},{id:"rust",name:"Rust",aliases:["rs"],import:()=>p(()=>import("./rust-DJErdhjk.js"),[])},{id:"sas",name:"SAS",import:()=>p(()=>import("./sas-BZeeyq_z.js"),__vite__mapDeps([176,113]))},{id:"sass",name:"Sass",import:()=>p(()=>import("./sass-CIfQ9yqV.js"),[])},{id:"scala",name:"Scala",import:()=>p(()=>import("./scala-CWwlNtab.js"),[])},{id:"scheme",name:"Scheme",import:()=>p(()=>import("./scheme-ByM66cy_.js"),[])},{id:"scss",name:"SCSS",import:()=>p(()=>import("./scss-Dk05w39G.js"),__vite__mapDeps([102,100]))},{id:"sdbl",name:"1C (Query)",aliases:["1c-query"],import:()=>p(()=>import("./sdbl-C5Q1usnU.js"),[])},{id:"shaderlab",name:"ShaderLab",aliases:["shader"],import:()=>p(()=>import("./shaderlab-DNkMdb2B.js"),__vite__mapDeps([177,178]))},{id:"shellscript",name:"Shell",aliases:["bash","sh","shell","zsh"],import:()=>p(()=>import("./shellscript-CE-5zpiL.js"),[])},{id:"shellsession",name:"Shell Session",aliases:["console"],import:()=>p(()=>import("./shellsession-BhddCRKA.js"),__vite__mapDeps([179,125]))},{id:"smalltalk",name:"Smalltalk",import:()=>p(()=>import("./smalltalk-GKfhTxrk.js"),[])},{id:"solidity",name:"Solidity",import:()=>p(()=>import("./solidity-DanOLEvk.js"),[])},{id:"soy",name:"Closure Templates",aliases:["closure-templates"],import:()=>p(()=>import("./soy-C6ERzLIv.js"),__vite__mapDeps([180,98,99,100]))},{id:"sparql",name:"SPARQL",import:()=>p(()=>import("./sparql-CHK3vDkL.js"),__vite__mapDeps([181,182]))},{id:"splunk",name:"Splunk Query Language",aliases:["spl"],import:()=>p(()=>import("./splunk-YU1HCmJX.js"),[])},{id:"sql",name:"SQL",import:()=>p(()=>import("./sql-CKXjX23X.js"),[])},{id:"ssh-config",name:"SSH Config",import:()=>p(()=>import("./ssh-config-Cpnw3KEt.js"),[])},{id:"stata",name:"Stata",import:()=>p(()=>import("./stata-BJqnY-gO.js"),__vite__mapDeps([183,113]))},{id:"stylus",name:"Stylus",aliases:["styl"],import:()=>p(()=>import("./stylus-CHekGIgu.js"),[])},{id:"svelte",name:"Svelte",import:()=>p(()=>import("./svelte-DmnhoTkn.js"),__vite__mapDeps([184,99,108,100,109]))},{id:"swift",name:"Swift",import:()=>p(()=>import("./swift-Deru3G9w.js"),[])},{id:"system-verilog",name:"SystemVerilog",import:()=>p(()=>import("./system-verilog-rKNYENrf.js"),[])},{id:"systemd",name:"Systemd Units",import:()=>p(()=>import("./systemd-C1FfcI00.js"),[])},{id:"talonscript",name:"TalonScript",aliases:["talon"],import:()=>p(()=>import("./talonscript-bksoRmW6.js"),[])},{id:"tasl",name:"Tasl",import:()=>p(()=>import("./tasl-Bl4tsGRM.js"),[])},{id:"tcl",name:"Tcl",import:()=>p(()=>import("./tcl-B2_VAYrd.js"),[])},{id:"templ",name:"Templ",import:()=>p(()=>import("./templ-CyHhV9jl.js"),__vite__mapDeps([185,186,99,100]))},{id:"terraform",name:"Terraform",aliases:["tf","tfvars"],import:()=>p(()=>import("./terraform-Ba94thAr.js"),[])},{id:"tex",name:"TeX",import:()=>p(()=>import("./tex-DZ7Smwga.js"),__vite__mapDeps([161,159]))},{id:"toml",name:"TOML",import:()=>p(()=>import("./toml-Btlk-g9G.js"),[])},{id:"ts-tags",name:"TypeScript with Tags",aliases:["lit"],import:()=>p(()=>import("./ts-tags-DMPjx__B.js"),__vite__mapDeps([187,108,100,99,122,123,98,113,104,105]))},{id:"tsv",name:"TSV",import:()=>p(()=>import("./tsv-DYfmKMIW.js"),[])},{id:"tsx",name:"TSX",import:()=>p(()=>import("./tsx-Dio8iE-N.js"),[])},{id:"turtle",name:"Turtle",import:()=>p(()=>import("./turtle-whXsfw69.js"),[])},{id:"twig",name:"Twig",import:()=>p(()=>import("./twig-vsFUeHgy.js"),__vite__mapDeps([188,100,99,102,169,98,104,105,113,106,117,130,131,132,108,133,110,120,121,122,123,125,134,135]))},{id:"typescript",name:"TypeScript",aliases:["ts","cts","mts"],import:()=>p(()=>import("./typescript-DttGkNCf.js"),[])},{id:"typespec",name:"TypeSpec",aliases:["tsp"],import:()=>p(()=>import("./typespec-C_z-8Pri.js"),[])},{id:"typst",name:"Typst",aliases:["typ"],import:()=>p(()=>import("./typst-D2RORpaG.js"),[])},{id:"v",name:"V",import:()=>p(()=>import("./v-CvM42WIw.js"),[])},{id:"vala",name:"Vala",import:()=>p(()=>import("./vala-B_5xOBNr.js"),[])},{id:"vb",name:"Visual Basic",aliases:["cmd"],import:()=>p(()=>import("./vb-BVDm3zBt.js"),[])},{id:"verilog",name:"Verilog",import:()=>p(()=>import("./verilog-D5iownw6.js"),[])},{id:"vhdl",name:"VHDL",import:()=>p(()=>import("./vhdl-Bmgbkl_-.js"),[])},{id:"viml",name:"Vim Script",aliases:["vim","vimscript"],import:()=>p(()=>import("./viml-3ZODU9FQ.js"),[])},{id:"vue",name:"Vue",import:()=>p(()=>import("./vue-BJuclMoA.js"),__vite__mapDeps([189,100,99,108,106,112,98]))},{id:"vue-html",name:"Vue HTML",import:()=>p(()=>import("./vue-html-CRAum25o.js"),__vite__mapDeps([190,189,100,99,108,106,112,98]))},{id:"vue-vine",name:"Vue Vine",import:()=>p(()=>import("./vue-vine-CDS6dxm6.js"),__vite__mapDeps([191,100,102,164,192,109,189,99,108,106,112,98]))},{id:"vyper",name:"Vyper",aliases:["vy"],import:()=>p(()=>import("./vyper-B6NKdirK.js"),[])},{id:"wasm",name:"WebAssembly",import:()=>p(()=>import("./wasm-LUzQYg3H.js"),[])},{id:"wenyan",name:"Wenyan",aliases:["文言"],import:()=>p(()=>import("./wenyan-8fXatRyt.js"),[])},{id:"wgsl",name:"WGSL",import:()=>p(()=>import("./wgsl-CECC3vJ5.js"),[])},{id:"wikitext",name:"Wikitext",aliases:["mediawiki","wiki"],import:()=>p(()=>import("./wikitext-BaRWL9sq.js"),[])},{id:"wit",name:"WebAssembly Interface Types",import:()=>p(()=>import("./wit-MEd50GYB.js"),[])},{id:"wolfram",name:"Wolfram",aliases:["wl"],import:()=>p(()=>import("./wolfram-CmMaIVaG.js"),[])},{id:"xml",name:"XML",import:()=>p(()=>import("./xml-DtyAt_xK.js"),__vite__mapDeps([104,105]))},{id:"xsl",name:"XSL",import:()=>p(()=>import("./xsl-Btrj9DhN.js"),__vite__mapDeps([193,104,105]))},{id:"yaml",name:"YAML",aliases:["yml"],import:()=>p(()=>import("./yaml-B92AUxDB.js"),[])},{id:"zenscript",name:"ZenScript",import:()=>p(()=>import("./zenscript-Dja4fBOE.js"),[])},{id:"zig",name:"Zig",import:()=>p(()=>import("./zig-LhWa2ADv.js"),[])}],JO=Object.fromEntries(Iy.map(e=>[e.id,e.import])),UO=Object.fromEntries(Iy.flatMap(e=>e.aliases?.map(A=>[A,e.import])||[])),ly={...JO,...UO},KO=[{id:"andromeeda",displayName:"Andromeeda",type:"dark",import:()=>p(()=>import("./andromeeda-C-Jbm3Hp.js"),[])},{id:"aurora-x",displayName:"Aurora X",type:"dark",import:()=>p(()=>import("./aurora-x-D-2ljcwZ.js"),[])},{id:"ayu-dark",displayName:"Ayu Dark",type:"dark",import:()=>p(()=>import("./ayu-dark-Cv9koXgw.js"),[])},{id:"catppuccin-frappe",displayName:"Catppuccin Frappé",type:"dark",import:()=>p(()=>import("./catppuccin-frappe-DFWUc33u.js"),[])},{id:"catppuccin-latte",displayName:"Catppuccin Latte",type:"light",import:()=>p(()=>import("./catppuccin-latte-C9dUb6Cb.js"),[])},{id:"catppuccin-macchiato",displayName:"Catppuccin Macchiato",type:"dark",import:()=>p(()=>import("./catppuccin-macchiato-DQyhUUbL.js"),[])},{id:"catppuccin-mocha",displayName:"Catppuccin Mocha",type:"dark",import:()=>p(()=>import("./catppuccin-mocha-D87Tk5Gz.js"),[])},{id:"dark-plus",displayName:"Dark Plus",type:"dark",import:()=>p(()=>import("./dark-plus-C3mMm8J8.js"),[])},{id:"dracula",displayName:"Dracula Theme",type:"dark",import:()=>p(()=>import("./dracula-BzJJZx-M.js"),[])},{id:"dracula-soft",displayName:"Dracula Theme Soft",type:"dark",import:()=>p(()=>import("./dracula-soft-BXkSAIEj.js"),[])},{id:"everforest-dark",displayName:"Everforest Dark",type:"dark",import:()=>p(()=>import("./everforest-dark-BgDCqdQA.js"),[])},{id:"everforest-light",displayName:"Everforest Light",type:"light",import:()=>p(()=>import("./everforest-light-C8M2exoo.js"),[])},{id:"github-dark",displayName:"GitHub Dark",type:"dark",import:()=>p(()=>import("./github-dark-DHJKELXO.js"),[])},{id:"github-dark-default",displayName:"GitHub Dark Default",type:"dark",import:()=>p(()=>import("./github-dark-default-Cuk6v7N8.js"),[])},{id:"github-dark-dimmed",displayName:"GitHub Dark Dimmed",type:"dark",import:()=>p(()=>import("./github-dark-dimmed-DH5Ifo-i.js"),[])},{id:"github-dark-high-contrast",displayName:"GitHub Dark High Contrast",type:"dark",import:()=>p(()=>import("./github-dark-high-contrast-E3gJ1_iC.js"),[])},{id:"github-light",displayName:"GitHub Light",type:"light",import:()=>p(()=>import("./github-light-DAi9KRSo.js"),[])},{id:"github-light-default",displayName:"GitHub Light Default",type:"light",import:()=>p(()=>import("./github-light-default-D7oLnXFd.js"),[])},{id:"github-light-high-contrast",displayName:"GitHub Light High Contrast",type:"light",import:()=>p(()=>import("./github-light-high-contrast-BfjtVDDH.js"),[])},{id:"gruvbox-dark-hard",displayName:"Gruvbox Dark Hard",type:"dark",import:()=>p(()=>import("./gruvbox-dark-hard-CFHQjOhq.js"),[])},{id:"gruvbox-dark-medium",displayName:"Gruvbox Dark Medium",type:"dark",import:()=>p(()=>import("./gruvbox-dark-medium-GsRaNv29.js"),[])},{id:"gruvbox-dark-soft",displayName:"Gruvbox Dark Soft",type:"dark",import:()=>p(()=>import("./gruvbox-dark-soft-CVdnzihN.js"),[])},{id:"gruvbox-light-hard",displayName:"Gruvbox Light Hard",type:"light",import:()=>p(()=>import("./gruvbox-light-hard-CH1njM8p.js"),[])},{id:"gruvbox-light-medium",displayName:"Gruvbox Light Medium",type:"light",import:()=>p(()=>import("./gruvbox-light-medium-DRw_LuNl.js"),[])},{id:"gruvbox-light-soft",displayName:"Gruvbox Light Soft",type:"light",import:()=>p(()=>import("./gruvbox-light-soft-hJgmCMqR.js"),[])},{id:"houston",displayName:"Houston",type:"dark",import:()=>p(()=>import("./houston-DnULxvSX.js"),[])},{id:"kanagawa-dragon",displayName:"Kanagawa Dragon",type:"dark",import:()=>p(()=>import("./kanagawa-dragon-CkXjmgJE.js"),[])},{id:"kanagawa-lotus",displayName:"Kanagawa Lotus",type:"light",import:()=>p(()=>import("./kanagawa-lotus-CfQXZHmo.js"),[])},{id:"kanagawa-wave",displayName:"Kanagawa Wave",type:"dark",import:()=>p(()=>import("./kanagawa-wave-DWedfzmr.js"),[])},{id:"laserwave",displayName:"LaserWave",type:"dark",import:()=>p(()=>import("./laserwave-DUszq2jm.js"),[])},{id:"light-plus",displayName:"Light Plus",type:"light",import:()=>p(()=>import("./light-plus-B7mTdjB0.js"),[])},{id:"material-theme",displayName:"Material Theme",type:"dark",import:()=>p(()=>import("./material-theme-D5KoaKCx.js"),[])},{id:"material-theme-darker",displayName:"Material Theme Darker",type:"dark",import:()=>p(()=>import("./material-theme-darker-BfHTSMKl.js"),[])},{id:"material-theme-lighter",displayName:"Material Theme Lighter",type:"light",import:()=>p(()=>import("./material-theme-lighter-B0m2ddpp.js"),[])},{id:"material-theme-ocean",displayName:"Material Theme Ocean",type:"dark",import:()=>p(()=>import("./material-theme-ocean-CyktbL80.js"),[])},{id:"material-theme-palenight",displayName:"Material Theme Palenight",type:"dark",import:()=>p(()=>import("./material-theme-palenight-Csfq5Kiy.js"),[])},{id:"min-dark",displayName:"Min Dark",type:"dark",import:()=>p(()=>import("./min-dark-CafNBF8u.js"),[])},{id:"min-light",displayName:"Min Light",type:"light",import:()=>p(()=>import("./min-light-CTRr51gU.js"),[])},{id:"monokai",displayName:"Monokai",type:"dark",import:()=>p(()=>import("./monokai-D4h5O-jR.js"),[])},{id:"night-owl",displayName:"Night Owl",type:"dark",import:()=>p(()=>import("./night-owl-C39BiMTA.js"),[])},{id:"nord",displayName:"Nord",type:"dark",import:()=>p(()=>import("./nord-Ddv68eIx.js"),[])},{id:"one-dark-pro",displayName:"One Dark Pro",type:"dark",import:()=>p(()=>import("./one-dark-pro-DVMEJ2y_.js"),[])},{id:"one-light",displayName:"One Light",type:"light",import:()=>p(()=>import("./one-light-PoHY5YXO.js"),[])},{id:"plastic",displayName:"Plastic",type:"dark",import:()=>p(()=>import("./plastic-3e1v2bzS.js"),[])},{id:"poimandres",displayName:"Poimandres",type:"dark",import:()=>p(()=>import("./poimandres-CS3Unz2-.js"),[])},{id:"red",displayName:"Red",type:"dark",import:()=>p(()=>import("./red-bN70gL4F.js"),[])},{id:"rose-pine",displayName:"Rosé Pine",type:"dark",import:()=>p(()=>import("./rose-pine-qdsjHGoJ.js"),[])},{id:"rose-pine-dawn",displayName:"Rosé Pine Dawn",type:"light",import:()=>p(()=>import("./rose-pine-dawn-DHQR4-dF.js"),[])},{id:"rose-pine-moon",displayName:"Rosé Pine Moon",type:"dark",import:()=>p(()=>import("./rose-pine-moon-D4_iv3hh.js"),[])},{id:"slack-dark",displayName:"Slack Dark",type:"dark",import:()=>p(()=>import("./slack-dark-BthQWCQV.js"),[])},{id:"slack-ochin",displayName:"Slack Ochin",type:"light",import:()=>p(()=>import("./slack-ochin-DqwNpetd.js"),[])},{id:"snazzy-light",displayName:"Snazzy Light",type:"light",import:()=>p(()=>import("./snazzy-light-Bw305WKR.js"),[])},{id:"solarized-dark",displayName:"Solarized Dark",type:"dark",import:()=>p(()=>import("./solarized-dark-DXbdFlpD.js"),[])},{id:"solarized-light",displayName:"Solarized Light",type:"light",import:()=>p(()=>import("./solarized-light-L9t79GZl.js"),[])},{id:"synthwave-84",displayName:"Synthwave '84",type:"dark",import:()=>p(()=>import("./synthwave-84-CbfX1IO0.js"),[])},{id:"tokyo-night",displayName:"Tokyo Night",type:"dark",import:()=>p(()=>import("./tokyo-night-hegEt444.js"),[])},{id:"vesper",displayName:"Vesper",type:"dark",import:()=>p(()=>import("./vesper-DU1UobuO.js"),[])},{id:"vitesse-black",displayName:"Vitesse Black",type:"dark",import:()=>p(()=>import("./vitesse-black-Bkuqu6BP.js"),[])},{id:"vitesse-dark",displayName:"Vitesse Dark",type:"dark",import:()=>p(()=>import("./vitesse-dark-D0r3Knsf.js"),[])},{id:"vitesse-light",displayName:"Vitesse Light",type:"light",import:()=>p(()=>import("./vitesse-light-CVO1_9PV.js"),[])}],cy=Object.fromEntries(KO.map(e=>[e.id,e.import]));class du extends Error{constructor(A){super(A),this.name="ShikiError"}}function LO(){return 2147483648}function RO(){return typeof performance<"u"?performance.now():Date.now()}const OO=(e,A)=>e+(A-e%A)%A;async function qO(e){let A,t;const r={};function n(E){t=E,r.HEAPU8=new Uint8Array(E),r.HEAPU32=new Uint32Array(E)}function i(E,I,c){r.HEAPU8.copyWithin(E,I,I+c)}function o(E){try{return A.grow(E-t.byteLength+65535>>>16),n(A.buffer),1}catch{}}function g(E){const I=r.HEAPU8.length;E=E>>>0;const c=LO();if(E>c)return!1;for(let u=1;u<=4;u*=2){let h=I*(1+.2/u);h=Math.min(h,E+100663296);const d=Math.min(c,OO(Math.max(E,h),65536));if(o(d))return!0}return!1}const Q=typeof TextDecoder<"u"?new TextDecoder("utf8"):void 0;function B(E,I,c=1024){const u=I+c;let h=I;for(;E[h]&&!(h>=u);)++h;if(h-I>16&&E.buffer&&Q)return Q.decode(E.subarray(I,h));let d="";for(;I>10,56320|N&1023)}}return d}function a(E,I){return E?B(r.HEAPU8,E,I):""}const s={emscripten_get_now:RO,emscripten_memcpy_big:i,emscripten_resize_heap:g,fd_write:()=>0};async function C(){const I=await e({env:s,wasi_snapshot_preview1:s});A=I.memory,n(A.buffer),Object.assign(r,I),r.UTF8ToString=a}return await C(),r}var TO=Object.defineProperty,HO=(e,A,t)=>A in e?TO(e,A,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[A]=t,Nt=(e,A,t)=>HO(e,typeof A!="symbol"?A+"":A,t);let Jt=null;function YO(e){throw new du(e.UTF8ToString(e.getLastOnigError()))}class fE{constructor(A){Nt(this,"utf16Length"),Nt(this,"utf8Length"),Nt(this,"utf16Value"),Nt(this,"utf8Value"),Nt(this,"utf16OffsetToUtf8"),Nt(this,"utf8OffsetToUtf16");const t=A.length,r=fE._utf8ByteLength(A),n=r!==t,i=n?new Uint32Array(t+1):null;n&&(i[t]=r);const o=n?new Uint32Array(r+1):null;n&&(o[r]=t);const g=new Uint8Array(r);let Q=0;for(let B=0;B=55296&&a<=56319&&B+1=56320&&E<=57343&&(s=(a-55296<<10)+65536|E-56320,C=!0)}n&&(i[B]=Q,C&&(i[B+1]=Q),s<=127?o[Q+0]=B:s<=2047?(o[Q+0]=B,o[Q+1]=B):s<=65535?(o[Q+0]=B,o[Q+1]=B,o[Q+2]=B):(o[Q+0]=B,o[Q+1]=B,o[Q+2]=B,o[Q+3]=B)),s<=127?g[Q++]=s:s<=2047?(g[Q++]=192|(s&1984)>>>6,g[Q++]=128|(s&63)>>>0):s<=65535?(g[Q++]=224|(s&61440)>>>12,g[Q++]=128|(s&4032)>>>6,g[Q++]=128|(s&63)>>>0):(g[Q++]=240|(s&1835008)>>>18,g[Q++]=128|(s&258048)>>>12,g[Q++]=128|(s&4032)>>>6,g[Q++]=128|(s&63)>>>0),C&&B++}this.utf16Length=t,this.utf8Length=r,this.utf16Value=A,this.utf8Value=g,this.utf16OffsetToUtf8=i,this.utf8OffsetToUtf16=o}static _utf8ByteLength(A){let t=0;for(let r=0,n=A.length;r=55296&&i<=56319&&r+1=56320&&Q<=57343&&(o=(i-55296<<10)+65536|Q-56320,g=!0)}o<=127?t+=1:o<=2047?t+=2:o<=65535?t+=3:t+=4,g&&r++}return t}createString(A){const t=A.omalloc(this.utf8Length);return A.HEAPU8.set(this.utf8Value,t),t}}const wE=class Cn{constructor(A){if(Nt(this,"id",++Cn.LAST_ID),Nt(this,"_onigBinding"),Nt(this,"content"),Nt(this,"utf16Length"),Nt(this,"utf8Length"),Nt(this,"utf16OffsetToUtf8"),Nt(this,"utf8OffsetToUtf16"),Nt(this,"ptr"),!Jt)throw new du("Must invoke loadWasm first.");this._onigBinding=Jt,this.content=A;const t=new fE(A);this.utf16Length=t.utf16Length,this.utf8Length=t.utf8Length,this.utf16OffsetToUtf8=t.utf16OffsetToUtf8,this.utf8OffsetToUtf16=t.utf8OffsetToUtf16,this.utf8Length<1e4&&!Cn._sharedPtrInUse?(Cn._sharedPtr||(Cn._sharedPtr=Jt.omalloc(1e4)),Cn._sharedPtrInUse=!0,Jt.HEAPU8.set(t.utf8Value,Cn._sharedPtr),this.ptr=Cn._sharedPtr):this.ptr=t.createString(Jt)}convertUtf8OffsetToUtf16(A){return this.utf8OffsetToUtf16?A<0?0:A>this.utf8Length?this.utf16Length:this.utf8OffsetToUtf16[A]:A}convertUtf16OffsetToUtf8(A){return this.utf16OffsetToUtf8?A<0?0:A>this.utf16Length?this.utf8Length:this.utf16OffsetToUtf8[A]:A}dispose(){this.ptr===Cn._sharedPtr?Cn._sharedPtrInUse=!1:this._onigBinding.ofree(this.ptr)}};Nt(wE,"LAST_ID",0);Nt(wE,"_sharedPtr",0);Nt(wE,"_sharedPtrInUse",!1);let uy=wE;class zO{constructor(A){if(Nt(this,"_onigBinding"),Nt(this,"_ptr"),!Jt)throw new du("Must invoke loadWasm first.");const t=[],r=[];for(let g=0,Q=A.length;g{let r=e;return r=await r,typeof r=="function"&&(r=await r(t)),typeof r=="function"&&(r=await r(t)),PO(r)?r=await r.instantiator(t):_O(r)?r=await r.default(t):(jO(r)&&(r=r.data),VO(r)?typeof WebAssembly.instantiateStreaming=="function"?r=await XO(r)(t):r=await $O(r)(t):WO(r)?r=await rI(r)(t):r instanceof WebAssembly.Module?r=await rI(r)(t):"default"in r&&r.default instanceof WebAssembly.Module&&(r=await rI(r.default)(t))),"instance"in r&&(r=r.instance),"exports"in r&&(r=r.exports),r})}return ba=A(),ba}function rI(e){return A=>WebAssembly.instantiate(e,A)}function XO(e){return A=>WebAssembly.instantiateStreaming(e,A)}function $O(e){return async A=>{const t=await e.arrayBuffer();return WebAssembly.instantiate(t,A)}}async function Aq(e){return e&&await ZO(e),{createScanner(A){return new zO(A.map(t=>typeof t=="string"?t:t.source))},createString(A){return new uy(A)}}}const eq=SO({langs:ly,themes:cy,engine:()=>Aq(p(()=>import("./wasm-CG6Dc4jp.js"),[]))}),XD=4294967295;class tq{constructor(A,t={}){this.patterns=A,this.options=t;const{forgiving:r=!1,cache:n,regexConstructor:i}=t;if(!i)throw new Error("Option `regexConstructor` is not provided");this.regexps=A.map(o=>{if(typeof o!="string")return o;const g=n?.get(o);if(g){if(g instanceof RegExp)return g;if(r)return null;throw g}try{const Q=i(o);return n?.set(o,Q),Q}catch(Q){if(n?.set(o,Q),r)return null;throw Q}})}regexps;findNextMatchSync(A,t,r){const n=typeof A=="string"?A:A.content,i=[];function o(g,Q,B=0){return{index:g,captureIndices:Q.indices.map(a=>a==null?{start:XD,end:XD,length:0}:{start:a[0]+B,end:a[1]+B,length:a[1]-a[0]})}}for(let g=0;gQ[1].index));for(const[Q,B,a]of i)if(B.index===g)return o(Q,B,a)}return null}}function rq(e,A){return KR(e,{global:!0,hasIndices:!0,lazyCompileLength:3e3,rules:{allowOrphanBackrefs:!0,asciiWordBoundaries:!0,captureGroup:!0,recursionLimit:5,singleline:!0},...A})}function nq(e={}){const A=Object.assign({target:"auto",cache:new Map},e);return A.regexConstructor||=t=>rq(t,{target:A.target}),{createScanner(t){return new tq(t,A)},createString(t){return{content:t}}}}async function dy(e){if(ry())throw new Error(`resolveLanguage("${e}") cannot be called from a worker context. Languages must be pre-resolved on the main thread and passed to the worker via the resolvedLanguages parameter.`);const A=eI.get(e);if(A!=null)return A;try{const t=ly[e];if(t==null)throw new Error(`resolveLanguage: "${e}" not found in bundled languages`);const r=t().then(({default:n})=>{const i={name:e,data:n};return xo.has(e)||xo.set(e,i),i});return eI.set(e,r),await r}finally{eI.delete(e)}}function hy(e){return xo.get(e)??dy(e)}const Ai=new Map,nI=new Map,pl=new Map,kl=new Set;function yl(e,A){e=Array.isArray(e)?e:[e];for(let t of e){let r;if(typeof t=="string"){if(r=Ai.get(t),r==null)throw new Error(`loadResolvedThemes: ${t} is not resolved, you must resolve it before calling loadResolvedThemes`)}else r=t,t=t.name,Ai.has(t)||Ai.set(t,r);kl.has(t)||(kl.add(t),A.loadThemeSync(r))}}async function Dy(e){if(ry())throw new Error(`resolveTheme("${e}") cannot be called from a worker context. Themes must be pre-resolved on the main thread and passed to the worker via the resolvedLanguages parameter.`);const A=nI.get(e);if(A!=null)return A;try{const t=pl.get(e)??cy[e];if(t==null)throw new Error(`resolveTheme: No valid loader for ${e}`);const r=t().then(i=>iq(e,"default"in i?i.default:i));nI.set(e,r);const n=await r;if(n.name!==e)throw new Error(`resolvedTheme: themeName: ${e} does not match theme.name: ${n.name}`);return Ai.set(n.name,n),n}finally{nI.delete(e)}}function iq(e,A){const t=Ai.get(e);return t??(A=DE(A),Ai.set(e,A),A)}function fy(e){return Ai.get(e)??Dy(e)}function hu(e,A){if(pl.has(e)){console.error("SharedHighlight.registerCustomTheme: theme name already registered",e);return}pl.set(e,A)}let ln;async function oB({themes:e,langs:A}){ln??=eq({themes:[],langs:["text"],engine:nq()});const t=oq(ln)?await ln:ln;ln=t;const r=[];for(const i of A){if(i==="text")continue;const o=hy(i);"then"in o?r.push(o):zD(o,t)}const n=[];for(const i of e){const o=fy(i);"then"in o?n.push(o):yl(o,ln)}return(r.length>0||n.length>0)&&await Promise.all([Promise.all(r).then(i=>{zD(i,t)}),Promise.all(n).then(i=>{yl(i,t)})]),t}function wy(){if(ln!=null&&!("then"in ln))return ln}function oq(e=ln){return e!=null&&"then"in e}hu("pierre-dark",()=>p(()=>import("./pierre-dark-BXuwtOqb.js"),[]));hu("pierre-light",()=>p(()=>import("./pierre-light-dckrK0oj.js"),[]));function gB(e=Vt){const A=[];return typeof e=="string"?A.push(e):(A.push(e.dark),A.push(e.light)),A}function jQ(e){for(const A of gB(e))if(!kl.has(A))return!1;return!0}function Ml(e){for(const A of e)if(!Ai.has(A))return!1;return!0}function Du(e,A){return e==null||A==null||typeof e=="string"||typeof A=="string"?e===A:e.dark===A.dark&&e.light===A.light}function Ti(e){return{type:"text",value:e}}function Fe({tagName:e,children:A=[],properties:t={}}){return{type:"element",tagName:e,properties:t,children:A}}function Nl({name:e,width:A=16,height:t=16,properties:r}){return Fe({tagName:"svg",properties:{width:A,height:t,viewBox:"0 0 16 16",...r},children:[Fe({tagName:"use",properties:{href:`#${e.replace(/^#/,"")}`}})]})}function gq(e){let A=e.children[0];for(;A!=null;){if(A.type==="element"&&A.tagName==="code")return A;"children"in A?A=A.children[0]:A=null}}function $a(e){return Fe({tagName:"div",children:[Fe({tagName:"div",children:e.annotations?.map(A=>Fe({tagName:"slot",properties:{name:A}})),properties:{"data-annotation-content":""}})],properties:{"data-line-annotation":`${e.hunkIndex},${e.lineIndex}`}})}function Qq(e){switch(e){case"file":return"diffs-icon-file-code";case"change":return"diffs-icon-symbol-modified";case"new":return"diffs-icon-symbol-added";case"deleted":return"diffs-icon-symbol-deleted";case"rename-pure":case"rename-changed":return"diffs-icon-symbol-moved"}}function my({fileOrDiff:e,themeStyles:A,themeType:t}){const r="type"in e?e:void 0,n={"data-diffs-header":"","data-change-type":r?.type,"data-theme-type":t!=="system"?t:void 0,style:A};return Fe({tagName:"div",children:[Bq({name:e.name,prevName:"prevName"in e?e.prevName:void 0,iconType:r?.type??"file"}),aq(r)],properties:n})}function Bq({name:e,prevName:A,iconType:t}){const r=[Nl({name:Qq(t),properties:{"data-change-icon":t}})];return A!=null&&(r.push(Fe({tagName:"div",children:[Ti(A)],properties:{"data-prev-name":""}})),r.push(Nl({name:"diffs-icon-arrow-right-short",properties:{"data-rename-icon":""}}))),r.push(Fe({tagName:"div",children:[Ti(e)],properties:{"data-title":""}})),Fe({tagName:"div",children:r,properties:{"data-header-content":""}})}function aq(e){const A=[];if(e!=null){let t=0,r=0;for(const n of e.hunks)t+=n.additionLines,r+=n.deletionLines;(r>0||t===0)&&A.push(Fe({tagName:"span",children:[Ti(`-${r}`)],properties:{"data-deletions-count":""}})),(t>0||r===0)&&A.push(Fe({tagName:"span",children:[Ti(`+${t}`)],properties:{"data-additions-count":""}}))}return A.push(Fe({tagName:"slot",properties:{name:Eu}})),Fe({tagName:"div",children:A,properties:{"data-metadata":""}})}function py(e){return Fe({tagName:"pre",properties:sq(e)})}function sq({diffIndicators:e,disableBackground:A,disableLineNumbers:t,overflow:r,split:n,themeType:i,themeStyles:o,totalLines:g}){const Q={"data-diffs":"","data-type":n?"split":"file","data-overflow":r,"data-disable-line-numbers":t?"":void 0,"data-background":A?void 0:"","data-indicators":e==="bars"||e==="classic"?e:void 0,"data-theme-type":i!=="system"?i:void 0,style:o,tabIndex:0};return Q.style+=`--diffs-min-number-column-width-default:${`${g}`.length}ch;`,Q}const hQ={"1c":"1c",abap:"abap",as:"actionscript-3",ada:"ada",adb:"ada",ads:"ada",adoc:"asciidoc",asciidoc:"asciidoc","component.html":"angular-html","component.ts":"angular-ts",conf:"nginx",htaccess:"apache",cls:"tex",trigger:"apex",apl:"apl",applescript:"applescript",scpt:"applescript",ara:"ara",asm:"asm",s:"riscv",astro:"astro",awk:"awk",bal:"ballerina",sh:"zsh",bash:"zsh",bat:"cmd",cmd:"cmd",be:"berry",beancount:"beancount",bib:"bibtex",bicep:"bicep","blade.php":"blade",bsl:"bsl",c:"c",h:"objective-cpp",cs:"csharp",cpp:"cpp",hpp:"cpp",cc:"cpp",cxx:"cpp",hh:"cpp",cdc:"cdc",cairo:"cairo",clar:"clarity",clj:"clojure",cljs:"clojure",cljc:"clojure",soy:"soy",cmake:"cmake","CMakeLists.txt":"cmake",cob:"cobol",cbl:"cobol",cobol:"cobol",CODEOWNERS:"codeowners",ql:"ql",coffee:"coffeescript",lisp:"lisp",cl:"lisp",lsp:"lisp",log:"log",v:"verilog",cql:"cql",cr:"crystal",css:"css",csv:"csv",cue:"cue",cypher:"cypher",cyp:"cypher",d:"d",dart:"dart",dax:"dax",desktop:"desktop",diff:"diff",patch:"diff",Dockerfile:"dockerfile",dockerfile:"dockerfile",env:"dotenv",dm:"dream-maker",edge:"edge",el:"emacs-lisp",ex:"elixir",exs:"elixir",elm:"elm",erb:"erb",erl:"erlang",hrl:"erlang",f:"fortran-fixed-form",for:"fortran-fixed-form",fs:"fsharp",fsi:"fsharp",fsx:"fsharp",f03:"f03",f08:"f08",f18:"f18",f77:"f77",f90:"fortran-free-form",f95:"fortran-free-form",fnl:"fennel",fish:"fish",ftl:"ftl",tres:"gdresource",res:"gdresource",gd:"gdscript",gdshader:"gdshader",gs:"genie",feature:"gherkin",COMMIT_EDITMSG:"git-commit","git-rebase-todo":"git-rebase",gjs:"glimmer-js",gleam:"gleam",gts:"glimmer-ts",glsl:"glsl",vert:"glsl",frag:"glsl",shader:"shaderlab",gp:"gnuplot",plt:"gnuplot",gnuplot:"gnuplot",go:"go",graphql:"graphql",gql:"graphql",groovy:"groovy",gvy:"groovy",hack:"hack",haml:"haml",hbs:"handlebars",handlebars:"handlebars",hs:"haskell",lhs:"haskell",hx:"haxe",hcl:"hcl",hjson:"hjson",hlsl:"hlsl",fx:"hlsl",html:"html",htm:"html",http:"http",rest:"http",hxml:"hxml",hy:"hy",imba:"imba",ini:"ini",cfg:"ini",jade:"pug",pug:"pug",java:"java",js:"javascript",mjs:"javascript",cjs:"javascript",jinja:"jinja",jinja2:"jinja",j2:"jinja",jison:"jison",jl:"julia",json:"json",json5:"json5",jsonc:"jsonc",jsonl:"jsonl",jsonnet:"jsonnet",libsonnet:"jsonnet",jssm:"jssm",jsx:"jsx",kt:"kotlin",kts:"kts",kql:"kusto",tex:"tex",ltx:"tex",lean:"lean4",less:"less",liquid:"liquid",lit:"lit",ll:"llvm",logo:"logo",lua:"lua",luau:"luau",Makefile:"makefile",mk:"makefile",makefile:"makefile",md:"markdown",markdown:"markdown",marko:"marko",m:"wolfram",mat:"matlab",mdc:"mdc",mdx:"mdx",wiki:"wikitext",mediawiki:"wikitext",mmd:"mermaid",mermaid:"mermaid",mips:"mipsasm",mojo:"mojo","🔥":"mojo",move:"move",nar:"narrat",nf:"nextflow",nim:"nim",nims:"nim",nimble:"nim",nix:"nix",nu:"nushell",mm:"objective-cpp",ml:"ocaml",mli:"ocaml",mll:"ocaml",mly:"ocaml",pas:"pascal",p:"pascal",pl:"prolog",pm:"perl",t:"perl",raku:"raku",p6:"raku",pl6:"raku",php:"php",phtml:"php",pls:"plsql",sql:"sql",po:"po",polar:"polar",pcss:"postcss",pot:"pot",potx:"potx",pq:"powerquery",pqm:"powerquery",ps1:"powershell",psm1:"powershell",psd1:"powershell",prisma:"prisma",pro:"prolog",P:"prolog",properties:"properties",proto:"protobuf",pp:"puppet",purs:"purescript",py:"python",pyw:"python",pyi:"python",qml:"qml",qmldir:"qmldir",qss:"qss",r:"r",R:"r",rkt:"racket",rktl:"racket",razor:"razor",cshtml:"razor",rb:"ruby",rbw:"ruby",reg:"reg",regex:"regexp",rel:"rel",rs:"rust",rst:"rst",rake:"ruby",gemspec:"ruby",sas:"sas",sass:"sass",scala:"scala",sc:"scala",scm:"scheme",ss:"scheme",sld:"scheme",scss:"scss",sdbl:"sdbl",shadergraph:"shader",st:"smalltalk",sol:"solidity",sparql:"sparql",rq:"sparql",spl:"splunk",config:"ssh-config",do:"stata",ado:"stata",dta:"stata",styl:"stylus",stylus:"stylus",svelte:"svelte",swift:"swift",sv:"system-verilog",svh:"system-verilog",service:"systemd",socket:"systemd",device:"systemd",timer:"systemd",talon:"talonscript",tasl:"tasl",tcl:"tcl",templ:"templ",tf:"tf",tfvars:"tfvars",toml:"toml",ts:"typescript",tsp:"typespec",tsv:"tsv",tsx:"tsx",ttl:"turtle",twig:"twig",typ:"typst",vv:"v",vala:"vala",vapi:"vala",vb:"vb",vbs:"vb",bas:"vb",vh:"verilog",vhd:"vhdl",vhdl:"vhdl",vim:"vimscript",vue:"vue","vine.ts":"vue-vine",vy:"vyper",wasm:"wasm",wat:"wasm",wy:"文言",wgsl:"wgsl",wit:"wit",wl:"wolfram",nb:"wolfram",xml:"xml",xsl:"xsl",xslt:"xsl",yaml:"yaml",yml:"yml",zs:"zenscript",zig:"zig",zsh:"zsh",sty:"tex"};function fn(e){if(hQ[e]!=null)return hQ[e];const A=e.match(/\.([^/\\]+\.[^/\\]+)$/);return A!=null&&hQ[A[1]]!=null?hQ[A[1]]??"text":hQ[e.match(/\.([^.]+)$/)?.[1]??""]??"text"}function ky(e,A){return{langs:[e??"text"],themes:gB(A.theme)}}function QB(e){return`annotation-${"side"in e?`${e.side}-`:""}${e.lineNumber}`}function Go(e){return e.replace(/\n$|\r\n$/,"")}function Eq(e,A,t){const r=typeof t.lineInfo=="function"?t.lineInfo(A):t.lineInfo[A];if(r==null)throw console.error({node:e,line:A,state:t}),new Error(`processLine: line ${A}, contains no state.lineInfo`);return e.tagName="span",e.properties["data-column-content"]="",e.children.length===0&&e.children.push(Ti(` `)),Fe({tagName:"div",children:[Fe({tagName:"span",children:[Fe({tagName:"span",children:[{type:"text",value:`${r.lineNumber}`}],properties:{"data-line-number-content":""}})],properties:{"data-column-number":""}}),e],properties:{"data-line":r.lineNumber,"data-alt-line":r.altLineNumber,"data-line-type":r.type,"data-line-index":r.lineIndex}})}function Cq(e={}){const{classPrefix:A="__shiki_",classSuffix:t="",classReplacer:r=g=>g}=e,n=new Map;function i(g){return Object.entries(g).map(([Q,B])=>`${Q}:${B}`).join(";")}function o(g){const Q=typeof g=="string"?g:i(g);let B=A+Iq(Q)+t;return B=r(B),n.has(B)||n.set(B,typeof g=="string"?g:{...g}),B}return{name:"@shikijs/transformers:style-to-class",pre(g){if(!g.properties.style)return;const Q=o(g.properties.style);delete g.properties.style,this.addClassToHast(g,Q)},tokens(g){for(const Q of g)for(const B of Q){if(!B.htmlStyle)continue;const a=o(B.htmlStyle);B.htmlStyle={},B.htmlAttrs||={},B.htmlAttrs.class?B.htmlAttrs.class+=` ${a}`:B.htmlAttrs.class=a}},getClassRegistry(){return n},getCSS(){let g="";for(const[Q,B]of n.entries())g+=`.${Q}{${typeof B=="string"?B:i(B)}}`;return g},clearRegistry(){n.clear()}}}function Iq(e,A=0){let t=3735928559^A,r=1103547991^A;for(let n=0,i;n>>16,2246822507),t^=Math.imul(r^r>>>13,3266489909),r=Math.imul(r^r>>>16,2246822507),r^=Math.imul(t^t>>>13,3266489909),(4294967296*(2097151&r)+(t>>>0)).toString(36).slice(0,6)}function yy(e=!1){const A={lineInfo:{}},t=[{line(r){return delete r.properties.class,r},pre(r){const n=gq(r),i=[];if(n!=null){let o=1;for(const g of n.children)g.type==="element"&&(i.push(Eq(g,o,A)),o++);n.children=i}return r}}];return e&&t.push(lq,$D),{state:A,transformers:t,toClass:$D}}const $D=Cq({classPrefix:"hl-"}),lq={name:"token-style-normalizer",tokens(e){for(const A of e)for(const t of A){if(t.htmlStyle!=null)continue;const r={};t.color!=null&&(r.color=t.color),t.bgColor!=null&&(r["background-color"]=t.bgColor),t.fontStyle!=null&&t.fontStyle!==0&&((t.fontStyle&1)!==0&&(r["font-style"]="italic"),(t.fontStyle&2)!==0&&(r["font-weight"]="bold"),(t.fontStyle&4)!==0&&(r["text-decoration"]="underline")),Object.keys(r).length>0&&(t.htmlStyle=r)}}};function cr(e="diffs"){return`--${e}-`}function My({theme:e=Vt,highlighter:A,prefix:t}){let r="";if(typeof e=="string"){const n=A.getTheme(e);r+=`color:${n.fg};`,r+=`background-color:${n.bg};`,r+=`${cr(t)}fg:${n.fg};`,r+=`${cr(t)}bg:${n.bg};`,r+=iI(n,t)}else{let n=A.getTheme(e.dark);r+=`${cr(t)}dark:${n.fg};`,r+=`${cr(t)}dark-bg:${n.bg};`,r+=iI(n,t,"dark"),n=A.getTheme(e.light),r+=`${cr(t)}light:${n.fg};`,r+=`${cr(t)}light-bg:${n.bg};`,r+=iI(n,t,"light")}return r}function iI(e,A,t){t=t!=null?`${t}-`:"";let r="";const n=e.colors?.["gitDecoration.addedResourceForeground"]??e.colors?.["terminal.ansiGreen"];n!=null&&(r+=`${cr(A)}${t}addition-color:${n};`);const i=e.colors?.["gitDecoration.deletedResourceForeground"]??e.colors?.["terminal.ansiRed"];i!=null&&(r+=`${cr(A)}${t}deletion-color:${i};`);const o=e.colors?.["gitDecoration.modifiedResourceForeground"]??e.colors?.["terminal.ansiBlue"];return o!=null&&(r+=`${cr(A)}${t}modified-color:${o};`),r}function vl(e){let A=e.children[0];for(;A!=null;){if(A.type==="element"&&A.tagName==="code")return A.children;"children"in A?A=A.children[0]:A=null}throw console.error(e),new Error("getLineNodes: Unable to find children")}function Ny(e,A,{theme:t=Vt,tokenizeMaxLineLength:r},n=!1){const{state:i,transformers:o}=yy(),g=n?"text":e.lang??fn(e.name),Q=(()=>{if(typeof t=="string")return A.getTheme(t).type})(),B=My({theme:t,highlighter:A});i.lineInfo=s=>({type:"context",lineIndex:s-1,lineNumber:s});const a=typeof t=="string"?{lang:g,theme:t,transformers:o,defaultColor:!1,cssVariablePrefix:cr(),tokenizeMaxLineLength:r}:{lang:g,themes:t,transformers:o,defaultColor:!1,cssVariablePrefix:cr(),tokenizeMaxLineLength:r};return{code:vl(A.codeToHast(Go(e.contents),a)),themeStyles:B,baseThemeType:Q}}var cq=class{highlighter;renderCache;computedLang="text";lineAnnotations={};constructor(e={theme:Vt},A,t){this.options=e,this.onRenderUpdate=A,this.workerManager=t,t?.isWorkingPool()!==!0&&(this.highlighter=jQ(e.theme??Vt)?wy():void 0)}setOptions(e){this.options=e}mergeOptions(e){this.options={...this.options,...e}}setThemeType(e){(this.options.themeType??"system")!==e&&this.mergeOptions({themeType:e})}setLineAnnotations(e){this.lineAnnotations={};for(const A of e){const t=this.lineAnnotations[A.lineNumber]??[];this.lineAnnotations[A.lineNumber]=t,t.push(A)}}cleanUp(){this.renderCache=void 0,this.highlighter=void 0,this.workerManager=void 0,this.onRenderUpdate=void 0}hydrate(e){const{options:A}=this.getRenderOptions(e);let t=this.workerManager?.getFileResultCache(e);t!=null&&!oI(A,t.options)&&(t=void 0),this.renderCache??={file:e,options:A,highlighted:!0,result:t?.result},this.workerManager?.isWorkingPool()===!0&&this.renderCache.result==null?this.workerManager.highlightFileAST(this,e):this.asyncHighlight(e).then(({result:r,options:n})=>{this.onHighlightSuccess(e,r,n)})}getRenderOptions(e){const A=(()=>{if(this.workerManager?.isWorkingPool()===!0)return this.workerManager.getFileRenderOptions();const{theme:r=Vt,tokenizeMaxLineLength:n=1e3}=this.options;return{theme:r,tokenizeMaxLineLength:n}})(),{renderCache:t}=this;return t?.result==null?{options:A,forceRender:!0}:e!==t.file||!oI(A,t.options)?{options:A,forceRender:!0}:{options:A,forceRender:!1}}renderFile(e=this.renderCache?.file){if(e==null)return;const A=this.workerManager?.getFileResultCache(e);A!=null&&this.renderCache==null&&(this.renderCache={file:e,highlighted:!0,...A});const{options:t,forceRender:r}=this.getRenderOptions(e);if(this.renderCache??={file:e,highlighted:!1,options:t,result:void 0},this.workerManager?.isWorkingPool()===!0)this.renderCache.result??=this.workerManager.getPlainFileAST(e),(!this.renderCache.highlighted||r)&&this.workerManager.highlightFileAST(this,e);else{this.computedLang=e.lang??fn(e.name);const n=this.highlighter!=null&&jQ(t.theme),i=this.highlighter!=null&&xs(this.computedLang);if(this.highlighter!=null&&n&&(r||!this.renderCache.highlighted&&i||this.renderCache.result==null)){const{result:o,options:g}=this.renderFileWithHighlighter(e,this.highlighter,!i);this.renderCache={file:e,options:g,highlighted:i,result:o}}(!n||!i)&&this.asyncHighlight(e).then(({result:o,options:g})=>{this.onHighlightSuccess(e,o,g)})}return this.renderCache.result!=null?this.processFileResult(this.renderCache.file,this.renderCache.result):void 0}async asyncRender(e){const{result:A}=await this.asyncHighlight(e);return this.processFileResult(e,A)}async asyncHighlight(e){this.computedLang=e.lang??fn(e.name);const A=this.highlighter!=null&&Ml(gB(this.options.theme)),t=this.highlighter!=null&&xs(this.computedLang);return(this.highlighter==null||!A||!t)&&(this.highlighter=await this.initializeHighlighter()),this.renderFileWithHighlighter(e,this.highlighter)}renderFileWithHighlighter(e,A,t=!1){const{options:r}=this.getRenderOptions(e);return{result:Ny(e,A,r,t),options:r}}processFileResult(e,A){const{disableFileHeader:t=!1}=this.options,r=[];let n=1;for(const i of A.code){r.push(i);const o=this.lineAnnotations[n];o!=null&&r.push($a({hunkIndex:0,lineIndex:n,annotations:o.map(g=>QB(g))})),n++}return{codeAST:r,preAST:this.createPreElement(A.code.length,A.themeStyles,A.baseThemeType),headerAST:t?void 0:this.renderHeader(e,A.themeStyles,A.baseThemeType),totalLines:A.code.length,themeStyles:A.themeStyles,baseThemeType:A.baseThemeType,css:""}}renderHeader(e,A,t){const{themeType:r="system"}=this.options;return my({fileOrDiff:e,themeStyles:A,themeType:t??r})}renderFullHTML(e){return Xn(this.renderFullAST(e))}renderFullAST(e,A=[]){return A.push(Fe({tagName:"code",children:e.codeAST,properties:{"data-code":""}})),{...e.preAST,children:A}}renderPartialHTML(e,A=!1){return Xn(A?Fe({tagName:"code",children:e,properties:{"data-code":""}}):e)}async initializeHighlighter(){return this.highlighter=await oB(ky(this.computedLang,this.options)),this.highlighter}onHighlightSuccess(e,A,t){if(this.renderCache==null)return;const r=this.renderCache.file!==e||!this.renderCache.highlighted||!oI(t,this.renderCache.options);this.renderCache={file:e,options:t,highlighted:!0,result:A},r&&this.onRenderUpdate?.()}onHighlightError(e){console.error(e)}createPreElement(e,A,t){const{disableLineNumbers:r=!1,overflow:n="scroll",themeType:i="system"}=this.options;return py({diffIndicators:"none",disableBackground:!0,disableLineNumbers:r,overflow:n,themeStyles:A,themeType:t??i,split:!1,totalLines:e})}};function oI(e,A){return Du(e.theme,A.theme)&&e.tokenizeMaxLineLength===A.tokenizeMaxLineLength}const vy=``;function bl(e,A){return e?.cacheKey===A?.cacheKey&&e?.contents===A?.contents&&e?.name===A?.name&&e?.lang===A?.lang}function by(e){const A=document.createElement("div");return A.dataset.annotationSlot="",A.slot=e,A.style.whiteSpace="normal",A}function As({pre:e,columnType:A}={}){const t=document.createElement("code");return t.dataset.code="",A!=null&&(t.dataset[A]=""),e?.appendChild(t),t}function Fy(){const e=document.createElement("div");return e.slot="hover-slot",e.style.position="absolute",e.style.top="0",e.style.bottom="0",e.style.textAlign="center",e.style.whiteSpace="normal",e}function xy(){const e=document.createElement("style");return e.setAttribute(Cu,""),e}var uq=`@layer base, theme, unsafe; @layer base { :host { --diffs-bg: #fff; --diffs-fg: #000; --diffs-font-fallback: 'SF Mono', Monaco, Consolas, 'Ubuntu Mono', 'Liberation Mono', 'Courier New', monospace; --diffs-header-font-fallback: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', 'Noto Sans', 'Liberation Sans', Arial, sans-serif; --diffs-mixer: light-dark(black, white); --diffs-gap-fallback: 8px; /* // Available CSS Color Overrides --diffs-bg-buffer-override --diffs-bg-hover-override --diffs-bg-context-override --diffs-bg-separator-override --diffs-fg-number-override --diffs-fg-number-addition-override --diffs-fg-number-deletion-override --diffs-deletion-color-override --diffs-addition-color-override --diffs-modified-color-override --diffs-bg-deletion-override --diffs-bg-deletion-number-override --diffs-bg-deletion-hover-override --diffs-bg-deletion-emphasis-override --diffs-bg-addition-override --diffs-bg-addition-number-override --diffs-bg-addition-hover-override --diffs-bg-addition-emphasis-override // Line Selection Color Overrides (for enableLineSelection) --diffs-selection-color-override --diffs-bg-selection-override --diffs-bg-selection-number-override --diffs-bg-selection-background-override --diffs-bg-selection-number-background-override // Available CSS Layout Overrides --diffs-gap-inline --diffs-gap-block --diffs-gap-style --diffs-tab-size */ color-scheme: light dark; display: block; font-family: var( --diffs-header-font-family, var(--diffs-header-font-fallback) ); font-size: var(--diffs-font-size, 13px); line-height: var(--diffs-line-height, 20px); font-feature-settings: var(--diffs-font-features); } /* NOTE(mdo): Some semantic HTML elements (e.g. \`pre\`, \`code\`) have default * user-agent styles. These must be overridden to use our custom styles. */ pre, code, [data-error-wrapper] { margin: 0; padding: 0; display: block; outline: none; font-family: var(--diffs-font-family, var(--diffs-font-fallback)); } *, *::before, *::after { box-sizing: border-box; } [data-icon-sprite] { display: none; } /* NOTE(mdo): Headers and separators are within pre/code, so we need to reset * their font-family explicitly. */ [data-diffs-header], [data-separator] { font-family: var( --diffs-header-font-family, var(--diffs-header-font-fallback) ); } [data-file-info] { padding: 10px; font-weight: 700; color: var(--fg); /* NOTE(amadeus): we cannot use 'in oklch' because current versions of cursor * and vscode use an older build of chrome that appears to have a bug with * color-mix and 'in oklch', so use 'in lab' instead */ background-color: color-mix(in lab, var(--bg) 98%, var(--fg)); border-block: 1px solid color-mix(in lab, var(--bg) 95%, var(--fg)); } [data-diffs-header], [data-diffs], [data-error-wrapper] { --diffs-bg: light-dark(var(--diffs-light-bg), var(--diffs-dark-bg)); /* NOTE(amadeus): we cannot use 'in oklch' because current versions of cursor * and vscode use an older build of chrome that appears to have a bug with * color-mix and 'in oklch', so use 'in lab' instead */ --diffs-bg-buffer: var( --diffs-bg-buffer-override, light-dark( color-mix(in lab, var(--diffs-bg) 92%, var(--diffs-mixer)), color-mix(in lab, var(--diffs-bg) 92%, var(--diffs-mixer)) ) ); --diffs-bg-hover: var( --diffs-bg-hover-override, light-dark( color-mix(in lab, var(--diffs-bg) 97%, var(--diffs-mixer)), color-mix(in lab, var(--diffs-bg) 91%, var(--diffs-mixer)) ) ); --diffs-bg-context: var( --diffs-bg-context-override, light-dark( color-mix(in lab, var(--diffs-bg) 98.5%, var(--diffs-mixer)), color-mix(in lab, var(--diffs-bg) 92.5%, var(--diffs-mixer)) ) ); --diffs-bg-separator: var( --diffs-bg-separator-override, light-dark( color-mix(in lab, var(--diffs-bg) 96%, var(--diffs-mixer)), color-mix(in lab, var(--diffs-bg) 85%, var(--diffs-mixer)) ) ); --diffs-fg: light-dark(var(--diffs-light), var(--diffs-dark)); --diffs-fg-number: var( --diffs-fg-number-override, light-dark( color-mix(in lab, var(--diffs-fg) 65%, var(--diffs-bg)), color-mix(in lab, var(--diffs-fg) 65%, var(--diffs-bg)) ) ); --diffs-deletion-base: var( --diffs-deletion-color-override, light-dark( var( --diffs-light-deletion-color, var(--diffs-deletion-color, rgb(255, 0, 0)) ), var( --diffs-dark-deletion-color, var(--diffs-deletion-color, rgb(255, 0, 0)) ) ) ); --diffs-addition-base: var( --diffs-addition-color-override, light-dark( var( --diffs-light-addition-color, var(--diffs-addition-color, rgb(0, 255, 0)) ), var( --diffs-dark-addition-color, var(--diffs-addition-color, rgb(0, 255, 0)) ) ) ); --diffs-modified-base: var( --diffs-modified-color-override, light-dark( var( --diffs-light-modified-color, var(--diffs-modified-color, rgb(0, 0, 255)) ), var( --diffs-dark-modified-color, var(--diffs-modified-color, rgb(0, 0, 255)) ) ) ); /* NOTE(amadeus): we cannot use 'in oklch' because current versions of cursor * and vscode use an older build of chrome that appears to have a bug with * color-mix and 'in oklch', so use 'in lab' instead */ --diffs-bg-deletion: var( --diffs-bg-deletion-override, light-dark( color-mix(in lab, var(--diffs-bg) 88%, var(--diffs-deletion-base)), color-mix(in lab, var(--diffs-bg) 80%, var(--diffs-deletion-base)) ) ); --diffs-bg-deletion-number: var( --diffs-bg-deletion-number-override, light-dark( color-mix(in lab, var(--diffs-bg) 91%, var(--diffs-deletion-base)), color-mix(in lab, var(--diffs-bg) 85%, var(--diffs-deletion-base)) ) ); --diffs-bg-deletion-hover: var( --diffs-bg-deletion-hover-override, light-dark( color-mix(in lab, var(--diffs-bg) 80%, var(--diffs-deletion-base)), color-mix(in lab, var(--diffs-bg) 75%, var(--diffs-deletion-base)) ) ); --diffs-bg-deletion-emphasis: var( --diffs-bg-deletion-emphasis-override, light-dark( rgb(from var(--diffs-deletion-base) r g b / 0.15), rgb(from var(--diffs-deletion-base) r g b / 0.2) ) ); --diffs-bg-addition: var( --diffs-bg-addition-override, light-dark( color-mix(in lab, var(--diffs-bg) 88%, var(--diffs-addition-base)), color-mix(in lab, var(--diffs-bg) 80%, var(--diffs-addition-base)) ) ); --diffs-bg-addition-number: var( --diffs-bg-addition-number-override, light-dark( color-mix(in lab, var(--diffs-bg) 91%, var(--diffs-addition-base)), color-mix(in lab, var(--diffs-bg) 85%, var(--diffs-addition-base)) ) ); --diffs-bg-addition-hover: var( --diffs-bg-addition-hover-override, light-dark( color-mix(in lab, var(--diffs-bg) 80%, var(--diffs-addition-base)), color-mix(in lab, var(--diffs-bg) 70%, var(--diffs-addition-base)) ) ); --diffs-bg-addition-emphasis: var( --diffs-bg-addition-emphasis-override, light-dark( rgb(from var(--diffs-addition-base) r g b / 0.15), rgb(from var(--diffs-addition-base) r g b / 0.2) ) ); --diffs-selection-base: var(--diffs-modified-base); --diffs-selection-number-fg: light-dark( color-mix(in lab, var(--diffs-selection-base) 65%, var(--diffs-mixer)), color-mix(in lab, var(--diffs-selection-base) 75%, var(--diffs-mixer)) ); --diffs-bg-selection: var( --diffs-bg-selection-override, light-dark( color-mix(in lab, var(--diffs-bg) 82%, var(--diffs-selection-base)), color-mix(in lab, var(--diffs-bg) 75%, var(--diffs-selection-base)) ) ); --diffs-bg-selection-number: var( --diffs-bg-selection-number-override, light-dark( color-mix(in lab, var(--diffs-bg) 75%, var(--diffs-selection-base)), color-mix(in lab, var(--diffs-bg) 60%, var(--diffs-selection-base)) ) ); background-color: var(--diffs-bg); color: var(--diffs-fg); } [data-diffs] { --diffs-code-grid: minmax(min-content, max-content) 1fr; [data-column-content] span { color: light-dark(var(--diffs-light), var(--diffs-dark)); font-weight: var(--diffs-light-font-weight); font-style: var(--diffs-light-font-style); } } [data-column-content] { background-color: var(--diffs-line-bg, 'transparent'); grid-column: 2 / 3; } [data-diffs][data-dehydrated] { --diffs-code-grid: minmax(min-content, max-content) minmax(0, 1fr); } @media (prefers-color-scheme: dark) { [data-diffs-header], [data-diffs] { color-scheme: dark; } [data-diffs] [data-column-content] span { font-weight: var(--diffs-dark-font-weight); font-style: var(--diffs-dark-font-style); } } [data-diffs-header][data-theme-type='light'], [data-diffs][data-theme-type='light'] { color-scheme: light; } [data-diffs][data-theme-type='light'] [data-column-content] span { font-weight: var(--diffs-light-font-weight); font-style: var(--diffs-light-font-style); } [data-diffs-header][data-theme-type='dark'], [data-diffs][data-theme-type='dark'] { color-scheme: dark; } [data-diffs][data-theme-type='dark'] [data-column-content] span { font-weight: var(--diffs-dark-font-weight); font-style: var(--diffs-dark-font-style); } [data-type='split'][data-overflow='wrap'] { display: grid; grid-auto-flow: dense; grid-template-columns: repeat(2, var(--diffs-code-grid)); } [data-type='split'][data-overflow='scroll'] { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; } [data-code] { display: block; display: grid; grid-auto-flow: dense; grid-template-columns: var(--diffs-code-grid); overflow: scroll clip; overscroll-behavior-x: none; tab-size: var(--diffs-tab-size, 2); align-self: flex-start; padding-top: var(--diffs-gap-block, var(--diffs-gap-fallback)); padding-bottom: max( 0px, calc(var(--diffs-gap-block, var(--diffs-gap-fallback)) - 6px) ); } [data-code]::-webkit-scrollbar { width: 0; height: 6px; } [data-code]::-webkit-scrollbar-track { background: transparent; } [data-code]::-webkit-scrollbar-thumb { background-color: transparent; border: 1px solid transparent; background-clip: content-box; border-radius: 3px; } [data-diffs]:hover [data-code]::-webkit-scrollbar-thumb { background-color: var(--diffs-bg-context); } [data-code]::-webkit-scrollbar-corner { background-color: transparent; } /* * If we apply these rules globally it will mean that webkit will opt into the * standards compliant version of custom css scrollbars, which we do not want * because the custom stuff will look better */ @supports (-moz-appearance: none) { [data-code] { scrollbar-width: thin; scrollbar-color: var(--diffs-bg-context) transparent; padding-bottom: var(--diffs-gap-block, var(--diffs-gap-fallback)); } } [data-diffs][data-type='split'][data-overflow='wrap'] { padding-block: var(--diffs-gap-block, var(--diffs-gap-fallback)); } [data-diffs-header] ~ [data-diffs] [data-code], [data-diffs-header] ~ [data-diffs][data-overflow='wrap'] { padding-top: 0; } [data-type='split'][data-overflow='wrap'] [data-code] { display: contents; } [data-line-annotation], [data-no-newline], [data-line] { position: relative; display: grid; grid-template-columns: subgrid; grid-column: 1 / 3; } [data-line-annotation][data-selected-line] { background-color: unset; &::before { content: ''; position: sticky; top: 0; left: 0; display: block; border-right: var(--diffs-gap-style, 1px solid var(--diffs-bg)); background-color: var(--diffs-bg-selection-number); } [data-annotation-content] { background-color: var(--diffs-bg-selection); } } [data-interactive-lines] [data-line] { cursor: pointer; } [data-buffer] { position: sticky; left: 0; grid-column: 1 / 3; -webkit-user-select: none; user-select: none; /* We multiply by 1.414 (√2) to better approximate the diagonal repeat distance */ background-image: repeating-linear-gradient( -45deg, transparent, transparent calc(3px * 1.414), var(--diffs-bg-buffer) calc(3px * 1.414), var(--diffs-bg-buffer) calc(4px * 1.414) ); min-height: 1lh; width: var(--diffs-column-width, auto); } [data-separator] { grid-column: span 2; } [data-separator='metadata'], [data-separator]:empty { min-height: 4px; background-color: var(--diffs-bg-separator); display: grid; grid-template-columns: subgrid; } [data-separator-wrapper] { -webkit-user-select: none; user-select: none; fill: currentColor; overflow: hidden; } [data-separator='metadata'] [data-separator-wrapper] { grid-column: 2 / 3; width: var(--diffs-column-content-width); position: sticky; left: var(--diffs-column-number-width); padding: 4px 1ch; } [data-separator='line-info'] { margin-block: var(--diffs-gap-block, var(--diffs-gap-fallback)); } [data-separator='line-info'][data-separator-first] { margin-top: 0; } [data-separator='line-info'][data-separator-last] { margin-bottom: 0; } [data-separator='line-info'] [data-separator-wrapper] { position: sticky; display: flex; align-items: center; gap: 2px; width: auto; width: calc(var(--diffs-column-width) - var(--diffs-gap-fallback)); border-radius: 6px; } @media (pointer: fine) { [data-separator-wrapper][data-separator-multi-button] { display: grid; grid-template-columns: auto minmax(0, 1fr); grid-template-rows: 15px 15px; [data-expand-button] { height: 15px; } } [data-type='split'] [data-additions] [data-separator-wrapper][data-separator-multi-button] { grid-template-columns: minmax(0, 1fr) auto; } [data-type='split'] [data-additions] [data-expand-button] { grid-column: 2; } [data-type='split'] [data-additions] [data-separator-content] { grid-column: 1; } } [data-expand-button], [data-separator-content] { display: flex; align-items: center; background-color: var(--diffs-bg-separator); } [data-expand-button] { justify-content: center; flex-shrink: 0; cursor: pointer; width: 32px; height: 32px; opacity: 0.65; } [data-hover-slot] { position: absolute; top: 0; bottom: 0; right: 0; display: flex; justify-content: flex-end; } @media (pointer: fine) { [data-expand-button]:hover { opacity: 1; } [data-line]:hover { z-index: 2; } } [data-expand-up] [data-icon] { transform: scaleY(-1); } [data-separator-content] { flex: 1 1 auto; padding: 0 1ch; height: 32px; opacity: 0.65; overflow: hidden; justify-content: flex-start; grid-column: 2; grid-row: 1 / -1; } [data-unmodified-lines] { display: block; overflow: hidden; min-width: 0; text-overflow: ellipsis; white-space: nowrap; flex: 0 1 auto; } [data-type='split'] [data-additions] [data-separator-content] { justify-content: flex-end; } [data-type='file'] [data-code] [data-separator='line-info'] [data-separator-wrapper] { left: var(--diffs-gap-inline, var(--diffs-gap-fallback)); margin-left: var(--diffs-gap-inline, var(--diffs-gap-fallback)); margin-right: var(--diffs-gap-inline, var(--diffs-gap-fallback)); width: calc( var(--diffs-column-width) - (var(--diffs-gap-inline, var(--diffs-gap-fallback)) * 2) ); } [data-type='split'] [data-deletions] [data-separator='line-info'] [data-separator-wrapper] { left: var(--diffs-gap-fallback); margin-left: var(--diffs-gap-fallback); border-top-right-radius: 0; border-bottom-right-radius: 0; } [data-type='split'] [data-additions] [data-separator='line-info'] [data-separator-wrapper] { left: 0; margin-right: var(--diffs-gap-inline, var(--diffs-gap-fallback)); border-top-left-radius: 0; border-bottom-left-radius: 0; flex-direction: row-reverse; } [data-line] { background-color: var(--diffs-bg); color: var(--diffs-fg); } [data-type='split'][data-overflow='wrap'] [data-deletions] { [data-line-annotation], [data-buffer], [data-line], [data-separator] { grid-column: 1 / 3; } } [data-line-annotation] { min-height: var(--diffs-annotation-min-height, 0); background-color: var(--diffs-bg-context); z-index: 3; } [data-type='split'][data-overflow='wrap'] [data-additions] { [data-line-annotation], [data-buffer], [data-line], [data-separator] { margin-left: 2px; grid-column: 3 / 5; } } [data-separator='custom'] { display: grid; grid-template-columns: subgrid; } [data-column-content], [data-column-number] { position: relative; padding-inline: 1ch; } [data-indicators='classic'] [data-column-content] { padding-inline-start: 2ch; } [data-indicators='classic'] { [data-line-type='change-addition'] [data-column-content]::before, [data-line-type='change-deletion'] [data-column-content]::before { display: inline-block; width: 1ch; height: 1lh; position: absolute; top: 0; left: 0; -webkit-user-select: none; user-select: none; } [data-line-type='change-addition'] [data-column-content]::before { content: '+'; color: var(--diffs-addition-base); } [data-line-type='change-deletion'] [data-column-content]::before { content: '-'; color: var(--diffs-deletion-base); } } [data-indicators='bars'] { [data-line-type='change-deletion'] [data-column-number]::before, [data-line-type='change-addition'] [data-column-number]::before { content: ''; display: block; width: 4px; height: 100%; position: absolute; top: 0; left: 0; -webkit-user-select: none; user-select: none; } [data-line-type='change-deletion'] [data-column-number]::before { background-image: linear-gradient( 0deg, var(--diffs-bg-deletion) 50%, var(--diffs-deletion-base) 50% ); background-repeat: repeat; background-size: 2px 2px; background-size: calc(1lh / round(1lh / 2px)) calc(1lh / round(1lh / 2px)); } [data-line-type='change-addition'] [data-column-number]::before { background-color: var(--diffs-addition-base); } } [data-overflow='wrap'] [data-column-content], [data-overflow='wrap'] [data-annotation-content] { white-space: pre-wrap; word-break: break-word; } [data-overflow='scroll'] [data-column-content] { white-space: pre; min-height: 1lh; } [data-column-number] { grid-column: 1 / 2; box-sizing: content-box; text-align: right; position: sticky; left: 0; -webkit-user-select: none; user-select: none; background-color: var(--diffs-bg); color: var(--diffs-fg-number); z-index: 1; min-width: var( --diffs-min-number-column-width, var(--diffs-min-number-column-width-default, 3ch) ); padding-left: 2ch; border-right: var(--diffs-gap-style, 1px solid var(--diffs-bg)); } [data-disable-line-numbers] { &[data-indicators='bars'] [data-column-number] { min-width: 4px; border-right: var(--diffs-gap-style, 1px solid var(--diffs-bg)); } [data-column-number] { border-right: none; min-width: 0; padding: 0; } [data-line-number-content] { display: none; } [data-hover-slot] { right: unset; left: 0; justify-content: flex-start; } &[data-indicators='bars'] [data-hover-slot] { /* Using 5px here because theres a 1px separator after the bar */ left: 5px; } } [data-interactive-line-numbers] [data-column-number] { cursor: pointer; } [data-diff-span] { border-radius: 3px; -webkit-box-decoration-break: clone; box-decoration-break: clone; } [data-line-type='change-addition'] { [data-column-number] { color: var( --diffs-fg-number-addition-override, var(--diffs-addition-base) ); } [data-diff-span] { background-color: var(--diffs-bg-addition-emphasis); } } [data-line-type='change-deletion'] { [data-column-number] { color: var( --diffs-fg-number-deletion-override, var(--diffs-deletion-base) ); } [data-diff-span] { background-color: var(--diffs-bg-deletion-emphasis); } } [data-background] [data-line-type='change-addition'] { --diffs-line-bg: var(--diffs-bg-addition); [data-column-number] { background-color: var(--diffs-bg-addition-number); } } [data-background] [data-line-type='change-deletion'] { --diffs-line-bg: var(--diffs-bg-deletion); [data-column-number] { background-color: var(--diffs-bg-deletion-number); } } [data-line-type='context-expanded'] { --diffs-line-bg: var(--diffs-bg-context); [data-column-number] { background-color: var(--diffs-bg-context); } } /* By wrapping hovers in a pointer: fine, we ensure that mobile devices don't * require a double click */ @media (pointer: fine) { [data-line]:hover:not([data-selected-line]) { [data-column-number], [data-column-content] { background-color: var(--diffs-bg-hover); } } [data-background] [data-line]:hover:not([data-selected-line]) { &[data-line-type='change-deletion'] [data-column-number], &[data-line-type='change-deletion'] [data-column-content] { background-color: var(--diffs-bg-deletion-hover); } &[data-line-type='change-addition'] [data-column-number], &[data-line-type='change-addition'] [data-column-content] { background-color: var(--diffs-bg-addition-hover); } } } [data-diffs-header] { display: flex; flex-direction: row; justify-content: space-between; align-items: center; gap: var(--diffs-gap-inline, var(--diffs-gap-fallback)); min-height: calc( 1lh + (var(--diffs-gap-block, var(--diffs-gap-fallback)) * 3) ); padding-inline: 16px; } [data-header-content] { display: flex; flex-direction: row; align-items: center; gap: var(--diffs-gap-inline, var(--diffs-gap-fallback)); min-width: 0; white-space: nowrap; } [data-header-content] [data-prev-name], [data-header-content] [data-title] { direction: rtl; overflow: hidden; text-overflow: ellipsis; min-width: 0; white-space: nowrap; } [data-prev-name] { opacity: 0.7; } [data-rename-icon] { fill: currentColor; flex-shrink: 0; flex-grow: 0; } [data-diffs-header] [data-metadata] { display: flex; align-items: center; gap: 1ch; white-space: nowrap; } [data-diffs-header] [data-additions-count] { font-family: var(--diffs-font-family, var(--diffs-font-fallback)); color: var(--diffs-addition-base); } [data-diffs-header] [data-deletions-count] { font-family: var(--diffs-font-family, var(--diffs-font-fallback)); color: var(--diffs-deletion-base); } [data-no-newline] { -webkit-user-select: none; user-select: none; [data-column-content] { opacity: 0.6; } } [data-annotation-content] { position: sticky; left: var(--diffs-column-number-width, 0); grid-column: 2 / -1; width: var(--diffs-column-content-width, auto); align-self: flex-start; z-index: 2; height: 100%; } /* Undo some of the stuff that the 'pre' tag does */ [data-annotation-slot] { text-wrap-mode: wrap; word-break: normal; white-space-collapse: collapse; } [data-change-icon] { fill: currentColor; flex-shrink: 0; } [data-change-icon='change'], [data-change-icon='rename-pure'], [data-change-icon='rename-changed'] { color: var(--diffs-modified-base); } [data-change-icon='new'] { color: var(--diffs-addition-base); } [data-change-icon='deleted'] { color: var(--diffs-deletion-base); } [data-change-icon='file'] { opacity: 0.6; } /* Line selection highlighting */ [data-line-type='context'][data-selected-line] { [data-column-number] { color: var(--diffs-selection-number-fg); background-color: var(--diffs-bg-selection-number); } [data-column-content] { background-color: var(--diffs-bg-selection); } } [data-line-type='context-expanded'], [data-line-type='change-addition'], [data-line-type='change-deletion'] { &[data-selected-line] { [data-column-content] { background-color: light-dark( color-mix( in lab, var(--diffs-line-bg, var(--diffs-bg)) 82%, var(--diffs-selection-base) ), color-mix( in lab, var(--diffs-line-bg, var(--diffs-bg)) 75%, var(--diffs-selection-base) ) ); } [data-column-number] { color: var(--diffs-selection-number-fg); background-color: light-dark( color-mix( in lab, var(--diffs-line-bg, var(--diffs-bg)) 75%, var(--diffs-selection-base) ), color-mix( in lab, var(--diffs-line-bg, var(--diffs-bg)) 60%, var(--diffs-selection-base) ) ); } } } [data-error-wrapper] { overflow: auto; padding: var(--diffs-gap-block, var(--diffs-gap-fallback)) var(--diffs-gap-inline, var(--diffs-gap-fallback)); max-height: 400px; scrollbar-width: none; [data-error-message] { font-weight: bold; font-size: 18px; color: var(--diffs-deletion-base); } [data-error-stack] { color: var(--diffs-fg-number); } } } `;const dq="@layer base, theme, unsafe;";function Gy(e){return`${dq} @layer unsafe { ${e} }`}function Sy(e,A){if(A==null)return;const t=e.shadowRoot??e.attachShadow({mode:"open"});t.innerHTML===""&&(t.innerHTML=A)}function Jy({diffIndicators:e,disableBackground:A,disableLineNumbers:t,overflow:r,pre:n,split:i,themeStyles:o,themeType:g,totalLines:Q}){switch(g==="system"?delete n.dataset.themeType:n.dataset.themeType=g,e){case"bars":case"classic":n.dataset.indicators=e;break;case"none":delete n.dataset.indicators;break}return t?n.dataset.disableLineNumbers="":delete n.dataset.disableLineNumbers,A?delete n.dataset.background:n.dataset.background="",n.dataset.type=i?"split":"file",n.dataset.overflow=r,n.dataset.diffs="",n.tabIndex=0,n.style=o,n.style.setProperty("--diffs-min-number-column-width-default",`${`${Q}`.length}ch`),n}if(typeof HTMLElement<"u"&&customElements.get(vs)==null){let e;class A extends HTMLElement{constructor(){if(super(),this.shadowRoot!=null)return;const r=this.attachShadow({mode:"open"});e==null&&(e=new CSSStyleSheet,e.replaceSync(`@layer base, theme, unsafe; @layer base { ${uq} }`)),r.adoptedStyleSheets=[e]}}customElements.define(vs,A)}const Uy=!0;let hq=-1;var Dq=class{static LoadedCustomComponent=Uy;__id=++hq;fileContainer;spriteSVG;pre;code;unsafeCSSStyle;hoverContent;errorWrapper;headerElement;headerMetadata;fileRenderer;resizeManager;mouseEventManager;lineSelectionManager;annotationElements=[];lineAnnotations=[];file;constructor(A={theme:Vt},t,r=!1){this.options=A,this.workerManager=t,this.isContainerManaged=r,this.fileRenderer=new cq(A,this.handleHighlightRender,this.workerManager),this.resizeManager=new ty,this.mouseEventManager=new ey("file",Fs(A)),this.lineSelectionManager=new Ay(bs(A)),this.workerManager?.subscribeToThemeChanges(this)}handleHighlightRender=()=>{this.rerender()};rerender(){this.file!=null&&this.render({file:this.file,forceRender:!0})}setOptions(A){A!=null&&(this.options=A,this.mouseEventManager.setOptions(Fs(A)),this.lineSelectionManager.setOptions(bs(A)))}mergeOptions(A){this.options={...this.options,...A}}setThemeType(A){if((this.options.themeType??"system")!==A&&(this.mergeOptions({themeType:A}),this.fileRenderer.setThemeType(A),this.headerElement!=null&&(A==="system"?delete this.headerElement.dataset.themeType:this.headerElement.dataset.themeType=A),this.pre!=null))switch(A){case"system":delete this.pre.dataset.themeType;break;case"light":case"dark":this.pre.dataset.themeType=A;break}}getHoveredLine=()=>this.mouseEventManager.getHoveredLine();setLineAnnotations(A){this.lineAnnotations=A}setSelectedLines(A){this.lineSelectionManager.setSelection(A)}cleanUp(){this.fileRenderer.cleanUp(),this.resizeManager.cleanUp(),this.mouseEventManager.cleanUp(),this.lineSelectionManager.cleanUp(),this.workerManager?.unsubscribeToThemeChanges(this),this.workerManager=void 0,this.file=void 0,this.isContainerManaged||this.fileContainer?.parentNode?.removeChild(this.fileContainer),this.fileContainer?.shadowRoot!=null&&(this.fileContainer.shadowRoot.innerHTML=""),this.fileContainer=void 0,this.pre=void 0,this.headerElement=void 0,this.errorWrapper=void 0,this.unsafeCSSStyle=void 0}hydrate(A){const{fileContainer:t,prerenderedHTML:r}=A;Sy(t,r);for(const n of Array.from(t.shadowRoot?.children??[])){if(n instanceof SVGElement){this.spriteSVG=n;continue}if(n instanceof HTMLElement){if(n instanceof HTMLPreElement){this.pre=n;continue}if(n instanceof HTMLStyleElement&&n.hasAttribute(Cu)){this.unsafeCSSStyle=n;continue}if("diffsHeader"in n.dataset){this.headerElement=n;continue}}}if(this.pre==null)this.render(A);else{const{file:n,lineAnnotations:i}=A;this.fileContainer=t,delete this.pre.dataset.dehydrated,this.lineAnnotations=i??this.lineAnnotations,this.file=n,this.fileRenderer.hydrate(n),this.renderAnnotations(),this.renderHoverUtility(),this.injectUnsafeCSS(),this.mouseEventManager.setup(this.pre),this.lineSelectionManager.setup(this.pre),(this.options.overflow??"scroll")==="scroll"&&this.resizeManager.setup(this.pre)}}render({file:A,fileContainer:t,forceRender:r=!1,containerWrapper:n,lineAnnotations:i}){const o=i!=null&&(i.length>0||this.lineAnnotations.length>0)?i!==this.lineAnnotations:!1;if(!r&&bl(this.file,A)&&!o)return;this.file=A,this.fileRenderer.setOptions(this.options),i!=null&&this.setLineAnnotations(i),this.fileRenderer.setLineAnnotations(this.lineAnnotations);const{disableFileHeader:g=!1}=this.options;g&&this.headerElement!=null&&(this.headerElement.parentNode?.removeChild(this.headerElement),this.headerElement=void 0),t=this.getOrCreateFileContainerNode(t,n);try{const Q=this.fileRenderer.renderFile(A);if(Q==null){this.workerManager!=null&&!this.workerManager.isInitialized()&&this.workerManager.initialize().then(()=>this.rerender());return}Q.headerAST!=null&&this.applyHeaderToDOM(Q.headerAST,t);const B=this.getOrCreatePreNode(t);this.applyHunksToDOM(Q,B),this.renderAnnotations(),this.renderHoverUtility()}catch(Q){Q instanceof Error&&this.applyErrorToDOM(Q,t)}}renderAnnotations(){if(this.isContainerManaged||this.fileContainer==null)return;for(const t of this.annotationElements)t.parentNode?.removeChild(t);this.annotationElements.length=0;const{renderAnnotation:A}=this.options;if(A!=null&&this.lineAnnotations.length>0)for(const t of this.lineAnnotations){const r=A(t);if(r==null)continue;const n=by(QB(t));n.appendChild(r),this.annotationElements.push(n),this.fileContainer.appendChild(n)}}renderHoverUtility(){const{renderHoverUtility:A}=this.options;if(this.fileContainer==null||A==null)return;this.hoverContent==null&&(this.hoverContent=Fy(),this.fileContainer.appendChild(this.hoverContent));const t=A(this.mouseEventManager.getHoveredLine);this.hoverContent.innerHTML="",t!=null&&this.hoverContent.appendChild(t)}injectUnsafeCSS(){if(this.fileContainer?.shadowRoot==null)return;const{unsafeCSS:A}=this.options;if(A==null||A===""){this.unsafeCSSStyle!=null&&(this.unsafeCSSStyle.parentNode?.removeChild(this.unsafeCSSStyle),this.unsafeCSSStyle=void 0);return}this.unsafeCSSStyle==null&&(this.unsafeCSSStyle=xy(),this.fileContainer.shadowRoot.appendChild(this.unsafeCSSStyle)),this.unsafeCSSStyle.innerText=Gy(A)}applyHunksToDOM(A,t){this.cleanupErrorWrapper(),this.applyPreNodeAttributes(t,A),t.innerHTML="",this.code=As(),this.code.innerHTML=this.fileRenderer.renderPartialHTML(A.codeAST),t.appendChild(this.code),this.injectUnsafeCSS(),this.mouseEventManager.setup(t),this.lineSelectionManager.setup(t),this.lineSelectionManager.setDirty(),(this.options.overflow??"scroll")==="scroll"?this.resizeManager.setup(t):this.resizeManager.cleanUp()}applyHeaderToDOM(A,t){const{file:r}=this;if(r==null)return;this.cleanupErrorWrapper();const n=document.createElement("div");n.innerHTML=Xn(A);const i=n.firstElementChild;if(!(i instanceof HTMLElement)||(this.headerElement!=null?t.shadowRoot?.replaceChild(i,this.headerElement):t.shadowRoot?.prepend(i),this.headerElement=i,this.isContainerManaged))return;const{renderCustomMetadata:o}=this.options;this.headerMetadata!=null&&this.headerMetadata.parentNode?.removeChild(this.headerMetadata);const g=o?.(r)??void 0;g!=null&&(this.headerMetadata=document.createElement("div"),this.headerMetadata.slot=Eu,g instanceof Element?this.headerMetadata.appendChild(g):this.headerMetadata.innerText=`${g}`,t.appendChild(this.headerMetadata))}getOrCreateFileContainerNode(A,t){if(this.fileContainer=A??this.fileContainer??document.createElement(vs),t!=null&&this.fileContainer.parentNode!==t&&t.appendChild(this.fileContainer),this.spriteSVG==null){const r=document.createElement("div");r.innerHTML=vy;const n=r.firstChild;n instanceof SVGElement&&(this.spriteSVG=n,this.fileContainer.shadowRoot?.appendChild(this.spriteSVG))}return this.fileContainer}getOrCreatePreNode(A){return this.pre==null?(this.pre=document.createElement("pre"),A.shadowRoot?.appendChild(this.pre)):this.pre.parentNode!==A&&A.shadowRoot?.appendChild(this.pre),this.pre}applyPreNodeAttributes(A,{totalLines:t,themeStyles:r,baseThemeType:n}){const{overflow:i="scroll",themeType:o="system",disableLineNumbers:g=!1}=this.options;Jy({pre:A,split:!1,themeStyles:r,overflow:i,disableLineNumbers:g,themeType:n??o,diffIndicators:"none",disableBackground:!0,totalLines:t})}applyErrorToDOM(A,t){this.cleanupErrorWrapper();const r=this.getOrCreatePreNode(t);r.innerHTML="",r.parentNode?.removeChild(r),this.pre=void 0;const n=t.shadowRoot??t.attachShadow({mode:"open"});this.errorWrapper??=document.createElement("div"),this.errorWrapper.dataset.errorWrapper="",this.errorWrapper.innerHTML="",n.appendChild(this.errorWrapper);const i=document.createElement("div");i.dataset.errorMessage="",i.innerText=A.message,this.errorWrapper.appendChild(i);const o=document.createElement("pre");o.dataset.errorStack="",o.innerText=A.stack??"No Error Stack",this.errorWrapper.appendChild(o)}cleanupErrorWrapper(){this.errorWrapper?.parentNode?.removeChild(this.errorWrapper),this.errorWrapper=void 0}},fq=class{isDeletionsScrolling=!1;isAdditionsScrolling=!1;timeoutId=-1;codeDeletions;codeAdditions;cleanUp(){this.codeDeletions?.removeEventListener("scroll",this.handleDeletionsScroll),this.codeAdditions?.removeEventListener("scroll",this.handleAdditionsScroll),clearTimeout(this.timeoutId),this.codeDeletions=void 0,this.codeAdditions=void 0}setup(e,A,t){if(A==null||t==null)for(const r of e.children??[])r instanceof HTMLElement&&("deletions"in r.dataset?A=r:"additions"in r.dataset&&(t=r));if(t==null||A==null){this.cleanUp();return}this.codeDeletions?.removeEventListener("scroll",this.handleDeletionsScroll),this.codeAdditions?.removeEventListener("scroll",this.handleAdditionsScroll),this.codeDeletions=A,this.codeAdditions=t,A.addEventListener("scroll",this.handleDeletionsScroll,{passive:!0}),t.addEventListener("scroll",this.handleAdditionsScroll,{passive:!0})}handleDeletionsScroll=()=>{this.isAdditionsScrolling||(this.isDeletionsScrolling=!0,clearTimeout(this.timeoutId),this.timeoutId=setTimeout(()=>{this.isDeletionsScrolling=!1},300),this.codeAdditions?.scrollTo({left:this.codeDeletions?.scrollLeft}))};handleAdditionsScroll=()=>{this.isDeletionsScrolling||(this.isAdditionsScrolling=!0,clearTimeout(this.timeoutId),this.timeoutId=setTimeout(()=>{this.isAdditionsScrolling=!1},300),this.codeDeletions?.scrollTo({left:this.codeAdditions?.scrollLeft}))}};function og(e){return Fe({tagName:"div",properties:{"data-buffer":"",style:`grid-row: span ${e};min-height:calc(${e} * 1lh)`}})}function gI(e){return Fe({tagName:"div",children:[Fe({tagName:"span",properties:{"data-column-number":""}}),Fe({tagName:"span",children:[Ti("No newline at end of file")],properties:{"data-column-content":""}})],properties:{"data-no-newline":"","data-line-type":e}})}function QI(e){return Fe({tagName:"div",children:[Nl({name:e==="both"?"diffs-icon-expand-all":"diffs-icon-expand",properties:{"data-icon":""}})],properties:{"data-expand-button":"","data-expand-both":e==="both"?"":void 0,"data-expand-up":e==="up"?"":void 0,"data-expand-down":e==="down"?"":void 0}})}function BI({type:e,content:A,expandIndex:t,chunked:r=!1,slotName:n,isFirstHunk:i,isLastHunk:o}){const g=[];if(e==="metadata"&&A!=null&&g.push(Fe({tagName:"div",children:[Ti(A)],properties:{"data-separator-wrapper":""}})),e==="line-info"&&A!=null){const Q=[];t!=null&&(r?(i||Q.push(QI("up")),o||Q.push(QI("down"))):Q.push(QI(!i&&!o?"both":i?"down":"up"))),Q.push(Fe({tagName:"div",children:[Fe({tagName:"span",children:[Ti(A)],properties:{"data-unmodified-lines":""}})],properties:{"data-separator-content":""}})),g.push(Fe({tagName:"div",children:Q,properties:{"data-separator-wrapper":"","data-separator-multi-button":Q.length>2?"":void 0}}))}return e==="custom"&&n!=null&&g.push(Fe({tagName:"slot",properties:{name:n}})),Fe({tagName:"div",children:g,properties:{"data-separator":g.length===0?"":e,"data-expand-index":t,"data-separator-first":i?"":void 0,"data-separator-last":o?"":void 0}})}function wq(e,A){return`hunk-separator-${e}-${A}`}function mq(e){const A=e[e.length-1];return A==null?0:Math.max(A.additionStart+A.additionCount,A.deletionStart+A.deletionCount)}let fu=class{diff(A,t,r={}){let n;typeof r=="function"?(n=r,r={}):"callback"in r&&(n=r.callback);const i=this.castInput(A,r),o=this.castInput(t,r),g=this.removeEmpty(this.tokenize(i,r)),Q=this.removeEmpty(this.tokenize(o,r));return this.diffWithOptionsObj(g,Q,r,n)}diffWithOptionsObj(A,t,r,n){var i;const o=d=>{if(d=this.postProcess(d,r),n){setTimeout(function(){n(d)},0);return}else return d},g=t.length,Q=A.length;let B=1,a=g+Q;r.maxEditLength!=null&&(a=Math.min(a,r.maxEditLength));const s=(i=r.timeout)!==null&&i!==void 0?i:1/0,C=Date.now()+s,E=[{oldPos:-1,lastComponent:void 0}];let I=this.extractCommon(E[0],t,A,0,r);if(E[0].oldPos+1>=Q&&I+1>=g)return o(this.buildValues(E[0].lastComponent,t,A));let c=-1/0,u=1/0;const h=()=>{for(let d=Math.max(c,-B);d<=Math.min(u,B);d+=2){let f;const m=E[d-1],k=E[d+1];m&&(E[d-1]=void 0);let N=!1;if(k){const L=k.oldPos-d;N=k&&0<=L&&L=Q&&I+1>=g)return o(this.buildValues(f.lastComponent,t,A))||!0;E[d]=f,f.oldPos+1>=Q&&(u=Math.min(u,d-1)),I+1>=g&&(c=Math.max(c,d+1))}B++};if(n)(function d(){setTimeout(function(){if(B>a||Date.now()>C)return n(void 0);h()||d()},0)})();else for(;B<=a&&Date.now()<=C;){const d=h();if(d)return d}}addToPath(A,t,r,n,i){const o=A.lastComponent;return o&&!i.oneChangePerToken&&o.added===t&&o.removed===r?{oldPos:A.oldPos+n,lastComponent:{count:o.count+1,added:t,removed:r,previousComponent:o.previousComponent}}:{oldPos:A.oldPos+n,lastComponent:{count:1,added:t,removed:r,previousComponent:o}}}extractCommon(A,t,r,n,i){const o=t.length,g=r.length;let Q=A.oldPos,B=Q-n,a=0;for(;B+1C.length?I:C}),a.value=this.join(s)}else a.value=this.join(t.slice(Q,Q+a.count));Q+=a.count,a.added||(B+=a.count)}}return n}};class pq extends fu{}const kq=new pq;function yq(e,A,t){return kq.diff(e,A,t)}const Af="a-zA-Z0-9_\\u{C0}-\\u{FF}\\u{D8}-\\u{F6}\\u{F8}-\\u{2C6}\\u{2C8}-\\u{2D7}\\u{2DE}-\\u{2FF}\\u{1E00}-\\u{1EFF}";class Mq extends fu{tokenize(A){const t=new RegExp(`(\\r?\\n)|[${Af}]+|[^\\S\\n\\r]+|[^${Af}]`,"ug");return A.match(t)||[]}}const Nq=new Mq;function vq(e,A,t){return Nq.diff(e,A,t)}class bq extends fu{constructor(){super(...arguments),this.tokenize=xq}equals(A,t,r){return r.ignoreWhitespace?((!r.newlineIsToken||!A.includes(` `))&&(A=A.trim()),(!r.newlineIsToken||!t.includes(` `))&&(t=t.trim())):r.ignoreNewlineAtEof&&!r.newlineIsToken&&(A.endsWith(` `)&&(A=A.slice(0,-1)),t.endsWith(` `)&&(t=t.slice(0,-1))),super.equals(A,t,r)}}const Fq=new bq;function ef(e,A,t){return Fq.diff(e,A,t)}function xq(e,A){A.stripTrailingCr&&(e=e.replace(/\r\n/g,` `));const t=[],r=e.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(let n=0;n"u"&&(g.context=4);const Q=g.context;if(g.newlineIsToken)throw new Error("newlineIsToken may not be used with patch-generation functions, only with diffing functions");if(g.callback){const{callback:a}=g;ef(t,r,Object.assign(Object.assign({},g),{callback:s=>{const C=B(s);a(C)}}))}else return B(ef(t,r,g));function B(a){if(!a)return;a.push({value:"",lines:[]});function s(d){return d.map(function(f){return" "+f})}const C=[];let E=0,I=0,c=[],u=1,h=1;for(let d=0;d0?s(k.lines.slice(-Q)):[],E-=c.length,I-=c.length)}for(const k of m)c.push((f.added?"+":"-")+k);f.added?h+=m.length:u+=m.length}else{if(E)if(m.length<=Q*2&&d"u"?"":" "+e.oldHeader)),A.push("+++ "+e.newFileName+(typeof e.newHeader>"u"?"":" "+e.newHeader));for(let t=0;tr+` `);return A?t.pop():t.push(t.pop().slice(0,-1)),t}function tf({line:e,spanStart:A,spanLength:t}){return{start:{line:e,character:A},end:{line:e,character:A+t},properties:{"data-diff-span":""},alwaysWrap:!0}}function Fa({item:e,arr:A,enableJoin:t,isNeutral:r=!1,isLastItem:n=!1}){const i=A[A.length-1];if(i==null||n||!t){A.push([r?0:1,e.value]);return}const o=i[0]===0;if(r===o||r&&e.value.length===1&&!o){i[1]+=e.value;return}A.push([r?0:1,e.value])}function Ly(e,A,t,r=!1){const n=(()=>{const B=t.theme??Vt;if(typeof B=="string")return A.getTheme(B).type})(),i=My({theme:t.theme,highlighter:A});if(e.newLines!=null&&e.oldLines!=null){const{oldContent:B,newContent:a,oldInfo:s,newInfo:C,oldDecorations:E,newDecorations:I}=rf({hunks:e.hunks,oldLines:e.oldLines,newLines:e.newLines,lineDiffType:t.lineDiffType});return{code:nf({oldFile:{name:e.prevName??e.name,contents:B},oldInfo:s,oldDecorations:E,newFile:{name:e.name,contents:a},newInfo:C,newDecorations:I,highlighter:A,options:t,languageOverride:r?"text":e.lang}),themeStyles:i,baseThemeType:n}}const o=[];let g=0,Q=0;for(const B of e.hunks){const{oldContent:a,newContent:s,oldInfo:C,newInfo:E,oldDecorations:I,newDecorations:c,splitLineIndex:u,unifiedLineIndex:h}=rf({hunks:[B],splitLineIndex:g,unifiedLineIndex:Q,lineDiffType:t.lineDiffType}),d={name:e.prevName??e.name,contents:a},f={name:e.name,contents:s};o.push(nf({oldFile:d,oldInfo:C,oldDecorations:I,newFile:f,newInfo:E,newDecorations:c,highlighter:A,options:t,languageOverride:r?"text":e.lang})),g=u,Q=h}return{code:(()=>{if(o.length<=1){const B=o[0]??{oldLines:[],newLines:[]};if(B.newLines.length===0||B.oldLines.length===0)return B}return{hunks:o}})(),themeStyles:i,baseThemeType:n}}function Uq({oldLine:e,newLine:A,oldLineIndex:t,newLineIndex:r,oldDecorations:n,newDecorations:i,lineDiffType:o}){if(e==null||A==null||o==="none")return;e=Go(e),A=Go(A);const g=o==="char"?yq(e,A):vq(e,A),Q=[],B=[],a=o==="word-alt";for(const C of g){const E=C===g[g.length-1];!C.added&&!C.removed?(Fa({item:C,arr:Q,enableJoin:a,isNeutral:!0,isLastItem:E}),Fa({item:C,arr:B,enableJoin:a,isNeutral:!0,isLastItem:E})):C.removed?Fa({item:C,arr:Q,enableJoin:a,isLastItem:E}):Fa({item:C,arr:B,enableJoin:a,isLastItem:E})}let s=0;for(const C of Q)C[0]===1&&n.push(tf({line:t-1,spanStart:s,spanLength:C[1].length})),s+=C[1].length;s=0;for(const C of B)C[0]===1&&i.push(tf({line:r-1,spanStart:s,spanLength:C[1].length})),s+=C[1].length}function rf({hunks:e,oldLines:A,newLines:t,splitLineIndex:r=0,unifiedLineIndex:n=0,lineDiffType:i}){const o={},g={},Q=[],B=[];let a=1,s=1,C=1,E=1,I="",c="";for(const u of e){for(;A!=null&&t!=null&&a{switch(A.side){case"deletions":return this.deletionAnnotations;case"additions":return this.additionAnnotations}})(),r=t[A.lineNumber]??[];t[A.lineNumber]=r,r.push(A)}}getOptionsWithDefaults(){const{diffIndicators:e="bars",diffStyle:A="split",disableBackground:t=!1,disableFileHeader:r=!1,disableLineNumbers:n=!1,expandUnchanged:i=!1,expansionLineCount:o=100,hunkSeparators:g="line-info",lineDiffType:Q="word-alt",maxLineDiffLength:B=1e3,overflow:a="scroll",theme:s=Vt,themeType:C="system",tokenizeMaxLineLength:E=1e3,useCSSClasses:I=!1}=this.options;return{diffIndicators:e,diffStyle:A,disableBackground:t,disableFileHeader:r,disableLineNumbers:n,expandUnchanged:i,expansionLineCount:o,hunkSeparators:g,lineDiffType:Q,maxLineDiffLength:B,overflow:a,theme:this.workerManager?.getDiffRenderOptions().theme??s,themeType:C,tokenizeMaxLineLength:E,useCSSClasses:I}}async initializeHighlighter(){return this.highlighter=await oB(ky(this.computedLang,this.options)),this.highlighter}hydrate(e){if(e==null)return;this.diff=e;const{options:A}=this.getRenderOptions(e);let t=this.workerManager?.getDiffResultCache(e);t!=null&&!aI(A,t.options)&&(t=void 0),this.renderCache??={diff:e,highlighted:!0,options:A,result:t?.result},this.workerManager?.isWorkingPool()===!0&&this.renderCache.result==null?this.workerManager.highlightDiffAST(this,this.diff):this.asyncHighlight(e).then(({result:r,options:n})=>{this.onHighlightSuccess(e,r,n)})}getRenderOptions(e){const A=(()=>{if(this.workerManager?.isWorkingPool()===!0)return this.workerManager.getDiffRenderOptions();const{theme:r,tokenizeMaxLineLength:n,lineDiffType:i}=this.getOptionsWithDefaults();return{theme:r,tokenizeMaxLineLength:n,lineDiffType:i}})();this.getOptionsWithDefaults();const{renderCache:t}=this;return t?.result==null?{options:A,forceRender:!0}:e!==t.diff||!aI(A,t.options)?{options:A,forceRender:!0}:{options:A,forceRender:!1}}renderDiff(e=this.renderCache?.diff){if(e==null)return;const A=this.workerManager?.getDiffResultCache(e);A!=null&&this.renderCache==null&&(this.renderCache={diff:e,highlighted:!0,...A});const{options:t,forceRender:r}=this.getRenderOptions(e);if(this.renderCache??={diff:e,highlighted:!1,options:t,result:void 0},this.workerManager?.isWorkingPool()===!0)this.renderCache.result??=this.workerManager.getPlainDiffAST(e),(!this.renderCache.highlighted||r)&&this.workerManager.highlightDiffAST(this,e);else{this.computedLang=e.lang??fn(e.name);const n=this.highlighter!=null&&jQ(t.theme),i=this.highlighter!=null&&xs(this.computedLang);if(this.highlighter!=null&&n&&(r||!this.renderCache.highlighted&&i||this.renderCache.result==null)){const{result:o,options:g}=this.renderDiffWithHighlighter(e,this.highlighter,!i);this.renderCache={diff:e,options:g,highlighted:i,result:o}}(!n||!i)&&this.asyncHighlight(e).then(({result:o,options:g})=>{this.onHighlightSuccess(e,o,g)})}return this.renderCache.result!=null?this.processDiffResult(this.renderCache.diff,this.renderCache.result):void 0}async asyncRender(e){const{result:A}=await this.asyncHighlight(e);return this.processDiffResult(e,A)}createPreElement(e,A,t,r){const{diffIndicators:n,disableBackground:i,disableLineNumbers:o,overflow:g,themeType:Q}=this.getOptionsWithDefaults();return py({diffIndicators:n,disableBackground:i,disableLineNumbers:o,overflow:g,themeStyles:t,split:e,themeType:r??Q,totalLines:A})}async asyncHighlight(e){this.computedLang=e.lang??fn(e.name);const A=this.highlighter!=null&&jQ(this.options.theme??Vt),t=this.highlighter!=null&&xs(this.computedLang);return(this.highlighter==null||!A||!t)&&(this.highlighter=await this.initializeHighlighter()),this.renderDiffWithHighlighter(e,this.highlighter)}renderDiffWithHighlighter(e,A,t=!1){const{options:r}=this.getRenderOptions(e);return{result:Ly(e,A,r,t),options:r}}onHighlightSuccess(e,A,t){if(this.renderCache==null)return;const r=this.renderCache.diff!==e||!this.renderCache.highlighted||!aI(this.renderCache.options,t);this.renderCache={diff:e,options:t,highlighted:!0,result:A},r&&this.onRenderUpdate?.()}onHighlightError(e){console.error(e)}processDiffResult(e,{code:A,themeStyles:t,baseThemeType:r}){const{diffStyle:n,disableFileHeader:i}=this.getOptionsWithDefaults();this.diff=e;const o=n==="unified";let g=[],Q=[],B=[],a=0;const s=[];let C,E=0;for(const u of e.hunks)E+=u.collapsedBefore,E=this.renderHunks({ast:A,hunk:u,prevHunk:C,hunkIndex:a,isLastHunk:a===e.hunks.length-1,additionsAST:g,deletionsAST:Q,unifiedAST:B,hunkData:s,lineIndex:E}),a++,C=u;const I=Math.max(mq(e.hunks),e.newLines?.length??0,e.oldLines?.length??0);g=!o&&(A.hunks!=null||A.newLines.length>0)?g:void 0,Q=!o&&(A.hunks!=null||A.oldLines.length>0)?Q:void 0,B=B.length>0?B:void 0;const c=this.createPreElement(Q!=null&&g!=null,I,t,r);return{additionsAST:g,deletionsAST:Q,unifiedAST:B,hunkData:s,preNode:c,themeStyles:t,baseThemeType:r,headerElement:i?void 0:this.renderHeader(this.diff,t,r),totalLines:I,css:""}}renderFullAST(e,A=[]){return e.unifiedAST!=null&&A.push(Fe({tagName:"code",children:e.unifiedAST,properties:{"data-code":"","data-unified":""}})),e.deletionsAST!=null&&A.push(Fe({tagName:"code",children:e.deletionsAST,properties:{"data-code":"","data-deletions":""}})),e.additionsAST!=null&&A.push(Fe({tagName:"code",children:e.additionsAST,properties:{"data-code":"","data-additions":""}})),{...e.preNode,children:A}}renderFullHTML(e,A=[]){return Xn(this.renderFullAST(e,A))}renderPartialHTML(e,A){return A==null?Xn(e):Xn(Fe({tagName:"code",children:e,properties:{"data-code":"",[`data-${A}`]:""}}))}renderCollapsedHunks({ast:e,hunkData:A,hunkIndex:t,hunkSpecs:r,isFirstHunk:n,isLastHunk:i,rangeSize:o,lineIndex:g,additionLineNumber:Q,deletionLineNumber:B,unifiedAST:a,deletionsAST:s,additionsAST:C}){if(o<=0)return;const{hunkSeparators:E,expandUnchanged:I,diffStyle:c,expansionLineCount:u}=this.getOptionsWithDefaults(),h=e.hunks==null&&e.newLines.length>0&&e.oldLines.length>0,d=this.expandedHunks.get(t)??Kq,f=o>u,m=Math.max(I?0:o-(d.fromEnd+d.fromStart),0),k=({type:F,linesAST:L})=>{if(E==="line-info"||E==="custom"){const v=wq(F,t);L.push(BI({type:E,content:Rq(m),expandIndex:h?t:void 0,chunked:f,slotName:v,isFirstHunk:n,isLastHunk:i})),A.push({slotName:v,hunkIndex:t,lines:m,type:F,expandable:h?{up:h&&!n,down:h,chunked:f}:void 0})}else E==="metadata"&&r!=null?L.push(BI({type:"metadata",content:r,isFirstHunk:n,isLastHunk:i})):E==="simple"&&t>0&&L.push(BI({type:"simple",isFirstHunk:n,isLastHunk:!1}))},N=({rangeLen:F,fromStart:L})=>{if(e.newLines==null||e.oldLines==null)return;const v=i?0:L?o:F;let O=B-v,W=Q-v,AA=g-v;for(let kA=0;kA0&&(c==="unified"?k({type:"unified",linesAST:a}):(k({type:"deletions",linesAST:s}),k({type:"additions",linesAST:C}))),m>0&&d.fromEnd>0&&!i&&N({rangeLen:Math.min(d.fromEnd,o),fromStart:!1})}renderHunks({hunk:e,hunkData:A,hunkIndex:t,lineIndex:r,isLastHunk:n,prevHunk:i,ast:o,deletionsAST:g,additionsAST:Q,unifiedAST:B}){const{diffStyle:a}=this.getOptionsWithDefaults(),s=a==="unified";let C=e.additionStart-1,E=e.deletionStart-1;this.renderCollapsedHunks({additionLineNumber:C,additionsAST:Q,ast:o,deletionLineNumber:E,deletionsAST:g,hunkData:A,hunkIndex:t,hunkSpecs:e.hunkSpecs,isFirstHunk:i==null,isLastHunk:!1,lineIndex:r,rangeSize:Math.max(e.collapsedBefore,0),unifiedAST:B});let{oldLines:I,newLines:c,oldIndex:u,newIndex:h}=(()=>{if(o.hunks!=null){const d=o.hunks[t];if(d==null)throw console.error({ast:o,hunkIndex:t}),new Error("DiffHunksRenderer.renderHunks: lineHunk doesn't exist");return{oldLines:d.oldLines,newLines:d.newLines,oldIndex:0,newIndex:0}}return{oldLines:o.oldLines,newLines:o.newLines,oldIndex:E,newIndex:C}})();for(const d of e.hunkContent)if(d.type==="context"){const{length:f}=d.lines;for(let m=0;m{let O=I[u],W=c[h];if(s?F=f&&(O=void 0),F>=m&&(W=void 0)),O==null&&W==null)throw console.error({i:F,len:k,ast:o,hunkContent:d}),new Error("renderHunks: oldLine and newLine are null, something is wrong");return{oldLine:O,newLine:W}})();if(L!=null&&(u++,E++),v!=null&&(h++,C++),s)this.pushLineWithAnnotation({oldLine:L,newLine:v,unifiedAST:B,unifiedSpan:this.getAnnotations("unified",L!=null?E:void 0,v!=null?C:void 0,t,r)}),r++;else{(L==null||v==null)&&N++;const O=this.getAnnotations("split",L!=null?E:void 0,v!=null?C:void 0,t,r);O!=null&&N>0&&(m>f?g.push(og(N)):Q.push(og(N)),N=0),this.pushLineWithAnnotation({newLine:v,oldLine:L,deletionsAST:g,additionsAST:Q,...O}),r++}}s||(N>0&&(m>f?g.push(og(N)):Q.push(og(N)),N=0),d.noEOFCRDeletions&&(g.push(gI("change-deletion")),d.noEOFCRAdditions||Q.push(og(1))),d.noEOFCRAdditions&&(Q.push(gI("change-addition")),d.noEOFCRDeletions||g.push(og(1))))}return n&&o.newLines!=null&&o.newLines.length>0&&this.renderCollapsedHunks({additionLineNumber:C,additionsAST:Q,ast:o,deletionLineNumber:E,deletionsAST:g,hunkData:A,hunkIndex:t+1,hunkSpecs:void 0,isFirstHunk:!1,isLastHunk:!0,lineIndex:r,rangeSize:Math.max(o.newLines.length-Math.max(e.additionStart+e.additionCount-1,0),0),unifiedAST:B}),r}pushLineWithAnnotation({newLine:e,oldLine:A,unifiedAST:t,additionsAST:r,deletionsAST:n,unifiedSpan:i,deletionSpan:o,additionSpan:g}){t!=null?(A!=null?t.push(A):e!=null&&t.push(e),i!=null&&t.push($a(i))):n!=null&&r!=null&&(A!=null&&n.push(A),e!=null&&r.push(e),o!=null&&n.push($a(o)),g!=null&&r.push($a(g)))}getAnnotations(e,A,t,r,n){const i={type:"annotation",hunkIndex:r,lineIndex:n,annotations:[]};if(A!=null)for(const g of this.deletionAnnotations[A]??[])i.annotations.push(QB(g));const o={type:"annotation",hunkIndex:r,lineIndex:n,annotations:[]};if(t!=null)for(const g of this.additionAnnotations[t]??[])(e==="unified"?i:o).annotations.push(QB(g));if(e==="unified")return i.annotations.length>0?i:void 0;if(!(o.annotations.length===0&&i.annotations.length===0))return{deletionSpan:i,additionSpan:o}}renderHeader(e,A,t){const{themeType:r}=this.getOptionsWithDefaults();return my({fileOrDiff:e,themeStyles:A,themeType:t??r})}};function aI(e,A){return Du(e.theme,A.theme)&&e.tokenizeMaxLineLength===A.tokenizeMaxLineLength&&e.lineDiffType===A.lineDiffType}function Rq(e){return`${e} unmodified line${e>1?"s":""}`}function Oq(e){const A=e[0];if(A!=="+"&&A!=="-"&&A!==" "&&A!=="\\"){console.error(`parseLineType: Invalid firstChar: "${A}", full line: "${e}"`);return}return{line:e.substring(1),type:A===" "?"context":A==="\\"?"metadata":A==="+"?"addition":"deletion"}}function qq(e,A){const t=$C.test(e),r=e.split(t?$C:YD);let n;const i=[];let o;for(const g of r){if(t&&!$C.test(g)){n==null?n=g:console.error("parsePatchContent: unknown file blob:",g);continue}else if(!t&&!YD.test(g)){n==null?n=g:console.error("parsePatchContent: unknown file blob:",g);continue}let Q=0;const B=g.split(OR);o=void 0;for(const a of B){const s=a.split(fl),C=s.shift();if(C==null){console.error("parsePatchContent: invalid hunk",a);continue}const E=C.match(qR),I=[];let c=0,u=0;if(E==null||o==null){if(o!=null){console.error("parsePatchContent: Invalid hunk",a);continue}o={name:"",prevName:void 0,type:"change",hunks:[],splitLineCount:0,unifiedLineCount:0,cacheKey:void 0},s.unshift(C);for(const d of s){const f=d.match(t?HR:TR);if(d.startsWith("diff --git")){const[,,m,,k]=d.trim().match(YR)??[];o.name=k.trim(),m!==k&&(o.prevName=m.trim())}else if(f!=null){const[,m,k]=f;m==="---"&&k!=="/dev/null"?(o.prevName=k.trim(),o.name=k.trim()):m==="+++"&&k!=="/dev/null"&&(o.name=k.trim())}else if(t){if(d.startsWith("new mode ")&&(o.mode=d.replace("new mode","").trim()),d.startsWith("old mode ")&&(o.oldMode=d.replace("old mode","").trim()),d.startsWith("new file mode")&&(o.type="new",o.mode=d.replace("new file mode","").trim()),d.startsWith("deleted file mode")&&(o.type="deleted",o.mode=d.replace("deleted file mode","").trim()),d.startsWith("similarity index")&&(d.startsWith("similarity index 100%")?o.type="rename-pure":o.type="rename-changed"),d.startsWith("index ")){const[,m]=d.trim().match(zR)??[];m!=null&&(o.mode=m)}d.startsWith("rename from ")&&(o.prevName=d.replace("rename from ","")),d.startsWith("rename to ")&&(o.name=d.replace("rename to ","").trim())}}continue}else{let d,f;for(;s.length>0&&(s[s.length-1]===` `||s[s.length-1]==="");)s.pop();for(const m of s){const k=Oq(m);if(k==null)continue;const{type:N,line:F}=k;if(N==="addition")(d==null||d.type!=="change")&&(d=sI("change"),I.push(d)),d.additions.push(F),c++,f="addition";else if(N==="deletion")(d==null||d.type!=="change")&&(d=sI("change"),I.push(d)),d.deletions.push(F),u++,f="deletion";else if(N==="context")(d==null||d.type!=="context")&&(d=sI("context"),I.push(d)),d.lines.push(F),f="context";else if(N==="metadata"&&d!=null){if(d.type==="context")d.noEOFCR=!0;else if(f==="deletion"){d.noEOFCRDeletions=!0;const L=d.deletions.length-1;L>=0&&(d.deletions[L]=Go(d.deletions[L]))}else if(f==="addition"){d.noEOFCRAdditions=!0;const L=d.additions.length-1;L>=0&&(d.additions[L]=Go(d.additions[L]))}}}}const h={collapsedBefore:0,splitLineCount:0,splitLineStart:0,unifiedLineCount:0,unifiedLineStart:0,additionCount:parseInt(E[4]??"1"),additionStart:parseInt(E[3]),additionLines:c,deletionCount:parseInt(E[2]??"1"),deletionStart:parseInt(E[1]),deletionLines:u,hunkContent:I,hunkContext:E[5],hunkSpecs:C};if(isNaN(h.additionCount)||isNaN(h.deletionCount)||isNaN(h.additionStart)||isNaN(h.deletionStart)){console.error("parsePatchContent: invalid hunk metadata",h);continue}h.collapsedBefore=Math.max(h.additionStart-1-Q,0),o.hunks.push(h),Q=h.additionStart+h.additionCount-1;for(const d of I)d.type==="context"?(h.splitLineCount+=d.lines.length,h.unifiedLineCount+=d.lines.length):(h.splitLineCount+=Math.max(d.additions.length,d.deletions.length),h.unifiedLineCount+=d.deletions.length+d.additions.length);h.splitLineStart=o.splitLineCount,h.unifiedLineStart=o.unifiedLineCount,o.splitLineCount+=h.splitLineCount,o.unifiedLineCount+=h.unifiedLineCount}o!=null&&(!t&&o.prevName!=null&&o.name!==o.prevName&&(o.hunks.length>0?o.type="rename-changed":o.type="rename-pure"),o.type!=="rename-pure"&&o.type!=="rename-changed"&&(o.prevName=void 0),i.push(o))}return{patchMetadata:n,files:i}}function Tq(e,A){const t=[];for(const r of e.split(RR))try{t.push(qq(r,A!=null?`${A}-${t.length}`:void 0))}catch(n){console.error(n)}return t}function sI(e){return e==="change"?{type:"change",additions:[],deletions:[],noEOFCRAdditions:!1,noEOFCRDeletions:!1}:{type:"context",lines:[],noEOFCR:!1}}function of(e,A){const t=Tq(Sq(e.name,A.name,e.contents,A.contents,e.header,A.header))[0]?.files[0];if(t==null)throw new Error("parseDiffFrom: FileInvalid diff -- probably need to fix something -- if the files are the same maybe?");return t.oldLines=e.contents.split(fl),t.newLines=A.contents.split(fl),e.cacheKey!=null&&A.cacheKey!=null&&(t.cacheKey=`${e.cacheKey}:${A.cacheKey}`),t}let Hq=-1;var Yq=class{static LoadedCustomComponent=Uy;__id=++Hq;fileContainer;spriteSVG;pre;unsafeCSSStyle;hoverContent;headerElement;headerMetadata;customHunkElements=[];errorWrapper;hunksRenderer;resizeManager;scrollSyncManager;mouseEventManager;lineSelectionManager;annotationElements=[];lineAnnotations=[];oldFile;newFile;fileDiff;constructor(e={theme:Vt},A,t=!1){this.options=e,this.workerManager=A,this.isContainerManaged=t,this.hunksRenderer=new Lq({...e,hunkSeparators:typeof e.hunkSeparators=="function"?"custom":e.hunkSeparators},this.handleHighlightRender,this.workerManager),this.resizeManager=new ty,this.scrollSyncManager=new fq,this.mouseEventManager=new ey("diff",Fs(e,typeof e.hunkSeparators=="function"||(e.hunkSeparators??"line-info")==="line-info"?this.handleExpandHunk:void 0)),this.lineSelectionManager=new Ay(bs(e)),this.workerManager?.subscribeToThemeChanges(this)}handleHighlightRender=()=>{this.rerender()};setOptions(e){e!=null&&(this.options=e,this.hunksRenderer.setOptions({...this.options,hunkSeparators:typeof e.hunkSeparators=="function"?"custom":e.hunkSeparators}),this.mouseEventManager.setOptions(Fs(e,typeof e.hunkSeparators=="function"||(e.hunkSeparators??"line-info")==="line-info"?this.handleExpandHunk:void 0)),this.lineSelectionManager.setOptions(bs(e)))}mergeOptions(e){this.options={...this.options,...e}}setThemeType(e){if((this.options.themeType??"system")!==e&&(this.mergeOptions({themeType:e}),this.hunksRenderer.setThemeType(e),this.headerElement!=null&&(e==="system"?delete this.headerElement.dataset.themeType:this.headerElement.dataset.themeType=e),this.pre!=null))switch(e){case"system":delete this.pre.dataset.themeType;break;case"light":case"dark":this.pre.dataset.themeType=e;break}}getHoveredLine=()=>this.mouseEventManager.getHoveredLine();setLineAnnotations(e){this.lineAnnotations=e}setSelectedLines(e){this.lineSelectionManager.setSelection(e)}cleanUp(){this.hunksRenderer.cleanUp(),this.resizeManager.cleanUp(),this.mouseEventManager.cleanUp(),this.scrollSyncManager.cleanUp(),this.lineSelectionManager.cleanUp(),this.workerManager?.unsubscribeToThemeChanges(this),this.workerManager=void 0,this.fileDiff=void 0,this.oldFile=void 0,this.newFile=void 0,this.isContainerManaged||this.fileContainer?.parentNode?.removeChild(this.fileContainer),this.fileContainer?.shadowRoot!=null&&(this.fileContainer.shadowRoot.innerHTML=""),this.fileContainer=void 0,this.pre=void 0,this.headerElement=void 0,this.errorWrapper=void 0}hydrate(e){const{fileContainer:A,prerenderedHTML:t}=e;Sy(A,t);for(const r of Array.from(A.shadowRoot?.children??[])){if(r instanceof SVGElement){this.spriteSVG=r;continue}if(r instanceof HTMLElement){if(r instanceof HTMLPreElement){this.pre=r;continue}if("diffsHeader"in r.dataset){this.headerElement=r;continue}if(r instanceof HTMLStyleElement&&r.hasAttribute(Cu)){this.unsafeCSSStyle=r;continue}}}if(this.pre==null)this.render(e);else{const{lineAnnotations:r,oldFile:n,newFile:i,fileDiff:o}=e;this.fileContainer=A,delete this.pre.dataset.dehydrated,this.lineAnnotations=r??this.lineAnnotations,this.newFile=i,this.oldFile=n,this.fileDiff=o??(n!=null&&i!=null?of(n,i):void 0),this.hunksRenderer.hydrate(this.fileDiff),this.renderAnnotations(),this.renderHoverUtility(),this.injectUnsafeCSS(),this.mouseEventManager.setup(this.pre),this.lineSelectionManager.setup(this.pre),(this.options.overflow??"scroll")==="scroll"&&(this.resizeManager.setup(this.pre),this.scrollSyncManager.setup(this.pre))}}rerender(){this.fileDiff==null&&this.newFile==null&&this.oldFile==null||this.render({oldFile:this.oldFile,newFile:this.newFile,fileDiff:this.fileDiff,forceRender:!0})}handleExpandHunk=(e,A)=>{this.expandHunk(e,A)};expandHunk(e,A){this.hunksRenderer.expandHunk(e,A),this.rerender()}render({oldFile:e,newFile:A,fileDiff:t,forceRender:r=!1,lineAnnotations:n,fileContainer:i,containerWrapper:o}){const g=e!=null&&A!=null&&(!bl(e,this.oldFile)||!bl(A,this.newFile)),Q=n!=null&&(n.length>0||this.lineAnnotations.length>0)?n!==this.lineAnnotations:!1;if(!r&&!Q&&(t!=null&&t===this.fileDiff||t==null&&!g)||(this.oldFile=e,this.newFile=A,t!=null?this.fileDiff=t:e!=null&&A!=null&&g&&(this.fileDiff=of(e,A)),n!=null&&this.setLineAnnotations(n),this.fileDiff==null))return;this.hunksRenderer.setOptions({...this.options,hunkSeparators:typeof this.options.hunkSeparators=="function"?"custom":this.options.hunkSeparators}),this.hunksRenderer.setLineAnnotations(this.lineAnnotations);const{disableFileHeader:B=!1}=this.options;B&&this.headerElement!=null&&(this.headerElement.parentNode?.removeChild(this.headerElement),this.headerElement=void 0),i=this.getOrCreateFileContainer(i,o);try{const a=this.hunksRenderer.renderDiff(this.fileDiff);if(a==null){this.workerManager!=null&&!this.workerManager.isInitialized()&&this.workerManager.initialize().then(()=>this.rerender());return}a.headerElement!=null&&this.applyHeaderToDOM(a.headerElement,i);const s=this.getOrCreatePreNode(i);this.applyHunksToDOM(s,a),this.renderSeparators(a.hunkData),this.renderAnnotations(),this.renderHoverUtility()}catch(a){a instanceof Error&&this.applyErrorToDOM(a,i)}}renderSeparators(e){const{hunkSeparators:A}=this.options;if(!(this.isContainerManaged||this.fileContainer==null||typeof A!="function")){for(const t of this.customHunkElements)t.parentNode?.removeChild(t);this.customHunkElements.length=0;for(const t of e){const r=document.createElement("div");r.style.display="contents",r.slot=t.slotName,r.appendChild(A(t,this)),this.fileContainer.appendChild(r),this.customHunkElements.push(r)}}}renderAnnotations(){if(this.isContainerManaged||this.fileContainer==null)return;for(const A of this.annotationElements)A.parentNode?.removeChild(A);this.annotationElements.length=0;const{renderAnnotation:e}=this.options;if(e!=null&&this.lineAnnotations.length>0)for(const A of this.lineAnnotations){const t=e(A);if(t==null)continue;const r=by(QB(A));r.appendChild(t),this.annotationElements.push(r),this.fileContainer.appendChild(r)}}renderHoverUtility(){const{renderHoverUtility:e}=this.options;if(this.fileContainer==null||e==null)return;this.hoverContent==null&&(this.hoverContent=Fy(),this.fileContainer.appendChild(this.hoverContent));const A=e(this.mouseEventManager.getHoveredLine);this.hoverContent.innerHTML="",A!=null&&this.hoverContent.appendChild(A)}getOrCreateFileContainer(e,A){if(this.fileContainer=e??this.fileContainer??document.createElement(vs),A!=null&&this.fileContainer.parentNode!==A&&A.appendChild(this.fileContainer),this.spriteSVG==null){const t=document.createElement("div");t.innerHTML=vy;const r=t.firstChild;r instanceof SVGElement&&(this.spriteSVG=r,this.fileContainer.shadowRoot?.appendChild(this.spriteSVG))}return this.fileContainer}getFileContainer(){return this.fileContainer}getOrCreatePreNode(e){return this.pre==null?(this.pre=document.createElement("pre"),e.shadowRoot?.appendChild(this.pre)):this.pre.parentNode!==e&&e.shadowRoot?.appendChild(this.pre),this.pre}applyHeaderToDOM(e,A){this.cleanupErrorWrapper();const t=document.createElement("div");t.innerHTML=Xn(e);const r=t.firstElementChild;if(!(r instanceof HTMLElement)||(this.headerElement!=null?A.shadowRoot?.replaceChild(r,this.headerElement):A.shadowRoot?.prepend(r),this.headerElement=r,this.isContainerManaged))return;const{renderHeaderMetadata:n}=this.options;this.headerMetadata!=null&&this.headerMetadata.parentNode?.removeChild(this.headerMetadata);const i=n?.({oldFile:this.oldFile,newFile:this.newFile,fileDiff:this.fileDiff})??void 0;i!=null&&(this.headerMetadata=document.createElement("div"),this.headerMetadata.slot=Eu,i instanceof Element?this.headerMetadata.appendChild(i):this.headerMetadata.innerText=`${i}`,A.appendChild(this.headerMetadata))}injectUnsafeCSS(){if(this.fileContainer?.shadowRoot==null)return;const{unsafeCSS:e}=this.options;e==null||e===""||(this.unsafeCSSStyle==null&&(this.unsafeCSSStyle=xy(),this.fileContainer.shadowRoot.appendChild(this.unsafeCSSStyle)),this.unsafeCSSStyle.innerText=Gy(e))}applyHunksToDOM(e,A){this.cleanupErrorWrapper(),this.applyPreNodeAttributes(e,A),e.innerHTML="";let t,r;if(A.unifiedAST!=null){const n=As({columnType:"unified"});n.innerHTML=this.hunksRenderer.renderPartialHTML(A.unifiedAST),e.appendChild(n)}else A.deletionsAST!=null&&(t=As({columnType:"deletions"}),t.innerHTML=this.hunksRenderer.renderPartialHTML(A.deletionsAST),e.appendChild(t)),A.additionsAST!=null&&(r=As({columnType:"additions"}),r.innerHTML=this.hunksRenderer.renderPartialHTML(A.additionsAST),e.appendChild(r));this.injectUnsafeCSS(),this.mouseEventManager.setup(e),this.lineSelectionManager.setup(e),(this.options.overflow??"scroll")==="scroll"?(this.resizeManager.setup(e),this.scrollSyncManager.setup(e,t,r)):(this.resizeManager.cleanUp(),this.scrollSyncManager.cleanUp())}applyPreNodeAttributes(e,{themeStyles:A,baseThemeType:t,additionsAST:r,deletionsAST:n,totalLines:i}){const{diffIndicators:o="bars",disableBackground:g=!1,disableLineNumbers:Q=!1,overflow:B="scroll",themeType:a="system",diffStyle:s="split"}=this.options;Jy({pre:e,diffIndicators:o,disableBackground:g,disableLineNumbers:Q,overflow:B,split:s==="unified"?!1:r!=null&&n!=null,themeStyles:A,themeType:t??a,totalLines:i})}applyErrorToDOM(e,A){this.cleanupErrorWrapper();const t=this.getOrCreatePreNode(A);t.innerHTML="",t.parentNode?.removeChild(t),this.pre=void 0;const r=A.shadowRoot??A.attachShadow({mode:"open"});this.errorWrapper??=document.createElement("div"),this.errorWrapper.dataset.errorWrapper="",this.errorWrapper.innerHTML="",r.appendChild(this.errorWrapper);const n=document.createElement("div");n.dataset.errorMessage="",n.innerText=e.message,this.errorWrapper.appendChild(n);const i=document.createElement("pre");i.dataset.errorStack="",i.innerText=e.stack??"No Error Stack",this.errorWrapper.appendChild(i)}cleanupErrorWrapper(){this.errorWrapper?.parentNode?.removeChild(this.errorWrapper),this.errorWrapper=void 0}};function gf(e){const A=[];for(const t of e){const r=xo.get(t);if(r==null)throw new Error(`getResolvedLanguages: ${t} is not resolved. Please resolve languages before calling getResolvedLanguages`);A.push(r)}return A}function Qf(e){for(const A of Array.isArray(e)?e:[e])if(!xo.has(A))return!1;return!0}async function Bf(e){const A=[],t=[];for(const r of e){if(r==="text")continue;const n=hy(r)??dy(r);"then"in n?t.push(n):A.push(n)}return t.length>0&&await Promise.all(t).then(r=>{for(const n of r){if(n==null)throw new Error("resolvedLanguages: unable to resolve language");A.push(n)}}),A}function af(e){const A=[];for(const t of e){const r=Ai.get(t);if(r==null)throw new Error(`getAllResolvedThemes: ${t} is unresolved, you must resolve all necessary themes before calling this function`);A.push(r)}return A}async function sf(e){const A=[],t=[];for(const r of e){const n=fy(r)??Dy(r);"then"in n?t.push(n):A.push(n)}return t.length>0&&await Promise.all(t).then(r=>{for(const n of r)n!=null&&A.push(n)}),A}hu("OpenCode",()=>Promise.resolve({name:"OpenCode",colors:{"editor.background":"transparent","editor.foreground":"var(--text-base)","gitDecoration.addedResourceForeground":"var(--syntax-diff-add)","gitDecoration.deletedResourceForeground":"var(--syntax-diff-delete)"},tokenColors:[{scope:["comment","punctuation.definition.comment","string.comment"],settings:{foreground:"var(--syntax-comment)"}},{scope:["entity.other.attribute-name"],settings:{foreground:"var(--syntax-property)"}},{scope:["constant","entity.name.constant","variable.other.constant","variable.language","entity"],settings:{foreground:"var(--syntax-constant)"}},{scope:["entity.name","meta.export.default","meta.definition.variable"],settings:{foreground:"var(--syntax-type)"}},{scope:["meta.object.member"],settings:{foreground:"var(--syntax-primitive)"}},{scope:["variable.parameter.function","meta.jsx.children","meta.block","meta.tag.attributes","entity.name.constant","meta.embedded.expression","meta.template.expression","string.other.begin.yaml","string.other.end.yaml"],settings:{foreground:"var(--syntax-punctuation)"}},{scope:["entity.name.function","support.type.primitive"],settings:{foreground:"var(--syntax-primitive)"}},{scope:["support.class.component"],settings:{foreground:"var(--syntax-type)"}},{scope:"keyword",settings:{foreground:"var(--syntax-keyword)"}},{scope:["keyword.operator","storage.type.function.arrow","punctuation.separator.key-value.css","entity.name.tag.yaml","punctuation.separator.key-value.mapping.yaml"],settings:{foreground:"var(--syntax-operator)"}},{scope:["storage","storage.type"],settings:{foreground:"var(--syntax-keyword)"}},{scope:["storage.modifier.package","storage.modifier.import","storage.type.java"],settings:{foreground:"var(--syntax-primitive)"}},{scope:["string","punctuation.definition.string","string punctuation.section.embedded source","entity.name.tag"],settings:{foreground:"var(--syntax-string)"}},{scope:"support",settings:{foreground:"var(--syntax-primitive)"}},{scope:["support.type.object.module","variable.other.object","support.type.property-name.css"],settings:{foreground:"var(--syntax-object)"}},{scope:"meta.property-name",settings:{foreground:"var(--syntax-property)"}},{scope:"variable",settings:{foreground:"var(--syntax-variable)"}},{scope:"variable.other",settings:{foreground:"var(--syntax-variable)"}},{scope:["invalid.broken","invalid.illegal","invalid.unimplemented","invalid.deprecated","message.error","markup.deleted","meta.diff.header.from-file","punctuation.definition.deleted","brackethighlighter.unmatched","token.error-token"],settings:{foreground:"var(--syntax-critical)"}},{scope:"carriage-return",settings:{foreground:"var(--syntax-keyword)"}},{scope:"string source",settings:{foreground:"var(--syntax-variable)"}},{scope:"string variable",settings:{foreground:"var(--syntax-constant)"}},{scope:["source.regexp","string.regexp","string.regexp.character-class","string.regexp constant.character.escape","string.regexp source.ruby.embedded","string.regexp string.regexp.arbitrary-repitition","string.regexp constant.character.escape"],settings:{foreground:"var(--syntax-regexp)"}},{scope:"support.constant",settings:{foreground:"var(--syntax-primitive)"}},{scope:"support.variable",settings:{foreground:"var(--syntax-variable)"}},{scope:"meta.module-reference",settings:{foreground:"var(--syntax-info)"}},{scope:"punctuation.definition.list.begin.markdown",settings:{foreground:"var(--syntax-punctuation)"}},{scope:["markup.heading","markup.heading entity.name"],settings:{fontStyle:"bold",foreground:"var(--syntax-info)"}},{scope:"markup.quote",settings:{foreground:"var(--syntax-info)"}},{scope:"markup.italic",settings:{fontStyle:"italic"}},{scope:"markup.bold",settings:{fontStyle:"bold",foreground:"var(--text-strong)"}},{scope:["markup.raw","markup.inserted","meta.diff.header.to-file","punctuation.definition.inserted","markup.changed","punctuation.definition.changed","markup.ignored","markup.untracked"],settings:{foreground:"var(--text-base)"}},{scope:"meta.diff.range",settings:{fontStyle:"bold",foreground:"var(--syntax-unknown)"}},{scope:"meta.diff.header",settings:{foreground:"var(--syntax-unknown)"}},{scope:"meta.separator",settings:{fontStyle:"bold",foreground:"var(--syntax-unknown)"}},{scope:"meta.output",settings:{foreground:"var(--syntax-unknown)"}},{scope:"meta.export.default",settings:{foreground:"var(--syntax-unknown)"}},{scope:["brackethighlighter.tag","brackethighlighter.curly","brackethighlighter.round","brackethighlighter.square","brackethighlighter.angle","brackethighlighter.quote"],settings:{foreground:"var(--syntax-unknown)"}},{scope:["constant.other.reference.link","string.other.link"],settings:{fontStyle:"underline",foreground:"var(--syntax-unknown)"}},{scope:"token.info-token",settings:{foreground:"var(--syntax-info)"}},{scope:"token.warn-token",settings:{foreground:"var(--syntax-warning)"}},{scope:"token.debug-token",settings:{foreground:"var(--syntax-info)"}}],semanticTokenColors:{comment:"var(--syntax-comment)",string:"var(--syntax-string)",number:"var(--syntax-constant)",regexp:"var(--syntax-regexp)",keyword:"var(--syntax-keyword)",variable:"var(--syntax-variable)",parameter:"var(--syntax-variable)",property:"var(--syntax-property)",function:"var(--syntax-primitive)",method:"var(--syntax-primitive)",type:"var(--syntax-type)",class:"var(--syntax-type)",namespace:"var(--syntax-type)",enumMember:"var(--syntax-primitive)","variable.constant":"var(--syntax-constant)","variable.defaultLibrary":"var(--syntax-unknown)"}}));const{use:zq,provider:Pq}=qt({name:"Marked",init:()=>Ye.use(PJ({throwOnError:!1}),VJ({async highlight(e,A){const t=await oB({themes:["OpenCode"],langs:[]});return A in eL||(A="text"),t.getLoadedLanguages().includes(A)||await t.loadLanguage(A),t.codeToHtml(e,{lang:A||"text",theme:"OpenCode",tabindex:!1})}}))}),Ry=qt({name:"DiffComponent",init:e=>e.component}),_q=Ry.provider,wu=Ry.use,Oy=qt({name:"CodeComponent",init:e=>e.component}),jq=Oy.provider,qy=Oy.use,Vq=` [data-diffs] { --diffs-bg: light-dark(var(--diffs-light-bg), var(--diffs-dark-bg)); --diffs-bg-buffer: var(--diffs-bg-buffer-override, light-dark( color-mix(in lab, var(--diffs-bg) 92%, var(--diffs-mixer)), color-mix(in lab, var(--diffs-bg) 92%, var(--diffs-mixer)))); --diffs-bg-hover: var(--diffs-bg-hover-override, light-dark( color-mix(in lab, var(--diffs-bg) 97%, var(--diffs-mixer)), color-mix(in lab, var(--diffs-bg) 91%, var(--diffs-mixer)))); --diffs-bg-context: var(--diffs-bg-context-override, light-dark( color-mix(in lab, var(--diffs-bg) 98.5%, var(--diffs-mixer)), color-mix(in lab, var(--diffs-bg) 92.5%, var(--diffs-mixer)))); --diffs-bg-separator: var(--diffs-bg-separator-override, light-dark( color-mix(in lab, var(--diffs-bg) 96%, var(--diffs-mixer)), color-mix(in lab, var(--diffs-bg) 85%, var(--diffs-mixer)))); --diffs-fg: light-dark(var(--diffs-light), var(--diffs-dark)); --diffs-fg-number: var(--diffs-fg-number-override, light-dark(color-mix(in lab, var(--diffs-fg) 65%, var(--diffs-bg)), color-mix(in lab, var(--diffs-fg) 65%, var(--diffs-bg)))); --diffs-deletion-base: var(--diffs-deletion-color-override, light-dark(var(--diffs-light-deletion-color, var(--diffs-deletion-color, rgb(255, 0, 0))), var(--diffs-dark-deletion-color, var(--diffs-deletion-color, rgb(255, 0, 0))))); --diffs-addition-base: var(--diffs-addition-color-override, light-dark(var(--diffs-light-addition-color, var(--diffs-addition-color, rgb(0, 255, 0))), var(--diffs-dark-addition-color, var(--diffs-addition-color, rgb(0, 255, 0))))); --diffs-modified-base: var(--diffs-modified-color-override, light-dark(var(--diffs-light-modified-color, var(--diffs-modified-color, rgb(0, 0, 255))), var(--diffs-dark-modified-color, var(--diffs-modified-color, rgb(0, 0, 255))))); --diffs-bg-deletion: var(--diffs-bg-deletion-override, light-dark( color-mix(in lab, var(--diffs-bg) 98%, var(--diffs-deletion-base)), color-mix(in lab, var(--diffs-bg) 92%, var(--diffs-deletion-base)))); --diffs-bg-deletion-number: var(--diffs-bg-deletion-number-override, light-dark( color-mix(in lab, var(--diffs-bg) 91%, var(--diffs-deletion-base)), color-mix(in lab, var(--diffs-bg) 85%, var(--diffs-deletion-base)))); --diffs-bg-deletion-hover: var(--diffs-bg-deletion-hover-override, light-dark( color-mix(in lab, var(--diffs-bg) 80%, var(--diffs-deletion-base)), color-mix(in lab, var(--diffs-bg) 75%, var(--diffs-deletion-base)))); --diffs-bg-deletion-emphasis: var(--diffs-bg-deletion-emphasis-override, light-dark(rgb(from var(--diffs-deletion-base) r g b / 0.7), rgb(from var(--diffs-deletion-base) r g b / 0.1))); --diffs-bg-addition: var(--diffs-bg-addition-override, light-dark( color-mix(in lab, var(--diffs-bg) 98%, var(--diffs-addition-base)), color-mix(in lab, var(--diffs-bg) 92%, var(--diffs-addition-base)))); --diffs-bg-addition-number: var(--diffs-bg-addition-number-override, light-dark( color-mix(in lab, var(--diffs-bg) 91%, var(--diffs-addition-base)), color-mix(in lab, var(--diffs-bg) 85%, var(--diffs-addition-base)))); --diffs-bg-addition-hover: var(--diffs-bg-addition-hover-override, light-dark( color-mix(in lab, var(--diffs-bg) 80%, var(--diffs-addition-base)), color-mix(in lab, var(--diffs-bg) 70%, var(--diffs-addition-base)))); --diffs-bg-addition-emphasis: var(--diffs-bg-addition-emphasis-override, light-dark(rgb(from var(--diffs-addition-base) r g b / 0.07), rgb(from var(--diffs-addition-base) r g b / 0.1))); --diffs-selection-base: var(--diffs-modified-base); --diffs-selection-number-fg: light-dark( color-mix(in lab, var(--diffs-selection-base) 65%, var(--diffs-mixer)), color-mix(in lab, var(--diffs-selection-base) 75%, var(--diffs-mixer))); --diffs-bg-selection: var(--diffs-bg-selection-override, light-dark( color-mix(in lab, var(--diffs-bg) 82%, var(--diffs-selection-base)), color-mix(in lab, var(--diffs-bg) 75%, var(--diffs-selection-base)))); --diffs-bg-selection-number: var(--diffs-bg-selection-number-override, light-dark( color-mix(in lab, var(--diffs-bg) 75%, var(--diffs-selection-base)), color-mix(in lab, var(--diffs-bg) 60%, var(--diffs-selection-base)))); } [data-diffs-header], [data-diffs] { [data-separator-wrapper] { margin: 0 !important; border-radius: 0 !important; } [data-expand-button] { width: 6.5ch !important; height: 24px !important; justify-content: end !important; padding-left: 3ch !important; padding-inline: 1ch !important; } [data-separator-multi-button] { grid-template-rows: 10px 10px !important; [data-expand-button] { height: 12px !important; } } [data-separator-content] { height: 24px !important; } [data-code] { overflow-x: auto !important; } }`;function Ty(e){return{theme:"OpenCode",themeType:"system",disableLineNumbers:!1,overflow:"wrap",diffStyle:e??"unified",diffIndicators:"bars",disableBackground:!1,expansionLineCount:20,lineDiffType:e==="split"?"word-alt":"none",maxLineDiffLength:1e3,maxLineLengthForHighlighting:1e3,disableFileHeader:!0,unsafeCSS:Vq}}const Hy={"--diffs-font-family":"var(--font-family-mono)","--diffs-font-size":"var(--font-size-small)","--diffs-line-height":"24px","--diffs-tab-size":2,"--diffs-font-features":"var(--font-family-mono--font-feature-settings)","--diffs-header-font-family":"var(--font-family-sans)","--diffs-gap-block":0,"--diffs-min-number-column-width":"4ch"};function Wq(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var xQ={exports:{}},Zq=xQ.exports,Ef;function Xq(){return Ef||(Ef=1,function(e,A){(function(t,r){r(A)})(Zq,function(t){const r=Symbol("newer"),n=Symbol("older");class i{constructor(s,C){typeof s!="number"&&(C=s,s=0),this.size=0,this.limit=s,this.oldest=this.newest=void 0,this._keymap=new Map,C&&(this.assign(C),s<1&&(this.limit=this.size))}_markEntryAsUsed(s){s!==this.newest&&(s[r]&&(s===this.oldest&&(this.oldest=s[r]),s[r][n]=s[n]),s[n]&&(s[n][r]=s[r]),s[r]=void 0,s[n]=this.newest,this.newest&&(this.newest[r]=s),this.newest=s)}assign(s){let C,E=this.limit||Number.MAX_VALUE;this._keymap.clear();let I=s[Symbol.iterator]();for(let c=I.next();!c.done;c=I.next()){let u=new o(c.value[0],c.value[1]);if(this._keymap.set(u.key,u),C?(C[r]=u,u[n]=C):this.oldest=u,C=u,E--==0)throw new Error("overflow")}this.newest=C,this.size=this._keymap.size}get(s){var C=this._keymap.get(s);return C?(this._markEntryAsUsed(C),C.value):void 0}set(s,C){var E=this._keymap.get(s);return E?(E.value=C,this._markEntryAsUsed(E),this):(this._keymap.set(s,E=new o(s,C)),this.newest?(this.newest[r]=E,E[n]=this.newest):this.oldest=E,this.newest=E,++this.size,this.size>this.limit&&this.shift(),this)}shift(){var s=this.oldest;if(s)return this.oldest[r]?(this.oldest=this.oldest[r],this.oldest[n]=void 0):(this.oldest=void 0,this.newest=void 0),s[r]=s[n]=void 0,this._keymap.delete(s.key),--this.size,[s.key,s.value]}find(s){let C=this._keymap.get(s);return C?C.value:void 0}has(s){return this._keymap.has(s)}delete(s){var C=this._keymap.get(s);return C?(this._keymap.delete(C.key),C[r]&&C[n]?(C[n][r]=C[r],C[r][n]=C[n]):C[r]?(C[r][n]=void 0,this.oldest=C[r]):C[n]?(C[n][r]=void 0,this.newest=C[n]):this.oldest=this.newest=void 0,this.size--,C.value):void 0}clear(){this.oldest=this.newest=void 0,this.size=0,this._keymap.clear()}keys(){return new Q(this.oldest)}values(){return new B(this.oldest)}entries(){return this}[Symbol.iterator](){return new g(this.oldest)}forEach(s,C){typeof C!="object"&&(C=this);let E=this.oldest;for(;E;)s.call(C,E.value,E.key,this),E=E[r]}toJSON(){for(var s=new Array(this.size),C=0,E=this.oldest;E;)s[C++]={key:E.key,value:E.value},E=E[r];return s}toString(){for(var s="",C=this.oldest;C;)s+=String(C.key)+":"+C.value,C=C[r],C&&(s+=" < ");return s}}t.LRUMap=i;function o(a,s){this.key=a,this.value=s,this[r]=void 0,this[n]=void 0}function g(a){this.entry=a}g.prototype[Symbol.iterator]=function(){return this},g.prototype.next=function(){let a=this.entry;return a?(this.entry=a[r],{done:!1,value:[a.key,a.value]}):{done:!0,value:void 0}};function Q(a){this.entry=a}Q.prototype[Symbol.iterator]=function(){return this},Q.prototype.next=function(){let a=this.entry;return a?(this.entry=a[r],{done:!1,value:a.key}):{done:!0,value:void 0}};function B(a){this.entry=a}B.prototype[Symbol.iterator]=function(){return this},B.prototype.next=function(){let a=this.entry;return a?(this.entry=a[r],{done:!1,value:a.value}):{done:!0,value:void 0}}})}(xQ,xQ.exports)),xQ.exports}var Cf=Xq();const If=Symbol("IGNORE_RESPONSE");var $q=class{highlighter;renderOptions;initialized=!1;workers=[];taskQueue=[];pendingTasks=new Map;nextRequestId=0;themeSubscribers=new Set;workersFailed=!1;instanceRequestMap=new Map;fileCache;diffCache;constructor(e,{langs:A,theme:t=Vt,lineDiffType:r="word-alt",tokenizeMaxLineLength:n=1e3}){this.options=e,this.renderOptions={theme:t,lineDiffType:r,tokenizeMaxLineLength:n},this.fileCache=new Cf.LRUMap(e.totalASTLRUCacheSize??100),this.diffCache=new Cf.LRUMap(e.totalASTLRUCacheSize??100),this.initialize(A)}isWorkingPool(){return!this.workersFailed}getFileResultCache(e){return e.cacheKey!=null?this.fileCache.get(e.cacheKey):void 0}getDiffResultCache(e){return e.cacheKey!=null?this.diffCache.get(e.cacheKey):void 0}inspectCaches(){const{fileCache:e,diffCache:A}=this;return{fileCache:e,diffCache:A}}evictFileFromCache(e){return this.fileCache.delete(e)!==void 0}evictDiffFromCache(e){return this.diffCache.delete(e)!==void 0}async setRenderOptions({theme:e=Vt,lineDiffType:A="word-alt",tokenizeMaxLineLength:t=1e3}){const r={theme:e,lineDiffType:A,tokenizeMaxLineLength:t};this.isInitialized()||await this.initialize();const n=Du(r.theme,this.renderOptions.theme);if(n&&r.lineDiffType===this.renderOptions.lineDiffType&&r.tokenizeMaxLineLength===this.renderOptions.tokenizeMaxLineLength)return;const i=gB(e);let o=[];if(n||(Ml(i)?o=af(i):o=await sf(i)),this.highlighter!=null)yl(o,this.highlighter),await this.setRenderOptionsOnWorkers(r,o);else{const[g]=await Promise.all([oB({themes:i,langs:["text"]}),this.setRenderOptionsOnWorkers(r,o)]);this.highlighter=g}this.renderOptions=r,this.diffCache.clear(),this.fileCache.clear();for(const g of this.themeSubscribers)g.rerender()}getFileRenderOptions(){const{tokenizeMaxLineLength:e,theme:A}=this.renderOptions;return{theme:A,tokenizeMaxLineLength:e}}getDiffRenderOptions(){return{...this.renderOptions}}async setRenderOptionsOnWorkers(e,A){if(this.workersFailed)return;this.isInitialized()||await this.initialize();const t=[];for(const r of this.workers){if(!r.initialized)throw console.log({managedWorker:r}),new Error("setRenderOptionsOnWorkers: Somehow we have an uninitialized worker");t.push(new Promise((n,i)=>{const o=this.generateRequestId(),g={type:"set-render-options",id:o,request:{type:"set-render-options",id:o,renderOptions:e,resolvedThemes:A},resolve:n,reject:i,requestStart:Date.now()};this.pendingTasks.set(o,g),r.worker.postMessage(g.request)}))}await Promise.all(t)}subscribeToThemeChanges(e){return this.themeSubscribers.add(e),()=>{this.unsubscribeToThemeChanges(e)}}unsubscribeToThemeChanges(e){this.themeSubscribers.delete(e)}isInitialized(){return this.initialized===!0}async initialize(e=[]){if(this.initialized!==!0)if(this.initialized===!1)this.initialized=new Promise((A,t)=>{(async()=>{try{const r=gB(this.renderOptions.theme);let n=[];Ml(r)?n=af(r):n=await sf(r);let i=[];Qf(e)?i=gf(e):i=await Bf(e);const[o]=await Promise.all([oB({themes:r,langs:["text",...e]}),this.initializeWorkers(n,i)]);if(this.initialized===!1){this.terminateWorkers(),t();return}this.highlighter=o,this.initialized=!0,this.diffCache.clear(),this.fileCache.clear(),this.drainQueue(),A()}catch(r){this.initialized=!1,this.workersFailed=!0,t(r)}})()});else return this.initialized}async initializeWorkers(e,A){this.workersFailed=!1;const t=[];this.workers.length>0&&this.terminateWorkers();for(let r=0;r<(this.options.poolSize??8);r++){const n=this.options.workerFactory(),i={worker:n,busy:!1,initialized:!1,langs:new Set(["text",...A.map(({name:o})=>o)])};n.addEventListener("message",o=>{this.handleWorkerMessage(i,o.data)}),n.addEventListener("error",o=>console.error("Worker error:",o,i)),this.workers.push(i),t.push(new Promise((o,g)=>{const Q=this.generateRequestId(),B={type:"initialize",id:Q,request:{type:"initialize",id:Q,renderOptions:this.renderOptions,resolvedThemes:e,resolvedLanguages:A},resolve(){i.initialized=!0,o()},reject:g,requestStart:Date.now()};this.pendingTasks.set(Q,B),this.executeTask(i,B)}))}await Promise.all(t)}drainQueue=()=>{if(this._queuedDrain=void 0,!(this.initialized!==!0||this.taskQueue.length===0))for(;this.taskQueue.length>0;){const e=this.taskQueue[0],A=lf(e),t=this.getAvailableWorker(A);if(t==null)break;this.taskQueue.shift(),this.resolveLanguagesAndExecuteTask(t,e,A)}};highlightFileAST(e,A){this.submitTask(e,{type:"file",file:A})}getPlainFileAST(e){if(this.highlighter==null){this.initialize();return}return Ny(e,this.highlighter,this.renderOptions,!0)}highlightDiffAST(e,A){this.submitTask(e,{type:"diff",diff:A})}getPlainDiffAST(e){return this.highlighter!=null?Ly(e,this.highlighter,this.renderOptions,!0):void 0}terminate(){this.terminateWorkers(),this.fileCache.clear(),this.diffCache.clear(),this.instanceRequestMap.clear(),this.taskQueue.length=0,this.pendingTasks.clear(),this.highlighter=void 0,this.initialized=!1,this.workersFailed=!1}terminateWorkers(){for(const e of this.workers)e.worker.terminate();this.workers.length=0}getStats(){return{totalWorkers:this.workers.length,busyWorkers:this.workers.filter(e=>e.busy).length,queuedTasks:this.taskQueue.length,pendingTasks:this.pendingTasks.size}}submitTask(e,A){this.initialized===!1&&this.initialize();const t=this.generateRequestId(),r=Date.now(),n=(()=>{switch(A.type){case"file":return{type:"file",id:t,request:{...A,id:t},instance:e,requestStart:r};case"diff":return{type:"diff",id:t,request:{...A,id:t},instance:e,requestStart:r}}})();this.instanceRequestMap.set(e,t),this.taskQueue.push(n),this.queueDrain()}async resolveLanguagesAndExecuteTask(e,A,t){if(A.type==="file"||A.type==="diff"){const r=t.filter(n=>!e.langs.has(n));r.length>0&&(Qf(r)?A.request.resolvedLanguages=gf(r):A.request.resolvedLanguages=await Bf(r))}this.executeTask(e,A)}handleWorkerMessage(e,A){const t=this.pendingTasks.get(A.id);try{if(t==null)throw new Error("handleWorkerMessage: Received response for unknown task");if(A.type==="error"){const r=new Error(A.error);throw A.stack&&(r.stack=A.stack),"reject"in t?t.reject(r):t.instance.onHighlightError(r),r}else{if("instance"in t&&this.instanceRequestMap.get(t.instance)!==A.id)throw If;switch(A.requestType){case"initialize":if(t.type!=="initialize")throw new Error("handleWorkerMessage: task/response dont match");t.resolve();break;case"set-render-options":if(t.type!=="set-render-options")throw new Error("handleWorkerMessage: task/response dont match");t.resolve();break;case"file":{if(t.type!=="file")throw new Error("handleWorkerMessage: task/response dont match");const{result:r,options:n}=A,{instance:i,request:o}=t;o.file.cacheKey!=null&&this.fileCache.set(o.file.cacheKey,{result:r,options:n}),i.onHighlightSuccess(o.file,r,n);break}case"diff":{if(t.type!=="diff")throw new Error("handleWorkerMessage: task/response dont match");const{result:r,options:n}=A,{instance:i,request:o}=t;o.diff.cacheKey!=null&&this.diffCache.set(o.diff.cacheKey,{result:r,options:n}),i.onHighlightSuccess(o.diff,r,n);break}}}}catch(r){r!==If&&console.error(r,t,A)}t!=null&&"instance"in t&&this.instanceRequestMap.get(t.instance)===A.id&&this.instanceRequestMap.delete(t.instance),this.pendingTasks.delete(A.id),e.busy=!1,this.taskQueue.length>0&&this.queueDrain()}_queuedDrain;queueDrain(){this._queuedDrain==null&&(this._queuedDrain=Promise.resolve().then(this.drainQueue))}executeTask(e,A){e.busy=!0,this.pendingTasks.set(A.id,A);for(const t of lf(A))e.langs.add(t);e.worker.postMessage(A.request)}getAvailableWorker(e){let A;for(const t of this.workers){if(t.busy||!t.initialized)continue;if(A=t,e.length===0)break;let r=!0;for(const n of e)if(!t.langs.has(n)){r=!1;break}if(r)break}return A}generateRequestId(){return`req_${++this.nextRequestId}`}};function lf(e){const A=new Set;if(e.type==="initialize"||e.type==="set-render-options")return[];switch(e.type){case"file":A.add(e.request.file.lang??fn(e.request.file.name));break;case"diff":A.add(e.request.diff.lang??fn(e.request.diff.name)),A.add(e.request.diff.lang??fn(e.request.diff.prevName??"-"));break}return A.delete("text"),Array.from(A)}const A6="/assets/worker-CKpRWWws.js";function e6(){return new Worker(A6,{type:"module"})}function cf(e){const A=new $q({workerFactory:e6,poolSize:2},{theme:"OpenCode",lineDiffType:e});return A.initialize(),A}let EI,CI;function Yy(e){if(!(typeof window>"u"))return e==="split"?(CI||(CI=cf("word-alt")),CI):(EI||(EI=cf("none")),EI)}var t6=J("

    ");function r6(e){let A;const[t,r]=eA(e,["before","after","class","classList","annotations"]),n=S(()=>new Yq({...Ty(e.diffStyle),...r},Yy(e.diffStyle)));return tA(()=>{const i=n();A.innerHTML="",i.render({oldFile:t.before,newFile:t.after,lineAnnotations:t.annotations,containerWrapper:A}),dA(()=>{i.cleanUp()})}),(()=>{var i=t6(),o=A;return typeof o=="function"?Qt(o,i):A=i,_A(g=>mB(i,Hy,g)),i})()}var n6=J("
    ");function i6(e){let A;const[t,r]=eA(e,["file","class","classList","annotations"]),n=S(()=>new Dq({...Ty("unified"),...r},Yy("unified")));return tA(()=>{A.innerHTML="",n().render({file:t.file,lineAnnotations:t.annotations,containerWrapper:A})}),(()=>{var i=n6(),o=A;return typeof o=="function"?Qt(o,i):A=i,_A(g=>{var Q=Hy,B={...t.classList||{},[t.class??""]:!!t.class};return g.e=mB(i,Q,g.e),g.t=qe(i,B,g.t),g},{e:void 0,t:void 0}),i})()}function zy(e){const A=e.replace("#",""),t=A.length===3?A.split("").map(n=>n+n).join(""):A,r=parseInt(t,16);return{r:(r>>16&255)/255,g:(r>>8&255)/255,b:(r&255)/255}}function o6(e,A,t){const r=n=>{const i=Math.max(0,Math.min(1,n));return Math.round(i*255).toString(16).padStart(2,"0")};return`#${r(e)}${r(A)}${r(t)}`}function II(e){return e<=.0031308?e*12.92:1.055*Math.pow(e,1/2.4)-.055}function lI(e){return e<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function g6(e,A,t){const r=lI(e),n=lI(A),i=lI(t),o=.4122214708*r+.5363325363*n+.0514459929*i,g=.2119034982*r+.6806995451*n+.1073969566*i,Q=.0883024619*r+.2817188376*n+.6299787005*i,B=Math.cbrt(o),a=Math.cbrt(g),s=Math.cbrt(Q),C=.2104542553*B+.793617785*a-.0040720468*s,E=1.9779984951*B-2.428592205*a+.4505937099*s,I=.0259040371*B+.7827717662*a-.808675766*s,c=Math.sqrt(E*E+I*I);let u=Math.atan2(I,E)*(180/Math.PI);return u<0&&(u+=360),{l:C,c,h:u}}function Q6(e){const{l:A,c:t,h:r}=e,n=t*Math.cos(r*Math.PI/180),i=t*Math.sin(r*Math.PI/180),o=A+.3963377774*n+.2158037573*i,g=A-.1055613458*n-.0638541728*i,Q=A-.0894841775*n-1.291485548*i,B=o*o*o,a=g*g*g,s=Q*Q*Q,C=4.0767416621*B-3.3077115913*a+.2309699292*s,E=-1.2684380046*B+2.6097574011*a-.3413193965*s,I=-.0041960863*B-.7034186147*a+1.707614701*s;return{r:II(C),g:II(E),b:II(I)}}function mu(e){const{r:A,g:t,b:r}=zy(e);return g6(A,t,r)}function pu(e){const{r:A,g:t,b:r}=Q6(e);return o6(A,t,r)}function di(e,A){const t=mu(e),r=[],n=A?[.15,.18,.22,.26,.32,.38,.46,.56,t.l,t.l-.05,.75,.93]:[.99,.97,.94,.9,.85,.79,.72,.64,t.l,t.l+.05,.45,.25],i=A?[.15,.2,.3,.4,.5,.6,.7,.85,1,1,.9,.6]:[.1,.15,.25,.35,.45,.55,.7,.85,1,1,.95,.85];for(let o=0;o<12;o++)r.push(pu({l:n[o],c:t.c*i[o],h:t.h}));return r}function B6(e,A){const t=mu(e),r=[],n=Math.min(t.c,.02),i=A?[.13,.16,.2,.24,.28,.33,.4,.52,.58,.66,.82,.96]:[.995,.98,.96,.94,.91,.88,.84,.78,.62,.56,.46,.2];for(let o=0;o<12;o++)r.push(pu({l:i[o],c:n,h:t.h}));return r}function St(e,A){const{r:t,g:r,b:n}=zy(e);return`rgba(${Math.round(t*255)}, ${Math.round(r*255)}, ${Math.round(n*255)}, ${A})`}function ku(e,A){const{seeds:t,overrides:r={}}=e,n=B6(t.neutral,A),i=di(t.primary,A),o=di(t.success,A),g=di(t.warning,A),Q=di(t.error,A),B=di(t.info,A),a=di(t.interactive,A),s=di(t.diffAdd,A),C=di(t.diffDelete,A),E=a6(n,A),I={};I["background-base"]=n[0],I["background-weak"]=n[2],I["background-strong"]=n[0],I["background-stronger"]=A?n[1]:"#fcfcfc",I["surface-base"]=E[1],I.base=E[1],I["surface-base-hover"]=E[2],I["surface-base-active"]=E[2],I["surface-base-interactive-active"]=St(a[2],.3),I.base2=E[1],I.base3=E[1],I["surface-inset-base"]=E[1],I["surface-inset-base-hover"]=E[2],I["surface-inset-strong"]=A?St(n[0],.5):St(n[3],.09),I["surface-inset-strong-hover"]=I["surface-inset-strong"],I["surface-raised-base"]=E[0],I["surface-float-base"]=A?n[0]:n[11],I["surface-float-base-hover"]=A?n[1]:n[10],I["surface-raised-base-hover"]=E[1],I["surface-raised-base-active"]=E[2],I["surface-raised-strong"]=A?E[3]:n[0],I["surface-raised-strong-hover"]=A?E[5]:"#ffffff",I["surface-raised-stronger"]=A?E[5]:"#ffffff",I["surface-raised-stronger-hover"]=A?E[6]:"#ffffff",I["surface-weak"]=E[2],I["surface-weaker"]=E[3],I["surface-strong"]=A?E[6]:"#ffffff",I["surface-raised-stronger-non-alpha"]=A?n[2]:"#ffffff",I["surface-brand-base"]=i[8],I["surface-brand-hover"]=i[9],I["surface-interactive-base"]=a[2],I["surface-interactive-hover"]=a[3],I["surface-interactive-weak"]=a[1],I["surface-interactive-weak-hover"]=a[2],I["surface-success-base"]=o[2],I["surface-success-weak"]=o[1],I["surface-success-strong"]=o[8],I["surface-warning-base"]=g[2],I["surface-warning-weak"]=g[1],I["surface-warning-strong"]=g[8],I["surface-critical-base"]=Q[2],I["surface-critical-weak"]=Q[1],I["surface-critical-strong"]=Q[8],I["surface-info-base"]=B[2],I["surface-info-weak"]=B[1],I["surface-info-strong"]=B[8],I["surface-diff-unchanged-base"]=A?n[0]:"#ffffff00",I["surface-diff-skip-base"]=A?E[0]:n[1],I["surface-diff-hidden-base"]=a[A?1:2],I["surface-diff-hidden-weak"]=a[A?0:1],I["surface-diff-hidden-weaker"]=a[A?2:0],I["surface-diff-hidden-strong"]=a[4],I["surface-diff-hidden-stronger"]=a[A?10:8],I["surface-diff-add-base"]=s[2],I["surface-diff-add-weak"]=s[A?3:1],I["surface-diff-add-weaker"]=s[A?2:0],I["surface-diff-add-strong"]=s[4],I["surface-diff-add-stronger"]=s[A?10:8],I["surface-diff-delete-base"]=C[2],I["surface-diff-delete-weak"]=C[A?3:1],I["surface-diff-delete-weaker"]=C[A?2:0],I["surface-diff-delete-strong"]=C[A?4:5],I["surface-diff-delete-stronger"]=C[A?10:8],I["input-base"]=A?n[1]:n[0],I["input-hover"]=n[1],I["input-active"]=a[0],I["input-selected"]=a[3],I["input-focus"]=a[0],I["input-disabled"]=n[3],I["text-base"]=n[10],I["text-weak"]=n[8],I["text-weaker"]=n[7],I["text-strong"]=n[11],I["text-invert-base"]=A?n[10]:E[10],I["text-invert-weak"]=A?n[8]:E[8],I["text-invert-weaker"]=A?n[7]:E[7],I["text-invert-strong"]=A?n[11]:E[11],I["text-interactive-base"]=a[A?10:8],I["text-on-brand-base"]=E[10],I["text-on-interactive-base"]=A?n[11]:n[0],I["text-on-interactive-weak"]=E[10],I["text-on-success-base"]=o[A?8:9],I["text-on-critical-base"]=Q[A?8:9],I["text-on-critical-weak"]=Q[7],I["text-on-critical-strong"]=Q[11],I["text-on-warning-base"]=E[10],I["text-on-info-base"]=E[10],I["text-diff-add-base"]=s[10],I["text-diff-delete-base"]=C[A?8:9],I["text-diff-delete-strong"]=C[11],I["text-diff-add-strong"]=s[A?7:11],I["text-on-info-weak"]=E[8],I["text-on-info-strong"]=E[11],I["text-on-warning-weak"]=E[8],I["text-on-warning-strong"]=E[11],I["text-on-success-weak"]=o[A?7:5],I["text-on-success-strong"]=o[11],I["text-on-brand-weak"]=E[8],I["text-on-brand-weaker"]=E[7],I["text-on-brand-strong"]=E[11],I["button-secondary-base"]=A?n[2]:n[0],I["button-secondary-hover"]=A?n[3]:n[1],I["button-ghost-hover"]=E[1],I["button-ghost-hover2"]=E[2],I["border-base"]=E[6],I["border-hover"]=E[7],I["border-active"]=E[8],I["border-selected"]=St(a[8],A?.9:.99),I["border-disabled"]=E[7],I["border-focus"]=E[8],I["border-weak-base"]=E[A?5:4],I["border-strong-base"]=E[A?7:6],I["border-strong-hover"]=E[7],I["border-strong-active"]=E[A?7:6],I["border-strong-selected"]=St(a[5],.6),I["border-strong-disabled"]=E[5],I["border-strong-focus"]=E[A?7:6],I["border-weak-hover"]=E[A?6:5],I["border-weak-active"]=E[A?7:6],I["border-weak-selected"]=St(a[4],A?.6:.5),I["border-weak-disabled"]=E[5],I["border-weak-focus"]=E[A?7:6],I["border-weaker-base"]=E[2],I["border-weaker-hover"]=E[3],I["border-weaker-active"]=E[5],I["border-weaker-selected"]=St(a[3],A?.3:.4),I["border-weaker-disabled"]=E[1],I["border-weaker-focus"]=E[5],I["border-interactive-base"]=a[6],I["border-interactive-hover"]=a[7],I["border-interactive-active"]=a[8],I["border-interactive-selected"]=a[8],I["border-interactive-disabled"]=n[7],I["border-interactive-focus"]=a[8],I["border-success-base"]=o[5],I["border-success-hover"]=o[6],I["border-success-selected"]=o[8],I["border-warning-base"]=g[5],I["border-warning-hover"]=g[6],I["border-warning-selected"]=g[8],I["border-critical-base"]=Q[A?4:5],I["border-critical-hover"]=Q[6],I["border-critical-selected"]=Q[8],I["border-info-base"]=B[5],I["border-info-hover"]=B[6],I["border-info-selected"]=B[8],I["border-color"]="#ffffff",I["icon-base"]=n[8],I["icon-hover"]=n[A?9:10],I["icon-active"]=n[A?10:11],I["icon-selected"]=n[11],I["icon-disabled"]=n[A?6:7],I["icon-focus"]=n[11],I["icon-invert-base"]=A?n[0]:"#ffffff",I["icon-weak-base"]=n[A?5:6],I["icon-weak-hover"]=n[6],I["icon-weak-active"]=n[7],I["icon-weak-selected"]=n[8],I["icon-weak-disabled"]=n[A?3:5],I["icon-weak-focus"]=n[8],I["icon-strong-base"]=n[11],I["icon-strong-hover"]=A?"#f6f3f3":"#151313",I["icon-strong-active"]=A?"#fcfcfc":"#020202",I["icon-strong-selected"]=A?"#fdfcfc":"#020202",I["icon-strong-disabled"]=n[7],I["icon-strong-focus"]=A?"#fdfcfc":"#020202",I["icon-brand-base"]=A?"#ffffff":n[11],I["icon-interactive-base"]=a[8],I["icon-success-base"]=o[6],I["icon-success-hover"]=o[7],I["icon-success-active"]=o[10],I["icon-warning-base"]=g[6],I["icon-warning-hover"]=g[7],I["icon-warning-active"]=g[10],I["icon-critical-base"]=Q[A?8:9],I["icon-critical-hover"]=Q[10],I["icon-critical-active"]=Q[11],I["icon-info-base"]=B[6],I["icon-info-hover"]=B[7],I["icon-info-active"]=B[10],I["icon-on-brand-base"]=E[10],I["icon-on-brand-hover"]=E[11],I["icon-on-brand-selected"]=E[11],I["icon-on-interactive-base"]=A?n[11]:n[0],I["icon-agent-plan-base"]=B[8],I["icon-agent-docs-base"]=g[8],I["icon-agent-ask-base"]=a[8],I["icon-agent-build-base"]=a[A?10:8],I["icon-on-success-base"]=St(o[8],.9),I["icon-on-success-hover"]=St(o[9],.9),I["icon-on-success-selected"]=St(o[10],.9),I["icon-on-warning-base"]=St(g[8],.9),I["icon-on-warning-hover"]=St(g[9],.9),I["icon-on-warning-selected"]=St(g[10],.9),I["icon-on-critical-base"]=St(Q[8],.9),I["icon-on-critical-hover"]=St(Q[9],.9),I["icon-on-critical-selected"]=St(Q[10],.9),I["icon-on-info-base"]=B[8],I["icon-on-info-hover"]=St(B[9],.9),I["icon-on-info-selected"]=St(B[10],.9),I["icon-diff-add-base"]=s[10],I["icon-diff-add-hover"]=s[A?9:11],I["icon-diff-add-active"]=s[A?10:11],I["icon-diff-delete-base"]=C[A?8:9],I["icon-diff-delete-hover"]=C[A?9:10],I["syntax-comment"]="var(--text-weak)",I["syntax-regexp"]="var(--text-base)",I["syntax-string"]=A?"#00ceb9":"#006656",I["syntax-keyword"]="var(--text-weak)",I["syntax-primitive"]=A?"#ffba92":"#fb4804",I["syntax-operator"]=A?"var(--text-weak)":"var(--text-base)",I["syntax-variable"]="var(--text-strong)",I["syntax-property"]=A?"#ff9ae2":"#ed6dc8",I["syntax-type"]=A?"#ecf58c":"#596600",I["syntax-constant"]=A?"#93e9f6":"#007b80",I["syntax-punctuation"]=A?"var(--text-weak)":"var(--text-base)",I["syntax-object"]="var(--text-strong)",I["syntax-success"]=o[9],I["syntax-warning"]=g[9],I["syntax-critical"]=Q[9],I["syntax-info"]=A?"#93e9f6":"#0092a8",I["syntax-diff-add"]=s[10],I["syntax-diff-delete"]=C[10],I["syntax-diff-unknown"]="#ff0000",I["markdown-heading"]=A?"#9d7cd8":"#d68c27",I["markdown-text"]=A?"#eeeeee":"#1a1a1a",I["markdown-link"]=A?"#fab283":"#3b7dd8",I["markdown-link-text"]=A?"#56b6c2":"#318795",I["markdown-code"]=A?"#7fd88f":"#3d9a57",I["markdown-block-quote"]=A?"#e5c07b":"#b0851f",I["markdown-emph"]=A?"#e5c07b":"#b0851f",I["markdown-strong"]=A?"#f5a742":"#d68c27",I["markdown-horizontal-rule"]=A?"#808080":"#8a8a8a",I["markdown-list-item"]=A?"#fab283":"#3b7dd8",I["markdown-list-enumeration"]=A?"#56b6c2":"#318795",I["markdown-image"]=A?"#fab283":"#3b7dd8",I["markdown-image-text"]=A?"#56b6c2":"#318795",I["markdown-code-block"]=A?"#eeeeee":"#1a1a1a",I["avatar-background-pink"]=A?"#501b3f":"#feeef8",I["avatar-background-mint"]=A?"#033a34":"#e1fbf4",I["avatar-background-orange"]=A?"#5f2a06":"#fff1e7",I["avatar-background-purple"]=A?"#432155":"#f9f1fe",I["avatar-background-cyan"]=A?"#0f3058":"#e7f9fb",I["avatar-background-lime"]=A?"#2b3711":"#eefadc",I["avatar-text-pink"]=A?"#e34ba9":"#cd1d8d",I["avatar-text-mint"]=A?"#95f3d9":"#147d6f",I["avatar-text-orange"]=A?"#ff802b":"#ed5f00",I["avatar-text-purple"]=A?"#9d5bd2":"#8445bc",I["avatar-text-cyan"]=A?"#369eff":"#0894b3",I["avatar-text-lime"]=A?"#c4f042":"#5d770d";for(const[c,u]of Object.entries(r))I[c]=u;return I}function a6(e,A){const t=A?[.02,.04,.08,.12,.16,.2,.26,.36,.44,.52,.72,.94]:[.01,.03,.06,.09,.12,.15,.2,.27,.46,.61,.5,.87];return e.map((r,n)=>{const i=mu(r),o=A?.1+t[n]*.8:1-t[n]*.8;return pu({...i,l:i.l*t[n]+o*(1-t[n])})})}function Py(e){return Object.entries(e).map(([A,t])=>`--${A}: ${t};`).join(` `)}const s6="https://opencode.ai/desktop-theme.json",E6="OC-1",C6="oc-1",I6=JSON.parse('{"seeds":{"neutral":"#8e8b8b","primary":"#dcde8d","success":"#12c905","warning":"#ffdc17","error":"#fc533a","info":"#a753ae","interactive":"#034cff","diffAdd":"#9ff29a","diffDelete":"#fc533a"},"overrides":{"background-base":"#f8f7f7","background-weak":"var(--smoke-light-3)","background-strong":"var(--smoke-light-1)","background-stronger":"#fcfcfc","surface-base":"var(--smoke-light-alpha-2)","base":"var(--smoke-light-alpha-2)","surface-base-hover":"#0500000f","surface-base-active":"var(--smoke-light-alpha-3)","surface-base-interactive-active":"var(--cobalt-light-alpha-3)","base2":"var(--smoke-light-alpha-2)","base3":"var(--smoke-light-alpha-2)","surface-inset-base":"var(--smoke-light-alpha-2)","surface-inset-base-hover":"var(--smoke-light-alpha-3)","surface-inset-strong":"#1f000017","surface-inset-strong-hover":"#1f000017","surface-raised-base":"var(--smoke-light-alpha-1)","surface-float-base":"var(--smoke-dark-1)","surface-float-base-hover":"var(--smoke-dark-2)","surface-raised-base-hover":"var(--smoke-light-alpha-2)","surface-raised-base-active":"var(--smoke-light-alpha-3)","surface-raised-strong":"var(--smoke-light-1)","surface-raised-strong-hover":"var(--white)","surface-raised-stronger":"var(--white)","surface-raised-stronger-hover":"var(--white)","surface-weak":"var(--smoke-light-alpha-3)","surface-weaker":"var(--smoke-light-alpha-4)","surface-strong":"#ffffff","surface-raised-stronger-non-alpha":"var(--white)","surface-brand-base":"var(--yuzu-light-9)","surface-brand-hover":"var(--yuzu-light-10)","surface-interactive-base":"var(--cobalt-light-3)","surface-interactive-hover":"var(--cobalt-light-4)","surface-interactive-weak":"var(--cobalt-light-2)","surface-interactive-weak-hover":"var(--cobalt-light-3)","surface-success-base":"var(--apple-light-3)","surface-success-weak":"var(--apple-light-2)","surface-success-strong":"var(--apple-light-9)","surface-warning-base":"var(--solaris-light-3)","surface-warning-weak":"var(--solaris-light-2)","surface-warning-strong":"var(--solaris-light-9)","surface-critical-base":"var(--ember-light-3)","surface-critical-weak":"var(--ember-light-2)","surface-critical-strong":"var(--ember-light-9)","surface-info-base":"var(--lilac-light-3)","surface-info-weak":"var(--lilac-light-2)","surface-info-strong":"var(--lilac-light-9)","surface-diff-unchanged-base":"#ffffff00","surface-diff-skip-base":"var(--smoke-light-2)","surface-diff-hidden-base":"var(--blue-light-3)","surface-diff-hidden-weak":"var(--blue-light-2)","surface-diff-hidden-weaker":"var(--blue-light-1)","surface-diff-hidden-strong":"var(--blue-light-5)","surface-diff-hidden-stronger":"var(--blue-light-9)","surface-diff-add-base":"#dafbe0","surface-diff-add-weak":"var(--mint-light-2)","surface-diff-add-weaker":"var(--mint-light-1)","surface-diff-add-strong":"var(--mint-light-5)","surface-diff-add-stronger":"var(--mint-light-9)","surface-diff-delete-base":"var(--ember-light-3)","surface-diff-delete-weak":"var(--ember-light-2)","surface-diff-delete-weaker":"var(--ember-light-1)","surface-diff-delete-strong":"var(--ember-light-6)","surface-diff-delete-stronger":"var(--ember-light-9)","input-base":"var(--smoke-light-1)","input-hover":"var(--smoke-light-2)","input-active":"var(--cobalt-light-1)","input-selected":"var(--cobalt-light-4)","input-focus":"var(--cobalt-light-1)","input-disabled":"var(--smoke-light-4)","text-base":"var(--smoke-light-11)","text-weak":"var(--smoke-light-9)","text-weaker":"var(--smoke-light-8)","text-strong":"var(--smoke-light-12)","text-invert-base":"var(--smoke-dark-alpha-11)","text-invert-weak":"var(--smoke-dark-alpha-9)","text-invert-weaker":"var(--smoke-dark-alpha-8)","text-invert-strong":"var(--smoke-dark-alpha-12)","text-interactive-base":"var(--cobalt-light-9)","text-on-brand-base":"var(--smoke-light-alpha-11)","text-on-interactive-base":"var(--smoke-light-1)","text-on-interactive-weak":"var(--smoke-dark-alpha-11)","text-on-success-base":"var(--apple-light-10)","text-on-critical-base":"var(--ember-light-10)","text-on-critical-weak":"var(--ember-light-8)","text-on-critical-strong":"var(--ember-light-12)","text-on-warning-base":"var(--smoke-dark-alpha-11)","text-on-info-base":"var(--smoke-dark-alpha-11)","text-diff-add-base":"var(--mint-light-11)","text-diff-delete-base":"var(--ember-light-10)","text-diff-delete-strong":"var(--ember-light-12)","text-diff-add-strong":"var(--mint-light-12)","text-on-info-weak":"var(--smoke-dark-alpha-9)","text-on-info-strong":"var(--smoke-dark-alpha-12)","text-on-warning-weak":"var(--smoke-dark-alpha-9)","text-on-warning-strong":"var(--smoke-dark-alpha-12)","text-on-success-weak":"var(--apple-light-6)","text-on-success-strong":"var(--apple-light-12)","text-on-brand-weak":"var(--smoke-light-alpha-9)","text-on-brand-weaker":"var(--smoke-light-alpha-8)","text-on-brand-strong":"var(--smoke-light-alpha-12)","button-secondary-base":"#fdfcfc","button-secondary-hover":"#faf9f9","border-base":"var(--smoke-light-alpha-7)","border-hover":"var(--smoke-light-alpha-8)","border-active":"var(--smoke-light-alpha-9)","border-selected":"var(--cobalt-light-alpha-9)","border-disabled":"var(--smoke-light-alpha-8)","border-focus":"var(--smoke-light-alpha-9)","border-weak-base":"var(--smoke-light-alpha-5)","border-strong-base":"var(--smoke-light-alpha-7)","border-strong-hover":"var(--smoke-light-alpha-8)","border-strong-active":"var(--smoke-light-alpha-7)","border-strong-selected":"var(--cobalt-light-alpha-6)","border-strong-disabled":"var(--smoke-light-alpha-6)","border-strong-focus":"var(--smoke-light-alpha-7)","border-weak-hover":"var(--smoke-light-alpha-6)","border-weak-active":"var(--smoke-light-alpha-7)","border-weak-selected":"var(--cobalt-light-alpha-5)","border-weak-disabled":"var(--smoke-light-alpha-6)","border-weak-focus":"var(--smoke-light-alpha-7)","border-interactive-base":"var(--cobalt-light-7)","border-interactive-hover":"var(--cobalt-light-8)","border-interactive-active":"var(--cobalt-light-9)","border-interactive-selected":"var(--cobalt-light-9)","border-interactive-disabled":"var(--smoke-light-8)","border-interactive-focus":"var(--cobalt-light-9)","border-success-base":"var(--apple-light-6)","border-success-hover":"var(--apple-light-7)","border-success-selected":"var(--apple-light-9)","border-warning-base":"var(--solaris-light-6)","border-warning-hover":"var(--solaris-light-7)","border-warning-selected":"var(--solaris-light-9)","border-critical-base":"var(--ember-light-6)","border-critical-hover":"var(--ember-light-7)","border-critical-selected":"var(--ember-light-9)","border-info-base":"var(--lilac-light-6)","border-info-hover":"var(--lilac-light-7)","border-info-selected":"var(--lilac-light-9)","icon-base":"var(--smoke-light-9)","icon-hover":"var(--smoke-light-11)","icon-active":"var(--smoke-light-12)","icon-selected":"var(--smoke-light-12)","icon-disabled":"var(--smoke-light-8)","icon-focus":"var(--smoke-light-12)","icon-invert-base":"#ffffff","icon-weak-base":"var(--smoke-light-7)","icon-weak-hover":"var(--smoke-light-8)","icon-weak-active":"var(--smoke-light-9)","icon-weak-selected":"var(--smoke-light-10)","icon-weak-disabled":"var(--smoke-light-6)","icon-weak-focus":"var(--smoke-light-9)","icon-strong-base":"var(--smoke-light-12)","icon-strong-hover":"#151313","icon-strong-active":"#020202","icon-strong-selected":"#020202","icon-strong-disabled":"var(--smoke-light-8)","icon-strong-focus":"#020202","icon-brand-base":"var(--smoke-light-12)","icon-interactive-base":"var(--cobalt-light-9)","icon-success-base":"var(--apple-light-7)","icon-success-hover":"var(--apple-light-8)","icon-success-active":"var(--apple-light-11)","icon-warning-base":"var(--amber-light-7)","icon-warning-hover":"var(--amber-light-8)","icon-warning-active":"var(--amber-light-11)","icon-critical-base":"var(--ember-light-10)","icon-critical-hover":"var(--ember-light-11)","icon-critical-active":"var(--ember-light-12)","icon-info-base":"var(--lilac-light-7)","icon-info-hover":"var(--lilac-light-8)","icon-info-active":"var(--lilac-light-11)","icon-on-brand-base":"var(--smoke-light-alpha-11)","icon-on-brand-hover":"var(--smoke-light-alpha-12)","icon-on-brand-selected":"var(--smoke-light-alpha-12)","icon-on-interactive-base":"var(--smoke-light-1)","icon-agent-plan-base":"var(--purple-light-9)","icon-agent-docs-base":"var(--amber-light-9)","icon-agent-ask-base":"var(--cyan-light-9)","icon-agent-build-base":"var(--cobalt-light-9)","icon-on-success-base":"var(--apple-light-alpha-9)","icon-on-success-hover":"var(--apple-light-alpha-10)","icon-on-success-selected":"var(--apple-light-alpha-11)","icon-on-warning-base":"var(--amber-lightalpha-9)","icon-on-warning-hover":"var(--amber-lightalpha-10)","icon-on-warning-selected":"var(--amber-lightalpha-11)","icon-on-critical-base":"var(--ember-light-alpha-9)","icon-on-critical-hover":"var(--ember-light-alpha-10)","icon-on-critical-selected":"var(--ember-light-alpha-11)","icon-on-info-base":"var(--lilac-light-9)","icon-on-info-hover":"var(--lilac-light-alpha-10)","icon-on-info-selected":"var(--lilac-light-alpha-11)","icon-diff-add-base":"var(--mint-light-11)","icon-diff-add-hover":"var(--mint-light-12)","icon-diff-add-active":"var(--mint-light-12)","icon-diff-delete-base":"var(--ember-light-10)","icon-diff-delete-hover":"var(--ember-light-11)","syntax-comment":"var(--text-weak)","syntax-regexp":"var(--text-base)","syntax-string":"#006656","syntax-keyword":"var(--text-weak)","syntax-primitive":"#fb4804","syntax-operator":"var(--text-base)","syntax-variable":"var(--text-strong)","syntax-property":"#ed6dc8","syntax-type":"#596600","syntax-constant":"#007b80","syntax-punctuation":"var(--text-base)","syntax-object":"var(--text-strong)","syntax-success":"var(--apple-light-10)","syntax-warning":"var(--amber-light-10)","syntax-critical":"var(--ember-light-10)","syntax-info":"#0092a8","syntax-diff-add":"var(--mint-light-11)","syntax-diff-delete":"var(--ember-light-11)","syntax-diff-unknown":"#ff0000","markdown-heading":"#d68c27","markdown-text":"#1a1a1a","markdown-link":"#3b7dd8","markdown-link-text":"#318795","markdown-code":"#3d9a57","markdown-block-quote":"#b0851f","markdown-emph":"#b0851f","markdown-strong":"#d68c27","markdown-horizontal-rule":"#8a8a8a","markdown-list-item":"#3b7dd8","markdown-list-enumeration":"#318795","markdown-image":"#3b7dd8","markdown-image-text":"#318795","markdown-code-block":"#1a1a1a","border-color":"#ffffff","border-weaker-base":"var(--smoke-light-alpha-3)","border-weaker-hover":"var(--smoke-light-alpha-4)","border-weaker-active":"var(--smoke-light-alpha-6)","border-weaker-selected":"var(--cobalt-light-alpha-4)","border-weaker-disabled":"var(--smoke-light-alpha-2)","border-weaker-focus":"var(--smoke-light-alpha-6)","button-ghost-hover":"var(--smoke-light-alpha-2)","button-ghost-hover2":"var(--smoke-light-alpha-3)","avatar-background-pink":"#feeef8","avatar-background-mint":"#e1fbf4","avatar-background-orange":"#fff1e7","avatar-background-purple":"#f9f1fe","avatar-background-cyan":"#e7f9fb","avatar-background-lime":"#eefadc","avatar-text-pink":"#cd1d8d","avatar-text-mint":"#147d6f","avatar-text-orange":"#ed5f00","avatar-text-purple":"#8445bc","avatar-text-cyan":"#0894b3","avatar-text-lime":"#5d770d"}}'),l6=JSON.parse('{"seeds":{"neutral":"#716c6b","primary":"#fab283","success":"#12c905","warning":"#fcd53a","error":"#fc533a","info":"#edb2f1","interactive":"#034cff","diffAdd":"#c8ffc4","diffDelete":"#fc533a"},"overrides":{"background-base":"var(--smoke-dark-1)","background-weak":"#1c1717","background-strong":"#151313","background-stronger":"#191515","surface-base":"var(--smoke-dark-alpha-2)","base":"var(--smoke-dark-alpha-2)","surface-base-hover":"#e0b7b716","surface-base-active":"var(--smoke-dark-alpha-3)","surface-base-interactive-active":"var(--cobalt-dark-alpha-2)","base2":"var(--smoke-dark-alpha-2)","base3":"var(--smoke-dark-alpha-2)","surface-inset-base":"#0e0b0b7f","surface-inset-base-hover":"#0e0b0b7f","surface-inset-strong":"#060505cc","surface-inset-strong-hover":"#060505cc","surface-raised-base":"var(--smoke-dark-alpha-3)","surface-float-base":"var(--smoke-dark-1)","surface-float-base-hover":"var(--smoke-dark-2)","surface-raised-base-hover":"var(--smoke-dark-alpha-4)","surface-raised-base-active":"var(--smoke-dark-alpha-5)","surface-raised-strong":"var(--smoke-dark-alpha-4)","surface-raised-strong-hover":"var(--smoke-dark-alpha-6)","surface-raised-stronger":"var(--smoke-dark-alpha-6)","surface-raised-stronger-hover":"var(--smoke-dark-alpha-7)","surface-weak":"var(--smoke-dark-alpha-4)","surface-weaker":"var(--smoke-dark-alpha-5)","surface-strong":"var(--smoke-dark-alpha-7)","surface-raised-stronger-non-alpha":"var(--smoke-dark-3)","surface-brand-base":"var(--yuzu-light-9)","surface-brand-hover":"var(--yuzu-light-10)","surface-interactive-base":"var(--cobalt-light-3)","surface-interactive-hover":"var(--cobalt-light-4)","surface-interactive-weak":"var(--cobalt-light-2)","surface-interactive-weak-hover":"var(--cobalt-light-3)","surface-success-base":"var(--apple-dark-3)","surface-success-weak":"var(--apple-dark-2)","surface-success-strong":"var(--apple-dark-9)","surface-warning-base":"var(--solaris-light-3)","surface-warning-weak":"var(--solaris-light-2)","surface-warning-strong":"var(--solaris-light-9)","surface-critical-base":"var(--ember-dark-3)","surface-critical-weak":"var(--ember-dark-2)","surface-critical-strong":"var(--ember-dark-9)","surface-info-base":"var(--lilac-light-3)","surface-info-weak":"var(--lilac-light-2)","surface-info-strong":"var(--lilac-light-9)","surface-diff-unchanged-base":"var(--smoke-dark-1)","surface-diff-skip-base":"var(--smoke-dark-alpha-1)","surface-diff-hidden-base":"var(--blue-dark-2)","surface-diff-hidden-weak":"var(--blue-dark-1)","surface-diff-hidden-weaker":"var(--blue-dark-3)","surface-diff-hidden-strong":"var(--blue-dark-5)","surface-diff-hidden-stronger":"var(--blue-dark-11)","surface-diff-add-base":"var(--mint-dark-3)","surface-diff-add-weak":"var(--mint-dark-4)","surface-diff-add-weaker":"var(--mint-dark-3)","surface-diff-add-strong":"var(--mint-dark-5)","surface-diff-add-stronger":"var(--mint-dark-11)","surface-diff-delete-base":"var(--ember-dark-3)","surface-diff-delete-weak":"var(--ember-dark-4)","surface-diff-delete-weaker":"var(--ember-dark-3)","surface-diff-delete-strong":"var(--ember-dark-5)","surface-diff-delete-stronger":"var(--ember-dark-11)","input-base":"var(--smoke-dark-2)","input-hover":"var(--smoke-dark-2)","input-active":"var(--cobalt-dark-1)","input-selected":"var(--cobalt-dark-2)","input-focus":"var(--cobalt-dark-1)","input-disabled":"var(--smoke-dark-4)","text-base":"var(--smoke-dark-alpha-11)","text-weak":"var(--smoke-dark-alpha-9)","text-weaker":"var(--smoke-dark-alpha-8)","text-strong":"var(--smoke-dark-alpha-12)","text-invert-base":"var(--smoke-dark-alpha-11)","text-invert-weak":"var(--smoke-dark-alpha-9)","text-invert-weaker":"var(--smoke-dark-alpha-8)","text-invert-strong":"var(--smoke-dark-alpha-12)","text-interactive-base":"var(--cobalt-dark-11)","text-on-brand-base":"var(--smoke-dark-alpha-11)","text-on-interactive-base":"var(--smoke-dark-12)","text-on-interactive-weak":"var(--smoke-dark-alpha-11)","text-on-success-base":"var(--apple-dark-9)","text-on-critical-base":"var(--ember-dark-9)","text-on-critical-weak":"var(--ember-dark-8)","text-on-critical-strong":"var(--ember-dark-12)","text-on-warning-base":"var(--smoke-dark-alpha-11)","text-on-info-base":"var(--smoke-dark-alpha-11)","text-diff-add-base":"var(--mint-dark-11)","text-diff-delete-base":"var(--ember-dark-9)","text-diff-delete-strong":"var(--ember-dark-12)","text-diff-add-strong":"var(--mint-dark-8)","text-on-info-weak":"var(--smoke-dark-alpha-9)","text-on-info-strong":"var(--smoke-dark-alpha-12)","text-on-warning-weak":"var(--smoke-dark-alpha-9)","text-on-warning-strong":"var(--smoke-dark-alpha-12)","text-on-success-weak":"var(--apple-dark-8)","text-on-success-strong":"var(--apple-dark-12)","text-on-brand-weak":"var(--smoke-dark-alpha-9)","text-on-brand-weaker":"var(--smoke-dark-alpha-8)","text-on-brand-strong":"var(--smoke-dark-alpha-12)","button-secondary-base":"#231f1f","button-secondary-hover":"#2a2727","border-base":"var(--smoke-dark-alpha-7)","border-hover":"var(--smoke-dark-alpha-8)","border-active":"var(--smoke-dark-alpha-9)","border-selected":"var(--cobalt-dark-alpha-11)","border-disabled":"var(--smoke-dark-alpha-8)","border-focus":"var(--smoke-dark-alpha-9)","border-weak-base":"var(--smoke-dark-alpha-6)","border-strong-base":"var(--smoke-dark-alpha-8)","border-strong-hover":"var(--smoke-dark-alpha-7)","border-strong-active":"var(--smoke-dark-alpha-8)","border-strong-selected":"var(--cobalt-dark-alpha-6)","border-strong-disabled":"var(--smoke-dark-alpha-6)","border-strong-focus":"var(--smoke-dark-alpha-8)","border-weak-hover":"var(--smoke-dark-alpha-7)","border-weak-active":"var(--smoke-dark-alpha-8)","border-weak-selected":"var(--cobalt-dark-alpha-6)","border-weak-disabled":"var(--smoke-dark-alpha-6)","border-weak-focus":"var(--smoke-dark-alpha-8)","border-interactive-base":"var(--cobalt-light-7)","border-interactive-hover":"var(--cobalt-light-8)","border-interactive-active":"var(--cobalt-light-9)","border-interactive-selected":"var(--cobalt-light-9)","border-interactive-disabled":"var(--smoke-light-8)","border-interactive-focus":"var(--cobalt-light-9)","border-success-base":"var(--apple-light-6)","border-success-hover":"var(--apple-light-7)","border-success-selected":"var(--apple-light-9)","border-warning-base":"var(--solaris-light-6)","border-warning-hover":"var(--solaris-light-7)","border-warning-selected":"var(--solaris-light-9)","border-critical-base":"var(--ember-dark-5)","border-critical-hover":"var(--ember-dark-7)","border-critical-selected":"var(--ember-dark-9)","border-info-base":"var(--lilac-light-6)","border-info-hover":"var(--lilac-light-7)","border-info-selected":"var(--lilac-light-9)","icon-base":"var(--smoke-dark-9)","icon-hover":"var(--smoke-dark-10)","icon-active":"var(--smoke-dark-11)","icon-selected":"var(--smoke-dark-12)","icon-disabled":"var(--smoke-dark-7)","icon-focus":"var(--smoke-dark-12)","icon-invert-base":"var(--smoke-dark-1)","icon-weak-base":"var(--smoke-dark-6)","icon-weak-hover":"var(--smoke-light-7)","icon-weak-active":"var(--smoke-light-8)","icon-weak-selected":"var(--smoke-light-9)","icon-weak-disabled":"var(--smoke-light-4)","icon-weak-focus":"var(--smoke-light-9)","icon-strong-base":"var(--smoke-dark-12)","icon-strong-hover":"#f6f3f3","icon-strong-active":"#fcfcfc","icon-strong-selected":"#fdfcfc","icon-strong-disabled":"var(--smoke-dark-8)","icon-strong-focus":"#fdfcfc","icon-brand-base":"var(--white)","icon-interactive-base":"var(--cobalt-dark-9)","icon-success-base":"var(--apple-dark-9)","icon-success-hover":"var(--apple-dark-10)","icon-success-active":"var(--apple-dark-11)","icon-warning-base":"var(--amber-dark-7)","icon-warning-hover":"var(--amber-dark-8)","icon-warning-active":"var(--amber-dark-11)","icon-critical-base":"var(--ember-dark-9)","icon-critical-hover":"var(--ember-dark-11)","icon-critical-active":"var(--ember-dark-12)","icon-info-base":"var(--lilac-dark-7)","icon-info-hover":"var(--lilac-dark-8)","icon-info-active":"var(--lilac-dark-11)","icon-on-brand-base":"var(--smoke-light-alpha-11)","icon-on-brand-hover":"var(--smoke-light-alpha-12)","icon-on-brand-selected":"var(--smoke-light-alpha-12)","icon-on-interactive-base":"var(--smoke-dark-12)","icon-agent-plan-base":"var(--purple-dark-9)","icon-agent-docs-base":"var(--amber-dark-9)","icon-agent-ask-base":"var(--cyan-dark-9)","icon-agent-build-base":"var(--cobalt-dark-11)","icon-on-success-base":"var(--apple-dark-alpha-9)","icon-on-success-hover":"var(--apple-dark-alpha-10)","icon-on-success-selected":"var(--apple-dark-alpha-11)","icon-on-warning-base":"var(--amber-darkalpha-9)","icon-on-warning-hover":"var(--amber-darkalpha-10)","icon-on-warning-selected":"var(--amber-darkalpha-11)","icon-on-critical-base":"var(--ember-dark-alpha-9)","icon-on-critical-hover":"var(--ember-dark-alpha-10)","icon-on-critical-selected":"var(--ember-dark-alpha-11)","icon-on-info-base":"var(--lilac-dark-9)","icon-on-info-hover":"var(--lilac-dark-alpha-10)","icon-on-info-selected":"var(--lilac-dark-alpha-11)","icon-diff-add-base":"var(--mint-dark-11)","icon-diff-add-hover":"var(--mint-dark-10)","icon-diff-add-active":"var(--mint-dark-11)","icon-diff-delete-base":"var(--ember-dark-9)","icon-diff-delete-hover":"var(--ember-dark-10)","syntax-comment":"var(--text-weak)","syntax-regexp":"var(--text-base)","syntax-string":"#00ceb9","syntax-keyword":"var(--text-weak)","syntax-primitive":"#ffba92","syntax-operator":"var(--text-weak)","syntax-variable":"var(--text-strong)","syntax-property":"#ff9ae2","syntax-type":"#ecf58c","syntax-constant":"#93e9f6","syntax-punctuation":"var(--text-weak)","syntax-object":"var(--text-strong)","syntax-success":"var(--apple-dark-10)","syntax-warning":"var(--amber-dark-10)","syntax-critical":"var(--ember-dark-10)","syntax-info":"#93e9f6","syntax-diff-add":"var(--mint-dark-11)","syntax-diff-delete":"var(--ember-dark-11)","syntax-diff-unknown":"#ff0000","markdown-heading":"#9d7cd8","markdown-text":"#eeeeee","markdown-link":"#fab283","markdown-link-text":"#56b6c2","markdown-code":"#7fd88f","markdown-block-quote":"#e5c07b","markdown-emph":"#e5c07b","markdown-strong":"#f5a742","markdown-horizontal-rule":"#808080","markdown-list-item":"#fab283","markdown-list-enumeration":"#56b6c2","markdown-image":"#fab283","markdown-image-text":"#56b6c2","markdown-code-block":"#eeeeee","border-color":"#ffffff","border-weaker-base":"var(--smoke-dark-alpha-3)","border-weaker-hover":"var(--smoke-dark-alpha-4)","border-weaker-active":"var(--smoke-dark-alpha-6)","border-weaker-selected":"var(--cobalt-dark-alpha-3)","border-weaker-disabled":"var(--smoke-dark-alpha-2)","border-weaker-focus":"var(--smoke-dark-alpha-6)","button-ghost-hover":"var(--smoke-dark-alpha-2)","button-ghost-hover2":"var(--smoke-dark-alpha-3)","avatar-background-pink":"#501b3f","avatar-background-mint":"#033a34","avatar-background-orange":"#5f2a06","avatar-background-purple":"#432155","avatar-background-cyan":"#0f3058","avatar-background-lime":"#2b3711","avatar-text-pink":"#e34ba9","avatar-text-mint":"#95f3d9","avatar-text-orange":"#ff802b","avatar-text-purple":"#9d5bd2","avatar-text-cyan":"#369eff","avatar-text-lime":"#c4f042"}}'),c6={$schema:s6,name:E6,id:C6,light:I6,dark:l6},u6="https://opencode.ai/desktop-theme.json",d6="Tokyonight",h6="tokyonight",D6={seeds:{neutral:"#e1e2e7",primary:"#2e7de9",success:"#587539",warning:"#8c6c3e",error:"#c94060",info:"#007197",interactive:"#2e7de9",diffAdd:"#4f8f7b",diffDelete:"#d05f7c"},overrides:{"background-base":"#e1e2e7","background-weak":"#dee0ea","background-strong":"#e5e6ee","background-stronger":"#e9eaf1","border-weak-base":"#cdd0dc","border-weak-hover":"#c3c6d2","border-weak-active":"#b9bcc8","border-weak-selected":"#aeb2bf","border-weak-disabled":"#e6e7ef","border-weak-focus":"#b3b6c3","border-base":"#a7abbb","border-hover":"#9ba0b1","border-active":"#9095a8","border-selected":"#83889e","border-disabled":"#dedfe6","border-focus":"#9599a8","border-strong-base":"#757b90","border-strong-hover":"#6a7084","border-strong-active":"#5f6578","border-strong-selected":"#545a6d","border-strong-disabled":"#c4c6d0","border-strong-focus":"#666b7f","surface-diff-add-base":"#dfe7da","surface-diff-delete-base":"#f4dadd","surface-diff-hidden-base":"#cfd1dd","text-base":"#273153","text-weak":"#5c6390","text-strong":"#1c2544","syntax-string":"#587539","syntax-primitive":"#b15c00","syntax-property":"#9854f1","syntax-type":"#3760bf","syntax-constant":"#007197","syntax-info":"#007197","markdown-heading":"#9854f1","markdown-text":"#273153","markdown-link":"#2e7de9","markdown-link-text":"#007197","markdown-code":"#587539","markdown-block-quote":"#8c6c3e","markdown-emph":"#8c6c3e","markdown-strong":"#b15c00","markdown-horizontal-rule":"#a1a6c5","markdown-list-item":"#2e7de9","markdown-list-enumeration":"#007197","markdown-image":"#2e7de9","markdown-image-text":"#007197","markdown-code-block":"#3760bf"}},f6={seeds:{neutral:"#1a1b26",primary:"#7aa2f7",success:"#9ece6a",warning:"#e0af68",error:"#f7768e",info:"#7dcfff",interactive:"#7aa2f7",diffAdd:"#41a6b5",diffDelete:"#c34043"},overrides:{"background-base":"#0f111a","background-weak":"#111428","background-strong":"#101324","background-stronger":"#13172a","border-weak-base":"#25283b","border-weak-hover":"#292c43","border-weak-active":"#2e314b","border-weak-selected":"#343755","border-weak-disabled":"#151727","border-weak-focus":"#30324f","border-base":"#3a3e57","border-hover":"#414264","border-active":"#474972","border-selected":"#4f507f","border-disabled":"#1c1d2d","border-focus":"#45496f","border-strong-base":"#5a5f82","border-strong-hover":"#646994","border-strong-active":"#6f74a6","border-strong-selected":"#7a7fb8","border-strong-disabled":"#23243a","border-strong-focus":"#6a6f9f","surface-base":"#1f2335",base:"#1f2335","surface-base-hover":"#232840","surface-base-active":"#262c46","surface-base-interactive-active":"#2b3357",base2:"#1f2335",base3:"#1f2335","surface-inset-base":"#161a2ab3","surface-inset-base-hover":"#161a2acc","surface-inset-strong":"#0d111fcc","surface-inset-strong-hover":"#0d111fcc","surface-raised-base":"#242a42","surface-float-base":"#242b45","surface-float-base-hover":"#2a3154","surface-raised-base-hover":"#272e49","surface-raised-base-active":"#2c3353","surface-raised-strong":"#31385a","surface-raised-strong-hover":"#373f6b","surface-raised-stronger":"#3b4261","surface-raised-stronger-hover":"#444c82","surface-weak":"#1b2033","surface-weaker":"#181d2d","surface-strong":"#323858","surface-raised-stronger-non-alpha":"#2b3150","surface-diff-add-base":"#1c2a38","surface-diff-delete-base":"#2a1f32","surface-diff-hidden-base":"#24283b","text-base":"#c0caf5","text-weak":"#7a88cf","text-strong":"#eaeaff","syntax-string":"#9ece6a","syntax-primitive":"#ff9e64","syntax-property":"#bb9af7","syntax-type":"#e0af68","syntax-constant":"#7dcfff","syntax-info":"#7dcfff","markdown-heading":"#bb9af7","markdown-text":"#c0caf5","markdown-link":"#7aa2f7","markdown-link-text":"#7dcfff","markdown-code":"#9ece6a","markdown-block-quote":"#e0af68","markdown-emph":"#e0af68","markdown-strong":"#ff9e64","markdown-horizontal-rule":"#3b4261","markdown-list-item":"#7aa2f7","markdown-list-enumeration":"#7dcfff","markdown-image":"#7aa2f7","markdown-image-text":"#7dcfff","markdown-code-block":"#c0caf5"}},w6={$schema:u6,name:d6,id:h6,light:D6,dark:f6},m6="https://opencode.ai/desktop-theme.json",p6="Dracula",k6="dracula",y6={seeds:{neutral:"#f8f8f2",primary:"#7c6bf5",success:"#2fbf71",warning:"#f7a14d",error:"#d9536f",info:"#1d7fc5",interactive:"#7c6bf5",diffAdd:"#9fe3b3",diffDelete:"#f8a1b8"},overrides:{"background-base":"#f8f8f2","background-weak":"#f1f2ed","background-strong":"#f6f6f1","background-stronger":"#f2f2ec","border-weak-base":"#e2e3da","border-weak-hover":"#d8d9d0","border-weak-active":"#cfd0c7","border-weak-selected":"#c4c6bc","border-weak-disabled":"#eceee3","border-weak-focus":"#c9cabf","border-base":"#c4c6ba","border-hover":"#b8baae","border-active":"#abada3","border-selected":"#979a90","border-disabled":"#e5e7dd","border-focus":"#b0b2a7","border-strong-base":"#9fa293","border-strong-hover":"#8e9185","border-strong-active":"#7e8176","border-strong-selected":"#6f7268","border-strong-disabled":"#c7c9be","border-strong-focus":"#878b7f","surface-diff-add-base":"#e4f5e6","surface-diff-delete-base":"#fae4eb","surface-diff-hidden-base":"#dedfe9","text-base":"#1f1f2f","text-weak":"#52526b","text-strong":"#05040c","syntax-string":"#2fbf71","syntax-primitive":"#d16090","syntax-property":"#7c6bf5","syntax-type":"#f7a14d","syntax-constant":"#1d7fc5","syntax-info":"#1d7fc5","markdown-heading":"#7c6bf5","markdown-text":"#1f1f2f","markdown-link":"#7c6bf5","markdown-link-text":"#1d7fc5","markdown-code":"#2fbf71","markdown-block-quote":"#f7a14d","markdown-emph":"#f7a14d","markdown-strong":"#d16090","markdown-horizontal-rule":"#c3c5d4","markdown-list-item":"#7c6bf5","markdown-list-enumeration":"#1d7fc5","markdown-image":"#7c6bf5","markdown-image-text":"#1d7fc5","markdown-code-block":"#1d7fc5"}},M6={seeds:{neutral:"#1d1e28",primary:"#bd93f9",success:"#50fa7b",warning:"#ffb86c",error:"#ff5555",info:"#8be9fd",interactive:"#bd93f9",diffAdd:"#2fb27d",diffDelete:"#ff6b81"},overrides:{"background-base":"#14151f","background-weak":"#181926","background-strong":"#161722","background-stronger":"#191a26","border-weak-base":"#2d2f3c","border-weak-hover":"#303244","border-weak-active":"#35364c","border-weak-selected":"#3b3d55","border-weak-disabled":"#1e1f2b","border-weak-focus":"#383a50","border-base":"#3f415a","border-hover":"#464967","border-active":"#4d5073","border-selected":"#55587f","border-disabled":"#272834","border-focus":"#4a4d6d","border-strong-base":"#606488","border-strong-hover":"#6a6e96","border-strong-active":"#7378a3","border-strong-selected":"#7d82b1","border-strong-disabled":"#343649","border-strong-focus":"#6f739c","surface-diff-add-base":"#1f2a2f","surface-diff-delete-base":"#2d1f27","surface-diff-hidden-base":"#24253a","text-base":"#f8f8f2","text-weak":"#b6b9e4","text-strong":"#ffffff","syntax-string":"#50fa7b","syntax-primitive":"#ff79c6","syntax-property":"#bd93f9","syntax-type":"#ffb86c","syntax-constant":"#8be9fd","syntax-info":"#8be9fd","markdown-heading":"#bd93f9","markdown-text":"#f8f8f2","markdown-link":"#bd93f9","markdown-link-text":"#8be9fd","markdown-code":"#50fa7b","markdown-block-quote":"#ffb86c","markdown-emph":"#ffb86c","markdown-strong":"#ff79c6","markdown-horizontal-rule":"#44475a","markdown-list-item":"#bd93f9","markdown-list-enumeration":"#8be9fd","markdown-image":"#bd93f9","markdown-image-text":"#8be9fd","markdown-code-block":"#f8f8f2"}},N6={$schema:m6,name:p6,id:k6,light:y6,dark:M6},v6="https://opencode.ai/desktop-theme.json",b6="Monokai",F6="monokai",x6={seeds:{neutral:"#fdf8ec",primary:"#bf7bff",success:"#4fb54b",warning:"#f1a948",error:"#e54b4b",info:"#2d9ad7",interactive:"#bf7bff",diffAdd:"#bfe7a3",diffDelete:"#f6a3ae"},overrides:{"background-base":"#fdf8ec","background-weak":"#f8f2e6","background-strong":"#fbf5e8","background-stronger":"#f7efdd","border-weak-base":"#e9e0cf","border-weak-hover":"#dfd5c3","border-weak-active":"#d5cab7","border-weak-selected":"#cabfad","border-weak-disabled":"#f3ebdd","border-weak-focus":"#d0c2b1","border-base":"#c7b9a5","border-hover":"#bcae98","border-active":"#b0a28c","border-selected":"#a49781","border-disabled":"#efe5d6","border-focus":"#b6a893","border-strong-base":"#998b76","border-strong-hover":"#8a7c67","border-strong-active":"#7a6d58","border-strong-selected":"#6c604c","border-strong-disabled":"#d7cabc","border-strong-focus":"#82745f","surface-diff-add-base":"#e8f7e1","surface-diff-delete-base":"#fde5e4","surface-diff-hidden-base":"#e9e0d0","text-base":"#292318","text-weak":"#6d5c40","text-strong":"#1c150c","syntax-string":"#4fb54b","syntax-primitive":"#d9487c","syntax-property":"#bf7bff","syntax-type":"#f1a948","syntax-constant":"#2d9ad7","syntax-info":"#2d9ad7","markdown-heading":"#bf7bff","markdown-text":"#292318","markdown-link":"#bf7bff","markdown-link-text":"#2d9ad7","markdown-code":"#4fb54b","markdown-block-quote":"#f1a948","markdown-emph":"#f1a948","markdown-strong":"#d9487c","markdown-horizontal-rule":"#cdbdab","markdown-list-item":"#bf7bff","markdown-list-enumeration":"#2d9ad7","markdown-image":"#bf7bff","markdown-image-text":"#2d9ad7","markdown-code-block":"#2d9ad7"}},G6={seeds:{neutral:"#272822",primary:"#ae81ff",success:"#a6e22e",warning:"#fd971f",error:"#f92672",info:"#66d9ef",interactive:"#ae81ff",diffAdd:"#4d7f2a",diffDelete:"#f4477c"},overrides:{"background-base":"#23241e","background-weak":"#27281f","background-strong":"#25261f","background-stronger":"#292a23","border-weak-base":"#343528","border-weak-hover":"#393a2d","border-weak-active":"#3f4033","border-weak-selected":"#454639","border-weak-disabled":"#1d1e16","border-weak-focus":"#414235","border-base":"#494a3a","border-hover":"#50523f","border-active":"#585a45","border-selected":"#60624b","border-disabled":"#23241b","border-focus":"#555741","border-strong-base":"#6a6c55","border-strong-hover":"#73755d","border-strong-active":"#7d7f66","border-strong-selected":"#878970","border-strong-disabled":"#2c2d23","border-strong-focus":"#7a7c63","surface-diff-add-base":"#1e2a1d","surface-diff-delete-base":"#301c24","surface-diff-hidden-base":"#2f2f24","text-base":"#f8f8f2","text-weak":"#c5c5c0","text-strong":"#ffffff","syntax-string":"#a6e22e","syntax-primitive":"#f92672","syntax-property":"#ae81ff","syntax-type":"#fd971f","syntax-constant":"#66d9ef","syntax-info":"#66d9ef","markdown-heading":"#ae81ff","markdown-text":"#f8f8f2","markdown-link":"#ae81ff","markdown-link-text":"#66d9ef","markdown-code":"#a6e22e","markdown-block-quote":"#fd971f","markdown-emph":"#fd971f","markdown-strong":"#f92672","markdown-horizontal-rule":"#3b3c34","markdown-list-item":"#ae81ff","markdown-list-enumeration":"#66d9ef","markdown-image":"#ae81ff","markdown-image-text":"#66d9ef","markdown-code-block":"#f8f8f2"}},S6={$schema:v6,name:b6,id:F6,light:x6,dark:G6},J6="https://opencode.ai/desktop-theme.json",U6="Solarized",K6="solarized",L6={seeds:{neutral:"#fdf6e3",primary:"#268bd2",success:"#859900",warning:"#b58900",error:"#dc322f",info:"#2aa198",interactive:"#268bd2",diffAdd:"#c6dc7a",diffDelete:"#f2a1a1"},overrides:{"background-base":"#fdf6e3","background-weak":"#f6efda","background-strong":"#faf3dc","background-stronger":"#f6edd4","border-weak-base":"#e3e0cd","border-weak-hover":"#d9d4c2","border-weak-active":"#cfcab7","border-weak-selected":"#c5c0ad","border-weak-disabled":"#f2edda","border-weak-focus":"#cbc6b2","border-base":"#bcb5a0","border-hover":"#b1aa96","border-active":"#a59f8c","border-selected":"#999382","border-disabled":"#ede7d4","border-focus":"#aca58f","border-strong-base":"#8c8572","border-strong-hover":"#7f7866","border-strong-active":"#716b5b","border-strong-selected":"#645f50","border-strong-disabled":"#d5cdb8","border-strong-focus":"#78715f","surface-diff-add-base":"#eef5d6","surface-diff-delete-base":"#fde4dd","surface-diff-hidden-base":"#e3ecf3","text-base":"#586e75","text-weak":"#7a8c8e","text-strong":"#073642","syntax-string":"#859900","syntax-primitive":"#d33682","syntax-property":"#268bd2","syntax-type":"#b58900","syntax-constant":"#2aa198","syntax-info":"#2aa198","markdown-heading":"#268bd2","markdown-text":"#586e75","markdown-link":"#268bd2","markdown-link-text":"#2aa198","markdown-code":"#859900","markdown-block-quote":"#b58900","markdown-emph":"#b58900","markdown-strong":"#d33682","markdown-horizontal-rule":"#cfd1bf","markdown-list-item":"#268bd2","markdown-list-enumeration":"#2aa198","markdown-image":"#268bd2","markdown-image-text":"#2aa198","markdown-code-block":"#2aa198"}},R6={seeds:{neutral:"#002b36",primary:"#6c71c4",success:"#859900",warning:"#b58900",error:"#dc322f",info:"#2aa198",interactive:"#6c71c4",diffAdd:"#4c7654",diffDelete:"#c34b4b"},overrides:{"background-base":"#001f27","background-weak":"#022733","background-strong":"#01222b","background-stronger":"#032830","border-weak-base":"#20373f","border-weak-hover":"#243e47","border-weak-active":"#28434f","border-weak-selected":"#2d4958","border-weak-disabled":"#0f2026","border-weak-focus":"#2a4552","border-base":"#31505b","border-hover":"#365765","border-active":"#3c5e70","border-selected":"#42657a","border-disabled":"#13272e","border-focus":"#3a5a6b","border-strong-base":"#4a7887","border-strong-hover":"#528294","border-strong-active":"#5a8ca1","border-strong-selected":"#6396ae","border-strong-disabled":"#1b323b","border-strong-focus":"#56879a","surface-diff-add-base":"#0f2f29","surface-diff-delete-base":"#321c1c","surface-diff-hidden-base":"#0f3844","text-base":"#93a1a1","text-weak":"#6c7f80","text-strong":"#fdf6e3","syntax-string":"#859900","syntax-primitive":"#d33682","syntax-property":"#6c71c4","syntax-type":"#b58900","syntax-constant":"#2aa198","syntax-info":"#2aa198","markdown-heading":"#6c71c4","markdown-text":"#93a1a1","markdown-link":"#6c71c4","markdown-link-text":"#2aa198","markdown-code":"#859900","markdown-block-quote":"#b58900","markdown-emph":"#b58900","markdown-strong":"#d33682","markdown-horizontal-rule":"#0e3b46","markdown-list-item":"#6c71c4","markdown-list-enumeration":"#2aa198","markdown-image":"#6c71c4","markdown-image-text":"#2aa198","markdown-code-block":"#93a1a1"}},O6={$schema:J6,name:U6,id:K6,light:L6,dark:R6},q6="https://opencode.ai/desktop-theme.json",T6="Nord",H6="nord",Y6={seeds:{neutral:"#eceff4",primary:"#5e81ac",success:"#8fbcbb",warning:"#d08770",error:"#bf616a",info:"#81a1c1",interactive:"#5e81ac",diffAdd:"#a3be8c",diffDelete:"#bf616a"},overrides:{"background-base":"#eceff4","background-weak":"#e4e8f0","background-strong":"#f1f3f8","background-stronger":"#f6f8fc","border-weak-base":"#d5dbe7","border-weak-hover":"#c9d0de","border-weak-active":"#bec5d4","border-weak-selected":"#b2bacc","border-weak-disabled":"#f0f3fa","border-weak-focus":"#b9bfd0","border-base":"#afb7cb","border-hover":"#a3abc1","border-active":"#979fb7","border-selected":"#8b94ad","border-disabled":"#e5e9f2","border-focus":"#9ca4ba","border-strong-base":"#757f97","border-strong-hover":"#69718a","border-strong-active":"#5d647d","border-strong-selected":"#525970","border-strong-disabled":"#c9cedc","border-strong-focus":"#636c84","surface-diff-add-base":"#e4f0e4","surface-diff-delete-base":"#f4e1e4","surface-diff-hidden-base":"#dfe6f2","text-base":"#2e3440","text-weak":"#4c566a","text-strong":"#1f2530","syntax-string":"#a3be8c","syntax-primitive":"#bf616a","syntax-property":"#5e81ac","syntax-type":"#d08770","syntax-constant":"#81a1c1","syntax-info":"#81a1c1","markdown-heading":"#5e81ac","markdown-text":"#2e3440","markdown-link":"#5e81ac","markdown-link-text":"#81a1c1","markdown-code":"#a3be8c","markdown-block-quote":"#d08770","markdown-emph":"#d08770","markdown-strong":"#bf616a","markdown-horizontal-rule":"#cbd3e1","markdown-list-item":"#5e81ac","markdown-list-enumeration":"#81a1c1","markdown-image":"#5e81ac","markdown-image-text":"#81a1c1","markdown-code-block":"#5e81ac"}},z6={seeds:{neutral:"#2e3440",primary:"#88c0d0",success:"#a3be8c",warning:"#d08770",error:"#bf616a",info:"#81a1c1",interactive:"#88c0d0",diffAdd:"#81a1c1",diffDelete:"#bf616a"},overrides:{"background-base":"#1f2430","background-weak":"#222938","background-strong":"#1c202a","background-stronger":"#181c24","border-weak-base":"#343a47","border-weak-hover":"#383f50","border-weak-active":"#3d4458","border-weak-selected":"#434a62","border-weak-disabled":"#151923","border-weak-focus":"#3f4359","border-base":"#4a5163","border-hover":"#515870","border-active":"#585f7c","border-selected":"#606889","border-disabled":"#1b202a","border-focus":"#545b78","border-strong-base":"#6a7492","border-strong-hover":"#747e9f","border-strong-active":"#7e88ac","border-strong-selected":"#8993b9","border-strong-disabled":"#232836","border-strong-focus":"#76819f","surface-diff-add-base":"#1f2e33","surface-diff-delete-base":"#2e212a","surface-diff-hidden-base":"#222b3a","text-base":"#e5e9f0","text-weak":"#a4adbf","text-strong":"#f8fafc","syntax-string":"#a3be8c","syntax-primitive":"#d57780","syntax-property":"#88c0d0","syntax-type":"#eac196","syntax-constant":"#81a1c1","syntax-info":"#81a1c1","markdown-heading":"#88c0d0","markdown-text":"#e5e9f0","markdown-link":"#88c0d0","markdown-link-text":"#81a1c1","markdown-code":"#a3be8c","markdown-block-quote":"#d08770","markdown-emph":"#d08770","markdown-strong":"#bf616a","markdown-horizontal-rule":"#2f384a","markdown-list-item":"#88c0d0","markdown-list-enumeration":"#81a1c1","markdown-image":"#88c0d0","markdown-image-text":"#81a1c1","markdown-code-block":"#cbd3e1"}},P6={$schema:q6,name:T6,id:H6,light:Y6,dark:z6},_6="https://opencode.ai/desktop-theme.json",j6="Catppuccin",V6="catppuccin",W6={seeds:{neutral:"#f5e0dc",primary:"#7287fd",success:"#40a02b",warning:"#df8e1d",error:"#d20f39",info:"#04a5e5",interactive:"#7287fd",diffAdd:"#a6d189",diffDelete:"#e78284"},overrides:{"background-base":"#f5e0dc","background-weak":"#f2d8d4","background-strong":"#f9e8e4","background-stronger":"#fdeeee","border-weak-base":"#e0cfd3","border-weak-hover":"#d6c4c8","border-weak-active":"#cdb9be","border-weak-selected":"#c2aeb4","border-weak-disabled":"#fbeff2","border-weak-focus":"#c7b4ba","border-base":"#bca6b2","border-hover":"#b19ca8","border-active":"#a6929e","border-selected":"#9a8894","border-disabled":"#f3e4e7","border-focus":"#ab97a1","border-strong-base":"#83677f","border-strong-hover":"#775b73","border-strong-active":"#6b5068","border-strong-selected":"#5f465d","border-strong-disabled":"#d9c5cf","border-strong-focus":"#714f66","surface-diff-add-base":"#edf5e6","surface-diff-delete-base":"#fde1e3","surface-diff-hidden-base":"#e4e2f6","text-base":"#4c4f69","text-weak":"#6c6f85","text-strong":"#1f1f2a","syntax-string":"#40a02b","syntax-primitive":"#d20f39","syntax-property":"#7287fd","syntax-type":"#df8e1d","syntax-constant":"#04a5e5","syntax-info":"#04a5e5","markdown-heading":"#7287fd","markdown-text":"#4c4f69","markdown-link":"#7287fd","markdown-link-text":"#04a5e5","markdown-code":"#40a02b","markdown-block-quote":"#df8e1d","markdown-emph":"#df8e1d","markdown-strong":"#d20f39","markdown-horizontal-rule":"#d4c5cf","markdown-list-item":"#7287fd","markdown-list-enumeration":"#04a5e5","markdown-image":"#7287fd","markdown-image-text":"#04a5e5","markdown-code-block":"#7287fd"}},Z6={seeds:{neutral:"#1e1e2e",primary:"#b4befe",success:"#a6d189",warning:"#f4b8e4",error:"#f38ba8",info:"#89dceb",interactive:"#b4befe",diffAdd:"#94e2d5",diffDelete:"#f38ba8"},overrides:{"background-base":"#1e1e2e","background-weak":"#211f31","background-strong":"#1c1c29","background-stronger":"#191926","border-weak-base":"#35324a","border-weak-hover":"#393655","border-weak-active":"#403c61","border-weak-selected":"#47436d","border-weak-disabled":"#141426","border-weak-focus":"#3d3a63","border-base":"#4a4763","border-hover":"#524f70","border-active":"#5a577d","border-selected":"#625f8a","border-disabled":"#1b1a2c","border-focus":"#575379","border-strong-base":"#6e6a8c","border-strong-hover":"#787497","border-strong-active":"#8380a2","border-strong-selected":"#8d8bad","border-strong-disabled":"#232237","border-strong-focus":"#7b779b","surface-diff-add-base":"#1d2c30","surface-diff-delete-base":"#2c1f2a","surface-diff-hidden-base":"#232538","text-base":"#cdd6f4","text-weak":"#a6adc8","text-strong":"#f4f2ff","syntax-string":"#a6e3a1","syntax-primitive":"#f38ba8","syntax-property":"#b4befe","syntax-type":"#f9e2af","syntax-constant":"#89dceb","syntax-info":"#89dceb","markdown-heading":"#b4befe","markdown-text":"#cdd6f4","markdown-link":"#b4befe","markdown-link-text":"#89dceb","markdown-code":"#a6e3a1","markdown-block-quote":"#f9e2af","markdown-emph":"#f9e2af","markdown-strong":"#f38ba8","markdown-horizontal-rule":"#2e2d45","markdown-list-item":"#b4befe","markdown-list-enumeration":"#89dceb","markdown-image":"#b4befe","markdown-image-text":"#89dceb","markdown-code-block":"#cdd6f4"}},X6={$schema:_6,name:j6,id:V6,light:W6,dark:Z6},$6="https://opencode.ai/desktop-theme.json",A5="Ayu",e5="ayu",t5={seeds:{neutral:"#fdfaf4",primary:"#55b4d4",success:"#6ac782",warning:"#f2ae49",error:"#f05f65",info:"#36a3d9",interactive:"#55b4d4",diffAdd:"#b8df8a",diffDelete:"#f05f65"},overrides:{"background-base":"#fdfaf4","background-weak":"#f6f0e7","background-strong":"#f1ebe2","background-stronger":"#ece4da","border-weak-base":"#e6ddcf","border-weak-hover":"#dcd3c5","border-weak-active":"#d1c9ba","border-weak-selected":"#c6bfaf","border-weak-disabled":"#f7f0e6","border-weak-focus":"#cbc4b6","border-base":"#bfb3a3","border-hover":"#b4a898","border-active":"#a99e8e","border-selected":"#9e9383","border-disabled":"#efe5d8","border-focus":"#b09f8f","border-strong-base":"#8f806f","border-strong-hover":"#837465","border-strong-active":"#77685a","border-strong-selected":"#6b5d51","border-strong-disabled":"#d8cabc","border-strong-focus":"#7c6d5e","surface-diff-add-base":"#eef5e4","surface-diff-delete-base":"#fde5e5","surface-diff-hidden-base":"#e3edf3","text-base":"#5c6773","text-weak":"#8a939f","text-strong":"#2a3038","syntax-string":"#86b300","syntax-primitive":"#f28779","syntax-property":"#55b4d4","syntax-type":"#f29e32","syntax-constant":"#36a3d9","syntax-info":"#36a3d9","markdown-heading":"#55b4d4","markdown-text":"#5c6773","markdown-link":"#55b4d4","markdown-link-text":"#36a3d9","markdown-code":"#86b300","markdown-block-quote":"#f29e32","markdown-emph":"#f29e32","markdown-strong":"#f28779","markdown-horizontal-rule":"#d7cec0","markdown-list-item":"#55b4d4","markdown-list-enumeration":"#36a3d9","markdown-image":"#55b4d4","markdown-image-text":"#36a3d9","markdown-code-block":"#55b4d4"}},r5={seeds:{neutral:"#0f1419",primary:"#39bae6",success:"#7fd962",warning:"#ebb062",error:"#ff8f77",info:"#73d0ff",interactive:"#39bae6",diffAdd:"#5cc885",diffDelete:"#ff8f77"},overrides:{"background-base":"#0f1419","background-weak":"#121920","background-strong":"#0d1116","background-stronger":"#0a0e13","border-weak-base":"#262c34","border-weak-hover":"#2b323d","border-weak-active":"#303746","border-weak-selected":"#363d50","border-weak-disabled":"#080b0f","border-weak-focus":"#323a48","border-base":"#3d4555","border-hover":"#454d61","border-active":"#4c556d","border-selected":"#545d79","border-disabled":"#0e1218","border-focus":"#495368","border-strong-base":"#626c81","border-strong-hover":"#6c7690","border-strong-active":"#76819f","border-strong-selected":"#808bae","border-strong-disabled":"#151b23","border-strong-focus":"#6f7a96","surface-diff-add-base":"#102922","surface-diff-delete-base":"#2b1718","surface-diff-hidden-base":"#182028","text-base":"#ced0d6","text-weak":"#8f9aa5","text-strong":"#f6f7f9","syntax-string":"#b8cc52","syntax-primitive":"#f59074","syntax-property":"#39bae6","syntax-type":"#ebb062","syntax-constant":"#73d0ff","syntax-info":"#73d0ff","markdown-heading":"#39bae6","markdown-text":"#ced0d6","markdown-link":"#39bae6","markdown-link-text":"#73d0ff","markdown-code":"#b8cc52","markdown-block-quote":"#ebb062","markdown-emph":"#ebb062","markdown-strong":"#f59074","markdown-horizontal-rule":"#1f2630","markdown-list-item":"#39bae6","markdown-list-enumeration":"#73d0ff","markdown-image":"#39bae6","markdown-image-text":"#73d0ff","markdown-code-block":"#ced0d6"}},n5={$schema:$6,name:A5,id:e5,light:t5,dark:r5},i5="https://opencode.ai/desktop-theme.json",o5="One Dark Pro",g5="onedarkpro",Q5={seeds:{neutral:"#f5f6f8",primary:"#528bff",success:"#4fa66d",warning:"#d19a66",error:"#e06c75",info:"#61afef",interactive:"#528bff",diffAdd:"#c2ebcf",diffDelete:"#f7c1c5"},overrides:{"background-base":"#f5f6f8","background-weak":"#eef0f4","background-strong":"#fafbfc","background-stronger":"#ffffff","border-weak-base":"#dee2eb","border-weak-hover":"#d4d9e3","border-weak-active":"#caced6","border-weak-selected":"#bec4d0","border-weak-disabled":"#f4f6fb","border-weak-focus":"#c4cada","border-base":"#b5bccd","border-hover":"#aab1c2","border-active":"#a0a7b8","border-selected":"#959cae","border-disabled":"#eceef4","border-focus":"#a6adbf","border-strong-base":"#747c92","border-strong-hover":"#6a7287","border-strong-active":"#60687c","border-strong-selected":"#565e71","border-strong-disabled":"#cbd0dd","border-strong-focus":"#666d82","surface-diff-add-base":"#e5f4ea","surface-diff-delete-base":"#fde7ea","surface-diff-hidden-base":"#e4e8f4","text-base":"#2b303b","text-weak":"#6b717f","text-strong":"#0e1118","syntax-string":"#4fa66d","syntax-primitive":"#d85462","syntax-property":"#528bff","syntax-type":"#d19a66","syntax-constant":"#61afef","syntax-info":"#61afef","markdown-heading":"#528bff","markdown-text":"#2b303b","markdown-link":"#528bff","markdown-link-text":"#61afef","markdown-code":"#4fa66d","markdown-block-quote":"#d19a66","markdown-emph":"#d19a66","markdown-strong":"#d85462","markdown-horizontal-rule":"#d3d7e4","markdown-list-item":"#528bff","markdown-list-enumeration":"#61afef","markdown-image":"#528bff","markdown-image-text":"#61afef","markdown-code-block":"#528bff"}},B5={seeds:{neutral:"#1e222a",primary:"#61afef",success:"#98c379",warning:"#e5c07b",error:"#e06c75",info:"#56b6c2",interactive:"#61afef",diffAdd:"#4b815a",diffDelete:"#b2555f"},overrides:{"background-base":"#1e222a","background-weak":"#212631","background-strong":"#1b1f27","background-stronger":"#171b23","border-weak-base":"#323848","border-weak-hover":"#363d52","border-weak-active":"#3c435c","border-weak-selected":"#424967","border-weak-disabled":"#141720","border-weak-focus":"#3f4560","border-base":"#4a5164","border-hover":"#515871","border-active":"#585f7e","border-selected":"#60688a","border-disabled":"#1a1e27","border-focus":"#555c79","border-strong-base":"#6a7390","border-strong-hover":"#737c9d","border-strong-active":"#7d87ab","border-strong-selected":"#8791b8","border-strong-disabled":"#212533","border-strong-focus":"#7680a2","surface-diff-add-base":"#1c2a26","surface-diff-delete-base":"#2a1c22","surface-diff-hidden-base":"#232836","text-base":"#abb2bf","text-weak":"#818899","text-strong":"#f6f7fb","syntax-string":"#98c379","syntax-primitive":"#e06c75","syntax-property":"#61afef","syntax-type":"#e5c07b","syntax-constant":"#56b6c2","syntax-info":"#56b6c2","markdown-heading":"#61afef","markdown-text":"#abb2bf","markdown-link":"#61afef","markdown-link-text":"#56b6c2","markdown-code":"#98c379","markdown-block-quote":"#e5c07b","markdown-emph":"#e5c07b","markdown-strong":"#e06c75","markdown-horizontal-rule":"#2d3444","markdown-list-item":"#61afef","markdown-list-enumeration":"#56b6c2","markdown-image":"#61afef","markdown-image-text":"#56b6c2","markdown-code-block":"#abb2bf"}},a5={$schema:i5,name:o5,id:g5,light:Q5,dark:B5},s5="https://opencode.ai/desktop-theme.json",E5="Shades of Purple",C5="shadesofpurple",I5={seeds:{neutral:"#f7ebff",primary:"#7a5af8",success:"#3dd598",warning:"#f7c948",error:"#ff6bd5",info:"#62d4ff",interactive:"#7a5af8",diffAdd:"#c8f8da",diffDelete:"#ffc3ef"},overrides:{"background-base":"#f7ebff","background-weak":"#f2e2ff","background-strong":"#fbf2ff","background-stronger":"#fff7ff","border-weak-base":"#e5d3ff","border-weak-hover":"#dac8f5","border-weak-active":"#d1bdeb","border-weak-selected":"#c6b3e1","border-weak-disabled":"#fcf6ff","border-weak-focus":"#ccb9e7","border-base":"#baa4d5","border-hover":"#b098cb","border-active":"#a68dc2","border-selected":"#9b82b8","border-disabled":"#f1e7ff","border-focus":"#a692c6","border-strong-base":"#8769a9","border-strong-hover":"#7b5c9d","border-strong-active":"#704f91","border-strong-selected":"#664587","border-strong-disabled":"#d8c4f0","border-strong-focus":"#755495","surface-diff-add-base":"#edf8f1","surface-diff-delete-base":"#ffe4f4","surface-diff-hidden-base":"#e9e4ff","text-base":"#3b2c59","text-weak":"#6c568f","text-strong":"#1c1033","syntax-string":"#3dd598","syntax-primitive":"#ff6bd5","syntax-property":"#7a5af8","syntax-type":"#f7c948","syntax-constant":"#62d4ff","syntax-info":"#62d4ff","markdown-heading":"#7a5af8","markdown-text":"#3b2c59","markdown-link":"#7a5af8","markdown-link-text":"#62d4ff","markdown-code":"#3dd598","markdown-block-quote":"#f7c948","markdown-emph":"#f7c948","markdown-strong":"#ff6bd5","markdown-horizontal-rule":"#decbed","markdown-list-item":"#7a5af8","markdown-list-enumeration":"#62d4ff","markdown-image":"#7a5af8","markdown-image-text":"#62d4ff","markdown-code-block":"#7a5af8"}},l5={seeds:{neutral:"#1a102b",primary:"#c792ff",success:"#7be0b0",warning:"#ffd580",error:"#ff7ac6",info:"#7dd4ff",interactive:"#c792ff",diffAdd:"#53c39f",diffDelete:"#d85aa0"},overrides:{"background-base":"#1a102b","background-weak":"#1f1434","background-strong":"#1c122f","background-stronger":"#170e26","border-weak-base":"#352552","border-weak-hover":"#3a2a5d","border-weak-active":"#402f68","border-weak-selected":"#463674","border-weak-disabled":"#10091b","border-weak-focus":"#3d2d65","border-base":"#4d3a73","border-hover":"#553f7f","border-active":"#5d468c","border-selected":"#654c99","border-disabled":"#150d21","border-focus":"#594283","border-strong-base":"#7659b0","border-strong-hover":"#8262be","border-strong-active":"#8e6ccc","border-strong-selected":"#9a77da","border-strong-disabled":"#1c122c","border-strong-focus":"#8666c4","surface-diff-add-base":"#142c27","surface-diff-delete-base":"#2d1424","surface-diff-hidden-base":"#231737","text-base":"#f5f0ff","text-weak":"#c9b6ff","text-strong":"#ffffff","syntax-string":"#7be0b0","syntax-primitive":"#ff7ac6","syntax-property":"#c792ff","syntax-type":"#ffd580","syntax-constant":"#7dd4ff","syntax-info":"#7dd4ff","markdown-heading":"#c792ff","markdown-text":"#f5f0ff","markdown-link":"#c792ff","markdown-link-text":"#7dd4ff","markdown-code":"#7be0b0","markdown-block-quote":"#ffd580","markdown-emph":"#ffd580","markdown-strong":"#ff7ac6","markdown-horizontal-rule":"#2d1d41","markdown-list-item":"#c792ff","markdown-list-enumeration":"#7dd4ff","markdown-image":"#c792ff","markdown-image-text":"#7dd4ff","markdown-code-block":"#f5f0ff"}},c5={$schema:s5,name:E5,id:C5,light:I5,dark:l5},u5=c6,d5=w6,h5=N6,D5=S6,f5=O6,w5=P6,m5=X6,p5=n5,k5=a5,y5=c5,M5={"oc-1":u5,tokyonight:d5,dracula:h5,monokai:D5,solarized:f5,nord:w5,catppuccin:m5,ayu:p5,onedarkpro:k5,shadesofpurple:y5},Gi={THEME_ID:"opencode-theme-id",COLOR_SCHEME:"opencode-color-scheme",THEME_CSS_LIGHT:"opencode-theme-css-light",THEME_CSS_DARK:"opencode-theme-css-dark"},uf="oc-theme";function N5(){const e=document.getElementById(uf);if(e)return e;const A=document.createElement("style");return A.id=uf,document.head.appendChild(A),A}function DQ(){return window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}function xa(e,A,t){const r=t==="dark",n=r?e.dark:e.light,i=ku(n,r),o=Py(i);if(A!=="oc-1")try{localStorage.setItem(r?Gi.THEME_CSS_DARK:Gi.THEME_CSS_LIGHT,o)}catch{}const g=`:root { color-scheme: ${t}; --text-mix-blend-mode: ${r?"plus-lighter":"multiply"}; ${o} }`;document.getElementById("oc-theme-preload")?.remove(),N5().textContent=g,document.documentElement.dataset.theme=A,document.documentElement.dataset.colorScheme=t}function df(e,A){if(A!=="oc-1")for(const t of["light","dark"]){const r=t==="dark",n=r?e.dark:e.light,i=ku(n,r),o=Py(i);try{localStorage.setItem(r?Gi.THEME_CSS_DARK:Gi.THEME_CSS_LIGHT,o)}catch{}}}const{use:_y,provider:v5}=qt({name:"Theme",init:e=>{const[A,t]=xe({themes:M5,themeId:e.defaultTheme??"oc-1",colorScheme:"system",mode:DQ(),previewThemeId:null,previewScheme:null});et(()=>{const i=window.matchMedia("(prefers-color-scheme: dark)"),o=()=>{A.colorScheme==="system"&&t("mode",DQ())};i.addEventListener("change",o),dA(()=>i.removeEventListener("change",o));const g=localStorage.getItem(Gi.THEME_ID),Q=localStorage.getItem(Gi.COLOR_SCHEME);g&&A.themes[g]&&t("themeId",g),Q&&(t("colorScheme",Q),Q!=="system"&&t("mode",Q));const B=A.themes[A.themeId];B&&df(B,A.themeId)}),tA(()=>{const i=A.themes[A.themeId];i&&xa(i,A.themeId,A.mode)});const r=i=>{const o=A.themes[i];if(!o){console.warn(`Theme "${i}" not found`);return}t("themeId",i),localStorage.setItem(Gi.THEME_ID,i),df(o,i)},n=i=>{t("colorScheme",i),localStorage.setItem(Gi.COLOR_SCHEME,i),t("mode",i==="system"?DQ():i)};return{themeId:()=>A.themeId,colorScheme:()=>A.colorScheme,mode:()=>A.mode,themes:()=>A.themes,setTheme:r,setColorScheme:n,registerTheme:i=>t("themes",i.id,i),previewTheme:i=>{const o=A.themes[i];if(!o)return;t("previewThemeId",i);const g=A.previewScheme?A.previewScheme==="system"?DQ():A.previewScheme:A.mode;xa(o,i,g)},previewColorScheme:i=>{t("previewScheme",i);const o=i==="system"?DQ():i,g=A.previewThemeId??A.themeId,Q=A.themes[g];Q&&xa(Q,g,o)},commitPreview:()=>{A.previewThemeId&&r(A.previewThemeId),A.previewScheme&&n(A.previewScheme),t("previewThemeId",null),t("previewScheme",null)},cancelPreview:()=>{t("previewThemeId",null),t("previewScheme",null);const i=A.themes[A.themeId];i&&xa(i,A.themeId,A.mode)}}}}),b5=({onRequest:e,onSseError:A,onSseEvent:t,responseTransformer:r,responseValidator:n,sseDefaultRetryDelay:i,sseMaxRetryAttempts:o,sseMaxRetryDelay:g,sseSleepFn:Q,url:B,...a})=>{let s;const C=Q??(c=>new Promise(u=>setTimeout(u,c)));return{stream:async function*(){let c=i??3e3,u=0;const h=a.signal??new AbortController().signal;for(;!h.aborted;){u++;const d=a.headers instanceof Headers?a.headers:new Headers(a.headers);s!==void 0&&d.set("Last-Event-ID",s);try{const f={redirect:"follow",...a,body:a.serializedBody,headers:d,signal:h};let m=new Request(B,f);e&&(m=await e(B,f));const N=await(a.fetch??globalThis.fetch)(m);if(!N.ok)throw new Error(`SSE failed: ${N.status} ${N.statusText}`);if(!N.body)throw new Error("No body in SSE response");const F=N.body.pipeThrough(new TextDecoderStream).getReader();let L="";const v=()=>{try{F.cancel()}catch{}};h.addEventListener("abort",v);try{for(;;){const{done:O,value:W}=await F.read();if(O)break;L+=W;const AA=L.split(` `);L=AA.pop()??"";for(const kA of AA){const K=kA.split(` `),$=[];let P;for(const MA of K)if(MA.startsWith("data:"))$.push(MA.replace(/^data:\s*/,""));else if(MA.startsWith("event:"))P=MA.replace(/^event:\s*/,"");else if(MA.startsWith("id:"))s=MA.replace(/^id:\s*/,"");else if(MA.startsWith("retry:")){const mA=Number.parseInt(MA.replace(/^retry:\s*/,""),10);Number.isNaN(mA)||(c=mA)}let SA,fA=!1;if($.length){const MA=$.join(` `);try{SA=JSON.parse(MA),fA=!0}catch{SA=MA}}fA&&(n&&await n(SA),r&&(SA=await r(SA))),t?.({data:SA,event:P,id:s,retry:c}),$.length&&(yield SA)}}}finally{h.removeEventListener("abort",v),F.releaseLock()}break}catch(f){if(A?.(f),o!==void 0&&u>=o)break;const m=Math.min(c*2**(u-1),g??3e4);await C(m)}}}()}},F5=e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},x5=e=>{switch(e){case"form":return",";case"pipeDelimited":return"|";case"spaceDelimited":return"%20";default:return","}},G5=e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},jy=({allowReserved:e,explode:A,name:t,style:r,value:n})=>{if(!A){const g=(e?n:n.map(Q=>encodeURIComponent(Q))).join(x5(r));switch(r){case"label":return`.${g}`;case"matrix":return`;${t}=${g}`;case"simple":return g;default:return`${t}=${g}`}}const i=F5(r),o=n.map(g=>r==="label"||r==="simple"?e?g:encodeURIComponent(g):mE({allowReserved:e,name:t,value:g})).join(i);return r==="label"||r==="matrix"?i+o:o},mE=({allowReserved:e,name:A,value:t})=>{if(t==null)return"";if(typeof t=="object")throw new Error("Deeply-nested arrays/objects aren’t supported. Provide your own `querySerializer()` to handle these.");return`${A}=${e?t:encodeURIComponent(t)}`},Vy=({allowReserved:e,explode:A,name:t,style:r,value:n,valueOnly:i})=>{if(n instanceof Date)return i?n.toISOString():`${t}=${n.toISOString()}`;if(r!=="deepObject"&&!A){let Q=[];Object.entries(n).forEach(([a,s])=>{Q=[...Q,a,e?s:encodeURIComponent(s)]});const B=Q.join(",");switch(r){case"form":return`${t}=${B}`;case"label":return`.${B}`;case"matrix":return`;${t}=${B}`;default:return B}}const o=G5(r),g=Object.entries(n).map(([Q,B])=>mE({allowReserved:e,name:r==="deepObject"?`${t}[${Q}]`:Q,value:B})).join(o);return r==="label"||r==="matrix"?o+g:g},S5=/\{[^{}]+\}/g,J5=({path:e,url:A})=>{let t=A;const r=A.match(S5);if(r)for(const n of r){let i=!1,o=n.substring(1,n.length-1),g="simple";o.endsWith("*")&&(i=!0,o=o.substring(0,o.length-1)),o.startsWith(".")?(o=o.substring(1),g="label"):o.startsWith(";")&&(o=o.substring(1),g="matrix");const Q=e[o];if(Q==null)continue;if(Array.isArray(Q)){t=t.replace(n,jy({explode:i,name:o,style:g,value:Q}));continue}if(typeof Q=="object"){t=t.replace(n,Vy({explode:i,name:o,style:g,value:Q,valueOnly:!0}));continue}if(g==="matrix"){t=t.replace(n,`;${mE({name:o,value:Q})}`);continue}const B=encodeURIComponent(g==="label"?`.${Q}`:Q);t=t.replace(n,B)}return t},U5=({baseUrl:e,path:A,query:t,querySerializer:r,url:n})=>{const i=n.startsWith("/")?n:`/${n}`;let o=(e??"")+i;A&&(o=J5({path:A,url:o}));let g=t?r(t):"";return g.startsWith("?")&&(g=g.substring(1)),g&&(o+=`?${g}`),o};function K5(e){const A=e.body!==void 0;if(A&&e.bodySerializer)return"serializedBody"in e?e.serializedBody!==void 0&&e.serializedBody!==""?e.serializedBody:null:e.body!==""?e.body:null;if(A)return e.body}const L5=async(e,A)=>{const t=typeof A=="function"?await A(e):A;if(t)return e.scheme==="bearer"?`Bearer ${t}`:e.scheme==="basic"?`Basic ${btoa(t)}`:t},R5={bodySerializer:e=>JSON.stringify(e,(A,t)=>typeof t=="bigint"?t.toString():t)},Wy=({parameters:e={},...A}={})=>r=>{const n=[];if(r&&typeof r=="object")for(const i in r){const o=r[i];if(o==null)continue;const g=e[i]||A;if(Array.isArray(o)){const Q=jy({allowReserved:g.allowReserved,explode:!0,name:i,style:"form",value:o,...g.array});Q&&n.push(Q)}else if(typeof o=="object"){const Q=Vy({allowReserved:g.allowReserved,explode:!0,name:i,style:"deepObject",value:o,...g.object});Q&&n.push(Q)}else{const Q=mE({allowReserved:g.allowReserved,name:i,value:o});Q&&n.push(Q)}}return n.join("&")},O5=e=>{if(!e)return"stream";const A=e.split(";")[0]?.trim();if(A){if(A.startsWith("application/json")||A.endsWith("+json"))return"json";if(A==="multipart/form-data")return"formData";if(["application/","audio/","image/","video/"].some(t=>A.startsWith(t)))return"blob";if(A.startsWith("text/"))return"text"}},q5=(e,A)=>A?!!(e.headers.has(A)||e.query?.[A]||e.headers.get("Cookie")?.includes(`${A}=`)):!1,T5=async({security:e,...A})=>{for(const t of e){if(q5(A,t.name))continue;const r=await L5(t,A.auth);if(!r)continue;const n=t.name??"Authorization";switch(t.in){case"query":A.query||(A.query={}),A.query[n]=r;break;case"cookie":A.headers.append("Cookie",`${n}=${r}`);break;case"header":default:A.headers.set(n,r);break}}},hf=e=>U5({baseUrl:e.baseUrl,path:e.path,query:e.query,querySerializer:typeof e.querySerializer=="function"?e.querySerializer:Wy(e.querySerializer),url:e.url}),Df=(e,A)=>{const t={...e,...A};return t.baseUrl?.endsWith("/")&&(t.baseUrl=t.baseUrl.substring(0,t.baseUrl.length-1)),t.headers=Zy(e.headers,A.headers),t},H5=e=>{const A=[];return e.forEach((t,r)=>{A.push([r,t])}),A},Zy=(...e)=>{const A=new Headers;for(const t of e){if(!t)continue;const r=t instanceof Headers?H5(t):Object.entries(t);for(const[n,i]of r)if(i===null)A.delete(n);else if(Array.isArray(i))for(const o of i)A.append(n,o);else i!==void 0&&A.set(n,typeof i=="object"?JSON.stringify(i):i)}return A};class cI{fns=[];clear(){this.fns=[]}eject(A){const t=this.getInterceptorIndex(A);this.fns[t]&&(this.fns[t]=null)}exists(A){const t=this.getInterceptorIndex(A);return!!this.fns[t]}getInterceptorIndex(A){return typeof A=="number"?this.fns[A]?A:-1:this.fns.indexOf(A)}update(A,t){const r=this.getInterceptorIndex(A);return this.fns[r]?(this.fns[r]=t,A):!1}use(A){return this.fns.push(A),this.fns.length-1}}const Y5=()=>({error:new cI,request:new cI,response:new cI}),z5=Wy({allowReserved:!1,array:{explode:!0,style:"form"},object:{explode:!0,style:"deepObject"}}),P5={"Content-Type":"application/json"},Xy=(e={})=>({...R5,headers:P5,parseAs:"auto",querySerializer:z5,...e}),$y=(e={})=>{let A=Df(Xy(),e);const t=()=>({...A}),r=B=>(A=Df(A,B),t()),n=Y5(),i=async B=>{const a={...A,...B,fetch:B.fetch??A.fetch??globalThis.fetch,headers:Zy(A.headers,B.headers),serializedBody:void 0};a.security&&await T5({...a,security:a.security}),a.requestValidator&&await a.requestValidator(a),a.body!==void 0&&a.bodySerializer&&(a.serializedBody=a.bodySerializer(a.body)),(a.body===void 0||a.serializedBody==="")&&a.headers.delete("Content-Type");const s=hf(a);return{opts:a,url:s}},o=async B=>{const{opts:a,url:s}=await i(B),C={redirect:"follow",...a,body:K5(a)};let E=new Request(s,C);for(const k of n.request.fns)k&&(E=await k(E,a));const I=a.fetch;let c;try{c=await I(E)}catch(k){let N=k;for(const F of n.error.fns)F&&(N=await F(k,void 0,E,a));if(N=N||{},a.throwOnError)throw N;return a.responseStyle==="data"?void 0:{error:N,request:E,response:void 0}}for(const k of n.response.fns)k&&(c=await k(c,E,a));const u={request:E,response:c};if(c.ok){const k=(a.parseAs==="auto"?O5(c.headers.get("Content-Type")):a.parseAs)??"json";if(c.status===204||c.headers.get("Content-Length")==="0"){let F;switch(k){case"arrayBuffer":case"blob":case"text":F=await c[k]();break;case"formData":F=new FormData;break;case"stream":F=c.body;break;case"json":default:F={};break}return a.responseStyle==="data"?F:{data:F,...u}}let N;switch(k){case"arrayBuffer":case"blob":case"formData":case"json":case"text":N=await c[k]();break;case"stream":return a.responseStyle==="data"?c.body:{data:c.body,...u}}return k==="json"&&(a.responseValidator&&await a.responseValidator(N),a.responseTransformer&&(N=await a.responseTransformer(N))),a.responseStyle==="data"?N:{data:N,...u}}const h=await c.text();let d;try{d=JSON.parse(h)}catch{}const f=d??h;let m=f;for(const k of n.error.fns)k&&(m=await k(f,c,E,a));if(m=m||{},a.throwOnError)throw m;return a.responseStyle==="data"?void 0:{error:m,...u}},g=B=>a=>o({...a,method:B}),Q=B=>async a=>{const{opts:s,url:C}=await i(a);return b5({...s,body:s.body,headers:s.headers,method:B,onRequest:async(E,I)=>{let c=new Request(E,I);for(const u of n.request.fns)u&&(c=await u(c,s));return c},url:C})};return{buildUrl:hf,connect:g("CONNECT"),delete:g("DELETE"),get:g("GET"),getConfig:t,head:g("HEAD"),interceptors:n,options:g("OPTIONS"),patch:g("PATCH"),post:g("POST"),put:g("PUT"),request:o,setConfig:r,sse:{connect:Q("CONNECT"),delete:Q("DELETE"),get:Q("GET"),head:Q("HEAD"),options:Q("OPTIONS"),patch:Q("PATCH"),post:Q("POST"),put:Q("PUT"),trace:Q("TRACE")},trace:g("TRACE")}},_5={$body_:"body",$headers_:"headers",$path_:"path",$query_:"query"},j5=Object.entries(_5),AM=(e,A)=>{A||(A=new Map);for(const t of e)"in"in t?t.key&&A.set(t.key,{in:t.in,map:t.map}):"key"in t?A.set(t.key,{map:t.map}):t.args&&AM(t.args,A);return A},V5=e=>{for(const[A,t]of Object.entries(e))t&&typeof t=="object"&&!Object.keys(t).length&&delete e[A]},KA=(e,A)=>{const t={body:{},headers:{},path:{},query:{}},r=AM(A);let n;for(const[i,o]of e.entries())if(A[i]&&(n=A[i]),!!n)if("in"in n)if(n.key){const g=r.get(n.key),Q=g.map||n.key;g.in&&(t[g.in][Q]=o)}else t.body=o;else for(const[g,Q]of Object.entries(o??{})){const B=r.get(g);if(B)if(B.in){const a=B.map||g;t[B.in][a]=Q}else t[B.map]=Q;else{const a=j5.find(([s])=>g.startsWith(s));if(a){const[s,C]=a;t[C][g.slice(s.length)]=Q}else if("allowExtra"in n&&n.allowExtra){for(const[s,C]of Object.entries(n.allowExtra))if(C){t[s][g]=Q;break}}}}return V5(t),t},W5=$y(Xy({baseUrl:"http://localhost:4096"}));class tt{client;constructor(A){this.client=A?.client??W5}}class Z5{defaultKey="default";instances=new Map;get(A){const t=this.instances.get(A??this.defaultKey);if(!t)throw new Error('No SDK client found. Create one with "new OpencodeClient()" to fix this error.');return t}set(A,t){this.instances.set(t??this.defaultKey,A)}}class X5 extends tt{health(A){return(A?.client??this.client).get({url:"/global/health",...A})}event(A){return(A?.client??this.client).sse.get({url:"/global/event",...A})}dispose(A){return(A?.client??this.client).post({url:"/global/dispose",...A})}}class $5 extends tt{list(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/project",...t,...r})}current(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/project/current",...t,...r})}update(A,t){const r=KA([A],[{args:[{in:"path",key:"projectID"},{in:"query",key:"directory"},{in:"body",key:"name"},{in:"body",key:"icon"}]}]);return(t?.client??this.client).patch({url:"/project/{projectID}",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}}class AT extends tt{list(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/pty",...t,...r})}create(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"body",key:"command"},{in:"body",key:"args"},{in:"body",key:"cwd"},{in:"body",key:"title"},{in:"body",key:"env"}]}]);return(t?.client??this.client).post({url:"/pty",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}remove(A,t){const r=KA([A],[{args:[{in:"path",key:"ptyID"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).delete({url:"/pty/{ptyID}",...t,...r})}get(A,t){const r=KA([A],[{args:[{in:"path",key:"ptyID"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/pty/{ptyID}",...t,...r})}update(A,t){const r=KA([A],[{args:[{in:"path",key:"ptyID"},{in:"query",key:"directory"},{in:"body",key:"title"},{in:"body",key:"size"}]}]);return(t?.client??this.client).put({url:"/pty/{ptyID}",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}connect(A,t){const r=KA([A],[{args:[{in:"path",key:"ptyID"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/pty/{ptyID}/connect",...t,...r})}}class eT extends tt{get(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/config",...t,...r})}update(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{key:"config",map:"body"}]}]);return(t?.client??this.client).patch({url:"/config",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}providers(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/config/providers",...t,...r})}}class tT extends tt{ids(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/experimental/tool/ids",...t,...r})}list(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"query",key:"provider"},{in:"query",key:"model"}]}]);return(t?.client??this.client).get({url:"/experimental/tool",...t,...r})}}class rT extends tt{dispose(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).post({url:"/instance/dispose",...t,...r})}}class nT extends tt{get(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/path",...t,...r})}}class iT extends tt{get(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/vcs",...t,...r})}}class oT extends tt{list(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/session",...t,...r})}create(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"body",key:"parentID"},{in:"body",key:"title"}]}]);return(t?.client??this.client).post({url:"/session",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}status(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/session/status",...t,...r})}delete(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).delete({url:"/session/{sessionID}",...t,...r})}get(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/session/{sessionID}",...t,...r})}update(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"body",key:"title"},{in:"body",key:"time"}]}]);return(t?.client??this.client).patch({url:"/session/{sessionID}",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}children(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/session/{sessionID}/children",...t,...r})}todo(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/session/{sessionID}/todo",...t,...r})}init(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"body",key:"modelID"},{in:"body",key:"providerID"},{in:"body",key:"messageID"}]}]);return(t?.client??this.client).post({url:"/session/{sessionID}/init",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}fork(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"body",key:"messageID"}]}]);return(t?.client??this.client).post({url:"/session/{sessionID}/fork",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}abort(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).post({url:"/session/{sessionID}/abort",...t,...r})}unshare(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).delete({url:"/session/{sessionID}/share",...t,...r})}share(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).post({url:"/session/{sessionID}/share",...t,...r})}diff(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"messageID"}]}]);return(t?.client??this.client).get({url:"/session/{sessionID}/diff",...t,...r})}summarize(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"body",key:"providerID"},{in:"body",key:"modelID"},{in:"body",key:"auto"}]}]);return(t?.client??this.client).post({url:"/session/{sessionID}/summarize",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}messages(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"limit"}]}]);return(t?.client??this.client).get({url:"/session/{sessionID}/message",...t,...r})}prompt(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"body",key:"messageID"},{in:"body",key:"model"},{in:"body",key:"agent"},{in:"body",key:"noReply"},{in:"body",key:"tools"},{in:"body",key:"system"},{in:"body",key:"variant"},{in:"body",key:"parts"}]}]);return(t?.client??this.client).post({url:"/session/{sessionID}/message",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}message(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"path",key:"messageID"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/session/{sessionID}/message/{messageID}",...t,...r})}promptAsync(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"body",key:"messageID"},{in:"body",key:"model"},{in:"body",key:"agent"},{in:"body",key:"noReply"},{in:"body",key:"tools"},{in:"body",key:"system"},{in:"body",key:"variant"},{in:"body",key:"parts"}]}]);return(t?.client??this.client).post({url:"/session/{sessionID}/prompt_async",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}command(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"body",key:"messageID"},{in:"body",key:"agent"},{in:"body",key:"model"},{in:"body",key:"arguments"},{in:"body",key:"command"},{in:"body",key:"variant"}]}]);return(t?.client??this.client).post({url:"/session/{sessionID}/command",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}shell(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"body",key:"agent"},{in:"body",key:"model"},{in:"body",key:"command"}]}]);return(t?.client??this.client).post({url:"/session/{sessionID}/shell",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}revert(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"body",key:"messageID"},{in:"body",key:"partID"}]}]);return(t?.client??this.client).post({url:"/session/{sessionID}/revert",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}unrevert(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).post({url:"/session/{sessionID}/unrevert",...t,...r})}}let gT=class extends tt{delete(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"path",key:"messageID"},{in:"path",key:"partID"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).delete({url:"/session/{sessionID}/message/{messageID}/part/{partID}",...t,...r})}update(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"path",key:"messageID"},{in:"path",key:"partID"},{in:"query",key:"directory"},{key:"part",map:"body"}]}]);return(t?.client??this.client).patch({url:"/session/{sessionID}/message/{messageID}/part/{partID}",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}};class QT extends tt{respond(A,t){const r=KA([A],[{args:[{in:"path",key:"sessionID"},{in:"path",key:"permissionID"},{in:"query",key:"directory"},{in:"body",key:"response"}]}]);return(t?.client??this.client).post({url:"/session/{sessionID}/permissions/{permissionID}",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}list(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/permission",...t,...r})}}class BT extends tt{list(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/command",...t,...r})}}class aT extends tt{authorize(A,t){const r=KA([A],[{args:[{in:"path",key:"providerID"},{in:"query",key:"directory"},{in:"body",key:"method"}]}]);return(t?.client??this.client).post({url:"/provider/{providerID}/oauth/authorize",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}callback(A,t){const r=KA([A],[{args:[{in:"path",key:"providerID"},{in:"query",key:"directory"},{in:"body",key:"method"},{in:"body",key:"code"}]}]);return(t?.client??this.client).post({url:"/provider/{providerID}/oauth/callback",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}}class sT extends tt{list(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/provider",...t,...r})}auth(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/provider/auth",...t,...r})}oauth=new aT({client:this.client})}class ET extends tt{text(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"query",key:"pattern"}]}]);return(t?.client??this.client).get({url:"/find",...t,...r})}files(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"query",key:"query"},{in:"query",key:"dirs"},{in:"query",key:"type"},{in:"query",key:"limit"}]}]);return(t?.client??this.client).get({url:"/find/file",...t,...r})}symbols(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"query",key:"query"}]}]);return(t?.client??this.client).get({url:"/find/symbol",...t,...r})}}let CT=class extends tt{list(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"query",key:"path"}]}]);return(t?.client??this.client).get({url:"/file",...t,...r})}read(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"query",key:"path"}]}]);return(t?.client??this.client).get({url:"/file/content",...t,...r})}status(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/file/status",...t,...r})}},IT=class extends tt{log(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"body",key:"service"},{in:"body",key:"level"},{in:"body",key:"message"},{in:"body",key:"extra"}]}]);return(t?.client??this.client).post({url:"/log",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}agents(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/agent",...t,...r})}};class eM extends tt{remove(A,t){const r=KA([A],[{args:[{in:"path",key:"name"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).delete({url:"/mcp/{name}/auth",...t,...r})}start(A,t){const r=KA([A],[{args:[{in:"path",key:"name"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).post({url:"/mcp/{name}/auth",...t,...r})}callback(A,t){const r=KA([A],[{args:[{in:"path",key:"name"},{in:"query",key:"directory"},{in:"body",key:"code"}]}]);return(t?.client??this.client).post({url:"/mcp/{name}/auth/callback",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}authenticate(A,t){const r=KA([A],[{args:[{in:"path",key:"name"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).post({url:"/mcp/{name}/auth/authenticate",...t,...r})}set(A,t){const r=KA([A],[{args:[{in:"path",key:"providerID"},{in:"query",key:"directory"},{key:"auth",map:"body"}]}]);return(t?.client??this.client).put({url:"/auth/{providerID}",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}}class lT extends tt{status(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/mcp",...t,...r})}add(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"body",key:"name"},{in:"body",key:"config"}]}]);return(t?.client??this.client).post({url:"/mcp",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}connect(A,t){const r=KA([A],[{args:[{in:"path",key:"name"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).post({url:"/mcp/{name}/connect",...t,...r})}disconnect(A,t){const r=KA([A],[{args:[{in:"path",key:"name"},{in:"query",key:"directory"}]}]);return(t?.client??this.client).post({url:"/mcp/{name}/disconnect",...t,...r})}auth=new eM({client:this.client})}class cT extends tt{status(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/lsp",...t,...r})}}let uT=class extends tt{status(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/formatter",...t,...r})}};class dT extends tt{next(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).get({url:"/tui/control/next",...t,...r})}response(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"body"}]}]);return(t?.client??this.client).post({url:"/tui/control/response",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}}class hT extends tt{appendPrompt(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"body",key:"text"}]}]);return(t?.client??this.client).post({url:"/tui/append-prompt",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}openHelp(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).post({url:"/tui/open-help",...t,...r})}openSessions(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).post({url:"/tui/open-sessions",...t,...r})}openThemes(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).post({url:"/tui/open-themes",...t,...r})}openModels(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).post({url:"/tui/open-models",...t,...r})}submitPrompt(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).post({url:"/tui/submit-prompt",...t,...r})}clearPrompt(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).post({url:"/tui/clear-prompt",...t,...r})}executeCommand(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"body",key:"command"}]}]);return(t?.client??this.client).post({url:"/tui/execute-command",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}showToast(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"body",key:"title"},{in:"body",key:"message"},{in:"body",key:"variant"},{in:"body",key:"duration"}]}]);return(t?.client??this.client).post({url:"/tui/show-toast",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}publish(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"},{in:"body"}]}]);return(t?.client??this.client).post({url:"/tui/publish",...t,...r,headers:{"Content-Type":"application/json",...t?.headers,...r.headers}})}control=new dT({client:this.client})}let DT=class extends tt{subscribe(A,t){const r=KA([A],[{args:[{in:"query",key:"directory"}]}]);return(t?.client??this.client).sse.get({url:"/event",...t,...r})}};class yu extends tt{static __registry=new Z5;constructor(A){super(A),yu.__registry.set(this,A?.key)}global=new X5({client:this.client});project=new $5({client:this.client});pty=new AT({client:this.client});config=new eT({client:this.client});tool=new tT({client:this.client});instance=new rT({client:this.client});path=new nT({client:this.client});vcs=new iT({client:this.client});session=new oT({client:this.client});part=new gT({client:this.client});permission=new QT({client:this.client});command=new BT({client:this.client});provider=new sT({client:this.client});find=new ET({client:this.client});file=new CT({client:this.client});app=new IT({client:this.client});mcp=new lT({client:this.client});lsp=new cT({client:this.client});formatter=new uT({client:this.client});tui=new hT({client:this.client});auth=new eM({client:this.client});event=new DT({client:this.client})}function So(e){e?.fetch||(e={...e,fetch:r=>(r.timeout=!1,fetch(r))}),e?.directory&&(e.headers={...e.headers,"x-opencode-directory":e.directory});const A=$y(e);return new yu({client:A})}var vt;(e=>{function A(r,n,i){let o=0,g=r.length-1;for(;o<=g;){const Q=Math.floor((o+g)/2),B=i(r[Q]);if(B===n)return{found:!0,index:Q};BA.includes(t))}async function Hn(e,A={}){const{attempts:t=3,delay:r=500,factor:n=2,maxDelay:i=1e4,retryIf:o=wT}=A;let g;for(let Q=0;QsetTimeout(s,a))}throw g}const{use:Zg,provider:mT}=qt({name:"Data",init:e=>({get store(){return e.data},get directory(){return e.directory},respondToPermission:e.onPermissionRespond})}),pT=e=>e!=null,kT=e=>e.filter(pT);function yT(e){return(...A)=>{for(const t of e)t&&t(...A)}}const oA=e=>typeof e=="function"&&!e.length?e():e,Fl=e=>Array.isArray(e)?e:e?[e]:[];function MT(e,...A){return typeof e=="function"?e(...A):e}const Mu=dA;function NT(e,A,t){return gA(A(),t)}function vT(e,A,t,r){const n=e.length,i=A.length;let o=0;if(!i){for(;o{Fl(oA(e)).forEach(i=>{i&&Fl(oA(A)).forEach(o=>bT(i,o,t,r))})};typeof e=="function"?tA(n):_A(n)}const uI=Symbol("fallback");function ff(e){for(const A of e)A.dispose()}function FT(e,A,t,r={}){const n=new Map;return dA(()=>ff(n.values())),()=>{const o=e()||[];return o[gs],fe(()=>{if(!o.length)return ff(n.values()),n.clear(),r.fallback?[Si(s=>(n.set(uI,{dispose:s}),r.fallback()))]:[];const g=new Array(o.length),Q=n.get(uI);if(!n.size||Q){Q?.dispose(),n.delete(uI);for(let a=0;as)):i(g,s,a,C)}for(const a of B)n.get(a)?.dispose(),n.delete(a);return g})};function i(o,g,Q,B){Si(a=>{const[s,C]=gA(g),E={setItem:C,dispose:a};if(t.length>1){const[I,c]=gA(Q);E.setIndex=c,E.mapped=t(s,I)}else E.mapped=t(s);n.set(B,E),o[Q]=E.mapped})}}function xT(e){const{by:A}=e;return S(FT(()=>e.each,typeof A=="function"?A:t=>t[A],e.children,"fallback"in e?{fallback:()=>e.fallback}:void 0))}const GT=/((?:--)?(?:\w+-?)+)\s*:\s*([^;]*)/g;function wf(e){const A={};let t;for(;t=GT.exec(e);)A[t[1]]=t[2];return A}function Tt(e,A){if(typeof e=="string"){if(typeof A=="string")return`${e};${A}`;e=wf(e)}else typeof A=="string"&&(A=wf(A));return{...e,...A}}function ae(...e){return yT(e)}function ST(e,A,t=-1){return t in e?[...e.slice(0,t),A,...e.slice(t)]:[...e,A]}function Gl(e,A){const t=[...e],r=t.indexOf(A);return r!==-1&&t.splice(r,1),t}function JT(e){return typeof e=="number"}function ug(e){return Object.prototype.toString.call(e)==="[object String]"}function Xg(e){return typeof e=="function"}function Gt(e){return A=>`${e()}-${A}`}function bt(e,A){return e?e===A||e.contains(A):!1}function GQ(e,A=!1){const{activeElement:t}=nr(e);if(!t?.nodeName)return null;if(tM(t)&&t.contentDocument)return GQ(t.contentDocument.body,A);if(A){const r=t.getAttribute("aria-activedescendant");if(r){const n=nr(t).getElementById(r);if(n)return n}}return t}function Nu(e){return nr(e).defaultView||window}function nr(e){return e?e.ownerDocument||e:document}function tM(e){return e.tagName==="IFRAME"}var xB=(e=>(e.Escape="Escape",e.Enter="Enter",e.Tab="Tab",e.Space=" ",e.ArrowDown="ArrowDown",e.ArrowLeft="ArrowLeft",e.ArrowRight="ArrowRight",e.ArrowUp="ArrowUp",e.End="End",e.Home="Home",e.PageDown="PageDown",e.PageUp="PageUp",e))(xB||{});function rM(e){return typeof window>"u"||window.navigator==null?!1:window.navigator.userAgentData?.brands.some(A=>e.test(A.brand))||e.test(window.navigator.userAgent)}function vu(e){return typeof window<"u"&&window.navigator!=null?e.test(window.navigator.userAgentData?.platform||window.navigator.platform):!1}function GB(){return vu(/^Mac/i)}function UT(){return vu(/^iPhone/i)}function KT(){return vu(/^iPad/i)||GB()&&navigator.maxTouchPoints>1}function LT(){return UT()||KT()}function RT(){return GB()||LT()}function nM(){return rM(/AppleWebKit/i)&&!OT()}function OT(){return rM(/Chrome/i)}function WA(e,A){return A&&(Xg(A)?A(e):A[0](A[1],e)),e?.defaultPrevented}function ge(e){return A=>{for(const t of e)WA(A,t)}}function qT(e){return GB()?e.metaKey&&!e.ctrlKey:e.ctrlKey&&!e.metaKey}function At(e){if(e)if(TT())e.focus({preventScroll:!0});else{const A=HT(e);e.focus(),YT(A)}}var Ga=null;function TT(){if(Ga==null){Ga=!1;try{document.createElement("div").focus({get preventScroll(){return Ga=!0,!0}})}catch{}}return Ga}function HT(e){let A=e.parentNode;const t=[],r=document.scrollingElement||document.documentElement;for(;A instanceof HTMLElement&&A!==r;)(A.offsetHeight{if(tM(n)&&n.contentDocument){const o=n.contentDocument.body,g=oM(o,!1);r.splice(i,1,...g)}}),r}function mf(e){return gM(e)&&!_T(e)}function gM(e){return e.matches(bu)&&Fu(e)}function _T(e){return Number.parseInt(e.getAttribute("tabindex")||"0",10)<0}function Fu(e,A){return e.nodeName!=="#comment"&&jT(e)&&VT(e,A)&&(!e.parentElement||Fu(e.parentElement,e))}function jT(e){if(!(e instanceof HTMLElement)&&!(e instanceof SVGElement))return!1;const{display:A,visibility:t}=e.style;let r=A!=="none"&&t!=="hidden"&&t!=="collapse";if(r){if(!e.ownerDocument.defaultView)return r;const{getComputedStyle:n}=e.ownerDocument.defaultView,{display:i,visibility:o}=n(e);r=i!=="none"&&o!=="hidden"&&o!=="collapse"}return r}function VT(e,A){return!e.hasAttribute("hidden")&&(e.nodeName==="DETAILS"&&A&&A.nodeName!=="SUMMARY"?e.hasAttribute("open"):!0)}function QM(e,A,t){const r=A?.tabbable?PT:bu,n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode(i){return A?.from?.contains(i)?NodeFilter.FILTER_REJECT:i.matches(r)&&Fu(i)&&(!A?.accept||A.accept(i))?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});return A?.from&&(n.currentNode=A.from),n}function pf(e){let A=e;for(;A&&!WT(A);)A=A.parentElement;return A||document.scrollingElement||document.documentElement}function WT(e){const A=window.getComputedStyle(e);return/(auto|scroll)/.test(A.overflow+A.overflowX+A.overflowY)}function ZT(){}function XT(e){return[e.clientX,e.clientY]}function BM(e,A){const[t,r]=e;let n=!1;const i=A.length;for(let o=i,g=0,Q=o-1;g=C&&r0&&(r===C?r>E&&(n=!n):n=!n)}}else if(aa&&r<=C){if(I===0)return!0;I<0&&(r===C?r=s&&t<=B||t>=B&&t<=s))return!0}return n}function OA(e,A){return H(e,A)}var fQ=new Map,kf=new Set;function yf(){if(typeof window>"u")return;const e=t=>{if(!t.target)return;let r=fQ.get(t.target);r||(r=new Set,fQ.set(t.target,r),t.target.addEventListener("transitioncancel",A)),r.add(t.propertyName)},A=t=>{if(!t.target)return;const r=fQ.get(t.target);if(r&&(r.delete(t.propertyName),r.size===0&&(t.target.removeEventListener("transitioncancel",A),fQ.delete(t.target)),fQ.size===0)){for(const n of kf)n();kf.clear()}};document.body.addEventListener("transitionrun",e),document.body.addEventListener("transitionend",A)}typeof document<"u"&&(document.readyState!=="loading"?yf():document.addEventListener("DOMContentLoaded",yf));function Sl(e,A){const t=Mf(e,A,"left"),r=Mf(e,A,"top"),n=A.offsetWidth,i=A.offsetHeight;let o=e.scrollLeft,g=e.scrollTop;const Q=o+e.offsetWidth,B=g+e.offsetHeight;t<=o?o=t:t+n>Q&&(o+=t+n-Q),r<=g?g=r:r+i>B&&(g+=r+i-B),e.scrollLeft=o,e.scrollTop=g}function Mf(e,A,t){const r=t==="left"?"offsetLeft":"offsetTop";let n=0;for(;A.offsetParent&&(n+=A[r],A.offsetParent!==e);){if(A.offsetParent.contains(e)){n-=e[r];break}A=A.offsetParent}return n}function $T(e,A){if(document.contains(e)){const t=document.scrollingElement||document.documentElement;if(window.getComputedStyle(t).overflow==="hidden"){let n=pf(e);for(;e&&n&&e!==t&&n!==t;)Sl(n,e),e=n,n=pf(e)}else{const{left:n,top:i}=e.getBoundingClientRect();e?.scrollIntoView?.({block:"nearest"});const{left:o,top:g}=e.getBoundingClientRect();(Math.abs(n-o)>1||Math.abs(i-g)>1)&&e.scrollIntoView?.({block:"nearest"})}}}var SB={border:"0",clip:"rect(0 0 0 0)","clip-path":"inset(50%)",height:"1px",margin:"0 -1px -1px 0",overflow:"hidden",padding:"0",position:"absolute",width:"1px","white-space":"nowrap"},BB="data-kb-top-layer",aM,Jl=!1,ni=[];function aB(e){return ni.findIndex(A=>A.node===e)}function AH(e){return ni[aB(e)]}function eH(e){return ni[ni.length-1].node===e}function sM(){return ni.filter(e=>e.isPointerBlocking)}function tH(){return[...sM()].slice(-1)[0]}function xu(){return sM().length>0}function EM(e){const A=aB(tH()?.node);return aB(e)e.onMountAutoFocus?.(I),g=I=>e.onUnmountAutoFocus?.(I),Q=()=>nr(A()),B=()=>{const I=Q().createElement("span");return I.setAttribute("data-focus-trap",""),I.tabIndex=0,Object.assign(I.style,SB),I},a=()=>{const I=A();return I?oM(I,!0).filter(c=>!c.hasAttribute("data-focus-trap")):[]},s=()=>{const I=a();return I.length>0?I[0]:null},C=()=>{const I=a();return I.length>0?I[I.length-1]:null},E=()=>{const I=A();if(!I)return!1;const c=GQ(I);return!c||bt(I,c)?!1:gM(c)};tA(()=>{const I=A();if(!I)return;vf.add(n);const c=GQ(I);if(!bt(I,c)){const h=new CustomEvent(dI,Nf);I.addEventListener(dI,o),I.dispatchEvent(h),h.defaultPrevented||setTimeout(()=>{At(s()),GQ(I)===c&&At(I)},0)}dA(()=>{I.removeEventListener(dI,o),setTimeout(()=>{const h=new CustomEvent(hI,Nf);E()&&h.preventDefault(),I.addEventListener(hI,g),I.dispatchEvent(h),h.defaultPrevented||At(c??Q().body),I.removeEventListener(hI,g),vf.remove(n)},0)})}),tA(()=>{const I=A();if(!I||!oA(e.trapFocus)||t())return;const c=h=>{const d=h.target;d?.closest(`[${BB}]`)||(bt(I,d)?i=d:At(i))},u=h=>{const f=h.relatedTarget??GQ(I);f?.closest(`[${BB}]`)||bt(I,f)||At(i)};Q().addEventListener("focusin",c),Q().addEventListener("focusout",u),dA(()=>{Q().removeEventListener("focusin",c),Q().removeEventListener("focusout",u)})}),tA(()=>{const I=A();if(!I||!oA(e.trapFocus)||t())return;const c=B();I.insertAdjacentElement("afterbegin",c);const u=B();I.insertAdjacentElement("beforeend",u);function h(f){const m=s(),k=C();f.relatedTarget===m?At(k):At(m)}c.addEventListener("focusin",h),u.addEventListener("focusin",h);const d=new MutationObserver(f=>{for(const m of f)m.previousSibling===u&&(u.remove(),I.insertAdjacentElement("beforeend",u)),m.nextSibling===c&&(c.remove(),I.insertAdjacentElement("afterbegin",c))});d.observe(I,{childList:!0,subtree:!1}),dA(()=>{c.removeEventListener("focusin",h),u.removeEventListener("focusin",h),c.remove(),u.remove(),d.disconnect()})})}var QH="data-live-announcer";function kE(e){tA(()=>{oA(e.isDisabled)||dA(BH(oA(e.targets),oA(e.root)))})}var wQ=new WeakMap,Mr=[];function BH(e,A=document.body){const t=new Set(e),r=new Set,n=Q=>{for(const C of Q.querySelectorAll(`[${QH}], [${BB}]`))t.add(C);const B=C=>{if(t.has(C)||C.parentElement&&r.has(C.parentElement)&&C.parentElement.getAttribute("role")!=="row")return NodeFilter.FILTER_REJECT;for(const E of t)if(C.contains(E))return NodeFilter.FILTER_SKIP;return NodeFilter.FILTER_ACCEPT},a=document.createTreeWalker(Q,NodeFilter.SHOW_ELEMENT,{acceptNode:B}),s=B(Q);if(s===NodeFilter.FILTER_ACCEPT&&i(Q),s!==NodeFilter.FILTER_REJECT){let C=a.nextNode();for(;C!=null;)i(C),C=a.nextNode()}},i=Q=>{const B=wQ.get(Q)??0;Q.getAttribute("aria-hidden")==="true"&&B===0||(B===0&&Q.setAttribute("aria-hidden","true"),r.add(Q),wQ.set(Q,B+1))};Mr.length&&Mr[Mr.length-1].disconnect(),n(A);const o=new MutationObserver(Q=>{for(const B of Q)if(!(B.type!=="childList"||B.addedNodes.length===0)&&![...t,...r].some(a=>a.contains(B.target))){for(const a of B.removedNodes)a instanceof Element&&(t.delete(a),r.delete(a));for(const a of B.addedNodes)(a instanceof HTMLElement||a instanceof SVGElement)&&(a.dataset.liveAnnouncer==="true"||a.dataset.reactAriaTopLayer==="true")?t.add(a):a instanceof Element&&n(a)}});o.observe(A,{childList:!0,subtree:!0});const g={observe(){o.observe(A,{childList:!0,subtree:!0})},disconnect(){o.disconnect()}};return Mr.push(g),()=>{o.disconnect();for(const Q of r){const B=wQ.get(Q);if(B==null)return;B===1?(Q.removeAttribute("aria-hidden"),wQ.delete(Q)):wQ.set(Q,B-1)}g===Mr[Mr.length-1]?(Mr.pop(),Mr.length&&Mr[Mr.length-1].observe()):Mr.splice(Mr.indexOf(g),1)}}var bf="interactOutside.pointerDownOutside",Ff="interactOutside.focusOutside";function aH(e,A){let t,r=ZT;const n=()=>nr(A()),i=s=>e.onPointerDownOutside?.(s),o=s=>e.onFocusOutside?.(s),g=s=>e.onInteractOutside?.(s),Q=s=>{const C=s.target;return!(C instanceof Element)||C.closest(`[${BB}]`)||!bt(n(),C)||bt(A(),C)?!1:!e.shouldExcludeElement?.(C)},B=s=>{function C(){const E=A(),I=s.target;if(!E||!I||!Q(s))return;const c=ge([i,g]);I.addEventListener(bf,c,{once:!0});const u=new CustomEvent(bf,{bubbles:!1,cancelable:!0,detail:{originalEvent:s,isContextMenu:s.button===2||qT(s)&&s.button===0}});I.dispatchEvent(u)}s.pointerType==="touch"?(n().removeEventListener("click",C),r=C,n().addEventListener("click",C,{once:!0})):C()},a=s=>{const C=A(),E=s.target;if(!C||!E||!Q(s))return;const I=ge([o,g]);E.addEventListener(Ff,I,{once:!0});const c=new CustomEvent(Ff,{bubbles:!1,cancelable:!0,detail:{originalEvent:s,isContextMenu:!1}});E.dispatchEvent(c)};tA(()=>{oA(e.isDisabled)||(t=window.setTimeout(()=>{n().addEventListener("pointerdown",B,!0)},0),n().addEventListener("focusin",a,!0),dA(()=>{window.clearTimeout(t),n().removeEventListener("click",r),n().removeEventListener("pointerdown",B,!0),n().removeEventListener("focusin",a,!0)}))})}function sH(e){const A=t=>{t.key===xB.Escape&&e.onEscapeKeyDown?.(t)};tA(()=>{if(oA(e.isDisabled))return;const t=e.ownerDocument?.()??nr();t.addEventListener("keydown",A),dA(()=>{t.removeEventListener("keydown",A)})})}function XA(e){const[A,t]=eA(e,["as"]);if(!A.as)throw new Error("[kobalte]: Polymorphic is missing the required `as` prop.");return l(Mn,H(t,{get component(){return A.as}}))}var CM=ye();function EH(){return pe(CM)}function JB(e){let A;const t=EH(),[r,n]=eA(e,["ref","disableOutsidePointerEvents","excludedElements","onEscapeKeyDown","onPointerDownOutside","onFocusOutside","onInteractOutside","onDismiss","bypassTopMostLayerCheck"]),i=new Set([]),o=s=>{i.add(s);const C=t?.registerNestedLayer(s);return()=>{i.delete(s),C?.()}};aH({shouldExcludeElement:s=>A?r.excludedElements?.some(C=>bt(C(),s))||[...i].some(C=>bt(C,s)):!1,onPointerDownOutside:s=>{!A||Cr.isBelowPointerBlockingLayer(A)||!r.bypassTopMostLayerCheck&&!Cr.isTopMostLayer(A)||(r.onPointerDownOutside?.(s),r.onInteractOutside?.(s),s.defaultPrevented||r.onDismiss?.())},onFocusOutside:s=>{r.onFocusOutside?.(s),r.onInteractOutside?.(s),s.defaultPrevented||r.onDismiss?.()}},()=>A),sH({ownerDocument:()=>nr(A),onEscapeKeyDown:s=>{!A||!Cr.isTopMostLayer(A)||(r.onEscapeKeyDown?.(s),!s.defaultPrevented&&r.onDismiss&&(s.preventDefault(),r.onDismiss()))}}),et(()=>{if(!A)return;Cr.addLayer({node:A,isPointerBlocking:r.disableOutsidePointerEvents,dismiss:r.onDismiss});const s=t?.registerNestedLayer(A);Cr.assignPointerEventToLayers(),Cr.disableBodyPointerEvents(A),dA(()=>{A&&(Cr.removeLayer(A),s?.(),Cr.assignPointerEventToLayers(),Cr.restoreBodyPointerEvents(A))})}),tA(be([()=>A,()=>r.disableOutsidePointerEvents],([s,C])=>{if(!s)return;const E=Cr.find(s);E&&E.isPointerBlocking!==C&&(E.isPointerBlocking=C,Cr.assignPointerEventToLayers()),C&&Cr.disableBodyPointerEvents(s),dA(()=>{Cr.restoreBodyPointerEvents(s)})},{defer:!0}));const a={registerNestedLayer:o};return l(CM.Provider,{value:a,get children(){return l(XA,H({as:"div",ref(s){var C=ae(E=>A=E,r.ref);typeof C=="function"&&C(s)}},n))}})}function Po(e){const[A,t]=gA(e.defaultValue?.()),r=S(()=>e.value?.()!==void 0),n=S(()=>r()?e.value?.():A());return[n,o=>{fe(()=>{const g=MT(o,n());return Object.is(g,n())||(r()||t(g),e.onChange?.(g)),g})}]}function IM(e){const[A,t]=Po(e);return[()=>A()??!1,t]}function CH(e){const[A,t]=Po(e);return[()=>A()??[],t]}function _o(e={}){const[A,t]=IM({value:()=>oA(e.open),defaultValue:()=>!!oA(e.defaultOpen),onChange:o=>e.onOpenChange?.(o)}),r=()=>{t(!0)},n=()=>{t(!1)};return{isOpen:A,setIsOpen:t,open:r,close:n,toggle:()=>{A()?n():r()}}}function yE(e,A){const[t,r]=gA(xf(A?.()));return tA(()=>{r(e()?.tagName.toLowerCase()||xf(A?.()))}),t}function xf(e){return ug(e)?e:void 0}var IH=Object.defineProperty,Zt=(e,A)=>{for(var t in A)IH(e,t,{get:A[t],enumerable:!0})},lH={};Zt(lH,{Button:()=>Gu,Root:()=>Fn});var cH=["button","color","file","image","reset","submit"];function uH(e){const A=e.tagName.toLowerCase();return A==="button"?!0:A==="input"&&e.type?cH.indexOf(e.type)!==-1:!1}function Fn(e){let A;const t=OA({type:"button"},e),[r,n]=eA(t,["ref","type","disabled"]),i=yE(()=>A,()=>"button"),o=S(()=>{const B=i();return B==null?!1:uH({tagName:B,type:r.type})}),g=S(()=>i()==="input"),Q=S(()=>i()==="a"&&A?.getAttribute("href")!=null);return l(XA,H({as:"button",ref(B){var a=ae(s=>A=s,r.ref);typeof a=="function"&&a(B)},get type(){return Ae(()=>!!(o()||g()))()?r.type:void 0},get role(){return!o()&&!Q()?"button":void 0},get tabIndex(){return!o()&&!Q()&&!r.disabled?0:void 0},get disabled(){return Ae(()=>!!(o()||g()))()?r.disabled:void 0},get"aria-disabled"(){return!o()&&!g()&&r.disabled?!0:void 0},get"data-disabled"(){return r.disabled?"":void 0}},n))}var Gu=Fn;function ze(e){return A=>(e(A),()=>e(void 0))}var _e=e=>typeof e=="function"?e():e,Ul=(e,A)=>{if(e.contains(A))return!0;let t=A;for(;t;){if(t===e)return!0;t=t._$host??t.parentElement}return!1},Sa=new Map,dH=e=>{tA(()=>{const A=_e(e.style)??{},t=_e(e.properties)??[],r={};for(const i in A)r[i]=e.element.style[i];const n=Sa.get(e.key);n?n.activeCount++:Sa.set(e.key,{activeCount:1,originalStyles:r,properties:t.map(i=>i.key)}),Object.assign(e.element.style,e.style);for(const i of t)e.element.style.setProperty(i.key,i.value);dA(()=>{const i=Sa.get(e.key);if(i){if(i.activeCount!==1){i.activeCount--;return}Sa.delete(e.key);for(const[o,g]of Object.entries(i.originalStyles))e.element.style[o]=g;for(const o of i.properties)e.element.style.removeProperty(o);e.element.style.length===0&&e.element.removeAttribute("style"),e.cleanup?.()}})})},Gf=dH,hH=(e,A)=>{switch(A){case"x":return[e.clientWidth,e.scrollLeft,e.scrollWidth];case"y":return[e.clientHeight,e.scrollTop,e.scrollHeight]}},DH=(e,A)=>{const t=getComputedStyle(e),r=A==="x"?t.overflowX:t.overflowY;return r==="auto"||r==="scroll"||e.tagName==="HTML"&&r==="visible"},fH=(e,A,t)=>{const r=A==="x"&&window.getComputedStyle(e).direction==="rtl"?-1:1;let n=e,i=0,o=0,g=!1;do{const[Q,B,a]=hH(n,A),s=a-Q-r*B;(B!==0||s!==0)&&DH(n,A)&&(i+=s,o+=B),n===(t??document.documentElement)?g=!0:n=n._$host??n.parentElement}while(n&&!g);return[i,o]},[Sf,Jf]=gA([]),wH=e=>Sf().indexOf(e)===Sf().length-1,mH=e=>{const A=H({element:null,enabled:!0,hideScrollbar:!0,preventScrollbarShift:!0,preventScrollbarShiftMode:"padding",restoreScrollPosition:!0,allowPinchZoom:!1},e),t=je();let r=[0,0],n=null,i=null;tA(()=>{_e(A.enabled)&&(Jf(B=>[...B,t]),dA(()=>{Jf(B=>B.filter(a=>a!==t))}))}),tA(()=>{if(!_e(A.enabled)||!_e(A.hideScrollbar))return;const{body:B}=document,a=window.innerWidth-B.offsetWidth;if(_e(A.preventScrollbarShift)){const s={overflow:"hidden"},C=[];a>0&&(_e(A.preventScrollbarShiftMode)==="padding"?s.paddingRight=`calc(${window.getComputedStyle(B).paddingRight} + ${a}px)`:s.marginRight=`calc(${window.getComputedStyle(B).marginRight} + ${a}px)`,C.push({key:"--scrollbar-width",value:`${a}px`}));const E=window.scrollY,I=window.scrollX;Gf({key:"prevent-scroll",element:B,style:s,properties:C,cleanup:()=>{_e(A.restoreScrollPosition)&&a>0&&window.scrollTo(I,E)}})}else Gf({key:"prevent-scroll",element:B,style:{overflow:"hidden"}})}),tA(()=>{!wH(t)||!_e(A.enabled)||(document.addEventListener("wheel",g,{passive:!1}),document.addEventListener("touchstart",o,{passive:!1}),document.addEventListener("touchmove",Q,{passive:!1}),dA(()=>{document.removeEventListener("wheel",g),document.removeEventListener("touchstart",o),document.removeEventListener("touchmove",Q)}))});const o=B=>{r=Uf(B),n=null,i=null},g=B=>{const a=B.target,s=_e(A.element),C=pH(B),E=Math.abs(C[0])>Math.abs(C[1])?"x":"y",I=E==="x"?C[0]:C[1],c=Kf(a,E,I,s);let u;s&&Ul(s,a)?u=!c:u=!0,u&&B.cancelable&&B.preventDefault()},Q=B=>{const a=_e(A.element),s=B.target;let C;if(B.touches.length===2)C=!_e(A.allowPinchZoom);else{if(n==null||i===null){const E=Uf(B).map((c,u)=>r[u]-c),I=Math.abs(E[0])>Math.abs(E[1])?"x":"y";n=I,i=I==="x"?E[0]:E[1]}if(s.type==="range")C=!1;else{const E=Kf(s,n,i,a);a&&Ul(a,s)?C=!E:C=!0}}C&&B.cancelable&&B.preventDefault()}},pH=e=>[e.deltaX,e.deltaY],Uf=e=>e.changedTouches[0]?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0],Kf=(e,A,t,r)=>{const n=r!==null&&Ul(r,e),[i,o]=fH(e,A,n?r:void 0);return!(t>0&&Math.abs(i)<=1||t<0&&Math.abs(o)<1)},kH=mH,ME=kH,yH=e=>{const A=S(()=>{const o=_e(e.element);if(o)return getComputedStyle(o)}),t=()=>A()?.animationName??"none",[r,n]=gA(_e(e.show)?"present":"hidden");let i="none";return tA(o=>{const g=_e(e.show);return fe(()=>{if(o===g)return g;const Q=i,B=t();g?n("present"):B==="none"||A()?.display==="none"?n("hidden"):n(o===!0&&Q!==B?"hiding":"hidden")}),g}),tA(()=>{const o=_e(e.element);if(!o)return;const g=B=>{B.target===o&&(i=t())},Q=B=>{const s=t().includes(B.animationName);B.target===o&&s&&r()==="hiding"&&n("hidden")};o.addEventListener("animationstart",g),o.addEventListener("animationcancel",Q),o.addEventListener("animationend",Q),dA(()=>{o.removeEventListener("animationstart",g),o.removeEventListener("animationcancel",Q),o.removeEventListener("animationend",Q)})}),{present:()=>r()==="present"||r()==="hiding",state:r,setState:n}},MH=yH,en=MH,NH={};Zt(NH,{CloseButton:()=>cM,Content:()=>uM,Description:()=>dM,Dialog:()=>hn,Overlay:()=>hM,Portal:()=>DM,Root:()=>fM,Title:()=>wM,Trigger:()=>mM,useDialogContext:()=>Wi});var lM=ye();function Wi(){const e=pe(lM);if(e===void 0)throw new Error("[kobalte]: `useDialogContext` must be used within a `Dialog` component");return e}function cM(e){const A=Wi(),[t,r]=eA(e,["aria-label","onClick"]);return l(Fn,H({get"aria-label"(){return t["aria-label"]||A.translations().dismiss},onClick:i=>{WA(i,t.onClick),A.close()}},r))}function uM(e){let A;const t=Wi(),r=OA({id:t.generateId("content")},e),[n,i]=eA(r,["ref","onOpenAutoFocus","onCloseAutoFocus","onPointerDownOutside","onFocusOutside","onInteractOutside"]);let o=!1,g=!1;const Q=C=>{n.onPointerDownOutside?.(C),t.modal()&&C.detail.isContextMenu&&C.preventDefault()},B=C=>{n.onFocusOutside?.(C),t.modal()&&C.preventDefault()},a=C=>{n.onInteractOutside?.(C),!t.modal()&&(C.defaultPrevented||(o=!0,C.detail.originalEvent.type==="pointerdown"&&(g=!0)),bt(t.triggerRef(),C.target)&&C.preventDefault(),C.detail.originalEvent.type==="focusin"&&g&&C.preventDefault())},s=C=>{n.onCloseAutoFocus?.(C),t.modal()?(C.preventDefault(),At(t.triggerRef())):(C.defaultPrevented||(o||At(t.triggerRef()),C.preventDefault()),o=!1,g=!1)};return kE({isDisabled:()=>!(t.isOpen()&&t.modal()),targets:()=>A?[A]:[]}),ME({element:()=>A??null,enabled:()=>t.contentPresent()&&t.preventScroll()}),pE({trapFocus:()=>t.isOpen()&&t.modal(),onMountAutoFocus:n.onOpenAutoFocus,onUnmountAutoFocus:s},()=>A),tA(()=>dA(t.registerContentId(i.id))),l(Y,{get when(){return t.contentPresent()},get children(){return l(JB,H({ref(C){var E=ae(I=>{t.setContentRef(I),A=I},n.ref);typeof E=="function"&&E(C)},role:"dialog",tabIndex:-1,get disableOutsidePointerEvents(){return Ae(()=>!!t.modal())()&&t.isOpen()},get excludedElements(){return[t.triggerRef]},get"aria-labelledby"(){return t.titleId()},get"aria-describedby"(){return t.descriptionId()},get"data-expanded"(){return t.isOpen()?"":void 0},get"data-closed"(){return t.isOpen()?void 0:""},onPointerDownOutside:Q,onFocusOutside:B,onInteractOutside:a,get onDismiss(){return t.close}},i))}})}function dM(e){const A=Wi(),t=OA({id:A.generateId("description")},e),[r,n]=eA(t,["id"]);return tA(()=>dA(A.registerDescriptionId(r.id))),l(XA,H({as:"p",get id(){return r.id}},n))}function hM(e){const A=Wi(),[t,r]=eA(e,["ref","style","onPointerDown"]),n=i=>{WA(i,t.onPointerDown),i.target===i.currentTarget&&i.preventDefault()};return l(Y,{get when(){return A.overlayPresent()},get children(){return l(XA,H({as:"div",ref(i){var o=ae(A.setOverlayRef,t.ref);typeof o=="function"&&o(i)},get style(){return Tt({"pointer-events":"auto"},t.style)},get"data-expanded"(){return A.isOpen()?"":void 0},get"data-closed"(){return A.isOpen()?void 0:""},onPointerDown:n},r))}})}function DM(e){const A=Wi();return l(Y,{get when(){return A.contentPresent()||A.overlayPresent()},get children(){return l(qo,e)}})}var Lf={dismiss:"Dismiss"};function fM(e){const A=`dialog-${je()}`,t=OA({id:A,modal:!0,translations:Lf},e),[r,n]=gA(),[i,o]=gA(),[g,Q]=gA(),[B,a]=gA(),[s,C]=gA(),[E,I]=gA(),c=_o({open:()=>t.open,defaultOpen:()=>t.defaultOpen,onOpenChange:m=>t.onOpenChange?.(m)}),u=()=>t.forceMount||c.isOpen(),{present:h}=en({show:u,element:()=>B()??null}),{present:d}=en({show:u,element:()=>s()??null}),f={translations:()=>t.translations??Lf,isOpen:c.isOpen,modal:()=>t.modal??!0,preventScroll:()=>t.preventScroll??f.modal(),contentId:r,titleId:i,descriptionId:g,triggerRef:E,overlayRef:B,setOverlayRef:a,contentRef:s,setContentRef:C,overlayPresent:h,contentPresent:d,close:c.close,toggle:c.toggle,setTriggerRef:I,generateId:Gt(()=>t.id),registerContentId:ze(n),registerTitleId:ze(o),registerDescriptionId:ze(Q)};return l(lM.Provider,{value:f,get children(){return t.children}})}function wM(e){const A=Wi(),t=OA({id:A.generateId("title")},e),[r,n]=eA(t,["id"]);return tA(()=>dA(A.registerTitleId(r.id))),l(XA,H({as:"h2",get id(){return r.id}},n))}function mM(e){const A=Wi(),[t,r]=eA(e,["ref","onClick"]);return l(Fn,H({ref(i){var o=ae(A.setTriggerRef,t.ref);typeof o=="function"&&o(i)},"aria-haspopup":"dialog",get"aria-expanded"(){return A.isOpen()},get"aria-controls"(){return Ae(()=>!!A.isOpen())()?A.contentId():void 0},get"data-expanded"(){return A.isOpen()?"":void 0},get"data-closed"(){return A.isOpen()?void 0:""},onClick:i=>{WA(i,t.onClick),A.toggle()}},r))}var hn=Object.assign(fM,{CloseButton:cM,Content:uM,Description:dM,Overlay:hM,Portal:DM,Title:wM,Trigger:mM}),vH=J("
    ");const pM=ye();function bH(){const[e,A]=gA(),t={get active(){return e()},close(){e()?.onClose?.(),A(void 0)},show(r,n,i){e()?.onClose?.();const o=Math.random().toString(36).slice(2);A({id:o,element:()=>DB(n,()=>l(Y,{get when(){return e()?.id===o},get children(){return l(hn,{modal:!0,open:!0,onOpenChange:g=>{g||t.close()},get children(){return l(hn.Portal,{get children(){return[l(hn.Overlay,{"data-component":"dialog-overlay"}),Ae(()=>r())]}})}})}})),onClose:i,owner:n})}};return t}function FH(e){const A=bH();return l(pM.Provider,{value:A,get children(){return[Ae(()=>e.children),(()=>{var t=vH();return M(t,()=>A.active?.element?.()),t})()]}})}function Ht(){const e=pe(pM),A=iE();if(!A)throw new Error("useDialog must be used within a DialogProvider");if(!e)throw new Error("useDialog must be used within a DialogProvider");return{get active(){return e.active},show(t,r){e.show(t,A,r)},close(){e.close()}}}class kM extends Set{emit(A){for(const t of this)t(A)}}function xH(){const e=new kM;return{listen(A){return e.add(A),Mu(e.delete.bind(e,A))},emit:e.emit.bind(e),clear:dA(e.clear.bind(e))}}class GH extends Map{on(A,t){let r=this.get(A);r||this.set(A,r=new kM),r.add(t)}off(A,t){const r=this.get(A);r?.delete(t)&&!r.size&&this.delete(A)}emit(A,t){this.get(A)?.emit(t)}}function SH(){const e=new GH;return{on(A,t){return e.on(A,t),Mu(e.off.bind(e,A,t))},emit:e.emit.bind(e),clear:dA(e.clear.bind(e))}}function yM(){const e=SH(),A=xH();return{on:e.on,clear:e.clear,listen:A.listen,emit(t,r){A.emit({name:t,details:r}),e.emit(t,r)}}}const{use:Bn,provider:JH}=qt({name:"Platform",init:e=>e.value});function UH(e,A={}){const t=A.storage||globalThis.localStorage,r=A.name||`storage-${je()}`;if(!t)return[e[0],e[1],null];const n=A.storageOptions,i=A.serialize||JSON.stringify.bind(JSON),o=A.deserialize||JSON.parse.bind(JSON),g=t.getItem(r,n),Q=typeof e[0]=="function"?a=>{try{const s=o(a);e[1](()=>s)}catch{}}:a=>{try{const s=o(a);e[1](Ut(s))}catch{}};let B=!0;if(g instanceof Promise?g.then(a=>B&&a&&Q(a)):g&&Q(g),typeof A.sync?.[0]=="function"){const a=typeof e[0]=="function"?e[0]:()=>e[0];A.sync[0](s=>{s.key!==r||(s.url||globalThis.location.href)!==globalThis.location.href||s.newValue===i(fe(a))||Q(s.newValue)})}return[e[0],typeof e[0]=="function"?a=>{const s=e[1](a),C=a!=null?i(s):a;return A.sync?.[1](r,C),C!=null?t.setItem(r,C,n):t.removeItem(r,n),B=!1,s}:(...a)=>{e[1](...a);const s=i(fe(()=>e[0]));A.sync?.[1](r,s),t.setItem(r,s,n),B=!1},g]}function ii(e,A){const t=Bn(),[r,n,i]=UH(A,{name:e,storage:t.storage?.()??localStorage}),o=i instanceof Promise,[g]=Ji(()=>i,async Q=>(Q instanceof Promise&&await Q,!0),{initialValue:!o});return[r,n,i,()=>g()===!0]}function Eo(e){const A=e.trim();return A?(/^https?:\/\//.test(A)?A:`http://${A}`).replace(/\/+$/,"").replace(/^(https?:\/\/[^/]+).*/,"$1"):void 0}function MM(e){return e?e.replace(/^https?:\/\//,"").replace(/\/+$/,"").split("/")[0]:""}function KH(e){if(!e)return"";const A=e.replace(/^https?:\/\//,"").split(":")[0];return A==="localhost"||A==="127.0.0.1"?"local":e}const{use:jo,provider:LH}=qt({name:"Server",init:e=>{const A=Bn(),[t,r,n,i]=ii("server.v3",xe({list:[],projects:{}})),[o,g]=gA("");function Q(h){const d=Eo(h);d&&g(d)}function B(h){const d=Eo(h);if(!d)return;const f=Eo(e.defaultUrl);if(f&&d===f){g(d);return}st(()=>{t.list.includes(d)||r("list",t.list.length,d),g(d)})}function a(h){const d=Eo(h);if(!d)return;const f=t.list.filter(k=>k!==d),m=o()===d?f[0]??Eo(e.defaultUrl)??"":o();st(()=>{r("list",f),g(m)})}tA(()=>{if(!i()||o())return;const h=Eo(e.defaultUrl);h&&g(h)});const s=S(()=>i()&&!!o()),[C,{refetch:E}]=Ji(()=>o()||void 0,async h=>h?So({baseUrl:h,fetch:A.fetch,signal:AbortSignal.timeout(2e3)}).global.health().then(f=>f.data?.healthy===!0).catch(()=>!1):void 0);tA(()=>{if(!o())return;const h=setInterval(()=>E(),1e4);dA(()=>clearInterval(h))});const I=S(()=>KH(o())),c=S(()=>t.projects[I()]??[]),u=S(()=>I()==="local");return{ready:s,healthy:C,isLocal:u,get url(){return o()},get name(){return MM(o())},get list(){return t.list},setActive:Q,add:B,remove:a,projects:{list:c,open(h){const d=I();if(!d)return;const f=t.projects[d]??[];f.find(m=>m.worktree===h)||r("projects",d,[{worktree:h,expanded:!0},...f])},close(h){const d=I();if(!d)return;const f=t.projects[d]??[];r("projects",d,f.filter(m=>m.worktree!==h))},expand(h){const d=I();if(!d)return;const m=(t.projects[d]??[]).findIndex(k=>k.worktree===h);m!==-1&&r("projects",d,m,"expanded",!0)},collapse(h){const d=I();if(!d)return;const m=(t.projects[d]??[]).findIndex(k=>k.worktree===h);m!==-1&&r("projects",d,m,"expanded",!1)},move(h,d){const f=I();if(!f)return;const m=t.projects[f]??[],k=m.findIndex(L=>L.worktree===h);if(k===-1||k===d)return;const N=[...m],[F]=N.splice(k,1);N.splice(d,0,F),r("projects",f,N)}}}}}),{use:xn,provider:RH}=qt({name:"GlobalSDK",init:()=>{const e=jo(),A=new AbortController,t=So({baseUrl:e.url,signal:A.signal}),r=yM();(async()=>{const o=await t.global.event();for await(const g of o.stream)r.emit(g.directory??"global",g.payload)})().catch(()=>{}),dA(()=>A.abort());const n=Bn(),i=So({baseUrl:e.url,signal:AbortSignal.timeout(1e3*60*10),fetch:n.fetch,throwOnError:!0});return{url:e.url,client:i,event:r}}});var UB=["id","name","validationState","required","disabled","readOnly"];function KB(e){const A=`form-control-${je()}`,t=OA({id:A},e),[r,n]=gA(),[i,o]=gA(),[g,Q]=gA(),[B,a]=gA(),s=(c,u,h)=>{const d=h!=null||r()!=null;return[h,r(),d&&u!=null?c:void 0].filter(Boolean).join(" ")||void 0},C=c=>[g(),B(),c].filter(Boolean).join(" ")||void 0,E=S(()=>({"data-valid":oA(t.validationState)==="valid"?"":void 0,"data-invalid":oA(t.validationState)==="invalid"?"":void 0,"data-required":oA(t.required)?"":void 0,"data-disabled":oA(t.disabled)?"":void 0,"data-readonly":oA(t.readOnly)?"":void 0}));return{formControlContext:{name:()=>oA(t.name)??oA(t.id),dataset:E,validationState:()=>oA(t.validationState),isRequired:()=>oA(t.required),isDisabled:()=>oA(t.disabled),isReadOnly:()=>oA(t.readOnly),labelId:r,fieldId:i,descriptionId:g,errorMessageId:B,getAriaLabelledBy:s,getAriaDescribedBy:C,generateId:Gt(()=>oA(t.id)),registerLabel:ze(n),registerField:ze(o),registerDescription:ze(Q),registerErrorMessage:ze(a)}}}var $g=ye();function Xt(){const e=pe($g);if(e===void 0)throw new Error("[kobalte]: `useFormControlContext` must be used within a `FormControlContext.Provider` component");return e}function Bi(e){const A=Xt(),t=OA({id:A.generateId("description")},e);return tA(()=>dA(A.registerDescription(t.id))),l(XA,H({as:"div"},()=>A.dataset(),t))}var NE=["id","aria-label","aria-labelledby","aria-describedby"];function vE(e){const A=Xt(),t=OA({id:A.generateId("field")},e);return tA(()=>dA(A.registerField(oA(t.id)))),{fieldProps:{id:()=>oA(t.id),ariaLabel:()=>oA(t["aria-label"]),ariaLabelledBy:()=>A.getAriaLabelledBy(oA(t.id),oA(t["aria-label"]),oA(t["aria-labelledby"])),ariaDescribedBy:()=>A.getAriaDescribedBy(oA(t["aria-describedby"]))}}}function AQ(e){let A;const t=Xt(),r=OA({id:t.generateId("label")},e),[n,i]=eA(r,["ref"]),o=yE(()=>A,()=>"label");return tA(()=>dA(t.registerLabel(i.id))),l(XA,H({as:"label",ref(g){var Q=ae(B=>A=B,n.ref);typeof Q=="function"&&Q(g)},get for(){return Ae(()=>o()==="label")()?t.fieldId():void 0}},()=>t.dataset(),i))}function eQ(e,A){tA(be(e,t=>{if(t==null)return;const r=OH(t);r!=null&&(r.addEventListener("reset",A,{passive:!0}),dA(()=>{r.removeEventListener("reset",A)}))}))}function OH(e){return qH(e)?e.form:e.closest("form")}function qH(e){return e.matches("textarea, input, select, button")}function ai(e){const A=Xt(),t=OA({id:A.generateId("error-message")},e),[r,n]=eA(t,["forceMount"]),i=()=>A.validationState()==="invalid";return tA(()=>{i()&&dA(A.registerErrorMessage(n.id))}),l(Y,{get when(){return r.forceMount||i()},get children(){return l(XA,H({as:"div"},()=>A.dataset(),n))}})}var TH={};Zt(TH,{Description:()=>Bi,ErrorMessage:()=>ai,Input:()=>vM,Label:()=>AQ,Root:()=>FM,TextArea:()=>xM,TextField:()=>Co,useTextFieldContext:()=>Su});var NM=ye();function Su(){const e=pe(NM);if(e===void 0)throw new Error("[kobalte]: `useTextFieldContext` must be used within a `TextField` component");return e}function vM(e){return l(bM,H({type:"text"},e))}function bM(e){const A=Xt(),t=Su(),r=OA({id:t.generateId("input")},e),[n,i,o]=eA(r,["onInput"],NE),{fieldProps:g}=vE(i);return l(XA,H({as:"input",get id(){return g.id()},get name(){return A.name()},get value(){return t.value()},get required(){return A.isRequired()},get disabled(){return A.isDisabled()},get readonly(){return A.isReadOnly()},get"aria-label"(){return g.ariaLabel()},get"aria-labelledby"(){return g.ariaLabelledBy()},get"aria-describedby"(){return g.ariaDescribedBy()},get"aria-invalid"(){return A.validationState()==="invalid"||void 0},get"aria-required"(){return A.isRequired()||void 0},get"aria-disabled"(){return A.isDisabled()||void 0},get"aria-readonly"(){return A.isReadOnly()||void 0},get onInput(){return ge([n.onInput,t.onInput])}},()=>A.dataset(),o))}function FM(e){let A;const t=`textfield-${je()}`,r=OA({id:t},e),[n,i,o]=eA(r,["ref","value","defaultValue","onChange"],UB),g=n.value,[Q,B]=Po({value:()=>g===void 0?void 0:n.value??"",defaultValue:()=>n.defaultValue,onChange:E=>n.onChange?.(E)}),{formControlContext:a}=KB(i);eQ(()=>A,()=>B(n.defaultValue??""));const s=E=>{if(a.isReadOnly()||a.isDisabled())return;const I=E.target;B(I.value),I.value=Q()??""},C={value:Q,generateId:Gt(()=>oA(i.id)),onInput:s};return l($g.Provider,{value:a,get children(){return l(NM.Provider,{value:C,get children(){return l(XA,H({as:"div",ref(E){var I=ae(c=>A=c,n.ref);typeof I=="function"&&I(E)},role:"group",get id(){return oA(i.id)}},()=>a.dataset(),o))}})}})}function xM(e){let A;const t=Su(),r=OA({id:t.generateId("textarea")},e),[n,i]=eA(r,["ref","autoResize","submitOnEnter","onKeyPress"]);tA(be([()=>A,()=>n.autoResize,()=>t.value()],([g,Q])=>{!g||!Q||HH(g)}));const o=g=>{A&&n.submitOnEnter&&g.key==="Enter"&&!g.shiftKey&&A.form&&(A.form.requestSubmit(),g.preventDefault())};return l(bM,H({as:"textarea",get"aria-multiline"(){return n.submitOnEnter?"false":void 0},get onKeyPress(){return ge([n.onKeyPress,o])},ref(g){var Q=ae(B=>A=B,n.ref);typeof Q=="function"&&Q(g)}},i))}function HH(e){const A=e.style.alignSelf,t=e.style.overflow;"MozAppearance"in e.style||(e.style.overflow="hidden"),e.style.alignSelf="start",e.style.height="auto",e.style.height=`${e.scrollHeight+(e.offsetHeight-e.clientHeight)}px`,e.style.overflow=t,e.style.alignSelf=A}var Co=Object.assign(FM,{Description:Bi,ErrorMessage:ai,Input:vM,Label:AQ,TextArea:xM}),YH=J('
    ");function hr(e){const[A,t]=eA(e,["title","keybind"]);return l(Ar,H(t,{get value(){return(()=>{var r=Q7(),n=r.firstChild,i=n.nextSibling;return M(n,()=>A.title),M(i,()=>A.keybind),r})()}}))}function Ar(e){const[A,t]=gA(!1),[r,n]=eA(e,["children","class","inactive"]),i=ji(()=>r.children);return et(()=>{const o=i();if(o instanceof HTMLElement)o.addEventListener("focus",()=>t(!0)),o.addEventListener("blur",()=>t(!1));else if(Array.isArray(o))for(const g of o)g instanceof HTMLElement&&(g.addEventListener("focus",()=>t(!0)),g.addEventListener("blur",()=>t(!1)))}),l(Je,{get children(){return[l(YA,{get when(){return r.inactive},get children(){return r.children}}),l(YA,{when:!0,get children(){return l(Pn,H({forceMount:!0,gutter:4},n,{get open(){return A()},onOpenChange:t,get children(){return[l(Pn.Trigger,{as:"div","data-component":"tooltip-trigger",get class(){return r.class},get children(){return i()}}),l(Pn.Portal,{get children(){return l(Pn.Content,{"data-component":"tooltip",get"data-placement"(){return e.placement},get children(){return n.value}})}})]}}))}})]}})}var B7=J("
    ");function Ki(e){const[A,t]=eA(e,["name","defaultValue","value","onChange","onKeyDown","validationState","required","disabled","readOnly","class","label","hideLabel","description","error","variant","copyable","multiline"]),[r,n]=gA(!1);async function i(){const g=A.value??A.defaultValue??"";await navigator.clipboard.writeText(g),n(!0),setTimeout(()=>n(!1),2e3)}function o(){A.copyable&&i()}return l(Co,{"data-component":"input",get"data-variant"(){return A.variant||"normal"},get name(){return A.name},get defaultValue(){return A.defaultValue},get value(){return A.value},get onChange(){return A.onChange},get onKeyDown(){return A.onKeyDown},onClick:o,get required(){return A.required},get disabled(){return A.disabled},get readOnly(){return A.readOnly},get validationState(){return A.validationState},get children(){return[l(Y,{get when(){return A.label},get children(){return l(Co.Label,{"data-slot":"input-label",get classList(){return{"sr-only":A.hideLabel}},get children(){return A.label}})}}),(()=>{var g=B7();return M(g,l(Y,{get when(){return A.multiline},get fallback(){return l(Co.Input,H(t,{"data-slot":"input-input",get class(){return A.class}}))},get children(){return l(Co.TextArea,H(t,{autoResize:!0,"data-slot":"input-input",get class(){return A.class}}))}}),null),M(g,l(Y,{get when(){return A.copyable},get children(){return l(Ar,{get value(){return r()?"Copied":"Copy to clipboard"},placement:"top",gutter:8,get children(){return l(Ot,{type:"button",get icon(){return r()?"check":"copy"},variant:"ghost",onClick:i,"data-slot":"input-copy-button"})}})}}),null),g})(),l(Y,{get when(){return A.description},get children(){return l(Co.Description,{"data-slot":"input-description",get children(){return A.description}})}}),l(Co.ErrorMessage,{"data-slot":"input-error",get children(){return A.error}})]}})}var a7=J(''),s7=J('');const E7=e=>(()=>{var A=a7();return _A(t=>qe(A,{[e.class??""]:!!e.class},t)),A})(),ZM=e=>(()=>{var A=s7();return _A(t=>qe(A,{[e.class??""]:!!e.class},t)),A})();function ue(e){const[A,t]=eA(e,["variant","size","icon","class","classList"]);return l(Gu,H(t,{"data-component":"button",get"data-size"(){return A.size||"normal"},get"data-variant"(){return A.variant||"secondary"},get"data-icon"(){return A.icon},get classList(){return{...A.classList??{},[A.class??""]:!!A.class}},get children(){return[l(Y,{get when(){return A.icon},get children(){return l(Ee,{get name(){return A.icon},size:"small"})}}),Ae(()=>e.children)]}}))}var C7=J('

    Version: '),I7=J('

    Something went wrong

    An error occurred while loading the application.

    Please report this error to the OpenCode team
    '),leA=J('
    '),ceA=J('
    StopESC'),ueA=J('
    Send');const fF=["image/png","image/jpeg","image/gif","image/webp"],LI=[...fF,"application/pdf"],RI=["Fix a TODO in the codebase","What is the tech stack of this project?","Fix broken tests","Explain how authentication works","Find and fix security vulnerabilities","Add unit tests for the user service","Refactor this function to be more readable","What does this error mean?","Help me debug this issue","Generate API documentation","Optimize database queries","Add input validation","Create a new component for...","How do I deploy this project?","Review my code for best practices","Add error handling to this function","Explain this regex pattern","Convert this to TypeScript","Add logging throughout the codebase","What dependencies are outdated?","Help me write a migration script","Implement caching for this endpoint","Add pagination to this list","Create a CLI command for...","How do environment variables work here?"],Bm=e=>{const A=To(),t=Xi(),r=Ii(),n=sQ(),i=C1(),o=nQ(),g=Qn(),Q=Ht(),B=jB(),a=JE(),s=Yu();let C,E,I;const c=()=>{const R=I,QA=window.getSelection();if(!R||!QA||QA.rangeCount===0)return;const hA=QA.getRangeAt(0);if(!C.contains(hA.startContainer))return;const uA=hA.getBoundingClientRect();if(!uA.height)return;const CA=R.getBoundingClientRect(),qA=uA.top-CA.top+R.scrollTop,jA=uA.bottom-CA.top+R.scrollTop,vA=12;if(qAR.scrollTop+R.clientHeight-vA&&(R.scrollTop=jA-R.clientHeight+vA)},u=()=>{requestAnimationFrame(c)},h=S(()=>`${g.dir}${g.id?"/"+g.id:""}`),d=S(()=>o.tabs(h())),f=S(()=>g.id?r.session.get(g.id):void 0),m=S(()=>r.data.session_status[g.id??""]??{type:"idle"}),k=S(()=>m()?.type!=="idle"),[N,F]=xe({popover:null,historyIndex:-1,savedPrompt:null,placeholder:Math.floor(Math.random()*RI.length),dragging:!1,imageAttachments:[],mode:"normal",applyingHistory:!1,killBuffer:""}),L=100,[v,O]=ii("prompt-history.v1",xe({entries:[]})),[W,AA]=ii("prompt-history-shell.v1",xe({entries:[]})),kA=R=>R.map(QA=>QA.type==="text"?{...QA}:QA.type==="image"?{...QA}:QA.type==="agent"?{...QA}:{...QA,selection:QA.selection?{...QA.selection}:void 0}),K=R=>R.reduce((QA,hA)=>QA+("content"in hA?hA.content.length:0),0),$=(R,QA)=>{const hA=QA==="start"?0:K(R);F("applyingHistory",!0),i.set(R,hA),requestAnimationFrame(()=>{C.focus(),wi(C,hA),F("applyingHistory",!1),u()})},P=()=>{const R=window.getSelection(),QA=K(i.current());if(!R||R.rangeCount===0)return{collapsed:!1,cursorPosition:0,textLength:QA};const hA=R.anchorNode;return!hA||!C.contains(hA)?{collapsed:!1,cursorPosition:0,textLength:QA}:{collapsed:R.isCollapsed,cursorPosition:Cg(C),textLength:QA}};tA(()=>{if(g.id,C.focus(),g.id)return;const R=setInterval(()=>{F("placeholder",QA=>(QA+1)%RI.length)},6500);dA(()=>clearInterval(R))});const SA=zV(()=>C),fA=async R=>{if(!LI.includes(R.type))return;const QA=new FileReader;QA.onload=()=>{const hA=QA.result,uA={type:"image",id:crypto.randomUUID(),filename:R.name,mime:R.type,dataUrl:hA};F(Dt(CA=>{CA.imageAttachments.push(uA)}))},QA.readAsDataURL(R)},MA=R=>{F(Dt(QA=>{QA.imageAttachments=QA.imageAttachments.filter(hA=>hA.id!==R)}))},mA=async R=>{if(!SA())return;const QA=R.clipboardData;if(!QA)return;const uA=Array.from(QA.items).filter(qA=>LI.includes(qA.type));if(uA.length>0){R.preventDefault(),R.stopPropagation();for(const qA of uA){const jA=qA.getAsFile();jA&&await fA(jA)}return}R.preventDefault(),R.stopPropagation();const CA=QA.getData("text/plain")??"";FA({type:"text",content:CA})},$A=R=>{R.preventDefault(),R.dataTransfer?.types.includes("Files")&&F("dragging",!0)},re=R=>{R.relatedTarget||F("dragging",!1)},de=async R=>{R.preventDefault(),F("dragging",!1);const QA=R.dataTransfer?.files;if(QA)for(const hA of Array.from(QA))LI.includes(hA.type)&&await fA(hA)};et(()=>{C.addEventListener("paste",mA),document.addEventListener("dragover",$A),document.addEventListener("dragleave",re),document.addEventListener("drop",de)}),dA(()=>{C.removeEventListener("paste",mA),document.removeEventListener("dragover",$A),document.removeEventListener("dragleave",re),document.removeEventListener("drop",de)}),tA(()=>{SA()||F("popover",null)});const z=S(()=>r.data.agent.filter(R=>!R.hidden&&R.mode!=="primary").map(R=>({type:"agent",name:R.name,display:R.name}))),q=R=>{R&&(R.type==="agent"?FA({type:"agent",name:R.name,content:"@"+R.name}):FA({type:"file",path:R.path,content:"@"+R.path}))},sA=R=>R?R.type==="agent"?`agent:${R.name}`:`file:${R.path}`:"",{flat:rA,active:V,onInput:cA,onKeyDown:IA}=Yl({items:async R=>{const QA=z(),uA=(await n.file.searchFilesAndDirectories(R)).map(CA=>({type:"file",path:CA,display:CA}));return[...QA,...uA]},key:sA,filterKeys:["display"],onSelect:q}),wA=S(()=>{const R=a.options.filter(hA=>!hA.disabled&&!hA.id.startsWith("suggested.")&&hA.slash).map(hA=>({id:hA.id,trigger:hA.slash,title:hA.title,description:hA.description,keybind:hA.keybind,type:"builtin"}));return[...r.data.command.map(hA=>({id:`custom.${hA.name}`,trigger:hA.name,title:hA.name,description:hA.description,type:"custom"})),...R]}),yA=R=>{if(R){if(F("popover",null),R.type==="custom"){const QA=`/${R.trigger} `;C.innerHTML="",C.textContent=QA,i.set([{type:"text",content:QA,start:0,end:QA.length}],QA.length),requestAnimationFrame(()=>{C.focus();const hA=document.createRange(),uA=window.getSelection();hA.selectNodeContents(C),hA.collapse(!1),uA?.removeAllRanges(),uA?.addRange(hA)});return}C.innerHTML="",i.set([{type:"text",content:"",start:0,end:0}],0),a.trigger(R.id,"slash")}},{flat:PA,active:Z,onInput:x,onKeyDown:j}=Yl({items:wA,key:R=>R?.id,filterKeys:["trigger","title","description"],onSelect:yA});tA(be(()=>i.current(),R=>{const QA=nA();if(Array.from(C.childNodes).every(qA=>{if(qA.nodeType===Node.TEXT_NODE){const vA=qA.textContent??"";if(!vA.includes("​"))return!0;if(vA!=="​")return!1;const aA=qA.previousSibling,VA=qA.nextSibling,LA=aA?.nodeType===Node.ELEMENT_NODE&&aA.tagName==="BR",Be=VA?.nodeType===Node.ELEMENT_NODE&&VA.tagName==="BR";return!(!LA&&!Be||Be&&!LA&&aA)}if(qA.nodeType!==Node.ELEMENT_NODE)return!1;const jA=qA;return jA.dataset.type==="file"||jA.dataset.type==="agent"?!0:jA.tagName==="BR"})&&E1(R,QA))return;const uA=window.getSelection();let CA=null;uA&&uA.rangeCount>0&&C.contains(uA.anchorNode)&&(CA=Cg(C)),C.innerHTML="",R.forEach(qA=>{if(qA.type==="text")C.appendChild(am(qA.content));else if(qA.type==="file"){const jA=document.createElement("span");jA.textContent=qA.content,jA.setAttribute("data-type","file"),jA.setAttribute("data-path",qA.path),jA.setAttribute("contenteditable","false"),jA.style.userSelect="text",jA.style.cursor="default",C.appendChild(jA)}else if(qA.type==="agent"){const jA=document.createElement("span");jA.textContent=qA.content,jA.setAttribute("data-type","agent"),jA.setAttribute("data-name",qA.name),jA.setAttribute("contenteditable","false"),jA.style.userSelect="text",jA.style.cursor="default",C.appendChild(jA)}}),CA!==null&&wi(C,CA)}));const nA=()=>{const R=[];let QA=0,hA="";const uA=()=>{const aA=hA.replace(/\r\n?/g,` `).replace(/\u200B/g,"");hA="",aA&&(R.push({type:"text",content:aA,start:QA,end:QA+aA.length}),QA+=aA.length)},CA=aA=>{const VA=aA.textContent??"";R.push({type:"file",path:aA.dataset.path,content:VA,start:QA,end:QA+VA.length}),QA+=VA.length},qA=aA=>{const VA=aA.textContent??"";R.push({type:"agent",name:aA.dataset.name,content:VA,start:QA,end:QA+VA.length}),QA+=VA.length},jA=aA=>{if(aA.nodeType===Node.TEXT_NODE){hA+=aA.textContent??"";return}if(aA.nodeType!==Node.ELEMENT_NODE)return;const VA=aA;if(VA.dataset.type==="file"){uA(),CA(VA);return}if(VA.dataset.type==="agent"){uA(),qA(VA);return}if(VA.tagName==="BR"){hA+=` `;return}for(const LA of Array.from(VA.childNodes))jA(LA)},vA=Array.from(C.childNodes);return vA.forEach((aA,VA)=>{const LA=aA.nodeType===Node.ELEMENT_NODE&&["DIV","P"].includes(aA.tagName);jA(aA),LA&&VA{const R=nA(),QA=Cg(C),hA=R.map(vA=>"content"in vA?vA.content:"").join(""),uA=hA.replace(/\u200B/g,"").trim(),CA=R.some(vA=>vA.type!=="text");if(uA.length===0&&!CA){F("popover",null),N.historyIndex>=0&&!N.applyingHistory&&(F("historyIndex",-1),F("savedPrompt",null)),i.dirty()&&i.set(Ng,0),u();return}if(N.mode==="shell")F("popover",null);else{const vA=hA.substring(0,QA).match(/@(\S*)$/),aA=hA.match(/^\/(\S*)$/);vA?(cA(vA[1]),F("popover","at")):aA?(x(aA[1]),F("popover","slash")):F("popover",null)}N.historyIndex>=0&&!N.applyingHistory&&(F("historyIndex",-1),F("savedPrompt",null)),i.set(R,QA),u()},BA=(R,QA,hA)=>{let uA=hA;const CA=Array.from(C.childNodes);for(const qA of CA){const jA=Dc(qA),vA=qA.nodeType===Node.TEXT_NODE,aA=qA.nodeType===Node.ELEMENT_NODE&&(qA.dataset.type==="file"||qA.dataset.type==="agent"),VA=qA.nodeType===Node.ELEMENT_NODE&&qA.tagName==="BR";if(vA&&uA<=jA){QA==="start"&&R.setStart(qA,uA),QA==="end"&&R.setEnd(qA,uA);return}if((aA||VA)&&uA<=jA){QA==="start"&&uA===0&&R.setStartBefore(qA),QA==="start"&&uA>0&&R.setStartAfter(qA),QA==="end"&&uA===0&&R.setEndBefore(qA),QA==="end"&&uA>0&&R.setEndAfter(qA);return}uA-=jA}},FA=R=>{const QA=window.getSelection();if(!QA||QA.rangeCount===0)return;const hA=Cg(C),jA=i.current().map(vA=>"content"in vA?vA.content:"").join("").substring(0,hA).match(/@(\S*)$/);if(R.type==="file"){const vA=document.createElement("span");vA.textContent=R.content,vA.setAttribute("data-type","file"),vA.setAttribute("data-path",R.path),vA.setAttribute("contenteditable","false"),vA.style.userSelect="text",vA.style.cursor="default";const aA=document.createTextNode(" "),VA=QA.getRangeAt(0);if(jA){const LA=jA.index??hA-jA[0].length;BA(VA,"start",LA),BA(VA,"end",hA)}VA.deleteContents(),VA.insertNode(aA),VA.insertNode(vA),VA.setStartAfter(aA),VA.collapse(!0),QA.removeAllRanges(),QA.addRange(VA)}else if(R.type==="agent"){const vA=document.createElement("span");vA.textContent=R.content,vA.setAttribute("data-type","agent"),vA.setAttribute("data-name",R.name),vA.setAttribute("contenteditable","false"),vA.style.userSelect="text",vA.style.cursor="default";const aA=document.createTextNode(" "),VA=QA.getRangeAt(0);if(jA){const LA=jA.index??hA-jA[0].length;BA(VA,"start",LA),BA(VA,"end",hA)}VA.deleteContents(),VA.insertNode(aA),VA.insertNode(vA),VA.setStartAfter(aA),VA.collapse(!0),QA.removeAllRanges(),QA.addRange(VA)}else if(R.type==="text"){const vA=QA.getRangeAt(0),aA=am(R.content),VA=aA.lastChild;if(vA.deleteContents(),vA.insertNode(aA),VA){if(VA.nodeType===Node.TEXT_NODE){const LA=VA.textContent??"";LA==="​"&&vA.setStart(VA,0),LA!=="​"&&vA.setStart(VA,LA.length)}VA.nodeType!==Node.TEXT_NODE&&vA.setStartAfter(VA)}vA.collapse(!0),QA.removeAllRanges(),QA.addRange(vA)}EA(),F("popover",null)},te=(R,QA)=>{const hA=window.getSelection();if(!hA)return!1;const uA=K(i.current()),CA=Math.max(0,Math.min(R,uA)),qA=Math.max(0,Math.min(QA,uA)),jA=Math.min(CA,qA),vA=Math.max(CA,qA),aA=document.createRange();aA.selectNodeContents(C);const VA=(LA,Be)=>{let Ge=Be;const Pe=Array.from(C.childNodes);for(const $e of Pe){const It=Dc($e),qr=$e.nodeType===Node.TEXT_NODE,lQ=$e.nodeType===Node.ELEMENT_NODE&&$e.dataset.type==="file",no=$e.nodeType===Node.ELEMENT_NODE&&$e.tagName==="BR";if(qr&&Ge<=It){LA==="start"&&aA.setStart($e,Ge),LA==="end"&&aA.setEnd($e,Ge);return}if((lQ||no)&&Ge<=It){LA==="start"&&Ge===0&&aA.setStartBefore($e),LA==="start"&&Ge>0&&aA.setStartAfter($e),LA==="end"&&Ge===0&&aA.setEndBefore($e),LA==="end"&&Ge>0&&aA.setEndAfter($e);return}Ge-=It}const kt=C.lastChild;if(!kt){LA==="start"&&aA.setStart(C,0),LA==="end"&&aA.setEnd(C,0);return}LA==="start"&&aA.setStartAfter(kt),LA==="end"&&aA.setEndAfter(kt)};return VA("start",jA),VA("end",vA),hA.removeAllRanges(),hA.addRange(aA),!0},RA=(R,QA,hA)=>te(R,QA)?(FA({type:"text",content:hA}),!0):!1,HA=(R,QA)=>{if(R===QA)return;const hA=i.current();if(!hA.every(CA=>CA.type==="text"))return;const uA=hA.map(CA=>CA.content).join("");F("killBuffer",uA.slice(R,QA))},xA=()=>t.client.session.abort({sessionID:g.id}).catch(()=>{}),ee=(R,QA)=>{const hA=R.map(vA=>"content"in vA?vA.content:"").join("").trim();if(!hA)return;const uA=kA(R),CA=QA==="shell"?W:v,qA=QA==="shell"?AA:O,jA=CA.entries[0];jA&&jA.map(aA=>"content"in aA?aA.content:"").join("")===hA||qA("entries",vA=>[uA,...vA].slice(0,L))},JA=R=>{const QA=N.mode==="shell"?W.entries:v.entries,hA=N.historyIndex;if(R==="up"){if(QA.length===0)return!1;if(hA===-1)return F("savedPrompt",kA(i.current())),F("historyIndex",0),$(QA[0],"start"),!0;if(hA0){const uA=hA-1;return F("historyIndex",uA),$(QA[uA],"end"),!0}if(hA===0){F("historyIndex",-1);const uA=N.savedPrompt;return uA?($(uA,"end"),F("savedPrompt",null),!0):($(Ng,"end"),!0)}return!1},ve=R=>{if(R.key==="Backspace"){const uA=window.getSelection();if(uA&&uA.isCollapsed){const CA=uA.anchorNode,qA=uA.anchorOffset;if(CA&&CA.nodeType===Node.TEXT_NODE){const jA=CA.textContent??"";if(/^\u200B+$/.test(jA)&&qA>0){const vA=document.createRange();vA.setStart(CA,0),vA.collapse(!0),uA.removeAllRanges(),uA.addRange(vA)}}}}if(R.key==="!"&&N.mode==="normal"&&Cg(C)===0){F("mode","shell"),F("popover",null),R.preventDefault();return}if(N.mode==="shell"){const{collapsed:uA,cursorPosition:CA,textLength:qA}=P();if(R.key==="Escape"){F("mode","normal"),R.preventDefault();return}if(R.key==="Backspace"&&uA&&CA===0&&qA===0){F("mode","normal"),R.preventDefault();return}}if(N.popover&&(R.key==="ArrowUp"||R.key==="ArrowDown"||R.key==="Enter")){N.popover==="at"?IA(R):j(R),R.preventDefault();return}const QA=R.ctrlKey&&!R.metaKey&&!R.altKey&&!R.shiftKey,hA=R.altKey&&!R.metaKey&&!R.ctrlKey&&!R.shiftKey;if(QA&&R.code==="KeyG"){if(N.popover){F("popover",null),R.preventDefault();return}k()&&(xA(),R.preventDefault());return}if(QA||hA){const{collapsed:uA,cursorPosition:CA,textLength:qA}=P();if(uA){const jA=i.current(),vA=jA.map(aA=>"content"in aA?aA.content:"").join("");if(QA){if(R.code==="KeyA"){const aA=vA.lastIndexOf(` `,CA-1)+1;wi(C,aA),R.preventDefault(),u();return}if(R.code==="KeyE"){const aA=vA.indexOf(` `,CA);wi(C,aA===-1?qA:aA),R.preventDefault(),u();return}if(R.code==="KeyB"){const aA=Math.max(0,CA-1);wi(C,aA),R.preventDefault(),u();return}if(R.code==="KeyF"){const aA=Math.min(qA,CA+1);wi(C,aA),R.preventDefault(),u();return}if(R.code==="KeyD"){if(N.mode==="shell"&&CA===0&&qA===0){F("mode","normal"),R.preventDefault();return}if(CA>=qA)return;RA(CA,CA+1,""),R.preventDefault();return}if(R.code==="KeyK"){const aA=vA.indexOf(` `,CA),VA=aA===-1?qA:aA,LA=VA===CA&&VA0&&/\s/.test(vA[aA-1]);)aA-=1;for(;aA>0&&!/\s/.test(vA[aA-1]);)aA-=1;if(aA===CA)return;HA(aA,CA),RA(aA,CA,""),R.preventDefault();return}if(R.code==="KeyY"){if(!N.killBuffer)return;FA({type:"text",content:N.killBuffer}),R.preventDefault();return}if(R.code==="KeyT"){if(!jA.every(Be=>Be.type==="text")||qA<2||CA===0)return;const aA=CA===qA,VA=aA?CA-2:CA-1,LA=aA?CA-1:CA;if(vA[VA]===` `||vA[LA]===` `)return;RA(VA,LA+1,`${vA[LA]}${vA[VA]}`),R.preventDefault();return}}if(hA){if(R.code==="KeyB"){let aA=CA;for(;aA>0&&/\s/.test(vA[aA-1]);)aA-=1;for(;aA>0&&!/\s/.test(vA[aA-1]);)aA-=1;wi(C,aA),R.preventDefault(),u();return}if(R.code==="KeyF"){let aA=CA;for(;aA"content"in kt?kt.content:"").join(""),vA=jA.trim()===""||qA<=1,aA=jA.includes(` `),VA=N.historyIndex>=0,LA=CA<=(vA?1:0),Be=CA>=(vA?qA-1:qA),Ge=vA||LA||!aA&&!VA||VA&&Be,Pe=vA||Be||!aA&&!VA||VA&&LA;if(R.key==="ArrowUp"){if(!Ge)return;JA("up")&&R.preventDefault();return}if(!Pe)return;JA("down")&&R.preventDefault();return}if(R.key==="Enter"&&R.shiftKey){FA({type:"text",content:` `}),R.preventDefault();return}R.key==="Enter"&&!R.shiftKey&&me(R),R.key==="Escape"&&(N.popover?F("popover",null):k()&&xA())},me=async R=>{R.preventDefault();const QA=i.current(),hA=QA.map(Me=>"content"in Me?Me.content:"").join(""),uA=N.imageAttachments.length>0;if(hA.trim().length===0&&!uA){k()&&xA();return}ee(QA,N.mode),F("historyIndex",-1),F("savedPrompt",null);let CA=f();if(CA||(CA=(await t.client.session.create()).data??void 0,CA&&A(CA.id)),!CA)return;const qA=Me=>Me.startsWith("/")?Me:r.absolute(Me),jA=QA.filter(Me=>Me.type==="file"),vA=QA.filter(Me=>Me.type==="agent"),aA=jA.map(Me=>{const aa=qA(Me.path),sa=Me.selection?`?start=${Me.selection.startLine}&end=${Me.selection.endLine}`:"";return{id:co.ascending("part"),type:"file",mime:"text/plain",url:`file://${aa}${sa}`,filename:ut(Me.path),source:{type:"file",text:{value:Me.content,start:Me.start,end:Me.end},path:aa}}}),VA=vA.map(Me=>({id:co.ascending("part"),type:"agent",name:Me.name,source:{value:Me.content,start:Me.start,end:Me.end}})),LA=N.imageAttachments.map(Me=>({id:co.ascending("part"),type:"file",mime:Me.mime,url:Me.dataUrl,filename:Me.filename})),Be=N.mode==="shell";d().setActive(void 0),C.innerHTML="",i.set([{type:"text",content:"",start:0,end:0}],0),F("imageAttachments",[]),F("mode","normal");const Ge=n.model.current(),Pe=n.agent.current();if(!Ge||!Pe){console.warn("No agent or model available for prompt submission");return}const kt={modelID:Ge.id,providerID:Ge.provider.id},$e=Pe.name,It=n.model.variant.current();if(Be){t.client.session.shell({sessionID:CA.id,agent:$e,model:kt,command:hA}).catch(Me=>{console.error("Failed to send shell command",Me)});return}if(hA.startsWith("/")){const[Me,...aa]=hA.split(" "),sa=Me.slice(1);if(r.data.command.find(hC=>hC.name===sa)){t.client.session.command({sessionID:CA.id,command:sa,arguments:aa.join(" "),agent:$e,model:`${kt.providerID}/${kt.modelID}`,variant:It}).catch(hC=>{console.error("Failed to send command",hC)});return}}const qr=co.ascending("message"),no=[{id:co.ascending("part"),type:"text",text:hA},...aA,...VA,...LA],Cx=no.map(Me=>({...Me,sessionID:CA.id,messageID:qr}));r.session.addOptimisticMessage({sessionID:CA.id,messageID:qr,parts:Cx,agent:$e,model:kt}),t.client.session.prompt({sessionID:CA.id,agent:$e,model:kt,messageID:qr,parts:no,variant:It}).catch(Me=>{console.error("Failed to send prompt",Me)})};return(()=>{var R=teA(),QA=R.firstChild,hA=QA.firstChild,uA=hA.firstChild,CA=hA.nextSibling,qA=CA.firstChild,jA=qA.nextSibling,vA=jA.firstChild,aA=vA.nextSibling;M(R,l(Y,{get when(){return N.popover},get children(){var LA=WAA();return M(LA,l(Je,{get children(){return[l(YA,{get when(){return N.popover==="at"},get children(){return l(Y,{get when(){return rA().length>0},get fallback(){return reA()},get children(){return l(Ke,{get each(){return rA().slice(0,10)},children:Be=>(()=>{var Ge=ieA();return Ge.$$click=()=>q(Be),M(Ge,l(Y,{get when(){return Be.type==="agent"},get fallback(){return[l(aQ,{get node(){return{path:Be.path,type:"file"}},class:"shrink-0 size-4"}),(()=>{var Pe=geA(),kt=Pe.firstChild;return M(kt,()=>Wo(Be.path)),M(Pe,l(Y,{get when(){return!Be.path.endsWith("/")},get children(){var $e=oeA();return M($e,()=>ut(Be.path)),$e}}),null),Pe})()]},get children(){return[l(Ee,{name:"brain",size:"small",class:"text-icon-info-active shrink-0"}),(()=>{var Pe=neA();return Pe.firstChild,M(Pe,()=>Be.name,null),Pe})()]}})),_A(Pe=>qe(Ge,{"w-full flex items-center gap-x-2 rounded-md px-2 py-0.5":!0,"bg-surface-raised-base-hover":V()===sA(Be)},Pe)),Ge})()})}})}}),l(YA,{get when(){return N.popover==="slash"},get children(){return l(Y,{get when(){return PA().length>0},get fallback(){return QeA()},get children(){return l(Ke,{get each(){return PA()},children:Be=>(()=>{var Ge=EeA(),Pe=Ge.firstChild,kt=Pe.firstChild;kt.firstChild;var $e=Pe.nextSibling;return Ge.$$click=()=>yA(Be),M(kt,()=>Be.trigger,null),M(Pe,l(Y,{get when(){return Be.description},get children(){var It=BeA();return M(It,()=>Be.description),It}}),null),M($e,l(Y,{get when(){return Be.type==="custom"},get children(){return aeA()}}),null),M($e,l(Y,{get when(){return a.keybind(Be.id)},get children(){var It=seA();return M(It,()=>a.keybind(Be.id)),It}}),null),_A(It=>qe(Ge,{"w-full flex items-center justify-between gap-4 rounded-md px-2 py-1":!0,"bg-surface-raised-base-hover":Z()===Be.id},It)),Ge})()})}})}})]}})),LA}}),QA),QA.addEventListener("submit",me),M(QA,l(Y,{get when(){return N.dragging},get children(){var LA=ZAA(),Be=LA.firstChild,Ge=Be.firstChild;return M(Be,l(Ee,{name:"photo",class:"size-8"}),Ge),LA}}),hA),M(QA,l(Y,{get when(){return N.imageAttachments.length>0},get children(){var LA=XAA();return M(LA,l(Ke,{get each(){return N.imageAttachments},children:Be=>(()=>{var Ge=IeA(),Pe=Ge.firstChild,kt=Pe.nextSibling,$e=kt.firstChild;return M(Ge,l(Y,{get when(){return Be.mime.startsWith("image/")},get fallback(){return(()=>{var It=leA();return M(It,l(Ee,{name:"folder",class:"size-6 text-text-weak"})),It})()},get children(){var It=CeA();return _A(qr=>{var lQ=Be.dataUrl,no=Be.filename;return lQ!==qr.e&&ce(It,"src",qr.e=lQ),no!==qr.t&&ce(It,"alt",qr.t=no),qr},{e:void 0,t:void 0}),It}}),Pe),Pe.$$click=()=>MA(Be.id),M(Pe,l(Ee,{name:"close",class:"size-3 text-text-weak"})),M($e,()=>Be.filename),Ge})()})),LA}}),hA),Qt(LA=>I=LA,hA),uA.$$keydown=ve,uA.$$input=EA,Qt(LA=>{C=LA,e.ref?.(LA)},uA),M(hA,l(Y,{get when(){return Ae(()=>!i.dirty())()&&N.imageAttachments.length===0},get children(){var LA=$AA();return M(LA,(()=>{var Be=Ae(()=>N.mode==="shell");return()=>Be()?"Enter shell command...":`Ask anything... "${RI[N.placeholder]}"`})()),LA}}),null),M(qA,l(Je,{get children(){return[l(YA,{get when(){return N.mode==="shell"},get children(){var LA=AeA(),Be=LA.firstChild;return M(LA,l(Ee,{name:"console",size:"small",class:"text-icon-primary"}),Be),LA}}),l(YA,{get when(){return N.mode==="normal"},get children(){return[l(hr,{placement:"top",title:"Cycle agent",get keybind(){return a.keybind("agent.cycle")},get children(){return l(sc,{get options(){return n.agent.list().map(LA=>LA.name)},get current(){return n.agent.current()?.name??""},get onSelect(){return n.agent.set},class:"capitalize",variant:"ghost"})}}),l(Y,{get when(){return B.paid().length>0},get fallback(){return l(hr,{placement:"top",title:"Choose model",get keybind(){return a.keybind("model.choose")},get children(){return l(ue,{as:"div",variant:"ghost",onClick:()=>Q.show(()=>l(IW,{})),get children(){return[Ae(()=>n.model.current()?.name??"Select model"),l(Ee,{name:"chevron-down",size:"small"})]}})}})},get children(){return l(gW,{get children(){return l(hr,{placement:"top",title:"Choose model",get keybind(){return a.keybind("model.choose")},get children(){return l(ue,{as:"div",variant:"ghost",get children(){return[Ae(()=>n.model.current()?.name??"Select model"),l(Ee,{name:"chevron-down",size:"small"})]}})}})}})}}),l(Y,{get when(){return n.model.variant.list().length>0},get children(){return l(hr,{placement:"top",title:"Thinking effort",get keybind(){return a.keybind("model.variant.cycle")},get children(){return l(ue,{variant:"ghost",class:"text-text-base _hidden group-hover/prompt-input:inline-block",onClick:()=>n.model.variant.cycle(),get children(){var LA=eeA();return M(LA,()=>n.model.variant.current()??"Default"),LA}})}})}}),l(Y,{get when(){return Ae(()=>!!s.permissionsEnabled())()&&g.id},get children(){return l(hr,{placement:"top",title:"Auto-accept edits",get keybind(){return a.keybind("permissions.autoaccept")},get children(){return l(ue,{variant:"ghost",onClick:()=>s.toggleAutoAccept(g.id,t.directory),get classList(){return{"_hidden group-hover/prompt-input:flex size-6 items-center justify-center":!0,"text-text-base":!s.isAutoAccepting(g.id),"hover:bg-surface-success-base":s.isAutoAccepting(g.id)}},get children(){return l(Ee,{name:"chevron-double-right",size:"small",get classList(){return{"text-icon-success-base":s.isAutoAccepting(g.id)}}})}})}})}})]}})]}})),vA.addEventListener("change",LA=>{const Be=LA.currentTarget.files?.[0];Be&&fA(Be),LA.currentTarget.value=""});var VA=E;return typeof VA=="function"?Qt(VA,vA):E=vA,M(aA,l(VAA,{}),null),M(aA,l(Y,{get when(){return N.mode==="normal"},get children(){return l(Ar,{placement:"top",value:"Attach image",get children(){return l(ue,{type:"button",variant:"ghost",class:"size-6",onClick:()=>E.click(),get children(){return l(Ee,{name:"photo",class:"size-4.5"})}})}})}}),null),M(jA,l(Ar,{placement:"top",get inactive(){return Ae(()=>!i.dirty())()&&!k()},get value(){return l(Je,{get children(){return[l(YA,{get when(){return k()},get children(){return ceA()}}),l(YA,{when:!0,get children(){var LA=ueA();return LA.firstChild,M(LA,l(Ee,{name:"enter",size:"small",class:"text-icon-base"}),null),LA}})]}})},get children(){return l(Ot,{type:"submit",get disabled(){return Ae(()=>!i.dirty()&&N.imageAttachments.length===0)()&&!k()},get icon(){return k()?"stop":"arrow-up"},variant:"primary",class:"h-6 w-4.5"})}}),null),_A(LA=>{var Be={"group/prompt-input":!0,"bg-surface-raised-stronger-non-alpha shadow-xs-border relative":!0,"rounded-md overflow-clip focus-within:shadow-xs-border":!0,"border-icon-info-active border-dashed":N.dragging,[e.class??""]:!!e.class},Ge={"select-text":!0,"w-full px-5 py-3 pr-12 text-14-regular text-text-strong focus:outline-none whitespace-pre-wrap":!0,"[&_[data-type=file]]:text-syntax-property":!0,"[&_[data-type=agent]]:text-syntax-type":!0,"font-mono!":N.mode==="shell"},Pe=fF.join(",");return LA.e=qe(QA,Be,LA.e),LA.t=qe(uA,Ge,LA.t),Pe!==LA.a&&ce(vA,"accept",LA.a=Pe),LA},{e:void 0,t:void 0,a:void 0}),R})()};function am(e){const A=document.createDocumentFragment(),t=e.split(` `);return t.forEach((r,n)=>{r?A.appendChild(document.createTextNode(r)):t.length>1&&A.appendChild(document.createTextNode("​")),n0&&B&&s.setStartAfter(r),t>0&&a){const E=r.nextSibling;E&&E.nodeType===Node.TEXT_NODE&&s.setStart(E,0),(!E||E.nodeType!==Node.TEXT_NODE)&&s.setStartAfter(r)}s.collapse(!0),C?.removeAllRanges(),C?.addRange(s);return}t-=g,r=r.nextSibling}const n=document.createRange(),i=window.getSelection(),o=e.lastChild;if(o&&o.nodeType===Node.TEXT_NODE){const g=o.textContent?o.textContent.length:0;n.setStart(o,g)}(!o||o.nodeType!==Node.TEXT_NODE)&&n.selectNodeContents(e),n.collapse(!1),i?.removeAllRanges(),i?.addRange(n)}or(["input","keydown","click"]);var deA=class{collection;direction;orientation;constructor(e,A,t){this.collection=e,this.direction=A,this.orientation=t}flipDirection(){return this.direction()==="rtl"&&this.orientation()==="horizontal"}getKeyLeftOf(e){if(this.flipDirection())return this.getNextKey(e);if(this.orientation()==="horizontal")return this.getPreviousKey(e)}getKeyRightOf(e){if(this.flipDirection())return this.getPreviousKey(e);if(this.orientation()==="horizontal")return this.getNextKey(e)}getKeyAbove(e){if(this.orientation()==="vertical")return this.getPreviousKey(e)}getKeyBelow(e){if(this.orientation()==="vertical")return this.getNextKey(e)}getFirstKey(){let e=this.collection().getFirstKey();return e==null?void 0:(this.collection().getItem(e)?.disabled&&(e=this.getNextKey(e)),e)}getLastKey(){let e=this.collection().getLastKey();return e==null?void 0:(this.collection().getItem(e)?.disabled&&(e=this.getPreviousKey(e)),e)}getNextKey(e){let A=e,t;do if(A=this.collection().getKeyAfter(A)??this.collection().getFirstKey(),A==null||(t=this.collection().getItem(A),t==null))return;while(t.disabled);return A}getPreviousKey(e){let A=e,t;do if(A=this.collection().getKeyBefore(A)??this.collection().getLastKey(),A==null||(t=this.collection().getItem(A),t==null))return;while(t.disabled);return A}},heA={};Zt(heA,{Content:()=>pF,Indicator:()=>kF,List:()=>yF,Root:()=>MF,Tabs:()=>ga,Trigger:()=>NF,useTabsContext:()=>oa});var mF=ye();function oa(){const e=pe(mF);if(e===void 0)throw new Error("[kobalte]: `useTabsContext` must be used within a `Tabs` component");return e}function pF(e){const[A,t]=gA(),r=oa(),[n,i]=eA(e,["ref","id","value","forceMount"]),[o,g]=gA(0),Q=()=>n.id??r.generateContentId(n.value),B=()=>r.listState().selectedKey()===n.value,{present:a}=en({show:()=>n.forceMount||B(),element:()=>A()??null});return tA(be([()=>A(),()=>a()],([s,C])=>{if(s==null||!C)return;const E=()=>{const c=QM(s,{tabbable:!0});g(c.nextNode()?void 0:0)};E();const I=new MutationObserver(E);I.observe(s,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["tabindex","disabled"]}),dA(()=>{I.disconnect()})})),tA(be([()=>n.value,Q],([s,C])=>{r.contentIdsMap().set(s,C)})),l(Y,{get when(){return a()},get children(){return l(XA,H({as:"div",ref(s){var C=ae(t,n.ref);typeof C=="function"&&C(s)},get id(){return Q()},role:"tabpanel",get tabIndex(){return o()},get"aria-labelledby"(){return r.triggerIdsMap().get(n.value)},get"data-orientation"(){return r.orientation()},get"data-selected"(){return B()?"":void 0}},i))}})}function kF(e){const A=oa(),[t,r]=eA(e,["style"]),[n,i]=gA({width:void 0,height:void 0}),{direction:o}=Gn(),g=()=>{const C=A.selectedTab();if(C==null)return;const E={transform:void 0,width:void 0,height:void 0},I=o()==="rtl"?-1*(C.offsetParent?.offsetWidth-C.offsetWidth-C.offsetLeft):C.offsetLeft;E.transform=A.orientation()==="vertical"?`translateY(${C.offsetTop}px)`:`translateX(${I}px)`,A.orientation()==="horizontal"?E.width=`${C.offsetWidth}px`:E.height=`${C.offsetHeight}px`,i(E)};et(()=>{queueMicrotask(()=>{g()})}),tA(be([A.selectedTab,A.orientation,o],()=>{g()},{defer:!0}));const[Q,B]=gA(!1);let a=null,s=null;return CB(A.selectedTab,(C,E)=>{if(s!==E){s=E;return}B(!0),a&&clearTimeout(a),a=setTimeout(()=>{a=null,B(!1)},1),g()}),l(XA,H({as:"div",role:"presentation",get style(){return Tt(n(),t.style)},get"data-orientation"(){return A.orientation()},get"data-resizing"(){return Q()}},r))}function yF(e){let A;const t=oa(),[r,n]=eA(e,["ref","onKeyDown","onMouseDown","onFocusIn","onFocusOut"]),{direction:i}=Gn(),o=new deA(()=>t.listState().collection(),i,t.orientation),g=NN({selectionManager:()=>t.listState().selectionManager(),keyboardDelegate:()=>o,selectOnFocus:()=>t.activationMode()==="automatic",shouldFocusWrap:!1,disallowEmptySelection:!0},()=>A);return tA(()=>{if(A==null)return;const Q=A.querySelector(`[data-key="${t.listState().selectedKey()}"]`);Q!=null&&t.setSelectedTab(Q)}),l(XA,H({as:"div",ref(Q){var B=ae(a=>A=a,r.ref);typeof B=="function"&&B(Q)},role:"tablist",get"aria-orientation"(){return t.orientation()},get"data-orientation"(){return t.orientation()},get onKeyDown(){return ge([r.onKeyDown,g.onKeyDown])},get onMouseDown(){return ge([r.onMouseDown,g.onMouseDown])},get onFocusIn(){return ge([r.onFocusIn,g.onFocusIn])},get onFocusOut(){return ge([r.onFocusOut,g.onFocusOut])}},n))}function DeA(e){const[A,t]=Po({value:()=>oA(e.selectedKey),defaultValue:()=>oA(e.defaultSelectedKey),onChange:B=>e.onSelectionChange?.(B)}),r=S(()=>{const B=A();return B!=null?[B]:[]}),[,n]=eA(e,["onSelectionChange"]),i=H(n,{selectionMode:"single",disallowEmptySelection:!0,allowDuplicateSelectionEvents:!0,selectedKeys:r,onSelectionChange:B=>{const a=B.values().next().value;a===A()&&e.onSelectionChange?.(a),t(a)}}),{collection:o,selectionManager:g}=_B(i),Q=S(()=>{const B=A();return B!=null?o().getItem(B):void 0});return{collection:o,selectionManager:g,selectedKey:A,setSelectedKey:t,selectedItem:Q}}function MF(e){const A=`tabs-${je()}`,t=OA({id:A,orientation:"horizontal",activationMode:"automatic"},e),[r,n]=eA(t,["value","defaultValue","onChange","orientation","activationMode","disabled"]),[i,o]=gA([]),[g,Q]=gA(),{DomCollectionProvider:B}=id({items:i,onItemsChange:o}),a=DeA({selectedKey:()=>r.value,defaultSelectedKey:()=>r.defaultValue,onSelectionChange:c=>r.onChange?.(String(c)),dataSource:i});let s=a.selectedKey();tA(be([()=>a.selectionManager(),()=>a.collection(),()=>a.selectedKey()],([c,u,h])=>{let d=h;if(c.isEmpty()||d==null||!u.getItem(d)){d=u.getFirstKey();let f=d!=null?u.getItem(d):void 0;for(;f?.disabled&&f.key!==u.getLastKey();)d=u.getKeyAfter(f.key),f=d!=null?u.getItem(d):void 0;f?.disabled&&d===u.getLastKey()&&(d=u.getFirstKey()),d!=null&&c.setSelectedKeys([d])}(c.focusedKey()==null||!c.isFocused()&&d!==s)&&c.setFocusedKey(d),s=d}));const C=new Map,E=new Map,I={isDisabled:()=>r.disabled??!1,orientation:()=>r.orientation,activationMode:()=>r.activationMode,triggerIdsMap:()=>C,contentIdsMap:()=>E,listState:()=>a,selectedTab:g,setSelectedTab:Q,generateTriggerId:c=>`${n.id}-trigger-${c}`,generateContentId:c=>`${n.id}-content-${c}`};return l(B,{get children(){return l(mF.Provider,{value:I,get children(){return l(XA,H({as:"div",get"data-orientation"(){return I.orientation()}},n))}})}})}function NF(e){let A;const t=oa(),r=OA({type:"button"},e),[n,i]=eA(r,["ref","id","value","disabled","onPointerDown","onPointerUp","onClick","onKeyDown","onMouseDown","onFocus"]),o=()=>n.id??t.generateTriggerId(n.value),g=()=>t.listState().selectionManager().focusedKey()===n.value,Q=()=>n.disabled||t.isDisabled(),B=()=>t.contentIdsMap().get(n.value);od({getItem:()=>({ref:()=>A,type:"item",key:n.value,textValue:"",disabled:Q()})});const a=PB({key:()=>n.value,selectionManager:()=>t.listState().selectionManager(),disabled:Q},()=>A),s=C=>{nM()&&At(C.currentTarget)};return tA(be([()=>n.value,o],([C,E])=>{t.triggerIdsMap().set(C,E)})),l(XA,H({as:"button",ref(C){var E=ae(I=>A=I,n.ref);typeof E=="function"&&E(C)},get id(){return o()},role:"tab",get tabIndex(){return Ae(()=>!Q())()?a.tabIndex():void 0},get disabled(){return Q()},get"aria-selected"(){return a.isSelected()},get"aria-disabled"(){return Q()||void 0},get"aria-controls"(){return Ae(()=>!!a.isSelected())()?B():void 0},get"data-key"(){return a.dataKey()},get"data-orientation"(){return t.orientation()},get"data-selected"(){return a.isSelected()?"":void 0},get"data-highlighted"(){return g()?"":void 0},get"data-disabled"(){return Q()?"":void 0},get onPointerDown(){return ge([n.onPointerDown,a.onPointerDown])},get onPointerUp(){return ge([n.onPointerUp,a.onPointerUp])},get onClick(){return ge([n.onClick,a.onClick,s])},get onKeyDown(){return ge([n.onKeyDown,a.onKeyDown])},get onMouseDown(){return ge([n.onMouseDown,a.onMouseDown])},get onFocus(){return ge([n.onFocus,a.onFocus])}},i))}var ga=Object.assign(MF,{Content:pF,Indicator:kF,List:yF,Trigger:NF}),feA=J("
    "),weA=J("
    ");function meA(e){const[A,t]=eA(e,["class","classList","variant","orientation"]);return l(ga,H(t,{get orientation(){return A.orientation},"data-component":"tabs",get"data-variant"(){return A.variant||"normal"},get"data-orientation"(){return A.orientation||"horizontal"},get classList(){return{...A.classList??{},[A.class??""]:!!A.class}}}))}function peA(e){const[A,t]=eA(e,["class","classList"]);return l(ga.List,H(t,{"data-slot":"tabs-list",get classList(){return{...A.classList??{},[A.class??""]:!!A.class}}}))}function keA(e){const[A,t]=eA(e,["class","classList","classes","children","closeButton","hideCloseButton"]);return(()=>{var r=feA();return M(r,l(ga.Trigger,H(t,{"data-slot":"tabs-trigger",get classList(){return{"group/tab":!0,[A.classes?.button??""]:A.classes?.button}},get children(){return A.children}})),null),M(r,l(Y,{get when(){return A.closeButton},children:n=>(()=>{var i=weA();return M(i,n),_A(()=>ce(i,"data-hidden",A.hideCloseButton)),i})()}),null),_A(n=>qe(r,{...A.classList??{},[A.class??""]:!!A.class},n)),r})()}function yeA(e){const[A,t]=eA(e,["class","classList","children"]);return l(ga.Content,H(t,{"data-slot":"tabs-content",get classList(){return{...A.classList??{},[A.class??""]:!!A.class}},get children(){return A.children}}))}const Yt=Object.assign(meA,{List:peA,Trigger:keA,Content:yeA});var MeA=J("│");const NeA=e=>{const[A,t]=xe({typing:!1,displayed:"",cursor:!0});return tA(()=>{const r=e.text;if(!r)return;let n=0;const i=[];t("typing",!0),t("displayed",""),t("cursor",!0);const o=()=>{const Q=Math.random();return Q<.05?150+Math.random()*100:Q<.15?80+Math.random()*60:30+Math.random()*50},g=()=>{nt("cursor",!1),2e3)))};i.push(setTimeout(g,200)),dA(()=>{for(const Q of i)clearTimeout(Q)})}),l(Mn,{get component(){return e.as||"p"},get class(){return e.class},get children(){return[Ae(()=>A.displayed),l(Y,{get when(){return A.cursor},get children(){var r=MeA();return _A(()=>r.classList.toggle("blinking-cursor",!A.typing)),r}})]}})};var veA=J("
    "),beA=J(""),FeA=J("
    "),xeA=J("");const GeA=e=>typeof e=="object"&&e!==null&&"title"in e&&(typeof Node>"u"||!(e instanceof Node));function Lr(e){const[A,t]=gA(e.defaultOpen??!1);return tA(()=>{e.forceOpen&&t(!0)}),l(fo,{get open(){return A()},onOpenChange:t,get children(){return[l(fo.Trigger,{get children(){var r=veA(),n=r.firstChild,i=n.firstChild;return M(n,l(Ee,{get name(){return e.icon},size:"small"}),i),M(i,l(Je,{get children(){return[l(YA,{get when(){return Ae(()=>!!GeA(e.trigger))()&&e.trigger},children:o=>(()=>{var g=FeA(),Q=g.firstChild,B=Q.firstChild;return M(B,()=>o().title),M(Q,l(Y,{get when(){return o().subtitle},get children(){var a=beA();return M(a,()=>o().subtitle),_A(s=>qe(a,{[o().subtitleClass??""]:!!o().subtitleClass},s)),a}}),null),M(Q,l(Y,{get when(){return o().args?.length},get children(){return l(Ke,{get each(){return o().args},children:a=>(()=>{var s=xeA();return M(s,a),_A(C=>qe(s,{[o().argsClass??""]:!!o().argsClass},C)),s})()})}}),null),M(g,l(Y,{get when(){return o().action},get children(){return o().action}}),null),_A(a=>qe(B,{[o().titleClass??""]:!!o().titleClass},a)),g})()}),l(YA,{when:!0,get children(){return e.trigger}})]}})),M(r,l(Y,{get when(){return Ae(()=>!!e.children)()&&!e.hideDetails},get children(){return l(fo.Arrow,{})}}),null),r}}),l(Y,{get when(){return Ae(()=>!!e.children)()&&!e.hideDetails},get children(){return l(fo.Content,{get children(){return e.children}})}})]}})}function vF(e){return l(Lr,{icon:"mcp",get trigger(){return{title:e.tool}},get hideDetails(){return e.hideDetails}})}var SeA=J("
    ");function fc(e){const[A,t]=eA(e,["variant","class","classList"]);return(()=>{var r=SeA();return dt(r,H(t,{"data-component":"card",get"data-variant"(){return A.variant||"normal"},get classList(){return{...A.classList??{},[A.class??""]:!!A.class}}}),!1,!0),M(r,()=>e.children),r})()}var JeA={};Zt(JeA,{Checkbox:()=>Mi,Control:()=>FF,Description:()=>xF,ErrorMessage:()=>GF,Indicator:()=>SF,Input:()=>JF,Label:()=>UF,Root:()=>KF,useCheckboxContext:()=>eg});var bF=ye();function eg(){const e=pe(bF);if(e===void 0)throw new Error("[kobalte]: `useCheckboxContext` must be used within a `Checkbox` component");return e}function FF(e){const A=Xt(),t=eg(),r=OA({id:t.generateId("control")},e),[n,i]=eA(r,["onClick","onKeyDown"]);return l(XA,H({as:"div",onClick:Q=>{WA(Q,n.onClick),t.toggle(),t.inputRef()?.focus()},onKeyDown:Q=>{WA(Q,n.onKeyDown),Q.key===xB.Space&&(t.toggle(),t.inputRef()?.focus())}},()=>A.dataset(),()=>t.dataset(),i))}function xF(e){const A=eg();return l(Bi,H(()=>A.dataset(),e))}function GF(e){const A=eg();return l(ai,H(()=>A.dataset(),e))}function SF(e){const A=Xt(),t=eg(),[r,n]=gA(),i=OA({id:t.generateId("indicator")},e),[o,g]=eA(i,["ref","forceMount"]),{present:Q}=en({show:()=>o.forceMount||t.indeterminate()||t.checked(),element:()=>r()??null});return l(Y,{get when(){return Q()},get children(){return l(XA,H({as:"div",ref(B){var a=ae(n,o.ref);typeof a=="function"&&a(B)}},()=>A.dataset(),()=>t.dataset(),g))}})}function JF(e){let A;const t=Xt(),r=eg(),n=OA({id:r.generateId("input")},e),[i,o,g]=eA(n,["ref","style","onChange","onFocus","onBlur"],NE),{fieldProps:Q}=vE(o),[B,a]=gA(!1),s=I=>{if(WA(I,i.onChange),I.stopPropagation(),!B()){const c=I.target;r.setIsChecked(c.checked),c.checked=r.checked()}a(!1)},C=I=>{WA(I,i.onFocus),r.setIsFocused(!0)},E=I=>{WA(I,i.onBlur),r.setIsFocused(!1)};return tA(be([()=>r.checked(),()=>r.value()],()=>{a(!0),A?.dispatchEvent(new Event("input",{bubbles:!0,cancelable:!0})),A?.dispatchEvent(new Event("change",{bubbles:!0,cancelable:!0}))},{defer:!0})),tA(be([()=>A,()=>r.indeterminate(),()=>r.checked()],([I,c])=>{I&&(I.indeterminate=c)})),l(XA,H({as:"input",ref(I){var c=ae(u=>{r.setInputRef(u),A=u},i.ref);typeof c=="function"&&c(I)},type:"checkbox",get id(){return Q.id()},get name(){return t.name()},get value(){return r.value()},get checked(){return r.checked()},get required(){return t.isRequired()},get disabled(){return t.isDisabled()},get readonly(){return t.isReadOnly()},get style(){return Tt(SB,i.style)},get"aria-label"(){return Q.ariaLabel()},get"aria-labelledby"(){return Q.ariaLabelledBy()},get"aria-describedby"(){return Q.ariaDescribedBy()},get"aria-invalid"(){return t.validationState()==="invalid"||void 0},get"aria-required"(){return t.isRequired()},get"aria-disabled"(){return t.isDisabled()},get"aria-readonly"(){return t.isReadOnly()},onChange:s,onFocus:C,onBlur:E},()=>t.dataset(),()=>r.dataset(),g))}function UF(e){const A=eg();return l(AQ,H(()=>A.dataset(),e))}function KF(e){let A;const t=`checkbox-${je()}`,r=OA({value:"on",id:t},e),[n,i,o]=eA(r,["ref","children","value","checked","defaultChecked","indeterminate","onChange","onPointerDown"],UB),[g,Q]=gA(),[B,a]=gA(!1),{formControlContext:s}=KB(i),C=gd({isSelected:()=>n.checked,defaultIsSelected:()=>n.defaultChecked,onSelectedChange:u=>n.onChange?.(u),isDisabled:()=>s.isDisabled(),isReadOnly:()=>s.isReadOnly()});eQ(()=>A,()=>C.setIsSelected(n.defaultChecked??!1));const E=u=>{WA(u,n.onPointerDown),B()&&u.preventDefault()},I=S(()=>({"data-checked":C.isSelected()?"":void 0,"data-indeterminate":n.indeterminate?"":void 0})),c={value:()=>n.value,dataset:I,checked:()=>C.isSelected(),indeterminate:()=>n.indeterminate??!1,inputRef:g,generateId:Gt(()=>oA(i.id)),toggle:()=>C.toggle(),setIsChecked:u=>C.setIsSelected(u),setIsFocused:a,setInputRef:Q};return l($g.Provider,{value:s,get children(){return l(bF.Provider,{value:c,get children(){return l(XA,H({as:"div",ref(u){var h=ae(d=>A=d,n.ref);typeof h=="function"&&h(u)},role:"group",get id(){return oA(i.id)},onPointerDown:E},()=>s.dataset(),I,o,{get children(){return l(UeA,{state:c,get children(){return n.children}})}}))}})}})}function UeA(e){const A=ji(()=>{const t=e.children;return Xg(t)?t(e.state):t});return Ae(A)}var Mi=Object.assign(KF,{Control:FF,Description:xF,ErrorMessage:GF,Indicator:SF,Input:JF,Label:UF}),KeA=J("
    "),LeA=J('');function ReA(e){const[A,t]=eA(e,["children","class","label","hideLabel","description","icon"]);return l(Mi,H(t,{"data-component":"checkbox",get children(){return[l(Mi.Input,{"data-slot":"checkbox-checkbox-input"}),l(Mi.Control,{"data-slot":"checkbox-checkbox-control",get children(){return l(Mi.Indicator,{"data-slot":"checkbox-checkbox-indicator",get children(){return A.icon||LeA()}})}}),(()=>{var r=KeA();return M(r,l(Y,{get when(){return e.children},get children(){return l(Mi.Label,{"data-slot":"checkbox-checkbox-label",get classList(){return{"sr-only":A.hideLabel}},get children(){return e.children}})}}),null),M(r,l(Y,{get when(){return A.description},get children(){return l(Mi.Description,{"data-slot":"checkbox-checkbox-description",get children(){return A.description}})}}),null),M(r,l(Mi.ErrorMessage,{"data-slot":"checkbox-checkbox-error"}),null),r})()]}}))}var OeA=J("
    ");function ro(e){const[A,t]=eA(e,["text","class","classList"]),r=zq(),[n]=Ji(()=>A.text,async i=>r.parse(i));return(()=>{var i=OeA();return dt(i,H({get classList(){return{...A.classList??{},[A.class??""]:!!A.class}},get innerHTML(){return n()}},t),!1,!1),i})()}var qeA=J("
    "),TeA=J("
    "),HeA=J("
    ");function YeA(e){return(()=>{var A=HeA(),t=A.firstChild;return M(t,l(hn.Content,{"data-slot":"image-preview-content",get children(){return[(()=>{var r=qeA();return M(r,l(hn.CloseButton,{"data-slot":"image-preview-close",as:Ot,icon:"close",variant:"ghost"})),r})(),(()=>{var r=TeA(),n=r.firstChild;return _A(i=>{var o=e.src,g=e.alt??"Image preview";return o!==i.e&&ce(n,"src",i.e=o),g!==i.t&&ce(n,"alt",i.t=g),i},{e:void 0,t:void 0}),r})()]}})),A})()}var zeA=J("
    "),PeA=J("
    Error[:]"),_eA=J("
    "),jeA=J("
    "),VeA=J("
    "),WeA=J(""),ZeA=J("
    "),XeA=J("
    "),$eA=J(""),LF=J("
    "),RF=J("
    "),AtA=J("
    "),etA=J(""),ttA=J("
    "),rtA=J("
    "),ntA=J("
    "),Qa=J("
    "),itA=J("
    "),otA=J("
    "),gtA=J(""),QtA=J("
    "),BtA=J("
    "),OF=J(""),atA=J("
    Edit
    "),stA=J("
    "),EtA=J("
    Write
    "),CtA=J("
    "),ItA=J("
    ");function qF(e,A){return!e||!A?[]:(e[A]??[]).filter(r=>r.severity===1).slice(0,3)}function TF(e){return l(Y,{get when(){return e.diagnostics.length>0},get children(){var A=zeA();return M(A,l(Ke,{get each(){return e.diagnostics},children:t=>(()=>{var r=PeA(),n=r.firstChild,i=n.nextSibling,o=i.firstChild,g=o.nextSibling,Q=g.nextSibling,B=Q.nextSibling;B.nextSibling;var a=i.nextSibling;return M(i,()=>t.range.start.line+1,g),M(i,()=>t.range.start.character+1,B),M(a,()=>t.message),r})()})),A}})}const lC={},ltA=100;function ctA(e,A){return e===A?!0:e.length!==A.length?!1:e.every((t,r)=>t===A[r])}function HF(e){const[A,t]=gA(e());let r,n=0;return tA(()=>{const i=e(),o=Date.now(),g=ltA-(o-n);if(g<=0){r&&(clearTimeout(r),r=void 0),n=o,t(i);return}r&&clearTimeout(r),r=setTimeout(()=>{n=Date.now(),t(i),r=void 0},g)}),dA(()=>{r&&clearTimeout(r)}),A}function YF(e,A){return e?A?e.split(A).join(""):e:""}function Ba(e){const A=Zg();return YF(Wo(e),A.directory)}function utA(e,A={}){switch(e){case"read":return{icon:"glasses",title:"Read",subtitle:A.filePath?ut(A.filePath):void 0};case"list":return{icon:"bullet-list",title:"List",subtitle:A.path?ut(A.path):void 0};case"glob":return{icon:"magnifying-glass-menu",title:"Glob",subtitle:A.pattern};case"grep":return{icon:"magnifying-glass-menu",title:"Grep",subtitle:A.pattern};case"webfetch":return{icon:"window-cursor",title:"Webfetch",subtitle:A.url};case"task":return{icon:"task",title:`${A.subagent_type||"task"} Agent`,subtitle:A.description};case"bash":return{icon:"console",title:"Shell",subtitle:A.description};case"edit":return{icon:"code-lines",title:"Edit",subtitle:A.filePath?ut(A.filePath):void 0};case"write":return{icon:"code-lines",title:"Write",subtitle:A.filePath?ut(A.filePath):void 0};case"todowrite":return{icon:"checklist",title:"To-dos"};case"todoread":return{icon:"checklist",title:"Read to-dos"};default:return{icon:"mcp",title:e}}}function zF(e){return l(Je,{get children(){return[l(YA,{get when(){return Ae(()=>e.message.role==="user")()&&e.message},children:A=>l(htA,{get message(){return A()},get parts(){return e.parts}})}),l(YA,{get when(){return Ae(()=>e.message.role==="assistant")()&&e.message},children:A=>l(dtA,{get message(){return A()},get parts(){return e.parts}})})]}})}function dtA(e){const t=S(()=>e.parts.filter(r=>r.type!=="tool"||r.tool!=="todoread"),[],{equals:ctA});return l(Ke,{get each(){return t()},children:r=>l(wc,{part:r,get message(){return e.message}})})}function htA(e){const A=Ht(),t=S(()=>e.parts?.find(B=>B.type==="text"&&!B.synthetic)),r=S(()=>t()?.text||""),n=S(()=>e.parts?.filter(B=>B.type==="file")??[]),i=S(()=>n()?.filter(B=>{const a=B.mime;return a.startsWith("image/")||a==="application/pdf"})),o=S(()=>n().filter(B=>{const a=B.mime;return!a.startsWith("image/")&&a!=="application/pdf"&&B.source?.text?.start!==void 0})),g=S(()=>e.parts?.filter(B=>B.type==="agent")??[]),Q=(B,a)=>{A.show(()=>l(YeA,{src:B,alt:a}))};return(()=>{var B=VeA();return M(B,l(Y,{get when(){return i().length>0},get children(){var a=_eA();return M(a,l(Ke,{get each(){return i()},children:s=>(()=>{var C=ZeA();return C.$$click=()=>{s.mime.startsWith("image/")&&s.url&&Q(s.url,s.filename)},M(C,l(Y,{get when(){return Ae(()=>!!s.mime.startsWith("image/"))()&&s.url},get fallback(){return(()=>{var E=XeA();return M(E,l(Ee,{name:"folder"})),E})()},get children(){var E=WeA();return _A(I=>{var c=s.url,u=s.filename??"attachment";return c!==I.e&&ce(E,"src",I.e=c),u!==I.t&&ce(E,"alt",I.t=u),I},{e:void 0,t:void 0}),E}})),_A(E=>{var I=s.mime.startsWith("image/")?"image":"file",c=s.mime.startsWith("image/")&&!!s.url;return I!==E.e&&ce(C,"data-type",E.e=I),c!==E.t&&ce(C,"data-clickable",E.t=c),E},{e:void 0,t:void 0}),C})()})),a}}),null),M(B,l(Y,{get when(){return r()},get children(){var a=jeA();return M(a,l(DtA,{get text(){return r()},get references(){return o()},get agents(){return g()}})),a}}),null),B})()}function DtA(e){const A=S(()=>{const t=e.text,r=[...e.references.filter(o=>o.source?.text?.start!==void 0&&o.source?.text?.end!==void 0).map(o=>({start:o.source.text.start,end:o.source.text.end,type:"file"})),...e.agents.filter(o=>o.source?.start!==void 0&&o.source?.end!==void 0).map(o=>({start:o.source.start,end:o.source.end,type:"agent"}))].sort((o,g)=>o.start-g.start),n=[];let i=0;for(const o of r)o.starti&&n.push({text:t.slice(i,o.start)}),n.push({text:t.slice(o.start,o.end),type:o.type}),i=o.end);return i(()=>{var r=$eA();return M(r,()=>t.text),_A(n=>{var i=t.type==="file",o=t.type==="agent";return i!==n.e&&r.classList.toggle("text-syntax-property",n.e=i),o!==n.t&&r.classList.toggle("text-syntax-type",n.t=o),n},{e:void 0,t:void 0}),r})()})}function wc(e){const A=S(()=>lC[e.part.type]);return l(Y,{get when(){return A()},get children(){return l(Mn,{get component(){return A()},get part(){return e.part},get message(){return e.message},get hideDetails(){return e.hideDetails},get defaultOpen(){return e.defaultOpen}})}})}const PF={};function ftA(e){return PF[e.name]=e,e}function wtA(e){return PF[e]?.render}const Rr={register:ftA,render:wtA};lC.tool=function(A){const t=Zg(),r=A.part,n=S(()=>{const c=t.store.permission?.[A.message.sessionID]?.[0];if(c&&c.callID===r.callID)return c}),[i,o]=gA(!1);tA(()=>{if(n()){const u=setTimeout(()=>o(!0),50);dA(()=>clearTimeout(u))}else o(!1)});const[g,Q]=gA(!1);tA(()=>{n()&&Q(!0)});const B=c=>{const u=n();!u||!t.respondToPermission||t.respondToPermission({sessionID:u.sessionID,permissionID:u.id,response:c})},a={},s={},C=()=>r.state?.input??a,E=()=>r.state?.metadata??s,I=Rr.render(r.tool)??vF;return(()=>{var c=RF();return M(c,l(Je,{get children(){return[l(YA,{get when(){return Ae(()=>r.state.status==="error")()&&r.state.error},children:u=>{const h=u().replace("Error: ",""),[d,...f]=h.split(": ");return l(fc,{variant:"error",get children(){var m=ttA();return M(m,l(Ee,{name:"circle-ban-sign",size:"small"}),null),M(m,l(Je,{get children(){return[l(YA,{get when(){return d&&d.length<30},get children(){var k=AtA(),N=k.firstChild,F=N.nextSibling;return M(N,d),M(F,()=>f.join(": ")),k}}),l(YA,{when:!0,get children(){var k=etA();return M(k,h),k}})]}}),null),m}})}}),l(YA,{when:!0,get children(){return l(Mn,{component:I,get input(){return C()},get tool(){return r.tool},get metadata(){return E()},get output(){return r.state.output},get status(){return r.state.status},get hideDetails(){return A.hideDetails},get forceOpen(){return g()},get defaultOpen(){return A.defaultOpen}})}})]}}),null),M(c,l(Y,{get when(){return Ae(()=>!!i())()&&n()},get children(){var u=LF(),h=u.firstChild;return M(h,l(ue,{variant:"ghost",size:"small",onClick:()=>B("reject"),children:"Deny"}),null),M(h,l(ue,{variant:"secondary",size:"small",onClick:()=>B("always"),children:"Allow always"}),null),M(h,l(ue,{variant:"primary",size:"small",onClick:()=>B("once"),children:"Allow once"}),null),u}}),null),_A(()=>ce(c,"data-permission",i())),c})()};lC.text=function(A){const t=Zg(),r=A.part,i=HF(()=>YF((r.text??"").trim(),t.directory));return l(Y,{get when(){return i()},get children(){var o=rtA();return M(o,l(ro,{get text(){return i()}})),o}})};lC.reasoning=function(A){const t=A.part,n=HF(()=>t.text.trim());return l(Y,{get when(){return n()},get children(){var i=ntA();return M(i,l(ro,{get text(){return n()}})),i}})};Rr.register({name:"read",render(e){const A=[];return e.input.offset&&A.push("offset="+e.input.offset),e.input.limit&&A.push("limit="+e.input.limit),l(Lr,H(e,{icon:"glasses",get trigger(){return{title:"Read",subtitle:e.input.filePath?ut(e.input.filePath):"",args:A}}}))}});Rr.register({name:"list",render(e){return l(Lr,H(e,{icon:"bullet-list",get trigger(){return{title:"List",subtitle:Ba(e.input.path||"/")}},get children(){return l(Y,{get when(){return e.output},children:A=>(()=>{var t=Qa();return M(t,l(ro,{get text(){return A()}})),t})()})}}))}});Rr.register({name:"glob",render(e){return l(Lr,H(e,{icon:"magnifying-glass-menu",get trigger(){return{title:"Glob",subtitle:Ba(e.input.path||"/"),args:e.input.pattern?["pattern="+e.input.pattern]:[]}},get children(){return l(Y,{get when(){return e.output},children:A=>(()=>{var t=Qa();return M(t,l(ro,{get text(){return A()}})),t})()})}}))}});Rr.register({name:"grep",render(e){const A=[];return e.input.pattern&&A.push("pattern="+e.input.pattern),e.input.include&&A.push("include="+e.input.include),l(Lr,H(e,{icon:"magnifying-glass-menu",get trigger(){return{title:"Grep",subtitle:Ba(e.input.path||"/"),args:A}},get children(){return l(Y,{get when(){return e.output},children:t=>(()=>{var r=Qa();return M(r,l(ro,{get text(){return t()}})),r})()})}}))}});Rr.register({name:"webfetch",render(e){return l(Lr,H(e,{icon:"window-cursor",get trigger(){return{title:"Webfetch",subtitle:e.input.url||"",args:e.input.format?["format="+e.input.format]:[],action:(()=>{var A=itA();return M(A,l(Ee,{name:"square-arrow-top-right",size:"small"})),A})()}},get children(){return l(Y,{get when(){return e.output},children:A=>(()=>{var t=Qa();return M(t,l(ro,{get text(){return A()}})),t})()})}}))}});Rr.register({name:"task",render(e){const A=Zg(),t=()=>e.metadata.summary??[],r=Pu({working:()=>!0}),n=()=>e.metadata.sessionId,i=S(()=>{const B=n();return B?(A.store.permission?.[B]??[])[0]:void 0}),o=S(()=>{const B=i();if(!B)return;const a=n();if(!a)return;const s=A.store.message[a]??[];for(const C of s){const E=A.store.part[C.id]??[];for(const I of E)if(I.type==="tool"&&I.callID===B.callID)return{part:I,message:C}}}),g=B=>{const a=i();!a||!A.respondToPermission||A.respondToPermission({sessionID:a.sessionID,permissionID:a.id,response:B})},Q=()=>{const B=o();if(!B)return null;const{part:a}=B,s=Rr.render(a.tool)??vF,C=a.state?.metadata??{},E=a.state?.input??{};return l(Mn,{component:s,input:E,get tool(){return a.tool},metadata:C,get output(){return a.state.output},get status(){return a.state.status},defaultOpen:!0})};return(()=>{var B=RF();return M(B,l(Je,{get children(){return[l(YA,{get when(){return i()},get children(){return[l(Y,{get when(){return o()},get fallback(){return l(Lr,{icon:"task",defaultOpen:!0,get trigger(){return{title:`${e.input.subagent_type||e.tool} Agent`,titleClass:"capitalize",subtitle:e.input.description}}})},get children(){return Q()}}),(()=>{var a=LF(),s=a.firstChild;return M(s,l(ue,{variant:"ghost",size:"small",onClick:()=>g("reject"),children:"Deny"}),null),M(s,l(ue,{variant:"secondary",size:"small",onClick:()=>g("always"),children:"Allow always"}),null),M(s,l(ue,{variant:"primary",size:"small",onClick:()=>g("once"),children:"Allow once"}),null),a})()]}}),l(YA,{when:!0,get children(){return l(Lr,{icon:"task",defaultOpen:!0,get trigger(){return{title:`${e.input.subagent_type||e.tool} Agent`,titleClass:"capitalize",subtitle:e.input.description}},get children(){var a=otA(),s=a.firstChild;Mo(a,"scroll",r.handleScroll);var C=r.scrollRef;typeof C=="function"?Qt(C,a):r.scrollRef=a;var E=r.contentRef;return typeof E=="function"?Qt(E,s):r.contentRef=s,M(s,l(Ke,{get each(){return t()},children:I=>{const c=utA(I.tool);return(()=>{var u=QtA(),h=u.firstChild;return M(u,l(Ee,{get name(){return c.icon},size:"small"}),h),M(h,()=>c.title),M(u,l(Y,{get when(){return I.state.title},get children(){var d=gtA();return M(d,()=>I.state.title),d}}),null),u})()}})),a}})}})]}})),_A(()=>ce(B,"data-permission",!!i())),B})()}});Rr.register({name:"bash",render(e){return l(Lr,H(e,{icon:"console",get trigger(){return{title:"Shell",subtitle:e.input.description}},get children(){var A=Qa();return M(A,l(ro,{get text(){return`\`\`\`command $ ${e.input.command??e.metadata.command??""}${e.output?` `+e.output:""} \`\`\``}})),A}}))}});Rr.register({name:"edit",render(e){const A=wu(),t=S(()=>qF(e.metadata.diagnostics,e.input.filePath));return l(Lr,H(e,{icon:"code-lines",get trigger(){return(()=>{var r=atA(),n=r.firstChild,i=n.firstChild,o=i.nextSibling,g=o.firstChild,Q=n.nextSibling;return M(o,l(Y,{get when(){return e.input.filePath?.includes("/")},get children(){var B=OF();return M(B,()=>Ba(e.input.filePath)),B}}),g),M(g,()=>ut(e.input.filePath??"")),M(Q,l(Y,{get when(){return e.metadata.filediff},get children(){return l(BQ,{get changes(){return e.metadata.filediff}})}})),r})()},get children(){return[l(Y,{get when(){return e.metadata.filediff?.path||e.input.filePath},get children(){var r=BtA();return M(r,l(Mn,{component:A,get before(){return{name:e.metadata?.filediff?.file||e.input.filePath,contents:e.metadata?.filediff?.before||e.input.oldString,cacheKey:Pi(e.metadata?.filediff?.before||e.input.oldString)}},get after(){return{name:e.metadata?.filediff?.file||e.input.filePath,contents:e.metadata?.filediff?.after||e.input.newString,cacheKey:Pi(e.metadata?.filediff?.after||e.input.newString)}}})),r}}),l(TF,{get diagnostics(){return t()}})]}}))}});Rr.register({name:"write",render(e){const A=qy(),t=S(()=>qF(e.metadata.diagnostics,e.input.filePath));return l(Lr,H(e,{icon:"code-lines",get trigger(){return(()=>{var r=EtA(),n=r.firstChild,i=n.firstChild,o=i.nextSibling,g=o.firstChild;return M(o,l(Y,{get when(){return e.input.filePath?.includes("/")},get children(){var Q=OF();return M(Q,()=>Ba(e.input.filePath)),Q}}),g),M(g,()=>ut(e.input.filePath??"")),r})()},get children(){return[l(Y,{get when(){return e.input.content},get children(){var r=stA();return M(r,l(Mn,{component:A,get file(){return{name:e.input.filePath,contents:e.input.content,cacheKey:Pi(e.input.content)}},overflow:"scroll"})),r}}),l(TF,{get diagnostics(){return t()}})]}}))}});Rr.register({name:"todowrite",render(e){return l(Lr,H(e,{defaultOpen:!0,icon:"checklist",get trigger(){return{title:"To-dos",subtitle:e.input.todos?`${e.input.todos.filter(A=>A.status==="completed").length}/${e.input.todos.length}`:""}},get children(){return l(Y,{get when(){return e.input.todos?.length},get children(){var A=CtA();return M(A,l(Ke,{get each(){return e.input.todos},children:t=>l(ReA,{readOnly:!0,get checked(){return t.status==="completed"},get children(){var r=ItA();return M(r,()=>t.content),_A(()=>ce(r,"data-completed",t.status==="completed")),r}})})),A}})}}))}});or(["click"]);var mtA={};Zt(mtA,{Accordion:()=>CQ,Content:()=>VF,Header:()=>WF,Item:()=>XF,Root:()=>$F,Trigger:()=>Ax,useAccordionContext:()=>Ah});var _F=ye();function jF(){const e=pe(_F);if(e===void 0)throw new Error("[kobalte]: `useAccordionItemContext` must be used within a `Accordion.Item` component");return e}function VF(e){const A=jF(),t=A.generateId("content"),r=OA({id:t},e),[n,i]=eA(r,["id","style"]);return tA(()=>dA(A.registerContentId(n.id))),l(ed,H({role:"region",get"aria-labelledby"(){return A.triggerId()},get style(){return Tt({"--kb-accordion-content-height":"var(--kb-collapsible-content-height)","--kb-accordion-content-width":"var(--kb-collapsible-content-width)"},n.style)}},i))}function WF(e){const A=zB();return l(XA,H({as:"h3"},()=>A.dataset(),e))}var ZF=ye();function Ah(){const e=pe(ZF);if(e===void 0)throw new Error("[kobalte]: `useAccordionContext` must be used within a `Accordion.Root` component");return e}function XF(e){const A=Ah(),t=`${A.generateId("item")}-${je()}`,r=OA({id:t},e),[n,i]=eA(r,["value","disabled"]),[o,g]=gA(),[Q,B]=gA(),a=()=>A.listState().selectionManager(),s=()=>a().isSelected(n.value),C={value:()=>n.value,triggerId:o,contentId:Q,generateId:Gt(()=>i.id),registerTriggerId:ze(g),registerContentId:ze(B)};return l(_F.Provider,{value:C,get children(){return l(td,H({get open(){return s()},get disabled(){return n.disabled}},i))}})}function $F(e){let A;const t=`accordion-${je()}`,r=OA({id:t,multiple:!1,collapsible:!1,shouldFocusWrap:!0},e),[n,i]=eA(r,["id","ref","value","defaultValue","onChange","multiple","collapsible","shouldFocusWrap","onKeyDown","onMouseDown","onFocusIn","onFocusOut"]),[o,g]=gA([]),{DomCollectionProvider:Q}=id({items:o,onItemsChange:g}),B=_B({selectedKeys:()=>n.value,defaultSelectedKeys:()=>n.defaultValue,onSelectionChange:C=>n.onChange?.(Array.from(C)),disallowEmptySelection:()=>!n.multiple&&!n.collapsible,selectionMode:()=>n.multiple?"multiple":"single",dataSource:o});B.selectionManager().setFocusedKey("item-1");const a=nd({selectionManager:()=>B.selectionManager(),collection:()=>B.collection(),disallowEmptySelection:()=>B.selectionManager().disallowEmptySelection(),shouldFocusWrap:()=>n.shouldFocusWrap,disallowTypeAhead:!0,allowsTabNavigation:!0},()=>A),s={listState:()=>B,generateId:Gt(()=>n.id)};return l(Q,{get children(){return l(ZF.Provider,{value:s,get children(){return l(XA,H({as:"div",get id(){return n.id},ref(C){var E=ae(I=>A=I,n.ref);typeof E=="function"&&E(C)},get onKeyDown(){return ge([n.onKeyDown,a.onKeyDown])},get onMouseDown(){return ge([n.onMouseDown,a.onMouseDown])},get onFocusIn(){return ge([n.onFocusIn])},get onFocusOut(){return ge([n.onFocusOut,a.onFocusOut])}},i))}})}})}function Ax(e){let A;const t=Ah(),r=jF(),n=zB(),i=r.generateId("trigger"),o=OA({id:i},e),[g,Q]=eA(o,["ref","onPointerDown","onPointerUp","onClick","onKeyDown","onMouseDown","onFocus"]);od({getItem:()=>({ref:()=>A,type:"item",key:r.value(),textValue:"",disabled:n.disabled()})});const B=PB({key:()=>r.value(),selectionManager:()=>t.listState().selectionManager(),disabled:()=>n.disabled(),shouldSelectOnPressUp:!0},()=>A),a=s=>{["Enter"," "].includes(s.key)&&s.preventDefault(),WA(s,g.onKeyDown),WA(s,B.onKeyDown)};return tA(()=>dA(r.registerTriggerId(Q.id))),l(rd,H({ref(s){var C=ae(E=>A=E,g.ref);typeof C=="function"&&C(s)},get"data-key"(){return B.dataKey()},get onPointerDown(){return ge([g.onPointerDown,B.onPointerDown])},get onPointerUp(){return ge([g.onPointerUp,B.onPointerUp])},get onClick(){return ge([g.onClick,B.onClick])},onKeyDown:a,get onMouseDown(){return ge([g.onMouseDown,B.onMouseDown])},get onFocus(){return ge([g.onFocus,B.onFocus])}},Q))}var CQ=Object.assign($F,{Content:VF,Header:WF,Item:XF,Trigger:Ax});function ptA(e){const[A,t]=eA(e,["class","classList"]);return l(CQ,H(t,{"data-component":"accordion",get classList(){return{...A.classList??{},[A.class??""]:!!A.class}}}))}function ktA(e){const[A,t]=eA(e,["class","classList"]);return l(CQ.Item,H(t,{"data-slot":"accordion-item",get classList(){return{...A.classList??{},[A.class??""]:!!A.class}}}))}function ytA(e){const[A,t]=eA(e,["class","classList","children"]);return l(CQ.Header,H(t,{"data-slot":"accordion-header",get classList(){return{...A.classList??{},[A.class??""]:!!A.class}},get children(){return A.children}}))}function MtA(e){const[A,t]=eA(e,["class","classList","children"]);return l(CQ.Trigger,H(t,{"data-slot":"accordion-trigger",get classList(){return{...A.classList??{},[A.class??""]:!!A.class}},get children(){return A.children}}))}function NtA(e){const[A,t]=eA(e,["class","classList","children"]);return l(CQ.Content,H(t,{"data-slot":"accordion-content",get classList(){return{...A.classList??{},[A.class??""]:!!A.class}},get children(){return A.children}}))}const Vn=Object.assign(ptA,{Item:ktA,Header:ytA,Trigger:MtA,Content:NtA});function ex(e){return l(Vn.Header,{"data-component":"sticky-accordion-header",get classList(){return{...e.classList??{},[e.class??""]:!!e.class}},get children(){return e.children}})}var vtA=J("
    "),btA=J("

    "),FtA=J("
    "),xtA=J("
    "),GtA=J(""),StA=J("· retrying "),JtA=J("(#)"),UtA=J("·"),KtA=J(""),LtA=J("
    "),RtA=J("
    "),OtA=J("
    "),qtA=J("

    Response"),TtA=J("
    "),HtA=J("‎"),YtA=J("
    ");function sm(e){if(e){if(e.type==="tool")switch(e.tool){case"task":return"Delegating work";case"todowrite":case"todoread":return"Planning next steps";case"read":return"Gathering context";case"list":case"grep":case"glob":return"Searching the codebase";case"webfetch":return"Searching the web";case"edit":case"write":return"Making edits";case"bash":return"Running commands";default:return}if(e.type==="reasoning"){const t=(e.text??"").trimStart().match(/^\*\*(.+?)\*\*/);return t?`Thinking · ${t[1].trim()}`:"Thinking"}if(e.type==="text")return"Gathering thoughts"}}function ztA(e,A){return e===A?!0:e.length!==A.length?!1:e.every((t,r)=>t===A[r])}function PtA(e){const A=Zg(),t=[],r=S(()=>A.store.part[e.message.id]??t),n=S(()=>{const o=r();for(let g=o.length-1;g>=0;g--){const Q=o[g];if(Q?.type==="text")return Q}}),i=S(()=>{let o=r();if(e.hideReasoning&&(o=o.filter(Q=>Q?.type!=="reasoning")),!e.hideResponsePart)return o;const g=e.responsePartId;return!g||g!==n()?.id?o:o.filter(Q=>Q?.id!==g)});return l(zF,{get message(){return e.message},get parts(){return i()}})}function Em(e){const A=Zg(),t=wu(),r=[],n=[],i=[],o=[],g=[],Q={type:"idle"},B=S(()=>A.store.message[e.sessionID]??r),a=S(()=>{const z=B(),q=vt.search(z,e.messageID,rA=>rA.id);return!q.found||z[q.index].role!=="user"?-1:q.index}),s=S(()=>{const z=a();if(z<0)return;const q=B()[z];if(!(!q||q.role!=="user"))return q}),C=S(()=>{if(e.lastUserMessageID)return e.lastUserMessageID;const z=B();for(let q=z.length-1;q>=0;q--){const sA=z[q];if(sA?.role==="user")return sA.id}}),E=S(()=>e.messageID===C()),I=S(()=>{const z=s();return z?A.store.part[z.id]??n:n}),c=S(()=>{const z=s();if(!z)return i;const q=B(),sA=a();if(sA<0)return i;const rA=[];for(let V=sA+1;Vc().at(-1)),h=S(()=>c().find(z=>z.error)?.error),d=S(()=>{const z=c();for(let q=z.length-1;q>=0;q--){const sA=A.store.part[z[q].id]??n;for(let rA=sA.length-1;rA>=0;rA--){const V=sA[rA];if(V?.type==="text")return V}}}),f=S(()=>{for(const z of c()){const q=A.store.part[z.id];if(q){for(const sA of q)if(sA?.type==="tool")return!0}}return!1}),m=S(()=>A.store.permission?.[e.sessionID]??o),k=S(()=>m().length),N=S(()=>m()[0]),F=S(()=>{if(e.stepsExpanded)return g;const z=N();if(!z)return g;for(const q of c()){const sA=A.store.part[q.id]??n;for(const rA of sA){if(rA?.type!=="tool")continue;const V=rA;if(V.callID===z.callID)return[{part:V,message:q}]}}return g}),L=S(()=>{if(!I().every(V=>V?.type==="text"&&V?.synthetic))return;const q=c();if(q.length!==1)return;const sA=A.store.part[q[0].id]??n;if(sA.length!==1)return;const rA=sA[0];if(rA?.type==="tool"&&rA.tool==="bash")return rA}),v=S(()=>!!L()),O=S(()=>{const z=c();let q,sA;for(let V=z.length-1;V>=0;V--){const cA=A.store.part[z[V].id]??n;for(let IA=cA.length-1;IA>=0;IA--){const wA=cA[IA];if(wA&&(q||(q=wA),wA.type==="tool"&&wA.tool==="task"&&wA.state&&"metadata"in wA.state&&wA.state.metadata?.sessionId&&wA.state.status==="running")){sA=wA;break}}if(sA)break}const rA=sA?.state&&"metadata"in sA.state?sA.state.metadata?.sessionId:void 0;if(rA){const V=A.store.message[rA]??r;for(let cA=V.length-1;cA>=0;cA--){const IA=V[cA];if(!IA||IA.role!=="assistant")continue;const wA=A.store.part[IA.id]??n;for(let yA=wA.length-1;yA>=0;yA--){const PA=wA[yA];if(PA)return sm(PA)}}}return sm(q)}),W=S(()=>A.store.session_status[e.sessionID]??Q),AA=S(()=>W().type!=="idle"&&E()),kA=S(()=>{const z=W();if(z.type==="retry")return z}),K=S(()=>d()?.text),$=S(()=>d()?.id),P=S(()=>s()?.summary?.diffs?.length),SA=S(()=>!AA()&&!!$());function fA(){const z=s();if(!z)return"";const q=u()?.time.completed,sA=ne.fromMillis(z.time.created),rA=q?ne.fromMillis(q):ne.now(),V=ot.fromDateTimes(sA,rA),cA=V.length("seconds")>60?["minutes","seconds"]:["seconds"];return V.toDuration(cA).normalize().toHuman({notation:"compact",unitDisplay:"narrow",compactDisplay:"short",showZeros:!1})}const MA=Pu({working:AA,onUserInteracted:e.onUserInteracted}),[mA,$A]=xe({stickyTitleRef:void 0,stickyTriggerRef:void 0,stickyHeaderHeight:0,retrySeconds:0,status:O(),duration:fA()});tA(()=>{const z=kA();if(!z){$A("retrySeconds",0);return}const q=()=>{const rA=z.next;rA&&$A("retrySeconds",Math.max(0,Math.round((rA-Date.now())/1e3)))};q();const sA=setInterval(q,1e3);dA(()=>clearInterval(sA))}),CB(()=>mA.stickyTitleRef,({height:z})=>{const q=mA.stickyTriggerRef?.offsetHeight??0;$A("stickyHeaderHeight",z+q+8)}),CB(()=>mA.stickyTriggerRef,({height:z})=>{const q=mA.stickyTitleRef?.offsetHeight??0;$A("stickyHeaderHeight",q+z+8)}),tA(()=>{const z=setInterval(()=>{$A("duration",fA())},1e3);dA(()=>clearInterval(z))}),tA(be(k,(z,q)=>{z&&(q!==void 0&&z<=q||MA.forceScrollToBottom())}));let re=Date.now(),de;return tA(()=>{const z=O();if(z===mA.status||!z)return;const q=Date.now()-re;q>=2500?($A("status",z),re=Date.now(),de&&(clearTimeout(de),de=void 0)):(de&&clearTimeout(de),de=setTimeout(()=>{$A("status",O()),re=Date.now(),de=void 0},2500-q))}),(()=>{var z=vtA(),q=z.firstChild,sA=q.firstChild;Mo(q,"scroll",MA.handleScroll);var rA=MA.scrollRef;return typeof rA=="function"?Qt(rA,q):MA.scrollRef=q,Mo(sA,"click",MA.handleInteraction,!0),M(sA,l(Y,{get when(){return s()},children:V=>(()=>{var cA=TtA(),IA=MA.contentRef;return typeof IA=="function"?Qt(IA,cA):MA.contentRef=cA,M(cA,l(Je,{get children(){return[l(YA,{get when(){return v()},get children(){return l(wc,{get part(){return L()},get message(){return V()},defaultOpen:!0})}}),l(YA,{when:!0,get children(){return[(()=>{var wA=FtA(),yA=wA.firstChild,PA=yA.firstChild;return Qt(Z=>$A("stickyTitleRef",Z),wA),M(PA,l(Je,{get children(){return[l(YA,{get when(){return AA()},get children(){return l(NeA,{as:"h1",get text(){return V().summary?.title},"data-slot":"session-turn-typewriter"})}}),l(YA,{when:!0,get children(){var Z=btA();return M(Z,()=>V().summary?.title),Z}})]}})),wA})(),(()=>{var wA=xtA();return M(wA,l(zF,{get message(){return V()},get parts(){return I()}})),wA})(),l(Y,{get when(){return AA()||f()},get children(){var wA=LtA();return Qt(yA=>$A("stickyTriggerRef",yA),wA),M(wA,l(ue,{get"data-expandable"(){return c().length>0},"data-slot":"session-turn-collapsible-trigger-content",variant:"ghost",size:"small",get onClick(){return e.onStepsExpandedToggle??(()=>{})},get children(){return[l(Y,{get when(){return AA()},get children(){return l(_s,{})}}),l(Je,{get children(){return[l(YA,{get when(){return kA()},get children(){return[(()=>{var yA=GtA();return M(yA,()=>{const PA=kA();return PA?PA.message.length>60?PA.message.slice(0,60)+"...":PA.message:""}),yA})(),(()=>{var yA=StA();return yA.firstChild,M(yA,(()=>{var PA=Ae(()=>mA.retrySeconds>0);return()=>PA()?`in ${mA.retrySeconds}s `:""})(),null),yA})(),(()=>{var yA=JtA(),PA=yA.firstChild,Z=PA.nextSibling;return Z.nextSibling,M(yA,()=>kA()?.attempt,Z),yA})()]}}),l(YA,{get when(){return AA()},get children(){return mA.status??"Considering next steps"}}),l(YA,{get when(){return e.stepsExpanded},children:"Hide steps"}),l(YA,{get when(){return!e.stepsExpanded},children:"Show steps"})]}}),UtA(),(()=>{var yA=KtA();return M(yA,()=>mA.duration),yA})(),l(Y,{get when(){return c().length>0},get children(){return l(Ee,{name:"chevron-grabber-vertical",size:"small"})}})]}})),wA}}),l(Y,{get when(){return Ae(()=>!!e.stepsExpanded)()&&c().length>0},get children(){var wA=RtA();return M(wA,l(Ke,{get each(){return c()},children:yA=>l(PtA,{message:yA,get responsePartId(){return $()},get hideResponsePart(){return SA()},get hideReasoning(){return!AA()}})}),null),M(wA,l(Y,{get when(){return h()},get children(){return l(fc,{variant:"error",class:"error-card",get children(){return h()?.data?.message}})}}),null),wA}}),l(Y,{get when(){return Ae(()=>!e.stepsExpanded)()&&F().length>0},get children(){var wA=OtA();return M(wA,l(Ke,{get each(){return F()},children:({part:yA,message:PA})=>l(wc,{part:yA,message:PA})})),wA}}),l(Y,{get when(){return Ae(()=>!AA())()&&(K()||P())},get children(){var wA=qtA(),yA=wA.firstChild;return yA.firstChild,M(yA,l(ro,{"data-slot":"session-turn-markdown",get"data-diffs"(){return P()},get text(){return K()??""}}),null),M(wA,l(Vn,{"data-slot":"session-turn-accordion",multiple:!0,get children(){return l(Ke,{get each(){return V().summary?.diffs??[]},children:PA=>l(Vn.Item,{get value(){return PA.file},get children(){return[l(ex,{get children(){return l(Vn.Trigger,{get children(){var Z=YtA(),x=Z.firstChild,j=x.firstChild,nA=j.firstChild,EA=x.nextSibling;return M(x,l(aQ,{get node(){return{path:PA.file,type:"file"}},"data-slot":"session-turn-file-icon"}),j),M(j,l(Y,{get when(){return PA.file.includes("/")},get children(){var BA=HtA(),FA=BA.firstChild;return M(BA,()=>Wo(PA.file),FA),BA}}),nA),M(nA,()=>ut(PA.file)),M(EA,l(BQ,{changes:PA}),null),M(EA,l(Ee,{name:"chevron-grabber-vertical",size:"small"}),null),Z}})}}),l(Vn.Content,{"data-slot":"session-turn-accordion-content",get children(){return l(Mn,{component:t,get before(){return{name:PA.file,contents:PA.before,cacheKey:Pi(PA.before)}},get after(){return{name:PA.file,contents:PA.after,cacheKey:Pi(PA.after)}}})}})]}})})}}),null),wA}}),l(Y,{get when(){return Ae(()=>!!h())()&&!e.stepsExpanded},get children(){return l(fc,{variant:"error",class:"error-card",get children(){return h()?.data?.message}})}})]}})]}})),_A(wA=>{var yA=V().id,PA=e.classes?.container,Z=`${mA.stickyHeaderHeight}px`;return yA!==wA.e&&ce(cA,"data-message",wA.e=yA),PA!==wA.t&&HQ(cA,wA.t=PA),Z!==wA.a&&No(cA,"--sticky-header-height",wA.a=Z),wA},{e:void 0,t:void 0,a:void 0}),cA})()}),null),M(sA,()=>e.children,null),_A(V=>{var cA=e.classes?.root,IA=e.classes?.content;return cA!==V.e&&HQ(z,V.e=cA),IA!==V.t&&HQ(q,V.t=IA),V},{e:void 0,t:void 0}),z})()}or(["click"]);var _tA=J("
      "),jtA=J("
      "),VtA=J("
      '),tnA=J('
      '),Dm=J('
      '),rnA=J("M"),nnA=J("A"),inA=J("D"),onA=J('