@wes-dev/pr 0.0.1 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (81) hide show
  1. package/CHANGELOG.md +33 -0
  2. package/README.md +10 -3
  3. package/dist/cli/index.js +57 -53
  4. package/dist/web/assets/{angular-html-Dy5TOb5M.js → angular-html-CNvA1zuH.js} +1 -1
  5. package/dist/web/assets/{angular-ts-CQ-VvwG4.js → angular-ts-Dcg1rXQO.js} +1 -1
  6. package/dist/web/assets/{apl-DLPyOpzA.js → apl-BYz5Hf2u.js} +1 -1
  7. package/dist/web/assets/{astro-Bg8eE3kY.js → astro-BNmm5iKB.js} +1 -1
  8. package/dist/web/assets/{blade-kDLtazTS.js → blade-DTAhJcAo.js} +1 -1
  9. package/dist/web/assets/{c-LLHuKvL1.js → c-JnETbbKh.js} +1 -1
  10. package/dist/web/assets/{cobol-KB1NrS7u.js → cobol-Dx8Ds744.js} +1 -1
  11. package/dist/web/assets/{coffee-BIVXoYBq.js → coffee-BkM4PUni.js} +1 -1
  12. package/dist/web/assets/{cpp-t-AOohLk.js → cpp-s7_JoZay.js} +1 -1
  13. package/dist/web/assets/{crystal-Siw7Sgsi.js → crystal-TjVXravD.js} +1 -1
  14. package/dist/web/assets/{css-C4JxYney.js → css-rsgUYxyr.js} +1 -1
  15. package/dist/web/assets/{edge-DWGhPgzT.js → edge-_LaVreSG.js} +1 -1
  16. package/dist/web/assets/{elixir-CRNPk2CS.js → elixir-CyNdviVP.js} +1 -1
  17. package/dist/web/assets/{elm-wtHW2ZzC.js → elm-JLPHqmtW.js} +1 -1
  18. package/dist/web/assets/{erb-zY-7xODc.js → erb-BxPqG309.js} +1 -1
  19. package/dist/web/assets/{git-rebase-DryBRQqt.js → git-rebase-DH0tcug9.js} +1 -1
  20. package/dist/web/assets/{glimmer-js-C1lI2oOe.js → glimmer-js-CadjWt9T.js} +1 -1
  21. package/dist/web/assets/{glimmer-ts-w8P2a6UH.js → glimmer-ts-BQwOnUiC.js} +1 -1
  22. package/dist/web/assets/{glsl-BOGqvuHx.js → glsl-DgEkB9wq.js} +1 -1
  23. package/dist/web/assets/{graphql-CMxvykwD.js → graphql-CkxNJin1.js} +1 -1
  24. package/dist/web/assets/{hack-BTJt-rSc.js → hack-Cx2aeoPG.js} +1 -1
  25. package/dist/web/assets/{haml-CpShFG-s.js → haml-6qfsyyuG.js} +1 -1
  26. package/dist/web/assets/{handlebars-BsUSmFng.js → handlebars-Dl2NJIlT.js} +1 -1
  27. package/dist/web/assets/{html-efT10kNy.js → html-D1zwS_Y6.js} +1 -1
  28. package/dist/web/assets/{html-derivative-DslI7lKP.js → html-derivative-JnsLWsez.js} +1 -1
  29. package/dist/web/assets/{http-DGneOSH7.js → http-OKR1Yox5.js} +1 -1
  30. package/dist/web/assets/{hurl-D7wxeizR.js → hurl-Dp_r9svp.js} +1 -1
  31. package/dist/web/assets/index-BUkgurE_.css +1 -0
  32. package/dist/web/assets/index-CWyZ6XRx.js +2898 -0
  33. package/dist/web/assets/{java-DRV6EAgN.js → java-aami8pBq.js} +1 -1
  34. package/dist/web/assets/{javascript-VqTwarqZ.js → javascript-BPWrhnX-.js} +1 -1
  35. package/dist/web/assets/{jinja-B0K-1eZW.js → jinja-C6if9zLU.js} +1 -1
  36. package/dist/web/assets/{jison-C6X_CrUT.js → jison-7oFp1xmT.js} +1 -1
  37. package/dist/web/assets/{json-BMTvgpRj.js → json-NWlrVqIA.js} +1 -1
  38. package/dist/web/assets/{jsx-BdBaYpud.js → jsx-BarzqCx-.js} +1 -1
  39. package/dist/web/assets/{julia-eSoxcKep.js → julia-Dno5JaFH.js} +1 -1
  40. package/dist/web/assets/{just-BMl4E389.js → just-CMC5pFEz.js} +1 -1
  41. package/dist/web/assets/{latex-vrLDptzo.js → latex-CrkA4r_Y.js} +1 -1
  42. package/dist/web/assets/{liquid-DhiVbfmF.js → liquid-CEefn5av.js} +1 -1
  43. package/dist/web/assets/{lua-BZarQnS9.js → lua-D2x5jth8.js} +1 -1
  44. package/dist/web/assets/{marko-BWPwdtQS.js → marko-Bg0EO4kh.js} +1 -1
  45. package/dist/web/assets/{mdc-Cx_ikHJA.js → mdc-LycNcJIc.js} +1 -1
  46. package/dist/web/assets/{nginx-iNlDtGB5.js → nginx-BXD3-aNx.js} +1 -1
  47. package/dist/web/assets/{nim-DGF5L7xM.js → nim-CVCKLhAN.js} +1 -1
  48. package/dist/web/assets/{perl-CFfHYoph.js → perl-BBOoylGj.js} +1 -1
  49. package/dist/web/assets/{php-CtPBh1K5.js → php-DC7DWNj0.js} +1 -1
  50. package/dist/web/assets/{pug-CxRWcKXx.js → pug-9a4nUMn2.js} +1 -1
  51. package/dist/web/assets/{qml-CQ8J3wuq.js → qml-CD7Jztqi.js} +1 -1
  52. package/dist/web/assets/{r-CItjESd8.js → r-zQcActoX.js} +1 -1
  53. package/dist/web/assets/{razor-BPkkINsq.js → razor--BGs0ioE.js} +1 -1
  54. package/dist/web/assets/{regexp-DX3MNthO.js → regexp-C7E19l_4.js} +1 -1
  55. package/dist/web/assets/{rst-ClRAjKbC.js → rst-DVAvGLqu.js} +1 -1
  56. package/dist/web/assets/{ruby-CgYgA9Jj.js → ruby-DrWWnDsD.js} +1 -1
  57. package/dist/web/assets/{sas-CPmYLbzU.js → sas-B0L4vbPF.js} +1 -1
  58. package/dist/web/assets/{scss-Cm-sHo09.js → scss-LHue-ciZ.js} +1 -1
  59. package/dist/web/assets/{shellscript-DmaaF0b7.js → shellscript-COL3-ob8.js} +1 -1
  60. package/dist/web/assets/{shellsession-CQx7VqyU.js → shellsession-Dh9ePmCl.js} +1 -1
  61. package/dist/web/assets/{soy-B_yUNzV2.js → soy-BXy9DlYu.js} +1 -1
  62. package/dist/web/assets/{sql-BJHohXqk.js → sql-I-LlvQU6.js} +1 -1
  63. package/dist/web/assets/{stata-UAFrzABU.js → stata-_NdjQJlR.js} +1 -1
  64. package/dist/web/assets/{surrealql-CWvgOHzZ.js → surrealql-KFhJ-vKU.js} +1 -1
  65. package/dist/web/assets/{svelte-BddkVZXj.js → svelte-BzRTBlZL.js} +1 -1
  66. package/dist/web/assets/{templ-C84Bu3va.js → templ-wEb1pleG.js} +1 -1
  67. package/dist/web/assets/{tex-RrP2i1xH.js → tex-6jA6UkGw.js} +1 -1
  68. package/dist/web/assets/{ts-tags-BRr3h9RL.js → ts-tags-CL6-c_t0.js} +1 -1
  69. package/dist/web/assets/{tsx-CzdrIvPO.js → tsx-CrJYZX0i.js} +1 -1
  70. package/dist/web/assets/{twig-CibPnSwR.js → twig-BQr0H8S_.js} +1 -1
  71. package/dist/web/assets/{typescript-CWzslnac.js → typescript-Pf82UNjk.js} +1 -1
  72. package/dist/web/assets/{vue-C-b1or0S.js → vue-a0DDumRw.js} +1 -1
  73. package/dist/web/assets/{vue-html-B7qsQ7no.js → vue-html-mS0LX1Q6.js} +1 -1
  74. package/dist/web/assets/{vue-vine-dqyrjuMF.js → vue-vine-BuqblR0E.js} +1 -1
  75. package/dist/web/assets/{xml-CG7JAl4q.js → xml-BCSi99jg.js} +1 -1
  76. package/dist/web/assets/{xsl-DE3Ct1nt.js → xsl-SABzfGmn.js} +1 -1
  77. package/dist/web/assets/{yaml-76tnpMFk.js → yaml-CT1I4qT1.js} +1 -1
  78. package/dist/web/index.html +2 -2
  79. package/package.json +3 -1
  80. package/dist/web/assets/index-CuLPuzv1.js +0 -2825
  81. package/dist/web/assets/index-dvXjNgUr.css +0 -1
@@ -0,0 +1,2898 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/angular-html-CNvA1zuH.js","assets/html-D1zwS_Y6.js","assets/javascript-BPWrhnX-.js","assets/css-rsgUYxyr.js","assets/angular-ts-Dcg1rXQO.js","assets/scss-LHue-ciZ.js","assets/apl-BYz5Hf2u.js","assets/xml-BCSi99jg.js","assets/java-aami8pBq.js","assets/json-NWlrVqIA.js","assets/astro-BNmm5iKB.js","assets/typescript-Pf82UNjk.js","assets/postcss-BXeXVLqQ.js","assets/tsx-CrJYZX0i.js","assets/blade-DTAhJcAo.js","assets/html-derivative-JnsLWsez.js","assets/sql-I-LlvQU6.js","assets/bsl-BkkzgIyY.js","assets/sdbl-bTVj8UrX.js","assets/cairo-DLTphjLi.js","assets/python-gzcpVVnB.js","assets/cobol-Dx8Ds744.js","assets/coffee-BkM4PUni.js","assets/cpp-s7_JoZay.js","assets/regexp-C7E19l_4.js","assets/glsl-DgEkB9wq.js","assets/c-JnETbbKh.js","assets/crystal-TjVXravD.js","assets/shellscript-COL3-ob8.js","assets/edge-_LaVreSG.js","assets/elixir-CyNdviVP.js","assets/elm-JLPHqmtW.js","assets/erb-BxPqG309.js","assets/ruby-DrWWnDsD.js","assets/haml-6qfsyyuG.js","assets/graphql-CkxNJin1.js","assets/jsx-BarzqCx-.js","assets/lua-D2x5jth8.js","assets/yaml-CT1I4qT1.js","assets/erlang-Cphh6RMH.js","assets/markdown-BYOwaDjH.js","assets/fortran-fixed-form-DEKoE2YW.js","assets/fortran-free-form-CYNrtFtB.js","assets/fsharp-D13ZGOAj.js","assets/gdresource-C0sCabJj.js","assets/gdshader-CBce3t8t.js","assets/gdscript-Cp2uCuqX.js","assets/git-commit-BSykSTBG.js","assets/diff-woXpYk--.js","assets/git-rebase-DH0tcug9.js","assets/glimmer-js-CadjWt9T.js","assets/glimmer-ts-BQwOnUiC.js","assets/hack-Cx2aeoPG.js","assets/handlebars-Dl2NJIlT.js","assets/http-OKR1Yox5.js","assets/hurl-Dp_r9svp.js","assets/csv-Dx-8-gkx.js","assets/hxml-B0Qn7Nwc.js","assets/haxe-OTjmBuCE.js","assets/jinja-C6if9zLU.js","assets/jison-7oFp1xmT.js","assets/julia-Dno5JaFH.js","assets/r-zQcActoX.js","assets/just-CMC5pFEz.js","assets/perl-BBOoylGj.js","assets/latex-CrkA4r_Y.js","assets/tex-6jA6UkGw.js","assets/liquid-CEefn5av.js","assets/marko-Bg0EO4kh.js","assets/less-DVTAwKKz.js","assets/mdc-LycNcJIc.js","assets/nextflow-BJtWHP5T.js","assets/nextflow-groovy-DJMQeKeT.js","assets/nginx-BXD3-aNx.js","assets/nim-CVCKLhAN.js","assets/php-DC7DWNj0.js","assets/pug-9a4nUMn2.js","assets/qml-CD7Jztqi.js","assets/razor--BGs0ioE.js","assets/csharp-oqKa8noW.js","assets/rst-DVAvGLqu.js","assets/cmake-Bj61d0ZC.js","assets/sas-B0L4vbPF.js","assets/shaderlab-TOUzSsQk.js","assets/hlsl-Cvrh5tZx.js","assets/shellsession-Dh9ePmCl.js","assets/soy-BXy9DlYu.js","assets/sparql-D_iOobhT.js","assets/turtle-ByJddavk.js","assets/stata-_NdjQJlR.js","assets/surrealql-KFhJ-vKU.js","assets/svelte-BzRTBlZL.js","assets/templ-wEb1pleG.js","assets/go-rLFTqkRN.js","assets/ts-tags-CL6-c_t0.js","assets/twig-BQr0H8S_.js","assets/vue-a0DDumRw.js","assets/vue-html-mS0LX1Q6.js","assets/vue-vine-BuqblR0E.js","assets/stylus-B6D30XZt.js","assets/xsl-SABzfGmn.js"])))=>i.map(i=>d[i]);
2
+ var e=Object.defineProperty,t=(t,n)=>{let r={};for(var i in t)e(r,i,{get:t[i],enumerable:!0});return n||e(r,Symbol.toStringTag,{value:`Module`}),r};(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),e.crossOrigin===`use-credentials`?t.credentials=`include`:e.crossOrigin===`anonymous`?t.credentials=`omit`:t.credentials=`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var n={context:void 0,registry:void 0,effects:void 0,done:!1,getContextId(){return r(this.context.count)},getNextContextId(){return r(this.context.count++)}};function r(e){let t=String(e),r=t.length-1;return n.context.id+(r?String.fromCharCode(96+r):``)+t}function i(e){n.context=e}function a(){return{...n.context,id:n.getNextContextId(),count:0}}var o=(e,t)=>e===t,s=Symbol(`solid-track`),c={equals:o},l=null,u=ce,d=1,f=2,p={owned:null,cleanups:null,context:null,owner:null},m=null,h=null,g=null,_=null,v=null,y=null,b=null,x=0;function S(e,t){let n=v,r=m,i=e.length===0,a=t===void 0?r:t,o=i?p:{owned:null,cleanups:null,context:a?a.context:null,owner:a},s=i?e:()=>e(()=>O(()=>fe(o)));m=o,v=null;try{return L(s,!0)}finally{v=n,m=r}}function C(e,t){t=t?Object.assign({},c,t):c;let n={value:e,observers:null,observerSlots:null,comparator:t.equals||void 0};return[re.bind(n),e=>(typeof e==`function`&&(e=h&&h.running&&h.sources.has(n)?e(n.tValue):e(n.value)),ie(n,e))]}function w(e,t,n){let r=F(e,t,!1,d);g&&h&&h.running?y.push(r):ae(r)}function T(e,t,n){u=ue;let r=F(e,t,!1,d),i=P&&te(P);i&&(r.suspense=i),(!n||!n.render)&&(r.user=!0),b?b.push(r):ae(r)}function E(e,t,n){n=n?Object.assign({},c,n):c;let r=F(e,t,!0,0);return r.observers=null,r.observerSlots=null,r.comparator=n.equals||void 0,g&&h&&h.running?(r.tState=d,y.push(r)):ae(r),re.bind(r)}function D(e){return L(e,!1)}function O(e){if(!_&&v===null)return e();let t=v;v=null;try{return _?_.untrack(e):e()}finally{v=t}}function ee(e){T(()=>O(e))}function k(e){return m===null||(m.cleanups===null?m.cleanups=[e]:m.cleanups.push(e)),e}function A(e){if(h&&h.running)return e(),h.done;let t=v,n=m;return Promise.resolve().then(()=>{v=t,m=n;let r;return(g||P)&&(r=h||={sources:new Set,effects:[],promises:new Set,disposed:new Set,queue:new Set,running:!0},r.done||=new Promise(e=>r.resolve=e),r.running=!0),L(e,!1),v=m=null,r?r.done:void 0})}var[j,M]=C(!1);function N(e,t){let n=Symbol(`context`);return{id:n,Provider:ve(n),defaultValue:e}}function te(e){let t;return m&&m.context&&(t=m.context[e.id])!==void 0?t:e.defaultValue}function ne(e){let t=E(e),n=E(()=>_e(t()));return n.toArray=()=>{let e=n();return Array.isArray(e)?e:e==null?[]:[e]},n}var P;function re(){let e=h&&h.running;if(this.sources&&(e?this.tState:this.state))if((e?this.tState:this.state)===d)ae(this);else{let e=y;y=null,L(()=>de(this),!1),y=e}if(v){let e=this.observers;if(!e||e[e.length-1]!==v){let t=e?e.length:0;v.sources?(v.sources.push(this),v.sourceSlots.push(t)):(v.sources=[this],v.sourceSlots=[t]),e?(e.push(v),this.observerSlots.push(v.sources.length-1)):(this.observers=[v],this.observerSlots=[v.sources.length-1])}}return e&&h.sources.has(this)?this.tValue:this.value}function ie(e,t,n){let r=h&&h.running&&h.sources.has(e)?e.tValue:e.value;if(!e.comparator||!e.comparator(r,t)){if(h){let r=h.running;(r||!n&&h.sources.has(e))&&(h.sources.add(e),e.tValue=t),r||(e.value=t)}else e.value=t;e.observers&&e.observers.length&&L(()=>{for(let t=0;t<e.observers.length;t+=1){let n=e.observers[t],r=h&&h.running;r&&h.disposed.has(n)||((r?!n.tState:!n.state)&&(n.pure?y.push(n):b.push(n),n.observers&&R(n)),r?n.tState=d:n.state=d)}if(y.length>1e6)throw y=[],Error()},!1)}return t}function ae(e){if(!e.fn)return;fe(e);let t=x;oe(e,h&&h.running&&h.sources.has(e)?e.tValue:e.value,t),h&&!h.running&&h.sources.has(e)&&queueMicrotask(()=>{L(()=>{h&&(h.running=!0),v=m=e,oe(e,e.tValue,t),v=m=null},!1)})}function oe(e,t,n){let r,i=m,a=v;v=m=e;try{r=e.fn(t)}catch(t){return e.pure&&(h&&h.running?(e.tState=d,e.tOwned&&e.tOwned.forEach(fe),e.tOwned=void 0):(e.state=d,e.owned&&e.owned.forEach(fe),e.owned=null)),e.updatedAt=n+1,ge(t)}finally{v=a,m=i}(!e.updatedAt||e.updatedAt<=n)&&(e.updatedAt!=null&&`observers`in e?ie(e,r,!0):h&&h.running&&e.pure?(h.sources.has(e)||(e.value=r),h.sources.add(e),e.tValue=r):e.value=r,e.updatedAt=n)}function F(e,t,n,r=d,i){let a={fn:e,state:r,updatedAt:null,owned:null,sources:null,sourceSlots:null,cleanups:null,value:t,owner:m,context:m?m.context:null,pure:n};if(h&&h.running&&(a.state=0,a.tState=r),m===null||m!==p&&(h&&h.running&&m.pure?m.tOwned?m.tOwned.push(a):m.tOwned=[a]:m.owned?m.owned.push(a):m.owned=[a]),_&&a.fn){let e=a.fn,[t,n]=C(void 0,{equals:!1}),r=_.factory(e,n);k(()=>r.dispose());let i,o=()=>A(n).then(()=>{i&&=(i.dispose(),void 0)});a.fn=n=>(t(),h&&h.running?(i||=_.factory(e,o),i.track(n)):r.track(n))}return a}function I(e){let t=h&&h.running;if((t?e.tState:e.state)===0)return;if((t?e.tState:e.state)===f)return de(e);if(e.suspense&&O(e.suspense.inFallback))return e.suspense.effects.push(e);let n=[e];for(;(e=e.owner)&&(!e.updatedAt||e.updatedAt<x);){if(t&&h.disposed.has(e))return;(t?e.tState:e.state)&&n.push(e)}for(let r=n.length-1;r>=0;r--){if(e=n[r],t){let t=e,i=n[r+1];for(;(t=t.owner)&&t!==i;)if(h.disposed.has(t))return}if((t?e.tState:e.state)===d)ae(e);else if((t?e.tState:e.state)===f){let t=y;y=null,L(()=>de(e,n[0]),!1),y=t}}}function L(e,t){if(y)return e();let n=!1;t||(y=[]),b?n=!0:b=[],x++;try{let t=e();return se(n),t}catch(e){n||(b=null),y=null,ge(e)}}function se(e){if(y&&=(g&&h&&h.running?le(y):ce(y),null),e)return;let t;if(h){if(!h.promises.size&&!h.queue.size){let e=h.sources,n=h.disposed;b.push.apply(b,h.effects),t=h.resolve;for(let e of b)`tState`in e&&(e.state=e.tState),delete e.tState;h=null,L(()=>{for(let e of n)fe(e);for(let t of e){if(t.value=t.tValue,t.owned)for(let e=0,n=t.owned.length;e<n;e++)fe(t.owned[e]);t.tOwned&&(t.owned=t.tOwned),delete t.tValue,delete t.tOwned,t.tState=0}M(!1)},!1)}else if(h.running){h.running=!1,h.effects.push.apply(h.effects,b),b=null,M(!0);return}}let n=b;b=null,n.length&&L(()=>u(n),!1),t&&t()}function ce(e){for(let t=0;t<e.length;t++)I(e[t])}function le(e){for(let t=0;t<e.length;t++){let n=e[t],r=h.queue;r.has(n)||(r.add(n),g(()=>{r.delete(n),L(()=>{h.running=!0,I(n)},!1),h&&(h.running=!1)}))}}function ue(e){let t,r=0;for(t=0;t<e.length;t++){let n=e[t];n.user?e[r++]=n:I(n)}if(n.context){if(n.count){n.effects||=[],n.effects.push(...e.slice(0,r));return}i()}for(n.effects&&(n.done||!n.count)&&(e=[...n.effects,...e],r+=n.effects.length,delete n.effects),t=0;t<r;t++)I(e[t])}function de(e,t){let n=h&&h.running;n?e.tState=0:e.state=0;for(let r=0;r<e.sources.length;r+=1){let i=e.sources[r];if(i.sources){let e=n?i.tState:i.state;e===d?i!==t&&(!i.updatedAt||i.updatedAt<x)&&I(i):e===f&&de(i,t)}}}function R(e){let t=h&&h.running;for(let n=0;n<e.observers.length;n+=1){let r=e.observers[n];(t?!r.tState:!r.state)&&(t?r.tState=f:r.state=f,r.pure?y.push(r):b.push(r),r.observers&&R(r))}}function fe(e){let t;if(e.sources)for(;e.sources.length;){let t=e.sources.pop(),n=e.sourceSlots.pop(),r=t.observers;if(r&&r.length){let e=r.pop(),i=t.observerSlots.pop();n<r.length&&(e.sourceSlots[i]=n,r[n]=e,t.observerSlots[n]=i)}}if(e.tOwned){for(t=e.tOwned.length-1;t>=0;t--)fe(e.tOwned[t]);delete e.tOwned}if(h&&h.running&&e.pure)pe(e,!0);else if(e.owned){for(t=e.owned.length-1;t>=0;t--)fe(e.owned[t]);e.owned=null}if(e.cleanups){for(t=e.cleanups.length-1;t>=0;t--)e.cleanups[t]();e.cleanups=null}h&&h.running?e.tState=0:e.state=0}function pe(e,t){if(t||(e.tState=0,h.disposed.add(e)),e.owned)for(let t=0;t<e.owned.length;t++)pe(e.owned[t])}function me(e){return e instanceof Error?e:Error(typeof e==`string`?e:`Unknown error`,{cause:e})}function he(e,t,n){try{for(let n of t)n(e)}catch(e){ge(e,n&&n.owner||null)}}function ge(e,t=m){let n=l&&t&&t.context&&t.context[l],r=me(e);if(!n)throw r;b?b.push({fn(){he(r,n,t)},state:d}):he(r,n,t)}function _e(e){if(typeof e==`function`&&!e.length)return _e(e());if(Array.isArray(e)){let t=[];for(let n=0;n<e.length;n++){let r=_e(e[n]);if(Array.isArray(r))if(r.length<32768)t.push.apply(t,r);else for(let e=0;e<r.length;e++)t.push(r[e]);else t.push(r)}return t}return e}function ve(e,t){return function(t){let n;return w(()=>n=O(()=>(m.context={...m.context,[e]:t.value},ne(()=>t.children))),void 0),n}}var ye=Symbol(`fallback`);function be(e){for(let t=0;t<e.length;t++)e[t]()}function xe(e,t,n={}){let r=[],i=[],a=[],o=0,c=t.length>1?[]:null;return k(()=>be(a)),()=>{let l=e()||[],u=l.length,d,f;return l[s],O(()=>{let e,t,s,m,h,g,_,v,y;if(u===0)o!==0&&(be(a),a=[],r=[],i=[],o=0,c&&=[]),n.fallback&&(r=[ye],i[0]=S(e=>(a[0]=e,n.fallback())),o=1);else if(o===0){for(i=Array(u),f=0;f<u;f++)r[f]=l[f],i[f]=S(p);o=u}else{for(s=Array(u),m=Array(u),c&&(h=Array(u)),g=0,_=Math.min(o,u);g<_&&r[g]===l[g];g++);for(_=o-1,v=u-1;_>=g&&v>=g&&r[_]===l[v];_--,v--)s[v]=i[_],m[v]=a[_],c&&(h[v]=c[_]);for(e=new Map,t=Array(v+1),f=v;f>=g;f--)y=l[f],d=e.get(y),t[f]=d===void 0?-1:d,e.set(y,f);for(d=g;d<=_;d++)y=r[d],f=e.get(y),f!==void 0&&f!==-1?(s[f]=i[d],m[f]=a[d],c&&(h[f]=c[d]),f=t[f],e.set(y,f)):a[d]();for(f=g;f<u;f++)f in s?(i[f]=s[f],a[f]=m[f],c&&(c[f]=h[f],c[f](f))):i[f]=S(p);i=i.slice(0,o=u),r=l.slice(0)}return i});function p(e){if(a[f]=e,c){let[e,n]=C(f);return c[f]=n,t(l[f],e)}return t(l[f])}}}var Se=!1;function z(e,t){if(Se&&n.context){let r=n.context;i(a());let o=O(()=>e(t||{}));return i(r),o}return O(()=>e(t||{}))}var Ce=e=>`Stale read from <${e}>.`;function we(e){let t=`fallback`in e&&{fallback:()=>e.fallback};return E(xe(()=>e.each,e.children,t||void 0))}function Te(e){let t=e.keyed,n=E(()=>e.when,void 0,void 0),r=t?n:E(n,void 0,{equals:(e,t)=>!e==!t});return E(()=>{let i=r();if(i){let a=e.children;return typeof a==`function`&&a.length>0?O(()=>a(t?i:()=>{if(!O(r))throw Ce(`Show`);return n()})):a}return e.fallback},void 0,void 0)}var Ee=new Set([`className`,`value`,`readOnly`,`noValidate`,`formNoValidate`,`isMap`,`noModule`,`playsInline`,`adAuctionHeaders`,`allowFullscreen`,`browsingTopics`,`defaultChecked`,`defaultMuted`,`defaultSelected`,`disablePictureInPicture`,`disableRemotePlayback`,`preservesPitch`,`shadowRootClonable`,`shadowRootCustomElementRegistry`,`shadowRootDelegatesFocus`,`shadowRootSerializable`,`sharedStorageWritable`,...`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`.split(`.`)]),De=new Set([`innerHTML`,`textContent`,`innerText`,`children`]),Oe=Object.assign(Object.create(null),{className:`class`,htmlFor:`for`}),ke=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 Ae(e,t){let n=ke[e];return typeof n==`object`?n[t]?n.$:void 0:n}var je=new Set([`beforeinput`,`click`,`dblclick`,`contextmenu`,`focusin`,`focusout`,`input`,`keydown`,`keyup`,`mousedown`,`mousemove`,`mouseout`,`mouseover`,`mouseup`,`pointerdown`,`pointermove`,`pointerout`,`pointerover`,`pointerup`,`touchend`,`touchmove`,`touchstart`]),Me=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`.split(`.`)),Ne={xlink:`http://www.w3.org/1999/xlink`,xml:`http://www.w3.org/XML/1998/namespace`},Pe=e=>E(()=>e());function Fe(e,t,n){let r=n.length,i=t.length,a=r,o=0,s=0,c=t[i-1].nextSibling,l=null;for(;o<i||s<a;){if(t[o]===n[s]){o++,s++;continue}for(;t[i-1]===n[a-1];)i--,a--;if(i===o){let t=a<r?s?n[s-1].nextSibling:n[a-s]:c;for(;s<a;)e.insertBefore(n[s++],t)}else if(a===s)for(;o<i;)(!l||!l.has(t[o]))&&t[o].remove(),o++;else if(t[o]===n[a-1]&&n[s]===t[i-1]){let r=t[--i].nextSibling;e.insertBefore(n[s++],t[o++].nextSibling),e.insertBefore(n[--a],r),t[i]=n[a]}else{if(!l){l=new Map;let e=s;for(;e<a;)l.set(n[e],e++)}let r=l.get(t[o]);if(r!=null)if(s<r&&r<a){let c=o,u=1,d;for(;++c<i&&c<a&&!((d=l.get(t[c]))==null||d!==r+u);)u++;if(u>r-s){let i=t[o];for(;s<r;)e.insertBefore(n[s++],i)}else e.replaceChild(n[s++],t[o++])}else o++;else t[o++].remove()}}}var Ie=`_$DX_DELEGATE`;function Le(e,t,n,r={}){let i;return S(r=>{i=r,t===document?e():V(t,e(),t.firstChild?null:void 0,n)},r.owner),()=>{i(),t.textContent=``}}function B(e,t,n,r){let i,a=()=>{let t=r?document.createElementNS(`http://www.w3.org/1998/Math/MathML`,`template`):document.createElement(`template`);return t.innerHTML=e,n?t.content.firstChild.firstChild:r?t.firstChild:t.content.firstChild},o=t?()=>O(()=>document.importNode(i||=a(),!0)):()=>(i||=a()).cloneNode(!0);return o.cloneNode=o,o}function Re(e,t=window.document){let n=t[Ie]||(t[Ie]=new Set);for(let r=0,i=e.length;r<i;r++){let i=e[r];n.has(i)||(n.add(i),t.addEventListener(i,et))}}function ze(e,t,n){Xe(e)||(n==null?e.removeAttribute(t):e.setAttribute(t,n))}function Be(e,t,n,r){Xe(e)||(r==null?e.removeAttributeNS(t,n):e.setAttributeNS(t,n,r))}function Ve(e,t,n){Xe(e)||(n?e.setAttribute(t,``):e.removeAttribute(t))}function He(e,t){Xe(e)||(t==null?e.removeAttribute(`class`):e.className=t)}function Ue(e,t,n,r){if(r)Array.isArray(n)?(e[`$$${t}`]=n[0],e[`$$${t}Data`]=n[1]):e[`$$${t}`]=n;else if(Array.isArray(n)){let r=n[0];e.addEventListener(t,n[0]=t=>r.call(e,n[1],t))}else e.addEventListener(t,n,typeof n!=`function`&&n)}function We(e,t,n={}){let r=Object.keys(t||{}),i=Object.keys(n),a,o;for(a=0,o=i.length;a<o;a++){let r=i[a];!r||r===`undefined`||t[r]||(Qe(e,r,!1),delete n[r])}for(a=0,o=r.length;a<o;a++){let i=r[a],o=!!t[i];!i||i===`undefined`||n[i]===o||!o||(Qe(e,i,!0),n[i]=o)}return n}function Ge(e,t,n){if(!t)return n?ze(e,`style`):t;let r=e.style;if(typeof t==`string`)return r.cssText=t;typeof n==`string`&&(r.cssText=n=void 0),n||={},t||={};let i,a;for(a in n)t[a]??r.removeProperty(a),delete n[a];for(a in t)i=t[a],i!==n[a]&&(r.setProperty(a,i),n[a]=i);return n}function Ke(e,t={},n,r){let i={};return r||w(()=>i.children=tt(e,t.children,i.children)),w(()=>typeof t.ref==`function`&&Je(t.ref,e)),w(()=>Ye(e,t,n,!0,i,!0)),i}function qe(e,t){let n=e[t];return Object.defineProperty(e,t,{get(){return n()},enumerable:!0}),e}function Je(e,t,n){return O(()=>e(t,n))}function V(e,t,n,r){if(n!==void 0&&!r&&(r=[]),typeof t!=`function`)return tt(e,t,r,n);w(r=>tt(e,t(),r,n),r)}function Ye(e,t,n,r,i={},a=!1){t||={};for(let r in i)if(!(r in t)){if(r===`children`)continue;i[r]=$e(e,r,null,i[r],n,a,t)}for(let o in t){if(o===`children`){r||tt(e,t.children);continue}let s=t[o];i[o]=$e(e,o,s,i[o],n,a,t)}}function Xe(e){return!!n.context&&!n.done&&(!e||e.isConnected)}function Ze(e){return e.toLowerCase().replace(/-([a-z])/g,(e,t)=>t.toUpperCase())}function Qe(e,t,n){let r=t.trim().split(/\s+/);for(let t=0,i=r.length;t<i;t++)e.classList.toggle(r[t],n)}function $e(e,t,n,r,i,a,o){let s,c,l,u,d;if(t===`style`)return Ge(e,n,r);if(t===`classList`)return We(e,n,r);if(n===r)return r;if(t===`ref`)a||n(e);else if(t.slice(0,3)===`on:`){let i=t.slice(3);r&&e.removeEventListener(i,r,typeof r!=`function`&&r),n&&e.addEventListener(i,n,typeof n!=`function`&&n)}else if(t.slice(0,10)===`oncapture:`){let i=t.slice(10);r&&e.removeEventListener(i,r,!0),n&&e.addEventListener(i,n,!0)}else if(t.slice(0,2)===`on`){let i=t.slice(2).toLowerCase(),a=je.has(i);if(!a&&r){let t=Array.isArray(r)?r[0]:r;e.removeEventListener(i,t)}(a||n)&&(Ue(e,i,n,a),a&&Re([i]))}else if(t.slice(0,5)===`attr:`)ze(e,t.slice(5),n);else if(t.slice(0,5)===`bool:`)Ve(e,t.slice(5),n);else if((d=t.slice(0,5)===`prop:`)||(l=De.has(t))||!i&&((u=Ae(t,e.tagName))||(c=Ee.has(t)))||(s=e.nodeName.includes(`-`)||`is`in o)){if(d)t=t.slice(5),c=!0;else if(Xe(e))return n;t===`class`||t===`className`?He(e,n):s&&!c&&!l?e[Ze(t)]=n:e[u||t]=n}else{let r=i&&t.indexOf(`:`)>-1&&Ne[t.split(`:`)[0]];r?Be(e,r,t,n):ze(e,Oe[t]||t,n)}return n}function et(e){if(n.registry&&n.events&&n.events.find(([t,n])=>n===e))return;let t=e.target,r=`$$${e.type}`,i=e.target,a=e.currentTarget,o=t=>Object.defineProperty(e,"target",{configurable:!0,value:t}),s=()=>{let n=t[r];if(n&&!t.disabled){let i=t[`${r}Data`];if(i===void 0?n.call(t,e):n.call(t,i,e),e.cancelBubble)return}return t.host&&typeof t.host!=`string`&&!t.host._$host&&t.contains(e.target)&&o(t.host),!0},c=()=>{for(;s()&&(t=t._$host||t.parentNode||t.host););};if(Object.defineProperty(e,"currentTarget",{configurable:!0,get(){return t||document}}),n.registry&&!n.done&&(n.done=_$HY.done=!0),e.composedPath){let n=e.composedPath();o(n[0]);for(let e=0;e<n.length-2&&(t=n[e],s());e++){if(t._$host){t=t._$host,c();break}if(t.parentNode===a)break}}else c();o(i)}function tt(e,t,n,r,i){let a=Xe(e);if(a){!n&&(n=[...e.childNodes]);let t=[];for(let e=0;e<n.length;e++){let r=n[e];r.nodeType===8&&r.data.slice(0,2)===`!$`?r.remove():t.push(r)}n=t}for(;typeof n==`function`;)n=n();if(t===n)return n;let o=typeof t,s=r!==void 0;if(e=s&&n[0]&&n[0].parentNode||e,o===`string`||o===`number`){if(a||o===`number`&&(t=t.toString(),t===n))return n;if(s){let i=n[0];i&&i.nodeType===3?i.data!==t&&(i.data=t):i=document.createTextNode(t),n=H(e,n,r,i)}else n=n!==``&&typeof n==`string`?e.firstChild.data=t:e.textContent=t}else if(t==null||o===`boolean`){if(a)return n;n=H(e,n,r)}else if(o===`function`)return w(()=>{let i=t();for(;typeof i==`function`;)i=i();n=tt(e,i,n,r)}),()=>n;else if(Array.isArray(t)){let o=[],c=n&&Array.isArray(n);if(nt(o,t,n,i))return w(()=>n=tt(e,o,n,r,!0)),()=>n;if(a){if(!o.length)return n;if(r===void 0)return n=[...e.childNodes];let t=o[0];if(t.parentNode!==e)return n;let i=[t];for(;(t=t.nextSibling)!==r;)i.push(t);return n=i}if(o.length===0){if(n=H(e,n,r),s)return n}else c?n.length===0?rt(e,o,r):Fe(e,n,o):(n&&H(e),rt(e,o));n=o}else if(t.nodeType){if(a&&t.parentNode)return n=s?[t]:t;if(Array.isArray(n)){if(s)return n=H(e,n,r,t);H(e,n,null,t)}else n==null||n===``||!e.firstChild?e.appendChild(t):e.replaceChild(t,e.firstChild);n=t}return n}function nt(e,t,n,r){let i=!1;for(let a=0,o=t.length;a<o;a++){let o=t[a],s=n&&n[e.length],c;if(!(o==null||o===!0||o===!1))if((c=typeof o)==`object`&&o.nodeType)e.push(o);else if(Array.isArray(o))i=nt(e,o,s)||i;else if(c===`function`)if(r){for(;typeof o==`function`;)o=o();i=nt(e,Array.isArray(o)?o:[o],Array.isArray(s)?s:[s])||i}else e.push(o),i=!0;else{let t=String(o);s&&s.nodeType===3&&s.data===t?e.push(s):e.push(document.createTextNode(t))}}return i}function rt(e,t,n=null){for(let r=0,i=t.length;r<i;r++)e.insertBefore(t[r],n)}function H(e,t,n,r){if(n===void 0)return e.textContent=``;let i=r||document.createTextNode(``);if(t.length){let r=!1;for(let a=t.length-1;a>=0;a--){let o=t[a];if(i!==o){let t=o.parentNode===e;!r&&!a?t?e.replaceChild(i,o):e.insertBefore(i,n):t&&o.remove()}else r=!0}}else e.insertBefore(i,n);return[i]}var it=Symbol(`hyper-element`);function at(e){function t(){let n=[].slice.call(arguments),r,i=[],a=!1;for(;Array.isArray(n[0]);)n=n[0];n[0][it]&&n.unshift(t.Fragment),typeof n[0]==`string`&&l(n);let o=()=>{for(;n.length;)s(n.shift());return r instanceof Element&&i.length&&r.classList.add(...i),r};return o[it]=!0,o;function s(t){let o=typeof t;if(t!=null){if(o===`string`)r?r.appendChild(document.createTextNode(t)):c(t);else if(o===`number`||o===`boolean`||o===`bigint`||o===`symbol`||t instanceof Date||t instanceof RegExp)r.appendChild(document.createTextNode(t.toString()));else if(Array.isArray(t))for(let e=0;e<t.length;e++)s(t[e]);else if(t instanceof Element)e.insert(r,t,a?null:void 0);else if(o===`object`){let a=!1,o=Object.getOwnPropertyDescriptors(t);for(let n in o){if(n===`class`&&i.length!==0){let e=i.join(` `),r=typeof o.class.value==`function`?()=>e+` `+o.class.value():e+` `+t.class;Object.defineProperty(t,"class",{...o[n],value:r}),i=[]}n!==`ref`&&n.slice(0,2)!==`on`&&typeof o[n].value==`function`?(e.dynamicProperty(t,n),a=!0):o[n].get&&(a=!0)}a?e.spread(r,t,r instanceof SVGElement,!!n.length):e.assign(r,t,r instanceof SVGElement,!!n.length)}else if(o===`function`)if(r){for(;t[it];)t=t();e.insert(r,t,a?null:void 0)}else{let i,a=n[0];(a==null||typeof a==`object`&&!Array.isArray(a)&&!(a instanceof Element))&&(i=n.shift()),i||={},n.length&&(i.children=n.length>1?n:n[0]);let o=Object.getOwnPropertyDescriptors(i);for(let t in o)if(Array.isArray(o[t].value)){let n=o[t].value;i[t]=()=>{for(let e=0;e<n.length;e++)for(;n[e][it];)n[e]=n[e]();return n},e.dynamicProperty(i,t)}else typeof o[t].value==`function`&&!o[t].value.length&&e.dynamicProperty(i,t);r=e.createComponent(t,i),n=[]}}}function c(t){let n=t.split(/([\.#]?[^\s#.]+)/);/^\.|#/.test(n[1])&&(r=document.createElement(`div`));for(let t=0;t<n.length;t++){let a=n[t],o=a.substring(1,a.length);a&&(r?a[0]===`.`?i.push(o):a[0]===`#`&&r.setAttribute(`id`,o):r=e.SVGElements.has(a)?document.createElementNS(`http://www.w3.org/2000/svg`,a):document.createElement(a))}}function l(e){for(let t=1;t<e.length;t++)if(typeof e[t]==`function`){a=!0;return}else Array.isArray(e[t])&&l(e[t])}}return t.Fragment=e=>e.children,t}var ot=at({spread:Ke,assign:Ye,insert:V,createComponent:z,dynamicProperty:qe,SVGElements:Me});function st(e,t,n){let r=[];for(let n of t)n&&r.push(e?.[n]??n);return n&&r.push(n),r.join(` `)}function ct(e){return(Array.isArray(e)?e:e?[e]:[]).map(e=>`-${e}`)}function lt(e,t){let n=e,r={};for(let e of Object.keys(n))t.has(e)||(r[e]=n[e]);return r}function ut(e){return e}var dt={menu:`MenuBar`,taskbar:`Taskbar`,taskbarClock:`TaskbarClock`,taskbarStatus:`TaskbarStatus`,taskbarWindows:`TaskbarWindows`,toolbar:`Toolbar`},ft={menu:`div`,taskbar:`footer`,taskbarClock:`div`,taskbarStatus:`div`,taskbarWindows:`div`,toolbar:`div`},pt=new Set([`as`,`children`,`class`,`classes`,`variant`]);function mt(e){return ut(ot(e.as??ft[e.variant],{...lt(e,pt),class:st(e.classes,[dt[e.variant]],e.class)},e.children))}function ht(e){return mt({...e,variant:`taskbar`})}function gt(e){return mt({...e,variant:`taskbarWindows`})}function _t(e){return mt({...e,variant:`taskbarStatus`})}function vt(e){return mt({...e,variant:`taskbarClock`})}Object.assign(ht,{Clock:vt,Status:_t,Windows:gt});function yt(e){return mt({...e,variant:`toolbar`})}var bt={border:`Border`,field:`Field`,status:`StatusField`,well:`Well`},xt=new Set([`as`,`children`,`class`,`classes`,`variant`]),St=new Set([`as`,`children`,`class`,`classes`]);function Ct(e){return ut(ot(e.as??`div`,{...lt(e,xt),class:st(e.classes,[bt[e.variant]],e.class)},e.children))}function wt(e){return Ct({...e,variant:`border`})}function Tt(e){return Ct({...e,variant:`field`})}function Et(e){return ut(ot(e.as??`div`,{...lt(e,St),class:st(e.classes,[`FieldContent`],e.class)},e.children))}function Dt(e){return ut(ot(e.as??`div`,{...lt(e,St),class:st(e.classes,[`FieldDocument`],e.class)},e.children))}var Ot=Object.assign(Tt,{Content:Et,Document:Dt});function kt(e){return function(t){return ut(ot(`div`,{...lt(t,new Set([`children`,`class`,`classes`])),class:st(t.classes,[e],t.class)},t.children))}}var At=kt(`ThemeClassic`),jt=new Set([`as`,`appearance`,`children`,`class`,`classes`]),Mt=new Set([`as`,`children`,`class`,`classes`]);function Nt(e){return ut(ot(e.as??`section`,{...lt(e,jt),class:st(e.classes,[`Window`,...ct(e.appearance)],e.class)},e.children))}function Pt(e,t){return function(n){return ut(ot(n.as??e,{...lt(n,Mt),class:st(n.classes,[t],n.class)},n.children))}}var Ft=Pt(`div`,`WindowTitleBar`),It=Pt(`span`,`WindowTitleIcon`),Lt=Pt(`span`,`WindowTitleText`),Rt=Pt(`div`,`WindowTitleButtons`),zt=Pt(`div`,`WindowContent`),Bt=Object.assign(Nt,{TitleBar:Ft,TitleIcon:It,TitleText:Lt,TitleButtons:Rt,Content:zt});function Vt(e){let t=e.trim();if(t)return Wt(t)??Ut(t)}function Ht(e){let t=e.split(`/`);return(t.length===2||t.length===3)&&t.every(e=>e.length>0&&!/\s/.test(e))}function Ut(e){let t=e.match(/^(?:(.+)#)?(\d+)$/);if(!t)return;let n=Number(t[2]),r=t[1];if(!(!Number.isSafeInteger(n)||n<=0)&&!(r&&!Ht(r)))return{repository:r,number:n}}function Wt(e){let t;try{t=new URL(e)}catch{try{t=new URL(`https://${e}`)}catch{return}}if(t.protocol!==`https:`&&t.protocol!==`http:`)return;let[n,r,i,a]=t.pathname.split(`/`).filter(Boolean);if(!n||!r||!a||![`pull`,`pulls`].includes(i?.toLowerCase()??``))return;let o=t.hostname.toLowerCase();return Ut(`${o===`github.com`||o===`www.github.com`?`${n}/${r}`:`${t.host}/${n}/${r}`}#${a}`)}var Gt=`all`;function Kt(e){if(e)try{return decodeURIComponent(e)}catch{return}}function qt(e){let t=e.pathname.split(`/`).filter(Boolean);if(t[0]!==`review`||t.length<4)return;let n=Kt(t[1]),r=Kt(t[2]),i=Number(t[3]);if(!n||!r||!Number.isSafeInteger(i)||i<=0)return;let a=new URLSearchParams(e.search).get(`host`)?.trim(),o=Kt(t[4]),s=t.slice(5).map(Kt);if(!s.some(e=>e===void 0))return{target:{repository:a?`${a}/${n}/${r}`:`${n}/${r}`,number:i},groupId:o&&o!==Gt?o:void 0,filePath:s.length>0?s.join(`/`):void 0}}function Jt(e){let t=e.target.repository.split(`/`),n=t.at(-1),r=t.at(-2);if(!r||!n)return`/`;let i=e.groupId??Gt,a=`/${[`review`,r,n,String(e.target.number),i,...e.filePath?.split(`/`)??[]].map(encodeURIComponent).join(`/`)}`,o=t.length===3?t[0]:void 0;return o?`${a}?host=${encodeURIComponent(o)}`:a}var Yt=Object.create,Xt=Object.defineProperty,Zt=Object.getOwnPropertyDescriptor,Qt=Object.getOwnPropertyNames,$t=Object.getPrototypeOf,en=Object.prototype.hasOwnProperty,tn=(e,t)=>function(){return t||(0,e[Qt(e)[0]])((t={exports:{}}).exports,t),t.exports},nn=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var i=Qt(t),a=0,o=i.length,s;a<o;a++)s=i[a],!en.call(e,s)&&s!==n&&Xt(e,s,{get:(e=>t[e]).bind(null,s),enumerable:!(r=Zt(t,s))||r.enumerable});return e},rn=(e,t,n)=>(n=e==null?{}:Yt($t(e)),nn(t||!e||!e.__esModule?Xt(n,`default`,{value:e,enumerable:!0}):n,e)),an=tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/typeof.js"(e,t){function n(e){"@babel/helpers - typeof";return t.exports=n=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},t.exports.__esModule=!0,t.exports.default=t.exports,n(e)}t.exports=n,t.exports.__esModule=!0,t.exports.default=t.exports}}),on=tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/toPrimitive.js"(e,t){var n=an().default;function r(e,t){if(n(e)!=`object`||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var i=r.call(e,t||`default`);if(n(i)!=`object`)return i;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}t.exports=r,t.exports.__esModule=!0,t.exports.default=t.exports}}),sn=tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/toPropertyKey.js"(e,t){var n=an().default,r=on();function i(e){var t=r(e,`string`);return n(t)==`symbol`?t:t+``}t.exports=i,t.exports.__esModule=!0,t.exports.default=t.exports}}),cn=tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/defineProperty.js"(e,t){var n=sn();function r(e,t,r){return(t=n(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}t.exports=r,t.exports.__esModule=!0,t.exports.default=t.exports}}),ln=tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/objectSpread2.js"(e,t){var n=cn();function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function i(e){for(var t=1;t<arguments.length;t++){var i=arguments[t]==null?{}:arguments[t];t%2?r(Object(i),!0).forEach(function(t){n(e,t,i[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):r(Object(i)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))})}return e}t.exports=i,t.exports.__esModule=!0,t.exports.default=t.exports}});function un(e){let t={subscribe(t){let n=null,r=!1,i=!1,a=!1;function o(){if(n===null){a=!0;return}i||(i=!0,typeof n==`function`?n():n&&n.unsubscribe())}return n=e({next(e){var n;r||(n=t.next)==null||n.call(t,e)},error(e){var n;r||(r=!0,(n=t.error)==null||n.call(t,e),o())},complete(){var e;r||(r=!0,(e=t.complete)==null||e.call(t),o())}}),a&&o(),{unsubscribe:o}},pipe(...e){return e.reduce(dn,t)}};return t}function dn(e,t){return t(e)}function fn(e){let t=new AbortController;return new Promise((n,r)=>{let i=!1;function a(){i||(i=!0,o.unsubscribe())}t.signal.addEventListener(`abort`,()=>{r(t.signal.reason)});let o=e.subscribe({next(e){i=!0,n(e),a()},error(e){r(e)},complete(){t.abort(),a()}})})}function pn(e){return e=>{let t=0,n=null,r=[];function i(){n||=e.subscribe({next(e){for(let n of r){var t;(t=n.next)==null||t.call(n,e)}},error(e){for(let n of r){var t;(t=n.error)==null||t.call(n,e)}},complete(){for(let t of r){var e;(e=t.complete)==null||e.call(t)}}})}function a(){if(t===0&&n){let e=n;n=null,e.unsubscribe()}}return un(e=>(t++,r.push(e),i(),{unsubscribe(){t--,a();let n=r.findIndex(t=>t===e);n>-1&&r.splice(n,1)}}))}}function mn(e){let t=e,n=[],r=e=>{t!==void 0&&e.next(t),n.push(e)},i=e=>{n.splice(n.indexOf(e),1)},a=un(e=>(r(e),()=>{i(e)}));return a.next=e=>{if(t!==e){t=e;for(let t of n)t.next(e)}},a.get=()=>t,a}function hn(e){return un(t=>{function n(t=0,r=e.op){let i=e.links[t];if(!i)throw Error(`No more links to execute - did you forget to add an ending link?`);return i({op:r,next(e){return n(t+1,e)}})}return n().subscribe(t)})}function gn(e){return!!e&&!Array.isArray(e)&&typeof e==`object`}function _n(){return Object.create(null)}var vn={PARSE_ERROR:-32700,BAD_REQUEST:-32600,INTERNAL_SERVER_ERROR:-32603,NOT_IMPLEMENTED:-32603,BAD_GATEWAY:-32603,SERVICE_UNAVAILABLE:-32603,GATEWAY_TIMEOUT:-32603,UNAUTHORIZED:-32001,PAYMENT_REQUIRED:-32002,FORBIDDEN:-32003,NOT_FOUND:-32004,METHOD_NOT_SUPPORTED:-32005,TIMEOUT:-32008,CONFLICT:-32009,PRECONDITION_FAILED:-32012,PAYLOAD_TOO_LARGE:-32013,UNSUPPORTED_MEDIA_TYPE:-32015,UNPROCESSABLE_CONTENT:-32022,PRECONDITION_REQUIRED:-32028,TOO_MANY_REQUESTS:-32029,CLIENT_CLOSED_REQUEST:-32099};vn.BAD_GATEWAY,vn.SERVICE_UNAVAILABLE,vn.GATEWAY_TIMEOUT,vn.INTERNAL_SERVER_ERROR;var yn=Object.create,bn=Object.defineProperty,xn=Object.getOwnPropertyDescriptor,Sn=Object.getOwnPropertyNames,Cn=Object.getPrototypeOf,wn=Object.prototype.hasOwnProperty,Tn=(e,t)=>function(){return t||(0,e[Sn(e)[0]])((t={exports:{}}).exports,t),t.exports},En=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var i=Sn(t),a=0,o=i.length,s;a<o;a++)s=i[a],!wn.call(e,s)&&s!==n&&bn(e,s,{get:(e=>t[e]).bind(null,s),enumerable:!(r=xn(t,s))||r.enumerable});return e},Dn=(e,t,n)=>(n=e==null?{}:yn(Cn(e)),En(t||!e||!e.__esModule?bn(n,`default`,{value:e,enumerable:!0}):n,e)),On=()=>{},kn=e=>{Object.freeze&&Object.freeze(e)};function An(e,t,n){let r=t.join(`.`);return n[r]??(n[r]=new Proxy(On,{get(r,i){if(!(typeof i!=`string`||i===`then`))return An(e,[...t,i],n)},apply(n,r,i){let a=t[t.length-1];if(a===`valueOf`||a===`toString`||a===`toJSON`)return`tRPC.proxy(${t.slice(0,-1).join(`.`)})`;let o={args:i,path:t};return a===`call`?o={args:i.length>=2?[i[1]]:[],path:t.slice(0,-1)}:a===`apply`&&(o={args:i.length>=2?i[1]:[],path:t.slice(0,-1)}),kn(o.args),kn(o.path),e(o)}})),n[r]}var jn=e=>An(e,[],_n()),Mn=e=>new Proxy(On,{get(t,n){if(n!==`then`)return e(n)}}),Nn=Tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/typeof.js"(e,t){function n(e){"@babel/helpers - typeof";return t.exports=n=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},t.exports.__esModule=!0,t.exports.default=t.exports,n(e)}t.exports=n,t.exports.__esModule=!0,t.exports.default=t.exports}}),Pn=Tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/toPrimitive.js"(e,t){var n=Nn().default;function r(e,t){if(n(e)!=`object`||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var i=r.call(e,t||`default`);if(n(i)!=`object`)return i;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}t.exports=r,t.exports.__esModule=!0,t.exports.default=t.exports}}),Fn=Tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/toPropertyKey.js"(e,t){var n=Nn().default,r=Pn();function i(e){var t=r(e,`string`);return n(t)==`symbol`?t:t+``}t.exports=i,t.exports.__esModule=!0,t.exports.default=t.exports}}),In=Tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/defineProperty.js"(e,t){var n=Fn();function r(e,t,r){return(t=n(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}t.exports=r,t.exports.__esModule=!0,t.exports.default=t.exports}}),Ln=Tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/objectSpread2.js"(e,t){var n=In();function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function i(e){for(var t=1;t<arguments.length;t++){var i=arguments[t]==null?{}:arguments[t];t%2?r(Object(i),!0).forEach(function(t){n(e,t,i[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):r(Object(i)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))})}return e}t.exports=i,t.exports.__esModule=!0,t.exports.default=t.exports}});Dn(Ln(),1),Dn(In(),1);var Rn=Dn(Ln(),1);function zn(e,t){if(`error`in e){let n=t.deserialize(e.error);return{ok:!1,error:(0,Rn.default)((0,Rn.default)({},e),{},{error:n})}}return{ok:!0,result:(0,Rn.default)((0,Rn.default)({},e.result),(!e.result.type||e.result.type===`data`)&&{type:`data`,data:t.deserialize(e.result.data)})}}var Bn=class extends Error{constructor(){super(`Unable to transform response from server`)}};function Vn(e,t){let n;try{n=zn(e,t)}catch{throw new Bn}if(!n.ok&&(!gn(n.error.error)||typeof n.error.error.code!=`number`)||n.ok&&!gn(n.result))throw new Bn;return n}Dn(Ln(),1);var Hn=rn(cn(),1),Un=rn(ln(),1);function Wn(e){return e instanceof qn}function Gn(e){return gn(e)&&gn(e.error)&&typeof e.error.code==`number`&&typeof e.error.message==`string`}function Kn(e,t){return typeof e==`string`?e:gn(e)&&typeof e.message==`string`?e.message:t}var qn=class e extends Error{constructor(t,n){var r,i;let a=n?.cause;super(t,{cause:a}),(0,Hn.default)(this,`cause`,void 0),(0,Hn.default)(this,`shape`,void 0),(0,Hn.default)(this,`data`,void 0),(0,Hn.default)(this,`meta`,void 0),this.meta=n?.meta,this.cause=a,this.shape=n==null||(r=n.result)==null?void 0:r.error,this.data=n==null||(i=n.result)==null?void 0:i.error.data,this.name=`TRPCClientError`,Object.setPrototypeOf(this,e.prototype)}static from(t,n={}){let r=t;return Wn(r)?(n.meta&&(r.meta=(0,Un.default)((0,Un.default)({},r.meta),n.meta)),r):Gn(r)?new e(r.error.message,(0,Un.default)((0,Un.default)({},n),{},{result:r,cause:n.cause})):new e(Kn(r,`Unknown error`),(0,Un.default)((0,Un.default)({},n),{},{cause:r}))}};function Jn(e){let t=e;return t?`input`in t?t:{input:t,output:t}:{input:{serialize:e=>e,deserialize:e=>e},output:{serialize:e=>e,deserialize:e=>e}}}var Yn=e=>typeof e==`function`;function Xn(e){if(e)return e;if(typeof window<`u`&&Yn(window.fetch))return window.fetch;if(typeof globalThis<`u`&&Yn(globalThis.fetch))return globalThis.fetch;throw Error(`No fetch implementation found`)}var Zn=rn(ln());function Qn(e){return{url:e.url.toString(),fetch:e.fetch,transformer:Jn(e.transformer),methodOverride:e.methodOverride}}function $n(e){let t={};for(let n=0;n<e.length;n++)t[n]=e[n];return t}var er={query:`GET`,mutation:`POST`,subscription:`PATCH`};function tr(e){return`input`in e?e.transformer.input.serialize(e.input):$n(e.inputs.map(t=>e.transformer.input.serialize(t)))}var nr=e=>{let t=e.url.split(`?`),n=t[0].replace(/\/$/,``)+`/`+e.path,r=[];if(t[1]&&r.push(t[1]),`inputs`in e&&r.push(`batch=1`),e.type===`query`||e.type===`subscription`){let t=tr(e);t!==void 0&&e.methodOverride!==`POST`&&r.push(`input=${encodeURIComponent(JSON.stringify(t))}`)}return r.length&&(n+=`?`+r.join(`&`)),n},rr=e=>{if(e.type===`query`&&e.methodOverride!==`POST`)return;let t=tr(e);return t===void 0?void 0:JSON.stringify(t)},ir=e=>cr((0,Zn.default)((0,Zn.default)({},e),{},{contentTypeHeader:`application/json`,getUrl:nr,getBody:rr})),ar=class extends Error{constructor(){let e=`AbortError`;super(e),this.name=e,this.message=e}},or=e=>{var t;if(e?.aborted)throw(t=e.throwIfAborted)==null||t.call(e),typeof DOMException<`u`?new DOMException(`AbortError`,`AbortError`):new ar};async function sr(e){or(e.signal);let t=e.getUrl(e),n=e.getBody(e),r=e.methodOverride??er[e.type],i=await(async()=>{let t=await e.headers();return Symbol.iterator in t?Object.fromEntries(t):t})(),a=(0,Zn.default)((0,Zn.default)((0,Zn.default)({},e.contentTypeHeader&&r!==`GET`?{"content-type":e.contentTypeHeader}:{}),e.trpcAcceptHeader?{[e.trpcAcceptHeaderKey??`trpc-accept`]:e.trpcAcceptHeader}:void 0),i);return Xn(e.fetch)(t,{method:r,signal:e.signal,body:n,headers:a})}async function cr(e){let t={},n=await sr(e);t.response=n;let r=await n.json();return t.responseJSON=r,{json:r,meta:t}}rn(ln(),1);var lr=()=>{throw Error(`Something went wrong. Please submit an issue at https://github.com/trpc/trpc/issues/new`)};function ur(e){let t=null,n=null,r=()=>{clearTimeout(n),n=null,t=null};function i(t){let n=[[]],r=0;for(;;){let o=t[r];if(!o)break;let s=n[n.length-1];if(o.aborted){var i;(i=o.reject)==null||i.call(o,Error(`Aborted`)),r++;continue}if(e.validate(s.concat(o).map(e=>e.key))){s.push(o),r++;continue}if(s.length===0){var a;(a=o.reject)==null||a.call(o,Error(`Input is too big for a single dispatch`)),r++;continue}n.push([])}return n}function a(){let n=i(t);r();for(let t of n){if(!t.length)continue;let n={items:t};for(let e of t)e.batch=n;e.fetch(n.items.map(e=>e.key)).then(async e=>{await Promise.all(e.map(async(e,t)=>{let r=n.items[t];try{var i;let t=await Promise.resolve(e);(i=r.resolve)==null||i.call(r,t)}catch(e){var a;(a=r.reject)==null||a.call(r,e)}r.batch=null,r.reject=null,r.resolve=null}));for(let e of n.items){var t;(t=e.reject)==null||t.call(e,Error(`Missing result`)),e.batch=null}}).catch(e=>{for(let r of n.items){var t;(t=r.reject)==null||t.call(r,e),r.batch=null}})}}function o(e){let r={aborted:!1,key:e,batch:null,resolve:lr,reject:lr},i=new Promise((e,n)=>{r.reject=n,r.resolve=e,t??=[],t.push(r)});return n??=setTimeout(a),i}return{load:o}}function dr(...e){let t=new AbortController,n=e.length,r=0,i=()=>{++r===n&&t.abort()};for(let t of e)t?.aborted?i():t?.addEventListener(`abort`,i,{once:!0});return t.signal}var fr=rn(ln(),1);function pr(e){let t=Qn(e),n=e.maxURLLength??1/0,r=e.maxItems??1/0;return()=>{let i=i=>({validate(e){if(n===1/0&&r===1/0)return!0;if(e.length>r)return!1;let a=e.map(e=>e.path).join(`,`),o=e.map(e=>e.input);return nr((0,fr.default)((0,fr.default)({},t),{},{type:i,path:a,inputs:o,signal:null})).length<=n},async fetch(n){let r=n.map(e=>e.path).join(`,`),a=n.map(e=>e.input),o=dr(...n.map(e=>e.signal)),s=await ir((0,fr.default)((0,fr.default)({},t),{},{path:r,inputs:a,type:i,headers(){return e.headers?typeof e.headers==`function`?e.headers({opList:n}):e.headers:{}},signal:o}));return(Array.isArray(s.json)?s.json:n.map(()=>s.json)).map(e=>({meta:s.meta,json:e}))}}),a={query:ur(i(`query`)),mutation:ur(i(`mutation`))};return({op:e})=>un(n=>{if(e.type===`subscription`)throw Error("Subscriptions are unsupported by `httpLink` - use `httpSubscriptionLink` or `wsLink`");let r=a[e.type].load(e),i;return r.then(e=>{i=e;let r=Vn(e.json,t.transformer.output);if(!r.ok){n.error(qn.from(r.error,{meta:e.meta}));return}n.next({context:e.meta,result:r.result}),n.complete()}).catch(e=>{n.error(qn.from(e,{meta:i?.meta}))}),()=>{}})}}rn(ln(),1);var mr=(e,...t)=>typeof e==`function`?e(...t):e;rn(cn(),1);function hr(){let e,t;return{promise:new Promise((n,r)=>{e=n,t=r}),resolve:e,reject:t}}async function gr(e){let t=await mr(e.url);return e.connectionParams?t+`${t.includes(`?`)?`&`:`?`}connectionParams=1`:t}async function _r(e,t){let n={method:`connectionParams`,data:await mr(e)};return t.encode(n)}rn(cn(),1);var vr=rn(cn(),1);function yr(e){let{promise:t,resolve:n,reject:r}=hr();return e.addEventListener(`open`,()=>{e.removeEventListener(`error`,r),n()}),e.addEventListener(`error`,r),t}function br(e,{intervalMs:t,pongTimeoutMs:n}){let r,i;function a(){r=setTimeout(()=>{e.send(`PING`),i=setTimeout(()=>{e.close()},n)},t)}function o(){clearTimeout(r),a()}function s(){clearTimeout(i),o()}e.addEventListener(`open`,a),e.addEventListener(`message`,({data:e})=>{clearTimeout(r),a(),e===`PONG`&&s()}),e.addEventListener(`close`,()=>{clearTimeout(r),clearTimeout(i)})}var xr=class e{constructor(t){if((0,vr.default)(this,`id`,++e.connectCount),(0,vr.default)(this,`WebSocketPonyfill`,void 0),(0,vr.default)(this,`urlOptions`,void 0),(0,vr.default)(this,`keepAliveOpts`,void 0),(0,vr.default)(this,`encoder`,void 0),(0,vr.default)(this,`wsObservable`,mn(null)),(0,vr.default)(this,`openPromise`,null),this.WebSocketPonyfill=t.WebSocketPonyfill??WebSocket,!this.WebSocketPonyfill)throw Error("No WebSocket implementation found - you probably don't want to use this on the server, but if you do you need to pass a `WebSocket`-ponyfill");this.urlOptions=t.urlOptions,this.keepAliveOpts=t.keepAlive,this.encoder=t.encoder}get ws(){return this.wsObservable.get()}set ws(e){this.wsObservable.next(e)}isOpen(){return!!this.ws&&this.ws.readyState===this.WebSocketPonyfill.OPEN&&!this.openPromise}isClosed(){return!!this.ws&&(this.ws.readyState===this.WebSocketPonyfill.CLOSING||this.ws.readyState===this.WebSocketPonyfill.CLOSED)}async open(){var t=this;if(t.openPromise)return t.openPromise;t.id=++e.connectCount,t.openPromise=gr(t.urlOptions).then(e=>new t.WebSocketPonyfill(e)).then(async e=>{t.ws=e,e.binaryType=`arraybuffer`,e.addEventListener(`message`,function({data:e}){e===`PING`&&this.send(`PONG`)}),t.keepAliveOpts.enabled&&br(e,t.keepAliveOpts),e.addEventListener(`close`,()=>{t.ws===e&&(t.ws=null)}),await yr(e),t.urlOptions.connectionParams&&e.send(await _r(t.urlOptions.connectionParams,t.encoder))});try{await t.openPromise}finally{t.openPromise=null}}async close(){var e=this;try{await e.openPromise}finally{var t;(t=e.ws)==null||t.close()}}};(0,vr.default)(xr,`connectCount`,0),rn(cn(),1),rn(ln(),1);var Sr=rn(cn(),1),Cr=rn(ln(),1),wr=class{constructor(e){(0,Sr.default)(this,`links`,void 0),(0,Sr.default)(this,`runtime`,void 0),(0,Sr.default)(this,`requestId`,void 0),this.requestId=0,this.runtime={},this.links=e.links.map(e=>e(this.runtime))}$request(e){return hn({links:this.links,op:(0,Cr.default)((0,Cr.default)({},e),{},{context:e.context??{},id:++this.requestId})}).pipe(pn())}async requestAsPromise(e){var t=this;try{return(await fn(t.$request(e))).result.data}catch(e){throw qn.from(e)}}query(e,t,n){return this.requestAsPromise({type:`query`,path:e,input:t,context:n?.context,signal:n?.signal})}mutation(e,t,n){return this.requestAsPromise({type:`mutation`,path:e,input:t,context:n?.context,signal:n?.signal})}subscription(e,t,n){return this.$request({type:`subscription`,path:e,input:t,context:n.context,signal:n.signal}).subscribe({next(e){switch(e.result.type){case`state`:var t;(t=n.onConnectionStateChange)==null||t.call(n,e.result);break;case`started`:var r;(r=n.onStarted)==null||r.call(n,{context:e.context});break;case`stopped`:var i;(i=n.onStopped)==null||i.call(n);break;case`data`:case void 0:var a;(a=n.onData)==null||a.call(n,e.result.data);break}},error(e){var t;(t=n.onError)==null||t.call(n,e)},complete(){var e;(e=n.onComplete)==null||e.call(n)}})}},Tr=Symbol.for(`trpc_untypedClient`),Er={query:`query`,mutate:`mutation`,subscribe:`subscription`},Dr=e=>Er[e];function Or(e){let t=jn(({path:t,args:n})=>{let r=[...t],i=Dr(r.pop()),a=r.join(`.`);return e[i](a,...n)});return Mn(n=>n===Tr?e:t[n])}function kr(e){return Or(new wr(e))}rn(ln(),1),rn(ln(),1),rn(tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/asyncIterator.js"(e,t){function n(e){var t,n,i,a=2;for(typeof Symbol<`u`&&(n=Symbol.asyncIterator,i=Symbol.iterator);a--;){if(n&&(t=e[n])!=null)return t.call(e);if(i&&(t=e[i])!=null)return new r(t.call(e));n=`@@asyncIterator`,i=`@@iterator`}throw TypeError(`Object is not async iterable`)}function r(e){function t(e){if(Object(e)!==e)return Promise.reject(TypeError(e+` is not an object.`));var t=e.done;return Promise.resolve(e.value).then(function(e){return{value:e,done:t}})}return r=function(e){this.s=e,this.n=e.next},r.prototype={s:null,n:null,next:function(){return t(this.n.apply(this.s,arguments))},return:function(e){var n=this.s.return;return n===void 0?Promise.resolve({value:e,done:!0}):t(n.apply(this.s,arguments))},throw:function(e){var n=this.s.return;return n===void 0?Promise.reject(e):t(n.apply(this.s,arguments))}},new r(e)}t.exports=n,t.exports.__esModule=!0,t.exports.default=t.exports}})(),1),rn(ln(),1);var Ar=tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/usingCtx.js"(e,t){function n(){var e=typeof SuppressedError==`function`?SuppressedError:function(e,t){var n=Error();return n.name=`SuppressedError`,n.error=e,n.suppressed=t,n},t={},n=[];function r(e,t){if(t!=null){if(Object(t)!==t)throw TypeError(`using declarations can only be used with objects, functions, null, or undefined.`);if(e)var r=t[Symbol.asyncDispose||Symbol.for(`Symbol.asyncDispose`)];if(r===void 0&&(r=t[Symbol.dispose||Symbol.for(`Symbol.dispose`)],e))var i=r;if(typeof r!=`function`)throw TypeError(`Object is not disposable.`);i&&(r=function(){try{i.call(t)}catch(e){return Promise.reject(e)}}),n.push({v:t,d:r,a:e})}else e&&n.push({d:t,a:e});return t}return{e:t,u:r.bind(null,!1),a:r.bind(null,!0),d:function(){var r,i=this.e,a=0;function o(){for(;r=n.pop();)try{if(!r.a&&a===1)return a=0,n.push(r),Promise.resolve().then(o);if(r.d){var e=r.d.call(r.v);if(r.a)return a|=2,Promise.resolve(e).then(o,s)}else a|=1}catch(e){return s(e)}if(a===1)return i===t?Promise.resolve():Promise.reject(i);if(i!==t)throw i}function s(n){return i=i===t?n:new e(n,i),o()}return o()}}}t.exports=n,t.exports.__esModule=!0,t.exports.default=t.exports}}),jr=tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/OverloadYield.js"(e,t){function n(e,t){this.v=e,this.k=t}t.exports=n,t.exports.__esModule=!0,t.exports.default=t.exports}}),Mr=tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/awaitAsyncGenerator.js"(e,t){var n=jr();function r(e){return new n(e,0)}t.exports=r,t.exports.__esModule=!0,t.exports.default=t.exports}}),Nr=tn({"../../node_modules/.pnpm/@oxc-project+runtime@0.72.2/node_modules/@oxc-project/runtime/src/helpers/wrapAsyncGenerator.js"(e,t){var n=jr();function r(e){return function(){return new i(e.apply(this,arguments))}}function i(e){var t,r;function i(t,r){try{var o=e[t](r),s=o.value,c=s instanceof n;Promise.resolve(c?s.v:s).then(function(n){if(c){var r=t===`return`?`return`:`next`;if(!s.k||n.done)return i(r,n);n=e[r](n).value}a(o.done?`return`:`normal`,n)},function(e){i(`throw`,e)})}catch(e){a(`throw`,e)}}function a(e,n){switch(e){case`return`:t.resolve({value:n,done:!0});break;case`throw`:t.reject(n);break;default:t.resolve({value:n,done:!1})}(t=t.next)?i(t.key,t.arg):r=null}this._invoke=function(e,n){return new Promise(function(a,o){var s={key:e,arg:n,resolve:a,reject:o,next:null};r?r=r.next=s:(t=r=s,i(e,n))})},typeof e.return!=`function`&&(this.return=void 0)}i.prototype[typeof Symbol==`function`&&Symbol.asyncIterator||`@@asyncIterator`]=function(){return this},i.prototype.next=function(e){return this._invoke(`next`,e)},i.prototype.throw=function(e){return this._invoke(`throw`,e)},i.prototype.return=function(e){return this._invoke(`return`,e)},t.exports=r,t.exports.__esModule=!0,t.exports.default=t.exports}});rn(Ar(),1),rn(Mr(),1),rn(Nr(),1),rn(ln(),1);var Pr=kr({links:[pr({url:`/api/trpc`})]}),Fr=`diffs-container`;(()=>{try{return!1}catch{return!1}})();var Ir=/(?=^From [a-f0-9]+ .+$)/m,Lr=/(?=^diff --git)/gm,Rr=/^(---|\+\+\+)\s+([^\t\r\n]+)/,zr=/^(---|\+\+\+)\s+[ab]\/([^\t\r\n]+)/,Br=/^diff --git (?:"a\/(.+?)"|a\/(.+?)) (?:"b\/(.+?)"|b\/(.+?))$/,Vr=/^index ([0-9a-f]+)\.\.([0-9a-f]+)(?: (\d+))?$/i,Hr=`header-prefix`,Ur=`header-metadata`,Wr=`header-custom`,Gr={dark:`pierre-dark`,light:`pierre-light`},Kr=`data-theme-css`,qr=`data-unsafe-css`,Jr=`data-diffs-scrollbar-measure`,Yr=`--diffs-scrollbar-gutter-measured`,Xr=1e5,Zr=Object.freeze({fromStart:0,fromEnd:0}),Qr={startingLine:0,totalLines:1/0,bufferBefore:0,bufferAfter:0},$r={startingLine:0,totalLines:0,bufferBefore:0,bufferAfter:0};function ei(e){return e.replace(/\n$|\r\n$/,``)}var ti=new TextEncoder,ni=new TextDecoder(`utf-8`,{ignoreBOM:!0}),ri=/[\uD800-\uDFFF]/,ii=1024,ai=new Uint8Array(ii);function oi(){ai.length!==ii&&(ai=new Uint8Array(ii))}function si(e){if(e.length===0)return e;if(ri.test(e))return JSON.parse(JSON.stringify(e));let t=e.length*3;ai.length<t&&(ai=new Uint8Array(t));let{written:n}=ti.encodeInto(e,ai);return ni.decode(ai.subarray(0,n))}function ci(e,t,n){try{return li(e,t,n)}finally{oi()}}function li(e,t,n=!1){let r=Di(e),i=r?gi(e):_i(e),a,o=[];for(let e of i){if(r&&!Lr.test(e)){if(a==null)a=si(e);else if(n)throw Error(`parsePatchContent: unknown file blob`);else console.error(`parsePatchContent: unknown file blob:`,e);continue}else if(!r&&!vi(e)){if(a==null)a=si(e);else if(n)throw Error(`parsePatchContent: unknown file blob`);else console.error(`parsePatchContent: unknown file blob:`,e);continue}let i=di(e,{cacheKey:t==null?void 0:`${t}-${o.length}`,isGitDiff:r,throwOnError:n});i!=null&&o.push(i)}return{patchMetadata:a,files:o}}function ui(e,t){try{return di(e,t)}finally{oi()}}function di(e,{cacheKey:t,isGitDiff:n=Lr.test(e),oldFile:r,newFile:i,throwOnError:a=!1}={}){let o=0,s=Oi(e,`@@ `),c,l=r==null||i==null,u=0,d=0;for(let e of s){let s=hi(e),f=s[0];if(f==null){if(a)throw Error(`parsePatchContent: invalid hunk`);console.error(`parsePatchContent: invalid hunk`,e);continue}let p=wi(f),m=0,h=0;if(p==null||c==null){if(c!=null){if(a)throw Error(`parsePatchContent: Invalid hunk`);console.error(`parsePatchContent: Invalid hunk`,e);continue}c={name:``,type:`change`,hunks:[],splitLineCount:0,unifiedLineCount:0,isPartial:l,additionLines:!l&&r!=null&&i!=null?mi(i.contents):[],deletionLines:!l&&r!=null&&i!=null?mi(r.contents):[],cacheKey:Ai(t)},c.additionLines.length===1&&i?.contents===``&&(c.additionLines.length=0),c.deletionLines.length===1&&r?.contents===``&&(c.deletionLines.length=0);for(let e of s){if(e.startsWith(`diff --git`)){let t=e.trim().match(Br),n=t?.[1]??t?.[2],r=t?.[3]??t?.[4];if(n==null||r==null){if(a)throw Error(`parsePatchContent: invalid git diff header`);console.error(`parsePatchContent: invalid git diff header`,e);continue}c.name=si(r.trim()),n!==r&&(c.prevName=si(n.trim()));continue}let t=e.startsWith(`---`)||e.startsWith(`+++`)?e.match(n?zr:Rr):null;if(t!=null){let[,e,n]=t;if(e===`---`&&n!==`/dev/null`){let e=si(n.trim());c.prevName=e,c.name=e}else e===`+++`&&n!==`/dev/null`&&(c.name=si(n.trim()))}else if(n){if(e.startsWith(`new mode `)&&(c.mode=si(e.slice(8).trim())),e.startsWith(`old mode `)&&(c.prevMode=si(e.slice(8).trim())),e.startsWith(`new file mode`)&&(c.type=`new`,c.mode=si(e.slice(13).trim())),e.startsWith(`deleted file mode`)&&(c.type=`deleted`,c.mode=si(e.slice(17).trim())),e.startsWith(`similarity index`)&&(e.startsWith(`similarity index 100%`)?c.type=`rename-pure`:c.type=`rename-changed`),e.startsWith(`index `)){let[,t,n,r]=e.trim().match(Vr)??[];t!=null&&(c.prevObjectId=si(t)),n!=null&&(c.newObjectId=si(n)),r!=null&&(c.mode=si(r))}e.startsWith(`rename from `)&&(c.prevName=si(e.slice(12).trim())),e.startsWith(`rename to `)&&(c.name=si(e.slice(10).trim()))}}continue}let g,_;for(;s.length>0&&(s[s.length-1]===`
3
+ `||s[s.length-1]===`\r`||s[s.length-1]===`\r
4
+ `||s[s.length-1]===``);)s.pop();let{additionStart:v,deletionStart:y}=p;u=l?u:y-1,d=l?d:v-1;let b={collapsedBefore:0,splitLineCount:0,splitLineStart:0,unifiedLineCount:0,unifiedLineStart:0,additionCount:p.additionCount,additionStart:v,additionLines:m,deletionCount:p.deletionCount,deletionStart:y,deletionLines:h,deletionLineIndex:u,additionLineIndex:d,hunkContent:[],hunkContext:Ai(p.hunkContext),hunkSpecs:si(f),noEOFCRAdditions:!1,noEOFCRDeletions:!1},x=0,S=0;for(let e=1;e<s.length;e++){let t=s[e];if(x>=b.additionCount&&S>=b.deletionCount&&!t.startsWith(`\\`)){if(a&&Si(t)&&!Ci(t))throw Error(`parsePatchContent: hunk has more lines than expected`);break}let n=t[0];if(n!==`+`&&n!==`-`&&n!==` `&&n!==`\\`){if(a)throw Error(`parsePatchContent: invalid hunk line`);console.error(`parseLineType: Invalid firstChar: "${n}", full line: "${t}"`),console.error(`processFile: invalid rawLine:`,t);continue}let r=ji(n);if(r===`addition`){if(a&&x>=b.additionCount)throw Error(`parsePatchContent: hunk has too many addition lines`);let e=Mi(t);(g==null||g.type!==`change`)&&(g=Ni(`change`,u,d),b.hunkContent.push(g)),d++,x++,l&&c.additionLines.push(e),g.additions++,m++,_=`addition`}else if(r===`deletion`){if(a&&S>=b.deletionCount)throw Error(`parsePatchContent: hunk has too many deletion lines`);let e=Mi(t);(g==null||g.type!==`change`)&&(g=Ni(`change`,u,d),b.hunkContent.push(g)),u++,S++,l&&c.deletionLines.push(e),g.deletions++,h++,_=`deletion`}else if(r===`context`){if(a&&(S>=b.deletionCount||x>=b.additionCount))throw Error(`parsePatchContent: hunk has too many context lines`);let e=Mi(t);(g==null||g.type!==`context`)&&(g=Ni(`context`,u,d),b.hunkContent.push(g)),d++,u++,x++,S++,l&&(c.deletionLines.push(e),c.additionLines.push(e)),g.lines++,_=`context`}else if(r===`metadata`&&g!=null){if(g.type===`context`?(b.noEOFCRAdditions=!0,b.noEOFCRDeletions=!0):_===`deletion`?b.noEOFCRDeletions=!0:_===`addition`&&(b.noEOFCRAdditions=!0),l&&(_===`addition`||_===`context`)){let e=c.additionLines.length-1;e>=0&&(c.additionLines[e]=ei(c.additionLines[e]))}if(l&&(_===`deletion`||_===`context`)){let e=c.deletionLines.length-1;e>=0&&(c.deletionLines[e]=ei(c.deletionLines[e]))}}}if(a&&(x!==b.additionCount||S!==b.deletionCount))throw Error(`parsePatchContent: hunk line count mismatch`);b.additionLines=m,b.deletionLines=h,b.collapsedBefore=Math.max(b.additionStart-1-o,0),c.hunks.push(b),o=b.additionStart+b.additionCount-1;for(let e of b.hunkContent)e.type===`context`?(b.splitLineCount+=e.lines,b.unifiedLineCount+=e.lines):(b.splitLineCount+=Math.max(e.additions,e.deletions),b.unifiedLineCount+=e.deletions+e.additions);b.splitLineStart=c.splitLineCount+b.collapsedBefore,b.unifiedLineStart=c.unifiedLineCount+b.collapsedBefore,c.splitLineCount+=b.collapsedBefore+b.splitLineCount,c.unifiedLineCount+=b.collapsedBefore+b.unifiedLineCount}if(c!=null){if(a&&l&&!n&&c.hunks.length===0)throw Error(`parsePatchContent: unified file has no hunks`);if(c.hunks.length>0&&!l&&c.additionLines.length>0&&c.deletionLines.length>0){let e=c.hunks[c.hunks.length-1],t=e.additionStart+e.additionCount-1,n=c.additionLines.length,r=Math.max(n-t,0);c.splitLineCount+=r,c.unifiedLineCount+=r}return n||(c.prevName!=null&&c.name!==c.prevName?c.hunks.length>0?c.type=`rename-changed`:c.type=`rename-pure`:(r==null||r.contents===``)&&i!=null&&i.contents!==``?c.type=`new`:r!=null&&r.contents!==``&&(i==null||i.contents===``)&&(c.type=`deleted`)),c.type!==`rename-pure`&&c.type!==`rename-changed`&&(c.prevName=void 0),c}}function fi(e,t,n=!1){let r=[],i=pi(e)?e.split(Ir):[e];for(let e of i)try{r.push(ci(e,t==null?void 0:`${t}-${r.length}`,n))}catch(e){if(n)throw e;console.error(e)}return r}function pi(e){return e.startsWith(`From `)||e.includes(`
5
+ From `)}function mi(e){let t=hi(e);for(let e=0;e<t.length;e++)t[e]=si(t[e]);return t}function hi(e){if(e.length===0)return[``];let t=[],n=0;for(;;){let r=e.indexOf(`
6
+ `,n);if(r===-1)break;t.push(e.slice(n,r+1)),n=r+1}return n<e.length&&t.push(e.slice(n)),t}function gi(e){return Oi(e,`diff --git`)}function _i(e){if(e.length===0)return[``];let t=[],n=0,r=0,i=0,a=0,o=!1;for(;r<e.length;){let s=xi(e,r);if(i<=0&&a<=0){if(yi(e,r)){r>n&&t.push(e.slice(n,r)),n=r,o=!0,r=xi(e,s);continue}if(o&&e.startsWith(`@@ -`,r)){let t=wi(e.slice(r,s));t!=null&&(i=t.deletionCount,a=t.additionCount)}r=s;continue}let c=e[r];if(c===`\\`){r=s;continue}c===` `?(i=Math.max(i-1,0),a=Math.max(a-1,0)):c===`-`?i=Math.max(i-1,0):c===`+`&&(a=Math.max(a-1,0)),r=s}return t.push(e.slice(n)),t}function vi(e){return yi(e,0)}function yi(e,t){let n=xi(e,t);return bi(e,t,`---`)&&bi(e,n,`+++`)}function bi(e,t,n){if(!e.startsWith(n,t))return!1;let r=e[t+n.length];if(r!==` `&&r!==` `)return!1;for(let r=t+n.length+1;r<e.length;r++){let t=e[r];if(t===`
7
+ `||t===`\r`)break;if(t!==` `&&t!==` `)return!0}return!1}function xi(e,t){let n=e.indexOf(`
8
+ `,t);return n===-1?e.length:n+1}function Si(e){let t=e[0];return t===`+`||t===`-`||t===` `}function Ci(e){if(!e.startsWith(`--`))return!1;for(let t=2;t<e.length;t++){let n=e[t];if(n!==` `&&n!==` `&&n!==`
9
+ `&&n!==`\r`)return!1}return!0}function wi(e){if(!e.startsWith(`@@ -`))return;let t=4,n=Ti(e,t);if(n==null)return;let r=n.value;t=n.endIndex;let i=1;if(e[t]===`,`){let n=Ti(e,t+1);if(n==null)return;i=n.value,t=n.endIndex}if(e[t]!==` `||e[t+1]!==`+`)return;t+=2;let a=Ti(e,t);if(a==null)return;let o=a.value;t=a.endIndex;let s=1;if(e[t]===`,`){let n=Ti(e,t+1);if(n==null)return;s=n.value,t=n.endIndex}if(e[t]!==` `||e[t+1]!==`@`||e[t+2]!==`@`)return;let c,l=t+3;return e[l]===` `&&(c=Ei(e.slice(l+1))),{additionCount:s,additionStart:o,deletionCount:i,deletionStart:r,hunkContext:c}}function Ti(e,t){let n=t,r=0;for(;n<e.length;n++){let t=e.charCodeAt(n)-48;if(t<0||t>9)break;r=r*10+t}if(n!==t)return{value:r,endIndex:n}}function Ei(e){return e.endsWith(`\r
10
+ `)?e.slice(0,-2):e.endsWith(`
11
+ `)?e.slice(0,-1):e}function Di(e){return e.startsWith(`diff --git`)||e.includes(`
12
+ diff --git`)}function Oi(e,t){if(e.length===0)return[``];let n=`\n${t}`,r=e.startsWith(t)?0:ki(e,n,0);if(r===-1)return[e];let i=[];r>0&&i.push(e.slice(0,r));let a=r;for(;;){let t=ki(e,n,a+1);if(t===-1)break;i.push(e.slice(a,t)),a=t}return i.push(e.slice(a)),i}function ki(e,t,n){let r=e.indexOf(t,n);return r===-1?-1:r+1}function Ai(e){return e==null?e:si(e)}function ji(e){return e===` `?`context`:e===`\\`?`metadata`:e===`+`?`addition`:`deletion`}function Mi(e){let t=e.slice(1);return si(t===``?`
13
+ `:t)}function Ni(e,t,n){return e===`change`?{type:`change`,additions:0,deletions:0,additionLineIndex:n,deletionLineIndex:t}:{type:`context`,lines:0,additionLineIndex:n,deletionLineIndex:t}}function Pi(e,t){return e==null||t==null||typeof e==`string`||typeof t==`string`?e===t:e.dark===t.dark&&e.light===t.light}function Fi(e){if(typeof HTMLStyleElement<`u`&&e instanceof HTMLStyleElement)return!0;let t=e.tagName??e.nodeName;return typeof t==`string`&&t.toLowerCase()===`style`}function Ii(e,t){return e?.start===t?.start&&e?.end===t?.end&&e?.side===t?.side&&e?.endSide===t?.endSide}function Li(e,t){return e.lineNumber===t.lineNumber&&e.side===t.side}function Ri(e){return{type:`text`,value:e}}function zi({tagName:e,children:t=[],properties:n={}}){return{type:`element`,tagName:e,properties:n,children:t}}function Bi({name:e,width:t=16,height:n=16,properties:r}){return zi({tagName:`svg`,properties:{width:t,height:n,viewBox:`0 0 16 16`,...r},children:[zi({tagName:`use`,properties:{href:`#${e.replace(/^#/,``)}`}})]})}function Vi(e){let t=e.children[0];for(;t!=null;){if(t.type===`element`&&t.tagName===`code`)return t;t=`children`in t?t.children[0]:null}}function Hi(e){return zi({tagName:`div`,properties:{"data-gutter":``},children:e})}function Ui(e,t,n,r={}){return zi({tagName:`div`,properties:{"data-line-type":e,"data-column-number":t,"data-line-index":n,...r},children:t==null?void 0:[zi({tagName:`span`,properties:{"data-line-number-content":``},children:[Ri(`${t}`)]})]})}function Wi(e,t,n){return zi({tagName:`div`,properties:{"data-gutter-buffer":t,"data-buffer-size":n,"data-line-type":t===`annotation`?void 0:e,style:t===`annotation`?`grid-row: span ${n};`:`grid-row: span ${n};min-height:calc(${n} * 1lh);`}})}function Gi(){return zi({tagName:`button`,properties:{"data-utility-button":``,type:`button`},children:[Bi({name:`diffs-icon-plus`,properties:{"data-icon":``}})]})}var Ki=[`area`,`base`,`basefont`,`bgsound`,`br`,`col`,`command`,`embed`,`frame`,`hr`,`image`,`img`,`input`,`keygen`,`link`,`meta`,`param`,`source`,`track`,`wbr`],qi=class{constructor(e,t,n){this.normal=t,this.property=e,n&&(this.space=n)}};qi.prototype.normal={},qi.prototype.property={},qi.prototype.space=void 0;function Ji(e,t){let n={},r={};for(let t of e)Object.assign(n,t.property),Object.assign(r,t.normal);return new qi(n,r,t)}function Yi(e){return e.toLowerCase()}var Xi=class{constructor(e,t){this.attribute=t,this.property=e}};Xi.prototype.attribute=``,Xi.prototype.booleanish=!1,Xi.prototype.boolean=!1,Xi.prototype.commaOrSpaceSeparated=!1,Xi.prototype.commaSeparated=!1,Xi.prototype.defined=!1,Xi.prototype.mustUseProperty=!1,Xi.prototype.number=!1,Xi.prototype.overloadedBoolean=!1,Xi.prototype.property=``,Xi.prototype.spaceSeparated=!1,Xi.prototype.space=void 0;var Zi=t({boolean:()=>U,booleanish:()=>$i,commaOrSpaceSeparated:()=>ra,commaSeparated:()=>na,number:()=>W,overloadedBoolean:()=>ea,spaceSeparated:()=>ta}),Qi=0,U=ia(),$i=ia(),ea=ia(),W=ia(),ta=ia(),na=ia(),ra=ia();function ia(){return 2**++Qi}var aa=Object.keys(Zi),oa=class extends Xi{constructor(e,t,n,r){let i=-1;if(super(e,t),sa(this,`space`,r),typeof n==`number`)for(;++i<aa.length;){let e=aa[i];sa(this,aa[i],(n&Zi[e])===Zi[e])}}};oa.prototype.defined=!0;function sa(e,t,n){n&&(e[t]=n)}function ca(e){let t={},n={};for(let[r,i]of Object.entries(e.properties)){let a=new oa(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[Yi(r)]=r,n[Yi(a.attribute)]=r}return new qi(t,n,e.space)}var la=ca({properties:{ariaActiveDescendant:null,ariaAtomic:$i,ariaAutoComplete:null,ariaBusy:$i,ariaChecked:$i,ariaColCount:W,ariaColIndex:W,ariaColSpan:W,ariaControls:ta,ariaCurrent:null,ariaDescribedBy:ta,ariaDetails:null,ariaDisabled:$i,ariaDropEffect:ta,ariaErrorMessage:null,ariaExpanded:$i,ariaFlowTo:ta,ariaGrabbed:$i,ariaHasPopup:null,ariaHidden:$i,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:ta,ariaLevel:W,ariaLive:null,ariaModal:$i,ariaMultiLine:$i,ariaMultiSelectable:$i,ariaOrientation:null,ariaOwns:ta,ariaPlaceholder:null,ariaPosInSet:W,ariaPressed:$i,ariaReadOnly:$i,ariaRelevant:null,ariaRequired:$i,ariaRoleDescription:ta,ariaRowCount:W,ariaRowIndex:W,ariaRowSpan:W,ariaSelected:$i,ariaSetSize:W,ariaSort:null,ariaValueMax:W,ariaValueMin:W,ariaValueNow:W,ariaValueText:null,role:null},transform(e,t){return t===`role`?t:`aria-`+t.slice(4).toLowerCase()}});function ua(e,t){return t in e?e[t]:t}function da(e,t){return ua(e,t.toLowerCase())}var fa=ca({attributes:{acceptcharset:`accept-charset`,classname:`class`,htmlfor:`for`,httpequiv:`http-equiv`},mustUseProperty:[`checked`,`multiple`,`muted`,`selected`],properties:{abbr:null,accept:na,acceptCharset:ta,accessKey:ta,action:null,allow:null,allowFullScreen:U,allowPaymentRequest:U,allowUserMedia:U,alpha:U,alt:null,as:null,async:U,autoCapitalize:null,autoComplete:ta,autoFocus:U,autoPlay:U,blocking:ta,capture:null,charSet:null,checked:U,cite:null,className:ta,closedBy:null,colorSpace:null,cols:W,colSpan:W,command:null,commandFor:null,content:null,contentEditable:$i,controls:U,controlsList:ta,coords:W|na,crossOrigin:null,data:null,dateTime:null,decoding:null,default:U,defer:U,dir:null,dirName:null,disabled:U,download:ea,draggable:$i,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:U,formTarget:null,headers:ta,height:W,hidden:ea,high:W,href:null,hrefLang:null,htmlFor:ta,httpEquiv:ta,id:null,imageSizes:null,imageSrcSet:null,inert:U,inputMode:null,integrity:null,is:null,isMap:U,itemId:null,itemProp:ta,itemRef:ta,itemScope:U,itemType:ta,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:U,low:W,manifest:null,max:null,maxLength:W,media:null,method:null,min:null,minLength:W,multiple:U,muted:U,name:null,nonce:null,noModule:U,noValidate:U,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:U,optimum:W,pattern:null,ping:ta,placeholder:null,playsInline:U,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:U,referrerPolicy:null,rel:ta,required:U,reversed:U,rows:W,rowSpan:W,sandbox:ta,scope:null,scoped:U,seamless:U,selected:U,shadowRootClonable:U,shadowRootCustomElementRegistry:U,shadowRootDelegatesFocus:U,shadowRootMode:null,shadowRootSerializable:U,shape:null,size:W,sizes:null,slot:null,span:W,spellCheck:$i,src:null,srcDoc:null,srcLang:null,srcSet:null,start:W,step:null,style:null,tabIndex:W,target:null,title:null,translate:null,type:null,typeMustMatch:U,useMap:null,value:$i,width:W,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:ta,axis:null,background:null,bgColor:null,border:W,borderColor:null,bottomMargin:W,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:U,declare:U,event:null,face:null,frame:null,frameBorder:null,hSpace:W,leftMargin:W,link:null,longDesc:null,lowSrc:null,marginHeight:W,marginWidth:W,noResize:U,noHref:U,noShade:U,noWrap:U,object:null,profile:null,prompt:null,rev:null,rightMargin:W,rules:null,scheme:null,scrolling:$i,standby:null,summary:null,text:null,topMargin:W,valueType:null,version:null,vAlign:null,vLink:null,vSpace:W,allowTransparency:null,autoCorrect:null,autoSave:null,credentialless:U,disablePictureInPicture:U,disableRemotePlayback:U,exportParts:na,part:ta,prefix:null,property:null,results:W,security:null,unselectable:null},space:`html`,transform:da}),pa=ca({attributes:{accentHeight:`accent-height`,alignmentBaseline:`alignment-baseline`,arabicForm:`arabic-form`,baselineShift:`baseline-shift`,capHeight:`cap-height`,className:`class`,clipPath:`clip-path`,clipRule:`clip-rule`,colorInterpolation:`color-interpolation`,colorInterpolationFilters:`color-interpolation-filters`,colorProfile:`color-profile`,colorRendering:`color-rendering`,crossOrigin:`crossorigin`,dataType:`datatype`,dominantBaseline:`dominant-baseline`,enableBackground:`enable-background`,fillOpacity:`fill-opacity`,fillRule:`fill-rule`,floodColor:`flood-color`,floodOpacity:`flood-opacity`,fontFamily:`font-family`,fontSize:`font-size`,fontSizeAdjust:`font-size-adjust`,fontStretch:`font-stretch`,fontStyle:`font-style`,fontVariant:`font-variant`,fontWeight:`font-weight`,glyphName:`glyph-name`,glyphOrientationHorizontal:`glyph-orientation-horizontal`,glyphOrientationVertical:`glyph-orientation-vertical`,hrefLang:`hreflang`,horizAdvX:`horiz-adv-x`,horizOriginX:`horiz-origin-x`,horizOriginY:`horiz-origin-y`,imageRendering:`image-rendering`,letterSpacing:`letter-spacing`,lightingColor:`lighting-color`,markerEnd:`marker-end`,markerMid:`marker-mid`,markerStart:`marker-start`,maskType:`mask-type`,navDown:`nav-down`,navDownLeft:`nav-down-left`,navDownRight:`nav-down-right`,navLeft:`nav-left`,navNext:`nav-next`,navPrev:`nav-prev`,navRight:`nav-right`,navUp:`nav-up`,navUpLeft:`nav-up-left`,navUpRight:`nav-up-right`,onAbort:`onabort`,onActivate:`onactivate`,onAfterPrint:`onafterprint`,onBeforePrint:`onbeforeprint`,onBegin:`onbegin`,onCancel:`oncancel`,onCanPlay:`oncanplay`,onCanPlayThrough:`oncanplaythrough`,onChange:`onchange`,onClick:`onclick`,onClose:`onclose`,onCopy:`oncopy`,onCueChange:`oncuechange`,onCut:`oncut`,onDblClick:`ondblclick`,onDrag:`ondrag`,onDragEnd:`ondragend`,onDragEnter:`ondragenter`,onDragExit:`ondragexit`,onDragLeave:`ondragleave`,onDragOver:`ondragover`,onDragStart:`ondragstart`,onDrop:`ondrop`,onDurationChange:`ondurationchange`,onEmptied:`onemptied`,onEnd:`onend`,onEnded:`onended`,onError:`onerror`,onFocus:`onfocus`,onFocusIn:`onfocusin`,onFocusOut:`onfocusout`,onHashChange:`onhashchange`,onInput:`oninput`,onInvalid:`oninvalid`,onKeyDown:`onkeydown`,onKeyPress:`onkeypress`,onKeyUp:`onkeyup`,onLoad:`onload`,onLoadedData:`onloadeddata`,onLoadedMetadata:`onloadedmetadata`,onLoadStart:`onloadstart`,onMessage:`onmessage`,onMouseDown:`onmousedown`,onMouseEnter:`onmouseenter`,onMouseLeave:`onmouseleave`,onMouseMove:`onmousemove`,onMouseOut:`onmouseout`,onMouseOver:`onmouseover`,onMouseUp:`onmouseup`,onMouseWheel:`onmousewheel`,onOffline:`onoffline`,onOnline:`ononline`,onPageHide:`onpagehide`,onPageShow:`onpageshow`,onPaste:`onpaste`,onPause:`onpause`,onPlay:`onplay`,onPlaying:`onplaying`,onPopState:`onpopstate`,onProgress:`onprogress`,onRateChange:`onratechange`,onRepeat:`onrepeat`,onReset:`onreset`,onResize:`onresize`,onScroll:`onscroll`,onSeeked:`onseeked`,onSeeking:`onseeking`,onSelect:`onselect`,onShow:`onshow`,onStalled:`onstalled`,onStorage:`onstorage`,onSubmit:`onsubmit`,onSuspend:`onsuspend`,onTimeUpdate:`ontimeupdate`,onToggle:`ontoggle`,onUnload:`onunload`,onVolumeChange:`onvolumechange`,onWaiting:`onwaiting`,onZoom:`onzoom`,overlinePosition:`overline-position`,overlineThickness:`overline-thickness`,paintOrder:`paint-order`,panose1:`panose-1`,pointerEvents:`pointer-events`,referrerPolicy:`referrerpolicy`,renderingIntent:`rendering-intent`,shapeRendering:`shape-rendering`,stopColor:`stop-color`,stopOpacity:`stop-opacity`,strikethroughPosition:`strikethrough-position`,strikethroughThickness:`strikethrough-thickness`,strokeDashArray:`stroke-dasharray`,strokeDashOffset:`stroke-dashoffset`,strokeLineCap:`stroke-linecap`,strokeLineJoin:`stroke-linejoin`,strokeMiterLimit:`stroke-miterlimit`,strokeOpacity:`stroke-opacity`,strokeWidth:`stroke-width`,tabIndex:`tabindex`,textAnchor:`text-anchor`,textDecoration:`text-decoration`,textRendering:`text-rendering`,transformOrigin:`transform-origin`,typeOf:`typeof`,underlinePosition:`underline-position`,underlineThickness:`underline-thickness`,unicodeBidi:`unicode-bidi`,unicodeRange:`unicode-range`,unitsPerEm:`units-per-em`,vAlphabetic:`v-alphabetic`,vHanging:`v-hanging`,vIdeographic:`v-ideographic`,vMathematical:`v-mathematical`,vectorEffect:`vector-effect`,vertAdvY:`vert-adv-y`,vertOriginX:`vert-origin-x`,vertOriginY:`vert-origin-y`,wordSpacing:`word-spacing`,writingMode:`writing-mode`,xHeight:`x-height`,playbackOrder:`playbackorder`,timelineBegin:`timelinebegin`},properties:{about:ra,accentHeight:W,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:W,amplitude:W,arabicForm:null,ascent:W,attributeName:null,attributeType:null,azimuth:W,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:W,by:null,calcMode:null,capHeight:W,className:ta,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:W,diffuseConstant:W,direction:null,display:null,dur:null,divisor:W,dominantBaseline:null,download:U,dx:null,dy:null,edgeMode:null,editable:null,elevation:W,enableBackground:null,end:null,event:null,exponent:W,externalResourcesRequired:null,fill:null,fillOpacity:W,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:na,g2:na,glyphName:na,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:W,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:W,horizOriginX:W,horizOriginY:W,id:null,ideographic:W,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:W,k:W,k1:W,k2:W,k3:W,k4:W,kernelMatrix:ra,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:W,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskType:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:W,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:W,overlineThickness:W,paintOrder:null,panose1:null,path:null,pathLength:W,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:ta,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:W,pointsAtY:W,pointsAtZ:W,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:ra,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:ra,rev:ra,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:ra,requiredFeatures:ra,requiredFonts:ra,requiredFormats:ra,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:W,specularExponent:W,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:W,strikethroughThickness:W,string:null,stroke:null,strokeDashArray:ra,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:W,strokeOpacity:W,strokeWidth:null,style:null,surfaceScale:W,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:ra,tabIndex:W,tableValues:null,target:null,targetX:W,targetY:W,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:ra,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:W,underlineThickness:W,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:W,values:null,vAlphabetic:W,vMathematical:W,vectorEffect:null,vHanging:W,vIdeographic:W,version:null,vertAdvY:W,vertOriginX:W,vertOriginY:W,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:W,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:`svg`,transform:ua}),ma=ca({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:`xlink`,transform(e,t){return`xlink:`+t.slice(5).toLowerCase()}}),ha=ca({attributes:{xmlnsxlink:`xmlns:xlink`},properties:{xmlnsXLink:null,xmlns:null},space:`xmlns`,transform:da}),ga=ca({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:`xml`,transform(e,t){return`xml:`+t.slice(3).toLowerCase()}}),_a=/[A-Z]/g,va=/-[a-z]/g,ya=/^data[-\w.:]+$/i;function ba(e,t){let n=Yi(t),r=t,i=Xi;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)===`data`&&ya.test(t)){if(t.charAt(4)===`-`){let e=t.slice(5).replace(va,Sa);r=`data`+e.charAt(0).toUpperCase()+e.slice(1)}else{let e=t.slice(4);if(!va.test(e)){let n=e.replace(_a,xa);n.charAt(0)!==`-`&&(n=`-`+n),t=`data`+n}}i=oa}return new i(r,t)}function xa(e){return`-`+e.toLowerCase()}function Sa(e){return e.charAt(1).toUpperCase()}var Ca=Ji([la,fa,ma,ha,ga],`html`),wa=Ji([la,pa,ma,ha,ga],`svg`),Ta={}.hasOwnProperty;function Ea(e,t){let n=t||{};function r(t,...n){let i=r.invalid,a=r.handlers;if(t&&Ta.call(t,e)){let n=String(t[e]);i=Ta.call(a,n)?a[n]:r.unknown}if(i)return i.call(this,t,...n)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}var Da=/["&'<>`]/g,Oa=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,ka=/[\x01-\t\v\f\x0E-\x1F\x7F\x81\x8D\x8F\x90\x9D\xA0-\uFFFF]/g,Aa=/[|\\{}()[\]^$+*?.]/g,ja=new WeakMap;function Ma(e,t){if(e=e.replace(t.subset?Na(t.subset):Da,r),t.subset||t.escapeOnly)return e;return e.replace(Oa,n).replace(ka,r);function n(e,n,r){return t.format((e.charCodeAt(0)-55296)*1024+e.charCodeAt(1)-56320+65536,r.charCodeAt(n+2),t)}function r(e,n,r){return t.format(e.charCodeAt(0),r.charCodeAt(n+1),t)}}function Na(e){let t=ja.get(e);return t||(t=Pa(e),ja.set(e,t)),t}function Pa(e){let t=[],n=-1;for(;++n<e.length;)t.push(e[n].replace(Aa,`\\$&`));return RegExp(`(?:`+t.join(`|`)+`)`,`g`)}var Fa=/[\dA-Fa-f]/;function Ia(e,t,n){let r=`&#x`+e.toString(16).toUpperCase();return n&&t&&!Fa.test(String.fromCharCode(t))?r:r+`;`}var La=/\d/;function Ra(e,t,n){let r=`&#`+String(e);return n&&t&&!La.test(String.fromCharCode(t))?r:r+`;`}var za=`AElig.AMP.Aacute.Acirc.Agrave.Aring.Atilde.Auml.COPY.Ccedil.ETH.Eacute.Ecirc.Egrave.Euml.GT.Iacute.Icirc.Igrave.Iuml.LT.Ntilde.Oacute.Ocirc.Ograve.Oslash.Otilde.Ouml.QUOT.REG.THORN.Uacute.Ucirc.Ugrave.Uuml.Yacute.aacute.acirc.acute.aelig.agrave.amp.aring.atilde.auml.brvbar.ccedil.cedil.cent.copy.curren.deg.divide.eacute.ecirc.egrave.eth.euml.frac12.frac14.frac34.gt.iacute.icirc.iexcl.igrave.iquest.iuml.laquo.lt.macr.micro.middot.nbsp.not.ntilde.oacute.ocirc.ograve.ordf.ordm.oslash.otilde.ouml.para.plusmn.pound.quot.raquo.reg.sect.shy.sup1.sup2.sup3.szlig.thorn.times.uacute.ucirc.ugrave.uml.uuml.yacute.yen.yuml`.split(`.`),Ba={nbsp:`\xA0`,iexcl:`¡`,cent:`¢`,pound:`£`,curren:`¤`,yen:`¥`,brvbar:`¦`,sect:`§`,uml:`¨`,copy:`©`,ordf:`ª`,laquo:`«`,not:`¬`,shy:`­`,reg:`®`,macr:`¯`,deg:`°`,plusmn:`±`,sup2:`²`,sup3:`³`,acute:`´`,micro:`µ`,para:`¶`,middot:`·`,cedil:`¸`,sup1:`¹`,ordm:`º`,raquo:`»`,frac14:`¼`,frac12:`½`,frac34:`¾`,iquest:`¿`,Agrave:`À`,Aacute:`Á`,Acirc:`Â`,Atilde:`Ã`,Auml:`Ä`,Aring:`Å`,AElig:`Æ`,Ccedil:`Ç`,Egrave:`È`,Eacute:`É`,Ecirc:`Ê`,Euml:`Ë`,Igrave:`Ì`,Iacute:`Í`,Icirc:`Î`,Iuml:`Ï`,ETH:`Ð`,Ntilde:`Ñ`,Ograve:`Ò`,Oacute:`Ó`,Ocirc:`Ô`,Otilde:`Õ`,Ouml:`Ö`,times:`×`,Oslash:`Ø`,Ugrave:`Ù`,Uacute:`Ú`,Ucirc:`Û`,Uuml:`Ü`,Yacute:`Ý`,THORN:`Þ`,szlig:`ß`,agrave:`à`,aacute:`á`,acirc:`â`,atilde:`ã`,auml:`ä`,aring:`å`,aelig:`æ`,ccedil:`ç`,egrave:`è`,eacute:`é`,ecirc:`ê`,euml:`ë`,igrave:`ì`,iacute:`í`,icirc:`î`,iuml:`ï`,eth:`ð`,ntilde:`ñ`,ograve:`ò`,oacute:`ó`,ocirc:`ô`,otilde:`õ`,ouml:`ö`,divide:`÷`,oslash:`ø`,ugrave:`ù`,uacute:`ú`,ucirc:`û`,uuml:`ü`,yacute:`ý`,thorn:`þ`,yuml:`ÿ`,fnof:`ƒ`,Alpha:`Α`,Beta:`Β`,Gamma:`Γ`,Delta:`Δ`,Epsilon:`Ε`,Zeta:`Ζ`,Eta:`Η`,Theta:`Θ`,Iota:`Ι`,Kappa:`Κ`,Lambda:`Λ`,Mu:`Μ`,Nu:`Ν`,Xi:`Ξ`,Omicron:`Ο`,Pi:`Π`,Rho:`Ρ`,Sigma:`Σ`,Tau:`Τ`,Upsilon:`Υ`,Phi:`Φ`,Chi:`Χ`,Psi:`Ψ`,Omega:`Ω`,alpha:`α`,beta:`β`,gamma:`γ`,delta:`δ`,epsilon:`ε`,zeta:`ζ`,eta:`η`,theta:`θ`,iota:`ι`,kappa:`κ`,lambda:`λ`,mu:`μ`,nu:`ν`,xi:`ξ`,omicron:`ο`,pi:`π`,rho:`ρ`,sigmaf:`ς`,sigma:`σ`,tau:`τ`,upsilon:`υ`,phi:`φ`,chi:`χ`,psi:`ψ`,omega:`ω`,thetasym:`ϑ`,upsih:`ϒ`,piv:`ϖ`,bull:`•`,hellip:`…`,prime:`′`,Prime:`″`,oline:`‾`,frasl:`⁄`,weierp:`℘`,image:`ℑ`,real:`ℜ`,trade:`™`,alefsym:`ℵ`,larr:`←`,uarr:`↑`,rarr:`→`,darr:`↓`,harr:`↔`,crarr:`↵`,lArr:`⇐`,uArr:`⇑`,rArr:`⇒`,dArr:`⇓`,hArr:`⇔`,forall:`∀`,part:`∂`,exist:`∃`,empty:`∅`,nabla:`∇`,isin:`∈`,notin:`∉`,ni:`∋`,prod:`∏`,sum:`∑`,minus:`−`,lowast:`∗`,radic:`√`,prop:`∝`,infin:`∞`,ang:`∠`,and:`∧`,or:`∨`,cap:`∩`,cup:`∪`,int:`∫`,there4:`∴`,sim:`∼`,cong:`≅`,asymp:`≈`,ne:`≠`,equiv:`≡`,le:`≤`,ge:`≥`,sub:`⊂`,sup:`⊃`,nsub:`⊄`,sube:`⊆`,supe:`⊇`,oplus:`⊕`,otimes:`⊗`,perp:`⊥`,sdot:`⋅`,lceil:`⌈`,rceil:`⌉`,lfloor:`⌊`,rfloor:`⌋`,lang:`〈`,rang:`〉`,loz:`◊`,spades:`♠`,clubs:`♣`,hearts:`♥`,diams:`♦`,quot:`"`,amp:`&`,lt:`<`,gt:`>`,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:`€`},Va=[`cent`,`copy`,`divide`,`gt`,`lt`,`not`,`para`,`times`],Ha={}.hasOwnProperty,Ua={},Wa;for(Wa in Ba)Ha.call(Ba,Wa)&&(Ua[Ba[Wa]]=Wa);var Ga=/[^\dA-Za-z]/;function Ka(e,t,n,r){let i=String.fromCharCode(e);if(Ha.call(Ua,i)){let e=Ua[i],a=`&`+e;return n&&za.includes(e)&&!Va.includes(e)&&(!r||t&&t!==61&&Ga.test(String.fromCharCode(t)))?a:a+`;`}return``}function qa(e,t,n){let r=Ia(e,t,n.omitOptionalSemicolons),i;if((n.useNamedReferences||n.useShortestReferences)&&(i=Ka(e,t,n.omitOptionalSemicolons,n.attribute)),(n.useShortestReferences||!i)&&n.useShortestReferences){let i=Ra(e,t,n.omitOptionalSemicolons);i.length<r.length&&(r=i)}return i&&(!n.useShortestReferences||i.length<r.length)?i:r}function Ja(e,t){return Ma(e,Object.assign({format:qa},t))}var Ya=/^>|^->|<!--|-->|--!>|<!-$/g,Xa=[`>`],Za=[`<`,`>`];function Qa(e,t,n,r){return r.settings.bogusComments?`<?`+Ja(e.value,Object.assign({},r.settings.characterReferences,{subset:Xa}))+`>`:`<!--`+e.value.replace(Ya,i)+`-->`;function i(e){return Ja(e,Object.assign({},r.settings.characterReferences,{subset:Za}))}}function $a(e,t,n,r){return`<!`+(r.settings.upperDoctype?`DOCTYPE`:`doctype`)+(r.settings.tightDoctype?``:` `)+`html>`}function eo(e,t){let n=String(e);if(typeof t!=`string`)throw TypeError(`Expected character`);let r=0,i=n.indexOf(t);for(;i!==-1;)r++,i=n.indexOf(t,i+t.length);return r}function to(e,t){let n=t||{};return(e[e.length-1]===``?[...e,``]:e).join((n.padRight?` `:``)+`,`+(n.padLeft===!1?``:` `)).trim()}function no(e){return e.join(` `).trim()}var ro=/[ \t\n\f\r]/g;function io(e){return typeof e==`object`?e.type===`text`?ao(e.value):!1:ao(e)}function ao(e){return e.replace(ro,``)===``}var oo=lo(1),so=lo(-1),co=[];function lo(e){return t;function t(t,n,r){let i=t?t.children:co,a=(n||0)+e,o=i[a];if(!r)for(;o&&io(o);)a+=e,o=i[a];return o}}var uo={}.hasOwnProperty;function fo(e){return t;function t(t,n,r){return uo.call(e,t.tagName)&&e[t.tagName](t,n,r)}}var po=fo({body:go,caption:mo,colgroup:mo,dd:bo,dt:yo,head:mo,html:ho,li:vo,optgroup:So,option:Co,p:_o,rp:xo,rt:xo,tbody:To,td:Oo,tfoot:Eo,th:Oo,thead:wo,tr:Do});function mo(e,t,n){let r=oo(n,t,!0);return!r||r.type!==`comment`&&!(r.type===`text`&&io(r.value.charAt(0)))}function ho(e,t,n){let r=oo(n,t);return!r||r.type!==`comment`}function go(e,t,n){let r=oo(n,t);return!r||r.type!==`comment`}function _o(e,t,n){let r=oo(n,t);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`):!n||!(n.type===`element`&&(n.tagName===`a`||n.tagName===`audio`||n.tagName===`del`||n.tagName===`ins`||n.tagName===`map`||n.tagName===`noscript`||n.tagName===`video`))}function vo(e,t,n){let r=oo(n,t);return!r||r.type===`element`&&r.tagName===`li`}function yo(e,t,n){let r=oo(n,t);return!!(r&&r.type===`element`&&(r.tagName===`dt`||r.tagName===`dd`))}function bo(e,t,n){let r=oo(n,t);return!r||r.type===`element`&&(r.tagName===`dt`||r.tagName===`dd`)}function xo(e,t,n){let r=oo(n,t);return!r||r.type===`element`&&(r.tagName===`rp`||r.tagName===`rt`)}function So(e,t,n){let r=oo(n,t);return!r||r.type===`element`&&r.tagName===`optgroup`}function Co(e,t,n){let r=oo(n,t);return!r||r.type===`element`&&(r.tagName===`option`||r.tagName===`optgroup`)}function wo(e,t,n){let r=oo(n,t);return!!(r&&r.type===`element`&&(r.tagName===`tbody`||r.tagName===`tfoot`))}function To(e,t,n){let r=oo(n,t);return!r||r.type===`element`&&(r.tagName===`tbody`||r.tagName===`tfoot`)}function Eo(e,t,n){return!oo(n,t)}function Do(e,t,n){let r=oo(n,t);return!r||r.type===`element`&&r.tagName===`tr`}function Oo(e,t,n){let r=oo(n,t);return!r||r.type===`element`&&(r.tagName===`td`||r.tagName===`th`)}var ko=fo({body:Mo,colgroup:No,head:jo,html:Ao,tbody:Po});function Ao(e){let t=oo(e,-1);return!t||t.type!==`comment`}function jo(e){let t=new Set;for(let n of e.children)if(n.type===`element`&&(n.tagName===`base`||n.tagName===`title`)){if(t.has(n.tagName))return!1;t.add(n.tagName)}let n=e.children[0];return!n||n.type===`element`}function Mo(e){let t=oo(e,-1,!0);return!t||t.type!==`comment`&&!(t.type===`text`&&io(t.value.charAt(0)))&&!(t.type===`element`&&(t.tagName===`meta`||t.tagName===`link`||t.tagName===`script`||t.tagName===`style`||t.tagName===`template`))}function No(e,t,n){let r=so(n,t),i=oo(e,-1,!0);return n&&r&&r.type===`element`&&r.tagName===`colgroup`&&po(r,n.children.indexOf(r),n)?!1:!!(i&&i.type===`element`&&i.tagName===`col`)}function Po(e,t,n){let r=so(n,t),i=oo(e,-1);return n&&r&&r.type===`element`&&(r.tagName===`thead`||r.tagName===`tbody`)&&po(r,n.children.indexOf(r),n)?!1:!!(i&&i.type===`element`&&i.tagName===`tr`)}var Fo={name:[[`
14
+ \f\r &/=>`.split(``),`
15
+ \f\r "&'/=>\``.split(``)],[`\0
16
+ \f\r "&'/<=>`.split(``),`\0
17
+ \f\r "&'/<=>\``.split(``)]],unquoted:[[`
18
+ \f\r &>`.split(``),`\0
19
+ \f\r "&'<=>\``.split(``)],[`\0
20
+ \f\r "&'<=>\``.split(``),`\0
21
+ \f\r "&'<=>\``.split(``)]],single:[[`&'`.split(``),`"&'\``.split(``)],[`\0&'`.split(``),`\0"&'\``.split(``)]],double:[[`"&`.split(``),`"&'\``.split(``)],[`\0"&`.split(``),`\0"&'\``.split(``)]]};function Io(e,t,n,r){let i=r.schema,a=i.space===`svg`?!1:r.settings.omitOptionalTags,o=i.space===`svg`?r.settings.closeEmptyElements:r.settings.voids.includes(e.tagName.toLowerCase()),s=[],c;i.space===`html`&&e.tagName===`svg`&&(r.schema=wa);let l=Lo(r,e.properties),u=r.all(i.space===`html`&&e.tagName===`template`?e.content:e);return r.schema=i,u&&(o=!1),(l||!a||!ko(e,t,n))&&(s.push(`<`,e.tagName,l?` `+l:``),o&&(i.space===`svg`||r.settings.closeSelfClosing)&&(c=l.charAt(l.length-1),(!r.settings.tightSelfClosing||c===`/`||c&&c!==`"`&&c!==`'`)&&s.push(` `),s.push(`/`)),s.push(`>`)),s.push(u),!o&&(!a||!po(e,t,n))&&s.push(`</`+e.tagName+`>`),s.join(``)}function Lo(e,t){let n=[],r=-1,i;if(t){for(i in t)if(t[i]!==null&&t[i]!==void 0){let r=Ro(e,i,t[i]);r&&n.push(r)}}for(;++r<n.length;){let t=e.settings.tightAttributes?n[r].charAt(n[r].length-1):void 0;r!==n.length-1&&t!==`"`&&t!==`'`&&(n[r]+=` `)}return n.join(``)}function Ro(e,t,n){let r=ba(e.schema,t),i=e.settings.allowParseErrors&&e.schema.space===`html`?0:1,a=+!e.settings.allowDangerousCharacters,o=e.quote,s;if(r.overloadedBoolean&&(n===r.attribute||n===``)?n=!0:(r.boolean||r.overloadedBoolean)&&(typeof n!=`string`||n===r.attribute||n===``)&&(n=!!n),n==null||n===!1||typeof n==`number`&&Number.isNaN(n))return``;let c=Ja(r.attribute,Object.assign({},e.settings.characterReferences,{subset:Fo.name[i][a]}));return n===!0||(n=Array.isArray(n)?(r.commaSeparated?to:no)(n,{padLeft:!e.settings.tightCommaSeparatedLists}):String(n),e.settings.collapseEmptyAttributes&&!n)?c:(e.settings.preferUnquoted&&(s=Ja(n,Object.assign({},e.settings.characterReferences,{attribute:!0,subset:Fo.unquoted[i][a]}))),s!==n&&(e.settings.quoteSmart&&eo(n,o)>eo(n,e.alternative)&&(o=e.alternative),s=o+Ja(n,Object.assign({},e.settings.characterReferences,{subset:(o===`'`?Fo.single:Fo.double)[i][a],attribute:!0}))+o),c+(s&&`=`+s))}var zo=[`<`,`&`];function Bo(e,t,n,r){return n&&n.type===`element`&&(n.tagName===`script`||n.tagName===`style`)?e.value:Ja(e.value,Object.assign({},r.settings.characterReferences,{subset:zo}))}function Vo(e,t,n,r){return r.settings.allowDangerousHtml?e.value:Bo(e,t,n,r)}function Ho(e,t,n,r){return r.all(e)}var Uo=Ea(`type`,{invalid:Wo,unknown:Go,handlers:{comment:Qa,doctype:$a,element:Io,raw:Vo,root:Ho,text:Bo}});function Wo(e){throw Error("Expected node, not `"+e+"`")}function Go(e){throw Error("Cannot compile unknown node `"+e.type+"`")}var Ko={},qo={},Jo=[];function Yo(e,t){let n=t||Ko,r=n.quote||`"`,i=r===`"`?`'`:`"`;if(r!==`"`&&r!==`'`)throw Error("Invalid quote `"+r+"`, expected `'` or `\"`");return{one:Xo,all:Zo,settings:{omitOptionalTags:n.omitOptionalTags||!1,allowParseErrors:n.allowParseErrors||!1,allowDangerousCharacters:n.allowDangerousCharacters||!1,quoteSmart:n.quoteSmart||!1,preferUnquoted:n.preferUnquoted||!1,tightAttributes:n.tightAttributes||!1,upperDoctype:n.upperDoctype||!1,tightDoctype:n.tightDoctype||!1,bogusComments:n.bogusComments||!1,tightCommaSeparatedLists:n.tightCommaSeparatedLists||!1,tightSelfClosing:n.tightSelfClosing||!1,collapseEmptyAttributes:n.collapseEmptyAttributes||!1,allowDangerousHtml:n.allowDangerousHtml||!1,voids:n.voids||Ki,characterReferences:n.characterReferences||qo,closeSelfClosing:n.closeSelfClosing||!1,closeEmptyElements:n.closeEmptyElements||!1},schema:n.space===`svg`?wa:Ca,quote:r,alternative:i}.one(Array.isArray(e)?{type:`root`,children:e}:e,void 0,void 0)}function Xo(e,t,n){return Uo(e,t,n,this)}function Zo(e){let t=[],n=e&&e.children||Jo,r=-1;for(;++r<n.length;)t[r]=this.one(n[r],r,e);return t.join(``)}var Qo=class{mode;options;hoveredLine;hoveredToken;pre;gutterUtilityLine;gutterUtilityContainer;gutterUtilityButton;gutterUtilitySlot;interactiveLinesAttr=!1;interactiveLineNumbersAttr=!1;hasPointerListeners=!1;hasDocumentPointerListeners=!1;selectedRange=null;proposedSelectedRange;renderedSelectionRange;selectionAnchor;queuedSelectionRender;pointerSession={mode:`idle`};constructor(e,t){this.mode=e,this.options=t}setOptions(e){this.options=e}cleanUp(){this.pre?.removeEventListener(`click`,this.handlePointerClick),this.pre?.removeEventListener(`pointerdown`,this.handlePointerDown),this.pre?.removeEventListener(`pointermove`,this.handlePointerMove),this.pre?.removeEventListener(`pointerleave`,this.handlePointerLeave),this.pre?.removeAttribute(`data-interactive-lines`),this.pre?.removeAttribute(`data-interactive-line-numbers`),this.pre=void 0,this.gutterUtilityContainer?.remove(),this.gutterUtilityLine=void 0,this.gutterUtilityContainer=void 0,this.gutterUtilityButton=void 0,this.gutterUtilitySlot=void 0,this.clearHoveredLine(),this.clearHoveredToken(),this.detachDocumentPointerListeners(),this.clearPointerSession(),this.queuedSelectionRender!=null&&(cancelAnimationFrame(this.queuedSelectionRender),this.queuedSelectionRender=void 0),this.interactiveLinesAttr=!1,this.interactiveLineNumbersAttr=!1,this.hasPointerListeners=!1}setup(e){this.setSelectionDirty();let{usesCustomGutterUtility:t=!1,enableGutterUtility:n=!1}=this.options;this.pre!==e&&(this.cleanUp(),this.pre=e),n?this.ensureGutterUtilityNode(t):this.gutterUtilityContainer!=null&&(this.gutterUtilityContainer.remove(),this.gutterUtilityLine=void 0,this.gutterUtilityContainer=void 0,this.gutterUtilityButton=void 0,this.gutterUtilitySlot=void 0,this.pointerSession.mode===`gutterSelecting`&&(this.clearPointerSession(),this.detachDocumentPointerListeners())),this.syncPointerListeners(e),this.updateInteractiveLineAttributes(),this.renderSelection(),this.placeUtility()}setSelectionDirty(){this.renderedSelectionRange=void 0}isSelectionDirty(){return this.renderedSelectionRange===null}setSelection(e,t){let n=!(e===this.selectedRange||Ii(e??void 0,this.selectedRange??void 0));!this.isSelectionDirty()&&!n||(this.proposedSelectedRange=void 0,this.selectedRange=e,this.renderSelection(),this.placeUtility(),n&&t?.notify!==!1&&this.notifySelectionCommitted())}getSelection(){return this.selectedRange}getHoveredLine=()=>{let e=this.gutterUtilityLine??this.hoveredLine;if(e!=null){if(this.mode===`diff`&&e.type===`diff-line`)return{lineNumber:e.lineNumber,side:e.annotationSide};if(this.mode===`file`&&e.type===`line`)return{lineNumber:e.lineNumber}}};handlePointerClick=e=>{let{onHunkExpand:t,onLineClick:n,onLineNumberClick:r,onTokenClick:i,onMergeConflictActionClick:a}=this.options;t==null&&n==null&&r==null&&a==null&&i==null||this.options.onGutterUtilityClick!=null&&hs(e.composedPath())||(gs(this.options.__debugPointerEvents,`click`,`FileDiff.DEBUG.handlePointerClick:`,e),this.handlePointerEvent({eventType:`click`,event:e}))};handlePointerMove=e=>{if(e.pointerType!==`mouse`)return;let{lineHoverHighlight:t=`disabled`,onLineEnter:n,onLineLeave:r,onTokenEnter:i,onTokenLeave:a,enableGutterUtility:o=!1}=this.options;t===`disabled`&&!o&&n==null&&r==null&&i==null&&a==null||(gs(this.options.__debugPointerEvents,`move`,`FileDiff.DEBUG.handlePointerMove:`,e),this.handlePointerEvent({eventType:`move`,event:e}))};handlePointerLeave=e=>{let{__debugPointerEvents:t}=this.options;if(gs(t,`move`,`FileDiff.DEBUG.handlePointerLeave: no event`),this.hoveredLine==null&&this.hoveredToken==null){gs(t,`move`,`FileDiff.DEBUG.handlePointerLeave: returned early, no hovered line or token`);return}this.hoveredToken!=null&&(this.options.onTokenLeave?.(this.hoveredToken,e),this.clearHoveredToken()),this.hoveredLine!=null&&(this.options.onLineLeave?.({...this.hoveredLine,event:e}),this.clearHoveredLine()),this.placeUtility()};handlePointerEvent({eventType:e,event:t}){let{__debugPointerEvents:n}=this.options,r=t.composedPath();gs(n,e,`FileDiff.DEBUG.handlePointerEvent:`,{eventType:e,composedPath:r});let i=this.resolvePointerTarget(r);gs(n,e,`FileDiff.DEBUG.handlePointerEvent: resolvePointerTarget result:`,i);let{onLineClick:a,onLineNumberClick:o,onLineEnter:s,onLineLeave:c,onTokenClick:l,onTokenEnter:u,onTokenLeave:d,onHunkExpand:f,onMergeConflictActionClick:p}=this.options;switch(e){case`move`:{let e=rs(i)&&this.hoveredLine?.lineElement===i.lineElement;ns(i)&&this.hoveredToken?.tokenElement===i.tokenElement||(this.hoveredToken!=null&&(d?.(this.hoveredToken,t),this.clearHoveredToken()),ns(i)&&(this.setHoveredToken(this.toTokenEventBaseProps(i)),u?.(this.hoveredToken,t))),e||(this.hoveredLine!=null&&(c?.({...this.hoveredLine,event:t}),this.clearHoveredLine()),rs(i)?(this.setHoveredLine(this.toEventBaseProps(i)),this.placeUtility(),s?.({...this.hoveredLine,event:t})):this.placeUtility());break}case`click`:{if(i==null)break;if(as(i)&&p!=null){p(i);break}if(is(i)&&f!=null){f(i.hunkIndex,i.all||t.shiftKey?`both`:i.direction,i.all||t.shiftKey?1/0:void 0);break}if(!rs(i))break;ns(i)&&l!=null&&l(this.toTokenEventBaseProps(i),t);let e=this.toEventBaseProps(i);o!=null&&i.numberColumn?o({...e,event:t}):a?.({...e,event:t});break}}}syncPointerListeners(e){let{__debugPointerEvents:t,lineHoverHighlight:n=`disabled`,onLineClick:r,onLineNumberClick:i,onLineEnter:a,onLineLeave:o,onTokenClick:s,onTokenEnter:c,onTokenLeave:l,onHunkExpand:u,onMergeConflictActionClick:d,enableGutterUtility:f=!1,enableLineSelection:p=!1,onGutterUtilityClick:m}=this.options,h=m!=null,g=n!==`disabled`||r!=null||i!=null||a!=null||o!=null||s!=null||c!=null||l!=null||u!=null||d!=null||f||p||h;g&&!this.hasPointerListeners?(e.addEventListener(`click`,this.handlePointerClick),e.addEventListener(`pointerdown`,this.handlePointerDown),e.addEventListener(`pointermove`,this.handlePointerMove),e.addEventListener(`pointerleave`,this.handlePointerLeave),this.hasPointerListeners=!0,gs(t,`click`,`FileDiff.DEBUG.attachEventListeners: Attaching click events for:`,(()=>{let e=[];return(t===`both`||t===`click`)&&(r!=null&&e.push(`onLineClick`),i!=null&&e.push(`onLineNumberClick`),u!=null&&e.push(`expandable hunk separators`),d!=null&&e.push(`merge conflict actions`)),e})()),gs(t,`move`,`FileDiff.DEBUG.attachEventListeners: Attaching pointer move event`),gs(t,`move`,`FileDiff.DEBUG.attachEventListeners: Attaching pointer leave event`)):!g&&this.hasPointerListeners&&(e.removeEventListener(`click`,this.handlePointerClick),e.removeEventListener(`pointerdown`,this.handlePointerDown),e.removeEventListener(`pointermove`,this.handlePointerMove),e.removeEventListener(`pointerleave`,this.handlePointerLeave),this.hasPointerListeners=!1);let _=this.pointerSession.mode===`selecting`||this.pointerSession.mode===`pendingSingleLineUnselect`,v=this.pointerSession.mode===`gutterSelecting`;(!p&&_||!h&&v)&&(this.clearPointerSession(),this.detachDocumentPointerListeners(),this.selectionAnchor=void 0,this.clearPendingSingleLineState())}updateInteractiveLineAttributes(){if(this.pre==null)return;let{onLineClick:e,onLineNumberClick:t,enableLineSelection:n=!1}=this.options,r=e!=null,i=t!=null||n;r&&!this.interactiveLinesAttr?(this.pre.setAttribute(`data-interactive-lines`,``),this.interactiveLinesAttr=!0):!r&&this.interactiveLinesAttr&&(this.pre.removeAttribute(`data-interactive-lines`),this.interactiveLinesAttr=!1),i&&!this.interactiveLineNumbersAttr?(this.pre.setAttribute(`data-interactive-line-numbers`,``),this.interactiveLineNumbersAttr=!0):!i&&this.interactiveLineNumbersAttr&&(this.pre.removeAttribute(`data-interactive-line-numbers`),this.interactiveLineNumbersAttr=!1)}handlePointerDown=e=>{if(e.pointerType===`mouse`&&e.button!==0||this.pre==null||this.pointerSession.mode!==`idle`)return;let t=e.composedPath();hs(t)&&this.options.onGutterUtilityClick!=null?this.startGutterSelectionFromPointerDown(e):(e.pointerType!==`mouse`&&this.revealUtilityFromGutterPath(t),this.startLineSelectionFromPointerDown(e))};startLineSelectionFromPointerDown(e){let{enableLineSelection:t=!1}=this.options;if(!t)return;let n=this.resolveSelectionInfo(e,{source:`event-path`,requireNumberColumn:!0});if(n==null)return;let{pre:r}=this;if(r==null)return;let{lineNumber:i,eventSide:a,lineIndex:o}=n;if(e.shiftKey&&this.selectedRange!=null){let t=this.getIndexesFromSelection(this.selectedRange,r.getAttribute(`data-diff-type`)===`split`);if(t==null)return;let n=t.start<=t.end?o>=t.start:o<=t.end;this.selectionAnchor={lineNumber:n?this.selectedRange.start:this.selectedRange.end,side:n?this.selectedRange.side:this.selectedRange.endSide??this.selectedRange.side},this.updateSelection(i,a,!1),this.notifySelectionStart(this.getCurrentSelectionRange()),this.pointerSession={mode:`selecting`,pointerId:e.pointerId},this.attachDocumentPointerListeners();return}if(this.selectedRange?.start===i&&this.selectedRange?.end===i){let t={lineNumber:i,side:a};this.selectionAnchor=t,this.pointerSession={mode:`pendingSingleLineUnselect`,pointerId:e.pointerId,anchor:t,pending:t},this.attachDocumentPointerListeners();return}this.options.controlledSelection===!0?this.proposedSelectedRange=null:this.selectedRange=null,this.placeUtility(),this.selectionAnchor={lineNumber:i,side:a},this.updateSelection(i,a,!1),this.notifySelectionStart(this.getCurrentSelectionRange()),this.pointerSession={mode:`selecting`,pointerId:e.pointerId},this.attachDocumentPointerListeners()}startGutterSelectionFromPointerDown(e){let{enableLineSelection:t=!1,onGutterUtilityClick:n}=this.options;if(n==null)return;let r=this.currentSelectionEnds(),i=r?.bottom??this.resolveSelectionPoint(e,{source:`event-path`,excludeUtility:!1}),a=r?.top??i;i==null||a==null||(e.preventDefault(),e.stopPropagation(),this.pointerSession={mode:`gutterSelecting`,pointerId:e.pointerId,anchor:a,current:i},t&&(this.selectionAnchor={lineNumber:a.lineNumber,side:a.side},this.updateSelection(i.lineNumber,i.side,!1),this.notifySelectionStart(this.getCurrentSelectionRange())),this.attachDocumentPointerListeners())}handleDocumentPointerMove=e=>{let{enableLineSelection:t=!1}=this.options;switch(this.pointerSession.mode){case`idle`:return;case`gutterSelecting`:{if(e.pointerId!==this.pointerSession.pointerId)return;e.preventDefault();let n=this.resolveSelectionPoint(e,{source:`coordinates-first`});if(n==null)return;this.pointerSession.current=n,t===!0&&this.updateSelection(n.lineNumber,n.side);return}case`selecting`:{if(e.pointerId!==this.pointerSession.pointerId)return;e.preventDefault();let t=this.resolveSelectionInfo(e,{source:`coordinates-first`,requireNumberColumn:!1});if(t==null||this.selectionAnchor==null)return;this.updateSelection(t.lineNumber,t.eventSide);return}case`pendingSingleLineUnselect`:{if(e.pointerId!==this.pointerSession.pointerId)return;e.preventDefault();let t=this.resolveSelectionInfo(e,{source:`coordinates-first`,requireNumberColumn:!1});if(t==null||this.selectionAnchor==null)return;let n={lineNumber:t.lineNumber,side:t.eventSide};if(Li(this.pointerSession.pending,n))return;this.updateSelection(t.lineNumber,t.eventSide,!1),this.notifySelectionStart(this.getCurrentSelectionRange()),this.notifySelectionChangeDelta(),this.pointerSession={mode:`selecting`,pointerId:e.pointerId};return}}};handleDocumentPointerUp=e=>{let{enableLineSelection:t=!1,onGutterUtilityClick:n}=this.options;switch(this.pointerSession.mode){case`idle`:return;case`gutterSelecting`:{if(e.pointerId!==this.pointerSession.pointerId)return;e.preventDefault();let r=this.resolveSelectionPoint(e,{source:`coordinates-first`});r!=null&&(this.pointerSession.current=r,t&&this.updateSelection(r.lineNumber,r.side)),n?.(this.buildSelectedLineRange(this.pointerSession.anchor,this.pointerSession.current)),this.selectionAnchor=void 0,t&&(this.notifySelectionEnd(this.getCurrentSelectionRange()),this.notifySelectionCommitted(),this.clearProposedSelection()),this.clearPointerSession(),this.detachDocumentPointerListeners();return}case`pendingSingleLineUnselect`:if(e.pointerId!==this.pointerSession.pointerId)return;e.preventDefault(),this.updateSelection(null,void 0,!1),this.selectionAnchor=void 0,this.clearPendingSingleLineState(),this.detachDocumentPointerListeners(),this.notifySelectionEnd(this.getCurrentSelectionRange()),this.notifySelectionCommitted(),this.clearProposedSelection();return;case`selecting`:if(e.pointerId!==this.pointerSession.pointerId)return;e.preventDefault(),this.selectionAnchor=void 0,this.detachDocumentPointerListeners(),this.clearPointerSession(),this.notifySelectionEnd(this.getCurrentSelectionRange()),this.notifySelectionCommitted(),this.clearProposedSelection()}};handleDocumentPointerCancel=e=>{switch(this.pointerSession.mode){case`idle`:return;case`gutterSelecting`:case`selecting`:case`pendingSingleLineUnselect`:if(`pointerId`in this.pointerSession&&e.pointerId!==this.pointerSession.pointerId)return;this.selectionAnchor=void 0,this.clearProposedSelection(),this.clearPendingSingleLineState(),this.clearPointerSession(),this.detachDocumentPointerListeners()}};clearHoveredLine(){this.hoveredLine!=null&&(this.hoveredLine.lineElement.removeAttribute(`data-hovered`),this.hoveredLine.numberElement.removeAttribute(`data-hovered`),this.hoveredLine=void 0)}setHoveredLine(e){let{lineHoverHighlight:t=`disabled`}=this.options;this.hoveredLine!=null&&this.clearHoveredLine(),this.hoveredLine=e,t!==`disabled`&&((t===`both`||t===`line`)&&this.hoveredLine.lineElement.setAttribute(`data-hovered`,``),(t===`both`||t===`number`)&&this.hoveredLine.numberElement.setAttribute(`data-hovered`,``))}clearHoveredToken(){this.hoveredToken!=null&&(this.hoveredToken=void 0)}setHoveredToken(e){this.hoveredToken!=null&&this.clearHoveredToken(),this.hoveredToken=e}ensureGutterUtilityNode(e){if(this.gutterUtilityContainer??(this.gutterUtilityContainer=document.createElement(`div`),this.gutterUtilityContainer.setAttribute(`data-gutter-utility-slot`,``)),e)this.gutterUtilityButton!=null&&(this.gutterUtilityButton.remove(),this.gutterUtilityButton=void 0),this.gutterUtilitySlot??(this.gutterUtilitySlot=document.createElement(`slot`),this.gutterUtilitySlot.name=`gutter-utility-slot`),this.gutterUtilitySlot.parentNode!==this.gutterUtilityContainer&&this.gutterUtilityContainer.replaceChildren(this.gutterUtilitySlot);else{if(this.gutterUtilitySlot?.remove(),this.gutterUtilitySlot=void 0,this.gutterUtilityButton==null){let e=document.createElement(`div`);e.innerHTML=Yo(Gi());let t=e.firstElementChild;if(!(t instanceof HTMLButtonElement))throw Error(`InteractionManager.ensureGutterUtilityNode: Node element should be a button`);t.remove(),this.gutterUtilityButton=t}this.gutterUtilityButton.parentNode!==this.gutterUtilityContainer&&this.gutterUtilityContainer.replaceChildren(this.gutterUtilityButton)}}revealUtilityFromGutterPath(e){if(this.placeUtilityFromSelection())return;let t=this.resolvePointerTarget(e);ts(t)&&t.numberColumn&&this.showUtilityOnLine(this.toEventBaseProps(t))}placeUtility(){if(!this.placeUtilityFromSelection()){if(this.hoveredLine!=null){this.showUtilityOnLine(this.hoveredLine);return}this.hideUtility()}}placeUtilityFromSelection(){let e=this.currentSelectionEnds();if(e==null)return!1;let t=this.targetForSelectionPoint(e.bottom);return t==null?this.hideUtility():this.showUtilityOnLine(this.toEventBaseProps(t)),!0}showUtilityOnLine(e){this.gutterUtilityContainer!=null&&(this.gutterUtilityLine=e,e.numberElement.appendChild(this.gutterUtilityContainer))}hideUtility(){this.gutterUtilityContainer?.remove(),this.gutterUtilityLine=void 0}currentSelectionEnds(){let e=this.getCurrentSelectionRange();return e==null?void 0:this.selectionEnds(e)}selectionEnds(e){let t={lineNumber:e.start,side:e.side},n={lineNumber:e.end,side:e.endSide??e.side},r=this.selectionPointRowIndex(t),i=this.selectionPointRowIndex(n);if(!(r==null||i==null))return r>i?{top:n,bottom:t}:{top:t,bottom:n}}selectionPointRowIndex(e){let t=this.getLineIndex(e.lineNumber,e.side);if(t!=null)return this.isSplitDiff()?t[1]:t[0]}targetForSelectionPoint(e){if(this.pre==null)return;let t=this.getLineIndex(e.lineNumber,e.side);if(t==null)return;let n=this.mode===`diff`?`${t[0]},${t[1]}`:`${t[0]}`,r=this.pre.querySelectorAll(`[data-column-number="${e.lineNumber}"][data-line-index="${n}"]`);for(let t of r){if(!(t instanceof HTMLElement))continue;let n=this.resolvePointerTarget(cs(t));if(ts(n)&&!(this.mode===`diff`&&e.side!=null&&n.side!==e.side))return n}}attachDocumentPointerListeners(){this.hasDocumentPointerListeners||=(document.addEventListener(`pointermove`,this.handleDocumentPointerMove),document.addEventListener(`pointerup`,this.handleDocumentPointerUp),document.addEventListener(`pointercancel`,this.handleDocumentPointerCancel),!0)}detachDocumentPointerListeners(){this.hasDocumentPointerListeners&&=(document.removeEventListener(`pointermove`,this.handleDocumentPointerMove),document.removeEventListener(`pointerup`,this.handleDocumentPointerUp),document.removeEventListener(`pointercancel`,this.handleDocumentPointerCancel),!1)}clearPointerSession(){this.pointerSession={mode:`idle`}}clearPendingSingleLineState(){this.pointerSession.mode===`pendingSingleLineUnselect`&&(this.pointerSession={mode:`idle`})}selectionInfoFromPath(e,t){let n=this.resolvePointerTarget(e);if(ts(n)&&!(t&&!n.numberColumn)&&n.splitLineIndex!=null)return{lineIndex:n.splitLineIndex,lineNumber:n.lineNumber,eventSide:this.mode===`diff`?n.side:void 0}}resolveSelectionInfo(e,t){let n=this.resolveSelectionPath(e,t);return n==null?void 0:this.selectionInfoFromPath(n,t.requireNumberColumn)}selectionPointFromPath(e){let t=this.resolvePointerTarget(e);if(ts(t))return{lineNumber:t.lineNumber,side:this.mode===`diff`?t.side:void 0}}resolveSelectionPoint(e,t){let n=this.resolveSelectionPath(e,t);return n==null?void 0:this.selectionPointFromPath(n)}resolveSelectionPath(e,t){let n=t.excludeUtility!==!1;switch(t.source){case`event-path`:return this.pathFromEventPath(e.composedPath(),n);case`coordinates-first`:{let t=this.pathFromCoordinates(e,n);return t===void 0?this.pathFromEventPath(e.composedPath(),n):t??void 0}}}pathFromCoordinates(e,t){let n=this.hitTest(e);if(n!==void 0)return n===null?null:this.pathFromElement(n,t)??null}pathFromEventPath(e,t){if(!(t&&hs(e))){for(let n of e)if(n instanceof Element)return this.pathFromElement(n,t)}}pathFromElement(e,t){let n=cs(e);if(t&&hs(n))return;let r=ls(e);return r==null?this.pathFromAnnotationSlot(e):cs(r)}pathFromAnnotationSlot(e){let t=ds(us(e));if(t==null)return;let n=this.targetForSelectionPoint(t);return n==null?void 0:cs(n.lineElement)}hitTest(e){if(!Number.isFinite(e.clientX)||!Number.isFinite(e.clientY))return;let t=this.pre?.getRootNode(),n=fs(t)?t:fs(document)?document:void 0;if(n!=null)return n.elementFromPoint(e.clientX,e.clientY)}getLineIndex(e,t){let{getLineIndex:n}=this.options;return n==null?[e-1,e-1]:n(e,t)}getCurrentSelectionRange(){return this.proposedSelectedRange===void 0?this.selectedRange:this.proposedSelectedRange}clearProposedSelection(){this.proposedSelectedRange=void 0}updateSelection(e,t,n=!0){let r=this.getCurrentSelectionRange(),i;if(e==null)i=null;else{let n=this.selectionAnchor?.side??t,r=this.selectionAnchor?.lineNumber??e;i=this.buildSelectionRange(r,e,n,t)}Ii(r??void 0,i??void 0)||(this.options.controlledSelection===!0?this.proposedSelectedRange=i:(this.selectedRange=i,this.queuedSelectionRender??=requestAnimationFrame(this.renderSelection)),this.placeUtility(),n&&this.notifySelectionChangeDelta())}getIndexesFromSelection(e,t){if(this.pre==null)return;let n=this.getLineIndex(e.start,e.side),r=this.getLineIndex(e.end,e.endSide??e.side);return n!=null&&r!=null?{start:t?n[1]:n[0],end:t?r[1]:r[0]}:void 0}renderSelection=()=>{if(this.queuedSelectionRender!=null&&(cancelAnimationFrame(this.queuedSelectionRender),this.queuedSelectionRender=void 0),this.pre==null||this.renderedSelectionRange===this.selectedRange)return;let e=this.pre.querySelectorAll(`[data-selected-line]`);for(let t of e)t.removeAttribute(`data-selected-line`);if(this.renderedSelectionRange=this.selectedRange,this.selectedRange==null)return;let{children:t}=this.pre;if(t.length===0)return;if(t.length>2)throw console.error(t),Error(`InteractionManager.renderSelection: Somehow there are more than 2 code elements...`);let n=this.pre.getAttribute(`data-diff-type`)===`split`,r=this.getIndexesFromSelection(this.selectedRange,n);if(r==null)throw console.error({rowRange:r,selectedRange:this.selectedRange}),Error(`InteractionManager.renderSelection: No valid rowRange`);let i=r.start===r.end,a=Math.min(r.start,r.end),o=Math.max(r.start,r.end);for(let e of t){let[t,r]=e.children,s=r.children.length;if(s!==t.children.length)throw Error(`InteractionManager.renderSelection: gutter and content children dont match, something is wrong`);for(let e=0;e<s;e++){let s=r.children[e],c=t.children[e];if(!(s instanceof HTMLElement)||!(c instanceof HTMLElement))continue;let l=this.parseLineIndex(s,n);if((l??0)>o)break;if(l==null||l<a)continue;let u=i?`single`:l===a?`first`:l===o?`last`:``;s.setAttribute(`data-selected-line`,u),c.setAttribute(`data-selected-line`,u),c.nextSibling instanceof HTMLElement&&s.nextSibling instanceof HTMLElement&&(s.nextSibling.hasAttribute(`data-line-annotation`)||s.nextSibling.hasAttribute(`data-merge-conflict-actions`))&&(i?(u=`last`,s.setAttribute(`data-selected-line`,`first`)):l===a?u=``:l===o&&s.setAttribute(`data-selected-line`,``),s.nextSibling.setAttribute(`data-selected-line`,u),c.nextSibling.setAttribute(`data-selected-line`,u))}}};notifySelectionCommitted(){this.options.onLineSelected?.(this.getCurrentSelectionRange()??null)}notifySelectionChangeDelta(){this.options.onLineSelectionChange?.(this.getCurrentSelectionRange()??null)}notifySelectionStart(e){this.options.onLineSelectionStart?.(e)}notifySelectionEnd(e){this.options.onLineSelectionEnd?.(e)}toEventBaseProps(e){return this.mode===`file`?{type:`line`,lineElement:e.lineElement,lineNumber:e.lineNumber,numberColumn:e.numberColumn,numberElement:e.numberElement}:{type:`diff-line`,annotationSide:e.side,lineType:e.lineType,lineElement:e.lineElement,numberElement:e.numberElement,lineNumber:e.lineNumber,numberColumn:e.numberColumn}}toTokenEventBaseProps({lineCharEnd:e,lineCharStart:t,lineNumber:n,side:r,tokenElement:i,tokenText:a}){return this.mode===`file`?{type:`token`,lineCharEnd:e,lineCharStart:t,lineNumber:n,tokenElement:i,tokenText:a}:{type:`token`,lineCharEnd:e,lineCharStart:t,lineNumber:n,side:r,tokenElement:i,tokenText:a}}buildSelectedLineRange(e,t){return this.buildSelectionRange(e.lineNumber,t.lineNumber,e.side,t.side)}buildSelectionRange(e,t,n,r){return{start:e,end:t,...n==null?{}:{side:n},...n!==r&&r!=null?{endSide:r}:{}}}resolvePointerTarget(e){let t=!1,n,r,i,a,o,s,c,l,u,d;for(let f of e){if(!(f instanceof HTMLElement))continue;if(d==null&&f.hasAttribute(`data-merge-conflict-action`)){let e=f.getAttribute(`data-merge-conflict-action`)??void 0,t=f.getAttribute(`data-merge-conflict-conflict-index`)??void 0,n=t==null?NaN:Number.parseInt(t,10);os(e)&&Number.isFinite(n)&&(d={kind:`merge-conflict-action`,resolution:e,conflictIndex:n})}if(s==null&&f.hasAttribute(`data-char`)){s=f;let e=f.getAttribute(`data-char`);if(e!=null){let t=Number.parseInt(e,10);if(!Number.isNaN(t)){let e=f.textContent??``,n=t+e.length;(e.trim()!==``||this.options.enableTokenInteractionsOnWhitespace===!0)&&(c={tokenElement:s,lineCharStart:t,lineCharEnd:n,tokenText:e});continue}}}let e=o==null?f.getAttribute(`data-column-number`)??void 0:void 0;if(e!=null){o=f,u=Number.parseInt(e,10),t=!0,n=ms(f),a=f.getAttribute(`data-line-index`)??void 0;continue}let p=i==null?f.getAttribute(`data-line`)??void 0:void 0;if(p!=null){i=f,u=Number.parseInt(p,10),n=ms(f),a=f.getAttribute(`data-line-index`)??void 0;continue}if(l==null&&(f.hasAttribute(`data-expand-button`)||f.hasAttribute(`data-unmodified-lines`))){l={hunkIndex:void 0,direction:f.hasAttribute(`data-expand-up`)?`up`:f.hasAttribute(`data-expand-down`)?`down`:`both`,all:f.hasAttribute(`data-expand-all-button`)};continue}let m=l==null?void 0:f.getAttribute(`data-expand-index`)??void 0;if(l!=null&&m!=null){let e=Number.parseInt(m,10);Number.isNaN(e)||(l.hunkIndex=e);continue}if(r==null&&f.hasAttribute(`data-code`)){r=f;break}}if(d!=null)return d;if(l?.hunkIndex!=null)return{type:`line-info`,hunkIndex:l.hunkIndex,direction:l.direction,all:l.all};if(i??=a==null?void 0:ss(r,`[data-line][data-line-index="${a}"]`),o??=a==null?void 0:ss(r,`[data-column-number][data-line-index="${a}"]`),r==null||i==null||o==null||n==null||u==null||Number.isNaN(u))return;let f=this.parseLineIndex(i,this.isSplitDiff());return c==null?this.mode===`file`?{kind:`line`,lineType:n,lineElement:i,lineNumber:u,numberColumn:t,numberElement:o,side:void 0,splitLineIndex:f}:{kind:`line`,lineType:n,lineElement:i,lineNumber:u,numberColumn:t,numberElement:o,side:ps(n,r),splitLineIndex:f}:this.mode===`file`?{kind:`token`,lineType:n,lineElement:i,lineNumber:u,numberColumn:t,numberElement:o,side:void 0,splitLineIndex:f,...c}:{kind:`token`,lineType:n,lineElement:i,lineNumber:u,numberColumn:t,numberElement:o,side:ps(n,r),splitLineIndex:f,...c}}isSplitDiff(){return this.pre?.getAttribute(`data-diff-type`)===`split`}parseLineIndex(e,t){let n=(e.getAttribute(`data-line-index`)??``).split(`,`).map(e=>Number.parseInt(e,10)).filter(e=>!Number.isNaN(e));if(t&&n.length===2)return n[1];if(!t)return n[0]}};function $o({enableTokenInteractionsOnWhitespace:e,enableGutterUtility:t,lineHoverHighlight:n,onGutterUtilityClick:r,onLineClick:i,onLineEnter:a,onLineLeave:o,onLineNumberClick:s,onTokenClick:c,onTokenEnter:l,onTokenLeave:u,renderGutterUtility:d,__debugPointerEvents:f,enableLineSelection:p,controlledSelection:m,onLineSelected:h,onLineSelectionStart:g,onLineSelectionChange:_,onLineSelectionEnd:v},y,b,x){return{enableTokenInteractionsOnWhitespace:e,enableGutterUtility:es({enableGutterUtility:t,renderGutterUtility:d,onGutterUtilityClick:r}),usesCustomGutterUtility:d!=null,lineHoverHighlight:n,onGutterUtilityClick:r,onHunkExpand:y,onMergeConflictActionClick:x,onLineClick:i,onLineEnter:a,onLineLeave:o,onLineNumberClick:s,onTokenClick:c,onTokenEnter:l,onTokenLeave:u,__debugPointerEvents:f,enableLineSelection:p,controlledSelection:m,onLineSelected:h,onLineSelectionStart:g,onLineSelectionChange:_,onLineSelectionEnd:v,getLineIndex:b}}function es({enableGutterUtility:e,renderGutterUtility:t,onGutterUtilityClick:n}){if(n!=null&&t!=null)throw Error(`Cannot use both 'onGutterUtilityClick' and 'renderGutterUtility'. Use only one gutter utility API.`);return e??!1}function ts(e){return e!=null&&`kind`in e&&e.kind===`line`}function ns(e){return e!=null&&`kind`in e&&e.kind===`token`}function rs(e){return ts(e)||ns(e)}function is(e){return`type`in e&&e.type===`line-info`}function as(e){return`kind`in e&&e.kind===`merge-conflict-action`}function os(e){return e===`current`||e===`incoming`||e===`both`}function ss(e,t){let n=e?.querySelector(t);return n instanceof HTMLElement?n:void 0}function cs(e){let t=[],n=e;for(;n!=null;)t.push(n),n=n.parentNode;return t}function ls(e){let t=e.closest(`[data-line], [data-column-number]`);if(t instanceof HTMLElement)return t;let n=e.closest(`[data-line-annotation], [data-gutter-buffer="annotation"]`);if(!(n instanceof HTMLElement))return;let r=n.previousElementSibling;return r instanceof HTMLElement&&(r.hasAttribute(`data-line`)||r.hasAttribute(`data-column-number`))?r:void 0}function us(e){let t=e.closest(`[slot^="annotation-"]`);if(t instanceof HTMLElement)return t.getAttribute(`slot`)??void 0;if(e instanceof HTMLElement){let t=e.getAttribute(`name`)??void 0;return t!=null&&t.startsWith(`annotation-`)?t:void 0}}function ds(e){if(e==null)return;let t=/^annotation-(?:(additions|deletions)-)?(\d+)$/.exec(e);if(t==null)return;let n=Number.parseInt(t[2],10);if(!(!Number.isFinite(n)||n<=0))return{lineNumber:n,side:t[1]}}function fs(e){return e!=null&&typeof e.elementFromPoint==`function`}function ps(e,t){switch(e){case`change-deletion`:return`deletions`;case`change-addition`:return`additions`;default:return t.hasAttribute(`data-deletions`)?`deletions`:`additions`}}function ms(e){let t=e.getAttribute(`data-line-type`);if(t!=null)switch(t){case`change-deletion`:case`change-addition`:case`context`:case`context-expanded`:return t;default:return}}function hs(e){for(let t of e)if(t instanceof HTMLElement&&(t.hasAttribute(`data-utility-button`)||t.hasAttribute(`data-gutter-utility-slot`)||t.getAttribute(`slot`)===`gutter-utility-slot`||t.getAttribute(`name`)===`gutter-utility-slot`))return!0;return!1}function gs(e=`none`,t,...n){switch(e){case`none`:return;case`both`:break;case`click`:if(t!==`click`)return;break;case`move`:if(t!==`move`)return;break}console.log(...n)}var _s=class e{static resizeObserver;static managersByElement=new Map;static getResizeObserver(){let t=e.resizeObserver??new ResizeObserver(e.handleSharedResizeEntries);return e.resizeObserver=t,t}static handleSharedResizeEntries(t){let n=new Map;for(let r of t){let t=e.managersByElement.get(r.target);if(t==null)continue;let i=n.get(t);i==null?n.set(t,[r]):i.push(r)}for(let[e,t]of n)e.handleResizeEntries(t)}observedNodes=new Map;setup(e,t){let n=new Set,r=0,i=new Map(this.observedNodes);this.observedNodes.clear();for(let t of e.children){if(r===2)break;let e=(()=>{if(t instanceof HTMLElement&&t.tagName===`CODE`)return t})();if(e==null)continue;r++;let n=i.get(e);if(n!=null&&n.type!==`code`)throw Error(`ResizeManager.setup: somehow a code node is being used for an annotation, should be impossible`);let a=e.firstElementChild;a instanceof HTMLElement||(a=null),n==null?(n={type:`code`,codeElement:e,numberElement:a,codeWidth:`auto`,numberWidth:0},this.observedNodes.set(e,n),this.observe(e),a!=null&&(this.observedNodes.set(a,n),this.observe(a))):(this.observedNodes.set(e,n),i.delete(e),n.numberElement===a?n.numberElement==null?n.numberWidth=0:(i.delete(n.numberElement),this.observedNodes.set(n.numberElement,n)):(n.numberElement!=null&&(this.unobserve(n.numberElement),i.delete(n.numberElement)),a!=null&&(this.observe(a),i.delete(a),this.observedNodes.set(a,n)),n.numberElement=a,n.numberWidth=0))}if(r>1&&!t){let t=e.querySelectorAll(`[data-line-annotation*=","]`),r=new Map;for(let e of t){if(!(e instanceof HTMLElement))continue;let t=e.getAttribute(`data-line-annotation`)??``;if(!/^-?\d+,-?\d+$/.test(t)){console.error(`DiffFileRenderer.setupResizeObserver: Invalid element or annotation`,{lineAnnotation:t,element:e});continue}let n=r.get(t);n??(n=[],r.set(t,n)),n.push(e)}for(let[e,t]of r){if(t.length!==2){console.error(`DiffFileRenderer.setupResizeObserver: Bad Pair`,e,t);continue}let[r,a]=t,o=r.firstElementChild,s=a.firstElementChild;if(!(r instanceof HTMLElement)||!(a instanceof HTMLElement)||!(o instanceof HTMLElement)||!(s instanceof HTMLElement))continue;let c=i.get(o);if(c!=null){this.observedNodes.set(o,c),this.observedNodes.set(s,c),i.delete(o),i.delete(s);continue}let l=o.getBoundingClientRect().height,u=s.getBoundingClientRect().height;c={type:`annotations`,column1:{container:r,child:o,childHeight:l},column2:{container:a,child:s,childHeight:u},currentHeight:`auto`},n.add({child1:o,child2:s,item:c,newHeight:Math.max(l,u)})}for(let e of n)this.applyNewHeight(e.item,e.newHeight),this.observedNodes.set(e.child1,e.item),this.observedNodes.set(e.child2,e.item),this.observe(e.child1),this.observe(e.child2);n.clear()}for(let[e,t]of i)this.unobserve(e),t.type===`code`?bs(t):xs(t);i.clear()}cleanUp(){for(let e of this.observedNodes.keys())this.unobserve(e);this.observedNodes.clear()}observe(t){let{managersByElement:n}=e,r=n.get(t);if(r!==this){if(r!=null&&r!==this)throw Error(`ResizeManager.observe: element is already owned by another ResizeManager`);n.set(t,this),e.getResizeObserver().observe(t)}}unobserve(t){let{managersByElement:n,resizeObserver:r}=e,i=n.get(t);if(i!=null){if(i!==this)throw Error(`ResizeManager.unobserve: element is owned by another ResizeManager`);n.delete(t),r?.unobserve(t),r!=null&&n.size===0&&(r.disconnect(),e.resizeObserver=void 0)}}handleResizeEntries(e){let t=new Map,n=new Set;for(let r of e){let{target:e,borderBoxSize:i,contentBoxSize:a}=r;if(!(e instanceof HTMLElement)){console.error(`ResizeManager.handleResizeEntries: Invalid element for ResizeObserver`,r);continue}let o=this.observedNodes.get(e);if(o==null){console.error(`ResizeManager.handleResizeEntries: Not a valid observed node`,r);continue}if(o.type===`annotations`){let t=(()=>{if(e===o.column1.child)return o.column1;if(e===o.column2.child)return o.column2})();if(t==null){console.error(`ResizeManager.handleResizeEntries: Couldn't find a column for`,{item:o,target:e});continue}t.childHeight=i[0].blockSize,n.add(o)}else if(o.type===`code`){let n=t.get(o)??{},r=a[0].inlineSize;e===o.codeElement?n.codeInlineSize=r:e===o.numberElement&&(n.numberInlineSize=r),t.set(o,n)}}this.applyAnnotationUpdates(n),n.clear(),this.applyColumnUpdates(t),t.clear()}applyAnnotationUpdates(e){for(let t of e)this.applyNewHeight(t,Math.max(t.column1.childHeight,t.column2.childHeight))}applyColumnUpdates=e=>{for(let[t,n]of e){let e=n.codeInlineSize==null?t.codeWidth:vs(n.codeInlineSize),r=n.numberInlineSize==null?t.numberWidth:ys(n.numberInlineSize),i=e!==t.codeWidth,a=r!==t.numberWidth;if(!(!i&&!a)&&(t.codeWidth=e,t.numberWidth=r,i&&t.codeElement.style.setProperty(`--diffs-column-width`,`${typeof e==`number`?`${e}px`:`auto`}`),a&&t.codeElement.style.setProperty(`--diffs-column-number-width`,`${r===0?`auto`:`${r}px`}`),i||a&&e!==`auto`)){let n=typeof e==`number`?Math.max(e-r,0):0;t.codeElement.style.setProperty(`--diffs-column-content-width`,`${n>0?`${n}px`:`auto`}`)}}};applyNewHeight(e,t){t!==e.currentHeight&&(e.currentHeight=Math.max(t,0),e.column1.container.style.setProperty(`--diffs-annotation-min-height`,`${e.currentHeight}px`),e.column2.container.style.setProperty(`--diffs-annotation-min-height`,`${e.currentHeight}px`))}};function vs(e){let t=Math.max(Math.floor(e),0);return t===0?`auto`:t}function ys(e){return Math.max(Math.ceil(e),0)}function bs(e){e.codeElement.isConnected&&(e.codeElement.style.removeProperty(`--diffs-column-content-width`),e.codeElement.style.removeProperty(`--diffs-column-number-width`),e.codeElement.style.removeProperty(`--diffs-column-width`))}function xs(e){e.column1.container.isConnected&&e.column1.container.style.removeProperty(`--diffs-annotation-min-height`),e.column2.container.isConnected&&e.column2.container.style.removeProperty(`--diffs-annotation-min-height`)}function Ss(e,t){return e?.cacheKey===t?.cacheKey&&e?.contents===t?.contents&&e?.name===t?.name&&e?.lang===t?.lang}function Cs(e,t){return e==null||t==null?e===t:e.startingLine===t.startingLine&&e.totalLines===t.totalLines&&e.bufferBefore===t.bufferBefore&&e.bufferAfter===t.bufferAfter}function ws(e){return`annotation-${`side`in e?`${e.side}-`:``}${e.lineNumber}`}var Ts=`<svg data-icon-sprite aria-hidden="true" width="0" height="0">
22
+ <symbol id="diffs-icon-arrow-right-short" viewBox="0 0 16 16">
23
+ <path d="M8.47 4.22a.75.75 0 0 0 0 1.06l1.97 1.97H3.75a.75.75 0 0 0 0 1.5h6.69l-1.97 1.97a.75.75 0 1 0 1.06 1.06l3.25-3.25a.75.75 0 0 0 0-1.06L9.53 4.22a.75.75 0 0 0-1.06 0"/>
24
+ </symbol>
25
+ <symbol id="diffs-icon-brand-github" viewBox="0 0 16 16">
26
+ <path d="M8 0c4.42 0 8 3.58 8 8a8.01 8.01 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27s-1.36.09-2 .27c-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8"/>
27
+ </symbol>
28
+ <symbol id="diffs-icon-chevron" viewBox="0 0 16 16">
29
+ <path d="M1.47 4.47a.75.75 0 0 1 1.06 0L8 9.94l5.47-5.47a.75.75 0 1 1 1.06 1.06l-6 6a.75.75 0 0 1-1.06 0l-6-6a.75.75 0 0 1 0-1.06"/>
30
+ </symbol>
31
+ <symbol id="diffs-icon-chevrons-narrow" viewBox="0 0 10 16">
32
+ <path d="M4.47 2.22a.75.75 0 0 1 1.06 0l3.25 3.25a.75.75 0 0 1-1.06 1.06L5 3.81 2.28 6.53a.75.75 0 0 1-1.06-1.06zM1.22 9.47a.75.75 0 0 1 1.06 0L5 12.19l2.72-2.72a.75.75 0 0 1 1.06 1.06l-3.25 3.25a.75.75 0 0 1-1.06 0l-3.25-3.25a.75.75 0 0 1 0-1.06"/>
33
+ </symbol>
34
+ <symbol id="diffs-icon-diff-split" viewBox="0 0 16 16">
35
+ <path d="M14 0H8.5v16H14a2 2 0 0 0 2-2V2a2 2 0 0 0-2-2m-1.5 6.5v1h1a.5.5 0 0 1 0 1h-1v1a.5.5 0 0 1-1 0v-1h-1a.5.5 0 0 1 0-1h1v-1a.5.5 0 0 1 1 0"/><path d="M2 0a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h5.5V0zm.5 7.5h3a.5.5 0 0 1 0 1h-3a.5.5 0 0 1 0-1" opacity=".3"/>
36
+ </symbol>
37
+ <symbol id="diffs-icon-diff-unified" viewBox="0 0 16 16">
38
+ <path fill-rule="evenodd" d="M16 14a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V8.5h16zm-8-4a.5.5 0 0 0-.5.5v1h-1a.5.5 0 0 0 0 1h1v1a.5.5 0 0 0 1 0v-1h1a.5.5 0 0 0 0-1h-1v-1A.5.5 0 0 0 8 10" clip-rule="evenodd"/><path fill-rule="evenodd" d="M14 0a2 2 0 0 1 2 2v5.5H0V2a2 2 0 0 1 2-2zM6.5 3.5a.5.5 0 0 0 0 1h3a.5.5 0 0 0 0-1z" clip-rule="evenodd" opacity=".4"/>
39
+ </symbol>
40
+ <symbol id="diffs-icon-expand" viewBox="0 0 16 16">
41
+ <path d="M3.47 5.47a.75.75 0 0 1 1.06 0L8 8.94l3.47-3.47a.75.75 0 1 1 1.06 1.06l-4 4a.75.75 0 0 1-1.06 0l-4-4a.75.75 0 0 1 0-1.06"/>
42
+ </symbol>
43
+ <symbol id="diffs-icon-expand-all" viewBox="0 0 16 16">
44
+ <path d="M11.47 9.47a.75.75 0 1 1 1.06 1.06l-4 4a.75.75 0 0 1-1.06 0l-4-4a.75.75 0 1 1 1.06-1.06L8 12.94zM7.526 1.418a.75.75 0 0 1 1.004.052l4 4a.75.75 0 1 1-1.06 1.06L8 3.06 4.53 6.53a.75.75 0 1 1-1.06-1.06l4-4z"/>
45
+ </symbol>
46
+ <symbol id="diffs-icon-file-code" viewBox="0 0 16 16">
47
+ <path d="M10.75 0c.199 0 .39.08.53.22l3.5 3.5c.14.14.22.331.22.53v9A2.75 2.75 0 0 1 12.25 16h-8.5A2.75 2.75 0 0 1 1 13.25V2.75A2.75 2.75 0 0 1 3.75 0zm-7 1.5c-.69 0-1.25.56-1.25 1.25v10.5c0 .69.56 1.25 1.25 1.25h8.5c.69 0 1.25-.56 1.25-1.25V5h-1.25A2.25 2.25 0 0 1 10 2.75V1.5z"/><path d="M7.248 6.19a.75.75 0 0 1 .063 1.058L5.753 9l1.558 1.752a.75.75 0 0 1-1.122.996l-2-2.25a.75.75 0 0 1 0-.996l2-2.25a.75.75 0 0 1 1.06-.063M8.69 7.248a.75.75 0 1 1 1.12-.996l2 2.25a.75.75 0 0 1 0 .996l-2 2.25a.75.75 0 1 1-1.12-.996L10.245 9z"/>
48
+ </symbol>
49
+ <symbol id="diffs-icon-plus" viewBox="0 0 16 16">
50
+ <path d="M8 3a.75.75 0 0 1 .75.75v3.5h3.5a.75.75 0 0 1 0 1.5h-3.5v3.5a.75.75 0 0 1-1.5 0v-3.5h-3.5a.75.75 0 0 1 0-1.5h3.5v-3.5A.75.75 0 0 1 8 3"/>
51
+ </symbol>
52
+ <symbol id="diffs-icon-symbol-added" viewBox="0 0 16 16">
53
+ <path d="M8 4a.75.75 0 0 1 .75.75v2.5h2.5a.75.75 0 0 1 0 1.5h-2.5v2.5a.75.75 0 0 1-1.5 0v-2.5h-2.5a.75.75 0 0 1 0-1.5h2.5v-2.5A.75.75 0 0 1 8 4"/><path d="M1.788 4.296c.196-.88.478-1.381.802-1.706s.826-.606 1.706-.802C5.194 1.588 6.387 1.5 8 1.5s2.806.088 3.704.288c.88.196 1.381.478 1.706.802s.607.826.802 1.706c.2.898.288 2.091.288 3.704s-.088 2.806-.288 3.704c-.195.88-.478 1.381-.802 1.706s-.826.607-1.706.802c-.898.2-2.091.288-3.704.288s-2.806-.088-3.704-.288c-.88-.195-1.381-.478-1.706-.802s-.606-.826-.802-1.706C1.588 10.806 1.5 9.613 1.5 8s.088-2.806.288-3.704M8 0C1.412 0 0 1.412 0 8s1.412 8 8 8 8-1.412 8-8-1.412-8-8-8"/>
54
+ </symbol>
55
+ <symbol id="diffs-icon-symbol-deleted" viewBox="0 0 16 16">
56
+ <path d="M4 8a.75.75 0 0 1 .75-.75h6.5a.75.75 0 0 1 0 1.5h-6.5A.75.75 0 0 1 4 8"/><path d="M1.788 4.296c.196-.88.478-1.381.802-1.706s.826-.606 1.706-.802C5.194 1.588 6.387 1.5 8 1.5s2.806.088 3.704.288c.88.196 1.381.478 1.706.802s.607.826.802 1.706c.2.898.288 2.091.288 3.704s-.088 2.806-.288 3.704c-.195.88-.478 1.381-.802 1.706s-.826.607-1.706.802c-.898.2-2.091.288-3.704.288s-2.806-.088-3.704-.288c-.88-.195-1.381-.478-1.706-.802s-.606-.826-.802-1.706C1.588 10.806 1.5 9.613 1.5 8s.088-2.806.288-3.704M8 0C1.412 0 0 1.412 0 8s1.412 8 8 8 8-1.412 8-8-1.412-8-8-8"/>
57
+ </symbol>
58
+ <symbol id="diffs-icon-symbol-diffstat" viewBox="0 0 16 16">
59
+ <path d="M1.788 4.296c.196-.88.478-1.381.802-1.706s.826-.606 1.706-.802C5.194 1.588 6.387 1.5 8 1.5s2.806.088 3.704.288c.88.196 1.381.478 1.706.802s.607.826.802 1.706c.2.898.288 2.091.288 3.704s-.088 2.806-.288 3.704c-.195.88-.478 1.381-.802 1.706s-.826.607-1.706.802c-.898.2-2.091.288-3.704.288s-2.806-.088-3.704-.288c-.88-.195-1.381-.478-1.706-.802s-.606-.826-.802-1.706C1.588 10.806 1.5 9.613 1.5 8s.088-2.806.288-3.704M8 0C1.412 0 0 1.412 0 8s1.412 8 8 8 8-1.412 8-8-1.412-8-8-8"/><path d="M8.75 4.296a.75.75 0 0 0-1.5 0V6.25h-2a.75.75 0 0 0 0 1.5h2v1.5h1.5v-1.5h2a.75.75 0 0 0 0-1.5h-2zM5.25 10a.75.75 0 0 0 0 1.5h5.5a.75.75 0 0 0 0-1.5z"/>
60
+ </symbol>
61
+ <symbol id="diffs-icon-symbol-ignored" viewBox="0 0 16 16">
62
+ <path d="M1.5 8c0 1.613.088 2.806.288 3.704.196.88.478 1.381.802 1.706s.826.607 1.706.802c.898.2 2.091.288 3.704.288s2.806-.088 3.704-.288c.88-.195 1.381-.478 1.706-.802s.607-.826.802-1.706c.2-.898.288-2.091.288-3.704s-.088-2.806-.288-3.704c-.195-.88-.478-1.381-.802-1.706s-.826-.606-1.706-.802C10.806 1.588 9.613 1.5 8 1.5s-2.806.088-3.704.288c-.88.196-1.381.478-1.706.802s-.606.826-.802 1.706C1.588 5.194 1.5 6.387 1.5 8M0 8c0-6.588 1.412-8 8-8s8 1.412 8 8-1.412 8-8 8-8-1.412-8-8m11.53-2.47a.75.75 0 0 0-1.06-1.06l-6 6a.75.75 0 1 0 1.06 1.06z"/>
63
+ </symbol>
64
+ <symbol id="diffs-icon-symbol-modified" viewBox="0 0 16 16">
65
+ <path d="M1.5 8c0 1.613.088 2.806.288 3.704.196.88.478 1.381.802 1.706s.826.607 1.706.802c.898.2 2.091.288 3.704.288s2.806-.088 3.704-.288c.88-.195 1.381-.478 1.706-.802s.607-.826.802-1.706c.2-.898.288-2.091.288-3.704s-.088-2.806-.288-3.704c-.195-.88-.478-1.381-.802-1.706s-.826-.606-1.706-.802C10.806 1.588 9.613 1.5 8 1.5s-2.806.088-3.704.288c-.88.196-1.381.478-1.706.802s-.606.826-.802 1.706C1.588 5.194 1.5 6.387 1.5 8M0 8c0-6.588 1.412-8 8-8s8 1.412 8 8-1.412 8-8 8-8-1.412-8-8m8 3a3 3 0 1 0 0-6 3 3 0 0 0 0 6"/>
66
+ </symbol>
67
+ <symbol id="diffs-icon-symbol-moved" viewBox="0 0 16 16">
68
+ <path d="M1.788 4.296c.196-.88.478-1.381.802-1.706s.826-.606 1.706-.802C5.194 1.588 6.387 1.5 8 1.5s2.806.088 3.704.288c.88.196 1.381.478 1.706.802s.607.826.802 1.706c.2.898.288 2.091.288 3.704s-.088 2.806-.288 3.704c-.195.88-.478 1.381-.802 1.706s-.826.607-1.706.802c-.898.2-2.091.288-3.704.288s-2.806-.088-3.704-.288c-.88-.195-1.381-.478-1.706-.802s-.606-.826-.802-1.706C1.588 10.806 1.5 9.613 1.5 8s.088-2.806.288-3.704M8 0C1.412 0 0 1.412 0 8s1.412 8 8 8 8-1.412 8-8-1.412-8-8-8"/><path d="M8.495 4.695a.75.75 0 0 0-.05 1.06L10.486 8l-2.041 2.246a.75.75 0 0 0 1.11 1.008l2.5-2.75a.75.75 0 0 0 0-1.008l-2.5-2.75a.75.75 0 0 0-1.06-.051m-4 0a.75.75 0 0 0-.05 1.06l2.044 2.248-1.796 1.995a.75.75 0 0 0 1.114 1.004l2.25-2.5a.75.75 0 0 0-.002-1.007l-2.5-2.75a.75.75 0 0 0-1.06-.05"/>
69
+ </symbol>
70
+ <symbol id="diffs-icon-symbol-ref" viewBox="0 0 16 16">
71
+ <path d="M1.5 8c0 1.613.088 2.806.288 3.704.196.88.478 1.381.802 1.706.286.286.71.54 1.41.73V1.86c-.7.19-1.124.444-1.41.73-.324.325-.606.826-.802 1.706C1.588 5.194 1.5 6.387 1.5 8m4 6.397c.697.07 1.522.103 2.5.103 1.613 0 2.806-.088 3.704-.288.88-.195 1.381-.478 1.706-.802s.607-.826.802-1.706c.2-.898.288-2.091.288-3.704s-.088-2.806-.288-3.704c-.195-.88-.478-1.381-.802-1.706s-.826-.606-1.706-.802C10.806 1.588 9.613 1.5 8 1.5c-.978 0-1.803.033-2.5.103zM0 8c0-6.588 1.412-8 8-8s8 1.412 8 8-1.412 8-8 8-8-1.412-8-8m7-2a1 1 0 0 1 1-1h3a1 1 0 0 1 1 1v1a1 1 0 0 1-1 1H8a1 1 0 0 1-1-1z"/>
72
+ </symbol>
73
+ </svg>`;function Es(e,t){return e==null||t==null?e===t:Os(e.customProperties,t.customProperties)&&e.type===t.type&&e.diffIndicators===t.diffIndicators&&e.disableBackground===t.disableBackground&&e.disableLineNumbers===t.disableLineNumbers&&e.overflow===t.overflow&&e.split===t.split&&e.totalLines===t.totalLines}var Ds={};function Os(e=Ds,t=Ds){if(e===t)return!0;let n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(let r of n)if(e[r]!==t[r])return!1;return!0}function ks(e){let t=document.createElement(`div`);return t.dataset.annotationSlot=``,t.slot=e,t.style.whiteSpace=`normal`,t}function As(){let e=document.createElement(`div`);return e.slot=`gutter-utility-slot`,e.style.position=`absolute`,e.style.top=`0`,e.style.bottom=`0`,e.style.textAlign=`center`,e.style.whiteSpace=`normal`,e.style.touchAction=`none`,e}function js(){let e=document.createElement(`style`);return e.setAttribute(qr,``),e}var Ms;function Ns(e){if(Ms!=null)return Ms;let t=e.host;if(typeof HTMLElement<`u`&&t instanceof HTMLElement&&!t.isConnected)return;let n=document.createElement(`div`);n.setAttribute(`data-code`,``),n.setAttribute(Jr,`true`);let r=document.createElement(`div`);return r.style.position=`relative`,r.style.width=`200%`,r.style.height=`200%`,n.appendChild(r),e.appendChild(n),Ms=Math.max(n.offsetHeight-n.clientHeight,0),n.remove(),Ms}function Ps(e){return`${Yr}: ${e==null?`var(--diffs-scrollbar-gutter-fallback)`:`${e}px`};`}var Fs=`@layer base {
74
+ :host {
75
+ --diffs-font-fallback: "SF Mono", Monaco, Consolas, "Ubuntu Mono", "Liberation Mono",
76
+ "Courier New", monospace;
77
+ --diffs-header-font-fallback: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue",
78
+ "Noto Sans", "Liberation Sans", Arial, sans-serif;
79
+ --diffs-mixer: light-dark(#000, #fff);
80
+ --diffs-gap-fallback: 8px;
81
+ --diffs-scrollbar-gutter-fallback: 6px;
82
+ --diffs-scrollbar-gutter: var(--diffs-scrollbar-gutter-override, var(--diffs-scrollbar-gutter-measured, var(--diffs-scrollbar-gutter-fallback)));
83
+ --diffs-added-light: #0dbe4e;
84
+ --diffs-added-dark: #5ecc71;
85
+ --diffs-modified-light: #009fff;
86
+ --diffs-modified-dark: #69b1ff;
87
+ --diffs-deleted-light: #ff2e3f;
88
+ --diffs-deleted-dark: #ff6762;
89
+ color-scheme: light dark;
90
+ font-family: var(--diffs-header-font-family, var(--diffs-header-font-fallback));
91
+ font-size: var(--diffs-font-size, 13px);
92
+ line-height: var(--diffs-line-height, 20px);
93
+ font-feature-settings: var(--diffs-font-features);
94
+ --diffs-bg: light-dark(var(--diffs-light-bg, #fff), var(--diffs-dark-bg, #000));
95
+ --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))));
96
+ --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))));
97
+ --diffs-bg-context-gutter: var(--diffs-bg-context-gutter-override, light-dark(color-mix(in lab, var(--diffs-bg-context) 90%, var(--diffs-bg)), color-mix(in lab, var(--diffs-bg-context) 45%, var(--diffs-bg))));
98
+ --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))));
99
+ --diffs-fg: light-dark(var(--diffs-light, #000), var(--diffs-dark, #fff));
100
+ --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))));
101
+ --diffs-fg-conflict-marker: var(--diffs-fg-conflict-marker-override, var(--diffs-fg-number));
102
+ --diffs-deletion-base: var(--diffs-deletion-color-override, light-dark(var(--diffs-light-deletion-color, var(--diffs-deletion-color, var(--diffs-deleted-light))), var(--diffs-dark-deletion-color, var(--diffs-deletion-color, var(--diffs-deleted-dark)))));
103
+ --diffs-addition-base: var(--diffs-addition-color-override, light-dark(var(--diffs-light-addition-color, var(--diffs-addition-color, var(--diffs-added-light))), var(--diffs-dark-addition-color, var(--diffs-addition-color, var(--diffs-added-dark)))));
104
+ --diffs-modified-base: var(--diffs-modified-color-override, light-dark(var(--diffs-light-modified-color, var(--diffs-modified-color, var(--diffs-modified-light))), var(--diffs-dark-modified-color, var(--diffs-modified-color, var(--diffs-modified-dark)))));
105
+ --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))));
106
+ --diffs-bg-deletion-emphasis: var(--diffs-bg-deletion-emphasis-override, light-dark(rgb(from var(--diffs-deletion-base) r g b / .15), rgb(from var(--diffs-deletion-base) r g b / .2)));
107
+ --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))));
108
+ --diffs-bg-addition-emphasis: var(--diffs-bg-addition-emphasis-override, light-dark(rgb(from var(--diffs-addition-base) r g b / .15), rgb(from var(--diffs-addition-base) r g b / .2)));
109
+ --diffs-selection-base: var(--diffs-modified-base);
110
+ --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)));
111
+ background-color: var(--diffs-bg);
112
+ color: var(--diffs-fg);
113
+ display: block;
114
+ }
115
+
116
+ pre, code, [data-error-wrapper] {
117
+ isolation: isolate;
118
+ font-family: var(--diffs-font-family, var(--diffs-font-fallback));
119
+ outline: none;
120
+ margin: 0;
121
+ padding: 0;
122
+ display: block;
123
+ }
124
+
125
+ pre, code {
126
+ background-color: var(--diffs-bg);
127
+ }
128
+
129
+ code {
130
+ contain: content;
131
+ }
132
+
133
+ *, :before, :after {
134
+ box-sizing: border-box;
135
+ }
136
+
137
+ [data-icon-sprite] {
138
+ display: none;
139
+ }
140
+
141
+ [data-diffs-header], [data-separator] {
142
+ font-family: var(--diffs-header-font-family, var(--diffs-header-font-fallback));
143
+ }
144
+
145
+ [data-diffs-header][data-sticky] {
146
+ z-index: 1;
147
+ background-color: var(--diffs-bg);
148
+ position: sticky;
149
+ top: 0;
150
+ }
151
+
152
+ [data-file-info] {
153
+ color: var(--fg);
154
+ background-color: color-mix(in lab, var(--bg) 98%, var(--fg));
155
+ border-block: 1px solid color-mix(in lab, var(--bg) 95%, var(--fg));
156
+ padding: 10px;
157
+ font-weight: 700;
158
+ }
159
+
160
+ [data-diff], [data-file] {
161
+ --diffs-grid-number-column-width: minmax(min-content, max-content);
162
+ --diffs-code-grid: var(--diffs-grid-number-column-width) 1fr;
163
+
164
+ &[data-dehydrated] {
165
+ --diffs-code-grid: var(--diffs-grid-number-column-width) minmax(0, 1fr);
166
+ }
167
+
168
+ &:hover [data-code]::-webkit-scrollbar-thumb {
169
+ background-color: var(--diffs-bg-context);
170
+ }
171
+ }
172
+
173
+ @supports (-webkit-touch-callout: none) {
174
+ :host {
175
+ --diffs-scrollbar-gutter-fallback: 0px;
176
+ }
177
+ }
178
+
179
+ [data-line] span {
180
+ color: light-dark(var(--diffs-token-light, var(--diffs-light)), var(--diffs-token-dark, var(--diffs-dark)));
181
+ background-color: light-dark(var(--diffs-token-light-bg, inherit), var(--diffs-token-dark-bg, inherit));
182
+ font-weight: light-dark(var(--diffs-token-light-font-weight, inherit), var(--diffs-token-dark-font-weight, inherit));
183
+ font-style: light-dark(var(--diffs-token-light-font-style, inherit), var(--diffs-token-dark-font-style, inherit));
184
+ text-decoration: light-dark(var(--diffs-token-light-text-decoration, inherit), var(--diffs-token-dark-text-decoration, inherit));
185
+ }
186
+
187
+ [data-line], [data-gutter-buffer], [data-column-number], [data-line-annotation], [data-no-newline], [data-merge-conflict], [data-merge-conflict-actions] {
188
+ --diffs-computed-decoration-bg: var(--diffs-bg);
189
+ --diffs-computed-diff-line-bg: var(--diffs-bg);
190
+ --diffs-computed-selected-line-bg: var(--diffs-bg);
191
+ color: var(--diffs-fg);
192
+ background-color: var(--diffs-line-bg, var(--diffs-bg));
193
+
194
+ @media (pointer: fine) {
195
+ &:where([data-hovered]) {
196
+ --diffs-computed-hovered-line-bg: light-dark(color-mix(in lab,
197
+ var(--diffs-computed-selected-line-bg) 97%,
198
+ var(--diffs-bg-hover-override, var(--diffs-mixer))), color-mix(in lab,
199
+ var(--diffs-computed-selected-line-bg) 91%,
200
+ var(--diffs-bg-hover-override, var(--diffs-mixer))));
201
+ --diffs-line-bg: var(--diffs-computed-hovered-line-bg, inherit);
202
+ }
203
+ }
204
+ }
205
+
206
+ [data-line], [data-no-newline] {
207
+ &[data-decoration-bg] {
208
+ --mix-deco-light: 92%;
209
+ --mix-deco-dark: 85%;
210
+
211
+ &[data-decoration-bg-depth="2"] {
212
+ --mix-deco-light: 88%;
213
+ --mix-deco-dark: 80%;
214
+ }
215
+
216
+ &[data-decoration-bg-depth="3"] {
217
+ --mix-deco-light: 85%;
218
+ --mix-deco-dark: 78%;
219
+ }
220
+
221
+ @media (pointer: fine) {
222
+ &[data-hovered]:not([data-selected-line]) {
223
+ --mix-deco-light: 85%;
224
+ --mix-deco-dark: 85%;
225
+ }
226
+
227
+ &[data-hovered]:not([data-selected-line])[data-decoration-bg-depth="2"] {
228
+ --mix-deco-light: 83%;
229
+ --mix-deco-dark: 83%;
230
+ }
231
+
232
+ &[data-hovered]:not([data-selected-line])[data-decoration-bg-depth="3"] {
233
+ --mix-deco-light: 81%;
234
+ --mix-deco-dark: 81%;
235
+ }
236
+ }
237
+
238
+ --diffs-computed-decoration-bg: light-dark(color-mix(in lab,
239
+ var(--diffs-bg) var(--mix-deco-light),
240
+ var(--diffs-decoration-bg)), color-mix(in lab,
241
+ var(--diffs-bg) var(--mix-deco-dark),
242
+ var(--diffs-decoration-bg)));
243
+ --diffs-computed-diff-line-bg: var(--diffs-computed-decoration-bg);
244
+ --diffs-computed-selected-line-bg: var(--diffs-computed-decoration-bg);
245
+ --diffs-line-bg: var(--diffs-computed-decoration-bg);
246
+ }
247
+ }
248
+
249
+ [data-line-annotation], [data-gutter-buffer="annotation"] {
250
+ --diffs-annotation-bg: var(--diffs-bg-context);
251
+ --diffs-computed-decoration-bg: var(--diffs-annotation-bg);
252
+ --diffs-computed-diff-line-bg: var(--diffs-annotation-bg);
253
+ --diffs-computed-selected-line-bg: var(--diffs-annotation-bg);
254
+ --diffs-line-bg: var(--diffs-annotation-bg);
255
+ }
256
+
257
+ [data-merge-conflict-actions], [data-gutter-buffer="merge-conflict-action"], [data-gutter-buffer="merge-conflict-marker-base"], [data-gutter-buffer="merge-conflict-marker-separator"], [data-merge-conflict="marker-base"], [data-merge-conflict="marker-separator"] {
258
+ --diffs-computed-decoration-bg: var(--diffs-bg-context);
259
+ --diffs-computed-diff-line-bg: var(--diffs-bg-context);
260
+ --diffs-computed-selected-line-bg: var(--diffs-bg-context);
261
+ --diffs-line-bg: var(--diffs-bg-context);
262
+ }
263
+
264
+ [data-gutter-buffer="merge-conflict-marker-start"], [data-merge-conflict="marker-start"] {
265
+ --diffs-computed-decoration-bg: light-dark(color-mix(in lab,
266
+ var(--diffs-bg) 78%,
267
+ var(--conflict-bg-current-header-override, var(--diffs-addition-base))), color-mix(in lab,
268
+ var(--diffs-bg) 68%,
269
+ var(--conflict-bg-current-header-override, var(--diffs-addition-base))));
270
+ --diffs-computed-diff-line-bg: var(--diffs-computed-decoration-bg);
271
+ --diffs-computed-selected-line-bg: var(--diffs-computed-decoration-bg);
272
+ --diffs-line-bg: var(--diffs-computed-decoration-bg);
273
+ }
274
+
275
+ [data-gutter-buffer="merge-conflict-marker-end"], [data-merge-conflict="marker-end"] {
276
+ --diffs-computed-decoration-bg: light-dark(color-mix(in lab,
277
+ var(--diffs-bg) 78%,
278
+ var(--conflict-bg-incoming-header-override, var(--diffs-modified-base))), color-mix(in lab,
279
+ var(--diffs-bg) 68%,
280
+ var(--conflict-bg-incoming-header-override, var(--diffs-modified-base))));
281
+ --diffs-computed-diff-line-bg: var(--diffs-computed-decoration-bg);
282
+ --diffs-computed-selected-line-bg: var(--diffs-computed-decoration-bg);
283
+ --diffs-line-bg: var(--diffs-computed-decoration-bg);
284
+ }
285
+
286
+ [data-has-merge-conflict] [data-line-annotation], [data-has-merge-conflict] [data-gutter-buffer="annotation"] {
287
+ --diffs-computed-decoration-bg: var(--diffs-bg);
288
+ --diffs-computed-diff-line-bg: var(--diffs-bg);
289
+ --diffs-computed-selected-line-bg: var(--diffs-bg);
290
+ --diffs-line-bg: var(--diffs-bg);
291
+ }
292
+
293
+ :where([data-background]) {
294
+ & [data-gutter-buffer], & [data-column-number] {
295
+ --mix-light: 91%;
296
+ --mix-dark: 85%;
297
+ }
298
+
299
+ & [data-line], & [data-no-newline] {
300
+ --mix-light: 88%;
301
+ --mix-dark: 80%;
302
+ }
303
+
304
+ & [data-gutter-buffer], & [data-column-number], & [data-line], & [data-no-newline] {
305
+ --diffs-diff-line-mix-target: var(--diffs-bg);
306
+
307
+ &[data-line-type="change-deletion"] {
308
+ --diffs-diff-line-mix-target: var(--diffs-bg-deletion-override, var(--diffs-deletion-base));
309
+
310
+ @media (pointer: fine) {
311
+ &[data-hovered] {
312
+ --mix-light: 80%;
313
+ --mix-dark: 75%;
314
+ }
315
+ }
316
+
317
+ &:where([data-gutter-buffer], [data-column-number]) {
318
+ color: var(--diffs-fg-number-deletion-override, var(--diffs-deletion-base));
319
+ --diffs-diff-line-mix-target: var(--diffs-bg-deletion-number-override, var(--diffs-deletion-base));
320
+ }
321
+
322
+ --diffs-computed-diff-line-bg: light-dark(color-mix(in lab,
323
+ var(--diffs-computed-decoration-bg) var(--mix-light),
324
+ var(--diffs-diff-line-mix-target)), color-mix(in lab,
325
+ var(--diffs-computed-decoration-bg) var(--mix-dark),
326
+ var(--diffs-diff-line-mix-target)));
327
+ --diffs-computed-selected-line-bg: var(--diffs-computed-diff-line-bg);
328
+ --diffs-line-bg: var(--diffs-computed-diff-line-bg, inherit);
329
+ }
330
+
331
+ &[data-line-type="change-addition"] {
332
+ --diffs-diff-line-mix-target: var(--diffs-bg-addition-override, var(--diffs-addition-base));
333
+
334
+ @media (pointer: fine) {
335
+ &[data-hovered] {
336
+ --mix-light: 80%;
337
+ --mix-dark: 70%;
338
+ }
339
+ }
340
+
341
+ &:where([data-gutter-buffer], [data-column-number]) {
342
+ color: var(--diffs-fg-number-addition-override, var(--diffs-addition-base));
343
+ --diffs-diff-line-mix-target: var(--diffs-bg-addition-number-override, var(--diffs-addition-base));
344
+ }
345
+
346
+ --diffs-computed-diff-line-bg: light-dark(color-mix(in lab,
347
+ var(--diffs-computed-decoration-bg) var(--mix-light),
348
+ var(--diffs-diff-line-mix-target)), color-mix(in lab,
349
+ var(--diffs-computed-decoration-bg) var(--mix-dark),
350
+ var(--diffs-diff-line-mix-target)));
351
+ --diffs-computed-selected-line-bg: var(--diffs-computed-diff-line-bg);
352
+ --diffs-line-bg: var(--diffs-computed-diff-line-bg, inherit);
353
+ }
354
+
355
+ &[data-merge-conflict="current"] {
356
+ --diffs-diff-line-mix-target: var(--conflict-bg-current-override, var(--diffs-addition-base));
357
+
358
+ &:where([data-gutter-buffer], [data-column-number]) {
359
+ color: var(--diffs-fg-number-addition-override, var(--diffs-addition-base));
360
+ --diffs-diff-line-mix-target: var(--conflict-bg-current-number-override, var(--diffs-addition-base));
361
+ }
362
+
363
+ @media (pointer: fine) {
364
+ &[data-hovered] {
365
+ --mix-light: 80%;
366
+ --mix-dark: 70%;
367
+ }
368
+ }
369
+
370
+ --diffs-computed-diff-line-bg: light-dark(color-mix(in lab,
371
+ var(--diffs-computed-decoration-bg) var(--mix-light),
372
+ var(--diffs-diff-line-mix-target)), color-mix(in lab,
373
+ var(--diffs-computed-decoration-bg) var(--mix-dark),
374
+ var(--diffs-diff-line-mix-target)));
375
+ --diffs-computed-selected-line-bg: var(--diffs-computed-diff-line-bg);
376
+ --diffs-line-bg: var(--diffs-computed-diff-line-bg, inherit);
377
+ }
378
+
379
+ &[data-merge-conflict="incoming"] {
380
+ --diffs-diff-line-mix-target: var(--conflict-bg-incoming-override, var(--diffs-modified-base));
381
+
382
+ &:where([data-gutter-buffer], [data-column-number]) {
383
+ color: var(--diffs-modified-base);
384
+ --diffs-diff-line-mix-target: var(--conflict-bg-incoming-number-override, var(--diffs-modified-base));
385
+ }
386
+
387
+ @media (pointer: fine) {
388
+ &[data-hovered] {
389
+ --mix-light: 80%;
390
+ --mix-dark: 70%;
391
+ }
392
+ }
393
+
394
+ --diffs-computed-diff-line-bg: light-dark(color-mix(in lab,
395
+ var(--diffs-computed-decoration-bg) var(--mix-light),
396
+ var(--diffs-diff-line-mix-target)), color-mix(in lab,
397
+ var(--diffs-computed-decoration-bg) var(--mix-dark),
398
+ var(--diffs-diff-line-mix-target)));
399
+ --diffs-computed-selected-line-bg: var(--diffs-computed-diff-line-bg);
400
+ --diffs-line-bg: var(--diffs-computed-diff-line-bg, inherit);
401
+ }
402
+ }
403
+ }
404
+
405
+ [data-gutter-buffer], [data-column-number], [data-line], [data-line-annotation], [data-merge-conflict], [data-merge-conflict-actions], [data-no-newline] {
406
+ --diffs-selection-mix-target: var(--diffs-bg-selection-override, var(--diffs-selection-base));
407
+
408
+ &:where([data-line], [data-line-annotation], [data-merge-conflict], [data-merge-conflict-actions], [data-no-newline])[data-selected-line] {
409
+ --mix-selection-light: 82%;
410
+ --mix-selection-dark: 75%;
411
+
412
+ @media (pointer: fine) {
413
+ &[data-hovered]:not([data-merge-conflict], [data-line-type="change-addition"], [data-line-type="change-deletion"]) {
414
+ --mix-selection-light: 75%;
415
+ --mix-selection-dark: 70%;
416
+ }
417
+ }
418
+ }
419
+
420
+ &:where([data-gutter-buffer], [data-column-number])[data-selected-line] {
421
+ --mix-selection-light: 75%;
422
+ --mix-selection-dark: 60%;
423
+ --diffs-selection-mix-target: var(--diffs-bg-selection-number-override, var(--diffs-selection-base));
424
+
425
+ @media (pointer: fine) {
426
+ &[data-hovered]:not([data-merge-conflict], [data-line-type="change-addition"], [data-line-type="change-deletion"]) {
427
+ --mix-selection-light: 70%;
428
+ --mix-selection-dark: 55%;
429
+ }
430
+ }
431
+ }
432
+
433
+ &[data-selected-line] {
434
+ --diffs-computed-selected-line-bg: light-dark(color-mix(in lab,
435
+ var(--diffs-computed-diff-line-bg) var(--mix-selection-light),
436
+ var(--diffs-selection-mix-target)), color-mix(in lab,
437
+ var(--diffs-computed-diff-line-bg) var(--mix-selection-dark),
438
+ var(--diffs-selection-mix-target)));
439
+ --diffs-line-bg: var(--diffs-computed-selected-line-bg, inherit);
440
+ }
441
+ }
442
+
443
+ [data-gutter-buffer], [data-column-number] {
444
+ &[data-selected-line] {
445
+ color: var(--diffs-selection-number-fg);
446
+ }
447
+ }
448
+
449
+ [data-no-newline] {
450
+ user-select: none;
451
+
452
+ & span {
453
+ opacity: .6;
454
+ }
455
+ }
456
+
457
+ [data-diff-type="split"][data-overflow="scroll"] {
458
+ grid-template-columns: 1fr 1fr;
459
+ display: grid;
460
+
461
+ & [data-additions] {
462
+ border-left: 1px solid var(--diffs-bg);
463
+ }
464
+
465
+ & [data-deletions] {
466
+ border-right: 1px solid var(--diffs-bg);
467
+ }
468
+ }
469
+
470
+ [data-code] {
471
+ grid-auto-flow: dense;
472
+ grid-template-columns: var(--diffs-code-grid);
473
+ overflow: var(--diffs-overflow-override, scroll) clip;
474
+ overscroll-behavior-x: none;
475
+ tab-size: var(--diffs-tab-size, 2);
476
+ padding-top: var(--diffs-gap-block, var(--diffs-gap-fallback));
477
+ padding-bottom: max(0px,
478
+ calc(var(--diffs-gap-block, var(--diffs-gap-fallback)) -
479
+ var(--diffs-scrollbar-gutter)));
480
+ scrollbar-gutter: stable;
481
+ align-self: flex-start;
482
+ display: grid;
483
+ }
484
+
485
+ [data-diffs-scrollbar-measure] {
486
+ opacity: 0;
487
+ pointer-events: none;
488
+ scrollbar-gutter: auto;
489
+ grid-template-columns: none;
490
+ width: 100px;
491
+ height: 100px;
492
+ padding: 0;
493
+ position: absolute;
494
+ top: -200px;
495
+ left: -200px;
496
+ }
497
+
498
+ [data-container-size] {
499
+ container-type: inline-size;
500
+ }
501
+
502
+ [data-code]::-webkit-scrollbar {
503
+ width: 0;
504
+ height: var(--diffs-scrollbar-gutter);
505
+ }
506
+
507
+ [data-code]::-webkit-scrollbar-track {
508
+ background: none;
509
+ }
510
+
511
+ [data-code]::-webkit-scrollbar-thumb {
512
+ background-color: #0000;
513
+ background-clip: content-box;
514
+ border: 1px solid #0000;
515
+ border-radius: 3px;
516
+ }
517
+
518
+ [data-code]::-webkit-scrollbar-corner {
519
+ background-color: #0000;
520
+ }
521
+
522
+ @supports ((-moz-appearance: none)) {
523
+ [data-code] {
524
+ scrollbar-width: thin;
525
+ scrollbar-color: var(--diffs-bg-context) transparent;
526
+ padding-bottom: var(--diffs-gap-block, var(--diffs-gap-fallback));
527
+ }
528
+ }
529
+
530
+ [data-diffs-header] ~ [data-diff], [data-diffs-header] ~ [data-file] {
531
+ & [data-code], &[data-overflow="wrap"] {
532
+ padding-top: 0;
533
+ }
534
+ }
535
+
536
+ [data-gutter] {
537
+ grid-template-rows: subgrid;
538
+ grid-template-columns: subgrid;
539
+ z-index: 3;
540
+ background-color: var(--diffs-bg);
541
+ grid-column: 1;
542
+ display: grid;
543
+ position: relative;
544
+
545
+ & [data-gutter-buffer], & [data-column-number] {
546
+ border-right: var(--diffs-gap-style, 2px solid var(--diffs-bg));
547
+ }
548
+ }
549
+
550
+ [data-content] {
551
+ grid-template-rows: subgrid;
552
+ grid-template-columns: subgrid;
553
+ background-color: var(--diffs-bg);
554
+ grid-column: 2;
555
+ min-width: 0;
556
+ display: grid;
557
+ }
558
+
559
+ [data-diff-type="split"][data-overflow="wrap"] {
560
+ grid-auto-flow: dense;
561
+ grid-template-columns: repeat(2, var(--diffs-code-grid));
562
+ padding-block: var(--diffs-gap-block, var(--diffs-gap-fallback));
563
+ display: grid;
564
+
565
+ & [data-deletions] {
566
+ display: contents;
567
+
568
+ & [data-gutter] {
569
+ grid-column: 1;
570
+ }
571
+
572
+ & [data-content] {
573
+ border-right: 1px solid var(--diffs-bg);
574
+ grid-column: 2;
575
+ }
576
+ }
577
+
578
+ & [data-additions] {
579
+ display: contents;
580
+
581
+ & [data-gutter] {
582
+ border-left: 1px solid var(--diffs-bg);
583
+ grid-column: 3;
584
+ }
585
+
586
+ & [data-content] {
587
+ grid-column: 4;
588
+ }
589
+ }
590
+ }
591
+
592
+ [data-overflow="scroll"] [data-gutter] {
593
+ position: sticky;
594
+ left: 0;
595
+ }
596
+
597
+ [data-interactive-lines] [data-line] {
598
+ cursor: pointer;
599
+ }
600
+
601
+ [data-interactive-line-numbers] [data-column-number] {
602
+ cursor: pointer;
603
+ touch-action: none;
604
+ }
605
+
606
+ [data-content-buffer], [data-gutter-buffer] {
607
+ user-select: none;
608
+ min-height: 1lh;
609
+ position: relative;
610
+ }
611
+
612
+ [data-gutter-buffer] {
613
+ padding-left: 2ch;
614
+ padding-right: 1ch;
615
+
616
+ &:before {
617
+ content: "";
618
+ min-width: var(--diffs-min-number-column-width, var(--diffs-min-number-column-width-default, 3ch));
619
+ display: block;
620
+ }
621
+ }
622
+
623
+ [data-gutter-buffer="annotation"] {
624
+ --diffs-annotation-bg: var(--diffs-bg-context-gutter);
625
+ min-height: 0;
626
+ }
627
+
628
+ [data-gutter-buffer="buffer"] {
629
+ --diffs-line-bg: var(--diffs-bg-context-gutter);
630
+ }
631
+
632
+ [data-content-buffer] {
633
+ background-position: 5px 0;
634
+ background-size: 8px 8px;
635
+ background-origin: border-box;
636
+ background-image: repeating-linear-gradient(-45deg,
637
+ transparent,
638
+ transparent calc(3px * 1.414),
639
+ var(--diffs-bg-buffer) calc(3px * 1.414),
640
+ var(--diffs-bg-buffer) calc(4px * 1.414));
641
+ grid-column: 1;
642
+ }
643
+
644
+ [data-separator] {
645
+ box-sizing: content-box;
646
+ background-color: var(--diffs-bg);
647
+ }
648
+
649
+ [data-separator="simple"] {
650
+ min-height: 4px;
651
+ }
652
+
653
+ [data-separator="line-info"], [data-separator="line-info-basic"], [data-separator="metadata"], [data-separator="simple"] {
654
+ background-color: var(--diffs-bg-separator);
655
+ }
656
+
657
+ [data-separator="line-info"], [data-separator="line-info-basic"], [data-separator="metadata"] {
658
+ height: 32px;
659
+ position: relative;
660
+ }
661
+
662
+ [data-separator-wrapper] {
663
+ user-select: none;
664
+ fill: currentColor;
665
+ background-color: var(--diffs-bg);
666
+ align-items: center;
667
+ height: 100%;
668
+ display: flex;
669
+ position: absolute;
670
+ inset-inline: 0;
671
+ }
672
+
673
+ [data-content] [data-separator-wrapper] {
674
+ display: none;
675
+ }
676
+
677
+ [data-separator="metadata"] [data-separator-wrapper] {
678
+ background-color: var(--diffs-bg-separator);
679
+ height: 100%;
680
+ color: var(--diffs-fg-number);
681
+ white-space: nowrap;
682
+ text-overflow: ellipsis;
683
+ min-width: min-content;
684
+ padding-inline: 1ch;
685
+ inset-inline: 100% auto;
686
+ overflow: hidden;
687
+ }
688
+
689
+ [data-separator="line-info"] {
690
+ margin-block: var(--diffs-gap-block, var(--diffs-gap-fallback));
691
+
692
+ & [data-separator-wrapper] {
693
+ min-width: 16px;
694
+ }
695
+ }
696
+
697
+ [data-separator="line-info-basic"], [data-separator="metadata"] {
698
+ margin-block: 0;
699
+ }
700
+
701
+ [data-separator="line-info"][data-separator-first] {
702
+ margin-top: 0;
703
+ }
704
+
705
+ [data-separator="line-info"][data-separator-last] {
706
+ margin-bottom: 0;
707
+ }
708
+
709
+ [data-expand-index] [data-separator-wrapper] {
710
+ grid-template-columns: 32px auto;
711
+ display: grid;
712
+ }
713
+
714
+ [data-expand-index] [data-separator-wrapper][data-separator-multi-button] {
715
+ grid-template-columns: 32px 32px auto;
716
+ }
717
+
718
+ [data-expand-button], [data-separator-content] {
719
+ background-color: var(--diffs-bg-separator);
720
+ flex: none;
721
+ align-items: center;
722
+ display: flex;
723
+ }
724
+
725
+ [data-expand-index] [data-separator-content]:hover {
726
+ cursor: pointer;
727
+ text-decoration: underline;
728
+ }
729
+
730
+ [data-expand-button] {
731
+ cursor: pointer;
732
+ min-width: 32px;
733
+ color: var(--diffs-fg-number);
734
+ border-right: 2px solid var(--diffs-bg);
735
+ flex-shrink: 0;
736
+ justify-content: center;
737
+ align-self: stretch;
738
+
739
+ &:hover {
740
+ color: var(--diffs-fg);
741
+ }
742
+
743
+ &[data-expand-all-button] {
744
+ display: none;
745
+ }
746
+ }
747
+
748
+ [data-expand-down] [data-icon] {
749
+ transform: scaleY(-1);
750
+ }
751
+
752
+ [data-separator-content] {
753
+ height: 100%;
754
+ color: var(--diffs-fg-number);
755
+ flex: auto;
756
+ justify-content: flex-start;
757
+ padding: 0 1ch;
758
+ overflow: hidden;
759
+ }
760
+
761
+ [data-separator="line-info"], [data-separator="line-info-basic"] {
762
+ & [data-separator-content] {
763
+ user-select: none;
764
+ height: 100%;
765
+ overflow: clip;
766
+ }
767
+ }
768
+
769
+ [data-unmodified-lines] {
770
+ text-overflow: ellipsis;
771
+ white-space: nowrap;
772
+ flex: 0 auto;
773
+ min-width: 0;
774
+ display: block;
775
+ overflow: hidden;
776
+ }
777
+
778
+ @supports (width: 1cqi) {
779
+ [data-unified] {
780
+ & [data-separator="line-info"] [data-separator-wrapper] {
781
+ padding-inline: var(--diffs-gap-inline, var(--diffs-gap-fallback));
782
+ width: 100cqi;
783
+
784
+ & [data-separator-content] {
785
+ border-radius: 6px;
786
+ }
787
+ }
788
+
789
+ & [data-separator="line-info"][data-expand-index] [data-separator-wrapper] [data-separator-content] {
790
+ border-top-left-radius: unset;
791
+ border-bottom-left-radius: unset;
792
+ }
793
+ }
794
+
795
+ [data-gutter] {
796
+ & [data-separator="line-info"] [data-separator-wrapper] {
797
+ padding-left: var(--diffs-gap-inline, var(--diffs-gap-fallback));
798
+ }
799
+
800
+ & [data-separator="line-info"] [data-separator-content] {
801
+ border-top-left-radius: 6px;
802
+ border-bottom-left-radius: 6px;
803
+ }
804
+
805
+ & [data-separator="line-info"][data-expand-index] [data-separator-content] {
806
+ border-top-left-radius: unset;
807
+ border-bottom-left-radius: unset;
808
+ }
809
+ }
810
+
811
+ [data-additions] {
812
+ & [data-content] [data-separator="line-info"] {
813
+ background-color: var(--diffs-bg);
814
+
815
+ & [data-separator-wrapper] {
816
+ display: none;
817
+ }
818
+ }
819
+
820
+ & [data-gutter] [data-separator="line-info"] [data-separator-wrapper] {
821
+ background-color: var(--diffs-bg-separator);
822
+ border-top-right-radius: 6px;
823
+ border-bottom-right-radius: 6px;
824
+ height: 100%;
825
+ display: block;
826
+
827
+ & [data-separator-content], & [data-expand-button] {
828
+ display: none;
829
+ }
830
+ }
831
+ }
832
+
833
+ [data-overflow="scroll"] [data-additions] [data-gutter] [data-separator="line-info"] [data-separator-wrapper] {
834
+ width: calc(100cqi - var(--diffs-gap-inline, var(--diffs-gap-fallback)));
835
+ }
836
+
837
+ [data-overflow="wrap"] [data-additions] [data-content] [data-separator="line-info"] [data-separator-wrapper] {
838
+ background-color: var(--diffs-bg-separator);
839
+ height: 100%;
840
+ margin-right: var(--diffs-gap-inline, var(--diffs-gap-fallback));
841
+ border-top-right-radius: 6px;
842
+ border-bottom-right-radius: 6px;
843
+ display: block;
844
+
845
+ & [data-separator-content], & [data-expand-button] {
846
+ display: none;
847
+ }
848
+ }
849
+
850
+ [data-separator="line-info"] [data-separator-wrapper] {
851
+ & [data-expand-both], & [data-expand-down], & [data-expand-up] {
852
+ border-top-left-radius: 6px;
853
+ border-bottom-left-radius: 6px;
854
+ }
855
+ }
856
+
857
+ @media (pointer: fine) {
858
+ [data-separator="line-info"] [data-separator-wrapper] {
859
+ &[data-separator-multi-button] {
860
+ & [data-expand-up] {
861
+ border-top-left-radius: 6px;
862
+ border-bottom-left-radius: unset;
863
+ }
864
+
865
+ & [data-expand-down] {
866
+ border-bottom-left-radius: 6px;
867
+ border-top-left-radius: unset;
868
+ }
869
+ }
870
+ }
871
+ }
872
+ }
873
+
874
+ @media (pointer: coarse) {
875
+ [data-separator="line-info-basic"] [data-separator-wrapper][data-separator-multi-button] {
876
+ grid-template-columns: 34px 34px auto;
877
+
878
+ & [data-separator-content] {
879
+ grid-column: unset;
880
+ grid-row: unset;
881
+ }
882
+ }
883
+
884
+ @supports (width: 1cqi) {
885
+ [data-separator="line-info"] [data-separator-wrapper] {
886
+ & [data-expand-both], & [data-expand-down], & [data-expand-up] {
887
+ border-top-left-radius: 6px;
888
+ border-bottom-left-radius: 6px;
889
+ }
890
+
891
+ &[data-separator-multi-button] {
892
+ & [data-expand-up] {
893
+ border-top-left-radius: 6px;
894
+ border-bottom-left-radius: 6px;
895
+ }
896
+
897
+ & [data-expand-down] {
898
+ border-bottom-left-radius: unset;
899
+ border-top-left-radius: unset;
900
+ }
901
+ }
902
+ }
903
+ }
904
+ }
905
+
906
+ @media (pointer: fine) {
907
+ [data-separator-wrapper][data-separator-multi-button] {
908
+ grid-template-rows: 50% 50%;
909
+ display: grid;
910
+
911
+ & [data-separator-content] {
912
+ grid-area: 1 / 2 / -1;
913
+ min-width: min-content;
914
+ }
915
+
916
+ & [data-expand-button] {
917
+ grid-column: 1;
918
+ }
919
+ }
920
+
921
+ [data-separator="line-info"] [data-separator-wrapper], [data-separator="line-info"] [data-separator-wrapper][data-separator-multi-button] {
922
+ grid-template-columns: 34px auto;
923
+ }
924
+
925
+ [data-separator="line-info-basic"][data-expand-index] [data-separator-wrapper] {
926
+ grid-template-columns: 100% auto;
927
+ }
928
+
929
+ [data-separator="line-info"], [data-separator="line-info-basic"] {
930
+ & [data-separator-multi-button] {
931
+ & [data-expand-up] {
932
+ border-bottom: 1px solid var(--diffs-bg);
933
+ border-right: 2px solid var(--diffs-bg);
934
+ }
935
+
936
+ & [data-expand-down] {
937
+ border-top: 1px solid var(--diffs-bg);
938
+ border-right: 2px solid var(--diffs-bg);
939
+ }
940
+ }
941
+ }
942
+ }
943
+
944
+ [data-additions] [data-gutter] [data-separator-wrapper], [data-additions] [data-separator="line-info-basic"] [data-separator-wrapper], [data-content] [data-separator-wrapper] {
945
+ display: none;
946
+ }
947
+
948
+ [data-line-annotation] {
949
+ min-height: var(--diffs-annotation-min-height, 0);
950
+ z-index: 2;
951
+ }
952
+
953
+ [data-merge-conflict-actions] {
954
+ z-index: 2;
955
+ }
956
+
957
+ [data-separator="custom"] {
958
+ grid-template-columns: subgrid;
959
+ display: grid;
960
+ }
961
+
962
+ [data-line], [data-column-number], [data-no-newline] {
963
+ padding-inline: 1ch;
964
+ position: relative;
965
+ }
966
+
967
+ [data-indicators="classic"] [data-line] {
968
+ padding-inline-start: 2ch;
969
+ }
970
+
971
+ [data-indicators="classic"] {
972
+ & [data-line-type="change-addition"], & [data-line-type="change-deletion"] {
973
+ &[data-no-newline], &[data-line] {
974
+ &:before {
975
+ user-select: none;
976
+ width: 1ch;
977
+ height: 1lh;
978
+ display: inline-block;
979
+ position: absolute;
980
+ top: 0;
981
+ left: 0;
982
+ }
983
+ }
984
+ }
985
+
986
+ & [data-line-type="change-addition"] {
987
+ &[data-line], &[data-no-newline] {
988
+ &:before {
989
+ content: "+";
990
+ color: var(--diffs-addition-base);
991
+ }
992
+ }
993
+ }
994
+
995
+ & [data-line-type="change-deletion"] {
996
+ &[data-line], &[data-no-newline] {
997
+ &:before {
998
+ content: "-";
999
+ color: var(--diffs-deletion-base);
1000
+ }
1001
+ }
1002
+ }
1003
+ }
1004
+
1005
+ [data-indicators="bars"] {
1006
+ & [data-line-type="change-deletion"], & [data-line-type="change-addition"] {
1007
+ &[data-column-number] {
1008
+ &:before {
1009
+ content: "";
1010
+ user-select: none;
1011
+ contain: strict;
1012
+ width: 4px;
1013
+ height: 100%;
1014
+ display: block;
1015
+ position: absolute;
1016
+ top: 0;
1017
+ left: 0;
1018
+ }
1019
+ }
1020
+ }
1021
+
1022
+ & [data-line-type="change-deletion"] {
1023
+ &[data-column-number] {
1024
+ &:before {
1025
+ background-image: linear-gradient(0deg,
1026
+ var(--diffs-bg-deletion) 50%,
1027
+ var(--diffs-deletion-base) 50%);
1028
+ background-repeat: repeat;
1029
+ background-size: 2px 2px;
1030
+ background-size: calc(1lh / round(1lh / 2px))
1031
+ calc(1lh / round(1lh / 2px));
1032
+ }
1033
+ }
1034
+ }
1035
+
1036
+ & [data-line-type="change-addition"] {
1037
+ &[data-column-number] {
1038
+ &:before {
1039
+ background-color: var(--diffs-addition-base);
1040
+ }
1041
+ }
1042
+ }
1043
+ }
1044
+
1045
+ [data-overflow="wrap"] {
1046
+ & [data-line], & [data-annotation-content] {
1047
+ white-space: pre-wrap;
1048
+ word-break: break-word;
1049
+ }
1050
+ }
1051
+
1052
+ [data-overflow="scroll"] [data-line] {
1053
+ white-space: pre;
1054
+ min-height: 1lh;
1055
+ }
1056
+
1057
+ [data-column-number] {
1058
+ box-sizing: content-box;
1059
+ text-align: right;
1060
+ user-select: none;
1061
+ color: var(--diffs-fg-number);
1062
+ padding-left: 2ch;
1063
+ }
1064
+
1065
+ [data-line-number-content] {
1066
+ min-width: var(--diffs-min-number-column-width, var(--diffs-min-number-column-width-default, 3ch));
1067
+ z-index: 1;
1068
+ display: inline-block;
1069
+ position: relative;
1070
+ }
1071
+
1072
+ [data-disable-line-numbers] {
1073
+ & [data-gutter-buffer], & [data-column-number] {
1074
+ min-width: 4px;
1075
+ padding: 0;
1076
+
1077
+ &:before {
1078
+ min-width: 0;
1079
+ }
1080
+ }
1081
+
1082
+ & [data-line-number-content] {
1083
+ display: none;
1084
+ }
1085
+
1086
+ & [data-gutter-utility-slot] {
1087
+ right: unset;
1088
+ justify-content: flex-start;
1089
+ left: 0;
1090
+ }
1091
+
1092
+ &[data-indicators="bars"] [data-gutter-utility-slot] {
1093
+ left: 6px;
1094
+ }
1095
+ }
1096
+
1097
+ [data-file][data-disable-line-numbers] {
1098
+ & [data-gutter-buffer], & [data-column-number] {
1099
+ border-right: 0;
1100
+ min-width: 0;
1101
+ }
1102
+ }
1103
+
1104
+ [data-diff-span] {
1105
+ box-decoration-break: clone;
1106
+ border-radius: 3px;
1107
+ }
1108
+
1109
+ [data-line-type="change-addition"] [data-diff-span] {
1110
+ background-color: var(--diffs-bg-addition-emphasis);
1111
+ }
1112
+
1113
+ [data-line-type="change-deletion"] [data-diff-span] {
1114
+ background-color: var(--diffs-bg-deletion-emphasis);
1115
+ }
1116
+
1117
+ [data-merge-conflict="marker-start"], [data-merge-conflict="marker-base"], [data-merge-conflict="marker-separator"], [data-merge-conflict="marker-end"] {
1118
+ color: var(--diffs-fg);
1119
+ padding-left: 1ch;
1120
+ }
1121
+
1122
+ [data-merge-conflict="marker-start"], [data-merge-conflict="marker-end"] {
1123
+ align-items: center;
1124
+ display: flex;
1125
+
1126
+ &:after {
1127
+ color: var(--diffs-fg-conflict-marker);
1128
+ font-size: .75rem;
1129
+ font-style: normal;
1130
+ line-height: 1.25rem;
1131
+ font-family: var(--diffs-header-font-family, var(--diffs-header-font-fallback));
1132
+ padding-left: 1ch;
1133
+ }
1134
+ }
1135
+
1136
+ [data-merge-conflict="marker-start"]:after {
1137
+ content: "(Current Change)";
1138
+ }
1139
+
1140
+ [data-merge-conflict="marker-end"]:after {
1141
+ content: "(Incoming Change)";
1142
+ }
1143
+
1144
+ [data-merge-conflict-actions-content] {
1145
+ min-height: 1.75rem;
1146
+ font-family: var(--diffs-header-font-family, var(--diffs-header-font-fallback));
1147
+ color: var(--diffs-fg);
1148
+ align-items: center;
1149
+ gap: .25rem;
1150
+ padding-inline: .5rem;
1151
+ font-size: .75rem;
1152
+ line-height: 1.2;
1153
+ display: flex;
1154
+ }
1155
+
1156
+ [data-merge-conflict-action] {
1157
+ appearance: none;
1158
+ color: var(--diffs-fg-number);
1159
+ font: inherit;
1160
+ cursor: pointer;
1161
+ background: none;
1162
+ border: 0;
1163
+ padding: 0;
1164
+ font-style: normal;
1165
+ }
1166
+
1167
+ [data-merge-conflict-action]:hover {
1168
+ color: var(--diffs-fg);
1169
+ }
1170
+
1171
+ [data-merge-conflict-action="current"]:hover {
1172
+ color: var(--diffs-addition-base);
1173
+ }
1174
+
1175
+ [data-merge-conflict-action="incoming"]:hover {
1176
+ color: var(--diffs-modified-base);
1177
+ }
1178
+
1179
+ [data-merge-conflict-action-separator] {
1180
+ color: var(--diffs-fg-number);
1181
+ opacity: .6;
1182
+ user-select: none;
1183
+ }
1184
+
1185
+ [data-diffs-header="default"] {
1186
+ background-color: var(--diffs-bg);
1187
+ justify-content: space-between;
1188
+ align-items: center;
1189
+ gap: var(--diffs-gap-inline, var(--diffs-gap-fallback));
1190
+ min-height: calc(1lh + (var(--diffs-gap-block, var(--diffs-gap-fallback)) * 3));
1191
+ z-index: 2;
1192
+ flex-direction: row;
1193
+ padding-inline: 16px;
1194
+ display: flex;
1195
+ position: relative;
1196
+ top: 0;
1197
+ }
1198
+
1199
+ [data-header-content] {
1200
+ align-items: center;
1201
+ gap: var(--diffs-gap-inline, var(--diffs-gap-fallback));
1202
+ white-space: nowrap;
1203
+ flex-direction: row;
1204
+ min-width: 0;
1205
+ display: flex;
1206
+ }
1207
+
1208
+ [data-header-content] [data-prev-name], [data-header-content] [data-title] {
1209
+ text-overflow: ellipsis;
1210
+ white-space: nowrap;
1211
+ direction: rtl;
1212
+ min-width: 0;
1213
+ overflow: hidden;
1214
+ }
1215
+
1216
+ [data-prev-name] {
1217
+ opacity: .7;
1218
+ }
1219
+
1220
+ [data-rename-icon] {
1221
+ fill: currentColor;
1222
+ flex-grow: 0;
1223
+ flex-shrink: 0;
1224
+ }
1225
+
1226
+ [data-diffs-header="default"] [data-metadata] {
1227
+ white-space: nowrap;
1228
+ align-items: center;
1229
+ gap: 1ch;
1230
+ display: flex;
1231
+ }
1232
+
1233
+ [data-diffs-header="default"] [data-additions-count] {
1234
+ font-family: var(--diffs-font-family, var(--diffs-font-fallback));
1235
+ color: var(--diffs-addition-base);
1236
+ }
1237
+
1238
+ [data-diffs-header="default"] [data-deletions-count] {
1239
+ font-family: var(--diffs-font-family, var(--diffs-font-fallback));
1240
+ color: var(--diffs-deletion-base);
1241
+ }
1242
+
1243
+ [data-change-icon] {
1244
+ fill: currentColor;
1245
+ flex-shrink: 0;
1246
+ }
1247
+
1248
+ [data-change-icon="change"], [data-change-icon="rename-pure"], [data-change-icon="rename-changed"] {
1249
+ color: var(--diffs-modified-base);
1250
+ }
1251
+
1252
+ [data-change-icon="new"] {
1253
+ color: var(--diffs-addition-base);
1254
+ }
1255
+
1256
+ [data-change-icon="deleted"] {
1257
+ color: var(--diffs-deletion-base);
1258
+ }
1259
+
1260
+ [data-change-icon="file"] {
1261
+ opacity: .6;
1262
+ }
1263
+
1264
+ [data-annotation-content] {
1265
+ z-index: 2;
1266
+ isolation: isolate;
1267
+ align-self: flex-start;
1268
+ min-width: 0;
1269
+ display: flow-root;
1270
+ position: relative;
1271
+ }
1272
+
1273
+ [data-overflow="scroll"] [data-annotation-content], [data-overflow="scroll"] [data-merge-conflict-actions-content] {
1274
+ width: var(--diffs-column-content-width, auto);
1275
+ left: var(--diffs-column-number-width, 0);
1276
+ position: sticky;
1277
+ }
1278
+
1279
+ [data-annotation-slot] {
1280
+ text-wrap-mode: wrap;
1281
+ word-break: normal;
1282
+ white-space-collapse: collapse;
1283
+ }
1284
+
1285
+ [data-gutter-utility-slot] {
1286
+ touch-action: none;
1287
+ justify-content: flex-end;
1288
+ display: flex;
1289
+ position: absolute;
1290
+ top: 0;
1291
+ bottom: 0;
1292
+ right: 0;
1293
+ }
1294
+
1295
+ [data-utility-button] {
1296
+ appearance: none;
1297
+ cursor: pointer;
1298
+ width: 1lh;
1299
+ height: 1lh;
1300
+ font-size: var(--diffs-font-size, 13px);
1301
+ line-height: var(--diffs-line-height, 20px);
1302
+ background-color: var(--diffs-modified-base);
1303
+ color: var(--diffs-bg);
1304
+ fill: currentColor;
1305
+ z-index: 4;
1306
+ touch-action: none;
1307
+ border: none;
1308
+ border-radius: 4px;
1309
+ justify-content: center;
1310
+ align-items: center;
1311
+ margin-right: calc(-1lh + 1ch);
1312
+ padding: 0;
1313
+ display: flex;
1314
+ position: relative;
1315
+
1316
+ &:before {
1317
+ content: "";
1318
+ display: block;
1319
+ position: absolute;
1320
+ inset: 0 0 0 -4px;
1321
+ }
1322
+ }
1323
+
1324
+ [data-decoration-bar-stack] {
1325
+ pointer-events: none;
1326
+ isolation: isolate;
1327
+ z-index: 1;
1328
+ background-color: var(--diffs-decoration-bar-color, transparent);
1329
+ box-sizing: content-box;
1330
+ border-left: 2px solid var(--diffs-bg);
1331
+ border-right: 2px solid var(--diffs-bg);
1332
+ width: 6px;
1333
+ position: absolute;
1334
+ top: 0;
1335
+ bottom: 0;
1336
+ right: -2px;
1337
+
1338
+ [data-decoration-bar-depth="1"] & {
1339
+ background-color: color-mix(in lab,
1340
+ var(--diffs-bg) 20%,
1341
+ var(--diffs-decoration-bar-color, transparent));
1342
+ }
1343
+
1344
+ [data-decoration-bar-depth="2"] & {
1345
+ background-color: color-mix(in lab,
1346
+ var(--diffs-bg) 45%,
1347
+ var(--diffs-decoration-bar-color, transparent));
1348
+ }
1349
+
1350
+ [data-decoration-bar-depth="3"] & {
1351
+ background-color: color-mix(in lab,
1352
+ var(--diffs-bg) 65%,
1353
+ var(--diffs-decoration-bar-color, transparent));
1354
+ }
1355
+
1356
+ [data-decoration-bar-start] & {
1357
+ border-top-left-radius: 5px;
1358
+ border-top-right-radius: 5px;
1359
+ }
1360
+
1361
+ [data-decoration-bar-end] & {
1362
+ z-index: 3;
1363
+ border-bottom-right-radius: 5px;
1364
+ border-bottom-left-radius: 5px;
1365
+ }
1366
+ }
1367
+
1368
+ [data-placeholder] {
1369
+ contain: strict;
1370
+ }
1371
+
1372
+ [data-error-wrapper] {
1373
+ padding: var(--diffs-gap-block, var(--diffs-gap-fallback))
1374
+ var(--diffs-gap-inline, var(--diffs-gap-fallback));
1375
+ scrollbar-width: none;
1376
+ max-height: 400px;
1377
+ overflow: auto;
1378
+
1379
+ & [data-error-message] {
1380
+ color: var(--diffs-deletion-base);
1381
+ font-size: 18px;
1382
+ font-weight: bold;
1383
+ }
1384
+
1385
+ & [data-error-stack] {
1386
+ color: var(--diffs-fg-number);
1387
+ }
1388
+ }
1389
+ }
1390
+
1391
+ @layer theme, rendered, unsafe;
1392
+ `,Is=`@layer base, theme, rendered, unsafe;`,Ls=RegExp(`${Vs(Yr)}\\s*:\\s*[^;]+;`);function Rs(e){return`${Is}
1393
+ @layer unsafe {
1394
+ ${e}
1395
+ }`}function zs(e,t=`system`,n){return`${Is}
1396
+ @layer rendered {
1397
+ :host {${t===`system`?``:`
1398
+ color-scheme: ${t};`}
1399
+ ${Ps(n)}
1400
+ ${e}
1401
+ }
1402
+ }`}function Bs(e,t){let n=Ps(t);return e.replace(Ls,n)}function Vs(e){return e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`)}function Hs({code:e,pre:t,columnType:n,rowSpan:r,containerSize:i=!1}={}){return e??(e=document.createElement(`code`),e.setAttribute(`data-code`,``),n!=null&&e.setAttribute(`data-${n}`,``),t?.appendChild(e)),r==null?e.style.removeProperty(`grid-row`):e.style.setProperty(`grid-row`,`span ${r}`),i?e.setAttribute(`data-container-size`,``):e.removeAttribute(`data-container-size`),e}function Us({shadowRoot:e,currentNode:t,themeCSS:n}){if(n.trim()===``){t?.remove();return}return t??=Ws(),t.textContent=n,t.parentNode!==e&&e.appendChild(t),t}function Ws(){let e=document.createElement(`style`);return e.setAttribute(Kr,``),e}function Gs(e,t){if(t==null)return;let n=e.shadowRoot??e.attachShadow({mode:`open`});n.innerHTML===``&&(n.innerHTML=t)}function Ks(e,{type:t,diffIndicators:n,disableBackground:r,disableLineNumbers:i,overflow:a,split:o,totalLines:s,customProperties:c}){if(c!=null)for(let t in c){let n=c[t];n!=null&&e.setAttribute(t,`${n}`)}switch(t===`diff`?(e.setAttribute(`data-diff`,``),e.removeAttribute(`data-file`)):(e.setAttribute(`data-file`,``),e.removeAttribute(`data-diff`)),n){case`bars`:case`classic`:e.setAttribute(`data-indicators`,n);break;case`none`:e.removeAttribute(`data-indicators`);break}return i?e.setAttribute(`data-disable-line-numbers`,``):e.removeAttribute(`data-disable-line-numbers`),r?e.removeAttribute(`data-background`):e.setAttribute(`data-background`,``),t===`diff`?e.setAttribute(`data-diff-type`,o?`split`:`single`):e.removeAttribute(`data-diff-type`),e.setAttribute(`data-overflow`,a),e.style.setProperty(`--diffs-min-number-column-width-default`,`${`${s}`.length}ch`),e}if(typeof HTMLElement<`u`&&customElements.get(`diffs-container`)==null){let e;class t extends HTMLElement{constructor(){if(super(),this.shadowRoot!=null)return;let t=this.attachShadow({mode:`open`});e??(e=new CSSStyleSheet,e.replaceSync(Fs)),t.adoptedStyleSheets=[e]}connectedCallback(){Ns(this.shadowRoot??this.attachShadow({mode:`open`}))}}customElements.define(Fr,t)}var qs=class{diff(e,t,n={}){let r;typeof n==`function`?(r=n,n={}):`callback`in n&&(r=n.callback);let i=this.castInput(e,n),a=this.castInput(t,n),o=this.removeEmpty(this.tokenize(i,n)),s=this.removeEmpty(this.tokenize(a,n));return this.diffWithOptionsObj(o,s,n,r)}diffWithOptionsObj(e,t,n,r){let i=e=>{if(e=this.postProcess(e,n),r){setTimeout(function(){r(e)},0);return}else return e},a=t.length,o=e.length,s=1,c=a+o;n.maxEditLength!=null&&(c=Math.min(c,n.maxEditLength));let l=n.timeout??1/0,u=Date.now()+l,d=[{oldPos:-1,lastComponent:void 0}],f=this.extractCommon(d[0],t,e,0,n);if(d[0].oldPos+1>=o&&f+1>=a)return i(this.buildValues(d[0].lastComponent,t,e));let p=-1/0,m=1/0,h=()=>{for(let r=Math.max(p,-s);r<=Math.min(m,s);r+=2){let s,c=d[r-1],l=d[r+1];c&&(d[r-1]=void 0);let u=!1;if(l){let e=l.oldPos-r;u=l&&0<=e&&e<a}let h=c&&c.oldPos+1<o;if(!u&&!h){d[r]=void 0;continue}if(s=!h||u&&c.oldPos<l.oldPos?this.addToPath(l,!0,!1,0,n):this.addToPath(c,!1,!0,1,n),f=this.extractCommon(s,t,e,r,n),s.oldPos+1>=o&&f+1>=a)return i(this.buildValues(s.lastComponent,t,e))||!0;d[r]=s,s.oldPos+1>=o&&(m=Math.min(m,r-1)),f+1>=a&&(p=Math.max(p,r+1))}s++};if(r)(function e(){setTimeout(function(){if(s>c||Date.now()>u)return r(void 0);h()||e()},0)})();else for(;s<=c&&Date.now()<=u;){let e=h();if(e)return e}}addToPath(e,t,n,r,i){let a=e.lastComponent;return a&&!i.oneChangePerToken&&a.added===t&&a.removed===n?{oldPos:e.oldPos+r,lastComponent:{count:a.count+1,added:t,removed:n,previousComponent:a.previousComponent}}:{oldPos:e.oldPos+r,lastComponent:{count:1,added:t,removed:n,previousComponent:a}}}extractCommon(e,t,n,r,i){let a=t.length,o=n.length,s=e.oldPos,c=s-r,l=0;for(;c+1<a&&s+1<o&&this.equals(n[s+1],t[c+1],i);)c++,s++,l++,i.oneChangePerToken&&(e.lastComponent={count:1,previousComponent:e.lastComponent,added:!1,removed:!1});return l&&!i.oneChangePerToken&&(e.lastComponent={count:l,previousComponent:e.lastComponent,added:!1,removed:!1}),e.oldPos=s,c}equals(e,t,n){return n.comparator?n.comparator(e,t):e===t||!!n.ignoreCase&&e.toLowerCase()===t.toLowerCase()}removeEmpty(e){let t=[];for(let n=0;n<e.length;n++)e[n]&&t.push(e[n]);return t}castInput(e,t){return e}tokenize(e,t){return Array.from(e)}join(e){return e.join(``)}postProcess(e,t){return e}get useLongestToken(){return!1}buildValues(e,t,n){let r=[],i;for(;e;)r.push(e),i=e.previousComponent,delete e.previousComponent,e=i;r.reverse();let a=r.length,o=0,s=0,c=0;for(;o<a;o++){let e=r[o];if(e.removed)e.value=this.join(n.slice(c,c+e.count)),c+=e.count;else{if(!e.added&&this.useLongestToken){let r=t.slice(s,s+e.count);r=r.map(function(e,t){let r=n[c+t];return r.length>e.length?r:e}),e.value=this.join(r)}else e.value=this.join(t.slice(s,s+e.count));s+=e.count,e.added||(c+=e.count)}}return r}},Js=new class extends qs{};function Ys(e,t,n){return Js.diff(e,t,n)}function Xs(e,t){let n;for(n=0;n<e.length&&n<t.length;n++)if(e[n]!=t[n])return e.slice(0,n);return e.slice(0,n)}function Zs(e,t){let n;if(!e||!t||e[e.length-1]!=t[t.length-1])return``;for(n=0;n<e.length&&n<t.length;n++)if(e[e.length-(n+1)]!=t[t.length-(n+1)])return e.slice(-n);return e.slice(-n)}function Qs(e,t,n){if(e.slice(0,t.length)!=t)throw Error(`string ${JSON.stringify(e)} doesn't start with prefix ${JSON.stringify(t)}; this is a bug`);return n+e.slice(t.length)}function $s(e,t,n){if(!t)return e+n;if(e.slice(-t.length)!=t)throw Error(`string ${JSON.stringify(e)} doesn't end with suffix ${JSON.stringify(t)}; this is a bug`);return e.slice(0,-t.length)+n}function ec(e,t){return Qs(e,t,``)}function tc(e,t){return $s(e,t,``)}function nc(e,t){return t.slice(0,rc(e,t))}function rc(e,t){let n=0;e.length>t.length&&(n=e.length-t.length);let r=t.length;e.length<t.length&&(r=e.length);let i=Array(r),a=0;i[0]=0;for(let e=1;e<r;e++){for(t[e]==t[a]?i[e]=i[a]:i[e]=a;a>0&&t[e]!=t[a];)a=i[a];t[e]==t[a]&&a++}a=0;for(let r=n;r<e.length;r++){for(;a>0&&e[r]!=t[a];)a=i[a];e[r]==t[a]&&a++}return a}function ic(e,t){let n=[];for(let r of Array.from(t.segment(e))){let e=r.segment;n.length&&/\s/.test(n[n.length-1])&&/\s/.test(e)?n[n.length-1]+=e:n.push(e)}return n}function ac(e,t){if(t)return sc(e,t)[1];let n;for(n=e.length-1;n>=0&&e[n].match(/\s/);n--);return e.substring(n+1)}function oc(e,t){if(t)return sc(e,t)[0];let n=e.match(/^\s*/);return n?n[0]:``}function sc(e,t){if(!t)return[oc(e),ac(e)];if(t.resolvedOptions().granularity!=`word`)throw Error(`The segmenter passed must have a granularity of "word"`);let n=ic(e,t),r=n[0],i=n[n.length-1];return[/\s/.test(r)?r:``,/\s/.test(i)?i:``]}var cc=`a-zA-Z0-9_\\u{AD}\\u{C0}-\\u{D6}\\u{D8}-\\u{F6}\\u{F8}-\\u{2C6}\\u{2C8}-\\u{2D7}\\u{2DE}-\\u{2FF}\\u{1E00}-\\u{1EFF}`,lc=RegExp(`[${cc}]+|\\s+|[^${cc}]`,`ug`);new class extends qs{equals(e,t,n){return n.ignoreCase&&(e=e.toLowerCase(),t=t.toLowerCase()),e.trim()===t.trim()}tokenize(e,t={}){let n;if(t.intlSegmenter){let r=t.intlSegmenter;if(r.resolvedOptions().granularity!=`word`)throw Error(`The segmenter passed must have a granularity of "word"`);n=ic(e,r)}else n=e.match(lc)||[];let r=[],i=null;return n.forEach(e=>{/\s/.test(e)?i==null?r.push(e):r.push(r.pop()+e):i!=null&&/\s/.test(i)?r[r.length-1]==i?r.push(r.pop()+e):r.push(i+e):r.push(e),i=e}),r}join(e){return e.map((e,t)=>t==0?e:e.replace(/^\s+/,``)).join(``)}postProcess(e,t){if(!e||t.oneChangePerToken)return e;let n=null,r=null,i=null;return e.forEach(e=>{e.added?r=e:e.removed?i=e:((r||i)&&uc(n,i,r,e,t.intlSegmenter),n=e,r=null,i=null)}),(r||i)&&uc(n,i,r,null,t.intlSegmenter),e}};function uc(e,t,n,r,i){if(t&&n){let[a,o]=sc(t.value,i),[s,c]=sc(n.value,i);if(e){let r=Xs(a,s);e.value=$s(e.value,s,r),t.value=ec(t.value,r),n.value=ec(n.value,r)}if(r){let e=Zs(o,c);r.value=Qs(r.value,c,e),t.value=tc(t.value,e),n.value=tc(n.value,e)}}else if(n){if(e){let e=oc(n.value,i);n.value=n.value.substring(e.length)}if(r){let e=oc(r.value,i);r.value=r.value.substring(e.length)}}else if(e&&r){let n=oc(r.value,i),[a,o]=sc(t.value,i),s=Xs(n,a);t.value=ec(t.value,s);let c=Zs(ec(n,s),o);t.value=tc(t.value,c),r.value=Qs(r.value,n,c),e.value=$s(e.value,n,n.slice(0,n.length-c.length))}else if(r){let e=oc(r.value,i),n=nc(ac(t.value,i),e);t.value=tc(t.value,n)}else if(e){let n=nc(ac(e.value,i),oc(t.value,i));t.value=ec(t.value,n)}}var dc=new class extends qs{tokenize(e){let t=RegExp(`(\\r?\\n)|[${cc}]+|[^\\S\\n\\r]+|[^${cc}]`,`ug`);return e.match(t)||[]}};function fc(e,t,n){return dc.diff(e,t,n)}var pc=new class extends qs{constructor(){super(...arguments),this.tokenize=hc}equals(e,t,n){return n.ignoreWhitespace?((!n.newlineIsToken||!e.includes(`
1403
+ `))&&(e=e.trim()),(!n.newlineIsToken||!t.includes(`
1404
+ `))&&(t=t.trim())):n.ignoreNewlineAtEof&&!n.newlineIsToken&&(e.endsWith(`
1405
+ `)&&(e=e.slice(0,-1)),t.endsWith(`
1406
+ `)&&(t=t.slice(0,-1))),super.equals(e,t,n)}};function mc(e,t,n){return pc.diff(e,t,n)}function hc(e,t){t.stripTrailingCr&&(e=e.replace(/\r\n/g,`
1407
+ `));let n=[],r=e.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(let e=0;e<r.length;e++){let i=r[e];e%2&&!t.newlineIsToken?n[n.length-1]+=i:n.push(i)}return n}function gc(e){return e==`.`||e==`!`||e==`?`}new class extends qs{tokenize(e){let t=[],n=0;for(let r=0;r<e.length;r++){if(r==e.length-1){t.push(e.slice(n));break}if(gc(e[r])&&e[r+1].match(/\s/)){for(t.push(e.slice(n,r+1)),r=n=r+1;e[r+1]?.match(/\s/);)r++;t.push(e.slice(n,r+1)),n=r+1}}return t}},new class extends qs{tokenize(e){return e.split(/([{}:;,]|\s+)/)}},new class extends qs{constructor(){super(...arguments),this.tokenize=hc}get useLongestToken(){return!0}castInput(e,t){let{undefinedReplacement:n,stringifyReplacer:r=(e,t)=>t===void 0?n:t}=t;return typeof e==`string`?e:JSON.stringify(_c(e,null,null,r),null,` `)}equals(e,t,n){return super.equals(e.replace(/,([\r\n])/g,`$1`),t.replace(/,([\r\n])/g,`$1`),n)}};function _c(e,t,n,r,i){t||=[],n||=[],r&&(e=r(i===void 0?``:i,e));let a;for(a=0;a<t.length;a+=1)if(t[a]===e)return n[a];let o;if(Object.prototype.toString.call(e)===`[object Array]`){for(t.push(e),o=Array(e.length),n.push(o),a=0;a<e.length;a+=1)o[a]=_c(e[a],t,n,r,String(a));return t.pop(),n.pop(),o}if(e&&e.toJSON&&(e=e.toJSON()),typeof e==`object`&&e){t.push(e),o={},n.push(o);let i=[],s;for(s in e)Object.prototype.hasOwnProperty.call(e,s)&&i.push(s);for(i.sort(),a=0;a<i.length;a+=1)s=i[a],o[s]=_c(e[s],t,n,r,s);t.pop(),n.pop()}else o=e;return o}new class extends qs{tokenize(e){return e.slice()}join(e){return e}removeEmpty(e){return e}};function vc(e){for(let t=0;t<e.length;t++)if(e[t]<` `||e[t]>`~`||e[t]===`"`||e[t]===`\\`)return!0;return!1}function yc(e){if(!vc(e))return e;let t=`"`,n=new TextEncoder().encode(e),r=0;for(;r<n.length;){let e=n[r];e===7?t+=`\\a`:e===8?t+=`\\b`:e===9?t+=`\\t`:e===10?t+=`\\n`:e===11?t+=`\\v`:e===12?t+=`\\f`:e===13?t+=`\\r`:e===34?t+=`\\"`:e===92?t+=`\\\\`:e>=32&&e<=126?t+=String.fromCharCode(e):t+=`\\`+e.toString(8).padStart(3,`0`),r++}return t+=`"`,t}var bc={includeIndex:!0,includeUnderline:!0,includeFileHeaders:!0};function xc(e,t,n,r,i,a,o){let s;s=o?typeof o==`function`?{callback:o}:o:{},s.context===void 0&&(s.context=4);let c=s.context;if(s.newlineIsToken)throw Error(`newlineIsToken may not be used with patch-generation functions, only with diffing functions`);if(s.callback){let{callback:e}=s;mc(n,r,Object.assign(Object.assign({},s),{callback:t=>{e(l(t))}}))}else return l(mc(n,r,s));function l(n){if(!n)return;n.push({value:``,lines:[]});function r(e){return e.map(function(e){return` `+e})}let o=[],s=0,l=0,u=[],d=1,f=1;for(let e=0;e<n.length;e++){let t=n[e],i=t.lines||wc(t.value);if(t.lines=i,t.added||t.removed){if(!s){let t=n[e-1];s=d,l=f,t&&(u=c>0?r(t.lines.slice(-c)):[],s-=u.length,l-=u.length)}for(let e of i)u.push((t.added?`+`:`-`)+e);t.added?f+=i.length:d+=i.length}else{if(s)if(i.length<=c*2&&e<n.length-2)for(let e of r(i))u.push(e);else{let e=Math.min(i.length,c);for(let t of r(i.slice(0,e)))u.push(t);let t={oldStart:s,oldLines:d-s+e,newStart:l,newLines:f-l+e,lines:u};o.push(t),s=0,l=0,u=[]}d+=i.length,f+=i.length}}for(let e of o)for(let t=0;t<e.lines.length;t++)e.lines[t].endsWith(`
1408
+ `)?e.lines[t]=e.lines[t].slice(0,-1):(e.lines.splice(t+1,0,`\`),t++);return{oldFileName:e,newFileName:t,oldHeader:i,newHeader:a,hunks:o}}}function Sc(e,t){if(t||=bc,Array.isArray(e)){if(e.length>1&&!t.includeFileHeaders&&!e.every(e=>e.isGit))throw Error(`Cannot omit file headers on a multi-file patch. (The result would be unparseable; how would a tool trying to apply the patch know which changes are to which file?)`);return e.map(e=>Sc(e,t)).join(`
1409
+ `)}let n=[];if(e.isGit){if(t=bc,!e.oldFileName)throw Error(`oldFileName must be specified for Git patches`);if(!e.newFileName)throw Error(`newFileName must be specified for Git patches`);let r=e.oldFileName,i=e.newFileName;e.isCreate&&r===`/dev/null`?r=i.replace(/^b\//,`a/`):e.isDelete&&i===`/dev/null`&&(i=r.replace(/^a\//,`b/`)),n.push(`diff --git `+yc(r)+` `+yc(i)),e.isDelete&&n.push(`deleted file mode `+(e.oldMode??`100644`)),e.isCreate&&n.push(`new file mode `+(e.newMode??`100644`)),e.oldMode&&e.newMode&&!e.isDelete&&!e.isCreate&&(n.push(`old mode `+e.oldMode),n.push(`new mode `+e.newMode)),e.isRename&&(n.push(`rename from `+yc((e.oldFileName??``).replace(/^a\//,``))),n.push(`rename to `+yc((e.newFileName??``).replace(/^b\//,``)))),e.isCopy&&(n.push(`copy from `+yc((e.oldFileName??``).replace(/^a\//,``))),n.push(`copy to `+yc((e.newFileName??``).replace(/^b\//,``))))}else t.includeIndex&&e.oldFileName==e.newFileName&&e.oldFileName!==void 0&&n.push(`Index: `+e.oldFileName),t.includeUnderline&&n.push(`===================================================================`);let r=e.hunks.length>0;t.includeFileHeaders&&e.oldFileName!==void 0&&e.newFileName!==void 0&&(!e.isGit||r)&&(n.push(`--- `+yc(e.oldFileName)+(e.oldHeader?` `+e.oldHeader:``)),n.push(`+++ `+yc(e.newFileName)+(e.newHeader?` `+e.newHeader:``)));for(let t=0;t<e.hunks.length;t++){let r=e.hunks[t],i=r.oldLines===0?r.oldStart-1:r.oldStart,a=r.newLines===0?r.newStart-1:r.newStart;n.push(`@@ -`+i+`,`+r.oldLines+` +`+a+`,`+r.newLines+` @@`);for(let e of r.lines)n.push(e)}return n.join(`
1410
+ `)+`
1411
+ `}function Cc(e,t,n,r,i,a,o){if(typeof o==`function`&&(o={callback:o}),o?.callback){let{callback:s}=o;xc(e,t,n,r,i,a,Object.assign(Object.assign({},o),{callback:e=>{s(e?Sc(e,o.headerOptions):void 0)}}))}else{let s=xc(e,t,n,r,i,a,o);return s?Sc(s,o?.headerOptions):void 0}}function wc(e){let t=e.endsWith(`
1412
+ `),n=e.split(`
1413
+ `).map(e=>e+`
1414
+ `);return t?n.pop():n.push(n.pop().slice(0,-1)),n}function Tc(e,t,n,r=!1){let i=ui(Cc(e.name,t.name,e.contents,t.contents,e.header,t.header,n),{cacheKey:(()=>{if(e.cacheKey!=null&&t.cacheKey!=null)return`${e.cacheKey}:${t.cacheKey}`})(),oldFile:e,newFile:t,throwOnError:r});if(i==null)throw Error(`parseDiffFrom: FileInvalid diff -- probably need to fix something -- if the files are the same maybe?`);return t.lang!=null&&(i.lang=t.lang),i}var Ec=class{isDeletionsScrolling=!1;isAdditionsScrolling=!1;timeoutId=-1;codeDeletions;codeAdditions;enabled=!1;cleanUp(){this.enabled&&=(this.codeDeletions?.removeEventListener(`scroll`,this.handleDeletionsScroll),this.codeAdditions?.removeEventListener(`scroll`,this.handleAdditionsScroll),clearTimeout(this.timeoutId),this.codeDeletions=void 0,this.codeAdditions=void 0,!1)}setup(e,t,n){if(t==null||n==null)for(let r of e.children??[])r instanceof HTMLElement&&(`deletions`in r.dataset?t=r:`additions`in r.dataset&&(n=r));if(n==null||t==null){this.cleanUp();return}this.codeDeletions!==t&&(this.codeDeletions?.removeEventListener(`scroll`,this.handleDeletionsScroll),this.codeDeletions=t,t.addEventListener(`scroll`,this.handleDeletionsScroll,{passive:!0})),this.codeAdditions!==n&&(this.codeAdditions?.removeEventListener(`scroll`,this.handleAdditionsScroll),this.codeAdditions=n,n.addEventListener(`scroll`,this.handleAdditionsScroll,{passive:!0})),this.enabled=!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}))}},Dc=new Map,Oc={"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`,jbuilder:`ruby`,builder:`ruby`,rabl:`ruby`,arb:`ruby`,ru:`ruby`,podspec:`ruby`,Gemfile:`ruby`,Rakefile:`ruby`,Guardfile:`ruby`,Capfile:`ruby`,Berksfile:`ruby`,Brewfile:`ruby`,Vagrantfile:`ruby`,Thorfile:`ruby`,Appraisals:`ruby`,Dangerfile:`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 kc(e){if(Dc.has(e))return Dc.get(e)??`text`;if(Oc[e]!=null)return Oc[e];let t=e.match(/\.([^/\\]+\.[^/\\]+)$/);if(t!=null){if(Dc.has(t[1]))return Dc.get(t[1])??`text`;if(Oc[t[1]]!=null)return Oc[t[1]]??`text`}let n=e.match(/\.([^.]+)$/)?.[1]??``;return Dc.has(n)?Dc.get(n)??`text`:Oc[n]??`text`}function Ac(e){let t=e.lang??kc(e.name),n=e.lang??(e.prevName==null?`text`:kc(e.prevName));return t===`text`&&n===`text`}function jc(e){let t=e[0];return t!=null&&t.length>0?t:void 0}function Mc(e){return e.startingLine===0&&e.totalLines>0}var Nc=new Map,Pc=new Map,Fc=new Map,Ic=new Set;function Lc(e){for(let t of Array.isArray(e)?e:[e])if(!(t===`text`||t===`ansi`)&&!Ic.has(t))return!1;return!0}function Rc(e,t){e=Array.isArray(e)?e:[e];for(let n of e){if(Ic.has(n.name))continue;let e=Nc.get(n.name);e??(e=n,Nc.set(n.name,e)),Ic.add(e.name),t.loadLanguageSync(e.data)}}function zc(){return typeof WorkerGlobalScope<`u`&&typeof self<`u`&&self instanceof WorkerGlobalScope}var Bc=`modulepreload`,Vc=function(e){return`/`+e},Hc={},G=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e=document.getElementsByTagName(`link`),i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}function s(e){return import.meta.resolve?import.meta.resolve(e):new URL(e,new URL(`../../../src/node/plugins/importAnalysisBuild.ts`,import.meta.url)).href}r=o(t.map(t=>{if(t=Vc(t,n),t=s(t),t in Hc)return;Hc[t]=!0;let r=t.endsWith(`.css`);for(let n=e.length-1;n>=0;n--){let i=e[n];if(i.href===t&&(!r||i.rel===`stylesheet`))return}let i=document.createElement(`link`);if(i.rel=r?`stylesheet`:Bc,r||(i.as=`script`),i.crossOrigin=``,i.href=t,a&&i.setAttribute(`nonce`,a),document.head.appendChild(i),r)return new Promise((e,n)=>{i.addEventListener(`load`,e),i.addEventListener(`error`,()=>n(Error(`Unable to preload CSS for ${t}`)))})}))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},Uc=[{id:`abap`,name:`ABAP`,import:(()=>G(()=>import(`./abap-CLvhMVsD.js`),[]))},{id:`actionscript-3`,name:`ActionScript`,import:(()=>G(()=>import(`./actionscript-3--17pq3dv.js`),[]))},{id:`ada`,name:`Ada`,import:(()=>G(()=>import(`./ada-C5qYipkI.js`),[]))},{id:`angular-html`,name:`Angular HTML`,import:(()=>G(()=>import(`./angular-html-CNvA1zuH.js`).then(e=>e.n),__vite__mapDeps([0,1,2,3])))},{id:`angular-ts`,name:`Angular TypeScript`,import:(()=>G(()=>import(`./angular-ts-Dcg1rXQO.js`),__vite__mapDeps([4,0,1,2,3,5])))},{id:`apache`,name:`Apache Conf`,import:(()=>G(()=>import(`./apache-U0d_L8uA.js`),[]))},{id:`apex`,name:`Apex`,import:(()=>G(()=>import(`./apex-VAyPSnFM.js`),[]))},{id:`apl`,name:`APL`,import:(()=>G(()=>import(`./apl-BYz5Hf2u.js`),__vite__mapDeps([6,2,3,1,7,8,9])))},{id:`applescript`,name:`AppleScript`,import:(()=>G(()=>import(`./applescript-CCn79oCD.js`),[]))},{id:`ara`,name:`Ara`,import:(()=>G(()=>import(`./ara-4CJ0cIlV.js`),[]))},{id:`asciidoc`,name:`AsciiDoc`,aliases:[`adoc`],import:(()=>G(()=>import(`./asciidoc-DE70LPWp.js`),[]))},{id:`asm`,name:`Assembly`,import:(()=>G(()=>import(`./asm-Cmm7eHzH.js`),[]))},{id:`astro`,name:`Astro`,import:(()=>G(()=>import(`./astro-BNmm5iKB.js`),__vite__mapDeps([10,2,3,9,11,12,13])))},{id:`awk`,name:`AWK`,import:(()=>G(()=>import(`./awk-BWXHIvNe.js`),[]))},{id:`ballerina`,name:`Ballerina`,import:(()=>G(()=>import(`./ballerina-B7ZEbQpA.js`),[]))},{id:`bat`,name:`Batch File`,aliases:[`batch`],import:(()=>G(()=>import(`./bat-Bo4NYOV-.js`),[]))},{id:`beancount`,name:`Beancount`,import:(()=>G(()=>import(`./beancount-D-usSTwE.js`),[]))},{id:`berry`,name:`Berry`,aliases:[`be`],import:(()=>G(()=>import(`./berry-DKpUyyne.js`),[]))},{id:`bibtex`,name:`BibTeX`,import:(()=>G(()=>import(`./bibtex-Ci_nEsc7.js`),[]))},{id:`bicep`,name:`Bicep`,import:(()=>G(()=>import(`./bicep-CUHmPFLl.js`),[]))},{id:`bird2`,name:`BIRD2 Configuration`,aliases:[`bird`],import:(()=>G(()=>import(`./bird2-C6vDhewU.js`),[]))},{id:`blade`,name:`Blade`,import:(()=>G(()=>import(`./blade-DTAhJcAo.js`),__vite__mapDeps([14,2,3,1,7,8,9,15,16])))},{id:`bsl`,name:`1C (Enterprise)`,aliases:[`1c`],import:(()=>G(()=>import(`./bsl-BkkzgIyY.js`),__vite__mapDeps([17,18])))},{id:`c`,name:`C`,import:(()=>G(()=>import(`./c-JnETbbKh.js`).then(e=>e.n),[]))},{id:`c3`,name:`C3`,import:(()=>G(()=>import(`./c3-BFHwR3_K.js`),[]))},{id:`cadence`,name:`Cadence`,aliases:[`cdc`],import:(()=>G(()=>import(`./cadence-CQ2zXKGN.js`),[]))},{id:`cairo`,name:`Cairo`,import:(()=>G(()=>import(`./cairo-DLTphjLi.js`),__vite__mapDeps([19,20])))},{id:`clarity`,name:`Clarity`,import:(()=>G(()=>import(`./clarity-SemFz856.js`),[]))},{id:`clojure`,name:`Clojure`,aliases:[`clj`],import:(()=>G(()=>import(`./clojure-DqKBuwfJ.js`),[]))},{id:`cmake`,name:`CMake`,import:(()=>G(()=>import(`./cmake-Bj61d0ZC.js`),[]))},{id:`cobol`,name:`COBOL`,import:(()=>G(()=>import(`./cobol-Dx8Ds744.js`),__vite__mapDeps([21,1,2,3,8])))},{id:`codeowners`,name:`CODEOWNERS`,import:(()=>G(()=>import(`./codeowners-C8r90Shi.js`),[]))},{id:`codeql`,name:`CodeQL`,aliases:[`ql`],import:(()=>G(()=>import(`./codeql-oeQT6MSM.js`),[]))},{id:`coffee`,name:`CoffeeScript`,aliases:[`coffeescript`],import:(()=>G(()=>import(`./coffee-BkM4PUni.js`),__vite__mapDeps([22,2])))},{id:`common-lisp`,name:`Common Lisp`,aliases:[`lisp`],import:(()=>G(()=>import(`./common-lisp-Cv5bFMCO.js`),[]))},{id:`coq`,name:`Coq`,import:(()=>G(()=>import(`./coq-BrsZFFmf.js`),[]))},{id:`cpp`,name:`C++`,aliases:[`c++`],import:(()=>G(()=>import(`./cpp-s7_JoZay.js`).then(e=>e.n),__vite__mapDeps([23,16,24,25,26])))},{id:`crystal`,name:`Crystal`,import:(()=>G(()=>import(`./crystal-TjVXravD.js`),__vite__mapDeps([27,2,3,1,16,26,28])))},{id:`csharp`,name:`C#`,aliases:[`c#`,`cs`],import:(()=>G(()=>import(`./csharp-oqKa8noW.js`),[]))},{id:`css`,name:`CSS`,import:(()=>G(()=>import(`./css-rsgUYxyr.js`).then(e=>e.n),[]))},{id:`csv`,name:`CSV`,import:(()=>G(()=>import(`./csv-Dx-8-gkx.js`),[]))},{id:`cue`,name:`CUE`,import:(()=>G(()=>import(`./cue-CE9AQfxI.js`),[]))},{id:`cypher`,name:`Cypher`,aliases:[`cql`],import:(()=>G(()=>import(`./cypher-ClKdZ_lG.js`),[]))},{id:`d`,name:`D`,import:(()=>G(()=>import(`./d-qD-0Kul2.js`),[]))},{id:`dart`,name:`Dart`,import:(()=>G(()=>import(`./dart-CnvKMtbv.js`),[]))},{id:`dax`,name:`DAX`,import:(()=>G(()=>import(`./dax-BkyTk9wS.js`),[]))},{id:`desktop`,name:`Desktop`,import:(()=>G(()=>import(`./desktop-Dlh5hvp9.js`),[]))},{id:`diff`,name:`Diff`,import:(()=>G(()=>import(`./diff-woXpYk--.js`),[]))},{id:`docker`,name:`Dockerfile`,aliases:[`dockerfile`],import:(()=>G(()=>import(`./docker-IyjqRm3v.js`),[]))},{id:`dotenv`,name:`dotEnv`,import:(()=>G(()=>import(`./dotenv-_5a1GRtc.js`),[]))},{id:`dream-maker`,name:`Dream Maker`,import:(()=>G(()=>import(`./dream-maker-DW3nJb8Q.js`),[]))},{id:`edge`,name:`Edge`,import:(()=>G(()=>import(`./edge-_LaVreSG.js`),__vite__mapDeps([29,1,2,3,11,15])))},{id:`elixir`,name:`Elixir`,import:(()=>G(()=>import(`./elixir-CyNdviVP.js`),__vite__mapDeps([30,1,2,3])))},{id:`elm`,name:`Elm`,import:(()=>G(()=>import(`./elm-JLPHqmtW.js`),__vite__mapDeps([31,25,26])))},{id:`emacs-lisp`,name:`Emacs Lisp`,aliases:[`elisp`],import:(()=>G(()=>import(`./emacs-lisp-B4R74twV.js`),[]))},{id:`erb`,name:`ERB`,import:(()=>G(()=>import(`./erb-BxPqG309.js`),__vite__mapDeps([32,1,2,3,33,7,8,16,26,23,24,25,28,34,35,11,13,36,37,38])))},{id:`erlang`,name:`Erlang`,aliases:[`erl`],import:(()=>G(()=>import(`./erlang-Cphh6RMH.js`),__vite__mapDeps([39,40])))},{id:`fennel`,name:`Fennel`,import:(()=>G(()=>import(`./fennel-DQxkIbk2.js`),[]))},{id:`fish`,name:`Fish`,import:(()=>G(()=>import(`./fish-BJitypiv.js`),[]))},{id:`fluent`,name:`Fluent`,aliases:[`ftl`],import:(()=>G(()=>import(`./fluent-C03EYrpw.js`),[]))},{id:`fortran-fixed-form`,name:`Fortran (Fixed Form)`,aliases:[`f`,`for`,`f77`],import:(()=>G(()=>import(`./fortran-fixed-form-DEKoE2YW.js`),__vite__mapDeps([41,42])))},{id:`fortran-free-form`,name:`Fortran (Free Form)`,aliases:[`f90`,`f95`,`f03`,`f08`,`f18`],import:(()=>G(()=>import(`./fortran-free-form-CYNrtFtB.js`),[]))},{id:`fsharp`,name:`F#`,aliases:[`f#`,`fs`],import:(()=>G(()=>import(`./fsharp-D13ZGOAj.js`),__vite__mapDeps([43,40])))},{id:`gdresource`,name:`GDResource`,aliases:[`tscn`,`tres`],import:(()=>G(()=>import(`./gdresource-C0sCabJj.js`),__vite__mapDeps([44,45,46])))},{id:`gdscript`,name:`GDScript`,aliases:[`gd`],import:(()=>G(()=>import(`./gdscript-Cp2uCuqX.js`),[]))},{id:`gdshader`,name:`GDShader`,import:(()=>G(()=>import(`./gdshader-CBce3t8t.js`),[]))},{id:`genie`,name:`Genie`,import:(()=>G(()=>import(`./genie-CV2tkWYe.js`),[]))},{id:`gherkin`,name:`Gherkin`,import:(()=>G(()=>import(`./gherkin-DExj1W_8.js`),[]))},{id:`git-commit`,name:`Git Commit Message`,import:(()=>G(()=>import(`./git-commit-BSykSTBG.js`),__vite__mapDeps([47,48])))},{id:`git-rebase`,name:`Git Rebase Message`,import:(()=>G(()=>import(`./git-rebase-DH0tcug9.js`),__vite__mapDeps([49,28])))},{id:`gleam`,name:`Gleam`,import:(()=>G(()=>import(`./gleam-CSRkHgEL.js`),[]))},{id:`glimmer-js`,name:`Glimmer JS`,aliases:[`gjs`],import:(()=>G(()=>import(`./glimmer-js-CadjWt9T.js`),__vite__mapDeps([50,2,3,1,11])))},{id:`glimmer-ts`,name:`Glimmer TS`,aliases:[`gts`],import:(()=>G(()=>import(`./glimmer-ts-BQwOnUiC.js`),__vite__mapDeps([51,2,3,1,11])))},{id:`glsl`,name:`GLSL`,import:(()=>G(()=>import(`./glsl-DgEkB9wq.js`).then(e=>e.n),__vite__mapDeps([25,26])))},{id:`gn`,name:`GN`,import:(()=>G(()=>import(`./gn-ilITqXS6.js`),[]))},{id:`gnuplot`,name:`Gnuplot`,import:(()=>G(()=>import(`./gnuplot-7GGW24-e.js`),[]))},{id:`go`,name:`Go`,import:(()=>G(()=>import(`./go-rLFTqkRN.js`),[]))},{id:`graphql`,name:`GraphQL`,aliases:[`gql`],import:(()=>G(()=>import(`./graphql-CkxNJin1.js`).then(e=>e.n),__vite__mapDeps([35,2,11,13,36])))},{id:`groovy`,name:`Groovy`,import:(()=>G(()=>import(`./groovy-CacY0gHj.js`),[]))},{id:`hack`,name:`Hack`,import:(()=>G(()=>import(`./hack-Cx2aeoPG.js`),__vite__mapDeps([52,1,2,3,16])))},{id:`haml`,name:`Ruby Haml`,import:(()=>G(()=>import(`./haml-6qfsyyuG.js`).then(e=>e.n),__vite__mapDeps([34,2,3])))},{id:`handlebars`,name:`Handlebars`,aliases:[`hbs`],import:(()=>G(()=>import(`./handlebars-Dl2NJIlT.js`),__vite__mapDeps([53,2,3,1,38])))},{id:`haskell`,name:`Haskell`,aliases:[`hs`],import:(()=>G(()=>import(`./haskell-D8IpX4py.js`),[]))},{id:`haxe`,name:`Haxe`,import:(()=>G(()=>import(`./haxe-OTjmBuCE.js`),[]))},{id:`hcl`,name:`HashiCorp HCL`,import:(()=>G(()=>import(`./hcl-Dh228itO.js`),[]))},{id:`hjson`,name:`Hjson`,import:(()=>G(()=>import(`./hjson-CxZEssPk.js`),[]))},{id:`hlsl`,name:`HLSL`,import:(()=>G(()=>import(`./hlsl-Cvrh5tZx.js`),[]))},{id:`html`,name:`HTML`,import:(()=>G(()=>import(`./html-D1zwS_Y6.js`).then(e=>e.n),__vite__mapDeps([1,2,3])))},{id:`html-derivative`,name:`HTML (Derivative)`,import:(()=>G(()=>import(`./html-derivative-JnsLWsez.js`),__vite__mapDeps([15,1,2,3])))},{id:`http`,name:`HTTP`,import:(()=>G(()=>import(`./http-OKR1Yox5.js`),__vite__mapDeps([54,7,8,9,28,35,2,11,13,36])))},{id:`hurl`,name:`Hurl`,import:(()=>G(()=>import(`./hurl-Dp_r9svp.js`),__vite__mapDeps([55,7,8,56,35,2,11,13,36])))},{id:`hxml`,name:`HXML`,import:(()=>G(()=>import(`./hxml-B0Qn7Nwc.js`),__vite__mapDeps([57,58])))},{id:`hy`,name:`Hy`,import:(()=>G(()=>import(`./hy-CZbG8q4J.js`),[]))},{id:`imba`,name:`Imba`,import:(()=>G(()=>import(`./imba-DsUTQ-LC.js`),[]))},{id:`ini`,name:`INI`,aliases:[`properties`],import:(()=>G(()=>import(`./ini-B5eOa1yu.js`),[]))},{id:`java`,name:`Java`,import:(()=>G(()=>import(`./java-aami8pBq.js`).then(e=>e.n),[]))},{id:`javascript`,name:`JavaScript`,aliases:[`js`,`cjs`,`mjs`],import:(()=>G(()=>import(`./javascript-BPWrhnX-.js`).then(e=>e.n),[]))},{id:`jinja`,name:`Jinja`,import:(()=>G(()=>import(`./jinja-C6if9zLU.js`),__vite__mapDeps([59,1,2,3])))},{id:`jison`,name:`Jison`,import:(()=>G(()=>import(`./jison-7oFp1xmT.js`),__vite__mapDeps([60,2])))},{id:`json`,name:`JSON`,import:(()=>G(()=>import(`./json-NWlrVqIA.js`).then(e=>e.n),[]))},{id:`json5`,name:`JSON5`,import:(()=>G(()=>import(`./json5-BR5RXkoi.js`),[]))},{id:`jsonc`,name:`JSON with Comments`,import:(()=>G(()=>import(`./jsonc-CYpm1nAK.js`),[]))},{id:`jsonl`,name:`JSON Lines`,import:(()=>G(()=>import(`./jsonl-CmCQp5Yx.js`),[]))},{id:`jsonnet`,name:`Jsonnet`,import:(()=>G(()=>import(`./jsonnet-CJTPZ8u_.js`),[]))},{id:`jssm`,name:`JSSM`,aliases:[`fsl`],import:(()=>G(()=>import(`./jssm-DXw9l8Rf.js`),[]))},{id:`jsx`,name:`JSX`,import:(()=>G(()=>import(`./jsx-BarzqCx-.js`).then(e=>e.n),[]))},{id:`julia`,name:`Julia`,aliases:[`jl`],import:(()=>G(()=>import(`./julia-Dno5JaFH.js`),__vite__mapDeps([61,2,16,20,23,24,25,26,62])))},{id:`just`,name:`Just`,import:(()=>G(()=>import(`./just-CMC5pFEz.js`),__vite__mapDeps([63,2,11,20,28,33,3,1,7,8,16,26,23,24,25,34,35,13,36,37,38,64])))},{id:`kdl`,name:`KDL`,import:(()=>G(()=>import(`./kdl-CsD5j6eV.js`),[]))},{id:`kotlin`,name:`Kotlin`,aliases:[`kt`,`kts`],import:(()=>G(()=>import(`./kotlin-DhhofPvG.js`),[]))},{id:`kusto`,name:`Kusto`,aliases:[`kql`],import:(()=>G(()=>import(`./kusto-C7mF5XQf.js`),[]))},{id:`latex`,name:`LaTeX`,import:(()=>G(()=>import(`./latex-CrkA4r_Y.js`),__vite__mapDeps([65,66,62])))},{id:`lean`,name:`Lean 4`,aliases:[`lean4`],import:(()=>G(()=>import(`./lean-CewbzKMR.js`),[]))},{id:`less`,name:`Less`,import:(()=>G(()=>import(`./less-DVTAwKKz.js`),[]))},{id:`liquid`,name:`Liquid`,import:(()=>G(()=>import(`./liquid-CEefn5av.js`),__vite__mapDeps([67,2,3,1,9])))},{id:`llvm`,name:`LLVM IR`,import:(()=>G(()=>import(`./llvm-Cm23YOpf.js`),[]))},{id:`log`,name:`Log file`,import:(()=>G(()=>import(`./log-BNLmms1o.js`),[]))},{id:`logo`,name:`Logo`,import:(()=>G(()=>import(`./logo-Cluzi2Zq.js`),[]))},{id:`lua`,name:`Lua`,import:(()=>G(()=>import(`./lua-D2x5jth8.js`).then(e=>e.n),__vite__mapDeps([37,26])))},{id:`luau`,name:`Luau`,import:(()=>G(()=>import(`./luau-FMPmPwt6.js`),[]))},{id:`make`,name:`Makefile`,aliases:[`makefile`],import:(()=>G(()=>import(`./make-Dixweg8N.js`),[]))},{id:`markdown`,name:`Markdown`,aliases:[`md`],import:(()=>G(()=>import(`./markdown-BYOwaDjH.js`),[]))},{id:`marko`,name:`Marko`,import:(()=>G(()=>import(`./marko-Bg0EO4kh.js`),__vite__mapDeps([68,3,5,11,69])))},{id:`matlab`,name:`MATLAB`,import:(()=>G(()=>import(`./matlab-D7qyCx1q.js`),[]))},{id:`mdc`,name:`MDC`,import:(()=>G(()=>import(`./mdc-LycNcJIc.js`),__vite__mapDeps([70,15,1,2,3,38,40])))},{id:`mdx`,name:`MDX`,import:(()=>G(()=>import(`./mdx-DQZ5AkYe.js`),[]))},{id:`mermaid`,name:`Mermaid`,aliases:[`mmd`],import:(()=>G(()=>import(`./mermaid-Bk4SNUv9.js`),[]))},{id:`mipsasm`,name:`MIPS Assembly`,aliases:[`mips`],import:(()=>G(()=>import(`./mipsasm-BMqwQI7S.js`),[]))},{id:`mojo`,name:`Mojo`,import:(()=>G(()=>import(`./mojo-BgCJLMeH.js`),[]))},{id:`moonbit`,name:`MoonBit`,aliases:[`mbt`,`mbti`],import:(()=>G(()=>import(`./moonbit-CaWjb8XO.js`),[]))},{id:`move`,name:`Move`,import:(()=>G(()=>import(`./move-B1IS1UjX.js`),[]))},{id:`narrat`,name:`Narrat Language`,aliases:[`nar`],import:(()=>G(()=>import(`./narrat-_X_XdTYD.js`),[]))},{id:`nextflow`,name:`Nextflow`,aliases:[`nf`],import:(()=>G(()=>import(`./nextflow-BJtWHP5T.js`),__vite__mapDeps([71,72])))},{id:`nextflow-groovy`,name:`Nextflow Groovy`,import:(()=>G(()=>import(`./nextflow-groovy-DJMQeKeT.js`),[]))},{id:`nginx`,name:`Nginx`,import:(()=>G(()=>import(`./nginx-BXD3-aNx.js`),__vite__mapDeps([73,37,26])))},{id:`nim`,name:`Nim`,import:(()=>G(()=>import(`./nim-CVCKLhAN.js`),__vite__mapDeps([74,2,3,1,7,8,26,25,40])))},{id:`nix`,name:`Nix`,import:(()=>G(()=>import(`./nix-IvuFDN5E.js`),[]))},{id:`nushell`,name:`nushell`,aliases:[`nu`],import:(()=>G(()=>import(`./nushell-DcLAeLz5.js`),[]))},{id:`objective-c`,name:`Objective-C`,aliases:[`objc`],import:(()=>G(()=>import(`./objective-c-D1A_Heim.js`),[]))},{id:`objective-cpp`,name:`Objective-C++`,import:(()=>G(()=>import(`./objective-cpp-BsSzOQcm.js`),[]))},{id:`ocaml`,name:`OCaml`,import:(()=>G(()=>import(`./ocaml-O90oeIOV.js`),[]))},{id:`odin`,name:`Odin`,import:(()=>G(()=>import(`./odin-B1RWQWA5.js`),[]))},{id:`openscad`,name:`OpenSCAD`,aliases:[`scad`],import:(()=>G(()=>import(`./openscad-BUDT5pXO.js`),[]))},{id:`pascal`,name:`Pascal`,import:(()=>G(()=>import(`./pascal-4ZHwLPI5.js`),[]))},{id:`perl`,name:`Perl`,import:(()=>G(()=>import(`./perl-BBOoylGj.js`),__vite__mapDeps([64,2,3,1,7,8,16])))},{id:`php`,name:`PHP`,import:(()=>G(()=>import(`./php-DC7DWNj0.js`),__vite__mapDeps([75,2,3,1,7,8,9,16])))},{id:`pkl`,name:`Pkl`,import:(()=>G(()=>import(`./pkl-ot-7Btpt.js`),[]))},{id:`plsql`,name:`PL/SQL`,import:(()=>G(()=>import(`./plsql-DGHpHOYJ.js`),[]))},{id:`po`,name:`Gettext PO`,aliases:[`pot`,`potx`],import:(()=>G(()=>import(`./po-BiJDBrnU.js`),[]))},{id:`polar`,name:`Polar`,import:(()=>G(()=>import(`./polar-C7UOKdEL.js`),[]))},{id:`postcss`,name:`PostCSS`,import:(()=>G(()=>import(`./postcss-BXeXVLqQ.js`),[]))},{id:`powerquery`,name:`PowerQuery`,import:(()=>G(()=>import(`./powerquery-DNMTfnFr.js`),[]))},{id:`powershell`,name:`PowerShell`,aliases:[`ps`,`ps1`],import:(()=>G(()=>import(`./powershell-DshXNtvi.js`),[]))},{id:`prisma`,name:`Prisma`,import:(()=>G(()=>import(`./prisma-BsRQq5mF.js`),[]))},{id:`prolog`,name:`Prolog`,import:(()=>G(()=>import(`./prolog-iXnhIJG7.js`),[]))},{id:`proto`,name:`Protocol Buffer 3`,aliases:[`protobuf`],import:(()=>G(()=>import(`./proto-DB4EqR-F.js`),[]))},{id:`pug`,name:`Pug`,aliases:[`jade`],import:(()=>G(()=>import(`./pug-9a4nUMn2.js`),__vite__mapDeps([76,2,3,1])))},{id:`puppet`,name:`Puppet`,import:(()=>G(()=>import(`./puppet-CDv2pdJW.js`),[]))},{id:`purescript`,name:`PureScript`,import:(()=>G(()=>import(`./purescript-9MfHhQsQ.js`),[]))},{id:`python`,name:`Python`,aliases:[`py`],import:(()=>G(()=>import(`./python-gzcpVVnB.js`),[]))},{id:`qml`,name:`QML`,import:(()=>G(()=>import(`./qml-CD7Jztqi.js`),__vite__mapDeps([77,2])))},{id:`qmldir`,name:`QML Directory`,import:(()=>G(()=>import(`./qmldir-DCQb3MpD.js`),[]))},{id:`qss`,name:`Qt Style Sheets`,import:(()=>G(()=>import(`./qss-Fe1Jh2GI.js`),[]))},{id:`r`,name:`R`,import:(()=>G(()=>import(`./r-zQcActoX.js`).then(e=>e.n),[]))},{id:`racket`,name:`Racket`,import:(()=>G(()=>import(`./racket-DcIDlBhZ.js`),[]))},{id:`raku`,name:`Raku`,aliases:[`perl6`],import:(()=>G(()=>import(`./raku-B3gFvitq.js`),[]))},{id:`razor`,name:`ASP.NET Razor`,import:(()=>G(()=>import(`./razor--BGs0ioE.js`),__vite__mapDeps([78,1,2,3,79])))},{id:`reg`,name:`Windows Registry Script`,import:(()=>G(()=>import(`./reg-CRGYupPL.js`),[]))},{id:`regexp`,name:`RegExp`,aliases:[`regex`],import:(()=>G(()=>import(`./regexp-C7E19l_4.js`).then(e=>e.n),[]))},{id:`rel`,name:`Rel`,import:(()=>G(()=>import(`./rel-BtDbiS_P.js`),[]))},{id:`riscv`,name:`RISC-V`,import:(()=>G(()=>import(`./riscv-Ckw8ddFX.js`),[]))},{id:`ron`,name:`RON`,import:(()=>G(()=>import(`./ron-VUp2lXgN.js`),[]))},{id:`rosmsg`,name:`ROS Interface`,import:(()=>G(()=>import(`./rosmsg-CAekHB0j.js`),[]))},{id:`rst`,name:`reStructuredText`,import:(()=>G(()=>import(`./rst-DVAvGLqu.js`),__vite__mapDeps([80,2,15,1,3,20,81,23,16,24,25,26,28,38,33,7,8,34,35,11,13,36,37])))},{id:`ruby`,name:`Ruby`,aliases:[`rb`],import:(()=>G(()=>import(`./ruby-DrWWnDsD.js`),__vite__mapDeps([33,2,3,1,7,8,16,26,23,24,25,28,34,35,11,13,36,37,38])))},{id:`rust`,name:`Rust`,aliases:[`rs`],import:(()=>G(()=>import(`./rust-Cfkwpbl8.js`),[]))},{id:`sas`,name:`SAS`,import:(()=>G(()=>import(`./sas-B0L4vbPF.js`),__vite__mapDeps([82,16])))},{id:`sass`,name:`Sass`,import:(()=>G(()=>import(`./sass-DXrisJhu.js`),[]))},{id:`scala`,name:`Scala`,import:(()=>G(()=>import(`./scala-DKOlJaKm.js`),[]))},{id:`scheme`,name:`Scheme`,import:(()=>G(()=>import(`./scheme-DQCgrYNe.js`),[]))},{id:`scss`,name:`SCSS`,import:(()=>G(()=>import(`./scss-LHue-ciZ.js`).then(e=>e.n),__vite__mapDeps([5,3])))},{id:`sdbl`,name:`1C (Query)`,aliases:[`1c-query`],import:(()=>G(()=>import(`./sdbl-bTVj8UrX.js`),[]))},{id:`shaderlab`,name:`ShaderLab`,aliases:[`shader`],import:(()=>G(()=>import(`./shaderlab-TOUzSsQk.js`),__vite__mapDeps([83,84])))},{id:`shellscript`,name:`Shell`,aliases:[`bash`,`sh`,`shell`,`zsh`],import:(()=>G(()=>import(`./shellscript-COL3-ob8.js`).then(e=>e.n),[]))},{id:`shellsession`,name:`Shell Session`,aliases:[`console`],import:(()=>G(()=>import(`./shellsession-Dh9ePmCl.js`),__vite__mapDeps([85,28])))},{id:`smalltalk`,name:`Smalltalk`,import:(()=>G(()=>import(`./smalltalk-B16xEiuN.js`),[]))},{id:`solidity`,name:`Solidity`,import:(()=>G(()=>import(`./solidity-CKzVLygQ.js`),[]))},{id:`soy`,name:`Closure Templates`,aliases:[`closure-templates`],import:(()=>G(()=>import(`./soy-BXy9DlYu.js`),__vite__mapDeps([86,1,2,3])))},{id:`sparql`,name:`SPARQL`,import:(()=>G(()=>import(`./sparql-D_iOobhT.js`),__vite__mapDeps([87,88])))},{id:`splunk`,name:`Splunk Query Language`,aliases:[`spl`],import:(()=>G(()=>import(`./splunk-BC2Px7Mm.js`),[]))},{id:`sql`,name:`SQL`,import:(()=>G(()=>import(`./sql-I-LlvQU6.js`).then(e=>e.n),[]))},{id:`ssh-config`,name:`SSH Config`,import:(()=>G(()=>import(`./ssh-config-BgfXC-Er.js`),[]))},{id:`stata`,name:`Stata`,import:(()=>G(()=>import(`./stata-_NdjQJlR.js`),__vite__mapDeps([89,16])))},{id:`stylus`,name:`Stylus`,aliases:[`styl`],import:(()=>G(()=>import(`./stylus-B6D30XZt.js`),[]))},{id:`surrealql`,name:`SurrealQL`,aliases:[`surql`],import:(()=>G(()=>import(`./surrealql-KFhJ-vKU.js`),__vite__mapDeps([90,2])))},{id:`svelte`,name:`Svelte`,import:(()=>G(()=>import(`./svelte-BzRTBlZL.js`),__vite__mapDeps([91,2,3,11,12])))},{id:`swift`,name:`Swift`,import:(()=>G(()=>import(`./swift-DonLKvLd.js`),[]))},{id:`system-verilog`,name:`SystemVerilog`,import:(()=>G(()=>import(`./system-verilog-DJ5XKQeo.js`),[]))},{id:`systemd`,name:`Systemd Units`,import:(()=>G(()=>import(`./systemd-BxMlprV5.js`),[]))},{id:`talonscript`,name:`TalonScript`,aliases:[`talon`],import:(()=>G(()=>import(`./talonscript-CohzipZa.js`),[]))},{id:`tasl`,name:`Tasl`,import:(()=>G(()=>import(`./tasl-DMoTqEGO.js`),[]))},{id:`tcl`,name:`Tcl`,import:(()=>G(()=>import(`./tcl-CZd0xW_V.js`),[]))},{id:`templ`,name:`Templ`,import:(()=>G(()=>import(`./templ-wEb1pleG.js`),__vite__mapDeps([92,2,3,93])))},{id:`terraform`,name:`Terraform`,aliases:[`tf`,`tfvars`],import:(()=>G(()=>import(`./terraform-DswuEJGm.js`),[]))},{id:`tex`,name:`TeX`,import:(()=>G(()=>import(`./tex-6jA6UkGw.js`),__vite__mapDeps([66,62])))},{id:`toml`,name:`TOML`,import:(()=>G(()=>import(`./toml-CcmNWLt0.js`),[]))},{id:`ts-tags`,name:`TypeScript with Tags`,aliases:[`lit`],import:(()=>G(()=>import(`./ts-tags-CL6-c_t0.js`),__vite__mapDeps([94,2,3,1,7,8,11,16,25,26])))},{id:`tsv`,name:`TSV`,import:(()=>G(()=>import(`./tsv-sltzmVWM.js`),[]))},{id:`tsx`,name:`TSX`,import:(()=>G(()=>import(`./tsx-CrJYZX0i.js`).then(e=>e.n),[]))},{id:`turtle`,name:`Turtle`,import:(()=>G(()=>import(`./turtle-ByJddavk.js`),[]))},{id:`twig`,name:`Twig`,import:(()=>G(()=>import(`./twig-BQr0H8S_.js`),__vite__mapDeps([95,2,3,5,20,33,1,7,8,16,26,23,24,25,28,34,35,11,13,36,37,38,75,9])))},{id:`typescript`,name:`TypeScript`,aliases:[`ts`,`cts`,`mts`],import:(()=>G(()=>import(`./typescript-Pf82UNjk.js`).then(e=>e.n),[]))},{id:`typespec`,name:`TypeSpec`,aliases:[`tsp`],import:(()=>G(()=>import(`./typespec-BRdr0IET.js`),[]))},{id:`typst`,name:`Typst`,aliases:[`typ`],import:(()=>G(()=>import(`./typst-DI99ib-x.js`),[]))},{id:`v`,name:`V`,import:(()=>G(()=>import(`./v-DETTlOr0.js`),[]))},{id:`vala`,name:`Vala`,import:(()=>G(()=>import(`./vala-zf12oZj6.js`),[]))},{id:`vb`,name:`Visual Basic`,aliases:[`cmd`],import:(()=>G(()=>import(`./vb-Djn5o6TS.js`),[]))},{id:`verilog`,name:`Verilog`,import:(()=>G(()=>import(`./verilog-CiiDBU1e.js`),[]))},{id:`vhdl`,name:`VHDL`,import:(()=>G(()=>import(`./vhdl-BroJfC0k.js`),[]))},{id:`viml`,name:`Vim Script`,aliases:[`vim`,`vimscript`],import:(()=>G(()=>import(`./viml-DvXPmvsu.js`),[]))},{id:`vue`,name:`Vue`,import:(()=>G(()=>import(`./vue-a0DDumRw.js`),__vite__mapDeps([96,2,3,1,9,11,15])))},{id:`vue-html`,name:`Vue HTML`,import:(()=>G(()=>import(`./vue-html-mS0LX1Q6.js`),__vite__mapDeps([97,2])))},{id:`vue-vine`,name:`Vue Vine`,import:(()=>G(()=>import(`./vue-vine-BuqblR0E.js`),__vite__mapDeps([98,2,3,5,12,69,99])))},{id:`vyper`,name:`Vyper`,aliases:[`vy`],import:(()=>G(()=>import(`./vyper-CgoNMtux.js`),[]))},{id:`wasm`,name:`WebAssembly`,import:(()=>G(()=>import(`./wasm-ByWQv1Qj.js`),[]))},{id:`wenyan`,name:`Wenyan`,aliases:[`文言`],import:(()=>G(()=>import(`./wenyan-C8pVoKbM.js`),[]))},{id:`wgsl`,name:`WGSL`,import:(()=>G(()=>import(`./wgsl-BsKzXJz4.js`),[]))},{id:`wikitext`,name:`Wikitext`,aliases:[`mediawiki`,`wiki`],import:(()=>G(()=>import(`./wikitext-ClFFjSW2.js`),[]))},{id:`wit`,name:`WebAssembly Interface Types`,import:(()=>G(()=>import(`./wit-DdvCle-K.js`),[]))},{id:`wolfram`,name:`Wolfram`,aliases:[`wl`],import:(()=>G(()=>import(`./wolfram-DLL8P-h_.js`),[]))},{id:`xml`,name:`XML`,import:(()=>G(()=>import(`./xml-BCSi99jg.js`).then(e=>e.n),__vite__mapDeps([7,8])))},{id:`xsl`,name:`XSL`,import:(()=>G(()=>import(`./xsl-SABzfGmn.js`),__vite__mapDeps([100,7,8])))},{id:`yaml`,name:`YAML`,aliases:[`yml`],import:(()=>G(()=>import(`./yaml-CT1I4qT1.js`).then(e=>e.n),[]))},{id:`zenscript`,name:`ZenScript`,import:(()=>G(()=>import(`./zenscript-BnlCZFoB.js`),[]))},{id:`zig`,name:`Zig`,import:(()=>G(()=>import(`./zig-CMLA9XwU.js`),[]))}],Wc=Object.fromEntries(Uc.map(e=>[e.id,e.import])),Gc=Object.fromEntries(Uc.flatMap(e=>e.aliases?.map(t=>[t,e.import])||[])),Kc={...Wc,...Gc},qc=Object.defineProperty,Jc=Object.getOwnPropertyDescriptor,Yc=Object.getOwnPropertyNames,Xc=Object.prototype.hasOwnProperty,Zc=(e,t)=>{let n={};for(var r in e)qc(n,r,{get:e[r],enumerable:!0});return t||qc(n,Symbol.toStringTag,{value:`Module`}),n},Qc=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var i=Yc(t),a=0,o=i.length,s;a<o;a++)s=i[a],!Xc.call(e,s)&&s!==n&&qc(e,s,{get:(e=>t[e]).bind(null,s),enumerable:!(r=Jc(t,s))||r.enumerable});return e},$c=(e,t,n)=>(Qc(e,t,`default`),n&&Qc(n,t,`default`)),el=t({createOnigurumaEngine:()=>Ol,getDefaultWasmLoader:()=>Dl,loadWasm:()=>xl,setDefaultWasmLoader:()=>El}),tl=class extends Error{constructor(e){super(e),this.name=`ShikiError`}};function nl(){return 2147483648}function rl(){return typeof performance<`u`?performance.now():Date.now()}var il=(e,t)=>e+(t-e%t)%t;async function al(e){let t,n,r={};function i(e){n=e,r.HEAPU8=new Uint8Array(e),r.HEAPU32=new Uint32Array(e)}function a(e,t,n){r.HEAPU8.copyWithin(e,t,t+n)}function o(e){try{return t.grow(e-n.byteLength+65535>>>16),i(t.buffer),1}catch{}}function s(e){let t=r.HEAPU8.length;e>>>=0;let n=nl();if(e>n)return!1;for(let r=1;r<=4;r*=2){let i=t*(1+.2/r);if(i=Math.min(i,e+100663296),o(Math.min(n,il(Math.max(e,i),65536))))return!0}return!1}let c=typeof TextDecoder<`u`?new TextDecoder(`utf8`):void 0;function l(e,t,n=1024){let r=t+n,i=t;for(;e[i]&&!(i>=r);)++i;if(i-t>16&&e.buffer&&c)return c.decode(e.subarray(t,i));let a=``;for(;t<i;){let n=e[t++];if(!(n&128)){a+=String.fromCharCode(n);continue}let r=e[t++]&63;if((n&224)==192){a+=String.fromCharCode((n&31)<<6|r);continue}let i=e[t++]&63;if(n=(n&240)==224?(n&15)<<12|r<<6|i:(n&7)<<18|r<<12|i<<6|e[t++]&63,n<65536)a+=String.fromCharCode(n);else{let e=n-65536;a+=String.fromCharCode(55296|e>>10,56320|e&1023)}}return a}function u(e,t){return e?l(r.HEAPU8,e,t):``}let d={emscripten_get_now:rl,emscripten_memcpy_big:a,emscripten_resize_heap:s,fd_write:()=>0};async function f(){let n=await e({env:d,wasi_snapshot_preview1:d});t=n.memory,i(t.buffer),Object.assign(r,n),r.UTF8ToString=u}return await f(),r}var ol=Object.defineProperty,sl=(e,t,n)=>t in e?ol(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,cl=(e,t,n)=>sl(e,typeof t==`symbol`?t:t+``,n),ll=null;function ul(e){throw new tl(e.UTF8ToString(e.getLastOnigError()))}var dl=class e{constructor(t){cl(this,`utf16Length`),cl(this,`utf8Length`),cl(this,`utf16Value`),cl(this,`utf8Value`),cl(this,`utf16OffsetToUtf8`),cl(this,`utf8OffsetToUtf16`);let n=t.length,r=e._utf8ByteLength(t),i=r!==n,a=i?new Uint32Array(n+1):null;i&&(a[n]=r);let o=i?new Uint32Array(r+1):null;i&&(o[r]=n);let s=new Uint8Array(r),c=0;for(let e=0;e<n;e++){let r=t.charCodeAt(e),l=r,u=!1;if(r>=55296&&r<=56319&&e+1<n){let n=t.charCodeAt(e+1);n>=56320&&n<=57343&&(l=(r-55296<<10)+65536|n-56320,u=!0)}i&&(a[e]=c,u&&(a[e+1]=c),l<=127?o[c+0]=e:l<=2047?(o[c+0]=e,o[c+1]=e):l<=65535?(o[c+0]=e,o[c+1]=e,o[c+2]=e):(o[c+0]=e,o[c+1]=e,o[c+2]=e,o[c+3]=e)),l<=127?s[c++]=l:l<=2047?(s[c++]=192|(l&1984)>>>6,s[c++]=128|(l&63)>>>0):l<=65535?(s[c++]=224|(l&61440)>>>12,s[c++]=128|(l&4032)>>>6,s[c++]=128|(l&63)>>>0):(s[c++]=240|(l&1835008)>>>18,s[c++]=128|(l&258048)>>>12,s[c++]=128|(l&4032)>>>6,s[c++]=128|(l&63)>>>0),u&&e++}this.utf16Length=n,this.utf8Length=r,this.utf16Value=t,this.utf8Value=s,this.utf16OffsetToUtf8=a,this.utf8OffsetToUtf16=o}static _utf8ByteLength(e){let t=0;for(let n=0,r=e.length;n<r;n++){let i=e.charCodeAt(n),a=i,o=!1;if(i>=55296&&i<=56319&&n+1<r){let t=e.charCodeAt(n+1);t>=56320&&t<=57343&&(a=(i-55296<<10)+65536|t-56320,o=!0)}a<=127?t+=1:a<=2047?t+=2:a<=65535?t+=3:t+=4,o&&n++}return t}createString(e){let t=e.omalloc(this.utf8Length);return e.HEAPU8.set(this.utf8Value,t),t}},fl=class e{constructor(t){if(cl(this,`id`,++e.LAST_ID),cl(this,`_onigBinding`),cl(this,`content`),cl(this,`utf16Length`),cl(this,`utf8Length`),cl(this,`utf16OffsetToUtf8`),cl(this,`utf8OffsetToUtf16`),cl(this,`ptr`),!ll)throw new tl(`Must invoke loadWasm first.`);this._onigBinding=ll,this.content=t;let n=new dl(t);this.utf16Length=n.utf16Length,this.utf8Length=n.utf8Length,this.utf16OffsetToUtf8=n.utf16OffsetToUtf8,this.utf8OffsetToUtf16=n.utf8OffsetToUtf16,this.utf8Length<1e4&&!e._sharedPtrInUse?(e._sharedPtr||=ll.omalloc(1e4),e._sharedPtrInUse=!0,ll.HEAPU8.set(n.utf8Value,e._sharedPtr),this.ptr=e._sharedPtr):this.ptr=n.createString(ll)}convertUtf8OffsetToUtf16(e){return this.utf8OffsetToUtf16?e<0?0:e>this.utf8Length?this.utf16Length:this.utf8OffsetToUtf16[e]:e}convertUtf16OffsetToUtf8(e){return this.utf16OffsetToUtf8?e<0?0:e>this.utf16Length?this.utf8Length:this.utf16OffsetToUtf8[e]:e}dispose(){this.ptr===e._sharedPtr?e._sharedPtrInUse=!1:this._onigBinding.ofree(this.ptr)}};cl(fl,`LAST_ID`,0),cl(fl,`_sharedPtr`,0),cl(fl,`_sharedPtrInUse`,!1);var pl=fl,ml=class{constructor(e){if(cl(this,`_onigBinding`),cl(this,`_ptr`),!ll)throw new tl(`Must invoke loadWasm first.`);let t=[],n=[];for(let r=0,i=e.length;r<i;r++){let i=new dl(e[r]);t[r]=i.createString(ll),n[r]=i.utf8Length}let r=ll.omalloc(4*e.length);ll.HEAPU32.set(t,r/4);let i=ll.omalloc(4*e.length);ll.HEAPU32.set(n,i/4);let a=ll.createOnigScanner(r,i,e.length);for(let n=0,r=e.length;n<r;n++)ll.ofree(t[n]);ll.ofree(i),ll.ofree(r),a===0&&ul(ll),this._onigBinding=ll,this._ptr=a}dispose(){this._onigBinding.freeOnigScanner(this._ptr)}findNextMatchSync(e,t,n){let r=0;if(typeof n==`number`&&(r=n),typeof e==`string`){e=new pl(e);let n=this._findNextMatchSync(e,t,!1,r);return e.dispose(),n}return this._findNextMatchSync(e,t,!1,r)}_findNextMatchSync(e,t,n,r){let i=this._onigBinding,a=i.findNextOnigScannerMatch(this._ptr,e.id,e.ptr,e.utf8Length,e.convertUtf16OffsetToUtf8(t),r);if(a===0)return null;let o=i.HEAPU32,s=a/4,c=o[s++],l=o[s++],u=[];for(let t=0;t<l;t++){let n=e.convertUtf8OffsetToUtf16(o[s++]),r=e.convertUtf8OffsetToUtf16(o[s++]);u[t]={start:n,end:r,length:r-n}}return{index:c,captureIndices:u}}};function hl(e){return typeof e.instantiator==`function`}function gl(e){return typeof e.default==`function`}function _l(e){return e.data!==void 0}function vl(e){return typeof Response<`u`&&e instanceof Response}function yl(e){return typeof ArrayBuffer<`u`&&(e instanceof ArrayBuffer||ArrayBuffer.isView(e))||typeof Buffer<`u`&&Buffer.isBuffer?.(e)||typeof SharedArrayBuffer<`u`&&e instanceof SharedArrayBuffer||typeof Uint32Array<`u`&&e instanceof Uint32Array}var bl;function xl(e){if(bl)return bl;async function t(){ll=await al(async t=>{let n=e;return n=await n,typeof n==`function`&&(n=await n(t)),typeof n==`function`&&(n=await n(t)),hl(n)?n=await n.instantiator(t):gl(n)?n=await n.default(t):(_l(n)&&(n=n.data),vl(n)?n=typeof WebAssembly.instantiateStreaming==`function`?await Cl(n)(t):await wl(n)(t):yl(n)||n instanceof WebAssembly.Module?n=await Sl(n)(t):`default`in n&&n.default instanceof WebAssembly.Module&&(n=await Sl(n.default)(t))),`instance`in n&&(n=n.instance),`exports`in n&&(n=n.exports),n})}return bl=t(),bl}function Sl(e){return t=>WebAssembly.instantiate(e,t)}function Cl(e){return t=>WebAssembly.instantiateStreaming(e,t)}function wl(e){return async t=>{let n=await e.arrayBuffer();return WebAssembly.instantiate(n,t)}}var Tl;function El(e){Tl=e}function Dl(){return Tl}async function Ol(e){return e&&await xl(e),{createScanner(e){return new ml(e.map(e=>typeof e==`string`?e:e.source))},createString(e){return new pl(e)}}}var kl=Zc({});$c(kl,el);var Al=Object.fromEntries([{id:`andromeeda`,displayName:`Andromeeda`,type:`dark`,import:(()=>G(()=>import(`./andromeeda-vGVdxbeo.js`),[]))},{id:`aurora-x`,displayName:`Aurora X`,type:`dark`,import:(()=>G(()=>import(`./aurora-x-CDeNXAV0.js`),[]))},{id:`ayu-dark`,displayName:`Ayu Dark`,type:`dark`,import:(()=>G(()=>import(`./ayu-dark-DluEY0Gj.js`),[]))},{id:`ayu-light`,displayName:`Ayu Light`,type:`light`,import:(()=>G(()=>import(`./ayu-light-C3h-C4tm.js`),[]))},{id:`ayu-mirage`,displayName:`Ayu Mirage`,type:`dark`,import:(()=>G(()=>import(`./ayu-mirage-Bqwy1Gya.js`),[]))},{id:`catppuccin-frappe`,displayName:`Catppuccin Frappé`,type:`dark`,import:(()=>G(()=>import(`./catppuccin-frappe-3VR1Za6u.js`),[]))},{id:`catppuccin-latte`,displayName:`Catppuccin Latte`,type:`light`,import:(()=>G(()=>import(`./catppuccin-latte-DwIHMF0Q.js`),[]))},{id:`catppuccin-macchiato`,displayName:`Catppuccin Macchiato`,type:`dark`,import:(()=>G(()=>import(`./catppuccin-macchiato-DYnBP6_5.js`),[]))},{id:`catppuccin-mocha`,displayName:`Catppuccin Mocha`,type:`dark`,import:(()=>G(()=>import(`./catppuccin-mocha-DYhrFGRu.js`),[]))},{id:`dark-plus`,displayName:`Dark Plus`,type:`dark`,import:(()=>G(()=>import(`./dark-plus-Cs2F2srj.js`),[]))},{id:`dracula`,displayName:`Dracula Theme`,type:`dark`,import:(()=>G(()=>import(`./dracula-BHWKrbxM.js`),[]))},{id:`dracula-soft`,displayName:`Dracula Theme Soft`,type:`dark`,import:(()=>G(()=>import(`./dracula-soft-5eyTD99u.js`),[]))},{id:`everforest-dark`,displayName:`Everforest Dark`,type:`dark`,import:(()=>G(()=>import(`./everforest-dark-sB-x3p7T.js`),[]))},{id:`everforest-light`,displayName:`Everforest Light`,type:`light`,import:(()=>G(()=>import(`./everforest-light-Df2xbC6M.js`),[]))},{id:`github-dark`,displayName:`GitHub Dark`,type:`dark`,import:(()=>G(()=>import(`./github-dark-C-LZuMrd.js`),[]))},{id:`github-dark-default`,displayName:`GitHub Dark Default`,type:`dark`,import:(()=>G(()=>import(`./github-dark-default-DXG-b-1a.js`),[]))},{id:`github-dark-dimmed`,displayName:`GitHub Dark Dimmed`,type:`dark`,import:(()=>G(()=>import(`./github-dark-dimmed-Bx1FflLF.js`),[]))},{id:`github-dark-high-contrast`,displayName:`GitHub Dark High Contrast`,type:`dark`,import:(()=>G(()=>import(`./github-dark-high-contrast-B_tTalzw.js`),[]))},{id:`github-light`,displayName:`GitHub Light`,type:`light`,import:(()=>G(()=>import(`./github-light-EUqPIrTm.js`),[]))},{id:`github-light-default`,displayName:`GitHub Light Default`,type:`light`,import:(()=>G(()=>import(`./github-light-default-BXViO-2h.js`),[]))},{id:`github-light-high-contrast`,displayName:`GitHub Light High Contrast`,type:`light`,import:(()=>G(()=>import(`./github-light-high-contrast-B68TUdTA.js`),[]))},{id:`gruvbox-dark-hard`,displayName:`Gruvbox Dark Hard`,type:`dark`,import:(()=>G(()=>import(`./gruvbox-dark-hard-C820rvS2.js`),[]))},{id:`gruvbox-dark-medium`,displayName:`Gruvbox Dark Medium`,type:`dark`,import:(()=>G(()=>import(`./gruvbox-dark-medium-BPjhmG05.js`),[]))},{id:`gruvbox-dark-soft`,displayName:`Gruvbox Dark Soft`,type:`dark`,import:(()=>G(()=>import(`./gruvbox-dark-soft-MrdJrrXF.js`),[]))},{id:`gruvbox-light-hard`,displayName:`Gruvbox Light Hard`,type:`light`,import:(()=>G(()=>import(`./gruvbox-light-hard-BC_s9l72.js`),[]))},{id:`gruvbox-light-medium`,displayName:`Gruvbox Light Medium`,type:`light`,import:(()=>G(()=>import(`./gruvbox-light-medium-BAWPOn9u.js`),[]))},{id:`gruvbox-light-soft`,displayName:`Gruvbox Light Soft`,type:`light`,import:(()=>G(()=>import(`./gruvbox-light-soft-BSMLrYjP.js`),[]))},{id:`horizon`,displayName:`Horizon`,type:`dark`,import:(()=>G(()=>import(`./horizon-CE9ld1lL.js`),[]))},{id:`horizon-bright`,displayName:`Horizon Bright`,type:`light`,import:(()=>G(()=>import(`./horizon-bright-DSNQnXHK.js`),[]))},{id:`houston`,displayName:`Houston`,type:`dark`,import:(()=>G(()=>import(`./houston-CsvMBhTu.js`),[]))},{id:`kanagawa-dragon`,displayName:`Kanagawa Dragon`,type:`dark`,import:(()=>G(()=>import(`./kanagawa-dragon-CXtmUGW6.js`),[]))},{id:`kanagawa-lotus`,displayName:`Kanagawa Lotus`,type:`light`,import:(()=>G(()=>import(`./kanagawa-lotus-BN08jTvb.js`),[]))},{id:`kanagawa-wave`,displayName:`Kanagawa Wave`,type:`dark`,import:(()=>G(()=>import(`./kanagawa-wave-CTweb8Dz.js`),[]))},{id:`laserwave`,displayName:`LaserWave`,type:`dark`,import:(()=>G(()=>import(`./laserwave-C_8bwKvT.js`),[]))},{id:`light-plus`,displayName:`Light Plus`,type:`light`,import:(()=>G(()=>import(`./light-plus-DVQuIRkW.js`),[]))},{id:`material-theme`,displayName:`Material Theme`,type:`dark`,import:(()=>G(()=>import(`./material-theme-Bm3Qr25_.js`),[]))},{id:`material-theme-darker`,displayName:`Material Theme Darker`,type:`dark`,import:(()=>G(()=>import(`./material-theme-darker-2IIEA8gg.js`),[]))},{id:`material-theme-lighter`,displayName:`Material Theme Lighter`,type:`light`,import:(()=>G(()=>import(`./material-theme-lighter-uhdI0v04.js`),[]))},{id:`material-theme-ocean`,displayName:`Material Theme Ocean`,type:`dark`,import:(()=>G(()=>import(`./material-theme-ocean-CHQ94UKr.js`),[]))},{id:`material-theme-palenight`,displayName:`Material Theme Palenight`,type:`dark`,import:(()=>G(()=>import(`./material-theme-palenight-B5W6OYN7.js`),[]))},{id:`min-dark`,displayName:`Min Dark`,type:`dark`,import:(()=>G(()=>import(`./min-dark-BSWPekZh.js`),[]))},{id:`min-light`,displayName:`Min Light`,type:`light`,import:(()=>G(()=>import(`./min-light-DDpmG2fV.js`),[]))},{id:`monokai`,displayName:`Monokai`,type:`dark`,import:(()=>G(()=>import(`./monokai-CdkpiU2Y.js`),[]))},{id:`night-owl`,displayName:`Night Owl`,type:`dark`,import:(()=>G(()=>import(`./night-owl-DhmEMT88.js`),[]))},{id:`night-owl-light`,displayName:`Night Owl Light`,type:`light`,import:(()=>G(()=>import(`./night-owl-light-eJ-hLW7d.js`),[]))},{id:`nord`,displayName:`Nord`,type:`dark`,import:(()=>G(()=>import(`./nord-Cb4Vim4T.js`),[]))},{id:`one-dark-pro`,displayName:`One Dark Pro`,type:`dark`,import:(()=>G(()=>import(`./one-dark-pro-CLwyXe_n.js`),[]))},{id:`one-light`,displayName:`One Light`,type:`light`,import:(()=>G(()=>import(`./one-light-D7Lr4KcI.js`),[]))},{id:`plastic`,displayName:`Plastic`,type:`dark`,import:(()=>G(()=>import(`./plastic-DQwYfKfQ.js`),[]))},{id:`poimandres`,displayName:`Poimandres`,type:`dark`,import:(()=>G(()=>import(`./poimandres-DRFjx7u4.js`),[]))},{id:`red`,displayName:`Red`,type:`dark`,import:(()=>G(()=>import(`./red-CJ3rzSJv.js`),[]))},{id:`rose-pine`,displayName:`Rosé Pine`,type:`dark`,import:(()=>G(()=>import(`./rose-pine-BthvhNj6.js`),[]))},{id:`rose-pine-dawn`,displayName:`Rosé Pine Dawn`,type:`light`,import:(()=>G(()=>import(`./rose-pine-dawn-Dg85fqjY.js`),[]))},{id:`rose-pine-moon`,displayName:`Rosé Pine Moon`,type:`dark`,import:(()=>G(()=>import(`./rose-pine-moon-hon4tzzS.js`),[]))},{id:`slack-dark`,displayName:`Slack Dark`,type:`dark`,import:(()=>G(()=>import(`./slack-dark-DnToyrRv.js`),[]))},{id:`slack-ochin`,displayName:`Slack Ochin`,type:`light`,import:(()=>G(()=>import(`./slack-ochin-B2OO5cIa.js`),[]))},{id:`snazzy-light`,displayName:`Snazzy Light`,type:`light`,import:(()=>G(()=>import(`./snazzy-light-4G7pJPwS.js`),[]))},{id:`solarized-dark`,displayName:`Solarized Dark`,type:`dark`,import:(()=>G(()=>import(`./solarized-dark-DV17i1UV.js`),[]))},{id:`solarized-light`,displayName:`Solarized Light`,type:`light`,import:(()=>G(()=>import(`./solarized-light-DSh2HLQt.js`),[]))},{id:`synthwave-84`,displayName:`Synthwave '84`,type:`dark`,import:(()=>G(()=>import(`./synthwave-84-nFMaYfgc.js`),[]))},{id:`tokyo-night`,displayName:`Tokyo Night`,type:`dark`,import:(()=>G(()=>import(`./tokyo-night-oM2G3aXe.js`),[]))},{id:`vesper`,displayName:`Vesper`,type:`dark`,import:(()=>G(()=>import(`./vesper-DdrHHSXu.js`),[]))},{id:`vitesse-black`,displayName:`Vitesse Black`,type:`dark`,import:(()=>G(()=>import(`./vitesse-black-fwtXNY1n.js`),[]))},{id:`vitesse-dark`,displayName:`Vitesse Dark`,type:`dark`,import:(()=>G(()=>import(`./vitesse-dark-BZCL-v6S.js`),[]))},{id:`vitesse-light`,displayName:`Vitesse Light`,type:`light`,import:(()=>G(()=>import(`./vitesse-light-VbXTXTou.js`),[]))}].map(e=>[e.id,e.import])),jl=class extends Error{constructor(e){super(e),this.name=`ShikiError`}};function Ml(e){return Nl(e)}function Nl(e){return Array.isArray(e)?Pl(e):e instanceof RegExp?e:typeof e==`object`?Fl(e):e}function Pl(e){let t=[];for(let n=0,r=e.length;n<r;n++)t[n]=Nl(e[n]);return t}function Fl(e){let t={};for(let n in e)t[n]=Nl(e[n]);return t}function Il(e,...t){return t.forEach(t=>{for(let n in t)e[n]=t[n]}),e}function Ll(e){let t=~e.lastIndexOf(`/`)||~e.lastIndexOf(`\\`);return t===0?e:~t===e.length-1?Ll(e.substring(0,e.length-1)):e.substr(~t+1)}var Rl=/\$(\d+)|\${(\d+):\/(downcase|upcase)}/g,zl=class{static hasCaptures(e){return e===null?!1:(Rl.lastIndex=0,Rl.test(e))}static replaceCaptures(e,t,n){return e.replace(Rl,(e,r,i,a)=>{let o=n[parseInt(r||i,10)];if(o){let e=t.substring(o.start,o.end);for(;e[0]===`.`;)e=e.substring(1);switch(a){case`downcase`:return e.toLowerCase();case`upcase`:return e.toUpperCase();default:return e}}else return e})}};function Bl(e,t){return e<t?-1:+(e>t)}function Vl(e,t){if(e===null&&t===null)return 0;if(!e)return-1;if(!t)return 1;let n=e.length,r=t.length;if(n===r){for(let r=0;r<n;r++){let n=Bl(e[r],t[r]);if(n!==0)return n}return 0}return n-r}function Hl(e){return!!(/^#[0-9a-f]{6}$/i.test(e)||/^#[0-9a-f]{8}$/i.test(e)||/^#[0-9a-f]{3}$/i.test(e)||/^#[0-9a-f]{4}$/i.test(e))}function Ul(e){return e.replace(/[\-\\\{\}\*\+\?\|\^\$\.\,\[\]\(\)\#\s]/g,`\\$&`)}var Wl=class{constructor(e){this.fn=e}cache=new Map;get(e){if(this.cache.has(e))return this.cache.get(e);let t=this.fn(e);return this.cache.set(e,t),t}},Gl=class{constructor(e,t,n){this._colorMap=e,this._defaults=t,this._root=n}static createFromRawTheme(e,t){return this.createFromParsedTheme(Xl(e),t)}static createFromParsedTheme(e,t){return $l(e,t)}_cachedMatchRoot=new Wl(e=>this._root.match(e));getColorMap(){return this._colorMap.getColorMap()}getDefaults(){return this._defaults}match(e){if(e===null)return this._defaults;let t=e.scopeName,n=this._cachedMatchRoot.get(t).find(t=>ql(e.parent,t.parentScopes));return n?new Yl(n.fontStyle,n.foreground,n.background):null}},Kl=class e{constructor(e,t){this.parent=e,this.scopeName=t}static push(t,n){for(let r of n)t=new e(t,r);return t}static from(...t){let n=null;for(let r=0;r<t.length;r++)n=new e(n,t[r]);return n}push(t){return new e(this,t)}getSegments(){let e=this,t=[];for(;e;)t.push(e.scopeName),e=e.parent;return t.reverse(),t}toString(){return this.getSegments().join(` `)}extends(e){return this===e?!0:this.parent===null?!1:this.parent.extends(e)}getExtensionIfDefined(e){let t=[],n=this;for(;n&&n!==e;)t.push(n.scopeName),n=n.parent;return n===e?t.reverse():void 0}};function ql(e,t){if(t.length===0)return!0;for(let n=0;n<t.length;n++){let r=t[n],i=!1;if(r===`>`){if(n===t.length-1)return!1;r=t[++n],i=!0}for(;e&&!Jl(e.scopeName,r);){if(i)return!1;e=e.parent}if(!e)return!1;e=e.parent}return!0}function Jl(e,t){return t===e||e.startsWith(t)&&e[t.length]===`.`}var Yl=class{constructor(e,t,n){this.fontStyle=e,this.foregroundId=t,this.backgroundId=n}};function Xl(e){if(!e||!e.settings||!Array.isArray(e.settings))return[];let t=e.settings,n=[],r=0;for(let e=0,i=t.length;e<i;e++){let i=t[e];if(!i.settings)continue;let a;if(typeof i.scope==`string`){let e=i.scope;e=e.replace(/^[,]+/,``),e=e.replace(/[,]+$/,``),a=e.split(`,`)}else a=Array.isArray(i.scope)?i.scope:[``];let o=-1;if(typeof i.settings.fontStyle==`string`){o=0;let e=i.settings.fontStyle.split(` `);for(let t=0,n=e.length;t<n;t++)switch(e[t]){case`italic`:o|=1;break;case`bold`:o|=2;break;case`underline`:o|=4;break;case`strikethrough`:o|=8;break}}let s=null;typeof i.settings.foreground==`string`&&Hl(i.settings.foreground)&&(s=i.settings.foreground);let c=null;typeof i.settings.background==`string`&&Hl(i.settings.background)&&(c=i.settings.background);for(let t=0,i=a.length;t<i;t++){let i=a[t].trim().split(` `),l=i[i.length-1],u=null;i.length>1&&(u=i.slice(0,i.length-1),u.reverse()),n[r++]=new Zl(l,u,e,o,s,c)}}return n}var Zl=class{constructor(e,t,n,r,i,a){this.scope=e,this.parentScopes=t,this.index=n,this.fontStyle=r,this.foreground=i,this.background=a}},Ql=(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))(Ql||{});function $l(e,t){e.sort((e,t)=>{let n=Bl(e.scope,t.scope);return n!==0||(n=Vl(e.parentScopes,t.parentScopes),n!==0)?n:e.index-t.index});let n=0,r=`#000000`,i=`#ffffff`;for(;e.length>=1&&e[0].scope===``;){let t=e.shift();t.fontStyle!==-1&&(n=t.fontStyle),t.foreground!==null&&(r=t.foreground),t.background!==null&&(i=t.background)}let a=new eu(t),o=new Yl(n,a.getId(r),a.getId(i)),s=new ru(new nu(0,null,-1,0,0),[]);for(let t=0,n=e.length;t<n;t++){let n=e[t];s.insert(0,n.scope,n.parentScopes,n.fontStyle,a.getId(n.foreground),a.getId(n.background))}return new Gl(a,o,s)}var eu=class{_isFrozen;_lastColorId;_id2color;_color2id;constructor(e){if(this._lastColorId=0,this._id2color=[],this._color2id=Object.create(null),Array.isArray(e)){this._isFrozen=!0;for(let t=0,n=e.length;t<n;t++)this._color2id[e[t]]=t,this._id2color[t]=e[t]}else this._isFrozen=!1}getId(e){if(e===null)return 0;e=e.toUpperCase();let t=this._color2id[e];if(t)return t;if(this._isFrozen)throw Error(`Missing color in color map - ${e}`);return t=++this._lastColorId,this._color2id[e]=t,this._id2color[t]=e,t}getColorMap(){return this._id2color.slice(0)}},tu=Object.freeze([]),nu=class e{scopeDepth;parentScopes;fontStyle;foreground;background;constructor(e,t,n,r,i){this.scopeDepth=e,this.parentScopes=t||tu,this.fontStyle=n,this.foreground=r,this.background=i}clone(){return new e(this.scopeDepth,this.parentScopes,this.fontStyle,this.foreground,this.background)}static cloneArr(e){let t=[];for(let n=0,r=e.length;n<r;n++)t[n]=e[n].clone();return t}acceptOverwrite(e,t,n,r){this.scopeDepth>e?console.log(`how did this happen?`):this.scopeDepth=e,t!==-1&&(this.fontStyle=t),n!==0&&(this.foreground=n),r!==0&&(this.background=r)}},ru=class e{constructor(e,t=[],n={}){this._mainRule=e,this._children=n,this._rulesWithParentScopes=t}_rulesWithParentScopes;static _cmpBySpecificity(e,t){if(e.scopeDepth!==t.scopeDepth)return t.scopeDepth-e.scopeDepth;let n=0,r=0;for(;e.parentScopes[n]===`>`&&n++,t.parentScopes[r]===`>`&&r++,!(n>=e.parentScopes.length||r>=t.parentScopes.length);){let i=t.parentScopes[r].length-e.parentScopes[n].length;if(i!==0)return i;n++,r++}return t.parentScopes.length-e.parentScopes.length}match(t){if(t!==``){let e=t.indexOf(`.`),n,r;if(e===-1?(n=t,r=``):(n=t.substring(0,e),r=t.substring(e+1)),this._children.hasOwnProperty(n))return this._children[n].match(r)}let n=this._rulesWithParentScopes.concat(this._mainRule);return n.sort(e._cmpBySpecificity),n}insert(t,n,r,i,a,o){if(n===``){this._doInsertHere(t,r,i,a,o);return}let s=n.indexOf(`.`),c,l;s===-1?(c=n,l=``):(c=n.substring(0,s),l=n.substring(s+1));let u;this._children.hasOwnProperty(c)?u=this._children[c]:(u=new e(this._mainRule.clone(),nu.cloneArr(this._rulesWithParentScopes)),this._children[c]=u),u.insert(t+1,l,r,i,a,o)}_doInsertHere(e,t,n,r,i){if(t===null){this._mainRule.acceptOverwrite(e,n,r,i);return}for(let a=0,o=this._rulesWithParentScopes.length;a<o;a++){let o=this._rulesWithParentScopes[a];if(Vl(o.parentScopes,t)===0){o.acceptOverwrite(e,n,r,i);return}}n===-1&&(n=this._mainRule.fontStyle),r===0&&(r=this._mainRule.foreground),i===0&&(i=this._mainRule.background),this._rulesWithParentScopes.push(new nu(e,t,n,r,i))}},iu=class e{static toBinaryStr(e){return e.toString(2).padStart(32,`0`)}static print(t){let n=e.getLanguageId(t),r=e.getTokenType(t),i=e.getFontStyle(t),a=e.getForeground(t),o=e.getBackground(t);console.log({languageId:n,tokenType:r,fontStyle:i,foreground:a,background:o})}static getLanguageId(e){return(e&255)>>>0}static getTokenType(e){return(e&768)>>>8}static containsBalancedBrackets(e){return(e&1024)!=0}static getFontStyle(e){return(e&30720)>>>11}static getForeground(e){return(e&16744448)>>>15}static getBackground(e){return(e&4278190080)>>>24}static set(t,n,r,i,a,o,s){let c=e.getLanguageId(t),l=e.getTokenType(t),u=+!!e.containsBalancedBrackets(t),d=e.getFontStyle(t),f=e.getForeground(t),p=e.getBackground(t);return n!==0&&(c=n),r!==8&&(l=ou(r)),i!==null&&(u=+!!i),a!==-1&&(d=a),o!==0&&(f=o),s!==0&&(p=s),(c<<0|l<<8|u<<10|d<<11|f<<15|p<<24)>>>0}};function au(e){return e}function ou(e){return e}function su(e,t){let n=[],r=lu(e),i=r.next();for(;i!==null;){let e=0;if(i.length===2&&i.charAt(1)===`:`){switch(i.charAt(0)){case`R`:e=1;break;case`L`:e=-1;break;default:console.log(`Unknown priority ${i} in scope selector`)}i=r.next()}let t=o();if(n.push({matcher:t,priority:e}),i!==`,`)break;i=r.next()}return n;function a(){if(i===`-`){i=r.next();let e=a();return t=>!!e&&!e(t)}if(i===`(`){i=r.next();let e=s();return i===`)`&&(i=r.next()),e}if(cu(i)){let e=[];do e.push(i),i=r.next();while(cu(i));return n=>t(e,n)}return null}function o(){let e=[],t=a();for(;t;)e.push(t),t=a();return t=>e.every(e=>e(t))}function s(){let e=[],t=o();for(;t&&(e.push(t),i===`|`||i===`,`);){do i=r.next();while(i===`|`||i===`,`);t=o()}return t=>e.some(e=>e(t))}}function cu(e){return!!e&&!!e.match(/[\w\.:]+/)}function lu(e){let t=/([LR]:|[\w\.:][\w\.:\-]*|[\,\|\-\(\)])/g,n=t.exec(e);return{next:()=>{if(!n)return null;let r=n[0];return n=t.exec(e),r}}}function uu(e){typeof e.dispose==`function`&&e.dispose()}var du=class{constructor(e){this.scopeName=e}toKey(){return this.scopeName}},fu=class{constructor(e,t){this.scopeName=e,this.ruleName=t}toKey(){return`${this.scopeName}#${this.ruleName}`}},pu=class{_references=[];_seenReferenceKeys=new Set;get references(){return this._references}visitedRule=new Set;add(e){let t=e.toKey();this._seenReferenceKeys.has(t)||(this._seenReferenceKeys.add(t),this._references.push(e))}},mu=class{constructor(e,t){this.repo=e,this.initialScopeName=t,this.seenFullScopeRequests.add(this.initialScopeName),this.Q=[new du(this.initialScopeName)]}seenFullScopeRequests=new Set;seenPartialScopeRequests=new Set;Q;processQueue(){let e=this.Q;this.Q=[];let t=new pu;for(let n of e)hu(n,this.initialScopeName,this.repo,t);for(let e of t.references)if(e instanceof du){if(this.seenFullScopeRequests.has(e.scopeName))continue;this.seenFullScopeRequests.add(e.scopeName),this.Q.push(e)}else{if(this.seenFullScopeRequests.has(e.scopeName)||this.seenPartialScopeRequests.has(e.toKey()))continue;this.seenPartialScopeRequests.add(e.toKey()),this.Q.push(e)}}};function hu(e,t,n,r){let i=n.lookup(e.scopeName);if(!i){if(e.scopeName===t)throw Error(`No grammar provided for <${t}>`);return}let a=n.lookup(t);e instanceof du?_u({baseGrammar:a,selfGrammar:i},r):gu(e.ruleName,{baseGrammar:a,selfGrammar:i,repository:i.repository},r);let o=n.injections(e.scopeName);if(o)for(let e of o)r.add(new du(e))}function gu(e,t,n){if(t.repository&&t.repository[e]){let r=t.repository[e];vu([r],t,n)}}function _u(e,t){e.selfGrammar.patterns&&Array.isArray(e.selfGrammar.patterns)&&vu(e.selfGrammar.patterns,{...e,repository:e.selfGrammar.repository},t),e.selfGrammar.injections&&vu(Object.values(e.selfGrammar.injections),{...e,repository:e.selfGrammar.repository},t)}function vu(e,t,n){for(let r of e){if(n.visitedRule.has(r))continue;n.visitedRule.add(r);let e=r.repository?Il({},t.repository,r.repository):t.repository;Array.isArray(r.patterns)&&vu(r.patterns,{...t,repository:e},n);let i=r.include;if(!i)continue;let a=wu(i);switch(a.kind){case 0:_u({...t,selfGrammar:t.baseGrammar},n);break;case 1:_u(t,n);break;case 2:gu(a.ruleName,{...t,repository:e},n);break;case 3:case 4:let r=a.scopeName===t.selfGrammar.scopeName?t.selfGrammar:a.scopeName===t.baseGrammar.scopeName?t.baseGrammar:void 0;if(r){let i={baseGrammar:t.baseGrammar,selfGrammar:r,repository:e};a.kind===4?gu(a.ruleName,i,n):_u(i,n)}else a.kind===4?n.add(new fu(a.scopeName,a.ruleName)):n.add(new du(a.scopeName));break}}}var yu=class{kind=0},bu=class{kind=1},xu=class{constructor(e){this.ruleName=e}kind=2},Su=class{constructor(e){this.scopeName=e}kind=3},Cu=class{constructor(e,t){this.scopeName=e,this.ruleName=t}kind=4};function wu(e){if(e===`$base`)return new yu;if(e===`$self`)return new bu;let t=e.indexOf(`#`);return t===-1?new Su(e):t===0?new xu(e.substring(1)):new Cu(e.substring(0,t),e.substring(t+1))}var Tu=/\\(\d+)/,Eu=/\\(\d+)/g,Du=-1,Ou=-2;function ku(e){return e}function Au(e){return e}var ju=class{$location;id;_nameIsCapturing;_name;_contentNameIsCapturing;_contentName;constructor(e,t,n,r){this.$location=e,this.id=t,this._name=n||null,this._nameIsCapturing=zl.hasCaptures(this._name),this._contentName=r||null,this._contentNameIsCapturing=zl.hasCaptures(this._contentName)}get debugName(){let e=this.$location?`${Ll(this.$location.filename)}:${this.$location.line}`:`unknown`;return`${this.constructor.name}#${this.id} @ ${e}`}getName(e,t){return!this._nameIsCapturing||this._name===null||e===null||t===null?this._name:zl.replaceCaptures(this._name,e,t)}getContentName(e,t){return!this._contentNameIsCapturing||this._contentName===null?this._contentName:zl.replaceCaptures(this._contentName,e,t)}},Mu=class extends ju{retokenizeCapturedWithRuleId;constructor(e,t,n,r,i){super(e,t,n,r),this.retokenizeCapturedWithRuleId=i}dispose(){}collectPatterns(e,t){throw Error(`Not supported!`)}compile(e,t){throw Error(`Not supported!`)}compileAG(e,t,n,r){throw Error(`Not supported!`)}},Nu=class extends ju{_match;captures;_cachedCompiledPatterns;constructor(e,t,n,r,i){super(e,t,n,null),this._match=new Ru(r,this.id),this.captures=i,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&=(this._cachedCompiledPatterns.dispose(),null)}get debugMatchRegExp(){return`${this._match.source}`}collectPatterns(e,t){t.push(this._match)}compile(e,t){return this._getCachedCompiledPatterns(e).compile(e)}compileAG(e,t,n,r){return this._getCachedCompiledPatterns(e).compileAG(e,n,r)}_getCachedCompiledPatterns(e){return this._cachedCompiledPatterns||(this._cachedCompiledPatterns=new zu,this.collectPatterns(e,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},Pu=class extends ju{hasMissingPatterns;patterns;_cachedCompiledPatterns;constructor(e,t,n,r,i){super(e,t,n,r),this.patterns=i.patterns,this.hasMissingPatterns=i.hasMissingPatterns,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&=(this._cachedCompiledPatterns.dispose(),null)}collectPatterns(e,t){for(let n of this.patterns)e.getRule(n).collectPatterns(e,t)}compile(e,t){return this._getCachedCompiledPatterns(e).compile(e)}compileAG(e,t,n,r){return this._getCachedCompiledPatterns(e).compileAG(e,n,r)}_getCachedCompiledPatterns(e){return this._cachedCompiledPatterns||(this._cachedCompiledPatterns=new zu,this.collectPatterns(e,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},Fu=class extends ju{_begin;beginCaptures;_end;endHasBackReferences;endCaptures;applyEndPatternLast;hasMissingPatterns;patterns;_cachedCompiledPatterns;constructor(e,t,n,r,i,a,o,s,c,l){super(e,t,n,r),this._begin=new Ru(i,this.id),this.beginCaptures=a,this._end=new Ru(o||`￿`,-1),this.endHasBackReferences=this._end.hasBackReferences,this.endCaptures=s,this.applyEndPatternLast=c||!1,this.patterns=l.patterns,this.hasMissingPatterns=l.hasMissingPatterns,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&=(this._cachedCompiledPatterns.dispose(),null)}get debugBeginRegExp(){return`${this._begin.source}`}get debugEndRegExp(){return`${this._end.source}`}getEndWithResolvedBackReferences(e,t){return this._end.resolveBackReferences(e,t)}collectPatterns(e,t){t.push(this._begin)}compile(e,t){return this._getCachedCompiledPatterns(e,t).compile(e)}compileAG(e,t,n,r){return this._getCachedCompiledPatterns(e,t).compileAG(e,n,r)}_getCachedCompiledPatterns(e,t){if(!this._cachedCompiledPatterns){this._cachedCompiledPatterns=new zu;for(let 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,t):this._cachedCompiledPatterns.setSource(0,t)),this._cachedCompiledPatterns}},Iu=class extends ju{_begin;beginCaptures;whileCaptures;_while;whileHasBackReferences;hasMissingPatterns;patterns;_cachedCompiledPatterns;_cachedCompiledWhilePatterns;constructor(e,t,n,r,i,a,o,s,c){super(e,t,n,r),this._begin=new Ru(i,this.id),this.beginCaptures=a,this.whileCaptures=s,this._while=new Ru(o,Ou),this.whileHasBackReferences=this._while.hasBackReferences,this.patterns=c.patterns,this.hasMissingPatterns=c.hasMissingPatterns,this._cachedCompiledPatterns=null,this._cachedCompiledWhilePatterns=null}dispose(){this._cachedCompiledPatterns&&=(this._cachedCompiledPatterns.dispose(),null),this._cachedCompiledWhilePatterns&&=(this._cachedCompiledWhilePatterns.dispose(),null)}get debugBeginRegExp(){return`${this._begin.source}`}get debugWhileRegExp(){return`${this._while.source}`}getWhileWithResolvedBackReferences(e,t){return this._while.resolveBackReferences(e,t)}collectPatterns(e,t){t.push(this._begin)}compile(e,t){return this._getCachedCompiledPatterns(e).compile(e)}compileAG(e,t,n,r){return this._getCachedCompiledPatterns(e).compileAG(e,n,r)}_getCachedCompiledPatterns(e){if(!this._cachedCompiledPatterns){this._cachedCompiledPatterns=new zu;for(let t of this.patterns)e.getRule(t).collectPatterns(e,this._cachedCompiledPatterns)}return this._cachedCompiledPatterns}compileWhile(e,t){return this._getCachedCompiledWhilePatterns(e,t).compile(e)}compileWhileAG(e,t,n,r){return this._getCachedCompiledWhilePatterns(e,t).compileAG(e,n,r)}_getCachedCompiledWhilePatterns(e,t){return this._cachedCompiledWhilePatterns||(this._cachedCompiledWhilePatterns=new zu,this._cachedCompiledWhilePatterns.push(this._while.hasBackReferences?this._while.clone():this._while)),this._while.hasBackReferences&&this._cachedCompiledWhilePatterns.setSource(0,t||`￿`),this._cachedCompiledWhilePatterns}},Lu=class e{static createCaptureRule(e,t,n,r,i){return e.registerRule(e=>new Mu(t,e,n,r,i))}static getCompiledRuleId(t,n,r){return t.id||n.registerRule(i=>{if(t.id=i,t.match)return new Nu(t.$vscodeTextmateLocation,t.id,t.name,t.match,e._compileCaptures(t.captures,n,r));if(t.begin===void 0){t.repository&&(r=Il({},r,t.repository));let i=t.patterns;return i===void 0&&t.include&&(i=[{include:t.include}]),new Pu(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,e._compilePatterns(i,n,r))}return t.while?new Iu(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,t.begin,e._compileCaptures(t.beginCaptures||t.captures,n,r),t.while,e._compileCaptures(t.whileCaptures||t.captures,n,r),e._compilePatterns(t.patterns,n,r)):new Fu(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,t.begin,e._compileCaptures(t.beginCaptures||t.captures,n,r),t.end,e._compileCaptures(t.endCaptures||t.captures,n,r),t.applyEndPatternLast,e._compilePatterns(t.patterns,n,r))}),t.id}static _compileCaptures(t,n,r){let i=[];if(t){let a=0;for(let e in t){if(e===`$vscodeTextmateLocation`)continue;let t=parseInt(e,10);t>a&&(a=t)}for(let e=0;e<=a;e++)i[e]=null;for(let a in t){if(a===`$vscodeTextmateLocation`)continue;let o=parseInt(a,10),s=0;t[a].patterns&&(s=e.getCompiledRuleId(t[a],n,r)),i[o]=e.createCaptureRule(n,t[a].$vscodeTextmateLocation,t[a].name,t[a].contentName,s)}}return i}static _compilePatterns(t,n,r){let i=[];if(t)for(let a=0,o=t.length;a<o;a++){let o=t[a],s=-1;if(o.include){let t=wu(o.include);switch(t.kind){case 0:case 1:s=e.getCompiledRuleId(r[o.include],n,r);break;case 2:let i=r[t.ruleName];i&&(s=e.getCompiledRuleId(i,n,r));break;case 3:case 4:let a=t.scopeName,c=t.kind===4?t.ruleName:null,l=n.getExternalGrammar(a,r);if(l)if(c){let t=l.repository[c];t&&(s=e.getCompiledRuleId(t,n,l.repository))}else s=e.getCompiledRuleId(l.repository.$self,n,l.repository);break}}else s=e.getCompiledRuleId(o,n,r);if(s!==-1){let e=n.getRule(s),t=!1;if((e instanceof Pu||e instanceof Fu||e instanceof Iu)&&e.hasMissingPatterns&&e.patterns.length===0&&(t=!0),t)continue;i.push(s)}}return{patterns:i,hasMissingPatterns:(t?t.length:0)!==i.length}}},Ru=class e{source;ruleId;hasAnchor;hasBackReferences;_anchorCache;constructor(e,t){if(e&&typeof e==`string`){let t=e.length,n=0,r=[],i=!1;for(let a=0;a<t;a++)if(e.charAt(a)===`\\`&&a+1<t){let t=e.charAt(a+1);t===`z`?(r.push(e.substring(n,a)),r.push(`$(?!\\n)(?<!\\n)`),n=a+2):(t===`A`||t===`G`)&&(i=!0),a++}this.hasAnchor=i,n===0?this.source=e:(r.push(e.substring(n,t)),this.source=r.join(``))}else this.hasAnchor=!1,this.source=e;this.hasAnchor?this._anchorCache=this._buildAnchorCache():this._anchorCache=null,this.ruleId=t,typeof this.source==`string`?this.hasBackReferences=Tu.test(this.source):this.hasBackReferences=!1}clone(){return new e(this.source,this.ruleId)}setSource(e){this.source!==e&&(this.source=e,this.hasAnchor&&(this._anchorCache=this._buildAnchorCache()))}resolveBackReferences(e,t){if(typeof this.source!=`string`)throw Error(`This method should only be called if the source is a string`);let n=t.map(t=>e.substring(t.start,t.end));return Eu.lastIndex=0,this.source.replace(Eu,(e,t)=>Ul(n[parseInt(t,10)]||``))}_buildAnchorCache(){if(typeof this.source!=`string`)throw Error(`This method should only be called if the source is a string`);let e=[],t=[],n=[],r=[],i,a,o,s;for(i=0,a=this.source.length;i<a;i++)o=this.source.charAt(i),e[i]=o,t[i]=o,n[i]=o,r[i]=o,o===`\\`&&i+1<a&&(s=this.source.charAt(i+1),s===`A`?(e[i+1]=`￿`,t[i+1]=`￿`,n[i+1]=`A`,r[i+1]=`A`):s===`G`?(e[i+1]=`￿`,t[i+1]=`G`,n[i+1]=`￿`,r[i+1]=`G`):(e[i+1]=s,t[i+1]=s,n[i+1]=s,r[i+1]=s),i++);return{A0_G0:e.join(``),A0_G1:t.join(``),A1_G0:n.join(``),A1_G1:r.join(``)}}resolveAnchors(e,t){return!this.hasAnchor||!this._anchorCache||typeof this.source!=`string`?this.source:e?t?this._anchorCache.A1_G1:this._anchorCache.A1_G0:t?this._anchorCache.A0_G1:this._anchorCache.A0_G0}},zu=class{_items;_hasAnchors;_cached;_anchorCache;constructor(){this._items=[],this._hasAnchors=!1,this._cached=null,this._anchorCache={A0_G0:null,A0_G1:null,A1_G0:null,A1_G1:null}}dispose(){this._disposeCaches()}_disposeCaches(){this._cached&&=(this._cached.dispose(),null),this._anchorCache.A0_G0&&(this._anchorCache.A0_G0.dispose(),this._anchorCache.A0_G0=null),this._anchorCache.A0_G1&&(this._anchorCache.A0_G1.dispose(),this._anchorCache.A0_G1=null),this._anchorCache.A1_G0&&(this._anchorCache.A1_G0.dispose(),this._anchorCache.A1_G0=null),this._anchorCache.A1_G1&&(this._anchorCache.A1_G1.dispose(),this._anchorCache.A1_G1=null)}push(e){this._items.push(e),this._hasAnchors=this._hasAnchors||e.hasAnchor}unshift(e){this._items.unshift(e),this._hasAnchors=this._hasAnchors||e.hasAnchor}length(){return this._items.length}setSource(e,t){this._items[e].source!==t&&(this._disposeCaches(),this._items[e].setSource(t))}compile(e){if(!this._cached){let t=this._items.map(e=>e.source);this._cached=new Bu(e,t,this._items.map(e=>e.ruleId))}return this._cached}compileAG(e,t,n){return this._hasAnchors?t?n?(this._anchorCache.A1_G1||(this._anchorCache.A1_G1=this._resolveAnchors(e,t,n)),this._anchorCache.A1_G1):(this._anchorCache.A1_G0||(this._anchorCache.A1_G0=this._resolveAnchors(e,t,n)),this._anchorCache.A1_G0):n?(this._anchorCache.A0_G1||(this._anchorCache.A0_G1=this._resolveAnchors(e,t,n)),this._anchorCache.A0_G1):(this._anchorCache.A0_G0||(this._anchorCache.A0_G0=this._resolveAnchors(e,t,n)),this._anchorCache.A0_G0):this.compile(e)}_resolveAnchors(e,t,n){return new Bu(e,this._items.map(e=>e.resolveAnchors(t,n)),this._items.map(e=>e.ruleId))}},Bu=class{constructor(e,t,n){this.regExps=t,this.rules=n,this.scanner=e.createOnigScanner(t)}scanner;dispose(){typeof this.scanner.dispose==`function`&&this.scanner.dispose()}toString(){let e=[];for(let t=0,n=this.rules.length;t<n;t++)e.push(` - `+this.rules[t]+`: `+this.regExps[t]);return e.join(`
1415
+ `)}findNextMatchSync(e,t,n){let r=this.scanner.findNextMatchSync(e,t,n);return r?{ruleId:this.rules[r.index],captureIndices:r.captureIndices}:null}},Vu=class{constructor(e,t){this.languageId=e,this.tokenType=t}},Hu=class e{_defaultAttributes;_embeddedLanguagesMatcher;constructor(e,t){this._defaultAttributes=new Vu(e,8),this._embeddedLanguagesMatcher=new Uu(Object.entries(t||{}))}getDefaultAttributes(){return this._defaultAttributes}getBasicScopeAttributes(t){return t===null?e._NULL_SCOPE_METADATA:this._getBasicScopeAttributes.get(t)}static _NULL_SCOPE_METADATA=new Vu(0,0);_getBasicScopeAttributes=new Wl(e=>new Vu(this._scopeToLanguage(e),this._toStandardTokenType(e)));_scopeToLanguage(e){return this._embeddedLanguagesMatcher.match(e)||0}_toStandardTokenType(t){let n=t.match(e.STANDARD_TOKEN_TYPE_REGEXP);if(!n)return 8;switch(n[1]){case`comment`:return 1;case`string`:return 2;case`regex`:return 3;case`meta.embedded`:return 0}throw Error(`Unexpected match for standard token type!`)}static STANDARD_TOKEN_TYPE_REGEXP=/\b(comment|string|regex|meta\.embedded)\b/},Uu=class{values;scopesRegExp;constructor(e){if(e.length===0)this.values=null,this.scopesRegExp=null;else{this.values=new Map(e);let t=e.map(([e,t])=>Ul(e));t.sort(),t.reverse(),this.scopesRegExp=RegExp(`^((${t.join(`)|(`)}))($|\\.)`,``)}}match(e){if(!this.scopesRegExp)return;let t=e.match(this.scopesRegExp);if(t)return this.values.get(t[1])}};typeof process<`u`&&{}.VSCODE_TEXTMATE_DEBUG;var Wu=!1,Gu=class{constructor(e,t){this.stack=e,this.stoppedEarly=t}};function Ku(e,t,n,r,i,a,o,s){let c=t.content.length,l=!1,u=-1;if(o){let o=qu(e,t,n,r,i,a);i=o.stack,r=o.linePos,n=o.isFirstLine,u=o.anchorPosition}let d=Date.now();for(;!l;){if(s!==0&&Date.now()-d>s)return new Gu(i,!0);f()}return new Gu(i,!1);function f(){let o=Ju(e,t,n,r,i,u);if(!o){a.produce(i,c),l=!0;return}let s=o.captureIndices,d=o.matchedRuleId,f=s&&s.length>0?s[0].end>r:!1;if(d===Du){let o=i.getRule(e);a.produce(i,s[0].start),i=i.withContentNameScopesList(i.nameScopesList),ed(e,t,n,i,a,o.endCaptures,s),a.produce(i,s[0].end);let d=i;if(i=i.parent,u=d.getAnchorPos(),!f&&d.getEnterPos()===r){i=d,a.produce(i,c),l=!0;return}}else{let o=e.getRule(d);a.produce(i,s[0].start);let p=i,m=o.getName(t.content,s),h=i.contentNameScopesList.pushAttributed(m,e);if(i=i.push(d,r,u,s[0].end===c,null,h,h),o instanceof Fu){let r=o;ed(e,t,n,i,a,r.beginCaptures,s),a.produce(i,s[0].end),u=s[0].end;let d=r.getContentName(t.content,s),m=h.pushAttributed(d,e);if(i=i.withContentNameScopesList(m),r.endHasBackReferences&&(i=i.withEndRule(r.getEndWithResolvedBackReferences(t.content,s))),!f&&p.hasSameRuleAs(i)){i=i.pop(),a.produce(i,c),l=!0;return}}else if(o instanceof Iu){let r=o;ed(e,t,n,i,a,r.beginCaptures,s),a.produce(i,s[0].end),u=s[0].end;let d=r.getContentName(t.content,s),m=h.pushAttributed(d,e);if(i=i.withContentNameScopesList(m),r.whileHasBackReferences&&(i=i.withEndRule(r.getWhileWithResolvedBackReferences(t.content,s))),!f&&p.hasSameRuleAs(i)){i=i.pop(),a.produce(i,c),l=!0;return}}else if(ed(e,t,n,i,a,o.captures,s),a.produce(i,s[0].end),i=i.pop(),!f){i=i.safePop(),a.produce(i,c),l=!0;return}}s[0].end>r&&(r=s[0].end,n=!1)}}function qu(e,t,n,r,i,a){let o=i.beginRuleCapturedEOL?0:-1,s=[];for(let t=i;t;t=t.pop()){let n=t.getRule(e);n instanceof Iu&&s.push({rule:n,stack:t})}for(let c=s.pop();c;c=s.pop()){let{ruleScanner:s,findOptions:l}=Qu(c.rule,e,c.stack.endRule,n,r===o),u=s.findNextMatchSync(t,r,l);if(u){if(u.ruleId!==Ou){i=c.stack.pop();break}u.captureIndices&&u.captureIndices.length&&(a.produce(c.stack,u.captureIndices[0].start),ed(e,t,n,c.stack,a,c.rule.whileCaptures,u.captureIndices),a.produce(c.stack,u.captureIndices[0].end),o=u.captureIndices[0].end,u.captureIndices[0].end>r&&(r=u.captureIndices[0].end,n=!1))}else{i=c.stack.pop();break}}return{stack:i,linePos:r,anchorPosition:o,isFirstLine:n}}function Ju(e,t,n,r,i,a){let o=Yu(e,t,n,r,i,a),s=e.getInjections();if(s.length===0)return o;let c=Xu(s,e,t,n,r,i,a);if(!c)return o;if(!o)return c;let l=o.captureIndices[0].start,u=c.captureIndices[0].start;return u<l||c.priorityMatch&&u===l?c:o}function Yu(e,t,n,r,i,a){let{ruleScanner:o,findOptions:s}=Zu(i.getRule(e),e,i.endRule,n,r===a),c=o.findNextMatchSync(t,r,s);return c?{captureIndices:c.captureIndices,matchedRuleId:c.ruleId}:null}function Xu(e,t,n,r,i,a,o){let s=Number.MAX_VALUE,c=null,l,u=0,d=a.contentNameScopesList.getScopeNames();for(let a=0,f=e.length;a<f;a++){let f=e[a];if(!f.matcher(d))continue;let{ruleScanner:p,findOptions:m}=Zu(t.getRule(f.ruleId),t,null,r,i===o),h=p.findNextMatchSync(n,i,m);if(!h)continue;let g=h.captureIndices[0].start;if(!(g>=s)&&(s=g,c=h.captureIndices,l=h.ruleId,u=f.priority,s===i))break}return c?{priorityMatch:u===-1,captureIndices:c,matchedRuleId:l}:null}function Zu(e,t,n,r,i){return Wu?{ruleScanner:e.compile(t,n),findOptions:$u(r,i)}:{ruleScanner:e.compileAG(t,n,r,i),findOptions:0}}function Qu(e,t,n,r,i){return Wu?{ruleScanner:e.compileWhile(t,n),findOptions:$u(r,i)}:{ruleScanner:e.compileWhileAG(t,n,r,i),findOptions:0}}function $u(e,t){let n=0;return e||(n|=1),t||(n|=4),n}function ed(e,t,n,r,i,a,o){if(a.length===0)return;let s=t.content,c=Math.min(a.length,o.length),l=[],u=o[0].end;for(let t=0;t<c;t++){let c=a[t];if(c===null)continue;let d=o[t];if(d.length===0)continue;if(d.start>u)break;for(;l.length>0&&l[l.length-1].endPos<=d.start;)i.produceFromScopes(l[l.length-1].scopes,l[l.length-1].endPos),l.pop();if(l.length>0?i.produceFromScopes(l[l.length-1].scopes,d.start):i.produce(r,d.start),c.retokenizeCapturedWithRuleId){let t=c.getName(s,o),a=r.contentNameScopesList.pushAttributed(t,e),l=c.getContentName(s,o),u=a.pushAttributed(l,e),f=r.push(c.retokenizeCapturedWithRuleId,d.start,-1,!1,null,a,u),p=e.createOnigString(s.substring(0,d.end));Ku(e,p,n&&d.start===0,d.start,f,i,!1,0),uu(p);continue}let f=c.getName(s,o);if(f!==null){let t=(l.length>0?l[l.length-1].scopes:r.contentNameScopesList).pushAttributed(f,e);l.push(new td(t,d.end))}}for(;l.length>0;)i.produceFromScopes(l[l.length-1].scopes,l[l.length-1].endPos),l.pop()}var td=class{scopes;endPos;constructor(e,t){this.scopes=e,this.endPos=t}};function nd(e,t,n,r,i,a,o,s){return new od(e,t,n,r,i,a,o,s)}function rd(e,t,n,r,i){let a=su(t,id),o=Lu.getCompiledRuleId(n,r,i.repository);for(let n of a)e.push({debugSelector:t,matcher:n.matcher,ruleId:o,grammar:i,priority:n.priority})}function id(e,t){if(t.length<e.length)return!1;let n=0;return e.every(e=>{for(let r=n;r<t.length;r++)if(ad(t[r],e))return n=r+1,!0;return!1})}function ad(e,t){if(!e)return!1;if(e===t)return!0;let n=t.length;return e.length>n&&e.substr(0,n)===t&&e[n]===`.`}var od=class{constructor(e,t,n,r,i,a,o,s){if(this._rootScopeName=e,this.balancedBracketSelectors=a,this._onigLib=s,this._basicScopeAttributesProvider=new Hu(n,r),this._rootId=-1,this._lastRuleId=0,this._ruleId2desc=[null],this._includedGrammars={},this._grammarRepository=o,this._grammar=sd(t,null),this._injections=null,this._tokenTypeMatchers=[],i)for(let e of Object.keys(i)){let t=su(e,id);for(let n of t)this._tokenTypeMatchers.push({matcher:n.matcher,type:i[e]})}}_rootId;_lastRuleId;_ruleId2desc;_includedGrammars;_grammarRepository;_grammar;_injections;_basicScopeAttributesProvider;_tokenTypeMatchers;get themeProvider(){return this._grammarRepository}dispose(){for(let 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(){let e={lookup:e=>e===this._rootScopeName?this._grammar:this.getExternalGrammar(e),injections:e=>this._grammarRepository.injections(e)},t=[],n=this._rootScopeName,r=e.lookup(n);if(r){let e=r.injections;if(e)for(let n in e)rd(t,n,e[n],this,r);let i=this._grammarRepository.injections(n);i&&i.forEach(e=>{let n=this.getExternalGrammar(e);if(n){let e=n.injectionSelector;e&&rd(t,e,n,this,n)}})}return t.sort((e,t)=>e.priority-t.priority),t}getInjections(){return this._injections===null&&(this._injections=this._collectInjections()),this._injections}registerRule(e){let t=++this._lastRuleId,n=e(ku(t));return this._ruleId2desc[t]=n,n}getRule(e){return this._ruleId2desc[Au(e)]}getExternalGrammar(e,t){if(this._includedGrammars[e])return this._includedGrammars[e];if(this._grammarRepository){let n=this._grammarRepository.lookup(e);if(n)return this._includedGrammars[e]=sd(n,t&&t.$base),this._includedGrammars[e]}}tokenizeLine(e,t,n=0){let r=this._tokenize(e,t,!1,n);return{tokens:r.lineTokens.getResult(r.ruleStack,r.lineLength),ruleStack:r.ruleStack,stoppedEarly:r.stoppedEarly}}tokenizeLine2(e,t,n=0){let r=this._tokenize(e,t,!0,n);return{tokens:r.lineTokens.getBinaryResult(r.ruleStack,r.lineLength),ruleStack:r.ruleStack,stoppedEarly:r.stoppedEarly}}_tokenize(e,t,n,r){this._rootId===-1&&(this._rootId=Lu.getCompiledRuleId(this._grammar.repository.$self,this,this._grammar.repository),this.getInjections());let i;if(!t||t===ld.NULL){i=!0;let e=this._basicScopeAttributesProvider.getDefaultAttributes(),n=this.themeProvider.getDefaults(),r=iu.set(0,e.languageId,e.tokenType,null,n.fontStyle,n.foregroundId,n.backgroundId),a=this.getRule(this._rootId).getName(null,null),o;o=a?cd.createRootAndLookUpScopeName(a,r,this):cd.createRoot(`unknown`,r),t=new ld(null,this._rootId,-1,-1,!1,null,o,o)}else i=!1,t.reset();e+=`
1416
+ `;let a=this.createOnigString(e),o=a.content.length,s=new dd(n,e,this._tokenTypeMatchers,this.balancedBracketSelectors),c=Ku(this,a,i,0,t,s,!0,r);return uu(a),{lineLength:o,lineTokens:s,ruleStack:c.stack,stoppedEarly:c.stoppedEarly}}};function sd(e,t){return e=Ml(e),e.repository=e.repository||{},e.repository.$self={$vscodeTextmateLocation:e.$vscodeTextmateLocation,patterns:e.patterns,name:e.scopeName},e.repository.$base=t||e.repository.$self,e}var cd=class e{constructor(e,t,n){this.parent=e,this.scopePath=t,this.tokenAttributes=n}static fromExtension(t,n){let r=t,i=t?.scopePath??null;for(let t of n)i=Kl.push(i,t.scopeNames),r=new e(r,i,t.encodedTokenAttributes);return r}static createRoot(t,n){return new e(null,new Kl(null,t),n)}static createRootAndLookUpScopeName(t,n,r){let i=r.getMetadataForScope(t),a=new Kl(null,t),o=r.themeProvider.themeMatch(a);return new e(null,a,e.mergeAttributes(n,i,o))}get scopeName(){return this.scopePath.scopeName}toString(){return this.getScopeNames().join(` `)}equals(t){return e.equals(this,t)}static equals(e,t){do{if(e===t||!e&&!t)return!0;if(!e||!t||e.scopeName!==t.scopeName||e.tokenAttributes!==t.tokenAttributes)return!1;e=e.parent,t=t.parent}while(!0)}static mergeAttributes(e,t,n){let r=-1,i=0,a=0;return n!==null&&(r=n.fontStyle,i=n.foregroundId,a=n.backgroundId),iu.set(e,t.languageId,t.tokenType,null,r,i,a)}pushAttributed(t,n){if(t===null)return this;if(t.indexOf(` `)===-1)return e._pushAttributed(this,t,n);let r=t.split(/ /g),i=this;for(let t of r)i=e._pushAttributed(i,t,n);return i}static _pushAttributed(t,n,r){let i=r.getMetadataForScope(n),a=t.scopePath.push(n),o=r.themeProvider.themeMatch(a);return new e(t,a,e.mergeAttributes(t.tokenAttributes,i,o))}getScopeNames(){return this.scopePath.getSegments()}getExtensionIfDefined(e){let t=[],n=this;for(;n&&n!==e;)t.push({encodedTokenAttributes:n.tokenAttributes,scopeNames:n.scopePath.getExtensionIfDefined(n.parent?.scopePath??null)}),n=n.parent;return n===e?t.reverse():void 0}},ld=class e{constructor(e,t,n,r,i,a,o,s){this.parent=e,this.ruleId=t,this.beginRuleCapturedEOL=i,this.endRule=a,this.nameScopesList=o,this.contentNameScopesList=s,this.depth=this.parent?this.parent.depth+1:1,this._enterPos=n,this._anchorPos=r}_stackElementBrand=void 0;static NULL=new e(null,0,0,0,!1,null,null,null);_enterPos;_anchorPos;depth;equals(t){return t===null?!1:e._equals(this,t)}static _equals(e,t){return e===t?!0:this._structuralEquals(e,t)?cd.equals(e.contentNameScopesList,t.contentNameScopesList):!1}static _structuralEquals(e,t){do{if(e===t||!e&&!t)return!0;if(!e||!t||e.depth!==t.depth||e.ruleId!==t.ruleId||e.endRule!==t.endRule)return!1;e=e.parent,t=t.parent}while(!0)}clone(){return this}static _reset(e){for(;e;)e._enterPos=-1,e._anchorPos=-1,e=e.parent}reset(){e._reset(this)}pop(){return this.parent}safePop(){return this.parent?this.parent:this}push(t,n,r,i,a,o,s){return new e(this,t,n,r,i,a,o,s)}getEnterPos(){return this._enterPos}getAnchorPos(){return this._anchorPos}getRule(e){return e.getRule(this.ruleId)}toString(){let e=[];return this._writeString(e,0),`[`+e.join(`,`)+`]`}_writeString(e,t){return this.parent&&(t=this.parent._writeString(e,t)),e[t++]=`(${this.ruleId}, ${this.nameScopesList?.toString()}, ${this.contentNameScopesList?.toString()})`,t}withContentNameScopesList(e){return this.contentNameScopesList===e?this:this.parent.push(this.ruleId,this._enterPos,this._anchorPos,this.beginRuleCapturedEOL,this.endRule,this.nameScopesList,e)}withEndRule(t){return this.endRule===t?this:new e(this.parent,this.ruleId,this._enterPos,this._anchorPos,this.beginRuleCapturedEOL,t,this.nameScopesList,this.contentNameScopesList)}hasSameRuleAs(e){let t=this;for(;t&&t._enterPos===e._enterPos;){if(t.ruleId===e.ruleId)return!0;t=t.parent}return!1}toStateStackFrame(){return{ruleId:Au(this.ruleId),beginRuleCapturedEOL:this.beginRuleCapturedEOL,endRule:this.endRule,nameScopesList:this.nameScopesList?.getExtensionIfDefined(this.parent?.nameScopesList??null)??[],contentNameScopesList:this.contentNameScopesList?.getExtensionIfDefined(this.nameScopesList)??[]}}static pushFrame(t,n){let r=cd.fromExtension(t?.nameScopesList??null,n.nameScopesList);return new e(t,ku(n.ruleId),n.enterPos??-1,n.anchorPos??-1,n.beginRuleCapturedEOL,n.endRule,r,cd.fromExtension(r,n.contentNameScopesList))}},ud=class{balancedBracketScopes;unbalancedBracketScopes;allowAny=!1;constructor(e,t){this.balancedBracketScopes=e.flatMap(e=>e===`*`?(this.allowAny=!0,[]):su(e,id).map(e=>e.matcher)),this.unbalancedBracketScopes=t.flatMap(e=>su(e,id).map(e=>e.matcher))}get matchesAlways(){return this.allowAny&&this.unbalancedBracketScopes.length===0}get matchesNever(){return this.balancedBracketScopes.length===0&&!this.allowAny}match(e){for(let t of this.unbalancedBracketScopes)if(t(e))return!1;for(let t of this.balancedBracketScopes)if(t(e))return!0;return this.allowAny}},dd=class{constructor(e,t,n,r){this.balancedBracketSelectors=r,this._emitBinaryTokens=e,this._tokenTypeOverrides=n,this._lineText=null,this._tokens=[],this._binaryTokens=[],this._lastTokenEndIndex=0}_emitBinaryTokens;_lineText;_tokens;_binaryTokens;_lastTokenEndIndex;_tokenTypeOverrides;produce(e,t){this.produceFromScopes(e.contentNameScopesList,t)}produceFromScopes(e,t){if(this._lastTokenEndIndex>=t)return;if(this._emitBinaryTokens){let n=e?.tokenAttributes??0,r=!1;if(this.balancedBracketSelectors?.matchesAlways&&(r=!0),this._tokenTypeOverrides.length>0||this.balancedBracketSelectors&&!this.balancedBracketSelectors.matchesAlways&&!this.balancedBracketSelectors.matchesNever){let t=e?.getScopeNames()??[];for(let e of this._tokenTypeOverrides)e.matcher(t)&&(n=iu.set(n,0,au(e.type),null,-1,0,0));this.balancedBracketSelectors&&(r=this.balancedBracketSelectors.match(t))}if(r&&(n=iu.set(n,0,8,r,-1,0,0)),this._binaryTokens.length>0&&this._binaryTokens[this._binaryTokens.length-1]===n){this._lastTokenEndIndex=t;return}this._binaryTokens.push(this._lastTokenEndIndex),this._binaryTokens.push(n),this._lastTokenEndIndex=t;return}let n=e?.getScopeNames()??[];this._tokens.push({startIndex:this._lastTokenEndIndex,endIndex:t,scopes:n}),this._lastTokenEndIndex=t}getResult(e,t){return this._tokens.length>0&&this._tokens[this._tokens.length-1].startIndex===t-1&&this._tokens.pop(),this._tokens.length===0&&(this._lastTokenEndIndex=-1,this.produce(e,t),this._tokens[this._tokens.length-1].startIndex=0),this._tokens}getBinaryResult(e,t){this._binaryTokens.length>0&&this._binaryTokens[this._binaryTokens.length-2]===t-1&&(this._binaryTokens.pop(),this._binaryTokens.pop()),this._binaryTokens.length===0&&(this._lastTokenEndIndex=-1,this.produce(e,t),this._binaryTokens[this._binaryTokens.length-2]=0);let n=new Uint32Array(this._binaryTokens.length);for(let e=0,t=this._binaryTokens.length;e<t;e++)n[e]=this._binaryTokens[e];return n}},fd=class{constructor(e,t){this._onigLib=t,this._theme=e}_grammars=new Map;_rawGrammars=new Map;_injectionGrammars=new Map;_theme;dispose(){for(let e of this._grammars.values())e.dispose()}setTheme(e){this._theme=e}getColorMap(){return this._theme.getColorMap()}addGrammar(e,t){this._rawGrammars.set(e.scopeName,e),t&&this._injectionGrammars.set(e.scopeName,t)}lookup(e){return this._rawGrammars.get(e)}injections(e){return this._injectionGrammars.get(e)}getDefaults(){return this._theme.getDefaults()}themeMatch(e){return this._theme.match(e)}grammarForScopeName(e,t,n,r,i){if(!this._grammars.has(e)){let a=this._rawGrammars.get(e);if(!a)return null;this._grammars.set(e,nd(e,a,t,n,r,i,this,this._onigLib))}return this._grammars.get(e)}},pd=class{_options;_syncRegistry;_ensureGrammarCache;constructor(e){this._options=e,this._syncRegistry=new fd(Gl.createFromRawTheme(e.theme,e.colorMap),e.onigLib),this._ensureGrammarCache=new Map}dispose(){this._syncRegistry.dispose()}setTheme(e,t){this._syncRegistry.setTheme(Gl.createFromRawTheme(e,t))}getColorMap(){return this._syncRegistry.getColorMap()}loadGrammarWithEmbeddedLanguages(e,t,n){return this.loadGrammarWithConfiguration(e,t,{embeddedLanguages:n})}loadGrammarWithConfiguration(e,t,n){return this._loadGrammar(e,t,n.embeddedLanguages,n.tokenTypes,new ud(n.balancedBracketSelectors||[],n.unbalancedBracketSelectors||[]))}loadGrammar(e){return this._loadGrammar(e,0,null,null,null)}_loadGrammar(e,t,n,r,i){let a=new mu(this._syncRegistry,e);for(;a.Q.length>0;)a.Q.map(e=>this._loadSingleGrammar(e.scopeName)),a.processQueue();return this._grammarForScopeName(e,t,n,r,i)}_loadSingleGrammar(e){this._ensureGrammarCache.has(e)||(this._doLoadSingleGrammar(e),this._ensureGrammarCache.set(e,!0))}_doLoadSingleGrammar(e){let t=this._options.loadGrammar(e);if(t){let n=typeof this._options.getInjections==`function`?this._options.getInjections(e):void 0;this._syncRegistry.addGrammar(t,n)}}addGrammar(e,t=[],n=0,r=null){return this._syncRegistry.addGrammar(e,t),this._grammarForScopeName(e.scopeName,n,r)}_grammarForScopeName(e,t=0,n=null,r=null,i=null){return this._syncRegistry.grammarForScopeName(e,t,n,r,i)}},md=ld.NULL;function hd(e,t){let n=typeof e==`string`?{}:{...e.colorReplacements},r=typeof e==`string`?e:e.name;for(let[e,i]of Object.entries(t?.colorReplacements||{}))typeof i==`string`?n[e]=i:e===r&&Object.assign(n,i);return n}function gd(e,t){return e&&(t?.[e?.toLowerCase()]||e)}function _d(e){return Array.isArray(e)?e:[e]}async function vd(e){return Promise.resolve(typeof e==`function`?e():e).then(e=>e.default||e)}function yd(e){return!e||[`plaintext`,`txt`,`text`,`plain`].includes(e)}function bd(e){return e===`ansi`||yd(e)}function xd(e){return e===`none`}function Sd(e){return xd(e)}var Cd=/(\r?\n)/g;function wd(e,t=!1){if(e.length===0)return[[``,0]];let n=e.split(Cd),r=0,i=[];for(let e=0;e<n.length;e+=2){let a=t?n[e]+(n[e+1]||``):n[e];i.push([a,r]),r+=n[e].length,r+=n[e+1]?.length||0}return i}var Td={light:`#333333`,dark:`#bbbbbb`},Ed={light:`#fffffe`,dark:`#1e1e1e`},Dd=`__shiki_resolved`;function Od(e){if(e?.[Dd])return e;let t={...e};t.tokenColors&&!t.settings&&(t.settings=t.tokenColors,delete t.tokenColors),t.type||=`dark`,t.colorReplacements={...t.colorReplacements},t.settings||=[];let{bg:n,fg:r}=t;if(!n||!r){let e=t.settings?t.settings.find(e=>!e.name&&!e.scope):void 0;e?.settings?.foreground&&(r=e.settings.foreground),e?.settings?.background&&(n=e.settings.background),!r&&t?.colors?.[`editor.foreground`]&&(r=t.colors[`editor.foreground`]),!n&&t?.colors?.[`editor.background`]&&(n=t.colors[`editor.background`]),r||=t.type===`light`?Td.light:Td.dark,n||=t.type===`light`?Ed.light:Ed.dark,t.fg=r,t.bg=n}t.settings[0]&&t.settings[0].settings&&!t.settings[0].scope||t.settings.unshift({settings:{foreground:t.fg,background:t.bg}});let i=0,a=new Map;function o(e){if(a.has(e))return a.get(e);i+=1;let n=`#${i.toString(16).padStart(8,`0`).toLowerCase()}`;return t.colorReplacements?.[`#${n}`]?o(e):(a.set(e,n),n)}t.settings=t.settings.map(e=>{let n=e.settings?.foreground&&!e.settings.foreground.startsWith(`#`),r=e.settings?.background&&!e.settings.background.startsWith(`#`);if(!n&&!r)return e;let i={...e,settings:{...e.settings}};if(n){let n=o(e.settings.foreground);t.colorReplacements[n]=e.settings.foreground,i.settings.foreground=n}if(r){let n=o(e.settings.background);t.colorReplacements[n]=e.settings.background,i.settings.background=n}return i});for(let e of Object.keys(t.colors||{}))if((e===`editor.foreground`||e===`editor.background`||e.startsWith(`terminal.ansi`))&&!t.colors[e]?.startsWith(`#`)){let n=o(t.colors[e]);t.colorReplacements[n]=t.colors[e],t.colors[e]=n}return Object.defineProperty(t,Dd,{enumerable:!1,writable:!1,value:!0}),t}async function kd(e){return[...new Set((await Promise.all(e.filter(e=>!bd(e)).map(async e=>await vd(e).then(e=>Array.isArray(e)?e:[e])))).flat())]}async function Ad(e){return(await Promise.all(e.map(async e=>Sd(e)?null:Od(await vd(e))))).filter(e=>!!e)}function jd(e,t){if(!t)return e;if(t[e]){let n=new Set([e]);for(;t[e];){if(e=t[e],n.has(e))throw new jl(`Circular alias \`${[...n].join(` -> `)} -> ${e}\``);n.add(e)}}return e}var Md=class extends pd{_resolver;_themes;_langs;_alias;_resolvedThemes=new Map;_resolvedGrammars=new Map;_langMap=new Map;_langGraph=new Map;_textmateThemeCache=new WeakMap;_loadedThemesCache=null;_loadedLanguagesCache=null;constructor(e,t,n,r={}){super(e),this._resolver=e,this._themes=t,this._langs=n,this._alias=r,this._themes.map(e=>this.loadTheme(e)),this.loadLanguages(this._langs)}getTheme(e){return typeof e==`string`?this._resolvedThemes.get(e):this.loadTheme(e)}loadTheme(e){let t=Od(e);return t.name&&(this._resolvedThemes.set(t.name,t),this._loadedThemesCache=null),t}getLoadedThemes(){return this._loadedThemesCache||=[...this._resolvedThemes.keys()],this._loadedThemesCache}setTheme(e){let t=this._textmateThemeCache.get(e);t||(t=Gl.createFromRawTheme(e),this._textmateThemeCache.set(e,t)),this._syncRegistry.setTheme(t)}getGrammar(e){return e=jd(e,this._alias),this._resolvedGrammars.get(e)}loadLanguage(e){if(this.getGrammar(e.name))return;let t=new Set([...this._langMap.values()].filter(t=>t.embeddedLangsLazy?.includes(e.name)));this._resolver.addLanguage(e);let n={balancedBracketSelectors:e.balancedBracketSelectors||[`*`],unbalancedBracketSelectors:e.unbalancedBracketSelectors||[]};this._syncRegistry._rawGrammars.set(e.scopeName,e);let r=this.loadGrammarWithConfiguration(e.scopeName,1,n);if(r.name=e.name,this._resolvedGrammars.set(e.name,r),e.aliases&&e.aliases.forEach(t=>{this._alias[t]=e.name}),this._loadedLanguagesCache=null,t.size)for(let e of t)this._resolvedGrammars.delete(e.name),this._loadedLanguagesCache=null,this._syncRegistry?._injectionGrammars?.delete(e.scopeName),this._syncRegistry?._grammars?.delete(e.scopeName),this.loadLanguage(this._langMap.get(e.name))}dispose(){super.dispose(),this._resolvedThemes.clear(),this._resolvedGrammars.clear(),this._langMap.clear(),this._langGraph.clear(),this._loadedThemesCache=null}loadLanguages(e){for(let t of e)this.resolveEmbeddedLanguages(t);let t=[...this._langGraph.entries()],n=t.filter(([e,t])=>!t);if(n.length){let e=t.filter(([e,t])=>t?(t.embeddedLanguages||t.embeddedLangs)?.some(e=>n.map(([e])=>e).includes(e)):!1).filter(e=>!n.includes(e));throw new jl(`Missing languages ${n.map(([e])=>`\`${e}\``).join(`, `)}, required by ${e.map(([e])=>`\`${e}\``).join(`, `)}`)}for(let[e,n]of t)this._resolver.addLanguage(n);for(let[e,n]of t)this.loadLanguage(n)}getLoadedLanguages(){return this._loadedLanguagesCache||=[...new Set([...this._resolvedGrammars.keys(),...Object.keys(this._alias)])],this._loadedLanguagesCache}resolveEmbeddedLanguages(e){this._langMap.set(e.name,e),this._langGraph.set(e.name,e);let t=e.embeddedLanguages??e.embeddedLangs;if(t)for(let e of t)this._langGraph.set(e,this._langMap.get(e))}},Nd=class{_langs=new Map;_scopeToLang=new Map;_injections=new Map;_onigLib;constructor(e,t){this._onigLib={createOnigScanner:t=>e.createScanner(t),createOnigString:t=>e.createString(t)},t.forEach(e=>this.addLanguage(e))}get onigLib(){return this._onigLib}getLangRegistration(e){return this._langs.get(e)}loadGrammar(e){return this._scopeToLang.get(e)}addLanguage(e){this._langs.set(e.name,e),e.aliases&&e.aliases.forEach(t=>{this._langs.set(t,e)}),this._scopeToLang.set(e.scopeName,e),e.injectTo&&e.injectTo.forEach(t=>{this._injections.get(t)||this._injections.set(t,[]),this._injections.get(t).push(e.scopeName)})}getInjections(e){let t=e.split(`.`),n=[];for(let e=1;e<=t.length;e++){let r=t.slice(0,e).join(`.`);n=[...n,...this._injections.get(r)||[]]}return n}},Pd=0;function Fd(e){Pd+=1,e.warnings!==!1&&Pd>=10&&Pd%10==0&&console.warn(`[Shiki] ${Pd} 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 t=!1;if(!e.engine)throw new jl("`engine` option is required for synchronous mode");let n=(e.langs||[]).flat(1),r=(e.themes||[]).flat(1).map(Od),i=new Md(new Nd(e.engine,n),r,n,e.langAlias),a;function o(t){return jd(t,e.langAlias)}function s(e){g();let t=i.getGrammar(typeof e==`string`?e:e.name);if(!t)throw new jl(`Language \`${e}\` not found, you may need to load it first`);return t}function c(e){if(e===`none`)return{bg:``,fg:``,name:`none`,settings:[],type:`dark`};g();let t=i.getTheme(e);if(!t)throw new jl(`Theme \`${e}\` not found, you may need to load it first`);return t}function l(e){g();let t=c(e);return a!==e&&(i.setTheme(t),a=e),{theme:t,colorMap:i.getColorMap()}}function u(){return g(),i.getLoadedThemes()}function d(){return g(),i.getLoadedLanguages()}function f(...e){g(),i.loadLanguages(e.flat(1))}async function p(...e){return f(await kd(e))}function m(...e){g();for(let t of e.flat(1))i.loadTheme(t)}async function h(...e){return g(),m(await Ad(e))}function g(){if(t)throw new jl(`Shiki instance has been disposed`)}function _(){t||(t=!0,i.dispose(),--Pd)}return{setTheme:l,getTheme:c,getLanguage:s,getLoadedThemes:u,getLoadedLanguages:d,resolveLangAlias:o,loadLanguage:p,loadLanguageSync:f,loadTheme:h,loadThemeSync:m,dispose:_,[Symbol.dispose]:_}}async function Id(e){e.engine||console.warn("`engine` option is required. Use `createOnigurumaEngine` or `createJavaScriptRegexEngine` to create an engine.");let[t,n,r]=await Promise.all([Ad(e.themes||[]),kd(e.langs||[]),e.engine]);return Fd({...e,themes:t,langs:n,engine:r})}var Ld=new WeakMap;function Rd(e,t){Ld.set(e,t)}function zd(e){return Ld.get(e)}var Bd=class e{_stacks={};lang;get themes(){return Object.keys(this._stacks)}get theme(){return this.themes[0]}get _stack(){return this._stacks[this.theme]}static initial(t,n){return new e(Object.fromEntries(_d(n).map(e=>[e,md])),t)}constructor(...e){if(e.length===2){let[t,n]=e;this.lang=n,this._stacks=t}else{let[t,n,r]=e;this.lang=n,this._stacks={[r]:t}}}getInternalStack(e=this.theme){return this._stacks[e]}getScopes(e=this.theme){return Vd(this._stacks[e])}toJSON(){return{lang:this.lang,theme:this.theme,themes:this.themes,scopes:this.getScopes()}}};function Vd(e){let t=[],n=new Set;function r(e){if(n.has(e))return;n.add(e);let i=e?.nameScopesList?.scopeName;i&&t.push(i),e.parent&&r(e.parent)}return r(e),t}function Hd(e,t){if(!(e instanceof Bd))throw new jl(`Invalid grammar state`);return e.getInternalStack(t)}var Ud=/,/,Wd=/ /;function Gd(e,t,n={}){let{theme:r=e.getLoadedThemes()[0]}=n;if(yd(e.resolveLangAlias(n.lang||`text`))||xd(r))return wd(t).map(e=>[{content:e[0],offset:e[1]}]);let{theme:i,colorMap:a}=e.setTheme(r),o=e.getLanguage(n.lang||`text`);if(n.grammarState){if(n.grammarState.lang!==o.name)throw new jl(`Grammar state language "${n.grammarState.lang}" does not match highlight language "${o.name}"`);if(!n.grammarState.themes.includes(i.name))throw new jl(`Grammar state themes "${n.grammarState.themes}" do not contain highlight theme "${i.name}"`)}return qd(t,o,i,a,n)}function Kd(...e){if(e.length===2)return zd(e[1]);let[t,n,r={}]=e,{lang:i=`text`,theme:a=t.getLoadedThemes()[0]}=r;if(yd(i)||xd(a))throw new jl(`Plain language does not have grammar state`);if(i===`ansi`)throw new jl(`ANSI language does not have grammar state`);let{theme:o,colorMap:s}=t.setTheme(a),c=t.getLanguage(i);return new Bd(Jd(n,c,o,s,r).stateStack,c.name,o.name)}function qd(e,t,n,r,i){let a=Jd(e,t,n,r,i),o=new Bd(a.stateStack,t.name,n.name);return Rd(a.tokens,o),a.tokens}function Jd(e,t,n,r,i){let a=hd(n,i),{tokenizeMaxLineLength:o=0,tokenizeTimeLimit:s=500}=i,c=wd(e),l=i.grammarState?Hd(i.grammarState,n.name)??md:i.grammarContextCode==null?md:Jd(i.grammarContextCode,t,n,r,{...i,grammarState:void 0,grammarContextCode:void 0}).stateStack,u=[],d=[];for(let e=0,f=c.length;e<f;e++){let[f,p]=c[e];if(f===``){u=[],d.push([]);continue}if(o>0&&f.length>=o){u=[],d.push([{content:f,offset:p,color:``,fontStyle:0}]);continue}let m,h,g;i.includeExplanation&&(m=t.tokenizeLine(f,l,s),h=m.tokens,g=0);let _=t.tokenizeLine2(f,l,s),v=_.tokens.length/2;for(let e=0;e<v;e++){let t=_.tokens[2*e],o=e+1<v?_.tokens[2*e+2]:f.length;if(t===o)continue;let s=_.tokens[2*e+1],c=gd(r[iu.getForeground(s)],a),l=iu.getFontStyle(s),d={content:f.substring(t,o),offset:p+t,color:c,fontStyle:l};if(i.includeExplanation){let e=[];if(i.includeExplanation!==`scopeName`)for(let t of n.settings){let n;switch(typeof t.scope){case`string`:n=t.scope.split(Ud).map(e=>e.trim());break;case`object`:n=t.scope;break;default:continue}e.push({settings:t,selectors:n.map(e=>e.split(Wd))})}d.explanation=[];let r=0;for(;t+r<o;){let t=h[g],n=f.substring(t.startIndex,t.endIndex);r+=n.length,d.explanation.push({content:n,scopes:i.includeExplanation===`scopeName`?Yd(t.scopes):Xd(e,t.scopes)}),g+=1}}u.push(d)}d.push(u),u=[],l=_.ruleStack}return{tokens:d,stateStack:l}}function Yd(e){return e.map(e=>({scopeName:e}))}function Xd(e,t){let n=[];for(let r=0,i=t.length;r<i;r++){let i=t[r];n[r]={scopeName:i,themeMatches:$d(e,i,t.slice(0,r))}}return n}function Zd(e,t){return e===t||t.substring(0,e.length)===e&&t[e.length]===`.`}function Qd(e,t,n){if(!Zd(e.at(-1),t))return!1;let r=e.length-2,i=n.length-1;for(;r>=0&&i>=0;)Zd(e[r],n[i])&&--r,--i;return r===-1}function $d(e,t,n){let r=[];for(let{selectors:i,settings:a}of e)for(let e of i)if(Qd(e,t,n)){r.push(a);break}return r}function ef(e,t,n,r=Gd){let i=Object.entries(n.themes).filter(e=>e[1]).map(e=>({color:e[0],theme:e[1]})),a=i.map(i=>{let a=r(e,t,{...n,theme:i.theme});return{tokens:a,state:zd(a),theme:typeof i.theme==`string`?i.theme:i.theme.name}}),o=tf(...a.map(e=>e.tokens)),s=o[0].map((e,t)=>e.map((e,r)=>{let a={content:e.content,variants:{},offset:e.offset};return`includeExplanation`in n&&n.includeExplanation&&(a.explanation=e.explanation),o.forEach((e,n)=>{let{content:o,explanation:s,offset:c,...l}=e[t][r];a.variants[i[n].color]=l}),a})),c=a[0].state?new Bd(Object.fromEntries(a.map(e=>[e.theme,e.state?.getInternalStack(e.theme)])),a[0].state.lang):void 0;return c&&Rd(s,c),s}function tf(...e){let t=e.map(()=>[]),n=e.length;for(let r=0;r<e[0].length;r++){let i=e.map(e=>e[r]),a=t.map(()=>[]);t.forEach((e,t)=>e.push(a[t]));let o=i.map(()=>0),s=i.map(e=>e[0]);for(;s.every(e=>e);){let e=Math.min(...s.map(e=>e.content.length));for(let t=0;t<n;t++){let n=s[t];n.content.length===e?(a[t].push(n),o[t]+=1,s[t]=i[t][o[t]]):(a[t].push({...n,content:n.content.slice(0,e)}),s[t]={...n,content:n.content.slice(e),offset:n.offset+e})}}}return t}var nf=/\s+/g;function rf(e,t){if(!t)return e;e.properties||={},e.properties.class||=[],typeof e.properties.class==`string`&&(e.properties.class=e.properties.class.split(nf)),Array.isArray(e.properties.class)||(e.properties.class=[]);let n=Array.isArray(t)?t:t.split(nf);for(let t of n)t&&!e.properties.class.includes(t)&&e.properties.class.push(t);return e}var af=/:?lang=["']([^"']+)["']/g,of=/(?:```|~~~)([\w-]+)/g,sf=/\\begin\{([\w-]+)\}/g,cf=/<script\s+(?:type|lang)=["']([^"']+)["']/gi;function lf(e){let t=wd(e,!0).map(([e])=>e);function n(n){if(n===e.length)return{line:t.length-1,character:t.at(-1).length};let r=n,i=0;for(let e of t){if(r<e.length)break;r-=e.length,i++}return{line:i,character:r}}function r(e,n){let r=0;for(let n=0;n<e;n++)r+=t[n].length;return r+=n,r}return{lines:t,indexToPos:n,posToIndex:r}}function uf(e,t,n){let r=new Set;for(let t of e.matchAll(af)){let e=t[1].toLowerCase().trim();e&&r.add(e)}for(let t of e.matchAll(of)){let e=t[1].toLowerCase().trim();e&&r.add(e)}for(let t of e.matchAll(sf)){let e=t[1].toLowerCase().trim();e&&r.add(e)}for(let t of e.matchAll(cf)){let e=t[1].toLowerCase().trim(),n=e.includes(`/`)?e.split(`/`).pop():e;n&&r.add(n)}if(!n)return[...r];let i=n.getBundledLanguages();return[...r].filter(e=>e&&i[e])}var df=[`color`,`background-color`];function ff(e,t){let n=0,r=[];for(let i of t)i>n&&r.push({...e,content:e.content.slice(n,i),offset:e.offset+n}),n=i;return n<e.content.length&&r.push({...e,content:e.content.slice(n),offset:e.offset+n}),r}function pf(e,t){let n=[...t instanceof Set?t:new Set(t)].sort((e,t)=>e-t);return n.length?e.map(e=>e.flatMap(e=>{let t=n.filter(t=>e.offset<t&&t<e.offset+e.content.length).map(t=>t-e.offset).sort((e,t)=>e-t);return t.length?ff(e,t):e})):e}function mf(e,t,n,r,i=`css-vars`){let a={content:e.content,explanation:e.explanation,offset:e.offset},o=t.map(t=>hf(e.variants[t])),s=new Set(o.flatMap(e=>Object.keys(e))),c={},l=(e,r)=>{let i=r===`color`?``:r===`background-color`?`-bg`:`-${r}`;return n+t[e]+(r===`color`?``:i)};return o.forEach((e,n)=>{for(let a of s){let s=e[a]||`inherit`;if(n===0&&r&&df.includes(a))if(r===`light-dark()`&&o.length>1){let e=t.findIndex(e=>e===`light`),r=t.findIndex(e=>e===`dark`);if(e===-1||r===-1)throw new jl('When using `defaultColor: "light-dark()"`, you must provide both `light` and `dark` themes');c[a]=`light-dark(${o[e][a]||`inherit`}, ${o[r][a]||`inherit`})`,i===`css-vars`&&(c[l(n,a)]=s)}else c[a]=s;else i===`css-vars`&&(c[l(n,a)]=s)}}),a.htmlStyle=c,a}function hf(e){let t={};if(e.color&&(t.color=e.color),e.bgColor&&(t[`background-color`]=e.bgColor),e.fontStyle){e.fontStyle&Ql.Italic&&(t[`font-style`]=`italic`),e.fontStyle&Ql.Bold&&(t[`font-weight`]=`bold`);let n=[];e.fontStyle&Ql.Underline&&n.push(`underline`),e.fontStyle&Ql.Strikethrough&&n.push(`line-through`),n.length&&(t[`text-decoration`]=n.join(` `))}return t}function gf(e){return typeof e==`string`?e:Object.entries(e).map(([e,t])=>`${e}:${t}`).join(`;`)}function _f(){let e=new WeakMap;function t(t){if(!e.has(t.meta)){let n=lf(t.source);function r(e){if(typeof e==`number`){if(e<0||e>t.source.length)throw new jl(`Invalid decoration offset: ${e}. Code length: ${t.source.length}`);return{...n.indexToPos(e),offset:e}}else{let t=n.lines[e.line];if(t===void 0)throw new jl(`Invalid decoration position ${JSON.stringify(e)}. Lines length: ${n.lines.length}`);let r=e.character;if(r<0&&(r=t.length+r),r<0||r>t.length)throw new jl(`Invalid decoration position ${JSON.stringify(e)}. Line ${e.line} length: ${t.length}`);return{...e,character:r,offset:n.posToIndex(e.line,r)}}}let i=(t.options.decorations||[]).map(e=>({...e,start:r(e.start),end:r(e.end)}));vf(i),e.set(t.meta,{decorations:i,converter:n,source:t.source})}return e.get(t.meta)}return{name:`shiki:decorations`,tokens(e){if(this.options.decorations?.length)return pf(e,t(this).decorations.flatMap(e=>[e.start.offset,e.end.offset]))},code(e){if(!this.options.decorations?.length)return;let n=t(this),r=[...e.children].filter(e=>e.type===`element`&&e.tagName===`span`);if(r.length!==n.converter.lines.length)throw new jl(`Number of lines in code element (${r.length}) does not match the number of lines in the source (${n.converter.lines.length}). Failed to apply decorations.`);function i(e,t,n,i){let a=r[e],s=``,c=-1,l=-1;if(t===0&&(c=0),n===0&&(l=0),n===1/0&&(l=a.children.length),c===-1||l===-1)for(let e=0;e<a.children.length;e++)s+=yf(a.children[e]),c===-1&&s.length===t&&(c=e+1),l===-1&&s.length===n&&(l=e+1);if(c===-1)throw new jl(`Failed to find start index for decoration ${JSON.stringify(i.start)}`);if(l===-1)throw new jl(`Failed to find end index for decoration ${JSON.stringify(i.end)}`);let u=a.children.slice(c,l);if(!i.alwaysWrap&&u.length===a.children.length)o(a,i,`line`);else if(!i.alwaysWrap&&u.length===1&&u[0].type===`element`)o(u[0],i,`token`);else{let e={type:`element`,tagName:`span`,properties:{},children:u};o(e,i,`wrapper`),a.children.splice(c,u.length,e)}}function a(e,t){r[e]=o(r[e],t,`line`)}function o(e,t,n){let r=t.properties||{},i=t.transform||(e=>e);return e.tagName=t.tagName||`span`,e.properties={...e.properties,...r,class:e.properties.class},t.properties?.class&&rf(e,t.properties.class),e=i(e,n)||e,e}let s=[],c=n.decorations.sort((e,t)=>t.start.offset-e.start.offset||e.end.offset-t.end.offset);for(let e of c){let{start:t,end:n}=e;if(t.line===n.line)i(t.line,t.character,n.character,e);else if(t.line<n.line){i(t.line,t.character,1/0,e);for(let r=t.line+1;r<n.line;r++)s.unshift(()=>a(r,e));i(n.line,0,n.character,e)}}s.forEach(e=>e())}}}function vf(e){for(let t=0;t<e.length;t++){let n=e[t];if(n.start.offset>n.end.offset)throw new jl(`Invalid decoration range: ${JSON.stringify(n.start)} - ${JSON.stringify(n.end)}`);for(let r=t+1;r<e.length;r++){let t=e[r],i=n.start.offset<=t.start.offset&&t.start.offset<n.end.offset,a=n.start.offset<t.end.offset&&t.end.offset<=n.end.offset,o=t.start.offset<=n.start.offset&&n.start.offset<t.end.offset,s=t.start.offset<n.end.offset&&n.end.offset<=t.end.offset;if(i||a||o||s){if(i&&a||o&&s||o&&n.start.offset===n.end.offset||a&&t.start.offset===t.end.offset)continue;throw new jl(`Decorations ${JSON.stringify(n.start)} and ${JSON.stringify(t.start)} intersect.`)}}}}function yf(e){return e.type===`text`?e.value:e.type===`element`?e.children.map(yf).join(``):``}var bf=[_f()];function xf(e){let t=Sf(e.transformers||[]);return[...t.pre,...t.normal,...t.post,...bf]}function Sf(e){let t=[],n=[],r=[];for(let i of e)switch(i.enforce){case`pre`:t.push(i);break;case`post`:n.push(i);break;default:r.push(i)}return{pre:t,post:n,normal:r}}var Cf=[`black`,`red`,`green`,`yellow`,`blue`,`magenta`,`cyan`,`white`,`brightBlack`,`brightRed`,`brightGreen`,`brightYellow`,`brightBlue`,`brightMagenta`,`brightCyan`,`brightWhite`],wf={1:`bold`,2:`dim`,3:`italic`,4:`underline`,7:`reverse`,8:`hidden`,9:`strikethrough`};function Tf(e,t){let n=e.indexOf(`\x1B`,t);if(n!==-1&&e[n+1]===`[`){let t=e.indexOf(`m`,n);if(t!==-1)return{sequence:e.substring(n+2,t).split(`;`),startPosition:n,position:t+1}}return{position:e.length}}function Ef(e){let t=e.shift();if(t===`2`){let t=e.splice(0,3).map(e=>Number.parseInt(e));return t.length!==3||t.some(e=>Number.isNaN(e))?void 0:{type:`rgb`,rgb:t}}else if(t===`5`){let t=e.shift();if(t)return{type:`table`,index:Number(t)}}}function Df(e){let t=[];for(;e.length>0;){let n=e.shift();if(!n)continue;let r=Number.parseInt(n);if(!Number.isNaN(r))if(r===0)t.push({type:`resetAll`});else if(r<=9)wf[r]&&t.push({type:`setDecoration`,value:wf[r]});else if(r<=29){let e=wf[r-20];e&&(t.push({type:`resetDecoration`,value:e}),e===`dim`&&t.push({type:`resetDecoration`,value:`bold`}))}else if(r<=37)t.push({type:`setForegroundColor`,value:{type:`named`,name:Cf[r-30]}});else if(r===38){let n=Ef(e);n&&t.push({type:`setForegroundColor`,value:n})}else if(r===39)t.push({type:`resetForegroundColor`});else if(r<=47)t.push({type:`setBackgroundColor`,value:{type:`named`,name:Cf[r-40]}});else if(r===48){let n=Ef(e);n&&t.push({type:`setBackgroundColor`,value:n})}else r===49?t.push({type:`resetBackgroundColor`}):r===53?t.push({type:`setDecoration`,value:`overline`}):r===55?t.push({type:`resetDecoration`,value:`overline`}):r>=90&&r<=97?t.push({type:`setForegroundColor`,value:{type:`named`,name:Cf[r-90+8]}}):r>=100&&r<=107&&t.push({type:`setBackgroundColor`,value:{type:`named`,name:Cf[r-100+8]}})}return t}function Of(){let e=null,t=null,n=new Set;return{parse(r){let i=[],a=0;do{let o=Tf(r,a),s=o.sequence?r.substring(a,o.startPosition):r.substring(a);if(s.length>0&&i.push({value:s,foreground:e,background:t,decorations:new Set(n)}),o.sequence){let r=Df(o.sequence);for(let i of r)i.type===`resetAll`?(e=null,t=null,n.clear()):i.type===`resetForegroundColor`?e=null:i.type===`resetBackgroundColor`?t=null:i.type===`resetDecoration`&&n.delete(i.value);for(let i of r)i.type===`setForegroundColor`?e=i.value:i.type===`setBackgroundColor`?t=i.value:i.type===`setDecoration`&&n.add(i.value)}a=o.position}while(a<r.length);return i}}}var kf={black:`#000000`,red:`#bb0000`,green:`#00bb00`,yellow:`#bbbb00`,blue:`#0000bb`,magenta:`#ff00ff`,cyan:`#00bbbb`,white:`#eeeeee`,brightBlack:`#555555`,brightRed:`#ff5555`,brightGreen:`#00ff00`,brightYellow:`#ffff55`,brightBlue:`#5555ff`,brightMagenta:`#ff55ff`,brightCyan:`#55ffff`,brightWhite:`#ffffff`};function Af(e=kf){function t(t){return e[t]}function n(e){return`#${e.map(e=>Math.max(0,Math.min(e,255)).toString(16).padStart(2,`0`)).join(``)}`}let r;function i(){if(r)return r;r=[];for(let e=0;e<Cf.length;e++)r.push(t(Cf[e]));let e=[0,95,135,175,215,255];for(let t=0;t<6;t++)for(let i=0;i<6;i++)for(let a=0;a<6;a++)r.push(n([e[t],e[i],e[a]]));let i=8;for(let e=0;e<24;e++,i+=10)r.push(n([i,i,i]));return r}function a(e){return i()[e]}function o(e){switch(e.type){case`named`:return t(e.name);case`rgb`:return n(e.rgb);case`table`:return a(e.index)}}return{value:o}}var jf=/#([0-9a-f]{3,8})/i,Mf=/var\((--[\w-]+-ansi-[\w-]+)\)/,Nf={black:`#000000`,red:`#cd3131`,green:`#0DBC79`,yellow:`#E5E510`,blue:`#2472C8`,magenta:`#BC3FBC`,cyan:`#11A8CD`,white:`#E5E5E5`,brightBlack:`#666666`,brightRed:`#F14C4C`,brightGreen:`#23D18B`,brightYellow:`#F5F543`,brightBlue:`#3B8EEA`,brightMagenta:`#D670D6`,brightCyan:`#29B8DB`,brightWhite:`#FFFFFF`};function Pf(e,t,n){let r=hd(e,n),i=wd(t),a=Af(Object.fromEntries(Cf.map(t=>{let n=`terminal.ansi${t[0].toUpperCase()}${t.substring(1)}`;return[t,e.colors?.[n]||Nf[t]]}))),o=Of();return i.map(t=>o.parse(t[0]).map(n=>{let i,o;n.decorations.has(`reverse`)?(i=n.background?a.value(n.background):e.bg,o=n.foreground?a.value(n.foreground):e.fg):(i=n.foreground?a.value(n.foreground):e.fg,o=n.background?a.value(n.background):void 0),i=gd(i,r),o=gd(o,r),n.decorations.has(`dim`)&&(i=Ff(i));let s=Ql.None;return n.decorations.has(`bold`)&&(s|=Ql.Bold),n.decorations.has(`italic`)&&(s|=Ql.Italic),n.decorations.has(`underline`)&&(s|=Ql.Underline),n.decorations.has(`strikethrough`)&&(s|=Ql.Strikethrough),{content:n.value,offset:t[1],color:i,bgColor:o,fontStyle:s}}))}function Ff(e){let t=e.match(jf);if(t){let e=t[1];if(e.length===8){let t=Math.round(Number.parseInt(e.slice(6,8),16)/2).toString(16).padStart(2,`0`);return`#${e.slice(0,6)}${t}`}else if(e.length===6)return`#${e}80`;else if(e.length===4){let t=e[0],n=e[1],r=e[2],i=e[3];return`#${t}${t}${n}${n}${r}${r}${Math.round(Number.parseInt(`${i}${i}`,16)/2).toString(16).padStart(2,`0`)}`}else if(e.length===3){let t=e[0],n=e[1],r=e[2];return`#${t}${t}${n}${n}${r}${r}80`}}let n=e.match(Mf);return n?`var(${n[1]}-dim)`:e}function If(e,t,n={}){let r=e.resolveLangAlias(n.lang||`text`),{theme:i=e.getLoadedThemes()[0]}=n;if(!yd(r)&&!xd(i)&&r===`ansi`){let{theme:r}=e.setTheme(i);return Pf(r,t,n)}return Gd(e,t,n)}function Lf(e,t,n){let r,i,a,o,s,c;if(`themes`in n){let{defaultColor:l=`light`,cssVariablePrefix:u=`--shiki-`,colorsRendering:d=`css-vars`}=n,f=Object.entries(n.themes).filter(e=>e[1]).map(e=>({color:e[0],theme:e[1]})).sort((e,t)=>e.color===l?-1:+(t.color===l));if(f.length===0)throw new jl("`themes` option must not be empty");let p=ef(e,t,n,If);if(c=zd(p),l&&l!==`light-dark()`&&!f.some(e=>e.color===l))throw new jl(`\`themes\` option must contain the defaultColor key \`${l}\``);let m=f.map(t=>e.getTheme(t.theme)),h=f.map(e=>e.color);a=p.map(e=>e.map(e=>mf(e,h,u,l,d))),c&&Rd(a,c);let g=f.map(e=>hd(e.theme,n));i=Rf(f,m,g,u,l,`fg`,d),r=Rf(f,m,g,u,l,`bg`,d),o=`shiki-themes ${m.map(e=>e.name).join(` `)}`,s=l?void 0:[i,r].join(`;`)}else if(`theme`in n){let s=hd(n.theme,n);a=If(e,t,n);let l=e.getTheme(n.theme);r=gd(l.bg,s),i=gd(l.fg,s),o=l.name,c=zd(a)}else throw new jl("Invalid options, either `theme` or `themes` must be provided");return{tokens:a,fg:i,bg:r,themeName:o,rootStyle:s,grammarState:c}}function Rf(e,t,n,r,i,a,o){return e.map((s,c)=>{let l=gd(t[c][a],n[c])||`inherit`,u=`${r+s.color}${a===`bg`?`-bg`:``}:${l}`;if(c===0&&i){if(i===`light-dark()`&&e.length>1){let r=e.findIndex(e=>e.color===`light`),i=e.findIndex(e=>e.color===`dark`);if(r===-1||i===-1)throw new jl('When using `defaultColor: "light-dark()"`, you must provide both `light` and `dark` themes');return`light-dark(${gd(t[r][a],n[r])||`inherit`}, ${gd(t[i][a],n[i])||`inherit`});${u}`}return l}return o===`css-vars`?u:null}).filter(e=>!!e).join(`;`)}var zf=/^\s+$/,Bf=/^(\s*)(.*?)(\s*)$/;function Vf(e,t,n,r={meta:{},options:n,codeToHast:(t,n)=>Vf(e,t,n),codeToTokens:(t,n)=>Lf(e,t,n)}){let i=t;for(let e of xf(n))i=e.preprocess?.call(r,i,n)||i;let{tokens:a,fg:o,bg:s,themeName:c,rootStyle:l,grammarState:u}=Lf(e,i,n),{mergeWhitespaces:d=!0,mergeSameStyleTokens:f=!1}=n;d===!0?a=Uf(a):d===`never`&&(a=Wf(a)),f&&(a=Gf(a));let p={...r,get source(){return i}};for(let e of xf(n))a=e.tokens?.call(p,a)||a;return Hf(a,{...n,fg:o,bg:s,themeName:c,rootStyle:n.rootStyle===!1?!1:n.rootStyle??l},p,u)}function Hf(e,t,n,r=zd(e)){let i=xf(t),a=[],o={type:`root`,children:[]},{structure:s=`classic`,tabindex:c=`0`}=t,l={class:`shiki ${t.themeName||``}`};t.rootStyle!==!1&&(t.rootStyle==null?l.style=`background-color:${t.bg};color:${t.fg}`:l.style=t.rootStyle),c!==!1&&c!=null&&(l.tabindex=c.toString());for(let[e,n]of Object.entries(t.meta||{}))e.startsWith(`_`)||(l[e]=n);let u={type:`element`,tagName:`pre`,properties:l,children:[],data:t.data},d={type:`element`,tagName:`code`,properties:{},children:a},f=[],p={...n,structure:s,addClassToHast:rf,get source(){return n.source},get tokens(){return e},get options(){return t},get root(){return o},get pre(){return u},get code(){return d},get lines(){return f}};if(e.forEach((e,t)=>{t&&(s===`inline`?o.children.push({type:`element`,tagName:`br`,properties:{},children:[]}):s===`classic`&&a.push({type:`text`,value:`
1417
+ `}));let n={type:`element`,tagName:`span`,properties:{class:`line`},children:[]},r=0;for(let a of e){let e={type:`element`,tagName:`span`,properties:{...a.htmlAttrs},children:[{type:`text`,value:a.content}]},c=gf(a.htmlStyle||hf(a));c&&(e.properties.style=c);for(let o of i)e=o?.span?.call(p,e,t+1,r,n,a)||e;s===`inline`?o.children.push(e):s===`classic`&&n.children.push(e),r+=a.content.length}if(s===`classic`){for(let e of i)n=e?.line?.call(p,n,t+1)||n;f.push(n),a.push(n)}else s===`inline`&&f.push(n)}),s===`classic`){for(let e of i)d=e?.code?.call(p,d)||d;u.children.push(d);for(let e of i)u=e?.pre?.call(p,u)||u;o.children.push(u)}else if(s===`inline`){let e=[],t={type:`element`,tagName:`span`,properties:{class:`line`},children:[]};for(let n of o.children)n.type===`element`&&n.tagName===`br`?(e.push(t),t={type:`element`,tagName:`span`,properties:{class:`line`},children:[]}):(n.type===`element`||n.type===`text`)&&t.children.push(n);e.push(t);let n={type:`element`,tagName:`code`,properties:{},children:e};for(let e of i)n=e?.code?.call(p,n)||n;o.children=[];for(let e=0;e<n.children.length;e++){e>0&&o.children.push({type:`element`,tagName:`br`,properties:{},children:[]});let t=n.children[e];t.type===`element`&&o.children.push(...t.children)}}let m=o;for(let e of i)m=e?.root?.call(p,m)||m;return r&&Rd(m,r),m}function Uf(e){return e.map(e=>{let t=[],n=``,r;return e.forEach((i,a)=>{let o=!(i.fontStyle&&(i.fontStyle&Ql.Underline||i.fontStyle&Ql.Strikethrough));o&&zf.test(i.content)&&e[a+1]?(r===void 0&&(r=i.offset),n+=i.content):n?(o?t.push({...i,offset:r,content:n+i.content}):t.push({content:n,offset:r},i),r=void 0,n=``):t.push(i)}),t})}function Wf(e){return e.map(e=>e.flatMap(e=>{if(zf.test(e.content))return e;let t=e.content.match(Bf);if(!t)return e;let[,n,r,i]=t;if(!n&&!i)return e;let a=[{...e,offset:e.offset+n.length,content:r}];return n&&a.unshift({content:n,offset:e.offset}),i&&a.push({content:i,offset:e.offset+n.length+r.length}),a}))}function Gf(e){return e.map(e=>{let t=[];for(let n of e){if(t.length===0){t.push({...n});continue}let e=t.at(-1),r=gf(e.htmlStyle||hf(e)),i=gf(n.htmlStyle||hf(n)),a=e.fontStyle&&(e.fontStyle&Ql.Underline||e.fontStyle&Ql.Strikethrough),o=n.fontStyle&&(n.fontStyle&Ql.Underline||n.fontStyle&Ql.Strikethrough);!a&&!o&&r===i?e.content+=n.content:t.push({...n})}return t})}var Kf=Yo;function qf(e,t,n){let r={meta:{},options:n,codeToHast:(t,n)=>Vf(e,t,n),codeToTokens:(t,n)=>Lf(e,t,n)},i=Kf(Vf(e,t,n,r));for(let e of xf(n))i=e.postprocess?.call(r,i,n)||i;return i}async function Jf(e){let t=await Id(e);return{getLastGrammarState:(...e)=>Kd(t,...e),codeToTokensBase:(e,n)=>If(t,e,n),codeToTokensWithThemes:(e,n)=>ef(t,e,n),codeToTokens:(e,n)=>Lf(t,e,n),codeToHast:(e,n)=>Vf(t,e,n),codeToHtml:(e,n)=>qf(t,e,n),getBundledLanguages:()=>({}),getBundledThemes:()=>({}),...t,getInternalContext:()=>t}}function Yf(e){let t=e.langs,n=e.themes,r=e.engine;async function i(e){function i(n){if(typeof n==`string`){if(n=e.langAlias?.[n]||n,bd(n))return[];let r=t[n];if(!r)throw new jl(`Language \`${n}\` is not included in this bundle. You may want to load it from external source.`);return r}return n}function a(e){if(Sd(e))return`none`;if(typeof e==`string`){let t=n[e];if(!t)throw new jl(`Theme \`${e}\` is not included in this bundle. You may want to load it from external source.`);return t}return e}let o=(e.themes??[]).map(e=>a(e)),s=(e.langs??[]).map(e=>i(e)),c=await Jf({engine:e.engine??r(),...e,themes:o,langs:s});return{...c,loadLanguage(...e){return c.loadLanguage(...e.map(i))},loadTheme(...e){return c.loadTheme(...e.map(a))},getBundledLanguages(){return t},getBundledThemes(){return n}}}return i}function Xf(e){let t;async function n(n={}){if(t){let e=await t;return await Promise.all([e.loadTheme(...n.themes||[]),e.loadLanguage(...n.langs||[])]),e}else{t=e({...n,themes:[],langs:[]});let r=await t;return await Promise.all([r.loadTheme(...n.themes||[]),r.loadLanguage(...n.langs||[])]),r}}return n}function Zf(e,t){let n=Xf(e);async function r(e,r){let i=await n({langs:[r.lang],themes:`theme`in r?[r.theme]:Object.values(r.themes)}),a=await t?.guessEmbeddedLanguages?.(e,r.lang,i);return a&&await i.loadLanguage(...a),i}return{getSingletonHighlighter(e){return n(e)},async codeToHtml(e,t){return(await r(e,t)).codeToHtml(e,t)},async codeToHast(e,t){return(await r(e,t)).codeToHast(e,t)},async codeToTokens(e,t){return(await r(e,t)).codeToTokens(e,t)},async codeToTokensBase(e,t){return(await r(e,t)).codeToTokensBase(e,t)},async codeToTokensWithThemes(e,t){return(await r(e,t)).codeToTokensWithThemes(e,t)},async getLastGrammarState(e,t){return(await n({langs:[t.lang],themes:[t.theme]})).getLastGrammarState(e,t)}}}var Qf=Yf({langs:Kc,themes:Al,engine:()=>(0,kl.createOnigurumaEngine)(G(()=>import(`./wasm-BnjxR4X6.js`),[]))}),{codeToHtml:$f,codeToHast:ep,codeToTokens:tp,codeToTokensBase:np,codeToTokensWithThemes:rp,getSingletonHighlighter:ip,getLastGrammarState:ap}=Zf(Qf,{guessEmbeddedLanguages:uf}),op=4294967295,sp=class{patterns;options;regexps;constructor(e,t={}){this.patterns=e,this.options=t;let{forgiving:n=!1,cache:r,regexConstructor:i}=t;if(!i)throw Error("Option `regexConstructor` is not provided");this.regexps=e.map(e=>{if(typeof e!=`string`)return e;let t=r?.get(e);if(t){if(t instanceof RegExp)return t;if(n)return null;throw t}try{let t=i(e);return r?.set(e,t),t}catch(t){if(r?.set(e,t),n)return null;throw t}})}findNextMatchSync(e,t,n){let r=typeof e==`string`?e:e.content,i=[];function a(e,t,n=0){return{index:e,captureIndices:t.indices.map(e=>e==null?{start:op,end:op,length:0}:{start:e[0]+n,end:e[1]+n,length:e[1]-e[0]})}}for(let e=0;e<this.regexps.length;e++){let n=this.regexps[e];if(n)try{n.lastIndex=t;let o=n.exec(r);if(!o)continue;if(o.index===t)return a(e,o,0);i.push([e,o,0])}catch(e){if(this.options.forgiving)continue;throw e}}if(i.length){let e=Math.min(...i.map(e=>e[1].index));for(let[t,n,r]of i)if(n.index===e)return a(t,n,r)}return null}};function cp(e){if([...e].length!==1)throw Error(`Expected "${e}" to be a single code point`);return e.codePointAt(0)}function lp(e,t,n){return e.has(t)||e.set(t,n),e.get(t)}var up=new Set([`alnum`,`alpha`,`ascii`,`blank`,`cntrl`,`digit`,`graph`,`lower`,`print`,`punct`,`space`,`upper`,`word`,`xdigit`]),dp=String.raw;function fp(e,t){if(e==null)throw Error(t??`Value expected`);return e}var pp=dp`\[\^?`,mp=`c.? | C(?:-.?)?|${dp`[pP]\{(?:\^?[-\x20_]*[A-Za-z][-\x20\w]*\})?`}|${dp`x[89A-Fa-f]\p{AHex}(?:\\x[89A-Fa-f]\p{AHex})*`}|${dp`u(?:\p{AHex}{4})? | x\{[^\}]*\}? | x\p{AHex}{0,2}`}|${dp`o\{[^\}]*\}?`}|${dp`\d{1,3}`}`,hp=/[?*+][?+]?|\{(?:\d+(?:,\d*)?|,\d+)\}\??/,gp=new RegExp(dp`
1418
+ \\ (?:
1419
+ ${mp}
1420
+ | [gk]<[^>]*>?
1421
+ | [gk]'[^']*'?
1422
+ | .
1423
+ )
1424
+ | \( (?:
1425
+ \? (?:
1426
+ [:=!>({]
1427
+ | <[=!]
1428
+ | <[^>]*>
1429
+ | '[^']*'
1430
+ | ~\|?
1431
+ | #(?:[^)\\]|\\.?)*
1432
+ | [^:)]*[:)]
1433
+ )?
1434
+ | \*[^\)]*\)?
1435
+ )?
1436
+ | (?:${hp.source})+
1437
+ | ${pp}
1438
+ | .
1439
+ `.replace(/\s+/g,``),`gsu`),_p=new RegExp(dp`
1440
+ \\ (?:
1441
+ ${mp}
1442
+ | .
1443
+ )
1444
+ | \[:(?:\^?\p{Alpha}+|\^):\]
1445
+ | ${pp}
1446
+ | &&
1447
+ | .
1448
+ `.replace(/\s+/g,``),`gsu`);function vp(e,t={}){let n={flags:``,...t,rules:{captureGroup:!1,singleline:!1,...t.rules}};if(typeof e!=`string`)throw Error(`String expected as pattern`);let r=Jp(n.flags),i=[r.extended],a={captureGroup:n.rules.captureGroup,getCurrentModX(){return i.at(-1)},numOpenGroups:0,popModX(){i.pop()},pushModX(e){i.push(e)},replaceCurrentModX(e){i[i.length-1]=e},singleline:n.rules.singleline},o=[],s;for(gp.lastIndex=0;s=gp.exec(e);){let t=yp(a,e,s[0],gp.lastIndex);t.tokens?o.push(...t.tokens):t.token&&o.push(t.token),t.lastIndex!==void 0&&(gp.lastIndex=t.lastIndex)}let c=[],l=0;o.filter(e=>e.type===`GroupOpen`).forEach(e=>{e.kind===`capturing`?e.number=++l:e.raw===`(`&&c.push(e)}),l||c.forEach((e,t)=>{e.kind=`capturing`,e.number=t+1});let u=l||c.length;return{tokens:o.map(e=>e.type===`EscapedNumber`?Xp(e,u):e).flat(),flags:r}}function yp(e,t,n,r){let[i,a]=n;if(n===`[`||n===`[^`){let e=bp(t,n,r);return{tokens:e.tokens,lastIndex:e.lastIndex}}if(i===`\\`){if(`AbBGyYzZ`.includes(a))return{token:wp(n,n)};if(/^\\g[<']/.test(n)){if(!/^\\g(?:<[^>]+>|'[^']+')$/.test(n))throw Error(`Invalid group name "${n}"`);return{token:Rp(n)}}if(/^\\k[<']/.test(n)){if(!/^\\k(?:<[^>]+>|'[^']+')$/.test(n))throw Error(`Invalid group name "${n}"`);return{token:Tp(n)}}if(a===`K`)return{token:Mp(`keep`,n)};if(a===`N`||a===`R`)return{token:jp(`newline`,n,{negate:a===`N`})};if(a===`O`)return{token:jp(`any`,n)};if(a===`X`)return{token:jp(`text_segment`,n)};let e=Sp(n,{inCharClass:!1});return Array.isArray(e)?{tokens:e}:{token:e}}if(i===`(`){if(a===`*`)return{token:Up(n)};if(n===`(?{`)throw Error(`Unsupported callout "${n}"`);if(n.startsWith(`(?#`)){if(t[r]!==`)`)throw Error(`Unclosed comment group "(?#"`);return{lastIndex:r+1}}if(/^\(\?[-imx]+[:)]$/.test(n))return{token:Hp(n,e)};if(e.pushModX(e.getCurrentModX()),e.numOpenGroups++,n===`(`&&!e.captureGroup||n===`(?:`)return{token:Fp(`group`,n)};if(n===`(?>`)return{token:Fp(`atomic`,n)};if(n===`(?=`||n===`(?!`||n===`(?<=`||n===`(?<!`)return{token:Fp(n[2]===`<`?`lookbehind`:`lookahead`,n,{negate:n.endsWith(`!`)})};if(n===`(`&&e.captureGroup||n.startsWith(`(?<`)&&n.endsWith(`>`)||n.startsWith(`(?'`)&&n.endsWith(`'`))return{token:Fp(`capturing`,n,{...n!==`(`&&{name:n.slice(3,-1)}})};if(n.startsWith(`(?~`)){if(n===`(?~|`)throw Error(`Unsupported absence function kind "${n}"`);return{token:Fp(`absence_repeater`,n)}}throw Error(n===`(?(`?`Unsupported conditional "${n}"`:`Invalid or unsupported group option "${n}"`)}if(n===`)`){if(e.popModX(),e.numOpenGroups--,e.numOpenGroups<0)throw Error(`Unmatched ")"`);return{token:Pp(n)}}if(e.getCurrentModX()){if(n===`#`){let e=t.indexOf(`
1449
+ `,r);return{lastIndex:e===-1?t.length:e}}if(/^\s$/.test(n)){let e=/\s+/y;return e.lastIndex=r,{lastIndex:e.exec(t)?e.lastIndex:r}}}return n===`.`?{token:jp(`dot`,n)}:n===`^`||n===`$`?{token:wp(e.singleline?{"^":dp`\A`,$:dp`\Z`}[n]:n,n)}:n===`|`?{token:Cp(n)}:hp.test(n)?{tokens:Zp(n)}:{token:Ep(cp(n),n)}}function bp(e,t,n){let r=[Ap(t[1]===`^`,t)],i=1,a;for(_p.lastIndex=n;a=_p.exec(e);){let e=a[0];if(e[0]===`[`&&e[1]!==`:`)i++,r.push(Ap(e[1]===`^`,e));else if(e===`]`){if(r.at(-1).type===`CharacterClassOpen`)r.push(Ep(93,e));else if(i--,r.push(Dp(e)),!i)break}else{let t=xp(e);Array.isArray(t)?r.push(...t):r.push(t)}}return{tokens:r,lastIndex:_p.lastIndex||e.length}}function xp(e){if(e[0]===`\\`)return Sp(e,{inCharClass:!0});if(e[0]===`[`){let t=/\[:(?<negate>\^?)(?<name>[a-z]+):\]/.exec(e);if(!t||!up.has(t.groups.name))throw Error(`Invalid POSIX class "${e}"`);return jp(`posix`,e,{value:t.groups.name,negate:!!t.groups.negate})}return e===`-`?Op(e):e===`&&`?kp(e):Ep(cp(e),e)}function Sp(e,{inCharClass:t}){let n=e[1];if(n===`c`||n===`C`)return Vp(e);if(`dDhHsSwW`.includes(n))return Gp(e);if(e.startsWith(dp`\o{`))throw Error(`Incomplete, invalid, or unsupported octal code point "${e}"`);if(/^\\[pP]\{/.test(e)){if(e.length===3)throw Error(`Incomplete or invalid Unicode property "${e}"`);return Kp(e)}if(/^\\x[89A-Fa-f]\p{AHex}/u.test(e))try{let t=e.split(/\\x/).slice(1).map(e=>parseInt(e,16)),n=new TextDecoder(`utf-8`,{ignoreBOM:!0,fatal:!0}).decode(new Uint8Array(t)),r=new TextEncoder;return[...n].map(e=>{let t=[...r.encode(e)].map(e=>`\\x${e.toString(16)}`).join(``);return Ep(cp(e),t)})}catch{throw Error(`Multibyte code "${e}" incomplete or invalid in Oniguruma`)}if(n===`u`||n===`x`)return Ep(Yp(e),e);if(Bp.has(n))return Ep(Bp.get(n),e);if(/\d/.test(n))return Np(t,e);if(e===`\\`)throw Error(dp`Incomplete escape "\"`);if(n===`M`)throw Error(`Unsupported meta "${e}"`);if([...e].length===2)return Ep(e.codePointAt(1),e);throw Error(`Unexpected escape "${e}"`)}function Cp(e){return{type:`Alternator`,raw:e}}function wp(e,t){return{type:`Assertion`,kind:e,raw:t}}function Tp(e){return{type:`Backreference`,raw:e}}function Ep(e,t){return{type:`Character`,value:e,raw:t}}function Dp(e){return{type:`CharacterClassClose`,raw:e}}function Op(e){return{type:`CharacterClassHyphen`,raw:e}}function kp(e){return{type:`CharacterClassIntersector`,raw:e}}function Ap(e,t){return{type:`CharacterClassOpen`,negate:e,raw:t}}function jp(e,t,n={}){return{type:`CharacterSet`,kind:e,...n,raw:t}}function Mp(e,t,n={}){return e===`keep`?{type:`Directive`,kind:e,raw:t}:{type:`Directive`,kind:e,flags:fp(n.flags),raw:t}}function Np(e,t){return{type:`EscapedNumber`,inCharClass:e,raw:t}}function Pp(e){return{type:`GroupClose`,raw:e}}function Fp(e,t,n={}){return{type:`GroupOpen`,kind:e,...n,raw:t}}function Ip(e,t,n,r){return{type:`NamedCallout`,kind:e,tag:t,arguments:n,raw:r}}function Lp(e,t,n,r){return{type:`Quantifier`,kind:e,min:t,max:n,raw:r}}function Rp(e){return{type:`Subroutine`,raw:e}}var zp=new Set([`COUNT`,`CMP`,`ERROR`,`FAIL`,`MAX`,`MISMATCH`,`SKIP`,`TOTAL_COUNT`]),Bp=new Map([[`a`,7],[`b`,8],[`e`,27],[`f`,12],[`n`,10],[`r`,13],[`t`,9],[`v`,11]]);function Vp(e){let t=e[1]===`c`?e[2]:e[3];if(!t||!/[A-Za-z]/.test(t))throw Error(`Unsupported control character "${e}"`);return Ep(cp(t.toUpperCase())-64,e)}function Hp(e,t){let{on:n,off:r}=/^\(\?(?<on>[imx]*)(?:-(?<off>[-imx]*))?/.exec(e).groups;r??=``;let i=(t.getCurrentModX()||n.includes(`x`))&&!r.includes(`x`),a=qp(n),o=qp(r),s={};if(a&&(s.enable=a),o&&(s.disable=o),e.endsWith(`)`))return t.replaceCurrentModX(i),Mp(`flags`,e,{flags:s});if(e.endsWith(`:`))return t.pushModX(i),t.numOpenGroups++,Fp(`group`,e,{...(a||o)&&{flags:s}});throw Error(`Unexpected flag modifier "${e}"`)}function Up(e){let t=/\(\*(?<name>[A-Za-z_]\w*)?(?:\[(?<tag>(?:[A-Za-z_]\w*)?)\])?(?:\{(?<args>[^}]*)\})?\)/.exec(e);if(!t)throw Error(`Incomplete or invalid named callout "${e}"`);let{name:n,tag:r,args:i}=t.groups;if(!n)throw Error(`Invalid named callout "${e}"`);if(r===``)throw Error(`Named callout tag with empty value not allowed "${e}"`);let a=i?i.split(`,`).filter(e=>e!==``).map(e=>/^[+-]?\d+$/.test(e)?+e:e):[],[o,s,c]=a,l=zp.has(n)?n.toLowerCase():`custom`;switch(l){case`fail`:case`mismatch`:case`skip`:if(a.length>0)throw Error(`Named callout arguments not allowed "${a}"`);break;case`error`:if(a.length>1)throw Error(`Named callout allows only one argument "${a}"`);if(typeof o==`string`)throw Error(`Named callout argument must be a number "${o}"`);break;case`max`:if(!a.length||a.length>2)throw Error(`Named callout must have one or two arguments "${a}"`);if(typeof o==`string`&&!/^[A-Za-z_]\w*$/.test(o))throw Error(`Named callout argument one must be a tag or number "${o}"`);if(a.length===2&&(typeof s==`number`||!/^[<>X]$/.test(s)))throw Error(`Named callout optional argument two must be '<', '>', or 'X' "${s}"`);break;case`count`:case`total_count`:if(a.length>1)throw Error(`Named callout allows only one argument "${a}"`);if(a.length===1&&(typeof o==`number`||!/^[<>X]$/.test(o)))throw Error(`Named callout optional argument must be '<', '>', or 'X' "${o}"`);break;case`cmp`:if(a.length!==3)throw Error(`Named callout must have three arguments "${a}"`);if(typeof o==`string`&&!/^[A-Za-z_]\w*$/.test(o))throw Error(`Named callout argument one must be a tag or number "${o}"`);if(typeof s==`number`||!/^(?:[<>!=]=|[<>])$/.test(s))throw Error(`Named callout argument two must be '==', '!=', '>', '<', '>=', or '<=' "${s}"`);if(typeof c==`string`&&!/^[A-Za-z_]\w*$/.test(c))throw Error(`Named callout argument three must be a tag or number "${c}"`);break;case`custom`:throw Error(`Undefined callout name "${n}"`);default:throw Error(`Unexpected named callout kind "${l}"`)}return Ip(l,r??null,i?.split(`,`)??null,e)}function Wp(e){let t=null,n,r;if(e[0]===`{`){let{minStr:i,maxStr:a}=/^\{(?<minStr>\d*)(?:,(?<maxStr>\d*))?/.exec(e).groups,o=1e5;if(+i>o||a&&+a>o)throw Error(`Quantifier value unsupported in Oniguruma`);if(n=+i,r=a===void 0?+i:a===``?1/0:+a,n>r&&(t=`possessive`,[n,r]=[r,n]),e.endsWith(`?`)){if(t===`possessive`)throw Error(`Unsupported possessive interval quantifier chain with "?"`);t=`lazy`}else t||=`greedy`}else n=+(e[0]===`+`),r=e[0]===`?`?1:1/0,t=e[1]===`+`?`possessive`:e[1]===`?`?`lazy`:`greedy`;return Lp(t,n,r,e)}function Gp(e){let t=e[1].toLowerCase();return jp({d:`digit`,h:`hex`,s:`space`,w:`word`}[t],e,{negate:e[1]!==t})}function Kp(e){let{p:t,neg:n,value:r}=/^\\(?<p>[pP])\{(?<neg>\^?)(?<value>[^}]+)/.exec(e).groups;return jp(`property`,e,{value:r,negate:t===`P`&&!n||t===`p`&&!!n})}function qp(e){let t={};return e.includes(`i`)&&(t.ignoreCase=!0),e.includes(`m`)&&(t.dotAll=!0),e.includes(`x`)&&(t.extended=!0),Object.keys(t).length?t:null}function Jp(e){let t={ignoreCase:!1,dotAll:!1,extended:!1,digitIsAscii:!1,posixIsAscii:!1,spaceIsAscii:!1,wordIsAscii:!1,textSegmentMode:null};for(let n=0;n<e.length;n++){let r=e[n];if(!`imxDPSWy`.includes(r))throw Error(`Invalid flag "${r}"`);if(r===`y`){if(!/^y{[gw]}/.test(e.slice(n)))throw Error(`Invalid or unspecified flag "y" mode`);t.textSegmentMode=e[n+2]===`g`?`grapheme`:`word`,n+=3;continue}t[{i:`ignoreCase`,m:`dotAll`,x:`extended`,D:`digitIsAscii`,P:`posixIsAscii`,S:`spaceIsAscii`,W:`wordIsAscii`}[r]]=!0}return t}function Yp(e){if(/^(?:\\u(?!\p{AHex}{4})|\\x(?!\p{AHex}{1,2}|\{\p{AHex}{1,8}\}))/u.test(e))throw Error(`Incomplete or invalid escape "${e}"`);let t=e[2]===`{`?/^\\x\{\s*(?<hex>\p{AHex}+)/u.exec(e).groups.hex:e.slice(2);return parseInt(t,16)}function Xp(e,t){let{raw:n,inCharClass:r}=e,i=n.slice(1);if(!r&&(i!==`0`&&i.length===1||i[0]!==`0`&&+i<=t))return[Tp(n)];let a=[],o=i.match(/^[0-7]+|\d/g);for(let e=0;e<o.length;e++){let t=o[e],r;if(e===0&&t!==`8`&&t!==`9`){if(r=parseInt(t,8),r>127)throw Error(dp`Octal encoded byte above 177 unsupported "${n}"`)}else r=cp(t);a.push(Ep(r,(e===0?`\\`:``)+t))}return a}function Zp(e){let t=[],n=new RegExp(hp,`gy`),r;for(;r=n.exec(e);){let e=r[0];if(e[0]===`{`){let r=/^\{(?<min>\d+),(?<max>\d+)\}\??$/.exec(e);if(r){let{min:i,max:a}=r.groups;if(+i>+a&&e.endsWith(`?`)){n.lastIndex--,t.push(Wp(e.slice(0,-1)));continue}}}t.push(Wp(e))}return t}function Qp(e,t){if(!Array.isArray(e.body))throw Error(`Expected node with body array`);if(e.body.length!==1)return!1;let n=e.body[0];return!t||Object.keys(t).every(e=>t[e]===n[e])}function $p(e){return em.has(e.type)}var em=new Set([`AbsenceFunction`,`Backreference`,`CapturingGroup`,`Character`,`CharacterClass`,`CharacterSet`,`Group`,`Quantifier`,`Subroutine`]);function tm(e,t={}){let n={flags:``,normalizeUnknownPropertyNames:!1,skipBackrefValidation:!1,skipLookbehindValidation:!1,skipPropertyNameValidation:!1,unicodePropertyMap:null,...t,rules:{captureGroup:!1,singleline:!1,...t.rules}},r=vp(e,{flags:n.flags,rules:{captureGroup:n.rules.captureGroup,singleline:n.rules.singleline}}),i=(e,t)=>{let n=r.tokens[a.nextIndex];switch(a.parent=e,a.nextIndex++,n.type){case`Alternator`:return dm();case`Assertion`:return nm(n);case`Backreference`:return rm(n,a);case`Character`:return hm(n.value,{useLastValid:!!t.isCheckingRangeEnd});case`CharacterClassHyphen`:return im(n,a,t);case`CharacterClassOpen`:return am(n,a,t);case`CharacterSet`:return om(n,a);case`Directive`:return ym(n.kind,{flags:n.flags});case`GroupOpen`:return sm(n,a,t);case`NamedCallout`:return Cm(n.kind,n.tag,n.arguments);case`Quantifier`:return cm(n,a);case`Subroutine`:return lm(n,a);default:throw Error(`Unexpected token type "${n.type}"`)}},a={capturingGroups:[],hasNumberedRef:!1,namedGroupsByName:new Map,nextIndex:0,normalizeUnknownPropertyNames:n.normalizeUnknownPropertyNames,parent:null,skipBackrefValidation:n.skipBackrefValidation,skipLookbehindValidation:n.skipLookbehindValidation,skipPropertyNameValidation:n.skipPropertyNameValidation,subroutines:[],tokens:r.tokens,unicodePropertyMap:n.unicodePropertyMap,walk:i},o=Em(bm(r.flags)),s=o.body[0];for(;a.nextIndex<r.tokens.length;){let e=i(s,{});e.type===`Alternative`?(o.body.push(e),s=e):s.body.push(e)}let{capturingGroups:c,hasNumberedRef:l,namedGroupsByName:u,subroutines:d}=a;if(l&&u.size&&!n.rules.captureGroup)throw Error(`Numbered backref/subroutine not allowed when using named capture`);for(let{ref:e}of d)if(typeof e==`number`){if(e>c.length)throw Error(`Subroutine uses a group number that's not defined`);e&&(c[e-1].isSubroutined=!0)}else if(u.has(e)){if(u.get(e).length>1)throw Error(dp`Subroutine uses a duplicate group name "\g<${e}>"`);u.get(e)[0].isSubroutined=!0}else throw Error(dp`Subroutine uses a group name that's not defined "\g<${e}>"`);return o}function nm({kind:e}){return fm(fp({"^":`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===dp`\B`||e===dp`\Y`})}function rm({raw:e},t){let n=/^\\k[<']/.test(e),r=n?e.slice(3,-1):e.slice(1),i=(n,r=!1)=>{let i=t.capturingGroups.length,a=!1;if(n>i)if(t.skipBackrefValidation)a=!0;else throw Error(`Not enough capturing groups defined to the left "${e}"`);return t.hasNumberedRef=!0,pm(r?i+1-n:n,{orphan:a})};if(n){let n=/^(?<sign>-?)0*(?<num>[1-9]\d*)$/.exec(r);if(n)return i(+n.groups.num,!!n.groups.sign);if(/[-+]/.test(r))throw Error(`Invalid backref name "${e}"`);if(!t.namedGroupsByName.has(r))throw Error(`Group name not defined to the left "${e}"`);return pm(r)}return i(+r)}function im(e,t,n){let{tokens:r,walk:i}=t,a=t.parent,o=a.body.at(-1),s=r[t.nextIndex];if(!n.isCheckingRangeEnd&&o&&o.type!==`CharacterClass`&&o.type!==`CharacterClassRange`&&s&&s.type!==`CharacterClassOpen`&&s.type!==`CharacterClassClose`&&s.type!==`CharacterClassIntersector`){let e=i(a,{...n,isCheckingRangeEnd:!0});if(o.type===`Character`&&e.type===`Character`)return a.body.pop(),_m(o,e);throw Error(`Invalid character class range`)}return hm(cp(`-`))}function am({negate:e},t,n){let{tokens:r,walk:i}=t,a=[gm()],o=r[t.nextIndex],s=Lm(o);for(;s.type!==`CharacterClassClose`;){if(s.type===`CharacterClassIntersector`)a.push(gm()),t.nextIndex++;else{let e=a.at(-1);e.body.push(i(e,n))}s=Lm(r[t.nextIndex],o)}let c=gm({negate:e});return a.length===1?c.body=a[0].body:(c.kind=`intersection`,c.body=a.map(e=>e.body.length===1?e.body[0]:e)),t.nextIndex++,c}function om({kind:e,negate:t,value:n},r){let{normalizeUnknownPropertyNames:i,skipPropertyNameValidation:a,unicodePropertyMap:o}=r;if(e===`property`){let r=Im(n);if(up.has(r)&&!o?.has(r))e=`posix`,n=r;else return Om(n,{negate:t,normalizeUnknownPropertyNames:i,skipPropertyNameValidation:a,unicodePropertyMap:o})}return e===`posix`?wm(n,{negate:t}):vm(e,{negate:t})}function sm(e,t,n){let{tokens:r,capturingGroups:i,namedGroupsByName:a,skipLookbehindValidation:o,walk:s}=t,c=km(e),l=c.type===`AbsenceFunction`,u=Nm(c),d=u&&c.negate;if(c.type===`CapturingGroup`&&(i.push(c),c.name&&lp(a,c.name,[]).push(c)),l&&n.isInAbsenceFunction)throw Error(`Nested absence function not supported by Oniguruma`);let f=Rm(r[t.nextIndex]);for(;f.type!==`GroupClose`;){if(f.type===`Alternator`)c.body.push(dm()),t.nextIndex++;else{let e=c.body.at(-1),t=s(e,{...n,isInAbsenceFunction:n.isInAbsenceFunction||l,isInLookbehind:n.isInLookbehind||u,isInNegLookbehind:n.isInNegLookbehind||d});if(e.body.push(t),(u||n.isInLookbehind)&&!o){let e=`Lookbehind includes a pattern not allowed by Oniguruma`;if(d||n.isInNegLookbehind){if(Mm(t)||t.type===`CapturingGroup`)throw Error(e)}else if(Mm(t)||Nm(t)&&t.negate)throw Error(e)}}f=Rm(r[t.nextIndex])}return t.nextIndex++,c}function cm({kind:e,min:t,max:n},r){let i=r.parent,a=i.body.at(-1);if(!a||!$p(a))throw Error(`Quantifier requires a repeatable token`);let o=Tm(e,t,n,a);return i.body.pop(),o}function lm({raw:e},t){let{capturingGroups:n,subroutines:r}=t,i=e.slice(3,-1),a=/^(?<sign>[-+]?)0*(?<num>[1-9]\d*)$/.exec(i);if(a){let e=+a.groups.num,r=n.length;if(t.hasNumberedRef=!0,i={"":e,"+":r+e,"-":r+1-e}[a.groups.sign],i<1)throw Error(`Invalid subroutine number`)}else i===`0`&&(i=0);let o=Dm(i);return r.push(o),o}function um(e,t){if(e!==`repeater`)throw Error(`Unexpected absence function kind "${e}"`);return{type:`AbsenceFunction`,kind:e,body:Am(t?.body)}}function dm(e){return{type:`Alternative`,body:jm(e?.body)}}function fm(e,t){let n={type:`Assertion`,kind:e};return(e===`word_boundary`||e===`text_segment_boundary`)&&(n.negate=!!t?.negate),n}function pm(e,t){let n=!!t?.orphan;return{type:`Backreference`,ref:e,...n&&{orphan:n}}}function mm(e,t){let n={name:void 0,isSubroutined:!1,...t};if(n.name!==void 0&&!Pm(n.name))throw Error(`Group name "${n.name}" invalid in Oniguruma`);return{type:`CapturingGroup`,number:e,...n.name&&{name:n.name},...n.isSubroutined&&{isSubroutined:n.isSubroutined},body:Am(t?.body)}}function hm(e,t){let n={useLastValid:!1,...t};if(e>1114111){let t=e.toString(16);if(n.useLastValid)e=1114111;else throw Error(e>1310719?`Invalid code point out of range "\\x{${t}}"`:`Invalid code point out of range in JS "\\x{${t}}"`)}return{type:`Character`,value:e}}function gm(e){let t={kind:`union`,negate:!1,...e};return{type:`CharacterClass`,kind:t.kind,negate:t.negate,body:jm(e?.body)}}function _m(e,t){if(t.value<e.value)throw Error(`Character class range out of order`);return{type:`CharacterClassRange`,min:e,max:t}}function vm(e,t){let n=!!t?.negate,r={type:`CharacterSet`,kind:e};return(e===`digit`||e===`hex`||e===`newline`||e===`space`||e===`word`)&&(r.negate=n),(e===`text_segment`||e===`newline`&&!n)&&(r.variableLength=!0),r}function ym(e,t={}){if(e===`keep`)return{type:`Directive`,kind:e};if(e===`flags`)return{type:`Directive`,kind:e,flags:fp(t.flags)};throw Error(`Unexpected directive kind "${e}"`)}function bm(e){return{type:`Flags`,...e}}function xm(e){let t=e?.atomic,n=e?.flags;if(t&&n)throw Error(`Atomic group cannot have flags`);return{type:`Group`,...t&&{atomic:t},...n&&{flags:n},body:Am(e?.body)}}function Sm(e){let t={behind:!1,negate:!1,...e};return{type:`LookaroundAssertion`,kind:t.behind?`lookbehind`:`lookahead`,negate:t.negate,body:Am(e?.body)}}function Cm(e,t,n){return{type:`NamedCallout`,kind:e,tag:t,arguments:n}}function wm(e,t){let n=!!t?.negate;if(!up.has(e))throw Error(`Invalid POSIX class "${e}"`);return{type:`CharacterSet`,kind:`posix`,value:e,negate:n}}function Tm(e,t,n,r){if(t>n)throw Error(`Invalid reversed quantifier range`);return{type:`Quantifier`,kind:e,min:t,max:n,body:r}}function Em(e,t){return{type:`Regex`,body:Am(t?.body),flags:e}}function Dm(e){return{type:`Subroutine`,ref:e}}function Om(e,t){let n={negate:!1,normalizeUnknownPropertyNames:!1,skipPropertyNameValidation:!1,unicodePropertyMap:null,...t},r=n.unicodePropertyMap?.get(Im(e));if(!r){if(n.normalizeUnknownPropertyNames)r=Fm(e);else if(n.unicodePropertyMap&&!n.skipPropertyNameValidation)throw Error(dp`Invalid Unicode property "\p{${e}}"`)}return{type:`CharacterSet`,kind:`property`,value:r??e,negate:n.negate}}function km({flags:e,kind:t,name:n,negate:r,number:i}){switch(t){case`absence_repeater`:return um(`repeater`);case`atomic`:return xm({atomic:!0});case`capturing`:return mm(i,{name:n});case`group`:return xm({flags:e});case`lookahead`:case`lookbehind`:return Sm({behind:t===`lookbehind`,negate:r});default:throw Error(`Unexpected group kind "${t}"`)}}function Am(e){if(e===void 0)e=[dm()];else if(!Array.isArray(e)||!e.length||!e.every(e=>e.type===`Alternative`))throw Error(`Invalid body; expected array of one or more Alternative nodes`);return e}function jm(e){if(e===void 0)e=[];else if(!Array.isArray(e)||!e.every(e=>!!e.type))throw Error(`Invalid body; expected array of nodes`);return e}function Mm(e){return e.type===`LookaroundAssertion`&&e.kind===`lookahead`}function Nm(e){return e.type===`LookaroundAssertion`&&e.kind===`lookbehind`}function Pm(e){return/^[\p{Alpha}\p{Pc}][^)]*$/u.test(e)}function Fm(e){return e.trim().replace(/[- _]+/g,`_`).replace(/[A-Z][a-z]+(?=[A-Z])/g,`$&_`).replace(/[A-Za-z]+/g,e=>e[0].toUpperCase()+e.slice(1).toLowerCase())}function Im(e){return e.replace(/[- _]+/g,``).toLowerCase()}function Lm(e,t){let n=t;return fp(e,`Unclosed character class${n?.type===`Character`&&n.value===93&&n.raw===`]`?` (started with "]")`:``}`)}function Rm(e){return fp(e,`Unclosed group`)}function zm(e,t,n=null){function r(e,t){for(let n=0;n<e.length;n++){let r=i(e[n],t,n,e);n=Math.max(-1,n+r)}}function i(a,o=null,s=null,c=null){let l=0,u=!1,d={node:a,parent:o,key:s,container:c,root:e,remove(){Bm(c).splice(Math.max(0,Vm(s)+l),1),l--,u=!0},removeAllNextSiblings(){return Bm(c).splice(Vm(s)+1)},removeAllPrevSiblings(){let e=Vm(s)+l;return l-=e,Bm(c).splice(0,Math.max(0,e))},replaceWith(e,t={}){let n=!!t.traverse;c?c[Math.max(0,Vm(s)+l)]=e:fp(o,`Can't replace root node`)[s]=e,n&&i(e,o,s,c),u=!0},replaceWithMultiple(e,t={}){let n=!!t.traverse;if(Bm(c).splice(Math.max(0,Vm(s)+l),1,...e),l+=e.length-1,n){let t=0;for(let n=0;n<e.length;n++)t+=i(e[n],o,Vm(s)+n+t,c)}u=!0},skip(){u=!0}},{type:f}=a,p=t[`*`],m=t[f],h=typeof p==`function`?p:p?.enter,g=typeof m==`function`?m:m?.enter;if(h?.(d,n),g?.(d,n),!u)switch(f){case`AbsenceFunction`:case`Alternative`:case`CapturingGroup`:case`CharacterClass`:case`Group`:case`LookaroundAssertion`:r(a.body,a);break;case`Assertion`:case`Backreference`:case`Character`:case`CharacterSet`:case`Directive`:case`Flags`:case`NamedCallout`:case`Subroutine`:break;case`CharacterClassRange`:i(a.min,a,`min`),i(a.max,a,`max`);break;case`Quantifier`:i(a.body,a,`body`);break;case`Regex`:r(a.body,a),i(a.flags,a,`flags`);break;default:throw Error(`Unexpected node type "${f}"`)}return m?.exit?.(d,n),p?.exit?.(d,n),l}return i(e),e}function Bm(e){if(!Array.isArray(e))throw Error(`Container expected`);return e}function Vm(e){if(typeof e!=`number`)throw Error(`Numeric key expected`);return e}var Hm=String.raw`\(\?(?:[:=!>A-Za-z\-]|<[=!]|\(DEFINE\))`;function Um(e,t){for(let n=0;n<e.length;n++)e[n]>=t&&e[n]++}function Wm(e,t,n,r){return e.slice(0,t)+r+e.slice(t+n.length)}var Gm=Object.freeze({DEFAULT:`DEFAULT`,CHAR_CLASS:`CHAR_CLASS`});function Km(e,t,n,r){let i=new RegExp(String.raw`${t}|(?<$skip>\[\^?|\\?.)`,`gsu`),a=[!1],o=0,s=``;for(let t of e.matchAll(i)){let{0:e,groups:{$skip:i}}=t;if(!i&&(!r||r===Gm.DEFAULT==!o)){n instanceof Function?s+=n(t,{context:o?Gm.CHAR_CLASS:Gm.DEFAULT,negated:a[a.length-1]}):s+=n;continue}e[0]===`[`?(o++,a.push(e[1]===`^`)):e===`]`&&o&&(o--,a.pop()),s+=e}return s}function qm(e,t,n,r){Km(e,t,n,r)}function Jm(e,t,n=0,r){if(!new RegExp(t,`su`).test(e))return null;let i=RegExp(`${t}|(?<$skip>\\\\?.)`,`gsu`);i.lastIndex=n;let a=0,o;for(;o=i.exec(e);){let{0:e,groups:{$skip:t}}=o;if(!t&&(!r||r===Gm.DEFAULT==!a))return o;e===`[`?a++:e===`]`&&a&&a--,i.lastIndex==o.index&&i.lastIndex++}return null}function Ym(e,t,n){return!!Jm(e,t,0,n)}function Xm(e,t){let n=/\\?./gsu;n.lastIndex=t;let r=e.length,i=0,a=1,o;for(;o=n.exec(e);){let[e]=o;if(e===`[`)i++;else if(i)e===`]`&&i--;else if(e===`(`)a++;else if(e===`)`&&(a--,!a)){r=o.index;break}}return e.slice(t,r)}var Zm=new RegExp(String.raw`(?<noncapturingStart>${Hm})|(?<capturingStart>\((?:\?<[^>]+>)?)|\\?.`,`gsu`);function Qm(e,t){let n=t?.hiddenCaptures??[],r=t?.captureTransfers??new Map;if(!/\(\?>/.test(e))return{pattern:e,captureTransfers:r,hiddenCaptures:n};let i=[0],a=[],o=0,s=0,c=NaN,l;do{l=!1;let t=0,u=0,d=!1,f;for(Zm.lastIndex=Number.isNaN(c)?0:c+7;f=Zm.exec(e);){let{0:p,index:m,groups:{capturingStart:h,noncapturingStart:g}}=f;if(p===`[`)t++;else if(t)p===`]`&&t--;else if(p===`(?>`&&!d)c=m,d=!0;else if(d&&g)u++;else if(h)d?u++:(o++,i.push(o+s));else if(p===`)`&&d){if(!u){s++;let t=o+s;if(e=`${e.slice(0,c)}(?:(?=(${e.slice(c+3,m)}))<$$${t}>)${e.slice(m+1)}`,l=!0,a.push(t),Um(n,t),r.size){let e=new Map;r.forEach((n,r)=>{e.set(r>=t?r+1:r,n.map(e=>e>=t?e+1:e))}),r=e}break}u--}}}while(l);return n.push(...a),e=Km(e,String.raw`\\(?<backrefNum>[1-9]\d*)|<\$\$(?<wrappedBackrefNum>\d+)>`,({0:e,groups:{backrefNum:t,wrappedBackrefNum:n}})=>{if(t){let n=+t;if(n>i.length-1)throw Error(`Backref "${e}" greater than number of captures`);return`\\${i[n]}`}return`\\${n}`},Gm.DEFAULT),{pattern:e,captureTransfers:r,hiddenCaptures:n}}var $m=String.raw`(?:[?*+]|\{\d+(?:,\d*)?\})`,eh=new RegExp(String.raw`
1450
+ \\(?: \d+
1451
+ | c[A-Za-z]
1452
+ | [gk]<[^>]+>
1453
+ | [pPu]\{[^\}]+\}
1454
+ | u[A-Fa-f\d]{4}
1455
+ | x[A-Fa-f\d]{2}
1456
+ )
1457
+ | \((?: \? (?: [:=!>]
1458
+ | <(?:[=!]|[^>]+>)
1459
+ | [A-Za-z\-]+:
1460
+ | \(DEFINE\)
1461
+ ))?
1462
+ | (?<qBase>${$m})(?<qMod>[?+]?)(?<invalidQ>[?*+\{]?)
1463
+ | \\?.
1464
+ `.replace(/\s+/g,``),`gsu`);function th(e){if(!RegExp(`${$m}\\+`).test(e))return{pattern:e};let t=[],n=null,r=null,i=``,a=0,o;for(eh.lastIndex=0;o=eh.exec(e);){let{0:s,index:c,groups:{qBase:l,qMod:u,invalidQ:d}}=o;if(s===`[`)a||(r=c),a++;else if(s===`]`)a?a--:r=null;else if(!a)if(u===`+`&&i&&!i.startsWith(`(`)){if(d)throw Error(`Invalid quantifier "${s}"`);let t=-1;if(/^\{\d+\}$/.test(l))e=Wm(e,c+l.length,u,``);else{if(i===`)`||i===`]`){let t=i===`)`?n:r;if(t===null)throw Error(`Invalid unmatched "${i}"`);e=`${e.slice(0,t)}(?>${e.slice(t,c)}${l})${e.slice(c+s.length)}`}else e=`${e.slice(0,c-i.length)}(?>${i}${l})${e.slice(c+s.length)}`;t+=4}eh.lastIndex+=t}else s[0]===`(`?t.push(c):s===`)`&&(n=t.length?t.pop():null);i=s}return{pattern:e}}var nh=String.raw,rh=nh`\(\?R=(?<rDepth>[^\)]+)\)|${nh`\\g<(?<gRNameOrNum>[^>&]+)&R=(?<gRDepth>[^>]+)>`}`,ih=nh`\(\?<(?![=!])(?<captureName>[^>]+)>`,ah=nh`${ih}|(?<unnamed>\()(?!\?)`,oh=new RegExp(nh`${ih}|${rh}|\(\?|\\?.`,`gsu`),sh=`Cannot use multiple overlapping recursions`;function ch(e,t){let{hiddenCaptures:n,mode:r}={hiddenCaptures:[],mode:`plugin`,...t},i=t?.captureTransfers??new Map;if(!new RegExp(rh,`su`).test(e))return{pattern:e,captureTransfers:i,hiddenCaptures:n};if(r===`plugin`&&Ym(e,nh`\(\?\(DEFINE\)`,Gm.DEFAULT))throw Error(`DEFINE groups cannot be used with recursion`);let a=[],o=Ym(e,nh`\\[1-9]`,Gm.DEFAULT),s=new Map,c=[],l=!1,u=0,d=0,f;for(oh.lastIndex=0;f=oh.exec(e);){let{0:t,groups:{captureName:p,rDepth:m,gRNameOrNum:h,gRDepth:g}}=f;if(t===`[`)u++;else if(u)t===`]`&&u--;else if(m){if(lh(m),l)throw Error(sh);if(o)throw Error(`${r===`external`?`Backrefs`:`Numbered backrefs`} cannot be used with global recursion`);let t=e.slice(0,f.index),s=e.slice(oh.lastIndex);if(Ym(s,rh,Gm.DEFAULT))throw Error(sh);let c=m-1;e=uh(t,s,c,!1,n,a,d),i=ph(i,t,c,a.length,0,d);break}else if(h){lh(g);let u=!1;for(let e of c)if(e.name===h||e.num===+h){if(u=!0,e.hasRecursedWithin)throw Error(sh);break}if(!u)throw Error(nh`Recursive \g cannot be used outside the referenced group "${r===`external`?h:nh`\g<${h}&R=${g}>`}"`);let p=s.get(h),m=Xm(e,p);if(o&&Ym(m,nh`${ih}|\((?!\?)`,Gm.DEFAULT))throw Error(`${r===`external`?`Backrefs`:`Numbered backrefs`} cannot be used with recursion of capturing groups`);let _=e.slice(p,f.index),v=m.slice(_.length+t.length),y=a.length,b=g-1,x=uh(_,v,b,!0,n,a,d);i=ph(i,_,b,a.length-y,y,d),e=`${e.slice(0,p)}${x}${e.slice(p+m.length)}`,oh.lastIndex+=x.length-t.length-_.length-v.length,c.forEach(e=>e.hasRecursedWithin=!0),l=!0}else if(p)d++,s.set(String(d),oh.lastIndex),s.set(p,oh.lastIndex),c.push({num:d,name:p});else if(t[0]===`(`){let e=t===`(`;e&&(d++,s.set(String(d),oh.lastIndex)),c.push(e?{num:d}:{})}else t===`)`&&c.pop()}return n.push(...a),{pattern:e,captureTransfers:i,hiddenCaptures:n}}function lh(e){let t=`Max depth must be integer between 2 and 100; used ${e}`;if(!/^[1-9]\d*$/.test(e)||(e=+e,e<2||e>100))throw Error(t)}function uh(e,t,n,r,i,a,o){let s=new Set;r&&qm(e+t,ih,({groups:{captureName:e}})=>{s.add(e)},Gm.DEFAULT);let c=[n,r?s:null,i,a,o];return`${e}${dh(`(?:${e}`,`forward`,...c)}(?:)${dh(`${t})`,`backward`,...c)}${t}`}function dh(e,t,n,r,i,a,o){let s=e=>t===`forward`?e+2:n-e+2-1,c=``;for(let t=0;t<n;t++){let n=s(t);c+=Km(e,nh`${ah}|\\k<(?<backref>[^>]+)>`,({0:e,groups:{captureName:t,unnamed:s,backref:c}})=>{if(c&&r&&!r.has(c))return e;let l=`_$${n}`;if(s||t){let n=o+a.length+1;return a.push(n),fh(i,n),s?e:`(?<${t}${l}>`}return nh`\k<${c}${l}>`},Gm.DEFAULT)}return c}function fh(e,t){for(let n=0;n<e.length;n++)e[n]>=t&&e[n]++}function ph(e,t,n,r,i,a){if(e.size&&r){let o=0;qm(t,ah,()=>o++,Gm.DEFAULT);let s=a-o+i,c=new Map;return e.forEach((e,t)=>{let i=(r-o*n)/n,a=o*n,l=t>s+o?t+r:t,u=[];for(let t of e)if(t<=s)u.push(t);else if(t>s+o+i)u.push(t+r);else if(t<=s+o)for(let e=0;e<=n;e++)u.push(t+o*e);else for(let e=0;e<=n;e++)u.push(t+a+i*e);c.set(l,u)}),c}return e}var mh=String.fromCodePoint,hh=String.raw,gh={},_h=globalThis.RegExp;gh.flagGroups=(()=>{try{new _h(`(?i:)`)}catch{return!1}return!0})(),gh.unicodeSets=(()=>{try{new _h(`[[]]`,`v`)}catch{return!1}return!0})(),gh.bugFlagVLiteralHyphenIsRange=gh.unicodeSets?(()=>{try{new _h(hh`[\d\-a]`,`v`)}catch{return!0}return!1})():!1,gh.bugNestedClassIgnoresNegation=gh.unicodeSets&&new _h(`[[^a]]`,`v`).test(`a`);function vh(e,{enable:t,disable:n}){return{dotAll:!n?.dotAll&&!!(t?.dotAll||e.dotAll),ignoreCase:!n?.ignoreCase&&!!(t?.ignoreCase||e.ignoreCase)}}function yh(e,t,n){return e.has(t)||e.set(t,n),e.get(t)}function bh(e,t){return Sh[e]>=Sh[t]}function xh(e,t){if(e==null)throw Error(t??`Value expected`);return e}var Sh={ES2025:2025,ES2024:2024,ES2018:2018},Ch={auto:`auto`,ES2025:`ES2025`,ES2024:`ES2024`,ES2018:`ES2018`};function wh(e={}){if({}.toString.call(e)!==`[object Object]`)throw Error(`Unexpected options`);if(e.target!==void 0&&!Ch[e.target])throw Error(`Unexpected target "${e.target}"`);let t={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 t.target===`auto`&&(t.target=gh.flagGroups?`ES2025`:gh.unicodeSets?`ES2024`:`ES2018`),t}var Th=`[ -\r ]`,Eh=new Set([mh(304),mh(305)]),Dh=hh`[\p{L}\p{M}\p{N}\p{Pc}]`;function Oh(e){if(Eh.has(e))return[e];let t=new Set,n=e.toLowerCase(),r=n.toUpperCase(),i=Mh.get(n),a=Ah.get(n),o=jh.get(n);return[...r].length===1&&t.add(r),o&&t.add(o),i&&t.add(i),t.add(n),a&&t.add(a),[...t]}var kh=new Map(`C Other
1465
+ Cc Control cntrl
1466
+ Cf Format
1467
+ Cn Unassigned
1468
+ Co Private_Use
1469
+ Cs Surrogate
1470
+ L Letter
1471
+ LC Cased_Letter
1472
+ Ll Lowercase_Letter
1473
+ Lm Modifier_Letter
1474
+ Lo Other_Letter
1475
+ Lt Titlecase_Letter
1476
+ Lu Uppercase_Letter
1477
+ M Mark Combining_Mark
1478
+ Mc Spacing_Mark
1479
+ Me Enclosing_Mark
1480
+ Mn Nonspacing_Mark
1481
+ N Number
1482
+ Nd Decimal_Number digit
1483
+ Nl Letter_Number
1484
+ No Other_Number
1485
+ P Punctuation punct
1486
+ Pc Connector_Punctuation
1487
+ Pd Dash_Punctuation
1488
+ Pe Close_Punctuation
1489
+ Pf Final_Punctuation
1490
+ Pi Initial_Punctuation
1491
+ Po Other_Punctuation
1492
+ Ps Open_Punctuation
1493
+ S Symbol
1494
+ Sc Currency_Symbol
1495
+ Sk Modifier_Symbol
1496
+ Sm Math_Symbol
1497
+ So Other_Symbol
1498
+ Z Separator
1499
+ Zl Line_Separator
1500
+ Zp Paragraph_Separator
1501
+ Zs Space_Separator
1502
+ ASCII
1503
+ ASCII_Hex_Digit AHex
1504
+ Alphabetic Alpha
1505
+ Any
1506
+ Assigned
1507
+ Bidi_Control Bidi_C
1508
+ Bidi_Mirrored Bidi_M
1509
+ Case_Ignorable CI
1510
+ Cased
1511
+ Changes_When_Casefolded CWCF
1512
+ Changes_When_Casemapped CWCM
1513
+ Changes_When_Lowercased CWL
1514
+ Changes_When_NFKC_Casefolded CWKCF
1515
+ Changes_When_Titlecased CWT
1516
+ Changes_When_Uppercased CWU
1517
+ Dash
1518
+ Default_Ignorable_Code_Point DI
1519
+ Deprecated Dep
1520
+ Diacritic Dia
1521
+ Emoji
1522
+ Emoji_Component EComp
1523
+ Emoji_Modifier EMod
1524
+ Emoji_Modifier_Base EBase
1525
+ Emoji_Presentation EPres
1526
+ Extended_Pictographic ExtPict
1527
+ Extender Ext
1528
+ Grapheme_Base Gr_Base
1529
+ Grapheme_Extend Gr_Ext
1530
+ Hex_Digit Hex
1531
+ IDS_Binary_Operator IDSB
1532
+ IDS_Trinary_Operator IDST
1533
+ ID_Continue IDC
1534
+ ID_Start IDS
1535
+ Ideographic Ideo
1536
+ Join_Control Join_C
1537
+ Logical_Order_Exception LOE
1538
+ Lowercase Lower
1539
+ Math
1540
+ Noncharacter_Code_Point NChar
1541
+ Pattern_Syntax Pat_Syn
1542
+ Pattern_White_Space Pat_WS
1543
+ Quotation_Mark QMark
1544
+ Radical
1545
+ Regional_Indicator RI
1546
+ Sentence_Terminal STerm
1547
+ Soft_Dotted SD
1548
+ Terminal_Punctuation Term
1549
+ Unified_Ideograph UIdeo
1550
+ Uppercase Upper
1551
+ Variation_Selector VS
1552
+ White_Space space
1553
+ XID_Continue XIDC
1554
+ XID_Start XIDS`.split(/\s/).map(e=>[Im(e),e])),Ah=new Map([[`s`,mh(383)],[mh(383),`s`]]),jh=new Map([[mh(223),mh(7838)],[mh(107),mh(8490)],[mh(229),mh(8491)],[mh(969),mh(8486)]]),Mh=new Map([Fh(453),Fh(456),Fh(459),Fh(498),...Ih(8072,8079),...Ih(8088,8095),...Ih(8104,8111),Fh(8124),Fh(8140),Fh(8188)]),Nh=new Map([[`alnum`,hh`[\p{Alpha}\p{Nd}]`],[`alpha`,hh`\p{Alpha}`],[`ascii`,hh`\p{ASCII}`],[`blank`,hh`[\p{Zs}\t]`],[`cntrl`,hh`\p{Cc}`],[`digit`,hh`\p{Nd}`],[`graph`,hh`[\P{space}&&\P{Cc}&&\P{Cn}&&\P{Cs}]`],[`lower`,hh`\p{Lower}`],[`print`,hh`[[\P{space}&&\P{Cc}&&\P{Cn}&&\P{Cs}]\p{Zs}]`],[`punct`,hh`[\p{P}\p{S}]`],[`space`,hh`\p{space}`],[`upper`,hh`\p{Upper}`],[`word`,hh`[\p{Alpha}\p{M}\p{Nd}\p{Pc}]`],[`xdigit`,hh`\p{AHex}`]]);function Ph(e,t){let n=[];for(let r=e;r<=t;r++)n.push(r);return n}function Fh(e){let t=mh(e);return[t.toLowerCase(),t]}function Ih(e,t){return Ph(e,t).map(e=>Fh(e))}var Lh=new Set([`Lower`,`Lowercase`,`Upper`,`Uppercase`,`Ll`,`Lowercase_Letter`,`Lt`,`Titlecase_Letter`,`Lu`,`Uppercase_Letter`]);function Rh(e,t){let n={accuracy:`default`,asciiWordBoundaries:!1,avoidSubclass:!1,bestEffortTarget:`ES2025`,...t};Hh(e);let r={accuracy:n.accuracy,asciiWordBoundaries:n.asciiWordBoundaries,avoidSubclass:n.avoidSubclass,flagDirectivesByAlt:new Map,jsGroupNameMap:new Map,minTargetEs2024:bh(n.bestEffortTarget,`ES2024`),passedLookbehind:!1,strategy:null,subroutineRefMap:new Map,supportedGNodes:new Set,digitIsAscii:e.flags.digitIsAscii,spaceIsAscii:e.flags.spaceIsAscii,wordIsAscii:e.flags.wordIsAscii};zm(e,zh,r);let i={dotAll:e.flags.dotAll,ignoreCase:e.flags.ignoreCase},a={currentFlags:i,prevFlags:null,globalFlags:i,groupOriginByCopy:new Map,groupsByName:new Map,multiplexCapturesToLeftByRef:new Map,openRefs:new Map,reffedNodesByReferencer:new Map,subroutineRefMap:r.subroutineRefMap};return zm(e,Bh,a),zm(e,Vh,{groupsByName:a.groupsByName,highestOrphanBackref:0,numCapturesToLeft:0,reffedNodesByReferencer:a.reffedNodesByReferencer}),e._originMap=a.groupOriginByCopy,e._strategy=r.strategy,e}var zh={AbsenceFunction({node:e,parent:t,replaceWith:n}){let{body:r,kind:i}=e;if(i===`repeater`){let e=xm();e.body[0].body.push(Sm({negate:!0,body:r}),Om(`Any`));let i=xm();i.body[0].body.push(Tm(`greedy`,0,1/0,e)),n(sg(i,t),{traverse:!0})}else throw Error(`Unsupported absence function "(?~|"`)},Alternative:{enter({node:e,parent:t,key:n},{flagDirectivesByAlt:r}){let i=e.body.filter(e=>e.kind===`flags`);for(let e=n+1;e<t.body.length;e++){let n=t.body[e];yh(r,n,[]).push(...i)}},exit({node:e},{flagDirectivesByAlt:t}){if(t.get(e)?.length){let n=Yh(t.get(e));if(n){let t=xm({flags:n});t.body[0].body=e.body,e.body=[sg(t,e)]}}}},Assertion({node:e,parent:t,key:n,container:r,root:i,remove:a,replaceWith:o},s){let{kind:c,negate:l}=e,{asciiWordBoundaries:u,avoidSubclass:d,supportedGNodes:f,wordIsAscii:p}=s;if(c===`text_segment_boundary`)throw Error(`Unsupported text segment boundary "\\${l?`Y`:`y`}"`);if(c===`line_end`)o(sg(Sm({body:[dm({body:[fm(`string_end`)]}),dm({body:[hm(10)]})]}),t));else if(c===`line_start`)o(sg(ig(hh`(?<=\A|\n(?!\z))`,{skipLookbehindValidation:!0}),t));else if(c===`search_start`)if(f.has(e))i.flags.sticky=!0,a();else{let e=r[n-1];if(e&&tg(e))o(sg(Sm({negate:!0}),t));else if(d)throw Error(hh`Uses "\G" in a way that requires a subclass`);else o(og(fm(`string_start`),t)),s.strategy=`clip_search`}else if(!(c===`string_end`||c===`string_start`))if(c===`string_end_newline`)o(sg(ig(hh`(?=\n?\z)`),t));else if(c===`word_boundary`){if(!p&&!u){let e=`(?:(?<=${Dh})(?!${Dh})|(?<!${Dh})(?=${Dh}))`,n=`(?:(?<=${Dh})(?=${Dh})|(?<!${Dh})(?!${Dh}))`;o(sg(ig(l?n:e),t))}}else throw Error(`Unexpected assertion kind "${c}"`)},Backreference({node:e},{jsGroupNameMap:t}){let{ref:n}=e;typeof n==`string`&&!rg(n)&&(n=Jh(n,t),e.ref=n)},CapturingGroup({node:e},{jsGroupNameMap:t,subroutineRefMap:n}){let{name:r}=e;r&&!rg(r)&&(r=Jh(r,t),e.name=r),n.set(e.number,e),r&&n.set(r,e)},CharacterClassRange({node:e,parent:t,replaceWith:n}){t.kind===`intersection`&&n(sg(gm({body:[e]}),t),{traverse:!0})},CharacterSet({node:e,parent:t,replaceWith:n},{accuracy:r,minTargetEs2024:i,digitIsAscii:a,spaceIsAscii:o,wordIsAscii:s}){let{kind:c,negate:l,value:u}=e;if(a&&(c===`digit`||u===`digit`)){n(og(vm(`digit`,{negate:l}),t));return}if(o&&(c===`space`||u===`space`)){n(sg(ag(ig(Th),l),t));return}if(s&&(c===`word`||u===`word`)){n(og(vm(`word`,{negate:l}),t));return}if(c===`any`)n(og(Om(`Any`),t));else if(c===`digit`)n(og(Om(`Nd`,{negate:l}),t));else if(c!==`dot`)if(c===`text_segment`){if(r===`strict`)throw Error(hh`Use of "\X" requires non-strict accuracy`);let e=`\\p{Emoji}(?:\\p{EMod}|\\uFE0F\\u20E3?|[\\x{E0020}-\\x{E007E}]+\\x{E007F})?`,a=hh`\p{RI}{2}|${e}(?:\u200D${e})*`;n(sg(ig(hh`(?>\r\n|${i?hh`\p{RGI_Emoji}`:a}|\P{M}\p{M}*)`,{skipPropertyNameValidation:!0}),t))}else if(c===`hex`)n(og(Om(`AHex`,{negate:l}),t));else if(c===`newline`)n(sg(ig(l?`[^
1555
+ ]`:`(?>\r
1556
+ ?|[
1557
+ \v\f…\u2028\u2029])`),t));else if(c===`posix`)if(!i&&(u===`graph`||u===`print`)){if(r===`strict`)throw Error(`POSIX class "${u}" requires min target ES2024 or non-strict accuracy`);let e={graph:`!-~`,print:` -~`}[u];l&&(e=`\0-${mh(e.codePointAt(0)-1)}${mh(e.codePointAt(2)+1)}-\u{10FFFF}`),n(sg(ig(`[${e}]`),t))}else n(sg(ag(ig(Nh.get(u)),l),t));else if(c===`property`)kh.has(Im(u))||(e.key=`sc`);else if(c===`space`)n(og(Om(`space`,{negate:l}),t));else if(c===`word`)n(sg(ag(ig(Dh),l),t));else throw Error(`Unexpected character set kind "${c}"`)},Directive({node:e,parent:t,root:n,remove:r,replaceWith:i,removeAllPrevSiblings:a,removeAllNextSiblings:o}){let{kind:s,flags:c}=e;if(s===`flags`)if(!c.enable&&!c.disable)r();else{let e=xm({flags:c});e.body[0].body=o(),i(sg(e,t),{traverse:!0})}else if(s===`keep`){let e=n.body[0],r=n.body.length===1&&Qp(e,{type:`Group`})&&e.body[0].body.length===1?e.body[0]:n;if(t.parent!==r||r.body.length>1)throw Error(hh`Uses "\K" in a way that's unsupported`);let o=Sm({behind:!0});o.body[0].body=a(),i(sg(o,t))}else throw Error(`Unexpected directive kind "${s}"`)},Flags({node:e,parent:t}){if(e.posixIsAscii)throw Error(`Unsupported flag "P"`);if(e.textSegmentMode===`word`)throw 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}),t.options={disable:{x:!0,n:!0},force:{v:!0}}},Group({node:e}){if(!e.flags)return;let{enable:t,disable:n}=e.flags;t?.extended&&delete t.extended,n?.extended&&delete n.extended,t?.dotAll&&n?.dotAll&&delete t.dotAll,t?.ignoreCase&&n?.ignoreCase&&delete t.ignoreCase,t&&!Object.keys(t).length&&delete e.flags.enable,n&&!Object.keys(n).length&&delete e.flags.disable,!e.flags.enable&&!e.flags.disable&&delete e.flags},LookaroundAssertion({node:e},t){let{kind:n}=e;n===`lookbehind`&&(t.passedLookbehind=!0)},NamedCallout({node:e,parent:t,replaceWith:n}){let{kind:r}=e;if(r===`fail`)n(sg(Sm({negate:!0}),t));else throw Error(`Unsupported named callout "(*${r.toUpperCase()}"`)},Quantifier({node:e}){if(e.body.type===`Quantifier`){let t=xm();t.body[0].body.push(e.body),e.body=sg(t,e)}},Regex:{enter({node:e},{supportedGNodes:t}){let n=[],r=!1,i=!1;for(let t of e.body)if(t.body.length===1&&t.body[0].kind===`search_start`)t.body.pop();else{let e=Qh(t.body);e?(r=!0,Array.isArray(e)?n.push(...e):n.push(e)):i=!0}r&&!i&&n.forEach(e=>t.add(e))},exit(e,{accuracy:t,passedLookbehind:n,strategy:r}){if(t===`strict`&&n&&r)throw Error(hh`Uses "\G" in a way that requires non-strict accuracy`)}},Subroutine({node:e},{jsGroupNameMap:t}){let{ref:n}=e;typeof n==`string`&&!rg(n)&&(n=Jh(n,t),e.ref=n)}},Bh={Backreference({node:e},{multiplexCapturesToLeftByRef:t,reffedNodesByReferencer:n}){let{orphan:r,ref:i}=e;r||n.set(e,[...t.get(i).map(({node:e})=>e)])},CapturingGroup:{enter({node:e,parent:t,replaceWith:n,skip:r},{groupOriginByCopy:i,groupsByName:a,multiplexCapturesToLeftByRef:o,openRefs:s,reffedNodesByReferencer:c}){let l=i.get(e);if(l&&s.has(e.number)){let r=og(Kh(e.number),t);c.set(r,s.get(e.number)),n(r);return}s.set(e.number,e),o.set(e.number,[]),e.name&&yh(o,e.name,[]);let u=o.get(e.name??e.number);for(let t=0;t<u.length;t++){let n=u[t];if(l===n.node||l&&l===n.origin||e===n.origin){u.splice(t,1);break}}if(o.get(e.number).push({node:e,origin:l}),e.name&&o.get(e.name).push({node:e,origin:l}),e.name){let t=yh(a,e.name,new Map),n=!1;if(l)n=!0;else for(let e of t.values())if(!e.hasDuplicateNameToRemove){n=!0;break}a.get(e.name).set(e,{node:e,hasDuplicateNameToRemove:n})}},exit({node:e},{openRefs:t}){t.get(e.number)===e&&t.delete(e.number)}},Group:{enter({node:e},t){t.prevFlags=t.currentFlags,e.flags&&(t.currentFlags=vh(t.currentFlags,e.flags))},exit(e,t){t.currentFlags=t.prevFlags}},Subroutine({node:e,parent:t,replaceWith:n},r){let{isRecursive:i,ref:a}=e;if(i){let n=t;for(;(n=n.parent)&&!(n.type===`CapturingGroup`&&(n.name===a||n.number===a)););r.reffedNodesByReferencer.set(e,n);return}let o=r.subroutineRefMap.get(a),s=a===0,c=s?Kh(0):Gh(o,r.groupOriginByCopy,null),l=c;if(!s){let e=Yh(qh(o,e=>e.type===`Group`&&!!e.flags)),t=e?vh(r.globalFlags,e):r.globalFlags;Uh(t,r.currentFlags)||(l=xm({flags:Xh(t)}),l.body[0].body.push(c))}n(sg(l,t),{traverse:!s})}},Vh={Backreference({node:e,parent:t,replaceWith:n},r){if(e.orphan){r.highestOrphanBackref=Math.max(r.highestOrphanBackref,e.ref);return}let i=r.reffedNodesByReferencer.get(e).filter(t=>Wh(t,e));i.length?i.length>1?n(sg(xm({atomic:!0,body:i.reverse().map(e=>dm({body:[pm(e.number)]}))}),t)):e.ref=i[0].number:n(sg(Sm({negate:!0}),t))},CapturingGroup({node:e},t){e.number=++t.numCapturesToLeft,e.name&&t.groupsByName.get(e.name).get(e).hasDuplicateNameToRemove&&delete e.name},Regex:{exit({node:e},t){let n=Math.max(t.highestOrphanBackref-t.numCapturesToLeft,0);for(let t=0;t<n;t++){let t=mm();e.body.at(-1).body.push(t)}}},Subroutine({node:e},t){!e.isRecursive||e.ref===0||(e.ref=t.reffedNodesByReferencer.get(e).number)}};function Hh(e){zm(e,{"*"({node:e,parent:t}){e.parent=t}})}function Uh(e,t){return e.dotAll===t.dotAll&&e.ignoreCase===t.ignoreCase}function Wh(e,t){let n=t;do{if(n.type===`Regex`)return!1;if(n.type===`Alternative`)continue;if(n===e)return!1;let t=Zh(n.parent);for(let r of t){if(r===n)break;if(r===e||$h(r,e))return!0}}while(n=n.parent);throw Error(`Unexpected path`)}function Gh(e,t,n,r){let i=Array.isArray(e)?[]:{};for(let[a,o]of Object.entries(e))a===`parent`?i.parent=Array.isArray(n)?r:n:o&&typeof o==`object`?i[a]=Gh(o,t,i,n):(a===`type`&&o===`CapturingGroup`&&t.set(i,t.get(e)??e),i[a]=o);return i}function Kh(e){let t=Dm(e);return t.isRecursive=!0,t}function qh(e,t){let n=[];for(;e=e.parent;)(!t||t(e))&&n.push(e);return n}function Jh(e,t){if(t.has(e))return t.get(e);let n=`$${t.size}_${e.replace(/^[^$_\p{IDS}]|[^$\u200C\u200D\p{IDC}]/gu,`_`)}`;return t.set(e,n),n}function Yh(e){let t=[`dotAll`,`ignoreCase`],n={enable:{},disable:{}};return e.forEach(({flags:e})=>{t.forEach(t=>{e.enable?.[t]&&(delete n.disable[t],n.enable[t]=!0),e.disable?.[t]&&(n.disable[t]=!0)})}),Object.keys(n.enable).length||delete n.enable,Object.keys(n.disable).length||delete n.disable,n.enable||n.disable?n:null}function Xh({dotAll:e,ignoreCase:t}){let n={};return(e||t)&&(n.enable={},e&&(n.enable.dotAll=!0),t&&(n.enable.ignoreCase=!0)),(!e||!t)&&(n.disable={},!e&&(n.disable.dotAll=!0),!t&&(n.disable.ignoreCase=!0)),n}function Zh(e){if(!e)throw Error(`Node expected`);let{body:t}=e;return Array.isArray(t)?t:t?[t]:null}function Qh(e){let t=e.find(e=>e.kind===`search_start`||ng(e,{negate:!1})||!eg(e));if(!t)return null;if(t.kind===`search_start`)return t;if(t.type===`LookaroundAssertion`)return t.body[0].body[0];if(t.type===`CapturingGroup`||t.type===`Group`){let e=[];for(let n of t.body){let t=Qh(n.body);if(!t)return null;Array.isArray(t)?e.push(...t):e.push(t)}return e}return null}function $h(e,t){let n=Zh(e)??[];for(let e of n)if(e===t||$h(e,t))return!0;return!1}function eg({type:e}){return e===`Assertion`||e===`Directive`||e===`LookaroundAssertion`}function tg(e){let t=[`Character`,`CharacterClass`,`CharacterSet`];return t.includes(e.type)||e.type===`Quantifier`&&e.min&&t.includes(e.body.type)}function ng(e,t){let n={negate:null,...t};return e.type===`LookaroundAssertion`&&(n.negate===null||e.negate===n.negate)&&e.body.length===1&&Qp(e.body[0],{type:`Assertion`,kind:`search_start`})}function rg(e){return/^[$_\p{IDS}][$\u200C\u200D\p{IDC}]*$/u.test(e)}function ig(e,t){let n=tm(e,{...t,unicodePropertyMap:kh}).body;return n.length>1||n[0].body.length>1?xm({body:n}):n[0].body[0]}function ag(e,t){return e.negate=t,e}function og(e,t){return e.parent=t,e}function sg(e,t){return Hh(e),e.parent=t,e}function cg(e,t){let n=wh(t),r=bh(n.target,`ES2024`),i=bh(n.target,`ES2025`),a=n.rules.recursionLimit;if(!Number.isInteger(a)||a<2||a>20)throw Error(`Invalid recursionLimit; use 2-20`);let o=null,s=null;if(!i){let t=[e.flags.ignoreCase];zm(e,lg,{getCurrentModI:()=>t.at(-1),popModI(){t.pop()},pushModI(e){t.push(e)},setHasCasedChar(){t.at(-1)?o=!0:s=!0}})}let c={dotAll:e.flags.dotAll,ignoreCase:!!((e.flags.ignoreCase||o)&&!s)},l=e,u={accuracy:n.accuracy,appliedGlobalFlags:c,captureMap:new Map,currentFlags:{dotAll:e.flags.dotAll,ignoreCase:e.flags.ignoreCase},inCharClass:!1,lastNode:l,originMap:e._originMap,recursionLimit:a,useAppliedIgnoreCase:!!(!i&&o&&s),useFlagMods:i,useFlagV:r,verbose:n.verbose};function d(e){return u.lastNode=l,l=e,xh(ug[e.type],`Unexpected node type "${e.type}"`)(e,u,d)}let f={pattern:e.body.map(d).join(`|`),flags:d(e.flags),options:{...e.options}};return r||(delete f.options.force.v,f.options.disable.v=!0,f.options.unicodeSetsPlugin=null),f._captureTransfers=new Map,f._hiddenCaptures=[],u.captureMap.forEach((e,t)=>{e.hidden&&f._hiddenCaptures.push(t),e.transferTo&&yh(f._captureTransfers,e.transferTo,[]).push(t)}),f}var lg={"*":{enter({node:e},t){if(Sg(e)){let n=t.getCurrentModI();t.pushModI(e.flags?vh({ignoreCase:n},e.flags).ignoreCase:n)}},exit({node:e},t){Sg(e)&&t.popModI()}},Backreference(e,t){t.setHasCasedChar()},Character({node:e},t){gg(mh(e.value))&&t.setHasCasedChar()},CharacterClassRange({node:e,skip:t},n){t(),_g(e,{firstOnly:!0}).length&&n.setHasCasedChar()},CharacterSet({node:e},t){e.kind===`property`&&Lh.has(e.value)&&t.setHasCasedChar()}},ug={Alternative({body:e},t,n){return e.map(n).join(``)},Assertion({kind:e,negate:t}){if(e===`string_end`)return`$`;if(e===`string_start`)return`^`;if(e===`word_boundary`)return t?hh`\B`:hh`\b`;throw Error(`Unexpected assertion kind "${e}"`)},Backreference({ref:e},t){if(typeof e!=`number`)throw Error(`Unexpected named backref in transformed AST`);if(!t.useFlagMods&&t.accuracy===`strict`&&t.currentFlags.ignoreCase&&!t.captureMap.get(e).ignoreCase)throw Error(`Use of case-insensitive backref to case-sensitive group requires target ES2025 or non-strict accuracy`);return`\\`+e},CapturingGroup(e,t,n){let{body:r,name:i,number:a}=e,o={ignoreCase:t.currentFlags.ignoreCase},s=t.originMap.get(e);return s&&(o.hidden=!0,a>s.number&&(o.transferTo=s.number)),t.captureMap.set(a,o),`(${i?`?<${i}>`:``}${r.map(n).join(`|`)})`},Character({value:e},t){let n=mh(e),r=vg(e,{escDigit:t.lastNode.type===`Backreference`,inCharClass:t.inCharClass,useFlagV:t.useFlagV});if(r!==n)return r;if(t.useAppliedIgnoreCase&&t.currentFlags.ignoreCase&&gg(n)){let e=Oh(n);return t.inCharClass?e.join(``):e.length>1?`[${e.join(``)}]`:e[0]}return n},CharacterClass(e,t,n){let{kind:r,negate:i,parent:a}=e,{body:o}=e;if(r===`intersection`&&!t.useFlagV)throw Error(`Use of character class intersection requires min target ES2024`);gh.bugFlagVLiteralHyphenIsRange&&t.useFlagV&&o.some(wg)&&(o=[hm(45),...o.filter(e=>!wg(e))]);let s=()=>`[${i?`^`:``}${o.map(n).join(r===`intersection`?`&&`:``)}]`;if(!t.inCharClass){if((!t.useFlagV||gh.bugNestedClassIgnoresNegation)&&!i){let t=o.filter(e=>e.type===`CharacterClass`&&e.kind===`union`&&e.negate);if(t.length){let r=xm(),i=r.body[0];return r.parent=a,i.parent=r,o=o.filter(e=>!t.includes(e)),e.body=o,o.length?(e.parent=i,i.body.push(e)):r.body.pop(),t.forEach(e=>{let t=dm({body:[e]});e.parent=t,t.parent=r,r.body.push(t)}),n(r)}}t.inCharClass=!0;let r=s();return t.inCharClass=!1,r}let c=o[0];if(r===`union`&&!i&&c&&((!t.useFlagV||!t.verbose)&&a.kind===`union`&&!(gh.bugFlagVLiteralHyphenIsRange&&t.useFlagV)||!t.verbose&&a.kind===`intersection`&&o.length===1&&c.type!==`CharacterClassRange`))return o.map(n).join(``);if(!t.useFlagV&&a.type===`CharacterClass`)throw Error(`Uses nested character class in a way that requires min target ES2024`);return s()},CharacterClassRange(e,t){let n=e.min.value,r=e.max.value,i={escDigit:!1,inCharClass:!0,useFlagV:t.useFlagV},a=vg(n,i),o=vg(r,i),s=new Set;return t.useAppliedIgnoreCase&&t.currentFlags.ignoreCase&&yg(_g(e)).forEach(e=>{s.add(Array.isArray(e)?`${vg(e[0],i)}-${vg(e[1],i)}`:vg(e,i))}),`${a}-${o}${[...s].join(``)}`},CharacterSet({kind:e,negate:t,value:n,key:r},i){if(e===`dot`)return i.currentFlags.dotAll?i.appliedGlobalFlags.dotAll||i.useFlagMods?`.`:`[^]`:hh`[^\n]`;if(e===`digit`)return t?hh`\D`:hh`\d`;if(e===`property`){if(i.useAppliedIgnoreCase&&i.currentFlags.ignoreCase&&Lh.has(n))throw Error(`Unicode property "${n}" can't be case-insensitive when other chars have specific case`);return`${t?hh`\P`:hh`\p`}{${r?`${r}=`:``}${n}}`}if(e===`word`)return t?hh`\W`:hh`\w`;throw Error(`Unexpected character set kind "${e}"`)},Flags(e,t){return(t.appliedGlobalFlags.ignoreCase?`i`:``)+(e.dotAll?`s`:``)+(e.sticky?`y`:``)},Group({atomic:e,body:t,flags:n,parent:r},i,a){let o=i.currentFlags;n&&(i.currentFlags=vh(o,n));let s=t.map(a).join(`|`),c=!i.verbose&&t.length===1&&r.type!==`Quantifier`&&!e&&(!i.useFlagMods||!n)?s:`(?${bg(e,n,i.useFlagMods)}${s})`;return i.currentFlags=o,c},LookaroundAssertion({body:e,kind:t,negate:n},r,i){return`(?${`${t===`lookahead`?``:`<`}${n?`!`:`=`}`}${e.map(i).join(`|`)})`},Quantifier(e,t,n){return n(e.body)+xg(e)},Subroutine({isRecursive:e,ref:t},n){if(!e)throw Error(`Unexpected non-recursive subroutine in transformed AST`);let r=n.recursionLimit;return t===0?`(?R=${r})`:hh`\g<${t}&R=${r}>`}},dg=new Set([`$`,`(`,`)`,`*`,`+`,`.`,`?`,`[`,`\\`,`]`,`^`,`{`,`|`,`}`]),fg=new Set([`-`,`\\`,`]`,`^`,`[`]),pg=new Set("()-/[\\]^{|}!#$%&*+,.:;<=>?@`~".split(``)),mg=new Map([[9,hh`\t`],[10,hh`\n`],[11,hh`\v`],[12,hh`\f`],[13,hh`\r`],[8232,hh`\u2028`],[8233,hh`\u2029`],[65279,hh`\uFEFF`]]),hg=/^\p{Cased}$/u;function gg(e){return hg.test(e)}function _g(e,t){let n=!!t?.firstOnly,r=e.min.value,i=e.max.value,a=[];if(r<65&&(i===65535||i>=131071)||r===65536&&i>=131071)return a;for(let e=r;e<=i;e++){let t=mh(e);if(!gg(t))continue;let o=Oh(t).filter(e=>{let t=e.codePointAt(0);return t<r||t>i});if(o.length&&(a.push(...o),n))break}return a}function vg(e,{escDigit:t,inCharClass:n,useFlagV:r}){if(mg.has(e))return mg.get(e);if(e<32||e>126&&e<160||e>262143||t&&Cg(e))return e>255?`\\u{${e.toString(16).toUpperCase()}}`:`\\x${e.toString(16).toUpperCase().padStart(2,`0`)}`;let i=n?r?pg:fg:dg,a=mh(e);return(i.has(a)?`\\`:``)+a}function yg(e){let t=e.map(e=>e.codePointAt(0)).sort((e,t)=>e-t),n=[],r=null;for(let e=0;e<t.length;e++)t[e+1]===t[e]+1?r??=t[e]:r===null?n.push(t[e]):(n.push([r,t[e]]),r=null);return n}function bg(e,t,n){if(e)return`>`;let r=``;if(t&&n){let{enable:e,disable:n}=t;r=(e?.ignoreCase?`i`:``)+(e?.dotAll?`s`:``)+(n?`-`:``)+(n?.ignoreCase?`i`:``)+(n?.dotAll?`s`:``)}return`${r}:`}function xg({kind:e,max:t,min:n}){let r;return r=!n&&t===1?`?`:!n&&t===1/0?`*`:n===1&&t===1/0?`+`:n===t?`{${n}}`:`{${n},${t===1/0?``:t}}`,r+{greedy:``,lazy:`?`,possessive:`+`}[e]}function Sg({type:e}){return e===`CapturingGroup`||e===`Group`||e===`LookaroundAssertion`}function Cg(e){return e>47&&e<58}function wg({type:e,value:t}){return e===`Character`&&t===45}var Tg=class e extends RegExp{#e=new Map;#t=null;#n;#r=null;#i=null;rawOptions={};get source(){return this.#n||`(?:)`}constructor(t,n,r){let i=!!r?.lazyCompile;if(t instanceof RegExp){if(r)throw Error(`Cannot provide options when copying a regexp`);let i=t;super(i,n),this.#n=i.source,i instanceof e&&(this.#e=i.#e,this.#r=i.#r,this.#i=i.#i,this.rawOptions=i.rawOptions)}else{let e={hiddenCaptures:[],strategy:null,transfers:[],...r};super(i?``:t,n),this.#n=t,this.#e=Dg(e.hiddenCaptures,e.transfers),this.#i=e.strategy,this.rawOptions=r??{}}i||(this.#t=this)}exec(t){if(!this.#t){let{lazyCompile:t,...n}=this.rawOptions;this.#t=new e(this.#n,this.flags,n)}let n=this.global||this.sticky,r=this.lastIndex;if(this.#i===`clip_search`&&n&&r){this.lastIndex=0;let e=this.#a(t.slice(r));return e&&(Eg(e,r,t,this.hasIndices),this.lastIndex+=r),e}return this.#a(t)}#a(e){this.#t.lastIndex=this.lastIndex;let t=super.exec.call(this.#t,e);if(this.lastIndex=this.#t.lastIndex,!t||!this.#e.size)return t;let n=[...t];t.length=1;let r;this.hasIndices&&(r=[...t.indices],t.indices.length=1);let i=[0];for(let e=1;e<n.length;e++){let{hidden:a,transferTo:o}=this.#e.get(e)??{};if(a?i.push(null):(i.push(t.length),t.push(n[e]),this.hasIndices&&t.indices.push(r[e])),o&&n[e]!==void 0){let a=i[o];if(!a)throw Error(`Invalid capture transfer to "${a}"`);if(t[a]=n[e],this.hasIndices&&(t.indices[a]=r[e]),t.groups){this.#r||=Og(this.source);let i=this.#r.get(o);i&&(t.groups[i]=n[e],this.hasIndices&&(t.indices.groups[i]=r[e]))}}}return t}};function Eg(e,t,n,r){if(e.index+=t,e.input=n,r){let n=e.indices;for(let e=0;e<n.length;e++){let r=n[e];r&&(n[e]=[r[0]+t,r[1]+t])}let r=n.groups;r&&Object.keys(r).forEach(e=>{let n=r[e];n&&(r[e]=[n[0]+t,n[1]+t])})}}function Dg(e,t){let n=new Map;for(let t of e)n.set(t,{hidden:!0});for(let[e,r]of t)for(let t of r)yh(n,t,{}).transferTo=e;return n}function Og(e){let t=/(?<capture>\((?:\?<(?![=!])(?<name>[^>]+)>|(?!\?)))|\\?./gsu,n=new Map,r=0,i=0,a;for(;a=t.exec(e);){let{0:e,groups:{capture:t,name:o}}=a;e===`[`?r++:r?e===`]`&&r--:t&&(i++,o&&n.set(i,o))}return n}function kg(e,t){let n=Ag(e,t);return n.options?new Tg(n.pattern,n.flags,n.options):new RegExp(n.pattern,n.flags)}function Ag(e,t){let n=wh(t),r=Rh(tm(e,{flags:n.flags,normalizeUnknownPropertyNames:!0,rules:{captureGroup:n.rules.captureGroup,singleline:n.rules.singleline},skipBackrefValidation:n.rules.allowOrphanBackrefs,unicodePropertyMap:kh}),{accuracy:n.accuracy,asciiWordBoundaries:n.rules.asciiWordBoundaries,avoidSubclass:n.avoidSubclass,bestEffortTarget:n.target}),i=cg(r,n),a=ch(i.pattern,{captureTransfers:i._captureTransfers,hiddenCaptures:i._hiddenCaptures,mode:`external`}),o=Qm(th(a.pattern).pattern,{captureTransfers:a.captureTransfers,hiddenCaptures:a.hiddenCaptures}),s={pattern:o.pattern,flags:`${n.hasIndices?`d`:``}${n.global?`g`:``}${i.flags}${i.options.disable.v?`u`:`v`}`};if(n.avoidSubclass){if(n.lazyCompileLength!==1/0)throw Error(`Lazy compilation requires subclass`)}else{let e=o.hiddenCaptures.sort((e,t)=>e-t),t=Array.from(o.captureTransfers),i=r._strategy,a=s.pattern.length>=n.lazyCompileLength;(e.length||t.length||i||a)&&(s.options={...e.length&&{hiddenCaptures:e},...t.length&&{transfers:t},...i&&{strategy:i},...a&&{lazyCompile:a}})}return s}function jg(e,t){return kg(e,{global:!0,hasIndices:!0,lazyCompileLength:3e3,rules:{allowOrphanBackrefs:!0,asciiWordBoundaries:!0,captureGroup:!0,recursionLimit:5,singleline:!0},...t})}function Mg(e={}){let t={target:`auto`,cache:new Map,...e};return t.regexConstructor||=e=>jg(e,{target:t.target}),{createScanner(e){return new sp(e,t)},createString(e){return{content:e}}}}async function Ng(e){if(zc())throw 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.`);let t=Pc.get(e);if(t!=null)return t;try{let t=Fc.get(e);if(t==null&&Object.prototype.hasOwnProperty.call(Kc,e)&&(t=Kc[e]),t==null)throw Error(`resolveLanguage: "${e}" not found in bundled or custom languages`);let n=t().then(({default:t})=>{let n={name:e,data:t};return Nc.has(e)||Nc.set(e,n),n});return Pc.set(e,n),await n}finally{Pc.delete(e)}}function Pg(e){return Nc.get(e)??Ng(e)}function Fg(e){return typeof e==`object`&&e&&`default`in e?e.default:e}var Ig=class extends Error{constructor(e){super(`Theme "${e}" is already registered`),this.name=`DuplicateThemeError`}},Lg=class extends Error{constructor(e){super(`No loader registered for theme "${e}"`),this.name=`UnregisteredThemeError`}},Rg=class extends Error{constructor(e){super(`Theme "${e}" has not been resolved`),this.name=`UnresolvedThemeError`}};function zg(){let e=new Map,t=new Map,n=new Map,r=0;function i(t,n){if(e.has(t))throw new Ig(t);e.set(t,n)}function a(t,n){return e.has(t)?!1:(e.set(t,n),!0)}function o(t){return e.has(t)}function s(i){let a=t.get(i);if(a!==void 0)return Promise.resolve(a);let o=n.get(i);if(o!==void 0)return o;let s=e.get(i);if(s===void 0)return Promise.reject(new Lg(i));let c=r,l=s().then(e=>{let a=Fg(e);return c===r&&t.set(i,a),n.get(i)===l&&n.delete(i),a}).catch(e=>{throw n.get(i)===l&&n.delete(i),e});return n.set(i,l),l}function c(e){return Promise.all(e.map(e=>s(e)))}function l(e,n){t.set(e,n)}function u(e){for(let[t,n]of e)l(t,n)}function d(e){return t.get(e)}function f(e){let n=[];for(let r of e){let e=t.get(r);if(e===void 0)throw new Rg(r);n.push(e)}return n}function p(e){return t.has(e)}function m(e){for(let n of e)if(!t.has(n))return!1;return!0}function h(e){let n=t.get(e);return n===void 0?s(e):n}function g(){r++,t.clear(),n.clear()}return{clearResolvedThemes:g,getResolvedOrResolveTheme:h,getResolvedTheme:d,getResolvedThemes:f,hasRegisteredTheme:o,hasResolvedTheme:p,hasResolvedThemes:m,registerTheme:i,registerThemeIfAbsent:a,resolveTheme:s,resolveThemes:c,seedResolvedTheme:l,seedResolvedThemes:u}}var Bg=zg(),Vg=new Set;function Hg(e,t){e=Array.isArray(e)?e:[e];for(let n of e){let e;if(typeof n==`string`){if(e=Bg.getResolvedTheme(n),e==null)throw Error(`loadResolvedThemes: ${n} is not resolved, you must resolve it before calling loadResolvedThemes`)}else e=n,n=n.name,Bg.getResolvedTheme(n)??Bg.seedResolvedTheme(n,e);Vg.has(n)||(Vg.add(n),t.loadThemeSync(e))}}function Ug(e){let t=[],n=new Set;for(let r of Wg(e.themes)){let e=qg(r)?r.getThemes():[r];for(let r of e){if(n.has(r.name))throw Error(`Theme collection already contains theme "${r.name}"`);n.add(r.name),t.push(r)}}let r=Object.freeze([...t]),i=Object.freeze(r.filter(e=>e.colorScheme===`light`)),a=Object.freeze(r.filter(e=>e.colorScheme===`dark`)),o=new Map(r.map(e=>[e.name,e])),s=Object.freeze(r.map(e=>e.name)),c=Object.freeze(i.map(e=>e.name)),l=Object.freeze(a.map(e=>e.name));function u(e){if(e==null)return r;let{colorScheme:t,collection:n}=e;return n==null?t===`light`?i:t===`dark`?a:r:r.filter(e=>e.collection===n?t==null||e.colorScheme===t:!1)}return{getTheme(e){return o.get(e)},getThemes(e){return u(e)},getThemeNames(e){return e?.collection==null?e?.colorScheme===`light`?c:e?.colorScheme===`dark`?l:s:u(e).map(e=>e.name)},hasTheme(e){return o.has(e)},orderBy(e){return Ug({themes:r.map((e,t)=>({descriptor:e,index:t})).sort((t,n)=>{let r=e(t.descriptor,n.descriptor);return r===0?t.index-n.index:r}).map(e=>e.descriptor)})},pick(e){let t=[],n=new Set;for(let r of e){if(n.has(r))throw Error(`Theme collection pick already includes theme "${r}"`);n.add(r);let e=o.get(r);if(e==null)throw Error(`Theme collection does not contain theme "${r}"`);t.push(e)}return Ug({themes:t})},registerInto(e){for(let t of r)e.registerThemeIfAbsent(t.name,t.load)}}}function Wg(e){return Gg(e)?[e]:e}function Gg(e){return qg(e)||Kg(e)}function Kg(e){return typeof e.name==`string`&&typeof e.load==`function`}function qg(e){return typeof e.getThemes==`function`}function Jg({name:e,load:t,colorScheme:n,collection:r,displayName:i}){return{name:e,colorScheme:n,collection:r,displayName:i,load:Yg(t)}}function Yg(e){return async()=>Od(Fg(await e()))}var Xg=`pierre`,Zg=[`pierre-dark`,`pierre-dark-soft`,`pierre-dark-vibrant`,`pierre-dark-protanopia-deuteranopia`,`pierre-dark-tritanopia`],Qg=[`pierre-light`,`pierre-light-soft`,`pierre-light-vibrant`,`pierre-light-protanopia-deuteranopia`,`pierre-light-tritanopia`],$g=[...Qg,...Zg],e_=new Set(Qg);function t_(e){return e_.has(e)?`light`:`dark`}var n_={"pierre-dark":`Pierre Dark`,"pierre-dark-soft":`Pierre Dark Soft`,"pierre-dark-vibrant":`Pierre Dark Vibrant`,"pierre-dark-protanopia-deuteranopia":`Pierre Dark Protanopia & Deuteranopia`,"pierre-dark-tritanopia":`Pierre Dark Tritanopia`,"pierre-light":`Pierre Light`,"pierre-light-soft":`Pierre Light Soft`,"pierre-light-vibrant":`Pierre Light Vibrant`,"pierre-light-protanopia-deuteranopia":`Pierre Light Protanopia & Deuteranopia`,"pierre-light-tritanopia":`Pierre Light Tritanopia`},r_={"pierre-dark":()=>G(()=>import(`./pierre-dark-CpLgRqie.js`),[]),"pierre-dark-soft":()=>G(()=>import(`./pierre-dark-soft-kZQmAZld.js`),[]),"pierre-dark-vibrant":()=>G(()=>import(`./pierre-dark-vibrant-CpQYzh95.js`),[]),"pierre-dark-protanopia-deuteranopia":()=>G(()=>import(`./pierre-dark-protanopia-deuteranopia-B35FxJx-.js`),[]),"pierre-dark-tritanopia":()=>G(()=>import(`./pierre-dark-tritanopia-CpjhbsIL.js`),[]),"pierre-light":()=>G(()=>import(`./pierre-light-CoaEpmwp.js`),[]),"pierre-light-soft":()=>G(()=>import(`./pierre-light-soft-lWLdNTOI.js`),[]),"pierre-light-vibrant":()=>G(()=>import(`./pierre-light-vibrant-D80Fkn33.js`),[]),"pierre-light-protanopia-deuteranopia":()=>G(()=>import(`./pierre-light-protanopia-deuteranopia-0fSaH845.js`),[]),"pierre-light-tritanopia":()=>G(()=>import(`./pierre-light-tritanopia-CEbqgOJL.js`),[])};function i_(e){return Jg({name:e,collection:Xg,colorScheme:t_(e),displayName:n_[e],load:r_[e]})}var a_=Ug({themes:$g.map(e=>i_(e))}),o_=`shiki`,s_=[`ayu-light`,`catppuccin-latte`,`everforest-light`,`github-light`,`github-light-default`,`github-light-high-contrast`,`gruvbox-light-hard`,`gruvbox-light-medium`,`gruvbox-light-soft`,`horizon-bright`,`kanagawa-lotus`,`light-plus`,`material-theme-lighter`,`min-light`,`night-owl-light`,`one-light`,`rose-pine-dawn`,`slack-ochin`,`snazzy-light`,`solarized-light`,`vitesse-light`],c_=`andromeeda.aurora-x.ayu-dark.ayu-mirage.catppuccin-frappe.catppuccin-macchiato.catppuccin-mocha.dark-plus.dracula.dracula-soft.everforest-dark.github-dark.github-dark-default.github-dark-dimmed.github-dark-high-contrast.gruvbox-dark-hard.gruvbox-dark-medium.gruvbox-dark-soft.horizon.houston.kanagawa-dragon.kanagawa-wave.laserwave.material-theme.material-theme-darker.material-theme-ocean.material-theme-palenight.min-dark.monokai.night-owl.nord.one-dark-pro.plastic.poimandres.red.rose-pine.rose-pine-moon.slack-dark.solarized-dark.synthwave-84.tokyo-night.vesper.vitesse-black.vitesse-dark`.split(`.`),l_=new Set(s_);function u_(e){return l_.has(e)?`light`:`dark`}var d_={andromeeda:()=>G(()=>import(`./andromeeda-vGVdxbeo.js`),[]),"aurora-x":()=>G(()=>import(`./aurora-x-CDeNXAV0.js`),[]),"ayu-dark":()=>G(()=>import(`./ayu-dark-DluEY0Gj.js`),[]),"ayu-light":()=>G(()=>import(`./ayu-light-C3h-C4tm.js`),[]),"ayu-mirage":()=>G(()=>import(`./ayu-mirage-Bqwy1Gya.js`),[]),"catppuccin-frappe":()=>G(()=>import(`./catppuccin-frappe-3VR1Za6u.js`),[]),"catppuccin-latte":()=>G(()=>import(`./catppuccin-latte-DwIHMF0Q.js`),[]),"catppuccin-macchiato":()=>G(()=>import(`./catppuccin-macchiato-DYnBP6_5.js`),[]),"catppuccin-mocha":()=>G(()=>import(`./catppuccin-mocha-DYhrFGRu.js`),[]),"dark-plus":()=>G(()=>import(`./dark-plus-Cs2F2srj.js`),[]),dracula:()=>G(()=>import(`./dracula-BHWKrbxM.js`),[]),"dracula-soft":()=>G(()=>import(`./dracula-soft-5eyTD99u.js`),[]),"everforest-dark":()=>G(()=>import(`./everforest-dark-sB-x3p7T.js`),[]),"everforest-light":()=>G(()=>import(`./everforest-light-Df2xbC6M.js`),[]),"github-dark":()=>G(()=>import(`./github-dark-C-LZuMrd.js`),[]),"github-dark-default":()=>G(()=>import(`./github-dark-default-DXG-b-1a.js`),[]),"github-dark-dimmed":()=>G(()=>import(`./github-dark-dimmed-Bx1FflLF.js`),[]),"github-dark-high-contrast":()=>G(()=>import(`./github-dark-high-contrast-B_tTalzw.js`),[]),"github-light":()=>G(()=>import(`./github-light-EUqPIrTm.js`),[]),"github-light-default":()=>G(()=>import(`./github-light-default-BXViO-2h.js`),[]),"github-light-high-contrast":()=>G(()=>import(`./github-light-high-contrast-B68TUdTA.js`),[]),"gruvbox-dark-hard":()=>G(()=>import(`./gruvbox-dark-hard-C820rvS2.js`),[]),"gruvbox-dark-medium":()=>G(()=>import(`./gruvbox-dark-medium-BPjhmG05.js`),[]),"gruvbox-dark-soft":()=>G(()=>import(`./gruvbox-dark-soft-MrdJrrXF.js`),[]),"gruvbox-light-hard":()=>G(()=>import(`./gruvbox-light-hard-BC_s9l72.js`),[]),"gruvbox-light-medium":()=>G(()=>import(`./gruvbox-light-medium-BAWPOn9u.js`),[]),"gruvbox-light-soft":()=>G(()=>import(`./gruvbox-light-soft-BSMLrYjP.js`),[]),horizon:()=>G(()=>import(`./horizon-CE9ld1lL.js`),[]),"horizon-bright":()=>G(()=>import(`./horizon-bright-DSNQnXHK.js`),[]),houston:()=>G(()=>import(`./houston-CsvMBhTu.js`),[]),"kanagawa-dragon":()=>G(()=>import(`./kanagawa-dragon-CXtmUGW6.js`),[]),"kanagawa-lotus":()=>G(()=>import(`./kanagawa-lotus-BN08jTvb.js`),[]),"kanagawa-wave":()=>G(()=>import(`./kanagawa-wave-CTweb8Dz.js`),[]),laserwave:()=>G(()=>import(`./laserwave-C_8bwKvT.js`),[]),"light-plus":()=>G(()=>import(`./light-plus-DVQuIRkW.js`),[]),"material-theme":()=>G(()=>import(`./material-theme-Bm3Qr25_.js`),[]),"material-theme-darker":()=>G(()=>import(`./material-theme-darker-2IIEA8gg.js`),[]),"material-theme-lighter":()=>G(()=>import(`./material-theme-lighter-uhdI0v04.js`),[]),"material-theme-ocean":()=>G(()=>import(`./material-theme-ocean-CHQ94UKr.js`),[]),"material-theme-palenight":()=>G(()=>import(`./material-theme-palenight-B5W6OYN7.js`),[]),"min-dark":()=>G(()=>import(`./min-dark-BSWPekZh.js`),[]),"min-light":()=>G(()=>import(`./min-light-DDpmG2fV.js`),[]),monokai:()=>G(()=>import(`./monokai-CdkpiU2Y.js`),[]),"night-owl":()=>G(()=>import(`./night-owl-DhmEMT88.js`),[]),"night-owl-light":()=>G(()=>import(`./night-owl-light-eJ-hLW7d.js`),[]),nord:()=>G(()=>import(`./nord-Cb4Vim4T.js`),[]),"one-dark-pro":()=>G(()=>import(`./one-dark-pro-CLwyXe_n.js`),[]),"one-light":()=>G(()=>import(`./one-light-D7Lr4KcI.js`),[]),plastic:()=>G(()=>import(`./plastic-DQwYfKfQ.js`),[]),poimandres:()=>G(()=>import(`./poimandres-DRFjx7u4.js`),[]),red:()=>G(()=>import(`./red-CJ3rzSJv.js`),[]),"rose-pine":()=>G(()=>import(`./rose-pine-BthvhNj6.js`),[]),"rose-pine-dawn":()=>G(()=>import(`./rose-pine-dawn-Dg85fqjY.js`),[]),"rose-pine-moon":()=>G(()=>import(`./rose-pine-moon-hon4tzzS.js`),[]),"slack-dark":()=>G(()=>import(`./slack-dark-DnToyrRv.js`),[]),"slack-ochin":()=>G(()=>import(`./slack-ochin-B2OO5cIa.js`),[]),"snazzy-light":()=>G(()=>import(`./snazzy-light-4G7pJPwS.js`),[]),"solarized-dark":()=>G(()=>import(`./solarized-dark-DV17i1UV.js`),[]),"solarized-light":()=>G(()=>import(`./solarized-light-DSh2HLQt.js`),[]),"synthwave-84":()=>G(()=>import(`./synthwave-84-nFMaYfgc.js`),[]),"tokyo-night":()=>G(()=>import(`./tokyo-night-oM2G3aXe.js`),[]),vesper:()=>G(()=>import(`./vesper-DdrHHSXu.js`),[]),"vitesse-black":()=>G(()=>import(`./vitesse-black-fwtXNY1n.js`),[]),"vitesse-dark":()=>G(()=>import(`./vitesse-dark-BZCL-v6S.js`),[]),"vitesse-light":()=>G(()=>import(`./vitesse-light-VbXTXTou.js`),[])};function f_(e){return Jg({name:e,collection:o_,colorScheme:u_(e),load:d_[e]})}var p_=Ug({themes:Object.freeze([...s_.map(e=>f_(e)),...c_.map(e=>f_(e))])});function m_(e){if(zc())throw Error(`Theme "${e}" cannot be resolved from a worker context. Themes must be pre-resolved on the main thread and passed to the worker via the resolvedLanguages parameter.`);if(Bg.hasRegisteredTheme(e))return;let t=p_.getTheme(e);if(t!=null){Bg.registerThemeIfAbsent(t.name,t.load);return}throw Error(`No valid theme loader registered for "${e}"`)}function h_(e,t){if(t.name!==e)throw Error(`resolvedTheme: themeName: ${e} does not match theme.name: ${t.name}`)}async function g_(e){m_(e);let t=await Bg.resolveTheme(e);return h_(e,t),t}function __(e){return Bg.getResolvedTheme(e)??g_(e)}var v_;async function y_({themes:e,langs:t,preferredHighlighter:n=`shiki-js`}){v_??=Qf({themes:[],langs:[`text`],engine:n===`shiki-wasm`?Ol(G(()=>import(`./wasm-BnjxR4X6.js`),[])):Mg()});let r=x_(v_)?await v_:v_;v_=r;let i=[];for(let e of t){if(e===`text`||e===`ansi`)continue;let t=Pg(e);`then`in t?i.push(t):Rc(t,r)}let a=[];for(let t of e){let e=__(t);`then`in e?a.push(e):Hg(e,v_)}return(i.length>0||a.length>0)&&await Promise.all([Promise.all(i).then(e=>{Rc(e,r)}),Promise.all(a).then(e=>{Hg(e,r)})]),r}function b_(){if(v_!=null&&!(`then`in v_))return v_}function x_(e=v_){return e!=null&&`then`in e}for(let e of a_.getThemes())Bg.registerThemeIfAbsent(e.name,e.load);function S_(e=Gr){let t=[];return typeof e==`string`?t.push(e):(t.push(e.dark),t.push(e.light)),t}function C_(e){for(let t of S_(e))if(!Vg.has(t))return!1;return!0}function w_(e){return zi({tagName:`div`,children:[zi({tagName:`div`,children:e.annotations?.map(e=>zi({tagName:`slot`,properties:{name:e}})),properties:{"data-annotation-content":``}})],properties:{"data-line-annotation":`${e.hunkIndex},${e.lineIndex}`}})}function T_(e,t){return zi({tagName:`div`,children:e,properties:{"data-content":``,style:`grid-row: span ${t}`}})}function E_(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 D_({fileOrDiff:e,mode:t,stickyHeader:n}){let r=`type`in e?e:void 0,i={"data-diffs-header":t,"data-change-type":r?.type,"data-sticky":n?``:void 0};return zi({tagName:`div`,children:[t===`custom`?zi({tagName:`slot`,properties:{name:Wr}}):O_({name:e.name,prevName:`prevName`in e?e.prevName:void 0,iconType:r?.type??`file`}),...t===`custom`?[]:[k_(r)]],properties:i})}function O_({name:e,prevName:t,iconType:n}){let r=[zi({tagName:`slot`,properties:{name:Hr}}),Bi({name:E_(n),properties:{"data-change-icon":n}})];return t!=null&&(r.push(zi({tagName:`div`,children:[zi({tagName:`bdi`,children:[Ri(t)]})],properties:{"data-prev-name":``}})),r.push(Bi({name:`diffs-icon-arrow-right-short`,properties:{"data-rename-icon":``}}))),r.push(zi({tagName:`div`,children:[zi({tagName:`bdi`,children:[Ri(e)]})],properties:{"data-title":``}})),zi({tagName:`div`,children:r,properties:{"data-header-content":``}})}function k_(e){let t=[];if(e!=null){let n=0,r=0;for(let t of e.hunks)n+=t.additionLines,r+=t.deletionLines;(r>0||n===0)&&t.push(zi({tagName:`span`,children:[Ri(`-${r}`)],properties:{"data-deletions-count":``}})),(n>0||r===0)&&t.push(zi({tagName:`span`,children:[Ri(`+${n}`)],properties:{"data-additions-count":``}}))}return t.push(zi({tagName:`slot`,properties:{name:Ur}})),zi({tagName:`div`,children:t,properties:{"data-metadata":``}})}function A_(e){return zi({tagName:`pre`,properties:j_(e)})}function j_({diffIndicators:e,disableBackground:t,disableLineNumbers:n,overflow:r,split:i,totalLines:a,type:o,customProperties:s}){return{...s,"data-diff":o===`diff`?``:void 0,"data-file":o===`file`?``:void 0,"data-diff-type":o===`diff`?i?`split`:`single`:void 0,"data-overflow":r,"data-disable-line-numbers":n?``:void 0,"data-background":t?void 0:``,"data-indicators":e===`bars`||e===`classic`?e:void 0,style:`--diffs-min-number-column-width-default:${`${a}`.length}ch;`}}function M_(e,{theme:t,preferredHighlighter:n=`shiki-js`}){return{langs:[e??`text`],themes:S_(t),preferredHighlighter:n}}function N_(e){return e.useTokenTransformer===!0||e.onTokenClick!=null||e.onTokenEnter!=null||e.onTokenLeave!=null}function P_(e,t){return e===t||e?.cacheKey!=null&&e.cacheKey===t?.cacheKey}function F_({isPartial:e,rangeSize:t,expandedHunks:n,hunkIndex:r,collapsedContextThreshold:i}){let a=Math.max(t,0);if(a===0||e)return{fromStart:0,fromEnd:0,rangeSize:a,collapsedLines:a,renderAll:!1};if(n===!0||a<=i)return{fromStart:a,fromEnd:0,rangeSize:a,collapsedLines:0,renderAll:!0};let o=n?.get(r),s=Math.min(Math.max(o?.fromStart??0,0),a),c=Math.min(Math.max(o?.fromEnd??0,0),a),l=s+c,u=l>=a;return{fromStart:u?a:s,fromEnd:u?0:c,rangeSize:a,collapsedLines:Math.max(a-l,0),renderAll:u}}function I_({fileDiff:e,errorPrefix:t}){let n=e.hunks[e.hunks.length-1];if(n==null||e.isPartial||e.additionLines.length===0||e.deletionLines.length===0)return 0;let r=e.additionLines.length-(n.additionLineIndex+n.additionCount),i=e.deletionLines.length-(n.deletionLineIndex+n.deletionCount);if(r<=0&&i<=0)return 0;if(r!==i)throw Error(`${t}: trailing context mismatch (additions=${r}, deletions=${i}) for ${e.name}`);return Math.min(r,i)}function L_({fileDiff:e,hunkIndex:t,expandedHunks:n,collapsedContextThreshold:r,errorPrefix:i}){if(t!==e.hunks.length-1)return;let a=I_({fileDiff:e,errorPrefix:i});if(a<=0)return;if(n===!0||a<=r)return{fromStart:a,fromEnd:0,rangeSize:a,collapsedLines:0,renderAll:!0};let o=n?.get(e.hunks.length),s=Math.min(Math.max(o?.fromStart??0,0),a);return{fromStart:s,fromEnd:0,rangeSize:a,collapsedLines:a-s,renderAll:s>=a}}function R_({diff:e,diffStyle:t,startingLine:n=0,totalLines:r=1/0,expandedHunks:i,collapsedContextThreshold:a=1,callback:o}){let s=z_({diff:e,diffStyle:t,startingLine:n,expandedHunks:i,collapsedContextThreshold:a}),c={viewportStart:n,viewportEnd:n+r,isWindowedHighlight:n>0||r<1/0,splitCount:s.splitCount,unifiedCount:s.unifiedCount,finalHunkIndex:e.hunks.length-1,shouldBreak(){if(!c.isWindowedHighlight)return!1;let e=c.unifiedCount>=n+r,i=c.splitCount>=n+r;return t===`unified`?e:(t===`split`||e)&&i},shouldSkip(e,r){if(!c.isWindowedHighlight)return!1;let i=c.unifiedCount+e<n,a=c.splitCount+r<n;return t===`unified`?i:(t===`split`||i)&&a},incrementCounts(e,n){(t===`unified`||t===`both`)&&(c.unifiedCount+=e),(t===`split`||t===`both`)&&(c.splitCount+=n)},isInWindow(e,n){if(!c.isWindowedHighlight)return!0;let r=c.isInUnifiedWindow(e),i=c.isInSplitWindow(n);return t===`unified`?r:t===`split`?i:r||i},isInUnifiedWindow(e){return!c.isWindowedHighlight||c.unifiedCount>=n-e&&c.unifiedCount<n+r},isInSplitWindow(e){return!c.isWindowedHighlight||c.splitCount>=n-e&&c.splitCount<n+r},emit(e,n=!1){return n||(t===`unified`?c.incrementCounts(1,0):t===`split`?c.incrementCounts(0,1):c.incrementCounts(1,1)),o(e)??!1}};hunkIterator:for(let n=s.hunkIndex;n<e.hunks.length;n++){let r=e.hunks[n];if(r==null)throw Error(`iterateOverDiff: invalid hunk index`);if(c.shouldBreak())break;let o=F_({isPartial:e.isPartial,rangeSize:r.collapsedBefore,expandedHunks:i,hunkIndex:n,collapsedContextThreshold:a}),s=n===c.finalHunkIndex?L_({fileDiff:e,hunkIndex:n,expandedHunks:i,collapsedContextThreshold:a,errorPrefix:`iterateOverDiff`}):void 0,l=o.fromStart+o.fromEnd;function u(e,n){return s==null||s.collapsedLines<=0||s.fromStart+s.fromEnd>0?0:t===`unified`?e===r.unifiedLineStart+r.unifiedLineCount-1?s.collapsedLines:0:n===r.splitLineStart+r.splitLineCount-1?s.collapsedLines:0}let d=o.collapsedLines===0;function f(){return d?0:(d=!0,o.collapsedLines)}if(c.shouldSkip(l,l))c.incrementCounts(l,l),f();else{let e=r.unifiedLineStart-o.rangeSize,i=r.splitLineStart-o.rangeSize,a=r.deletionLineIndex-o.rangeSize,s=r.additionLineIndex-o.rangeSize,l=r.deletionStart-o.rangeSize,u=r.additionStart-o.rangeSize;if(H_(c,o.fromStart,t,t=>c.emit({hunkIndex:n,hunk:r,collapsedBefore:0,collapsedAfter:0,type:`context-expanded`,deletionLine:{lineNumber:l+t,lineIndex:a+t,noEOFCR:!1,unifiedLineIndex:e+t,splitLineIndex:i+t},additionLine:{unifiedLineIndex:e+t,splitLineIndex:i+t,lineIndex:s+t,lineNumber:u+t,noEOFCR:!1}}))||(e=r.unifiedLineStart-o.fromEnd,i=r.splitLineStart-o.fromEnd,a=r.deletionLineIndex-o.fromEnd,s=r.additionLineIndex-o.fromEnd,l=r.deletionStart-o.fromEnd,u=r.additionStart-o.fromEnd,H_(c,o.fromEnd,t,t=>c.emit({hunkIndex:n,hunk:r,collapsedBefore:f(),collapsedAfter:0,type:`context-expanded`,deletionLine:{lineNumber:l+t,lineIndex:a+t,noEOFCR:!1,unifiedLineIndex:e+t,splitLineIndex:i+t},additionLine:{unifiedLineIndex:e+t,splitLineIndex:i+t,lineIndex:s+t,lineNumber:u+t,noEOFCR:!1}}),()=>{f()})))break hunkIterator}let p=r.unifiedLineStart,m=r.splitLineStart,h=r.deletionLineIndex,g=r.additionLineIndex,_=r.deletionStart,v=r.additionStart,y=r.hunkContent.at(-1);for(let e of r.hunkContent){if(c.shouldBreak())break hunkIterator;let i=e===y;if(e.type===`context`){if(c.shouldSkip(e.lines,e.lines))c.incrementCounts(e.lines,e.lines),f();else if(H_(c,e.lines,t,t=>{let a=i&&t===e.lines-1,o=p+t,s=m+t;return c.emit({hunkIndex:n,hunk:r,collapsedBefore:f(),collapsedAfter:u(o,s),type:`context`,deletionLine:{lineNumber:_+t,lineIndex:h+t,noEOFCR:a&&r.noEOFCRDeletions,unifiedLineIndex:o,splitLineIndex:s},additionLine:{unifiedLineIndex:o,splitLineIndex:s,lineIndex:g+t,lineNumber:v+t,noEOFCR:a&&r.noEOFCRAdditions}})},()=>{f()}))break hunkIterator;p+=e.lines,m+=e.lines,h+=e.lines,g+=e.lines,_+=e.lines,v+=e.lines}else{let a=Math.max(e.deletions,e.additions),o=e.deletions+e.additions;if(!c.shouldSkip(o,a)){let s=U_(c,e,t);(s[0]?.[0]??0)>0&&f();for(let[l,d]of s)for(let s=l;s<d;s++){let l=u(p+s,t===`unified`?m+(s<e.deletions?s:s-e.deletions):m+s);if(c.emit(W_({hunkIndex:n,hunk:r,collapsedBefore:f(),collapsedAfter:l,diffStyle:t,index:s,unifiedLineIndex:p,splitLineIndex:m,additionLineIndex:g,deletionLineIndex:h,additionLineNumber:v,deletionLineNumber:_,content:e,isLastContent:i,unifiedCount:o,splitCount:a}),!0))break hunkIterator}}f(),c.incrementCounts(o,a),p+=o,m+=a,h+=e.deletions,g+=e.additions,_+=e.deletions,v+=e.additions}}if(s!=null){let{collapsedLines:n,fromStart:r,fromEnd:i}=s,a=r+i;if(H_(c,a,t,t=>{let r=t===a-1;return c.emit({hunkIndex:e.hunks.length,hunk:void 0,collapsedBefore:0,collapsedAfter:r?n:0,type:`context-expanded`,deletionLine:{lineNumber:_+t,lineIndex:h+t,noEOFCR:!1,unifiedLineIndex:p+t,splitLineIndex:m+t},additionLine:{unifiedLineIndex:p+t,splitLineIndex:m+t,lineIndex:g+t,lineNumber:v+t,noEOFCR:!1}})},void 0,()=>c.shouldBreak()))break hunkIterator}}}function z_({diff:e,diffStyle:t,startingLine:n,expandedHunks:r,collapsedContextThreshold:i}){if(n<=0||t===`both`)return{hunkIndex:0,splitCount:0,unifiedCount:0};let a=B_({diff:e,expandedHunks:r,collapsedContextThreshold:i}),o=0,s=e.hunks.length-1,c=e.hunks.length;for(;o<=s;){let e=o+s>>1,r=a[e+1];if(r==null)throw Error(`iterateOverDiff: invalid hunk prefix index`);(t===`unified`?r.unifiedCount:r.splitCount)>n?(c=e,s=e-1):o=e+1}if(c>=e.hunks.length){let t=a[e.hunks.length];if(t==null)throw Error(`iterateOverDiff: invalid terminal hunk prefix index`);return{hunkIndex:e.hunks.length,splitCount:t.splitCount,unifiedCount:t.unifiedCount}}let l=a[c];if(l==null)throw Error(`iterateOverDiff: invalid selected hunk prefix index`);return{hunkIndex:c,splitCount:l.splitCount,unifiedCount:l.unifiedCount}}function B_({diff:e,expandedHunks:t,collapsedContextThreshold:n}){let r=0,i=0,a=e.hunks.length-1,o=[{splitCount:0,unifiedCount:0}];for(let s=0;s<e.hunks.length;s++){let c=e.hunks[s];if(c==null)throw Error(`iterateOverDiff: invalid hunk summary index`);let l=F_({isPartial:e.isPartial,rangeSize:c.collapsedBefore,expandedHunks:t,hunkIndex:s,collapsedContextThreshold:n}),u=l.fromStart+l.fromEnd;r+=u+c.splitLineCount,i+=u+c.unifiedLineCount;let d=s===a?L_({fileDiff:e,hunkIndex:s,expandedHunks:t,collapsedContextThreshold:n,errorPrefix:`iterateOverDiff`}):void 0;if(d!=null){let e=d.fromStart+d.fromEnd;r+=e,i+=e}o.push({splitCount:r,unifiedCount:i})}return o}function V_(e,t,n){if(!e.isWindowedHighlight||t<=0)return[0,t];let r=[];function i(n){let i=Math.max(0,e.viewportStart-n),a=Math.min(t,e.viewportEnd-n);a>i&&r.push([i,a])}if(n!==`split`&&i(e.unifiedCount),n!==`unified`&&i(e.splitCount),r.length===0)return[0,0];let a=r[0][0],o=r[0][1];for(let e=1;e<r.length;e++){let t=r[e];a=Math.min(a,t[0]),o=Math.max(o,t[1])}return[a,o]}function H_(e,t,n,r,i,a){let[o,s]=V_(e,t,n);o>0&&(e.incrementCounts(o,o),i?.());let c=o;for(;c<t;){if(a?.()===!0)return!0;if(c>=s){e.incrementCounts(t-c,t-c);break}if(e.isInWindow(0,0)){if(r(c)===!0)return!0}else e.incrementCounts(1,1);c++}return!1}function U_(e,t,n){if(!e.isWindowedHighlight)return[[0,n===`unified`?t.deletions+t.additions:Math.max(t.deletions,t.additions)]];let r=n!==`split`,i=n!==`unified`,a=n===`unified`?`unified`:`split`,o=[];function s(t,n){if(t+n<=e.viewportStart||t>=e.viewportEnd)return;let r=Math.max(0,e.viewportStart-t),i=Math.min(n,e.viewportEnd-t);return i>r?[r,i]:void 0}function c(e,n){return a===`split`?e:n===`additions`?[e[0]+t.deletions,e[1]+t.deletions]:e}function l(e,t){if(e==null)return;let[n,r]=c(e,t);r>n&&o.push([n,r])}if(r&&(l(s(e.unifiedCount,t.deletions),`deletions`),l(s(e.unifiedCount+t.deletions,t.additions),`additions`)),i&&(l(s(e.splitCount,t.deletions),`deletions`),l(s(e.splitCount,t.additions),`additions`)),o.length===0)return o;o.sort((e,t)=>e[0]-t[0]);let u=[o[0]];for(let[e,t]of o.slice(1)){let n=u[u.length-1];e<=n[1]?n[1]=Math.max(n[1],t):u.push([e,t])}return u}function W_({hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,diffStyle:i,index:a,unifiedLineIndex:o,splitLineIndex:s,additionLineIndex:c,deletionLineIndex:l,additionLineNumber:u,deletionLineNumber:d,content:f,isLastContent:p,unifiedCount:m,splitCount:h}){let g=a<f.deletions?o+a:void 0,_=i===`unified`?a>=f.deletions?o+a:void 0:a<f.additions?o+f.deletions+a:void 0,v=i===`unified`?s+(a<f.deletions?a:a-f.deletions):s+a,y=a<f.deletions?l+a:void 0,b=a<f.deletions?d+a:void 0,x=i===`unified`?a>=f.deletions?c+(a-f.deletions):void 0:a<f.additions?c+a:void 0,S=i===`unified`?a>=f.deletions?u+(a-f.deletions):void 0:a<f.additions?u+a:void 0,C=i===`unified`?p&&a===f.deletions-1&&t.noEOFCRDeletions:p&&a===h-1&&t.noEOFCRDeletions,w=i===`unified`?p&&a===m-1&&t.noEOFCRAdditions:p&&a===h-1&&t.noEOFCRAdditions,T=y!=null&&b!=null&&g!=null?{lineNumber:b,lineIndex:y,noEOFCR:C,unifiedLineIndex:g,splitLineIndex:v}:void 0,E=x!=null&&S!=null&&_!=null?{unifiedLineIndex:_,splitLineIndex:v,lineIndex:x,lineNumber:S,noEOFCR:w}:void 0;if(T==null&&E!=null)return{type:`change`,hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:void 0,additionLine:E};if(T!=null&&E==null)return{type:`change`,hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:T,additionLine:void 0};if(T==null||E==null)throw Error(`iterateOverDiff: missing change line data`);return{type:`change`,hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:T,additionLine:E}}function G_(e,t){return Pi(e.theme,t.theme)&&e.useTokenTransformer===t.useTokenTransformer&&e.tokenizeMaxLineLength===t.tokenizeMaxLineLength&&e.lineDiffType===t.lineDiffType&&e.maxLineDiffLength===t.maxLineDiffLength}function K_(e){return zi({tagName:`div`,properties:{"data-content-buffer":``,"data-buffer-size":e,style:`grid-row: span ${e};min-height:calc(${e} * 1lh)`}})}function q_(e){return zi({tagName:`div`,children:[zi({tagName:`span`,children:[Ri(`No newline at end of file`)]})],properties:{"data-no-newline":``,"data-line-type":e,"data-column-content":``}})}function J_(e){return zi({tagName:`div`,children:[Bi({name:e===`both`?`diffs-icon-expand-all`:`diffs-icon-expand`,properties:{"data-icon":``}})],properties:{role:`button`,"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 Y_({type:e,content:t,expandIndex:n,chunked:r=!1,slotName:i,isFirstHunk:a,isLastHunk:o}){let s=0,c=[];if(e===`metadata`&&t!=null&&c.push(zi({tagName:`div`,children:[Ri(t)],properties:{"data-separator-wrapper":``}})),(e===`line-info`||e===`line-info-basic`)&&t!=null){let e=[];n!=null&&(r?(a||(e.push(J_(`up`)),s++),o||(e.push(J_(`down`)),s++)):(e.push(J_(!a&&!o?`both`:a?`down`:`up`)),s++)),e.push(zi({tagName:`div`,children:[zi({tagName:`span`,children:[Ri(t)],properties:{"data-unmodified-lines":``}})],properties:{"data-separator-content":``}})),r&&n!=null&&e.push(zi({tagName:`div`,children:[Ri(`Expand all`)],properties:{role:`button`,"data-expand-button":``,"data-expand-all-button":``}})),c.push(zi({tagName:`div`,children:e,properties:{"data-separator-wrapper":``,"data-separator-multi-button":s>1?``:void 0}}))}return e===`custom`&&i!=null&&c.push(zi({tagName:`slot`,properties:{name:i}})),zi({tagName:`div`,children:c,properties:{"data-separator":c.length===0?`simple`:e,"data-expand-index":n,"data-separator-first":a?``:void 0,"data-separator-last":o?``:void 0}})}function X_(e,t){return`hunk-separator-${e}-${t}`}function Z_(e){let t=e.at(-1);return t==null?0:Math.max(t.additionStart+t.additionCount,t.deletionStart+t.deletionCount)}function Q_(e){return e.startingLine===0&&e.totalLines===1/0&&e.bufferBefore===0&&e.bufferAfter===0}function $_(e,t,n){let r=typeof n.lineInfo==`function`?n.lineInfo(t):n.lineInfo[t-1];if(r==null){let r=`processLine: line ${t}, contains no state.lineInfo`;throw console.error(r,{node:e,line:t,state:n}),Error(r)}return e.tagName=`div`,e.properties[`data-line`]=r.lineNumber,e.properties[`data-alt-line`]=r.altLineNumber,e.properties[`data-line-type`]=r.type,e.properties[`data-line-index`]=r.lineIndex,e.children.length===0&&e.children.push(Ri(`
1558
+ `)),e}var ev=Symbol(`no-token`),tv=Symbol(`multiple-tokens`);function nv(e){let t=rv(e);if(t!=null)return t;let n=ev,r=[],i=[],a,o=()=>{if(i.length===0||a==null){i=[],a=void 0;return}if(i.length===1){let e=i[0];if(e?.type===`element`){av(e,a);for(let t of e.children)iv(t)}else iv(e);r.push(e),i=[],a=void 0;return}for(let e of i)iv(e);r.push(zi({tagName:`span`,properties:{"data-char":a},children:i})),i=[],a=void 0},s=e=>{if(e!==ev){if(e===tv){n=tv;return}if(n===ev){n=e;return}n!==e&&(n=tv)}};for(let t of e.children){let e=t.type===`element`?nv(t):ev;if(s(e),typeof e!=`number`){o(),r.push(t);continue}a!=null&&a!==e&&o(),a??=e,i.push(t)}return o(),e.children=r,n}function rv(e){let t=e.properties[`data-char`];if(typeof t==`number`)return t}function iv(e){if(e.type===`element`){e.properties[`data-char`]=void 0;for(let t of e.children)iv(t)}}function av(e,t){e.properties[`data-char`]=t}function ov(e={}){let{classPrefix:t=`__shiki_`,classSuffix:n=``,classReplacer:r=e=>e}=e,i=new Map;function a(e){return Object.entries(e).map(([e,t])=>`${e}:${t}`).join(`;`)}function o(e){let o=t+sv(typeof e==`string`?e:a(e))+n;return o=r(o),i.has(o)||i.set(o,typeof e==`string`?e:{...e}),o}return{name:`@shikijs/transformers:style-to-class`,pre(e){if(!e.properties.style)return;let t=o(e.properties.style);delete e.properties.style,this.addClassToHast(e,t)},tokens(e){for(let t of e)for(let e of t){if(!e.htmlStyle)continue;let t=o(e.htmlStyle);e.htmlStyle={},e.htmlAttrs||={},e.htmlAttrs.class?e.htmlAttrs.class+=` ${t}`:e.htmlAttrs.class=t}},getClassRegistry(){return i},getCSS(){let e=``;for(let[t,n]of i.entries())e+=`.${t}{${typeof n==`string`?n:a(n)}}`;return e},clearRegistry(){i.clear()}}}function sv(e,t=0){let n=3735928559^t,r=1103547991^t;for(let t=0,i;t<e.length;t++)i=e.charCodeAt(t),n=Math.imul(n^i,2654435761),r=Math.imul(r^i,1597334677);return n=Math.imul(n^n>>>16,2246822507),n^=Math.imul(r^r>>>13,3266489909),r=Math.imul(r^r>>>16,2246822507),r^=Math.imul(n^n>>>13,3266489909),(4294967296*(2097151&r)+(n>>>0)).toString(36).slice(0,6)}function cv(e=!1,t=!1){let n={lineInfo:[]},r=[{line(e){return delete e.properties.class,e},pre(t){let r=Vi(t),i=[];if(r!=null){let t=1;for(let a of r.children)a.type===`element`&&(e&&nv(a),i.push($_(a,t,n)),t++);r.children=i}return t},...e?{tokens(e){for(let t of e){let e=0;for(let n of t){let t=n;t.__lineChar??=e,e+=n.content.length}}},preprocess(e,t){t.mergeWhitespaces=`never`},span(e,t,n,r,i){if(i?.offset!=null&&i.content!=null){let t=i.__lineChar;return t!=null&&(e.properties[`data-char`]=t),e}return e}}:null}];return t&&r.push(uv,lv),{state:n,transformers:r,toClass:lv}}var lv=ov({classPrefix:`hl-`}),uv={name:`token-style-normalizer`,tokens(e){for(let t of e)for(let e of t){if(e.htmlStyle!=null)continue;let t={};e.color!=null&&(t.color=e.color),e.bgColor!=null&&(t[`background-color`]=e.bgColor),e.fontStyle!=null&&e.fontStyle!==0&&(e.fontStyle&1&&(t[`font-style`]=`italic`),e.fontStyle&2&&(t[`font-weight`]=`bold`),e.fontStyle&4&&(t[`text-decoration`]=`underline`)),Object.keys(t).length>0&&(e.htmlStyle=t)}}};function dv(e){return`--${e===`token`?`diffs-token`:`diffs`}-`}var fv=/^#(?:[0-9a-f]{3}0|[0-9a-f]{6}00)$/i,pv=/^0(?:\.0+)?%?$/;function mv(e){let t=e.indexOf(`(`);if(t<=0||!e.endsWith(`)`))return;let n=e.slice(0,t).trim();if(!/^(?:rgb|rgba|hsl|hsla|hwb|lab|lch|oklab|oklch|color)$/i.test(n))return;let r=e.slice(t+1,-1).trim();if(r.length===0)return;let i=r.lastIndexOf(`/`);if(i!==-1)return r.slice(i+1).trim();if(/^(?:rgba|hsla)$/i.test(n)){let e=r.split(`,`);if(e.length===4)return e[3]?.trim()}}function hv(e){let t=/^#([0-9a-f]{3}|[0-9a-f]{6}|[0-9a-f]{8})\b/i.exec(e.trim());if(t==null)return null;let n=t[1],r,i=1;return n.length===3?r=n.split(``).map(e=>e+e).join(``):n.length===6?r=n:(r=n.slice(0,6),i=parseInt(n.slice(6,8),16)/255),[parseInt(r.slice(0,2),16),parseInt(r.slice(2,4),16),parseInt(r.slice(4,6),16),i]}function gv(e){if(e==null)return null;let t=hv(e);if(t==null)return null;let n=t[0]/255,r=t[1]/255,i=t[2]/255,a=e=>e<=.03928?e/12.92:((e+.055)/1.055)**2.4;return .2126*a(n)+.7152*a(r)+.0722*a(i)}function _v(e){if(e==null)return!1;let t=e.trim().toLowerCase();if(t===`transparent`||fv.test(t))return!0;let n=mv(t);return n!=null&&pv.test(n)}function vv(e,t,n){if(t==null||n==null)return!1;let r=gv(e),i=gv(t),a=gv(n);return r==null||i==null||a==null?!1:Math.abs(r-a)<Math.abs(r-i)}var yv=new WeakMap;function bv(e){let t=yv.get(e);if(t!=null)return t;let n=e.colors??{},r={...n},i=n[`editor.background`]??e.bg,a=n[`editor.foreground`]??e.fg,o=n[`sideBar.background`]??i,s=n[`sideBar.foreground`]??a;xv(r,`editor.background`,i),xv(r,`editor.foreground`,a),xv(r,`sideBar.background`,o),xv(r,`sideBar.foreground`,s),xv(r,`input.background`,n[`input.background`]??o),xv(r,`sideBarSectionHeader.foreground`,n[`sideBarSectionHeader.foreground`]??s),xv(r,`list.activeSelectionForeground`,n[`list.activeSelectionForeground`]??s),xv(r,`gitDecoration.addedResourceForeground`,Sv(n[`gitDecoration.addedResourceForeground`],n[`terminal.ansiGreen`],n[`editorGutter.addedBackground`])),xv(r,`gitDecoration.modifiedResourceForeground`,Sv(n[`gitDecoration.modifiedResourceForeground`],n[`terminal.ansiBlue`],n[`editorGutter.modifiedBackground`])),xv(r,`gitDecoration.deletedResourceForeground`,Sv(n[`gitDecoration.deletedResourceForeground`],n[`terminal.ansiRed`],n[`editorGutter.deletedBackground`]));let c=(_v(n[`list.focusOutline`])?void 0:n[`list.focusOutline`])??(_v(n.focusBorder)?void 0:n.focusBorder);c==null?delete r[`list.focusOutline`]:r[`list.focusOutline`]=c;let l=n[`list.hoverBackground`];l!=null&&(Cv(l,o)||vv(l,o,s))&&delete r[`list.hoverBackground`];let u=Object.freeze({...e,colors:Object.freeze(r)});return yv.set(e,u),u}function xv(e,t,n){n!=null&&n!==``&&(e[t]=n)}function Sv(...e){for(let t of e)if(t!=null&&t!==``)return t}function Cv(e,t){return t!=null&&e.toLowerCase()===t.toLowerCase()}function wv({theme:e=Gr,highlighter:t,prefix:n}){let r=``;if(typeof e==`string`){let i=t.getTheme(e),a=bv(i);r+=`color:${a.fg};`,r+=`background-color:${a.bg};`,r+=`${dv(`global`)}fg:${a.fg};`,r+=`${dv(`global`)}bg:${a.bg};`,r+=Tv(i,n)}else{let n=t.getTheme(e.dark),i=bv(n);r+=`${dv(`global`)}dark:${i.fg};`,r+=`${dv(`global`)}dark-bg:${i.bg};`,r+=Tv(n,`dark`),n=t.getTheme(e.light),i=bv(n),r+=`${dv(`global`)}light:${i.fg};`,r+=`${dv(`global`)}light-bg:${i.bg};`,r+=Tv(n,`light`)}return r}function Tv(e,t){t=t==null?``:`${t}-`;let n=``,r=e.colors?.[`gitDecoration.addedResourceForeground`]??e.colors?.[`terminal.ansiGreen`];r!=null&&(n+=`${dv(`global`)}${t}addition-color:${r};`);let i=e.colors?.[`gitDecoration.deletedResourceForeground`]??e.colors?.[`terminal.ansiRed`];i!=null&&(n+=`${dv(`global`)}${t}deletion-color:${i};`);let a=e.colors?.[`gitDecoration.modifiedResourceForeground`]??e.colors?.[`terminal.ansiBlue`];return a!=null&&(n+=`${dv(`global`)}${t}modified-color:${a};`),n}function Ev(e){let t=e.children[0];for(;t!=null;){if(t.type===`element`&&t.tagName===`code`)return t.children;t=`children`in t?t.children[0]:null}throw console.error(e),Error(`getLineNodes: Unable to find children`)}function Dv({line:e,spanStart:t,spanLength:n}){return{start:{line:e,character:t},end:{line:e,character:t+n},properties:{"data-diff-span":``},alwaysWrap:!0}}function Ov({item:e,arr:t,enableJoin:n,isNeutral:r=!1,isLastItem:i=!1}){let a=t[t.length-1];if(a==null||i||!n){t.push([+!r,e.value]);return}let o=a[0]===0;if(r===o||r&&e.value.length===1&&!o){a[1]+=e.value;return}t.push([+!r,e.value])}var kv={forcePlainText:!1};function Av(e,t,n,{forcePlainText:r,startingLine:i,totalLines:a,expandedHunks:o,collapsedContextThreshold:s=1}=kv){r?(i??=0,a??=1/0):(i=0,a=1/0);let c=i>0||a<1/0,l=typeof n.theme==`string`?t.getTheme(n.theme).type:void 0,u=wv({theme:n.theme,highlighter:t}),d=r&&!c&&(e.unifiedLineCount>1e3||e.splitLineCount>1e3)?`none`:n.lineDiffType,f={deletionLines:[],additionLines:[]},{maxLineDiffLength:p}=n,m=!r&&!e.isPartial,h=r?o:void 0,g=new Map;function _(e){let t=m?0:e,n=g.get(t)??Mv();return g.set(t,n),n}function v(e,t,n,r){if(c){let e=n.at(-1);(e==null||e.targetIndex+e.count!==t)&&(e={targetIndex:t,originalOffset:r.length,count:0},n.push(e)),e.count++}r.push(e)}R_({diff:e,diffStyle:`both`,startingLine:i,totalLines:a,expandedHunks:c?h:!0,collapsedContextThreshold:s,callback:({hunkIndex:t,additionLine:n,deletionLine:r,type:i})=>{let a=_(t),o=n==null?r.splitLineIndex:n.splitLineIndex;i===`change`&&n!=null&&r!=null&&jv({additionLine:e.additionLines[n.lineIndex],deletionLine:e.deletionLines[r.lineIndex],deletionLineIndex:a.deletionContent.length,additionLineIndex:a.additionContent.length,deletionDecorations:a.deletionDecorations,additionDecorations:a.additionDecorations,lineDiffType:d,maxLineDiffLength:p}),r!=null&&(v(e.deletionLines[r.lineIndex],r.lineIndex,a.deletionSegments,a.deletionContent),a.deletionInfo.push({type:i===`change`?`change-deletion`:i,lineNumber:r.lineNumber,altLineNumber:i===`change`?void 0:n.lineNumber??void 0,lineIndex:`${r.unifiedLineIndex},${o}`})),n!=null&&(v(e.additionLines[n.lineIndex],n.lineIndex,a.additionSegments,a.additionContent),a.additionInfo.push({type:i===`change`?`change-addition`:i,lineNumber:n.lineNumber,altLineNumber:i===`change`?void 0:r.lineNumber??void 0,lineIndex:`${n.unifiedLineIndex},${o}`}))}});for(let i of g.values()){if(i.deletionContent.length===0&&i.additionContent.length===0)continue;let a={name:e.prevName??e.name,contents:i.deletionContent.value},o={name:e.name,contents:i.additionContent.value},{deletionLines:s,additionLines:c}=Nv({deletionFile:a,deletionInfo:i.deletionInfo,deletionDecorations:i.deletionDecorations,additionFile:o,additionInfo:i.additionInfo,additionDecorations:i.additionDecorations,highlighter:t,options:n,languageOverride:r?`text`:e.lang});if(m){f.deletionLines=s,f.additionLines=c;continue}if(i.deletionSegments.length>0)for(let e of i.deletionSegments)for(let t=0;t<e.count;t++)f.deletionLines[e.targetIndex+t]=s[e.originalOffset+t];else f.deletionLines.push(...s);if(i.additionSegments.length>0)for(let e of i.additionSegments)for(let t=0;t<e.count;t++)f.additionLines[e.targetIndex+t]=c[e.originalOffset+t];else f.additionLines.push(...c)}return{code:f,themeStyles:u,baseThemeType:l}}function jv({deletionLine:e,additionLine:t,deletionLineIndex:n,additionLineIndex:r,deletionDecorations:i,additionDecorations:a,lineDiffType:o,maxLineDiffLength:s}){if(e==null||t==null||o===`none`||(e=ei(e),t=ei(t),e.length>s||t.length>s))return;let c=o===`char`?Ys(e,t):fc(e,t),l=[],u=[],d=o===`word-alt`,f=c.at(-1);for(let e of c){let t=e===f;!e.added&&!e.removed?(Ov({item:e,arr:l,enableJoin:d,isNeutral:!0,isLastItem:t}),Ov({item:e,arr:u,enableJoin:d,isNeutral:!0,isLastItem:t})):e.removed?Ov({item:e,arr:l,enableJoin:d,isLastItem:t}):Ov({item:e,arr:u,enableJoin:d,isLastItem:t})}let p=0;for(let e of l)e[0]===1&&i.push(Dv({line:n,spanStart:p,spanLength:e[1].length})),p+=e[1].length;p=0;for(let e of u)e[0]===1&&a.push(Dv({line:r,spanStart:p,spanLength:e[1].length})),p+=e[1].length}function Mv(){return{deletionContent:{push(e){this.value+=e,this.length++},value:``,length:0},additionContent:{push(e){this.value+=e,this.length++},value:``,length:0},deletionInfo:[],additionInfo:[],deletionDecorations:[],additionDecorations:[],deletionSegments:[],additionSegments:[]}}function Nv({deletionFile:e,additionFile:t,deletionInfo:n,additionInfo:r,highlighter:i,deletionDecorations:a,additionDecorations:o,languageOverride:s,options:{theme:c=Gr,...l}}){let u=s??kc(e.name),d=s??kc(t.name),{state:f,transformers:p}=cv(l.useTokenTransformer),m=typeof c==`string`?{...l,lang:`text`,theme:c,transformers:p,decorations:void 0,defaultColor:!1,cssVariablePrefix:dv(`token`),tokenizeTimeLimit:0}:{...l,lang:`text`,themes:c,transformers:p,decorations:void 0,defaultColor:!1,cssVariablePrefix:dv(`token`),tokenizeTimeLimit:0};return{deletionLines:e.contents===``?[]:(m.lang=u,f.lineInfo=n,m.decorations=a,Ev(i.codeToHast(ei(e.contents),m))),additionLines:t.contents===``?[]:(m.lang=d,m.decorations=o,f.lineInfo=r,Ev(i.codeToHast(ei(t.contents),m)))}}var Pv=-1,Fv=class{options;onRenderUpdate;workerManager;__id=`diff-hunks-renderer:${++Pv}`;highlighter;diff;expandedHunks=new Map;deletionAnnotations={};additionAnnotations={};computedLang=`text`;renderCache;constructor(e={theme:Gr},t,n){this.options=e,this.onRenderUpdate=t,this.workerManager=n,n?.isWorkingPool()!==!0&&(this.highlighter=C_(e.theme??Gr)?b_():void 0)}cleanUp(){this.recycle(),this.expandedHunks.clear(),this.workerManager=void 0,this.onRenderUpdate=void 0}recycle(){this.highlighter=void 0,this.diff=void 0,this.clearRenderCache(),this.additionAnnotations={},this.deletionAnnotations={},this.workerManager?.cleanUpTasks(this)}clearRenderCache(){this.renderCache=void 0}setOptions(e){this.options=e}mergeOptions(e){this.options={...this.options,...e}}expandHunk(e,t,n=this.getOptionsWithDefaults().expansionLineCount){let r={...this.expandedHunks.get(e)??{fromStart:0,fromEnd:0}};(t===`up`||t===`both`)&&(r.fromStart+=n),(t===`down`||t===`both`)&&(r.fromEnd+=n),this.renderCache?.highlighted!==!0&&this.clearRenderCache(),this.expandedHunks.set(e,r)}getExpandedHunk(e){return this.expandedHunks.get(e)??Zr}getExpandedHunksMap(){return this.expandedHunks}setLineAnnotations(e){this.additionAnnotations={},this.deletionAnnotations={};for(let t of e){let e=(()=>{switch(t.side){case`deletions`:return this.deletionAnnotations;case`additions`:return this.additionAnnotations}})(),n=e[t.lineNumber]??[];e[t.lineNumber]=n,n.push(t)}}getUnifiedLineDecoration({lineType:e}){return{gutterLineType:e}}getSplitLineDecoration({side:e,type:t}){return t===`change`?{gutterLineType:e===`deletions`?`change-deletion`:`change-addition`}:{gutterLineType:t}}createAnnotationElement=e=>w_(e);getOptionsWithDefaults(){let{diffIndicators:e=`bars`,diffStyle:t=`split`,disableBackground:n=!1,disableFileHeader:r=!1,disableLineNumbers:i=!1,disableVirtualizationBuffers:a=!1,collapsed:o=!1,expandUnchanged:s=!1,collapsedContextThreshold:c=1,expansionLineCount:l=100,hunkSeparators:u=`line-info`,lineDiffType:d=`word-alt`,maxLineDiffLength:f=1e3,overflow:p=`scroll`,stickyHeader:m=!1,theme:h=Gr,headerRenderMode:g=`default`,tokenizeMaxLineLength:_=1e3,tokenizeMaxLength:v=Xr,useTokenTransformer:y=!1,useCSSClasses:b=!1}=this.options;return{diffIndicators:e,diffStyle:t,disableBackground:n,disableFileHeader:r,disableLineNumbers:i,disableVirtualizationBuffers:a,collapsed:o,expandUnchanged:s,collapsedContextThreshold:c,expansionLineCount:l,hunkSeparators:u,lineDiffType:d,maxLineDiffLength:f,overflow:p,stickyHeader:m,theme:this.workerManager?.getDiffRenderOptions().theme??h,headerRenderMode:g,tokenizeMaxLineLength:_,tokenizeMaxLength:v,useTokenTransformer:y,useCSSClasses:b}}async initializeHighlighter(){return this.highlighter=await y_(M_(this.computedLang,this.options)),this.highlighter}hydrate(e){if(e==null)return;this.diff=e;let{options:t}=this.getRenderOptions(e),n=Wv(e,this.getTokenizeMaxLength()),r=this.workerManager?.getDiffResultCache(e);r!=null&&!G_(t,r.options)&&(r=void 0),this.renderCache??={diff:e,highlighted:!n&&!Ac(e),options:t,result:n?void 0:r?.result,renderRange:void 0},this.workerManager?.isWorkingPool()===!0?this.renderCache.result==null&&!n&&this.workerManager.highlightDiffAST(this,this.diff):this.highlighter??(this.computedLang=e.lang??kc(e.name),this.initializeHighlighter())}getRenderOptions(e){let t=(()=>{if(this.workerManager?.isWorkingPool()===!0)return this.workerManager.getDiffRenderOptions();let{theme:e,tokenizeMaxLineLength:t,lineDiffType:n,maxLineDiffLength:r}=this.getOptionsWithDefaults();return{theme:e,useTokenTransformer:N_(this.options),tokenizeMaxLineLength:t,lineDiffType:n,maxLineDiffLength:r}})();this.getOptionsWithDefaults();let{renderCache:n}=this;return n?.result==null||!P_(e,n.diff)||!G_(t,n.options)?{options:t,forceHighlight:!0}:{options:t,forceHighlight:!1}}renderDiff(e=this.renderCache?.diff,t=Qr){if(e==null)return;let{expandUnchanged:n=!1,collapsedContextThreshold:r}=this.getOptionsWithDefaults(),{options:i,forceHighlight:a}=this.getRenderOptions(e),o=this.getMatchingWorkerResultCache(e,i);o!=null&&!this.hasHighlightedRenderCache(e,i)&&(this.renderCache={diff:e,highlighted:!0,renderRange:void 0,...o},a=!1),this.renderCache??={diff:e,highlighted:!1,options:i,result:void 0,renderRange:void 0};let s=e.additionLines.length>0||e.deletionLines.length>0,c=!s||Ac(e)||Wv(e,this.getTokenizeMaxLength()),l=!P_(e,this.renderCache.diff),u=!Cs(this.renderCache.renderRange,t);if(this.workerManager?.isWorkingPool()===!0)(c||this.renderCache.result==null||!this.renderCache.highlighted&&(l||u))&&(this.renderCache.diff=e,this.renderCache.options=i,this.renderCache.highlighted=!1,(this.renderCache.result==null||l||u||a)&&(this.renderCache.result=this.workerManager.getPlainDiffAST(e,t.startingLine,t.totalLines,Q_(t)||n?!0:this.expandedHunks,r)),this.renderCache.renderRange=t),!c&&s&&(!this.renderCache.highlighted||a)&&this.workerManager.highlightDiffAST(this,e);else{this.computedLang=e.lang??kc(e.name);let t=this.highlighter!=null&&C_(i.theme),n=this.highlighter!=null&&Lc(this.computedLang),r=!c&&n;if(this.highlighter!=null&&t&&(a||c||!this.renderCache.highlighted&&r||this.renderCache.result==null)){let{result:t,options:i}=this.renderDiffWithHighlighter(e,this.highlighter,c||!n);this.renderCache={diff:e,options:i,highlighted:r,result:t,renderRange:void 0}}(!t||!c&&!n)&&this.asyncHighlight(e).then(({result:t,options:n})=>{this.renderCache!=null&&(this.renderCache.highlighted=!1),this.onHighlightSuccess(e,t,n,!c)})}return this.renderCache.result==null?void 0:this.processDiffResult(this.renderCache.diff,t,this.renderCache.result)}async asyncRender(e,t=Qr){let{result:n}=await this.asyncHighlight(e);return this.processDiffResult(e,t,n)}createPreElement(e,t,n){let{diffIndicators:r,disableBackground:i,disableLineNumbers:a,overflow:o}=this.getOptionsWithDefaults();return A_({type:`diff`,diffIndicators:r,disableBackground:i,disableLineNumbers:a,overflow:o,split:e,totalLines:t,customProperties:n})}async asyncHighlight(e){let t=Wv(e,this.getTokenizeMaxLength());this.computedLang=t?`text`:e.lang??kc(e.name);let n=this.highlighter!=null&&C_(this.options.theme??Gr),r=t||this.highlighter!=null&&Lc(this.computedLang);return(this.highlighter==null||!n||!r)&&(this.highlighter=await this.initializeHighlighter()),this.renderDiffWithHighlighter(e,this.highlighter,t)}renderDiffWithHighlighter(e,t,n=!1){let{options:r}=this.getRenderOptions(e),{collapsedContextThreshold:i}=this.getOptionsWithDefaults();return{result:Av(e,t,r,{forcePlainText:n,expandedHunks:n?!0:void 0,collapsedContextThreshold:i}),options:r}}onHighlightSuccess(e,t,n,r=!0){if(this.renderCache==null)return;let i=!this.renderCache.highlighted||!G_(this.renderCache.options,n)||!P_(this.renderCache.diff,e);this.renderCache={diff:e,options:n,highlighted:r,result:t,renderRange:void 0},i&&this.onRenderUpdate?.()}getMatchingWorkerResultCache(e,t){let n=this.workerManager?.getDiffResultCache(e);if(!(n==null||!G_(t,n.options)))return n}hasHighlightedRenderCache(e,t){let{renderCache:n}=this;return n?.result!=null&&n.highlighted&&P_(e,n.diff)&&G_(t,n.options)}onHighlightError(e){console.error(e)}getTokenizeMaxLength(){return this.options.tokenizeMaxLength??1e5}processDiffResult(e,t,{code:n,themeStyles:r,baseThemeType:i}){let{diffStyle:a,disableFileHeader:o,expandUnchanged:s,expansionLineCount:c,collapsedContextThreshold:l,hunkSeparators:u}=this.getOptionsWithDefaults();this.diff=e;let d=a===`unified`,f=[],p=[],m=[],h=[],{additionLines:g,deletionLines:_}=n,v={rowCount:0,hunkSeparators:u,additionsContentAST:f,deletionsContentAST:p,unifiedContentAST:m,unifiedGutterAST:Hi(),deletionsGutterAST:Hi(),additionsGutterAST:Hi(),expansionLineCount:c,hunkData:h,incrementRowCount(e=1){v.rowCount+=e},pushToGutter(e,t){switch(e){case`unified`:v.unifiedGutterAST.children.push(t);break;case`deletions`:v.deletionsGutterAST.children.push(t);break;case`additions`:v.additionsGutterAST.children.push(t);break}}},y=I_({fileDiff:e,errorPrefix:`DiffHunksRenderer.processDiffResult`}),b={size:0,side:void 0,increment(){this.size+=1},flush(){if(a!==`unified`){if(this.size<=0||this.side==null){this.side=void 0,this.size=0;return}this.side===`additions`?(v.pushToGutter(`additions`,Wi(void 0,`buffer`,this.size)),f?.push(K_(this.size))):(v.pushToGutter(`deletions`,Wi(void 0,`buffer`,this.size)),p?.push(K_(this.size))),this.size=0,this.side=void 0}}},x=(e,t,n,r,i)=>{v.pushToGutter(e,Ui(t,n,r,i))};function S(e){b.flush(),a===`unified`?Hv(`unified`,e,v):(Hv(`deletions`,e,v),Hv(`additions`,e,v))}this.pushFileLevelAnnotations(e,a,t,v),R_({diff:e,diffStyle:a,startingLine:t.startingLine,totalLines:t.totalLines,expandedHunks:s?!0:this.expandedHunks,collapsedContextThreshold:l,callback:({hunkIndex:t,hunk:n,collapsedBefore:r,collapsedAfter:i,additionLine:o,deletionLine:s,type:c})=>{let l=s==null?o.splitLineIndex:s.splitLineIndex,d=o==null?s.unifiedLineIndex:o.unifiedLineIndex;a===`split`&&c!==`change`&&b.flush(),r>0&&S({hunkIndex:t,collapsedLines:r,rangeSize:Math.max(n?.collapsedBefore??0,0),hunkSpecs:n?.hunkSpecs,isFirstHunk:t===0,isLastHunk:!1,isExpandable:!e.isPartial});let f=a===`unified`?d:l,p={type:c,hunkIndex:t,lineIndex:f,unifiedLineIndex:d,splitLineIndex:l,deletionLine:s,additionLine:o};if(a===`unified`){let n=this.getUnifiedInjectedRowsForLine?.(p);n?.before!=null&&zv(n.before,v);let r=s==null?void 0:_[s.lineIndex],i=o==null?void 0:g[o.lineIndex];if(r==null&&i==null){let t=`DiffHunksRenderer.processDiffResult: deletionLine and additionLine are null, something is wrong`;throw console.error(t,{file:e.name}),Error(t)}let a=c===`change`?o==null?`change-deletion`:`change-addition`:c,u=this.getUnifiedLineDecoration({type:c,lineType:a,additionLineIndex:o?.lineIndex,deletionLineIndex:s?.lineIndex});x(`unified`,u.gutterLineType,o==null?s.lineNumber:o.lineNumber,`${d},${l}`,u.gutterProperties),i==null?r!=null&&(r=Uv(r,u.contentProperties)):i=Uv(i,u.contentProperties),Vv({diffStyle:`unified`,type:c,deletionLine:r,additionLine:i,unifiedSpan:this.getAnnotations(`unified`,s?.lineNumber,o?.lineNumber,t,f),createAnnotationElement:e=>this.createAnnotationElement(e),context:v}),n?.after!=null&&zv(n.after,v)}else{let n=this.getSplitInjectedRowsForLine?.(p);n?.before!=null&&Bv(n.before,v,b);let r=s==null?void 0:_[s.lineIndex],i=o==null?void 0:g[o.lineIndex],a=this.getSplitLineDecoration({side:`deletions`,type:c,lineIndex:s?.lineIndex}),u=this.getSplitLineDecoration({side:`additions`,type:c,lineIndex:o?.lineIndex});if(r==null&&i==null){let t=`DiffHunksRenderer.processDiffResult: deletionLine and additionLine are null, something is wrong`;throw console.error(t,{file:e.name}),Error(t)}let d=(()=>{if(c===`change`){if(i==null)return`additions`;if(r==null)return`deletions`}})();if(d!=null){if(b.side!=null&&b.side!==d)throw Error(`DiffHunksRenderer.processDiffResult: iterateOverDiff, invalid pending splits`);b.side=d,b.increment()}let m=this.getAnnotations(`split`,s?.lineNumber,o?.lineNumber,t,f);if(m!=null&&b.size>0&&b.flush(),s!=null){let e=Uv(r,a.contentProperties);x(`deletions`,a.gutterLineType,s.lineNumber,`${s.unifiedLineIndex},${l}`,a.gutterProperties),e!=null&&(r=e)}if(o!=null){let e=Uv(i,u.contentProperties);x(`additions`,u.gutterLineType,o.lineNumber,`${o.unifiedLineIndex},${l}`,u.gutterProperties),e!=null&&(i=e)}Vv({diffStyle:`split`,type:c,additionLine:i,deletionLine:r,...m,createAnnotationElement:e=>this.createAnnotationElement(e),context:v}),n?.after!=null&&Bv(n.after,v,b)}let m=a===`split`&&n!=null&&l===n.splitLineStart+n.splitLineCount-1,h=m?n.noEOFCRDeletions:!1,C=m?n.noEOFCRAdditions:!1,w=(s?.noEOFCR??!1)||h,T=(o?.noEOFCR??!1)||C;if(T||w){if(a===`split`&&b.flush(),w){let e=c===`context`||c===`context-expanded`?c:`change-deletion`;a===`unified`?(v.unifiedContentAST.push(q_(e)),v.pushToGutter(`unified`,Wi(e,`metadata`,1))):(v.deletionsContentAST.push(q_(e)),v.pushToGutter(`deletions`,Wi(e,`metadata`,1)),T||(v.pushToGutter(`additions`,Wi(void 0,`buffer`,1)),v.additionsContentAST.push(K_(1))))}if(T){let e=c===`context`||c===`context-expanded`?c:`change-addition`;a===`unified`?(v.unifiedContentAST.push(q_(e)),v.pushToGutter(`unified`,Wi(e,`metadata`,1))):(v.additionsContentAST.push(q_(e)),v.pushToGutter(`additions`,Wi(e,`metadata`,1)),w||(v.pushToGutter(`deletions`,Wi(void 0,`buffer`,1)),v.deletionsContentAST.push(K_(1))))}v.incrementRowCount(1)}i>0&&u!==`simple`&&S({hunkIndex:c===`context-expanded`?t:t+1,collapsedLines:i,rangeSize:y,hunkSpecs:void 0,isFirstHunk:!1,isLastHunk:!0,isExpandable:!e.isPartial}),v.incrementRowCount(1)}}),a===`split`&&b.flush();let C=Math.max(Z_(e.hunks),e.additionLines.length??0,e.deletionLines.length??0),w=t.bufferBefore>0||t.bufferAfter>0,T=!d&&e.type!==`deleted`,E=!d&&e.type!==`new`,D=v.rowCount>0||w;f=T&&D?f:void 0,p=E&&D?p:void 0,m=d&&D?m:void 0;let O=this.createPreElement(p!=null&&f!=null,C);return{unifiedGutterAST:d&&D?v.unifiedGutterAST.children:void 0,unifiedContentAST:m,deletionsGutterAST:E&&D?v.deletionsGutterAST.children:void 0,deletionsContentAST:p,additionsGutterAST:T&&D?v.additionsGutterAST.children:void 0,additionsContentAST:f,hunkData:h,preNode:O,themeStyles:r,baseThemeType:i,headerElement:o?void 0:this.renderHeader(this.diff),totalLines:C,rowCount:v.rowCount,bufferBefore:t.bufferBefore,bufferAfter:t.bufferAfter,css:``}}renderCodeAST(e,t){let n=e===`unified`?t.unifiedGutterAST:e===`deletions`?t.deletionsGutterAST:t.additionsGutterAST,r=e===`unified`?t.unifiedContentAST:e===`deletions`?t.deletionsContentAST:t.additionsContentAST;if(n==null||r==null)return;let i=Hi(n);return i.properties.style=`grid-row: span ${t.rowCount}`,[i,T_(r,t.rowCount)]}renderFullAST(e,t=[]){let n=this.getOptionsWithDefaults().hunkSeparators===`line-info`,r=this.renderCodeAST(`unified`,e);if(r!=null)return t.push(zi({tagName:`code`,children:r,properties:{"data-code":``,"data-container-size":n?``:void 0,"data-unified":``}})),{...e.preNode,children:t};let i=this.renderCodeAST(`deletions`,e);i!=null&&t.push(zi({tagName:`code`,children:i,properties:{"data-code":``,"data-container-size":n?``:void 0,"data-deletions":``}}));let a=this.renderCodeAST(`additions`,e);return a!=null&&t.push(zi({tagName:`code`,children:a,properties:{"data-code":``,"data-container-size":n?``:void 0,"data-additions":``}})),{...e.preNode,children:t}}renderFullHTML(e,t=[]){return Yo(this.renderFullAST(e,t))}renderPartialHTML(e,t){return Yo(t==null?e:zi({tagName:`code`,children:e,properties:{"data-code":``,"data-container-size":this.getOptionsWithDefaults().hunkSeparators===`line-info`?``:void 0,[`data-${t}`]:``}}))}pushFileLevelAnnotations(e,t,n,r){if(!Mc(n))return;let i=e.type===`new`?[]:Iv(jc(this.deletionAnnotations)),a=e.type===`deleted`?[]:Iv(jc(this.additionAnnotations));if(i.length===0&&a.length===0)return;let{createAnnotationElement:o}=this;if(t===`unified`){Vv({diffStyle:t,type:`context`,unifiedSpan:{type:`annotation`,hunkIndex:-1,lineIndex:-1,annotations:i.concat(a)},createAnnotationElement:o,context:r});return}Vv({diffStyle:t,type:`context`,deletionSpan:{type:`annotation`,hunkIndex:-1,lineIndex:-1,annotations:i},additionSpan:{type:`annotation`,hunkIndex:-1,lineIndex:-1,annotations:a},createAnnotationElement:o,context:r})}getAnnotations(e,t,n,r,i){let a={type:`annotation`,hunkIndex:r,lineIndex:i,annotations:[]};if(t!=null)for(let e of this.deletionAnnotations[t]??[])a.annotations.push(ws(e));let o={type:`annotation`,hunkIndex:r,lineIndex:i,annotations:[]};if(n!=null)for(let t of this.additionAnnotations[n]??[])(e===`unified`?a:o).annotations.push(ws(t));if(e===`unified`)return a.annotations.length>0?a:void 0;if(!(o.annotations.length===0&&a.annotations.length===0))return{deletionSpan:a,additionSpan:o}}renderHeader(e){let{headerRenderMode:t,stickyHeader:n}=this.getOptionsWithDefaults();return D_({fileOrDiff:e,mode:t,stickyHeader:n})}};function Iv(e){return e?.map(e=>ws(e))??[]}var Lv=new Intl.PluralRules(`en-US`);function Rv(e){return`${e} unmodified line${Lv.select(e)===`one`?``:`s`}`}function zv(e,t){for(let n of e)t.unifiedContentAST.push(n.content),t.pushToGutter(`unified`,n.gutter),t.incrementRowCount(1)}function Bv(e,t,n){for(let{deletion:r,addition:i}of e){if(r==null&&i==null)continue;let e=r!=null&&i!=null?void 0:r==null?`deletions`:`additions`;(e==null||n.side!==e)&&n.flush(),r!=null&&(t.deletionsContentAST.push(r.content),t.pushToGutter(`deletions`,r.gutter)),i!=null&&(t.additionsContentAST.push(i.content),t.pushToGutter(`additions`,i.gutter)),e!=null&&(n.side=e,n.increment()),t.incrementRowCount(1)}}function Vv({diffStyle:e,type:t,deletionLine:n,additionLine:r,unifiedSpan:i,deletionSpan:a,additionSpan:o,createAnnotationElement:s,context:c}){let l=!1;if(e===`unified`){if(r==null?n!=null&&c.unifiedContentAST.push(n):c.unifiedContentAST.push(r),i!=null){let e=t===`change`?n==null?`change-addition`:`change-deletion`:t;c.unifiedContentAST.push(s(i)),c.pushToGutter(`unified`,Wi(e,`annotation`,1)),l=!0}}else if(e===`split`){if(n!=null&&c.deletionsContentAST.push(n),r!=null&&c.additionsContentAST.push(r),a!=null){let e=t===`change`?n==null?`context`:`change-deletion`:t;c.deletionsContentAST.push(s(a)),c.pushToGutter(`deletions`,Wi(e,`annotation`,1)),l=!0}if(o!=null){let e=t===`change`?r==null?`context`:`change-addition`:t;c.additionsContentAST.push(s(o)),c.pushToGutter(`additions`,Wi(e,`annotation`,1)),l=!0}}l&&c.incrementRowCount(1)}function Hv(e,{hunkIndex:t,collapsedLines:n,rangeSize:r,hunkSpecs:i,isFirstHunk:a,isLastHunk:o,isExpandable:s},c){if(n<=0)return;let l=e===`unified`?c.unifiedContentAST:e===`deletions`?c.deletionsContentAST:c.additionsContentAST;if(c.hunkSeparators===`metadata`){i!=null&&(c.pushToGutter(e,Y_({type:`metadata`,content:i,isFirstHunk:a,isLastHunk:o})),l.push(Y_({type:`metadata`,content:i,isFirstHunk:a,isLastHunk:o})),e!==`additions`&&c.incrementRowCount(1));return}if(c.hunkSeparators===`simple`){t>0&&(c.pushToGutter(e,Y_({type:`simple`,isFirstHunk:a,isLastHunk:!1})),l.push(Y_({type:`simple`,isFirstHunk:a,isLastHunk:!1})),e!==`additions`&&c.incrementRowCount(1));return}let u=X_(e,t),d=r>c.expansionLineCount,f=s?t:void 0;c.pushToGutter(e,Y_({type:c.hunkSeparators,content:Rv(n),expandIndex:f,chunked:d,slotName:u,isFirstHunk:a,isLastHunk:o})),l.push(Y_({type:c.hunkSeparators,content:Rv(n),expandIndex:f,chunked:d,slotName:u,isFirstHunk:a,isLastHunk:o})),e!==`additions`&&c.incrementRowCount(1),c.hunkData.push({slotName:u,hunkIndex:t,lines:n,type:e,expandable:s?{up:!a,down:!o,chunked:d}:void 0})}function Uv(e,t){return e==null||e.type!==`element`||t==null?e:{...e,properties:{...e.properties,...t}}}function Wv(e,t){return Math.max(e.additionLines.length,e.deletionLines.length)>t}function Gv(e,t){return e.lineNumber===t.lineNumber&&e.side===t.side&&e.metadata===t.metadata}function Kv(e,t){return e.slotName===t.slotName&&e.hunkIndex===t.hunkIndex&&e.lines===t.lines&&e.type===t.type&&e.expandable?.chunked===t.expandable?.chunked&&e.expandable?.up===t.expandable?.up&&e.expandable?.down===t.expandable?.down}function qv(e){return{theme:e?.theme,disableLineNumbers:e?.disableLineNumbers,overflow:e?.overflow,collapsed:e?.collapsed,disableFileHeader:e?.disableFileHeader,disableVirtualizationBuffers:e?.disableVirtualizationBuffers,stickyHeader:e?.stickyHeader,preferredHighlighter:e?.preferredHighlighter,useCSSClasses:e?.useCSSClasses,useTokenTransformer:e?.useTokenTransformer,tokenizeMaxLineLength:e?.tokenizeMaxLineLength,tokenizeMaxLength:e?.tokenizeMaxLength,diffStyle:e?.diffStyle,diffIndicators:e?.diffIndicators,disableBackground:e?.disableBackground,hunkSeparators:typeof e?.hunkSeparators==`function`?`custom`:e?.hunkSeparators,expandUnchanged:e?.expandUnchanged,collapsedContextThreshold:e?.collapsedContextThreshold,lineDiffType:e?.lineDiffType,maxLineDiffLength:e?.maxLineDiffLength,expansionLineCount:e?.expansionLineCount,headerRenderMode:e?.renderCustomHeader==null?`default`:`custom`}}var Jv=-1,Yv=class{options;workerManager;isContainerManaged;static LoadedCustomComponent=!0;__id=`file-diff:${++Jv}`;type=`file-diff`;fileContainer;spriteSVG;pre;codeUnified;codeDeletions;codeAdditions;bufferBefore;bufferAfter;themeCSSStyle;appliedThemeCSS;hasAdoptedThemeCSS=!1;unsafeCSSStyle;appliedUnsafeCSS;gutterUtilityContent;headerElement;headerPrefix;headerMetadata;headerCustom;separatorCache=new Map;errorWrapper;placeHolder;hunksRenderer;resizeManager;scrollSyncManager;interactionManager;annotationCache=new Map;lineAnnotations=[];managersDirty=!1;deletionFile;additionFile;fileDiff;renderRange;appliedPreAttributes;lastRenderedHeaderHTML;cachedHeaderHTML;lastRowCount;mounted=!1;enabled=!0;constructor(e={theme:Gr},t,n=!1){this.options=e,this.workerManager=t,this.isContainerManaged=n,this.hunksRenderer=this.createHunksRenderer(e),this.resizeManager=new _s,this.scrollSyncManager=new Ec,this.interactionManager=new Qo(`diff`,$o(e,typeof e.hunkSeparators==`function`||(e.hunkSeparators??`line-info`)===`line-info`||e.hunkSeparators===`line-info-basic`?this.handleExpandHunk:void 0,this.getLineIndex)),this.workerManager?.subscribeToThemeChanges(this),this.enabled=!0}handleHighlightRender=()=>{this.rerender()};getHunksRendererOptions(e){return qv(e)}createHunksRenderer(e){return new Fv(this.getHunksRendererOptions(e),this.handleHighlightRender,this.workerManager)}getLineIndex=(e,t=`additions`)=>{if(this.fileDiff==null)return;let n=this.fileDiff.hunks.at(-1),r,i;hunkIterator:for(let a of this.fileDiff.hunks){let o=t===`deletions`?a.deletionStart:a.additionStart,s=t===`deletions`?a.deletionCount:a.additionCount,c=a.splitLineStart,l=a.unifiedLineStart;if(e<o){let t=o-e;r=Math.max(l-t,0),i=Math.max(c-t,0);break hunkIterator}if(e>=o+s){if(a===n){let t=e-(o+s);r=l+a.unifiedLineCount+t,i=c+a.splitLineCount+t;break hunkIterator}continue}for(let n of a.hunkContent)if(n.type===`context`)if(e<o+n.lines){let t=e-o;i=c+t,r=l+t;break hunkIterator}else o+=n.lines,c+=n.lines,l+=n.lines;else{let a=t===`deletions`?n.deletions:n.additions;if(e<o+a){let a=e-o;r=l+(t===`additions`?n.deletions:0)+a,i=c+a;break hunkIterator}else o+=a,c+=Math.max(n.deletions,n.additions),l+=n.deletions+n.additions}break hunkIterator}if(!(r==null||i==null))return[r,i]};setOptions(e){e!=null&&(this.options=e,this.cachedHeaderHTML=void 0,this.hunksRenderer.setOptions(this.getHunksRendererOptions(e)),this.syncInteractionOptions())}syncInteractionOptions(){this.interactionManager.setOptions($o(this.options,typeof this.options.hunkSeparators==`function`||(this.options.hunkSeparators??`line-info`)===`line-info`||this.options.hunkSeparators===`line-info-basic`?this.handleExpandHunk:void 0,this.getLineIndex))}mergeOptions(e){this.options={...this.options,...e}}setThemeType(e){(this.options.themeType??`system`)!==e&&(this.mergeOptions({themeType:e}),this.applyCachedThemeState(e))}applyCachedThemeState(e){if(typeof this.options.theme==`string`||this.fileContainer==null||this.appliedThemeCSS==null)return!1;let t=this.appliedThemeCSS.baseThemeType??e;return this.appliedThemeCSS.themeType===t?!1:(this.applyThemeState(this.fileContainer,this.appliedThemeCSS.themeStyles,e,this.appliedThemeCSS.baseThemeType),!0)}hasThemeChanged(){return this.appliedThemeCSS!=null&&!Pi(this.appliedThemeCSS.theme,this.options.theme??Gr)}getHoveredLine=()=>this.interactionManager.getHoveredLine();setLineAnnotations(e){this.lineAnnotations=e}canPartiallyRender(e,t,n){return!(e||t||n||typeof this.options.hunkSeparators==`function`)}setSelectedLines(e,t){this.interactionManager.setSelection(e,t)}flushManagers(){if(!this.managersDirty||this.pre==null){this.managersDirty=!1;return}let{diffStyle:e=`split`,overflow:t=`scroll`}=this.options;this.interactionManager.setup(this.pre),this.resizeManager.setup(this.pre,t===`wrap`),t===`scroll`&&e===`split`?this.scrollSyncManager.setup(this.pre,this.codeDeletions,this.codeAdditions):this.scrollSyncManager.cleanUp(),this.managersDirty=!1}cleanUp(e=!1){this.emitPostRender(!0),this.resizeManager.cleanUp(),this.interactionManager.cleanUp(),this.scrollSyncManager.cleanUp(),this.managersDirty=!1,this.workerManager?.unsubscribeToThemeChanges(this),this.renderRange=void 0,this.isContainerManaged||this.fileContainer?.remove(),this.fileContainer=void 0,this.mounted=!1,e||(this.lineAnnotations=[]),this.clearAuxiliaryNodes(),this.annotationCache.clear(),this.pre=void 0,this.codeUnified=void 0,this.codeDeletions=void 0,this.codeAdditions=void 0,this.bufferBefore=void 0,this.bufferAfter=void 0,this.appliedPreAttributes=void 0,this.headerElement=void 0,this.headerPrefix=void 0,this.headerMetadata=void 0,this.headerCustom=void 0,this.placeHolder=void 0,this.lastRenderedHeaderHTML=void 0,e||(this.cachedHeaderHTML=void 0),this.errorWrapper=void 0,this.spriteSVG=void 0,this.lastRowCount=void 0,this.themeCSSStyle=void 0,this.appliedThemeCSS=void 0,this.hasAdoptedThemeCSS=!1,this.unsafeCSSStyle=void 0,this.appliedUnsafeCSS=void 0,e?this.hunksRenderer.recycle():(this.hunksRenderer.cleanUp(),this.workerManager=void 0,this.fileDiff=void 0,this.deletionFile=void 0,this.additionFile=void 0),this.enabled=!1}virtualizedSetup(){this.enabled=!0,this.workerManager?.subscribeToThemeChanges(this)}hydrate(e){let{fileContainer:t,prerenderedHTML:n,preventEmit:r=!1,lineAnnotations:i,oldFile:a,newFile:o,fileDiff:s}=e;this.hydrateElements(t,n),Qv(this.pre,Xv({fileDiff:s,oldFile:a,newFile:o}),this.options.collapsed)||$v(this.headerElement,Zv({fileDiff:s,oldFile:a,newFile:o}),this.options.disableFileHeader)?this.render({...e,preventEmit:!0}):this.hydrationSetup({fileDiff:s,oldFile:a,newFile:o,lineAnnotations:i}),r||this.emitPostRender()}hydrateElements(e,t){this.fileContainer!==e&&this.emitPostRender(!0),Gs(e,t);for(let t of e.shadowRoot?.children??[]){if(t instanceof SVGElement){this.spriteSVG=t;continue}if(t instanceof HTMLElement){if(t instanceof HTMLPreElement){this.pre=t;for(let e of t.children)!(e instanceof HTMLElement)||e.tagName.toLowerCase()!==`code`||(`deletions`in e.dataset&&(this.codeDeletions=e),`additions`in e.dataset&&(this.codeAdditions=e),`unified`in e.dataset&&(this.codeUnified=e));continue}if(`diffsHeader`in t.dataset){this.headerElement=t;continue}if(t instanceof HTMLStyleElement&&t.hasAttribute(`data-theme-css`)){this.themeCSSStyle=t;continue}if(t instanceof HTMLStyleElement&&t.hasAttribute(`data-unsafe-css`)){this.unsafeCSSStyle=t,this.appliedUnsafeCSS=t.textContent;continue}}}this.pre!=null&&(this.syncCodeNodesFromPre(this.pre),this.pre.removeAttribute(`data-dehydrated`)),this.fileContainer=e,this.hydrateMeasuredScrollbar()}hydrationSetup({fileDiff:e,oldFile:t,newFile:n,lineAnnotations:r}){this.lineAnnotations=r??this.lineAnnotations,this.additionFile=n,this.deletionFile=t,this.fileDiff=e??(t!=null&&n!=null?Tc(t,n,this.options.parseDiffOptions):void 0),this.pre!=null&&(this.syncInteractionOptions(),this.hunksRenderer.hydrate(this.fileDiff),this.renderAnnotations(),this.renderGutterUtility(),this.injectUnsafeCSS(),this.managersDirty=!0,this.flushManagers())}rerender(){!this.enabled||this.fileDiff==null&&this.additionFile==null&&this.deletionFile==null||this.render({forceRender:!0,renderRange:this.renderRange})}onThemeChange(){this.hunksRenderer.clearRenderCache(),this.rerender()}handleExpandHunk=(e,t,n)=>{this.expandHunk(e,t,n)};expandHunk=(e,t,n)=>{this.hunksRenderer.expandHunk(e,t,n),this.rerender()};render({oldFile:e,newFile:t,fileDiff:n,deferManagers:r=!1,forceRender:i=!1,preventEmit:a=!1,lineAnnotations:o,fileContainer:s,containerWrapper:c,renderRange:l}){if(!this.enabled)throw Error(`FileDiff.render: attempting to call render after cleaned up`);let{collapsed:u=!1,themeType:d=`system`}=this.options,f=u?void 0:l,p=this.hasThemeChanged(),m=e!=null&&t!=null&&(!Ss(e,this.deletionFile)||!Ss(t,this.additionFile)),h=n!=null&&n!==this.fileDiff,g=o!=null&&(o.length>0||this.lineAnnotations.length>0)?o!==this.lineAnnotations:!1;if(!u&&Cs(f,this.renderRange)&&!i&&!g&&!p&&(n!=null&&n===this.fileDiff||n==null&&!m))return this.applyCachedThemeState(d);let{renderRange:_}=this;if(this.renderRange=f,this.deletionFile=e,this.additionFile=t,n==null?e!=null&&t!=null&&m&&(h=!0,this.fileDiff=Tc(e,t,this.options.parseDiffOptions)):this.fileDiff=n,h&&(this.cachedHeaderHTML=void 0),o!=null&&this.setLineAnnotations(o),this.fileDiff==null)return!1;this.hunksRenderer.setOptions(this.getHunksRendererOptions(this.options)),this.syncInteractionOptions(),this.hunksRenderer.setLineAnnotations(this.lineAnnotations);let{disableErrorHandling:v=!1,disableFileHeader:y=!1}=this.options;if(y&&(this.headerElement!=null&&(this.headerElement.remove(),this.headerElement=void 0,this.lastRenderedHeaderHTML=void 0),this.clearHeaderSlots()),s=this.getOrCreateFileContainer(s,c),this.applyCachedThemeState(d),u){this.removeRenderedCode(),this.clearAuxiliaryNodes();try{let e=this.hunksRenderer.renderDiff(this.fileDiff,$r);e!=null&&this.applyThemeState(s,e.themeStyles,d,e.baseThemeType),e?.headerElement!=null&&this.applyHeaderToDOM(e.headerElement,s),this.renderSeparators([]),this.injectUnsafeCSS()}catch(e){if(v)throw e;console.error(e),e instanceof Error&&this.applyErrorToDOM(e,s)}return a||this.emitPostRender(),!0}try{let e=this.getOrCreatePreNode(s);if(!(this.canPartiallyRender(i,g,m||h||p)&&this.applyPartialRender({previousRenderRange:_,renderRange:f}))){let t=this.hunksRenderer.renderDiff(this.fileDiff,f);if(t==null)return this.workerManager?.isInitialized()===!1&&this.workerManager.initialize().then(()=>this.rerender()),!1;this.applyThemeState(s,t.themeStyles,d,t.baseThemeType),t.headerElement!=null&&this.applyHeaderToDOM(t.headerElement,s),t.additionsContentAST!=null||t.deletionsContentAST!=null||t.unifiedContentAST!=null?this.applyHunksToDOM(e,t):this.pre!=null&&(this.pre.remove(),this.pre=void 0),this.renderSeparators(t.hunkData)}this.applyBuffers(e,f),this.injectUnsafeCSS(),this.renderAnnotations(),this.renderGutterUtility(),this.managersDirty=!0,r||this.flushManagers()}catch(e){if(v)throw e;console.error(e),e instanceof Error&&this.applyErrorToDOM(e,s)}return a||this.emitPostRender(),!0}emitPostRender(e=!1){let{fileContainer:t,options:{onPostRender:n}}=this;if(e){if(!this.mounted||(this.mounted=!1,t==null))return;this.options.onPostRender?.(t,this,`unmount`);return}if(t==null)return;let r=this.mounted?`update`:`mount`;this.mounted=!0,n?.(t,this,r)}removeRenderedCode(){this.resizeManager.cleanUp(),this.scrollSyncManager.cleanUp(),this.interactionManager.cleanUp(),this.bufferBefore?.remove(),this.bufferBefore=void 0,this.bufferAfter?.remove(),this.bufferAfter=void 0,this.codeUnified?.remove(),this.codeUnified=void 0,this.codeDeletions?.remove(),this.codeDeletions=void 0,this.codeAdditions?.remove(),this.codeAdditions=void 0,this.pre?.remove(),this.pre=void 0,this.appliedPreAttributes=void 0,this.lastRowCount=void 0}clearAuxiliaryNodes(){for(let{element:e}of this.separatorCache.values())e.remove();this.separatorCache.clear();for(let{element:e}of this.annotationCache.values())e.remove();this.annotationCache.clear(),this.gutterUtilityContent?.remove(),this.gutterUtilityContent=void 0}renderPlaceholder(e){if(this.fileContainer==null)return!1;if(this.emitPostRender(!0),this.cleanChildNodes(),this.placeHolder==null){let e=this.fileContainer.shadowRoot??this.fileContainer.attachShadow({mode:`open`});this.placeHolder=document.createElement(`div`),this.placeHolder.dataset.placeholder=``,e.appendChild(this.placeHolder)}return this.placeHolder.style.setProperty(`height`,`${e}px`),!0}primeHighlightCache(){let{fileDiff:e,workerManager:t}=this;if(e==null||t==null||Ac(e))return;let n=this.options.tokenizeMaxLength??1e5;Math.max(e.additionLines.length,e.deletionLines.length)>n||t.primeDiffHighlightCache(e)}cleanChildNodes(){this.resizeManager.cleanUp(),this.scrollSyncManager.cleanUp(),this.interactionManager.cleanUp(),this.clearAuxiliaryNodes(),this.bufferAfter?.remove(),this.bufferBefore?.remove(),this.codeAdditions?.remove(),this.codeDeletions?.remove(),this.codeUnified?.remove(),this.errorWrapper?.remove(),this.headerElement?.remove(),this.headerPrefix?.remove(),this.headerMetadata?.remove(),this.headerCustom?.remove(),this.pre?.remove(),this.spriteSVG?.remove(),this.themeCSSStyle?.remove(),this.unsafeCSSStyle?.remove(),this.bufferAfter=void 0,this.bufferBefore=void 0,this.codeAdditions=void 0,this.codeDeletions=void 0,this.codeUnified=void 0,this.errorWrapper=void 0,this.headerElement=void 0,this.headerPrefix=void 0,this.headerMetadata=void 0,this.headerCustom=void 0,this.pre=void 0,this.spriteSVG=void 0,this.themeCSSStyle=void 0,this.appliedThemeCSS=void 0,this.hasAdoptedThemeCSS=!1,this.unsafeCSSStyle=void 0,this.appliedUnsafeCSS=void 0,this.lastRenderedHeaderHTML=void 0,this.lastRowCount=void 0,this.mounted=!1}renderSeparators(e){let{hunkSeparators:t}=this.options;if(this.isContainerManaged||this.fileContainer==null||typeof t!=`function`){for(let{element:e}of this.separatorCache.values())e.remove();this.separatorCache.clear();return}let n=new Map(this.separatorCache);for(let r of e){let e=r.slotName,i=this.separatorCache.get(e);if(i==null||!Kv(r,i.hunkData)){i?.element.remove();let n=document.createElement(`div`);n.style.display=`contents`,n.slot=r.slotName;let a=t(r,this);a!=null&&n.appendChild(a),this.fileContainer.appendChild(n),i={element:n,hunkData:r},this.separatorCache.set(e,i)}n.delete(e)}for(let[e,{element:t}]of n.entries())this.separatorCache.delete(e),t.remove()}renderAnnotations(){if(this.isContainerManaged||this.fileContainer==null){for(let{element:e}of this.annotationCache.values())e.remove();this.annotationCache.clear();return}let e=new Map(this.annotationCache),{renderAnnotation:t}=this.options;if(t!=null&&this.lineAnnotations.length>0)for(let[n,r]of this.lineAnnotations.entries()){let i=`${n}-${ws(r)}`,a=this.annotationCache.get(i);if(a==null||!Gv(r,a.annotation)){a?.element.remove();let e=t(r);if(e==null)continue;a={element:ks(ws(r)),annotation:r},a.element.appendChild(e),this.fileContainer.appendChild(a.element),this.annotationCache.set(i,a)}e.delete(i)}for(let[t,{element:n}]of e.entries())this.annotationCache.delete(t),n.remove()}renderGutterUtility(){let{renderGutterUtility:e}=this.options;if(this.fileContainer==null||e==null){this.gutterUtilityContent?.remove(),this.gutterUtilityContent=void 0;return}let t=e(this.interactionManager.getHoveredLine);if(t!=null&&this.gutterUtilityContent!=null)return;if(t==null){this.gutterUtilityContent?.remove(),this.gutterUtilityContent=void 0;return}let n=As();n.appendChild(t),this.fileContainer.appendChild(n),this.gutterUtilityContent=n}getOrCreateFileContainer(e,t){let{fileContainer:n}=this,r=e??n??document.createElement(`diffs-container`),i=n!==r;return i&&this.emitPostRender(!0),this.fileContainer=r,n!=null&&i&&(this.lastRenderedHeaderHTML=void 0,this.headerElement=void 0),t!=null&&this.fileContainer.parentNode!==t&&t.appendChild(this.fileContainer),i&&this.adoptReusableShellElements(this.fileContainer),this.ensureSpriteSVG(this.fileContainer),this.fileContainer}adoptReusableShellElements(e){let{shadowRoot:t}=e;if(t!=null)for(let e of t.children)e instanceof SVGElement?this.spriteSVG??=e:Fi(e)&&e.hasAttribute(`data-theme-css`)?(this.themeCSSStyle??=e,this.hasAdoptedThemeCSS=!0):Fi(e)&&e.hasAttribute(`data-unsafe-css`)&&(this.unsafeCSSStyle??=e,this.appliedUnsafeCSS??=this.options.unsafeCSS??void 0)}ensureSpriteSVG(e){let t=e.shadowRoot??e.attachShadow({mode:`open`});if(this.spriteSVG==null){let e=document.createElement(`div`);e.innerHTML=Ts;let t=e.firstChild;t instanceof SVGElement&&(this.spriteSVG=t)}this.spriteSVG!=null&&this.spriteSVG.parentNode!==t&&t.appendChild(this.spriteSVG)}getOrCreatePreNode(e){let t=e.shadowRoot??e.attachShadow({mode:`open`});return this.pre==null?(this.pre=document.createElement(`pre`),this.appliedPreAttributes=void 0,this.codeUnified=void 0,this.codeDeletions=void 0,this.codeAdditions=void 0,t.appendChild(this.pre)):this.pre.parentNode!==t&&(t.appendChild(this.pre),this.appliedPreAttributes=void 0),this.placeHolder?.remove(),this.placeHolder=void 0,this.pre}syncCodeNodesFromPre(e){this.codeUnified=void 0,this.codeDeletions=void 0,this.codeAdditions=void 0;for(let t of Array.from(e.children))t instanceof HTMLElement&&(t.hasAttribute(`data-unified`)?this.codeUnified=t:t.hasAttribute(`data-deletions`)?this.codeDeletions=t:t.hasAttribute(`data-additions`)&&(this.codeAdditions=t))}applyHeaderToDOM(e,t){this.cleanupErrorWrapper(),this.placeHolder?.remove(),this.placeHolder=void 0;let{fileDiff:n}=this,r=this.cachedHeaderHTML??Yo(e);if(this.cachedHeaderHTML=r,r!==this.lastRenderedHeaderHTML){let e=document.createElement(`div`);e.innerHTML=r;let n=e.firstElementChild;if(!(n instanceof HTMLElement))return;this.headerElement==null?t.shadowRoot?.prepend(n):t.shadowRoot?.replaceChild(n,this.headerElement),this.headerElement=n,this.lastRenderedHeaderHTML=r}if(this.isContainerManaged||n==null)return;let{renderCustomHeader:i,renderHeaderPrefix:a,renderHeaderMetadata:o}=this.options;if(i!=null){let e=i(n)??void 0;this.headerCustom=this.upsertHeaderSlotElement(t,this.headerCustom,Wr,e),this.headerPrefix?.remove(),this.headerMetadata?.remove(),this.headerPrefix=void 0,this.headerMetadata=void 0;return}let s=a?.(n)??void 0,c=o?.(n)??void 0;this.headerPrefix=this.upsertHeaderSlotElement(t,this.headerPrefix,Hr,s),this.headerMetadata=this.upsertHeaderSlotElement(t,this.headerMetadata,Ur,c),this.headerCustom?.remove(),this.headerCustom=void 0}clearHeaderSlots(){this.headerPrefix?.remove(),this.headerMetadata?.remove(),this.headerCustom?.remove(),this.headerPrefix=void 0,this.headerMetadata=void 0,this.headerCustom=void 0}upsertHeaderSlotElement(e,t,n,r){if(r==null){t?.remove();return}let i=t??this.createHeaderSlotElement(n);return t??e.appendChild(i),this.replaceHeaderSlotContent(i,r),i}replaceHeaderSlotContent(e,t){e.replaceChildren(),t instanceof Element?e.appendChild(t):e.innerText=`${t}`}createHeaderSlotElement(e){let t=document.createElement(`div`);return t.slot=e,t}injectUnsafeCSS(){let{unsafeCSS:e}=this.options,t=this.fileContainer?.shadowRoot;if(t!=null){if(e==null||e===``){this.unsafeCSSStyle!=null&&(this.unsafeCSSStyle.remove(),this.unsafeCSSStyle=void 0),this.appliedUnsafeCSS=void 0;return}this.unsafeCSSStyle?.parentNode===t&&this.appliedUnsafeCSS===e||(this.unsafeCSSStyle??=js(),this.unsafeCSSStyle.parentNode!==t&&t.appendChild(this.unsafeCSSStyle),this.unsafeCSSStyle.textContent=Rs(e),this.appliedUnsafeCSS=e)}}applyThemeState(e,t,n,r){let i=e.shadowRoot??e.attachShadow({mode:`open`}),a=r??n,o=this.options.theme??Gr,s=typeof o==`string`?o:{...o},c=Ns(i);if(this.themeCSSStyle?.parentNode===i&&this.appliedThemeCSS?.themeStyles===t&&this.appliedThemeCSS.themeType===a&&this.appliedThemeCSS.scrollbarGutter===c){this.appliedThemeCSS.theme=s;return}if(this.hasAdoptedThemeCSS&&this.themeCSSStyle?.parentNode===i){this.hasAdoptedThemeCSS=!1,this.appliedThemeCSS={theme:s,themeStyles:t,themeType:a,baseThemeType:r,scrollbarGutter:c};return}this.themeCSSStyle=Us({shadowRoot:i,currentNode:this.themeCSSStyle,themeCSS:zs(t,a,c)}),this.appliedThemeCSS=this.themeCSSStyle==null?void 0:{theme:s,themeStyles:t,themeType:a,baseThemeType:r,scrollbarGutter:c}}hydrateMeasuredScrollbar(){let e=this.fileContainer?.shadowRoot;e==null||this.themeCSSStyle==null||(this.themeCSSStyle.textContent=Bs(this.themeCSSStyle.textContent??``,Ns(e)))}applyHunksToDOM(e,t){let{overflow:n=`scroll`}=this.options,r=(this.options.hunkSeparators??`line-info`)===`line-info`,i=n===`wrap`?t.rowCount:void 0;this.cleanupErrorWrapper(),this.applyPreNodeAttributes(e,t);let a=!1,o=[],s=this.hunksRenderer.renderCodeAST(`unified`,t),c=this.hunksRenderer.renderCodeAST(`deletions`,t),l=this.hunksRenderer.renderCodeAST(`additions`,t);s==null?c!=null||l!=null?(c==null?(this.codeDeletions?.remove(),this.codeDeletions=void 0):(a=this.codeDeletions==null||this.codeUnified!=null,this.codeUnified?.remove(),this.codeUnified=void 0,this.codeDeletions=Hs({code:this.codeDeletions,columnType:`deletions`,rowSpan:i,containerSize:r}),this.codeDeletions.innerHTML=this.hunksRenderer.renderPartialHTML(c),o.push(this.codeDeletions)),l==null?(this.codeAdditions?.remove(),this.codeAdditions=void 0):(a=a||this.codeAdditions==null||this.codeUnified!=null,this.codeUnified?.remove(),this.codeUnified=void 0,this.codeAdditions=Hs({code:this.codeAdditions,columnType:`additions`,rowSpan:i,containerSize:r}),this.codeAdditions.innerHTML=this.hunksRenderer.renderPartialHTML(l),o.push(this.codeAdditions))):(this.codeUnified?.remove(),this.codeUnified=void 0,this.codeDeletions?.remove(),this.codeDeletions=void 0,this.codeAdditions?.remove(),this.codeAdditions=void 0):(a=this.codeUnified==null||this.codeAdditions!=null||this.codeDeletions!=null,this.codeDeletions?.remove(),this.codeDeletions=void 0,this.codeAdditions?.remove(),this.codeAdditions=void 0,this.codeUnified=Hs({code:this.codeUnified,columnType:`unified`,rowSpan:i,containerSize:r}),this.codeUnified.innerHTML=this.hunksRenderer.renderPartialHTML(s),o.push(this.codeUnified)),o.length===0?e.textContent=``:a&&e.replaceChildren(...o),this.lastRowCount=t.rowCount}applyPartialRender({previousRenderRange:e,renderRange:t}){let{pre:n,codeUnified:r,codeAdditions:i,codeDeletions:a,options:{diffStyle:o=`split`}}=this;if(n==null||e==null||t==null||!Number.isFinite(e.totalLines)||!Number.isFinite(t.totalLines)||this.lastRowCount==null)return!1;let s=this.getCodeColumns(o,r,a,i);if(s==null)return!1;let c=e.startingLine,l=t.startingLine,u=c+e.totalLines,d=l+t.totalLines,f=Math.max(c,l),p=Math.min(u,d);if(p<=f)return!1;let m=Math.max(0,f-c),h=Math.max(0,u-p),g=this.trimColumns({columns:s,trimStart:m,trimEnd:h,previousStart:c,overlapStart:f,overlapEnd:p,diffStyle:o});if(g<0)throw Error(`applyPartialRender: failed to trim to overlap`);if(this.lastRowCount<g)throw Error(`applyPartialRender: trimmed beyond DOM row count`);let _=this.lastRowCount-g,v=(e,t)=>{if(!(t<=0||this.fileDiff==null))return this.hunksRenderer.renderDiff(this.fileDiff,{startingLine:e,totalLines:t,bufferBefore:0,bufferAfter:0})},y=v(l,Math.max(f-l,0));if(y==null&&l<f)return!1;let b=v(p,Math.max(d-p,0));if(b==null&&d>p)return!1;let x=(e,t)=>{if(e!=null){if(o===`unified`&&!Array.isArray(s))this.insertPartialHTML(o,s,e,t);else if(o===`split`&&Array.isArray(s))this.insertPartialHTML(o,s,e,t);else throw Error(`FileDiff.applyPartialRender.applyChunk: invalid chunk application`);_+=e.rowCount}};return this.cleanupErrorWrapper(),x(y,`afterbegin`),x(b,`beforeend`),this.lastRowCount!==_&&(this.applyRowSpan(o,s,_),this.lastRowCount=_),!0}insertPartialHTML(e,t,n,r){if(e===`unified`&&!Array.isArray(t)){let e=this.hunksRenderer.renderCodeAST(`unified`,n);this.renderPartialColumn(t,e,r)}else if(e===`split`&&Array.isArray(t)){let e=this.hunksRenderer.renderCodeAST(`deletions`,n),i=this.hunksRenderer.renderCodeAST(`additions`,n);this.renderPartialColumn(t[0],e,r),this.renderPartialColumn(t[1],i,r)}else throw Error(`FileDiff.insertPartialHTML: Invalid argument composition`)}renderPartialColumn(e,t,n){if(e==null||t==null)return;let r=ey(t[0]),i=ey(t[1]);if(r==null||i==null)throw Error(`FileDiff.insertPartialHTML: Unexpected AST structure`);let a=i.at(0);n===`beforeend`&&a?.type===`element`&&typeof a.properties[`data-buffer-size`]==`number`&&this.mergeBuffersIfNecessary(a.properties[`data-buffer-size`],e.content.children[e.content.children.length-1],e.gutter.children[e.gutter.children.length-1],r,i,!0);let o=i.at(-1);n===`afterbegin`&&o?.type===`element`&&typeof o.properties[`data-buffer-size`]==`number`&&this.mergeBuffersIfNecessary(o.properties[`data-buffer-size`],e.content.children[0],e.gutter.children[0],r,i,!1),e.gutter.insertAdjacentHTML(n,this.hunksRenderer.renderPartialHTML(r)),e.content.insertAdjacentHTML(n,this.hunksRenderer.renderPartialHTML(i))}mergeBuffersIfNecessary(e,t,n,r,i,a){if(!(t instanceof HTMLElement)||!(n instanceof HTMLElement))return;let o=this.getBufferSize(t.dataset);o!=null&&(a?(r.shift(),i.shift()):(r.pop(),i.pop()),this.updateBufferSize(t,o+e),this.updateBufferSize(n,o+e))}applyRowSpan(e,t,n){let r=e=>{e!=null&&(e.gutter.style.setProperty(`grid-row`,`span ${n}`),e.content.style.setProperty(`grid-row`,`span ${n}`))};if(e===`unified`&&!Array.isArray(t))r(t);else if(e===`split`&&Array.isArray(t))r(t[0]),r(t[1]);else throw Error(`dun fuuuuked up`)}trimColumnRows(e,t,n){let r=0,i=0,a=0,o=!1,s=n>=0;if(e==null)return 0;let c=Array.from(e.content.children),l=Array.from(e.gutter.children);if(c.length!==l.length)throw Error(`FileDiff.trimColumnRows: columns do not match`);for(;a<c.length&&!(t<=0&&!s&&!o);){let e=l[a],u=c[a];if(a++,!(e instanceof HTMLElement)||!(u instanceof HTMLElement))throw console.error({gutterElement:e,contentElement:u}),Error(`FileDiff.trimColumnRows: invalid row elements`);if(o&&(o=!1,e.dataset.gutterBuffer===`annotation`&&`lineAnnotation`in u.dataset||e.dataset.gutterBuffer===`metadata`&&`noNewline`in u.dataset)){e.remove(),u.remove(),i++;continue}if(`lineIndex`in e.dataset&&`lineIndex`in u.dataset){(t>0||s&&r>=n)&&(e.remove(),u.remove(),t>0&&(t--,t===0&&(o=!0)),i++),r++;continue}if(`separator`in e.dataset&&`separator`in u.dataset){(t>0||s&&r>=n)&&(e.remove(),u.remove(),i++);continue}if(e.dataset.gutterBuffer===`annotation`&&`lineAnnotation`in u.dataset){(t>0||s&&r>=n)&&(e.remove(),u.remove(),i++);continue}if(e.dataset.gutterBuffer===`metadata`&&`noNewline`in u.dataset){(t>0||s&&r>=n)&&(e.remove(),u.remove(),i++);continue}if(e.dataset.gutterBuffer===`buffer`&&`contentBuffer`in u.dataset){let a=this.getBufferSize(u.dataset);if(a==null)throw Error(`FileDiff.trimColumnRows: invalid element`);if(t>0){let n=Math.min(t,a),r=a-n;r>0?(this.updateBufferSize(e,r),this.updateBufferSize(u,r),i+=n):(e.remove(),u.remove(),i+=a),t-=n,t===0&&r===0&&(o=!0)}else if(s){let t=r,o=r+a-1;if(n<=t)e.remove(),u.remove(),i+=a;else if(n<=o){let t=o-n+1,r=a-t;this.updateBufferSize(e,r),this.updateBufferSize(u,r),i+=t}}r+=a;continue}throw console.error({gutterElement:e,contentElement:u}),Error(`FileDiff.trimColumnRows: unknown row elements`)}return i}trimColumns({columns:e,diffStyle:t,overlapEnd:n,overlapStart:r,previousStart:i,trimEnd:a,trimStart:o}){let s=Math.max(0,r-i),c=n-i;if(c<0)throw Error(`FileDiff.trimColumns: overlap ends before previous`);let l=o>0,u=a>0;if(!l&&!u)return 0;let d=l?s:0,f=u?c:-1;if(t===`unified`&&!Array.isArray(e))return this.trimColumnRows(e,d,f);if(t===`split`&&Array.isArray(e)){let t=this.trimColumnRows(e[0],d,f),n=this.trimColumnRows(e[1],d,f);if(e[0]!=null&&e[1]!=null&&t!==n)throw Error(`FileDiff.trimColumns: split columns out of sync`);return e[0]==null?n:t}else throw console.error({diffStyle:t,columns:e}),Error(`FileDiff.trimColumns: Invalid columns for diffType`)}getBufferSize(e){let t=Number.parseInt(e?.bufferSize??``,10);return Number.isNaN(t)?void 0:t}updateBufferSize(e,t){e.dataset.bufferSize=`${t}`,e.style.setProperty(`grid-row`,`span ${t}`),e.style.setProperty(`min-height`,`calc(${t} * 1lh)`)}getCodeColumns(e,t,n,r){function i(e){if(e==null)return;let t=e.children[0],n=e.children[1];if(!(!(t instanceof HTMLElement)||!(n instanceof HTMLElement)||t.dataset.gutter==null||n.dataset.content==null))return{gutter:t,content:n}}if(e===`unified`)return i(t);{let e=i(n),t=i(r);return e!=null||t!=null?[e,t]:void 0}}applyBuffers(e,t){if(t==null||this.shouldDisableVirtualizationBuffers()){this.bufferBefore!=null&&(this.bufferBefore.remove(),this.bufferBefore=void 0),this.bufferAfter!=null&&(this.bufferAfter.remove(),this.bufferAfter=void 0);return}t.bufferBefore>0?(this.bufferBefore??(this.bufferBefore=document.createElement(`div`),this.bufferBefore.dataset.virtualizerBuffer=`before`,e.before(this.bufferBefore)),this.bufferBefore.style.setProperty(`height`,`${t.bufferBefore}px`),this.bufferBefore.style.setProperty(`contain`,`strict`)):this.bufferBefore!=null&&(this.bufferBefore.remove(),this.bufferBefore=void 0),t.bufferAfter>0?(this.bufferAfter??(this.bufferAfter=document.createElement(`div`),this.bufferAfter.dataset.virtualizerBuffer=`after`,e.after(this.bufferAfter)),this.bufferAfter.style.setProperty(`height`,`${t.bufferAfter}px`),this.bufferAfter.style.setProperty(`contain`,`strict`)):this.bufferAfter!=null&&(this.bufferAfter.remove(),this.bufferAfter=void 0)}shouldDisableVirtualizationBuffers(){return this.options.disableVirtualizationBuffers??!1}applyPreNodeAttributes(e,{additionsContentAST:t,deletionsContentAST:n,totalLines:r},i){let{diffIndicators:a=`bars`,disableBackground:o=!1,disableLineNumbers:s=!1,overflow:c=`scroll`,diffStyle:l=`split`}=this.options,u={type:`diff`,diffIndicators:a,disableBackground:o,disableLineNumbers:s,overflow:c,split:l===`unified`?!1:t!=null&&n!=null,totalLines:r,customProperties:i};Es(u,this.appliedPreAttributes)||(Ks(e,u),this.appliedPreAttributes=u)}applyErrorToDOM(e,t){this.cleanupErrorWrapper(),this.pre?.remove(),this.pre=void 0,this.appliedPreAttributes=void 0;let n=t.shadowRoot??t.attachShadow({mode:`open`});this.errorWrapper??=document.createElement(`div`),this.errorWrapper.dataset.errorWrapper=``,this.errorWrapper.textContent=``,n.appendChild(this.errorWrapper);let r=document.createElement(`div`);r.dataset.errorMessage=``,r.innerText=e.message,this.errorWrapper.appendChild(r);let i=document.createElement(`pre`);i.dataset.errorStack=``,i.innerText=e.stack??`No Error Stack`,this.errorWrapper.appendChild(i)}cleanupErrorWrapper(){this.errorWrapper?.remove(),this.errorWrapper=void 0}};function Xv({fileDiff:e,oldFile:t,newFile:n}){return e!=null&&e.hunks.length>0||t!=null||n!=null}function Zv({fileDiff:e,oldFile:t,newFile:n}){return e!=null||t!=null||n!=null}function Qv(e,t,n=!1){return!n&&e==null&&t}function $v(e,t,n=!1){return e==null&&t&&!n}function ey(e){if(!(e==null||e.type!==`element`))return e.children??[]}function ty(e,t){return e.split(/(?=^diff --git )/m).find(e=>ny(e)===t)}function ny(e){return e.match(/^\+\+\+ b\/(.+)$/m)?.[1]||e.match(/^--- a\/(.+)$/m)?.[1]||e.match(/^diff --git a\/(.+?) b\/(.+)$/m)?.[2]}function ry(e){return e===`left`?`deletions`:`additions`}function iy(e){return t=>{let n=t.metadata;return n.kind===`draft`?ay(n,e):oy(n,e)}}function ay(e,t){let n=document.createElement(e.editing?`form`:`article`),r=document.createElement(`div`),i=document.createElement(`strong`);if(n.className=`diff-annotation diff-annotation-draft`,r.className=`diff-annotation-heading`,i.textContent=`Draft comment`,e.editing){let a=document.createElement(`span`),o=document.createElement(`textarea`),s=document.createElement(`div`),c=document.createElement(`button`),l=document.createElement(`button`);a.textContent=e.pending?`Saving…`:`Editing`,o.className=`TextBox`,o.value=e.body,o.rows=3,o.disabled=e.pending,s.className=`diff-comment-actions`,c.className=`Button`,c.type=`button`,c.textContent=`Cancel`,c.disabled=e.pending,l.type=`submit`,l.className=`Button`,l.textContent=e.pending?`Saving…`:`Save comment`,l.disabled=e.pending,c.addEventListener(`click`,()=>t.setEditingCommentId(void 0)),n.addEventListener(`submit`,n=>{n.preventDefault();let r=o.value.trim();if(!r){o.focus();return}t.onUpdateComment(e.id,r)?.then(e=>{e&&t.setEditingCommentId(void 0)})}),r.append(i,a),s.append(c,l),n.append(r,o,s),queueMicrotask(()=>{o.focus(),o.setSelectionRange(o.value.length,o.value.length)})}else{let a=document.createElement(`div`),o=document.createElement(`span`),s=document.createElement(`button`),c=document.createElement(`button`),l=document.createElement(`p`);a.className=`diff-annotation-controls`,o.textContent=e.pending?`Working…`:`Pending`,s.className=`LinkButton`,s.type=`button`,s.textContent=`Edit`,s.disabled=e.pending,c.type=`button`,c.className=`danger-link LinkButton`,c.textContent=`Delete`,c.disabled=e.pending,l.textContent=e.body,s.addEventListener(`click`,()=>t.setEditingCommentId(e.id)),c.addEventListener(`click`,()=>{window.confirm(`Delete this draft comment?`)&&t.onDeleteComment(e.id)?.then(n=>{n&&t.editingCommentId()===e.id&&t.setEditingCommentId(void 0)})}),a.append(o,s,c),r.append(i,a),n.append(r,l)}return n}function oy(e,t){let n=document.createElement(`form`),r=document.createElement(`div`),i=document.createElement(`strong`),a=document.createElement(`span`),o=document.createElement(`textarea`),s=document.createElement(`div`),c=document.createElement(`button`),l=document.createElement(`button`);return n.className=`diff-annotation diff-comment-composer`,r.className=`diff-annotation-heading`,i.textContent=`Add review comment`,a.textContent=`${e.target.side===`left`?`Old`:`New`} line ${e.target.line}`,o.className=`TextBox`,o.placeholder=`Leave a comment on this line…`,o.rows=3,o.disabled=e.pending,s.className=`diff-comment-actions`,c.className=`Button`,c.type=`button`,c.textContent=`Cancel`,c.disabled=e.pending,l.type=`submit`,l.className=`Button`,l.textContent=e.pending?`Adding…`:`Add to review`,l.disabled=e.pending,c.addEventListener(`click`,t.closeCommentComposer),n.addEventListener(`submit`,n=>{n.preventDefault();let r=o.value.trim();if(!r){o.focus();return}t.onAddComment(e.target.line,e.target.side,r)?.then(e=>{e&&t.closeCommentComposer()})}),r.append(i,a),s.append(c,l),n.append(r,o,s),queueMicrotask(()=>o.focus()),n}var sy=B(`<div>`),cy=B(`<div class=diff-viewer>`),ly=B(`<div class=diff-empty><span class=diff-empty-icon>{ }</span><p>`);function uy(e){return e===`deletions`?`left`:`right`}function dy(e){let[t,n]=C(),[r,i]=C(),[a,o]=C(),s,c;function l(){i(void 0),s?.setSelectedLines(null)}let u=iy({closeCommentComposer:l,editingCommentId:a,onAddComment:(t,n,r)=>e.onAddComment?.(t,n,r),onDeleteComment:t=>e.onDeleteComment?.(t),onUpdateComment:(t,n)=>e.onUpdateComment?.(t,n),setEditingCommentId:o});function d(){return new Yv({diffStyle:`split`,disableFileHeader:!0,enableGutterUtility:!0,enableLineSelection:!0,hunkSeparators:`line-info`,lineDiffType:`word`,lineHoverHighlight:`both`,onGutterUtilityClick:e=>{i({line:e.end,side:uy(e.endSide??e.side??`additions`)})},onLineEnter:({numberElement:e})=>{let t=e.querySelector(`[data-utility-button]`);t?.setAttribute(`aria-label`,`Add a review comment`),t?.setAttribute(`title`,`Add a review comment`)},overflow:`scroll`,renderAnnotation:u,theme:{dark:`github-dark`,light:`github-light`},themeType:`light`,unsafeCSS:`
1559
+ [data-utility-button] {
1560
+ align-items: center;
1561
+ background: #3168d5;
1562
+ border: 0;
1563
+ border-radius: 4px;
1564
+ color: #fff;
1565
+ cursor: pointer;
1566
+ display: flex;
1567
+ height: 17px;
1568
+ justify-content: center;
1569
+ margin-left: -2px;
1570
+ padding: 0;
1571
+ width: 17px;
1572
+ }
1573
+ [data-utility-button]:hover { background: #285bbd; }
1574
+ [data-utility-button] [data-icon] { height: 11px; width: 11px; }
1575
+ `})}function f(){s?.cleanUp(),s=void 0}let p=E(()=>{let t=(e.selectedPath?ty(e.diff,e.selectedPath):e.diff)?.trim()??``;if(t.length!==0)return fi(t,`review-diff`).flatMap(e=>e.files)[0]}),m=E(()=>{let t=e.selectedPath,n=a(),i=(e.draftComments??[]).filter(e=>e.filePath===t).map(t=>({lineNumber:t.line,metadata:{body:t.body,editing:t.id===n,id:t.id,kind:`draft`,pending:!!e.commentPending},side:ry(t.side)})),o=r();return o&&i.push({lineNumber:o.line,metadata:{kind:`composer`,pending:!!e.commentPending,target:o},side:ry(o.side)}),i});return T(()=>{let e=p(),n=t(),r=m();if(!n||!e){f();return}s??=d(),s.render({fileDiff:e,containerWrapper:n,forceRender:!0,lineAnnotations:r})}),T(()=>{let t=e.selectedPath;t!==c&&(i(void 0),o(void 0),c=t)}),k(f),(()=>{var t=cy();return V(t,z(Te,{get when(){return p()},get fallback(){return(()=>{var t=ly(),n=t.firstChild.nextSibling;return V(n,()=>e.loading?`Loading diff…`:`No diff is available for this file.`),t})()},get children(){var e=sy();return Je(n,e),e}})),t})()}var fy=B(`<div class=file-identity><span></span><strong>`),py=B(`<div class=file-toolbar-actions><span class=file-position> / </span><div class=file-nav><button type=button class=ToolbarButton aria-label="Previous file"title="Previous file">↑</button><button type=button class=ToolbarButton aria-label="Next file"title="Next file">↓`),my=B(`<footer class=diff-statusbar><span class=StatusField>Split diff · <!> pending comments`),hy=B(`<span class=group-context>`),gy=B(`<span class=file-changes><span class=additions>+</span><span class=deletions>−`);function _y(e){return z(wt,{as:`section`,class:`diff-workspace`,get children(){return[z(yt,{as:`header`,class:`diff-toolbar`,get children(){return[(()=>{var t=fy(),n=t.firstChild,r=n.nextSibling;return V(r,()=>e.activeFile??`No file selected`),V(t,z(Te,{get when(){return e.selectedGroup},children:e=>(()=>{var t=hy();return V(t,()=>e().title),t})()}),null),w(()=>He(n,`file-status ${e.activeReviewFile?.status??``}`)),t})(),(()=>{var t=py(),n=t.firstChild,r=n.firstChild,i=n.nextSibling.firstChild,a=i.nextSibling;return V(t,z(Te,{get when(){return e.activeReviewFile},children:e=>(()=>{var t=gy(),n=t.firstChild;n.firstChild;var r=n.nextSibling;return r.firstChild,V(n,()=>e().additions,null),V(r,()=>e().deletions,null),t})()}),n),V(n,()=>e.activeFileIndex+1,r),V(n,()=>e.visibleFileCount,null),i.$$click=()=>e.onMoveFile(-1),a.$$click=()=>e.onMoveFile(1),w(t=>{var n=e.activeFileIndex<=0,r=e.activeFileIndex<0||e.activeFileIndex>=e.visibleFileCount-1;return n!==t.e&&(i.disabled=t.e=n),r!==t.t&&(a.disabled=t.t=r),t},{e:void 0,t:void 0}),t})()]}}),z(Ot,{class:`diff-field`,get children(){return z(Ot.Content,{class:`diff-field-content`,get children(){return z(dy,{get commentPending(){return e.commentPending},get diff(){return e.activeDiff},get draftComments(){return e.draftComments},get loading(){return e.loading},get onAddComment(){return e.onAddComment},get onDeleteComment(){return e.onDeleteComment},get onUpdateComment(){return e.onUpdateComment},get selectedPath(){return e.activeFile}})}})}}),(()=>{var t=my(),n=t.firstChild,r=n.firstChild.nextSibling;return r.nextSibling,V(n,()=>e.draftComments.length,r),t})()]}})}Re([`click`]);var vy={af:`⁡`,applyfunction:`⁡`,ic:`⁣`,invisiblecomma:`⁣`,invisibletimes:`⁢`,it:`⁢`,lrm:`‎`,negativemediumspace:`​`,negativethickspace:`​`,negativethinspace:`​`,negativeverythinspace:`​`,nobreak:`⁠`,rlm:`‏`,shy:`­`,zerowidthspace:`​`,zwj:`‍`,zwnj:`‌`,downbreve:`̑`,tdot:`⃛`,tripledot:`⃛`,dotdot:`⃜`,tab:` `,newline:`
1576
+ `,emsp:` `,emsp13:` `,emsp14:` `,ensp:` `,hairsp:` `,mediumspace:` `,puncsp:` `,thinsp:` `,thinspace:` `,verythinspace:` `,nbsp:`\xA0`,nonbreakingspace:`\xA0`,numsp:` `,thickspace:`  `,oline:`‾`,overbar:`‾`,lowbar:`_`,underbar:`_`,dash:`‐`,hyphen:`‐`,ndash:`–`,mdash:`—`,horbar:`―`,comma:`,`,semi:`;`,bsemi:`⁏`,colon:`:`,Colone:`⩴`,excl:`!`,iexcl:`¡`,quest:`?`,iquest:`¿`,period:`.`,nldr:`‥`,hellip:`…`,mldr:`…`,centerdot:`·`,middot:`·`,apos:`'`,lsquo:`‘`,opencurlyquote:`‘`,closecurlyquote:`’`,rsquo:`’`,rsquor:`’`,lsquor:`‚`,sbquo:`‚`,lsaquo:`‹`,rsaquo:`›`,quot:`"`,ldquo:`“`,opencurlydoublequote:`“`,closecurlydoublequote:`”`,rdquo:`”`,rdquor:`”`,bdquo:`„`,ldquor:`„`,laquo:`«`,raquo:`»`,lpar:`(`,rpar:`)`,lbrack:`[`,lsqb:`[`,rbrack:`]`,rsqb:`]`,lbrace:`{`,lcub:`{`,rbrace:`}`,rcub:`}`,lceil:`⌈`,leftceiling:`⌈`,rceil:`⌉`,rightceiling:`⌉`,leftfloor:`⌊`,lfloor:`⌊`,rfloor:`⌋`,rightfloor:`⌋`,lopar:`⦅`,ropar:`⦆`,lbrke:`⦋`,rbrke:`⦌`,lbrkslu:`⦍`,rbrksld:`⦎`,lbrksld:`⦏`,rbrkslu:`⦐`,langd:`⦑`,rangd:`⦒`,lparlt:`⦓`,rpargt:`⦔`,gtlpar:`⦕`,ltrpar:`⦖`,leftdoublebracket:`⟦`,lobrk:`⟦`,rightdoublebracket:`⟧`,robrk:`⟧`,lang:`⟨`,langle:`⟨`,leftanglebracket:`⟨`,rang:`⟩`,rangle:`⟩`,rightanglebracket:`⟩`,Lang:`⟪`,Rang:`⟫`,loang:`⟬`,roang:`⟭`,lbbrk:`❲`,rbbrk:`❳`,Verbar:`‖`,Vert:`‖`,sect:`§`,para:`¶`,commat:`@`,ast:`*`,midast:`*`,sol:`/`,bsol:`\\`,amp:`&`,num:`#`,percnt:`%`,permil:`‰`,pertenk:`‱`,dagger:`†`,Dagger:`‡`,ddagger:`‡`,bull:`•`,bullet:`•`,hybull:`⁃`,prime:`′`,Prime:`″`,tprime:`‴`,qprime:`⁗`,backprime:`‵`,bprime:`‵`,caret:`⁁`,diacriticalgrave:"`",grave:"`",acute:`´`,diacriticalacute:`´`,diacriticaltilde:`˜`,tilde:`˜`,hat:`^`,macr:`¯`,strns:`¯`,breve:`˘`,diacriticaldot:`˙`,dot:`˙`,die:`¨`,Dot:`¨`,doubledot:`¨`,uml:`¨`,ring:`˚`,dblac:`˝`,diacriticaldoubleacute:`˝`,cedil:`¸`,cedilla:`¸`,ogon:`˛`,circ:`ˆ`,caron:`ˇ`,hacek:`ˇ`,deg:`°`,copy:`©`,circledr:`®`,reg:`®`,copysr:`℗`,weierp:`℘`,wp:`℘`,rx:`℞`,mho:`℧`,iiota:`℩`,larr:`←`,leftarrow:`←`,shortleftarrow:`←`,slarr:`←`,nlarr:`↚`,nleftarrow:`↚`,rarr:`→`,rightarrow:`→`,shortrightarrow:`→`,srarr:`→`,nrarr:`↛`,nrightarrow:`↛`,shortuparrow:`↑`,uarr:`↑`,uparrow:`↑`,darr:`↓`,downarrow:`↓`,shortdownarrow:`↓`,harr:`↔`,leftrightarrow:`↔`,nharr:`↮`,nleftrightarrow:`↮`,updownarrow:`↕`,varr:`↕`,nwarr:`↖`,nwarrow:`↖`,upperleftarrow:`↖`,nearr:`↗`,nearrow:`↗`,upperrightarrow:`↗`,lowerrightarrow:`↘`,searr:`↘`,searrow:`↘`,lowerleftarrow:`↙`,swarr:`↙`,swarrow:`↙`,rarrw:`↝`,rightsquigarrow:`↝`,nrarrw:`↝̸`,Larr:`↞`,twoheadleftarrow:`↞`,Uarr:`↟`,Rarr:`↠`,twoheadrightarrow:`↠`,Darr:`↡`,larrtl:`↢`,leftarrowtail:`↢`,rarrtl:`↣`,rightarrowtail:`↣`,leftteearrow:`↤`,mapstoleft:`↤`,mapstoup:`↥`,upteearrow:`↥`,map:`↦`,mapsto:`↦`,rightteearrow:`↦`,downteearrow:`↧`,mapstodown:`↧`,hookleftarrow:`↩`,larrhk:`↩`,hookrightarrow:`↪`,rarrhk:`↪`,larrlp:`↫`,looparrowleft:`↫`,looparrowright:`↬`,rarrlp:`↬`,harrw:`↭`,leftrightsquigarrow:`↭`,lsh:`↰`,rsh:`↱`,ldsh:`↲`,rdsh:`↳`,crarr:`↵`,cularr:`↶`,curvearrowleft:`↶`,curarr:`↷`,curvearrowright:`↷`,circlearrowleft:`↺`,olarr:`↺`,circlearrowright:`↻`,orarr:`↻`,leftharpoonup:`↼`,leftvector:`↼`,lharu:`↼`,downleftvector:`↽`,leftharpoondown:`↽`,lhard:`↽`,rightupvector:`↾`,uharr:`↾`,upharpoonright:`↾`,leftupvector:`↿`,uharl:`↿`,upharpoonleft:`↿`,rharu:`⇀`,rightharpoonup:`⇀`,rightvector:`⇀`,downrightvector:`⇁`,rhard:`⇁`,rightharpoondown:`⇁`,dharr:`⇂`,downharpoonright:`⇂`,rightdownvector:`⇂`,dharl:`⇃`,downharpoonleft:`⇃`,leftdownvector:`⇃`,rightarrowleftarrow:`⇄`,rightleftarrows:`⇄`,rlarr:`⇄`,udarr:`⇅`,uparrowdownarrow:`⇅`,leftarrowrightarrow:`⇆`,leftrightarrows:`⇆`,lrarr:`⇆`,leftleftarrows:`⇇`,llarr:`⇇`,upuparrows:`⇈`,uuarr:`⇈`,rightrightarrows:`⇉`,rrarr:`⇉`,ddarr:`⇊`,downdownarrows:`⇊`,leftrightharpoons:`⇋`,lrhar:`⇋`,reverseequilibrium:`⇋`,equilibrium:`⇌`,rightleftharpoons:`⇌`,rlhar:`⇌`,doubleleftarrow:`⇐`,lArr:`⇐`,Leftarrow:`⇐`,nlArr:`⇍`,nLeftarrow:`⇍`,doubleuparrow:`⇑`,uArr:`⇑`,Uparrow:`⇑`,doublerightarrow:`⇒`,implies:`⇒`,rArr:`⇒`,Rightarrow:`⇒`,nrArr:`⇏`,nRightarrow:`⇏`,dArr:`⇓`,doubledownarrow:`⇓`,Downarrow:`⇓`,doubleleftrightarrow:`⇔`,hArr:`⇔`,iff:`⇔`,Leftrightarrow:`⇔`,nhArr:`⇎`,nLeftrightarrow:`⇎`,doubleupdownarrow:`⇕`,Updownarrow:`⇕`,vArr:`⇕`,nwArr:`⇖`,neArr:`⇗`,seArr:`⇘`,swArr:`⇙`,laarr:`⇚`,lleftarrow:`⇚`,raarr:`⇛`,rrightarrow:`⇛`,zigrarr:`⇝`,larrb:`⇤`,leftarrowbar:`⇤`,rarrb:`⇥`,rightarrowbar:`⇥`,downarrowuparrow:`⇵`,duarr:`⇵`,loarr:`⇽`,roarr:`⇾`,hoarr:`⇿`,forall:`∀`,comp:`∁`,complement:`∁`,part:`∂`,partiald:`∂`,npart:`∂̸`,exist:`∃`,exists:`∃`,nexist:`∄`,nexists:`∄`,notexists:`∄`,empty:`∅`,emptyset:`∅`,emptyv:`∅`,varnothing:`∅`,del:`∇`,nabla:`∇`,element:`∈`,in:`∈`,isin:`∈`,isinv:`∈`,notelement:`∉`,notin:`∉`,notinva:`∉`,ni:`∋`,niv:`∋`,reverseelement:`∋`,suchthat:`∋`,notni:`∌`,notniva:`∌`,notreverseelement:`∌`,backepsilon:`϶`,bepsi:`϶`,prod:`∏`,product:`∏`,coprod:`∐`,coproduct:`∐`,sum:`∑`,plus:`+`,plusminus:`±`,plusmn:`±`,pm:`±`,div:`÷`,divide:`÷`,times:`×`,lt:`<`,nless:`≮`,nlt:`≮`,notless:`≮`,nvlt:`<⃒`,equals:`=`,ne:`≠`,notequal:`≠`,bne:`=⃥`,equal:`⩵`,gt:`>`,ngt:`≯`,ngtr:`≯`,notgreater:`≯`,nvgt:`>⃒`,not:`¬`,verbar:`|`,vert:`|`,verticalline:`|`,brvbar:`¦`,minus:`−`,minusplus:`∓`,mnplus:`∓`,mp:`∓`,dotplus:`∔`,plusdo:`∔`,frasl:`⁄`,backslash:`∖`,setminus:`∖`,setmn:`∖`,smallsetminus:`∖`,ssetmn:`∖`,lowast:`∗`,compfn:`∘`,smallcircle:`∘`,radic:`√`,sqrt:`√`,prop:`∝`,proportional:`∝`,propto:`∝`,varpropto:`∝`,vprop:`∝`,infin:`∞`,angrt:`∟`,ang:`∠`,angle:`∠`,nang:`∠⃒`,angmsd:`∡`,measuredangle:`∡`,angsph:`∢`,mid:`∣`,shortmid:`∣`,smid:`∣`,verticalbar:`∣`,nmid:`∤`,notverticalbar:`∤`,nshortmid:`∤`,nsmid:`∤`,doubleverticalbar:`∥`,par:`∥`,parallel:`∥`,shortparallel:`∥`,spar:`∥`,notdoubleverticalbar:`∦`,npar:`∦`,nparallel:`∦`,nshortparallel:`∦`,nspar:`∦`,and:`∧`,wedge:`∧`,or:`∨`,vee:`∨`,cap:`∩`,caps:`∩︀`,cup:`∪`,cups:`∪︀`,int:`∫`,integral:`∫`,Int:`∬`,iiint:`∭`,tint:`∭`,iiiint:`⨌`,qint:`⨌`,conint:`∮`,contourintegral:`∮`,oint:`∮`,Conint:`∯`,doublecontourintegral:`∯`,cconint:`∰`,cwint:`∱`,clockwisecontourintegral:`∲`,cwconint:`∲`,awconint:`∳`,counterclockwisecontourintegral:`∳`,there4:`∴`,therefore:`∴`,becaus:`∵`,because:`∵`,ratio:`∶`,Colon:`∷`,proportion:`∷`,dotminus:`∸`,minusd:`∸`,mddot:`∺`,homtht:`∻`,sim:`∼`,thicksim:`∼`,thksim:`∼`,Tilde:`∼`,nottilde:`≁`,nsim:`≁`,nvsim:`∼⃒`,backsim:`∽`,bsim:`∽`,race:`∽̱`,ac:`∾`,mstpos:`∾`,ace:`∾̳`,acd:`∿`,verticaltilde:`≀`,wr:`≀`,wreath:`≀`,eqsim:`≂`,equaltilde:`≂`,esim:`≂`,nesim:`≂̸`,notequaltilde:`≂̸`,sime:`≃`,simeq:`≃`,tildeequal:`≃`,nottildeequal:`≄`,nsime:`≄`,nsimeq:`≄`,cong:`≅`,tildefullequal:`≅`,ncong:`≇`,nottildefullequal:`≇`,simne:`≆`,ap:`≈`,approx:`≈`,asymp:`≈`,thickapprox:`≈`,thkap:`≈`,tildetilde:`≈`,nap:`≉`,napprox:`≉`,nottildetilde:`≉`,ape:`≊`,approxeq:`≊`,apid:`≋`,napid:`≋̸`,backcong:`≌`,bcong:`≌`,asympeq:`≍`,CupCap:`≍`,notcupcap:`≭`,nvap:`≍⃒`,bump:`≎`,Bumpeq:`≎`,humpdownhump:`≎`,nbump:`≎̸`,nothumpdownhump:`≎̸`,bumpe:`≏`,bumpeq:`≏`,humpequal:`≏`,nbumpe:`≏̸`,nothumpequal:`≏̸`,doteq:`≐`,dotequal:`≐`,esdot:`≐`,nedot:`≐̸`,doteqdot:`≑`,eDot:`≑`,efdot:`≒`,fallingdotseq:`≒`,erdot:`≓`,risingdotseq:`≓`,assign:`≔`,colone:`≔`,coloneq:`≔`,ecolon:`≕`,eqcolon:`≕`,ecir:`≖`,eqcirc:`≖`,circeq:`≗`,cire:`≗`,wedgeq:`≙`,veeeq:`≚`,triangleq:`≜`,trie:`≜`,equest:`≟`,questeq:`≟`,congruent:`≡`,equiv:`≡`,nequiv:`≢`,notcongruent:`≢`,bnequiv:`≡⃥`,le:`≤`,leq:`≤`,nle:`≰`,nleq:`≰`,notlessequal:`≰`,nvle:`≤⃒`,ge:`≥`,geq:`≥`,greaterequal:`≥`,nge:`≱`,ngeq:`≱`,notgreaterequal:`≱`,nvge:`≥⃒`,lE:`≦`,leqq:`≦`,lessfullequal:`≦`,nlE:`≦̸`,nleqq:`≦̸`,gE:`≧`,geqq:`≧`,greaterfullequal:`≧`,ngE:`≧̸`,ngeqq:`≧̸`,notgreaterfullequal:`≧̸`,lnE:`≨`,lneqq:`≨`,lvertneqq:`≨︀`,lvne:`≨︀`,gnE:`≩`,gneqq:`≩`,gvertneqq:`≩︀`,gvne:`≩︀`,ll:`≪`,Lt:`≪`,nestedlessless:`≪`,nltv:`≪̸`,notlessless:`≪̸`,nLt:`≪⃒`,gg:`≫`,Gt:`≫`,nestedgreatergreater:`≫`,ngtv:`≫̸`,notgreatergreater:`≫̸`,nGt:`≫⃒`,between:`≬`,twixt:`≬`,lesssim:`≲`,lesstilde:`≲`,lsim:`≲`,nlsim:`≴`,notlesstilde:`≴`,greatertilde:`≳`,gsim:`≳`,gtrsim:`≳`,ngsim:`≵`,notgreatertilde:`≵`,lessgreater:`≶`,lessgtr:`≶`,lg:`≶`,notlessgreater:`≸`,ntlg:`≸`,gl:`≷`,greaterless:`≷`,gtrless:`≷`,notgreaterless:`≹`,ntgl:`≹`,pr:`≺`,prec:`≺`,precedes:`≺`,notprecedes:`⊀`,npr:`⊀`,nprec:`⊀`,sc:`≻`,succ:`≻`,succeeds:`≻`,notsucceeds:`⊁`,nsc:`⊁`,nsucc:`⊁`,prcue:`≼`,preccurlyeq:`≼`,precedesslantequal:`≼`,notprecedesslantequal:`⋠`,nprcue:`⋠`,sccue:`≽`,succcurlyeq:`≽`,succeedsslantequal:`≽`,notsucceedsslantequal:`⋡`,nsccue:`⋡`,precedestilde:`≾`,precsim:`≾`,prsim:`≾`,scsim:`≿`,succeedstilde:`≿`,succsim:`≿`,notsucceedstilde:`≿̸`,sub:`⊂`,subset:`⊂`,nsub:`⊄`,notsubset:`⊂⃒`,nsubset:`⊂⃒`,vnsub:`⊂⃒`,sup:`⊃`,superset:`⊃`,supset:`⊃`,nsup:`⊅`,notsuperset:`⊃⃒`,nsupset:`⊃⃒`,vnsup:`⊃⃒`,sube:`⊆`,subseteq:`⊆`,subsetequal:`⊆`,notsubsetequal:`⊈`,nsube:`⊈`,nsubseteq:`⊈`,supe:`⊇`,supersetequal:`⊇`,supseteq:`⊇`,notsupersetequal:`⊉`,nsupe:`⊉`,nsupseteq:`⊉`,subne:`⊊`,subsetneq:`⊊`,varsubsetneq:`⊊︀`,vsubne:`⊊︀`,supne:`⊋`,supsetneq:`⊋`,varsupsetneq:`⊋︀`,vsupne:`⊋︀`,cupdot:`⊍`,unionplus:`⊎`,uplus:`⊎`,sqsub:`⊏`,sqsubset:`⊏`,squaresubset:`⊏`,notsquaresubset:`⊏̸`,sqsup:`⊐`,sqsupset:`⊐`,squaresuperset:`⊐`,notsquaresuperset:`⊐̸`,sqsube:`⊑`,sqsubseteq:`⊑`,squaresubsetequal:`⊑`,notsquaresubsetequal:`⋢`,nsqsube:`⋢`,sqsupe:`⊒`,sqsupseteq:`⊒`,squaresupersetequal:`⊒`,notsquaresupersetequal:`⋣`,nsqsupe:`⋣`,sqcap:`⊓`,sqcaps:`⊓︀`,squareintersection:`⊓`,sqcup:`⊔`,sqcups:`⊔︀`,squareunion:`⊔`,circleplus:`⊕`,oplus:`⊕`,circleminus:`⊖`,ominus:`⊖`,circletimes:`⊗`,otimes:`⊗`,osol:`⊘`,circledot:`⊙`,odot:`⊙`,circledcirc:`⊚`,ocir:`⊚`,circledast:`⊛`,oast:`⊛`,circleddash:`⊝`,odash:`⊝`,boxplus:`⊞`,plusb:`⊞`,boxminus:`⊟`,minusb:`⊟`,boxtimes:`⊠`,timesb:`⊠`,dotsquare:`⊡`,sdotb:`⊡`,righttee:`⊢`,vdash:`⊢`,nvdash:`⊬`,dashv:`⊣`,lefttee:`⊣`,downtee:`⊤`,top:`⊤`,bot:`⊥`,bottom:`⊥`,perp:`⊥`,uptee:`⊥`,models:`⊧`,doublerighttee:`⊨`,vDash:`⊨`,nvDash:`⊭`,Vdash:`⊩`,nVdash:`⊮`,vvdash:`⊪`,VDash:`⊫`,nVDash:`⊯`,prurel:`⊰`,lefttriangle:`⊲`,vartriangleleft:`⊲`,vltri:`⊲`,nltri:`⋪`,notlefttriangle:`⋪`,ntriangleleft:`⋪`,righttriangle:`⊳`,vartriangleright:`⊳`,vrtri:`⊳`,notrighttriangle:`⋫`,nrtri:`⋫`,ntriangleright:`⋫`,lefttriangleequal:`⊴`,ltrie:`⊴`,trianglelefteq:`⊴`,nltrie:`⋬`,notlefttriangleequal:`⋬`,ntrianglelefteq:`⋬`,nvltrie:`⊴⃒`,righttriangleequal:`⊵`,rtrie:`⊵`,trianglerighteq:`⊵`,notrighttriangleequal:`⋭`,nrtrie:`⋭`,ntrianglerighteq:`⋭`,nvrtrie:`⊵⃒`,origof:`⊶`,imof:`⊷`,multimap:`⊸`,mumap:`⊸`,hercon:`⊹`,intcal:`⊺`,intercal:`⊺`,veebar:`⊻`,barvee:`⊽`,angrtvb:`⊾`,lrtri:`⊿`,bigwedge:`⋀`,Wedge:`⋀`,xwedge:`⋀`,bigvee:`⋁`,Vee:`⋁`,xvee:`⋁`,bigcap:`⋂`,intersection:`⋂`,xcap:`⋂`,bigcup:`⋃`,union:`⋃`,xcup:`⋃`,diam:`⋄`,diamond:`⋄`,sdot:`⋅`,sstarf:`⋆`,Star:`⋆`,divideontimes:`⋇`,divonx:`⋇`,bowtie:`⋈`,ltimes:`⋉`,rtimes:`⋊`,leftthreetimes:`⋋`,lthree:`⋋`,rightthreetimes:`⋌`,rthree:`⋌`,backsimeq:`⋍`,bsime:`⋍`,curlyvee:`⋎`,cuvee:`⋎`,curlywedge:`⋏`,cuwed:`⋏`,Sub:`⋐`,Subset:`⋐`,Sup:`⋑`,Supset:`⋑`,Cap:`⋒`,Cup:`⋓`,fork:`⋔`,pitchfork:`⋔`,epar:`⋕`,lessdot:`⋖`,ltdot:`⋖`,gtdot:`⋗`,gtrdot:`⋗`,Ll:`⋘`,nll:`⋘̸`,Gg:`⋙`,ggg:`⋙`,ngg:`⋙̸`,leg:`⋚`,lesg:`⋚︀`,lesseqgtr:`⋚`,lessequalgreater:`⋚`,gel:`⋛`,gesl:`⋛︀`,greaterequalless:`⋛`,gtreqless:`⋛`,cuepr:`⋞`,curlyeqprec:`⋞`,cuesc:`⋟`,curlyeqsucc:`⋟`,lnsim:`⋦`,gnsim:`⋧`,precnsim:`⋨`,prnsim:`⋨`,scnsim:`⋩`,succnsim:`⋩`,vellip:`⋮`,ctdot:`⋯`,utdot:`⋰`,dtdot:`⋱`,disin:`⋲`,isinsv:`⋳`,isins:`⋴`,isindot:`⋵`,notindot:`⋵̸`,notinvc:`⋶`,notinvb:`⋷`,isine:`⋹`,notine:`⋹̸`,nisd:`⋺`,xnis:`⋻`,nis:`⋼`,notnivc:`⋽`,notnivb:`⋾`,barwed:`⌅`,barwedge:`⌅`,Barwed:`⌆`,doublebarwedge:`⌆`,drcrop:`⌌`,dlcrop:`⌍`,urcrop:`⌎`,ulcrop:`⌏`,bnot:`⌐`,profline:`⌒`,profsurf:`⌓`,telrec:`⌕`,target:`⌖`,ulcorn:`⌜`,ulcorner:`⌜`,urcorn:`⌝`,urcorner:`⌝`,dlcorn:`⌞`,llcorner:`⌞`,drcorn:`⌟`,lrcorner:`⌟`,frown:`⌢`,sfrown:`⌢`,smile:`⌣`,ssmile:`⌣`,cylcty:`⌭`,profalar:`⌮`,topbot:`⌶`,ovbar:`⌽`,solbar:`⌿`,angzarr:`⍼`,lmoust:`⎰`,lmoustache:`⎰`,rmoust:`⎱`,rmoustache:`⎱`,overbracket:`⎴`,tbrk:`⎴`,bbrk:`⎵`,underbracket:`⎵`,bbrktbrk:`⎶`,overparenthesis:`⏜`,underparenthesis:`⏝`,overbrace:`⏞`,underbrace:`⏟`,trpezium:`⏢`,elinters:`⏧`,blank:`␣`,boxh:`─`,horizontalline:`─`,boxv:`│`,boxdr:`┌`,boxdl:`┐`,boxur:`└`,boxul:`┘`,boxvr:`├`,boxvl:`┤`,boxhd:`┬`,boxhu:`┴`,boxvh:`┼`,boxH:`═`,boxV:`║`,boxdR:`╒`,boxDr:`╓`,boxDR:`╔`,boxdL:`╕`,boxDl:`╖`,boxDL:`╗`,boxuR:`╘`,boxUr:`╙`,boxUR:`╚`,boxuL:`╛`,boxUl:`╜`,boxUL:`╝`,boxvR:`╞`,boxVr:`╟`,boxVR:`╠`,boxvL:`╡`,boxVl:`╢`,boxVL:`╣`,boxHd:`╤`,boxhD:`╥`,boxHD:`╦`,boxHu:`╧`,boxhU:`╨`,boxHU:`╩`,boxvH:`╪`,boxVh:`╫`,boxVH:`╬`,uhblk:`▀`,lhblk:`▄`,block:`█`,blk14:`░`,blk12:`▒`,blk34:`▓`,squ:`□`,square:`□`,blacksquare:`▪`,filledverysmallsquare:`▪`,squarf:`▪`,squf:`▪`,emptyverysmallsquare:`▫`,rect:`▭`,marker:`▮`,fltns:`▱`,bigtriangleup:`△`,xutri:`△`,blacktriangle:`▴`,utrif:`▴`,triangle:`▵`,utri:`▵`,blacktriangleright:`▸`,rtrif:`▸`,rtri:`▹`,triangleright:`▹`,bigtriangledown:`▽`,xdtri:`▽`,blacktriangledown:`▾`,dtrif:`▾`,dtri:`▿`,triangledown:`▿`,blacktriangleleft:`◂`,ltrif:`◂`,ltri:`◃`,triangleleft:`◃`,loz:`◊`,lozenge:`◊`,cir:`○`,tridot:`◬`,bigcirc:`◯`,xcirc:`◯`,ultri:`◸`,urtri:`◹`,lltri:`◺`,emptysmallsquare:`◻`,filledsmallsquare:`◼`,bigstar:`★`,starf:`★`,star:`☆`,phone:`☎`,female:`♀`,male:`♂`,spades:`♠`,spadesuit:`♠`,clubs:`♣`,clubsuit:`♣`,hearts:`♥`,heartsuit:`♥`,diamondsuit:`♦`,diams:`♦`,sung:`♪`,check:`✓`,checkmark:`✓`,cross:`✗`,malt:`✠`,maltese:`✠`,sext:`✶`,verticalseparator:`❘`,bsolhsub:`⟈`,suphsol:`⟉`,longleftarrow:`⟵`,xlarr:`⟵`,longrightarrow:`⟶`,xrarr:`⟶`,longleftrightarrow:`⟷`,xharr:`⟷`,doublelongleftarrow:`⟸`,Longleftarrow:`⟸`,xlArr:`⟸`,doublelongrightarrow:`⟹`,Longrightarrow:`⟹`,xrArr:`⟹`,doublelongleftrightarrow:`⟺`,Longleftrightarrow:`⟺`,xhArr:`⟺`,longmapsto:`⟼`,xmap:`⟼`,dzigrarr:`⟿`,nvlarr:`⤂`,nvrarr:`⤃`,nvharr:`⤄`,Map:`⤅`,lbarr:`⤌`,bkarow:`⤍`,lBarr:`⤎`,dbkarow:`⤏`,rBarr:`⤏`,drbkarow:`⤐`,rbarr:`⤐`,RBarr:`⤐`,ddotrahd:`⤑`,uparrowbar:`⤒`,downarrowbar:`⤓`,Rarrtl:`⤖`,latail:`⤙`,ratail:`⤚`,lAtail:`⤛`,rAtail:`⤜`,larrfs:`⤝`,rarrfs:`⤞`,larrbfs:`⤟`,rarrbfs:`⤠`,nwarhk:`⤣`,nearhk:`⤤`,hksearow:`⤥`,searhk:`⤥`,hkswarow:`⤦`,swarhk:`⤦`,nwnear:`⤧`,nesear:`⤨`,toea:`⤨`,seswar:`⤩`,tosa:`⤩`,swnwar:`⤪`,rarrc:`⤳`,nrarrc:`⤳̸`,cudarrr:`⤵`,ldca:`⤶`,rdca:`⤷`,cudarrl:`⤸`,larrpl:`⤹`,curarrm:`⤼`,cularrp:`⤽`,rarrpl:`⥅`,harrcir:`⥈`,uarrocir:`⥉`,lurdshar:`⥊`,ldrushar:`⥋`,leftrightvector:`⥎`,rightupdownvector:`⥏`,downleftrightvector:`⥐`,leftupdownvector:`⥑`,leftvectorbar:`⥒`,rightvectorbar:`⥓`,rightupvectorbar:`⥔`,rightdownvectorbar:`⥕`,downleftvectorbar:`⥖`,downrightvectorbar:`⥗`,leftupvectorbar:`⥘`,leftdownvectorbar:`⥙`,leftteevector:`⥚`,rightteevector:`⥛`,rightupteevector:`⥜`,rightdownteevector:`⥝`,downleftteevector:`⥞`,downrightteevector:`⥟`,leftupteevector:`⥠`,leftdownteevector:`⥡`,lhar:`⥢`,uhar:`⥣`,rhar:`⥤`,dhar:`⥥`,luruhar:`⥦`,ldrdhar:`⥧`,ruluhar:`⥨`,rdldhar:`⥩`,lharul:`⥪`,llhard:`⥫`,rharul:`⥬`,lrhard:`⥭`,udhar:`⥮`,upequilibrium:`⥮`,duhar:`⥯`,reverseupequilibrium:`⥯`,roundimplies:`⥰`,erarr:`⥱`,simrarr:`⥲`,larrsim:`⥳`,rarrsim:`⥴`,rarrap:`⥵`,ltlarr:`⥶`,gtrarr:`⥸`,subrarr:`⥹`,suplarr:`⥻`,lfisht:`⥼`,rfisht:`⥽`,ufisht:`⥾`,dfisht:`⥿`,vzigzag:`⦚`,vangrt:`⦜`,angrtvbd:`⦝`,ange:`⦤`,range:`⦥`,dwangle:`⦦`,uwangle:`⦧`,angmsdaa:`⦨`,angmsdab:`⦩`,angmsdac:`⦪`,angmsdad:`⦫`,angmsdae:`⦬`,angmsdaf:`⦭`,angmsdag:`⦮`,angmsdah:`⦯`,bemptyv:`⦰`,demptyv:`⦱`,cemptyv:`⦲`,raemptyv:`⦳`,laemptyv:`⦴`,ohbar:`⦵`,omid:`⦶`,opar:`⦷`,operp:`⦹`,olcross:`⦻`,odsold:`⦼`,olcir:`⦾`,ofcir:`⦿`,olt:`⧀`,ogt:`⧁`,cirscir:`⧂`,cirE:`⧃`,solb:`⧄`,bsolb:`⧅`,boxbox:`⧉`,trisb:`⧍`,rtriltri:`⧎`,lefttrianglebar:`⧏`,notlefttrianglebar:`⧏̸`,righttrianglebar:`⧐`,notrighttrianglebar:`⧐̸`,iinfin:`⧜`,infintie:`⧝`,nvinfin:`⧞`,eparsl:`⧣`,smeparsl:`⧤`,eqvparsl:`⧥`,blacklozenge:`⧫`,lozf:`⧫`,ruledelayed:`⧴`,dsol:`⧶`,bigodot:`⨀`,xodot:`⨀`,bigoplus:`⨁`,xoplus:`⨁`,bigotimes:`⨂`,xotime:`⨂`,biguplus:`⨄`,xuplus:`⨄`,bigsqcup:`⨆`,xsqcup:`⨆`,fpartint:`⨍`,cirfnint:`⨐`,awint:`⨑`,rppolint:`⨒`,scpolint:`⨓`,npolint:`⨔`,pointint:`⨕`,quatint:`⨖`,intlarhk:`⨗`,pluscir:`⨢`,plusacir:`⨣`,simplus:`⨤`,plusdu:`⨥`,plussim:`⨦`,plustwo:`⨧`,mcomma:`⨩`,minusdu:`⨪`,loplus:`⨭`,roplus:`⨮`,Cross:`⨯`,timesd:`⨰`,timesbar:`⨱`,smashp:`⨳`,lotimes:`⨴`,rotimes:`⨵`,otimesas:`⨶`,Otimes:`⨷`,odiv:`⨸`,triplus:`⨹`,triminus:`⨺`,tritime:`⨻`,intprod:`⨼`,iprod:`⨼`,amalg:`⨿`,capdot:`⩀`,ncup:`⩂`,ncap:`⩃`,capand:`⩄`,cupor:`⩅`,cupcap:`⩆`,capcup:`⩇`,cupbrcap:`⩈`,capbrcup:`⩉`,cupcup:`⩊`,capcap:`⩋`,ccups:`⩌`,ccaps:`⩍`,ccupssm:`⩐`,And:`⩓`,Or:`⩔`,andand:`⩕`,oror:`⩖`,orslope:`⩗`,andslope:`⩘`,andv:`⩚`,orv:`⩛`,andd:`⩜`,ord:`⩝`,wedbar:`⩟`,sdote:`⩦`,simdot:`⩪`,congdot:`⩭`,ncongdot:`⩭̸`,easter:`⩮`,apacir:`⩯`,apE:`⩰`,nape:`⩰̸`,eplus:`⩱`,pluse:`⩲`,Esim:`⩳`,ddotseq:`⩷`,eddot:`⩷`,equivdd:`⩸`,ltcir:`⩹`,gtcir:`⩺`,ltquest:`⩻`,gtquest:`⩼`,leqslant:`⩽`,les:`⩽`,lessslantequal:`⩽`,nleqslant:`⩽̸`,nles:`⩽̸`,notlessslantequal:`⩽̸`,geqslant:`⩾`,ges:`⩾`,greaterslantequal:`⩾`,ngeqslant:`⩾̸`,nges:`⩾̸`,notgreaterslantequal:`⩾̸`,lesdot:`⩿`,gesdot:`⪀`,lesdoto:`⪁`,gesdoto:`⪂`,lesdotor:`⪃`,gesdotol:`⪄`,lap:`⪅`,lessapprox:`⪅`,gap:`⪆`,gtrapprox:`⪆`,lne:`⪇`,lneq:`⪇`,gne:`⪈`,gneq:`⪈`,lnap:`⪉`,lnapprox:`⪉`,gnap:`⪊`,gnapprox:`⪊`,lEg:`⪋`,lesseqqgtr:`⪋`,gEl:`⪌`,gtreqqless:`⪌`,lsime:`⪍`,gsime:`⪎`,lsimg:`⪏`,gsiml:`⪐`,lge:`⪑`,gle:`⪒`,lesges:`⪓`,gesles:`⪔`,els:`⪕`,eqslantless:`⪕`,egs:`⪖`,eqslantgtr:`⪖`,elsdot:`⪗`,egsdot:`⪘`,el:`⪙`,eg:`⪚`,siml:`⪝`,simg:`⪞`,simle:`⪟`,simge:`⪠`,lessless:`⪡`,notnestedlessless:`⪡̸`,greatergreater:`⪢`,notnestedgreatergreater:`⪢̸`,glj:`⪤`,gla:`⪥`,ltcc:`⪦`,gtcc:`⪧`,lescc:`⪨`,gescc:`⪩`,smt:`⪪`,lat:`⪫`,smte:`⪬`,smtes:`⪬︀`,late:`⪭`,lates:`⪭︀`,bumpE:`⪮`,pre:`⪯`,precedesequal:`⪯`,preceq:`⪯`,notprecedesequal:`⪯̸`,npre:`⪯̸`,npreceq:`⪯̸`,sce:`⪰`,succeedsequal:`⪰`,succeq:`⪰`,notsucceedsequal:`⪰̸`,nsce:`⪰̸`,nsucceq:`⪰̸`,prE:`⪳`,scE:`⪴`,precneqq:`⪵`,prne:`⪵`,scne:`⪶`,succneqq:`⪶`,prap:`⪷`,precapprox:`⪷`,scap:`⪸`,succapprox:`⪸`,precnapprox:`⪹`,prnap:`⪹`,scnap:`⪺`,succnapprox:`⪺`,Pr:`⪻`,Sc:`⪼`,subdot:`⪽`,supdot:`⪾`,subplus:`⪿`,supplus:`⫀`,submult:`⫁`,supmult:`⫂`,subedot:`⫃`,supedot:`⫄`,subE:`⫅`,subseteqq:`⫅`,nsubE:`⫅̸`,nsubseteqq:`⫅̸`,supE:`⫆`,supseteqq:`⫆`,nsupE:`⫆̸`,nsupseteqq:`⫆̸`,subsim:`⫇`,supsim:`⫈`,subnE:`⫋`,subsetneqq:`⫋`,varsubsetneqq:`⫋︀`,vsubnE:`⫋︀`,supnE:`⫌`,supsetneqq:`⫌`,varsupsetneqq:`⫌︀`,vsupnE:`⫌︀`,csub:`⫏`,csup:`⫐`,csube:`⫑`,csupe:`⫒`,subsup:`⫓`,supsub:`⫔`,subsub:`⫕`,supsup:`⫖`,suphsub:`⫗`,supdsub:`⫘`,forkv:`⫙`,topfork:`⫚`,mlcp:`⫛`,Dashv:`⫤`,doublelefttee:`⫤`,vdashl:`⫦`,barv:`⫧`,vbar:`⫨`,vbarv:`⫩`,Vbar:`⫫`,Not:`⫬`,bNot:`⫭`,rnmid:`⫮`,cirmid:`⫯`,midcir:`⫰`,topcir:`⫱`,nhpar:`⫲`,parsim:`⫳`,parsl:`⫽`,nparsl:`⫽⃥`,flat:`♭`,natur:`♮`,natural:`♮`,sharp:`♯`,curren:`¤`,cent:`¢`,dollar:`$`,pound:`£`,yen:`¥`,euro:`€`,sup1:`¹`,frac12:`½`,half:`½`,frac13:`⅓`,frac14:`¼`,frac15:`⅕`,frac16:`⅙`,frac18:`⅛`,sup2:`²`,frac23:`⅔`,frac25:`⅖`,sup3:`³`,frac34:`¾`,frac35:`⅗`,frac38:`⅜`,frac45:`⅘`,frac56:`⅚`,frac58:`⅝`,frac78:`⅞`,afr:`𝔞`,aopf:`𝕒`,ascr:`𝒶`,Afr:`𝔄`,Aopf:`𝔸`,Ascr:`𝒜`,ordf:`ª`,aacute:`á`,Aacute:`Á`,agrave:`à`,Agrave:`À`,abreve:`ă`,Abreve:`Ă`,acirc:`â`,Acirc:`Â`,aring:`å`,angst:`Å`,Aring:`Å`,auml:`ä`,Auml:`Ä`,atilde:`ã`,Atilde:`Ã`,aogon:`ą`,Aogon:`Ą`,amacr:`ā`,Amacr:`Ā`,aelig:`Æ`,AElig:`Æ`,bfr:`𝔟`,bopf:`𝕓`,bscr:`𝒷`,bernou:`ℬ`,bernoullis:`ℬ`,Bfr:`𝔅`,Bopf:`𝔹`,Bscr:`ℬ`,cfr:`𝔠`,copf:`𝕔`,cscr:`𝒸`,cayleys:`ℭ`,Cfr:`ℭ`,complexes:`ℂ`,Copf:`ℂ`,Cscr:`𝒞`,cacute:`ć`,Cacute:`Ć`,ccirc:`ĉ`,Ccirc:`Ĉ`,ccaron:`č`,Ccaron:`Č`,cdot:`ċ`,Cdot:`Ċ`,ccedil:`ç`,Ccedil:`Ç`,incare:`℅`,dfr:`𝔡`,differentiald:`ⅆ`,dopf:`𝕕`,dscr:`𝒹`,capitaldifferentiald:`ⅅ`,dd:`ⅅ`,DD:`ⅅ`,Dfr:`𝔇`,Dopf:`𝔻`,Dscr:`𝒟`,dcaron:`ď`,Dcaron:`Ď`,dstrok:`đ`,Dstrok:`Đ`,eth:`ð`,ETH:`Ð`,ee:`ⅇ`,efr:`𝔢`,eopf:`𝕖`,escr:`ℯ`,exponentiale:`ⅇ`,Efr:`𝔈`,Eopf:`𝔼`,Escr:`ℰ`,expectation:`ℰ`,eacute:`é`,Eacute:`É`,egrave:`è`,Egrave:`È`,ecirc:`ê`,Ecirc:`Ê`,ecaron:`ě`,Ecaron:`Ě`,euml:`ë`,Euml:`Ë`,edot:`ė`,Edot:`Ė`,eogon:`ę`,Eogon:`Ę`,emacr:`ē`,Emacr:`Ē`,ffr:`𝔣`,fopf:`𝕗`,fscr:`𝒻`,Ffr:`𝔉`,Fopf:`𝔽`,fouriertrf:`ℱ`,Fscr:`ℱ`,fflig:`ff`,ffilig:`ffi`,ffllig:`ffl`,filig:`fi`,fjlig:`fj`,fllig:`fl`,fnof:`ƒ`,gfr:`𝔤`,gopf:`𝕘`,gscr:`ℊ`,Gfr:`𝔊`,Gopf:`𝔾`,Gscr:`𝒢`,gacute:`ǵ`,gbreve:`ğ`,Gbreve:`Ğ`,gcirc:`ĝ`,Gcirc:`Ĝ`,gdot:`ġ`,Gdot:`Ġ`,gcedil:`Ģ`,hfr:`𝔥`,hopf:`𝕙`,hscr:`𝒽`,planckh:`ℎ`,hamilt:`ℋ`,Hfr:`ℌ`,hilbertspace:`ℋ`,Hopf:`ℍ`,Hscr:`ℋ`,poincareplane:`ℌ`,quaternions:`ℍ`,hcirc:`ĥ`,Hcirc:`Ĥ`,hbar:`ℏ`,hslash:`ℏ`,hstrok:`ħ`,planck:`ℏ`,plankv:`ℏ`,Hstrok:`Ħ`,ifr:`𝔦`,ii:`ⅈ`,imaginaryi:`ⅈ`,iopf:`𝕚`,iscr:`𝒾`,Ifr:`ℑ`,im:`ℑ`,image:`ℑ`,imagline:`ℐ`,imagpart:`ℑ`,Iopf:`𝕀`,Iscr:`ℐ`,iacute:`í`,Iacute:`Í`,igrave:`ì`,Igrave:`Ì`,icirc:`î`,Icirc:`Î`,iuml:`ï`,Iuml:`Ï`,itilde:`ĩ`,Itilde:`Ĩ`,idot:`İ`,iogon:`į`,Iogon:`Į`,imacr:`ī`,Imacr:`Ī`,ijlig:`IJ`,IJlig:`IJ`,imath:`ı`,inodot:`ı`,jfr:`𝔧`,jopf:`𝕛`,jscr:`𝒿`,Jfr:`𝔍`,Jopf:`𝕁`,Jscr:`𝒥`,jcirc:`ĵ`,Jcirc:`Ĵ`,jmath:`ȷ`,kfr:`𝔨`,kopf:`𝕜`,kscr:`𝓀`,Kfr:`𝔎`,Kopf:`𝕂`,Kscr:`𝒦`,kcedil:`ķ`,Kcedil:`Ķ`,ell:`ℓ`,lfr:`𝔩`,lopf:`𝕝`,lscr:`𝓁`,lagran:`ℒ`,laplacetrf:`ℒ`,Lfr:`𝔏`,Lopf:`𝕃`,Lscr:`ℒ`,lacute:`ĺ`,Lacute:`Ĺ`,lcaron:`ľ`,Lcaron:`Ľ`,lcedil:`ļ`,Lcedil:`Ļ`,lstrok:`ł`,Lstrok:`Ł`,lmidot:`ŀ`,Lmidot:`Ŀ`,mfr:`𝔪`,mopf:`𝕞`,mscr:`𝓂`,mellintrf:`ℳ`,Mfr:`𝔐`,Mopf:`𝕄`,Mscr:`ℳ`,phmmat:`ℳ`,nfr:`𝔫`,nopf:`𝕟`,nscr:`𝓃`,naturals:`ℕ`,Nfr:`𝔑`,Nopf:`ℕ`,Nscr:`𝒩`,nacute:`ń`,Nacute:`Ń`,ncaron:`ň`,Ncaron:`Ň`,ntilde:`ñ`,Ntilde:`Ñ`,ncedil:`ņ`,Ncedil:`Ņ`,numero:`№`,eng:`ŋ`,ENG:`Ŋ`,ofr:`𝔬`,oopf:`𝕠`,order:`ℴ`,orderof:`ℴ`,oscr:`ℴ`,Ofr:`𝔒`,Oopf:`𝕆`,Oscr:`𝒪`,ordm:`º`,oacute:`ó`,Oacute:`Ó`,ograve:`ò`,Ograve:`Ò`,ocirc:`ô`,Ocirc:`Ô`,ouml:`ö`,Ouml:`Ö`,odblac:`ő`,Odblac:`Ő`,otilde:`õ`,Otilde:`Õ`,oslash:`ø`,Oslash:`Ø`,omacr:`ō`,Omacr:`Ō`,oelig:`Œ`,OElig:`Œ`,pfr:`𝔭`,popf:`𝕡`,pscr:`𝓅`,Pfr:`𝔓`,Popf:`ℙ`,primes:`ℙ`,Pscr:`𝒫`,qfr:`𝔮`,qopf:`𝕢`,qscr:`𝓆`,Qfr:`𝔔`,Qopf:`ℚ`,Qscr:`𝒬`,rationals:`ℚ`,kgreen:`ĸ`,rfr:`𝔯`,ropf:`𝕣`,rscr:`𝓇`,re:`ℜ`,real:`ℜ`,realine:`ℛ`,realpart:`ℜ`,reals:`ℝ`,Rfr:`ℜ`,Ropf:`ℝ`,Rscr:`ℛ`,racute:`ŕ`,Racute:`Ŕ`,rcaron:`ř`,Rcaron:`Ř`,rcedil:`ŗ`,Rcedil:`Ŗ`,sfr:`𝔰`,sopf:`𝕤`,sscr:`𝓈`,Sfr:`𝔖`,Sopf:`𝕊`,Sscr:`𝒮`,circleds:`Ⓢ`,os:`Ⓢ`,sacute:`ś`,Sacute:`Ś`,scirc:`ŝ`,Scirc:`Ŝ`,scaron:`š`,Scaron:`Š`,scedil:`ş`,Scedil:`Ş`,szlig:`ß`,tfr:`𝔱`,topf:`𝕥`,tscr:`𝓉`,Tfr:`𝔗`,Topf:`𝕋`,Tscr:`𝒯`,tcaron:`ť`,Tcaron:`Ť`,tcedil:`ţ`,Tcedil:`Ţ`,trade:`™`,tstrok:`ŧ`,Tstrok:`Ŧ`,ufr:`𝔲`,uopf:`𝕦`,uscr:`𝓊`,Ufr:`𝔘`,Uopf:`𝕌`,Uscr:`𝒰`,uacute:`ú`,Uacute:`Ú`,ugrave:`ù`,Ugrave:`Ù`,ubreve:`ŭ`,Ubreve:`Ŭ`,ucirc:`û`,Ucirc:`Û`,uring:`ů`,Uring:`Ů`,uuml:`ü`,Uuml:`Ü`,udblac:`ű`,Udblac:`Ű`,utilde:`ũ`,Utilde:`Ũ`,uogon:`ų`,Uogon:`Ų`,umacr:`ū`,Umacr:`Ū`,vfr:`𝔳`,vopf:`𝕧`,vscr:`𝓋`,Vfr:`𝔙`,Vopf:`𝕍`,Vscr:`𝒱`,wfr:`𝔴`,wopf:`𝕨`,wscr:`𝓌`,Wfr:`𝔚`,Wopf:`𝕎`,Wscr:`𝒲`,wcirc:`ŵ`,Wcirc:`Ŵ`,xfr:`𝔵`,xopf:`𝕩`,xscr:`𝓍`,Xfr:`𝔛`,Xopf:`𝕏`,Xscr:`𝒳`,yfr:`𝔶`,yopf:`𝕪`,yscr:`𝓎`,Yfr:`𝔜`,Yopf:`𝕐`,Yscr:`𝒴`,yacute:`ý`,Yacute:`Ý`,ycirc:`ŷ`,Ycirc:`Ŷ`,yuml:`ÿ`,Yuml:`Ÿ`,zfr:`𝔷`,zopf:`𝕫`,zscr:`𝓏`,integers:`ℤ`,zeetrf:`ℨ`,Zfr:`ℨ`,Zopf:`ℤ`,Zscr:`𝒵`,zacute:`ź`,Zacute:`Ź`,zcaron:`ž`,Zcaron:`Ž`,zdot:`ż`,Zdot:`Ż`,imped:`Ƶ`,thorn:`þ`,THORN:`Þ`,napos:`ʼn`,alpha:`α`,Alpha:`Α`,beta:`β`,Beta:`Β`,gamma:`γ`,Gamma:`Γ`,delta:`δ`,Delta:`Δ`,epsi:`ε`,epsilon:`ε`,epsiv:`ϵ`,straightepsilon:`ϵ`,varepsilon:`ϵ`,Epsilon:`Ε`,digamma:`ϝ`,gammad:`ϝ`,Gammad:`Ϝ`,zeta:`ζ`,Zeta:`Ζ`,eta:`η`,Eta:`Η`,theta:`θ`,thetasym:`ϑ`,thetav:`ϑ`,vartheta:`ϑ`,Theta:`Θ`,iota:`ι`,Iota:`Ι`,kappa:`κ`,kappav:`ϰ`,varkappa:`ϰ`,Kappa:`Κ`,lambda:`λ`,Lambda:`Λ`,mu:`μ`,micro:`µ`,Mu:`Μ`,nu:`ν`,Nu:`Ν`,xi:`ξ`,Xi:`Ξ`,omicron:`ο`,Omicron:`Ο`,pi:`π`,piv:`ϖ`,varpi:`ϖ`,Pi:`Π`,rho:`ρ`,rhov:`ϱ`,varrho:`ϱ`,Rho:`Ρ`,sigma:`σ`,Sigma:`Σ`,sigmaf:`ς`,sigmav:`ς`,varsigma:`ς`,tau:`τ`,Tau:`Τ`,upsi:`υ`,upsilon:`υ`,Upsilon:`Υ`,Upsi:`ϒ`,upsih:`ϒ`,phi:`φ`,phiv:`ϕ`,straightphi:`ϕ`,varphi:`ϕ`,Phi:`Φ`,chi:`χ`,Chi:`Χ`,psi:`ψ`,Psi:`Ψ`,omega:`ω`,ohm:`Ω`,Omega:`Ω`,acy:`а`,Acy:`А`,bcy:`б`,Bcy:`Б`,vcy:`в`,Vcy:`В`,gcy:`г`,Gcy:`Г`,gjcy:`Ѓ`,GJcy:`Ѓ`,dcy:`д`,Dcy:`Д`,djcy:`Ђ`,DJcy:`Ђ`,iecy:`Е`,IEcy:`Е`,iocy:`Ё`,IOcy:`Ё`,jukcy:`є`,Jukcy:`Є`,zhcy:`Ж`,ZHcy:`Ж`,zcy:`з`,Zcy:`З`,dscy:`Ѕ`,DScy:`Ѕ`,icy:`и`,Icy:`И`,iukcy:`і`,Iukcy:`І`,yicy:`Ї`,YIcy:`Ї`,jcy:`й`,Jcy:`Й`,jsercy:`ј`,Jsercy:`Ј`,kcy:`к`,Kcy:`К`,kjcy:`Ќ`,KJcy:`Ќ`,lcy:`л`,Lcy:`Л`,ljcy:`Љ`,LJcy:`Љ`,mcy:`м`,Mcy:`М`,ncy:`н`,Ncy:`Н`,njcy:`Њ`,NJcy:`Њ`,ocy:`о`,Ocy:`О`,pcy:`п`,Pcy:`П`,rcy:`р`,Rcy:`Р`,scy:`с`,Scy:`С`,tcy:`т`,Tcy:`Т`,tshcy:`ћ`,TSHcy:`Ћ`,ucy:`у`,Ucy:`У`,ubrcy:`ў`,Ubrcy:`Ў`,fcy:`ф`,Fcy:`Ф`,khcy:`Х`,KHcy:`Х`,tscy:`Ц`,TScy:`Ц`,chcy:`Ч`,CHcy:`Ч`,dzcy:`Џ`,DZcy:`Џ`,shcy:`Ш`,SHcy:`Ш`,shchcy:`щ`,SHCHcy:`Щ`,hardcy:`ъ`,HARDcy:`Ъ`,ycy:`ы`,Ycy:`Ы`,softcy:`ь`,SOFTcy:`Ь`,ecy:`э`,Ecy:`Э`,yucy:`Ю`,YUcy:`Ю`,yacy:`Я`,YAcy:`Я`,alefsym:`ℵ`,aleph:`ℵ`,beth:`ℶ`,gimel:`ℷ`,daleth:`ℸ`};function yy(e){return vy[e]||vy[e.toLowerCase()]}var K={blockQuote:0,breakLine:1,breakThematic:2,codeBlock:3,codeInline:4,footnote:5,footnoteReference:6,frontmatter:7,gfmTask:8,heading:9,htmlBlock:10,htmlComment:11,htmlSelfClosing:12,image:13,link:14,orderedList:15,paragraph:16,ref:17,refCollection:18,table:19,text:20,textFormatted:21,unorderedList:22},q=32,J=9,by=13,Y=10,xy=96,Sy=126,Cy=91,wy=94,Ty=62,Ey=35,Dy=37,Oy=45,ky=61,Ay=92,jy=42,My=95,Ny=60,Py=64,Fy=93,Iy=33,Ly=38,Ry=58,zy=70,By=102,Vy=104,Hy=119,Uy=116,Wy=112,Gy=115,Ky=160,qy=12,Jy=44,Yy=59,Xy=63,Zy=46,Qy=47,$y=39,eb=34,tb=43,nb=124,rb=123,ib=125,ab=40,ob=41,sb=120,cb=88,lb=30,ub=48,db=57,fb=65,pb=90,mb=97,hb=122,gb=128,_b=32;function vb(e){if(!Ob(e,`---`))return null;let t=3;for(;t<e.length&&(e[t]===` `||e[t]===` `);)t++;if(t<e.length&&e[t]===`\r`&&t++,t>=e.length||e[t]!==`
1577
+ `)return null;t++;let n=!1;for(;t<e.length;){let r=t;for(;t<e.length&&e[t]!==`
1578
+ `&&e[t]!==`\r`;)t++;if(t>=e.length)break;let i=t;if(e[t]===`\r`&&t++,t<e.length&&e[t]===`
1579
+ `&&t++,Ob(e,`---`,r))return{endPos:t,hasValidYaml:n};if(!n){let t=Ub(e,r,i);if(t<i){let r=e.charCodeAt(t);if(r>=mb&&r<=hb||r>=fb&&r<=pb||r>=ub&&r<=db||r===My){for(t++;t<i&&(r=e.charCodeAt(t),r>=mb&&r<=hb||r>=fb&&r<=pb||r>=ub&&r<=db||r===My||r===Oy||r===Zy);)t++;t<i&&e.charCodeAt(t)===Ry&&(t++,t>=i?n=!0:(r=e.charCodeAt(t),(r===q||r===J)&&(n=!0)))}}}}return null}var yb=/&([a-zA-Z0-9]+|#[0-9]{1,7}|#x[0-9a-fA-F]{1,6});/gi,bb=/(\n|^[-*]\s|^#|^ {2,}|^-{2,}|^>\s|^<(div|p|h[1-6]|ul|ol|li|blockquote|pre|table|thead|tbody|tr|td|th|dl|dt|dd|hr|address|article|aside|details|dialog|figure|figcaption|footer|form|header|main|menu|nav|section|summary|textarea|fieldset|legend|center|dir|hgroup|marquee|search|output|template)\b)/i;function xb(e){return e.indexOf(`&`)===-1?e:e.replace(yb,(e,t)=>{var n=yy(t);if(n)return n;if(t[0]===`#`){var r=t[1]===`x`||t[1]===`X`?parseInt(t.slice(2),16):parseInt(t.slice(1),10);return r===0||r>=55296&&r<=57343||r>1114111?`�`:r<=65535?String.fromCharCode(r):String.fromCharCode(55296+(r-65536>>10),56320+(r-65536&1023))}return e})}var Sb=/(javascript|vbscript|data(?!:image)):/i;function Cb(e){if(Sb.test(e))return null;if(e.indexOf(`%`)===-1)return e;try{let t=decodeURIComponent(e).replace(/[^A-Za-z0-9/:]/g,``);if(Sb.test(t))return null}catch{return null}return e}var wb={},Tb,Eb;for(Tb=[192,193,194,195,196,197,224,225,226,227,228,229,230,198],Eb=0;Eb<Tb.length;Eb++)wb[Tb[Eb]]=`a`;for(wb[231]=wb[199]=`c`,wb[240]=wb[208]=`d`,Tb=[200,201,202,203,233,232,234,235],Eb=0;Eb<Tb.length;Eb++)wb[Tb[Eb]]=`e`;for(Tb=[207,239,206,238,205,237,204,236],Eb=0;Eb<Tb.length;Eb++)wb[Tb[Eb]]=`i`;for(wb[209]=wb[241]=`n`,Tb=[248,216,339,338,213,245,212,244,211,243,210,242],Eb=0;Eb<Tb.length;Eb++)wb[Tb[Eb]]=`o`;for(Tb=[220,252,219,251,218,250,217,249],Eb=0;Eb<Tb.length;Eb++)wb[Tb[Eb]]=`u`;wb[376]=wb[255]=wb[221]=wb[253]=`y`;function Db(e){for(var t=``,n=-1,r=e.length,i=0;i<r;i++){var a=e.charCodeAt(i);if(a>=mb&&a<=hb||a>=ub&&a<=db){n<0&&(n=i);continue}if(a>=fb&&a<=pb){n>=0&&(t+=e.slice(n,i),n=-1),t+=String.fromCharCode(a+_b);continue}if(a===q||a===Oy){n>=0&&(t+=e.slice(n,i),n=-1),t+=`-`;continue}n>=0&&(t+=e.slice(n,i),n=-1);var o=wb[a];o&&(t+=o)}return n>=0&&(t+=e.slice(n)),t}function Ob(e,t,n){return e.startsWith(t,n)}var kb=new Set([`area`,`base`,`br`,`col`,`embed`,`hr`,`img`,`input`,`link`,`meta`,`param`,`source`,`track`,`wbr`,`circle`,`ellipse`,`line`,`path`,`polygon`,`polyline`,`rect`,`use`,`stop`,`animate`,`set`]);function Ab(e){let t=e.toLowerCase();if(kb.has(t))return!0;let n=t.indexOf(`:`);return n===-1?!1:(t=t.slice(n+1),kb.has(t))}var jb=1,Mb=2,Nb=4,Pb=8,Fb=16,Ib=32,Lb=64,Rb=(function(){var e=new Uint8Array(128),t;for(e[J]=jb,e[Y]=jb|Mb,e[qy]=jb,e[by]=jb|Mb,e[q]=jb,t=Iy;t<=Qy;t++)e[t]=Nb;for(t=Ry;t<=Py;t++)e[t]=Nb;for(t=Cy;t<=xy;t++)e[t]=Nb;for(t=rb;t<=Sy;t++)e[t]=Nb;for(t=ub;t<=db;t++)e[t]=Fb;for(t=fb;t<=pb;t++)e[t]=Pb;for(t=mb;t<=hb;t++)e[t]=Pb;return e})(),zb=/[\p{P}\p{S}]/u,Bb=/\p{Zs}/u,Vb=[];function Hb(e){var t=e.indexOf(`\r`),n=e.indexOf(`\0`);if(t===-1&&n===-1)return e;var r=e.length;Vb.length=0;var i=0,a=0;for(a=t===-1?n:n===-1||t<n?t:n;a<r;a++){var o=e.charCodeAt(a);o===by?(i<a&&Vb.push(e.slice(i,a)),a+1<r&&e.charCodeAt(a+1)===Y&&a++,Vb.push(`
1580
+ `),i=a+1):o===0&&(i<a&&Vb.push(e.slice(i,a)),Vb.push(`�`),i=a+1)}return i<r&&Vb.push(e.slice(i)),Vb.join(``)}function Ub(e,t,n){let r=n??e.length;for(;t<r&&(e[t]===` `||e[t]===` `);)t++;return t}function Wb(e){if(!e)return!1;for(var t in e)return!0;return!1}function Gb(e){return{attrs:{},children:[{type:K.text,text:e}],d:!0,type:K.htmlBlock,tag:`header`}}var Kb=/^\n+/;function qb(e){for(var t=e.length;t>0&&(e[t-1]===`
1581
+ `||e[t-1]===`\r`);)t--;return e.slice(0,t).replace(Kb,``)+`
1582
+
1583
+ `}function Jb(e){if((e.type===K.htmlSelfClosing||e.type===K.htmlBlock)&&e.b)return[];if(e.type===K.paragraph){var t=e.children;return t?t.flatMap(Jb):[]}return e.type===K.text?e.text?.trim()?[e]:[]:e.type===K.htmlBlock&&e.children?[{...e,children:e.children?.flatMap(Jb)}]:[e]}function Yb(e,t){return RegExp(`^<${t}(\\s|>)`,`i`).test(e)&&e.toLowerCase().trimEnd().endsWith(`</`+t.toLowerCase()+`>`)}function Xb(e){for(var t=0;t<e.length;t++){if(e[t].type===K.htmlBlock){var n=e[t],r=!1;if(n.d&&n.a&&t===e.length-1){var i=`</`+String(n.tag).toLowerCase()+`>`,a=n.a.toLowerCase().indexOf(i);a!==-1&&n.a.slice(a+i.length).replace(/<\/[a-z][a-z0-9-]*\s*>/gi,``).trim()&&(r=!0)}r||(n.d=!1)}`children`in e[t]&&e[t].children&&Xb(e[t].children)}}function Zb(e,t){for(var n=0;n<e.length;n++){var r=e[n];if(r.type===K.paragraph&&r.children)for(var i=r.children,a=0;a<i.length;a++){var o=i[a];if(o.type===K.htmlSelfClosing&&o.b&&o.tag.toLowerCase()===t){var s=e.slice(0,n);a>0&&s.push({type:K.paragraph,children:i.slice(0,a)});var c=[];if(a+1<i.length){var l=i.slice(a+1).filter(function(e){return!(e.type===K.htmlSelfClosing&&e.b)});l.length>0&&(c=l)}return c=c.concat(e.slice(n+1)),{found:!0,beforeClose:s,afterClose:c}}}if((r.type===K.htmlSelfClosing||r.type===K.htmlBlock)&&r.b&&r.tag.toLowerCase()===t)return{found:!0,beforeClose:e.slice(0,n),afterClose:e.slice(n+1)}}return{found:!1,beforeClose:e,afterClose:[]}}function Qb(e,t,n){var r=e.replace(RegExp(`\\s*</`+t+`>\\s*$`,`i`),``);return n?sx(r):r}function $b(e){var t=``;for(var n in e){var r=e[n];r===!0?t+=` `+n:r!=null&&r!==!1&&(t+=` `+n+`="`+String(r)+`"`)}return t}function ex(e){var t=[];if(!e)return t;for(var n in e)n.charCodeAt(0)===94&&t.push({identifier:n,footnote:e[n].target});return t}function tx(e,t,n){if(t.indexOf(`.`)===-1)return e?.[t]||n;for(var r=e,i=t.split(`.`),a=0;a<i.length&&(r=r?.[i[a]],r!==void 0);)a++;return r||n}function nx(e){for(var t=!1,n=0;n<e.length;n++){var r=e.charCodeAt(n);if(r<=q||r===eb||r===Dy||r===Ny||r===Ty||r===Cy||r===Ay||r===Fy||r===wy||r===xy||r>=123){t=!0;break}}if(!t)return e;for(var i=``,n=0;n<e.length;n++){var r=e.charCodeAt(n);if(r===Dy&&n+2<e.length){var a=e.charCodeAt(n+1),o=e.charCodeAt(n+2);if((a>=ub&&a<=db||a>=fb&&a<=zy||a>=mb&&a<=By)&&(o>=ub&&o<=db||o>=fb&&o<=zy||o>=mb&&o<=By)){i+=e[n]+e[n+1]+e[n+2],n+=2;continue}}i+=encodeURI(e[n])}return i}function rx(...e){return e.filter(Boolean).join(` `)}var ix=new Set([`title`,`textarea`,`style`,`xmp`,`iframe`,`noembed`,`noframes`,`script`,`plaintext`]),ax=/<(\/?)(title|textarea|style|xmp|iframe|noembed|noframes|script|plaintext)(\s|>|\/)/gi;function ox(e){return ix.has(e.toLowerCase())}function sx(e){return ax.lastIndex=0,e.replace(ax,function(e,t,n,r){return`&lt;`+t+n+r})}var cx=/^<([a-zA-Z][a-zA-Z0-9-]*)\s[^>]*>/,lx=/^<[A-Z]/,ux=[`script`,`pre`,`style`,`textarea`],dx=new Set(ux),fx=/<(?:pre|script|style|textarea)\b/iy,px=/^(\s{0,3}#[#\s]|\s{0,3}[-*+]\s|\s{0,3}\d+\.\s|\s{0,3}>\s|\s{0,3}```)/m,mx=/^<([a-z][^ >/\n\r]*) ?([^>]*?)>/im,hx=new Uint8Array(128);(function(){for(var e=[xy,jy,My,Sy,ky,Cy,Iy,Ny,Ay,Ly,Y,Vy,Hy,By],t=0;t<e.length;t++)hx[e[t]]=1})();var gx=/([a-zA-Z_][a-zA-Z0-9_-]*)=(?:"([^"]*)"|'([^']*)')/g;function _x(e){return dx.has(e)}function vx(e,t,n){for(var r=t,i=n;r<i&&(e.charCodeAt(r)===q||e.charCodeAt(r)===J);)r++;if(r>=i)return!1;e.charCodeAt(r)===nb&&r++;for(var a=0;r<i;){for(;r<i&&(e.charCodeAt(r)===q||e.charCodeAt(r)===J);)r++;if(r>=i)break;if(e.charCodeAt(r)===nb&&a>0){for(var o=r+1;o<i&&(e.charCodeAt(o)===q||e.charCodeAt(o)===J);)o++;if(o>=i)return!0}if(e.charCodeAt(r)===Ry&&r++,r>=i||e.charCodeAt(r)!==Oy)return!1;for(;r<i&&e.charCodeAt(r)===Oy;)r++;for(r<i&&e.charCodeAt(r)===Ry&&r++,a++;r<i&&(e.charCodeAt(r)===q||e.charCodeAt(r)===J);)r++;if(r<i)if(e.charCodeAt(r)===nb)r++;else return!1}return a>0}function yx(e,t){if(e.charCodeAt(t)!==Ny)return null;let n=t+1,r=e.length,i=!1;e.charCodeAt(n)===Qy&&(n++,i=!0);let a=n,o=e.charCodeAt(n);if(!(o>=mb&&o<=hb||o>=fb&&o<=pb))return null;for(;n<r&&(e.charCodeAt(n)>=mb&&e.charCodeAt(n)<=hb||e.charCodeAt(n)>=fb&&e.charCodeAt(n)<=pb||e.charCodeAt(n)>=ub&&e.charCodeAt(n)<=db||e.charCodeAt(n)===Oy);)n++;let s=e.slice(a,n);if(!s)return null;let c=n;for(;n<r&&(e.charCodeAt(n)===q||e.charCodeAt(n)===J||e.charCodeAt(n)===Y);)n++;let l=e.slice(c,n);if(n===c&&n<r){var u=e.charCodeAt(n);if(u!==Ty&&u!==Qy)return null}let d=n,f={},p=!1;for(;n<r;){let t=e.charCodeAt(n);if(t===Ty){let t=e.slice(d,n);return{tag:s,attrs:f,selfClosing:!1,end:n+1,rawAttrs:t,whitespaceBeforeAttrs:l,isClosing:i,hasSpaceBeforeSlash:p}}if(t===q||t===J||t===Y){n++;continue}if(t===Qy&&n+1<r&&e.charCodeAt(n+1)===Ty){let t=e.slice(d,n);return p=n>d&&e.charCodeAt(n-1)===q,{tag:s,attrs:f,selfClosing:!0,end:n+2,rawAttrs:t,whitespaceBeforeAttrs:l,isClosing:i,hasSpaceBeforeSlash:p}}var m=n,h=e.charCodeAt(n);if(!(h>=mb&&h<=hb||h>=fb&&h<=pb||h===My||h===Ry))return null;for(n++;n<r;){var g=e.charCodeAt(n);if(g>=mb&&g<=hb||g>=fb&&g<=pb||g>=ub&&g<=db||g===My||g===Zy||g===Ry||g===Oy)n++;else break}for(var _=e.slice(m,n);n<r&&(e.charCodeAt(n)===q||e.charCodeAt(n)===J);)n++;if(e.charCodeAt(n)!==ky){f[_]=``;continue}for(n++;n<r&&(e.charCodeAt(n)===q||e.charCodeAt(n)===J);)n++;var v=e.charCodeAt(n);if(v===eb||v===$y){n++;for(var y=n;n<r&&e.charCodeAt(n)!==v;)n++;if(n>=r)return null;if(f[_]=e.slice(y,n),n++,n<r){var b=e.charCodeAt(n);if(b!==q&&b!==J&&b!==Y&&b!==Ty&&b!==Qy)return null}}else if(v===rb){var x=1,y=n;for(n++;n<r&&x>0;){var g=e.charCodeAt(n);g===rb?x++:g===ib&&x--,n++}f[_]=e.slice(y,n)}else{for(var y=n;n<r;){var S=e.charCodeAt(n);if(S===q||S===J||S===Ty||S===Y||S===eb||S===$y||S===ky||S===Ny||S===xy)break;n++}if(n===y)return null;f[_]=e.slice(y,n)}}return null}function bx(e,t,n){if(!n.optimizeForStreaming&&e.indexOf(`[`)===-1)return!1;for(var r=0,i=e.length,a=!1,o=!1;r<i;){for(var s=e.indexOf(`
1584
+ `,r),c=s<0?i:s,l=r,u=0;l<c&&u<4;)if(e.charCodeAt(l)===q)u++,l++;else if(e.charCodeAt(l)===J)u+=4,l++;else break;if(l>=c){a=!1,r=s<0?i:s+1;continue}if(u<4){var d=e.charCodeAt(l);if(d===xy||d===Sy){for(var f=d,p=0,m=l;m<c&&e.charCodeAt(m)===f;)p++,m++;if(p>=3){var h=!0;if(f===xy){for(var g=m;g<c;g++)if(e.charCodeAt(g)===xy){h=!1;break}}if(h){a=!1;for(var _=s<0?i:s+1;_<i;){for(var v=_,y=0;v<i&&y<4;){var b=e.charCodeAt(v);if(b===q)y++,v++;else if(b===J)y+=4,v++;else break}if(y<4&&v<i&&e.charCodeAt(v)===f){for(var x=0;v<i&&e.charCodeAt(v)===f;)x++,v++;if(x>=p){for(;v<i&&(e.charCodeAt(v)===q||e.charCodeAt(v)===J);)v++;if(v>=i||e.charCodeAt(v)===Y){r=v>=i?i:v+1;break}}}for(;_<i&&e.charCodeAt(_)!==Y;)_++;_<i&&_++}_>=i&&(r=i,o=!0);continue}}}}for(var S=l;S<c&&e.charCodeAt(S)===Ty;){S++,S<c&&e.charCodeAt(S)===q&&S++;for(var C=0;S<c&&C<4;)if(e.charCodeAt(S)===q)C++,S++;else if(e.charCodeAt(S)===J)C+=4,S++;else break;if(C>=4)break;a=!1}if(!a&&u<4&&S<c&&e.charCodeAt(S)===Cy&&!(S+1<i&&e.charCodeAt(S+1)===wy)){var w=xx(e,S,t);if(w){r=w,a=!1;continue}}var T=e.charCodeAt(l);if(T===Ey&&u<4)a=!1;else if(u<4&&(T===Oy||T===jy||T===My)){for(var E=l,D=0;E<c;){var O=e.charCodeAt(E);if(O===T)D++;else if(O!==q&&O!==J)break;E++}a=!(D>=3&&E>=c)}else a=!0;r=s<0?i:s+1}return o}function xx(e,t,n){let r=e.length;if(e.charCodeAt(t)!==Cy)return null;let i=t+1<r&&e.charCodeAt(t+1)===wy,a=t+1;for(;a<r;){var o=e.charCodeAt(a);if(o===Fy){a++;break}if(o===Cy)return null;o===Ay&&a+1<r&&a++,a++}if(a>r||e.charCodeAt(a-1)!==Fy)return null;let s=e.slice(t+1,a-1);if(s.length>999)return null;let c=Tx(s);if(!c||a>=r||e.charCodeAt(a)!==Ry)return null;a++;let l=!1;for(;a<r;){let t=e.charCodeAt(a);if(t===q||t===J)a++;else if(t===Y&&!l)l=!0,a++;else break}if(i){let t=e.indexOf(`
1585
+ `,a),i=t<0?r:t;return n[c]={target:e.slice(a,i).trim(),title:void 0},t<0?r:t+1}var u;if(a<r&&e.charCodeAt(a)===Ny){a++;for(var d=a;a<r&&e.charCodeAt(a)!==Ty&&e.charCodeAt(a)!==Y;)e.charCodeAt(a)===Ay&&a+1<r&&a++,a++;if(a>=r||e.charCodeAt(a)!==Ty)return null;u=e.slice(d,a),a++;for(var f=e.indexOf(`
1586
+ `,a),p=f<0?r:f,m=a;m<p&&(e.charCodeAt(m)===q||e.charCodeAt(m)===J);)m++;if(m<p){if(m===a)return null;var h=e.charCodeAt(m);if(h!==eb&&h!==$y&&h!==ab)return null}}else{for(var d=a,g=0;a<r;){var o=e.charCodeAt(a);if(o===ab)g++;else if(o===ob){if(g===0)break;g--}else{if(o===q||o===J||o===Y)break;o===Ay&&a+1<r&&a++}a++}if(u=e.slice(d,a),!u)return null}for(;a<r&&(e.charCodeAt(a)===q||e.charCodeAt(a)===J);)a++;var _=e.indexOf(`
1587
+ `,a),v=_<0?r:_,y,b=!1,x=a,S=a;if(a===v&&a<r)for(S=a+1;S<r&&(e.charCodeAt(S)===q||e.charCodeAt(S)===J);)S++;if(S<r){var C=e.charCodeAt(S);if(C===eb||C===$y||C===ab){for(var w=C===ab?41:C,T=S+1,E=T;T<r;){var D=e.charCodeAt(T);if(D===w){for(var O=T+1;O<r&&(e.charCodeAt(O)===q||e.charCodeAt(O)===J);)O++;(O>=r||e.charCodeAt(O)===Y)&&(y=e.slice(E,T),b=!0,x=O<r?O+1:r);break}if(D===Ay&&T+1<r){T+=2;continue}if(D===Y&&T+1<r&&e.charCodeAt(T+1)===Y)break;T++}if(!b&&S===a)return null}}if(b)return n[c]||(n[c]={target:Dx(u),title:y===void 0?y:xb(Dx(y))}),x;for(;a<v&&(e.charCodeAt(a)===q||e.charCodeAt(a)===J);)a++;return a<v?null:(n[c]||(n[c]={target:Dx(u),title:y}),_<0?r:_+1)}var Sx=new Uint8Array(Rb);for(Sx[Ey]|=Ib,Sx[Ty]|=Ib,Sx[Oy]|=Ib|Lb,Sx[tb]|=Ib,Sx[jy]|=Ib|Lb,Sx[My]|=Ib|Lb,Sx[xy]|=Ib|Lb,Sx[Sy]|=Ib|Lb,Sx[Ny]|=Ib|Lb,Sx[Cy]|=Lb,Sx[Iy]|=Lb,Sx[nb]|=Ib,Cx=ub;Cx<=db;Cx++)Sx[Cx]|=Ib;var Cx;function wx(e){if(e.indexOf(`[`)<0&&e.indexOf(`]`)<0)return!1;for(var t=0;t<e.length;t++){if(e.charCodeAt(t)===Ay){t++;continue}if(e.charCodeAt(t)===Cy||e.charCodeAt(t)===Fy)return!0}return!1}function Tx(e){for(var t=e.length,n=!0,r=t>0,i=0;i<t;i++){var a=e.charCodeAt(i);if(a===q){if(n){r=!1;break}n=!0}else if(a<33||a>126||a>=fb&&a<=pb){r=!1;break}else n=!1}if(r&&!n)return e;var o=e.replace(/\s+/g,` `).trim();return o.indexOf(`ẞ`)===-1?o.toLowerCase():o.replace(/\u1E9E/g,`ss`).toLowerCase()}function Ex(e){return e<gb?Sx[e]:e===Ky?jb:0}function Dx(e){return e.indexOf(`\\`)===-1?e:e.replace(/\\([!"#$%&'()*+,\-./:;<=>?@[\\\]^_`{|}~])/g,`$1`)}var Ox=null,kx=-1,Ax=-1;function jx(e,t){if(t>=kx&&t<=Ax&&e===Ox)return Ax;var n=e.indexOf(`
1588
+ `,t),r=n<0?e.length:n;return Ox=e,kx=t,Ax=r,r}function Mx(e,t){let n=jx(e,t);return n<e.length?n+1:n}function Nx(e,t,n){for(;t<n;){let n=e.charCodeAt(t);if(n!==q&&n!==J)break;t++}return t}function Px(e,t){let n=Mx(e,t);for(;n<e.length;){let t=jx(e,n);if(zx(e,n,t))return n;n=Mx(e,n)}return e.length}function Fx(e,t,n,r){let i=0;for(;t+i<n&&e.charCodeAt(t+i)===r;)i++;return i}var Ix=0,Lx=0;function Rx(e,t,n){for(Ix=0,Lx=0;t+Lx<n;){let n=e.charCodeAt(t+Lx);if(n===J)Ix+=4-Ix%4;else if(n===q)Ix++;else break;Lx++}}function zx(e,t,n){return Nx(e,t,n)>=n}function Bx(e,t,n,r){let i=jx(e,t);if(Rx(e,t,i),Ix>3)return null;let a=t+Lx;if(e.charCodeAt(a)!==Ey)return null;let o=Fx(e,a,i,35);if(o<1||o>6||(a+=o,a<i&&e.charCodeAt(a)!==q&&e.charCodeAt(a)!==J))return null;a=Nx(e,a,i);for(var s=i;s>a&&e.charCodeAt(s-1)===q;)s--;for(var c=s;s>a&&e.charCodeAt(s-1)===Ey;)s--;if(s<c)if(s===a||e.charCodeAt(s-1)===q)for(;s>a&&e.charCodeAt(s-1)===q;)s--;else s=c;let l=e.slice(a,s),u=uS(l,!1,n,r),d=(r?.slugify||Db)(l);return{node:{type:K.heading,level:o,children:u,id:d},end:Mx(e,i)}}function Vx(e,t,n){var r=e.charCodeAt(t);if(r!==ky&&r!==Oy)return!1;for(var i=t;i<n&&e.charCodeAt(i)===r;)i++;for(;i<n&&(e.charCodeAt(i)===q||e.charCodeAt(i)===J);)i++;return i>=n}function Hx(e,t){let n=jx(e,t);if(Rx(e,t,n),Ix>3)return null;let r=t+Lx,i=e.charCodeAt(r);if(i!==Oy&&i!==jy&&i!==My)return null;let a=0;for(;r<n;){let t=e.charCodeAt(r);if(t===i)a++;else if(t!==q&&t!==J)return null;r++}return a<3?null:{node:{type:K.breakThematic},end:Mx(e,n)}}function Ux(e,t,n){let r=jx(e,t);if(Rx(e,t,r),Ix>3)return null;let i=Ix,a=t+Lx,o=e.charCodeAt(a);if(o!==xy&&o!==Sy)return null;let s=Fx(e,a,r,o);if(s<3)return null;a+=s;let c=Nx(e,a,r),l=r;if(o===xy){for(let t=c;t<r;t++)if(e.charCodeAt(t)===xy)return null}for(;l>c&&(e.charCodeAt(l-1)===q||e.charCodeAt(l-1)===J);)l--;let u=e.slice(c,l),d=``,f=``,p=u.indexOf(` `);p===-1?d=u:(d=u.slice(0,p),f=u.slice(p+1).trim()),d=Dx(d);var m=void 0;if(f){gx.lastIndex=0;for(var h;(h=gx.exec(f))!==null;)m||={},m[h[1]]=h[2]===void 0?h[3]:h[2]}let g=Mx(e,r),_=e.length,v=e.length;for(var y=String.fromCharCode(o).repeat(s),b=g;b<e.length;){var x=e.indexOf(y,b);if(x===-1)break;for(var S=x,C=0;S>0&&C<4&&e.charCodeAt(S-1)===q;)S--,C++;if(C<=3&&(S===0||e.charCodeAt(S-1)===Y)){for(var w=x+s;w<e.length&&e.charCodeAt(w)===o;)w++;var T=jx(e,w);if(zx(e,w,T)){_=S,v=Mx(e,T);break}}b=x+1}var E;if(i===0)E=_>g&&e.charCodeAt(_-1)===Y?e.slice(g,_-1):e.slice(g,_);else{E=``;for(var D=g;D<_;){var O=jx(e,D);Rx(e,D,O);var ee=Math.min(Lx,i);E+=e.slice(D+ee,O)+`
1589
+ `,D=Mx(e,O)}E.length>0&&E.charCodeAt(E.length-1)===Y&&(E=E.slice(0,-1))}return{node:{type:K.codeBlock,lang:d||void 0,text:E,infoString:f||void 0,attrs:m},end:v}}function Wx(e,t){if(Rx(e,t,jx(e,t)),Ix<4)return null;let n=``,r=t;for(;r<e.length;){let t=jx(e,r);if(Rx(e,r,t),zx(e,r,t)){for(var i=0,a=Mx(e,t);a<e.length;){var o=jx(e,a);if(zx(e,a,o)){i++,a=Mx(e,o);continue}if(Rx(e,a,o),Ix>=4){for(var s=0;s<=i;s++)n+=`
1590
+ `;r=a;break}break}if(r!==a)break;continue}if(Ix<4)break;let f=0,p=0;var c=0;for(let n=r;n<t&&p<4;n++){if(e.charCodeAt(n)===J){var l=4-p%4;p+l>4&&(c=p+l-4),p+=l}else p++;f++}var u=``;if(c>0)for(var d=0;d<c;d++)u+=` `;u+=e.slice(r+f,t),n+=u+`
1591
+ `,r=Mx(e,t)}for(;n.length>0&&n.charCodeAt(n.length-1)===Y;)n=n.slice(0,-1);return n?{node:{type:K.codeBlock,lang:void 0,text:n,infoString:void 0,attrs:void 0},end:r}:null}function Gx(e,t,n,r){if(Rx(e,t,jx(e,t)),Ix>3)return null;let i=t+Lx;if(e.charCodeAt(i)!==Ty)return null;let a=``,o=t,s,c=!1,l=!1,u=!1;for(;o<e.length;){let t=jx(e,o);Rx(e,o,t);let n=o+Lx;if(e.charCodeAt(n)===Ty){let r=n+1;var d=Ix+1,f=!1;if(r<t){var p=e.charCodeAt(r);p===q?(r++,d++,f=!0):p===J&&(f=!0)}for(var m=``,h=!1,g=r;g<t;g++)if(e.charCodeAt(g)===J){h=!0;break}if(h){var _=d;if(f&&r<t&&e.charCodeAt(r)===J){for(var v=4-_%4,y=0;y<v-1;y++)m+=` `;_+=v,r++}for(var b=r;b<t;b++)if(e.charCodeAt(b)===J){for(var x=4-_%4,S=0;S<x;S++)m+=` `;_+=x}else m+=e[b],_++}else m=e.slice(r,t);if(!a&&!s){let n=m.match(/^\[!([A-Za-z]+)\]\s*$/);if(n){s=n[1].toUpperCase(),o=Mx(e,t);continue}}a+=m+`
1592
+ `;var C=m.trimStart();C.startsWith("```")||C.startsWith(`~~~`)?u=!u:(m.startsWith(` `)||m.startsWith(` `))&&(u=!0),l=C.length>0,o=Mx(e,t)}else if(a&&!zx(e,o,t)&&l){if(Ix<4){var w=o+Lx,T=w<t?e.charCodeAt(w):0;if(T===Ey||T===Ty||T===xy||T===Sy||T===Ny||(T===Oy||T===jy||T===My)&&Hx(e,o)||(T===Oy||T===jy||T===tb)&&w+1<t&&(e.charCodeAt(w+1)===q||e.charCodeAt(w+1)===J))break;if(T>=ub&&T<=db){for(var E=w;E<t&&e.charCodeAt(E)>=ub&&e.charCodeAt(E)<=db;)E++;if(E<t&&(e.charCodeAt(E)===Zy||e.charCodeAt(E)===ob))break}}if(u)break;a+=e.slice(o,t)+`
1593
+ `,c=!0,o=Mx(e,t)}else break}if(!a&&!s)return null;var{inBlockQuote:D,f:O}=n;n.inBlockQuote=!0,c&&(n.f=!0);let ee=PS(a||``,n,r);return n.inBlockQuote=D,n.f=O,{node:{type:K.blockQuote,children:ee,alert:s||void 0},end:o}}function Kx(e,t,n){for(var r=0,i=t;i<n;i++)e.charCodeAt(i)===J?r+=4-r%4:r++;return r}function qx(e,t,n){if(Rx(e,t,n),Ix>3)return null;var r=t+Lx;if(r>=n)return null;var i=e.charCodeAt(r),a=Ix,o=r;if(i===Oy||i===jy||i===tb){if(o=r+1,o<n&&e.charCodeAt(o)!==q&&e.charCodeAt(o)!==J&&e.charCodeAt(o)!==Y)return null}else if(i>=ub&&i<=db){for(var s=r;s<n&&s-r<9;){var c=e.charCodeAt(s);if(c<ub||c>db)break;s++}if(s>r&&s<n){var l=e.charCodeAt(s);if(l===Zy||l===ob){if(o=s+1,o<n&&e.charCodeAt(o)!==q&&e.charCodeAt(o)!==J&&e.charCodeAt(o)!==Y)return null}else return null}else return null}else return null;var u=o,d=Kx(e,t,o),f=0,p=u,m=d;if(u>=n)return{ordered:i>=ub&&i<=db,marker:i>=ub&&i<=db?e[s]:e[r],start:i>=ub&&i<=db?parseInt(e.slice(r,s),10):void 0,contentStart:u,contentCol:d+1,markerCol:a,isEmpty:!0};for(;p<n&&(e.charCodeAt(p)===q||e.charCodeAt(p)===J);){if(e.charCodeAt(p)===J){var h=4-m%4;m+=h}else m++;p++,f++}var g=p>=n,_=m-d;return g||_>4?(m=d+1,p=u+1,f=1):f===0&&(m=d+1,p=u,f=1),{ordered:i>=ub&&i<=db,marker:i>=ub&&i<=db?e[s]:e[r],start:i>=ub&&i<=db?parseInt(e.slice(r,s),10):void 0,contentStart:p,contentCol:m,markerCol:a,isEmpty:g}}var Jx=0;function Yx(e,t,n,r){var i=0,a=t;for(Jx=0;a<n&&i<r;){var o=e.charCodeAt(a);if(o===J){var s=4-i%4;if(i+s>r){Jx=i+s-r,a++,i=r;break}i+=s}else if(o===q)i++;else break;a++}return a}function Xx(e,t,n,r){var i=jx(e,t),a=qx(e,t,i);if(!a)return null;var o=[],s=t,c=a.contentCol,l=``,u=a.isEmpty,d=!1,f=!1;if(!a.isEmpty){for(var p=!1,m=a.contentStart;m<i;m++)if(e.charCodeAt(m)===J){p=!0;break}if(p){var h=``,g=Kx(e,t,a.contentStart),_=g-a.contentCol;if(_>0)for(var v=0;v<_;v++)h+=` `;for(var y=a.contentStart;y<i;y++)if(e.charCodeAt(y)===J){for(var b=4-g%4,x=0;x<b;x++)h+=` `;g+=b}else h+=e[y],g++;l=h+`
1594
+ `}else l=e.slice(a.contentStart,i)+`
1595
+ `}for(s=Mx(e,i);s<e.length;){var S=jx(e,s);Rx(e,s,S);var C=e.charCodeAt(s+Lx);if(Ix<c&&(C===Oy||C===jy||C===My)&&Ix<=3&&Hx(e,s))break;var w=qx(e,s,S);if(w&&w.ordered===a.ordered&&w.marker===a.marker&&w.markerCol<c){o.push({contentCol:c,raw:l,hasBlankAfter:d,isEmpty:u}),d&&(f=!0),c=w.contentCol,u=w.isEmpty,d=!1,l=w.isEmpty?``:e.slice(w.contentStart,S)+`
1596
+ `,s=Mx(e,S);continue}if(zx(e,s,S)){l+=`
1597
+ `,s=Mx(e,S);for(var T=!1,E=0;E<l.length;E++){var D=l.charCodeAt(E);if(D!==Y&&D!==by&&D!==q&&D!==J){T=!0;break}}if(u&&!T)if(s<e.length){var O=jx(e,s),ee=qx(e,s,O);if(!ee||ee.ordered!==a.ordered||ee.marker!==a.marker)break;d=!0}else break;if(s<e.length){var k=jx(e,s);Rx(e,s,k);var A=e.charCodeAt(s+Lx);if((A===Oy||A===jy||A===My)&&Ix<=3&&Hx(e,s))break;var j=qx(e,s,k);if(j&&j.ordered===a.ordered&&j.marker===a.marker&&j.markerCol<c){d=!0;continue}if(!zx(e,s,k)&&Ix<c)break}continue}if(Ix>=c){var M=Yx(e,s,S,c);if(Jx>0){for(var N=``,te=c,ne=0;ne<Jx;ne++)N+=` `,te++;for(var P=M;P<S;P++)if(e.charCodeAt(P)===J){for(var re=4-te%4,ie=0;ie<re;ie++)N+=` `;te+=re}else N+=e[P],te++;l+=N+`
1598
+ `}else l+=e.slice(M,S)+`
1599
+ `;s=Mx(e,S);continue}for(var ae=!1,oe=0;oe<l.length;oe++){var F=l.charCodeAt(oe);if(F!==Y&&F!==by&&F!==q&&F!==J){ae=!0;break}}if(!d&&ae&&!u){var I=s+Lx,L=e.charCodeAt(I);if(!(L===Ey||L===Ty||L===Ny||L===xy||L===Sy||(L===Oy||L===jy||L===My||L===tb)&&(Hx(e,s)!==null||qx(e,s,S)!==null)||L>=ub&&L<=db&&qx(e,s,S)!==null)){l+=``+e.slice(I,S)+`
1600
+ `,s=Mx(e,S);continue}}break}if(o.push({contentCol:c,raw:l,hasBlankAfter:d,isEmpty:u}),o.length===0)return null;var se=f;if(!se)for(var ce=0;ce<o.length;ce++){if(o[ce].hasBlankAfter&&ce<o.length-1){se=!0;break}if(!o[ce].isEmpty){for(var le=o[ce].raw,ue=le.length,de=0,R=!1,fe=!1,pe=!1,me=!1,he=0,ge=0,_e=-1;de<ue;){var ve=le.indexOf(`
1601
+ `,de);if(ve<0&&(ve=ue),me){Rx(le,de,ve);for(var ye=le.slice(de+Lx,ve),be=0;be<ye.length&&ye.charCodeAt(be)===he;)be++;be>=ge&&ye.slice(be).trim()===``&&(me=!1),de=ve<ue?ve+1:ue;continue}if(zx(le,de,ve)){_e>=0?pe=!0:R&&(fe=!0),de=ve<ue?ve+1:ue;continue}if(Rx(le,de,ve),_e>=0){if(Ix>=_e){de=ve<ue?ve+1:ue;continue}var xe=qx(le,de,ve);if(xe&&xe.markerCol<_e&&xe.contentCol<=_e){de=ve<ue?ve+1:ue;continue}if(xe){de=ve<ue?ve+1:ue;continue}_e=-1,pe&&=(fe=!0,!1)}var Se=le.slice(de+Lx,ve),z=Se.charCodeAt(0);if((z===xy||z===Sy)&&Ix<=3){for(var Ce=0;Ce<Se.length&&Se.charCodeAt(Ce)===z;)Ce++;if(Ce>=3){if(fe&&R){se=!0;break}me=!0,he=z,ge=Ce,R=!0,de=ve<ue?ve+1:ue;continue}}var we=Ix<=3?qx(le,de,ve):null;if(we&&R){if(fe){se=!0;break}_e=we.contentCol,pe=!1,de=ve<ue?ve+1:ue,R=!0;continue}if(fe){se=!0;break}R=!0,de=ve<ue?ve+1:ue}if(se)break}}for(var Te=[],Ee=0;Ee<o.length;Ee++){for(var De=o[Ee],Oe=De.raw,ke=Oe.length;ke>0&&Oe.charCodeAt(ke-1)===Y;)ke--;var Ae=ke<Oe.length?Oe.slice(0,ke):Oe,je=null;if(Ae.length>=3&&Ae.charCodeAt(0)===Cy){var Me=Ae[1];(Me===` `||Me===`x`||Me===`X`)&&Ae.charCodeAt(2)===Fy&&(je={type:K.gfmTask,completed:Me===`x`||Me===`X`},Ae=Ae.slice(3))}var Ne;if(De.isEmpty&&Ae.trim()===``)Ne=[];else if(se){var Pe=n.inList;n.inList=!0,Ne=PS(Ae,n,r),n.inList=Pe}else{var Fe=n.inList;if(n.inList=!0,Ne=PS(Ae,n,r),n.inList=Fe,Ne.length===1&&Ne[0].type===K.paragraph)Ne=Ne[0].children;else if(n.h){var Ie=[];n.h.push({src:Ne,dest:Ie,unwrap:!0}),Ne=Ie}else{for(var Le=[],B=0;B<Ne.length;B++)if(Ne[B].type===K.paragraph)for(var Re=Ne[B].children,ze=0;ze<Re.length;ze++)Le.push(Re[ze]);else Le.push(Ne[B]);Ne=Le}}if(je){var Be=[je,{type:K.text,text:` `}];if(n.h)n.h.push({src:Ne,dest:Be,unwrap:!1});else for(var Ve=0;Ve<Ne.length;Ve++)Be.push(Ne[Ve]);Te.push(Be)}else Te.push(Ne)}return{node:{type:a.ordered?K.orderedList:K.unorderedList,start:a.ordered?a.start:void 0,items:Te},end:s}}var Zx=new Set(`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.h1.h2.h3.h4.h5.h6.head.header.hr.html.iframe.legend.li.link.main.menu.menuitem.nav.noframes.ol.optgroup.option.p.param.search.section.summary.table.tbody.td.tfoot.th.thead.title.tr.track.ul`.split(`.`));function Qx(e,t,n){let r={};for(let[o,s]of Object.entries(e)){let e=o.toLowerCase();if(e===`style`&&typeof s==`string`){let e={},t=[],n=0,i=0;for(let e=0;e<s.length;e++){let r=s.charCodeAt(e);r===ab?n++:r===ob?n--:r===Yy&&n===0&&(t.push(s.slice(i,e)),i=e+1)}i<s.length&&t.push(s.slice(i));let a=!1;t.forEach(t=>{let n=t.indexOf(`:`);if(n===-1)return;let r=t.slice(0,n).trim(),i=t.slice(n+1).trim();if(r&&i){if(/url\s*\(\s*(javascript|vbscript|data:(?!image\/))/i.test(i)){a=!0;return}let t=r.indexOf(`-`)===-1?r:r.replace(/-([a-z])/g,(e,t)=>t.toUpperCase());e[t]=i}}),!a&&Object.keys(e).length>0&&(r[o]=e)}else if((e===`href`||e===`src`)&&n?.sanitizer){let i=n.sanitizer(s,t,e);i!==null&&(r[o]=i)}else if(s===``)r[o]=!0;else if(s.length>=2&&s.charCodeAt(0)===rb&&s.charCodeAt(s.length-1)===ib){var i=s.slice(1,-1);if(i.length>0){var a=i.charCodeAt(0);if(a===Cy||a===rb)try{r[o]=JSON.parse(i);continue}catch{}}if(i===`true`){r[o]=!0;continue}if(i===`false`){r[o]=!1;continue}if(n?.evalUnserializableExpressions)try{r[o]=(0,eval)(`(`+i+`)`);continue}catch{}r[o]=i}else r[o]=s}return r}function $x(e,t,n){let r=t.length;if(r===0)return n;var i=t.charCodeAt(0);if(!(i>=fb&&i<=pb||i>=mb&&i<=hb)){for(var a=String.fromCharCode(i),o=e.length-r,s=n;s<=o;){var c=e.indexOf(a,s);if(c===-1||c>o)return-1;for(var l=!0,u=1;u<r;u++){var d=e.charCodeAt(c+u),f=t.charCodeAt(u);if(d>=fb&&d<=pb&&(d+=_b),f>=fb&&f<=pb&&(f+=_b),d!==f){l=!1;break}}if(l)return c;s=c+1}return-1}i>=fb&&i<=pb&&(i+=_b);for(let a=n;a<=e.length-r;a++){var p=e.charCodeAt(a);if(p>=fb&&p<=pb&&(p+=_b),p!==i)continue;let n=!0;for(let i=1;i<r;i++){let r=e.charCodeAt(a+i),o=t.charCodeAt(i);if(r>=fb&&r<=pb&&(r+=_b),o>=fb&&o<=pb&&(o+=_b),r!==o){n=!1;break}}if(n)return a}return-1}function eS(e,t,n){let r=t.length;var i=t.charCodeAt(0);i>=fb&&i<=pb&&(i+=_b);for(let o=Math.min(n,e.length-r);o>=0;o--){var a=e.charCodeAt(o);if(a>=fb&&a<=pb&&(a+=_b),a!==i)continue;let n=!0;for(let i=1;i<r;i++){let r=e.charCodeAt(o+i),a=t.charCodeAt(i);if(r>=fb&&r<=pb&&(r+=_b),a>=fb&&a<=pb&&(a+=_b),r!==a){n=!1;break}}if(n)return o}return-1}var tS=-1;function nS(e,t,n){let r=n.toLowerCase(),i=`<`+r,a=`</`+r,o=1,s=t,c=e.length;for(tS=-1;s<c&&o>0;){let t=$x(e,i,s),n=$x(e,a,s);if(n===-1)return-1;if(t!==-1&&t<n){let n=yx(e,t);n?(n.tag.toLowerCase()===r&&!n.isClosing&&!n.selfClosing&&!Ab(n.tag)&&o++,s=n.end):s=t+1}else{var l=n+a.length,u=l<c?e.charCodeAt(l):62;if((u===Ty||u===q||u===J||u===Y)&&(o--,o===0)){tS=n;let t=n+a.length;for(;t<c&&e.charCodeAt(t)!==Ty;)t++;return t+1}s=n+1}}return-1}function rS(e,t,n,r){if(r.ignoreHTMLBlocks||r.disableParsingRawHTML)return null;var i=jx(e,t);if(Rx(e,t,i),Ix>3&&!n.inHTML)return null;var a=t+Lx;if(e.charCodeAt(a)!==Ny)return null;var o=e.indexOf(`>`,a+1);if(o!==-1&&o<i){var s=e.slice(a+1,o);if(/^[a-zA-Z][a-zA-Z0-9+.-]*:/.test(s)||/^[^\s@]+@[^\s@]+$/.test(s))return null}var c=iS(e,a);if(c>=1&&c<=5){var l=e.length;if(c===1){for(var u=e.length,d=0;d<ux.length;d++){var f=$x(e,`</`+ux[d]+`>`,a);f>=0&&f<u&&(u=f)}if(u<e.length){var p=e.indexOf(`>`,u);l=p>=0?Mx(e,p+1):e.length}}else{var m=c===2?`-->`:c===3?`?>`:c===4?`>`:`]]>`,h=e.indexOf(m,a);h>=0&&(l=Mx(e,h+m.length))}var g=e.slice(a,l);if(c>=2)return{node:{type:K.htmlComment,text:g,l:!1,raw:!0},end:l};var _=`div`,v=g.match(/^<\/?([a-zA-Z][a-zA-Z0-9-]*)/);v&&(_=v[1]);var y=yx(e,a),b={},x;y&&!y.isClosing&&(b=Qx(y.attrs,_,r),x=y.whitespaceBeforeAttrs+y.rawAttrs);var S=[],C=$x(g,`</`+_.toLowerCase(),0),w=g,T=``;if(y&&y.isClosing)for(w=g.slice(y.end-a);w.length>0&&w.charCodeAt(w.length-1)===Y;)w=w.slice(0,-1);else if(y&&!y.isClosing){var E=y.end-a;if(C!==-1)for(w=g.slice(E),w.charCodeAt(0)===Y&&(w=w.slice(1));w.length>0&&w.charCodeAt(w.length-1)===Y;)w=w.slice(0,-1);else for(w=g;w.length>0&&w.charCodeAt(w.length-1)===Y;)w=w.slice(0,-1);C!==-1&&(T=g.slice(E,C).trim())}var D=y?y.isClosing:!1;return{node:{type:K.htmlBlock,tag:_,attrs:b,i:x,children:S,a:w,text:T,d:!0,b:D},end:l}}if(c===6||c===7){var O=Px(e,t),ee=O<e.length?O:e.length,k=e.slice(a,ee),A=O<e.length?Mx(e,O):e.length,j=yx(e,a);if(j){var M=j.tag,N=M.toLowerCase();if(j.isClosing){var te=e.slice(j.end,ee);return{node:{type:K.htmlBlock,tag:M,attrs:{},children:[],a:te,text:te,d:!0,b:!0},end:A}}if(j.selfClosing||Ab(M))return{node:{type:K.htmlBlock,tag:M,attrs:Qx(j.attrs,M,r),i:j.whitespaceBeforeAttrs+j.rawAttrs,children:[],a:``,text:``,d:!1,b:!1},end:j.end<e.length&&e.charCodeAt(j.end)===Y?j.end+1:j.end};var ne=n.c||0,P=e.slice(a,ee),re=-1,ie=-1;if(ne<10){for(var ae=`</`+N,oe=j.end-a,F=1,I=oe;I<P.length&&F>0;){var L=$x(P,`<`+N,I),se=$x(P,ae,I);if(se===-1)break;if(L!==-1&&L<se){var ce=L+N.length+1;if(ce<P.length){var le=P.charCodeAt(ce);(le===q||le===J||le===Y||le===Ty||le===Qy)&&F++}I=L+1}else{var ue=se+ae.length;if(ue<P.length){var de=P.charCodeAt(ue);if((de===Ty||de===q||de===J||de===Y)&&(F--,F===0)){re=se;for(var R=ue;R<P.length&&P.charCodeAt(R)!==Ty;)R++;ie=R+1;break}}else if(F--,F===0){re=se,ie=P.length;break}I=se+1}}var fe=!1;if(re===-1&&c===6&&!j.isClosing){var pe=nS(e,j.end,N);if(pe!==-1){for(var me=tS,he=j.end,ge=!1,_e=!1,ve=!1,ye=0,be=!1,xe=!1,Se=he;Se<me;){var z=e.charCodeAt(Se);if(z===Y)xe&&(ge=!0),be||ye++,xe=!0,Se++;else if(z===q||z===J)Se++;else{if(!be&&(be=!0,ye>=2&&z===Ny)){ve=!0;break}if(xe=!1,z===Ny){var Ce=e.charCodeAt(Se+1)|32;if((Ce===Wy||Ce===Gy||Ce===Uy)&&(fx.lastIndex=Se,fx.test(e))){_e=!0;break}}Se++}}if(ge&&!ve&&!_e){var we=jx(e,pe);ee=we,A=Mx(e,we),P=e.slice(a,ee),k=e.slice(a,ee),re=me-a,ie=pe-a,fe=!0}}}}var Te=j.rawAttrs.indexOf(`
1602
+ `)!==-1||j.whitespaceBeforeAttrs.indexOf(`
1603
+ `)!==-1,Ee=!1;re!==-1&&(Ee=P.slice(ie).trim().length===0);var De=!1,Oe=ee,ke=A;if(re!==-1){var Ae=a+ie,je=jx(e,Ae-1);if(Ae<je){for(var Me=Ae;Me<je&&(e.charCodeAt(Me)===q||e.charCodeAt(Me)===J);)Me++;if(Me<je&&e.charCodeAt(Me)===Ny){var Ne=yx(e,Me);Ne&&!Ne.isClosing&&(De=!0,Oe=Ae,ke=Ae,Ee=!0)}}if(!De){var Pe=Mx(e,je);if(Pe<ee){for(var Fe=Pe;Fe<ee&&(e.charCodeAt(Fe)===q||e.charCodeAt(Fe)===J);)Fe++;Fe<ee&&e.charCodeAt(Fe)===Ny&&yx(e,Fe)&&(De=!0,Oe=je,ke=Pe,Ee=!0)}}!De&&n.inHTML&&(De=!0,Oe=je,ke=Mx(e,je),Ee=e.slice(Ae,je).trim().length===0)}var Ie=[],Le=``;if(re!==-1){Le=P.slice(j.end-a,re);var B=Le.trim();if(B){var{inline:Re,inHTML:ze,c:Be}=n;if(n.inHTML=!0,n.c=ne+1,N===`p`)n.inline=!0,Ie=uS(B,!1,n,r);else{var Ve=Le.indexOf(`
1604
+
1605
+ `)!==-1,He=px.test(B),Ue=mx.test(B),We=Ve||He||n.inHTML&&Ue;Le.length>=2&&Le.charCodeAt(0)===Y&&Le.charCodeAt(Le.length-1)===Y&&!Ve&&!He&&!Ue?Ie=[{type:K.text,text:B}]:We||Ue?(n.inline=!1,Ie=PS(Le,n,r)):(n.inline=!0,Ie=uS(B,!1,n,r))}n.inline=Re,n.inHTML=ze,n.c=Be}}var Ge=!1;if(c===6&&re!==-1&&!n.inHTML&&!Te){var Ke=/<[a-zA-Z][^>]*>/.test(Le),qe=Le.indexOf(`
1606
+
1607
+ `)!==-1||px.test(Le);Ke&&!qe&&(Ge=!0)}if(!fe&&(n.inHTML||c===7||Te||!Ee||Ge)){var Je,V=!1;if(re!==-1&&De){var Ye=!1;if(n.inHTML&&ie<P.length){for(var Xe=ie;Xe<P.length&&P.charCodeAt(Xe)!==Y;)Xe++;var Ze=P.slice(ie,Xe).trim();Ye=Ze.length>1&&Ze.charCodeAt(0)===Ny&&Ze.charCodeAt(1)!==Qy}Je=Ye?P.slice(j.end-a):Le,V=!0}else(c===7||n.inHTML)&&re!==-1?(Je=P.slice(j.end-a),Je.charCodeAt(0)===Y&&(Je=Je.slice(1))):De?Je=e.slice(a,Oe):Te?Je=k:(Je=P.slice(j.end-a),Je.charCodeAt(0)===Y&&(Je=Je.slice(1)));var Qe={type:K.htmlBlock,tag:M,attrs:Qx(j.attrs,M,r),i:j.whitespaceBeforeAttrs+j.rawAttrs,children:Ie,a:Je,text:Je,d:!0,b:!1};return V&&(Qe.n=!0),{node:Qe,end:ke}}return{node:{type:K.htmlBlock,tag:M,attrs:Qx(j.attrs,M,r),i:j.whitespaceBeforeAttrs+j.rawAttrs,children:Ie,a:fe?``:Le,text:Le,d:!1,b:!1},end:ke}}var $e=k.match(/^<(\/?)([a-zA-Z][a-zA-Z0-9-]*)/),et=$e?$e[2]:`div`,tt=$e?$e[1]===`/`:!1,nt=k;if(tt){var rt=k.indexOf(`>`);rt!==-1&&(nt=k.slice(rt+1))}return{node:{type:K.htmlBlock,tag:et,attrs:{},children:[],a:nt,text:nt,d:!0,b:tt},end:A}}var H=yx(e,a);if(!H)return null;var it=H.tag,at=it.toLowerCase(),ot=it.charCodeAt(0),st=ot>=fb&&ot<=pb;if(!st&&!Zx.has(at)&&!dx.has(at)&&!at.includes(`-`))return null;if(H.isClosing)return{node:{type:K.htmlSelfClosing,tag:it,attrs:{},a:e.slice(a,H.end),b:!0},end:H.end};var ct=nS(e,H.end,it),lt=[];if(ct!==-1){var ut=tS,dt=e.slice(H.end,ut),ft=dt.trim();if(ft){var pt=dt.indexOf(`
1608
+
1609
+ `)!==-1,mt=px.test(ft),ht=mx.test(ft),gt=n.inline,_t=n.inHTML,vt=n.c;n.inHTML=!0,n.c=(n.c||0)+1,pt||mt||ht?(n.inline=!1,lt=PS(dt,n,r)):(n.inline=!0,lt=uS(ft,!1,n,r)),n.inline=gt,n.inHTML=_t,n.c=vt}var yt=jx(e,ct),bt=e.slice(ct,yt).trim()?ct:Mx(e,ct),xt=st?e.slice(a,ct):e.slice(a,bt);return{node:{type:K.htmlBlock,tag:it,attrs:Qx(H.attrs,it,r),i:H.whitespaceBeforeAttrs+H.rawAttrs,children:lt,a:xt,text:st?dt:xt,d:!0,b:!1},end:bt}}var St=Px(e,H.end),Ct=St<e.length?Mx(e,St):St,wt=e.slice(H.end,St);if(wt.trim()){var{inline:Tt,inHTML:Et,c:Dt}=n;n.inline=!1,n.inHTML=!0,n.c=(n.c||0)+1,lt=PS(wt,n,r),n.inline=Tt,n.inHTML=Et,n.c=Dt}var Ot=e.slice(H.end,St);return{node:{type:K.htmlBlock,tag:it,attrs:Qx(H.attrs,it,r),i:H.whitespaceBeforeAttrs+H.rawAttrs,children:lt,a:Ot,text:wt,d:!0,b:!1},end:Ct}}function iS(e,t){if(e.charCodeAt(t)!==Ny)return 0;var n=t+1,r=e.length;if(e.charCodeAt(n)===Iy&&e.charCodeAt(n+1)===Oy&&e.charCodeAt(n+2)===Oy)return 2;if(e.charCodeAt(n)===Xy)return 3;if(e.charCodeAt(n)===Iy){var i=e.charCodeAt(n+1);if(i>=fb&&i<=pb)return 4;if(e.slice(n+1,n+8)===`[CDATA[`)return 5}for(var a=e.charCodeAt(n)===Qy,o=a?n+1:n,s=o;s<r;){var c=e.charCodeAt(s);if(c>=fb&&c<=pb||c>=mb&&c<=hb||c>=ub&&c<=db||c===Oy)s++;else break}if(s===o)return 0;var l=e.slice(o,s);if(dx.has(l.toLowerCase())){if(a)return 0;var u=e.charCodeAt(s);return+(u===q||u===J||u===Ty||u===Y||s>=r)}if(Zx.has(l.toLowerCase())){if(a){for(var d=s;d<r&&(e.charCodeAt(d)===q||e.charCodeAt(d)===J);)d++;return d<r&&e.charCodeAt(d)===Ty?6:0}var f=s<r?e.charCodeAt(s):-1;return f===q||f===J||f===Ty||f===Y||f===Qy||f===-1?6:0}if(a){for(var p=s;p<r&&(e.charCodeAt(p)===q||e.charCodeAt(p)===J);)p++;if(p<r&&e.charCodeAt(p)===Ty){var m=jx(e,t);if(e.slice(p+1,m).trim()===``)return 7}}else{var h=jx(e,t),g=yx(e,t);if(g&&g.end<=h&&e.slice(g.end,h).trim()===``)return 7}return 0}function aS(e,t,n){for(var r=0,i=e.length;r<i&&(e.charCodeAt(r)===q||e.charCodeAt(r)===J);)r++;for(;i>r&&(e.charCodeAt(i-1)===q||e.charCodeAt(i-1)===J);)i--;r<i&&e.charCodeAt(r)===nb&&r++,i>r&&e.charCodeAt(i-1)===nb&&(i-2<r||e.charCodeAt(i-2)!==Ay)&&i--;for(var a=[],o=r,s=!1,c=[],l=r;l<i;){var u=e.charCodeAt(l);if(u===Ay&&l+1<i){e.charCodeAt(l+1)===nb?(s||(s=!0,c=[]),c.push(e.slice(o,l)),c.push(`|`),l+=2,o=l):l+=2;continue}if(u===xy){for(var d=0;l<i&&e.charCodeAt(l)===xy;)d++,l++;for(var f=!1;l<i&&!f;){for(var p=0;l<i&&e.charCodeAt(l)===xy;)p++,l++;p===d?f=!0:p===0&&l++}continue}if(u===nb){var m=s?(c.push(e.slice(o,l)),c.join(``)):e.slice(o,l);a.push(m.trim()),l++,o=l,s=!1,c=[];continue}l++}var h=s?(c.push(e.slice(o,i)),c.join(``)):e.slice(o,i);return a.push(h.trim()),a.map(function(e){var r=e.indexOf(`\\|`)===-1?e:e.replace(/\\\|/g,`|`);return r?uS(r,!1,t,n):[]})}function oS(e,t,n,r){let i=jx(e,t);var a=e.indexOf(`|`,t);if(a<0||a>=i)return null;let o=Mx(e,i);if(o>=e.length)return null;let s=jx(e,o);if(!vx(e,o,s))return null;let c=e.slice(t,i),l=e.slice(o,s);for(var u=[],d=0,f=l.length;d<f&&(l.charCodeAt(d)===q||l.charCodeAt(d)===J);)d++;for(d<f&&l.charCodeAt(d)===nb&&d++;d<f;){for(;d<f&&(l.charCodeAt(d)===q||l.charCodeAt(d)===J);)d++;if(d>=f||l.charCodeAt(d)===nb)break;var p=l.charCodeAt(d)===Ry;for(p&&d++;d<f&&l.charCodeAt(d)===Oy;)d++;var m=d<f&&l.charCodeAt(d)===Ry;for(m&&d++,u.push(p&&m?`center`:m?`right`:p?`left`:null);d<f&&(l.charCodeAt(d)===q||l.charCodeAt(d)===J);)d++;d<f&&l.charCodeAt(d)===nb&&d++}let h=aS(c,n,r);if(u.length!==h.length)return null;let g=[],_=Mx(e,s);for(;_<e.length;){let t=jx(e,_),i=e.slice(_,t);if(zx(e,_,t))break;if(Rx(e,_,t),Ix<4){var v=e.charCodeAt(_+Lx);if(v===Ty||v===Ey||(v===Oy||v===jy||v===My)&&Hx(e,_))break;if(v===xy||v===Sy){for(var y=_+Lx,b=0;y<t&&e.charCodeAt(y)===v;)b++,y++;if(b>=3)break}}g.push(aS(i,n,r)),_=Mx(e,t)}if(r.optimizeForStreaming&&g.length===0)return null;for(var x=h.length,S=0;S<g.length;S++)if(g[S].length<x)for(;g[S].length<x;)g[S].push([]);else g[S].length>x&&(g[S].length=x);return{node:{type:K.table,header:h,cells:g,align:u},end:_}}function sS(e,t,n){if(Rx(e,t,jx(e,t)),Ix>3)return null;var r=t+Lx;if(e.charCodeAt(r)!==Cy)return null;if(r+1<e.length&&e.charCodeAt(r+1)===wy)return cS(e,r,n)||null;n.refs||={};var i=xx(e,r,n.refs);return i===null?null:{node:{type:K.refCollection},end:i}}function cS(e,t,n){var r=e.length;if(e.charCodeAt(t)!==Cy||t+1>=r||e.charCodeAt(t+1)!==wy)return null;for(var i=t+2,a=i;i<r&&e.charCodeAt(i)!==Fy;){if(e.charCodeAt(i)===Y)return null;i++}if(i>=r)return null;var o=(`^`+e.slice(a,i)).toLowerCase();if(i++,i>=r||e.charCodeAt(i)!==Ry)return null;for(i++;i<r&&(e.charCodeAt(i)===q||e.charCodeAt(i)===J);)i++;if(i<r&&e.charCodeAt(i)===Y)for(i++;i<r&&(e.charCodeAt(i)===q||e.charCodeAt(i)===J);)i++;var s=e.indexOf(`
1610
+ `,i);s<0&&(s=r);for(var c=e.slice(i,s).trim(),l=s<r?s+1:r;l<r;){var u=jx(e,l);if(Rx(e,l,u),Ix>=2&&!zx(e,l,u))c+=`
1611
+ `+e.slice(l,u),l=Mx(e,u);else if(zx(e,l,u)){var d=Mx(e,u);if(d<r&&(Rx(e,d,jx(e,d)),Ix>=2)){c+=`
1612
+ `,l=Mx(e,u);continue}break}else break}return n.refs[o]||(n.refs[o]={target:c,title:void 0}),{node:{type:K.footnote},end:l}}function lS(e,t,n,r){let i=t,a=0,o=0,s=-1;for(;i<e.length;){let t=s>=0?s:jx(e,i);if(s=-1,zx(e,i,t))break;if(Rx(e,i,t),Ix<4&&o>0&&!n.f){let n=e.charCodeAt(i+Lx);if(n===ky||n===Oy){let r=i+Lx;for(;r<t&&e.charCodeAt(r)===n;)r++;for(;r<t&&(e.charCodeAt(r)===q||e.charCodeAt(r)===J);)r++;if(r>=t){a=n===ky?1:2,i=Mx(e,t);break}}}o=t;let x=Mx(e,t);if(x<e.length){if(e.charCodeAt(x)===lb){var c=jx(e,x);i=Mx(e,c),o=c;continue}let t=jx(e,x);if(s=t,Rx(e,x,t),Ix<4){let a=e.charCodeAt(x+Lx);if(a===Ty){i=x;break}if(a===Ey){for(var l=x+Lx,u=0;l<t&&e.charCodeAt(l)===Ey&&u<=6;)u++,l++;if(u>=1&&u<=6&&(l>=t||e.charCodeAt(l)===q||e.charCodeAt(l)===J)){i=x;break}}if(a===xy||a===Sy){for(var d=x+Lx,f=0;d<t&&e.charCodeAt(d)===a;)f++,d++;if(f>=3){i=x;break}}if(a===Ny){var p=x+Lx+1,m=p<t?e.charCodeAt(p):0,h=m===Iy||m===Xy;if(!h&&m===Qy){for(var g=p+1,_=g;_<t&&(e.charCodeAt(_)>=fb&&e.charCodeAt(_)<=pb||e.charCodeAt(_)>=mb&&e.charCodeAt(_)<=hb||e.charCodeAt(_)>=ub&&e.charCodeAt(_)<=db||e.charCodeAt(_)===Oy);)_++;_>g&&(h=Zx.has(e.slice(g,_).toLowerCase()))}else if(!h){for(var v=p;v<t&&(e.charCodeAt(v)>=fb&&e.charCodeAt(v)<=pb||e.charCodeAt(v)>=mb&&e.charCodeAt(v)<=hb||e.charCodeAt(v)>=ub&&e.charCodeAt(v)<=db||e.charCodeAt(v)===Oy);)v++;if(v>p){var y=e.slice(p,v).toLowerCase();h=Zx.has(y)||dx.has(y)}}if(h&&rS(e,x,n,r)){i=x;break}}if(a===Oy||a===jy||a===tb){let n=x+Lx+1;if(n<t&&(e.charCodeAt(n)===q||e.charCodeAt(n)===J)&&Nx(e,n,t)<t&&!Hx(e,x)){i=x;break}}if(a>=ub&&a<=db){let n=x+Lx;for(;n<t&&e.charCodeAt(n)>=ub&&e.charCodeAt(n)<=db;)n++;if(n<t&&(e.charCodeAt(n)===Zy||e.charCodeAt(n)===ob)&&n-(x+Lx)===1&&e.charCodeAt(x+Lx)===49){var b=n+1;if(b<t&&(e.charCodeAt(b)===q||e.charCodeAt(b)===J)&&Nx(e,b,t)<t){i=x;break}}}if(a===nb){let n=Mx(e,t);if(n<e.length&&vx(e,n,jx(e,n))){i=x;break}}if((a===Oy||a===jy||a===My)&&Hx(e,x)){if(a!==Oy){i=x;break}let n=0,r=x+Lx;for(;r<t&&e.charCodeAt(r)===Oy;)n++,r++;for(;r<t&&(e.charCodeAt(r)===q||e.charCodeAt(r)===J);)r++;if(r<t){i=x;break}}}}i=Mx(e,t)}for(var x=a?o:i;x>t&&(e.charCodeAt(x-1)===Y||e.charCodeAt(x-1)===by||e.charCodeAt(x-1)===q||e.charCodeAt(x-1)===J);)x--;for(var S=t;S<x&&(e.charCodeAt(S)===q||e.charCodeAt(S)===J);)S++;if(S>=x)return null;for(var C=!1,w=S;w<x;w++)if(e.charCodeAt(w)===lb){C=!0;break}var T=C?e.slice(S,x).replace(/\u001E/g,``):e.slice(S,x);if(!T)return null;let E=uS(T,!0,n,r);if(a){let e=(r?.slugify||Db)(T);return{node:{type:K.heading,level:a,children:E,id:e},end:i}}return{node:{type:K.paragraph,children:E},end:i}}function uS(e,t,n,r){var i=n.k;if(!i){var a=n.e;n.e=t;var o=MS(e,0,e.length,n,r);return n.e=a,o}var s=[];return i.push({dest:s,text:e,breaks:t,inline:n.inline,inAnchor:n.inAnchor,inHTML:n.inHTML,htmlDepth:n.c,inList:n.inList,inBlockQuote:n.inBlockQuote,noSetext:n.f,depth:n.j}),s}function dS(e,t,n){if(e.charCodeAt(t)!==xy)return null;let r=Fx(e,t,n,96),i=t+r;for(;i<n;){let a=e.indexOf("`",i);if(a<0||a>=n)return null;let o=Fx(e,a,n,96);if(o===r){let n=e.slice(t+r,a);return n.indexOf(`
1613
+ `)!==-1&&(n=n.replace(/\n/g,` `)),n.length>0&&n[0]===` `&&n[n.length-1]===` `&&n.trim().length>0&&(n=n.slice(1,-1)),{node:{type:K.codeInline,text:n},end:a+o}}i=a+o}return null}function fS(e,t,n){if(e.charCodeAt(t)!==xy)return t;let r=Fx(e,t,n,96),i=t+r;for(;i<n;){let a=e.indexOf("`",i);if(a<0||a>=n)return t;let o=Fx(e,a,n,96);if(o===r)return a+o;i=a+o}return t}function pS(e,t,n){if(e.charCodeAt(t)!==Ny)return t;if(t+1<n&&e.charCodeAt(t+1)===Qy){let r=t+2;for(;r<n&&e.charCodeAt(r)!==Ty;)r++;return r<n?r+1:t}if(t+3<n&&e.charCodeAt(t+1)===Iy&&e.charCodeAt(t+2)===Oy&&e.charCodeAt(t+3)===Oy){let n=e.indexOf(`-->`,t+4);return n>=0?n+3:t}let r=t+1,i=r;for(;r<n;){let t=e.charCodeAt(r);if(t>=fb&&t<=pb||t>=mb&&t<=hb||t>=ub&&t<=db||t===Oy)r++;else break}if(r===i)return t;let a=e.slice(i,r).toLowerCase(),o=!1;for(;r<n;){let i=e.charCodeAt(r);if(i===Ty){r++;break}if(i===Qy&&r+1<n&&e.charCodeAt(r+1)===Ty){r+=2,o=!0;break}if(i===eb||i===$y){var s=i;for(r++;r<n&&e.charCodeAt(r)!==s;)r++;r<n&&r++;continue}if(i===Y)return t;r++}if(o||Ab(a))return r;let c=1;for(;r<n&&c>0;)if(e.charCodeAt(r)===Ny)if(r+1<n&&e.charCodeAt(r+1)===Qy){let t=r+2,i=t;for(;i<n&&(e.charCodeAt(i)>=fb&&e.charCodeAt(i)<=pb||e.charCodeAt(i)>=mb&&e.charCodeAt(i)<=hb);)i++;if(e.slice(t,i).toLowerCase()===a){for(;i<n&&e.charCodeAt(i)!==Ty;)i++;if(i<n&&i++,c--,c===0)return i}r=i}else{let t=r+1,i=t;for(;i<n&&(e.charCodeAt(i)>=fb&&e.charCodeAt(i)<=pb||e.charCodeAt(i)>=mb&&e.charCodeAt(i)<=hb);)i++;e.slice(t,i).toLowerCase()===a&&c++,r++}else r++;return r}function mS(e,t,n,r,i){if(e.charCodeAt(t)!==Sy||t+1>=n||e.charCodeAt(t+1)!==Sy)return null;let a=t+2;for(;a+1<n;){let o=e.charCodeAt(a);if(o===xy){let t=fS(e,a,n);if(t>a){a=t;continue}}if(o===Sy&&e.charCodeAt(a+1)===Sy){let n=e.slice(t+2,a),o=MS(n,0,n.length,r,i);return{node:{type:K.textFormatted,tag:`del`,children:o},end:a+2}}o===Ay&&a+1<n&&a++,a++}return null}function hS(e,t,n,r,i){if(e.charCodeAt(t)!==ky||t+1>=n||e.charCodeAt(t+1)!==ky)return null;let a=t+2;for(;a+1<n;){let o=e.charCodeAt(a);if(o===xy){let t=fS(e,a,n);if(t>a){a=t;continue}}if(o===ky&&e.charCodeAt(a+1)===ky&&a>t+2){let n=e.slice(t+2,a),o=MS(n,0,n.length,r,i);return{node:{type:K.textFormatted,tag:`mark`,children:o},end:a+2}}o===Ay&&a+1<n&&a++,a++}return null}function gS(e,t,n){return e<gb?!!(Ex(e)&Nb):zb.test(t[n])}function _S(e,t,n){return e<gb?!!(Ex(e)&jb):Bb.test(t[n])}function vS(e,t,n){var r=e.charCodeAt(t);if(r!==jy&&r!==My)return null;var i=Fx(e,t,n,r);if(i===0)return null;var a=t>0?e.charCodeAt(t-1):32,o=t+i<n?e.charCodeAt(t+i):32,s=_S(a,e,t-1),c=_S(o,e,t+i),l=t>0?gS(a,e,t-1):!1,u=t+i<n?gS(o,e,t+i):!1,d=!c&&(!u||s||l),f=!s&&(!l||c||u),p,m;return r===jy?(p=d,m=f):(p=d&&(!f||l),m=f&&(!d||u)),{len:i,canOpen:p,canClose:m}}function yS(e,t,n,r){if(t.length!==0){for(var i=e.length,a=Array(i),o=null,s=null,c=0;c<i;c++){var l={node:e[c],prev:s,next:null};s?s.next=l:o=l,a[c]=l,s=l}for(var u=Array(t.length),d=0;d<t.length;d++)u[d]=a[t[d].idx];for(var f=[],p=0;p<12;p++)f[p]=-1;for(var m=0;m<t.length;){var h=t[m];if(!h.active||!h.canClose){m++;continue}for(var g=(h.ch===jy?0:1)*6+h.len%3*2+ +!!h.canOpen,_=f[g]===void 0?-1:f[g],v=-1,y=m-1;y>_;y--){var b=t[y];if(!(!b.active||b.ch!==h.ch||!b.canOpen)&&!((h.canOpen||b.canClose)&&(b.len+h.len)%3==0&&b.len%3!=0)){v=y;break}}if(v<0){f[g]=m-1,!h.canOpen&&(h.active=!1),m++;continue}var x=t[v],S=x.len>=2&&h.len>=2,C=S?2:1;x.len-=C,h.len-=C;var w=u[v],T=u[m],E=w.node,D=T.node;E.text=E.text.slice(0,E.text.length-C),D.text=D.text.slice(C);for(var O=[],ee=w.next;ee&&ee!==T;)O.push(ee.node),ee=ee.next;var k={node:{type:K.textFormatted,tag:S?`strong`:`em`,children:O},prev:w,next:T};w.next=k,T.prev=k;for(var A=v+1;A<m;A++)t[A].active=!1;if(x.len===0&&(x.active=!1,E.text===``)){var j=w.prev;k.prev=j,j?j.next=k:o=k}if(h.len===0){if(h.active=!1,D.text===``){var M=T.next;k.next=M,M&&(M.prev=k)}}else continue;m++}for(var N=0,te=o;te;){var ne=te.node;if(ne.type===K.text){var P=ne;if(P.text===``){te=te.next;continue}if(N>0&&e[N-1].type===K.text){e[N-1].text+=P.text,te=te.next;continue}}e[N++]=ne,te=te.next}e.length=N}}function bS(e,t,n,r,i){let a=e.charCodeAt(t)===Iy,o=a?t+1:t;if(e.charCodeAt(o)!==Cy)return null;var s=e.indexOf(`]`,o+1);if(s<0||s>=n)return null;for(var c=o+1,l=1;c<n&&l>0;){var u=e.charCodeAt(c);if(u===Ay&&c+1<n){c+=2;continue}if(u===xy){var d=fS(e,c,n);if(d>c){c=d;continue}}if(u===Ny){var f=xS(e,c,n);if(f){c=f.end;continue}var p=pS(e,c,n);if(p>c){c=p;continue}}u===Cy?l++:u===Fy&&l--,c++}if(l!==0)return null;var m=c-1,h=e.slice(o+1,m),g=c<n?e.charCodeAt(c):0,_=!1;if(g===ab){var v=!0;for(c++;c<n&&(e.charCodeAt(c)===q||e.charCodeAt(c)===Y);)c++;var y=``,b=c;if(c<n&&e.charCodeAt(c)===Ny){for(c++,b=c;b<n&&e.charCodeAt(b)!==Ty;){if(e.charCodeAt(b)===Ay&&b+1<n){b+=2;continue}if(e.charCodeAt(b)===Y){v=!1;break}b++}v&&(b>=n||e.charCodeAt(b)!==Ty)&&(v=!1),v&&(y=e.slice(c,b),b++)}else if(v)if(r.g!==void 0&&c>=r.g)v=!1;else{for(var x=0,S=!1;b<n;){var C=e.charCodeAt(b);if(C===Ay&&b+1<n){b+=2;continue}if(C===ab)x++;else if(C===ob){if(S=!0,x===0)break;x--}else if(C===q||C===Y)break;b++}b>=n&&!S&&(r.g===void 0||c<r.g)&&(r.g=c),y=e.slice(c,b)}if(v){for(c=b;c<n&&(e.charCodeAt(c)===q||e.charCodeAt(c)===Y);)c++;var w;if(c<n){var T=e.charCodeAt(c);if(T===eb||T===$y||T===ab){var E=T===ab?41:T;c++;for(var D=c;c<n&&e.charCodeAt(c)!==E;)e.charCodeAt(c)===Ay&&c+1<n&&c++,c++;c>=n?v=!1:(w=e.slice(D,c),c++)}}if(v){for(;c<n&&(e.charCodeAt(c)===q||e.charCodeAt(c)===Y);)c++;(c>=n||e.charCodeAt(c)!==ob)&&(v=!1)}}if(v){c++,y=Dx(y),w!==void 0&&(w=xb(Dx(w)));var O=(i?.sanitizer||Cb)(y,a?`img`:`a`,a?`src`:`href`)===null?null:y;if(a){var ee=ES(MS(h,0,h.length,r,i));return{node:{type:K.image,target:O,alt:ee,title:w},end:c}}else{var k=r.inAnchor;r.inAnchor=!0;var A=k?[{type:K.text,text:h}]:MS(h,0,h.length,r,i);return r.inAnchor=k,!r.inAnchor&&TS(A)?null:{node:{type:K.link,target:O,title:w,children:A},end:c}}}else c=m+1,_=!0}var j=``,M=c;if(!_&&g===Cy){var N=c+1;M=N;for(var te=!1;M<n&&e.charCodeAt(M)!==Fy;){if(e.charCodeAt(M)===Ay&&M+1<n){M+=2;continue}if(e.charCodeAt(M)===Cy){te=!0;break}M++}if(te||M>=n)return null;var ne=e.slice(N,M);if(ne.trim())j=Tx(ne);else{if(wx(h))return null;j=Tx(h)}M+=1}else{if(wx(h))return null;j=Tx(h)}var P=r.refs[j];if(!P)return null;if(a)return{node:{type:K.image,target:P.target,alt:ES(MS(h,0,h.length,r,i)),title:P.title},end:M};var re=r.inAnchor;r.inAnchor=!0;var A=re?[{type:K.text,text:h}]:MS(h,0,h.length,r,i);return r.inAnchor=re,!r.inAnchor&&TS(A)?null:{node:{type:K.link,target:P.target,title:P.title,children:A},end:M}}function xS(e,t,n){if(e.charCodeAt(t)!==Ny)return null;for(var r=t+1;r<n;){var i=e.charCodeAt(r);if(i===Ty)break;if(i===q||i===Y||i===by||i===Ny)return null;r++}if(r>=n||e.charCodeAt(r)!==Ty)return null;var a=e.slice(t+1,r);return a.match(/^([a-zA-Z][a-zA-Z0-9+.-]{1,31}):([^\x00-\x20]*)$/)?{node:{type:K.link,target:a,title:void 0,children:[{type:K.text,text:a}]},end:r+1}:a.indexOf(`@`)!==-1&&/^[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])?)*$/.test(a)?{node:{type:K.link,target:`mailto:`+a,title:void 0,children:[{type:K.text,text:a}]},end:r+1}:null}function SS(e,t,n,r){if(e.charCodeAt(t)!==Cy||t+1>=n||e.charCodeAt(t+1)!==wy)return null;let i=t+2;for(;i<n&&e.charCodeAt(i)!==Fy&&e.charCodeAt(i)!==Y;)i++;if(i>=n||e.charCodeAt(i)!==Fy)return null;let a=e.slice(t+2,i);return a?{node:{type:K.footnoteReference,target:`#`+Db(a),text:a},end:i+1}:null}function CS(e,t,n,r){if(r.disableBareUrls)return null;var i=``,a=!1,o=e.charCodeAt(t);if(o===Vy||o===72?t+8<=n&&e.charCodeAt(t+1)===Uy&&e.charCodeAt(t+2)===Uy&&e.charCodeAt(t+3)===Wy&&(e.charCodeAt(t+4)===Gy&&e.charCodeAt(t+5)===Ry&&e.charCodeAt(t+6)===Qy&&e.charCodeAt(t+7)===Qy?i=`https://`:e.charCodeAt(t+4)===Ry&&e.charCodeAt(t+5)===Qy&&e.charCodeAt(t+6)===Qy&&(i=`http://`)):o===By||o===70?t+6<=n&&e.charCodeAt(t+1)===Uy&&e.charCodeAt(t+2)===Wy&&e.charCodeAt(t+3)===Ry&&e.charCodeAt(t+4)===Qy&&e.charCodeAt(t+5)===Qy&&(i=`ftp://`):(o===Hy||o===87)&&t+4<=n&&e.charCodeAt(t+1)===Hy&&e.charCodeAt(t+2)===Hy&&e.charCodeAt(t+3)===Zy&&(i=`www.`,a=!0),!i)return null;let s=t+i.length;for(;s<n;){let t=e.charCodeAt(s);if(t===q||t===Y||t===J||t===by||t===Ny||t===Ty)break;s++}for(var c=0,l=0,u=t;u<s;u++){var d=e.charCodeAt(u);d===ab?c++:d===ob&&l++}let f=s;for(;f>t+i.length;){let n=e.charCodeAt(f-1);if(n===Zy||n===Jy||n===Ry||n===Iy||n===Xy||n===ob||n===jy||n===My||n===Sy){if(n===ob){if(c>=l)break;l--}f--}else if(n===Yy){for(var p=f-2;p>t&&(e.charCodeAt(p)>=fb&&e.charCodeAt(p)<=pb||e.charCodeAt(p)>=mb&&e.charCodeAt(p)<=hb||e.charCodeAt(p)>=ub&&e.charCodeAt(p)<=db);)p--;p>=t&&e.charCodeAt(p)===Ly?f=p:f--}else break}if(f<=t+i.length)return null;var m=t+(a?4:i.length),h=e.indexOf(`/`,m);if((h<0||h>f)&&(h=f),a&&e.indexOf(`.`,m)===-1)return null;for(var g=-1,_=-1,v=h-1;v>=m;v--)if(e.charCodeAt(v)===Zy)if(g<0)g=v;else{_=v;break}for(var v=_>=0?_+1:m;v<h;v++)if(e.charCodeAt(v)===My)return null;var y=e.slice(t,f),b=a?`http://`+y:y;return{node:{type:K.link,target:b,title:void 0,children:[{type:K.text,text:y}]},end:f}}function wS(e,t,n,r){if(r.disableBareUrls)return null;for(var i=t,a=i;i<n;){var o=e.charCodeAt(i);if(o>=fb&&o<=pb||o>=mb&&o<=hb||o>=ub&&o<=db||o===Zy||o===Iy||o===Ey||o===36||o===Dy||o===Ly||o===$y||o===jy||o===tb||o===Qy||o===ky||o===Xy||o===wy||o===My||o===xy||o===rb||o===nb||o===ib||o===Sy||o===Oy)i++;else break}if(i===a||i>=n||e.charCodeAt(i)!==Py)return null;i++;for(var s=i,c=-1,l=i;i<n;){var o=e.charCodeAt(i);if(o>=fb&&o<=pb||o>=mb&&o<=hb||o>=ub&&o<=db)i++;else if((o===Oy||o===My)&&i>s)i++;else if(o===Zy){if(i===s)break;var u=e.charCodeAt(i-1);if(u===Oy||u===My||i-l>63)break;if(i+1<n){var d=e.charCodeAt(i+1);if(d>=fb&&d<=pb||d>=mb&&d<=hb||d>=ub&&d<=db)c=i,l=i+1,i++;else break}else break}else break}if(i-l>63||c<0)return null;var f=e.charCodeAt(i-1);if(!(f>=fb&&f<=pb||f>=mb&&f<=hb||f>=ub&&f<=db)||i<=c+1)return null;for(var p=-1,m=c-1;m>=s;m--)if(e.charCodeAt(m)===Zy){p=m;break}for(var m=p>=0?p+1:s;m<i;m++)if(e.charCodeAt(m)===My)return null;var h=e.slice(t,i);return{node:{type:K.link,target:`mailto:`+h,title:void 0,children:[{type:K.text,text:h}]},end:i}}function TS(e){for(var t=0;t<e.length;t++)if(e[t].type===K.link||`children`in e[t]&&Array.isArray(e[t].children)&&TS(e[t].children))return!0;return!1}function ES(e){for(var t=``,n=0;n<e.length;n++){var r=e[n];r.type===K.text?t+=r.text:r.type===K.breakLine?t+=` `:r.type===K.codeInline?t+=r.text:`children`in r&&Array.isArray(r.children)?t+=ES(r.children):r.type===K.image&&(t+=r.alt||``)}return t}function DS(e){return{type:K.text,text:e}}function OS(e,t,n){var r=t+1;if(r>=n)return-1;if(e.charCodeAt(r)===Ey){r++;var i=r<n&&(e.charCodeAt(r)===sb||e.charCodeAt(r)===cb);i&&r++;for(var a=r,o=i?6:7;r<n&&r-a<=o;){var s=e.charCodeAt(r);if(!(s>=ub&&s<=db||i&&(s>=fb&&s<=zy||s>=mb&&s<=By)))break;r++}return r===a||r-a>o?-1:r<n&&e.charCodeAt(r)===Yy?r+1:-1}for(var c=r;r<n&&r-c<48;){var l=e.charCodeAt(r);if(l>=fb&&l<=pb||l>=mb&&l<=hb||l>=ub&&l<=db){r++;continue}break}return r===c?-1:r<n&&e.charCodeAt(r)===Yy?r+1:-1}function kS(e,t,n,r,i){if(e.charCodeAt(t)!==Ny)return null;var a=t+1;if(a>=n)return null;var o=e.charCodeAt(a);if(o===Iy&&a+1<n&&e.charCodeAt(a+1)===Oy&&a+2<n&&e.charCodeAt(a+2)===Oy){var s=a+3;if(s<n&&e.charCodeAt(s)===Ty)return{node:{type:K.htmlComment,text:``,l:!0},end:s+1};if(s+1<n&&e.charCodeAt(s)===Oy&&e.charCodeAt(s+1)===Ty)return{node:{type:K.htmlComment,text:`-`,l:!0},end:s+2};var c=e.indexOf(`-->`,s);return c!==-1&&c<=n-3?{node:{type:K.htmlComment,text:e.slice(t+4,c),l:!1},end:c+3}:null}if(o===Xy){var l=e.indexOf(`?>`,a+1);return l!==-1&&l<n?{node:{type:K.htmlSelfClosing,tag:`?`,attrs:{},a:e.slice(t,l+2),b:!1},end:l+2}:null}if(o===Iy&&a+1<n){var u=e.charCodeAt(a+1);if(u===Cy&&e.slice(a+1,a+8)===`[CDATA[`){var d=e.indexOf(`]]>`,a+8);return d!==-1&&d<n?{node:{type:K.htmlSelfClosing,tag:`![CDATA[`,attrs:{},a:e.slice(t,d+3),b:!1},end:d+3}:null}if(u>=fb&&u<=pb){var f=e.indexOf(`>`,a+2);return f!==-1&&f<n?{node:{type:K.htmlSelfClosing,tag:`!`+e.slice(a+1,f),attrs:{},a:e.slice(t,f+1),b:!1},end:f+1}:null}}if(o===Qy){var p=a+1;if(p>=n)return null;var m=e.charCodeAt(p);if(!(m>=fb&&m<=pb||m>=mb&&m<=hb))return null;for(p++;p<n;){var h=e.charCodeAt(p);if(h>=fb&&h<=pb||h>=mb&&h<=hb||h>=ub&&h<=db||h===Oy)p++;else break}for(;p<n&&(e.charCodeAt(p)===q||e.charCodeAt(p)===J||e.charCodeAt(p)===Y);)p++;if(p<n&&e.charCodeAt(p)===Ty){var g=e.slice(a+1,p).trim();return{node:{type:K.htmlSelfClosing,tag:g,attrs:{},a:e.slice(t,p+1),b:!0},end:p+1}}return null}if(!(o>=fb&&o<=pb||o>=mb&&o<=hb))return null;var _=yx(e,t);if(!_)return null;var v=_.tag,y=v.toLowerCase();if(_.selfClosing||Ab(v))return{node:{type:K.htmlSelfClosing,tag:v,attrs:Qx(_.attrs,v,i),a:e.slice(t,_.end),b:!1},end:_.end};var b=dx.has(y),x=nS(e.slice(0,n),_.end,v);if(x===-1)return{node:{type:K.htmlSelfClosing,tag:v,attrs:Qx(_.attrs,v,i),a:e.slice(t,_.end),b:!1},end:_.end};var S=eS(e,`</`+y,x),C=e.slice(_.end,S),w=[];if(b)C.trim()&&(w=[{type:K.text,text:C}]);else{var T=C.trim();if(T){var{inAnchor:E,inline:D,e:O}=r;y===`a`&&(r.inAnchor=!0),r.e=!1,T.indexOf(`
1614
+
1615
+ `)!==-1||/^#{1,6}\s/.test(T)?(r.inline=!1,w=PS(T,r,i)):w=MS(T,0,T.length,r,i),r.inAnchor=E,r.inline=D,r.e=O}}return{node:{type:K.htmlBlock,tag:v,attrs:Qx(_.attrs,v,i),i:_.rawAttrs,children:w,a:void 0,text:C,d:!1,b:!1},end:x}}var AS=200,jS=0;function MS(e,t,n,r,i){if(jS++,jS>AS)return jS--,[{type:K.text,text:e.slice(t,n)}];var a=r.g;r.g=void 0;let o=r;if(i.optimizeForStreaming){let r=function(e,t){for(var n=1,r=t+1;r<e.length;r++){var i=e.charCodeAt(r);if(i===Cy)n++;else if(i===Fy&&(n--,n===0))return r}return-1},i=e.slice(t,n),a=i;for(var s=0,c=0,l=0,u=0,d=0,f=-1,p=-1,m=-1,h=-1,g=-1,_=0;_<i.length;_++){var v=i.charCodeAt(_);v===jy?_+1<i.length&&i.charCodeAt(_+1)===jy?(s++,f=_,_++):(c++,p=_):v===My?_+1<i.length&&i.charCodeAt(_+1)===My?(l++,m=_,_++):(u++,h=_):v===Sy&&_+1<i.length&&i.charCodeAt(_+1)===Sy&&(d++,g=_,_++)}var y=[];d%2==1&&g>=0&&y.push([g,2]),l%2==1&&m>=0&&y.push([m,2]),u%2==1&&h>=0&&y.push([h,1]),s%2==1&&f>=0&&y.push([f,2]),c%2==1&&p>=0&&y.push([p,1]),y.sort(function(e,t){return t[0]-e[0]});for(var b=0;b<y.length;b++){var x=y[b][0],S=y[b][1];i=i.slice(0,x)+i.slice(x+S)}let o=0,ae=-1;for(let e=0;e<i.length;e++)i.charCodeAt(e)===xy&&(o++,ae=e);if(o%2==1&&ae!==-1){let e=!1,t=-1,n=0;for(;n<i.length;)i.charCodeAt(n)===xy&&(e?(e=!1,t=-1):(t=n,e=!0)),n++;e&&t!==-1&&(i=i.slice(0,t))}for(var C=!0;C;){C=!1;for(var w=-1,T=-1,E=-1,D=!1,O=0;O<i.length;O++)if(i.charCodeAt(O)===Cy&&(O===0||i.charCodeAt(O-1)!==Ay)){var ee=O>0&&i.charCodeAt(O-1)===Iy,k=ee?O-1:O,A=r(i,O);if(A===-1)w=k,D=ee,T=O+1,E=i.length;else{var j=A+1;if(j>=i.length)w=k,D=ee,T=O+1,E=A;else if(i.charCodeAt(j)===ab){var M=i.indexOf(`)`,j+1);M===-1?(w=k,D=ee,T=O+1,E=A,O=i.length):O=M}else if(i.charCodeAt(j)===Cy){var N=i.indexOf(`]`,j+1);N===-1?(w=k,D=ee,T=O+1,E=A,O=i.length):O=N}else O=A}}if(w>=0){var te=D?``:i.slice(T,E);i=i.slice(0,w)+te,C=!0}}let oe=i.match(/<([A-Z][A-Za-z0-9]*)(?:\s[^>]*)?>([^<]*)$/);if(oe&&oe.index!==void 0){var ne=oe[0].length-oe[2].length;if(!(ne>=2&&oe[0].charCodeAt(ne-2)===Qy)){for(var P=!1,re=0,ie=0;ie<oe.index;ie++)i.charCodeAt(ie)===xy&&re++;if(P=re%2==1,!P){let e=oe[1];$x(i,`</`+e,0)===-1&&(i=i.slice(0,oe.index)+oe[2])}}}i!==a&&(e=e.slice(0,t)+i,n=t+i.length)}let ae=[];var oe=[];let F=t;var I=``,L=i.disableAutoLink||i.disableBareUrls||o.inAnchor?-1:e.indexOf(`@`,t);for(L>=n&&(L=-1);t<n;){let r=e.charCodeAt(t),a=null;if(r===xy){if(a=dS(e,t,n),!a){var se=Fx(e,t,n,xy);t+=se-1}}else if(r===jy||r===My){var ce=vS(e,t,n);if(ce){if(ce.canOpen||ce.canClose){(I||t>F)&&(ae.push(DS(I+e.slice(F,t))),I=``);var le=DS(e.slice(t,t+ce.len));oe.push({idx:ae.length,ch:r,len:ce.len,canOpen:ce.canOpen,canClose:ce.canClose,active:!0}),ae.push(le),t+=ce.len,F=t;continue}t+=ce.len-1}}else if(r===Sy)a=mS(e,t,n,o,i);else if(r===ky)a=hS(e,t,n,o,i);else if(r===Cy)t+1<n&&e.charCodeAt(t+1)===wy&&(a=SS(e,t,n,o)),a||=bS(e,t,n,o,i);else if(r===Iy&&t+1<n&&e.charCodeAt(t+1)===Cy)a=bS(e,t,n,o,i);else if(r===Ny)a=xS(e,t,n),!a&&!i.disableParsingRawHTML&&!i.ignoreHTMLBlocks&&(a=kS(e,t,n,o,i));else if(r===Ly){var ue=OS(e,t,n);if(ue!==-1){var de=e.slice(t,ue),R=xb(de);if(R!==de){I=I+e.slice(F,t)+R,t=ue,F=ue;continue}}}else if((r===Vy||r===Hy||r===By)&&!o.inAnchor&&!i.disableAutoLink&&(t===0||e.charCodeAt(t-1)!==Ny)){var fe=t+1<n?e.charCodeAt(t+1):0;(r===Vy&&fe===Uy||r===By&&fe===Uy||r===Hy&&fe===Hy)&&(a=CS(e,t,n,i))}if(!a&&L>=0&&L-t<=64&&!o.inAnchor&&!i.disableAutoLink&&!i.disableBareUrls&&(r>=fb&&r<=pb||r>=mb&&r<=hb||r>=ub&&r<=db)&&(a=wS(e,t,n,i),!a&&t>=L&&(L=e.indexOf(`@`,t+1),L>=n&&(L=-1))),r===Y&&o.e){var pe=!1,me=0;if(t>F&&e.charCodeAt(t-1)===Ay)pe=!0,me=1;else{for(var he=0,ge=t-1;ge>=F&&e.charCodeAt(ge)===q;)he++,ge--;he>=2&&(pe=!0,me=he)}if(pe){for((I||t-me>F)&&(ae.push(DS(I+e.slice(F,t-me))),I=``),ae.push({type:K.breakLine}),t++;t<n&&e.charCodeAt(t)===q;)t++;F=t;continue}var _e=t>F&&e.charCodeAt(t-1)===q,ve=t+1<n&&e.charCodeAt(t+1)===q;if(_e||ve){for(var ye=t;ye>F&&e.charCodeAt(ye-1)===q;)ye--;for(I+=e.slice(F,ye)+`
1616
+ `,t++;t<n&&e.charCodeAt(t)===q;)t++;F=t;continue}}if(a)(I||t>F)&&(ae.push(DS(I+e.slice(F,t))),I=``),ae.push(a.node),t=a.end,F=t;else{if(r===Ay&&t+1<n&&Ex(e.charCodeAt(t+1))&Nb){(I||t>F)&&(ae.push(DS(I+e.slice(F,t))),I=``),ae.push(DS(e[t+1])),t+=2,F=t;continue}if(t++,L<0||L-t>64)for(;t<n&&!(L>=0&&L-t<=64);){var be=e.charCodeAt(t);if(be<gb&&!hx[be])t++;else break}}}return(I||n>F)&&(ae.push(DS(I+e.slice(F,n))),I=``),oe.length>0&&yS(ae,oe,r,i),r.g=a,jS--,ae}var NS=500;function PS(e,t,n){var r=t.j||0;if(r>NS)return[{type:K.text,text:e}];if(t.j=r+1,n.optimizeForStreaming&&!t.m){var i=e.length;i>0&&e.charCodeAt(i-1)===Y&&i--;for(var a=i;a>0&&e.charCodeAt(a-1)!==Y;)a--;if(a>0&&e.charCodeAt(a)===nb){for(var o=!0,s=a;s<i;s++){var c=e.charCodeAt(s);if(c!==q&&c!==J&&c!==Oy&&c!==Ry&&c!==nb){o=!1;break}}if(o){for(var l=a-1;l>0&&e.charCodeAt(l-1)!==Y;)l--;e.charCodeAt(l)===nb&&(e=e.slice(0,l).trimEnd())}}var u=e.trim(),d=u.lastIndexOf(`
1617
+ `),f=d===-1?u:u.slice(d+1);if(f.length>0&&f.charCodeAt(0)===nb){for(var p=!1,m=!1,h=1;h<f.length;h++){var g=f.charCodeAt(h);g===nb&&(p=!0),g===Oy&&(m=!0)}p&&m&&(e=d===-1?``:e.slice(0,e.lastIndexOf(f)).trimEnd())}for(var _=-1,v=-1,y=-1,b=e.length-1;b>=0;b--)if(e.charCodeAt(b)===Ny){var x=b+1<e.length?e.charCodeAt(b+1):0;if(x>=fb&&x<=pb||x>=mb&&x<=hb){for(var S=b+2;S<e.length;){var C=e.charCodeAt(S);if(C>=fb&&C<=pb||C>=mb&&C<=hb||C>=ub&&C<=db)S++;else break}for(var w=S;w<e.length&&e.charCodeAt(w)!==Ty;)w++;if(w<e.length&&e.charCodeAt(w-1)!==Qy){for(var T=!1,E=w+1;E<e.length;E++)if(e.charCodeAt(E)===Ny){T=!0;break}T||(_=b,v=S,y=w+1)}}break}if(_>=0){for(var D=0,O=0;O<_;O++)e.charCodeAt(O)===xy&&D++;if(D%2==0){var ee=e.slice(_+1,v);$x(e,`</`+ee,0)===-1&&(e=e.slice(0,_)+e.slice(y))}}for(var k=e.length;k>0&&e.charCodeAt(k-1)===Y;)k--;if(k>0){for(var A=k;A>0&&e.charCodeAt(A-1)!==Y;)A--;for(var j=A,M=0;j<k&&e.charCodeAt(j)===q&&M<3;)j++,M++;if(A>0&&j<k&&Vx(e,j,k)){for(var N=A-1,te=N;te>0&&e.charCodeAt(te-1)!==Y;)te--;zx(e,te,N)||(e=e.slice(0,A).trimEnd())}}var ne=e.length;if(ne>0){for(var P=e.lastIndexOf(`
1618
+ `),re=P===-1?0:P+1,ie=ne,ae=re,oe=0;ae<ie&&e.charCodeAt(ae)===q&&oe<3;)ae++,oe++;if(ae<ie){var F=e.charCodeAt(ae),I=!1;if(F===jy||F===Oy||F===tb){var L=ae+1;if(L>=ie||e.charCodeAt(L)===q||e.charCodeAt(L)===J){for(var se=L;se<ie&&(e.charCodeAt(se)===q||e.charCodeAt(se)===J);)se++;se>=ie&&(I=!0)}}else if(F>=ub&&F<=db){for(var ce=ae;ce<ie&&e.charCodeAt(ce)>=ub&&e.charCodeAt(ce)<=db;)ce++;if(ce<ie&&(e.charCodeAt(ce)===Zy||e.charCodeAt(ce)===ob)){var le=ce+1;if(le>=ie||e.charCodeAt(le)===q||e.charCodeAt(le)===J){for(var ue=le;ue<ie&&(e.charCodeAt(ue)===q||e.charCodeAt(ue)===J);)ue++;ue>=ie&&(I=!0)}}}I&&(e=e.slice(0,re).trimEnd())}}}if(t.inline)return MS(e,0,e.length,t,n);let de=[],R=0,fe=e.length;if(R===0&&!n.disableFrontmatter&&e.startsWith(`---`)){let t=vb(e);if(t&&t.hasValidYaml){if(n.preserveFrontmatter!==!1){let n=e.slice(0,t.endPos).trimEnd();de.push({type:K.frontmatter,text:n})}R=t.endPos}}for(;R<fe;){for(var pe=e.indexOf(`
1619
+ `,R),me=pe<0?fe:pe;R<fe&&zx(e,R,me);)R=me<fe?me+1:me,R<fe&&(pe=e.indexOf(`
1620
+ `,R),me=pe<0?fe:pe);if(R>=fe)break;var he=e.charCodeAt(R)===lb;Rx(e,R,me);let r=null;if(Ox=e,kx=R,Ax=me,!he&&Ix>=4&&!t.inHTML)r=Wx(e,R);else if(!he){let i=R+Lx,a=e.charCodeAt(i);a===Ey?r=Bx(e,R,t,n):a===Ty?r=Gx(e,R,t,n):a===xy||a===Sy?r=Ux(e,R,t):a===Oy||a===jy||a===My?(r=Hx(e,R),!r&&(r=Xx(e,R,t,n))):a===tb||a>=ub&&a<=db?r=Xx(e,R,t,n):a===Ny?r=rS(e,R,t,n):a===nb?r=oS(e,R,t,n):a===Cy&&(r=sS(e,R,t))}if(!r){for(var ge=!1,_e=R;_e<me;_e++)if(e.charCodeAt(_e)===nb){ge=!0;break}ge&&(r=oS(e,R,t,n))}if(r||=lS(e,R,t,n),r)r.node.type!==K.refCollection&&de.push(r.node),R=r.end;else{var ve=e.indexOf(`
1621
+ `,R);R=ve<0?fe:ve+1}}return t.j=r,de}function FS(e,t){e.charCodeAt(0)===65279&&(e=e.slice(1));let n={inline:!1,inAnchor:!1,inHTML:!1,inList:!1,inBlockQuote:!1,refs:{}},r={...t,slugify:t?.slugify?e=>t.slugify(e,Db):Db,sanitizer:t?.sanitizer||Cb,tagfilter:t?.tagfilter!==!1};return LS(e,n,r)}function IS(e,t,n,r){var i=yx(e,t);return i?{tagName:i.tag,tagLower:i.tag.toLowerCase(),attrs:i.rawAttrs,whitespaceBeforeAttrs:i.whitespaceBeforeAttrs,isSelfClosing:i.selfClosing,hasSpaceBeforeSlash:i.hasSpaceBeforeSlash,isClosing:i.isClosing,hasNewline:i.whitespaceBeforeAttrs.includes(`
1622
+ `)||i.rawAttrs.includes(`
1623
+ `),endPos:i.end}:null}function LS(e,t,n){jS=0,e=Hb(e),!t.refs&&(t.refs={}),(n.optimizeForStreaming||t.inline)&&(t.m=bx(e,t.refs,n));var r=!t.k;r&&(t.k=[],t.h=[]);let i=PS(e,t,n);if(r){for(var a=t.k,o={inline:t.inline,inAnchor:t.inAnchor,inHTML:t.inHTML,htmlDepth:t.c,inList:t.inList,inBlockQuote:t.inBlockQuote,noSetext:t.f,depth:t.j},s=0;s<a.length;s++){var c=a[s];t.inline=c.inline,t.inAnchor=c.inAnchor,t.inHTML=c.inHTML,t.c=c.htmlDepth,t.inList=c.inList,t.inBlockQuote=c.inBlockQuote,t.f=c.noSetext,t.j=c.depth,t.e=c.breaks;var l=MS(c.text,0,c.text.length,t,n);t.e=!1;for(var u=0;u<l.length;u++)c.dest.push(l[u])}t.inline=o.inline,t.inAnchor=o.inAnchor,t.inHTML=o.inHTML,t.c=o.htmlDepth,t.inList=o.inList,t.inBlockQuote=o.inBlockQuote,t.f=o.noSetext,t.j=o.depth;for(var d=t.h,f=0;f<d.length;f++)for(var p=d[f],m=0;m<p.src.length;m++){var h=p.src[m];if(p.unwrap&&h.type===K.paragraph)for(var g=h.children,_=0;_<g.length;_++)p.dest.push(g[_]);else p.dest.push(h)}t.k=void 0,t.h=void 0}return Wb(t.refs)?[{type:K.refCollection,refs:t.refs},...i]:i}var RS=typeof document<`u`,zS=e=>Array.isArray(e)?e:[e],BS=e=>typeof e==`function`||typeof e==`object`&&!!e&&`render`in e;function VS(e,t,n,r,i,a,o,s){switch(e.type){case K.blockQuote:{let i={},o=e.children;return e.alert&&(i.class=`markdown-alert-`+a(e.alert.toLowerCase(),Db),o=[Gb(e.alert),...o]),r(`blockquote`,i,...zS(t(o,n)))}case K.breakLine:return r(`br`,{});case K.breakThematic:return r(`hr`,{});case K.frontmatter:return s.preserveFrontmatter?r(`pre`,{},e.text):null;case K.codeBlock:{let t=e.lang?xb(e.lang):``;return r(`pre`,{},r(`code`,{...e.attrs||{},class:t?`language-${t} lang-${t}`:``},e.text))}case K.codeInline:return r(`code`,{},e.text);case K.footnoteReference:return r(`a`,{href:i(e.target,`a`,`href`)},r(`sup`,{},e.text));case K.gfmTask:return r(`input`,{checked:e.completed,readOnly:!0,type:`checkbox`});case K.heading:return r(`h${e.level}`,{id:e.id},...zS(t(e.children,n)));case K.htmlBlock:{let c=e;if(s.tagfilter&&ox(c.tag))return r(`span`,{},typeof c.a==`string`?c.a:`<${c.tag}${$b(c.attrs)}>`);if(c.a&&c.d){let l=c.tag.toLowerCase();if(_x(l)){let t=Qb(c.a,l,s.tagfilter);return/<[a-z][^>]{0,100}>/i.test(c.a)?r(e.tag,{...e.attrs,innerHTML:t}):r(e.tag,{...e.attrs},t)}if(/<\/?pre\b/i.test(c.a)){let t=s.tagfilter?sx(c.a):c.a;return r(e.tag,{...e.attrs,innerHTML:t})}let u={slugify:e=>a(e,Db),sanitizer:i,tagfilter:!0},d=c.a.replace(/>\s+</g,`><`).replace(/\n+/g,` `).trim();if(RegExp(`^<${c.tag}(\\s[^>]*)?>(\\s*</${c.tag}>)?$`,`i`).test(d))return r(e.tag,{...e.attrs});let f=LS(d,{inline:!1,refs:o,inHTML:!1},u);if(Xb(f),Yb(d,c.tag))return t(f.flatMap(Jb),n);let p=Zb(f,l);if(p.found&&p.afterClose.length>0)return[r(e.tag,{...e.attrs},...zS(t(p.beforeClose.flatMap(Jb),n))),...zS(t(p.afterClose.flatMap(Jb),n))];let m=t(f.flatMap(Jb),n);return r(e.tag,{...e.attrs},...zS(m))}return Ab(e.tag)?r(e.tag,{...e.attrs}):r(e.tag,{...e.attrs},...e.children?zS(t(e.children,n)):[])}case K.htmlSelfClosing:{let t=e;return s.tagfilter&&ox(t.tag)?r(`span`,{},typeof t.a==`string`?t.a:`<${t.tag}${$b(t.attrs)} />`):r(t.tag,{...t.attrs})}case K.image:return r(`img`,{alt:e.alt&&e.alt.length>0?e.alt:void 0,title:e.title||void 0,src:i(e.target,`img`,`src`)});case K.link:{let i={};return e.target!=null&&(i.href=nx(e.target)),e.title&&(i.title=e.title),r(`a`,i,...zS(t(e.children,n)))}case K.table:{let i=e;return r(`table`,{},r(`thead`,{},r(`tr`,{},...i.header.map(function(e,a){return r(`th`,{style:i.align[a]==null?{}:{textAlign:i.align[a]}},...zS(t(e,n)))}))),i.cells.length>0?r(`tbody`,{},...i.cells.map(function(e,a){return r(`tr`,{},...e.map(function(e,a){return r(`td`,{style:i.align[a]==null?{}:{textAlign:i.align[a]}},...zS(t(e,n)))}))})):null)}case K.text:return e.text;case K.textFormatted:return r(e.tag,{},...zS(t(e.children,n)));case K.orderedList:case K.unorderedList:return r(e.type===K.orderedList?`ol`:`ul`,{start:e.type===K.orderedList?e.start:void 0},...e.items.map(function(e,i){return r(`li`,{},...zS(t(e,n)))}));case K.paragraph:return r(`p`,{},...zS(t(e.children,n)));case K.ref:return null;default:return null}}var HS=(e,t,n,r,i,a)=>{let o=(o,s,c)=>{let l=()=>VS(o,e=>s(zS(e)),c,t,n,r,i,a);return e?e(l,o,s,c):l()},s=e=>e.map(e=>`text`in e?e.text:``),c=(e,t={})=>{let n=(t.renderDepth||0)+1;if(n>2500)return s(e);let r=[],i=!1;for(let a=0;a<e.length;a++){let s=o(e[a],c,{...t,renderDepth:n}),l=typeof s==`string`;if(l&&i)r[r.length-1]+=s;else if(s!==null)if(Array.isArray(s))for(let e=0;e<s.length;e++)r.push(s[e]);else r.push(s);i=l}return r};return c},US=(e,t)=>{let n=tx(t,e,void 0);if(!n)return e;if(BS(n))return n;let r=tx(t,`${e}.component`,e);return BS(r),r};function WS(e,t){let n={...t||{}};n.overrides=n.overrides||{};let r=n.slugify||Db,i=n.sanitizer||Cb,a=e=>GS(e,{...n,wrapper:null});function o(e,t,...r){let i=tx(n.overrides,`${e}.props`,{}),o=t||{};for(let e in o){let t=o[e];if(typeof t==`string`&&t.length>0&&t[0]===`<`&&(cx.test(t)||lx.test(t)||IS(t,0))){let n=a(t.trim());o[e]=e===`innerHTML`&&Array.isArray(n)?n[0]:n}}let s=US(e,n.overrides),c=rx(o?.class,i.class||void 0)||void 0,l={...o,...i};return c&&(l.class=c),o.innerHTML&&i.innerHTML===void 0&&(l.innerHTML=o.innerHTML,delete o.innerHTML),qS(s,l,...r)}let s=n.createElement||((e,t,...n)=>qS(e,t||{},...n)),c={slugify:e=>r(e,Db),sanitizer:i,tagfilter:n.tagfilter!==!1,disableAutoLink:n.disableAutoLink,disableParsingRawHTML:n.disableParsingRawHTML,enforceAtxHeadings:n.enforceAtxHeadings,forceBlock:n.forceBlock,forceInline:n.forceInline,preserveFrontmatter:n.preserveFrontmatter},l=e[0]&&e[0].type===K.refCollection?e[0].refs:{},u=HS(n.renderRule,o,i,r,l,n),d=u(e,{inline:n.forceInline,refs:l}),f=ex(l);if(f.length&&d.push(o(`footer`,{},...f.map(function(e){let t=e.identifier.slice(1),n=u(LS(e.footnote,{inline:!0,refs:l},c),{inline:!0,refs:l});return o(`div`,{id:r(t,Db)},t+`: `,...zS(n))}))),n.wrapper===null)return d.length===0?null:d.length===1?d[0]:d;let p=n.wrapper||(n.forceInline?`span`:`div`),m;if(d.length>1||n.forceWrapper)m=d;else return d.length===1?d[0]:null;return s(p,{...n.wrapperProps},m)}function GS(e=``,t={}){let n={...t||{}};n.overrides=n.overrides||{};let r=n.slugify||Db,i=n.sanitizer||Cb;function a(e){let t=n.forceInline||!n.forceBlock&&!bb.test(e),a={slugify:e=>r(e,Db),sanitizer:i,tagfilter:n.tagfilter!==!1,disableAutoLink:n.disableAutoLink,disableParsingRawHTML:n.disableParsingRawHTML,enforceAtxHeadings:n.enforceAtxHeadings,forceBlock:n.forceBlock,forceInline:t,preserveFrontmatter:n.preserveFrontmatter},s=t?e:qb(e);return WS(LS(t?e:s,{inline:t,refs:o},a),{...n,forceInline:t})}let o={};return a(e)}var KS=N(void 0);function qS(e,t,...n){if(!RS){let r=n.length===0?void 0:n.length===1?n[0]:n,i=r===void 0?t:{...t,children:r};return typeof e==`function`?e(i):{t:e,p:i}}let r=ot(e,t,...n);return typeof r==`function`?r():r}var JS=e=>{let t=te(KS),n=E(()=>({...t,...e.options})),r=E(()=>(typeof e.children==`function`?e.children():e.children)??``),i=E(()=>FS(r(),n()));return E(()=>WS(i(),{...n(),wrapperProps:{...n()?.wrapperProps,...Object.fromEntries(Object.entries(e).filter(([e])=>e!==`children`&&e!==`options`))}}))()},YS=B(`<div class=modal-backdrop><section class="review-dialog description-dialog Window -active"role=dialog aria-modal=true aria-labelledby=description-dialog-title><header class="dialog-header WindowTitleBar"><div><h2 id=description-dialog-title></h2><p> #</p></div><button type=button class="dialog-close WindowTitleButton"aria-label="Close pull request description">×</button></header><div class="dialog-body description-body WindowContent">`),XS=B(`<p class=markdown-empty>This pull request has no description.`),ZS=B(`<article class=markdown-body>`),QS=B(`<details class=draft-summary><summary>Inline comments<span></span></summary><div class=draft-list>`),$S=B(`<details class="draft-summary github-comments"open><summary>Existing GitHub comments<span></span></summary><div class=draft-list>`),eC=B(`<div class=modal-backdrop><section class="review-dialog Window -active"role=dialog aria-modal=true aria-labelledby=review-dialog-title><header class="dialog-header WindowTitleBar"><div><h2 id=review-dialog-title>Finish your review</h2><p> inline comment<!> will be included.</p></div><button type=button class="dialog-close WindowTitleButton"aria-label="Close review">×</button></header><div class="dialog-body WindowContent"><label class=review-note>Review summary <span>optional</span><textarea class=TextBox placeholder="Add an overall note…"></textarea></label></div><footer class=dialog-footer><div><button type=button class=Button>Sync comments</button><button type=button class=Button>Save draft</button></div><div><button type=button class=Button>Cancel</button><button type=button class="Button -main">Submit review`),tC=B(`<article><strong>:</strong><p>`),nC=B(`<article><strong></strong><span></span><p>`),rC=B(`<div class=decision-options role=radiogroup>`),iC=B(`<button type=button role=radio class="Button decision-option"><span></span><span><strong></strong><small>`);function aC(e){return z(Te,{get when(){return e.open},get children(){var t=YS(),n=t.firstChild.firstChild,r=n.firstChild,i=r.firstChild,a=i.nextSibling,o=a.firstChild,s=r.nextSibling,c=n.nextSibling;return t.$$click=t=>{t.target===t.currentTarget&&e.onClose()},V(i,()=>e.session.pullRequest.title),V(a,()=>e.session.pullRequest.repository,o),V(a,()=>e.session.pullRequest.number,null),Ue(s,`click`,e.onClose,!0),V(c,z(Te,{get when(){return e.session.pullRequest.body},get fallback(){return XS()},children:e=>(()=>{var t=ZS();return V(t,z(JS,{get children(){return e()},options:{disableParsingRawHTML:!0}})),t})()})),t}})}function oC(e){return z(Te,{get when(){return e.open},get children(){var t=eC(),n=t.firstChild.firstChild,r=n.firstChild,i=r.firstChild.nextSibling,a=i.firstChild,o=a.nextSibling;o.nextSibling;var s=r.nextSibling,c=n.nextSibling,l=c.firstChild,u=l.firstChild.nextSibling.nextSibling,d=c.nextSibling.firstChild,f=d.firstChild,p=f.nextSibling,m=d.nextSibling.firstChild,h=m.nextSibling;return t.$$click=t=>{t.target===t.currentTarget&&e.onClose()},V(i,()=>e.session.draftComments.length,a),V(i,()=>e.session.draftComments.length===1?``:`s`,o),Ue(s,`click`,e.onClose,!0),V(c,z(sC,{get decision(){return e.decision},get onChange(){return e.onDecisionChange}}),l),u.$$input=t=>e.onReviewBodyChange(t.currentTarget.value),V(c,z(Te,{get when(){return e.session.draftComments.length>0},get children(){var t=QS(),n=t.firstChild,r=n.firstChild.nextSibling,i=n.nextSibling;return V(r,()=>e.session.draftComments.length),V(i,z(we,{get each(){return e.session.draftComments},children:e=>(()=>{var t=tC(),n=t.firstChild,r=n.firstChild,i=n.nextSibling;return V(n,()=>e.filePath,r),V(n,()=>e.line,null),V(i,()=>e.body),t})()})),t}}),null),V(c,z(Te,{get when(){return e.currentComments.length>0},get children(){var t=$S(),n=t.firstChild,r=n.firstChild.nextSibling,i=n.nextSibling;return V(r,()=>e.currentComments.length),V(i,z(we,{get each(){return e.currentComments},children:e=>(()=>{var t=nC(),n=t.firstChild,r=n.nextSibling,i=r.nextSibling;return V(n,()=>e.author),V(r,(()=>{var t=Pe(()=>!!e.filePath);return()=>t()?`${e.filePath}:${e.line??``}`:`General comment`})()),V(i,()=>e.body),t})()})),t}}),null),Ue(f,`click`,e.onRefreshComments,!0),Ue(p,`click`,e.onSaveDraft,!0),Ue(m,`click`,e.onClose,!0),Ue(h,`click`,e.onSubmit,!0),w(t=>{var n=e.isPending,r=e.isPending,i=e.isPending||e.decision===`pending`;return n!==t.e&&(f.disabled=t.e=n),r!==t.t&&(p.disabled=t.t=r),i!==t.a&&(h.disabled=t.a=i),t},{e:void 0,t:void 0,a:void 0}),w(()=>u.value=e.reviewBody),t}})}function sC(e){return(()=>{var t=rC();return V(t,z(cC,{description:`General feedback`,icon:`●`,iconClass:`comment`,label:`Comment`,get selected(){return e.decision===`comment`},onClick:()=>e.onChange(`comment`)}),null),V(t,z(cC,{description:`Ready to merge`,icon:`✓`,iconClass:`approve`,label:`Approve`,get selected(){return e.decision===`approve`},onClick:()=>e.onChange(`approve`)}),null),V(t,z(cC,{description:`Must be addressed`,icon:`!`,iconClass:`changes`,label:`Request changes`,get selected(){return e.decision===`request-changes`},onClick:()=>e.onChange(`request-changes`)}),null),t})()}function cC(e){return(()=>{var t=iC(),n=t.firstChild,r=n.nextSibling.firstChild,i=r.nextSibling;return Ue(t,`click`,e.onClick,!0),V(n,()=>e.icon),V(r,()=>e.label),V(i,()=>e.description),w(r=>{var i=e.selected,a=!!e.selected,o=!!e.selected,s=`decision-icon ${e.iconClass}`;return i!==r.e&&ze(t,`aria-checked`,r.e=i),a!==r.t&&t.classList.toggle(`-down`,r.t=a),o!==r.a&&t.classList.toggle(`selected`,r.a=o),s!==r.o&&He(n,r.o=s),r},{e:void 0,t:void 0,a:void 0,o:void 0}),t})()}Re([`click`,`input`]);var lC=B(`<header class="topbar WindowTitleBar"><div class=product-mark aria-label="PR review"><span class=product-icon>PR</span><span class=product-name>Review`),uC=B(`<form class=pr-picker><div class=popover-heading><strong>Open pull request</strong><span>Paste any URL for the pull request.</span></div><label>Pull request URL<input class=TextBox type=text inputmode=url autocomplete=url placeholder=https://github.com/owner/repo/pull/123></label><div class=popover-actions><button type=button class=Button>Cancel</button><button type=submit class=Button>Open PR`),dC=B(`<div class=pr-identity><div class=pr-title-row><span class=pr-number> #</span><h1><button type=button class="pr-title-button ThinButton"aria-haspopup=dialog title="View pull request description"></button></h1></div><div class=pr-meta><span class=branch-flow><code></code><span>←</span><code></code></span><span class="change-count additions">+</span><span class="change-count deletions">−`),fC=B(`<span>by `),pC=B(`<span class=button-badge>`),mC=B(`<div class=topbar-actions><a class="quiet-link ToolbarButton"target=_blank rel=noreferrer>GitHub ↗</a><button type=button class="icon-button ToolbarButton"title="Open another pull request"aria-label="Open another pull request">↔</button><details class=llm-settings><summary class=ToolbarButton title="LLM settings"aria-label="LLM settings">⚙</summary><div class=llm-settings-panel><div class=popover-heading><strong>Grouping model</strong><span>Reasoning effort by stage</span></div><button type=button class=Button>Apply settings</button></div></details><button type=button class="Button review-button">Review changes`),hC=B(`<label><select class=TextBox>`),gC=B(`<option>`),_C=[{label:`Model default`,value:``},{label:`None`,value:`none`},{label:`Minimal`,value:`minimal`},{label:`Low`,value:`low`},{label:`Medium`,value:`medium`},{label:`High`,value:`high`},{label:`Extra high`,value:`xhigh`}];function vC(e){return[(()=>{var t=lC();return t.firstChild,V(t,z(Te,{get when(){return e.session},children:t=>(()=>{var n=dC(),r=n.firstChild,i=r.firstChild,a=i.firstChild,o=i.nextSibling.firstChild,s=r.nextSibling,c=s.firstChild,l=c.firstChild,u=l.nextSibling.nextSibling,d=c.nextSibling;d.firstChild;var f=d.nextSibling;return f.firstChild,V(i,()=>t().pullRequest.repository,a),V(i,()=>t().pullRequest.number,null),Ue(o,`click`,e.onDescriptionOpen,!0),V(o,()=>t().pullRequest.title),V(s,z(Te,{get when(){return t().pullRequest.author},children:e=>(()=>{var t=fC();return t.firstChild,V(t,e,null),t})()}),c),V(l,()=>t().pullRequest.baseRef),V(u,()=>t().pullRequest.headRef),V(d,()=>e.totalAdditions,null),V(f,()=>e.totalDeletions,null),n})()}),null),V(t,z(Te,{get when(){return e.session},children:t=>(()=>{var n=mC(),r=n.firstChild,i=r.nextSibling,a=i.nextSibling,o=a.firstChild.nextSibling,s=o.firstChild.nextSibling,c=a.nextSibling;return c.firstChild,Ue(i,`click`,e.onPickerToggle,!0),V(o,z(yC,{label:`Manifest`,get value(){return e.manifestReasoning},get onChange(){return e.onManifestReasoningChange}}),s),V(o,z(yC,{label:`Group agent`,get value(){return e.groupAgentReasoning},get onChange(){return e.onGroupAgentReasoningChange}}),s),V(o,z(yC,{label:`Reducer`,get value(){return e.reducerReasoning},get onChange(){return e.onReducerReasoningChange}}),s),Ue(s,`click`,e.onSaveLlmSettings,!0),Ue(c,`click`,e.onReviewOpen,!0),V(c,z(Te,{get when(){return t().draftComments.length>0},get children(){var e=pC();return V(e,()=>t().draftComments.length),e}}),null),w(n=>{var i=t().pullRequest.url,a=e.isPending;return i!==n.e&&ze(r,`href`,n.e=i),a!==n.t&&(s.disabled=n.t=a),n},{e:void 0,t:void 0}),n})()}),null),t})(),z(Te,{get when(){return e.pickerOpen},get children(){var t=uC(),n=t.firstChild.nextSibling,r=n.firstChild.nextSibling,i=n.nextSibling.firstChild,a=i.nextSibling;return t.addEventListener(`submit`,t=>{t.preventDefault(),e.onLoadPullRequest()}),r.$$input=t=>e.onPullRequestUrlChange(t.currentTarget.value),Ue(i,`click`,e.onPickerClose,!0),w(()=>a.disabled=e.isPending),w(()=>r.value=e.pullRequestUrl),t}})]}function yC(e){return(()=>{var t=hC(),n=t.firstChild;return V(t,()=>e.label,n),n.addEventListener(`change`,t=>e.onChange(t.currentTarget.value)),V(n,z(we,{each:_C,children:e=>(()=>{var t=gC();return V(t,()=>e.label),w(()=>t.value=e.value),t})()})),w(()=>n.value=e.value),t})()}Re([`input`,`click`]);var bC=`<svg data-icon-sprite aria-hidden="true" width="0" height="0">
1624
+ <symbol id="file-tree-icon-chevron" viewBox="0 0 16 16">
1625
+ <path d="M12.4697 5.46973C12.7626 5.17684 13.2374 5.17684 13.5303 5.46973C13.8232 5.76262 13.8232 6.23738 13.5303 6.53028L8.53028 11.5303C8.23738 11.8232 7.76262 11.8232 7.46973 11.5303L2.46973 6.53028C2.17684 6.23738 2.17684 5.76262 2.46973 5.46973C2.76262 5.17684 3.23738 5.17684 3.53028 5.46973L8 9.93946L12.4697 5.46973Z" fill="currentcolor"/>
1626
+ </symbol>
1627
+ <symbol id="file-tree-icon-dot" viewBox="0 0 6 6">
1628
+ <circle cx="3" cy="3" r="3" />
1629
+ </symbol>
1630
+ <symbol id="file-tree-icon-file" viewBox="0 0 16 16">
1631
+ <path fill="currentColor" d="M8 1v3a3 3 0 0 0 3 3h3v5.5a2.5 2.5 0 0 1-2.5 2.5h-7A2.5 2.5 0 0 1 2 12.5v-9A2.5 2.5 0 0 1 4.5 1z" class="bg" opacity=".5"/>
1632
+ <path fill="currentColor" d="M9.5 1a.5.5 0 0 1 .354.146l4 4A.5.5 0 0 1 14 5.5V6h-3a2 2 0 0 1-2-2V1z" class="fg"/>
1633
+ </symbol>
1634
+ <symbol id="file-tree-icon-lock" viewBox="0 0 16 16">
1635
+ <path fill="currentcolor" d="M4 5.336V4a4 4 0 1 1 8 0v1.336c1.586.54 2 1.843 2 4.664v1c0 4.118-.883 5-5 5H7c-4.117 0-5-.883-5-5v-1c0-2.821.414-4.124 2-4.664M5.5 4v1.054Q6.166 4.998 7 5h2q.834-.002 1.5.054V4a2.5 2.5 0 0 0-5 0m-2 6v1c0 .995.055 1.692.167 2.193.107.483.246.686.35.79s.307.243.79.35c.5.112 1.198.167 2.193.167h2c.995 0 1.692-.055 2.193-.166.483-.108.686-.247.79-.35.104-.105.243-.308.35-.791.112-.5.167-1.198.167-2.193v-1c0-.995-.055-1.692-.166-2.193-.108-.483-.247-.686-.35-.79-.105-.104-.308-.243-.791-.35C10.693 6.555 9.995 6.5 9 6.5H7c-.995 0-1.692.055-2.193.167-.483.107-.686.246-.79.35s-.243.307-.35.79C3.555 8.307 3.5 9.005 3.5 10" />
1636
+ </symbol>
1637
+ <symbol id="file-tree-icon-ellipsis" viewBox="0 0 16 16">
1638
+ <path d="M5 8.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0M9.5 8.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0M14 8.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0" />
1639
+ </symbol>
1640
+ </svg>`,xC=`<symbol id="file-tree-builtin-astro" viewBox="0 0 16 16">
1641
+ <path fill="currentColor" d="M6.08 13.92c-.63-.57-.81-1.79-.55-2.67.45.56 1.08.73 1.73.83 1 .15 1.99.1 2.92-.37l.32-.19q.13.38.08.78a2.1 2.1 0 0 1-.9 1.5q-.3.24-.61.43c-.64.44-.81.95-.57 1.69l.02.08a1.7 1.7 0 0 1-.74-.64 2 2 0 0 1-.3-.98q0-.27-.02-.52-.07-.61-.61-.62a.7.7 0 0 0-.75.6z" class="bg" opacity=".6"/>
1642
+ <path fill="currentColor" d="M2.5 11.1s1.86-.9 3.72-.9l1.4-4.39c.05-.21.2-.36.38-.36s.33.15.38.36l1.4 4.38c2.2 0 3.72.92 3.72.92l-3.16-8.69q-.13-.4-.45-.42H6.11q-.3.02-.45.42z" class="fg"/>
1643
+ </symbol>`,SC=`<symbol id="file-tree-builtin-babel" viewBox="0 0 16 16">
1644
+ <path fill="currentColor" fill-rule="evenodd" d="M9.49.5q1.92.05 2.66.54 1.27.6 1.35 1.52v.23a4 4 0 0 1-.53 1.9l-1.38 1.24q-.74.38-.72.63c.77.82 1.33 1.29.85 2.42q-.47 1.1-2.04 2.28c-.5.32-1.88 1.35-2.96 1.86-1.64.77-3.1 1.4-4.65 1.89-.51.16-1.5.16-1.5.16L.5 15A76 76 0 0 0 5.76 3.49q-.1-.08-.1-.2.1 0 .32-.35l-.03-.09q-1.17.39-2.38 1.3l-.13.03q0-.1-.21-.16-.46.31-.82.7l-.13-.19.16-.06-.03-.16-.34.29L2 4.5q.36-.48.72-.54l.04-.1V3.8q.16 0 .15-.06l.13-.06a6 6 0 0 0 1.13-.9v-.03H4.1l-.12.07q0-.1-.1-.1l-.15.07-.04-.1q.93-.52 1.63-1.05Q7.89.65 9.5.5M8.46 7.83l-.32.04c-1.31.54-2.31.82-2.91.88a71 71 0 0 0-2.2 4.54h.07q.58-.04 3.04-1.42.13 0 1.66-1.05L9.18 9.7v.03q.45-.2.81-1.3v-.2q-.5-.46-1.53-.4m.28-5.75c-.5.1-.75.19-.72.38l-1.16 2.6q-.17.1-.34.95-.3.48-.25.77v.1l.22.05A15 15 0 0 1 8.86 6c1.1-.71 2.12-1.38 2.8-2.54q.24-.33.21-.54-.02-.33-.4-.54c-.54 0-1.07-.34-1.63-.28l-.94-.03z" clip-rule="evenodd"/>
1645
+ </symbol>`,CC=`<symbol id="file-tree-builtin-bash" viewBox="0 0 16 16">
1646
+ <path fill="currentColor" d="M8 1C2.24 1 1 2.24 1 8s1.24 7 7 7 7-1.24 7-7-1.24-7-7-7" class="bg" opacity=".2"/>
1647
+ <path fill="currentColor" d="M11.5 11a.5.5 0 0 1 0 1h-3a.5.5 0 0 1 0-1zM7 6.75C7 6.42 6.64 6 6 6s-1 .42-1 .75q-.01.25.22.41.26.21.89.35.74.14 1.28.53c.37.29.61.7.61 1.21 0 .87-.68 1.5-1.5 1.7v.55a.5.5 0 0 1-1 0v-.56c-.82-.18-1.5-.82-1.5-1.69a.5.5 0 0 1 1 0c0 .33.36.75 1 .75s1-.42 1-.75q.01-.25-.22-.41a2 2 0 0 0-.89-.35q-.74-.14-1.28-.53A1.5 1.5 0 0 1 4 6.75c0-.87.68-1.5 1.5-1.7V4.5a.5.5 0 0 1 1 0v.56c.82.18 1.5.82 1.5 1.69a.5.5 0 0 1-1 0" class="fg-stroke"/>
1648
+ </symbol>`,wC=`<symbol id="file-tree-builtin-biome" viewBox="0 0 16 16">
1649
+ <path fill="currentColor" d="M8 2 4.88 7.35a7 7 0 0 1 3.7-.13l1.04.25-.99 4.16-1.05-.25a2.7 2.7 0 0 0-3.07 1.45l-.98-.47a4 4 0 0 1 1.07-1.31 3.8 3.8 0 0 1 3.23-.71l.5-2.08a6 6 0 0 0-5.07 1.12A5.9 5.9 0 0 0 1 14h14z"/>
1650
+ </symbol>`,TC=`<symbol id="file-tree-builtin-bootstrap" viewBox="0 0 16 16">
1651
+ <path fill="currentColor" fill-rule="evenodd" d="M11.72 1.5A2.5 2.5 0 0 1 14.2 4q.02 1.08.3 2.09c.22.73.56 1.24 1.08 1.45.22.08.4.27.4.5s-.18.43-.4.51q-.76.34-1.08 1.45c-.2.65-.27 1.32-.3 2a2.5 2.5 0 0 1-2.48 2.5H4.25A2.6 2.6 0 0 1 1.7 12c-.04-.85-.1-1.68-.22-2.04C1.26 9.23.92 8.7.4 8.5.18 8.42 0 8.23 0 8s.18-.42.4-.5q.77-.35 1.09-1.46c.1-.36.17-1.19.2-2.04a2.6 2.6 0 0 1 2.56-2.5z" class="bg" clip-rule="evenodd" opacity=".2"/>
1652
+ <path fill="currentColor" fill-rule="evenodd" d="M8.47 4.54c1.23 0 2.04.68 2.04 1.73 0 .73-.55 1.39-1.24 1.5v.04c.94.1 1.58.77 1.58 1.7 0 1.2-.9 1.95-2.37 1.95H5.97a.3.3 0 0 1-.2-.08.3.3 0 0 1-.08-.2V4.82a.3.3 0 0 1 .08-.2.3.3 0 0 1 .2-.08zm-1.7 6.04h1.49q1.47-.01 1.49-1.15Q9.74 8.31 8.2 8.3H6.77zm0-5.16v2.06h1.21c.93 0 1.45-.38 1.45-1.06 0-.65-.44-1-1.22-1z" class="fg" clip-rule="evenodd"/>
1653
+ </symbol>`,EC=`<symbol id="file-tree-builtin-browserslist" viewBox="0 0 16 16">
1654
+ <path fill="currentColor" d="M8.88 6.96c0 3.82 3.72 4.7 5.7 3.74-.23.9-1.04 1.67-2.35 1.93-.02.4.42 1.28.82 1.63-.9.35-1.94-.12-2.51-.48a5 5 0 0 0-.32 1.87c-.68 0-1.57-1-1.8-1.37-.3.18-.85 1.15-.96 1.72a2.4 2.4 0 0 1-.81-.86 2.4 2.4 0 0 1-.3-1.15c-.38.27-1.48.95-1.99 1.18-.25-.58-.15-1.3 0-2.06-.21.12-1.8.27-2.43.12.32-.36.75-1.19.94-1.57A4.5 4.5 0 0 1 .44 10.6c.48-.22.97-.53 1.49-1.06C1.26 9.17.24 8.64 0 7.7a6 6 0 0 0 1.79-.32C1.28 7.08.44 6.15.6 5.01c.42.21 1.3.37 1.73.3a3.4 3.4 0 0 1-.25-2.75 5 5 0 0 0 1.48 1c-.08-.8.3-2.31.8-2.71.2.46.73 1.21 1.08 1.4.09-.61.87-2.06 1.57-2.25 0 .5.27 1.4.5 1.67.51-.54 2.25-1.44 3.64-1.13-.43.45-.75.61-.86.98 1.05 0 2.78.34 4.27 1.93-2.34-.89-5.69.56-5.69 3.5" class="bg" opacity=".5"/>
1655
+ <path fill="currentColor" d="M11.21 3.59a4.1 4.1 0 0 0 2.47 2.89c.24-.22.61-.38.95-.19.76.44.2 1.26-.34 1.66l-.07.06a13 13 0 0 1-4.49 1.61l-.3-.43a10.5 10.5 0 0 0 4.13-1.31 1 1 0 0 0 .23-.25.5.5 0 0 0-.21-.69l-.15-.06a4.5 4.5 0 0 1-1.77-1.31 4.5 4.5 0 0 1-.88-1.77q.2-.12.43-.21"/>
1656
+ <path fill="currentColor" d="M10.36 5.18a.4.4 0 0 0-.03.38c.09.2.3.3.46.23s.24-.3.15-.5l-.01-.02q.23.13.34.39a.83.83 0 0 1-.43 1.08.8.8 0 0 1-1.08-.43.83.83 0 0 1 .6-1.13"/>
1657
+ </symbol>`,DC=`<symbol id="file-tree-builtin-bun" viewBox="0 0 16 16">
1658
+ <path fill="currentColor" d="M8 14c3.87 0 7-2.46 7-5.49 0-1.88-1.2-3.53-3.04-4.52q-1.1-.61-1.84-1.07C9.2 2.35 8.64 2 8 2s-1.36.45-2.31 1.03A29 29 0 0 1 4.04 4C2.2 4.98 1 6.63 1 8.51 1 11.54 4.13 14 8 14M7.18 3.88q.3-.66.3-1.37c0-.08.11-.1.13-.01.38 1.57-.53 2.35-1.2 2.61-.08.03-.12-.07-.06-.12a3 3 0 0 0 .83-1.12m1.2-.05a3 3 0 0 0-.45-1.3V2.5c-.04-.07.05-.15.1-.1 1.15 1.2.77 2.3.33 2.87-.05.05-.13 0-.11-.08q.21-.67.13-1.37m1.04-.32a3 3 0 0 0-.94-1.02v-.01c-.06-.05-.01-.16.07-.12 1.51.61 1.61 1.8 1.43 2.5l-.03.03a.07.07 0 0 1-.1-.06 3 3 0 0 0-.43-1.32m-2.97.32c-.36.3-.74.43-1.2.56q-.11 0-.1-.1a3.5 3.5 0 0 0 1.76-1.57s.09-.07.1.04c0 .18-.2.76-.56 1.07m2.89 6.36q-.13.52-.55.88a1.3 1.3 0 0 1-.75.35 1.3 1.3 0 0 1-.77-.35 1.7 1.7 0 0 1-.54-.88.13.13 0 0 1 .15-.15h2.31a.14.14 0 0 1 .15.15M6.15 8.95a1.1 1.1 0 0 1-1.39-.14A1.1 1.1 0 0 1 5.12 7a1.1 1.1 0 0 1 1.2.25 1.1 1.1 0 0 1-.17 1.69m4.96 0a1.1 1.1 0 0 1-1.4-.14 1.1 1.1 0 0 1 .37-1.8 1.1 1.1 0 0 1 1.2.25 1.1 1.1 0 0 1 .24 1.2 1 1 0 0 1-.41.5"/>
1659
+ </symbol>`,OC=`<symbol id="file-tree-builtin-c" viewBox="0 0 16 16">
1660
+ <path fill="currentColor" fill-rule="evenodd" d="M8 1q.084 0 .166.021.098.023.186.075c1.055.624 4.22 2.486 5.277 3.11.085.05.15.112.209.192h-.002l.028.037a.5.5 0 0 1 .103.21q.031.102.033.21v6.29a.71.71 0 0 1-.347.616l-5.307 3.144a.68.68 0 0 1-.693 0l-5.307-3.144A.72.72 0 0 1 2 11.145V4.832a.71.71 0 0 1 .346-.612l5.288-3.126A.7.7 0 0 1 7.992 1zm2.901 4.349a3.75 3.75 0 1 0 0 5.302l-1.06-1.06a2.25 2.25 0 1 1 0-3.182z" clip-rule="evenodd"/>
1661
+ </symbol>`,kC=`<symbol id="file-tree-builtin-claude" viewBox="0 0 16 16">
1662
+ <path fill="currentColor" d="M3.75 10.31 6.5 8.77l.04-.14-.04-.07h-.14l-.46-.03-1.57-.04-1.38-.07-1.33-.07-.34-.07L1 7.86l.03-.21.28-.18.4.03.89.07 1.33.08.97.06 1.43.16h.22l.03-.1-.07-.05-.06-.06-1.39-.92-1.48-.98-.79-.57-.42-.28-.2-.28-.1-.6.39-.41.52.04.12.03.52.4 1.12.86L6.2 6.04l.2.17.09-.06.01-.04-.1-.15-.76-1.46-.85-1.46-.37-.6-.1-.36a1 1 0 0 1-.06-.42l.42-.59.25-.07.6.08.22.2.36.84.58 1.3.9 1.77.29.53.14.47.04.14h.1v-.07l.07-1 .14-1.22.14-1.57.04-.45.23-.53.42-.28.36.15.28.41-.04.25-.16 1.08-.36 1.7-.21 1.14h.12l.14-.15.58-.76.97-1.2.42-.5.5-.51.32-.25h.6l.44.66-.2.68-.61.79-.52.65-.74 1-.45.8.04.05h.1l1.68-.36.9-.16 1.06-.18.5.23.05.22-.2.48-1.15.28-1.34.28-2 .46-.04.01.03.04.9.09.4.03h.94l1.77.14.46.28.27.37-.04.28-.72.37-.95-.23-2.24-.53-.76-.18h-.11v.06l.64.63L12 10.86l1.48 1.35.07.34-.18.28-.2-.03-1.29-.98-.5-.42-1.12-.95h-.07v.1l.25.38 1.37 2.05.07.63-.1.2-.36.14-.38-.08-.8-1.12-.85-1.26-.66-1.15-.07.05-.4 4.23-.19.21-.42.17-.35-.28-.2-.42.2-.87.23-1.12.18-.9.17-1.1.1-.36v-.03h-.1l-.84 1.16-1.27 1.72-1 1.07-.24.1-.42-.22.04-.39.22-.32 1.4-1.8.84-1.1.57-.64-.02-.07h-.04l-3.7 2.4-.66.09-.28-.28.03-.42.14-.14 1.12-.77z"/>
1663
+ </symbol>`,AC=`<symbol id="file-tree-builtin-cpp" viewBox="0 0 16 16">
1664
+ <path fill="currentColor" fill-rule="evenodd" d="M8 1q.084 0 .166.021.098.023.186.075c1.055.624 4.22 2.486 5.277 3.11.085.05.15.112.209.192h-.002l.028.037a.5.5 0 0 1 .103.21q.031.102.033.21v6.29a.71.71 0 0 1-.347.616l-5.307 3.144a.68.68 0 0 1-.693 0l-5.307-3.144A.72.72 0 0 1 2 11.145V4.832a.71.71 0 0 1 .346-.612l5.288-3.126A.7.7 0 0 1 7.992 1zm2.901 4.349a3.75 3.75 0 1 0 0 5.302l-1.06-1.06a2.25 2.25 0 1 1 0-3.182z" clip-rule="evenodd"/>
1665
+ </symbol>`,jC=`<symbol id="file-tree-builtin-css" viewBox="0 0 16 16">
1666
+ <path fill="currentColor" d="M8 15c-5.76 0-7-1.24-7-7V2a1 1 0 0 1 1-1h6c5.77 0 7 1.24 7 7s-1.24 7-7 7" class="vector" opacity=".2"/>
1667
+ <path fill="currentColor" d="M10.1 9.19h.73c.03.49.22.6 1 .6.76 0 .93-.12.93-.68 0-.52-.17-.67-.94-.85-1.38-.3-1.68-.56-1.68-1.47 0-1.05.3-1.29 1.67-1.29 1.29 0 1.57.2 1.6 1.13h-.74c-.01-.34-.17-.42-.85-.42-.77 0-.94.1-.94.58 0 .42.17.55.96.73 1.36.3 1.66.58 1.66 1.59 0 1.14-.31 1.39-1.73 1.39-1.39 0-1.69-.24-1.67-1.31m-3.9 0h.74c.03.49.21.6.99.6.76 0 .93-.12.93-.68 0-.52-.17-.67-.93-.85-1.39-.3-1.69-.56-1.69-1.47 0-1.05.3-1.29 1.67-1.29 1.3 0 1.58.2 1.6 1.13h-.73c-.02-.34-.18-.42-.85-.42-.78 0-.95.1-.95.58 0 .42.17.55.96.73 1.37.3 1.67.58 1.67 1.59 0 1.14-.32 1.39-1.74 1.39-1.38 0-1.68-.24-1.66-1.31m-1.22 0h.75c-.09 1.07-.37 1.31-1.56 1.31-1.37 0-1.68-.45-1.68-2.5 0-1.96.36-2.5 1.68-2.5 1.16 0 1.44.25 1.52 1.35h-.76c-.08-.52-.22-.64-.76-.64-.74 0-.9.33-.9 1.78 0 1.47.16 1.8.9 1.8.58 0 .74-.11.8-.6"/>
1668
+ </symbol>`,MC=`<symbol id="file-tree-builtin-database" viewBox="0 0 16 16">
1669
+ <path fill="currentColor" d="M14.953 9.733a12.4 12.4 0 0 1-.244 1.936c-.207.933-.532 1.58-.996 2.044s-1.11.789-2.044.996C10.73 14.918 9.533 15 8 15s-2.73-.082-3.669-.291c-.933-.207-1.58-.532-2.044-.996s-.789-1.11-.996-2.044c-.122-.547-.2-1.182-.244-1.92q.23.364.532.667c.64.639 1.482 1.031 2.533 1.265 1.046.232 2.33.315 3.884.315 1.555 0 2.838-.083 3.884-.315 1.051-.234 1.893-.626 2.532-1.265a4 4 0 0 0 .541-.683"/>
1670
+ <path fill="currentColor" d="M14.93 5.924c-.046.663-.118 1.24-.23 1.743-.207.932-.532 1.579-.995 2.042s-1.11.789-2.042.996c-.938.209-2.135.291-3.667.291-1.531 0-2.729-.082-3.667-.29-.932-.208-1.579-.534-2.042-.997s-.789-1.11-.996-2.042a12 12 0 0 1-.227-1.683l.016-.188a4 4 0 0 0 .5.62c.638.639 1.48 1.031 2.532 1.265 1.046.232 2.33.315 3.884.315 1.555 0 2.838-.083 3.884-.315 1.051-.234 1.893-.626 2.532-1.265.192-.192.357-.404.506-.633z"/>
1671
+ <path fill="currentColor" d="M8 1c1.533 0 2.73.082 3.669.291.933.207 1.58.533 2.044.996.403.404.904.944.91 1.695.004.764-.509 1.318-.918 1.727-.463.463-1.11.789-2.042.996-.938.209-2.135.291-3.667.291-1.531 0-2.729-.082-3.667-.29-.932-.208-1.579-.534-2.042-.997-.406-.406-.915-.953-.915-1.71 0-.758.509-1.305.915-1.712.464-.463 1.11-.789 2.044-.996C5.27 1.082 6.467 1 8 1"/>
1672
+ </symbol>`,NC=`<symbol id="file-tree-builtin-default" viewBox="0 0 16 16">
1673
+ <path fill="currentColor" d="M8 1v3a3 3 0 0 0 3 3h3v5.5a2.5 2.5 0 0 1-2.5 2.5h-7A2.5 2.5 0 0 1 2 12.5v-9A2.5 2.5 0 0 1 4.5 1z" class="bg" opacity=".4"/>
1674
+ <path fill="currentColor" d="M9.5 1a.5.5 0 0 1 .354.146l4 4A.5.5 0 0 1 14 5.5V6h-3a2 2 0 0 1-2-2V1z" class="fg"/>
1675
+ </symbol>`,PC=`<symbol id="file-tree-builtin-docker" viewBox="0 0 16 16">
1676
+ <path fill="currentColor" d="M15.85 6.54c-.05-.04-.45-.36-1.31-.36q-.34 0-.68.06a2.7 2.7 0 0 0-1.14-1.79l-.23-.14-.15.23a3 3 0 0 0-.4 1q-.24 1.01.26 1.84c-.4.24-1.03.3-1.17.3H.5a.5.5 0 0 0-.5.52q-.01 1.46.46 2.83.55 1.5 1.6 2.18c.79.5 2.08.79 3.54.79q.96 0 1.94-.18a8 8 0 0 0 2.55-.97 7 7 0 0 0 1.73-1.5 10 10 0 0 0 1.7-3.06h.15a2.4 2.4 0 0 0 1.8-.7 2 2 0 0 0 .47-.74l.06-.2z"/>
1677
+ <path fill="currentColor" d="M1.48 7.36h1.4a.14.14 0 0 0 .14-.13V5.91q-.01-.12-.13-.14H1.48a.13.13 0 0 0-.13.14v1.32q.02.13.13.13m1.94 0h1.41a.14.14 0 0 0 .13-.13V5.91q-.01-.12-.13-.14h-1.4a.13.13 0 0 0-.13.14v1.32q0 .13.12.13m1.98 0h1.4q.13 0 .14-.13V5.91a.13.13 0 0 0-.14-.14H5.4q-.1.01-.12.14v1.32q0 .13.12.13m1.95 0h1.42q.1 0 .12-.13V5.91q0-.12-.12-.14H7.35q-.1.01-.12.14v1.32q.01.13.12.13M3.42 5.5h1.41c.07 0 .13-.08.13-.15V4.03a.13.13 0 0 0-.13-.14h-1.4q-.12 0-.13.14v1.31q0 .13.12.15m1.98 0h1.4c.08 0 .14-.08.14-.15V4.03q0-.13-.14-.14H5.4q-.1 0-.12.14v1.31q0 .13.12.15m1.95 0h1.42c.06 0 .12-.08.12-.15V4.03q-.01-.13-.12-.14H7.35q-.1 0-.12.14v1.31q.01.13.12.15m0-1.9h1.42q.1-.02.12-.14v-1.3Q8.88 2 8.77 2H7.35q-.1 0-.12.14v1.3q.01.13.12.14m1.97 3.78h1.4a.13.13 0 0 0 .14-.13V5.91q-.01-.12-.13-.14H9.32q-.1.01-.12.14v1.32q.01.13.12.13" opacity=".5"/>
1678
+ </symbol>`,FC=`<symbol id="file-tree-builtin-eslint" viewBox="0 0 16 16">
1679
+ <path fill="currentColor" d="M11.16 6.1 8.12 4.35a.3.3 0 0 0-.24 0L4.84 6.1a.3.3 0 0 0-.12.2v3.5q0 .14.12.22l3.04 1.74q.12.08.24 0l3.04-1.74a.2.2 0 0 0 .13-.22V6.3a.3.3 0 0 0-.13-.2" opacity=".5"/>
1680
+ <path fill="currentColor" d="m.1 7.69 3.63-6.3A.8.8 0 0 1 4.37 1h7.26c.26 0 .5.17.64.4l3.63 6.27a.8.8 0 0 1 0 .75l-3.63 6.24a.7.7 0 0 1-.64.34H4.37a.7.7 0 0 1-.64-.34L.1 8.41a.7.7 0 0 1 0-.72m3 3.02q.01.15.14.23l4.63 2.66q.13.06.26 0l4.63-2.66a.3.3 0 0 0 .14-.23V5.4a.3.3 0 0 0-.14-.23L8.13 2.52a.3.3 0 0 0-.26 0L3.24 5.17a.3.3 0 0 0-.14.23z"/>
1681
+ </symbol>`,IC=`<symbol id="file-tree-builtin-font" viewBox="0 0 16 16">
1682
+ <path fill="currentColor" d="M12.3 13c-1.59 0-2.68-.99-2.68-2.5 0-1.43 1-2.34 2.88-2.35h2.16v-.83c0-1.08-.62-1.68-1.73-1.68-1.05 0-1.66.54-1.73 1.36H9.93c.09-1.43 1.06-2.48 3.05-2.48 1.75 0 3.02.95 3.02 2.68v5.66h-1.29v-1.02h-.04c-.41.66-1.16 1.16-2.37 1.16m.36-1.12c1.14 0 2-.72 2-1.74v-.96H12.6c-1.12 0-1.6.54-1.6 1.28 0 .97.8 1.42 1.66 1.42m-11.24.98H0L3.8 2h1.39l3.8 10.86H7.54l-1.08-3.2H2.5zm3.09-9.25h-.04l-1.6 4.95H6.1z"/>
1683
+ </symbol>`,LC=`<symbol id="file-tree-builtin-git" viewBox="0 0 16 16">
1684
+ <path fill="currentColor" d="M14.74 7.38 8.62 1.26a.9.9 0 0 0-1.27 0L6.08 2.53l1.61 1.61a1.07 1.07 0 0 1 1.36 1.37l1.55 1.55a1.07 1.07 0 0 1 1.1 1.77 1.07 1.07 0 0 1-1.74-1.16L8.5 6.22v3.8a1.07 1.07 0 1 1-.89-.02V6.15a1.07 1.07 0 0 1-.58-1.4l-1.58-1.6-4.2 4.2a.9.9 0 0 0 0 1.27l6.12 6.12a.9.9 0 0 0 1.27 0l6.09-6.09a.9.9 0 0 0 0-1.27"/>
1685
+ </symbol>`,RC=`<symbol id="file-tree-builtin-go" viewBox="0 0 16 16">
1686
+ <path fill="currentColor" fill-rule="evenodd" d="M4.41 4.57A3.2 3.2 0 0 1 6.87 5q.74.49 1.08 1.29.08.12-.1.16l-1.55.4c-.14.03-.15.04-.27-.1a1 1 0 0 0-.44-.34 1.6 1.6 0 0 0-1.68.14q-.95.61-.94 1.73c0 .73.52 1.33 1.25 1.43q.95.1 1.58-.6l.25-.34h-1.8c-.19 0-.24-.12-.17-.27.12-.28.34-.76.47-1a.3.3 0 0 1 .24-.14h2.98a4 4 0 0 1 .64-1.19 4 4 0 0 1 2.6-1.52 3.5 3.5 0 0 1 2.64.46q1.13.73 1.31 2.04a3.5 3.5 0 0 1-1.06 3.09q-.93.92-2.23 1.17l-.74.08a3.5 3.5 0 0 1-2.27-.8 3 3 0 0 1-.93-1.42 4 4 0 0 1-.39.61 4 4 0 0 1-2.64 1.56 3.3 3.3 0 0 1-2.5-.6 3 3 0 0 1-1.18-2.03 3.5 3.5 0 0 1 .8-2.67 4 4 0 0 1 2.6-1.58M13.1 7.5a1.53 1.53 0 0 0-1.9-1.21q-1.3.3-1.62 1.59a1.5 1.5 0 0 0 .85 1.72q.77.33 1.52-.05a2 2 0 0 0 1.18-1.74q0-.17-.03-.3" clip-rule="evenodd"/>
1687
+ </symbol>`,zC=`<symbol id="file-tree-builtin-graphql" viewBox="0 0 16 16">
1688
+ <path fill="currentColor" fill-rule="evenodd" d="M8 1a1.25 1.25 0 0 1 1.18 1.65l2.8 1.61q.33-.25.77-.26a1.25 1.25 0 0 1 .48 2.4v3.2a1.25 1.25 0 1 1-1.25 2.13l-2.8 1.62A1.25 1.25 0 0 1 8 15a1.25 1.25 0 0 1-1.18-1.65l-2.8-1.62q-.33.26-.77.27a1.25 1.25 0 0 1-.48-2.4V6.4a1.25 1.25 0 1 1 1.25-2.14l2.8-1.61A1.25 1.25 0 0 1 8 1M4.44 11.14l-.06.13 2.75 1.58a1.25 1.25 0 0 1 1.74 0l2.74-1.58-.05-.13zm3.89-7.68a1.3 1.3 0 0 1-.66 0L4.03 9.77q.37.3.45.78h7.04q.08-.48.45-.78zM4.38 4.73a1.24 1.24 0 0 1-1.02 1.76v3.02l.13.01 3.67-6.35-.03-.02zm4.46-1.56 3.67 6.35.13-.01V6.49a1.25 1.25 0 0 1-1.03-1.76L8.87 3.15z" clip-rule="evenodd"/>
1689
+ </symbol>`,BC=`<symbol id="file-tree-builtin-html" viewBox="0 0 16 16">
1690
+ <path fill="currentColor" d="M8 1C2.24 1 1 2.24 1 8s1.24 7 7 7 7-1.24 7-7-1.24-7-7-7" class="bg" opacity=".2"/>
1691
+ <path fill="currentColor" d="M10.48 3.76a.5.5 0 0 1 .4.58L10.6 5.8h1.14a.5.5 0 0 1 0 1h-1.32L10 9.2h1.08a.5.5 0 0 1 0 1H9.8l-.3 1.64a.5.5 0 1 1-.98-.18l.27-1.46H6.4l-.3 1.64a.5.5 0 1 1-.98-.18l.27-1.46H4.25a.5.5 0 0 1 0-1h1.32L6 6.8H4.93a.5.5 0 0 1 0-1H6.2l.3-1.64a.5.5 0 1 1 .98.18L7.2 5.8h2.4l.3-1.64a.5.5 0 0 1 .58-.4M6.58 9.2h2.4l.44-2.4h-2.4z" class="fg"/>
1692
+ </symbol>`,VC=`<symbol id="file-tree-builtin-image" viewBox="0 0 16 16">
1693
+ <path fill="currentColor" d="M12.5 2A2.5 2.5 0 0 1 15 4.5v4.67l-4.05-3.54-4.08 4.08-3-2L1 10.6V4.5A2.5 2.5 0 0 1 3.5 2z" opacity=".3"/>
1694
+ <path fill="currentColor" d="M15 10.5v1a2.5 2.5 0 0 1-2.5 2.5h-9a2.5 2.5 0 0 1-2.46-2.04L4 9l3 2 4-4zm-7-5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0"/>
1695
+ </symbol>`,HC=`<symbol id="file-tree-builtin-javascript" viewBox="0 0 16 16">
1696
+ <path fill="currentColor" d="M8 1C2.24 1 1 2.24 1 8s1.24 7 7 7 7-1.24 7-7-1.24-7-7-7" class="bg" opacity=".2"/>
1697
+ <path fill="currentColor" d="M8.1 9.64h.95c.04.62.28.76 1.28.76s1.2-.14 1.2-.85c0-.66-.2-.85-1.2-1.07-1.79-.38-2.18-.7-2.18-1.86C8.15 5.3 8.54 5 10.31 5c1.67 0 2.04.26 2.07 1.42h-.95c-.02-.43-.23-.53-1.1-.53-1 0-1.22.14-1.22.74 0 .52.22.7 1.24.92 1.76.38 2.15.73 2.15 2 0 1.44-.4 1.75-2.24 1.75-1.8 0-2.18-.3-2.15-1.66M3.5 9.5h.98c0 .76.15.92.85.92.77 0 .94-.18.94-1.02V5.1h1v4.34c0 1.54-.35 1.87-1.92 1.87-1.55 0-1.89-.32-1.86-1.8"/>
1698
+ </symbol>`,UC=`<symbol id="file-tree-builtin-json" viewBox="0 0 16 16">
1699
+ <path fill="currentColor" d="M13.25 11.5V9.75a.5.5 0 0 1 .36-.48l.55-.15a1.16 1.16 0 0 0 0-2.24l-.55-.15a.5.5 0 0 1-.36-.48V4.5a2.5 2.5 0 0 0-2.5-2.5h-.25a.5.5 0 0 0 0 1h.25a1.5 1.5 0 0 1 1.5 1.5v1.75a1.5 1.5 0 0 0 1.09 1.44l.54.15a.16.16 0 0 1 0 .32l-.54.15a1.5 1.5 0 0 0-1.09 1.44v1.75a1.5 1.5 0 0 1-1.5 1.5h-.25a.5.5 0 0 0 0 1h.25a2.5 2.5 0 0 0 2.5-2.5m-10.5 0V9.75a.5.5 0 0 0-.36-.48l-.55-.15a1.16 1.16 0 0 1 0-2.24l.55-.15a.5.5 0 0 0 .36-.48V4.5A2.5 2.5 0 0 1 5.25 2h.25a.5.5 0 0 1 0 1h-.25a1.5 1.5 0 0 0-1.5 1.5v1.75a1.5 1.5 0 0 1-1.09 1.44l-.54.15a.16.16 0 0 0 0 .32l.54.15a1.5 1.5 0 0 1 1.09 1.45v1.74a1.5 1.5 0 0 0 1.5 1.5h.25a.5.5 0 0 1 0 1h-.25a2.5 2.5 0 0 1-2.5-2.5"/>
1700
+ </symbol>`,WC=`<symbol id="file-tree-builtin-markdown" viewBox="0 0 16 16">
1701
+ <path fill="currentColor" d="M1 12V4h2l2 2.5L7 4h2v8H7V7.5l-2 2-2-2V12zm9-3 3 3.5L16 9h-2V4h-2v5z"/>
1702
+ </symbol>`,GC=`<symbol id="file-tree-builtin-mcp" viewBox="0 0 16 16">
1703
+ <path fill="currentColor" d="M9.26-.04a3 3 0 0 1 2 .82 2.8 2.8 0 0 1 .8 2.35 2.9 2.9 0 0 1 2.41.8l.03.02a2.74 2.74 0 0 1 0 3.94l-5.8 5.69-.04.06-.02.07q0 .04.02.07.01.04.04.06l1.2 1.17a.55.55 0 0 1 0 .79.6.6 0 0 1-.81 0l-1.2-1.17a1.3 1.3 0 0 1 0-1.84L13.7 7.1a1.65 1.65 0 0 0 .37-1.82 2 2 0 0 0-.37-.54l-.03-.03a1.73 1.73 0 0 0-2.4 0L6.47 9.4l-.07.06a.58.58 0 0 1-.92-.18.6.6 0 0 1 .12-.6l4.85-4.76a1.65 1.65 0 0 0 0-2.36 1.73 1.73 0 0 0-2.4 0l-6.43 6.3a.6.6 0 0 1-.8 0 .55.55 0 0 1 0-.8L7.25.79a3 3 0 0 1 2-.82"/>
1704
+ <path fill="currentColor" d="M9.26 2.19a.6.6 0 0 1 .52.34.6.6 0 0 1 0 .43l-.12.18L4.9 7.79a1.65 1.65 0 0 0 0 2.36 1.73 1.73 0 0 0 2.4 0l4.75-4.66a.58.58 0 0 1 .93.18.6.6 0 0 1-.12.61l-4.75 4.66a2.9 2.9 0 0 1-4.01 0 2.75 2.75 0 0 1-.62-3.04A3 3 0 0 1 4.1 7l4.74-4.65a.6.6 0 0 1 .4-.16"/>
1705
+ </symbol>`,KC=`<symbol id="file-tree-builtin-nextjs" viewBox="0 0 16 16">
1706
+ <defs>
1707
+ <linearGradient id="a" x1="4.522" x2="14" y1="3.943" y2="16" gradientUnits="userSpaceOnUse">
1708
+ <stop stop-color="currentColor"/>
1709
+ <stop offset="1" stop-color="currentColor" stop-opacity="0"/>
1710
+ </linearGradient>
1711
+ </defs>
1712
+ <path fill="currentColor" d="M3 2h1.522v9.09H3z"/>
1713
+ <path fill="url(#a)" d="M4.903 2 15 15.075q-.565.5-1.195.925L4.522 3.943z"/>
1714
+ <path fill="currentColor" d="M12.172 2h-1.508v9.094h1.508z"/>
1715
+ </symbol>`,qC=`<symbol id="file-tree-builtin-npm" viewBox="0 0 16 16">
1716
+ <path fill="currentColor" d="M2 1a1 1 0 0 0-1 1v12a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1V2a1 1 0 0 0-1-1z" class="vector" opacity=".2"/>
1717
+ <path fill="currentColor" d="M10.5 13H13V3H3v10h5V5.5h2.5z"/>
1718
+ </symbol>`,JC=`<symbol id="file-tree-builtin-oxc" viewBox="0 0 16 16">
1719
+ <path fill="currentColor" d="M9.5 1a.5.5 0 0 1 .5.5V3h3.5a.5.5 0 0 1 .38.83L10.5 7.69v1.44q.41.04.95-.16a4 4 0 0 0 .72-.35l.04-.03h.01a.5.5 0 0 1 .67.1l2 2.5a.5.5 0 0 1 0 .62c-.76.96-3.14 2.69-6.89 2.69s-6.13-1.73-6.89-2.69a.5.5 0 0 1 0-.62l2-2.5a.5.5 0 0 1 .67-.1l.05.03.16.09q.22.13.56.26.54.2.95.16V7.69L2.12 3.83A.5.5 0 0 1 2.5 3H6V1.5a.5.5 0 0 1 .5-.5zM7 3.5a.5.5 0 0 1-.5.5H3.6l2.78 3.17a.5.5 0 0 1 .12.33v2a.5.5 0 0 1-.28.45c-.7.35-1.5.15-2.02-.05a5 5 0 0 1-.58-.26l-1.46 1.84c.82.78 2.8 2.02 5.84 2.02s5.02-1.24 5.84-2.02l-1.46-1.83a5 5 0 0 1-.58.26c-.52.2-1.33.39-2.02.04a.5.5 0 0 1-.28-.45v-2a.5.5 0 0 1 .12-.33L12.4 4H9.5a.5.5 0 0 1-.5-.5V2H7z"/>
1720
+ </symbol>`,YC=`<symbol id="file-tree-builtin-postcss" viewBox="0 0 16 16">
1721
+ <path fill="currentColor" d="M14.5 8a6.5 6.5 0 0 0-5.9-6.47l5.42 8.93A7 7 0 0 0 14.5 8M2.88 12A6.5 6.5 0 0 0 8 14.5c2.08 0 3.93-.98 5.12-2.5zm8.62-1h1.68L11.5 8.24zm-1-.55a4 4 0 0 1-.7.55h.7zM8 5.5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5M5.5 11h.7a4 4 0 0 1-.7-.55zm-2.68 0H4.5V8.24zm3.76-6.2A4 4 0 0 1 8 4.5q.76 0 1.42.3L8 2.46zM1.5 8q0 1.31.48 2.46L7.4 1.53A6.5 6.5 0 0 0 1.5 8m14 0a7.5 7.5 0 0 1-.99 3.72l-.01.03-.02.03A7.5 7.5 0 0 1 8 15.5a7.5 7.5 0 0 1-6.5-3.75l-.01-.03A7.5 7.5 0 1 1 15.5 8"/>
1722
+ </symbol>`,XC=`<symbol id="file-tree-builtin-prettier" viewBox="0 0 16 16">
1723
+ <path fill="currentColor" d="M6 12v1H4.93v-1zm1-2v1H2v-1zm6-4v1h-3V6zm-1-4v1H9V2z"/>
1724
+ <path fill="currentColor" d="M11.5 10v1H8v-1zM5 6v1H2V6zm5-2v1H9V4z" opacity=".8"/>
1725
+ <path fill="currentColor" d="M6 14v1H2v-1zm-.5-6v1H2V8zM13 4v1h-3V4zM4.93 2v1H2V2z" opacity=".6"/>
1726
+ <path fill="currentColor" d="M4.93 12v1H2v-1zM13 8v1H9V8zM5.5 4v1H2V4zM9 2v1H4.93V2z" opacity=".4"/>
1727
+ </symbol>`,ZC=`<symbol id="file-tree-builtin-python" viewBox="0 0 16 16">
1728
+ <path fill="currentColor" d="M8.33 8.4H10c1.16 0 1.9-.73 1.9-1.86V5.08q0-.24.25-.24h.74c.75 0 1.33.32 1.66.97q.4.73.41 1.46c.09.9.09 1.78-.24 2.67-.25.73-.75 1.3-1.58 1.46h-4.8c-.08 0-.25 0-.25.08v.4s.17.09.25.09h2.82q.34-.02.33.32v1.06c0 .56-.25.97-.75 1.13-.41.16-.83.33-1.24.4a7 7 0 0 1-2.98-.07 3 3 0 0 1-1.16-.49c-.33-.32-.58-.65-.5-1.14v-2.91c0-1.13.67-1.78 1.82-1.78q.89-.1 1.66-.08m2.32 4.86a.65.65 0 0 0-.66-.65c-.34 0-.67.33-.67.65s.33.57.67.65a.65.65 0 0 0 .66-.65" class="bg" opacity=".8"/>
1729
+ <path fill="currentColor" d="M7.67 7.6H6c-1.16 0-1.9.73-1.9 1.86v1.46q0 .24-.25.24h-.74c-.75 0-1.33-.32-1.66-.97a3 3 0 0 1-.41-1.46 6 6 0 0 1 .24-2.67c.25-.73.75-1.3 1.58-1.46h4.8c.08 0 .25 0 .25-.08v-.4s-.17-.09-.25-.09H4.85c-.24 0-.33-.08-.33-.32V2.65c0-.56.25-.97.75-1.13.41-.16.83-.33 1.24-.4a7 7 0 0 1 2.98.07c.41.09.83.25 1.16.49.33.32.58.65.5 1.13v2.92c0 1.14-.67 1.78-1.82 1.78-.58.08-1.16.08-1.66.08M5.35 2.73c0 .33.25.65.66.65.33 0 .66-.32.66-.65 0-.32-.33-.56-.66-.64a.65.65 0 0 0-.66.64" class="fg"/>
1730
+ </symbol>`,QC=`<symbol id="file-tree-builtin-react" viewBox="0 0 16 16">
1731
+ <path fill="currentColor" d="M8 6.65c.73 0 1.31.6 1.31 1.35S8.73 9.35 8 9.35 6.69 8.75 6.69 8 7.27 6.65 8 6.65"/>
1732
+ <path fill="currentColor" fill-rule="evenodd" d="M8 2.55c1.3-.99 2.59-1.34 3.5-.8.92.55 1.27 1.87 1.08 3.53C14.06 5.94 15 6.9 15 8s-.94 2.06-2.42 2.72c.19 1.65-.16 2.98-1.08 3.52-.91.55-2.2.2-3.5-.8-1.3 1-2.58 1.35-3.5.8-.91-.54-1.27-1.87-1.08-3.52C1.94 10.06 1 9.1 1 8s.94-2.06 2.42-2.72c-.19-1.66.17-2.98 1.08-3.52s2.2-.2 3.5.8M4.26 11.2c-.08 1.34.28 2.03.68 2.26s1.15.22 2.25-.52l.11-.09a12 12 0 0 1-1.24-1.39 11 11 0 0 1-1.8-.41zm7.47-.15q-.83.27-1.79.41-.6.8-1.24 1.4l.11.08c1.1.74 1.86.76 2.25.52.4-.23.76-.92.68-2.26zm-3.04.54a14 14 0 0 1-1.38 0q.34.38.69.7.35-.32.7-.7M8 5.29q-.76 0-1.47.1A13 13 0 0 0 5.07 8a14 14 0 0 0 1.46 2.62 13 13 0 0 0 2.94 0A13 13 0 0 0 10.93 8a14 14 0 0 0-1.46-2.62A13 13 0 0 0 8 5.3M4.64 9.18q-.15.5-.25.96.44.16.94.27a15 15 0 0 1-.7-1.23m6.73 0a15 15 0 0 1-.7 1.23q.5-.11.95-.27a10 10 0 0 0-.25-.96M3.44 6.26C2.27 6.86 1.87 7.53 1.87 8s.4 1.14 1.57 1.74l.13.07q.18-.88.55-1.81a12 12 0 0 1-.55-1.8q-.07.02-.13.06m8.99-.07A12 12 0 0 1 11.88 8q.36.94.55 1.8l.13-.06c1.17-.6 1.56-1.27 1.56-1.74s-.39-1.14-1.56-1.74zm-7.1-.6q-.5.11-.94.27.1.46.25.96a15 15 0 0 1 .69-1.23m5.34 0a15 15 0 0 1 .7 1.23q.14-.5.24-.96-.44-.15-.94-.27M7.18 3.06c-1.09-.74-1.85-.76-2.24-.52s-.76.92-.69 2.26l.01.15a11 11 0 0 1 1.8-.41q.6-.8 1.24-1.4zm3.88-.52c-.4-.24-1.15-.22-2.25.52l-.12.08q.65.6 1.25 1.4.96.15 1.8.41v-.14c.08-1.35-.28-2.04-.68-2.27M8 3.7a10 10 0 0 0-.7.7 14 14 0 0 1 1.4 0 10 10 0 0 0-.7-.7" clip-rule="evenodd"/>
1733
+ </symbol>`,$C=`<symbol id="file-tree-builtin-ruby" viewBox="0 0 16 16">
1734
+ <path fill="currentColor" fill-rule="evenodd" d="M11.04 2c.48 0 .92.23 1.18.6l2.54 3.65c.37.52.3 1.23-.15 1.69l-5.58 5.64a1.47 1.47 0 0 1-2.06 0L1.39 7.94a1.3 1.3 0 0 1-.15-1.7l2.54-3.63q.2-.3.5-.45.33-.16.68-.16zm.84 2.17a.5.5 0 0 0-.7-.05L8 6.84 4.83 4.12a.5.5 0 0 0-.65.76L6.65 7H3.5a.5.5 0 0 0 0 1h9a.5.5 0 0 0 0-1H9.35l2.48-2.12a.5.5 0 0 0 .05-.7" clip-rule="evenodd"/>
1735
+ </symbol>`,ew=`<symbol id="file-tree-builtin-rust" viewBox="0 0 16 16">
1736
+ <path fill="currentColor" fill-rule="evenodd" d="M8 .8a.2.2 0 0 1 .18.1l.38.6.16.02.5-.53.01-.01a.2.2 0 0 1 .33.08l.25.68.16.05.59-.43h.02a.2.2 0 0 1 .3.14l.12.71.15.08.65-.3a.2.2 0 0 1 .2.02.2.2 0 0 1 .1.18l-.03.72.12.1.71-.16a.2.2 0 0 1 .25.25l-.17.7q.06.06.1.13l.73-.03A.2.2 0 0 1 14 4a.2.2 0 0 1 .02.2l-.3.66.08.14.71.12a.2.2 0 0 1 .14.32l-.43.59.05.16.68.25a.2.2 0 0 1 .07.35l-.53.49.01.16.62.38a.2.2 0 0 1 0 .36l-.62.38-.01.16.53.5a.2.2 0 0 1-.07.34l-.68.25-.05.16.43.59a.2.2 0 0 1-.14.32l-.72.12-.07.15.3.65a.2.2 0 0 1-.02.2.2.2 0 0 1-.18.1l-.72-.03-.1.13.16.7a.2.2 0 0 1-.25.25l-.7-.17-.13.1.03.73a.2.2 0 0 1-.1.18.2.2 0 0 1-.2.02l-.66-.3-.14.08-.12.71a.2.2 0 0 1-.32.14l-.59-.43-.16.05-.25.68a.2.2 0 0 1-.34.07l-.5-.53-.16.01-.38.62a.2.2 0 0 1-.36 0l-.38-.62-.16-.01-.5.53a.2.2 0 0 1-.34-.07l-.25-.68-.16-.05-.59.43a.2.2 0 0 1-.32-.14L5 13.78l-.15-.07-.65.3a.2.2 0 0 1-.2-.02.2.2 0 0 1-.1-.18l.03-.72-.13-.1-.7.16a.2.2 0 0 1-.25-.25l.17-.7-.1-.13-.73.03a.2.2 0 0 1-.2-.3l.3-.66-.08-.14-.71-.12a.2.2 0 0 1-.14-.32l.43-.59-.05-.16-.68-.25A.2.2 0 0 1 1 9.22l.53-.5-.02-.16-.6-.38A.2.2 0 0 1 .8 8a.2.2 0 0 1 .1-.18l.6-.38.02-.16-.53-.5a.2.2 0 0 1 .07-.34l.68-.25.05-.16-.43-.59a.2.2 0 0 1 .14-.32L2.2 5l.08-.15L2 4.2a.2.2 0 0 1 .2-.3l.72.03.1-.13-.16-.7a.2.2 0 0 1 .25-.25l.7.16.13-.1-.03-.72A.2.2 0 0 1 4 2a.2.2 0 0 1 .2-.02l.65.3L5 2.2l.12-.71v-.03a.2.2 0 0 1 .32-.1l.59.41.16-.04.25-.68.01-.02A.2.2 0 0 1 6.8.99l.49.53.16-.02.38-.61.02-.02A.2.2 0 0 1 8 .79M6.8 9.45h1.26l.06.01q.03.01.03.05v1.52q0 .07-.09.06h-4.5A5.4 5.4 0 0 0 8 13.42a5.4 5.4 0 0 0 4.45-2.33h-2.42c-.36 0-.68-.5-.77-.75-.08-.22-.2-.91-.25-1.12-.15-.61-.59-.71-.78-.73H6.8zM8 2.58a5.4 5.4 0 0 0-4.07 1.85h5.74l.17.02c.23.03.6.12.96.35.34.23.83.68.83 1.4 0 .66-.55 1.16-1.08 1.5.42.33.7.53.86 1.44.04.17.34.32.62.29.29-.03.62-.16.62-.75v-.24q0-.1.07-.1h.68A5.43 5.43 0 0 0 8 2.59M2.96 6.03a5.4 5.4 0 0 0-.19 3.37h1.66V6.03zM6.8 7.06h1.66c.35 0 .77-.12.77-.47 0-.42-.55-.53-.65-.53H6.8z" clip-rule="evenodd"/>
1737
+ </symbol>`,tw=`<symbol id="file-tree-builtin-sass" viewBox="0 0 16 16">
1738
+ <path fill="currentColor" fill-rule="evenodd" d="M8.08 1.44c2.41-.91 4.96-.37 5.35 1.27.39 1.62-.92 3.56-2.6 4.25a5 5 0 0 1-3.26.35c-.58-.2-.92-.62-1-.85-.03-.09-.09-.24 0-.3.05-.03.08-.02.22.15s.7.6 1.75.48c2.78-.34 4.45-2.64 3.92-3.88-.37-.87-2.5-1.26-5.18.16C4.03 4.81 3.85 6.24 3.82 6.8c-.08 1.5 1.73 2.28 2.7 3.4q.04.03.07.08c.3-.12.7-.19 1.35-.2 1.58-.03 2.47 1.08 2.43 2.08-.03.78-.7 1.1-.82 1.13-.1.01-.14.02-.15-.06q-.03-.06.13-.15c.16-.09.42-.3.48-.72.05-.43-.24-1.44-1.76-1.63a3 3 0 0 0-1.33.08c.27.62.32 1.87-.29 2.83-.63 1-1.8 1.61-2.93 1.27-.37-.1-.93-.92-.45-2.05.46-1.07 2.4-2.12 2.66-2.26-.9-.83-3.08-1.95-3.4-3.65-.08-.49.13-1.65 1.46-2.98a12 12 0 0 1 4.11-2.52m-1.88 9.7c-.01.01-.9.47-1.52 1.17-.59.66-.75 1.48-.43 1.69.3.18 1-.04 1.51-.62a3 3 0 0 0 .5-.9q.2-.64.02-1.39z" clip-rule="evenodd"/>
1739
+ </symbol>`,nw=`<symbol id="file-tree-builtin-stylelint" viewBox="0 0 16 16">
1740
+ <path fill="currentColor" d="M4 3v3.5l1.5-1L7 15 .5 6l1-1.5L0 3l2.5-2h1zm12 0-1.5 1.5 1 1.5L9 15l1.5-9.5 1.5 1V3l.5-2h1zm-8 8.5a.5.5 0 1 1 0 1 .5.5 0 0 1 0-1m0-3a.5.5 0 1 1 0 1 .5.5 0 0 1 0-1m0-3a.5.5 0 1 1 0 1 .5.5 0 0 1 0-1"/>
1741
+ <path fill="currentColor" d="M6.5 2.5V4l-2 1.5v-4zm5 3L9.5 4V2.5l2-1zM9 4H7V2.5h2z"/>
1742
+ </symbol>`,rw=`<symbol id="file-tree-builtin-svelte" viewBox="0 0 16 16">
1743
+ <path fill="currentColor" d="m3.98 3.7 3.36-2.08a4.5 4.5 0 0 1 5.9 1.23 4 4 0 0 1 .7 3.02q-.16.75-.58 1.4c.42.77.56 1.66.4 2.52a3.7 3.7 0 0 1-1.57 2.4l-.17.1-3.36 2.09a4.5 4.5 0 0 1-5.9-1.23 4 4 0 0 1-.66-1.44 4 4 0 0 1-.04-1.58 4 4 0 0 1 .58-1.4 4 4 0 0 1-.4-2.52 3.7 3.7 0 0 1 1.57-2.4zl3.36-2.08zm7.87 0a2.7 2.7 0 0 0-1.26-.95 2.7 2.7 0 0 0-1.6-.07 3 3 0 0 0-.52.2l-.16.09-3.36 2.08a2 2 0 0 0-.69.64 2 2 0 0 0-.36.86 2.3 2.3 0 0 0 .42 1.81A2.7 2.7 0 0 0 7.18 9.4q.28-.06.53-.2l.16-.09 1.28-.79.2-.09a.8.8 0 0 1 .87.31.7.7 0 0 1 .13.55.7.7 0 0 1-.24.4l-.08.05-3.36 2.08-.2.09a1 1 0 0 1-.49-.02 1 1 0 0 1-.38-.3 1 1 0 0 1-.13-.37v-.1l.01-.13-.13-.03a4 4 0 0 1-1.1-.5l-.2-.14-.18-.12-.07.18-.08.3a2.3 2.3 0 0 0 .43 1.82q.45.64 1.19.93.73.28 1.51.14l.16-.04q.27-.07.52-.2l.16-.09 3.36-2.08q.4-.25.69-.64.27-.4.36-.86a2.3 2.3 0 0 0-.42-1.82 2.7 2.7 0 0 0-1.27-.95 2.7 2.7 0 0 0-1.6-.08q-.27.07-.52.2l-.16.1-1.28.79-.2.09a1 1 0 0 1-.49-.03 1 1 0 0 1-.38-.29.7.7 0 0 1-.13-.54.7.7 0 0 1 .24-.4l.08-.06L9.33 4.4l.2-.1a.8.8 0 0 1 .87.32 1 1 0 0 1 .13.38v.22l.11.04q.6.18 1.12.5l.2.14.17.12.06-.19.08-.3a2.3 2.3 0 0 0-.42-1.81z"/>
1744
+ </symbol>`,iw=`<symbol id="file-tree-builtin-svg" viewBox="0 0 16 16">
1745
+ <path fill="currentColor" d="M5 7a2 2 0 0 1 2-2h6a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2z"/>
1746
+ <path fill="currentColor" d="M6 1a5 5 0 0 1 4.58 3H7a3 3 0 0 0-3 3v3.58A5 5 0 0 1 6 1" opacity=".5"/>
1747
+ </symbol>`,aw=`<symbol id="file-tree-builtin-svgo" viewBox="0 0 16 16">
1748
+ <path fill="currentColor" d="M9.43 4.8A.6.6 0 1 1 9.19 6l-.56.96a1.2 1.2 0 0 1 .32 1.58l.7.53a.89.89 0 1 1-.17.22l-.7-.52a1.2 1.2 0 0 1-1.4.25l-.56.87a.75.75 0 1 1-.57-.2 1 1 0 0 1 .32.05l.56-.87a1.2 1.2 0 0 1-.4-1.24l-1.2-.47a.56.56 0 1 1 .1-.28v.02l1.2.47a1.2 1.2 0 0 1 1.56-.55l.56-.97a.6.6 0 0 1-.15-.64.6.6 0 0 1 .63-.4"/>
1749
+ <path fill="currentColor" fill-rule="evenodd" d="M9.17 1q.16.63.27 1.26a6 6 0 0 1 1.61.67q.52-.38 1.08-.71l1.65 1.64q-.32.56-.68 1.05.48.78.72 1.67.6.09 1.18.25v2.32q-.55.15-1.11.24a6 6 0 0 1-.7 1.82q.31.44.59.91l-1.65 1.65-.85-.55a6 6 0 0 1-1.9.83q-.08.47-.2.95H6.84q-.12-.46-.2-.93a6 6 0 0 1-1.96-.81q-.39.27-.8.51l-1.65-1.65q.25-.43.53-.84a6 6 0 0 1-.75-1.9L1 9.16V6.83q.54-.14 1.09-.24a6 6 0 0 1 .77-1.74q-.33-.47-.63-.98l1.65-1.65q.54.32 1.03.68a6 6 0 0 1 1.66-.66q.1-.61.26-1.24zM7.96 3.73a4 4 0 0 0-1.74.36 4.5 4.5 0 0 0-2.3 2.3 4.4 4.4 0 0 0-.1 3.29l.03.06a4.4 4.4 0 0 0 2.4 2.47 4.4 4.4 0 0 0 3.48-.02l.03-.02a4.4 4.4 0 0 0 2.3-2.42l.06-.14a4.4 4.4 0 0 0-.2-3.4 4.4 4.4 0 0 0-2.13-2.07L9.47 4a4 4 0 0 0-1.51-.27" clip-rule="evenodd"/>
1750
+ </symbol>`,ow=`<symbol id="file-tree-builtin-swift" viewBox="0 0 16 16">
1751
+ <path fill="currentColor" d="M9.63 1c6.15 4.35 4.16 9.15 4.16 9.15s1.75 2.05 1.04 3.85c0 0-.72-1.26-1.93-1.26-1.17 0-1.85 1.26-4.2 1.26C3.47 14 1 9.46 1 9.46c4.71 3.22 7.93.94 7.93.94C6.8 9.12 2.29 3 2.29 3c3.93 3.47 5.63 4.39 5.63 4.39-1.01-.87-3.86-5.13-3.86-5.13C6.34 4.66 10.86 8 10.86 8c1.28-3.7-1.23-7-1.23-7"/>
1752
+ </symbol>`,sw=`<symbol id="file-tree-builtin-table" viewBox="0 0 16 16">
1753
+ <path fill="currentColor" d="M8 4a3 3 0 0 0 3 3h3v5.5a2.5 2.5 0 0 1-2.5 2.5h-7A2.5 2.5 0 0 1 2 12.5v-9A2.5 2.5 0 0 1 4.5 1H8z" class="bg" opacity=".4"/>
1754
+ <path fill="currentColor" d="M11.5 8a.5.5 0 0 1 .5.5v4a.5.5 0 0 1-.5.5h-7a.5.5 0 0 1-.5-.5v-4a.5.5 0 0 1 .5-.5zM5 12h2.5v-1H5zm3.5 0H11v-1H8.5zM5 10h2.5V9H5zm3.5 0H11V9H8.5zm1-9a.5.5 0 0 1 .354.146l4 4A.5.5 0 0 1 14 5.5V6h-3a2 2 0 0 1-2-2V1z" class="fg"/>
1755
+ </symbol>`,cw=`<symbol id="file-tree-builtin-tailwind" viewBox="0 0 16 16">
1756
+ <path fill="currentColor" fill-rule="evenodd" d="M8 4Q5.2 4 4.5 6.67q1.05-1.34 2.45-1c.53.12.91.5 1.33.9C8.98 7.23 9.77 8 11.5 8q2.8 0 3.5-2.67-1.05 1.34-2.45 1c-.53-.12-.91-.5-1.33-.9C10.52 4.77 9.73 4 8 4M4.5 8Q1.7 8 1 10.67q1.05-1.34 2.45-1c.53.12.91.5 1.33.9C5.48 11.23 6.26 12 8 12q2.8 0 3.5-2.67-1.05 1.34-2.45 1c-.53-.12-.91-.5-1.33-.9C7.02 8.77 6.24 8 4.5 8" clip-rule="evenodd"/>
1757
+ </symbol>`,lw=`<symbol id="file-tree-builtin-terraform" viewBox="0 0 16 16">
1758
+ <path fill="currentColor" d="M1 0v5.05l4.35 2.53V2.53zm9.18 5.34L5.83 2.82v5.05l4.35 2.53zm.47 5.06V5.34L15 2.82v5.05zm-.48 5.6-4.35-2.53V8.42l4.35 2.53z"/>
1759
+ </symbol>`,uw=`<symbol id="file-tree-builtin-text" viewBox="0 0 16 16">
1760
+ <path fill="currentColor" fill-rule="evenodd" d="M8 4a3 3 0 0 0 3 3h3v5.5a2.5 2.5 0 0 1-2.5 2.5h-7A2.5 2.5 0 0 1 2 12.5v-9A2.5 2.5 0 0 1 4.5 1H8z" class="bg" clip-rule="evenodd" opacity=".4"/>
1761
+ <path fill="currentColor" d="M8.5 11a.5.5 0 0 1 0 1h-3a.5.5 0 0 1 0-1zm2-2a.5.5 0 0 1 0 1h-5a.5.5 0 0 1 0-1zm-1-8a.5.5 0 0 1 .354.146l4 4A.5.5 0 0 1 14 5.5V6h-3a2 2 0 0 1-2-2V1z"/>
1762
+ </symbol>`,dw=`<symbol id="file-tree-builtin-typescript" viewBox="0 0 16 16">
1763
+ <path fill="currentColor" d="M8 1C2.24 1 1 2.24 1 8s1.24 7 7 7 7-1.24 7-7-1.24-7-7-7" class="bg" opacity=".2"/>
1764
+ <path fill="currentColor" d="M8.1 9.64h.95c.04.62.28.76 1.28.76s1.2-.14 1.2-.85c0-.66-.2-.85-1.2-1.07-1.79-.38-2.18-.7-2.18-1.86C8.15 5.3 8.54 5 10.31 5c1.67 0 2.04.26 2.07 1.42h-.95c-.02-.43-.23-.53-1.1-.53-1 0-1.22.14-1.22.74 0 .52.22.7 1.24.92 1.76.38 2.15.73 2.15 2 0 1.44-.4 1.75-2.24 1.75-1.8 0-2.18-.3-2.15-1.66m-3 1.57V5.99H3.5v-.9h4.21v.9H6.1v5.22z"/>
1765
+ </symbol>`,fw=`<symbol id="file-tree-builtin-vite" viewBox="0 0 16 16">
1766
+ <path fill="currentColor" d="M8.57 14.87c-.18.26-.55.11-.55-.22v-3.18l-.05-.27-.13-.22-.2-.15-.24-.06H4.29c-.26 0-.4-.32-.26-.55L6.08 7c.3-.46 0-1.1-.5-1.1H1.8c-.25 0-.4-.32-.25-.56l2.65-4.2A.3.3 0 0 1 4.46 1h7.9c.26 0 .4.32.26.55l-2.05 3.23c-.29.46 0 1.1.5 1.1h3.12c.26 0 .4.34.24.57z"/>
1767
+ </symbol>`,pw=`<symbol id="file-tree-builtin-vscode" viewBox="0 0 16 16">
1768
+ <path fill="currentColor" d="m5.11 9.68-2.4 1.84a.6.6 0 0 1-.75-.04l-.77-.7a.6.6 0 0 1 0-.87L3.28 8zm5.52-8.42a.51.51 0 0 1 .87.36V4.8L7.32 8 5.1 6.32z" opacity=".75"/>
1769
+ <path fill="currentColor" d="M11.1 14.99h.03zM1.96 4.52a.6.6 0 0 1 .75-.04l8.8 6.71v3.19a.51.51 0 0 1-.88.36L1.19 6.1a.6.6 0 0 1 0-.87z" opacity=".65"/>
1770
+ <path fill="currentColor" d="M11.62 14.91a.9.9 0 0 1-1-.17.51.51 0 0 0 .88-.36V1.62a.51.51 0 0 0-.87-.36.9.9 0 0 1 1-.17l2.87 1.39a.9.9 0 0 1 .5.8v9.44a.9.9 0 0 1-.5.8z"/>
1771
+ </symbol>`,mw=`<symbol id="file-tree-builtin-vue" viewBox="0 0 16 16">
1772
+ <path fill="currentColor" d="M9.62 2.25 8 5.02 6.38 2.25H1l7 12 7-12z" opacity=".5"/>
1773
+ <path fill="currentColor" d="M9.54 2.25 8 4.95l-1.54-2.7H4l4 7 4-7z"/>
1774
+ </symbol>`,hw=`<symbol id="file-tree-builtin-wasm" viewBox="0 0 16 16">
1775
+ <path fill="currentColor" d="M13 1a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H3a2 2 0 0 1-2-2V3a2 2 0 0 1 2-2h3a2 2 0 1 0 4 0z" class="subtract" opacity=".2"/>
1776
+ <path fill="currentColor" d="M4.64 11.4h.02l.8-3.4h.91l.73 3.45L7.88 8h.96l-1.25 5h-.97L5.9 9.6 5.1 13h-1L3 8h.98z"/>
1777
+ <path fill="currentColor" fill-rule="evenodd" d="M13 13h-1.02l-.33-1.11H9.9L9.64 13h-.97l1.26-5h1.54zm-2.49-3.77-.42 1.84h1.32l-.49-1.84z" clip-rule="evenodd"/>
1778
+ </symbol>`,gw=`<symbol id="file-tree-builtin-webpack" viewBox="0 0 16 16">
1779
+ <path fill="currentColor" d="M14.1 11.79 8.26 15v-2.5l3.64-1.94zm.4-.35V4.73l-2.14 1.2v4.3zm-12.6.35L7.74 15v-2.5L4.1 10.56zm-.4-.35V4.73l2.14 1.2v4.3zm.25-7.15 6-3.29v2.42L3.9 5.47l-.03.01zm12.5 0L8.25 1v2.42l3.85 2.05.03.01z" class="bg" opacity=".4"/>
1780
+ <path fill="currentColor" d="m7.74 11.93-3.59-1.92v-3.8l3.6 2.02zm.52 0 3.59-1.92v-3.8l-3.6 2.02zM4.4 5.77 8 3.85l3.6 1.93L8 7.8z" class="fg"/>
1781
+ </symbol>`,_w=`<symbol id="file-tree-builtin-yml" viewBox="0 0 16 16">
1782
+ <path fill="currentColor" d="M7.5 2A1.5 1.5 0 0 1 9 3.5v3A1.5 1.5 0 0 1 7.5 8h-2v2A1.5 1.5 0 0 0 7 11.5v-1A1.5 1.5 0 0 1 8.5 9h5a1.5 1.5 0 0 1 1.5 1.5v3a1.5 1.5 0 0 1-1.5 1.5h-5A1.5 1.5 0 0 1 7 13.5v-1A2.5 2.5 0 0 1 4.5 10V8h-2A1.5 1.5 0 0 1 1 6.5v-3A1.5 1.5 0 0 1 2.5 2zm1 8a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h5a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5zm-6-7a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h5a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5z"/>
1783
+ </symbol>`,vw=`<symbol id="file-tree-builtin-zig" viewBox="0 0 16 16">
1784
+ <path fill="currentColor" d="m14.73 1.5-7.29 8.82h4.17l-1.73 2.04H5.76L1.27 14.5l7.3-8.91H4.39l1.73-2.05h4.12z"/>
1785
+ <path fill="currentColor" d="M5.21 3.54 3.56 5.6h-.55v4.73h.83L2.1 12.36H1V3.54zm9.79 0v8.82h-4.3l1.74-2.04h.55V5.68h-.83l1.74-2.14z"/>
1786
+ </symbol>`,yw=[CC,OC,AC,jC,MC,NC,IC,LC,RC,BC,VC,HC,UC,WC,GC,ZC,$C,ew,ow,sw,uw,dw,`<symbol id="file-tree-builtin-zip" viewBox="0 0 16 16">
1787
+ <path fill="currentColor" d="M4.585 2a2 2 0 0 1 1.028.285l1.788 1.072a1 1 0 0 0 .514.143H12A2 2 0 0 1 13.935 5H0V4a2 2 0 0 1 2-2z" class="bg" opacity=".5"/>
1788
+ <path fill="currentColor" fill-rule="evenodd" d="M14 12a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2v-1.25h1v-1H0V6h14zM9.9 8.25c-.883 0-1.9.5-1.9.5H7v1h1v1s1.017.5 1.9.5c.884 0 1.6-.672 1.6-1.5s-.716-1.5-1.6-1.5M2 9.75v1h1v-1zm2 0v1h1v-1zm2 0v1h1v-1zm-5-1v1h1v-1zm2 0v1h1v-1zm2 0v1h1v-1z" class="fg" clip-rule="evenodd"/>
1789
+ </symbol>`],bw=[xC,SC,wC,TC,EC,DC,kC,PC,FC,zC,KC,qC,JC,YC,XC,QC,tw,nw,rw,iw,aw,cw,lw,fw,pw,mw,hw,gw,_w,vw];function xw(e,t){return t.length===0?e:e.replace(`</svg>`,`\n ${t.join(`
1790
+ `)}\n</svg>`)}var Sw=xw(bC,yw),Cw={minimal:bC,standard:Sw,complete:xw(Sw,bw)},ww={".babelrc":`babel`,".babelrc.json":`babel`,".bash_profile":`bash`,".bashrc":`bash`,".browserslistrc":`browserslist`,".dockerignore":`docker`,".eslintignore":`eslint`,".eslintrc":`eslint`,".eslintrc.cjs":`eslint`,".eslintrc.js":`eslint`,".eslintrc.json":`eslint`,".eslintrc.yaml":`eslint`,".eslintrc.yml":`eslint`,".gitattributes":`git`,".gitignore":`git`,".gitkeep":`git`,".gitmodules":`git`,".oxlintrc.json":`oxc`,".postcssrc":`postcss`,".postcssrc.json":`postcss`,".postcssrc.yaml":`postcss`,".postcssrc.yml":`postcss`,".prettierignore":`prettier`,".prettierrc":`prettier`,".prettierrc.cjs":`prettier`,".prettierrc.js":`prettier`,".prettierrc.json":`prettier`,".prettierrc.mjs":`prettier`,".prettierrc.toml":`prettier`,".prettierrc.yaml":`prettier`,".prettierrc.yml":`prettier`,".stylelintignore":`stylelint`,".stylelintrc":`stylelint`,".stylelintrc.cjs":`stylelint`,".stylelintrc.js":`stylelint`,".stylelintrc.json":`stylelint`,".stylelintrc.mjs":`stylelint`,".stylelintrc.yaml":`stylelint`,".stylelintrc.yml":`stylelint`,".terraform.lock.hcl":`terraform`,".zprofile":`bash`,".zshenv":`bash`,".zshrc":`bash`,"babel.config.cjs":`babel`,"babel.config.js":`babel`,"babel.config.json":`babel`,"babel.config.mjs":`babel`,"biome.json":`biome`,"biome.jsonc":`biome`,"bootstrap.bundle.js":`bootstrap`,"bootstrap.bundle.min.js":`bootstrap`,"bootstrap.css":`bootstrap`,"bootstrap.js":`bootstrap`,"bootstrap.min.css":`bootstrap`,"bootstrap.min.js":`bootstrap`,"bun.lock":`bun`,"bun.lockb":`bun`,"bunfig.toml":`bun`,"claude.md":`claude`,"compose.yaml":`docker`,"compose.yml":`docker`,"docker-compose.override.yml":`docker`,"docker-compose.yaml":`docker`,"docker-compose.yml":`docker`,dockerfile:`docker`,"eslint.config.cjs":`eslint`,"eslint.config.js":`eslint`,"eslint.config.mjs":`eslint`,"eslint.config.mts":`eslint`,"eslint.config.ts":`eslint`,gemfile:`ruby`,"next.config.js":`nextjs`,"next.config.mjs":`nextjs`,"next.config.mts":`nextjs`,"next.config.ts":`nextjs`,"postcss.config.cjs":`postcss`,"postcss.config.js":`postcss`,"postcss.config.mjs":`postcss`,"postcss.config.ts":`postcss`,"prettier.config.cjs":`prettier`,"prettier.config.js":`prettier`,"prettier.config.mjs":`prettier`,rakefile:`ruby`,"readme.md":`markdown`,"stylelint.config.cjs":`stylelint`,"stylelint.config.js":`stylelint`,"stylelint.config.mjs":`stylelint`,"svgo.config.cjs":`svgo`,"svgo.config.js":`svgo`,"svgo.config.mjs":`svgo`,"svgo.config.ts":`svgo`,"tailwind.config.cjs":`tailwind`,"tailwind.config.js":`tailwind`,"tailwind.config.mjs":`tailwind`,"tailwind.config.ts":`tailwind`,"vite.config.js":`vite`,"vite.config.mjs":`vite`,"vite.config.mts":`vite`,"vite.config.ts":`vite`,"webpack.config.babel.js":`webpack`,"webpack.config.cjs":`webpack`,"webpack.config.js":`webpack`,"webpack.config.mjs":`webpack`,"webpack.config.ts":`webpack`},Tw={"7z":`zip`,astro:`astro`,AUTHORS:`text`,avif:`image`,bash:`bash`,bmp:`image`,bz2:`zip`,c:`c`,cc:`cpp`,cfg:`text`,CHANGELOG:`text`,cjs:`javascript`,"code-workspace":`vscode`,conf:`text`,CONTRIBUTORS:`text`,cpp:`cpp`,csh:`bash`,css:`css`,csv:`table`,cts:`typescript`,cxx:`cpp`,db:`database`,editorconfig:`text`,env:`text`,"env.development":`text`,"env.local":`text`,"env.production":`text`,eot:`font`,erb:`ruby`,fish:`bash`,gemspec:`ruby`,gif:`image`,go:`go`,gql:`graphql`,graphql:`graphql`,gz:`zip`,h:`c`,hh:`cpp`,hpp:`cpp`,htm:`html`,html:`html`,hxx:`cpp`,icns:`image`,ico:`image`,ini:`text`,inl:`cpp`,jar:`zip`,jpeg:`image`,jpg:`image`,js:`javascript`,json:`json`,json5:`json`,jsonc:`json`,jsonl:`json`,jsx:`javascript`,ksh:`bash`,less:`css`,LICENSE:`text`,log:`text`,markdown:`markdown`,mcp:`mcp`,md:`markdown`,mdx:`markdown`,"mdx.tsx":`markdown`,mjs:`javascript`,mm:`cpp`,mts:`typescript`,ods:`table`,otf:`font`,png:`image`,postcss:`css`,py:`python`,pyi:`python`,pyw:`python`,pyx:`python`,rake:`ruby`,rar:`zip`,rb:`ruby`,rs:`rust`,rst:`text`,rtf:`text`,sass:`css`,scss:`css`,sh:`bash`,sql:`database`,sqlite:`database`,sqlite3:`database`,styl:`css`,svelte:`svelte`,svg:`svg`,swift:`swift`,tar:`zip`,tf:`terraform`,tfstate:`terraform`,tfvars:`terraform`,tgz:`zip`,tif:`image`,tiff:`image`,ts:`typescript`,tsv:`table`,tsx:`typescript`,ttf:`font`,txt:`text`,vue:`vue`,war:`zip`,wasm:`wasm`,wast:`wasm`,wat:`wasm`,webp:`image`,woff:`font`,woff2:`font`,xhtml:`html`,xls:`table`,xlsx:`table`,xz:`zip`,yaml:`yml`,yml:`yml`,zig:`zig`,zip:`zip`,zsh:`bash`},Ew={jsx:`react`,sass:`sass`,scss:`sass`,tsx:`react`},Dw=new Set([`bash`,`c`,`cpp`,`css`,`database`,`default`,`font`,`git`,`go`,`html`,`image`,`javascript`,`json`,`markdown`,`mcp`,`python`,`ruby`,`rust`,`swift`,`table`,`text`,`typescript`,`zip`]),Ow=new Set([`complete`]);function kw(e){return Cw[e===`none`?`minimal`:e]}function Aw(e){return`file-tree-builtin-${e}`}function jw(e){return e!==`none`&&Ow.has(e)}function Mw(e,t,n){if(e===`minimal`||e===`none`)return;let r=e===`complete`,i=ww[t.toLowerCase()];if(i!=null&&(r||Dw.has(i)))return i;for(let e of n){if(r){let t=Ew[e];if(t!=null)return t}let t=Tw[e];if(t!=null&&(r||Dw.has(t)))return t}return`default`}var Nw=`file-tree-container`,Pw=`data-file-tree-style`,Fw=`data-file-tree-unsafe-css`,Iw=`data-file-tree-scrollbar-measure`,Lw=`data-file-tree-scrollbar-gutter-measured`,Rw=`--trees-scrollbar-gutter-measured`,zw=`header`,Bw=`context-menu`,Vw=`context-menu-trigger`;function Hw(e){return e.spriteSheet!=null||e.remap!=null||e.byFileName!=null||e.byFileExtension!=null||e.byFileNameContains!=null}function Uw(e){return e==null?{set:`complete`,colored:!0}:typeof e==`string`?{set:e,colored:!0}:{...e,set:e.set??(Hw(e)?`none`:`complete`),colored:e.colored??!0}}var Ww={compact:{itemHeight:24,factor:.8},default:{itemHeight:30,factor:1},relaxed:{itemHeight:36,factor:1.2}};function Gw(e,t){if(typeof e==`number`)return{itemHeight:t??Ww.default.itemHeight,factor:e};let n=Ww[e??`default`];return{itemHeight:t??n.itemHeight,factor:n.factor}}var Kw=Ww.default.itemHeight,qw=`@layer base {
1791
+ :host {
1792
+ --trees-accent: var(--trees-accent-override, #009fff);
1793
+ --trees-fg: var(--trees-fg-override, var(--trees-theme-sidebar-fg, light-dark(#6c6c71, #adadb1)));
1794
+ --trees-fg-muted: var(--trees-fg-muted-override, var(--trees-theme-sidebar-header-fg, light-dark(#84848a, #84848a)));
1795
+ --trees-bg: var(--trees-bg-override, var(--trees-theme-sidebar-bg, light-dark(#f8f8f8, #141415)));
1796
+ --trees-bg-muted: var(--trees-bg-muted-override, var(--trees-theme-list-hover-bg, light-dark(color-mix(in lab,
1797
+ var(--trees-accent) var(--trees-bg-alpha-light, 8%),
1798
+ var(--trees-bg)), color-mix(in lab,
1799
+ var(--trees-accent) var(--trees-bg-alpha-dark, 10%),
1800
+ var(--trees-bg)))));
1801
+ --trees-input-bg: var(--trees-input-bg-override, light-dark(#f8f8f8, #070707));
1802
+ --trees-added-light: #16a994;
1803
+ --trees-added-dark: #00cab1;
1804
+ --trees-ignored-light: #adadb1;
1805
+ --trees-ignored-dark: #4a4a4e;
1806
+ --trees-modified-light: #1ca1c7;
1807
+ --trees-modified-dark: #08c0ef;
1808
+ --trees-renamed-light: #d5a910;
1809
+ --trees-renamed-dark: #ffd452;
1810
+ --trees-untracked-light: #16a994;
1811
+ --trees-untracked-dark: #00cab1;
1812
+ --trees-deleted-light: #ff2e3f;
1813
+ --trees-deleted-dark: #ff6762;
1814
+ --trees-border-color: var(--trees-border-color-override, var(--trees-theme-sidebar-border, light-dark(#eeeeef, #070707)));
1815
+ --trees-indent-guide-bg: var(--trees-indent-guide-bg-override, color-mix(in lab, var(--trees-fg-muted) 25%, transparent));
1816
+ --trees-density: var(--trees-density-override, 1);
1817
+ --trees-border-radius: var(--trees-border-radius-override, calc(6px * var(--trees-density)));
1818
+ --trees-font-family: var(--trees-font-family-override, system-ui);
1819
+ --trees-font-size: var(--trees-font-size-override, 13px);
1820
+ --trees-font-weight-regular: var(--trees-font-weight-regular-override, 400);
1821
+ --trees-font-weight-semibold: var(--trees-font-weight-semibold-override, 600);
1822
+ --trees-focus-ring-color: var(--trees-focus-ring-color-override, var(--trees-theme-focus-ring, var(--trees-accent)));
1823
+ --trees-focus-ring-width: var(--trees-focus-ring-width-override, 1px);
1824
+ --trees-focus-ring-offset: var(--trees-focus-ring-offset-override, -1px);
1825
+ --trees-search-fg: var(--trees-search-fg-override, var(--trees-theme-input-fg, var(--trees-fg)));
1826
+ --trees-search-font-weight: var(--trees-search-font-weight-override, 600);
1827
+ --trees-search-bg: var(--trees-search-bg-override, var(--trees-theme-input-bg, var(--trees-input-bg)));
1828
+ --trees-scrollbar-thumb: var(--trees-scrollbar-thumb-override, var(--trees-theme-scrollbar-thumb, color-mix(in lab, var(--trees-fg) 25%, var(--trees-bg))));
1829
+ --trees-selected-fg: var(--trees-selected-fg-override, var(--trees-theme-list-active-selection-fg, var(--trees-fg)));
1830
+ --trees-selected-bg: var(--trees-selected-bg-override, var(--trees-theme-list-active-selection-bg, light-dark(color-mix(in lab, var(--trees-accent) 12%, var(--trees-bg)), color-mix(in lab, var(--trees-accent) 15%, var(--trees-bg)))));
1831
+ --trees-selected-focused-border-color: var(--trees-selected-focused-border-color-override, var(--trees-theme-focus-ring, var(--trees-accent)));
1832
+ --trees-status-added: var(--trees-status-added-override, var(--trees-theme-git-added-fg, light-dark(var(--trees-added-light), var(--trees-added-dark))));
1833
+ --trees-status-ignored: var(--trees-status-ignored-override, var(--trees-theme-git-ignored-fg, light-dark(var(--trees-ignored-light), var(--trees-ignored-dark))));
1834
+ --trees-status-modified: var(--trees-status-modified-override, var(--trees-theme-git-modified-fg, light-dark(var(--trees-modified-light), var(--trees-modified-dark))));
1835
+ --trees-status-renamed: var(--trees-status-renamed-override, var(--trees-theme-git-renamed-fg, light-dark(var(--trees-renamed-light), var(--trees-renamed-dark))));
1836
+ --trees-status-untracked: var(--trees-status-untracked-override, var(--trees-theme-git-untracked-fg, light-dark(var(--trees-untracked-light), var(--trees-untracked-dark))));
1837
+ --trees-status-deleted: var(--trees-status-deleted-override, var(--trees-theme-git-deleted-fg, light-dark(var(--trees-deleted-light), var(--trees-deleted-dark))));
1838
+ --trees-git-modified-color: var(--trees-git-modified-color-override, var(--trees-status-modified));
1839
+ --trees-git-added-color: var(--trees-git-added-color-override, var(--trees-status-added));
1840
+ --trees-git-ignored-color: var(--trees-git-ignored-color-override, var(--trees-status-ignored));
1841
+ --trees-git-deleted-color: var(--trees-git-deleted-color-override, var(--trees-status-deleted));
1842
+ --trees-git-renamed-color: var(--trees-git-renamed-color-override, var(--trees-status-renamed));
1843
+ --trees-git-untracked-color: var(--trees-git-untracked-color-override, var(--trees-status-untracked));
1844
+ --trees-icon-gray: light-dark(#84848a, #adadb1);
1845
+ --trees-icon-red: light-dark(#d52c36, #ff6762);
1846
+ --trees-icon-vermilion: light-dark(#ff8c5b, #d5512f);
1847
+ --trees-icon-orange: light-dark(#d47628, #ffa359);
1848
+ --trees-icon-yellow: light-dark(#d5a910, #ffd452);
1849
+ --trees-icon-green: light-dark(#199f43, #5ecc71);
1850
+ --trees-icon-teal: light-dark(#17a5af, #64d1db);
1851
+ --trees-icon-cyan: light-dark(#1ca1c7, #68cdf2);
1852
+ --trees-icon-blue: light-dark(#1a85d4, #69b1ff);
1853
+ --trees-icon-indigo: light-dark(#693acf, #9d6afb);
1854
+ --trees-icon-purple: light-dark(#a631be, #d568ea);
1855
+ --trees-icon-pink: light-dark(#d32a61, #ff678d);
1856
+ --trees-icon-mauve: light-dark(#594c5b, #79697b);
1857
+ --trees-file-icon-color-default: var(--trees-file-icon-color, var(--trees-icon-gray));
1858
+ --trees-file-icon-color-astro: var(--trees-file-icon-color, var(--trees-icon-purple));
1859
+ --trees-file-icon-color-babel: var(--trees-file-icon-color, var(--trees-icon-yellow));
1860
+ --trees-file-icon-color-bash: var(--trees-file-icon-color, var(--trees-icon-green));
1861
+ --trees-file-icon-color-biome: var(--trees-file-icon-color, var(--trees-icon-blue));
1862
+ --trees-file-icon-color-bootstrap: var(--trees-file-icon-color, var(--trees-icon-indigo));
1863
+ --trees-file-icon-color-browserslist: var(--trees-file-icon-color, var(--trees-icon-yellow));
1864
+ --trees-file-icon-color-bun: var(--trees-file-icon-color, var(--trees-icon-mauve));
1865
+ --trees-file-icon-color-c: var(--trees-file-icon-color, var(--trees-icon-blue));
1866
+ --trees-file-icon-color-cpp: var(--trees-file-icon-color, var(--trees-icon-blue));
1867
+ --trees-file-icon-color-claude: var(--trees-file-icon-color, var(--trees-icon-orange));
1868
+ --trees-file-icon-color-css: var(--trees-file-icon-color, var(--trees-icon-indigo));
1869
+ --trees-file-icon-color-database: var(--trees-file-icon-color, var(--trees-icon-purple));
1870
+ --trees-file-icon-color-docker: var(--trees-file-icon-color, var(--trees-icon-blue));
1871
+ --trees-file-icon-color-eslint: var(--trees-file-icon-color, var(--trees-icon-indigo));
1872
+ --trees-file-icon-color-git: var(--trees-file-icon-vermilion, var(--trees-icon-vermilion));
1873
+ --trees-file-icon-color-go: var(--trees-file-icon-color, var(--trees-icon-cyan));
1874
+ --trees-file-icon-color-graphql: var(--trees-file-icon-color, var(--trees-icon-pink));
1875
+ --trees-file-icon-color-html: var(--trees-file-icon-color, var(--trees-icon-orange));
1876
+ --trees-file-icon-color-image: var(--trees-file-icon-color, var(--trees-icon-pink));
1877
+ --trees-file-icon-color-javascript: var(--trees-file-icon-color, var(--trees-icon-yellow));
1878
+ --trees-file-icon-color-json: var(--trees-file-icon-color, var(--trees-icon-orange));
1879
+ --trees-file-icon-color-markdown: var(--trees-file-icon-color, var(--trees-icon-green));
1880
+ --trees-file-icon-color-mcp: var(--trees-file-icon-color, var(--trees-icon-teal));
1881
+ --trees-file-icon-color-npm: var(--trees-file-icon-color, var(--trees-icon-red));
1882
+ --trees-file-icon-color-oxc: var(--trees-file-icon-cyan, var(--trees-icon-cyan));
1883
+ --trees-file-icon-color-postcss: var(--trees-file-icon-color, var(--trees-icon-red));
1884
+ --trees-file-icon-color-prettier: var(--trees-file-icon-color, var(--trees-icon-teal));
1885
+ --trees-file-icon-color-python: var(--trees-file-icon-color, var(--trees-icon-blue));
1886
+ --trees-file-icon-color-react: var(--trees-file-icon-color, var(--trees-icon-cyan));
1887
+ --trees-file-icon-color-ruby: var(--trees-file-icon-color, var(--trees-icon-red));
1888
+ --trees-file-icon-color-rust: var(--trees-file-icon-color, var(--trees-icon-orange));
1889
+ --trees-file-icon-color-sass: var(--trees-file-icon-color, var(--trees-icon-pink));
1890
+ --trees-file-icon-color-svg: var(--trees-file-icon-color, var(--trees-icon-orange));
1891
+ --trees-file-icon-color-svelte: var(--trees-file-icon-color, var(--trees-icon-red));
1892
+ --trees-file-icon-color-svgo: var(--trees-file-icon-color, var(--trees-icon-green));
1893
+ --trees-file-icon-color-swift: var(--trees-file-icon-color, var(--trees-icon-orange));
1894
+ --trees-file-icon-color-table: var(--trees-file-icon-color, var(--trees-icon-teal));
1895
+ --trees-file-icon-color-text: var(--trees-file-icon-color, var(--trees-icon-gray));
1896
+ --trees-file-icon-color-tailwind: var(--trees-file-icon-color, var(--trees-icon-cyan));
1897
+ --trees-file-icon-color-terraform: var(--trees-file-icon-color, var(--trees-icon-indigo));
1898
+ --trees-file-icon-color-typescript: var(--trees-file-icon-color, var(--trees-icon-blue));
1899
+ --trees-file-icon-color-vite: var(--trees-file-icon-color, var(--trees-icon-purple));
1900
+ --trees-file-icon-color-vscode: var(--trees-file-icon-color, var(--trees-icon-blue));
1901
+ --trees-file-icon-color-vue: var(--trees-file-icon-color, var(--trees-icon-green));
1902
+ --trees-file-icon-color-wasm: var(--trees-file-icon-color, var(--trees-icon-indigo));
1903
+ --trees-file-icon-color-webpack: var(--trees-file-icon-color, var(--trees-icon-blue));
1904
+ --trees-file-icon-color-yml: var(--trees-file-icon-color, var(--trees-icon-red));
1905
+ --trees-file-icon-color-zig: var(--trees-file-icon-color, var(--trees-icon-orange));
1906
+ --trees-file-icon-color-zip: var(--trees-file-icon-color, var(--trees-icon-orange));
1907
+ --trees-level-gap: var(--trees-level-gap-override, calc(8px * var(--trees-density)));
1908
+ --trees-item-padding-x: var(--trees-item-padding-x-override, calc(8px * var(--trees-density)));
1909
+ --trees-item-margin-x: var(--trees-item-margin-x-override, calc(2px * var(--trees-density)));
1910
+ --trees-item-row-gap: var(--trees-item-row-gap-override, calc(6px * var(--trees-density)));
1911
+ --trees-icon-width: var(--trees-icon-width-override, 16px);
1912
+ --trees-icon-nudge: var(--trees-icon-nudge-override, calc(1px * var(--trees-density)));
1913
+ --trees-row-height: var(--trees-item-height, 30px);
1914
+ --trees-git-lane-width: var(--trees-git-lane-width-override, 12px);
1915
+ --trees-action-lane-width: var(--trees-action-lane-width-override, calc(var(--trees-icon-width) + 2px));
1916
+ --trees-context-menu-trigger-inline-offset: calc(var(--trees-padding-inline) + var(--trees-item-padding-x) -
1917
+ var(--trees-focus-ring-width));
1918
+ --trees-scrollbar-gutter: var(--trees-scrollbar-gutter-override, 6px);
1919
+ --trees-padding-inline: var(--trees-padding-inline-override, 16px);
1920
+ color-scheme: light dark;
1921
+ font-size: var(--trees-font-size);
1922
+ color: var(--trees-fg);
1923
+ background-color: var(--trees-bg);
1924
+ --truncate-marker-background-color: var(--trees-bg);
1925
+ --truncate-marker-background-overlay-color: transparent;
1926
+ font-family: var(--trees-font-family);
1927
+ font-weight: var(--trees-font-weight-regular);
1928
+ flex-direction: column;
1929
+ display: flex;
1930
+ }
1931
+
1932
+ :host([data-file-tree-virtualized="true"]) {
1933
+ height: 100%;
1934
+ overflow: hidden;
1935
+ }
1936
+
1937
+ [data-file-tree-virtualized-wrapper="true"], [data-file-tree-virtualized-root="true"] {
1938
+ flex-direction: column;
1939
+ height: 100%;
1940
+ display: flex;
1941
+ overflow: hidden;
1942
+ }
1943
+
1944
+ [data-file-tree-virtualized-scroll="true"], [data-file-tree-scrollbar-measure="true"] {
1945
+ --trees-scrollbar-thumb-current: transparent;
1946
+ scrollbar-gutter: stable;
1947
+ overflow-y: auto;
1948
+
1949
+ &:hover {
1950
+ --trees-scrollbar-thumb-current: var(--trees-scrollbar-thumb);
1951
+ }
1952
+
1953
+ &::-webkit-scrollbar {
1954
+ width: var(--trees-scrollbar-gutter);
1955
+ height: var(--trees-scrollbar-gutter);
1956
+ }
1957
+
1958
+ &::-webkit-scrollbar-track {
1959
+ background: none;
1960
+ }
1961
+
1962
+ &::-webkit-scrollbar-thumb {
1963
+ background-color: var(--trees-scrollbar-thumb-current);
1964
+ border-radius: calc(var(--trees-scrollbar-gutter) / 2);
1965
+ background-clip: content-box;
1966
+ border: 1px solid #0000;
1967
+ }
1968
+
1969
+ &::-webkit-scrollbar-corner {
1970
+ background-color: #0000;
1971
+ }
1972
+ }
1973
+
1974
+ [data-file-tree-scrollbar-measure="true"] {
1975
+ visibility: hidden;
1976
+ pointer-events: none;
1977
+ width: 100px;
1978
+ height: 100px;
1979
+ position: absolute;
1980
+ top: 0;
1981
+ left: 0;
1982
+ }
1983
+
1984
+ @supports ((-moz-appearance: none)) {
1985
+ [data-file-tree-virtualized-scroll="true"], [data-file-tree-scrollbar-measure="true"] {
1986
+ scrollbar-width: thin;
1987
+ scrollbar-color: var(--trees-scrollbar-thumb-current) transparent;
1988
+ }
1989
+ }
1990
+
1991
+ [data-file-tree-virtualized-scroll="true"] {
1992
+ min-height: 0;
1993
+ padding-inline: max(calc(var(--trees-padding-inline) - var(--trees-item-margin-x)),
1994
+ 0px)
1995
+ /* NOTE(amadeus): We can assume that all Webkit based browser gutters
1996
+ * will align to the value of '--trees-scrollbar-gutter', however if not, then
1997
+ * \`--trees-scrollbar-gutter-measured\` should correct it. Mostly we are
1998
+ * hoping to avoid SSR alignment jumps if possible. In non-SSR'd environments
1999
+ * \`--trees-scrollbar-gutter-measured\` should always be immediately available.
2000
+ */
2001
+ max(calc(var(--trees-padding-inline) - var(--trees-item-margin-x) -
2002
+ var(--trees-scrollbar-gutter-measured, var(--trees-scrollbar-gutter))),
2003
+ 0px);
2004
+ flex: 1 1 0;
2005
+ position: relative;
2006
+ overflow-y: auto;
2007
+ }
2008
+
2009
+ @supports ((-moz-appearance: none)) {
2010
+ [data-file-tree-virtualized-scroll="true"] {
2011
+ padding-inline: max(calc(var(--trees-padding-inline) - var(--trees-item-margin-x)),
2012
+ 0px)
2013
+ /* NOTE(amadeus): However on Firefox it can vary a little bit, but most
2014
+ * likely the majority of cases will default to a 0px width scrollbar lets
2015
+ * inherit that first to avoid SSR jumps. In non-SSR'd environments
2016
+ * \`--trees-scrollbar-gutter-measured\` should always be immediately available.
2017
+ */
2018
+ max(calc(var(--trees-padding-inline) - var(--trees-item-margin-x) -
2019
+ var(--trees-scrollbar-gutter-measured, 0px)),
2020
+ 0px);
2021
+ }
2022
+ }
2023
+
2024
+ [data-file-tree-sticky-overlay="true"] {
2025
+ z-index: 4;
2026
+ pointer-events: none;
2027
+ height: 0;
2028
+ position: sticky;
2029
+ top: 0;
2030
+ overflow: visible;
2031
+ }
2032
+
2033
+ [data-file-tree-virtualized-root="true"][data-scroll-at-top="true"]:not([data-overlay-reveal]) [data-file-tree-sticky-overlay="true"] {
2034
+ visibility: hidden;
2035
+ }
2036
+
2037
+ [data-file-tree-sticky-overlay-content="true"] {
2038
+ background-color: var(--trees-bg);
2039
+ pointer-events: none;
2040
+ position: relative;
2041
+ }
2042
+
2043
+ [data-file-tree-virtualized-list="true"] {
2044
+ background-color: var(--trees-bg);
2045
+ overflow-anchor: none;
2046
+ width: 100%;
2047
+ min-height: 100%;
2048
+ position: relative;
2049
+
2050
+ &[data-is-scrolling] {
2051
+ pointer-events: none;
2052
+ }
2053
+ }
2054
+
2055
+ [data-file-tree-virtualized-sticky-offset="true"] {
2056
+ contain: layout size;
2057
+ }
2058
+
2059
+ [data-file-tree-virtualized-sticky="true"] {
2060
+ isolation: isolate;
2061
+ will-change: transform;
2062
+ flex-direction: column;
2063
+ width: 100%;
2064
+ display: flex;
2065
+ position: sticky;
2066
+ top: 0;
2067
+ }
2068
+
2069
+ [data-file-tree-search-container] {
2070
+ padding: 0;
2071
+ padding-inline: var(--trees-padding-inline);
2072
+ margin-bottom: var(--trees-item-row-gap);
2073
+ display: flex;
2074
+ }
2075
+
2076
+ [data-file-tree-search-input] {
2077
+ --trees-focus-ring-width: 2px;
2078
+ font-family: var(--trees-font-family);
2079
+ font-size: var(--trees-font-size);
2080
+ height: var(--trees-row-height);
2081
+ padding-inline: var(--trees-item-padding-x);
2082
+ line-height: var(--trees-row-height);
2083
+ color: var(--trees-search-fg);
2084
+ background-color: var(--trees-search-bg);
2085
+ border: 1px solid var(--trees-border-color);
2086
+ border-radius: var(--trees-border-radius);
2087
+ outline: none;
2088
+ flex: 1;
2089
+ margin-block: 1px;
2090
+
2091
+ &::placeholder {
2092
+ color: color-mix(in lab,
2093
+ var(--trees-search-fg) 65%,
2094
+ var(--trees-search-bg));
2095
+ }
2096
+
2097
+ &:focus-visible, &[data-file-tree-search-input-fake-focus="true"] {
2098
+ outline: var(--trees-focus-ring-width) solid var(--trees-focus-ring-color);
2099
+ outline-offset: var(--trees-focus-ring-offset);
2100
+ }
2101
+ }
2102
+
2103
+ [role="tree"] {
2104
+ gap: var(--trees-gap-override, 0);
2105
+ flex-direction: column;
2106
+ display: flex;
2107
+ position: relative;
2108
+ }
2109
+
2110
+ [data-type="item"] {
2111
+ color: inherit;
2112
+ font-family: var(--trees-font-family);
2113
+ font-size: var(--trees-font-size);
2114
+ text-align: start;
2115
+ background-color: var(--trees-bg);
2116
+ padding: 0 var(--trees-item-padding-x);
2117
+ margin: 0 var(--trees-item-margin-x);
2118
+ cursor: pointer;
2119
+ user-select: none;
2120
+ -webkit-touch-callout: none;
2121
+ touch-action: manipulation;
2122
+ flex: 0 0 var(--trees-row-height);
2123
+ height: var(--trees-row-height);
2124
+ line-height: var(--trees-row-height);
2125
+ align-items: center;
2126
+ gap: var(--trees-item-row-gap);
2127
+ border-radius: var(--trees-border-radius);
2128
+ --truncate-marker-background-color: var(--trees-bg);
2129
+ --truncate-marker-background-overlay-color: transparent;
2130
+ --truncate-marker-block-inset: 0px;
2131
+ border: none;
2132
+ outline: none;
2133
+ display: flex;
2134
+ position: relative;
2135
+
2136
+ &:hover, &[data-item-context-hover="true"] {
2137
+ background-color: var(--trees-bg-muted);
2138
+ --truncate-marker-background-overlay-color: var(--trees-bg-muted);
2139
+ }
2140
+
2141
+ &[data-item-focused="true"], &:focus-visible {
2142
+ z-index: 2;
2143
+
2144
+ & [data-item-flattened-subitems] {
2145
+ --truncate-marker-block-inset: var(--trees-focus-ring-width);
2146
+ }
2147
+
2148
+ &:before {
2149
+ content: "";
2150
+ border-radius: var(--trees-border-radius);
2151
+ outline: var(--trees-focus-ring-width) solid
2152
+ var(--trees-focus-ring-color);
2153
+ outline-offset: var(--trees-focus-ring-offset);
2154
+ pointer-events: none;
2155
+ display: block;
2156
+ position: absolute;
2157
+ inset: 0;
2158
+ }
2159
+
2160
+ &[data-item-selected="true"]:before {
2161
+ outline-color: var(--trees-selected-focused-border-color);
2162
+ }
2163
+ }
2164
+
2165
+ &[data-item-selected="true"] {
2166
+ color: var(--trees-selected-fg);
2167
+ background-color: var(--trees-selected-bg);
2168
+ --truncate-marker-background-overlay-color: var(--trees-selected-bg);
2169
+ z-index: 3;
2170
+
2171
+ & [data-item-section="icon"] {
2172
+ color: var(--trees-selected-fg);
2173
+ }
2174
+ }
2175
+
2176
+ &[data-item-search-match="true"] {
2177
+ font-weight: var(--trees-search-font-weight);
2178
+ }
2179
+ }
2180
+
2181
+ [data-type="item"][data-file-tree-sticky-row="true"] {
2182
+ pointer-events: auto;
2183
+ }
2184
+
2185
+ [data-file-tree-virtualized-root="true"][data-is-scrolling] [data-type="item"][data-file-tree-sticky-row="true"] {
2186
+ pointer-events: none;
2187
+ }
2188
+
2189
+ [data-file-tree-virtualized-root="true"][data-is-scrolling] [data-type="item"][data-file-tree-sticky-row="true"]:hover:not([data-item-selected="true"]), [data-file-tree-virtualized-root="true"][data-is-scrolling] [data-type="item"][data-file-tree-sticky-row="true"][data-item-context-hover="true"]:not([data-item-selected="true"]) {
2190
+ background-color: var(--trees-bg);
2191
+ --truncate-marker-background-overlay-color: transparent;
2192
+ }
2193
+
2194
+ [data-item-selected="true"]:has( + [data-item-selected="true"]) {
2195
+ border-bottom-right-radius: 0;
2196
+ border-bottom-left-radius: 0;
2197
+ }
2198
+
2199
+ [data-item-selected="true"] + [data-item-selected="true"] {
2200
+ border-top-left-radius: 0;
2201
+ border-top-right-radius: 0;
2202
+ }
2203
+
2204
+ [data-item-flattened-subitems] {
2205
+ align-items: center;
2206
+ gap: 2px;
2207
+ display: inline-flex;
2208
+ }
2209
+
2210
+ [data-item-flattened-subitem]:hover, [data-item-flattened-subitem-drag-target="true"] {
2211
+ text-decoration: underline;
2212
+ }
2213
+
2214
+ [data-item-section="icon"] {
2215
+ color: var(--trees-fg-muted);
2216
+ fill: currentColor;
2217
+ width: var(--trees-icon-width);
2218
+ flex-shrink: 0;
2219
+ justify-content: center;
2220
+ align-items: center;
2221
+ display: flex;
2222
+ }
2223
+
2224
+ :where([data-item-section="icon"] > [data-icon-token]) {
2225
+ color: var(--trees-fg-muted);
2226
+ }
2227
+
2228
+ [data-file-tree-colored-icons="true"] {
2229
+ & [data-icon-token="astro"] {
2230
+ color: var(--trees-file-icon-color-astro);
2231
+ }
2232
+
2233
+ & [data-icon-token="babel"] {
2234
+ color: var(--trees-file-icon-color-babel);
2235
+ }
2236
+
2237
+ & [data-icon-token="bash"] {
2238
+ color: var(--trees-file-icon-color-bash);
2239
+ }
2240
+
2241
+ & [data-icon-token="biome"] {
2242
+ color: var(--trees-file-icon-color-biome);
2243
+ }
2244
+
2245
+ & [data-icon-token="bootstrap"] {
2246
+ color: var(--trees-file-icon-color-bootstrap);
2247
+ }
2248
+
2249
+ & [data-icon-token="browserslist"] {
2250
+ color: var(--trees-file-icon-color-browserslist);
2251
+ }
2252
+
2253
+ & [data-icon-token="bun"] {
2254
+ color: var(--trees-file-icon-color-bun);
2255
+ }
2256
+
2257
+ & [data-icon-token="c"] {
2258
+ color: var(--trees-file-icon-color-c);
2259
+ }
2260
+
2261
+ & [data-icon-token="cpp"] {
2262
+ color: var(--trees-file-icon-color-cpp);
2263
+ }
2264
+
2265
+ & [data-icon-token="claude"] {
2266
+ color: var(--trees-file-icon-color-claude);
2267
+ }
2268
+
2269
+ & [data-icon-token="css"] {
2270
+ color: var(--trees-file-icon-color-css);
2271
+ }
2272
+
2273
+ & [data-icon-token="database"] {
2274
+ color: var(--trees-file-icon-color-database);
2275
+ }
2276
+
2277
+ & [data-icon-token="default"] {
2278
+ color: var(--trees-file-icon-color-default);
2279
+ }
2280
+
2281
+ & [data-icon-token="docker"] {
2282
+ color: var(--trees-file-icon-color-docker);
2283
+ }
2284
+
2285
+ & [data-icon-token="eslint"] {
2286
+ color: var(--trees-file-icon-color-eslint);
2287
+ }
2288
+
2289
+ & [data-icon-token="git"] {
2290
+ color: var(--trees-file-icon-color-git);
2291
+ }
2292
+
2293
+ & [data-icon-token="go"] {
2294
+ color: var(--trees-file-icon-color-go);
2295
+ }
2296
+
2297
+ & [data-icon-token="graphql"] {
2298
+ color: var(--trees-file-icon-color-graphql);
2299
+ }
2300
+
2301
+ & [data-icon-token="html"] {
2302
+ color: var(--trees-file-icon-color-html);
2303
+ }
2304
+
2305
+ & [data-icon-token="image"] {
2306
+ color: var(--trees-file-icon-color-image);
2307
+ }
2308
+
2309
+ & [data-icon-token="javascript"] {
2310
+ color: var(--trees-file-icon-color-javascript);
2311
+ }
2312
+
2313
+ & [data-icon-token="json"] {
2314
+ color: var(--trees-file-icon-color-json);
2315
+ }
2316
+
2317
+ & [data-icon-token="markdown"] {
2318
+ color: var(--trees-file-icon-color-markdown);
2319
+ }
2320
+
2321
+ & [data-icon-token="mcp"] {
2322
+ color: var(--trees-file-icon-color-mcp);
2323
+ }
2324
+
2325
+ & [data-icon-token="npm"] {
2326
+ color: var(--trees-file-icon-color-npm);
2327
+ }
2328
+
2329
+ & [data-icon-token="oxc"] {
2330
+ color: var(--trees-file-icon-color-oxc);
2331
+ }
2332
+
2333
+ & [data-icon-token="postcss"] {
2334
+ color: var(--trees-file-icon-color-postcss);
2335
+ }
2336
+
2337
+ & [data-icon-token="prettier"] {
2338
+ color: var(--trees-file-icon-color-prettier);
2339
+ }
2340
+
2341
+ & [data-icon-token="python"] {
2342
+ color: var(--trees-file-icon-color-python);
2343
+ }
2344
+
2345
+ & [data-icon-token="react"] {
2346
+ color: var(--trees-file-icon-color-react);
2347
+ }
2348
+
2349
+ & [data-icon-token="ruby"] {
2350
+ color: var(--trees-file-icon-color-ruby);
2351
+ }
2352
+
2353
+ & [data-icon-token="rust"] {
2354
+ color: var(--trees-file-icon-color-rust);
2355
+ }
2356
+
2357
+ & [data-icon-token="sass"] {
2358
+ color: var(--trees-file-icon-color-sass);
2359
+ }
2360
+
2361
+ & [data-icon-token="svg"] {
2362
+ color: var(--trees-file-icon-color-svg);
2363
+ }
2364
+
2365
+ & [data-icon-token="svelte"] {
2366
+ color: var(--trees-file-icon-color-svelte);
2367
+ }
2368
+
2369
+ & [data-icon-token="svgo"] {
2370
+ color: var(--trees-file-icon-color-svgo);
2371
+ }
2372
+
2373
+ & [data-icon-token="swift"] {
2374
+ color: var(--trees-file-icon-color-swift);
2375
+ }
2376
+
2377
+ & [data-icon-token="table"] {
2378
+ color: var(--trees-file-icon-color-table);
2379
+ }
2380
+
2381
+ & [data-icon-token="text"] {
2382
+ color: var(--trees-file-icon-color-text);
2383
+ }
2384
+
2385
+ & [data-icon-token="tailwind"] {
2386
+ color: var(--trees-file-icon-color-tailwind);
2387
+ }
2388
+
2389
+ & [data-icon-token="terraform"] {
2390
+ color: var(--trees-file-icon-color-terraform);
2391
+ }
2392
+
2393
+ & [data-icon-token="typescript"] {
2394
+ color: var(--trees-file-icon-color-typescript);
2395
+ }
2396
+
2397
+ & [data-icon-token="vite"] {
2398
+ color: var(--trees-file-icon-color-vite);
2399
+ }
2400
+
2401
+ & [data-icon-token="vscode"] {
2402
+ color: var(--trees-file-icon-color-vscode);
2403
+ }
2404
+
2405
+ & [data-icon-token="vue"] {
2406
+ color: var(--trees-file-icon-color-vue);
2407
+ }
2408
+
2409
+ & [data-icon-token="wasm"] {
2410
+ color: var(--trees-file-icon-color-wasm);
2411
+ }
2412
+
2413
+ & [data-icon-token="webpack"] {
2414
+ color: var(--trees-file-icon-color-webpack);
2415
+ }
2416
+
2417
+ & [data-icon-token="yml"] {
2418
+ color: var(--trees-file-icon-color-yml);
2419
+ }
2420
+
2421
+ & [data-icon-token="zig"] {
2422
+ color: var(--trees-file-icon-color-zig);
2423
+ }
2424
+
2425
+ & [data-icon-token="zip"] {
2426
+ color: var(--trees-file-icon-color-zip);
2427
+ }
2428
+ }
2429
+
2430
+ [data-icon-name="file-tree-icon-chevron"] {
2431
+ &[data-align-capitals="false"] {
2432
+ transform: translate(0, var(--trees-icon-nudge));
2433
+ }
2434
+
2435
+ &[data-align-capitals="true"] {
2436
+ transform: translate(0);
2437
+ }
2438
+ }
2439
+
2440
+ [data-item-section="content"] {
2441
+ text-align: start;
2442
+ text-overflow: ellipsis;
2443
+ flex: 0 auto;
2444
+ min-width: 0;
2445
+ max-width: 100%;
2446
+ overflow: hidden;
2447
+ }
2448
+
2449
+ [data-item-section="decoration"] {
2450
+ text-align: end;
2451
+ min-width: 0;
2452
+ color: var(--trees-fg-muted);
2453
+ flex: 1 1 0;
2454
+ justify-content: flex-end;
2455
+ display: flex;
2456
+ overflow: hidden;
2457
+ }
2458
+
2459
+ [data-item-section="decoration"] > span {
2460
+ text-overflow: ellipsis;
2461
+ white-space: nowrap;
2462
+ justify-content: flex-end;
2463
+ align-items: center;
2464
+ min-width: 0;
2465
+ max-width: 100%;
2466
+ display: inline-flex;
2467
+ overflow: hidden;
2468
+ }
2469
+
2470
+ [data-item-section="git"], [data-item-section="action"] {
2471
+ flex: none;
2472
+ justify-content: center;
2473
+ align-items: center;
2474
+ display: flex;
2475
+ }
2476
+
2477
+ [data-item-section="git"] {
2478
+ width: var(--trees-git-lane-width);
2479
+ }
2480
+
2481
+ [data-item-section="action"] {
2482
+ width: var(--trees-action-lane-width);
2483
+ color: var(--trees-fg-muted);
2484
+ fill: currentColor;
2485
+ pointer-events: none;
2486
+ }
2487
+
2488
+ [data-item-section="git"] > span, [data-item-section="action"] > span {
2489
+ justify-content: center;
2490
+ align-items: center;
2491
+ width: 100%;
2492
+ display: inline-flex;
2493
+ }
2494
+
2495
+ [data-item-action-affordance="decorative"] {
2496
+ opacity: .85;
2497
+ }
2498
+
2499
+ [data-item-rename-input] {
2500
+ appearance: none;
2501
+ width: 100%;
2502
+ min-width: 0;
2503
+ height: calc(var(--trees-row-height) - 4px);
2504
+ font-family: inherit;
2505
+ font-size: inherit;
2506
+ color: inherit;
2507
+ box-sizing: border-box;
2508
+ background-color: #0000;
2509
+ border: 0;
2510
+ outline: none;
2511
+ padding-inline: 6px;
2512
+ }
2513
+
2514
+ [data-item-section="content"]:has([data-item-rename-input]) ~ [data-item-section="action"], [data-item-section="content"]:has([data-item-rename-input]) ~ [data-item-section="decoration"] {
2515
+ display: none;
2516
+ }
2517
+
2518
+ [aria-expanded="false"][data-item-type="folder"] > [data-item-section="icon"] > [data-icon-name="file-tree-icon-chevron"] {
2519
+ &[data-align-capitals="true"] {
2520
+ transform: rotate(-90deg)
2521
+ translate(calc(var(--trees-icon-nudge) / 2),
2522
+ calc(var(--trees-icon-nudge) / 2));
2523
+ }
2524
+
2525
+ &[data-align-capitals="false"] {
2526
+ transform: rotate(-90deg)
2527
+ translate(calc(var(--trees-icon-nudge) / 2 * -1),
2528
+ calc(var(--trees-icon-nudge) / 2));
2529
+ }
2530
+ }
2531
+
2532
+ [data-item-section="spacing"] {
2533
+ height: var(--trees-row-height);
2534
+ padding-left: calc(calc(var(--trees-icon-width) / 2) - .5px);
2535
+ flex-direction: row;
2536
+ justify-content: center;
2537
+ align-items: center;
2538
+ display: flex;
2539
+
2540
+ &:empty {
2541
+ padding-left: 0;
2542
+ }
2543
+ }
2544
+
2545
+ [data-item-section="spacing-item"] {
2546
+ border-left: 1px solid var(--trees-indent-guide-bg);
2547
+ height: 100%;
2548
+ margin-right: calc(var(--trees-level-gap) - 1px);
2549
+ opacity: 0;
2550
+ transition: opacity .15s;
2551
+ display: inline-block;
2552
+ transform: translateX(-.25px);
2553
+
2554
+ & + & {
2555
+ margin-left: calc(var(--trees-item-row-gap) + calc(var(--trees-icon-width) / 2) - .5px);
2556
+ }
2557
+ }
2558
+
2559
+ :host(:hover) [data-item-section="spacing-item"] {
2560
+ opacity: .75;
2561
+ }
2562
+
2563
+ [data-item-contains-git-change="true"] > [data-item-section="git"] {
2564
+ color: var(--trees-git-modified-color);
2565
+ opacity: .5;
2566
+ fill: currentColor;
2567
+ }
2568
+
2569
+ [data-item-git-status] {
2570
+ & > :where([data-item-section="icon"]) > :where(:not([data-icon-name="file-tree-icon-chevron"])), & > [data-item-section="content"] {
2571
+ color: var(--trees-item-git-status-color);
2572
+ }
2573
+
2574
+ & > [data-item-section="git"] {
2575
+ color: var(--trees-item-git-status-color);
2576
+ font-weight: var(--trees-font-weight-semibold);
2577
+ }
2578
+ }
2579
+
2580
+ [data-item-git-status="added"] {
2581
+ --trees-item-git-status-color: var(--trees-git-added-color);
2582
+ }
2583
+
2584
+ [data-item-git-status="deleted"] {
2585
+ --trees-item-git-status-color: var(--trees-git-deleted-color);
2586
+ }
2587
+
2588
+ [data-item-git-status="ignored"] {
2589
+ --trees-item-git-status-color: var(--trees-git-ignored-color);
2590
+
2591
+ & > [data-item-section="icon"] {
2592
+ opacity: .5;
2593
+ }
2594
+ }
2595
+
2596
+ [data-item-section="git"] [data-icon-name="file-tree-icon-dot"] {
2597
+ transform: translateY(calc(.65ex - 50%));
2598
+ }
2599
+
2600
+ [data-item-git-status="modified"] {
2601
+ --trees-item-git-status-color: var(--trees-git-modified-color);
2602
+ }
2603
+
2604
+ [data-item-git-status="renamed"] {
2605
+ --trees-item-git-status-color: var(--trees-git-renamed-color);
2606
+ }
2607
+
2608
+ [data-item-git-status="untracked"] {
2609
+ --trees-item-git-status-color: var(--trees-git-untracked-color);
2610
+ }
2611
+
2612
+ [data-item-drag-target="true"] {
2613
+ background-color: var(--trees-selected-bg);
2614
+ }
2615
+
2616
+ [data-item-dragging="true"] {
2617
+ opacity: .5;
2618
+ }
2619
+
2620
+ [data-item-section="lock"] {
2621
+ color: var(--trees-fg-muted);
2622
+ flex: none;
2623
+ align-items: center;
2624
+ margin-left: auto;
2625
+ display: flex;
2626
+ }
2627
+
2628
+ [data-item-section="lock"] svg {
2629
+ display: block;
2630
+ }
2631
+
2632
+ [data-type="header-slot"] {
2633
+ flex: none;
2634
+ display: block;
2635
+ }
2636
+
2637
+ [data-type="context-menu-wash"] {
2638
+ z-index: 3;
2639
+ touch-action: none;
2640
+ background-color: #0000;
2641
+ position: absolute;
2642
+ inset: 0;
2643
+ }
2644
+
2645
+ [data-type="context-menu-anchor"] {
2646
+ top: 0;
2647
+ right: var(--trees-context-menu-trigger-inline-offset);
2648
+ z-index: 4;
2649
+ align-items: center;
2650
+ display: none;
2651
+ position: absolute;
2652
+
2653
+ &[data-visible="true"] {
2654
+ display: flex;
2655
+ }
2656
+ }
2657
+
2658
+ [data-file-tree-virtualized-root="true"][data-is-scrolling] [data-type="context-menu-anchor"] {
2659
+ display: none;
2660
+ }
2661
+
2662
+ [data-type="context-menu-anchor"] > slot[name="context-menu"] {
2663
+ flex: 0 0 0;
2664
+ width: 0;
2665
+ min-width: 0;
2666
+ display: block;
2667
+ overflow: visible;
2668
+ }
2669
+
2670
+ [data-type="context-menu-trigger"] {
2671
+ all: unset;
2672
+ width: var(--trees-action-lane-width);
2673
+ color: var(--trees-fg-muted);
2674
+ fill: currentColor;
2675
+ cursor: pointer;
2676
+ font-family: var(--trees-font-family);
2677
+ font-size: var(--trees-font-size);
2678
+ border-top-right-radius: var(--trees-border-radius);
2679
+ border-bottom-right-radius: var(--trees-border-radius);
2680
+ margin: var(--trees-focus-ring-width);
2681
+ height: calc(var(--trees-row-height) - var(--trees-focus-ring-width) * 2);
2682
+ border-width: 0;
2683
+ justify-content: center;
2684
+ align-items: center;
2685
+ transition: color .12s;
2686
+ display: flex;
2687
+ }
2688
+
2689
+ [data-type="context-menu-trigger"]:hover, [data-type="context-menu-trigger"][aria-expanded="true"] {
2690
+ color: var(--trees-fg);
2691
+ }
2692
+
2693
+ [data-truncate-container] {
2694
+ --truncate-internal-marker-fade-width: var(--truncate-marker-fade-width, 2px);
2695
+ --truncate-internal-marker-gap: var(--truncate-marker-gap, 0px);
2696
+ --truncate-internal-marker-opacity: var(--truncate-marker-opacity, 50%);
2697
+ --truncate-internal-middle-marker-opacity: var(--truncate-middle-marker-opacity, 80%);
2698
+ --truncate-internal-marker-background-color: var(--truncate-marker-background-color, light-dark(#fff, #000));
2699
+ --truncate-internal-marker-background-overlay-color: var(--truncate-marker-background-overlay-color, transparent);
2700
+ --truncate-internal-marker-block-inset: var(--truncate-marker-block-inset, 0px);
2701
+ --truncate-internal-marker-fade-out-duration: var(--truncate-marker-fade-out-duration, 0s);
2702
+ --truncate-internal-marker-fade-in-duration: var(--truncate-marker-fade-in-duration, .1s);
2703
+ --truncate-internal-fade-marker-color: var(--truncate-fade-marker-color, #000);
2704
+ --truncate-internal-fade-marker-width: var(--truncate-fade-marker-width, .2lh);
2705
+ --truncate-internal-single-line-height: 1lh;
2706
+ height: var(--truncate-internal-single-line-height);
2707
+ min-width: 0;
2708
+ margin-top: -1px;
2709
+ margin-bottom: -1px;
2710
+ overflow: hidden;
2711
+ }
2712
+
2713
+ [data-truncate-marker] {
2714
+ height: var(--truncate-internal-single-line-height);
2715
+ padding-block: var(--truncate-internal-marker-block-inset);
2716
+ box-sizing: border-box;
2717
+ z-index: 2;
2718
+ color: color-mix(in srgb,
2719
+ currentColor var(--truncate-internal-marker-opacity),
2720
+ transparent);
2721
+ opacity: 0;
2722
+ transition: opacity var(--truncate-internal-marker-fade-out-duration)
2723
+ ease-in-out;
2724
+ background-clip: content-box;
2725
+ align-items: center;
2726
+ display: flex;
2727
+ position: absolute;
2728
+ }
2729
+
2730
+ @container measure (height > 1lh) {
2731
+ [data-truncate-marker] {
2732
+ opacity: 1;
2733
+ transition: opacity var(--truncate-internal-marker-fade-in-duration)
2734
+ ease-in-out;
2735
+ }
2736
+ }
2737
+
2738
+ [data-truncate-grid] {
2739
+ display: grid;
2740
+ position: relative;
2741
+ }
2742
+
2743
+ [data-truncate-content="visible"] {
2744
+ white-space: nowrap;
2745
+ }
2746
+
2747
+ [data-truncate-content="overflow"] {
2748
+ opacity: 0;
2749
+ pointer-events: none;
2750
+ user-select: none;
2751
+ word-break: break-all;
2752
+ margin-top: calc(-1 * var(--truncate-internal-single-line-height));
2753
+ }
2754
+
2755
+ [data-truncate-marker-cell] {
2756
+ user-select: none;
2757
+ pointer-events: none;
2758
+ overflow: visible;
2759
+ container: measure / size;
2760
+ }
2761
+
2762
+ [data-truncate-container="truncate"] {
2763
+ & [data-truncate-grid] {
2764
+ grid-template-columns: minmax(0, max-content) 0;
2765
+ }
2766
+
2767
+ & [data-truncate-marker] {
2768
+ right: 0;
2769
+ }
2770
+
2771
+ & [data-truncate-fade] {
2772
+ margin-right: calc(-2 * var(--truncate-internal-fade-marker-width));
2773
+ }
2774
+ }
2775
+
2776
+ [data-truncate-container="fruncate"] {
2777
+ & [data-truncate-grid] {
2778
+ grid-template-columns: 0 minmax(0, max-content) auto;
2779
+ }
2780
+
2781
+ & [data-truncate-content] {
2782
+ direction: rtl;
2783
+ }
2784
+
2785
+ & [data-truncate-content] > span {
2786
+ unicode-bidi: plaintext;
2787
+ }
2788
+
2789
+ & [data-truncate-fade] {
2790
+ margin-left: calc(-2 * var(--truncate-internal-fade-marker-width));
2791
+ }
2792
+ }
2793
+
2794
+ [data-truncate-variant="default"] {
2795
+ & [data-truncate-marker] {
2796
+ background-color: var(--truncate-internal-marker-background-color);
2797
+ background-image: linear-gradient(var(--truncate-internal-marker-background-overlay-color),
2798
+ var(--truncate-internal-marker-background-overlay-color));
2799
+ }
2800
+
2801
+ & [data-truncate-marker]:after, & [data-truncate-marker]:before {
2802
+ content: "";
2803
+ width: calc(var(--truncate-internal-marker-fade-width) +
2804
+ var(--truncate-internal-marker-gap));
2805
+ height: max(0px,
2806
+ calc(var(--truncate-internal-single-line-height) -
2807
+ var(--truncate-internal-marker-block-inset) * 2));
2808
+ background-color: var(--truncate-internal-marker-background-color);
2809
+ background-image: linear-gradient(var(--truncate-internal-marker-background-overlay-color),
2810
+ var(--truncate-internal-marker-background-overlay-color));
2811
+ -webkit-mask-image: linear-gradient(var(--truncate-internal-fade-dir),
2812
+ #000 0%,
2813
+ #000 var(--truncate-internal-marker-gap),
2814
+ transparent 100%);
2815
+ mask-image: linear-gradient(var(--truncate-internal-fade-dir),
2816
+ #000 0%,
2817
+ #000 var(--truncate-internal-marker-gap),
2818
+ transparent 100%);
2819
+ position: absolute;
2820
+ inset-block-start: var(--truncate-internal-marker-block-inset);
2821
+ }
2822
+
2823
+ & [data-truncate-marker]:after {
2824
+ --truncate-internal-fade-dir: to right;
2825
+ right: calc(-1 *
2826
+ (
2827
+ var(--truncate-internal-marker-fade-width) +
2828
+ var(--truncate-internal-marker-gap)
2829
+ ));
2830
+ }
2831
+
2832
+ & [data-truncate-marker]:before {
2833
+ --truncate-internal-fade-dir: to left;
2834
+ left: calc(-1 *
2835
+ (
2836
+ var(--truncate-internal-marker-fade-width) +
2837
+ var(--truncate-internal-marker-gap)
2838
+ ));
2839
+ }
2840
+ }
2841
+
2842
+ [data-truncate-variant="fade"] {
2843
+ & [data-truncate-marker] {
2844
+ background: none;
2845
+ }
2846
+ }
2847
+
2848
+ [data-truncate-fade] {
2849
+ box-shadow: 0 0 calc(var(--truncate-internal-fade-marker-width) / 2)
2850
+ var(--truncate-internal-fade-marker-color),
2851
+ 0 0 var(--truncate-internal-fade-marker-width)
2852
+ var(--truncate-internal-fade-marker-color);
2853
+ width: calc(var(--truncate-internal-fade-marker-width) * 2);
2854
+ height: calc(var(--truncate-internal-single-line-height) -
2855
+ (var(--truncate-internal-fade-marker-width) * 2));
2856
+ margin: var(--truncate-internal-fade-marker-width) 0;
2857
+ }
2858
+
2859
+ [data-truncate-group-container="middle"] {
2860
+ & [data-truncate-container] {
2861
+ --truncate-marker-opacity: var(--truncate-internal-middle-marker-opacity);
2862
+ }
2863
+
2864
+ min-width: 0;
2865
+ display: flex;
2866
+
2867
+ & > div {
2868
+ min-width: 0;
2869
+ }
2870
+
2871
+ & > div[data-truncate-segment-priority="1"] {
2872
+ flex: 0 1 max-content;
2873
+ }
2874
+
2875
+ & > div[data-truncate-segment-priority="2"] {
2876
+ flex: 0 999999 max-content;
2877
+ }
2878
+ }
2879
+ }
2880
+
2881
+ @layer theme, unsafe;
2882
+ `,Jw=`@layer base, unsafe;`;function Yw(e){return`${Jw}
2883
+ @layer base {
2884
+ ${e}
2885
+ }`}function Xw(e){return`${Jw}
2886
+ @layer unsafe {
2887
+ ${e}
2888
+ }`}var Zw=new WeakMap;function Qw(e){let t=Zw.get(e);if(t!=null)return t;let n=document.createElement(`div`);n.setAttribute(Iw,`true`);let r=document.createElement(`div`);r.style.position=`relative`,r.style.height=`200%`,n.appendChild(r),e.appendChild(n);let i=Math.max(n.offsetWidth-n.clientWidth,0);return n.remove(),Zw.set(e,i),i}function $w(e,t){if(!e.isConnected)return;let n=Qw(t);if(n==null)return;let r=t.querySelector(`style[${Lw}]`),i=r instanceof HTMLStyleElement?r:document.createElement(`style`);r instanceof HTMLStyleElement||(i.setAttribute(Lw,``),t.appendChild(i)),i.textContent=`:host { ${Rw}: ${n}px; }`}var eT;function tT(e){if(typeof CSSStyleSheet<`u`&&typeof CSSStyleSheet.prototype.replaceSync==`function`&&`adoptedStyleSheets`in e){eT??(eT=new CSSStyleSheet,eT.replaceSync(Yw(qw)));let t=!1;try{e.adoptedStyleSheets=[eT],t=!0}catch{}if(t){e.querySelector(`style[${Pw}]`)?.remove();return}}if(e.querySelector(`style[data-file-tree-style]`)==null){let t=document.createElement(`style`);t.setAttribute(Pw,``),t.textContent=Yw(qw),e.prepend(t)}}function nT(e,t){rT(e,t),tT(t),$w(e,t)}function rT(e,t){let n=e.querySelector(`template[shadowrootmode="open"], template[data-file-tree-shadowrootmode="open"]`);n instanceof HTMLTemplateElement&&(t.childNodes.length>0||(t.appendChild(n.content.cloneNode(!0)),n.hasAttribute(`shadowrootmode`)&&n.remove()))}if(typeof HTMLElement<`u`&&customElements.get(`file-tree-container`)==null){class e extends HTMLElement{constructor(){super()}connectedCallback(){let e=this.shadowRoot??this.attachShadow({mode:`open`});nT(this,e)}}if(customElements.define(Nw,e),typeof document<`u`)for(let e of Array.from(document.querySelectorAll(Nw)))e instanceof HTMLElement&&nT(e,e.shadowRoot??e.attachShadow({mode:`open`}))}var iT=5,aT=1<<iT,oT=aT*4;function sT(){return{childIdByNameId:new Map,childIds:[],childPositionById:new Map,childVisibleChunkSums:null,totalChildSubtreeNodeCount:0,totalChildVisibleSubtreeCount:0}}function cT(){return{childIdByNameId:null,childIds:[],childPositionById:null,childVisibleChunkSums:null,totalChildSubtreeNodeCount:0,totalChildVisibleSubtreeCount:0}}function lT(e,t){if(t.childIdByNameId!=null)return t.childIdByNameId;let n=new Map;for(let r of t.childIds){let t=e[r];t!=null&&n.set(t.nameId,r)}return t.childIdByNameId=n,n}function uT(e){if(e.childPositionById!=null)return e.childPositionById;let t=new Map;for(let n=0;n<e.childIds.length;n++){let r=e.childIds[n];r!=null&&t.set(r,n)}return e.childPositionById=t,t}function dT(e,t){e.childPositionById!=null&&e.childPositionById.set(t,e.childIds.length),e.childIds.push(t)}function fT(e,t){if(e.childPositionById!=null)for(let n=t;n<e.childIds.length;n++){let t=e.childIds[n];t!=null&&e.childPositionById.set(t,n)}}function pT(e,t){let n=0,r=0;for(let i of t.childIds){let t=e[i];t!=null&&(n+=t.subtreeNodeCount,r+=t.visibleSubtreeCount)}t.totalChildSubtreeNodeCount=n,t.totalChildVisibleSubtreeCount=r,_T(e,t)}function mT(e,t,n,r){if(e.totalChildSubtreeNodeCount+=n,e.totalChildVisibleSubtreeCount+=r,e.childVisibleChunkSums==null||r===0)return;let i=uT(e).get(t);if(i===void 0)return;let a=i>>iT;e.childVisibleChunkSums[a]+=r}function hT(e,t,n){let r=t.childVisibleChunkSums;if(r!=null){let i=n,a=0;for(let o of r){if(i<o){let r=vT(e,t,a,i);return{...r,childVisibleIndex:n-r.localVisibleIndex}}i-=o,a+=aT}throw Error(`Visible child index ${String(n)} is out of range`)}let i=n;for(let r=0;r<t.childIds.length;r++){let a=t.childIds[r];if(a==null)continue;let o=e[a];if(o!=null){if(i<o.visibleSubtreeCount)return{childIndex:r,childVisibleIndex:n-i,localVisibleIndex:i};i-=o.visibleSubtreeCount}}throw Error(`Visible child index ${String(n)} is out of range`)}function gT(e,t,n){let r=0,i=t.childVisibleChunkSums,a=0;if(i!=null){let e=n>>iT;for(let t=0;t<e;t+=1)r+=i[t]??0;a=e<<iT}for(let i=a;i<n;i+=1){let n=t.childIds[i];if(n==null)continue;let a=e[n];a!=null&&(r+=a.visibleSubtreeCount)}return r}function _T(e,t){if(t.childIds.length<oT){t.childVisibleChunkSums=null;return}let n=Math.ceil(t.childIds.length/aT),r=new Int32Array(n);for(let n=0;n<t.childIds.length;n++){let i=t.childIds[n];if(i==null)continue;let a=e[i];a!=null&&(r[n>>iT]+=a.visibleSubtreeCount)}t.childVisibleChunkSums=r}function vT(e,t,n,r){let i=Math.min(t.childIds.length,n+aT),a=r;for(let r=n;r<i;r++){let n=t.childIds[r];if(n==null)continue;let i=e[n];if(i!=null){if(a<i.visibleSubtreeCount)return{childIndex:r,localVisibleIndex:a};a-=i.visibleSubtreeCount}}throw Error(`Visible child index ${String(r)} is out of range`)}var yT=7,bT=3,xT=1<<bT,ST=4;function CT(e,t,n=0){return e<<ST|n<<bT|t}function wT(e){return e.depthAndFlags>>>ST}function TT(e){return(e.depthAndFlags&xT)>>bT}function X(e){return(e.depthAndFlags&xT)!==0}function ET(e){return e.depthAndFlags&yT}function DT(e,t){return(ET(e)&t)!==0}function OT(e,t){e.depthAndFlags|=t}function kT(e,t){e.depthAndFlags=CT(t,ET(e),TT(e))}var AT=Symbol(`benchmarkInstrumentation`);function jT(e,t){return t==null||Object.defineProperty(e,AT,{configurable:!0,enumerable:!1,value:t,writable:!1}),e}function MT(e){return e==null?null:e[AT]??null}function Z(e,t,n){return e==null?n():e.measurePhase(t,n)}function NT(e,t,n){!Number.isFinite(n)||e==null||e.setCounter(t,n)}function PT(e){return e>=48&&e<=57}function FT(e){let t=[],n=0,r=0;for(;r<e.length;){for(;r<e.length&&!PT(e.charCodeAt(r));)r+=1;if(r>=e.length)break;r>n&&t.push(e.slice(n,r));let i=0;for(;r<e.length&&PT(e.charCodeAt(r));)i=i*10+(e.charCodeAt(r)-48),r+=1;t.push(i),n=r}return(n<e.length||t.length===0)&&t.push(e.slice(n)),t}function IT(e){let t=e.toLowerCase();return{lowerValue:t,tokens:FT(t)}}function LT(e,t){let n=Math.min(e.length,t.length);for(let r=0;r<n;r++){let n=e[r],i=t[r];if(n===i)continue;if(typeof n==`number`&&typeof i==`number`)return n<i?-1:1;let a=String(n),o=String(i);if(a!==o)return a<o?-1:1}return e.length===t.length?0:e.length<t.length?-1:1}function RT(e,t){if(e.tokens.length===1&&t.tokens.length===1&&typeof e.tokens[0]==`string`&&typeof t.tokens[0]==`string`)return e.lowerValue===t.lowerValue?0:e.lowerValue<t.lowerValue?-1:1;let n=LT(e.tokens,t.tokens);return n===0?e.lowerValue===t.lowerValue?0:e.lowerValue<t.lowerValue?-1:1:n}function zT(e,t,n){let r=RT(n(e),n(t));return r===0?e===t?0:e<t?-1:1:r}function BT(e,t){return zT(e,t,IT)}function VT(e,t){return t===e.segments.length-1?+!!e.isDirectory:1}function HT(e,t){let n=Math.min(e.segments.length,t.segments.length);for(let r=0;r<n;r++){let n=e.segments[r],i=t.segments[r];if(n===i)continue;let a=VT(e,r);return a===VT(t,r)?BT(n,i):a===1?-1:1}return e.segments.length===t.segments.length?e.isDirectory===t.isDirectory?0:e.isDirectory?-1:1:e.segments.length<t.segments.length?-1:1}function UT(e,t){return HT(e,t)}function WT(e,t,n){let r=e=>{let t=n.get(e);if(t!=null)return t;let r=IT(e);return n.set(e,r),r},i=Math.min(e.segments.length,t.segments.length);for(let n=0;n<i;n++){let i=e.segments[n],a=t.segments[n];if(i===a)continue;let o=VT(e,n);return o===VT(t,n)?zT(i,a,r):o===1?-1:1}return e.segments.length===t.segments.length?e.isDirectory===t.isDirectory?0:e.isDirectory?-1:1:e.segments.length<t.segments.length?-1:1}function GT(e,t){let n=e.sortKeyById[t];if(n!==void 0)return n;let r=e.valueById[t],i=IT(r);return e.sortKeyById[t]=i,i}function KT(e={}){return{flattenEmptyDirectories:e.flattenEmptyDirectories!==!1,sort:e.sort??`default`}}function qT(e){let t=e.length>0&&e.charCodeAt(e.length-1)===47,n=t?e.length-1:e.length,r=[],i=0;for(let t=0;t<n;t++)e.charCodeAt(t)===47&&(r.push(e.slice(i,t)),i=t+1);return r.push(e.slice(i,n)),{hasTrailingSlash:t,segments:r}}function JT(e){let{hasTrailingSlash:t,segments:n}=qT(e);return{basename:n[n.length-1]??``,isDirectory:t,path:e,segments:n}}function YT(e){if(e.length===0)return{requiresDirectory:!1,segments:[]};let{hasTrailingSlash:t,segments:n}=qT(e);return{requiresDirectory:t,segments:n}}function XT(){let e=new Map;return e.set(``,0),{idByValue:e,valueById:[``],sortKeyById:[IT(``)]}}function ZT(e,t){let n=e.idByValue.get(t);if(n!==void 0)return n;let r=e.valueById.length;return e.idByValue.set(t,r),e.valueById.push(t),r}function QT(e,t){let n=e.valueById[t];if(n===void 0)throw Error(`Unknown segment ID: ${String(t)}`);return n}var $T=Symbol(`pathStorePreparedInputKind`);function eE(e,t){return e[$T]=t,e}function tE(e){return{basename:e.basename,depth:e.segments.length,isDirectory:e.isDirectory,path:e.path,segments:e.segments}}function nE(e,t,n){return n==="default"?UT(e,t):n(tE(e),tE(t))}function rE(){return{depthAndFlags:CT(0,3,1),nameId:0,parentId:0,subtreeNodeCount:1,visibleSubtreeCount:1}}function iE(e,t){let n=Math.min(e.length,t.length);for(let r=0;r<n;r++)if(e[r]!==t[r])return r;return n}function aE(e){return e.isDirectory?e.segments.length:e.segments.length-1}function oE(e){return Array.isArray(e)&&e.every(e=>typeof e==`object`&&!!e&&typeof e.path==`string`&&Array.isArray(e.segments)&&typeof e.basename==`string`&&typeof e.isDirectory==`boolean`)}function sE(e){return Array.isArray(e)&&e.every(e=>typeof e==`string`)}function cE(e,t={}){return mE(e,t).map(e=>e.path)}function lE(e,t={}){let n=mE(e,t);return eE({paths:n.map(e=>e.path),preparedPaths:n},`prepared`)}function uE(e){let t=e.length,n=!1;for(let r=0;r<t;r+=1){let t=e[r];if(t.length>0&&t.charCodeAt(t.length-1)===47){n=!0;break}}return eE({paths:e,presortedPaths:e,presortedPathsContainDirectories:n},`presorted`)}function dE(e){let t=e,n=t.preparedPaths;if(t[$T]===`prepared`&&n!=null)return n;if(!oE(n))throw Error(`preparedInput must come from PathStore.prepareInput()`);return n}function fE(e){let t=e;return t[$T]===`presorted`&&t.presortedPaths!=null||sE(t.presortedPaths)?t.presortedPaths:null}function pE(e){let t=e;return typeof t.presortedPathsContainDirectories==`boolean`?t.presortedPathsContainDirectories:null}function mE(e,t={}){let n=KT(t),r=MT(t);NT(r,`workload.inputFiles`,e.length);let i=Z(r,`store.preparePathEntries.parse`,()=>e.map(e=>JT(e)));return Z(r,`store.preparePathEntries.sort`,()=>i.sort((e,t)=>nE(e,t,n.sort))),i}var hE=class{directories=new Map;directoryStack=[0];presortedDirectoryNodeIds=[];initialExpandedPathSet;createdDirectoriesAllExpanded=!1;createdDirectoryCount=0;lastPreparedPath=null;nodes=[rE()];options;instrumentation;segmentSortKeyCache=new Map;segmentTable=XT();hasDeferredDirectoryIndexes=!1;constructor(e={}){this.instrumentation=MT(e),this.options=KT(e);let t=e.initialExpandedPaths??null;if(t==null||t.length===0)this.initialExpandedPathSet=null;else{let e=new Set,n=t.length;for(let r=0;r<n;r+=1){let n=t[r],i=n.length;e.add(i>0&&n.charCodeAt(i-1)===47?n.slice(0,i-1):n)}this.initialExpandedPathSet=e,this.createdDirectoriesAllExpanded=!0}this.directories.set(0,sT())}appendPaths(e){return Z(this.instrumentation,`store.builder.appendPaths.parse`,()=>this.appendPreparedPaths(e.map(e=>JT(e))))}appendPreparedPaths(e,t=!0){return this.createdDirectoriesAllExpanded=!1,Z(this.instrumentation,`store.builder.appendPreparedPaths`,()=>{for(let n of e)this.appendPreparedPath(n,t)}),this}appendPresortedPaths(e,t=null){return Z(this.instrumentation,`store.builder.appendPresortedPaths`,()=>{if(t===!1){this.appendPresortedFilePaths(e);return}this.createdDirectoriesAllExpanded=!1;let n=null,r=0,i=this.nodes,a=this.segmentTable,o=a.idByValue,s=a.valueById,c=this.directoryStack,l=0,u=``,d=0;for(let t of e){if(n===t)throw Error(`Duplicate path: "${t}"`);let e=t.length>0&&t.charCodeAt(t.length-1)===47,a=e?t.length-1:t.length,f=0,p=0;if(n!=null)if(u.length>0&&t.length>u.length&&t.startsWith(u))f=d,p=u.length;else{let r=Math.min(a,n.length),i=!0;for(let e=0;e<r;e++){let r=t.charCodeAt(e);if(r!==n.charCodeAt(e)){i=!1;break}r===47&&(f++,p=e+1)}i&&e&&r===a&&n.length>a&&n.charCodeAt(a)===47&&(f++,p=a+1)}l=f,r=f;let m=p,h=t.indexOf(`/`,m);for(;h>=0&&h<a;){let e=c[l];if(e===void 0)throw Error(`Directory stack underflow while building the path store`);r++;let n=t.slice(m,h),a=o.get(n);a===void 0&&(a=s.length,o.set(n,a),s.push(n));let u=i.length;i.push({depthAndFlags:CT(r,0,1),nameId:a,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),this.recordCreatedDirectoryPath(t.slice(0,h)),l++,c[l]=u,m=h+1,h=t.indexOf(`/`,m)}if(e){if(m<a){let e=c[l];if(e===void 0)throw Error(`Unable to resolve directory parent for "${t}"`);r++;let n=t.slice(m,a),u=o.get(n);u===void 0&&(u=s.length,o.set(n,u),s.push(n));let d=i.length;i.push({depthAndFlags:CT(r,0,1),nameId:u,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),l++,c[l]=d}let e=c[l];if(e===void 0)throw Error(`Unable to resolve directory node for "${t}"`);this.promoteDirectoryToExplicit(e,t)}else{let e=c[l];if(e===void 0)throw Error(`Unable to resolve file parent for "${t}"`);let n=t.slice(m),a=o.get(n);a===void 0&&(a=s.length,o.set(n,a),s.push(n)),i.push({depthAndFlags:CT(r+1,0),nameId:a,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1})}m!==u.length&&(u=t.substring(0,m),d=r),n=t}c.length=l+1,n!=null&&(this.lastPreparedPath=JT(n)),this.hasDeferredDirectoryIndexes=!0}),this}appendPresortedFilePaths(e){let t=null,n=0,r=this.nodes,i=this.segmentTable,a=i.idByValue,o=i.valueById,s=this.directoryStack,c=0,l=``,u=0;for(let i of e){if(t===i)throw Error(`Duplicate path: "${i}"`);let e=i.length,d=0,f=0;if(t!=null)if(l.length>0&&i.length>l.length&&i.startsWith(l))d=u,f=l.length;else{let n=Math.min(e,t.length);for(let e=0;e<n;e++){let n=i.charCodeAt(e);if(n!==t.charCodeAt(e))break;n===47&&(d++,f=e+1)}}c=d,n=d;let p=f,m=i.indexOf(`/`,p);for(;m>=0;){let e=s[c];if(e===void 0)throw Error(`Directory stack underflow while building the path store`);n++;let t=i.slice(p,m),l=a.get(t);l===void 0&&(l=o.length,a.set(t,l),o.push(t));let u=r.length;r.push({depthAndFlags:CT(n,0,1),nameId:l,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),this.recordCreatedDirectoryPath(i.slice(0,m)),this.presortedDirectoryNodeIds.push(u),c++,s[c]=u,p=m+1,m=i.indexOf(`/`,p)}let h=s[c];if(h===void 0)throw Error(`Unable to resolve file parent for "${i}"`);let g=i.slice(p),_=a.get(g);_===void 0&&(_=o.length,a.set(g,_),o.push(g)),r.push({depthAndFlags:CT(n+1,0),nameId:_,parentId:h,subtreeNodeCount:1,visibleSubtreeCount:1}),p!==l.length&&(l=i.substring(0,p),u=n),t=i}s.length=c+1,t!=null&&(this.lastPreparedPath=JT(t)),this.hasDeferredDirectoryIndexes=!0}finish(e={}){let t=e.skipSubtreeCountPass===!0;return this.hasDeferredDirectoryIndexes?(Z(this.instrumentation,`store.builder.buildDirectoryIndexes`,()=>this.buildPresortedFinish(t)),this.hasDeferredDirectoryIndexes=!1):t||Z(this.instrumentation,`store.builder.computeSubtreeCounts`,()=>this.computeSubtreeCounts(0)),{directories:this.directories,nodes:this.nodes,options:this.options,rootId:0,segmentTable:this.segmentTable,presortedDirectoryNodeIds:this.presortedDirectoryNodeIds.length>0?this.presortedDirectoryNodeIds:null}}didMatchAllInitialExpandedPaths(){return this.createdDirectoriesAllExpanded&&this.initialExpandedPathSet!=null&&this.createdDirectoryCount===this.initialExpandedPathSet.size}appendPreparedPath(e,t){if(this.hasDeferredDirectoryIndexes&&=(this.buildDirectoryIndexes(),!1),this.lastPreparedPath!=null){if(e.path===this.lastPreparedPath.path)throw Error(`Duplicate path: "${e.path}"`);if(t&&(this.options.sort==="default"?WT(this.lastPreparedPath,e,this.segmentSortKeyCache):nE(this.lastPreparedPath,e,this.options.sort))>0)throw Error(`Builder input must be sorted before appendPaths(): "${e.path}"`)}let n=this.lastPreparedPath,r=aE(e),i=n==null?0:aE(n),a=n==null?0:iE(n.segments,e.segments),o=Math.min(a,r,i);this.directoryStack.length=o+1;for(let n=o;n<r;n++){let r=this.directoryStack[this.directoryStack.length-1];if(r===void 0)throw Error(`Directory stack underflow while building the path store`);let i=t?this.getOrCreateDirectoryChild(r,e.segments[n]):this.createDirectoryChild(r,e.segments[n]);this.directoryStack.push(i)}if(e.isDirectory){let t=this.directoryStack[this.directoryStack.length-1];if(t===void 0)throw Error(`Unable to resolve directory node for "${e.path}"`);this.promoteDirectoryToExplicit(t,e.path),this.lastPreparedPath=e;return}let s=this.directoryStack[this.directoryStack.length-1];if(s===void 0)throw Error(`Unable to resolve file parent for "${e.path}"`);t?this.createFileChild(s,e.basename,e.path):this.createFileChildUnchecked(s,e.basename),this.lastPreparedPath=e}recordCreatedDirectoryPath(e){!this.createdDirectoriesAllExpanded||this.initialExpandedPathSet==null||(this.createdDirectoryCount+=1,this.initialExpandedPathSet.has(e)||(this.createdDirectoriesAllExpanded=!1))}createFileChild(e,t,n){let r=ZT(this.segmentTable,t),i=this.getDirectoryIndex(e),a=i.childIdByNameId;if(a!=null&&a.get(r)!==void 0)throw Error(`Path collides with an existing entry: "${n}"`);let o=this.nodes[e];if(o===void 0)throw Error(`Unknown parent node ID: ${String(e)}`);let s=this.nodes.length;return this.nodes.push({depthAndFlags:CT(wT(o)+1,0),nameId:r,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),a?.set(r,s),dT(i,s),s}createFileChildUnchecked(e,t){let n=ZT(this.segmentTable,t),r=this.getDirectoryIndex(e),i=this.nodes[e];if(i===void 0)throw Error(`Unknown parent node ID: ${String(e)}`);let a=this.nodes.length;return this.nodes.push({depthAndFlags:CT(wT(i)+1,0),nameId:n,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),r.childIdByNameId!=null&&r.childIdByNameId.set(n,a),dT(r,a),a}getOrCreateDirectoryChild(e,t){let n=ZT(this.segmentTable,t),r=this.getDirectoryIndex(e);if(r.childIdByNameId!=null){let e=r.childIdByNameId.get(n);if(e!==void 0){let n=this.nodes[e];if(n!=null&&!X(n))throw Error(`Path collides with an existing file while creating directory "${t}"`);return e}}let i=this.nodes[e];if(i===void 0)throw Error(`Unknown parent node ID: ${String(e)}`);let a=this.nodes.length;return this.nodes.push({depthAndFlags:CT(wT(i)+1,0,1),nameId:n,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),r.childIdByNameId!=null&&r.childIdByNameId.set(n,a),dT(r,a),this.directories.set(a,sT()),a}createDirectoryChild(e,t){let n=ZT(this.segmentTable,t),r=this.getDirectoryIndex(e),i=this.nodes[e];if(i===void 0)throw Error(`Unknown parent node ID: ${String(e)}`);let a=this.nodes.length;return this.nodes.push({depthAndFlags:CT(wT(i)+1,0,1),nameId:n,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),r.childIdByNameId!=null&&r.childIdByNameId.set(n,a),dT(r,a),this.directories.set(a,sT()),a}promoteDirectoryToExplicit(e,t){let n=this.nodes[e];if(n===void 0)throw Error(`Unknown directory node ID: ${String(e)}`);if(!X(n))throw Error(`Path is not a directory: "${t}"`);if(DT(n,1))throw Error(`Duplicate path: "${t}"`);OT(n,1)}getDirectoryIndex(e){let t=this.directories.get(e);if(t!==void 0)return t;throw Error(`Unknown directory child index for node ${String(e)}`)}buildPresortedFinish(e){let t=this.nodes,n=this.directories;n.set(0,cT());let r=-1,i=null;for(let e=1;e<t.length;e++){let a=t[e];if(a==null)continue;if(X(a)){let t=cT();n.set(e,t),r=e,i=t}let o;a.parentId===r?o=i:(o=n.get(a.parentId),r=a.parentId,i=o??null),o?.childIds.push(e)}if(!e)for(let e=t.length-1;e>=1;e--){let n=t[e];if(n==null)continue;let r=t[n.parentId];r!=null&&(r.subtreeNodeCount+=n.subtreeNodeCount,r.visibleSubtreeCount+=n.visibleSubtreeCount)}}buildDirectoryIndexes(){let e=this.nodes;for(let t=1;t<e.length;t++){let n=e[t];if(n==null)continue;X(n)&&this.directories.set(t,sT());let r=this.directories.get(n.parentId);r!=null&&(r.childIdByNameId!=null&&r.childIdByNameId.set(n.nameId,t),dT(r,t))}}computeSubtreeCounts(e){let t=this.nodes[e];if(t===void 0)throw Error(`Unknown node ID: ${String(e)}`);if(!X(t))return t.subtreeNodeCount=1,t.visibleSubtreeCount=1,1;let n=this.getDirectoryIndex(e),r=1;for(let e of n.childIds)r+=this.computeSubtreeCounts(e);return pT(this.nodes,n),t.subtreeNodeCount=r,t.visibleSubtreeCount=r,r}};function gE(e,t=`closed`,n=null){let r=vE(t);return{activeNodeCount:e.nodes.length-1,collapsedDirectoryIds:new Set,collapseNewDirectoriesByDefault:!1,defaultExpansion:r,directoriesOpenByDefault:r===`open`,hasCollapsedDirectoryOverrides:!1,directoryLoadInfoById:new Map,expandedDirectoryIds:new Set,instrumentation:n,listeners:new Map,pathCacheByNodeId:new Map([[e.rootId,{path:``,version:0}]]),pathCacheVersion:0,snapshot:e,transactionStack:[]}}function _E(){return{affectedAncestorIds:new Set,affectedNodeIds:new Set,events:[]}}function vE(e){if(typeof e!=`number`)return e;if(!Number.isInteger(e)||e<0)throw Error(`initialExpansion must be "open", "closed", or a non-negative integer depth. Received: ${String(e)}`);return e}function yE(e,t){return DT(t,2)||e.defaultExpansion===`open`?!0:e.defaultExpansion===`closed`?!1:wT(t)<=e.defaultExpansion}function bE(e,t,n=e.snapshot.nodes[t]){return n==null||!X(n)?!1:e.directoriesOpenByDefault&&!e.hasCollapsedDirectoryOverrides?!0:e.collapsedDirectoryIds.has(t)?!1:e.expandedDirectoryIds.has(t)?!0:yE(e,n)}function xE(e,t,n,r=e.snapshot.nodes[t]){if(r==null||!X(r))return;let i=yE(e,r);if(n){if(i){e.collapsedDirectoryIds.delete(t),e.hasCollapsedDirectoryOverrides=e.collapsedDirectoryIds.size>0;return}e.expandedDirectoryIds.add(t);return}if(i){e.collapsedDirectoryIds.add(t),e.hasCollapsedDirectoryOverrides=!0;return}e.expandedDirectoryIds.delete(t)}function SE(e,t){let n=e.directoryLoadInfoById.get(t);if(n!=null)return n;let r={activeAttemptId:null,errorMessage:null,nextAttemptId:1,state:`loaded`};return e.directoryLoadInfoById.set(t,r),r}function CE(e,t){return e.directoryLoadInfoById.get(t)?.state??`loaded`}function wE(e,t){let n=SE(e,t);if(n.state===`loading`&&n.activeAttemptId!=null)return{attemptId:n.activeAttemptId,nodeId:t,reused:!0};let r=n.nextAttemptId;return n.activeAttemptId=r,n.errorMessage=null,n.nextAttemptId+=1,n.state=`loading`,{attemptId:r,nodeId:t,reused:!1}}function TE(e,t){let n=SE(e,t);n.activeAttemptId=null,n.errorMessage=null,n.state=`unloaded`}function EE(e,t,n){let r=e.directoryLoadInfoById.get(t);return r==null||r.activeAttemptId!==n?!1:(r.activeAttemptId=null,r.errorMessage=null,r.state=`loaded`,!0)}function DE(e,t,n){return e.directoryLoadInfoById.get(t)?.activeAttemptId===n}function OE(e,t,n,r){let i=e.directoryLoadInfoById.get(t);return i==null||i.activeAttemptId!==n?!1:(i.activeAttemptId=null,i.errorMessage=r??null,i.state=`error`,!0)}function kE(e,t){e.directoryLoadInfoById.delete(t)}function AE(e,t,n){let r=n,i=e.listeners.get(t);return i==null?e.listeners.set(t,new Set([r])):i.add(r),()=>{let n=e.listeners.get(t);n!=null&&(n.delete(r),n.size===0&&e.listeners.delete(t))}}function jE(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!0,operation:`add`,path:e.path,projectionChanged:e.projectionChanged,visibleCountDelta:null}}function ME(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!0,operation:`remove`,path:e.path,projectionChanged:e.projectionChanged,recursive:e.recursive,visibleCountDelta:null}}function NE(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!0,from:e.from,operation:`move`,projectionChanged:e.projectionChanged,to:e.to,visibleCountDelta:null}}function PE(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!1,operation:`expand`,path:e.path,projectionChanged:!0,visibleCountDelta:null}}function FE(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!1,operation:`collapse`,path:e.path,projectionChanged:!0,visibleCountDelta:null}}function IE(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!1,operation:`mark-directory-unloaded`,path:e.path,projectionChanged:e.projectionChanged,visibleCountDelta:null}}function LE(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],attemptId:e.attemptId,canonicalChanged:!1,operation:`begin-child-load`,path:e.path,projectionChanged:e.projectionChanged,reused:e.reused,visibleCountDelta:null}}function RE(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],attemptId:e.attemptId,canonicalChanged:e.childEvents.some(e=>e.canonicalChanged),childEvents:e.childEvents,operation:`apply-child-patch`,path:e.path,projectionChanged:e.projectionChanged,visibleCountDelta:null}}function zE(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],attemptId:e.attemptId,canonicalChanged:!1,operation:`complete-child-load`,path:e.path,projectionChanged:e.projectionChanged,stale:e.stale,visibleCountDelta:null}}function BE(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],attemptId:e.attemptId,canonicalChanged:!1,errorMessage:e.errorMessage,operation:`fail-child-load`,path:e.path,projectionChanged:e.projectionChanged,stale:e.stale,visibleCountDelta:null}}function VE(e){return{activeNodeCountAfter:e.activeNodeCountAfter,activeNodeCountBefore:e.activeNodeCountBefore,affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],cachedPathEntryCountAfter:e.cachedPathEntryCountAfter,cachedPathEntryCountBefore:e.cachedPathEntryCountBefore,canonicalChanged:!1,idsPreserved:e.idsPreserved,loadInfoEntryCountAfter:e.loadInfoEntryCountAfter,loadInfoEntryCountBefore:e.loadInfoEntryCountBefore,mode:e.mode,operation:`cleanup`,projectionChanged:e.projectionChanged,reclaimedCachedPathEntryCount:e.reclaimedCachedPathEntryCount,reclaimedLoadInfoEntryCount:e.reclaimedLoadInfoEntryCount,reclaimedNodeSlotCount:e.reclaimedNodeSlotCount,reclaimedSegmentCount:e.reclaimedSegmentCount,segmentCountAfter:e.segmentCountAfter,segmentCountBefore:e.segmentCountBefore,totalNodeSlotCountAfter:e.totalNodeSlotCountAfter,totalNodeSlotCountBefore:e.totalNodeSlotCountBefore,visibleCountDelta:null}}function HE(e,t,n){return{...n,visibleCountDelta:$E(e)-t}}function UE(e,t){let n=$E(e),r=_E();e.transactionStack.push(r);try{t()}catch(t){throw KE(e,r,!1),t}KE(e,r,!0,$E(e)-n)}function WE(e,t){let n=e.instrumentation;if(n==null){GE(e,t);return}Z(n,`store.events.record`,()=>GE(e,t))}function GE(e,t){let n=e.transactionStack[e.transactionStack.length-1]??null;if(n==null){ZE(e,t);return}n.events.push(t),XE(n,t)}function KE(e,t,n,r=null){if(e.transactionStack.pop()!==t)throw Error(`Transaction stack underflow`);if(!n)return;let i=e.transactionStack[e.transactionStack.length-1]??null;if(i!=null){let n=e.instrumentation;n==null?YE(i,t):Z(n,`store.events.batch.merge`,()=>YE(i,t));return}let a=qE(t,r),o=e.instrumentation;if(o==null){ZE(e,a);return}Z(o,`store.events.batch.commit`,()=>ZE(e,a))}function qE(e,t){return{affectedAncestorIds:[...e.affectedAncestorIds],affectedNodeIds:[...e.affectedNodeIds],canonicalChanged:e.events.some(e=>e.canonicalChanged),events:[...e.events],operation:`batch`,projectionChanged:e.events.some(e=>e.projectionChanged),visibleCountDelta:t}}function JE(e,t){for(let n of t.affectedAncestorIds)e.affectedAncestorIds.add(n);for(let n of t.affectedNodeIds)e.affectedNodeIds.add(n)}function YE(e,t){for(let n of t.events)e.events.push(n);JE(e,t)}function XE(e,t){for(let n of t.affectedNodeIds)e.affectedNodeIds.add(n);for(let n of t.affectedAncestorIds)e.affectedAncestorIds.add(n)}function ZE(e,t){let n=e.instrumentation;if(n==null){QE(e,t);return}Z(n,`store.events.emit`,()=>QE(e,t))}function QE(e,t){e.listeners.get(t.operation)?.forEach(e=>e(t)),e.listeners.get(`*`)?.forEach(e=>e(t))}function $E(e){return e.snapshot.nodes[e.snapshot.rootId]?.visibleSubtreeCount??0}function eD(e,t){if(e.snapshot.options.flattenEmptyDirectories!==!0)return null;let n=e.snapshot.nodes[t];if(n==null||!X(n)||DT(n,2))return null;let r=e.snapshot.directories.get(t);if(r==null||r.childIds.length!==1)return null;let i=r.childIds[0];if(i==null)return null;let a=e.snapshot.nodes[i];return a==null||!X(a)?null:i}function tD(e,t){let n=t;for(;;){let t=eD(e,n);if(t==null)return n;n=t}}function nD(e,t){let n=[t],r=t;for(;;){let t=eD(e,r);if(t==null)return n;n.push(t),r=t}}function rD(e,t){let n=t==null?e.snapshot.rootId:pD(e,t);return n==null?[]:gD(e,n)}function iD(e,t){let n=JT(t),r=n.isDirectory?n.segments:n.segments.slice(0,-1),i=jD(e,AD(e,r)),{createdNodeIds:a,directoryId:o}=_D(e,r),s=new Set(a),c=o;if(n.isDirectory){let n=Q(e,o);if(DT(n,1))throw Error(`Path already exists: "${t}"`);OT(n,1),e.pathCacheByNodeId.set(o,{path:t,version:e.pathCacheVersion}),s.add(o)}else c=yD(e,o,n.basename),s.add(c);uD(e,o);let l=jD(e,o);return jE({affectedAncestorIds:fD(e,c),affectedNodeIds:[...s],path:t,projectionChanged:MD(i,l)})}function aD(e,t,n){let r=pD(e,t);if(r==null)throw Error(`Path does not exist: "${t}"`);let i=Q(e,r);if(DT(i,2))throw Error(`The root node cannot be removed`);if(X(i)&&hD(e,r).childIds.length>0&&n.recursive!==!0)throw Error(`Cannot remove a non-empty directory without recursive: "${t}"`);let a=i.parentId,o=jD(e,a),s=OD(e,r);SD(e,a,r,i.nameId),kD(e,a),uD(e,a);let c=jD(e,a);return ME({affectedAncestorIds:fD(e,a),affectedNodeIds:s,path:t,projectionChanged:MD(o,c),recursive:n.recursive===!0})}function oD(e,t,n,r){let i=pD(e,t);if(i==null)throw Error(`Source path does not exist: "${t}"`);let a=Q(e,i);if(DT(a,2))throw Error(`The root node cannot be moved`);let o=r.collision??`error`,s=ED(e,i,n),c=jD(e,a.parentId),l=jD(e,s.parentId),u=QT(e.snapshot.segmentTable,a.nameId),d=ZT(e.snapshot.segmentTable,s.basename);if(s.parentId===a.parentId&&u===s.basename)return null;if(X(a)&&ID(e,i,s.parentId))throw Error(`Cannot move a directory into one of its descendants`);let f=lT(e.snapshot.nodes,hD(e,s.parentId)).get(d),p=s.existingNodeId??f??null;if(p!=null&&p!==i&&DD(e,p,o,TT(a))===`skip`)return null;let m=a.parentId;SD(e,m,i,a.nameId),a.parentId=s.parentId,a.nameId=d,e.pathCacheByNodeId.delete(i),FD(e,i),xD(e,s.parentId,i),kD(e,m),e.pathCacheVersion++,uD(e,m),s.parentId!==m&&uD(e,s.parentId);let h=jD(e,m),g=jD(e,s.parentId);return NE({affectedAncestorIds:[...new Set([...fD(e,m),...fD(e,s.parentId)])],affectedNodeIds:[i],from:t,projectionChanged:ND([c,l],[h,g]),to:lD(e,i)})}function sD(e,t){let n=e.pathCacheByNodeId.get(t);return n!=null&&n.version===e.pathCacheVersion?n.path:null}function cD(e,t,n){return e.pathCacheByNodeId.set(t,{path:n,version:e.pathCacheVersion}),n}function lD(e,t){let n=Q(e,t),r=sD(e,t);if(r!=null)return r;if(DT(n,2))return cD(e,t,``);let i=lD(e,n.parentId),a=QT(e.snapshot.segmentTable,n.nameId),o=i.length===0?a:`${i}${a}`;return cD(e,t,X(n)?`${o}/`:o)}function uD(e,t){let n=e.instrumentation;if(n==null){RD(e,t);return}Z(n,`store.recomputeCountsUpwardFrom`,()=>RD(e,t))}function dD(e,t){let n=[[t,0]],{nodes:r,directories:i}=e.snapshot;for(;n.length>0;){let t=n[n.length-1],a=t[0],o=r[a];if(o==null||!X(o)){LD(e,a,o,!0),n.pop();continue}let s=i.get(a);if(s==null||t[1]>=s.childIds.length){LD(e,a,o,!0),n.pop();continue}let c=s.childIds[t[1]++];n.push([c,0])}}function fD(e,t){let n=[],r=t;for(;r!=null;){let t=Q(e,r);if(n.push(r),r===e.snapshot.rootId)break;r=t.parentId}return n}function pD(e,t){if(t.length===0)return e.snapshot.rootId;let n=YT(t);return mD(e,n.segments,n.requiresDirectory)}function mD(e,t,n){let r=e.snapshot.rootId;for(let n of t){let t=e.snapshot.segmentTable.idByValue.get(n);if(t===void 0)return null;let i=hD(e,r),a=lT(e.snapshot.nodes,i).get(t);if(a===void 0)return null;r=a}let i=Q(e,r);return n&&!X(i)?null:r}function hD(e,t){let n=e.snapshot.directories.get(t);if(n===void 0)throw Error(`Unknown directory child index for node ${String(t)}`);return n}function Q(e,t){let n=e.snapshot.nodes[t];if(n===void 0||DT(n,4))throw Error(`Unknown node ID: ${String(t)}`);return n}function gD(e,t){let n=e.snapshot.nodes[t];if(n===void 0||DT(n,4))return[];if(!X(n))return[lD(e,t)];if(hD(e,t).childIds.length===0)return DT(n,1)&&!DT(n,2)?[lD(e,t)]:[];let r=[],i=[{childIndex:0,nodeId:t}];for(;i.length>0;){let t=i[i.length-1];if(t==null)break;let n=e.snapshot.nodes[t.nodeId];if(n===void 0||DT(n,4)){i.pop();continue}if(!X(n)){r.push(lD(e,t.nodeId)),i.pop();continue}let a=hD(e,t.nodeId);if(a.childIds.length===0){DT(n,1)&&!DT(n,2)&&r.push(lD(e,t.nodeId)),i.pop();continue}let o=a.childIds[t.childIndex];if(o==null){i.pop();continue}t.childIndex++,i.push({childIndex:0,nodeId:o})}return r}function _D(e,t){let n=[],r=e.snapshot.rootId;for(let i of t){let t=ZT(e.snapshot.segmentTable,i),a=hD(e,r),o=lT(e.snapshot.nodes,a).get(t);if(o!==void 0){if(!X(Q(e,o)))throw Error(`Cannot create a directory that collides with an existing file: "${i}"`);r=o;continue}r=vD(e,r,t),n.push(r)}return{createdNodeIds:n,directoryId:r}}function vD(e,t,n){let r=Q(e,t),i=e.snapshot.nodes.length;return e.snapshot.nodes.push({depthAndFlags:CT(wT(r)+1,0,1),nameId:n,parentId:t,subtreeNodeCount:1,visibleSubtreeCount:1}),e.snapshot.directories.set(i,sT()),xD(e,t,i),e.collapseNewDirectoriesByDefault&&(e.collapsedDirectoryIds.add(i),e.hasCollapsedDirectoryOverrides=!0),e.activeNodeCount++,i}function yD(e,t,n){let r=ZT(e.snapshot.segmentTable,n),i=hD(e,t);if(lT(e.snapshot.nodes,i).has(r))throw Error(`Path already exists: "${BD(e,t,n)}"`);let a=Q(e,t),o=e.snapshot.nodes.length;return e.snapshot.nodes.push({depthAndFlags:CT(wT(a)+1,0),nameId:r,parentId:t,subtreeNodeCount:1,visibleSubtreeCount:1}),xD(e,t,o),e.activeNodeCount++,o}function bD(e,t,n){let r=0,i=t.childIds.length;for(;r<i;){let a=r+i>>>1,o=t.childIds[a];if(o==null){i=a;continue}CD(e,n,o)<0?i=a:r=a+1}return r}function xD(e,t,n){let r=hD(e,t),i=Q(e,n);lT(e.snapshot.nodes,r).set(i.nameId,n),mT(r,n,i.subtreeNodeCount,i.visibleSubtreeCount);let a=bD(e,r,n);r.childIds.splice(a,0,n),fT(r,a),_T(e.snapshot.nodes,r)}function SD(e,t,n,r){let i=hD(e,t),a=uT(i),o=a.get(n)??-1;lT(e.snapshot.nodes,i).delete(r),a.delete(n);let s=e.snapshot.nodes[n];s!=null&&mT(i,n,-s.subtreeNodeCount,-s.visibleSubtreeCount),o>=0&&(i.childIds.splice(o,1),fT(i,o),_T(e.snapshot.nodes,i))}function CD(e,t,n){let r=e.snapshot.options.sort;return r==="default"?wD(e,t,n):r(TD(e,t),TD(e,n))}function wD(e,t,n){let r=Q(e,t),i=Q(e,n),a=X(r);if(a!==X(i))return a?-1:1;let o=RT(GT(e.snapshot.segmentTable,r.nameId),GT(e.snapshot.segmentTable,i.nameId));if(o!==0)return o;let s=QT(e.snapshot.segmentTable,r.nameId),c=QT(e.snapshot.segmentTable,i.nameId);return s===c?t<n?-1:1:s<c?-1:1}function TD(e,t){let n=Q(e,t),r=lD(e,t),i=X(n),a=i?r.slice(0,-1):r;return{basename:QT(e.snapshot.segmentTable,n.nameId),depth:wT(n),isDirectory:i,path:r,segments:a.length===0?[]:a.split(`/`)}}function ED(e,t,n){let r=Q(e,t),i=pD(e,n);if(i!=null){let t=Q(e,i);if(X(t))return{basename:QT(e.snapshot.segmentTable,r.nameId),existingNodeId:null,parentId:i};let a=YT(n).segments;return{basename:a[a.length-1]??``,existingNodeId:i,parentId:t.parentId}}let a=YT(n),o=a.segments[a.segments.length-1]??``,s=a.segments.slice(0,-1),c=s.length===0?e.snapshot.rootId:mD(e,s,!0);if(c==null)throw Error(`Destination parent does not exist: "${n}"`);return{basename:o,existingNodeId:null,parentId:c}}function DD(e,t,n,r){if(n===`skip`)return`skip`;if(n===`error`)throw Error(`Destination already exists: "${lD(e,t)}"`);let i=Q(e,t);if(TT(i)!==r)throw Error(`replace collision requires the same source and destination kinds`);if(X(i)&&hD(e,t).childIds.length>0)throw Error(`replace collision does not support non-empty directories`);let a=i.parentId,o=i.nameId;return OD(e,t),SD(e,a,t,o),kD(e,a),uD(e,a),`handled`}function OD(e,t){let n=[],r=[{nodeId:t,visitedChildren:!1}];for(;r.length>0;){let t=r.pop();if(t==null)break;let i=Q(e,t.nodeId);if(t.visitedChildren||!X(i)){X(i)&&e.snapshot.directories.delete(t.nodeId),OT(i,4),e.pathCacheByNodeId.delete(t.nodeId),e.collapsedDirectoryIds.delete(t.nodeId)&&(e.hasCollapsedDirectoryOverrides=e.collapsedDirectoryIds.size>0),e.expandedDirectoryIds.delete(t.nodeId),kE(e,t.nodeId),e.activeNodeCount--,n.push(t.nodeId);continue}r.push({nodeId:t.nodeId,visitedChildren:!0});let a=hD(e,t.nodeId);for(let e=a.childIds.length-1;e>=0;e--){let t=a.childIds[e];t!=null&&r.push({nodeId:t,visitedChildren:!1})}}return n}function kD(e,t){let n=t;for(;n!=null;){let t=Q(e,n);if(!X(t)||DT(t,2)||hD(e,n).childIds.length>0)return;OT(t,1),n=t.parentId===n?null:t.parentId}}function AD(e,t){let n=e.snapshot.rootId;for(let r of t){let t=e.snapshot.segmentTable.idByValue.get(r);if(t==null)break;let i=lT(e.snapshot.nodes,hD(e,n)).get(t);if(i==null||!X(Q(e,i)))break;n=i}return n}function jD(e,t){let n=PD(e,t);if(n==null)return null;let r=tD(e,n),i=Q(e,r),a=n===r?null:nD(e,n).map(t=>lD(e,t));return JSON.stringify({flattenedSegmentPaths:a,hasChildren:hD(e,r).childIds.length>0,path:lD(e,r),terminalKind:TT(i)})}function MD(e,t){return ND([e],[t])}function ND(e,t){for(let n=0;n<e.length;n+=1){let r=e[n],i=t[n];if(r==null||i==null||r!==i)return!0}return!1}function PD(e,t){let n=t;for(;n!=null;){let t=Q(e,n);if(!X(t)||DT(t,2))return null;if(!bE(e,n,t))return n;n=t.parentId}return null}function FD(e,t){let n=Q(e,t);if(kT(n,(t===e.snapshot.rootId?-1:wT(Q(e,n.parentId)))+1),!X(n))return;let r=hD(e,t);for(let t of r.childIds)FD(e,t)}function ID(e,t,n){let r=n;for(;r!=null;){if(r===t)return!0;let n=Q(e,r);if(r===e.snapshot.rootId)return!1;r=n.parentId}return!1}function LD(e,t,n=Q(e,t),r=!1){let i=e.instrumentation;if(i==null){zD(e,t,n,r);return}Z(i,`store.recomputeNodeCounts`,()=>zD(e,t,n,r))}function RD(e,t){let n=t;for(;n!=null;){let t=Q(e,n),r=t.subtreeNodeCount,i=t.visibleSubtreeCount;if(LD(e,n,t),n===e.snapshot.rootId)return;let a=t.subtreeNodeCount-r,o=t.visibleSubtreeCount-i,s=t.parentId;(a!==0||o!==0)&&mT(hD(e,s),n,a,o),n=s}}function zD(e,t,n,r){if(!X(n)){n.subtreeNodeCount=1,n.visibleSubtreeCount=1;return}let i=hD(e,t);if(r){let t=e.instrumentation;t==null?pT(e.snapshot.nodes,i):Z(t,`store.recomputeNodeCounts.rebuildChildAggregates`,()=>pT(e.snapshot.nodes,i))}let a=1+i.totalChildSubtreeNodeCount,o=i.totalChildVisibleSubtreeCount;if(n.subtreeNodeCount=a,DT(n,2)){n.visibleSubtreeCount=o;return}n.visibleSubtreeCount=eD(e,t)==null?bE(e,t,n)?1+o:1:o}function BD(e,t,n){let r=lD(e,t);return r.length===0?n:`${r}${n}`}function VD(e){return e!=null&&!DT(e,4)}function HD(e,t){let n=e.snapshot.nodes[t];return!VD(n)||!X(n)||DT(n,2)?null:n}function UD(e){let t=0;for(let[n,r]of e.pathCacheByNodeId)r.version===e.pathCacheVersion&&VD(e.snapshot.nodes[n])&&(t+=1);return t}function WD(e){return Math.max(0,e.valueById.length-1)}function GD(e){return{activeNodeCount:e.activeNodeCount,cachedPathEntryCount:UD(e),loadInfoEntryCount:e.directoryLoadInfoById.size,segmentCount:WD(e.snapshot.segmentTable),totalNodeSlotCount:Math.max(0,e.snapshot.nodes.length-1)}}function KD(e,t,n,r){return{activeNodeCountAfter:r.activeNodeCount,activeNodeCountBefore:n.activeNodeCount,cachedPathEntryCountAfter:r.cachedPathEntryCount,cachedPathEntryCountBefore:n.cachedPathEntryCount,idsPreserved:t,loadInfoEntryCountAfter:r.loadInfoEntryCount,loadInfoEntryCountBefore:n.loadInfoEntryCount,mode:e,reclaimedCachedPathEntryCount:n.cachedPathEntryCount-r.cachedPathEntryCount,reclaimedLoadInfoEntryCount:n.loadInfoEntryCount-r.loadInfoEntryCount,reclaimedNodeSlotCount:n.totalNodeSlotCount-r.totalNodeSlotCount,reclaimedSegmentCount:n.segmentCount-r.segmentCount,segmentCountAfter:r.segmentCount,segmentCountBefore:n.segmentCount,totalNodeSlotCountAfter:r.totalNodeSlotCount,totalNodeSlotCountBefore:n.totalNodeSlotCount}}function qD(e){let t=[],n=[];for(let n of e.collapsedDirectoryIds)HD(e,n)!=null&&t.push(lD(e,n));for(let t of e.expandedDirectoryIds)HD(e,t)!=null&&n.push(lD(e,t));return{collapsedPaths:t,expandedPaths:n}}function JD(e){let t=[];for(let[n,r]of e.directoryLoadInfoById)HD(e,n)==null||CE(e,n)===`loaded`||t.push({info:{activeAttemptId:null,errorMessage:r.errorMessage,nextAttemptId:r.nextAttemptId,state:r.state},path:lD(e,n)});return t}function YD(e,t){e.collapsedDirectoryIds.clear(),e.hasCollapsedDirectoryOverrides=!1,e.expandedDirectoryIds.clear();for(let n of t.expandedPaths){let t=pD(e,n);t!=null&&xE(e,t,!0,Q(e,t))}for(let n of t.collapsedPaths){let t=pD(e,n);t!=null&&xE(e,t,!1,Q(e,t))}}function XD(e,t){e.directoryLoadInfoById.clear();for(let n of t){let t=pD(e,n.path);t!=null&&HD(e,t)!=null&&e.directoryLoadInfoById.set(t,{activeAttemptId:null,errorMessage:n.info.errorMessage,nextAttemptId:n.info.nextAttemptId,state:n.info.state})}}function ZD(e){e.pathCacheVersion+=1,e.pathCacheByNodeId.clear(),e.pathCacheByNodeId.set(e.snapshot.rootId,{path:``,version:e.pathCacheVersion})}function QD(e){let t=e.snapshot.segmentTable,n=XT();for(let r of e.snapshot.nodes)if(VD(r)){if(DT(r,2)){r.nameId=0;continue}r.nameId=ZT(n,QT(t,r.nameId))}e.snapshot.segmentTable=n}function $D(e){for(let[t,n]of e.snapshot.directories){let r=e.snapshot.nodes[t];if(!VD(r)||!X(r)){e.snapshot.directories.delete(t);continue}let i=n.childIds.filter(n=>{let r=e.snapshot.nodes[n];return VD(r)&&r.parentId===t});n.childIds=i,n.childIdByNameId=new Map(i.map(t=>[Q(e,t).nameId,t])),n.childPositionById=new Map(i.map((e,t)=>[e,t])),pT(e.snapshot.nodes,n)}}function eO(e){let t=e.snapshot.nodes.length-1;for(;t>e.snapshot.rootId;){let n=e.snapshot.nodes[t];if(VD(n))break;--t}e.snapshot.nodes.length=t+1}function tO(e){let t=qD(e),n=JD(e);Z(e.instrumentation,`store.cleanup.stable.clearPathCaches`,()=>ZD(e)),Z(e.instrumentation,`store.cleanup.stable.rebuildSegmentTable`,()=>QD(e)),Z(e.instrumentation,`store.cleanup.stable.rebuildDirectoryIndexes`,()=>$D(e)),Z(e.instrumentation,`store.cleanup.stable.trimTrailingRemovedNodeSlots`,()=>eO(e)),Z(e.instrumentation,`store.cleanup.stable.restoreExpansionOverrides`,()=>YD(e,t)),Z(e.instrumentation,`store.cleanup.stable.restoreDirectoryLoadInfos`,()=>XD(e,n)),Z(e.instrumentation,`store.cleanup.stable.recomputeCounts`,()=>dD(e,e.snapshot.rootId))}function nO(e){let t=qD(e),n=JD(e),r=Z(e.instrumentation,`store.cleanup.aggressive.listPaths`,()=>rD(e)),i=jT({...e.snapshot.options},e.instrumentation),a=Z(e.instrumentation,`store.cleanup.aggressive.rebuildSnapshot`,()=>{let e=new hE(i);return e.appendPaths(r),e.finish()});e.snapshot=a,e.activeNodeCount=a.nodes.length-1,e.pathCacheByNodeId=new Map([[a.rootId,{path:``,version:0}]]),e.pathCacheVersion=0,Z(e.instrumentation,`store.cleanup.aggressive.restoreExpansionOverrides`,()=>YD(e,t)),Z(e.instrumentation,`store.cleanup.aggressive.restoreDirectoryLoadInfos`,()=>XD(e,n)),Z(e.instrumentation,`store.cleanup.aggressive.recomputeCounts`,()=>dD(e,e.snapshot.rootId))}function rO(e){for(let t of e.directoryLoadInfoById.values())if(t.state===`loading`&&t.activeAttemptId!=null)return!0;return!1}function iO(e,t){let n=GD(e);t===`stable`?Z(e.instrumentation,`store.cleanup.stable`,()=>tO(e)):Z(e.instrumentation,`store.cleanup.aggressive`,()=>nO(e));let r=GD(e);return KD(t,t===`stable`,n,r)}var aO=64;function oO(e,t){let n=t+2;if(n<=e.length)return e;let r=e.length;for(;r<n;)r*=2;let i=new Int32Array(r);return i.fill(-1),i.set(e),i}function sO(e){return Q(e,e.snapshot.rootId).visibleSubtreeCount}function cO(e,t,n,r){let i=Q(e,t.terminalNodeId),a=Math.max(1,i.visibleSubtreeCount);return Math.min(r-1,n+a-1)}function lO(e,t,n,r){return{ancestorPaths:r,index:t.index,posInSet:t.posInSet,row:OO(e,t.cursor),setSize:t.setSize,subtreeEndIndex:cO(e,t.cursor,t.index,n)}}function uO(e,t,n,r,i,a){let o=hD(e,t),{childIndex:s,childVisibleIndex:c,localVisibleIndex:l}=hT(e.snapshot.nodes,o,n),u=o.childIds[s];if(u==null)throw Error(`Visible index ${String(n)} is out of range`);return dO(e,u,l,r+c,i+1,s,o.childIds.length,a)}function dO(e,t,n,r,i,a,o,s){if(!X(Q(e,t))){if(n===0)return{ancestors:s,cursor:{headNodeId:t,terminalNodeId:t,visibleDepth:i},index:r,posInSet:a,setSize:o};throw Error(`Visible index ${String(n)} is out of range for file`)}let c=SO(e,t,i);if(n===0)return{ancestors:s,cursor:c,index:r,posInSet:a,setSize:o};let l=Q(e,c.terminalNodeId);if(!X(l)||!bE(e,c.terminalNodeId,l))throw Error(`Visible index ${String(n)} is out of range for collapsed directory`);return uO(e,c.terminalNodeId,n-1,r+1,c.visibleDepth,[...s,{cursor:c,index:r,posInSet:a,setSize:o}])}function fO(e,t){let n=sO(e);if(t<0||t>=n)return null;let r=uO(e,e.snapshot.rootId,t,0,-1,[]),i=r.ancestors.map(t=>lD(e,t.cursor.terminalNodeId)),a=null;return{ancestorPaths:i,get ancestorRows(){if(a!=null)return a;let t=[],i=[];for(let a of r.ancestors){let r=lO(e,a,n,[...i]);t.push(r),i.push(r.row.path)}return a=t,a},index:r.index,posInSet:r.posInSet,row:OO(e,r.cursor),setSize:r.setSize,subtreeEndIndex:cO(e,r.cursor,r.index,n)}}function pO(e,t,n){let r=e.instrumentation,i=sO(e);if(i<=0||n<t)return[];let a=Math.max(0,Math.min(t,i-1)),o=Math.max(a,Math.min(n,i-1));if(r==null){if(a===0)return DO(e,o+1);let t=[],n=yO(e,a);for(let r=a;r<=o&&n!=null;r++){let r=OO(e,n);t.push(r),n=wO(e,n)}return t}let s=[],c=0,l=0,u=Z(r,`store.getVisibleSlice.selectFirstRow`,()=>yO(e,a));for(let t=a;t<=o&&u!=null;t++){let t=Z(r,`store.getVisibleSlice.materializeRow`,()=>OO(e,u));s.push(t),t.isFlattened&&(c++,l+=t.flattenedSegments?.length??0),u=Z(r,`store.getVisibleSlice.advanceCursor`,()=>wO(e,u))}return NT(r,`workload.visibleRowsRead`,s.length),NT(r,`workload.flattenedRowsRead`,c),NT(r,`workload.flattenedSegmentsRead`,l),s}function mO(e,t=sO(e)){let n=e.instrumentation;return n==null?EO(e,t):Z(n,`store.getVisibleTreeProjection`,()=>EO(e,t))}function hO(e){return TO(mO(e))}function gO(e,t){let n=pD(e,t);if(n==null||n===e.snapshot.rootId||X(Q(e,n))&&tD(e,n)!==n)return null;let r=0,i=n,{nodes:a,rootId:o}=e.snapshot;for(;i!==o;){let t=Q(e,i).parentId,n=hD(e,t),s=uT(n).get(i);if(s==null)throw Error(`Child ${String(i)} was not found in its parent index`);if(r+=gT(a,n,s),t!==o){let n=Q(e,t),a=eD(e,t);if(!bE(e,t,n)&&a!==i)return null;tD(e,t)===t&&(r+=1)}i=t}return r}function _O(e,t){let n=pD(e,t);if(n==null)throw Error(`Path does not exist: "${t}"`);let r=Q(e,n);if(!X(r))throw Error(`Path is not a directory: "${t}"`);return bE(e,n,r)?null:(xE(e,n,!0,r),uD(e,n),PE({affectedAncestorIds:fD(e,n),affectedNodeIds:[n],path:t,projectionChanged:!0}))}function vO(e,t){let n=pD(e,t);if(n==null)throw Error(`Path does not exist: "${t}"`);let r=Q(e,n);if(!X(r))throw Error(`Path is not a directory: "${t}"`);return bE(e,n,r)?(xE(e,n,!1,r),uD(e,n),FE({affectedAncestorIds:fD(e,n),affectedNodeIds:[n],path:t,projectionChanged:!0})):null}function yO(e,t){return t<0||t>=sO(e)?null:bO(e,e.snapshot.rootId,t,-1)}function bO(e,t,n,r){let i=hD(e,t),a=e.instrumentation,{childIndex:o,localVisibleIndex:s}=a==null?hT(e.snapshot.nodes,i,n):Z(a,`store.getVisibleSlice.selectChildIndex`,()=>hT(e.snapshot.nodes,i,n)),c=i.childIds[o];if(c!=null)return xO(e,c,s,r+1);throw Error(`Visible index ${String(n)} is out of range`)}function xO(e,t,n,r){if(!X(Q(e,t))){if(n===0)return{headNodeId:t,terminalNodeId:t,visibleDepth:r};throw Error(`Visible index ${String(n)} is out of range for file`)}let i=SO(e,t,r);if(n===0)return i;let a=Q(e,i.terminalNodeId);if(!X(a)||!bE(e,i.terminalNodeId,a))throw Error(`Visible index ${String(n)} is out of range for collapsed directory`);return bO(e,i.terminalNodeId,n-1,i.visibleDepth)}function SO(e,t,n){return X(Q(e,t))?e.instrumentation==null?{headNodeId:t,terminalNodeId:tD(e,t),visibleDepth:n}:{headNodeId:t,terminalNodeId:Z(e.instrumentation,`store.getVisibleSlice.flatten.resolveTerminalDirectory`,()=>tD(e,t)),visibleDepth:n}:{headNodeId:t,terminalNodeId:t,visibleDepth:n}}function CO(e,t){let n=Q(e,t);if(!X(n))return!0;let r=n.parentId;return r===e.snapshot.rootId?!0:eD(e,r)!==t}function wO(e,t){let n=Q(e,t.terminalNodeId);if(X(n)){let r=hD(e,t.terminalNodeId);if(bE(e,t.terminalNodeId,n)&&r.childIds.length>0){let n=r.childIds[0];return n==null?null:xO(e,n,0,t.visibleDepth+1)}}let r=t.terminalNodeId,i=t.visibleDepth;for(;;){let t=Q(e,r);if(r===e.snapshot.rootId)return null;let n=t.parentId,a=hD(e,n),o=uT(a).get(r)??-1;if(o<0)throw Error(`Child ${String(r)} was not found in its parent index`);let s=a.childIds[o+1]??null;if(s!=null)return xO(e,s,0,i);CO(e,r)&&i--,r=n}}function TO(e){let t=e.paths.length,n=Array(t);for(let r=0;r<t;r+=1){let t=e.getParentIndex(r);n[r]={index:r,parentPath:t>=0?e.paths[t]??null:null,path:e.paths[r]??``,posInSet:e.posInSetByIndex[r]??0,setSize:e.setSizeByIndex[r]??0}}return{getParentIndex:e.getParentIndex,rows:n,get visibleIndexByPath(){return e.visibleIndexByPath}}}function EO(e,t){let n=Array(t),r=new Int32Array(t),i=new Int32Array(t),a=new Int32Array(t),o=new Int32Array(aO);o.fill(-1);let s=0,{nodes:c,directories:l,segmentTable:u}=e.snapshot,d=[[l.get(e.snapshot.rootId),0,-1,``]],f=e.snapshot.options.flattenEmptyDirectories,p=e.pathCacheByNodeId,m=e.pathCacheVersion,h=u.valueById;for(;d.length>0&&s<t;){let t=d[d.length-1],u=t[0];if(t[1]>=u.childIds.length){d.pop();continue}let g=t[1],_=u.childIds[t[1]++],v=c[_],y=t[2]+1,b=t[3];o=oO(o,y);let x,S=_;if(X(v))S=f?tD(e,_):_,x=S===_?`${b}${h[v.nameId]}/`:lD(e,S);else{let e=p.get(_);x=e!=null&&e.version===m?e.path:`${b}${h[v.nameId]}`}r[s]=o[y],n[s]=x,i[s]=g,a[s]=u.childIds.length,o[y+1]=s,s+=1;let C=c[S];C!=null&&X(C)&&bE(e,S,C)&&d.push([l.get(S),0,y,x])}s<t&&(n.length=s);let g=r.subarray(0,s),_=i.subarray(0,s),v=a.subarray(0,s),y=null;return{getParentIndex(e){return e<0||e>=s?-1:g[e]??-1},paths:n,posInSetByIndex:_,setSizeByIndex:v,get visibleIndexByPath(){if(y==null){y=new Map;for(let e=0;e<s;e+=1)y.set(n[e]??``,e)}return y}}}function DO(e,t){let n=Array(t),r=0,{nodes:i,directories:a,segmentTable:o}=e.snapshot,s=[[a.get(e.snapshot.rootId),0,-1]],c=o.valueById,l=e.snapshot.options.flattenEmptyDirectories,u=e.pathCacheByNodeId,d=e.pathCacheVersion;for(;s.length>0&&r<t;){let t=s[s.length-1],o=t[0];if(t[1]>=o.childIds.length){s.pop();continue}let f=o.childIds[t[1]++],p=i[f],m=t[2]+1;if(!X(p)){let t=u.get(f);n[r++]={depth:m,flattenedSegments:void 0,hasChildren:!1,id:f,isExpanded:!1,isFlattened:!1,isLoading:!1,kind:`file`,loadState:void 0,name:c[p.nameId],path:t!=null&&t.version===d?t.path:lD(e,f)};continue}let h=l?tD(e,f):f,g={headNodeId:f,terminalNodeId:h,visibleDepth:m};n[r++]=OO(e,g);let _=i[h];_!=null&&X(_)&&bE(e,h,_)&&s.push([a.get(h),0,m])}return r<t&&(n.length=r),n}function OO(e,t){let n=Q(e,t.terminalNodeId),r=X(n)?kO(e,t):null,i=lD(e,t.terminalNodeId),a=QT(e.snapshot.segmentTable,n.nameId),o=X(n)&&hD(e,t.terminalNodeId).childIds.length>0,s=t.headNodeId!==t.terminalNodeId,c=e.instrumentation,l=s?c==null?nD(e,t.headNodeId).map(n=>{let r=Q(e,n);return{isTerminal:n===t.terminalNodeId,name:QT(e.snapshot.segmentTable,r.nameId),nodeId:n,path:lD(e,n)}}):Z(c,`store.getVisibleSlice.flatten.collectSegments`,()=>nD(e,t.headNodeId).map(n=>{let r=Q(e,n);return{isTerminal:n===t.terminalNodeId,name:QT(e.snapshot.segmentTable,r.nameId),nodeId:n,path:lD(e,n)}})):void 0;return{depth:t.visibleDepth,flattenedSegments:l,hasChildren:o,id:t.terminalNodeId,isExpanded:X(n)&&bE(e,t.terminalNodeId,n),isFlattened:s,isLoading:r===`loading`,kind:X(n)?`directory`:`file`,loadState:r==null||r===`loaded`?void 0:r,name:a,path:i}}function kO(e,t){if(t.headNodeId===t.terminalNodeId)return CE(e,t.terminalNodeId);let n=nD(e,t.headNodeId),r=!1,i=!1;for(let t of n){let n=CE(e,t);if(n===`loading`)return`loading`;if(n===`error`){i=!0;continue}n===`unloaded`&&(r=!0)}return i?`error`:r?`unloaded`:`loaded`}function AO(e){let{directories:t,nodes:n,options:r,rootId:i,presortedDirectoryNodeIds:a}=e.snapshot,o=r.flattenEmptyDirectories===!0,s=e=>{let r=n[e];if(r==null||!X(r))return;let i=t.get(e);if(i==null)throw Error(`Unknown directory child index for node ${String(e)}`);let a=i.childIds,s=a.length,c=0,l=0;for(let e=0;e<s;e++){let t=a[e];if(t==null)continue;let r=n[t];c+=r.subtreeNodeCount,l+=r.visibleSubtreeCount}i.totalChildSubtreeNodeCount=c,i.totalChildVisibleSubtreeCount=l,s>=128&&_T(n,i),r.subtreeNodeCount=1+c;let u;if(o&&s===1){let e=n[a[0]];u=e!=null&&X(e)?l:1+l}else u=1+l;r.visibleSubtreeCount=u};if(a!=null)for(let e=a.length-1;e>=0;e--)s(a[e]);else for(let e=n.length-1;e>=1;e--)s(e);let c=n[i],l=t.get(i);if(c==null||l==null)return;let u=l.childIds,d=0,f=0;for(let e=0;e<u.length;e++){let t=u[e];if(t==null)continue;let r=n[t];d+=r.subtreeNodeCount,f+=r.visibleSubtreeCount}l.totalChildSubtreeNodeCount=d,l.totalChildVisibleSubtreeCount=f,_T(n,l),c.subtreeNodeCount=1+d,c.visibleSubtreeCount=f}function jO(e){return e.initialExpansion===`open`&&(e.initialExpandedPaths==null||e.initialExpandedPaths.length===0)}var MO=class e{#e;constructor(e={}){let t=MT(e),n=Z(t,`store.builder.create`,()=>new hE(e));if(e.preparedInput!=null){let t=fE(e.preparedInput);t==null?n.appendPreparedPaths(dE(e.preparedInput),!1):n.appendPresortedPaths(t,pE(e.preparedInput))}else{let r=e.paths??[];e.presorted===!0?n.appendPaths(r):n.appendPreparedPaths(Z(t,`store.preparePathEntries`,()=>mE(r,e)))}let r=Z(t,`store.builder.finish`,()=>n.finish({skipSubtreeCountPass:!0})),i=Z(t,`store.state.detectAllDirectoriesExpanded`,()=>(e.initialExpansion??`closed`)===`closed`&&n.didMatchAllInitialExpandedPaths());this.#e=Z(t,`store.state.create`,()=>gE(r,i?`open`:e.initialExpansion??`closed`,t)),i&&(this.#e.collapseNewDirectoriesByDefault=!0);let a=i?this.#e.snapshot.directories.size-1:Z(t,`store.state.initializeExpandedPaths`,()=>this.initializeExpandedPaths(e.initialExpandedPaths));i||jO(e)||(e.initialExpansion??`closed`)===`closed`&&a===this.#e.snapshot.directories.size-1||(e.initialExpandedPaths?.length??0)>0&&Z(t,`store.state.checkAllDirectoriesExpanded`,()=>this.hasAllDirectoriesExpanded())?Z(t,`store.state.initializeOpenVisibleCounts`,()=>AO(this.#e)):Z(t,`store.state.recomputeCounts`,()=>dD(this.#e,this.#e.snapshot.rootId))}static preparePaths(e,t={}){return cE(e,t)}static prepareInput(e,t={}){return lE(e,t)}static preparePresortedInput(e){return uE(e)}list(e){return Z(this.#e.instrumentation,`store.list`,()=>rD(this.#e,e))}add(e){Z(this.#e.instrumentation,`store.add`,()=>{let t=sO(this.#e);WE(this.#e,HE(this.#e,t,iD(this.#e,e)))})}remove(e,t={}){Z(this.#e.instrumentation,`store.remove`,()=>{let n=sO(this.#e);WE(this.#e,HE(this.#e,n,aD(this.#e,e,t)))})}move(e,t,n={}){Z(this.#e.instrumentation,`store.move`,()=>{let r=sO(this.#e),i=oD(this.#e,e,t,n);i!=null&&WE(this.#e,HE(this.#e,r,i))})}batch(e){UE(this.#e,()=>{if(typeof e==`function`){e(this);return}for(let t of e)switch(t.type){case`add`:this.add(t.path);break;case`remove`:this.remove(t.path,{recursive:t.recursive});break;case`move`:this.move(t.from,t.to,{collision:t.collision});break}})}getVisibleCount(){return Z(this.#e.instrumentation,`store.getVisibleCount`,()=>sO(this.#e))}getVisibleSlice(e,t){return Z(this.#e.instrumentation,`store.getVisibleSlice`,()=>pO(this.#e,e,t))}getVisibleRowContext(e){return Z(this.#e.instrumentation,`store.getVisibleRowContext`,()=>fO(this.#e,e))}getVisibleTreeProjection(){return hO(this.#e)}getVisibleTreeProjectionData(e){return mO(this.#e,e)}getVisibleIndex(e){return Z(this.#e.instrumentation,`store.getVisibleIndex`,()=>gO(this.#e,e))}getPathInfo(e){return Z(this.#e.instrumentation,`store.getPathInfo`,()=>{let t=pD(this.#e,e);if(t==null)return null;let n=Q(this.#e,t);return{depth:wT(n),kind:X(n)?`directory`:`file`,path:lD(this.#e,t)}})}isExpanded(e){return Z(this.#e.instrumentation,`store.isExpanded`,()=>{let t=this.requireDirectoryNodeId(e),n=Q(this.#e,t);return bE(this.#e,t,n)})}expand(e){Z(this.#e.instrumentation,`store.expand`,()=>{let t=sO(this.#e),n=_O(this.#e,e);n!=null&&WE(this.#e,HE(this.#e,t,n))})}collapse(e){Z(this.#e.instrumentation,`store.collapse`,()=>{let t=sO(this.#e),n=vO(this.#e,e);n!=null&&WE(this.#e,HE(this.#e,t,n))})}on(e,t){return AE(this.#e,e,t)}getDirectoryLoadState(e){let t=this.requireDirectoryNodeId(e);return CE(this.#e,t)}markDirectoryUnloaded(e){Z(this.#e.instrumentation,`store.markDirectoryUnloaded`,()=>{let t=this.requireDirectoryNodeId(e);if(hD(this.#e,t).childIds.length>0)throw Error(`Cannot mark a directory with known children as unloaded: "${e}"`);let n=sO(this.#e);TE(this.#e,t),WE(this.#e,HE(this.#e,n,IE({affectedAncestorIds:fD(this.#e,t),affectedNodeIds:[t],path:e,projectionChanged:this.isDirectoryProjectionVisible(t)})))})}beginChildLoad(e){return Z(this.#e.instrumentation,`store.beginChildLoad`,()=>{let t=this.requireDirectoryNodeId(e),n=sO(this.#e),r=wE(this.#e,t);return WE(this.#e,HE(this.#e,n,LE({affectedAncestorIds:fD(this.#e,t),affectedNodeIds:[t],attemptId:r.attemptId,path:e,projectionChanged:this.isDirectoryProjectionVisible(t),reused:r.reused}))),r})}applyChildPatch(e,t){return Z(this.#e.instrumentation,`store.applyChildPatch`,()=>{let n=this.resolveActiveDirectoryNodeId(e.nodeId);if(n==null||CE(this.#e,n)!==`loading`||!DE(this.#e,n,e.attemptId))return!1;let r=lD(this.#e,n);this.validateChildPatch(r,t);let i=sO(this.#e),a=[];for(let e of t.operations){NO(r,e);let t=sO(this.#e);switch(e.type){case`add`:a.push(HE(this.#e,t,iD(this.#e,e.path)));break;case`remove`:a.push(HE(this.#e,t,aD(this.#e,e.path,{recursive:e.recursive})));break;case`move`:{let n=oD(this.#e,e.from,e.to,{collision:e.collision});n!=null&&a.push(HE(this.#e,t,n));break}}}let o=a.some(e=>e.projectionChanged)||this.isDirectoryProjectionVisible(n);return WE(this.#e,HE(this.#e,i,RE({affectedAncestorIds:fD(this.#e,n),affectedNodeIds:[n],attemptId:e.attemptId,childEvents:a,path:lD(this.#e,n),projectionChanged:o}))),!0})}completeChildLoad(e){return Z(this.#e.instrumentation,`store.completeChildLoad`,()=>{let t=this.resolveActiveDirectoryNodeId(e.nodeId);if(t==null)return!1;let n=sO(this.#e),r=EE(this.#e,t,e.attemptId);return WE(this.#e,HE(this.#e,n,zE({affectedAncestorIds:fD(this.#e,t),affectedNodeIds:[t],attemptId:e.attemptId,path:lD(this.#e,t),projectionChanged:this.isDirectoryProjectionVisible(t),stale:!r}))),r})}failChildLoad(e,t){return Z(this.#e.instrumentation,`store.failChildLoad`,()=>{let n=this.resolveActiveDirectoryNodeId(e.nodeId);if(n==null)return!1;let r=sO(this.#e),i=OE(this.#e,n,e.attemptId,t);return WE(this.#e,HE(this.#e,r,BE({affectedAncestorIds:fD(this.#e,n),affectedNodeIds:[n],attemptId:e.attemptId,errorMessage:t,path:lD(this.#e,n),projectionChanged:this.isDirectoryProjectionVisible(n),stale:!i}))),i})}cleanup(e={}){return Z(this.#e.instrumentation,`store.cleanup`,()=>{if(this.#e.transactionStack.length>0)throw Error(`Cleanup cannot run during an open batch or transaction.`);if(rO(this.#e))throw Error(`Cleanup cannot run while directory loads are active.`);let t=sO(this.#e),n=iO(this.#e,e.mode??`stable`);return WE(this.#e,HE(this.#e,t,VE({...n,affectedAncestorIds:[],affectedNodeIds:[],projectionChanged:n.idsPreserved===!1}))),n})}getNodeCount(){return this.#e.activeNodeCount}initializeExpandedPaths(e){if(e==null||e.length===0)return 0;let t=0,n=[],r=[],i=0,a=null,o=this.#e.snapshot.segmentTable,s=o.valueById,c=this.#e.snapshot.nodes,l=new Map;for(let u of e){a!=null&&u<a&&(a=null,i=0,n.length=0,r.length=0);let e=u.length>0&&u.charCodeAt(u.length-1)===47?u.length-1:u.length;if(e===0){a=u,i=e,n.length=0,r.length=0;continue}let d=0,f=0;if(a!=null){let t=Math.min(e,i),n=!0;for(let e=0;e<t;e+=1){let t=u.charCodeAt(e);if(t!==a.charCodeAt(e)){n=!1;break}t===47&&(d+=1,f=e+1)}n&&(t===i&&e>t&&u.charCodeAt(t)===47?(d+=1,f=t+1):t===e&&i>t&&a.charCodeAt(t)===47&&(d+=1,f=e+1)),d=Math.min(d,r.length)}let p=d===0?this.#e.snapshot.rootId:r[d-1]??this.#e.snapshot.rootId,m=d,h=!0,g=f;for(;g<=e;){let t=u.indexOf(`/`,g),i=t===-1||t>e?e:t,a=u.slice(g,i),f=hD(this.#e,p).childIds,_=m===d?n[m]??0:0,v=_,y,b=l.get(a)??IT(a);l.set(a,b);let x=(e,t)=>{for(v=e;v<t;v+=1){let e=f[v],t=c[e],n=s[t.nameId];if(n===a)return y=e,!0;let r=RT(GT(o,t.nameId),b);if(r>0||r===0&&n>a)return!1}return!1};if(!x(_,f.length)&&_>0&&x(0,_),y===void 0){h=!1;break}if(!X(Q(this.#e,y))){h=!1;break}if(n[m]=v,r[m]=y,p=y,m+=1,i===e)break;g=i+1}if(a=u,i=e,n.length=m,r.length=m,!h){a=null,i=0,n.length=0,r.length=0;continue}for(let e=d;e<m;e+=1){let n=r[e];if(n==null)continue;let i=Q(this.#e,n);bE(this.#e,n,i)||(xE(this.#e,n,!0,i),t+=1)}}return t}hasAllDirectoriesExpanded(){for(let e of this.#e.snapshot.directories.keys()){if(e===this.#e.snapshot.rootId)continue;let t=Q(this.#e,e);if(!bE(this.#e,e,t))return!1}return!0}requireDirectoryNodeId(e){let t=pD(this.#e,e);if(t==null)throw Error(`Path does not exist: "${e}"`);if(!X(Q(this.#e,t)))throw Error(`Path is not a directory: "${e}"`);return t}resolveActiveDirectoryNodeId(e){try{if(!X(Q(this.#e,e)))throw Error(`Node is not a directory: ${String(e)}`);return e}catch{return null}}isDirectoryProjectionVisible(e){let t=e;for(;t!==this.#e.snapshot.rootId;){let e=Q(this.#e,t).parentId;if(e!==this.#e.snapshot.rootId){let n=Q(this.#e,e),r=eD(this.#e,e);if(!bE(this.#e,e,n)&&r!==t)return!1}t=e}return!0}validateChildPatch(t,n){new e({paths:this.list(t),presorted:!0,sort:this.#e.snapshot.options.sort}).batch(n.operations)}};function NO(e,t){switch(t.type){case`add`:case`remove`:if(!t.path.startsWith(e)||t.path===e)throw Error(`Child patch operation must stay within ${e}: "${t.path}"`);break;case`move`:if(!t.from.startsWith(e)||!t.to.startsWith(e)||t.from===e||t.to===e)throw Error(`Child patch move must stay within ${e}: "${t.from}" -> "${t.to}"`);break}}var PO=e=>e.startsWith(`f::`)?e.slice(3):e;function FO(e){let t=e.lastIndexOf(`/`);return t<0?{parentPath:``,baseName:e}:{parentPath:e.slice(0,t),baseName:e.slice(t+1)}}function IO(e,t){return e===``?t:`${e}/${t}`}function LO({files:e,path:t,isFolder:n,nextBasename:r}){let i=PO(t),a=r.trim();if(a.length===0)return{error:`Name cannot be empty.`};if(a.includes(`/`))return{error:`Name cannot include "/".`};let{parentPath:o,baseName:s}=FO(i);if(a===s)return{nextFiles:e,sourcePath:i,destinationPath:i,isFolder:n};let c=IO(o,a),l=Array(e.length),u=new Set;if(!n){let t=`${c}/`,r=!1;for(let n=0;n<e.length;n++){let a=e[n];if(a!==i&&a.startsWith(t))return{error:`"${c}" already exists.`};let o=a===i?c:a;if(u.has(o))return{error:`"${c}" already exists.`};u.add(o),l[n]=o,a===i&&(r=!0)}return r?{nextFiles:l,sourcePath:i,destinationPath:c,isFolder:n}:{error:`Could not find the selected file to rename.`}}let d=`${i}/`,f=`${c}/`,p=0;for(let t=0;t<e.length;t++){let n=e[t],r=n===i||n.startsWith(d);if(!r&&(n===c||n.startsWith(f)))return{error:`"${c}" already exists.`};let a=r?`${c}${n.slice(i.length)}`:n;if(u.has(a))return{error:`"${c}" already exists.`};u.add(a),l[t]=a,r&&p++}return p===0?{error:`Could not find the selected folder to rename.`}:{nextFiles:l,sourcePath:i,destinationPath:c,isFolder:n}}function RO(e){return e.endsWith(`/`)}function zO(e){let t=e.endsWith(`/`)?e.slice(0,-1):e,n=t.lastIndexOf(`/`),r=n<0?t:t.slice(n+1);return e.endsWith(`/`)?`${r}/`:r}function BO(e){let t=[],n=new Set;for(let r of e)n.has(r)||(n.add(r),t.push(r));let r=new Set;for(let e of t.toSorted((e,t)=>e.length===t.length?e.localeCompare(t):e.length-t.length)){let t=(e.endsWith(`/`)?e.slice(0,-1):e).split(`/`),n=!1;for(let e=0;e<t.length-1;e+=1){let i=`${t.slice(0,e+1).join(`/`)}/`;if(r.has(i)){n=!0;break}}n||r.add(e)}return t.filter(e=>r.has(e))}function VO(e,t){return t.includes(e)?BO(t):[e]}function HO(e,t){return e===t?!0:e==null||t==null?!1:e.kind===t.kind&&e.directoryPath===t.directoryPath&&e.flattenedSegmentPath===t.flattenedSegmentPath&&e.hoveredPath===t.hoveredPath}function UO(e,t){return{draggedPaths:e,target:t}}function WO(e,t){if(t.kind!==`directory`||t.directoryPath==null)return!1;for(let n of e)if(RO(n)&&(t.directoryPath===n||t.directoryPath.startsWith(n)))return!0;return!1}function GO(e,t){return t.kind===`root`||t.directoryPath==null?zO(e):t.directoryPath}function KO(e,t){let n=e.map(e=>{let n=GO(e,t);return n===e?null:{from:e,to:n,type:`move`}}).filter(e=>e!=null);return n.length===0?null:{operations:n,result:{draggedPaths:e,operation:n.length===1?`move`:`batch`,target:t}}}function qO(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let n=0;n<e.length;n+=1)if(e[n]!==t[n])return!1;return!0}function JO(e,t,n){let{paths:r,preparedInput:i}=e;if(i==null){if(r==null)throw Error(`FileTree requires paths or preparedInput`);return{paths:r,preparedInput:void 0}}let a=i.paths;if(r==null)return{paths:a,preparedInput:i};if(!qO(MO.preparePaths(r,n==null?{}:{sort:n}),a))throw Error(`FileTree ${t} received paths and preparedInput for different path lists`);return{paths:a,preparedInput:i}}function YO(e){return e.operation===`add`||e.operation===`remove`||e.operation===`move`||e.operation===`batch`}function XO(e,t,n){if(e===t)return n;let r=t.endsWith(`/`)?t:`${t}/`;return e.startsWith(r)?`${n.endsWith(`/`)?n:`${n}/`}${e.slice(r.length)}`:e}function ZO(e,t){if(e===t)return!0;let n=t.endsWith(`/`)?t:`${t}/`;return e.startsWith(n)}function QO(e,t,n=!1){if(e==null)return null;switch(t.operation){case`add`:case`expand`:case`collapse`:case`mark-directory-unloaded`:case`begin-child-load`:case`apply-child-patch`:case`complete-child-load`:case`fail-child-load`:case`cleanup`:return e;case`remove`:return ZO(e,t.path)?n?e:null:e;case`move`:return XO(e,t.from,t.to);case`batch`:{let r=e;for(let e of t.events)if(r=QO(r,e,n),r==null)return null;return r}}}function $O(e){return{canonicalChanged:e.canonicalChanged,projectionChanged:e.projectionChanged,visibleCountDelta:e.visibleCountDelta}}function ek(e){switch(e.operation){case`add`:return{...$O(e),operation:`add`,path:e.path};case`remove`:return{...$O(e),operation:`remove`,path:e.path,recursive:e.recursive};case`move`:return{...$O(e),from:e.from,operation:`move`,to:e.to}}}function tk(e){return{...$O(e),events:e.events.filter(e=>e.operation===`add`||e.operation===`remove`||e.operation===`move`).map(e=>ek(e)),operation:`batch`}}function nk(e){switch(e.operation){case`add`:case`remove`:case`move`:return ek(e);case`batch`:return tk(e);default:return null}}function rk(e,t){if(e.size!==t.length)return!1;for(let n of t)if(!e.has(n))return!1;return!0}function ik(e){let t=e.endsWith(`/`)?e.slice(0,-1):e;if(t.length===0)return[];let n=t.split(`/`);return n.slice(0,-1).map((e,t)=>`${n.slice(0,t+1).join(`/`)}/`)}function ak(e){return ik(e).at(-1)??null}function ok(e,t){return t==null?e:e.startsWith(t)?e.slice(t.length):e}function sk(e){return e.endsWith(`/`)}var ck=e=>e.toLowerCase();function lk(e){let t=e.endsWith(`/`)?e.slice(0,-1):e,n=t.lastIndexOf(`/`);return n<0?t:t.slice(n+1)}function uk(e){return e.endsWith(`/`)?e.slice(0,-1):e}function dk(e,t){return t&&!e.endsWith(`/`)?`${e}/`:e}var fk=e=>{let t=e.trim();return t.length===0?``:(t.includes(`\\`)?t.replaceAll(`\\`,`/`):t).toLowerCase()},pk=Symbol(`FILE_TREE_RENAME_VIEW`),mk=512,hk=512;function gk(e){return e===`top`||e===`center`?e:`nearest`}function _k(e,t,n){if(e===0)return-1;if(n!=null){let e=t(n);if(e!=null)return e;let r=ik(n);for(let e=r.length-1;e>=0;--e){let n=r[e];if(n==null)continue;let i=t(n);if(i!=null)return i}}return 0}function vk(e,t,n){if(e.paths.length===0)return{focusedIndex:-1,getParentIndex:e.getParentIndex,paths:e.paths,posInSetByIndex:e.posInSetByIndex,setSizeByIndex:e.setSizeByIndex};if(t==null)return{focusedIndex:0,getParentIndex:e.getParentIndex,paths:e.paths,posInSetByIndex:e.posInSetByIndex,setSizeByIndex:e.setSizeByIndex};let r=n??(t=>e.visibleIndexByPath.get(t)??null);return{focusedIndex:_k(e.paths.length,r,t),getParentIndex:e.getParentIndex,paths:e.paths,posInSetByIndex:e.posInSetByIndex,setSizeByIndex:e.setSizeByIndex}}var yk=class e{static{Object.defineProperty(e.prototype,pk,{configurable:!0,value(){return{cancel:()=>{this.#q()},commit:()=>{this.#J()},getPath:()=>this.#T,getValue:()=>this.#E,isActive:()=>this.#T!=null,setValue:e=>{this.#Y(e)}}},writable:!0})}#e;#t=new Set;#n=new Map;#r=null;#i=null;#a=new Map;#o=new Map;#s=-1;#c=null;#l=!1;#u=e=>-1;#d=new Map;#f=null;#p=null;#m=null;#h=null;#g=null;#_;#v;#y;#b=[];#x=new Int32Array;#S=new Int32Array;#C=void 0;#w=!1;#T=null;#E=``;#D=!1;#O=new Set;#k=[];#A;#j=null;#M=null;#N=null;#P=null;#F=null;#I=null;#L=null;#R=0;#z=null;#B=new Set;#V=0;#H;#U=0;#W=!1;#G=0;#K;constructor(e){let{dragAndDrop:t,fileTreeSearchMode:n,initialSearchQuery:r,initialSelectedPaths:i,renaming:a,onSearchChange:o,paths:s,preparedInput:c,...l}=e,u=JO({paths:s,preparedInput:c},`constructor`,l.sort);this.#e=l,t!=null&&t!==!1&&(this.#r=t===!0?{}:t),this.#w=a!=null&&a!==!1,a!=null&&a!==!1&&a!==!0&&(this.#C=a.canRename,this.#v=a.onError,this.#_=a.onRename),this.#y=o,this.#A=n??`hide-non-matches`,this.#H=this.#le(u.paths,u.preparedInput);let d=i?.map(e=>this.#Ne(e)).filter(e=>e!=null)??[],f=d.at(-1)??null;d.length>0&&(this.#B=new Set(d),this.#z=f,this.#V=1),this.#je(f,!1),r!=null&&this.#Te(r,!1),this.#K=this.#Re()}destroy(){this.#K?.(),this.#K=null,this.#n.clear(),this.#t.clear(),this.#d.clear(),this.#i=null,this.#he()}focusFirstItem(){this.#be().length>0&&this.#Fe(0)}focusLastItem(){this.#G<=0||(this.#Ie(),this.#Fe(this.#G-1))}focusNextItem(){this.#Ae(1)}focusParentItem(){if(this.#c==null)return;let e=ak(this.#c);if(e==null)return;let t=this.#Z(e);t>=0&&this.#Fe(t)}focusPath(e){let t=this.#H.getPathInfo(e)?.path??null;if(t==null)return;this.#Ie();let n=this.#Z(t);n>=0&&this.#Fe(n)}scrollToPath(e,t){let n=this.#H.getPathInfo(e)?.path??null;if(n==null)return;this.#Ie();let r=this.#xe(n);r<0||this.#Me(r)!=null&&(t?.focus!==!1&&this.#Fe(r,!1),this.#L={id:this.#R+=1,offset:gk(t?.offset),visibleIndex:r},this.#De())}focusMountedPathFromInput(e){let t=this.#H.getPathInfo(e)?.path??null;if(t==null)return;let n=this.#Z(t);n>=0&&this.#Fe(n)}focusNearestPath(e){let t=this.resolveNearestVisiblePath(e);if(t==null)return null;let n=this.#Z(t);return n>=0?(this.#Fe(n),this.#be()[n]??t):null}focusPreviousItem(){this.#Ae(-1)}getFocusedIndex(){return this.#s}getFocusedItem(){return this.#c==null?null:this.#Q(this.#c)}getFocusedPath(){return this.#c}getScrollRequest(){return this.#L}clearScrollRequest(e){this.#L?.id===e&&(this.#L=null)}resolveNearestVisiblePath(e){let t=this.#be();if(this.#G===0)return null;if(e==null)return this.#c??t[0]??null;let n=this.#H.getPathInfo(e)?.path??e,r=this.#Z(n);return r>=0?t[r]??n:this.#X(n)??this.#c??t[0]??null}getSelectedPaths(){return[...this.#B]}getSelectionVersion(){return this.#V}getVisibleCount(){return this.#G}getVisibleRows(e,t){if(t<e||this.#G===0)return[];let n=Math.max(0,e),r=Math.min(this.#G-1,t);if(r<n)return[];let i=r-n+1;if(this.#F==null&&!this.#l&&r>=this.#b.length&&i<=hk){let e=[];for(let t=n;t<=r;t+=1){let n=this.#H.getVisibleRowContext(t);if(n==null)break;e.push(this.#ee(n))}return e}if(!this.#l&&r>=this.#b.length&&this.#Ie(),this.#F!=null){let e=Array.from({length:r-n+1},(e,t)=>this.#Se(n+t)),t=new Map,i=e[0]??-1,a=i;for(let n=1;n<=e.length;n+=1){let r=e[n];if(r!=null&&r===a+1){a=r;continue}if(i>=0&&this.#H.getVisibleSlice(i,a).forEach((e,n)=>{t.set(i+n,e)}),r==null){i=-1,a=-1;continue}i=r,a=r}return Array.from({length:r-n+1},(e,r)=>{let i=n+r,a=this.#Se(i),o=t.get(a),s=this.#b[a];if(o==null||s==null)throw Error(`Missing projection row for filtered visible index ${String(i)}`);return this.#$(o,i,a,{ancestorPaths:this.#re(a),path:s})})}return this.#H.getVisibleSlice(n,r).map((e,t)=>{let r=n+t,i=this.#b[r];if(i==null)throw Error(`Missing projection path for visible index ${String(r)}`);return this.#$(e,r,r,{ancestorPaths:this.#re(r),path:i})})}getStickyRowCandidates(e,t){if(this.#F!=null)return null;if(this.#G===0||e<=0||t<=0)return[];let n=[];for(let r=0;r<this.#G;r+=1){let i=e+r*t,a=Math.min(this.#G-1,Math.floor(i/t)),o=this.#te(a,r)??(a>0?this.#te(a-1,r):void 0);if(o==null)break;n.push({row:this.#ee(o),subtreeEndIndex:o.subtreeEndIndex})}return n}getItem(e){let t=this.#H.getPathInfo(e);return t==null?null:this.#Q(t.path,t)}resolveMountedDirectoryPathFromInput(e){let t=this.#H.getPathInfo(e);return t?.kind===`directory`?t.path:null}toggleMountedDirectoryFromInput(e){let t=this.resolveMountedDirectoryPathFromInput(e);t!=null&&this.#ze(t)}selectAllVisiblePaths(){this.#Ie();let e=[...this.#be()];this.#ae(e,this.#c??this.#z)}selectOnlyPath(e){let t=this.#Ne(e);t!=null&&this.#ae([t],t)}selectOnlyMountedPathFromInput(e){this.#ae([e],e)}selectPath(e){let t=this.#Ne(e);t==null||this.#B.has(t)||this.#ae([...this.#B,t])}deselectPath(e){let t=this.#Ne(e);t==null||!this.#B.has(t)||this.#ae([...this.#B].filter(e=>e!==t))}toggleFocusedSelection(){this.#c!=null&&this.togglePathSelectionFromInput(this.#c)}togglePathSelection(e){let t=this.#Ne(e);if(t!=null){if(this.#B.has(t)){this.deselectPath(t);return}this.selectPath(t)}}togglePathSelectionFromInput(e){let t=this.#Ne(e);if(t!=null){if(this.#B.has(t)){this.#ae([...this.#B].filter(e=>e!==t),t);return}this.#ae([...this.#B,t],t)}}selectPathRange(e,t){let n=this.#Ne(e);if(n==null)return;this.#Ie();let r=this.#z,i=r==null?-1:this.#Ce(r),a=this.#Ce(n);if(i===-1||a===-1){let e=t?[...this.#B,n]:[n];this.#ae(e,n);return}let[o,s]=i<=a?[i,a]:[a,i],c=this.#be().slice(o,s+1),l=t?[...this.#B,...c]:c;this.#ae(l,r)}extendSelectionFromFocused(e){if(this.#c==null)return;let t=this.#s;if(t===-1)return;let n=Math.min(this.#G-1,Math.max(0,t+e));if(n===t)return;!this.#l&&n>=this.#b.length&&this.#Ie();let r=this.#be(),i=r[t]??null,a=r[n]??null;if(i==null||a==null)return;let o=new Set(this.#B);o.has(i)&&o.has(a)?o.delete(i):o.add(a),this.#ae([...o],this.#z??i,!1),this.#Fe(n)}getDragAndDropConfig(){return this.#r}isDragAndDropEnabled(){return this.#r!=null}getDragSession(){return this.#i==null?null:{draggedPaths:[...this.#i.draggedPaths],primaryPath:this.#i.primaryPath,target:this.#i.target==null?null:{...this.#i.target}}}startDrag(e){if(this.#r==null)return!1;let t=this.#Ne(e);if(t==null||this.#M!=null&&this.#M.length>0)return!1;let n=this.getSelectedPaths(),r=VO(t,n);return this.#r.canDrag?.(r)===!1?!1:(n.includes(t)||this.#ae([t],t,!1),this.#Pe(t),this.#i={draggedPaths:r,primaryPath:t,target:null},this.#De(),!0)}setDragTarget(e){let t=this.#i;if(t==null)return;let n=e;if(n!=null){let e=UO(t.draggedPaths,n);(WO(t.draggedPaths,n)||this.#r?.canDrop?.(e)===!1)&&(n=null)}HO(t.target,n)||(this.#i={...t,target:n},this.#De())}cancelDrag(){this.#i!=null&&(this.#i=null,this.#De())}completeDrag(){let e=this.#i;if(e==null)return!1;this.#i=null;let t=e.target==null?null:{...e.target};if(t==null)return this.#De(),!1;let n=UO(e.draggedPaths,t);if(WO(e.draggedPaths,t)||this.#r?.canDrop?.(n)===!1)return this.#De(),!1;let r=KO(e.draggedPaths,t);if(r==null)return this.#De(),!1;try{if(r.operations.length===1){let e=r.operations[0];if(e==null||e.type!==`move`)throw Error(`Expected a single move operation for one-item drops`);this.#H.move(e.from,e.to,{collision:e.collision})}else this.#ce(r.operations),this.#H.batch(r.operations)}catch(e){return this.#De(),this.#r?.onDropError?.(e instanceof Error?e.message:String(e),n),!1}return this.#r?.onDropComplete?.(r.result),!0}subscribe(e){return this.#t.add(e),e(),()=>{this.#t.delete(e)}}add(e){this.#H.add(e)}remove(e,t={}){this.#H.remove(e,t)}move(e,t,n={}){this.#H.move(e,t,n)}batch(e){this.#H.batch(e)}onMutation(e,t){let n=e,r=t,i=this.#n.get(n);return i??(i=new Set,this.#n.set(n,i)),i.add(r),()=>{let e=this.#n.get(n);e?.delete(r),e?.size===0&&this.#n.delete(n)}}setSearch(e){this.#Te(e,!0)}openSearch(e=``){this.#Te(e,!0)}closeSearch(){this.#Te(null,!0)}isSearchOpen(){return this.#M!==null}getSearchValue(){return this.#M??``}getSearchMatchingPaths(){return this.#k}focusNextSearchMatch(){this.#we(1)}focusPreviousSearchMatch(){this.#we(-1)}startRenaming(e=this.#c??``,t={}){if(!this.#w)return!1;let n=this.#H.getPathInfo(e);if(n==null)return!1;let r=n.path,i=sk(r),a=uk(r);if(this.#C?.({isFolder:i,path:a})===!1)return!1;for(let e of ik(r))this.#H.isExpanded(e)||this.#H.expand(e);return this.#ae([r],r,!1),this.#M!=null&&(this.#Te(null,!1),this.#y?.(this.#M)),this.#Pe(r),this.#T=r,this.#E=lk(r),this.#D=t.removeIfCanceled??!1,this.#De(),!0}#q(){if(this.#T==null)return;let e=this.#T,t=this.#D;if(this.#T=null,this.#E=``,this.#D=!1,t){this.remove(e,sk(e)?{recursive:!0}:void 0);return}this.#Pe(e),this.#De()}#J(){let e=this.#T;if(e==null)return;if(this.#D&&this.#E.trim().length===0){this.#T=null,this.#E=``,this.#D=!1,this.remove(e,sk(e)?{recursive:!0}:void 0);return}let t=sk(e),n=LO({files:this.#H.list(),isFolder:t,nextBasename:this.#E,path:uk(e)});if(this.#T=null,this.#E=``,this.#D=!1,`error`in n){this.#Pe(e),this.#v?.(n.error),this.#De();return}if(n.sourcePath===n.destinationPath){this.#Pe(e),this.#De();return}this.#_?.({destinationPath:n.destinationPath,isFolder:n.isFolder,sourcePath:n.sourcePath}),this.move(dk(n.sourcePath,t),dk(n.destinationPath,t))}#Y(e){this.#T==null||this.#E===e||(this.#E=e,this.#De())}resetPaths(e,t={}){let n=!Array.isArray(e),r=n?void 0:e,i=n?e:t,a=this.#H.list().length,o=this.#G,s=JO({paths:r,preparedInput:i.preparedInput},`resetPaths`,this.#e.sort),c=this.#le(s.paths,s.preparedInput,i.initialExpandedPaths),l=this.#c,u=this.#T,d=this.getSelectedPaths(),f=this.#z;this.#K?.(),this.#H=c,this.#d.clear(),this.#he();let p=d.map(e=>c.getPathInfo(e)?.path??null).filter(e=>e!=null),m=!rk(this.#B,p);this.#B=new Set(p),m&&(this.#V+=1),this.#z=f==null?null:c.getPathInfo(f)?.path??null,this.#T=u==null?null:c.getPathInfo(u)?.path??null,this.#T??(this.#E=``,this.#D=!1),this.#je(l,l!=null||p.length>0||this.#z!=null),this.#K=this.#Re(),this.#De(),this.#Oe({canonicalChanged:!0,operation:`reset`,pathCountAfter:s.paths.length,pathCountBefore:a,projectionChanged:!0,usedPreparedInput:i.preparedInput!=null,visibleCountDelta:this.#G-o})}#X(e){this.#Ie();let t=ak(e),n=ok(e,t),r=null,i=null;for(let e of this.#be()){if(ak(e)!==t)continue;let a=ok(e,t);if(a<n){r=e;continue}if(a>n){i=e;break}}return r??i}#Z(e){let t=this.#Ce(e);if(t!==-1)return t;let n=ik(e);for(let e=n.length-1;e>=0;--e){let t=n[e];if(t==null)continue;let r=this.#Ce(t);if(r!==-1)return r}return this.#be().length>0?0:-1}#Q(e,t){let n=this.#d.get(e);if(n!=null)return n;let r=t??this.#H.getPathInfo(e);if(r==null)return null;let i=r.kind===`directory`?this.#oe(r.path):this.#se(r.path);return this.#d.set(r.path,i),i}#$(e,t,n,r){return{ancestorPaths:r.ancestorPaths,depth:e.depth,flattenedSegments:e.flattenedSegments?.map(e=>({isTerminal:e.isTerminal,name:e.name,path:e.path})),hasChildren:e.hasChildren,index:t,isExpanded:e.isExpanded,isFlattened:e.isFlattened,isFocused:r.path===this.#c,isSelected:this.#B.has(r.path),kind:e.kind,level:e.depth,name:e.name,path:r.path,posInSet:r.posInSet??this.#x[n]??0,setSize:r.setSize??this.#S[n]??0}}#ee(e){return this.#$(e.row,e.index,e.index,{ancestorPaths:e.ancestorPaths,path:e.row.path,posInSet:e.posInSet,setSize:e.setSize})}#te(e,t){let n=this.#H.getVisibleRowContext(e);return n==null?void 0:n.ancestorRows[t]??(t===n.ancestorRows.length&&n.row.kind===`directory`&&n.row.isExpanded?n:void 0)}#ne(e){let t=this.#a.get(e);if(t!=null)return t;let n=this.#u(e),r=n<0?[]:[...this.#ne(n),n];return this.#a.set(e,r),r}#re(e){let t=this.#o.get(e);if(t!=null)return t;let n=this.#ne(e).map(e=>this.#b[e]??``).filter(e=>e!==``);return this.#o.set(e,n),n}#ie(e){this.#H.collapse(e)}#ae(e,t=this.#z,n=!0){let r=[...new Set(e)],i=!rk(this.#B,r),a=this.#z!==t;!i&&!a||(this.#B=new Set(r),this.#z=t,i&&(this.#V+=1),n&&this.#De())}#oe(e){return{collapse:()=>{this.#ie(e)},deselect:()=>{this.deselectPath(e)},expand:()=>{this.#ke(e)},focus:()=>{this.focusPath(e)},getPath:()=>e,isDirectory:()=>!0,isExpanded:()=>this.#H.isExpanded(e),isFocused:()=>this.#c===e,isSelected:()=>this.#B.has(e),select:()=>{this.selectPath(e)},toggleSelect:()=>{this.togglePathSelection(e)},toggle:()=>{this.#ze(e)}}}#se(e){return{deselect:()=>{this.deselectPath(e)},focus:()=>{this.focusPath(e)},getPath:()=>e,isDirectory:()=>!1,isFocused:()=>this.#c===e,isSelected:()=>this.#B.has(e),select:()=>{this.selectPath(e)},toggleSelect:()=>{this.togglePathSelection(e)}}}#ce(e){let t=this.#H.list();this.#le(t).batch(e)}#le(e,t,n){return new MO({...this.#e,paths:e,preparedInput:t??void 0,...n===void 0?{}:{initialExpandedPaths:n}})}#ue(){return this.#h??=this.#H.list(),this.#h}#de(){if(this.#m!=null)return this.#m;let e=new Set;for(let t of this.#ue()){e.add(t);for(let n of ik(t))e.add(n)}return this.#m=[...e].sort(),this.#m}#fe(){return this.#g??=this.#ue().map(ck),this.#g}#pe(){return this.#f??=this.#de().filter(e=>e.endsWith(`/`)),this.#f}#me(){return this.#p??=this.#pe().map(ck),this.#p}#he(){this.#f=null,this.#p=null,this.#m=null,this.#h=null,this.#g=null}#ge(){return this.#pe().filter(e=>this.#H.isExpanded(e))}#_e(e){let t=new Set(this.#j??[]);if(e)for(let e of this.#B)for(let n of ik(e))t.add(n);this.#ve(t)}#ve(e){this.#W=!0;try{for(let t of this.#pe()){let n=e.has(t),r=this.#H.isExpanded(t);n&&!r?this.#H.expand(t):!n&&r&&this.#H.collapse(t)}}finally{this.#W=!1}}#ye(){if(this.#M==null||this.#M.length===0){this.#k=[],this.#F=null,this.#I=null,this.#P=null,this.#G=this.#U;return}let e=this.#b;if(this.#k=e.filter(e=>this.#O.has(e)),this.#A!==`hide-non-matches`||this.#O.size===0){this.#F=null,this.#I=null,this.#P=null,this.#G=this.#U;return}let t=[],n=[],r=new Map;for(let[i,a]of e.entries())this.#N?.has(a)===!0&&(r.set(a,n.length),t.push(i),n.push(a));this.#F=t,this.#I=n,this.#P=r,this.#G=n.length}#be(){return this.#I??this.#b}#xe(e){return this.#I==null?this.#H.getVisibleIndex(e)??-1:this.#P?.get(e)??-1}#Se(e){return this.#F?.[e]??e}#Ce(e){return this.#P?.get(e)??this.#H.getVisibleIndex(e)??-1}#we(e){let t=this.#k;if(t.length===0)return;let n=this.#c,r=n==null?-1:t.indexOf(n),i=t[r<0?e>0?0:t.length-1:Math.min(t.length-1,Math.max(0,r+e))];i!=null&&this.focusPath(i)}#Te(e,t){let n=e==null?null:fk(e),r=this.#M;if(r!==n){if(r==null&&n!=null&&(this.#j=this.#ge()),this.#M=n,n==null)this.#_e(!0),this.#j=null,this.#O.clear(),this.#N=null,this.#je(this.#c,!0);else if(n.length===0)this.#_e(!1),this.#O.clear(),this.#N=null,this.#je(this.#c,!0);else{let e=this.#Ee();this.#je(e,!0)}t&&(this.#y?.(this.#M),this.#De())}}#Ee(){if(this.#M==null||this.#M.length===0)return this.#O.clear(),this.#c;let e=this.#M,t=this.#ue(),n=this.#fe(),r=[],i=new Set,a=null;for(let o=0;o<t.length;o+=1){if(!n[o].includes(e))continue;let s=t[o];r.push(s),i.add(s),a??=s}let o=this.#pe(),s=this.#me();for(let t=0;t<o.length;t+=1){if(!s[t].includes(e))continue;let n=o[t];i.has(n)||(r.push(n),i.add(n),a??=n)}this.#O=i;let c=this.#A===`hide-non-matches`&&r.length>0?new Set:null;this.#N=c;let l=this.#A===`expand-matches`?new Set(this.#j??[]):new Set;for(let e of r){c?.add(e),e.endsWith(`/`)&&l.add(e);for(let t of ik(e))l.add(t),c?.add(t)}return this.#ve(l),a??this.#c}#De(){for(let e of this.#t)e()}#Oe(e){this.#n.get(e.operation)?.forEach(t=>{t(e)}),this.#n.get(`*`)?.forEach(t=>{t(e)})}#ke(e){for(let t of ik(e))this.#H.isExpanded(t)||this.#H.expand(t);this.#H.isExpanded(e)||this.#H.expand(e)}#Ae(e){let t=this.#G;if(t===0)return;let n=this.#s===-1?0:this.#s,r=Math.min(t-1,Math.max(0,n+e));(r!==n||this.#s===-1)&&(!this.#l&&this.#F==null&&r>=this.#b.length&&this.#Ie(),this.#Fe(r))}#je(e,t=!0){let n=this.#H.getVisibleCount();this.#U=n;let r=vk(this.#H.getVisibleTreeProjectionData(t?void 0:Math.min(n,mk)),e,t?e=>this.#H.getVisibleIndex(e):void 0);this.#a.clear(),this.#o.clear(),this.#l=r.paths.length>=n,this.#u=r.getParentIndex,this.#b=r.paths,this.#x=r.posInSetByIndex,this.#S=r.setSizeByIndex,this.#ye(),this.#s=e==null?this.#be().length>0?0:-1:this.#Z(e),this.#c=this.#s<0?null:this.#Me(this.#s)}#Me(e){return this.#be()[e]??(this.#F==null?this.#H.getVisibleRowContext(e)?.row.path??null:null)}#Ne(e){return this.#H.getPathInfo(e)?.path??null}#Pe(e){if(e==null)return;let t=this.#Z(e);t>=0&&this.#Fe(t,!1)}#Fe(e,t=!0){let n=this.#Me(e);n!=null&&(this.#s===e&&this.#c===n||(this.#s=e,this.#c=n,t&&this.#De()))}#Ie(){this.#l||this.#je(this.#c,!0)}#Le(e){let t=QO(this.#T,e);t==null&&this.#T!=null&&(this.#E=``),this.#T=t;let n=QO(this.#c,e,!0),r=[...this.#B].map(t=>QO(t,e)).filter(e=>e!=null).map(e=>this.#H.getPathInfo(e)?.path??null).filter(e=>e!=null),i=QO(this.#z,e),a=i==null?null:this.#H.getPathInfo(i)?.path??null,o=[...new Set(r)];return rk(this.#B,o)||(this.#B=new Set(o),this.#V+=1),this.#z=a,n}#Re(){return this.#H.on(`*`,e=>{if(this.#W)return;e.canonicalChanged&&(this.#d.clear(),this.#he()),this.#i!=null&&YO(e)&&(this.#i=null);let t=YO(e)?this.#Le(e):this.#c,n=this.#M!=null&&this.#M.length>0?this.#Ee():this.#M===``?this.#c:t,r=this.#M!=null||e.operation!==`expand`&&e.operation!==`collapse`;this.#je(n,r),this.#De();let i=nk(e);i!=null&&this.#Oe(i)})}#ze(e){if(this.#H.isExpanded(e)){this.#ie(e);return}this.#ke(e)}},bk=e=>{if(e==null||e.length===0)return`0`;let t=`${e.length}`;for(let n of e)t+=`\0${n.path}\0${n.status}`;return t};function xk(e){let t=e.endsWith(`/`),n=``,r=-1;for(let t=0;t<=e.length;t+=1){if(!(e[t]===`/`||t===e.length)){r===-1&&(r=t);continue}r!==-1&&(n!==``&&(n+=`/`),n+=e.slice(r,t),r=-1)}return n===``?null:{isDirectory:t,path:n}}function Sk(e){let t=e.endsWith(`/`)?e.slice(0,-1):e;if(t.length===0)return[];let n=[],r=0;for(;;){let e=t.indexOf(`/`,r);if(e===-1)break;n.push(t.slice(0,e+1)),r=e+1}return n}function Ck(e,t){return t?`${e}/`:e}function wk(e,t=null){let n=bk(e==null?void 0:[...e]);if(n===`0`)return null;if(t?.signature===n)return t;let r=new Map,i=new Set,a=new Set,o=new Map;for(let t of e??[]){let e=Ek(t);e!=null&&kk({canonicalPath:e.canonicalPath,changeCountByDirectoryPath:o,directoriesWithChanges:i,ignoredDirectoryPaths:a,isDirectory:e.isDirectory,status:t.status,statusByPath:r})}return r.size===0?null:{changeCountByDirectoryPath:o,directoriesWithChanges:i,ignoredDirectoryPaths:a,signature:n,statusByPath:r}}function Tk(e,t){let n=t?.remove??[],r=t?.set??[];if(n.length===0&&r.length===0)return e;let i=new Map(e?.statusByPath),a=new Set(e?.directoriesWithChanges),o=new Set(e?.ignoredDirectoryPaths),s=new Map(e?.changeCountByDirectoryPath),c=!1;for(let e of n){let t=Dk(e);t!=null&&(c=Ok({canonicalPath:t.canonicalPath,changeCountByDirectoryPath:s,directoriesWithChanges:a,ignoredDirectoryPaths:o,statusByPath:i})||c)}for(let e of r){let t=Ek(e);t!=null&&(c=kk({canonicalPath:t.canonicalPath,changeCountByDirectoryPath:s,directoriesWithChanges:a,ignoredDirectoryPaths:o,isDirectory:t.isDirectory,status:e.status,statusByPath:i})||c)}return c?i.size===0?null:{changeCountByDirectoryPath:s,directoriesWithChanges:a,ignoredDirectoryPaths:o,signature:Mk(i),statusByPath:i}:e}function Ek(e){return Dk(e.path)}function Dk(e){let t=xk(e);if(t!=null)return{canonicalPath:Ck(t.path,t.isDirectory),isDirectory:t.isDirectory}}function Ok({canonicalPath:e,changeCountByDirectoryPath:t,directoriesWithChanges:n,ignoredDirectoryPaths:r,statusByPath:i}){let a=i.get(e);return a==null?!1:(i.delete(e),a===`ignored`&&e.endsWith(`/`)&&r.delete(e),jk(t,n,e),!0)}function kk({canonicalPath:e,changeCountByDirectoryPath:t,directoriesWithChanges:n,ignoredDirectoryPaths:r,isDirectory:i,status:a,statusByPath:o}){let s=o.get(e);return s===a?!1:(s??Ak(t,n,e),o.set(e,a),a===`ignored`&&i?r.add(e):i&&r.delete(e),!0)}function Ak(e,t,n){for(let r of Sk(n))e.set(r,(e.get(r)??0)+1),t.add(r)}function jk(e,t,n){for(let r of Sk(n)){let n=(e.get(r)??0)-1;n>0?e.set(r,n):(e.delete(r),t.delete(r))}}function Mk(e){let t=`${e.size}`;for(let[n,r]of e)t+=`\0${n}\0${r}`;return t}var Nk=e=>e.trim().toLowerCase(),Pk=e=>e.split(`/`).at(-1)??e,Fk=e=>{let t=e.toLowerCase().split(`.`),n=[];for(let e=1;e<t.length;e+=1)n.push(t.slice(e).join(`.`));return n};function Ik(e,t){return typeof e==`string`?{name:e,remappedFrom:t}:{...e,remappedFrom:t}}function Lk(e){let t=Uw(e),n=t.remap,r=new Map;for(let[e,n]of Object.entries(t.byFileName??{}))r.set(e.toLowerCase(),n);let i=new Map;for(let[e,n]of Object.entries(t.byFileExtension??{}))i.set(Nk(e),n);let a=Object.entries(t.byFileNameContains??{}).map(([e,t])=>[e.toLowerCase(),t]);return{resolveIcon:(e,o)=>{if(e===`file-tree-icon-file`&&o!=null){let s=Pk(o),c=s.toLowerCase(),l=r.get(c);if(l!=null)return Ik(l,e);for(let[t,n]of a)if(c.includes(t))return Ik(n,e);let u=Fk(s);for(let t of u){let n=i.get(t);if(n!=null)return Ik(n,e)}let d=Mw(t.set,s,u);if(d!=null&&t.set!==`none`){if(d==="default"){let t=n?.[e];if(t!=null)return Ik(t,e)}return{name:Aw(d),remappedFrom:e,token:d}}}let s=n?.[e];return s==null?{name:e}:Ik(s,e)}}}var Rk,zk,Bk,Vk,Hk,Uk,Wk,Gk,Kk,qk,Jk={},Yk=[],Xk=Array.isArray,Zk=Yk.slice,Qk=Object.assign;function $k(e){e&&e.parentNode&&e.remove()}function eA(e,t,n){var r,i,a,o={};for(a in t)a==`key`?r=t[a]:a==`ref`&&typeof e!=`function`?i=t[a]:o[a]=t[a];return arguments.length>2&&(o.children=arguments.length>3?Zk.call(arguments,2):n),tA(e,o,r,i,null)}function tA(e,t,n,r,i){var a={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:i??++zk,__i:-1,__u:0};return i==null&&Rk.vnode!=null&&Rk.vnode(a),a}function nA(e){return e.children}function rA(e,t){this.props=e,this.context=t,this.__g=0}function iA(e,t){if(t==null)return e.__?iA(e.__,e.__i+1):null;for(var n;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null)return n.__e;return typeof e.type==`function`?iA(e):null}function aA(e){var t,n;if((e=e.__)!=null&&e.__c!=null){for(e.__e=null,t=0;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null){e.__e=n.__e;break}return aA(e)}}function oA(e){(8&e.__g||!(e.__g|=8)||!Bk.push(e)||Hk++)&&Vk==Rk.debounceRendering||((Vk=Rk.debounceRendering)||queueMicrotask)(sA)}function sA(){for(var e,t,n,r,i,a,o,s,c=1;Bk.length;)Bk.length>c&&Bk.sort(Uk),e=Bk.shift(),c=Bk.length,8&e.__g&&(n=void 0,i=(r=(t=e).__v).__e,a=[],o=[],(s=t.__P)&&((n=Qk({},r)).__v=r.__v+1,Rk.vnode&&Rk.vnode(n),hA(s,n,r,t.__n,s.namespaceURI,32&r.__u?[i]:null,a,i??iA(r),!!(32&r.__u),o,s.ownerDocument),n.__v=r.__v,n.__.__k[n.__i]=n,_A(a,n,o),n.__e!=i&&aA(n)));Hk=0}function cA(e,t,n,r,i,a,o,s,c,l,u,d){var f,p,m,h,g,_,v,y=r&&r.__k||Yk,b=t.length;for(c=lA(n,t,y,c,b),f=0;f<b;f++)(m=n.__k[f])!=null&&(p=m.__i==-1?Jk:y[m.__i]||Jk,m.__i=f,_=hA(e,m,p,i,a,o,s,c,l,u,d),h=m.__e,m.ref&&p.ref!=m.ref&&(p.ref&&bA(p.ref,null,m),u.push(m.ref,m.__c||h,m)),g==null&&h!=null&&(g=h),(v=!!(4&m.__u))||p.__k===m.__k?c=uA(m,c,e,v):typeof m.type==`function`&&_!==void 0?c=_:h&&(c=h.nextSibling),m.__u&=-7);return n.__e=g,c}function lA(e,t,n,r,i){var a,o,s,c,l,u=n.length,d=u,f=0;for(e.__k=Array(i),a=0;a<i;a++)(o=t[a])!=null&&typeof o!=`boolean`&&typeof o!=`function`?(c=a+f,(o=e.__k[a]=typeof o==`string`||typeof o==`number`||typeof o==`bigint`||o.constructor==String?tA(null,o,null,null,null):Xk(o)?tA(nA,{children:o},null,null,null):o.constructor==null&&o.__b>0?tA(o.type,o.props,o.key,o.ref?o.ref:null,o.__v):o).__=e,o.__b=e.__b+1,s=null,(l=o.__i=dA(o,n,c,d))!=-1&&(d--,(s=n[l])&&(s.__u|=2)),s==null||s.__v==null?(l==-1&&(i>u?f--:i<u&&f++),typeof o.type!=`function`&&(o.__u|=4)):l!=c&&(l==c-1?f--:l==c+1?f++:(l>c?f--:f++,o.__u|=4))):e.__k[a]=null;if(d)for(a=0;a<u;a++)(s=n[a])!=null&&!(2&s.__u)&&(s.__e==r&&(r=iA(s)),xA(s,s));return r}function uA(e,t,n,r){var i,a;if(typeof e.type==`function`){for(i=e.__k,a=0;i&&a<i.length;a++)i[a]&&(i[a].__=e,t=uA(i[a],t,n,r));return t}e.__e!=t&&(r&&(t&&e.type&&!t.parentNode&&(t=iA(e)),n.insertBefore(e.__e,t||null)),t=e.__e);do t&&=t.nextSibling;while(t!=null&&t.nodeType==8);return t}function dA(e,t,n,r){var i,a,o,s=e.key,c=e.type,l=t[n],u=l!=null&&(2&l.__u)==0;if(l===null&&e.key==null||u&&s==l.key&&c==l.type)return n;if(r>+!!u){for(i=n-1,a=n+1;i>=0||a<t.length;)if((l=t[o=i>=0?i--:a++])!=null&&!(2&l.__u)&&s==l.key&&c==l.type)return o}return-1}function fA(e,t,n){t[0]==`-`?e.setProperty(t,n??``):e[t]=n??``}function pA(e,t,n,r,i){var a;n:if(t==`style`)if(typeof n==`string`)e.style.cssText=n;else{if(typeof r==`string`&&(e.style.cssText=r=``),r)for(t in r)n&&t in n||fA(e.style,t,``);if(n)for(t in n)r&&n[t]==r[t]||fA(e.style,t,n[t])}else if(t[0]==`o`&&t[1]==`n`)a=t!=(t=t.replace(Wk,`$1`)),(t=t.slice(2))[0].toLowerCase()!=t[0]&&(t=t.toLowerCase()),e.__l||={},e.__l[t+a]=n,n?r?n.l=r.l:(n.l=Gk,e.addEventListener(t,a?qk:Kk,a)):e.removeEventListener(t,a?qk:Kk,a);else{if(i==`http://www.w3.org/2000/svg`)t=t.replace(/xlink(H|:h)/,`h`).replace(/sName$/,`s`);else if(t!=`width`&&t!=`height`&&t!=`href`&&t!=`list`&&t!=`form`&&t!=`tabIndex`&&t!=`download`&&t!=`rowSpan`&&t!=`colSpan`&&t!=`role`&&t!=`popover`&&t in e)try{e[t]=n??``;break n}catch{}typeof n==`function`||(n==null||!1===n&&t[4]!=`-`?e.removeAttribute(t):e.setAttribute(t,t==`popover`&&n==1?``:n))}}function mA(e){return function(t){if(this.__l){var n=this.__l[t.type+e];if(t.u==null)t.u=Gk++;else if(t.u<n.l)return;return n(Rk.event?Rk.event(t):t)}}}function hA(e,t,n,r,i,a,o,s,c,l,u){var d,f,p,m,h,g,_,v,y,b,x,S,C,w,T,E,D,O,ee,k,A,j=t.type;if(t.constructor!=null)return null;128&n.__u&&(c=!!(32&n.__u),n.__c.__z&&(s=t.__e=n.__e=(a=n.__c.__z)[0],n.__c.__z=null)),(d=Rk.__b)&&d(t);n:if(typeof j==`function`)try{if(v=t.props,y=`prototype`in j&&j.prototype.render,b=(d=j.contextType)&&r[d.__c],x=d?b?b.props.value:d.__:r,n.__c?2&(f=t.__c=n.__c).__g&&(f.__g|=1,_=!0):(y?t.__c=f=new j(v,x):(t.__c=f=new rA(v,x),f.constructor=j,f.render=SA),b&&b.sub(f),f.props=v,f.state||={},f.context=x,f.__n=r,p=!0,f.__g|=8,f.__h=[],f._sb=[]),y&&f.__s==null&&(f.__s=f.state),y&&j.getDerivedStateFromProps!=null&&(f.__s==f.state&&(f.__s=Qk({},f.__s)),Qk(f.__s,j.getDerivedStateFromProps(v,f.__s))),m=f.props,h=f.state,f.__v=t,p)y&&j.getDerivedStateFromProps==null&&f.componentWillMount!=null&&f.componentWillMount(),y&&f.componentDidMount!=null&&f.__h.push(f.componentDidMount);else{if(y&&j.getDerivedStateFromProps==null&&v!==m&&f.componentWillReceiveProps!=null&&f.componentWillReceiveProps(v,x),!(4&f.__g)&&f.shouldComponentUpdate!=null&&!1===f.shouldComponentUpdate(v,f.__s,x)||t.__v==n.__v){for(t.__v!=n.__v&&(f.props=v,f.state=f.__s,f.__g&=-9),t.__e=n.__e,t.__k=n.__k,t.__k.some(function(e){e&&(e.__=t)}),S=0;S<f._sb.length;S++)f.__h.push(f._sb[S]);f._sb=[],f.__h.length&&o.push(f);break n}f.componentWillUpdate!=null&&f.componentWillUpdate(v,f.__s,x),y&&f.componentDidUpdate!=null&&f.__h.push(function(){f.componentDidUpdate(m,h,g)})}if(f.context=x,f.props=v,f.__P=e,f.__g&=-5,C=Rk.__r,w=0,y){for(f.state=f.__s,f.__g&=-9,C&&C(t),d=f.render(f.props,f.state,f.context),T=0;T<f._sb.length;T++)f.__h.push(f._sb[T]);f._sb=[]}else do f.__g&=-9,C&&C(t),d=f.render(f.props,f.state,f.context),f.state=f.__s;while(8&f.__g&&++w<25);f.state=f.__s,f.getChildContext!=null&&(r=Qk({},r,f.getChildContext())),y&&!p&&f.getSnapshotBeforeUpdate!=null&&(g=f.getSnapshotBeforeUpdate(m,h)),E=d,d!=null&&d.type===nA&&d.key==null&&(E=vA(d.props.children)),s=cA(e,Xk(E)?E:[E],t,n,r,i,a,o,s,c,l,u),t.__u&=-161,f.__h.length&&o.push(f),_&&(f.__g&=-4)}catch(e){if(t.__v=null,c||a!=null)if(e.then){for(D=0,O=!1,t.__u|=c?160:128,t.__c.__z=[],ee=0;ee<a.length;ee++)(k=a[ee])==null||O||(k.nodeType==8&&k.data==`$s`?(D>0&&t.__c.__z.push(k),D++,a[ee]=null):k.nodeType==8&&k.data==`/$s`?(--D>0&&t.__c.__z.push(k),O=D===0,s=a[ee],a[ee]=null):D>0&&(t.__c.__z.push(k),a[ee]=null));if(!O){for(;s&&s.nodeType==8&&s.nextSibling;)s=s.nextSibling;a[a.indexOf(s)]=null,t.__c.__z=[s]}t.__e=s}else{for(A=a.length;A--;)$k(a[A]);gA(t)}else t.__e=n.__e,t.__k=n.__k,e.then||gA(t);Rk.__e(e,t,n)}else s=t.__e=yA(n.__e,t,n,r,i,a,o,c,l,u);return(d=Rk.diffed)&&d(t),128&t.__u?void 0:s}function gA(e){e&&e.__c&&(e.__c.__g|=4),e&&e.__k&&e.__k.forEach(gA)}function _A(e,t,n){for(var r=0;r<n.length;r++)bA(n[r],n[++r],n[++r]);Rk.__c&&Rk.__c(t,e),e.some(function(t){try{e=t.__h,t.__h=[],e.some(function(e){e.call(t)})}catch(e){Rk.__e(e,t.__v)}})}function vA(e){return typeof e!=`object`||!e||e.__b&&e.__b>0?e:Xk(e)?e.map(vA):Qk({},e)}function yA(e,t,n,r,i,a,o,s,c,l){var u,d,f,p,m,h,g,_,v=n.props,y=t.props,b=t.type;if(b==`svg`?i=`http://www.w3.org/2000/svg`:b==`math`?i=`http://www.w3.org/1998/Math/MathML`:i||=`http://www.w3.org/1999/xhtml`,a!=null){for(u=0;u<a.length;u++)if((m=a[u])&&`setAttribute`in m==!!b&&(b?m.localName==b:m.nodeType==3)){e=m,a[u]=null;break}}if(e==null){if(b==null)return l.createTextNode(y);e=l.createElementNS(i,b,y.is&&y),s&&=(Rk.__m&&Rk.__m(t,a),!1),a=null}if(b==null)v===y||s&&e.data==y||(e.data=y);else{if(a&&=Zk.call(e.childNodes),v=n.props||Jk,!s&&a!=null)for(v={},u=0;u<e.attributes.length;u++)v[(m=e.attributes[u]).name]=m.value;for(u in v)if(m=v[u],u!=`children`){if(u==`dangerouslySetInnerHTML`)f=m;else if(!(u in y)){if(u==`value`&&`defaultValue`in y||u==`checked`&&`defaultChecked`in y)continue;pA(e,u,null,m,i)}}for(u in _=1&n.__u,y)m=y[u],u==`children`?p=m:u==`dangerouslySetInnerHTML`?d=m:u==`value`?h=m:u==`checked`?g=m:s&&typeof m!=`function`||v[u]===m&&!_||pA(e,u,m,v[u],i);if(d)s||f&&(d.__html==f.__html||d.__html==e.innerHTML)||(e.innerHTML=d.__html),t.__k=[];else if(f&&(e.innerHTML=``),cA(b==`template`?e.content:e,Xk(p)?p:[p],t,n,r,b==`foreignObject`?`http://www.w3.org/1999/xhtml`:i,a,o,a?a[0]:n.__k&&iA(n,0),s,c,l),a!=null)for(u=a.length;u--;)$k(a[u]);s||(u=`value`,b==`progress`&&h==null?e.removeAttribute(`value`):h==null||h===e[u]&&(b!==`progress`||h)||pA(e,u,h,v[u],i),u=`checked`,g!=null&&g!=e[u]&&pA(e,u,g,v[u],i))}return e}function bA(e,t,n){try{if(typeof e==`function`){var r=typeof e.__u==`function`;r&&e.__u(),r&&t==null||(e.__u=e(t))}else e.current=t}catch(e){Rk.__e(e,n)}}function xA(e,t,n){var r,i;if(Rk.unmount&&Rk.unmount(e),(r=e.ref)&&(r.current&&r.current!=e.__e||bA(r,null,t)),(r=e.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(e){Rk.__e(e,t)}r.__P=null}if(r=e.__k)for(i=0;i<r.length;i++)r[i]&&xA(r[i],t,n||typeof e.type!=`function`);n||$k(e.__e),e.__e&&e.__e.__l&&(e.__e.__l=null),e.__e=e.__c=e.__=null}function SA(e,t,n){return this.constructor(e,n)}function CA(e,t){var n,r,i,a;t==document&&(t=document.documentElement),Rk.__&&Rk.__(e,t),r=(n=!!(e&&32&e.__u))?null:t.__k,e=t.__k=eA(nA,null,[e]),i=[],a=[],hA(t,e,r||Jk,Jk,t.namespaceURI,r?null:t.firstChild?Zk.call(t.childNodes):null,i,r?r.__e:t.firstChild,n,a,t.ownerDocument),_A(i,e,a)}function wA(e,t){e.__u|=32,CA(e,t)}Rk={__e:function(e,t,n,r){for(var i,a,o;t=t.__;)if((i=t.__c)&&!(1&i.__g)){i.__g|=4;try{if((a=i.constructor)&&a.getDerivedStateFromError!=null&&(i.setState(a.getDerivedStateFromError(e)),o=8&i.__g),i.componentDidCatch!=null&&(i.componentDidCatch(e,r||{}),o=8&i.__g),o)return void(i.__g|=2)}catch(t){e=t}}throw Hk=0,e}},zk=0,rA.prototype.setState=function(e,t){var n=this.__s!=null&&this.__s!=this.state?this.__s:this.__s=Qk({},this.state);typeof e==`function`&&(e=e(Qk({},n),this.props)),e&&Qk(n,e),e!=null&&this.__v&&(t&&this._sb.push(t),oA(this))},rA.prototype.forceUpdate=function(e){this.__v&&(this.__g|=4,e&&this.__h.push(e),oA(this))},rA.prototype.render=nA,Bk=[],Hk=0,Uk=function(e,t){return e.__v.__b-t.__v.__b},Wk=/(PointerCapture)$|Capture$/i,Gk=0,Kk=mA(!1),qk=mA(!0);var TA=0;Array.isArray;function $(e,t,n,r,i,a){t||={};var o,s,c=t;if(`ref`in c&&typeof e!=`function`)for(s in c={},t)s==`ref`?o=t[s]:c[s]=t[s];var l={type:e,props:c,key:n,ref:o,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:--TA,__i:-1,__u:0,__source:i,__self:a};return Rk.vnode&&Rk.vnode(l),l}var EA=16,DA=16,OA={};function kA({name:e,remappedFrom:t,token:n,width:r,height:i,viewBox:a,label:o,alignCapitals:s=!1}){"use no memo";let c=`#${e.replace(/^#/,``)}`,{width:l,height:u,viewBox:d}=OA[e]??{width:EA,height:DA},f=r??l,p=i??u,m=a??d??`0 0 ${l} ${u}`;return $(`svg`,{"data-icon-name":t??e,"data-icon-token":n,"data-align-capitals":s,...o==null?{"aria-hidden":!0}:{"aria-label":o,role:`img`},viewBox:m,width:f,height:p,children:$(`use`,{href:c})})}var AA=e=>e!==void 0&&/\s/.test(e),jA=(e,t)=>{let n=t=>AA(e[t-1])||AA(e[t]);if(!n(t))return t;for(let r=1;r<e.length;r++){let i=t-r;if(i>0&&!n(i))return i;let a=t+r;if(a<e.length&&!n(a))return a}return t},MA=e=>jA(e,Math.ceil(e.length/2)),NA=e=>{if(e.length<2)return[e,``];let t=MA(e);return[e.slice(0,t),e.slice(t)]},PA=e=>{if(e.length<4)return[e,``];let t=e.lastIndexOf(`.`)+1,n=e.length-t>10,r=t>=1&&!n?t:MA(e);return[e.slice(0,r),e.slice(r)]},FA=e=>{if(e.length<4)return[e,``];let t=e.lastIndexOf(`/`)+1,n=e.length-t>25,r=t>=1&&!n?t:Math.ceil(e.length/2);return[e.slice(0,r),e.slice(r)]},IA=(e,{splitIndex:t}={})=>{if(typeof t!=`number`){let t=Math.ceil(e.length/2);return[e.slice(0,t),e.slice(t)]}return[e.slice(0,t),e.slice(t)]},LA=(e,{splitOffset:t}={})=>{if(typeof t!=`number`||t<=0||t>=e.length){let t=Math.ceil(e.length/2);return[e.slice(0,t),e.slice(t)]}let n=e.length-t;return[e.slice(0,n),e.slice(n)]},RA=(e,{splitOffset:t}={})=>{if(typeof t!=`number`||t<=0||t>=e.length){let t=Math.ceil(e.length/2);return[e.slice(0,t),e.slice(t)]}let n=t;return[e.slice(0,n),e.slice(n)]};function zA({children:e,marker:t,variant:n=`default`}){"use no memo";return $(`div`,{"aria-hidden":!0,"data-truncate-marker-cell":!0,children:$(`div`,{"data-truncate-marker":!0,children:typeof t==`function`?t({children:e}):n===`fade`?$(`span`,{"data-truncate-fade":!0}):t})})}function BA(e){"use no memo";let{mode:t,children:n}=e;return $(`div`,{children:[$(`div`,{"data-truncate-content":`visible`,children:t===`fruncate`?$(`span`,{children:n}):n}),$(`div`,{"data-truncate-content":`overflow`,"aria-hidden":!0,children:t===`fruncate`?$(`span`,{children:n}):n})]})}function VA({children:e,mode:t=`truncate`,marker:n=`…`,variant:r=`default`,...i}){"use no memo";let a=$(BA,{mode:t,children:e},`content`),o=$(zA,{marker:n,mode:t,variant:r},`marker`),s=$(`div`,{"data-truncate-fill":!0},`fill`);return $(`div`,{"data-truncate-container":t,"data-truncate-variant":r,...i,children:$(`div`,{"data-truncate-grid":!0,children:t===`truncate`?[a,o]:[o,a,s]})})}function HA({children:e,...t}){"use no memo";return $(VA,{mode:`truncate`,...t,children:e})}function UA({children:e,...t}){"use no memo";return $(VA,{mode:`fruncate`,...t,children:e})}function WA({children:e,contents:t,priority:n=`end`,split:r=`center`,minimumLength:i=12,className:a,style:o,...s}){"use no memo";let c=null,l=null;if(Array.isArray(t)){if(t.length!==2)return console.error(`MiddleTruncate: contents must be an array of two items`),null;c=$(HA,{...s,children:t[0]}),l=$(UA,{...s,children:t[1]})}else{if(typeof e!=`string`)return console.error(`MiddleTruncate: children must be a string`),null;if(e.length===0)return $(`div`,{className:a,style:o});if(e.length<i)return $(n===`end`?UA:HA,{...s,className:a,style:o,children:e});let t=null,u=null,d=null;if(typeof r==`string`)r===`center`?t=NA:r===`extension`?t=PA:r===`leaf-path`&&(t=FA);else if(typeof r==`number`)t=IA,u=r;else if(Array.isArray(r)){let[e,n]=r;d=n,e===`last`?t=LA:e===`first`&&(t=RA)}else typeof r==`function`&&(t=r);t??=NA;let[f,p]=t(e,{priority:n,variant:s.variant,splitIndex:typeof u==`number`?u:void 0,splitOffset:typeof d==`number`?d:void 0}),m=f.length>=p.length,h=n===`equal`&&!m,g=n===`equal`&&m,_={},v={};h&&(_.marker=``),g&&(v.marker=``),c=$(HA,{...s,..._,children:f}),l=$(UA,{...s,...v,children:p})}return $(`div`,{"data-truncate-group-container":`middle`,className:a,style:o,children:[$(`div`,{"data-truncate-segment-priority":n===`start`||n===`equal`?`1`:`2`,children:c}),$(`div`,{"data-truncate-segment-priority":n===`end`||n===`equal`?`1`:`2`,children:l})]})}var GA={endIndex:-1,startIndex:-1};function KA(e,t,n){return Math.min(Math.max(e,t),n)}function qA(e,t){return e<0||t<e?GA:{endIndex:t,startIndex:e}}function JA(e){return e.startIndex<0||e.endIndex<e.startIndex}function YA(e,t){return JA(e)?0:(e.endIndex-e.startIndex+1)*t}function XA(e,t,n){if(t<=0)return-1;let r=t*n;return e<=0?0:e>=r?t:Math.floor(e/n)}function ZA(e,t,n){return t<=0||e<=0?-1:e>=t*n?t-1:Math.ceil(e/n)-1}function QA(e){let t=new Map;return e.forEach((e,n)=>{if(e.kind!==`directory`||!e.isExpanded)return;let r=e.ancestorPaths.length,i=t.get(r);if(i==null){t.set(r,[n]);return}i.push(n)}),t}function $A(e,t){let n=0,r=e.length-1,i=-1;for(;n<=r;){let a=Math.floor((n+r)/2),o=e[a];if(o==null)break;if(o<=t){i=a,n=a+1;continue}r=a-1}return i}function ej(e){let t=new Map,n=[];for(let r=0;r<e.length;r+=1){let i=e[r];if(i==null)continue;let a=i.kind===`directory`&&i.isExpanded?[...i.ancestorPaths,i.path]:i.ancestorPaths,o=0;for(;o<n.length&&o<a.length&&n[o]===a[o];)o+=1;for(let e=n.length-1;e>=o;--e){let i=n[e];i!=null&&t.set(i,r-1)}n.length=o;for(let e=o;e<a.length;e+=1){let t=a[e];t!=null&&n.push(t)}}let r=e.length-1;for(let e of n)t.set(e,r);return t}function tj(e,t,n){if(e.length===0||t<=0)return[];let r=ej(e),i=QA(e),a=[];for(let r=0;r<e.length;r+=1){let o=i.get(r);if(o==null||o.length===0)break;let s=t+r*n,c=$A(o,Math.min(e.length-1,Math.floor(s/n))),l=null;for(;c>=0;){let t=o[c],n=t==null?null:e[t]??null;if(n!=null&&(r===0||n.ancestorPaths[r-1]===a[r-1]?.path)){l=n;break}--c}if(l==null)break;a.push(l)}return a.map((i,a)=>{let o=a*n,s=(r.get(i.path)??e.length-1)+1;if(s>=e.length)return{row:i,top:o};let c=s*n-t;return{row:i,top:Math.min(o,c-n)}}).filter(e=>e.top+n>0)}function nj(e,t){let n=t.totalRowCount??e.length,r=n*t.itemHeight,i=Math.max(0,t.viewportHeight),a=Math.max(0,Math.floor(t.overscan)),o=Math.max(0,r-i),s=KA(t.scrollTop,0,o),c=t.stickyRows??tj(e,s,t.itemHeight),l=c.reduce((e,n)=>Math.max(e,n.top+t.itemHeight),0),u=Math.min(r,s+l),d=Math.max(0,i-l),f=Math.max(0,r-u),p=XA(s,n,t.itemHeight),m=XA(u,n,t.itemHeight),h=l<=0||p<0||p>=n?-1:p,g=h===-1?-1:Math.min(n-1,m-1),_=h===-1||g<h?0:g-h+1,v=d<=0||m>=n?GA:qA(m,ZA(u+d,n,t.itemHeight)),y=g+1,b=JA(v)?GA:qA(Math.max(y,v.startIndex-a),Math.min(n-1,v.endIndex+a)),x=YA(b,t.itemHeight);return{occlusion:{firstOccludedIndex:h,lastOccludedIndex:g,occludedCount:_},physical:{itemHeight:t.itemHeight,maxScrollTop:o,overscan:a,scrollTop:s,totalHeight:r,totalRowCount:n,viewportHeight:i},projected:{contentHeight:f,paneHeight:d,paneTop:u},sticky:{height:l,rows:c},visible:v,window:{endIndex:b.endIndex,height:x,offsetTop:JA(b)?0:b.startIndex*t.itemHeight,startIndex:b.startIndex}}}var rj={added:`A`,deleted:`D`,ignored:null,modified:`M`,renamed:`R`,untracked:`U`},ij={added:`Git status: added`,deleted:`Git status: deleted`,ignored:`Git status: ignored`,modified:`Git status: modified`,renamed:`Git status: renamed`,untracked:`Git status: untracked`},aj=`Contains git status items`;function oj(e){return e.current?!0:(e.current=!0,!1)}function sj(e){let{currentScrollTop:t,focusedIndex:n,itemHeight:r,topInset:i=0,viewportHeight:a}=e;if(n<0)return null;let o=Math.max(0,i),s=n*r,c=s+r;if(s<t+o){let e=Math.max(0,s-o);return e===t?null:e}if(c>t+a){let e=c-a;return e===t?null:e}return null}function cj(e){let{currentScrollTop:t,focusedIndex:n,itemHeight:r,offset:i,topInset:a=0,totalHeight:o,viewportHeight:s}=e;if(i===`nearest`)return sj({currentScrollTop:t,focusedIndex:n,itemHeight:r,topInset:a,viewportHeight:s});if(n<0)return null;let c=Math.max(0,a),l=n*r,u=Math.max(0,s-c),d=i===`center`?c+Math.max(0,(u-r)/2):c,f=Math.max(0,o-s),p=Math.max(0,Math.min(l-d,f));return p===t?null:p}function lj(e){let{currentScrollTop:t,focusedIndex:n,itemHeight:r,targetViewportOffset:i,totalHeight:a,viewportHeight:o}=e;if(n<0)return null;let s=Math.max(0,i),c=n*r,l=c+r,u=t+s,d=t+o;if(c>=u&&l<=d)return null;let f=Math.max(0,a-o),p=Math.max(0,Math.min(c-s,f));return p===t?null:p}function uj(e){if(e==null||!e.isConnected||e===document.body||e===document.documentElement)return!1;e.focus({preventScroll:!0});let t=e.getRootNode();return t instanceof ShadowRoot?t.activeElement===e:document.activeElement===e}function dj(e){let t=e.getRootNode();if(t instanceof ShadowRoot){let e=t.activeElement;return e instanceof HTMLElement?e:null}let n=document.activeElement;return n instanceof HTMLElement&&e.contains(n)?n:null}function fj(e,t){if(e==null)return t;let n=e.getBoundingClientRect().height;return n>0?n:e.clientHeight>0?e.clientHeight:t}function pj(e,t){return e!=null&&e>0?e:t}function mj(e){let t=e.borderBoxSize,n=Array.isArray(t)?t[0]:t;return n!=null&&Number.isFinite(n.blockSize)&&n.blockSize>0?n.blockSize:e.contentRect.height>0?e.contentRect.height:null}function hj(e,t,n,r,i=0){let a=sj({currentScrollTop:e.scrollTop,focusedIndex:t,itemHeight:n,topInset:i,viewportHeight:r});return a==null?!1:(e.scrollTop=a,!0)}function gj(e,t,n,r,i,a,o=0){let s=cj({currentScrollTop:e.scrollTop,focusedIndex:t,itemHeight:n,offset:a,topInset:o,totalHeight:i,viewportHeight:r});return s==null?!1:(e.scrollTop=s,!0)}function _j(e,t,n,r,i,a){let o=lj({currentScrollTop:e.scrollTop,focusedIndex:t,itemHeight:n,targetViewportOffset:a,totalHeight:i,viewportHeight:r});return o==null?!1:(e.scrollTop=o,!0)}function vj(e,t,n,r){return n.end<n.start?null:e<n.start?-t:e>n.end?r:null}function yj(e){let{renamingPath:t,previousRenamingPath:n,hasRenderedInput:r}=e;return t==null?`reset`:r?n===t?`ignore`:`focus-input`:`reveal-canonical`}function bj({ariaLabel:e,isFlattened:t=!1,ref:n,value:r,onBlur:i,onInput:a}){return $(`input`,{ref:n,"data-item-rename-input":!0,...t?{"data-item-flattened-rename-input":!0}:{},"aria-label":e,value:r,onBlur:i,onInput:a,onClick:e=>e.stopPropagation(),onMouseDown:e=>e.stopPropagation(),onPointerDown:e=>e.stopPropagation()})}function xj(e){let{row:t,mode:n,targetPath:r,ariaLabel:i,domId:a,isParked:o,itemHeight:s,features:c,state:l,extraStyle:u}=e,d=n===`sticky`,f=t.ancestorPaths.at(-1)??``,p={};return l.isFocusRinged&&(p[`data-item-focused`]=!0),t.isSelected&&(p[`data-item-selected`]=!0),l.isContextHovered&&(p[`data-item-context-hover`]=`true`),l.isDragTarget&&(p[`data-item-drag-target`]=!0),l.isDragging&&(p[`data-item-dragging`]=!0),l.effectiveGitStatus!=null&&(p[`data-item-git-status`]=l.effectiveGitStatus),l.containsGitChange&&(p[`data-item-contains-git-change`]=`true`),{"aria-expanded":!d&&t.kind===`directory`?t.isExpanded:void 0,"aria-haspopup":c.contextMenuEnabled?`menu`:void 0,"aria-label":i,"aria-level":d?void 0:t.level+1,"aria-posinset":d?void 0:t.posInSet+1,"aria-selected":d?void 0:t.isSelected?`true`:`false`,"aria-setsize":d?void 0:t.setSize,"data-file-tree-sticky-path":d?r:void 0,"data-file-tree-sticky-row":d?`true`:void 0,"data-item-context-menu-button-visibility":c.actionLaneEnabled?c.contextMenuButtonVisibility:void 0,"data-item-context-menu-trigger-mode":c.contextMenuEnabled?c.contextMenuTriggerMode:void 0,"data-item-has-context-menu-action-lane":c.actionLaneEnabled?`true`:void 0,"data-item-has-git-lane":c.gitLaneActive?`true`:void 0,"data-item-parent-path":f.length>0?f:void 0,"data-item-parked":o?`true`:void 0,"data-item-path":r,"data-item-type":t.kind===`directory`?`folder`:`file`,"data-type":`item`,id:d?void 0:a,role:d?void 0:`treeitem`,style:{minHeight:`${s}px`,...u},tabIndex:!d&&t.isFocused?0:-1,...p}}function Sj(e){let{event:t,mode:n,isSearchOpen:r,isDirectory:i}=e,a=t.ctrlKey||t.metaKey,o=t.shiftKey||a,s=t.shiftKey?{additive:a,kind:`range`}:a?{kind:`toggle`}:{kind:`single`};return{closeSearch:r,revealCanonical:n===`sticky`,selection:s,toggleDirectory:!o&&i}}var Cj,wj,Tj,Ej,Dj=Object.is,Oj=0,kj=[],Aj=Rk,jj=Aj.__b,Mj=Aj.__r,Nj=Aj.diffed,Pj=Aj.__c,Fj=Aj.unmount,Ij=Aj.__;function Lj(e,t){Aj.__h&&Aj.__h(wj,e,Oj||t),Oj=0;var n=wj.__H||={__:[],__h:[]};return e>=n.__.length&&n.__.push({}),n.__[e]}function Rj(e){return Oj=1,zj(Zj,e)}function zj(e,t,n){var r=Lj(Cj++,2);if(r.t=e,!r.__c&&(r.__=[n?n(t):Zj(void 0,t),function(e){var t=r.__N?r.__N[0]:r.__[0],n=r.t(t,e);Dj(t,n)||(r.__N=[n,r.__[1]],r.__c.setState({}))}],r.__c=wj,!wj.__f)){var i=function(e,t,n){if(!r.__c.__H)return!0;var i=r.__c.__H.__.filter(function(e){return!!e.__c});if(i.every(function(e){return!e.__N}))return!a||a.call(this,e,t,n);var o=r.__c.props!==e;return i.forEach(function(e){if(e.__N){var t=e.__[0];e.__=e.__N,e.__N=void 0,Dj(t,e.__[0])||(o=!0)}}),a&&a.call(this,e,t,n)||o};wj.__f=!0;var a=wj.shouldComponentUpdate,o=wj.componentWillUpdate;wj.componentWillUpdate=function(e,t,n){if(4&this.__g){var r=a;a=void 0,i(e,t,n),a=r}o&&o.call(this,e,t,n)},wj.shouldComponentUpdate=i}return r.__N||r.__}function Bj(e,t){var n=Lj(Cj++,3);!Aj.__s&&Xj(n.__H,t)&&(n.__=e,n.u=t,wj.__H.__h.push(n))}function Vj(e,t){var n=Lj(Cj++,4);!Aj.__s&&Xj(n.__H,t)&&(n.__=e,n.u=t,wj.__h.push(n))}function Hj(e){return Oj=5,Uj(function(){return{current:e}},[])}function Uj(e,t){var n=Lj(Cj++,7);return Xj(n.__H,t)&&(n.__=e(),n.__H=t,n.__h=e),n.__}function Wj(e,t){return Oj=8,Uj(function(){return e},t)}function Gj(){for(var e;e=kj.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(Jj),e.__H.__h.forEach(Yj),e.__H.__h=[]}catch(t){e.__H.__h=[],Aj.__e(t,e.__v)}}Aj.__b=function(e){wj=null,jj&&jj(e)},Aj.__=function(e,t){e&&t.__k&&t.__k.__m&&(e.__m=t.__k.__m),Ij&&Ij(e,t)},Aj.__r=function(e){Mj&&Mj(e),Cj=0;var t=(wj=e.__c).__H;t&&(Tj===wj?(t.__h=[],wj.__h=[],t.__.forEach(function(e){e.__N&&(e.__=e.__N),e.u=e.__N=void 0})):(t.__h.forEach(Jj),t.__h.forEach(Yj),t.__h=[],Cj=0)),Tj=wj},Aj.diffed=function(e){Nj&&Nj(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(kj.push(t)!==1&&Ej===Aj.requestAnimationFrame||((Ej=Aj.requestAnimationFrame)||qj)(Gj)),t.__H.__.forEach(function(e){e.u&&(e.__H=e.u),e.u=void 0})),Tj=wj=null},Aj.__c=function(e,t){t.some(function(e){try{e.__h.forEach(Jj),e.__h=e.__h.filter(function(e){return!e.__||Yj(e)})}catch(n){t.some(function(e){e.__h&&=[]}),t=[],Aj.__e(n,e.__v)}}),Pj&&Pj(e,t)},Aj.unmount=function(e){Fj&&Fj(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach(function(e){try{Jj(e)}catch(e){t=e}}),n.__H=void 0,t&&Aj.__e(t,n.__v))};var Kj=typeof requestAnimationFrame==`function`;function qj(e){var t,n=function(){clearTimeout(r),Kj&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,35);Kj&&(t=requestAnimationFrame(n))}function Jj(e){var t=wj,n=e.__c;typeof n==`function`&&(e.__c=void 0,n()),wj=t}function Yj(e){var t=wj;e.__c=e.__(),wj=t}function Xj(e,t){return!e||e.length!==t.length||t.some(function(t,n){return!Dj(t,e[n])})}function Zj(e,t){return typeof t==`function`?t(e):t}function Qj(e,t=null,n=null){"use no memo";let r=e.flattenedSegments;return r==null||r.length===0?t??e.name:$(`span`,{"data-item-flattened-subitems":!0,children:r.map((e,i)=>{let a=i===r.length-1;return $(nA,{children:[$(`span`,{"data-item-flattened-subitem":e.path,"data-item-flattened-subitem-drag-target":n===e.path?`true`:void 0,children:a&&t!=null?t:$(HA,{children:e.name})}),i<r.length-1?` / `:``]},e.path)})})}function $j(e){return e.isFlattened?e.flattenedSegments?.findLast(e=>e.isTerminal)?.path??e.path:e.path}function eM(e){let t=e.flattenedSegments;return t==null||t.length===0?e.name:t.map(e=>e.name).join(` / `)}function tM(e,t,n,r){return e.map((e,i)=>{let a=i*n,o=e.subtreeEndIndex+1;if(o>=r)return{row:e.row,top:a};let s=o*n-t;return{row:e.row,top:Math.min(a,s-n)}}).filter(e=>e.top+n>0)}function nM({controller:e,itemHeight:t,overscan:n,scrollTop:r,stickyFolders:i,viewportHeight:a}){let o=e.getVisibleCount(),s=i&&o>0?e.getStickyRowCandidates(r,t):[],c=s==null&&i&&o>0?e.getVisibleRows(0,o-1):[],l=nj(c,{itemHeight:t,overscan:n,scrollTop:r,stickyRows:s==null?void 0:tM(s,r,t,o),totalRowCount:o,viewportHeight:a}),u=i&&r<=0&&o>0?e.getStickyRowCandidates(1,t):[],d=u!=null&&r<=0?tM(u,1,t,o):i&&r<=0&&c.length>0?tj(c,1,t):l.sticky.rows;return{overlayHeight:d.reduce((e,n)=>Math.max(e,n.top+t),0),overlayRows:d,snapshot:l,visibleRows:c}}var rM=400,iM=10,aM=40,oM=18;function sM(e,t,n){let r=e,i=document.elementFromPoint?.bind(document)??null,a=r.elementFromPoint?.(t,n)??i?.(t,n)??null;return e instanceof ShadowRoot&&(a==null||!e.contains(a))?cM(e,t,n):a instanceof HTMLElement?a:null}function cM(e,t,n){let r=Array.from(e.querySelectorAll(`[data-type="item"], [data-item-flattened-subitem]`));for(let e=r.length-1;e>=0;e--){let i=r[e],a=i.getBoundingClientRect();if(t>=a.left&&t<=a.right&&n>=a.top&&n<=a.bottom)return i}return null}function lM(e){let t=e?.closest?.(`[data-type="item"]`);if(!(t instanceof HTMLElement))return null;let n=t.dataset.itemPath??null;if(n==null)return null;let r=e?.closest?.(`[data-item-flattened-subitem]`),i=r instanceof HTMLElement?r.getAttribute(`data-item-flattened-subitem`)??null:null;if(i!=null&&i.endsWith(`/`))return{directoryPath:i,flattenedSegmentPath:i,hoveredPath:n,kind:`directory`};if(t.dataset.itemType===`folder`)return{directoryPath:n,flattenedSegmentPath:null,hoveredPath:n,kind:`directory`};let a=t.dataset.itemParentPath??null;return a==null||a.length===0?{directoryPath:null,flattenedSegmentPath:null,hoveredPath:n,kind:`root`}:{directoryPath:a,flattenedSegmentPath:null,hoveredPath:n,kind:`directory`}}function uM(e){let t=e.cloneNode(!0);return t.removeAttribute(`id`),t.dataset.fileTreeDragPreview=`true`,t.setAttribute(`aria-hidden`,`true`),t.tabIndex=-1,Object.assign(t.style,{boxShadow:`0 4px 12px rgba(0, 0, 0, 0.15)`,left:`0px`,margin:`0`,pointerEvents:`none`,position:`fixed`,top:`0px`,willChange:`transform`,zIndex:`10000`}),t}function dM(){return navigator.vendor!==`Apple Computer, Inc.`}function fM(e,t){let n=e-t.top;if(n<aM)return-Math.ceil((aM-Math.max(0,n))/aM*oM);let r=t.bottom-e;return r<aM?Math.ceil((aM-Math.max(0,r))/aM*oM):0}function pM(e,t){if(e!=null){let t=rj[e];return t==null?null:{text:t,title:ij[e]}}return t?{icon:{name:`file-tree-icon-dot`,width:6,height:6},title:aj}:null}function mM(e,t,n){if(t==null||t.size===0)return null;let r=[];for(let i=e.length-1;i>=0;--i){let a=e[i],o=n.get(a);if(o!=null){for(let e of r)n.set(e,o);return o?`ignored`:null}if(t.has(a)){n.set(a,!0);for(let e of r)n.set(e,!0);return`ignored`}r.push(a)}for(let e of r)n.set(e,!1);return null}function hM(e){return e!=null&&`toggle`in e}function gM(e){return e.code===`Space`||e.key===` `||e.key===`Spacebar`}function _M(e){return e.key.length===1&&/^[\p{L}\p{N}]$/u.test(e.key)&&!e.ctrlKey&&!e.metaKey&&!e.altKey}function vM(e){return e==null?``:`[data-item-section="spacing-item"][data-ancestor-path="${e.replaceAll(`\\`,`\\\\`).replaceAll(`"`,`\\"`)}"] { opacity: 1; }`}function yM(e){return e.shiftKey&&e.key===`F10`||e.key===`ContextMenu`}function bM(e,t){return t&&yM(e)||(e.ctrlKey||e.metaKey)&&gM(e)?!0:e.key===`ArrowDown`||e.key===`ArrowLeft`||e.key===`ArrowRight`||e.key===`ArrowUp`}var xM=new Set([`ArrowDown`,`ArrowLeft`,`ArrowRight`,`ArrowUp`,`End`,`Home`,`PageDown`,`PageUp`]);function SM(e){for(let t of e.composedPath())if(t instanceof HTMLElement&&(t.dataset.fileTreeContextMenuRoot===`true`||t.dataset.type===`context-menu-anchor`||t.dataset.type===`context-menu-trigger`||t.getAttribute(`slot`)===`context-menu`))return!0;return!1}function CM(e){return{bottom:e.bottom,height:e.height,left:e.left,right:e.right,top:e.top,width:e.width,x:e.x,y:e.y}}function wM(e,t){return{bottom:t,height:0,left:e,right:e,top:t,width:0,x:e,y:t}}function TM(e,t){if(e==null)return t.offsetTop;let n=t.getBoundingClientRect(),r=e.getBoundingClientRect();return n.top-r.top}function EM(e,t,n){if(n==null){e.delete(t);return}e.set(t,n)}function DM(e,t,n){if(e==null)return null;let r=t.get(e)??null;if(r!=null)return r;let i=n.get(e)??null;return i?.dataset.itemParked===`true`?null:i}function OM(e){if(e==null)return[];let t=[];for(let n of e.querySelectorAll(`button[data-file-tree-sticky-row="true"]`)){if(!(n instanceof HTMLElement))continue;let e=n.dataset.fileTreeStickyPath;e!=null&&t.push(e)}return t}function kM(e,t){if(e==null||t==null)return null;for(let n of e.querySelectorAll(`button[data-item-focused="true"][data-item-parked="true"]`))if(n instanceof HTMLElement&&n.dataset.itemPath===t)return n;return null}function AM(e,t,n,r,i,a,o){let s=Math.max(0,a-i),c=t?.getBoundingClientRect()??null,l=c==null||n==null?null:n.getBoundingClientRect().top-c.top,u=kM(e,r),d=c==null||u==null?null:u.getBoundingClientRect().top-c.top;return Math.max(0,Math.min(d??Math.max(l??0,s),Math.max(0,o-i)))}function jM(e,t){return{kind:e.kind,name:eM(e),path:t}}function MM(e){return e==null?void 0:`${e}__tree`}function NM(e,t,n){if(e!=null)return`${e}__focused-item-${encodeURIComponent(t)}${n?`__parked`:``}`}function PM(e){return e===`file-tree-icon-chevron`||e===`file-tree-icon-dot`||e===`file-tree-icon-file`||e===`file-tree-icon-lock`}function FM(e,t){if(e==null)return null;if(`text`in e)return $(`span`,{title:e.title,children:e.text});let n=typeof e.icon==`string`?PM(e.icon)?t(e.icon):{name:e.icon}:PM(e.icon.name)?(()=>{let n=t(e.icon.name),{name:r,...i}=e.icon;return{...n,...i}})():e.icon;return $(`span`,{title:e.title,children:$(kA,{...n})})}function IM(e){e!=null&&uj(e.querySelector([`button:not([disabled])`,`[href]`,`input:not([disabled])`,`select:not([disabled])`,`textarea:not([disabled])`,`[tabindex]:not([tabindex="-1"])`].join(`, `))??e)}function LM(e,t,{actionLaneEnabled:n=!1,customDecoration:r=null,decorationLaneEnabled:i=!1,dragTargetFlattenedSegmentPath:a=null,gitDecoration:o=null,gitLaneActive:s=!1,renameInput:c=null,showDecorativeActionAffordance:l=!1}={}){let u=$j(e);return $(nA,{children:[e.depth>0?$(`div`,{"data-item-section":`spacing`,children:Array.from({length:e.depth}).map((t,n)=>$(`div`,{"data-item-section":`spacing-item`,"data-ancestor-path":e.ancestorPaths[n]},n))}):null,$(`div`,{"data-item-section":`icon`,children:e.kind===`directory`?$(kA,{...t(`file-tree-icon-chevron`)}):$(kA,{...t(`file-tree-icon-file`,u)})}),$(`div`,{"data-item-section":`content`,children:e.isFlattened?Qj(e,c,a):c??$(WA,{minimumLength:5,split:`extension`,children:e.name})}),i?$(`div`,{"data-item-section":`decoration`,children:r==null?null:FM(r,t)}):null,s?$(`div`,{"data-item-section":`git`,children:FM(o,t)}):null,n?$(`div`,{"data-item-section":`action`,children:l?$(`span`,{"aria-hidden":`true`,"data-item-action-affordance":`decorative`,children:$(kA,{...t(`file-tree-icon-ellipsis`)})}):null}):null]})}function RM(e,t,n,r={}){let{controller:i,renameView:a,visualFocusPath:o,contextHoverPath:s,draggedPathSet:c,dragTarget:l,dragAndDropEnabled:u,shouldSuppressContextMenu:d,handleRowDragStart:f,handleRowDragEnd:p,handleRowTouchStart:m,instanceId:h,itemHeight:g,gitStatusByPath:_,ignoredGitDirectories:v,ignoredInheritanceCache:y,directoriesWithGitChanges:b,gitLaneActive:x,contextMenuEnabled:S,contextMenuTriggerMode:C,contextMenuButtonTriggerEnabled:w,contextMenuButtonVisibility:T,contextMenuRightClickEnabled:E,registerRenameInput:D,registerButton:O,resolveIcon:ee,renderDecorationForRow:k,openContextMenuForRow:A,onRowClick:j,onKeyDown:M}=e,N=$j(t),{isParked:te=!1,mode:ne=`flow`,style:P}=r,re=ne===`sticky`,ie=_?.get(N)??null??mM(t.ancestorPaths,v,y),ae=t.kind===`directory`&&(b?.has(N)??!1),oe=k(t,N),F=pM(ie,ae),I=S&&w,L=oe!=null||x||I,se=I&&T===`always`,ce=a.getPath()===N,le=ce?a.getValue():``,ue=re||!ce?null:$(bj,{ref:D,ariaLabel:`Rename ${eM(t)}`,isFlattened:t.isFlattened,value:le,onBlur:()=>{a.commit()},onInput:e=>{a.setValue(e.currentTarget.value)}}),de=LM(t,ee,{actionLaneEnabled:I,customDecoration:oe,decorationLaneEnabled:L,dragTargetFlattenedSegmentPath:l?.flattenedSegmentPath??null,gitDecoration:F,gitLaneActive:x,renameInput:ue,showDecorativeActionAffordance:se}),R={...xj({ariaLabel:eM(t),domId:t.isFocused?NM(h,N,te):void 0,extraStyle:P,features:{actionLaneEnabled:I,contextMenuButtonVisibility:I?T:null,contextMenuEnabled:S,contextMenuTriggerMode:S?C:null,gitLaneActive:x},isParked:te,itemHeight:g,mode:ne,row:t,state:{containsGitChange:ae,effectiveGitStatus:ie,isContextHovered:s===N,isDragTarget:l?.kind===`directory`&&l.directoryPath===N,isDragging:c?.has(N)===!0,isFocusRinged:t.isFocused&&o===N},targetPath:N}),key:n,onContextMenu:S||u?e=>{if(d()){e.preventDefault();return}S&&(e.preventDefault(),E&&(i.focusMountedPathFromInput(N),A(t,N,{anchorRect:wM(e.clientX,e.clientY),source:`right-click`})))}:void 0,onFocus:re?void 0:()=>{i.focusMountedPathFromInput(N)},onKeyDown:re?void 0:M,ref:e=>{O(N,e)}};return!re&&ce?$(`div`,{...R,children:de}):$(`button`,{...R,type:`button`,draggable:u&&!te,onDragEnd:u&&!te?p:void 0,onDragStart:u&&!te?e=>{f(e,t,N)}:void 0,onMouseDown:e=>{if(re){e.preventDefault();return}i.isSearchOpen()&&e.preventDefault()},onTouchStart:u&&!te?e=>{m(e,t,N)}:void 0,onClick:e=>{j(e,t,N,ne)},children:de})}function zM(e,t,n){return t.end<t.start?[]:e.controller.getVisibleRows(t.start,t.end).filter(e=>!n.has($j(e))).map((n,r)=>RM(e,n,t.start+r))}function BM({composition:e,controller:t,gitStatusByPath:n,ignoredGitDirectories:r,directoriesWithGitChanges:i,icons:a,instanceId:o,itemHeight:s=Kw,overscan:c=10,renamingEnabled:l=!1,renderRowDecoration:u,searchBlurBehavior:d=`close`,searchEnabled:f=!1,searchFakeFocus:p=!1,slotHost:m,stickyFolders:h=!1,initialViewportHeight:g=420}){"use no memo";let _=Hj(null),v=Hj(null),y=Hj(!1),b=Hj(null),x=Hj(null),S=Hj(null),C=Hj(null),w=Hj(null),T=Hj(new Map),E=Hj(new Map),D=Hj(()=>{}),O=Hj(null),ee=Hj(0),k=Hj(!1),A=Hj(null);A.current!==t&&(k.current=!1,A.current=t);let j=Hj(!1),M=Hj(null),N=Hj(null),te=Hj(!1),ne=Hj(null),P=Hj(null),re=Hj(null),ie=Hj(null),ae=Hj(null),oe=Hj(null),F=Hj(null),I=Hj(null),L=Hj(!1),se=Hj(null),ce=Hj(null),le=Hj(null),ue=Hj(null),de=Uj(()=>new Map,[]),[,R]=Rj(0),fe=Hj(!1),[pe,me]=Rj(null),[he,ge]=Rj(null),[_e,ve]=Rj(null),[ye,be]=Rj(null),[xe,Se]=Rj(0),[z,Ce]=Rj(null),we=Hj(z);we.current=z;let Te=Hj(null),Ee=Hj(null),De=Hj(null),Oe=Hj(null),ke=Hj(null),Ae=Hj(!1),je=()=>{Ee.current=null,De.current=null,Oe.current=null},Me=(e,t)=>{Ee.current=e,De.current=null,Oe.current=t==null?null:{path:e,scrollTop:t}},Ne=(e,t)=>{Ee.current=null,De.current={path:e,viewportOffset:t},Oe.current=null},Pe=Hj(d===`retain`&&t.isSearchOpen()),[Fe,Ie]=Rj(p);Bj(()=>{p||Ie(!1)},[p]);let Le=Hj(!1),B=Wj(()=>{Le.current=!0,Ie(e=>e&&!1)},[]),[Re,ze]=Rj(()=>nM({controller:t,itemHeight:s,overscan:c,scrollTop:0,stickyFolders:h,viewportHeight:g})),[Be,Ve]=Rj(!1);Bj(()=>{Ve(!0)},[]);let He=e?.contextMenu?.enabled===!0||e?.contextMenu?.render!=null||e?.contextMenu?.onOpen!=null||e?.contextMenu?.onClose!=null,Ue=e?.contextMenu?.triggerMode??(He?`right-click`:`both`),We=Ue===`both`||Ue===`button`,Ge=e?.contextMenu?.buttonVisibility??`when-needed`,Ke=Ue===`both`||Ue===`right-click`;Vj(()=>{let e=S.current;if(e==null)return;let t=e=>{if(!(e instanceof CustomEvent))return;let t=e.detail?.path??null;ke.current=t,ge(t),be(t==null?null:`pointer`)},n=e=>{e instanceof CustomEvent&&(Ae.current=e.detail?.disabled===!0)};return e.addEventListener(`file-tree-debug-set-context-menu-trigger`,t),e.addEventListener(`file-tree-debug-set-scroll-suppression`,n),()=>{e.removeEventListener(`file-tree-debug-set-context-menu-trigger`,t),e.removeEventListener(`file-tree-debug-set-scroll-suppression`,n)}},[]);let qe=Wj((e,t)=>{EM(T.current,e,t)},[]),Je=Wj((e,t)=>{EM(E.current,e,t)},[]),V=Wj(e=>{x.current=e},[]),Ye=Wj(e=>DM(e,E.current,T.current),[]),Xe=n!=null||r!=null||i!=null,{resolveIcon:Ze}=Uj(()=>Lk(a),[a]),Qe=t[pk](),$e=Qe.getPath(),et=$e!=null,tt=t.isSearchOpen(),nt=t.getSearchValue(),rt=t.getFocusedPath(),H=t.getFocusedIndex(),it=t.getScrollRequest(),at=t.isDragAndDropEnabled(),ot=t.getDragSession(),st=Uj(()=>ot==null?null:new Set(ot.draggedPaths),[ot]),ct=ot?.target??null,lt=ot?.primaryPath??null,ut=MM(o),{overlayHeight:dt,overlayRows:ft,snapshot:pt,visibleRows:mt}=Re,ht=pt.physical.viewportHeight,gt=Uj(()=>({end:pt.window.endIndex,start:pt.window.startIndex}),[pt.window.endIndex,pt.window.startIndex]),_t=ft,vt=pt.sticky.rows,yt=pt.physical.totalHeight,bt=pt.sticky.height,xt=Uj(()=>new Set(vt.map(e=>$j(e.row))),[vt]),St=H>=0&&H>=gt.start&&H<=gt.end,Ct=Wj((e,t)=>u?.({item:jM(e,t),row:e})??null,[u]),wt=Wj(e=>uj(e==null?null:T.current.get(e)??null)?!0:uj(S.current),[]),Tt=Wj(e=>{wt(t.focusNearestPath(e))},[t,wt]),Et=Hj(Tt);Et.current=Tt;let Dt=Hj(!0),Ot=Hj(()=>{}),kt=Wj((t=!0)=>{let n=we.current;n!=null&&(Dt.current=Dt.current&&t,Ce(null),e?.contextMenu?.onClose?.(),Dt.current&&Tt(n.path))},[e?.contextMenu,Tt]);Ot.current=kt;let At=Wj(e=>{let t=e==null?null:TM(S.current,e);ve(e=>e===t?e:t)},[]),jt=Wj((e,n,r)=>{let i=t.getItem(n);if(i==null)return;let a=Ye(n);if(a?.dataset.fileTreeStickyRow===`true`){let e=C.current;Me(n,e?.scrollTop??null),j.current=!0,me(e=>e===n?e:n)}i.focus(),At(a),Dt.current=!0,Ce({anchorRect:r?.anchorRect??null,item:jM(e,n),path:n,source:r?.source??`keyboard`})},[t,Ye,At]),Mt=Wj(e=>{if(l){if(t.isSearchOpen()){let e=C.current,t=fj(e,ht);ne.current=H<0||e==null?null:Math.max(0,Math.min(H*s-e.scrollTop,Math.max(0,t-s))),te.current=!0}t.startRenaming(e)!==!1&&(be(`focus`),R(e=>e+1))}},[t,H,s,l,ht]),Nt=Wj((e,{restoreTreeFocus:n=!0,targetOffset:r=`live-overlay`}={})=>{let i=C.current;if(i==null)return!1;t.focusPath(e);let a=t.getFocusedIndex();if(a<0)return!1;let o=t.getVisibleRows(a,a)[0]??null;if(o==null)return!1;let l=fj(i,ht),u=t.getVisibleCount()*s,d=r===`sticky-parents`?o.ancestorPaths.length*s:nM({controller:t,itemHeight:s,overscan:c,scrollTop:i.scrollTop,stickyFolders:h,viewportHeight:l}).snapshot.sticky.height;return j.current=!0,_j(i,a,s,l,u,d),D.current(),Te.current=n?e:null,!0},[t,s,c,ht,h]),Pt=()=>y.current===!0||ue.current!=null||L.current===!0,Ft=e=>typeof window.requestAnimationFrame==`function`?window.requestAnimationFrame(()=>{e()}):window.setTimeout(e,16),It=e=>{if(e!=null){if(typeof window.cancelAnimationFrame==`function`){window.cancelAnimationFrame(e);return}window.clearTimeout(e)}},Lt=()=>{ie.current!=null&&(clearTimeout(ie.current),ie.current=null),re.current=null},Rt=()=>{oe.current?.remove(),oe.current=null},zt=()=>{It(P.current),P.current=null,ae.current=null},Bt=e=>{let t=S.current?.getRootNode();if(t instanceof ShadowRoot){t.append(e);return}document.body.append(e)},Vt=()=>{I.current?.(),I.current=null,ue.current!=null&&(clearTimeout(ue.current),ue.current=null),L.current=!1,se.current=null,le.current=null,ce.current!=null&&(ce.current.setAttribute(`draggable`,`true`),ce.current.style.removeProperty(`touch-action`),ce.current=null),Rt(),Lt(),zt(),F.current=null},Ht=(e,n)=>{let r=S.current?.getRootNode(),i=lM(sM(r instanceof ShadowRoot?r:document,e,n));return t.setDragTarget(i),t.getDragSession()?.target??null},Ut=e=>{let n=t.getDragAndDropConfig()?.openOnDropDelay??800;if(e==null||e.kind!==`directory`||e.directoryPath==null||n<=0){Lt();return}let r=t.getItem(e.directoryPath),i=hM(r)?r:null;if(i==null||i.isExpanded()){Lt();return}let a=`${e.directoryPath}::${e.flattenedSegmentPath??``}`;re.current!==a&&(Lt(),re.current=a,ie.current=setTimeout(()=>{let n=t.getDragSession()?.target;n?.kind!==`directory`||n.directoryPath!==e.directoryPath||n.flattenedSegmentPath!==e.flattenedSegmentPath||i.expand()},n))},Wt=()=>{P.current=null;let e=ae.current,n=C.current;if(e==null||n==null||t.getDragSession()==null)return;let r=n.getBoundingClientRect(),i=fM(e.clientY,r);if(i===0)return;let a=Math.max(0,n.scrollHeight-n.clientHeight),o=Math.max(0,Math.min(a,n.scrollTop+i));o!==n.scrollTop&&(n.scrollTop=o,D.current()),Ut(Ht(e.clientX,e.clientY)),P.current=Ft(Wt)},Gt=(e,t)=>{ae.current={clientX:e,clientY:t},P.current??=Ft(Wt)},Kt=(e,n,r)=>{let i=e.currentTarget;if(i!=null){if(Vt(),Rt(),Lt(),zt(),t.startDrag(r)===!1){e.preventDefault();return}if(F.current=n,e.dataTransfer!=null&&(e.dataTransfer.effectAllowed=`move`,e.dataTransfer.dropEffect=`move`,e.dataTransfer.setData(`text/plain`,r),dM())){let t=uM(i),n=i.getBoundingClientRect();Object.assign(t.style,{height:`${n.height}px`,opacity:`0.85`,transform:`translate3d(-9999px, 0px, 0)`,width:`${n.width}px`}),Bt(t),oe.current=t,e.dataTransfer.setDragImage(t,Math.max(0,e.clientX-n.left),Math.max(0,e.clientY-n.top))}}},qt=()=>{Rt(),Lt(),zt(),F.current=null,t.cancelDrag()},Jt=(e,n,r)=>{if(ue.current!=null||L.current)return;let i=e.touches[0],a=e.currentTarget;if(i==null||a==null)return;le.current={clientX:i.clientX,clientY:i.clientY},ce.current=a,a.setAttribute(`draggable`,`false`);let o=(e={})=>{let t=e.restoreNativeDraggable??!L.current;ue.current!=null&&(clearTimeout(ue.current),ue.current=null),document.removeEventListener(`touchmove`,s),document.removeEventListener(`touchend`,c),document.removeEventListener(`touchcancel`,c),I.current===o&&(I.current=null),t&&(a.setAttribute(`draggable`,`true`),ce.current===a&&(ce.current=null),le.current=null)},s=e=>{let t=e.touches[0],n=le.current;if(t==null||n==null)return;let r=t.clientX-n.clientX,i=t.clientY-n.clientY;r*r+i*i<=iM*iM||o()},c=()=>{o()};document.addEventListener(`touchmove`,s,{passive:!0}),document.addEventListener(`touchend`,c),document.addEventListener(`touchcancel`,c),I.current=o,ue.current=setTimeout(()=>{if(o({restoreNativeDraggable:!1}),t.startDrag(r)===!1){a.setAttribute(`draggable`,`true`),ce.current===a&&(ce.current=null),le.current=null;return}L.current=!0,ce.current=a,a.setAttribute(`draggable`,`false`),a.style.setProperty(`touch-action`,`none`),F.current=n;let e=a.getBoundingClientRect(),s=uM(a);Object.assign(s.style,{height:`${e.height}px`,opacity:`0.85`,transform:`translate3d(${e.left}px, ${e.top}px, 0)`,width:`${e.width}px`}),Bt(s),oe.current=s,se.current={x:i.clientX-e.left,y:i.clientY-e.top};let c=e=>{let t=e.touches[0];if(t==null)return;e.preventDefault();let n=se.current;n!=null&&oe.current!=null&&(oe.current.style.transform=`translate3d(${t.clientX-n.x}px, ${t.clientY-n.y}px, 0)`),Ut(Ht(t.clientX,t.clientY)),Gt(t.clientX,t.clientY)},l=e=>{let n=e.changedTouches[0];n!=null&&Ht(n.clientX,n.clientY),t.completeDrag(),Vt()},u=()=>{t.cancelDrag(),Vt()};I.current=()=>{document.removeEventListener(`touchmove`,c),document.removeEventListener(`touchend`,l),document.removeEventListener(`touchcancel`,u)},document.addEventListener(`touchmove`,c,{passive:!1}),document.addEventListener(`touchend`,l),document.addEventListener(`touchcancel`,u)},rM)},Yt=e=>{if(z!=null){if(e.key===`Escape`){kt(),e.preventDefault(),e.stopPropagation();return}xM.has(e.key)&&(e.preventDefault(),e.stopPropagation());return}if(Qe.isActive()){if(e.key===`Escape`)Qe.cancel();else if(e.key===`Enter`)Qe.commit();else return;be(`focus`),R(e=>e+1),e.preventDefault(),e.stopPropagation();return}if(l&&e.key===`F2`){Mt(rt??void 0),e.preventDefault(),e.stopPropagation();return}if(tt){if(e.key===`Escape`)te.current=!1,ne.current=null,t.closeSearch();else if(e.key===`Enter`){let e=t.getFocusedPath();e!=null&&t.selectOnlyPath(e);let n=C.current,r=fj(n,ht);ne.current=H<0||n==null?null:Math.max(0,Math.min(H*s-n.scrollTop,Math.max(0,r-s))),te.current=!0,t.closeSearch()}else if(e.key===`ArrowDown`)t.focusNextSearchMatch();else if(e.key===`ArrowUp`)t.focusPreviousSearchMatch();else return;be(`focus`),R(e=>e+1),e.preventDefault(),e.stopPropagation();return}if(f&&_M(e)){t.openSearch(e.key),R(e=>e+1),e.preventDefault(),e.stopPropagation();return}let n=He&&yM(e),r=bM(e,He),i=r&&S.current!=null?dj(S.current):null,a=r?new Set(OM(S.current)):new Set,o=i?.dataset.fileTreeStickyPath??null,c=i?.dataset.fileTreeStickyRow===`true`&&o!=null;if(c&&o!==rt&&a.has(o)){let e=C.current;Me(o,e?.scrollTop??null),t.focusPath(o)}let u=t.getFocusedPath(),d=t.getFocusedIndex(),p=t.getFocusedItem();if(p==null)return;let m=hM(p)?p:null,h=u!=null&&(xt.has(u)||c&&o===u&&a.has(u)),g=e.key===`ArrowDown`||e.key===`ArrowUp`||e.key===`ArrowRight`&&m!=null&&m.isExpanded(),_=e.key===`ArrowLeft`&&h&&m!=null&&m.isExpanded(),v=C.current,y=!0;if(e.shiftKey&&e.key===`ArrowDown`)t.extendSelectionFromFocused(1);else if(e.shiftKey&&e.key===`ArrowUp`)t.extendSelectionFromFocused(-1);else if(n&&u!=null&&d>=0){let e=t.getVisibleRows(d,d)[0]??null,n=DM(u,E.current,T.current);e==null||n==null?y=!1:jt(e,u)}else if((e.ctrlKey||e.metaKey)&&gM(e))t.toggleFocusedSelection();else if((e.ctrlKey||e.metaKey)&&e.key.toLowerCase()===`a`)t.selectAllVisiblePaths();else switch(e.key){case`ArrowDown`:t.focusNextItem();break;case`ArrowUp`:t.focusPreviousItem();break;case`ArrowRight`:m==null||m.isExpanded()?t.focusNextItem():m.expand();break;case`ArrowLeft`:m!=null&&m.isExpanded()?m.collapse():t.focusParentItem();break;case`Home`:t.focusFirstItem();break;case`End`:t.focusLastItem();break;default:y=!1}if(!y)return;be(`focus`);let b=t.getFocusedPath(),x=b!=null&&(xt.has(b)||a.has(b)),w=g&&b!==u,D=n&&c&&o===u&&b===u;if((h||D)&&b!=null&&(w&&x||D))Me(b,v?.scrollTop??null),j.current=!0,me(e=>e===b?e:b);else{let t=e.key===`ArrowUp`&&h&&b!==u;b!=null&&(t||_&&b===u)?(Ne(b,AM(S.current,v,i,u,s,bt,ht)),j.current=!0,me(e=>e===b?e:b)):je()}R(e=>e+1),e.preventDefault(),e.stopPropagation()};Vj(()=>{if(!(!f||!tt)){if(Pe.current){Pe.current=!1;return}uj(w.current)}},[tt,f]),Vj(()=>{let e=x.current;switch(yj({hasRenderedInput:e!=null,previousRenamingPath:N.current,renamingPath:$e})){case`reset`:N.current=null;return;case`reveal-canonical`:$e!=null&&Nt($e,{restoreTreeFocus:!1,targetOffset:`live-overlay`});return;case`ignore`:return;case`focus-input`:e!=null&&(Te.current=null,N.current=$e,uj(e),e.select());return}},[gt.end,gt.start,$e,Nt,xt]),Vj(()=>{let e=S.current;if(e==null)return;let t=null,n=()=>{t!=null&&(clearTimeout(t),t=null)},r=()=>{let t=dj(e)?.dataset.itemPath??null;me(e=>e===t?e:t)},i=()=>{n(),j.current=!0,r()},a=i=>{let a=i.relatedTarget;if(a==null){n(),t=setTimeout(()=>{if(t=null,dj(e)!=null){r();return}j.current=!1,me(null)},0);return}if(!(a instanceof Node)||!e.contains(a)){n(),j.current=!1,me(null);return}let o=a instanceof HTMLElement?a.dataset.itemPath??null:null;me(e=>e===o?e:o)};return e.addEventListener(`focusin`,i),e.addEventListener(`focusout`,a),()=>{n(),e.removeEventListener(`focusin`,i),e.removeEventListener(`focusout`,a)}},[]),Vj(()=>{let e=S.current;e!=null&&(pt.physical.scrollTop<=0?e.dataset.scrollAtTop=`true`:delete e.dataset.scrollAtTop)},[pt.physical.scrollTop]),Vj(()=>{let e=null,n=C.current,r=b.current,i=S.current;if(n==null)return;O.current=fj(n,g);let a=()=>{let e=t.getVisibleCount(),r=pj(O.current,g),i=Math.max(0,e*s-r);n.scrollTop>i&&(n.scrollTop=i),ze(nM({controller:t,itemHeight:s,overscan:c,scrollTop:Math.min(n.scrollTop,i),stickyFolders:h,viewportHeight:r}))};if(!k.current){k.current=!0;let e=t.getFocusedIndex();if(e>=0){let r=pj(O.current,g),i=t.getVisibleRows(e,e)[0]??null;hj(n,e,s,r,h&&i!=null?Math.max(0,Math.min(i.ancestorPaths.length*s,Math.max(0,r-s))):0)}}D.current=a;let o=t.subscribe(()=>{oj(fe)&&R(e=>e+1),a()}),l=()=>{Ae.current!==!0&&(r!=null&&(r.dataset.isScrolling??=``),i!=null&&(i.dataset.isScrolling??=``),y.current=!0,e!=null&&clearTimeout(e),e=setTimeout(()=>{r!=null&&delete r.dataset.isScrolling,i!=null&&delete i.dataset.isScrolling,y.current=!1,Se(e=>e+1),e=null},50))},u=null,d=()=>{i!=null&&delete i.dataset.overlayReveal,u!=null&&(clearTimeout(u),u=null)},f=()=>{i==null||Ae.current===!0||n.scrollTop>0||(i.dataset.overlayReveal=`true`,u!=null&&clearTimeout(u),u=setTimeout(()=>{d()},200))},p=()=>{if(a(),n.scrollTop>0&&d(),we.current!=null&&y.current&&Ot.current(),Ae.current===!0){y.current=!1;return}ge(e=>e==null?e:null),l()},m=()=>{l(),f()},_=new Set([`ArrowUp`,`ArrowDown`,`ArrowLeft`,`ArrowRight`,`PageUp`,`PageDown`,`Home`,`End`,` `,`Spacebar`]),v=e=>{_.has(e.key)&&m()};n.addEventListener(`scroll`,p,{passive:!0}),n.addEventListener(`wheel`,m,{passive:!0}),n.addEventListener(`touchmove`,m,{passive:!0}),n.addEventListener(`keydown`,v);let x=typeof ResizeObserver<`u`?new ResizeObserver(e=>{O.current=(e[0]==null?null:mj(e[0]))??fj(n,g),a()}):null;return x?.observe(n),()=>{D.current=()=>{},o(),n.removeEventListener(`scroll`,p),n.removeEventListener(`wheel`,m),n.removeEventListener(`touchmove`,m),n.removeEventListener(`keydown`,v),e!=null&&clearTimeout(e),u!=null&&clearTimeout(u),r!=null&&delete r.dataset.isScrolling,i!=null&&(delete i.dataset.isScrolling,delete i.dataset.overlayReveal),y.current=!1,O.current=null,x?.disconnect()}},[t,g,s,c,h]),Vj(()=>{He||z==null||kt(!1)},[kt,He,z]);let Xt=Uj(()=>z==null?null:`${z.path}::${z.source}`,[z]);Vj(()=>{if(Xt==null){m?.clearSlotContent(Bw);return}let t=we.current;if(t==null)return;let n=v.current??_.current;if(n==null)return;let r={anchorElement:n,anchorRect:t.anchorRect??CM(n.getBoundingClientRect()),close:e=>{Ot.current(e?.restoreFocus??!0)},restoreFocus:()=>{Dt.current&&Et.current(we.current?.path??null)}},i=e?.contextMenu?.render?.(t.item,r)??null;return m?.setSlotContent(Bw,i),e?.contextMenu?.onOpen?.(t.item,r),IM(i),queueMicrotask(()=>{i==null||!i.isConnected||document.activeElement===i&&IM(i)}),()=>{m?.clearSlotContent(Bw)}},[Xt,e?.contextMenu,m]),Vj(()=>{z!=null&&t.getItem(z.path)==null&&kt()},[kt,z,t]),Vj(()=>{if(z==null)return;let e=S.current?.getRootNode(),t=e instanceof ShadowRoot?e.host:S.current,n=e=>{let n=e.target;n instanceof Node&&(SM(e)||_.current?.contains(n)!==!0&&t?.contains(n)!==!0&&kt())},r=e=>{e.key===`Escape`&&(e.preventDefault(),e.stopPropagation(),kt())};return document.addEventListener(`mousedown`,n,!0),document.addEventListener(`keydown`,r,!0),()=>{document.removeEventListener(`mousedown`,n,!0),document.removeEventListener(`keydown`,r,!0)}},[kt,z]),Vj(()=>{let e=C.current,n=S.current;if(e==null||n==null){M.current=rt;return}let r=rt==null?null:T.current.get(rt)??null,i=dj(n),a=i?.dataset.itemPath??null,o=et&&x.current===i,c=f&&w.current===i,l=te.current&&!tt,u=ne.current??0,d=Te.current,p=Ee.current,m=De.current,g=Oe.current,_=i!=null,v=j.current||_,y=M.current!==rt,b=p!=null&&p===rt&&rt!=null,E=!1,O=!1;if(it!=null&&it.id!==ee.current){ee.current=it.id;let n=it.visibleIndex,r=t.getVisibleRows(n,n)[0]??null;if(r!=null){let t=h?Math.max(0,Math.min(r.ancestorPaths.length*s,Math.max(0,ht-s))):bt;E=!0,O=gj(e,n,s,ht,yt,it.offset,t)}t.clearScrollRequest(it.id)}let k=!E&&l&&_j(e,H,s,ht,yt,u),A=!E&&d!=null&&d===rt&&_j(e,H,s,ht,yt,bt),N=!E&&m!=null&&m.path===rt&&_j(e,H,s,ht,yt,m.viewportOffset),P=!E&&g!=null&&g.path===rt&&e.scrollTop!==g.scrollTop;if(P&&(e.scrollTop=g.scrollTop),(P||O||A||N||k||v&&y&&d!==rt&&!b&&hj(e,H,s,ht,bt))&&D.current(),E){M.current=rt;return}if(!v){M.current=rt;return}if(o){M.current=rt;return}if(c&&!l){M.current=rt;return}if(r==null){l&&H>=0&&(_j(e,H,s,ht,yt,u),D.current()),M.current=rt;return}(y||l||d===rt||p===rt||m?.path===rt||g?.path===rt||a==null||a!==rt)&&(uj(r),d===rt&&(Te.current=null),p===rt&&(Ee.current=null),m?.path===rt&&(De.current=null),g?.path===rt&&(Oe.current=null),te.current=!1,ne.current=null),M.current=rt},[t,H,rt,St,s,et,tt,gt,ht,f,it,h,bt,yt,mt]);let Zt=H>=0&&H>=pt.visible.startIndex&&H<=pt.visible.endIndex,Qt=rt!=null&&_t.some(e=>$j(e.row)===rt),$t=Zt||Qt,en=We&&j.current===!0&&$t?rt:null,tn=ye===`pointer`?he:null,nn=z?.path??ke.current??tn??en??he,rn=z?.source===`right-click`;Vj(()=>{y.current&&z==null||At(Ye(nn))},[z,Ye,gt,ht,xe,_t,nn,At,mt]);let an=Wj(e=>{if(y.current||SM(e))return;let t=e.target;if(!(t instanceof HTMLElement)||t.closest?.(`[data-type="context-menu-trigger"]`)!=null)return;let n=t.closest?.(`[data-file-tree-sticky-row="true"]`),r=t.closest?.(`[data-type="item"]`),i=n instanceof HTMLElement?n.dataset.fileTreeStickyPath??null:r instanceof HTMLElement?r.dataset.itemPath??null:null;i!=null&&be(e=>e===`pointer`?e:`pointer`),ge(e=>e===i?e:i)},[]),on=Wj(()=>{ge(null)},[]);Vj(()=>{if(!at)return;let e=()=>{Vt(),t.cancelDrag()};return window.addEventListener(`dragend`,e),()=>{window.removeEventListener(`dragend`,e),Vt(),t.cancelDrag()}},[t,at]);let sn=e=>{if(!at||t.getDragSession()==null||L.current)return;let n=lM(e.target instanceof HTMLElement?e.target:null);t.setDragTarget(n),Ut(t.getDragSession()?.target??null),Gt(e.clientX,e.clientY),e.dataTransfer!=null&&(e.dataTransfer.dropEffect=`move`),e.preventDefault()},cn=e=>{if(!at||t.getDragSession()==null||L.current)return;let n=e.relatedTarget;n instanceof Node&&S.current?.contains(n)===!0||(Lt(),zt(),t.setDragTarget(null))},ln=e=>{!at||t.getDragSession()==null||L.current||(e.preventDefault(),Ht(e.clientX,e.clientY),t.completeDrag(),Rt(),Lt(),zt(),F.current=null)},un=pt.window.height,dn=pt.window.offsetTop,fn=Math.min(0,ht-un),pn=Math.min(0,ht-un-bt),mn=pe===rt||te.current,hn=rt!=null&&mn&&!St&&H>=0?mt[H]??t.getVisibleRows(H,H)[0]??null:null,gn=hn==null?null:vj(H,s,gt,un),_n=F.current,vn=lt!=null&&_n!=null&&_n.path===lt&&_n.index>=gt.start&&_n.index<=gt.end,yn=lt!=null&&_n!=null&&_n.path===lt&&!vn&&_n.path!==hn?.path?_n:null,bn=yn==null?null:vj(yn.index,s,gt,un),xn=vM((H>=0?mt[H]??t.getVisibleRows(H,H)[0]??null:null)?.ancestorPaths.at(-1)??null),Sn=tt&&rt!=null?NM(o,rt,!St):void 0,Cn=z?.path??(tt?rt:pe),wn=z?.path??he,Tn=Ye(nn),En=He&&We&&!rn&&!et&&Tn!=null&&_e!=null&&nn!=null,Dn=He&&(En||z!=null),On=z?.anchorRect,kn=On==null&&Tn!=null&&_e!=null&&(z!=null||En)?_e:null,An=On==null?kn==null?void 0:{top:`${kn}px`}:{left:`${On.left}px`,position:`fixed`,right:`auto`,top:`${On.top}px`},jn=rn?{opacity:`0`}:void 0,Mn=Wj((e,n,r,i)=>{let a=Sj({event:{ctrlKey:e.ctrlKey,metaKey:e.metaKey,shiftKey:e.shiftKey},isDirectory:n.kind===`directory`,isSearchOpen:tt,mode:i}),o=a.toggleDirectory&&n.kind===`directory`,s=o?t.resolveMountedDirectoryPathFromInput(r):null;if(o&&s==null)return;let c=s??r;switch(a.selection.kind){case`range`:t.selectPathRange(c,a.selection.additive);break;case`toggle`:t.togglePathSelectionFromInput(c);break;case`single`:t.selectOnlyMountedPathFromInput(c);break}let l=e.currentTarget instanceof HTMLElement?e.currentTarget:null,u=n.index>=pt.visible.startIndex&&n.index<=pt.visible.endIndex,d=i===`flow`&&u&&l!=null&&l.dataset.itemParked!==`true`;t.focusMountedPathFromInput(c),d&&(j.current=!0,me(e=>e===c?e:c),be(`focus`)),o&&t.toggleMountedDirectoryFromInput(c),a.closeSearch&&t.closeSearch(),a.revealCanonical&&Nt(c,{targetOffset:`sticky-parents`})},[t,tt,pt.visible.endIndex,pt.visible.startIndex,Nt]),Nn=()=>{if(y.current||!We||nn==null||Tn==null)return;let e=t.getItem(nn);e!=null&&(At(Tn),Dt.current=!0,Ce({anchorRect:null,item:{kind:e.isDirectory()?`directory`:`file`,name:Tn.getAttribute(`aria-label`)??nn,path:e.getPath()},path:e.getPath(),source:`button`}))},Pn={contextHoverPath:wn,contextMenuButtonTriggerEnabled:We,contextMenuButtonVisibility:Ge,contextMenuEnabled:He,contextMenuRightClickEnabled:Ke,contextMenuTriggerMode:Ue,controller:t,directoriesWithGitChanges:i,dragAndDropEnabled:at,draggedPathSet:st,dragTarget:ct,gitLaneActive:Xe,gitStatusByPath:n,handleRowDragEnd:qt,handleRowDragStart:Kt,handleRowTouchStart:Jt,ignoredGitDirectories:r,ignoredInheritanceCache:de,instanceId:o,itemHeight:s,onKeyDown:Yt,onRowClick:Mn,openContextMenuForRow:jt,registerButton:qe,registerRenameInput:V,renameView:Qe,renderDecorationForRow:Ct,resolveIcon:Ze,shouldSuppressContextMenu:Pt,visualFocusPath:Cn},Fn={...Pn,registerButton:Je};return $(`div`,{ref:S,id:ut,"data-file-tree-context-menu-button-visibility":He&&We?Ge:void 0,"data-file-tree-context-menu-trigger-mode":He?Ue:void 0,"data-file-tree-has-context-menu-action-lane":He&&We?`true`:void 0,"data-file-tree-has-git-lane":Xe?`true`:void 0,"data-file-tree-virtualized-root":`true`,onDragLeave:at?cn:void 0,onDragOver:at?sn:void 0,onDrop:at?ln:void 0,onKeyDown:Yt,onPointerLeave:He?on:void 0,onPointerOver:He?an:void 0,role:`tree`,tabIndex:-1,style:{outline:`none`,position:`relative`},children:[$(`style`,{"data-file-tree-guide-style":`true`,dangerouslySetInnerHTML:{__html:xn}}),$(`slot`,{name:zw,"data-type":`header-slot`}),f?$(`div`,{"data-file-tree-search-container":!0,"data-open":tt?`true`:`false`,children:$(`input`,{ref:w,"aria-activedescendant":Sn,"aria-controls":ut,placeholder:`Search…`,"data-file-tree-search-input":!0,"data-file-tree-search-input-fake-focus":Fe?`true`:void 0,value:nt,onBlur:()=>{d===`retain`&&!Le.current||t.closeSearch()},onFocus:B,onPointerDown:B,onInput:e=>{B();let n=e.currentTarget;t.setSearch(n.value)}})}):null,$(`div`,{ref:C,"data-file-tree-virtualized-scroll":`true`,children:[h&&Be&&_t.length>0?$(`div`,{"aria-hidden":`true`,"data-file-tree-sticky-overlay":`true`,children:$(`div`,{"data-file-tree-sticky-overlay-content":`true`,style:{height:`${dt}px`},children:_t.map((e,t)=>RM(Fn,e.row,`sticky:${$j(e.row)}`,{mode:`sticky`,style:{left:`0`,position:`absolute`,right:`0`,top:`${e.top}px`,zIndex:`${_t.length-t}`}}))})}):null,$(`div`,{ref:b,"data-file-tree-virtualized-list":`true`,style:{height:`${yt}px`},children:[$(`div`,{"data-file-tree-virtualized-sticky-offset":`true`,"aria-hidden":`true`,style:{height:`${dn}px`}}),$(`div`,{"data-file-tree-virtualized-sticky":`true`,style:{height:`${un}px`,top:`${fn}px`,bottom:`${pn}px`},children:[zM(Pn,gt,xt),hn!=null&&gn!=null?RM(Pn,hn,`parked:${hn.path}`,{isParked:!0,style:{left:`0`,opacity:`0`,pointerEvents:lt===hn.path?`none`:void 0,position:`absolute`,right:`0`,top:`${gn}px`}}):null,yn!=null&&bn!=null?RM(Pn,yn,`parked-drag:${yn.path}`,{isParked:!0,style:{left:`0`,opacity:`0`,pointerEvents:`none`,position:`absolute`,right:`0`,top:`${bn}px`}}):null]})]})]}),He?$(`div`,{ref:_,"data-type":`context-menu-anchor`,"data-visible":Dn?`true`:`false`,style:An,children:[$(`button`,{ref:v,type:`button`,"data-type":Vw,"aria-label":`Options`,"aria-haspopup":`menu`,"aria-expanded":z==null?`false`:`true`,"data-visible":En?`true`:`false`,onMouseDown:e=>{e.preventDefault()},onClick:e=>{if(e.preventDefault(),e.stopPropagation(),z!=null){kt();return}Nn()},tabIndex:-1,style:jn,children:$(kA,{...Ze(`file-tree-icon-ellipsis`)})}),z==null?null:$(`slot`,{name:Bw})]}):null,z==null?null:$(`div`,{"data-type":`context-menu-wash`,"aria-hidden":`true`,onMouseDownCapture:e=>{e.preventDefault(),kt()},onTouchStartCapture:e=>{e.preventDefault(),e.stopPropagation(),kt()},onTouchMoveCapture:e=>{e.preventDefault(),e.stopPropagation()},onWheelCapture:e=>{e.preventDefault(),e.stopPropagation()}})]})}var VM={hydrateRoot:(e,t)=>{wA(eA(BM,t),e)},renderRoot:(e,t)=>{CA(eA(BM,t),e)},unmountRoot:e=>{CA(null,e)}};function HM(e,t){VM.renderRoot(e,t)}function UM(e,t){VM.hydrateRoot(e,t)}function WM(e){VM.unmountRoot(e)}var GM=class{#e=new Map;#t=null;clearAll(){for(let e of this.#e.values())e.remove();this.#e.clear()}clearSlotContent(e){let t=this.#n(e);t!=null&&(t.remove(),this.#e.delete(e))}setHost(e){if(this.#t=e,e!=null){this.#i(e);for(let[e,t]of this.#e)this.#r(e,t)}}setSlotContent(e,t){let n=this.#n(e);if(n===t){t!=null&&(this.#e.set(e,t),this.#r(e,t));return}if(n?.remove(),t==null){this.#e.delete(e);return}this.#e.set(e,t),this.#r(e,t)}setSlotHtml(e,t){let n=t?.trim()??``;if(n.length===0){this.setSlotContent(e,null);return}let r=this.#n(e);if(r!=null&&r.innerHTML===n){this.#e.set(e,r),this.#r(e,r);return}let i=document.createElement(`div`);i.innerHTML=n,this.setSlotContent(e,i)}#n(e){let t=this.#e.get(e)??null;if(t!=null)return t;let n=this.#t;if(n==null)return null;for(let t of Array.from(n.children))if(t instanceof HTMLElement&&t.dataset.fileTreeManagedSlot===e)return t;return null}#r(e,t){t.slot=e,t.dataset.fileTreeManagedSlot=e,this.#t!=null&&t.parentNode!==this.#t&&this.#t.appendChild(t)}#i(e){for(let t of Array.from(e.children)){if(!(t instanceof HTMLElement))continue;let e=t.dataset.fileTreeManagedSlot;e==null||this.#e.has(e)||this.#e.set(e,t)}}},KM=`__c`,qM=`__k`,JM=`__d`,YM=`__s`,XM=/[\s\n\\/='"\0<>]/,ZM=/^(xlink|xmlns|xml)([A-Z])/,QM=/^(?:accessK|auto[A-Z]|cell|ch|col|cont|cross|dateT|encT|form[A-Z]|frame|hrefL|inputM|maxL|minL|noV|playsI|popoverT|readO|rowS|src[A-Z]|tabI|useM|item[A-Z])/,$M=/^ac|^ali|arabic|basel|cap|clipPath$|clipRule$|color|dominant|enable|fill|flood|font|glyph[^R]|horiz|image|letter|lighting|marker[^WUH]|overline|panose|pointe|paint|rendering|shape|stop|strikethrough|stroke|text[^L]|transform|underline|unicode|units|^v[^i]|^w|^xH/,eN=new Set([`draggable`,`spellcheck`]);function tN(e){e.__g===void 0?e[JM]=!0:e.__g|=8}function nN(e){e.__g===void 0?e[JM]=!1:e.__g&=-9}function rN(e){return e.__g===void 0?!0===e[JM]:!!(8&e.__g)}var iN=/["&<]/;function aN(e){if(e.length===0||!1===iN.test(e))return e;for(var t=0,n=0,r=``,i=``;n<e.length;n++){switch(e.charCodeAt(n)){case 34:i=`&quot;`;break;case 38:i=`&amp;`;break;case 60:i=`&lt;`;break;default:continue}n!==t&&(r+=e.slice(t,n)),r+=i,t=n+1}return n!==t&&(r+=e.slice(t,n)),r}var oN={},sN=new Set(`animation-iteration-count.border-image-outset.border-image-slice.border-image-width.box-flex.box-flex-group.box-ordinal-group.column-count.fill-opacity.flex.flex-grow.flex-negative.flex-order.flex-positive.flex-shrink.flood-opacity.font-weight.grid-column.grid-row.line-clamp.line-height.opacity.order.orphans.stop-opacity.stroke-dasharray.stroke-dashoffset.stroke-miterlimit.stroke-opacity.stroke-width.tab-size.widows.z-index.zoom`.split(`.`)),cN=/[A-Z]/g;function lN(e){var t=``;for(var n in e){var r=e[n];if(r!=null&&r!==``){var i=n[0]==`-`?n:oN[n]||(oN[n]=n.replace(cN,`-$&`).toLowerCase()),a=`;`;typeof r!=`number`||i.startsWith(`--`)||sN.has(i)||(a=`px;`),t=t+i+`:`+r+a}}return t||void 0}function uN(){this.__d=!0}function dN(e,t){return{__v:e,context:t,props:e.props,setState:uN,forceUpdate:uN,__d:!0,__h:[]}}function fN(e,t,n){if(!e.s){if(n instanceof pN){if(!n.s)return void(n.o=fN.bind(null,e,t));1&t&&(t=n.s),n=n.v}if(n&&n.then)return void n.then(fN.bind(null,e,t),fN.bind(null,e,2));e.s=t,e.v=n;let r=e.o;r&&r(e)}}var pN=function(){function e(){}return e.prototype.then=function(t,n){var r=new e,i=this.s;if(i){var a=1&i?t:n;if(a){try{fN(r,1,a(this.v))}catch(e){fN(r,2,e)}return r}return this}return this.o=function(e){try{var i=e.v;1&e.s?fN(r,1,t?t(i):i):n?fN(r,1,n(i)):fN(r,2,i)}catch(e){fN(r,2,e)}},r},e}(),mN,hN,gN,_N,vN={},yN=Array.isArray,bN=Object.assign,xN=``,SN=`<!--$s-->`,CN=`<!--/$s-->`;function wN(e,t){var n,r=e.type,i=!0;return e[KM]?(i=!1,(n=e[KM]).state=n[YM]):n=new r(e.props,t),e[KM]=n,n.__v=e,n.props=e.props,n.context=t,tN(n),n.state??=vN,n[YM]??(n[YM]=n.state),r.getDerivedStateFromProps?n.state=bN({},n.state,r.getDerivedStateFromProps(n.props,n.state)):i&&n.componentWillMount?(n.componentWillMount(),n.state=n[YM]===n.state?n.state:n[YM]):!i&&n.componentWillUpdate&&n.componentWillUpdate(),gN&&gN(e),n.render(n.props,n.state,t)}function TN(e,t,n,r,i,a,o){if(e==null||!0===e||!1===e||e===xN)return xN;var s=typeof e;if(s!=`object`)return s==`function`?xN:s==`string`?aN(e):e+xN;if(yN(e)){var c,l=xN;i[qM]=e;for(var u=e.length,d=0;d<u;d++){var f=e[d];if(f!=null&&typeof f!=`boolean`){var p,m=TN(f,t,n,r,i,a,o);typeof m==`string`?l+=m:(c||=Array(u),l&&c.push(l),l=xN,yN(m)?(p=c).push.apply(p,m):c.push(m))}}return c?(l&&c.push(l),c):l}if(e.constructor!==void 0)return xN;e.__=i,mN&&mN(e);var h=e.type,g=e.props;if(typeof h==`function`){var _,v,y,b=t;if(h===nA){if(`tpl`in g){for(var x=xN,S=0;S<g.tpl.length;S++)if(x+=g.tpl[S],g.exprs&&S<g.exprs.length){var C=g.exprs[S];if(C==null)continue;typeof C!=`object`||C.constructor!==void 0&&!yN(C)?x+=C:x+=TN(C,t,n,r,e,a,o)}return x}if(`UNSTABLE_comment`in g)return`<!--`+aN(g.UNSTABLE_comment)+`-->`;v=g.children}else{if((_=h.contextType)!=null){var w=t[_.__c];b=w?w.props.value:_.__}var T=h.prototype&&typeof h.prototype.render==`function`;if(T)v=wN(e,b),y=e[KM];else{e[KM]=y=dN(e,b);for(var E=0;rN(y)&&E++<25;){nN(y),gN&&gN(e);try{v=h.call(y,g,b)}catch(t){throw a&&t&&typeof t.then==`function`&&(e._suspended=!0),t}}tN(y)}if(y.getChildContext!=null&&(t=bN({},t,y.getChildContext())),T&&Rk.errorBoundaries&&(h.getDerivedStateFromError||y.componentDidCatch)){v=v!=null&&v.type===nA&&v.key==null&&v.props.tpl==null?v.props.children:v;try{return TN(v,t,n,r,e,a,!1)}catch(i){return h.getDerivedStateFromError&&(y[YM]=h.getDerivedStateFromError(i)),y.componentDidCatch&&y.componentDidCatch(i,vN),rN(y)?(v=wN(e,t),(y=e[KM]).getChildContext!=null&&(t=bN({},t,y.getChildContext())),TN(v=v!=null&&v.type===nA&&v.key==null&&v.props.tpl==null?v.props.children:v,t,n,r,e,a,o)):xN}finally{hN&&hN(e),_N&&_N(e)}}}v=v!=null&&v.type===nA&&v.key==null&&v.props.tpl==null?v.props.children:v;try{var D=TN(v,t,n,r,e,a,o);return hN&&hN(e),Rk.unmount&&Rk.unmount(e),e._suspended?typeof D==`string`?SN+D+CN:yN(D)?(D.unshift(SN),D.push(CN),D):D.then(function(e){return SN+e+CN}):D}catch(i){if(!a&&o&&o.onError){var O=function i(s){return o.onError(s,e,function(e,s){try{return TN(e,t,n,r,s,a,o)}catch(e){return i(e)}})}(i);if(O!==void 0)return O;var ee=Rk.__e;return ee&&ee(i,e),xN}if(!a||!i||typeof i.then!=`function`)throw i;return i.then(function i(){try{var s=TN(v,t,n,r,e,a,o);return e._suspended?SN+s+CN:s}catch(e){if(!e||typeof e.then!=`function`)throw e;return e.then(i)}})}}var k,A=`<`+h,j=xN;for(var M in g){var N=g[M];if(typeof(N=DN(N)?N.value:N)!=`function`||M===`class`||M===`className`){switch(M){case`children`:k=N;continue;case`key`:case`ref`:case`__self`:case`__source`:continue;case`htmlFor`:if(`for`in g)continue;M=`for`;break;case`className`:if(`class`in g)continue;M=`class`;break;case`defaultChecked`:M=`checked`;break;case`defaultSelected`:M=`selected`;break;case`defaultValue`:case`value`:switch(M=`value`,h){case`textarea`:k=N;continue;case`select`:r=N;continue;case`option`:r!=N||`selected`in g||(A+=` selected`)}break;case`dangerouslySetInnerHTML`:j=N&&N.__html;continue;case`style`:typeof N==`object`&&(N=lN(N));break;case`acceptCharset`:M=`accept-charset`;break;case`httpEquiv`:M=`http-equiv`;break;default:if(ZM.test(M))M=M.replace(ZM,`$1:$2`).toLowerCase();else{if(XM.test(M))continue;M[4]!==`-`&&!eN.has(M)||N==null?n?$M.test(M)&&(M=M===`panose1`?`panose-1`:M.replace(/([A-Z])/g,`-$1`).toLowerCase()):QM.test(M)&&(M=M.toLowerCase()):N+=xN}}N!=null&&!1!==N&&(A=!0===N||N===xN?A+` `+M:A+` `+M+`="`+(typeof N==`string`?aN(N):N+xN)+`"`)}}if(XM.test(h))throw Error(h+` is not a valid HTML tag name in `+A+`>`);if(j||(typeof k==`string`?j=aN(k):k!=null&&!1!==k&&!0!==k&&(j=TN(k,t,h===`svg`||h!==`foreignObject`&&n,r,e,a,o))),hN&&hN(e),_N&&_N(e),!j&&EN.has(h))return A+`/>`;var te=`</`+h+`>`,ne=A+`>`;return yN(j)?[ne].concat(j,[te]):typeof j==`string`?ne+j+te:[ne,j,te]}var EN=new Set([`area`,`base`,`br`,`col`,`command`,`embed`,`hr`,`img`,`input`,`keygen`,`link`,`meta`,`param`,`source`,`track`,`wbr`]);function DN(e){return typeof e==`object`&&!!e&&typeof e.peek==`function`&&`value`in e}var ON=0;function kN(e){return e!=null&&e.length>0?e:(ON+=1,`pst_ft_${ON}`)}function AN({initialVisibleRowCount:e,itemHeight:t}){return e==null?420:Math.max(0,e)*(t??Kw)}function jN(e){if(typeof document>`u`)return;let t=document.createElement(`div`);t.innerHTML=e;let n=t.querySelector(`svg`);return n instanceof SVGElement?n:void 0}function MN(e){return e.querySelector(`#file-tree-icon-chevron`)instanceof SVGElement&&e.querySelector(`#file-tree-icon-file`)instanceof SVGElement&&e.querySelector(`#file-tree-icon-dot`)instanceof SVGElement&&e.querySelector(`#file-tree-icon-lock`)instanceof SVGElement}function NN(e){return Array.from(e.children).filter(e=>e instanceof SVGElement)}var PN=class{static LoadedCustomComponent=!0;#e;#t;#n;#r;#i;#a;#o;#s;#c;#l=new GM;#u;#d;#f;#p;#m;#h;#g;#_;#v;#y=null;#b;#x=!1;#S=!1;constructor(e){let{composition:t,density:n,fileTreeSearchMode:r,gitStatus:i,id:a,initialSearchQuery:o,icons:s,itemHeight:c,onSearchChange:l,onSelectionChange:u,overscan:d,renderRowDecoration:f,renaming:p,search:m,searchBlurBehavior:h,searchFakeFocus:g,stickyFolders:_,unsafeCSS:v,initialVisibleRowCount:y,...b}=e;this.#e=t,this.#n=kN(a),this.#p=wk(i),this.#m=s,this.#h=v,this.#r=u,this.#i=f,this.#a=p!=null&&p!==!1,this.#o=h,this.#s=m===!0,this.#c=g===!0,this.#u=Gw(n,c),this.#d={itemHeight:this.#u.itemHeight,overscan:d,stickyFolders:_,initialVisibleRowCount:y},this.#t=new yk({...b,fileTreeSearchMode:r,initialSearchQuery:o,onSearchChange:l,renaming:p}),this.#v=this.#t.getSelectionVersion(),this.#y=this.#r==null?null:this.subscribe(()=>{this.#D()})}unmount(){this.#b!=null&&(WM(this.#b),delete this.#b.dataset.fileTreeVirtualizedWrapper,this.#b=void 0),this.#l.clearAll(),this.#l.setHost(null),this.#f!=null&&(delete this.#f.dataset.fileTreeVirtualized,this.#I(this.#f),this.#f=void 0)}cleanUp(){this.unmount(),this.#y?.(),this.#y=null,this.#t.destroy()}getFileTreeContainer(){return this.#f}getItem(e){return this.#t.getItem(e)}getFocusedItem(){return this.#t.getFocusedItem()}getFocusedPath(){return this.#t.getFocusedPath()}getSelectedPaths(){return this.#t.getSelectedPaths()}getComposition(){return this.#e}getItemHeight(){return this.#u.itemHeight}getDensityFactor(){return this.#u.factor}subscribe(e){let t=!1;return this.#t.subscribe(()=>{if(!t){t=!0;return}e()})}focusPath(e){this.#t.focusPath(e)}scrollToPath(e,t){this.#t.scrollToPath(e,t)}focusNearestPath(e){return this.#t.focusNearestPath(e)}add(e){this.#t.add(e)}batch(e){this.#t.batch(e)}applyGitStatusPatch(e){let t=Tk(this.#p,e);if(t===this.#p)return;this.#p=t;let n=this.#T();n!=null&&HM(n.wrapper,this.#w())}move(e,t,n){this.#t.move(e,t,n)}onMutation(e,t){return this.#t.onMutation(e,t)}setSearch(e){this.#t.setSearch(e)}openSearch(e){this.#t.openSearch(e)}closeSearch(){this.#t.closeSearch()}isSearchOpen(){return this.#t.isSearchOpen()}getSearchValue(){return this.#t.getSearchValue()}getSearchMatchingPaths(){return this.#t.getSearchMatchingPaths()}focusNextSearchMatch(){this.#t.focusNextSearchMatch()}focusPreviousSearchMatch(){this.#t.focusPreviousSearchMatch()}startRenaming(e,t){return this.#t.startRenaming(e,t)}remove(e,t){this.#t.remove(e,t)}resetPaths(e,t){Array.isArray(e)?this.#t.resetPaths(e,t):this.#t.resetPaths(e)}setComposition(e){this.#e=e;let t=this.#T();t!=null&&(this.#O(),HM(t.wrapper,this.#w()))}setGitStatus(e){let t=wk(e,this.#p);if(t===this.#p)return;this.#p=t;let n=this.#T();n!=null&&HM(n.wrapper,this.#w())}setIcons(e){this.#m=e;let t=this.#T();t!=null&&(this.#E(t.host,t.wrapper),HM(t.wrapper,this.#w()))}hydrate({fileTreeContainer:e}){let t=this.#P(e),n=this.#N(t);this.#O(),UM(n,this.#w())}render({containerWrapper:e,fileTreeContainer:t}){let n=this.#P(t??this.#f,e),r=this.#N(n);this.#O(),HM(r,this.#w())}#C(){return{initialViewportHeight:AN({initialVisibleRowCount:this.#d.initialVisibleRowCount,itemHeight:this.#d.itemHeight}),itemHeight:this.#d.itemHeight,overscan:this.#d.overscan,stickyFolders:this.#d.stickyFolders}}#w(){return{composition:this.#e,controller:this.#t,gitStatusByPath:this.#p?.statusByPath,ignoredGitDirectories:this.#p?.ignoredDirectoryPaths,directoriesWithGitChanges:this.#p?.directoriesWithChanges,icons:this.#m,instanceId:this.#n,renamingEnabled:this.#a,renderRowDecoration:this.#i,searchBlurBehavior:this.#o,searchEnabled:this.#s,searchFakeFocus:this.#c,slotHost:this.#l,...this.#C()}}#T(){let e=this.#f,t=this.#b;return e==null||t==null?null:{host:e,wrapper:t}}#E(e,t){let n=e.shadowRoot;n!=null&&(this.#k(n),this.#A(n)),this.#j(t)}#D(){let e=this.#r;if(e==null)return;let t=this.#t.getSelectionVersion();t!==this.#v&&(this.#v=t,e(this.#t.getSelectedPaths()))}#O(){let e=this.#e?.header?.render;if(e!=null){this.#l.setSlotContent(zw,e());return}this.#l.setSlotHtml(zw,this.#e?.header?.html??null)}#k(e){let t=NN(e).find(e=>MN(e)),n=jN(kw(Uw(this.#m).set));n!=null&&(t!=null&&t.outerHTML===n.outerHTML||(t==null?e.prepend(n):t.replaceWith(n)))}#A(e){let t=NN(e),n=t.find(e=>MN(e)),r=t.filter(e=>e!==n),i=Uw(this.#m).spriteSheet?.trim()??``;if(i.length===0){for(let e of r)e.remove();return}let a=jN(i);if(a==null){for(let e of r)e.remove();return}if(!(r.length===1&&r[0].outerHTML===a.outerHTML)){for(let e of r)e.remove();e.appendChild(a)}}#j(e){let t=Uw(this.#m);t.colored&&jw(t.set)?e.dataset.fileTreeColoredIcons=`true`:delete e.dataset.fileTreeColoredIcons}#M(e){let t=e.querySelector(`style[${Fw}]`);if(this.#g==null&&t instanceof HTMLStyleElement&&(this.#g=t),this.#h==null||this.#h===``){this.#g?.remove(),this.#g=void 0,this.#_=void 0;return}this.#g?.parentNode===e&&this.#_===this.#h||(this.#g??=document.createElement(`style`),this.#g.setAttribute(Fw,``),this.#g.parentNode!==e&&e.appendChild(this.#g),this.#g.textContent=Xw(this.#h),this.#_=this.#h)}#N(e){if(this.#b!=null)return this.#b;let t=e.shadowRoot;if(t==null)throw Error(`FileTree requires a shadow root`);let n=Array.from(t.children).filter(e=>e instanceof HTMLDivElement&&typeof e.dataset.fileTreeId==`string`&&e.dataset.fileTreeId.length>0),r=n.find(e=>e.dataset.fileTreeId===this.#n)??n[0];return r!=null&&(this.#n=r.dataset.fileTreeId??this.#n),this.#b=r??document.createElement(`div`),this.#b.dataset.fileTreeId=this.#n,this.#b.dataset.fileTreeVirtualizedWrapper=`true`,this.#E(e,this.#b),this.#b.parentNode!==t&&t.appendChild(this.#b),this.#b}#P(e,t){let n=e??this.#f??document.createElement(`file-tree-container`);t!=null&&n.parentNode!==t&&t.appendChild(n);let r=n.shadowRoot??n.attachShadow({mode:`open`});return nT(n,r),this.#M(r),n.dataset.fileTreeVirtualized=`true`,n.style.display=`flex`,this.#F(n),this.#l.setHost(n),this.#f=n,n}#F(e){e.style.getPropertyValue(`--trees-item-height`)===``&&(e.style.setProperty(`--trees-item-height`,`${String(this.#u.itemHeight)}px`),this.#x=!0),e.style.getPropertyValue(`--trees-density-override`)===``&&(e.style.setProperty(`--trees-density-override`,String(this.#u.factor)),this.#S=!0)}#I(e){this.#x&&=(e.style.removeProperty(`--trees-item-height`),!1),this.#S&&=(e.style.removeProperty(`--trees-density-override`),!1)}},FN=B(`<div class=file-tree-mount>`),IN=B(`<p class=empty>Load a PR to see its changed files.`),LN=`
2889
+ [data-type='item'][data-item-selected='true'] >
2890
+ :is(
2891
+ [data-item-section='icon'],
2892
+ [data-item-section='content'],
2893
+ [data-item-section='decoration'],
2894
+ [data-item-section='git']
2895
+ ) {
2896
+ color: var(--trees-selected-fg) !important;
2897
+ }
2898
+ `;function RN(e){return e.status===`added`?`added`:e.status===`removed`?`deleted`:`modified`}function zN(e){return e.join(`\0`)}function BN(e){let t,n,r=``,i=E(()=>e.files.map(e=>e.path)),a=E(()=>e.files.map(e=>({path:e.path,status:RN(e)})));return ee(()=>{if(!t)return;let o=i();r=zN(o),n=new PN({density:`compact`,flattenEmptyDirectories:!0,gitStatus:a(),initialExpansion:`open`,initialSelectedPaths:e.activePath?[e.activePath]:[],paths:o,unsafeCSS:LN,onSelectionChange:t=>{let[n]=t;n&&e.onSelect(n)}}),n.render({containerWrapper:t})}),T(()=>{let e=i(),t=zN(e);n&&t!==r&&(n.resetPaths(e,{initialExpandedPaths:e}),r=t),n?.setGitStatus(a())}),T(()=>{let t=e.activePath;if(!t)return;let r=n?.getItem(t);r&&!r.isSelected()&&r.select(),n?.scrollToPath(t,{focus:!1,offset:`nearest`})}),k(()=>{n?.cleanUp()}),z(Ot,{class:`file-tree`,get children(){return z(Ot.Content,{class:`file-tree-content`,get children(){return[(()=>{var e=FN();return Je(e=>{t=e},e),e})(),z(Te,{get when(){return e.files.length===0},get children(){return IN()}})]}})}})}var VN=B(`<ul class=grouping-warnings>`),HN=B(`<details class=grouping-progress><summary><span></span><span></span></summary><ol>`),UN=B(`<li><span class=grouping-step-state></span><span>`),WN=B(`<li>`),GN=B(`<button type=button class=group-item><strong>All changes</strong><span> groups`),KN=B(`<div class=group-list>`),qN=B(`<div class=group-empty><span class=group-empty-icon>✦</span><strong>Build a review map</strong><span>Turn this diff into focused groups.</span><button type=button class=Button>`),JN=B(`<button type=button class=group-item><strong></strong><span></span><small> files, <!> chunks`),YN=B(`<button type=button class="sidebar-toggle ToolbarButton">`),XN=B(`<div class=sidebar-title><strong>Review map</strong><span> logical groups`),ZN=B(`<div class=sidebar-content><section class="sidebar-section group-section"><div class=section-heading><h2>Groups</h2><span></span></div></section><button type=button class=section-resizer aria-label="Resize files section"title="Drag to resize files section"></button><section class="sidebar-section file-section"><div class=section-heading><h2>Files</h2><span>/`),QN=B(`<button type=button class=sidebar-resizer aria-label="Resize review sidebar"title="Drag to resize">`);function $N(e){return(()=>{var t=HN(),n=t.firstChild,r=n.firstChild,i=r.nextSibling,a=n.nextSibling;return V(i,()=>e.grouping.message??`Grouping changes`),V(a,z(we,{get each(){return e.grouping.steps},children:e=>(()=>{var t=UN(),n=t.firstChild.nextSibling;return V(n,()=>e.label),w(()=>ze(t,`data-state`,e.state)),t})()})),V(t,z(Te,{get when(){return e.grouping.warnings.length>0},get children(){var t=VN();return V(t,z(we,{get each(){return e.grouping.warnings},children:e=>(()=>{var t=WN();return V(t,e),t})()})),t}}),null),w(n=>{var i=e.grouping.state===`running`||e.grouping.warnings.length>0,a=`grouping-state ${e.grouping.state}`;return i!==n.e&&(t.open=n.e=i),a!==n.t&&He(r,n.t=a),n},{e:void 0,t:void 0}),t})()}function eP(e){return z(Ot,{class:`group-field`,get children(){return z(Ot.Content,{class:`group-field-content`,get children(){var t=KN();return V(t,z(Te,{get when(){return e.groups.length>0},get fallback(){return(()=>{var t=qN(),n=t.firstChild.nextSibling.nextSibling.nextSibling;return Ue(n,`click`,e.onGroup,!0),V(n,()=>e.grouping.state===`running`?`Grouping…`:`Group changes`),w(()=>n.disabled=e.isPending||e.grouping.state===`running`),t})()},get children(){return[(()=>{var t=GN(),n=t.firstChild.nextSibling,r=n.firstChild;return t.$$click=()=>e.onSelect(void 0),V(n,()=>e.groups.length,r),w(n=>{var r=!e.selectedGroupId,i=!e.selectedGroupId;return r!==n.e&&t.classList.toggle(`selected`,n.e=r),i!==n.t&&ze(t,`aria-pressed`,n.t=i),n},{e:void 0,t:void 0}),t})(),z(we,{get each(){return e.groups},children:t=>(()=>{var n=JN(),r=n.firstChild,i=r.nextSibling,a=i.nextSibling,o=a.firstChild,s=o.nextSibling;return s.nextSibling,n.$$click=()=>e.onSelect(t.id),V(r,()=>t.title),V(i,()=>t.summary),V(a,()=>t.files.length,o),V(a,()=>t.chunks.length,s),w(r=>{var i=t.id===e.selectedGroupId,a=t.id===e.selectedGroupId;return i!==r.e&&n.classList.toggle(`selected`,r.e=i),a!==r.t&&ze(n,`aria-pressed`,r.t=a),r},{e:void 0,t:void 0}),n})()})]}})),w(()=>t.classList.toggle(`is-empty`,e.groups.length===0)),t}})}})}function tP(e){return z(Bt,{as:`aside`,appearance:`active`,class:`review-sidebar`,get children(){return[z(Bt.TitleBar,{class:`sidebar-topbar`,get children(){return[(()=>{var t=YN();return Ue(t,`click`,e.onToggle,!0),V(t,()=>e.collapsed?`›`:`‹`),w(n=>{var r=!e.collapsed,i=e.collapsed?`Expand review sidebar`:`Collapse review sidebar`,a=e.collapsed?`Expand sidebar`:`Collapse sidebar`;return r!==n.e&&ze(t,`aria-expanded`,n.e=r),i!==n.t&&ze(t,`aria-label`,n.t=i),a!==n.a&&ze(t,`title`,n.a=a),n},{e:void 0,t:void 0,a:void 0}),t})(),(()=>{var t=XN(),n=t.firstChild.nextSibling,r=n.firstChild;return V(n,()=>e.groups.length,r),t})()]}}),(()=>{var t=ZN(),n=t.firstChild,r=n.firstChild.firstChild.nextSibling,i=n.nextSibling,a=i.nextSibling,o=a.firstChild.firstChild.nextSibling,s=o.firstChild;return V(t,z(Te,{get when(){return e.grouping.state!==`idle`},get children(){return z($N,{get grouping(){return e.grouping}})}}),n),V(r,()=>e.groups.length),V(n,z(eP,{get groups(){return e.groups},get grouping(){return e.grouping},get isPending(){return e.isPending},get onGroup(){return e.onGroup},get selectedGroupId(){return e.selectedGroupId},get onSelect(){return e.onGroupSelect}}),null),Ue(i,`pointerdown`,e.onSectionResize,!0),V(o,()=>e.files.length,s),V(o,()=>e.totalFileCount,null),V(a,z(BN,{get activePath(){return e.activeFile},get files(){return e.files},get onSelect(){return e.onFileSelect}}),null),w(n=>Ge(t,`--group-section-height: ${e.groupSectionHeight}px`,n)),t})(),(()=>{var t=QN();return Ue(t,`pointerdown`,e.onSidebarResize,!0),t})()]}})}Re([`click`,`pointerdown`]);function nP(e,t){let n=e.path.split(`/`),r=t.path.split(`/`),i=Math.min(n.length,r.length);for(let e=0;e<i;e+=1){let t=n[e],i=r[e];if(t===i)continue;let a=e<n.length-1;return a===e<r.length-1?t.localeCompare(i,void 0,{sensitivity:`base`}):a?-1:1}return n.length-r.length}function rP(e){return[...e].sort(nP)}var iP=B(`<section class=empty-state><div class="welcome-window Window -active"><header class="welcome-titlebar WindowTitleBar"><span class=WindowTitleText>PR Review</span></header><div class="welcome-content WindowContent"><div class=empty-state-copy><span class=eyebrow>LLM-assisted code review</span><h1>Review the change, not the noise.</h1><p>Load a pull request and organize its diff into focused, logical groups before you review it.</p></div><form class=empty-loader><label>Pull request URL<input class=TextBox type=text inputmode=url autocomplete=url placeholder=https://github.com/owner/repo/pull/123></label><button type=submit class=Button>`),aP=B(`<div class=error role=alert><span></span><button type=button class=Button aria-label="Dismiss error">×`),oP=B(`<section class=review-workspace>`);function sP(e){return e instanceof Error?e.message:String(e)}function cP(){let[e,t]=C(``),[n,r]=C(),[i,a]=C(),[o,s]=C(),[c,l]=C(``),[u,d]=C(!1),[f,p]=C(``),[m,h]=C(``),[g,_]=C(``),[v,y]=C(`pending`),[b,x]=C(``),[S,O]=C([]),[A,j]=C(),[M,N]=C(),[te,ne]=C(!1),[P,re]=C(!1),[ie,ae]=C(!1),[oe,F]=C(!1),[I,L]=C(292),[se,ce]=C(240),[le,ue]=C(!1),de,R,fe=0,pe=E(()=>n()?.id),me=E(()=>rP(n()?.files??[])),he=E(()=>n()?.groups.find(e=>e.id===i())),ge=E(()=>{let e=he();return e?me().filter(t=>e.files.includes(t.path)):me()}),_e=E(()=>o()??ge()[0]?.path),ve=E(()=>me().find(e=>e.path===_e())),ye=E(()=>ge().findIndex(e=>e.path===_e())),be=E(()=>me().reduce((e,t)=>e+t.additions,0)),xe=E(()=>me().reduce((e,t)=>e+t.deletions,0));T(()=>{let e=ge(),t=o();t&&!e.some(e=>e.path===t)&&s(e[0]?.path)}),T(()=>{let e=pe(),t=_e(),n=i(),r=++fe;if(!e||!t){l(``),d(!1);return}l(``),d(!0),Pr.review.getFileDiff.query({sessionId:e,path:t,groupId:n}).then(e=>{r===fe&&l(e.diff)}).catch(e=>{r===fe&&N(sP(e))}).finally(()=>{r===fe&&d(!1)})}),T(()=>{i()&&!he()&&a(void 0)}),T(()=>{if(!le())return;let e=n();if(!e)return;let t=Jt({target:{repository:e.pullRequest.repository,number:e.pullRequest.number},groupId:i(),filePath:_e()});t!==`${window.location.pathname}${window.location.search}`&&window.history.replaceState(null,``,t)}),T(()=>{let e=n(),t=e?.grouping.state===`running`?e.id:void 0;t!==R?.sessionId&&(Ee(),t&&we(t))}),k(()=>{Ee(),de?.()}),ee(()=>{(async()=>{let e=qt(window.location);try{let e=await Pr.review.getLlmSettings.query();p(e.reasoning.manifest??``),h(e.reasoning.groupAgent??``),_(e.reasoning.reducer??``)}catch(e){N(sP(e))}try{if(e)await Se(e.target,e);else{let e=await Pr.review.initialPullRequest.query();e.target&&await Se(e.target)}}catch(e){N(sP(e))}finally{ue(!0)}})()});async function Se(i,c){let u=i??Vt(e().trim());if(!u||!i&&!u.repository){N(`Enter a valid GitHub pull request URL.`);return}j(`load`),N(void 0);try{let e,i=n();if(u.repository&&i?.pullRequest.repository===u.repository&&i?.pullRequest.number===u.number&&i)e=i;else if(c&&u.repository)try{e=await Pr.review.getSession.query({sessionId:`${u.repository}#${u.number}`})}catch{e=await Pr.review.loadPullRequest.mutate({repository:u.repository,number:u.number})}else e=await Pr.review.loadPullRequest.mutate({repository:u.repository,number:u.number});let d=c?.groupId?e.groups.find(e=>e.id===c.groupId):void 0,f=rP(e.files),p=d?f.filter(e=>d.files.includes(e.path)):f,m=c?.filePath??o(),h=p.find(e=>e.path===m);D(()=>{r(e),l(``),a(d?.id),t(e.pullRequest.url),s(h?.path??p[0]?.path),y(e.decision.decision),x(e.decision.body),O([]),ne(!1),re(!1)})}catch(e){N(sP(e))}finally{j(void 0)}}function Ce(e){a(e);let t=e?me().filter(t=>n()?.groups.find(t=>t.id===e)?.files.includes(t.path)):me();t.some(e=>e.path===o())||s(t[0]?.path)}function we(e){let t={cancelled:!1,inFlight:!1,interval:0,sessionId:e},i=async()=>{if(!(t.cancelled||t.inFlight||n()?.id!==e)){t.inFlight=!0;try{let i=await Pr.review.getSession.query({sessionId:e});!t.cancelled&&n()?.id===e&&r(i)}catch(e){t.cancelled||N(sP(e))}finally{t.inFlight=!1}}};t.interval=window.setInterval(()=>{i()},750),R=t,i()}function Ee(){R&&=(R.cancelled=!0,window.clearInterval(R.interval),void 0)}async function De(){let e=n();if(e){j(`groups`),N(void 0);try{r(await Pr.review.groupChanges.mutate({sessionId:e.id}))}catch(t){try{r(await Pr.review.getSession.query({sessionId:e.id}))}catch{}N(sP(t))}finally{j(void 0)}}}async function Oe(){j(`llm-settings`),N(void 0);try{let e=await Pr.review.setLlmSettings.mutate({reasoning:{manifest:f()||void 0,groupAgent:m()||void 0,reducer:g()||void 0}});p(e.reasoning.manifest??``),h(e.reasoning.groupAgent??``),_(e.reasoning.reducer??``)}catch(e){N(sP(e))}finally{j(void 0)}}async function ke(e,t,i){let a=n(),o=_e();if(!a||!o||!i.trim())return!1;j(`comment`),N(void 0);try{return r(await Pr.review.addDraftComment.mutate({sessionId:a.id,filePath:o,line:e,side:t,body:i.trim()})),!0}catch(e){return N(sP(e)),!1}finally{j(void 0)}}async function Ae(e,t){let i=n();if(!i||!t.trim())return!1;j(`comment`),N(void 0);try{return r(await Pr.review.updateDraftComment.mutate({sessionId:i.id,commentId:e,body:t.trim()})),!0}catch(e){return N(sP(e)),!1}finally{j(void 0)}}async function je(e){let t=n();if(!t)return!1;j(`comment`),N(void 0);try{return r(await Pr.review.deleteDraftComment.mutate({sessionId:t.id,commentId:e})),!0}catch(e){return N(sP(e)),!1}finally{j(void 0)}}function Me(e){let t=ge()[ye()+e];t&&s(t.path)}function Ne(e){if(oe())return;e.preventDefault(),de?.();let t=e.clientX,n=I(),r=e=>{L(Math.min(520,Math.max(220,n+e.clientX-t)))},i=()=>{document.removeEventListener(`pointermove`,r),document.removeEventListener(`pointerup`,i),document.removeEventListener(`pointercancel`,i),document.body.classList.remove(`is-resizing-sidebar`),de=void 0};document.body.classList.add(`is-resizing-sidebar`),document.addEventListener(`pointermove`,r),document.addEventListener(`pointerup`,i),document.addEventListener(`pointercancel`,i),de=i}function Pe(e){let t=e.currentTarget.parentElement,n=t?.querySelector(`.group-section`),r=t?.querySelector(`.file-section`);if(!n||!r)return;e.preventDefault(),de?.();let i=e.clientY,a=n.getBoundingClientRect().height,o=a+r.getBoundingClientRect().height,s=Math.max(100,o-120),c=e=>{ce(Math.min(s,Math.max(100,a+e.clientY-i)))},l=()=>{document.removeEventListener(`pointermove`,c),document.removeEventListener(`pointerup`,l),document.removeEventListener(`pointercancel`,l),document.body.classList.remove(`is-resizing-sections`),de=void 0};document.body.classList.add(`is-resizing-sections`),document.addEventListener(`pointermove`,c),document.addEventListener(`pointerup`,l),document.addEventListener(`pointercancel`,l),de=l}async function Fe(){let e=n();if(e){j(`decision`),N(void 0);try{r(await Pr.review.setDecisionDraft.mutate({sessionId:e.id,decision:{decision:v(),body:b()}}))}catch(e){N(sP(e))}finally{j(void 0)}}}async function Ie(){let e=n();if(e){j(`comments`),N(void 0);try{O(await Pr.review.listCurrentComments.query({sessionId:e.id}))}catch(e){N(sP(e))}finally{j(void 0)}}}async function Le(){let e=n();if(!(!e||v()===`pending`)){j(`submit`),N(void 0);try{await Pr.review.setDecisionDraft.mutate({sessionId:e.id,decision:{decision:v(),body:b()}}),r(await Pr.review.submitReview.mutate({sessionId:e.id})),y(`pending`),x(``),O([]),ae(!1)}catch(e){N(sP(e))}finally{j(void 0)}}}return z(At,{class:`app-shell`,get children(){return[z(vC,{get groupAgentReasoning(){return m()},get isPending(){return!!A()},get manifestReasoning(){return f()},onDescriptionOpen:()=>re(!0),onGroupAgentReasoningChange:h,onLoadPullRequest:()=>void Se(),onManifestReasoningChange:p,onPickerClose:()=>ne(!1),onPickerToggle:()=>ne(!te()),onPullRequestUrlChange:t,onReducerReasoningChange:_,onReviewOpen:()=>ae(!0),onSaveLlmSettings:()=>void Oe(),get pickerOpen(){return te()},get pullRequestUrl(){return e()},get reducerReasoning(){return g()},get session(){return n()},get totalAdditions(){return be()},get totalDeletions(){return xe()}}),z(Te,{get when(){return M()},children:e=>(()=>{var t=aP(),n=t.firstChild,r=n.nextSibling;return V(n,e),r.$$click=()=>N(void 0),t})()}),z(Te,{get when(){return n()},children:e=>[(()=>{var t=oP();return V(t,z(tP,{get activeFile(){return _e()},get collapsed(){return oe()},get files(){return ge()},get groupSectionHeight(){return se()},get grouping(){return e().grouping},get groups(){return e().groups},get isPending(){return!!A()},onFileSelect:s,onGroup:()=>void De(),onGroupSelect:Ce,onSectionResize:Pe,onSidebarResize:Ne,onToggle:()=>F(!oe()),get selectedGroupId(){return i()},get totalFileCount(){return me().length}}),null),V(t,z(_y,{get activeDiff(){return c()},get activeFile(){return _e()},get activeFileIndex(){return ye()},get activeReviewFile(){return ve()},get commentPending(){return A()===`comment`},get draftComments(){return e().draftComments},get loading(){return u()},onAddComment:ke,onDeleteComment:je,onMoveFile:Me,onUpdateComment:Ae,get selectedGroup(){return he()},get visibleFileCount(){return ge().length}}),null),w(e=>{var n=!!oe(),r=`--sidebar-width: ${I()}px`;return n!==e.e&&t.classList.toggle(`sidebar-collapsed`,e.e=n),e.t=Ge(t,r,e.t),e},{e:void 0,t:void 0}),t})(),z(aC,{onClose:()=>re(!1),get open(){return P()},get session(){return e()}}),z(oC,{get currentComments(){return S()},get decision(){return v()},get isPending(){return!!A()},onClose:()=>ae(!1),onDecisionChange:y,onRefreshComments:()=>void Ie(),onReviewBodyChange:x,onSaveDraft:()=>void Fe(),onSubmit:()=>void Le(),get open(){return ie()},get reviewBody(){return b()},get session(){return e()}})]}),z(Te,{get when(){return!n()},get children(){var n=iP(),r=n.firstChild.firstChild.nextSibling.firstChild.nextSibling,i=r.firstChild,a=i.firstChild.nextSibling,o=i.nextSibling;return r.addEventListener(`submit`,e=>{e.preventDefault(),Se()}),a.$$input=e=>t(e.currentTarget.value),V(o,()=>A()===`load`?`Loading…`:`Open review`),w(()=>o.disabled=!!A()),w(()=>a.value=e()),n}})]}})}Re([`input`,`click`]);var lP=document.getElementById(`root`);if(!lP)throw Error(`Missing root element.`);Le(()=>z(cP,{}),lP);export{t};