@markusylisiurunen/tau 0.3.63 → 0.3.65
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core/config/schema.js +2 -2
- package/dist/core/config/schema.js.map +1 -1
- package/dist/core/diff_review/bridge.js +1 -1
- package/dist/core/diff_review/bridge.js.map +1 -1
- package/dist/core/diff_review/index.js.map +1 -1
- package/dist/core/diff_review/protocol.js +11 -7
- package/dist/core/diff_review/protocol.js.map +1 -1
- package/dist/core/diff_review/result_text.js +14 -4
- package/dist/core/diff_review/result_text.js.map +1 -1
- package/dist/core/diff_review/snapshot.js +13 -9
- package/dist/core/diff_review/snapshot.js.map +1 -1
- package/dist/core/static/tau_docs/config-reference.md +3 -3
- package/dist/core/static/tau_docs/configuration.md +1 -1
- package/dist/core/static/tau_docs/credentials.md +2 -2
- package/dist/core/static/tau_docs/sdk-diff-review.md +15 -6
- package/dist/core/static/tau_docs/telegram.md +2 -3
- package/dist/core/static/tau_docs/troubleshooting.md +2 -2
- package/dist/core/static/tau_docs/tui.md +4 -2
- package/dist/core/telegram/adapter.js +0 -7
- package/dist/core/telegram/adapter.js.map +1 -1
- package/dist/core/telegram/cli.js +1 -3
- package/dist/core/telegram/cli.js.map +1 -1
- package/dist/core/telegram/runtime.js +0 -1
- package/dist/core/telegram/runtime.js.map +1 -1
- package/dist/core/utils/gemini_transcription.js +510 -97
- package/dist/core/utils/gemini_transcription.js.map +1 -1
- package/dist/core/utils/openai_transcription.js +6 -34
- package/dist/core/utils/openai_transcription.js.map +1 -1
- package/dist/core/utils/speech_to_text.js +23 -14
- package/dist/core/utils/speech_to_text.js.map +1 -1
- package/dist/core/utils/speech_to_text_keywords.js +32 -0
- package/dist/core/utils/speech_to_text_keywords.js.map +1 -0
- package/dist/core/version.js +2 -2
- package/dist/diff_tool/app/dist/assets/{angular-html-Ix0KPi7a.js → angular-html-DRzRrsA1.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{angular-ts-C9FSwTpA.js → angular-ts-tbivEFEF.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{apl-DKkOnH2I.js → apl-CY7Wo94D.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{astro-DPET4gPf.js → astro-Bx9eET42.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{blade-DhJUXJLU.js → blade-MrKrcBds.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{c-67jpMvb2.js → c-C5P-tnLE.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{chapel-MBDqDT37.js → chapel-DW9xLN1i.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{cobol-M2TY0mLn.js → cobol-D5upXK5x.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{coffee-BC0bY29j.js → coffee-CH-CbdAu.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{cpp-DsCOGWNN.js → cpp-CYOejM6s.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{crystal-BCNAyK7e.js → crystal-B1PdqQ4F.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{css-Z80vApOh.js → css-B6kONN6r.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{edge-Cu-rbWZy.js → edge-DO-0gFMz.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{elixir-CAKwsmnn.js → elixir-BIwgFlwP.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{elm-CMQXUUh5.js → elm-Dbo-IffC.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{erb-B1_VD0-c.js → erb-DZ7kUx4Q.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{git-rebase-D4h0IB-Z.js → git-rebase-Cf4aQom5.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{glimmer-js-D37W__QR.js → glimmer-js-B8L9c2W6.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{glimmer-ts-CJiHgwc1.js → glimmer-ts-CzAUKEr_.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{glsl-DPWDnqEZ.js → glsl-BZnQq81v.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{graphql-BERyG10r.js → graphql-QI7m1-dG.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{hack-Dhrkqbqh.js → hack-oWgmL-1w.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{haml-CgHqro8t.js → haml-Dsp05dm-.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{handlebars-DA0oBJQC.js → handlebars-DkEP_XDs.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{html-C07_gUIM.js → html-Jb4Hlhlf.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{html-derivative-C2Iz7NdD.js → html-derivative-jFzowccf.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{http-BIjFcXtf.js → http-CIm3Kw31.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{hurl-BSo6-xEj.js → hurl-CLvYxNZa.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{index-HwJ9ZF3R.js → index-J0S24TTC.js} +19 -19
- package/dist/diff_tool/app/dist/assets/{java-CoMQRgf3.js → java-Rw3L1ZVe.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{javascript-59Bh6eFS.js → javascript-BDTOnMX6.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{jinja-BbL8kFH_.js → jinja-V3XFOf5X.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{jison-DkCA1Xy9.js → jison-DsX2fRlw.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{json-K7B9fx2M.js → json-DXtaKgIN.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{jsx-CYU0LgTf.js → jsx-C--z3Vz0.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{julia-Cek7iS3T.js → julia-CYpeWsG7.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{just-CV-zTYju.js → just-BuEYXcL7.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{latex-CumIBD1i.js → latex-Cm1B1ddK.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{liquid-6O_k925L.js → liquid-GkjL8esp.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{lua-DSabO_9y.js → lua-CvYt7dZy.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{marko-BQCJYZMU.js → marko-BMSo_3mq.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{mdc-C52qECYt.js → mdc-oSXeVlop.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{nginx-wGDK7kDX.js → nginx-WTmYQb7p.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{nim-8L0XMTBj.js → nim-DukmWsYe.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{org-qlylGQgn.js → org-B3Mg55pm.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{perl-CykLITRy.js → perl-Biyv-RCp.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{php-OrvNGJNb.js → php-DhLwDtyd.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{pug-YNEJJlsa.js → pug-Bu1fHTcb.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{qml-CcMVyzXP.js → qml-CyeLhJPf.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{r-BME81pvY.js → r-oMvZ7vof.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{razor-B6zaSHM_.js → razor-QR2R7Wy2.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{regexp-hfj_QKqr.js → regexp-Dy_006lz.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{rst-DW60Xb1U.js → rst-bSV3koz4.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{ruby-CC0ZraKC.js → ruby-D4XPeMQn.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{sas-9nl6_97c.js → sas-K00l5DQD.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{scss-Otpp0Cxe.js → scss-Cw-YxsUO.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{shellscript-DZKiAu0u.js → shellscript-Oo-I28wg.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{shellsession-CFyCG6LV.js → shellsession-D8YpK5Gt.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{soy-4B16Rf4R.js → soy-CirTT52K.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{sql-BfAjAHn7.js → sql-C8VWaiZL.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{stata-B_5JAo7J.js → stata-BJZ5oZlg.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{surrealql-B0HCK9pb.js → surrealql-cWw1kS_r.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{svelte-C0cCGsEl.js → svelte-qe4-sQol.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{templ-D1R1J2lJ.js → templ-Ttp3sKu1.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{tex--Wuw24L6.js → tex-CEAqnEVG.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{ts-tags-Dq1FPY1M.js → ts-tags-DSeRvYgh.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{tsx-VGY-Mp0k.js → tsx-BNFQ917s.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{twig-BEkxP8Q6.js → twig-Dle5Xpmn.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{typescript-CPyocJP3.js → typescript-BbQ7yQ6i.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{typst-xRIkWHxZ.js → typst-Cbf-O2WN.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{vue-C5KmXZMh.js → vue-YmceU--9.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{vue-html-xbHMTmXj.js → vue-html-qwVM617a.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{vue-vine-CArUes0e.js → vue-vine-CwQvVGBQ.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{xml-CgD7OGIH.js → xml-CjaiHDlR.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{xsl-DXL0y1Sw.js → xsl-C7AYdAd6.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{yaml-BOSKQnUw.js → yaml-BF0Ptbfs.js} +1 -1
- package/dist/diff_tool/app/dist/index.html +1 -1
- package/dist/diff_tool/http_server.js +3 -3
- package/dist/diff_tool/http_server.js.map +1 -1
- package/dist/diff_tool/review_state.js +9 -6
- package/dist/diff_tool/review_state.js.map +1 -1
- package/dist/diff_tool/shared_types.js +3 -0
- package/dist/diff_tool/shared_types.js.map +1 -1
- package/dist/sdk/diff_review.d.ts +9 -0
- package/dist/sdk/diff_review.js +9 -3
- package/dist/sdk/diff_review.js.map +1 -1
- package/dist/tui/chat_controller/diff_review_service.js +6 -2
- package/dist/tui/chat_controller/diff_review_service.js.map +1 -1
- package/dist/tui/chat_controller/diff_review_user_message.js +4 -2
- package/dist/tui/chat_controller/diff_review_user_message.js.map +1 -1
- package/dist/tui/listen_capture.js +2 -6
- package/dist/tui/listen_capture.js.map +1 -1
- package/dist/tui/session_chat_controller.js +3 -3
- package/dist/tui/session_chat_controller.js.map +1 -1
- package/package.json +8 -8
- package/dist/core/utils/mistral_transcription.js +0 -44
- package/dist/core/utils/mistral_transcription.js.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./angular-html-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./angular-html-DRzRrsA1.js","./html-Jb4Hlhlf.js","./javascript-BDTOnMX6.js","./css-B6kONN6r.js","./angular-ts-tbivEFEF.js","./scss-Cw-YxsUO.js","./apl-CY7Wo94D.js","./xml-CjaiHDlR.js","./java-Rw3L1ZVe.js","./json-DXtaKgIN.js","./astro-Bx9eET42.js","./typescript-BbQ7yQ6i.js","./postcss-BXeXVLqQ.js","./tsx-BNFQ917s.js","./blade-MrKrcBds.js","./html-derivative-jFzowccf.js","./sql-C8VWaiZL.js","./bsl-_VjlB9mv.js","./sdbl-bTVj8UrX.js","./cairo-DLTphjLi.js","./python-gzcpVVnB.js","./chapel-DW9xLN1i.js","./c-C5P-tnLE.js","./cobol-D5upXK5x.js","./coffee-CH-CbdAu.js","./cpp-CYOejM6s.js","./regexp-Dy_006lz.js","./glsl-BZnQq81v.js","./crystal-B1PdqQ4F.js","./shellscript-Oo-I28wg.js","./edge-DO-0gFMz.js","./elixir-BIwgFlwP.js","./elm-Dbo-IffC.js","./erb-DZ7kUx4Q.js","./ruby-D4XPeMQn.js","./haml-Dsp05dm-.js","./graphql-QI7m1-dG.js","./jsx-C--z3Vz0.js","./lua-CvYt7dZy.js","./yaml-BF0Ptbfs.js","./erlang-Cphh6RMH.js","./markdown-BYOwaDjH.js","./fortran-fixed-form-DEKoE2YW.js","./fortran-free-form-CYNrtFtB.js","./fsharp-D13ZGOAj.js","./gdresource-xMC7jr7x.js","./gdshader-CBce3t8t.js","./gdscript-DYvRD3hg.js","./git-commit-BSykSTBG.js","./diff-woXpYk--.js","./git-rebase-Cf4aQom5.js","./glimmer-js-B8L9c2W6.js","./glimmer-ts-CzAUKEr_.js","./hack-oWgmL-1w.js","./handlebars-DkEP_XDs.js","./http-CIm3Kw31.js","./hurl-CLvYxNZa.js","./csv-Dx-8-gkx.js","./hxml-Dcm88srW.js","./haxe-C8oCnwJJ.js","./jinja-V3XFOf5X.js","./jison-DsX2fRlw.js","./julia-CYpeWsG7.js","./r-oMvZ7vof.js","./just-BuEYXcL7.js","./perl-Biyv-RCp.js","./latex-Cm1B1ddK.js","./tex-CEAqnEVG.js","./liquid-GkjL8esp.js","./marko-BMSo_3mq.js","./less-DVTAwKKz.js","./mdc-oSXeVlop.js","./nextflow-BJtWHP5T.js","./nextflow-groovy-DJMQeKeT.js","./nginx-WTmYQb7p.js","./nim-DukmWsYe.js","./org-B3Mg55pm.js","./clojure-DqKBuwfJ.js","./csharp-oqKa8noW.js","./dart-CnvKMtbv.js","./docker-IyjqRm3v.js","./go-rLFTqkRN.js","./groovy-CacY0gHj.js","./ini-B5eOa1yu.js","./make-Dixweg8N.js","./objective-c-D1A_Heim.js","./ocaml-O90oeIOV.js","./php-DhLwDtyd.js","./vb-DOwzaHZ0.js","./raku-B3gFvitq.js","./rust-Cfkwpbl8.js","./scala-BiFt_7mu.js","./zig-CMLA9XwU.js","./xsl-C7AYdAd6.js","./pug-Bu1fHTcb.js","./qml-CyeLhJPf.js","./razor-QR2R7Wy2.js","./rst-bSV3koz4.js","./cmake-Bj61d0ZC.js","./sas-K00l5DQD.js","./shaderlab-TOUzSsQk.js","./hlsl-Cvrh5tZx.js","./shellsession-D8YpK5Gt.js","./soy-CirTT52K.js","./sparql-D_iOobhT.js","./turtle-ByJddavk.js","./stata-BJZ5oZlg.js","./surrealql-cWw1kS_r.js","./svelte-qe4-sQol.js","./templ-Ttp3sKu1.js","./ts-tags-DSeRvYgh.js","./twig-Dle5Xpmn.js","./typst-Cbf-O2WN.js","./bat-qdxAdBWQ.js","./bibtex-Ci_nEsc7.js","./jsonc-CYpm1nAK.js","./log-BNLmms1o.js","./powershell-CCSX75yM.js","./swift-CyEgAFGc.js","./system-verilog-Dh5ihWbf.js","./verilog-B2gwz-sJ.js","./vue-YmceU--9.js","./vue-html-qwVM617a.js","./vue-vine-CwQvVGBQ.js","./stylus-B6D30XZt.js"])))=>i.map(i=>d[i]);
|
|
2
2
|
var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),s=(e,n)=>{let r={};for(var i in e)t(r,i,{get:e[i],enumerable:!0});return n||t(r,Symbol.toStringTag,{value:`Module`}),r},c=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},l=(n,r,o)=>(o=n==null?{}:e(i(n)),c(r||!n||!n.__esModule||!a.call(n,`default`)?t(o,`default`,{value:n,enumerable:!0}):o,n));(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),t.credentials=e.crossOrigin===`use-credentials`?`include`:e.crossOrigin===`anonymous`?`omit`:`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var u=o((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.iterator;function m(e){return typeof e!=`object`||!e?null:(e=p&&e[p]||e[`@@iterator`],typeof e==`function`?e:null)}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,_={};function v(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function y(){}y.prototype=v.prototype;function b(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}var x=b.prototype=new y;x.constructor=b,g(x,v.prototype),x.isPureReactComponent=!0;var S=Array.isArray;function C(){}var w={H:null,A:null,T:null,S:null},T=Object.prototype.hasOwnProperty;function E(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function ee(e,t){return E(e.type,t,e.props)}function D(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function O(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var te=/\/+/g;function ne(e,t){return typeof e==`object`&&e&&e.key!=null?O(``+e.key):t.toString(36)}function re(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(C,C):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function ie(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,ie(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+ne(e,0):a,S(o)?(i=``,c!=null&&(i=c.replace(te,`$&/`)+`/`),ie(o,r,i,``,function(e){return e})):o!=null&&(D(o)&&(o=ee(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(te,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(S(e))for(var u=0;u<e.length;u++)a=e[u],s=l+ne(a,u),c+=ie(a,r,i,s,o);else if(u=m(e),typeof u==`function`)for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,s=l+ne(a,u++),c+=ie(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return ie(re(e),r,i,a,o);throw r=String(e),Error(`Objects are not valid as a React child (found: `+(r===`[object Object]`?`object with keys {`+Object.keys(e).join(`, `)+`}`:r)+`). If you meant to render a collection of children, use an array instead.`)}return c}function ae(e,t,n){if(e==null)return e;var r=[],i=0;return ie(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function oe(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t)},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var k=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},A={map:ae,forEach:function(e,t,n){ae(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return ae(e,function(){t++}),t},toArray:function(e){return ae(e,function(e){return e})||[]},only:function(e){if(!D(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=A,e.Component=v,e.Fragment=r,e.Profiler=a,e.PureComponent=b,e.StrictMode=i,e.Suspense=l,e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=w,e.__COMPILER_RUNTIME={__proto__:null,c:function(e){return w.H.useMemoCache(e)}},e.cache=function(e){return function(){return e.apply(null,arguments)}},e.cacheSignal=function(){return null},e.cloneElement=function(e,t,n){if(e==null)throw Error(`The argument must be a React element, but you passed `+e+`.`);var r=g({},e.props),i=e.key;if(t!=null)for(a in t.key!==void 0&&(i=``+t.key),t)!T.call(t,a)||a===`key`||a===`__self`||a===`__source`||a===`ref`&&t.ref===void 0||(r[a]=t[a]);var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){for(var o=Array(a),s=0;s<a;s++)o[s]=arguments[s+2];r.children=o}return E(e.type,i,r)},e.createContext=function(e){return e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:o,_context:e},e},e.createElement=function(e,t,n){var r,i={},a=null;if(t!=null)for(r in t.key!==void 0&&(a=``+t.key),t)T.call(t,r)&&r!==`key`&&r!==`__self`&&r!==`__source`&&(i[r]=t[r]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var s=Array(o),c=0;c<o;c++)s[c]=arguments[c+2];i.children=s}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)i[r]===void 0&&(i[r]=o[r]);return E(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=D,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:oe}},e.memo=function(e,t){return{$$typeof:u,type:e,compare:t===void 0?null:t}},e.startTransition=function(e){var t=w.T,n={};w.T=n;try{var r=e(),i=w.S;i!==null&&i(n,r),typeof r==`object`&&r&&typeof r.then==`function`&&r.then(C,k)}catch(e){k(e)}finally{t!==null&&n.types!==null&&(t.types=n.types),w.T=t}},e.unstable_useCacheRefresh=function(){return w.H.useCacheRefresh()},e.use=function(e){return w.H.use(e)},e.useActionState=function(e,t,n){return w.H.useActionState(e,t,n)},e.useCallback=function(e,t){return w.H.useCallback(e,t)},e.useContext=function(e){return w.H.useContext(e)},e.useDebugValue=function(){},e.useDeferredValue=function(e,t){return w.H.useDeferredValue(e,t)},e.useEffect=function(e,t){return w.H.useEffect(e,t)},e.useEffectEvent=function(e){return w.H.useEffectEvent(e)},e.useId=function(){return w.H.useId()},e.useImperativeHandle=function(e,t,n){return w.H.useImperativeHandle(e,t,n)},e.useInsertionEffect=function(e,t){return w.H.useInsertionEffect(e,t)},e.useLayoutEffect=function(e,t){return w.H.useLayoutEffect(e,t)},e.useMemo=function(e,t){return w.H.useMemo(e,t)},e.useOptimistic=function(e,t){return w.H.useOptimistic(e,t)},e.useReducer=function(e,t,n){return w.H.useReducer(e,t,n)},e.useRef=function(e){return w.H.useRef(e)},e.useState=function(e){return w.H.useState(e)},e.useSyncExternalStore=function(e,t,n){return w.H.useSyncExternalStore(e,t,n)},e.useTransition=function(){return w.H.useTransition()},e.version=`19.2.8`})),d=o(((e,t)=>{t.exports=u()})),f=o((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0<n;){var r=n-1>>>1,a=e[r];if(0<i(a,t))e[r]=t,e[n]=a,n=r;else break a}}function n(e){return e.length===0?null:e[0]}function r(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;a:for(var r=0,a=e.length,o=a>>>1;r<o;){var s=2*(r+1)-1,c=e[s],l=s+1,u=e[l];if(0>i(c,n))l<a&&0>i(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(l<a&&0>i(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m){if(n(c)!==null)m=!0,S||(S=!0,D());else{var t=n(l);t!==null&&ne(x,t.startTime-e)}}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-T<w)}function ee(){if(g=!1,S){var t=e.unstable_now();T=t;var i=!0;try{a:{m=!1,h&&(h=!1,v(C),C=-1),p=!0;var a=f;try{b:{for(b(t),d=n(c);d!==null&&!(d.expirationTime>t&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&ne(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?D():S=!1}}}var D;if(typeof y==`function`)D=function(){y(ee)};else if(typeof MessageChannel<`u`){var O=new MessageChannel,te=O.port2;O.port1.onmessage=ee,D=function(){te.postMessage(null)}}else D=function(){_(ee,0)};function ne(t,n){C=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125<e?console.error(`forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported`):w=0<e?Math.floor(1e3/e):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_requestPaint=function(){g=!0},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,i,a){var o=e.unstable_now();switch(typeof a==`object`&&a?(a=a.delay,a=typeof a==`number`&&0<a?o+a:o):a=o,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return s=a+s,r={id:u++,callback:i,priorityLevel:r,startTime:a,expirationTime:s,sortIndex:-1},a>o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,ne(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,D()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),p=o(((e,t)=>{t.exports=f()})),m=o((e=>{var t=d();function n(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function r(){}var i={d:{f:r,r:function(){throw Error(n(522))},D:r,C:r,L:r,m:r,X:r,S:r,M:r},p:0,findDOMNode:null},a=Symbol.for(`react.portal`);function o(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:a,key:r==null?null:``+r,children:e,containerInfo:t,implementation:n}}var s=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function c(e,t){if(e===`font`)return``;if(typeof t==`string`)return t===`use-credentials`?t:``}e.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=i,e.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error(n(299));return o(e,t,null,r)},e.flushSync=function(e){var t=s.T,n=i.p;try{if(s.T=null,i.p=2,e)return e()}finally{s.T=t,i.p=n,i.d.f()}},e.preconnect=function(e,t){typeof e==`string`&&(t?(t=t.crossOrigin,t=typeof t==`string`?t===`use-credentials`?t:``:void 0):t=null,i.d.C(e,t))},e.prefetchDNS=function(e){typeof e==`string`&&i.d.D(e)},e.preinit=function(e,t){if(typeof e==`string`&&t&&typeof t.as==`string`){var n=t.as,r=c(n,t.crossOrigin),a=typeof t.integrity==`string`?t.integrity:void 0,o=typeof t.fetchPriority==`string`?t.fetchPriority:void 0;n===`style`?i.d.S(e,typeof t.precedence==`string`?t.precedence:void 0,{crossOrigin:r,integrity:a,fetchPriority:o}):n===`script`&&i.d.X(e,{crossOrigin:r,integrity:a,fetchPriority:o,nonce:typeof t.nonce==`string`?t.nonce:void 0})}},e.preinitModule=function(e,t){if(typeof e==`string`){if(typeof t==`object`&&t){if(t.as==null||t.as===`script`){var n=c(t.as,t.crossOrigin);i.d.M(e,{crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0})}}else t??i.d.M(e)}},e.preload=function(e,t){if(typeof e==`string`&&typeof t==`object`&&t&&typeof t.as==`string`){var n=t.as,r=c(n,t.crossOrigin);i.d.L(e,n,{crossOrigin:r,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,type:typeof t.type==`string`?t.type:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy==`string`?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet==`string`?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes==`string`?t.imageSizes:void 0,media:typeof t.media==`string`?t.media:void 0})}},e.preloadModule=function(e,t){if(typeof e==`string`){if(t){var n=c(t.as,t.crossOrigin);i.d.m(e,{as:typeof t.as==`string`&&t.as!==`script`?t.as:void 0,crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0})}else i.d.m(e)}},e.requestFormReset=function(e){i.d.r(e)},e.unstable_batchedUpdates=function(e,t){return e(t)},e.useFormState=function(e,t,n){return s.H.useFormState(e,t,n)},e.useFormStatus=function(){return s.H.useHostTransitionStatus()},e.version=`19.2.8`})),h=o(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=m()})),g=o((e=>{var t=p(),n=d(),r=h();function i(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function a(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function o(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function s(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function c(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function l(e){if(o(e)!==e)throw Error(i(188))}function u(e){var t=e.alternate;if(!t){if(t=o(e),t===null)throw Error(i(188));return t===e?e:null}for(var n=e,r=t;;){var a=n.return;if(a===null)break;var s=a.alternate;if(s===null){if(r=a.return,r!==null){n=r;continue}break}if(a.child===s.child){for(s=a.child;s;){if(s===n)return l(a),e;if(s===r)return l(a),t;s=s.sibling}throw Error(i(188))}if(n.return!==r.return)n=a,r=s;else{for(var c=!1,u=a.child;u;){if(u===n){c=!0,n=a,r=s;break}if(u===r){c=!0,r=a,n=s;break}u=u.sibling}if(!c){for(u=s.child;u;){if(u===n){c=!0,n=s,r=a;break}if(u===r){c=!0,r=s,n=a;break}u=u.sibling}if(!c)throw Error(i(189))}}if(n.alternate!==r)throw Error(i(190))}if(n.tag!==3)throw Error(i(188));return n.stateNode.current===n?e:t}function f(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=f(e),t!==null)return t;e=e.sibling}return null}var m=Object.assign,g=Symbol.for(`react.element`),_=Symbol.for(`react.transitional.element`),v=Symbol.for(`react.portal`),y=Symbol.for(`react.fragment`),b=Symbol.for(`react.strict_mode`),x=Symbol.for(`react.profiler`),S=Symbol.for(`react.consumer`),C=Symbol.for(`react.context`),w=Symbol.for(`react.forward_ref`),T=Symbol.for(`react.suspense`),E=Symbol.for(`react.suspense_list`),ee=Symbol.for(`react.memo`),D=Symbol.for(`react.lazy`),O=Symbol.for(`react.activity`),te=Symbol.for(`react.memo_cache_sentinel`),ne=Symbol.iterator;function re(e){return typeof e!=`object`||!e?null:(e=ne&&e[ne]||e[`@@iterator`],typeof e==`function`?e:null)}var ie=Symbol.for(`react.client.reference`);function ae(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===ie?null:e.displayName||e.name||null;if(typeof e==`string`)return e;switch(e){case y:return`Fragment`;case x:return`Profiler`;case b:return`StrictMode`;case T:return`Suspense`;case E:return`SuspenseList`;case O:return`Activity`}if(typeof e==`object`)switch(e.$$typeof){case v:return`Portal`;case C:return e.displayName||`Context`;case S:return(e._context.displayName||`Context`)+`.Consumer`;case w:var t=e.render;return e=e.displayName,e||=(e=t.displayName||t.name||``,e===``?`ForwardRef`:`ForwardRef(`+e+`)`),e;case ee:return t=e.displayName||null,t===null?ae(e.type)||`Memo`:t;case D:t=e._payload,e=e._init;try{return ae(e(t))}catch{}}return null}var oe=Array.isArray,k=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,A=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,se={pending:!1,data:null,method:null,action:null},ce=[],le=-1;function ue(e){return{current:e}}function de(e){0>le||(e.current=ce[le],ce[le]=null,le--)}function j(e,t){le++,ce[le]=e.current,e.current=t}var fe=ue(null),pe=ue(null),me=ue(null),he=ue(null);function ge(e,t){switch(j(me,t),j(pe,e),j(fe,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Gd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Gd(t),e=Kd(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}de(fe),j(fe,e)}function _e(){de(fe),de(pe),de(me)}function ve(e){e.memoizedState!==null&&j(he,e);var t=fe.current,n=Kd(t,e.type);t!==n&&(j(pe,e),j(fe,n))}function ye(e){pe.current===e&&(de(fe),de(pe)),he.current===e&&(de(he),np._currentValue=se)}var be,xe;function Se(e){if(be===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);be=t&&t[1]||``,xe=-1<e.stack.indexOf(`
|
|
3
3
|
at`)?` (<anonymous>)`:-1<e.stack.indexOf(`@`)?`@unknown:0:0`:``}return`
|
|
4
4
|
`+be+e+xe}var Ce=!1;function we(e,t){if(!e||Ce)return``;Ce=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,"props",{set:function(){throw Error()}}),typeof Reflect==`object`&&Reflect.construct){try{Reflect.construct(n,[])}catch(e){var r=e}Reflect.construct(e,[],n)}else{try{n.call()}catch(e){r=e}e.call(n.prototype)}}else{try{throw Error()}catch(e){r=e}(n=e())&&typeof n.catch==`function`&&n.catch(function(){})}}catch(e){if(e&&r&&typeof e.stack==`string`)return[e.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName=`DetermineComponentFrameRoot`;var i=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,`name`);i&&i.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,"name",{value:`DetermineComponentFrameRoot`});var a=r.DetermineComponentFrameRoot(),o=a[0],s=a[1];if(o&&s){var c=o.split(`
|
|
@@ -7,7 +7,7 @@ var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=
|
|
|
7
7
|
`+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(`<anonymous>`)&&(u=u.replace(`<anonymous>`,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{Ce=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?Se(n):``}function Te(e,t){switch(e.tag){case 26:case 27:case 5:return Se(e.type);case 16:return Se(`Lazy`);case 13:return e.child!==t&&t!==null?Se(`Suspense Fallback`):Se(`Suspense`);case 19:return Se(`SuspenseList`);case 0:case 15:return we(e.type,!1);case 11:return we(e.type.render,!1);case 1:return we(e.type,!0);case 31:return Se(`Activity`);default:return``}}function Ee(e){try{var t=``,n=null;do t+=Te(e,n),n=e,e=e.return;while(e);return t}catch(e){return`
|
|
8
8
|
Error generating stack: `+e.message+`
|
|
9
9
|
`+e.stack}}var De=Object.prototype.hasOwnProperty,Oe=t.unstable_scheduleCallback,ke=t.unstable_cancelCallback,Ae=t.unstable_shouldYield,je=t.unstable_requestPaint,Me=t.unstable_now,Ne=t.unstable_getCurrentPriorityLevel,Pe=t.unstable_ImmediatePriority,Fe=t.unstable_UserBlockingPriority,Ie=t.unstable_NormalPriority,Le=t.unstable_LowPriority,Re=t.unstable_IdlePriority,ze=t.log,Be=t.unstable_setDisableYieldValue,Ve=null,He=null;function Ue(e){if(typeof ze==`function`&&Be(e),He&&typeof He.setStrictMode==`function`)try{He.setStrictMode(Ve,e)}catch{}}var We=Math.clz32?Math.clz32:qe,Ge=Math.log,Ke=Math.LN2;function qe(e){return e>>>=0,e===0?32:31-(Ge(e)/Ke|0)|0}var Je=256,Ye=262144,Xe=4194304;function Ze(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Qe(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=Ze(n))):i=Ze(o):i=Ze(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=Ze(n))):i=Ze(o)):i=Ze(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function $e(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function et(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function tt(){var e=Xe;return Xe<<=1,!(Xe&62914560)&&(Xe=4194304),e}function nt(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function rt(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function it(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0<n;){var u=31-We(n),d=1<<u;s[u]=0,c[u]=-1;var f=l[u];if(f!==null)for(l[u]=null,u=0;u<f.length;u++){var p=f[u];p!==null&&(p.lane&=-536870913)}n&=~d}r!==0&&at(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function at(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-We(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function ot(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-We(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function st(e,t){var n=t&-t;return n=n&42?1:ct(n),(n&(e.suspendedLanes|t))===0?n:0}function ct(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function M(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function lt(){var e=A.p;return e===0?(e=window.event,e===void 0?32:vp(e.type)):e}function ut(e,t){var n=A.p;try{return A.p=e,t()}finally{A.p=n}}var dt=Math.random().toString(36).slice(2),ft=`__reactFiber$`+dt,pt=`__reactProps$`+dt,mt=`__reactContainer$`+dt,ht=`__reactEvents$`+dt,gt=`__reactListeners$`+dt,_t=`__reactHandles$`+dt,vt=`__reactResources$`+dt,yt=`__reactMarker$`+dt;function bt(e){delete e[ft],delete e[pt],delete e[ht],delete e[gt],delete e[_t]}function xt(e){var t=e[ft];if(t)return t;for(var n=e.parentNode;n;){if(t=n[mt]||n[ft]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=hf(e);e!==null;){if(n=e[ft])return n;e=hf(e)}return t}e=n,n=e.parentNode}return null}function St(e){if(e=e[ft]||e[mt]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function Ct(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(i(33))}function wt(e){var t=e[vt];return t||=e[vt]={hoistableStyles:new Map,hoistableScripts:new Map},t}function Tt(e){e[yt]=!0}var Et=new Set,Dt={};function Ot(e,t){kt(e,t),kt(e+`Capture`,t)}function kt(e,t){for(Dt[e]=t,e=0;e<t.length;e++)Et.add(t[e])}var At=RegExp(`^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$`),jt={},Mt={};function Nt(e){return De.call(Mt,e)?!0:De.call(jt,e)?!1:At.test(e)?Mt[e]=!0:(jt[e]=!0,!1)}function Pt(e,t,n){if(Nt(t)){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:e.removeAttribute(t);return;case`boolean`:var r=t.toLowerCase().slice(0,5);if(r!==`data-`&&r!==`aria-`){e.removeAttribute(t);return}}e.setAttribute(t,``+n)}}}function Ft(e,t,n){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(t);return}e.setAttribute(t,``+n)}}function It(e,t,n,r){if(r===null)e.removeAttribute(n);else{switch(typeof r){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(n);return}e.setAttributeNS(t,n,``+r)}}function Lt(e){switch(typeof e){case`bigint`:case`boolean`:case`number`:case`string`:case`undefined`:return e;case`object`:return e;default:return``}}function Rt(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()===`input`&&(t===`checkbox`||t===`radio`)}function zt(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&r!==void 0&&typeof r.get==`function`&&typeof r.set==`function`){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){n=``+e,a.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=``+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Bt(e){if(!e._valueTracker){var t=Rt(e)?`checked`:`value`;e._valueTracker=zt(e,t,``+e[t])}}function Vt(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r=``;return e&&(r=Rt(e)?e.checked?`true`:`false`:e.value),e=r,e!==n&&(t.setValue(e),!0)}function Ht(e){if(e||=typeof document<`u`?document:void 0,e===void 0)return null;try{return e.activeElement||e.body}catch{return e.body}}var Ut=/[\n"\\]/g;function Wt(e){return e.replace(Ut,function(e){return`\\`+e.charCodeAt(0).toString(16)+` `})}function Gt(e,t,n,r,i,a,o,s){e.name=``,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`?e.type=o:e.removeAttribute(`type`),t==null?o!==`submit`&&o!==`reset`||e.removeAttribute(`value`):o===`number`?(t===0&&e.value===``||e.value!=t)&&(e.value=``+Lt(t)):e.value!==``+Lt(t)&&(e.value=``+Lt(t)),t==null?n==null?r!=null&&e.removeAttribute(`value`):qt(e,o,Lt(n)):qt(e,o,Lt(t)),i==null&&a!=null&&(e.defaultChecked=!!a),i!=null&&(e.checked=i&&typeof i!=`function`&&typeof i!=`symbol`),s!=null&&typeof s!=`function`&&typeof s!=`symbol`&&typeof s!=`boolean`?e.name=``+Lt(s):e.removeAttribute(`name`)}function Kt(e,t,n,r,i,a,o,s){if(a!=null&&typeof a!=`function`&&typeof a!=`symbol`&&typeof a!=`boolean`&&(e.type=a),t!=null||n!=null){if(!(a!==`submit`&&a!==`reset`||t!=null)){Bt(e);return}n=n==null?``:``+Lt(n),t=t==null?n:``+Lt(t),s||t===e.value||(e.value=t),e.defaultValue=t}r??=i,r=typeof r!=`function`&&typeof r!=`symbol`&&!!r,e.checked=s?e.checked:!!r,e.defaultChecked=!!r,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`&&(e.name=o),Bt(e)}function qt(e,t,n){t===`number`&&Ht(e.ownerDocument)===e||e.defaultValue===``+n||(e.defaultValue=``+n)}function Jt(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t[`$`+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty(`$`+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=``+Lt(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function Yt(e,t,n){if(t!=null&&(t=``+Lt(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n==null?``:``+Lt(n)}function Xt(e,t,n,r){if(t==null){if(r!=null){if(n!=null)throw Error(i(92));if(oe(r)){if(1<r.length)throw Error(i(93));r=r[0]}n=r}n??=``,t=n}n=Lt(t),e.defaultValue=n,r=e.textContent,r===n&&r!==``&&r!==null&&(e.value=r),Bt(e)}function Zt(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Qt=new Set(`animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp`.split(` `));function $t(e,t,n){var r=t.indexOf(`--`)===0;n==null||typeof n==`boolean`||n===``?r?e.setProperty(t,``):t===`float`?e.cssFloat=``:e[t]=``:r?e.setProperty(t,n):typeof n!=`number`||n===0||Qt.has(t)?t===`float`?e.cssFloat=n:e[t]=(``+n).trim():e[t]=n+`px`}function en(e,t,n){if(t!=null&&typeof t!=`object`)throw Error(i(62));if(e=e.style,n!=null){for(var r in n)!n.hasOwnProperty(r)||t!=null&&t.hasOwnProperty(r)||(r.indexOf(`--`)===0?e.setProperty(r,``):r===`float`?e.cssFloat=``:e[r]=``);for(var a in t)r=t[a],t.hasOwnProperty(a)&&n[a]!==r&&$t(e,a,r)}else for(var o in t)t.hasOwnProperty(o)&&$t(e,o,t[o])}function tn(e){if(e.indexOf(`-`)===-1)return!1;switch(e){case`annotation-xml`:case`color-profile`:case`font-face`:case`font-face-src`:case`font-face-uri`:case`font-face-format`:case`font-face-name`:case`missing-glyph`:return!1;default:return!0}}var nn=new Map([[`acceptCharset`,`accept-charset`],[`htmlFor`,`for`],[`httpEquiv`,`http-equiv`],[`crossOrigin`,`crossorigin`],[`accentHeight`,`accent-height`],[`alignmentBaseline`,`alignment-baseline`],[`arabicForm`,`arabic-form`],[`baselineShift`,`baseline-shift`],[`capHeight`,`cap-height`],[`clipPath`,`clip-path`],[`clipRule`,`clip-rule`],[`colorInterpolation`,`color-interpolation`],[`colorInterpolationFilters`,`color-interpolation-filters`],[`colorProfile`,`color-profile`],[`colorRendering`,`color-rendering`],[`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`],[`horizAdvX`,`horiz-adv-x`],[`horizOriginX`,`horiz-origin-x`],[`imageRendering`,`image-rendering`],[`letterSpacing`,`letter-spacing`],[`lightingColor`,`lighting-color`],[`markerEnd`,`marker-end`],[`markerMid`,`marker-mid`],[`markerStart`,`marker-start`],[`overlinePosition`,`overline-position`],[`overlineThickness`,`overline-thickness`],[`paintOrder`,`paint-order`],[`panose-1`,`panose-1`],[`pointerEvents`,`pointer-events`],[`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`],[`textAnchor`,`text-anchor`],[`textDecoration`,`text-decoration`],[`textRendering`,`text-rendering`],[`transformOrigin`,`transform-origin`],[`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`],[`xmlnsXlink`,`xmlns:xlink`],[`xHeight`,`x-height`]]),rn=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function an(e){return rn.test(``+e)?`javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')`:e}function on(){}var sn=null;function cn(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var ln=null,un=null;function dn(e){var t=St(e);if(t&&(e=t.stateNode)){var n=e[pt]||null;a:switch(e=t.stateNode,t.type){case`input`:if(Gt(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,n.type===`radio`&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll(`input[name="`+Wt(``+t)+`"][type="radio"]`),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var a=r[pt]||null;if(!a)throw Error(i(90));Gt(r,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(t=0;t<n.length;t++)r=n[t],r.form===e.form&&Vt(r)}break a;case`textarea`:Yt(e,n.value,n.defaultValue);break a;case`select`:t=n.value,t!=null&&Jt(e,!!n.multiple,t,!1)}}}var fn=!1;function pn(e,t,n){if(fn)return e(t,n);fn=!0;try{return e(t)}finally{if(fn=!1,(ln!==null||un!==null)&&(Tu(),ln&&(t=ln,e=un,un=ln=null,dn(t),e)))for(t=0;t<e.length;t++)dn(e[t])}}function mn(e,t){var n=e.stateNode;if(n===null)return null;var r=n[pt]||null;if(r===null)return null;n=r[t];a:switch(t){case`onClick`:case`onClickCapture`:case`onDoubleClick`:case`onDoubleClickCapture`:case`onMouseDown`:case`onMouseDownCapture`:case`onMouseMove`:case`onMouseMoveCapture`:case`onMouseUp`:case`onMouseUpCapture`:case`onMouseEnter`:(r=!r.disabled)||(e=e.type,r=e!==`button`&&e!==`input`&&e!==`select`&&e!==`textarea`),e=!r;break a;default:e=!1}if(e)return null;if(n&&typeof n!=`function`)throw Error(i(231,t,typeof n));return n}var hn=!(typeof window>`u`||window.document===void 0||window.document.createElement===void 0),gn=!1;if(hn)try{var _n={};Object.defineProperty(_n,"passive",{get:function(){gn=!0}}),window.addEventListener(`test`,_n,_n),window.removeEventListener(`test`,_n,_n)}catch{gn=!1}var vn=null,yn=null,bn=null;function xn(){if(bn)return bn;var e,t=yn,n=t.length,r,i=`value`in vn?vn.value:vn.textContent,a=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[a-r];r++);return bn=i.slice(e,1<r?1-r:void 0)}function Sn(e){var t=e.keyCode;return`charCode`in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Cn(){return!0}function wn(){return!1}function Tn(e){function t(t,n,r,i,a){for(var o in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=a,this.currentTarget=null,e)e.hasOwnProperty(o)&&(t=e[o],this[o]=t?t(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented==null?!1===i.returnValue:i.defaultPrevented)?Cn:wn,this.isPropagationStopped=wn,this}return m(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():typeof e.returnValue!=`unknown`&&(e.returnValue=!1),this.isDefaultPrevented=Cn)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!=`unknown`&&(e.cancelBubble=!0),this.isPropagationStopped=Cn)},persist:function(){},isPersistent:Cn}),t}var En={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Dn=Tn(En),On=m({},En,{view:0,detail:0}),kn=Tn(On),An,jn,Mn,Nn=m({},On,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Wn,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return`movementX`in e?e.movementX:(e!==Mn&&(Mn&&e.type===`mousemove`?(An=e.screenX-Mn.screenX,jn=e.screenY-Mn.screenY):jn=An=0,Mn=e),An)},movementY:function(e){return`movementY`in e?e.movementY:jn}}),Pn=Tn(Nn),Fn=Tn(m({},Nn,{dataTransfer:0})),In=Tn(m({},On,{relatedTarget:0})),Ln=Tn(m({},En,{animationName:0,elapsedTime:0,pseudoElement:0})),Rn=Tn(m({},En,{clipboardData:function(e){return`clipboardData`in e?e.clipboardData:window.clipboardData}})),zn=Tn(m({},En,{data:0})),Bn={Esc:`Escape`,Spacebar:` `,Left:`ArrowLeft`,Up:`ArrowUp`,Right:`ArrowRight`,Down:`ArrowDown`,Del:`Delete`,Win:`OS`,Menu:`ContextMenu`,Apps:`ContextMenu`,Scroll:`ScrollLock`,MozPrintableKey:`Unidentified`},Vn={8:`Backspace`,9:`Tab`,12:`Clear`,13:`Enter`,16:`Shift`,17:`Control`,18:`Alt`,19:`Pause`,20:`CapsLock`,27:`Escape`,32:` `,33:`PageUp`,34:`PageDown`,35:`End`,36:`Home`,37:`ArrowLeft`,38:`ArrowUp`,39:`ArrowRight`,40:`ArrowDown`,45:`Insert`,46:`Delete`,112:`F1`,113:`F2`,114:`F3`,115:`F4`,116:`F5`,117:`F6`,118:`F7`,119:`F8`,120:`F9`,121:`F10`,122:`F11`,123:`F12`,144:`NumLock`,145:`ScrollLock`,224:`Meta`},Hn={Alt:`altKey`,Control:`ctrlKey`,Meta:`metaKey`,Shift:`shiftKey`};function Un(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Hn[e])?!!t[e]:!1}function Wn(){return Un}var Gn=Tn(m({},On,{key:function(e){if(e.key){var t=Bn[e.key]||e.key;if(t!==`Unidentified`)return t}return e.type===`keypress`?(e=Sn(e),e===13?`Enter`:String.fromCharCode(e)):e.type===`keydown`||e.type===`keyup`?Vn[e.keyCode]||`Unidentified`:``},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Wn,charCode:function(e){return e.type===`keypress`?Sn(e):0},keyCode:function(e){return e.type===`keydown`||e.type===`keyup`?e.keyCode:0},which:function(e){return e.type===`keypress`?Sn(e):e.type===`keydown`||e.type===`keyup`?e.keyCode:0}})),Kn=Tn(m({},Nn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),qn=Tn(m({},On,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Wn})),Jn=Tn(m({},En,{propertyName:0,elapsedTime:0,pseudoElement:0})),Yn=Tn(m({},Nn,{deltaX:function(e){return`deltaX`in e?e.deltaX:`wheelDeltaX`in e?-e.wheelDeltaX:0},deltaY:function(e){return`deltaY`in e?e.deltaY:`wheelDeltaY`in e?-e.wheelDeltaY:`wheelDelta`in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0})),Xn=Tn(m({},En,{newState:0,oldState:0})),Zn=[9,13,27,32],Qn=hn&&`CompositionEvent`in window,$n=null;hn&&`documentMode`in document&&($n=document.documentMode);var er=hn&&`TextEvent`in window&&!$n,tr=hn&&(!Qn||$n&&8<$n&&11>=$n),nr=` `,rr=!1;function ir(e,t){switch(e){case`keyup`:return Zn.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function ar(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var or=!1;function sr(e,t){switch(e){case`compositionend`:return ar(t);case`keypress`:return t.which===32?(rr=!0,nr):null;case`textInput`:return e=t.data,e===nr&&rr?null:e;default:return null}}function cr(e,t){if(or)return e===`compositionend`||!Qn&&ir(e,t)?(e=xn(),bn=yn=vn=null,or=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case`compositionend`:return tr&&t.locale!==`ko`?null:t.data;default:return null}}var lr={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function ur(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t===`input`?!!lr[e.type]:t===`textarea`}function dr(e,t,n,r){ln?un?un.push(r):un=[r]:ln=r,t=Ad(t,`onChange`),0<t.length&&(n=new Dn(`onChange`,`change`,null,n,r),e.push({event:n,listeners:t}))}var fr=null,pr=null;function mr(e){q(e,0)}function hr(e){if(Vt(Ct(e)))return e}function gr(e,t){if(e===`change`)return t}var _r=!1;if(hn){var vr;if(hn){var yr=`oninput`in document;if(!yr){var br=document.createElement(`div`);br.setAttribute(`oninput`,`return;`),yr=typeof br.oninput==`function`}vr=yr}else vr=!1;_r=vr&&(!document.documentMode||9<document.documentMode)}function xr(){fr&&(fr.detachEvent(`onpropertychange`,Sr),pr=fr=null)}function Sr(e){if(e.propertyName===`value`&&hr(pr)){var t=[];dr(t,pr,e,cn(e)),pn(mr,t)}}function Cr(e,t,n){e===`focusin`?(xr(),fr=t,pr=n,fr.attachEvent(`onpropertychange`,Sr)):e===`focusout`&&xr()}function wr(e){if(e===`selectionchange`||e===`keyup`||e===`keydown`)return hr(pr)}function Tr(e,t){if(e===`click`)return hr(t)}function Er(e,t){if(e===`input`||e===`change`)return hr(t)}function Dr(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var Or=typeof Object.is==`function`?Object.is:Dr;function kr(e,t){if(Or(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!De.call(t,i)||!Or(e[i],t[i]))return!1}return!0}function Ar(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function jr(e,t){var n=Ar(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=Ar(n)}}function Mr(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Mr(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Nr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Ht(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=Ht(e.document)}return t}function Pr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var Fr=hn&&`documentMode`in document&&11>=document.documentMode,Ir=null,Lr=null,Rr=null,zr=!1;function Br(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;zr||Ir==null||Ir!==Ht(r)||(r=Ir,`selectionStart`in r&&Pr(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Rr&&kr(Rr,r)||(Rr=r,r=Ad(Lr,`onSelect`),0<r.length&&(t=new Dn(`onSelect`,`select`,null,t,n),e.push({event:t,listeners:r}),t.target=Ir)))}function Vr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit`+e]=`webkit`+t,n[`Moz`+e]=`moz`+t,n}var Hr={animationend:Vr(`Animation`,`AnimationEnd`),animationiteration:Vr(`Animation`,`AnimationIteration`),animationstart:Vr(`Animation`,`AnimationStart`),transitionrun:Vr(`Transition`,`TransitionRun`),transitionstart:Vr(`Transition`,`TransitionStart`),transitioncancel:Vr(`Transition`,`TransitionCancel`),transitionend:Vr(`Transition`,`TransitionEnd`)},Ur={},Wr={};hn&&(Wr=document.createElement(`div`).style,`AnimationEvent`in window||(delete Hr.animationend.animation,delete Hr.animationiteration.animation,delete Hr.animationstart.animation),`TransitionEvent`in window||delete Hr.transitionend.transition);function Gr(e){if(Ur[e])return Ur[e];if(!Hr[e])return e;var t=Hr[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Wr)return Ur[e]=t[n];return e}var Kr=Gr(`animationend`),qr=Gr(`animationiteration`),Jr=Gr(`animationstart`),Yr=Gr(`transitionrun`),Xr=Gr(`transitionstart`),Zr=Gr(`transitioncancel`),Qr=Gr(`transitionend`),$r=new Map,ei=`abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel`.split(` `);ei.push(`scrollEnd`);function ti(e,t){$r.set(e,t),Ot(t,[e])}var ni=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},ri=[],ii=0,ai=0;function oi(){for(var e=ii,t=ai=ii=0;t<e;){var n=ri[t];ri[t++]=null;var r=ri[t];ri[t++]=null;var i=ri[t];ri[t++]=null;var a=ri[t];if(ri[t++]=null,r!==null&&i!==null){var o=r.pending;o===null?i.next=i:(i.next=o.next,o.next=i),r.pending=i}a!==0&&ui(n,i,a)}}function si(e,t,n,r){ri[ii++]=e,ri[ii++]=t,ri[ii++]=n,ri[ii++]=r,ai|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function ci(e,t,n,r){return si(e,t,n,r),di(e)}function li(e,t){return si(e,null,null,t),di(e)}function ui(e,t,n){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n);for(var i=!1,a=e.return;a!==null;)a.childLanes|=n,r=a.alternate,r!==null&&(r.childLanes|=n),a.tag===22&&(e=a.stateNode,e===null||e._visibility&1||(i=!0)),e=a,a=a.return;return e.tag===3?(a=e.stateNode,i&&t!==null&&(i=31-We(n),e=a.hiddenUpdates,r=e[i],r===null?e[i]=[t]:r.push(t),t.lane=n|536870912),a):null}function di(e){if(50<gu)throw gu=0,_u=null,Error(i(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var fi={};function pi(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function mi(e,t,n,r){return new pi(e,t,n,r)}function hi(e){return e=e.prototype,!(!e||!e.isReactComponent)}function gi(e,t){var n=e.alternate;return n===null?(n=mi(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&65011712,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function _i(e,t){e.flags&=65011714;var n=e.alternate;return n===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function vi(e,t,n,r,a,o){var s=0;if(r=e,typeof e==`function`)hi(e)&&(s=1);else if(typeof e==`string`)s=qf(e,n,fe.current)?26:e===`html`||e===`head`||e===`body`?27:5;else a:switch(e){case O:return e=mi(31,n,t,a),e.elementType=O,e.lanes=o,e;case y:return yi(n.children,a,o,t);case b:s=8,a|=24;break;case x:return e=mi(12,n,t,a|2),e.elementType=x,e.lanes=o,e;case T:return e=mi(13,n,t,a),e.elementType=T,e.lanes=o,e;case E:return e=mi(19,n,t,a),e.elementType=E,e.lanes=o,e;default:if(typeof e==`object`&&e)switch(e.$$typeof){case C:s=10;break a;case S:s=9;break a;case w:s=11;break a;case ee:s=14;break a;case D:s=16,r=null;break a}s=29,n=Error(i(130,e===null?`null`:typeof e,``)),r=null}return t=mi(s,n,t,a),t.elementType=e,t.type=r,t.lanes=o,t}function yi(e,t,n,r){return e=mi(7,e,r,t),e.lanes=n,e}function bi(e,t,n){return e=mi(6,e,null,t),e.lanes=n,e}function xi(e){var t=mi(18,null,null,0);return t.stateNode=e,t}function N(e,t,n){return t=mi(4,e.children===null?[]:e.children,e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var Si=new WeakMap;function Ci(e,t){if(typeof e==`object`&&e){var n=Si.get(e);return n===void 0?(t={value:e,source:t,stack:Ee(t)},Si.set(e,t),t):n}return{value:e,source:t,stack:Ee(t)}}var P=[],F=0,wi=null,Ti=0,Ei=[],Di=0,Oi=null,ki=1,Ai=``;function ji(e,t){P[F++]=Ti,P[F++]=wi,wi=e,Ti=t}function Mi(e,t,n){Ei[Di++]=ki,Ei[Di++]=Ai,Ei[Di++]=Oi,Oi=e;var r=ki;e=Ai;var i=32-We(r)-1;r&=~(1<<i),n+=1;var a=32-We(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,ki=1<<32-We(t)+i|n<<i|r,Ai=a+e}else ki=1<<a|n<<i|r,Ai=e}function Ni(e){e.return!==null&&(ji(e,1),Mi(e,1,0))}function Pi(e){for(;e===wi;)wi=P[--F],P[F]=null,Ti=P[--F],P[F]=null;for(;e===Oi;)Oi=Ei[--Di],Ei[Di]=null,Ai=Ei[--Di],Ei[Di]=null,ki=Ei[--Di],Ei[Di]=null}function Fi(e,t){Ei[Di++]=ki,Ei[Di++]=Ai,Ei[Di++]=Oi,ki=t.id,Ai=t.overflow,Oi=e}var Ii=null,I=null,L=!1,Li=null,Ri=!1,zi=Error(i(519));function Bi(e){throw Ki(Ci(Error(i(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),zi}function Vi(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[ft]=e,t[pt]=r,n){case`dialog`:J(`cancel`,t),J(`close`,t);break;case`iframe`:case`object`:case`embed`:J(`load`,t);break;case`video`:case`audio`:for(n=0;n<Sd.length;n++)J(Sd[n],t);break;case`source`:J(`error`,t);break;case`img`:case`image`:case`link`:J(`error`,t),J(`load`,t);break;case`details`:J(`toggle`,t);break;case`input`:J(`invalid`,t),Kt(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case`select`:J(`invalid`,t);break;case`textarea`:J(`invalid`,t),Xt(t,r.value,r.defaultValue,r.children)}n=r.children,typeof n!=`string`&&typeof n!=`number`&&typeof n!=`bigint`||t.textContent===``+n||!0===r.suppressHydrationWarning||Id(t.textContent,n)?(r.popover!=null&&(J(`beforetoggle`,t),J(`toggle`,t)),r.onScroll!=null&&J(`scroll`,t),r.onScrollEnd!=null&&J(`scrollend`,t),r.onClick!=null&&(t.onclick=on),t=!0):t=!1,t||Bi(e,!0)}function Hi(e){for(Ii=e.return;Ii;)switch(Ii.tag){case 5:case 31:case 13:Ri=!1;return;case 27:case 3:Ri=!0;return;default:Ii=Ii.return}}function Ui(e){if(e!==Ii)return!1;if(!L)return Hi(e),L=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=n===`form`||n===`button`||qd(e.type,e.memoizedProps)),n=!n),n&&I&&Bi(e),Hi(e),t===13){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));I=mf(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));I=mf(e)}else t===27?(t=I,tf(e.type)?(e=pf,pf=null,I=e):I=t):I=Ii?ff(e.stateNode.nextSibling):null;return!0}function Wi(){I=Ii=null,L=!1}function Gi(){var e=Li;return e!==null&&(nu===null?nu=e:nu.push.apply(nu,e),Li=null),e}function Ki(e){Li===null?Li=[e]:Li.push(e)}var qi=ue(null),Ji=null,Yi=null;function Xi(e,t,n){j(qi,t._currentValue),t._currentValue=n}function Zi(e){e._currentValue=qi.current,de(qi)}function Qi(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)===t?r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t):(e.childLanes|=t,r!==null&&(r.childLanes|=t)),e===n)break;e=e.return}}function $i(e,t,n,r){var a=e.child;for(a!==null&&(a.return=e);a!==null;){var o=a.dependencies;if(o!==null){var s=a.child;o=o.firstContext;a:for(;o!==null;){var c=o;o=a;for(var l=0;l<t.length;l++)if(c.context===t[l]){o.lanes|=n,c=o.alternate,c!==null&&(c.lanes|=n),Qi(o.return,n,e),r||(s=null);break a}o=c.next}}else if(a.tag===18){if(s=a.return,s===null)throw Error(i(341));s.lanes|=n,o=s.alternate,o!==null&&(o.lanes|=n),Qi(s,n,e),s=null}else s=a.child;if(s!==null)s.return=a;else for(s=a;s!==null;){if(s===e){s=null;break}if(a=s.sibling,a!==null){a.return=s.return,s=a;break}s=s.return}a=s}}function ea(e,t,n,r){e=null;for(var a=t,o=!1;a!==null;){if(!o){if(a.flags&524288)o=!0;else if(a.flags&262144)break}if(a.tag===10){var s=a.alternate;if(s===null)throw Error(i(387));if(s=s.memoizedProps,s!==null){var c=a.type;Or(a.pendingProps.value,s.value)||(e===null?e=[c]:e.push(c))}}else if(a===he.current){if(s=a.alternate,s===null)throw Error(i(387));s.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(e===null?e=[np]:e.push(np))}a=a.return}e!==null&&$i(t,e,n,r),t.flags|=262144}function ta(e){for(e=e.firstContext;e!==null;){if(!Or(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function na(e){Ji=e,Yi=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function ra(e){return aa(Ji,e)}function ia(e,t){return Ji===null&&na(e),aa(e,t)}function aa(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},Yi===null){if(e===null)throw Error(i(308));Yi=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Yi=Yi.next=t;return n}var oa=typeof AbortController<`u`?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},sa=t.unstable_scheduleCallback,ca=t.unstable_NormalPriority,la={$$typeof:C,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function ua(){return{controller:new oa,data:new Map,refCount:0}}function da(e){e.refCount--,e.refCount===0&&sa(ca,function(){e.controller.abort()})}var fa=null,pa=0,ma=0,ha=null;function ga(e,t){if(fa===null){var n=fa=[];pa=0,ma=gd(),ha={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return pa++,t.then(_a,_a),t}function _a(){if(--pa===0&&fa!==null){ha!==null&&(ha.status=`fulfilled`);var e=fa;fa=null,ma=0,ha=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function va(e,t){var n=[],r={status:`pending`,value:null,reason:null,then:function(e){n.push(e)}};return e.then(function(){r.status=`fulfilled`,r.value=t;for(var e=0;e<n.length;e++)(0,n[e])(t)},function(e){for(r.status=`rejected`,r.reason=e,e=0;e<n.length;e++)(0,n[e])(void 0)}),r}var ya=k.S;k.S=function(e,t){au=Me(),typeof t==`object`&&t&&typeof t.then==`function`&&ga(e,t),ya!==null&&ya(e,t)};var ba=ue(null);function xa(){var e=ba.current;return e===null?H.pooledCache:e}function Sa(e,t){t===null?j(ba,ba.current):j(ba,t.pool)}function Ca(){var e=xa();return e===null?null:{parent:la._currentValue,pool:e}}var wa=Error(i(460)),Ta=Error(i(474)),Ea=Error(i(542)),Da={then:function(){}};function Oa(e){return e=e.status,e===`fulfilled`||e===`rejected`}function ka(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(on,on),t=n),t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Na(e),e;default:if(typeof t.status==`string`)t.then(on,on);else{if(e=H,e!==null&&100<e.shellSuspendCounter)throw Error(i(482));e=t,e.status=`pending`,e.then(function(e){if(t.status===`pending`){var n=t;n.status=`fulfilled`,n.value=e}},function(e){if(t.status===`pending`){var n=t;n.status=`rejected`,n.reason=e}})}switch(t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Na(e),e}throw ja=t,wa}}function Aa(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(ja=e,wa):e}}var ja=null;function Ma(){if(ja===null)throw Error(i(459));var e=ja;return ja=null,e}function Na(e){if(e===wa||e===Ea)throw Error(i(483))}var Pa=null,Fa=0;function Ia(e){var t=Fa;return Fa+=1,Pa===null&&(Pa=[]),ka(Pa,e,t)}function La(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function Ra(e,t){throw t.$$typeof===g?Error(i(525)):(e=Object.prototype.toString.call(t),Error(i(31,e===`[object Object]`?`object with keys {`+Object.keys(t).join(`, `)+`}`:e)))}function za(e){function t(t,n){if(e){var r=t.deletions;r===null?(t.deletions=[n],t.flags|=16):r.push(n)}}function n(n,r){if(!e)return null;for(;r!==null;)t(n,r),r=r.sibling;return null}function r(e){for(var t=new Map;e!==null;)e.key===null?t.set(e.index,e):t.set(e.key,e),e=e.sibling;return t}function a(e,t){return e=gi(e,t),e.index=0,e.sibling=null,e}function o(t,n,r){return t.index=r,e?(r=t.alternate,r===null?(t.flags|=67108866,n):(r=r.index,r<n?(t.flags|=67108866,n):r)):(t.flags|=1048576,n)}function s(t){return e&&t.alternate===null&&(t.flags|=67108866),t}function c(e,t,n,r){return t===null||t.tag!==6?(t=bi(n,e.mode,r),t.return=e,t):(t=a(t,n),t.return=e,t)}function l(e,t,n,r){var i=n.type;return i===y?d(e,t,n.props.children,r,n.key):t!==null&&(t.elementType===i||typeof i==`object`&&i&&i.$$typeof===D&&Aa(i)===t.type)?(t=a(t,n.props),La(t,n),t.return=e,t):(t=vi(n.type,n.key,n.props,null,e.mode,r),La(t,n),t.return=e,t)}function u(e,t,n,r){return t===null||t.tag!==4||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?(t=N(n,e.mode,r),t.return=e,t):(t=a(t,n.children||[]),t.return=e,t)}function d(e,t,n,r,i){return t===null||t.tag!==7?(t=yi(n,e.mode,r,i),t.return=e,t):(t=a(t,n),t.return=e,t)}function f(e,t,n){if(typeof t==`string`&&t!==``||typeof t==`number`||typeof t==`bigint`)return t=bi(``+t,e.mode,n),t.return=e,t;if(typeof t==`object`&&t){switch(t.$$typeof){case _:return n=vi(t.type,t.key,t.props,null,e.mode,n),La(n,t),n.return=e,n;case v:return t=N(t,e.mode,n),t.return=e,t;case D:return t=Aa(t),f(e,t,n)}if(oe(t)||re(t))return t=yi(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return f(e,Ia(t),n);if(t.$$typeof===C)return f(e,ia(e,t),n);Ra(e,t)}return null}function p(e,t,n,r){var i=t===null?null:t.key;if(typeof n==`string`&&n!==``||typeof n==`number`||typeof n==`bigint`)return i===null?c(e,t,``+n,r):null;if(typeof n==`object`&&n){switch(n.$$typeof){case _:return n.key===i?l(e,t,n,r):null;case v:return n.key===i?u(e,t,n,r):null;case D:return n=Aa(n),p(e,t,n,r)}if(oe(n)||re(n))return i===null?d(e,t,n,r,null):null;if(typeof n.then==`function`)return p(e,t,Ia(n),r);if(n.$$typeof===C)return p(e,t,ia(e,n),r);Ra(e,n)}return null}function m(e,t,n,r,i){if(typeof r==`string`&&r!==``||typeof r==`number`||typeof r==`bigint`)return e=e.get(n)||null,c(t,e,``+r,i);if(typeof r==`object`&&r){switch(r.$$typeof){case _:return e=e.get(r.key===null?n:r.key)||null,l(t,e,r,i);case v:return e=e.get(r.key===null?n:r.key)||null,u(t,e,r,i);case D:return r=Aa(r),m(e,t,n,r,i)}if(oe(r)||re(r))return e=e.get(n)||null,d(t,e,r,i,null);if(typeof r.then==`function`)return m(e,t,n,Ia(r),i);if(r.$$typeof===C)return m(e,t,n,ia(t,r),i);Ra(t,r)}return null}function h(i,a,s,c){for(var l=null,u=null,d=a,h=a=0,g=null;d!==null&&h<s.length;h++){d.index>h?(g=d,d=null):g=d.sibling;var _=p(i,d,s[h],c);if(_===null){d===null&&(d=g);break}e&&d&&_.alternate===null&&t(i,d),a=o(_,a,h),u===null?l=_:u.sibling=_,u=_,d=g}if(h===s.length)return n(i,d),L&&ji(i,h),l;if(d===null){for(;h<s.length;h++)d=f(i,s[h],c),d!==null&&(a=o(d,a,h),u===null?l=d:u.sibling=d,u=d);return L&&ji(i,h),l}for(d=r(d);h<s.length;h++)g=m(d,i,h,s[h],c),g!==null&&(e&&g.alternate!==null&&d.delete(g.key===null?h:g.key),a=o(g,a,h),u===null?l=g:u.sibling=g,u=g);return e&&d.forEach(function(e){return t(i,e)}),L&&ji(i,h),l}function g(a,s,c,l){if(c==null)throw Error(i(151));for(var u=null,d=null,h=s,g=s=0,_=null,v=c.next();h!==null&&!v.done;g++,v=c.next()){h.index>g?(_=h,h=null):_=h.sibling;var y=p(a,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(a,h),s=o(y,s,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(a,h),L&&ji(a,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(a,v.value,l),v!==null&&(s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return L&&ji(a,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,a,g,v.value,l),v!==null&&(e&&v.alternate!==null&&h.delete(v.key===null?g:v.key),s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return e&&h.forEach(function(e){return t(a,e)}),L&&ji(a,g),u}function b(e,r,o,c){if(typeof o==`object`&&o&&o.type===y&&o.key===null&&(o=o.props.children),typeof o==`object`&&o){switch(o.$$typeof){case _:a:{for(var l=o.key;r!==null;){if(r.key===l){if(l=o.type,l===y){if(r.tag===7){n(e,r.sibling),c=a(r,o.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===D&&Aa(l)===r.type){n(e,r.sibling),c=a(r,o.props),La(c,o),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}o.type===y?(c=yi(o.props.children,e.mode,c,o.key),c.return=e,e=c):(c=vi(o.type,o.key,o.props,null,e.mode,c),La(c,o),c.return=e,e=c)}return s(e);case v:a:{for(l=o.key;r!==null;){if(r.key===l){if(r.tag===4&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),c=a(r,o.children||[]),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}c=N(o,e.mode,c),c.return=e,e=c}return s(e);case D:return o=Aa(o),b(e,r,o,c)}if(oe(o))return h(e,r,o,c);if(re(o)){if(l=re(o),typeof l!=`function`)throw Error(i(150));return o=l.call(o),g(e,r,o,c)}if(typeof o.then==`function`)return b(e,r,Ia(o),c);if(o.$$typeof===C)return b(e,r,ia(e,o),c);Ra(e,o)}return typeof o==`string`&&o!==``||typeof o==`number`||typeof o==`bigint`?(o=``+o,r!==null&&r.tag===6?(n(e,r.sibling),c=a(r,o),c.return=e,e=c):(n(e,r),c=bi(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{Fa=0;var i=b(e,t,n,r);return Pa=null,i}catch(t){if(t===wa||t===Ea)throw t;var a=mi(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Ba=za(!0),Va=za(!1),Ha=!1;function Ua(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Wa(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Ga(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Ka(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,V&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=di(e),ui(e,null,n),t}return si(e,r,t,n),di(e)}function qa(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,ot(e,n)}}function Ja(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var Ya=!1;function Xa(){if(Ya){var e=ha;if(e!==null)throw e}}function Za(e,t,n,r){Ya=!1;var i=e.updateQueue;Ha=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var f=s.lane&-536870913,p=f!==s.lane;if(p?(W&f)===f:(r&f)===f){f!==0&&f===ma&&(Ya=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var h=e,g=s;f=t;var _=n;switch(g.tag){case 1:if(h=g.payload,typeof h==`function`){d=h.call(_,d,f);break a}d=h;break a;case 3:h.flags=h.flags&-65537|128;case 0:if(h=g.payload,f=typeof h==`function`?h.call(_,d,f):h,f==null)break a;d=m({},d,f);break a;case 2:Ha=!0}}f=s.callback,f!==null&&(e.flags|=64,p&&(e.flags|=8192),p=i.callbacks,p===null?i.callbacks=[f]:p.push(f))}else p={lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=p,c=d):u=u.next=p,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;p=s,s=p.next,p.next=null,i.lastBaseUpdate=p,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),Xl|=o,e.lanes=o,e.memoizedState=d}}function Qa(e,t){if(typeof e!=`function`)throw Error(i(191,e));e.call(t)}function $a(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)Qa(n[e],t)}var eo=ue(null),to=ue(0);function no(e,t){e=Jl,j(to,e),j(eo,t),Jl=e|t.baseLanes}function ro(){j(to,Jl),j(eo,eo.current)}function io(){Jl=to.current,de(eo),de(to)}var ao=ue(null),oo=null;function so(e){var t=e.alternate;j(po,po.current&1),j(ao,e),oo===null&&(t===null||eo.current!==null||t.memoizedState!==null)&&(oo=e)}function co(e){j(po,po.current),j(ao,e),oo===null&&(oo=e)}function lo(e){e.tag===22?(j(po,po.current),j(ao,e),oo===null&&(oo=e)):uo(e)}function uo(){j(po,po.current),j(ao,ao.current)}function fo(e){de(ao),oo===e&&(oo=null),de(po)}var po=ue(0);function mo(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||lf(n)||uf(n)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder===`forwards`||t.memoizedProps.revealOrder===`backwards`||t.memoizedProps.revealOrder===`unstable_legacy-backwards`||t.memoizedProps.revealOrder===`together`)){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var ho=0,R=null,z=null,go=null,_o=!1,vo=!1,yo=!1,bo=0,xo=0,So=null,Co=0;function wo(){throw Error(i(321))}function To(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Or(e[n],t[n]))return!1;return!0}function Eo(e,t,n,r,i,a){return ho=a,R=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,k.H=e===null||e.memoizedState===null?Us:Ws,yo=!1,a=n(r,i),yo=!1,vo&&(a=Oo(t,n,r,i)),Do(e),a}function Do(e){k.H=Hs;var t=z!==null&&z.next!==null;if(ho=0,go=z=R=null,_o=!1,xo=0,So=null,t)throw Error(i(300));e===null||sc||(e=e.dependencies,e!==null&&ta(e)&&(sc=!0))}function Oo(e,t,n,r){R=e;var a=0;do{if(vo&&(So=null),xo=0,vo=!1,25<=a)throw Error(i(301));if(a+=1,go=z=null,e.updateQueue!=null){var o=e.updateQueue;o.lastEffect=null,o.events=null,o.stores=null,o.memoCache!=null&&(o.memoCache.index=0)}k.H=Gs,o=t(n,r)}while(vo);return o}function ko(){var e=k.H,t=e.useState()[0];return t=typeof t.then==`function`?Io(t):t,e=e.useState()[0],(z===null?null:z.memoizedState)!==e&&(R.flags|=1024),t}function Ao(){var e=bo!==0;return bo=0,e}function jo(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function Mo(e){if(_o){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}_o=!1}ho=0,go=z=R=null,vo=!1,xo=bo=0,So=null}function No(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return go===null?R.memoizedState=go=e:go=go.next=e,go}function Po(){if(z===null){var e=R.alternate;e=e===null?null:e.memoizedState}else e=z.next;var t=go===null?R.memoizedState:go.next;if(t!==null)go=t,z=e;else{if(e===null)throw R.alternate===null?Error(i(467)):Error(i(310));z=e,e={memoizedState:z.memoizedState,baseState:z.baseState,baseQueue:z.baseQueue,queue:z.queue,next:null},go===null?R.memoizedState=go=e:go=go.next=e}return go}function Fo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Io(e){var t=xo;return xo+=1,So===null&&(So=[]),e=ka(So,e,t),t=R,(go===null?t.memoizedState:go.next)===null&&(t=t.alternate,k.H=t===null||t.memoizedState===null?Us:Ws),e}function Lo(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return Io(e);if(e.$$typeof===C)return ra(e)}throw Error(i(438,String(e)))}function Ro(e){var t=null,n=R.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=R.alternate;r!==null&&(r=r.updateQueue,r!==null&&(r=r.memoCache,r!=null&&(t={data:r.data.map(function(e){return e.slice()}),index:0})))}if(t??={data:[],index:0},n===null&&(n=Fo(),R.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=te;return t.index++,n}function zo(e,t){return typeof t==`function`?t(e):t}function Bo(e){return Vo(Po(),z,e)}function Vo(e,t,n){var r=e.queue;if(r===null)throw Error(i(311));r.lastRenderedReducer=n;var a=e.baseQueue,o=r.pending;if(o!==null){if(a!==null){var s=a.next;a.next=o.next,o.next=s}t.baseQueue=a=o,r.pending=null}if(o=e.baseState,a===null)e.memoizedState=o;else{t=a.next;var c=s=null,l=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f===u.lane?(ho&f)===f:(W&f)===f){var p=u.revertLane;if(p===0)l!==null&&(l=l.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===ma&&(d=!0);else if((ho&p)===p){u=u.next,p===ma&&(d=!0);continue}else f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=f,s=o):l=l.next=f,R.lanes|=p,Xl|=p;f=u.action,yo&&n(o,f),o=u.hasEagerState?u.eagerState:n(o,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=p,s=o):l=l.next=p,R.lanes|=f,Xl|=f;u=u.next}while(u!==null&&u!==t);if(l===null?s=o:l.next=c,!Or(o,e.memoizedState)&&(sc=!0,d&&(n=ha,n!==null)))throw n;e.memoizedState=o,e.baseState=s,e.baseQueue=l,r.lastRenderedState=o}return a===null&&(r.lanes=0),[e.memoizedState,r.dispatch]}function Ho(e){var t=Po(),n=t.queue;if(n===null)throw Error(i(311));n.lastRenderedReducer=e;var r=n.dispatch,a=n.pending,o=t.memoizedState;if(a!==null){n.pending=null;var s=a=a.next;do o=e(o,s.action),s=s.next;while(s!==a);Or(o,t.memoizedState)||(sc=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function Uo(e,t,n){var r=R,a=Po(),o=L;if(o){if(n===void 0)throw Error(i(407));n=n()}else n=t();var s=!Or((z||a).memoizedState,n);if(s&&(a.memoizedState=n,sc=!0),a=a.queue,ms(Ko.bind(null,r,a,e),[e]),a.getSnapshot!==t||s||go!==null&&go.memoizedState.tag&1){if(r.flags|=2048,ls(9,{destroy:void 0},Go.bind(null,r,a,n,t),null),H===null)throw Error(i(349));o||ho&127||Wo(r,t,n)}return n}function Wo(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=R.updateQueue,t===null?(t=Fo(),R.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Go(e,t,n,r){t.value=n,t.getSnapshot=r,qo(t)&&Jo(e)}function Ko(e,t,n){return n(function(){qo(t)&&Jo(e)})}function qo(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Or(e,n)}catch{return!0}}function Jo(e){var t=li(e,2);t!==null&&bu(t,e,2)}function Yo(e){var t=No();if(typeof e==`function`){var n=e;if(e=n(),yo){Ue(!0);try{n()}finally{Ue(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:zo,lastRenderedState:e},t}function Xo(e,t,n,r){return e.baseState=n,Vo(e,z,typeof r==`function`?r:zo)}function Zo(e,t,n,r,a){if(zs(e))throw Error(i(485));if(e=t.action,e!==null){var o={payload:a,action:e,next:null,isTransition:!0,status:`pending`,value:null,reason:null,listeners:[],then:function(e){o.listeners.push(e)}};k.T===null?o.isTransition=!1:n(!0),r(o),n=t.pending,n===null?(o.next=t.pending=o,Qo(t,o)):(o.next=n.next,t.pending=n.next=o)}}function Qo(e,t){var n=t.action,r=t.payload,i=e.state;if(t.isTransition){var a=k.T,o={};k.T=o;try{var s=n(i,r),c=k.S;c!==null&&c(o,s),$o(e,t,s)}catch(n){ts(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),k.T=a}}else try{a=n(i,r),$o(e,t,a)}catch(n){ts(e,t,n)}}function $o(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){es(e,t,n)},function(n){return ts(e,t,n)}):es(e,t,n)}function es(e,t,n){t.status=`fulfilled`,t.value=n,ns(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,Qo(e,n)))}function ts(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,ns(t),t=t.next;while(t!==r)}e.action=null}function ns(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function rs(e,t){return t}function is(e,t){if(L){var n=H.formState;if(n!==null){a:{var r=R;if(L){if(I){b:{for(var i=I,a=Ri;i.nodeType!==8;){if(!a){i=null;break b}if(i=ff(i.nextSibling),i===null){i=null;break b}}a=i.data,i=a===`F!`||a===`F`?i:null}if(i){I=ff(i.nextSibling),r=i.data===`F!`;break a}}Bi(r)}r=!1}r&&(t=n[0])}}return n=No(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:rs,lastRenderedState:t},n.queue=r,n=Is.bind(null,R,r),r.dispatch=n,r=Yo(!1),a=Rs.bind(null,R,!1,r.queue),r=No(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=Zo.bind(null,R,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function as(e){return os(Po(),z,e)}function os(e,t,n){if(t=Vo(e,t,rs)[0],e=Bo(zo)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=Io(t)}catch(e){throw e===wa?Ea:e}else r=t;t=Po();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(R.flags|=2048,ls(9,{destroy:void 0},ss.bind(null,i,n),null)),[r,a,e]}function ss(e,t){e.action=t}function cs(e){var t=Po(),n=z;if(n!==null)return os(t,n,e);Po(),t=t.memoizedState,n=Po();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function ls(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=R.updateQueue,t===null&&(t=Fo(),R.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function us(){return Po().memoizedState}function ds(e,t,n,r){var i=No();R.flags|=e,i.memoizedState=ls(1|t,{destroy:void 0},n,r===void 0?null:r)}function fs(e,t,n,r){var i=Po();r=r===void 0?null:r;var a=i.memoizedState.inst;z!==null&&r!==null&&To(r,z.memoizedState.deps)?i.memoizedState=ls(t,a,n,r):(R.flags|=e,i.memoizedState=ls(1|t,a,n,r))}function ps(e,t){ds(8390656,8,e,t)}function ms(e,t){fs(2048,8,e,t)}function hs(e){R.flags|=4;var t=R.updateQueue;if(t===null)t=Fo(),R.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function gs(e){var t=Po().memoizedState;return hs({ref:t,nextImpl:e}),function(){if(V&2)throw Error(i(440));return t.impl.apply(void 0,arguments)}}function _s(e,t){return fs(4,2,e,t)}function vs(e,t){return fs(4,4,e,t)}function ys(e,t){if(typeof t==`function`){e=e();var n=t(e);return function(){typeof n==`function`?n():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function bs(e,t,n){n=n==null?null:n.concat([e]),fs(4,4,ys.bind(null,t,e),n)}function xs(){}function Ss(e,t){var n=Po();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&To(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Cs(e,t){var n=Po();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&To(t,r[1]))return r[0];if(r=e(),yo){Ue(!0);try{e()}finally{Ue(!1)}}return n.memoizedState=[r,t],r}function ws(e,t,n){return n===void 0||ho&1073741824&&!(W&261930)?e.memoizedState=t:(e.memoizedState=n,e=yu(),R.lanes|=e,Xl|=e,n)}function Ts(e,t,n,r){return Or(n,t)?n:eo.current===null?!(ho&42)||ho&1073741824&&!(W&261930)?(sc=!0,e.memoizedState=n):(e=yu(),R.lanes|=e,Xl|=e,t):(e=ws(e,n,r),Or(e,t)||(sc=!0),e)}function Es(e,t,n,r,i){var a=A.p;A.p=a!==0&&8>a?a:8;var o=k.T,s={};k.T=s,Rs(e,!1,t,n);try{var c=i(),l=k.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?Ls(e,t,va(c,r),vu(e)):Ls(e,t,r,vu(e))}catch(n){Ls(e,t,{then:function(){},status:`rejected`,reason:n},vu())}finally{A.p=a,o!==null&&s.types!==null&&(o.types=s.types),k.T=o}}function Ds(){}function Os(e,t,n,r){if(e.tag!==5)throw Error(i(476));var a=ks(e).queue;Es(e,a,t,se,n===null?Ds:function(){return As(e),n(r)})}function ks(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:se,baseState:se,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:zo,lastRenderedState:se},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:zo,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function As(e){var t=ks(e);t.next===null&&(t=e.alternate.memoizedState),Ls(e,t.next.queue,{},vu())}function js(){return ra(np)}function Ms(){return Po().memoizedState}function Ns(){return Po().memoizedState}function Ps(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=vu();e=Ga(n);var r=Ka(t,e,n);r!==null&&(bu(r,t,n),qa(r,t,n)),t={cache:ua()},e.payload=t;return}t=t.return}}function Fs(e,t,n){var r=vu();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},zs(e)?Bs(t,n):(n=ci(e,t,n,r),n!==null&&(bu(n,e,r),Vs(n,t,r)))}function Is(e,t,n){Ls(e,t,n,vu())}function Ls(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(zs(e))Bs(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,Or(s,o))return si(e,t,i,0),H===null&&oi(),!1}catch{}if(n=ci(e,t,i,r),n!==null)return bu(n,e,r),Vs(n,t,r),!0}return!1}function Rs(e,t,n,r){if(r={lane:2,revertLane:gd(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},zs(e)){if(t)throw Error(i(479))}else t=ci(e,n,r,2),t!==null&&bu(t,e,2)}function zs(e){var t=e.alternate;return e===R||t!==null&&t===R}function Bs(e,t){vo=_o=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Vs(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,ot(e,n)}}var Hs={readContext:ra,use:Lo,useCallback:wo,useContext:wo,useEffect:wo,useImperativeHandle:wo,useLayoutEffect:wo,useInsertionEffect:wo,useMemo:wo,useReducer:wo,useRef:wo,useState:wo,useDebugValue:wo,useDeferredValue:wo,useTransition:wo,useSyncExternalStore:wo,useId:wo,useHostTransitionStatus:wo,useFormState:wo,useActionState:wo,useOptimistic:wo,useMemoCache:wo,useCacheRefresh:wo};Hs.useEffectEvent=wo;var Us={readContext:ra,use:Lo,useCallback:function(e,t){return No().memoizedState=[e,t===void 0?null:t],e},useContext:ra,useEffect:ps,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),ds(4194308,4,ys.bind(null,t,e),n)},useLayoutEffect:function(e,t){return ds(4194308,4,e,t)},useInsertionEffect:function(e,t){ds(4,2,e,t)},useMemo:function(e,t){var n=No();t=t===void 0?null:t;var r=e();if(yo){Ue(!0);try{e()}finally{Ue(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=No();if(n!==void 0){var i=n(t);if(yo){Ue(!0);try{n(t)}finally{Ue(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=Fs.bind(null,R,e),[r.memoizedState,e]},useRef:function(e){var t=No();return e={current:e},t.memoizedState=e},useState:function(e){e=Yo(e);var t=e.queue,n=Is.bind(null,R,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:xs,useDeferredValue:function(e,t){return ws(No(),e,t)},useTransition:function(){var e=Yo(!1);return e=Es.bind(null,R,e.queue,!0,!1),No().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=R,a=No();if(L){if(n===void 0)throw Error(i(407));n=n()}else{if(n=t(),H===null)throw Error(i(349));W&127||Wo(r,t,n)}a.memoizedState=n;var o={value:n,getSnapshot:t};return a.queue=o,ps(Ko.bind(null,r,o,e),[e]),r.flags|=2048,ls(9,{destroy:void 0},Go.bind(null,r,o,n,t),null),n},useId:function(){var e=No(),t=H.identifierPrefix;if(L){var n=Ai,r=ki;n=(r&~(1<<32-We(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=bo++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=Co++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:js,useFormState:is,useActionState:is,useOptimistic:function(e){var t=No();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=Rs.bind(null,R,!0,n),n.dispatch=t,[e,t]},useMemoCache:Ro,useCacheRefresh:function(){return No().memoizedState=Ps.bind(null,R)},useEffectEvent:function(e){var t=No(),n={impl:e};return t.memoizedState=n,function(){if(V&2)throw Error(i(440));return n.impl.apply(void 0,arguments)}}},Ws={readContext:ra,use:Lo,useCallback:Ss,useContext:ra,useEffect:ms,useImperativeHandle:bs,useInsertionEffect:_s,useLayoutEffect:vs,useMemo:Cs,useReducer:Bo,useRef:us,useState:function(){return Bo(zo)},useDebugValue:xs,useDeferredValue:function(e,t){return Ts(Po(),z.memoizedState,e,t)},useTransition:function(){var e=Bo(zo)[0],t=Po().memoizedState;return[typeof e==`boolean`?e:Io(e),t]},useSyncExternalStore:Uo,useId:Ms,useHostTransitionStatus:js,useFormState:as,useActionState:as,useOptimistic:function(e,t){return Xo(Po(),z,e,t)},useMemoCache:Ro,useCacheRefresh:Ns};Ws.useEffectEvent=gs;var Gs={readContext:ra,use:Lo,useCallback:Ss,useContext:ra,useEffect:ms,useImperativeHandle:bs,useInsertionEffect:_s,useLayoutEffect:vs,useMemo:Cs,useReducer:Ho,useRef:us,useState:function(){return Ho(zo)},useDebugValue:xs,useDeferredValue:function(e,t){var n=Po();return z===null?ws(n,e,t):Ts(n,z.memoizedState,e,t)},useTransition:function(){var e=Ho(zo)[0],t=Po().memoizedState;return[typeof e==`boolean`?e:Io(e),t]},useSyncExternalStore:Uo,useId:Ms,useHostTransitionStatus:js,useFormState:cs,useActionState:cs,useOptimistic:function(e,t){var n=Po();return z===null?(n.baseState=e,[e,n.queue.dispatch]):Xo(n,z,e,t)},useMemoCache:Ro,useCacheRefresh:Ns};Gs.useEffectEvent=gs;function Ks(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:m({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var qs={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=vu(),i=Ga(r);i.payload=t,n!=null&&(i.callback=n),t=Ka(e,i,r),t!==null&&(bu(t,e,r),qa(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=vu(),i=Ga(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=Ka(e,i,r),t!==null&&(bu(t,e,r),qa(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=vu(),r=Ga(n);r.tag=2,t!=null&&(r.callback=t),t=Ka(e,r,n),t!==null&&(bu(t,e,n),qa(t,e,n))}};function Js(e,t,n,r,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate==`function`?e.shouldComponentUpdate(r,a,o):t.prototype&&t.prototype.isPureReactComponent?!kr(n,r)||!kr(i,a):!0}function Ys(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps==`function`&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps==`function`&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&qs.enqueueReplaceState(t,t.state,null)}function Xs(e,t){var n=t;if(`ref`in t)for(var r in n={},t)r!==`ref`&&(n[r]=t[r]);if(e=e.defaultProps)for(var i in n===t&&(n=m({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function Zs(e){ni(e)}function Qs(e){console.error(e)}function $s(e){ni(e)}function ec(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function tc(e,t,n){try{var r=e.onCaughtError;r(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function nc(e,t,n){return n=Ga(n),n.tag=3,n.payload={element:null},n.callback=function(){ec(e,t)},n}function rc(e){return e=Ga(e),e.tag=3,e}function ic(e,t,n,r){var i=n.type.getDerivedStateFromError;if(typeof i==`function`){var a=r.value;e.payload=function(){return i(a)},e.callback=function(){tc(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){tc(t,n,r),typeof i!=`function`&&(cu===null?cu=new Set([this]):cu.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function ac(e,t,n,r,a){if(n.flags|=32768,typeof r==`object`&&r&&typeof r.then==`function`){if(t=n.alternate,t!==null&&ea(t,n,a,!0),n=ao.current,n!==null){switch(n.tag){case 31:case 13:return oo===null?Mu():n.alternate===null&&Yl===0&&(Yl=3),n.flags&=-257,n.flags|=65536,n.lanes=a,r===Da?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),Xu(e,r,a)),!1;case 22:return n.flags|=65536,r===Da?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([r]):n.add(r)),Xu(e,r,a)),!1}throw Error(i(435,n.tag))}return Xu(e,r,a),Mu(),!1}if(L)return t=ao.current,t===null?(r!==zi&&(t=Error(i(423),{cause:r}),Ki(Ci(t,n))),e=e.current.alternate,e.flags|=65536,a&=-a,e.lanes|=a,r=Ci(r,n),a=nc(e.stateNode,r,a),Ja(e,a),Yl!==4&&(Yl=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=a,r!==zi&&(e=Error(i(422),{cause:r}),Ki(Ci(e,n)))),!1;var o=Error(i(520),{cause:r});if(o=Ci(o,n),tu===null?tu=[o]:tu.push(o),Yl!==4&&(Yl=2),t===null)return!0;r=Ci(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=a&-a,n.lanes|=e,e=nc(n.stateNode,r,e),Ja(n,e),!1;case 1:if(t=n.type,o=n.stateNode,!(n.flags&128)&&(typeof t.getDerivedStateFromError==`function`||o!==null&&typeof o.componentDidCatch==`function`&&(cu===null||!cu.has(o))))return n.flags|=65536,a&=-a,n.lanes|=a,a=rc(a),ic(a,e,n,r),Ja(n,a),!1}n=n.return}while(n!==null);return!1}var oc=Error(i(461)),sc=!1;function cc(e,t,n,r){t.child=e===null?Va(t,null,n,r):Ba(t,e.child,n,r)}function lc(e,t,n,r,i){n=n.render;var a=t.ref;if(`ref`in r){var o={};for(var s in r)s!==`ref`&&(o[s]=r[s])}else o=r;return na(t),r=Eo(e,t,n,o,a,i),s=Ao(),e!==null&&!sc?(jo(e,t,i),Nc(e,t,i)):(L&&s&&Ni(t),t.flags|=1,cc(e,t,r,i),t.child)}function uc(e,t,n,r,i){if(e===null){var a=n.type;return typeof a==`function`&&!hi(a)&&a.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=a,dc(e,t,a,r,i)):(e=vi(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!Pc(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?kr:n,n(o,r)&&e.ref===t.ref)return Nc(e,t,i)}return t.flags|=1,e=gi(a,r),e.ref=t.ref,e.return=t,t.child=e}function dc(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(kr(a,r)&&e.ref===t.ref){if(sc=!1,t.pendingProps=r=a,Pc(e,i))e.flags&131072&&(sc=!0);else return t.lanes=e.lanes,Nc(e,t,i)}}return yc(e,t,n,r,i)}function fc(e,t,n,r){var i=r.children,a=e===null?null:e.memoizedState;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.mode===`hidden`){if(t.flags&128){if(a=a===null?n:a.baseLanes|n,e!==null){for(r=t.child=e.child,i=0;r!==null;)i=i|r.lanes|r.childLanes,r=r.sibling;r=i&~a}else r=0,t.child=null;return mc(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Sa(t,a===null?null:a.cachePool),a===null?ro():no(t,a),lo(t);else return r=t.lanes=536870912,mc(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&Sa(t,null),ro(),uo(t)):(Sa(t,a.cachePool),no(t,a),uo(t),t.memoizedState=null);return cc(e,t,i,n),t.child}function pc(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function mc(e,t,n,r,i){var a=xa();return a=a===null?null:{parent:la._currentValue,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&Sa(t,null),ro(),lo(t),e!==null&&ea(e,t,r,!0),t.childLanes=i,null}function hc(e,t){return t=Oc({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function gc(e,t,n){return Ba(t,e.child,null,n),e=hc(t,t.pendingProps),e.flags|=2,fo(t),t.memoizedState=null,e}function _c(e,t,n){var r=t.pendingProps,a=!!(t.flags&128);if(t.flags&=-129,e===null){if(L){if(r.mode===`hidden`)return e=hc(t,r),t.lanes=536870912,pc(null,e);if(co(t),(e=I)?(e=cf(e,Ri),e=e!==null&&e.data===`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Oi===null?null:{id:ki,overflow:Ai},retryLane:536870912,hydrationErrors:null},n=xi(e),n.return=t,t.child=n,Ii=t,I=null)):e=null,e===null)throw Bi(t);return t.lanes=536870912,null}return hc(t,r)}var o=e.memoizedState;if(o!==null){var s=o.dehydrated;if(co(t),a){if(t.flags&256)t.flags&=-257,t=gc(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(i(558))}else if(sc||ea(e,t,n,!1),a=(n&e.childLanes)!==0,sc||a){if(r=H,r!==null&&(s=st(r,n),s!==0&&s!==o.retryLane))throw o.retryLane=s,li(e,s),bu(r,e,s),oc;Mu(),t=gc(e,t,n)}else e=o.treeContext,I=ff(s.nextSibling),Ii=t,L=!0,Li=null,Ri=!1,e!==null&&Fi(t,e),t=hc(t,r),t.flags|=4096;return t}return e=gi(e.child,{mode:r.mode,children:r.children}),e.ref=t.ref,t.child=e,e.return=t,e}function vc(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!=`function`&&typeof n!=`object`)throw Error(i(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function yc(e,t,n,r,i){return na(t),n=Eo(e,t,n,r,void 0,i),r=Ao(),e!==null&&!sc?(jo(e,t,i),Nc(e,t,i)):(L&&r&&Ni(t),t.flags|=1,cc(e,t,n,i),t.child)}function bc(e,t,n,r,i,a){return na(t),t.updateQueue=null,n=Oo(t,r,n,i),Do(e),r=Ao(),e!==null&&!sc?(jo(e,t,a),Nc(e,t,a)):(L&&r&&Ni(t),t.flags|=1,cc(e,t,n,a),t.child)}function xc(e,t,n,r,i){if(na(t),t.stateNode===null){var a=fi,o=n.contextType;typeof o==`object`&&o&&(a=ra(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=qs,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},Ua(t),o=n.contextType,a.context=typeof o==`object`&&o?ra(o):fi,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(Ks(t,n,o,r),a.state=t.memoizedState),typeof n.getDerivedStateFromProps==`function`||typeof a.getSnapshotBeforeUpdate==`function`||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(o=a.state,typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount(),o!==a.state&&qs.enqueueReplaceState(a,a.state,null),Za(t,r,a,i),Xa(),a.state=t.memoizedState),typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!0}else if(e===null){a=t.stateNode;var s=t.memoizedProps,c=Xs(n,s);a.props=c;var l=a.context,u=n.contextType;o=fi,typeof u==`object`&&u&&(o=ra(u));var d=n.getDerivedStateFromProps;u=typeof d==`function`||typeof a.getSnapshotBeforeUpdate==`function`,s=t.pendingProps!==s,u||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(s||l!==o)&&Ys(t,a,r,o),Ha=!1;var f=t.memoizedState;a.state=f,Za(t,r,a,i),Xa(),l=t.memoizedState,s||f!==l||Ha?(typeof d==`function`&&(Ks(t,n,d,r),l=t.memoizedState),(c=Ha||Js(t,n,c,r,f,l,o))?(u||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount==`function`&&(t.flags|=4194308)):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=o,r=c):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,Wa(e,t),o=t.memoizedProps,u=Xs(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=fi,typeof l==`object`&&l&&(c=ra(l)),s=n.getDerivedStateFromProps,(l=typeof s==`function`||typeof a.getSnapshotBeforeUpdate==`function`)||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(o!==d||f!==c)&&Ys(t,a,r,c),Ha=!1,f=t.memoizedState,a.state=f,Za(t,r,a,i),Xa();var p=t.memoizedState;o!==d||f!==p||Ha||e!==null&&e.dependencies!==null&&ta(e.dependencies)?(typeof s==`function`&&(Ks(t,n,s,r),p=t.memoizedState),(u=Ha||Js(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&ta(e.dependencies))?(l||typeof a.UNSAFE_componentWillUpdate!=`function`&&typeof a.componentWillUpdate!=`function`||(typeof a.componentWillUpdate==`function`&&a.componentWillUpdate(r,p,c),typeof a.UNSAFE_componentWillUpdate==`function`&&a.UNSAFE_componentWillUpdate(r,p,c)),typeof a.componentDidUpdate==`function`&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate==`function`&&(t.flags|=1024)):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),a.props=r,a.state=p,a.context=c,r=u):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return a=r,vc(e,t),r=!!(t.flags&128),a||r?(a=t.stateNode,n=r&&typeof n.getDerivedStateFromError!=`function`?null:a.render(),t.flags|=1,e!==null&&r?(t.child=Ba(t,e.child,null,i),t.child=Ba(t,null,n,i)):cc(e,t,n,i),t.memoizedState=a.state,e=t.child):e=Nc(e,t,i),e}function Sc(e,t,n,r){return Wi(),t.flags|=256,cc(e,t,n,r),t.child}var Cc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function wc(e){return{baseLanes:e,cachePool:Ca()}}function Tc(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=$l),e}function Ec(e,t,n){var r=t.pendingProps,a=!1,o=!!(t.flags&128),s;if((s=o)||(s=e!==null&&e.memoizedState===null?!1:!!(po.current&2)),s&&(a=!0,t.flags&=-129),s=!!(t.flags&32),t.flags&=-33,e===null){if(L){if(a?so(t):uo(t),(e=I)?(e=cf(e,Ri),e=e!==null&&e.data!==`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Oi===null?null:{id:ki,overflow:Ai},retryLane:536870912,hydrationErrors:null},n=xi(e),n.return=t,t.child=n,Ii=t,I=null)):e=null,e===null)throw Bi(t);return uf(e)?t.lanes=32:t.lanes=536870912,null}var c=r.children;return r=r.fallback,a?(uo(t),a=t.mode,c=Oc({mode:`hidden`,children:c},a),r=yi(r,a,n,null),c.return=t,r.return=t,c.sibling=r,t.child=c,r=t.child,r.memoizedState=wc(n),r.childLanes=Tc(e,s,n),t.memoizedState=Cc,pc(null,r)):(so(t),Dc(t,c))}var l=e.memoizedState;if(l!==null&&(c=l.dehydrated,c!==null)){if(o)t.flags&256?(so(t),t.flags&=-257,t=kc(e,t,n)):t.memoizedState===null?(uo(t),c=r.fallback,a=t.mode,r=Oc({mode:`visible`,children:r.children},a),c=yi(c,a,n,null),c.flags|=2,r.return=t,c.return=t,r.sibling=c,t.child=r,Ba(t,e.child,null,n),r=t.child,r.memoizedState=wc(n),r.childLanes=Tc(e,s,n),t.memoizedState=Cc,t=pc(null,r)):(uo(t),t.child=e.child,t.flags|=128,t=null);else if(so(t),uf(c)){if(s=c.nextSibling&&c.nextSibling.dataset,s)var u=s.dgst;s=u,r=Error(i(419)),r.stack=``,r.digest=s,Ki({value:r,source:null,stack:null}),t=kc(e,t,n)}else if(sc||ea(e,t,n,!1),s=(n&e.childLanes)!==0,sc||s){if(s=H,s!==null&&(r=st(s,n),r!==0&&r!==l.retryLane))throw l.retryLane=r,li(e,r),bu(s,e,r),oc;lf(c)||Mu(),t=kc(e,t,n)}else lf(c)?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,I=ff(c.nextSibling),Ii=t,L=!0,Li=null,Ri=!1,e!==null&&Fi(t,e),t=Dc(t,r.children),t.flags|=4096);return t}return a?(uo(t),c=r.fallback,a=t.mode,l=e.child,u=l.sibling,r=gi(l,{mode:`hidden`,children:r.children}),r.subtreeFlags=l.subtreeFlags&65011712,u===null?(c=yi(c,a,n,null),c.flags|=2):c=gi(u,c),c.return=t,r.return=t,r.sibling=c,t.child=r,pc(null,r),r=t.child,c=e.child.memoizedState,c===null?c=wc(n):(a=c.cachePool,a===null?a=Ca():(l=la._currentValue,a=a.parent===l?a:{parent:l,pool:l}),c={baseLanes:c.baseLanes|n,cachePool:a}),r.memoizedState=c,r.childLanes=Tc(e,s,n),t.memoizedState=Cc,pc(e.child,r)):(so(t),n=e.child,e=n.sibling,n=gi(n,{mode:`visible`,children:r.children}),n.return=t,n.sibling=null,e!==null&&(s=t.deletions,s===null?(t.deletions=[e],t.flags|=16):s.push(e)),t.child=n,t.memoizedState=null,n)}function Dc(e,t){return t=Oc({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function Oc(e,t){return e=mi(22,e,null,t),e.lanes=0,e}function kc(e,t,n){return Ba(t,e.child,null,n),e=Dc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Ac(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Qi(e.return,t,n)}function jc(e,t,n,r,i,a){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,treeForkCount:a}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i,o.treeForkCount=a)}function Mc(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=po.current,s=!!(o&2);if(s?(o=o&1|2,t.flags|=128):o&=1,j(po,o),cc(e,t,r,n),r=L?Ti:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Ac(e,n,t);else if(e.tag===19)Ac(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break a;for(;e.sibling===null;){if(e.return===null||e.return===t)break a;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(i){case`forwards`:for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&mo(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),jc(t,!1,i,n,a,r);break;case`backwards`:case`unstable_legacy-backwards`:for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&mo(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}jc(t,!0,n,null,a,r);break;case`together`:jc(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function Nc(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Xl|=t.lanes,(n&t.childLanes)===0){if(e!==null){if(ea(e,t,n,!1),(n&t.childLanes)===0)return null}else return null}if(e!==null&&t.child!==e.child)throw Error(i(153));if(t.child!==null){for(e=t.child,n=gi(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=gi(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Pc(e,t){return(e.lanes&t)!==0||(e=e.dependencies,!!(e!==null&&ta(e)))}function Fc(e,t,n){switch(t.tag){case 3:ge(t,t.stateNode.containerInfo),Xi(t,la,e.memoizedState.cache),Wi();break;case 27:case 5:ve(t);break;case 4:ge(t,t.stateNode.containerInfo);break;case 10:Xi(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,co(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated===null?(n&t.child.childLanes)===0?(so(t),e=Nc(e,t,n),e===null?null:e.sibling):Ec(e,t,n):(so(t),t.flags|=128,null);so(t);break;case 19:var i=!!(e.flags&128);if(r=(n&t.childLanes)!==0,r||=(ea(e,t,n,!1),(n&t.childLanes)!==0),i){if(r)return Mc(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),j(po,po.current),r)break;return null;case 22:return t.lanes=0,fc(e,t,n,t.pendingProps);case 24:Xi(t,la,e.memoizedState.cache)}return Nc(e,t,n)}function Ic(e,t,n){if(e!==null){if(e.memoizedProps!==t.pendingProps)sc=!0;else{if(!Pc(e,n)&&!(t.flags&128))return sc=!1,Fc(e,t,n);sc=!!(e.flags&131072)}}else sc=!1,L&&t.flags&1048576&&Mi(t,Ti,t.index);switch(t.lanes=0,t.tag){case 16:a:{var r=t.pendingProps;if(e=Aa(t.elementType),t.type=e,typeof e==`function`)hi(e)?(r=Xs(e,r),t.tag=1,t=xc(null,t,e,r,n)):(t.tag=0,t=yc(null,t,e,r,n));else{if(e!=null){var a=e.$$typeof;if(a===w){t.tag=11,t=lc(null,t,e,r,n);break a}if(a===ee){t.tag=14,t=uc(null,t,e,r,n);break a}}throw t=ae(e)||e,Error(i(306,t,``))}}return t;case 0:return yc(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,a=Xs(r,t.pendingProps),xc(e,t,r,a,n);case 3:a:{if(ge(t,t.stateNode.containerInfo),e===null)throw Error(i(387));r=t.pendingProps;var o=t.memoizedState;a=o.element,Wa(e,t),Za(t,r,null,n);var s=t.memoizedState;if(r=s.cache,Xi(t,la,r),r!==o.cache&&$i(t,[la],n,!0),Xa(),r=s.element,o.isDehydrated){if(o={element:r,isDehydrated:!1,cache:s.cache},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){t=Sc(e,t,r,n);break a}if(r!==a){a=Ci(Error(i(424)),t),Ki(a),t=Sc(e,t,r,n);break a}switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName===`HTML`?e.ownerDocument.body:e}for(I=ff(e.firstChild),Ii=t,L=!0,Li=null,Ri=!0,n=Va(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(Wi(),r===a){t=Nc(e,t,n);break a}cc(e,t,r,n)}t=t.child}return t;case 26:return vc(e,t),e===null?(n=Nf(t.type,null,t.pendingProps,null))?t.memoizedState=n:L||(n=t.type,e=t.pendingProps,r=Wd(me.current).createElement(n),r[ft]=t,r[pt]=e,Rd(r,n,e),Tt(r),t.stateNode=r):t.memoizedState=Nf(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return ve(t),e===null&&L&&(r=t.stateNode=gf(t.type,t.pendingProps,me.current),Ii=t,Ri=!0,a=I,tf(t.type)?(pf=a,I=ff(r.firstChild)):I=a),cc(e,t,t.pendingProps.children,n),vc(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&L&&((a=r=I)&&(r=of(r,t.type,t.pendingProps,Ri),r===null?a=!1:(t.stateNode=r,Ii=t,I=ff(r.firstChild),Ri=!1,a=!0)),a||Bi(t)),ve(t),a=t.type,o=t.pendingProps,s=e===null?null:e.memoizedProps,r=o.children,qd(a,o)?r=null:s!==null&&qd(a,s)&&(t.flags|=32),t.memoizedState!==null&&(a=Eo(e,t,ko,null,null,n),np._currentValue=a),vc(e,t),cc(e,t,r,n),t.child;case 6:return e===null&&L&&((e=n=I)&&(n=sf(n,t.pendingProps,Ri),n===null?e=!1:(t.stateNode=n,Ii=t,I=null,e=!0)),e||Bi(t)),null;case 13:return Ec(e,t,n);case 4:return ge(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Ba(t,null,r,n):cc(e,t,r,n),t.child;case 11:return lc(e,t,t.type,t.pendingProps,n);case 7:return cc(e,t,t.pendingProps,n),t.child;case 8:return cc(e,t,t.pendingProps.children,n),t.child;case 12:return cc(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,Xi(t,t.type,r.value),cc(e,t,r.children,n),t.child;case 9:return a=t.type._context,r=t.pendingProps.children,na(t),a=ra(a),r=r(a),t.flags|=1,cc(e,t,r,n),t.child;case 14:return uc(e,t,t.type,t.pendingProps,n);case 15:return dc(e,t,t.type,t.pendingProps,n);case 19:return Mc(e,t,n);case 31:return _c(e,t,n);case 22:return fc(e,t,n,t.pendingProps);case 24:return na(t),r=ra(la),e===null?(a=xa(),a===null&&(a=H,o=ua(),a.pooledCache=o,o.refCount++,o!==null&&(a.pooledCacheLanes|=n),a=o),t.memoizedState={parent:r,cache:a},Ua(t),Xi(t,la,a)):((e.lanes&n)!==0&&(Wa(e,t),Za(t,null,null,n),Xa()),a=e.memoizedState,o=t.memoizedState,a.parent===r?(r=o.cache,Xi(t,la,r),r!==a.cache&&$i(t,[la],n,!0)):(a={parent:r,cache:r},t.memoizedState=a,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=a),Xi(t,la,r))),cc(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(i(156,t.tag))}function Lc(e){e.flags|=4}function Rc(e,t,n,r,i){if((t=!!(e.mode&32))&&(t=!1),t){if(e.flags|=16777216,(i&335544128)===i){if(e.stateNode.complete)e.flags|=8192;else if(ku())e.flags|=8192;else throw ja=Da,Ta}}else e.flags&=-16777217}function zc(e,t){if(t.type!==`stylesheet`||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!Jf(t)){if(ku())e.flags|=8192;else throw ja=Da,Ta}}function Bc(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:tt(),e.lanes|=t,eu|=t)}function Vc(e,t){if(!L)switch(e.tailMode){case`hidden`:t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case`collapsed`:n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Hc(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&65011712,r|=i.flags&65011712,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function Uc(e,t,n){var r=t.pendingProps;switch(Pi(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Hc(t),null;case 1:return Hc(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),Zi(la),_e(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(Ui(t)?Lc(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Gi())),Hc(t),null;case 26:var a=t.type,o=t.memoizedState;return e===null?(Lc(t),o===null?(Hc(t),Rc(t,a,null,r,n)):(Hc(t),zc(t,o))):o?o===e.memoizedState?(Hc(t),t.flags&=-16777217):(Lc(t),Hc(t),zc(t,o)):(e=e.memoizedProps,e!==r&&Lc(t),Hc(t),Rc(t,a,e,r,n)),null;case 27:if(ye(t),n=me.current,a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Lc(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return Hc(t),null}e=fe.current,Ui(t)?Vi(t,e):(e=gf(a,r,n),t.stateNode=e,Lc(t))}return Hc(t),null;case 5:if(ye(t),a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Lc(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return Hc(t),null}if(o=fe.current,Ui(t))Vi(t,o);else{var s=Wd(me.current);switch(o){case 1:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case 2:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;default:switch(a){case`svg`:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case`math`:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;case`script`:o=s.createElement(`div`),o.innerHTML=`<script><\/script>`,o=o.removeChild(o.firstChild);break;case`select`:o=typeof r.is==`string`?s.createElement(`select`,{is:r.is}):s.createElement(`select`),r.multiple?o.multiple=!0:r.size&&(o.size=r.size);break;default:o=typeof r.is==`string`?s.createElement(a,{is:r.is}):s.createElement(a)}}o[ft]=t,o[pt]=r;a:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)o.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break a;for(;s.sibling===null;){if(s.return===null||s.return===t)break a;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=o;a:switch(Rd(o,a,r),a){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&Lc(t)}}return Hc(t),Rc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&Lc(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(i(166));if(e=me.current,Ui(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,a=Ii,a!==null)switch(a.tag){case 27:case 5:r=a.memoizedProps}e[ft]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||Id(e.nodeValue,n)),e||Bi(t,!0)}else e=Wd(e).createTextNode(r),e[ft]=t,t.stateNode=e}return Hc(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Ui(t),n!==null){if(e===null){if(!r)throw Error(i(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(557));e[ft]=t}else Wi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Hc(t),e=!1}else n=Gi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(fo(t),t):(fo(t),null);if(t.flags&128)throw Error(i(558))}return Hc(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=Ui(t),r!==null&&r.dehydrated!==null){if(e===null){if(!a)throw Error(i(318));if(a=t.memoizedState,a=a===null?null:a.dehydrated,!a)throw Error(i(317));a[ft]=t}else Wi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Hc(t),a=!1}else a=Gi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(fo(t),t):(fo(t),null)}return fo(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,a=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(a=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==a&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Bc(t,t.updateQueue),Hc(t),null);case 4:return _e(),e===null&&Ed(t.stateNode.containerInfo),Hc(t),null;case 10:return Zi(t.type),Hc(t),null;case 19:if(de(po),r=t.memoizedState,r===null)return Hc(t),null;if(a=!!(t.flags&128),o=r.rendering,o===null){if(a)Vc(r,!1);else{if(Yl!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=mo(e),o!==null){for(t.flags|=128,Vc(r,!1),e=o.updateQueue,t.updateQueue=e,Bc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)_i(n,e),n=n.sibling;return j(po,po.current&1|2),L&&ji(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&Me()>ou&&(t.flags|=128,a=!0,Vc(r,!1),t.lanes=4194304)}}else{if(!a){if(e=mo(o),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,Bc(t,e),Vc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!L)return Hc(t),null}else 2*Me()-r.renderingStartTime>ou&&n!==536870912&&(t.flags|=128,a=!0,Vc(r,!1),t.lanes=4194304)}r.isBackwards?(o.sibling=t.child,t.child=o):(e=r.last,e===null?t.child=o:e.sibling=o,r.last=o)}return r.tail===null?(Hc(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=Me(),e.sibling=null,n=po.current,j(po,a?n&1|2:n&1),L&&ji(t,r.treeForkCount),e);case 22:case 23:return fo(t),io(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Hc(t),t.subtreeFlags&6&&(t.flags|=8192)):Hc(t),n=t.updateQueue,n!==null&&Bc(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&de(ba),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Zi(la),Hc(t),null;case 25:return null;case 30:return null}throw Error(i(156,t.tag))}function Wc(e,t){switch(Pi(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Zi(la),_e(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return ye(t),null;case 31:if(t.memoizedState!==null){if(fo(t),t.alternate===null)throw Error(i(340));Wi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(fo(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(i(340));Wi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return de(po),null;case 4:return _e(),null;case 10:return Zi(t.type),null;case 22:case 23:return fo(t),io(),e!==null&&de(ba),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Zi(la),null;case 25:return null;default:return null}}function Gc(e,t){switch(Pi(t),t.tag){case 3:Zi(la),_e();break;case 26:case 27:case 5:ye(t);break;case 4:_e();break;case 31:t.memoizedState!==null&&fo(t);break;case 13:fo(t);break;case 19:de(po);break;case 10:Zi(t.type);break;case 22:case 23:fo(t),io(),e!==null&&de(ba);break;case 24:Zi(la)}}function Kc(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){K(t,t.return,e)}}function qc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){K(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){K(t,t.return,e)}}function Jc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{$a(t,n)}catch(t){K(e,e.return,t)}}}function Yc(e,t,n){n.props=Xs(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){K(e,t,n)}}function Xc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){K(e,t,n)}}function Zc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null){if(typeof r==`function`)try{r()}catch(n){K(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){K(e,t,n)}else n.current=null}}function Qc(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){K(e,e.return,t)}}function $c(e,t,n){try{var r=e.stateNode;zd(r,e.type,n,t),r[pt]=t}catch(t){K(e,e.return,t)}}function el(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&tf(e.type)||e.tag===4}function tl(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||el(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&tf(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function nl(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=on));else if(r!==4&&(r===27&&tf(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(nl(e,t,n),e=e.sibling;e!==null;)nl(e,t,n),e=e.sibling}function rl(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&tf(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(rl(e,t,n),e=e.sibling;e!==null;)rl(e,t,n),e=e.sibling}function il(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Rd(t,r,n),t[ft]=e,t[pt]=n}catch(t){K(e,e.return,t)}}var al=!1,ol=!1,sl=!1,cl=typeof WeakSet==`function`?WeakSet:Set,ll=null;function ul(e,t){if(e=e.containerInfo,Hd=dp,e=Nr(e),Pr(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var a=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break a}var s=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||a!==0&&f.nodeType!==3||(c=s+a),f!==o||r!==0&&f.nodeType!==3||(l=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===a&&(c=s),p===o&&++d===r&&(l=s),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(Ud={focusedElem:e,selectionRange:n},dp=!1,ll=t;ll!==null;)if(t=ll,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,ll=e;else for(;ll!==null;){switch(t=ll,o=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n<e.length;n++)a=e[n],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if(e&1024&&o!==null){e=void 0,n=t,a=o.memoizedProps,o=o.memoizedState,r=n.stateNode;try{var h=Xs(n.type,a);e=r.getSnapshotBeforeUpdate(h,o),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){K(n,n.return,e)}}break;case 3:if(e&1024){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)af(e);else if(n===1)switch(e.nodeName){case`HEAD`:case`HTML`:case`BODY`:af(e);break;default:e.textContent=``}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if(e&1024)throw Error(i(163))}if(e=t.sibling,e!==null){e.return=t.return,ll=e;break}ll=t.return}}function dl(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:El(e,n),r&4&&Kc(5,n);break;case 1:if(El(e,n),r&4){if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){K(n,n.return,e)}else{var i=Xs(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){K(n,n.return,e)}}}r&64&&Jc(n),r&512&&Xc(n,n.return);break;case 3:if(El(e,n),r&64&&(e=n.updateQueue,e!==null)){if(t=null,n.child!==null)switch(n.child.tag){case 27:case 5:t=n.child.stateNode;break;case 1:t=n.child.stateNode}try{$a(e,t)}catch(e){K(n,n.return,e)}}break;case 27:t===null&&r&4&&il(n);case 26:case 5:El(e,n),t===null&&r&4&&Qc(n),r&512&&Xc(n,n.return);break;case 12:El(e,n);break;case 31:El(e,n),r&4&&_l(e,n);break;case 13:El(e,n),r&4&&vl(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=$u.bind(null,n),df(e,n))));break;case 22:if(r=n.memoizedState!==null||al,!r){t=t!==null&&t.memoizedState!==null||ol,i=al;var a=ol;al=r,(ol=t)&&!a?Ol(e,n,!!(n.subtreeFlags&8772)):El(e,n),al=i,ol=a}break;case 30:break;default:El(e,n)}}function fl(e){var t=e.alternate;t!==null&&(e.alternate=null,fl(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&bt(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var pl=null,ml=!1;function hl(e,t,n){for(n=n.child;n!==null;)gl(e,t,n),n=n.sibling}function gl(e,t,n){if(He&&typeof He.onCommitFiberUnmount==`function`)try{He.onCommitFiberUnmount(Ve,n)}catch{}switch(n.tag){case 26:ol||Zc(n,t),hl(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:ol||Zc(n,t);var r=pl,i=ml;tf(n.type)&&(pl=n.stateNode,ml=!1),hl(e,t,n),_f(n.stateNode),pl=r,ml=i;break;case 5:ol||Zc(n,t);case 6:if(r=pl,i=ml,pl=null,hl(e,t,n),pl=r,ml=i,pl!==null){if(ml)try{(pl.nodeType===9?pl.body:pl.nodeName===`HTML`?pl.ownerDocument.body:pl).removeChild(n.stateNode)}catch(e){K(n,t,e)}else try{pl.removeChild(n.stateNode)}catch(e){K(n,t,e)}}break;case 18:pl!==null&&(ml?(e=pl,nf(e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,n.stateNode),Lp(e)):nf(pl,n.stateNode));break;case 4:r=pl,i=ml,pl=n.stateNode.containerInfo,ml=!0,hl(e,t,n),pl=r,ml=i;break;case 0:case 11:case 14:case 15:qc(2,n,t),ol||qc(4,n,t),hl(e,t,n);break;case 1:ol||(Zc(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&Yc(n,t,r)),hl(e,t,n);break;case 21:hl(e,t,n);break;case 22:ol=(r=ol)||n.memoizedState!==null,hl(e,t,n),ol=r;break;default:hl(e,t,n)}}function _l(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Lp(e)}catch(e){K(t,t.return,e)}}}function vl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Lp(e)}catch(e){K(t,t.return,e)}}function yl(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new cl),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new cl),t;default:throw Error(i(435,e.tag))}}function bl(e,t){var n=yl(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=ed.bind(null,e,t);t.then(r,r)}})}function xl(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var a=n[r],o=e,s=t,c=s;a:for(;c!==null;){switch(c.tag){case 27:if(tf(c.type)){pl=c.stateNode,ml=!1;break a}break;case 5:pl=c.stateNode,ml=!1;break a;case 3:case 4:pl=c.stateNode.containerInfo,ml=!0;break a}c=c.return}if(pl===null)throw Error(i(160));gl(o,s,a),pl=null,ml=!1,o=a.alternate,o!==null&&(o.return=null),a.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)Cl(t,e),t=t.sibling}var Sl=null;function Cl(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:xl(t,e),wl(e),r&4&&(qc(3,e,e.return),Kc(3,e),qc(5,e,e.return));break;case 1:xl(t,e),wl(e),r&512&&(ol||n===null||Zc(n,n.return)),r&64&&al&&(e=e.updateQueue,e!==null&&(r=e.callbacks,r!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?r:n.concat(r))));break;case 26:var a=Sl;if(xl(t,e),wl(e),r&512&&(ol||n===null||Zc(n,n.return)),r&4){var o=n===null?null:n.memoizedState;if(r=e.memoizedState,n===null){if(r===null){if(e.stateNode===null){a:{r=e.type,n=e.memoizedProps,a=a.ownerDocument||a;b:switch(r){case`title`:o=a.getElementsByTagName(`title`)[0],(!o||o[yt]||o[ft]||o.namespaceURI===`http://www.w3.org/2000/svg`||o.hasAttribute(`itemprop`))&&(o=a.createElement(r),a.head.insertBefore(o,a.querySelector(`head > title`))),Rd(o,r,n),o[ft]=e,Tt(o),r=o;break a;case`link`:var s=Gf(`link`,`href`,a).get(r+(n.href||``));if(s){for(var c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`href`)===(n.href==null||n.href===``?null:n.href)&&o.getAttribute(`rel`)===(n.rel==null?null:n.rel)&&o.getAttribute(`title`)===(n.title==null?null:n.title)&&o.getAttribute(`crossorigin`)===(n.crossOrigin==null?null:n.crossOrigin)){s.splice(c,1);break b}}o=a.createElement(r),Rd(o,r,n),a.head.appendChild(o);break;case`meta`:if(s=Gf(`meta`,`content`,a).get(r+(n.content||``))){for(c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`content`)===(n.content==null?null:``+n.content)&&o.getAttribute(`name`)===(n.name==null?null:n.name)&&o.getAttribute(`property`)===(n.property==null?null:n.property)&&o.getAttribute(`http-equiv`)===(n.httpEquiv==null?null:n.httpEquiv)&&o.getAttribute(`charset`)===(n.charSet==null?null:n.charSet)){s.splice(c,1);break b}}o=a.createElement(r),Rd(o,r,n),a.head.appendChild(o);break;default:throw Error(i(468,r))}o[ft]=e,Tt(o),r=o}e.stateNode=r}else Kf(a,e.type,e.stateNode)}else e.stateNode=Bf(a,r,e.memoizedProps)}else o===r?r===null&&e.stateNode!==null&&$c(e,e.memoizedProps,n.memoizedProps):(o===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):o.count--,r===null?Kf(a,e.type,e.stateNode):Bf(a,r,e.memoizedProps))}break;case 27:xl(t,e),wl(e),r&512&&(ol||n===null||Zc(n,n.return)),n!==null&&r&4&&$c(e,e.memoizedProps,n.memoizedProps);break;case 5:if(xl(t,e),wl(e),r&512&&(ol||n===null||Zc(n,n.return)),e.flags&32){a=e.stateNode;try{Zt(a,``)}catch(t){K(e,e.return,t)}}r&4&&e.stateNode!=null&&(a=e.memoizedProps,$c(e,a,n===null?a:n.memoizedProps)),r&1024&&(sl=!0);break;case 6:if(xl(t,e),wl(e),r&4){if(e.stateNode===null)throw Error(i(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){K(e,e.return,t)}}break;case 3:if(Wf=null,a=Sl,Sl=bf(t.containerInfo),xl(t,e),Sl=a,wl(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Lp(t.containerInfo)}catch(t){K(e,e.return,t)}sl&&(sl=!1,Tl(e));break;case 4:r=Sl,Sl=bf(e.stateNode.containerInfo),xl(t,e),wl(e),Sl=r;break;case 12:xl(t,e),wl(e);break;case 31:xl(t,e),wl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,bl(e,r)));break;case 13:xl(t,e),wl(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(iu=Me()),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,bl(e,r)));break;case 22:a=e.memoizedState!==null;var l=n!==null&&n.memoizedState!==null,u=al,d=ol;if(al=u||a,ol=d||l,xl(t,e),ol=d,al=u,wl(e),r&8192)a:for(t=e.stateNode,t._visibility=a?t._visibility&-2:t._visibility|1,a&&(n===null||l||al||ol||Dl(e)),n=null,t=e;;){if(t.tag===5||t.tag===26){if(n===null){l=n=t;try{if(o=l.stateNode,a)s=o.style,typeof s.setProperty==`function`?s.setProperty(`display`,`none`,`important`):s.display=`none`;else{c=l.stateNode;var f=l.memoizedProps.style,p=f!=null&&f.hasOwnProperty(`display`)?f.display:null;c.style.display=p==null||typeof p==`boolean`?``:(``+p).trim()}}catch(e){K(l,l.return,e)}}}else if(t.tag===6){if(n===null){l=t;try{l.stateNode.nodeValue=a?``:l.memoizedProps}catch(e){K(l,l.return,e)}}}else if(t.tag===18){if(n===null){l=t;try{var m=l.stateNode;a?rf(m,!0):rf(l.stateNode,!1)}catch(e){K(l,l.return,e)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break a;for(;t.sibling===null;){if(t.return===null||t.return===e)break a;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}r&4&&(r=e.updateQueue,r!==null&&(n=r.retryQueue,n!==null&&(r.retryQueue=null,bl(e,n))));break;case 19:xl(t,e),wl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,bl(e,r)));break;case 30:break;case 21:break;default:xl(t,e),wl(e)}}function wl(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(el(r)){n=r;break}r=r.return}if(n==null)throw Error(i(160));switch(n.tag){case 27:var a=n.stateNode;rl(e,tl(e),a);break;case 5:var o=n.stateNode;n.flags&32&&(Zt(o,``),n.flags&=-33),rl(e,tl(e),o);break;case 3:case 4:var s=n.stateNode.containerInfo;nl(e,tl(e),s);break;default:throw Error(i(161))}}catch(t){K(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Tl(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;Tl(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function El(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)dl(e,t.alternate,t),t=t.sibling}function Dl(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:qc(4,t,t.return),Dl(t);break;case 1:Zc(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==`function`&&Yc(t,t.return,n),Dl(t);break;case 27:_f(t.stateNode);case 26:case 5:Zc(t,t.return),Dl(t);break;case 22:t.memoizedState===null&&Dl(t);break;case 30:Dl(t);break;default:Dl(t)}e=e.sibling}}function Ol(e,t,n){for(n&&=!!(t.subtreeFlags&8772),t=t.child;t!==null;){var r=t.alternate,i=e,a=t,o=a.flags;switch(a.tag){case 0:case 11:case 15:Ol(i,a,n),Kc(4,a);break;case 1:if(Ol(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){K(r,r.return,e)}if(r=a,i=r.updateQueue,i!==null){var s=r.stateNode;try{var c=i.shared.hiddenCallbacks;if(c!==null)for(i.shared.hiddenCallbacks=null,i=0;i<c.length;i++)Qa(c[i],s)}catch(e){K(r,r.return,e)}}n&&o&64&&Jc(a),Xc(a,a.return);break;case 27:il(a);case 26:case 5:Ol(i,a,n),n&&r===null&&o&4&&Qc(a),Xc(a,a.return);break;case 12:Ol(i,a,n);break;case 31:Ol(i,a,n),n&&o&4&&_l(i,a);break;case 13:Ol(i,a,n),n&&o&4&&vl(i,a);break;case 22:a.memoizedState===null&&Ol(i,a,n),Xc(a,a.return);break;case 30:break;default:Ol(i,a,n)}t=t.sibling}}function kl(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&da(n))}function Al(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&da(e))}function B(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)jl(e,t,n,r),t=t.sibling}function jl(e,t,n,r){var i=t.flags;switch(t.tag){case 0:case 11:case 15:B(e,t,n,r),i&2048&&Kc(9,t);break;case 1:B(e,t,n,r);break;case 3:B(e,t,n,r),i&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&da(e)));break;case 12:if(i&2048){B(e,t,n,r),e=t.stateNode;try{var a=t.memoizedProps,o=a.id,s=a.onPostCommit;typeof s==`function`&&s(o,t.alternate===null?`mount`:`update`,e.passiveEffectDuration,-0)}catch(e){K(t,t.return,e)}}else B(e,t,n,r);break;case 31:B(e,t,n,r);break;case 13:B(e,t,n,r);break;case 23:break;case 22:a=t.stateNode,o=t.alternate,t.memoizedState===null?a._visibility&2?B(e,t,n,r):(a._visibility|=2,Ml(e,t,n,r,!!(t.subtreeFlags&10256)||!1)):a._visibility&2?B(e,t,n,r):Nl(e,t),i&2048&&kl(o,t);break;case 24:B(e,t,n,r),i&2048&&Al(t.alternate,t);break;default:B(e,t,n,r)}}function Ml(e,t,n,r,i){for(i&&=!!(t.subtreeFlags&10256)||!1,t=t.child;t!==null;){var a=e,o=t,s=n,c=r,l=o.flags;switch(o.tag){case 0:case 11:case 15:Ml(a,o,s,c,i),Kc(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,Ml(a,o,s,c,i)):u._visibility&2?Ml(a,o,s,c,i):Nl(a,o),i&&l&2048&&kl(o.alternate,o);break;case 24:Ml(a,o,s,c,i),i&&l&2048&&Al(o.alternate,o);break;default:Ml(a,o,s,c,i)}t=t.sibling}}function Nl(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,r=t,i=r.flags;switch(r.tag){case 22:Nl(n,r),i&2048&&kl(r.alternate,r);break;case 24:Nl(n,r),i&2048&&Al(r.alternate,r);break;default:Nl(n,r)}t=t.sibling}}var Pl=8192;function Fl(e,t,n){if(e.subtreeFlags&Pl)for(e=e.child;e!==null;)Il(e,t,n),e=e.sibling}function Il(e,t,n){switch(e.tag){case 26:Fl(e,t,n),e.flags&Pl&&e.memoizedState!==null&&Yf(n,Sl,e.memoizedState,e.memoizedProps);break;case 5:Fl(e,t,n);break;case 3:case 4:var r=Sl;Sl=bf(e.stateNode.containerInfo),Fl(e,t,n),Sl=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=Pl,Pl=16777216,Fl(e,t,n),Pl=r):Fl(e,t,n));break;default:Fl(e,t,n)}}function Ll(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Rl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];ll=r,Vl(r,e)}Ll(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)zl(e),e=e.sibling}function zl(e){switch(e.tag){case 0:case 11:case 15:Rl(e),e.flags&2048&&qc(9,e,e.return);break;case 3:Rl(e);break;case 12:Rl(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,Bl(e)):Rl(e);break;default:Rl(e)}}function Bl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];ll=r,Vl(r,e)}Ll(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:qc(8,t,t.return),Bl(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,Bl(t));break;default:Bl(t)}e=e.sibling}}function Vl(e,t){for(;ll!==null;){var n=ll;switch(n.tag){case 0:case 11:case 15:qc(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var r=n.memoizedState.cachePool.pool;r!=null&&r.refCount++}break;case 24:da(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,ll=r;else a:for(n=e;ll!==null;){r=ll;var i=r.sibling,a=r.return;if(fl(r),r===n){ll=null;break a}if(i!==null){i.return=a,ll=i;break a}ll=a}}}var Hl={getCacheForType:function(e){var t=ra(la),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return ra(la).controller.signal}},Ul=typeof WeakMap==`function`?WeakMap:Map,V=0,H=null,U=null,W=0,G=0,Wl=null,Gl=!1,Kl=!1,ql=!1,Jl=0,Yl=0,Xl=0,Zl=0,Ql=0,$l=0,eu=0,tu=null,nu=null,ru=!1,iu=0,au=0,ou=1/0,su=null,cu=null,lu=0,uu=null,du=null,fu=0,pu=0,mu=null,hu=null,gu=0,_u=null;function vu(){return V&2&&W!==0?W&-W:k.T===null?lt():gd()}function yu(){if($l===0){if(!(W&536870912)||L){var e=Ye;Ye<<=1,!(Ye&3932160)&&(Ye=262144),$l=e}else $l=536870912}return e=ao.current,e!==null&&(e.flags|=32),$l}function bu(e,t,n){(e===H&&(G===2||G===9)||e.cancelPendingCommit!==null)&&(Du(e,0),wu(e,W,$l,!1)),rt(e,n),(!(V&2)||e!==H)&&(e===H&&(!(V&2)&&(Zl|=n),Yl===4&&wu(e,W,$l,!1)),cd(e))}function xu(e,t,n){if(V&6)throw Error(i(327));var r=!n&&!(t&127)&&(t&e.expiredLanes)===0||$e(e,t),a=r?Fu(e,t):Nu(e,t,!0),o=r;do{if(a===0){Kl&&!r&&wu(e,t,0,!1);break}if(n=e.current.alternate,o&&!Cu(n)){a=Nu(e,t,!1),o=!1;continue}if(a===2){if(o=t,e.errorRecoveryDisabledLanes&o)var s=0;else s=e.pendingLanes&-536870913,s=s===0?s&536870912?536870912:0:s;if(s!==0){t=s;a:{var c=e;a=tu;var l=c.current.memoizedState.isDehydrated;if(l&&(Du(c,s).flags|=256),s=Nu(c,s,!1),s!==2){if(ql&&!l){c.errorRecoveryDisabledLanes|=o,Zl|=o,a=4;break a}o=nu,nu=a,o!==null&&(nu===null?nu=o:nu.push.apply(nu,o))}a=s}if(o=!1,a!==2)continue}}if(a===1){Du(e,0),wu(e,t,0,!0);break}a:{switch(r=e,o=a,o){case 0:case 1:throw Error(i(345));case 4:if((t&4194048)!==t)break;case 6:wu(r,t,$l,!Gl);break a;case 2:nu=null;break;case 3:case 5:break;default:throw Error(i(329))}if((t&62914560)===t&&(a=iu+300-Me(),10<a)){if(wu(r,t,$l,!Gl),Qe(r,0,!0)!==0)break a;fu=t,r.timeoutHandle=Xd(Su.bind(null,r,n,nu,su,ru,t,$l,Zl,eu,Gl,o,`Throttled`,-0,0),a);break a}Su(r,n,nu,su,ru,t,$l,Zl,eu,Gl,o,null,-0,0)}break}while(1);cd(e)}function Su(e,t,n,r,i,a,o,s,c,l,u,d,f,p){if(e.timeoutHandle=-1,d=t.subtreeFlags,d&8192||(d&16785408)==16785408){d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:on},Il(t,a,d);var m=(a&62914560)===a?iu-Me():(a&4194048)===a?au-Me():0;if(m=Zf(d,m),m!==null){fu=a,e.cancelPendingCommit=m(Hu.bind(null,e,t,a,n,r,i,o,s,c,u,d,null,f,p)),wu(e,a,o,!l);return}}Hu(e,t,a,n,r,i,o,s,c)}function Cu(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var r=0;r<n.length;r++){var i=n[r],a=i.getSnapshot;i=i.value;try{if(!Or(a(),i))return!1}catch{return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function wu(e,t,n,r){t&=~Ql,t&=~Zl,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-We(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&at(e,n,t)}function Tu(){return V&6?!0:(ld(0,!1),!1)}function Eu(){if(U!==null){if(G===0)var e=U.return;else e=U,Yi=Ji=null,Mo(e),Pa=null,Fa=0,e=U;for(;e!==null;)Gc(e.alternate,e),e=e.return;U=null}}function Du(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,Zd(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),fu=0,Eu(),H=e,U=n=gi(e.current,null),W=t,G=0,Wl=null,Gl=!1,Kl=$e(e,t),ql=!1,eu=$l=Ql=Zl=Xl=Yl=0,nu=tu=null,ru=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var i=31-We(r),a=1<<i;t|=e[i],r&=~a}return Jl=t,oi(),n}function Ou(e,t){R=null,k.H=Hs,t===wa||t===Ea?(t=Ma(),G=3):t===Ta?(t=Ma(),G=4):G=t===oc?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,Wl=t,U===null&&(Yl=1,ec(e,Ci(t,e.current)))}function ku(){var e=ao.current;return e===null?!0:(W&4194048)===W?oo===null:(W&62914560)===W||W&536870912?e===oo:!1}function Au(){var e=k.H;return k.H=Hs,e===null?Hs:e}function ju(){var e=k.A;return k.A=Hl,e}function Mu(){Yl=4,Gl||(W&4194048)!==W&&ao.current!==null||(Kl=!0),!(Xl&134217727)&&!(Zl&134217727)||H===null||wu(H,W,$l,!1)}function Nu(e,t,n){var r=V;V|=2;var i=Au(),a=ju();(H!==e||W!==t)&&(su=null,Du(e,t)),t=!1;var o=Yl;a:do try{if(G!==0&&U!==null){var s=U,c=Wl;switch(G){case 8:Eu(),o=6;break a;case 3:case 2:case 9:case 6:ao.current===null&&(t=!0);var l=G;if(G=0,Wl=null,zu(e,s,c,l),n&&Kl){o=0;break a}break;default:l=G,G=0,Wl=null,zu(e,s,c,l)}}Pu(),o=Yl;break}catch(t){Ou(e,t)}while(1);return t&&e.shellSuspendCounter++,Yi=Ji=null,V=r,k.H=i,k.A=a,U===null&&(H=null,W=0,oi()),o}function Pu(){for(;U!==null;)Lu(U)}function Fu(e,t){var n=V;V|=2;var r=Au(),a=ju();H!==e||W!==t?(su=null,ou=Me()+500,Du(e,t)):Kl=$e(e,t);a:do try{if(G!==0&&U!==null){t=U;var o=Wl;b:switch(G){case 1:G=0,Wl=null,zu(e,t,o,1);break;case 2:case 9:if(Oa(o)){G=0,Wl=null,Ru(t);break}t=function(){G!==2&&G!==9||H!==e||(G=7),cd(e)},o.then(t,t);break a;case 3:G=7;break a;case 4:G=5;break a;case 7:Oa(o)?(G=0,Wl=null,Ru(t)):(G=0,Wl=null,zu(e,t,o,7));break;case 5:var s=null;switch(U.tag){case 26:s=U.memoizedState;case 5:case 27:var c=U;if(s?Jf(s):c.stateNode.complete){G=0,Wl=null;var l=c.sibling;if(l!==null)U=l;else{var u=c.return;u===null?U=null:(U=u,Bu(u))}break b}}G=0,Wl=null,zu(e,t,o,5);break;case 6:G=0,Wl=null,zu(e,t,o,6);break;case 8:Eu(),Yl=6;break a;default:throw Error(i(462))}}Iu();break}catch(t){Ou(e,t)}while(1);return Yi=Ji=null,k.H=r,k.A=a,V=n,U===null?(H=null,W=0,oi(),Yl):0}function Iu(){for(;U!==null&&!Ae();)Lu(U)}function Lu(e){var t=Ic(e.alternate,e,Jl);e.memoizedProps=e.pendingProps,t===null?Bu(e):U=t}function Ru(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=bc(n,t,t.pendingProps,t.type,void 0,W);break;case 11:t=bc(n,t,t.pendingProps,t.type.render,t.ref,W);break;case 5:Mo(t);default:Gc(n,t),t=U=_i(t,Jl),t=Ic(n,t,Jl)}e.memoizedProps=e.pendingProps,t===null?Bu(e):U=t}function zu(e,t,n,r){Yi=Ji=null,Mo(t),Pa=null,Fa=0;var i=t.return;try{if(ac(e,i,t,n,W)){Yl=1,ec(e,Ci(n,e.current)),U=null;return}}catch(t){if(i!==null)throw U=i,t;Yl=1,ec(e,Ci(n,e.current)),U=null;return}t.flags&32768?(L||r===1?e=!0:Kl||W&536870912?e=!1:(Gl=e=!0,(r===2||r===9||r===3||r===6)&&(r=ao.current,r!==null&&r.tag===13&&(r.flags|=16384))),Vu(t,e)):Bu(t)}function Bu(e){var t=e;do{if(t.flags&32768){Vu(t,Gl);return}e=t.return;var n=Uc(t.alternate,t,Jl);if(n!==null){U=n;return}if(t=t.sibling,t!==null){U=t;return}U=t=e}while(t!==null);Yl===0&&(Yl=5)}function Vu(e,t){do{var n=Wc(e.alternate,e);if(n!==null){n.flags&=32767,U=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){U=e;return}U=e=n}while(e!==null);Yl=6,U=null}function Hu(e,t,n,r,a,o,s,c,l){e.cancelPendingCommit=null;do qu();while(lu!==0);if(V&6)throw Error(i(327));if(t!==null){if(t===e.current)throw Error(i(177));if(o=t.lanes|t.childLanes,o|=ai,it(e,n,o,s,c,l),e===H&&(U=H=null,W=0),du=t,uu=e,fu=n,pu=o,mu=a,hu=r,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,td(Ie,function(){return Ju(),null})):(e.callbackNode=null,e.callbackPriority=0),r=!!(t.flags&13878),t.subtreeFlags&13878||r){r=k.T,k.T=null,a=A.p,A.p=2,s=V,V|=4;try{ul(e,t,n)}finally{V=s,A.p=a,k.T=r}}lu=1,Uu(),Wu(),Gu()}}function Uu(){if(lu===1){lu=0;var e=uu,t=du,n=!!(t.flags&13878);if(t.subtreeFlags&13878||n){n=k.T,k.T=null;var r=A.p;A.p=2;var i=V;V|=4;try{Cl(t,e);var a=Ud,o=Nr(e.containerInfo),s=a.focusedElem,c=a.selectionRange;if(o!==s&&s&&s.ownerDocument&&Mr(s.ownerDocument.documentElement,s)){if(c!==null&&Pr(s)){var l=c.start,u=c.end;if(u===void 0&&(u=l),`selectionStart`in s)s.selectionStart=l,s.selectionEnd=Math.min(u,s.value.length);else{var d=s.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),m=s.textContent.length,h=Math.min(c.start,m),g=c.end===void 0?h:Math.min(c.end,m);!p.extend&&h>g&&(o=g,g=h,h=o);var _=jr(s,h),v=jr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;s<d.length;s++){var b=d[s];b.element.scrollLeft=b.left,b.element.scrollTop=b.top}}dp=!!Hd,Ud=Hd=null}finally{V=i,A.p=r,k.T=n}}e.current=t,lu=2}}function Wu(){if(lu===2){lu=0;var e=uu,t=du,n=!!(t.flags&8772);if(t.subtreeFlags&8772||n){n=k.T,k.T=null;var r=A.p;A.p=2;var i=V;V|=4;try{dl(e,t.alternate,t)}finally{V=i,A.p=r,k.T=n}}lu=3}}function Gu(){if(lu===4||lu===3){lu=0,je();var e=uu,t=du,n=fu,r=hu;t.subtreeFlags&10256||t.flags&10256?lu=5:(lu=0,du=uu=null,Ku(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(cu=null),M(n),t=t.stateNode,He&&typeof He.onCommitFiberRoot==`function`)try{He.onCommitFiberRoot(Ve,t,void 0,(t.current.flags&128)==128)}catch{}if(r!==null){t=k.T,i=A.p,A.p=2,k.T=null;try{for(var a=e.onRecoverableError,o=0;o<r.length;o++){var s=r[o];a(s.value,{componentStack:s.stack})}}finally{k.T=t,A.p=i}}fu&3&&qu(),cd(e),i=e.pendingLanes,n&261930&&i&42?e===_u?gu++:(gu=0,_u=e):gu=0,ld(0,!1)}}function Ku(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,da(t)))}function qu(){return Uu(),Wu(),Gu(),Ju()}function Ju(){if(lu!==5)return!1;var e=uu,t=pu;pu=0;var n=M(fu),r=k.T,a=A.p;try{A.p=32>n?32:n,k.T=null,n=mu,mu=null;var o=uu,s=fu;if(lu=0,du=uu=null,fu=0,V&6)throw Error(i(331));var c=V;if(V|=4,zl(o.current),jl(o,o.current,s,n),V=c,ld(0,!1),He&&typeof He.onPostCommitFiberRoot==`function`)try{He.onPostCommitFiberRoot(Ve,o)}catch{}return!0}finally{A.p=a,k.T=r,Ku(e,t)}}function Yu(e,t,n){t=Ci(n,t),t=nc(e.stateNode,t,2),e=Ka(e,t,2),e!==null&&(rt(e,2),cd(e))}function K(e,t,n){if(e.tag===3)Yu(e,e,n);else for(;t!==null;){if(t.tag===3){Yu(t,e,n);break}if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(cu===null||!cu.has(r))){e=Ci(n,e),n=rc(2),r=Ka(t,n,2),r!==null&&(ic(n,r,t,e),rt(r,2),cd(r));break}}t=t.return}}function Xu(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Ul;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(ql=!0,i.add(n),e=Zu.bind(null,e,t,n),t.then(e,e))}function Zu(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,H===e&&(W&n)===n&&(Yl===4||Yl===3&&(W&62914560)===W&&300>Me()-iu?!(V&2)&&Du(e,0):Ql|=n,eu===W&&(eu=0)),cd(e)}function Qu(e,t){t===0&&(t=tt()),e=li(e,t),e!==null&&(rt(e,t),cd(e))}function $u(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Qu(e,n)}function ed(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,a=e.memoizedState;a!==null&&(n=a.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(i(314))}r!==null&&r.delete(t),Qu(e,n)}function td(e,t){return Oe(e,t)}var nd=null,rd=null,id=!1,ad=!1,od=!1,sd=0;function cd(e){e!==rd&&e.next===null&&(rd===null?nd=rd=e:rd=rd.next=e),ad=!0,id||(id=!0,hd())}function ld(e,t){if(!od&&ad){od=!0;do for(var n=!1,r=nd;r!==null;){if(!t){if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-We(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,md(r,a))}else a=W,a=Qe(r,r===H?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||$e(r,a)||(n=!0,md(r,a))}r=r.next}while(n);od=!1}}function ud(){dd()}function dd(){ad=id=!1;var e=0;sd!==0&&Yd()&&(e=sd);for(var t=Me(),n=null,r=nd;r!==null;){var i=r.next,a=fd(r,t);a===0?(r.next=null,n===null?nd=i:n.next=i,i===null&&(rd=n)):(n=r,(e!==0||a&3)&&(ad=!0)),r=i}lu!==0&&lu!==5||ld(e,!1),sd!==0&&(sd=0)}function fd(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-We(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=et(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=H,n=W,n=Qe(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(G===2||G===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&ke(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||$e(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&ke(r),M(n)){case 2:case 8:n=Fe;break;case 32:n=Ie;break;case 268435456:n=Re;break;default:n=Ie}return r=pd.bind(null,e),n=Oe(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&ke(r),e.callbackPriority=2,e.callbackNode=null,2}function pd(e,t){if(lu!==0&&lu!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(qu()&&e.callbackNode!==n)return null;var r=W;return r=Qe(e,e===H?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(xu(e,r,t),fd(e,Me()),e.callbackNode!=null&&e.callbackNode===n?pd.bind(null,e):null)}function md(e,t){if(qu())return null;xu(e,t,!0)}function hd(){$d(function(){V&6?Oe(Pe,ud):dd()})}function gd(){if(sd===0){var e=ma;e===0&&(e=Je,Je<<=1,!(Je&261888)&&(Je=256)),sd=e}return sd}function _d(e){return e==null||typeof e==`symbol`||typeof e==`boolean`?null:typeof e==`function`?e:an(``+e)}function vd(e,t){var n=t.ownerDocument.createElement(`input`);return n.name=t.name,n.value=t.value,e.id&&n.setAttribute(`form`,e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}function yd(e,t,n,r,i){if(t===`submit`&&n&&n.stateNode===i){var a=_d((i[pt]||null).action),o=r.submitter;o&&(t=(t=o[pt]||null)?_d(t.formAction):o.getAttribute(`formAction`),t!==null&&(a=t,o=null));var s=new Dn(`action`,`action`,null,r,i);e.push({event:s,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(sd!==0){var e=o?vd(i,o):new FormData(i);Os(n,{pending:!0,data:e,method:i.method,action:a},null,e)}}else typeof a==`function`&&(s.preventDefault(),e=o?vd(i,o):new FormData(i),Os(n,{pending:!0,data:e,method:i.method,action:a},a,e))},currentTarget:i}]})}}for(var bd=0;bd<ei.length;bd++){var xd=ei[bd];ti(xd.toLowerCase(),`on`+(xd[0].toUpperCase()+xd.slice(1)))}ti(Kr,`onAnimationEnd`),ti(qr,`onAnimationIteration`),ti(Jr,`onAnimationStart`),ti(`dblclick`,`onDoubleClick`),ti(`focusin`,`onFocus`),ti(`focusout`,`onBlur`),ti(Yr,`onTransitionRun`),ti(Xr,`onTransitionStart`),ti(Zr,`onTransitionCancel`),ti(Qr,`onTransitionEnd`),kt(`onMouseEnter`,[`mouseout`,`mouseover`]),kt(`onMouseLeave`,[`mouseout`,`mouseover`]),kt(`onPointerEnter`,[`pointerout`,`pointerover`]),kt(`onPointerLeave`,[`pointerout`,`pointerover`]),Ot(`onChange`,`change click focusin focusout input keydown keyup selectionchange`.split(` `)),Ot(`onSelect`,`focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange`.split(` `)),Ot(`onBeforeInput`,[`compositionend`,`keypress`,`textInput`,`paste`]),Ot(`onCompositionEnd`,`compositionend focusout keydown keypress keyup mousedown`.split(` `)),Ot(`onCompositionStart`,`compositionstart focusout keydown keypress keyup mousedown`.split(` `)),Ot(`onCompositionUpdate`,`compositionupdate focusout keydown keypress keyup mousedown`.split(` `));var Sd=`abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting`.split(` `),Cd=new Set(`beforetoggle cancel close invalid load scroll scrollend toggle`.split(` `).concat(Sd));function q(e,t){t=!!(t&4);for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;a:{var a=void 0;if(t)for(var o=r.length-1;0<=o;o--){var s=r[o],c=s.instance,l=s.currentTarget;if(s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){ni(e)}i.currentTarget=null,a=c}else for(o=0;o<r.length;o++){if(s=r[o],c=s.instance,l=s.currentTarget,s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){ni(e)}i.currentTarget=null,a=c}}}}function J(e,t){var n=t[ht];n===void 0&&(n=t[ht]=new Set);var r=e+`__bubble`;n.has(r)||(Dd(t,e,2,!1),n.add(r))}function wd(e,t,n){var r=0;t&&(r|=4),Dd(n,e,r,t)}var Td=`_reactListening`+Math.random().toString(36).slice(2);function Ed(e){if(!e[Td]){e[Td]=!0,Et.forEach(function(t){t!==`selectionchange`&&(Cd.has(t)||wd(t,!1,e),wd(t,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Td]||(t[Td]=!0,wd(`selectionchange`,!1,t))}}function Dd(e,t,n,r){switch(vp(t)){case 2:var i=fp;break;case 8:i=pp;break;default:i=mp}n=i.bind(null,t,n,e),i=void 0,!gn||t!==`touchstart`&&t!==`touchmove`&&t!==`wheel`||(i=!0),r?i===void 0?e.addEventListener(t,n,!0):e.addEventListener(t,n,{capture:!0,passive:i}):i===void 0?e.addEventListener(t,n,!1):e.addEventListener(t,n,{passive:i})}function Od(e,t,n,r,i){var a=r;if(!(t&1)&&!(t&2)&&r!==null)a:for(;;){if(r===null)return;var s=r.tag;if(s===3||s===4){var c=r.stateNode.containerInfo;if(c===i)break;if(s===4)for(s=r.return;s!==null;){var l=s.tag;if((l===3||l===4)&&s.stateNode.containerInfo===i)return;s=s.return}for(;c!==null;){if(s=xt(c),s===null)return;if(l=s.tag,l===5||l===6||l===26||l===27){r=a=s;continue a}c=c.parentNode}}r=r.return}pn(function(){var r=a,i=cn(n),s=[];a:{var c=$r.get(e);if(c!==void 0){var l=Dn,u=e;switch(e){case`keypress`:if(Sn(n)===0)break a;case`keydown`:case`keyup`:l=Gn;break;case`focusin`:u=`focus`,l=In;break;case`focusout`:u=`blur`,l=In;break;case`beforeblur`:case`afterblur`:l=In;break;case`click`:if(n.button===2)break a;case`auxclick`:case`dblclick`:case`mousedown`:case`mousemove`:case`mouseup`:case`mouseout`:case`mouseover`:case`contextmenu`:l=Pn;break;case`drag`:case`dragend`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`dragstart`:case`drop`:l=Fn;break;case`touchcancel`:case`touchend`:case`touchmove`:case`touchstart`:l=qn;break;case Kr:case qr:case Jr:l=Ln;break;case Qr:l=Jn;break;case`scroll`:case`scrollend`:l=kn;break;case`wheel`:l=Yn;break;case`copy`:case`cut`:case`paste`:l=Rn;break;case`gotpointercapture`:case`lostpointercapture`:case`pointercancel`:case`pointerdown`:case`pointermove`:case`pointerout`:case`pointerover`:case`pointerup`:l=Kn;break;case`toggle`:case`beforetoggle`:l=Xn}var d=!!(t&4),f=!d&&(e===`scroll`||e===`scrollend`),p=d?c===null?null:c+`Capture`:c;d=[];for(var m=r,h;m!==null;){var g=m;if(h=g.stateNode,g=g.tag,g!==5&&g!==26&&g!==27||h===null||p===null||(g=mn(m,p),g!=null&&d.push(kd(m,g,h))),f)break;m=m.return}0<d.length&&(c=new l(c,u,null,n,i),s.push({event:c,listeners:d}))}}if(!(t&7)){a:{if(c=e===`mouseover`||e===`pointerover`,l=e===`mouseout`||e===`pointerout`,c&&n!==sn&&(u=n.relatedTarget||n.fromElement)&&(xt(u)||u[mt]))break a;if((l||c)&&(c=i.window===i?i:(c=i.ownerDocument)?c.defaultView||c.parentWindow:window,l?(u=n.relatedTarget||n.toElement,l=r,u=u?xt(u):null,u!==null&&(f=o(u),d=u.tag,u!==f||d!==5&&d!==27&&d!==6)&&(u=null)):(l=null,u=r),l!==u)){if(d=Pn,g=`onMouseLeave`,p=`onMouseEnter`,m=`mouse`,(e===`pointerout`||e===`pointerover`)&&(d=Kn,g=`onPointerLeave`,p=`onPointerEnter`,m=`pointer`),f=l==null?c:Ct(l),h=u==null?c:Ct(u),c=new d(g,m+`leave`,l,n,i),c.target=f,c.relatedTarget=h,g=null,xt(i)===r&&(d=new d(p,m+`enter`,u,n,i),d.target=h,d.relatedTarget=f,g=d),f=g,l&&u)b:{for(d=jd,p=l,m=u,h=0,g=p;g;g=d(g))h++;g=0;for(var _=m;_;_=d(_))g++;for(;0<h-g;)p=d(p),h--;for(;0<g-h;)m=d(m),g--;for(;h--;){if(p===m||m!==null&&p===m.alternate){d=p;break b}p=d(p),m=d(m)}d=null}else d=null;l!==null&&Md(s,c,l,d,!1),u!==null&&f!==null&&Md(s,f,u,d,!0)}}a:{if(c=r?Ct(r):window,l=c.nodeName&&c.nodeName.toLowerCase(),l===`select`||l===`input`&&c.type===`file`)var v=gr;else if(ur(c)){if(_r)v=Er;else{v=wr;var y=Cr}}else l=c.nodeName,!l||l.toLowerCase()!==`input`||c.type!==`checkbox`&&c.type!==`radio`?r&&tn(r.elementType)&&(v=gr):v=Tr;if(v&&=v(e,r)){dr(s,v,n,i);break a}y&&y(e,c,r),e===`focusout`&&r&&c.type===`number`&&r.memoizedProps.value!=null&&qt(c,`number`,c.value)}switch(y=r?Ct(r):window,e){case`focusin`:(ur(y)||y.contentEditable===`true`)&&(Ir=y,Lr=r,Rr=null);break;case`focusout`:Rr=Lr=Ir=null;break;case`mousedown`:zr=!0;break;case`contextmenu`:case`mouseup`:case`dragend`:zr=!1,Br(s,n,i);break;case`selectionchange`:if(Fr)break;case`keydown`:case`keyup`:Br(s,n,i)}var b;if(Qn)b:{switch(e){case`compositionstart`:var x=`onCompositionStart`;break b;case`compositionend`:x=`onCompositionEnd`;break b;case`compositionupdate`:x=`onCompositionUpdate`;break b}x=void 0}else or?ir(e,n)&&(x=`onCompositionEnd`):e===`keydown`&&n.keyCode===229&&(x=`onCompositionStart`);x&&(tr&&n.locale!==`ko`&&(or||x!==`onCompositionStart`?x===`onCompositionEnd`&&or&&(b=xn()):(vn=i,yn=`value`in vn?vn.value:vn.textContent,or=!0)),y=Ad(r,x),0<y.length&&(x=new zn(x,e,null,n,i),s.push({event:x,listeners:y}),b?x.data=b:(b=ar(n),b!==null&&(x.data=b)))),(b=er?sr(e,n):cr(e,n))&&(x=Ad(r,`onBeforeInput`),0<x.length&&(y=new zn(`onBeforeInput`,`beforeinput`,null,n,i),s.push({event:y,listeners:x}),y.data=b)),yd(s,e,r,n,i)}q(s,t)})}function kd(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Ad(e,t){for(var n=t+`Capture`,r=[];e!==null;){var i=e,a=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||a===null||(i=mn(e,n),i!=null&&r.unshift(kd(e,i,a)),i=mn(e,t),i!=null&&r.push(kd(e,i,a))),e.tag===3)return r;e=e.return}return[]}function jd(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Md(e,t,n,r,i){for(var a=t._reactName,o=[];n!==null&&n!==r;){var s=n,c=s.alternate,l=s.stateNode;if(s=s.tag,c!==null&&c===r)break;s!==5&&s!==26&&s!==27||l===null||(c=l,i?(l=mn(n,a),l!=null&&o.unshift(kd(n,l,c))):i||(l=mn(n,a),l!=null&&o.push(kd(n,l,c)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var Nd=/\r\n?/g,Pd=/\u0000|\uFFFD/g;function Fd(e){return(typeof e==`string`?e:``+e).replace(Nd,`
|
|
10
|
-
`).replace(Pd,``)}function Id(e,t){return t=Fd(t),Fd(e)===t}function Y(e,t,n,r,a,o){switch(n){case`children`:typeof r==`string`?t===`body`||t===`textarea`&&r===``||Zt(e,r):(typeof r==`number`||typeof r==`bigint`)&&t!==`body`&&Zt(e,``+r);break;case`className`:Ft(e,`class`,r);break;case`tabIndex`:Ft(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:Ft(e,n,r);break;case`style`:en(e,r,o);break;case`data`:if(t!==`object`){Ft(e,`data`,r);break}case`src`:case`href`:if(r===``&&(t!==`a`||n!==`href`)){e.removeAttribute(n);break}if(r==null||typeof r==`function`||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=an(``+r),e.setAttribute(n,r);break;case`action`:case`formAction`:if(typeof r==`function`){e.setAttribute(n,`javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')`);break}if(typeof o==`function`&&(n===`formAction`?(t!==`input`&&Y(e,t,`name`,a.name,a,null),Y(e,t,`formEncType`,a.formEncType,a,null),Y(e,t,`formMethod`,a.formMethod,a,null),Y(e,t,`formTarget`,a.formTarget,a,null)):(Y(e,t,`encType`,a.encType,a,null),Y(e,t,`method`,a.method,a,null),Y(e,t,`target`,a.target,a,null))),r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=an(``+r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=on);break;case`onScroll`:r!=null&&J(`scroll`,e);break;case`onScrollEnd`:r!=null&&J(`scrollend`,e);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`multiple`:e.multiple=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`muted`:e.muted=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`defaultValue`:case`defaultChecked`:case`innerHTML`:case`ref`:break;case`autoFocus`:break;case`xlinkHref`:if(r==null||typeof r==`function`||typeof r==`boolean`||typeof r==`symbol`){e.removeAttribute(`xlink:href`);break}n=an(``+r),e.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,n);break;case`contentEditable`:case`spellCheck`:case`draggable`:case`value`:case`autoReverse`:case`externalResourcesRequired`:case`focusable`:case`preserveAlpha`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``+r):e.removeAttribute(n);break;case`inert`:case`allowFullScreen`:case`async`:case`autoPlay`:case`controls`:case`default`:case`defer`:case`disabled`:case`disablePictureInPicture`:case`disableRemotePlayback`:case`formNoValidate`:case`hidden`:case`loop`:case`noModule`:case`noValidate`:case`open`:case`playsInline`:case`readOnly`:case`required`:case`reversed`:case`scoped`:case`seamless`:case`itemScope`:r&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``):e.removeAttribute(n);break;case`capture`:case`download`:!0===r?e.setAttribute(n,``):!1!==r&&r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`cols`:case`rows`:case`size`:case`span`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case`rowSpan`:case`start`:r==null||typeof r==`function`||typeof r==`symbol`||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case`popover`:J(`beforetoggle`,e),J(`toggle`,e),Pt(e,`popover`,r);break;case`xlinkActuate`:It(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:It(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:It(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:It(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:It(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:It(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:It(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:It(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:It(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:Pt(e,`is`,r);break;case`innerText`:case`textContent`:break;default:(!(2<n.length)||n[0]!==`o`&&n[0]!==`O`||n[1]!==`n`&&n[1]!==`N`)&&(n=nn.get(n)||n,Pt(e,n,r))}}function Ld(e,t,n,r,a,o){switch(n){case`style`:en(e,r,o);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`children`:typeof r==`string`?Zt(e,r):(typeof r==`number`||typeof r==`bigint`)&&Zt(e,``+r);break;case`onScroll`:r!=null&&J(`scroll`,e);break;case`onScrollEnd`:r!=null&&J(`scrollend`,e);break;case`onClick`:r!=null&&(e.onclick=on);break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:break;case`innerText`:case`textContent`:break;default:if(!Dt.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(a=n.endsWith(`Capture`),t=n.slice(2,a?n.length-7:void 0),o=e[pt]||null,o=o==null?null:o[n],typeof o==`function`&&e.removeEventListener(t,o,a),typeof r==`function`)){typeof o!=`function`&&o!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,a);break a}n in e?e[n]=r:!0===r?e.setAttribute(n,``):Pt(e,n,r)}}}function Rd(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:J(`error`,e),J(`load`,e);var r=!1,a=!1,o;for(o in n)if(n.hasOwnProperty(o)){var s=n[o];if(s!=null)switch(o){case`src`:r=!0;break;case`srcSet`:a=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:Y(e,t,o,s,n,null)}}a&&Y(e,t,`srcSet`,n.srcSet,n,null),r&&Y(e,t,`src`,n.src,n,null);return;case`input`:J(`invalid`,e);var c=o=s=a=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:a=d;break;case`type`:s=d;break;case`checked`:l=d;break;case`defaultChecked`:u=d;break;case`value`:o=d;break;case`defaultValue`:c=d;break;case`children`:case`dangerouslySetInnerHTML`:if(d!=null)throw Error(i(137,t));break;default:Y(e,t,r,d,n,null)}}Kt(e,o,c,l,u,s,a,!1);return;case`select`:for(a in J(`invalid`,e),r=s=o=null,n)if(n.hasOwnProperty(a)&&(c=n[a],c!=null))switch(a){case`value`:o=c;break;case`defaultValue`:s=c;break;case`multiple`:r=c;default:Y(e,t,a,c,n,null)}t=o,n=s,e.multiple=!!r,t==null?n!=null&&Jt(e,!!r,n,!0):Jt(e,!!r,t,!1);return;case`textarea`:for(s in J(`invalid`,e),o=a=r=null,n)if(n.hasOwnProperty(s)&&(c=n[s],c!=null))switch(s){case`value`:r=c;break;case`defaultValue`:a=c;break;case`children`:o=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(i(91));break;default:Y(e,t,s,c,n,null)}Xt(e,r,a,o);return;case`option`:for(l in n)if(n.hasOwnProperty(l)&&(r=n[l],r!=null))switch(l){case`selected`:e.selected=r&&typeof r!=`function`&&typeof r!=`symbol`;break;default:Y(e,t,l,r,n,null)}return;case`dialog`:J(`beforetoggle`,e),J(`toggle`,e),J(`cancel`,e),J(`close`,e);break;case`iframe`:case`object`:J(`load`,e);break;case`video`:case`audio`:for(r=0;r<Sd.length;r++)J(Sd[r],e);break;case`image`:J(`error`,e),J(`load`,e);break;case`details`:J(`toggle`,e);break;case`embed`:case`source`:case`link`:J(`error`,e),J(`load`,e);case`area`:case`base`:case`br`:case`col`:case`hr`:case`keygen`:case`meta`:case`param`:case`track`:case`wbr`:case`menuitem`:for(u in n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:Y(e,t,u,r,n,null)}return;default:if(tn(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Ld(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&Y(e,t,c,r,n,null))}function zd(e,t,n,r){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`input`:var a=null,o=null,s=null,c=null,l=null,u=null,d=null;for(m in n){var f=n[m];if(n.hasOwnProperty(m)&&f!=null)switch(m){case`checked`:break;case`value`:break;case`defaultValue`:l=f;default:r.hasOwnProperty(m)||Y(e,t,m,null,r,f)}}for(var p in r){var m=r[p];if(f=n[p],r.hasOwnProperty(p)&&(m!=null||f!=null))switch(p){case`type`:o=m;break;case`name`:a=m;break;case`checked`:u=m;break;case`defaultChecked`:d=m;break;case`value`:s=m;break;case`defaultValue`:c=m;break;case`children`:case`dangerouslySetInnerHTML`:if(m!=null)throw Error(i(137,t));break;default:m!==f&&Y(e,t,p,m,r,f)}}Gt(e,s,c,l,u,d,o,a);return;case`select`:for(o in m=s=c=p=null,n)if(l=n[o],n.hasOwnProperty(o)&&l!=null)switch(o){case`value`:break;case`multiple`:m=l;default:r.hasOwnProperty(o)||Y(e,t,o,null,r,l)}for(a in r)if(o=r[a],l=n[a],r.hasOwnProperty(a)&&(o!=null||l!=null))switch(a){case`value`:p=o;break;case`defaultValue`:c=o;break;case`multiple`:s=o;default:o!==l&&Y(e,t,a,o,r,l)}t=c,n=s,r=m,p==null?!!r!=!!n&&(t==null?Jt(e,!!n,n?[]:``,!1):Jt(e,!!n,t,!0)):Jt(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(a=n[c],n.hasOwnProperty(c)&&a!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:Y(e,t,c,null,r,a)}for(s in r)if(a=r[s],o=n[s],r.hasOwnProperty(s)&&(a!=null||o!=null))switch(s){case`value`:p=a;break;case`defaultValue`:m=a;break;case`children`:break;case`dangerouslySetInnerHTML`:if(a!=null)throw Error(i(91));break;default:a!==o&&Y(e,t,s,a,r,o)}Yt(e,p,m);return;case`option`:for(var h in n)if(p=n[h],n.hasOwnProperty(h)&&p!=null&&!r.hasOwnProperty(h))switch(h){case`selected`:e.selected=!1;break;default:Y(e,t,h,null,r,p)}for(l in r)if(p=r[l],m=n[l],r.hasOwnProperty(l)&&p!==m&&(p!=null||m!=null))switch(l){case`selected`:e.selected=p&&typeof p!=`function`&&typeof p!=`symbol`;break;default:Y(e,t,l,p,r,m)}return;case`img`:case`link`:case`area`:case`base`:case`br`:case`col`:case`embed`:case`hr`:case`keygen`:case`meta`:case`param`:case`source`:case`track`:case`wbr`:case`menuitem`:for(var g in n)p=n[g],n.hasOwnProperty(g)&&p!=null&&!r.hasOwnProperty(g)&&Y(e,t,g,null,r,p);for(u in r)if(p=r[u],m=n[u],r.hasOwnProperty(u)&&p!==m&&(p!=null||m!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:if(p!=null)throw Error(i(137,t));break;default:Y(e,t,u,p,r,m)}return;default:if(tn(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&Ld(e,t,_,void 0,r,p);for(d in r)p=r[d],m=n[d],!r.hasOwnProperty(d)||p===m||p===void 0&&m===void 0||Ld(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&Y(e,t,v,null,r,p);for(f in r)p=r[f],m=n[f],!r.hasOwnProperty(f)||p===m||p==null&&m==null||Y(e,t,f,p,r,m)}function Bd(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Vd(){if(typeof performance.getEntriesByType==`function`){for(var e=0,t=0,n=performance.getEntriesByType(`resource`),r=0;r<n.length;r++){var i=n[r],a=i.transferSize,o=i.initiatorType,s=i.duration;if(a&&s&&Bd(o)){for(o=0,s=i.responseEnd,r+=1;r<n.length;r++){var c=n[r],l=c.startTime;if(l>s)break;var u=c.transferSize,d=c.initiatorType;u&&Bd(d)&&(c=c.responseEnd,o+=u*(c<s?1:(s-l)/(c-l)))}if(--r,t+=8*(a+o)/(i.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e==`number`)?e:5}var Hd=null,Ud=null;function Wd(e){return e.nodeType===9?e:e.ownerDocument}function Gd(e){switch(e){case`http://www.w3.org/2000/svg`:return 1;case`http://www.w3.org/1998/Math/MathML`:return 2;default:return 0}}function Kd(e,t){if(e===0)switch(t){case`svg`:return 1;case`math`:return 2;default:return 0}return e===1&&t===`foreignObject`?0:e}function qd(e,t){return e===`textarea`||e===`noscript`||typeof t.children==`string`||typeof t.children==`number`||typeof t.children==`bigint`||typeof t.dangerouslySetInnerHTML==`object`&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Jd=null;function Yd(){var e=window.event;return e&&e.type===`popstate`?e!==Jd&&(Jd=e,!0):(Jd=null,!1)}var Xd=typeof setTimeout==`function`?setTimeout:void 0,Zd=typeof clearTimeout==`function`?clearTimeout:void 0,Qd=typeof Promise==`function`?Promise:void 0,$d=typeof queueMicrotask==`function`?queueMicrotask:Qd===void 0?Xd:function(e){return Qd.resolve(null).then(e).catch(ef)};function ef(e){setTimeout(function(){throw e})}function tf(e){return e===`head`}function nf(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8){if(n=i.data,n===`/$`||n===`/&`){if(r===0){e.removeChild(i),Lp(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)_f(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,_f(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[yt]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&_f(e.ownerDocument.body)}n=i}while(n);Lp(t)}function rf(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display=`none`):(n.style.display=n._stashedDisplay||``,n.getAttribute(`style`)===``&&n.removeAttribute(`style`)):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=``):n.nodeValue=n._stashedText||``),r&&r.nodeType===8){if(n=r.data,n===`/$`){if(e===0)break;e--}else n!==`$`&&n!==`$?`&&n!==`$~`&&n!==`$!`||e++}n=r}while(n)}function af(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case`HTML`:case`HEAD`:case`BODY`:af(n),bt(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function of(e,t,n,r){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!==`INPUT`||e.type!==`hidden`))break}else if(!r){if(t===`input`&&e.type===`hidden`){var a=i.name==null?null:``+i.name;if(i.type===`hidden`&&e.getAttribute(`name`)===a)return e}else return e}else if(!e[yt])switch(t){case`meta`:if(!e.hasAttribute(`itemprop`))break;return e;case`link`:if(a=e.getAttribute(`rel`),a===`stylesheet`&&e.hasAttribute(`data-precedence`)||a!==i.rel||e.getAttribute(`href`)!==(i.href==null||i.href===``?null:i.href)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute(`title`)!==(i.title==null?null:i.title))break;return e;case`style`:if(e.hasAttribute(`data-precedence`))break;return e;case`script`:if(a=e.getAttribute(`src`),(a!==(i.src==null?null:i.src)||e.getAttribute(`type`)!==(i.type==null?null:i.type)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin))&&a&&e.hasAttribute(`async`)&&!e.hasAttribute(`itemprop`))break;return e;default:return e}if(e=ff(e.nextSibling),e===null)break}return null}function sf(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=ff(e.nextSibling),e===null))return null;return e}function cf(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=ff(e.nextSibling),e===null))return null;return e}function lf(e){return e.data===`$?`||e.data===`$~`}function uf(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function df(e,t){var n=e.ownerDocument;if(e.data===`$~`)e._reactRetry=t;else if(e.data!==`$?`||n.readyState!==`loading`)t();else{var r=function(){t(),n.removeEventListener(`DOMContentLoaded`,r)};n.addEventListener(`DOMContentLoaded`,r),e._reactRetry=r}}function ff(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t===`$`||t===`$!`||t===`$?`||t===`$~`||t===`&`||t===`F!`||t===`F`)break;if(t===`/$`||t===`/&`)return null}}return e}var pf=null;function mf(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return ff(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function hf(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`$`||n===`$!`||n===`$?`||n===`$~`||n===`&`){if(t===0)return e;t--}else n!==`/$`&&n!==`/&`||t++}e=e.previousSibling}return null}function gf(e,t,n){switch(t=Wd(n),e){case`html`:if(e=t.documentElement,!e)throw Error(i(452));return e;case`head`:if(e=t.head,!e)throw Error(i(453));return e;case`body`:if(e=t.body,!e)throw Error(i(454));return e;default:throw Error(i(451))}}function _f(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);bt(e)}var vf=new Map,yf=new Set;function bf(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var xf=A.d;A.d={f:Sf,r:Cf,D:Ef,C:Df,L:Of,m:kf,X:jf,S:Af,M:Mf};function Sf(){var e=xf.f(),t=Tu();return e||t}function Cf(e){var t=St(e);t!==null&&t.tag===5&&t.type===`form`?As(t):xf.r(e)}var wf=typeof document>`u`?null:document;function Tf(e,t,n){var r=wf;if(r&&typeof t==`string`&&t){var i=Wt(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),yf.has(i)||(yf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Rd(t,`link`,e),Tt(t),r.head.appendChild(t)))}}function Ef(e){xf.D(e),Tf(`dns-prefetch`,e,null)}function Df(e,t){xf.C(e,t),Tf(`preconnect`,e,t)}function Of(e,t,n){xf.L(e,t,n);var r=wf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Wt(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Wt(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Wt(n.imageSizes)+`"]`)):i+=`[href="`+Wt(e)+`"]`;var a=i;switch(t){case`style`:a=Pf(e);break;case`script`:a=Rf(e)}vf.has(a)||(e=m({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),vf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(Ff(a))||t===`script`&&r.querySelector(zf(a))||(t=r.createElement(`link`),Rd(t,`link`,e),Tt(t),r.head.appendChild(t)))}}function kf(e,t){xf.m(e,t);var n=wf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Wt(r)+`"][href="`+Wt(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Rf(e)}if(!vf.has(a)&&(e=m({rel:`modulepreload`,href:e},t),vf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(zf(a)))return}r=n.createElement(`link`),Rd(r,`link`,e),Tt(r),n.head.appendChild(r)}}}function Af(e,t,n){xf.S(e,t,n);var r=wf;if(r&&e){var i=wt(r).hoistableStyles,a=Pf(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(Ff(a)))s.loading=5;else{e=m({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=vf.get(a))&&Hf(e,n);var c=o=r.createElement(`link`);Tt(c),Rd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Vf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function jf(e,t){xf.X(e,t);var n=wf;if(n&&e){var r=wt(n).hoistableScripts,i=Rf(e),a=r.get(i);a||(a=n.querySelector(zf(i)),a||(e=m({src:e,async:!0},t),(t=vf.get(i))&&Uf(e,t),a=n.createElement(`script`),Tt(a),Rd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Mf(e,t){xf.M(e,t);var n=wf;if(n&&e){var r=wt(n).hoistableScripts,i=Rf(e),a=r.get(i);a||(a=n.querySelector(zf(i)),a||(e=m({src:e,async:!0,type:`module`},t),(t=vf.get(i))&&Uf(e,t),a=n.createElement(`script`),Tt(a),Rd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Nf(e,t,n,r){var a=(a=me.current)?bf(a):null;if(!a)throw Error(i(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Pf(n.href),n=wt(a).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Pf(n.href);var o=wt(a).hoistableStyles,s=o.get(e);if(s||(a=a.ownerDocument||a,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=a.querySelector(Ff(e)))&&!o._p&&(s.instance=o,s.state.loading=5),vf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},vf.set(e,n),o||Lf(a,e,n,s.state))),t&&r===null)throw Error(i(528,``));return s}if(t&&r!==null)throw Error(i(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Rf(n),n=wt(a).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(i(444,e))}}function Pf(e){return`href="`+Wt(e)+`"`}function Ff(e){return`link[rel="stylesheet"][`+e+`]`}function If(e){return m({},e,{"data-precedence":e.precedence,precedence:null})}function Lf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Rd(t,`link`,n),Tt(t),e.head.appendChild(t))}function Rf(e){return`[src="`+Wt(e)+`"]`}function zf(e){return`script[async]`+e}function Bf(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Wt(n.href)+`"]`);if(r)return t.instance=r,Tt(r),r;var a=m({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),Tt(r),Rd(r,`style`,a),Vf(r,n.precedence,e),t.instance=r;case`stylesheet`:a=Pf(n.href);var o=e.querySelector(Ff(a));if(o)return t.state.loading|=4,t.instance=o,Tt(o),o;r=If(n),(a=vf.get(a))&&Hf(r,a),o=(e.ownerDocument||e).createElement(`link`),Tt(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Rd(o,`link`,r),t.state.loading|=4,Vf(o,n.precedence,e),t.instance=o;case`script`:return o=Rf(n.src),(a=e.querySelector(zf(o)))?(t.instance=a,Tt(a),a):(r=n,(a=vf.get(o))&&(r=m({},n),Uf(r,a)),e=e.ownerDocument||e,a=e.createElement(`script`),Tt(a),Rd(a,`link`,r),e.head.appendChild(a),t.instance=a);case`void`:return null;default:throw Error(i(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Vf(r,n.precedence,e));return t.instance}function Vf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o<r.length;o++){var s=r[o];if(s.dataset.precedence===t)a=s;else if(a!==i)break}a?a.parentNode.insertBefore(e,a.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Hf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function Uf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var Wf=null;function Gf(e,t,n){if(Wf===null){var r=new Map,i=Wf=new Map;i.set(n,r)}else i=Wf,r=i.get(n),r||(r=new Map,i.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),i=0;i<n.length;i++){var a=n[i];if(!(a[yt]||a[ft]||e===`link`&&a.getAttribute(`rel`)===`stylesheet`)&&a.namespaceURI!==`http://www.w3.org/2000/svg`){var o=a.getAttribute(t)||``;o=e+o;var s=r.get(o);s?s.push(a):r.set(o,[a])}}return r}function Kf(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function qf(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function Jf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Yf(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Pf(r.href),a=t.querySelector(Ff(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=Qf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,Tt(a);return}a=t.ownerDocument||t,r=If(r),(i=vf.get(i))&&Hf(r,i),a=a.createElement(`link`),Tt(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Rd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=Qf.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var Xf=0;function Zf(e,t){return e.stylesheets&&e.count===0&&ep(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&ep(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&Xf===0&&(Xf=62500*Vd());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&ep(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>Xf?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function Qf(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)ep(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var $f=null;function ep(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,$f=new Map,t.forEach(tp,e),$f=null,Qf.call(e))}function tp(e,t){if(!(t.state.loading&4)){var n=$f.get(e);if(n)var r=n.get(null);else{n=new Map,$f.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a<i.length;a++){var o=i[a];(o.nodeName===`LINK`||o.getAttribute(`media`)!==`not all`)&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}i=t.instance,o=i.getAttribute(`data-precedence`),a=n.get(o)||r,a===r&&n.set(null,i),n.set(o,i),this.count++,r=Qf.bind(this),i.addEventListener(`load`,r),i.addEventListener(`error`,r),a?a.parentNode.insertBefore(i,a.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}var np={$$typeof:C,Provider:null,Consumer:null,_currentValue:se,_currentValue2:se,_threadCount:0};function rp(e,t,n,r,i,a,o,s,c){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=nt(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=nt(0),this.hiddenUpdates=nt(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.incompleteTransitions=new Map}function ip(e,t,n,r,i,a,o,s,c,l,u,d){return e=new rp(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=mi(3,null,null,t),e.current=a,a.stateNode=e,t=ua(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},Ua(a),e}function ap(e){return e?(e=fi,e):fi}function op(e,t,n,r,i,a){i=ap(i),r.context===null?r.context=i:r.pendingContext=i,r=Ga(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=Ka(e,r,t),n!==null&&(bu(n,e,t),qa(n,e,t))}function sp(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function cp(e,t){sp(e,t),(e=e.alternate)&&sp(e,t)}function lp(e){if(e.tag===13||e.tag===31){var t=li(e,67108864);t!==null&&bu(t,e,67108864),cp(e,67108864)}}function up(e){if(e.tag===13||e.tag===31){var t=vu();t=ct(t);var n=li(e,t);n!==null&&bu(n,e,t),cp(e,t)}}var dp=!0;function fp(e,t,n,r){var i=k.T;k.T=null;var a=A.p;try{A.p=2,mp(e,t,n,r)}finally{A.p=a,k.T=i}}function pp(e,t,n,r){var i=k.T;k.T=null;var a=A.p;try{A.p=8,mp(e,t,n,r)}finally{A.p=a,k.T=i}}function mp(e,t,n,r){if(dp){var i=hp(r);if(i===null)Od(e,t,r,gp,n),Dp(e,r);else if(kp(i,e,t,n,r))r.stopPropagation();else if(Dp(e,r),t&4&&-1<Ep.indexOf(e)){for(;i!==null;){var a=St(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=Ze(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-We(o);s.entanglements[1]|=c,o&=~c}cd(a),!(V&6)&&(ou=Me()+500,ld(0,!1))}}break;case 31:case 13:s=li(a,2),s!==null&&bu(s,a,2),Tu(),cp(a,2)}if(a=hp(r),a===null&&Od(e,t,r,gp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Od(e,t,r,null,n)}}function hp(e){return e=cn(e),_p(e)}var gp=null;function _p(e){if(gp=null,e=xt(e),e!==null){var t=o(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=s(t),e!==null)return e;e=null}else if(n===31){if(e=c(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return gp=e,null}function vp(e){switch(e){case`beforetoggle`:case`cancel`:case`click`:case`close`:case`contextmenu`:case`copy`:case`cut`:case`auxclick`:case`dblclick`:case`dragend`:case`dragstart`:case`drop`:case`focusin`:case`focusout`:case`input`:case`invalid`:case`keydown`:case`keypress`:case`keyup`:case`mousedown`:case`mouseup`:case`paste`:case`pause`:case`play`:case`pointercancel`:case`pointerdown`:case`pointerup`:case`ratechange`:case`reset`:case`resize`:case`seeked`:case`submit`:case`toggle`:case`touchcancel`:case`touchend`:case`touchstart`:case`volumechange`:case`change`:case`selectionchange`:case`textInput`:case`compositionstart`:case`compositionend`:case`compositionupdate`:case`beforeblur`:case`afterblur`:case`beforeinput`:case`blur`:case`fullscreenchange`:case`focus`:case`hashchange`:case`popstate`:case`select`:case`selectstart`:return 2;case`drag`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`mousemove`:case`mouseout`:case`mouseover`:case`pointermove`:case`pointerout`:case`pointerover`:case`scroll`:case`touchmove`:case`wheel`:case`mouseenter`:case`mouseleave`:case`pointerenter`:case`pointerleave`:return 8;case`message`:switch(Ne()){case Pe:return 2;case Fe:return 8;case Ie:case Le:return 32;case Re:return 268435456;default:return 32}default:return 32}}var yp=!1,bp=null,xp=null,Sp=null,Cp=new Map,wp=new Map,Tp=[],Ep=`mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset`.split(` `);function Dp(e,t){switch(e){case`focusin`:case`focusout`:bp=null;break;case`dragenter`:case`dragleave`:xp=null;break;case`mouseover`:case`mouseout`:Sp=null;break;case`pointerover`:case`pointerout`:Cp.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:wp.delete(t.pointerId)}}function Op(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=St(t),t!==null&&lp(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function kp(e,t,n,r,i){switch(t){case`focusin`:return bp=Op(bp,e,t,n,r,i),!0;case`dragenter`:return xp=Op(xp,e,t,n,r,i),!0;case`mouseover`:return Sp=Op(Sp,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return Cp.set(a,Op(Cp.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,wp.set(a,Op(wp.get(a)||null,e,t,n,r,i)),!0}return!1}function Ap(e){var t=xt(e.target);if(t!==null){var n=o(t);if(n!==null){if(t=n.tag,t===13){if(t=s(n),t!==null){e.blockedOn=t,ut(e.priority,function(){up(n)});return}}else if(t===31){if(t=c(n),t!==null){e.blockedOn=t,ut(e.priority,function(){up(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function jp(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=hp(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);sn=r,n.target.dispatchEvent(r),sn=null}else return t=St(n),t!==null&&lp(t),e.blockedOn=n,!1;t.shift()}return!0}function Mp(e,t,n){jp(e)&&n.delete(t)}function Np(){yp=!1,bp!==null&&jp(bp)&&(bp=null),xp!==null&&jp(xp)&&(xp=null),Sp!==null&&jp(Sp)&&(Sp=null),Cp.forEach(Mp),wp.forEach(Mp)}function Pp(e,n){e.blockedOn===n&&(e.blockedOn=null,yp||(yp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,Np)))}var Fp=null;function Ip(e){Fp!==e&&(Fp=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){Fp===e&&(Fp=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],i=e[t+2];if(typeof r!=`function`){if(_p(r||n)===null)continue;break}var a=St(n);a!==null&&(e.splice(t,3),t-=3,Os(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Lp(e){function t(t){return Pp(t,e)}bp!==null&&Pp(bp,e),xp!==null&&Pp(xp,e),Sp!==null&&Pp(Sp,e),Cp.forEach(t),wp.forEach(t);for(var n=0;n<Tp.length;n++){var r=Tp[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<Tp.length&&(n=Tp[0],n.blockedOn===null);)Ap(n),n.blockedOn===null&&Tp.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var i=n[r],a=n[r+1],o=i[pt]||null;if(typeof a==`function`)o||Ip(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[pt]||null)s=o.formAction;else if(_p(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),Ip(n)}}}function Rp(){function e(e){e.canIntercept&&e.info===`react-transition`&&e.intercept({handler:function(){return new Promise(function(e){return i=e})},focusReset:`manual`,scroll:`manual`})}function t(){i!==null&&(i(),i=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&e.url!=null&&navigation.navigate(e.url,{state:e.getState(),info:`react-transition`,history:`replace`})}}if(typeof navigation==`object`){var r=!1,i=null;return navigation.addEventListener(`navigate`,e),navigation.addEventListener(`navigatesuccess`,t),navigation.addEventListener(`navigateerror`,t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener(`navigate`,e),navigation.removeEventListener(`navigatesuccess`,t),navigation.removeEventListener(`navigateerror`,t),i!==null&&(i(),i=null)}}}function zp(e){this._internalRoot=e}Bp.prototype.render=zp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(i(409));var n=t.current;op(n,vu(),e,t,null,null)},Bp.prototype.unmount=zp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;op(e.current,2,null,e,null,null),Tu(),t[mt]=null}};function Bp(e){this._internalRoot=e}Bp.prototype.unstable_scheduleHydration=function(e){if(e){var t=lt();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Tp.length&&t!==0&&t<Tp[n].priority;n++);Tp.splice(n,0,e),n===0&&Ap(e)}};var Vp=n.version;if(Vp!==`19.2.8`)throw Error(i(527,Vp,`19.2.8`));A.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(i(188)):(e=Object.keys(e).join(`,`),Error(i(268,e)));return e=u(t),e=e===null?null:f(e),e=e===null?null:e.stateNode,e};var Hp={bundleType:0,version:`19.2.8`,rendererPackageName:`react-dom`,currentDispatcherRef:k,reconcilerVersion:`19.2.8`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var Up=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Up.isDisabled&&Up.supportsFiber)try{Ve=Up.inject(Hp),He=Up}catch{}}e.createRoot=function(e,t){if(!a(e))throw Error(i(299));var n=!1,r=``,o=Zs,s=Qs,c=$s;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(o=t.onUncaughtError),t.onCaughtError!==void 0&&(s=t.onCaughtError),t.onRecoverableError!==void 0&&(c=t.onRecoverableError)),t=ip(e,1,!1,null,null,n,r,null,o,s,c,Rp),e[mt]=t.current,Ed(e),new zp(t)}})),_=o(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=g()})),v=d(),y=_();function b(e){return e.anchor.kind===`line`}function x(e){return e.anchor.kind===`detached`}function S(e){let t=new Map;for(let n of e){if(!b(n))continue;let e={lineNumber:n.anchor.lineNumber,side:n.anchor.side,metadata:{type:`thread`,thread:n}},r=t.get(n.anchor.fileId);r?r.push(e):t.set(n.anchor.fileId,[e])}return t}function C(e){let t=new Map;for(let n of e)b(n)&&t.set(n.anchor.fileId,(t.get(n.anchor.fileId)??0)+1);return t}function w(e,t,n,r){return!r||n?.fileId!==t?e:[...e,r]}function T(e,t){let n=t.find(t=>t.id===e.fileId);return e.side===`deletions`?n?.oldRepoPath??n?.newRepoPath??e.fileId:n?.newRepoPath??n?.oldRepoPath??e.fileId}function E(e){let t=(0,v.useRef)(e);return(0,v.useInsertionEffect)(()=>void(t.current=e)),(0,v.useCallback)((...e)=>t.current(...e),[])}var ee=o((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.fragment`);function r(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.Fragment=n,e.jsx=r,e.jsxs=r})),D=o(((e,t)=>{t.exports=ee()}))(),O=(0,v.createContext)(void 0);function te(){return(0,v.useContext)(O)}var ne={position:`absolute`,top:0,bottom:0,textAlign:`center`,whiteSpace:`normal`,touchAction:`none`},re={display:`contents`};function ie(){return null}var ae=`diffs-container`,oe=/(?=^From [a-f0-9]+ .+$)/m,k=/(?=^diff --git)/gm,A=/(?<=\n)/,se=/^(---|\+\+\+)\s+([^\t\r\n]+)/,ce=/^(---|\+\+\+)\s+[ab]\/([^\t\r\n]+)/,le=/^diff --git (?:"a\/(.+?)"|a\/(.+?)) (?:"b\/(.+?)"|b\/(.+?))$/,ue=/^index ([0-9a-f]+)\.\.([0-9a-f]+)(?: (\d+))?$/i,de=`header-prefix`,j=`header-filename-suffix`,fe=`header-metadata`,pe=`header-custom`,me={dark:`pierre-dark`,light:`pierre-light`},he=`data-theme-css`,ge=`data-unsafe-css`,_e=`data-diffs-scrollbar-measure`,ve=`--diffs-scrollbar-gutter-measured`,ye=1e5,be={hunkLineCount:50,lineHeight:20,diffHeaderHeight:44,spacing:8};({...be});var xe=Object.freeze({fromStart:0,fromEnd:0}),Se={startingLine:0,totalLines:1/0,bufferBefore:0,bufferAfter:0},Ce={startingLine:0,totalLines:0,bufferBefore:0,bufferAfter:0};function we(e){return`annotation-${`side`in e?`${e.side}-`:``}${e.lineNumber}`}function Te({hunkIndex:e,lineIndex:t,conflictIndex:n}){return`merge-conflict-action-${e}-${t}-${n}`}function Ee(e,t){return e-(t===0?0:1)}function De(e,t){return Ee(e,t)+t}function Oe(e,t){let n=t.hunks[e.hunkIndex];if(n!=null)return{hunkIndex:e.hunkIndex,lineIndex:ke(n,e.startContentIndex)}}function ke(e,t){let n=e.unifiedLineStart;for(let r=0;r<t;r++){let t=e.hunkContent[r];n+=t.type===`context`?t.lines:t.deletions+t.additions}return n}function Ae({fileDiff:e,actions:t,renderCustomHeader:n,renderHeaderPrefix:r,renderHeaderFilenameSuffix:i,renderHeaderMetadata:a,renderAnnotation:o,renderGutterUtility:s,renderMergeConflictUtility:c,lineAnnotations:l,getHoveredLine:u,getInstance:d}){let f=n?.(e),p=r?.(e),m=i?.(e),h=a?.(e);return(0,D.jsxs)(D.Fragment,{children:[f==null?(0,D.jsxs)(D.Fragment,{children:[p!=null&&(0,D.jsx)(`div`,{slot:`header-prefix`,children:p}),m!=null&&(0,D.jsx)(`div`,{slot:`header-filename-suffix`,children:m}),h!=null&&(0,D.jsx)(`div`,{slot:`header-metadata`,children:h})]}):(0,D.jsx)(`div`,{slot:pe,children:f}),o!=null&&l?.map((e,t)=>(0,D.jsx)(`div`,{slot:we(e),children:o(e)},t)),t!=null&&c!=null&&d!=null&&t.map(t=>{if(t==null)return;let n=je(t,e);return(0,D.jsx)(`div`,{slot:n,style:re,children:c(t,d)},n)}),s!=null&&(0,D.jsx)(`div`,{slot:`gutter-utility-slot`,style:ne,children:s(u)})]})}function je(e,t){let n=Oe(e,t);return n==null?void 0:Te({hunkIndex:n.hunkIndex,lineIndex:n.lineIndex,conflictIndex:e.conflictIndex})}function Me(e,t){return e==null||t==null||typeof e==`string`||typeof t==`string`?e===t:e.dark===t.dark&&e.light===t.light}function Ne(e,t){return e?.cacheKey===t?.cacheKey&&e?.contents===t?.contents&&e?.name===t?.name&&e?.lang===t?.lang}var Pe=new Set;function Fe(e){let t=[],n=new Set;for(let r of Ie(e.themes)){let e=ze(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 Fe({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 Fe({themes:t})},registerInto(e){for(let t of r)e.registerThemeIfAbsent(t.name,t.load)}}}function Ie(e){return Le(e)?[e]:e}function Le(e){return ze(e)||Re(e)}function Re(e){return typeof e.name==`string`&&typeof e.load==`function`}function ze(e){return typeof e.getThemes==`function`}function Be(e){return typeof e==`object`&&e&&`default`in e?e.default:e}var Ve=class extends Error{constructor(e){super(`Theme "${e}" is already registered`),this.name=`DuplicateThemeError`}},He=class extends Error{constructor(e){super(`No loader registered for theme "${e}"`),this.name=`UnregisteredThemeError`}},Ue=class extends Error{constructor(e){super(`Theme "${e}" has not been resolved`),this.name=`UnresolvedThemeError`}};function We(){let e=new Map,t=new Map,n=new Map,r=0;function i(t,n){if(e.has(t))throw new Ve(t);e.set(t,n)}function a(t,n){return!e.has(t)&&(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 He(i));let c=r,l=s().then(e=>{let a=Be(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 Ue(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 Ge=We();function Ke(e,t){e=Array.isArray(e)?e:[e];for(let n of e){let e;if(typeof n==`string`){if(e=Ge.getResolvedTheme(n),e==null)throw Error(`loadResolvedThemes: ${n} is not resolved, you must resolve it before calling loadResolvedThemes`)}else e=n,n=n.name,Ge.getResolvedTheme(n)??Ge.seedResolvedTheme(n,e);Pe.has(n)||(Pe.add(n),t.loadThemeSync(e))}}var qe=new Map,Je=new Map,Ye=new Map,Xe=new Set;function Ze(e,t){e=Array.isArray(e)?e:[e];for(let n of e){if(Xe.has(n.name))continue;let e=qe.get(n.name);e??(e=n,qe.set(n.name,e)),Xe.add(e.name),t.loadLanguageSync(e.data)}}function Qe(){return typeof WorkerGlobalScope<`u`&&typeof self<`u`&&self instanceof WorkerGlobalScope}var $e=Object.defineProperty,et=Object.getOwnPropertyDescriptor,tt=Object.getOwnPropertyNames,nt=Object.prototype.hasOwnProperty,rt=(e,t)=>{let n={};for(var r in e)$e(n,r,{get:e[r],enumerable:!0});return t||$e(n,Symbol.toStringTag,{value:`Module`}),n},it=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var i=tt(t),a=0,o=i.length,s;a<o;a++)s=i[a],!nt.call(e,s)&&s!==n&&$e(e,s,{get:(e=>t[e]).bind(null,s),enumerable:!(r=et(t,s))||r.enumerable});return e},at=(e,t,n)=>(it(e,t,`default`),n&&it(n,t,`default`)),ot=`modulepreload`,st=function(e,t){return new URL(e,t).href},ct={},M=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,import.meta.url).href}r=o(t.map(t=>{if(t=st(t,n),t=s(t),t in ct)return;ct[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`:ot,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)})},lt=[{id:`abap`,name:`ABAP`,import:(()=>M(()=>import(`./abap-CLvhMVsD.js`),[],import.meta.url))},{id:`actionscript-3`,name:`ActionScript`,aliases:[`actionscript`,`as3`],import:(()=>M(()=>import(`./actionscript-3-Cs6JJXT5.js`),[],import.meta.url))},{id:`ada`,name:`Ada`,import:(()=>M(()=>import(`./ada-C5qYipkI.js`),[],import.meta.url))},{id:`ahk`,name:`AutoHotkey`,aliases:[`ahk1`],import:(()=>M(()=>import(`./ahk-CA9gdOdF.js`),[],import.meta.url))},{id:`ahk2`,name:`AutoHotkey2`,import:(()=>M(()=>import(`./ahk2-_6rzW9BS.js`),[],import.meta.url))},{id:`angular-html`,name:`Angular HTML`,import:(()=>M(()=>import(`./angular-html-Ix0KPi7a.js`).then(e=>e.n),__vite__mapDeps([0,1,2,3]),import.meta.url))},{id:`angular-ts`,name:`Angular TypeScript`,import:(()=>M(()=>import(`./angular-ts-C9FSwTpA.js`),__vite__mapDeps([4,0,1,2,3,5]),import.meta.url))},{id:`apache`,name:`Apache Conf`,import:(()=>M(()=>import(`./apache-U0d_L8uA.js`),[],import.meta.url))},{id:`apex`,name:`Apex`,import:(()=>M(()=>import(`./apex-KFGFyKwG.js`),[],import.meta.url))},{id:`apl`,name:`APL`,import:(()=>M(()=>import(`./apl-DKkOnH2I.js`),__vite__mapDeps([6,2,3,1,7,8,9]),import.meta.url))},{id:`applescript`,name:`AppleScript`,import:(()=>M(()=>import(`./applescript-CCn79oCD.js`),[],import.meta.url))},{id:`ara`,name:`Ara`,import:(()=>M(()=>import(`./ara-4CJ0cIlV.js`),[],import.meta.url))},{id:`asciidoc`,name:`AsciiDoc`,aliases:[`adoc`],import:(()=>M(()=>import(`./asciidoc-SCjQUq34.js`),[],import.meta.url))},{id:`asm`,name:`Assembly`,import:(()=>M(()=>import(`./asm-Cmm7eHzH.js`),[],import.meta.url))},{id:`astro`,name:`Astro`,import:(()=>M(()=>import(`./astro-DPET4gPf.js`),__vite__mapDeps([10,2,3,9,11,12,13]),import.meta.url))},{id:`awk`,name:`AWK`,import:(()=>M(()=>import(`./awk-BWXHIvNe.js`),[],import.meta.url))},{id:`ballerina`,name:`Ballerina`,import:(()=>M(()=>import(`./ballerina-B7ZEbQpA.js`),[],import.meta.url))},{id:`bat`,name:`Batch File`,aliases:[`batch`,`cmd`],import:(()=>M(()=>import(`./bat-qdxAdBWQ.js`),[],import.meta.url))},{id:`beancount`,name:`Beancount`,import:(()=>M(()=>import(`./beancount-D-usSTwE.js`),[],import.meta.url))},{id:`berry`,name:`Berry`,aliases:[`be`],import:(()=>M(()=>import(`./berry-DKpUyyne.js`),[],import.meta.url))},{id:`bibtex`,name:`BibTeX`,import:(()=>M(()=>import(`./bibtex-Ci_nEsc7.js`),[],import.meta.url))},{id:`bicep`,name:`Bicep`,import:(()=>M(()=>import(`./bicep-CUHmPFLl.js`),[],import.meta.url))},{id:`bird2`,name:`BIRD2 Configuration`,aliases:[`bird`],import:(()=>M(()=>import(`./bird2-CYIUgYqB.js`),[],import.meta.url))},{id:`blade`,name:`Blade`,import:(()=>M(()=>import(`./blade-DhJUXJLU.js`),__vite__mapDeps([14,2,3,1,7,8,9,15,16]),import.meta.url))},{id:`bsl`,name:`1C (Enterprise)`,aliases:[`1c`],import:(()=>M(()=>import(`./bsl-_VjlB9mv.js`),__vite__mapDeps([17,18]),import.meta.url))},{id:`c`,name:`C`,import:(()=>M(()=>import(`./c-67jpMvb2.js`).then(e=>e.n),[],import.meta.url))},{id:`c3`,name:`C3`,import:(()=>M(()=>import(`./c3-D0apG41V.js`),[],import.meta.url))},{id:`cadence`,name:`Cadence`,aliases:[`cdc`],import:(()=>M(()=>import(`./cadence-CQ2zXKGN.js`),[],import.meta.url))},{id:`cairo`,name:`Cairo`,import:(()=>M(()=>import(`./cairo-DLTphjLi.js`),__vite__mapDeps([19,20]),import.meta.url))},{id:`chapel`,name:`Chapel`,aliases:[`chpl`],import:(()=>M(()=>import(`./chapel-MBDqDT37.js`),__vite__mapDeps([21,22]),import.meta.url))},{id:`clarity`,name:`Clarity`,import:(()=>M(()=>import(`./clarity-CtfBBspg.js`),[],import.meta.url))},{id:`clojure`,name:`Clojure`,aliases:[`clj`],import:(()=>M(()=>import(`./clojure-DqKBuwfJ.js`),[],import.meta.url))},{id:`cmake`,name:`CMake`,import:(()=>M(()=>import(`./cmake-Bj61d0ZC.js`),[],import.meta.url))},{id:`cobol`,name:`COBOL`,import:(()=>M(()=>import(`./cobol-M2TY0mLn.js`),__vite__mapDeps([23,1,2,3,8]),import.meta.url))},{id:`codeowners`,name:`CODEOWNERS`,import:(()=>M(()=>import(`./codeowners-C8r90Shi.js`),[],import.meta.url))},{id:`codeql`,name:`CodeQL`,aliases:[`ql`],import:(()=>M(()=>import(`./codeql-oeQT6MSM.js`),[],import.meta.url))},{id:`coffee`,name:`CoffeeScript`,aliases:[`coffeescript`],import:(()=>M(()=>import(`./coffee-BC0bY29j.js`),__vite__mapDeps([24,2]),import.meta.url))},{id:`common-lisp`,name:`Common Lisp`,aliases:[`lisp`],import:(()=>M(()=>import(`./common-lisp-Cv5bFMCO.js`),[],import.meta.url))},{id:`coq`,name:`Rocq`,import:(()=>M(()=>import(`./coq-DuBRPxYg.js`),[],import.meta.url))},{id:`cpp`,name:`C++`,aliases:[`c++`],import:(()=>M(()=>import(`./cpp-DsCOGWNN.js`).then(e=>e.n),__vite__mapDeps([25,26,27,22]),import.meta.url))},{id:`crystal`,name:`Crystal`,import:(()=>M(()=>import(`./crystal-BCNAyK7e.js`),__vite__mapDeps([28,2,3,1,16,22,29]),import.meta.url))},{id:`csharp`,name:`C#`,aliases:[`c#`,`cs`],import:(()=>M(()=>import(`./csharp-oqKa8noW.js`),[],import.meta.url))},{id:`css`,name:`CSS`,import:(()=>M(()=>import(`./css-Z80vApOh.js`).then(e=>e.n),[],import.meta.url))},{id:`csv`,name:`CSV`,import:(()=>M(()=>import(`./csv-Dx-8-gkx.js`),[],import.meta.url))},{id:`cue`,name:`CUE`,import:(()=>M(()=>import(`./cue-CE9AQfxI.js`),[],import.meta.url))},{id:`cypher`,name:`Cypher`,aliases:[`cql`],import:(()=>M(()=>import(`./cypher-ClKdZ_lG.js`),[],import.meta.url))},{id:`d`,name:`D`,import:(()=>M(()=>import(`./d-qD-0Kul2.js`),[],import.meta.url))},{id:`dart`,name:`Dart`,import:(()=>M(()=>import(`./dart-CnvKMtbv.js`),[],import.meta.url))},{id:`dax`,name:`DAX`,import:(()=>M(()=>import(`./dax-BkyTk9wS.js`),[],import.meta.url))},{id:`desktop`,name:`Desktop`,import:(()=>M(()=>import(`./desktop-Dlh5hvp9.js`),[],import.meta.url))},{id:`diff`,name:`Diff`,import:(()=>M(()=>import(`./diff-woXpYk--.js`),[],import.meta.url))},{id:`docker`,name:`Dockerfile`,aliases:[`dockerfile`],import:(()=>M(()=>import(`./docker-IyjqRm3v.js`),[],import.meta.url))},{id:`dotenv`,name:`dotEnv`,import:(()=>M(()=>import(`./dotenv-_5a1GRtc.js`),[],import.meta.url))},{id:`dream-maker`,name:`Dream Maker`,import:(()=>M(()=>import(`./dream-maker-DW3nJb8Q.js`),[],import.meta.url))},{id:`edge`,name:`Edge`,import:(()=>M(()=>import(`./edge-Cu-rbWZy.js`),__vite__mapDeps([30,1,2,3,11,15]),import.meta.url))},{id:`elixir`,name:`Elixir`,import:(()=>M(()=>import(`./elixir-CAKwsmnn.js`),__vite__mapDeps([31,1,2,3]),import.meta.url))},{id:`elm`,name:`Elm`,import:(()=>M(()=>import(`./elm-CMQXUUh5.js`),__vite__mapDeps([32,27,22]),import.meta.url))},{id:`emacs-lisp`,name:`Emacs Lisp`,aliases:[`elisp`],import:(()=>M(()=>import(`./emacs-lisp-c_oH4hRZ.js`),[],import.meta.url))},{id:`erb`,name:`ERB`,import:(()=>M(()=>import(`./erb-B1_VD0-c.js`),__vite__mapDeps([33,1,2,3,34,7,8,16,22,25,26,27,29,35,36,11,13,37,38,39]),import.meta.url))},{id:`erlang`,name:`Erlang`,aliases:[`erl`],import:(()=>M(()=>import(`./erlang-Cphh6RMH.js`),__vite__mapDeps([40,41]),import.meta.url))},{id:`fennel`,name:`Fennel`,import:(()=>M(()=>import(`./fennel-DQxkIbk2.js`),[],import.meta.url))},{id:`fish`,name:`Fish`,import:(()=>M(()=>import(`./fish-BJitypiv.js`),[],import.meta.url))},{id:`fluent`,name:`Fluent`,aliases:[`ftl`],import:(()=>M(()=>import(`./fluent-C03EYrpw.js`),[],import.meta.url))},{id:`fortran-fixed-form`,name:`Fortran (Fixed Form)`,aliases:[`f`,`for`,`f77`],import:(()=>M(()=>import(`./fortran-fixed-form-DEKoE2YW.js`),__vite__mapDeps([42,43]),import.meta.url))},{id:`fortran-free-form`,name:`Fortran (Free Form)`,aliases:[`f90`,`f95`,`f03`,`f08`,`f18`],import:(()=>M(()=>import(`./fortran-free-form-CYNrtFtB.js`),[],import.meta.url))},{id:`fsharp`,name:`F#`,aliases:[`f#`,`fs`],import:(()=>M(()=>import(`./fsharp-D13ZGOAj.js`),__vite__mapDeps([44,41]),import.meta.url))},{id:`gdresource`,name:`GDResource`,aliases:[`tscn`,`tres`],import:(()=>M(()=>import(`./gdresource-xMC7jr7x.js`),__vite__mapDeps([45,46,47]),import.meta.url))},{id:`gdscript`,name:`GDScript`,aliases:[`gd`],import:(()=>M(()=>import(`./gdscript-DYvRD3hg.js`),[],import.meta.url))},{id:`gdshader`,name:`GDShader`,import:(()=>M(()=>import(`./gdshader-CBce3t8t.js`),[],import.meta.url))},{id:`genie`,name:`Genie`,import:(()=>M(()=>import(`./genie-CV2tkWYe.js`),[],import.meta.url))},{id:`gherkin`,name:`Gherkin`,import:(()=>M(()=>import(`./gherkin-DExj1W_8.js`),[],import.meta.url))},{id:`git-commit`,name:`Git Commit Message`,import:(()=>M(()=>import(`./git-commit-BSykSTBG.js`),__vite__mapDeps([48,49]),import.meta.url))},{id:`git-rebase`,name:`Git Rebase Message`,import:(()=>M(()=>import(`./git-rebase-D4h0IB-Z.js`),__vite__mapDeps([50,29]),import.meta.url))},{id:`gleam`,name:`Gleam`,import:(()=>M(()=>import(`./gleam-CSRkHgEL.js`),[],import.meta.url))},{id:`glimmer-js`,name:`Glimmer JS`,aliases:[`gjs`],import:(()=>M(()=>import(`./glimmer-js-D37W__QR.js`),__vite__mapDeps([51,2,3,1,11]),import.meta.url))},{id:`glimmer-ts`,name:`Glimmer TS`,aliases:[`gts`],import:(()=>M(()=>import(`./glimmer-ts-CJiHgwc1.js`),__vite__mapDeps([52,2,3,1,11]),import.meta.url))},{id:`glsl`,name:`GLSL`,import:(()=>M(()=>import(`./glsl-DPWDnqEZ.js`).then(e=>e.n),__vite__mapDeps([27,22]),import.meta.url))},{id:`gn`,name:`GN`,import:(()=>M(()=>import(`./gn-ilITqXS6.js`),[],import.meta.url))},{id:`gnuplot`,name:`Gnuplot`,import:(()=>M(()=>import(`./gnuplot-7GGW24-e.js`),[],import.meta.url))},{id:`go`,name:`Go`,import:(()=>M(()=>import(`./go-rLFTqkRN.js`),[],import.meta.url))},{id:`graphql`,name:`GraphQL`,aliases:[`gql`],import:(()=>M(()=>import(`./graphql-BERyG10r.js`).then(e=>e.n),__vite__mapDeps([36,2,11,13,37]),import.meta.url))},{id:`groovy`,name:`Groovy`,import:(()=>M(()=>import(`./groovy-CacY0gHj.js`),[],import.meta.url))},{id:`hack`,name:`Hack`,import:(()=>M(()=>import(`./hack-Dhrkqbqh.js`),__vite__mapDeps([53,1,2,3,16]),import.meta.url))},{id:`haml`,name:`Ruby Haml`,import:(()=>M(()=>import(`./haml-CgHqro8t.js`).then(e=>e.n),__vite__mapDeps([35,2,3]),import.meta.url))},{id:`handlebars`,name:`Handlebars`,aliases:[`hbs`],import:(()=>M(()=>import(`./handlebars-DA0oBJQC.js`),__vite__mapDeps([54,2,3,1,39]),import.meta.url))},{id:`haskell`,name:`Haskell`,aliases:[`hs`],import:(()=>M(()=>import(`./haskell-D8IpX4py.js`),[],import.meta.url))},{id:`haxe`,name:`Haxe`,import:(()=>M(()=>import(`./haxe-C8oCnwJJ.js`),[],import.meta.url))},{id:`hcl`,name:`HashiCorp HCL`,import:(()=>M(()=>import(`./hcl-Dh228itO.js`),[],import.meta.url))},{id:`hjson`,name:`Hjson`,import:(()=>M(()=>import(`./hjson-CxZEssPk.js`),[],import.meta.url))},{id:`hlsl`,name:`HLSL`,import:(()=>M(()=>import(`./hlsl-Cvrh5tZx.js`),[],import.meta.url))},{id:`html`,name:`HTML`,import:(()=>M(()=>import(`./html-C07_gUIM.js`).then(e=>e.n),__vite__mapDeps([1,2,3]),import.meta.url))},{id:`html-derivative`,name:`HTML (Derivative)`,import:(()=>M(()=>import(`./html-derivative-C2Iz7NdD.js`),__vite__mapDeps([15,1,2,3]),import.meta.url))},{id:`http`,name:`HTTP`,import:(()=>M(()=>import(`./http-BIjFcXtf.js`),__vite__mapDeps([55,7,8,9,29,36,2,11,13,37]),import.meta.url))},{id:`hurl`,name:`Hurl`,import:(()=>M(()=>import(`./hurl-BSo6-xEj.js`),__vite__mapDeps([56,7,8,57,36,2,11,13,37]),import.meta.url))},{id:`hxml`,name:`HXML`,import:(()=>M(()=>import(`./hxml-Dcm88srW.js`),__vite__mapDeps([58,59]),import.meta.url))},{id:`hy`,name:`Hy`,import:(()=>M(()=>import(`./hy-CZbG8q4J.js`),[],import.meta.url))},{id:`imba`,name:`Imba`,import:(()=>M(()=>import(`./imba-DsUTQ-LC.js`),[],import.meta.url))},{id:`ini`,name:`INI`,aliases:[`properties`],import:(()=>M(()=>import(`./ini-B5eOa1yu.js`),[],import.meta.url))},{id:`java`,name:`Java`,import:(()=>M(()=>import(`./java-CoMQRgf3.js`).then(e=>e.n),[],import.meta.url))},{id:`javascript`,name:`JavaScript`,aliases:[`js`,`cjs`,`mjs`],import:(()=>M(()=>import(`./javascript-59Bh6eFS.js`).then(e=>e.n),[],import.meta.url))},{id:`jinja`,name:`Jinja`,import:(()=>M(()=>import(`./jinja-BbL8kFH_.js`),__vite__mapDeps([60,1,2,3]),import.meta.url))},{id:`jison`,name:`Jison`,import:(()=>M(()=>import(`./jison-DkCA1Xy9.js`),__vite__mapDeps([61,2]),import.meta.url))},{id:`json`,name:`JSON`,import:(()=>M(()=>import(`./json-K7B9fx2M.js`).then(e=>e.n),[],import.meta.url))},{id:`json5`,name:`JSON5`,import:(()=>M(()=>import(`./json5-BR5RXkoi.js`),[],import.meta.url))},{id:`jsonc`,name:`JSON with Comments`,import:(()=>M(()=>import(`./jsonc-CYpm1nAK.js`),[],import.meta.url))},{id:`jsonl`,name:`JSON Lines`,import:(()=>M(()=>import(`./jsonl-CmCQp5Yx.js`),[],import.meta.url))},{id:`jsonnet`,name:`Jsonnet`,import:(()=>M(()=>import(`./jsonnet-CJTPZ8u_.js`),[],import.meta.url))},{id:`jssm`,name:`JSSM`,aliases:[`fsl`],import:(()=>M(()=>import(`./jssm-DXw9l8Rf.js`),[],import.meta.url))},{id:`jsx`,name:`JSX`,import:(()=>M(()=>import(`./jsx-CYU0LgTf.js`).then(e=>e.n),[],import.meta.url))},{id:`julia`,name:`Julia`,aliases:[`jl`],import:(()=>M(()=>import(`./julia-Cek7iS3T.js`),__vite__mapDeps([62,2,16,20,25,26,27,22,63]),import.meta.url))},{id:`just`,name:`Just`,aliases:[`justfile`],import:(()=>M(()=>import(`./just-CV-zTYju.js`),__vite__mapDeps([64,2,11,20,29,34,3,1,7,8,16,22,25,26,27,35,36,13,37,38,39,65]),import.meta.url))},{id:`kdl`,name:`KDL`,import:(()=>M(()=>import(`./kdl-CsD5j6eV.js`),[],import.meta.url))},{id:`kotlin`,name:`Kotlin`,aliases:[`kt`,`kts`],import:(()=>M(()=>import(`./kotlin-DhhofPvG.js`),[],import.meta.url))},{id:`kusto`,name:`Kusto`,aliases:[`kql`],import:(()=>M(()=>import(`./kusto-C7mF5XQf.js`),[],import.meta.url))},{id:`latex`,name:`LaTeX`,import:(()=>M(()=>import(`./latex-CumIBD1i.js`),__vite__mapDeps([66,67,63]),import.meta.url))},{id:`lean`,name:`Lean 4`,aliases:[`lean4`],import:(()=>M(()=>import(`./lean-CewbzKMR.js`),[],import.meta.url))},{id:`less`,name:`Less`,import:(()=>M(()=>import(`./less-DVTAwKKz.js`),[],import.meta.url))},{id:`liquid`,name:`Liquid`,import:(()=>M(()=>import(`./liquid-6O_k925L.js`),__vite__mapDeps([68,2,3,1,9]),import.meta.url))},{id:`llvm`,name:`LLVM IR`,import:(()=>M(()=>import(`./llvm-DqHOMS-s.js`),[],import.meta.url))},{id:`log`,name:`Log file`,import:(()=>M(()=>import(`./log-BNLmms1o.js`),[],import.meta.url))},{id:`logo`,name:`Logo`,import:(()=>M(()=>import(`./logo-Cluzi2Zq.js`),[],import.meta.url))},{id:`lua`,name:`Lua`,import:(()=>M(()=>import(`./lua-DSabO_9y.js`).then(e=>e.n),__vite__mapDeps([38,22]),import.meta.url))},{id:`luau`,name:`Luau`,import:(()=>M(()=>import(`./luau-C2pBCSgt.js`),[],import.meta.url))},{id:`make`,name:`Makefile`,aliases:[`makefile`],import:(()=>M(()=>import(`./make-Dixweg8N.js`),[],import.meta.url))},{id:`markdown`,name:`Markdown`,aliases:[`md`],import:(()=>M(()=>import(`./markdown-BYOwaDjH.js`),[],import.meta.url))},{id:`marko`,name:`Marko`,import:(()=>M(()=>import(`./marko-BQCJYZMU.js`),__vite__mapDeps([69,3,5,11,70]),import.meta.url))},{id:`matlab`,name:`MATLAB`,import:(()=>M(()=>import(`./matlab-D7qyCx1q.js`),[],import.meta.url))},{id:`mdc`,name:`MDC`,import:(()=>M(()=>import(`./mdc-C52qECYt.js`),__vite__mapDeps([71,15,1,2,3,39,41]),import.meta.url))},{id:`mdx`,name:`MDX`,import:(()=>M(()=>import(`./mdx-DQZ5AkYe.js`),[],import.meta.url))},{id:`mermaid`,name:`Mermaid`,aliases:[`mmd`],import:(()=>M(()=>import(`./mermaid-BxpfTIzt.js`),[],import.meta.url))},{id:`mipsasm`,name:`MIPS Assembly`,aliases:[`mips`],import:(()=>M(()=>import(`./mipsasm-BMqwQI7S.js`),[],import.meta.url))},{id:`mojo`,name:`Mojo`,import:(()=>M(()=>import(`./mojo-fg40_ntQ.js`),[],import.meta.url))},{id:`moonbit`,name:`MoonBit`,aliases:[`mbt`,`mbti`],import:(()=>M(()=>import(`./moonbit-DgjMoLWr.js`),[],import.meta.url))},{id:`move`,name:`Move`,import:(()=>M(()=>import(`./move-BYnGhZoM.js`),[],import.meta.url))},{id:`narrat`,name:`Narrat Language`,aliases:[`nar`],import:(()=>M(()=>import(`./narrat-_X_XdTYD.js`),[],import.meta.url))},{id:`nextflow`,name:`Nextflow`,aliases:[`nf`],import:(()=>M(()=>import(`./nextflow-BJtWHP5T.js`),__vite__mapDeps([72,73]),import.meta.url))},{id:`nextflow-groovy`,name:`Nextflow Groovy`,import:(()=>M(()=>import(`./nextflow-groovy-DJMQeKeT.js`),[],import.meta.url))},{id:`nginx`,name:`Nginx`,import:(()=>M(()=>import(`./nginx-wGDK7kDX.js`),__vite__mapDeps([74,38,22]),import.meta.url))},{id:`nim`,name:`Nim`,import:(()=>M(()=>import(`./nim-8L0XMTBj.js`),__vite__mapDeps([75,2,3,1,7,8,22,27,41]),import.meta.url))},{id:`nix`,name:`Nix`,import:(()=>M(()=>import(`./nix-IvuFDN5E.js`),[],import.meta.url))},{id:`nsis`,name:`NSIS`,import:(()=>M(()=>import(`./nsis-CjNLYCLg.js`),[],import.meta.url))},{id:`nushell`,name:`nushell`,aliases:[`nu`],import:(()=>M(()=>import(`./nushell-DHYfO66s.js`),[],import.meta.url))},{id:`objective-c`,name:`Objective-C`,aliases:[`objc`],import:(()=>M(()=>import(`./objective-c-D1A_Heim.js`),[],import.meta.url))},{id:`objective-cpp`,name:`Objective-C++`,import:(()=>M(()=>import(`./objective-cpp-BsSzOQcm.js`),[],import.meta.url))},{id:`ocaml`,name:`OCaml`,import:(()=>M(()=>import(`./ocaml-O90oeIOV.js`),[],import.meta.url))},{id:`odin`,name:`Odin`,import:(()=>M(()=>import(`./odin-B1RWQWA5.js`),[],import.meta.url))},{id:`openscad`,name:`OpenSCAD`,aliases:[`scad`],import:(()=>M(()=>import(`./openscad-BUDT5pXO.js`),[],import.meta.url))},{id:`org`,name:`Org Markup`,import:(()=>M(()=>import(`./org-qlylGQgn.js`),__vite__mapDeps([76,2,3,1,5,8,7,9,11,13,16,22,20,77,24,26,25,27,29,78,79,49,80,31,38,39,34,35,36,37,41,40,48,50,81,82,83,63,65,66,67,70,84,75,85,86,87,88,89,90,91,92,93]),import.meta.url))},{id:`pascal`,name:`Pascal`,import:(()=>M(()=>import(`./pascal-4ZHwLPI5.js`),[],import.meta.url))},{id:`perl`,name:`Perl`,import:(()=>M(()=>import(`./perl-CykLITRy.js`),__vite__mapDeps([65,2,3,1,7,8,16]),import.meta.url))},{id:`php`,name:`PHP`,import:(()=>M(()=>import(`./php-OrvNGJNb.js`),__vite__mapDeps([87,2,3,1,7,8,9,16]),import.meta.url))},{id:`pkl`,name:`Pkl`,import:(()=>M(()=>import(`./pkl-ot-7Btpt.js`),[],import.meta.url))},{id:`plsql`,name:`PL/SQL`,import:(()=>M(()=>import(`./plsql-DGHpHOYJ.js`),[],import.meta.url))},{id:`po`,name:`Gettext PO`,aliases:[`pot`,`potx`],import:(()=>M(()=>import(`./po-BiJDBrnU.js`),[],import.meta.url))},{id:`polar`,name:`Polar`,import:(()=>M(()=>import(`./polar-C7UOKdEL.js`),[],import.meta.url))},{id:`postcss`,name:`PostCSS`,import:(()=>M(()=>import(`./postcss-BXeXVLqQ.js`),[],import.meta.url))},{id:`powerquery`,name:`PowerQuery`,import:(()=>M(()=>import(`./powerquery-DNMTfnFr.js`),[],import.meta.url))},{id:`powershell`,name:`PowerShell`,aliases:[`ps`,`ps1`,`pwsh`],import:(()=>M(()=>import(`./powershell-CCSX75yM.js`),[],import.meta.url))},{id:`prisma`,name:`Prisma`,import:(()=>M(()=>import(`./prisma-DMgNhnYS.js`),[],import.meta.url))},{id:`prolog`,name:`Prolog`,import:(()=>M(()=>import(`./prolog-iXnhIJG7.js`),[],import.meta.url))},{id:`proto`,name:`Protocol Buffer 3`,aliases:[`protobuf`],import:(()=>M(()=>import(`./proto-DB4EqR-F.js`),[],import.meta.url))},{id:`pug`,name:`Pug`,aliases:[`jade`],import:(()=>M(()=>import(`./pug-YNEJJlsa.js`),__vite__mapDeps([94,2,3,1]),import.meta.url))},{id:`puppet`,name:`Puppet`,import:(()=>M(()=>import(`./puppet-CDv2pdJW.js`),[],import.meta.url))},{id:`purescript`,name:`PureScript`,import:(()=>M(()=>import(`./purescript-9MfHhQsQ.js`),[],import.meta.url))},{id:`python`,name:`Python`,aliases:[`py`],import:(()=>M(()=>import(`./python-gzcpVVnB.js`),[],import.meta.url))},{id:`qml`,name:`QML`,import:(()=>M(()=>import(`./qml-CcMVyzXP.js`),__vite__mapDeps([95,2]),import.meta.url))},{id:`qmldir`,name:`QML Directory`,import:(()=>M(()=>import(`./qmldir-DCQb3MpD.js`),[],import.meta.url))},{id:`qss`,name:`Qt Style Sheets`,import:(()=>M(()=>import(`./qss-Fe1Jh2GI.js`),[],import.meta.url))},{id:`r`,name:`R`,import:(()=>M(()=>import(`./r-BME81pvY.js`).then(e=>e.n),[],import.meta.url))},{id:`racket`,name:`Racket`,import:(()=>M(()=>import(`./racket-DcIDlBhZ.js`),[],import.meta.url))},{id:`raku`,name:`Raku`,aliases:[`perl6`],import:(()=>M(()=>import(`./raku-B3gFvitq.js`),[],import.meta.url))},{id:`razor`,name:`ASP.NET Razor`,import:(()=>M(()=>import(`./razor-B6zaSHM_.js`),__vite__mapDeps([96,1,2,3,78]),import.meta.url))},{id:`rbs`,name:`RBS`,aliases:[`ruby-signature`],import:(()=>M(()=>import(`./rbs-C0MpOrj4.js`),[],import.meta.url))},{id:`reg`,name:`Windows Registry Script`,import:(()=>M(()=>import(`./reg-CRGYupPL.js`),[],import.meta.url))},{id:`regexp`,name:`RegExp`,aliases:[`regex`],import:(()=>M(()=>import(`./regexp-hfj_QKqr.js`).then(e=>e.n),[],import.meta.url))},{id:`rel`,name:`Rel`,import:(()=>M(()=>import(`./rel-BtDbiS_P.js`),[],import.meta.url))},{id:`riscv`,name:`RISC-V`,import:(()=>M(()=>import(`./riscv-Ckw8ddFX.js`),[],import.meta.url))},{id:`ron`,name:`RON`,import:(()=>M(()=>import(`./ron-VUp2lXgN.js`),[],import.meta.url))},{id:`rosmsg`,name:`ROS Interface`,import:(()=>M(()=>import(`./rosmsg-CAekHB0j.js`),[],import.meta.url))},{id:`rst`,name:`reStructuredText`,import:(()=>M(()=>import(`./rst-DW60Xb1U.js`),__vite__mapDeps([97,2,15,1,3,20,98,25,26,27,22,29,39,34,7,8,16,35,36,11,13,37,38]),import.meta.url))},{id:`ruby`,name:`Ruby`,aliases:[`rb`],import:(()=>M(()=>import(`./ruby-CC0ZraKC.js`),__vite__mapDeps([34,2,3,1,7,8,16,22,25,26,27,29,35,36,11,13,37,38,39]),import.meta.url))},{id:`rust`,name:`Rust`,aliases:[`rs`],import:(()=>M(()=>import(`./rust-Cfkwpbl8.js`),[],import.meta.url))},{id:`sas`,name:`SAS`,import:(()=>M(()=>import(`./sas-9nl6_97c.js`),__vite__mapDeps([99,16]),import.meta.url))},{id:`sass`,name:`Sass`,import:(()=>M(()=>import(`./sass-DXrisJhu.js`),[],import.meta.url))},{id:`scala`,name:`Scala`,import:(()=>M(()=>import(`./scala-BiFt_7mu.js`),[],import.meta.url))},{id:`scheme`,name:`Scheme`,import:(()=>M(()=>import(`./scheme-DQCgrYNe.js`),[],import.meta.url))},{id:`scss`,name:`SCSS`,import:(()=>M(()=>import(`./scss-Otpp0Cxe.js`).then(e=>e.n),__vite__mapDeps([5,3]),import.meta.url))},{id:`sdbl`,name:`1C (Query)`,aliases:[`1c-query`],import:(()=>M(()=>import(`./sdbl-bTVj8UrX.js`),[],import.meta.url))},{id:`shaderlab`,name:`ShaderLab`,aliases:[`shader`],import:(()=>M(()=>import(`./shaderlab-TOUzSsQk.js`),__vite__mapDeps([100,101]),import.meta.url))},{id:`shellscript`,name:`Shell`,aliases:[`bash`,`sh`,`shell`,`zsh`],import:(()=>M(()=>import(`./shellscript-DZKiAu0u.js`).then(e=>e.n),[],import.meta.url))},{id:`shellsession`,name:`Shell Session`,aliases:[`console`],import:(()=>M(()=>import(`./shellsession-CFyCG6LV.js`),__vite__mapDeps([102,29]),import.meta.url))},{id:`smalltalk`,name:`GNU Smalltalk`,import:(()=>M(()=>import(`./smalltalk-BHpQb5nM.js`),[],import.meta.url))},{id:`smithy`,name:`Smithy`,import:(()=>M(()=>import(`./smithy-Dgaz7aur.js`),[],import.meta.url))},{id:`solidity`,name:`Solidity`,import:(()=>M(()=>import(`./solidity-Bj7E1mRn.js`),[],import.meta.url))},{id:`soy`,name:`Closure Templates`,aliases:[`closure-templates`],import:(()=>M(()=>import(`./soy-4B16Rf4R.js`),__vite__mapDeps([103,1,2,3]),import.meta.url))},{id:`sparql`,name:`SPARQL`,import:(()=>M(()=>import(`./sparql-D_iOobhT.js`),__vite__mapDeps([104,105]),import.meta.url))},{id:`splunk`,name:`Splunk Query Language`,aliases:[`spl`],import:(()=>M(()=>import(`./splunk-BC2Px7Mm.js`),[],import.meta.url))},{id:`sql`,name:`SQL`,import:(()=>M(()=>import(`./sql-BfAjAHn7.js`).then(e=>e.n),[],import.meta.url))},{id:`ssh-config`,name:`SSH Config`,import:(()=>M(()=>import(`./ssh-config-BgfXC-Er.js`),[],import.meta.url))},{id:`stata`,name:`Stata`,import:(()=>M(()=>import(`./stata-B_5JAo7J.js`),__vite__mapDeps([106,16]),import.meta.url))},{id:`stylus`,name:`Stylus`,aliases:[`styl`],import:(()=>M(()=>import(`./stylus-B6D30XZt.js`),[],import.meta.url))},{id:`surrealql`,name:`SurrealQL`,aliases:[`surql`],import:(()=>M(()=>import(`./surrealql-B0HCK9pb.js`),__vite__mapDeps([107,2]),import.meta.url))},{id:`svelte`,name:`Svelte`,import:(()=>M(()=>import(`./svelte-C0cCGsEl.js`),__vite__mapDeps([108,2,3,11,12]),import.meta.url))},{id:`swift`,name:`Swift`,import:(()=>M(()=>import(`./swift-CyEgAFGc.js`),[],import.meta.url))},{id:`system-verilog`,name:`SystemVerilog`,import:(()=>M(()=>import(`./system-verilog-Dh5ihWbf.js`),[],import.meta.url))},{id:`systemd`,name:`Systemd Units`,import:(()=>M(()=>import(`./systemd-BxMlprV5.js`),[],import.meta.url))},{id:`talonscript`,name:`TalonScript`,aliases:[`talon`],import:(()=>M(()=>import(`./talonscript-CohzipZa.js`),[],import.meta.url))},{id:`tasl`,name:`Tasl`,import:(()=>M(()=>import(`./tasl-DMoTqEGO.js`),[],import.meta.url))},{id:`tcl`,name:`Tcl`,import:(()=>M(()=>import(`./tcl-CZd0xW_V.js`),[],import.meta.url))},{id:`templ`,name:`Templ`,import:(()=>M(()=>import(`./templ-D1R1J2lJ.js`),__vite__mapDeps([109,2,3,81]),import.meta.url))},{id:`terraform`,name:`Terraform`,aliases:[`tf`,`tfvars`],import:(()=>M(()=>import(`./terraform-DswuEJGm.js`),[],import.meta.url))},{id:`tex`,name:`TeX`,import:(()=>M(()=>import(`./tex--Wuw24L6.js`).then(e=>e.n),__vite__mapDeps([67,63]),import.meta.url))},{id:`toml`,name:`TOML`,import:(()=>M(()=>import(`./toml-CcmNWLt0.js`),[],import.meta.url))},{id:`ts-tags`,name:`TypeScript with Tags`,aliases:[`lit`],import:(()=>M(()=>import(`./ts-tags-Dq1FPY1M.js`),__vite__mapDeps([110,2,3,1,7,8,11,16,27,22]),import.meta.url))},{id:`tsv`,name:`TSV`,import:(()=>M(()=>import(`./tsv-sltzmVWM.js`),[],import.meta.url))},{id:`tsx`,name:`TSX`,import:(()=>M(()=>import(`./tsx-VGY-Mp0k.js`).then(e=>e.n),[],import.meta.url))},{id:`turtle`,name:`Turtle`,import:(()=>M(()=>import(`./turtle-ByJddavk.js`),[],import.meta.url))},{id:`twig`,name:`Twig`,import:(()=>M(()=>import(`./twig-BEkxP8Q6.js`),__vite__mapDeps([111,2,3,5,20,34,1,7,8,16,22,25,26,27,29,35,36,11,13,37,38,39,87,9]),import.meta.url))},{id:`typescript`,name:`TypeScript`,aliases:[`ts`,`cts`,`mts`],import:(()=>M(()=>import(`./typescript-CPyocJP3.js`).then(e=>e.n),[],import.meta.url))},{id:`typespec`,name:`TypeSpec`,aliases:[`tsp`],import:(()=>M(()=>import(`./typespec-BRdr0IET.js`),[],import.meta.url))},{id:`typst`,name:`Typst`,aliases:[`typ`],import:(()=>M(()=>import(`./typst-xRIkWHxZ.js`),__vite__mapDeps([112,2,3,1,5,8,7,9,11,13,113,114,16,22,20,77,24,26,25,27,29,78,79,49,80,31,38,39,34,35,36,37,41,40,44,48,50,81,82,54,83,115,63,62,65,66,67,70,116,84,85,87,88,89,90,91,93,117,94,118,119,111,120]),import.meta.url))},{id:`v`,name:`V`,import:(()=>M(()=>import(`./v-DBj4K9d_.js`),[],import.meta.url))},{id:`vala`,name:`Vala`,import:(()=>M(()=>import(`./vala-zf12oZj6.js`),[],import.meta.url))},{id:`vb`,name:`Visual Basic`,import:(()=>M(()=>import(`./vb-DOwzaHZ0.js`),[],import.meta.url))},{id:`verilog`,name:`Verilog`,import:(()=>M(()=>import(`./verilog-B2gwz-sJ.js`),[],import.meta.url))},{id:`vhdl`,name:`VHDL`,import:(()=>M(()=>import(`./vhdl-BroJfC0k.js`),[],import.meta.url))},{id:`viml`,name:`Vim Script`,aliases:[`vim`,`vimscript`],import:(()=>M(()=>import(`./viml-DvXPmvsu.js`),[],import.meta.url))},{id:`vue`,name:`Vue`,import:(()=>M(()=>import(`./vue-C5KmXZMh.js`),__vite__mapDeps([121,2,3,1,9,11,15]),import.meta.url))},{id:`vue-html`,name:`Vue HTML`,import:(()=>M(()=>import(`./vue-html-xbHMTmXj.js`),__vite__mapDeps([122,2]),import.meta.url))},{id:`vue-vine`,name:`Vue Vine`,import:(()=>M(()=>import(`./vue-vine-CArUes0e.js`),__vite__mapDeps([123,2,3,5,12,70,124]),import.meta.url))},{id:`vyper`,name:`Vyper`,aliases:[`vy`],import:(()=>M(()=>import(`./vyper-CgoNMtux.js`),[],import.meta.url))},{id:`wasm`,name:`WebAssembly`,import:(()=>M(()=>import(`./wasm-ByWQv1Qj.js`),[],import.meta.url))},{id:`wenyan`,name:`Wenyan`,aliases:[`文言`],import:(()=>M(()=>import(`./wenyan-C8pVoKbM.js`),[],import.meta.url))},{id:`wgsl`,name:`WGSL`,import:(()=>M(()=>import(`./wgsl-BsKzXJz4.js`),[],import.meta.url))},{id:`wikitext`,name:`Wikitext`,aliases:[`mediawiki`,`wiki`],import:(()=>M(()=>import(`./wikitext-ClFFjSW2.js`),[],import.meta.url))},{id:`wit`,name:`WebAssembly Interface Types`,import:(()=>M(()=>import(`./wit-DdvCle-K.js`),[],import.meta.url))},{id:`wolfram`,name:`Wolfram`,aliases:[`wl`],import:(()=>M(()=>import(`./wolfram-DLL8P-h_.js`),[],import.meta.url))},{id:`xml`,name:`XML`,import:(()=>M(()=>import(`./xml-CgD7OGIH.js`).then(e=>e.n),__vite__mapDeps([7,8]),import.meta.url))},{id:`xsl`,name:`XSL`,import:(()=>M(()=>import(`./xsl-DXL0y1Sw.js`),__vite__mapDeps([93,7,8]),import.meta.url))},{id:`yaml`,name:`YAML`,aliases:[`yml`],import:(()=>M(()=>import(`./yaml-BOSKQnUw.js`).then(e=>e.n),[],import.meta.url))},{id:`zenscript`,name:`ZenScript`,import:(()=>M(()=>import(`./zenscript-BnlCZFoB.js`),[],import.meta.url))},{id:`zig`,name:`Zig`,import:(()=>M(()=>import(`./zig-CMLA9XwU.js`),[],import.meta.url))}],ut=Object.fromEntries(lt.map(e=>[e.id,e.import])),dt=Object.fromEntries(lt.flatMap(e=>e.aliases?.map(t=>[t,e.import])||[])),ft={...ut,...dt},pt=Object.fromEntries([{id:`andromeeda`,displayName:`Andromeeda`,type:`dark`,import:(()=>M(()=>import(`./andromeeda-vGVdxbeo.js`),[],import.meta.url))},{id:`aurora-x`,displayName:`Aurora X`,type:`dark`,import:(()=>M(()=>import(`./aurora-x-CDeNXAV0.js`),[],import.meta.url))},{id:`ayu-dark`,displayName:`Ayu Dark`,type:`dark`,import:(()=>M(()=>import(`./ayu-dark-DluEY0Gj.js`),[],import.meta.url))},{id:`ayu-light`,displayName:`Ayu Light`,type:`light`,import:(()=>M(()=>import(`./ayu-light-C3h-C4tm.js`),[],import.meta.url))},{id:`ayu-mirage`,displayName:`Ayu Mirage`,type:`dark`,import:(()=>M(()=>import(`./ayu-mirage-Bqwy1Gya.js`),[],import.meta.url))},{id:`catppuccin-frappe`,displayName:`Catppuccin Frappé`,type:`dark`,import:(()=>M(()=>import(`./catppuccin-frappe-C9Q5zVZY.js`),[],import.meta.url))},{id:`catppuccin-latte`,displayName:`Catppuccin Latte`,type:`light`,import:(()=>M(()=>import(`./catppuccin-latte-CtsyrtPq.js`),[],import.meta.url))},{id:`catppuccin-macchiato`,displayName:`Catppuccin Macchiato`,type:`dark`,import:(()=>M(()=>import(`./catppuccin-macchiato-R8nAf1vR.js`),[],import.meta.url))},{id:`catppuccin-mocha`,displayName:`Catppuccin Mocha`,type:`dark`,import:(()=>M(()=>import(`./catppuccin-mocha-DjuaAJKi.js`),[],import.meta.url))},{id:`dark-plus`,displayName:`Dark Plus`,type:`dark`,import:(()=>M(()=>import(`./dark-plus-Cs2F2srj.js`),[],import.meta.url))},{id:`dracula`,displayName:`Dracula Theme`,type:`dark`,import:(()=>M(()=>import(`./dracula-BHWKrbxM.js`),[],import.meta.url))},{id:`dracula-soft`,displayName:`Dracula Theme Soft`,type:`dark`,import:(()=>M(()=>import(`./dracula-soft-5eyTD99u.js`),[],import.meta.url))},{id:`everforest-dark`,displayName:`Everforest Dark`,type:`dark`,import:(()=>M(()=>import(`./everforest-dark-sB-x3p7T.js`),[],import.meta.url))},{id:`everforest-light`,displayName:`Everforest Light`,type:`light`,import:(()=>M(()=>import(`./everforest-light-Df2xbC6M.js`),[],import.meta.url))},{id:`github-dark`,displayName:`GitHub Dark`,type:`dark`,import:(()=>M(()=>import(`./github-dark-C-LZuMrd.js`),[],import.meta.url))},{id:`github-dark-default`,displayName:`GitHub Dark Default`,type:`dark`,import:(()=>M(()=>import(`./github-dark-default-DXG-b-1a.js`),[],import.meta.url))},{id:`github-dark-dimmed`,displayName:`GitHub Dark Dimmed`,type:`dark`,import:(()=>M(()=>import(`./github-dark-dimmed-Bx1FflLF.js`),[],import.meta.url))},{id:`github-dark-high-contrast`,displayName:`GitHub Dark High Contrast`,type:`dark`,import:(()=>M(()=>import(`./github-dark-high-contrast-B_tTalzw.js`),[],import.meta.url))},{id:`github-light`,displayName:`GitHub Light`,type:`light`,import:(()=>M(()=>import(`./github-light-EUqPIrTm.js`),[],import.meta.url))},{id:`github-light-default`,displayName:`GitHub Light Default`,type:`light`,import:(()=>M(()=>import(`./github-light-default-BXViO-2h.js`),[],import.meta.url))},{id:`github-light-high-contrast`,displayName:`GitHub Light High Contrast`,type:`light`,import:(()=>M(()=>import(`./github-light-high-contrast-B68TUdTA.js`),[],import.meta.url))},{id:`gruvbox-dark-hard`,displayName:`Gruvbox Dark Hard`,type:`dark`,import:(()=>M(()=>import(`./gruvbox-dark-hard-C820rvS2.js`),[],import.meta.url))},{id:`gruvbox-dark-medium`,displayName:`Gruvbox Dark Medium`,type:`dark`,import:(()=>M(()=>import(`./gruvbox-dark-medium-BPjhmG05.js`),[],import.meta.url))},{id:`gruvbox-dark-soft`,displayName:`Gruvbox Dark Soft`,type:`dark`,import:(()=>M(()=>import(`./gruvbox-dark-soft-MrdJrrXF.js`),[],import.meta.url))},{id:`gruvbox-light-hard`,displayName:`Gruvbox Light Hard`,type:`light`,import:(()=>M(()=>import(`./gruvbox-light-hard-BC_s9l72.js`),[],import.meta.url))},{id:`gruvbox-light-medium`,displayName:`Gruvbox Light Medium`,type:`light`,import:(()=>M(()=>import(`./gruvbox-light-medium-BAWPOn9u.js`),[],import.meta.url))},{id:`gruvbox-light-soft`,displayName:`Gruvbox Light Soft`,type:`light`,import:(()=>M(()=>import(`./gruvbox-light-soft-BSMLrYjP.js`),[],import.meta.url))},{id:`horizon`,displayName:`Horizon`,type:`dark`,import:(()=>M(()=>import(`./horizon-CE9ld1lL.js`),[],import.meta.url))},{id:`horizon-bright`,displayName:`Horizon Bright`,type:`light`,import:(()=>M(()=>import(`./horizon-bright-DSNQnXHK.js`),[],import.meta.url))},{id:`houston`,displayName:`Houston`,type:`dark`,import:(()=>M(()=>import(`./houston-CsvMBhTu.js`),[],import.meta.url))},{id:`kanagawa-dragon`,displayName:`Kanagawa Dragon`,type:`dark`,import:(()=>M(()=>import(`./kanagawa-dragon-Bozd7klA.js`),[],import.meta.url))},{id:`kanagawa-lotus`,displayName:`Kanagawa Lotus`,type:`light`,import:(()=>M(()=>import(`./kanagawa-lotus-BmuOG9ZW.js`),[],import.meta.url))},{id:`kanagawa-wave`,displayName:`Kanagawa Wave`,type:`dark`,import:(()=>M(()=>import(`./kanagawa-wave-BML5mF2J.js`),[],import.meta.url))},{id:`laserwave`,displayName:`LaserWave`,type:`dark`,import:(()=>M(()=>import(`./laserwave-C_8bwKvT.js`),[],import.meta.url))},{id:`light-plus`,displayName:`Light Plus`,type:`light`,import:(()=>M(()=>import(`./light-plus-DVQuIRkW.js`),[],import.meta.url))},{id:`material-theme`,displayName:`Material Theme`,type:`dark`,import:(()=>M(()=>import(`./material-theme-Bm3Qr25_.js`),[],import.meta.url))},{id:`material-theme-darker`,displayName:`Material Theme Darker`,type:`dark`,import:(()=>M(()=>import(`./material-theme-darker-2IIEA8gg.js`),[],import.meta.url))},{id:`material-theme-lighter`,displayName:`Material Theme Lighter`,type:`light`,import:(()=>M(()=>import(`./material-theme-lighter-uhdI0v04.js`),[],import.meta.url))},{id:`material-theme-ocean`,displayName:`Material Theme Ocean`,type:`dark`,import:(()=>M(()=>import(`./material-theme-ocean-CHQ94UKr.js`),[],import.meta.url))},{id:`material-theme-palenight`,displayName:`Material Theme Palenight`,type:`dark`,import:(()=>M(()=>import(`./material-theme-palenight-B5W6OYN7.js`),[],import.meta.url))},{id:`min-dark`,displayName:`Min Dark`,type:`dark`,import:(()=>M(()=>import(`./min-dark-BSWPekZh.js`),[],import.meta.url))},{id:`min-light`,displayName:`Min Light`,type:`light`,import:(()=>M(()=>import(`./min-light-DDpmG2fV.js`),[],import.meta.url))},{id:`monokai`,displayName:`Monokai`,type:`dark`,import:(()=>M(()=>import(`./monokai-B_bV9PQ9.js`),[],import.meta.url))},{id:`night-owl`,displayName:`Night Owl`,type:`dark`,import:(()=>M(()=>import(`./night-owl-DhmEMT88.js`),[],import.meta.url))},{id:`night-owl-light`,displayName:`Night Owl Light`,type:`light`,import:(()=>M(()=>import(`./night-owl-light-eJ-hLW7d.js`),[],import.meta.url))},{id:`nord`,displayName:`Nord`,type:`dark`,import:(()=>M(()=>import(`./nord-Cb4Vim4T.js`),[],import.meta.url))},{id:`one-dark-pro`,displayName:`One Dark Pro`,type:`dark`,import:(()=>M(()=>import(`./one-dark-pro-CLwyXe_n.js`),[],import.meta.url))},{id:`one-light`,displayName:`One Light`,type:`light`,import:(()=>M(()=>import(`./one-light-D7Lr4KcI.js`),[],import.meta.url))},{id:`plastic`,displayName:`Plastic`,type:`dark`,import:(()=>M(()=>import(`./plastic-DQwYfKfQ.js`),[],import.meta.url))},{id:`poimandres`,displayName:`Poimandres`,type:`dark`,import:(()=>M(()=>import(`./poimandres-DRFjx7u4.js`),[],import.meta.url))},{id:`red`,displayName:`Red`,type:`dark`,import:(()=>M(()=>import(`./red-DX1BQOs8.js`),[],import.meta.url))},{id:`rose-pine`,displayName:`Rosé Pine`,type:`dark`,import:(()=>M(()=>import(`./rose-pine-aMsaMD1D.js`),[],import.meta.url))},{id:`rose-pine-dawn`,displayName:`Rosé Pine Dawn`,type:`light`,import:(()=>M(()=>import(`./rose-pine-dawn-8PwUyIlP.js`),[],import.meta.url))},{id:`rose-pine-moon`,displayName:`Rosé Pine Moon`,type:`dark`,import:(()=>M(()=>import(`./rose-pine-moon-DO-qXg-I.js`),[],import.meta.url))},{id:`slack-dark`,displayName:`Slack Dark`,type:`dark`,import:(()=>M(()=>import(`./slack-dark-DnToyrRv.js`),[],import.meta.url))},{id:`slack-ochin`,displayName:`Slack Ochin`,type:`light`,import:(()=>M(()=>import(`./slack-ochin-B2OO5cIa.js`),[],import.meta.url))},{id:`snazzy-light`,displayName:`Snazzy Light`,type:`light`,import:(()=>M(()=>import(`./snazzy-light-4G7pJPwS.js`),[],import.meta.url))},{id:`solarized-dark`,displayName:`Solarized Dark`,type:`dark`,import:(()=>M(()=>import(`./solarized-dark-UdsmMDCL.js`),[],import.meta.url))},{id:`solarized-light`,displayName:`Solarized Light`,type:`light`,import:(()=>M(()=>import(`./solarized-light-C1IUL_tW.js`),[],import.meta.url))},{id:`synthwave-84`,displayName:`Synthwave '84`,type:`dark`,import:(()=>M(()=>import(`./synthwave-84-nFMaYfgc.js`),[],import.meta.url))},{id:`tokyo-night`,displayName:`Tokyo Night`,type:`dark`,import:(()=>M(()=>import(`./tokyo-night-oM2G3aXe.js`),[],import.meta.url))},{id:`vesper`,displayName:`Vesper`,type:`dark`,import:(()=>M(()=>import(`./vesper-DdrHHSXu.js`),[],import.meta.url))},{id:`vitesse-black`,displayName:`Vitesse Black`,type:`dark`,import:(()=>M(()=>import(`./vitesse-black-fwtXNY1n.js`),[],import.meta.url))},{id:`vitesse-dark`,displayName:`Vitesse Dark`,type:`dark`,import:(()=>M(()=>import(`./vitesse-dark-BZCL-v6S.js`),[],import.meta.url))},{id:`vitesse-light`,displayName:`Vitesse Light`,type:`light`,import:(()=>M(()=>import(`./vitesse-light-VbXTXTou.js`),[],import.meta.url))}].map(e=>[e.id,e.import])),mt=s({createOnigurumaEngine:()=>Ht,getDefaultWasmLoader:()=>Vt,loadWasm:()=>Ft,setDefaultWasmLoader:()=>Bt}),ht=class extends Error{constructor(e){super(e),this.name=`ShikiError`}};function gt(){return 2147483648}function _t(){return typeof performance<`u`?performance.now():Date.now()}var vt=(e,t)=>e+(t-e%t)%t;async function yt(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=gt();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,vt(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:_t,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 bt=Object.defineProperty,xt=(e,t,n)=>t in e?bt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,St=(e,t,n)=>xt(e,typeof t==`symbol`?t:t+``,n),Ct=null;function wt(e){throw new ht(e.UTF8ToString(e.getLastOnigError()))}var Tt=class e{constructor(t){St(this,`utf16Length`),St(this,`utf8Length`),St(this,`utf16Value`),St(this,`utf8Value`),St(this,`utf16OffsetToUtf8`),St(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)}t+=a<=127?1:a<=2047?2:a<=65535?3:4,o&&n++}return t}createString(e){let t=e.omalloc(this.utf8Length);return e.HEAPU8.set(this.utf8Value,t),t}},Et=class e{constructor(t){if(St(this,`id`,++e.LAST_ID),St(this,`_onigBinding`),St(this,`content`),St(this,`utf16Length`),St(this,`utf8Length`),St(this,`utf16OffsetToUtf8`),St(this,`utf8OffsetToUtf16`),St(this,`ptr`),!Ct)throw new ht(`Must invoke loadWasm first.`);this._onigBinding=Ct,this.content=t;let n=new Tt(t);this.utf16Length=n.utf16Length,this.utf8Length=n.utf8Length,this.utf16OffsetToUtf8=n.utf16OffsetToUtf8,this.utf8OffsetToUtf16=n.utf8OffsetToUtf16,this.utf8Length<1e4&&!e._sharedPtrInUse?(e._sharedPtr||=Ct.omalloc(1e4),e._sharedPtrInUse=!0,Ct.HEAPU8.set(n.utf8Value,e._sharedPtr),this.ptr=e._sharedPtr):this.ptr=n.createString(Ct)}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)}};St(Et,`LAST_ID`,0),St(Et,`_sharedPtr`,0),St(Et,`_sharedPtrInUse`,!1);var Dt=Et,Ot=class{constructor(e){if(St(this,`_onigBinding`),St(this,`_ptr`),!Ct)throw new ht(`Must invoke loadWasm first.`);let t=[],n=[];for(let r=0,i=e.length;r<i;r++){let i=new Tt(e[r]);t[r]=i.createString(Ct),n[r]=i.utf8Length}let r=Ct.omalloc(4*e.length);Ct.HEAPU32.set(t,r/4);let i=Ct.omalloc(4*e.length);Ct.HEAPU32.set(n,i/4);let a=Ct.createOnigScanner(r,i,e.length);for(let n=0,r=e.length;n<r;n++)Ct.ofree(t[n]);Ct.ofree(i),Ct.ofree(r),a===0&&wt(Ct),this._onigBinding=Ct,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 Dt(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 kt(e){return typeof e.instantiator==`function`}function At(e){return typeof e.default==`function`}function jt(e){return e.data!==void 0}function Mt(e){return typeof Response<`u`&&e instanceof Response}function Nt(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 Pt;function Ft(e){if(Pt)return Pt;async function t(){Ct=await yt(async t=>{let n=e;return n=await n,typeof n==`function`&&(n=await n(t)),typeof n==`function`&&(n=await n(t)),kt(n)?n=await n.instantiator(t):At(n)?n=await n.default(t):(jt(n)&&(n=n.data),Mt(n)?n=typeof WebAssembly.instantiateStreaming==`function`?await Lt(n)(t):await Rt(n)(t):Nt(n)||n instanceof WebAssembly.Module?n=await It(n)(t):`default`in n&&n.default instanceof WebAssembly.Module&&(n=await It(n.default)(t))),`instance`in n&&(n=n.instance),`exports`in n&&(n=n.exports),n})}return Pt=t(),Pt}function It(e){return t=>WebAssembly.instantiate(e,t)}function Lt(e){return t=>WebAssembly.instantiateStreaming(e,t)}function Rt(e){return async t=>{let n=await e.arrayBuffer();return WebAssembly.instantiate(n,t)}}var zt;function Bt(e){zt=e}function Vt(){return zt}async function Ht(e){return e&&await Ft(e),{createScanner(e){return new Ot(e.map(e=>typeof e==`string`?e:e.source))},createString(e){return new Dt(e)}}}var Ut=rt({});at(Ut,mt);var Wt=class extends Error{constructor(e){super(e),this.name=`ShikiError`}},Gt=class extends Error{constructor(e){super(e),this.name=`ShikiError`}};function Kt(e){return qt(e)}function qt(e){return Array.isArray(e)?Jt(e):e instanceof RegExp?e:typeof e==`object`?Yt(e):e}function Jt(e){let t=[];for(let n=0,r=e.length;n<r;n++)t[n]=qt(e[n]);return t}function Yt(e){let t={};for(let n in e)t[n]=qt(e[n]);return t}function Xt(e,...t){return t.forEach(t=>{for(let n in t)e[n]=t[n]}),e}function Zt(e){let t=~e.lastIndexOf(`/`)||~e.lastIndexOf(`\\`);return t===0?e:~t===e.length-1?Zt(e.substring(0,e.length-1)):e.substr(~t+1)}var Qt=/\$(\d+)|\${(\d+):\/(downcase|upcase)}/g,$t=class{static hasCaptures(e){return e!==null&&(Qt.lastIndex=0,Qt.test(e))}static replaceCaptures(e,t,n){return e.replace(Qt,(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 en(e,t){return e<t?-1:+(e>t)}function tn(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=en(e[r],t[r]);if(n!==0)return n}return 0}return n-r}function nn(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 rn(e){return e.replace(/[\-\\\{\}\*\+\?\|\^\$\.\,\[\]\(\)\#\s]/g,`\\$&`)}var an=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}},on=class{constructor(e,t,n){this._colorMap=e,this._defaults=t,this._root=n}static createFromRawTheme(e,t){return this.createFromParsedTheme(dn(e),t)}static createFromParsedTheme(e,t){return mn(e,t)}_cachedMatchRoot=new an(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=>cn(e.parent,t.parentScopes));return n?new un(n.fontStyle,n.foreground,n.background):null}},sn=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||this.parent!==null&&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 cn(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&&!ln(e.scopeName,r);){if(i)return!1;e=e.parent}if(!e)return!1;e=e.parent}return!0}function ln(e,t){return t===e||e.startsWith(t)&&e[t.length]===`.`}var un=class{constructor(e,t,n){this.fontStyle=e,this.foregroundId=t,this.backgroundId=n}};function dn(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}}let s=null;typeof i.settings.foreground==`string`&&nn(i.settings.foreground)&&(s=i.settings.foreground);let c=null;typeof i.settings.background==`string`&&nn(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 fn(l,u,e,o,s,c)}}return n}var fn=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}},pn=(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))(pn||{});function mn(e,t){e.sort((e,t)=>{let n=en(e.scope,t.scope);return n!==0||(n=tn(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 hn(t),o=new un(n,a.getId(r),a.getId(i)),s=new vn(new _n(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 on(a,o,s)}var hn=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)}},gn=Object.freeze([]),_n=class e{scopeDepth;parentScopes;fontStyle;foreground;background;constructor(e,t,n,r,i){this.scopeDepth=e,this.parentScopes=t||gn,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)}},vn=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(),_n.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(tn(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 _n(e,t,n,r,i))}},yn=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)}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=xn(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 bn(e){return e}function xn(e){return e}function Sn(e,t){let n=[],r=wn(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(Cn(i)){let e=[];do e.push(i),i=r.next();while(Cn(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 Cn(e){return!!e&&!!e.match(/[\w\.:]+/)}function wn(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 Tn(e){typeof e.dispose==`function`&&e.dispose()}var En=class{constructor(e){this.scopeName=e}toKey(){return this.scopeName}},Dn=class{constructor(e,t){this.scopeName=e,this.ruleName=t}toKey(){return`${this.scopeName}#${this.ruleName}`}},On=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))}},kn=class{constructor(e,t){this.repo=e,this.initialScopeName=t,this.seenFullScopeRequests.add(this.initialScopeName),this.Q=[new En(this.initialScopeName)]}seenFullScopeRequests=new Set;seenPartialScopeRequests=new Set;Q;processQueue(){let e=this.Q;this.Q=[];let t=new On;for(let n of e)An(n,this.initialScopeName,this.repo,t);for(let e of t.references)if(e instanceof En){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 An(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 En?Mn({baseGrammar:a,selfGrammar:i},r):jn(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 En(e))}function jn(e,t,n){if(t.repository&&t.repository[e]){let r=t.repository[e];Nn([r],t,n)}}function Mn(e,t){e.selfGrammar.patterns&&Array.isArray(e.selfGrammar.patterns)&&Nn(e.selfGrammar.patterns,{...e,repository:e.selfGrammar.repository},t),e.selfGrammar.injections&&Nn(Object.values(e.selfGrammar.injections),{...e,repository:e.selfGrammar.repository},t)}function Nn(e,t,n){for(let r of e){if(n.visitedRule.has(r))continue;n.visitedRule.add(r);let e=r.repository?Xt({},t.repository,r.repository):t.repository;Array.isArray(r.patterns)&&Nn(r.patterns,{...t,repository:e},n);let i=r.include;if(!i)continue;let a=zn(i);switch(a.kind){case 0:Mn({...t,selfGrammar:t.baseGrammar},n);break;case 1:Mn(t,n);break;case 2:jn(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?jn(a.ruleName,i,n):Mn(i,n)}else a.kind===4?n.add(new Dn(a.scopeName,a.ruleName)):n.add(new En(a.scopeName))}}}var Pn=class{kind=0},Fn=class{kind=1},In=class{constructor(e){this.ruleName=e}kind=2},Ln=class{constructor(e){this.scopeName=e}kind=3},Rn=class{constructor(e,t){this.scopeName=e,this.ruleName=t}kind=4};function zn(e){if(e===`$base`)return new Pn;if(e===`$self`)return new Fn;let t=e.indexOf(`#`);return t===-1?new Ln(e):t===0?new In(e.substring(1)):new Rn(e.substring(0,t),e.substring(t+1))}var Bn=/\\(\d+)/,Vn=/\\(\d+)/g,Hn=-1,Un=-2;function Wn(e){return e}function Gn(e){return e}var Kn=class{$location;id;_nameIsCapturing;_name;_contentNameIsCapturing;_contentName;constructor(e,t,n,r){this.$location=e,this.id=t,this._name=n||null,this._nameIsCapturing=$t.hasCaptures(this._name),this._contentName=r||null,this._contentNameIsCapturing=$t.hasCaptures(this._contentName)}get debugName(){let e=this.$location?`${Zt(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:$t.replaceCaptures(this._name,e,t)}getContentName(e,t){return!this._contentNameIsCapturing||this._contentName===null?this._contentName:$t.replaceCaptures(this._contentName,e,t)}},qn=class extends Kn{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!`)}},Jn=class extends Kn{_match;captures;_cachedCompiledPatterns;constructor(e,t,n,r,i){super(e,t,n,null),this._match=new $n(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 er,this.collectPatterns(e,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},Yn=class extends Kn{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 er,this.collectPatterns(e,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},Xn=class extends Kn{_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 $n(i,this.id),this.beginCaptures=a,this._end=new $n(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 er;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}},Zn=class extends Kn{_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 $n(i,this.id),this.beginCaptures=a,this.whileCaptures=s,this._while=new $n(o,Un),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 er;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 er,this._cachedCompiledWhilePatterns.push(this._while.hasBackReferences?this._while.clone():this._while)),this._while.hasBackReferences&&this._cachedCompiledWhilePatterns.setSource(0,t||``),this._cachedCompiledWhilePatterns}},Qn=class e{static createCaptureRule(e,t,n,r,i){return e.registerRule(e=>new qn(t,e,n,r,i))}static getCompiledRuleId(t,n,r){return t.id||n.registerRule(i=>{if(t.id=i,t.match)return new Jn(t.$vscodeTextmateLocation,t.id,t.name,t.match,e._compileCaptures(t.captures,n,r));if(t.begin===void 0){t.repository&&(r=Xt({},r,t.repository));let i=t.patterns;return i===void 0&&t.include&&(i=[{include:t.include}]),new Yn(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,e._compilePatterns(i,n,r))}return t.while?new Zn(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 Xn(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=zn(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)}}}else s=e.getCompiledRuleId(o,n,r);if(s!==-1){let e=n.getRule(s),t=!1;if((e instanceof Yn||e instanceof Xn||e instanceof Zn)&&e.hasMissingPatterns&&e.patterns.length===0&&(t=!0),t)continue;i.push(s)}}return{patterns:i,hasMissingPatterns:(t?t.length:0)!==i.length}}},$n=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._anchorCache=this.hasAnchor?this._buildAnchorCache():null,this.ruleId=t,this.hasBackReferences=typeof this.source==`string`&&Bn.test(this.source)}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 Vn.lastIndex=0,this.source.replace(Vn,(e,t)=>rn(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}},er=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 tr(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 tr(e,this._items.map(e=>e.resolveAnchors(t,n)),this._items.map(e=>e.ruleId))}},tr=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(`
|
|
10
|
+
`).replace(Pd,``)}function Id(e,t){return t=Fd(t),Fd(e)===t}function Y(e,t,n,r,a,o){switch(n){case`children`:typeof r==`string`?t===`body`||t===`textarea`&&r===``||Zt(e,r):(typeof r==`number`||typeof r==`bigint`)&&t!==`body`&&Zt(e,``+r);break;case`className`:Ft(e,`class`,r);break;case`tabIndex`:Ft(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:Ft(e,n,r);break;case`style`:en(e,r,o);break;case`data`:if(t!==`object`){Ft(e,`data`,r);break}case`src`:case`href`:if(r===``&&(t!==`a`||n!==`href`)){e.removeAttribute(n);break}if(r==null||typeof r==`function`||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=an(``+r),e.setAttribute(n,r);break;case`action`:case`formAction`:if(typeof r==`function`){e.setAttribute(n,`javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')`);break}if(typeof o==`function`&&(n===`formAction`?(t!==`input`&&Y(e,t,`name`,a.name,a,null),Y(e,t,`formEncType`,a.formEncType,a,null),Y(e,t,`formMethod`,a.formMethod,a,null),Y(e,t,`formTarget`,a.formTarget,a,null)):(Y(e,t,`encType`,a.encType,a,null),Y(e,t,`method`,a.method,a,null),Y(e,t,`target`,a.target,a,null))),r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=an(``+r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=on);break;case`onScroll`:r!=null&&J(`scroll`,e);break;case`onScrollEnd`:r!=null&&J(`scrollend`,e);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`multiple`:e.multiple=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`muted`:e.muted=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`defaultValue`:case`defaultChecked`:case`innerHTML`:case`ref`:break;case`autoFocus`:break;case`xlinkHref`:if(r==null||typeof r==`function`||typeof r==`boolean`||typeof r==`symbol`){e.removeAttribute(`xlink:href`);break}n=an(``+r),e.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,n);break;case`contentEditable`:case`spellCheck`:case`draggable`:case`value`:case`autoReverse`:case`externalResourcesRequired`:case`focusable`:case`preserveAlpha`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``+r):e.removeAttribute(n);break;case`inert`:case`allowFullScreen`:case`async`:case`autoPlay`:case`controls`:case`default`:case`defer`:case`disabled`:case`disablePictureInPicture`:case`disableRemotePlayback`:case`formNoValidate`:case`hidden`:case`loop`:case`noModule`:case`noValidate`:case`open`:case`playsInline`:case`readOnly`:case`required`:case`reversed`:case`scoped`:case`seamless`:case`itemScope`:r&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``):e.removeAttribute(n);break;case`capture`:case`download`:!0===r?e.setAttribute(n,``):!1!==r&&r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`cols`:case`rows`:case`size`:case`span`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case`rowSpan`:case`start`:r==null||typeof r==`function`||typeof r==`symbol`||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case`popover`:J(`beforetoggle`,e),J(`toggle`,e),Pt(e,`popover`,r);break;case`xlinkActuate`:It(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:It(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:It(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:It(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:It(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:It(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:It(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:It(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:It(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:Pt(e,`is`,r);break;case`innerText`:case`textContent`:break;default:(!(2<n.length)||n[0]!==`o`&&n[0]!==`O`||n[1]!==`n`&&n[1]!==`N`)&&(n=nn.get(n)||n,Pt(e,n,r))}}function Ld(e,t,n,r,a,o){switch(n){case`style`:en(e,r,o);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`children`:typeof r==`string`?Zt(e,r):(typeof r==`number`||typeof r==`bigint`)&&Zt(e,``+r);break;case`onScroll`:r!=null&&J(`scroll`,e);break;case`onScrollEnd`:r!=null&&J(`scrollend`,e);break;case`onClick`:r!=null&&(e.onclick=on);break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:break;case`innerText`:case`textContent`:break;default:if(!Dt.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(a=n.endsWith(`Capture`),t=n.slice(2,a?n.length-7:void 0),o=e[pt]||null,o=o==null?null:o[n],typeof o==`function`&&e.removeEventListener(t,o,a),typeof r==`function`)){typeof o!=`function`&&o!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,a);break a}n in e?e[n]=r:!0===r?e.setAttribute(n,``):Pt(e,n,r)}}}function Rd(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:J(`error`,e),J(`load`,e);var r=!1,a=!1,o;for(o in n)if(n.hasOwnProperty(o)){var s=n[o];if(s!=null)switch(o){case`src`:r=!0;break;case`srcSet`:a=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:Y(e,t,o,s,n,null)}}a&&Y(e,t,`srcSet`,n.srcSet,n,null),r&&Y(e,t,`src`,n.src,n,null);return;case`input`:J(`invalid`,e);var c=o=s=a=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:a=d;break;case`type`:s=d;break;case`checked`:l=d;break;case`defaultChecked`:u=d;break;case`value`:o=d;break;case`defaultValue`:c=d;break;case`children`:case`dangerouslySetInnerHTML`:if(d!=null)throw Error(i(137,t));break;default:Y(e,t,r,d,n,null)}}Kt(e,o,c,l,u,s,a,!1);return;case`select`:for(a in J(`invalid`,e),r=s=o=null,n)if(n.hasOwnProperty(a)&&(c=n[a],c!=null))switch(a){case`value`:o=c;break;case`defaultValue`:s=c;break;case`multiple`:r=c;default:Y(e,t,a,c,n,null)}t=o,n=s,e.multiple=!!r,t==null?n!=null&&Jt(e,!!r,n,!0):Jt(e,!!r,t,!1);return;case`textarea`:for(s in J(`invalid`,e),o=a=r=null,n)if(n.hasOwnProperty(s)&&(c=n[s],c!=null))switch(s){case`value`:r=c;break;case`defaultValue`:a=c;break;case`children`:o=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(i(91));break;default:Y(e,t,s,c,n,null)}Xt(e,r,a,o);return;case`option`:for(l in n)if(n.hasOwnProperty(l)&&(r=n[l],r!=null))switch(l){case`selected`:e.selected=r&&typeof r!=`function`&&typeof r!=`symbol`;break;default:Y(e,t,l,r,n,null)}return;case`dialog`:J(`beforetoggle`,e),J(`toggle`,e),J(`cancel`,e),J(`close`,e);break;case`iframe`:case`object`:J(`load`,e);break;case`video`:case`audio`:for(r=0;r<Sd.length;r++)J(Sd[r],e);break;case`image`:J(`error`,e),J(`load`,e);break;case`details`:J(`toggle`,e);break;case`embed`:case`source`:case`link`:J(`error`,e),J(`load`,e);case`area`:case`base`:case`br`:case`col`:case`hr`:case`keygen`:case`meta`:case`param`:case`track`:case`wbr`:case`menuitem`:for(u in n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:Y(e,t,u,r,n,null)}return;default:if(tn(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Ld(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&Y(e,t,c,r,n,null))}function zd(e,t,n,r){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`input`:var a=null,o=null,s=null,c=null,l=null,u=null,d=null;for(m in n){var f=n[m];if(n.hasOwnProperty(m)&&f!=null)switch(m){case`checked`:break;case`value`:break;case`defaultValue`:l=f;default:r.hasOwnProperty(m)||Y(e,t,m,null,r,f)}}for(var p in r){var m=r[p];if(f=n[p],r.hasOwnProperty(p)&&(m!=null||f!=null))switch(p){case`type`:o=m;break;case`name`:a=m;break;case`checked`:u=m;break;case`defaultChecked`:d=m;break;case`value`:s=m;break;case`defaultValue`:c=m;break;case`children`:case`dangerouslySetInnerHTML`:if(m!=null)throw Error(i(137,t));break;default:m!==f&&Y(e,t,p,m,r,f)}}Gt(e,s,c,l,u,d,o,a);return;case`select`:for(o in m=s=c=p=null,n)if(l=n[o],n.hasOwnProperty(o)&&l!=null)switch(o){case`value`:break;case`multiple`:m=l;default:r.hasOwnProperty(o)||Y(e,t,o,null,r,l)}for(a in r)if(o=r[a],l=n[a],r.hasOwnProperty(a)&&(o!=null||l!=null))switch(a){case`value`:p=o;break;case`defaultValue`:c=o;break;case`multiple`:s=o;default:o!==l&&Y(e,t,a,o,r,l)}t=c,n=s,r=m,p==null?!!r!=!!n&&(t==null?Jt(e,!!n,n?[]:``,!1):Jt(e,!!n,t,!0)):Jt(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(a=n[c],n.hasOwnProperty(c)&&a!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:Y(e,t,c,null,r,a)}for(s in r)if(a=r[s],o=n[s],r.hasOwnProperty(s)&&(a!=null||o!=null))switch(s){case`value`:p=a;break;case`defaultValue`:m=a;break;case`children`:break;case`dangerouslySetInnerHTML`:if(a!=null)throw Error(i(91));break;default:a!==o&&Y(e,t,s,a,r,o)}Yt(e,p,m);return;case`option`:for(var h in n)if(p=n[h],n.hasOwnProperty(h)&&p!=null&&!r.hasOwnProperty(h))switch(h){case`selected`:e.selected=!1;break;default:Y(e,t,h,null,r,p)}for(l in r)if(p=r[l],m=n[l],r.hasOwnProperty(l)&&p!==m&&(p!=null||m!=null))switch(l){case`selected`:e.selected=p&&typeof p!=`function`&&typeof p!=`symbol`;break;default:Y(e,t,l,p,r,m)}return;case`img`:case`link`:case`area`:case`base`:case`br`:case`col`:case`embed`:case`hr`:case`keygen`:case`meta`:case`param`:case`source`:case`track`:case`wbr`:case`menuitem`:for(var g in n)p=n[g],n.hasOwnProperty(g)&&p!=null&&!r.hasOwnProperty(g)&&Y(e,t,g,null,r,p);for(u in r)if(p=r[u],m=n[u],r.hasOwnProperty(u)&&p!==m&&(p!=null||m!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:if(p!=null)throw Error(i(137,t));break;default:Y(e,t,u,p,r,m)}return;default:if(tn(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&Ld(e,t,_,void 0,r,p);for(d in r)p=r[d],m=n[d],!r.hasOwnProperty(d)||p===m||p===void 0&&m===void 0||Ld(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&Y(e,t,v,null,r,p);for(f in r)p=r[f],m=n[f],!r.hasOwnProperty(f)||p===m||p==null&&m==null||Y(e,t,f,p,r,m)}function Bd(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Vd(){if(typeof performance.getEntriesByType==`function`){for(var e=0,t=0,n=performance.getEntriesByType(`resource`),r=0;r<n.length;r++){var i=n[r],a=i.transferSize,o=i.initiatorType,s=i.duration;if(a&&s&&Bd(o)){for(o=0,s=i.responseEnd,r+=1;r<n.length;r++){var c=n[r],l=c.startTime;if(l>s)break;var u=c.transferSize,d=c.initiatorType;u&&Bd(d)&&(c=c.responseEnd,o+=u*(c<s?1:(s-l)/(c-l)))}if(--r,t+=8*(a+o)/(i.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e==`number`)?e:5}var Hd=null,Ud=null;function Wd(e){return e.nodeType===9?e:e.ownerDocument}function Gd(e){switch(e){case`http://www.w3.org/2000/svg`:return 1;case`http://www.w3.org/1998/Math/MathML`:return 2;default:return 0}}function Kd(e,t){if(e===0)switch(t){case`svg`:return 1;case`math`:return 2;default:return 0}return e===1&&t===`foreignObject`?0:e}function qd(e,t){return e===`textarea`||e===`noscript`||typeof t.children==`string`||typeof t.children==`number`||typeof t.children==`bigint`||typeof t.dangerouslySetInnerHTML==`object`&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Jd=null;function Yd(){var e=window.event;return e&&e.type===`popstate`?e!==Jd&&(Jd=e,!0):(Jd=null,!1)}var Xd=typeof setTimeout==`function`?setTimeout:void 0,Zd=typeof clearTimeout==`function`?clearTimeout:void 0,Qd=typeof Promise==`function`?Promise:void 0,$d=typeof queueMicrotask==`function`?queueMicrotask:Qd===void 0?Xd:function(e){return Qd.resolve(null).then(e).catch(ef)};function ef(e){setTimeout(function(){throw e})}function tf(e){return e===`head`}function nf(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8){if(n=i.data,n===`/$`||n===`/&`){if(r===0){e.removeChild(i),Lp(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)_f(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,_f(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[yt]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&_f(e.ownerDocument.body)}n=i}while(n);Lp(t)}function rf(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display=`none`):(n.style.display=n._stashedDisplay||``,n.getAttribute(`style`)===``&&n.removeAttribute(`style`)):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=``):n.nodeValue=n._stashedText||``),r&&r.nodeType===8){if(n=r.data,n===`/$`){if(e===0)break;e--}else n!==`$`&&n!==`$?`&&n!==`$~`&&n!==`$!`||e++}n=r}while(n)}function af(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case`HTML`:case`HEAD`:case`BODY`:af(n),bt(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function of(e,t,n,r){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!==`INPUT`||e.type!==`hidden`))break}else if(!r){if(t===`input`&&e.type===`hidden`){var a=i.name==null?null:``+i.name;if(i.type===`hidden`&&e.getAttribute(`name`)===a)return e}else return e}else if(!e[yt])switch(t){case`meta`:if(!e.hasAttribute(`itemprop`))break;return e;case`link`:if(a=e.getAttribute(`rel`),a===`stylesheet`&&e.hasAttribute(`data-precedence`)||a!==i.rel||e.getAttribute(`href`)!==(i.href==null||i.href===``?null:i.href)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute(`title`)!==(i.title==null?null:i.title))break;return e;case`style`:if(e.hasAttribute(`data-precedence`))break;return e;case`script`:if(a=e.getAttribute(`src`),(a!==(i.src==null?null:i.src)||e.getAttribute(`type`)!==(i.type==null?null:i.type)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin))&&a&&e.hasAttribute(`async`)&&!e.hasAttribute(`itemprop`))break;return e;default:return e}if(e=ff(e.nextSibling),e===null)break}return null}function sf(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=ff(e.nextSibling),e===null))return null;return e}function cf(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=ff(e.nextSibling),e===null))return null;return e}function lf(e){return e.data===`$?`||e.data===`$~`}function uf(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function df(e,t){var n=e.ownerDocument;if(e.data===`$~`)e._reactRetry=t;else if(e.data!==`$?`||n.readyState!==`loading`)t();else{var r=function(){t(),n.removeEventListener(`DOMContentLoaded`,r)};n.addEventListener(`DOMContentLoaded`,r),e._reactRetry=r}}function ff(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t===`$`||t===`$!`||t===`$?`||t===`$~`||t===`&`||t===`F!`||t===`F`)break;if(t===`/$`||t===`/&`)return null}}return e}var pf=null;function mf(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return ff(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function hf(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`$`||n===`$!`||n===`$?`||n===`$~`||n===`&`){if(t===0)return e;t--}else n!==`/$`&&n!==`/&`||t++}e=e.previousSibling}return null}function gf(e,t,n){switch(t=Wd(n),e){case`html`:if(e=t.documentElement,!e)throw Error(i(452));return e;case`head`:if(e=t.head,!e)throw Error(i(453));return e;case`body`:if(e=t.body,!e)throw Error(i(454));return e;default:throw Error(i(451))}}function _f(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);bt(e)}var vf=new Map,yf=new Set;function bf(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var xf=A.d;A.d={f:Sf,r:Cf,D:Ef,C:Df,L:Of,m:kf,X:jf,S:Af,M:Mf};function Sf(){var e=xf.f(),t=Tu();return e||t}function Cf(e){var t=St(e);t!==null&&t.tag===5&&t.type===`form`?As(t):xf.r(e)}var wf=typeof document>`u`?null:document;function Tf(e,t,n){var r=wf;if(r&&typeof t==`string`&&t){var i=Wt(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),yf.has(i)||(yf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Rd(t,`link`,e),Tt(t),r.head.appendChild(t)))}}function Ef(e){xf.D(e),Tf(`dns-prefetch`,e,null)}function Df(e,t){xf.C(e,t),Tf(`preconnect`,e,t)}function Of(e,t,n){xf.L(e,t,n);var r=wf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Wt(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Wt(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Wt(n.imageSizes)+`"]`)):i+=`[href="`+Wt(e)+`"]`;var a=i;switch(t){case`style`:a=Pf(e);break;case`script`:a=Rf(e)}vf.has(a)||(e=m({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),vf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(Ff(a))||t===`script`&&r.querySelector(zf(a))||(t=r.createElement(`link`),Rd(t,`link`,e),Tt(t),r.head.appendChild(t)))}}function kf(e,t){xf.m(e,t);var n=wf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Wt(r)+`"][href="`+Wt(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Rf(e)}if(!vf.has(a)&&(e=m({rel:`modulepreload`,href:e},t),vf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(zf(a)))return}r=n.createElement(`link`),Rd(r,`link`,e),Tt(r),n.head.appendChild(r)}}}function Af(e,t,n){xf.S(e,t,n);var r=wf;if(r&&e){var i=wt(r).hoistableStyles,a=Pf(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(Ff(a)))s.loading=5;else{e=m({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=vf.get(a))&&Hf(e,n);var c=o=r.createElement(`link`);Tt(c),Rd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Vf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function jf(e,t){xf.X(e,t);var n=wf;if(n&&e){var r=wt(n).hoistableScripts,i=Rf(e),a=r.get(i);a||(a=n.querySelector(zf(i)),a||(e=m({src:e,async:!0},t),(t=vf.get(i))&&Uf(e,t),a=n.createElement(`script`),Tt(a),Rd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Mf(e,t){xf.M(e,t);var n=wf;if(n&&e){var r=wt(n).hoistableScripts,i=Rf(e),a=r.get(i);a||(a=n.querySelector(zf(i)),a||(e=m({src:e,async:!0,type:`module`},t),(t=vf.get(i))&&Uf(e,t),a=n.createElement(`script`),Tt(a),Rd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Nf(e,t,n,r){var a=(a=me.current)?bf(a):null;if(!a)throw Error(i(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Pf(n.href),n=wt(a).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Pf(n.href);var o=wt(a).hoistableStyles,s=o.get(e);if(s||(a=a.ownerDocument||a,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=a.querySelector(Ff(e)))&&!o._p&&(s.instance=o,s.state.loading=5),vf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},vf.set(e,n),o||Lf(a,e,n,s.state))),t&&r===null)throw Error(i(528,``));return s}if(t&&r!==null)throw Error(i(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Rf(n),n=wt(a).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(i(444,e))}}function Pf(e){return`href="`+Wt(e)+`"`}function Ff(e){return`link[rel="stylesheet"][`+e+`]`}function If(e){return m({},e,{"data-precedence":e.precedence,precedence:null})}function Lf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Rd(t,`link`,n),Tt(t),e.head.appendChild(t))}function Rf(e){return`[src="`+Wt(e)+`"]`}function zf(e){return`script[async]`+e}function Bf(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Wt(n.href)+`"]`);if(r)return t.instance=r,Tt(r),r;var a=m({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),Tt(r),Rd(r,`style`,a),Vf(r,n.precedence,e),t.instance=r;case`stylesheet`:a=Pf(n.href);var o=e.querySelector(Ff(a));if(o)return t.state.loading|=4,t.instance=o,Tt(o),o;r=If(n),(a=vf.get(a))&&Hf(r,a),o=(e.ownerDocument||e).createElement(`link`),Tt(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Rd(o,`link`,r),t.state.loading|=4,Vf(o,n.precedence,e),t.instance=o;case`script`:return o=Rf(n.src),(a=e.querySelector(zf(o)))?(t.instance=a,Tt(a),a):(r=n,(a=vf.get(o))&&(r=m({},n),Uf(r,a)),e=e.ownerDocument||e,a=e.createElement(`script`),Tt(a),Rd(a,`link`,r),e.head.appendChild(a),t.instance=a);case`void`:return null;default:throw Error(i(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Vf(r,n.precedence,e));return t.instance}function Vf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o<r.length;o++){var s=r[o];if(s.dataset.precedence===t)a=s;else if(a!==i)break}a?a.parentNode.insertBefore(e,a.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Hf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function Uf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var Wf=null;function Gf(e,t,n){if(Wf===null){var r=new Map,i=Wf=new Map;i.set(n,r)}else i=Wf,r=i.get(n),r||(r=new Map,i.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),i=0;i<n.length;i++){var a=n[i];if(!(a[yt]||a[ft]||e===`link`&&a.getAttribute(`rel`)===`stylesheet`)&&a.namespaceURI!==`http://www.w3.org/2000/svg`){var o=a.getAttribute(t)||``;o=e+o;var s=r.get(o);s?s.push(a):r.set(o,[a])}}return r}function Kf(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function qf(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function Jf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Yf(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Pf(r.href),a=t.querySelector(Ff(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=Qf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,Tt(a);return}a=t.ownerDocument||t,r=If(r),(i=vf.get(i))&&Hf(r,i),a=a.createElement(`link`),Tt(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Rd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=Qf.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var Xf=0;function Zf(e,t){return e.stylesheets&&e.count===0&&ep(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&ep(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&Xf===0&&(Xf=62500*Vd());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&ep(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>Xf?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function Qf(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)ep(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var $f=null;function ep(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,$f=new Map,t.forEach(tp,e),$f=null,Qf.call(e))}function tp(e,t){if(!(t.state.loading&4)){var n=$f.get(e);if(n)var r=n.get(null);else{n=new Map,$f.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a<i.length;a++){var o=i[a];(o.nodeName===`LINK`||o.getAttribute(`media`)!==`not all`)&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}i=t.instance,o=i.getAttribute(`data-precedence`),a=n.get(o)||r,a===r&&n.set(null,i),n.set(o,i),this.count++,r=Qf.bind(this),i.addEventListener(`load`,r),i.addEventListener(`error`,r),a?a.parentNode.insertBefore(i,a.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}var np={$$typeof:C,Provider:null,Consumer:null,_currentValue:se,_currentValue2:se,_threadCount:0};function rp(e,t,n,r,i,a,o,s,c){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=nt(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=nt(0),this.hiddenUpdates=nt(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.incompleteTransitions=new Map}function ip(e,t,n,r,i,a,o,s,c,l,u,d){return e=new rp(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=mi(3,null,null,t),e.current=a,a.stateNode=e,t=ua(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},Ua(a),e}function ap(e){return e?(e=fi,e):fi}function op(e,t,n,r,i,a){i=ap(i),r.context===null?r.context=i:r.pendingContext=i,r=Ga(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=Ka(e,r,t),n!==null&&(bu(n,e,t),qa(n,e,t))}function sp(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function cp(e,t){sp(e,t),(e=e.alternate)&&sp(e,t)}function lp(e){if(e.tag===13||e.tag===31){var t=li(e,67108864);t!==null&&bu(t,e,67108864),cp(e,67108864)}}function up(e){if(e.tag===13||e.tag===31){var t=vu();t=ct(t);var n=li(e,t);n!==null&&bu(n,e,t),cp(e,t)}}var dp=!0;function fp(e,t,n,r){var i=k.T;k.T=null;var a=A.p;try{A.p=2,mp(e,t,n,r)}finally{A.p=a,k.T=i}}function pp(e,t,n,r){var i=k.T;k.T=null;var a=A.p;try{A.p=8,mp(e,t,n,r)}finally{A.p=a,k.T=i}}function mp(e,t,n,r){if(dp){var i=hp(r);if(i===null)Od(e,t,r,gp,n),Dp(e,r);else if(kp(i,e,t,n,r))r.stopPropagation();else if(Dp(e,r),t&4&&-1<Ep.indexOf(e)){for(;i!==null;){var a=St(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=Ze(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-We(o);s.entanglements[1]|=c,o&=~c}cd(a),!(V&6)&&(ou=Me()+500,ld(0,!1))}}break;case 31:case 13:s=li(a,2),s!==null&&bu(s,a,2),Tu(),cp(a,2)}if(a=hp(r),a===null&&Od(e,t,r,gp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Od(e,t,r,null,n)}}function hp(e){return e=cn(e),_p(e)}var gp=null;function _p(e){if(gp=null,e=xt(e),e!==null){var t=o(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=s(t),e!==null)return e;e=null}else if(n===31){if(e=c(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return gp=e,null}function vp(e){switch(e){case`beforetoggle`:case`cancel`:case`click`:case`close`:case`contextmenu`:case`copy`:case`cut`:case`auxclick`:case`dblclick`:case`dragend`:case`dragstart`:case`drop`:case`focusin`:case`focusout`:case`input`:case`invalid`:case`keydown`:case`keypress`:case`keyup`:case`mousedown`:case`mouseup`:case`paste`:case`pause`:case`play`:case`pointercancel`:case`pointerdown`:case`pointerup`:case`ratechange`:case`reset`:case`resize`:case`seeked`:case`submit`:case`toggle`:case`touchcancel`:case`touchend`:case`touchstart`:case`volumechange`:case`change`:case`selectionchange`:case`textInput`:case`compositionstart`:case`compositionend`:case`compositionupdate`:case`beforeblur`:case`afterblur`:case`beforeinput`:case`blur`:case`fullscreenchange`:case`focus`:case`hashchange`:case`popstate`:case`select`:case`selectstart`:return 2;case`drag`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`mousemove`:case`mouseout`:case`mouseover`:case`pointermove`:case`pointerout`:case`pointerover`:case`scroll`:case`touchmove`:case`wheel`:case`mouseenter`:case`mouseleave`:case`pointerenter`:case`pointerleave`:return 8;case`message`:switch(Ne()){case Pe:return 2;case Fe:return 8;case Ie:case Le:return 32;case Re:return 268435456;default:return 32}default:return 32}}var yp=!1,bp=null,xp=null,Sp=null,Cp=new Map,wp=new Map,Tp=[],Ep=`mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset`.split(` `);function Dp(e,t){switch(e){case`focusin`:case`focusout`:bp=null;break;case`dragenter`:case`dragleave`:xp=null;break;case`mouseover`:case`mouseout`:Sp=null;break;case`pointerover`:case`pointerout`:Cp.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:wp.delete(t.pointerId)}}function Op(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=St(t),t!==null&&lp(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function kp(e,t,n,r,i){switch(t){case`focusin`:return bp=Op(bp,e,t,n,r,i),!0;case`dragenter`:return xp=Op(xp,e,t,n,r,i),!0;case`mouseover`:return Sp=Op(Sp,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return Cp.set(a,Op(Cp.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,wp.set(a,Op(wp.get(a)||null,e,t,n,r,i)),!0}return!1}function Ap(e){var t=xt(e.target);if(t!==null){var n=o(t);if(n!==null){if(t=n.tag,t===13){if(t=s(n),t!==null){e.blockedOn=t,ut(e.priority,function(){up(n)});return}}else if(t===31){if(t=c(n),t!==null){e.blockedOn=t,ut(e.priority,function(){up(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function jp(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=hp(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);sn=r,n.target.dispatchEvent(r),sn=null}else return t=St(n),t!==null&&lp(t),e.blockedOn=n,!1;t.shift()}return!0}function Mp(e,t,n){jp(e)&&n.delete(t)}function Np(){yp=!1,bp!==null&&jp(bp)&&(bp=null),xp!==null&&jp(xp)&&(xp=null),Sp!==null&&jp(Sp)&&(Sp=null),Cp.forEach(Mp),wp.forEach(Mp)}function Pp(e,n){e.blockedOn===n&&(e.blockedOn=null,yp||(yp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,Np)))}var Fp=null;function Ip(e){Fp!==e&&(Fp=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){Fp===e&&(Fp=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],i=e[t+2];if(typeof r!=`function`){if(_p(r||n)===null)continue;break}var a=St(n);a!==null&&(e.splice(t,3),t-=3,Os(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Lp(e){function t(t){return Pp(t,e)}bp!==null&&Pp(bp,e),xp!==null&&Pp(xp,e),Sp!==null&&Pp(Sp,e),Cp.forEach(t),wp.forEach(t);for(var n=0;n<Tp.length;n++){var r=Tp[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<Tp.length&&(n=Tp[0],n.blockedOn===null);)Ap(n),n.blockedOn===null&&Tp.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var i=n[r],a=n[r+1],o=i[pt]||null;if(typeof a==`function`)o||Ip(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[pt]||null)s=o.formAction;else if(_p(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),Ip(n)}}}function Rp(){function e(e){e.canIntercept&&e.info===`react-transition`&&e.intercept({handler:function(){return new Promise(function(e){return i=e})},focusReset:`manual`,scroll:`manual`})}function t(){i!==null&&(i(),i=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&e.url!=null&&navigation.navigate(e.url,{state:e.getState(),info:`react-transition`,history:`replace`})}}if(typeof navigation==`object`){var r=!1,i=null;return navigation.addEventListener(`navigate`,e),navigation.addEventListener(`navigatesuccess`,t),navigation.addEventListener(`navigateerror`,t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener(`navigate`,e),navigation.removeEventListener(`navigatesuccess`,t),navigation.removeEventListener(`navigateerror`,t),i!==null&&(i(),i=null)}}}function zp(e){this._internalRoot=e}Bp.prototype.render=zp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(i(409));var n=t.current;op(n,vu(),e,t,null,null)},Bp.prototype.unmount=zp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;op(e.current,2,null,e,null,null),Tu(),t[mt]=null}};function Bp(e){this._internalRoot=e}Bp.prototype.unstable_scheduleHydration=function(e){if(e){var t=lt();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Tp.length&&t!==0&&t<Tp[n].priority;n++);Tp.splice(n,0,e),n===0&&Ap(e)}};var Vp=n.version;if(Vp!==`19.2.8`)throw Error(i(527,Vp,`19.2.8`));A.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(i(188)):(e=Object.keys(e).join(`,`),Error(i(268,e)));return e=u(t),e=e===null?null:f(e),e=e===null?null:e.stateNode,e};var Hp={bundleType:0,version:`19.2.8`,rendererPackageName:`react-dom`,currentDispatcherRef:k,reconcilerVersion:`19.2.8`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var Up=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Up.isDisabled&&Up.supportsFiber)try{Ve=Up.inject(Hp),He=Up}catch{}}e.createRoot=function(e,t){if(!a(e))throw Error(i(299));var n=!1,r=``,o=Zs,s=Qs,c=$s;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(o=t.onUncaughtError),t.onCaughtError!==void 0&&(s=t.onCaughtError),t.onRecoverableError!==void 0&&(c=t.onRecoverableError)),t=ip(e,1,!1,null,null,n,r,null,o,s,c,Rp),e[mt]=t.current,Ed(e),new zp(t)}})),_=o(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=g()})),v=d(),y=_();function b(e){return e.anchor.kind===`line`}function x(e){return e.anchor.kind===`detached`}function S(e){let t=new Map;for(let n of e){if(!b(n))continue;let e={lineNumber:n.anchor.lineNumber,side:n.anchor.side,metadata:{type:`thread`,thread:n}},r=t.get(n.anchor.fileId);r?r.push(e):t.set(n.anchor.fileId,[e])}return t}function C(e){let t=new Map;for(let n of e)b(n)&&t.set(n.anchor.fileId,(t.get(n.anchor.fileId)??0)+1);return t}function w(e,t,n,r){return!r||n?.fileId!==t?e:[...e,r]}function T(e,t){let n=t.find(t=>t.id===e.fileId);return e.side===`deletions`?n?.oldRepoPath??n?.newRepoPath??e.fileId:n?.newRepoPath??n?.oldRepoPath??e.fileId}function E(e){let t=(0,v.useRef)(e);return(0,v.useInsertionEffect)(()=>void(t.current=e)),(0,v.useCallback)((...e)=>t.current(...e),[])}var ee=o((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.fragment`);function r(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.Fragment=n,e.jsx=r,e.jsxs=r})),D=o(((e,t)=>{t.exports=ee()}))(),O=(0,v.createContext)(void 0);function te(){return(0,v.useContext)(O)}var ne={position:`absolute`,top:0,bottom:0,textAlign:`center`,whiteSpace:`normal`,touchAction:`none`},re={display:`contents`};function ie(){return null}var ae=`diffs-container`,oe=/(?=^From [a-f0-9]+ .+$)/m,k=/(?=^diff --git)/gm,A=/(?<=\n)/,se=/^(---|\+\+\+)\s+([^\t\r\n]+)/,ce=/^(---|\+\+\+)\s+[ab]\/([^\t\r\n]+)/,le=/^diff --git (?:"a\/(.+?)"|a\/(.+?)) (?:"b\/(.+?)"|b\/(.+?))$/,ue=/^index ([0-9a-f]+)\.\.([0-9a-f]+)(?: (\d+))?$/i,de=`header-prefix`,j=`header-filename-suffix`,fe=`header-metadata`,pe=`header-custom`,me={dark:`pierre-dark`,light:`pierre-light`},he=`data-theme-css`,ge=`data-unsafe-css`,_e=`data-diffs-scrollbar-measure`,ve=`--diffs-scrollbar-gutter-measured`,ye=1e5,be={hunkLineCount:50,lineHeight:20,diffHeaderHeight:44,spacing:8};({...be});var xe=Object.freeze({fromStart:0,fromEnd:0}),Se={startingLine:0,totalLines:1/0,bufferBefore:0,bufferAfter:0},Ce={startingLine:0,totalLines:0,bufferBefore:0,bufferAfter:0};function we(e){return`annotation-${`side`in e?`${e.side}-`:``}${e.lineNumber}`}function Te({hunkIndex:e,lineIndex:t,conflictIndex:n}){return`merge-conflict-action-${e}-${t}-${n}`}function Ee(e,t){return e-(t===0?0:1)}function De(e,t){return Ee(e,t)+t}function Oe(e,t){let n=t.hunks[e.hunkIndex];if(n!=null)return{hunkIndex:e.hunkIndex,lineIndex:ke(n,e.startContentIndex)}}function ke(e,t){let n=e.unifiedLineStart;for(let r=0;r<t;r++){let t=e.hunkContent[r];n+=t.type===`context`?t.lines:t.deletions+t.additions}return n}function Ae({fileDiff:e,actions:t,renderCustomHeader:n,renderHeaderPrefix:r,renderHeaderFilenameSuffix:i,renderHeaderMetadata:a,renderAnnotation:o,renderGutterUtility:s,renderMergeConflictUtility:c,lineAnnotations:l,getHoveredLine:u,getInstance:d}){let f=n?.(e),p=r?.(e),m=i?.(e),h=a?.(e);return(0,D.jsxs)(D.Fragment,{children:[f==null?(0,D.jsxs)(D.Fragment,{children:[p!=null&&(0,D.jsx)(`div`,{slot:`header-prefix`,children:p}),m!=null&&(0,D.jsx)(`div`,{slot:`header-filename-suffix`,children:m}),h!=null&&(0,D.jsx)(`div`,{slot:`header-metadata`,children:h})]}):(0,D.jsx)(`div`,{slot:pe,children:f}),o!=null&&l?.map((e,t)=>(0,D.jsx)(`div`,{slot:we(e),children:o(e)},t)),t!=null&&c!=null&&d!=null&&t.map(t=>{if(t==null)return;let n=je(t,e);return(0,D.jsx)(`div`,{slot:n,style:re,children:c(t,d)},n)}),s!=null&&(0,D.jsx)(`div`,{slot:`gutter-utility-slot`,style:ne,children:s(u)})]})}function je(e,t){let n=Oe(e,t);return n==null?void 0:Te({hunkIndex:n.hunkIndex,lineIndex:n.lineIndex,conflictIndex:e.conflictIndex})}function Me(e,t){return e==null||t==null||typeof e==`string`||typeof t==`string`?e===t:e.dark===t.dark&&e.light===t.light}function Ne(e,t){return e?.cacheKey===t?.cacheKey&&e?.contents===t?.contents&&e?.name===t?.name&&e?.lang===t?.lang}var Pe=new Set;function Fe(e){let t=[],n=new Set;for(let r of Ie(e.themes)){let e=ze(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 Fe({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 Fe({themes:t})},registerInto(e){for(let t of r)e.registerThemeIfAbsent(t.name,t.load)}}}function Ie(e){return Le(e)?[e]:e}function Le(e){return ze(e)||Re(e)}function Re(e){return typeof e.name==`string`&&typeof e.load==`function`}function ze(e){return typeof e.getThemes==`function`}function Be(e){return typeof e==`object`&&e&&`default`in e?e.default:e}var Ve=class extends Error{constructor(e){super(`Theme "${e}" is already registered`),this.name=`DuplicateThemeError`}},He=class extends Error{constructor(e){super(`No loader registered for theme "${e}"`),this.name=`UnregisteredThemeError`}},Ue=class extends Error{constructor(e){super(`Theme "${e}" has not been resolved`),this.name=`UnresolvedThemeError`}};function We(){let e=new Map,t=new Map,n=new Map,r=0;function i(t,n){if(e.has(t))throw new Ve(t);e.set(t,n)}function a(t,n){return!e.has(t)&&(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 He(i));let c=r,l=s().then(e=>{let a=Be(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 Ue(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 Ge=We();function Ke(e,t){e=Array.isArray(e)?e:[e];for(let n of e){let e;if(typeof n==`string`){if(e=Ge.getResolvedTheme(n),e==null)throw Error(`loadResolvedThemes: ${n} is not resolved, you must resolve it before calling loadResolvedThemes`)}else e=n,n=n.name,Ge.getResolvedTheme(n)??Ge.seedResolvedTheme(n,e);Pe.has(n)||(Pe.add(n),t.loadThemeSync(e))}}var qe=new Map,Je=new Map,Ye=new Map,Xe=new Set;function Ze(e,t){e=Array.isArray(e)?e:[e];for(let n of e){if(Xe.has(n.name))continue;let e=qe.get(n.name);e??(e=n,qe.set(n.name,e)),Xe.add(e.name),t.loadLanguageSync(e.data)}}function Qe(){return typeof WorkerGlobalScope<`u`&&typeof self<`u`&&self instanceof WorkerGlobalScope}var $e=Object.defineProperty,et=Object.getOwnPropertyDescriptor,tt=Object.getOwnPropertyNames,nt=Object.prototype.hasOwnProperty,rt=(e,t)=>{let n={};for(var r in e)$e(n,r,{get:e[r],enumerable:!0});return t||$e(n,Symbol.toStringTag,{value:`Module`}),n},it=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var i=tt(t),a=0,o=i.length,s;a<o;a++)s=i[a],!nt.call(e,s)&&s!==n&&$e(e,s,{get:(e=>t[e]).bind(null,s),enumerable:!(r=et(t,s))||r.enumerable});return e},at=(e,t,n)=>(it(e,t,`default`),n&&it(n,t,`default`)),ot=`modulepreload`,st=function(e,t){return new URL(e,t).href},ct={},M=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,import.meta.url).href}r=o(t.map(t=>{if(t=st(t,n),t=s(t),t in ct)return;ct[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`:ot,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)})},lt=[{id:`abap`,name:`ABAP`,import:(()=>M(()=>import(`./abap-CLvhMVsD.js`),[],import.meta.url))},{id:`actionscript-3`,name:`ActionScript`,aliases:[`actionscript`,`as3`],import:(()=>M(()=>import(`./actionscript-3-Cs6JJXT5.js`),[],import.meta.url))},{id:`ada`,name:`Ada`,import:(()=>M(()=>import(`./ada-C5qYipkI.js`),[],import.meta.url))},{id:`ahk`,name:`AutoHotkey`,aliases:[`ahk1`],import:(()=>M(()=>import(`./ahk-CA9gdOdF.js`),[],import.meta.url))},{id:`ahk2`,name:`AutoHotkey2`,import:(()=>M(()=>import(`./ahk2-_6rzW9BS.js`),[],import.meta.url))},{id:`angular-html`,name:`Angular HTML`,import:(()=>M(()=>import(`./angular-html-DRzRrsA1.js`).then(e=>e.n),__vite__mapDeps([0,1,2,3]),import.meta.url))},{id:`angular-ts`,name:`Angular TypeScript`,import:(()=>M(()=>import(`./angular-ts-tbivEFEF.js`),__vite__mapDeps([4,0,1,2,3,5]),import.meta.url))},{id:`apache`,name:`Apache Conf`,import:(()=>M(()=>import(`./apache-U0d_L8uA.js`),[],import.meta.url))},{id:`apex`,name:`Apex`,import:(()=>M(()=>import(`./apex-KFGFyKwG.js`),[],import.meta.url))},{id:`apl`,name:`APL`,import:(()=>M(()=>import(`./apl-CY7Wo94D.js`),__vite__mapDeps([6,2,3,1,7,8,9]),import.meta.url))},{id:`applescript`,name:`AppleScript`,import:(()=>M(()=>import(`./applescript-CCn79oCD.js`),[],import.meta.url))},{id:`ara`,name:`Ara`,import:(()=>M(()=>import(`./ara-4CJ0cIlV.js`),[],import.meta.url))},{id:`asciidoc`,name:`AsciiDoc`,aliases:[`adoc`],import:(()=>M(()=>import(`./asciidoc-SCjQUq34.js`),[],import.meta.url))},{id:`asm`,name:`Assembly`,import:(()=>M(()=>import(`./asm-Cmm7eHzH.js`),[],import.meta.url))},{id:`astro`,name:`Astro`,import:(()=>M(()=>import(`./astro-Bx9eET42.js`),__vite__mapDeps([10,2,3,9,11,12,13]),import.meta.url))},{id:`awk`,name:`AWK`,import:(()=>M(()=>import(`./awk-BWXHIvNe.js`),[],import.meta.url))},{id:`ballerina`,name:`Ballerina`,import:(()=>M(()=>import(`./ballerina-B7ZEbQpA.js`),[],import.meta.url))},{id:`bat`,name:`Batch File`,aliases:[`batch`,`cmd`],import:(()=>M(()=>import(`./bat-qdxAdBWQ.js`),[],import.meta.url))},{id:`beancount`,name:`Beancount`,import:(()=>M(()=>import(`./beancount-D-usSTwE.js`),[],import.meta.url))},{id:`berry`,name:`Berry`,aliases:[`be`],import:(()=>M(()=>import(`./berry-DKpUyyne.js`),[],import.meta.url))},{id:`bibtex`,name:`BibTeX`,import:(()=>M(()=>import(`./bibtex-Ci_nEsc7.js`),[],import.meta.url))},{id:`bicep`,name:`Bicep`,import:(()=>M(()=>import(`./bicep-CUHmPFLl.js`),[],import.meta.url))},{id:`bird2`,name:`BIRD2 Configuration`,aliases:[`bird`],import:(()=>M(()=>import(`./bird2-CYIUgYqB.js`),[],import.meta.url))},{id:`blade`,name:`Blade`,import:(()=>M(()=>import(`./blade-MrKrcBds.js`),__vite__mapDeps([14,2,3,1,7,8,9,15,16]),import.meta.url))},{id:`bsl`,name:`1C (Enterprise)`,aliases:[`1c`],import:(()=>M(()=>import(`./bsl-_VjlB9mv.js`),__vite__mapDeps([17,18]),import.meta.url))},{id:`c`,name:`C`,import:(()=>M(()=>import(`./c-C5P-tnLE.js`).then(e=>e.n),[],import.meta.url))},{id:`c3`,name:`C3`,import:(()=>M(()=>import(`./c3-D0apG41V.js`),[],import.meta.url))},{id:`cadence`,name:`Cadence`,aliases:[`cdc`],import:(()=>M(()=>import(`./cadence-CQ2zXKGN.js`),[],import.meta.url))},{id:`cairo`,name:`Cairo`,import:(()=>M(()=>import(`./cairo-DLTphjLi.js`),__vite__mapDeps([19,20]),import.meta.url))},{id:`chapel`,name:`Chapel`,aliases:[`chpl`],import:(()=>M(()=>import(`./chapel-DW9xLN1i.js`),__vite__mapDeps([21,22]),import.meta.url))},{id:`clarity`,name:`Clarity`,import:(()=>M(()=>import(`./clarity-CtfBBspg.js`),[],import.meta.url))},{id:`clojure`,name:`Clojure`,aliases:[`clj`],import:(()=>M(()=>import(`./clojure-DqKBuwfJ.js`),[],import.meta.url))},{id:`cmake`,name:`CMake`,import:(()=>M(()=>import(`./cmake-Bj61d0ZC.js`),[],import.meta.url))},{id:`cobol`,name:`COBOL`,import:(()=>M(()=>import(`./cobol-D5upXK5x.js`),__vite__mapDeps([23,1,2,3,8]),import.meta.url))},{id:`codeowners`,name:`CODEOWNERS`,import:(()=>M(()=>import(`./codeowners-C8r90Shi.js`),[],import.meta.url))},{id:`codeql`,name:`CodeQL`,aliases:[`ql`],import:(()=>M(()=>import(`./codeql-oeQT6MSM.js`),[],import.meta.url))},{id:`coffee`,name:`CoffeeScript`,aliases:[`coffeescript`],import:(()=>M(()=>import(`./coffee-CH-CbdAu.js`),__vite__mapDeps([24,2]),import.meta.url))},{id:`common-lisp`,name:`Common Lisp`,aliases:[`lisp`],import:(()=>M(()=>import(`./common-lisp-Cv5bFMCO.js`),[],import.meta.url))},{id:`coq`,name:`Rocq`,import:(()=>M(()=>import(`./coq-DuBRPxYg.js`),[],import.meta.url))},{id:`cpp`,name:`C++`,aliases:[`c++`],import:(()=>M(()=>import(`./cpp-CYOejM6s.js`).then(e=>e.n),__vite__mapDeps([25,26,27,22]),import.meta.url))},{id:`crystal`,name:`Crystal`,import:(()=>M(()=>import(`./crystal-B1PdqQ4F.js`),__vite__mapDeps([28,2,3,1,16,22,29]),import.meta.url))},{id:`csharp`,name:`C#`,aliases:[`c#`,`cs`],import:(()=>M(()=>import(`./csharp-oqKa8noW.js`),[],import.meta.url))},{id:`css`,name:`CSS`,import:(()=>M(()=>import(`./css-B6kONN6r.js`).then(e=>e.n),[],import.meta.url))},{id:`csv`,name:`CSV`,import:(()=>M(()=>import(`./csv-Dx-8-gkx.js`),[],import.meta.url))},{id:`cue`,name:`CUE`,import:(()=>M(()=>import(`./cue-CE9AQfxI.js`),[],import.meta.url))},{id:`cypher`,name:`Cypher`,aliases:[`cql`],import:(()=>M(()=>import(`./cypher-ClKdZ_lG.js`),[],import.meta.url))},{id:`d`,name:`D`,import:(()=>M(()=>import(`./d-qD-0Kul2.js`),[],import.meta.url))},{id:`dart`,name:`Dart`,import:(()=>M(()=>import(`./dart-CnvKMtbv.js`),[],import.meta.url))},{id:`dax`,name:`DAX`,import:(()=>M(()=>import(`./dax-BkyTk9wS.js`),[],import.meta.url))},{id:`desktop`,name:`Desktop`,import:(()=>M(()=>import(`./desktop-Dlh5hvp9.js`),[],import.meta.url))},{id:`diff`,name:`Diff`,import:(()=>M(()=>import(`./diff-woXpYk--.js`),[],import.meta.url))},{id:`docker`,name:`Dockerfile`,aliases:[`dockerfile`],import:(()=>M(()=>import(`./docker-IyjqRm3v.js`),[],import.meta.url))},{id:`dotenv`,name:`dotEnv`,import:(()=>M(()=>import(`./dotenv-_5a1GRtc.js`),[],import.meta.url))},{id:`dream-maker`,name:`Dream Maker`,import:(()=>M(()=>import(`./dream-maker-DW3nJb8Q.js`),[],import.meta.url))},{id:`edge`,name:`Edge`,import:(()=>M(()=>import(`./edge-DO-0gFMz.js`),__vite__mapDeps([30,1,2,3,11,15]),import.meta.url))},{id:`elixir`,name:`Elixir`,import:(()=>M(()=>import(`./elixir-BIwgFlwP.js`),__vite__mapDeps([31,1,2,3]),import.meta.url))},{id:`elm`,name:`Elm`,import:(()=>M(()=>import(`./elm-Dbo-IffC.js`),__vite__mapDeps([32,27,22]),import.meta.url))},{id:`emacs-lisp`,name:`Emacs Lisp`,aliases:[`elisp`],import:(()=>M(()=>import(`./emacs-lisp-c_oH4hRZ.js`),[],import.meta.url))},{id:`erb`,name:`ERB`,import:(()=>M(()=>import(`./erb-DZ7kUx4Q.js`),__vite__mapDeps([33,1,2,3,34,7,8,16,22,25,26,27,29,35,36,11,13,37,38,39]),import.meta.url))},{id:`erlang`,name:`Erlang`,aliases:[`erl`],import:(()=>M(()=>import(`./erlang-Cphh6RMH.js`),__vite__mapDeps([40,41]),import.meta.url))},{id:`fennel`,name:`Fennel`,import:(()=>M(()=>import(`./fennel-DQxkIbk2.js`),[],import.meta.url))},{id:`fish`,name:`Fish`,import:(()=>M(()=>import(`./fish-BJitypiv.js`),[],import.meta.url))},{id:`fluent`,name:`Fluent`,aliases:[`ftl`],import:(()=>M(()=>import(`./fluent-C03EYrpw.js`),[],import.meta.url))},{id:`fortran-fixed-form`,name:`Fortran (Fixed Form)`,aliases:[`f`,`for`,`f77`],import:(()=>M(()=>import(`./fortran-fixed-form-DEKoE2YW.js`),__vite__mapDeps([42,43]),import.meta.url))},{id:`fortran-free-form`,name:`Fortran (Free Form)`,aliases:[`f90`,`f95`,`f03`,`f08`,`f18`],import:(()=>M(()=>import(`./fortran-free-form-CYNrtFtB.js`),[],import.meta.url))},{id:`fsharp`,name:`F#`,aliases:[`f#`,`fs`],import:(()=>M(()=>import(`./fsharp-D13ZGOAj.js`),__vite__mapDeps([44,41]),import.meta.url))},{id:`gdresource`,name:`GDResource`,aliases:[`tscn`,`tres`],import:(()=>M(()=>import(`./gdresource-xMC7jr7x.js`),__vite__mapDeps([45,46,47]),import.meta.url))},{id:`gdscript`,name:`GDScript`,aliases:[`gd`],import:(()=>M(()=>import(`./gdscript-DYvRD3hg.js`),[],import.meta.url))},{id:`gdshader`,name:`GDShader`,import:(()=>M(()=>import(`./gdshader-CBce3t8t.js`),[],import.meta.url))},{id:`genie`,name:`Genie`,import:(()=>M(()=>import(`./genie-CV2tkWYe.js`),[],import.meta.url))},{id:`gherkin`,name:`Gherkin`,import:(()=>M(()=>import(`./gherkin-DExj1W_8.js`),[],import.meta.url))},{id:`git-commit`,name:`Git Commit Message`,import:(()=>M(()=>import(`./git-commit-BSykSTBG.js`),__vite__mapDeps([48,49]),import.meta.url))},{id:`git-rebase`,name:`Git Rebase Message`,import:(()=>M(()=>import(`./git-rebase-Cf4aQom5.js`),__vite__mapDeps([50,29]),import.meta.url))},{id:`gleam`,name:`Gleam`,import:(()=>M(()=>import(`./gleam-CSRkHgEL.js`),[],import.meta.url))},{id:`glimmer-js`,name:`Glimmer JS`,aliases:[`gjs`],import:(()=>M(()=>import(`./glimmer-js-B8L9c2W6.js`),__vite__mapDeps([51,2,3,1,11]),import.meta.url))},{id:`glimmer-ts`,name:`Glimmer TS`,aliases:[`gts`],import:(()=>M(()=>import(`./glimmer-ts-CzAUKEr_.js`),__vite__mapDeps([52,2,3,1,11]),import.meta.url))},{id:`glsl`,name:`GLSL`,import:(()=>M(()=>import(`./glsl-BZnQq81v.js`).then(e=>e.n),__vite__mapDeps([27,22]),import.meta.url))},{id:`gn`,name:`GN`,import:(()=>M(()=>import(`./gn-ilITqXS6.js`),[],import.meta.url))},{id:`gnuplot`,name:`Gnuplot`,import:(()=>M(()=>import(`./gnuplot-7GGW24-e.js`),[],import.meta.url))},{id:`go`,name:`Go`,import:(()=>M(()=>import(`./go-rLFTqkRN.js`),[],import.meta.url))},{id:`graphql`,name:`GraphQL`,aliases:[`gql`],import:(()=>M(()=>import(`./graphql-QI7m1-dG.js`).then(e=>e.n),__vite__mapDeps([36,2,11,13,37]),import.meta.url))},{id:`groovy`,name:`Groovy`,import:(()=>M(()=>import(`./groovy-CacY0gHj.js`),[],import.meta.url))},{id:`hack`,name:`Hack`,import:(()=>M(()=>import(`./hack-oWgmL-1w.js`),__vite__mapDeps([53,1,2,3,16]),import.meta.url))},{id:`haml`,name:`Ruby Haml`,import:(()=>M(()=>import(`./haml-Dsp05dm-.js`).then(e=>e.n),__vite__mapDeps([35,2,3]),import.meta.url))},{id:`handlebars`,name:`Handlebars`,aliases:[`hbs`],import:(()=>M(()=>import(`./handlebars-DkEP_XDs.js`),__vite__mapDeps([54,2,3,1,39]),import.meta.url))},{id:`haskell`,name:`Haskell`,aliases:[`hs`],import:(()=>M(()=>import(`./haskell-D8IpX4py.js`),[],import.meta.url))},{id:`haxe`,name:`Haxe`,import:(()=>M(()=>import(`./haxe-C8oCnwJJ.js`),[],import.meta.url))},{id:`hcl`,name:`HashiCorp HCL`,import:(()=>M(()=>import(`./hcl-Dh228itO.js`),[],import.meta.url))},{id:`hjson`,name:`Hjson`,import:(()=>M(()=>import(`./hjson-CxZEssPk.js`),[],import.meta.url))},{id:`hlsl`,name:`HLSL`,import:(()=>M(()=>import(`./hlsl-Cvrh5tZx.js`),[],import.meta.url))},{id:`html`,name:`HTML`,import:(()=>M(()=>import(`./html-Jb4Hlhlf.js`).then(e=>e.n),__vite__mapDeps([1,2,3]),import.meta.url))},{id:`html-derivative`,name:`HTML (Derivative)`,import:(()=>M(()=>import(`./html-derivative-jFzowccf.js`),__vite__mapDeps([15,1,2,3]),import.meta.url))},{id:`http`,name:`HTTP`,import:(()=>M(()=>import(`./http-CIm3Kw31.js`),__vite__mapDeps([55,7,8,9,29,36,2,11,13,37]),import.meta.url))},{id:`hurl`,name:`Hurl`,import:(()=>M(()=>import(`./hurl-CLvYxNZa.js`),__vite__mapDeps([56,7,8,57,36,2,11,13,37]),import.meta.url))},{id:`hxml`,name:`HXML`,import:(()=>M(()=>import(`./hxml-Dcm88srW.js`),__vite__mapDeps([58,59]),import.meta.url))},{id:`hy`,name:`Hy`,import:(()=>M(()=>import(`./hy-CZbG8q4J.js`),[],import.meta.url))},{id:`imba`,name:`Imba`,import:(()=>M(()=>import(`./imba-DsUTQ-LC.js`),[],import.meta.url))},{id:`ini`,name:`INI`,aliases:[`properties`],import:(()=>M(()=>import(`./ini-B5eOa1yu.js`),[],import.meta.url))},{id:`java`,name:`Java`,import:(()=>M(()=>import(`./java-Rw3L1ZVe.js`).then(e=>e.n),[],import.meta.url))},{id:`javascript`,name:`JavaScript`,aliases:[`js`,`cjs`,`mjs`],import:(()=>M(()=>import(`./javascript-BDTOnMX6.js`).then(e=>e.n),[],import.meta.url))},{id:`jinja`,name:`Jinja`,import:(()=>M(()=>import(`./jinja-V3XFOf5X.js`),__vite__mapDeps([60,1,2,3]),import.meta.url))},{id:`jison`,name:`Jison`,import:(()=>M(()=>import(`./jison-DsX2fRlw.js`),__vite__mapDeps([61,2]),import.meta.url))},{id:`json`,name:`JSON`,import:(()=>M(()=>import(`./json-DXtaKgIN.js`).then(e=>e.n),[],import.meta.url))},{id:`json5`,name:`JSON5`,import:(()=>M(()=>import(`./json5-BR5RXkoi.js`),[],import.meta.url))},{id:`jsonc`,name:`JSON with Comments`,import:(()=>M(()=>import(`./jsonc-CYpm1nAK.js`),[],import.meta.url))},{id:`jsonl`,name:`JSON Lines`,import:(()=>M(()=>import(`./jsonl-CmCQp5Yx.js`),[],import.meta.url))},{id:`jsonnet`,name:`Jsonnet`,import:(()=>M(()=>import(`./jsonnet-CJTPZ8u_.js`),[],import.meta.url))},{id:`jssm`,name:`JSSM`,aliases:[`fsl`],import:(()=>M(()=>import(`./jssm-DXw9l8Rf.js`),[],import.meta.url))},{id:`jsx`,name:`JSX`,import:(()=>M(()=>import(`./jsx-C--z3Vz0.js`).then(e=>e.n),[],import.meta.url))},{id:`julia`,name:`Julia`,aliases:[`jl`],import:(()=>M(()=>import(`./julia-CYpeWsG7.js`),__vite__mapDeps([62,2,16,20,25,26,27,22,63]),import.meta.url))},{id:`just`,name:`Just`,aliases:[`justfile`],import:(()=>M(()=>import(`./just-BuEYXcL7.js`),__vite__mapDeps([64,2,11,20,29,34,3,1,7,8,16,22,25,26,27,35,36,13,37,38,39,65]),import.meta.url))},{id:`kdl`,name:`KDL`,import:(()=>M(()=>import(`./kdl-CsD5j6eV.js`),[],import.meta.url))},{id:`kotlin`,name:`Kotlin`,aliases:[`kt`,`kts`],import:(()=>M(()=>import(`./kotlin-DhhofPvG.js`),[],import.meta.url))},{id:`kusto`,name:`Kusto`,aliases:[`kql`],import:(()=>M(()=>import(`./kusto-C7mF5XQf.js`),[],import.meta.url))},{id:`latex`,name:`LaTeX`,import:(()=>M(()=>import(`./latex-Cm1B1ddK.js`),__vite__mapDeps([66,67,63]),import.meta.url))},{id:`lean`,name:`Lean 4`,aliases:[`lean4`],import:(()=>M(()=>import(`./lean-CewbzKMR.js`),[],import.meta.url))},{id:`less`,name:`Less`,import:(()=>M(()=>import(`./less-DVTAwKKz.js`),[],import.meta.url))},{id:`liquid`,name:`Liquid`,import:(()=>M(()=>import(`./liquid-GkjL8esp.js`),__vite__mapDeps([68,2,3,1,9]),import.meta.url))},{id:`llvm`,name:`LLVM IR`,import:(()=>M(()=>import(`./llvm-DqHOMS-s.js`),[],import.meta.url))},{id:`log`,name:`Log file`,import:(()=>M(()=>import(`./log-BNLmms1o.js`),[],import.meta.url))},{id:`logo`,name:`Logo`,import:(()=>M(()=>import(`./logo-Cluzi2Zq.js`),[],import.meta.url))},{id:`lua`,name:`Lua`,import:(()=>M(()=>import(`./lua-CvYt7dZy.js`).then(e=>e.n),__vite__mapDeps([38,22]),import.meta.url))},{id:`luau`,name:`Luau`,import:(()=>M(()=>import(`./luau-C2pBCSgt.js`),[],import.meta.url))},{id:`make`,name:`Makefile`,aliases:[`makefile`],import:(()=>M(()=>import(`./make-Dixweg8N.js`),[],import.meta.url))},{id:`markdown`,name:`Markdown`,aliases:[`md`],import:(()=>M(()=>import(`./markdown-BYOwaDjH.js`),[],import.meta.url))},{id:`marko`,name:`Marko`,import:(()=>M(()=>import(`./marko-BMSo_3mq.js`),__vite__mapDeps([69,3,5,11,70]),import.meta.url))},{id:`matlab`,name:`MATLAB`,import:(()=>M(()=>import(`./matlab-D7qyCx1q.js`),[],import.meta.url))},{id:`mdc`,name:`MDC`,import:(()=>M(()=>import(`./mdc-oSXeVlop.js`),__vite__mapDeps([71,15,1,2,3,39,41]),import.meta.url))},{id:`mdx`,name:`MDX`,import:(()=>M(()=>import(`./mdx-DQZ5AkYe.js`),[],import.meta.url))},{id:`mermaid`,name:`Mermaid`,aliases:[`mmd`],import:(()=>M(()=>import(`./mermaid-BxpfTIzt.js`),[],import.meta.url))},{id:`mipsasm`,name:`MIPS Assembly`,aliases:[`mips`],import:(()=>M(()=>import(`./mipsasm-BMqwQI7S.js`),[],import.meta.url))},{id:`mojo`,name:`Mojo`,import:(()=>M(()=>import(`./mojo-fg40_ntQ.js`),[],import.meta.url))},{id:`moonbit`,name:`MoonBit`,aliases:[`mbt`,`mbti`],import:(()=>M(()=>import(`./moonbit-DgjMoLWr.js`),[],import.meta.url))},{id:`move`,name:`Move`,import:(()=>M(()=>import(`./move-BYnGhZoM.js`),[],import.meta.url))},{id:`narrat`,name:`Narrat Language`,aliases:[`nar`],import:(()=>M(()=>import(`./narrat-_X_XdTYD.js`),[],import.meta.url))},{id:`nextflow`,name:`Nextflow`,aliases:[`nf`],import:(()=>M(()=>import(`./nextflow-BJtWHP5T.js`),__vite__mapDeps([72,73]),import.meta.url))},{id:`nextflow-groovy`,name:`Nextflow Groovy`,import:(()=>M(()=>import(`./nextflow-groovy-DJMQeKeT.js`),[],import.meta.url))},{id:`nginx`,name:`Nginx`,import:(()=>M(()=>import(`./nginx-WTmYQb7p.js`),__vite__mapDeps([74,38,22]),import.meta.url))},{id:`nim`,name:`Nim`,import:(()=>M(()=>import(`./nim-DukmWsYe.js`),__vite__mapDeps([75,2,3,1,7,8,22,27,41]),import.meta.url))},{id:`nix`,name:`Nix`,import:(()=>M(()=>import(`./nix-IvuFDN5E.js`),[],import.meta.url))},{id:`nsis`,name:`NSIS`,import:(()=>M(()=>import(`./nsis-CjNLYCLg.js`),[],import.meta.url))},{id:`nushell`,name:`nushell`,aliases:[`nu`],import:(()=>M(()=>import(`./nushell-DHYfO66s.js`),[],import.meta.url))},{id:`objective-c`,name:`Objective-C`,aliases:[`objc`],import:(()=>M(()=>import(`./objective-c-D1A_Heim.js`),[],import.meta.url))},{id:`objective-cpp`,name:`Objective-C++`,import:(()=>M(()=>import(`./objective-cpp-BsSzOQcm.js`),[],import.meta.url))},{id:`ocaml`,name:`OCaml`,import:(()=>M(()=>import(`./ocaml-O90oeIOV.js`),[],import.meta.url))},{id:`odin`,name:`Odin`,import:(()=>M(()=>import(`./odin-B1RWQWA5.js`),[],import.meta.url))},{id:`openscad`,name:`OpenSCAD`,aliases:[`scad`],import:(()=>M(()=>import(`./openscad-BUDT5pXO.js`),[],import.meta.url))},{id:`org`,name:`Org Markup`,import:(()=>M(()=>import(`./org-B3Mg55pm.js`),__vite__mapDeps([76,2,3,1,5,8,7,9,11,13,16,22,20,77,24,26,25,27,29,78,79,49,80,31,38,39,34,35,36,37,41,40,48,50,81,82,83,63,65,66,67,70,84,75,85,86,87,88,89,90,91,92,93]),import.meta.url))},{id:`pascal`,name:`Pascal`,import:(()=>M(()=>import(`./pascal-4ZHwLPI5.js`),[],import.meta.url))},{id:`perl`,name:`Perl`,import:(()=>M(()=>import(`./perl-Biyv-RCp.js`),__vite__mapDeps([65,2,3,1,7,8,16]),import.meta.url))},{id:`php`,name:`PHP`,import:(()=>M(()=>import(`./php-DhLwDtyd.js`),__vite__mapDeps([87,2,3,1,7,8,9,16]),import.meta.url))},{id:`pkl`,name:`Pkl`,import:(()=>M(()=>import(`./pkl-ot-7Btpt.js`),[],import.meta.url))},{id:`plsql`,name:`PL/SQL`,import:(()=>M(()=>import(`./plsql-DGHpHOYJ.js`),[],import.meta.url))},{id:`po`,name:`Gettext PO`,aliases:[`pot`,`potx`],import:(()=>M(()=>import(`./po-BiJDBrnU.js`),[],import.meta.url))},{id:`polar`,name:`Polar`,import:(()=>M(()=>import(`./polar-C7UOKdEL.js`),[],import.meta.url))},{id:`postcss`,name:`PostCSS`,import:(()=>M(()=>import(`./postcss-BXeXVLqQ.js`),[],import.meta.url))},{id:`powerquery`,name:`PowerQuery`,import:(()=>M(()=>import(`./powerquery-DNMTfnFr.js`),[],import.meta.url))},{id:`powershell`,name:`PowerShell`,aliases:[`ps`,`ps1`,`pwsh`],import:(()=>M(()=>import(`./powershell-CCSX75yM.js`),[],import.meta.url))},{id:`prisma`,name:`Prisma`,import:(()=>M(()=>import(`./prisma-DMgNhnYS.js`),[],import.meta.url))},{id:`prolog`,name:`Prolog`,import:(()=>M(()=>import(`./prolog-iXnhIJG7.js`),[],import.meta.url))},{id:`proto`,name:`Protocol Buffer 3`,aliases:[`protobuf`],import:(()=>M(()=>import(`./proto-DB4EqR-F.js`),[],import.meta.url))},{id:`pug`,name:`Pug`,aliases:[`jade`],import:(()=>M(()=>import(`./pug-Bu1fHTcb.js`),__vite__mapDeps([94,2,3,1]),import.meta.url))},{id:`puppet`,name:`Puppet`,import:(()=>M(()=>import(`./puppet-CDv2pdJW.js`),[],import.meta.url))},{id:`purescript`,name:`PureScript`,import:(()=>M(()=>import(`./purescript-9MfHhQsQ.js`),[],import.meta.url))},{id:`python`,name:`Python`,aliases:[`py`],import:(()=>M(()=>import(`./python-gzcpVVnB.js`),[],import.meta.url))},{id:`qml`,name:`QML`,import:(()=>M(()=>import(`./qml-CyeLhJPf.js`),__vite__mapDeps([95,2]),import.meta.url))},{id:`qmldir`,name:`QML Directory`,import:(()=>M(()=>import(`./qmldir-DCQb3MpD.js`),[],import.meta.url))},{id:`qss`,name:`Qt Style Sheets`,import:(()=>M(()=>import(`./qss-Fe1Jh2GI.js`),[],import.meta.url))},{id:`r`,name:`R`,import:(()=>M(()=>import(`./r-oMvZ7vof.js`).then(e=>e.n),[],import.meta.url))},{id:`racket`,name:`Racket`,import:(()=>M(()=>import(`./racket-DcIDlBhZ.js`),[],import.meta.url))},{id:`raku`,name:`Raku`,aliases:[`perl6`],import:(()=>M(()=>import(`./raku-B3gFvitq.js`),[],import.meta.url))},{id:`razor`,name:`ASP.NET Razor`,import:(()=>M(()=>import(`./razor-QR2R7Wy2.js`),__vite__mapDeps([96,1,2,3,78]),import.meta.url))},{id:`rbs`,name:`RBS`,aliases:[`ruby-signature`],import:(()=>M(()=>import(`./rbs-C0MpOrj4.js`),[],import.meta.url))},{id:`reg`,name:`Windows Registry Script`,import:(()=>M(()=>import(`./reg-CRGYupPL.js`),[],import.meta.url))},{id:`regexp`,name:`RegExp`,aliases:[`regex`],import:(()=>M(()=>import(`./regexp-Dy_006lz.js`).then(e=>e.n),[],import.meta.url))},{id:`rel`,name:`Rel`,import:(()=>M(()=>import(`./rel-BtDbiS_P.js`),[],import.meta.url))},{id:`riscv`,name:`RISC-V`,import:(()=>M(()=>import(`./riscv-Ckw8ddFX.js`),[],import.meta.url))},{id:`ron`,name:`RON`,import:(()=>M(()=>import(`./ron-VUp2lXgN.js`),[],import.meta.url))},{id:`rosmsg`,name:`ROS Interface`,import:(()=>M(()=>import(`./rosmsg-CAekHB0j.js`),[],import.meta.url))},{id:`rst`,name:`reStructuredText`,import:(()=>M(()=>import(`./rst-bSV3koz4.js`),__vite__mapDeps([97,2,15,1,3,20,98,25,26,27,22,29,39,34,7,8,16,35,36,11,13,37,38]),import.meta.url))},{id:`ruby`,name:`Ruby`,aliases:[`rb`],import:(()=>M(()=>import(`./ruby-D4XPeMQn.js`),__vite__mapDeps([34,2,3,1,7,8,16,22,25,26,27,29,35,36,11,13,37,38,39]),import.meta.url))},{id:`rust`,name:`Rust`,aliases:[`rs`],import:(()=>M(()=>import(`./rust-Cfkwpbl8.js`),[],import.meta.url))},{id:`sas`,name:`SAS`,import:(()=>M(()=>import(`./sas-K00l5DQD.js`),__vite__mapDeps([99,16]),import.meta.url))},{id:`sass`,name:`Sass`,import:(()=>M(()=>import(`./sass-DXrisJhu.js`),[],import.meta.url))},{id:`scala`,name:`Scala`,import:(()=>M(()=>import(`./scala-BiFt_7mu.js`),[],import.meta.url))},{id:`scheme`,name:`Scheme`,import:(()=>M(()=>import(`./scheme-DQCgrYNe.js`),[],import.meta.url))},{id:`scss`,name:`SCSS`,import:(()=>M(()=>import(`./scss-Cw-YxsUO.js`).then(e=>e.n),__vite__mapDeps([5,3]),import.meta.url))},{id:`sdbl`,name:`1C (Query)`,aliases:[`1c-query`],import:(()=>M(()=>import(`./sdbl-bTVj8UrX.js`),[],import.meta.url))},{id:`shaderlab`,name:`ShaderLab`,aliases:[`shader`],import:(()=>M(()=>import(`./shaderlab-TOUzSsQk.js`),__vite__mapDeps([100,101]),import.meta.url))},{id:`shellscript`,name:`Shell`,aliases:[`bash`,`sh`,`shell`,`zsh`],import:(()=>M(()=>import(`./shellscript-Oo-I28wg.js`).then(e=>e.n),[],import.meta.url))},{id:`shellsession`,name:`Shell Session`,aliases:[`console`],import:(()=>M(()=>import(`./shellsession-D8YpK5Gt.js`),__vite__mapDeps([102,29]),import.meta.url))},{id:`smalltalk`,name:`GNU Smalltalk`,import:(()=>M(()=>import(`./smalltalk-BHpQb5nM.js`),[],import.meta.url))},{id:`smithy`,name:`Smithy`,import:(()=>M(()=>import(`./smithy-Dgaz7aur.js`),[],import.meta.url))},{id:`solidity`,name:`Solidity`,import:(()=>M(()=>import(`./solidity-Bj7E1mRn.js`),[],import.meta.url))},{id:`soy`,name:`Closure Templates`,aliases:[`closure-templates`],import:(()=>M(()=>import(`./soy-CirTT52K.js`),__vite__mapDeps([103,1,2,3]),import.meta.url))},{id:`sparql`,name:`SPARQL`,import:(()=>M(()=>import(`./sparql-D_iOobhT.js`),__vite__mapDeps([104,105]),import.meta.url))},{id:`splunk`,name:`Splunk Query Language`,aliases:[`spl`],import:(()=>M(()=>import(`./splunk-BC2Px7Mm.js`),[],import.meta.url))},{id:`sql`,name:`SQL`,import:(()=>M(()=>import(`./sql-C8VWaiZL.js`).then(e=>e.n),[],import.meta.url))},{id:`ssh-config`,name:`SSH Config`,import:(()=>M(()=>import(`./ssh-config-BgfXC-Er.js`),[],import.meta.url))},{id:`stata`,name:`Stata`,import:(()=>M(()=>import(`./stata-BJZ5oZlg.js`),__vite__mapDeps([106,16]),import.meta.url))},{id:`stylus`,name:`Stylus`,aliases:[`styl`],import:(()=>M(()=>import(`./stylus-B6D30XZt.js`),[],import.meta.url))},{id:`surrealql`,name:`SurrealQL`,aliases:[`surql`],import:(()=>M(()=>import(`./surrealql-cWw1kS_r.js`),__vite__mapDeps([107,2]),import.meta.url))},{id:`svelte`,name:`Svelte`,import:(()=>M(()=>import(`./svelte-qe4-sQol.js`),__vite__mapDeps([108,2,3,11,12]),import.meta.url))},{id:`swift`,name:`Swift`,import:(()=>M(()=>import(`./swift-CyEgAFGc.js`),[],import.meta.url))},{id:`system-verilog`,name:`SystemVerilog`,import:(()=>M(()=>import(`./system-verilog-Dh5ihWbf.js`),[],import.meta.url))},{id:`systemd`,name:`Systemd Units`,import:(()=>M(()=>import(`./systemd-BxMlprV5.js`),[],import.meta.url))},{id:`talonscript`,name:`TalonScript`,aliases:[`talon`],import:(()=>M(()=>import(`./talonscript-CohzipZa.js`),[],import.meta.url))},{id:`tasl`,name:`Tasl`,import:(()=>M(()=>import(`./tasl-DMoTqEGO.js`),[],import.meta.url))},{id:`tcl`,name:`Tcl`,import:(()=>M(()=>import(`./tcl-CZd0xW_V.js`),[],import.meta.url))},{id:`templ`,name:`Templ`,import:(()=>M(()=>import(`./templ-Ttp3sKu1.js`),__vite__mapDeps([109,2,3,81]),import.meta.url))},{id:`terraform`,name:`Terraform`,aliases:[`tf`,`tfvars`],import:(()=>M(()=>import(`./terraform-DswuEJGm.js`),[],import.meta.url))},{id:`tex`,name:`TeX`,import:(()=>M(()=>import(`./tex-CEAqnEVG.js`).then(e=>e.n),__vite__mapDeps([67,63]),import.meta.url))},{id:`toml`,name:`TOML`,import:(()=>M(()=>import(`./toml-CcmNWLt0.js`),[],import.meta.url))},{id:`ts-tags`,name:`TypeScript with Tags`,aliases:[`lit`],import:(()=>M(()=>import(`./ts-tags-DSeRvYgh.js`),__vite__mapDeps([110,2,3,1,7,8,11,16,27,22]),import.meta.url))},{id:`tsv`,name:`TSV`,import:(()=>M(()=>import(`./tsv-sltzmVWM.js`),[],import.meta.url))},{id:`tsx`,name:`TSX`,import:(()=>M(()=>import(`./tsx-BNFQ917s.js`).then(e=>e.n),[],import.meta.url))},{id:`turtle`,name:`Turtle`,import:(()=>M(()=>import(`./turtle-ByJddavk.js`),[],import.meta.url))},{id:`twig`,name:`Twig`,import:(()=>M(()=>import(`./twig-Dle5Xpmn.js`),__vite__mapDeps([111,2,3,5,20,34,1,7,8,16,22,25,26,27,29,35,36,11,13,37,38,39,87,9]),import.meta.url))},{id:`typescript`,name:`TypeScript`,aliases:[`ts`,`cts`,`mts`],import:(()=>M(()=>import(`./typescript-BbQ7yQ6i.js`).then(e=>e.n),[],import.meta.url))},{id:`typespec`,name:`TypeSpec`,aliases:[`tsp`],import:(()=>M(()=>import(`./typespec-BRdr0IET.js`),[],import.meta.url))},{id:`typst`,name:`Typst`,aliases:[`typ`],import:(()=>M(()=>import(`./typst-Cbf-O2WN.js`),__vite__mapDeps([112,2,3,1,5,8,7,9,11,13,113,114,16,22,20,77,24,26,25,27,29,78,79,49,80,31,38,39,34,35,36,37,41,40,44,48,50,81,82,54,83,115,63,62,65,66,67,70,116,84,85,87,88,89,90,91,93,117,94,118,119,111,120]),import.meta.url))},{id:`v`,name:`V`,import:(()=>M(()=>import(`./v-DBj4K9d_.js`),[],import.meta.url))},{id:`vala`,name:`Vala`,import:(()=>M(()=>import(`./vala-zf12oZj6.js`),[],import.meta.url))},{id:`vb`,name:`Visual Basic`,import:(()=>M(()=>import(`./vb-DOwzaHZ0.js`),[],import.meta.url))},{id:`verilog`,name:`Verilog`,import:(()=>M(()=>import(`./verilog-B2gwz-sJ.js`),[],import.meta.url))},{id:`vhdl`,name:`VHDL`,import:(()=>M(()=>import(`./vhdl-BroJfC0k.js`),[],import.meta.url))},{id:`viml`,name:`Vim Script`,aliases:[`vim`,`vimscript`],import:(()=>M(()=>import(`./viml-DvXPmvsu.js`),[],import.meta.url))},{id:`vue`,name:`Vue`,import:(()=>M(()=>import(`./vue-YmceU--9.js`),__vite__mapDeps([121,2,3,1,9,11,15]),import.meta.url))},{id:`vue-html`,name:`Vue HTML`,import:(()=>M(()=>import(`./vue-html-qwVM617a.js`),__vite__mapDeps([122,2]),import.meta.url))},{id:`vue-vine`,name:`Vue Vine`,import:(()=>M(()=>import(`./vue-vine-CwQvVGBQ.js`),__vite__mapDeps([123,2,3,5,12,70,124]),import.meta.url))},{id:`vyper`,name:`Vyper`,aliases:[`vy`],import:(()=>M(()=>import(`./vyper-CgoNMtux.js`),[],import.meta.url))},{id:`wasm`,name:`WebAssembly`,import:(()=>M(()=>import(`./wasm-ByWQv1Qj.js`),[],import.meta.url))},{id:`wenyan`,name:`Wenyan`,aliases:[`文言`],import:(()=>M(()=>import(`./wenyan-C8pVoKbM.js`),[],import.meta.url))},{id:`wgsl`,name:`WGSL`,import:(()=>M(()=>import(`./wgsl-BsKzXJz4.js`),[],import.meta.url))},{id:`wikitext`,name:`Wikitext`,aliases:[`mediawiki`,`wiki`],import:(()=>M(()=>import(`./wikitext-ClFFjSW2.js`),[],import.meta.url))},{id:`wit`,name:`WebAssembly Interface Types`,import:(()=>M(()=>import(`./wit-DdvCle-K.js`),[],import.meta.url))},{id:`wolfram`,name:`Wolfram`,aliases:[`wl`],import:(()=>M(()=>import(`./wolfram-DLL8P-h_.js`),[],import.meta.url))},{id:`xml`,name:`XML`,import:(()=>M(()=>import(`./xml-CjaiHDlR.js`).then(e=>e.n),__vite__mapDeps([7,8]),import.meta.url))},{id:`xsl`,name:`XSL`,import:(()=>M(()=>import(`./xsl-C7AYdAd6.js`),__vite__mapDeps([93,7,8]),import.meta.url))},{id:`yaml`,name:`YAML`,aliases:[`yml`],import:(()=>M(()=>import(`./yaml-BF0Ptbfs.js`).then(e=>e.n),[],import.meta.url))},{id:`zenscript`,name:`ZenScript`,import:(()=>M(()=>import(`./zenscript-BnlCZFoB.js`),[],import.meta.url))},{id:`zig`,name:`Zig`,import:(()=>M(()=>import(`./zig-CMLA9XwU.js`),[],import.meta.url))}],ut=Object.fromEntries(lt.map(e=>[e.id,e.import])),dt=Object.fromEntries(lt.flatMap(e=>e.aliases?.map(t=>[t,e.import])||[])),ft={...ut,...dt},pt=Object.fromEntries([{id:`andromeeda`,displayName:`Andromeeda`,type:`dark`,import:(()=>M(()=>import(`./andromeeda-vGVdxbeo.js`),[],import.meta.url))},{id:`aurora-x`,displayName:`Aurora X`,type:`dark`,import:(()=>M(()=>import(`./aurora-x-CDeNXAV0.js`),[],import.meta.url))},{id:`ayu-dark`,displayName:`Ayu Dark`,type:`dark`,import:(()=>M(()=>import(`./ayu-dark-DluEY0Gj.js`),[],import.meta.url))},{id:`ayu-light`,displayName:`Ayu Light`,type:`light`,import:(()=>M(()=>import(`./ayu-light-C3h-C4tm.js`),[],import.meta.url))},{id:`ayu-mirage`,displayName:`Ayu Mirage`,type:`dark`,import:(()=>M(()=>import(`./ayu-mirage-Bqwy1Gya.js`),[],import.meta.url))},{id:`catppuccin-frappe`,displayName:`Catppuccin Frappé`,type:`dark`,import:(()=>M(()=>import(`./catppuccin-frappe-C9Q5zVZY.js`),[],import.meta.url))},{id:`catppuccin-latte`,displayName:`Catppuccin Latte`,type:`light`,import:(()=>M(()=>import(`./catppuccin-latte-CtsyrtPq.js`),[],import.meta.url))},{id:`catppuccin-macchiato`,displayName:`Catppuccin Macchiato`,type:`dark`,import:(()=>M(()=>import(`./catppuccin-macchiato-R8nAf1vR.js`),[],import.meta.url))},{id:`catppuccin-mocha`,displayName:`Catppuccin Mocha`,type:`dark`,import:(()=>M(()=>import(`./catppuccin-mocha-DjuaAJKi.js`),[],import.meta.url))},{id:`dark-plus`,displayName:`Dark Plus`,type:`dark`,import:(()=>M(()=>import(`./dark-plus-Cs2F2srj.js`),[],import.meta.url))},{id:`dracula`,displayName:`Dracula Theme`,type:`dark`,import:(()=>M(()=>import(`./dracula-BHWKrbxM.js`),[],import.meta.url))},{id:`dracula-soft`,displayName:`Dracula Theme Soft`,type:`dark`,import:(()=>M(()=>import(`./dracula-soft-5eyTD99u.js`),[],import.meta.url))},{id:`everforest-dark`,displayName:`Everforest Dark`,type:`dark`,import:(()=>M(()=>import(`./everforest-dark-sB-x3p7T.js`),[],import.meta.url))},{id:`everforest-light`,displayName:`Everforest Light`,type:`light`,import:(()=>M(()=>import(`./everforest-light-Df2xbC6M.js`),[],import.meta.url))},{id:`github-dark`,displayName:`GitHub Dark`,type:`dark`,import:(()=>M(()=>import(`./github-dark-C-LZuMrd.js`),[],import.meta.url))},{id:`github-dark-default`,displayName:`GitHub Dark Default`,type:`dark`,import:(()=>M(()=>import(`./github-dark-default-DXG-b-1a.js`),[],import.meta.url))},{id:`github-dark-dimmed`,displayName:`GitHub Dark Dimmed`,type:`dark`,import:(()=>M(()=>import(`./github-dark-dimmed-Bx1FflLF.js`),[],import.meta.url))},{id:`github-dark-high-contrast`,displayName:`GitHub Dark High Contrast`,type:`dark`,import:(()=>M(()=>import(`./github-dark-high-contrast-B_tTalzw.js`),[],import.meta.url))},{id:`github-light`,displayName:`GitHub Light`,type:`light`,import:(()=>M(()=>import(`./github-light-EUqPIrTm.js`),[],import.meta.url))},{id:`github-light-default`,displayName:`GitHub Light Default`,type:`light`,import:(()=>M(()=>import(`./github-light-default-BXViO-2h.js`),[],import.meta.url))},{id:`github-light-high-contrast`,displayName:`GitHub Light High Contrast`,type:`light`,import:(()=>M(()=>import(`./github-light-high-contrast-B68TUdTA.js`),[],import.meta.url))},{id:`gruvbox-dark-hard`,displayName:`Gruvbox Dark Hard`,type:`dark`,import:(()=>M(()=>import(`./gruvbox-dark-hard-C820rvS2.js`),[],import.meta.url))},{id:`gruvbox-dark-medium`,displayName:`Gruvbox Dark Medium`,type:`dark`,import:(()=>M(()=>import(`./gruvbox-dark-medium-BPjhmG05.js`),[],import.meta.url))},{id:`gruvbox-dark-soft`,displayName:`Gruvbox Dark Soft`,type:`dark`,import:(()=>M(()=>import(`./gruvbox-dark-soft-MrdJrrXF.js`),[],import.meta.url))},{id:`gruvbox-light-hard`,displayName:`Gruvbox Light Hard`,type:`light`,import:(()=>M(()=>import(`./gruvbox-light-hard-BC_s9l72.js`),[],import.meta.url))},{id:`gruvbox-light-medium`,displayName:`Gruvbox Light Medium`,type:`light`,import:(()=>M(()=>import(`./gruvbox-light-medium-BAWPOn9u.js`),[],import.meta.url))},{id:`gruvbox-light-soft`,displayName:`Gruvbox Light Soft`,type:`light`,import:(()=>M(()=>import(`./gruvbox-light-soft-BSMLrYjP.js`),[],import.meta.url))},{id:`horizon`,displayName:`Horizon`,type:`dark`,import:(()=>M(()=>import(`./horizon-CE9ld1lL.js`),[],import.meta.url))},{id:`horizon-bright`,displayName:`Horizon Bright`,type:`light`,import:(()=>M(()=>import(`./horizon-bright-DSNQnXHK.js`),[],import.meta.url))},{id:`houston`,displayName:`Houston`,type:`dark`,import:(()=>M(()=>import(`./houston-CsvMBhTu.js`),[],import.meta.url))},{id:`kanagawa-dragon`,displayName:`Kanagawa Dragon`,type:`dark`,import:(()=>M(()=>import(`./kanagawa-dragon-Bozd7klA.js`),[],import.meta.url))},{id:`kanagawa-lotus`,displayName:`Kanagawa Lotus`,type:`light`,import:(()=>M(()=>import(`./kanagawa-lotus-BmuOG9ZW.js`),[],import.meta.url))},{id:`kanagawa-wave`,displayName:`Kanagawa Wave`,type:`dark`,import:(()=>M(()=>import(`./kanagawa-wave-BML5mF2J.js`),[],import.meta.url))},{id:`laserwave`,displayName:`LaserWave`,type:`dark`,import:(()=>M(()=>import(`./laserwave-C_8bwKvT.js`),[],import.meta.url))},{id:`light-plus`,displayName:`Light Plus`,type:`light`,import:(()=>M(()=>import(`./light-plus-DVQuIRkW.js`),[],import.meta.url))},{id:`material-theme`,displayName:`Material Theme`,type:`dark`,import:(()=>M(()=>import(`./material-theme-Bm3Qr25_.js`),[],import.meta.url))},{id:`material-theme-darker`,displayName:`Material Theme Darker`,type:`dark`,import:(()=>M(()=>import(`./material-theme-darker-2IIEA8gg.js`),[],import.meta.url))},{id:`material-theme-lighter`,displayName:`Material Theme Lighter`,type:`light`,import:(()=>M(()=>import(`./material-theme-lighter-uhdI0v04.js`),[],import.meta.url))},{id:`material-theme-ocean`,displayName:`Material Theme Ocean`,type:`dark`,import:(()=>M(()=>import(`./material-theme-ocean-CHQ94UKr.js`),[],import.meta.url))},{id:`material-theme-palenight`,displayName:`Material Theme Palenight`,type:`dark`,import:(()=>M(()=>import(`./material-theme-palenight-B5W6OYN7.js`),[],import.meta.url))},{id:`min-dark`,displayName:`Min Dark`,type:`dark`,import:(()=>M(()=>import(`./min-dark-BSWPekZh.js`),[],import.meta.url))},{id:`min-light`,displayName:`Min Light`,type:`light`,import:(()=>M(()=>import(`./min-light-DDpmG2fV.js`),[],import.meta.url))},{id:`monokai`,displayName:`Monokai`,type:`dark`,import:(()=>M(()=>import(`./monokai-B_bV9PQ9.js`),[],import.meta.url))},{id:`night-owl`,displayName:`Night Owl`,type:`dark`,import:(()=>M(()=>import(`./night-owl-DhmEMT88.js`),[],import.meta.url))},{id:`night-owl-light`,displayName:`Night Owl Light`,type:`light`,import:(()=>M(()=>import(`./night-owl-light-eJ-hLW7d.js`),[],import.meta.url))},{id:`nord`,displayName:`Nord`,type:`dark`,import:(()=>M(()=>import(`./nord-Cb4Vim4T.js`),[],import.meta.url))},{id:`one-dark-pro`,displayName:`One Dark Pro`,type:`dark`,import:(()=>M(()=>import(`./one-dark-pro-CLwyXe_n.js`),[],import.meta.url))},{id:`one-light`,displayName:`One Light`,type:`light`,import:(()=>M(()=>import(`./one-light-D7Lr4KcI.js`),[],import.meta.url))},{id:`plastic`,displayName:`Plastic`,type:`dark`,import:(()=>M(()=>import(`./plastic-DQwYfKfQ.js`),[],import.meta.url))},{id:`poimandres`,displayName:`Poimandres`,type:`dark`,import:(()=>M(()=>import(`./poimandres-DRFjx7u4.js`),[],import.meta.url))},{id:`red`,displayName:`Red`,type:`dark`,import:(()=>M(()=>import(`./red-DX1BQOs8.js`),[],import.meta.url))},{id:`rose-pine`,displayName:`Rosé Pine`,type:`dark`,import:(()=>M(()=>import(`./rose-pine-aMsaMD1D.js`),[],import.meta.url))},{id:`rose-pine-dawn`,displayName:`Rosé Pine Dawn`,type:`light`,import:(()=>M(()=>import(`./rose-pine-dawn-8PwUyIlP.js`),[],import.meta.url))},{id:`rose-pine-moon`,displayName:`Rosé Pine Moon`,type:`dark`,import:(()=>M(()=>import(`./rose-pine-moon-DO-qXg-I.js`),[],import.meta.url))},{id:`slack-dark`,displayName:`Slack Dark`,type:`dark`,import:(()=>M(()=>import(`./slack-dark-DnToyrRv.js`),[],import.meta.url))},{id:`slack-ochin`,displayName:`Slack Ochin`,type:`light`,import:(()=>M(()=>import(`./slack-ochin-B2OO5cIa.js`),[],import.meta.url))},{id:`snazzy-light`,displayName:`Snazzy Light`,type:`light`,import:(()=>M(()=>import(`./snazzy-light-4G7pJPwS.js`),[],import.meta.url))},{id:`solarized-dark`,displayName:`Solarized Dark`,type:`dark`,import:(()=>M(()=>import(`./solarized-dark-UdsmMDCL.js`),[],import.meta.url))},{id:`solarized-light`,displayName:`Solarized Light`,type:`light`,import:(()=>M(()=>import(`./solarized-light-C1IUL_tW.js`),[],import.meta.url))},{id:`synthwave-84`,displayName:`Synthwave '84`,type:`dark`,import:(()=>M(()=>import(`./synthwave-84-nFMaYfgc.js`),[],import.meta.url))},{id:`tokyo-night`,displayName:`Tokyo Night`,type:`dark`,import:(()=>M(()=>import(`./tokyo-night-oM2G3aXe.js`),[],import.meta.url))},{id:`vesper`,displayName:`Vesper`,type:`dark`,import:(()=>M(()=>import(`./vesper-DdrHHSXu.js`),[],import.meta.url))},{id:`vitesse-black`,displayName:`Vitesse Black`,type:`dark`,import:(()=>M(()=>import(`./vitesse-black-fwtXNY1n.js`),[],import.meta.url))},{id:`vitesse-dark`,displayName:`Vitesse Dark`,type:`dark`,import:(()=>M(()=>import(`./vitesse-dark-BZCL-v6S.js`),[],import.meta.url))},{id:`vitesse-light`,displayName:`Vitesse Light`,type:`light`,import:(()=>M(()=>import(`./vitesse-light-VbXTXTou.js`),[],import.meta.url))}].map(e=>[e.id,e.import])),mt=s({createOnigurumaEngine:()=>Ht,getDefaultWasmLoader:()=>Vt,loadWasm:()=>Ft,setDefaultWasmLoader:()=>Bt}),ht=class extends Error{constructor(e){super(e),this.name=`ShikiError`}};function gt(){return 2147483648}function _t(){return typeof performance<`u`?performance.now():Date.now()}var vt=(e,t)=>e+(t-e%t)%t;async function yt(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=gt();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,vt(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:_t,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 bt=Object.defineProperty,xt=(e,t,n)=>t in e?bt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,St=(e,t,n)=>xt(e,typeof t==`symbol`?t:t+``,n),Ct=null;function wt(e){throw new ht(e.UTF8ToString(e.getLastOnigError()))}var Tt=class e{constructor(t){St(this,`utf16Length`),St(this,`utf8Length`),St(this,`utf16Value`),St(this,`utf8Value`),St(this,`utf16OffsetToUtf8`),St(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)}t+=a<=127?1:a<=2047?2:a<=65535?3:4,o&&n++}return t}createString(e){let t=e.omalloc(this.utf8Length);return e.HEAPU8.set(this.utf8Value,t),t}},Et=class e{constructor(t){if(St(this,`id`,++e.LAST_ID),St(this,`_onigBinding`),St(this,`content`),St(this,`utf16Length`),St(this,`utf8Length`),St(this,`utf16OffsetToUtf8`),St(this,`utf8OffsetToUtf16`),St(this,`ptr`),!Ct)throw new ht(`Must invoke loadWasm first.`);this._onigBinding=Ct,this.content=t;let n=new Tt(t);this.utf16Length=n.utf16Length,this.utf8Length=n.utf8Length,this.utf16OffsetToUtf8=n.utf16OffsetToUtf8,this.utf8OffsetToUtf16=n.utf8OffsetToUtf16,this.utf8Length<1e4&&!e._sharedPtrInUse?(e._sharedPtr||=Ct.omalloc(1e4),e._sharedPtrInUse=!0,Ct.HEAPU8.set(n.utf8Value,e._sharedPtr),this.ptr=e._sharedPtr):this.ptr=n.createString(Ct)}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)}};St(Et,`LAST_ID`,0),St(Et,`_sharedPtr`,0),St(Et,`_sharedPtrInUse`,!1);var Dt=Et,Ot=class{constructor(e){if(St(this,`_onigBinding`),St(this,`_ptr`),!Ct)throw new ht(`Must invoke loadWasm first.`);let t=[],n=[];for(let r=0,i=e.length;r<i;r++){let i=new Tt(e[r]);t[r]=i.createString(Ct),n[r]=i.utf8Length}let r=Ct.omalloc(4*e.length);Ct.HEAPU32.set(t,r/4);let i=Ct.omalloc(4*e.length);Ct.HEAPU32.set(n,i/4);let a=Ct.createOnigScanner(r,i,e.length);for(let n=0,r=e.length;n<r;n++)Ct.ofree(t[n]);Ct.ofree(i),Ct.ofree(r),a===0&&wt(Ct),this._onigBinding=Ct,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 Dt(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 kt(e){return typeof e.instantiator==`function`}function At(e){return typeof e.default==`function`}function jt(e){return e.data!==void 0}function Mt(e){return typeof Response<`u`&&e instanceof Response}function Nt(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 Pt;function Ft(e){if(Pt)return Pt;async function t(){Ct=await yt(async t=>{let n=e;return n=await n,typeof n==`function`&&(n=await n(t)),typeof n==`function`&&(n=await n(t)),kt(n)?n=await n.instantiator(t):At(n)?n=await n.default(t):(jt(n)&&(n=n.data),Mt(n)?n=typeof WebAssembly.instantiateStreaming==`function`?await Lt(n)(t):await Rt(n)(t):Nt(n)||n instanceof WebAssembly.Module?n=await It(n)(t):`default`in n&&n.default instanceof WebAssembly.Module&&(n=await It(n.default)(t))),`instance`in n&&(n=n.instance),`exports`in n&&(n=n.exports),n})}return Pt=t(),Pt}function It(e){return t=>WebAssembly.instantiate(e,t)}function Lt(e){return t=>WebAssembly.instantiateStreaming(e,t)}function Rt(e){return async t=>{let n=await e.arrayBuffer();return WebAssembly.instantiate(n,t)}}var zt;function Bt(e){zt=e}function Vt(){return zt}async function Ht(e){return e&&await Ft(e),{createScanner(e){return new Ot(e.map(e=>typeof e==`string`?e:e.source))},createString(e){return new Dt(e)}}}var Ut=rt({});at(Ut,mt);var Wt=class extends Error{constructor(e){super(e),this.name=`ShikiError`}},Gt=class extends Error{constructor(e){super(e),this.name=`ShikiError`}};function Kt(e){return qt(e)}function qt(e){return Array.isArray(e)?Jt(e):e instanceof RegExp?e:typeof e==`object`?Yt(e):e}function Jt(e){let t=[];for(let n=0,r=e.length;n<r;n++)t[n]=qt(e[n]);return t}function Yt(e){let t={};for(let n in e)t[n]=qt(e[n]);return t}function Xt(e,...t){return t.forEach(t=>{for(let n in t)e[n]=t[n]}),e}function Zt(e){let t=~e.lastIndexOf(`/`)||~e.lastIndexOf(`\\`);return t===0?e:~t===e.length-1?Zt(e.substring(0,e.length-1)):e.substr(~t+1)}var Qt=/\$(\d+)|\${(\d+):\/(downcase|upcase)}/g,$t=class{static hasCaptures(e){return e!==null&&(Qt.lastIndex=0,Qt.test(e))}static replaceCaptures(e,t,n){return e.replace(Qt,(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 en(e,t){return e<t?-1:+(e>t)}function tn(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=en(e[r],t[r]);if(n!==0)return n}return 0}return n-r}function nn(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 rn(e){return e.replace(/[\-\\\{\}\*\+\?\|\^\$\.\,\[\]\(\)\#\s]/g,`\\$&`)}var an=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}},on=class{constructor(e,t,n){this._colorMap=e,this._defaults=t,this._root=n}static createFromRawTheme(e,t){return this.createFromParsedTheme(dn(e),t)}static createFromParsedTheme(e,t){return mn(e,t)}_cachedMatchRoot=new an(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=>cn(e.parent,t.parentScopes));return n?new un(n.fontStyle,n.foreground,n.background):null}},sn=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||this.parent!==null&&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 cn(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&&!ln(e.scopeName,r);){if(i)return!1;e=e.parent}if(!e)return!1;e=e.parent}return!0}function ln(e,t){return t===e||e.startsWith(t)&&e[t.length]===`.`}var un=class{constructor(e,t,n){this.fontStyle=e,this.foregroundId=t,this.backgroundId=n}};function dn(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}}let s=null;typeof i.settings.foreground==`string`&&nn(i.settings.foreground)&&(s=i.settings.foreground);let c=null;typeof i.settings.background==`string`&&nn(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 fn(l,u,e,o,s,c)}}return n}var fn=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}},pn=(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))(pn||{});function mn(e,t){e.sort((e,t)=>{let n=en(e.scope,t.scope);return n!==0||(n=tn(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 hn(t),o=new un(n,a.getId(r),a.getId(i)),s=new vn(new _n(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 on(a,o,s)}var hn=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)}},gn=Object.freeze([]),_n=class e{scopeDepth;parentScopes;fontStyle;foreground;background;constructor(e,t,n,r,i){this.scopeDepth=e,this.parentScopes=t||gn,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)}},vn=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(),_n.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(tn(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 _n(e,t,n,r,i))}},yn=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)}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=xn(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 bn(e){return e}function xn(e){return e}function Sn(e,t){let n=[],r=wn(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(Cn(i)){let e=[];do e.push(i),i=r.next();while(Cn(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 Cn(e){return!!e&&!!e.match(/[\w\.:]+/)}function wn(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 Tn(e){typeof e.dispose==`function`&&e.dispose()}var En=class{constructor(e){this.scopeName=e}toKey(){return this.scopeName}},Dn=class{constructor(e,t){this.scopeName=e,this.ruleName=t}toKey(){return`${this.scopeName}#${this.ruleName}`}},On=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))}},kn=class{constructor(e,t){this.repo=e,this.initialScopeName=t,this.seenFullScopeRequests.add(this.initialScopeName),this.Q=[new En(this.initialScopeName)]}seenFullScopeRequests=new Set;seenPartialScopeRequests=new Set;Q;processQueue(){let e=this.Q;this.Q=[];let t=new On;for(let n of e)An(n,this.initialScopeName,this.repo,t);for(let e of t.references)if(e instanceof En){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 An(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 En?Mn({baseGrammar:a,selfGrammar:i},r):jn(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 En(e))}function jn(e,t,n){if(t.repository&&t.repository[e]){let r=t.repository[e];Nn([r],t,n)}}function Mn(e,t){e.selfGrammar.patterns&&Array.isArray(e.selfGrammar.patterns)&&Nn(e.selfGrammar.patterns,{...e,repository:e.selfGrammar.repository},t),e.selfGrammar.injections&&Nn(Object.values(e.selfGrammar.injections),{...e,repository:e.selfGrammar.repository},t)}function Nn(e,t,n){for(let r of e){if(n.visitedRule.has(r))continue;n.visitedRule.add(r);let e=r.repository?Xt({},t.repository,r.repository):t.repository;Array.isArray(r.patterns)&&Nn(r.patterns,{...t,repository:e},n);let i=r.include;if(!i)continue;let a=zn(i);switch(a.kind){case 0:Mn({...t,selfGrammar:t.baseGrammar},n);break;case 1:Mn(t,n);break;case 2:jn(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?jn(a.ruleName,i,n):Mn(i,n)}else a.kind===4?n.add(new Dn(a.scopeName,a.ruleName)):n.add(new En(a.scopeName))}}}var Pn=class{kind=0},Fn=class{kind=1},In=class{constructor(e){this.ruleName=e}kind=2},Ln=class{constructor(e){this.scopeName=e}kind=3},Rn=class{constructor(e,t){this.scopeName=e,this.ruleName=t}kind=4};function zn(e){if(e===`$base`)return new Pn;if(e===`$self`)return new Fn;let t=e.indexOf(`#`);return t===-1?new Ln(e):t===0?new In(e.substring(1)):new Rn(e.substring(0,t),e.substring(t+1))}var Bn=/\\(\d+)/,Vn=/\\(\d+)/g,Hn=-1,Un=-2;function Wn(e){return e}function Gn(e){return e}var Kn=class{$location;id;_nameIsCapturing;_name;_contentNameIsCapturing;_contentName;constructor(e,t,n,r){this.$location=e,this.id=t,this._name=n||null,this._nameIsCapturing=$t.hasCaptures(this._name),this._contentName=r||null,this._contentNameIsCapturing=$t.hasCaptures(this._contentName)}get debugName(){let e=this.$location?`${Zt(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:$t.replaceCaptures(this._name,e,t)}getContentName(e,t){return!this._contentNameIsCapturing||this._contentName===null?this._contentName:$t.replaceCaptures(this._contentName,e,t)}},qn=class extends Kn{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!`)}},Jn=class extends Kn{_match;captures;_cachedCompiledPatterns;constructor(e,t,n,r,i){super(e,t,n,null),this._match=new $n(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 er,this.collectPatterns(e,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},Yn=class extends Kn{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 er,this.collectPatterns(e,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},Xn=class extends Kn{_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 $n(i,this.id),this.beginCaptures=a,this._end=new $n(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 er;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}},Zn=class extends Kn{_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 $n(i,this.id),this.beginCaptures=a,this.whileCaptures=s,this._while=new $n(o,Un),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 er;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 er,this._cachedCompiledWhilePatterns.push(this._while.hasBackReferences?this._while.clone():this._while)),this._while.hasBackReferences&&this._cachedCompiledWhilePatterns.setSource(0,t||``),this._cachedCompiledWhilePatterns}},Qn=class e{static createCaptureRule(e,t,n,r,i){return e.registerRule(e=>new qn(t,e,n,r,i))}static getCompiledRuleId(t,n,r){return t.id||n.registerRule(i=>{if(t.id=i,t.match)return new Jn(t.$vscodeTextmateLocation,t.id,t.name,t.match,e._compileCaptures(t.captures,n,r));if(t.begin===void 0){t.repository&&(r=Xt({},r,t.repository));let i=t.patterns;return i===void 0&&t.include&&(i=[{include:t.include}]),new Yn(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,e._compilePatterns(i,n,r))}return t.while?new Zn(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 Xn(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=zn(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)}}}else s=e.getCompiledRuleId(o,n,r);if(s!==-1){let e=n.getRule(s),t=!1;if((e instanceof Yn||e instanceof Xn||e instanceof Zn)&&e.hasMissingPatterns&&e.patterns.length===0&&(t=!0),t)continue;i.push(s)}}return{patterns:i,hasMissingPatterns:(t?t.length:0)!==i.length}}},$n=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._anchorCache=this.hasAnchor?this._buildAnchorCache():null,this.ruleId=t,this.hasBackReferences=typeof this.source==`string`&&Bn.test(this.source)}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 Vn.lastIndex=0,this.source.replace(Vn,(e,t)=>rn(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}},er=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 tr(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 tr(e,this._items.map(e=>e.resolveAnchors(t,n)),this._items.map(e=>e.ruleId))}},tr=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(`
|
|
11
11
|
`)}findNextMatchSync(e,t,n){let r=this.scanner.findNextMatchSync(e,t,n);return r?{ruleId:this.rules[r.index],captureIndices:r.captureIndices}:null}},nr=class{constructor(e,t){this.languageId=e,this.tokenType=t}},rr=class e{_defaultAttributes;_embeddedLanguagesMatcher;constructor(e,t){this._defaultAttributes=new nr(e,8),this._embeddedLanguagesMatcher=new ir(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 nr(0,0);_getBasicScopeAttributes=new an(e=>new nr(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/},ir=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])=>rn(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 ar=class{constructor(e,t){this.stack=e,this.stoppedEarly=t}};function or(e,t,n,r,i,a,o,s){let c=t.content.length,l=!1,u=-1;if(o){let o=sr(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 ar(i,!0);f()}return new ar(i,!1);function f(){let o=cr(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===Hn){let o=i.getRule(e);a.produce(i,s[0].start),i=i.withContentNameScopesList(i.nameScopesList),pr(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 Xn){let r=o;pr(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 Zn){let r=o;pr(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(pr(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 sr(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 Zn&&s.push({rule:n,stack:t})}for(let c=s.pop();c;c=s.pop()){let{ruleScanner:s,findOptions:l}=fr(c.rule,e,c.stack.endRule,n,r===o),u=s.findNextMatchSync(t,r,l);if(u){if(u.ruleId!==Un){i=c.stack.pop();break}u.captureIndices&&u.captureIndices.length&&(a.produce(c.stack,u.captureIndices[0].start),pr(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 cr(e,t,n,r,i,a){let o=lr(e,t,n,r,i,a),s=e.getInjections();if(s.length===0)return o;let c=ur(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 lr(e,t,n,r,i,a){let{ruleScanner:o,findOptions:s}=dr(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 ur(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}=dr(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 dr(e,t,n,r,i){return{ruleScanner:e.compileAG(t,n,r,i),findOptions:0}}function fr(e,t,n,r,i){return{ruleScanner:e.compileWhileAG(t,n,r,i),findOptions:0}}function pr(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));or(e,p,n&&d.start===0,d.start,f,i,!1,0),Tn(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 mr(t,d.end))}}for(;l.length>0;)i.produceFromScopes(l[l.length-1].scopes,l[l.length-1].endPos),l.pop()}var mr=class{scopes;endPos;constructor(e,t){this.scopes=e,this.endPos=t}};function hr(e,t,n,r,i,a,o,s){return new yr(e,t,n,r,i,a,o,s)}function gr(e,t,n,r,i){let a=Sn(t,_r),o=Qn.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 _r(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(vr(t[r],e))return n=r+1,!0;return!1})}function vr(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 yr=class{constructor(e,t,n,r,i,a,o,s){if(this._rootScopeName=e,this.balancedBracketSelectors=a,this._onigLib=s,this._basicScopeAttributesProvider=new rr(n,r),this._rootId=-1,this._lastRuleId=0,this._ruleId2desc=[null],this._includedGrammars={},this._grammarRepository=o,this._grammar=br(t,null),this._injections=null,this._tokenTypeMatchers=[],i)for(let e of Object.keys(i)){let t=Sn(e,_r);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)gr(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&&gr(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(Wn(t));return this._ruleId2desc[t]=n,n}getRule(e){return this._ruleId2desc[Gn(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]=br(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=Qn.getCompiledRuleId(this._grammar.repository.$self,this,this._grammar.repository),this.getInjections());let i;if(!t||t===Sr.NULL){i=!0;let e=this._basicScopeAttributesProvider.getDefaultAttributes(),n=this.themeProvider.getDefaults(),r=yn.set(0,e.languageId,e.tokenType,null,n.fontStyle,n.foregroundId,n.backgroundId),a=this.getRule(this._rootId).getName(null,null),o;o=a?xr.createRootAndLookUpScopeName(a,r,this):xr.createRoot(`unknown`,r),t=new Sr(null,this._rootId,-1,-1,!1,null,o,o)}else i=!1,t.reset();e+=`
|
|
12
12
|
`;let a=this.createOnigString(e),o=a.content.length,s=new wr(n,e,this._tokenTypeMatchers,this.balancedBracketSelectors),c=or(this,a,i,0,t,s,!0,r);return Tn(a),{lineLength:o,lineTokens:s,ruleStack:c.stack,stoppedEarly:c.stoppedEarly}}};function br(e,t){return e=Kt(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 xr=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=sn.push(i,t.scopeNames),r=new e(r,i,t.encodedTokenAttributes);return r}static createRoot(t,n){return new e(null,new sn(null,t),n)}static createRootAndLookUpScopeName(t,n,r){let i=r.getMetadataForScope(t),a=new sn(null,t),o=r.themeProvider.themeMatch(a),s=e.mergeAttributes(n,i,o);return new e(null,a,s)}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),yn.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),s=e.mergeAttributes(t.tokenAttributes,i,o);return new e(t,a,s)}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}},Sr=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&&e._equals(this,t)}static _equals(e,t){return e===t?!0:this._structuralEquals(e,t)?xr.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:Gn(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=xr.fromExtension(t?.nameScopesList??null,n.nameScopesList);return new e(t,Wn(n.ruleId),n.enterPos??-1,n.anchorPos??-1,n.beginRuleCapturedEOL,n.endRule,r,xr.fromExtension(r,n.contentNameScopesList))}},Cr=class{balancedBracketScopes;unbalancedBracketScopes;allowAny=!1;constructor(e,t){this.balancedBracketScopes=e.flatMap(e=>e===`*`?(this.allowAny=!0,[]):Sn(e,_r).map(e=>e.matcher)),this.unbalancedBracketScopes=t.flatMap(e=>Sn(e,_r).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}},wr=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=yn.set(n,0,bn(e.type),null,-1,0,0));this.balancedBracketSelectors&&(r=this.balancedBracketSelectors.match(t))}if(r&&(n=yn.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}},Tr=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,hr(e,a,t,n,r,i,this,this._onigLib))}return this._grammars.get(e)}},Er=class{_options;_syncRegistry;_ensureGrammarCache;constructor(e){this._options=e,this._syncRegistry=new Tr(on.createFromRawTheme(e.theme,e.colorMap),e.onigLib),this._ensureGrammarCache=new Map}dispose(){this._syncRegistry.dispose()}setTheme(e,t){this._syncRegistry.setTheme(on.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 Cr(n.balancedBracketSelectors||[],n.unbalancedBracketSelectors||[]))}loadGrammar(e){return this._loadGrammar(e,0,null,null,null)}_loadGrammar(e,t,n,r,i){let a=new kn(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)}},Dr=Sr.NULL;function Or(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 kr(e,t){return e&&(t?.[e?.toLowerCase()]||e)}function Ar(e){return Array.isArray(e)?e:[e]}async function jr(e){return Promise.resolve(typeof e==`function`?e():e).then(e=>e.default||e)}function Mr(e){return!e||[`plaintext`,`txt`,`text`,`plain`].includes(e)}function Nr(e){return e===`ansi`||Mr(e)}function Pr(e){return e===`none`}function Fr(e){return Pr(e)}var Ir=/(\r?\n)/g;function Lr(e,t=!1){if(e.length===0)return[[``,0]];let n=e.split(Ir),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 Rr={light:`#333333`,dark:`#bbbbbb`},zr={light:`#fffffe`,dark:`#1e1e1e`},Br=`__shiki_resolved`;function Vr(e){if(e?.[Br])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`?Rr.light:Rr.dark,n||=t.type===`light`?zr.light:zr.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,Br,{enumerable:!1,writable:!1,value:!0}),t}async function Hr(e){return[...new Set((await Promise.all(e.filter(e=>!Nr(e)).map(async e=>await jr(e).then(e=>Array.isArray(e)?e:[e])))).flat())]}async function Ur(e){return(await Promise.all(e.map(async e=>Fr(e)?null:Vr(await jr(e))))).filter(e=>!!e)}function Wr(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 Gt(`Circular alias \`${[...n].join(` -> `)} -> ${e}\``);n.add(e)}}return e}var Gr=class extends Er{_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=Vr(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=on.createFromRawTheme(e),this._textmateThemeCache.set(e,t)),this._syncRegistry.setTheme(t)}getGrammar(e){return e=Wr(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 Gt(`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))}},Kr=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}},qr=0;function Jr(e){qr+=1,e.warnings!==!1&&qr>=10&&qr%10==0&&console.warn(`[Shiki] ${qr} 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 Gt("`engine` option is required for synchronous mode");let n=(e.langs||[]).flat(1),r=(e.themes||[]).flat(1).map(Vr),i=new Gr(new Kr(e.engine,n),r,n,e.langAlias),a;function o(t){return Wr(t,e.langAlias)}function s(e){g();let t=i.getGrammar(typeof e==`string`?e:e.name);if(!t)throw new Gt(`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 Gt(`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 Hr(e))}function m(...e){g();for(let t of e.flat(1))i.loadTheme(t)}async function h(...e){return g(),m(await Ur(e))}function g(){if(t)throw new Gt(`Shiki instance has been disposed`)}function _(){t||(t=!0,i.dispose(),--qr)}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 Yr(e){e.engine||console.warn("`engine` option is required. Use `createOnigurumaEngine` or `createJavaScriptRegexEngine` to create an engine.");let[t,n,r]=await Promise.all([Ur(e.themes||[]),Hr(e.langs||[]),e.engine]);return Jr({...e,themes:t,langs:n,engine:r})}var Xr=new WeakMap;function Zr(e,t){Xr.set(e,t)}function Qr(e){return Xr.get(e)}var $r=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(Ar(n).map(e=>[e,Dr])),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 ei(this._stacks[e])}toJSON(){return{lang:this.lang,theme:this.theme,themes:this.themes,scopes:this.getScopes()}}};function ei(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 ti(e,t){if(!(e instanceof $r))throw new Gt(`Invalid grammar state`);return e.getInternalStack(t)}var ni=/,/,ri=/ /;function ii(e,t,n={}){let{theme:r=e.getLoadedThemes()[0]}=n;if(Mr(e.resolveLangAlias(n.lang||`text`))||Pr(r))return Lr(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 Gt(`Grammar state language "${n.grammarState.lang}" does not match highlight language "${o.name}"`);if(!n.grammarState.themes.includes(i.name))throw new Gt(`Grammar state themes "${n.grammarState.themes}" do not contain highlight theme "${i.name}"`)}return oi(t,o,i,a,n)}function ai(...e){if(e.length===2)return Qr(e[1]);let[t,n,r={}]=e,{lang:i=`text`,theme:a=t.getLoadedThemes()[0]}=r;if(Mr(i)||Pr(a))throw new Gt(`Plain language does not have grammar state`);if(i===`ansi`)throw new Gt(`ANSI language does not have grammar state`);let{theme:o,colorMap:s}=t.setTheme(a),c=t.getLanguage(i);return new $r(si(n,c,o,s,r).stateStack,c.name,o.name)}function oi(e,t,n,r,i){let a=si(e,t,n,r,i),o=new $r(a.stateStack,t.name,n.name);return Zr(a.tokens,o),a.tokens}function si(e,t,n,r,i){let a=Or(n,i),{tokenizeMaxLineLength:o=0,tokenizeTimeLimit:s=500,includeExplanation:c=!1}=i,l=Lr(e),u=i.grammarState?ti(i.grammarState,n.name)??Dr:i.grammarContextCode==null?Dr:si(i.grammarContextCode,t,n,r,{...i,grammarState:void 0,grammarContextCode:void 0}).stateStack,d=[],f=[];for(let e=0,i=l.length;e<i;e++){let[i,p]=l[e];if(i===``){d=[],f.push([]);continue}if(o>0&&i.length>=o){d=[],f.push([{content:i,offset:p,color:``,fontStyle:0}]);continue}let m,h,g;c&&c!==`tokenType`&&(m=t.tokenizeLine(i,u,s),h=m.tokens,g=0);let _=t.tokenizeLine2(i,u,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]:i.length;if(t===o)continue;let s=_.tokens[2*e+1],l=kr(r[yn.getForeground(s)],a),u=yn.getFontStyle(s),f={content:i.substring(t,o),offset:p+t,color:l,fontStyle:u};if(c===`tokenType`)f.type=yn.getTokenType(s);else if(c){let e=[];if(c!==`scopeName`)for(let t of n.settings){let n;switch(typeof t.scope){case`string`:n=t.scope.split(ni).map(e=>e.trim());break;case`object`:n=t.scope;break;default:continue}e.push({settings:t,selectors:n.map(e=>e.split(ri))})}f.explanation=[];let r=0;for(;t+r<o;){let t=h[g],n=i.substring(t.startIndex,t.endIndex);r+=n.length,f.explanation.push({content:n,scopes:c===`scopeName`?ci(t.scopes):li(e,t.scopes)}),g+=1}}d.push(f)}f.push(d),d=[],u=_.ruleStack}return{tokens:f,stateStack:u}}function ci(e){return e.map(e=>({scopeName:e}))}function li(e,t){let n=[];for(let r=0,i=t.length;r<i;r++){let i=t[r];n[r]={scopeName:i,themeMatches:fi(e,i,t.slice(0,r))}}return n}function ui(e,t){return e===t||t.substring(0,e.length)===e&&t[e.length]===`.`}function di(e,t,n){if(!ui(e.at(-1),t))return!1;let r=e.length-2,i=n.length-1;for(;r>=0&&i>=0;)ui(e[r],n[i])&&--r,--i;return r===-1}function fi(e,t,n){let r=[];for(let{selectors:i,settings:a}of e)for(let e of i)if(di(e,t,n)){r.push(a);break}return r}function pi(e,t,n,r=ii){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:Qr(a),theme:typeof i.theme==`string`?i.theme:i.theme.name}}),o=mi(...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 $r(Object.fromEntries(a.map(e=>[e.theme,e.state?.getInternalStack(e.theme)])),a[0].state.lang):void 0;return c&&Zr(s,c),s}function mi(...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 hi=[`area`,`base`,`basefont`,`bgsound`,`br`,`col`,`command`,`embed`,`frame`,`hr`,`image`,`img`,`input`,`keygen`,`link`,`meta`,`param`,`source`,`track`,`wbr`],gi=class{constructor(e,t,n){this.normal=t,this.property=e,n&&(this.space=n)}};gi.prototype.normal={},gi.prototype.property={},gi.prototype.space=void 0;function _i(e,t){let n={},r={};for(let t of e)Object.assign(n,t.property),Object.assign(r,t.normal);return new gi(n,r,t)}function vi(e){return e.toLowerCase()}var yi=class{constructor(e,t){this.attribute=t,this.property=e}};yi.prototype.attribute=``,yi.prototype.booleanish=!1,yi.prototype.boolean=!1,yi.prototype.commaOrSpaceSeparated=!1,yi.prototype.commaSeparated=!1,yi.prototype.defined=!1,yi.prototype.mustUseProperty=!1,yi.prototype.number=!1,yi.prototype.overloadedBoolean=!1,yi.prototype.property=``,yi.prototype.spaceSeparated=!1,yi.prototype.space=void 0;var bi=s({boolean:()=>N,booleanish:()=>Si,commaOrSpaceSeparated:()=>Ti,commaSeparated:()=>wi,number:()=>P,overloadedBoolean:()=>Ci,spaceSeparated:()=>F}),xi=0,N=Ei(),Si=Ei(),Ci=Ei(),P=Ei(),F=Ei(),wi=Ei(),Ti=Ei();function Ei(){return 2**++xi}var Di=Object.keys(bi),Oi=class extends yi{constructor(e,t,n,r){let i=-1;if(super(e,t),ki(this,`space`,r),typeof n==`number`)for(;++i<Di.length;){let e=Di[i];ki(this,Di[i],(n&bi[e])===bi[e])}}};Oi.prototype.defined=!0;function ki(e,t,n){n&&(e[t]=n)}function Ai(e){let t={},n={};for(let[r,i]of Object.entries(e.properties)){let a=new Oi(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[vi(r)]=r,n[vi(a.attribute)]=r}return new gi(t,n,e.space)}var ji=Ai({properties:{ariaActiveDescendant:null,ariaAtomic:Si,ariaAutoComplete:null,ariaBusy:Si,ariaChecked:Si,ariaColCount:P,ariaColIndex:P,ariaColSpan:P,ariaControls:F,ariaCurrent:null,ariaDescribedBy:F,ariaDetails:null,ariaDisabled:Si,ariaDropEffect:F,ariaErrorMessage:null,ariaExpanded:Si,ariaFlowTo:F,ariaGrabbed:Si,ariaHasPopup:null,ariaHidden:Si,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:F,ariaLevel:P,ariaLive:null,ariaModal:Si,ariaMultiLine:Si,ariaMultiSelectable:Si,ariaOrientation:null,ariaOwns:F,ariaPlaceholder:null,ariaPosInSet:P,ariaPressed:Si,ariaReadOnly:Si,ariaRelevant:null,ariaRequired:Si,ariaRoleDescription:F,ariaRowCount:P,ariaRowIndex:P,ariaRowSpan:P,ariaSelected:Si,ariaSetSize:P,ariaSort:null,ariaValueMax:P,ariaValueMin:P,ariaValueNow:P,ariaValueText:null,role:null},transform(e,t){return t===`role`?t:`aria-`+t.slice(4).toLowerCase()}});function Mi(e,t){return t in e?e[t]:t}function Ni(e,t){return Mi(e,t.toLowerCase())}var Pi=Ai({attributes:{acceptcharset:`accept-charset`,classname:`class`,htmlfor:`for`,httpequiv:`http-equiv`},mustUseProperty:[`checked`,`multiple`,`muted`,`selected`],properties:{abbr:null,accept:wi,acceptCharset:F,accessKey:F,action:null,allow:null,allowFullScreen:N,allowPaymentRequest:N,allowUserMedia:N,alt:null,as:null,async:N,autoCapitalize:null,autoComplete:F,autoFocus:N,autoPlay:N,blocking:F,capture:null,charSet:null,checked:N,cite:null,className:F,cols:P,colSpan:null,content:null,contentEditable:Si,controls:N,controlsList:F,coords:P|wi,crossOrigin:null,data:null,dateTime:null,decoding:null,default:N,defer:N,dir:null,dirName:null,disabled:N,download:Ci,draggable:Si,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:N,formTarget:null,headers:F,height:P,hidden:Ci,high:P,href:null,hrefLang:null,htmlFor:F,httpEquiv:F,id:null,imageSizes:null,imageSrcSet:null,inert:N,inputMode:null,integrity:null,is:null,isMap:N,itemId:null,itemProp:F,itemRef:F,itemScope:N,itemType:F,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:N,low:P,manifest:null,max:null,maxLength:P,media:null,method:null,min:null,minLength:P,multiple:N,muted:N,name:null,nonce:null,noModule:N,noValidate:N,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:N,optimum:P,pattern:null,ping:F,placeholder:null,playsInline:N,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:N,referrerPolicy:null,rel:F,required:N,reversed:N,rows:P,rowSpan:P,sandbox:F,scope:null,scoped:N,seamless:N,selected:N,shadowRootClonable:N,shadowRootDelegatesFocus:N,shadowRootMode:null,shape:null,size:P,sizes:null,slot:null,span:P,spellCheck:Si,src:null,srcDoc:null,srcLang:null,srcSet:null,start:P,step:null,style:null,tabIndex:P,target:null,title:null,translate:null,type:null,typeMustMatch:N,useMap:null,value:Si,width:P,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:F,axis:null,background:null,bgColor:null,border:P,borderColor:null,bottomMargin:P,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:N,declare:N,event:null,face:null,frame:null,frameBorder:null,hSpace:P,leftMargin:P,link:null,longDesc:null,lowSrc:null,marginHeight:P,marginWidth:P,noResize:N,noHref:N,noShade:N,noWrap:N,object:null,profile:null,prompt:null,rev:null,rightMargin:P,rules:null,scheme:null,scrolling:Si,standby:null,summary:null,text:null,topMargin:P,valueType:null,version:null,vAlign:null,vLink:null,vSpace:P,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:N,disableRemotePlayback:N,prefix:null,property:null,results:P,security:null,unselectable:null},space:`html`,transform:Ni}),Fi=Ai({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`,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:Ti,accentHeight:P,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:P,amplitude:P,arabicForm:null,ascent:P,attributeName:null,attributeType:null,azimuth:P,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:P,by:null,calcMode:null,capHeight:P,className:F,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:P,diffuseConstant:P,direction:null,display:null,dur:null,divisor:P,dominantBaseline:null,download:N,dx:null,dy:null,edgeMode:null,editable:null,elevation:P,enableBackground:null,end:null,event:null,exponent:P,externalResourcesRequired:null,fill:null,fillOpacity:P,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:wi,g2:wi,glyphName:wi,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:P,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:P,horizOriginX:P,horizOriginY:P,id:null,ideographic:P,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:P,k:P,k1:P,k2:P,k3:P,k4:P,kernelMatrix:Ti,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:P,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:P,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:P,overlineThickness:P,paintOrder:null,panose1:null,path:null,pathLength:P,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:F,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:P,pointsAtY:P,pointsAtZ:P,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Ti,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Ti,rev:Ti,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Ti,requiredFeatures:Ti,requiredFonts:Ti,requiredFormats:Ti,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:P,specularExponent:P,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:P,strikethroughThickness:P,string:null,stroke:null,strokeDashArray:Ti,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:P,strokeOpacity:P,strokeWidth:null,style:null,surfaceScale:P,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Ti,tabIndex:P,tableValues:null,target:null,targetX:P,targetY:P,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Ti,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:P,underlineThickness:P,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:P,values:null,vAlphabetic:P,vMathematical:P,vectorEffect:null,vHanging:P,vIdeographic:P,version:null,vertAdvY:P,vertOriginX:P,vertOriginY:P,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:P,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:`svg`,transform:Mi}),Ii=Ai({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()}}),I=Ai({attributes:{xmlnsxlink:`xmlns:xlink`},properties:{xmlnsXLink:null,xmlns:null},space:`xmlns`,transform:Ni}),L=Ai({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:`xml`,transform(e,t){return`xml:`+t.slice(3).toLowerCase()}}),Li={classId:`classID`,dataType:`datatype`,itemId:`itemID`,strokeDashArray:`strokeDasharray`,strokeDashOffset:`strokeDashoffset`,strokeLineCap:`strokeLinecap`,strokeLineJoin:`strokeLinejoin`,strokeMiterLimit:`strokeMiterlimit`,typeOf:`typeof`,xLinkActuate:`xlinkActuate`,xLinkArcRole:`xlinkArcrole`,xLinkHref:`xlinkHref`,xLinkRole:`xlinkRole`,xLinkShow:`xlinkShow`,xLinkTitle:`xlinkTitle`,xLinkType:`xlinkType`,xmlnsXLink:`xmlnsXlink`},Ri=/[A-Z]/g,zi=/-[a-z]/g,Bi=/^data[-\w.:]+$/i;function Vi(e,t){let n=vi(t),r=t,i=yi;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)===`data`&&Bi.test(t)){if(t.charAt(4)===`-`){let e=t.slice(5).replace(zi,Ui);r=`data`+e.charAt(0).toUpperCase()+e.slice(1)}else{let e=t.slice(4);if(!zi.test(e)){let n=e.replace(Ri,Hi);n.charAt(0)!==`-`&&(n=`-`+n),t=`data`+n}}i=Oi}return new i(r,t)}function Hi(e){return`-`+e.toLowerCase()}function Ui(e){return e.charAt(1).toUpperCase()}var Wi=_i([ji,Pi,Ii,I,L],`html`),Gi=_i([ji,Fi,Ii,I,L],`svg`),Ki={}.hasOwnProperty;function qi(e,t){let n=t||{};function r(t,...n){let i=r.invalid,a=r.handlers;if(t&&Ki.call(t,e)){let n=String(t[e]);i=Ki.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 Ji=/["&'<>`]/g,Yi=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,Xi=/[\x01-\t\v\f\x0E-\x1F\x7F\x81\x8D\x8F\x90\x9D\xA0-\uFFFF]/g,Zi=/[|\\{}()[\]^$+*?.]/g,Qi=new WeakMap;function $i(e,t){if(e=e.replace(t.subset?ea(t.subset):Ji,r),t.subset||t.escapeOnly)return e;return e.replace(Yi,n).replace(Xi,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 ea(e){let t=Qi.get(e);return t||(t=ta(e),Qi.set(e,t)),t}function ta(e){let t=[],n=-1;for(;++n<e.length;)t.push(e[n].replace(Zi,`\\$&`));return RegExp(`(?:`+t.join(`|`)+`)`,`g`)}var na=/[\dA-Fa-f]/;function ra(e,t,n){let r=`&#x`+e.toString(16).toUpperCase();return n&&t&&!na.test(String.fromCharCode(t))?r:r+`;`}var ia=/\d/;function aa(e,t,n){let r=`&#`+String(e);return n&&t&&!ia.test(String.fromCharCode(t))?r:r+`;`}var oa=`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(`.`),sa={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:`€`},ca=[`cent`,`copy`,`divide`,`gt`,`lt`,`not`,`para`,`times`],la={}.hasOwnProperty,ua={},da;for(da in sa)la.call(sa,da)&&(ua[sa[da]]=da);var fa=/[^\dA-Za-z]/;function pa(e,t,n,r){let i=String.fromCharCode(e);if(la.call(ua,i)){let e=ua[i],a=`&`+e;return n&&oa.includes(e)&&!ca.includes(e)&&(!r||t&&t!==61&&fa.test(String.fromCharCode(t)))?a:a+`;`}return``}function ma(e,t,n){let r=ra(e,t,n.omitOptionalSemicolons),i;if((n.useNamedReferences||n.useShortestReferences)&&(i=pa(e,t,n.omitOptionalSemicolons,n.attribute)),(n.useShortestReferences||!i)&&n.useShortestReferences){let i=aa(e,t,n.omitOptionalSemicolons);i.length<r.length&&(r=i)}return i&&(!n.useShortestReferences||i.length<r.length)?i:r}function ha(e,t){return $i(e,Object.assign({format:ma},t))}var ga=/^>|^->|<!--|-->|--!>|<!-$/g,_a=[`>`],va=[`<`,`>`];function ya(e,t,n,r){return r.settings.bogusComments?`<?`+ha(e.value,Object.assign({},r.settings.characterReferences,{subset:_a}))+`>`:`<!--`+e.value.replace(ga,i)+`-->`;function i(e){return ha(e,Object.assign({},r.settings.characterReferences,{subset:va}))}}function ba(e,t,n,r){return`<!`+(r.settings.upperDoctype?`DOCTYPE`:`doctype`)+(r.settings.tightDoctype?``:` `)+`html>`}function xa(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 Sa(e,t){let n=t||{};return(e[e.length-1]===``?[...e,``]:e).join((n.padRight?` `:``)+`,`+(n.padLeft===!1?``:` `)).trim()}function Ca(e){return e.join(` `).trim()}var wa=/[ \t\n\f\r]/g;function Ta(e){return typeof e==`object`?e.type===`text`&&Ea(e.value):Ea(e)}function Ea(e){return e.replace(wa,``)===``}var Da=Aa(1),Oa=Aa(-1),ka=[];function Aa(e){return t;function t(t,n,r){let i=t?t.children:ka,a=(n||0)+e,o=i[a];if(!r)for(;o&&Ta(o);)a+=e,o=i[a];return o}}var ja={}.hasOwnProperty;function Ma(e){return t;function t(t,n,r){return ja.call(e,t.tagName)&&e[t.tagName](t,n,r)}}var Na=Ma({body:Ia,caption:Pa,colgroup:Pa,dd:Ba,dt:za,head:Pa,html:Fa,li:Ra,optgroup:Ha,option:Ua,p:La,rp:Va,rt:Va,tbody:Ga,td:Ja,tfoot:Ka,th:Ja,thead:Wa,tr:qa});function Pa(e,t,n){let r=Da(n,t,!0);return!r||r.type!==`comment`&&!(r.type===`text`&&Ta(r.value.charAt(0)))}function Fa(e,t,n){let r=Da(n,t);return!r||r.type!==`comment`}function Ia(e,t,n){let r=Da(n,t);return!r||r.type!==`comment`}function La(e,t,n){let r=Da(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 Ra(e,t,n){let r=Da(n,t);return!r||r.type===`element`&&r.tagName===`li`}function za(e,t,n){let r=Da(n,t);return!!(r&&r.type===`element`&&(r.tagName===`dt`||r.tagName===`dd`))}function Ba(e,t,n){let r=Da(n,t);return!r||r.type===`element`&&(r.tagName===`dt`||r.tagName===`dd`)}function Va(e,t,n){let r=Da(n,t);return!r||r.type===`element`&&(r.tagName===`rp`||r.tagName===`rt`)}function Ha(e,t,n){let r=Da(n,t);return!r||r.type===`element`&&r.tagName===`optgroup`}function Ua(e,t,n){let r=Da(n,t);return!r||r.type===`element`&&(r.tagName===`option`||r.tagName===`optgroup`)}function Wa(e,t,n){let r=Da(n,t);return!!(r&&r.type===`element`&&(r.tagName===`tbody`||r.tagName===`tfoot`))}function Ga(e,t,n){let r=Da(n,t);return!r||r.type===`element`&&(r.tagName===`tbody`||r.tagName===`tfoot`)}function Ka(e,t,n){return!Da(n,t)}function qa(e,t,n){let r=Da(n,t);return!r||r.type===`element`&&r.tagName===`tr`}function Ja(e,t,n){let r=Da(n,t);return!r||r.type===`element`&&(r.tagName===`td`||r.tagName===`th`)}var Ya=Ma({body:Qa,colgroup:$a,head:Za,html:Xa,tbody:eo});function Xa(e){let t=Da(e,-1);return!t||t.type!==`comment`}function Za(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 Qa(e){let t=Da(e,-1,!0);return!t||t.type!==`comment`&&!(t.type===`text`&&Ta(t.value.charAt(0)))&&(t.type!==`element`||t.tagName!==`meta`&&t.tagName!==`link`&&t.tagName!==`script`&&t.tagName!==`style`&&t.tagName!==`template`)}function $a(e,t,n){let r=Oa(n,t),i=Da(e,-1,!0);return n&&r&&r.type===`element`&&r.tagName===`colgroup`&&Na(r,n.children.indexOf(r),n)?!1:!!(i&&i.type===`element`&&i.tagName===`col`)}function eo(e,t,n){let r=Oa(n,t),i=Da(e,-1);return n&&r&&r.type===`element`&&(r.tagName===`thead`||r.tagName===`tbody`)&&Na(r,n.children.indexOf(r),n)?!1:!!(i&&i.type===`element`&&i.tagName===`tr`)}var to={name:[[`
|
|
13
13
|
\f\r &/=>`.split(``),`
|
|
@@ -1534,32 +1534,32 @@ diff --git`)}function sm(e,t){if(e.length===0)return[``];let n=`\n${t}`,r=e.star
|
|
|
1534
1534
|
`;if(t.endsWith(`
|
|
1535
1535
|
`))return`
|
|
1536
1536
|
`;if(t.endsWith(`\r`))return`\r`}return`
|
|
1537
|
-
`}function h_(e,t){return Math.max(e.additionLines.length,e.deletionLines.length)>t}function g_(e,t){return e.isPartial&&t&&(e.type===`change`||e.type===`rename-changed`)}function __(e,t){return e.lineNumber===t.lineNumber&&e.side===t.side&&e.metadata===t.metadata}function v_(e,t){return e.slotName===t.slotName&&e.hunkIndex===t.hunkIndex&&e.lines===t.lines&&e.lineCountKnown===t.lineCountKnown&&e.type===t.type&&e.expandable?.chunked===t.expandable?.chunked&&e.expandable?.up===t.expandable?.up&&e.expandable?.down===t.expandable?.down}function y_(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:bg(e),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,loadDiffFiles:e?.loadDiffFiles,collapsedContextThreshold:e?.collapsedContextThreshold,lineDiffType:e?.lineDiffType,maxLineDiffLength:e?.maxLineDiffLength,expansionLineCount:e?.expansionLineCount,headerRenderMode:e?.renderCustomHeader==null?`default`:`custom`}}function b_(e){return e.isPartial&&(e.type===`change`||e.type===`rename-changed`||e.type===`rename-pure`)}var x_=-1,S_=class{options;workerManager;isContainerManaged;static LoadedCustomComponent=!0;__id=`file-diff:${++x_}`;type=`file-diff`;fileContainer;spriteSVG;pre;codeUnified;codeDeletions;codeAdditions;bufferBefore;bufferAfter;themeCSSStyle;appliedThemeCSS;hasAdoptedThemeCSS=!1;unsafeCSSStyle;appliedUnsafeCSS;gutterUtilityContent;headerElement;headerPrefix;headerFilenameSuffix;headerMetadata;headerCustom;separatorCache=new Map;errorWrapper;placeHolder;hunksRenderer;resizeManager;scrollSyncManager;interactionManager;annotationCache=new Map;lineAnnotations=[];managersDirty=!1;deletionFile;additionFile;fileDiff;renderRange;pendingFiles;appliedPreAttributes;lastRenderedHeaderHTML;cachedHeaderHTML;lastRowCount;mounted=!1;enabled=!0;editor;refreshViewTimeout;lineStateRefreshPending=!1;deferredSelectedLines;deferredEditorActiveLine;constructor(e={theme:me},t,n=!1){this.options=e,this.workerManager=t,this.isContainerManaged=n,this.hunksRenderer=this.createHunksRenderer(e),this.resizeManager=new Ih,this.scrollSyncManager=new Gg,this.interactionManager=new gh(`diff`,_h(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 y_(e)}createHunksRenderer(e){return new e_(this.getHunksRendererOptions(e),this.handleHighlightRender,this.workerManager)}getLineIndex=(e,t=`additions`)=>{let n=this.fileDiffCache;if(n==null)return;let r=n.hunks.at(-1),i,a;hunkIterator:for(let o of n.hunks){let n=t===`deletions`?o.deletionStart:o.additionStart,s=t===`deletions`?o.deletionCount:o.additionCount,c=Ee(n,s)+1,l=o.splitLineStart,u=o.unifiedLineStart;if(e<c){let t=c-e;i=Math.max(u-t,0),a=Math.max(l-t,0);break hunkIterator}if(e>=c+s){if(o===r){let t=e-(c+s);i=u+o.unifiedLineCount+t,a=l+o.splitLineCount+t;break hunkIterator}continue}for(let n of o.hunkContent)if(n.type===`context`){if(e<c+n.lines){let t=e-c;a=l+t,i=u+t;break hunkIterator}c+=n.lines,l+=n.lines,u+=n.lines}else{let r=t===`deletions`?n.deletions:n.additions;if(e<c+r){let r=e-c;i=u+(t===`additions`?n.deletions:0)+r,a=l+r;break hunkIterator}c+=r,l+=Math.max(n.deletions,n.additions),u+=n.deletions+n.additions}break hunkIterator}if(i!=null&&a!=null)return[i,a]};setOptions(e){e!=null&&(this.options=e,this.cachedHeaderHTML=void 0,this.hunksRenderer.setOptions(this.getHunksRendererOptions(e)),this.syncInteractionOptions())}syncInteractionOptions(){this.interactionManager.setOptions(_h(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&&(this.applyThemeState(this.fileContainer,this.appliedThemeCSS.themeStyles,e,this.appliedThemeCSS.baseThemeType),!0)}hasThemeChanged(){return this.appliedThemeCSS!=null&&!Me(this.appliedThemeCSS.theme,this.options.theme??me)}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.lineStateRefreshPending?this.deferredSelectedLines=[e,t]:this.interactionManager.setSelection(e,t)}setEditorActiveLine(e,t){this.lineStateRefreshPending?this.deferredEditorActiveLine=[e,t]:this.interactionManager.setEditorActiveLine(e,{lineNumberOnly:t?.lineNumberOnly,side:t?.side??`additions`})}flushDeferredLineState(){let{deferredEditorActiveLine:e,deferredSelectedLines:t}=this;this.lineStateRefreshPending=!1,this.deferredEditorActiveLine=void 0,this.deferredSelectedLines=void 0,e!=null&&this.setEditorActiveLine(...e),t!=null&&this.interactionManager.setSelection(...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,{disableAnnotations:t===`wrap`,columnVariables:this.shouldApplyColumnVariables(t)?`apply`:`measure`}),t===`scroll`&&e===`split`?this.scrollSyncManager.setup(this.pre,this.codeDeletions,this.codeAdditions):this.scrollSyncManager.cleanUp(),this.managersDirty=!1}shouldApplyColumnVariables(e){return typeof this.options.hunkSeparators==`function`||e===`scroll`&&(this.lineAnnotations.length>0||this.pre?.hasAttribute(`data-has-merge-conflict`)===!0)}getCodeScrollLeft(){return Math.max(this.codeUnified?.scrollLeft??0,this.codeDeletions?.scrollLeft??0,this.codeAdditions?.scrollLeft??0)}setCodeScrollLeft(e){this.codeUnified!=null&&(this.codeUnified.scrollLeft=e),this.codeAdditions!=null&&(this.codeAdditions.scrollLeft=e),this.codeDeletions!=null&&(this.codeDeletions.scrollLeft=e)}__getEffectiveCodeOptions(){return{...this.options,...this.hunksRenderer.getEffectiveCodeOptions()}}cleanUp(e=!1){Cp(this.handleEditSessionRender),this.emitPostRender(!0),this.editor?.cleanUp(e),this.editor=void 0,this.resizeManager.cleanUp(),this.interactionManager.cleanUp(),this.scrollSyncManager.cleanUp(),this.managersDirty=!1,this.workerManager?.unsubscribeToThemeChanges(this),this.renderRange=void 0,this.pendingFiles=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?.remove(),this.bufferBefore=void 0,this.bufferAfter?.remove(),this.bufferAfter=void 0,this.appliedPreAttributes=void 0,this.headerElement=void 0,this.headerPrefix=void 0,this.headerFilenameSuffix=void 0,this.headerMetadata=void 0,this.headerCustom=void 0,this.placeHolder?.remove(),this.placeHolder=void 0,this.lastRenderedHeaderHTML=void 0,e||(this.cachedHeaderHTML=void 0),this.errorWrapper?.remove(),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.refreshViewTimeout!=null&&(clearTimeout(this.refreshViewTimeout),this.refreshViewTimeout=void 0),this.lineStateRefreshPending=!1,this.deferredEditorActiveLine=void 0,this.deferredSelectedLines=void 0,this.enabled=!1}virtualizedSetup(){this.enabled=!0,this.workerManager?.subscribeToThemeChanges(this)}hydrate({fileContainer:e,prerenderedHTML:t,preventEmit:n=!1,lineAnnotations:r,fileDiff:i,...a}){if(!this.enabled)throw Error(`FileDiff.hydrate: attempting to call hydrate after cleaned up`);if(this.fileContainer!=null)throw Error(`FileDiff.hydrate: hydrate can only be called before the instance has rendered or hydrated`);let o=Ng(a,`FileDiff.hydrate`),s=o?.oldFile,c=o?.newFile;this.hydrateElements(e,t),E_(this.pre,w_({fileDiff:i,oldFile:s,newFile:c}),this.options.collapsed)||D_(this.headerElement,T_({fileDiff:i,oldFile:s,newFile:c}),this.options.disableFileHeader)?this.render({...a,fileContainer:e,lineAnnotations:r,fileDiff:i,preventEmit:!0}):this.hydrationSetup({fileDiff:i,lineAnnotations:r,...o}),n||this.emitPostRender()}hydrateElements(e,t){this.fileContainer!==e&&this.emitPostRender(!0),Dg(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!==void 0&&n!==void 0?mm(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.loadFilesIfNecessary(),this.rerender()};loadFilesIfNecessary(){let{fileDiff:e,options:{loadDiffFiles:t}}=this;e==null||t==null||!b_(e)||this.pendingFiles?.fileDiff===e||(this.pendingFiles={fileDiff:e,promise:this.loadFilesForDiff(e,t)})}async loadFilesForDiff(e,t){try{let n=await t(e);if(!this.enabled||this.fileDiff!==e)return;await this.handleFilesLoaded(e,n)}catch(e){if(this.options.disableErrorHandling===!0)throw e;console.error(e)}finally{this.pendingFiles?.fileDiff===e&&(this.pendingFiles=void 0)}}async handleFilesLoaded(e,t){this.fileDiff!==e||!e.isPartial||(Ig(`merge`,e,t),this.setHydratedState(t),await kg(()=>this.primeHighlightCache(e)),!(!this.enabled||this.fileDiff!==e)&&this.rerender())}setHydratedState(e){this.deletionFile=e.oldFile,this.additionFile=e.newFile,this.workerManager?.cleanUpTasks(this.hunksRenderer),this.hunksRenderer.clearRenderCache()}render({fileDiff:e,deferManagers:t=!1,forceRender:n=!1,preventEmit:r=!1,lineAnnotations:i,fileContainer:a,containerWrapper:o,renderRange:s,...c}){let l=Ng(c,`FileDiff.render`),u=l?.oldFile,d=l?.newFile;if(!this.enabled)throw Error(`FileDiff.render: attempting to call render after cleaned up`);e!=null&&e.cacheKey===void 0&&(e.cacheKey=e.prevName==null?e.name:e.prevName+`:`+e.name),this.editor?.__postponeBgTokenizeToNextFrame();let{collapsed:f=!1,themeType:p=`system`,expandUnchanged:m=!1}=this.options,h=f?void 0:s,g=this.hasThemeChanged(),_=l!=null,v=_&&(!C_(u,this.deletionFile)||!C_(d,this.additionFile)),y=e!=null&&e!==this.fileDiff,b=i!=null&&(i.length>0||this.lineAnnotations.length>0)&&i!==this.lineAnnotations;if(!f&&Wh(h,this.renderRange)&&!n&&!b&&!g&&(e!=null&&e===this.fileDiff||e==null&&!v))return this.applyCachedThemeState(p);let x;e==null&&_&&(v||this.fileDiff==null)&&(x=mm(l.oldFile,l.newFile,this.options.parseDiffOptions));let{renderRange:S}=this;if(this.renderRange=h,_?(this.deletionFile=u,this.additionFile=d):e!=null&&(this.deletionFile=void 0,this.additionFile=void 0),e==null?x!=null&&(y=!0,this.fileDiff=x):this.fileDiff=e,y&&(this.cachedHeaderHTML=void 0),i!=null&&this.setLineAnnotations(i),this.fileDiff==null)return!1;this.fileDiff.editSessionDirty===!0&&this.shouldSelfHealEditSession()&&(Km(this.fileDiff,this.options.parseDiffOptions),this.hunksRenderer.refreshHighlightedResult()),m&&this.loadFilesIfNecessary(),this.hunksRenderer.setOptions(this.getHunksRendererOptions(this.options)),this.syncInteractionOptions(),this.hunksRenderer.setLineAnnotations(this.lineAnnotations);let{disableErrorHandling:C=!1,disableFileHeader:w=!1}=this.options;if(w&&(this.headerElement!=null&&(this.headerElement.remove(),this.headerElement=void 0,this.lastRenderedHeaderHTML=void 0),this.clearHeaderSlots()),a=this.getOrCreateFileContainer(a,o),this.applyCachedThemeState(p),f){this.removeRenderedCode(),this.clearAuxiliaryNodes();try{let e=this.hunksRenderer.renderDiff(this.fileDiff,Ce);e!=null&&this.applyThemeState(a,e.themeStyles,p,e.baseThemeType),e?.headerElement!=null&&this.applyHeaderToDOM(e.headerElement,a),this.renderSeparators([]),this.injectUnsafeCSS()}catch(e){if(C)throw e;console.error(e),e instanceof Error&&this.applyErrorToDOM(e,a)}return r||this.emitPostRender(),!0}try{let e=this.getOrCreatePreNode(a);if(!(this.canPartiallyRender(n,b,v||y||g)&&this.applyPartialRender({previousRenderRange:S,renderRange:h}))){let t=this.hunksRenderer.renderDiff(this.fileDiff,h);if(t==null)return this.workerManager?.isInitialized()===!1&&this.workerManager.initialize().then(()=>this.rerender()),!1;this.applyThemeState(a,t.themeStyles,p,t.baseThemeType),t.headerElement!=null&&this.applyHeaderToDOM(t.headerElement,a),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,h),this.injectUnsafeCSS(),this.renderAnnotations(),this.renderGutterUtility(),this.managersDirty=!0,t||this.flushManagers(),this.editor!=null&&this.syncRenderViewToEditor()}catch(e){if(C)throw e;console.error(e),e instanceof Error&&this.applyErrorToDOM(e,a)}return r||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)}get fileDiffCache(){return this.hunksRenderer.diffCache??this.fileDiff}syncRenderViewToEditor(){let e=this.editor,t=this.fileContainer,n=this.fileDiffCache,r=this.lineAnnotations,i=this.computeEditorRenderRange(this.renderRange);e!=null&&t!=null&&n!=null&&!n.isPartial&&this.hunksRenderer.initializeHighlighter().then(a=>{!this.enabled||this.editor!==e||this.fileContainer!==t||this.fileDiffCache!==n||e.__syncRenderView(a,t,n,r,i)})}computeEditorRenderRange(e){let t=this.fileDiffCache;if(e==null||t==null||Kg(e))return e;let{diffStyle:n=`split`,expandUnchanged:r=!1,collapsedContextThreshold:i=1}=this.options,a,o;return wf({diff:t,diffStyle:n,startingLine:e.startingLine,totalLines:e.totalLines,expandedHunks:r?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:i,callback:({additionLine:e})=>{e!=null&&(a??=e.lineNumber,o=e.lineNumber)}}),a==null||o==null?{...e,startingLine:0,totalLines:0}:{...e,startingLine:a-1,totalLines:o-a+1}}attachEditor(e){if(this.type!==`file-diff`)throw Error(`FileDiff.attachEditor: cannot attach an editor to a "${this.type}" diff`);return this.editor?.cleanUp(),this.editor=e,this.hunksRenderer.beginEditSession(),this.fileDiff?.isPartial===!0&&this.loadFilesIfNecessary(),this.hunksRenderer.editorRenderReady()?this.syncRenderViewToEditor():this.rerender(),e=>{this.editor=void 0,e!==!0&&this.finishEditSession()}}finishEditSession(){this.hunksRenderer.endEditSession(),this.completeEditSession()}completeEditSession(){let e=this.fileDiffCache;if(e==null||e.editSessionDirty!==!0)return!1;let{collapsedContextThreshold:t=1}=this.options,n=Wm(e,this.hunksRenderer.getExpandedHunksMap(),t);return Km(e,this.options.parseDiffOptions),this.hunksRenderer.setExpandedHunksMap(Gm(e,n)),this.hunksRenderer.refreshHighlightedResult(),this.escalateEditSessionRender(),!0}applyDocumentChange(e,t){this.hunksRenderer.applyDocumentChange(e);let n=this.hunksRenderer.diffCache;if(n!=null){let e=this.fileDiff?.cacheKey;e!=null&&n.cacheKey==null&&(n.cacheKey=e),this.fileDiff=n}t!==void 0&&t!==this.lineAnnotations&&(this.setLineAnnotations(t),this.hunksRenderer.setLineAnnotations(this.lineAnnotations),this.renderAnnotations()),this.rerender(),this.interactionManager.setSelectionDirty()}updateRenderCache(e,t,n={}){let{shouldRefreshDiffsView:r,lineCountChangeInFlight:i}=n;if(this.hunksRenderer.updateRenderCache(e,t,i)){this.refreshViewTimeout!=null&&(clearTimeout(this.refreshViewTimeout),this.refreshViewTimeout=void 0),this.lineStateRefreshPending=!0,this.escalateEditSessionRender();return}r===!0&&(this.refreshViewTimeout!=null&&clearTimeout(this.refreshViewTimeout),this.lineStateRefreshPending=!0,this.refreshViewTimeout=setTimeout(()=>{this.refreshViewTimeout=void 0,this.options.diffStyle===`split`?this.refreshSplitDiffView():this.refreshUnifiedDiffView(),this.flushDeferredLineState()},150))}isLineRenderable(e){let t=this.fileDiffCache;if(t==null)return!0;let{expandUnchanged:n=!1,collapsedContextThreshold:r=1}=this.options;return gf({fileDiff:t,lineNumber:e,expandedHunks:n?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:r})}getNearestRenderableLine(e,t){let n=this.fileDiffCache;if(n==null)return e;let{expandUnchanged:r=!1,collapsedContextThreshold:i=1}=this.options;return _f({fileDiff:n,lineNumber:e,direction:t,expandedHunks:r?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:i})}revealLine(e){let t=this.fileDiffCache,{expandUnchanged:n=!1,collapsedContextThreshold:r=1,expansionLineCount:i=100}=this.options;if(t==null||t.isPartial||n)return!1;let a=this.hunksRenderer.getExpandedHunksMap();for(let[n,o]of t.hunks.entries()){let[s,c]=df(o);if(e<s){let c=ff({isPartial:t.isPartial,rangeSize:o.collapsedBefore,expandedHunks:a,hunkIndex:n,collapsedContextThreshold:r}),l=s-c.rangeSize;if(c.renderAll||e<l+c.fromStart||e>=s-c.fromEnd)return!1;let u=e-(l+c.fromStart)+1,d=s-c.fromEnd-e;return u<=d?this.expandHunk(n,`up`,u+i):this.expandHunk(n,`down`,d+i),!0}if(e<c)return!1}let o=hf({fileDiff:t,hunkIndex:t.hunks.length-1,expandedHunks:a,collapsedContextThreshold:r,errorPrefix:`FileDiff.revealLine`});if(o==null||o.renderAll)return!1;let s=t.hunks[t.hunks.length-1],[,c]=df(s);return e<c+o.fromStart||e>=c+o.rangeSize?!1:(this.expandHunk(t.hunks.length,`up`,e-(c+o.fromStart)+1+i),!0)}shouldSelfHealEditSession(){return this.editor==null}escalateEditSessionRender(){Sp(this.handleEditSessionRender)}handleEditSessionRender=()=>{this.rerender(),this.flushDeferredLineState()};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}async primeHighlightCache(e=this.fileDiff){let{workerManager:t}=this;if(e==null||t==null||!t.isWorkingPool()||e.cacheKey==null||rf(e))return;let n=this.options.tokenizeMaxLength??1e5;Math.max(e.additionLines.length,e.deletionLines.length)>n||await t.primeDiffHighlightCache(e).catch(e=>{console.error(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.headerFilenameSuffix?.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.headerFilenameSuffix=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||!v_(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}-${we(r)}`,a=this.annotationCache.get(i);if(a==null||!__(r,a.annotation)){a?.element.remove();let e=t(r);if(e==null)continue;a={element:sg(we(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=cg();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 n!=null&&i&&this.editor?.__captureFocusForDOMReplacement(),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:ch(e)&&e.hasAttribute(`data-theme-css`)?(this.themeCSSStyle??=e,this.hasAdoptedThemeCSS=!0):ch(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=rg;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&&(this.editor?.__captureFocusForDOMReplacement(),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??R(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,renderHeaderFilenameSuffix:o,renderHeaderMetadata:s}=this.options;if(i!=null){let e=i(n)??void 0;this.headerCustom=this.upsertHeaderSlotElement(t,this.headerCustom,pe,e),this.headerPrefix?.remove(),this.headerFilenameSuffix?.remove(),this.headerMetadata?.remove(),this.headerPrefix=void 0,this.headerFilenameSuffix=void 0,this.headerMetadata=void 0;return}let c=a?.(n)??void 0,l=o?.(n)??void 0,u=s?.(n)??void 0;this.headerPrefix=this.upsertHeaderSlotElement(t,this.headerPrefix,de,c),this.headerFilenameSuffix=this.upsertHeaderSlotElement(t,this.headerFilenameSuffix,j,l),this.headerMetadata=this.upsertHeaderSlotElement(t,this.headerMetadata,fe,u),this.headerCustom?.remove(),this.headerCustom=void 0}clearHeaderSlots(){this.headerPrefix?.remove(),this.headerFilenameSuffix?.remove(),this.headerMetadata?.remove(),this.headerCustom?.remove(),this.headerPrefix=void 0,this.headerFilenameSuffix=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??=lg(),this.unsafeCSSStyle.parentNode!==t&&t.appendChild(this.unsafeCSSStyle),this.unsafeCSSStyle.textContent=gg(e),this.appliedUnsafeCSS=e)}}applyThemeState(e,t,n,r){let i=e.shadowRoot??e.attachShadow({mode:`open`}),a=r??n,o=this.options.theme??me,s=typeof o==`string`?o:{...o},c=dg(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=Cg({shadowRoot:i,currentNode:this.themeCSSStyle,themeCSS:_g(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=vg(this.themeCSSStyle.textContent??``,dg(e)))}shouldGuardRebuildScroll(){return this.editor!=null&&Eg()}applyHunksToDOM(e,t){this.shouldGuardRebuildScroll()?Sg(e,()=>this.replaceCodeColumns(e,t)):this.replaceCodeColumns(e,t)}applyCodeColumnsInPlace(e,t,n){let r=this.getColumnPair(e);if(r==null)return!1;let i=O_(t[0]),a=O_(t[1]);return i==null||a==null?!1:(r.gutter.innerHTML=R(i),r.content.innerHTML=R(a),n!==this.lastRowCount&&(r.gutter.style.setProperty(`grid-row`,`span ${n}`),r.content.style.setProperty(`grid-row`,`span ${n}`)),!0)}replaceCodeColumns(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);this.editor?.__captureFocusForDOMReplacement(),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=xg({code:this.codeDeletions,columnType:`deletions`,rowSpan:i,containerSize:r}),this.applyCodeColumnsInPlace(this.codeDeletions,c,t.rowCount)||(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=xg({code:this.codeAdditions,columnType:`additions`,rowSpan:i,containerSize:r}),this.applyCodeColumnsInPlace(this.codeAdditions,l,t.rowCount)||(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=xg({code:this.codeUnified,columnType:`unified`,rowSpan:i,containerSize:r}),this.applyCodeColumnsInPlace(this.codeUnified,s,t.rowCount)||(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(`FileDiff.applyPartialRender: failed to trim to overlap`);if(this.lastRowCount<g)throw Error(`FileDiff.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`)}refreshSplitDiffView(){if(this.options.diffStyle!==`split`)return;let e=this.hunksRenderer.renderDiff(this.fileDiff,this.renderRange);if(e==null)return;let t=this.getCodeColumns(`split`,this.codeUnified,this.codeDeletions,this.codeAdditions);if(!Array.isArray(t))return;let n=(t,n)=>{if(n==null)return;let r=this.hunksRenderer.renderCodeAST(t,e),i=O_(r?.[0]),a=O_(r?.[1]);for(let[e,t]of[[n.gutter,i],[n.content,a]])if(t!=null&&e.childElementCount===t.length)for(let n=0;n<t.length;n++){let r=e.children[n],i=t[n].properties[`data-line-type`];i!=null&&r.dataset.lineType!==i&&(r.dataset.lineType=i)}};n(`deletions`,t[0]),n(`additions`,t[1])}refreshUnifiedDiffView(){if(this.options.diffStyle!==`unified`)return;let e=this.hunksRenderer.renderDiff(this.fileDiff,this.renderRange);if(e==null)return;let t=this.getCodeColumns(`unified`,this.codeUnified,this.codeDeletions,this.codeAdditions);if(t==null||Array.isArray(t))return;let n=this.hunksRenderer.renderCodeAST(`unified`,e),r=O_(n?.[0]),i=O_(n?.[1]),a=()=>{for(let[e,n]of[[t.gutter,r],[t.content,i]])n!=null&&(e.innerHTML=R(n));e.rowCount!==this.lastRowCount&&(this.applyRowSpan(`unified`,t,e.rowCount),this.lastRowCount=e.rowCount)};this.shouldGuardRebuildScroll()?Sg(this.pre,a):a(),this.renderSeparators(e.hunkData),this.managersDirty=!0,this.flushManagers(),this.syncRenderViewToEditor()}renderPartialColumn(e,t,n){if(e==null||t==null)return;let r=O_(t[0]),i=O_(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}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)`)}getColumnPair(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}}getCodeColumns(e,t,n,r){if(e===`unified`)return this.getColumnPair(t);{let e=this.getColumnPair(n),t=this.getColumnPair(r);return e!=null||t!=null?[e,t]:void 0}}updateBuffers(e){this.pre!=null&&this.applyBuffers(this.pre,e)}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`&&t!=null&&n!=null,totalLines:r,customProperties:i};ig(u,this.appliedPreAttributes)||(Og(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 C_(e,t){return e==null||t==null?e==null&&t==null:Ne(e,t)}function w_({fileDiff:e,oldFile:t,newFile:n}){return e!=null&&e.hunks.length>0||t!=null||n!=null}function T_({fileDiff:e,oldFile:t,newFile:n}){return e!=null||t!=null||n!=null}function E_(e,t,n=!1){return!n&&e==null&&t}function D_(e,t,n=!1){return e==null&&t&&!n}function O_(e){if(e!=null&&e.type===`element`)return e.children??[]}var k_=3e3,A_=-1,j_=class extends S_{__id=`little-virtualized-file-diff:${++A_}`;top;height=0;metrics;cache={heightDeltas:new Map,measuredHeightDeltaTotal:0,estimatedSplitHeight:void 0,estimatedUnifiedHeight:void 0,checkpoints:[],totalLines:0,fileAnnotationHeight:0};isVisible=!1;isSetup=!1;virtualizer;layoutDirty=!0;forceRenderOverride;currentCollapsed;currentExpandUnchanged;pendingHydratedDiff;pendingExpansions;constructor(e,t,n,r,i=!1){super(e,r,i),this.virtualizer=t,this.metrics=of(n)}setMetrics(e,t=!1){let n=of(e);!t&&_p(this.metrics,n)||(this.metrics=n,this.resetLayoutCache({includeEstimatedHeights:!0}))}setLineAnnotations(e){this.syncLineAnnotations(e)&&this.resetLayoutCache({includeEstimatedHeights:!1})}syncLineAnnotations(e){return e==null||e===this.lineAnnotations||e.length===0&&this.lineAnnotations.length===0?!1:(super.setLineAnnotations(e),!0)}setFileAnnotationHeight(e){let t=this.cache.fileAnnotationHeight;return e!==t&&(this.cache.fileAnnotationHeight=e,this.cache.measuredHeightDeltaTotal+=e-t,!0)}hasFileAnnotations(e=this.fileDiff){return e==null||!uh(this.lineAnnotations)?!1:this.lineAnnotations.some(t=>t.lineNumber===0?e.type===`new`?t.side===`additions`:e.type!==`deleted`||t.side===`deletions`:!1)}getLineHeight(e,t=!1){return this.getEstimatedLineHeight(t)+(this.cache.heightDeltas.get(e)??0)}getEstimatedLineHeight(e=!1){let t=e?2:1;return this.metrics.lineHeight*t}setOptions(e){if(this.isAdvancedMode())throw Error(`VirtualizedFileDiff.setOptions cannot be used inside CodeView. Update CodeView options instead.`);if(e==null)return;let{options:t}=this,n=!vp(t,e),r=n&&z_(t,e);super.setOptions(e),r&&this.resetLayoutCache({forceSimpleRecompute:!0,includeEstimatedHeights:B_(t,e)}),n&&(this.forceRenderOverride=!0),n&&this.isSimpleMode()&&this.virtualizer.instanceChanged(this,r)}setThemeType(e){if(this.isAdvancedMode())throw Error(`VirtualizedFileDiff.setThemeType cannot be used inside CodeView. Update CodeView options instead.`);super.setThemeType(e)}resetLayoutCache({forceSimpleRecompute:e=!1,includeEstimatedHeights:t=!1,resetRenderRange:n=!0}={}){this.layoutDirty=!0,this.cache.fileAnnotationHeight=0,this.cache.heightDeltas.size>0&&this.cache.heightDeltas.clear(),this.cache.measuredHeightDeltaTotal!==0&&(this.cache.measuredHeightDeltaTotal=0),this.invalidateDerivedLayoutCache(t,n),e&&this.isSimpleMode()&&this.computeApproximateSize()}invalidateDerivedLayoutCache(e,t=!0){this.layoutDirty=!0,this.cache.checkpoints.length>0&&(this.cache.checkpoints.length=0),this.cache.totalLines!==0&&(this.cache.totalLines=0),e&&(this.cache.estimatedSplitHeight=void 0,this.cache.estimatedUnifiedHeight=void 0),this.renderRange!=null&&t&&(this.renderRange=void 0)}reconcileHeights(){let e=!1,{overflow:t=`scroll`}=this.options;if(this.fileContainer==null||this.fileDiff==null)return this.height!==0&&(e=!0),this.height=0,e;if(this.top=this.getVirtualizedTop(),t===`scroll`&&this.lineAnnotations.length===0&&!this.isResizeDebuggingEnabled())return e;let n=this.getDiffStyle(),r=n===`split`?[this.codeDeletions,this.codeAdditions]:[this.codeUnified],i=this.hasFileAnnotations(this.fileDiff);if(this.renderRange!=null&&i&&fh(this.renderRange)){let t=M_(r)??0;this.setFileAnnotationHeight(t)&&(e=!0)}else!i&&this.setFileAnnotationHeight(0)&&(e=!0);for(let t of r){if(t==null)continue;let r=t.children[1];if(r instanceof HTMLElement)for(let t of r.children){if(!(t instanceof HTMLElement))continue;let r=t.dataset.lineIndex;if(r==null)continue;let i=W_(r,n),a=t.getBoundingClientRect().height,o=!1;t.nextElementSibling instanceof HTMLElement&&(`lineAnnotation`in t.nextElementSibling.dataset||`noNewline`in t.nextElementSibling.dataset)&&(`noNewline`in t.nextElementSibling.dataset&&(o=!0),a+=t.nextElementSibling.getBoundingClientRect().height);let s=this.getEstimatedLineHeight(o),c=this.cache.heightDeltas.get(i)??0,l=a-s;l!==c&&(e=!0,this.cache.measuredHeightDeltaTotal+=l-c,l===0?this.cache.heightDeltas.delete(i):this.cache.heightDeltas.set(i,l))}}return(e||this.isResizeDebuggingEnabled())&&this.computeApproximateSize(!0),e}onRender=e=>this.fileContainer!=null&&(e&&(this.top=this.getVirtualizedTop()),this.render());flushManagers(){super.flushManagers(),this.lineStateRefreshPending&&this.flushDeferredLineState()}prepareCodeViewItem(e,t,n,r){let i=!tf(this.fileDiff,e),a=this.syncLineAnnotations(r),o=n?.resetDiffLayoutCache===!0||i||a,s=i||n?.resetDiffLayoutCache===!0&&n.includeEstimatedDiffHeights;n?.metrics!=null&&(this.metrics=of(n.metrics),o=!0,s=!0);let{collapsed:c=!1,expandUnchanged:l=!1}=this.options;return this.currentCollapsed!==c&&(this.currentCollapsed=c,o=!0),this.currentExpandUnchanged!==l&&(this.currentExpandUnchanged=l,o=!0,s=!0),o&&this.resetLayoutCache({includeEstimatedHeights:s}),this.fileDiff=e,this.top=t,this.computeApproximateSize(),this.height}getLinePosition(e,t=`additions`){if(this.fileDiff==null||e<1)return;let n=this.getLineIndex(e,t);if(n==null)return;let{disableFileHeader:r=!1,expandUnchanged:i=!1,collapsed:a=!1,collapsedContextThreshold:o=1}=this.options,s=this.getDiffStyle(),c=this.getHunkSeparatorType(),l=s===`split`?n[1]:n[0];this.approximateLayoutCheckpoints();let u=sf(this.metrics,r),d=this.getLayoutCheckpointBeforeLineIndex(l),f=d?.top??u+this.cache.fileAnnotationHeight;if(a)return{top:u,height:0};let p;return wf({diff:this.fileDiff,diffStyle:s,startingLine:d?.renderedLineIndex??0,expandedHunks:i?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:o,callback:({hunkIndex:e,hunk:t,collapsedBefore:n,collapsedAfter:r,deletionLine:i,additionLine:a})=>{let o=s===`split`?a?.splitLineIndex??i?.splitLineIndex:a?.unifiedLineIndex??i?.unifiedLineIndex;if(o==null)throw Error(`VirtualizedFileDiff.getLinePosition: missing line index data`);if(n>0){let r=Sf({type:c,metrics:this.metrics,hunkIndex:e,hunkSpecs:t?.hunkSpecs});if(r!=null){if(f+=r.gapBefore,l>=o-n&&l<o)return p={top:f,height:r.height},!0;f+=r.height+r.gapAfter}}let u=this.getLineHeight(o,(a?.noEOFCR??!1)||(i?.noEOFCR??!1));if(o===l)return p={top:f,height:u},!0;if(f+=u,r>0){let e=Cf({type:c,metrics:this.metrics});if(e!=null){if(l>o&&l<=o+r)return p={top:f+e.gapBefore,height:e.height},!0;f+=e.totalHeight}}return!1}}),p}getEditorViewport(){return this.virtualizer.type===`simple`?this.virtualizer.getRoot():this.virtualizer.getContainerElement()}getNumericScrollAnchor(e){if(this.fileDiff==null)return;let{disableFileHeader:t=!1,expandUnchanged:n=!1,collapsed:r=!1,collapsedContextThreshold:i=1}=this.options;if(r)return;let a=this.getDiffStyle(),o=this.getHunkSeparatorType();this.approximateLayoutCheckpoints();let s=this.getLayoutCheckpointBeforeTop(e),c=s?.top??sf(this.metrics,t)+this.cache.fileAnnotationHeight,l;return wf({diff:this.fileDiff,diffStyle:a,startingLine:s?.renderedLineIndex??0,expandedHunks:n?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:i,callback:({hunkIndex:t,hunk:n,collapsedBefore:r,collapsedAfter:i,deletionLine:s,additionLine:u})=>{let d=a===`split`?u?.splitLineIndex??s?.splitLineIndex:u?.unifiedLineIndex??s?.unifiedLineIndex;if(d==null)throw Error(`VirtualizedFileDiff.getNumericScrollAnchor: missing line index data`);if(r>0){let e=Sf({type:o,metrics:this.metrics,hunkIndex:t,hunkSpecs:n?.hunkSpecs});e!=null&&(c+=e.totalHeight)}if(c>=e&&(s==null?u!=null&&(l={lineNumber:u.lineNumber,side:`additions`,top:c}):l={lineNumber:s.lineNumber,side:`deletions`,top:c},l!=null))return!0;let f=this.getLineHeight(d,(u?.noEOFCR??!1)||(s?.noEOFCR??!1));if(c+=f,i>0){let e=Cf({type:o,metrics:this.metrics});e!=null&&(c+=e.totalHeight)}return!1}}),l}getVirtualizedHeight(){return this.height}getAdvancedStickySpecs(e){if(this.top==null||this.fileDiff==null)return;if(this.options.collapsed===!0)return{topOffset:this.top,height:this.height};let t=e==null?this.renderRange:this.computeRenderRangeFromWindow(this.fileDiff,this.top,e);if(t==null)return;let{bufferBefore:n,bufferAfter:r,totalLines:i}=t,a=0;if(i===0){let t=e??this.virtualizer.getWindowSpecs();this.top<t.top&&(a=r)}return{topOffset:this.top+n+a,height:this.height-(n+r)}}cleanUp(e=!1){this.fileContainer!=null&&this.isSimpleMode()&&this.getSimpleVirtualizer()?.disconnect(this.fileContainer),e||(this.resetLayoutCache({includeEstimatedHeights:!0}),this.pendingExpansions=void 0,this.pendingHydratedDiff=void 0),this.isSetup=!1,super.cleanUp(e)}expandHunk=(e,t,n)=>{this.fileDiff!=null&&(this.isAdvancedMode()?(this.pendingExpansions??=[],this.pendingExpansions.push({hunkIndex:e,direction:t,expansionLineCountOverride:n})):(this.hunksRenderer.expandHunk(e,t,n),this.resetLayoutCache({includeEstimatedHeights:!0}),this.computeApproximateSize()),this.loadFilesIfNecessary(),this.forceRenderOverride=!0,this.virtualizer.instanceChanged(this,!0))};async handleFilesLoaded(e,t){if(!(this.fileDiff!==e||!e.isPartial)){if(this.isAdvancedMode()){let n=Ig(`clone`,e,t);if(await kg(()=>this.primeHighlightCache(n)),!this.enabled||this.fileDiff!==e)return;this.pendingHydratedDiff={expectedDiff:e,nextDiff:n,files:t}}else{if(Ig(`merge`,e,t),this.setHydratedState(t),await kg(()=>this.primeHighlightCache(e)),!this.enabled||this.fileDiff!==e)return;this.resetLayoutCache({includeEstimatedHeights:!0}),this.computeApproximateSize()}this.forceRenderOverride=!0,this.virtualizer.instanceChanged(this,!0)}}consumeCodeViewLayoutChanges(e){let t=!1,n,{pendingExpansions:r,pendingHydratedDiff:i}=this;if(r!=null){this.pendingExpansions=void 0;for(let e of r)this.hunksRenderer.expandHunk(e.hunkIndex,e.direction,e.expansionLineCountOverride),t=!0}return i!=null&&(this.pendingHydratedDiff=void 0,i.expectedDiff===e&&(this.setHydratedState(i.files),n=i.nextDiff)),n==null?t&&(this.forceRenderOverride=!0,this.invalidateDerivedLayoutCache(!0)):(this.forceRenderOverride=!0,this.resetLayoutCache({includeEstimatedHeights:!0})),n}loadFilesIfNecessary(){if(this.pendingHydratedDiff!=null){if(this.pendingHydratedDiff.expectedDiff===this.fileDiff)return;this.pendingHydratedDiff=void 0}super.loadFilesIfNecessary()}isLineRenderable(e){if(super.isLineRenderable(e))return!0;let{pendingExpansions:t}=this,n=this.fileDiffCache;if(t==null||t.length===0||n==null)return!1;let{expansionLineCount:r=100,collapsedContextThreshold:i=1}=this.options,a=new Map(this.hunksRenderer.getExpandedHunksMap());for(let e of t){let t={...a.get(e.hunkIndex)??{fromStart:0,fromEnd:0}},n=e.expansionLineCountOverride??r;(e.direction===`up`||e.direction===`both`)&&(t.fromStart+=n),(e.direction===`down`||e.direction===`both`)&&(t.fromEnd+=n),a.set(e.hunkIndex,t)}return gf({fileDiff:n,lineNumber:e,expandedHunks:a,collapsedContextThreshold:i})}invalidateEditSessionLayout(){this.getSimpleVirtualizer()?.markDOMDirty(),this.resetLayoutCache({forceSimpleRecompute:this.isSimpleMode(),includeEstimatedHeights:!0,resetRenderRange:!1}),this.isSimpleMode()||this.computeApproximateSize(!0),this.getSimpleVirtualizer()?.requestHeightReconcile(this)}escalateEditSessionRender(){this.invalidateEditSessionLayout(),!(!this.enabled||this.fileDiff==null)&&(this.forceRenderOverride=!0,this.virtualizer.instanceChanged(this,!0))}shouldSelfHealEditSession(){return!this.isAdvancedMode()&&super.shouldSelfHealEditSession()}setVisibility(e){this.isAdvancedMode()||this.fileContainer==null||(this.renderRange=void 0,e&&!this.isVisible?(this.top=this.getVirtualizedTop(),this.isVisible=!0):!e&&this.isVisible&&(this.isVisible=!1,this.rerender()))}rerender(){!this.enabled||this.fileDiff==null&&this.additionFile==null&&this.deletionFile==null||(this.forceRenderOverride=!0,this.virtualizer.instanceChanged(this,!1))}applyDocumentChange(e,t,n=!1){let{renderRange:r}=this;if(this.getAdvancedVirtualizer()?.capturePendingLayoutAnchor(),super.applyDocumentChange(e,t),this.getSimpleVirtualizer()?.markDOMDirty(),this.resetLayoutCache({forceSimpleRecompute:this.isSimpleMode(),includeEstimatedHeights:!0,resetRenderRange:!1}),!this.isSimpleMode())this.computeApproximateSize(!0);else if(n&&r!==void 0&&this.fileDiff!==void 0){let e=this.virtualizer.getWindowSpecs(),t=this.computeRenderRangeFromWindow(this.fileDiff,this.top??0,e);t.bufferAfter!==r.bufferAfter&&this.updateBuffers(t)}this.forceRenderOverride=!0,this.virtualizer.instanceChanged(this,!0)}computeApproximateSize(e=!1,t=this.fileDiff){let n=this.isResizeDebuggingEnabled();if(!e&&!this.layoutDirty&&!n)return;let r=this.height===0;if(this.height=0,this.cache.checkpoints=[],this.cache.totalLines=0,t==null){this.layoutDirty=!1;return}let{disableFileHeader:i=!1,collapsed:a=!1}=this.options,o=sf(this.metrics,i);if(this.height+=o,a){this.layoutDirty=!1;return}this.height=this.getActiveEstimatedHeight(t)+this.cache.measuredHeightDeltaTotal,n&&!r&&this.validateComputedHeight(t),this.layoutDirty=!1}getActiveEstimatedHeight(e=this.fileDiff){this.ensureEstimatedDiffHeights(e);let t=this.getDiffStyle()===`split`?this.cache.estimatedSplitHeight:this.cache.estimatedUnifiedHeight;if(t==null)throw Error(`VirtualizedFileDiff.getActiveEstimatedHeight: missing estimated height`);return t}ensureEstimatedDiffHeights(e=this.fileDiff){if(e==null){this.cache.estimatedSplitHeight=void 0,this.cache.estimatedUnifiedHeight=void 0;return}if(this.cache.estimatedSplitHeight!=null&&this.cache.estimatedUnifiedHeight!=null)return;let{disableFileHeader:t=!1,expandUnchanged:n=!1,collapsedContextThreshold:r=1}=this.options,{splitHeight:i,unifiedHeight:a}=Ag({fileDiff:e,metrics:this.metrics,disableFileHeader:t,hunkSeparators:this.getHunkSeparatorType(),expandUnchanged:n,expandedHunks:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:r,canHydratePartialDiff:V_(e,this.options.loadDiffFiles!=null)});this.cache.estimatedSplitHeight=i,this.cache.estimatedUnifiedHeight=a}validateComputedHeight(e=this.fileDiff){if(this.fileContainer==null||e==null)return;let t=this.fileContainer.getBoundingClientRect();t.height===this.height?console.log(`VirtualizedFileDiff.computeApproximateSize: computed height IS CORRECT`):console.log(`VirtualizedFileDiff.computeApproximateSize: computed height doesnt match`,{name:e.name,elementHeight:t.height,computedHeight:this.height})}render({fileContainer:e,fileDiff:t,forceRender:n=!1,lineAnnotations:r,...i}={}){let a=Ng(i,`VirtualizedFileDiff.render`),o=a!=null,s=a?.oldFile,c=a?.newFile,l=o&&(!U_(s,this.deletionFile)||!U_(c,this.additionFile)),u=t??this.fileDiff;t==null&&o&&(l||this.fileDiff==null)&&(u=mm(a.oldFile,a.newFile,this.options.parseDiffOptions));let{forceRenderOverride:d,isSetup:f}=this;this.forceRenderOverride=void 0;let p=this.syncLineAnnotations(r);p&&this.resetLayoutCache({includeEstimatedHeights:!1});let m=t!=null&&t!==this.fileDiff,h=u!=null&&!tf(this.fileDiff,u),g=m||l;if(h&&this.resetLayoutCache({includeEstimatedHeights:!0}),e=this.getOrCreateFileContainer(e),u==null)return console.error(`VirtualizedFileDiff.render: attempting to virtually render when we dont have the correct data`),!1;if(f)this.top??=this.getVirtualizedTop(),h&&(this.getSimpleVirtualizer()?.markDOMDirty(),this.computeApproximateSize(!1,u));else{this.computeApproximateSize(!1,u);let t=this.getSimpleVirtualizer();if(this.top??=this.getVirtualizedTop(),this.isAdvancedMode())this.isVisible=!0;else{if(t==null)throw Error(`VirtualizedFileDiff.render: simple virtualizer is not available`);t.connect(e,this),this.isVisible=t.isInstanceVisible(this.top??0,this.height)}this.isSetup=!0}if(!this.isVisible&&this.isSimpleMode()&&(!g||!f))return this.fileDiff=u,a!=null&&(this.deletionFile=s,this.additionFile=c),h&&(this.cachedHeaderHTML=void 0),this.renderPlaceholder(this.height);let _=this.virtualizer.getWindowSpecs(),v=this.top??0,y=this.computeRenderRangeFromWindow(u,v,_),b=super.render({fileDiff:u,fileContainer:e,renderRange:y,lineAnnotations:r,forceRender:(d??n)||p||h,...a,...i});return this.isSimpleMode()&&b&&this.getSimpleVirtualizer()?.requestHeightReconcile(this),b}syncVirtualizedTop(){this.top=this.getVirtualizedTop()}shouldDisableVirtualizationBuffers(){return this.isAdvancedMode()||super.shouldDisableVirtualizationBuffers()}shouldGuardRebuildScroll(){return!1}isSimpleMode(){return this.virtualizer.type===`simple`}isAdvancedMode(){return this.virtualizer.type===`advanced`}getVirtualizedTop(){return this.virtualizer.type===`advanced`?this.virtualizer.getLocalTopForInstance(this):this.fileContainer==null?0:this.virtualizer.getOffsetInScrollContainer(this.fileContainer)}getSimpleVirtualizer(){return this.virtualizer.type===`simple`?this.virtualizer:void 0}getAdvancedVirtualizer(){return this.virtualizer.type===`advanced`?this.virtualizer:void 0}isResizeDebuggingEnabled(){return this.getSimpleVirtualizer()?.config.resizeDebugging??!1}getDiffStyle(){return this.options.diffStyle??`split`}getHunkSeparatorType(){return H_(this.options.hunkSeparators)}approximateLayoutCheckpoints(e=this.fileDiff){if(!this.layoutDirty&&this.cache.checkpoints.length>0||e==null||e.hunks.length===0||this.options.collapsed===!0)return;let{disableFileHeader:t=!1,expandUnchanged:n=!1,collapsedContextThreshold:r=1}=this.options,i=e.hunks.length-1,a=V_(e,this.options.loadDiffFiles!=null),o=this.getDiffStyle(),s=this.getHunkSeparatorType(),c=n?!0:this.hunksRenderer.getExpandedHunksMap(),l=N_(this.cache.heightDeltas),u=sf(this.metrics,t)+this.cache.fileAnnotationHeight,d=0,f=({rowCount:e,startLineIndex:t,preSeparatorHeight:n=0,postSeparatorHeight:r=0,metadataOffsets:i=[]})=>{if(e<=0)return;let a=d,o=d+e,s=I_(a);for(;s<o;){let e=s-a,r=u+(e>0?n:0)+e*this.metrics.lineHeight+L_(i,e)*this.metrics.lineHeight+P_(l,t,t+e);this.cache.checkpoints.push({renderedLineIndex:s,lineIndex:t+e,top:r}),s+=k_}u+=n+e*this.metrics.lineHeight+i.length*this.metrics.lineHeight+P_(l,t,t+e)+r,d=o};for(let t=0;t<e.hunks.length;t++){let n=e.hunks[t];if(n==null)throw Error(`VirtualizedFileDiff.approximateLayoutCheckpoints: invalid hunk index`);let l=ff({isPartial:e.isPartial,rangeSize:n.collapsedBefore,expandedHunks:c,hunkIndex:t,collapsedContextThreshold:r}),u=l.collapsedLines>0?Sf({type:s,metrics:this.metrics,hunkIndex:t,hunkSpecs:n.hunkSpecs})?.totalHeight??0:0;f({rowCount:l.fromStart,startLineIndex:(o===`split`?n.splitLineStart:n.unifiedLineStart)-l.rangeSize});let d=u;f({rowCount:l.fromEnd,startLineIndex:(o===`split`?n.splitLineStart:n.unifiedLineStart)-l.fromEnd,preSeparatorHeight:d}),l.fromEnd>0&&(d=0);let p=t===i?hf({fileDiff:e,hunkIndex:t,expandedHunks:c,collapsedContextThreshold:r,errorPrefix:`VirtualizedFileDiff`}):void 0,m=p!=null&&p.collapsedLines>0||t===i&&a?Cf({type:s,metrics:this.metrics})?.totalHeight??0:0,h=p==null?0:p.fromStart+p.fromEnd,g=o===`split`?n.splitLineCount:n.unifiedLineCount,_=o===`split`?n.splitLineStart:n.unifiedLineStart;f({rowCount:g,startLineIndex:_,preSeparatorHeight:d,postSeparatorHeight:h===0?m:0,metadataOffsets:R_({diffStyle:o,hunk:n,rowCount:g})}),p!=null&&h>0&&f({rowCount:h,startLineIndex:_+g,postSeparatorHeight:m})}this.cache.totalLines=d}getLayoutCheckpointBeforeLineIndex(e){if(e<=0||this.cache.checkpoints.length===0)return;let t=0,n=this.cache.checkpoints.length-1,r;for(;t<=n;){let i=t+n>>1,a=this.cache.checkpoints[i];if(a==null)throw Error(`VirtualizedFileDiff: invalid checkpoint index`);a.lineIndex<=e?(r=a,t=i+1):n=i-1}return r}getLayoutCheckpointBeforeTop(e,t){let n=0,r=this.cache.checkpoints.length-1,i=-1;for(;n<=r;){let t=n+r>>1,a=this.cache.checkpoints[t];if(a==null)throw Error(`VirtualizedFileDiff: invalid checkpoint index`);a.top<=e?(i=t,n=t+1):r=t-1}if(t==null)return i>=0?this.cache.checkpoints[i]:void 0;for(let e=i;e>=0;e--){let n=this.cache.checkpoints[e];if(n==null)throw Error(`VirtualizedFileDiff: invalid checkpoint index`);if(n.renderedLineIndex%t===0)return n}}getExpandedLineCount(e,t){let n=0;if(e.isPartial){for(let r of e.hunks)n+=t===`split`?r.splitLineCount:r.unifiedLineCount;return n}let{expandUnchanged:r=!1,collapsedContextThreshold:i=1}=this.options,a=r?!0:this.hunksRenderer.getExpandedHunksMap();for(let[r,o]of e.hunks.entries()){let s=t===`split`?o.splitLineCount:o.unifiedLineCount;n+=s;let c=Math.max(o.collapsedBefore,0),{fromStart:l,fromEnd:u,renderAll:d}=ff({isPartial:e.isPartial,rangeSize:c,expandedHunks:a,hunkIndex:r,collapsedContextThreshold:i});c>0&&(n+=d?c:l+u)}let o=hf({fileDiff:e,hunkIndex:e.hunks.length-1,expandedHunks:a,collapsedContextThreshold:i,errorPrefix:`VirtualizedFileDiff`});return o!=null&&(n+=o.fromStart+o.fromEnd),n}getLayoutLineCount(e,t){let n=this.getExpandedLineCount(e,t),r=t===`split`?e.splitLineCount:e.unifiedLineCount;return Math.max(n,r,e.additionLines.length,e.deletionLines.length,this.cache.totalLines)}computeRenderRangeFromWindow(e,t,{top:n,bottom:r}){let{disableFileHeader:i=!1,expandUnchanged:a=!1,collapsedContextThreshold:o=1}=this.options,{hunkLineCount:s,lineHeight:c}=this.metrics,l=this.getDiffStyle(),u=this.getHunkSeparatorType(),d=V_(e,this.options.loadDiffFiles!=null),f=this.height,p=this.getLayoutLineCount(e,l),m=sf(this.metrics,i),h=e.hunks.length>0?lf(this.metrics):0,{fileAnnotationHeight:g}=this.cache,_=m+g,v=Math.max(0,f-m-g-h),y=this.hasFileAnnotations(e),b=t+m,x=g>0&&y&&b<r&&b+g>n;if(t<n-f||t>r)return{startingLine:0,totalLines:0,bufferBefore:0,bufferAfter:f-m-h};if(p<=s||e.hunks.length===0)return{startingLine:0,totalLines:s,bufferBefore:0,bufferAfter:0};this.approximateLayoutCheckpoints(e),p=this.getLayoutLineCount(e,l);let S=Math.ceil(Math.max(r-n,0)/c),C=Math.ceil(S/s)*s+s,w=C/s,T=w,E=[],ee=(n+r)/2,D=this.getLayoutCheckpointBeforeTop(Math.max(0,n-t-C*c*2),s),O=t+(D?.top??_),te=D?.renderedLineIndex??0,ne,re,ie;if(wf({diff:e,diffStyle:l,startingLine:D?.renderedLineIndex??0,expandedHunks:a?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:o,callback:({hunkIndex:i,hunk:a,collapsedBefore:o,collapsedAfter:c,deletionLine:f,additionLine:p})=>{let m=p==null?f.splitLineIndex:p.splitLineIndex,h=p==null?f.unifiedLineIndex:p.unifiedLineIndex,g=(p?.noEOFCR??!1)||(f?.noEOFCR??!1),v=i===e.hunks.length-1&&a!=null&&(l===`split`?m===a.splitLineStart+a.splitLineCount-1:h===a.unifiedLineStart+a.unifiedLineCount-1),y=(o>0?Sf({type:u,metrics:this.metrics,hunkIndex:i,hunkSpecs:a?.hunkSpecs}):void 0)?.totalHeight??0;O+=y;let b=te%s===0,x=Math.floor(te/s);if(b&&(E[x]=O-(t+_+y),ie!=null)){if(ie<=0)return!0;ie--}let S=this.getLineHeight(l===`split`?m:h,g);if(O>n-S&&O<r&&(ne??=x),re==null&&O+S>ee&&(re=x),ie==null&&O>=r&&b&&(ie=T),te++,O+=S,c>0||v&&d){let e=Cf({type:u,metrics:this.metrics});e!=null&&(O<r&&O+e.totalHeight>n&&(ne??=x),re==null&&O+e.totalHeight>ee&&(re=x),O+=e.totalHeight)}return!1}}),ne==null){if(x)ne=0,re=0;else return{startingLine:0,totalLines:0,bufferBefore:0,bufferAfter:f-m-h}}re??=ne;let ae=Math.round(re-w/2),oe=Math.max(0,Math.ceil(p/s)-w),k=Math.max(0,Math.min(ae,oe)),A=k*s,se=ae<0?C+ae*s:C,ce=E[k]??0,le=A===0?0:g+ce,ue=k+se/s,de=ue<E.length?v-E[ue]:v-(O-t-_);return{startingLine:A,totalLines:se,bufferBefore:le,bufferAfter:Math.max(0,de)}}};function M_(e){let t;for(let n of e){if(n==null)continue;let e=n.children[1];if(e instanceof HTMLElement)for(let n of e.children)n instanceof HTMLElement&&n.dataset.lineAnnotation===lh&&(t=Math.max(t??0,n.getBoundingClientRect().height))}return t}function N_(e){let t=Array.from(e).sort((e,t)=>e[0]-t[0]),n=[],r=[0],i=0;for(let[e,a]of t)n.push(e),i+=a,r.push(i);return{lineIndexes:n,prefixTotals:r}}function P_({lineIndexes:e,prefixTotals:t},n,r){if(n>=r||e.length===0)return 0;let i=F_(e,n);return(t[F_(e,r)]??0)-(t[i]??0)}function F_(e,t){let n=0,r=e.length;for(;n<r;){let i=n+r>>1,a=e[i];if(a==null)throw Error(`VirtualizedFileDiff: invalid prefix index`);a<t?n=i+1:r=i}return n}function I_(e){return Math.ceil(e/k_)*k_}function L_(e,t){let n=0;for(let r of e)r<t&&n++;return n}function R_({diffStyle:e,hunk:t,rowCount:n}){if(n<=0||!t.noEOFCRAdditions&&!t.noEOFCRDeletions)return[];let r=t.hunkContent.at(-1);if(r==null)return[];if(r.type===`context`)return[n-1];let i=Math.max(r.deletions,r.additions),a=r.deletions+r.additions;if(e===`split`)return i>0&&(t.noEOFCRAdditions||t.noEOFCRDeletions)?[n-1]:[];let o=[],s=n-a;return r.deletions>0&&t.noEOFCRDeletions&&o.push(s+r.deletions-1),r.additions>0&&t.noEOFCRAdditions&&o.push(n-1),o}function z_(e,t){return(e.diffStyle??`split`)!==(t.diffStyle??`split`)||(e.overflow??`scroll`)!==(t.overflow??`scroll`)||(e.collapsed??!1)!==(t.collapsed??!1)||(e.disableLineNumbers??!1)!==(t.disableLineNumbers??!1)||(e.disableFileHeader??!1)!==(t.disableFileHeader??!1)||(e.diffIndicators??`bars`)!==(t.diffIndicators??`bars`)||(e.hunkSeparators??`line-info`)!==(t.hunkSeparators??`line-info`)||!!e.loadDiffFiles!=!!t.loadDiffFiles||(e.expandUnchanged??!1)!==(t.expandUnchanged??!1)||(e.collapsedContextThreshold??1)!==(t.collapsedContextThreshold??1)||e.unsafeCSS!==t.unsafeCSS}function B_(e,t){return(e.disableFileHeader??!1)!==(t.disableFileHeader??!1)||(e.hunkSeparators??`line-info`)!==(t.hunkSeparators??`line-info`)||!!e.loadDiffFiles!=!!t.loadDiffFiles||(e.expandUnchanged??!1)!==(t.expandUnchanged??!1)||(e.collapsedContextThreshold??1)!==(t.collapsedContextThreshold??1)}function V_(e,t){return e.isPartial&&t&&(e.type===`change`||e.type===`rename-changed`)}function H_(e){return typeof e==`function`?`custom`:e??`line-info`}function U_(e,t){return e==null||t==null?e==null&&t==null:Ne(e,t)}function W_(e,t){let[n,r]=e.split(`,`).map(Number);return t===`split`?r:n}function G_(e,t){return typeof window>`u`&&t!=null?(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(`template`,{shadowrootmode:`open`,dangerouslySetInnerHTML:{__html:t}}),e]}):(0,D.jsx)(D.Fragment,{children:e})}var K_=(0,v.createContext)(void 0);function q_(){return(0,v.useContext)(K_)}var J_=typeof window>`u`?v.useEffect:v.useLayoutEffect;function Y_({fileDiff:e,options:t,editorOptions:n,lineAnnotations:r,selectedLines:i,prerenderedHTML:a,metrics:o,hasGutterRenderUtility:s,hasCustomHeader:c,disableWorkerPool:l,edit:u}){let d=q_(),f=i!==void 0,p=(0,v.useContext)(gp),m=te(),h=(0,v.useRef)(null),g=E(n=>{if(n!=null){if(h.current!=null)throw Error(`useFileDiffInstance: An instance should not already exist when a node is created`);d==null?h.current=new S_(X_({controlledSelection:f,hasCustomHeader:c,hasGutterRenderUtility:s,options:t}),l?void 0:p,!0):h.current=new j_(X_({controlledSelection:f,hasCustomHeader:c,hasGutterRenderUtility:s,options:t}),d,o,l?void 0:p,!0),h.current.hydrate({fileDiff:e,fileContainer:n,lineAnnotations:r,prerenderedHTML:a})}else{if(h.current==null)throw Error(`useFileDiffInstance: A FileDiff instance should exist when unmounting`);h.current.cleanUp(),h.current=null}});return J_(()=>{let{current:n}=h;if(n==null)return;let a=X_({controlledSelection:f,hasCustomHeader:c,hasGutterRenderUtility:s,options:t}),o=a!==void 0&&!vp(n.options,a);n.setOptions(a),n.render({forceRender:o,fileDiff:e,lineAnnotations:r}),i!==void 0&&n.setSelectedLines(i)}),J_(()=>{if(u&&h.current!=null){if(m===void 0)throw Error(`FileDiff: EditContext is not attached`);let e=m(n??{});if(e==null)throw Error(`FileDiff: EditProvider.createEditor must return an editor instance`);try{return e.edit(h.current)}catch(t){throw e.cleanUp(),t}}},[u]),{ref:g,getHoveredLine:(0,v.useCallback)(()=>h.current?.getHoveredLine(),[])}}function X_({options:e,controlledSelection:t,hasCustomHeader:n,hasGutterRenderUtility:r}){return t||r||n?{...e,controlledSelection:t,renderCustomHeader:n?ie:e?.renderCustomHeader,renderGutterUtility:r?ie:e?.renderGutterUtility}:e}function Z_({fileDiff:e,options:t,editorOptions:n,metrics:r,lineAnnotations:i,selectedLines:a,className:o,style:s,prerenderedHTML:c,renderAnnotation:l,renderCustomHeader:u,renderHeaderPrefix:d,renderHeaderFilenameSuffix:f,renderHeaderMetadata:p,renderGutterUtility:m,disableWorkerPool:h=!1,edit:g=!1}){let{ref:_,getHoveredLine:v}=Y_({fileDiff:e,options:t,editorOptions:n,metrics:r,lineAnnotations:i,selectedLines:a,prerenderedHTML:c,hasGutterRenderUtility:m!=null,hasCustomHeader:u!=null,disableWorkerPool:h,edit:g});return(0,D.jsx)(ae,{ref:_,className:o,style:s,children:G_(Ae({fileDiff:e,renderCustomHeader:u,renderHeaderPrefix:d,renderHeaderFilenameSuffix:f,renderHeaderMetadata:p,renderAnnotation:l,renderGutterUtility:m,lineAnnotations:i,getHoveredLine:v}),c)})}var Q_=(...e)=>e.filter((e,t,n)=>!!e&&e.trim()!==``&&n.indexOf(e)===t).join(` `).trim(),$_=e=>e.replace(/([a-z0-9])([A-Z])/g,`$1-$2`).toLowerCase(),ev=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,n)=>n?n.toUpperCase():t.toLowerCase()),tv=e=>{let t=ev(e);return t.charAt(0).toUpperCase()+t.slice(1)},nv={xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:2,strokeLinecap:`round`,strokeLinejoin:`round`},rv=e=>{for(let t in e)if(t.startsWith(`aria-`)||t===`role`||t===`title`)return!0;return!1},iv=(0,v.createContext)({}),av=()=>(0,v.useContext)(iv),ov=(0,v.forwardRef)(({color:e,size:t,strokeWidth:n,absoluteStrokeWidth:r,className:i=``,children:a,iconNode:o,...s},c)=>{let{size:l=24,strokeWidth:u=2,absoluteStrokeWidth:d=!1,color:f=`currentColor`,className:p=``}=av()??{},m=r??d?Number(n??u)*24/Number(t??l):n??u;return(0,v.createElement)(`svg`,{ref:c,...nv,width:t??l??nv.width,height:t??l??nv.height,stroke:e??f,strokeWidth:m,className:Q_(`lucide`,p,i),...!a&&!rv(s)&&{"aria-hidden":`true`},...s},[...o.map(([e,t])=>(0,v.createElement)(e,t)),...Array.isArray(a)?a:[a]])}),sv=(e,t)=>{let n=(0,v.forwardRef)(({className:n,...r},i)=>(0,v.createElement)(ov,{ref:i,iconNode:t,className:Q_(`lucide-${$_(tv(e))}`,`lucide-${e}`,n),...r}));return n.displayName=tv(e),n},cv=sv(`check`,[[`path`,{d:`M20 6 9 17l-5-5`,key:`1gmf2c`}]]),lv=sv(`chevron-down`,[[`path`,{d:`m6 9 6 6 6-6`,key:`qrunsl`}]]),uv=sv(`chevron-right`,[[`path`,{d:`m9 18 6-6-6-6`,key:`mthhwq`}]]),dv=sv(`chevrons-down-up`,[[`path`,{d:`m7 20 5-5 5 5`,key:`13a0gw`}],[`path`,{d:`m7 4 5 5 5-5`,key:`1kwcof`}]]),fv=sv(`chevrons-up-down`,[[`path`,{d:`m7 15 5 5 5-5`,key:`1hf1tw`}],[`path`,{d:`m7 9 5-5 5 5`,key:`sgt6xg`}]]),pv=sv(`eye-off`,[[`path`,{d:`M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49`,key:`ct8e1f`}],[`path`,{d:`M14.084 14.158a3 3 0 0 1-4.242-4.242`,key:`151rxh`}],[`path`,{d:`M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143`,key:`13bj9a`}],[`path`,{d:`m2 2 20 20`,key:`1ooewy`}]]),mv=sv(`eye`,[[`path`,{d:`M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0`,key:`1nclc0`}],[`circle`,{cx:`12`,cy:`12`,r:`3`,key:`1v7zrd`}]]),hv=sv(`message-square-plus`,[[`path`,{d:`M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z`,key:`18887p`}],[`path`,{d:`M12 8v6`,key:`1ib9pf`}],[`path`,{d:`M9 11h6`,key:`1fldmi`}]]),gv=sv(`message-square`,[[`path`,{d:`M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z`,key:`18887p`}]]),_v=sv(`plus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`M12 5v14`,key:`s699le`}]]),vv=sv(`rotate-ccw-clock`,[[`path`,{d:`M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8`,key:`1357e3`}],[`path`,{d:`M3 3v5h5`,key:`1xhq8a`}],[`path`,{d:`M12 7v5l4 2`,key:`1fdv2h`}]]),yv=sv(`sparkles`,[[`path`,{d:`M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z`,key:`1s2grr`}],[`path`,{d:`M20 2v4`,key:`1rf3ol`}],[`path`,{d:`M22 4h-4`,key:`gwowj6`}],[`circle`,{cx:`4`,cy:`20`,r:`2`,key:`6kqj1y`}]]),bv=sv(`trash`,[[`path`,{d:`M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6`,key:`miytrc`}],[`path`,{d:`M3 6h18`,key:`d0wm0j`}],[`path`,{d:`M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2`,key:`e791ji`}]]),xv=sv(`x`,[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]),Sv=`github-dark-dimmed`;function Cv(e){switch(e.kind){case`orientation`:return`orientation`;case`topic`:return`topic:${e.topicId}`;case`question`:return`question:${e.questionId}`}}function wv({checked:e,label:t,onChange:n,className:r}){return(0,D.jsxs)(`label`,{className:`checkbox-btn${r?` ${r}`:``}`,children:[(0,D.jsx)(`input`,{type:`checkbox`,className:`checkbox-input`,checked:e,onChange:e=>n(e.target.checked)}),(0,D.jsx)(`span`,{className:`checkbox-box`,"aria-hidden":`true`,children:e&&(0,D.jsx)(cv,{size:10,strokeWidth:3})}),(0,D.jsx)(`span`,{children:t})]})}function X({variant:e=`default`,active:t=!1,muted:n=!1,iconOnly:r=!1,pill:i=!1,type:a=`button`,className:o,...s}){let c=[`button`,`button-${e}`,t&&`button-active`,n&&`button-muted`,r&&`button-icon-only`,i&&`button-pill`,o].filter(Boolean).join(` `);return(0,D.jsx)(`button`,{...s,type:a,className:c})}function Tv({className:e,inputClassName:t,actionsClassName:n,placeholder:r,submitLabel:i,cancelLabel:a=`Cancel`,value:o,rows:s=3,autoFocus:c=!1,allowEmptySubmit:l=!1,children:u,onValueChange:d,onSubmit:f,onCancel:p}){let[m,h]=(0,v.useState)(``),g=(0,v.useRef)(null),_=o??m,y=_.trim();(0,v.useEffect)(()=>{c&&g.current?.focus()},[c]);let b=e=>{o===void 0&&h(e),d?.(e)},x=()=>{!y&&!l||(o===void 0&&h(``),f(y))},S=(0,D.jsx)(`textarea`,{ref:g,className:[`text-input-area`,t].filter(Boolean).join(` `),value:_,rows:s,autoFocus:c,placeholder:r,onChange:e=>b(e.target.value),onKeyDown:e=>{e.key===`Enter`&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),x()),e.key===`Escape`&&p&&(e.preventDefault(),p())}});return(0,D.jsxs)(`form`,{className:e,onSubmit:e=>{e.preventDefault(),x()},children:[S,(0,D.jsxs)(`div`,{className:n,children:[u,p&&(0,D.jsx)(X,{variant:`ghost`,onClick:p,children:a}),(0,D.jsx)(X,{type:`submit`,variant:`primary`,disabled:!y&&!l,children:i})]})]})}var Ev=(0,v.memo)(function({onSave:e,onCancel:t}){let[n,r]=(0,v.useState)(!1);return(0,D.jsx)(Tv,{className:`comment-editor`,inputClassName:`comment-input`,actionsClassName:`comment-actions`,placeholder:`Add a comment…`,submitLabel:`comment`,rows:2,autoFocus:!0,allowEmptySubmit:!0,onSubmit:t=>e(t,n),onCancel:t,children:(0,D.jsx)(wv,{checked:n,label:`ask agent`,onChange:r})})});function Dv({additions:e,deletions:t,className:n}){let r=[`diff-stats`,n].filter(Boolean).join(` `);return(0,D.jsxs)(`span`,{className:r,children:[(0,D.jsxs)(`span`,{className:`stat-add`,children:[`+`,e]}),(0,D.jsxs)(`span`,{className:`stat-del`,children:[`-`,t]})]})}var Ov=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,kv=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,Av={};function jv(e,t){return((t||Av).jsx?kv:Ov).test(e)}var Mv=o(((e,t)=>{var n=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,r=/\n/g,i=/^\s*/,a=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,s=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,c=/^[;\s]*/,l=/^\s+|\s+$/g;function u(e,t){if(typeof e!=`string`)throw TypeError(`First argument must be a string`);if(!e)return[];t||={};var l=1,u=1;function f(e){var t=e.match(r);t&&(l+=t.length);var n=e.lastIndexOf(`
|
|
1538
|
-
`);u=~n?e.length-n:u+e.length}function p(){var e={line:l,column:u};return function(t){return t.position=new m(e),_(),t}}function m(e){this.start=e,this.end={line:l,column:u},this.source=t.source}m.prototype.content=e;function h(n){var r=Error(t.source+`:`+l+`:`+u+`: `+n);if(r.reason=n,r.filename=t.source,r.line=l,r.column=u,r.source=e,!t.silent)throw r}function g(t){var n=t.exec(e);if(n){var r=n[0];return f(r),e=e.slice(r.length),n}}function _(){g(i)}function v(e){var t;for(e||=[];t=y();)t!==!1&&e.push(t);return e}function y(){var t=p();if(e.charAt(0)==`/`&&e.charAt(1)==`*`){for(var n=2;e.charAt(n)!=``&&(e.charAt(n)!=`*`||e.charAt(n+1)!=`/`);)++n;if(n+=2,e.charAt(n-1)===``)return h(`End of comment missing`);var r=e.slice(2,n-2);return u+=2,f(r),e=e.slice(n),u+=2,t({type:`comment`,comment:r})}}function b(){var e=p(),t=g(a);if(t){if(y(),!g(o))return h(`property missing ':'`);var r=g(s),i=e({type:`declaration`,property:d(t[0].replace(n,``)),value:r?d(r[0].replace(n,``)):``});return g(c),i}}function x(){var e=[];v(e);for(var t;t=b();)t!==!1&&(e.push(t),v(e));return e}return _(),x()}function d(e){return e?e.replace(l,``):``}t.exports=u})),Nv=o((e=>{var t=e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;var n=t(Mv());function r(e,t){let r=null;if(!e||typeof e!=`string`)return r;let i=(0,n.default)(e),a=typeof t==`function`;return i.forEach(e=>{if(e.type!==`declaration`)return;let{property:n,value:i}=e;a?t(n,i,e):i&&(r||={},r[n]=i)}),r}})),Pv=o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.camelCase=void 0;var t=/^--[a-zA-Z0-9_-]+$/,n=/-([a-z])/g,r=/^[^-]+$/,i=/^-(webkit|moz|ms|o|khtml)-/,a=/^-(ms)-/,o=function(e){return!e||r.test(e)||t.test(e)},s=function(e,t){return t.toUpperCase()},c=function(e,t){return`${t}-`};e.camelCase=function(e,t){return t===void 0&&(t={}),o(e)?e:(e=e.toLowerCase(),e=t.reactCompat?e.replace(a,c):e.replace(i,c),e.replace(n,s))}})),Fv=o(((e,t)=>{var n=(e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(Nv()),r=Pv();function i(e,t){var i={};return!e||typeof e!=`string`||(0,n.default)(e,function(e,n){e&&n&&(i[(0,r.camelCase)(e,t)]=n)}),i}i.default=i,t.exports=i})),Iv=Rv(`end`),Lv=Rv(`start`);function Rv(e){return t;function t(t){let n=t&&t.position&&t.position[e]||{};if(typeof n.line==`number`&&n.line>0&&typeof n.column==`number`&&n.column>0)return{line:n.line,column:n.column,offset:typeof n.offset==`number`&&n.offset>-1?n.offset:void 0}}}function zv(e){let t=Lv(e),n=Iv(e);if(t&&n)return{start:t,end:n}}function Bv(e){return!e||typeof e!=`object`?``:`position`in e||`type`in e?Hv(e.position):`start`in e||`end`in e?Hv(e):`line`in e||`column`in e?Vv(e):``}function Vv(e){return Uv(e&&e.line)+`:`+Uv(e&&e.column)}function Hv(e){return Vv(e&&e.start)+`-`+Vv(e&&e.end)}function Uv(e){return e&&typeof e==`number`?e:1}var Wv=class extends Error{constructor(e,t,n){super(),typeof t==`string`&&(n=t,t=void 0);let r=``,i={},a=!1;if(t&&(i=`line`in t&&`column`in t||`start`in t&&`end`in t?{place:t}:`type`in t?{ancestors:[t],place:t.position}:{...t}),typeof e==`string`?r=e:!i.cause&&e&&(a=!0,r=e.message,i.cause=e),!i.ruleId&&!i.source&&typeof n==`string`){let e=n.indexOf(`:`);e===-1?i.ruleId=n:(i.source=n.slice(0,e),i.ruleId=n.slice(e+1))}if(!i.place&&i.ancestors&&i.ancestors){let e=i.ancestors[i.ancestors.length-1];e&&(i.place=e.position)}let o=i.place&&`start`in i.place?i.place.start:i.place;this.ancestors=i.ancestors||void 0,this.cause=i.cause||void 0,this.column=o?o.column:void 0,this.fatal=void 0,this.file=``,this.message=r,this.line=o?o.line:void 0,this.name=Bv(i.place)||`1:1`,this.place=i.place||void 0,this.reason=this.message,this.ruleId=i.ruleId||void 0,this.source=i.source||void 0,this.stack=a&&i.cause&&typeof i.cause.stack==`string`?i.cause.stack:``,this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}};Wv.prototype.file=``,Wv.prototype.name=``,Wv.prototype.reason=``,Wv.prototype.message=``,Wv.prototype.stack=``,Wv.prototype.column=void 0,Wv.prototype.line=void 0,Wv.prototype.ancestors=void 0,Wv.prototype.cause=void 0,Wv.prototype.fatal=void 0,Wv.prototype.place=void 0,Wv.prototype.ruleId=void 0,Wv.prototype.source=void 0;var Gv=l(Fv(),1),Kv={}.hasOwnProperty,qv=new Map,Jv=/[A-Z]/g,Yv=new Set([`table`,`tbody`,`thead`,`tfoot`,`tr`]),Xv=new Set([`td`,`th`]),Zv=`https://github.com/syntax-tree/hast-util-to-jsx-runtime`;function Qv(e,t){if(!t||t.Fragment===void 0)throw TypeError("Expected `Fragment` in options");let n=t.filePath||void 0,r;if(t.development){if(typeof t.jsxDEV!=`function`)throw TypeError("Expected `jsxDEV` in options when `development: true`");r=ly(n,t.jsxDEV)}else{if(typeof t.jsx!=`function`)throw TypeError("Expected `jsx` in production options");if(typeof t.jsxs!=`function`)throw TypeError("Expected `jsxs` in production options");r=cy(n,t.jsx,t.jsxs)}let i={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:r,elementAttributeNameCase:t.elementAttributeNameCase||`react`,evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space===`svg`?Gi:Wi,stylePropertyNameCase:t.stylePropertyNameCase||`dom`,tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=$v(i,e,void 0);return a&&typeof a!=`string`?a:i.create(e,i.Fragment,{children:a||void 0},void 0)}function $v(e,t,n){if(t.type===`element`)return ey(e,t,n);if(t.type===`mdxFlowExpression`||t.type===`mdxTextExpression`)return ty(e,t);if(t.type===`mdxJsxFlowElement`||t.type===`mdxJsxTextElement`)return ry(e,t,n);if(t.type===`mdxjsEsm`)return ny(e,t);if(t.type===`root`)return iy(e,t,n);if(t.type===`text`)return ay(e,t)}function ey(e,t,n){let r=e.schema,i=r;t.tagName.toLowerCase()===`svg`&&r.space===`html`&&(i=Gi,e.schema=i),e.ancestors.push(t);let a=hy(e,t.tagName,!1),o=uy(e,t),s=fy(e,t);return Yv.has(t.tagName)&&(s=s.filter(function(e){return typeof e!=`string`||!Ta(e)})),oy(e,o,a,t),sy(o,s),e.ancestors.pop(),e.schema=r,e.create(t,a,o,n)}function ty(e,t){if(t.data&&t.data.estree&&e.evaluater){let n=t.data.estree.body[0];return n.type,e.evaluater.evaluateExpression(n.expression)}gy(e,t.position)}function ny(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);gy(e,t.position)}function ry(e,t,n){let r=e.schema,i=r;t.name===`svg`&&r.space===`html`&&(i=Gi,e.schema=i),e.ancestors.push(t);let a=t.name===null?e.Fragment:hy(e,t.name,!0),o=dy(e,t),s=fy(e,t);return oy(e,o,a,t),sy(o,s),e.ancestors.pop(),e.schema=r,e.create(t,a,o,n)}function iy(e,t,n){let r={};return sy(r,fy(e,t)),e.create(t,e.Fragment,r,n)}function ay(e,t){return t.value}function oy(e,t,n,r){typeof n!=`string`&&n!==e.Fragment&&e.passNode&&(t.node=r)}function sy(e,t){if(t.length>0){let n=t.length>1?t:t[0];n&&(e.children=n)}}function cy(e,t,n){return r;function r(e,r,i,a){let o=Array.isArray(i.children)?n:t;return a?o(r,i,a):o(r,i)}}function ly(e,t){return n;function n(n,r,i,a){let o=Array.isArray(i.children),s=Lv(n);return t(r,i,a,o,{columnNumber:s?s.column-1:void 0,fileName:e,lineNumber:s?s.line:void 0},void 0)}}function uy(e,t){let n={},r,i;for(i in t.properties)if(i!==`children`&&Kv.call(t.properties,i)){let a=py(e,i,t.properties[i]);if(a){let[i,o]=a;e.tableCellAlignToStyle&&i===`align`&&typeof o==`string`&&Xv.has(t.tagName)?r=o:n[i]=o}}if(r){let t=n.style||={};t[e.stylePropertyNameCase===`css`?`text-align`:`textAlign`]=r}return n}function dy(e,t){let n={};for(let r of t.attributes)if(r.type===`mdxJsxExpressionAttribute`){if(r.data&&r.data.estree&&e.evaluater){let t=r.data.estree.body[0];t.type;let i=t.expression;i.type;let a=i.properties[0];a.type,Object.assign(n,e.evaluater.evaluateExpression(a.argument))}else gy(e,t.position)}else{let i=r.name,a;if(r.value&&typeof r.value==`object`){if(r.value.data&&r.value.data.estree&&e.evaluater){let t=r.value.data.estree.body[0];t.type,a=e.evaluater.evaluateExpression(t.expression)}else gy(e,t.position)}else a=r.value===null||r.value;n[i]=a}return n}function fy(e,t){let n=[],r=-1,i=e.passKeys?new Map:qv;for(;++r<t.children.length;){let a=t.children[r],o;if(e.passKeys){let e=a.type===`element`?a.tagName:a.type===`mdxJsxFlowElement`||a.type===`mdxJsxTextElement`?a.name:void 0;if(e){let t=i.get(e)||0;o=e+`-`+t,i.set(e,t+1)}}let s=$v(e,a,o);s!==void 0&&n.push(s)}return n}function py(e,t,n){let r=Vi(e.schema,t);if(!(n==null||typeof n==`number`&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?Sa(n):Ca(n)),r.property===`style`){let t=typeof n==`object`?n:my(e,String(n));return e.stylePropertyNameCase===`css`&&(t=_y(t)),[`style`,t]}return[e.elementAttributeNameCase===`react`&&r.space?Li[r.property]||r.property:r.attribute,n]}}function my(e,t){try{return(0,Gv.default)(t,{reactCompat:!0})}catch(t){if(e.ignoreInvalidStyle)return{};let n=t,r=new Wv("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:n,ruleId:`style`,source:`hast-util-to-jsx-runtime`});throw r.file=e.filePath||void 0,r.url=Zv+`#cannot-parse-style-attribute`,r}}function hy(e,t,n){let r;if(!n)r={type:`Literal`,value:t};else if(t.includes(`.`)){let e=t.split(`.`),n=-1,i;for(;++n<e.length;){let t=jv(e[n])?{type:`Identifier`,name:e[n]}:{type:`Literal`,value:e[n]};i=i?{type:`MemberExpression`,object:i,property:t,computed:!!(n&&t.type===`Literal`),optional:!1}:t}r=i}else r=jv(t)&&!/^[a-z]/.test(t)?{type:`Identifier`,name:t}:{type:`Literal`,value:t};if(r.type===`Literal`){let t=r.value;return Kv.call(e.components,t)?e.components[t]:t}if(e.evaluater)return e.evaluater.evaluateExpression(r);gy(e)}function gy(e,t){let n=new Wv("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:`mdx-estree`,source:`hast-util-to-jsx-runtime`});throw n.file=e.filePath||void 0,n.url=Zv+`#cannot-handle-mdx-estrees-without-createevaluater`,n}function _y(e){let t={},n;for(n in e)Kv.call(e,n)&&(t[vy(n)]=e[n]);return t}function vy(e){let t=e.replace(Jv,yy);return t.slice(0,3)===`ms-`&&(t=`-`+t),t}function yy(e){return`-`+e.toLowerCase()}var by={action:[`form`],cite:[`blockquote`,`del`,`ins`,`q`],data:[`object`],formAction:[`button`,`input`],href:[`a`,`area`,`base`,`link`],icon:[`menuitem`],itemId:null,manifest:[`html`],ping:[`a`,`area`],poster:[`video`],src:[`audio`,`embed`,`iframe`,`img`,`input`,`script`,`source`,`track`,`video`]},xy={};function Sy(e,t){let n=t||xy;return Cy(e,typeof n.includeImageAlt!=`boolean`||n.includeImageAlt,typeof n.includeHtml!=`boolean`||n.includeHtml)}function Cy(e,t,n){if(Ty(e)){if(`value`in e)return e.type===`html`&&!n?``:e.value;if(t&&`alt`in e&&e.alt)return e.alt;if(`children`in e)return wy(e.children,t,n)}return Array.isArray(e)?wy(e,t,n):``}function wy(e,t,n){let r=[],i=-1;for(;++i<e.length;)r[i]=Cy(e[i],t,n);return r.join(``)}function Ty(e){return!!(e&&typeof e==`object`)}var Ey=document.createElement(`i`);function Dy(e){let t=`&`+e+`;`;Ey.innerHTML=t;let n=Ey.textContent;return n.charCodeAt(n.length-1)===59&&e!==`semi`?!1:n!==t&&n}function Oy(e,t,n,r){let i=e.length,a=0,o;if(t=t<0?-t>i?0:i+t:t>i?i:t,n=n>0?n:0,r.length<1e4)o=Array.from(r),o.unshift(t,n),e.splice(...o);else for(n&&e.splice(t,n);a<r.length;)o=r.slice(a,a+1e4),o.unshift(t,0),e.splice(...o),a+=1e4,t+=1e4}function ky(e,t){return e.length>0?(Oy(e,e.length,0,t),e):t}var Ay={}.hasOwnProperty;function jy(e){let t={},n=-1;for(;++n<e.length;)My(t,e[n]);return t}function My(e,t){let n;for(n in t){let r=(Ay.call(e,n)?e[n]:void 0)||(e[n]={}),i=t[n],a;if(i)for(a in i){Ay.call(r,a)||(r[a]=[]);let e=i[a];Ny(r[a],Array.isArray(e)?e:e?[e]:[])}}}function Ny(e,t){let n=-1,r=[];for(;++n<t.length;)(t[n].add===`after`?e:r).push(t[n]);Oy(e,0,0,r)}function Py(e,t){let n=Number.parseInt(e,t);return n<9||n===11||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)==65535||(n&65535)==65534||n>1114111?`�`:String.fromCodePoint(n)}function Fy(e){return e.replace(/[\t\n\r ]+/g,` `).replace(/^ | $/g,``).toLowerCase().toUpperCase()}var Iy=Ky(/[A-Za-z]/),Ly=Ky(/[\dA-Za-z]/),Ry=Ky(/[#-'*+\--9=?A-Z^-~]/);function zy(e){return e!==null&&(e<32||e===127)}var By=Ky(/\d/),Vy=Ky(/[\dA-Fa-f]/),Hy=Ky(/[!-/:-@[-`{-~]/);function Z(e){return e!==null&&e<-2}function Uy(e){return e!==null&&(e<0||e===32)}function Q(e){return e===-2||e===-1||e===32}var Wy=Ky(/\p{P}|\p{S}/u),Gy=Ky(/\s/);function Ky(e){return t;function t(t){return t!==null&&t>-1&&e.test(String.fromCharCode(t))}}function qy(e){let t=[],n=-1,r=0,i=0;for(;++n<e.length;){let a=e.charCodeAt(n),o=``;if(a===37&&Ly(e.charCodeAt(n+1))&&Ly(e.charCodeAt(n+2)))i=2;else if(a<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(a))||(o=String.fromCharCode(a));else if(a>55295&&a<57344){let t=e.charCodeAt(n+1);a<56320&&t>56319&&t<57344?(o=String.fromCharCode(a,t),i=1):o=`�`}else o=String.fromCharCode(a);o&&=(t.push(e.slice(r,n),encodeURIComponent(o)),r=n+i+1,``),i&&=(n+=i,0)}return t.join(``)+e.slice(r)}function $(e,t,n,r){let i=r?r-1:1/0,a=0;return o;function o(r){return Q(r)?(e.enter(n),s(r)):t(r)}function s(r){return Q(r)&&a++<i?(e.consume(r),s):(e.exit(n),t(r))}}var Jy={tokenize:Yy};function Yy(e){let t=e.attempt(this.parser.constructs.contentInitial,r,i),n;return t;function r(n){if(n===null){e.consume(n);return}return e.enter(`lineEnding`),e.consume(n),e.exit(`lineEnding`),$(e,t,`linePrefix`)}function i(t){return e.enter(`paragraph`),a(t)}function a(t){let r=e.enter(`chunkText`,{contentType:`text`,previous:n});return n&&(n.next=r),n=r,o(t)}function o(t){if(t===null){e.exit(`chunkText`),e.exit(`paragraph`),e.consume(t);return}return Z(t)?(e.consume(t),e.exit(`chunkText`),a):(e.consume(t),o)}}var Xy={tokenize:Qy},Zy={tokenize:$y};function Qy(e){let t=this,n=[],r=0,i,a,o;return s;function s(i){if(r<n.length){let a=n[r];return t.containerState=a[1],e.attempt(a[0].continuation,c,l)(i)}return l(i)}function c(e){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,i&&v();let n=t.events.length,a=n,o;for(;a--;)if(t.events[a][0]===`exit`&&t.events[a][1].type===`chunkFlow`){o=t.events[a][1].end;break}_(r);let s=n;for(;s<t.events.length;)t.events[s][1].end={...o},s++;return Oy(t.events,a+1,0,t.events.slice(n)),t.events.length=s,l(e)}return s(e)}function l(a){if(r===n.length){if(!i)return f(a);if(i.currentConstruct&&i.currentConstruct.concrete)return m(a);t.interrupt=!!(i.currentConstruct&&!i._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(Zy,u,d)(a)}function u(e){return i&&v(),_(r),f(e)}function d(e){return t.parser.lazy[t.now().line]=r!==n.length,o=t.now().offset,m(e)}function f(n){return t.containerState={},e.attempt(Zy,p,m)(n)}function p(e){return r++,n.push([t.currentConstruct,t.containerState]),f(e)}function m(n){if(n===null){i&&v(),_(0),e.consume(n);return}return i||=t.parser.flow(t.now()),e.enter(`chunkFlow`,{_tokenizer:i,contentType:`flow`,previous:a}),h(n)}function h(n){if(n===null){g(e.exit(`chunkFlow`),!0),_(0),e.consume(n);return}return Z(n)?(e.consume(n),g(e.exit(`chunkFlow`)),r=0,t.interrupt=void 0,s):(e.consume(n),h)}function g(e,n){let s=t.sliceStream(e);if(n&&s.push(null),e.previous=a,a&&(a.next=e),a=e,i.defineSkip(e.start),i.write(s),t.parser.lazy[e.start.line]){let e=i.events.length;for(;e--;)if(i.events[e][1].start.offset<o&&(!i.events[e][1].end||i.events[e][1].end.offset>o))return;let n=t.events.length,a=n,s,c;for(;a--;)if(t.events[a][0]===`exit`&&t.events[a][1].type===`chunkFlow`){if(s){c=t.events[a][1].end;break}s=!0}for(_(r),e=n;e<t.events.length;)t.events[e][1].end={...c},e++;Oy(t.events,a+1,0,t.events.slice(n)),t.events.length=e}}function _(r){let i=n.length;for(;i-->r;){let r=n[i];t.containerState=r[1],r[0].exit.call(t,e)}n.length=r}function v(){i.write([null]),a=void 0,i=void 0,t.containerState._closeFlow=void 0}}function $y(e,t,n){return $(e,e.attempt(this.parser.constructs.document,t,n),`linePrefix`,this.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)}function eb(e){if(e===null||Uy(e)||Gy(e))return 1;if(Wy(e))return 2}function tb(e,t,n){let r=[],i=-1;for(;++i<e.length;){let a=e[i].resolveAll;a&&!r.includes(a)&&(t=a(t,n),r.push(a))}return t}var nb={name:`attention`,resolveAll:rb,tokenize:ib};function rb(e,t){let n=-1,r,i,a,o,s,c,l,u;for(;++n<e.length;)if(e[n][0]===`enter`&&e[n][1].type===`attentionSequence`&&e[n][1]._close){for(r=n;r--;)if(e[r][0]===`exit`&&e[r][1].type===`attentionSequence`&&e[r][1]._open&&t.sliceSerialize(e[r][1]).charCodeAt(0)===t.sliceSerialize(e[n][1]).charCodeAt(0)){if((e[r][1]._close||e[n][1]._open)&&(e[n][1].end.offset-e[n][1].start.offset)%3&&!((e[r][1].end.offset-e[r][1].start.offset+e[n][1].end.offset-e[n][1].start.offset)%3))continue;c=e[r][1].end.offset-e[r][1].start.offset>1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;let d={...e[r][1].end},f={...e[n][1].start};ab(d,-c),ab(f,c),o={type:c>1?`strongSequence`:`emphasisSequence`,start:d,end:{...e[r][1].end}},s={type:c>1?`strongSequence`:`emphasisSequence`,start:{...e[n][1].start},end:f},a={type:c>1?`strongText`:`emphasisText`,start:{...e[r][1].end},end:{...e[n][1].start}},i={type:c>1?`strong`:`emphasis`,start:{...o.start},end:{...s.end}},e[r][1].end={...o.start},e[n][1].start={...s.end},l=[],e[r][1].end.offset-e[r][1].start.offset&&(l=ky(l,[[`enter`,e[r][1],t],[`exit`,e[r][1],t]])),l=ky(l,[[`enter`,i,t],[`enter`,o,t],[`exit`,o,t],[`enter`,a,t]]),l=ky(l,tb(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),l=ky(l,[[`exit`,a,t],[`enter`,s,t],[`exit`,s,t],[`exit`,i,t]]),e[n][1].end.offset-e[n][1].start.offset?(u=2,l=ky(l,[[`enter`,e[n][1],t],[`exit`,e[n][1],t]])):u=0,Oy(e,r-1,n-r+3,l),n=r+l.length-u-2;break}}for(n=-1;++n<e.length;)e[n][1].type===`attentionSequence`&&(e[n][1].type=`data`);return e}function ib(e,t){let n=this.parser.constructs.attentionMarkers.null,r=this.previous,i=eb(r),a;return o;function o(t){return a=t,e.enter(`attentionSequence`),s(t)}function s(o){if(o===a)return e.consume(o),s;let c=e.exit(`attentionSequence`),l=eb(o),u=!l||l===2&&i||n.includes(o),d=!i||i===2&&l||n.includes(r);return c._open=!!(a===42?u:u&&(i||!d)),c._close=!!(a===42?d:d&&(l||!u)),t(o)}}function ab(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}var ob={name:`autolink`,tokenize:sb};function sb(e,t,n){let r=0;return i;function i(t){return e.enter(`autolink`),e.enter(`autolinkMarker`),e.consume(t),e.exit(`autolinkMarker`),e.enter(`autolinkProtocol`),a}function a(t){return Iy(t)?(e.consume(t),o):t===64?n(t):l(t)}function o(e){return e===43||e===45||e===46||Ly(e)?(r=1,s(e)):l(e)}function s(t){return t===58?(e.consume(t),r=0,c):(t===43||t===45||t===46||Ly(t))&&r++<32?(e.consume(t),s):(r=0,l(t))}function c(r){return r===62?(e.exit(`autolinkProtocol`),e.enter(`autolinkMarker`),e.consume(r),e.exit(`autolinkMarker`),e.exit(`autolink`),t):r===null||r===32||r===60||zy(r)?n(r):(e.consume(r),c)}function l(t){return t===64?(e.consume(t),u):Ry(t)?(e.consume(t),l):n(t)}function u(e){return Ly(e)?d(e):n(e)}function d(n){return n===46?(e.consume(n),r=0,u):n===62?(e.exit(`autolinkProtocol`).type=`autolinkEmail`,e.enter(`autolinkMarker`),e.consume(n),e.exit(`autolinkMarker`),e.exit(`autolink`),t):f(n)}function f(t){if((t===45||Ly(t))&&r++<63){let n=t===45?f:d;return e.consume(t),n}return n(t)}}var cb={partial:!0,tokenize:lb};function lb(e,t,n){return r;function r(t){return Q(t)?$(e,i,`linePrefix`)(t):i(t)}function i(e){return e===null||Z(e)?t(e):n(e)}}var ub={continuation:{tokenize:fb},exit:pb,name:`blockQuote`,tokenize:db};function db(e,t,n){let r=this;return i;function i(t){if(t===62){let n=r.containerState;return n.open||=(e.enter(`blockQuote`,{_container:!0}),!0),e.enter(`blockQuotePrefix`),e.enter(`blockQuoteMarker`),e.consume(t),e.exit(`blockQuoteMarker`),a}return n(t)}function a(n){return Q(n)?(e.enter(`blockQuotePrefixWhitespace`),e.consume(n),e.exit(`blockQuotePrefixWhitespace`),e.exit(`blockQuotePrefix`),t):(e.exit(`blockQuotePrefix`),t(n))}}function fb(e,t,n){let r=this;return i;function i(t){return Q(t)?$(e,a,`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(t):a(t)}function a(r){return e.attempt(ub,t,n)(r)}}function pb(e){e.exit(`blockQuote`)}var mb={name:`characterEscape`,tokenize:hb};function hb(e,t,n){return r;function r(t){return e.enter(`characterEscape`),e.enter(`escapeMarker`),e.consume(t),e.exit(`escapeMarker`),i}function i(r){return Hy(r)?(e.enter(`characterEscapeValue`),e.consume(r),e.exit(`characterEscapeValue`),e.exit(`characterEscape`),t):n(r)}}var gb={name:`characterReference`,tokenize:_b};function _b(e,t,n){let r=this,i=0,a,o;return s;function s(t){return e.enter(`characterReference`),e.enter(`characterReferenceMarker`),e.consume(t),e.exit(`characterReferenceMarker`),c}function c(t){return t===35?(e.enter(`characterReferenceMarkerNumeric`),e.consume(t),e.exit(`characterReferenceMarkerNumeric`),l):(e.enter(`characterReferenceValue`),a=31,o=Ly,u(t))}function l(t){return t===88||t===120?(e.enter(`characterReferenceMarkerHexadecimal`),e.consume(t),e.exit(`characterReferenceMarkerHexadecimal`),e.enter(`characterReferenceValue`),a=6,o=Vy,u):(e.enter(`characterReferenceValue`),a=7,o=By,u(t))}function u(s){if(s===59&&i){let i=e.exit(`characterReferenceValue`);return o===Ly&&!Dy(r.sliceSerialize(i))?n(s):(e.enter(`characterReferenceMarker`),e.consume(s),e.exit(`characterReferenceMarker`),e.exit(`characterReference`),t)}return o(s)&&i++<a?(e.consume(s),u):n(s)}}var vb={partial:!0,tokenize:xb},yb={concrete:!0,name:`codeFenced`,tokenize:bb};function bb(e,t,n){let r=this,i={partial:!0,tokenize:x},a=0,o=0,s;return c;function c(e){return l(e)}function l(t){let n=r.events[r.events.length-1];return a=n&&n[1].type===`linePrefix`?n[2].sliceSerialize(n[1],!0).length:0,s=t,e.enter(`codeFenced`),e.enter(`codeFencedFence`),e.enter(`codeFencedFenceSequence`),u(t)}function u(t){return t===s?(o++,e.consume(t),u):o<3?n(t):(e.exit(`codeFencedFenceSequence`),Q(t)?$(e,d,`whitespace`)(t):d(t))}function d(n){return n===null||Z(n)?(e.exit(`codeFencedFence`),r.interrupt?t(n):e.check(vb,h,b)(n)):(e.enter(`codeFencedFenceInfo`),e.enter(`chunkString`,{contentType:`string`}),f(n))}function f(t){return t===null||Z(t)?(e.exit(`chunkString`),e.exit(`codeFencedFenceInfo`),d(t)):Q(t)?(e.exit(`chunkString`),e.exit(`codeFencedFenceInfo`),$(e,p,`whitespace`)(t)):t===96&&t===s?n(t):(e.consume(t),f)}function p(t){return t===null||Z(t)?d(t):(e.enter(`codeFencedFenceMeta`),e.enter(`chunkString`,{contentType:`string`}),m(t))}function m(t){return t===null||Z(t)?(e.exit(`chunkString`),e.exit(`codeFencedFenceMeta`),d(t)):t===96&&t===s?n(t):(e.consume(t),m)}function h(t){return e.attempt(i,b,g)(t)}function g(t){return e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),_}function _(t){return a>0&&Q(t)?$(e,v,`linePrefix`,a+1)(t):v(t)}function v(t){return t===null||Z(t)?e.check(vb,h,b)(t):(e.enter(`codeFlowValue`),y(t))}function y(t){return t===null||Z(t)?(e.exit(`codeFlowValue`),v(t)):(e.consume(t),y)}function b(n){return e.exit(`codeFenced`),t(n)}function x(e,t,n){let i=0;return a;function a(t){return e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),c}function c(t){return e.enter(`codeFencedFence`),Q(t)?$(e,l,`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(t):l(t)}function l(t){return t===s?(e.enter(`codeFencedFenceSequence`),u(t)):n(t)}function u(t){return t===s?(i++,e.consume(t),u):i>=o?(e.exit(`codeFencedFenceSequence`),Q(t)?$(e,d,`whitespace`)(t):d(t)):n(t)}function d(r){return r===null||Z(r)?(e.exit(`codeFencedFence`),t(r)):n(r)}}}function xb(e,t,n){let r=this;return i;function i(t){return t===null?n(t):(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),a)}function a(e){return r.parser.lazy[r.now().line]?n(e):t(e)}}var Sb={name:`codeIndented`,tokenize:wb},Cb={partial:!0,tokenize:Tb};function wb(e,t,n){let r=this;return i;function i(t){return e.enter(`codeIndented`),$(e,a,`linePrefix`,5)(t)}function a(e){let t=r.events[r.events.length-1];return t&&t[1].type===`linePrefix`&&t[2].sliceSerialize(t[1],!0).length>=4?o(e):n(e)}function o(t){return t===null?c(t):Z(t)?e.attempt(Cb,o,c)(t):(e.enter(`codeFlowValue`),s(t))}function s(t){return t===null||Z(t)?(e.exit(`codeFlowValue`),o(t)):(e.consume(t),s)}function c(n){return e.exit(`codeIndented`),t(n)}}function Tb(e,t,n){let r=this;return i;function i(t){return r.parser.lazy[r.now().line]?n(t):Z(t)?(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),i):$(e,a,`linePrefix`,5)(t)}function a(e){let a=r.events[r.events.length-1];return a&&a[1].type===`linePrefix`&&a[2].sliceSerialize(a[1],!0).length>=4?t(e):Z(e)?i(e):n(e)}}var Eb={name:`codeText`,previous:Ob,resolve:Db,tokenize:kb};function Db(e){let t=e.length-4,n=3,r,i;if((e[n][1].type===`lineEnding`||e[n][1].type===`space`)&&(e[t][1].type===`lineEnding`||e[t][1].type===`space`)){for(r=n;++r<t;)if(e[r][1].type===`codeTextData`){e[n][1].type=`codeTextPadding`,e[t][1].type=`codeTextPadding`,n+=2,t-=2;break}}for(r=n-1,t++;++r<=t;)i===void 0?r!==t&&e[r][1].type!==`lineEnding`&&(i=r):(r===t||e[r][1].type===`lineEnding`)&&(e[i][1].type=`codeTextData`,r!==i+2&&(e[i][1].end=e[r-1][1].end,e.splice(i+2,r-i-2),t-=r-i-2,r=i+2),i=void 0);return e}function Ob(e){return e!==96||this.events[this.events.length-1][1].type===`characterEscape`}function kb(e,t,n){let r=0,i,a;return o;function o(t){return e.enter(`codeText`),e.enter(`codeTextSequence`),s(t)}function s(t){return t===96?(e.consume(t),r++,s):(e.exit(`codeTextSequence`),c(t))}function c(t){return t===null?n(t):t===32?(e.enter(`space`),e.consume(t),e.exit(`space`),c):t===96?(a=e.enter(`codeTextSequence`),i=0,u(t)):Z(t)?(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),c):(e.enter(`codeTextData`),l(t))}function l(t){return t===null||t===32||t===96||Z(t)?(e.exit(`codeTextData`),c(t)):(e.consume(t),l)}function u(n){return n===96?(e.consume(n),i++,u):i===r?(e.exit(`codeTextSequence`),e.exit(`codeText`),t(n)):(a.type=`codeTextData`,l(n))}}var Ab=class{constructor(e){this.left=e?[...e]:[],this.right=[]}get(e){if(e<0||e>=this.left.length+this.right.length)throw RangeError("Cannot access index `"+e+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return e<this.left.length?this.left[e]:this.right[this.right.length-e+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(e,t){let n=t??1/0;return n<this.left.length?this.left.slice(e,n):e>this.left.length?this.right.slice(this.right.length-n+this.left.length,this.right.length-e+this.left.length).reverse():this.left.slice(e).concat(this.right.slice(this.right.length-n+this.left.length).reverse())}splice(e,t,n){let r=t||0;this.setCursor(Math.trunc(e));let i=this.right.splice(this.right.length-r,1/0);return n&&jb(this.left,n),i.reverse()}pop(){return this.setCursor(1/0),this.left.pop()}push(e){this.setCursor(1/0),this.left.push(e)}pushMany(e){this.setCursor(1/0),jb(this.left,e)}unshift(e){this.setCursor(0),this.right.push(e)}unshiftMany(e){this.setCursor(0),jb(this.right,e.reverse())}setCursor(e){if(!(e===this.left.length||e>this.left.length&&this.right.length===0||e<0&&this.left.length===0)){if(e<this.left.length){let t=this.left.splice(e,1/0);jb(this.right,t.reverse())}else{let t=this.right.splice(this.left.length+this.right.length-e,1/0);jb(this.left,t.reverse())}}}};function jb(e,t){let n=0;if(t.length<1e4)e.push(...t);else for(;n<t.length;)e.push(...t.slice(n,n+1e4)),n+=1e4}function Mb(e){let t={},n=-1,r,i,a,o,s,c,l,u=new Ab(e);for(;++n<u.length;){for(;n in t;)n=t[n];if(r=u.get(n),n&&r[1].type===`chunkFlow`&&u.get(n-1)[1].type===`listItemPrefix`&&(c=r[1]._tokenizer.events,a=0,a<c.length&&c[a][1].type===`lineEndingBlank`&&(a+=2),a<c.length&&c[a][1].type===`content`))for(;++a<c.length&&c[a][1].type!==`content`;)c[a][1].type===`chunkText`&&(c[a][1]._isInFirstContentOfListItem=!0,a++);if(r[0]===`enter`)r[1].contentType&&(Object.assign(t,Nb(u,n)),n=t[n],l=!0);else if(r[1]._container){for(a=n,i=void 0;a--;)if(o=u.get(a),o[1].type===`lineEnding`||o[1].type===`lineEndingBlank`)o[0]===`enter`&&(i&&(u.get(i)[1].type=`lineEndingBlank`),o[1].type=`lineEnding`,i=a);else if(o[1].type!==`linePrefix`&&o[1].type!==`listItemIndent`)break;i&&(r[1].end={...u.get(i)[1].start},s=u.slice(i,n),s.unshift(r),u.splice(i,n-i+1,s))}}return Oy(e,0,1/0,u.slice(0)),!l}function Nb(e,t){let n=e.get(t)[1],r=e.get(t)[2],i=t-1,a=[],o=n._tokenizer;o||(o=r.parser[n.contentType](n.start),n._contentTypeTextTrailing&&(o._contentTypeTextTrailing=!0));let s=o.events,c=[],l={},u,d,f=-1,p=n,m=0,h=0,g=[h];for(;p;){for(;e.get(++i)[1]!==p;);a.push(i),p._tokenizer||(u=r.sliceStream(p),p.next||u.push(null),d&&o.defineSkip(p.start),p._isInFirstContentOfListItem&&(o._gfmTasklistFirstContentOfListItem=!0),o.write(u),p._isInFirstContentOfListItem&&(o._gfmTasklistFirstContentOfListItem=void 0)),d=p,p=p.next}for(p=n;++f<s.length;)s[f][0]===`exit`&&s[f-1][0]===`enter`&&s[f][1].type===s[f-1][1].type&&s[f][1].start.line!==s[f][1].end.line&&(h=f+1,g.push(h),p._tokenizer=void 0,p.previous=void 0,p=p.next);for(o.events=[],p?(p._tokenizer=void 0,p.previous=void 0):g.pop(),f=g.length;f--;){let t=s.slice(g[f],g[f+1]),n=a.pop();c.push([n,n+t.length-1]),e.splice(n,2,t)}for(c.reverse(),f=-1;++f<c.length;)l[m+c[f][0]]=m+c[f][1],m+=c[f][1]-c[f][0]-1;return l}var Pb={resolve:Ib,tokenize:Lb},Fb={partial:!0,tokenize:Rb};function Ib(e){return Mb(e),e}function Lb(e,t){let n;return r;function r(t){return e.enter(`content`),n=e.enter(`chunkContent`,{contentType:`content`}),i(t)}function i(t){return t===null?a(t):Z(t)?e.check(Fb,o,a)(t):(e.consume(t),i)}function a(n){return e.exit(`chunkContent`),e.exit(`content`),t(n)}function o(t){return e.consume(t),e.exit(`chunkContent`),n.next=e.enter(`chunkContent`,{contentType:`content`,previous:n}),n=n.next,i}}function Rb(e,t,n){let r=this;return i;function i(t){return e.exit(`chunkContent`),e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),$(e,a,`linePrefix`)}function a(i){if(i===null||Z(i))return n(i);let a=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes(`codeIndented`)&&a&&a[1].type===`linePrefix`&&a[2].sliceSerialize(a[1],!0).length>=4?t(i):e.interrupt(r.parser.constructs.flow,n,t)(i)}}function zb(e,t,n,r,i,a,o,s,c){let l=c||1/0,u=0;return d;function d(t){return t===60?(e.enter(r),e.enter(i),e.enter(a),e.consume(t),e.exit(a),f):t===null||t===32||t===41||zy(t)?n(t):(e.enter(r),e.enter(o),e.enter(s),e.enter(`chunkString`,{contentType:`string`}),h(t))}function f(n){return n===62?(e.enter(a),e.consume(n),e.exit(a),e.exit(i),e.exit(r),t):(e.enter(s),e.enter(`chunkString`,{contentType:`string`}),p(n))}function p(t){return t===62?(e.exit(`chunkString`),e.exit(s),f(t)):t===null||t===60||Z(t)?n(t):(e.consume(t),t===92?m:p)}function m(t){return t===60||t===62||t===92?(e.consume(t),p):p(t)}function h(i){return!u&&(i===null||i===41||Uy(i))?(e.exit(`chunkString`),e.exit(s),e.exit(o),e.exit(r),t(i)):u<l&&i===40?(e.consume(i),u++,h):i===41?(e.consume(i),u--,h):i===null||i===32||i===40||zy(i)?n(i):(e.consume(i),i===92?g:h)}function g(t){return t===40||t===41||t===92?(e.consume(t),h):h(t)}}function Bb(e,t,n,r,i,a){let o=this,s=0,c;return l;function l(t){return e.enter(r),e.enter(i),e.consume(t),e.exit(i),e.enter(a),u}function u(l){return s>999||l===null||l===91||l===93&&!c||l===94&&!s&&`_hiddenFootnoteSupport`in o.parser.constructs?n(l):l===93?(e.exit(a),e.enter(i),e.consume(l),e.exit(i),e.exit(r),t):Z(l)?(e.enter(`lineEnding`),e.consume(l),e.exit(`lineEnding`),u):(e.enter(`chunkString`,{contentType:`string`}),d(l))}function d(t){return t===null||t===91||t===93||Z(t)||s++>999?(e.exit(`chunkString`),u(t)):(e.consume(t),c||=!Q(t),t===92?f:d)}function f(t){return t===91||t===92||t===93?(e.consume(t),s++,d):d(t)}}function Vb(e,t,n,r,i,a){let o;return s;function s(t){return t===34||t===39||t===40?(e.enter(r),e.enter(i),e.consume(t),e.exit(i),o=t===40?41:t,c):n(t)}function c(n){return n===o?(e.enter(i),e.consume(n),e.exit(i),e.exit(r),t):(e.enter(a),l(n))}function l(t){return t===o?(e.exit(a),c(o)):t===null?n(t):Z(t)?(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),$(e,l,`linePrefix`)):(e.enter(`chunkString`,{contentType:`string`}),u(t))}function u(t){return t===o||t===null||Z(t)?(e.exit(`chunkString`),l(t)):(e.consume(t),t===92?d:u)}function d(t){return t===o||t===92?(e.consume(t),u):u(t)}}function Hb(e,t){let n;return r;function r(i){return Z(i)?(e.enter(`lineEnding`),e.consume(i),e.exit(`lineEnding`),n=!0,r):Q(i)?$(e,r,n?`linePrefix`:`lineSuffix`)(i):t(i)}}var Ub={name:`definition`,tokenize:Gb},Wb={partial:!0,tokenize:Kb};function Gb(e,t,n){let r=this,i;return a;function a(t){return e.enter(`definition`),o(t)}function o(t){return Bb.call(r,e,s,n,`definitionLabel`,`definitionLabelMarker`,`definitionLabelString`)(t)}function s(t){return i=Fy(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),t===58?(e.enter(`definitionMarker`),e.consume(t),e.exit(`definitionMarker`),c):n(t)}function c(t){return Uy(t)?Hb(e,l)(t):l(t)}function l(t){return zb(e,u,n,`definitionDestination`,`definitionDestinationLiteral`,`definitionDestinationLiteralMarker`,`definitionDestinationRaw`,`definitionDestinationString`)(t)}function u(t){return e.attempt(Wb,d,d)(t)}function d(t){return Q(t)?$(e,f,`whitespace`)(t):f(t)}function f(a){return a===null||Z(a)?(e.exit(`definition`),r.parser.defined.push(i),t(a)):n(a)}}function Kb(e,t,n){return r;function r(t){return Uy(t)?Hb(e,i)(t):n(t)}function i(t){return Vb(e,a,n,`definitionTitle`,`definitionTitleMarker`,`definitionTitleString`)(t)}function a(t){return Q(t)?$(e,o,`whitespace`)(t):o(t)}function o(e){return e===null||Z(e)?t(e):n(e)}}var qb={name:`hardBreakEscape`,tokenize:Jb};function Jb(e,t,n){return r;function r(t){return e.enter(`hardBreakEscape`),e.consume(t),i}function i(r){return Z(r)?(e.exit(`hardBreakEscape`),t(r)):n(r)}}var Yb={name:`headingAtx`,resolve:Xb,tokenize:Zb};function Xb(e,t){let n=e.length-2,r=3,i,a;return e[r][1].type===`whitespace`&&(r+=2),n-2>r&&e[n][1].type===`whitespace`&&(n-=2),e[n][1].type===`atxHeadingSequence`&&(r===n-1||n-4>r&&e[n-2][1].type===`whitespace`)&&(n-=r+1===n?2:4),n>r&&(i={type:`atxHeadingText`,start:e[r][1].start,end:e[n][1].end},a={type:`chunkText`,start:e[r][1].start,end:e[n][1].end,contentType:`text`},Oy(e,r,n-r+1,[[`enter`,i,t],[`enter`,a,t],[`exit`,a,t],[`exit`,i,t]])),e}function Zb(e,t,n){let r=0;return i;function i(t){return e.enter(`atxHeading`),a(t)}function a(t){return e.enter(`atxHeadingSequence`),o(t)}function o(t){return t===35&&r++<6?(e.consume(t),o):t===null||Uy(t)?(e.exit(`atxHeadingSequence`),s(t)):n(t)}function s(n){return n===35?(e.enter(`atxHeadingSequence`),c(n)):n===null||Z(n)?(e.exit(`atxHeading`),t(n)):Q(n)?$(e,s,`whitespace`)(n):(e.enter(`atxHeadingText`),l(n))}function c(t){return t===35?(e.consume(t),c):(e.exit(`atxHeadingSequence`),s(t))}function l(t){return t===null||t===35||Uy(t)?(e.exit(`atxHeadingText`),s(t)):(e.consume(t),l)}}var Qb=`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(`.`),$b=[`pre`,`script`,`style`,`textarea`],ex={concrete:!0,name:`htmlFlow`,resolveTo:rx,tokenize:ix},tx={partial:!0,tokenize:ox},nx={partial:!0,tokenize:ax};function rx(e){let t=e.length;for(;t--&&(e[t][0]!==`enter`||e[t][1].type!==`htmlFlow`););return t>1&&e[t-2][1].type===`linePrefix`&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function ix(e,t,n){let r=this,i,a,o,s,c;return l;function l(e){return u(e)}function u(t){return e.enter(`htmlFlow`),e.enter(`htmlFlowData`),e.consume(t),d}function d(s){return s===33?(e.consume(s),f):s===47?(e.consume(s),a=!0,h):s===63?(e.consume(s),i=3,r.interrupt?t:k):Iy(s)?(e.consume(s),o=String.fromCharCode(s),g):n(s)}function f(a){return a===45?(e.consume(a),i=2,p):a===91?(e.consume(a),i=5,s=0,m):Iy(a)?(e.consume(a),i=4,r.interrupt?t:k):n(a)}function p(i){return i===45?(e.consume(i),r.interrupt?t:k):n(i)}function m(i){return i===`CDATA[`.charCodeAt(s++)?(e.consume(i),s===6?r.interrupt?t:D:m):n(i)}function h(t){return Iy(t)?(e.consume(t),o=String.fromCharCode(t),g):n(t)}function g(s){if(s===null||s===47||s===62||Uy(s)){let c=s===47,l=o.toLowerCase();return!c&&!a&&$b.includes(l)?(i=1,r.interrupt?t(s):D(s)):Qb.includes(o.toLowerCase())?(i=6,c?(e.consume(s),_):r.interrupt?t(s):D(s)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(s):a?v(s):y(s))}return s===45||Ly(s)?(e.consume(s),o+=String.fromCharCode(s),g):n(s)}function _(i){return i===62?(e.consume(i),r.interrupt?t:D):n(i)}function v(t){return Q(t)?(e.consume(t),v):E(t)}function y(t){return t===47?(e.consume(t),E):t===58||t===95||Iy(t)?(e.consume(t),b):Q(t)?(e.consume(t),y):E(t)}function b(t){return t===45||t===46||t===58||t===95||Ly(t)?(e.consume(t),b):x(t)}function x(t){return t===61?(e.consume(t),S):Q(t)?(e.consume(t),x):y(t)}function S(t){return t===null||t===60||t===61||t===62||t===96?n(t):t===34||t===39?(e.consume(t),c=t,C):Q(t)?(e.consume(t),S):w(t)}function C(t){return t===c?(e.consume(t),c=null,T):t===null||Z(t)?n(t):(e.consume(t),C)}function w(t){return t===null||t===34||t===39||t===47||t===60||t===61||t===62||t===96||Uy(t)?x(t):(e.consume(t),w)}function T(e){return e===47||e===62||Q(e)?y(e):n(e)}function E(t){return t===62?(e.consume(t),ee):n(t)}function ee(t){return t===null||Z(t)?D(t):Q(t)?(e.consume(t),ee):n(t)}function D(t){return t===45&&i===2?(e.consume(t),re):t===60&&i===1?(e.consume(t),ie):t===62&&i===4?(e.consume(t),A):t===63&&i===3?(e.consume(t),k):t===93&&i===5?(e.consume(t),oe):Z(t)&&(i===6||i===7)?(e.exit(`htmlFlowData`),e.check(tx,se,O)(t)):t===null||Z(t)?(e.exit(`htmlFlowData`),O(t)):(e.consume(t),D)}function O(t){return e.check(nx,te,se)(t)}function te(t){return e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),ne}function ne(t){return t===null||Z(t)?O(t):(e.enter(`htmlFlowData`),D(t))}function re(t){return t===45?(e.consume(t),k):D(t)}function ie(t){return t===47?(e.consume(t),o=``,ae):D(t)}function ae(t){if(t===62){let n=o.toLowerCase();return $b.includes(n)?(e.consume(t),A):D(t)}return Iy(t)&&o.length<8?(e.consume(t),o+=String.fromCharCode(t),ae):D(t)}function oe(t){return t===93?(e.consume(t),k):D(t)}function k(t){return t===62?(e.consume(t),A):t===45&&i===2?(e.consume(t),k):D(t)}function A(t){return t===null||Z(t)?(e.exit(`htmlFlowData`),se(t)):(e.consume(t),A)}function se(n){return e.exit(`htmlFlow`),t(n)}}function ax(e,t,n){let r=this;return i;function i(t){return Z(t)?(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),a):n(t)}function a(e){return r.parser.lazy[r.now().line]?n(e):t(e)}}function ox(e,t,n){return r;function r(r){return e.enter(`lineEnding`),e.consume(r),e.exit(`lineEnding`),e.attempt(cb,t,n)}}var sx={name:`htmlText`,tokenize:cx};function cx(e,t,n){let r=this,i,a,o;return s;function s(t){return e.enter(`htmlText`),e.enter(`htmlTextData`),e.consume(t),c}function c(t){return t===33?(e.consume(t),l):t===47?(e.consume(t),x):t===63?(e.consume(t),y):Iy(t)?(e.consume(t),w):n(t)}function l(t){return t===45?(e.consume(t),u):t===91?(e.consume(t),a=0,m):Iy(t)?(e.consume(t),v):n(t)}function u(t){return t===45?(e.consume(t),p):n(t)}function d(t){return t===null?n(t):t===45?(e.consume(t),f):Z(t)?(o=d,ie(t)):(e.consume(t),d)}function f(t){return t===45?(e.consume(t),p):d(t)}function p(e){return e===62?re(e):e===45?f(e):d(e)}function m(t){return t===`CDATA[`.charCodeAt(a++)?(e.consume(t),a===6?h:m):n(t)}function h(t){return t===null?n(t):t===93?(e.consume(t),g):Z(t)?(o=h,ie(t)):(e.consume(t),h)}function g(t){return t===93?(e.consume(t),_):h(t)}function _(t){return t===62?re(t):t===93?(e.consume(t),_):h(t)}function v(t){return t===null||t===62?re(t):Z(t)?(o=v,ie(t)):(e.consume(t),v)}function y(t){return t===null?n(t):t===63?(e.consume(t),b):Z(t)?(o=y,ie(t)):(e.consume(t),y)}function b(e){return e===62?re(e):y(e)}function x(t){return Iy(t)?(e.consume(t),S):n(t)}function S(t){return t===45||Ly(t)?(e.consume(t),S):C(t)}function C(t){return Z(t)?(o=C,ie(t)):Q(t)?(e.consume(t),C):re(t)}function w(t){return t===45||Ly(t)?(e.consume(t),w):t===47||t===62||Uy(t)?T(t):n(t)}function T(t){return t===47?(e.consume(t),re):t===58||t===95||Iy(t)?(e.consume(t),E):Z(t)?(o=T,ie(t)):Q(t)?(e.consume(t),T):re(t)}function E(t){return t===45||t===46||t===58||t===95||Ly(t)?(e.consume(t),E):ee(t)}function ee(t){return t===61?(e.consume(t),D):Z(t)?(o=ee,ie(t)):Q(t)?(e.consume(t),ee):T(t)}function D(t){return t===null||t===60||t===61||t===62||t===96?n(t):t===34||t===39?(e.consume(t),i=t,O):Z(t)?(o=D,ie(t)):Q(t)?(e.consume(t),D):(e.consume(t),te)}function O(t){return t===i?(e.consume(t),i=void 0,ne):t===null?n(t):Z(t)?(o=O,ie(t)):(e.consume(t),O)}function te(t){return t===null||t===34||t===39||t===60||t===61||t===96?n(t):t===47||t===62||Uy(t)?T(t):(e.consume(t),te)}function ne(e){return e===47||e===62||Uy(e)?T(e):n(e)}function re(r){return r===62?(e.consume(r),e.exit(`htmlTextData`),e.exit(`htmlText`),t):n(r)}function ie(t){return e.exit(`htmlTextData`),e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),ae}function ae(t){return Q(t)?$(e,oe,`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(t):oe(t)}function oe(t){return e.enter(`htmlTextData`),o(t)}}var lx={name:`labelEnd`,resolveAll:px,resolveTo:mx,tokenize:hx},ux={tokenize:gx},dx={tokenize:_x},fx={tokenize:vx};function px(e){let t=-1,n=[];for(;++t<e.length;){let r=e[t][1];if(n.push(e[t]),r.type===`labelImage`||r.type===`labelLink`||r.type===`labelEnd`){let e=r.type===`labelImage`?4:2;r.type=`data`,t+=e}}return e.length!==n.length&&Oy(e,0,e.length,n),e}function mx(e,t){let n=e.length,r=0,i,a,o,s;for(;n--;)if(i=e[n][1],a){if(i.type===`link`||i.type===`labelLink`&&i._inactive)break;e[n][0]===`enter`&&i.type===`labelLink`&&(i._inactive=!0)}else if(o){if(e[n][0]===`enter`&&(i.type===`labelImage`||i.type===`labelLink`)&&!i._balanced&&(a=n,i.type!==`labelLink`)){r=2;break}}else i.type===`labelEnd`&&(o=n);let c={type:e[a][1].type===`labelLink`?`link`:`image`,start:{...e[a][1].start},end:{...e[e.length-1][1].end}},l={type:`label`,start:{...e[a][1].start},end:{...e[o][1].end}},u={type:`labelText`,start:{...e[a+r+2][1].end},end:{...e[o-2][1].start}};return s=[[`enter`,c,t],[`enter`,l,t]],s=ky(s,e.slice(a+1,a+r+3)),s=ky(s,[[`enter`,u,t]]),s=ky(s,tb(t.parser.constructs.insideSpan.null,e.slice(a+r+4,o-3),t)),s=ky(s,[[`exit`,u,t],e[o-2],e[o-1],[`exit`,l,t]]),s=ky(s,e.slice(o+1)),s=ky(s,[[`exit`,c,t]]),Oy(e,a,e.length,s),e}function hx(e,t,n){let r=this,i=r.events.length,a,o;for(;i--;)if((r.events[i][1].type===`labelImage`||r.events[i][1].type===`labelLink`)&&!r.events[i][1]._balanced){a=r.events[i][1];break}return s;function s(t){return a?a._inactive?d(t):(o=r.parser.defined.includes(Fy(r.sliceSerialize({start:a.end,end:r.now()}))),e.enter(`labelEnd`),e.enter(`labelMarker`),e.consume(t),e.exit(`labelMarker`),e.exit(`labelEnd`),c):n(t)}function c(t){return t===40?e.attempt(ux,u,o?u:d)(t):t===91?e.attempt(dx,u,o?l:d)(t):o?u(t):d(t)}function l(t){return e.attempt(fx,u,d)(t)}function u(e){return t(e)}function d(e){return a._balanced=!0,n(e)}}function gx(e,t,n){return r;function r(t){return e.enter(`resource`),e.enter(`resourceMarker`),e.consume(t),e.exit(`resourceMarker`),i}function i(t){return Uy(t)?Hb(e,a)(t):a(t)}function a(t){return t===41?u(t):zb(e,o,s,`resourceDestination`,`resourceDestinationLiteral`,`resourceDestinationLiteralMarker`,`resourceDestinationRaw`,`resourceDestinationString`,32)(t)}function o(t){return Uy(t)?Hb(e,c)(t):u(t)}function s(e){return n(e)}function c(t){return t===34||t===39||t===40?Vb(e,l,n,`resourceTitle`,`resourceTitleMarker`,`resourceTitleString`)(t):u(t)}function l(t){return Uy(t)?Hb(e,u)(t):u(t)}function u(r){return r===41?(e.enter(`resourceMarker`),e.consume(r),e.exit(`resourceMarker`),e.exit(`resource`),t):n(r)}}function _x(e,t,n){let r=this;return i;function i(t){return Bb.call(r,e,a,o,`reference`,`referenceMarker`,`referenceString`)(t)}function a(e){return r.parser.defined.includes(Fy(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(e):n(e)}function o(e){return n(e)}}function vx(e,t,n){return r;function r(t){return e.enter(`reference`),e.enter(`referenceMarker`),e.consume(t),e.exit(`referenceMarker`),i}function i(r){return r===93?(e.enter(`referenceMarker`),e.consume(r),e.exit(`referenceMarker`),e.exit(`reference`),t):n(r)}}var yx={name:`labelStartImage`,resolveAll:lx.resolveAll,tokenize:bx};function bx(e,t,n){let r=this;return i;function i(t){return e.enter(`labelImage`),e.enter(`labelImageMarker`),e.consume(t),e.exit(`labelImageMarker`),a}function a(t){return t===91?(e.enter(`labelMarker`),e.consume(t),e.exit(`labelMarker`),e.exit(`labelImage`),o):n(t)}function o(e){return e===94&&`_hiddenFootnoteSupport`in r.parser.constructs?n(e):t(e)}}var xx={name:`labelStartLink`,resolveAll:lx.resolveAll,tokenize:Sx};function Sx(e,t,n){let r=this;return i;function i(t){return e.enter(`labelLink`),e.enter(`labelMarker`),e.consume(t),e.exit(`labelMarker`),e.exit(`labelLink`),a}function a(e){return e===94&&`_hiddenFootnoteSupport`in r.parser.constructs?n(e):t(e)}}var Cx={name:`lineEnding`,tokenize:wx};function wx(e,t){return n;function n(n){return e.enter(`lineEnding`),e.consume(n),e.exit(`lineEnding`),$(e,t,`linePrefix`)}}var Tx={name:`thematicBreak`,tokenize:Ex};function Ex(e,t,n){let r=0,i;return a;function a(t){return e.enter(`thematicBreak`),o(t)}function o(e){return i=e,s(e)}function s(a){return a===i?(e.enter(`thematicBreakSequence`),c(a)):r>=3&&(a===null||Z(a))?(e.exit(`thematicBreak`),t(a)):n(a)}function c(t){return t===i?(e.consume(t),r++,c):(e.exit(`thematicBreakSequence`),Q(t)?$(e,s,`whitespace`)(t):s(t))}}var Dx={continuation:{tokenize:jx},exit:Nx,name:`list`,tokenize:Ax},Ox={partial:!0,tokenize:Px},kx={partial:!0,tokenize:Mx};function Ax(e,t,n){let r=this,i=r.events[r.events.length-1],a=i&&i[1].type===`linePrefix`?i[2].sliceSerialize(i[1],!0).length:0,o=0;return s;function s(t){let i=r.containerState.type||(t===42||t===43||t===45?`listUnordered`:`listOrdered`);if(i===`listUnordered`?!r.containerState.marker||t===r.containerState.marker:By(t)){if(r.containerState.type||(r.containerState.type=i,e.enter(i,{_container:!0})),i===`listUnordered`)return e.enter(`listItemPrefix`),t===42||t===45?e.check(Tx,n,l)(t):l(t);if(!r.interrupt||t===49)return e.enter(`listItemPrefix`),e.enter(`listItemValue`),c(t)}return n(t)}function c(t){return By(t)&&++o<10?(e.consume(t),c):(!r.interrupt||o<2)&&(r.containerState.marker?t===r.containerState.marker:t===41||t===46)?(e.exit(`listItemValue`),l(t)):n(t)}function l(t){return e.enter(`listItemMarker`),e.consume(t),e.exit(`listItemMarker`),r.containerState.marker=r.containerState.marker||t,e.check(cb,r.interrupt?n:u,e.attempt(Ox,f,d))}function u(e){return r.containerState.initialBlankLine=!0,a++,f(e)}function d(t){return Q(t)?(e.enter(`listItemPrefixWhitespace`),e.consume(t),e.exit(`listItemPrefixWhitespace`),f):n(t)}function f(n){return r.containerState.size=a+r.sliceSerialize(e.exit(`listItemPrefix`),!0).length,t(n)}}function jx(e,t,n){let r=this;return r.containerState._closeFlow=void 0,e.check(cb,i,a);function i(n){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,$(e,t,`listItemIndent`,r.containerState.size+1)(n)}function a(n){return r.containerState.furtherBlankLines||!Q(n)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,o(n)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(kx,t,o)(n))}function o(i){return r.containerState._closeFlow=!0,r.interrupt=void 0,$(e,e.attempt(Dx,t,n),`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(i)}}function Mx(e,t,n){let r=this;return $(e,i,`listItemIndent`,r.containerState.size+1);function i(e){let i=r.events[r.events.length-1];return i&&i[1].type===`listItemIndent`&&i[2].sliceSerialize(i[1],!0).length===r.containerState.size?t(e):n(e)}}function Nx(e){e.exit(this.containerState.type)}function Px(e,t,n){let r=this;return $(e,i,`listItemPrefixWhitespace`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:5);function i(e){let i=r.events[r.events.length-1];return!Q(e)&&i&&i[1].type===`listItemPrefixWhitespace`?t(e):n(e)}}var Fx={name:`setextUnderline`,resolveTo:Ix,tokenize:Lx};function Ix(e,t){let n=e.length,r,i,a;for(;n--;)if(e[n][0]===`enter`){if(e[n][1].type===`content`){r=n;break}e[n][1].type===`paragraph`&&(i=n)}else e[n][1].type===`content`&&e.splice(n,1),!a&&e[n][1].type===`definition`&&(a=n);let o={type:`setextHeading`,start:{...e[r][1].start},end:{...e[e.length-1][1].end}};return e[i][1].type=`setextHeadingText`,a?(e.splice(i,0,[`enter`,o,t]),e.splice(a+1,0,[`exit`,e[r][1],t]),e[r][1].end={...e[a][1].end}):e[r][1]=o,e.push([`exit`,o,t]),e}function Lx(e,t,n){let r=this,i;return a;function a(t){let a=r.events.length,s;for(;a--;)if(r.events[a][1].type!==`lineEnding`&&r.events[a][1].type!==`linePrefix`&&r.events[a][1].type!==`content`){s=r.events[a][1].type===`paragraph`;break}return!r.parser.lazy[r.now().line]&&(r.interrupt||s)?(e.enter(`setextHeadingLine`),i=t,o(t)):n(t)}function o(t){return e.enter(`setextHeadingLineSequence`),s(t)}function s(t){return t===i?(e.consume(t),s):(e.exit(`setextHeadingLineSequence`),Q(t)?$(e,c,`lineSuffix`)(t):c(t))}function c(r){return r===null||Z(r)?(e.exit(`setextHeadingLine`),t(r)):n(r)}}var Rx={tokenize:zx};function zx(e){let t=this,n=e.attempt(cb,r,e.attempt(this.parser.constructs.flowInitial,i,$(e,e.attempt(this.parser.constructs.flow,i,e.attempt(Pb,i)),`linePrefix`)));return n;function r(r){if(r===null){e.consume(r);return}return e.enter(`lineEndingBlank`),e.consume(r),e.exit(`lineEndingBlank`),t.currentConstruct=void 0,n}function i(r){if(r===null){e.consume(r);return}return e.enter(`lineEnding`),e.consume(r),e.exit(`lineEnding`),t.currentConstruct=void 0,n}}var Bx={resolveAll:Wx()},Vx=Ux(`string`),Hx=Ux(`text`);function Ux(e){return{resolveAll:Wx(e===`text`?Gx:void 0),tokenize:t};function t(t){let n=this,r=this.parser.constructs[e],i=t.attempt(r,a,o);return a;function a(e){return c(e)?i(e):o(e)}function o(e){if(e===null){t.consume(e);return}return t.enter(`data`),t.consume(e),s}function s(e){return c(e)?(t.exit(`data`),i(e)):(t.consume(e),s)}function c(e){if(e===null)return!0;let t=r[e],i=-1;if(t)for(;++i<t.length;){let e=t[i];if(!e.previous||e.previous.call(n,n.previous))return!0}return!1}}}function Wx(e){return t;function t(t,n){let r=-1,i;for(;++r<=t.length;)i===void 0?t[r]&&t[r][1].type===`data`&&(i=r,r++):(!t[r]||t[r][1].type!==`data`)&&(r!==i+2&&(t[i][1].end=t[r-1][1].end,t.splice(i+2,r-i-2),r=i+2),i=void 0);return e?e(t,n):t}}function Gx(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||e[n][1].type===`lineEnding`)&&e[n-1][1].type===`data`){let r=e[n-1][1],i=t.sliceStream(r),a=i.length,o=-1,s=0,c;for(;a--;){let e=i[a];if(typeof e==`string`){for(o=e.length;e.charCodeAt(o-1)===32;)s++,o--;if(o)break;o=-1}else if(e===-2)c=!0,s++;else if(e!==-1){a++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(s=0),s){let i={type:n===e.length||c||s<2?`lineSuffix`:`hardBreakTrailing`,start:{_bufferIndex:a?o:r.start._bufferIndex+o,_index:r.start._index+a,line:r.end.line,column:r.end.column-s,offset:r.end.offset-s},end:{...r.end}};r.end={...i.start},r.start.offset===r.end.offset?Object.assign(r,i):(e.splice(n,0,[`enter`,i,t],[`exit`,i,t]),n+=2)}n++}return e}var Kx=s({attentionMarkers:()=>eS,contentInitial:()=>Jx,disable:()=>tS,document:()=>qx,flow:()=>Xx,flowInitial:()=>Yx,insideSpan:()=>$x,string:()=>Zx,text:()=>Qx}),qx={42:Dx,43:Dx,45:Dx,48:Dx,49:Dx,50:Dx,51:Dx,52:Dx,53:Dx,54:Dx,55:Dx,56:Dx,57:Dx,62:ub},Jx={91:Ub},Yx={[-2]:Sb,[-1]:Sb,32:Sb},Xx={35:Yb,42:Tx,45:[Fx,Tx],60:ex,61:Fx,95:Tx,96:yb,126:yb},Zx={38:gb,92:mb},Qx={[-5]:Cx,[-4]:Cx,[-3]:Cx,33:yx,38:gb,42:nb,60:[ob,sx],91:xx,92:[qb,mb],93:lx,95:nb,96:Eb},$x={null:[nb,Bx]},eS={null:[42,95]},tS={null:[]};function nS(e,t,n){let r={_bufferIndex:-1,_index:0,line:n&&n.line||1,column:n&&n.column||1,offset:n&&n.offset||0},i={},a=[],o=[],s=[],c={attempt:C(x),check:C(S),consume:v,enter:y,exit:b,interrupt:C(S,{interrupt:!0})},l={code:null,containerState:{},defineSkip:h,events:[],now:m,parser:e,previous:null,sliceSerialize:f,sliceStream:p,write:d},u=t.tokenize.call(l,c);return t.resolveAll&&a.push(t),l;function d(e){return o=ky(o,e),g(),o[o.length-1]===null?(w(t,0),l.events=tb(a,l.events,l),l.events):[]}function f(e,t){return iS(p(e),t)}function p(e){return rS(o,e)}function m(){let{_bufferIndex:e,_index:t,line:n,column:i,offset:a}=r;return{_bufferIndex:e,_index:t,line:n,column:i,offset:a}}function h(e){i[e.line]=e.column,E()}function g(){let e;for(;r._index<o.length;){let t=o[r._index];if(typeof t==`string`)for(e=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===e&&r._bufferIndex<t.length;)_(t.charCodeAt(r._bufferIndex));else _(t)}}function _(e){u=u(e)}function v(e){Z(e)?(r.line++,r.column=1,r.offset+=e===-3?2:1,E()):e!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===o[r._index].length&&(r._bufferIndex=-1,r._index++)),l.previous=e}function y(e,t){let n=t||{};return n.type=e,n.start=m(),l.events.push([`enter`,n,l]),s.push(n),n}function b(e){let t=s.pop();return t.end=m(),l.events.push([`exit`,t,l]),t}function x(e,t){w(e,t.from)}function S(e,t){t.restore()}function C(e,t){return n;function n(n,r,i){let a,o,s,u;return Array.isArray(n)?f(n):`tokenize`in n?f([n]):d(n);function d(e){return t;function t(t){let n=t!==null&&e[t],r=t!==null&&e.null;return f([...Array.isArray(n)?n:n?[n]:[],...Array.isArray(r)?r:r?[r]:[]])(t)}}function f(e){return a=e,o=0,e.length===0?i:p(e[o])}function p(e){return n;function n(n){return u=T(),s=e,e.partial||(l.currentConstruct=e),e.name&&l.parser.constructs.disable.null.includes(e.name)?h(n):e.tokenize.call(t?Object.assign(Object.create(l),t):l,c,m,h)(n)}}function m(t){return e(s,u),r}function h(e){return u.restore(),++o<a.length?p(a[o]):i}}}function w(e,t){e.resolveAll&&!a.includes(e)&&a.push(e),e.resolve&&Oy(l.events,t,l.events.length-t,e.resolve(l.events.slice(t),l)),e.resolveTo&&(l.events=e.resolveTo(l.events,l))}function T(){let e=m(),t=l.previous,n=l.currentConstruct,i=l.events.length,a=Array.from(s);return{from:i,restore:o};function o(){r=e,l.previous=t,l.currentConstruct=n,l.events.length=i,s=a,E()}}function E(){r.line in i&&r.column<2&&(r.column=i[r.line],r.offset+=i[r.line]-1)}}function rS(e,t){let n=t.start._index,r=t.start._bufferIndex,i=t.end._index,a=t.end._bufferIndex,o;if(n===i)o=[e[n].slice(r,a)];else{if(o=e.slice(n,i),r>-1){let e=o[0];typeof e==`string`?o[0]=e.slice(r):o.shift()}a>0&&o.push(e[i].slice(0,a))}return o}function iS(e,t){let n=-1,r=[],i;for(;++n<e.length;){let a=e[n],o;if(typeof a==`string`)o=a;else switch(a){case-5:o=`\r`;break;case-4:o=`
|
|
1537
|
+
`}function h_(e,t){return Math.max(e.additionLines.length,e.deletionLines.length)>t}function g_(e,t){return e.isPartial&&t&&(e.type===`change`||e.type===`rename-changed`)}function __(e,t){return e.lineNumber===t.lineNumber&&e.side===t.side&&e.metadata===t.metadata}function v_(e,t){return e.slotName===t.slotName&&e.hunkIndex===t.hunkIndex&&e.lines===t.lines&&e.lineCountKnown===t.lineCountKnown&&e.type===t.type&&e.expandable?.chunked===t.expandable?.chunked&&e.expandable?.up===t.expandable?.up&&e.expandable?.down===t.expandable?.down}function y_(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:bg(e),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,loadDiffFiles:e?.loadDiffFiles,collapsedContextThreshold:e?.collapsedContextThreshold,lineDiffType:e?.lineDiffType,maxLineDiffLength:e?.maxLineDiffLength,expansionLineCount:e?.expansionLineCount,headerRenderMode:e?.renderCustomHeader==null?`default`:`custom`}}function b_(e){return e.isPartial&&(e.type===`change`||e.type===`rename-changed`||e.type===`rename-pure`)}var x_=-1,S_=class{options;workerManager;isContainerManaged;static LoadedCustomComponent=!0;__id=`file-diff:${++x_}`;type=`file-diff`;fileContainer;spriteSVG;pre;codeUnified;codeDeletions;codeAdditions;bufferBefore;bufferAfter;themeCSSStyle;appliedThemeCSS;hasAdoptedThemeCSS=!1;unsafeCSSStyle;appliedUnsafeCSS;gutterUtilityContent;headerElement;headerPrefix;headerFilenameSuffix;headerMetadata;headerCustom;separatorCache=new Map;errorWrapper;placeHolder;hunksRenderer;resizeManager;scrollSyncManager;interactionManager;annotationCache=new Map;lineAnnotations=[];managersDirty=!1;deletionFile;additionFile;fileDiff;renderRange;pendingFiles;appliedPreAttributes;lastRenderedHeaderHTML;cachedHeaderHTML;lastRowCount;mounted=!1;enabled=!0;editor;refreshViewTimeout;lineStateRefreshPending=!1;deferredSelectedLines;deferredEditorActiveLine;constructor(e={theme:me},t,n=!1){this.options=e,this.workerManager=t,this.isContainerManaged=n,this.hunksRenderer=this.createHunksRenderer(e),this.resizeManager=new Ih,this.scrollSyncManager=new Gg,this.interactionManager=new gh(`diff`,_h(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 y_(e)}createHunksRenderer(e){return new e_(this.getHunksRendererOptions(e),this.handleHighlightRender,this.workerManager)}getLineIndex=(e,t=`additions`)=>{let n=this.fileDiffCache;if(n==null)return;let r=n.hunks.at(-1),i,a;hunkIterator:for(let o of n.hunks){let n=t===`deletions`?o.deletionStart:o.additionStart,s=t===`deletions`?o.deletionCount:o.additionCount,c=Ee(n,s)+1,l=o.splitLineStart,u=o.unifiedLineStart;if(e<c){let t=c-e;i=Math.max(u-t,0),a=Math.max(l-t,0);break hunkIterator}if(e>=c+s){if(o===r){let t=e-(c+s);i=u+o.unifiedLineCount+t,a=l+o.splitLineCount+t;break hunkIterator}continue}for(let n of o.hunkContent)if(n.type===`context`){if(e<c+n.lines){let t=e-c;a=l+t,i=u+t;break hunkIterator}c+=n.lines,l+=n.lines,u+=n.lines}else{let r=t===`deletions`?n.deletions:n.additions;if(e<c+r){let r=e-c;i=u+(t===`additions`?n.deletions:0)+r,a=l+r;break hunkIterator}c+=r,l+=Math.max(n.deletions,n.additions),u+=n.deletions+n.additions}break hunkIterator}if(i!=null&&a!=null)return[i,a]};setOptions(e){e!=null&&(this.options=e,this.cachedHeaderHTML=void 0,this.hunksRenderer.setOptions(this.getHunksRendererOptions(e)),this.syncInteractionOptions())}syncInteractionOptions(){this.interactionManager.setOptions(_h(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&&(this.applyThemeState(this.fileContainer,this.appliedThemeCSS.themeStyles,e,this.appliedThemeCSS.baseThemeType),!0)}hasThemeChanged(){return this.appliedThemeCSS!=null&&!Me(this.appliedThemeCSS.theme,this.options.theme??me)}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.lineStateRefreshPending?this.deferredSelectedLines=[e,t]:this.interactionManager.setSelection(e,t)}setEditorActiveLine(e,t){this.lineStateRefreshPending?this.deferredEditorActiveLine=[e,t]:this.interactionManager.setEditorActiveLine(e,{lineNumberOnly:t?.lineNumberOnly,side:t?.side??`additions`})}flushDeferredLineState(){let{deferredEditorActiveLine:e,deferredSelectedLines:t}=this;this.lineStateRefreshPending=!1,this.deferredEditorActiveLine=void 0,this.deferredSelectedLines=void 0,e!=null&&this.setEditorActiveLine(...e),t!=null&&this.interactionManager.setSelection(...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,{disableAnnotations:t===`wrap`,columnVariables:this.shouldApplyColumnVariables(t)?`apply`:`measure`}),t===`scroll`&&e===`split`?this.scrollSyncManager.setup(this.pre,this.codeDeletions,this.codeAdditions):this.scrollSyncManager.cleanUp(),this.managersDirty=!1}shouldApplyColumnVariables(e){return typeof this.options.hunkSeparators==`function`||e===`scroll`&&(this.lineAnnotations.length>0||this.pre?.hasAttribute(`data-has-merge-conflict`)===!0)}getCodeScrollLeft(){return Math.max(this.codeUnified?.scrollLeft??0,this.codeDeletions?.scrollLeft??0,this.codeAdditions?.scrollLeft??0)}setCodeScrollLeft(e){this.codeUnified!=null&&(this.codeUnified.scrollLeft=e),this.codeAdditions!=null&&(this.codeAdditions.scrollLeft=e),this.codeDeletions!=null&&(this.codeDeletions.scrollLeft=e)}__getEffectiveCodeOptions(){return{...this.options,...this.hunksRenderer.getEffectiveCodeOptions()}}cleanUp(e=!1){Cp(this.handleEditSessionRender),this.emitPostRender(!0),this.editor?.cleanUp(e),this.editor=void 0,this.resizeManager.cleanUp(),this.interactionManager.cleanUp(),this.scrollSyncManager.cleanUp(),this.managersDirty=!1,this.workerManager?.unsubscribeToThemeChanges(this),this.renderRange=void 0,this.pendingFiles=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?.remove(),this.bufferBefore=void 0,this.bufferAfter?.remove(),this.bufferAfter=void 0,this.appliedPreAttributes=void 0,this.headerElement=void 0,this.headerPrefix=void 0,this.headerFilenameSuffix=void 0,this.headerMetadata=void 0,this.headerCustom=void 0,this.placeHolder?.remove(),this.placeHolder=void 0,this.lastRenderedHeaderHTML=void 0,e||(this.cachedHeaderHTML=void 0),this.errorWrapper?.remove(),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.refreshViewTimeout!=null&&(clearTimeout(this.refreshViewTimeout),this.refreshViewTimeout=void 0),this.lineStateRefreshPending=!1,this.deferredEditorActiveLine=void 0,this.deferredSelectedLines=void 0,this.enabled=!1}virtualizedSetup(){this.enabled=!0,this.workerManager?.subscribeToThemeChanges(this)}hydrate({fileContainer:e,prerenderedHTML:t,preventEmit:n=!1,lineAnnotations:r,fileDiff:i,...a}){if(!this.enabled)throw Error(`FileDiff.hydrate: attempting to call hydrate after cleaned up`);if(this.fileContainer!=null)throw Error(`FileDiff.hydrate: hydrate can only be called before the instance has rendered or hydrated`);let o=Ng(a,`FileDiff.hydrate`),s=o?.oldFile,c=o?.newFile;this.hydrateElements(e,t),E_(this.pre,w_({fileDiff:i,oldFile:s,newFile:c}),this.options.collapsed)||D_(this.headerElement,T_({fileDiff:i,oldFile:s,newFile:c}),this.options.disableFileHeader)?this.render({...a,fileContainer:e,lineAnnotations:r,fileDiff:i,preventEmit:!0}):this.hydrationSetup({fileDiff:i,lineAnnotations:r,...o}),n||this.emitPostRender()}hydrateElements(e,t){this.fileContainer!==e&&this.emitPostRender(!0),Dg(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!==void 0&&n!==void 0?mm(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.loadFilesIfNecessary(),this.rerender()};loadFilesIfNecessary(){let{fileDiff:e,options:{loadDiffFiles:t}}=this;e==null||t==null||!b_(e)||this.pendingFiles?.fileDiff===e||(this.pendingFiles={fileDiff:e,promise:this.loadFilesForDiff(e,t)})}async loadFilesForDiff(e,t){try{let n=await t(e);if(!this.enabled||this.fileDiff!==e)return;await this.handleFilesLoaded(e,n)}catch(e){if(this.options.disableErrorHandling===!0)throw e;console.error(e)}finally{this.pendingFiles?.fileDiff===e&&(this.pendingFiles=void 0)}}async handleFilesLoaded(e,t){this.fileDiff!==e||!e.isPartial||(Ig(`merge`,e,t),this.setHydratedState(t),await kg(()=>this.primeHighlightCache(e)),!(!this.enabled||this.fileDiff!==e)&&this.rerender())}setHydratedState(e){this.deletionFile=e.oldFile,this.additionFile=e.newFile,this.workerManager?.cleanUpTasks(this.hunksRenderer),this.hunksRenderer.clearRenderCache()}render({fileDiff:e,deferManagers:t=!1,forceRender:n=!1,preventEmit:r=!1,lineAnnotations:i,fileContainer:a,containerWrapper:o,renderRange:s,...c}){let l=Ng(c,`FileDiff.render`),u=l?.oldFile,d=l?.newFile;if(!this.enabled)throw Error(`FileDiff.render: attempting to call render after cleaned up`);e!=null&&e.cacheKey===void 0&&(e.cacheKey=e.prevName==null?e.name:e.prevName+`:`+e.name),this.editor?.__postponeBgTokenizeToNextFrame();let{collapsed:f=!1,themeType:p=`system`,expandUnchanged:m=!1}=this.options,h=f?void 0:s,g=this.hasThemeChanged(),_=l!=null,v=_&&(!C_(u,this.deletionFile)||!C_(d,this.additionFile)),y=e!=null&&e!==this.fileDiff,b=i!=null&&(i.length>0||this.lineAnnotations.length>0)&&i!==this.lineAnnotations;if(!f&&Wh(h,this.renderRange)&&!n&&!b&&!g&&(e!=null&&e===this.fileDiff||e==null&&!v))return this.applyCachedThemeState(p);let x;e==null&&_&&(v||this.fileDiff==null)&&(x=mm(l.oldFile,l.newFile,this.options.parseDiffOptions));let{renderRange:S}=this;if(this.renderRange=h,_?(this.deletionFile=u,this.additionFile=d):e!=null&&(this.deletionFile=void 0,this.additionFile=void 0),e==null?x!=null&&(y=!0,this.fileDiff=x):this.fileDiff=e,y&&(this.cachedHeaderHTML=void 0),i!=null&&this.setLineAnnotations(i),this.fileDiff==null)return!1;this.fileDiff.editSessionDirty===!0&&this.shouldSelfHealEditSession()&&(Km(this.fileDiff,this.options.parseDiffOptions),this.hunksRenderer.refreshHighlightedResult()),m&&this.loadFilesIfNecessary(),this.hunksRenderer.setOptions(this.getHunksRendererOptions(this.options)),this.syncInteractionOptions(),this.hunksRenderer.setLineAnnotations(this.lineAnnotations);let{disableErrorHandling:C=!1,disableFileHeader:w=!1}=this.options;if(w&&(this.headerElement!=null&&(this.headerElement.remove(),this.headerElement=void 0,this.lastRenderedHeaderHTML=void 0),this.clearHeaderSlots()),a=this.getOrCreateFileContainer(a,o),this.applyCachedThemeState(p),f){this.removeRenderedCode(),this.clearAuxiliaryNodes();try{let e=this.hunksRenderer.renderDiff(this.fileDiff,Ce);e!=null&&this.applyThemeState(a,e.themeStyles,p,e.baseThemeType),e?.headerElement!=null&&this.applyHeaderToDOM(e.headerElement,a),this.renderSeparators([]),this.injectUnsafeCSS()}catch(e){if(C)throw e;console.error(e),e instanceof Error&&this.applyErrorToDOM(e,a)}return r||this.emitPostRender(),!0}try{let e=this.getOrCreatePreNode(a);if(!(this.canPartiallyRender(n,b,v||y||g)&&this.applyPartialRender({previousRenderRange:S,renderRange:h}))){let t=this.hunksRenderer.renderDiff(this.fileDiff,h);if(t==null)return this.workerManager?.isInitialized()===!1&&this.workerManager.initialize().then(()=>this.rerender()),!1;this.applyThemeState(a,t.themeStyles,p,t.baseThemeType),t.headerElement!=null&&this.applyHeaderToDOM(t.headerElement,a),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,h),this.injectUnsafeCSS(),this.renderAnnotations(),this.renderGutterUtility(),this.managersDirty=!0,t||this.flushManagers(),this.editor!=null&&this.syncRenderViewToEditor()}catch(e){if(C)throw e;console.error(e),e instanceof Error&&this.applyErrorToDOM(e,a)}return r||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)}get fileDiffCache(){return this.hunksRenderer.diffCache??this.fileDiff}syncRenderViewToEditor(){let e=this.editor,t=this.fileContainer,n=this.fileDiffCache,r=this.lineAnnotations,i=this.computeEditorRenderRange(this.renderRange);e!=null&&t!=null&&n!=null&&!n.isPartial&&this.hunksRenderer.initializeHighlighter().then(a=>{!this.enabled||this.editor!==e||this.fileContainer!==t||this.fileDiffCache!==n||e.__syncRenderView(a,t,n,r,i)})}computeEditorRenderRange(e){let t=this.fileDiffCache;if(e==null||t==null||Kg(e))return e;let{diffStyle:n=`split`,expandUnchanged:r=!1,collapsedContextThreshold:i=1}=this.options,a,o;return wf({diff:t,diffStyle:n,startingLine:e.startingLine,totalLines:e.totalLines,expandedHunks:r?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:i,callback:({additionLine:e})=>{e!=null&&(a??=e.lineNumber,o=e.lineNumber)}}),a==null||o==null?{...e,startingLine:0,totalLines:0}:{...e,startingLine:a-1,totalLines:o-a+1}}attachEditor(e){if(this.type!==`file-diff`)throw Error(`FileDiff.attachEditor: cannot attach an editor to a "${this.type}" diff`);return this.editor?.cleanUp(),this.editor=e,this.hunksRenderer.beginEditSession(),this.fileDiff?.isPartial===!0&&this.loadFilesIfNecessary(),this.hunksRenderer.editorRenderReady()?this.syncRenderViewToEditor():this.rerender(),e=>{this.editor=void 0,e!==!0&&this.finishEditSession()}}finishEditSession(){this.hunksRenderer.endEditSession(),this.completeEditSession()}completeEditSession(){let e=this.fileDiffCache;if(e==null||e.editSessionDirty!==!0)return!1;let{collapsedContextThreshold:t=1}=this.options,n=Wm(e,this.hunksRenderer.getExpandedHunksMap(),t);return Km(e,this.options.parseDiffOptions),this.hunksRenderer.setExpandedHunksMap(Gm(e,n)),this.hunksRenderer.refreshHighlightedResult(),this.escalateEditSessionRender(),!0}applyDocumentChange(e,t){this.hunksRenderer.applyDocumentChange(e);let n=this.hunksRenderer.diffCache;if(n!=null){let e=this.fileDiff?.cacheKey;e!=null&&n.cacheKey==null&&(n.cacheKey=e),this.fileDiff=n}t!==void 0&&t!==this.lineAnnotations&&(this.setLineAnnotations(t),this.hunksRenderer.setLineAnnotations(this.lineAnnotations),this.renderAnnotations()),this.rerender(),this.interactionManager.setSelectionDirty()}updateRenderCache(e,t,n={}){let{shouldRefreshDiffsView:r,lineCountChangeInFlight:i}=n;if(this.hunksRenderer.updateRenderCache(e,t,i)){this.refreshViewTimeout!=null&&(clearTimeout(this.refreshViewTimeout),this.refreshViewTimeout=void 0),this.lineStateRefreshPending=!0,this.escalateEditSessionRender();return}r===!0&&(this.refreshViewTimeout!=null&&clearTimeout(this.refreshViewTimeout),this.lineStateRefreshPending=!0,this.refreshViewTimeout=setTimeout(()=>{this.refreshViewTimeout=void 0,this.options.diffStyle===`split`?this.refreshSplitDiffView():this.refreshUnifiedDiffView(),this.flushDeferredLineState()},150))}isLineRenderable(e){let t=this.fileDiffCache;if(t==null)return!0;let{expandUnchanged:n=!1,collapsedContextThreshold:r=1}=this.options;return gf({fileDiff:t,lineNumber:e,expandedHunks:n?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:r})}getNearestRenderableLine(e,t){let n=this.fileDiffCache;if(n==null)return e;let{expandUnchanged:r=!1,collapsedContextThreshold:i=1}=this.options;return _f({fileDiff:n,lineNumber:e,direction:t,expandedHunks:r?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:i})}revealLine(e){let t=this.fileDiffCache,{expandUnchanged:n=!1,collapsedContextThreshold:r=1,expansionLineCount:i=100}=this.options;if(t==null||t.isPartial||n)return!1;let a=this.hunksRenderer.getExpandedHunksMap();for(let[n,o]of t.hunks.entries()){let[s,c]=df(o);if(e<s){let c=ff({isPartial:t.isPartial,rangeSize:o.collapsedBefore,expandedHunks:a,hunkIndex:n,collapsedContextThreshold:r}),l=s-c.rangeSize;if(c.renderAll||e<l+c.fromStart||e>=s-c.fromEnd)return!1;let u=e-(l+c.fromStart)+1,d=s-c.fromEnd-e;return u<=d?this.expandHunk(n,`up`,u+i):this.expandHunk(n,`down`,d+i),!0}if(e<c)return!1}let o=hf({fileDiff:t,hunkIndex:t.hunks.length-1,expandedHunks:a,collapsedContextThreshold:r,errorPrefix:`FileDiff.revealLine`});if(o==null||o.renderAll)return!1;let s=t.hunks[t.hunks.length-1],[,c]=df(s);return e<c+o.fromStart||e>=c+o.rangeSize?!1:(this.expandHunk(t.hunks.length,`up`,e-(c+o.fromStart)+1+i),!0)}shouldSelfHealEditSession(){return this.editor==null}escalateEditSessionRender(){Sp(this.handleEditSessionRender)}handleEditSessionRender=()=>{this.rerender(),this.flushDeferredLineState()};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}async primeHighlightCache(e=this.fileDiff){let{workerManager:t}=this;if(e==null||t==null||!t.isWorkingPool()||e.cacheKey==null||rf(e))return;let n=this.options.tokenizeMaxLength??1e5;Math.max(e.additionLines.length,e.deletionLines.length)>n||await t.primeDiffHighlightCache(e).catch(e=>{console.error(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.headerFilenameSuffix?.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.headerFilenameSuffix=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||!v_(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}-${we(r)}`,a=this.annotationCache.get(i);if(a==null||!__(r,a.annotation)){a?.element.remove();let e=t(r);if(e==null)continue;a={element:sg(we(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=cg();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 n!=null&&i&&this.editor?.__captureFocusForDOMReplacement(),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:ch(e)&&e.hasAttribute(`data-theme-css`)?(this.themeCSSStyle??=e,this.hasAdoptedThemeCSS=!0):ch(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=rg;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&&(this.editor?.__captureFocusForDOMReplacement(),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??R(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,renderHeaderFilenameSuffix:o,renderHeaderMetadata:s}=this.options;if(i!=null){let e=i(n)??void 0;this.headerCustom=this.upsertHeaderSlotElement(t,this.headerCustom,pe,e),this.headerPrefix?.remove(),this.headerFilenameSuffix?.remove(),this.headerMetadata?.remove(),this.headerPrefix=void 0,this.headerFilenameSuffix=void 0,this.headerMetadata=void 0;return}let c=a?.(n)??void 0,l=o?.(n)??void 0,u=s?.(n)??void 0;this.headerPrefix=this.upsertHeaderSlotElement(t,this.headerPrefix,de,c),this.headerFilenameSuffix=this.upsertHeaderSlotElement(t,this.headerFilenameSuffix,j,l),this.headerMetadata=this.upsertHeaderSlotElement(t,this.headerMetadata,fe,u),this.headerCustom?.remove(),this.headerCustom=void 0}clearHeaderSlots(){this.headerPrefix?.remove(),this.headerFilenameSuffix?.remove(),this.headerMetadata?.remove(),this.headerCustom?.remove(),this.headerPrefix=void 0,this.headerFilenameSuffix=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??=lg(),this.unsafeCSSStyle.parentNode!==t&&t.appendChild(this.unsafeCSSStyle),this.unsafeCSSStyle.textContent=gg(e),this.appliedUnsafeCSS=e)}}applyThemeState(e,t,n,r){let i=e.shadowRoot??e.attachShadow({mode:`open`}),a=r??n,o=this.options.theme??me,s=typeof o==`string`?o:{...o},c=dg(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=Cg({shadowRoot:i,currentNode:this.themeCSSStyle,themeCSS:_g(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=vg(this.themeCSSStyle.textContent??``,dg(e)))}shouldGuardRebuildScroll(){return this.editor!=null&&Eg()}applyHunksToDOM(e,t){this.shouldGuardRebuildScroll()?Sg(e,()=>this.replaceCodeColumns(e,t)):this.replaceCodeColumns(e,t)}applyCodeColumnsInPlace(e,t,n){let r=this.getColumnPair(e);if(r==null)return!1;let i=O_(t[0]),a=O_(t[1]);return i==null||a==null?!1:(r.gutter.innerHTML=R(i),r.content.innerHTML=R(a),n!==this.lastRowCount&&(r.gutter.style.setProperty(`grid-row`,`span ${n}`),r.content.style.setProperty(`grid-row`,`span ${n}`)),!0)}replaceCodeColumns(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);this.editor?.__captureFocusForDOMReplacement(),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=xg({code:this.codeDeletions,columnType:`deletions`,rowSpan:i,containerSize:r}),this.applyCodeColumnsInPlace(this.codeDeletions,c,t.rowCount)||(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=xg({code:this.codeAdditions,columnType:`additions`,rowSpan:i,containerSize:r}),this.applyCodeColumnsInPlace(this.codeAdditions,l,t.rowCount)||(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=xg({code:this.codeUnified,columnType:`unified`,rowSpan:i,containerSize:r}),this.applyCodeColumnsInPlace(this.codeUnified,s,t.rowCount)||(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(`FileDiff.applyPartialRender: failed to trim to overlap`);if(this.lastRowCount<g)throw Error(`FileDiff.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`)}refreshSplitDiffView(){if(this.options.diffStyle!==`split`)return;let e=this.hunksRenderer.renderDiff(this.fileDiff,this.renderRange);if(e==null)return;let t=this.getCodeColumns(`split`,this.codeUnified,this.codeDeletions,this.codeAdditions);if(!Array.isArray(t))return;let n=(t,n)=>{if(n==null)return;let r=this.hunksRenderer.renderCodeAST(t,e),i=O_(r?.[0]),a=O_(r?.[1]);for(let[e,t]of[[n.gutter,i],[n.content,a]])if(t!=null&&e.childElementCount===t.length)for(let n=0;n<t.length;n++){let r=e.children[n],i=t[n].properties[`data-line-type`];i!=null&&r.dataset.lineType!==i&&(r.dataset.lineType=i)}};n(`deletions`,t[0]),n(`additions`,t[1])}refreshUnifiedDiffView(){if(this.options.diffStyle!==`unified`)return;let e=this.hunksRenderer.renderDiff(this.fileDiff,this.renderRange);if(e==null)return;let t=this.getCodeColumns(`unified`,this.codeUnified,this.codeDeletions,this.codeAdditions);if(t==null||Array.isArray(t))return;let n=this.hunksRenderer.renderCodeAST(`unified`,e),r=O_(n?.[0]),i=O_(n?.[1]),a=()=>{for(let[e,n]of[[t.gutter,r],[t.content,i]])n!=null&&(e.innerHTML=R(n));e.rowCount!==this.lastRowCount&&(this.applyRowSpan(`unified`,t,e.rowCount),this.lastRowCount=e.rowCount)};this.shouldGuardRebuildScroll()?Sg(this.pre,a):a(),this.renderSeparators(e.hunkData),this.managersDirty=!0,this.flushManagers(),this.syncRenderViewToEditor()}renderPartialColumn(e,t,n){if(e==null||t==null)return;let r=O_(t[0]),i=O_(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}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)`)}getColumnPair(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}}getCodeColumns(e,t,n,r){if(e===`unified`)return this.getColumnPair(t);{let e=this.getColumnPair(n),t=this.getColumnPair(r);return e!=null||t!=null?[e,t]:void 0}}updateBuffers(e){this.pre!=null&&this.applyBuffers(this.pre,e)}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`&&t!=null&&n!=null,totalLines:r,customProperties:i};ig(u,this.appliedPreAttributes)||(Og(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 C_(e,t){return e==null||t==null?e==null&&t==null:Ne(e,t)}function w_({fileDiff:e,oldFile:t,newFile:n}){return e!=null&&e.hunks.length>0||t!=null||n!=null}function T_({fileDiff:e,oldFile:t,newFile:n}){return e!=null||t!=null||n!=null}function E_(e,t,n=!1){return!n&&e==null&&t}function D_(e,t,n=!1){return e==null&&t&&!n}function O_(e){if(e!=null&&e.type===`element`)return e.children??[]}var k_=3e3,A_=-1,j_=class extends S_{__id=`little-virtualized-file-diff:${++A_}`;top;height=0;metrics;cache={heightDeltas:new Map,measuredHeightDeltaTotal:0,estimatedSplitHeight:void 0,estimatedUnifiedHeight:void 0,checkpoints:[],totalLines:0,fileAnnotationHeight:0};isVisible=!1;isSetup=!1;virtualizer;layoutDirty=!0;forceRenderOverride;currentCollapsed;currentExpandUnchanged;pendingHydratedDiff;pendingExpansions;constructor(e,t,n,r,i=!1){super(e,r,i),this.virtualizer=t,this.metrics=of(n)}setMetrics(e,t=!1){let n=of(e);!t&&_p(this.metrics,n)||(this.metrics=n,this.resetLayoutCache({includeEstimatedHeights:!0}))}setLineAnnotations(e){this.syncLineAnnotations(e)&&this.resetLayoutCache({includeEstimatedHeights:!1})}syncLineAnnotations(e){return e==null||e===this.lineAnnotations||e.length===0&&this.lineAnnotations.length===0?!1:(super.setLineAnnotations(e),!0)}setFileAnnotationHeight(e){let t=this.cache.fileAnnotationHeight;return e!==t&&(this.cache.fileAnnotationHeight=e,this.cache.measuredHeightDeltaTotal+=e-t,!0)}hasFileAnnotations(e=this.fileDiff){return e==null||!uh(this.lineAnnotations)?!1:this.lineAnnotations.some(t=>t.lineNumber===0?e.type===`new`?t.side===`additions`:e.type!==`deleted`||t.side===`deletions`:!1)}getLineHeight(e,t=!1){return this.getEstimatedLineHeight(t)+(this.cache.heightDeltas.get(e)??0)}getEstimatedLineHeight(e=!1){let t=e?2:1;return this.metrics.lineHeight*t}setOptions(e){if(this.isAdvancedMode())throw Error(`VirtualizedFileDiff.setOptions cannot be used inside CodeView. Update CodeView options instead.`);if(e==null)return;let{options:t}=this,n=!vp(t,e),r=n&&z_(t,e);super.setOptions(e),r&&this.resetLayoutCache({forceSimpleRecompute:!0,includeEstimatedHeights:B_(t,e)}),n&&(this.forceRenderOverride=!0),n&&this.isSimpleMode()&&this.virtualizer.instanceChanged(this,r)}setThemeType(e){if(this.isAdvancedMode())throw Error(`VirtualizedFileDiff.setThemeType cannot be used inside CodeView. Update CodeView options instead.`);super.setThemeType(e)}resetLayoutCache({forceSimpleRecompute:e=!1,includeEstimatedHeights:t=!1,resetRenderRange:n=!0}={}){this.layoutDirty=!0,this.cache.fileAnnotationHeight=0,this.cache.heightDeltas.size>0&&this.cache.heightDeltas.clear(),this.cache.measuredHeightDeltaTotal!==0&&(this.cache.measuredHeightDeltaTotal=0),this.invalidateDerivedLayoutCache(t,n),e&&this.isSimpleMode()&&this.computeApproximateSize()}invalidateDerivedLayoutCache(e,t=!0){this.layoutDirty=!0,this.cache.checkpoints.length>0&&(this.cache.checkpoints.length=0),this.cache.totalLines!==0&&(this.cache.totalLines=0),e&&(this.cache.estimatedSplitHeight=void 0,this.cache.estimatedUnifiedHeight=void 0),this.renderRange!=null&&t&&(this.renderRange=void 0)}reconcileHeights(){let e=!1,{overflow:t=`scroll`}=this.options;if(this.fileContainer==null||this.fileDiff==null)return this.height!==0&&(e=!0),this.height=0,e;if(this.top=this.getVirtualizedTop(),t===`scroll`&&this.lineAnnotations.length===0&&!this.isResizeDebuggingEnabled())return e;let n=this.getDiffStyle(),r=n===`split`?[this.codeDeletions,this.codeAdditions]:[this.codeUnified],i=this.hasFileAnnotations(this.fileDiff);if(this.renderRange!=null&&i&&fh(this.renderRange)){let t=M_(r)??0;this.setFileAnnotationHeight(t)&&(e=!0)}else!i&&this.setFileAnnotationHeight(0)&&(e=!0);for(let t of r){if(t==null)continue;let r=t.children[1];if(r instanceof HTMLElement)for(let t of r.children){if(!(t instanceof HTMLElement))continue;let r=t.dataset.lineIndex;if(r==null)continue;let i=W_(r,n),a=t.getBoundingClientRect().height,o=!1;t.nextElementSibling instanceof HTMLElement&&(`lineAnnotation`in t.nextElementSibling.dataset||`noNewline`in t.nextElementSibling.dataset)&&(`noNewline`in t.nextElementSibling.dataset&&(o=!0),a+=t.nextElementSibling.getBoundingClientRect().height);let s=this.getEstimatedLineHeight(o),c=this.cache.heightDeltas.get(i)??0,l=a-s;l!==c&&(e=!0,this.cache.measuredHeightDeltaTotal+=l-c,l===0?this.cache.heightDeltas.delete(i):this.cache.heightDeltas.set(i,l))}}return(e||this.isResizeDebuggingEnabled())&&this.computeApproximateSize(!0),e}onRender=e=>this.fileContainer!=null&&(e&&(this.top=this.getVirtualizedTop()),this.render());flushManagers(){super.flushManagers(),this.lineStateRefreshPending&&this.flushDeferredLineState()}prepareCodeViewItem(e,t,n,r){let i=!tf(this.fileDiff,e),a=this.syncLineAnnotations(r),o=n?.resetDiffLayoutCache===!0||i||a,s=i||n?.resetDiffLayoutCache===!0&&n.includeEstimatedDiffHeights;n?.metrics!=null&&(this.metrics=of(n.metrics),o=!0,s=!0);let{collapsed:c=!1,expandUnchanged:l=!1}=this.options;return this.currentCollapsed!==c&&(this.currentCollapsed=c,o=!0),this.currentExpandUnchanged!==l&&(this.currentExpandUnchanged=l,o=!0,s=!0),o&&this.resetLayoutCache({includeEstimatedHeights:s}),this.fileDiff=e,this.top=t,this.computeApproximateSize(),this.height}getLinePosition(e,t=`additions`){if(this.fileDiff==null||e<1)return;let n=this.getLineIndex(e,t);if(n==null)return;let{disableFileHeader:r=!1,expandUnchanged:i=!1,collapsed:a=!1,collapsedContextThreshold:o=1}=this.options,s=this.getDiffStyle(),c=this.getHunkSeparatorType(),l=s===`split`?n[1]:n[0];this.approximateLayoutCheckpoints();let u=sf(this.metrics,r),d=this.getLayoutCheckpointBeforeLineIndex(l),f=d?.top??u+this.cache.fileAnnotationHeight;if(a)return{top:u,height:0};let p;return wf({diff:this.fileDiff,diffStyle:s,startingLine:d?.renderedLineIndex??0,expandedHunks:i?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:o,callback:({hunkIndex:e,hunk:t,collapsedBefore:n,collapsedAfter:r,deletionLine:i,additionLine:a})=>{let o=s===`split`?a?.splitLineIndex??i?.splitLineIndex:a?.unifiedLineIndex??i?.unifiedLineIndex;if(o==null)throw Error(`VirtualizedFileDiff.getLinePosition: missing line index data`);if(n>0){let r=Sf({type:c,metrics:this.metrics,hunkIndex:e,hunkSpecs:t?.hunkSpecs});if(r!=null){if(f+=r.gapBefore,l>=o-n&&l<o)return p={top:f,height:r.height},!0;f+=r.height+r.gapAfter}}let u=this.getLineHeight(o,(a?.noEOFCR??!1)||(i?.noEOFCR??!1));if(o===l)return p={top:f,height:u},!0;if(f+=u,r>0){let e=Cf({type:c,metrics:this.metrics});if(e!=null){if(l>o&&l<=o+r)return p={top:f+e.gapBefore,height:e.height},!0;f+=e.totalHeight}}return!1}}),p}getEditorViewport(){return this.virtualizer.type===`simple`?this.virtualizer.getRoot():this.virtualizer.getContainerElement()}getNumericScrollAnchor(e){if(this.fileDiff==null)return;let{disableFileHeader:t=!1,expandUnchanged:n=!1,collapsed:r=!1,collapsedContextThreshold:i=1}=this.options;if(r)return;let a=this.getDiffStyle(),o=this.getHunkSeparatorType();this.approximateLayoutCheckpoints();let s=this.getLayoutCheckpointBeforeTop(e),c=s?.top??sf(this.metrics,t)+this.cache.fileAnnotationHeight,l;return wf({diff:this.fileDiff,diffStyle:a,startingLine:s?.renderedLineIndex??0,expandedHunks:n?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:i,callback:({hunkIndex:t,hunk:n,collapsedBefore:r,collapsedAfter:i,deletionLine:s,additionLine:u})=>{let d=a===`split`?u?.splitLineIndex??s?.splitLineIndex:u?.unifiedLineIndex??s?.unifiedLineIndex;if(d==null)throw Error(`VirtualizedFileDiff.getNumericScrollAnchor: missing line index data`);if(r>0){let e=Sf({type:o,metrics:this.metrics,hunkIndex:t,hunkSpecs:n?.hunkSpecs});e!=null&&(c+=e.totalHeight)}if(c>=e&&(s==null?u!=null&&(l={lineNumber:u.lineNumber,side:`additions`,top:c}):l={lineNumber:s.lineNumber,side:`deletions`,top:c},l!=null))return!0;let f=this.getLineHeight(d,(u?.noEOFCR??!1)||(s?.noEOFCR??!1));if(c+=f,i>0){let e=Cf({type:o,metrics:this.metrics});e!=null&&(c+=e.totalHeight)}return!1}}),l}getVirtualizedHeight(){return this.height}getAdvancedStickySpecs(e){if(this.top==null||this.fileDiff==null)return;if(this.options.collapsed===!0)return{topOffset:this.top,height:this.height};let t=e==null?this.renderRange:this.computeRenderRangeFromWindow(this.fileDiff,this.top,e);if(t==null)return;let{bufferBefore:n,bufferAfter:r,totalLines:i}=t,a=0;if(i===0){let t=e??this.virtualizer.getWindowSpecs();this.top<t.top&&(a=r)}return{topOffset:this.top+n+a,height:this.height-(n+r)}}cleanUp(e=!1){this.fileContainer!=null&&this.isSimpleMode()&&this.getSimpleVirtualizer()?.disconnect(this.fileContainer),e||(this.resetLayoutCache({includeEstimatedHeights:!0}),this.pendingExpansions=void 0,this.pendingHydratedDiff=void 0),this.isSetup=!1,super.cleanUp(e)}expandHunk=(e,t,n)=>{this.fileDiff!=null&&(this.isAdvancedMode()?(this.pendingExpansions??=[],this.pendingExpansions.push({hunkIndex:e,direction:t,expansionLineCountOverride:n})):(this.hunksRenderer.expandHunk(e,t,n),this.resetLayoutCache({includeEstimatedHeights:!0}),this.computeApproximateSize()),this.loadFilesIfNecessary(),this.forceRenderOverride=!0,this.virtualizer.instanceChanged(this,!0))};async handleFilesLoaded(e,t){if(!(this.fileDiff!==e||!e.isPartial)){if(this.isAdvancedMode()){let n=Ig(`clone`,e,t);if(await kg(()=>this.primeHighlightCache(n)),!this.enabled||this.fileDiff!==e)return;this.pendingHydratedDiff={expectedDiff:e,nextDiff:n,files:t}}else{if(Ig(`merge`,e,t),this.setHydratedState(t),await kg(()=>this.primeHighlightCache(e)),!this.enabled||this.fileDiff!==e)return;this.resetLayoutCache({includeEstimatedHeights:!0}),this.computeApproximateSize()}this.forceRenderOverride=!0,this.virtualizer.instanceChanged(this,!0)}}consumeCodeViewLayoutChanges(e){let t=!1,n,{pendingExpansions:r,pendingHydratedDiff:i}=this;if(r!=null){this.pendingExpansions=void 0;for(let e of r)this.hunksRenderer.expandHunk(e.hunkIndex,e.direction,e.expansionLineCountOverride),t=!0}return i!=null&&(this.pendingHydratedDiff=void 0,i.expectedDiff===e&&(this.setHydratedState(i.files),n=i.nextDiff)),n==null?t&&(this.forceRenderOverride=!0,this.invalidateDerivedLayoutCache(!0)):(this.forceRenderOverride=!0,this.resetLayoutCache({includeEstimatedHeights:!0})),n}loadFilesIfNecessary(){if(this.pendingHydratedDiff!=null){if(this.pendingHydratedDiff.expectedDiff===this.fileDiff)return;this.pendingHydratedDiff=void 0}super.loadFilesIfNecessary()}isLineRenderable(e){if(super.isLineRenderable(e))return!0;let{pendingExpansions:t}=this,n=this.fileDiffCache;if(t==null||t.length===0||n==null)return!1;let{expansionLineCount:r=100,collapsedContextThreshold:i=1}=this.options,a=new Map(this.hunksRenderer.getExpandedHunksMap());for(let e of t){let t={...a.get(e.hunkIndex)??{fromStart:0,fromEnd:0}},n=e.expansionLineCountOverride??r;(e.direction===`up`||e.direction===`both`)&&(t.fromStart+=n),(e.direction===`down`||e.direction===`both`)&&(t.fromEnd+=n),a.set(e.hunkIndex,t)}return gf({fileDiff:n,lineNumber:e,expandedHunks:a,collapsedContextThreshold:i})}invalidateEditSessionLayout(){this.getSimpleVirtualizer()?.markDOMDirty(),this.resetLayoutCache({forceSimpleRecompute:this.isSimpleMode(),includeEstimatedHeights:!0,resetRenderRange:!1}),this.isSimpleMode()||this.computeApproximateSize(!0),this.getSimpleVirtualizer()?.requestHeightReconcile(this)}escalateEditSessionRender(){this.invalidateEditSessionLayout(),!(!this.enabled||this.fileDiff==null)&&(this.forceRenderOverride=!0,this.virtualizer.instanceChanged(this,!0))}shouldSelfHealEditSession(){return!this.isAdvancedMode()&&super.shouldSelfHealEditSession()}setVisibility(e){this.isAdvancedMode()||this.fileContainer==null||(this.renderRange=void 0,e&&!this.isVisible?(this.top=this.getVirtualizedTop(),this.isVisible=!0):!e&&this.isVisible&&(this.isVisible=!1,this.rerender()))}rerender(){!this.enabled||this.fileDiff==null&&this.additionFile==null&&this.deletionFile==null||(this.forceRenderOverride=!0,this.virtualizer.instanceChanged(this,!1))}applyDocumentChange(e,t,n=!1){let{renderRange:r}=this;if(this.getAdvancedVirtualizer()?.capturePendingLayoutAnchor(),super.applyDocumentChange(e,t),this.getSimpleVirtualizer()?.markDOMDirty(),this.resetLayoutCache({forceSimpleRecompute:this.isSimpleMode(),includeEstimatedHeights:!0,resetRenderRange:!1}),!this.isSimpleMode())this.computeApproximateSize(!0);else if(n&&r!==void 0&&this.fileDiff!==void 0){let e=this.virtualizer.getWindowSpecs(),t=this.computeRenderRangeFromWindow(this.fileDiff,this.top??0,e);t.bufferAfter!==r.bufferAfter&&this.updateBuffers(t)}this.forceRenderOverride=!0,this.virtualizer.instanceChanged(this,!0)}computeApproximateSize(e=!1,t=this.fileDiff){let n=this.isResizeDebuggingEnabled();if(!e&&!this.layoutDirty&&!n)return;let r=this.height===0;if(this.height=0,this.cache.checkpoints=[],this.cache.totalLines=0,t==null){this.layoutDirty=!1;return}let{disableFileHeader:i=!1,collapsed:a=!1}=this.options,o=sf(this.metrics,i);if(this.height+=o,a){this.layoutDirty=!1;return}this.height=this.getActiveEstimatedHeight(t)+this.cache.measuredHeightDeltaTotal,n&&!r&&this.validateComputedHeight(t),this.layoutDirty=!1}getActiveEstimatedHeight(e=this.fileDiff){this.ensureEstimatedDiffHeights(e);let t=this.getDiffStyle()===`split`?this.cache.estimatedSplitHeight:this.cache.estimatedUnifiedHeight;if(t==null)throw Error(`VirtualizedFileDiff.getActiveEstimatedHeight: missing estimated height`);return t}ensureEstimatedDiffHeights(e=this.fileDiff){if(e==null){this.cache.estimatedSplitHeight=void 0,this.cache.estimatedUnifiedHeight=void 0;return}if(this.cache.estimatedSplitHeight!=null&&this.cache.estimatedUnifiedHeight!=null)return;let{disableFileHeader:t=!1,expandUnchanged:n=!1,collapsedContextThreshold:r=1}=this.options,{splitHeight:i,unifiedHeight:a}=Ag({fileDiff:e,metrics:this.metrics,disableFileHeader:t,hunkSeparators:this.getHunkSeparatorType(),expandUnchanged:n,expandedHunks:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:r,canHydratePartialDiff:V_(e,this.options.loadDiffFiles!=null)});this.cache.estimatedSplitHeight=i,this.cache.estimatedUnifiedHeight=a}validateComputedHeight(e=this.fileDiff){if(this.fileContainer==null||e==null)return;let t=this.fileContainer.getBoundingClientRect();t.height===this.height?console.log(`VirtualizedFileDiff.computeApproximateSize: computed height IS CORRECT`):console.log(`VirtualizedFileDiff.computeApproximateSize: computed height doesnt match`,{name:e.name,elementHeight:t.height,computedHeight:this.height})}render({fileContainer:e,fileDiff:t,forceRender:n=!1,lineAnnotations:r,...i}={}){let a=Ng(i,`VirtualizedFileDiff.render`),o=a!=null,s=a?.oldFile,c=a?.newFile,l=o&&(!U_(s,this.deletionFile)||!U_(c,this.additionFile)),u=t??this.fileDiff;t==null&&o&&(l||this.fileDiff==null)&&(u=mm(a.oldFile,a.newFile,this.options.parseDiffOptions));let{forceRenderOverride:d,isSetup:f}=this;this.forceRenderOverride=void 0;let p=this.syncLineAnnotations(r);p&&this.resetLayoutCache({includeEstimatedHeights:!1});let m=t!=null&&t!==this.fileDiff,h=u!=null&&!tf(this.fileDiff,u),g=m||l;if(h&&this.resetLayoutCache({includeEstimatedHeights:!0}),e=this.getOrCreateFileContainer(e),u==null)return console.error(`VirtualizedFileDiff.render: attempting to virtually render when we dont have the correct data`),!1;if(f)this.top??=this.getVirtualizedTop(),h&&(this.getSimpleVirtualizer()?.markDOMDirty(),this.computeApproximateSize(!1,u));else{this.computeApproximateSize(!1,u);let t=this.getSimpleVirtualizer();if(this.top??=this.getVirtualizedTop(),this.isAdvancedMode())this.isVisible=!0;else{if(t==null)throw Error(`VirtualizedFileDiff.render: simple virtualizer is not available`);t.connect(e,this),this.isVisible=t.isInstanceVisible(this.top??0,this.height)}this.isSetup=!0}if(!this.isVisible&&this.isSimpleMode()&&(!g||!f))return this.fileDiff=u,a!=null&&(this.deletionFile=s,this.additionFile=c),h&&(this.cachedHeaderHTML=void 0),this.renderPlaceholder(this.height);let _=this.virtualizer.getWindowSpecs(),v=this.top??0,y=this.computeRenderRangeFromWindow(u,v,_),b=super.render({fileDiff:u,fileContainer:e,renderRange:y,lineAnnotations:r,forceRender:(d??n)||p||h,...a,...i});return this.isSimpleMode()&&b&&this.getSimpleVirtualizer()?.requestHeightReconcile(this),b}syncVirtualizedTop(){this.top=this.getVirtualizedTop()}shouldDisableVirtualizationBuffers(){return this.isAdvancedMode()||super.shouldDisableVirtualizationBuffers()}shouldGuardRebuildScroll(){return!1}isSimpleMode(){return this.virtualizer.type===`simple`}isAdvancedMode(){return this.virtualizer.type===`advanced`}getVirtualizedTop(){return this.virtualizer.type===`advanced`?this.virtualizer.getLocalTopForInstance(this):this.fileContainer==null?0:this.virtualizer.getOffsetInScrollContainer(this.fileContainer)}getSimpleVirtualizer(){return this.virtualizer.type===`simple`?this.virtualizer:void 0}getAdvancedVirtualizer(){return this.virtualizer.type===`advanced`?this.virtualizer:void 0}isResizeDebuggingEnabled(){return this.getSimpleVirtualizer()?.config.resizeDebugging??!1}getDiffStyle(){return this.options.diffStyle??`split`}getHunkSeparatorType(){return H_(this.options.hunkSeparators)}approximateLayoutCheckpoints(e=this.fileDiff){if(!this.layoutDirty&&this.cache.checkpoints.length>0||e==null||e.hunks.length===0||this.options.collapsed===!0)return;let{disableFileHeader:t=!1,expandUnchanged:n=!1,collapsedContextThreshold:r=1}=this.options,i=e.hunks.length-1,a=V_(e,this.options.loadDiffFiles!=null),o=this.getDiffStyle(),s=this.getHunkSeparatorType(),c=n?!0:this.hunksRenderer.getExpandedHunksMap(),l=N_(this.cache.heightDeltas),u=sf(this.metrics,t)+this.cache.fileAnnotationHeight,d=0,f=({rowCount:e,startLineIndex:t,preSeparatorHeight:n=0,postSeparatorHeight:r=0,metadataOffsets:i=[]})=>{if(e<=0)return;let a=d,o=d+e,s=I_(a);for(;s<o;){let e=s-a,r=u+(e>0?n:0)+e*this.metrics.lineHeight+L_(i,e)*this.metrics.lineHeight+P_(l,t,t+e);this.cache.checkpoints.push({renderedLineIndex:s,lineIndex:t+e,top:r}),s+=k_}u+=n+e*this.metrics.lineHeight+i.length*this.metrics.lineHeight+P_(l,t,t+e)+r,d=o};for(let t=0;t<e.hunks.length;t++){let n=e.hunks[t];if(n==null)throw Error(`VirtualizedFileDiff.approximateLayoutCheckpoints: invalid hunk index`);let l=ff({isPartial:e.isPartial,rangeSize:n.collapsedBefore,expandedHunks:c,hunkIndex:t,collapsedContextThreshold:r}),u=l.collapsedLines>0?Sf({type:s,metrics:this.metrics,hunkIndex:t,hunkSpecs:n.hunkSpecs})?.totalHeight??0:0;f({rowCount:l.fromStart,startLineIndex:(o===`split`?n.splitLineStart:n.unifiedLineStart)-l.rangeSize});let d=u;f({rowCount:l.fromEnd,startLineIndex:(o===`split`?n.splitLineStart:n.unifiedLineStart)-l.fromEnd,preSeparatorHeight:d}),l.fromEnd>0&&(d=0);let p=t===i?hf({fileDiff:e,hunkIndex:t,expandedHunks:c,collapsedContextThreshold:r,errorPrefix:`VirtualizedFileDiff`}):void 0,m=p!=null&&p.collapsedLines>0||t===i&&a?Cf({type:s,metrics:this.metrics})?.totalHeight??0:0,h=p==null?0:p.fromStart+p.fromEnd,g=o===`split`?n.splitLineCount:n.unifiedLineCount,_=o===`split`?n.splitLineStart:n.unifiedLineStart;f({rowCount:g,startLineIndex:_,preSeparatorHeight:d,postSeparatorHeight:h===0?m:0,metadataOffsets:R_({diffStyle:o,hunk:n,rowCount:g})}),p!=null&&h>0&&f({rowCount:h,startLineIndex:_+g,postSeparatorHeight:m})}this.cache.totalLines=d}getLayoutCheckpointBeforeLineIndex(e){if(e<=0||this.cache.checkpoints.length===0)return;let t=0,n=this.cache.checkpoints.length-1,r;for(;t<=n;){let i=t+n>>1,a=this.cache.checkpoints[i];if(a==null)throw Error(`VirtualizedFileDiff: invalid checkpoint index`);a.lineIndex<=e?(r=a,t=i+1):n=i-1}return r}getLayoutCheckpointBeforeTop(e,t){let n=0,r=this.cache.checkpoints.length-1,i=-1;for(;n<=r;){let t=n+r>>1,a=this.cache.checkpoints[t];if(a==null)throw Error(`VirtualizedFileDiff: invalid checkpoint index`);a.top<=e?(i=t,n=t+1):r=t-1}if(t==null)return i>=0?this.cache.checkpoints[i]:void 0;for(let e=i;e>=0;e--){let n=this.cache.checkpoints[e];if(n==null)throw Error(`VirtualizedFileDiff: invalid checkpoint index`);if(n.renderedLineIndex%t===0)return n}}getExpandedLineCount(e,t){let n=0;if(e.isPartial){for(let r of e.hunks)n+=t===`split`?r.splitLineCount:r.unifiedLineCount;return n}let{expandUnchanged:r=!1,collapsedContextThreshold:i=1}=this.options,a=r?!0:this.hunksRenderer.getExpandedHunksMap();for(let[r,o]of e.hunks.entries()){let s=t===`split`?o.splitLineCount:o.unifiedLineCount;n+=s;let c=Math.max(o.collapsedBefore,0),{fromStart:l,fromEnd:u,renderAll:d}=ff({isPartial:e.isPartial,rangeSize:c,expandedHunks:a,hunkIndex:r,collapsedContextThreshold:i});c>0&&(n+=d?c:l+u)}let o=hf({fileDiff:e,hunkIndex:e.hunks.length-1,expandedHunks:a,collapsedContextThreshold:i,errorPrefix:`VirtualizedFileDiff`});return o!=null&&(n+=o.fromStart+o.fromEnd),n}getLayoutLineCount(e,t){let n=this.getExpandedLineCount(e,t),r=t===`split`?e.splitLineCount:e.unifiedLineCount;return Math.max(n,r,e.additionLines.length,e.deletionLines.length,this.cache.totalLines)}computeRenderRangeFromWindow(e,t,{top:n,bottom:r}){let{disableFileHeader:i=!1,expandUnchanged:a=!1,collapsedContextThreshold:o=1}=this.options,{hunkLineCount:s,lineHeight:c}=this.metrics,l=this.getDiffStyle(),u=this.getHunkSeparatorType(),d=V_(e,this.options.loadDiffFiles!=null),f=this.height,p=this.getLayoutLineCount(e,l),m=sf(this.metrics,i),h=e.hunks.length>0?lf(this.metrics):0,{fileAnnotationHeight:g}=this.cache,_=m+g,v=Math.max(0,f-m-g-h),y=this.hasFileAnnotations(e),b=t+m,x=g>0&&y&&b<r&&b+g>n;if(t<n-f||t>r)return{startingLine:0,totalLines:0,bufferBefore:0,bufferAfter:f-m-h};if(p<=s||e.hunks.length===0)return{startingLine:0,totalLines:s,bufferBefore:0,bufferAfter:0};this.approximateLayoutCheckpoints(e),p=this.getLayoutLineCount(e,l);let S=Math.ceil(Math.max(r-n,0)/c),C=Math.ceil(S/s)*s+s,w=C/s,T=w,E=[],ee=(n+r)/2,D=this.getLayoutCheckpointBeforeTop(Math.max(0,n-t-C*c*2),s),O=t+(D?.top??_),te=D?.renderedLineIndex??0,ne,re,ie;if(wf({diff:e,diffStyle:l,startingLine:D?.renderedLineIndex??0,expandedHunks:a?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:o,callback:({hunkIndex:i,hunk:a,collapsedBefore:o,collapsedAfter:c,deletionLine:f,additionLine:p})=>{let m=p==null?f.splitLineIndex:p.splitLineIndex,h=p==null?f.unifiedLineIndex:p.unifiedLineIndex,g=(p?.noEOFCR??!1)||(f?.noEOFCR??!1),v=i===e.hunks.length-1&&a!=null&&(l===`split`?m===a.splitLineStart+a.splitLineCount-1:h===a.unifiedLineStart+a.unifiedLineCount-1),y=(o>0?Sf({type:u,metrics:this.metrics,hunkIndex:i,hunkSpecs:a?.hunkSpecs}):void 0)?.totalHeight??0;O+=y;let b=te%s===0,x=Math.floor(te/s);if(b&&(E[x]=O-(t+_+y),ie!=null)){if(ie<=0)return!0;ie--}let S=this.getLineHeight(l===`split`?m:h,g);if(O>n-S&&O<r&&(ne??=x),re==null&&O+S>ee&&(re=x),ie==null&&O>=r&&b&&(ie=T),te++,O+=S,c>0||v&&d){let e=Cf({type:u,metrics:this.metrics});e!=null&&(O<r&&O+e.totalHeight>n&&(ne??=x),re==null&&O+e.totalHeight>ee&&(re=x),O+=e.totalHeight)}return!1}}),ne==null){if(x)ne=0,re=0;else return{startingLine:0,totalLines:0,bufferBefore:0,bufferAfter:f-m-h}}re??=ne;let ae=Math.round(re-w/2),oe=Math.max(0,Math.ceil(p/s)-w),k=Math.max(0,Math.min(ae,oe)),A=k*s,se=ae<0?C+ae*s:C,ce=E[k]??0,le=A===0?0:g+ce,ue=k+se/s,de=ue<E.length?v-E[ue]:v-(O-t-_);return{startingLine:A,totalLines:se,bufferBefore:le,bufferAfter:Math.max(0,de)}}};function M_(e){let t;for(let n of e){if(n==null)continue;let e=n.children[1];if(e instanceof HTMLElement)for(let n of e.children)n instanceof HTMLElement&&n.dataset.lineAnnotation===lh&&(t=Math.max(t??0,n.getBoundingClientRect().height))}return t}function N_(e){let t=Array.from(e).sort((e,t)=>e[0]-t[0]),n=[],r=[0],i=0;for(let[e,a]of t)n.push(e),i+=a,r.push(i);return{lineIndexes:n,prefixTotals:r}}function P_({lineIndexes:e,prefixTotals:t},n,r){if(n>=r||e.length===0)return 0;let i=F_(e,n);return(t[F_(e,r)]??0)-(t[i]??0)}function F_(e,t){let n=0,r=e.length;for(;n<r;){let i=n+r>>1,a=e[i];if(a==null)throw Error(`VirtualizedFileDiff: invalid prefix index`);a<t?n=i+1:r=i}return n}function I_(e){return Math.ceil(e/k_)*k_}function L_(e,t){let n=0;for(let r of e)r<t&&n++;return n}function R_({diffStyle:e,hunk:t,rowCount:n}){if(n<=0||!t.noEOFCRAdditions&&!t.noEOFCRDeletions)return[];let r=t.hunkContent.at(-1);if(r==null)return[];if(r.type===`context`)return[n-1];let i=Math.max(r.deletions,r.additions),a=r.deletions+r.additions;if(e===`split`)return i>0&&(t.noEOFCRAdditions||t.noEOFCRDeletions)?[n-1]:[];let o=[],s=n-a;return r.deletions>0&&t.noEOFCRDeletions&&o.push(s+r.deletions-1),r.additions>0&&t.noEOFCRAdditions&&o.push(n-1),o}function z_(e,t){return(e.diffStyle??`split`)!==(t.diffStyle??`split`)||(e.overflow??`scroll`)!==(t.overflow??`scroll`)||(e.collapsed??!1)!==(t.collapsed??!1)||(e.disableLineNumbers??!1)!==(t.disableLineNumbers??!1)||(e.disableFileHeader??!1)!==(t.disableFileHeader??!1)||(e.diffIndicators??`bars`)!==(t.diffIndicators??`bars`)||(e.hunkSeparators??`line-info`)!==(t.hunkSeparators??`line-info`)||!!e.loadDiffFiles!=!!t.loadDiffFiles||(e.expandUnchanged??!1)!==(t.expandUnchanged??!1)||(e.collapsedContextThreshold??1)!==(t.collapsedContextThreshold??1)||e.unsafeCSS!==t.unsafeCSS}function B_(e,t){return(e.disableFileHeader??!1)!==(t.disableFileHeader??!1)||(e.hunkSeparators??`line-info`)!==(t.hunkSeparators??`line-info`)||!!e.loadDiffFiles!=!!t.loadDiffFiles||(e.expandUnchanged??!1)!==(t.expandUnchanged??!1)||(e.collapsedContextThreshold??1)!==(t.collapsedContextThreshold??1)}function V_(e,t){return e.isPartial&&t&&(e.type===`change`||e.type===`rename-changed`)}function H_(e){return typeof e==`function`?`custom`:e??`line-info`}function U_(e,t){return e==null||t==null?e==null&&t==null:Ne(e,t)}function W_(e,t){let[n,r]=e.split(`,`).map(Number);return t===`split`?r:n}function G_(e,t){return typeof window>`u`&&t!=null?(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(`template`,{shadowrootmode:`open`,dangerouslySetInnerHTML:{__html:t}}),e]}):(0,D.jsx)(D.Fragment,{children:e})}var K_=(0,v.createContext)(void 0);function q_(){return(0,v.useContext)(K_)}var J_=typeof window>`u`?v.useEffect:v.useLayoutEffect;function Y_({fileDiff:e,options:t,editorOptions:n,lineAnnotations:r,selectedLines:i,prerenderedHTML:a,metrics:o,hasGutterRenderUtility:s,hasCustomHeader:c,disableWorkerPool:l,edit:u}){let d=q_(),f=i!==void 0,p=(0,v.useContext)(gp),m=te(),h=(0,v.useRef)(null),g=E(n=>{if(n!=null){if(h.current!=null)throw Error(`useFileDiffInstance: An instance should not already exist when a node is created`);d==null?h.current=new S_(X_({controlledSelection:f,hasCustomHeader:c,hasGutterRenderUtility:s,options:t}),l?void 0:p,!0):h.current=new j_(X_({controlledSelection:f,hasCustomHeader:c,hasGutterRenderUtility:s,options:t}),d,o,l?void 0:p,!0),h.current.hydrate({fileDiff:e,fileContainer:n,lineAnnotations:r,prerenderedHTML:a})}else{if(h.current==null)throw Error(`useFileDiffInstance: A FileDiff instance should exist when unmounting`);h.current.cleanUp(),h.current=null}});return J_(()=>{let{current:n}=h;if(n==null)return;let a=X_({controlledSelection:f,hasCustomHeader:c,hasGutterRenderUtility:s,options:t}),o=a!==void 0&&!vp(n.options,a);n.setOptions(a),n.render({forceRender:o,fileDiff:e,lineAnnotations:r}),i!==void 0&&n.setSelectedLines(i)}),J_(()=>{if(u&&h.current!=null){if(m===void 0)throw Error(`FileDiff: EditContext is not attached`);let e=m(n??{});if(e==null)throw Error(`FileDiff: EditProvider.createEditor must return an editor instance`);try{return e.edit(h.current)}catch(t){throw e.cleanUp(),t}}},[u]),{ref:g,getHoveredLine:(0,v.useCallback)(()=>h.current?.getHoveredLine(),[])}}function X_({options:e,controlledSelection:t,hasCustomHeader:n,hasGutterRenderUtility:r}){return t||r||n?{...e,controlledSelection:t,renderCustomHeader:n?ie:e?.renderCustomHeader,renderGutterUtility:r?ie:e?.renderGutterUtility}:e}function Z_({fileDiff:e,options:t,editorOptions:n,metrics:r,lineAnnotations:i,selectedLines:a,className:o,style:s,prerenderedHTML:c,renderAnnotation:l,renderCustomHeader:u,renderHeaderPrefix:d,renderHeaderFilenameSuffix:f,renderHeaderMetadata:p,renderGutterUtility:m,disableWorkerPool:h=!1,edit:g=!1}){let{ref:_,getHoveredLine:v}=Y_({fileDiff:e,options:t,editorOptions:n,metrics:r,lineAnnotations:i,selectedLines:a,prerenderedHTML:c,hasGutterRenderUtility:m!=null,hasCustomHeader:u!=null,disableWorkerPool:h,edit:g});return(0,D.jsx)(ae,{ref:_,className:o,style:s,children:G_(Ae({fileDiff:e,renderCustomHeader:u,renderHeaderPrefix:d,renderHeaderFilenameSuffix:f,renderHeaderMetadata:p,renderAnnotation:l,renderGutterUtility:m,lineAnnotations:i,getHoveredLine:v}),c)})}var Q_=(...e)=>e.filter((e,t,n)=>!!e&&e.trim()!==``&&n.indexOf(e)===t).join(` `).trim(),$_=e=>e.replace(/([a-z0-9])([A-Z])/g,`$1-$2`).toLowerCase(),ev=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,n)=>n?n.toUpperCase():t.toLowerCase()),tv=e=>{let t=ev(e);return t.charAt(0).toUpperCase()+t.slice(1)},nv={xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:2,strokeLinecap:`round`,strokeLinejoin:`round`},rv=e=>{for(let t in e)if(t.startsWith(`aria-`)||t===`role`||t===`title`)return!0;return!1},iv=(0,v.createContext)({}),av=()=>(0,v.useContext)(iv),ov=(0,v.forwardRef)(({color:e,size:t,strokeWidth:n,absoluteStrokeWidth:r,className:i=``,children:a,iconNode:o,...s},c)=>{let{size:l=24,strokeWidth:u=2,absoluteStrokeWidth:d=!1,color:f=`currentColor`,className:p=``}=av()??{},m=r??d?Number(n??u)*24/Number(t??l):n??u;return(0,v.createElement)(`svg`,{ref:c,...nv,width:t??l??nv.width,height:t??l??nv.height,stroke:e??f,strokeWidth:m,className:Q_(`lucide`,p,i),...!a&&!rv(s)&&{"aria-hidden":`true`},...s},[...o.map(([e,t])=>(0,v.createElement)(e,t)),...Array.isArray(a)?a:[a]])}),sv=(e,t)=>{let n=(0,v.forwardRef)(({className:n,...r},i)=>(0,v.createElement)(ov,{ref:i,iconNode:t,className:Q_(`lucide-${$_(tv(e))}`,`lucide-${e}`,n),...r}));return n.displayName=tv(e),n},cv=sv(`check`,[[`path`,{d:`M20 6 9 17l-5-5`,key:`1gmf2c`}]]),lv=sv(`chevron-down`,[[`path`,{d:`m6 9 6 6 6-6`,key:`qrunsl`}]]),uv=sv(`chevron-right`,[[`path`,{d:`m9 18 6-6-6-6`,key:`mthhwq`}]]),dv=sv(`chevrons-down-up`,[[`path`,{d:`m7 20 5-5 5 5`,key:`13a0gw`}],[`path`,{d:`m7 4 5 5 5-5`,key:`1kwcof`}]]),fv=sv(`chevrons-up-down`,[[`path`,{d:`m7 15 5 5 5-5`,key:`1hf1tw`}],[`path`,{d:`m7 9 5-5 5 5`,key:`sgt6xg`}]]),pv=sv(`eye-off`,[[`path`,{d:`M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49`,key:`ct8e1f`}],[`path`,{d:`M14.084 14.158a3 3 0 0 1-4.242-4.242`,key:`151rxh`}],[`path`,{d:`M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143`,key:`13bj9a`}],[`path`,{d:`m2 2 20 20`,key:`1ooewy`}]]),mv=sv(`eye`,[[`path`,{d:`M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0`,key:`1nclc0`}],[`circle`,{cx:`12`,cy:`12`,r:`3`,key:`1v7zrd`}]]),hv=sv(`message-square-plus`,[[`path`,{d:`M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z`,key:`18887p`}],[`path`,{d:`M12 8v6`,key:`1ib9pf`}],[`path`,{d:`M9 11h6`,key:`1fldmi`}]]),gv=sv(`message-square`,[[`path`,{d:`M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z`,key:`18887p`}]]),_v=sv(`plus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`M12 5v14`,key:`s699le`}]]),vv=sv(`rotate-ccw-clock`,[[`path`,{d:`M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8`,key:`1357e3`}],[`path`,{d:`M3 3v5h5`,key:`1xhq8a`}],[`path`,{d:`M12 7v5l4 2`,key:`1fdv2h`}]]),yv=sv(`sparkles`,[[`path`,{d:`M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z`,key:`1s2grr`}],[`path`,{d:`M20 2v4`,key:`1rf3ol`}],[`path`,{d:`M22 4h-4`,key:`gwowj6`}],[`circle`,{cx:`4`,cy:`20`,r:`2`,key:`6kqj1y`}]]),bv=sv(`trash`,[[`path`,{d:`M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6`,key:`miytrc`}],[`path`,{d:`M3 6h18`,key:`d0wm0j`}],[`path`,{d:`M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2`,key:`e791ji`}]]),xv=sv(`x`,[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]),Sv=`github-dark-dimmed`;function Cv(e){switch(e.kind){case`orientation`:return`orientation`;case`topic`:return`topic:${e.topicId}`;case`question`:return`question:${e.questionId}`}}function wv(e){return e.guide.comments.length>0||e.threads.some(e=>!e.resolved)}function Tv({checked:e,label:t,onChange:n,className:r}){return(0,D.jsxs)(`label`,{className:`checkbox-btn${r?` ${r}`:``}`,children:[(0,D.jsx)(`input`,{type:`checkbox`,className:`checkbox-input`,checked:e,onChange:e=>n(e.target.checked)}),(0,D.jsx)(`span`,{className:`checkbox-box`,"aria-hidden":`true`,children:e&&(0,D.jsx)(cv,{size:10,strokeWidth:3})}),(0,D.jsx)(`span`,{children:t})]})}function X({variant:e=`default`,active:t=!1,muted:n=!1,iconOnly:r=!1,pill:i=!1,type:a=`button`,className:o,...s}){let c=[`button`,`button-${e}`,t&&`button-active`,n&&`button-muted`,r&&`button-icon-only`,i&&`button-pill`,o].filter(Boolean).join(` `);return(0,D.jsx)(`button`,{...s,type:a,className:c})}function Ev({className:e,inputClassName:t,actionsClassName:n,placeholder:r,submitLabel:i,cancelLabel:a=`Cancel`,value:o,rows:s=3,autoFocus:c=!1,allowEmptySubmit:l=!1,children:u,onValueChange:d,onSubmit:f,onCancel:p}){let[m,h]=(0,v.useState)(``),g=(0,v.useRef)(null),_=o??m,y=_.trim();(0,v.useEffect)(()=>{c&&g.current?.focus()},[c]);let b=e=>{o===void 0&&h(e),d?.(e)},x=()=>{!y&&!l||(o===void 0&&h(``),f(y))},S=(0,D.jsx)(`textarea`,{ref:g,className:[`text-input-area`,t].filter(Boolean).join(` `),value:_,rows:s,autoFocus:c,placeholder:r,onChange:e=>b(e.target.value),onKeyDown:e=>{e.key===`Enter`&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),x()),e.key===`Escape`&&p&&(e.preventDefault(),p())}});return(0,D.jsxs)(`form`,{className:e,onSubmit:e=>{e.preventDefault(),x()},children:[S,(0,D.jsxs)(`div`,{className:n,children:[u,p&&(0,D.jsx)(X,{variant:`ghost`,onClick:p,children:a}),(0,D.jsx)(X,{type:`submit`,variant:`primary`,disabled:!y&&!l,children:i})]})]})}var Dv=(0,v.memo)(function({onSave:e,onCancel:t}){let[n,r]=(0,v.useState)(!1);return(0,D.jsx)(Ev,{className:`comment-editor`,inputClassName:`comment-input`,actionsClassName:`comment-actions`,placeholder:`Add a comment…`,submitLabel:`comment`,rows:2,autoFocus:!0,allowEmptySubmit:!0,onSubmit:t=>e(t,n),onCancel:t,children:(0,D.jsx)(Tv,{checked:n,label:`ask agent`,onChange:r})})});function Ov({additions:e,deletions:t,className:n}){let r=[`diff-stats`,n].filter(Boolean).join(` `);return(0,D.jsxs)(`span`,{className:r,children:[(0,D.jsxs)(`span`,{className:`stat-add`,children:[`+`,e]}),(0,D.jsxs)(`span`,{className:`stat-del`,children:[`-`,t]})]})}var kv=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,Av=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,jv={};function Mv(e,t){return((t||jv).jsx?Av:kv).test(e)}var Nv=o(((e,t)=>{var n=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,r=/\n/g,i=/^\s*/,a=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,s=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,c=/^[;\s]*/,l=/^\s+|\s+$/g;function u(e,t){if(typeof e!=`string`)throw TypeError(`First argument must be a string`);if(!e)return[];t||={};var l=1,u=1;function f(e){var t=e.match(r);t&&(l+=t.length);var n=e.lastIndexOf(`
|
|
1538
|
+
`);u=~n?e.length-n:u+e.length}function p(){var e={line:l,column:u};return function(t){return t.position=new m(e),_(),t}}function m(e){this.start=e,this.end={line:l,column:u},this.source=t.source}m.prototype.content=e;function h(n){var r=Error(t.source+`:`+l+`:`+u+`: `+n);if(r.reason=n,r.filename=t.source,r.line=l,r.column=u,r.source=e,!t.silent)throw r}function g(t){var n=t.exec(e);if(n){var r=n[0];return f(r),e=e.slice(r.length),n}}function _(){g(i)}function v(e){var t;for(e||=[];t=y();)t!==!1&&e.push(t);return e}function y(){var t=p();if(e.charAt(0)==`/`&&e.charAt(1)==`*`){for(var n=2;e.charAt(n)!=``&&(e.charAt(n)!=`*`||e.charAt(n+1)!=`/`);)++n;if(n+=2,e.charAt(n-1)===``)return h(`End of comment missing`);var r=e.slice(2,n-2);return u+=2,f(r),e=e.slice(n),u+=2,t({type:`comment`,comment:r})}}function b(){var e=p(),t=g(a);if(t){if(y(),!g(o))return h(`property missing ':'`);var r=g(s),i=e({type:`declaration`,property:d(t[0].replace(n,``)),value:r?d(r[0].replace(n,``)):``});return g(c),i}}function x(){var e=[];v(e);for(var t;t=b();)t!==!1&&(e.push(t),v(e));return e}return _(),x()}function d(e){return e?e.replace(l,``):``}t.exports=u})),Pv=o((e=>{var t=e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;var n=t(Nv());function r(e,t){let r=null;if(!e||typeof e!=`string`)return r;let i=(0,n.default)(e),a=typeof t==`function`;return i.forEach(e=>{if(e.type!==`declaration`)return;let{property:n,value:i}=e;a?t(n,i,e):i&&(r||={},r[n]=i)}),r}})),Fv=o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.camelCase=void 0;var t=/^--[a-zA-Z0-9_-]+$/,n=/-([a-z])/g,r=/^[^-]+$/,i=/^-(webkit|moz|ms|o|khtml)-/,a=/^-(ms)-/,o=function(e){return!e||r.test(e)||t.test(e)},s=function(e,t){return t.toUpperCase()},c=function(e,t){return`${t}-`};e.camelCase=function(e,t){return t===void 0&&(t={}),o(e)?e:(e=e.toLowerCase(),e=t.reactCompat?e.replace(a,c):e.replace(i,c),e.replace(n,s))}})),Iv=o(((e,t)=>{var n=(e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(Pv()),r=Fv();function i(e,t){var i={};return!e||typeof e!=`string`||(0,n.default)(e,function(e,n){e&&n&&(i[(0,r.camelCase)(e,t)]=n)}),i}i.default=i,t.exports=i})),Lv=zv(`end`),Rv=zv(`start`);function zv(e){return t;function t(t){let n=t&&t.position&&t.position[e]||{};if(typeof n.line==`number`&&n.line>0&&typeof n.column==`number`&&n.column>0)return{line:n.line,column:n.column,offset:typeof n.offset==`number`&&n.offset>-1?n.offset:void 0}}}function Bv(e){let t=Rv(e),n=Lv(e);if(t&&n)return{start:t,end:n}}function Vv(e){return!e||typeof e!=`object`?``:`position`in e||`type`in e?Uv(e.position):`start`in e||`end`in e?Uv(e):`line`in e||`column`in e?Hv(e):``}function Hv(e){return Wv(e&&e.line)+`:`+Wv(e&&e.column)}function Uv(e){return Hv(e&&e.start)+`-`+Hv(e&&e.end)}function Wv(e){return e&&typeof e==`number`?e:1}var Gv=class extends Error{constructor(e,t,n){super(),typeof t==`string`&&(n=t,t=void 0);let r=``,i={},a=!1;if(t&&(i=`line`in t&&`column`in t||`start`in t&&`end`in t?{place:t}:`type`in t?{ancestors:[t],place:t.position}:{...t}),typeof e==`string`?r=e:!i.cause&&e&&(a=!0,r=e.message,i.cause=e),!i.ruleId&&!i.source&&typeof n==`string`){let e=n.indexOf(`:`);e===-1?i.ruleId=n:(i.source=n.slice(0,e),i.ruleId=n.slice(e+1))}if(!i.place&&i.ancestors&&i.ancestors){let e=i.ancestors[i.ancestors.length-1];e&&(i.place=e.position)}let o=i.place&&`start`in i.place?i.place.start:i.place;this.ancestors=i.ancestors||void 0,this.cause=i.cause||void 0,this.column=o?o.column:void 0,this.fatal=void 0,this.file=``,this.message=r,this.line=o?o.line:void 0,this.name=Vv(i.place)||`1:1`,this.place=i.place||void 0,this.reason=this.message,this.ruleId=i.ruleId||void 0,this.source=i.source||void 0,this.stack=a&&i.cause&&typeof i.cause.stack==`string`?i.cause.stack:``,this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}};Gv.prototype.file=``,Gv.prototype.name=``,Gv.prototype.reason=``,Gv.prototype.message=``,Gv.prototype.stack=``,Gv.prototype.column=void 0,Gv.prototype.line=void 0,Gv.prototype.ancestors=void 0,Gv.prototype.cause=void 0,Gv.prototype.fatal=void 0,Gv.prototype.place=void 0,Gv.prototype.ruleId=void 0,Gv.prototype.source=void 0;var Kv=l(Iv(),1),qv={}.hasOwnProperty,Jv=new Map,Yv=/[A-Z]/g,Xv=new Set([`table`,`tbody`,`thead`,`tfoot`,`tr`]),Zv=new Set([`td`,`th`]),Qv=`https://github.com/syntax-tree/hast-util-to-jsx-runtime`;function $v(e,t){if(!t||t.Fragment===void 0)throw TypeError("Expected `Fragment` in options");let n=t.filePath||void 0,r;if(t.development){if(typeof t.jsxDEV!=`function`)throw TypeError("Expected `jsxDEV` in options when `development: true`");r=uy(n,t.jsxDEV)}else{if(typeof t.jsx!=`function`)throw TypeError("Expected `jsx` in production options");if(typeof t.jsxs!=`function`)throw TypeError("Expected `jsxs` in production options");r=ly(n,t.jsx,t.jsxs)}let i={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:r,elementAttributeNameCase:t.elementAttributeNameCase||`react`,evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space===`svg`?Gi:Wi,stylePropertyNameCase:t.stylePropertyNameCase||`dom`,tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=ey(i,e,void 0);return a&&typeof a!=`string`?a:i.create(e,i.Fragment,{children:a||void 0},void 0)}function ey(e,t,n){if(t.type===`element`)return ty(e,t,n);if(t.type===`mdxFlowExpression`||t.type===`mdxTextExpression`)return ny(e,t);if(t.type===`mdxJsxFlowElement`||t.type===`mdxJsxTextElement`)return iy(e,t,n);if(t.type===`mdxjsEsm`)return ry(e,t);if(t.type===`root`)return ay(e,t,n);if(t.type===`text`)return oy(e,t)}function ty(e,t,n){let r=e.schema,i=r;t.tagName.toLowerCase()===`svg`&&r.space===`html`&&(i=Gi,e.schema=i),e.ancestors.push(t);let a=gy(e,t.tagName,!1),o=dy(e,t),s=py(e,t);return Xv.has(t.tagName)&&(s=s.filter(function(e){return typeof e!=`string`||!Ta(e)})),sy(e,o,a,t),cy(o,s),e.ancestors.pop(),e.schema=r,e.create(t,a,o,n)}function ny(e,t){if(t.data&&t.data.estree&&e.evaluater){let n=t.data.estree.body[0];return n.type,e.evaluater.evaluateExpression(n.expression)}_y(e,t.position)}function ry(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);_y(e,t.position)}function iy(e,t,n){let r=e.schema,i=r;t.name===`svg`&&r.space===`html`&&(i=Gi,e.schema=i),e.ancestors.push(t);let a=t.name===null?e.Fragment:gy(e,t.name,!0),o=fy(e,t),s=py(e,t);return sy(e,o,a,t),cy(o,s),e.ancestors.pop(),e.schema=r,e.create(t,a,o,n)}function ay(e,t,n){let r={};return cy(r,py(e,t)),e.create(t,e.Fragment,r,n)}function oy(e,t){return t.value}function sy(e,t,n,r){typeof n!=`string`&&n!==e.Fragment&&e.passNode&&(t.node=r)}function cy(e,t){if(t.length>0){let n=t.length>1?t:t[0];n&&(e.children=n)}}function ly(e,t,n){return r;function r(e,r,i,a){let o=Array.isArray(i.children)?n:t;return a?o(r,i,a):o(r,i)}}function uy(e,t){return n;function n(n,r,i,a){let o=Array.isArray(i.children),s=Rv(n);return t(r,i,a,o,{columnNumber:s?s.column-1:void 0,fileName:e,lineNumber:s?s.line:void 0},void 0)}}function dy(e,t){let n={},r,i;for(i in t.properties)if(i!==`children`&&qv.call(t.properties,i)){let a=my(e,i,t.properties[i]);if(a){let[i,o]=a;e.tableCellAlignToStyle&&i===`align`&&typeof o==`string`&&Zv.has(t.tagName)?r=o:n[i]=o}}if(r){let t=n.style||={};t[e.stylePropertyNameCase===`css`?`text-align`:`textAlign`]=r}return n}function fy(e,t){let n={};for(let r of t.attributes)if(r.type===`mdxJsxExpressionAttribute`){if(r.data&&r.data.estree&&e.evaluater){let t=r.data.estree.body[0];t.type;let i=t.expression;i.type;let a=i.properties[0];a.type,Object.assign(n,e.evaluater.evaluateExpression(a.argument))}else _y(e,t.position)}else{let i=r.name,a;if(r.value&&typeof r.value==`object`){if(r.value.data&&r.value.data.estree&&e.evaluater){let t=r.value.data.estree.body[0];t.type,a=e.evaluater.evaluateExpression(t.expression)}else _y(e,t.position)}else a=r.value===null||r.value;n[i]=a}return n}function py(e,t){let n=[],r=-1,i=e.passKeys?new Map:Jv;for(;++r<t.children.length;){let a=t.children[r],o;if(e.passKeys){let e=a.type===`element`?a.tagName:a.type===`mdxJsxFlowElement`||a.type===`mdxJsxTextElement`?a.name:void 0;if(e){let t=i.get(e)||0;o=e+`-`+t,i.set(e,t+1)}}let s=ey(e,a,o);s!==void 0&&n.push(s)}return n}function my(e,t,n){let r=Vi(e.schema,t);if(!(n==null||typeof n==`number`&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?Sa(n):Ca(n)),r.property===`style`){let t=typeof n==`object`?n:hy(e,String(n));return e.stylePropertyNameCase===`css`&&(t=vy(t)),[`style`,t]}return[e.elementAttributeNameCase===`react`&&r.space?Li[r.property]||r.property:r.attribute,n]}}function hy(e,t){try{return(0,Kv.default)(t,{reactCompat:!0})}catch(t){if(e.ignoreInvalidStyle)return{};let n=t,r=new Gv("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:n,ruleId:`style`,source:`hast-util-to-jsx-runtime`});throw r.file=e.filePath||void 0,r.url=Qv+`#cannot-parse-style-attribute`,r}}function gy(e,t,n){let r;if(!n)r={type:`Literal`,value:t};else if(t.includes(`.`)){let e=t.split(`.`),n=-1,i;for(;++n<e.length;){let t=Mv(e[n])?{type:`Identifier`,name:e[n]}:{type:`Literal`,value:e[n]};i=i?{type:`MemberExpression`,object:i,property:t,computed:!!(n&&t.type===`Literal`),optional:!1}:t}r=i}else r=Mv(t)&&!/^[a-z]/.test(t)?{type:`Identifier`,name:t}:{type:`Literal`,value:t};if(r.type===`Literal`){let t=r.value;return qv.call(e.components,t)?e.components[t]:t}if(e.evaluater)return e.evaluater.evaluateExpression(r);_y(e)}function _y(e,t){let n=new Gv("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:`mdx-estree`,source:`hast-util-to-jsx-runtime`});throw n.file=e.filePath||void 0,n.url=Qv+`#cannot-handle-mdx-estrees-without-createevaluater`,n}function vy(e){let t={},n;for(n in e)qv.call(e,n)&&(t[yy(n)]=e[n]);return t}function yy(e){let t=e.replace(Yv,by);return t.slice(0,3)===`ms-`&&(t=`-`+t),t}function by(e){return`-`+e.toLowerCase()}var xy={action:[`form`],cite:[`blockquote`,`del`,`ins`,`q`],data:[`object`],formAction:[`button`,`input`],href:[`a`,`area`,`base`,`link`],icon:[`menuitem`],itemId:null,manifest:[`html`],ping:[`a`,`area`],poster:[`video`],src:[`audio`,`embed`,`iframe`,`img`,`input`,`script`,`source`,`track`,`video`]},Sy={};function Cy(e,t){let n=t||Sy;return wy(e,typeof n.includeImageAlt!=`boolean`||n.includeImageAlt,typeof n.includeHtml!=`boolean`||n.includeHtml)}function wy(e,t,n){if(Ey(e)){if(`value`in e)return e.type===`html`&&!n?``:e.value;if(t&&`alt`in e&&e.alt)return e.alt;if(`children`in e)return Ty(e.children,t,n)}return Array.isArray(e)?Ty(e,t,n):``}function Ty(e,t,n){let r=[],i=-1;for(;++i<e.length;)r[i]=wy(e[i],t,n);return r.join(``)}function Ey(e){return!!(e&&typeof e==`object`)}var Dy=document.createElement(`i`);function Oy(e){let t=`&`+e+`;`;Dy.innerHTML=t;let n=Dy.textContent;return n.charCodeAt(n.length-1)===59&&e!==`semi`?!1:n!==t&&n}function ky(e,t,n,r){let i=e.length,a=0,o;if(t=t<0?-t>i?0:i+t:t>i?i:t,n=n>0?n:0,r.length<1e4)o=Array.from(r),o.unshift(t,n),e.splice(...o);else for(n&&e.splice(t,n);a<r.length;)o=r.slice(a,a+1e4),o.unshift(t,0),e.splice(...o),a+=1e4,t+=1e4}function Ay(e,t){return e.length>0?(ky(e,e.length,0,t),e):t}var jy={}.hasOwnProperty;function My(e){let t={},n=-1;for(;++n<e.length;)Ny(t,e[n]);return t}function Ny(e,t){let n;for(n in t){let r=(jy.call(e,n)?e[n]:void 0)||(e[n]={}),i=t[n],a;if(i)for(a in i){jy.call(r,a)||(r[a]=[]);let e=i[a];Py(r[a],Array.isArray(e)?e:e?[e]:[])}}}function Py(e,t){let n=-1,r=[];for(;++n<t.length;)(t[n].add===`after`?e:r).push(t[n]);ky(e,0,0,r)}function Fy(e,t){let n=Number.parseInt(e,t);return n<9||n===11||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)==65535||(n&65535)==65534||n>1114111?`�`:String.fromCodePoint(n)}function Iy(e){return e.replace(/[\t\n\r ]+/g,` `).replace(/^ | $/g,``).toLowerCase().toUpperCase()}var Ly=qy(/[A-Za-z]/),Ry=qy(/[\dA-Za-z]/),zy=qy(/[#-'*+\--9=?A-Z^-~]/);function By(e){return e!==null&&(e<32||e===127)}var Vy=qy(/\d/),Hy=qy(/[\dA-Fa-f]/),Uy=qy(/[!-/:-@[-`{-~]/);function Z(e){return e!==null&&e<-2}function Wy(e){return e!==null&&(e<0||e===32)}function Q(e){return e===-2||e===-1||e===32}var Gy=qy(/\p{P}|\p{S}/u),Ky=qy(/\s/);function qy(e){return t;function t(t){return t!==null&&t>-1&&e.test(String.fromCharCode(t))}}function Jy(e){let t=[],n=-1,r=0,i=0;for(;++n<e.length;){let a=e.charCodeAt(n),o=``;if(a===37&&Ry(e.charCodeAt(n+1))&&Ry(e.charCodeAt(n+2)))i=2;else if(a<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(a))||(o=String.fromCharCode(a));else if(a>55295&&a<57344){let t=e.charCodeAt(n+1);a<56320&&t>56319&&t<57344?(o=String.fromCharCode(a,t),i=1):o=`�`}else o=String.fromCharCode(a);o&&=(t.push(e.slice(r,n),encodeURIComponent(o)),r=n+i+1,``),i&&=(n+=i,0)}return t.join(``)+e.slice(r)}function $(e,t,n,r){let i=r?r-1:1/0,a=0;return o;function o(r){return Q(r)?(e.enter(n),s(r)):t(r)}function s(r){return Q(r)&&a++<i?(e.consume(r),s):(e.exit(n),t(r))}}var Yy={tokenize:Xy};function Xy(e){let t=e.attempt(this.parser.constructs.contentInitial,r,i),n;return t;function r(n){if(n===null){e.consume(n);return}return e.enter(`lineEnding`),e.consume(n),e.exit(`lineEnding`),$(e,t,`linePrefix`)}function i(t){return e.enter(`paragraph`),a(t)}function a(t){let r=e.enter(`chunkText`,{contentType:`text`,previous:n});return n&&(n.next=r),n=r,o(t)}function o(t){if(t===null){e.exit(`chunkText`),e.exit(`paragraph`),e.consume(t);return}return Z(t)?(e.consume(t),e.exit(`chunkText`),a):(e.consume(t),o)}}var Zy={tokenize:$y},Qy={tokenize:eb};function $y(e){let t=this,n=[],r=0,i,a,o;return s;function s(i){if(r<n.length){let a=n[r];return t.containerState=a[1],e.attempt(a[0].continuation,c,l)(i)}return l(i)}function c(e){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,i&&v();let n=t.events.length,a=n,o;for(;a--;)if(t.events[a][0]===`exit`&&t.events[a][1].type===`chunkFlow`){o=t.events[a][1].end;break}_(r);let s=n;for(;s<t.events.length;)t.events[s][1].end={...o},s++;return ky(t.events,a+1,0,t.events.slice(n)),t.events.length=s,l(e)}return s(e)}function l(a){if(r===n.length){if(!i)return f(a);if(i.currentConstruct&&i.currentConstruct.concrete)return m(a);t.interrupt=!!(i.currentConstruct&&!i._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(Qy,u,d)(a)}function u(e){return i&&v(),_(r),f(e)}function d(e){return t.parser.lazy[t.now().line]=r!==n.length,o=t.now().offset,m(e)}function f(n){return t.containerState={},e.attempt(Qy,p,m)(n)}function p(e){return r++,n.push([t.currentConstruct,t.containerState]),f(e)}function m(n){if(n===null){i&&v(),_(0),e.consume(n);return}return i||=t.parser.flow(t.now()),e.enter(`chunkFlow`,{_tokenizer:i,contentType:`flow`,previous:a}),h(n)}function h(n){if(n===null){g(e.exit(`chunkFlow`),!0),_(0),e.consume(n);return}return Z(n)?(e.consume(n),g(e.exit(`chunkFlow`)),r=0,t.interrupt=void 0,s):(e.consume(n),h)}function g(e,n){let s=t.sliceStream(e);if(n&&s.push(null),e.previous=a,a&&(a.next=e),a=e,i.defineSkip(e.start),i.write(s),t.parser.lazy[e.start.line]){let e=i.events.length;for(;e--;)if(i.events[e][1].start.offset<o&&(!i.events[e][1].end||i.events[e][1].end.offset>o))return;let n=t.events.length,a=n,s,c;for(;a--;)if(t.events[a][0]===`exit`&&t.events[a][1].type===`chunkFlow`){if(s){c=t.events[a][1].end;break}s=!0}for(_(r),e=n;e<t.events.length;)t.events[e][1].end={...c},e++;ky(t.events,a+1,0,t.events.slice(n)),t.events.length=e}}function _(r){let i=n.length;for(;i-->r;){let r=n[i];t.containerState=r[1],r[0].exit.call(t,e)}n.length=r}function v(){i.write([null]),a=void 0,i=void 0,t.containerState._closeFlow=void 0}}function eb(e,t,n){return $(e,e.attempt(this.parser.constructs.document,t,n),`linePrefix`,this.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)}function tb(e){if(e===null||Wy(e)||Ky(e))return 1;if(Gy(e))return 2}function nb(e,t,n){let r=[],i=-1;for(;++i<e.length;){let a=e[i].resolveAll;a&&!r.includes(a)&&(t=a(t,n),r.push(a))}return t}var rb={name:`attention`,resolveAll:ib,tokenize:ab};function ib(e,t){let n=-1,r,i,a,o,s,c,l,u;for(;++n<e.length;)if(e[n][0]===`enter`&&e[n][1].type===`attentionSequence`&&e[n][1]._close){for(r=n;r--;)if(e[r][0]===`exit`&&e[r][1].type===`attentionSequence`&&e[r][1]._open&&t.sliceSerialize(e[r][1]).charCodeAt(0)===t.sliceSerialize(e[n][1]).charCodeAt(0)){if((e[r][1]._close||e[n][1]._open)&&(e[n][1].end.offset-e[n][1].start.offset)%3&&!((e[r][1].end.offset-e[r][1].start.offset+e[n][1].end.offset-e[n][1].start.offset)%3))continue;c=e[r][1].end.offset-e[r][1].start.offset>1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;let d={...e[r][1].end},f={...e[n][1].start};ob(d,-c),ob(f,c),o={type:c>1?`strongSequence`:`emphasisSequence`,start:d,end:{...e[r][1].end}},s={type:c>1?`strongSequence`:`emphasisSequence`,start:{...e[n][1].start},end:f},a={type:c>1?`strongText`:`emphasisText`,start:{...e[r][1].end},end:{...e[n][1].start}},i={type:c>1?`strong`:`emphasis`,start:{...o.start},end:{...s.end}},e[r][1].end={...o.start},e[n][1].start={...s.end},l=[],e[r][1].end.offset-e[r][1].start.offset&&(l=Ay(l,[[`enter`,e[r][1],t],[`exit`,e[r][1],t]])),l=Ay(l,[[`enter`,i,t],[`enter`,o,t],[`exit`,o,t],[`enter`,a,t]]),l=Ay(l,nb(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),l=Ay(l,[[`exit`,a,t],[`enter`,s,t],[`exit`,s,t],[`exit`,i,t]]),e[n][1].end.offset-e[n][1].start.offset?(u=2,l=Ay(l,[[`enter`,e[n][1],t],[`exit`,e[n][1],t]])):u=0,ky(e,r-1,n-r+3,l),n=r+l.length-u-2;break}}for(n=-1;++n<e.length;)e[n][1].type===`attentionSequence`&&(e[n][1].type=`data`);return e}function ab(e,t){let n=this.parser.constructs.attentionMarkers.null,r=this.previous,i=tb(r),a;return o;function o(t){return a=t,e.enter(`attentionSequence`),s(t)}function s(o){if(o===a)return e.consume(o),s;let c=e.exit(`attentionSequence`),l=tb(o),u=!l||l===2&&i||n.includes(o),d=!i||i===2&&l||n.includes(r);return c._open=!!(a===42?u:u&&(i||!d)),c._close=!!(a===42?d:d&&(l||!u)),t(o)}}function ob(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}var sb={name:`autolink`,tokenize:cb};function cb(e,t,n){let r=0;return i;function i(t){return e.enter(`autolink`),e.enter(`autolinkMarker`),e.consume(t),e.exit(`autolinkMarker`),e.enter(`autolinkProtocol`),a}function a(t){return Ly(t)?(e.consume(t),o):t===64?n(t):l(t)}function o(e){return e===43||e===45||e===46||Ry(e)?(r=1,s(e)):l(e)}function s(t){return t===58?(e.consume(t),r=0,c):(t===43||t===45||t===46||Ry(t))&&r++<32?(e.consume(t),s):(r=0,l(t))}function c(r){return r===62?(e.exit(`autolinkProtocol`),e.enter(`autolinkMarker`),e.consume(r),e.exit(`autolinkMarker`),e.exit(`autolink`),t):r===null||r===32||r===60||By(r)?n(r):(e.consume(r),c)}function l(t){return t===64?(e.consume(t),u):zy(t)?(e.consume(t),l):n(t)}function u(e){return Ry(e)?d(e):n(e)}function d(n){return n===46?(e.consume(n),r=0,u):n===62?(e.exit(`autolinkProtocol`).type=`autolinkEmail`,e.enter(`autolinkMarker`),e.consume(n),e.exit(`autolinkMarker`),e.exit(`autolink`),t):f(n)}function f(t){if((t===45||Ry(t))&&r++<63){let n=t===45?f:d;return e.consume(t),n}return n(t)}}var lb={partial:!0,tokenize:ub};function ub(e,t,n){return r;function r(t){return Q(t)?$(e,i,`linePrefix`)(t):i(t)}function i(e){return e===null||Z(e)?t(e):n(e)}}var db={continuation:{tokenize:pb},exit:mb,name:`blockQuote`,tokenize:fb};function fb(e,t,n){let r=this;return i;function i(t){if(t===62){let n=r.containerState;return n.open||=(e.enter(`blockQuote`,{_container:!0}),!0),e.enter(`blockQuotePrefix`),e.enter(`blockQuoteMarker`),e.consume(t),e.exit(`blockQuoteMarker`),a}return n(t)}function a(n){return Q(n)?(e.enter(`blockQuotePrefixWhitespace`),e.consume(n),e.exit(`blockQuotePrefixWhitespace`),e.exit(`blockQuotePrefix`),t):(e.exit(`blockQuotePrefix`),t(n))}}function pb(e,t,n){let r=this;return i;function i(t){return Q(t)?$(e,a,`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(t):a(t)}function a(r){return e.attempt(db,t,n)(r)}}function mb(e){e.exit(`blockQuote`)}var hb={name:`characterEscape`,tokenize:gb};function gb(e,t,n){return r;function r(t){return e.enter(`characterEscape`),e.enter(`escapeMarker`),e.consume(t),e.exit(`escapeMarker`),i}function i(r){return Uy(r)?(e.enter(`characterEscapeValue`),e.consume(r),e.exit(`characterEscapeValue`),e.exit(`characterEscape`),t):n(r)}}var _b={name:`characterReference`,tokenize:vb};function vb(e,t,n){let r=this,i=0,a,o;return s;function s(t){return e.enter(`characterReference`),e.enter(`characterReferenceMarker`),e.consume(t),e.exit(`characterReferenceMarker`),c}function c(t){return t===35?(e.enter(`characterReferenceMarkerNumeric`),e.consume(t),e.exit(`characterReferenceMarkerNumeric`),l):(e.enter(`characterReferenceValue`),a=31,o=Ry,u(t))}function l(t){return t===88||t===120?(e.enter(`characterReferenceMarkerHexadecimal`),e.consume(t),e.exit(`characterReferenceMarkerHexadecimal`),e.enter(`characterReferenceValue`),a=6,o=Hy,u):(e.enter(`characterReferenceValue`),a=7,o=Vy,u(t))}function u(s){if(s===59&&i){let i=e.exit(`characterReferenceValue`);return o===Ry&&!Oy(r.sliceSerialize(i))?n(s):(e.enter(`characterReferenceMarker`),e.consume(s),e.exit(`characterReferenceMarker`),e.exit(`characterReference`),t)}return o(s)&&i++<a?(e.consume(s),u):n(s)}}var yb={partial:!0,tokenize:Sb},bb={concrete:!0,name:`codeFenced`,tokenize:xb};function xb(e,t,n){let r=this,i={partial:!0,tokenize:x},a=0,o=0,s;return c;function c(e){return l(e)}function l(t){let n=r.events[r.events.length-1];return a=n&&n[1].type===`linePrefix`?n[2].sliceSerialize(n[1],!0).length:0,s=t,e.enter(`codeFenced`),e.enter(`codeFencedFence`),e.enter(`codeFencedFenceSequence`),u(t)}function u(t){return t===s?(o++,e.consume(t),u):o<3?n(t):(e.exit(`codeFencedFenceSequence`),Q(t)?$(e,d,`whitespace`)(t):d(t))}function d(n){return n===null||Z(n)?(e.exit(`codeFencedFence`),r.interrupt?t(n):e.check(yb,h,b)(n)):(e.enter(`codeFencedFenceInfo`),e.enter(`chunkString`,{contentType:`string`}),f(n))}function f(t){return t===null||Z(t)?(e.exit(`chunkString`),e.exit(`codeFencedFenceInfo`),d(t)):Q(t)?(e.exit(`chunkString`),e.exit(`codeFencedFenceInfo`),$(e,p,`whitespace`)(t)):t===96&&t===s?n(t):(e.consume(t),f)}function p(t){return t===null||Z(t)?d(t):(e.enter(`codeFencedFenceMeta`),e.enter(`chunkString`,{contentType:`string`}),m(t))}function m(t){return t===null||Z(t)?(e.exit(`chunkString`),e.exit(`codeFencedFenceMeta`),d(t)):t===96&&t===s?n(t):(e.consume(t),m)}function h(t){return e.attempt(i,b,g)(t)}function g(t){return e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),_}function _(t){return a>0&&Q(t)?$(e,v,`linePrefix`,a+1)(t):v(t)}function v(t){return t===null||Z(t)?e.check(yb,h,b)(t):(e.enter(`codeFlowValue`),y(t))}function y(t){return t===null||Z(t)?(e.exit(`codeFlowValue`),v(t)):(e.consume(t),y)}function b(n){return e.exit(`codeFenced`),t(n)}function x(e,t,n){let i=0;return a;function a(t){return e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),c}function c(t){return e.enter(`codeFencedFence`),Q(t)?$(e,l,`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(t):l(t)}function l(t){return t===s?(e.enter(`codeFencedFenceSequence`),u(t)):n(t)}function u(t){return t===s?(i++,e.consume(t),u):i>=o?(e.exit(`codeFencedFenceSequence`),Q(t)?$(e,d,`whitespace`)(t):d(t)):n(t)}function d(r){return r===null||Z(r)?(e.exit(`codeFencedFence`),t(r)):n(r)}}}function Sb(e,t,n){let r=this;return i;function i(t){return t===null?n(t):(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),a)}function a(e){return r.parser.lazy[r.now().line]?n(e):t(e)}}var Cb={name:`codeIndented`,tokenize:Tb},wb={partial:!0,tokenize:Eb};function Tb(e,t,n){let r=this;return i;function i(t){return e.enter(`codeIndented`),$(e,a,`linePrefix`,5)(t)}function a(e){let t=r.events[r.events.length-1];return t&&t[1].type===`linePrefix`&&t[2].sliceSerialize(t[1],!0).length>=4?o(e):n(e)}function o(t){return t===null?c(t):Z(t)?e.attempt(wb,o,c)(t):(e.enter(`codeFlowValue`),s(t))}function s(t){return t===null||Z(t)?(e.exit(`codeFlowValue`),o(t)):(e.consume(t),s)}function c(n){return e.exit(`codeIndented`),t(n)}}function Eb(e,t,n){let r=this;return i;function i(t){return r.parser.lazy[r.now().line]?n(t):Z(t)?(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),i):$(e,a,`linePrefix`,5)(t)}function a(e){let a=r.events[r.events.length-1];return a&&a[1].type===`linePrefix`&&a[2].sliceSerialize(a[1],!0).length>=4?t(e):Z(e)?i(e):n(e)}}var Db={name:`codeText`,previous:kb,resolve:Ob,tokenize:Ab};function Ob(e){let t=e.length-4,n=3,r,i;if((e[n][1].type===`lineEnding`||e[n][1].type===`space`)&&(e[t][1].type===`lineEnding`||e[t][1].type===`space`)){for(r=n;++r<t;)if(e[r][1].type===`codeTextData`){e[n][1].type=`codeTextPadding`,e[t][1].type=`codeTextPadding`,n+=2,t-=2;break}}for(r=n-1,t++;++r<=t;)i===void 0?r!==t&&e[r][1].type!==`lineEnding`&&(i=r):(r===t||e[r][1].type===`lineEnding`)&&(e[i][1].type=`codeTextData`,r!==i+2&&(e[i][1].end=e[r-1][1].end,e.splice(i+2,r-i-2),t-=r-i-2,r=i+2),i=void 0);return e}function kb(e){return e!==96||this.events[this.events.length-1][1].type===`characterEscape`}function Ab(e,t,n){let r=0,i,a;return o;function o(t){return e.enter(`codeText`),e.enter(`codeTextSequence`),s(t)}function s(t){return t===96?(e.consume(t),r++,s):(e.exit(`codeTextSequence`),c(t))}function c(t){return t===null?n(t):t===32?(e.enter(`space`),e.consume(t),e.exit(`space`),c):t===96?(a=e.enter(`codeTextSequence`),i=0,u(t)):Z(t)?(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),c):(e.enter(`codeTextData`),l(t))}function l(t){return t===null||t===32||t===96||Z(t)?(e.exit(`codeTextData`),c(t)):(e.consume(t),l)}function u(n){return n===96?(e.consume(n),i++,u):i===r?(e.exit(`codeTextSequence`),e.exit(`codeText`),t(n)):(a.type=`codeTextData`,l(n))}}var jb=class{constructor(e){this.left=e?[...e]:[],this.right=[]}get(e){if(e<0||e>=this.left.length+this.right.length)throw RangeError("Cannot access index `"+e+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return e<this.left.length?this.left[e]:this.right[this.right.length-e+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(e,t){let n=t??1/0;return n<this.left.length?this.left.slice(e,n):e>this.left.length?this.right.slice(this.right.length-n+this.left.length,this.right.length-e+this.left.length).reverse():this.left.slice(e).concat(this.right.slice(this.right.length-n+this.left.length).reverse())}splice(e,t,n){let r=t||0;this.setCursor(Math.trunc(e));let i=this.right.splice(this.right.length-r,1/0);return n&&Mb(this.left,n),i.reverse()}pop(){return this.setCursor(1/0),this.left.pop()}push(e){this.setCursor(1/0),this.left.push(e)}pushMany(e){this.setCursor(1/0),Mb(this.left,e)}unshift(e){this.setCursor(0),this.right.push(e)}unshiftMany(e){this.setCursor(0),Mb(this.right,e.reverse())}setCursor(e){if(!(e===this.left.length||e>this.left.length&&this.right.length===0||e<0&&this.left.length===0)){if(e<this.left.length){let t=this.left.splice(e,1/0);Mb(this.right,t.reverse())}else{let t=this.right.splice(this.left.length+this.right.length-e,1/0);Mb(this.left,t.reverse())}}}};function Mb(e,t){let n=0;if(t.length<1e4)e.push(...t);else for(;n<t.length;)e.push(...t.slice(n,n+1e4)),n+=1e4}function Nb(e){let t={},n=-1,r,i,a,o,s,c,l,u=new jb(e);for(;++n<u.length;){for(;n in t;)n=t[n];if(r=u.get(n),n&&r[1].type===`chunkFlow`&&u.get(n-1)[1].type===`listItemPrefix`&&(c=r[1]._tokenizer.events,a=0,a<c.length&&c[a][1].type===`lineEndingBlank`&&(a+=2),a<c.length&&c[a][1].type===`content`))for(;++a<c.length&&c[a][1].type!==`content`;)c[a][1].type===`chunkText`&&(c[a][1]._isInFirstContentOfListItem=!0,a++);if(r[0]===`enter`)r[1].contentType&&(Object.assign(t,Pb(u,n)),n=t[n],l=!0);else if(r[1]._container){for(a=n,i=void 0;a--;)if(o=u.get(a),o[1].type===`lineEnding`||o[1].type===`lineEndingBlank`)o[0]===`enter`&&(i&&(u.get(i)[1].type=`lineEndingBlank`),o[1].type=`lineEnding`,i=a);else if(o[1].type!==`linePrefix`&&o[1].type!==`listItemIndent`)break;i&&(r[1].end={...u.get(i)[1].start},s=u.slice(i,n),s.unshift(r),u.splice(i,n-i+1,s))}}return ky(e,0,1/0,u.slice(0)),!l}function Pb(e,t){let n=e.get(t)[1],r=e.get(t)[2],i=t-1,a=[],o=n._tokenizer;o||(o=r.parser[n.contentType](n.start),n._contentTypeTextTrailing&&(o._contentTypeTextTrailing=!0));let s=o.events,c=[],l={},u,d,f=-1,p=n,m=0,h=0,g=[h];for(;p;){for(;e.get(++i)[1]!==p;);a.push(i),p._tokenizer||(u=r.sliceStream(p),p.next||u.push(null),d&&o.defineSkip(p.start),p._isInFirstContentOfListItem&&(o._gfmTasklistFirstContentOfListItem=!0),o.write(u),p._isInFirstContentOfListItem&&(o._gfmTasklistFirstContentOfListItem=void 0)),d=p,p=p.next}for(p=n;++f<s.length;)s[f][0]===`exit`&&s[f-1][0]===`enter`&&s[f][1].type===s[f-1][1].type&&s[f][1].start.line!==s[f][1].end.line&&(h=f+1,g.push(h),p._tokenizer=void 0,p.previous=void 0,p=p.next);for(o.events=[],p?(p._tokenizer=void 0,p.previous=void 0):g.pop(),f=g.length;f--;){let t=s.slice(g[f],g[f+1]),n=a.pop();c.push([n,n+t.length-1]),e.splice(n,2,t)}for(c.reverse(),f=-1;++f<c.length;)l[m+c[f][0]]=m+c[f][1],m+=c[f][1]-c[f][0]-1;return l}var Fb={resolve:Lb,tokenize:Rb},Ib={partial:!0,tokenize:zb};function Lb(e){return Nb(e),e}function Rb(e,t){let n;return r;function r(t){return e.enter(`content`),n=e.enter(`chunkContent`,{contentType:`content`}),i(t)}function i(t){return t===null?a(t):Z(t)?e.check(Ib,o,a)(t):(e.consume(t),i)}function a(n){return e.exit(`chunkContent`),e.exit(`content`),t(n)}function o(t){return e.consume(t),e.exit(`chunkContent`),n.next=e.enter(`chunkContent`,{contentType:`content`,previous:n}),n=n.next,i}}function zb(e,t,n){let r=this;return i;function i(t){return e.exit(`chunkContent`),e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),$(e,a,`linePrefix`)}function a(i){if(i===null||Z(i))return n(i);let a=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes(`codeIndented`)&&a&&a[1].type===`linePrefix`&&a[2].sliceSerialize(a[1],!0).length>=4?t(i):e.interrupt(r.parser.constructs.flow,n,t)(i)}}function Bb(e,t,n,r,i,a,o,s,c){let l=c||1/0,u=0;return d;function d(t){return t===60?(e.enter(r),e.enter(i),e.enter(a),e.consume(t),e.exit(a),f):t===null||t===32||t===41||By(t)?n(t):(e.enter(r),e.enter(o),e.enter(s),e.enter(`chunkString`,{contentType:`string`}),h(t))}function f(n){return n===62?(e.enter(a),e.consume(n),e.exit(a),e.exit(i),e.exit(r),t):(e.enter(s),e.enter(`chunkString`,{contentType:`string`}),p(n))}function p(t){return t===62?(e.exit(`chunkString`),e.exit(s),f(t)):t===null||t===60||Z(t)?n(t):(e.consume(t),t===92?m:p)}function m(t){return t===60||t===62||t===92?(e.consume(t),p):p(t)}function h(i){return!u&&(i===null||i===41||Wy(i))?(e.exit(`chunkString`),e.exit(s),e.exit(o),e.exit(r),t(i)):u<l&&i===40?(e.consume(i),u++,h):i===41?(e.consume(i),u--,h):i===null||i===32||i===40||By(i)?n(i):(e.consume(i),i===92?g:h)}function g(t){return t===40||t===41||t===92?(e.consume(t),h):h(t)}}function Vb(e,t,n,r,i,a){let o=this,s=0,c;return l;function l(t){return e.enter(r),e.enter(i),e.consume(t),e.exit(i),e.enter(a),u}function u(l){return s>999||l===null||l===91||l===93&&!c||l===94&&!s&&`_hiddenFootnoteSupport`in o.parser.constructs?n(l):l===93?(e.exit(a),e.enter(i),e.consume(l),e.exit(i),e.exit(r),t):Z(l)?(e.enter(`lineEnding`),e.consume(l),e.exit(`lineEnding`),u):(e.enter(`chunkString`,{contentType:`string`}),d(l))}function d(t){return t===null||t===91||t===93||Z(t)||s++>999?(e.exit(`chunkString`),u(t)):(e.consume(t),c||=!Q(t),t===92?f:d)}function f(t){return t===91||t===92||t===93?(e.consume(t),s++,d):d(t)}}function Hb(e,t,n,r,i,a){let o;return s;function s(t){return t===34||t===39||t===40?(e.enter(r),e.enter(i),e.consume(t),e.exit(i),o=t===40?41:t,c):n(t)}function c(n){return n===o?(e.enter(i),e.consume(n),e.exit(i),e.exit(r),t):(e.enter(a),l(n))}function l(t){return t===o?(e.exit(a),c(o)):t===null?n(t):Z(t)?(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),$(e,l,`linePrefix`)):(e.enter(`chunkString`,{contentType:`string`}),u(t))}function u(t){return t===o||t===null||Z(t)?(e.exit(`chunkString`),l(t)):(e.consume(t),t===92?d:u)}function d(t){return t===o||t===92?(e.consume(t),u):u(t)}}function Ub(e,t){let n;return r;function r(i){return Z(i)?(e.enter(`lineEnding`),e.consume(i),e.exit(`lineEnding`),n=!0,r):Q(i)?$(e,r,n?`linePrefix`:`lineSuffix`)(i):t(i)}}var Wb={name:`definition`,tokenize:Kb},Gb={partial:!0,tokenize:qb};function Kb(e,t,n){let r=this,i;return a;function a(t){return e.enter(`definition`),o(t)}function o(t){return Vb.call(r,e,s,n,`definitionLabel`,`definitionLabelMarker`,`definitionLabelString`)(t)}function s(t){return i=Iy(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),t===58?(e.enter(`definitionMarker`),e.consume(t),e.exit(`definitionMarker`),c):n(t)}function c(t){return Wy(t)?Ub(e,l)(t):l(t)}function l(t){return Bb(e,u,n,`definitionDestination`,`definitionDestinationLiteral`,`definitionDestinationLiteralMarker`,`definitionDestinationRaw`,`definitionDestinationString`)(t)}function u(t){return e.attempt(Gb,d,d)(t)}function d(t){return Q(t)?$(e,f,`whitespace`)(t):f(t)}function f(a){return a===null||Z(a)?(e.exit(`definition`),r.parser.defined.push(i),t(a)):n(a)}}function qb(e,t,n){return r;function r(t){return Wy(t)?Ub(e,i)(t):n(t)}function i(t){return Hb(e,a,n,`definitionTitle`,`definitionTitleMarker`,`definitionTitleString`)(t)}function a(t){return Q(t)?$(e,o,`whitespace`)(t):o(t)}function o(e){return e===null||Z(e)?t(e):n(e)}}var Jb={name:`hardBreakEscape`,tokenize:Yb};function Yb(e,t,n){return r;function r(t){return e.enter(`hardBreakEscape`),e.consume(t),i}function i(r){return Z(r)?(e.exit(`hardBreakEscape`),t(r)):n(r)}}var Xb={name:`headingAtx`,resolve:Zb,tokenize:Qb};function Zb(e,t){let n=e.length-2,r=3,i,a;return e[r][1].type===`whitespace`&&(r+=2),n-2>r&&e[n][1].type===`whitespace`&&(n-=2),e[n][1].type===`atxHeadingSequence`&&(r===n-1||n-4>r&&e[n-2][1].type===`whitespace`)&&(n-=r+1===n?2:4),n>r&&(i={type:`atxHeadingText`,start:e[r][1].start,end:e[n][1].end},a={type:`chunkText`,start:e[r][1].start,end:e[n][1].end,contentType:`text`},ky(e,r,n-r+1,[[`enter`,i,t],[`enter`,a,t],[`exit`,a,t],[`exit`,i,t]])),e}function Qb(e,t,n){let r=0;return i;function i(t){return e.enter(`atxHeading`),a(t)}function a(t){return e.enter(`atxHeadingSequence`),o(t)}function o(t){return t===35&&r++<6?(e.consume(t),o):t===null||Wy(t)?(e.exit(`atxHeadingSequence`),s(t)):n(t)}function s(n){return n===35?(e.enter(`atxHeadingSequence`),c(n)):n===null||Z(n)?(e.exit(`atxHeading`),t(n)):Q(n)?$(e,s,`whitespace`)(n):(e.enter(`atxHeadingText`),l(n))}function c(t){return t===35?(e.consume(t),c):(e.exit(`atxHeadingSequence`),s(t))}function l(t){return t===null||t===35||Wy(t)?(e.exit(`atxHeadingText`),s(t)):(e.consume(t),l)}}var $b=`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(`.`),ex=[`pre`,`script`,`style`,`textarea`],tx={concrete:!0,name:`htmlFlow`,resolveTo:ix,tokenize:ax},nx={partial:!0,tokenize:sx},rx={partial:!0,tokenize:ox};function ix(e){let t=e.length;for(;t--&&(e[t][0]!==`enter`||e[t][1].type!==`htmlFlow`););return t>1&&e[t-2][1].type===`linePrefix`&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function ax(e,t,n){let r=this,i,a,o,s,c;return l;function l(e){return u(e)}function u(t){return e.enter(`htmlFlow`),e.enter(`htmlFlowData`),e.consume(t),d}function d(s){return s===33?(e.consume(s),f):s===47?(e.consume(s),a=!0,h):s===63?(e.consume(s),i=3,r.interrupt?t:k):Ly(s)?(e.consume(s),o=String.fromCharCode(s),g):n(s)}function f(a){return a===45?(e.consume(a),i=2,p):a===91?(e.consume(a),i=5,s=0,m):Ly(a)?(e.consume(a),i=4,r.interrupt?t:k):n(a)}function p(i){return i===45?(e.consume(i),r.interrupt?t:k):n(i)}function m(i){return i===`CDATA[`.charCodeAt(s++)?(e.consume(i),s===6?r.interrupt?t:D:m):n(i)}function h(t){return Ly(t)?(e.consume(t),o=String.fromCharCode(t),g):n(t)}function g(s){if(s===null||s===47||s===62||Wy(s)){let c=s===47,l=o.toLowerCase();return!c&&!a&&ex.includes(l)?(i=1,r.interrupt?t(s):D(s)):$b.includes(o.toLowerCase())?(i=6,c?(e.consume(s),_):r.interrupt?t(s):D(s)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(s):a?v(s):y(s))}return s===45||Ry(s)?(e.consume(s),o+=String.fromCharCode(s),g):n(s)}function _(i){return i===62?(e.consume(i),r.interrupt?t:D):n(i)}function v(t){return Q(t)?(e.consume(t),v):E(t)}function y(t){return t===47?(e.consume(t),E):t===58||t===95||Ly(t)?(e.consume(t),b):Q(t)?(e.consume(t),y):E(t)}function b(t){return t===45||t===46||t===58||t===95||Ry(t)?(e.consume(t),b):x(t)}function x(t){return t===61?(e.consume(t),S):Q(t)?(e.consume(t),x):y(t)}function S(t){return t===null||t===60||t===61||t===62||t===96?n(t):t===34||t===39?(e.consume(t),c=t,C):Q(t)?(e.consume(t),S):w(t)}function C(t){return t===c?(e.consume(t),c=null,T):t===null||Z(t)?n(t):(e.consume(t),C)}function w(t){return t===null||t===34||t===39||t===47||t===60||t===61||t===62||t===96||Wy(t)?x(t):(e.consume(t),w)}function T(e){return e===47||e===62||Q(e)?y(e):n(e)}function E(t){return t===62?(e.consume(t),ee):n(t)}function ee(t){return t===null||Z(t)?D(t):Q(t)?(e.consume(t),ee):n(t)}function D(t){return t===45&&i===2?(e.consume(t),re):t===60&&i===1?(e.consume(t),ie):t===62&&i===4?(e.consume(t),A):t===63&&i===3?(e.consume(t),k):t===93&&i===5?(e.consume(t),oe):Z(t)&&(i===6||i===7)?(e.exit(`htmlFlowData`),e.check(nx,se,O)(t)):t===null||Z(t)?(e.exit(`htmlFlowData`),O(t)):(e.consume(t),D)}function O(t){return e.check(rx,te,se)(t)}function te(t){return e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),ne}function ne(t){return t===null||Z(t)?O(t):(e.enter(`htmlFlowData`),D(t))}function re(t){return t===45?(e.consume(t),k):D(t)}function ie(t){return t===47?(e.consume(t),o=``,ae):D(t)}function ae(t){if(t===62){let n=o.toLowerCase();return ex.includes(n)?(e.consume(t),A):D(t)}return Ly(t)&&o.length<8?(e.consume(t),o+=String.fromCharCode(t),ae):D(t)}function oe(t){return t===93?(e.consume(t),k):D(t)}function k(t){return t===62?(e.consume(t),A):t===45&&i===2?(e.consume(t),k):D(t)}function A(t){return t===null||Z(t)?(e.exit(`htmlFlowData`),se(t)):(e.consume(t),A)}function se(n){return e.exit(`htmlFlow`),t(n)}}function ox(e,t,n){let r=this;return i;function i(t){return Z(t)?(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),a):n(t)}function a(e){return r.parser.lazy[r.now().line]?n(e):t(e)}}function sx(e,t,n){return r;function r(r){return e.enter(`lineEnding`),e.consume(r),e.exit(`lineEnding`),e.attempt(lb,t,n)}}var cx={name:`htmlText`,tokenize:lx};function lx(e,t,n){let r=this,i,a,o;return s;function s(t){return e.enter(`htmlText`),e.enter(`htmlTextData`),e.consume(t),c}function c(t){return t===33?(e.consume(t),l):t===47?(e.consume(t),x):t===63?(e.consume(t),y):Ly(t)?(e.consume(t),w):n(t)}function l(t){return t===45?(e.consume(t),u):t===91?(e.consume(t),a=0,m):Ly(t)?(e.consume(t),v):n(t)}function u(t){return t===45?(e.consume(t),p):n(t)}function d(t){return t===null?n(t):t===45?(e.consume(t),f):Z(t)?(o=d,ie(t)):(e.consume(t),d)}function f(t){return t===45?(e.consume(t),p):d(t)}function p(e){return e===62?re(e):e===45?f(e):d(e)}function m(t){return t===`CDATA[`.charCodeAt(a++)?(e.consume(t),a===6?h:m):n(t)}function h(t){return t===null?n(t):t===93?(e.consume(t),g):Z(t)?(o=h,ie(t)):(e.consume(t),h)}function g(t){return t===93?(e.consume(t),_):h(t)}function _(t){return t===62?re(t):t===93?(e.consume(t),_):h(t)}function v(t){return t===null||t===62?re(t):Z(t)?(o=v,ie(t)):(e.consume(t),v)}function y(t){return t===null?n(t):t===63?(e.consume(t),b):Z(t)?(o=y,ie(t)):(e.consume(t),y)}function b(e){return e===62?re(e):y(e)}function x(t){return Ly(t)?(e.consume(t),S):n(t)}function S(t){return t===45||Ry(t)?(e.consume(t),S):C(t)}function C(t){return Z(t)?(o=C,ie(t)):Q(t)?(e.consume(t),C):re(t)}function w(t){return t===45||Ry(t)?(e.consume(t),w):t===47||t===62||Wy(t)?T(t):n(t)}function T(t){return t===47?(e.consume(t),re):t===58||t===95||Ly(t)?(e.consume(t),E):Z(t)?(o=T,ie(t)):Q(t)?(e.consume(t),T):re(t)}function E(t){return t===45||t===46||t===58||t===95||Ry(t)?(e.consume(t),E):ee(t)}function ee(t){return t===61?(e.consume(t),D):Z(t)?(o=ee,ie(t)):Q(t)?(e.consume(t),ee):T(t)}function D(t){return t===null||t===60||t===61||t===62||t===96?n(t):t===34||t===39?(e.consume(t),i=t,O):Z(t)?(o=D,ie(t)):Q(t)?(e.consume(t),D):(e.consume(t),te)}function O(t){return t===i?(e.consume(t),i=void 0,ne):t===null?n(t):Z(t)?(o=O,ie(t)):(e.consume(t),O)}function te(t){return t===null||t===34||t===39||t===60||t===61||t===96?n(t):t===47||t===62||Wy(t)?T(t):(e.consume(t),te)}function ne(e){return e===47||e===62||Wy(e)?T(e):n(e)}function re(r){return r===62?(e.consume(r),e.exit(`htmlTextData`),e.exit(`htmlText`),t):n(r)}function ie(t){return e.exit(`htmlTextData`),e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),ae}function ae(t){return Q(t)?$(e,oe,`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(t):oe(t)}function oe(t){return e.enter(`htmlTextData`),o(t)}}var ux={name:`labelEnd`,resolveAll:mx,resolveTo:hx,tokenize:gx},dx={tokenize:_x},fx={tokenize:vx},px={tokenize:yx};function mx(e){let t=-1,n=[];for(;++t<e.length;){let r=e[t][1];if(n.push(e[t]),r.type===`labelImage`||r.type===`labelLink`||r.type===`labelEnd`){let e=r.type===`labelImage`?4:2;r.type=`data`,t+=e}}return e.length!==n.length&&ky(e,0,e.length,n),e}function hx(e,t){let n=e.length,r=0,i,a,o,s;for(;n--;)if(i=e[n][1],a){if(i.type===`link`||i.type===`labelLink`&&i._inactive)break;e[n][0]===`enter`&&i.type===`labelLink`&&(i._inactive=!0)}else if(o){if(e[n][0]===`enter`&&(i.type===`labelImage`||i.type===`labelLink`)&&!i._balanced&&(a=n,i.type!==`labelLink`)){r=2;break}}else i.type===`labelEnd`&&(o=n);let c={type:e[a][1].type===`labelLink`?`link`:`image`,start:{...e[a][1].start},end:{...e[e.length-1][1].end}},l={type:`label`,start:{...e[a][1].start},end:{...e[o][1].end}},u={type:`labelText`,start:{...e[a+r+2][1].end},end:{...e[o-2][1].start}};return s=[[`enter`,c,t],[`enter`,l,t]],s=Ay(s,e.slice(a+1,a+r+3)),s=Ay(s,[[`enter`,u,t]]),s=Ay(s,nb(t.parser.constructs.insideSpan.null,e.slice(a+r+4,o-3),t)),s=Ay(s,[[`exit`,u,t],e[o-2],e[o-1],[`exit`,l,t]]),s=Ay(s,e.slice(o+1)),s=Ay(s,[[`exit`,c,t]]),ky(e,a,e.length,s),e}function gx(e,t,n){let r=this,i=r.events.length,a,o;for(;i--;)if((r.events[i][1].type===`labelImage`||r.events[i][1].type===`labelLink`)&&!r.events[i][1]._balanced){a=r.events[i][1];break}return s;function s(t){return a?a._inactive?d(t):(o=r.parser.defined.includes(Iy(r.sliceSerialize({start:a.end,end:r.now()}))),e.enter(`labelEnd`),e.enter(`labelMarker`),e.consume(t),e.exit(`labelMarker`),e.exit(`labelEnd`),c):n(t)}function c(t){return t===40?e.attempt(dx,u,o?u:d)(t):t===91?e.attempt(fx,u,o?l:d)(t):o?u(t):d(t)}function l(t){return e.attempt(px,u,d)(t)}function u(e){return t(e)}function d(e){return a._balanced=!0,n(e)}}function _x(e,t,n){return r;function r(t){return e.enter(`resource`),e.enter(`resourceMarker`),e.consume(t),e.exit(`resourceMarker`),i}function i(t){return Wy(t)?Ub(e,a)(t):a(t)}function a(t){return t===41?u(t):Bb(e,o,s,`resourceDestination`,`resourceDestinationLiteral`,`resourceDestinationLiteralMarker`,`resourceDestinationRaw`,`resourceDestinationString`,32)(t)}function o(t){return Wy(t)?Ub(e,c)(t):u(t)}function s(e){return n(e)}function c(t){return t===34||t===39||t===40?Hb(e,l,n,`resourceTitle`,`resourceTitleMarker`,`resourceTitleString`)(t):u(t)}function l(t){return Wy(t)?Ub(e,u)(t):u(t)}function u(r){return r===41?(e.enter(`resourceMarker`),e.consume(r),e.exit(`resourceMarker`),e.exit(`resource`),t):n(r)}}function vx(e,t,n){let r=this;return i;function i(t){return Vb.call(r,e,a,o,`reference`,`referenceMarker`,`referenceString`)(t)}function a(e){return r.parser.defined.includes(Iy(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(e):n(e)}function o(e){return n(e)}}function yx(e,t,n){return r;function r(t){return e.enter(`reference`),e.enter(`referenceMarker`),e.consume(t),e.exit(`referenceMarker`),i}function i(r){return r===93?(e.enter(`referenceMarker`),e.consume(r),e.exit(`referenceMarker`),e.exit(`reference`),t):n(r)}}var bx={name:`labelStartImage`,resolveAll:ux.resolveAll,tokenize:xx};function xx(e,t,n){let r=this;return i;function i(t){return e.enter(`labelImage`),e.enter(`labelImageMarker`),e.consume(t),e.exit(`labelImageMarker`),a}function a(t){return t===91?(e.enter(`labelMarker`),e.consume(t),e.exit(`labelMarker`),e.exit(`labelImage`),o):n(t)}function o(e){return e===94&&`_hiddenFootnoteSupport`in r.parser.constructs?n(e):t(e)}}var Sx={name:`labelStartLink`,resolveAll:ux.resolveAll,tokenize:Cx};function Cx(e,t,n){let r=this;return i;function i(t){return e.enter(`labelLink`),e.enter(`labelMarker`),e.consume(t),e.exit(`labelMarker`),e.exit(`labelLink`),a}function a(e){return e===94&&`_hiddenFootnoteSupport`in r.parser.constructs?n(e):t(e)}}var wx={name:`lineEnding`,tokenize:Tx};function Tx(e,t){return n;function n(n){return e.enter(`lineEnding`),e.consume(n),e.exit(`lineEnding`),$(e,t,`linePrefix`)}}var Ex={name:`thematicBreak`,tokenize:Dx};function Dx(e,t,n){let r=0,i;return a;function a(t){return e.enter(`thematicBreak`),o(t)}function o(e){return i=e,s(e)}function s(a){return a===i?(e.enter(`thematicBreakSequence`),c(a)):r>=3&&(a===null||Z(a))?(e.exit(`thematicBreak`),t(a)):n(a)}function c(t){return t===i?(e.consume(t),r++,c):(e.exit(`thematicBreakSequence`),Q(t)?$(e,s,`whitespace`)(t):s(t))}}var Ox={continuation:{tokenize:Mx},exit:Px,name:`list`,tokenize:jx},kx={partial:!0,tokenize:Fx},Ax={partial:!0,tokenize:Nx};function jx(e,t,n){let r=this,i=r.events[r.events.length-1],a=i&&i[1].type===`linePrefix`?i[2].sliceSerialize(i[1],!0).length:0,o=0;return s;function s(t){let i=r.containerState.type||(t===42||t===43||t===45?`listUnordered`:`listOrdered`);if(i===`listUnordered`?!r.containerState.marker||t===r.containerState.marker:Vy(t)){if(r.containerState.type||(r.containerState.type=i,e.enter(i,{_container:!0})),i===`listUnordered`)return e.enter(`listItemPrefix`),t===42||t===45?e.check(Ex,n,l)(t):l(t);if(!r.interrupt||t===49)return e.enter(`listItemPrefix`),e.enter(`listItemValue`),c(t)}return n(t)}function c(t){return Vy(t)&&++o<10?(e.consume(t),c):(!r.interrupt||o<2)&&(r.containerState.marker?t===r.containerState.marker:t===41||t===46)?(e.exit(`listItemValue`),l(t)):n(t)}function l(t){return e.enter(`listItemMarker`),e.consume(t),e.exit(`listItemMarker`),r.containerState.marker=r.containerState.marker||t,e.check(lb,r.interrupt?n:u,e.attempt(kx,f,d))}function u(e){return r.containerState.initialBlankLine=!0,a++,f(e)}function d(t){return Q(t)?(e.enter(`listItemPrefixWhitespace`),e.consume(t),e.exit(`listItemPrefixWhitespace`),f):n(t)}function f(n){return r.containerState.size=a+r.sliceSerialize(e.exit(`listItemPrefix`),!0).length,t(n)}}function Mx(e,t,n){let r=this;return r.containerState._closeFlow=void 0,e.check(lb,i,a);function i(n){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,$(e,t,`listItemIndent`,r.containerState.size+1)(n)}function a(n){return r.containerState.furtherBlankLines||!Q(n)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,o(n)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(Ax,t,o)(n))}function o(i){return r.containerState._closeFlow=!0,r.interrupt=void 0,$(e,e.attempt(Ox,t,n),`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(i)}}function Nx(e,t,n){let r=this;return $(e,i,`listItemIndent`,r.containerState.size+1);function i(e){let i=r.events[r.events.length-1];return i&&i[1].type===`listItemIndent`&&i[2].sliceSerialize(i[1],!0).length===r.containerState.size?t(e):n(e)}}function Px(e){e.exit(this.containerState.type)}function Fx(e,t,n){let r=this;return $(e,i,`listItemPrefixWhitespace`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:5);function i(e){let i=r.events[r.events.length-1];return!Q(e)&&i&&i[1].type===`listItemPrefixWhitespace`?t(e):n(e)}}var Ix={name:`setextUnderline`,resolveTo:Lx,tokenize:Rx};function Lx(e,t){let n=e.length,r,i,a;for(;n--;)if(e[n][0]===`enter`){if(e[n][1].type===`content`){r=n;break}e[n][1].type===`paragraph`&&(i=n)}else e[n][1].type===`content`&&e.splice(n,1),!a&&e[n][1].type===`definition`&&(a=n);let o={type:`setextHeading`,start:{...e[r][1].start},end:{...e[e.length-1][1].end}};return e[i][1].type=`setextHeadingText`,a?(e.splice(i,0,[`enter`,o,t]),e.splice(a+1,0,[`exit`,e[r][1],t]),e[r][1].end={...e[a][1].end}):e[r][1]=o,e.push([`exit`,o,t]),e}function Rx(e,t,n){let r=this,i;return a;function a(t){let a=r.events.length,s;for(;a--;)if(r.events[a][1].type!==`lineEnding`&&r.events[a][1].type!==`linePrefix`&&r.events[a][1].type!==`content`){s=r.events[a][1].type===`paragraph`;break}return!r.parser.lazy[r.now().line]&&(r.interrupt||s)?(e.enter(`setextHeadingLine`),i=t,o(t)):n(t)}function o(t){return e.enter(`setextHeadingLineSequence`),s(t)}function s(t){return t===i?(e.consume(t),s):(e.exit(`setextHeadingLineSequence`),Q(t)?$(e,c,`lineSuffix`)(t):c(t))}function c(r){return r===null||Z(r)?(e.exit(`setextHeadingLine`),t(r)):n(r)}}var zx={tokenize:Bx};function Bx(e){let t=this,n=e.attempt(lb,r,e.attempt(this.parser.constructs.flowInitial,i,$(e,e.attempt(this.parser.constructs.flow,i,e.attempt(Fb,i)),`linePrefix`)));return n;function r(r){if(r===null){e.consume(r);return}return e.enter(`lineEndingBlank`),e.consume(r),e.exit(`lineEndingBlank`),t.currentConstruct=void 0,n}function i(r){if(r===null){e.consume(r);return}return e.enter(`lineEnding`),e.consume(r),e.exit(`lineEnding`),t.currentConstruct=void 0,n}}var Vx={resolveAll:Gx()},Hx=Wx(`string`),Ux=Wx(`text`);function Wx(e){return{resolveAll:Gx(e===`text`?Kx:void 0),tokenize:t};function t(t){let n=this,r=this.parser.constructs[e],i=t.attempt(r,a,o);return a;function a(e){return c(e)?i(e):o(e)}function o(e){if(e===null){t.consume(e);return}return t.enter(`data`),t.consume(e),s}function s(e){return c(e)?(t.exit(`data`),i(e)):(t.consume(e),s)}function c(e){if(e===null)return!0;let t=r[e],i=-1;if(t)for(;++i<t.length;){let e=t[i];if(!e.previous||e.previous.call(n,n.previous))return!0}return!1}}}function Gx(e){return t;function t(t,n){let r=-1,i;for(;++r<=t.length;)i===void 0?t[r]&&t[r][1].type===`data`&&(i=r,r++):(!t[r]||t[r][1].type!==`data`)&&(r!==i+2&&(t[i][1].end=t[r-1][1].end,t.splice(i+2,r-i-2),r=i+2),i=void 0);return e?e(t,n):t}}function Kx(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||e[n][1].type===`lineEnding`)&&e[n-1][1].type===`data`){let r=e[n-1][1],i=t.sliceStream(r),a=i.length,o=-1,s=0,c;for(;a--;){let e=i[a];if(typeof e==`string`){for(o=e.length;e.charCodeAt(o-1)===32;)s++,o--;if(o)break;o=-1}else if(e===-2)c=!0,s++;else if(e!==-1){a++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(s=0),s){let i={type:n===e.length||c||s<2?`lineSuffix`:`hardBreakTrailing`,start:{_bufferIndex:a?o:r.start._bufferIndex+o,_index:r.start._index+a,line:r.end.line,column:r.end.column-s,offset:r.end.offset-s},end:{...r.end}};r.end={...i.start},r.start.offset===r.end.offset?Object.assign(r,i):(e.splice(n,0,[`enter`,i,t],[`exit`,i,t]),n+=2)}n++}return e}var qx=s({attentionMarkers:()=>tS,contentInitial:()=>Yx,disable:()=>nS,document:()=>Jx,flow:()=>Zx,flowInitial:()=>Xx,insideSpan:()=>eS,string:()=>Qx,text:()=>$x}),Jx={42:Ox,43:Ox,45:Ox,48:Ox,49:Ox,50:Ox,51:Ox,52:Ox,53:Ox,54:Ox,55:Ox,56:Ox,57:Ox,62:db},Yx={91:Wb},Xx={[-2]:Cb,[-1]:Cb,32:Cb},Zx={35:Xb,42:Ex,45:[Ix,Ex],60:tx,61:Ix,95:Ex,96:bb,126:bb},Qx={38:_b,92:hb},$x={[-5]:wx,[-4]:wx,[-3]:wx,33:bx,38:_b,42:rb,60:[sb,cx],91:Sx,92:[Jb,hb],93:ux,95:rb,96:Db},eS={null:[rb,Vx]},tS={null:[42,95]},nS={null:[]};function rS(e,t,n){let r={_bufferIndex:-1,_index:0,line:n&&n.line||1,column:n&&n.column||1,offset:n&&n.offset||0},i={},a=[],o=[],s=[],c={attempt:C(x),check:C(S),consume:v,enter:y,exit:b,interrupt:C(S,{interrupt:!0})},l={code:null,containerState:{},defineSkip:h,events:[],now:m,parser:e,previous:null,sliceSerialize:f,sliceStream:p,write:d},u=t.tokenize.call(l,c);return t.resolveAll&&a.push(t),l;function d(e){return o=Ay(o,e),g(),o[o.length-1]===null?(w(t,0),l.events=nb(a,l.events,l),l.events):[]}function f(e,t){return aS(p(e),t)}function p(e){return iS(o,e)}function m(){let{_bufferIndex:e,_index:t,line:n,column:i,offset:a}=r;return{_bufferIndex:e,_index:t,line:n,column:i,offset:a}}function h(e){i[e.line]=e.column,E()}function g(){let e;for(;r._index<o.length;){let t=o[r._index];if(typeof t==`string`)for(e=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===e&&r._bufferIndex<t.length;)_(t.charCodeAt(r._bufferIndex));else _(t)}}function _(e){u=u(e)}function v(e){Z(e)?(r.line++,r.column=1,r.offset+=e===-3?2:1,E()):e!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===o[r._index].length&&(r._bufferIndex=-1,r._index++)),l.previous=e}function y(e,t){let n=t||{};return n.type=e,n.start=m(),l.events.push([`enter`,n,l]),s.push(n),n}function b(e){let t=s.pop();return t.end=m(),l.events.push([`exit`,t,l]),t}function x(e,t){w(e,t.from)}function S(e,t){t.restore()}function C(e,t){return n;function n(n,r,i){let a,o,s,u;return Array.isArray(n)?f(n):`tokenize`in n?f([n]):d(n);function d(e){return t;function t(t){let n=t!==null&&e[t],r=t!==null&&e.null;return f([...Array.isArray(n)?n:n?[n]:[],...Array.isArray(r)?r:r?[r]:[]])(t)}}function f(e){return a=e,o=0,e.length===0?i:p(e[o])}function p(e){return n;function n(n){return u=T(),s=e,e.partial||(l.currentConstruct=e),e.name&&l.parser.constructs.disable.null.includes(e.name)?h(n):e.tokenize.call(t?Object.assign(Object.create(l),t):l,c,m,h)(n)}}function m(t){return e(s,u),r}function h(e){return u.restore(),++o<a.length?p(a[o]):i}}}function w(e,t){e.resolveAll&&!a.includes(e)&&a.push(e),e.resolve&&ky(l.events,t,l.events.length-t,e.resolve(l.events.slice(t),l)),e.resolveTo&&(l.events=e.resolveTo(l.events,l))}function T(){let e=m(),t=l.previous,n=l.currentConstruct,i=l.events.length,a=Array.from(s);return{from:i,restore:o};function o(){r=e,l.previous=t,l.currentConstruct=n,l.events.length=i,s=a,E()}}function E(){r.line in i&&r.column<2&&(r.column=i[r.line],r.offset+=i[r.line]-1)}}function iS(e,t){let n=t.start._index,r=t.start._bufferIndex,i=t.end._index,a=t.end._bufferIndex,o;if(n===i)o=[e[n].slice(r,a)];else{if(o=e.slice(n,i),r>-1){let e=o[0];typeof e==`string`?o[0]=e.slice(r):o.shift()}a>0&&o.push(e[i].slice(0,a))}return o}function aS(e,t){let n=-1,r=[],i;for(;++n<e.length;){let a=e[n],o;if(typeof a==`string`)o=a;else switch(a){case-5:o=`\r`;break;case-4:o=`
|
|
1539
1539
|
`;break;case-3:o=`\r
|
|
1540
|
-
`;break;case-2:o=t?` `:` `;break;case-1:if(!t&&i)continue;o=` `;break;default:o=String.fromCharCode(a)}i=a===-2,r.push(o)}return r.join(``)}function aS(e){let t={constructs:jy([Kx,...(e||{}).extensions||[]]),content:n(Jy),defined:[],document:n(Xy),flow:n(Rx),lazy:{},string:n(Vx),text:n(Hx)};return t;function n(e){return n;function n(n){return nS(t,e,n)}}}function oS(e){for(;!Mb(e););return e}var sS=/[\0\t\n\r]/g;function cS(){let e=1,t=``,n=!0,r;return i;function i(i,a,o){let s=[],c,l,u,d,f;for(i=t+(typeof i==`string`?i.toString():new TextDecoder(a||void 0).decode(i)),u=0,t=``,n&&=(i.charCodeAt(0)===65279&&u++,void 0);u<i.length;){if(sS.lastIndex=u,c=sS.exec(i),d=c&&c.index!==void 0?c.index:i.length,f=i.charCodeAt(d),!c){t=i.slice(u);break}if(f===10&&u===d&&r)s.push(-3),r=void 0;else switch(r&&=(s.push(-5),void 0),u<d&&(s.push(i.slice(u,d)),e+=d-u),f){case 0:s.push(65533),e++;break;case 9:for(l=Math.ceil(e/4)*4,s.push(-2);e++<l;)s.push(-1);break;case 10:s.push(-4),e=1;break;default:r=!0,e=1}u=d+1}return o&&(r&&s.push(-5),t&&s.push(t),s.push(null)),s}}var lS=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function uS(e){return e.replace(lS,dS)}function dS(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){let e=n.charCodeAt(1),t=e===120||e===88;return Py(n.slice(t?2:1),t?16:10)}return Dy(n)||e}var fS={}.hasOwnProperty;function pS(e,t,n){return t&&typeof t==`object`&&(n=t,t=void 0),mS(n)(oS(aS(n).document().write(cS()(e,t,!0))))}function mS(e){let t={transforms:[],canContainEols:[`emphasis`,`fragment`,`heading`,`paragraph`,`strong`],enter:{autolink:a(Ce),autolinkProtocol:T,autolinkEmail:T,atxHeading:a(ye),blockQuote:a(me),characterEscape:T,characterReference:T,codeFenced:a(he),codeFencedFenceInfo:o,codeFencedFenceMeta:o,codeIndented:a(he,o),codeText:a(ge,o),codeTextData:T,data:T,codeFlowValue:T,definition:a(_e),definitionDestinationString:o,definitionLabelString:o,definitionTitleString:o,emphasis:a(ve),hardBreakEscape:a(be),hardBreakTrailing:a(be),htmlFlow:a(xe,o),htmlFlowData:T,htmlText:a(xe,o),htmlTextData:T,image:a(Se),label:o,link:a(Ce),listItem:a(Te),listItemValue:f,listOrdered:a(we,d),listUnordered:a(we),paragraph:a(Ee),reference:ce,referenceString:o,resourceDestinationString:o,resourceTitleString:o,setextHeading:a(ye),strong:a(De),thematicBreak:a(ke)},exit:{atxHeading:c(),atxHeadingSequence:x,autolink:c(),autolinkEmail:pe,autolinkProtocol:fe,blockQuote:c(),characterEscapeValue:E,characterReferenceMarkerHexadecimal:ue,characterReferenceMarkerNumeric:ue,characterReferenceValue:de,characterReference:j,codeFenced:c(g),codeFencedFence:h,codeFencedFenceInfo:p,codeFencedFenceMeta:m,codeFlowValue:E,codeIndented:c(_),codeText:c(ne),codeTextData:E,data:E,definition:c(),definitionDestinationString:b,definitionLabelString:v,definitionTitleString:y,emphasis:c(),hardBreakEscape:c(D),hardBreakTrailing:c(D),htmlFlow:c(O),htmlFlowData:E,htmlText:c(te),htmlTextData:E,image:c(ie),label:oe,labelText:ae,lineEnding:ee,link:c(re),listItem:c(),listOrdered:c(),listUnordered:c(),paragraph:c(),referenceString:le,resourceDestinationString:k,resourceTitleString:A,resource:se,setextHeading:c(w),setextHeadingLineSequence:C,setextHeadingText:S,strong:c(),thematicBreak:c()}};gS(t,(e||{}).mdastExtensions||[]);let n={};return r;function r(e){let r={type:`root`,children:[]},a={stack:[r],tokenStack:[],config:t,enter:s,exit:l,buffer:o,resume:u,data:n},c=[],d=-1;for(;++d<e.length;)(e[d][1].type===`listOrdered`||e[d][1].type===`listUnordered`)&&(e[d][0]===`enter`?c.push(d):d=i(e,c.pop(),d));for(d=-1;++d<e.length;){let n=t[e[d][0]];fS.call(n,e[d][1].type)&&n[e[d][1].type].call(Object.assign({sliceSerialize:e[d][2].sliceSerialize},a),e[d][1])}if(a.tokenStack.length>0){let e=a.tokenStack[a.tokenStack.length-1];(e[1]||vS).call(a,void 0,e[0])}for(r.position={start:hS(e.length>0?e[0][1].start:{line:1,column:1,offset:0}),end:hS(e.length>0?e[e.length-2][1].end:{line:1,column:1,offset:0})},d=-1;++d<t.transforms.length;)r=t.transforms[d](r)||r;return r}function i(e,t,n){let r=t-1,i=-1,a=!1,o,s,c,l;for(;++r<=n;){let t=e[r];switch(t[1].type){case`listUnordered`:case`listOrdered`:case`blockQuote`:t[0]===`enter`?i++:i--,l=void 0;break;case`lineEndingBlank`:t[0]===`enter`&&(o&&!l&&!i&&!c&&(c=r),l=void 0);break;case`linePrefix`:case`listItemValue`:case`listItemMarker`:case`listItemPrefix`:case`listItemPrefixWhitespace`:break;default:l=void 0}if(!i&&t[0]===`enter`&&t[1].type===`listItemPrefix`||i===-1&&t[0]===`exit`&&(t[1].type===`listUnordered`||t[1].type===`listOrdered`)){if(o){let i=r;for(s=void 0;i--;){let t=e[i];if(t[1].type===`lineEnding`||t[1].type===`lineEndingBlank`){if(t[0]===`exit`)continue;s&&(e[s][1].type=`lineEndingBlank`,a=!0),t[1].type=`lineEnding`,s=i}else if(t[1].type!==`linePrefix`&&t[1].type!==`blockQuotePrefix`&&t[1].type!==`blockQuotePrefixWhitespace`&&t[1].type!==`blockQuoteMarker`&&t[1].type!==`listItemIndent`)break}c&&(!s||c<s)&&(o._spread=!0),o.end=Object.assign({},s?e[s][1].start:t[1].end),e.splice(s||r,0,[`exit`,o,t[2]]),r++,n++}if(t[1].type===`listItemPrefix`){let i={type:`listItem`,_spread:!1,start:Object.assign({},t[1].start),end:void 0};o=i,e.splice(r,0,[`enter`,i,t[2]]),r++,n++,c=void 0,l=!0}}}return e[t][1]._spread=a,n}function a(e,t){return n;function n(n){s.call(this,e(n),n),t&&t.call(this,n)}}function o(){this.stack.push({type:`fragment`,children:[]})}function s(e,t,n){this.stack[this.stack.length-1].children.push(e),this.stack.push(e),this.tokenStack.push([t,n||void 0]),e.position={start:hS(t.start),end:void 0}}function c(e){return t;function t(t){e&&e.call(this,t),l.call(this,t)}}function l(e,t){let n=this.stack.pop(),r=this.tokenStack.pop();if(r)r[0].type!==e.type&&(t?t.call(this,e,r[0]):(r[1]||vS).call(this,e,r[0]));else throw Error("Cannot close `"+e.type+"` ("+Bv({start:e.start,end:e.end})+`): it’s not open`);n.position.end=hS(e.end)}function u(){return Sy(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function f(e){if(this.data.expectingFirstListItemValue){let t=this.stack[this.stack.length-2];t.start=Number.parseInt(this.sliceSerialize(e),10),this.data.expectingFirstListItemValue=void 0}}function p(){let e=this.resume(),t=this.stack[this.stack.length-1];t.lang=e}function m(){let e=this.resume(),t=this.stack[this.stack.length-1];t.meta=e}function h(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function g(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,``),this.data.flowCodeInside=void 0}function _(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e.replace(/(\r?\n|\r)$/g,``)}function v(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=Fy(this.sliceSerialize(e)).toLowerCase()}function y(){let e=this.resume(),t=this.stack[this.stack.length-1];t.title=e}function b(){let e=this.resume(),t=this.stack[this.stack.length-1];t.url=e}function x(e){let t=this.stack[this.stack.length-1];t.depth||=this.sliceSerialize(e).length}function S(){this.data.setextHeadingSlurpLineEnding=!0}function C(e){let t=this.stack[this.stack.length-1];t.depth=this.sliceSerialize(e).codePointAt(0)===61?1:2}function w(){this.data.setextHeadingSlurpLineEnding=void 0}function T(e){let t=this.stack[this.stack.length-1].children,n=t[t.length-1];(!n||n.type!==`text`)&&(n=Oe(),n.position={start:hS(e.start),end:void 0},t.push(n)),this.stack.push(n)}function E(e){let t=this.stack.pop();t.value+=this.sliceSerialize(e),t.position.end=hS(e.end)}function ee(e){let n=this.stack[this.stack.length-1];if(this.data.atHardBreak){let t=n.children[n.children.length-1];t.position.end=hS(e.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(n.type)&&(T.call(this,e),E.call(this,e))}function D(){this.data.atHardBreak=!0}function O(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function te(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function ne(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function re(){let e=this.stack[this.stack.length-1];if(this.data.inReference){let t=this.data.referenceType||`shortcut`;e.type+=`Reference`,e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}function ie(){let e=this.stack[this.stack.length-1];if(this.data.inReference){let t=this.data.referenceType||`shortcut`;e.type+=`Reference`,e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}function ae(e){let t=this.sliceSerialize(e),n=this.stack[this.stack.length-2];n.label=uS(t),n.identifier=Fy(t).toLowerCase()}function oe(){let e=this.stack[this.stack.length-1],t=this.resume(),n=this.stack[this.stack.length-1];this.data.inReference=!0,n.type===`link`?n.children=e.children:n.alt=t}function k(){let e=this.resume(),t=this.stack[this.stack.length-1];t.url=e}function A(){let e=this.resume(),t=this.stack[this.stack.length-1];t.title=e}function se(){this.data.inReference=void 0}function ce(){this.data.referenceType=`collapsed`}function le(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=Fy(this.sliceSerialize(e)).toLowerCase(),this.data.referenceType=`full`}function ue(e){this.data.characterReferenceType=e.type}function de(e){let t=this.sliceSerialize(e),n=this.data.characterReferenceType,r;n?(r=Py(t,n===`characterReferenceMarkerNumeric`?10:16),this.data.characterReferenceType=void 0):r=Dy(t);let i=this.stack[this.stack.length-1];i.value+=r}function j(e){let t=this.stack.pop();t.position.end=hS(e.end)}function fe(e){E.call(this,e);let t=this.stack[this.stack.length-1];t.url=this.sliceSerialize(e)}function pe(e){E.call(this,e);let t=this.stack[this.stack.length-1];t.url=`mailto:`+this.sliceSerialize(e)}function me(){return{type:`blockquote`,children:[]}}function he(){return{type:`code`,lang:null,meta:null,value:``}}function ge(){return{type:`inlineCode`,value:``}}function _e(){return{type:`definition`,identifier:``,label:null,title:null,url:``}}function ve(){return{type:`emphasis`,children:[]}}function ye(){return{type:`heading`,depth:0,children:[]}}function be(){return{type:`break`}}function xe(){return{type:`html`,value:``}}function Se(){return{type:`image`,title:null,url:``,alt:null}}function Ce(){return{type:`link`,title:null,url:``,children:[]}}function we(e){return{type:`list`,ordered:e.type===`listOrdered`,start:null,spread:e._spread,children:[]}}function Te(e){return{type:`listItem`,spread:e._spread,checked:null,children:[]}}function Ee(){return{type:`paragraph`,children:[]}}function De(){return{type:`strong`,children:[]}}function Oe(){return{type:`text`,value:``}}function ke(){return{type:`thematicBreak`}}}function hS(e){return{line:e.line,column:e.column,offset:e.offset}}function gS(e,t){let n=-1;for(;++n<t.length;){let r=t[n];Array.isArray(r)?gS(e,r):_S(e,r)}}function _S(e,t){let n;for(n in t)if(fS.call(t,n))switch(n){case`canContainEols`:{let r=t[n];r&&e[n].push(...r);break}case`transforms`:{let r=t[n];r&&e[n].push(...r);break}case`enter`:case`exit`:{let r=t[n];r&&Object.assign(e[n],r);break}}}function vS(e,t){throw Error(e?"Cannot close `"+e.type+"` ("+Bv({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+Bv({start:t.start,end:t.end})+`) is open`:"Cannot close document, a token (`"+t.type+"`, "+Bv({start:t.start,end:t.end})+`) is still open`)}function yS(e){let t=this;t.parser=n;function n(n){return pS(n,{...t.data(`settings`),...e,extensions:t.data(`micromarkExtensions`)||[],mdastExtensions:t.data(`fromMarkdownExtensions`)||[]})}}function bS(e,t){let n={type:`element`,tagName:`blockquote`,properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function xS(e,t){let n={type:`element`,tagName:`br`,properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:`text`,value:`
|
|
1541
|
-
`}]}function
|
|
1542
|
-
`:``,r={},i=t.lang?t.lang.split(/\s+/):[];i.length>0&&(r.className=[`language-`+i[0]]);let a={type:`element`,tagName:`code`,properties:r,children:[{type:`text`,value:n}]};return t.meta&&(a.data={meta:t.meta}),e.patch(t,a),a=e.applyData(t,a),a={type:`element`,tagName:`pre`,properties:{},children:[a]},e.patch(t,a),a}function
|
|
1540
|
+
`;break;case-2:o=t?` `:` `;break;case-1:if(!t&&i)continue;o=` `;break;default:o=String.fromCharCode(a)}i=a===-2,r.push(o)}return r.join(``)}function oS(e){let t={constructs:My([qx,...(e||{}).extensions||[]]),content:n(Yy),defined:[],document:n(Zy),flow:n(zx),lazy:{},string:n(Hx),text:n(Ux)};return t;function n(e){return n;function n(n){return rS(t,e,n)}}}function sS(e){for(;!Nb(e););return e}var cS=/[\0\t\n\r]/g;function lS(){let e=1,t=``,n=!0,r;return i;function i(i,a,o){let s=[],c,l,u,d,f;for(i=t+(typeof i==`string`?i.toString():new TextDecoder(a||void 0).decode(i)),u=0,t=``,n&&=(i.charCodeAt(0)===65279&&u++,void 0);u<i.length;){if(cS.lastIndex=u,c=cS.exec(i),d=c&&c.index!==void 0?c.index:i.length,f=i.charCodeAt(d),!c){t=i.slice(u);break}if(f===10&&u===d&&r)s.push(-3),r=void 0;else switch(r&&=(s.push(-5),void 0),u<d&&(s.push(i.slice(u,d)),e+=d-u),f){case 0:s.push(65533),e++;break;case 9:for(l=Math.ceil(e/4)*4,s.push(-2);e++<l;)s.push(-1);break;case 10:s.push(-4),e=1;break;default:r=!0,e=1}u=d+1}return o&&(r&&s.push(-5),t&&s.push(t),s.push(null)),s}}var uS=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function dS(e){return e.replace(uS,fS)}function fS(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){let e=n.charCodeAt(1),t=e===120||e===88;return Fy(n.slice(t?2:1),t?16:10)}return Oy(n)||e}var pS={}.hasOwnProperty;function mS(e,t,n){return t&&typeof t==`object`&&(n=t,t=void 0),hS(n)(sS(oS(n).document().write(lS()(e,t,!0))))}function hS(e){let t={transforms:[],canContainEols:[`emphasis`,`fragment`,`heading`,`paragraph`,`strong`],enter:{autolink:a(Ce),autolinkProtocol:T,autolinkEmail:T,atxHeading:a(ye),blockQuote:a(me),characterEscape:T,characterReference:T,codeFenced:a(he),codeFencedFenceInfo:o,codeFencedFenceMeta:o,codeIndented:a(he,o),codeText:a(ge,o),codeTextData:T,data:T,codeFlowValue:T,definition:a(_e),definitionDestinationString:o,definitionLabelString:o,definitionTitleString:o,emphasis:a(ve),hardBreakEscape:a(be),hardBreakTrailing:a(be),htmlFlow:a(xe,o),htmlFlowData:T,htmlText:a(xe,o),htmlTextData:T,image:a(Se),label:o,link:a(Ce),listItem:a(Te),listItemValue:f,listOrdered:a(we,d),listUnordered:a(we),paragraph:a(Ee),reference:ce,referenceString:o,resourceDestinationString:o,resourceTitleString:o,setextHeading:a(ye),strong:a(De),thematicBreak:a(ke)},exit:{atxHeading:c(),atxHeadingSequence:x,autolink:c(),autolinkEmail:pe,autolinkProtocol:fe,blockQuote:c(),characterEscapeValue:E,characterReferenceMarkerHexadecimal:ue,characterReferenceMarkerNumeric:ue,characterReferenceValue:de,characterReference:j,codeFenced:c(g),codeFencedFence:h,codeFencedFenceInfo:p,codeFencedFenceMeta:m,codeFlowValue:E,codeIndented:c(_),codeText:c(ne),codeTextData:E,data:E,definition:c(),definitionDestinationString:b,definitionLabelString:v,definitionTitleString:y,emphasis:c(),hardBreakEscape:c(D),hardBreakTrailing:c(D),htmlFlow:c(O),htmlFlowData:E,htmlText:c(te),htmlTextData:E,image:c(ie),label:oe,labelText:ae,lineEnding:ee,link:c(re),listItem:c(),listOrdered:c(),listUnordered:c(),paragraph:c(),referenceString:le,resourceDestinationString:k,resourceTitleString:A,resource:se,setextHeading:c(w),setextHeadingLineSequence:C,setextHeadingText:S,strong:c(),thematicBreak:c()}};_S(t,(e||{}).mdastExtensions||[]);let n={};return r;function r(e){let r={type:`root`,children:[]},a={stack:[r],tokenStack:[],config:t,enter:s,exit:l,buffer:o,resume:u,data:n},c=[],d=-1;for(;++d<e.length;)(e[d][1].type===`listOrdered`||e[d][1].type===`listUnordered`)&&(e[d][0]===`enter`?c.push(d):d=i(e,c.pop(),d));for(d=-1;++d<e.length;){let n=t[e[d][0]];pS.call(n,e[d][1].type)&&n[e[d][1].type].call(Object.assign({sliceSerialize:e[d][2].sliceSerialize},a),e[d][1])}if(a.tokenStack.length>0){let e=a.tokenStack[a.tokenStack.length-1];(e[1]||yS).call(a,void 0,e[0])}for(r.position={start:gS(e.length>0?e[0][1].start:{line:1,column:1,offset:0}),end:gS(e.length>0?e[e.length-2][1].end:{line:1,column:1,offset:0})},d=-1;++d<t.transforms.length;)r=t.transforms[d](r)||r;return r}function i(e,t,n){let r=t-1,i=-1,a=!1,o,s,c,l;for(;++r<=n;){let t=e[r];switch(t[1].type){case`listUnordered`:case`listOrdered`:case`blockQuote`:t[0]===`enter`?i++:i--,l=void 0;break;case`lineEndingBlank`:t[0]===`enter`&&(o&&!l&&!i&&!c&&(c=r),l=void 0);break;case`linePrefix`:case`listItemValue`:case`listItemMarker`:case`listItemPrefix`:case`listItemPrefixWhitespace`:break;default:l=void 0}if(!i&&t[0]===`enter`&&t[1].type===`listItemPrefix`||i===-1&&t[0]===`exit`&&(t[1].type===`listUnordered`||t[1].type===`listOrdered`)){if(o){let i=r;for(s=void 0;i--;){let t=e[i];if(t[1].type===`lineEnding`||t[1].type===`lineEndingBlank`){if(t[0]===`exit`)continue;s&&(e[s][1].type=`lineEndingBlank`,a=!0),t[1].type=`lineEnding`,s=i}else if(t[1].type!==`linePrefix`&&t[1].type!==`blockQuotePrefix`&&t[1].type!==`blockQuotePrefixWhitespace`&&t[1].type!==`blockQuoteMarker`&&t[1].type!==`listItemIndent`)break}c&&(!s||c<s)&&(o._spread=!0),o.end=Object.assign({},s?e[s][1].start:t[1].end),e.splice(s||r,0,[`exit`,o,t[2]]),r++,n++}if(t[1].type===`listItemPrefix`){let i={type:`listItem`,_spread:!1,start:Object.assign({},t[1].start),end:void 0};o=i,e.splice(r,0,[`enter`,i,t[2]]),r++,n++,c=void 0,l=!0}}}return e[t][1]._spread=a,n}function a(e,t){return n;function n(n){s.call(this,e(n),n),t&&t.call(this,n)}}function o(){this.stack.push({type:`fragment`,children:[]})}function s(e,t,n){this.stack[this.stack.length-1].children.push(e),this.stack.push(e),this.tokenStack.push([t,n||void 0]),e.position={start:gS(t.start),end:void 0}}function c(e){return t;function t(t){e&&e.call(this,t),l.call(this,t)}}function l(e,t){let n=this.stack.pop(),r=this.tokenStack.pop();if(r)r[0].type!==e.type&&(t?t.call(this,e,r[0]):(r[1]||yS).call(this,e,r[0]));else throw Error("Cannot close `"+e.type+"` ("+Vv({start:e.start,end:e.end})+`): it’s not open`);n.position.end=gS(e.end)}function u(){return Cy(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function f(e){if(this.data.expectingFirstListItemValue){let t=this.stack[this.stack.length-2];t.start=Number.parseInt(this.sliceSerialize(e),10),this.data.expectingFirstListItemValue=void 0}}function p(){let e=this.resume(),t=this.stack[this.stack.length-1];t.lang=e}function m(){let e=this.resume(),t=this.stack[this.stack.length-1];t.meta=e}function h(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function g(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,``),this.data.flowCodeInside=void 0}function _(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e.replace(/(\r?\n|\r)$/g,``)}function v(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=Iy(this.sliceSerialize(e)).toLowerCase()}function y(){let e=this.resume(),t=this.stack[this.stack.length-1];t.title=e}function b(){let e=this.resume(),t=this.stack[this.stack.length-1];t.url=e}function x(e){let t=this.stack[this.stack.length-1];t.depth||=this.sliceSerialize(e).length}function S(){this.data.setextHeadingSlurpLineEnding=!0}function C(e){let t=this.stack[this.stack.length-1];t.depth=this.sliceSerialize(e).codePointAt(0)===61?1:2}function w(){this.data.setextHeadingSlurpLineEnding=void 0}function T(e){let t=this.stack[this.stack.length-1].children,n=t[t.length-1];(!n||n.type!==`text`)&&(n=Oe(),n.position={start:gS(e.start),end:void 0},t.push(n)),this.stack.push(n)}function E(e){let t=this.stack.pop();t.value+=this.sliceSerialize(e),t.position.end=gS(e.end)}function ee(e){let n=this.stack[this.stack.length-1];if(this.data.atHardBreak){let t=n.children[n.children.length-1];t.position.end=gS(e.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(n.type)&&(T.call(this,e),E.call(this,e))}function D(){this.data.atHardBreak=!0}function O(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function te(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function ne(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function re(){let e=this.stack[this.stack.length-1];if(this.data.inReference){let t=this.data.referenceType||`shortcut`;e.type+=`Reference`,e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}function ie(){let e=this.stack[this.stack.length-1];if(this.data.inReference){let t=this.data.referenceType||`shortcut`;e.type+=`Reference`,e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}function ae(e){let t=this.sliceSerialize(e),n=this.stack[this.stack.length-2];n.label=dS(t),n.identifier=Iy(t).toLowerCase()}function oe(){let e=this.stack[this.stack.length-1],t=this.resume(),n=this.stack[this.stack.length-1];this.data.inReference=!0,n.type===`link`?n.children=e.children:n.alt=t}function k(){let e=this.resume(),t=this.stack[this.stack.length-1];t.url=e}function A(){let e=this.resume(),t=this.stack[this.stack.length-1];t.title=e}function se(){this.data.inReference=void 0}function ce(){this.data.referenceType=`collapsed`}function le(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=Iy(this.sliceSerialize(e)).toLowerCase(),this.data.referenceType=`full`}function ue(e){this.data.characterReferenceType=e.type}function de(e){let t=this.sliceSerialize(e),n=this.data.characterReferenceType,r;n?(r=Fy(t,n===`characterReferenceMarkerNumeric`?10:16),this.data.characterReferenceType=void 0):r=Oy(t);let i=this.stack[this.stack.length-1];i.value+=r}function j(e){let t=this.stack.pop();t.position.end=gS(e.end)}function fe(e){E.call(this,e);let t=this.stack[this.stack.length-1];t.url=this.sliceSerialize(e)}function pe(e){E.call(this,e);let t=this.stack[this.stack.length-1];t.url=`mailto:`+this.sliceSerialize(e)}function me(){return{type:`blockquote`,children:[]}}function he(){return{type:`code`,lang:null,meta:null,value:``}}function ge(){return{type:`inlineCode`,value:``}}function _e(){return{type:`definition`,identifier:``,label:null,title:null,url:``}}function ve(){return{type:`emphasis`,children:[]}}function ye(){return{type:`heading`,depth:0,children:[]}}function be(){return{type:`break`}}function xe(){return{type:`html`,value:``}}function Se(){return{type:`image`,title:null,url:``,alt:null}}function Ce(){return{type:`link`,title:null,url:``,children:[]}}function we(e){return{type:`list`,ordered:e.type===`listOrdered`,start:null,spread:e._spread,children:[]}}function Te(e){return{type:`listItem`,spread:e._spread,checked:null,children:[]}}function Ee(){return{type:`paragraph`,children:[]}}function De(){return{type:`strong`,children:[]}}function Oe(){return{type:`text`,value:``}}function ke(){return{type:`thematicBreak`}}}function gS(e){return{line:e.line,column:e.column,offset:e.offset}}function _S(e,t){let n=-1;for(;++n<t.length;){let r=t[n];Array.isArray(r)?_S(e,r):vS(e,r)}}function vS(e,t){let n;for(n in t)if(pS.call(t,n))switch(n){case`canContainEols`:{let r=t[n];r&&e[n].push(...r);break}case`transforms`:{let r=t[n];r&&e[n].push(...r);break}case`enter`:case`exit`:{let r=t[n];r&&Object.assign(e[n],r);break}}}function yS(e,t){throw Error(e?"Cannot close `"+e.type+"` ("+Vv({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+Vv({start:t.start,end:t.end})+`) is open`:"Cannot close document, a token (`"+t.type+"`, "+Vv({start:t.start,end:t.end})+`) is still open`)}function bS(e){let t=this;t.parser=n;function n(n){return mS(n,{...t.data(`settings`),...e,extensions:t.data(`micromarkExtensions`)||[],mdastExtensions:t.data(`fromMarkdownExtensions`)||[]})}}function xS(e,t){let n={type:`element`,tagName:`blockquote`,properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function SS(e,t){let n={type:`element`,tagName:`br`,properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:`text`,value:`
|
|
1541
|
+
`}]}function CS(e,t){let n=t.value?t.value+`
|
|
1542
|
+
`:``,r={},i=t.lang?t.lang.split(/\s+/):[];i.length>0&&(r.className=[`language-`+i[0]]);let a={type:`element`,tagName:`code`,properties:r,children:[{type:`text`,value:n}]};return t.meta&&(a.data={meta:t.meta}),e.patch(t,a),a=e.applyData(t,a),a={type:`element`,tagName:`pre`,properties:{},children:[a]},e.patch(t,a),a}function wS(e,t){let n={type:`element`,tagName:`del`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function TS(e,t){let n={type:`element`,tagName:`em`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function ES(e,t){let n=typeof e.options.clobberPrefix==`string`?e.options.clobberPrefix:`user-content-`,r=String(t.identifier).toUpperCase(),i=Jy(r.toLowerCase()),a=e.footnoteOrder.indexOf(r),o,s=e.footnoteCounts.get(r);s===void 0?(s=0,e.footnoteOrder.push(r),o=e.footnoteOrder.length):o=a+1,s+=1,e.footnoteCounts.set(r,s);let c={type:`element`,tagName:`a`,properties:{href:`#`+n+`fn-`+i,id:n+`fnref-`+i+(s>1?`-`+s:``),dataFootnoteRef:!0,ariaDescribedBy:[`footnote-label`]},children:[{type:`text`,value:String(o)}]};e.patch(t,c);let l={type:`element`,tagName:`sup`,properties:{},children:[c]};return e.patch(t,l),e.applyData(t,l)}function DS(e,t){let n={type:`element`,tagName:`h`+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function OS(e,t){if(e.options.allowDangerousHtml){let n={type:`raw`,value:t.value};return e.patch(t,n),e.applyData(t,n)}}function kS(e,t){let n=t.referenceType,r=`]`;if(n===`collapsed`?r+=`[]`:n===`full`&&(r+=`[`+(t.label||t.identifier)+`]`),t.type===`imageReference`)return[{type:`text`,value:`![`+t.alt+r}];let i=e.all(t),a=i[0];a&&a.type===`text`?a.value=`[`+a.value:i.unshift({type:`text`,value:`[`});let o=i[i.length-1];return o&&o.type===`text`?o.value+=r:i.push({type:`text`,value:r}),i}function AS(e,t){let n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return kS(e,t);let i={src:Jy(r.url||``),alt:t.alt};r.title!==null&&r.title!==void 0&&(i.title=r.title);let a={type:`element`,tagName:`img`,properties:i,children:[]};return e.patch(t,a),e.applyData(t,a)}function jS(e,t){let n={src:Jy(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);let r={type:`element`,tagName:`img`,properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)}function MS(e,t){let n={type:`text`,value:t.value.replace(/\r?\n|\r/g,` `)};e.patch(t,n);let r={type:`element`,tagName:`code`,properties:{},children:[n]};return e.patch(t,r),e.applyData(t,r)}function NS(e,t){let n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return kS(e,t);let i={href:Jy(r.url||``)};r.title!==null&&r.title!==void 0&&(i.title=r.title);let a={type:`element`,tagName:`a`,properties:i,children:e.all(t)};return e.patch(t,a),e.applyData(t,a)}function PS(e,t){let n={href:Jy(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);let r={type:`element`,tagName:`a`,properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function FS(e,t,n){let r=e.all(t),i=n?IS(n):LS(t),a={},o=[];if(typeof t.checked==`boolean`){let e=r[0],n;e&&e.type===`element`&&e.tagName===`p`?n=e:(n={type:`element`,tagName:`p`,properties:{},children:[]},r.unshift(n)),n.children.length>0&&n.children.unshift({type:`text`,value:` `}),n.children.unshift({type:`element`,tagName:`input`,properties:{type:`checkbox`,checked:t.checked,disabled:!0},children:[]}),a.className=[`task-list-item`]}let s=-1;for(;++s<r.length;){let e=r[s];(i||s!==0||e.type!==`element`||e.tagName!==`p`)&&o.push({type:`text`,value:`
|
|
1543
1543
|
`}),e.type===`element`&&e.tagName===`p`&&!i?o.push(...e.children):o.push(e)}let c=r[r.length-1];c&&(i||c.type!==`element`||c.tagName!==`p`)&&o.push({type:`text`,value:`
|
|
1544
|
-
`});let l={type:`element`,tagName:`li`,properties:a,children:o};return e.patch(t,l),e.applyData(t,l)}function
|
|
1544
|
+
`});let l={type:`element`,tagName:`li`,properties:a,children:o};return e.patch(t,l),e.applyData(t,l)}function IS(e){let t=!1;if(e.type===`list`){t=e.spread||!1;let n=e.children,r=-1;for(;!t&&++r<n.length;)t=LS(n[r])}return t}function LS(e){return e.spread??e.children.length>1}function RS(e,t){let n={},r=e.all(t),i=-1;for(typeof t.start==`number`&&t.start!==1&&(n.start=t.start);++i<r.length;){let e=r[i];if(e.type===`element`&&e.tagName===`li`&&e.properties&&Array.isArray(e.properties.className)&&e.properties.className.includes(`task-list-item`)){n.className=[`contains-task-list`];break}}let a={type:`element`,tagName:t.ordered?`ol`:`ul`,properties:n,children:e.wrap(r,!0)};return e.patch(t,a),e.applyData(t,a)}function zS(e,t){let n={type:`element`,tagName:`p`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function BS(e,t){let n={type:`root`,children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function VS(e,t){let n={type:`element`,tagName:`strong`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function HS(e,t){let n=e.all(t),r=n.shift(),i=[];if(r){let n={type:`element`,tagName:`thead`,properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],n),i.push(n)}if(n.length>0){let r={type:`element`,tagName:`tbody`,properties:{},children:e.wrap(n,!0)},a=Rv(t.children[1]),o=Lv(t.children[t.children.length-1]);a&&o&&(r.position={start:a,end:o}),i.push(r)}let a={type:`element`,tagName:`table`,properties:{},children:e.wrap(i,!0)};return e.patch(t,a),e.applyData(t,a)}function US(e,t,n){let r=n?n.children:void 0,i=(r?r.indexOf(t):1)===0?`th`:`td`,a=n&&n.type===`table`?n.align:void 0,o=a?a.length:t.children.length,s=-1,c=[];for(;++s<o;){let n=t.children[s],r={},o=a?a[s]:void 0;o&&(r.align=o);let l={type:`element`,tagName:i,properties:r,children:[]};n&&(l.children=e.all(n),e.patch(n,l),l=e.applyData(n,l)),c.push(l)}let l={type:`element`,tagName:`tr`,properties:{},children:e.wrap(c,!0)};return e.patch(t,l),e.applyData(t,l)}function WS(e,t){let n={type:`element`,tagName:`td`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}var GS=9,KS=32;function qS(e){let t=String(e),n=/\r?\n|\r/g,r=n.exec(t),i=0,a=[];for(;r;)a.push(JS(t.slice(i,r.index),i>0,!0),r[0]),i=r.index+r[0].length,r=n.exec(t);return a.push(JS(t.slice(i),i>0,!1)),a.join(``)}function JS(e,t,n){let r=0,i=e.length;if(t){let t=e.codePointAt(r);for(;t===GS||t===KS;)r++,t=e.codePointAt(r)}if(n){let t=e.codePointAt(i-1);for(;t===GS||t===KS;)i--,t=e.codePointAt(i-1)}return i>r?e.slice(r,i):``}function YS(e,t){let n={type:`text`,value:qS(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function XS(e,t){let n={type:`element`,tagName:`hr`,properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}var ZS={blockquote:xS,break:SS,code:CS,delete:wS,emphasis:TS,footnoteReference:ES,heading:DS,html:OS,imageReference:AS,image:jS,inlineCode:MS,linkReference:NS,link:PS,listItem:FS,list:RS,paragraph:zS,root:BS,strong:VS,table:HS,tableCell:WS,tableRow:US,text:YS,thematicBreak:XS,toml:QS,yaml:QS,definition:QS,footnoteDefinition:QS};function QS(){}var $S=typeof self==`object`?self:globalThis,eC=(e,t)=>{switch(e){case`Function`:case`SharedWorker`:case`Worker`:case`eval`:case`setInterval`:case`setTimeout`:throw TypeError(`unable to deserialize `+e)}return new $S[e](t)},tC=(e,t)=>{let n=(t,n)=>(e.set(n,t),t),r=i=>{if(e.has(i))return e.get(i);let[a,o]=t[i];switch(a){case 0:case-1:return n(o,i);case 1:{let e=n([],i);for(let t of o)e.push(r(t));return e}case 2:{let e=n({},i);for(let[t,n]of o)e[r(t)]=r(n);return e}case 3:return n(new Date(o),i);case 4:{let{source:e,flags:t}=o;return n(new RegExp(e,t),i)}case 5:{let e=n(new Map,i);for(let[t,n]of o)e.set(r(t),r(n));return e}case 6:{let e=n(new Set,i);for(let t of o)e.add(r(t));return e}case 7:{let{name:e,message:t}=o;return n(eC(e,t),i)}case 8:return n(BigInt(o),i);case`BigInt`:return n(Object(BigInt(o)),i);case`ArrayBuffer`:return n(new Uint8Array(o).buffer,o);case`DataView`:{let{buffer:e}=new Uint8Array(o);return n(new DataView(e),o)}}return n(eC(a,o),i)};return r},nC=e=>tC(new Map,e)(0),rC=``,{toString:iC}={},{keys:aC}=Object,oC=e=>{let t=typeof e;if(t!==`object`||!e)return[0,t];let n=iC.call(e).slice(8,-1);switch(n){case`Array`:return[1,rC];case`Object`:return[2,rC];case`Date`:return[3,rC];case`RegExp`:return[4,rC];case`Map`:return[5,rC];case`Set`:return[6,rC];case`DataView`:return[1,n]}return n.includes(`Array`)?[1,n]:n.includes(`Error`)?[7,n]:[2,n]},sC=([e,t])=>e===0&&(t===`function`||t===`symbol`),cC=(e,t,n,r)=>{let i=(e,t)=>{let i=r.push(e)-1;return n.set(t,i),i},a=r=>{if(n.has(r))return n.get(r);let[o,s]=oC(r);switch(o){case 0:{let t=r;switch(s){case`bigint`:o=8,t=r.toString();break;case`function`:case`symbol`:if(e)throw TypeError(`unable to serialize `+s);t=null;break;case`undefined`:return i([-1],r)}return i([o,t],r)}case 1:{if(s){let e=r;return s===`DataView`?e=new Uint8Array(r.buffer):s===`ArrayBuffer`&&(e=new Uint8Array(r)),i([s,[...e]],r)}let e=[],t=i([o,e],r);for(let t of r)e.push(a(t));return t}case 2:{if(s)switch(s){case`BigInt`:return i([s,r.toString()],r);case`Boolean`:case`Number`:case`String`:return i([s,r.valueOf()],r)}if(t&&`toJSON`in r)return a(r.toJSON());let n=[],c=i([o,n],r);for(let t of aC(r))(e||!sC(oC(r[t])))&&n.push([a(t),a(r[t])]);return c}case 3:return i([o,r.toISOString()],r);case 4:{let{source:e,flags:t}=r;return i([o,{source:e,flags:t}],r)}case 5:{let t=[],n=i([o,t],r);for(let[n,i]of r)(e||!(sC(oC(n))||sC(oC(i))))&&t.push([a(n),a(i)]);return n}case 6:{let t=[],n=i([o,t],r);for(let n of r)(e||!sC(oC(n)))&&t.push(a(n));return n}}let{message:c}=r;return i([o,{name:s,message:c}],r)};return a},lC=(e,{json:t,lossy:n}={})=>{let r=[];return cC(!(t||n),!!t,new Map,r)(e),r},uC=typeof structuredClone==`function`?(e,t)=>t&&(`json`in t||`lossy`in t)?nC(lC(e,t)):structuredClone(e):(e,t)=>nC(lC(e,t));function dC(e,t){let n=[{type:`text`,value:`↩`}];return t>1&&n.push({type:`element`,tagName:`sup`,properties:{},children:[{type:`text`,value:String(t)}]}),n}function fC(e,t){return`Back to reference `+(e+1)+(t>1?`-`+t:``)}function pC(e){let t=typeof e.options.clobberPrefix==`string`?e.options.clobberPrefix:`user-content-`,n=e.options.footnoteBackContent||dC,r=e.options.footnoteBackLabel||fC,i=e.options.footnoteLabel||`Footnotes`,a=e.options.footnoteLabelTagName||`h2`,o=e.options.footnoteLabelProperties||{className:[`sr-only`]},s=[],c=-1;for(;++c<e.footnoteOrder.length;){let i=e.footnoteById.get(e.footnoteOrder[c]);if(!i)continue;let a=e.all(i),o=String(i.identifier).toUpperCase(),l=Jy(o.toLowerCase()),u=0,d=[],f=e.footnoteCounts.get(o);for(;f!==void 0&&++u<=f;){d.length>0&&d.push({type:`text`,value:` `});let e=typeof n==`string`?n:n(c,u);typeof e==`string`&&(e={type:`text`,value:e}),d.push({type:`element`,tagName:`a`,properties:{href:`#`+t+`fnref-`+l+(u>1?`-`+u:``),dataFootnoteBackref:``,ariaLabel:typeof r==`string`?r:r(c,u),className:[`data-footnote-backref`]},children:Array.isArray(e)?e:[e]})}let p=a[a.length-1];if(p&&p.type===`element`&&p.tagName===`p`){let e=p.children[p.children.length-1];e&&e.type===`text`?e.value+=` `:p.children.push({type:`text`,value:` `}),p.children.push(...d)}else a.push(...d);let m={type:`element`,tagName:`li`,properties:{id:t+`fn-`+l},children:e.wrap(a,!0)};e.patch(i,m),s.push(m)}if(s.length!==0)return{type:`element`,tagName:`section`,properties:{dataFootnotes:!0,className:[`footnotes`]},children:[{type:`element`,tagName:a,properties:{...uC(o),id:`footnote-label`},children:[{type:`text`,value:i}]},{type:`text`,value:`
|
|
1545
1545
|
`},{type:`element`,tagName:`ol`,properties:{},children:e.wrap(s,!0)},{type:`text`,value:`
|
|
1546
|
-
`}]}}var
|
|
1546
|
+
`}]}}var mC=(function(e){if(e==null)return yC;if(typeof e==`function`)return vC(e);if(typeof e==`object`)return Array.isArray(e)?hC(e):gC(e);if(typeof e==`string`)return _C(e);throw Error(`Expected function, string, or object as test`)});function hC(e){let t=[],n=-1;for(;++n<e.length;)t[n]=mC(e[n]);return vC(r);function r(...e){let n=-1;for(;++n<t.length;)if(t[n].apply(this,e))return!0;return!1}}function gC(e){let t=e;return vC(n);function n(n){let r=n,i;for(i in e)if(r[i]!==t[i])return!1;return!0}}function _C(e){return vC(t);function t(t){return t&&t.type===e}}function vC(e){return t;function t(t,n,r){return!!(bC(t)&&e.call(this,t,typeof n==`number`?n:void 0,r||void 0))}}function yC(){return!0}function bC(e){return typeof e==`object`&&!!e&&`type`in e}function xC(e){return e}var SC=[];function CC(e,t,n,r){let i;typeof t==`function`&&typeof n!=`function`?(r=n,n=t):i=t;let a=mC(i),o=r?-1:1;s(e,void 0,[])();function s(e,i,c){let l=e&&typeof e==`object`?e:{};if(typeof l.type==`string`){let t=typeof l.tagName==`string`?l.tagName:typeof l.name==`string`?l.name:void 0;Object.defineProperty(u,"name",{value:`node (`+xC(e.type+(t?`<`+t+`>`:``))+`)`})}return u;function u(){let l=SC,u,d,f;if((!t||a(e,i,c[c.length-1]||void 0))&&(l=wC(n(e,c)),l[0]===!1))return l;if(`children`in e&&e.children){let t=e;if(t.children&&l[0]!==`skip`)for(d=(r?t.children.length:-1)+o,f=c.concat(t);d>-1&&d<t.children.length;){let e=t.children[d];if(u=s(e,d,f)(),u[0]===!1)return u;d=typeof u[1]==`number`?u[1]:d+o}}return l}}}function wC(e){return Array.isArray(e)?e:typeof e==`number`?[!0,e]:e==null?SC:[e]}function TC(e,t,n,r){let i,a,o;typeof t==`function`&&typeof n!=`function`?(a=void 0,o=t,i=n):(a=t,o=n,i=r),CC(e,a,s,i);function s(e,t){let n=t[t.length-1],r=n?n.children.indexOf(e):void 0;return o(e,r,n)}}var EC={}.hasOwnProperty,DC={};function OC(e,t){let n=t||DC,r=new Map,i=new Map,a={all:s,applyData:AC,definitionById:r,footnoteById:i,footnoteCounts:new Map,footnoteOrder:[],handlers:{...ZS,...n.handlers},one:o,options:n,patch:kC,wrap:MC};return TC(e,function(e){if(e.type===`definition`||e.type===`footnoteDefinition`){let t=e.type===`definition`?r:i,n=String(e.identifier).toUpperCase();t.has(n)||t.set(n,e)}}),a;function o(e,t){let n=e.type,r=a.handlers[n];if(EC.call(a.handlers,n)&&r)return r(a,e,t);if(a.options.passThrough&&a.options.passThrough.includes(n)){if(`children`in e){let{children:t,...n}=e,r=uC(n);return r.children=a.all(e),r}return uC(e)}return(a.options.unknownHandler||jC)(a,e,t)}function s(e){let t=[];if(`children`in e){let n=e.children,r=-1;for(;++r<n.length;){let i=a.one(n[r],e);if(i){if(r&&n[r-1].type===`break`&&(!Array.isArray(i)&&i.type===`text`&&(i.value=NC(i.value)),!Array.isArray(i)&&i.type===`element`)){let e=i.children[0];e&&e.type===`text`&&(e.value=NC(e.value))}Array.isArray(i)?t.push(...i):t.push(i)}}}return t}}function kC(e,t){e.position&&(t.position=Bv(e))}function AC(e,t){let n=t;if(e&&e.data){let t=e.data.hName,r=e.data.hChildren,i=e.data.hProperties;typeof t==`string`&&(n.type===`element`?n.tagName=t:n={type:`element`,tagName:t,properties:{},children:`children`in n?n.children:[n]}),n.type===`element`&&i&&Object.assign(n.properties,uC(i)),`children`in n&&n.children&&r!=null&&(n.children=r)}return n}function jC(e,t){let n=t.data||{},r=`value`in t&&!(EC.call(n,`hProperties`)||EC.call(n,`hChildren`))?{type:`text`,value:t.value}:{type:`element`,tagName:`div`,properties:{},children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function MC(e,t){let n=[],r=-1;for(t&&n.push({type:`text`,value:`
|
|
1547
1547
|
`});++r<e.length;)r&&n.push({type:`text`,value:`
|
|
1548
1548
|
`}),n.push(e[r]);return t&&e.length>0&&n.push({type:`text`,value:`
|
|
1549
|
-
`}),n}function
|
|
1550
|
-
`},i)),a}function PC(e,t){return e&&`run`in e?async function(n,r){let i=NC(n,{file:r,...t});await e.run(i,r)}:function(n,r){return NC(n,{file:r,...e||t})}}function FC(e){if(e)throw e}var IC=o(((e,t)=>{var n=Object.prototype.hasOwnProperty,r=Object.prototype.toString,i=Object.defineProperty,a=Object.getOwnPropertyDescriptor,o=function(e){return typeof Array.isArray==`function`?Array.isArray(e):r.call(e)===`[object Array]`},s=function(e){if(!e||r.call(e)!==`[object Object]`)return!1;var t=n.call(e,`constructor`),i=e.constructor&&e.constructor.prototype&&n.call(e.constructor.prototype,`isPrototypeOf`);if(e.constructor&&!t&&!i)return!1;for(var a in e);return a===void 0||n.call(e,a)},c=function(e,t){i&&t.name===`__proto__`?i(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},l=function(e,t){if(t===`__proto__`){if(!n.call(e,t))return;if(a)return a(e,t).value}return e[t]};t.exports=function e(){var t,n,r,i,a,u,d=arguments[0],f=1,p=arguments.length,m=!1;for(typeof d==`boolean`&&(m=d,d=arguments[1]||{},f=2),(d==null||typeof d!=`object`&&typeof d!=`function`)&&(d={});f<p;++f)if(t=arguments[f],t!=null)for(n in t)r=l(d,n),i=l(t,n),d!==i&&(m&&i&&(s(i)||(a=o(i)))?(a?(a=!1,u=r&&o(r)?r:[]):u=r&&s(r)?r:{},c(d,{name:n,newValue:e(m,u,i)})):i!==void 0&&c(d,{name:n,newValue:i}));return d}}));function LC(e){if(typeof e!=`object`||!e)return!1;let t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function RC(){let e=[],t={run:n,use:r};return t;function n(...t){let n=-1,r=t.pop();if(typeof r!=`function`)throw TypeError(`Expected function as last argument, not `+r);i(null,...t);function i(a,...o){let s=e[++n],c=-1;if(a){r(a);return}for(;++c<t.length;)(o[c]===null||o[c]===void 0)&&(o[c]=t[c]);t=o,s?zC(s,i)(...o):r(null,...o)}}function r(n){if(typeof n!=`function`)throw TypeError("Expected `middelware` to be a function, not "+n);return e.push(n),t}}function zC(e,t){let n;return r;function r(...t){let r=e.length>t.length,o;r&&t.push(i);try{o=e.apply(this,t)}catch(e){let t=e;if(r&&n)throw t;return i(t)}r||(o&&o.then&&typeof o.then==`function`?o.then(a,i):o instanceof Error?i(o):a(o))}function i(e,...r){n||(n=!0,t(e,...r))}function a(e){i(null,e)}}var BC={basename:VC,dirname:HC,extname:UC,join:WC,sep:`/`};function VC(e,t){if(t!==void 0&&typeof t!=`string`)throw TypeError(`"ext" argument must be a string`);qC(e);let n=0,r=-1,i=e.length,a;if(t===void 0||t.length===0||t.length>e.length){for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else r<0&&(a=!0,r=i+1);return r<0?``:e.slice(n,r)}if(t===e)return``;let o=-1,s=t.length-1;for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else o<0&&(a=!0,o=i+1),s>-1&&(e.codePointAt(i)===t.codePointAt(s--)?s<0&&(r=i):(s=-1,r=o));return n===r?r=o:r<0&&(r=e.length),e.slice(n,r)}function HC(e){if(qC(e),e.length===0)return`.`;let t=-1,n=e.length,r;for(;--n;)if(e.codePointAt(n)===47){if(r){t=n;break}}else r||=!0;return t<0?e.codePointAt(0)===47?`/`:`.`:t===1&&e.codePointAt(0)===47?`//`:e.slice(0,t)}function UC(e){qC(e);let t=e.length,n=-1,r=0,i=-1,a=0,o;for(;t--;){let s=e.codePointAt(t);if(s===47){if(o){r=t+1;break}continue}n<0&&(o=!0,n=t+1),s===46?i<0?i=t:a!==1&&(a=1):i>-1&&(a=-1)}return i<0||n<0||a===0||a===1&&i===n-1&&i===r+1?``:e.slice(i,n)}function WC(...e){let t=-1,n;for(;++t<e.length;)qC(e[t]),e[t]&&(n=n===void 0?e[t]:n+`/`+e[t]);return n===void 0?`.`:GC(n)}function GC(e){qC(e);let t=e.codePointAt(0)===47,n=KC(e,!t);return n.length===0&&!t&&(n=`.`),n.length>0&&e.codePointAt(e.length-1)===47&&(n+=`/`),t?`/`+n:n}function KC(e,t){let n=``,r=0,i=-1,a=0,o=-1,s,c;for(;++o<=e.length;){if(o<e.length)s=e.codePointAt(o);else if(s===47)break;else s=47;if(s===47){if(i!==o-1&&a!==1){if(i!==o-1&&a===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(c=n.lastIndexOf(`/`),c!==n.length-1){c<0?(n=``,r=0):(n=n.slice(0,c),r=n.length-1-n.lastIndexOf(`/`)),i=o,a=0;continue}}else if(n.length>0){n=``,r=0,i=o,a=0;continue}}t&&(n=n.length>0?n+`/..`:`..`,r=2)}else n.length>0?n+=`/`+e.slice(i+1,o):n=e.slice(i+1,o),r=o-i-1}i=o,a=0}else s===46&&a>-1?a++:a=-1}return n}function qC(e){if(typeof e!=`string`)throw TypeError(`Path must be a string. Received `+JSON.stringify(e))}var JC={cwd:YC};function YC(){return`/`}function XC(e){return!!(typeof e==`object`&&e&&`href`in e&&e.href&&`protocol`in e&&e.protocol&&e.auth===void 0)}function ZC(e){if(typeof e==`string`)e=new URL(e);else if(!XC(e)){let t=TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code=`ERR_INVALID_ARG_TYPE`,t}if(e.protocol!==`file:`){let e=TypeError(`The URL must be of scheme file`);throw e.code=`ERR_INVALID_URL_SCHEME`,e}return QC(e)}function QC(e){if(e.hostname!==``){let e=TypeError(`File URL host must be "localhost" or empty on darwin`);throw e.code=`ERR_INVALID_FILE_URL_HOST`,e}let t=e.pathname,n=-1;for(;++n<t.length;)if(t.codePointAt(n)===37&&t.codePointAt(n+1)===50){let e=t.codePointAt(n+2);if(e===70||e===102){let e=TypeError(`File URL path must not include encoded / characters`);throw e.code=`ERR_INVALID_FILE_URL_PATH`,e}}return decodeURIComponent(t)}var $C=[`history`,`path`,`basename`,`stem`,`extname`,`dirname`],ew=class{constructor(e){let t;t=e?XC(e)?{path:e}:typeof e==`string`||iw(e)?{value:e}:e:{},this.cwd=`cwd`in t?``:JC.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let n=-1;for(;++n<$C.length;){let e=$C[n];e in t&&t[e]!==void 0&&t[e]!==null&&(this[e]=e===`history`?[...t[e]]:t[e])}let r;for(r in t)$C.includes(r)||(this[r]=t[r])}get basename(){return typeof this.path==`string`?BC.basename(this.path):void 0}set basename(e){nw(e,`basename`),tw(e,`basename`),this.path=BC.join(this.dirname||``,e)}get dirname(){return typeof this.path==`string`?BC.dirname(this.path):void 0}set dirname(e){rw(this.basename,`dirname`),this.path=BC.join(e||``,this.basename)}get extname(){return typeof this.path==`string`?BC.extname(this.path):void 0}set extname(e){if(tw(e,`extname`),rw(this.dirname,`extname`),e){if(e.codePointAt(0)!==46)throw Error("`extname` must start with `.`");if(e.includes(`.`,1))throw Error("`extname` cannot contain multiple dots")}this.path=BC.join(this.dirname,this.stem+(e||``))}get path(){return this.history[this.history.length-1]}set path(e){XC(e)&&(e=ZC(e)),nw(e,`path`),this.path!==e&&this.history.push(e)}get stem(){return typeof this.path==`string`?BC.basename(this.path,this.extname):void 0}set stem(e){nw(e,`stem`),tw(e,`stem`),this.path=BC.join(this.dirname||``,e+(this.extname||``))}fail(e,t,n){let r=this.message(e,t,n);throw r.fatal=!0,r}info(e,t,n){let r=this.message(e,t,n);return r.fatal=void 0,r}message(e,t,n){let r=new Wv(e,t,n);return this.path&&(r.name=this.path+`:`+r.name,r.file=this.path),r.fatal=!1,this.messages.push(r),r}toString(e){return this.value===void 0?``:typeof this.value==`string`?this.value:new TextDecoder(e||void 0).decode(this.value)}};function tw(e,t){if(e&&e.includes(BC.sep))throw Error("`"+t+"` cannot be a path: did not expect `"+BC.sep+"`")}function nw(e,t){if(!e)throw Error("`"+t+"` cannot be empty")}function rw(e,t){if(!e)throw Error("Setting `"+t+"` requires `path` to be set too")}function iw(e){return!!(e&&typeof e==`object`&&`byteLength`in e&&`byteOffset`in e)}var aw=(function(e){let t=this.constructor.prototype,n=t[e],r=function(){return n.apply(r,arguments)};return Object.setPrototypeOf(r,t),r}),ow=l(IC(),1),sw={}.hasOwnProperty,cw=new class e extends aw{constructor(){super(`copy`),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=RC()}copy(){let t=new e,n=-1;for(;++n<this.attachers.length;){let e=this.attachers[n];t.use(...e)}return t.data((0,ow.default)(!0,{},this.namespace)),t}data(e,t){return typeof e==`string`?arguments.length===2?(dw(`data`,this.frozen),this.namespace[e]=t,this):sw.call(this.namespace,e)&&this.namespace[e]||void 0:e?(dw(`data`,this.frozen),this.namespace=e,this):this.namespace}freeze(){if(this.frozen)return this;let e=this;for(;++this.freezeIndex<this.attachers.length;){let[t,...n]=this.attachers[this.freezeIndex];if(n[0]===!1)continue;n[0]===!0&&(n[0]=void 0);let r=t.call(e,...n);typeof r==`function`&&this.transformers.use(r)}return this.frozen=!0,this.freezeIndex=1/0,this}parse(e){this.freeze();let t=mw(e),n=this.parser||this.Parser;return lw(`parse`,n),n(String(t),t)}process(e,t){let n=this;return this.freeze(),lw(`process`,this.parser||this.Parser),uw(`process`,this.compiler||this.Compiler),t?r(void 0,t):new Promise(r);function r(r,i){let a=mw(e),o=n.parse(a);n.run(o,a,function(e,t,r){if(e||!t||!r)return s(e);let i=t,a=n.stringify(i,r);gw(a)?r.value=a:r.result=a,s(e,r)});function s(e,n){e||!n?i(e):r?r(n):t(void 0,n)}}}processSync(e){let t=!1,n;return this.freeze(),lw(`processSync`,this.parser||this.Parser),uw(`processSync`,this.compiler||this.Compiler),this.process(e,r),pw(`processSync`,`process`,t),n;function r(e,r){t=!0,FC(e),n=r}}run(e,t,n){fw(e),this.freeze();let r=this.transformers;return!n&&typeof t==`function`&&(n=t,t=void 0),n?i(void 0,n):new Promise(i);function i(i,a){let o=mw(t);r.run(e,o,s);function s(t,r,o){let s=r||e;t?a(t):i?i(s):n(void 0,s,o)}}}runSync(e,t){let n=!1,r;return this.run(e,t,i),pw(`runSync`,`run`,n),r;function i(e,t){FC(e),r=t,n=!0}}stringify(e,t){this.freeze();let n=mw(t),r=this.compiler||this.Compiler;return uw(`stringify`,r),fw(e),r(e,n)}use(e,...t){let n=this.attachers,r=this.namespace;if(dw(`use`,this.frozen),e!=null){if(typeof e==`function`)s(e,t);else if(typeof e==`object`)Array.isArray(e)?o(e):a(e);else throw TypeError("Expected usable value, not `"+e+"`")}return this;function i(e){if(typeof e==`function`)s(e,[]);else if(typeof e==`object`){if(Array.isArray(e)){let[t,...n]=e;s(t,n)}else a(e)}else throw TypeError("Expected usable value, not `"+e+"`")}function a(e){if(!(`plugins`in e)&&!(`settings`in e))throw Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");o(e.plugins),e.settings&&(r.settings=(0,ow.default)(!0,r.settings,e.settings))}function o(e){let t=-1;if(e!=null){if(Array.isArray(e))for(;++t<e.length;){let n=e[t];i(n)}else throw TypeError("Expected a list of plugins, not `"+e+"`")}}function s(e,t){let r=-1,i=-1;for(;++r<n.length;)if(n[r][0]===e){i=r;break}if(i===-1)n.push([e,...t]);else if(t.length>0){let[r,...a]=t,o=n[i][1];LC(o)&&LC(r)&&(r=(0,ow.default)(!0,o,r)),n[i]=[e,r,...a]}}}}().freeze();function lw(e,t){if(typeof t!=`function`)throw TypeError("Cannot `"+e+"` without `parser`")}function uw(e,t){if(typeof t!=`function`)throw TypeError("Cannot `"+e+"` without `compiler`")}function dw(e,t){if(t)throw Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function fw(e){if(!LC(e)||typeof e.type!=`string`)throw TypeError("Expected node, got `"+e+"`")}function pw(e,t,n){if(!n)throw Error("`"+e+"` finished async. Use `"+t+"` instead")}function mw(e){return hw(e)?e:new ew(e)}function hw(e){return!!(e&&typeof e==`object`&&`message`in e&&`messages`in e)}function gw(e){return typeof e==`string`||_w(e)}function _w(e){return!!(e&&typeof e==`object`&&`byteLength`in e&&`byteOffset`in e)}var vw=[],yw={allowDangerousHtml:!0},bw=/^(https?|ircs?|mailto|xmpp)$/i,xw=[{from:`astPlugins`,id:`remove-buggy-html-in-markdown-parser`},{from:`allowDangerousHtml`,id:`remove-buggy-html-in-markdown-parser`},{from:`allowNode`,id:`replace-allownode-allowedtypes-and-disallowedtypes`,to:`allowElement`},{from:`allowedTypes`,id:`replace-allownode-allowedtypes-and-disallowedtypes`,to:`allowedElements`},{from:`className`,id:`remove-classname`},{from:`disallowedTypes`,id:`replace-allownode-allowedtypes-and-disallowedtypes`,to:`disallowedElements`},{from:`escapeHtml`,id:`remove-buggy-html-in-markdown-parser`},{from:`includeElementIndex`,id:`#remove-includeelementindex`},{from:`includeNodeIndex`,id:`change-includenodeindex-to-includeelementindex`},{from:`linkTarget`,id:`remove-linktarget`},{from:`plugins`,id:`change-plugins-to-remarkplugins`,to:`remarkPlugins`},{from:`rawSourcePos`,id:`#remove-rawsourcepos`},{from:`renderers`,id:`change-renderers-to-components`,to:`components`},{from:`source`,id:`change-source-to-children`,to:`children`},{from:`sourcePos`,id:`#remove-sourcepos`},{from:`transformImageUri`,id:`#add-urltransform`,to:`urlTransform`},{from:`transformLinkUri`,id:`#add-urltransform`,to:`urlTransform`}];function Sw(e){let t=Cw(e),n=ww(e);return Tw(t.runSync(t.parse(n),n),e)}function Cw(e){let t=e.rehypePlugins||vw,n=e.remarkPlugins||vw,r=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...yw}:yw;return cw().use(yS).use(n).use(PC,r).use(t)}function ww(e){let t=e.children||``,n=new ew;return typeof t==`string`?n.value=t:``+t,n}function Tw(e,t){let n=t.allowedElements,r=t.allowElement,i=t.components,a=t.disallowedElements,o=t.skipHtml,s=t.unwrapDisallowed,c=t.urlTransform||Ew;for(let e of xw)Object.hasOwn(t,e.from)&&``+e.from+(e.to?"use `"+e.to+"` instead":`remove it`)+e.id;return wC(e,l),Qv(e,{Fragment:D.Fragment,components:i,ignoreInvalidStyle:!0,jsx:D.jsx,jsxs:D.jsxs,passKeys:!0,passNode:!0});function l(e,t,i){if(e.type===`raw`&&i&&typeof t==`number`)return o?i.children.splice(t,1):i.children[t]={type:`text`,value:e.value},t;if(e.type===`element`){let t;for(t in by)if(Object.hasOwn(by,t)&&Object.hasOwn(e.properties,t)){let n=e.properties[t],r=by[t];(r===null||r.includes(e.tagName))&&(e.properties[t]=c(String(n||``),t,e))}}if(e.type===`element`){let o=n?!n.includes(e.tagName):a?a.includes(e.tagName):!1;if(!o&&r&&typeof t==`number`&&(o=!r(e,t,i)),o&&i&&typeof t==`number`)return s&&e.children?i.children.splice(t,1,...e.children):i.children.splice(t,1),t}}}function Ew(e){let t=e.indexOf(`:`),n=e.indexOf(`?`),r=e.indexOf(`#`),i=e.indexOf(`/`);return t===-1||i!==-1&&t>i||n!==-1&&t>n||r!==-1&&t>r||bw.test(e.slice(0,t))?e:``}function Dw(e){if(typeof e!=`string`)throw TypeError(`Expected a string`);return e.replace(/[|\\{}()[\]^$+*?.]/g,`\\$&`).replace(/-/g,`\\x2d`)}function Ow(e,t,n){let r=pC((n||{}).ignore||[]),i=kw(t),a=-1;for(;++a<i.length;)SC(e,`text`,o);function o(e,t){let n=-1,i;for(;++n<t.length;){let e=t[n],a=i?i.children:void 0;if(r(e,a?a.indexOf(e):void 0,i))return;i=e}if(i)return s(e,t)}function s(e,t){let n=t[t.length-1],r=i[a][0],o=i[a][1],s=0,c=n.children.indexOf(e),l=!1,u=[];r.lastIndex=0;let d=r.exec(e.value);for(;d;){let n=d.index,i={index:d.index,input:d.input,stack:[...t,e]},a=o(...d,i);if(typeof a==`string`&&(a=a.length>0?{type:`text`,value:a}:void 0),a===!1?r.lastIndex=n+1:(s!==n&&u.push({type:`text`,value:e.value.slice(s,n)}),Array.isArray(a)?u.push(...a):a&&u.push(a),s=n+d[0].length,l=!0),!r.global)break;d=r.exec(e.value)}return l?(s<e.value.length&&u.push({type:`text`,value:e.value.slice(s)}),n.children.splice(c,1,...u)):u=[e],c+u.length}}function kw(e){let t=[];if(!Array.isArray(e))throw TypeError(`Expected find and replace tuple or list of tuples`);let n=!e[0]||Array.isArray(e[0])?e:[e],r=-1;for(;++r<n.length;){let e=n[r];t.push([Aw(e[0]),jw(e[1])])}return t}function Aw(e){return typeof e==`string`?new RegExp(Dw(e),`g`):e}function jw(e){return typeof e==`function`?e:function(){return e}}var Mw=`phrasing`,Nw=[`autolink`,`link`,`image`,`label`];function Pw(){return{transforms:[Hw],enter:{literalAutolink:Iw,literalAutolinkEmail:Lw,literalAutolinkHttp:Lw,literalAutolinkWww:Lw},exit:{literalAutolink:Vw,literalAutolinkEmail:Bw,literalAutolinkHttp:Rw,literalAutolinkWww:zw}}}function Fw(){return{unsafe:[{character:`@`,before:`[+\\-.\\w]`,after:`[\\-.\\w]`,inConstruct:Mw,notInConstruct:Nw},{character:`.`,before:`[Ww]`,after:`[\\-.\\w]`,inConstruct:Mw,notInConstruct:Nw},{character:`:`,before:`[ps]`,after:`\\/`,inConstruct:Mw,notInConstruct:Nw}]}}function Iw(e){this.enter({type:`link`,title:null,url:``,children:[]},e)}function Lw(e){this.config.enter.autolinkProtocol.call(this,e)}function Rw(e){this.config.exit.autolinkProtocol.call(this,e)}function zw(e){this.config.exit.data.call(this,e);let t=this.stack[this.stack.length-1];t.type,t.url=`http://`+this.sliceSerialize(e)}function Bw(e){this.config.exit.autolinkEmail.call(this,e)}function Vw(e){this.exit(e)}function Hw(e){Ow(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,Uw],[/(?<=^|\s|\p{P}|\p{S})([-.\w+]+)@([-\w]+(?:\.[-\w]+)+)/gu,Ww]],{ignore:[`link`,`linkReference`]})}function Uw(e,t,n,r,i){let a=``;if(!qw(i)||(/^w/i.test(t)&&(n=t+n,t=``,a=`http://`),!Gw(n)))return!1;let o=Kw(n+r);if(!o[0])return!1;let s={type:`link`,title:null,url:a+t+o[0],children:[{type:`text`,value:t+o[0]}]};return o[1]?[s,{type:`text`,value:o[1]}]:s}function Ww(e,t,n,r){return!qw(r,!0)||/[-\d_]$/.test(n)?!1:{type:`link`,title:null,url:`mailto:`+t+`@`+n,children:[{type:`text`,value:t+`@`+n}]}}function Gw(e){let t=e.split(`.`);return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function Kw(e){let t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(`)`),i=xa(e,`(`),a=xa(e,`)`);for(;r!==-1&&i>a;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(`)`),a++;return[e,n]}function qw(e,t){let n=e.input.charCodeAt(e.index-1);return(e.index===0||Gy(n)||Wy(n))&&(!t||n!==47)}rT.peek=nT;function Jw(){this.buffer()}function Yw(e){this.enter({type:`footnoteReference`,identifier:``,label:``},e)}function Xw(){this.buffer()}function Zw(e){this.enter({type:`footnoteDefinition`,identifier:``,label:``,children:[]},e)}function Qw(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Fy(this.sliceSerialize(e)).toLowerCase(),n.label=t}function $w(e){this.exit(e)}function eT(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Fy(this.sliceSerialize(e)).toLowerCase(),n.label=t}function tT(e){this.exit(e)}function nT(){return`[`}function rT(e,t,n,r){let i=n.createTracker(r),a=i.move(`[^`),o=n.enter(`footnoteReference`),s=n.enter(`reference`);return a+=i.move(n.safe(n.associationId(e),{after:`]`,before:a})),s(),o(),a+=i.move(`]`),a}function iT(){return{enter:{gfmFootnoteCallString:Jw,gfmFootnoteCall:Yw,gfmFootnoteDefinitionLabelString:Xw,gfmFootnoteDefinition:Zw},exit:{gfmFootnoteCallString:Qw,gfmFootnoteCall:$w,gfmFootnoteDefinitionLabelString:eT,gfmFootnoteDefinition:tT}}}function aT(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:rT},unsafe:[{character:`[`,inConstruct:[`label`,`phrasing`,`reference`]}]};function n(e,n,r,i){let a=r.createTracker(i),o=a.move(`[^`),s=r.enter(`footnoteDefinition`),c=r.enter(`label`);return o+=a.move(r.safe(r.associationId(e),{before:o,after:`]`})),c(),o+=a.move(`]:`),e.children&&e.children.length>0&&(a.shift(4),o+=a.move((t?`
|
|
1551
|
-
`:` `)+r.indentLines(r.containerFlow(e,a.current()),t?sT
|
|
1552
|
-
`)}function
|
|
1553
|
-
`&&
|
|
1554
|
-
`}function
|
|
1549
|
+
`}),n}function NC(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function PC(e,t){let n=OC(e,t),r=n.one(e,void 0),i=pC(n),a=Array.isArray(r)?{type:`root`,children:r}:r||{type:`root`,children:[]};return i&&(`children`in a,a.children.push({type:`text`,value:`
|
|
1550
|
+
`},i)),a}function FC(e,t){return e&&`run`in e?async function(n,r){let i=PC(n,{file:r,...t});await e.run(i,r)}:function(n,r){return PC(n,{file:r,...e||t})}}function IC(e){if(e)throw e}var LC=o(((e,t)=>{var n=Object.prototype.hasOwnProperty,r=Object.prototype.toString,i=Object.defineProperty,a=Object.getOwnPropertyDescriptor,o=function(e){return typeof Array.isArray==`function`?Array.isArray(e):r.call(e)===`[object Array]`},s=function(e){if(!e||r.call(e)!==`[object Object]`)return!1;var t=n.call(e,`constructor`),i=e.constructor&&e.constructor.prototype&&n.call(e.constructor.prototype,`isPrototypeOf`);if(e.constructor&&!t&&!i)return!1;for(var a in e);return a===void 0||n.call(e,a)},c=function(e,t){i&&t.name===`__proto__`?i(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},l=function(e,t){if(t===`__proto__`){if(!n.call(e,t))return;if(a)return a(e,t).value}return e[t]};t.exports=function e(){var t,n,r,i,a,u,d=arguments[0],f=1,p=arguments.length,m=!1;for(typeof d==`boolean`&&(m=d,d=arguments[1]||{},f=2),(d==null||typeof d!=`object`&&typeof d!=`function`)&&(d={});f<p;++f)if(t=arguments[f],t!=null)for(n in t)r=l(d,n),i=l(t,n),d!==i&&(m&&i&&(s(i)||(a=o(i)))?(a?(a=!1,u=r&&o(r)?r:[]):u=r&&s(r)?r:{},c(d,{name:n,newValue:e(m,u,i)})):i!==void 0&&c(d,{name:n,newValue:i}));return d}}));function RC(e){if(typeof e!=`object`||!e)return!1;let t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function zC(){let e=[],t={run:n,use:r};return t;function n(...t){let n=-1,r=t.pop();if(typeof r!=`function`)throw TypeError(`Expected function as last argument, not `+r);i(null,...t);function i(a,...o){let s=e[++n],c=-1;if(a){r(a);return}for(;++c<t.length;)(o[c]===null||o[c]===void 0)&&(o[c]=t[c]);t=o,s?BC(s,i)(...o):r(null,...o)}}function r(n){if(typeof n!=`function`)throw TypeError("Expected `middelware` to be a function, not "+n);return e.push(n),t}}function BC(e,t){let n;return r;function r(...t){let r=e.length>t.length,o;r&&t.push(i);try{o=e.apply(this,t)}catch(e){let t=e;if(r&&n)throw t;return i(t)}r||(o&&o.then&&typeof o.then==`function`?o.then(a,i):o instanceof Error?i(o):a(o))}function i(e,...r){n||(n=!0,t(e,...r))}function a(e){i(null,e)}}var VC={basename:HC,dirname:UC,extname:WC,join:GC,sep:`/`};function HC(e,t){if(t!==void 0&&typeof t!=`string`)throw TypeError(`"ext" argument must be a string`);JC(e);let n=0,r=-1,i=e.length,a;if(t===void 0||t.length===0||t.length>e.length){for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else r<0&&(a=!0,r=i+1);return r<0?``:e.slice(n,r)}if(t===e)return``;let o=-1,s=t.length-1;for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else o<0&&(a=!0,o=i+1),s>-1&&(e.codePointAt(i)===t.codePointAt(s--)?s<0&&(r=i):(s=-1,r=o));return n===r?r=o:r<0&&(r=e.length),e.slice(n,r)}function UC(e){if(JC(e),e.length===0)return`.`;let t=-1,n=e.length,r;for(;--n;)if(e.codePointAt(n)===47){if(r){t=n;break}}else r||=!0;return t<0?e.codePointAt(0)===47?`/`:`.`:t===1&&e.codePointAt(0)===47?`//`:e.slice(0,t)}function WC(e){JC(e);let t=e.length,n=-1,r=0,i=-1,a=0,o;for(;t--;){let s=e.codePointAt(t);if(s===47){if(o){r=t+1;break}continue}n<0&&(o=!0,n=t+1),s===46?i<0?i=t:a!==1&&(a=1):i>-1&&(a=-1)}return i<0||n<0||a===0||a===1&&i===n-1&&i===r+1?``:e.slice(i,n)}function GC(...e){let t=-1,n;for(;++t<e.length;)JC(e[t]),e[t]&&(n=n===void 0?e[t]:n+`/`+e[t]);return n===void 0?`.`:KC(n)}function KC(e){JC(e);let t=e.codePointAt(0)===47,n=qC(e,!t);return n.length===0&&!t&&(n=`.`),n.length>0&&e.codePointAt(e.length-1)===47&&(n+=`/`),t?`/`+n:n}function qC(e,t){let n=``,r=0,i=-1,a=0,o=-1,s,c;for(;++o<=e.length;){if(o<e.length)s=e.codePointAt(o);else if(s===47)break;else s=47;if(s===47){if(i!==o-1&&a!==1){if(i!==o-1&&a===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(c=n.lastIndexOf(`/`),c!==n.length-1){c<0?(n=``,r=0):(n=n.slice(0,c),r=n.length-1-n.lastIndexOf(`/`)),i=o,a=0;continue}}else if(n.length>0){n=``,r=0,i=o,a=0;continue}}t&&(n=n.length>0?n+`/..`:`..`,r=2)}else n.length>0?n+=`/`+e.slice(i+1,o):n=e.slice(i+1,o),r=o-i-1}i=o,a=0}else s===46&&a>-1?a++:a=-1}return n}function JC(e){if(typeof e!=`string`)throw TypeError(`Path must be a string. Received `+JSON.stringify(e))}var YC={cwd:XC};function XC(){return`/`}function ZC(e){return!!(typeof e==`object`&&e&&`href`in e&&e.href&&`protocol`in e&&e.protocol&&e.auth===void 0)}function QC(e){if(typeof e==`string`)e=new URL(e);else if(!ZC(e)){let t=TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code=`ERR_INVALID_ARG_TYPE`,t}if(e.protocol!==`file:`){let e=TypeError(`The URL must be of scheme file`);throw e.code=`ERR_INVALID_URL_SCHEME`,e}return $C(e)}function $C(e){if(e.hostname!==``){let e=TypeError(`File URL host must be "localhost" or empty on darwin`);throw e.code=`ERR_INVALID_FILE_URL_HOST`,e}let t=e.pathname,n=-1;for(;++n<t.length;)if(t.codePointAt(n)===37&&t.codePointAt(n+1)===50){let e=t.codePointAt(n+2);if(e===70||e===102){let e=TypeError(`File URL path must not include encoded / characters`);throw e.code=`ERR_INVALID_FILE_URL_PATH`,e}}return decodeURIComponent(t)}var ew=[`history`,`path`,`basename`,`stem`,`extname`,`dirname`],tw=class{constructor(e){let t;t=e?ZC(e)?{path:e}:typeof e==`string`||aw(e)?{value:e}:e:{},this.cwd=`cwd`in t?``:YC.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let n=-1;for(;++n<ew.length;){let e=ew[n];e in t&&t[e]!==void 0&&t[e]!==null&&(this[e]=e===`history`?[...t[e]]:t[e])}let r;for(r in t)ew.includes(r)||(this[r]=t[r])}get basename(){return typeof this.path==`string`?VC.basename(this.path):void 0}set basename(e){rw(e,`basename`),nw(e,`basename`),this.path=VC.join(this.dirname||``,e)}get dirname(){return typeof this.path==`string`?VC.dirname(this.path):void 0}set dirname(e){iw(this.basename,`dirname`),this.path=VC.join(e||``,this.basename)}get extname(){return typeof this.path==`string`?VC.extname(this.path):void 0}set extname(e){if(nw(e,`extname`),iw(this.dirname,`extname`),e){if(e.codePointAt(0)!==46)throw Error("`extname` must start with `.`");if(e.includes(`.`,1))throw Error("`extname` cannot contain multiple dots")}this.path=VC.join(this.dirname,this.stem+(e||``))}get path(){return this.history[this.history.length-1]}set path(e){ZC(e)&&(e=QC(e)),rw(e,`path`),this.path!==e&&this.history.push(e)}get stem(){return typeof this.path==`string`?VC.basename(this.path,this.extname):void 0}set stem(e){rw(e,`stem`),nw(e,`stem`),this.path=VC.join(this.dirname||``,e+(this.extname||``))}fail(e,t,n){let r=this.message(e,t,n);throw r.fatal=!0,r}info(e,t,n){let r=this.message(e,t,n);return r.fatal=void 0,r}message(e,t,n){let r=new Gv(e,t,n);return this.path&&(r.name=this.path+`:`+r.name,r.file=this.path),r.fatal=!1,this.messages.push(r),r}toString(e){return this.value===void 0?``:typeof this.value==`string`?this.value:new TextDecoder(e||void 0).decode(this.value)}};function nw(e,t){if(e&&e.includes(VC.sep))throw Error("`"+t+"` cannot be a path: did not expect `"+VC.sep+"`")}function rw(e,t){if(!e)throw Error("`"+t+"` cannot be empty")}function iw(e,t){if(!e)throw Error("Setting `"+t+"` requires `path` to be set too")}function aw(e){return!!(e&&typeof e==`object`&&`byteLength`in e&&`byteOffset`in e)}var ow=(function(e){let t=this.constructor.prototype,n=t[e],r=function(){return n.apply(r,arguments)};return Object.setPrototypeOf(r,t),r}),sw=l(LC(),1),cw={}.hasOwnProperty,lw=new class e extends ow{constructor(){super(`copy`),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=zC()}copy(){let t=new e,n=-1;for(;++n<this.attachers.length;){let e=this.attachers[n];t.use(...e)}return t.data((0,sw.default)(!0,{},this.namespace)),t}data(e,t){return typeof e==`string`?arguments.length===2?(fw(`data`,this.frozen),this.namespace[e]=t,this):cw.call(this.namespace,e)&&this.namespace[e]||void 0:e?(fw(`data`,this.frozen),this.namespace=e,this):this.namespace}freeze(){if(this.frozen)return this;let e=this;for(;++this.freezeIndex<this.attachers.length;){let[t,...n]=this.attachers[this.freezeIndex];if(n[0]===!1)continue;n[0]===!0&&(n[0]=void 0);let r=t.call(e,...n);typeof r==`function`&&this.transformers.use(r)}return this.frozen=!0,this.freezeIndex=1/0,this}parse(e){this.freeze();let t=hw(e),n=this.parser||this.Parser;return uw(`parse`,n),n(String(t),t)}process(e,t){let n=this;return this.freeze(),uw(`process`,this.parser||this.Parser),dw(`process`,this.compiler||this.Compiler),t?r(void 0,t):new Promise(r);function r(r,i){let a=hw(e),o=n.parse(a);n.run(o,a,function(e,t,r){if(e||!t||!r)return s(e);let i=t,a=n.stringify(i,r);_w(a)?r.value=a:r.result=a,s(e,r)});function s(e,n){e||!n?i(e):r?r(n):t(void 0,n)}}}processSync(e){let t=!1,n;return this.freeze(),uw(`processSync`,this.parser||this.Parser),dw(`processSync`,this.compiler||this.Compiler),this.process(e,r),mw(`processSync`,`process`,t),n;function r(e,r){t=!0,IC(e),n=r}}run(e,t,n){pw(e),this.freeze();let r=this.transformers;return!n&&typeof t==`function`&&(n=t,t=void 0),n?i(void 0,n):new Promise(i);function i(i,a){let o=hw(t);r.run(e,o,s);function s(t,r,o){let s=r||e;t?a(t):i?i(s):n(void 0,s,o)}}}runSync(e,t){let n=!1,r;return this.run(e,t,i),mw(`runSync`,`run`,n),r;function i(e,t){IC(e),r=t,n=!0}}stringify(e,t){this.freeze();let n=hw(t),r=this.compiler||this.Compiler;return dw(`stringify`,r),pw(e),r(e,n)}use(e,...t){let n=this.attachers,r=this.namespace;if(fw(`use`,this.frozen),e!=null){if(typeof e==`function`)s(e,t);else if(typeof e==`object`)Array.isArray(e)?o(e):a(e);else throw TypeError("Expected usable value, not `"+e+"`")}return this;function i(e){if(typeof e==`function`)s(e,[]);else if(typeof e==`object`){if(Array.isArray(e)){let[t,...n]=e;s(t,n)}else a(e)}else throw TypeError("Expected usable value, not `"+e+"`")}function a(e){if(!(`plugins`in e)&&!(`settings`in e))throw Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");o(e.plugins),e.settings&&(r.settings=(0,sw.default)(!0,r.settings,e.settings))}function o(e){let t=-1;if(e!=null){if(Array.isArray(e))for(;++t<e.length;){let n=e[t];i(n)}else throw TypeError("Expected a list of plugins, not `"+e+"`")}}function s(e,t){let r=-1,i=-1;for(;++r<n.length;)if(n[r][0]===e){i=r;break}if(i===-1)n.push([e,...t]);else if(t.length>0){let[r,...a]=t,o=n[i][1];RC(o)&&RC(r)&&(r=(0,sw.default)(!0,o,r)),n[i]=[e,r,...a]}}}}().freeze();function uw(e,t){if(typeof t!=`function`)throw TypeError("Cannot `"+e+"` without `parser`")}function dw(e,t){if(typeof t!=`function`)throw TypeError("Cannot `"+e+"` without `compiler`")}function fw(e,t){if(t)throw Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function pw(e){if(!RC(e)||typeof e.type!=`string`)throw TypeError("Expected node, got `"+e+"`")}function mw(e,t,n){if(!n)throw Error("`"+e+"` finished async. Use `"+t+"` instead")}function hw(e){return gw(e)?e:new tw(e)}function gw(e){return!!(e&&typeof e==`object`&&`message`in e&&`messages`in e)}function _w(e){return typeof e==`string`||vw(e)}function vw(e){return!!(e&&typeof e==`object`&&`byteLength`in e&&`byteOffset`in e)}var yw=[],bw={allowDangerousHtml:!0},xw=/^(https?|ircs?|mailto|xmpp)$/i,Sw=[{from:`astPlugins`,id:`remove-buggy-html-in-markdown-parser`},{from:`allowDangerousHtml`,id:`remove-buggy-html-in-markdown-parser`},{from:`allowNode`,id:`replace-allownode-allowedtypes-and-disallowedtypes`,to:`allowElement`},{from:`allowedTypes`,id:`replace-allownode-allowedtypes-and-disallowedtypes`,to:`allowedElements`},{from:`className`,id:`remove-classname`},{from:`disallowedTypes`,id:`replace-allownode-allowedtypes-and-disallowedtypes`,to:`disallowedElements`},{from:`escapeHtml`,id:`remove-buggy-html-in-markdown-parser`},{from:`includeElementIndex`,id:`#remove-includeelementindex`},{from:`includeNodeIndex`,id:`change-includenodeindex-to-includeelementindex`},{from:`linkTarget`,id:`remove-linktarget`},{from:`plugins`,id:`change-plugins-to-remarkplugins`,to:`remarkPlugins`},{from:`rawSourcePos`,id:`#remove-rawsourcepos`},{from:`renderers`,id:`change-renderers-to-components`,to:`components`},{from:`source`,id:`change-source-to-children`,to:`children`},{from:`sourcePos`,id:`#remove-sourcepos`},{from:`transformImageUri`,id:`#add-urltransform`,to:`urlTransform`},{from:`transformLinkUri`,id:`#add-urltransform`,to:`urlTransform`}];function Cw(e){let t=ww(e),n=Tw(e);return Ew(t.runSync(t.parse(n),n),e)}function ww(e){let t=e.rehypePlugins||yw,n=e.remarkPlugins||yw,r=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...bw}:bw;return lw().use(bS).use(n).use(FC,r).use(t)}function Tw(e){let t=e.children||``,n=new tw;return typeof t==`string`?n.value=t:``+t,n}function Ew(e,t){let n=t.allowedElements,r=t.allowElement,i=t.components,a=t.disallowedElements,o=t.skipHtml,s=t.unwrapDisallowed,c=t.urlTransform||Dw;for(let e of Sw)Object.hasOwn(t,e.from)&&``+e.from+(e.to?"use `"+e.to+"` instead":`remove it`)+e.id;return TC(e,l),$v(e,{Fragment:D.Fragment,components:i,ignoreInvalidStyle:!0,jsx:D.jsx,jsxs:D.jsxs,passKeys:!0,passNode:!0});function l(e,t,i){if(e.type===`raw`&&i&&typeof t==`number`)return o?i.children.splice(t,1):i.children[t]={type:`text`,value:e.value},t;if(e.type===`element`){let t;for(t in xy)if(Object.hasOwn(xy,t)&&Object.hasOwn(e.properties,t)){let n=e.properties[t],r=xy[t];(r===null||r.includes(e.tagName))&&(e.properties[t]=c(String(n||``),t,e))}}if(e.type===`element`){let o=n?!n.includes(e.tagName):a?a.includes(e.tagName):!1;if(!o&&r&&typeof t==`number`&&(o=!r(e,t,i)),o&&i&&typeof t==`number`)return s&&e.children?i.children.splice(t,1,...e.children):i.children.splice(t,1),t}}}function Dw(e){let t=e.indexOf(`:`),n=e.indexOf(`?`),r=e.indexOf(`#`),i=e.indexOf(`/`);return t===-1||i!==-1&&t>i||n!==-1&&t>n||r!==-1&&t>r||xw.test(e.slice(0,t))?e:``}function Ow(e){if(typeof e!=`string`)throw TypeError(`Expected a string`);return e.replace(/[|\\{}()[\]^$+*?.]/g,`\\$&`).replace(/-/g,`\\x2d`)}function kw(e,t,n){let r=mC((n||{}).ignore||[]),i=Aw(t),a=-1;for(;++a<i.length;)CC(e,`text`,o);function o(e,t){let n=-1,i;for(;++n<t.length;){let e=t[n],a=i?i.children:void 0;if(r(e,a?a.indexOf(e):void 0,i))return;i=e}if(i)return s(e,t)}function s(e,t){let n=t[t.length-1],r=i[a][0],o=i[a][1],s=0,c=n.children.indexOf(e),l=!1,u=[];r.lastIndex=0;let d=r.exec(e.value);for(;d;){let n=d.index,i={index:d.index,input:d.input,stack:[...t,e]},a=o(...d,i);if(typeof a==`string`&&(a=a.length>0?{type:`text`,value:a}:void 0),a===!1?r.lastIndex=n+1:(s!==n&&u.push({type:`text`,value:e.value.slice(s,n)}),Array.isArray(a)?u.push(...a):a&&u.push(a),s=n+d[0].length,l=!0),!r.global)break;d=r.exec(e.value)}return l?(s<e.value.length&&u.push({type:`text`,value:e.value.slice(s)}),n.children.splice(c,1,...u)):u=[e],c+u.length}}function Aw(e){let t=[];if(!Array.isArray(e))throw TypeError(`Expected find and replace tuple or list of tuples`);let n=!e[0]||Array.isArray(e[0])?e:[e],r=-1;for(;++r<n.length;){let e=n[r];t.push([jw(e[0]),Mw(e[1])])}return t}function jw(e){return typeof e==`string`?new RegExp(Ow(e),`g`):e}function Mw(e){return typeof e==`function`?e:function(){return e}}var Nw=`phrasing`,Pw=[`autolink`,`link`,`image`,`label`];function Fw(){return{transforms:[Uw],enter:{literalAutolink:Lw,literalAutolinkEmail:Rw,literalAutolinkHttp:Rw,literalAutolinkWww:Rw},exit:{literalAutolink:Hw,literalAutolinkEmail:Vw,literalAutolinkHttp:zw,literalAutolinkWww:Bw}}}function Iw(){return{unsafe:[{character:`@`,before:`[+\\-.\\w]`,after:`[\\-.\\w]`,inConstruct:Nw,notInConstruct:Pw},{character:`.`,before:`[Ww]`,after:`[\\-.\\w]`,inConstruct:Nw,notInConstruct:Pw},{character:`:`,before:`[ps]`,after:`\\/`,inConstruct:Nw,notInConstruct:Pw}]}}function Lw(e){this.enter({type:`link`,title:null,url:``,children:[]},e)}function Rw(e){this.config.enter.autolinkProtocol.call(this,e)}function zw(e){this.config.exit.autolinkProtocol.call(this,e)}function Bw(e){this.config.exit.data.call(this,e);let t=this.stack[this.stack.length-1];t.type,t.url=`http://`+this.sliceSerialize(e)}function Vw(e){this.config.exit.autolinkEmail.call(this,e)}function Hw(e){this.exit(e)}function Uw(e){kw(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,Ww],[/(?<=^|\s|\p{P}|\p{S})([-.\w+]+)@([-\w]+(?:\.[-\w]+)+)/gu,Gw]],{ignore:[`link`,`linkReference`]})}function Ww(e,t,n,r,i){let a=``;if(!Jw(i)||(/^w/i.test(t)&&(n=t+n,t=``,a=`http://`),!Kw(n)))return!1;let o=qw(n+r);if(!o[0])return!1;let s={type:`link`,title:null,url:a+t+o[0],children:[{type:`text`,value:t+o[0]}]};return o[1]?[s,{type:`text`,value:o[1]}]:s}function Gw(e,t,n,r){return!Jw(r,!0)||/[-\d_]$/.test(n)?!1:{type:`link`,title:null,url:`mailto:`+t+`@`+n,children:[{type:`text`,value:t+`@`+n}]}}function Kw(e){let t=e.split(`.`);return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function qw(e){let t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(`)`),i=xa(e,`(`),a=xa(e,`)`);for(;r!==-1&&i>a;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(`)`),a++;return[e,n]}function Jw(e,t){let n=e.input.charCodeAt(e.index-1);return(e.index===0||Ky(n)||Gy(n))&&(!t||n!==47)}iT.peek=rT;function Yw(){this.buffer()}function Xw(e){this.enter({type:`footnoteReference`,identifier:``,label:``},e)}function Zw(){this.buffer()}function Qw(e){this.enter({type:`footnoteDefinition`,identifier:``,label:``,children:[]},e)}function $w(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Iy(this.sliceSerialize(e)).toLowerCase(),n.label=t}function eT(e){this.exit(e)}function tT(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Iy(this.sliceSerialize(e)).toLowerCase(),n.label=t}function nT(e){this.exit(e)}function rT(){return`[`}function iT(e,t,n,r){let i=n.createTracker(r),a=i.move(`[^`),o=n.enter(`footnoteReference`),s=n.enter(`reference`);return a+=i.move(n.safe(n.associationId(e),{after:`]`,before:a})),s(),o(),a+=i.move(`]`),a}function aT(){return{enter:{gfmFootnoteCallString:Yw,gfmFootnoteCall:Xw,gfmFootnoteDefinitionLabelString:Zw,gfmFootnoteDefinition:Qw},exit:{gfmFootnoteCallString:$w,gfmFootnoteCall:eT,gfmFootnoteDefinitionLabelString:tT,gfmFootnoteDefinition:nT}}}function oT(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:iT},unsafe:[{character:`[`,inConstruct:[`label`,`phrasing`,`reference`]}]};function n(e,n,r,i){let a=r.createTracker(i),o=a.move(`[^`),s=r.enter(`footnoteDefinition`),c=r.enter(`label`);return o+=a.move(r.safe(r.associationId(e),{before:o,after:`]`})),c(),o+=a.move(`]:`),e.children&&e.children.length>0&&(a.shift(4),o+=a.move((t?`
|
|
1551
|
+
`:` `)+r.indentLines(r.containerFlow(e,a.current()),t?cT:sT))),s(),o}}function sT(e,t,n){return t===0?e:cT(e,t,n)}function cT(e,t,n){return(n?``:` `)+e}var lT=[`autolink`,`destinationLiteral`,`destinationRaw`,`reference`,`titleQuote`,`titleApostrophe`];mT.peek=hT;function uT(){return{canContainEols:[`delete`],enter:{strikethrough:fT},exit:{strikethrough:pT}}}function dT(){return{unsafe:[{character:`~`,inConstruct:`phrasing`,notInConstruct:lT}],handlers:{delete:mT}}}function fT(e){this.enter({type:`delete`,children:[]},e)}function pT(e){this.exit(e)}function mT(e,t,n,r){let i=n.createTracker(r),a=n.enter(`strikethrough`),o=i.move(`~~`);return o+=n.containerPhrasing(e,{...i.current(),before:o,after:`~`}),o+=i.move(`~~`),a(),o}function hT(){return`~`}function gT(e){return e.length}function _T(e,t){let n=t||{},r=(n.align||[]).concat(),i=n.stringLength||gT,a=[],o=[],s=[],c=[],l=0,u=-1;for(;++u<e.length;){let t=[],r=[],a=-1;for(e[u].length>l&&(l=e[u].length);++a<e[u].length;){let o=vT(e[u][a]);if(n.alignDelimiters!==!1){let e=i(o);r[a]=e,(c[a]===void 0||e>c[a])&&(c[a]=e)}t.push(o)}o[u]=t,s[u]=r}let d=-1;if(typeof r==`object`&&`length`in r)for(;++d<l;)a[d]=yT(r[d]);else{let e=yT(r);for(;++d<l;)a[d]=e}d=-1;let f=[],p=[];for(;++d<l;){let e=a[d],t=``,r=``;e===99?(t=`:`,r=`:`):e===108?t=`:`:e===114&&(r=`:`);let i=n.alignDelimiters===!1?1:Math.max(1,c[d]-t.length-r.length),o=t+`-`.repeat(i)+r;n.alignDelimiters!==!1&&(i=t.length+i+r.length,i>c[d]&&(c[d]=i),p[d]=i),f[d]=o}o.splice(1,0,f),s.splice(1,0,p),u=-1;let m=[];for(;++u<o.length;){let e=o[u],t=s[u];d=-1;let r=[];for(;++d<l;){let i=e[d]||``,o=``,s=``;if(n.alignDelimiters!==!1){let e=c[d]-(t[d]||0),n=a[d];n===114?o=` `.repeat(e):n===99?e%2?(o=` `.repeat(e/2+.5),s=` `.repeat(e/2-.5)):(o=` `.repeat(e/2),s=o):s=` `.repeat(e)}n.delimiterStart!==!1&&!d&&r.push(`|`),n.padding!==!1&&(n.alignDelimiters!==!1||i!==``)&&(n.delimiterStart!==!1||d)&&r.push(` `),n.alignDelimiters!==!1&&r.push(o),r.push(i),n.alignDelimiters!==!1&&r.push(s),n.padding!==!1&&r.push(` `),(n.delimiterEnd!==!1||d!==l-1)&&r.push(`|`)}m.push(n.delimiterEnd===!1?r.join(``).replace(/ +$/,``):r.join(``))}return m.join(`
|
|
1552
|
+
`)}function vT(e){return e==null?``:String(e)}function yT(e){let t=typeof e==`string`?e.codePointAt(0):0;return t===67||t===99?99:t===76||t===108?108:t===82||t===114?114:0}function bT(e,t,n,r){let i=n.enter(`blockquote`),a=n.createTracker(r);a.move(`> `),a.shift(2);let o=n.indentLines(n.containerFlow(e,a.current()),xT);return i(),o}function xT(e,t,n){return`>`+(n?``:` `)+e}function ST(e,t){return CT(e,t.inConstruct,!0)&&!CT(e,t.notInConstruct,!1)}function CT(e,t,n){if(typeof t==`string`&&(t=[t]),!t||t.length===0)return n;let r=-1;for(;++r<t.length;)if(e.includes(t[r]))return!0;return!1}function wT(e,t,n,r){let i=-1;for(;++i<n.unsafe.length;)if(n.unsafe[i].character===`
|
|
1553
|
+
`&&ST(n.stack,n.unsafe[i]))return/[ \t]/.test(r.before)?``:` `;return`\\
|
|
1554
|
+
`}function TT(e,t){let n=String(e),r=n.indexOf(t),i=r,a=0,o=0;if(typeof t!=`string`)throw TypeError(`Expected substring`);for(;r!==-1;)r===i?++a>o&&(o=a):a=1,i=r+t.length,r=n.indexOf(t,i);return o}function ET(e,t){return!!(t.options.fences===!1&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}function DT(e){let t=e.options.fence||"`";if(t!=="`"&&t!==`~`)throw Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}function OT(e,t,n,r){let i=DT(n),a=e.value||``,o=i==="`"?`GraveAccent`:`Tilde`;if(ET(e,n)){let e=n.enter(`codeIndented`),t=n.indentLines(a,kT);return e(),t}let s=n.createTracker(r),c=i.repeat(Math.max(TT(a,i)+1,3)),l=n.enter(`codeFenced`),u=s.move(c);if(e.lang){let t=n.enter(`codeFencedLang${o}`);u+=s.move(n.safe(e.lang,{before:u,after:` `,encode:["`"],...s.current()})),t()}if(e.lang&&e.meta){let t=n.enter(`codeFencedMeta${o}`);u+=s.move(` `),u+=s.move(n.safe(e.meta,{before:u,after:`
|
|
1555
1555
|
`,encode:["`"],...s.current()})),t()}return u+=s.move(`
|
|
1556
1556
|
`),a&&(u+=s.move(a+`
|
|
1557
|
-
`)),u+=s.move(c),l(),u}function
|
|
1558
|
-
`,...c.current()}))),s(),e.title&&(s=n.enter(`title${a}`),l+=c.move(` `+i),l+=c.move(n.safe(e.title,{before:l,after:i,...c.current()})),l+=c.move(i),s()),o(),l}function
|
|
1557
|
+
`)),u+=s.move(c),l(),u}function kT(e,t,n){return(n?``:` `)+e}function AT(e){let t=e.options.quote||`"`;if(t!==`"`&&t!==`'`)throw Error("Cannot serialize title with `"+t+"` for `options.quote`, expected `\"`, or `'`");return t}function jT(e,t,n,r){let i=AT(n),a=i===`"`?`Quote`:`Apostrophe`,o=n.enter(`definition`),s=n.enter(`label`),c=n.createTracker(r),l=c.move(`[`);return l+=c.move(n.safe(n.associationId(e),{before:l,after:`]`,...c.current()})),l+=c.move(`]: `),s(),!e.url||/[\0- \u007F]/.test(e.url)?(s=n.enter(`destinationLiteral`),l+=c.move(`<`),l+=c.move(n.safe(e.url,{before:l,after:`>`,...c.current()})),l+=c.move(`>`)):(s=n.enter(`destinationRaw`),l+=c.move(n.safe(e.url,{before:l,after:e.title?` `:`
|
|
1558
|
+
`,...c.current()}))),s(),e.title&&(s=n.enter(`title${a}`),l+=c.move(` `+i),l+=c.move(n.safe(e.title,{before:l,after:i,...c.current()})),l+=c.move(i),s()),o(),l}function MT(e){let t=e.options.emphasis||`*`;if(t!==`*`&&t!==`_`)throw Error("Cannot serialize emphasis with `"+t+"` for `options.emphasis`, expected `*`, or `_`");return t}function NT(e){return`&#x`+e.toString(16).toUpperCase()+`;`}function PT(e,t,n){let r=tb(e),i=tb(t);return r===void 0?i===void 0?n===`_`?{inside:!0,outside:!0}:{inside:!1,outside:!1}:i===1?{inside:!0,outside:!0}:{inside:!1,outside:!0}:r===1?i===void 0?{inside:!1,outside:!1}:i===1?{inside:!0,outside:!0}:{inside:!1,outside:!1}:i===void 0?{inside:!1,outside:!1}:i===1?{inside:!0,outside:!1}:{inside:!1,outside:!1}}FT.peek=IT;function FT(e,t,n,r){let i=MT(n),a=n.enter(`emphasis`),o=n.createTracker(r),s=o.move(i),c=o.move(n.containerPhrasing(e,{after:i,before:s,...o.current()})),l=c.charCodeAt(0),u=PT(r.before.charCodeAt(r.before.length-1),l,i);u.inside&&(c=NT(l)+c.slice(1));let d=c.charCodeAt(c.length-1),f=PT(r.after.charCodeAt(0),d,i);f.inside&&(c=c.slice(0,-1)+NT(d));let p=o.move(i);return a(),n.attentionEncodeSurroundingInfo={after:f.outside,before:u.outside},s+c+p}function IT(e,t,n){return n.options.emphasis||`*`}function LT(e,t){let n=!1;return TC(e,function(e){if(`value`in e&&/\r?\n|\r/.test(e.value)||e.type===`break`)return n=!0,!1}),!!((!e.depth||e.depth<3)&&Cy(e)&&(t.options.setext||n))}function RT(e,t,n,r){let i=Math.max(Math.min(6,e.depth||1),1),a=n.createTracker(r);if(LT(e,n)){let t=n.enter(`headingSetext`),r=n.enter(`phrasing`),o=n.containerPhrasing(e,{...a.current(),before:`
|
|
1559
1559
|
`,after:`
|
|
1560
1560
|
`});return r(),t(),o+`
|
|
1561
1561
|
`+(i===1?`=`:`-`).repeat(o.length-(Math.max(o.lastIndexOf(`\r`),o.lastIndexOf(`
|
|
1562
1562
|
`))+1))}let o=`#`.repeat(i),s=n.enter(`headingAtx`),c=n.enter(`phrasing`);a.move(o+` `);let l=n.containerPhrasing(e,{before:`# `,after:`
|
|
1563
|
-
`,...a.current()});return/^[\t ]/.test(l)&&(l=
|
|
1563
|
+
`,...a.current()});return/^[\t ]/.test(l)&&(l=NT(l.charCodeAt(0))+l.slice(1)),l=l?o+` `+l:o,n.options.closeAtx&&(l+=` `+o),c(),s(),l}zT.peek=BT;function zT(e){return e.value||``}function BT(){return`<`}VT.peek=HT;function VT(e,t,n,r){let i=AT(n),a=i===`"`?`Quote`:`Apostrophe`,o=n.enter(`image`),s=n.enter(`label`),c=n.createTracker(r),l=c.move(`![`);return l+=c.move(n.safe(e.alt,{before:l,after:`]`,...c.current()})),l+=c.move(`](`),s(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(s=n.enter(`destinationLiteral`),l+=c.move(`<`),l+=c.move(n.safe(e.url,{before:l,after:`>`,...c.current()})),l+=c.move(`>`)):(s=n.enter(`destinationRaw`),l+=c.move(n.safe(e.url,{before:l,after:e.title?` `:`)`,...c.current()}))),s(),e.title&&(s=n.enter(`title${a}`),l+=c.move(` `+i),l+=c.move(n.safe(e.title,{before:l,after:i,...c.current()})),l+=c.move(i),s()),l+=c.move(`)`),o(),l}function HT(){return`!`}UT.peek=WT;function UT(e,t,n,r){let i=e.referenceType,a=n.enter(`imageReference`),o=n.enter(`label`),s=n.createTracker(r),c=s.move(`![`),l=n.safe(e.alt,{before:c,after:`]`,...s.current()});c+=s.move(l+`][`),o();let u=n.stack;n.stack=[],o=n.enter(`reference`);let d=n.safe(n.associationId(e),{before:c,after:`]`,...s.current()});return o(),n.stack=u,a(),i===`full`||!l||l!==d?c+=s.move(d+`]`):i===`shortcut`?c=c.slice(0,-1):c+=s.move(`]`),c}function WT(){return`!`}GT.peek=KT;function GT(e,t,n){let r=e.value||``,i="`",a=-1;for(;RegExp("(^|[^`])"+i+"([^`]|$)").test(r);)i+="`";for(/[^ \r\n]/.test(r)&&(/^[ \r\n]/.test(r)&&/[ \r\n]$/.test(r)||/^`|`$/.test(r))&&(r=` `+r+` `);++a<n.unsafe.length;){let e=n.unsafe[a],t=n.compilePattern(e),i;if(e.atBreak)for(;i=t.exec(r);){let e=i.index;r.charCodeAt(e)===10&&r.charCodeAt(e-1)===13&&e--,r=r.slice(0,e)+` `+r.slice(i.index+1)}}return i+r+i}function KT(){return"`"}function qT(e,t){let n=Cy(e);return!!(!t.options.resourceLink&&e.url&&!e.title&&e.children&&e.children.length===1&&e.children[0].type===`text`&&(n===e.url||`mailto:`+n===e.url)&&/^[a-z][a-z+.-]+:/i.test(e.url)&&!/[\0- <>\u007F]/.test(e.url))}JT.peek=YT;function JT(e,t,n,r){let i=AT(n),a=i===`"`?`Quote`:`Apostrophe`,o=n.createTracker(r),s,c;if(qT(e,n)){let t=n.stack;n.stack=[],s=n.enter(`autolink`);let r=o.move(`<`);return r+=o.move(n.containerPhrasing(e,{before:r,after:`>`,...o.current()})),r+=o.move(`>`),s(),n.stack=t,r}s=n.enter(`link`),c=n.enter(`label`);let l=o.move(`[`);return l+=o.move(n.containerPhrasing(e,{before:l,after:`](`,...o.current()})),l+=o.move(`](`),c(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(c=n.enter(`destinationLiteral`),l+=o.move(`<`),l+=o.move(n.safe(e.url,{before:l,after:`>`,...o.current()})),l+=o.move(`>`)):(c=n.enter(`destinationRaw`),l+=o.move(n.safe(e.url,{before:l,after:e.title?` `:`)`,...o.current()}))),c(),e.title&&(c=n.enter(`title${a}`),l+=o.move(` `+i),l+=o.move(n.safe(e.title,{before:l,after:i,...o.current()})),l+=o.move(i),c()),l+=o.move(`)`),s(),l}function YT(e,t,n){return qT(e,n)?`<`:`[`}XT.peek=ZT;function XT(e,t,n,r){let i=e.referenceType,a=n.enter(`linkReference`),o=n.enter(`label`),s=n.createTracker(r),c=s.move(`[`),l=n.containerPhrasing(e,{before:c,after:`]`,...s.current()});c+=s.move(l+`][`),o();let u=n.stack;n.stack=[],o=n.enter(`reference`);let d=n.safe(n.associationId(e),{before:c,after:`]`,...s.current()});return o(),n.stack=u,a(),i===`full`||!l||l!==d?c+=s.move(d+`]`):i===`shortcut`?c=c.slice(0,-1):c+=s.move(`]`),c}function ZT(){return`[`}function QT(e){let t=e.options.bullet||`*`;if(t!==`*`&&t!==`+`&&t!==`-`)throw Error("Cannot serialize items with `"+t+"` for `options.bullet`, expected `*`, `+`, or `-`");return t}function $T(e){let t=QT(e),n=e.options.bulletOther;if(!n)return t===`*`?`-`:`*`;if(n!==`*`&&n!==`+`&&n!==`-`)throw Error("Cannot serialize items with `"+n+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(n===t)throw Error("Expected `bullet` (`"+t+"`) and `bulletOther` (`"+n+"`) to be different");return n}function eE(e){let t=e.options.bulletOrdered||`.`;if(t!==`.`&&t!==`)`)throw Error("Cannot serialize items with `"+t+"` for `options.bulletOrdered`, expected `.` or `)`");return t}function tE(e){let t=e.options.rule||`*`;if(t!==`*`&&t!==`-`&&t!==`_`)throw Error("Cannot serialize rules with `"+t+"` for `options.rule`, expected `*`, `-`, or `_`");return t}function nE(e,t,n,r){let i=n.enter(`list`),a=n.bulletCurrent,o=e.ordered?eE(n):QT(n),s=e.ordered?o===`.`?`)`:`.`:$T(n),c=t&&n.bulletLastUsed?o===n.bulletLastUsed:!1;if(!e.ordered){let t=e.children?e.children[0]:void 0;if((o===`*`||o===`-`)&&t&&(!t.children||!t.children[0])&&n.stack[n.stack.length-1]===`list`&&n.stack[n.stack.length-2]===`listItem`&&n.stack[n.stack.length-3]===`list`&&n.stack[n.stack.length-4]===`listItem`&&n.indexStack[n.indexStack.length-1]===0&&n.indexStack[n.indexStack.length-2]===0&&n.indexStack[n.indexStack.length-3]===0&&(c=!0),tE(n)===o&&t){let t=-1;for(;++t<e.children.length;){let n=e.children[t];if(n&&n.type===`listItem`&&n.children&&n.children[0]&&n.children[0].type===`thematicBreak`){c=!0;break}}}}c&&(o=s),n.bulletCurrent=o;let l=n.containerFlow(e,r);return n.bulletLastUsed=o,n.bulletCurrent=a,i(),l}function rE(e){let t=e.options.listItemIndent||`one`;if(t!==`tab`&&t!==`one`&&t!==`mixed`)throw Error("Cannot serialize items with `"+t+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return t}function iE(e,t,n,r){let i=rE(n),a=n.bulletCurrent||QT(n);t&&t.type===`list`&&t.ordered&&(a=(typeof t.start==`number`&&t.start>-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+a);let o=a.length+1;(i===`tab`||i===`mixed`&&(t&&t.type===`list`&&t.spread||e.spread))&&(o=Math.ceil(o/4)*4);let s=n.createTracker(r);s.move(a+` `.repeat(o-a.length)),s.shift(o);let c=n.enter(`listItem`),l=n.indentLines(n.containerFlow(e,s.current()),u);return c(),l;function u(e,t,n){return t?(n?``:` `.repeat(o))+e:(n?a:a+` `.repeat(o-a.length))+e}}function aE(e,t,n,r){let i=n.enter(`paragraph`),a=n.enter(`phrasing`),o=n.containerPhrasing(e,r);return a(),i(),o}var oE=mC([`break`,`delete`,`emphasis`,`footnote`,`footnoteReference`,`image`,`imageReference`,`inlineCode`,`inlineMath`,`link`,`linkReference`,`mdxJsxTextElement`,`mdxTextExpression`,`strong`,`text`,`textDirective`]);function sE(e,t,n,r){return(e.children.some(function(e){return oE(e)})?n.containerPhrasing:n.containerFlow).call(n,e,r)}function cE(e){let t=e.options.strong||`*`;if(t!==`*`&&t!==`_`)throw Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}lE.peek=uE;function lE(e,t,n,r){let i=cE(n),a=n.enter(`strong`),o=n.createTracker(r),s=o.move(i+i),c=o.move(n.containerPhrasing(e,{after:i,before:s,...o.current()})),l=c.charCodeAt(0),u=PT(r.before.charCodeAt(r.before.length-1),l,i);u.inside&&(c=NT(l)+c.slice(1));let d=c.charCodeAt(c.length-1),f=PT(r.after.charCodeAt(0),d,i);f.inside&&(c=c.slice(0,-1)+NT(d));let p=o.move(i+i);return a(),n.attentionEncodeSurroundingInfo={after:f.outside,before:u.outside},s+c+p}function uE(e,t,n){return n.options.strong||`*`}function dE(e,t,n,r){return n.safe(e.value,r)}function fE(e){let t=e.options.ruleRepetition||3;if(t<3)throw Error("Cannot serialize rules with repetition `"+t+"` for `options.ruleRepetition`, expected `3` or more");return t}function pE(e,t,n){let r=(tE(n)+(n.options.ruleSpaces?` `:``)).repeat(fE(n));return n.options.ruleSpaces?r.slice(0,-1):r}var mE={blockquote:bT,break:wT,code:OT,definition:jT,emphasis:FT,hardBreak:wT,heading:RT,html:zT,image:VT,imageReference:UT,inlineCode:GT,link:JT,linkReference:XT,list:nE,listItem:iE,paragraph:aE,root:sE,strong:lE,text:dE,thematicBreak:pE};function hE(){return{enter:{table:gE,tableData:bE,tableHeader:bE,tableRow:vE},exit:{codeText:xE,table:_E,tableData:yE,tableHeader:yE,tableRow:yE}}}function gE(e){let t=e._align;this.enter({type:`table`,align:t.map(function(e){return e===`none`?null:e}),children:[]},e),this.data.inTable=!0}function _E(e){this.exit(e),this.data.inTable=void 0}function vE(e){this.enter({type:`tableRow`,children:[]},e)}function yE(e){this.exit(e)}function bE(e){this.enter({type:`tableCell`,children:[]},e)}function xE(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,SE));let n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function SE(e,t){return t===`|`?t:e}function CE(e){let t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,i=t.stringLength,a=n?` `:`|`;return{unsafe:[{character:`\r`,inConstruct:`tableCell`},{character:`
|
|
1564
1564
|
`,inConstruct:`tableCell`},{atBreak:!0,character:`|`,after:`[ :-]`},{character:`|`,inConstruct:`tableCell`},{atBreak:!0,character:`:`,after:`-`},{atBreak:!0,character:`-`,after:`[:|-]`}],handlers:{inlineCode:f,table:o,tableCell:c,tableRow:s}};function o(e,t,n,r){return l(u(e,n,r),e.align)}function s(e,t,n,r){let i=l([d(e,n,r)]);return i.slice(0,i.indexOf(`
|
|
1565
|
-
`))}function c(e,t,n,r){let i=n.enter(`tableCell`),o=n.enter(`phrasing`),s=n.containerPhrasing(e,{...r,before:a,after:a});return o(),i(),s}function l(e,t){return gT(e,{align:t,alignDelimiters:r,padding:n,stringLength:i})}function u(e,t,n){let r=e.children,i=-1,a=[],o=t.enter(`table`);for(;++i<r.length;)a[i]=d(r[i],t,n);return o(),a}function d(e,t,n){let r=e.children,i=-1,a=[],o=t.enter(`tableRow`);for(;++i<r.length;)a[i]=c(r[i],e,t,n);return o(),a}function f(e,t,n){let r=pE.inlineCode(e,t,n);return n.stack.includes(`tableCell`)&&(r=r.replace(/\|/g,`\\$&`)),r}}function CE(){return{exit:{taskListCheckValueChecked:TE,taskListCheckValueUnchecked:TE,paragraph:EE}}}function wE(){return{unsafe:[{atBreak:!0,character:`-`,after:`[:|-]`}],handlers:{listItem:DE}}}function TE(e){let t=this.stack[this.stack.length-2];t.type,t.checked=e.type===`taskListCheckValueChecked`}function EE(e){let t=this.stack[this.stack.length-2];if(t&&t.type===`listItem`&&typeof t.checked==`boolean`){let e=this.stack[this.stack.length-1];e.type;let n=e.children[0];if(n&&n.type===`text`){let r=t.children,i=-1,a;for(;++i<r.length;){let e=r[i];if(e.type===`paragraph`){a=e;break}}a===e&&(n.value=n.value.slice(1),n.value.length===0?e.children.shift():e.position&&n.position&&typeof n.position.start.offset==`number`&&(n.position.start.column++,n.position.start.offset++,e.position.start=Object.assign({},n.position.start)))}}this.exit(e)}function DE(e,t,n,r){let i=e.children[0],a=typeof e.checked==`boolean`&&i&&i.type===`paragraph`,o=`[`+(e.checked?`x`:` `)+`] `,s=n.createTracker(r);a&&s.move(o);let c=pE.listItem(e,t,n,{...r,...s.current()});return a&&(c=c.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,l)),c;function l(e){return e+o}}function OE(){return[Pw(),iT(),lT(),mE(),CE()]}function kE(e){return{extensions:[Fw(),aT(e),uT(),SE(e),wE()]}}var AE={tokenize:WE,partial:!0},jE={tokenize:GE,partial:!0},ME={tokenize:KE,partial:!0},NE={tokenize:qE,partial:!0},PE={tokenize:JE,partial:!0},FE={name:`wwwAutolink`,tokenize:HE,previous:YE},IE={name:`protocolAutolink`,tokenize:UE,previous:XE},LE={name:`emailAutolink`,tokenize:VE,previous:ZE},RE={};function zE(){return{text:RE}}for(var BE=48;BE<123;)RE[BE]=LE,BE++,BE===58?BE=65:BE===91&&(BE=97);RE[43]=LE,RE[45]=LE,RE[46]=LE,RE[95]=LE,RE[72]=[LE,IE],RE[104]=[LE,IE],RE[87]=[LE,FE],RE[119]=[LE,FE];function VE(e,t,n){let r=this,i,a;return o;function o(t){return!QE(t)||!ZE.call(r,r.previous)||$E(r.events)?n(t):(e.enter(`literalAutolink`),e.enter(`literalAutolinkEmail`),s(t))}function s(t){return QE(t)?(e.consume(t),s):t===64?(e.consume(t),c):n(t)}function c(t){return t===46?e.check(PE,u,l)(t):t===45||t===95||Ly(t)?(a=!0,e.consume(t),c):u(t)}function l(t){return e.consume(t),i=!0,c}function u(o){return a&&i&&Iy(r.previous)?(e.exit(`literalAutolinkEmail`),e.exit(`literalAutolink`),t(o)):n(o)}}function HE(e,t,n){let r=this;return i;function i(t){return t!==87&&t!==119||!YE.call(r,r.previous)||$E(r.events)?n(t):(e.enter(`literalAutolink`),e.enter(`literalAutolinkWww`),e.check(AE,e.attempt(jE,e.attempt(ME,a),n),n)(t))}function a(n){return e.exit(`literalAutolinkWww`),e.exit(`literalAutolink`),t(n)}}function UE(e,t,n){let r=this,i=``,a=!1;return o;function o(t){return(t===72||t===104)&&XE.call(r,r.previous)&&!$E(r.events)?(e.enter(`literalAutolink`),e.enter(`literalAutolinkHttp`),i+=String.fromCodePoint(t),e.consume(t),s):n(t)}function s(t){if(Iy(t)&&i.length<5)return i+=String.fromCodePoint(t),e.consume(t),s;if(t===58){let n=i.toLowerCase();if(n===`http`||n===`https`)return e.consume(t),c}return n(t)}function c(t){return t===47?(e.consume(t),a?l:(a=!0,c)):n(t)}function l(t){return t===null||zy(t)||Uy(t)||Gy(t)||Wy(t)?n(t):e.attempt(jE,e.attempt(ME,u),n)(t)}function u(n){return e.exit(`literalAutolinkHttp`),e.exit(`literalAutolink`),t(n)}}function WE(e,t,n){let r=0;return i;function i(t){return(t===87||t===119)&&r<3?(r++,e.consume(t),i):t===46&&r===3?(e.consume(t),a):n(t)}function a(e){return e===null?n(e):t(e)}}function GE(e,t,n){let r,i,a;return o;function o(t){return t===46||t===95?e.check(NE,c,s)(t):t===null||Uy(t)||Gy(t)||t!==45&&Wy(t)?c(t):(a=!0,e.consume(t),o)}function s(t){return t===95?r=!0:(i=r,r=void 0),e.consume(t),o}function c(e){return i||r||!a?n(e):t(e)}}function KE(e,t){let n=0,r=0;return i;function i(o){return o===40?(n++,e.consume(o),i):o===41&&r<n?a(o):o===33||o===34||o===38||o===39||o===41||o===42||o===44||o===46||o===58||o===59||o===60||o===63||o===93||o===95||o===126?e.check(NE,t,a)(o):o===null||Uy(o)||Gy(o)?t(o):(e.consume(o),i)}function a(t){return t===41&&r++,e.consume(t),i}}function qE(e,t,n){return r;function r(o){return o===33||o===34||o===39||o===41||o===42||o===44||o===46||o===58||o===59||o===63||o===95||o===126?(e.consume(o),r):o===38?(e.consume(o),a):o===93?(e.consume(o),i):o===60||o===null||Uy(o)||Gy(o)?t(o):n(o)}function i(e){return e===null||e===40||e===91||Uy(e)||Gy(e)?t(e):r(e)}function a(e){return Iy(e)?o(e):n(e)}function o(t){return t===59?(e.consume(t),r):Iy(t)?(e.consume(t),o):n(t)}}function JE(e,t,n){return r;function r(t){return e.consume(t),i}function i(e){return Ly(e)?n(e):t(e)}}function YE(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||Uy(e)}function XE(e){return!Iy(e)}function ZE(e){return!(e===47||QE(e))}function QE(e){return e===43||e===45||e===46||e===95||Ly(e)}function $E(e){let t=e.length,n=!1;for(;t--;){let r=e[t][1];if((r.type===`labelLink`||r.type===`labelImage`)&&!r._balanced){n=!0;break}if(r._gfmAutolinkLiteralWalkedInto){n=!1;break}}return e.length>0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}var eD={tokenize:cD,partial:!0};function tD(){return{document:{91:{name:`gfmFootnoteDefinition`,tokenize:aD,continuation:{tokenize:oD},exit:sD}},text:{91:{name:`gfmFootnoteCall`,tokenize:iD},93:{name:`gfmPotentialFootnoteCall`,add:`after`,tokenize:nD,resolveTo:rD}}}}function nD(e,t,n){let r=this,i=r.events.length,a=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]),o;for(;i--;){let e=r.events[i][1];if(e.type===`labelImage`){o=e;break}if(e.type===`gfmFootnoteCall`||e.type===`labelLink`||e.type===`label`||e.type===`image`||e.type===`link`)break}return s;function s(i){if(!o||!o._balanced)return n(i);let s=Fy(r.sliceSerialize({start:o.end,end:r.now()}));return s.codePointAt(0)!==94||!a.includes(s.slice(1))?n(i):(e.enter(`gfmFootnoteCallLabelMarker`),e.consume(i),e.exit(`gfmFootnoteCallLabelMarker`),t(i))}}function rD(e,t){let n=e.length;for(;n--;)if(e[n][1].type===`labelImage`&&e[n][0]===`enter`){e[n][1];break}e[n+1][1].type=`data`,e[n+3][1].type=`gfmFootnoteCallLabelMarker`;let r={type:`gfmFootnoteCall`,start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},i={type:`gfmFootnoteCallMarker`,start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};i.end.column++,i.end.offset++,i.end._bufferIndex++;let a={type:`gfmFootnoteCallString`,start:Object.assign({},i.end),end:Object.assign({},e[e.length-1][1].start)},o={type:`chunkString`,contentType:`string`,start:Object.assign({},a.start),end:Object.assign({},a.end)},s=[e[n+1],e[n+2],[`enter`,r,t],e[n+3],e[n+4],[`enter`,i,t],[`exit`,i,t],[`enter`,a,t],[`enter`,o,t],[`exit`,o,t],[`exit`,a,t],e[e.length-2],e[e.length-1],[`exit`,r,t]];return e.splice(n,e.length-n+1,...s),e}function iD(e,t,n){let r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]),a=0,o;return s;function s(t){return e.enter(`gfmFootnoteCall`),e.enter(`gfmFootnoteCallLabelMarker`),e.consume(t),e.exit(`gfmFootnoteCallLabelMarker`),c}function c(t){return t===94?(e.enter(`gfmFootnoteCallMarker`),e.consume(t),e.exit(`gfmFootnoteCallMarker`),e.enter(`gfmFootnoteCallString`),e.enter(`chunkString`).contentType=`string`,l):n(t)}function l(s){if(a>999||s===93&&!o||s===null||s===91||Uy(s))return n(s);if(s===93){e.exit(`chunkString`);let a=e.exit(`gfmFootnoteCallString`);return i.includes(Fy(r.sliceSerialize(a)))?(e.enter(`gfmFootnoteCallLabelMarker`),e.consume(s),e.exit(`gfmFootnoteCallLabelMarker`),e.exit(`gfmFootnoteCall`),t):n(s)}return Uy(s)||(o=!0),a++,e.consume(s),s===92?u:l}function u(t){return t===91||t===92||t===93?(e.consume(t),a++,l):l(t)}}function aD(e,t,n){let r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]),a,o=0,s;return c;function c(t){return e.enter(`gfmFootnoteDefinition`)._container=!0,e.enter(`gfmFootnoteDefinitionLabel`),e.enter(`gfmFootnoteDefinitionLabelMarker`),e.consume(t),e.exit(`gfmFootnoteDefinitionLabelMarker`),l}function l(t){return t===94?(e.enter(`gfmFootnoteDefinitionMarker`),e.consume(t),e.exit(`gfmFootnoteDefinitionMarker`),e.enter(`gfmFootnoteDefinitionLabelString`),e.enter(`chunkString`).contentType=`string`,u):n(t)}function u(t){if(o>999||t===93&&!s||t===null||t===91||Uy(t))return n(t);if(t===93){e.exit(`chunkString`);let n=e.exit(`gfmFootnoteDefinitionLabelString`);return a=Fy(r.sliceSerialize(n)),e.enter(`gfmFootnoteDefinitionLabelMarker`),e.consume(t),e.exit(`gfmFootnoteDefinitionLabelMarker`),e.exit(`gfmFootnoteDefinitionLabel`),f}return Uy(t)||(s=!0),o++,e.consume(t),t===92?d:u}function d(t){return t===91||t===92||t===93?(e.consume(t),o++,u):u(t)}function f(t){return t===58?(e.enter(`definitionMarker`),e.consume(t),e.exit(`definitionMarker`),i.includes(a)||i.push(a),$(e,p,`gfmFootnoteDefinitionWhitespace`)):n(t)}function p(e){return t(e)}}function oD(e,t,n){return e.check(cb,t,e.attempt(eD,t,n))}function sD(e){e.exit(`gfmFootnoteDefinition`)}function cD(e,t,n){let r=this;return $(e,i,`gfmFootnoteDefinitionIndent`,5);function i(e){let i=r.events[r.events.length-1];return i&&i[1].type===`gfmFootnoteDefinitionIndent`&&i[2].sliceSerialize(i[1],!0).length===4?t(e):n(e)}}function lD(e){let t=(e||{}).singleTilde,n={name:`strikethrough`,tokenize:i,resolveAll:r};return t??=!0,{text:{126:n},insideSpan:{null:[n]},attentionMarkers:{null:[126]}};function r(e,t){let n=-1;for(;++n<e.length;)if(e[n][0]===`enter`&&e[n][1].type===`strikethroughSequenceTemporary`&&e[n][1]._close){let r=n;for(;r--;)if(e[r][0]===`exit`&&e[r][1].type===`strikethroughSequenceTemporary`&&e[r][1]._open&&e[n][1].end.offset-e[n][1].start.offset===e[r][1].end.offset-e[r][1].start.offset){e[n][1].type=`strikethroughSequence`,e[r][1].type=`strikethroughSequence`;let i={type:`strikethrough`,start:Object.assign({},e[r][1].start),end:Object.assign({},e[n][1].end)},a={type:`strikethroughText`,start:Object.assign({},e[r][1].end),end:Object.assign({},e[n][1].start)},o=[[`enter`,i,t],[`enter`,e[r][1],t],[`exit`,e[r][1],t],[`enter`,a,t]],s=t.parser.constructs.insideSpan.null;s&&Oy(o,o.length,0,tb(s,e.slice(r+1,n),t)),Oy(o,o.length,0,[[`exit`,a,t],[`enter`,e[n][1],t],[`exit`,e[n][1],t],[`exit`,i,t]]),Oy(e,r-1,n-r+3,o),n=r+o.length-2;break}}for(n=-1;++n<e.length;)e[n][1].type===`strikethroughSequenceTemporary`&&(e[n][1].type=`data`);return e}function i(e,n,r){let i=this.previous,a=this.events,o=0;return s;function s(t){return i===126&&a[a.length-1][1].type!==`characterEscape`?r(t):(e.enter(`strikethroughSequenceTemporary`),c(t))}function c(a){let s=eb(i);if(a===126)return o>1?r(a):(e.consume(a),o++,c);if(o<2&&!t)return r(a);let l=e.exit(`strikethroughSequenceTemporary`),u=eb(a);return l._open=!u||u===2&&!!s,l._close=!s||s===2&&!!u,n(a)}}}var uD=class{constructor(){this.map=[]}add(e,t,n){dD(this,e,t,n)}consume(e){if(this.map.sort(function(e,t){return e[0]-t[0]}),this.map.length===0)return;let t=this.map.length,n=[];for(;t>0;)--t,n.push(e.slice(this.map[t][0]+this.map[t][1]),this.map[t][2]),e.length=this.map[t][0];n.push(e.slice()),e.length=0;let r=n.pop();for(;r;){for(let t of r)e.push(t);r=n.pop()}this.map.length=0}};function dD(e,t,n,r){let i=0;if(n!==0||r.length!==0){for(;i<e.map.length;){if(e.map[i][0]===t){e.map[i][1]+=n,e.map[i][2].push(...r);return}i+=1}e.map.push([t,n,r])}}function fD(e,t){let n=!1,r=[];for(;t<e.length;){let i=e[t];if(n){if(i[0]===`enter`)i[1].type===`tableContent`&&r.push(e[t+1][1].type===`tableDelimiterMarker`?`left`:`none`);else if(i[1].type===`tableContent`){if(e[t-1][1].type===`tableDelimiterMarker`){let e=r.length-1;r[e]=r[e]===`left`?`center`:`right`}}else if(i[1].type===`tableDelimiterRow`)break}else i[0]===`enter`&&i[1].type===`tableDelimiterRow`&&(n=!0);t+=1}return r}function pD(){return{flow:{null:{name:`table`,tokenize:mD,resolveAll:hD}}}}function mD(e,t,n){let r=this,i=0,a=0,o;return s;function s(e){let t=r.events.length-1;for(;t>-1;){let e=r.events[t][1].type;if(e===`lineEnding`||e===`linePrefix`)t--;else break}let i=t>-1?r.events[t][1].type:null,a=i===`tableHead`||i===`tableRow`?S:c;return a===S&&r.parser.lazy[r.now().line]?n(e):a(e)}function c(t){return e.enter(`tableHead`),e.enter(`tableRow`),l(t)}function l(e){return e===124?u(e):(o=!0,a+=1,u(e))}function u(t){return t===null?n(t):Z(t)?a>1?(a=0,r.interrupt=!0,e.exit(`tableRow`),e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),p):n(t):Q(t)?$(e,u,`whitespace`)(t):(a+=1,o&&(o=!1,i+=1),t===124?(e.enter(`tableCellDivider`),e.consume(t),e.exit(`tableCellDivider`),o=!0,u):(e.enter(`data`),d(t)))}function d(t){return t===null||t===124||Uy(t)?(e.exit(`data`),u(t)):(e.consume(t),t===92?f:d)}function f(t){return t===92||t===124?(e.consume(t),d):d(t)}function p(t){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(t):(e.enter(`tableDelimiterRow`),o=!1,Q(t)?$(e,m,`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(t):m(t))}function m(t){return t===45||t===58?g(t):t===124?(o=!0,e.enter(`tableCellDivider`),e.consume(t),e.exit(`tableCellDivider`),h):x(t)}function h(t){return Q(t)?$(e,g,`whitespace`)(t):g(t)}function g(t){return t===58?(a+=1,o=!0,e.enter(`tableDelimiterMarker`),e.consume(t),e.exit(`tableDelimiterMarker`),_):t===45?(a+=1,_(t)):t===null||Z(t)?b(t):x(t)}function _(t){return t===45?(e.enter(`tableDelimiterFiller`),v(t)):x(t)}function v(t){return t===45?(e.consume(t),v):t===58?(o=!0,e.exit(`tableDelimiterFiller`),e.enter(`tableDelimiterMarker`),e.consume(t),e.exit(`tableDelimiterMarker`),y):(e.exit(`tableDelimiterFiller`),y(t))}function y(t){return Q(t)?$(e,b,`whitespace`)(t):b(t)}function b(n){return n===124?m(n):n===null||Z(n)?!o||i!==a?x(n):(e.exit(`tableDelimiterRow`),e.exit(`tableHead`),t(n)):x(n)}function x(e){return n(e)}function S(t){return e.enter(`tableRow`),C(t)}function C(n){return n===124?(e.enter(`tableCellDivider`),e.consume(n),e.exit(`tableCellDivider`),C):n===null||Z(n)?(e.exit(`tableRow`),t(n)):Q(n)?$(e,C,`whitespace`)(n):(e.enter(`data`),w(n))}function w(t){return t===null||t===124||Uy(t)?(e.exit(`data`),C(t)):(e.consume(t),t===92?T:w)}function T(t){return t===92||t===124?(e.consume(t),w):w(t)}}function hD(e,t){let n=-1,r=!0,i=0,a=[0,0,0,0],o=[0,0,0,0],s=!1,c=0,l,u,d,f=new uD;for(;++n<e.length;){let p=e[n],m=p[1];p[0]===`enter`?m.type===`tableHead`?(s=!1,c!==0&&(_D(f,t,c,l,u),u=void 0,c=0),l={type:`table`,start:Object.assign({},m.start),end:Object.assign({},m.end)},f.add(n,0,[[`enter`,l,t]])):m.type===`tableRow`||m.type===`tableDelimiterRow`?(r=!0,d=void 0,a=[0,0,0,0],o=[0,n+1,0,0],s&&(s=!1,u={type:`tableBody`,start:Object.assign({},m.start),end:Object.assign({},m.end)},f.add(n,0,[[`enter`,u,t]])),i=m.type===`tableDelimiterRow`?2:u?3:1):i&&(m.type===`data`||m.type===`tableDelimiterMarker`||m.type===`tableDelimiterFiller`)?(r=!1,o[2]===0&&(a[1]!==0&&(o[0]=o[1],d=gD(f,t,a,i,void 0,d),a=[0,0,0,0]),o[2]=n)):m.type===`tableCellDivider`&&(r?r=!1:(a[1]!==0&&(o[0]=o[1],d=gD(f,t,a,i,void 0,d)),a=o,o=[a[1],n,0,0])):m.type===`tableHead`?(s=!0,c=n):m.type===`tableRow`||m.type===`tableDelimiterRow`?(c=n,a[1]===0?o[1]!==0&&(d=gD(f,t,o,i,n,d)):(o[0]=o[1],d=gD(f,t,a,i,n,d)),i=0):i&&(m.type===`data`||m.type===`tableDelimiterMarker`||m.type===`tableDelimiterFiller`)&&(o[3]=n)}for(c!==0&&_D(f,t,c,l,u),f.consume(t.events),n=-1;++n<t.events.length;){let e=t.events[n];e[0]===`enter`&&e[1].type===`table`&&(e[1]._align=fD(t.events,n))}return e}function gD(e,t,n,r,i,a){let o=r===1?`tableHeader`:r===2?`tableDelimiter`:`tableData`;n[0]!==0&&(a.end=Object.assign({},vD(t.events,n[0])),e.add(n[0],0,[[`exit`,a,t]]));let s=vD(t.events,n[1]);if(a={type:o,start:Object.assign({},s),end:Object.assign({},s)},e.add(n[1],0,[[`enter`,a,t]]),n[2]!==0){let i=vD(t.events,n[2]),a=vD(t.events,n[3]),o={type:`tableContent`,start:Object.assign({},i),end:Object.assign({},a)};if(e.add(n[2],0,[[`enter`,o,t]]),r!==2){let r=t.events[n[2]],i=t.events[n[3]];if(r[1].end=Object.assign({},i[1].end),r[1].type=`chunkText`,r[1].contentType=`text`,n[3]>n[2]+1){let t=n[2]+1,r=n[3]-n[2]-1;e.add(t,r,[])}}e.add(n[3]+1,0,[[`exit`,o,t]])}return i!==void 0&&(a.end=Object.assign({},vD(t.events,i)),e.add(i,0,[[`exit`,a,t]]),a=void 0),a}function _D(e,t,n,r,i){let a=[],o=vD(t.events,n);i&&(i.end=Object.assign({},o),a.push([`exit`,i,t])),r.end=Object.assign({},o),a.push([`exit`,r,t]),e.add(n+1,0,a)}function vD(e,t){let n=e[t],r=n[0]===`enter`?`start`:`end`;return n[1][r]}var yD={name:`tasklistCheck`,tokenize:xD};function bD(){return{text:{91:yD}}}function xD(e,t,n){let r=this;return i;function i(t){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(t):(e.enter(`taskListCheck`),e.enter(`taskListCheckMarker`),e.consume(t),e.exit(`taskListCheckMarker`),a)}function a(t){return Uy(t)?(e.enter(`taskListCheckValueUnchecked`),e.consume(t),e.exit(`taskListCheckValueUnchecked`),o):t===88||t===120?(e.enter(`taskListCheckValueChecked`),e.consume(t),e.exit(`taskListCheckValueChecked`),o):n(t)}function o(t){return t===93?(e.enter(`taskListCheckMarker`),e.consume(t),e.exit(`taskListCheckMarker`),e.exit(`taskListCheck`),s):n(t)}function s(r){return Z(r)?t(r):Q(r)?e.check({tokenize:SD},t,n)(r):n(r)}}function SD(e,t,n){return $(e,r,`whitespace`);function r(e){return e===null?n(e):t(e)}}function CD(e){return jy([zE(),tD(),lD(e),pD(),bD()])}var wD={};function TD(e){let t=this,n=e||wD,r=t.data(),i=r.micromarkExtensions||=[],a=r.fromMarkdownExtensions||=[],o=r.toMarkdownExtensions||=[];i.push(CD(n)),a.push(OE()),o.push(kE(n))}function ED({checked:e,label:t,onChange:n}){return(0,D.jsxs)(`label`,{className:`switch`,children:[(0,D.jsx)(`input`,{className:`switch-input`,type:`checkbox`,role:`switch`,checked:e,onChange:e=>n(e.target.checked)}),(0,D.jsx)(`span`,{className:`switch-track`,"aria-hidden":`true`,children:(0,D.jsx)(`span`,{className:`switch-thumb`})}),(0,D.jsx)(`span`,{className:`switch-label`,children:t})]})}var DD=new Map,OD={bash:`Bash`,c:`C`,cpp:`C++`,cs:`C#`,csharp:`C#`,css:`CSS`,diff:`Diff`,dockerfile:`Dockerfile`,go:`Go`,html:`HTML`,java:`Java`,javascript:`JavaScript`,js:`JavaScript`,json:`JSON`,jsonc:`JSON with Comments`,jsx:`JSX`,kotlin:`Kotlin`,markdown:`Markdown`,md:`Markdown`,php:`PHP`,plaintext:`Plain text`,py:`Python`,python:`Python`,rb:`Ruby`,rs:`Rust`,ruby:`Ruby`,rust:`Rust`,scss:`SCSS`,sh:`Shell`,shell:`Shell`,sql:`SQL`,swift:`Swift`,text:`Plain text`,ts:`TypeScript`,tsx:`TSX`,txt:`Plain text`,typescript:`TypeScript`,xml:`XML`,yaml:`YAML`,yml:`YAML`,zsh:`Zsh`};function kD({className:e,children:t}){let[n,r]=(0,v.useState)(null),[i,a]=(0,v.useState)(!1),o=e?.match(/language-([^\s]+)/)?.[1]??`text`,s=OD[o.toLowerCase()]??o,c=String(t??``).replace(/\n$/,``);return(0,v.useEffect)(()=>{let e=!1;return r(null),AD(c,o).then(t=>{e||r(t)}),()=>{e=!0}},[c,o]),(0,D.jsxs)(`div`,{className:`markdown-code-block${i?` markdown-code-block-wrap`:``}`,children:[(0,D.jsxs)(`div`,{className:`markdown-code-block-header`,children:[(0,D.jsx)(`span`,{className:`markdown-code-block-language`,children:s}),(0,D.jsx)(ED,{checked:i,label:`Wrap`,onChange:a})]}),(0,D.jsx)(`div`,{className:`markdown-code-block-content`,children:n===null?(0,D.jsx)(`pre`,{children:(0,D.jsx)(`code`,{children:t})}):(0,D.jsx)(`div`,{dangerouslySetInnerHTML:{__html:n}})})]})}async function AD(e,t){let n=`${t}\u0000${e}`,r=DD.get(n);if(r)return r;let i=jD(e,t).catch(()=>null);return DD.set(n,i),i}async function jD(e,t){try{return await hs(e,{lang:t,theme:`github-dark-default`})}catch{return hs(e,{lang:`text`,theme:`github-dark-default`})}}function MD({content:e,className:t,variant:n}){let r=[`markdown-content`,n?`markdown-content-${n}`:null,t].filter(Boolean).join(` `);return(0,D.jsx)(`div`,{className:r,children:(0,D.jsx)(Sw,{remarkPlugins:[TD],components:{table({children:e}){return(0,D.jsx)(`div`,{className:`markdown-table-scroll`,children:(0,D.jsx)(`table`,{children:e})})},pre({children:e}){if((0,v.isValidElement)(e)){let{className:t,children:n}=e.props;return(0,D.jsx)(kD,{className:t,children:n})}return(0,D.jsx)(`pre`,{children:e})}},children:e})})}function ND({thread:e,onDeleteMessage:t}){return(0,D.jsxs)(`div`,{className:`thread-message-list`,children:[e.messages.map((e,n)=>(0,D.jsxs)(`div`,{className:`thread-message thread-message-${e.role}`,children:[(0,D.jsxs)(`div`,{className:`thread-message-header`,children:[(0,D.jsx)(`span`,{className:`thread-message-role`,children:e.role===`user`?`you`:`agent`}),(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,onClick:()=>t(n),"aria-label":`Delete ${e.role===`user`?`your`:`agent`} comment`,title:`delete comment`,children:(0,D.jsx)(bv,{size:13})})]}),(0,D.jsx)(MD,{content:e.text,variant:`thread`})]},`${e.role}:${n}:${e.text}`)),e.loading&&(0,D.jsxs)(`div`,{className:`thread-message thread-message-assistant`,children:[(0,D.jsx)(`span`,{className:`thread-message-role`,children:`agent`}),(0,D.jsx)(`span`,{className:`thread-message-thinking`,children:`thinking…`})]})]})}var PD=(0,v.memo)(function({thread:e,onAddReply:t,onRequestAgent:n,onToggleResolved:r,onToggleCollapsed:i,onDeleteMessage:a}){let[o,s]=(0,v.useState)(!1),[c,l]=(0,v.useState)(!1),u=e.messages[e.messages.length-1]?.role===`user`&&!e.loading&&!e.resolved,d=e.messages.length,f=`${e.resolved?`Resolved thread`:`Thread`} with ${d} comment${d===1?``:`s`}`,p=e.resolved?`Reopen`:`Resolve`,m=(0,v.useCallback)(e=>{s(!1),t(e,c),l(!1)},[t,c]),h=(0,v.useCallback)(()=>{r(!e.resolved)},[r,e.resolved]),g=(0,v.useCallback)(()=>{l(!1),s(!1)},[]);return e.collapsed?(0,D.jsx)(`div`,{className:`thread-card collapsed${e.resolved?` resolved`:``}`,children:(0,D.jsx)(`div`,{className:`thread-collapsed-row`,children:(0,D.jsxs)(X,{variant:`unstyled`,onClick:()=>i(!1),"aria-label":`Expand thread`,"aria-expanded":!1,children:[(0,D.jsx)(fv,{size:14}),(0,D.jsx)(`span`,{className:`thread-summary`,children:f})]})})}):(0,D.jsxs)(`div`,{className:`thread-card${e.resolved?` resolved`:``}`,children:[(0,D.jsx)(`div`,{className:`thread-header-row`,children:(0,D.jsxs)(X,{variant:`unstyled`,onClick:()=>i(!0),"aria-label":`Collapse thread`,"aria-expanded":!0,children:[(0,D.jsx)(dv,{size:14}),(0,D.jsx)(`span`,{className:`thread-summary`,children:f})]})}),(0,D.jsx)(ND,{thread:e,onDeleteMessage:a}),(0,D.jsx)(`div`,{className:`thread-footer`,children:o?(0,D.jsx)(Tv,{inputClassName:`thread-reply-input`,actionsClassName:`thread-actions`,placeholder:`Reply…`,submitLabel:`Comment`,autoFocus:!0,onSubmit:m,onCancel:g,children:(0,D.jsx)(wv,{checked:c,label:`Ask agent`,onChange:l})}):(0,D.jsxs)(`div`,{className:`thread-actions`,children:[(0,D.jsx)(X,{variant:`ghost`,onClick:h,children:p}),(0,D.jsx)(X,{onClick:()=>s(!0),children:`Reply`}),u&&(0,D.jsxs)(X,{onClick:n,children:[(0,D.jsx)(yv,{size:14}),`Ask agent`]})]})})]})}),FD={theme:Sv,themeType:`dark`,diffStyle:`unified`,diffIndicators:`none`,hunkSeparators:`line-info-basic`,lineDiffType:`word-alt`,disableFileHeader:!0,overflow:`wrap`,unsafeCSS:[`:host { --diffs-dark-bg: var(--surface); --diffs-bg: var(--surface); font-weight: var(--font-weight-code); }`,`pre { background-color: var(--surface) !important; }`,`[data-annotation-slot], [data-annotation-content] { font-family: var(--font-family-ui); }`,`[data-annotation-slot] code, [data-annotation-slot] pre, [data-annotation-content] code, [data-annotation-content] pre { font-family: var(--font-family-code); }`,`[data-overflow='wrap'] [data-code] { overflow-x: hidden; }`,`[data-overflow='wrap'] [data-annotation-content] { width: auto; }`].join(` `)},ID=(0,v.memo)(function({file:e,diffStyle:t,overflowMode:n,codeTheme:r,collapsed:i,viewed:a,annotations:o,unresolvedThreadCount:s,renderReady:c,onToggleCollapsed:l,onToggleViewed:u,onLineActivate:d,onSaveDraft:f,onCancelDraft:p,onAddReply:m,onRequestAgent:h,onToggleResolved:g,onToggleThreadCollapsed:_,onDeleteThreadMessage:y}){let b=(0,v.useMemo)(()=>{let i=t===`split`?`split`:`unified`;return{...FD,theme:r,diffStyle:i,overflow:n,onLineNumberClick:({lineNumber:t,annotationSide:n})=>{d(e.id,t,n)}}},[r,t,e.id,d,n]),x=(0,v.useCallback)(e=>{if(e.metadata.type===`draft`)return(0,D.jsx)(Ev,{onSave:f,onCancel:p});let{thread:t}=e.metadata;return(0,D.jsx)(PD,{thread:t,onAddReply:(e,n)=>m(t.id,e,n),onRequestAgent:()=>h(t.id),onToggleResolved:e=>g(t.id,e),onToggleCollapsed:e=>_(t.id,e),onDeleteMessage:e=>y(t.id,e)})},[m,p,h,f,y,g,_]);return(0,D.jsxs)(`section`,{className:`file-section${i?` collapsed`:``}`,id:`file-${e.id}`,children:[(0,D.jsxs)(`div`,{className:`file-header`,children:[(0,D.jsxs)(X,{variant:`unstyled`,className:`file-toggle`,onClick:()=>l(e.id),"aria-label":i?`Expand file`:`Collapse file`,children:[i?(0,D.jsx)(uv,{size:14}):(0,D.jsx)(lv,{size:14}),(0,D.jsx)(`span`,{className:`file-path`,children:e.displayPath}),s>0&&(0,D.jsxs)(`span`,{className:`file-thread-count`,"aria-label":`${s} unresolved comment thread${s===1?``:`s`}`,title:`${s} unresolved comment thread${s===1?``:`s`}`,children:[(0,D.jsx)(gv,{size:12}),(0,D.jsx)(`span`,{children:s})]})]}),(0,D.jsxs)(`div`,{className:`file-meta`,children:[(0,D.jsx)(Dv,{additions:e.additions,deletions:e.deletions}),(0,D.jsx)(wv,{checked:a,label:`Viewed`,className:`viewed-checkbox`,onChange:()=>u(e.id)})]})]}),!i&&(0,D.jsx)(`div`,{className:`file-body`,children:c?(0,D.jsx)(Z_,{className:`diff-view`,fileDiff:e.file,options:b,lineAnnotations:o,renderAnnotation:x}):(0,D.jsx)(`div`,{className:`diff-placeholder`,children:`preparing diff…`})})]})});function LD({directory:e}){let t=(0,v.useRef)(null),[n,r]=(0,v.useState)(()=>zD(e)),i=(0,v.useMemo)(()=>RD(),[]);return(0,v.useLayoutEffect)(()=>{let n=t.current;if(!n)return;let a=()=>{let t=window.getComputedStyle(n);r(BD(e,n.clientWidth,t.font,i))};a();let o=new ResizeObserver(a);return o.observe(n),()=>{o.disconnect()}},[e,i]),(0,D.jsx)(`div`,{ref:t,className:`sidebar-file-directory`,title:e,children:n})}function RD(){let e=document.createElement(`canvas`).getContext(`2d`);return(t,n)=>e?(e.font=n,e.measureText(t).width):t.length*8}function zD(e){let t=HD(e);return t.length<=2?e:`${t[0]}/…/${t[t.length-1]}/`}function BD(e,t,n,r){let i=VD(e);for(let e of i)if(r(e,n)<=t)return e;return i[i.length-1]??e}function VD(e){let t=HD(e),n=[e];return t.length>2&&(n.push(`${t[0]}/…/${t.slice(1).join(`/`)}/`),n.push(`${t[0]}/…/${t.slice(-2).join(`/`)}/`),n.push(`${t[0]}/…/${t[t.length-1]}/`)),t.length>0&&n.push(`…/${t[t.length-1]}/`),[...new Set(n)]}function HD(e){return e===`./`?[]:e.split(`/`).filter(Boolean)}function UD({files:e,viewed:t,onJumpToFile:n}){let r=WD(e);return(0,D.jsx)(`aside`,{className:`sidebar`,children:(0,D.jsx)(`div`,{className:`sidebar-file-list`,children:r.map((e,r)=>(0,D.jsxs)(`div`,{className:`sidebar-file-group`,children:[(0,D.jsx)(LD,{directory:e.directory}),e.files.map(e=>(0,D.jsxs)(`button`,{type:`button`,className:`sidebar-file-item${t[e.id]?` viewed`:``}`,onClick:()=>n(e.id),title:e.displayPath,children:[(0,D.jsx)(`span`,{className:`sidebar-file-status ${e.status}`,"aria-label":e.status,children:JD(e.status)}),(0,D.jsx)(`span`,{className:`sidebar-file-name`,children:KD(e)}),(0,D.jsx)(Dv,{additions:e.additions,deletions:e.deletions,className:`sidebar-stats`})]},e.id))]},`${e.directory}:${r}`))})})}function WD(e){let t=[];for(let n of e){let e=GD(n.newRepoPath),r=t[t.length-1];if(r?.directory===e){r.files.push(n);continue}t.push({directory:e,files:[n]})}return t}function GD(e){let t=e.lastIndexOf(`/`);return t<0?`./`:`${e.slice(0,t)}/`}function KD(e){return qD(e.newRepoPath)}function qD(e){let t=e.lastIndexOf(`/`);return t<0?e:e.slice(t+1)}function JD(e){switch(e){case`added`:return`A`;case`deleted`:return`D`;case`renamed`:return`R`;case`copied`:return`C`;case`type-changed`:return`T`;case`unmerged`:return`U`;case`modified`:return`M`;case`unknown`:return`?`}}var YD=[];function XD({contentRef:e,files:t,emptyContent:n,reviewState:r,renderReady:i,fileState:a,threads:o,onJumpToFile:s}){return(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(UD,{files:t,viewed:a.viewed,onJumpToFile:s}),(0,D.jsxs)(`main`,{ref:e,className:`content`,children:[t.length===0&&(0,D.jsx)(`div`,{className:`empty`,children:n}),t.map(e=>{let t=w(o.threadsByFileId.get(e.id)??YD,e.id,o.draft,o.draftAnnotation);return(0,D.jsx)(ID,{file:e,diffStyle:r.diffStyle,overflowMode:r.overflowMode,codeTheme:r.codeTheme,collapsed:a.collapsed[e.id]??!1,viewed:a.viewed[e.id]??!1,annotations:t,unresolvedThreadCount:a.unresolvedThreadCountsByFileId.get(e.id)??0,renderReady:i,onToggleCollapsed:a.toggleCollapsed,onToggleViewed:a.toggleViewed,onLineActivate:o.activateLine,onSaveDraft:o.saveDraft,onCancelDraft:o.cancelDraft,onAddReply:o.addReply,onRequestAgent:o.requestAgent,onToggleResolved:o.toggleResolved,onToggleThreadCollapsed:o.toggleThreadCollapsed,onDeleteThreadMessage:o.removeThreadMessage},e.id)})]})]})}function ZD(e){return Object.fromEntries(e.map(e=>[e,!0]))}function QD(e,t){return e.includes(t)?e.filter(e=>e!==t):[...e,t]}function $D(e){return[...new Set(e)]}function eO(e,t){return{additions:e.additions+t.additions,deletions:e.deletions+t.deletions}}function tO({files:e,reviewState:t,applyStatePatch:n,scrollToFile:r}){let i=(0,v.useRef)(null),a=(0,v.useMemo)(()=>ZD(t.collapsedFileIds),[t.collapsedFileIds]),o=(0,v.useMemo)(()=>ZD(t.viewedFileIds),[t.viewedFileIds]),s=(0,v.useMemo)(()=>t.threads.filter(e=>!e.resolved),[t.threads]),c=(0,v.useMemo)(()=>s.filter(b),[s]),l=(0,v.useMemo)(()=>$D(c.map(e=>e.anchor.fileId)),[c]),u=(0,v.useMemo)(()=>C(c),[c]),d=(0,v.useMemo)(()=>e.reduce(eO,{additions:0,deletions:0}),[e]),f=(0,v.useCallback)(e=>{n({collapsedFileIds:QD(t.collapsedFileIds,e)})},[n,t.collapsedFileIds]),p=(0,v.useCallback)(e=>{let r=QD(t.viewedFileIds,e),a=r.includes(e),o=a?$D([...t.collapsedFileIds,e]):t.collapsedFileIds;i.current=a&&!t.collapsedFileIds.includes(e)?e:null,n({viewedFileIds:r,collapsedFileIds:o},{onError:()=>{i.current=null}})},[n,t.collapsedFileIds,t.viewedFileIds]),m=(0,v.useCallback)(()=>{n({collapsedFileIds:[]})},[n]),h=(0,v.useCallback)(()=>{n({collapsedFileIds:e.map(e=>e.id)})},[n,e]),g=(0,v.useCallback)(()=>{if(l.length===0)return;let e=new Set(l);n({collapsedFileIds:t.collapsedFileIds.filter(t=>!e.has(t))})},[n,l,t.collapsedFileIds]),_=(0,v.useCallback)(()=>{n({collapsedFileIds:$D([...t.collapsedFileIds,...t.viewedFileIds])})},[n,t.collapsedFileIds,t.viewedFileIds]);return(0,v.useLayoutEffect)(()=>{let e=i.current;e&&(i.current=null,r(e,`auto`))},[t.collapsedFileIds,r]),{collapsed:a,viewed:o,unresolvedThreadCount:c.length,filesWithUnresolvedThreads:l,unresolvedThreadCountsByFileId:u,totals:d,toggleCollapsed:f,toggleViewed:p,expandAll:m,collapseAll:h,expandUnresolved:g,collapseViewed:_}}function nO(e,t){let[n,r]=(0,v.useState)(!1);return(0,v.useEffect)(()=>{if(e.length===0){r(!1);return}let n=!0;return r(!1),rO(e,t).then(()=>{n&&r(!0)}),()=>{n=!1}},[t,e]),n}async function rO(e,t){await Promise.all([document.fonts?.ready??Promise.resolve(),vd({themes:[t],langs:iO(e)}).catch(()=>void 0)])}function iO(e){let t=new Set;for(let n of e)t.add(n.file.lang??Sd(n.file.name));return[...t]}function aO({value:e,options:t,label:n,onChange:r}){return(0,D.jsx)(`div`,{className:`toggle-group`,role:`radiogroup`,"aria-label":n,children:t.map(t=>(0,D.jsx)(X,{variant:`ghost`,active:e===t.value,role:`radio`,"aria-checked":e===t.value,onClick:()=>r(t.value),children:t.label},t.value))})}function oO({target:e,comments:t,requestChanges:n,onComment:r}){let[i,a]=(0,v.useState)(null),o=Cv(e),s=t.find(e=>Cv(e.target)===o),c=s?.body.trim()?`Edit your comment`:`Write a comment`,l=[{value:`comment`,label:c},{value:`changes`,label:`Ask for changes`}],[u,d]=(0,v.useState)(s?.body??``);if((0,v.useEffect)(()=>{d(s?.body??``)},[s?.body]),(0,v.useEffect)(()=>{!n&&i===`changes`&&a(null)},[i,n]),i===null)return(0,D.jsxs)(`div`,{className:`guide-feedback-actions`,"aria-label":`Feedback`,children:[(0,D.jsx)(X,{variant:`ghost`,onClick:()=>a(`comment`),children:c}),n&&(0,D.jsx)(X,{variant:`ghost`,onClick:()=>a(`changes`),children:`Ask for changes`})]});let f=n?(0,D.jsx)(aO,{value:i,options:l,label:`Feedback mode`,onChange:a}):void 0;return i===`changes`&&n?(0,D.jsx)(sO,{label:`Feedback`,heading:f,placeholder:n.placeholder,submitLabel:n.submitLabel,onClose:()=>a(null),onSubmit:e=>{n.onSubmit(e),a(null)}}):(0,D.jsx)(sO,{label:`Feedback`,heading:f,placeholder:`Write your review comment…`,submitLabel:`Save comment`,value:u,allowEmptySubmit:!!s,onValueChange:d,onClose:()=>a(null),onSubmit:t=>{r(e,t),a(null)}})}function sO({label:e,heading:t,placeholder:n,submitLabel:r,value:i,allowEmptySubmit:a,onValueChange:o,onClose:s,onSubmit:c}){return(0,D.jsxs)(`aside`,{className:`guide-feedback-card`,"aria-label":e,children:[t&&(0,D.jsx)(`header`,{className:`guide-feedback-card-heading`,children:t}),(0,D.jsx)(Tv,{className:`guide-feedback-form`,inputClassName:`guide-feedback-input`,actionsClassName:`guide-feedback-footer`,placeholder:n,submitLabel:r,cancelLabel:`Close`,value:i,autoFocus:!0,allowEmptySubmit:a,onValueChange:o,onCancel:s,onSubmit:c})]})}function cO({content:e,comments:t,loading:n,onComment:r}){return(0,D.jsxs)(`section`,{className:`guide-section`,"aria-labelledby":`guide-title`,children:[(0,D.jsxs)(`header`,{className:`guide-section-heading`,children:[(0,D.jsx)(`h2`,{id:`guide-title`,className:`guide-section-title`,children:`Orientation`}),n&&(0,D.jsx)(`output`,{className:`guide-loading`,children:`Updating…`})]}),(0,D.jsx)(MD,{content:e,variant:`guide`}),(0,D.jsx)(oO,{comments:t,target:{kind:`orientation`},onComment:r})]})}function lO({questions:e,pendingQuestions:t,comments:n,onOperate:r,onComment:i}){let[a,o]=(0,v.useState)(!1);return(0,D.jsxs)(`section`,{className:`guide-section`,"aria-labelledby":`guide-questions-title`,children:[(0,D.jsx)(`header`,{className:`guide-section-heading`,children:(0,D.jsx)(`h2`,{id:`guide-questions-title`,className:`guide-section-title`,children:`Questions`})}),(e.length>0||t.length>0)&&(0,D.jsxs)(`ul`,{className:`guide-question-list`,children:[e.map(e=>(0,D.jsx)(`li`,{className:`guide-question-item`,children:(0,D.jsxs)(`details`,{className:`guide-question`,children:[(0,D.jsxs)(`summary`,{children:[(0,D.jsx)(uv,{className:`guide-question-icon`,size:16}),(0,D.jsx)(`span`,{className:`guide-question-label`,children:(0,D.jsx)(`strong`,{children:e.question})})]}),(0,D.jsxs)(`div`,{className:`guide-question-answer`,children:[(0,D.jsx)(MD,{content:e.answer,variant:`guide`}),(0,D.jsx)(oO,{comments:n,target:{kind:`question`,questionId:e.id},onComment:i})]})]})},e.id)),t.map(e=>(0,D.jsx)(`li`,{className:`guide-question-item`,children:(0,D.jsx)(`div`,{className:`guide-question-pending`,role:`status`,"aria-label":`${e.question}, generating answer`,children:(0,D.jsx)(`span`,{className:`guide-question-label`,children:(0,D.jsx)(`strong`,{children:e.question})})})},e.id))]}),a?(0,D.jsx)(sO,{label:`Ask a question`,placeholder:`Write the question you want answered…`,submitLabel:`Ask`,onClose:()=>o(!1),onSubmit:e=>{r({kind:`question.ask`,question:e}),o(!1)}}):(0,D.jsx)(`div`,{className:`guide-question-actions`,children:(0,D.jsx)(X,{variant:`ghost`,onClick:()=>o(!0),children:`Ask a question`})})]})}function uO({topic:e,comments:t,onOperate:n,onComment:r}){return(0,D.jsxs)(`article`,{className:`guide-topic-content`,children:[(0,D.jsx)(`header`,{className:`guide-topic-heading`,children:(0,D.jsx)(`h3`,{children:e.heading})}),(0,D.jsx)(MD,{content:e.body,variant:`guide`}),(0,D.jsx)(oO,{comments:t,target:{kind:`topic`,topicId:e.id},requestChanges:{placeholder:`Describe the changes you want…`,submitLabel:`Request changes`,onSubmit:t=>{n({kind:`topic.revise`,topicId:e.id,request:t})}},onComment:r})]})}function dO({topics:e,pendingTopics:t,comments:n,onOperate:r,onComment:i}){let[a,o]=(0,v.useState)(!1),[s,c]=(0,v.useState)(()=>e[0]?.id??null),l=(0,v.useRef)(null),u=(0,v.useRef)(null),d=(0,v.useMemo)(()=>t.filter(e=>e.kind===`add`),[t]),f=(0,v.useMemo)(()=>new Set(t.flatMap(e=>e.kind===`revise`?[e.topicId]:[])),[t]),p=d.find(e=>e.id===s),m=p?void 0:e.find(e=>e.id===s)??e[0];return(0,v.useEffect)(()=>{let t=l.current;t===null||e.length<=t||(c(e[e.length-1]?.id??null),l.current=null)},[e]),(0,v.useEffect)(()=>{let e=u.current;e===null||d.length<=e||(c(d[d.length-1]?.id??null),u.current=null)},[d]),(0,D.jsxs)(`section`,{className:`guide-section`,"aria-label":`Topics`,children:[(0,D.jsxs)(`div`,{className:`guide-topic-cloud`,"aria-label":`Guide topics`,children:[e.map(e=>{let t=!a&&e.id===m?.id,n=f.has(e.id);return(0,D.jsxs)(X,{variant:t?`default`:`ghost`,active:t,pill:!0,"aria-label":n?`${e.label}, updating`:void 0,"aria-pressed":t,onClick:()=>{c(e.id),o(!1)},children:[e.label,n&&(0,D.jsx)(`span`,{className:`guide-topic-working-dot`,"aria-hidden":`true`})]},e.id)}),d.map(e=>{let t=!a&&e.id===p?.id;return(0,D.jsxs)(X,{variant:t?`default`:`ghost`,active:t,pill:!0,"aria-label":`New topic, generating`,"aria-pressed":t,onClick:()=>{c(e.id),o(!1)},children:[`New topic`,(0,D.jsx)(`span`,{className:`guide-topic-working-dot`,"aria-hidden":`true`})]},e.id)}),(0,D.jsx)(X,{variant:a?`default`:`ghost`,active:a,muted:!a,pill:!0,"aria-pressed":a,onClick:()=>o(!0),children:`Ask about…`})]}),a?(0,D.jsx)(sO,{label:`Ask about a topic`,placeholder:`Describe the topic you want explained…`,submitLabel:`Ask`,onClose:()=>o(!1),onSubmit:t=>{l.current=e.length,u.current=d.length,r({kind:`topic.add`,request:t}),o(!1)}}):p?(0,D.jsxs)(`article`,{className:`guide-topic-content`,role:`status`,children:[(0,D.jsx)(`header`,{className:`guide-topic-heading`,children:(0,D.jsx)(`h3`,{children:`Generating topic…`})}),(0,D.jsx)(`p`,{className:`guide-topic-generating`,children:`Building a focused explanation for this topic.`})]}):m&&(0,D.jsx)(uO,{topic:m,comments:n,onOperate:r,onComment:i},m.id)]})}function fO({guide:e,pendingTopics:t,pendingQuestions:n,onGenerate:r,onOperate:i,onComment:a}){return e.orientation.trim()?(0,D.jsxs)(`article`,{className:`guide`,"aria-labelledby":`guide-title`,children:[(0,D.jsx)(cO,{content:e.orientation,comments:e.comments,loading:e.loading,onComment:a}),(0,D.jsx)(dO,{topics:e.topics,pendingTopics:t,comments:e.comments,onOperate:i,onComment:a}),(0,D.jsx)(lO,{questions:e.questions,pendingQuestions:n,comments:e.comments,onOperate:i,onComment:a})]}):(0,D.jsxs)(`section`,{className:`guide-empty`,"aria-labelledby":`guide-empty-title`,"aria-busy":e.loading,children:[(0,D.jsx)(`h1`,{id:`guide-empty-title`,className:`guide-section-title`,children:`Understand this change`}),(0,D.jsx)(`p`,{children:`Get oriented before reading the implementation, then explore the parts and questions that matter to you.`}),(0,D.jsx)(X,{variant:`primary`,disabled:e.loading,onClick:r,children:e.loading?`Building guide…`:`Generate guide`})]})}var pO=5;function mO({thread:e,body:t,draftKind:n,disabled:r,onBodyChange:i,onSubmit:a}){let o=(0,v.useRef)(null);if((0,v.useLayoutEffect)(()=>{let e=o.current;if(!e)return;e.style.height=`auto`;let t=getComputedStyle(e),n=Number.parseFloat(t.lineHeight),r=Number.parseFloat(t.paddingTop)+Number.parseFloat(t.paddingBottom)+Number.parseFloat(t.borderTopWidth)+Number.parseFloat(t.borderBottomWidth),i=n*pO+r,a=Math.min(e.scrollHeight,i);e.style.height=`${a}px`,e.style.overflowY=e.scrollHeight>i?`auto`:`hidden`},[t]),e?.resolved)return(0,D.jsx)(`div`,{className:`guide-conversation-excluded-footer`,children:`Excluded from review`});let s=!e&&n===`comment`?`Write a global review comment`:`Ask anything`;return(0,D.jsx)(`div`,{className:`guide-conversation-composer`,children:(0,D.jsx)(`textarea`,{ref:o,className:`guide-conversation-input`,value:t,rows:1,disabled:r,placeholder:`${s}…`,"aria-label":s,onChange:e=>i(e.target.value),onKeyDown:e=>{e.key!==`Enter`||e.shiftKey||e.nativeEvent.isComposing||(e.preventDefault(),t.trim()&&a())}})})}function hO({thread:e}){return(0,D.jsxs)(`div`,{className:`guide-conversation-message-list`,children:[e.messages.map((e,t)=>(0,D.jsx)(`article`,{className:`guide-conversation-message ${e.role}`,children:e.role===`user`?(0,D.jsx)(`div`,{className:`guide-conversation-user-text`,children:e.text}):(0,D.jsx)(MD,{content:e.text,className:`guide-conversation-message-content`})},`${e.role}:${t}:${e.text}`)),e.loading&&(0,D.jsx)(`div`,{className:`guide-conversation-message assistant loading`,children:(0,D.jsx)(`span`,{className:`guide-conversation-thinking`,children:`Thinking…`})})]})}function gO({thread:e,body:t,draftKind:n,submitting:r,onBodyChange:i,onSubmit:a}){let o=(0,v.useRef)(null),s=e?.messages.length??0;return(0,v.useLayoutEffect)(()=>{let e=o.current;e&&(e.scrollTop=e.scrollHeight)},[s,e?.id,e?.loading]),(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(`div`,{ref:o,className:`guide-conversation-messages`,"aria-live":`polite`,children:e?(0,D.jsx)(hO,{thread:e}):(0,D.jsx)(`div`,{className:`guide-conversation-empty`,children:n===`comment`?(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(`h2`,{children:`Add a global review comment`}),(0,D.jsx)(`p`,{children:`Leave feedback that does not belong to a specific diff line or guide block.`})]}):(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(`h2`,{children:`What would you like to know?`}),(0,D.jsx)(`p`,{children:`Ask about the intent, tradeoffs, or any part of the change you want to understand better.`})]})})}),(0,D.jsx)(mO,{thread:e,body:t,draftKind:n,disabled:r||!!e?.loading,onBodyChange:i,onSubmit:a})]})}function _O({conversations:e}){let{items:t,selected:n,view:r}=e;return(0,D.jsxs)(`aside`,{className:`guide-conversation-panel`,"aria-label":`Guide conversations`,children:[(0,D.jsxs)(`header`,{className:`guide-conversation-header`,children:[(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,active:r===`history`,"aria-label":`Conversation history`,"aria-pressed":r===`history`,title:`Conversation history`,onClick:e.showHistory,children:(0,D.jsx)(vv,{size:16})}),(0,D.jsxs)(`div`,{className:`guide-conversation-header-actions`,children:[n&&(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,"aria-label":n.resolved?`Include conversation in review`:`Exclude conversation from review`,title:n.resolved?`Include in review`:`Exclude from review`,onClick:()=>n.resolved?e.include(n.id):e.exclude(n.id),children:n.resolved?(0,D.jsx)(mv,{size:16}):(0,D.jsx)(pv,{size:16})}),(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,active:r===`new`&&e.draftKind===`comment`,"aria-label":`Add global comment`,"aria-pressed":r===`new`&&e.draftKind===`comment`,title:`Add global comment`,onClick:e.openComment,children:(0,D.jsx)(hv,{size:16})}),(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,active:r===`new`&&e.draftKind===`conversation`,"aria-label":`New agent conversation`,"aria-pressed":r===`new`&&e.draftKind===`conversation`,title:`New agent conversation`,onClick:e.openConversation,children:(0,D.jsx)(_v,{size:16})})]})]}),r===`history`?(0,D.jsx)(`div`,{className:`guide-conversation-history`,children:t.length===0?(0,D.jsx)(`p`,{className:`guide-conversation-history-empty`,children:`No conversations yet`}):t.map(t=>{let n=vO(t);return(0,D.jsxs)(X,{variant:`unstyled`,className:`guide-conversation-item${t.resolved?` excluded`:``}`,onClick:()=>e.open(t.id),title:n,children:[(0,D.jsx)(gv,{size:14,"aria-hidden":`true`}),(0,D.jsx)(`span`,{children:n}),t.resolved?(0,D.jsx)(`span`,{className:`guide-conversation-excluded`,children:`Excluded`}):(0,D.jsx)(`span`,{className:`guide-conversation-status${t.loading?` active`:``}`,"aria-label":t.loading?`Agent responding`:void 0,"aria-hidden":!t.loading||void 0})]},t.id)})}):(0,D.jsx)(gO,{thread:n,body:e.body,draftKind:e.draftKind,submitting:e.submitting,onBodyChange:e.setBody,onSubmit:e.submit},n?.id??`new`)]})}function vO(e){let t=e.messages.find(e=>e.role===`user`)?.text.replace(/\s+/g,` `).trim()??``;return t?t.length<=96?t:`${t.slice(0,93).trimEnd()}…`:`New conversation`}async function yO(e,t={}){let n=await fetch(new URL(e,document.baseURI),{headers:{"content-type":`application/json`,...t.headers},...t}),r=await bO(n);if(!n.ok)throw Error(r.error||n.statusText||`request to ${e} failed`);return r}async function bO(e){let t=await e.text();if(!t)return{};try{return JSON.parse(t)}catch{throw Error(`server returned an invalid JSON response`)}}async function xO(){return yO(`api/bootstrap`)}async function SO(e){return yO(`api/diff${e?`?path=${encodeURIComponent(e)}`:``}`)}async function CO(e){return yO(`api/state`,{method:`POST`,body:JSON.stringify(e)})}async function wO(e){return yO(`api/thread`,{method:`POST`,body:JSON.stringify(e)})}async function TO(e){return yO(`api/thread/reply`,{method:`POST`,body:JSON.stringify(e)})}async function EO(e){return yO(`api/thread-message`,{method:`POST`,body:JSON.stringify({id:e})})}async function DO(e){return yO(`api/thread-message/delete`,{method:`POST`,body:JSON.stringify(e)})}async function OO(e){return yO(`api/thread/resolve`,{method:`POST`,body:JSON.stringify(e)})}async function kO(e){return yO(`api/thread/collapse`,{method:`POST`,body:JSON.stringify(e)})}async function AO(){return yO(`api/guide/generate`,{method:`POST`})}async function jO(e){return yO(`api/guide/operate`,{method:`POST`,body:JSON.stringify(e)})}async function MO(e){return yO(`api/guide/comment`,{method:`POST`,body:JSON.stringify(e)})}async function NO(){return yO(`api/review`,{method:`POST`})}async function PO(){return yO(`api/cancel`,{method:`POST`})}function FO({bootstrap:e,reviewState:t,setGuideLoading:n,syncReviewState:r}){let i=(0,v.useRef)(!1),a=(0,v.useRef)(0),[o,s]=(0,v.useState)([]),[c,l]=(0,v.useState)([]),u=(0,v.useCallback)(()=>{n(!0),r(AO(),{onError:()=>{i.current=!1,n(!1)}})},[n,r]),d=(0,v.useCallback)(e=>{let t=`guide-operation-${a.current++}`;e.kind===`topic.add`?s(e=>[...e,{id:t,kind:`add`}]):e.kind===`topic.revise`?s(n=>[...n,{id:t,kind:`revise`,topicId:e.topicId}]):e.kind===`question.ask`&&l(n=>[...n,{id:t,question:e.question}]),n(!0),r(jO(e),{onError:()=>{n(!1)}}).finally(()=>{e.kind===`topic.add`||e.kind===`topic.revise`?s(e=>e.filter(e=>e.id!==t)):e.kind===`question.ask`&&l(e=>e.filter(e=>e.id!==t))})},[n,r]),f=(0,v.useCallback)((e,t)=>{r(MO({target:e,body:t}))},[r]);return(0,v.useEffect)(()=>{!e||t.guide.orientation||i.current||(i.current=!0,u())},[e,u,t.guide.orientation]),{pendingTopics:o,pendingQuestions:c,requestGuide:u,runGuideOperation:d,saveComment:f}}var IO=[{value:`guide`,label:`Guide`},{value:`diff`,label:`Diff`}],LO=[{value:`split`,label:`Split`},{value:`stacked`,label:`Stacked`}],RO=14;function zO({mode:e,fileCount:t,viewedCount:n,additions:r,deletions:i,commentCount:a,diffStyle:o,overflowMode:s,finished:c,hasUnresolvedFileThreads:l,onModeChange:u,onExpandAll:d,onExpandUnresolved:f,onCollapseViewed:p,onCollapseAll:m,onDiffStyleChange:h,onOverflowModeChange:g,onSubmit:_,onCancel:v}){let y=o===`split`?`split`:`stacked`,b=s===`scroll`?`scroll`:`wrap`,x=t>0?Math.round(n/t*100):0;return(0,D.jsxs)(`header`,{className:`top-bar`,children:[(0,D.jsx)(`div`,{className:`top-bar-left`,children:(0,D.jsx)(aO,{value:e,options:IO,label:`Review mode`,onChange:u})}),(0,D.jsxs)(`div`,{className:`top-bar-right`,children:[e===`diff`&&(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(`span`,{"aria-label":`${r} additions and ${i} deletions`,children:(0,D.jsx)(Dv,{additions:r,deletions:i})}),(0,D.jsxs)(`div`,{className:`top-bar-viewed`,"aria-label":`${n} of ${t} viewed, ${a} unresolved comments`,children:[(0,D.jsx)(`span`,{className:`top-bar-viewed-ring`,style:{background:`conic-gradient(var(--accent-interactive) ${x}%, var(--border) ${x}% 100%)`},"aria-hidden":`true`,children:(0,D.jsx)(`span`,{className:`top-bar-viewed-ring-inner`})}),(0,D.jsxs)(`span`,{className:`top-bar-viewed-text`,children:[n,` of `,t,` viewed`]})]}),(0,D.jsxs)(`div`,{className:`button-group`,children:[(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,"aria-label":`Expand all files`,onClick:d,children:(0,D.jsx)(fv,{size:RO})}),(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,"aria-label":`Expand files with unresolved threads`,onClick:f,disabled:!l,children:(0,D.jsx)(gv,{size:RO})}),(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,"aria-label":`Collapse viewed files`,onClick:p,children:(0,D.jsx)(pv,{size:RO})}),(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,"aria-label":`Collapse all files`,onClick:m,children:(0,D.jsx)(dv,{size:RO})})]}),(0,D.jsx)(ED,{checked:b===`wrap`,label:`Wrap`,onChange:e=>g(e?`wrap`:`scroll`)}),(0,D.jsx)(aO,{value:y,options:LO,label:`Diff style`,onChange:h})]}),(0,D.jsxs)(`div`,{className:`top-bar-actions`,children:[(0,D.jsx)(X,{variant:`primary`,onClick:_,disabled:c,children:`Submit`}),(0,D.jsx)(X,{variant:`danger`,iconOnly:!0,onClick:v,disabled:c,"aria-label":`cancel`,children:(0,D.jsx)(xv,{size:RO,strokeWidth:2.25})})]})]})]})}function BO(){let[e,t]=(0,v.useState)(`guide`),n=(0,v.useRef)(null),r=(0,v.useRef)({guide:0,diff:0});return{mode:e,contentRef:n,changeMode:(0,v.useCallback)(i=>{if(i===e)return;let a=n.current;a&&(r.current[e]=a.scrollTop),t(i),requestAnimationFrame(()=>{n.current?.scrollTo({top:r.current[i],behavior:`auto`})})},[e]),scrollToFile:(0,v.useCallback)((e,t=`smooth`)=>{let r=n.current,i=document.getElementById(`file-${e}`);if(!r||!i)return;let a=r.getBoundingClientRect(),o=i.getBoundingClientRect(),s=Number.parseFloat(getComputedStyle(r).paddingTop);r.scrollTo({top:r.scrollTop+o.top-a.top-s,behavior:t})},[])}}function VO(e,t,n){if(!e.trim())return[];let r=Gp(e,n),i=WO(t),a=0;return r.flatMap(e=>e.files.map(e=>{let t=GO(e,i);return{id:e.cacheKey??`${e.name}::${a++}`,file:e,displayPath:t.displayPath,status:t.status,oldRepoPath:t.oldRepoPath,newRepoPath:t.newRepoPath,additions:UO(e,`additions`),deletions:UO(e,`deletions`)}}))}function HO(e){return e.prevName&&e.prevName!==e.name?`renamed`:`modified`}function UO(e,t){return e.hunks.reduce((e,n)=>e+n.hunkContent.reduce((e,n)=>e+(n.type===`change`?n[t]:0),0),0)}function WO(e){let t=new Map;for(let n of e??[]){let e={displayPath:n.oldPath&&n.newPath&&n.oldPath!==n.newPath?`${n.oldPath} → ${n.newPath}`:n.path,status:n.status,oldRepoPath:n.oldPath,newRepoPath:n.newPath??n.path};t.set(n.path,e),n.newPath&&t.set(n.newPath,e),n.oldPath&&t.set(n.oldPath,e)}return t}function GO(e,t){return t.get(e.name)||(e.prevName?t.get(e.prevName):void 0)||{displayPath:e.prevName&&e.prevName!==e.name?`${e.prevName} → ${e.name}`:e.name,status:HO(e),oldRepoPath:e.prevName,newRepoPath:e.name}}var KO={diffStyle:`stacked`,overflowMode:`wrap`,codeTheme:Sv,collapsedFileIds:[],viewedFileIds:[],threads:[],guide:{orientation:``,topics:[],questions:[],comments:[],loading:!1}};function qO(e,t,n){return{...e,threads:e.threads.map(e=>e.id===t?{...e,loading:n}:e)}}function JO(e,t){return{...e,guide:{...e.guide,loading:t}}}function YO(){let[e,t]=(0,v.useState)(null),[n,r]=(0,v.useState)(null),[i,a]=(0,v.useState)(KO),o=(0,v.useCallback)(e=>{a(e)},[]),s=(0,v.useCallback)(async(e,t={})=>{try{let t=await e;o(t.state)}catch{t.onError?.()}},[o]),c=(0,v.useCallback)((e,t)=>{s(CO(e),t)},[s]),l=(0,v.useCallback)((e,t)=>{a(n=>qO(n,e,t))},[]),u=(0,v.useCallback)(e=>{a(t=>JO(t,e))},[]);(0,v.useEffect)(()=>{let e=!0;return(async()=>{try{let n=await xO();if(!n.state)throw Error(`diff tool bootstrap response did not include review state`);if(!e)return;t(n),o(n.state);let i=await SO();e&&r(i)}catch{}})(),()=>{e=!1}},[o]);let d=n&&`patch`in n?n.patch:``;return{bootstrap:e,reviewState:i,files:(0,v.useMemo)(()=>VO(d,e?.files,e?.context.sessionId),[e,d]),emptyContent:n?`no changes to review`:`loading…`,applyReviewState:o,syncReviewState:s,applyStatePatch:c,setThreadLoading:l,setGuideLoading:u}}function XO(){let[e,t]=(0,v.useState)(!1);return{finished:e,submit:(0,v.useCallback)(async()=>{t(!0);try{await NO()}catch{t(!1)}},[]),cancel:(0,v.useCallback)(async()=>{t(!0);try{await PO()}catch{t(!1)}},[])}}function ZO({reviewState:e,requestThreadAgentReply:t,applyReviewState:n}){let[r,i]=(0,v.useState)(``),[a,o]=(0,v.useState)(!1),[s,c]=(0,v.useState)({mode:`new`,kind:`conversation`}),l=(0,v.useRef)(0),u=(0,v.useRef)(!1),d=(0,v.useMemo)(()=>e.threads.filter(x).reverse(),[e.threads]),f=(0,v.useMemo)(()=>s.mode===`thread`?d.find(e=>e.id===s.threadId)??null:null,[d,s]),p=(0,v.useCallback)(e=>{l.current+=1,i(``),c({mode:`new`,kind:e})},[]),m=(0,v.useCallback)(e=>{l.current+=1,i(``),c({mode:`thread`,threadId:e})},[]),h=(0,v.useCallback)(()=>{l.current+=1,i(``),c({mode:`history`})},[]);(0,v.useEffect)(()=>{s.mode===`thread`&&!f&&h()},[f,h,s]);let g=(0,v.useCallback)(e=>l.current===e&&(i(``),!0),[]),_=(0,v.useCallback)(async()=>{let e=r.trim();if(!e||u.current||s.mode===`history`||s.mode===`thread`&&(!f||f.loading||f.resolved))return;let i=l.current,a=s.mode===`thread`||s.kind===`conversation`,d;u.current=!0,o(!0);try{if(s.mode===`thread`)d=s.threadId,n((await TO({id:d,text:e})).state),g(i);else{let t=await wO({body:e,anchor:{kind:`detached`}});d=t.threadId,n(t.state),g(i)&&c({mode:`thread`,threadId:d})}}catch{return}finally{u.current=!1,o(!1)}a&&await t(d)},[n,r,t,g,f,s]);return{body:r,setBody:i,submitting:a,threads:d,selectedThread:f,view:s.mode,draftKind:s.mode===`new`?s.kind:`conversation`,openDraft:p,openThread:m,showHistory:h,submit:_}}function QO({files:e,reviewState:t,requestThreadAgentReply:n,applyReviewState:r}){let[i,a]=(0,v.useState)(null),o=(0,v.useMemo)(()=>S(t.threads),[t.threads]);return{draft:i,draftAnnotation:(0,v.useMemo)(()=>i?{lineNumber:i.lineNumber,side:i.side,metadata:{type:`draft`,draft:i}}:null,[i]),threadsByFileId:o,activateLine:(0,v.useCallback)((e,t,n)=>{a(r=>r?.fileId===e&&r.lineNumber===t&&r.side===n?r:{fileId:e,lineNumber:t,side:n})},[]),saveDraft:(0,v.useCallback)((t,o)=>{if(!i)return;let s=t.trim();if(!s){a(null);return}let c={kind:`line`,fileId:i.fileId,filePath:T(i,e),lineNumber:i.lineNumber,side:i.side};(async()=>{try{let e=await wO({body:s,anchor:c});r(e.state),a(null),o&&await n(e.threadId)}catch{}})()},[r,i,e,n]),cancelDraft:(0,v.useCallback)(()=>a(null),[])}}function $O({applyReviewState:e,syncReviewState:t,setThreadLoading:n}){let r=(0,v.useCallback)(async t=>{n(t,!0);try{e((await EO(t)).state)}catch{n(t,!1)}},[e,n]);return{requestThreadAgentReply:r,addReply:(0,v.useCallback)((n,i,a)=>{if(!a){t(TO({id:n,text:i}));return}(async()=>{try{e((await TO({id:n,text:i})).state),await r(n)}catch{}})()},[e,r,t]),requestAgent:(0,v.useCallback)(e=>{r(e)},[r]),toggleResolved:(0,v.useCallback)((e,n)=>{t(OO({id:e,resolved:n}))},[t]),toggleThreadCollapsed:(0,v.useCallback)((e,n)=>{t(kO({id:e,collapsed:n}))},[t]),removeThreadMessage:(0,v.useCallback)((e,n)=>{t(DO({id:e,messageIndex:n}))},[t])}}function ek({files:e,reviewState:t,applyReviewState:n,syncReviewState:r,setThreadLoading:i}){let a=$O({applyReviewState:n,syncReviewState:r,setThreadLoading:i}),o=QO({files:e,reviewState:t,requestThreadAgentReply:a.requestThreadAgentReply,applyReviewState:n}),s=ZO({reviewState:t,requestThreadAgentReply:a.requestThreadAgentReply,applyReviewState:n});return{...o,addReply:a.addReply,requestAgent:a.requestAgent,toggleResolved:a.toggleResolved,toggleThreadCollapsed:a.toggleThreadCollapsed,removeThreadMessage:a.removeThreadMessage,guideConversations:{items:s.threads,selected:s.selectedThread,view:s.view,draftKind:s.draftKind,body:s.body,submitting:s.submitting,setBody:s.setBody,openComment:()=>s.openDraft(`comment`),openConversation:()=>s.openDraft(`conversation`),open:s.openThread,showHistory:s.showHistory,submit:s.submit,exclude:e=>a.toggleResolved(e,!0),include:e=>a.toggleResolved(e,!1)}}}function tk(){let e=YO(),t=BO(),n=tO({files:e.files,reviewState:e.reviewState,applyStatePatch:e.applyStatePatch,scrollToFile:t.scrollToFile}),r=ek({files:e.files,reviewState:e.reviewState,applyReviewState:e.applyReviewState,syncReviewState:e.syncReviewState,setThreadLoading:e.setThreadLoading}),i=FO({bootstrap:e.bootstrap,reviewState:e.reviewState,setGuideLoading:e.setGuideLoading,syncReviewState:e.syncReviewState}),a=XO(),o=nO(e.files,e.reviewState.codeTheme);return(0,D.jsxs)(D.Fragment,{children:[(0,D.jsxs)(`div`,{className:`app ${t.mode}-mode`,children:[(0,D.jsx)(zO,{mode:t.mode,fileCount:e.files.length,viewedCount:e.reviewState.viewedFileIds.length,additions:n.totals.additions,deletions:n.totals.deletions,commentCount:n.unresolvedThreadCount,diffStyle:e.reviewState.diffStyle,overflowMode:e.reviewState.overflowMode,finished:a.finished,hasUnresolvedFileThreads:n.filesWithUnresolvedThreads.length>0,onModeChange:t.changeMode,onExpandAll:n.expandAll,onExpandUnresolved:n.expandUnresolved,onCollapseViewed:n.collapseViewed,onCollapseAll:n.collapseAll,onDiffStyleChange:t=>{e.applyStatePatch({diffStyle:t})},onOverflowModeChange:t=>{e.applyStatePatch({overflowMode:t})},onSubmit:a.submit,onCancel:a.cancel}),t.mode===`guide`?(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(`main`,{ref:t.contentRef,className:`content guide-content`,children:(0,D.jsx)(fO,{guide:e.reviewState.guide,pendingTopics:i.pendingTopics,pendingQuestions:i.pendingQuestions,onGenerate:i.requestGuide,onOperate:i.runGuideOperation,onComment:i.saveComment})}),(0,D.jsx)(_O,{conversations:r.guideConversations})]}):(0,D.jsx)(XD,{contentRef:t.contentRef,files:e.files,emptyContent:e.emptyContent,reviewState:e.reviewState,renderReady:o,fileState:n,threads:r,onJumpToFile:t.scrollToFile})]}),null]})}(0,y.createRoot)(document.getElementById(`root`)).render((0,D.jsx)(v.StrictMode,{children:(0,D.jsx)(tk,{})}));export{s as t};
|
|
1565
|
+
`))}function c(e,t,n,r){let i=n.enter(`tableCell`),o=n.enter(`phrasing`),s=n.containerPhrasing(e,{...r,before:a,after:a});return o(),i(),s}function l(e,t){return _T(e,{align:t,alignDelimiters:r,padding:n,stringLength:i})}function u(e,t,n){let r=e.children,i=-1,a=[],o=t.enter(`table`);for(;++i<r.length;)a[i]=d(r[i],t,n);return o(),a}function d(e,t,n){let r=e.children,i=-1,a=[],o=t.enter(`tableRow`);for(;++i<r.length;)a[i]=c(r[i],e,t,n);return o(),a}function f(e,t,n){let r=mE.inlineCode(e,t,n);return n.stack.includes(`tableCell`)&&(r=r.replace(/\|/g,`\\$&`)),r}}function wE(){return{exit:{taskListCheckValueChecked:EE,taskListCheckValueUnchecked:EE,paragraph:DE}}}function TE(){return{unsafe:[{atBreak:!0,character:`-`,after:`[:|-]`}],handlers:{listItem:OE}}}function EE(e){let t=this.stack[this.stack.length-2];t.type,t.checked=e.type===`taskListCheckValueChecked`}function DE(e){let t=this.stack[this.stack.length-2];if(t&&t.type===`listItem`&&typeof t.checked==`boolean`){let e=this.stack[this.stack.length-1];e.type;let n=e.children[0];if(n&&n.type===`text`){let r=t.children,i=-1,a;for(;++i<r.length;){let e=r[i];if(e.type===`paragraph`){a=e;break}}a===e&&(n.value=n.value.slice(1),n.value.length===0?e.children.shift():e.position&&n.position&&typeof n.position.start.offset==`number`&&(n.position.start.column++,n.position.start.offset++,e.position.start=Object.assign({},n.position.start)))}}this.exit(e)}function OE(e,t,n,r){let i=e.children[0],a=typeof e.checked==`boolean`&&i&&i.type===`paragraph`,o=`[`+(e.checked?`x`:` `)+`] `,s=n.createTracker(r);a&&s.move(o);let c=mE.listItem(e,t,n,{...r,...s.current()});return a&&(c=c.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,l)),c;function l(e){return e+o}}function kE(){return[Fw(),aT(),uT(),hE(),wE()]}function AE(e){return{extensions:[Iw(),oT(e),dT(),CE(e),TE()]}}var jE={tokenize:GE,partial:!0},ME={tokenize:KE,partial:!0},NE={tokenize:qE,partial:!0},PE={tokenize:JE,partial:!0},FE={tokenize:YE,partial:!0},IE={name:`wwwAutolink`,tokenize:UE,previous:XE},LE={name:`protocolAutolink`,tokenize:WE,previous:ZE},RE={name:`emailAutolink`,tokenize:HE,previous:QE},zE={};function BE(){return{text:zE}}for(var VE=48;VE<123;)zE[VE]=RE,VE++,VE===58?VE=65:VE===91&&(VE=97);zE[43]=RE,zE[45]=RE,zE[46]=RE,zE[95]=RE,zE[72]=[RE,LE],zE[104]=[RE,LE],zE[87]=[RE,IE],zE[119]=[RE,IE];function HE(e,t,n){let r=this,i,a;return o;function o(t){return!$E(t)||!QE.call(r,r.previous)||eD(r.events)?n(t):(e.enter(`literalAutolink`),e.enter(`literalAutolinkEmail`),s(t))}function s(t){return $E(t)?(e.consume(t),s):t===64?(e.consume(t),c):n(t)}function c(t){return t===46?e.check(FE,u,l)(t):t===45||t===95||Ry(t)?(a=!0,e.consume(t),c):u(t)}function l(t){return e.consume(t),i=!0,c}function u(o){return a&&i&&Ly(r.previous)?(e.exit(`literalAutolinkEmail`),e.exit(`literalAutolink`),t(o)):n(o)}}function UE(e,t,n){let r=this;return i;function i(t){return t!==87&&t!==119||!XE.call(r,r.previous)||eD(r.events)?n(t):(e.enter(`literalAutolink`),e.enter(`literalAutolinkWww`),e.check(jE,e.attempt(ME,e.attempt(NE,a),n),n)(t))}function a(n){return e.exit(`literalAutolinkWww`),e.exit(`literalAutolink`),t(n)}}function WE(e,t,n){let r=this,i=``,a=!1;return o;function o(t){return(t===72||t===104)&&ZE.call(r,r.previous)&&!eD(r.events)?(e.enter(`literalAutolink`),e.enter(`literalAutolinkHttp`),i+=String.fromCodePoint(t),e.consume(t),s):n(t)}function s(t){if(Ly(t)&&i.length<5)return i+=String.fromCodePoint(t),e.consume(t),s;if(t===58){let n=i.toLowerCase();if(n===`http`||n===`https`)return e.consume(t),c}return n(t)}function c(t){return t===47?(e.consume(t),a?l:(a=!0,c)):n(t)}function l(t){return t===null||By(t)||Wy(t)||Ky(t)||Gy(t)?n(t):e.attempt(ME,e.attempt(NE,u),n)(t)}function u(n){return e.exit(`literalAutolinkHttp`),e.exit(`literalAutolink`),t(n)}}function GE(e,t,n){let r=0;return i;function i(t){return(t===87||t===119)&&r<3?(r++,e.consume(t),i):t===46&&r===3?(e.consume(t),a):n(t)}function a(e){return e===null?n(e):t(e)}}function KE(e,t,n){let r,i,a;return o;function o(t){return t===46||t===95?e.check(PE,c,s)(t):t===null||Wy(t)||Ky(t)||t!==45&&Gy(t)?c(t):(a=!0,e.consume(t),o)}function s(t){return t===95?r=!0:(i=r,r=void 0),e.consume(t),o}function c(e){return i||r||!a?n(e):t(e)}}function qE(e,t){let n=0,r=0;return i;function i(o){return o===40?(n++,e.consume(o),i):o===41&&r<n?a(o):o===33||o===34||o===38||o===39||o===41||o===42||o===44||o===46||o===58||o===59||o===60||o===63||o===93||o===95||o===126?e.check(PE,t,a)(o):o===null||Wy(o)||Ky(o)?t(o):(e.consume(o),i)}function a(t){return t===41&&r++,e.consume(t),i}}function JE(e,t,n){return r;function r(o){return o===33||o===34||o===39||o===41||o===42||o===44||o===46||o===58||o===59||o===63||o===95||o===126?(e.consume(o),r):o===38?(e.consume(o),a):o===93?(e.consume(o),i):o===60||o===null||Wy(o)||Ky(o)?t(o):n(o)}function i(e){return e===null||e===40||e===91||Wy(e)||Ky(e)?t(e):r(e)}function a(e){return Ly(e)?o(e):n(e)}function o(t){return t===59?(e.consume(t),r):Ly(t)?(e.consume(t),o):n(t)}}function YE(e,t,n){return r;function r(t){return e.consume(t),i}function i(e){return Ry(e)?n(e):t(e)}}function XE(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||Wy(e)}function ZE(e){return!Ly(e)}function QE(e){return!(e===47||$E(e))}function $E(e){return e===43||e===45||e===46||e===95||Ry(e)}function eD(e){let t=e.length,n=!1;for(;t--;){let r=e[t][1];if((r.type===`labelLink`||r.type===`labelImage`)&&!r._balanced){n=!0;break}if(r._gfmAutolinkLiteralWalkedInto){n=!1;break}}return e.length>0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}var tD={tokenize:lD,partial:!0};function nD(){return{document:{91:{name:`gfmFootnoteDefinition`,tokenize:oD,continuation:{tokenize:sD},exit:cD}},text:{91:{name:`gfmFootnoteCall`,tokenize:aD},93:{name:`gfmPotentialFootnoteCall`,add:`after`,tokenize:rD,resolveTo:iD}}}}function rD(e,t,n){let r=this,i=r.events.length,a=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]),o;for(;i--;){let e=r.events[i][1];if(e.type===`labelImage`){o=e;break}if(e.type===`gfmFootnoteCall`||e.type===`labelLink`||e.type===`label`||e.type===`image`||e.type===`link`)break}return s;function s(i){if(!o||!o._balanced)return n(i);let s=Iy(r.sliceSerialize({start:o.end,end:r.now()}));return s.codePointAt(0)!==94||!a.includes(s.slice(1))?n(i):(e.enter(`gfmFootnoteCallLabelMarker`),e.consume(i),e.exit(`gfmFootnoteCallLabelMarker`),t(i))}}function iD(e,t){let n=e.length;for(;n--;)if(e[n][1].type===`labelImage`&&e[n][0]===`enter`){e[n][1];break}e[n+1][1].type=`data`,e[n+3][1].type=`gfmFootnoteCallLabelMarker`;let r={type:`gfmFootnoteCall`,start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},i={type:`gfmFootnoteCallMarker`,start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};i.end.column++,i.end.offset++,i.end._bufferIndex++;let a={type:`gfmFootnoteCallString`,start:Object.assign({},i.end),end:Object.assign({},e[e.length-1][1].start)},o={type:`chunkString`,contentType:`string`,start:Object.assign({},a.start),end:Object.assign({},a.end)},s=[e[n+1],e[n+2],[`enter`,r,t],e[n+3],e[n+4],[`enter`,i,t],[`exit`,i,t],[`enter`,a,t],[`enter`,o,t],[`exit`,o,t],[`exit`,a,t],e[e.length-2],e[e.length-1],[`exit`,r,t]];return e.splice(n,e.length-n+1,...s),e}function aD(e,t,n){let r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]),a=0,o;return s;function s(t){return e.enter(`gfmFootnoteCall`),e.enter(`gfmFootnoteCallLabelMarker`),e.consume(t),e.exit(`gfmFootnoteCallLabelMarker`),c}function c(t){return t===94?(e.enter(`gfmFootnoteCallMarker`),e.consume(t),e.exit(`gfmFootnoteCallMarker`),e.enter(`gfmFootnoteCallString`),e.enter(`chunkString`).contentType=`string`,l):n(t)}function l(s){if(a>999||s===93&&!o||s===null||s===91||Wy(s))return n(s);if(s===93){e.exit(`chunkString`);let a=e.exit(`gfmFootnoteCallString`);return i.includes(Iy(r.sliceSerialize(a)))?(e.enter(`gfmFootnoteCallLabelMarker`),e.consume(s),e.exit(`gfmFootnoteCallLabelMarker`),e.exit(`gfmFootnoteCall`),t):n(s)}return Wy(s)||(o=!0),a++,e.consume(s),s===92?u:l}function u(t){return t===91||t===92||t===93?(e.consume(t),a++,l):l(t)}}function oD(e,t,n){let r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]),a,o=0,s;return c;function c(t){return e.enter(`gfmFootnoteDefinition`)._container=!0,e.enter(`gfmFootnoteDefinitionLabel`),e.enter(`gfmFootnoteDefinitionLabelMarker`),e.consume(t),e.exit(`gfmFootnoteDefinitionLabelMarker`),l}function l(t){return t===94?(e.enter(`gfmFootnoteDefinitionMarker`),e.consume(t),e.exit(`gfmFootnoteDefinitionMarker`),e.enter(`gfmFootnoteDefinitionLabelString`),e.enter(`chunkString`).contentType=`string`,u):n(t)}function u(t){if(o>999||t===93&&!s||t===null||t===91||Wy(t))return n(t);if(t===93){e.exit(`chunkString`);let n=e.exit(`gfmFootnoteDefinitionLabelString`);return a=Iy(r.sliceSerialize(n)),e.enter(`gfmFootnoteDefinitionLabelMarker`),e.consume(t),e.exit(`gfmFootnoteDefinitionLabelMarker`),e.exit(`gfmFootnoteDefinitionLabel`),f}return Wy(t)||(s=!0),o++,e.consume(t),t===92?d:u}function d(t){return t===91||t===92||t===93?(e.consume(t),o++,u):u(t)}function f(t){return t===58?(e.enter(`definitionMarker`),e.consume(t),e.exit(`definitionMarker`),i.includes(a)||i.push(a),$(e,p,`gfmFootnoteDefinitionWhitespace`)):n(t)}function p(e){return t(e)}}function sD(e,t,n){return e.check(lb,t,e.attempt(tD,t,n))}function cD(e){e.exit(`gfmFootnoteDefinition`)}function lD(e,t,n){let r=this;return $(e,i,`gfmFootnoteDefinitionIndent`,5);function i(e){let i=r.events[r.events.length-1];return i&&i[1].type===`gfmFootnoteDefinitionIndent`&&i[2].sliceSerialize(i[1],!0).length===4?t(e):n(e)}}function uD(e){let t=(e||{}).singleTilde,n={name:`strikethrough`,tokenize:i,resolveAll:r};return t??=!0,{text:{126:n},insideSpan:{null:[n]},attentionMarkers:{null:[126]}};function r(e,t){let n=-1;for(;++n<e.length;)if(e[n][0]===`enter`&&e[n][1].type===`strikethroughSequenceTemporary`&&e[n][1]._close){let r=n;for(;r--;)if(e[r][0]===`exit`&&e[r][1].type===`strikethroughSequenceTemporary`&&e[r][1]._open&&e[n][1].end.offset-e[n][1].start.offset===e[r][1].end.offset-e[r][1].start.offset){e[n][1].type=`strikethroughSequence`,e[r][1].type=`strikethroughSequence`;let i={type:`strikethrough`,start:Object.assign({},e[r][1].start),end:Object.assign({},e[n][1].end)},a={type:`strikethroughText`,start:Object.assign({},e[r][1].end),end:Object.assign({},e[n][1].start)},o=[[`enter`,i,t],[`enter`,e[r][1],t],[`exit`,e[r][1],t],[`enter`,a,t]],s=t.parser.constructs.insideSpan.null;s&&ky(o,o.length,0,nb(s,e.slice(r+1,n),t)),ky(o,o.length,0,[[`exit`,a,t],[`enter`,e[n][1],t],[`exit`,e[n][1],t],[`exit`,i,t]]),ky(e,r-1,n-r+3,o),n=r+o.length-2;break}}for(n=-1;++n<e.length;)e[n][1].type===`strikethroughSequenceTemporary`&&(e[n][1].type=`data`);return e}function i(e,n,r){let i=this.previous,a=this.events,o=0;return s;function s(t){return i===126&&a[a.length-1][1].type!==`characterEscape`?r(t):(e.enter(`strikethroughSequenceTemporary`),c(t))}function c(a){let s=tb(i);if(a===126)return o>1?r(a):(e.consume(a),o++,c);if(o<2&&!t)return r(a);let l=e.exit(`strikethroughSequenceTemporary`),u=tb(a);return l._open=!u||u===2&&!!s,l._close=!s||s===2&&!!u,n(a)}}}var dD=class{constructor(){this.map=[]}add(e,t,n){fD(this,e,t,n)}consume(e){if(this.map.sort(function(e,t){return e[0]-t[0]}),this.map.length===0)return;let t=this.map.length,n=[];for(;t>0;)--t,n.push(e.slice(this.map[t][0]+this.map[t][1]),this.map[t][2]),e.length=this.map[t][0];n.push(e.slice()),e.length=0;let r=n.pop();for(;r;){for(let t of r)e.push(t);r=n.pop()}this.map.length=0}};function fD(e,t,n,r){let i=0;if(n!==0||r.length!==0){for(;i<e.map.length;){if(e.map[i][0]===t){e.map[i][1]+=n,e.map[i][2].push(...r);return}i+=1}e.map.push([t,n,r])}}function pD(e,t){let n=!1,r=[];for(;t<e.length;){let i=e[t];if(n){if(i[0]===`enter`)i[1].type===`tableContent`&&r.push(e[t+1][1].type===`tableDelimiterMarker`?`left`:`none`);else if(i[1].type===`tableContent`){if(e[t-1][1].type===`tableDelimiterMarker`){let e=r.length-1;r[e]=r[e]===`left`?`center`:`right`}}else if(i[1].type===`tableDelimiterRow`)break}else i[0]===`enter`&&i[1].type===`tableDelimiterRow`&&(n=!0);t+=1}return r}function mD(){return{flow:{null:{name:`table`,tokenize:hD,resolveAll:gD}}}}function hD(e,t,n){let r=this,i=0,a=0,o;return s;function s(e){let t=r.events.length-1;for(;t>-1;){let e=r.events[t][1].type;if(e===`lineEnding`||e===`linePrefix`)t--;else break}let i=t>-1?r.events[t][1].type:null,a=i===`tableHead`||i===`tableRow`?S:c;return a===S&&r.parser.lazy[r.now().line]?n(e):a(e)}function c(t){return e.enter(`tableHead`),e.enter(`tableRow`),l(t)}function l(e){return e===124?u(e):(o=!0,a+=1,u(e))}function u(t){return t===null?n(t):Z(t)?a>1?(a=0,r.interrupt=!0,e.exit(`tableRow`),e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),p):n(t):Q(t)?$(e,u,`whitespace`)(t):(a+=1,o&&(o=!1,i+=1),t===124?(e.enter(`tableCellDivider`),e.consume(t),e.exit(`tableCellDivider`),o=!0,u):(e.enter(`data`),d(t)))}function d(t){return t===null||t===124||Wy(t)?(e.exit(`data`),u(t)):(e.consume(t),t===92?f:d)}function f(t){return t===92||t===124?(e.consume(t),d):d(t)}function p(t){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(t):(e.enter(`tableDelimiterRow`),o=!1,Q(t)?$(e,m,`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(t):m(t))}function m(t){return t===45||t===58?g(t):t===124?(o=!0,e.enter(`tableCellDivider`),e.consume(t),e.exit(`tableCellDivider`),h):x(t)}function h(t){return Q(t)?$(e,g,`whitespace`)(t):g(t)}function g(t){return t===58?(a+=1,o=!0,e.enter(`tableDelimiterMarker`),e.consume(t),e.exit(`tableDelimiterMarker`),_):t===45?(a+=1,_(t)):t===null||Z(t)?b(t):x(t)}function _(t){return t===45?(e.enter(`tableDelimiterFiller`),v(t)):x(t)}function v(t){return t===45?(e.consume(t),v):t===58?(o=!0,e.exit(`tableDelimiterFiller`),e.enter(`tableDelimiterMarker`),e.consume(t),e.exit(`tableDelimiterMarker`),y):(e.exit(`tableDelimiterFiller`),y(t))}function y(t){return Q(t)?$(e,b,`whitespace`)(t):b(t)}function b(n){return n===124?m(n):n===null||Z(n)?!o||i!==a?x(n):(e.exit(`tableDelimiterRow`),e.exit(`tableHead`),t(n)):x(n)}function x(e){return n(e)}function S(t){return e.enter(`tableRow`),C(t)}function C(n){return n===124?(e.enter(`tableCellDivider`),e.consume(n),e.exit(`tableCellDivider`),C):n===null||Z(n)?(e.exit(`tableRow`),t(n)):Q(n)?$(e,C,`whitespace`)(n):(e.enter(`data`),w(n))}function w(t){return t===null||t===124||Wy(t)?(e.exit(`data`),C(t)):(e.consume(t),t===92?T:w)}function T(t){return t===92||t===124?(e.consume(t),w):w(t)}}function gD(e,t){let n=-1,r=!0,i=0,a=[0,0,0,0],o=[0,0,0,0],s=!1,c=0,l,u,d,f=new dD;for(;++n<e.length;){let p=e[n],m=p[1];p[0]===`enter`?m.type===`tableHead`?(s=!1,c!==0&&(vD(f,t,c,l,u),u=void 0,c=0),l={type:`table`,start:Object.assign({},m.start),end:Object.assign({},m.end)},f.add(n,0,[[`enter`,l,t]])):m.type===`tableRow`||m.type===`tableDelimiterRow`?(r=!0,d=void 0,a=[0,0,0,0],o=[0,n+1,0,0],s&&(s=!1,u={type:`tableBody`,start:Object.assign({},m.start),end:Object.assign({},m.end)},f.add(n,0,[[`enter`,u,t]])),i=m.type===`tableDelimiterRow`?2:u?3:1):i&&(m.type===`data`||m.type===`tableDelimiterMarker`||m.type===`tableDelimiterFiller`)?(r=!1,o[2]===0&&(a[1]!==0&&(o[0]=o[1],d=_D(f,t,a,i,void 0,d),a=[0,0,0,0]),o[2]=n)):m.type===`tableCellDivider`&&(r?r=!1:(a[1]!==0&&(o[0]=o[1],d=_D(f,t,a,i,void 0,d)),a=o,o=[a[1],n,0,0])):m.type===`tableHead`?(s=!0,c=n):m.type===`tableRow`||m.type===`tableDelimiterRow`?(c=n,a[1]===0?o[1]!==0&&(d=_D(f,t,o,i,n,d)):(o[0]=o[1],d=_D(f,t,a,i,n,d)),i=0):i&&(m.type===`data`||m.type===`tableDelimiterMarker`||m.type===`tableDelimiterFiller`)&&(o[3]=n)}for(c!==0&&vD(f,t,c,l,u),f.consume(t.events),n=-1;++n<t.events.length;){let e=t.events[n];e[0]===`enter`&&e[1].type===`table`&&(e[1]._align=pD(t.events,n))}return e}function _D(e,t,n,r,i,a){let o=r===1?`tableHeader`:r===2?`tableDelimiter`:`tableData`;n[0]!==0&&(a.end=Object.assign({},yD(t.events,n[0])),e.add(n[0],0,[[`exit`,a,t]]));let s=yD(t.events,n[1]);if(a={type:o,start:Object.assign({},s),end:Object.assign({},s)},e.add(n[1],0,[[`enter`,a,t]]),n[2]!==0){let i=yD(t.events,n[2]),a=yD(t.events,n[3]),o={type:`tableContent`,start:Object.assign({},i),end:Object.assign({},a)};if(e.add(n[2],0,[[`enter`,o,t]]),r!==2){let r=t.events[n[2]],i=t.events[n[3]];if(r[1].end=Object.assign({},i[1].end),r[1].type=`chunkText`,r[1].contentType=`text`,n[3]>n[2]+1){let t=n[2]+1,r=n[3]-n[2]-1;e.add(t,r,[])}}e.add(n[3]+1,0,[[`exit`,o,t]])}return i!==void 0&&(a.end=Object.assign({},yD(t.events,i)),e.add(i,0,[[`exit`,a,t]]),a=void 0),a}function vD(e,t,n,r,i){let a=[],o=yD(t.events,n);i&&(i.end=Object.assign({},o),a.push([`exit`,i,t])),r.end=Object.assign({},o),a.push([`exit`,r,t]),e.add(n+1,0,a)}function yD(e,t){let n=e[t],r=n[0]===`enter`?`start`:`end`;return n[1][r]}var bD={name:`tasklistCheck`,tokenize:SD};function xD(){return{text:{91:bD}}}function SD(e,t,n){let r=this;return i;function i(t){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(t):(e.enter(`taskListCheck`),e.enter(`taskListCheckMarker`),e.consume(t),e.exit(`taskListCheckMarker`),a)}function a(t){return Wy(t)?(e.enter(`taskListCheckValueUnchecked`),e.consume(t),e.exit(`taskListCheckValueUnchecked`),o):t===88||t===120?(e.enter(`taskListCheckValueChecked`),e.consume(t),e.exit(`taskListCheckValueChecked`),o):n(t)}function o(t){return t===93?(e.enter(`taskListCheckMarker`),e.consume(t),e.exit(`taskListCheckMarker`),e.exit(`taskListCheck`),s):n(t)}function s(r){return Z(r)?t(r):Q(r)?e.check({tokenize:CD},t,n)(r):n(r)}}function CD(e,t,n){return $(e,r,`whitespace`);function r(e){return e===null?n(e):t(e)}}function wD(e){return My([BE(),nD(),uD(e),mD(),xD()])}var TD={};function ED(e){let t=this,n=e||TD,r=t.data(),i=r.micromarkExtensions||=[],a=r.fromMarkdownExtensions||=[],o=r.toMarkdownExtensions||=[];i.push(wD(n)),a.push(kE()),o.push(AE(n))}function DD({checked:e,label:t,onChange:n}){return(0,D.jsxs)(`label`,{className:`switch`,children:[(0,D.jsx)(`input`,{className:`switch-input`,type:`checkbox`,role:`switch`,checked:e,onChange:e=>n(e.target.checked)}),(0,D.jsx)(`span`,{className:`switch-track`,"aria-hidden":`true`,children:(0,D.jsx)(`span`,{className:`switch-thumb`})}),(0,D.jsx)(`span`,{className:`switch-label`,children:t})]})}var OD=new Map,kD={bash:`Bash`,c:`C`,cpp:`C++`,cs:`C#`,csharp:`C#`,css:`CSS`,diff:`Diff`,dockerfile:`Dockerfile`,go:`Go`,html:`HTML`,java:`Java`,javascript:`JavaScript`,js:`JavaScript`,json:`JSON`,jsonc:`JSON with Comments`,jsx:`JSX`,kotlin:`Kotlin`,markdown:`Markdown`,md:`Markdown`,php:`PHP`,plaintext:`Plain text`,py:`Python`,python:`Python`,rb:`Ruby`,rs:`Rust`,ruby:`Ruby`,rust:`Rust`,scss:`SCSS`,sh:`Shell`,shell:`Shell`,sql:`SQL`,swift:`Swift`,text:`Plain text`,ts:`TypeScript`,tsx:`TSX`,txt:`Plain text`,typescript:`TypeScript`,xml:`XML`,yaml:`YAML`,yml:`YAML`,zsh:`Zsh`};function AD({className:e,children:t}){let[n,r]=(0,v.useState)(null),[i,a]=(0,v.useState)(!1),o=e?.match(/language-([^\s]+)/)?.[1]??`text`,s=kD[o.toLowerCase()]??o,c=String(t??``).replace(/\n$/,``);return(0,v.useEffect)(()=>{let e=!1;return r(null),jD(c,o).then(t=>{e||r(t)}),()=>{e=!0}},[c,o]),(0,D.jsxs)(`div`,{className:`markdown-code-block${i?` markdown-code-block-wrap`:``}`,children:[(0,D.jsxs)(`div`,{className:`markdown-code-block-header`,children:[(0,D.jsx)(`span`,{className:`markdown-code-block-language`,children:s}),(0,D.jsx)(DD,{checked:i,label:`Wrap`,onChange:a})]}),(0,D.jsx)(`div`,{className:`markdown-code-block-content`,children:n===null?(0,D.jsx)(`pre`,{children:(0,D.jsx)(`code`,{children:t})}):(0,D.jsx)(`div`,{dangerouslySetInnerHTML:{__html:n}})})]})}async function jD(e,t){let n=`${t}\u0000${e}`,r=OD.get(n);if(r)return r;let i=MD(e,t).catch(()=>null);return OD.set(n,i),i}async function MD(e,t){try{return await hs(e,{lang:t,theme:`github-dark-default`})}catch{return hs(e,{lang:`text`,theme:`github-dark-default`})}}function ND({content:e,className:t,variant:n}){let r=[`markdown-content`,n?`markdown-content-${n}`:null,t].filter(Boolean).join(` `);return(0,D.jsx)(`div`,{className:r,children:(0,D.jsx)(Cw,{remarkPlugins:[ED],components:{table({children:e}){return(0,D.jsx)(`div`,{className:`markdown-table-scroll`,children:(0,D.jsx)(`table`,{children:e})})},pre({children:e}){if((0,v.isValidElement)(e)){let{className:t,children:n}=e.props;return(0,D.jsx)(AD,{className:t,children:n})}return(0,D.jsx)(`pre`,{children:e})}},children:e})})}function PD({thread:e,onDeleteMessage:t}){return(0,D.jsxs)(`div`,{className:`thread-message-list`,children:[e.messages.map((e,n)=>(0,D.jsxs)(`div`,{className:`thread-message thread-message-${e.role}`,children:[(0,D.jsxs)(`div`,{className:`thread-message-header`,children:[(0,D.jsx)(`span`,{className:`thread-message-role`,children:e.role===`user`?`you`:`agent`}),(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,onClick:()=>t(n),"aria-label":`Delete ${e.role===`user`?`your`:`agent`} comment`,title:`delete comment`,children:(0,D.jsx)(bv,{size:13})})]}),(0,D.jsx)(ND,{content:e.text,variant:`thread`})]},`${e.role}:${n}:${e.text}`)),e.loading&&(0,D.jsxs)(`div`,{className:`thread-message thread-message-assistant`,children:[(0,D.jsx)(`span`,{className:`thread-message-role`,children:`agent`}),(0,D.jsx)(`span`,{className:`thread-message-thinking`,children:`thinking…`})]})]})}var FD=(0,v.memo)(function({thread:e,onAddReply:t,onRequestAgent:n,onToggleResolved:r,onToggleCollapsed:i,onDeleteMessage:a}){let[o,s]=(0,v.useState)(!1),[c,l]=(0,v.useState)(!1),u=e.messages[e.messages.length-1]?.role===`user`&&!e.loading&&!e.resolved,d=e.messages.length,f=`${e.resolved?`Resolved thread`:`Thread`} with ${d} comment${d===1?``:`s`}`,p=e.resolved?`Reopen`:`Resolve`,m=(0,v.useCallback)(e=>{s(!1),t(e,c),l(!1)},[t,c]),h=(0,v.useCallback)(()=>{r(!e.resolved)},[r,e.resolved]),g=(0,v.useCallback)(()=>{l(!1),s(!1)},[]);return e.collapsed?(0,D.jsx)(`div`,{className:`thread-card collapsed${e.resolved?` resolved`:``}`,children:(0,D.jsx)(`div`,{className:`thread-collapsed-row`,children:(0,D.jsxs)(X,{variant:`unstyled`,onClick:()=>i(!1),"aria-label":`Expand thread`,"aria-expanded":!1,children:[(0,D.jsx)(fv,{size:14}),(0,D.jsx)(`span`,{className:`thread-summary`,children:f})]})})}):(0,D.jsxs)(`div`,{className:`thread-card${e.resolved?` resolved`:``}`,children:[(0,D.jsx)(`div`,{className:`thread-header-row`,children:(0,D.jsxs)(X,{variant:`unstyled`,onClick:()=>i(!0),"aria-label":`Collapse thread`,"aria-expanded":!0,children:[(0,D.jsx)(dv,{size:14}),(0,D.jsx)(`span`,{className:`thread-summary`,children:f})]})}),(0,D.jsx)(PD,{thread:e,onDeleteMessage:a}),(0,D.jsx)(`div`,{className:`thread-footer`,children:o?(0,D.jsx)(Ev,{inputClassName:`thread-reply-input`,actionsClassName:`thread-actions`,placeholder:`Reply…`,submitLabel:`Comment`,autoFocus:!0,onSubmit:m,onCancel:g,children:(0,D.jsx)(Tv,{checked:c,label:`Ask agent`,onChange:l})}):(0,D.jsxs)(`div`,{className:`thread-actions`,children:[(0,D.jsx)(X,{variant:`ghost`,onClick:h,children:p}),(0,D.jsx)(X,{onClick:()=>s(!0),children:`Reply`}),u&&(0,D.jsxs)(X,{onClick:n,children:[(0,D.jsx)(yv,{size:14}),`Ask agent`]})]})})]})}),ID={theme:Sv,themeType:`dark`,diffStyle:`unified`,diffIndicators:`none`,hunkSeparators:`line-info-basic`,lineDiffType:`word-alt`,disableFileHeader:!0,overflow:`wrap`,unsafeCSS:[`:host { --diffs-dark-bg: var(--surface); --diffs-bg: var(--surface); font-weight: var(--font-weight-code); }`,`pre { background-color: var(--surface) !important; }`,`[data-annotation-slot], [data-annotation-content] { font-family: var(--font-family-ui); }`,`[data-annotation-slot] code, [data-annotation-slot] pre, [data-annotation-content] code, [data-annotation-content] pre { font-family: var(--font-family-code); }`,`[data-overflow='wrap'] [data-code] { overflow-x: hidden; }`,`[data-overflow='wrap'] [data-annotation-content] { width: auto; }`].join(` `)},LD=(0,v.memo)(function({file:e,diffStyle:t,overflowMode:n,codeTheme:r,collapsed:i,viewed:a,annotations:o,unresolvedThreadCount:s,renderReady:c,onToggleCollapsed:l,onToggleViewed:u,onLineActivate:d,onSaveDraft:f,onCancelDraft:p,onAddReply:m,onRequestAgent:h,onToggleResolved:g,onToggleThreadCollapsed:_,onDeleteThreadMessage:y}){let b=(0,v.useMemo)(()=>{let i=t===`split`?`split`:`unified`;return{...ID,theme:r,diffStyle:i,overflow:n,onLineNumberClick:({lineNumber:t,annotationSide:n})=>{d(e.id,t,n)}}},[r,t,e.id,d,n]),x=(0,v.useCallback)(e=>{if(e.metadata.type===`draft`)return(0,D.jsx)(Dv,{onSave:f,onCancel:p});let{thread:t}=e.metadata;return(0,D.jsx)(FD,{thread:t,onAddReply:(e,n)=>m(t.id,e,n),onRequestAgent:()=>h(t.id),onToggleResolved:e=>g(t.id,e),onToggleCollapsed:e=>_(t.id,e),onDeleteMessage:e=>y(t.id,e)})},[m,p,h,f,y,g,_]);return(0,D.jsxs)(`section`,{className:`file-section${i?` collapsed`:``}`,id:`file-${e.id}`,children:[(0,D.jsxs)(`div`,{className:`file-header`,children:[(0,D.jsxs)(X,{variant:`unstyled`,className:`file-toggle`,onClick:()=>l(e.id),"aria-label":i?`Expand file`:`Collapse file`,children:[i?(0,D.jsx)(uv,{size:14}):(0,D.jsx)(lv,{size:14}),(0,D.jsx)(`span`,{className:`file-path`,children:e.displayPath}),s>0&&(0,D.jsxs)(`span`,{className:`file-thread-count`,"aria-label":`${s} unresolved comment thread${s===1?``:`s`}`,title:`${s} unresolved comment thread${s===1?``:`s`}`,children:[(0,D.jsx)(gv,{size:12}),(0,D.jsx)(`span`,{children:s})]})]}),(0,D.jsxs)(`div`,{className:`file-meta`,children:[(0,D.jsx)(Ov,{additions:e.additions,deletions:e.deletions}),(0,D.jsx)(Tv,{checked:a,label:`Viewed`,className:`viewed-checkbox`,onChange:()=>u(e.id)})]})]}),!i&&(0,D.jsx)(`div`,{className:`file-body`,children:c?(0,D.jsx)(Z_,{className:`diff-view`,fileDiff:e.file,options:b,lineAnnotations:o,renderAnnotation:x}):(0,D.jsx)(`div`,{className:`diff-placeholder`,children:`preparing diff…`})})]})});function RD({directory:e}){let t=(0,v.useRef)(null),[n,r]=(0,v.useState)(()=>BD(e)),i=(0,v.useMemo)(()=>zD(),[]);return(0,v.useLayoutEffect)(()=>{let n=t.current;if(!n)return;let a=()=>{let t=window.getComputedStyle(n);r(VD(e,n.clientWidth,t.font,i))};a();let o=new ResizeObserver(a);return o.observe(n),()=>{o.disconnect()}},[e,i]),(0,D.jsx)(`div`,{ref:t,className:`sidebar-file-directory`,title:e,children:n})}function zD(){let e=document.createElement(`canvas`).getContext(`2d`);return(t,n)=>e?(e.font=n,e.measureText(t).width):t.length*8}function BD(e){let t=UD(e);return t.length<=2?e:`${t[0]}/…/${t[t.length-1]}/`}function VD(e,t,n,r){let i=HD(e);for(let e of i)if(r(e,n)<=t)return e;return i[i.length-1]??e}function HD(e){let t=UD(e),n=[e];return t.length>2&&(n.push(`${t[0]}/…/${t.slice(1).join(`/`)}/`),n.push(`${t[0]}/…/${t.slice(-2).join(`/`)}/`),n.push(`${t[0]}/…/${t[t.length-1]}/`)),t.length>0&&n.push(`…/${t[t.length-1]}/`),[...new Set(n)]}function UD(e){return e===`./`?[]:e.split(`/`).filter(Boolean)}function WD({files:e,viewed:t,onJumpToFile:n}){let r=GD(e);return(0,D.jsx)(`aside`,{className:`sidebar`,children:(0,D.jsx)(`div`,{className:`sidebar-file-list`,children:r.map((e,r)=>(0,D.jsxs)(`div`,{className:`sidebar-file-group`,children:[(0,D.jsx)(RD,{directory:e.directory}),e.files.map(e=>(0,D.jsxs)(`button`,{type:`button`,className:`sidebar-file-item${t[e.id]?` viewed`:``}`,onClick:()=>n(e.id),title:e.displayPath,children:[(0,D.jsx)(`span`,{className:`sidebar-file-status ${e.status}`,"aria-label":e.status,children:YD(e.status)}),(0,D.jsx)(`span`,{className:`sidebar-file-name`,children:qD(e)}),(0,D.jsx)(Ov,{additions:e.additions,deletions:e.deletions,className:`sidebar-stats`})]},e.id))]},`${e.directory}:${r}`))})})}function GD(e){let t=[];for(let n of e){let e=KD(n.newRepoPath),r=t[t.length-1];if(r?.directory===e){r.files.push(n);continue}t.push({directory:e,files:[n]})}return t}function KD(e){let t=e.lastIndexOf(`/`);return t<0?`./`:`${e.slice(0,t)}/`}function qD(e){return JD(e.newRepoPath)}function JD(e){let t=e.lastIndexOf(`/`);return t<0?e:e.slice(t+1)}function YD(e){switch(e){case`added`:return`A`;case`deleted`:return`D`;case`renamed`:return`R`;case`copied`:return`C`;case`type-changed`:return`T`;case`unmerged`:return`U`;case`modified`:return`M`;case`unknown`:return`?`}}var XD=[];function ZD({contentRef:e,files:t,emptyContent:n,reviewState:r,renderReady:i,fileState:a,threads:o,onJumpToFile:s}){return(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(WD,{files:t,viewed:a.viewed,onJumpToFile:s}),(0,D.jsxs)(`main`,{ref:e,className:`content`,children:[t.length===0&&(0,D.jsx)(`div`,{className:`empty`,children:n}),t.map(e=>{let t=w(o.threadsByFileId.get(e.id)??XD,e.id,o.draft,o.draftAnnotation);return(0,D.jsx)(LD,{file:e,diffStyle:r.diffStyle,overflowMode:r.overflowMode,codeTheme:r.codeTheme,collapsed:a.collapsed[e.id]??!1,viewed:a.viewed[e.id]??!1,annotations:t,unresolvedThreadCount:a.unresolvedThreadCountsByFileId.get(e.id)??0,renderReady:i,onToggleCollapsed:a.toggleCollapsed,onToggleViewed:a.toggleViewed,onLineActivate:o.activateLine,onSaveDraft:o.saveDraft,onCancelDraft:o.cancelDraft,onAddReply:o.addReply,onRequestAgent:o.requestAgent,onToggleResolved:o.toggleResolved,onToggleThreadCollapsed:o.toggleThreadCollapsed,onDeleteThreadMessage:o.removeThreadMessage},e.id)})]})]})}function QD(e){return Object.fromEntries(e.map(e=>[e,!0]))}function $D(e,t){return e.includes(t)?e.filter(e=>e!==t):[...e,t]}function eO(e){return[...new Set(e)]}function tO(e,t){return{additions:e.additions+t.additions,deletions:e.deletions+t.deletions}}function nO({files:e,reviewState:t,applyStatePatch:n,scrollToFile:r}){let i=(0,v.useRef)(null),a=(0,v.useMemo)(()=>QD(t.collapsedFileIds),[t.collapsedFileIds]),o=(0,v.useMemo)(()=>QD(t.viewedFileIds),[t.viewedFileIds]),s=(0,v.useMemo)(()=>t.threads.filter(e=>!e.resolved),[t.threads]),c=(0,v.useMemo)(()=>s.filter(b),[s]),l=(0,v.useMemo)(()=>eO(c.map(e=>e.anchor.fileId)),[c]),u=(0,v.useMemo)(()=>C(c),[c]),d=(0,v.useMemo)(()=>e.reduce(tO,{additions:0,deletions:0}),[e]),f=(0,v.useCallback)(e=>{n({collapsedFileIds:$D(t.collapsedFileIds,e)})},[n,t.collapsedFileIds]),p=(0,v.useCallback)(e=>{let r=$D(t.viewedFileIds,e),a=r.includes(e),o=a?eO([...t.collapsedFileIds,e]):t.collapsedFileIds;i.current=a&&!t.collapsedFileIds.includes(e)?e:null,n({viewedFileIds:r,collapsedFileIds:o},{onError:()=>{i.current=null}})},[n,t.collapsedFileIds,t.viewedFileIds]),m=(0,v.useCallback)(()=>{n({collapsedFileIds:[]})},[n]),h=(0,v.useCallback)(()=>{n({collapsedFileIds:e.map(e=>e.id)})},[n,e]),g=(0,v.useCallback)(()=>{if(l.length===0)return;let e=new Set(l);n({collapsedFileIds:t.collapsedFileIds.filter(t=>!e.has(t))})},[n,l,t.collapsedFileIds]),_=(0,v.useCallback)(()=>{n({collapsedFileIds:eO([...t.collapsedFileIds,...t.viewedFileIds])})},[n,t.collapsedFileIds,t.viewedFileIds]);return(0,v.useLayoutEffect)(()=>{let e=i.current;e&&(i.current=null,r(e,`auto`))},[t.collapsedFileIds,r]),{collapsed:a,viewed:o,unresolvedThreadCount:c.length,filesWithUnresolvedThreads:l,unresolvedThreadCountsByFileId:u,totals:d,toggleCollapsed:f,toggleViewed:p,expandAll:m,collapseAll:h,expandUnresolved:g,collapseViewed:_}}function rO(e,t){let[n,r]=(0,v.useState)(!1);return(0,v.useEffect)(()=>{if(e.length===0){r(!1);return}let n=!0;return r(!1),iO(e,t).then(()=>{n&&r(!0)}),()=>{n=!1}},[t,e]),n}async function iO(e,t){await Promise.all([document.fonts?.ready??Promise.resolve(),vd({themes:[t],langs:aO(e)}).catch(()=>void 0)])}function aO(e){let t=new Set;for(let n of e)t.add(n.file.lang??Sd(n.file.name));return[...t]}function oO({value:e,options:t,label:n,onChange:r}){return(0,D.jsx)(`div`,{className:`toggle-group`,role:`radiogroup`,"aria-label":n,children:t.map(t=>(0,D.jsx)(X,{variant:`ghost`,active:e===t.value,role:`radio`,"aria-checked":e===t.value,onClick:()=>r(t.value),children:t.label},t.value))})}function sO({target:e,comments:t,requestChanges:n,onComment:r}){let[i,a]=(0,v.useState)(null),o=Cv(e),s=t.find(e=>Cv(e.target)===o),c=s?.body.trim()?`Edit your comment`:`Write a comment`,l=[{value:`comment`,label:c},{value:`changes`,label:`Ask for changes`}],[u,d]=(0,v.useState)(s?.body??``);if((0,v.useEffect)(()=>{d(s?.body??``)},[s?.body]),(0,v.useEffect)(()=>{!n&&i===`changes`&&a(null)},[i,n]),i===null)return(0,D.jsxs)(`div`,{className:`guide-feedback-actions`,"aria-label":`Feedback`,children:[(0,D.jsx)(X,{variant:`ghost`,onClick:()=>a(`comment`),children:c}),n&&(0,D.jsx)(X,{variant:`ghost`,onClick:()=>a(`changes`),children:`Ask for changes`})]});let f=n?(0,D.jsx)(oO,{value:i,options:l,label:`Feedback mode`,onChange:a}):void 0;return i===`changes`&&n?(0,D.jsx)(cO,{label:`Feedback`,heading:f,placeholder:n.placeholder,submitLabel:n.submitLabel,onClose:()=>a(null),onSubmit:e=>{n.onSubmit(e),a(null)}}):(0,D.jsx)(cO,{label:`Feedback`,heading:f,placeholder:`Write your review comment…`,submitLabel:`Save comment`,value:u,allowEmptySubmit:!!s,onValueChange:d,onClose:()=>a(null),onSubmit:t=>{r(e,t),a(null)}})}function cO({label:e,heading:t,placeholder:n,submitLabel:r,value:i,allowEmptySubmit:a,onValueChange:o,onClose:s,onSubmit:c}){return(0,D.jsxs)(`aside`,{className:`guide-feedback-card`,"aria-label":e,children:[t&&(0,D.jsx)(`header`,{className:`guide-feedback-card-heading`,children:t}),(0,D.jsx)(Ev,{className:`guide-feedback-form`,inputClassName:`guide-feedback-input`,actionsClassName:`guide-feedback-footer`,placeholder:n,submitLabel:r,cancelLabel:`Close`,value:i,autoFocus:!0,allowEmptySubmit:a,onValueChange:o,onCancel:s,onSubmit:c})]})}function lO({content:e,comments:t,loading:n,onComment:r}){return(0,D.jsxs)(`section`,{className:`guide-section`,"aria-labelledby":`guide-title`,children:[(0,D.jsxs)(`header`,{className:`guide-section-heading`,children:[(0,D.jsx)(`h2`,{id:`guide-title`,className:`guide-section-title`,children:`Orientation`}),n&&(0,D.jsx)(`output`,{className:`guide-loading`,children:`Updating…`})]}),(0,D.jsx)(ND,{content:e,variant:`guide`}),(0,D.jsx)(sO,{comments:t,target:{kind:`orientation`},onComment:r})]})}function uO({questions:e,pendingQuestions:t,comments:n,onOperate:r,onComment:i}){let[a,o]=(0,v.useState)(!1);return(0,D.jsxs)(`section`,{className:`guide-section`,"aria-labelledby":`guide-questions-title`,children:[(0,D.jsx)(`header`,{className:`guide-section-heading`,children:(0,D.jsx)(`h2`,{id:`guide-questions-title`,className:`guide-section-title`,children:`Questions`})}),(e.length>0||t.length>0)&&(0,D.jsxs)(`ul`,{className:`guide-question-list`,children:[e.map(e=>(0,D.jsx)(`li`,{className:`guide-question-item`,children:(0,D.jsxs)(`details`,{className:`guide-question`,children:[(0,D.jsxs)(`summary`,{children:[(0,D.jsx)(uv,{className:`guide-question-icon`,size:16}),(0,D.jsx)(`span`,{className:`guide-question-label`,children:(0,D.jsx)(`strong`,{children:e.question})})]}),(0,D.jsxs)(`div`,{className:`guide-question-answer`,children:[(0,D.jsx)(ND,{content:e.answer,variant:`guide`}),(0,D.jsx)(sO,{comments:n,target:{kind:`question`,questionId:e.id},onComment:i})]})]})},e.id)),t.map(e=>(0,D.jsx)(`li`,{className:`guide-question-item`,children:(0,D.jsx)(`div`,{className:`guide-question-pending`,role:`status`,"aria-label":`${e.question}, generating answer`,children:(0,D.jsx)(`span`,{className:`guide-question-label`,children:(0,D.jsx)(`strong`,{children:e.question})})})},e.id))]}),a?(0,D.jsx)(cO,{label:`Ask a question`,placeholder:`Write the question you want answered…`,submitLabel:`Ask`,onClose:()=>o(!1),onSubmit:e=>{r({kind:`question.ask`,question:e}),o(!1)}}):(0,D.jsx)(`div`,{className:`guide-question-actions`,children:(0,D.jsx)(X,{variant:`ghost`,onClick:()=>o(!0),children:`Ask a question`})})]})}function dO({topic:e,comments:t,onOperate:n,onComment:r}){return(0,D.jsxs)(`article`,{className:`guide-topic-content`,children:[(0,D.jsx)(`header`,{className:`guide-topic-heading`,children:(0,D.jsx)(`h3`,{children:e.heading})}),(0,D.jsx)(ND,{content:e.body,variant:`guide`}),(0,D.jsx)(sO,{comments:t,target:{kind:`topic`,topicId:e.id},requestChanges:{placeholder:`Describe the changes you want…`,submitLabel:`Request changes`,onSubmit:t=>{n({kind:`topic.revise`,topicId:e.id,request:t})}},onComment:r})]})}function fO({topics:e,pendingTopics:t,comments:n,onOperate:r,onComment:i}){let[a,o]=(0,v.useState)(!1),[s,c]=(0,v.useState)(()=>e[0]?.id??null),l=(0,v.useRef)(null),u=(0,v.useRef)(null),d=(0,v.useMemo)(()=>t.filter(e=>e.kind===`add`),[t]),f=(0,v.useMemo)(()=>new Set(t.flatMap(e=>e.kind===`revise`?[e.topicId]:[])),[t]),p=d.find(e=>e.id===s),m=p?void 0:e.find(e=>e.id===s)??e[0];return(0,v.useEffect)(()=>{let t=l.current;t===null||e.length<=t||(c(e[e.length-1]?.id??null),l.current=null)},[e]),(0,v.useEffect)(()=>{let e=u.current;e===null||d.length<=e||(c(d[d.length-1]?.id??null),u.current=null)},[d]),(0,D.jsxs)(`section`,{className:`guide-section`,"aria-label":`Topics`,children:[(0,D.jsxs)(`div`,{className:`guide-topic-cloud`,"aria-label":`Guide topics`,children:[e.map(e=>{let t=!a&&e.id===m?.id,n=f.has(e.id);return(0,D.jsxs)(X,{variant:t?`default`:`ghost`,active:t,pill:!0,"aria-label":n?`${e.label}, updating`:void 0,"aria-pressed":t,onClick:()=>{c(e.id),o(!1)},children:[e.label,n&&(0,D.jsx)(`span`,{className:`guide-topic-working-dot`,"aria-hidden":`true`})]},e.id)}),d.map(e=>{let t=!a&&e.id===p?.id;return(0,D.jsxs)(X,{variant:t?`default`:`ghost`,active:t,pill:!0,"aria-label":`New topic, generating`,"aria-pressed":t,onClick:()=>{c(e.id),o(!1)},children:[`New topic`,(0,D.jsx)(`span`,{className:`guide-topic-working-dot`,"aria-hidden":`true`})]},e.id)}),(0,D.jsx)(X,{variant:a?`default`:`ghost`,active:a,muted:!a,pill:!0,"aria-pressed":a,onClick:()=>o(!0),children:`Ask about…`})]}),a?(0,D.jsx)(cO,{label:`Ask about a topic`,placeholder:`Describe the topic you want explained…`,submitLabel:`Ask`,onClose:()=>o(!1),onSubmit:t=>{l.current=e.length,u.current=d.length,r({kind:`topic.add`,request:t}),o(!1)}}):p?(0,D.jsxs)(`article`,{className:`guide-topic-content`,role:`status`,children:[(0,D.jsx)(`header`,{className:`guide-topic-heading`,children:(0,D.jsx)(`h3`,{children:`Generating topic…`})}),(0,D.jsx)(`p`,{className:`guide-topic-generating`,children:`Building a focused explanation for this topic.`})]}):m&&(0,D.jsx)(dO,{topic:m,comments:n,onOperate:r,onComment:i},m.id)]})}function pO({guide:e,pendingTopics:t,pendingQuestions:n,onGenerate:r,onOperate:i,onComment:a}){return e.orientation.trim()?(0,D.jsxs)(`article`,{className:`guide`,"aria-labelledby":`guide-title`,children:[(0,D.jsx)(lO,{content:e.orientation,comments:e.comments,loading:e.loading,onComment:a}),(0,D.jsx)(fO,{topics:e.topics,pendingTopics:t,comments:e.comments,onOperate:i,onComment:a}),(0,D.jsx)(uO,{questions:e.questions,pendingQuestions:n,comments:e.comments,onOperate:i,onComment:a})]}):(0,D.jsxs)(`section`,{className:`guide-empty`,"aria-labelledby":`guide-empty-title`,"aria-busy":e.loading,children:[(0,D.jsx)(`h1`,{id:`guide-empty-title`,className:`guide-section-title`,children:`Understand this change`}),(0,D.jsx)(`p`,{children:`Get oriented before reading the implementation, then explore the parts and questions that matter to you.`}),(0,D.jsx)(X,{variant:`primary`,disabled:e.loading,onClick:r,children:e.loading?`Building guide…`:`Generate guide`})]})}var mO=5;function hO({thread:e,body:t,draftKind:n,disabled:r,onBodyChange:i,onSubmit:a}){let o=(0,v.useRef)(null);if((0,v.useLayoutEffect)(()=>{let e=o.current;if(!e)return;e.style.height=`auto`;let t=getComputedStyle(e),n=Number.parseFloat(t.lineHeight),r=Number.parseFloat(t.paddingTop)+Number.parseFloat(t.paddingBottom)+Number.parseFloat(t.borderTopWidth)+Number.parseFloat(t.borderBottomWidth),i=n*mO+r,a=Math.min(e.scrollHeight,i);e.style.height=`${a}px`,e.style.overflowY=e.scrollHeight>i?`auto`:`hidden`},[t]),e?.resolved)return(0,D.jsx)(`div`,{className:`guide-conversation-excluded-footer`,children:`Excluded from review`});let s=!e&&n===`comment`?`Write a global review comment`:`Ask anything`;return(0,D.jsx)(`div`,{className:`guide-conversation-composer`,children:(0,D.jsx)(`textarea`,{ref:o,className:`guide-conversation-input`,value:t,rows:1,disabled:r,placeholder:`${s}…`,"aria-label":s,onChange:e=>i(e.target.value),onKeyDown:e=>{e.key!==`Enter`||e.shiftKey||e.nativeEvent.isComposing||(e.preventDefault(),t.trim()&&a())}})})}function gO({thread:e}){return(0,D.jsxs)(`div`,{className:`guide-conversation-message-list`,children:[e.messages.map((e,t)=>(0,D.jsx)(`article`,{className:`guide-conversation-message ${e.role}`,children:e.role===`user`?(0,D.jsx)(`div`,{className:`guide-conversation-user-text`,children:e.text}):(0,D.jsx)(ND,{content:e.text,className:`guide-conversation-message-content`})},`${e.role}:${t}:${e.text}`)),e.loading&&(0,D.jsx)(`div`,{className:`guide-conversation-message assistant loading`,children:(0,D.jsx)(`span`,{className:`guide-conversation-thinking`,children:`Thinking…`})})]})}function _O({thread:e,body:t,draftKind:n,submitting:r,onBodyChange:i,onSubmit:a}){let o=(0,v.useRef)(null),s=e?.messages.length??0;return(0,v.useLayoutEffect)(()=>{let e=o.current;e&&(e.scrollTop=e.scrollHeight)},[s,e?.id,e?.loading]),(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(`div`,{ref:o,className:`guide-conversation-messages`,"aria-live":`polite`,children:e?(0,D.jsx)(gO,{thread:e}):(0,D.jsx)(`div`,{className:`guide-conversation-empty`,children:n===`comment`?(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(`h2`,{children:`Add a global review comment`}),(0,D.jsx)(`p`,{children:`Leave feedback that does not belong to a specific diff line or guide block.`})]}):(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(`h2`,{children:`What would you like to know?`}),(0,D.jsx)(`p`,{children:`Ask about the intent, tradeoffs, or any part of the change you want to understand better.`})]})})}),(0,D.jsx)(hO,{thread:e,body:t,draftKind:n,disabled:r||!!e?.loading,onBodyChange:i,onSubmit:a})]})}function vO({conversations:e}){let{items:t,selected:n,view:r}=e;return(0,D.jsxs)(`aside`,{className:`guide-conversation-panel`,"aria-label":`Guide conversations`,children:[(0,D.jsxs)(`header`,{className:`guide-conversation-header`,children:[(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,active:r===`history`,"aria-label":`Conversation history`,"aria-pressed":r===`history`,title:`Conversation history`,onClick:e.showHistory,children:(0,D.jsx)(vv,{size:16})}),(0,D.jsxs)(`div`,{className:`guide-conversation-header-actions`,children:[n&&(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,"aria-label":n.resolved?`Include conversation in review`:`Exclude conversation from review`,title:n.resolved?`Include in review`:`Exclude from review`,onClick:()=>n.resolved?e.include(n.id):e.exclude(n.id),children:n.resolved?(0,D.jsx)(mv,{size:16}):(0,D.jsx)(pv,{size:16})}),(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,active:r===`new`&&e.draftKind===`comment`,"aria-label":`Add global comment`,"aria-pressed":r===`new`&&e.draftKind===`comment`,title:`Add global comment`,onClick:e.openComment,children:(0,D.jsx)(hv,{size:16})}),(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,active:r===`new`&&e.draftKind===`conversation`,"aria-label":`New agent conversation`,"aria-pressed":r===`new`&&e.draftKind===`conversation`,title:`New agent conversation`,onClick:e.openConversation,children:(0,D.jsx)(_v,{size:16})})]})]}),r===`history`?(0,D.jsx)(`div`,{className:`guide-conversation-history`,children:t.length===0?(0,D.jsx)(`p`,{className:`guide-conversation-history-empty`,children:`No conversations yet`}):t.map(t=>{let n=yO(t);return(0,D.jsxs)(X,{variant:`unstyled`,className:`guide-conversation-item${t.resolved?` excluded`:``}`,onClick:()=>e.open(t.id),title:n,children:[(0,D.jsx)(gv,{size:14,"aria-hidden":`true`}),(0,D.jsx)(`span`,{children:n}),t.resolved?(0,D.jsx)(`span`,{className:`guide-conversation-excluded`,children:`Excluded`}):(0,D.jsx)(`span`,{className:`guide-conversation-status${t.loading?` active`:``}`,"aria-label":t.loading?`Agent responding`:void 0,"aria-hidden":!t.loading||void 0})]},t.id)})}):(0,D.jsx)(_O,{thread:n,body:e.body,draftKind:e.draftKind,submitting:e.submitting,onBodyChange:e.setBody,onSubmit:e.submit},n?.id??`new`)]})}function yO(e){let t=e.messages.find(e=>e.role===`user`)?.text.replace(/\s+/g,` `).trim()??``;return t?t.length<=96?t:`${t.slice(0,93).trimEnd()}…`:`New conversation`}async function bO(e,t={}){let n=await fetch(new URL(e,document.baseURI),{headers:{"content-type":`application/json`,...t.headers},...t}),r=await xO(n);if(!n.ok)throw Error(r.error||n.statusText||`request to ${e} failed`);return r}async function xO(e){let t=await e.text();if(!t)return{};try{return JSON.parse(t)}catch{throw Error(`server returned an invalid JSON response`)}}async function SO(){return bO(`api/bootstrap`)}async function CO(e){return bO(`api/diff${e?`?path=${encodeURIComponent(e)}`:``}`)}async function wO(e){return bO(`api/state`,{method:`POST`,body:JSON.stringify(e)})}async function TO(e){return bO(`api/thread`,{method:`POST`,body:JSON.stringify(e)})}async function EO(e){return bO(`api/thread/reply`,{method:`POST`,body:JSON.stringify(e)})}async function DO(e){return bO(`api/thread-message`,{method:`POST`,body:JSON.stringify({id:e})})}async function OO(e){return bO(`api/thread-message/delete`,{method:`POST`,body:JSON.stringify(e)})}async function kO(e){return bO(`api/thread/resolve`,{method:`POST`,body:JSON.stringify(e)})}async function AO(e){return bO(`api/thread/collapse`,{method:`POST`,body:JSON.stringify(e)})}async function jO(){return bO(`api/guide/generate`,{method:`POST`})}async function MO(e){return bO(`api/guide/operate`,{method:`POST`,body:JSON.stringify(e)})}async function NO(e){return bO(`api/guide/comment`,{method:`POST`,body:JSON.stringify(e)})}async function PO(){return bO(`api/review`,{method:`POST`})}async function FO(){return bO(`api/cancel`,{method:`POST`})}function IO({bootstrap:e,reviewState:t,setGuideLoading:n,syncReviewState:r}){let i=(0,v.useRef)(!1),a=(0,v.useRef)(0),[o,s]=(0,v.useState)([]),[c,l]=(0,v.useState)([]),u=(0,v.useCallback)(()=>{n(!0),r(jO(),{onError:()=>{i.current=!1,n(!1)}})},[n,r]),d=(0,v.useCallback)(e=>{let t=`guide-operation-${a.current++}`;e.kind===`topic.add`?s(e=>[...e,{id:t,kind:`add`}]):e.kind===`topic.revise`?s(n=>[...n,{id:t,kind:`revise`,topicId:e.topicId}]):e.kind===`question.ask`&&l(n=>[...n,{id:t,question:e.question}]),n(!0),r(MO(e),{onError:()=>{n(!1)}}).finally(()=>{e.kind===`topic.add`||e.kind===`topic.revise`?s(e=>e.filter(e=>e.id!==t)):e.kind===`question.ask`&&l(e=>e.filter(e=>e.id!==t))})},[n,r]),f=(0,v.useCallback)((e,t)=>{r(NO({target:e,body:t}))},[r]);return(0,v.useEffect)(()=>{!e||t.guide.orientation||i.current||(i.current=!0,u())},[e,u,t.guide.orientation]),{pendingTopics:o,pendingQuestions:c,requestGuide:u,runGuideOperation:d,saveComment:f}}var LO=[{value:`guide`,label:`Guide`},{value:`diff`,label:`Diff`}],RO=[{value:`split`,label:`Split`},{value:`stacked`,label:`Stacked`}],zO=14;function BO({mode:e,fileCount:t,viewedCount:n,additions:r,deletions:i,commentCount:a,diffStyle:o,overflowMode:s,finished:c,hasReviewComments:l,hasUnresolvedFileThreads:u,onModeChange:d,onExpandAll:f,onExpandUnresolved:p,onCollapseViewed:m,onCollapseAll:h,onDiffStyleChange:g,onOverflowModeChange:_,onSubmit:v,onCancel:y}){let b=o===`split`?`split`:`stacked`,x=s===`scroll`?`scroll`:`wrap`,S=t>0?Math.round(n/t*100):0;return(0,D.jsxs)(`header`,{className:`top-bar`,children:[(0,D.jsx)(`div`,{className:`top-bar-left`,children:(0,D.jsx)(oO,{value:e,options:LO,label:`Review mode`,onChange:d})}),(0,D.jsxs)(`div`,{className:`top-bar-right`,children:[e===`diff`&&(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(`span`,{"aria-label":`${r} additions and ${i} deletions`,children:(0,D.jsx)(Ov,{additions:r,deletions:i})}),(0,D.jsxs)(`div`,{className:`top-bar-viewed`,"aria-label":`${n} of ${t} viewed, ${a} unresolved comments`,children:[(0,D.jsx)(`span`,{className:`top-bar-viewed-ring`,style:{background:`conic-gradient(var(--accent-interactive) ${S}%, var(--border) ${S}% 100%)`},"aria-hidden":`true`,children:(0,D.jsx)(`span`,{className:`top-bar-viewed-ring-inner`})}),(0,D.jsxs)(`span`,{className:`top-bar-viewed-text`,children:[n,` of `,t,` viewed`]})]}),(0,D.jsxs)(`div`,{className:`button-group`,children:[(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,"aria-label":`Expand all files`,onClick:f,children:(0,D.jsx)(fv,{size:zO})}),(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,"aria-label":`Expand files with unresolved threads`,onClick:p,disabled:!u,children:(0,D.jsx)(gv,{size:zO})}),(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,"aria-label":`Collapse viewed files`,onClick:m,children:(0,D.jsx)(pv,{size:zO})}),(0,D.jsx)(X,{variant:`ghost`,iconOnly:!0,"aria-label":`Collapse all files`,onClick:h,children:(0,D.jsx)(dv,{size:zO})})]}),(0,D.jsx)(DD,{checked:x===`wrap`,label:`Wrap`,onChange:e=>_(e?`wrap`:`scroll`)}),(0,D.jsx)(oO,{value:b,options:RO,label:`Diff style`,onChange:g})]}),(0,D.jsxs)(`div`,{className:`top-bar-actions`,children:[(0,D.jsx)(X,{variant:`primary`,onClick:v,disabled:c,children:l?`Submit`:`Approve`}),(0,D.jsx)(X,{variant:`danger`,iconOnly:!0,onClick:y,disabled:c,"aria-label":`cancel`,children:(0,D.jsx)(xv,{size:zO,strokeWidth:2.25})})]})]})]})}function VO(){let[e,t]=(0,v.useState)(`guide`),n=(0,v.useRef)(null),r=(0,v.useRef)({guide:0,diff:0});return{mode:e,contentRef:n,changeMode:(0,v.useCallback)(i=>{if(i===e)return;let a=n.current;a&&(r.current[e]=a.scrollTop),t(i),requestAnimationFrame(()=>{n.current?.scrollTo({top:r.current[i],behavior:`auto`})})},[e]),scrollToFile:(0,v.useCallback)((e,t=`smooth`)=>{let r=n.current,i=document.getElementById(`file-${e}`);if(!r||!i)return;let a=r.getBoundingClientRect(),o=i.getBoundingClientRect(),s=Number.parseFloat(getComputedStyle(r).paddingTop);r.scrollTo({top:r.scrollTop+o.top-a.top-s,behavior:t})},[])}}function HO(e,t,n){if(!e.trim())return[];let r=Gp(e,n),i=GO(t),a=0;return r.flatMap(e=>e.files.map(e=>{let t=KO(e,i);return{id:e.cacheKey??`${e.name}::${a++}`,file:e,displayPath:t.displayPath,status:t.status,oldRepoPath:t.oldRepoPath,newRepoPath:t.newRepoPath,additions:WO(e,`additions`),deletions:WO(e,`deletions`)}}))}function UO(e){return e.prevName&&e.prevName!==e.name?`renamed`:`modified`}function WO(e,t){return e.hunks.reduce((e,n)=>e+n.hunkContent.reduce((e,n)=>e+(n.type===`change`?n[t]:0),0),0)}function GO(e){let t=new Map;for(let n of e??[]){let e={displayPath:n.oldPath&&n.newPath&&n.oldPath!==n.newPath?`${n.oldPath} → ${n.newPath}`:n.path,status:n.status,oldRepoPath:n.oldPath,newRepoPath:n.newPath??n.path};t.set(n.path,e),n.newPath&&t.set(n.newPath,e),n.oldPath&&t.set(n.oldPath,e)}return t}function KO(e,t){return t.get(e.name)||(e.prevName?t.get(e.prevName):void 0)||{displayPath:e.prevName&&e.prevName!==e.name?`${e.prevName} → ${e.name}`:e.name,status:UO(e),oldRepoPath:e.prevName,newRepoPath:e.name}}var qO={diffStyle:`stacked`,overflowMode:`wrap`,codeTheme:Sv,collapsedFileIds:[],viewedFileIds:[],threads:[],guide:{orientation:``,topics:[],questions:[],comments:[],loading:!1}};function JO(e,t,n){return{...e,threads:e.threads.map(e=>e.id===t?{...e,loading:n}:e)}}function YO(e,t){return{...e,guide:{...e.guide,loading:t}}}function XO(){let[e,t]=(0,v.useState)(null),[n,r]=(0,v.useState)(null),[i,a]=(0,v.useState)(qO),o=(0,v.useCallback)(e=>{a(e)},[]),s=(0,v.useCallback)(async(e,t={})=>{try{let t=await e;o(t.state)}catch{t.onError?.()}},[o]),c=(0,v.useCallback)((e,t)=>{s(wO(e),t)},[s]),l=(0,v.useCallback)((e,t)=>{a(n=>JO(n,e,t))},[]),u=(0,v.useCallback)(e=>{a(t=>YO(t,e))},[]);(0,v.useEffect)(()=>{let e=!0;return(async()=>{try{let n=await SO();if(!n.state)throw Error(`diff tool bootstrap response did not include review state`);if(!e)return;t(n),o(n.state);let i=await CO();e&&r(i)}catch{}})(),()=>{e=!1}},[o]);let d=n&&`patch`in n?n.patch:``;return{bootstrap:e,reviewState:i,files:(0,v.useMemo)(()=>HO(d,e?.files,e?.context.sessionId),[e,d]),emptyContent:n?`no changes to review`:`loading…`,applyReviewState:o,syncReviewState:s,applyStatePatch:c,setThreadLoading:l,setGuideLoading:u}}function ZO(){let[e,t]=(0,v.useState)(!1);return{finished:e,submit:(0,v.useCallback)(async()=>{t(!0);try{await PO()}catch{t(!1)}},[]),cancel:(0,v.useCallback)(async()=>{t(!0);try{await FO()}catch{t(!1)}},[])}}function QO({reviewState:e,requestThreadAgentReply:t,applyReviewState:n}){let[r,i]=(0,v.useState)(``),[a,o]=(0,v.useState)(!1),[s,c]=(0,v.useState)({mode:`new`,kind:`conversation`}),l=(0,v.useRef)(0),u=(0,v.useRef)(!1),d=(0,v.useMemo)(()=>e.threads.filter(x).reverse(),[e.threads]),f=(0,v.useMemo)(()=>s.mode===`thread`?d.find(e=>e.id===s.threadId)??null:null,[d,s]),p=(0,v.useCallback)(e=>{l.current+=1,i(``),c({mode:`new`,kind:e})},[]),m=(0,v.useCallback)(e=>{l.current+=1,i(``),c({mode:`thread`,threadId:e})},[]),h=(0,v.useCallback)(()=>{l.current+=1,i(``),c({mode:`history`})},[]);(0,v.useEffect)(()=>{s.mode===`thread`&&!f&&h()},[f,h,s]);let g=(0,v.useCallback)(e=>l.current===e&&(i(``),!0),[]),_=(0,v.useCallback)(async()=>{let e=r.trim();if(!e||u.current||s.mode===`history`||s.mode===`thread`&&(!f||f.loading||f.resolved))return;let i=l.current,a=s.mode===`thread`||s.kind===`conversation`,d;u.current=!0,o(!0);try{if(s.mode===`thread`)d=s.threadId,n((await EO({id:d,text:e})).state),g(i);else{let t=await TO({body:e,anchor:{kind:`detached`}});d=t.threadId,n(t.state),g(i)&&c({mode:`thread`,threadId:d})}}catch{return}finally{u.current=!1,o(!1)}a&&await t(d)},[n,r,t,g,f,s]);return{body:r,setBody:i,submitting:a,threads:d,selectedThread:f,view:s.mode,draftKind:s.mode===`new`?s.kind:`conversation`,openDraft:p,openThread:m,showHistory:h,submit:_}}function $O({files:e,reviewState:t,requestThreadAgentReply:n,applyReviewState:r}){let[i,a]=(0,v.useState)(null),o=(0,v.useMemo)(()=>S(t.threads),[t.threads]);return{draft:i,draftAnnotation:(0,v.useMemo)(()=>i?{lineNumber:i.lineNumber,side:i.side,metadata:{type:`draft`,draft:i}}:null,[i]),threadsByFileId:o,activateLine:(0,v.useCallback)((e,t,n)=>{a(r=>r?.fileId===e&&r.lineNumber===t&&r.side===n?r:{fileId:e,lineNumber:t,side:n})},[]),saveDraft:(0,v.useCallback)((t,o)=>{if(!i)return;let s=t.trim();if(!s){a(null);return}let c={kind:`line`,fileId:i.fileId,filePath:T(i,e),lineNumber:i.lineNumber,side:i.side};(async()=>{try{let e=await TO({body:s,anchor:c});r(e.state),a(null),o&&await n(e.threadId)}catch{}})()},[r,i,e,n]),cancelDraft:(0,v.useCallback)(()=>a(null),[])}}function ek({applyReviewState:e,syncReviewState:t,setThreadLoading:n}){let r=(0,v.useCallback)(async t=>{n(t,!0);try{e((await DO(t)).state)}catch{n(t,!1)}},[e,n]);return{requestThreadAgentReply:r,addReply:(0,v.useCallback)((n,i,a)=>{if(!a){t(EO({id:n,text:i}));return}(async()=>{try{e((await EO({id:n,text:i})).state),await r(n)}catch{}})()},[e,r,t]),requestAgent:(0,v.useCallback)(e=>{r(e)},[r]),toggleResolved:(0,v.useCallback)((e,n)=>{t(kO({id:e,resolved:n}))},[t]),toggleThreadCollapsed:(0,v.useCallback)((e,n)=>{t(AO({id:e,collapsed:n}))},[t]),removeThreadMessage:(0,v.useCallback)((e,n)=>{t(OO({id:e,messageIndex:n}))},[t])}}function tk({files:e,reviewState:t,applyReviewState:n,syncReviewState:r,setThreadLoading:i}){let a=ek({applyReviewState:n,syncReviewState:r,setThreadLoading:i}),o=$O({files:e,reviewState:t,requestThreadAgentReply:a.requestThreadAgentReply,applyReviewState:n}),s=QO({reviewState:t,requestThreadAgentReply:a.requestThreadAgentReply,applyReviewState:n});return{...o,addReply:a.addReply,requestAgent:a.requestAgent,toggleResolved:a.toggleResolved,toggleThreadCollapsed:a.toggleThreadCollapsed,removeThreadMessage:a.removeThreadMessage,guideConversations:{items:s.threads,selected:s.selectedThread,view:s.view,draftKind:s.draftKind,body:s.body,submitting:s.submitting,setBody:s.setBody,openComment:()=>s.openDraft(`comment`),openConversation:()=>s.openDraft(`conversation`),open:s.openThread,showHistory:s.showHistory,submit:s.submit,exclude:e=>a.toggleResolved(e,!0),include:e=>a.toggleResolved(e,!1)}}}function nk(){let e=XO(),t=VO(),n=nO({files:e.files,reviewState:e.reviewState,applyStatePatch:e.applyStatePatch,scrollToFile:t.scrollToFile}),r=tk({files:e.files,reviewState:e.reviewState,applyReviewState:e.applyReviewState,syncReviewState:e.syncReviewState,setThreadLoading:e.setThreadLoading}),i=IO({bootstrap:e.bootstrap,reviewState:e.reviewState,setGuideLoading:e.setGuideLoading,syncReviewState:e.syncReviewState}),a=ZO(),o=rO(e.files,e.reviewState.codeTheme);return(0,D.jsxs)(D.Fragment,{children:[(0,D.jsxs)(`div`,{className:`app ${t.mode}-mode`,children:[(0,D.jsx)(BO,{mode:t.mode,fileCount:e.files.length,viewedCount:e.reviewState.viewedFileIds.length,additions:n.totals.additions,deletions:n.totals.deletions,commentCount:n.unresolvedThreadCount,diffStyle:e.reviewState.diffStyle,overflowMode:e.reviewState.overflowMode,finished:a.finished,hasReviewComments:wv(e.reviewState),hasUnresolvedFileThreads:n.filesWithUnresolvedThreads.length>0,onModeChange:t.changeMode,onExpandAll:n.expandAll,onExpandUnresolved:n.expandUnresolved,onCollapseViewed:n.collapseViewed,onCollapseAll:n.collapseAll,onDiffStyleChange:t=>{e.applyStatePatch({diffStyle:t})},onOverflowModeChange:t=>{e.applyStatePatch({overflowMode:t})},onSubmit:a.submit,onCancel:a.cancel}),t.mode===`guide`?(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(`main`,{ref:t.contentRef,className:`content guide-content`,children:(0,D.jsx)(pO,{guide:e.reviewState.guide,pendingTopics:i.pendingTopics,pendingQuestions:i.pendingQuestions,onGenerate:i.requestGuide,onOperate:i.runGuideOperation,onComment:i.saveComment})}),(0,D.jsx)(vO,{conversations:r.guideConversations})]}):(0,D.jsx)(ZD,{contentRef:t.contentRef,files:e.files,emptyContent:e.emptyContent,reviewState:e.reviewState,renderReady:o,fileState:n,threads:r,onJumpToFile:t.scrollToFile})]}),null]})}(0,y.createRoot)(document.getElementById(`root`)).render((0,D.jsx)(v.StrictMode,{children:(0,D.jsx)(nk,{})}));export{s as t};
|