codemini-cli 0.6.1 → 0.6.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (636) hide show
  1. package/codemini-web/dist/assets/AboutDialog-CBmrZqhV.js +3 -0
  2. package/codemini-web/dist/assets/CodeWikiPanel-BjI4vz9H.js +1 -0
  3. package/codemini-web/dist/assets/ConfigDialog-hxEIuIXJ.js +1 -0
  4. package/codemini-web/dist/assets/GitDiffDialog-CVpmPcGi.js +222 -0
  5. package/codemini-web/dist/assets/MessageBubble-BkkfePXe.js +6 -0
  6. package/codemini-web/dist/assets/ProjectSelector-CjE9gbEY.js +1 -0
  7. package/codemini-web/dist/assets/SkillDialog-CpX5c2q5.js +6 -0
  8. package/codemini-web/dist/assets/SoulDialog-5ZMpAJl3.js +1 -0
  9. package/codemini-web/dist/assets/{angular-html-CHsdtmkx.js → angular-html-DQ1gtQ6R.js} +1 -1
  10. package/codemini-web/dist/assets/{angular-html-DlSp9HPG.js → angular-html-kg4tCYym.js} +1 -1
  11. package/codemini-web/dist/assets/{angular-ts-B29Ypg6B.js → angular-ts-C_VTyikG.js} +1 -1
  12. package/codemini-web/dist/assets/{angular-ts-JNDGGWj0.js → angular-ts-QUaQh54x.js} +1 -1
  13. package/codemini-web/dist/assets/{apl-BASZ7uB_.js → apl-D2YQXnhn.js} +1 -1
  14. package/codemini-web/dist/assets/{apl-Byuv-g-O.js → apl-DTyfz60o.js} +1 -1
  15. package/codemini-web/dist/assets/{astro-CTzEugGW.js → astro-DrBiKBx0.js} +1 -1
  16. package/codemini-web/dist/assets/{astro-l-XABzN2.js → astro-STdMQy7_.js} +1 -1
  17. package/codemini-web/dist/assets/{blade-B3_bxlV2.js → blade-BzcRYrK8.js} +1 -1
  18. package/codemini-web/dist/assets/{blade-Dt6km9YT.js → blade-DV-5zppA.js} +1 -1
  19. package/codemini-web/dist/assets/{bsl-CPV9KqsG.js → bsl-D8KU0pjR.js} +1 -1
  20. package/codemini-web/dist/assets/{bsl-D3u1l2dW.js → bsl-JaCMWPaY.js} +1 -1
  21. package/codemini-web/dist/assets/bundle-mjs-C44PrJ2C.js +1 -0
  22. package/codemini-web/dist/assets/{cairo-CoQzhJ_o.js → cairo-D7Xpkdmw.js} +1 -1
  23. package/codemini-web/dist/assets/{cairo-CyiRuu7R.js → cairo-DcJUH2W4.js} +1 -1
  24. package/codemini-web/dist/assets/chunk-BO2N2NFS-C-dwTHqR.js +131 -0
  25. package/codemini-web/dist/assets/{cobol-DqhY5el-.js → cobol-DcObg-T7.js} +1 -1
  26. package/codemini-web/dist/assets/{cobol-D_kesMA-.js → cobol-VahErUC5.js} +1 -1
  27. package/codemini-web/dist/assets/{coffee-DF15_0rk.js → coffee-B5QkIGo_.js} +1 -1
  28. package/codemini-web/dist/assets/{coffee-rY-gkJy7.js → coffee-eHrF22jH.js} +1 -1
  29. package/codemini-web/dist/assets/{cpp-Bw-qV0P6.js → cpp-hpmt0Dm0.js} +1 -1
  30. package/codemini-web/dist/assets/{cpp-Cudwe5mG.js → cpp-oPWeBIxQ.js} +1 -1
  31. package/codemini-web/dist/assets/{crystal-Bw1_1hFA.js → crystal-CoivzC9J.js} +1 -1
  32. package/codemini-web/dist/assets/{crystal-DV9Nijjb.js → crystal-s_8obDZh.js} +1 -1
  33. package/codemini-web/dist/assets/{edge-BosfXYh1.js → edge--dOGTygN.js} +1 -1
  34. package/codemini-web/dist/assets/{edge-r5NIe9Lp.js → edge-C-DECmFd.js} +1 -1
  35. package/codemini-web/dist/assets/{elixir-B04apOJS.js → elixir-9z9mJoua.js} +1 -1
  36. package/codemini-web/dist/assets/{elixir-Dw_vsdUl.js → elixir-D3BiPlt5.js} +1 -1
  37. package/codemini-web/dist/assets/{elm-Cezz_HNz.js → elm-BuOfOpho.js} +1 -1
  38. package/codemini-web/dist/assets/{elm-DPfFNNkG.js → elm-DjcEOkt6.js} +1 -1
  39. package/codemini-web/dist/assets/{erb-BNioEFKQ.js → erb-B6UlpZlF.js} +1 -1
  40. package/codemini-web/dist/assets/{erb-DZuoCU5t.js → erb-omHMX7PR.js} +1 -1
  41. package/codemini-web/dist/assets/{erlang-BC8wryba.js → erlang-DJdyEhn7.js} +1 -1
  42. package/codemini-web/dist/assets/{erlang-CqHCISqs.js → erlang-l2na0rr-.js} +1 -1
  43. package/codemini-web/dist/assets/{fortran-fixed-form-60ZQAHDk.js → fortran-fixed-form-72xY_C5B.js} +1 -1
  44. package/codemini-web/dist/assets/{fortran-fixed-form-CyrImzNA.js → fortran-fixed-form-Dyncprn4.js} +1 -1
  45. package/codemini-web/dist/assets/{fsharp-Ch5ZVinn.js → fsharp-CAeGcLFg.js} +1 -1
  46. package/codemini-web/dist/assets/{fsharp-OCW_PZ4J.js → fsharp-D6WYKxtq.js} +1 -1
  47. package/codemini-web/dist/assets/{gdresource-Cl3bohRI.js → gdresource-Bac2fAQZ.js} +1 -1
  48. package/codemini-web/dist/assets/{gdresource-CqNLhJW1.js → gdresource-D9tlxSca.js} +1 -1
  49. package/codemini-web/dist/assets/{git-commit-CSWECvqq.js → git-commit-BQ43t81h.js} +1 -1
  50. package/codemini-web/dist/assets/{git-commit-DJZpdBwB.js → git-commit-CDZnUqIF.js} +1 -1
  51. package/codemini-web/dist/assets/{git-rebase-BJE30GTP.js → git-rebase-CrM8c9uR.js} +1 -1
  52. package/codemini-web/dist/assets/{git-rebase-MUvuytPe.js → git-rebase-nf_-tAIT.js} +1 -1
  53. package/codemini-web/dist/assets/{glimmer-js-Dn6vjgHP.js → glimmer-js-BG6a3MVV.js} +1 -1
  54. package/codemini-web/dist/assets/{glimmer-js-HDDEErW7.js → glimmer-js-CmAPRjq-.js} +1 -1
  55. package/codemini-web/dist/assets/{glimmer-ts-Dq0_BflX.js → glimmer-ts-CQha3IIl.js} +1 -1
  56. package/codemini-web/dist/assets/{glimmer-ts-mq-Q_zEE.js → glimmer-ts-WUsACCRt.js} +1 -1
  57. package/codemini-web/dist/assets/{glsl-C4rvog10.js → glsl-CAJiER_N.js} +1 -1
  58. package/codemini-web/dist/assets/{glsl-C8VPaAWs.js → glsl-CUfWCqOt.js} +1 -1
  59. package/codemini-web/dist/assets/{graphql-Dg0Ewf8Q.js → graphql-B-xWjhGC.js} +1 -1
  60. package/codemini-web/dist/assets/{graphql-WZCiqIl-.js → graphql-CufH1FQw.js} +1 -1
  61. package/codemini-web/dist/assets/{hack-DeD259o6.js → hack-6ZyX-jpl.js} +1 -1
  62. package/codemini-web/dist/assets/{hack-DjE76gIx.js → hack-D9TV3mFw.js} +1 -1
  63. package/codemini-web/dist/assets/{haml-B8MRe8CS.js → haml-CXPCOKlR.js} +1 -1
  64. package/codemini-web/dist/assets/{haml-DyIc_iO2.js → haml-zf3skXy8.js} +1 -1
  65. package/codemini-web/dist/assets/{handlebars-DQ4X08Zf.js → handlebars-BFZlhIIV.js} +1 -1
  66. package/codemini-web/dist/assets/{handlebars-GoJyzhp1.js → handlebars-BzLrTccQ.js} +1 -1
  67. package/codemini-web/dist/assets/highlighted-body-OFNGDK62-BlOR-p_j.js +1 -0
  68. package/codemini-web/dist/assets/{html-GfHBuoLs.js → html-CZRPtk7M.js} +1 -1
  69. package/codemini-web/dist/assets/{html-B7kk5NVw.js → html-DLN1MsZQ.js} +1 -1
  70. package/codemini-web/dist/assets/{html-derivative-Ba28nVB3.js → html-derivative-DGaxN6Jm.js} +1 -1
  71. package/codemini-web/dist/assets/{html-derivative-ChSmSZXY.js → html-derivative-Dryc40mO.js} +1 -1
  72. package/codemini-web/dist/assets/{http-DMTBhQm8.js → http-B3D7H2pi.js} +1 -1
  73. package/codemini-web/dist/assets/{http-Deln4Vyb.js → http-CD8xd_ys.js} +1 -1
  74. package/codemini-web/dist/assets/{hurl-CYSuhGkj.js → hurl-4R1-_fJo.js} +1 -1
  75. package/codemini-web/dist/assets/{hurl-XIpACwjS.js → hurl-DhA9rL1f.js} +1 -1
  76. package/codemini-web/dist/assets/{hxml-BmF7ngDz.js → hxml-BNblpm3P.js} +1 -1
  77. package/codemini-web/dist/assets/{hxml-PnV_FpS-.js → hxml-y50fEZfK.js} +1 -1
  78. package/codemini-web/dist/assets/index-BkhgO3hd.js +65 -0
  79. package/codemini-web/dist/assets/index-COyr1sc3.css +2 -0
  80. package/codemini-web/dist/assets/input-CNJXW0J8.js +1 -0
  81. package/codemini-web/dist/assets/{jinja-8ATGhxJO.js → jinja-BGFo9cp_.js} +1 -1
  82. package/codemini-web/dist/assets/{jinja-Dx5IcFSt.js → jinja-CMJRtHk5.js} +1 -1
  83. package/codemini-web/dist/assets/{jison-CSsYnr7O.js → jison-CjADtx7J.js} +1 -1
  84. package/codemini-web/dist/assets/{jison-DuNOGix6.js → jison-DZG53562.js} +1 -1
  85. package/codemini-web/dist/assets/{julia-Cqc1ADyw.js → julia-CrDH-yy9.js} +1 -1
  86. package/codemini-web/dist/assets/{julia-vjG00jwO.js → julia-DGoXLnGd.js} +1 -1
  87. package/codemini-web/dist/assets/{just-C7G3KFgN.js → just-BV8ObQSd.js} +1 -1
  88. package/codemini-web/dist/assets/{just-BlUYrdKb.js → just-bFDeah4I.js} +1 -1
  89. package/codemini-web/dist/assets/{latex-BEPTKliI.js → latex-DDcspDwa.js} +1 -1
  90. package/codemini-web/dist/assets/{latex-D8-NgtPj.js → latex-DHgb1D3g.js} +1 -1
  91. package/codemini-web/dist/assets/lib-DQpX2ek0.js +11 -0
  92. package/codemini-web/dist/assets/lib-Dj6FJSN8.js +1 -0
  93. package/codemini-web/dist/assets/{liquid-BUh7yINm.js → liquid-CodJB6Oo.js} +1 -1
  94. package/codemini-web/dist/assets/{liquid-D2m0XXrV.js → liquid-DY_Nh1yB.js} +1 -1
  95. package/codemini-web/dist/assets/{lua-BeSXusec.js → lua-CSNL2IG5.js} +1 -1
  96. package/codemini-web/dist/assets/{lua-BroxvhVt.js → lua-Mbb_FM_D.js} +1 -1
  97. package/codemini-web/dist/assets/{marko-DPnRthJQ.js → marko-BtH_ko92.js} +1 -1
  98. package/codemini-web/dist/assets/{marko-Dm8xPXkG.js → marko-CoJz_b4R.js} +1 -1
  99. package/codemini-web/dist/assets/{mdc-BLdFHYKv.js → mdc-U2Od-Be6.js} +1 -1
  100. package/codemini-web/dist/assets/{mdc-Dzipcsdb.js → mdc-pc5Bd-NW.js} +1 -1
  101. package/codemini-web/dist/assets/mermaid-GHXKKRXX-DV0jg4UB.js +1 -0
  102. package/codemini-web/dist/assets/{nextflow-BRiWOV-p.js → nextflow-C240AutA.js} +1 -1
  103. package/codemini-web/dist/assets/{nextflow-c8YCPRRb.js → nextflow-dLJhzX3Z.js} +1 -1
  104. package/codemini-web/dist/assets/{nginx-Da_Uewgc.js → nginx-9UIFC5W_.js} +1 -1
  105. package/codemini-web/dist/assets/{nginx-u-hq5m-a.js → nginx-CeVyuhn6.js} +1 -1
  106. package/codemini-web/dist/assets/{nim-CvgRYLO2.js → nim-A60PrBkG.js} +1 -1
  107. package/codemini-web/dist/assets/{nim-B5b6_jZr.js → nim-DhQ1Hs8s.js} +1 -1
  108. package/codemini-web/dist/assets/pencil-CARzRgk1.js +1 -0
  109. package/codemini-web/dist/assets/{perl-BIcNvyL6.js → perl-BPmyA-C2.js} +1 -1
  110. package/codemini-web/dist/assets/{perl-DdF12AsD.js → perl-CA0CUhlR.js} +1 -1
  111. package/codemini-web/dist/assets/{php-BP-3TkW_.js → php-DFR1z6f_.js} +1 -1
  112. package/codemini-web/dist/assets/{php-CyQZnE0l.js → php-aSpTH15w.js} +1 -1
  113. package/codemini-web/dist/assets/{pug-HwoxZo9M.js → pug-2MsinVHa.js} +1 -1
  114. package/codemini-web/dist/assets/{pug-_XoIcKf3.js → pug-DXmP4Dd5.js} +1 -1
  115. package/codemini-web/dist/assets/{qml-CysuucQ6.js → qml-Cp-MkXo2.js} +1 -1
  116. package/codemini-web/dist/assets/{qml-DWxWu28U.js → qml-Dmd77dfv.js} +1 -1
  117. package/codemini-web/dist/assets/{razor-ZpEr_C9H.js → razor-BH58TmZI.js} +1 -1
  118. package/codemini-web/dist/assets/{razor-DQ6FV4WL.js → razor-knNn5G4N.js} +1 -1
  119. package/codemini-web/dist/assets/{rst-CjO4XFKz.js → rst-BkVCrdGo.js} +1 -1
  120. package/codemini-web/dist/assets/{rst-DDrWKQ9c.js → rst-l2oLaq8i.js} +1 -1
  121. package/codemini-web/dist/assets/{ruby-CZgIYPlP.js → ruby-B4GtprLK.js} +1 -1
  122. package/codemini-web/dist/assets/{ruby-BOVYgV5O.js → ruby-gJeF3z-Y.js} +1 -1
  123. package/codemini-web/dist/assets/{sas-DPGT0TjQ.js → sas-CTgoo8hu.js} +1 -1
  124. package/codemini-web/dist/assets/{sas-DYNukvU9.js → sas-Dav6qQnM.js} +1 -1
  125. package/codemini-web/dist/assets/{scss-CaciJ0Gl.js → scss-B8ysOo22.js} +1 -1
  126. package/codemini-web/dist/assets/{scss-YARKxu2i.js → scss-C8Gq31Qt.js} +1 -1
  127. package/codemini-web/dist/assets/select-BQ3BvnG8.js +1 -0
  128. package/codemini-web/dist/assets/{shaderlab-JWcsxey4.js → shaderlab-BaYU-HWs.js} +1 -1
  129. package/codemini-web/dist/assets/{shaderlab-TbUUdmUb.js → shaderlab-CSb6CBXg.js} +1 -1
  130. package/codemini-web/dist/assets/{shellsession-BeWGuVoR.js → shellsession-Ms8iC_in.js} +1 -1
  131. package/codemini-web/dist/assets/{shellsession-DYmuifdt.js → shellsession-eIO2JTpk.js} +1 -1
  132. package/codemini-web/dist/assets/{soy-7iHZG9Jz.js → soy-CnmcxzZM.js} +1 -1
  133. package/codemini-web/dist/assets/{soy-h0dQKbQs.js → soy-U7sqkat1.js} +1 -1
  134. package/codemini-web/dist/assets/{sparql-BGRSvFxd.js → sparql-DrRAT0nC.js} +1 -1
  135. package/codemini-web/dist/assets/{sparql-DIFvSn1n.js → sparql-J1VOnnwM.js} +1 -1
  136. package/codemini-web/dist/assets/{stata-C5mLa_ER.js → stata-C07HETWZ.js} +1 -1
  137. package/codemini-web/dist/assets/{stata-lXN9BRaz.js → stata-C84Azx6N.js} +1 -1
  138. package/codemini-web/dist/assets/{surrealql-DyoUfV6n.js → surrealql-CHm1_yMm.js} +1 -1
  139. package/codemini-web/dist/assets/{surrealql-l0SGzwOs.js → surrealql-D_Sm2j7-.js} +1 -1
  140. package/codemini-web/dist/assets/{svelte-BM89dRu0.js → svelte-BgklcIcA.js} +1 -1
  141. package/codemini-web/dist/assets/{svelte-CijnRGul.js → svelte-UDeamd-l.js} +1 -1
  142. package/codemini-web/dist/assets/{templ-CNjJl440.js → templ-C1aXNqxr.js} +1 -1
  143. package/codemini-web/dist/assets/{templ-D1GoDFsp.js → templ-Dej5xCfm.js} +1 -1
  144. package/codemini-web/dist/assets/{tex-CxEkh6NI.js → tex-CwV6ECg2.js} +1 -1
  145. package/codemini-web/dist/assets/{tex-ezg8IclB.js → tex-DqduegnD.js} +1 -1
  146. package/codemini-web/dist/assets/trash-2-BvANH-oV.js +1 -0
  147. package/codemini-web/dist/assets/{ts-tags-DV6nguf9.js → ts-tags-JHISWk_W.js} +1 -1
  148. package/codemini-web/dist/assets/{ts-tags-B88Nbzcl.js → ts-tags-jpfdYtbg.js} +1 -1
  149. package/codemini-web/dist/assets/{twig-B3Kws0Fb.js → twig-Co8p9s-G.js} +1 -1
  150. package/codemini-web/dist/assets/{twig-BROkIZLg.js → twig-Cq6hSxza.js} +1 -1
  151. package/codemini-web/dist/assets/{vue-CT36qSUr.js → vue-CL6MdYNh.js} +1 -1
  152. package/codemini-web/dist/assets/{vue-BUQP_8VF.js → vue-CopUaTTK.js} +1 -1
  153. package/codemini-web/dist/assets/{vue-html-Bx2Sgp8M.js → vue-html-BJ2qlvpA.js} +1 -1
  154. package/codemini-web/dist/assets/{vue-html-bJyjqZnI.js → vue-html-BkstOd36.js} +1 -1
  155. package/codemini-web/dist/assets/{vue-vine-BLqV15Pm.js → vue-vine-BpJg_Jgw.js} +1 -1
  156. package/codemini-web/dist/assets/{vue-vine-RK3AHrhp.js → vue-vine-kdYS8aKZ.js} +1 -1
  157. package/codemini-web/dist/assets/{xml-BkdunjRC.js → xml-BVIbPGAO.js} +1 -1
  158. package/codemini-web/dist/assets/{xml-DyJ3D9rW.js → xml-Cd8Ewme9.js} +1 -1
  159. package/codemini-web/dist/assets/{xsl-BOsdDgv_.js → xsl-DsYdc3fS.js} +1 -1
  160. package/codemini-web/dist/assets/{xsl-C66i1pDH.js → xsl-JOQu_a5N.js} +1 -1
  161. package/codemini-web/dist/index.html +3 -2
  162. package/codemini-web/lib/runtime-bridge.js +94 -9
  163. package/codemini-web/server.js +4 -4
  164. package/package.json +1 -1
  165. package/src/core/agent-loop.js +63 -14
  166. package/src/core/chat-runtime.js +88 -39
  167. package/src/core/session-store.js +34 -11
  168. package/src/core/tools.js +48 -16
  169. package/codemini-web/dist/assets/highlighted-body-OFNGDK62-DaefZcrn.js +0 -1
  170. package/codemini-web/dist/assets/index-Bk_gka_s.js +0 -435
  171. package/codemini-web/dist/assets/index-BzSHdGYY.css +0 -2
  172. package/codemini-web/dist/assets/mermaid-GHXKKRXX-BSt5tun0.js +0 -1
  173. /package/codemini-web/dist/assets/{abap-9R7RjkQK.js → abap-8gQxhw9X.js} +0 -0
  174. /package/codemini-web/dist/assets/{abap-BRbAAyvE.js → abap-DKGmjV0m.js} +0 -0
  175. /package/codemini-web/dist/assets/{actionscript-3-CNowah7a.js → actionscript-3-Bvx2-wHH.js} +0 -0
  176. /package/codemini-web/dist/assets/{actionscript-3-Cj-0sM4g.js → actionscript-3-PQHI9sRP.js} +0 -0
  177. /package/codemini-web/dist/assets/{ada-D5HmrmpD.js → ada-7dCRqcEc.js} +0 -0
  178. /package/codemini-web/dist/assets/{ada-DhEA_nP5.js → ada-DXyixiJc.js} +0 -0
  179. /package/codemini-web/dist/assets/{andromeeda-CWmR-N6V.js → andromeeda-CvHLbWZU.js} +0 -0
  180. /package/codemini-web/dist/assets/{andromeeda-i_b3g2bn.js → andromeeda-D2bWTgXr.js} +0 -0
  181. /package/codemini-web/dist/assets/{apache-D37U8o0r.js → apache-DuwFT_ko.js} +0 -0
  182. /package/codemini-web/dist/assets/{apache-D5R2GKIs.js → apache-r4zD7Rt3.js} +0 -0
  183. /package/codemini-web/dist/assets/{apex-CszkG4lQ.js → apex-D3aemokf.js} +0 -0
  184. /package/codemini-web/dist/assets/{apex-Qu8W4hal.js → apex-ZrILV9y9.js} +0 -0
  185. /package/codemini-web/dist/assets/{applescript-Ajt9gmC_.js → applescript-B2uvrvew.js} +0 -0
  186. /package/codemini-web/dist/assets/{applescript-CBey3ErE.js → applescript-QewDI2Hm.js} +0 -0
  187. /package/codemini-web/dist/assets/{ara-CRKnUAN1.js → ara-CAKYVeDX.js} +0 -0
  188. /package/codemini-web/dist/assets/{ara-DpGk8XWf.js → ara-bfzpmn9d.js} +0 -0
  189. /package/codemini-web/dist/assets/{asciidoc-1KYZEB6-.js → asciidoc-CN-ydgfB.js} +0 -0
  190. /package/codemini-web/dist/assets/{asciidoc-BdDORSgx.js → asciidoc-xYtH5EEV.js} +0 -0
  191. /package/codemini-web/dist/assets/{asm-DAaViY0U.js → asm-DsgOTp4c.js} +0 -0
  192. /package/codemini-web/dist/assets/{asm-DGLRM3OU.js → asm-DuNyKkDV.js} +0 -0
  193. /package/codemini-web/dist/assets/{aurora-x-DdfqxvM_.js → aurora-x-CUFqx0Kt.js} +0 -0
  194. /package/codemini-web/dist/assets/{aurora-x-LPpmXm4i.js → aurora-x-mlfFqJAh.js} +0 -0
  195. /package/codemini-web/dist/assets/{awk-B-J9te9x.js → awk-BDSWDVpS.js} +0 -0
  196. /package/codemini-web/dist/assets/{awk-ButuPTaW.js → awk-DETgsRcQ.js} +0 -0
  197. /package/codemini-web/dist/assets/{ayu-dark-BdNJk5qF.js → ayu-dark-BTeHke7b.js} +0 -0
  198. /package/codemini-web/dist/assets/{ayu-dark-Dv4ngVMP.js → ayu-dark-tcpgNy3s.js} +0 -0
  199. /package/codemini-web/dist/assets/{ayu-light-CxeOePuA.js → ayu-light-B3O22CFD.js} +0 -0
  200. /package/codemini-web/dist/assets/{ayu-light-DkLNbAkT.js → ayu-light-CoZXvb4i.js} +0 -0
  201. /package/codemini-web/dist/assets/{ayu-mirage-BoyGjGHX.js → ayu-mirage-DkAXwBmm.js} +0 -0
  202. /package/codemini-web/dist/assets/{ayu-mirage-i2YLXKmY.js → ayu-mirage-DlGy8b5I.js} +0 -0
  203. /package/codemini-web/dist/assets/{ballerina-CZ8CAKmi.js → ballerina-Dj9SHEWp.js} +0 -0
  204. /package/codemini-web/dist/assets/{ballerina-DodmBVwR.js → ballerina-eIQtFtZN.js} +0 -0
  205. /package/codemini-web/dist/assets/{bat-fNtaIqKE.js → bat-DVPhDFws.js} +0 -0
  206. /package/codemini-web/dist/assets/{bat-jA-YqDhG.js → bat-Dr7SKqI2.js} +0 -0
  207. /package/codemini-web/dist/assets/{beancount-9imagnS2.js → beancount-C5lGUCpK.js} +0 -0
  208. /package/codemini-web/dist/assets/{beancount-BCkjWTs-.js → beancount-DRh4LoEp.js} +0 -0
  209. /package/codemini-web/dist/assets/{berry-DjEHm1kC.js → berry-BJPWN0aG.js} +0 -0
  210. /package/codemini-web/dist/assets/{berry-QTBYpUPn.js → berry-C-53c7Cz.js} +0 -0
  211. /package/codemini-web/dist/assets/{bibtex-CzFWvn9u.js → bibtex-BXZl-zGT.js} +0 -0
  212. /package/codemini-web/dist/assets/{bibtex-aOfmXHFj.js → bibtex-c-0Qlbu0.js} +0 -0
  213. /package/codemini-web/dist/assets/{bicep-BZLx0b6B.js → bicep-CCk_fREF.js} +0 -0
  214. /package/codemini-web/dist/assets/{bicep-DLWEubga.js → bicep-DUhze7H3.js} +0 -0
  215. /package/codemini-web/dist/assets/{bird2-VVa6lZ01.js → bird2-DIkIj7Bl.js} +0 -0
  216. /package/codemini-web/dist/assets/{bird2-V7dWeQhQ.js → bird2-D_94N4Us.js} +0 -0
  217. /package/codemini-web/dist/assets/{c-Bv0tI3pq.js → c-6DvQDc19.js} +0 -0
  218. /package/codemini-web/dist/assets/{c-CgTSul4N.js → c-C6aegu_R.js} +0 -0
  219. /package/codemini-web/dist/assets/{c3-BDcFIiRd.js → c3-CUFd2ak_.js} +0 -0
  220. /package/codemini-web/dist/assets/{c3-SmmwBAzR.js → c3-_P-DNRtg.js} +0 -0
  221. /package/codemini-web/dist/assets/{cadence-DVNAI4pJ.js → cadence-CRyyaA0J.js} +0 -0
  222. /package/codemini-web/dist/assets/{cadence-DaglWUgA.js → cadence-zuA3Lqsu.js} +0 -0
  223. /package/codemini-web/dist/assets/{catppuccin-frappe-CSAC76is.js → catppuccin-frappe-C4xh_RpD.js} +0 -0
  224. /package/codemini-web/dist/assets/{catppuccin-frappe-DXCXlnyU.js → catppuccin-frappe-CptwRcV-.js} +0 -0
  225. /package/codemini-web/dist/assets/{catppuccin-latte-BXW2qYGv.js → catppuccin-latte-B5zTan83.js} +0 -0
  226. /package/codemini-web/dist/assets/{catppuccin-latte-Jt6sqtds.js → catppuccin-latte-ZIzlVBYe.js} +0 -0
  227. /package/codemini-web/dist/assets/{catppuccin-macchiato--32cesHH.js → catppuccin-macchiato-D9kD7BY6.js} +0 -0
  228. /package/codemini-web/dist/assets/{catppuccin-macchiato-HM96_05s.js → catppuccin-macchiato-DOZXEuSH.js} +0 -0
  229. /package/codemini-web/dist/assets/{catppuccin-mocha-BBRFilGN.js → catppuccin-mocha-DJlDggGb.js} +0 -0
  230. /package/codemini-web/dist/assets/{catppuccin-mocha-CXgIAGBL.js → catppuccin-mocha-rnm_6i_u.js} +0 -0
  231. /package/codemini-web/dist/assets/{clarity-BJs8u8xG.js → clarity-CRWl5goA.js} +0 -0
  232. /package/codemini-web/dist/assets/{clarity-DS5YLe8G.js → clarity-Dp-fzxYs.js} +0 -0
  233. /package/codemini-web/dist/assets/{clojure-BVGPdaE2.js → clojure-85kagXuc.js} +0 -0
  234. /package/codemini-web/dist/assets/{clojure-DpYoDXXl.js → clojure-Dva5KkQZ.js} +0 -0
  235. /package/codemini-web/dist/assets/{cmake-CCC7tP43.js → cmake-5KZO_J3V.js} +0 -0
  236. /package/codemini-web/dist/assets/{cmake-CdseusyP.js → cmake-BLlH-zTC.js} +0 -0
  237. /package/codemini-web/dist/assets/{codeowners-5EAeZxPo.js → codeowners-CwITHnrC.js} +0 -0
  238. /package/codemini-web/dist/assets/{codeowners-DXhoR5Ap.js → codeowners-EEO8moZM.js} +0 -0
  239. /package/codemini-web/dist/assets/{codeql-BGjlu3KC.js → codeql-C3IPOiKP.js} +0 -0
  240. /package/codemini-web/dist/assets/{codeql-OkUuMGe9.js → codeql-DsuZZPKs.js} +0 -0
  241. /package/codemini-web/dist/assets/{common-lisp-BE6wRQeA.js → common-lisp-DQj0fa1s.js} +0 -0
  242. /package/codemini-web/dist/assets/{common-lisp-DCRDlc4V.js → common-lisp-DtIqam2P.js} +0 -0
  243. /package/codemini-web/dist/assets/{coq-CRT8yML1.js → coq-BGPtnnb4.js} +0 -0
  244. /package/codemini-web/dist/assets/{coq-acwo70uY.js → coq-CcjGcL2N.js} +0 -0
  245. /package/codemini-web/dist/assets/{csharp-Ca2kU4Te.js → csharp-Bz4y1fn8.js} +0 -0
  246. /package/codemini-web/dist/assets/{csharp-Cqz84DXU.js → csharp-CvOkmYFZ.js} +0 -0
  247. /package/codemini-web/dist/assets/{css-Dr0v2l-V.js → css-Cqx-Zivz.js} +0 -0
  248. /package/codemini-web/dist/assets/{css-z2ijrDWT.js → css-DsnEBqY_.js} +0 -0
  249. /package/codemini-web/dist/assets/{csv-CqpUSPyF.js → csv-92JdhrVb.js} +0 -0
  250. /package/codemini-web/dist/assets/{csv-DUpZC5ZD.js → csv-Cz8IGB-r.js} +0 -0
  251. /package/codemini-web/dist/assets/{cue-D4-Hq7Jx.js → cue-BAtFpXsn.js} +0 -0
  252. /package/codemini-web/dist/assets/{cue-DlXQ7arx.js → cue-DO5iBckt.js} +0 -0
  253. /package/codemini-web/dist/assets/{cypher-CXMVfSpG.js → cypher-DrFFccaV.js} +0 -0
  254. /package/codemini-web/dist/assets/{cypher-D6dhuZbo.js → cypher-Dt0SBufN.js} +0 -0
  255. /package/codemini-web/dist/assets/{d-BUgyoY6k.js → d-BIzkfvy1.js} +0 -0
  256. /package/codemini-web/dist/assets/{d-Cc_KoyiC.js → d-POAmrdpL.js} +0 -0
  257. /package/codemini-web/dist/assets/{dark-plus-C0kLyDb3.js → dark-plus-Ci223Kw7.js} +0 -0
  258. /package/codemini-web/dist/assets/{dark-plus-DNkJKrcZ.js → dark-plus-D-icMr_O.js} +0 -0
  259. /package/codemini-web/dist/assets/{dart-BIyV3H7V.js → dart-BA_zGMIh.js} +0 -0
  260. /package/codemini-web/dist/assets/{dart-CVd7TDni.js → dart-Cv4z4sEx.js} +0 -0
  261. /package/codemini-web/dist/assets/{dax-DtoJMuz5.js → dax-CArXkuXO.js} +0 -0
  262. /package/codemini-web/dist/assets/{dax-sEzq00Tq.js → dax-Cw_LNvcO.js} +0 -0
  263. /package/codemini-web/dist/assets/{desktop-3VGbzlmJ.js → desktop-BRifweK7.js} +0 -0
  264. /package/codemini-web/dist/assets/{desktop-BkIJ2CMP.js → desktop-B_uWbpWi.js} +0 -0
  265. /package/codemini-web/dist/assets/{diff-D4HSRbRn.js → diff-CTnn6Hu3.js} +0 -0
  266. /package/codemini-web/dist/assets/{diff-RUsawely.js → diff-pSjjL-ZH.js} +0 -0
  267. /package/codemini-web/dist/assets/{docker-CDpVZYy7.js → docker-D0ufKJwE.js} +0 -0
  268. /package/codemini-web/dist/assets/{docker-DkLGgDMo.js → docker-r0L9bSzI.js} +0 -0
  269. /package/codemini-web/dist/assets/{dotenv-BWp1FaLo.js → dotenv-BKm_YkX-.js} +0 -0
  270. /package/codemini-web/dist/assets/{dotenv-DWnlamm2.js → dotenv-DU-Uz6AA.js} +0 -0
  271. /package/codemini-web/dist/assets/{dracula-Donvxzd6.js → dracula-BkVbNmMW.js} +0 -0
  272. /package/codemini-web/dist/assets/{dracula-QP8aKUFB.js → dracula-C5lq8I7X.js} +0 -0
  273. /package/codemini-web/dist/assets/{dracula-soft-BNzyYlRI.js → dracula-soft-Benyby8y.js} +0 -0
  274. /package/codemini-web/dist/assets/{dracula-soft-BqL-kkUg.js → dracula-soft-QH3ntlSU.js} +0 -0
  275. /package/codemini-web/dist/assets/{dream-maker-DtLD6KM3.js → dream-maker-Cp0hXi31.js} +0 -0
  276. /package/codemini-web/dist/assets/{dream-maker-MNBsfIGU.js → dream-maker-DE3sVgWW.js} +0 -0
  277. /package/codemini-web/dist/assets/{emacs-lisp-CVlPXEEa.js → emacs-lisp-H4-vgzf_.js} +0 -0
  278. /package/codemini-web/dist/assets/{emacs-lisp-BHIDiQRU.js → emacs-lisp-aMjKKeFP.js} +0 -0
  279. /package/codemini-web/dist/assets/{everforest-dark-DSK976eP.js → everforest-dark-CDp5hxXO.js} +0 -0
  280. /package/codemini-web/dist/assets/{everforest-dark-pZNhY4MK.js → everforest-dark-KTiMpaXm.js} +0 -0
  281. /package/codemini-web/dist/assets/{everforest-light-BijKClkf.js → everforest-light-vtFhxTqx.js} +0 -0
  282. /package/codemini-web/dist/assets/{everforest-light-BkaBVm1r.js → everforest-light-yJZ9a76P.js} +0 -0
  283. /package/codemini-web/dist/assets/{fennel-BsP4yvxI.js → fennel-Bruivvq3.js} +0 -0
  284. /package/codemini-web/dist/assets/{fennel-Cd-BhZ0S.js → fennel-DNMUz8BE.js} +0 -0
  285. /package/codemini-web/dist/assets/{fish-CimYqIk1.js → fish-C44z9fhZ.js} +0 -0
  286. /package/codemini-web/dist/assets/{fish-CpsjJ6FK.js → fish-CaGhpV7s.js} +0 -0
  287. /package/codemini-web/dist/assets/{fluent-D1peBFgx.js → fluent-BsmQk-nO.js} +0 -0
  288. /package/codemini-web/dist/assets/{fluent-O-Iic89O.js → fluent-d_qH0cYL.js} +0 -0
  289. /package/codemini-web/dist/assets/{fortran-free-form-BVNtEstX.js → fortran-free-form-B9mY58s0.js} +0 -0
  290. /package/codemini-web/dist/assets/{fortran-free-form-CIAQqF5W.js → fortran-free-form-DYzg4zHf.js} +0 -0
  291. /package/codemini-web/dist/assets/{gdscript-B_XVILZe.js → gdscript-B_WUGHIs.js} +0 -0
  292. /package/codemini-web/dist/assets/{gdscript-D-FJCTl3.js → gdscript-xj-VlIRU.js} +0 -0
  293. /package/codemini-web/dist/assets/{gdshader-BOrkFM_X.js → gdshader-BR6nyn6z.js} +0 -0
  294. /package/codemini-web/dist/assets/{gdshader-Czvzt8dR.js → gdshader-BbYnAK14.js} +0 -0
  295. /package/codemini-web/dist/assets/{genie-BE7nKhIq.js → genie-CNeJKHWH.js} +0 -0
  296. /package/codemini-web/dist/assets/{genie-Mnf_jXpg.js → genie-CW-a1unw.js} +0 -0
  297. /package/codemini-web/dist/assets/{gherkin-DzGJhdqS.js → gherkin-By4Zv-ZP.js} +0 -0
  298. /package/codemini-web/dist/assets/{gherkin-DzkYuFEO.js → gherkin-D8z0Dn14.js} +0 -0
  299. /package/codemini-web/dist/assets/{github-dark-BB9G20EV.js → github-dark-BLlNbGxe.js} +0 -0
  300. /package/codemini-web/dist/assets/{github-dark-C98YWDhk.js → github-dark-C2YvJIRl.js} +0 -0
  301. /package/codemini-web/dist/assets/{github-dark-default-CBFNEU03.js → github-dark-default-DPZ1YWUU.js} +0 -0
  302. /package/codemini-web/dist/assets/{github-dark-default-CDGuVkyn.js → github-dark-default-XYu-6ww7.js} +0 -0
  303. /package/codemini-web/dist/assets/{github-dark-dimmed-CarTohA3.js → github-dark-dimmed-BlMwpJVf.js} +0 -0
  304. /package/codemini-web/dist/assets/{github-dark-dimmed-sQhEp72S.js → github-dark-dimmed-XAi8Eb3C.js} +0 -0
  305. /package/codemini-web/dist/assets/{github-dark-high-contrast-C8GVvrcM.js → github-dark-high-contrast-D86iyx7L.js} +0 -0
  306. /package/codemini-web/dist/assets/{github-dark-high-contrast-CsjOICAd.js → github-dark-high-contrast-KRBg57oP.js} +0 -0
  307. /package/codemini-web/dist/assets/{github-light-D17m3GP4.js → github-light-BLj5WXD_.js} +0 -0
  308. /package/codemini-web/dist/assets/{github-light-pT7U8Cnd.js → github-light-DxDzpZWY.js} +0 -0
  309. /package/codemini-web/dist/assets/{github-light-default-DiMoa1ZI.js → github-light-default-BLgrdOV4.js} +0 -0
  310. /package/codemini-web/dist/assets/{github-light-default-iyEXWnoa.js → github-light-default-BzOWmaf-.js} +0 -0
  311. /package/codemini-web/dist/assets/{github-light-high-contrast-DGwHD8Ty.js → github-light-high-contrast-Bm3JPX7v.js} +0 -0
  312. /package/codemini-web/dist/assets/{github-light-high-contrast-DLnsZL7l.js → github-light-high-contrast-Bmexxccr.js} +0 -0
  313. /package/codemini-web/dist/assets/{gleam-B9ISJjDl.js → gleam-BtOZgVle.js} +0 -0
  314. /package/codemini-web/dist/assets/{gleam-MAXpOqqF.js → gleam-Lf_XYEK-.js} +0 -0
  315. /package/codemini-web/dist/assets/{gn-BNADkWgR.js → gn-CY4VHHa6.js} +0 -0
  316. /package/codemini-web/dist/assets/{gn-RQRMslrP.js → gn-JO9YMz2t.js} +0 -0
  317. /package/codemini-web/dist/assets/{gnuplot-BRQvwTQM.js → gnuplot-DjZHg3_f.js} +0 -0
  318. /package/codemini-web/dist/assets/{gnuplot-CfIGZWjt.js → gnuplot-MPAbQV9r.js} +0 -0
  319. /package/codemini-web/dist/assets/{go-D6k5URxL.js → go-C6ThH8Hx.js} +0 -0
  320. /package/codemini-web/dist/assets/{go-iV8pwUYW.js → go-D2GlBE5F.js} +0 -0
  321. /package/codemini-web/dist/assets/{groovy-CxG1cXrE.js → groovy-1vEGAvvX.js} +0 -0
  322. /package/codemini-web/dist/assets/{groovy-lvGC2zUz.js → groovy-C_xCWdb_.js} +0 -0
  323. /package/codemini-web/dist/assets/{gruvbox-dark-hard-CC38iqQ4.js → gruvbox-dark-hard-DHhjEKTi.js} +0 -0
  324. /package/codemini-web/dist/assets/{gruvbox-dark-hard-Cnb1fzry.js → gruvbox-dark-hard-pdBjrsK5.js} +0 -0
  325. /package/codemini-web/dist/assets/{gruvbox-dark-medium-Cu5j8v_d.js → gruvbox-dark-medium-CL0I2zDn.js} +0 -0
  326. /package/codemini-web/dist/assets/{gruvbox-dark-medium-DaS0IqFN.js → gruvbox-dark-medium-Csp4lPEF.js} +0 -0
  327. /package/codemini-web/dist/assets/{gruvbox-dark-soft-BghHDwrM.js → gruvbox-dark-soft-BpNWvgik.js} +0 -0
  328. /package/codemini-web/dist/assets/{gruvbox-dark-soft-C4niJipy.js → gruvbox-dark-soft-Dy9vkRG2.js} +0 -0
  329. /package/codemini-web/dist/assets/{gruvbox-light-hard-BUhLUxUB.js → gruvbox-light-hard-CC8CVJp5.js} +0 -0
  330. /package/codemini-web/dist/assets/{gruvbox-light-hard-DTfv4LmB.js → gruvbox-light-hard-DO2pUUQV.js} +0 -0
  331. /package/codemini-web/dist/assets/{gruvbox-light-medium-GXeiXGL9.js → gruvbox-light-medium-B_nBvpHM.js} +0 -0
  332. /package/codemini-web/dist/assets/{gruvbox-light-medium-m1VBpvsE.js → gruvbox-light-medium-D2yGUmJd.js} +0 -0
  333. /package/codemini-web/dist/assets/{gruvbox-light-soft-CiE1IJdk.js → gruvbox-light-soft-C_9RTTTT.js} +0 -0
  334. /package/codemini-web/dist/assets/{gruvbox-light-soft-pTZgKx7j.js → gruvbox-light-soft-DuLKkKFi.js} +0 -0
  335. /package/codemini-web/dist/assets/{haskell-BZ8bGMYA.js → haskell-BFZjB68l.js} +0 -0
  336. /package/codemini-web/dist/assets/{haskell-DdaZtXdd.js → haskell-DfX5asxK.js} +0 -0
  337. /package/codemini-web/dist/assets/{haxe-1eAUKQ0B.js → haxe-DDQKctJt.js} +0 -0
  338. /package/codemini-web/dist/assets/{haxe-Df79h8x1.js → haxe-Me-TWuvr.js} +0 -0
  339. /package/codemini-web/dist/assets/{hcl-BibREsa1.js → hcl-DUAADz_v.js} +0 -0
  340. /package/codemini-web/dist/assets/{hcl-DQqvKq2I.js → hcl-Ry3nZWbt.js} +0 -0
  341. /package/codemini-web/dist/assets/{hjson-D-iSecYq.js → hjson-CGFDmpMn.js} +0 -0
  342. /package/codemini-web/dist/assets/{hjson-DNWMSWLN.js → hjson-DyGphq4K.js} +0 -0
  343. /package/codemini-web/dist/assets/{hlsl-CckLjo_3.js → hlsl-BKWZVvKK.js} +0 -0
  344. /package/codemini-web/dist/assets/{hlsl-Df5oFh9i.js → hlsl-BVEJlW36.js} +0 -0
  345. /package/codemini-web/dist/assets/{horizon-BCbhfxa1.js → horizon-BZmYXqIF.js} +0 -0
  346. /package/codemini-web/dist/assets/{horizon-BG-OH9yH.js → horizon-D3wQTjs_.js} +0 -0
  347. /package/codemini-web/dist/assets/{horizon-bright-CXcxBcih.js → horizon-bright-Cfh8ud4W.js} +0 -0
  348. /package/codemini-web/dist/assets/{horizon-bright-B0vmEjwb.js → horizon-bright-D0uooZm5.js} +0 -0
  349. /package/codemini-web/dist/assets/{houston-C8DdNIgg.js → houston-BUtcOxf9.js} +0 -0
  350. /package/codemini-web/dist/assets/{houston-DHnjBE42.js → houston-CGv9NbgY.js} +0 -0
  351. /package/codemini-web/dist/assets/{hy-6acR1htR.js → hy-BqI2sCU2.js} +0 -0
  352. /package/codemini-web/dist/assets/{hy-DaILHjW8.js → hy-oWi_RwAK.js} +0 -0
  353. /package/codemini-web/dist/assets/{imba-BA6_JyKt.js → imba-DnUn0wai.js} +0 -0
  354. /package/codemini-web/dist/assets/{imba-I9bJJvhi.js → imba-iwzgkuTD.js} +0 -0
  355. /package/codemini-web/dist/assets/{ini-DqXMcqXm.js → ini-BNaakZQr.js} +0 -0
  356. /package/codemini-web/dist/assets/{ini-ovi-wMtM.js → ini-DMV_1xp9.js} +0 -0
  357. /package/codemini-web/dist/assets/{java-Ds1cyVrp.js → java-CTslCthB.js} +0 -0
  358. /package/codemini-web/dist/assets/{java-X0I2c5Az.js → java-DbkCw8gs.js} +0 -0
  359. /package/codemini-web/dist/assets/{javascript-Cx8CXBJR.js → javascript-BzJBge5U.js} +0 -0
  360. /package/codemini-web/dist/assets/{javascript-WC6XFf_S.js → javascript-DqHURDA-.js} +0 -0
  361. /package/codemini-web/dist/assets/{json-CY14kIzN.js → json-Cu3T5nD7.js} +0 -0
  362. /package/codemini-web/dist/assets/{json-CmuSmrUv.js → json-DZN6rfPx.js} +0 -0
  363. /package/codemini-web/dist/assets/{json5-Cus7zL-r.js → json5-DSzj6NCq.js} +0 -0
  364. /package/codemini-web/dist/assets/{json5-JNG5kh3j.js → json5-Y2CuQCK-.js} +0 -0
  365. /package/codemini-web/dist/assets/{jsonc-Bo6bgSpa.js → jsonc-B30nqSUF.js} +0 -0
  366. /package/codemini-web/dist/assets/{jsonc-RzqrtWTz.js → jsonc-DwzKY8NT.js} +0 -0
  367. /package/codemini-web/dist/assets/{jsonl-CLcLUtvq.js → jsonl-B7UEa0TN.js} +0 -0
  368. /package/codemini-web/dist/assets/{jsonl-eDmbsRcr.js → jsonl-C8L12LZq.js} +0 -0
  369. /package/codemini-web/dist/assets/{jsonnet--7yRuAzt.js → jsonnet-DYAV3b_U.js} +0 -0
  370. /package/codemini-web/dist/assets/{jsonnet-BrmnmEy9.js → jsonnet-ZiCJB3SD.js} +0 -0
  371. /package/codemini-web/dist/assets/{jssm-C-QfdDgD.js → jssm-6UFVEBGg.js} +0 -0
  372. /package/codemini-web/dist/assets/{jssm-Cid5Rr2Y.js → jssm-BOfC2rh1.js} +0 -0
  373. /package/codemini-web/dist/assets/{jsx-Bl4e1-KE.js → jsx-AgmFDCOF.js} +0 -0
  374. /package/codemini-web/dist/assets/{jsx-DmH5dwMF.js → jsx-BEmZt5uE.js} +0 -0
  375. /package/codemini-web/dist/assets/{kanagawa-dragon-BxDDNs-7.js → kanagawa-dragon-BVoApXR6.js} +0 -0
  376. /package/codemini-web/dist/assets/{kanagawa-dragon-Dc8jzBf8.js → kanagawa-dragon-DF1o80wl.js} +0 -0
  377. /package/codemini-web/dist/assets/{kanagawa-lotus-BQyifewU.js → kanagawa-lotus-BkVGQkvY.js} +0 -0
  378. /package/codemini-web/dist/assets/{kanagawa-lotus-DglQpAHb.js → kanagawa-lotus-C-uV5im6.js} +0 -0
  379. /package/codemini-web/dist/assets/{kanagawa-wave-BsJGVIZT.js → kanagawa-wave-BizPisns.js} +0 -0
  380. /package/codemini-web/dist/assets/{kanagawa-wave-CTxJC692.js → kanagawa-wave-Cl5W2OPg.js} +0 -0
  381. /package/codemini-web/dist/assets/{kdl-CPujEk7a.js → kdl-BCaiqQ4X.js} +0 -0
  382. /package/codemini-web/dist/assets/{kdl-D2MbAIKj.js → kdl-Bg7xxjIF.js} +0 -0
  383. /package/codemini-web/dist/assets/{kotlin-GNGS6f4G.js → kotlin-CNprttl8.js} +0 -0
  384. /package/codemini-web/dist/assets/{kotlin-fpq87Jdo.js → kotlin-DRaoVNCW.js} +0 -0
  385. /package/codemini-web/dist/assets/{kusto-B1r4va-8.js → kusto-CW62F42W.js} +0 -0
  386. /package/codemini-web/dist/assets/{kusto-BcKmLn2p.js → kusto-D3uRUZFA.js} +0 -0
  387. /package/codemini-web/dist/assets/{laserwave-BLDq6SCM.js → laserwave-B1sGpeV2.js} +0 -0
  388. /package/codemini-web/dist/assets/{laserwave-CrjhMkHv.js → laserwave-BypMvj8s.js} +0 -0
  389. /package/codemini-web/dist/assets/{lean-B9Xp-kaJ.js → lean-BbKKg8_U.js} +0 -0
  390. /package/codemini-web/dist/assets/{lean-CQ4oht2M.js → lean-CYwit69O.js} +0 -0
  391. /package/codemini-web/dist/assets/{less-BKjOc0Gl.js → less-6BW8xQaX.js} +0 -0
  392. /package/codemini-web/dist/assets/{less-DgluPI4Z.js → less-CMYX9LBx.js} +0 -0
  393. /package/codemini-web/dist/assets/{light-plus-Ce6vIMrA.js → light-plus-CytNlrnF.js} +0 -0
  394. /package/codemini-web/dist/assets/{light-plus-DFt9HI_B.js → light-plus-zSYF2DYe.js} +0 -0
  395. /package/codemini-web/dist/assets/{llvm-C_Bk8N51.js → llvm-BFcvUor4.js} +0 -0
  396. /package/codemini-web/dist/assets/{llvm-XDy97SdL.js → llvm-OMExIg60.js} +0 -0
  397. /package/codemini-web/dist/assets/{log-Cqyx7kYB.js → log-BBfW4u9k.js} +0 -0
  398. /package/codemini-web/dist/assets/{log-tjGJZ7jx.js → log-BrS0_Y6P.js} +0 -0
  399. /package/codemini-web/dist/assets/{logo-BMyACSNp.js → logo-D8GGcRiY.js} +0 -0
  400. /package/codemini-web/dist/assets/{logo-rCQwad-6.js → logo-L3bKRswG.js} +0 -0
  401. /package/codemini-web/dist/assets/{luau-C0wE4YeK.js → luau-B-E69GSh.js} +0 -0
  402. /package/codemini-web/dist/assets/{luau-Dw3qkd4h.js → luau-CZIl0XK4.js} +0 -0
  403. /package/codemini-web/dist/assets/{make-DRoG6w-e.js → make-CA9NajZk.js} +0 -0
  404. /package/codemini-web/dist/assets/{make-DZENZd8z.js → make-mlZyflos.js} +0 -0
  405. /package/codemini-web/dist/assets/{markdown-CbgVmtS5.js → markdown-CppElJDR.js} +0 -0
  406. /package/codemini-web/dist/assets/{markdown-DMIvNSB1.js → markdown-DkXb8qKc.js} +0 -0
  407. /package/codemini-web/dist/assets/{material-theme-D1yzOeFY.js → material-theme-BYnCtUED.js} +0 -0
  408. /package/codemini-web/dist/assets/{material-theme-YhiuxyiP.js → material-theme-OBz0sIMu.js} +0 -0
  409. /package/codemini-web/dist/assets/{material-theme-darker-CKeuyK7B.js → material-theme-darker-BNfFk916.js} +0 -0
  410. /package/codemini-web/dist/assets/{material-theme-darker-DhWqiNtj.js → material-theme-darker-s0o-qH0l.js} +0 -0
  411. /package/codemini-web/dist/assets/{material-theme-lighter-C56RzTfM.js → material-theme-lighter-BXApD6tt.js} +0 -0
  412. /package/codemini-web/dist/assets/{material-theme-lighter-PKoq0Soa.js → material-theme-lighter-D0OJsx_T.js} +0 -0
  413. /package/codemini-web/dist/assets/{material-theme-ocean-DUos8xKe.js → material-theme-ocean-CKWC7YJB.js} +0 -0
  414. /package/codemini-web/dist/assets/{material-theme-ocean-TtH-ZZAj.js → material-theme-ocean-Cl_PEvBf.js} +0 -0
  415. /package/codemini-web/dist/assets/{material-theme-palenight-CZBKx4B1.js → material-theme-palenight-CEFfV_mF.js} +0 -0
  416. /package/codemini-web/dist/assets/{material-theme-palenight-DPEAidnA.js → material-theme-palenight-DOTFIR3W.js} +0 -0
  417. /package/codemini-web/dist/assets/{matlab-BJwkjxyL.js → matlab-BiYD-Y7N.js} +0 -0
  418. /package/codemini-web/dist/assets/{matlab-Buftnej6.js → matlab-CwLrY_Ss.js} +0 -0
  419. /package/codemini-web/dist/assets/{mdx-BvkytFG9.js → mdx-OZt5aooY.js} +0 -0
  420. /package/codemini-web/dist/assets/{mdx-COL7Vpwq.js → mdx-irdaVRH8.js} +0 -0
  421. /package/codemini-web/dist/assets/{mermaid-Ctx7uNrT.js → mermaid-CkReAMVX.js} +0 -0
  422. /package/codemini-web/dist/assets/{mermaid-tvyj1ZQ2.js → mermaid-mzvznqsh.js} +0 -0
  423. /package/codemini-web/dist/assets/{min-dark-BA-rwgF3.js → min-dark-BAbZNtjj.js} +0 -0
  424. /package/codemini-web/dist/assets/{min-dark-D66g901Q.js → min-dark-DoFQ3_GG.js} +0 -0
  425. /package/codemini-web/dist/assets/{min-light-CMnDj2iG.js → min-light-BzEisXBR.js} +0 -0
  426. /package/codemini-web/dist/assets/{min-light-DHUVhXnm.js → min-light-o5Iu4PYL.js} +0 -0
  427. /package/codemini-web/dist/assets/{mipsasm-ByaU0dEX.js → mipsasm-B9ciUcum.js} +0 -0
  428. /package/codemini-web/dist/assets/{mipsasm-C6fvALrw.js → mipsasm-DONjtc4L.js} +0 -0
  429. /package/codemini-web/dist/assets/{mojo-B3qnM1a8.js → mojo-A9VdeGlD.js} +0 -0
  430. /package/codemini-web/dist/assets/{mojo-CqhYERP_.js → mojo-CHKQ5hW9.js} +0 -0
  431. /package/codemini-web/dist/assets/{monokai-D3MyQCxG.js → monokai-B8rLeJY_.js} +0 -0
  432. /package/codemini-web/dist/assets/{monokai-DCoxt20T.js → monokai-SjnsTHn6.js} +0 -0
  433. /package/codemini-web/dist/assets/{moonbit-C4BfwLm6.js → moonbit-Bb7eeXNq.js} +0 -0
  434. /package/codemini-web/dist/assets/{moonbit-Cjo3d0oi.js → moonbit-CWIHpJf0.js} +0 -0
  435. /package/codemini-web/dist/assets/{move-BZSDQnwS.js → move-Dy7CmIgW.js} +0 -0
  436. /package/codemini-web/dist/assets/{move-DOj5FawL.js → move-MA-qIPBB.js} +0 -0
  437. /package/codemini-web/dist/assets/{narrat-CDHYPJWr.js → narrat-Cq6wc063.js} +0 -0
  438. /package/codemini-web/dist/assets/{narrat-DY5cg5OF.js → narrat-NioX5-_j.js} +0 -0
  439. /package/codemini-web/dist/assets/{nextflow-groovy-o7ZjyFmf.js → nextflow-groovy-BgEBN3iS.js} +0 -0
  440. /package/codemini-web/dist/assets/{nextflow-groovy-D6rYlJlL.js → nextflow-groovy-jKlTICX_.js} +0 -0
  441. /package/codemini-web/dist/assets/{night-owl-DuMFo77c.js → night-owl-C_xVeV9U.js} +0 -0
  442. /package/codemini-web/dist/assets/{night-owl-NHZjGVLB.js → night-owl-DHaGAA37.js} +0 -0
  443. /package/codemini-web/dist/assets/{night-owl-light-DcKosvl7.js → night-owl-light-B1H1b6pL.js} +0 -0
  444. /package/codemini-web/dist/assets/{night-owl-light-DihOYNub.js → night-owl-light-C_DkqGGe.js} +0 -0
  445. /package/codemini-web/dist/assets/{nix-C2G-gZoY.js → nix-BZVKmCQS.js} +0 -0
  446. /package/codemini-web/dist/assets/{nix-Csr5leD-.js → nix-CBdStlCf.js} +0 -0
  447. /package/codemini-web/dist/assets/{nord-CqZqLQaJ.js → nord-3ndmnVQb.js} +0 -0
  448. /package/codemini-web/dist/assets/{nord-DomFMWpF.js → nord-CrTSutxR.js} +0 -0
  449. /package/codemini-web/dist/assets/{nushell-IZVQdI7Z.js → nushell-BSMBFYgO.js} +0 -0
  450. /package/codemini-web/dist/assets/{nushell-S11HUHTG.js → nushell-C8hgS98n.js} +0 -0
  451. /package/codemini-web/dist/assets/{objective-c-D9GKvYFi.js → objective-c-BUiYTSad.js} +0 -0
  452. /package/codemini-web/dist/assets/{objective-c-DD1i5sf2.js → objective-c-DGGlUjtt.js} +0 -0
  453. /package/codemini-web/dist/assets/{objective-cpp-CtzOCe2w.js → objective-cpp-Bk8vAxra.js} +0 -0
  454. /package/codemini-web/dist/assets/{objective-cpp-SqrtXFXh.js → objective-cpp-BwY1U2XT.js} +0 -0
  455. /package/codemini-web/dist/assets/{ocaml-BlMDMjEj.js → ocaml-D51PiCY5.js} +0 -0
  456. /package/codemini-web/dist/assets/{ocaml-C_PTi_Pz.js → ocaml-KuZ2AeVv.js} +0 -0
  457. /package/codemini-web/dist/assets/{odin-BWpZDKBG.js → odin-CoC4d8pi.js} +0 -0
  458. /package/codemini-web/dist/assets/{odin-CoWSDSNi.js → odin-CvKV_dam.js} +0 -0
  459. /package/codemini-web/dist/assets/{one-dark-pro-DWENJxB_.js → one-dark-pro-BbI-DLX3.js} +0 -0
  460. /package/codemini-web/dist/assets/{one-dark-pro-DpWTHpwg.js → one-dark-pro-C9bEA2Dz.js} +0 -0
  461. /package/codemini-web/dist/assets/{one-light-CEeF6aqP.js → one-light-DZ_5GYrV.js} +0 -0
  462. /package/codemini-web/dist/assets/{one-light-Cu0d64Hp.js → one-light-Do56bP_A.js} +0 -0
  463. /package/codemini-web/dist/assets/{openscad-BM4fjXzn.js → openscad-0H6ozqDa.js} +0 -0
  464. /package/codemini-web/dist/assets/{openscad-D3gRRPUh.js → openscad-DCmPLSXt.js} +0 -0
  465. /package/codemini-web/dist/assets/{pascal-DYsRufgb.js → pascal-BMY45JJO.js} +0 -0
  466. /package/codemini-web/dist/assets/{pascal-G3gJIkHz.js → pascal-DghlbeLm.js} +0 -0
  467. /package/codemini-web/dist/assets/{pierre-dark-CBqOR10c.js → pierre-dark-Be9bUWwI.js} +0 -0
  468. /package/codemini-web/dist/assets/{pierre-light-sgwdVCEP.js → pierre-light-Cq6kCwdb.js} +0 -0
  469. /package/codemini-web/dist/assets/{pkl-DdsryWcC.js → pkl-BlBky-cR.js} +0 -0
  470. /package/codemini-web/dist/assets/{pkl-Djf8ANrI.js → pkl-BzGvIelR.js} +0 -0
  471. /package/codemini-web/dist/assets/{plastic-CmjIC4JL.js → plastic-C50vuo0c.js} +0 -0
  472. /package/codemini-web/dist/assets/{plastic-CwUA_4-2.js → plastic-CHL2Ec9b.js} +0 -0
  473. /package/codemini-web/dist/assets/{plsql-B1bmZxUF.js → plsql-B6Eq-lAd.js} +0 -0
  474. /package/codemini-web/dist/assets/{plsql-C2yEtnCG.js → plsql-mtL4EDYx.js} +0 -0
  475. /package/codemini-web/dist/assets/{po-BvnTR3_f.js → po-9sFvF4V8.js} +0 -0
  476. /package/codemini-web/dist/assets/{po-Dy7ytuR1.js → po-ByS5p8Sz.js} +0 -0
  477. /package/codemini-web/dist/assets/{poimandres-BTndTogr.js → poimandres-Cs9j_baE.js} +0 -0
  478. /package/codemini-web/dist/assets/{poimandres-u68WOWhl.js → poimandres-Cu7ZGbJ7.js} +0 -0
  479. /package/codemini-web/dist/assets/{polar-CAj5SJyd.js → polar-COmSbiHW.js} +0 -0
  480. /package/codemini-web/dist/assets/{polar-CjLVWIyd.js → polar-Dc9aglFR.js} +0 -0
  481. /package/codemini-web/dist/assets/{postcss-DiNtjF5e.js → postcss-B_ncIJlb.js} +0 -0
  482. /package/codemini-web/dist/assets/{postcss-DrpvRGGG.js → postcss-D_ArMqNC.js} +0 -0
  483. /package/codemini-web/dist/assets/{powerquery-I1Ei5hrS.js → powerquery-BzHwsYRb.js} +0 -0
  484. /package/codemini-web/dist/assets/{powerquery-iC4Ra9LJ.js → powerquery-CnV22x6V.js} +0 -0
  485. /package/codemini-web/dist/assets/{powershell-Ch2YpFAx.js → powershell-BGZYhdIS.js} +0 -0
  486. /package/codemini-web/dist/assets/{powershell-Coc0WruX.js → powershell-C6bIwB0M.js} +0 -0
  487. /package/codemini-web/dist/assets/{prisma-HWctQCpn.js → prisma-D5S9vj6g.js} +0 -0
  488. /package/codemini-web/dist/assets/{prisma-Ojgxt2lx.js → prisma-rx7KPY6m.js} +0 -0
  489. /package/codemini-web/dist/assets/{prolog-C1UOAv4v.js → prolog-BfgX1o85.js} +0 -0
  490. /package/codemini-web/dist/assets/{prolog-DHAsH4Hf.js → prolog-CHVuxG8M.js} +0 -0
  491. /package/codemini-web/dist/assets/{proto-D07RTuB5.js → proto-B_ioi7EM.js} +0 -0
  492. /package/codemini-web/dist/assets/{proto-mTghX89X.js → proto-BhkmoXVj.js} +0 -0
  493. /package/codemini-web/dist/assets/{puppet-D1Zcnrr5.js → puppet-Brdz8eoo.js} +0 -0
  494. /package/codemini-web/dist/assets/{puppet-D_zyrMo2.js → puppet-tRlrvlcY.js} +0 -0
  495. /package/codemini-web/dist/assets/{purescript-CV-DVmZj.js → purescript-Bwtvgqjl.js} +0 -0
  496. /package/codemini-web/dist/assets/{purescript-s82m5f0Y.js → purescript-DX3wKXeK.js} +0 -0
  497. /package/codemini-web/dist/assets/{python-BhsI1K6K.js → python-9qQRnRoJ.js} +0 -0
  498. /package/codemini-web/dist/assets/{python-DcnbpNOV.js → python-CUtprRpG.js} +0 -0
  499. /package/codemini-web/dist/assets/{qmldir-BBNnU9RJ.js → qmldir-BP8WEvx8.js} +0 -0
  500. /package/codemini-web/dist/assets/{qmldir-Bzkc2Njy.js → qmldir-ftS4SxdQ.js} +0 -0
  501. /package/codemini-web/dist/assets/{qss-CC0PKRbL.js → qss-DrZJSiDh.js} +0 -0
  502. /package/codemini-web/dist/assets/{qss-CKbozdtF.js → qss-Mo-j41VR.js} +0 -0
  503. /package/codemini-web/dist/assets/{r-B4lG5syH.js → r-BX0U3688.js} +0 -0
  504. /package/codemini-web/dist/assets/{r-BKej5r_k.js → r-DN76jn9o.js} +0 -0
  505. /package/codemini-web/dist/assets/{racket-CUDoXUwy.js → racket-CrTD1_3_.js} +0 -0
  506. /package/codemini-web/dist/assets/{racket-Cbwns2Cq.js → racket-DCvJyROq.js} +0 -0
  507. /package/codemini-web/dist/assets/{raku-CeV6tH_x.js → raku-Bhig3MAC.js} +0 -0
  508. /package/codemini-web/dist/assets/{raku-XPAjN9OU.js → raku-CvVnta4t.js} +0 -0
  509. /package/codemini-web/dist/assets/{red-8aRo80UF.js → red-CWX-2pbk.js} +0 -0
  510. /package/codemini-web/dist/assets/{red-CVEaJbMR.js → red-CztBD70n.js} +0 -0
  511. /package/codemini-web/dist/assets/{reg-B0B_plbq.js → reg-99qFU_BD.js} +0 -0
  512. /package/codemini-web/dist/assets/{reg-C_WE1pkC.js → reg-C0s7-4s0.js} +0 -0
  513. /package/codemini-web/dist/assets/{regexp-CK-1EP63.js → regexp-BIytsEkR.js} +0 -0
  514. /package/codemini-web/dist/assets/{regexp-da3KYCEG.js → regexp-Cov7gRr6.js} +0 -0
  515. /package/codemini-web/dist/assets/{rel-CpHQF4b7.js → rel-BuFiYCnx.js} +0 -0
  516. /package/codemini-web/dist/assets/{rel-DhoFe2Y7.js → rel-D1_XRRAX.js} +0 -0
  517. /package/codemini-web/dist/assets/{riscv-CKx_Jisq.js → riscv-CdWUuizJ.js} +0 -0
  518. /package/codemini-web/dist/assets/{riscv-Co5eiPIZ.js → riscv-QV-e36TY.js} +0 -0
  519. /package/codemini-web/dist/assets/{ron-CgTit1dG.js → ron-B-EB7ZBI.js} +0 -0
  520. /package/codemini-web/dist/assets/{ron-qyvgw9vu.js → ron-B9EiEQzE.js} +0 -0
  521. /package/codemini-web/dist/assets/{rose-pine-BDTwvYHf.js → rose-pine-B05wARW4.js} +0 -0
  522. /package/codemini-web/dist/assets/{rose-pine-R3f76h4_.js → rose-pine-Dxqc8n_1.js} +0 -0
  523. /package/codemini-web/dist/assets/{rose-pine-dawn-BS09rtpK.js → rose-pine-dawn-CSpx1lq4.js} +0 -0
  524. /package/codemini-web/dist/assets/{rose-pine-dawn-CAIk_wLV.js → rose-pine-dawn-pz_3O4ep.js} +0 -0
  525. /package/codemini-web/dist/assets/{rose-pine-moon-B4Q4DiPG.js → rose-pine-moon-B27idgkd.js} +0 -0
  526. /package/codemini-web/dist/assets/{rose-pine-moon-C5gdiznP.js → rose-pine-moon-DXyZaCQX.js} +0 -0
  527. /package/codemini-web/dist/assets/{rosmsg-C0tpzWlc.js → rosmsg-7fMni2bi.js} +0 -0
  528. /package/codemini-web/dist/assets/{rosmsg-Dy_ItAfo.js → rosmsg-CcBwQf5j.js} +0 -0
  529. /package/codemini-web/dist/assets/{rust-BWAfVMY4.js → rust-BHulpgn4.js} +0 -0
  530. /package/codemini-web/dist/assets/{rust-CNEVkiWF.js → rust-ppknoGus.js} +0 -0
  531. /package/codemini-web/dist/assets/{sass-D2nye32F.js → sass-Baw41att.js} +0 -0
  532. /package/codemini-web/dist/assets/{sass-MovLey2R.js → sass-DwJf1cGc.js} +0 -0
  533. /package/codemini-web/dist/assets/{scala-B8greAnE.js → scala-B_iky--A.js} +0 -0
  534. /package/codemini-web/dist/assets/{scala-C2w7y2mZ.js → scala-DtlnBhKt.js} +0 -0
  535. /package/codemini-web/dist/assets/{scheme-Bf85FNnm.js → scheme-B8EPXl9-.js} +0 -0
  536. /package/codemini-web/dist/assets/{scheme-Ci_aquns.js → scheme-DYQMayIi.js} +0 -0
  537. /package/codemini-web/dist/assets/{sdbl-D4tJqBiC.js → sdbl-BQ-WHv_b.js} +0 -0
  538. /package/codemini-web/dist/assets/{sdbl-DoQ_zDzo.js → sdbl-D0gXyfL6.js} +0 -0
  539. /package/codemini-web/dist/assets/{shellscript-CxhArCCJ.js → shellscript-B_ROtSU5.js} +0 -0
  540. /package/codemini-web/dist/assets/{shellscript-KUJZnuCi.js → shellscript-CPlx29kh.js} +0 -0
  541. /package/codemini-web/dist/assets/{slack-dark-BcN7KJ02.js → slack-dark-D27cdsBY.js} +0 -0
  542. /package/codemini-web/dist/assets/{slack-dark-BnOYKTBJ.js → slack-dark-D_l_kxUG.js} +0 -0
  543. /package/codemini-web/dist/assets/{slack-ochin-43udxtUg.js → slack-ochin-BE7dVjTN.js} +0 -0
  544. /package/codemini-web/dist/assets/{slack-ochin-D4iInQ9w.js → slack-ochin-BaRZ7cFo.js} +0 -0
  545. /package/codemini-web/dist/assets/{smalltalk-BwSireXb.js → smalltalk-B12I7SNP.js} +0 -0
  546. /package/codemini-web/dist/assets/{smalltalk-Mlf5-xbr.js → smalltalk-DRM3jr39.js} +0 -0
  547. /package/codemini-web/dist/assets/{snazzy-light-B45TfPsv.js → snazzy-light-BayTLer3.js} +0 -0
  548. /package/codemini-web/dist/assets/{snazzy-light-kw-pZEiM.js → snazzy-light-CooAwQFN.js} +0 -0
  549. /package/codemini-web/dist/assets/{solarized-dark-8yYW1wLs.js → solarized-dark-DJyTII3y.js} +0 -0
  550. /package/codemini-web/dist/assets/{solarized-dark-BDezFa9V.js → solarized-dark-Y31Htb59.js} +0 -0
  551. /package/codemini-web/dist/assets/{solarized-light-BY3Hr0Ud.js → solarized-light-AlAlWTlV.js} +0 -0
  552. /package/codemini-web/dist/assets/{solarized-light-CkoenhS2.js → solarized-light-B-u_T8hk.js} +0 -0
  553. /package/codemini-web/dist/assets/{solidity-CIUlntDs.js → solidity-CYAp_sJG.js} +0 -0
  554. /package/codemini-web/dist/assets/{solidity-DYHGECBw.js → solidity-DGySeR8E.js} +0 -0
  555. /package/codemini-web/dist/assets/{splunk-DOdklC0I.js → splunk-DIQhxWy6.js} +0 -0
  556. /package/codemini-web/dist/assets/{splunk-DueVPk5k.js → splunk-LsCTpuOP.js} +0 -0
  557. /package/codemini-web/dist/assets/{sql-CZAMrWdL.js → sql-BHYM5i23.js} +0 -0
  558. /package/codemini-web/dist/assets/{sql-Q6zkgi_w.js → sql-Cl5BmUDB.js} +0 -0
  559. /package/codemini-web/dist/assets/{ssh-config-DKIMErlp.js → ssh-config-CTKraw7w.js} +0 -0
  560. /package/codemini-web/dist/assets/{ssh-config-DwwFW7AS.js → ssh-config-QxQe7y21.js} +0 -0
  561. /package/codemini-web/dist/assets/{stylus-BO6mlOab.js → stylus-DZvi0832.js} +0 -0
  562. /package/codemini-web/dist/assets/{stylus-oqceM0yt.js → stylus-MJorGDSp.js} +0 -0
  563. /package/codemini-web/dist/assets/{swift-D9A08YU9.js → swift-BBBWvOdl.js} +0 -0
  564. /package/codemini-web/dist/assets/{swift-foA31xPc.js → swift-vEJN8-U8.js} +0 -0
  565. /package/codemini-web/dist/assets/{synthwave-84-B002ZU4p.js → synthwave-84-CU96aGm9.js} +0 -0
  566. /package/codemini-web/dist/assets/{synthwave-84-C69NN2j9.js → synthwave-84-Dq9WAwjJ.js} +0 -0
  567. /package/codemini-web/dist/assets/{system-verilog-CCSGcM60.js → system-verilog-BNegUpQT.js} +0 -0
  568. /package/codemini-web/dist/assets/{system-verilog-DjR3sN6w.js → system-verilog-Ddagu-BW.js} +0 -0
  569. /package/codemini-web/dist/assets/{systemd-BymS_eIJ.js → systemd-BxlmhgV_.js} +0 -0
  570. /package/codemini-web/dist/assets/{systemd-CJWuVSJU.js → systemd-k28iMR-m.js} +0 -0
  571. /package/codemini-web/dist/assets/{talonscript-CXqq0wX-.js → talonscript-DprpkXjP.js} +0 -0
  572. /package/codemini-web/dist/assets/{talonscript-Ccc0122j.js → talonscript-p-GlmLEL.js} +0 -0
  573. /package/codemini-web/dist/assets/{tasl-GVNf7pB7.js → tasl-BNm9EzXM.js} +0 -0
  574. /package/codemini-web/dist/assets/{tasl-o38sfjeU.js → tasl-CcWIX7df.js} +0 -0
  575. /package/codemini-web/dist/assets/{tcl-DISPE-5Q.js → tcl-BQwTCs7_.js} +0 -0
  576. /package/codemini-web/dist/assets/{tcl-DNlfRSl5.js → tcl-CDAGOvGJ.js} +0 -0
  577. /package/codemini-web/dist/assets/{terraform-DUK0FOOj.js → terraform-DLqNQanb.js} +0 -0
  578. /package/codemini-web/dist/assets/{terraform-V85Kewcz.js → terraform-DQhgYyF5.js} +0 -0
  579. /package/codemini-web/dist/assets/{tokyo-night-BLn5KNCP.js → tokyo-night-DxL5lL62.js} +0 -0
  580. /package/codemini-web/dist/assets/{tokyo-night-DWTtuXS3.js → tokyo-night-mZPbj36U.js} +0 -0
  581. /package/codemini-web/dist/assets/{toml-X5n3zjEH.js → toml-BncMjmx0.js} +0 -0
  582. /package/codemini-web/dist/assets/{toml-uEjeW8NC.js → toml-C7zZe7mY.js} +0 -0
  583. /package/codemini-web/dist/assets/{tsv-Bqs_rchc.js → tsv--yOlbuAc.js} +0 -0
  584. /package/codemini-web/dist/assets/{tsv-DjGwUc04.js → tsv-BYgjC2V4.js} +0 -0
  585. /package/codemini-web/dist/assets/{tsx-5O-M05V0.js → tsx-CQpoSLkt.js} +0 -0
  586. /package/codemini-web/dist/assets/{tsx-CfyUE2pW.js → tsx-_xvh4DFW.js} +0 -0
  587. /package/codemini-web/dist/assets/{turtle-BsUuoeVK.js → turtle-DO1RZ6-t.js} +0 -0
  588. /package/codemini-web/dist/assets/{turtle-PTxTluYn.js → turtle-ZCrKgE8E.js} +0 -0
  589. /package/codemini-web/dist/assets/{typescript-C6LvTgbf.js → typescript-BGytLZ-E.js} +0 -0
  590. /package/codemini-web/dist/assets/{typescript-hRweav8r.js → typescript-Bl_SUyNj.js} +0 -0
  591. /package/codemini-web/dist/assets/{typespec-CKEcF6Kw.js → typespec-9rD7KG94.js} +0 -0
  592. /package/codemini-web/dist/assets/{typespec-N7-U_jBZ.js → typespec-Bb7cO9Af.js} +0 -0
  593. /package/codemini-web/dist/assets/{typst-CPL77SDw.js → typst-CChrusEX.js} +0 -0
  594. /package/codemini-web/dist/assets/{typst-DSQh9HII.js → typst-DJ10KoY6.js} +0 -0
  595. /package/codemini-web/dist/assets/{v-CoJD3IPx.js → v-CutuAYrg.js} +0 -0
  596. /package/codemini-web/dist/assets/{v-obK6h_YW.js → v-DCfT4ti_.js} +0 -0
  597. /package/codemini-web/dist/assets/{vala-C42IfotU.js → vala-APnq2lEm.js} +0 -0
  598. /package/codemini-web/dist/assets/{vala-DXa9jSo-.js → vala-DJpFErrU.js} +0 -0
  599. /package/codemini-web/dist/assets/{vb-CVMKTK26.js → vb-2TNZABCr.js} +0 -0
  600. /package/codemini-web/dist/assets/{vb-DEPbtYq-.js → vb-DQuyY02M.js} +0 -0
  601. /package/codemini-web/dist/assets/{verilog-Bs-185hK.js → verilog-Bc6dGayD.js} +0 -0
  602. /package/codemini-web/dist/assets/{verilog-P63PhzSt.js → verilog-BuvxZrtu.js} +0 -0
  603. /package/codemini-web/dist/assets/{vesper-B7BneC5G.js → vesper-5CiKYnlC.js} +0 -0
  604. /package/codemini-web/dist/assets/{vesper-BGr95374.js → vesper-bM1AKkiO.js} +0 -0
  605. /package/codemini-web/dist/assets/{vhdl-2WwUdgX8.js → vhdl-2NYOzUvZ.js} +0 -0
  606. /package/codemini-web/dist/assets/{vhdl-CBukgB2Z.js → vhdl-pScFq2IF.js} +0 -0
  607. /package/codemini-web/dist/assets/{viml-C1cRY0x6.js → viml-AdCpKk5r.js} +0 -0
  608. /package/codemini-web/dist/assets/{viml-CGPGWJA6.js → viml-LZIbwXqf.js} +0 -0
  609. /package/codemini-web/dist/assets/{vitesse-black-D3_12zni.js → vitesse-black-BhKXUSxn.js} +0 -0
  610. /package/codemini-web/dist/assets/{vitesse-black-cI0k84-I.js → vitesse-black-DJ5O_Wf1.js} +0 -0
  611. /package/codemini-web/dist/assets/{vitesse-dark-B_iF7INE.js → vitesse-dark-23Naczwl.js} +0 -0
  612. /package/codemini-web/dist/assets/{vitesse-dark-SouM0FMW.js → vitesse-dark-BzqhRcAC.js} +0 -0
  613. /package/codemini-web/dist/assets/{vitesse-light-DbrrMtxY.js → vitesse-light-BDEFVzPq.js} +0 -0
  614. /package/codemini-web/dist/assets/{vitesse-light-WiCy6lDO.js → vitesse-light-C6rj90Ld.js} +0 -0
  615. /package/codemini-web/dist/assets/{vyper-BxVot6rR.js → vyper-CAC2wkEx.js} +0 -0
  616. /package/codemini-web/dist/assets/{vyper-DP_vqZO9.js → vyper-Cli2Hz-N.js} +0 -0
  617. /package/codemini-web/dist/assets/{wasm-Db7VBw0n.js → wasm-BYEYHoBh.js} +0 -0
  618. /package/codemini-web/dist/assets/{wasm-BNTPmfEI.js → wasm-C_1NoYKf.js} +0 -0
  619. /package/codemini-web/dist/assets/{wasm-DiIFv9DE.js → wasm-DmLFHHUn.js} +0 -0
  620. /package/codemini-web/dist/assets/{wasm-o5uYkU9G.js → wasm-JuQDwMf4.js} +0 -0
  621. /package/codemini-web/dist/assets/{wenyan-MnC4h24X.js → wenyan-BtC3dCkd.js} +0 -0
  622. /package/codemini-web/dist/assets/{wenyan-ZEcjghA1.js → wenyan-DZOq1WNp.js} +0 -0
  623. /package/codemini-web/dist/assets/{wgsl-BgfkHnVi.js → wgsl-BfhDoYq0.js} +0 -0
  624. /package/codemini-web/dist/assets/{wgsl-CdusuPLe.js → wgsl-sEaiSqkk.js} +0 -0
  625. /package/codemini-web/dist/assets/{wikitext-CBIB6hmW.js → wikitext-BBK9d3N8.js} +0 -0
  626. /package/codemini-web/dist/assets/{wikitext-DCOnP3yk.js → wikitext-BN0a9cMl.js} +0 -0
  627. /package/codemini-web/dist/assets/{wit-5UDEI7sp.js → wit-B5eB3VJ4.js} +0 -0
  628. /package/codemini-web/dist/assets/{wit-ZhUbVeze.js → wit-Drz0L2pK.js} +0 -0
  629. /package/codemini-web/dist/assets/{wolfram-HyMOyERF.js → wolfram-BjzpXDTC.js} +0 -0
  630. /package/codemini-web/dist/assets/{wolfram-vvgPlu2n.js → wolfram-hGtNh8mf.js} +0 -0
  631. /package/codemini-web/dist/assets/{yaml-C-G727Y6.js → yaml-45PVuYHO.js} +0 -0
  632. /package/codemini-web/dist/assets/{yaml-D_uvhEF7.js → yaml-CvJwaec9.js} +0 -0
  633. /package/codemini-web/dist/assets/{zenscript-BPjqX0BY.js → zenscript-ChrmAB59.js} +0 -0
  634. /package/codemini-web/dist/assets/{zenscript-C6ZuzgrL.js → zenscript-Dl5s7Kfy.js} +0 -0
  635. /package/codemini-web/dist/assets/{zig-Bd91oU8r.js → zig-BYKQoCIF.js} +0 -0
  636. /package/codemini-web/dist/assets/{zig-Do2h8XKj.js → zig-Dashm4F0.js} +0 -0
@@ -1,435 +0,0 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/highlighted-body-OFNGDK62-DaefZcrn.js","assets/rolldown-runtime-S-ySWqyJ.js","assets/angular-html-DlSp9HPG.js","assets/html-GfHBuoLs.js","assets/css-Dr0v2l-V.js","assets/javascript-Cx8CXBJR.js","assets/angular-ts-B29Ypg6B.js","assets/scss-YARKxu2i.js","assets/apl-BASZ7uB_.js","assets/json-CY14kIzN.js","assets/xml-DyJ3D9rW.js","assets/java-Ds1cyVrp.js","assets/astro-l-XABzN2.js","assets/postcss-DiNtjF5e.js","assets/tsx-5O-M05V0.js","assets/typescript-hRweav8r.js","assets/blade-B3_bxlV2.js","assets/html-derivative-ChSmSZXY.js","assets/sql-Q6zkgi_w.js","assets/bsl-D3u1l2dW.js","assets/sdbl-D4tJqBiC.js","assets/c-CgTSul4N.js","assets/cairo-CoQzhJ_o.js","assets/python-BhsI1K6K.js","assets/cobol-D_kesMA-.js","assets/coffee-DF15_0rk.js","assets/cpp-Cudwe5mG.js","assets/glsl-C4rvog10.js","assets/regexp-CK-1EP63.js","assets/crystal-DV9Nijjb.js","assets/shellscript-CxhArCCJ.js","assets/edge-BosfXYh1.js","assets/elixir-Dw_vsdUl.js","assets/elm-DPfFNNkG.js","assets/erb-DZuoCU5t.js","assets/ruby-CZgIYPlP.js","assets/graphql-Dg0Ewf8Q.js","assets/jsx-DmH5dwMF.js","assets/haml-DyIc_iO2.js","assets/lua-BeSXusec.js","assets/yaml-C-G727Y6.js","assets/erlang-CqHCISqs.js","assets/markdown-CbgVmtS5.js","assets/fortran-fixed-form-60ZQAHDk.js","assets/fortran-free-form-BVNtEstX.js","assets/fsharp-Ch5ZVinn.js","assets/gdresource-CqNLhJW1.js","assets/gdscript-D-FJCTl3.js","assets/gdshader-Czvzt8dR.js","assets/git-commit-CSWECvqq.js","assets/diff-RUsawely.js","assets/git-rebase-MUvuytPe.js","assets/glimmer-js-HDDEErW7.js","assets/glimmer-ts-Dq0_BflX.js","assets/hack-DjE76gIx.js","assets/handlebars-DQ4X08Zf.js","assets/http-DMTBhQm8.js","assets/hurl-XIpACwjS.js","assets/csv-CqpUSPyF.js","assets/hxml-PnV_FpS-.js","assets/haxe-1eAUKQ0B.js","assets/jinja-8ATGhxJO.js","assets/jison-CSsYnr7O.js","assets/julia-vjG00jwO.js","assets/r-BKej5r_k.js","assets/just-C7G3KFgN.js","assets/perl-DdF12AsD.js","assets/latex-D8-NgtPj.js","assets/tex-CxEkh6NI.js","assets/liquid-D2m0XXrV.js","assets/marko-DPnRthJQ.js","assets/less-BKjOc0Gl.js","assets/mdc-BLdFHYKv.js","assets/nextflow-c8YCPRRb.js","assets/nextflow-groovy-o7ZjyFmf.js","assets/nginx-u-hq5m-a.js","assets/nim-B5b6_jZr.js","assets/php-CyQZnE0l.js","assets/pug-HwoxZo9M.js","assets/qml-CysuucQ6.js","assets/razor-ZpEr_C9H.js","assets/csharp-Cqz84DXU.js","assets/rst-CjO4XFKz.js","assets/cmake-CdseusyP.js","assets/sas-DPGT0TjQ.js","assets/shaderlab-JWcsxey4.js","assets/hlsl-Df5oFh9i.js","assets/shellsession-DYmuifdt.js","assets/soy-7iHZG9Jz.js","assets/sparql-BGRSvFxd.js","assets/turtle-PTxTluYn.js","assets/stata-lXN9BRaz.js","assets/surrealql-l0SGzwOs.js","assets/svelte-BM89dRu0.js","assets/templ-D1GoDFsp.js","assets/go-D6k5URxL.js","assets/ts-tags-B88Nbzcl.js","assets/twig-B3Kws0Fb.js","assets/vue-CT36qSUr.js","assets/vue-html-bJyjqZnI.js","assets/vue-vine-BLqV15Pm.js","assets/stylus-oqceM0yt.js","assets/xsl-BOsdDgv_.js","assets/angular-html-CHsdtmkx.js","assets/html-B7kk5NVw.js","assets/css-z2ijrDWT.js","assets/javascript-WC6XFf_S.js","assets/angular-ts-JNDGGWj0.js","assets/scss-CaciJ0Gl.js","assets/apl-Byuv-g-O.js","assets/json-CmuSmrUv.js","assets/xml-BkdunjRC.js","assets/java-X0I2c5Az.js","assets/astro-CTzEugGW.js","assets/postcss-DrpvRGGG.js","assets/tsx-CfyUE2pW.js","assets/typescript-C6LvTgbf.js","assets/blade-Dt6km9YT.js","assets/html-derivative-Ba28nVB3.js","assets/sql-CZAMrWdL.js","assets/bsl-CPV9KqsG.js","assets/sdbl-DoQ_zDzo.js","assets/c-Bv0tI3pq.js","assets/cairo-CyiRuu7R.js","assets/python-DcnbpNOV.js","assets/cobol-DqhY5el-.js","assets/coffee-rY-gkJy7.js","assets/cpp-Bw-qV0P6.js","assets/glsl-C8VPaAWs.js","assets/regexp-da3KYCEG.js","assets/crystal-Bw1_1hFA.js","assets/shellscript-KUJZnuCi.js","assets/edge-r5NIe9Lp.js","assets/elixir-B04apOJS.js","assets/elm-Cezz_HNz.js","assets/erb-BNioEFKQ.js","assets/ruby-BOVYgV5O.js","assets/graphql-WZCiqIl-.js","assets/jsx-Bl4e1-KE.js","assets/haml-B8MRe8CS.js","assets/lua-BroxvhVt.js","assets/yaml-D_uvhEF7.js","assets/erlang-BC8wryba.js","assets/markdown-DMIvNSB1.js","assets/fortran-fixed-form-CyrImzNA.js","assets/fortran-free-form-CIAQqF5W.js","assets/fsharp-OCW_PZ4J.js","assets/gdresource-Cl3bohRI.js","assets/gdscript-B_XVILZe.js","assets/gdshader-BOrkFM_X.js","assets/git-commit-DJZpdBwB.js","assets/diff-D4HSRbRn.js","assets/git-rebase-BJE30GTP.js","assets/glimmer-js-Dn6vjgHP.js","assets/glimmer-ts-mq-Q_zEE.js","assets/hack-DeD259o6.js","assets/handlebars-GoJyzhp1.js","assets/http-Deln4Vyb.js","assets/hurl-CYSuhGkj.js","assets/csv-DUpZC5ZD.js","assets/hxml-BmF7ngDz.js","assets/haxe-Df79h8x1.js","assets/jinja-Dx5IcFSt.js","assets/jison-DuNOGix6.js","assets/julia-Cqc1ADyw.js","assets/r-B4lG5syH.js","assets/just-BlUYrdKb.js","assets/perl-BIcNvyL6.js","assets/latex-BEPTKliI.js","assets/tex-ezg8IclB.js","assets/liquid-BUh7yINm.js","assets/marko-Dm8xPXkG.js","assets/less-DgluPI4Z.js","assets/mdc-Dzipcsdb.js","assets/nextflow-BRiWOV-p.js","assets/nextflow-groovy-D6rYlJlL.js","assets/nginx-Da_Uewgc.js","assets/nim-CvgRYLO2.js","assets/php-BP-3TkW_.js","assets/pug-_XoIcKf3.js","assets/qml-DWxWu28U.js","assets/razor-DQ6FV4WL.js","assets/csharp-Ca2kU4Te.js","assets/rst-DDrWKQ9c.js","assets/cmake-CCC7tP43.js","assets/sas-DYNukvU9.js","assets/shaderlab-TbUUdmUb.js","assets/hlsl-CckLjo_3.js","assets/shellsession-BeWGuVoR.js","assets/soy-h0dQKbQs.js","assets/sparql-DIFvSn1n.js","assets/turtle-BsUuoeVK.js","assets/stata-C5mLa_ER.js","assets/surrealql-DyoUfV6n.js","assets/svelte-CijnRGul.js","assets/templ-CNjJl440.js","assets/go-iV8pwUYW.js","assets/ts-tags-DV6nguf9.js","assets/twig-BROkIZLg.js","assets/vue-BUQP_8VF.js","assets/vue-html-Bx2Sgp8M.js","assets/vue-vine-RK3AHrhp.js","assets/stylus-BO6mlOab.js","assets/xsl-C66i1pDH.js"])))=>i.map(i=>d[i]);
2
- import{n as e,r as t,t as n}from"./rolldown-runtime-S-ySWqyJ.js";(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),e.crossOrigin===`use-credentials`?t.credentials=`include`:e.crossOrigin===`anonymous`?t.credentials=`omit`:t.credentials=`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var r=n((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 D(e,t){return E(e.type,t,e.props)}function O(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function ee(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var te=/\/+/g;function k(e,t){return typeof e==`object`&&e&&e.key!=null?ee(``+e.key):t.toString(36)}function A(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 j(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,j(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+k(e,0):a,S(o)?(i=``,c!=null&&(i=c.replace(te,`$&/`)+`/`),j(o,r,i,``,function(e){return e})):o!=null&&(O(o)&&(o=D(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+k(a,u),c+=j(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+k(a,u++),c+=j(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return j(A(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 M(e,t,n){if(e==null)return e;var r=[],i=0;return j(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function ne(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 N=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)},P={map:M,forEach:function(e,t,n){M(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return M(e,function(){t++}),t},toArray:function(e){return M(e,function(e){return e})||[]},only:function(e){if(!O(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=P,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=O,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:ne}},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,N)}catch(e){N(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.5`})),i=n(((e,t)=>{t.exports=r()})),a=n((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,O());else{var t=n(l);t!==null&&k(x,t.startTime-e)}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-T<w)}function D(){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&&k(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var ee=new MessageChannel,te=ee.port2;ee.port1.onmessage=D,O=function(){te.postMessage(null)}}else O=function(){_(D,0)};function k(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,k(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,O()))),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}}}})),o=n(((e,t)=>{t.exports=a()})),s=n((e=>{var t=i();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 a={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},o=Symbol.for(`react.portal`);function s(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:o,key:r==null?null:``+r,children:e,containerInfo:t,implementation:n}}var c=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function l(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=a,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 s(e,t,null,r)},e.flushSync=function(e){var t=c.T,n=a.p;try{if(c.T=null,a.p=2,e)return e()}finally{c.T=t,a.p=n,a.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,a.d.C(e,t))},e.prefetchDNS=function(e){typeof e==`string`&&a.d.D(e)},e.preinit=function(e,t){if(typeof e==`string`&&t&&typeof t.as==`string`){var n=t.as,r=l(n,t.crossOrigin),i=typeof t.integrity==`string`?t.integrity:void 0,o=typeof t.fetchPriority==`string`?t.fetchPriority:void 0;n===`style`?a.d.S(e,typeof t.precedence==`string`?t.precedence:void 0,{crossOrigin:r,integrity:i,fetchPriority:o}):n===`script`&&a.d.X(e,{crossOrigin:r,integrity:i,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=l(t.as,t.crossOrigin);a.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??a.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=l(n,t.crossOrigin);a.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=l(t.as,t.crossOrigin);a.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 a.d.m(e)},e.requestFormReset=function(e){a.d.r(e)},e.unstable_batchedUpdates=function(e,t){return e(t)},e.useFormState=function(e,t,n){return c.H.useFormState(e,t,n)},e.useFormStatus=function(){return c.H.useHostTransitionStatus()},e.version=`19.2.5`})),c=n(((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=s()})),l=n((e=>{var t=o(),n=i(),r=c();function a(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 s(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function l(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 u(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 d(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 f(e){if(l(e)!==e)throw Error(a(188))}function p(e){var t=e.alternate;if(!t){if(t=l(e),t===null)throw Error(a(188));return t===e?e:null}for(var n=e,r=t;;){var i=n.return;if(i===null)break;var o=i.alternate;if(o===null){if(r=i.return,r!==null){n=r;continue}break}if(i.child===o.child){for(o=i.child;o;){if(o===n)return f(i),e;if(o===r)return f(i),t;o=o.sibling}throw Error(a(188))}if(n.return!==r.return)n=i,r=o;else{for(var s=!1,c=i.child;c;){if(c===n){s=!0,n=i,r=o;break}if(c===r){s=!0,r=i,n=o;break}c=c.sibling}if(!s){for(c=o.child;c;){if(c===n){s=!0,n=o,r=i;break}if(c===r){s=!0,r=o,n=i;break}c=c.sibling}if(!s)throw Error(a(189))}}if(n.alternate!==r)throw Error(a(190))}if(n.tag!==3)throw Error(a(188));return n.stateNode.current===n?e:t}function m(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=m(e),t!==null)return t;e=e.sibling}return null}var h=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`),D=Symbol.for(`react.memo`),O=Symbol.for(`react.lazy`),ee=Symbol.for(`react.activity`),te=Symbol.for(`react.memo_cache_sentinel`),k=Symbol.iterator;function A(e){return typeof e!=`object`||!e?null:(e=k&&e[k]||e[`@@iterator`],typeof e==`function`?e:null)}var j=Symbol.for(`react.client.reference`);function M(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===j?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 ee: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 D:return t=e.displayName||null,t===null?M(e.type)||`Memo`:t;case O:t=e._payload,e=e._init;try{return M(e(t))}catch{}}return null}var ne=Array.isArray,N=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,P=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,re={pending:!1,data:null,method:null,action:null},ie=[],ae=-1;function oe(e){return{current:e}}function F(e){0>ae||(e.current=ie[ae],ie[ae]=null,ae--)}function I(e,t){ae++,ie[ae]=e.current,e.current=t}var se=oe(null),ce=oe(null),le=oe(null),ue=oe(null);function de(e,t){switch(I(le,t),I(ce,e),I(se,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?$d(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=$d(t),e=ef(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}F(se),I(se,e)}function fe(){F(se),F(ce),F(le)}function pe(e){e.memoizedState!==null&&I(ue,e);var t=se.current,n=ef(t,e.type);t!==n&&(I(ce,e),I(se,n))}function me(e){ce.current===e&&(F(se),F(ce)),ue.current===e&&(F(ue),lp._currentValue=re)}var he,ge;function _e(e){if(he===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);he=t&&t[1]||``,ge=-1<e.stack.indexOf(`
3
- at`)?` (<anonymous>)`:-1<e.stack.indexOf(`@`)?`@unknown:0:0`:``}return`
4
- `+he+e+ge}var ve=!1;function ye(e,t){if(!e||ve)return``;ve=!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(`
5
- `),l=s.split(`
6
- `);for(i=r=0;r<c.length&&!c[r].includes(`DetermineComponentFrameRoot`);)r++;for(;i<l.length&&!l[i].includes(`DetermineComponentFrameRoot`);)i++;if(r===c.length||i===l.length)for(r=c.length-1,i=l.length-1;1<=r&&0<=i&&c[r]!==l[i];)i--;for(;1<=r&&0<=i;r--,i--)if(c[r]!==l[i]){if(r!==1||i!==1)do if(r--,i--,0>i||c[r]!==l[i]){var u=`
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{ve=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?_e(n):``}function be(e,t){switch(e.tag){case 26:case 27:case 5:return _e(e.type);case 16:return _e(`Lazy`);case 13:return e.child!==t&&t!==null?_e(`Suspense Fallback`):_e(`Suspense`);case 19:return _e(`SuspenseList`);case 0:case 15:return ye(e.type,!1);case 11:return ye(e.type.render,!1);case 1:return ye(e.type,!0);case 31:return _e(`Activity`);default:return``}}function xe(e){try{var t=``,n=null;do t+=be(e,n),n=e,e=e.return;while(e);return t}catch(e){return`
8
- Error generating stack: `+e.message+`
9
- `+e.stack}}var Se=Object.prototype.hasOwnProperty,Ce=t.unstable_scheduleCallback,we=t.unstable_cancelCallback,Te=t.unstable_shouldYield,Ee=t.unstable_requestPaint,De=t.unstable_now,Oe=t.unstable_getCurrentPriorityLevel,ke=t.unstable_ImmediatePriority,Ae=t.unstable_UserBlockingPriority,je=t.unstable_NormalPriority,Me=t.unstable_LowPriority,Ne=t.unstable_IdlePriority,Pe=t.log,Fe=t.unstable_setDisableYieldValue,Ie=null,Le=null;function Re(e){if(typeof Pe==`function`&&Fe(e),Le&&typeof Le.setStrictMode==`function`)try{Le.setStrictMode(Ie,e)}catch{}}var ze=Math.clz32?Math.clz32:He,Be=Math.log,Ve=Math.LN2;function He(e){return e>>>=0,e===0?32:31-(Be(e)/Ve|0)|0}var Ue=256,We=262144,Ge=4194304;function Ke(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=Ke(n))):i=Ke(o):i=Ke(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=Ke(n))):i=Ke(o)):i=Ke(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 Je(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Ye(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 Xe(){var e=Ge;return Ge<<=1,!(Ge&62914560)&&(Ge=4194304),e}function Ze(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Qe(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function $e(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-ze(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&&et(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function et(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-ze(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function tt(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-ze(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function nt(e,t){var n=t&-t;return n=n&42?1:rt(n),(n&(e.suspendedLanes|t))===0?n:0}function rt(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 it(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function at(){var e=P.p;return e===0?(e=window.event,e===void 0?32:Tp(e.type)):e}function ot(e,t){var n=P.p;try{return P.p=e,t()}finally{P.p=n}}var st=Math.random().toString(36).slice(2),ct=`__reactFiber$`+st,lt=`__reactProps$`+st,ut=`__reactContainer$`+st,dt=`__reactEvents$`+st,ft=`__reactListeners$`+st,pt=`__reactHandles$`+st,mt=`__reactResources$`+st,ht=`__reactMarker$`+st;function gt(e){delete e[ct],delete e[lt],delete e[dt],delete e[ft],delete e[pt]}function _t(e){var t=e[ct];if(t)return t;for(var n=e.parentNode;n;){if(t=n[ut]||n[ct]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Cf(e);e!==null;){if(n=e[ct])return n;e=Cf(e)}return t}e=n,n=e.parentNode}return null}function vt(e){if(e=e[ct]||e[ut]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function yt(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(a(33))}function bt(e){var t=e[mt];return t||=e[mt]={hoistableStyles:new Map,hoistableScripts:new Map},t}function xt(e){e[ht]=!0}var St=new Set,Ct={};function wt(e,t){Tt(e,t),Tt(e+`Capture`,t)}function Tt(e,t){for(Ct[e]=t,e=0;e<t.length;e++)St.add(t[e])}var Et=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]*$`),Dt={},Ot={};function kt(e){return Se.call(Ot,e)?!0:Se.call(Dt,e)?!1:Et.test(e)?Ot[e]=!0:(Dt[e]=!0,!1)}function At(e,t,n){if(kt(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 jt(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 Mt(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 Nt(e){switch(typeof e){case`bigint`:case`boolean`:case`number`:case`string`:case`undefined`:return e;case`object`:return e;default:return``}}function Pt(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()===`input`&&(t===`checkbox`||t===`radio`)}function Ft(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 It(e){if(!e._valueTracker){var t=Pt(e)?`checked`:`value`;e._valueTracker=Ft(e,t,``+e[t])}}function Lt(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r=``;return e&&(r=Pt(e)?e.checked?`true`:`false`:e.value),e=r,e===n?!1:(t.setValue(e),!0)}function Rt(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 zt=/[\n"\\]/g;function Bt(e){return e.replace(zt,function(e){return`\\`+e.charCodeAt(0).toString(16)+` `})}function Vt(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=``+Nt(t)):e.value!==``+Nt(t)&&(e.value=``+Nt(t)),t==null?n==null?r!=null&&e.removeAttribute(`value`):Ut(e,o,Nt(n)):Ut(e,o,Nt(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=``+Nt(s):e.removeAttribute(`name`)}function Ht(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)){It(e);return}n=n==null?``:``+Nt(n),t=t==null?n:``+Nt(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),It(e)}function Ut(e,t,n){t===`number`&&Rt(e.ownerDocument)===e||e.defaultValue===``+n||(e.defaultValue=``+n)}function Wt(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=``+Nt(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 Gt(e,t,n){if(t!=null&&(t=``+Nt(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n==null?``:``+Nt(n)}function Kt(e,t,n,r){if(t==null){if(r!=null){if(n!=null)throw Error(a(92));if(ne(r)){if(1<r.length)throw Error(a(93));r=r[0]}n=r}n??=``,t=n}n=Nt(t),e.defaultValue=n,r=e.textContent,r===n&&r!==``&&r!==null&&(e.value=r),It(e)}function qt(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Jt=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 Yt(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||Jt.has(t)?t===`float`?e.cssFloat=n:e[t]=(``+n).trim():e[t]=n+`px`}function Xt(e,t,n){if(t!=null&&typeof t!=`object`)throw Error(a(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 i in t)r=t[i],t.hasOwnProperty(i)&&n[i]!==r&&Yt(e,i,r)}else for(var o in t)t.hasOwnProperty(o)&&Yt(e,o,t[o])}function Zt(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 Qt=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`]]),$t=/^[\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 en(e){return $t.test(``+e)?`javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')`:e}function tn(){}var nn=null;function rn(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var an=null,on=null;function sn(e){var t=vt(e);if(t&&(e=t.stateNode)){var n=e[lt]||null;a:switch(e=t.stateNode,t.type){case`input`:if(Vt(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="`+Bt(``+t)+`"][type="radio"]`),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var i=r[lt]||null;if(!i)throw Error(a(90));Vt(r,i.value,i.defaultValue,i.defaultValue,i.checked,i.defaultChecked,i.type,i.name)}}for(t=0;t<n.length;t++)r=n[t],r.form===e.form&&Lt(r)}break a;case`textarea`:Gt(e,n.value,n.defaultValue);break a;case`select`:t=n.value,t!=null&&Wt(e,!!n.multiple,t,!1)}}}var cn=!1;function ln(e,t,n){if(cn)return e(t,n);cn=!0;try{return e(t)}finally{if(cn=!1,(an!==null||on!==null)&&(Pu(),an&&(t=an,e=on,on=an=null,sn(t),e)))for(t=0;t<e.length;t++)sn(e[t])}}function un(e,t){var n=e.stateNode;if(n===null)return null;var r=n[lt]||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(a(231,t,typeof n));return n}var dn=!(typeof window>`u`||window.document===void 0||window.document.createElement===void 0),fn=!1;if(dn)try{var pn={};Object.defineProperty(pn,`passive`,{get:function(){fn=!0}}),window.addEventListener(`test`,pn,pn),window.removeEventListener(`test`,pn,pn)}catch{fn=!1}var mn=null,hn=null,gn=null;function _n(){if(gn)return gn;var e,t=hn,n=t.length,r,i=`value`in mn?mn.value:mn.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 gn=i.slice(e,1<r?1-r:void 0)}function vn(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 yn(){return!0}function bn(){return!1}function xn(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)?yn:bn,this.isPropagationStopped=bn,this}return h(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=yn)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!=`unknown`&&(e.cancelBubble=!0),this.isPropagationStopped=yn)},persist:function(){},isPersistent:yn}),t}var Sn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Cn=xn(Sn),wn=h({},Sn,{view:0,detail:0}),Tn=xn(wn),En,Dn,On,kn=h({},wn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Bn,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!==On&&(On&&e.type===`mousemove`?(En=e.screenX-On.screenX,Dn=e.screenY-On.screenY):Dn=En=0,On=e),En)},movementY:function(e){return`movementY`in e?e.movementY:Dn}}),An=xn(kn),jn=xn(h({},kn,{dataTransfer:0})),Mn=xn(h({},wn,{relatedTarget:0})),Nn=xn(h({},Sn,{animationName:0,elapsedTime:0,pseudoElement:0})),Pn=xn(h({},Sn,{clipboardData:function(e){return`clipboardData`in e?e.clipboardData:window.clipboardData}})),Fn=xn(h({},Sn,{data:0})),In={Esc:`Escape`,Spacebar:` `,Left:`ArrowLeft`,Up:`ArrowUp`,Right:`ArrowRight`,Down:`ArrowDown`,Del:`Delete`,Win:`OS`,Menu:`ContextMenu`,Apps:`ContextMenu`,Scroll:`ScrollLock`,MozPrintableKey:`Unidentified`},Ln={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`},Rn={Alt:`altKey`,Control:`ctrlKey`,Meta:`metaKey`,Shift:`shiftKey`};function zn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Rn[e])?!!t[e]:!1}function Bn(){return zn}var Vn=xn(h({},wn,{key:function(e){if(e.key){var t=In[e.key]||e.key;if(t!==`Unidentified`)return t}return e.type===`keypress`?(e=vn(e),e===13?`Enter`:String.fromCharCode(e)):e.type===`keydown`||e.type===`keyup`?Ln[e.keyCode]||`Unidentified`:``},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Bn,charCode:function(e){return e.type===`keypress`?vn(e):0},keyCode:function(e){return e.type===`keydown`||e.type===`keyup`?e.keyCode:0},which:function(e){return e.type===`keypress`?vn(e):e.type===`keydown`||e.type===`keyup`?e.keyCode:0}})),Hn=xn(h({},kn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),Un=xn(h({},wn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Bn})),Wn=xn(h({},Sn,{propertyName:0,elapsedTime:0,pseudoElement:0})),Gn=xn(h({},kn,{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})),Kn=xn(h({},Sn,{newState:0,oldState:0})),qn=[9,13,27,32],Jn=dn&&`CompositionEvent`in window,Yn=null;dn&&`documentMode`in document&&(Yn=document.documentMode);var Xn=dn&&`TextEvent`in window&&!Yn,Zn=dn&&(!Jn||Yn&&8<Yn&&11>=Yn),Qn=` `,$n=!1;function er(e,t){switch(e){case`keyup`:return qn.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function tr(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var nr=!1;function rr(e,t){switch(e){case`compositionend`:return tr(t);case`keypress`:return t.which===32?($n=!0,Qn):null;case`textInput`:return e=t.data,e===Qn&&$n?null:e;default:return null}}function ir(e,t){if(nr)return e===`compositionend`||!Jn&&er(e,t)?(e=_n(),gn=hn=mn=null,nr=!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 Zn&&t.locale!==`ko`?null:t.data;default:return null}}var ar={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 or(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t===`input`?!!ar[e.type]:t===`textarea`}function sr(e,t,n,r){an?on?on.push(r):on=[r]:an=r,t=Ld(t,`onChange`),0<t.length&&(n=new Cn(`onChange`,`change`,null,n,r),e.push({event:n,listeners:t}))}var cr=null,lr=null;function ur(e){kd(e,0)}function dr(e){if(Lt(yt(e)))return e}function fr(e,t){if(e===`change`)return t}var pr=!1;if(dn){var mr;if(dn){var hr=`oninput`in document;if(!hr){var gr=document.createElement(`div`);gr.setAttribute(`oninput`,`return;`),hr=typeof gr.oninput==`function`}mr=hr}else mr=!1;pr=mr&&(!document.documentMode||9<document.documentMode)}function _r(){cr&&(cr.detachEvent(`onpropertychange`,vr),lr=cr=null)}function vr(e){if(e.propertyName===`value`&&dr(lr)){var t=[];sr(t,lr,e,rn(e)),ln(ur,t)}}function yr(e,t,n){e===`focusin`?(_r(),cr=t,lr=n,cr.attachEvent(`onpropertychange`,vr)):e===`focusout`&&_r()}function br(e){if(e===`selectionchange`||e===`keyup`||e===`keydown`)return dr(lr)}function xr(e,t){if(e===`click`)return dr(t)}function Sr(e,t){if(e===`input`||e===`change`)return dr(t)}function Cr(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var wr=typeof Object.is==`function`?Object.is:Cr;function Tr(e,t){if(wr(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(!Se.call(t,i)||!wr(e[i],t[i]))return!1}return!0}function Er(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Dr(e,t){var n=Er(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=Er(n)}}function Or(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Or(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function kr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Rt(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=Rt(e.document)}return t}function Ar(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 jr=dn&&`documentMode`in document&&11>=document.documentMode,Mr=null,Nr=null,Pr=null,Fr=!1;function Ir(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Fr||Mr==null||Mr!==Rt(r)||(r=Mr,`selectionStart`in r&&Ar(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}),Pr&&Tr(Pr,r)||(Pr=r,r=Ld(Nr,`onSelect`),0<r.length&&(t=new Cn(`onSelect`,`select`,null,t,n),e.push({event:t,listeners:r}),t.target=Mr)))}function Lr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit`+e]=`webkit`+t,n[`Moz`+e]=`moz`+t,n}var Rr={animationend:Lr(`Animation`,`AnimationEnd`),animationiteration:Lr(`Animation`,`AnimationIteration`),animationstart:Lr(`Animation`,`AnimationStart`),transitionrun:Lr(`Transition`,`TransitionRun`),transitionstart:Lr(`Transition`,`TransitionStart`),transitioncancel:Lr(`Transition`,`TransitionCancel`),transitionend:Lr(`Transition`,`TransitionEnd`)},zr={},Br={};dn&&(Br=document.createElement(`div`).style,`AnimationEvent`in window||(delete Rr.animationend.animation,delete Rr.animationiteration.animation,delete Rr.animationstart.animation),`TransitionEvent`in window||delete Rr.transitionend.transition);function Vr(e){if(zr[e])return zr[e];if(!Rr[e])return e;var t=Rr[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Br)return zr[e]=t[n];return e}var Hr=Vr(`animationend`),Ur=Vr(`animationiteration`),Wr=Vr(`animationstart`),Gr=Vr(`transitionrun`),Kr=Vr(`transitionstart`),qr=Vr(`transitioncancel`),Jr=Vr(`transitionend`),Yr=new Map,Xr=`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(` `);Xr.push(`scrollEnd`);function Zr(e,t){Yr.set(e,t),wt(t,[e])}var Qr=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)},$r=[],ei=0,ti=0;function ni(){for(var e=ei,t=ti=ei=0;t<e;){var n=$r[t];$r[t++]=null;var r=$r[t];$r[t++]=null;var i=$r[t];$r[t++]=null;var a=$r[t];if($r[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&&oi(n,i,a)}}function ri(e,t,n,r){$r[ei++]=e,$r[ei++]=t,$r[ei++]=n,$r[ei++]=r,ti|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function ii(e,t,n,r){return ri(e,t,n,r),si(e)}function ai(e,t){return ri(e,null,null,t),si(e)}function oi(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-ze(n),e=a.hiddenUpdates,r=e[i],r===null?e[i]=[t]:r.push(t),t.lane=n|536870912),a):null}function si(e){if(50<Tu)throw Tu=0,Eu=null,Error(a(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var ci={};function li(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 ui(e,t,n,r){return new li(e,t,n,r)}function di(e){return e=e.prototype,!(!e||!e.isReactComponent)}function fi(e,t){var n=e.alternate;return n===null?(n=ui(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 pi(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 mi(e,t,n,r,i,o){var s=0;if(r=e,typeof e==`function`)di(e)&&(s=1);else if(typeof e==`string`)s=tp(e,n,se.current)?26:e===`html`||e===`head`||e===`body`?27:5;else a:switch(e){case ee:return e=ui(31,n,t,i),e.elementType=ee,e.lanes=o,e;case y:return hi(n.children,i,o,t);case b:s=8,i|=24;break;case x:return e=ui(12,n,t,i|2),e.elementType=x,e.lanes=o,e;case T:return e=ui(13,n,t,i),e.elementType=T,e.lanes=o,e;case E:return e=ui(19,n,t,i),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 D:s=14;break a;case O:s=16,r=null;break a}s=29,n=Error(a(130,e===null?`null`:typeof e,``)),r=null}return t=ui(s,n,t,i),t.elementType=e,t.type=r,t.lanes=o,t}function hi(e,t,n,r){return e=ui(7,e,r,t),e.lanes=n,e}function gi(e,t,n){return e=ui(6,e,null,t),e.lanes=n,e}function _i(e){var t=ui(18,null,null,0);return t.stateNode=e,t}function vi(e,t,n){return t=ui(4,e.children===null?[]:e.children,e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var yi=new WeakMap;function bi(e,t){if(typeof e==`object`&&e){var n=yi.get(e);return n===void 0?(t={value:e,source:t,stack:xe(t)},yi.set(e,t),t):n}return{value:e,source:t,stack:xe(t)}}var xi=[],Si=0,Ci=null,wi=0,Ti=[],Ei=0,Di=null,Oi=1,ki=``;function Ai(e,t){xi[Si++]=wi,xi[Si++]=Ci,Ci=e,wi=t}function ji(e,t,n){Ti[Ei++]=Oi,Ti[Ei++]=ki,Ti[Ei++]=Di,Di=e;var r=Oi;e=ki;var i=32-ze(r)-1;r&=~(1<<i),n+=1;var a=32-ze(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,Oi=1<<32-ze(t)+i|n<<i|r,ki=a+e}else Oi=1<<a|n<<i|r,ki=e}function Mi(e){e.return!==null&&(Ai(e,1),ji(e,1,0))}function Ni(e){for(;e===Ci;)Ci=xi[--Si],xi[Si]=null,wi=xi[--Si],xi[Si]=null;for(;e===Di;)Di=Ti[--Ei],Ti[Ei]=null,ki=Ti[--Ei],Ti[Ei]=null,Oi=Ti[--Ei],Ti[Ei]=null}function Pi(e,t){Ti[Ei++]=Oi,Ti[Ei++]=ki,Ti[Ei++]=Di,Oi=t.id,ki=t.overflow,Di=e}var Fi=null,Ii=null,Li=!1,Ri=null,zi=!1,Bi=Error(a(519));function Vi(e){throw qi(bi(Error(a(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),Bi}function Hi(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[ct]=e,t[lt]=r,n){case`dialog`:Ad(`cancel`,t),Ad(`close`,t);break;case`iframe`:case`object`:case`embed`:Ad(`load`,t);break;case`video`:case`audio`:for(n=0;n<Dd.length;n++)Ad(Dd[n],t);break;case`source`:Ad(`error`,t);break;case`img`:case`image`:case`link`:Ad(`error`,t),Ad(`load`,t);break;case`details`:Ad(`toggle`,t);break;case`input`:Ad(`invalid`,t),Ht(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case`select`:Ad(`invalid`,t);break;case`textarea`:Ad(`invalid`,t),Kt(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||Ud(t.textContent,n)?(r.popover!=null&&(Ad(`beforetoggle`,t),Ad(`toggle`,t)),r.onScroll!=null&&Ad(`scroll`,t),r.onScrollEnd!=null&&Ad(`scrollend`,t),r.onClick!=null&&(t.onclick=tn),t=!0):t=!1,t||Vi(e,!0)}function Ui(e){for(Fi=e.return;Fi;)switch(Fi.tag){case 5:case 31:case 13:zi=!1;return;case 27:case 3:zi=!0;return;default:Fi=Fi.return}}function Wi(e){if(e!==Fi)return!1;if(!Li)return Ui(e),Li=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=!(n!==`form`&&n!==`button`)||tf(e.type,e.memoizedProps)),n=!n),n&&Ii&&Vi(e),Ui(e),t===13){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(a(317));Ii=Sf(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(a(317));Ii=Sf(e)}else t===27?(t=Ii,uf(e.type)?(e=xf,xf=null,Ii=e):Ii=t):Ii=Fi?bf(e.stateNode.nextSibling):null;return!0}function Gi(){Ii=Fi=null,Li=!1}function Ki(){var e=Ri;return e!==null&&(du===null?du=e:du.push.apply(du,e),Ri=null),e}function qi(e){Ri===null?Ri=[e]:Ri.push(e)}var Ji=oe(null),Yi=null,Xi=null;function Zi(e,t,n){I(Ji,t._currentValue),t._currentValue=n}function Qi(e){e._currentValue=Ji.current,F(Ji)}function $i(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 ea(e,t,n,r){var i=e.child;for(i!==null&&(i.return=e);i!==null;){var o=i.dependencies;if(o!==null){var s=i.child;o=o.firstContext;a:for(;o!==null;){var c=o;o=i;for(var l=0;l<t.length;l++)if(c.context===t[l]){o.lanes|=n,c=o.alternate,c!==null&&(c.lanes|=n),$i(o.return,n,e),r||(s=null);break a}o=c.next}}else if(i.tag===18){if(s=i.return,s===null)throw Error(a(341));s.lanes|=n,o=s.alternate,o!==null&&(o.lanes|=n),$i(s,n,e),s=null}else s=i.child;if(s!==null)s.return=i;else for(s=i;s!==null;){if(s===e){s=null;break}if(i=s.sibling,i!==null){i.return=s.return,s=i;break}s=s.return}i=s}}function ta(e,t,n,r){e=null;for(var i=t,o=!1;i!==null;){if(!o){if(i.flags&524288)o=!0;else if(i.flags&262144)break}if(i.tag===10){var s=i.alternate;if(s===null)throw Error(a(387));if(s=s.memoizedProps,s!==null){var c=i.type;wr(i.pendingProps.value,s.value)||(e===null?e=[c]:e.push(c))}}else if(i===ue.current){if(s=i.alternate,s===null)throw Error(a(387));s.memoizedState.memoizedState!==i.memoizedState.memoizedState&&(e===null?e=[lp]:e.push(lp))}i=i.return}e!==null&&ea(t,e,n,r),t.flags|=262144}function na(e){for(e=e.firstContext;e!==null;){if(!wr(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function ra(e){Yi=e,Xi=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function ia(e){return oa(Yi,e)}function aa(e,t){return Yi===null&&ra(e),oa(e,t)}function oa(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},Xi===null){if(e===null)throw Error(a(308));Xi=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Xi=Xi.next=t;return n}var sa=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()})}},ca=t.unstable_scheduleCallback,la=t.unstable_NormalPriority,ua={$$typeof:C,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function da(){return{controller:new sa,data:new Map,refCount:0}}function fa(e){e.refCount--,e.refCount===0&&ca(la,function(){e.controller.abort()})}var pa=null,ma=0,ha=0,ga=null;function _a(e,t){if(pa===null){var n=pa=[];ma=0,ha=Sd(),ga={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return ma++,t.then(va,va),t}function va(){if(--ma===0&&pa!==null){ga!==null&&(ga.status=`fulfilled`);var e=pa;pa=null,ha=0,ga=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function ya(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 ba=N.S;N.S=function(e,t){mu=De(),typeof t==`object`&&t&&typeof t.then==`function`&&_a(e,t),ba!==null&&ba(e,t)};var xa=oe(null);function Sa(){var e=xa.current;return e===null?Yl.pooledCache:e}function Ca(e,t){t===null?I(xa,xa.current):I(xa,t.pool)}function wa(){var e=Sa();return e===null?null:{parent:ua._currentValue,pool:e}}var Ta=Error(a(460)),Ea=Error(a(474)),Da=Error(a(542)),Oa={then:function(){}};function ka(e){return e=e.status,e===`fulfilled`||e===`rejected`}function Aa(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(tn,tn),t=n),t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Pa(e),e;default:if(typeof t.status==`string`)t.then(tn,tn);else{if(e=Yl,e!==null&&100<e.shellSuspendCounter)throw Error(a(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,Pa(e),e}throw Ma=t,Ta}}function ja(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(Ma=e,Ta):e}}var Ma=null;function Na(){if(Ma===null)throw Error(a(459));var e=Ma;return Ma=null,e}function Pa(e){if(e===Ta||e===Da)throw Error(a(483))}var Fa=null,Ia=0;function La(e){var t=Ia;return Ia+=1,Fa===null&&(Fa=[]),Aa(Fa,e,t)}function Ra(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function za(e,t){throw t.$$typeof===g?Error(a(525)):(e=Object.prototype.toString.call(t),Error(a(31,e===`[object Object]`?`object with keys {`+Object.keys(t).join(`, `)+`}`:e)))}function Ba(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 i(e,t){return e=fi(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=gi(n,e.mode,r),t.return=e,t):(t=i(t,n),t.return=e,t)}function l(e,t,n,r){var a=n.type;return a===y?d(e,t,n.props.children,r,n.key):t!==null&&(t.elementType===a||typeof a==`object`&&a&&a.$$typeof===O&&ja(a)===t.type)?(t=i(t,n.props),Ra(t,n),t.return=e,t):(t=mi(n.type,n.key,n.props,null,e.mode,r),Ra(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=vi(n,e.mode,r),t.return=e,t):(t=i(t,n.children||[]),t.return=e,t)}function d(e,t,n,r,a){return t===null||t.tag!==7?(t=hi(n,e.mode,r,a),t.return=e,t):(t=i(t,n),t.return=e,t)}function f(e,t,n){if(typeof t==`string`&&t!==``||typeof t==`number`||typeof t==`bigint`)return t=gi(``+t,e.mode,n),t.return=e,t;if(typeof t==`object`&&t){switch(t.$$typeof){case _:return n=mi(t.type,t.key,t.props,null,e.mode,n),Ra(n,t),n.return=e,n;case v:return t=vi(t,e.mode,n),t.return=e,t;case O:return t=ja(t),f(e,t,n)}if(ne(t)||A(t))return t=hi(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return f(e,La(t),n);if(t.$$typeof===C)return f(e,aa(e,t),n);za(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 O:return n=ja(n),p(e,t,n,r)}if(ne(n)||A(n))return i===null?d(e,t,n,r,null):null;if(typeof n.then==`function`)return p(e,t,La(n),r);if(n.$$typeof===C)return p(e,t,aa(e,n),r);za(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 O:return r=ja(r),m(e,t,n,r,i)}if(ne(r)||A(r))return e=e.get(n)||null,d(t,e,r,i,null);if(typeof r.then==`function`)return m(e,t,n,La(r),i);if(r.$$typeof===C)return m(e,t,n,aa(t,r),i);za(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),Li&&Ai(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 Li&&Ai(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)}),Li&&Ai(i,h),l}function g(i,s,c,l){if(c==null)throw Error(a(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(i,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(i,h),s=o(y,s,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(i,h),Li&&Ai(i,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(i,v.value,l),v!==null&&(s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return Li&&Ai(i,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,i,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(i,e)}),Li&&Ai(i,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=i(r,o.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===O&&ja(l)===r.type){n(e,r.sibling),c=i(r,o.props),Ra(c,o),c.return=e,e=c;break a}n(e,r);break}else t(e,r);r=r.sibling}o.type===y?(c=hi(o.props.children,e.mode,c,o.key),c.return=e,e=c):(c=mi(o.type,o.key,o.props,null,e.mode,c),Ra(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=i(r,o.children||[]),c.return=e,e=c;break a}else{n(e,r);break}else t(e,r);r=r.sibling}c=vi(o,e.mode,c),c.return=e,e=c}return s(e);case O:return o=ja(o),b(e,r,o,c)}if(ne(o))return h(e,r,o,c);if(A(o)){if(l=A(o),typeof l!=`function`)throw Error(a(150));return o=l.call(o),g(e,r,o,c)}if(typeof o.then==`function`)return b(e,r,La(o),c);if(o.$$typeof===C)return b(e,r,aa(e,o),c);za(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=i(r,o),c.return=e,e=c):(n(e,r),c=gi(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{Ia=0;var i=b(e,t,n,r);return Fa=null,i}catch(t){if(t===Ta||t===Da)throw t;var a=ui(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Va=Ba(!0),Ha=Ba(!1),Ua=!1;function Wa(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Ga(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 Ka(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function qa(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,Jl&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=si(e),oi(e,null,n),t}return ri(e,r,t,n),si(e)}function Ja(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,tt(e,n)}}function Ya(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 Xa=!1;function Za(){if(Xa){var e=ga;if(e!==null)throw e}}function Qa(e,t,n,r){Xa=!1;var i=e.updateQueue;Ua=!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?(Zl&f)===f:(r&f)===f){f!==0&&f===ha&&(Xa=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var m=e,g=s;f=t;var _=n;switch(g.tag){case 1:if(m=g.payload,typeof m==`function`){d=m.call(_,d,f);break a}d=m;break a;case 3:m.flags=m.flags&-65537|128;case 0:if(m=g.payload,f=typeof m==`function`?m.call(_,d,f):m,f==null)break a;d=h({},d,f);break a;case 2:Ua=!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),au|=o,e.lanes=o,e.memoizedState=d}}function $a(e,t){if(typeof e!=`function`)throw Error(a(191,e));e.call(t)}function eo(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)$a(n[e],t)}var to=oe(null),no=oe(0);function ro(e,t){e=ru,I(no,e),I(to,t),ru=e|t.baseLanes}function io(){I(no,ru),I(to,to.current)}function ao(){ru=no.current,F(to),F(no)}var oo=oe(null),so=null;function co(e){var t=e.alternate;I(mo,mo.current&1),I(oo,e),so===null&&(t===null||to.current!==null||t.memoizedState!==null)&&(so=e)}function lo(e){I(mo,mo.current),I(oo,e),so===null&&(so=e)}function uo(e){e.tag===22?(I(mo,mo.current),I(oo,e),so===null&&(so=e)):fo(e)}function fo(){I(mo,mo.current),I(oo,oo.current)}function po(e){F(oo),so===e&&(so=null),F(mo)}var mo=oe(0);function ho(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||_f(n)||vf(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 go=0,_o=null,vo=null,yo=null,bo=!1,xo=!1,So=!1,Co=0,wo=0,To=null,Eo=0;function Do(){throw Error(a(321))}function Oo(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!wr(e[n],t[n]))return!1;return!0}function ko(e,t,n,r,i,a){return go=a,_o=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,N.H=e===null||e.memoizedState===null?Ks:qs,So=!1,a=n(r,i),So=!1,xo&&(a=jo(t,n,r,i)),Ao(e),a}function Ao(e){N.H=Gs;var t=vo!==null&&vo.next!==null;if(go=0,yo=vo=_o=null,bo=!1,wo=0,To=null,t)throw Error(a(300));e===null||uc||(e=e.dependencies,e!==null&&na(e)&&(uc=!0))}function jo(e,t,n,r){_o=e;var i=0;do{if(xo&&(To=null),wo=0,xo=!1,25<=i)throw Error(a(301));if(i+=1,yo=vo=null,e.updateQueue!=null){var o=e.updateQueue;o.lastEffect=null,o.events=null,o.stores=null,o.memoCache!=null&&(o.memoCache.index=0)}N.H=Js,o=t(n,r)}while(xo);return o}function Mo(){var e=N.H,t=e.useState()[0];return t=typeof t.then==`function`?zo(t):t,e=e.useState()[0],(vo===null?null:vo.memoizedState)!==e&&(_o.flags|=1024),t}function No(){var e=Co!==0;return Co=0,e}function Po(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function Fo(e){if(bo){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}bo=!1}go=0,yo=vo=_o=null,xo=!1,wo=Co=0,To=null}function Io(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return yo===null?_o.memoizedState=yo=e:yo=yo.next=e,yo}function Lo(){if(vo===null){var e=_o.alternate;e=e===null?null:e.memoizedState}else e=vo.next;var t=yo===null?_o.memoizedState:yo.next;if(t!==null)yo=t,vo=e;else{if(e===null)throw _o.alternate===null?Error(a(467)):Error(a(310));vo=e,e={memoizedState:vo.memoizedState,baseState:vo.baseState,baseQueue:vo.baseQueue,queue:vo.queue,next:null},yo===null?_o.memoizedState=yo=e:yo=yo.next=e}return yo}function Ro(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function zo(e){var t=wo;return wo+=1,To===null&&(To=[]),e=Aa(To,e,t),t=_o,(yo===null?t.memoizedState:yo.next)===null&&(t=t.alternate,N.H=t===null||t.memoizedState===null?Ks:qs),e}function Bo(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return zo(e);if(e.$$typeof===C)return ia(e)}throw Error(a(438,String(e)))}function Vo(e){var t=null,n=_o.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=_o.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=Ro(),_o.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 Ho(e,t){return typeof t==`function`?t(e):t}function Uo(e){return Wo(Lo(),vo,e)}function Wo(e,t,n){var r=e.queue;if(r===null)throw Error(a(311));r.lastRenderedReducer=n;var i=e.baseQueue,o=r.pending;if(o!==null){if(i!==null){var s=i.next;i.next=o.next,o.next=s}t.baseQueue=i=o,r.pending=null}if(o=e.baseState,i===null)e.memoizedState=o;else{t=i.next;var c=s=null,l=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f===u.lane?(go&f)===f:(Zl&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===ha&&(d=!0);else if((go&p)===p){u=u.next,p===ha&&(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,_o.lanes|=p,au|=p;f=u.action,So&&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,_o.lanes|=f,au|=f;u=u.next}while(u!==null&&u!==t);if(l===null?s=o:l.next=c,!wr(o,e.memoizedState)&&(uc=!0,d&&(n=ga,n!==null)))throw n;e.memoizedState=o,e.baseState=s,e.baseQueue=l,r.lastRenderedState=o}return i===null&&(r.lanes=0),[e.memoizedState,r.dispatch]}function Go(e){var t=Lo(),n=t.queue;if(n===null)throw Error(a(311));n.lastRenderedReducer=e;var r=n.dispatch,i=n.pending,o=t.memoizedState;if(i!==null){n.pending=null;var s=i=i.next;do o=e(o,s.action),s=s.next;while(s!==i);wr(o,t.memoizedState)||(uc=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function Ko(e,t,n){var r=_o,i=Lo(),o=Li;if(o){if(n===void 0)throw Error(a(407));n=n()}else n=t();var s=!wr((vo||i).memoizedState,n);if(s&&(i.memoizedState=n,uc=!0),i=i.queue,_s(Yo.bind(null,r,i,e),[e]),i.getSnapshot!==t||s||yo!==null&&yo.memoizedState.tag&1){if(r.flags|=2048,fs(9,{destroy:void 0},Jo.bind(null,r,i,n,t),null),Yl===null)throw Error(a(349));o||go&127||qo(r,t,n)}return n}function qo(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=_o.updateQueue,t===null?(t=Ro(),_o.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Jo(e,t,n,r){t.value=n,t.getSnapshot=r,Xo(t)&&Zo(e)}function Yo(e,t,n){return n(function(){Xo(t)&&Zo(e)})}function Xo(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!wr(e,n)}catch{return!0}}function Zo(e){var t=ai(e,2);t!==null&&ku(t,e,2)}function Qo(e){var t=Io();if(typeof e==`function`){var n=e;if(e=n(),So){Re(!0);try{n()}finally{Re(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ho,lastRenderedState:e},t}function $o(e,t,n,r){return e.baseState=n,Wo(e,vo,typeof r==`function`?r:Ho)}function es(e,t,n,r,i){if(Hs(e))throw Error(a(485));if(e=t.action,e!==null){var o={payload:i,action:e,next:null,isTransition:!0,status:`pending`,value:null,reason:null,listeners:[],then:function(e){o.listeners.push(e)}};N.T===null?o.isTransition=!1:n(!0),r(o),n=t.pending,n===null?(o.next=t.pending=o,ts(t,o)):(o.next=n.next,t.pending=n.next=o)}}function ts(e,t){var n=t.action,r=t.payload,i=e.state;if(t.isTransition){var a=N.T,o={};N.T=o;try{var s=n(i,r),c=N.S;c!==null&&c(o,s),ns(e,t,s)}catch(n){is(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),N.T=a}}else try{a=n(i,r),ns(e,t,a)}catch(n){is(e,t,n)}}function ns(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){rs(e,t,n)},function(n){return is(e,t,n)}):rs(e,t,n)}function rs(e,t,n){t.status=`fulfilled`,t.value=n,as(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,ts(e,n)))}function is(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,as(t),t=t.next;while(t!==r)}e.action=null}function as(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function os(e,t){return t}function ss(e,t){if(Li){var n=Yl.formState;if(n!==null){a:{var r=_o;if(Li){if(Ii){b:{for(var i=Ii,a=zi;i.nodeType!==8;){if(!a){i=null;break b}if(i=bf(i.nextSibling),i===null){i=null;break b}}a=i.data,i=a===`F!`||a===`F`?i:null}if(i){Ii=bf(i.nextSibling),r=i.data===`F!`;break a}}Vi(r)}r=!1}r&&(t=n[0])}}return n=Io(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:os,lastRenderedState:t},n.queue=r,n=zs.bind(null,_o,r),r.dispatch=n,r=Qo(!1),a=Vs.bind(null,_o,!1,r.queue),r=Io(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=es.bind(null,_o,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function cs(e){return ls(Lo(),vo,e)}function ls(e,t,n){if(t=Wo(e,t,os)[0],e=Uo(Ho)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=zo(t)}catch(e){throw e===Ta?Da:e}else r=t;t=Lo();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(_o.flags|=2048,fs(9,{destroy:void 0},us.bind(null,i,n),null)),[r,a,e]}function us(e,t){e.action=t}function ds(e){var t=Lo(),n=vo;if(n!==null)return ls(t,n,e);Lo(),t=t.memoizedState,n=Lo();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function fs(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=_o.updateQueue,t===null&&(t=Ro(),_o.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 ps(){return Lo().memoizedState}function ms(e,t,n,r){var i=Io();_o.flags|=e,i.memoizedState=fs(1|t,{destroy:void 0},n,r===void 0?null:r)}function hs(e,t,n,r){var i=Lo();r=r===void 0?null:r;var a=i.memoizedState.inst;vo!==null&&r!==null&&Oo(r,vo.memoizedState.deps)?i.memoizedState=fs(t,a,n,r):(_o.flags|=e,i.memoizedState=fs(1|t,a,n,r))}function gs(e,t){ms(8390656,8,e,t)}function _s(e,t){hs(2048,8,e,t)}function vs(e){_o.flags|=4;var t=_o.updateQueue;if(t===null)t=Ro(),_o.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function ys(e){var t=Lo().memoizedState;return vs({ref:t,nextImpl:e}),function(){if(Jl&2)throw Error(a(440));return t.impl.apply(void 0,arguments)}}function bs(e,t){return hs(4,2,e,t)}function xs(e,t){return hs(4,4,e,t)}function Ss(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 Cs(e,t,n){n=n==null?null:n.concat([e]),hs(4,4,Ss.bind(null,t,e),n)}function ws(){}function Ts(e,t){var n=Lo();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&Oo(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Es(e,t){var n=Lo();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&Oo(t,r[1]))return r[0];if(r=e(),So){Re(!0);try{e()}finally{Re(!1)}}return n.memoizedState=[r,t],r}function Ds(e,t,n){return n===void 0||go&1073741824&&!(Zl&261930)?e.memoizedState=t:(e.memoizedState=n,e=Ou(),_o.lanes|=e,au|=e,n)}function Os(e,t,n,r){return wr(n,t)?n:to.current===null?!(go&42)||go&1073741824&&!(Zl&261930)?(uc=!0,e.memoizedState=n):(e=Ou(),_o.lanes|=e,au|=e,t):(e=Ds(e,n,r),wr(e,t)||(uc=!0),e)}function ks(e,t,n,r,i){var a=P.p;P.p=a!==0&&8>a?a:8;var o=N.T,s={};N.T=s,Vs(e,!1,t,n);try{var c=i(),l=N.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?Bs(e,t,ya(c,r),Du(e)):Bs(e,t,r,Du(e))}catch(n){Bs(e,t,{then:function(){},status:`rejected`,reason:n},Du())}finally{P.p=a,o!==null&&s.types!==null&&(o.types=s.types),N.T=o}}function As(){}function js(e,t,n,r){if(e.tag!==5)throw Error(a(476));var i=Ms(e).queue;ks(e,i,t,re,n===null?As:function(){return Ns(e),n(r)})}function Ms(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:re,baseState:re,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ho,lastRenderedState:re},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ho,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Ns(e){var t=Ms(e);t.next===null&&(t=e.alternate.memoizedState),Bs(e,t.next.queue,{},Du())}function Ps(){return ia(lp)}function Fs(){return Lo().memoizedState}function Is(){return Lo().memoizedState}function Ls(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=Du();e=Ka(n);var r=qa(t,e,n);r!==null&&(ku(r,t,n),Ja(r,t,n)),t={cache:da()},e.payload=t;return}t=t.return}}function Rs(e,t,n){var r=Du();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Hs(e)?Us(t,n):(n=ii(e,t,n,r),n!==null&&(ku(n,e,r),Ws(n,t,r)))}function zs(e,t,n){Bs(e,t,n,Du())}function Bs(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(Hs(e))Us(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,wr(s,o))return ri(e,t,i,0),Yl===null&&ni(),!1}catch{}if(n=ii(e,t,i,r),n!==null)return ku(n,e,r),Ws(n,t,r),!0}return!1}function Vs(e,t,n,r){if(r={lane:2,revertLane:Sd(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},Hs(e)){if(t)throw Error(a(479))}else t=ii(e,n,r,2),t!==null&&ku(t,e,2)}function Hs(e){var t=e.alternate;return e===_o||t!==null&&t===_o}function Us(e,t){xo=bo=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Ws(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,tt(e,n)}}var Gs={readContext:ia,use:Bo,useCallback:Do,useContext:Do,useEffect:Do,useImperativeHandle:Do,useLayoutEffect:Do,useInsertionEffect:Do,useMemo:Do,useReducer:Do,useRef:Do,useState:Do,useDebugValue:Do,useDeferredValue:Do,useTransition:Do,useSyncExternalStore:Do,useId:Do,useHostTransitionStatus:Do,useFormState:Do,useActionState:Do,useOptimistic:Do,useMemoCache:Do,useCacheRefresh:Do};Gs.useEffectEvent=Do;var Ks={readContext:ia,use:Bo,useCallback:function(e,t){return Io().memoizedState=[e,t===void 0?null:t],e},useContext:ia,useEffect:gs,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),ms(4194308,4,Ss.bind(null,t,e),n)},useLayoutEffect:function(e,t){return ms(4194308,4,e,t)},useInsertionEffect:function(e,t){ms(4,2,e,t)},useMemo:function(e,t){var n=Io();t=t===void 0?null:t;var r=e();if(So){Re(!0);try{e()}finally{Re(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=Io();if(n!==void 0){var i=n(t);if(So){Re(!0);try{n(t)}finally{Re(!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=Rs.bind(null,_o,e),[r.memoizedState,e]},useRef:function(e){var t=Io();return e={current:e},t.memoizedState=e},useState:function(e){e=Qo(e);var t=e.queue,n=zs.bind(null,_o,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:ws,useDeferredValue:function(e,t){return Ds(Io(),e,t)},useTransition:function(){var e=Qo(!1);return e=ks.bind(null,_o,e.queue,!0,!1),Io().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=_o,i=Io();if(Li){if(n===void 0)throw Error(a(407));n=n()}else{if(n=t(),Yl===null)throw Error(a(349));Zl&127||qo(r,t,n)}i.memoizedState=n;var o={value:n,getSnapshot:t};return i.queue=o,gs(Yo.bind(null,r,o,e),[e]),r.flags|=2048,fs(9,{destroy:void 0},Jo.bind(null,r,o,n,t),null),n},useId:function(){var e=Io(),t=Yl.identifierPrefix;if(Li){var n=ki,r=Oi;n=(r&~(1<<32-ze(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=Co++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=Eo++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:Ps,useFormState:ss,useActionState:ss,useOptimistic:function(e){var t=Io();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=Vs.bind(null,_o,!0,n),n.dispatch=t,[e,t]},useMemoCache:Vo,useCacheRefresh:function(){return Io().memoizedState=Ls.bind(null,_o)},useEffectEvent:function(e){var t=Io(),n={impl:e};return t.memoizedState=n,function(){if(Jl&2)throw Error(a(440));return n.impl.apply(void 0,arguments)}}},qs={readContext:ia,use:Bo,useCallback:Ts,useContext:ia,useEffect:_s,useImperativeHandle:Cs,useInsertionEffect:bs,useLayoutEffect:xs,useMemo:Es,useReducer:Uo,useRef:ps,useState:function(){return Uo(Ho)},useDebugValue:ws,useDeferredValue:function(e,t){return Os(Lo(),vo.memoizedState,e,t)},useTransition:function(){var e=Uo(Ho)[0],t=Lo().memoizedState;return[typeof e==`boolean`?e:zo(e),t]},useSyncExternalStore:Ko,useId:Fs,useHostTransitionStatus:Ps,useFormState:cs,useActionState:cs,useOptimistic:function(e,t){return $o(Lo(),vo,e,t)},useMemoCache:Vo,useCacheRefresh:Is};qs.useEffectEvent=ys;var Js={readContext:ia,use:Bo,useCallback:Ts,useContext:ia,useEffect:_s,useImperativeHandle:Cs,useInsertionEffect:bs,useLayoutEffect:xs,useMemo:Es,useReducer:Go,useRef:ps,useState:function(){return Go(Ho)},useDebugValue:ws,useDeferredValue:function(e,t){var n=Lo();return vo===null?Ds(n,e,t):Os(n,vo.memoizedState,e,t)},useTransition:function(){var e=Go(Ho)[0],t=Lo().memoizedState;return[typeof e==`boolean`?e:zo(e),t]},useSyncExternalStore:Ko,useId:Fs,useHostTransitionStatus:Ps,useFormState:ds,useActionState:ds,useOptimistic:function(e,t){var n=Lo();return vo===null?(n.baseState=e,[e,n.queue.dispatch]):$o(n,vo,e,t)},useMemoCache:Vo,useCacheRefresh:Is};Js.useEffectEvent=ys;function Ys(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:h({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Xs={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=Du(),i=Ka(r);i.payload=t,n!=null&&(i.callback=n),t=qa(e,i,r),t!==null&&(ku(t,e,r),Ja(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=Du(),i=Ka(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=qa(e,i,r),t!==null&&(ku(t,e,r),Ja(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Du(),r=Ka(n);r.tag=2,t!=null&&(r.callback=t),t=qa(e,r,n),t!==null&&(ku(t,e,n),Ja(t,e,n))}};function Zs(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?!Tr(n,r)||!Tr(i,a):!0}function Qs(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&&Xs.enqueueReplaceState(t,t.state,null)}function $s(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=h({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function ec(e){Qr(e)}function tc(e){console.error(e)}function nc(e){Qr(e)}function rc(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function ic(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 ac(e,t,n){return n=Ka(n),n.tag=3,n.payload={element:null},n.callback=function(){rc(e,t)},n}function oc(e){return e=Ka(e),e.tag=3,e}function sc(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(){ic(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){ic(t,n,r),typeof i!=`function`&&(_u===null?_u=new Set([this]):_u.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function cc(e,t,n,r,i){if(n.flags|=32768,typeof r==`object`&&r&&typeof r.then==`function`){if(t=n.alternate,t!==null&&ta(t,n,i,!0),n=oo.current,n!==null){switch(n.tag){case 31:case 13:return so===null?Vu():n.alternate===null&&iu===0&&(iu=3),n.flags&=-257,n.flags|=65536,n.lanes=i,r===Oa?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),id(e,r,i)),!1;case 22:return n.flags|=65536,r===Oa?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)),id(e,r,i)),!1}throw Error(a(435,n.tag))}return id(e,r,i),Vu(),!1}if(Li)return t=oo.current,t===null?(r!==Bi&&(t=Error(a(423),{cause:r}),qi(bi(t,n))),e=e.current.alternate,e.flags|=65536,i&=-i,e.lanes|=i,r=bi(r,n),i=ac(e.stateNode,r,i),Ya(e,i),iu!==4&&(iu=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=i,r!==Bi&&(e=Error(a(422),{cause:r}),qi(bi(e,n)))),!1;var o=Error(a(520),{cause:r});if(o=bi(o,n),uu===null?uu=[o]:uu.push(o),iu!==4&&(iu=2),t===null)return!0;r=bi(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=i&-i,n.lanes|=e,e=ac(n.stateNode,r,e),Ya(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`&&(_u===null||!_u.has(o))))return n.flags|=65536,i&=-i,n.lanes|=i,i=oc(i),sc(i,e,n,r),Ya(n,i),!1}n=n.return}while(n!==null);return!1}var lc=Error(a(461)),uc=!1;function dc(e,t,n,r){t.child=e===null?Ha(t,null,n,r):Va(t,e.child,n,r)}function fc(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 ra(t),r=ko(e,t,n,o,a,i),s=No(),e!==null&&!uc?(Po(e,t,i),Ic(e,t,i)):(Li&&s&&Mi(t),t.flags|=1,dc(e,t,r,i),t.child)}function pc(e,t,n,r,i){if(e===null){var a=n.type;return typeof a==`function`&&!di(a)&&a.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=a,mc(e,t,a,r,i)):(e=mi(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!Lc(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?Tr:n,n(o,r)&&e.ref===t.ref)return Ic(e,t,i)}return t.flags|=1,e=fi(a,r),e.ref=t.ref,e.return=t,t.child=e}function mc(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(Tr(a,r)&&e.ref===t.ref)if(uc=!1,t.pendingProps=r=a,Lc(e,i))e.flags&131072&&(uc=!0);else return t.lanes=e.lanes,Ic(e,t,i)}return Sc(e,t,n,r,i)}function hc(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 _c(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Ca(t,a===null?null:a.cachePool),a===null?io():ro(t,a),uo(t);else return r=t.lanes=536870912,_c(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&Ca(t,null),io(),fo(t)):(Ca(t,a.cachePool),ro(t,a),fo(t),t.memoizedState=null);return dc(e,t,i,n),t.child}function gc(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function _c(e,t,n,r,i){var a=Sa();return a=a===null?null:{parent:ua._currentValue,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&Ca(t,null),io(),uo(t),e!==null&&ta(e,t,r,!0),t.childLanes=i,null}function vc(e,t){return t=jc({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function yc(e,t,n){return Va(t,e.child,null,n),e=vc(t,t.pendingProps),e.flags|=2,po(t),t.memoizedState=null,e}function bc(e,t,n){var r=t.pendingProps,i=(t.flags&128)!=0;if(t.flags&=-129,e===null){if(Li){if(r.mode===`hidden`)return e=vc(t,r),t.lanes=536870912,gc(null,e);if(lo(t),(e=Ii)?(e=gf(e,zi),e=e!==null&&e.data===`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Di===null?null:{id:Oi,overflow:ki},retryLane:536870912,hydrationErrors:null},n=_i(e),n.return=t,t.child=n,Fi=t,Ii=null)):e=null,e===null)throw Vi(t);return t.lanes=536870912,null}return vc(t,r)}var o=e.memoizedState;if(o!==null){var s=o.dehydrated;if(lo(t),i)if(t.flags&256)t.flags&=-257,t=yc(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(a(558));else if(uc||ta(e,t,n,!1),i=(n&e.childLanes)!==0,uc||i){if(r=Yl,r!==null&&(s=nt(r,n),s!==0&&s!==o.retryLane))throw o.retryLane=s,ai(e,s),ku(r,e,s),lc;Vu(),t=yc(e,t,n)}else e=o.treeContext,Ii=bf(s.nextSibling),Fi=t,Li=!0,Ri=null,zi=!1,e!==null&&Pi(t,e),t=vc(t,r),t.flags|=4096;return t}return e=fi(e.child,{mode:r.mode,children:r.children}),e.ref=t.ref,t.child=e,e.return=t,e}function xc(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(a(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function Sc(e,t,n,r,i){return ra(t),n=ko(e,t,n,r,void 0,i),r=No(),e!==null&&!uc?(Po(e,t,i),Ic(e,t,i)):(Li&&r&&Mi(t),t.flags|=1,dc(e,t,n,i),t.child)}function Cc(e,t,n,r,i,a){return ra(t),t.updateQueue=null,n=jo(t,r,n,i),Ao(e),r=No(),e!==null&&!uc?(Po(e,t,a),Ic(e,t,a)):(Li&&r&&Mi(t),t.flags|=1,dc(e,t,n,a),t.child)}function wc(e,t,n,r,i){if(ra(t),t.stateNode===null){var a=ci,o=n.contextType;typeof o==`object`&&o&&(a=ia(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=Xs,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},Wa(t),o=n.contextType,a.context=typeof o==`object`&&o?ia(o):ci,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(Ys(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&&Xs.enqueueReplaceState(a,a.state,null),Qa(t,r,a,i),Za(),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=$s(n,s);a.props=c;var l=a.context,u=n.contextType;o=ci,typeof u==`object`&&u&&(o=ia(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)&&Qs(t,a,r,o),Ua=!1;var f=t.memoizedState;a.state=f,Qa(t,r,a,i),Za(),l=t.memoizedState,s||f!==l||Ua?(typeof d==`function`&&(Ys(t,n,d,r),l=t.memoizedState),(c=Ua||Zs(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,Ga(e,t),o=t.memoizedProps,u=$s(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=ci,typeof l==`object`&&l&&(c=ia(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)&&Qs(t,a,r,c),Ua=!1,f=t.memoizedState,a.state=f,Qa(t,r,a,i),Za();var p=t.memoizedState;o!==d||f!==p||Ua||e!==null&&e.dependencies!==null&&na(e.dependencies)?(typeof s==`function`&&(Ys(t,n,s,r),p=t.memoizedState),(u=Ua||Zs(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&na(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,xc(e,t),r=(t.flags&128)!=0,a||r?(a=t.stateNode,n=r&&typeof n.getDerivedStateFromError!=`function`?null:a.render(),t.flags|=1,e!==null&&r?(t.child=Va(t,e.child,null,i),t.child=Va(t,null,n,i)):dc(e,t,n,i),t.memoizedState=a.state,e=t.child):e=Ic(e,t,i),e}function Tc(e,t,n,r){return Gi(),t.flags|=256,dc(e,t,n,r),t.child}var Ec={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Dc(e){return{baseLanes:e,cachePool:wa()}}function Oc(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=cu),e}function kc(e,t,n){var r=t.pendingProps,i=!1,o=(t.flags&128)!=0,s;if((s=o)||(s=e!==null&&e.memoizedState===null?!1:(mo.current&2)!=0),s&&(i=!0,t.flags&=-129),s=(t.flags&32)!=0,t.flags&=-33,e===null){if(Li){if(i?co(t):fo(t),(e=Ii)?(e=gf(e,zi),e=e!==null&&e.data!==`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Di===null?null:{id:Oi,overflow:ki},retryLane:536870912,hydrationErrors:null},n=_i(e),n.return=t,t.child=n,Fi=t,Ii=null)):e=null,e===null)throw Vi(t);return vf(e)?t.lanes=32:t.lanes=536870912,null}var c=r.children;return r=r.fallback,i?(fo(t),i=t.mode,c=jc({mode:`hidden`,children:c},i),r=hi(r,i,n,null),c.return=t,r.return=t,c.sibling=r,t.child=c,r=t.child,r.memoizedState=Dc(n),r.childLanes=Oc(e,s,n),t.memoizedState=Ec,gc(null,r)):(co(t),Ac(t,c))}var l=e.memoizedState;if(l!==null&&(c=l.dehydrated,c!==null)){if(o)t.flags&256?(co(t),t.flags&=-257,t=Mc(e,t,n)):t.memoizedState===null?(fo(t),c=r.fallback,i=t.mode,r=jc({mode:`visible`,children:r.children},i),c=hi(c,i,n,null),c.flags|=2,r.return=t,c.return=t,r.sibling=c,t.child=r,Va(t,e.child,null,n),r=t.child,r.memoizedState=Dc(n),r.childLanes=Oc(e,s,n),t.memoizedState=Ec,t=gc(null,r)):(fo(t),t.child=e.child,t.flags|=128,t=null);else if(co(t),vf(c)){if(s=c.nextSibling&&c.nextSibling.dataset,s)var u=s.dgst;s=u,r=Error(a(419)),r.stack=``,r.digest=s,qi({value:r,source:null,stack:null}),t=Mc(e,t,n)}else if(uc||ta(e,t,n,!1),s=(n&e.childLanes)!==0,uc||s){if(s=Yl,s!==null&&(r=nt(s,n),r!==0&&r!==l.retryLane))throw l.retryLane=r,ai(e,r),ku(s,e,r),lc;_f(c)||Vu(),t=Mc(e,t,n)}else _f(c)?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,Ii=bf(c.nextSibling),Fi=t,Li=!0,Ri=null,zi=!1,e!==null&&Pi(t,e),t=Ac(t,r.children),t.flags|=4096);return t}return i?(fo(t),c=r.fallback,i=t.mode,l=e.child,u=l.sibling,r=fi(l,{mode:`hidden`,children:r.children}),r.subtreeFlags=l.subtreeFlags&65011712,u===null?(c=hi(c,i,n,null),c.flags|=2):c=fi(u,c),c.return=t,r.return=t,r.sibling=c,t.child=r,gc(null,r),r=t.child,c=e.child.memoizedState,c===null?c=Dc(n):(i=c.cachePool,i===null?i=wa():(l=ua._currentValue,i=i.parent===l?i:{parent:l,pool:l}),c={baseLanes:c.baseLanes|n,cachePool:i}),r.memoizedState=c,r.childLanes=Oc(e,s,n),t.memoizedState=Ec,gc(e.child,r)):(co(t),n=e.child,e=n.sibling,n=fi(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 Ac(e,t){return t=jc({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function jc(e,t){return e=ui(22,e,null,t),e.lanes=0,e}function Mc(e,t,n){return Va(t,e.child,null,n),e=Ac(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Nc(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),$i(e.return,t,n)}function Pc(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 Fc(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=mo.current,s=(o&2)!=0;if(s?(o=o&1|2,t.flags|=128):o&=1,I(mo,o),dc(e,t,r,n),r=Li?wi:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Nc(e,n,t);else if(e.tag===19)Nc(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&&ho(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),Pc(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&&ho(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}Pc(t,!0,n,null,a,r);break;case`together`:Pc(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function Ic(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),au|=t.lanes,(n&t.childLanes)===0)if(e!==null){if(ta(e,t,n,!1),(n&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(a(153));if(t.child!==null){for(e=t.child,n=fi(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=fi(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Lc(e,t){return(e.lanes&t)===0?(e=e.dependencies,!!(e!==null&&na(e))):!0}function Rc(e,t,n){switch(t.tag){case 3:de(t,t.stateNode.containerInfo),Zi(t,ua,e.memoizedState.cache),Gi();break;case 27:case 5:pe(t);break;case 4:de(t,t.stateNode.containerInfo);break;case 10:Zi(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,lo(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated===null?(n&t.child.childLanes)===0?(co(t),e=Ic(e,t,n),e===null?null:e.sibling):kc(e,t,n):(co(t),t.flags|=128,null);co(t);break;case 19:var i=(e.flags&128)!=0;if(r=(n&t.childLanes)!==0,r||=(ta(e,t,n,!1),(n&t.childLanes)!==0),i){if(r)return Fc(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),I(mo,mo.current),r)break;return null;case 22:return t.lanes=0,hc(e,t,n,t.pendingProps);case 24:Zi(t,ua,e.memoizedState.cache)}return Ic(e,t,n)}function zc(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps)uc=!0;else{if(!Lc(e,n)&&!(t.flags&128))return uc=!1,Rc(e,t,n);uc=!!(e.flags&131072)}else uc=!1,Li&&t.flags&1048576&&ji(t,wi,t.index);switch(t.lanes=0,t.tag){case 16:a:{var r=t.pendingProps;if(e=ja(t.elementType),t.type=e,typeof e==`function`)di(e)?(r=$s(e,r),t.tag=1,t=wc(null,t,e,r,n)):(t.tag=0,t=Sc(null,t,e,r,n));else{if(e!=null){var i=e.$$typeof;if(i===w){t.tag=11,t=fc(null,t,e,r,n);break a}else if(i===D){t.tag=14,t=pc(null,t,e,r,n);break a}}throw t=M(e)||e,Error(a(306,t,``))}}return t;case 0:return Sc(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,i=$s(r,t.pendingProps),wc(e,t,r,i,n);case 3:a:{if(de(t,t.stateNode.containerInfo),e===null)throw Error(a(387));r=t.pendingProps;var o=t.memoizedState;i=o.element,Ga(e,t),Qa(t,r,null,n);var s=t.memoizedState;if(r=s.cache,Zi(t,ua,r),r!==o.cache&&ea(t,[ua],n,!0),Za(),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=Tc(e,t,r,n);break a}else if(r!==i){i=bi(Error(a(424)),t),qi(i),t=Tc(e,t,r,n);break a}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName===`HTML`?e.ownerDocument.body:e}for(Ii=bf(e.firstChild),Fi=t,Li=!0,Ri=null,zi=!0,n=Ha(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(Gi(),r===i){t=Ic(e,t,n);break a}dc(e,t,r,n)}t=t.child}return t;case 26:return xc(e,t),e===null?(n=Vf(t.type,null,t.pendingProps,null))?t.memoizedState=n:Li||(n=t.type,e=t.pendingProps,r=Qd(le.current).createElement(n),r[ct]=t,r[lt]=e,Kd(r,n,e),xt(r),t.stateNode=r):t.memoizedState=Vf(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return pe(t),e===null&&Li&&(r=t.stateNode=wf(t.type,t.pendingProps,le.current),Fi=t,zi=!0,i=Ii,uf(t.type)?(xf=i,Ii=bf(r.firstChild)):Ii=i),dc(e,t,t.pendingProps.children,n),xc(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&Li&&((i=r=Ii)&&(r=mf(r,t.type,t.pendingProps,zi),r===null?i=!1:(t.stateNode=r,Fi=t,Ii=bf(r.firstChild),zi=!1,i=!0)),i||Vi(t)),pe(t),i=t.type,o=t.pendingProps,s=e===null?null:e.memoizedProps,r=o.children,tf(i,o)?r=null:s!==null&&tf(i,s)&&(t.flags|=32),t.memoizedState!==null&&(i=ko(e,t,Mo,null,null,n),lp._currentValue=i),xc(e,t),dc(e,t,r,n),t.child;case 6:return e===null&&Li&&((e=n=Ii)&&(n=hf(n,t.pendingProps,zi),n===null?e=!1:(t.stateNode=n,Fi=t,Ii=null,e=!0)),e||Vi(t)),null;case 13:return kc(e,t,n);case 4:return de(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Va(t,null,r,n):dc(e,t,r,n),t.child;case 11:return fc(e,t,t.type,t.pendingProps,n);case 7:return dc(e,t,t.pendingProps,n),t.child;case 8:return dc(e,t,t.pendingProps.children,n),t.child;case 12:return dc(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,Zi(t,t.type,r.value),dc(e,t,r.children,n),t.child;case 9:return i=t.type._context,r=t.pendingProps.children,ra(t),i=ia(i),r=r(i),t.flags|=1,dc(e,t,r,n),t.child;case 14:return pc(e,t,t.type,t.pendingProps,n);case 15:return mc(e,t,t.type,t.pendingProps,n);case 19:return Fc(e,t,n);case 31:return bc(e,t,n);case 22:return hc(e,t,n,t.pendingProps);case 24:return ra(t),r=ia(ua),e===null?(i=Sa(),i===null&&(i=Yl,o=da(),i.pooledCache=o,o.refCount++,o!==null&&(i.pooledCacheLanes|=n),i=o),t.memoizedState={parent:r,cache:i},Wa(t),Zi(t,ua,i)):((e.lanes&n)!==0&&(Ga(e,t),Qa(t,null,null,n),Za()),i=e.memoizedState,o=t.memoizedState,i.parent===r?(r=o.cache,Zi(t,ua,r),r!==i.cache&&ea(t,[ua],n,!0)):(i={parent:r,cache:r},t.memoizedState=i,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=i),Zi(t,ua,r))),dc(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(a(156,t.tag))}function Bc(e){e.flags|=4}function Vc(e,t,n,r,i){if((t=(e.mode&32)!=0)&&(t=!1),t){if(e.flags|=16777216,(i&335544128)===i)if(e.stateNode.complete)e.flags|=8192;else if(Ru())e.flags|=8192;else throw Ma=Oa,Ea}else e.flags&=-16777217}function Hc(e,t){if(t.type!==`stylesheet`||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!np(t))if(Ru())e.flags|=8192;else throw Ma=Oa,Ea}function Uc(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:Xe(),e.lanes|=t,lu|=t)}function Wc(e,t){if(!Li)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 Gc(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 Kc(e,t,n){var r=t.pendingProps;switch(Ni(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Gc(t),null;case 1:return Gc(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),Qi(ua),fe(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(Wi(t)?Bc(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Ki())),Gc(t),null;case 26:var i=t.type,o=t.memoizedState;return e===null?(Bc(t),o===null?(Gc(t),Vc(t,i,null,r,n)):(Gc(t),Hc(t,o))):o?o===e.memoizedState?(Gc(t),t.flags&=-16777217):(Bc(t),Gc(t),Hc(t,o)):(e=e.memoizedProps,e!==r&&Bc(t),Gc(t),Vc(t,i,e,r,n)),null;case 27:if(me(t),n=le.current,i=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Bc(t);else{if(!r){if(t.stateNode===null)throw Error(a(166));return Gc(t),null}e=se.current,Wi(t)?Hi(t,e):(e=wf(i,r,n),t.stateNode=e,Bc(t))}return Gc(t),null;case 5:if(me(t),i=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Bc(t);else{if(!r){if(t.stateNode===null)throw Error(a(166));return Gc(t),null}if(o=se.current,Wi(t))Hi(t,o);else{var s=Qd(le.current);switch(o){case 1:o=s.createElementNS(`http://www.w3.org/2000/svg`,i);break;case 2:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,i);break;default:switch(i){case`svg`:o=s.createElementNS(`http://www.w3.org/2000/svg`,i);break;case`math`:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,i);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(i,{is:r.is}):s.createElement(i)}}o[ct]=t,o[lt]=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(Kd(o,i,r),i){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&Bc(t)}}return Gc(t),Vc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&Bc(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(a(166));if(e=le.current,Wi(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,i=Fi,i!==null)switch(i.tag){case 27:case 5:r=i.memoizedProps}e[ct]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||Ud(e.nodeValue,n)),e||Vi(t,!0)}else e=Qd(e).createTextNode(r),e[ct]=t,t.stateNode=e}return Gc(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Wi(t),n!==null){if(e===null){if(!r)throw Error(a(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(a(557));e[ct]=t}else Gi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Gc(t),e=!1}else n=Ki(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(po(t),t):(po(t),null);if(t.flags&128)throw Error(a(558))}return Gc(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(i=Wi(t),r!==null&&r.dehydrated!==null){if(e===null){if(!i)throw Error(a(318));if(i=t.memoizedState,i=i===null?null:i.dehydrated,!i)throw Error(a(317));i[ct]=t}else Gi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Gc(t),i=!1}else i=Ki(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=i),i=!0;if(!i)return t.flags&256?(po(t),t):(po(t),null)}return po(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,i=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(i=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==i&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Uc(t,t.updateQueue),Gc(t),null);case 4:return fe(),e===null&&Nd(t.stateNode.containerInfo),Gc(t),null;case 10:return Qi(t.type),Gc(t),null;case 19:if(F(mo),r=t.memoizedState,r===null)return Gc(t),null;if(i=(t.flags&128)!=0,o=r.rendering,o===null)if(i)Wc(r,!1);else{if(iu!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=ho(e),o!==null){for(t.flags|=128,Wc(r,!1),e=o.updateQueue,t.updateQueue=e,Uc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)pi(n,e),n=n.sibling;return I(mo,mo.current&1|2),Li&&Ai(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&De()>hu&&(t.flags|=128,i=!0,Wc(r,!1),t.lanes=4194304)}else{if(!i)if(e=ho(o),e!==null){if(t.flags|=128,i=!0,e=e.updateQueue,t.updateQueue=e,Uc(t,e),Wc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!Li)return Gc(t),null}else 2*De()-r.renderingStartTime>hu&&n!==536870912&&(t.flags|=128,i=!0,Wc(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?(Gc(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=De(),e.sibling=null,n=mo.current,I(mo,i?n&1|2:n&1),Li&&Ai(t,r.treeForkCount),e);case 22:case 23:return po(t),ao(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Gc(t),t.subtreeFlags&6&&(t.flags|=8192)):Gc(t),n=t.updateQueue,n!==null&&Uc(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&&F(xa),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Qi(ua),Gc(t),null;case 25:return null;case 30:return null}throw Error(a(156,t.tag))}function qc(e,t){switch(Ni(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Qi(ua),fe(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return me(t),null;case 31:if(t.memoizedState!==null){if(po(t),t.alternate===null)throw Error(a(340));Gi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(po(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(a(340));Gi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return F(mo),null;case 4:return fe(),null;case 10:return Qi(t.type),null;case 22:case 23:return po(t),ao(),e!==null&&F(xa),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Qi(ua),null;case 25:return null;default:return null}}function Jc(e,t){switch(Ni(t),t.tag){case 3:Qi(ua),fe();break;case 26:case 27:case 5:me(t);break;case 4:fe();break;case 31:t.memoizedState!==null&&po(t);break;case 13:po(t);break;case 19:F(mo);break;case 10:Qi(t.type);break;case 22:case 23:po(t),ao(),e!==null&&F(xa);break;case 24:Qi(ua)}}function Yc(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){rd(t,t.return,e)}}function Xc(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){rd(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){rd(t,t.return,e)}}function Zc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{eo(t,n)}catch(t){rd(e,e.return,t)}}}function Qc(e,t,n){n.props=$s(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){rd(e,t,n)}}function $c(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){rd(e,t,n)}}function el(e,t){var n=e.ref,r=e.refCleanup;if(n!==null)if(typeof r==`function`)try{r()}catch(n){rd(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){rd(e,t,n)}else n.current=null}function tl(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){rd(e,e.return,t)}}function nl(e,t,n){try{var r=e.stateNode;qd(r,e.type,n,t),r[lt]=t}catch(t){rd(e,e.return,t)}}function rl(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&uf(e.type)||e.tag===4}function il(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||rl(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&&uf(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 al(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=tn));else if(r!==4&&(r===27&&uf(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(al(e,t,n),e=e.sibling;e!==null;)al(e,t,n),e=e.sibling}function ol(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&&uf(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(ol(e,t,n),e=e.sibling;e!==null;)ol(e,t,n),e=e.sibling}function sl(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Kd(t,r,n),t[ct]=e,t[lt]=n}catch(t){rd(e,e.return,t)}}var cl=!1,ll=!1,ul=!1,dl=typeof WeakSet==`function`?WeakSet:Set,fl=null;function pl(e,t){if(e=e.containerInfo,Xd=vp,e=kr(e),Ar(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 i=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||i!==0&&f.nodeType!==3||(c=s+i),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===i&&(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(Zd={focusedElem:e,selectionRange:n},vp=!1,fl=t;fl!==null;)if(t=fl,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,fl=e;else for(;fl!==null;){switch(t=fl,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++)i=e[n],i.ref.impl=i.nextImpl;break;case 11:case 15:break;case 1:if(e&1024&&o!==null){e=void 0,n=t,i=o.memoizedProps,o=o.memoizedState,r=n.stateNode;try{var h=$s(n.type,i);e=r.getSnapshotBeforeUpdate(h,o),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){rd(n,n.return,e)}}break;case 3:if(e&1024){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)pf(e);else if(n===1)switch(e.nodeName){case`HEAD`:case`HTML`:case`BODY`:pf(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(a(163))}if(e=t.sibling,e!==null){e.return=t.return,fl=e;break}fl=t.return}}function ml(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:kl(e,n),r&4&&Yc(5,n);break;case 1:if(kl(e,n),r&4)if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){rd(n,n.return,e)}else{var i=$s(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){rd(n,n.return,e)}}r&64&&Zc(n),r&512&&$c(n,n.return);break;case 3:if(kl(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{eo(e,t)}catch(e){rd(n,n.return,e)}}break;case 27:t===null&&r&4&&sl(n);case 26:case 5:kl(e,n),t===null&&r&4&&tl(n),r&512&&$c(n,n.return);break;case 12:kl(e,n);break;case 31:kl(e,n),r&4&&bl(e,n);break;case 13:kl(e,n),r&4&&xl(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=sd.bind(null,n),yf(e,n))));break;case 22:if(r=n.memoizedState!==null||cl,!r){t=t!==null&&t.memoizedState!==null||ll,i=cl;var a=ll;cl=r,(ll=t)&&!a?jl(e,n,(n.subtreeFlags&8772)!=0):kl(e,n),cl=i,ll=a}break;case 30:break;default:kl(e,n)}}function hl(e){var t=e.alternate;t!==null&&(e.alternate=null,hl(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&gt(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 gl=null,_l=!1;function vl(e,t,n){for(n=n.child;n!==null;)yl(e,t,n),n=n.sibling}function yl(e,t,n){if(Le&&typeof Le.onCommitFiberUnmount==`function`)try{Le.onCommitFiberUnmount(Ie,n)}catch{}switch(n.tag){case 26:ll||el(n,t),vl(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:ll||el(n,t);var r=gl,i=_l;uf(n.type)&&(gl=n.stateNode,_l=!1),vl(e,t,n),Tf(n.stateNode),gl=r,_l=i;break;case 5:ll||el(n,t);case 6:if(r=gl,i=_l,gl=null,vl(e,t,n),gl=r,_l=i,gl!==null)if(_l)try{(gl.nodeType===9?gl.body:gl.nodeName===`HTML`?gl.ownerDocument.body:gl).removeChild(n.stateNode)}catch(e){rd(n,t,e)}else try{gl.removeChild(n.stateNode)}catch(e){rd(n,t,e)}break;case 18:gl!==null&&(_l?(e=gl,df(e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,n.stateNode),Wp(e)):df(gl,n.stateNode));break;case 4:r=gl,i=_l,gl=n.stateNode.containerInfo,_l=!0,vl(e,t,n),gl=r,_l=i;break;case 0:case 11:case 14:case 15:Xc(2,n,t),ll||Xc(4,n,t),vl(e,t,n);break;case 1:ll||(el(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&Qc(n,t,r)),vl(e,t,n);break;case 21:vl(e,t,n);break;case 22:ll=(r=ll)||n.memoizedState!==null,vl(e,t,n),ll=r;break;default:vl(e,t,n)}}function bl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Wp(e)}catch(e){rd(t,t.return,e)}}}function xl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Wp(e)}catch(e){rd(t,t.return,e)}}function Sl(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new dl),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new dl),t;default:throw Error(a(435,e.tag))}}function Cl(e,t){var n=Sl(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=cd.bind(null,e,t);t.then(r,r)}})}function wl(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var i=n[r],o=e,s=t,c=s;a:for(;c!==null;){switch(c.tag){case 27:if(uf(c.type)){gl=c.stateNode,_l=!1;break a}break;case 5:gl=c.stateNode,_l=!1;break a;case 3:case 4:gl=c.stateNode.containerInfo,_l=!0;break a}c=c.return}if(gl===null)throw Error(a(160));yl(o,s,i),gl=null,_l=!1,o=i.alternate,o!==null&&(o.return=null),i.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)El(t,e),t=t.sibling}var Tl=null;function El(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:wl(t,e),Dl(e),r&4&&(Xc(3,e,e.return),Yc(3,e),Xc(5,e,e.return));break;case 1:wl(t,e),Dl(e),r&512&&(ll||n===null||el(n,n.return)),r&64&&cl&&(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 i=Tl;if(wl(t,e),Dl(e),r&512&&(ll||n===null||el(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,i=i.ownerDocument||i;b:switch(r){case`title`:o=i.getElementsByTagName(`title`)[0],(!o||o[ht]||o[ct]||o.namespaceURI===`http://www.w3.org/2000/svg`||o.hasAttribute(`itemprop`))&&(o=i.createElement(r),i.head.insertBefore(o,i.querySelector(`head > title`))),Kd(o,r,n),o[ct]=e,xt(o),r=o;break a;case`link`:var s=$f(`link`,`href`,i).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=i.createElement(r),Kd(o,r,n),i.head.appendChild(o);break;case`meta`:if(s=$f(`meta`,`content`,i).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=i.createElement(r),Kd(o,r,n),i.head.appendChild(o);break;default:throw Error(a(468,r))}o[ct]=e,xt(o),r=o}e.stateNode=r}else ep(i,e.type,e.stateNode);else e.stateNode=Jf(i,r,e.memoizedProps);else o===r?r===null&&e.stateNode!==null&&nl(e,e.memoizedProps,n.memoizedProps):(o===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):o.count--,r===null?ep(i,e.type,e.stateNode):Jf(i,r,e.memoizedProps))}break;case 27:wl(t,e),Dl(e),r&512&&(ll||n===null||el(n,n.return)),n!==null&&r&4&&nl(e,e.memoizedProps,n.memoizedProps);break;case 5:if(wl(t,e),Dl(e),r&512&&(ll||n===null||el(n,n.return)),e.flags&32){i=e.stateNode;try{qt(i,``)}catch(t){rd(e,e.return,t)}}r&4&&e.stateNode!=null&&(i=e.memoizedProps,nl(e,i,n===null?i:n.memoizedProps)),r&1024&&(ul=!0);break;case 6:if(wl(t,e),Dl(e),r&4){if(e.stateNode===null)throw Error(a(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){rd(e,e.return,t)}}break;case 3:if(Qf=null,i=Tl,Tl=Of(t.containerInfo),wl(t,e),Tl=i,Dl(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Wp(t.containerInfo)}catch(t){rd(e,e.return,t)}ul&&(ul=!1,Ol(e));break;case 4:r=Tl,Tl=Of(e.stateNode.containerInfo),wl(t,e),Dl(e),Tl=r;break;case 12:wl(t,e),Dl(e);break;case 31:wl(t,e),Dl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,Cl(e,r)));break;case 13:wl(t,e),Dl(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(pu=De()),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,Cl(e,r)));break;case 22:i=e.memoizedState!==null;var l=n!==null&&n.memoizedState!==null,u=cl,d=ll;if(cl=u||i,ll=d||l,wl(t,e),ll=d,cl=u,Dl(e),r&8192)a:for(t=e.stateNode,t._visibility=i?t._visibility&-2:t._visibility|1,i&&(n===null||l||cl||ll||Al(e)),n=null,t=e;;){if(t.tag===5||t.tag===26){if(n===null){l=n=t;try{if(o=l.stateNode,i)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){rd(l,l.return,e)}}}else if(t.tag===6){if(n===null){l=t;try{l.stateNode.nodeValue=i?``:l.memoizedProps}catch(e){rd(l,l.return,e)}}}else if(t.tag===18){if(n===null){l=t;try{var m=l.stateNode;i?ff(m,!0):ff(l.stateNode,!1)}catch(e){rd(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,Cl(e,n))));break;case 19:wl(t,e),Dl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,Cl(e,r)));break;case 30:break;case 21:break;default:wl(t,e),Dl(e)}}function Dl(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(rl(r)){n=r;break}r=r.return}if(n==null)throw Error(a(160));switch(n.tag){case 27:var i=n.stateNode;ol(e,il(e),i);break;case 5:var o=n.stateNode;n.flags&32&&(qt(o,``),n.flags&=-33),ol(e,il(e),o);break;case 3:case 4:var s=n.stateNode.containerInfo;al(e,il(e),s);break;default:throw Error(a(161))}}catch(t){rd(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Ol(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;Ol(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function kl(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)ml(e,t.alternate,t),t=t.sibling}function Al(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Xc(4,t,t.return),Al(t);break;case 1:el(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==`function`&&Qc(t,t.return,n),Al(t);break;case 27:Tf(t.stateNode);case 26:case 5:el(t,t.return),Al(t);break;case 22:t.memoizedState===null&&Al(t);break;case 30:Al(t);break;default:Al(t)}e=e.sibling}}function jl(e,t,n){for(n&&=(t.subtreeFlags&8772)!=0,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:jl(i,a,n),Yc(4,a);break;case 1:if(jl(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){rd(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++)$a(c[i],s)}catch(e){rd(r,r.return,e)}}n&&o&64&&Zc(a),$c(a,a.return);break;case 27:sl(a);case 26:case 5:jl(i,a,n),n&&r===null&&o&4&&tl(a),$c(a,a.return);break;case 12:jl(i,a,n);break;case 31:jl(i,a,n),n&&o&4&&bl(i,a);break;case 13:jl(i,a,n),n&&o&4&&xl(i,a);break;case 22:a.memoizedState===null&&jl(i,a,n),$c(a,a.return);break;case 30:break;default:jl(i,a,n)}t=t.sibling}}function Ml(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&&fa(n))}function Nl(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&fa(e))}function Pl(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Fl(e,t,n,r),t=t.sibling}function Fl(e,t,n,r){var i=t.flags;switch(t.tag){case 0:case 11:case 15:Pl(e,t,n,r),i&2048&&Yc(9,t);break;case 1:Pl(e,t,n,r);break;case 3:Pl(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&&fa(e)));break;case 12:if(i&2048){Pl(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){rd(t,t.return,e)}}else Pl(e,t,n,r);break;case 31:Pl(e,t,n,r);break;case 13:Pl(e,t,n,r);break;case 23:break;case 22:a=t.stateNode,o=t.alternate,t.memoizedState===null?a._visibility&2?Pl(e,t,n,r):(a._visibility|=2,Il(e,t,n,r,(t.subtreeFlags&10256)!=0||!1)):a._visibility&2?Pl(e,t,n,r):Ll(e,t),i&2048&&Ml(o,t);break;case 24:Pl(e,t,n,r),i&2048&&Nl(t.alternate,t);break;default:Pl(e,t,n,r)}}function Il(e,t,n,r,i){for(i&&=(t.subtreeFlags&10256)!=0||!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:Il(a,o,s,c,i),Yc(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,Il(a,o,s,c,i)):u._visibility&2?Il(a,o,s,c,i):Ll(a,o),i&&l&2048&&Ml(o.alternate,o);break;case 24:Il(a,o,s,c,i),i&&l&2048&&Nl(o.alternate,o);break;default:Il(a,o,s,c,i)}t=t.sibling}}function Ll(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:Ll(n,r),i&2048&&Ml(r.alternate,r);break;case 24:Ll(n,r),i&2048&&Nl(r.alternate,r);break;default:Ll(n,r)}t=t.sibling}}var Rl=8192;function zl(e,t,n){if(e.subtreeFlags&Rl)for(e=e.child;e!==null;)Bl(e,t,n),e=e.sibling}function Bl(e,t,n){switch(e.tag){case 26:zl(e,t,n),e.flags&Rl&&e.memoizedState!==null&&rp(n,Tl,e.memoizedState,e.memoizedProps);break;case 5:zl(e,t,n);break;case 3:case 4:var r=Tl;Tl=Of(e.stateNode.containerInfo),zl(e,t,n),Tl=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=Rl,Rl=16777216,zl(e,t,n),Rl=r):zl(e,t,n));break;default:zl(e,t,n)}}function Vl(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 Hl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];fl=r,Gl(r,e)}Vl(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Ul(e),e=e.sibling}function Ul(e){switch(e.tag){case 0:case 11:case 15:Hl(e),e.flags&2048&&Xc(9,e,e.return);break;case 3:Hl(e);break;case 12:Hl(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,Wl(e)):Hl(e);break;default:Hl(e)}}function Wl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];fl=r,Gl(r,e)}Vl(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Xc(8,t,t.return),Wl(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,Wl(t));break;default:Wl(t)}e=e.sibling}}function Gl(e,t){for(;fl!==null;){var n=fl;switch(n.tag){case 0:case 11:case 15:Xc(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:fa(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,fl=r;else a:for(n=e;fl!==null;){r=fl;var i=r.sibling,a=r.return;if(hl(r),r===n){fl=null;break a}if(i!==null){i.return=a,fl=i;break a}fl=a}}}var Kl={getCacheForType:function(e){var t=ia(ua),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return ia(ua).controller.signal}},ql=typeof WeakMap==`function`?WeakMap:Map,Jl=0,Yl=null,Xl=null,Zl=0,Ql=0,$l=null,eu=!1,tu=!1,nu=!1,ru=0,iu=0,au=0,ou=0,su=0,cu=0,lu=0,uu=null,du=null,fu=!1,pu=0,mu=0,hu=1/0,gu=null,_u=null,vu=0,yu=null,bu=null,xu=0,Su=0,Cu=null,wu=null,Tu=0,Eu=null;function Du(){return Jl&2&&Zl!==0?Zl&-Zl:N.T===null?at():Sd()}function Ou(){if(cu===0)if(!(Zl&536870912)||Li){var e=We;We<<=1,!(We&3932160)&&(We=262144),cu=e}else cu=536870912;return e=oo.current,e!==null&&(e.flags|=32),cu}function ku(e,t,n){(e===Yl&&(Ql===2||Ql===9)||e.cancelPendingCommit!==null)&&(Iu(e,0),Nu(e,Zl,cu,!1)),Qe(e,n),(!(Jl&2)||e!==Yl)&&(e===Yl&&(!(Jl&2)&&(ou|=n),iu===4&&Nu(e,Zl,cu,!1)),hd(e))}function Au(e,t,n){if(Jl&6)throw Error(a(327));var r=!n&&(t&127)==0&&(t&e.expiredLanes)===0||Je(e,t),i=r?Uu(e,t):Hu(e,t,!0),o=r;do{if(i===0){tu&&!r&&Nu(e,t,0,!1);break}else{if(n=e.current.alternate,o&&!Mu(n)){i=Hu(e,t,!1),o=!1;continue}if(i===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;i=uu;var l=c.current.memoizedState.isDehydrated;if(l&&(Iu(c,s).flags|=256),s=Hu(c,s,!1),s!==2){if(nu&&!l){c.errorRecoveryDisabledLanes|=o,ou|=o,i=4;break a}o=du,du=i,o!==null&&(du===null?du=o:du.push.apply(du,o))}i=s}if(o=!1,i!==2)continue}}if(i===1){Iu(e,0),Nu(e,t,0,!0);break}a:{switch(r=e,o=i,o){case 0:case 1:throw Error(a(345));case 4:if((t&4194048)!==t)break;case 6:Nu(r,t,cu,!eu);break a;case 2:du=null;break;case 3:case 5:break;default:throw Error(a(329))}if((t&62914560)===t&&(i=pu+300-De(),10<i)){if(Nu(r,t,cu,!eu),qe(r,0,!0)!==0)break a;xu=t,r.timeoutHandle=af(ju.bind(null,r,n,du,gu,fu,t,cu,ou,lu,eu,o,`Throttled`,-0,0),i);break a}ju(r,n,du,gu,fu,t,cu,ou,lu,eu,o,null,-0,0)}}break}while(1);hd(e)}function ju(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:tn},Bl(t,a,d);var m=(a&62914560)===a?pu-De():(a&4194048)===a?mu-De():0;if(m=H(d,m),m!==null){xu=a,e.cancelPendingCommit=m(R.bind(null,e,t,a,n,r,i,o,s,c,u,d,null,f,p)),Nu(e,a,o,!l);return}}R(e,t,a,n,r,i,o,s,c)}function Mu(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(!wr(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 Nu(e,t,n,r){t&=~su,t&=~ou,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-ze(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&et(e,n,t)}function Pu(){return Jl&6?!0:(gd(0,!1),!1)}function Fu(){if(Xl!==null){if(Ql===0)var e=Xl.return;else e=Xl,Xi=Yi=null,Fo(e),Fa=null,Ia=0,e=Xl;for(;e!==null;)Jc(e.alternate,e),e=e.return;Xl=null}}function Iu(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,of(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),xu=0,Fu(),Yl=e,Xl=n=fi(e.current,null),Zl=t,Ql=0,$l=null,eu=!1,tu=Je(e,t),nu=!1,lu=cu=su=ou=au=iu=0,du=uu=null,fu=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var i=31-ze(r),a=1<<i;t|=e[i],r&=~a}return ru=t,ni(),n}function Lu(e,t){_o=null,N.H=Gs,t===Ta||t===Da?(t=Na(),Ql=3):t===Ea?(t=Na(),Ql=4):Ql=t===lc?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,$l=t,Xl===null&&(iu=1,rc(e,bi(t,e.current)))}function Ru(){var e=oo.current;return e===null?!0:(Zl&4194048)===Zl?so===null:(Zl&62914560)===Zl||Zl&536870912?e===so:!1}function zu(){var e=N.H;return N.H=Gs,e===null?Gs:e}function Bu(){var e=N.A;return N.A=Kl,e}function Vu(){iu=4,eu||(Zl&4194048)!==Zl&&oo.current!==null||(tu=!0),!(au&134217727)&&!(ou&134217727)||Yl===null||Nu(Yl,Zl,cu,!1)}function Hu(e,t,n){var r=Jl;Jl|=2;var i=zu(),a=Bu();(Yl!==e||Zl!==t)&&(gu=null,Iu(e,t)),t=!1;var o=iu;a:do try{if(Ql!==0&&Xl!==null){var s=Xl,c=$l;switch(Ql){case 8:Fu(),o=6;break a;case 3:case 2:case 9:case 6:oo.current===null&&(t=!0);var l=Ql;if(Ql=0,$l=null,qu(e,s,c,l),n&&tu){o=0;break a}break;default:l=Ql,Ql=0,$l=null,qu(e,s,c,l)}}L(),o=iu;break}catch(t){Lu(e,t)}while(1);return t&&e.shellSuspendCounter++,Xi=Yi=null,Jl=r,N.H=i,N.A=a,Xl===null&&(Yl=null,Zl=0,ni()),o}function L(){for(;Xl!==null;)Gu(Xl)}function Uu(e,t){var n=Jl;Jl|=2;var r=zu(),i=Bu();Yl!==e||Zl!==t?(gu=null,hu=De()+500,Iu(e,t)):tu=Je(e,t);a:do try{if(Ql!==0&&Xl!==null){t=Xl;var o=$l;b:switch(Ql){case 1:Ql=0,$l=null,qu(e,t,o,1);break;case 2:case 9:if(ka(o)){Ql=0,$l=null,Ku(t);break}t=function(){Ql!==2&&Ql!==9||Yl!==e||(Ql=7),hd(e)},o.then(t,t);break a;case 3:Ql=7;break a;case 4:Ql=5;break a;case 7:ka(o)?(Ql=0,$l=null,Ku(t)):(Ql=0,$l=null,qu(e,t,o,7));break;case 5:var s=null;switch(Xl.tag){case 26:s=Xl.memoizedState;case 5:case 27:var c=Xl;if(s?np(s):c.stateNode.complete){Ql=0,$l=null;var l=c.sibling;if(l!==null)Xl=l;else{var u=c.return;u===null?Xl=null:(Xl=u,Ju(u))}break b}}Ql=0,$l=null,qu(e,t,o,5);break;case 6:Ql=0,$l=null,qu(e,t,o,6);break;case 8:Fu(),iu=6;break a;default:throw Error(a(462))}}Wu();break}catch(t){Lu(e,t)}while(1);return Xi=Yi=null,N.H=r,N.A=i,Jl=n,Xl===null?(Yl=null,Zl=0,ni(),iu):0}function Wu(){for(;Xl!==null&&!Te();)Gu(Xl)}function Gu(e){var t=zc(e.alternate,e,ru);e.memoizedProps=e.pendingProps,t===null?Ju(e):Xl=t}function Ku(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=Cc(n,t,t.pendingProps,t.type,void 0,Zl);break;case 11:t=Cc(n,t,t.pendingProps,t.type.render,t.ref,Zl);break;case 5:Fo(t);default:Jc(n,t),t=Xl=pi(t,ru),t=zc(n,t,ru)}e.memoizedProps=e.pendingProps,t===null?Ju(e):Xl=t}function qu(e,t,n,r){Xi=Yi=null,Fo(t),Fa=null,Ia=0;var i=t.return;try{if(cc(e,i,t,n,Zl)){iu=1,rc(e,bi(n,e.current)),Xl=null;return}}catch(t){if(i!==null)throw Xl=i,t;iu=1,rc(e,bi(n,e.current)),Xl=null;return}t.flags&32768?(Li||r===1?e=!0:tu||Zl&536870912?e=!1:(eu=e=!0,(r===2||r===9||r===3||r===6)&&(r=oo.current,r!==null&&r.tag===13&&(r.flags|=16384))),Yu(t,e)):Ju(t)}function Ju(e){var t=e;do{if(t.flags&32768){Yu(t,eu);return}e=t.return;var n=Kc(t.alternate,t,ru);if(n!==null){Xl=n;return}if(t=t.sibling,t!==null){Xl=t;return}Xl=t=e}while(t!==null);iu===0&&(iu=5)}function Yu(e,t){do{var n=qc(e.alternate,e);if(n!==null){n.flags&=32767,Xl=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){Xl=e;return}Xl=e=n}while(e!==null);iu=6,Xl=null}function R(e,t,n,r,i,o,s,c,l){e.cancelPendingCommit=null;do ed();while(vu!==0);if(Jl&6)throw Error(a(327));if(t!==null){if(t===e.current)throw Error(a(177));if(o=t.lanes|t.childLanes,o|=ti,$e(e,n,o,s,c,l),e===Yl&&(Xl=Yl=null,Zl=0),bu=t,yu=e,xu=n,Su=o,Cu=i,wu=r,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,ld(je,function(){return td(),null})):(e.callbackNode=null,e.callbackPriority=0),r=(t.flags&13878)!=0,t.subtreeFlags&13878||r){r=N.T,N.T=null,i=P.p,P.p=2,s=Jl,Jl|=4;try{pl(e,t,n)}finally{Jl=s,P.p=i,N.T=r}}vu=1,Xu(),Zu(),Qu()}}function Xu(){if(vu===1){vu=0;var e=yu,t=bu,n=(t.flags&13878)!=0;if(t.subtreeFlags&13878||n){n=N.T,N.T=null;var r=P.p;P.p=2;var i=Jl;Jl|=4;try{El(t,e);var a=Zd,o=kr(e.containerInfo),s=a.focusedElem,c=a.selectionRange;if(o!==s&&s&&s.ownerDocument&&Or(s.ownerDocument.documentElement,s)){if(c!==null&&Ar(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 _=Dr(s,h),v=Dr(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}}vp=!!Xd,Zd=Xd=null}finally{Jl=i,P.p=r,N.T=n}}e.current=t,vu=2}}function Zu(){if(vu===2){vu=0;var e=yu,t=bu,n=(t.flags&8772)!=0;if(t.subtreeFlags&8772||n){n=N.T,N.T=null;var r=P.p;P.p=2;var i=Jl;Jl|=4;try{ml(e,t.alternate,t)}finally{Jl=i,P.p=r,N.T=n}}vu=3}}function Qu(){if(vu===4||vu===3){vu=0,Ee();var e=yu,t=bu,n=xu,r=wu;t.subtreeFlags&10256||t.flags&10256?vu=5:(vu=0,bu=yu=null,$u(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(_u=null),it(n),t=t.stateNode,Le&&typeof Le.onCommitFiberRoot==`function`)try{Le.onCommitFiberRoot(Ie,t,void 0,(t.current.flags&128)==128)}catch{}if(r!==null){t=N.T,i=P.p,P.p=2,N.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{N.T=t,P.p=i}}xu&3&&ed(),hd(e),i=e.pendingLanes,n&261930&&i&42?e===Eu?Tu++:(Tu=0,Eu=e):Tu=0,gd(0,!1)}}function $u(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,fa(t)))}function ed(){return Xu(),Zu(),Qu(),td()}function td(){if(vu!==5)return!1;var e=yu,t=Su;Su=0;var n=it(xu),r=N.T,i=P.p;try{P.p=32>n?32:n,N.T=null,n=Cu,Cu=null;var o=yu,s=xu;if(vu=0,bu=yu=null,xu=0,Jl&6)throw Error(a(331));var c=Jl;if(Jl|=4,Ul(o.current),Fl(o,o.current,s,n),Jl=c,gd(0,!1),Le&&typeof Le.onPostCommitFiberRoot==`function`)try{Le.onPostCommitFiberRoot(Ie,o)}catch{}return!0}finally{P.p=i,N.T=r,$u(e,t)}}function nd(e,t,n){t=bi(n,t),t=ac(e.stateNode,t,2),e=qa(e,t,2),e!==null&&(Qe(e,2),hd(e))}function rd(e,t,n){if(e.tag===3)nd(e,e,n);else for(;t!==null;){if(t.tag===3){nd(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(_u===null||!_u.has(r))){e=bi(n,e),n=oc(2),r=qa(t,n,2),r!==null&&(sc(n,r,t,e),Qe(r,2),hd(r));break}}t=t.return}}function id(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new ql;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)||(nu=!0,i.add(n),e=ad.bind(null,e,t,n),t.then(e,e))}function ad(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Yl===e&&(Zl&n)===n&&(iu===4||iu===3&&(Zl&62914560)===Zl&&300>De()-pu?!(Jl&2)&&Iu(e,0):su|=n,lu===Zl&&(lu=0)),hd(e)}function od(e,t){t===0&&(t=Xe()),e=ai(e,t),e!==null&&(Qe(e,t),hd(e))}function sd(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),od(e,n)}function cd(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(a(314))}r!==null&&r.delete(t),od(e,n)}function ld(e,t){return Ce(e,t)}var ud=null,dd=null,fd=!1,pd=!1,z=!1,md=0;function hd(e){e!==dd&&e.next===null&&(dd===null?ud=dd=e:dd=dd.next=e),pd=!0,fd||(fd=!0,B())}function gd(e,t){if(!z&&pd){z=!0;do for(var n=!1,r=ud;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-ze(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,xd(r,a))}else a=Zl,a=qe(r,r===Yl?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||Je(r,a)||(n=!0,xd(r,a));r=r.next}while(n);z=!1}}function _d(){vd()}function vd(){pd=fd=!1;var e=0;md!==0&&rf()&&(e=md);for(var t=De(),n=null,r=ud;r!==null;){var i=r.next,a=yd(r,t);a===0?(r.next=null,n===null?ud=i:n.next=i,i===null&&(dd=n)):(n=r,(e!==0||a&3)&&(pd=!0)),r=i}vu!==0&&vu!==5||gd(e,!1),md!==0&&(md=0)}function yd(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-ze(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=Ye(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=Yl,n=Zl,n=qe(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(Ql===2||Ql===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&we(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||Je(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&we(r),it(n)){case 2:case 8:n=Ae;break;case 32:n=je;break;case 268435456:n=Ne;break;default:n=je}return r=bd.bind(null,e),n=Ce(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&we(r),e.callbackPriority=2,e.callbackNode=null,2}function bd(e,t){if(vu!==0&&vu!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(ed()&&e.callbackNode!==n)return null;var r=Zl;return r=qe(e,e===Yl?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(Au(e,r,t),yd(e,De()),e.callbackNode!=null&&e.callbackNode===n?bd.bind(null,e):null)}function xd(e,t){if(ed())return null;Au(e,t,!0)}function B(){cf(function(){Jl&6?Ce(ke,_d):vd()})}function Sd(){if(md===0){var e=ha;e===0&&(e=Ue,Ue<<=1,!(Ue&261888)&&(Ue=256)),md=e}return md}function Cd(e){return e==null||typeof e==`symbol`||typeof e==`boolean`?null:typeof e==`function`?e:en(``+e)}function V(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 wd(e,t,n,r,i){if(t===`submit`&&n&&n.stateNode===i){var a=Cd((i[lt]||null).action),o=r.submitter;o&&(t=(t=o[lt]||null)?Cd(t.formAction):o.getAttribute(`formAction`),t!==null&&(a=t,o=null));var s=new Cn(`action`,`action`,null,r,i);e.push({event:s,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(md!==0){var e=o?V(i,o):new FormData(i);js(n,{pending:!0,data:e,method:i.method,action:a},null,e)}}else typeof a==`function`&&(s.preventDefault(),e=o?V(i,o):new FormData(i),js(n,{pending:!0,data:e,method:i.method,action:a},a,e))},currentTarget:i}]})}}for(var Td=0;Td<Xr.length;Td++){var Ed=Xr[Td];Zr(Ed.toLowerCase(),`on`+(Ed[0].toUpperCase()+Ed.slice(1)))}Zr(Hr,`onAnimationEnd`),Zr(Ur,`onAnimationIteration`),Zr(Wr,`onAnimationStart`),Zr(`dblclick`,`onDoubleClick`),Zr(`focusin`,`onFocus`),Zr(`focusout`,`onBlur`),Zr(Gr,`onTransitionRun`),Zr(Kr,`onTransitionStart`),Zr(qr,`onTransitionCancel`),Zr(Jr,`onTransitionEnd`),Tt(`onMouseEnter`,[`mouseout`,`mouseover`]),Tt(`onMouseLeave`,[`mouseout`,`mouseover`]),Tt(`onPointerEnter`,[`pointerout`,`pointerover`]),Tt(`onPointerLeave`,[`pointerout`,`pointerover`]),wt(`onChange`,`change click focusin focusout input keydown keyup selectionchange`.split(` `)),wt(`onSelect`,`focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange`.split(` `)),wt(`onBeforeInput`,[`compositionend`,`keypress`,`textInput`,`paste`]),wt(`onCompositionEnd`,`compositionend focusout keydown keypress keyup mousedown`.split(` `)),wt(`onCompositionStart`,`compositionstart focusout keydown keypress keyup mousedown`.split(` `)),wt(`onCompositionUpdate`,`compositionupdate focusout keydown keypress keyup mousedown`.split(` `));var Dd=`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(` `),Od=new Set(`beforetoggle cancel close invalid load scroll scrollend toggle`.split(` `).concat(Dd));function kd(e,t){t=(t&4)!=0;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){Qr(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){Qr(e)}i.currentTarget=null,a=c}}}}function Ad(e,t){var n=t[dt];n===void 0&&(n=t[dt]=new Set);var r=e+`__bubble`;n.has(r)||(Pd(t,e,2,!1),n.add(r))}function jd(e,t,n){var r=0;t&&(r|=4),Pd(n,e,r,t)}var Md=`_reactListening`+Math.random().toString(36).slice(2);function Nd(e){if(!e[Md]){e[Md]=!0,St.forEach(function(t){t!==`selectionchange`&&(Od.has(t)||jd(t,!1,e),jd(t,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Md]||(t[Md]=!0,jd(`selectionchange`,!1,t))}}function Pd(e,t,n,r){switch(Tp(t)){case 2:var i=yp;break;case 8:i=bp;break;default:i=xp}n=i.bind(null,t,n,e),i=void 0,!fn||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 Fd(e,t,n,r,i){var a=r;if(!(t&1)&&!(t&2)&&r!==null)a:for(;;){if(r===null)return;var o=r.tag;if(o===3||o===4){var s=r.stateNode.containerInfo;if(s===i)break;if(o===4)for(o=r.return;o!==null;){var c=o.tag;if((c===3||c===4)&&o.stateNode.containerInfo===i)return;o=o.return}for(;s!==null;){if(o=_t(s),o===null)return;if(c=o.tag,c===5||c===6||c===26||c===27){r=a=o;continue a}s=s.parentNode}}r=r.return}ln(function(){var r=a,i=rn(n),o=[];a:{var s=Yr.get(e);if(s!==void 0){var c=Cn,u=e;switch(e){case`keypress`:if(vn(n)===0)break a;case`keydown`:case`keyup`:c=Vn;break;case`focusin`:u=`focus`,c=Mn;break;case`focusout`:u=`blur`,c=Mn;break;case`beforeblur`:case`afterblur`:c=Mn;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`:c=An;break;case`drag`:case`dragend`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`dragstart`:case`drop`:c=jn;break;case`touchcancel`:case`touchend`:case`touchmove`:case`touchstart`:c=Un;break;case Hr:case Ur:case Wr:c=Nn;break;case Jr:c=Wn;break;case`scroll`:case`scrollend`:c=Tn;break;case`wheel`:c=Gn;break;case`copy`:case`cut`:case`paste`:c=Pn;break;case`gotpointercapture`:case`lostpointercapture`:case`pointercancel`:case`pointerdown`:case`pointermove`:case`pointerout`:case`pointerover`:case`pointerup`:c=Hn;break;case`toggle`:case`beforetoggle`:c=Kn}var d=(t&4)!=0,f=!d&&(e===`scroll`||e===`scrollend`),p=d?s===null?null:s+`Capture`:s;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=un(m,p),g!=null&&d.push(Id(m,g,h))),f)break;m=m.return}0<d.length&&(s=new c(s,u,null,n,i),o.push({event:s,listeners:d}))}}if(!(t&7)){a:{if(s=e===`mouseover`||e===`pointerover`,c=e===`mouseout`||e===`pointerout`,s&&n!==nn&&(u=n.relatedTarget||n.fromElement)&&(_t(u)||u[ut]))break a;if((c||s)&&(s=i.window===i?i:(s=i.ownerDocument)?s.defaultView||s.parentWindow:window,c?(u=n.relatedTarget||n.toElement,c=r,u=u?_t(u):null,u!==null&&(f=l(u),d=u.tag,u!==f||d!==5&&d!==27&&d!==6)&&(u=null)):(c=null,u=r),c!==u)){if(d=An,g=`onMouseLeave`,p=`onMouseEnter`,m=`mouse`,(e===`pointerout`||e===`pointerover`)&&(d=Hn,g=`onPointerLeave`,p=`onPointerEnter`,m=`pointer`),f=c==null?s:yt(c),h=u==null?s:yt(u),s=new d(g,m+`leave`,c,n,i),s.target=f,s.relatedTarget=h,g=null,_t(i)===r&&(d=new d(p,m+`enter`,u,n,i),d.target=h,d.relatedTarget=f,g=d),f=g,c&&u)b:{for(d=Rd,p=c,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;c!==null&&zd(o,s,c,d,!1),u!==null&&f!==null&&zd(o,f,u,d,!0)}}a:{if(s=r?yt(r):window,c=s.nodeName&&s.nodeName.toLowerCase(),c===`select`||c===`input`&&s.type===`file`)var v=fr;else if(or(s))if(pr)v=Sr;else{v=br;var y=yr}else c=s.nodeName,!c||c.toLowerCase()!==`input`||s.type!==`checkbox`&&s.type!==`radio`?r&&Zt(r.elementType)&&(v=fr):v=xr;if(v&&=v(e,r)){sr(o,v,n,i);break a}y&&y(e,s,r),e===`focusout`&&r&&s.type===`number`&&r.memoizedProps.value!=null&&Ut(s,`number`,s.value)}switch(y=r?yt(r):window,e){case`focusin`:(or(y)||y.contentEditable===`true`)&&(Mr=y,Nr=r,Pr=null);break;case`focusout`:Pr=Nr=Mr=null;break;case`mousedown`:Fr=!0;break;case`contextmenu`:case`mouseup`:case`dragend`:Fr=!1,Ir(o,n,i);break;case`selectionchange`:if(jr)break;case`keydown`:case`keyup`:Ir(o,n,i)}var b;if(Jn)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 nr?er(e,n)&&(x=`onCompositionEnd`):e===`keydown`&&n.keyCode===229&&(x=`onCompositionStart`);x&&(Zn&&n.locale!==`ko`&&(nr||x!==`onCompositionStart`?x===`onCompositionEnd`&&nr&&(b=_n()):(mn=i,hn=`value`in mn?mn.value:mn.textContent,nr=!0)),y=Ld(r,x),0<y.length&&(x=new Fn(x,e,null,n,i),o.push({event:x,listeners:y}),b?x.data=b:(b=tr(n),b!==null&&(x.data=b)))),(b=Xn?rr(e,n):ir(e,n))&&(x=Ld(r,`onBeforeInput`),0<x.length&&(y=new Fn(`onBeforeInput`,`beforeinput`,null,n,i),o.push({event:y,listeners:x}),y.data=b)),wd(o,e,r,n,i)}kd(o,t)})}function Id(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Ld(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=un(e,n),i!=null&&r.unshift(Id(e,i,a)),i=un(e,t),i!=null&&r.push(Id(e,i,a))),e.tag===3)return r;e=e.return}return[]}function Rd(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function zd(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=un(n,a),l!=null&&o.unshift(Id(n,l,c))):i||(l=un(n,a),l!=null&&o.push(Id(n,l,c)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var Bd=/\r\n?/g,Vd=/\u0000|\uFFFD/g;function Hd(e){return(typeof e==`string`?e:``+e).replace(Bd,`
10
- `).replace(Vd,``)}function Ud(e,t){return t=Hd(t),Hd(e)===t}function Wd(e,t,n,r,i,o){switch(n){case`children`:typeof r==`string`?t===`body`||t===`textarea`&&r===``||qt(e,r):(typeof r==`number`||typeof r==`bigint`)&&t!==`body`&&qt(e,``+r);break;case`className`:jt(e,`class`,r);break;case`tabIndex`:jt(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:jt(e,n,r);break;case`style`:Xt(e,r,o);break;case`data`:if(t!==`object`){jt(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=en(``+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}else typeof o==`function`&&(n===`formAction`?(t!==`input`&&Wd(e,t,`name`,i.name,i,null),Wd(e,t,`formEncType`,i.formEncType,i,null),Wd(e,t,`formMethod`,i.formMethod,i,null),Wd(e,t,`formTarget`,i.formTarget,i,null)):(Wd(e,t,`encType`,i.encType,i,null),Wd(e,t,`method`,i.method,i,null),Wd(e,t,`target`,i.target,i,null)));if(r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=en(``+r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=tn);break;case`onScroll`:r!=null&&Ad(`scroll`,e);break;case`onScrollEnd`:r!=null&&Ad(`scrollend`,e);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(a(61));if(n=r.__html,n!=null){if(i.children!=null)throw Error(a(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=en(``+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`:Ad(`beforetoggle`,e),Ad(`toggle`,e),At(e,`popover`,r);break;case`xlinkActuate`:Mt(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:Mt(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:Mt(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:Mt(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:Mt(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:Mt(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:Mt(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:Mt(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:Mt(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:At(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=Qt.get(n)||n,At(e,n,r))}}function Gd(e,t,n,r,i,o){switch(n){case`style`:Xt(e,r,o);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(a(61));if(n=r.__html,n!=null){if(i.children!=null)throw Error(a(60));e.innerHTML=n}}break;case`children`:typeof r==`string`?qt(e,r):(typeof r==`number`||typeof r==`bigint`)&&qt(e,``+r);break;case`onScroll`:r!=null&&Ad(`scroll`,e);break;case`onScrollEnd`:r!=null&&Ad(`scrollend`,e);break;case`onClick`:r!=null&&(e.onclick=tn);break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:break;case`innerText`:case`textContent`:break;default:if(!Ct.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(i=n.endsWith(`Capture`),t=n.slice(2,i?n.length-7:void 0),o=e[lt]||null,o=o==null?null:o[n],typeof o==`function`&&e.removeEventListener(t,o,i),typeof r==`function`)){typeof o!=`function`&&o!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,i);break a}n in e?e[n]=r:!0===r?e.setAttribute(n,``):At(e,n,r)}}}function Kd(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:Ad(`error`,e),Ad(`load`,e);var r=!1,i=!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`:i=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(a(137,t));default:Wd(e,t,o,s,n,null)}}i&&Wd(e,t,`srcSet`,n.srcSet,n,null),r&&Wd(e,t,`src`,n.src,n,null);return;case`input`:Ad(`invalid`,e);var c=o=s=i=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:i=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(a(137,t));break;default:Wd(e,t,r,d,n,null)}}Ht(e,o,c,l,u,s,i,!1);return;case`select`:for(i in Ad(`invalid`,e),r=s=o=null,n)if(n.hasOwnProperty(i)&&(c=n[i],c!=null))switch(i){case`value`:o=c;break;case`defaultValue`:s=c;break;case`multiple`:r=c;default:Wd(e,t,i,c,n,null)}t=o,n=s,e.multiple=!!r,t==null?n!=null&&Wt(e,!!r,n,!0):Wt(e,!!r,t,!1);return;case`textarea`:for(s in Ad(`invalid`,e),o=i=r=null,n)if(n.hasOwnProperty(s)&&(c=n[s],c!=null))switch(s){case`value`:r=c;break;case`defaultValue`:i=c;break;case`children`:o=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(a(91));break;default:Wd(e,t,s,c,n,null)}Kt(e,r,i,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:Wd(e,t,l,r,n,null)}return;case`dialog`:Ad(`beforetoggle`,e),Ad(`toggle`,e),Ad(`cancel`,e),Ad(`close`,e);break;case`iframe`:case`object`:Ad(`load`,e);break;case`video`:case`audio`:for(r=0;r<Dd.length;r++)Ad(Dd[r],e);break;case`image`:Ad(`error`,e),Ad(`load`,e);break;case`details`:Ad(`toggle`,e);break;case`embed`:case`source`:case`link`:Ad(`error`,e),Ad(`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(a(137,t));default:Wd(e,t,u,r,n,null)}return;default:if(Zt(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Gd(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&Wd(e,t,c,r,n,null))}function qd(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 i=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)||Wd(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`:i=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(a(137,t));break;default:m!==f&&Wd(e,t,p,m,r,f)}}Vt(e,s,c,l,u,d,o,i);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)||Wd(e,t,o,null,r,l)}for(i in r)if(o=r[i],l=n[i],r.hasOwnProperty(i)&&(o!=null||l!=null))switch(i){case`value`:p=o;break;case`defaultValue`:c=o;break;case`multiple`:s=o;default:o!==l&&Wd(e,t,i,o,r,l)}t=c,n=s,r=m,p==null?!!r!=!!n&&(t==null?Wt(e,!!n,n?[]:``,!1):Wt(e,!!n,t,!0)):Wt(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(i=n[c],n.hasOwnProperty(c)&&i!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:Wd(e,t,c,null,r,i)}for(s in r)if(i=r[s],o=n[s],r.hasOwnProperty(s)&&(i!=null||o!=null))switch(s){case`value`:p=i;break;case`defaultValue`:m=i;break;case`children`:break;case`dangerouslySetInnerHTML`:if(i!=null)throw Error(a(91));break;default:i!==o&&Wd(e,t,s,i,r,o)}Gt(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:Wd(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:Wd(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)&&Wd(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(a(137,t));break;default:Wd(e,t,u,p,r,m)}return;default:if(Zt(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&Gd(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||Gd(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&Wd(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||Wd(e,t,f,p,r,m)}function Jd(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Yd(){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&&Jd(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&&Jd(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 Xd=null,Zd=null;function Qd(e){return e.nodeType===9?e:e.ownerDocument}function $d(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 ef(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 tf(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 nf=null;function rf(){var e=window.event;return e&&e.type===`popstate`?e===nf?!1:(nf=e,!0):(nf=null,!1)}var af=typeof setTimeout==`function`?setTimeout:void 0,of=typeof clearTimeout==`function`?clearTimeout:void 0,sf=typeof Promise==`function`?Promise:void 0,cf=typeof queueMicrotask==`function`?queueMicrotask:sf===void 0?af:function(e){return sf.resolve(null).then(e).catch(lf)};function lf(e){setTimeout(function(){throw e})}function uf(e){return e===`head`}function df(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),Wp(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)Tf(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,Tf(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[ht]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&Tf(e.ownerDocument.body);n=i}while(n);Wp(t)}function ff(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 pf(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`:pf(n),gt(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function mf(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[ht])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=bf(e.nextSibling),e===null)break}return null}function hf(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=bf(e.nextSibling),e===null))return null;return e}function gf(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=bf(e.nextSibling),e===null))return null;return e}function _f(e){return e.data===`$?`||e.data===`$~`}function vf(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function yf(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 bf(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 xf=null;function Sf(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return bf(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function Cf(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 wf(e,t,n){switch(t=Qd(n),e){case`html`:if(e=t.documentElement,!e)throw Error(a(452));return e;case`head`:if(e=t.head,!e)throw Error(a(453));return e;case`body`:if(e=t.body,!e)throw Error(a(454));return e;default:throw Error(a(451))}}function Tf(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);gt(e)}var Ef=new Map,Df=new Set;function Of(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var kf=P.d;P.d={f:Af,r:jf,D:Pf,C:Ff,L:If,m:Lf,X:zf,S:Rf,M:Bf};function Af(){var e=kf.f(),t=Pu();return e||t}function jf(e){var t=vt(e);t!==null&&t.tag===5&&t.type===`form`?Ns(t):kf.r(e)}var Mf=typeof document>`u`?null:document;function Nf(e,t,n){var r=Mf;if(r&&typeof t==`string`&&t){var i=Bt(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),Df.has(i)||(Df.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Kd(t,`link`,e),xt(t),r.head.appendChild(t)))}}function Pf(e){kf.D(e),Nf(`dns-prefetch`,e,null)}function Ff(e,t){kf.C(e,t),Nf(`preconnect`,e,t)}function If(e,t,n){kf.L(e,t,n);var r=Mf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Bt(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Bt(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Bt(n.imageSizes)+`"]`)):i+=`[href="`+Bt(e)+`"]`;var a=i;switch(t){case`style`:a=Hf(e);break;case`script`:a=Kf(e)}Ef.has(a)||(e=h({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),Ef.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(Uf(a))||t===`script`&&r.querySelector(qf(a))||(t=r.createElement(`link`),Kd(t,`link`,e),xt(t),r.head.appendChild(t)))}}function Lf(e,t){kf.m(e,t);var n=Mf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Bt(r)+`"][href="`+Bt(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Kf(e)}if(!Ef.has(a)&&(e=h({rel:`modulepreload`,href:e},t),Ef.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(qf(a)))return}r=n.createElement(`link`),Kd(r,`link`,e),xt(r),n.head.appendChild(r)}}}function Rf(e,t,n){kf.S(e,t,n);var r=Mf;if(r&&e){var i=bt(r).hoistableStyles,a=Hf(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(Uf(a)))s.loading=5;else{e=h({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=Ef.get(a))&&Xf(e,n);var c=o=r.createElement(`link`);xt(c),Kd(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,Yf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function zf(e,t){kf.X(e,t);var n=Mf;if(n&&e){var r=bt(n).hoistableScripts,i=Kf(e),a=r.get(i);a||(a=n.querySelector(qf(i)),a||(e=h({src:e,async:!0},t),(t=Ef.get(i))&&Zf(e,t),a=n.createElement(`script`),xt(a),Kd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Bf(e,t){kf.M(e,t);var n=Mf;if(n&&e){var r=bt(n).hoistableScripts,i=Kf(e),a=r.get(i);a||(a=n.querySelector(qf(i)),a||(e=h({src:e,async:!0,type:`module`},t),(t=Ef.get(i))&&Zf(e,t),a=n.createElement(`script`),xt(a),Kd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Vf(e,t,n,r){var i=(i=le.current)?Of(i):null;if(!i)throw Error(a(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Hf(n.href),n=bt(i).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=Hf(n.href);var o=bt(i).hoistableStyles,s=o.get(e);if(s||(i=i.ownerDocument||i,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=i.querySelector(Uf(e)))&&!o._p&&(s.instance=o,s.state.loading=5),Ef.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},Ef.set(e,n),o||Gf(i,e,n,s.state))),t&&r===null)throw Error(a(528,``));return s}if(t&&r!==null)throw Error(a(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Kf(n),n=bt(i).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(a(444,e))}}function Hf(e){return`href="`+Bt(e)+`"`}function Uf(e){return`link[rel="stylesheet"][`+e+`]`}function Wf(e){return h({},e,{"data-precedence":e.precedence,precedence:null})}function Gf(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}),Kd(t,`link`,n),xt(t),e.head.appendChild(t))}function Kf(e){return`[src="`+Bt(e)+`"]`}function qf(e){return`script[async]`+e}function Jf(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Bt(n.href)+`"]`);if(r)return t.instance=r,xt(r),r;var i=h({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),xt(r),Kd(r,`style`,i),Yf(r,n.precedence,e),t.instance=r;case`stylesheet`:i=Hf(n.href);var o=e.querySelector(Uf(i));if(o)return t.state.loading|=4,t.instance=o,xt(o),o;r=Wf(n),(i=Ef.get(i))&&Xf(r,i),o=(e.ownerDocument||e).createElement(`link`),xt(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Kd(o,`link`,r),t.state.loading|=4,Yf(o,n.precedence,e),t.instance=o;case`script`:return o=Kf(n.src),(i=e.querySelector(qf(o)))?(t.instance=i,xt(i),i):(r=n,(i=Ef.get(o))&&(r=h({},n),Zf(r,i)),e=e.ownerDocument||e,i=e.createElement(`script`),xt(i),Kd(i,`link`,r),e.head.appendChild(i),t.instance=i);case`void`:return null;default:throw Error(a(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Yf(r,n.precedence,e));return t.instance}function Yf(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 Xf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function Zf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var Qf=null;function $f(e,t,n){if(Qf===null){var r=new Map,i=Qf=new Map;i.set(n,r)}else i=Qf,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[ht]||a[ct]||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 ep(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function tp(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 np(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function rp(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=Hf(r.href),a=t.querySelector(Uf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=ap.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,xt(a);return}a=t.ownerDocument||t,r=Wf(r),(i=Ef.get(i))&&Xf(r,i),a=a.createElement(`link`),xt(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Kd(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=ap.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var ip=0;function H(e,t){return e.stylesheets&&e.count===0&&sp(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&sp(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&ip===0&&(ip=62500*Yd());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&sp(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>ip?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function ap(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)sp(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var op=null;function sp(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,op=new Map,t.forEach(cp,e),op=null,ap.call(e))}function cp(e,t){if(!(t.state.loading&4)){var n=op.get(e);if(n)var r=n.get(null);else{n=new Map,op.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=ap.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 lp={$$typeof:C,Provider:null,Consumer:null,_currentValue:re,_currentValue2:re,_threadCount:0};function up(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=Ze(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ze(0),this.hiddenUpdates=Ze(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 dp(e,t,n,r,i,a,o,s,c,l,u,d){return e=new up(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=ui(3,null,null,t),e.current=a,a.stateNode=e,t=da(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},Wa(a),e}function fp(e){return e?(e=ci,e):ci}function pp(e,t,n,r,i,a){i=fp(i),r.context===null?r.context=i:r.pendingContext=i,r=Ka(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=qa(e,r,t),n!==null&&(ku(n,e,t),Ja(n,e,t))}function mp(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function hp(e,t){mp(e,t),(e=e.alternate)&&mp(e,t)}function gp(e){if(e.tag===13||e.tag===31){var t=ai(e,67108864);t!==null&&ku(t,e,67108864),hp(e,67108864)}}function _p(e){if(e.tag===13||e.tag===31){var t=Du();t=rt(t);var n=ai(e,t);n!==null&&ku(n,e,t),hp(e,t)}}var vp=!0;function yp(e,t,n,r){var i=N.T;N.T=null;var a=P.p;try{P.p=2,xp(e,t,n,r)}finally{P.p=a,N.T=i}}function bp(e,t,n,r){var i=N.T;N.T=null;var a=P.p;try{P.p=8,xp(e,t,n,r)}finally{P.p=a,N.T=i}}function xp(e,t,n,r){if(vp){var i=Sp(r);if(i===null)Fd(e,t,r,Cp,n),Pp(e,r);else if(Ip(i,e,t,n,r))r.stopPropagation();else if(Pp(e,r),t&4&&-1<Np.indexOf(e)){for(;i!==null;){var a=vt(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=Ke(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-ze(o);s.entanglements[1]|=c,o&=~c}hd(a),!(Jl&6)&&(hu=De()+500,gd(0,!1))}}break;case 31:case 13:s=ai(a,2),s!==null&&ku(s,a,2),Pu(),hp(a,2)}if(a=Sp(r),a===null&&Fd(e,t,r,Cp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Fd(e,t,r,null,n)}}function Sp(e){return e=rn(e),wp(e)}var Cp=null;function wp(e){if(Cp=null,e=_t(e),e!==null){var t=l(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=u(t),e!==null)return e;e=null}else if(n===31){if(e=d(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 Cp=e,null}function Tp(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(Oe()){case ke:return 2;case Ae:return 8;case je:case Me:return 32;case Ne:return 268435456;default:return 32}default:return 32}}var Ep=!1,Dp=null,Op=null,kp=null,Ap=new Map,jp=new Map,Mp=[],Np=`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 Pp(e,t){switch(e){case`focusin`:case`focusout`:Dp=null;break;case`dragenter`:case`dragleave`:Op=null;break;case`mouseover`:case`mouseout`:kp=null;break;case`pointerover`:case`pointerout`:Ap.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:jp.delete(t.pointerId)}}function Fp(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=vt(t),t!==null&&gp(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function Ip(e,t,n,r,i){switch(t){case`focusin`:return Dp=Fp(Dp,e,t,n,r,i),!0;case`dragenter`:return Op=Fp(Op,e,t,n,r,i),!0;case`mouseover`:return kp=Fp(kp,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return Ap.set(a,Fp(Ap.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,jp.set(a,Fp(jp.get(a)||null,e,t,n,r,i)),!0}return!1}function Lp(e){var t=_t(e.target);if(t!==null){var n=l(t);if(n!==null){if(t=n.tag,t===13){if(t=u(n),t!==null){e.blockedOn=t,ot(e.priority,function(){_p(n)});return}}else if(t===31){if(t=d(n),t!==null){e.blockedOn=t,ot(e.priority,function(){_p(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 Rp(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=Sp(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);nn=r,n.target.dispatchEvent(r),nn=null}else return t=vt(n),t!==null&&gp(t),e.blockedOn=n,!1;t.shift()}return!0}function zp(e,t,n){Rp(e)&&n.delete(t)}function Bp(){Ep=!1,Dp!==null&&Rp(Dp)&&(Dp=null),Op!==null&&Rp(Op)&&(Op=null),kp!==null&&Rp(kp)&&(kp=null),Ap.forEach(zp),jp.forEach(zp)}function Vp(e,n){e.blockedOn===n&&(e.blockedOn=null,Ep||(Ep=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,Bp)))}var Hp=null;function Up(e){Hp!==e&&(Hp=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){Hp===e&&(Hp=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(wp(r||n)===null)continue;break}var a=vt(n);a!==null&&(e.splice(t,3),t-=3,js(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Wp(e){function t(t){return Vp(t,e)}Dp!==null&&Vp(Dp,e),Op!==null&&Vp(Op,e),kp!==null&&Vp(kp,e),Ap.forEach(t),jp.forEach(t);for(var n=0;n<Mp.length;n++){var r=Mp[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<Mp.length&&(n=Mp[0],n.blockedOn===null);)Lp(n),n.blockedOn===null&&Mp.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[lt]||null;if(typeof a==`function`)o||Up(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[lt]||null)s=o.formAction;else if(wp(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),Up(n)}}}function Gp(){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 Kp(e){this._internalRoot=e}qp.prototype.render=Kp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(a(409));var n=t.current;pp(n,Du(),e,t,null,null)},qp.prototype.unmount=Kp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;pp(e.current,2,null,e,null,null),Pu(),t[ut]=null}};function qp(e){this._internalRoot=e}qp.prototype.unstable_scheduleHydration=function(e){if(e){var t=at();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Mp.length&&t!==0&&t<Mp[n].priority;n++);Mp.splice(n,0,e),n===0&&Lp(e)}};var Jp=n.version;if(Jp!==`19.2.5`)throw Error(a(527,Jp,`19.2.5`));P.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(a(188)):(e=Object.keys(e).join(`,`),Error(a(268,e)));return e=p(t),e=e===null?null:m(e),e=e===null?null:e.stateNode,e};var Yp={bundleType:0,version:`19.2.5`,rendererPackageName:`react-dom`,currentDispatcherRef:N,reconcilerVersion:`19.2.5`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var Xp=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Xp.isDisabled&&Xp.supportsFiber)try{Ie=Xp.inject(Yp),Le=Xp}catch{}}e.createRoot=function(e,t){if(!s(e))throw Error(a(299));var n=!1,r=``,i=ec,o=tc,c=nc;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(i=t.onUncaughtError),t.onCaughtError!==void 0&&(o=t.onCaughtError),t.onRecoverableError!==void 0&&(c=t.onRecoverableError)),t=dp(e,1,!1,null,null,n,r,null,i,o,c,Gp),e[ut]=t.current,Nd(e),new Kp(t)}})),u=n(((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=l()})),d=t(i(),1);function f(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}function p(...e){return t=>{let n=!1,r=e.map(e=>{let r=f(e,t);return!n&&typeof r==`function`&&(n=!0),r});if(n)return()=>{for(let t=0;t<r.length;t++){let n=r[t];typeof n==`function`?n():f(e[t],null)}}}}function m(...e){return d.useCallback(p(...e),e)}var h=n((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})),g=n(((e,t)=>{t.exports=h()})),_=g();function v(e){let t=b(e),n=d.forwardRef((e,n)=>{let{children:r,...i}=e,a=d.Children.toArray(r),o=a.find(C);if(o){let e=o.props.children,r=a.map(t=>t===o?d.Children.count(e)>1?d.Children.only(null):d.isValidElement(e)?e.props.children:null:t);return(0,_.jsx)(t,{...i,ref:n,children:d.isValidElement(e)?d.cloneElement(e,void 0,r):null})}return(0,_.jsx)(t,{...i,ref:n,children:r})});return n.displayName=`${e}.Slot`,n}var y=v(`Slot`);function b(e){let t=d.forwardRef((e,t)=>{let{children:n,...r}=e;if(d.isValidElement(n)){let e=T(n),i=w(r,n.props);return n.type!==d.Fragment&&(i.ref=t?p(t,e):e),d.cloneElement(n,i)}return d.Children.count(n)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var x=Symbol(`radix.slottable`);function S(e){let t=({children:e})=>(0,_.jsx)(_.Fragment,{children:e});return t.displayName=`${e}.Slottable`,t.__radixId=x,t}function C(e){return d.isValidElement(e)&&typeof e.type==`function`&&`__radixId`in e.type&&e.type.__radixId===x}function w(e,t){let n={...t};for(let r in t){let i=e[r],a=t[r];/^on[A-Z]/.test(r)?i&&a?n[r]=(...e)=>{let t=a(...e);return i(...e),t}:i&&(n[r]=i):r===`style`?n[r]={...i,...a}:r===`className`&&(n[r]=[i,a].filter(Boolean).join(` `))}return{...e,...n}}function T(e){let t=Object.getOwnPropertyDescriptor(e.props,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var E=t(c(),1),D=[`a`,`button`,`div`,`form`,`h2`,`h3`,`img`,`input`,`label`,`li`,`nav`,`ol`,`p`,`select`,`span`,`svg`,`ul`].reduce((e,t)=>{let n=v(`Primitive.${t}`),r=d.forwardRef((e,r)=>{let{asChild:i,...a}=e,o=i?n:t;return typeof window<`u`&&(window[Symbol.for(`radix-ui`)]=!0),(0,_.jsx)(o,{...a,ref:r})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function O(e,t){e&&E.flushSync(()=>e.dispatchEvent(t))}var ee=Object.freeze({position:`absolute`,border:0,width:1,height:1,padding:0,margin:-1,overflow:`hidden`,clip:`rect(0, 0, 0, 0)`,whiteSpace:`nowrap`,wordWrap:`normal`}),te=`VisuallyHidden`,k=d.forwardRef((e,t)=>(0,_.jsx)(D.span,{...e,ref:t,style:{...ee,...e.style}}));k.displayName=te;var A=k;function j(e,t){let n=d.createContext(t),r=e=>{let{children:t,...r}=e,i=d.useMemo(()=>r,Object.values(r));return(0,_.jsx)(n.Provider,{value:i,children:t})};r.displayName=e+`Provider`;function i(r){let i=d.useContext(n);if(i)return i;if(t!==void 0)return t;throw Error(`\`${r}\` must be used within \`${e}\``)}return[r,i]}function M(e,t=[]){let n=[];function r(t,r){let i=d.createContext(r),a=n.length;n=[...n,r];let o=t=>{let{scope:n,children:r,...o}=t,s=n?.[e]?.[a]||i,c=d.useMemo(()=>o,Object.values(o));return(0,_.jsx)(s.Provider,{value:c,children:r})};o.displayName=t+`Provider`;function s(n,o){let s=o?.[e]?.[a]||i,c=d.useContext(s);if(c)return c;if(r!==void 0)return r;throw Error(`\`${n}\` must be used within \`${t}\``)}return[o,s]}let i=()=>{let t=n.map(e=>d.createContext(e));return function(n){let r=n?.[e]||t;return d.useMemo(()=>({[`__scope${e}`]:{...n,[e]:r}}),[n,r])}};return i.scopeName=e,[r,ne(i,...t)]}function ne(...e){let t=e[0];if(e.length===1)return t;let n=()=>{let n=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return function(e){let r=n.reduce((t,{useScope:n,scopeName:r})=>{let i=n(e)[`__scope${r}`];return{...t,...i}},{});return d.useMemo(()=>({[`__scope${t.scopeName}`]:r}),[r])}};return n.scopeName=t.scopeName,n}function N(e){let t=e+`CollectionProvider`,[n,r]=M(t),[i,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),o=e=>{let{scope:t,children:n}=e,r=d.useRef(null),a=d.useRef(new Map).current;return(0,_.jsx)(i,{scope:t,itemMap:a,collectionRef:r,children:n})};o.displayName=t;let s=e+`CollectionSlot`,c=v(s),l=d.forwardRef((e,t)=>{let{scope:n,children:r}=e;return(0,_.jsx)(c,{ref:m(t,a(s,n).collectionRef),children:r})});l.displayName=s;let u=e+`CollectionItemSlot`,f=`data-radix-collection-item`,p=v(u),h=d.forwardRef((e,t)=>{let{scope:n,children:r,...i}=e,o=d.useRef(null),s=m(t,o),c=a(u,n);return d.useEffect(()=>(c.itemMap.set(o,{ref:o,...i}),()=>void c.itemMap.delete(o))),(0,_.jsx)(p,{[f]:``,ref:s,children:r})});h.displayName=u;function g(t){let n=a(e+`CollectionConsumer`,t);return d.useCallback(()=>{let e=n.collectionRef.current;if(!e)return[];let t=Array.from(e.querySelectorAll(`[${f}]`));return Array.from(n.itemMap.values()).sort((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current))},[n.collectionRef,n.itemMap])}return[{Provider:o,Slot:l,ItemSlot:h},g,r]}typeof window<`u`&&window.document&&window.document.createElement;function P(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),n===!1||!r.defaultPrevented)return t?.(r)}}var re=globalThis?.document?d.useLayoutEffect:()=>{},ie=d.useInsertionEffect||re;function ae({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){let[i,a,o]=oe({defaultProp:t,onChange:n}),s=e!==void 0,c=s?e:i;{let t=d.useRef(e!==void 0);d.useEffect(()=>{let e=t.current;e!==s&&console.warn(`${r} is changing from ${e?`controlled`:`uncontrolled`} to ${s?`controlled`:`uncontrolled`}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),t.current=s},[s,r])}return[c,d.useCallback(t=>{if(s){let n=F(t)?t(e):t;n!==e&&o.current?.(n)}else a(t)},[s,e,a,o])]}function oe({defaultProp:e,onChange:t}){let[n,r]=d.useState(e),i=d.useRef(n),a=d.useRef(t);return ie(()=>{a.current=t},[t]),d.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,r,a]}function F(e){return typeof e==`function`}function I(e,t){return d.useReducer((e,n)=>t[e][n]??e,e)}var se=e=>{let{present:t,children:n}=e,r=ce(t),i=typeof n==`function`?n({present:r.isPresent}):d.Children.only(n),a=m(r.ref,ue(i));return typeof n==`function`||r.isPresent?d.cloneElement(i,{ref:a}):null};se.displayName=`Presence`;function ce(e){let[t,n]=d.useState(),r=d.useRef(null),i=d.useRef(e),a=d.useRef(`none`),[o,s]=I(e?`mounted`:`unmounted`,{mounted:{UNMOUNT:`unmounted`,ANIMATION_OUT:`unmountSuspended`},unmountSuspended:{MOUNT:`mounted`,ANIMATION_END:`unmounted`},unmounted:{MOUNT:`mounted`}});return d.useEffect(()=>{let e=le(r.current);a.current=o===`mounted`?e:`none`},[o]),re(()=>{let t=r.current,n=i.current;if(n!==e){let r=a.current,o=le(t);e?s(`MOUNT`):o===`none`||t?.display===`none`?s(`UNMOUNT`):s(n&&r!==o?`ANIMATION_OUT`:`UNMOUNT`),i.current=e}},[e,s]),re(()=>{if(t){let e,n=t.ownerDocument.defaultView??window,o=a=>{let o=le(r.current).includes(CSS.escape(a.animationName));if(a.target===t&&o&&(s(`ANIMATION_END`),!i.current)){let r=t.style.animationFillMode;t.style.animationFillMode=`forwards`,e=n.setTimeout(()=>{t.style.animationFillMode===`forwards`&&(t.style.animationFillMode=r)})}},c=e=>{e.target===t&&(a.current=le(r.current))};return t.addEventListener(`animationstart`,c),t.addEventListener(`animationcancel`,o),t.addEventListener(`animationend`,o),()=>{n.clearTimeout(e),t.removeEventListener(`animationstart`,c),t.removeEventListener(`animationcancel`,o),t.removeEventListener(`animationend`,o)}}else s(`ANIMATION_END`)},[t,s]),{isPresent:[`mounted`,`unmountSuspended`].includes(o),ref:d.useCallback(e=>{r.current=e?getComputedStyle(e):null,n(e)},[])}}function le(e){return e?.animationName||`none`}function ue(e){let t=Object.getOwnPropertyDescriptor(e.props,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var de=d.useId||(()=>void 0),fe=0;function pe(e){let[t,n]=d.useState(de());return re(()=>{e||n(e=>e??String(fe++))},[e]),e||(t?`radix-${t}`:``)}var me=d.createContext(void 0);function he(e){let t=d.useContext(me);return e||t||`ltr`}function ge(e){let t=d.useRef(e);return d.useEffect(()=>{t.current=e}),d.useMemo(()=>(...e)=>t.current?.(...e),[])}function _e(e,t=globalThis?.document){let n=ge(e);d.useEffect(()=>{let e=e=>{e.key===`Escape`&&n(e)};return t.addEventListener(`keydown`,e,{capture:!0}),()=>t.removeEventListener(`keydown`,e,{capture:!0})},[n,t])}var ve=`DismissableLayer`,ye=`dismissableLayer.update`,be=`dismissableLayer.pointerDownOutside`,xe=`dismissableLayer.focusOutside`,Se,Ce=d.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),we=d.forwardRef((e,t)=>{let{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:a,onInteractOutside:o,onDismiss:s,...c}=e,l=d.useContext(Ce),[u,f]=d.useState(null),p=u?.ownerDocument??globalThis?.document,[,h]=d.useState({}),g=m(t,e=>f(e)),v=Array.from(l.layers),[y]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),b=v.indexOf(y),x=u?v.indexOf(u):-1,S=l.layersWithOutsidePointerEventsDisabled.size>0,C=x>=b,w=De(e=>{let t=e.target,n=[...l.branches].some(e=>e.contains(t));!C||n||(i?.(e),o?.(e),e.defaultPrevented||s?.())},p),T=Oe(e=>{let t=e.target;[...l.branches].some(e=>e.contains(t))||(a?.(e),o?.(e),e.defaultPrevented||s?.())},p);return _e(e=>{x===l.layers.size-1&&(r?.(e),!e.defaultPrevented&&s&&(e.preventDefault(),s()))},p),d.useEffect(()=>{if(u)return n&&(l.layersWithOutsidePointerEventsDisabled.size===0&&(Se=p.body.style.pointerEvents,p.body.style.pointerEvents=`none`),l.layersWithOutsidePointerEventsDisabled.add(u)),l.layers.add(u),ke(),()=>{n&&l.layersWithOutsidePointerEventsDisabled.size===1&&(p.body.style.pointerEvents=Se)}},[u,p,n,l]),d.useEffect(()=>()=>{u&&(l.layers.delete(u),l.layersWithOutsidePointerEventsDisabled.delete(u),ke())},[u,l]),d.useEffect(()=>{let e=()=>h({});return document.addEventListener(ye,e),()=>document.removeEventListener(ye,e)},[]),(0,_.jsx)(D.div,{...c,ref:g,style:{pointerEvents:S?C?`auto`:`none`:void 0,...e.style},onFocusCapture:P(e.onFocusCapture,T.onFocusCapture),onBlurCapture:P(e.onBlurCapture,T.onBlurCapture),onPointerDownCapture:P(e.onPointerDownCapture,w.onPointerDownCapture)})});we.displayName=ve;var Te=`DismissableLayerBranch`,Ee=d.forwardRef((e,t)=>{let n=d.useContext(Ce),r=d.useRef(null),i=m(t,r);return d.useEffect(()=>{let e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}},[n.branches]),(0,_.jsx)(D.div,{...e,ref:i})});Ee.displayName=Te;function De(e,t=globalThis?.document){let n=ge(e),r=d.useRef(!1),i=d.useRef(()=>{});return d.useEffect(()=>{let e=e=>{if(e.target&&!r.current){let r=function(){Ae(be,n,a,{discrete:!0})},a={originalEvent:e};e.pointerType===`touch`?(t.removeEventListener(`click`,i.current),i.current=r,t.addEventListener(`click`,i.current,{once:!0})):r()}else t.removeEventListener(`click`,i.current);r.current=!1},a=window.setTimeout(()=>{t.addEventListener(`pointerdown`,e)},0);return()=>{window.clearTimeout(a),t.removeEventListener(`pointerdown`,e),t.removeEventListener(`click`,i.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function Oe(e,t=globalThis?.document){let n=ge(e),r=d.useRef(!1);return d.useEffect(()=>{let e=e=>{e.target&&!r.current&&Ae(xe,n,{originalEvent:e},{discrete:!1})};return t.addEventListener(`focusin`,e),()=>t.removeEventListener(`focusin`,e)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function ke(){let e=new CustomEvent(ye);document.dispatchEvent(e)}function Ae(e,t,n,{discrete:r}){let i=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?O(i,a):i.dispatchEvent(a)}var je=`focusScope.autoFocusOnMount`,Me=`focusScope.autoFocusOnUnmount`,Ne={bubbles:!1,cancelable:!0},Pe=`FocusScope`,Fe=d.forwardRef((e,t)=>{let{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:a,...o}=e,[s,c]=d.useState(null),l=ge(i),u=ge(a),f=d.useRef(null),p=m(t,e=>c(e)),h=d.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;d.useEffect(()=>{if(r){let e=function(e){if(h.paused||!s)return;let t=e.target;s.contains(t)?f.current=t:He(f.current,{select:!0})},t=function(e){if(h.paused||!s)return;let t=e.relatedTarget;t!==null&&(s.contains(t)||He(f.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(let t of e)t.removedNodes.length>0&&He(s)};document.addEventListener(`focusin`,e),document.addEventListener(`focusout`,t);let r=new MutationObserver(n);return s&&r.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener(`focusin`,e),document.removeEventListener(`focusout`,t),r.disconnect()}}},[r,s,h.paused]),d.useEffect(()=>{if(s){Ue.add(h);let e=document.activeElement;if(!s.contains(e)){let t=new CustomEvent(je,Ne);s.addEventListener(je,l),s.dispatchEvent(t),t.defaultPrevented||(Ie(Ke(Re(s)),{select:!0}),document.activeElement===e&&He(s))}return()=>{s.removeEventListener(je,l),setTimeout(()=>{let t=new CustomEvent(Me,Ne);s.addEventListener(Me,u),s.dispatchEvent(t),t.defaultPrevented||He(e??document.body,{select:!0}),s.removeEventListener(Me,u),Ue.remove(h)},0)}}},[s,l,u,h]);let g=d.useCallback(e=>{if(!n&&!r||h.paused)return;let t=e.key===`Tab`&&!e.altKey&&!e.ctrlKey&&!e.metaKey,i=document.activeElement;if(t&&i){let t=e.currentTarget,[r,a]=Le(t);r&&a?!e.shiftKey&&i===a?(e.preventDefault(),n&&He(r,{select:!0})):e.shiftKey&&i===r&&(e.preventDefault(),n&&He(a,{select:!0})):i===t&&e.preventDefault()}},[n,r,h.paused]);return(0,_.jsx)(D.div,{tabIndex:-1,...o,ref:p,onKeyDown:g})});Fe.displayName=Pe;function Ie(e,{select:t=!1}={}){let n=document.activeElement;for(let r of e)if(He(r,{select:t}),document.activeElement!==n)return}function Le(e){let t=Re(e);return[ze(t,e),ze(t.reverse(),e)]}function Re(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{let t=e.tagName===`INPUT`&&e.type===`hidden`;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function ze(e,t){for(let n of e)if(!Be(n,{upTo:t}))return n}function Be(e,{upTo:t}){if(getComputedStyle(e).visibility===`hidden`)return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display===`none`)return!0;e=e.parentElement}return!1}function Ve(e){return e instanceof HTMLInputElement&&`select`in e}function He(e,{select:t=!1}={}){if(e&&e.focus){let n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Ve(e)&&t&&e.select()}}var Ue=We();function We(){let e=[];return{add(t){let n=e[0];t!==n&&n?.pause(),e=Ge(e,t),e.unshift(t)},remove(t){e=Ge(e,t),e[0]?.resume()}}}function Ge(e,t){let n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function Ke(e){return e.filter(e=>e.tagName!==`A`)}var qe=`Portal`,Je=d.forwardRef((e,t)=>{let{container:n,...r}=e,[i,a]=d.useState(!1);re(()=>a(!0),[]);let o=n||i&&globalThis?.document?.body;return o?E.createPortal((0,_.jsx)(D.div,{...r,ref:t}),o):null});Je.displayName=qe;var Ye=0;function Xe(){d.useEffect(()=>{let e=document.querySelectorAll(`[data-radix-focus-guard]`);return document.body.insertAdjacentElement(`afterbegin`,e[0]??Ze()),document.body.insertAdjacentElement(`beforeend`,e[1]??Ze()),Ye++,()=>{Ye===1&&document.querySelectorAll(`[data-radix-focus-guard]`).forEach(e=>e.remove()),Ye--}},[])}function Ze(){let e=document.createElement(`span`);return e.setAttribute(`data-radix-focus-guard`,``),e.tabIndex=0,e.style.outline=`none`,e.style.opacity=`0`,e.style.position=`fixed`,e.style.pointerEvents=`none`,e}var Qe=function(){return Qe=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},Qe.apply(this,arguments)};function $e(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function et(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,a;r<i;r++)(a||!(r in t))&&(a||=Array.prototype.slice.call(t,0,r),a[r]=t[r]);return e.concat(a||Array.prototype.slice.call(t))}var tt=`right-scroll-bar-position`,nt=`width-before-scroll-bar`,rt=`with-scroll-bars-hidden`,it=`--removed-body-scroll-bar-size`;function at(e,t){return typeof e==`function`?e(t):e&&(e.current=t),e}function ot(e,t){var n=(0,d.useState)(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(e){var t=n.value;t!==e&&(n.value=e,n.callback(e,t))}}}})[0];return n.callback=t,n.facade}var st=typeof window<`u`?d.useLayoutEffect:d.useEffect,ct=new WeakMap;function lt(e,t){var n=ot(t||null,function(t){return e.forEach(function(e){return at(e,t)})});return st(function(){var t=ct.get(n);if(t){var r=new Set(t),i=new Set(e),a=n.current;r.forEach(function(e){i.has(e)||at(e,null)}),i.forEach(function(e){r.has(e)||at(e,a)})}ct.set(n,e)},[e]),n}function ut(e){return e}function dt(e,t){t===void 0&&(t=ut);var n=[],r=!1;return{read:function(){if(r)throw Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(e){var i=t(e,r);return n.push(i),function(){n=n.filter(function(e){return e!==i})}},assignSyncMedium:function(e){for(r=!0;n.length;){var t=n;n=[],t.forEach(e)}n={push:function(t){return e(t)},filter:function(){return n}}},assignMedium:function(e){r=!0;var t=[];if(n.length){var i=n;n=[],i.forEach(e),t=n}var a=function(){var n=t;t=[],n.forEach(e)},o=function(){return Promise.resolve().then(a)};o(),n={push:function(e){t.push(e),o()},filter:function(e){return t=t.filter(e),n}}}}}function ft(e){e===void 0&&(e={});var t=dt(null);return t.options=Qe({async:!0,ssr:!1},e),t}var pt=function(e){var t=e.sideCar,n=$e(e,[`sideCar`]);if(!t)throw Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw Error(`Sidecar medium not found`);return d.createElement(r,Qe({},n))};pt.isSideCarExport=!0;function mt(e,t){return e.useMedium(t),pt}var ht=ft(),gt=function(){},_t=d.forwardRef(function(e,t){var n=d.useRef(null),r=d.useState({onScrollCapture:gt,onWheelCapture:gt,onTouchMoveCapture:gt}),i=r[0],a=r[1],o=e.forwardProps,s=e.children,c=e.className,l=e.removeScrollBar,u=e.enabled,f=e.shards,p=e.sideCar,m=e.noRelative,h=e.noIsolation,g=e.inert,_=e.allowPinchZoom,v=e.as,y=v===void 0?`div`:v,b=e.gapMode,x=$e(e,[`forwardProps`,`children`,`className`,`removeScrollBar`,`enabled`,`shards`,`sideCar`,`noRelative`,`noIsolation`,`inert`,`allowPinchZoom`,`as`,`gapMode`]),S=p,C=lt([n,t]),w=Qe(Qe({},x),i);return d.createElement(d.Fragment,null,u&&d.createElement(S,{sideCar:ht,removeScrollBar:l,shards:f,noRelative:m,noIsolation:h,inert:g,setCallbacks:a,allowPinchZoom:!!_,lockRef:n,gapMode:b}),o?d.cloneElement(d.Children.only(s),Qe(Qe({},w),{ref:C})):d.createElement(y,Qe({},w,{className:c,ref:C}),s))});_t.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},_t.classNames={fullWidth:nt,zeroRight:tt};var vt,yt=function(){if(vt)return vt;if(typeof __webpack_nonce__<`u`)return __webpack_nonce__};function bt(){if(!document)return null;var e=document.createElement(`style`);e.type=`text/css`;var t=yt();return t&&e.setAttribute(`nonce`,t),e}function xt(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function St(e){(document.head||document.getElementsByTagName(`head`)[0]).appendChild(e)}var Ct=function(){var e=0,t=null;return{add:function(n){e==0&&(t=bt())&&(xt(t,n),St(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},wt=function(){var e=Ct();return function(t,n){d.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Tt=function(){var e=wt();return function(t){var n=t.styles,r=t.dynamic;return e(n,r),null}},Et={left:0,top:0,right:0,gap:0},Dt=function(e){return parseInt(e||``,10)||0},Ot=function(e){var t=window.getComputedStyle(document.body),n=t[e===`padding`?`paddingLeft`:`marginLeft`],r=t[e===`padding`?`paddingTop`:`marginTop`],i=t[e===`padding`?`paddingRight`:`marginRight`];return[Dt(n),Dt(r),Dt(i)]},kt=function(e){if(e===void 0&&(e=`margin`),typeof window>`u`)return Et;var t=Ot(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},At=Tt(),jt=`data-scroll-locked`,Mt=function(e,t,n,r){var i=e.left,a=e.top,o=e.right,s=e.gap;return n===void 0&&(n=`margin`),`
11
- .${rt} {
12
- overflow: hidden ${r};
13
- padding-right: ${s}px ${r};
14
- }
15
- body[${jt}] {
16
- overflow: hidden ${r};
17
- overscroll-behavior: contain;
18
- ${[t&&`position: relative ${r};`,n===`margin`&&`
19
- padding-left: ${i}px;
20
- padding-top: ${a}px;
21
- padding-right: ${o}px;
22
- margin-left:0;
23
- margin-top:0;
24
- margin-right: ${s}px ${r};
25
- `,n===`padding`&&`padding-right: ${s}px ${r};`].filter(Boolean).join(``)}
26
- }
27
-
28
- .${tt} {
29
- right: ${s}px ${r};
30
- }
31
-
32
- .${nt} {
33
- margin-right: ${s}px ${r};
34
- }
35
-
36
- .${tt} .${tt} {
37
- right: 0 ${r};
38
- }
39
-
40
- .${nt} .${nt} {
41
- margin-right: 0 ${r};
42
- }
43
-
44
- body[${jt}] {
45
- ${it}: ${s}px;
46
- }
47
- `},Nt=function(){var e=parseInt(document.body.getAttribute(`data-scroll-locked`)||`0`,10);return isFinite(e)?e:0},Pt=function(){d.useEffect(function(){return document.body.setAttribute(jt,(Nt()+1).toString()),function(){var e=Nt()-1;e<=0?document.body.removeAttribute(jt):document.body.setAttribute(jt,e.toString())}},[])},Ft=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?`margin`:r;Pt();var a=d.useMemo(function(){return kt(i)},[i]);return d.createElement(At,{styles:Mt(a,!t,i,n?``:`!important`)})},It=!1;if(typeof window<`u`)try{var Lt=Object.defineProperty({},`passive`,{get:function(){return It=!0,!0}});window.addEventListener(`test`,Lt,Lt),window.removeEventListener(`test`,Lt,Lt)}catch{It=!1}var Rt=It?{passive:!1}:!1,zt=function(e){return e.tagName===`TEXTAREA`},Bt=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!==`hidden`&&!(n.overflowY===n.overflowX&&!zt(e)&&n[t]===`visible`)},Vt=function(e){return Bt(e,`overflowY`)},Ht=function(e){return Bt(e,`overflowX`)},Ut=function(e,t){var n=t.ownerDocument,r=t;do{if(typeof ShadowRoot<`u`&&r instanceof ShadowRoot&&(r=r.host),Kt(e,r)){var i=qt(e,r);if(i[1]>i[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},Wt=function(e){return[e.scrollTop,e.scrollHeight,e.clientHeight]},Gt=function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]},Kt=function(e,t){return e===`v`?Vt(t):Ht(t)},qt=function(e,t){return e===`v`?Wt(t):Gt(t)},Jt=function(e,t){return e===`h`&&t===`rtl`?-1:1},Yt=function(e,t,n,r,i){var a=Jt(e,window.getComputedStyle(t).direction),o=a*r,s=n.target,c=t.contains(s),l=!1,u=o>0,d=0,f=0;do{if(!s)break;var p=qt(e,s),m=p[0],h=p[1]-p[2]-a*m;(m||h)&&Kt(e,s)&&(d+=h,f+=m);var g=s.parentNode;s=g&&g.nodeType===Node.DOCUMENT_FRAGMENT_NODE?g.host:g}while(!c&&s!==document.body||c&&(t.contains(s)||t===s));return(u&&(i&&Math.abs(d)<1||!i&&o>d)||!u&&(i&&Math.abs(f)<1||!i&&-o>f))&&(l=!0),l},Xt=function(e){return`changedTouches`in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Zt=function(e){return[e.deltaX,e.deltaY]},Qt=function(e){return e&&`current`in e?e.current:e},$t=function(e,t){return e[0]===t[0]&&e[1]===t[1]},en=function(e){return`
48
- .block-interactivity-${e} {pointer-events: none;}
49
- .allow-interactivity-${e} {pointer-events: all;}
50
- `},tn=0,nn=[];function rn(e){var t=d.useRef([]),n=d.useRef([0,0]),r=d.useRef(),i=d.useState(tn++)[0],a=d.useState(Tt)[0],o=d.useRef(e);d.useEffect(function(){o.current=e},[e]),d.useEffect(function(){if(e.inert){document.body.classList.add(`block-interactivity-${i}`);var t=et([e.lockRef.current],(e.shards||[]).map(Qt),!0).filter(Boolean);return t.forEach(function(e){return e.classList.add(`allow-interactivity-${i}`)}),function(){document.body.classList.remove(`block-interactivity-${i}`),t.forEach(function(e){return e.classList.remove(`allow-interactivity-${i}`)})}}},[e.inert,e.lockRef.current,e.shards]);var s=d.useCallback(function(e,t){if(`touches`in e&&e.touches.length===2||e.type===`wheel`&&e.ctrlKey)return!o.current.allowPinchZoom;var i=Xt(e),a=n.current,s=`deltaX`in e?e.deltaX:a[0]-i[0],c=`deltaY`in e?e.deltaY:a[1]-i[1],l,u=e.target,d=Math.abs(s)>Math.abs(c)?`h`:`v`;if(`touches`in e&&d===`h`&&u.type===`range`)return!1;var f=window.getSelection(),p=f&&f.anchorNode;if(p&&(p===u||p.contains(u)))return!1;var m=Ut(d,u);if(!m)return!0;if(m?l=d:(l=d===`v`?`h`:`v`,m=Ut(d,u)),!m)return!1;if(!r.current&&`changedTouches`in e&&(s||c)&&(r.current=l),!l)return!0;var h=r.current||l;return Yt(h,t,e,h===`h`?s:c,!0)},[]),c=d.useCallback(function(e){var n=e;if(!(!nn.length||nn[nn.length-1]!==a)){var r=`deltaY`in n?Zt(n):Xt(n),i=t.current.filter(function(e){return e.name===n.type&&(e.target===n.target||n.target===e.shadowParent)&&$t(e.delta,r)})[0];if(i&&i.should){n.cancelable&&n.preventDefault();return}if(!i){var c=(o.current.shards||[]).map(Qt).filter(Boolean).filter(function(e){return e.contains(n.target)});(c.length>0?s(n,c[0]):!o.current.noIsolation)&&n.cancelable&&n.preventDefault()}}},[]),l=d.useCallback(function(e,n,r,i){var a={name:e,delta:n,target:r,should:i,shadowParent:an(r)};t.current.push(a),setTimeout(function(){t.current=t.current.filter(function(e){return e!==a})},1)},[]),u=d.useCallback(function(e){n.current=Xt(e),r.current=void 0},[]),f=d.useCallback(function(t){l(t.type,Zt(t),t.target,s(t,e.lockRef.current))},[]),p=d.useCallback(function(t){l(t.type,Xt(t),t.target,s(t,e.lockRef.current))},[]);d.useEffect(function(){return nn.push(a),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:p}),document.addEventListener(`wheel`,c,Rt),document.addEventListener(`touchmove`,c,Rt),document.addEventListener(`touchstart`,u,Rt),function(){nn=nn.filter(function(e){return e!==a}),document.removeEventListener(`wheel`,c,Rt),document.removeEventListener(`touchmove`,c,Rt),document.removeEventListener(`touchstart`,u,Rt)}},[]);var m=e.removeScrollBar,h=e.inert;return d.createElement(d.Fragment,null,h?d.createElement(a,{styles:en(i)}):null,m?d.createElement(Ft,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function an(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}var on=mt(ht,rn),sn=d.forwardRef(function(e,t){return d.createElement(_t,Qe({},e,{ref:t,sideCar:on}))});sn.classNames=_t.classNames;var cn=function(e){return typeof document>`u`?null:(Array.isArray(e)?e[0]:e).ownerDocument.body},ln=new WeakMap,un=new WeakMap,dn={},fn=0,pn=function(e){return e&&(e.host||pn(e.parentNode))},mn=function(e,t){return t.map(function(t){if(e.contains(t))return t;var n=pn(t);return n&&e.contains(n)?n:(console.error(`aria-hidden`,t,`in not contained inside`,e,`. Doing nothing`),null)}).filter(function(e){return!!e})},hn=function(e,t,n,r){var i=mn(t,Array.isArray(e)?e:[e]);dn[n]||(dn[n]=new WeakMap);var a=dn[n],o=[],s=new Set,c=new Set(i),l=function(e){!e||s.has(e)||(s.add(e),l(e.parentNode))};i.forEach(l);var u=function(e){!e||c.has(e)||Array.prototype.forEach.call(e.children,function(e){if(s.has(e))u(e);else try{var t=e.getAttribute(r),i=t!==null&&t!==`false`,c=(ln.get(e)||0)+1,l=(a.get(e)||0)+1;ln.set(e,c),a.set(e,l),o.push(e),c===1&&i&&un.set(e,!0),l===1&&e.setAttribute(n,`true`),i||e.setAttribute(r,`true`)}catch(t){console.error(`aria-hidden: cannot operate on `,e,t)}})};return u(t),s.clear(),fn++,function(){o.forEach(function(e){var t=ln.get(e)-1,i=a.get(e)-1;ln.set(e,t),a.set(e,i),t||(un.has(e)||e.removeAttribute(r),un.delete(e)),i||e.removeAttribute(n)}),fn--,fn||(ln=new WeakMap,ln=new WeakMap,un=new WeakMap,dn={})}},gn=function(e,t,n){n===void 0&&(n=`data-aria-hidden`);var r=Array.from(Array.isArray(e)?e:[e]),i=t||cn(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll(`[aria-live], script`))),hn(r,i,n,`aria-hidden`)):function(){return null}},_n=`Dialog`,[vn,yn]=M(_n),[bn,xn]=vn(_n),Sn=e=>{let{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!0}=e,s=d.useRef(null),c=d.useRef(null),[l,u]=ae({prop:r,defaultProp:i??!1,onChange:a,caller:_n});return(0,_.jsx)(bn,{scope:t,triggerRef:s,contentRef:c,contentId:pe(),titleId:pe(),descriptionId:pe(),open:l,onOpenChange:u,onOpenToggle:d.useCallback(()=>u(e=>!e),[u]),modal:o,children:n})};Sn.displayName=_n;var Cn=`DialogTrigger`,wn=d.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=xn(Cn,n),a=m(t,i.triggerRef);return(0,_.jsx)(D.button,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":i.open,"aria-controls":i.contentId,"data-state":Wn(i.open),...r,ref:a,onClick:P(e.onClick,i.onOpenToggle)})});wn.displayName=Cn;var Tn=`DialogPortal`,[En,Dn]=vn(Tn,{forceMount:void 0}),On=e=>{let{__scopeDialog:t,forceMount:n,children:r,container:i}=e,a=xn(Tn,t);return(0,_.jsx)(En,{scope:t,forceMount:n,children:d.Children.map(r,e=>(0,_.jsx)(se,{present:n||a.open,children:(0,_.jsx)(Je,{asChild:!0,container:i,children:e})}))})};On.displayName=Tn;var kn=`DialogOverlay`,An=d.forwardRef((e,t)=>{let n=Dn(kn,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=xn(kn,e.__scopeDialog);return a.modal?(0,_.jsx)(se,{present:r||a.open,children:(0,_.jsx)(Mn,{...i,ref:t})}):null});An.displayName=kn;var jn=v(`DialogOverlay.RemoveScroll`),Mn=d.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=xn(kn,n);return(0,_.jsx)(sn,{as:jn,allowPinchZoom:!0,shards:[i.contentRef],children:(0,_.jsx)(D.div,{"data-state":Wn(i.open),...r,ref:t,style:{pointerEvents:`auto`,...r.style}})})}),Nn=`DialogContent`,Pn=d.forwardRef((e,t)=>{let n=Dn(Nn,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=xn(Nn,e.__scopeDialog);return(0,_.jsx)(se,{present:r||a.open,children:a.modal?(0,_.jsx)(Fn,{...i,ref:t}):(0,_.jsx)(In,{...i,ref:t})})});Pn.displayName=Nn;var Fn=d.forwardRef((e,t)=>{let n=xn(Nn,e.__scopeDialog),r=d.useRef(null),i=m(t,n.contentRef,r);return d.useEffect(()=>{let e=r.current;if(e)return gn(e)},[]),(0,_.jsx)(Ln,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:P(e.onCloseAutoFocus,e=>{e.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:P(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0;(t.button===2||n)&&e.preventDefault()}),onFocusOutside:P(e.onFocusOutside,e=>e.preventDefault())})}),In=d.forwardRef((e,t)=>{let n=xn(Nn,e.__scopeDialog),r=d.useRef(!1),i=d.useRef(!1);return(0,_.jsx)(Ln,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(r.current||n.triggerRef.current?.focus(),t.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(r.current=!0,t.detail.originalEvent.type===`pointerdown`&&(i.current=!0));let a=t.target;n.triggerRef.current?.contains(a)&&t.preventDefault(),t.detail.originalEvent.type===`focusin`&&i.current&&t.preventDefault()}})}),Ln=d.forwardRef((e,t)=>{let{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,...o}=e,s=xn(Nn,n),c=d.useRef(null),l=m(t,c);return Xe(),(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(Fe,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:a,children:(0,_.jsx)(we,{role:`dialog`,id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":Wn(s.open),...o,ref:l,onDismiss:()=>s.onOpenChange(!1)})}),(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(Jn,{titleId:s.titleId}),(0,_.jsx)(Xn,{contentRef:c,descriptionId:s.descriptionId})]})]})}),Rn=`DialogTitle`,zn=d.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=xn(Rn,n);return(0,_.jsx)(D.h2,{id:i.titleId,...r,ref:t})});zn.displayName=Rn;var Bn=`DialogDescription`,Vn=d.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=xn(Bn,n);return(0,_.jsx)(D.p,{id:i.descriptionId,...r,ref:t})});Vn.displayName=Bn;var Hn=`DialogClose`,Un=d.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=xn(Hn,n);return(0,_.jsx)(D.button,{type:`button`,...r,ref:t,onClick:P(e.onClick,()=>i.onOpenChange(!1))})});Un.displayName=Hn;function Wn(e){return e?`open`:`closed`}var Gn=`DialogTitleWarning`,[Kn,qn]=j(Gn,{contentName:Nn,titleName:Rn,docsSlug:`dialog`}),Jn=({titleId:e})=>{let t=qn(Gn),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
51
-
52
- If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
53
-
54
- For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return d.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},Yn=`DialogDescriptionWarning`,Xn=({contentRef:e,descriptionId:t})=>{let n=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${qn(Yn).contentName}}.`;return d.useEffect(()=>{let r=e.current?.getAttribute(`aria-describedby`);t&&r&&(document.getElementById(t)||console.warn(n))},[n,e,t]),null},Zn=Sn,Qn=On,$n=An,er=Pn,tr=zn,nr=Vn,rr=Un;function ir(e){let t=d.useRef({value:e,previous:e});return d.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}function ar(e){let[t,n]=d.useState(void 0);return re(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});let t=new ResizeObserver(t=>{if(!Array.isArray(t)||!t.length)return;let r=t[0],i,a;if(`borderBoxSize`in r){let e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;i=t.inlineSize,a=t.blockSize}else i=e.offsetWidth,a=e.offsetHeight;n({width:i,height:a})});return t.observe(e,{box:`border-box`}),()=>t.unobserve(e)}else n(void 0)},[e]),t}var or=[`top`,`right`,`bottom`,`left`],sr=Math.min,cr=Math.max,lr=Math.round,ur=Math.floor,dr=e=>({x:e,y:e}),fr={left:`right`,right:`left`,bottom:`top`,top:`bottom`};function pr(e,t,n){return cr(e,sr(t,n))}function mr(e,t){return typeof e==`function`?e(t):e}function hr(e){return e.split(`-`)[0]}function gr(e){return e.split(`-`)[1]}function _r(e){return e===`x`?`y`:`x`}function vr(e){return e===`y`?`height`:`width`}function yr(e){let t=e[0];return t===`t`||t===`b`?`y`:`x`}function br(e){return _r(yr(e))}function xr(e,t,n){n===void 0&&(n=!1);let r=gr(e),i=br(e),a=vr(i),o=i===`x`?r===(n?`end`:`start`)?`right`:`left`:r===`start`?`bottom`:`top`;return t.reference[a]>t.floating[a]&&(o=Ar(o)),[o,Ar(o)]}function Sr(e){let t=Ar(e);return[Cr(e),t,Cr(t)]}function Cr(e){return e.includes(`start`)?e.replace(`start`,`end`):e.replace(`end`,`start`)}var wr=[`left`,`right`],Tr=[`right`,`left`],Er=[`top`,`bottom`],Dr=[`bottom`,`top`];function Or(e,t,n){switch(e){case`top`:case`bottom`:return n?t?Tr:wr:t?wr:Tr;case`left`:case`right`:return t?Er:Dr;default:return[]}}function kr(e,t,n,r){let i=gr(e),a=Or(hr(e),n===`start`,r);return i&&(a=a.map(e=>e+`-`+i),t&&(a=a.concat(a.map(Cr)))),a}function Ar(e){let t=hr(e);return fr[t]+e.slice(t.length)}function jr(e){return{top:0,right:0,bottom:0,left:0,...e}}function Mr(e){return typeof e==`number`?{top:e,right:e,bottom:e,left:e}:jr(e)}function Nr(e){let{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function Pr(e,t,n){let{reference:r,floating:i}=e,a=yr(t),o=br(t),s=vr(o),c=hr(t),l=a===`y`,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,f=r[s]/2-i[s]/2,p;switch(c){case`top`:p={x:u,y:r.y-i.height};break;case`bottom`:p={x:u,y:r.y+r.height};break;case`right`:p={x:r.x+r.width,y:d};break;case`left`:p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}switch(gr(t)){case`start`:p[o]-=f*(n&&l?-1:1);break;case`end`:p[o]+=f*(n&&l?-1:1);break}return p}async function Fr(e,t){t===void 0&&(t={});let{x:n,y:r,platform:i,rects:a,elements:o,strategy:s}=e,{boundary:c=`clippingAncestors`,rootBoundary:l=`viewport`,elementContext:u=`floating`,altBoundary:d=!1,padding:f=0}=mr(t,e),p=Mr(f),m=o[d?u===`floating`?`reference`:`floating`:u],h=Nr(await i.getClippingRect({element:await(i.isElement==null?void 0:i.isElement(m))??!0?m:m.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(o.floating)),boundary:c,rootBoundary:l,strategy:s})),g=u===`floating`?{x:n,y:r,width:a.floating.width,height:a.floating.height}:a.reference,_=await(i.getOffsetParent==null?void 0:i.getOffsetParent(o.floating)),v=await(i.isElement==null?void 0:i.isElement(_))&&await(i.getScale==null?void 0:i.getScale(_))||{x:1,y:1},y=Nr(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:o,rect:g,offsetParent:_,strategy:s}):g);return{top:(h.top-y.top+p.top)/v.y,bottom:(y.bottom-h.bottom+p.bottom)/v.y,left:(h.left-y.left+p.left)/v.x,right:(y.right-h.right+p.right)/v.x}}var Ir=50,Lr=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=o.detectOverflow?o:{...o,detectOverflow:Fr},c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=Pr(l,r,c),f=r,p=0,m={};for(let n=0;n<a.length;n++){let h=a[n];if(!h)continue;let{name:g,fn:_}=h,{x:v,y,data:b,reset:x}=await _({x:u,y:d,initialPlacement:r,placement:f,strategy:i,middlewareData:m,rects:l,platform:s,elements:{reference:e,floating:t}});u=v??u,d=y??d,m[g]={...m[g],...b},x&&p<Ir&&(p++,typeof x==`object`&&(x.placement&&(f=x.placement),x.rects&&(l=x.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):x.rects),{x:u,y:d}=Pr(l,f,c)),n=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:m}},Rr=e=>({name:`arrow`,options:e,async fn(t){let{x:n,y:r,placement:i,rects:a,platform:o,elements:s,middlewareData:c}=t,{element:l,padding:u=0}=mr(e,t)||{};if(l==null)return{};let d=Mr(u),f={x:n,y:r},p=br(i),m=vr(p),h=await o.getDimensions(l),g=p===`y`,_=g?`top`:`left`,v=g?`bottom`:`right`,y=g?`clientHeight`:`clientWidth`,b=a.reference[m]+a.reference[p]-f[p]-a.floating[m],x=f[p]-a.reference[p],S=await(o.getOffsetParent==null?void 0:o.getOffsetParent(l)),C=S?S[y]:0;(!C||!await(o.isElement==null?void 0:o.isElement(S)))&&(C=s.floating[y]||a.floating[m]);let w=b/2-x/2,T=C/2-h[m]/2-1,E=sr(d[_],T),D=sr(d[v],T),O=E,ee=C-h[m]-D,te=C/2-h[m]/2+w,k=pr(O,te,ee),A=!c.arrow&&gr(i)!=null&&te!==k&&a.reference[m]/2-(te<O?E:D)-h[m]/2<0,j=A?te<O?te-O:te-ee:0;return{[p]:f[p]+j,data:{[p]:k,centerOffset:te-k-j,...A&&{alignmentOffset:j}},reset:A}}}),zr=function(e){return e===void 0&&(e={}),{name:`flip`,options:e,async fn(t){var n;let{placement:r,middlewareData:i,rects:a,initialPlacement:o,platform:s,elements:c}=t,{mainAxis:l=!0,crossAxis:u=!0,fallbackPlacements:d,fallbackStrategy:f=`bestFit`,fallbackAxisSideDirection:p=`none`,flipAlignment:m=!0,...h}=mr(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};let g=hr(r),_=yr(o),v=hr(o)===o,y=await(s.isRTL==null?void 0:s.isRTL(c.floating)),b=d||(v||!m?[Ar(o)]:Sr(o)),x=p!==`none`;!d&&x&&b.push(...kr(o,m,p,y));let S=[o,...b],C=await s.detectOverflow(t,h),w=[],T=i.flip?.overflows||[];if(l&&w.push(C[g]),u){let e=xr(r,a,y);w.push(C[e[0]],C[e[1]])}if(T=[...T,{placement:r,overflows:w}],!w.every(e=>e<=0)){let e=(i.flip?.index||0)+1,t=S[e];if(t&&(!(u===`alignment`&&_!==yr(t))||T.every(e=>yr(e.placement)===_?e.overflows[0]>0:!0)))return{data:{index:e,overflows:T},reset:{placement:t}};let n=T.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0]?.placement;if(!n)switch(f){case`bestFit`:{let e=T.filter(e=>{if(x){let t=yr(e.placement);return t===_||t===`y`}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0]?.[0];e&&(n=e);break}case`initialPlacement`:n=o;break}if(r!==n)return{reset:{placement:n}}}return{}}}};function Br(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Vr(e){return or.some(t=>e[t]>=0)}var Hr=function(e){return e===void 0&&(e={}),{name:`hide`,options:e,async fn(t){let{rects:n,platform:r}=t,{strategy:i=`referenceHidden`,...a}=mr(e,t);switch(i){case`referenceHidden`:{let e=Br(await r.detectOverflow(t,{...a,elementContext:`reference`}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:Vr(e)}}}case`escaped`:{let e=Br(await r.detectOverflow(t,{...a,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:Vr(e)}}}default:return{}}}}},Ur=new Set([`left`,`top`]);async function Wr(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=hr(n),s=gr(n),c=yr(n)===`y`,l=Ur.has(o)?-1:1,u=a&&c?-1:1,d=mr(t,e),{mainAxis:f,crossAxis:p,alignmentAxis:m}=typeof d==`number`?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof m==`number`&&(p=s===`end`?m*-1:m),c?{x:p*u,y:f*l}:{x:f*l,y:p*u}}var Gr=function(e){return e===void 0&&(e=0),{name:`offset`,options:e,async fn(t){var n;let{x:r,y:i,placement:a,middlewareData:o}=t,s=await Wr(t,e);return a===o.offset?.placement&&(n=o.arrow)!=null&&n.alignmentOffset?{}:{x:r+s.x,y:i+s.y,data:{...s,placement:a}}}}},Kr=function(e){return e===void 0&&(e={}),{name:`shift`,options:e,async fn(t){let{x:n,y:r,placement:i,platform:a}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:c={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=mr(e,t),u={x:n,y:r},d=await a.detectOverflow(t,l),f=yr(hr(i)),p=_r(f),m=u[p],h=u[f];if(o){let e=p===`y`?`top`:`left`,t=p===`y`?`bottom`:`right`,n=m+d[e],r=m-d[t];m=pr(n,m,r)}if(s){let e=f===`y`?`top`:`left`,t=f===`y`?`bottom`:`right`,n=h+d[e],r=h-d[t];h=pr(n,h,r)}let g=c.fn({...t,[p]:m,[f]:h});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[p]:o,[f]:s}}}}}},qr=function(e){return e===void 0&&(e={}),{options:e,fn(t){let{x:n,y:r,placement:i,rects:a,middlewareData:o}=t,{offset:s=0,mainAxis:c=!0,crossAxis:l=!0}=mr(e,t),u={x:n,y:r},d=yr(i),f=_r(d),p=u[f],m=u[d],h=mr(s,t),g=typeof h==`number`?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(c){let e=f===`y`?`height`:`width`,t=a.reference[f]-a.floating[e]+g.mainAxis,n=a.reference[f]+a.reference[e]-g.mainAxis;p<t?p=t:p>n&&(p=n)}if(l){let e=f===`y`?`width`:`height`,t=Ur.has(hr(i)),n=a.reference[d]-a.floating[e]+(t&&o.offset?.[d]||0)+(t?0:g.crossAxis),r=a.reference[d]+a.reference[e]+(t?0:o.offset?.[d]||0)-(t?g.crossAxis:0);m<n?m=n:m>r&&(m=r)}return{[f]:p,[d]:m}}}},Jr=function(e){return e===void 0&&(e={}),{name:`size`,options:e,async fn(t){var n,r;let{placement:i,rects:a,platform:o,elements:s}=t,{apply:c=()=>{},...l}=mr(e,t),u=await o.detectOverflow(t,l),d=hr(i),f=gr(i),p=yr(i)===`y`,{width:m,height:h}=a.floating,g,_;d===`top`||d===`bottom`?(g=d,_=f===(await(o.isRTL==null?void 0:o.isRTL(s.floating))?`start`:`end`)?`left`:`right`):(_=d,g=f===`end`?`top`:`bottom`);let v=h-u.top-u.bottom,y=m-u.left-u.right,b=sr(h-u[g],v),x=sr(m-u[_],y),S=!t.middlewareData.shift,C=b,w=x;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(w=y),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(C=v),S&&!f){let e=cr(u.left,0),t=cr(u.right,0),n=cr(u.top,0),r=cr(u.bottom,0);p?w=m-2*(e!==0||t!==0?e+t:cr(u.left,u.right)):C=h-2*(n!==0||r!==0?n+r:cr(u.top,u.bottom))}await c({...t,availableWidth:w,availableHeight:C});let T=await o.getDimensions(s.floating);return m!==T.width||h!==T.height?{reset:{rects:!0}}:{}}}};function Yr(){return typeof window<`u`}function Xr(e){return $r(e)?(e.nodeName||``).toLowerCase():`#document`}function Zr(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Qr(e){return(($r(e)?e.ownerDocument:e.document)||window.document)?.documentElement}function $r(e){return Yr()?e instanceof Node||e instanceof Zr(e).Node:!1}function ei(e){return Yr()?e instanceof Element||e instanceof Zr(e).Element:!1}function ti(e){return Yr()?e instanceof HTMLElement||e instanceof Zr(e).HTMLElement:!1}function ni(e){return!Yr()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof Zr(e).ShadowRoot}function ri(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=mi(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!==`inline`&&i!==`contents`}function ii(e){return/^(table|td|th)$/.test(Xr(e))}function ai(e){try{if(e.matches(`:popover-open`))return!0}catch{}try{return e.matches(`:modal`)}catch{return!1}}var oi=/transform|translate|scale|rotate|perspective|filter/,si=/paint|layout|strict|content/,ci=e=>!!e&&e!==`none`,li;function ui(e){let t=ei(e)?mi(e):e;return ci(t.transform)||ci(t.translate)||ci(t.scale)||ci(t.rotate)||ci(t.perspective)||!fi()&&(ci(t.backdropFilter)||ci(t.filter))||oi.test(t.willChange||``)||si.test(t.contain||``)}function di(e){let t=gi(e);for(;ti(t)&&!pi(t);){if(ui(t))return t;if(ai(t))return null;t=gi(t)}return null}function fi(){return li??=typeof CSS<`u`&&CSS.supports&&CSS.supports(`-webkit-backdrop-filter`,`none`),li}function pi(e){return/^(html|body|#document)$/.test(Xr(e))}function mi(e){return Zr(e).getComputedStyle(e)}function hi(e){return ei(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function gi(e){if(Xr(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||ni(e)&&e.host||Qr(e);return ni(t)?t.host:t}function _i(e){let t=gi(e);return pi(t)?e.ownerDocument?e.ownerDocument.body:e.body:ti(t)&&ri(t)?t:_i(t)}function vi(e,t,n){t===void 0&&(t=[]),n===void 0&&(n=!0);let r=_i(e),i=r===e.ownerDocument?.body,a=Zr(r);if(i){let e=yi(a);return t.concat(a,a.visualViewport||[],ri(r)?r:[],e&&n?vi(e):[])}else return t.concat(r,vi(r,[],n))}function yi(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function bi(e){let t=mi(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=ti(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=lr(n)!==a||lr(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function xi(e){return ei(e)?e:e.contextElement}function Si(e){let t=xi(e);if(!ti(t))return dr(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=bi(t),o=(a?lr(n.width):n.width)/r,s=(a?lr(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}var Ci=dr(0);function wi(e){let t=Zr(e);return!fi()||!t.visualViewport?Ci:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Ti(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Zr(e)?!1:t}function Ei(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=xi(e),o=dr(1);t&&(r?ei(r)&&(o=Si(r)):o=Si(e));let s=Ti(a,n,r)?wi(a):dr(0),c=(i.left+s.x)/o.x,l=(i.top+s.y)/o.y,u=i.width/o.x,d=i.height/o.y;if(a){let e=Zr(a),t=r&&ei(r)?Zr(r):r,n=e,i=yi(n);for(;i&&r&&t!==n;){let e=Si(i),t=i.getBoundingClientRect(),r=mi(i),a=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,o=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,l*=e.y,u*=e.x,d*=e.y,c+=a,l+=o,n=Zr(i),i=yi(n)}}return Nr({width:u,height:d,x:c,y:l})}function Di(e,t){let n=hi(e).scrollLeft;return t?t.left+n:Ei(Qr(e)).left+n}function Oi(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-Di(e,n),y:n.top+t.scrollTop}}function ki(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=Qr(r),s=t?ai(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=dr(1),u=dr(0),d=ti(r);if((d||!d&&!a)&&((Xr(r)!==`body`||ri(o))&&(c=hi(r)),d)){let e=Ei(r);l=Si(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?Oi(o,c):dr(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+u.x+f.x,y:n.y*l.y-c.scrollTop*l.y+u.y+f.y}}function Ai(e){return Array.from(e.getClientRects())}function ji(e){let t=Qr(e),n=hi(e),r=e.ownerDocument.body,i=cr(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=cr(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),o=-n.scrollLeft+Di(e),s=-n.scrollTop;return mi(r).direction===`rtl`&&(o+=cr(t.clientWidth,r.clientWidth)-i),{width:i,height:a,x:o,y:s}}var Mi=25;function Ni(e,t){let n=Zr(e),r=Qr(e),i=n.visualViewport,a=r.clientWidth,o=r.clientHeight,s=0,c=0;if(i){a=i.width,o=i.height;let e=fi();(!e||e&&t===`fixed`)&&(s=i.offsetLeft,c=i.offsetTop)}let l=Di(r);if(l<=0){let e=r.ownerDocument,t=e.body,n=getComputedStyle(t),i=e.compatMode===`CSS1Compat`&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,o=Math.abs(r.clientWidth-t.clientWidth-i);o<=Mi&&(a-=o)}else l<=Mi&&(a+=l);return{width:a,height:o,x:s,y:c}}function Pi(e,t){let n=Ei(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=ti(e)?Si(e):dr(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function Fi(e,t,n){let r;if(t===`viewport`)r=Ni(e,n);else if(t===`document`)r=ji(Qr(e));else if(ei(t))r=Pi(t,n);else{let n=wi(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return Nr(r)}function Ii(e,t){let n=gi(e);return n===t||!ei(n)||pi(n)?!1:mi(n).position===`fixed`||Ii(n,t)}function Li(e,t){let n=t.get(e);if(n)return n;let r=vi(e,[],!1).filter(e=>ei(e)&&Xr(e)!==`body`),i=null,a=mi(e).position===`fixed`,o=a?gi(e):e;for(;ei(o)&&!pi(o);){let t=mi(o),n=ui(o);!n&&t.position===`fixed`&&(i=null),(a?!n&&!i:!n&&t.position===`static`&&i&&(i.position===`absolute`||i.position===`fixed`)||ri(o)&&!n&&Ii(e,o))?r=r.filter(e=>e!==o):i=t,o=gi(o)}return t.set(e,r),r}function Ri(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?ai(t)?[]:Li(t,this._c):[].concat(n),r],o=Fi(t,a[0],i),s=o.top,c=o.right,l=o.bottom,u=o.left;for(let e=1;e<a.length;e++){let n=Fi(t,a[e],i);s=cr(n.top,s),c=sr(n.right,c),l=sr(n.bottom,l),u=cr(n.left,u)}return{width:c-u,height:l-s,x:u,y:s}}function zi(e){let{width:t,height:n}=bi(e);return{width:t,height:n}}function Bi(e,t,n){let r=ti(t),i=Qr(t),a=n===`fixed`,o=Ei(e,!0,a,t),s={scrollLeft:0,scrollTop:0},c=dr(0);function l(){c.x=Di(i)}if(r||!r&&!a)if((Xr(t)!==`body`||ri(i))&&(s=hi(t)),r){let e=Ei(t,!0,a,t);c.x=e.x+t.clientLeft,c.y=e.y+t.clientTop}else i&&l();a&&!r&&i&&l();let u=i&&!r&&!a?Oi(i,s):dr(0);return{x:o.left+s.scrollLeft-c.x-u.x,y:o.top+s.scrollTop-c.y-u.y,width:o.width,height:o.height}}function Vi(e){return mi(e).position===`static`}function Hi(e,t){if(!ti(e)||mi(e).position===`fixed`)return null;if(t)return t(e);let n=e.offsetParent;return Qr(e)===n&&(n=n.ownerDocument.body),n}function Ui(e,t){let n=Zr(e);if(ai(e))return n;if(!ti(e)){let t=gi(e);for(;t&&!pi(t);){if(ei(t)&&!Vi(t))return t;t=gi(t)}return n}let r=Hi(e,t);for(;r&&ii(r)&&Vi(r);)r=Hi(r,t);return r&&pi(r)&&Vi(r)&&!ui(r)?n:r||di(e)||n}var Wi=async function(e){let t=this.getOffsetParent||Ui,n=this.getDimensions,r=await n(e.floating);return{reference:Bi(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Gi(e){return mi(e).direction===`rtl`}var Ki={convertOffsetParentRelativeRectToViewportRelativeRect:ki,getDocumentElement:Qr,getClippingRect:Ri,getOffsetParent:Ui,getElementRects:Wi,getClientRects:Ai,getDimensions:zi,getScale:Si,isElement:ei,isRTL:Gi};function qi(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Ji(e,t){let n=null,r,i=Qr(e);function a(){var e;clearTimeout(r),(e=n)==null||e.disconnect(),n=null}function o(s,c){s===void 0&&(s=!1),c===void 0&&(c=1),a();let l=e.getBoundingClientRect(),{left:u,top:d,width:f,height:p}=l;if(s||t(),!f||!p)return;let m=ur(d),h=ur(i.clientWidth-(u+f)),g=ur(i.clientHeight-(d+p)),_=ur(u),v={rootMargin:-m+`px `+-h+`px `+-g+`px `+-_+`px`,threshold:cr(0,sr(1,c))||1},y=!0;function b(t){let n=t[0].intersectionRatio;if(n!==c){if(!y)return o();n?o(!1,n):r=setTimeout(()=>{o(!1,1e-7)},1e3)}n===1&&!qi(l,e.getBoundingClientRect())&&o(),y=!1}try{n=new IntersectionObserver(b,{...v,root:i.ownerDocument})}catch{n=new IntersectionObserver(b,v)}n.observe(e)}return o(!0),a}function Yi(e,t,n,r){r===void 0&&(r={});let{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:o=typeof ResizeObserver==`function`,layoutShift:s=typeof IntersectionObserver==`function`,animationFrame:c=!1}=r,l=xi(e),u=i||a?[...l?vi(l):[],...t?vi(t):[]]:[];u.forEach(e=>{i&&e.addEventListener(`scroll`,n,{passive:!0}),a&&e.addEventListener(`resize`,n)});let d=l&&s?Ji(l,n):null,f=-1,p=null;o&&(p=new ResizeObserver(e=>{let[r]=e;r&&r.target===l&&p&&t&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var e;(e=p)==null||e.observe(t)})),n()}),l&&!c&&p.observe(l),t&&p.observe(t));let m,h=c?Ei(e):null;c&&g();function g(){let t=Ei(e);h&&!qi(h,t)&&n(),h=t,m=requestAnimationFrame(g)}return n(),()=>{var e;u.forEach(e=>{i&&e.removeEventListener(`scroll`,n),a&&e.removeEventListener(`resize`,n)}),d?.(),(e=p)==null||e.disconnect(),p=null,c&&cancelAnimationFrame(m)}}var Xi=Gr,Zi=Kr,Qi=zr,$i=Jr,ea=Hr,ta=Rr,na=qr,ra=(e,t,n)=>{let r=new Map,i={platform:Ki,...n},a={...i.platform,_c:r};return Lr(e,t,{...i,platform:a})},ia=typeof document<`u`?d.useLayoutEffect:function(){};function aa(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e==`function`&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e==`object`){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!aa(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){let n=i[r];if(!(n===`_owner`&&e.$$typeof)&&!aa(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function oa(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function sa(e,t){let n=oa(e);return Math.round(t*n)/n}function ca(e){let t=d.useRef(e);return ia(()=>{t.current=e}),t}function la(e){e===void 0&&(e={});let{placement:t=`bottom`,strategy:n=`absolute`,middleware:r=[],platform:i,elements:{reference:a,floating:o}={},transform:s=!0,whileElementsMounted:c,open:l}=e,[u,f]=d.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,m]=d.useState(r);aa(p,r)||m(r);let[h,g]=d.useState(null),[_,v]=d.useState(null),y=d.useCallback(e=>{e!==C.current&&(C.current=e,g(e))},[]),b=d.useCallback(e=>{e!==w.current&&(w.current=e,v(e))},[]),x=a||h,S=o||_,C=d.useRef(null),w=d.useRef(null),T=d.useRef(u),D=c!=null,O=ca(c),ee=ca(i),te=ca(l),k=d.useCallback(()=>{if(!C.current||!w.current)return;let e={placement:t,strategy:n,middleware:p};ee.current&&(e.platform=ee.current),ra(C.current,w.current,e).then(e=>{let t={...e,isPositioned:te.current!==!1};A.current&&!aa(T.current,t)&&(T.current=t,E.flushSync(()=>{f(t)}))})},[p,t,n,ee,te]);ia(()=>{l===!1&&T.current.isPositioned&&(T.current.isPositioned=!1,f(e=>({...e,isPositioned:!1})))},[l]);let A=d.useRef(!1);ia(()=>(A.current=!0,()=>{A.current=!1}),[]),ia(()=>{if(x&&(C.current=x),S&&(w.current=S),x&&S){if(O.current)return O.current(x,S,k);k()}},[x,S,k,O,D]);let j=d.useMemo(()=>({reference:C,floating:w,setReference:y,setFloating:b}),[y,b]),M=d.useMemo(()=>({reference:x,floating:S}),[x,S]),ne=d.useMemo(()=>{let e={position:n,left:0,top:0};if(!M.floating)return e;let t=sa(M.floating,u.x),r=sa(M.floating,u.y);return s?{...e,transform:`translate(`+t+`px, `+r+`px)`,...oa(M.floating)>=1.5&&{willChange:`transform`}}:{position:n,left:t,top:r}},[n,s,M.floating,u.x,u.y]);return d.useMemo(()=>({...u,update:k,refs:j,elements:M,floatingStyles:ne}),[u,k,j,M,ne])}var ua=e=>{function t(e){return{}.hasOwnProperty.call(e,`current`)}return{name:`arrow`,options:e,fn(n){let{element:r,padding:i}=typeof e==`function`?e(n):e;return r&&t(r)?r.current==null?{}:ta({element:r.current,padding:i}).fn(n):r?ta({element:r,padding:i}).fn(n):{}}}},da=(e,t)=>{let n=Xi(e);return{name:n.name,fn:n.fn,options:[e,t]}},fa=(e,t)=>{let n=Zi(e);return{name:n.name,fn:n.fn,options:[e,t]}},pa=(e,t)=>({fn:na(e).fn,options:[e,t]}),ma=(e,t)=>{let n=Qi(e);return{name:n.name,fn:n.fn,options:[e,t]}},ha=(e,t)=>{let n=$i(e);return{name:n.name,fn:n.fn,options:[e,t]}},ga=(e,t)=>{let n=ea(e);return{name:n.name,fn:n.fn,options:[e,t]}},_a=(e,t)=>{let n=ua(e);return{name:n.name,fn:n.fn,options:[e,t]}},va=`Arrow`,ya=d.forwardRef((e,t)=>{let{children:n,width:r=10,height:i=5,...a}=e;return(0,_.jsx)(D.svg,{...a,ref:t,width:r,height:i,viewBox:`0 0 30 10`,preserveAspectRatio:`none`,children:e.asChild?n:(0,_.jsx)(`polygon`,{points:`0,0 30,0 15,10`})})});ya.displayName=va;var ba=ya,xa=`Popper`,[Sa,Ca]=M(xa),[wa,Ta]=Sa(xa),Ea=e=>{let{__scopePopper:t,children:n}=e,[r,i]=d.useState(null);return(0,_.jsx)(wa,{scope:t,anchor:r,onAnchorChange:i,children:n})};Ea.displayName=xa;var Da=`PopperAnchor`,Oa=d.forwardRef((e,t)=>{let{__scopePopper:n,virtualRef:r,...i}=e,a=Ta(Da,n),o=d.useRef(null),s=m(t,o),c=d.useRef(null);return d.useEffect(()=>{let e=c.current;c.current=r?.current||o.current,e!==c.current&&a.onAnchorChange(c.current)}),r?null:(0,_.jsx)(D.div,{...i,ref:s})});Oa.displayName=Da;var ka=`PopperContent`,[Aa,ja]=Sa(ka),Ma=d.forwardRef((e,t)=>{let{__scopePopper:n,side:r=`bottom`,sideOffset:i=0,align:a=`center`,alignOffset:o=0,arrowPadding:s=0,avoidCollisions:c=!0,collisionBoundary:l=[],collisionPadding:u=0,sticky:f=`partial`,hideWhenDetached:p=!1,updatePositionStrategy:h=`optimized`,onPlaced:g,...v}=e,y=Ta(ka,n),[b,x]=d.useState(null),S=m(t,e=>x(e)),[C,w]=d.useState(null),T=ar(C),E=T?.width??0,O=T?.height??0,ee=r+(a===`center`?``:`-`+a),te=typeof u==`number`?u:{top:0,right:0,bottom:0,left:0,...u},k=Array.isArray(l)?l:[l],A=k.length>0,j={padding:te,boundary:k.filter(Ia),altBoundary:A},{refs:M,floatingStyles:ne,placement:N,isPositioned:P,middlewareData:ie}=la({strategy:`fixed`,placement:ee,whileElementsMounted:(...e)=>Yi(...e,{animationFrame:h===`always`}),elements:{reference:y.anchor},middleware:[da({mainAxis:i+O,alignmentAxis:o}),c&&fa({mainAxis:!0,crossAxis:!1,limiter:f===`partial`?pa():void 0,...j}),c&&ma({...j}),ha({...j,apply:({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{let{width:i,height:a}=t.reference,o=e.floating.style;o.setProperty(`--radix-popper-available-width`,`${n}px`),o.setProperty(`--radix-popper-available-height`,`${r}px`),o.setProperty(`--radix-popper-anchor-width`,`${i}px`),o.setProperty(`--radix-popper-anchor-height`,`${a}px`)}}),C&&_a({element:C,padding:s}),La({arrowWidth:E,arrowHeight:O}),p&&ga({strategy:`referenceHidden`,...j})]}),[ae,oe]=Ra(N),F=ge(g);re(()=>{P&&F?.()},[P,F]);let I=ie.arrow?.x,se=ie.arrow?.y,ce=ie.arrow?.centerOffset!==0,[le,ue]=d.useState();return re(()=>{b&&ue(window.getComputedStyle(b).zIndex)},[b]),(0,_.jsx)(`div`,{ref:M.setFloating,"data-radix-popper-content-wrapper":``,style:{...ne,transform:P?ne.transform:`translate(0, -200%)`,minWidth:`max-content`,zIndex:le,"--radix-popper-transform-origin":[ie.transformOrigin?.x,ie.transformOrigin?.y].join(` `),...ie.hide?.referenceHidden&&{visibility:`hidden`,pointerEvents:`none`}},dir:e.dir,children:(0,_.jsx)(Aa,{scope:n,placedSide:ae,onArrowChange:w,arrowX:I,arrowY:se,shouldHideArrow:ce,children:(0,_.jsx)(D.div,{"data-side":ae,"data-align":oe,...v,ref:S,style:{...v.style,animation:P?void 0:`none`}})})})});Ma.displayName=ka;var Na=`PopperArrow`,Pa={top:`bottom`,right:`left`,bottom:`top`,left:`right`},Fa=d.forwardRef(function(e,t){let{__scopePopper:n,...r}=e,i=ja(Na,n),a=Pa[i.placedSide];return(0,_.jsx)(`span`,{ref:i.onArrowChange,style:{position:`absolute`,left:i.arrowX,top:i.arrowY,[a]:0,transformOrigin:{top:``,right:`0 0`,bottom:`center 0`,left:`100% 0`}[i.placedSide],transform:{top:`translateY(100%)`,right:`translateY(50%) rotate(90deg) translateX(-50%)`,bottom:`rotate(180deg)`,left:`translateY(50%) rotate(-90deg) translateX(50%)`}[i.placedSide],visibility:i.shouldHideArrow?`hidden`:void 0},children:(0,_.jsx)(ba,{...r,ref:t,style:{...r.style,display:`block`}})})});Fa.displayName=Na;function Ia(e){return e!==null}var La=e=>({name:`transformOrigin`,options:e,fn(t){let{placement:n,rects:r,middlewareData:i}=t,a=i.arrow?.centerOffset!==0,o=a?0:e.arrowWidth,s=a?0:e.arrowHeight,[c,l]=Ra(n),u={start:`0%`,center:`50%`,end:`100%`}[l],d=(i.arrow?.x??0)+o/2,f=(i.arrow?.y??0)+s/2,p=``,m=``;return c===`bottom`?(p=a?u:`${d}px`,m=`${-s}px`):c===`top`?(p=a?u:`${d}px`,m=`${r.floating.height+s}px`):c===`right`?(p=`${-s}px`,m=a?u:`${f}px`):c===`left`&&(p=`${r.floating.width+s}px`,m=a?u:`${f}px`),{data:{x:p,y:m}}}});function Ra(e){let[t,n=`center`]=e.split(`-`);return[t,n]}var za=Ea,Ba=Oa,Va=Ma,Ha=Fa;function Ua(e,[t,n]){return Math.min(n,Math.max(t,e))}var Wa=`Popover`,[Ga,Ka]=M(Wa,[Ca]),qa=Ca(),[Ja,Ya]=Ga(Wa),Xa=e=>{let{__scopePopover:t,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!1}=e,s=qa(t),c=d.useRef(null),[l,u]=d.useState(!1),[f,p]=ae({prop:r,defaultProp:i??!1,onChange:a,caller:Wa});return(0,_.jsx)(za,{...s,children:(0,_.jsx)(Ja,{scope:t,contentId:pe(),triggerRef:c,open:f,onOpenChange:p,onOpenToggle:d.useCallback(()=>p(e=>!e),[p]),hasCustomAnchor:l,onCustomAnchorAdd:d.useCallback(()=>u(!0),[]),onCustomAnchorRemove:d.useCallback(()=>u(!1),[]),modal:o,children:n})})};Xa.displayName=Wa;var Za=`PopoverAnchor`,Qa=d.forwardRef((e,t)=>{let{__scopePopover:n,...r}=e,i=Ya(Za,n),a=qa(n),{onCustomAnchorAdd:o,onCustomAnchorRemove:s}=i;return d.useEffect(()=>(o(),()=>s()),[o,s]),(0,_.jsx)(Ba,{...a,...r,ref:t})});Qa.displayName=Za;var $a=`PopoverTrigger`,eo=d.forwardRef((e,t)=>{let{__scopePopover:n,...r}=e,i=Ya($a,n),a=qa(n),o=m(t,i.triggerRef),s=(0,_.jsx)(D.button,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":i.open,"aria-controls":i.contentId,"data-state":go(i.open),...r,ref:o,onClick:P(e.onClick,i.onOpenToggle)});return i.hasCustomAnchor?s:(0,_.jsx)(Ba,{asChild:!0,...a,children:s})});eo.displayName=$a;var to=`PopoverPortal`,[no,ro]=Ga(to,{forceMount:void 0}),io=e=>{let{__scopePopover:t,forceMount:n,children:r,container:i}=e,a=Ya(to,t);return(0,_.jsx)(no,{scope:t,forceMount:n,children:(0,_.jsx)(se,{present:n||a.open,children:(0,_.jsx)(Je,{asChild:!0,container:i,children:r})})})};io.displayName=to;var ao=`PopoverContent`,oo=d.forwardRef((e,t)=>{let n=ro(ao,e.__scopePopover),{forceMount:r=n.forceMount,...i}=e,a=Ya(ao,e.__scopePopover);return(0,_.jsx)(se,{present:r||a.open,children:a.modal?(0,_.jsx)(co,{...i,ref:t}):(0,_.jsx)(lo,{...i,ref:t})})});oo.displayName=ao;var so=v(`PopoverContent.RemoveScroll`),co=d.forwardRef((e,t)=>{let n=Ya(ao,e.__scopePopover),r=d.useRef(null),i=m(t,r),a=d.useRef(!1);return d.useEffect(()=>{let e=r.current;if(e)return gn(e)},[]),(0,_.jsx)(sn,{as:so,allowPinchZoom:!0,children:(0,_.jsx)(uo,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:P(e.onCloseAutoFocus,e=>{e.preventDefault(),a.current||n.triggerRef.current?.focus()}),onPointerDownOutside:P(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0;a.current=t.button===2||n},{checkForDefaultPrevented:!1}),onFocusOutside:P(e.onFocusOutside,e=>e.preventDefault(),{checkForDefaultPrevented:!1})})})}),lo=d.forwardRef((e,t)=>{let n=Ya(ao,e.__scopePopover),r=d.useRef(!1),i=d.useRef(!1);return(0,_.jsx)(uo,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(r.current||n.triggerRef.current?.focus(),t.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(r.current=!0,t.detail.originalEvent.type===`pointerdown`&&(i.current=!0));let a=t.target;n.triggerRef.current?.contains(a)&&t.preventDefault(),t.detail.originalEvent.type===`focusin`&&i.current&&t.preventDefault()}})}),uo=d.forwardRef((e,t)=>{let{__scopePopover:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,disableOutsidePointerEvents:o,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:l,onInteractOutside:u,...d}=e,f=Ya(ao,n),p=qa(n);return Xe(),(0,_.jsx)(Fe,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:a,children:(0,_.jsx)(we,{asChild:!0,disableOutsidePointerEvents:o,onInteractOutside:u,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:l,onDismiss:()=>f.onOpenChange(!1),children:(0,_.jsx)(Va,{"data-state":go(f.open),role:`dialog`,id:f.contentId,...p,...d,ref:t,style:{...d.style,"--radix-popover-content-transform-origin":`var(--radix-popper-transform-origin)`,"--radix-popover-content-available-width":`var(--radix-popper-available-width)`,"--radix-popover-content-available-height":`var(--radix-popper-available-height)`,"--radix-popover-trigger-width":`var(--radix-popper-anchor-width)`,"--radix-popover-trigger-height":`var(--radix-popper-anchor-height)`}})})})}),fo=`PopoverClose`,po=d.forwardRef((e,t)=>{let{__scopePopover:n,...r}=e,i=Ya(fo,n);return(0,_.jsx)(D.button,{type:`button`,...r,ref:t,onClick:P(e.onClick,()=>i.onOpenChange(!1))})});po.displayName=fo;var mo=`PopoverArrow`,ho=d.forwardRef((e,t)=>{let{__scopePopover:n,...r}=e,i=qa(n);return(0,_.jsx)(Ha,{...i,...r,ref:t})});ho.displayName=mo;function go(e){return e?`open`:`closed`}var _o=Xa,vo=eo,yo=io,bo=oo,xo=`Progress`,So=100,[Co,wo]=M(xo),[To,Eo]=Co(xo),Do=d.forwardRef((e,t)=>{let{__scopeProgress:n,value:r=null,max:i,getValueLabel:a=Ao,...o}=e;(i||i===0)&&!No(i)&&console.error(Fo(`${i}`,`Progress`));let s=No(i)?i:So;r!==null&&!Po(r,s)&&console.error(Io(`${r}`,`Progress`));let c=Po(r,s)?r:null,l=Mo(c)?a(c,s):void 0;return(0,_.jsx)(To,{scope:n,value:c,max:s,children:(0,_.jsx)(D.div,{"aria-valuemax":s,"aria-valuemin":0,"aria-valuenow":Mo(c)?c:void 0,"aria-valuetext":l,role:`progressbar`,"data-state":jo(c,s),"data-value":c??void 0,"data-max":s,...o,ref:t})})});Do.displayName=xo;var Oo=`ProgressIndicator`,ko=d.forwardRef((e,t)=>{let{__scopeProgress:n,...r}=e,i=Eo(Oo,n);return(0,_.jsx)(D.div,{"data-state":jo(i.value,i.max),"data-value":i.value??void 0,"data-max":i.max,...r,ref:t})});ko.displayName=Oo;function Ao(e,t){return`${Math.round(e/t*100)}%`}function jo(e,t){return e==null?`indeterminate`:e===t?`complete`:`loading`}function Mo(e){return typeof e==`number`}function No(e){return Mo(e)&&!isNaN(e)&&e>0}function Po(e,t){return Mo(e)&&!isNaN(e)&&e<=t&&e>=0}function Fo(e,t){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${t}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${So}\`.`}function Io(e,t){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${t}\`. The \`value\` prop must be:
55
- - a positive number
56
- - less than the value passed to \`max\` (or ${So} if no \`max\` prop is set)
57
- - \`null\` or \`undefined\` if the progress is indeterminate.
58
-
59
- Defaulting to \`null\`.`}var Lo=Do,Ro=ko;function zo(e,t){return d.useReducer((e,n)=>t[e][n]??e,e)}var Bo=`ScrollArea`,[Vo,Ho]=M(Bo),[Uo,Wo]=Vo(Bo),Go=d.forwardRef((e,t)=>{let{__scopeScrollArea:n,type:r=`hover`,dir:i,scrollHideDelay:a=600,...o}=e,[s,c]=d.useState(null),[l,u]=d.useState(null),[f,p]=d.useState(null),[h,g]=d.useState(null),[v,y]=d.useState(null),[b,x]=d.useState(0),[S,C]=d.useState(0),[w,T]=d.useState(!1),[E,O]=d.useState(!1),ee=m(t,e=>c(e)),te=he(i);return(0,_.jsx)(Uo,{scope:n,type:r,dir:te,scrollHideDelay:a,scrollArea:s,viewport:l,onViewportChange:u,content:f,onContentChange:p,scrollbarX:h,onScrollbarXChange:g,scrollbarXEnabled:w,onScrollbarXEnabledChange:T,scrollbarY:v,onScrollbarYChange:y,scrollbarYEnabled:E,onScrollbarYEnabledChange:O,onCornerWidthChange:x,onCornerHeightChange:C,children:(0,_.jsx)(D.div,{dir:te,...o,ref:ee,style:{position:`relative`,"--radix-scroll-area-corner-width":b+`px`,"--radix-scroll-area-corner-height":S+`px`,...e.style}})})});Go.displayName=Bo;var Ko=`ScrollAreaViewport`,qo=d.forwardRef((e,t)=>{let{__scopeScrollArea:n,children:r,nonce:i,...a}=e,o=Wo(Ko,n),s=m(t,d.useRef(null),o.onViewportChange);return(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(`style`,{dangerouslySetInnerHTML:{__html:`[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}`},nonce:i}),(0,_.jsx)(D.div,{"data-radix-scroll-area-viewport":``,...a,ref:s,style:{overflowX:o.scrollbarXEnabled?`scroll`:`hidden`,overflowY:o.scrollbarYEnabled?`scroll`:`hidden`,...e.style},children:(0,_.jsx)(`div`,{ref:o.onContentChange,style:{minWidth:`100%`,display:`table`},children:r})})]})});qo.displayName=Ko;var Jo=`ScrollAreaScrollbar`,Yo=d.forwardRef((e,t)=>{let{forceMount:n,...r}=e,i=Wo(Jo,e.__scopeScrollArea),{onScrollbarXEnabledChange:a,onScrollbarYEnabledChange:o}=i,s=e.orientation===`horizontal`;return d.useEffect(()=>(s?a(!0):o(!0),()=>{s?a(!1):o(!1)}),[s,a,o]),i.type===`hover`?(0,_.jsx)(Xo,{...r,ref:t,forceMount:n}):i.type===`scroll`?(0,_.jsx)(Zo,{...r,ref:t,forceMount:n}):i.type===`auto`?(0,_.jsx)(Qo,{...r,ref:t,forceMount:n}):i.type===`always`?(0,_.jsx)($o,{...r,ref:t}):null});Yo.displayName=Jo;var Xo=d.forwardRef((e,t)=>{let{forceMount:n,...r}=e,i=Wo(Jo,e.__scopeScrollArea),[a,o]=d.useState(!1);return d.useEffect(()=>{let e=i.scrollArea,t=0;if(e){let n=()=>{window.clearTimeout(t),o(!0)},r=()=>{t=window.setTimeout(()=>o(!1),i.scrollHideDelay)};return e.addEventListener(`pointerenter`,n),e.addEventListener(`pointerleave`,r),()=>{window.clearTimeout(t),e.removeEventListener(`pointerenter`,n),e.removeEventListener(`pointerleave`,r)}}},[i.scrollArea,i.scrollHideDelay]),(0,_.jsx)(se,{present:n||a,children:(0,_.jsx)(Qo,{"data-state":a?`visible`:`hidden`,...r,ref:t})})}),Zo=d.forwardRef((e,t)=>{let{forceMount:n,...r}=e,i=Wo(Jo,e.__scopeScrollArea),a=e.orientation===`horizontal`,o=ys(()=>c(`SCROLL_END`),100),[s,c]=zo(`hidden`,{hidden:{SCROLL:`scrolling`},scrolling:{SCROLL_END:`idle`,POINTER_ENTER:`interacting`},interacting:{SCROLL:`interacting`,POINTER_LEAVE:`idle`},idle:{HIDE:`hidden`,SCROLL:`scrolling`,POINTER_ENTER:`interacting`}});return d.useEffect(()=>{if(s===`idle`){let e=window.setTimeout(()=>c(`HIDE`),i.scrollHideDelay);return()=>window.clearTimeout(e)}},[s,i.scrollHideDelay,c]),d.useEffect(()=>{let e=i.viewport,t=a?`scrollLeft`:`scrollTop`;if(e){let n=e[t],r=()=>{let r=e[t];n!==r&&(c(`SCROLL`),o()),n=r};return e.addEventListener(`scroll`,r),()=>e.removeEventListener(`scroll`,r)}},[i.viewport,a,c,o]),(0,_.jsx)(se,{present:n||s!==`hidden`,children:(0,_.jsx)($o,{"data-state":s===`hidden`?`hidden`:`visible`,...r,ref:t,onPointerEnter:P(e.onPointerEnter,()=>c(`POINTER_ENTER`)),onPointerLeave:P(e.onPointerLeave,()=>c(`POINTER_LEAVE`))})})}),Qo=d.forwardRef((e,t)=>{let n=Wo(Jo,e.__scopeScrollArea),{forceMount:r,...i}=e,[a,o]=d.useState(!1),s=e.orientation===`horizontal`,c=ys(()=>{if(n.viewport){let e=n.viewport.offsetWidth<n.viewport.scrollWidth,t=n.viewport.offsetHeight<n.viewport.scrollHeight;o(s?e:t)}},10);return bs(n.viewport,c),bs(n.content,c),(0,_.jsx)(se,{present:r||a,children:(0,_.jsx)($o,{"data-state":a?`visible`:`hidden`,...i,ref:t})})}),$o=d.forwardRef((e,t)=>{let{orientation:n=`vertical`,...r}=e,i=Wo(Jo,e.__scopeScrollArea),a=d.useRef(null),o=d.useRef(0),[s,c]=d.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),l=fs(s.viewport,s.content),u={...r,sizes:s,onSizesChange:c,hasThumb:l>0&&l<1,onThumbChange:e=>a.current=e,onThumbPointerUp:()=>o.current=0,onThumbPointerDown:e=>o.current=e};function f(e,t){return ms(e,o.current,s,t)}return n===`horizontal`?(0,_.jsx)(es,{...u,ref:t,onThumbPositionChange:()=>{if(i.viewport&&a.current){let e=i.viewport.scrollLeft,t=hs(e,s,i.dir);a.current.style.transform=`translate3d(${t}px, 0, 0)`}},onWheelScroll:e=>{i.viewport&&(i.viewport.scrollLeft=e)},onDragScroll:e=>{i.viewport&&(i.viewport.scrollLeft=f(e,i.dir))}}):n===`vertical`?(0,_.jsx)(ts,{...u,ref:t,onThumbPositionChange:()=>{if(i.viewport&&a.current){let e=i.viewport.scrollTop,t=hs(e,s);a.current.style.transform=`translate3d(0, ${t}px, 0)`}},onWheelScroll:e=>{i.viewport&&(i.viewport.scrollTop=e)},onDragScroll:e=>{i.viewport&&(i.viewport.scrollTop=f(e))}}):null}),es=d.forwardRef((e,t)=>{let{sizes:n,onSizesChange:r,...i}=e,a=Wo(Jo,e.__scopeScrollArea),[o,s]=d.useState(),c=d.useRef(null),l=m(t,c,a.onScrollbarXChange);return d.useEffect(()=>{c.current&&s(getComputedStyle(c.current))},[c]),(0,_.jsx)(is,{"data-orientation":`horizontal`,...i,ref:l,sizes:n,style:{bottom:0,left:a.dir===`rtl`?`var(--radix-scroll-area-corner-width)`:0,right:a.dir===`ltr`?`var(--radix-scroll-area-corner-width)`:0,"--radix-scroll-area-thumb-width":ps(n)+`px`,...e.style},onThumbPointerDown:t=>e.onThumbPointerDown(t.x),onDragScroll:t=>e.onDragScroll(t.x),onWheelScroll:(t,n)=>{if(a.viewport){let r=a.viewport.scrollLeft+t.deltaX;e.onWheelScroll(r),_s(r,n)&&t.preventDefault()}},onResize:()=>{c.current&&a.viewport&&o&&r({content:a.viewport.scrollWidth,viewport:a.viewport.offsetWidth,scrollbar:{size:c.current.clientWidth,paddingStart:ds(o.paddingLeft),paddingEnd:ds(o.paddingRight)}})}})}),ts=d.forwardRef((e,t)=>{let{sizes:n,onSizesChange:r,...i}=e,a=Wo(Jo,e.__scopeScrollArea),[o,s]=d.useState(),c=d.useRef(null),l=m(t,c,a.onScrollbarYChange);return d.useEffect(()=>{c.current&&s(getComputedStyle(c.current))},[c]),(0,_.jsx)(is,{"data-orientation":`vertical`,...i,ref:l,sizes:n,style:{top:0,right:a.dir===`ltr`?0:void 0,left:a.dir===`rtl`?0:void 0,bottom:`var(--radix-scroll-area-corner-height)`,"--radix-scroll-area-thumb-height":ps(n)+`px`,...e.style},onThumbPointerDown:t=>e.onThumbPointerDown(t.y),onDragScroll:t=>e.onDragScroll(t.y),onWheelScroll:(t,n)=>{if(a.viewport){let r=a.viewport.scrollTop+t.deltaY;e.onWheelScroll(r),_s(r,n)&&t.preventDefault()}},onResize:()=>{c.current&&a.viewport&&o&&r({content:a.viewport.scrollHeight,viewport:a.viewport.offsetHeight,scrollbar:{size:c.current.clientHeight,paddingStart:ds(o.paddingTop),paddingEnd:ds(o.paddingBottom)}})}})}),[ns,rs]=Vo(Jo),is=d.forwardRef((e,t)=>{let{__scopeScrollArea:n,sizes:r,hasThumb:i,onThumbChange:a,onThumbPointerUp:o,onThumbPointerDown:s,onThumbPositionChange:c,onDragScroll:l,onWheelScroll:u,onResize:f,...p}=e,h=Wo(Jo,n),[g,v]=d.useState(null),y=m(t,e=>v(e)),b=d.useRef(null),x=d.useRef(``),S=h.viewport,C=r.content-r.viewport,w=ge(u),T=ge(c),E=ys(f,10);function O(e){b.current&&l({x:e.clientX-b.current.left,y:e.clientY-b.current.top})}return d.useEffect(()=>{let e=e=>{let t=e.target;g?.contains(t)&&w(e,C)};return document.addEventListener(`wheel`,e,{passive:!1}),()=>document.removeEventListener(`wheel`,e,{passive:!1})},[S,g,C,w]),d.useEffect(T,[r,T]),bs(g,E),bs(h.content,E),(0,_.jsx)(ns,{scope:n,scrollbar:g,hasThumb:i,onThumbChange:ge(a),onThumbPointerUp:ge(o),onThumbPositionChange:T,onThumbPointerDown:ge(s),children:(0,_.jsx)(D.div,{...p,ref:y,style:{position:`absolute`,...p.style},onPointerDown:P(e.onPointerDown,e=>{e.button===0&&(e.target.setPointerCapture(e.pointerId),b.current=g.getBoundingClientRect(),x.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect=`none`,h.viewport&&(h.viewport.style.scrollBehavior=`auto`),O(e))}),onPointerMove:P(e.onPointerMove,O),onPointerUp:P(e.onPointerUp,e=>{let t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),document.body.style.webkitUserSelect=x.current,h.viewport&&(h.viewport.style.scrollBehavior=``),b.current=null})})})}),as=`ScrollAreaThumb`,os=d.forwardRef((e,t)=>{let{forceMount:n,...r}=e,i=rs(as,e.__scopeScrollArea);return(0,_.jsx)(se,{present:n||i.hasThumb,children:(0,_.jsx)(ss,{ref:t,...r})})}),ss=d.forwardRef((e,t)=>{let{__scopeScrollArea:n,style:r,...i}=e,a=Wo(as,n),o=rs(as,n),{onThumbPositionChange:s}=o,c=m(t,e=>o.onThumbChange(e)),l=d.useRef(void 0),u=ys(()=>{l.current&&=(l.current(),void 0)},100);return d.useEffect(()=>{let e=a.viewport;if(e){let t=()=>{u(),l.current||(l.current=vs(e,s),s())};return s(),e.addEventListener(`scroll`,t),()=>e.removeEventListener(`scroll`,t)}},[a.viewport,u,s]),(0,_.jsx)(D.div,{"data-state":o.hasThumb?`visible`:`hidden`,...i,ref:c,style:{width:`var(--radix-scroll-area-thumb-width)`,height:`var(--radix-scroll-area-thumb-height)`,...r},onPointerDownCapture:P(e.onPointerDownCapture,e=>{let t=e.target.getBoundingClientRect(),n=e.clientX-t.left,r=e.clientY-t.top;o.onThumbPointerDown({x:n,y:r})}),onPointerUp:P(e.onPointerUp,o.onThumbPointerUp)})});os.displayName=as;var cs=`ScrollAreaCorner`,ls=d.forwardRef((e,t)=>{let n=Wo(cs,e.__scopeScrollArea),r=!!(n.scrollbarX&&n.scrollbarY);return n.type!==`scroll`&&r?(0,_.jsx)(us,{...e,ref:t}):null});ls.displayName=cs;var us=d.forwardRef((e,t)=>{let{__scopeScrollArea:n,...r}=e,i=Wo(cs,n),[a,o]=d.useState(0),[s,c]=d.useState(0),l=!!(a&&s);return bs(i.scrollbarX,()=>{let e=i.scrollbarX?.offsetHeight||0;i.onCornerHeightChange(e),c(e)}),bs(i.scrollbarY,()=>{let e=i.scrollbarY?.offsetWidth||0;i.onCornerWidthChange(e),o(e)}),l?(0,_.jsx)(D.div,{...r,ref:t,style:{width:a,height:s,position:`absolute`,right:i.dir===`ltr`?0:void 0,left:i.dir===`rtl`?0:void 0,bottom:0,...e.style}}):null});function ds(e){return e?parseInt(e,10):0}function fs(e,t){let n=e/t;return isNaN(n)?0:n}function ps(e){let t=fs(e.viewport,e.content),n=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,r=(e.scrollbar.size-n)*t;return Math.max(r,18)}function ms(e,t,n,r=`ltr`){let i=ps(n),a=i/2,o=t||a,s=i-o,c=n.scrollbar.paddingStart+o,l=n.scrollbar.size-n.scrollbar.paddingEnd-s,u=n.content-n.viewport,d=r===`ltr`?[0,u]:[u*-1,0];return gs([c,l],d)(e)}function hs(e,t,n=`ltr`){let r=ps(t),i=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,a=t.scrollbar.size-i,o=t.content-t.viewport,s=a-r,c=Ua(e,n===`ltr`?[0,o]:[o*-1,0]);return gs([0,o],[0,s])(c)}function gs(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];let r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}function _s(e,t){return e>0&&e<t}var vs=(e,t=()=>{})=>{let n={left:e.scrollLeft,top:e.scrollTop},r=0;return(function i(){let a={left:e.scrollLeft,top:e.scrollTop},o=n.left!==a.left,s=n.top!==a.top;(o||s)&&t(),n=a,r=window.requestAnimationFrame(i)})(),()=>window.cancelAnimationFrame(r)};function ys(e,t){let n=ge(e),r=d.useRef(0);return d.useEffect(()=>()=>window.clearTimeout(r.current),[]),d.useCallback(()=>{window.clearTimeout(r.current),r.current=window.setTimeout(n,t)},[n,t])}function bs(e,t){let n=ge(t);re(()=>{let t=0;if(e){let r=new ResizeObserver(()=>{cancelAnimationFrame(t),t=window.requestAnimationFrame(n)});return r.observe(e),()=>{window.cancelAnimationFrame(t),r.unobserve(e)}}},[e,n])}var xs=Go,Ss=qo,Cs=ls,ws=[` `,`Enter`,`ArrowUp`,`ArrowDown`],Ts=[` `,`Enter`],Es=`Select`,[Ds,Os,ks]=N(Es),[As,js]=M(Es,[ks,Ca]),Ms=Ca(),[Ns,Ps]=As(Es),[Fs,Is]=As(Es),Ls=e=>{let{__scopeSelect:t,children:n,open:r,defaultOpen:i,onOpenChange:a,value:o,defaultValue:s,onValueChange:c,dir:l,name:u,autoComplete:f,disabled:p,required:m,form:h}=e,g=Ms(t),[v,y]=d.useState(null),[b,x]=d.useState(null),[S,C]=d.useState(!1),w=he(l),[T,E]=ae({prop:r,defaultProp:i??!1,onChange:a,caller:Es}),[D,O]=ae({prop:o,defaultProp:s,onChange:c,caller:Es}),ee=d.useRef(null),te=v?h||!!v.closest(`form`):!0,[k,A]=d.useState(new Set),j=Array.from(k).map(e=>e.props.value).join(`;`);return(0,_.jsx)(za,{...g,children:(0,_.jsxs)(Ns,{required:m,scope:t,trigger:v,onTriggerChange:y,valueNode:b,onValueNodeChange:x,valueNodeHasChildren:S,onValueNodeHasChildrenChange:C,contentId:pe(),value:D,onValueChange:O,open:T,onOpenChange:E,dir:w,triggerPointerDownPosRef:ee,disabled:p,children:[(0,_.jsx)(Ds.Provider,{scope:t,children:(0,_.jsx)(Fs,{scope:e.__scopeSelect,onNativeOptionAdd:d.useCallback(e=>{A(t=>new Set(t).add(e))},[]),onNativeOptionRemove:d.useCallback(e=>{A(t=>{let n=new Set(t);return n.delete(e),n})},[]),children:n})}),te?(0,_.jsxs)(Mc,{"aria-hidden":!0,required:m,tabIndex:-1,name:u,autoComplete:f,value:D,onChange:e=>O(e.target.value),disabled:p,form:h,children:[D===void 0?(0,_.jsx)(`option`,{value:``}):null,Array.from(k)]},j):null]})})};Ls.displayName=Es;var Rs=`SelectTrigger`,zs=d.forwardRef((e,t)=>{let{__scopeSelect:n,disabled:r=!1,...i}=e,a=Ms(n),o=Ps(Rs,n),s=o.disabled||r,c=m(t,o.onTriggerChange),l=Os(n),u=d.useRef(`touch`),[f,p,h]=Pc(e=>{let t=l().filter(e=>!e.disabled),n=Fc(t,e,t.find(e=>e.value===o.value));n!==void 0&&o.onValueChange(n.value)}),g=e=>{s||(o.onOpenChange(!0),h()),e&&(o.triggerPointerDownPosRef.current={x:Math.round(e.pageX),y:Math.round(e.pageY)})};return(0,_.jsx)(Ba,{asChild:!0,...a,children:(0,_.jsx)(D.button,{type:`button`,role:`combobox`,"aria-controls":o.contentId,"aria-expanded":o.open,"aria-required":o.required,"aria-autocomplete":`none`,dir:o.dir,"data-state":o.open?`open`:`closed`,disabled:s,"data-disabled":s?``:void 0,"data-placeholder":Nc(o.value)?``:void 0,...i,ref:c,onClick:P(i.onClick,e=>{e.currentTarget.focus(),u.current!==`mouse`&&g(e)}),onPointerDown:P(i.onPointerDown,e=>{u.current=e.pointerType;let t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),e.button===0&&e.ctrlKey===!1&&e.pointerType===`mouse`&&(g(e),e.preventDefault())}),onKeyDown:P(i.onKeyDown,e=>{let t=f.current!==``;!(e.ctrlKey||e.altKey||e.metaKey)&&e.key.length===1&&p(e.key),!(t&&e.key===` `)&&ws.includes(e.key)&&(g(),e.preventDefault())})})})});zs.displayName=Rs;var Bs=`SelectValue`,Vs=d.forwardRef((e,t)=>{let{__scopeSelect:n,className:r,style:i,children:a,placeholder:o=``,...s}=e,c=Ps(Bs,n),{onValueNodeHasChildrenChange:l}=c,u=a!==void 0,d=m(t,c.onValueNodeChange);return re(()=>{l(u)},[l,u]),(0,_.jsx)(D.span,{...s,ref:d,style:{pointerEvents:`none`},children:Nc(c.value)?(0,_.jsx)(_.Fragment,{children:o}):a})});Vs.displayName=Bs;var Hs=`SelectIcon`,Us=d.forwardRef((e,t)=>{let{__scopeSelect:n,children:r,...i}=e;return(0,_.jsx)(D.span,{"aria-hidden":!0,...i,ref:t,children:r||`▼`})});Us.displayName=Hs;var Ws=`SelectPortal`,Gs=e=>(0,_.jsx)(Je,{asChild:!0,...e});Gs.displayName=Ws;var Ks=`SelectContent`,qs=d.forwardRef((e,t)=>{let n=Ps(Ks,e.__scopeSelect),[r,i]=d.useState();if(re(()=>{i(new DocumentFragment)},[]),!n.open){let t=r;return t?E.createPortal((0,_.jsx)(Ys,{scope:e.__scopeSelect,children:(0,_.jsx)(Ds.Slot,{scope:e.__scopeSelect,children:(0,_.jsx)(`div`,{children:e.children})})}),t):null}return(0,_.jsx)($s,{...e,ref:t})});qs.displayName=Ks;var Js=10,[Ys,Xs]=As(Ks),Zs=`SelectContentImpl`,Qs=v(`SelectContent.RemoveScroll`),$s=d.forwardRef((e,t)=>{let{__scopeSelect:n,position:r=`item-aligned`,onCloseAutoFocus:i,onEscapeKeyDown:a,onPointerDownOutside:o,side:s,sideOffset:c,align:l,alignOffset:u,arrowPadding:f,collisionBoundary:p,collisionPadding:h,sticky:g,hideWhenDetached:v,avoidCollisions:y,...b}=e,x=Ps(Ks,n),[S,C]=d.useState(null),[w,T]=d.useState(null),E=m(t,e=>C(e)),[D,O]=d.useState(null),[ee,te]=d.useState(null),k=Os(n),[A,j]=d.useState(!1),M=d.useRef(!1);d.useEffect(()=>{if(S)return gn(S)},[S]),Xe();let ne=d.useCallback(e=>{let[t,...n]=k().map(e=>e.ref.current),[r]=n.slice(-1),i=document.activeElement;for(let n of e)if(n===i||(n?.scrollIntoView({block:`nearest`}),n===t&&w&&(w.scrollTop=0),n===r&&w&&(w.scrollTop=w.scrollHeight),n?.focus(),document.activeElement!==i))return},[k,w]),N=d.useCallback(()=>ne([D,S]),[ne,D,S]);d.useEffect(()=>{A&&N()},[A,N]);let{onOpenChange:re,triggerPointerDownPosRef:ie}=x;d.useEffect(()=>{if(S){let e={x:0,y:0},t=t=>{e={x:Math.abs(Math.round(t.pageX)-(ie.current?.x??0)),y:Math.abs(Math.round(t.pageY)-(ie.current?.y??0))}},n=n=>{e.x<=10&&e.y<=10?n.preventDefault():S.contains(n.target)||re(!1),document.removeEventListener(`pointermove`,t),ie.current=null};return ie.current!==null&&(document.addEventListener(`pointermove`,t),document.addEventListener(`pointerup`,n,{capture:!0,once:!0})),()=>{document.removeEventListener(`pointermove`,t),document.removeEventListener(`pointerup`,n,{capture:!0})}}},[S,re,ie]),d.useEffect(()=>{let e=()=>re(!1);return window.addEventListener(`blur`,e),window.addEventListener(`resize`,e),()=>{window.removeEventListener(`blur`,e),window.removeEventListener(`resize`,e)}},[re]);let[ae,oe]=Pc(e=>{let t=k().filter(e=>!e.disabled),n=Fc(t,e,t.find(e=>e.ref.current===document.activeElement));n&&setTimeout(()=>n.ref.current.focus())}),F=d.useCallback((e,t,n)=>{let r=!M.current&&!n;(x.value!==void 0&&x.value===t||r)&&(O(e),r&&(M.current=!0))},[x.value]),I=d.useCallback(()=>S?.focus(),[S]),se=d.useCallback((e,t,n)=>{let r=!M.current&&!n;(x.value!==void 0&&x.value===t||r)&&te(e)},[x.value]),ce=r===`popper`?rc:tc,le=ce===rc?{side:s,sideOffset:c,align:l,alignOffset:u,arrowPadding:f,collisionBoundary:p,collisionPadding:h,sticky:g,hideWhenDetached:v,avoidCollisions:y}:{};return(0,_.jsx)(Ys,{scope:n,content:S,viewport:w,onViewportChange:T,itemRefCallback:F,selectedItem:D,onItemLeave:I,itemTextRefCallback:se,focusSelectedItem:N,selectedItemText:ee,position:r,isPositioned:A,searchRef:ae,children:(0,_.jsx)(sn,{as:Qs,allowPinchZoom:!0,children:(0,_.jsx)(Fe,{asChild:!0,trapped:x.open,onMountAutoFocus:e=>{e.preventDefault()},onUnmountAutoFocus:P(i,e=>{x.trigger?.focus({preventScroll:!0}),e.preventDefault()}),children:(0,_.jsx)(we,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:a,onPointerDownOutside:o,onFocusOutside:e=>e.preventDefault(),onDismiss:()=>x.onOpenChange(!1),children:(0,_.jsx)(ce,{role:`listbox`,id:x.contentId,"data-state":x.open?`open`:`closed`,dir:x.dir,onContextMenu:e=>e.preventDefault(),...b,...le,onPlaced:()=>j(!0),ref:E,style:{display:`flex`,flexDirection:`column`,outline:`none`,...b.style},onKeyDown:P(b.onKeyDown,e=>{let t=e.ctrlKey||e.altKey||e.metaKey;if(e.key===`Tab`&&e.preventDefault(),!t&&e.key.length===1&&oe(e.key),[`ArrowUp`,`ArrowDown`,`Home`,`End`].includes(e.key)){let t=k().filter(e=>!e.disabled).map(e=>e.ref.current);if([`ArrowUp`,`End`].includes(e.key)&&(t=t.slice().reverse()),[`ArrowUp`,`ArrowDown`].includes(e.key)){let n=e.target,r=t.indexOf(n);t=t.slice(r+1)}setTimeout(()=>ne(t)),e.preventDefault()}})})})})})})});$s.displayName=Zs;var ec=`SelectItemAlignedPosition`,tc=d.forwardRef((e,t)=>{let{__scopeSelect:n,onPlaced:r,...i}=e,a=Ps(Ks,n),o=Xs(Ks,n),[s,c]=d.useState(null),[l,u]=d.useState(null),f=m(t,e=>u(e)),p=Os(n),h=d.useRef(!1),g=d.useRef(!0),{viewport:v,selectedItem:y,selectedItemText:b,focusSelectedItem:x}=o,S=d.useCallback(()=>{if(a.trigger&&a.valueNode&&s&&l&&v&&y&&b){let e=a.trigger.getBoundingClientRect(),t=l.getBoundingClientRect(),n=a.valueNode.getBoundingClientRect(),i=b.getBoundingClientRect();if(a.dir!==`rtl`){let r=i.left-t.left,a=n.left-r,o=e.left-a,c=e.width+o,l=Math.max(c,t.width),u=window.innerWidth-Js,d=Ua(a,[Js,Math.max(Js,u-l)]);s.style.minWidth=c+`px`,s.style.left=d+`px`}else{let r=t.right-i.right,a=window.innerWidth-n.right-r,o=window.innerWidth-e.right-a,c=e.width+o,l=Math.max(c,t.width),u=window.innerWidth-Js,d=Ua(a,[Js,Math.max(Js,u-l)]);s.style.minWidth=c+`px`,s.style.right=d+`px`}let o=p(),c=window.innerHeight-Js*2,u=v.scrollHeight,d=window.getComputedStyle(l),f=parseInt(d.borderTopWidth,10),m=parseInt(d.paddingTop,10),g=parseInt(d.borderBottomWidth,10),_=parseInt(d.paddingBottom,10),x=f+m+u+_+g,S=Math.min(y.offsetHeight*5,x),C=window.getComputedStyle(v),w=parseInt(C.paddingTop,10),T=parseInt(C.paddingBottom,10),E=e.top+e.height/2-Js,D=c-E,O=y.offsetHeight/2,ee=y.offsetTop+O,te=f+m+ee,k=x-te;if(te<=E){let e=o.length>0&&y===o[o.length-1].ref.current;s.style.bottom=`0px`;let t=l.clientHeight-v.offsetTop-v.offsetHeight,n=te+Math.max(D,O+(e?T:0)+t+g);s.style.height=n+`px`}else{let e=o.length>0&&y===o[0].ref.current;s.style.top=`0px`;let t=Math.max(E,f+v.offsetTop+(e?w:0)+O)+k;s.style.height=t+`px`,v.scrollTop=te-E+v.offsetTop}s.style.margin=`${Js}px 0`,s.style.minHeight=S+`px`,s.style.maxHeight=c+`px`,r?.(),requestAnimationFrame(()=>h.current=!0)}},[p,a.trigger,a.valueNode,s,l,v,y,b,a.dir,r]);re(()=>S(),[S]);let[C,w]=d.useState();return re(()=>{l&&w(window.getComputedStyle(l).zIndex)},[l]),(0,_.jsx)(ic,{scope:n,contentWrapper:s,shouldExpandOnScrollRef:h,onScrollButtonChange:d.useCallback(e=>{e&&g.current===!0&&(S(),x?.(),g.current=!1)},[S,x]),children:(0,_.jsx)(`div`,{ref:c,style:{display:`flex`,flexDirection:`column`,position:`fixed`,zIndex:C},children:(0,_.jsx)(D.div,{...i,ref:f,style:{boxSizing:`border-box`,maxHeight:`100%`,...i.style}})})})});tc.displayName=ec;var nc=`SelectPopperPosition`,rc=d.forwardRef((e,t)=>{let{__scopeSelect:n,align:r=`start`,collisionPadding:i=Js,...a}=e,o=Ms(n);return(0,_.jsx)(Va,{...o,...a,ref:t,align:r,collisionPadding:i,style:{boxSizing:`border-box`,...a.style,"--radix-select-content-transform-origin":`var(--radix-popper-transform-origin)`,"--radix-select-content-available-width":`var(--radix-popper-available-width)`,"--radix-select-content-available-height":`var(--radix-popper-available-height)`,"--radix-select-trigger-width":`var(--radix-popper-anchor-width)`,"--radix-select-trigger-height":`var(--radix-popper-anchor-height)`}})});rc.displayName=nc;var[ic,ac]=As(Ks,{}),oc=`SelectViewport`,sc=d.forwardRef((e,t)=>{let{__scopeSelect:n,nonce:r,...i}=e,a=Xs(oc,n),o=ac(oc,n),s=m(t,a.onViewportChange),c=d.useRef(0);return(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(`style`,{dangerouslySetInnerHTML:{__html:`[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}`},nonce:r}),(0,_.jsx)(Ds.Slot,{scope:n,children:(0,_.jsx)(D.div,{"data-radix-select-viewport":``,role:`presentation`,...i,ref:s,style:{position:`relative`,flex:1,overflow:`hidden auto`,...i.style},onScroll:P(i.onScroll,e=>{let t=e.currentTarget,{contentWrapper:n,shouldExpandOnScrollRef:r}=o;if(r?.current&&n){let e=Math.abs(c.current-t.scrollTop);if(e>0){let r=window.innerHeight-Js*2,i=parseFloat(n.style.minHeight),a=parseFloat(n.style.height),o=Math.max(i,a);if(o<r){let i=o+e,a=Math.min(r,i),s=i-a;n.style.height=a+`px`,n.style.bottom===`0px`&&(t.scrollTop=s>0?s:0,n.style.justifyContent=`flex-end`)}}}c.current=t.scrollTop})})})]})});sc.displayName=oc;var cc=`SelectGroup`,[lc,uc]=As(cc),dc=d.forwardRef((e,t)=>{let{__scopeSelect:n,...r}=e,i=pe();return(0,_.jsx)(lc,{scope:n,id:i,children:(0,_.jsx)(D.div,{role:`group`,"aria-labelledby":i,...r,ref:t})})});dc.displayName=cc;var fc=`SelectLabel`,pc=d.forwardRef((e,t)=>{let{__scopeSelect:n,...r}=e,i=uc(fc,n);return(0,_.jsx)(D.div,{id:i.id,...r,ref:t})});pc.displayName=fc;var mc=`SelectItem`,[hc,gc]=As(mc),_c=d.forwardRef((e,t)=>{let{__scopeSelect:n,value:r,disabled:i=!1,textValue:a,...o}=e,s=Ps(mc,n),c=Xs(mc,n),l=s.value===r,[u,f]=d.useState(a??``),[p,h]=d.useState(!1),g=m(t,e=>c.itemRefCallback?.(e,r,i)),v=pe(),y=d.useRef(`touch`),b=()=>{i||(s.onValueChange(r),s.onOpenChange(!1))};if(r===``)throw Error(`A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.`);return(0,_.jsx)(hc,{scope:n,value:r,disabled:i,textId:v,isSelected:l,onItemTextChange:d.useCallback(e=>{f(t=>t||(e?.textContent??``).trim())},[]),children:(0,_.jsx)(Ds.ItemSlot,{scope:n,value:r,disabled:i,textValue:u,children:(0,_.jsx)(D.div,{role:`option`,"aria-labelledby":v,"data-highlighted":p?``:void 0,"aria-selected":l&&p,"data-state":l?`checked`:`unchecked`,"aria-disabled":i||void 0,"data-disabled":i?``:void 0,tabIndex:i?void 0:-1,...o,ref:g,onFocus:P(o.onFocus,()=>h(!0)),onBlur:P(o.onBlur,()=>h(!1)),onClick:P(o.onClick,()=>{y.current!==`mouse`&&b()}),onPointerUp:P(o.onPointerUp,()=>{y.current===`mouse`&&b()}),onPointerDown:P(o.onPointerDown,e=>{y.current=e.pointerType}),onPointerMove:P(o.onPointerMove,e=>{y.current=e.pointerType,i?c.onItemLeave?.():y.current===`mouse`&&e.currentTarget.focus({preventScroll:!0})}),onPointerLeave:P(o.onPointerLeave,e=>{e.currentTarget===document.activeElement&&c.onItemLeave?.()}),onKeyDown:P(o.onKeyDown,e=>{c.searchRef?.current!==``&&e.key===` `||(Ts.includes(e.key)&&b(),e.key===` `&&e.preventDefault())})})})})});_c.displayName=mc;var vc=`SelectItemText`,yc=d.forwardRef((e,t)=>{let{__scopeSelect:n,className:r,style:i,...a}=e,o=Ps(vc,n),s=Xs(vc,n),c=gc(vc,n),l=Is(vc,n),[u,f]=d.useState(null),p=m(t,e=>f(e),c.onItemTextChange,e=>s.itemTextRefCallback?.(e,c.value,c.disabled)),h=u?.textContent,g=d.useMemo(()=>(0,_.jsx)(`option`,{value:c.value,disabled:c.disabled,children:h},c.value),[c.disabled,c.value,h]),{onNativeOptionAdd:v,onNativeOptionRemove:y}=l;return re(()=>(v(g),()=>y(g)),[v,y,g]),(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(D.span,{id:c.textId,...a,ref:p}),c.isSelected&&o.valueNode&&!o.valueNodeHasChildren?E.createPortal(a.children,o.valueNode):null]})});yc.displayName=vc;var bc=`SelectItemIndicator`,xc=d.forwardRef((e,t)=>{let{__scopeSelect:n,...r}=e;return gc(bc,n).isSelected?(0,_.jsx)(D.span,{"aria-hidden":!0,...r,ref:t}):null});xc.displayName=bc;var Sc=`SelectScrollUpButton`,Cc=d.forwardRef((e,t)=>{let n=Xs(Sc,e.__scopeSelect),r=ac(Sc,e.__scopeSelect),[i,a]=d.useState(!1),o=m(t,r.onScrollButtonChange);return re(()=>{if(n.viewport&&n.isPositioned){let e=function(){a(t.scrollTop>0)},t=n.viewport;return e(),t.addEventListener(`scroll`,e),()=>t.removeEventListener(`scroll`,e)}},[n.viewport,n.isPositioned]),i?(0,_.jsx)(Ec,{...e,ref:o,onAutoScroll:()=>{let{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop-=t.offsetHeight)}}):null});Cc.displayName=Sc;var wc=`SelectScrollDownButton`,Tc=d.forwardRef((e,t)=>{let n=Xs(wc,e.__scopeSelect),r=ac(wc,e.__scopeSelect),[i,a]=d.useState(!1),o=m(t,r.onScrollButtonChange);return re(()=>{if(n.viewport&&n.isPositioned){let e=function(){let e=t.scrollHeight-t.clientHeight;a(Math.ceil(t.scrollTop)<e)},t=n.viewport;return e(),t.addEventListener(`scroll`,e),()=>t.removeEventListener(`scroll`,e)}},[n.viewport,n.isPositioned]),i?(0,_.jsx)(Ec,{...e,ref:o,onAutoScroll:()=>{let{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop+=t.offsetHeight)}}):null});Tc.displayName=wc;var Ec=d.forwardRef((e,t)=>{let{__scopeSelect:n,onAutoScroll:r,...i}=e,a=Xs(`SelectScrollButton`,n),o=d.useRef(null),s=Os(n),c=d.useCallback(()=>{o.current!==null&&(window.clearInterval(o.current),o.current=null)},[]);return d.useEffect(()=>()=>c(),[c]),re(()=>{s().find(e=>e.ref.current===document.activeElement)?.ref.current?.scrollIntoView({block:`nearest`})},[s]),(0,_.jsx)(D.div,{"aria-hidden":!0,...i,ref:t,style:{flexShrink:0,...i.style},onPointerDown:P(i.onPointerDown,()=>{o.current===null&&(o.current=window.setInterval(r,50))}),onPointerMove:P(i.onPointerMove,()=>{a.onItemLeave?.(),o.current===null&&(o.current=window.setInterval(r,50))}),onPointerLeave:P(i.onPointerLeave,()=>{c()})})}),Dc=`SelectSeparator`,Oc=d.forwardRef((e,t)=>{let{__scopeSelect:n,...r}=e;return(0,_.jsx)(D.div,{"aria-hidden":!0,...r,ref:t})});Oc.displayName=Dc;var kc=`SelectArrow`,Ac=d.forwardRef((e,t)=>{let{__scopeSelect:n,...r}=e,i=Ms(n),a=Ps(kc,n),o=Xs(kc,n);return a.open&&o.position===`popper`?(0,_.jsx)(Ha,{...i,...r,ref:t}):null});Ac.displayName=kc;var jc=`SelectBubbleInput`,Mc=d.forwardRef(({__scopeSelect:e,value:t,...n},r)=>{let i=d.useRef(null),a=m(r,i),o=ir(t);return d.useEffect(()=>{let e=i.current;if(!e)return;let n=window.HTMLSelectElement.prototype,r=Object.getOwnPropertyDescriptor(n,`value`).set;if(o!==t&&r){let n=new Event(`change`,{bubbles:!0});r.call(e,t),e.dispatchEvent(n)}},[o,t]),(0,_.jsx)(D.select,{...n,style:{...ee,...n.style},ref:a,defaultValue:t})});Mc.displayName=jc;function Nc(e){return e===``||e===void 0}function Pc(e){let t=ge(e),n=d.useRef(``),r=d.useRef(0),i=d.useCallback(e=>{let i=n.current+e;t(i),(function e(t){n.current=t,window.clearTimeout(r.current),t!==``&&(r.current=window.setTimeout(()=>e(``),1e3))})(i)},[t]),a=d.useCallback(()=>{n.current=``,window.clearTimeout(r.current)},[]);return d.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,i,a]}function Fc(e,t,n){let r=t.length>1&&Array.from(t).every(e=>e===t[0])?t[0]:t,i=n?e.indexOf(n):-1,a=Ic(e,Math.max(i,0));r.length===1&&(a=a.filter(e=>e!==n));let o=a.find(e=>e.textValue.toLowerCase().startsWith(r.toLowerCase()));return o===n?void 0:o}function Ic(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var Lc=Ls,Rc=zs,zc=Vs,Bc=Us,Vc=Gs,Hc=qs,Uc=sc,Wc=_c,Gc=yc,Kc=xc,qc=Cc,Jc=Tc,Yc=`Separator`,Xc=`horizontal`,Zc=[`horizontal`,`vertical`],Qc=d.forwardRef((e,t)=>{let{decorative:n,orientation:r=Xc,...i}=e,a=$c(r)?r:Xc,o=n?{role:`none`}:{"aria-orientation":a===`vertical`?a:void 0,role:`separator`};return(0,_.jsx)(D.div,{"data-orientation":a,...o,...i,ref:t})});Qc.displayName=Yc;function $c(e){return Zc.includes(e)}var el=Qc,[tl,nl]=M(`Tooltip`,[Ca]),rl=Ca(),il=`TooltipProvider`,al=700,ol=`tooltip.open`,[sl,cl]=tl(il),ll=e=>{let{__scopeTooltip:t,delayDuration:n=al,skipDelayDuration:r=300,disableHoverableContent:i=!1,children:a}=e,o=d.useRef(!0),s=d.useRef(!1),c=d.useRef(0);return d.useEffect(()=>{let e=c.current;return()=>window.clearTimeout(e)},[]),(0,_.jsx)(sl,{scope:t,isOpenDelayedRef:o,delayDuration:n,onOpen:d.useCallback(()=>{window.clearTimeout(c.current),o.current=!1},[]),onClose:d.useCallback(()=>{window.clearTimeout(c.current),c.current=window.setTimeout(()=>o.current=!0,r)},[r]),isPointerInTransitRef:s,onPointerInTransitChange:d.useCallback(e=>{s.current=e},[]),disableHoverableContent:i,children:a})};ll.displayName=il;var ul=`Tooltip`,[dl,fl]=tl(ul),pl=e=>{let{__scopeTooltip:t,children:n,open:r,defaultOpen:i,onOpenChange:a,disableHoverableContent:o,delayDuration:s}=e,c=cl(ul,e.__scopeTooltip),l=rl(t),[u,f]=d.useState(null),p=pe(),m=d.useRef(0),h=o??c.disableHoverableContent,g=s??c.delayDuration,v=d.useRef(!1),[y,b]=ae({prop:r,defaultProp:i??!1,onChange:e=>{e?(c.onOpen(),document.dispatchEvent(new CustomEvent(ol))):c.onClose(),a?.(e)},caller:ul}),x=d.useMemo(()=>y?v.current?`delayed-open`:`instant-open`:`closed`,[y]),S=d.useCallback(()=>{window.clearTimeout(m.current),m.current=0,v.current=!1,b(!0)},[b]),C=d.useCallback(()=>{window.clearTimeout(m.current),m.current=0,b(!1)},[b]),w=d.useCallback(()=>{window.clearTimeout(m.current),m.current=window.setTimeout(()=>{v.current=!0,b(!0),m.current=0},g)},[g,b]);return d.useEffect(()=>()=>{m.current&&=(window.clearTimeout(m.current),0)},[]),(0,_.jsx)(za,{...l,children:(0,_.jsx)(dl,{scope:t,contentId:p,open:y,stateAttribute:x,trigger:u,onTriggerChange:f,onTriggerEnter:d.useCallback(()=>{c.isOpenDelayedRef.current?w():S()},[c.isOpenDelayedRef,w,S]),onTriggerLeave:d.useCallback(()=>{h?C():(window.clearTimeout(m.current),m.current=0)},[C,h]),onOpen:S,onClose:C,disableHoverableContent:h,children:n})})};pl.displayName=ul;var ml=`TooltipTrigger`,hl=d.forwardRef((e,t)=>{let{__scopeTooltip:n,...r}=e,i=fl(ml,n),a=cl(ml,n),o=rl(n),s=m(t,d.useRef(null),i.onTriggerChange),c=d.useRef(!1),l=d.useRef(!1),u=d.useCallback(()=>c.current=!1,[]);return d.useEffect(()=>()=>document.removeEventListener(`pointerup`,u),[u]),(0,_.jsx)(Ba,{asChild:!0,...o,children:(0,_.jsx)(D.button,{"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute,...r,ref:s,onPointerMove:P(e.onPointerMove,e=>{e.pointerType!==`touch`&&!l.current&&!a.isPointerInTransitRef.current&&(i.onTriggerEnter(),l.current=!0)}),onPointerLeave:P(e.onPointerLeave,()=>{i.onTriggerLeave(),l.current=!1}),onPointerDown:P(e.onPointerDown,()=>{i.open&&i.onClose(),c.current=!0,document.addEventListener(`pointerup`,u,{once:!0})}),onFocus:P(e.onFocus,()=>{c.current||i.onOpen()}),onBlur:P(e.onBlur,i.onClose),onClick:P(e.onClick,i.onClose)})})});hl.displayName=ml;var gl=`TooltipPortal`,[_l,vl]=tl(gl,{forceMount:void 0}),yl=e=>{let{__scopeTooltip:t,forceMount:n,children:r,container:i}=e,a=fl(gl,t);return(0,_.jsx)(_l,{scope:t,forceMount:n,children:(0,_.jsx)(se,{present:n||a.open,children:(0,_.jsx)(Je,{asChild:!0,container:i,children:r})})})};yl.displayName=gl;var bl=`TooltipContent`,xl=d.forwardRef((e,t)=>{let n=vl(bl,e.__scopeTooltip),{forceMount:r=n.forceMount,side:i=`top`,...a}=e,o=fl(bl,e.__scopeTooltip);return(0,_.jsx)(se,{present:r||o.open,children:o.disableHoverableContent?(0,_.jsx)(El,{side:i,...a,ref:t}):(0,_.jsx)(Sl,{side:i,...a,ref:t})})}),Sl=d.forwardRef((e,t)=>{let n=fl(bl,e.__scopeTooltip),r=cl(bl,e.__scopeTooltip),i=d.useRef(null),a=m(t,i),[o,s]=d.useState(null),{trigger:c,onClose:l}=n,u=i.current,{onPointerInTransitChange:f}=r,p=d.useCallback(()=>{s(null),f(!1)},[f]),h=d.useCallback((e,t)=>{let n=e.currentTarget,r={x:e.clientX,y:e.clientY},i=Al(r,kl(r,n.getBoundingClientRect())),a=jl(t.getBoundingClientRect());s(Nl([...i,...a])),f(!0)},[f]);return d.useEffect(()=>()=>p(),[p]),d.useEffect(()=>{if(c&&u){let e=e=>h(e,u),t=e=>h(e,c);return c.addEventListener(`pointerleave`,e),u.addEventListener(`pointerleave`,t),()=>{c.removeEventListener(`pointerleave`,e),u.removeEventListener(`pointerleave`,t)}}},[c,u,h,p]),d.useEffect(()=>{if(o){let e=e=>{let t=e.target,n={x:e.clientX,y:e.clientY},r=c?.contains(t)||u?.contains(t),i=!Ml(n,o);r?p():i&&(p(),l())};return document.addEventListener(`pointermove`,e),()=>document.removeEventListener(`pointermove`,e)}},[c,u,o,l,p]),(0,_.jsx)(El,{...e,ref:a})}),[Cl,wl]=tl(ul,{isInside:!1}),Tl=S(`TooltipContent`),El=d.forwardRef((e,t)=>{let{__scopeTooltip:n,children:r,"aria-label":i,onEscapeKeyDown:a,onPointerDownOutside:o,...s}=e,c=fl(bl,n),l=rl(n),{onClose:u}=c;return d.useEffect(()=>(document.addEventListener(ol,u),()=>document.removeEventListener(ol,u)),[u]),d.useEffect(()=>{if(c.trigger){let e=e=>{e.target?.contains(c.trigger)&&u()};return window.addEventListener(`scroll`,e,{capture:!0}),()=>window.removeEventListener(`scroll`,e,{capture:!0})}},[c.trigger,u]),(0,_.jsx)(we,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:o,onFocusOutside:e=>e.preventDefault(),onDismiss:u,children:(0,_.jsxs)(Va,{"data-state":c.stateAttribute,...l,...s,ref:t,style:{...s.style,"--radix-tooltip-content-transform-origin":`var(--radix-popper-transform-origin)`,"--radix-tooltip-content-available-width":`var(--radix-popper-available-width)`,"--radix-tooltip-content-available-height":`var(--radix-popper-available-height)`,"--radix-tooltip-trigger-width":`var(--radix-popper-anchor-width)`,"--radix-tooltip-trigger-height":`var(--radix-popper-anchor-height)`},children:[(0,_.jsx)(Tl,{children:r}),(0,_.jsx)(Cl,{scope:n,isInside:!0,children:(0,_.jsx)(A,{id:c.contentId,role:`tooltip`,children:i||r})})]})})});xl.displayName=bl;var Dl=`TooltipArrow`,Ol=d.forwardRef((e,t)=>{let{__scopeTooltip:n,...r}=e,i=rl(n);return wl(Dl,n).isInside?null:(0,_.jsx)(Ha,{...i,...r,ref:t})});Ol.displayName=Dl;function kl(e,t){let n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(n,r,i,a)){case a:return`left`;case i:return`right`;case n:return`top`;case r:return`bottom`;default:throw Error(`unreachable`)}}function Al(e,t,n=5){let r=[];switch(t){case`top`:r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case`bottom`:r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case`left`:r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case`right`:r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function jl(e){let{top:t,right:n,bottom:r,left:i}=e;return[{x:i,y:t},{x:n,y:t},{x:n,y:r},{x:i,y:r}]}function Ml(e,t){let{x:n,y:r}=e,i=!1;for(let e=0,a=t.length-1;e<t.length;a=e++){let o=t[e],s=t[a],c=o.x,l=o.y,u=s.x,d=s.y;l>r!=d>r&&n<(u-c)*(r-l)/(d-l)+c&&(i=!i)}return i}function Nl(e){let t=e.slice();return t.sort((e,t)=>e.x<t.x?-1:e.x>t.x?1:e.y<t.y?-1:+(e.y>t.y)),Pl(t)}function Pl(e){if(e.length<=1)return e.slice();let t=[];for(let n=0;n<e.length;n++){let r=e[n];for(;t.length>=2;){let e=t[t.length-1],n=t[t.length-2];if((e.x-n.x)*(r.y-n.y)>=(e.y-n.y)*(r.x-n.x))t.pop();else break}t.push(r)}t.pop();let n=[];for(let t=e.length-1;t>=0;t--){let r=e[t];for(;n.length>=2;){let e=n[n.length-1],t=n[n.length-2];if((e.x-t.x)*(r.y-t.y)>=(e.y-t.y)*(r.x-t.x))n.pop();else break}n.push(r)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var Fl=ll,Il=pl,Ll=hl,Rl=yl,zl=xl,Bl=Ol,Vl=u();function Hl(e){var t,n,r=``;if(typeof e==`string`||typeof e==`number`)r+=e;else if(typeof e==`object`)if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=Hl(e[t]))&&(r&&(r+=` `),r+=n)}else for(n in e)e[n]&&(r&&(r+=` `),r+=n);return r}function Ul(){for(var e,t,n=0,r=``,i=arguments.length;n<i;n++)(e=arguments[n])&&(t=Hl(e))&&(r&&(r+=` `),r+=t);return r}var Wl=(e,t)=>{let n=Array(e.length+t.length);for(let t=0;t<e.length;t++)n[t]=e[t];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n},Gl=(e,t)=>({classGroupId:e,validator:t}),Kl=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),ql=`-`,Jl=[],Yl=`arbitrary..`,Xl=e=>{let t=$l(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:e=>{if(e.startsWith(`[`)&&e.endsWith(`]`))return Ql(e);let n=e.split(ql);return Zl(n,+(n[0]===``&&n.length>1),t)},getConflictingClassGroupIds:(e,t)=>{if(t){let t=r[e],i=n[e];return t?i?Wl(i,t):t:i||Jl}return n[e]||Jl}}},Zl=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;let r=e[t],i=n.nextPart.get(r);if(i){let n=Zl(e,t+1,i);if(n)return n}let a=n.validators;if(a===null)return;let o=t===0?e.join(ql):e.slice(t).join(ql),s=a.length;for(let e=0;e<s;e++){let t=a[e];if(t.validator(o))return t.classGroupId}},Ql=e=>e.slice(1,-1).indexOf(`:`)===-1?void 0:(()=>{let t=e.slice(1,-1),n=t.indexOf(`:`),r=t.slice(0,n);return r?Yl+r:void 0})(),$l=e=>{let{theme:t,classGroups:n}=e;return eu(n,t)},eu=(e,t)=>{let n=Kl();for(let r in e){let i=e[r];tu(i,n,r,t)}return n},tu=(e,t,n,r)=>{let i=e.length;for(let a=0;a<i;a++){let i=e[a];nu(i,t,n,r)}},nu=(e,t,n,r)=>{if(typeof e==`string`){ru(e,t,n);return}if(typeof e==`function`){iu(e,t,n,r);return}au(e,t,n,r)},ru=(e,t,n)=>{let r=e===``?t:ou(t,e);r.classGroupId=n},iu=(e,t,n,r)=>{if(su(e)){tu(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(Gl(n,e))},au=(e,t,n,r)=>{let i=Object.entries(e),a=i.length;for(let e=0;e<a;e++){let[a,o]=i[e];tu(o,ou(t,a),n,r)}},ou=(e,t)=>{let n=e,r=t.split(ql),i=r.length;for(let e=0;e<i;e++){let t=r[e],i=n.nextPart.get(t);i||(i=Kl(),n.nextPart.set(t,i)),n=i}return n},su=e=>`isThemeGetter`in e&&e.isThemeGetter===!0,cu=e=>{if(e<1)return{get:()=>void 0,set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null),i=(i,a)=>{n[i]=a,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(e){let t=n[e];if(t!==void 0)return t;if((t=r[e])!==void 0)return i(e,t),t},set(e,t){e in n?n[e]=t:i(e,t)}}},lu=`!`,uu=`:`,du=[],fu=(e,t,n,r,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),pu=e=>{let{prefix:t,experimentalParseClassName:n}=e,r=e=>{let t=[],n=0,r=0,i=0,a,o=e.length;for(let s=0;s<o;s++){let o=e[s];if(n===0&&r===0){if(o===uu){t.push(e.slice(i,s)),i=s+1;continue}if(o===`/`){a=s;continue}}o===`[`?n++:o===`]`?n--:o===`(`?r++:o===`)`&&r--}let s=t.length===0?e:e.slice(i),c=s,l=!1;s.endsWith(lu)?(c=s.slice(0,-1),l=!0):s.startsWith(lu)&&(c=s.slice(1),l=!0);let u=a&&a>i?a-i:void 0;return fu(t,l,c,u)};if(t){let e=t+uu,n=r;r=t=>t.startsWith(e)?n(t.slice(e.length)):fu(du,!1,t,void 0,!0)}if(n){let e=r;r=t=>n({className:t,parseClassName:e})}return r},mu=e=>{let t=new Map;return e.orderSensitiveModifiers.forEach((e,n)=>{t.set(e,1e6+n)}),e=>{let n=[],r=[];for(let i=0;i<e.length;i++){let a=e[i],o=a[0]===`[`,s=t.has(a);o||s?(r.length>0&&(r.sort(),n.push(...r),r=[]),n.push(a)):r.push(a)}return r.length>0&&(r.sort(),n.push(...r)),n}},hu=e=>({cache:cu(e.cacheSize),parseClassName:pu(e),sortModifiers:mu(e),...Xl(e)}),gu=/\s+/,_u=(e,t)=>{let{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:a}=t,o=[],s=e.trim().split(gu),c=``;for(let e=s.length-1;e>=0;--e){let t=s[e],{isExternal:l,modifiers:u,hasImportantModifier:d,baseClassName:f,maybePostfixModifierPosition:p}=n(t);if(l){c=t+(c.length>0?` `+c:c);continue}let m=!!p,h=r(m?f.substring(0,p):f);if(!h){if(!m){c=t+(c.length>0?` `+c:c);continue}if(h=r(f),!h){c=t+(c.length>0?` `+c:c);continue}m=!1}let g=u.length===0?``:u.length===1?u[0]:a(u).join(`:`),_=d?g+lu:g,v=_+h;if(o.indexOf(v)>-1)continue;o.push(v);let y=i(h,m);for(let e=0;e<y.length;++e){let t=y[e];o.push(_+t)}c=t+(c.length>0?` `+c:c)}return c},vu=(...e)=>{let t=0,n,r,i=``;for(;t<e.length;)(n=e[t++])&&(r=yu(n))&&(i&&(i+=` `),i+=r);return i},yu=e=>{if(typeof e==`string`)return e;let t,n=``;for(let r=0;r<e.length;r++)e[r]&&(t=yu(e[r]))&&(n&&(n+=` `),n+=t);return n},bu=(e,...t)=>{let n,r,i,a,o=o=>(n=hu(t.reduce((e,t)=>t(e),e())),r=n.cache.get,i=n.cache.set,a=s,s(o)),s=e=>{let t=r(e);if(t)return t;let a=_u(e,n);return i(e,a),a};return a=o,(...e)=>a(vu(...e))},xu=[],Su=e=>{let t=t=>t[e]||xu;return t.isThemeGetter=!0,t},Cu=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,wu=/^\((?:(\w[\w-]*):)?(.+)\)$/i,Tu=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,Eu=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Du=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Ou=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,ku=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Au=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,ju=e=>Tu.test(e),Mu=e=>!!e&&!Number.isNaN(Number(e)),Nu=e=>!!e&&Number.isInteger(Number(e)),Pu=e=>e.endsWith(`%`)&&Mu(e.slice(0,-1)),Fu=e=>Eu.test(e),Iu=()=>!0,Lu=e=>Du.test(e)&&!Ou.test(e),Ru=()=>!1,zu=e=>ku.test(e),Bu=e=>Au.test(e),Vu=e=>!L(e)&&!R(e),Hu=e=>rd(e,sd,Ru),L=e=>Cu.test(e),Uu=e=>rd(e,cd,Lu),Wu=e=>rd(e,ld,Mu),Gu=e=>rd(e,dd,Iu),Ku=e=>rd(e,ud,Ru),qu=e=>rd(e,ad,Ru),Ju=e=>rd(e,od,Bu),Yu=e=>rd(e,fd,zu),R=e=>wu.test(e),Xu=e=>id(e,cd),Zu=e=>id(e,ud),Qu=e=>id(e,ad),$u=e=>id(e,sd),ed=e=>id(e,od),td=e=>id(e,fd,!0),nd=e=>id(e,dd,!0),rd=(e,t,n)=>{let r=Cu.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},id=(e,t,n=!1)=>{let r=wu.exec(e);return r?r[1]?t(r[1]):n:!1},ad=e=>e===`position`||e===`percentage`,od=e=>e===`image`||e===`url`,sd=e=>e===`length`||e===`size`||e===`bg-size`,cd=e=>e===`length`,ld=e=>e===`number`,ud=e=>e===`family-name`,dd=e=>e===`number`||e===`weight`,fd=e=>e===`shadow`,pd=bu(()=>{let e=Su(`color`),t=Su(`font`),n=Su(`text`),r=Su(`font-weight`),i=Su(`tracking`),a=Su(`leading`),o=Su(`breakpoint`),s=Su(`container`),c=Su(`spacing`),l=Su(`radius`),u=Su(`shadow`),d=Su(`inset-shadow`),f=Su(`text-shadow`),p=Su(`drop-shadow`),m=Su(`blur`),h=Su(`perspective`),g=Su(`aspect`),_=Su(`ease`),v=Su(`animate`),y=()=>[`auto`,`avoid`,`all`,`avoid-page`,`page`,`left`,`right`,`column`],b=()=>[`center`,`top`,`bottom`,`left`,`right`,`top-left`,`left-top`,`top-right`,`right-top`,`bottom-right`,`right-bottom`,`bottom-left`,`left-bottom`],x=()=>[...b(),R,L],S=()=>[`auto`,`hidden`,`clip`,`visible`,`scroll`],C=()=>[`auto`,`contain`,`none`],w=()=>[R,L,c],T=()=>[ju,`full`,`auto`,...w()],E=()=>[Nu,`none`,`subgrid`,R,L],D=()=>[`auto`,{span:[`full`,Nu,R,L]},Nu,R,L],O=()=>[Nu,`auto`,R,L],ee=()=>[`auto`,`min`,`max`,`fr`,R,L],te=()=>[`start`,`end`,`center`,`between`,`around`,`evenly`,`stretch`,`baseline`,`center-safe`,`end-safe`],k=()=>[`start`,`end`,`center`,`stretch`,`center-safe`,`end-safe`],A=()=>[`auto`,...w()],j=()=>[ju,`auto`,`full`,`dvw`,`dvh`,`lvw`,`lvh`,`svw`,`svh`,`min`,`max`,`fit`,...w()],M=()=>[ju,`screen`,`full`,`dvw`,`lvw`,`svw`,`min`,`max`,`fit`,...w()],ne=()=>[ju,`screen`,`full`,`lh`,`dvh`,`lvh`,`svh`,`min`,`max`,`fit`,...w()],N=()=>[e,R,L],P=()=>[...b(),Qu,qu,{position:[R,L]}],re=()=>[`no-repeat`,{repeat:[``,`x`,`y`,`space`,`round`]}],ie=()=>[`auto`,`cover`,`contain`,$u,Hu,{size:[R,L]}],ae=()=>[Pu,Xu,Uu],oe=()=>[``,`none`,`full`,l,R,L],F=()=>[``,Mu,Xu,Uu],I=()=>[`solid`,`dashed`,`dotted`,`double`],se=()=>[`normal`,`multiply`,`screen`,`overlay`,`darken`,`lighten`,`color-dodge`,`color-burn`,`hard-light`,`soft-light`,`difference`,`exclusion`,`hue`,`saturation`,`color`,`luminosity`],ce=()=>[Mu,Pu,Qu,qu],le=()=>[``,`none`,m,R,L],ue=()=>[`none`,Mu,R,L],de=()=>[`none`,Mu,R,L],fe=()=>[Mu,R,L],pe=()=>[ju,`full`,...w()];return{cacheSize:500,theme:{animate:[`spin`,`ping`,`pulse`,`bounce`],aspect:[`video`],blur:[Fu],breakpoint:[Fu],color:[Iu],container:[Fu],"drop-shadow":[Fu],ease:[`in`,`out`,`in-out`],font:[Vu],"font-weight":[`thin`,`extralight`,`light`,`normal`,`medium`,`semibold`,`bold`,`extrabold`,`black`],"inset-shadow":[Fu],leading:[`none`,`tight`,`snug`,`normal`,`relaxed`,`loose`],perspective:[`dramatic`,`near`,`normal`,`midrange`,`distant`,`none`],radius:[Fu],shadow:[Fu],spacing:[`px`,Mu],text:[Fu],"text-shadow":[Fu],tracking:[`tighter`,`tight`,`normal`,`wide`,`wider`,`widest`]},classGroups:{aspect:[{aspect:[`auto`,`square`,ju,L,R,g]}],container:[`container`],columns:[{columns:[Mu,L,R,s]}],"break-after":[{"break-after":y()}],"break-before":[{"break-before":y()}],"break-inside":[{"break-inside":[`auto`,`avoid`,`avoid-page`,`avoid-column`]}],"box-decoration":[{"box-decoration":[`slice`,`clone`]}],box:[{box:[`border`,`content`]}],display:[`block`,`inline-block`,`inline`,`flex`,`inline-flex`,`table`,`inline-table`,`table-caption`,`table-cell`,`table-column`,`table-column-group`,`table-footer-group`,`table-header-group`,`table-row-group`,`table-row`,`flow-root`,`grid`,`inline-grid`,`contents`,`list-item`,`hidden`],sr:[`sr-only`,`not-sr-only`],float:[{float:[`right`,`left`,`none`,`start`,`end`]}],clear:[{clear:[`left`,`right`,`both`,`none`,`start`,`end`]}],isolation:[`isolate`,`isolation-auto`],"object-fit":[{object:[`contain`,`cover`,`fill`,`none`,`scale-down`]}],"object-position":[{object:x()}],overflow:[{overflow:S()}],"overflow-x":[{"overflow-x":S()}],"overflow-y":[{"overflow-y":S()}],overscroll:[{overscroll:C()}],"overscroll-x":[{"overscroll-x":C()}],"overscroll-y":[{"overscroll-y":C()}],position:[`static`,`fixed`,`absolute`,`relative`,`sticky`],inset:[{inset:T()}],"inset-x":[{"inset-x":T()}],"inset-y":[{"inset-y":T()}],start:[{"inset-s":T(),start:T()}],end:[{"inset-e":T(),end:T()}],"inset-bs":[{"inset-bs":T()}],"inset-be":[{"inset-be":T()}],top:[{top:T()}],right:[{right:T()}],bottom:[{bottom:T()}],left:[{left:T()}],visibility:[`visible`,`invisible`,`collapse`],z:[{z:[Nu,`auto`,R,L]}],basis:[{basis:[ju,`full`,`auto`,s,...w()]}],"flex-direction":[{flex:[`row`,`row-reverse`,`col`,`col-reverse`]}],"flex-wrap":[{flex:[`nowrap`,`wrap`,`wrap-reverse`]}],flex:[{flex:[Mu,ju,`auto`,`initial`,`none`,L]}],grow:[{grow:[``,Mu,R,L]}],shrink:[{shrink:[``,Mu,R,L]}],order:[{order:[Nu,`first`,`last`,`none`,R,L]}],"grid-cols":[{"grid-cols":E()}],"col-start-end":[{col:D()}],"col-start":[{"col-start":O()}],"col-end":[{"col-end":O()}],"grid-rows":[{"grid-rows":E()}],"row-start-end":[{row:D()}],"row-start":[{"row-start":O()}],"row-end":[{"row-end":O()}],"grid-flow":[{"grid-flow":[`row`,`col`,`dense`,`row-dense`,`col-dense`]}],"auto-cols":[{"auto-cols":ee()}],"auto-rows":[{"auto-rows":ee()}],gap:[{gap:w()}],"gap-x":[{"gap-x":w()}],"gap-y":[{"gap-y":w()}],"justify-content":[{justify:[...te(),`normal`]}],"justify-items":[{"justify-items":[...k(),`normal`]}],"justify-self":[{"justify-self":[`auto`,...k()]}],"align-content":[{content:[`normal`,...te()]}],"align-items":[{items:[...k(),{baseline:[``,`last`]}]}],"align-self":[{self:[`auto`,...k(),{baseline:[``,`last`]}]}],"place-content":[{"place-content":te()}],"place-items":[{"place-items":[...k(),`baseline`]}],"place-self":[{"place-self":[`auto`,...k()]}],p:[{p:w()}],px:[{px:w()}],py:[{py:w()}],ps:[{ps:w()}],pe:[{pe:w()}],pbs:[{pbs:w()}],pbe:[{pbe:w()}],pt:[{pt:w()}],pr:[{pr:w()}],pb:[{pb:w()}],pl:[{pl:w()}],m:[{m:A()}],mx:[{mx:A()}],my:[{my:A()}],ms:[{ms:A()}],me:[{me:A()}],mbs:[{mbs:A()}],mbe:[{mbe:A()}],mt:[{mt:A()}],mr:[{mr:A()}],mb:[{mb:A()}],ml:[{ml:A()}],"space-x":[{"space-x":w()}],"space-x-reverse":[`space-x-reverse`],"space-y":[{"space-y":w()}],"space-y-reverse":[`space-y-reverse`],size:[{size:j()}],"inline-size":[{inline:[`auto`,...M()]}],"min-inline-size":[{"min-inline":[`auto`,...M()]}],"max-inline-size":[{"max-inline":[`none`,...M()]}],"block-size":[{block:[`auto`,...ne()]}],"min-block-size":[{"min-block":[`auto`,...ne()]}],"max-block-size":[{"max-block":[`none`,...ne()]}],w:[{w:[s,`screen`,...j()]}],"min-w":[{"min-w":[s,`screen`,`none`,...j()]}],"max-w":[{"max-w":[s,`screen`,`none`,`prose`,{screen:[o]},...j()]}],h:[{h:[`screen`,`lh`,...j()]}],"min-h":[{"min-h":[`screen`,`lh`,`none`,...j()]}],"max-h":[{"max-h":[`screen`,`lh`,...j()]}],"font-size":[{text:[`base`,n,Xu,Uu]}],"font-smoothing":[`antialiased`,`subpixel-antialiased`],"font-style":[`italic`,`not-italic`],"font-weight":[{font:[r,nd,Gu]}],"font-stretch":[{"font-stretch":[`ultra-condensed`,`extra-condensed`,`condensed`,`semi-condensed`,`normal`,`semi-expanded`,`expanded`,`extra-expanded`,`ultra-expanded`,Pu,L]}],"font-family":[{font:[Zu,Ku,t]}],"font-features":[{"font-features":[L]}],"fvn-normal":[`normal-nums`],"fvn-ordinal":[`ordinal`],"fvn-slashed-zero":[`slashed-zero`],"fvn-figure":[`lining-nums`,`oldstyle-nums`],"fvn-spacing":[`proportional-nums`,`tabular-nums`],"fvn-fraction":[`diagonal-fractions`,`stacked-fractions`],tracking:[{tracking:[i,R,L]}],"line-clamp":[{"line-clamp":[Mu,`none`,R,Wu]}],leading:[{leading:[a,...w()]}],"list-image":[{"list-image":[`none`,R,L]}],"list-style-position":[{list:[`inside`,`outside`]}],"list-style-type":[{list:[`disc`,`decimal`,`none`,R,L]}],"text-alignment":[{text:[`left`,`center`,`right`,`justify`,`start`,`end`]}],"placeholder-color":[{placeholder:N()}],"text-color":[{text:N()}],"text-decoration":[`underline`,`overline`,`line-through`,`no-underline`],"text-decoration-style":[{decoration:[...I(),`wavy`]}],"text-decoration-thickness":[{decoration:[Mu,`from-font`,`auto`,R,Uu]}],"text-decoration-color":[{decoration:N()}],"underline-offset":[{"underline-offset":[Mu,`auto`,R,L]}],"text-transform":[`uppercase`,`lowercase`,`capitalize`,`normal-case`],"text-overflow":[`truncate`,`text-ellipsis`,`text-clip`],"text-wrap":[{text:[`wrap`,`nowrap`,`balance`,`pretty`]}],indent:[{indent:w()}],"vertical-align":[{align:[`baseline`,`top`,`middle`,`bottom`,`text-top`,`text-bottom`,`sub`,`super`,R,L]}],whitespace:[{whitespace:[`normal`,`nowrap`,`pre`,`pre-line`,`pre-wrap`,`break-spaces`]}],break:[{break:[`normal`,`words`,`all`,`keep`]}],wrap:[{wrap:[`break-word`,`anywhere`,`normal`]}],hyphens:[{hyphens:[`none`,`manual`,`auto`]}],content:[{content:[`none`,R,L]}],"bg-attachment":[{bg:[`fixed`,`local`,`scroll`]}],"bg-clip":[{"bg-clip":[`border`,`padding`,`content`,`text`]}],"bg-origin":[{"bg-origin":[`border`,`padding`,`content`]}],"bg-position":[{bg:P()}],"bg-repeat":[{bg:re()}],"bg-size":[{bg:ie()}],"bg-image":[{bg:[`none`,{linear:[{to:[`t`,`tr`,`r`,`br`,`b`,`bl`,`l`,`tl`]},Nu,R,L],radial:[``,R,L],conic:[Nu,R,L]},ed,Ju]}],"bg-color":[{bg:N()}],"gradient-from-pos":[{from:ae()}],"gradient-via-pos":[{via:ae()}],"gradient-to-pos":[{to:ae()}],"gradient-from":[{from:N()}],"gradient-via":[{via:N()}],"gradient-to":[{to:N()}],rounded:[{rounded:oe()}],"rounded-s":[{"rounded-s":oe()}],"rounded-e":[{"rounded-e":oe()}],"rounded-t":[{"rounded-t":oe()}],"rounded-r":[{"rounded-r":oe()}],"rounded-b":[{"rounded-b":oe()}],"rounded-l":[{"rounded-l":oe()}],"rounded-ss":[{"rounded-ss":oe()}],"rounded-se":[{"rounded-se":oe()}],"rounded-ee":[{"rounded-ee":oe()}],"rounded-es":[{"rounded-es":oe()}],"rounded-tl":[{"rounded-tl":oe()}],"rounded-tr":[{"rounded-tr":oe()}],"rounded-br":[{"rounded-br":oe()}],"rounded-bl":[{"rounded-bl":oe()}],"border-w":[{border:F()}],"border-w-x":[{"border-x":F()}],"border-w-y":[{"border-y":F()}],"border-w-s":[{"border-s":F()}],"border-w-e":[{"border-e":F()}],"border-w-bs":[{"border-bs":F()}],"border-w-be":[{"border-be":F()}],"border-w-t":[{"border-t":F()}],"border-w-r":[{"border-r":F()}],"border-w-b":[{"border-b":F()}],"border-w-l":[{"border-l":F()}],"divide-x":[{"divide-x":F()}],"divide-x-reverse":[`divide-x-reverse`],"divide-y":[{"divide-y":F()}],"divide-y-reverse":[`divide-y-reverse`],"border-style":[{border:[...I(),`hidden`,`none`]}],"divide-style":[{divide:[...I(),`hidden`,`none`]}],"border-color":[{border:N()}],"border-color-x":[{"border-x":N()}],"border-color-y":[{"border-y":N()}],"border-color-s":[{"border-s":N()}],"border-color-e":[{"border-e":N()}],"border-color-bs":[{"border-bs":N()}],"border-color-be":[{"border-be":N()}],"border-color-t":[{"border-t":N()}],"border-color-r":[{"border-r":N()}],"border-color-b":[{"border-b":N()}],"border-color-l":[{"border-l":N()}],"divide-color":[{divide:N()}],"outline-style":[{outline:[...I(),`none`,`hidden`]}],"outline-offset":[{"outline-offset":[Mu,R,L]}],"outline-w":[{outline:[``,Mu,Xu,Uu]}],"outline-color":[{outline:N()}],shadow:[{shadow:[``,`none`,u,td,Yu]}],"shadow-color":[{shadow:N()}],"inset-shadow":[{"inset-shadow":[`none`,d,td,Yu]}],"inset-shadow-color":[{"inset-shadow":N()}],"ring-w":[{ring:F()}],"ring-w-inset":[`ring-inset`],"ring-color":[{ring:N()}],"ring-offset-w":[{"ring-offset":[Mu,Uu]}],"ring-offset-color":[{"ring-offset":N()}],"inset-ring-w":[{"inset-ring":F()}],"inset-ring-color":[{"inset-ring":N()}],"text-shadow":[{"text-shadow":[`none`,f,td,Yu]}],"text-shadow-color":[{"text-shadow":N()}],opacity:[{opacity:[Mu,R,L]}],"mix-blend":[{"mix-blend":[...se(),`plus-darker`,`plus-lighter`]}],"bg-blend":[{"bg-blend":se()}],"mask-clip":[{"mask-clip":[`border`,`padding`,`content`,`fill`,`stroke`,`view`]},`mask-no-clip`],"mask-composite":[{mask:[`add`,`subtract`,`intersect`,`exclude`]}],"mask-image-linear-pos":[{"mask-linear":[Mu]}],"mask-image-linear-from-pos":[{"mask-linear-from":ce()}],"mask-image-linear-to-pos":[{"mask-linear-to":ce()}],"mask-image-linear-from-color":[{"mask-linear-from":N()}],"mask-image-linear-to-color":[{"mask-linear-to":N()}],"mask-image-t-from-pos":[{"mask-t-from":ce()}],"mask-image-t-to-pos":[{"mask-t-to":ce()}],"mask-image-t-from-color":[{"mask-t-from":N()}],"mask-image-t-to-color":[{"mask-t-to":N()}],"mask-image-r-from-pos":[{"mask-r-from":ce()}],"mask-image-r-to-pos":[{"mask-r-to":ce()}],"mask-image-r-from-color":[{"mask-r-from":N()}],"mask-image-r-to-color":[{"mask-r-to":N()}],"mask-image-b-from-pos":[{"mask-b-from":ce()}],"mask-image-b-to-pos":[{"mask-b-to":ce()}],"mask-image-b-from-color":[{"mask-b-from":N()}],"mask-image-b-to-color":[{"mask-b-to":N()}],"mask-image-l-from-pos":[{"mask-l-from":ce()}],"mask-image-l-to-pos":[{"mask-l-to":ce()}],"mask-image-l-from-color":[{"mask-l-from":N()}],"mask-image-l-to-color":[{"mask-l-to":N()}],"mask-image-x-from-pos":[{"mask-x-from":ce()}],"mask-image-x-to-pos":[{"mask-x-to":ce()}],"mask-image-x-from-color":[{"mask-x-from":N()}],"mask-image-x-to-color":[{"mask-x-to":N()}],"mask-image-y-from-pos":[{"mask-y-from":ce()}],"mask-image-y-to-pos":[{"mask-y-to":ce()}],"mask-image-y-from-color":[{"mask-y-from":N()}],"mask-image-y-to-color":[{"mask-y-to":N()}],"mask-image-radial":[{"mask-radial":[R,L]}],"mask-image-radial-from-pos":[{"mask-radial-from":ce()}],"mask-image-radial-to-pos":[{"mask-radial-to":ce()}],"mask-image-radial-from-color":[{"mask-radial-from":N()}],"mask-image-radial-to-color":[{"mask-radial-to":N()}],"mask-image-radial-shape":[{"mask-radial":[`circle`,`ellipse`]}],"mask-image-radial-size":[{"mask-radial":[{closest:[`side`,`corner`],farthest:[`side`,`corner`]}]}],"mask-image-radial-pos":[{"mask-radial-at":b()}],"mask-image-conic-pos":[{"mask-conic":[Mu]}],"mask-image-conic-from-pos":[{"mask-conic-from":ce()}],"mask-image-conic-to-pos":[{"mask-conic-to":ce()}],"mask-image-conic-from-color":[{"mask-conic-from":N()}],"mask-image-conic-to-color":[{"mask-conic-to":N()}],"mask-mode":[{mask:[`alpha`,`luminance`,`match`]}],"mask-origin":[{"mask-origin":[`border`,`padding`,`content`,`fill`,`stroke`,`view`]}],"mask-position":[{mask:P()}],"mask-repeat":[{mask:re()}],"mask-size":[{mask:ie()}],"mask-type":[{"mask-type":[`alpha`,`luminance`]}],"mask-image":[{mask:[`none`,R,L]}],filter:[{filter:[``,`none`,R,L]}],blur:[{blur:le()}],brightness:[{brightness:[Mu,R,L]}],contrast:[{contrast:[Mu,R,L]}],"drop-shadow":[{"drop-shadow":[``,`none`,p,td,Yu]}],"drop-shadow-color":[{"drop-shadow":N()}],grayscale:[{grayscale:[``,Mu,R,L]}],"hue-rotate":[{"hue-rotate":[Mu,R,L]}],invert:[{invert:[``,Mu,R,L]}],saturate:[{saturate:[Mu,R,L]}],sepia:[{sepia:[``,Mu,R,L]}],"backdrop-filter":[{"backdrop-filter":[``,`none`,R,L]}],"backdrop-blur":[{"backdrop-blur":le()}],"backdrop-brightness":[{"backdrop-brightness":[Mu,R,L]}],"backdrop-contrast":[{"backdrop-contrast":[Mu,R,L]}],"backdrop-grayscale":[{"backdrop-grayscale":[``,Mu,R,L]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[Mu,R,L]}],"backdrop-invert":[{"backdrop-invert":[``,Mu,R,L]}],"backdrop-opacity":[{"backdrop-opacity":[Mu,R,L]}],"backdrop-saturate":[{"backdrop-saturate":[Mu,R,L]}],"backdrop-sepia":[{"backdrop-sepia":[``,Mu,R,L]}],"border-collapse":[{border:[`collapse`,`separate`]}],"border-spacing":[{"border-spacing":w()}],"border-spacing-x":[{"border-spacing-x":w()}],"border-spacing-y":[{"border-spacing-y":w()}],"table-layout":[{table:[`auto`,`fixed`]}],caption:[{caption:[`top`,`bottom`]}],transition:[{transition:[``,`all`,`colors`,`opacity`,`shadow`,`transform`,`none`,R,L]}],"transition-behavior":[{transition:[`normal`,`discrete`]}],duration:[{duration:[Mu,`initial`,R,L]}],ease:[{ease:[`linear`,`initial`,_,R,L]}],delay:[{delay:[Mu,R,L]}],animate:[{animate:[`none`,v,R,L]}],backface:[{backface:[`hidden`,`visible`]}],perspective:[{perspective:[h,R,L]}],"perspective-origin":[{"perspective-origin":x()}],rotate:[{rotate:ue()}],"rotate-x":[{"rotate-x":ue()}],"rotate-y":[{"rotate-y":ue()}],"rotate-z":[{"rotate-z":ue()}],scale:[{scale:de()}],"scale-x":[{"scale-x":de()}],"scale-y":[{"scale-y":de()}],"scale-z":[{"scale-z":de()}],"scale-3d":[`scale-3d`],skew:[{skew:fe()}],"skew-x":[{"skew-x":fe()}],"skew-y":[{"skew-y":fe()}],transform:[{transform:[R,L,``,`none`,`gpu`,`cpu`]}],"transform-origin":[{origin:x()}],"transform-style":[{transform:[`3d`,`flat`]}],translate:[{translate:pe()}],"translate-x":[{"translate-x":pe()}],"translate-y":[{"translate-y":pe()}],"translate-z":[{"translate-z":pe()}],"translate-none":[`translate-none`],accent:[{accent:N()}],appearance:[{appearance:[`none`,`auto`]}],"caret-color":[{caret:N()}],"color-scheme":[{scheme:[`normal`,`dark`,`light`,`light-dark`,`only-dark`,`only-light`]}],cursor:[{cursor:[`auto`,`default`,`pointer`,`wait`,`text`,`move`,`help`,`not-allowed`,`none`,`context-menu`,`progress`,`cell`,`crosshair`,`vertical-text`,`alias`,`copy`,`no-drop`,`grab`,`grabbing`,`all-scroll`,`col-resize`,`row-resize`,`n-resize`,`e-resize`,`s-resize`,`w-resize`,`ne-resize`,`nw-resize`,`se-resize`,`sw-resize`,`ew-resize`,`ns-resize`,`nesw-resize`,`nwse-resize`,`zoom-in`,`zoom-out`,R,L]}],"field-sizing":[{"field-sizing":[`fixed`,`content`]}],"pointer-events":[{"pointer-events":[`auto`,`none`]}],resize:[{resize:[`none`,``,`y`,`x`]}],"scroll-behavior":[{scroll:[`auto`,`smooth`]}],"scroll-m":[{"scroll-m":w()}],"scroll-mx":[{"scroll-mx":w()}],"scroll-my":[{"scroll-my":w()}],"scroll-ms":[{"scroll-ms":w()}],"scroll-me":[{"scroll-me":w()}],"scroll-mbs":[{"scroll-mbs":w()}],"scroll-mbe":[{"scroll-mbe":w()}],"scroll-mt":[{"scroll-mt":w()}],"scroll-mr":[{"scroll-mr":w()}],"scroll-mb":[{"scroll-mb":w()}],"scroll-ml":[{"scroll-ml":w()}],"scroll-p":[{"scroll-p":w()}],"scroll-px":[{"scroll-px":w()}],"scroll-py":[{"scroll-py":w()}],"scroll-ps":[{"scroll-ps":w()}],"scroll-pe":[{"scroll-pe":w()}],"scroll-pbs":[{"scroll-pbs":w()}],"scroll-pbe":[{"scroll-pbe":w()}],"scroll-pt":[{"scroll-pt":w()}],"scroll-pr":[{"scroll-pr":w()}],"scroll-pb":[{"scroll-pb":w()}],"scroll-pl":[{"scroll-pl":w()}],"snap-align":[{snap:[`start`,`end`,`center`,`align-none`]}],"snap-stop":[{snap:[`normal`,`always`]}],"snap-type":[{snap:[`none`,`x`,`y`,`both`]}],"snap-strictness":[{snap:[`mandatory`,`proximity`]}],touch:[{touch:[`auto`,`none`,`manipulation`]}],"touch-x":[{"touch-pan":[`x`,`left`,`right`]}],"touch-y":[{"touch-pan":[`y`,`up`,`down`]}],"touch-pz":[`touch-pinch-zoom`],select:[{select:[`none`,`text`,`all`,`auto`]}],"will-change":[{"will-change":[`auto`,`scroll`,`contents`,`transform`,R,L]}],fill:[{fill:[`none`,...N()]}],"stroke-w":[{stroke:[Mu,Xu,Uu,Wu]}],stroke:[{stroke:[`none`,...N()]}],"forced-color-adjust":[{"forced-color-adjust":[`auto`,`none`]}]},conflictingClassGroups:{overflow:[`overflow-x`,`overflow-y`],overscroll:[`overscroll-x`,`overscroll-y`],inset:[`inset-x`,`inset-y`,`inset-bs`,`inset-be`,`start`,`end`,`top`,`right`,`bottom`,`left`],"inset-x":[`right`,`left`],"inset-y":[`top`,`bottom`],flex:[`basis`,`grow`,`shrink`],gap:[`gap-x`,`gap-y`],p:[`px`,`py`,`ps`,`pe`,`pbs`,`pbe`,`pt`,`pr`,`pb`,`pl`],px:[`pr`,`pl`],py:[`pt`,`pb`],m:[`mx`,`my`,`ms`,`me`,`mbs`,`mbe`,`mt`,`mr`,`mb`,`ml`],mx:[`mr`,`ml`],my:[`mt`,`mb`],size:[`w`,`h`],"font-size":[`leading`],"fvn-normal":[`fvn-ordinal`,`fvn-slashed-zero`,`fvn-figure`,`fvn-spacing`,`fvn-fraction`],"fvn-ordinal":[`fvn-normal`],"fvn-slashed-zero":[`fvn-normal`],"fvn-figure":[`fvn-normal`],"fvn-spacing":[`fvn-normal`],"fvn-fraction":[`fvn-normal`],"line-clamp":[`display`,`overflow`],rounded:[`rounded-s`,`rounded-e`,`rounded-t`,`rounded-r`,`rounded-b`,`rounded-l`,`rounded-ss`,`rounded-se`,`rounded-ee`,`rounded-es`,`rounded-tl`,`rounded-tr`,`rounded-br`,`rounded-bl`],"rounded-s":[`rounded-ss`,`rounded-es`],"rounded-e":[`rounded-se`,`rounded-ee`],"rounded-t":[`rounded-tl`,`rounded-tr`],"rounded-r":[`rounded-tr`,`rounded-br`],"rounded-b":[`rounded-br`,`rounded-bl`],"rounded-l":[`rounded-tl`,`rounded-bl`],"border-spacing":[`border-spacing-x`,`border-spacing-y`],"border-w":[`border-w-x`,`border-w-y`,`border-w-s`,`border-w-e`,`border-w-bs`,`border-w-be`,`border-w-t`,`border-w-r`,`border-w-b`,`border-w-l`],"border-w-x":[`border-w-r`,`border-w-l`],"border-w-y":[`border-w-t`,`border-w-b`],"border-color":[`border-color-x`,`border-color-y`,`border-color-s`,`border-color-e`,`border-color-bs`,`border-color-be`,`border-color-t`,`border-color-r`,`border-color-b`,`border-color-l`],"border-color-x":[`border-color-r`,`border-color-l`],"border-color-y":[`border-color-t`,`border-color-b`],translate:[`translate-x`,`translate-y`,`translate-none`],"translate-none":[`translate`,`translate-x`,`translate-y`,`translate-z`],"scroll-m":[`scroll-mx`,`scroll-my`,`scroll-ms`,`scroll-me`,`scroll-mbs`,`scroll-mbe`,`scroll-mt`,`scroll-mr`,`scroll-mb`,`scroll-ml`],"scroll-mx":[`scroll-mr`,`scroll-ml`],"scroll-my":[`scroll-mt`,`scroll-mb`],"scroll-p":[`scroll-px`,`scroll-py`,`scroll-ps`,`scroll-pe`,`scroll-pbs`,`scroll-pbe`,`scroll-pt`,`scroll-pr`,`scroll-pb`,`scroll-pl`],"scroll-px":[`scroll-pr`,`scroll-pl`],"scroll-py":[`scroll-pt`,`scroll-pb`],touch:[`touch-x`,`touch-y`,`touch-pz`],"touch-x":[`touch`],"touch-y":[`touch`],"touch-pz":[`touch`]},conflictingClassGroupModifiers:{"font-size":[`leading`]},orderSensitiveModifiers:[`*`,`**`,`after`,`backdrop`,`before`,`details-content`,`file`,`first-letter`,`first-line`,`marker`,`placeholder`,`selection`]}});function z(...e){return pd(Ul(e))}function md({delayDuration:e=0,...t}){return(0,_.jsx)(Fl,{"data-slot":`tooltip-provider`,delayDuration:e,...t})}function hd({...e}){return(0,_.jsx)(Il,{"data-slot":`tooltip`,...e})}function gd({...e}){return(0,_.jsx)(Ll,{"data-slot":`tooltip-trigger`,...e})}function _d({className:e,sideOffset:t=0,children:n,...r}){return(0,_.jsx)(Rl,{children:(0,_.jsxs)(zl,{"data-slot":`tooltip-content`,sideOffset:t,className:z(`z-50 w-fit origin-(--radix-tooltip-content-transform-origin) animate-in rounded-md border border-(--border-default) bg-(--bg-secondary) px-3 py-1.5 text-xs text-balance text-(--text-primary) shadow-lg fade-in-0 zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95`,e),...r,children:[n,(0,_.jsx)(Bl,{className:`z-50 size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px] bg-(--bg-secondary) fill-(--bg-secondary)`})]})})}var vd={zh:{brand:`Codemini`,live:`运行中`,idle:`空闲`,sending:`发送中`,thinking:`思考中`,streaming:`回复中`,tooling:`工具执行中`,inputPlaceholder:`输入消息或 / 命令...`,inputDisabled:`等待当前请求完成...`,inputPlanReviewDisabled:`请先在上方审阅计划,批准、修改或否决后再继续输入`,abort:`停止`,approveTitle:`确认操作`,approve:`允许`,deny:`拒绝`,deleteApproval:`确认删除`,runApproval:`确认执行命令`,planApproval:`确认执行计划`,reflectApproval:`确认保存技能`,toolRunning:`运行中`,toolDone:`完成`,toolError:`错误`,toolBlocked:`已阻止`,toolGroupTools:`已运行 {{count}} 个工具`,toolGroupCommands:`已运行 {{count}} 条命令`,toolGroupExpand:`点击展开`,planTitle:`执行计划`,planDone:`完成`,planReviewTitle:`审阅计划`,planReviewSummary:`摘要`,planReviewSteps:`计划步骤`,planApprove:`批准执行`,planReject:`否决`,planEdit:`修改计划`,planEditPlaceholder:`描述你的修改意见...`,planSubmitFeedback:`提交反馈`,planStepCount:`个步骤`,planReviewStatus:`等待审阅`,planWaitingReview:`正在等待计划审阅…`,waitingResponse:`正在等待回复…`,reflectReviewTitle:`审阅技能草稿`,reflectReviewStatus:`等待审阅`,reflectScope:`范围`,reflectConfidence:`置信度`,reflectApprove:`保存技能`,reflectReject:`丢弃`,reflectEdit:`修改草稿`,reflectEditPlaceholder:`描述你希望如何修改这个技能草稿...`,reflectSubmitFeedback:`提交反馈`,reflectReviewFirst:`请先审阅技能草稿,保存、修改或丢弃后再继续输入`,runtimeActivityDreamRunning:`Dream 正在整理记忆`,runtimeActivityDreamDone:`Dream 已完成`,runtimeActivityDreamError:`Dream 失败`,runtimeActivityCompactDone:`上下文已压缩`,runtimeActivityCompactPreview:`上下文压缩预览`,runtimeActivityMicroCompactDone:`微压缩已完成`,runtimeActivityMicroCompactPreview:`微压缩预览`,runtimeActivityInboxCaptured:`已写入 Inbox`,runtimeActivityInboxListed:`Inbox 已查看`,runtimeActivityReflectPending:`Reflect 等待审阅`,runtimeActivityReflectRevised:`Reflect 草稿已更新`,runtimeActivityReflectSaving:`正在保存技能`,runtimeActivityReflectSaved:`技能已保存`,runtimeActivityReflectRevising:`正在修改草稿`,runtimeActivityReflectDiscarding:`正在丢弃草稿`,runtimeActivityReflectDiscarded:`草稿已丢弃`,runtimeActivityReflectNone:`未找到可沉淀技能`,skillRunning:`运行中`,skillDone:`完成`,skillError:`失败`,skillAuto:`自动技能`,contextUsage:`上下文使用`,fileChanges:`文件变更`,thought:`思考过程`,thoughtFor:`思考了 {{duration}}`,thinkingNow:`正在思考中...`,thoughtForNow:`已思考 {{duration}}`,processed:`已处理`,processedFor:`已处理 {{duration}}`,processedDetails:`{{thoughts}} 段思考,{{tools}} 个工具`,usageTokens:`tokens`,usageCache:`缓存`,usageInput:`输入`,usageOutput:`输出`,usageTotal:`总计`,usageCacheHit:`缓存命中`,usageCacheMiss:`缓存未命中`,usageCacheWrite:`缓存写入`,usageReasoning:`推理`,usageRequests:`{{count}} 次请求`,newChat:`新对话`,skills:`Skills`,souls:`Souls`,projects:`项目`,newSessionInProject:`在此项目中新建对话`,openCodeWiki:`打开 CodeWiki`,collapseProject:`折叠项目`,expandProject:`展开项目`,sessionActions:`会话操作`,deleteSession:`删除`,noSessions:`暂无对话`,about:`关于`,lightMode:`浅色`,darkMode:`深色`,autoModeTheme:`跟随系统`,switchTheme:`切换主题`,settings:`设置`,deleteSessionConfirm:`删除会话?`,deleteSessionDescription:`会话「{{session}}」会从历史记录中移除,此操作不可撤销。`,settingsTitle:`设置`,configRequired:`请先在设置中配置接口地址和 API Key`,configRequiredTitle:`需要先配置模型接口`,configRequiredDesc:`当前仍是新安装的默认接口地址。设置 Base URL、API Key 和模型后即可开始使用。`,cancel:`取消`,saveChanges:`保存更改`,gateway:`网关`,baseUrl:`接口地址`,apiKey:`API 密钥`,timeout:`超时 (ms)`,maxRetries:`最大重试`,model:`模型`,modelName:`模型名称`,fastModel:`快速模型`,maxContextTokens:`最大上下文 Tokens`,sdk:`SDK`,provider:`服务商`,execution:`执行`,mode:`模式`,maxSteps:`最大步数`,context:`上下文`,contextMaxTokens:`上下文 Token 预算`,preflightTrigger:`预压缩阈值 (%)`,hardLimit:`硬压缩阈值 (%)`,toolResultMaxChars:`工具结果字符上限`,microcompactEnabled:`微压缩`,microcompactKeepRecent:`微压缩保留数`,shell:`终端`,defaultShell:`默认 Shell`,policy:`策略`,safeMode:`安全模式`,allowedPaths:`目录白名单`,allowedPathsHelp:`可信绝对目录根路径的 JSON 数组。文件工具和 safe mode 的 shell 路径检查除了当前工作区,也允许访问这些目录。`,allowDangerousCommands:`允许危险命令`,ui:`界面`,uiLanguage:`界面语言`,replyLanguage:`回复语言`,backToTop:`回到顶部`,pendingItems:`排队中`,copyCode:`复制`,copyMessage:`复制`,copied:`已复制`,connected:`已连接`,disconnected:`连接断开,正在重连...`,unknownProject:`未知项目`,emptyChat:`空对话`,messages:`条消息`,renderError:`渲染错误`,retry:`重试`,planReviewFirst:`请先在上方审阅计划,批准、修改或否决后再继续输入`,loading:`加载中`,sending:`发送`,updating:`更新中...`,updatedRestart:`已更新,请重启`,updateAvailable:`新版本可用,点击更新`,openSettings:`打开设置`,current:`当前`,sessions:`会话`,items:`项`,enabled:`已启用`,disabled:`已停用`,disable:`停用`,noMatches:`没有匹配结果`,generationDepthFast:`快速`,generationDepthStandard:`标准`,generationDepthDeep:`深度`,startingAnalysis:`正在启动项目需求分析`,preparingScan:`准备扫描代码、接口和项目结构`,generationFailed:`生成遇到问题`,generatingCodeWiki:`正在生成 CodeWiki`,stepsCompleted:`个步骤完成`,codewikiFailed:`CodeWiki 问答失败`,failedToLoad:`无法加载 CodeWiki 报告`,failedToStart:`无法启动 CodeWiki 生成`,failedToDelete:`无法删除 CodeWiki 报告`,currentProject:`当前项目`,generating:`生成中`,generateNew:`生成新的 CodeWiki`,report:`报告`,refreshReport:`刷新报告`,noReportYet:`还没有 requirements 报告。生成后会出现在这里。`,reportActions:`报告操作`,deleteReport:`删除`,loadingReport:`加载报告`,projectDocs:`基于 project-requirements 的项目文档`,generate:`生成`,noCodeWiki:`还没有 CodeWiki`,generateRequirements:`生成当前项目的 requirements`,reportWillShow:`报告后,这里会展示架构图、接口需求、流程和风险说明。`,reportLoadFailed:`报告加载失败。`,noQuestionsDuringGeneration:`CodeWiki 生成完成前暂不接受提问。`,tempReadOnlyQa:`临时只读问答,不会修改项目,也不会保存到会话历史。`,processingQuestion:`当前问题处理中`,canAskAboutProject:`可以问当前项目`,askAfterGeneration:`生成完成后再基于报告提问。`,exampleQuestions:`例如:主要业务流程是什么?哪些接口风险最高?`,answering:`正在回答...`,sendingQuestion:`发送问题`,deleteReportConfirm:`删除 CodeWiki 报告?`,deleteReportDescription:`报告「{{report}}」会从当前项目历史报告中移除,此操作不可撤销。`,executionMode:`执行模式`,normalExecutionMode:`普通会话`,normalModeDesc:`编辑和命令工具需审阅`,autoMode:`自动`,autoModeDesc:`自动执行,复杂任务自动规划`,planMode:`计划`,planModeDesc:`仅规划不执行,审阅后再执行`,switchMode:`切换执行模式`,switchModeDisabled:`当前请求完成后可切换执行模式`,soulSwitch:`灵魂切换`,switchSoul:`切换灵魂`,builtin:`内置`,custom:`自定义`,sendMessageToCodemini:`给 Codemini 发送消息`,sendMessageToCodeminiWithSlash:`给 Codemini 发送消息,输入 / 查看更多功能`,askAnything:`可向 Codemini 询问任何事。输入 / 使用命令或技能`,addContext:`添加上下文`,switchWorkspace:`切换工作区`,name:`名称`,soulContent:`灵魂内容`,newSoul:`新建灵魂`,editSoul:`编辑灵魂`,soulEditorHint:`灵魂只影响回复语气,不应写入执行规则或工具策略。`,soulPlaceholder:`描述这个人格的语气、措辞和表达偏好...`,soulPanelHint:`选择默认人格;新的对话和后续请求会使用当前灵魂语气。`,noActiveSoul:`未选择灵魂`,searchSouls:`搜索灵魂名称...`,create:`创建`,save:`保存`,contentPreview:`- 内容预览`,close:`关闭`,addSoul:`添加灵魂`,noSouls:`暂无灵魂`,noSoulsHint:`创建一个自定义灵魂,用来固定 Codemini 的回复语气。`,activate:`激活`,edit:`编辑`,view:`查看`,delete:`删除`,deleting:`删除中`,globalScope:`全局`,projectScope:`项目`,enable:`启用`,addSkill:`添加技能`,installSkill:`安装`,installing:`安装中...`,skillInstallPlaceholder:`GitHub 仓库、URL、目录路径,或 npx skills@latest add owner/repo`,skillScope:`安装范围`,noSkills:`暂无技能`,noSkillsHint:`创建项目技能,把可复用工作流沉淀成 / 命令。`,skillLibrary:`技能库`,skillPanelHint:`技能会作为 / 命令或自动技能注入到 prompt,内置技能始终可用。`,newSkill:`新建技能`,editSkill:`编辑技能`,skillEditorHint:`技能适合沉淀稳定流程、检查清单和项目约定。`,searchSkills:`搜索技能名称...`,skillDescriptionPlaceholder:`这个技能适合什么时候使用...`,skillContent:`SKILL.md 内容`,skillRoutingSettings:`路由设置`,skillMode:`模式`,skillMode_always:`始终`,skillMode_auto_attach:`自动附加`,skillMode_agent_requested:`Agent 请求`,skillMode_manual:`手动`,skillPriority:`优先级`,skillTriggers:`触发器`,description:`描述`,noDescription:`暂无描述`,noPreview:`暂无预览`,filter_all:`全部`,filter_enabled:`启用`,filter_builtin:`内置`,filter_custom:`自定义`,confirmDeleteSkill:`确定删除技能 "{{name}}"?`,confirmDeleteSoul:`确定删除灵魂 "{{name}}"?`,aboutTitle:`关于 Codemini`,aboutEyebrow:`本地 coding agent`,aboutTagline:`一个更克制、更可审计的 coding agent:CLI 的速度,Web UI 的可见性,项目记忆、技能、审批和干净的上下文管理都在一起。`,aboutFeatureRuntime:`同一套运行时`,aboutFeatureRuntimeDesc:`CLI 和 Web UI 共享会话、配置、项目状态、技能和执行模式。`,aboutFeatureApprovals:`过程可审阅`,aboutFeatureApprovalsDesc:`工具调用、计划和高风险动作在执行前都能看清楚。`,aboutFeatureMemory:`上下文更稳`,aboutFeatureMemoryDesc:`压缩摘要、项目索引、记忆 inbox 和 dream consolidation 让长任务可继续。`,aboutFeatureConfig:`接入你的模型`,aboutFeatureConfigDesc:`支持 OpenAI 兼容网关或内部模型服务,不改变工作流。`,projectRepository:`GitHub 项目主页`,installation:`安装`,startWebUI:`启动 Web UI`,startWebUIDesc:`启动后浏览器会自动打开 Web 界面,也可以手动访问终端中显示的地址。`,basicUsage:`基本使用`,chatUsage:`在输入框直接输入问题或指令,按 Enter 发送`,skillUsage:`输入 / 触发技能选择面板`,soulUsage:`点击输入框工具栏的灵魂按钮切换 AI 人格`,normalMode:`普通`,autoModeAbout:`自动`,modeUsage:`需确认工具调用,`,modeUsageAuto:`全自动执行`,workspace:`工作区`,workspaceUsage:`点击输入框的文件夹按钮切换项目目录`,configureModel:`配置模型`,configureModelDesc:`支持 OpenAI 兼容接口,可在设置中配置 API Key、Endpoint 等。`,selectProject:`选择项目`,enterOrBrowse:`输入或浏览项目路径...`,select:`选择`,noSubDirs:`无子目录`,language:`语言`,switchLanguage:`切换语言`,switchThemePalette:`切换主题配色`,themeDefault:`Default`,themeCatppuccin:`Catppuccin`,themeTokyoNight:`Tokyo Night`,themeOne:`One`,themeGithub:`GitHub`,themeVSCode:`VS Code`,generalChat:`普通会话`,projectTask:`项目任务`,generalChatDesc:`无需绑定项目,自由对话`,enterGeneral:`进入普通会话`,askAnythingGeneral:`有什么可以帮你的?`,buildInProject:`要在 {{project}} 中构建什么?`,gitStaged:`已暂存`,gitModified:`已修改`,gitUntracked:`未跟踪`,gitClean:`无变更`,gitDiffTitle:`Git 差异`,gitDiffNoChanges:`无变更`,gitDiffLoading:`加载差异...`,gitDiffStaged:`已暂存`,gitDiffModified:`已修改`,gitDiffDeleted:`已删除`,gitDiffUntracked:`未跟踪`,gitDiffNoDiffAvailable:`无差异内容`,conversations:`对话`,noConversations:`暂无聊天`,justNow:`刚刚`,minutesAgo:`分钟前`,hoursAgo:`小时前`,daysAgo:`天前`},en:{brand:`Codemini`,live:`LIVE`,idle:`IDLE`,sending:`SENDING`,thinking:`THINKING`,streaming:`STREAMING`,tooling:`TOOLING`,inputPlaceholder:`Type a message or / command...`,inputDisabled:`Waiting for current request to finish...`,inputPlanReviewDisabled:`Review the plan above before continuing`,abort:`Stop`,approveTitle:`Confirm Action`,approve:`Approve`,deny:`Deny`,deleteApproval:`Confirm Delete`,runApproval:`Confirm Run Command`,planApproval:`Confirm Plan`,reflectApproval:`Confirm Save Skill`,toolRunning:`Running`,toolDone:`Done`,toolError:`Error`,toolBlocked:`Blocked`,toolGroupTools:`Ran {{count}} tools`,toolGroupCommands:`Ran {{count}} commands`,toolGroupExpand:`Click to expand`,planTitle:`Execution Plan`,planDone:`Done`,planReviewTitle:`Review Plan`,planReviewSummary:`Summary`,planReviewSteps:`Plan Steps`,planApprove:`Approve`,planReject:`Reject`,planEdit:`Edit Plan`,planEditPlaceholder:`Describe your changes...`,planSubmitFeedback:`Submit Feedback`,planStepCount:`steps`,planReviewStatus:`Awaiting Review`,planWaitingReview:`Waiting for plan review…`,waitingResponse:`Waiting for response…`,reflectReviewTitle:`Review Skill Draft`,reflectReviewStatus:`Awaiting Review`,reflectScope:`Scope`,reflectConfidence:`Confidence`,reflectApprove:`Save Skill`,reflectReject:`Discard`,reflectEdit:`Revise Draft`,reflectEditPlaceholder:`Describe how this skill draft should change...`,reflectSubmitFeedback:`Submit Feedback`,reflectReviewFirst:`Review the skill draft before continuing`,runtimeActivityDreamRunning:`Dream is consolidating memory`,runtimeActivityDreamDone:`Dream complete`,runtimeActivityDreamError:`Dream failed`,runtimeActivityCompactDone:`Context compacted`,runtimeActivityCompactPreview:`Compact preview`,runtimeActivityMicroCompactDone:`Micro-compact complete`,runtimeActivityMicroCompactPreview:`Micro-compact preview`,runtimeActivityInboxCaptured:`Saved to Inbox`,runtimeActivityInboxListed:`Inbox checked`,runtimeActivityReflectPending:`Reflect awaiting review`,runtimeActivityReflectRevised:`Reflect draft updated`,runtimeActivityReflectSaving:`Saving skill`,runtimeActivityReflectSaved:`Skill saved`,runtimeActivityReflectRevising:`Revising draft`,runtimeActivityReflectDiscarding:`Discarding draft`,runtimeActivityReflectDiscarded:`Draft discarded`,runtimeActivityReflectNone:`No reusable skill found`,skillRunning:`Running`,skillDone:`Done`,skillError:`Failed`,skillAuto:`Auto Skill`,contextUsage:`Context`,fileChanges:`File Changes`,thought:`Thought process`,thoughtFor:`Thought for {{duration}}`,thinkingNow:`Thinking...`,thoughtForNow:`Thinking for {{duration}}`,processed:`Processed`,processedFor:`Processed for {{duration}}`,processedDetails:`{{thoughts}} thoughts, {{tools}} tools`,usageTokens:`tokens`,usageCache:`cache`,usageInput:`input`,usageOutput:`output`,usageTotal:`total`,usageCacheHit:`cache hit`,usageCacheMiss:`cache miss`,usageCacheWrite:`cache write`,usageReasoning:`reasoning`,usageRequests:`{{count}} requests`,newChat:`New Chat`,skills:`Skills`,souls:`Souls`,projects:`Projects`,newSessionInProject:`New Chat in Project`,openCodeWiki:`Open CodeWiki`,collapseProject:`Collapse Project`,expandProject:`Expand Project`,sessionActions:`Session Actions`,deleteSession:`Delete`,noSessions:`No conversations yet`,about:`About`,lightMode:`Light`,darkMode:`Dark`,autoModeTheme:`System`,switchTheme:`Switch Theme`,settings:`Settings`,deleteSessionConfirm:`Delete Session?`,deleteSessionDescription:`Session "{{session}}" will be removed from history, this action cannot be undone.`,settingsTitle:`Settings`,configRequired:`Configure the API Base URL and API Key in Settings first`,configRequiredTitle:`Model gateway setup required`,configRequiredDesc:`This install is still using the default gateway endpoint. Set the Base URL, API Key, and model before chatting.`,cancel:`Cancel`,saveChanges:`Save Changes`,gateway:`Gateway`,baseUrl:`Base URL`,apiKey:`API Key`,timeout:`Timeout (ms)`,maxRetries:`Max Retries`,model:`Model`,modelName:`Model Name`,fastModel:`Fast Model`,maxContextTokens:`Max Context Tokens`,sdk:`SDK`,provider:`Provider`,execution:`Execution`,mode:`Mode`,maxSteps:`Max Steps`,context:`Context`,contextMaxTokens:`Context Token Budget`,preflightTrigger:`Preflight Trigger (%)`,hardLimit:`Hard Limit (%)`,toolResultMaxChars:`Tool Result Char Limit`,microcompactEnabled:`Micro-Compact`,microcompactKeepRecent:`Micro Keep Recent`,shell:`Shell`,defaultShell:`Default Shell`,policy:`Policy`,safeMode:`Safe Mode`,allowedPaths:`Allowed Paths`,allowedPathsHelp:`JSON array of trusted absolute directory roots. File tools and safe-mode shell path checks may access these paths in addition to the current workspace.`,allowDangerousCommands:`Allow Dangerous Commands`,ui:`UI`,uiLanguage:`UI Language`,replyLanguage:`Reply Language`,backToTop:`Back to top`,pendingItems:`Queued`,copyCode:`Copy`,copyMessage:`Copy`,copied:`Copied`,connected:`Connected`,disconnected:`Disconnected, reconnecting...`,unknownProject:`Unknown Project`,emptyChat:`Empty Chat`,messages:`messages`,renderError:`Render Error`,retry:`Retry`,planReviewFirst:`Please review the plan above, approve, modify, or reject before continuing`,loading:`Loading`,sending:`Send`,updating:`Updating...`,updatedRestart:`Updated, please restart`,updateAvailable:`new version available, click to update`,openSettings:`Open Settings`,current:`Current`,sessions:`Sessions`,items:`items`,enabled:`Enabled`,disabled:`Disabled`,disable:`Disable`,noMatches:`No matches`,generationDepthFast:`Fast`,generationDepthStandard:`Standard`,generationDepthDeep:`Deep`,startingAnalysis:`Starting project requirements analysis`,preparingScan:`Preparing to scan code, interfaces, and project structure`,generationFailed:`Generation encountered an issue`,generatingCodeWiki:`Generating CodeWiki`,stepsCompleted:`steps completed`,codewikiFailed:`CodeWiki Q&A failed`,failedToLoad:`Failed to load CodeWiki report`,failedToStart:`Failed to start CodeWiki generation`,failedToDelete:`Failed to delete CodeWiki report`,currentProject:`Current Project`,generating:`Generating`,generateNew:`Generate New CodeWiki`,report:`Report`,refreshReport:`Refresh Report`,noReportYet:`No requirements report yet. It will appear here after generation.`,reportActions:`Report Actions`,deleteReport:`Delete`,loadingReport:`Loading Report`,projectDocs:`Project documentation based on project-requirements`,generate:`Generate`,noCodeWiki:`No CodeWiki yet`,generateRequirements:`Generate requirements for the current project`,reportWillShow:`After generating the report, architecture diagrams, interface requirements, processes, and risk descriptions will be displayed here.`,reportLoadFailed:`Report failed to load.`,noQuestionsDuringGeneration:`Questions not accepted until CodeWiki generation is complete.`,tempReadOnlyQa:`Temporary read-only Q&A, will not modify the project or save to session history.`,processingQuestion:`Processing current question`,canAskAboutProject:`You can ask about the current project`,askAfterGeneration:`Ask questions based on the report after generation is complete.`,exampleQuestions:`For example: What is the main business process? Which interfaces have the highest risks?`,answering:`Answering...`,sendingQuestion:`Send Question`,deleteReportConfirm:`Delete CodeWiki Report?`,deleteReportDescription:`Report "{{report}}" will be removed from current project history reports, this action cannot be undone.`,executionMode:`Execution Mode`,normalExecutionMode:`Manual`,normalModeDesc:`Review edits and commands`,autoMode:`Auto`,autoModeDesc:`Auto-execute, complex tasks auto-plan`,planMode:`Plan`,planModeDesc:`Plan only, review before execution`,switchMode:`Switch Execution Mode`,switchModeDisabled:`Can switch execution mode after current request completes`,soulSwitch:`Soul Switch`,switchSoul:`Switch Soul`,builtin:`Built-in`,custom:`Custom`,sendMessageToCodemini:`Message Codemini`,sendMessageToCodeminiWithSlash:`Message Codemini, type / for more features`,askAnything:`You can ask Codemini anything. Type / to use commands or skills`,addContext:`Add Context`,switchWorkspace:`Switch Workspace`,name:`Name`,soulContent:`Soul Content`,newSoul:`New Soul`,editSoul:`Edit Soul`,soulEditorHint:`Souls affect response tone only; avoid execution rules or tool policy here.`,soulPlaceholder:`Describe tone, phrasing, and personality preferences...`,soulPanelHint:`Choose the default personality. New prompts will use the active soul tone.`,noActiveSoul:`No soul selected`,searchSouls:`Search souls by name...`,create:`Create`,save:`Save`,contentPreview:`- Content Preview`,close:`Close`,addSoul:`Add Soul`,noSouls:`No souls yet`,noSoulsHint:`Create a custom soul to keep Codemini response tone consistent.`,activate:`Activate`,edit:`Edit`,view:`View`,delete:`Delete`,deleting:`Deleting...`,globalScope:`Global`,projectScope:`Project`,enable:`Enable`,addSkill:`Add Skill`,installSkill:`Install`,installing:`Installing...`,skillInstallPlaceholder:`GitHub repo, URL, folder path, or npx skills@latest add owner/repo`,skillScope:`Install Scope`,noSkills:`No skills yet`,noSkillsHint:`Create a project skill to turn reusable workflows into / commands.`,skillLibrary:`Skill Library`,skillPanelHint:`Skills can be invoked as / commands or injected automatically. Built-in skills are always available.`,newSkill:`New Skill`,editSkill:`Edit Skill`,skillEditorHint:`Skills are best for stable workflows, checklists, and project conventions.`,searchSkills:`Search skills by name...`,skillDescriptionPlaceholder:`When should this skill be used...`,skillContent:`SKILL.md Content`,skillRoutingSettings:`Routing Settings`,skillMode:`Mode`,skillMode_always:`Always`,skillMode_auto_attach:`Auto Attach`,skillMode_agent_requested:`Agent Requested`,skillMode_manual:`Manual`,skillPriority:`Priority`,skillTriggers:`Triggers`,description:`Description`,noDescription:`No description`,noPreview:`No preview`,filter_all:`All`,filter_enabled:`Enabled`,filter_builtin:`Built-in`,filter_custom:`Custom`,confirmDeleteSkill:`Delete skill "{{name}}"?`,confirmDeleteSoul:`Delete soul "{{name}}"?`,aboutTitle:`About Codemini`,aboutEyebrow:`Local coding agent`,aboutTagline:`A compact, auditable coding agent with CLI speed, Web UI visibility, project memory, skills, approvals, and clean context management.`,aboutFeatureRuntime:`One runtime`,aboutFeatureRuntimeDesc:`CLI and Web UI share sessions, config, project state, skills, and execution mode.`,aboutFeatureApprovals:`Reviewable work`,aboutFeatureApprovalsDesc:`Tool calls, plans, and risky actions stay visible before they run.`,aboutFeatureMemory:`Smarter context`,aboutFeatureMemoryDesc:`Compact summaries, project index, memory inbox, and dream consolidation keep long work usable.`,aboutFeatureConfig:`Bring your model`,aboutFeatureConfigDesc:`Use OpenAI-compatible gateways or internal providers without changing the workflow.`,projectRepository:`GitHub repository`,installation:`Installation`,startWebUI:`Start Web UI`,startWebUIDesc:`After starting, the browser will automatically open the Web interface. You can also manually visit the address shown in the terminal.`,basicUsage:`Basic Usage`,chatUsage:`Type questions or instructions in the input box, press Enter to send`,skillUsage:`Type / to open the skill selection panel`,soulUsage:`Click the soul button in the input toolbar to switch AI personality`,normalMode:`Normal`,autoModeAbout:`Auto`,modeUsage:`requires confirming tool calls, `,modeUsageAuto:`executes everything automatically`,workspace:`Workspace`,workspaceUsage:`Click the folder button in the input box to switch project directory`,configureModel:`Configure Model`,configureModelDesc:`Supports OpenAI-compatible interfaces. Configure API Key, Endpoint, etc. in Settings.`,selectProject:`Select Project`,enterOrBrowse:`Enter or browse project path...`,select:`Select`,noSubDirs:`No subdirectories`,language:`Language`,switchLanguage:`Switch Language`,switchThemePalette:`Switch Theme Palette`,themeDefault:`Default`,themeCatppuccin:`Catppuccin`,themeTokyoNight:`Tokyo Night`,themeOne:`One`,themeGithub:`GitHub`,themeVSCode:`VS Code`,generalChat:`General Chat`,projectTask:`Project Task`,generalChatDesc:`Chat freely without binding to a project`,enterGeneral:`Enter General Chat`,askAnythingGeneral:`How can I help you?`,buildInProject:`What do you want to build in {{project}}?`,gitStaged:`Staged`,gitModified:`Modified`,gitUntracked:`Untracked`,gitClean:`Clean`,gitDiffTitle:`Git Diff`,gitDiffNoChanges:`No changes`,gitDiffLoading:`Loading diff...`,gitDiffStaged:`Staged`,gitDiffModified:`Modified`,gitDiffDeleted:`Deleted`,gitDiffUntracked:`Untracked`,gitDiffNoDiffAvailable:`No diff available`,conversations:`Conversations`,noConversations:`No conversations yet`,justNow:`just now`,minutesAgo:`m ago`,hoursAgo:`h ago`,daysAgo:`d ago`}},yd=`zh`,bd=localStorage.getItem(`codemini-ui-language`);bd&&vd[bd]&&(yd=bd);function xd(e){vd[e]&&(yd=e,localStorage.setItem(`codemini-ui-language`,e))}function B(e){return vd[yd][e]||vd.en[e]||e}function Sd(){return yd}var Cd={"Content-Type":`application/json`};async function V(e,t={}){return await fetch(e,t)}async function wd(){return(await V(`/api/version`)).json()}async function Td(){return(await V(`/api/update`,{method:`POST`})).json()}async function Ed(){return(await V(`/api/state`)).json()}async function Dd(){return(await V(`/api/startup-events`)).json()}async function Od(){return(await V(`/api/history`)).json()}async function kd(){return(await V(`/api/sessions`)).json()}async function Ad(){return(await V(`/api/session/messages`)).json()}async function jd(){return(await V(`/api/session/ui-messages`)).json()}async function Md(e,t={}){return await V(`/api/submit`,{method:`POST`,headers:Cd,body:JSON.stringify({line:e,...t.readOnlyCodeWiki?{readOnlyCodeWiki:!0}:{}})})}async function Nd(){await V(`/api/abort`,{method:`POST`})}async function Pd(e){return(await V(`/api/execution-mode`,{method:`POST`,headers:Cd,body:JSON.stringify({mode:e})})).json()}async function Fd(e,t){await V(`/api/approval`,{method:`POST`,headers:Cd,body:JSON.stringify({id:e,approved:t})})}async function Id(e){return(await V(`/api/sessions/switch`,{method:`POST`,headers:Cd,body:JSON.stringify({sessionId:e})})).json()}async function Ld(e){return(await V(`/api/sessions/${encodeURIComponent(e)}`,{method:`DELETE`})).json()}async function Rd(){return(await V(`/api/sessions/new`,{method:`POST`})).json()}async function zd(){return(await V(`/api/config`)).json()}async function Bd(){return(await V(`/api/config/status`)).json()}async function Vd(e,t){return(await V(`/api/config/set`,{method:`POST`,headers:Cd,body:JSON.stringify({key:e,value:t})})).json().catch(()=>({}))}async function Hd(){return(await V(`/api/project`)).json()}async function Ud(){return(await V(`/api/git`)).json()}async function Wd(){return(await V(`/api/git-diff`)).json()}async function Gd(e){return(await V(`/api/git-batch`,{method:`POST`,headers:Cd,body:JSON.stringify({dirs:e})})).json()}async function Kd(e){return(await V(`/api/project/open`,{method:`POST`,headers:Cd,body:JSON.stringify({path:e})})).json()}async function qd(e){return(await V(`/api/project/browse`,{method:`POST`,headers:Cd,body:JSON.stringify({dir:e})})).json()}async function Jd(){return(await V(`/api/skills`)).json()}async function Yd(e){return(await V(`/api/skills/${encodeURIComponent(e)}/content`)).json()}async function Xd({name:e,description:t,content:n,scope:r}){return(await V(`/api/skills/create`,{method:`POST`,headers:Cd,body:JSON.stringify({name:e,description:t,content:n,scope:r})})).json()}async function Zd({source:e,scope:t}){return(await V(`/api/skills/install`,{method:`POST`,headers:Cd,body:JSON.stringify({source:e,scope:t})})).json()}async function Qd(e,t){return(await V(`/api/skills/${encodeURIComponent(e)}/content`,{method:`PUT`,headers:Cd,body:JSON.stringify({content:t})})).json()}async function $d(e,t){return(await V(`/api/skills/${encodeURIComponent(e)}/metadata`,{method:`PUT`,headers:Cd,body:JSON.stringify(t||{})})).json()}async function ef(e){return(await V(`/api/skills/${encodeURIComponent(e)}`,{method:`DELETE`})).json()}async function tf(e,t){return(await V(`/api/skills/${encodeURIComponent(e)}/toggle`,{method:`POST`,headers:Cd,body:JSON.stringify({enabled:t})})).json()}async function nf(){return(await V(`/api/souls`)).json()}async function rf(e){return(await V(`/api/souls/${encodeURIComponent(e)}/content`)).json()}async function af({name:e,content:t}){return(await V(`/api/souls/create`,{method:`POST`,headers:Cd,body:JSON.stringify({name:e,content:t})})).json()}async function of(e,t){return(await V(`/api/souls/${encodeURIComponent(e)}/content`,{method:`PUT`,headers:Cd,body:JSON.stringify({content:t})})).json()}async function sf(e){return(await V(`/api/souls/${encodeURIComponent(e)}`,{method:`DELETE`})).json()}async function cf(e){return(await V(`/api/souls/activate`,{method:`POST`,headers:Cd,body:JSON.stringify({name:e})})).json()}function lf(e=``){return e?`?project=${encodeURIComponent(e)}`:``}async function uf(e=``){return(await V(`/api/codewiki/reports${lf(e)}`)).json()}async function df(e=``){return(await V(`/api/codewiki/symbol-graph${lf(e)}`)).json()}async function ff(e=`standard`,t=``){return(await V(`/api/codewiki/generate${lf(t)}`,{method:`POST`,headers:Cd,body:JSON.stringify({depth:e})})).json()}async function pf({question:e,reportFile:t=``,project:n=``,onEvent:r}={}){let i=await V(`/api/codewiki/ask${lf(n)}`,{method:`POST`,headers:Cd,body:JSON.stringify({question:e,reportFile:t})});if(!i.ok){let e=await i.json().catch(()=>({}));throw Error(e?.message||`CodeWiki 问答失败`)}if(!i.body)throw Error(`当前浏览器不支持流式响应`);let a=i.body.getReader(),o=new TextDecoder,s=``;for(;;){let{value:e,done:t}=await a.read();if(t)break;s+=o.decode(e,{stream:!0});let n=s.indexOf(`
60
- `);for(;n!==-1;){let e=s.slice(0,n).trim();s=s.slice(n+1),e&&r?.(JSON.parse(e)),n=s.indexOf(`
61
- `)}}s+=o.decode();let c=s.trim();c&&r?.(JSON.parse(c))}async function mf(e,t=``){return(await V(`/api/codewiki/report/${encodeURIComponent(e)}${lf(t)}`,{method:`DELETE`})).json()}var hf=(0,d.createContext)(null);function gf(e){let t=String(e?.name||``).toLowerCase(),n=String(e?.summary||``).toLowerCase();return t.includes(`project_index`)||t.includes(`initializeprojectindex`)||n.includes(`project_index(`)||n.includes(`initialized `)&&n.includes(`/.codemini`)}function _f(){let e=window.location.pathname.replace(/\/+$/,``)||`/`,t=new URLSearchParams(window.location.search),n=e.match(/^\/chat\/([^/]+)$/);return n?{view:`chat`,sessionId:decodeURIComponent(n[1])}:e===`/codewiki`?{view:`codewiki`,projectPath:t.get(`project`)||``}:{view:`chat`}}function vf(e,t,n={}){if(e===`codewiki`){let e=String(n.projectPath||``).trim();return e?`/codewiki?project=${encodeURIComponent(e)}`:`/codewiki`}return t?`/chat/${encodeURIComponent(t)}`:`/`}function yf(e,t,{replace:n=!1,projectPath:r=``}={}){let i=vf(e,t,{projectPath:r});if(`${window.location.pathname}${window.location.search}`===i)return;let a={view:e,sessionId:t||null,projectPath:r||null};n?window.history.replaceState(a,``,i):window.history.pushState(a,``,i)}var bf={stage:`idle`,busy:!1,currentView:`chat`,runtimeState:null,live:!1,stageLabel:``,messages:[],activeMsgId:null,pendingToolChanges:[],planSteps:[],pendingPlanApproval:null,pendingReflectApproval:null,runtimeActivities:[],approvalRequest:null,config:null,configStatus:null,configOpen:!1,projectOpen:!1,skillsOpen:!1,soulsOpen:!1,aboutOpen:!1,gitDiffOpen:!1,sessions:[],projectCwd:null,isGeneral:!1,history:[],skills:[],gitInfo:null,gitBatch:{},codewikiProjectPath:``,versionInfo:null,updateStatus:null,initialLoading:!0,sessionsLoading:!1,messagesLoading:!1};function xf(e){let t=String(e||``),n=t.match(/^\[Executing skill: \/([^\]\s]+)\]\n\n/);if(!n)return t;let r=`/${n[1]}`,i=t.match(/\nCurrent question:\n([\s\S]+)$/);return i?.[1]?.trim()?`${r} ${i[1].trim()}`:r}function Sf(e,t,n){return e.map(e=>{if(e.type!==`tools`)return e;let r=e.cards.findIndex(e=>e.id===t);if(r===-1)return e;let i=[...e.cards];return i[r]=n(i[r]),{...e,cards:i}})}function Cf(e,t){if(e.length===0)return[{type:`tools`,cards:[t]}];let n=e[e.length-1];return n.type===`tools`?[...e.slice(0,-1),{...n,cards:[...n.cards,t]}]:[...e,{type:`tools`,cards:[t]}]}function wf(e){return e.length===0?[{type:`text`,text:``,isStreaming:!1}]:e[e.length-1].type===`text`?e:[...e,{type:`text`,text:``,isStreaming:!1}]}function Tf(e,t){let n=wf(e),r=n[n.length-1];return[...n.slice(0,-1),{...r,text:(r.text||``)+t,isStreaming:!0}]}function Ef(e,t,n=!0){let r=String(t||``);if(!r)return e||[];let i=Array.isArray(e)?e:[],a=new Date().toISOString(),o=Date.parse(a),s=i[i.length-1];if(s?.type===`thinking`){let e=s.startedAt||a;return[...i.slice(0,-1),{...s,text:`${s.text||``}${r}`,isStreaming:n,startedAt:e,endedAt:n?null:s.endedAt||a,durationMs:Math.max(Number(s.durationMs||0),o-Date.parse(e))}]}return[...i,{type:`thinking`,text:r,isStreaming:n,startedAt:a,endedAt:n?null:a,durationMs:n?0:null}]}function Df(e,t){let n=Number(e?.durationMs),r=Date.parse(e?.startedAt||``),i=Date.parse(e?.endedAt||t||``),a=Number.isFinite(r)&&Number.isFinite(i)?Math.max(0,i-r):null;return Number.isFinite(n)&&a!=null?Math.max(n,a):Number.isFinite(n)?Math.max(0,n):a}function Of(e){let t=new Date().toISOString();return(Array.isArray(e)?e:[]).map(e=>e.type===`thinking`?{...e,isStreaming:!1,endedAt:e.endedAt||t,durationMs:Df(e,t)}:e)}function kf(e){if(!e||typeof e!=`object`)return null;let t={};for(let n of[`inputTokens`,`outputTokens`,`totalTokens`,`cachedInputTokens`,`cacheMissInputTokens`,`cacheWriteInputTokens`,`reasoningOutputTokens`,`requests`]){let r=Number(e?.[n]);Number.isFinite(r)&&(t[n]=Math.max(0,Math.round(r)))}return Object.keys(t).length?t:null}function Af(e,t){let n=kf(e),r=kf(t);if(!n)return r;if(!r)return n;let i={};for(let e of[`inputTokens`,`outputTokens`,`totalTokens`,`cachedInputTokens`,`cacheMissInputTokens`,`cacheWriteInputTokens`,`reasoningOutputTokens`,`requests`])i[e]=Math.max(0,Math.round(Number(n[e]||0)+Number(r[e]||0)));return i}function jf(e){return Array.isArray(e)?e.map(e=>!e||typeof e!=`object`?``:e.type===`thinking`?e.thinking||e.text||``:e.type===`reasoning`||e.type===`reasoning_content`?e.text||e.reasoning_content||``:e.type===`redacted_thinking`?`[redacted thinking]`:``).filter(Boolean).join(`
62
-
63
- `):``}function Mf(e){return String(e?.reasoningContent||e?.reasoning_content||``).trim()||jf(e?.reasoningDetails||e?.reasoning_details).trim()}function Nf(e){return String(e||``).replace(/(?:^|\n)\[plan\]\s+Step\s+\d+\/\d+\s+->[^\n]*\n?/g,``)}function Pf(e){if(!e)return null;if(typeof e==`object`)return e;if(typeof e!=`string`)return null;try{return JSON.parse(e)}catch{return null}}function Ff(e,t){let n=String(e||``).split(`.`)[0].toLowerCase();if(![`edit`,`write`,`delete`].includes(n)||!t||typeof t!=`object`)return null;if(t.deleted){let e=String(t.path||``);return e?{path:e,action:`delete`,linesAdded:0,linesRemoved:0}:null}if(!(`path`in t)||!(`action`in t))return null;let r=String(t.path||``);return r?{path:r,action:String(t.action||``)===`create`?`create`:`edit`,linesAdded:Number(t.lines_added??t.linesAdded??0),linesRemoved:Number(t.lines_removed??t.linesRemoved??0),changedLine:Number(t.changed_line??t.changedLine??0),diffPreview:String(t.diff_preview??t.diffPreview??``)}:null}function If(e=[]){let t=[];for(let n of Array.isArray(e)?e:[])if(n?.type===`tools`)for(let e of Array.isArray(n.cards)?n.cards:[]){let n=e.fileChange||Ff(e.name,Pf(e.result));n?.path&&t.push(n)}return t}function Lf(e,t){let n=new Set(Array.isArray(t)?t:[t]);return e.filter(e=>{if(n.has(e.transientKey))return!1;let t=String(e.text||``);return!(n.has(`plan-waiting-review`)&&(t.includes(`等待计划审阅`)||t.includes(`Waiting for plan review`))||n.has(`waiting-response`)&&(t.includes(`等待回复`)||t.includes(`Waiting for response`)))})}function Rf(e){let t=String(e||``);return t.includes(`Auto plan finished`)||t.includes(`Plan created and waiting for approval`)||t.includes(`Pending plan approval`)||t.includes(`Plan File:`)&&t.includes(`/yes`)}function zf(e){let t=String(e||``);return t.includes(`Reflect skill draft pending.`)||t.includes(`Reflect skill draft revised.`)||t.includes(`Reflect skill written and loaded:`)||t.includes(`Reflect skill draft discarded.`)}function Bf(e){let t=String(e||``).trim();if(t.startsWith(`Reflect skill written and loaded:`)){let e=t.match(/\/[A-Za-z0-9_-]+/)?.[0]||``;return{key:`reflect`,status:`done`,emoji:`✨`,label:B(`runtimeActivityReflectSaved`),detail:e}}return t.startsWith(`Reflect skill draft revised.`)?{key:`reflect`,status:`running`,emoji:`📝`,label:B(`runtimeActivityReflectRevised`)}:t.startsWith(`Reflect skill draft pending.`)?{key:`reflect`,status:`running`,emoji:`🪞`,label:B(`runtimeActivityReflectPending`)}:t.startsWith(`Reflect skill draft discarded.`)?{key:`reflect`,status:`done`,emoji:`🗑️`,label:B(`runtimeActivityReflectDiscarded`)}:t.startsWith(`Reflect found no reusable skill candidate.`)?{key:`reflect`,status:`done`,emoji:`🪞`,label:B(`runtimeActivityReflectNone`)}:t.startsWith(`Dream failed:`)?{key:`dream`,status:`error`,emoji:`⚠️`,label:B(`runtimeActivityDreamError`),detail:t.slice(13).trim()}:t.startsWith(`Dream done`)?{key:`dream`,status:`done`,emoji:`🌙`,label:B(`runtimeActivityDreamDone`)}:t.startsWith(`Micro-compact`)?{key:`compact`,status:`done`,emoji:`🪄`,label:t.includes(` preview`)?B(`runtimeActivityMicroCompactPreview`):B(`runtimeActivityMicroCompactDone`),detail:t.split(`
64
- `)[0]}:t.startsWith(`Compact `)||t===`Context restored to full view`?{key:`compact`,status:`done`,emoji:`🧳`,label:t.includes(` preview`)?B(`runtimeActivityCompactPreview`):B(`runtimeActivityCompactDone`),detail:t.split(`
65
- `)[0]}:t.startsWith(`Captured to inbox:`)?{key:`inbox`,status:`done`,emoji:`📥`,label:B(`runtimeActivityInboxCaptured`)}:t.startsWith(`Inbox (`)||t===`Inbox is empty.`?{key:`inbox`,status:`done`,emoji:`📬`,label:B(`runtimeActivityInboxListed`)}:null}function Vf(e){let t=new Map;for(let n of e||[]){if(n?.role!==`assistant`)continue;let e=Bf(n.content);if(!e)continue;let r=e.key||`runtime`;t.set(r,{id:`runtime-${r}`,key:r,status:e.status||`done`,emoji:e.emoji||`•`,label:e.label||``,detail:e.detail||``,timestamp:n.at||new Date().toISOString()})}return[...t.values()].sort((e,t)=>String(t.timestamp).localeCompare(String(e.timestamp))).slice(0,3)}function Hf(e){let t=String(e||``).trim().toLowerCase();return[`yes`,`y`,`/yes`,`/plan approve`,`approve`,`approved`,`no`,`n`,`/no`,`/reject`].includes(t)||t.startsWith(`/edit `)}function Uf(e){let t=String(e||``).trim().toLowerCase();return[`/yes`,`/plan approve`,`/no`,`/reject`].includes(t)||t.startsWith(`/edit `)}function Wf(e){return{id:`plan-step-${e.step}-${Date.now()}-${Math.random().toString(36).slice(2,8)}`,role:e.role||`general`,isComplete:!1,text:``,segments:[],skillBadges:[],fileChanges:[],timestamp:new Date().toISOString(),planStep:{step:e.step,total:e.total,role:e.role||`general`,title:e.title||``,status:`running`,summary:``}}}function Gf(e){let t=String(e||``),n=[...t.matchAll(/^\[(DONE|FAILED|RUNNING)\]\s+([A-Za-z0-9_-]+):\s*(.*)$/gm)];return!n.length||n[0].index>t.slice(0,n[0].index).trim().length?null:n.map((e,r)=>{let i=n[r+1],a=e.index+e[0].length,o=i?i.index:t.length,s=String(e[1]||``).toLowerCase();return{step:r+1,total:n.length,status:s===`failed`?`failed`:s===`done`?`done`:`running`,role:String(e[2]||`general`).toLowerCase(),title:String(e[3]||``).trim(),body:t.slice(a,o).trim()}})}function Kf(e,t){let n=e.role===`summarizer`;return{id:`plan-history-${Date.now()}-${t}-${e.step}`,role:e.role||`general`,segments:n&&e.body?[{type:`text`,text:e.body,isStreaming:!1}]:[],skillBadges:[],fileChanges:[],planStep:{step:e.step,total:e.total,role:e.role||`general`,title:e.title||``,status:e.status||`done`,summary:``}}}function qf(e,t){let n=Array.isArray(e.segments)?e.segments:[];return{id:`plan-transcript-${Date.now()}-${t}-${e.step||0}`,role:e.role||`general`,segments:n,skillBadges:[],fileChanges:Array.isArray(e.fileChanges)?e.fileChanges:If(n),usage:kf(e.usage),planStep:{step:e.step,total:e.total,role:e.role||`general`,title:e.title||``,status:e.status||`done`,summary:e.summary||``}}}function Jf({children:e}){let[t,n]=(0,d.useState)(bf),r=(0,d.useRef)(t);r.current=t;let i=(0,d.useRef)(null),a=(0,d.useRef)([]),o=(0,d.useRef)(!1),s=(0,d.useRef)(new Map),c=(0,d.useRef)(new Map),l=(0,d.useRef)(null),u=(0,d.useRef)(null),f=(0,d.useCallback)(e=>{n(t=>({...t,...e}))},[]),p=(0,d.useCallback)(e=>{let t=e.id||`msg-${Date.now()}-${Math.random().toString(36).slice(2,8)}`,r=[];e.text&&r.push({type:`text`,text:e.text,isStreaming:e.isStreaming||!1});let i={...e,id:t,segments:r,skillBadges:[],fileChanges:[]};return n(e=>({...e,messages:[...e.messages,i]})),t},[]),m=(0,d.useCallback)((e,t=6500)=>{clearTimeout(c.current.get(e));let r=setTimeout(()=>{c.current.delete(e),n(t=>({...t,runtimeActivities:t.runtimeActivities.filter(t=>t.id!==e)}))},t);c.current.set(e,r)},[]),h=(0,d.useCallback)(e=>{let t=e.key||e.id||`runtime`,r=`runtime-${t}`,i=Number(e.clearAfterMs),a={id:r,key:t,status:e.status||`done`,emoji:e.emoji||`•`,label:e.label||``,detail:e.detail||``,sticky:e.sticky===!0||t===`reflect`,timestamp:new Date().toISOString()};clearTimeout(c.current.get(r)),c.current.delete(r),n(e=>({...e,runtimeActivities:[a,...e.runtimeActivities.filter(e=>e.id!==r)].slice(0,4)})),a.status!==`running`&&!a.sticky?m(r,Number.isFinite(i)?i:6500):a.status===`running`&&Number.isFinite(i)&&m(r,i)},[m]),g=(0,d.useCallback)(e=>{i.current=e,f({activeMsgId:e})},[f]),v=(0,d.useCallback)(async()=>{try{let e=await Ed(),t=e.isGeneral?`__codemini_general__`:e.cwd?.split(/[/\\]/).pop()||e.cwd||`...`,r=!!e.busy;return n(n=>({...n,runtimeState:e,projectCwd:t,isGeneral:!!e.isGeneral,pendingPlanApproval:e?.pendingPlanApproval||null,pendingReflectApproval:e?.pendingReflectSkill||null,busy:r,live:r||n.live,stage:r?`thinking`:n.stage,stageLabel:r?B(`waitingResponse`):n.stageLabel,messages:e?.pendingPlanApproval?n.messages:Lf(n.messages,`plan-waiting-review`)})),e}catch{return null}},[f]),y=(0,d.useCallback)(async({openIfRequired:e=!1}={})=>{try{let t=await Bd();return f({configStatus:t,configOpen:e&&t?.setupRequired?!0:r.current.configOpen}),t}catch{return null}},[f]),b=(0,d.useCallback)(async()=>{try{f({gitInfo:await Ud()})}catch{}},[f]),x=(0,d.useCallback)(async e=>{let t=[...new Set((e||[]).map(e=>e.projectDir).filter(Boolean))];if(t.length)try{f({gitBatch:await Gd(t)})}catch{}},[f]),S=(0,d.useCallback)(async()=>{try{let e=await Od();f({history:Array.isArray(e)?e:[]})}catch{}},[f]),C=(0,d.useCallback)(async()=>{f({sessionsLoading:!0});try{let e=await kd(),t=Array.isArray(e)?e:[];f({sessions:t}),x(t)}catch{}finally{f({sessionsLoading:!1})}},[f,x]),w=(0,d.useCallback)(async e=>{if(!e)return null;try{let t=await Ed();if(t?.cwd===e)return t;let n=await Kd(e);return n?.error?null:n}catch{return null}},[]),T=(0,d.useCallback)(async()=>{try{let e=await Jd();f({skills:Array.isArray(e)?e:[]})}catch{}},[f]),E=(0,d.useCallback)(async()=>{f({messagesLoading:!0});try{let e=await Ad(),t=Array.isArray(e)?e:e.messages||[],n=e?.compact||null,r=Vf(t);if(!t.length){let e=await jd();Array.isArray(e)&&e.length&&f({messages:e});return}let i=[],a=null,o=n?.boundaryIndex,s=o==null;for(let e=0;e<t.length;e++){let r=t[e];if(!s&&e>=o&&(i.push({id:`msg-compact-divider-${Date.now()}`,role:`divider`,dividerType:`compact`,text:`以上内容已压缩 (${n.mode||``})`,timestamp:n.timestamp||new Date().toISOString()}),s=!0),r.role===`user`){if(Uf(r.content))continue;a=null;let e=xf(r.content||``);i.push({id:`msg-${Date.now()}-${Math.random().toString(36).slice(2,8)}-u${i.length}`,role:`you`,segments:[{type:`text`,text:e,isStreaming:!1}],skillBadges:[],fileChanges:[]})}else if(r.role===`assistant`){if(Bf(r.content)&&zf(r.content)){a=null;continue}if(Array.isArray(r.planTranscript)&&r.planTranscript.length){a=null;for(let e of r.planTranscript)i.push(qf(e,i.length));continue}let e=Gf(r.content);if(e?.length){a=null;let t=[...e].reverse().find(e=>e.role===`summarizer`)||e[e.length-1];i.push(Kf({...t,step:1,total:1,role:t.role||`summarizer`},i.length));continue}a||(a={id:`msg-${Date.now()}-${Math.random().toString(36).slice(2,8)}-a${i.length}`,role:`general`,segments:[],skillBadges:[],fileChanges:[]},i.push(a)),a.usage=Af(a.usage,r.usage);let t=Mf(r);if(t&&a.segments.push({type:`thinking`,text:t,isStreaming:!1,startedAt:r.reasoningStartedAt||r.at||null,endedAt:r.reasoningEndedAt||r.at||null,durationMs:Number.isFinite(Number(r.reasoningDurationMs))?Number(r.reasoningDurationMs):null}),r.content&&a.segments.push({type:`text`,text:r.content,isStreaming:!1}),r.toolCalls&&r.toolCalls.length){let e=r.toolCalls.map(e=>({id:e.id,name:e.function?.name||e.name||`tool`,arguments:e.function?.arguments||e.arguments||{},status:e.status||`done`,durationMs:e.durationMs,summary:e.summary||``,result:``,...e.fileChange?{fileChange:e.fileChange}:{}})),t=If([{type:`tools`,cards:e}]);t.length&&(a.fileChanges=[...a.fileChanges||[],...t]),a.segments.push({type:`tools`,cards:e})}}else if(r.role===`tool`&&a){let e=r.toolCallId||r.tool_call_id;if(!e)continue;for(let t of a.segments){if(t.type!==`tools`)continue;let n=t.cards.find(t=>t.id===e);if(!n)continue;r.toolSummary&&(n.summary=r.toolSummary),r.toolDurationMs!=null&&(n.durationMs=r.toolDurationMs),r.toolStatus===`error`&&(n.status=`error`),r.toolStatus===`blocked`&&(n.status=`blocked`),r.content&&(n.result=r.content);let i=Ff(n.name,Pf(r.content));i?.path&&(n.fileChange=i,a.fileChanges=[...a.fileChanges||[],i]);break}}}f({messages:i,runtimeActivities:r})}catch{}finally{f({messagesLoading:!1})}},[f]),D=(0,d.useCallback)(e=>{if(!e?.type||gf(e))return;let t=r.current,c=i.current;switch(e.type){case`connected`:break;case`assistant:start`:{if(t.currentView!==`chat`&&t.currentView!==`codewiki`&&f({currentView:`chat`}),n(e=>({...e,messages:Lf(e.messages,`waiting-response`)})),o.current){f({stage:`thinking`,busy:!0,live:!0,stageLabel:B(`thinking`)});break}let e=c;e?n(t=>({...t,messages:t.messages.map(t=>t.id===e?{...t,isComplete:!1}:t)})):(e=p({role:`general`,timestamp:new Date().toISOString(),text:``,isStreaming:!1,isComplete:!1}),g(e)),f({stage:`thinking`,busy:!0,live:!0,stageLabel:B(`thinking`)});break}case`assistant:delta`:{let t=Nf(e.text);c&&t&&n(e=>({...e,messages:e.messages.map(e=>e.id===c?{...e,segments:Tf(Of(e.segments),t)}:e)})),f({stage:`streaming`,live:!0,stageLabel:B(`streaming`)});break}case`assistant:reasoning_delta`:c&&e.text&&n(t=>({...t,messages:t.messages.map(t=>t.id===c?{...t,segments:Ef(t.segments,e.text,!0)}:t)})),f({stage:`thinking`,live:!0,stageLabel:B(`thinking`)});break;case`assistant:tool_call_delta`:break;case`assistant:response`:c&&n(t=>({...t,messages:t.messages.map(t=>{if(t.id!==c)return t;let n=Mf(e.assistantMessage),r=n&&!(Array.isArray(t.segments)?t.segments:[]).some(e=>e.type===`thinking`&&String(e.text||``).trim())?{...t,segments:Ef(t.segments,n,!1)}:t;if(e.text){let t=Nf(e.text),n=wf(r.segments),i=n.length-1;return{...r,usage:Af(r.usage,e.usage||e.assistantMessage?.usage),segments:Of(n).map((e,n)=>n===i&&e.type===`text`?{...e,text:t,isStreaming:!1}:e)}}return{...r,usage:Af(r.usage,e.usage||e.assistantMessage?.usage),segments:Of(r.segments).map(e=>e.type===`text`?{...e,isStreaming:!1}:e)}})}));break;case`tool:start`:if(f({stage:`tooling`,live:!0,stageLabel:B(`tooling`)}),c){let t={id:e.id,name:e.name,arguments:e.arguments,status:`running`,durationMs:null,summary:``,result:``};n(e=>({...e,messages:e.messages.map(e=>e.id===c?{...e,segments:Cf(Of(e.segments),t)}:e)}))}break;case`tool:end`:c&&n(t=>({...t,messages:t.messages.map(t=>t.id===c?(e.fileChange&&(a.current=[...a.current,e.fileChange]),{...t,segments:Sf(t.segments,e.id,t=>{let n={...t,status:`done`,durationMs:e.durationMs};return e.summary&&(n.summary=e.summary),n})}):t)}));break;case`tool:result`:c&&n(t=>({...t,messages:t.messages.map(t=>t.id===c?{...t,segments:Sf(t.segments,e.id,t=>({...t,result:e.content||``}))}:t)}));break;case`tool:error`:c&&n(t=>({...t,messages:t.messages.map(t=>t.id===c?{...t,segments:Sf(t.segments,e.id,t=>({...t,status:`error`,durationMs:e.durationMs,summary:e.summary||t.summary}))}:t)}));break;case`tool:blocked`:c&&n(t=>({...t,messages:t.messages.map(t=>t.id===c?{...t,segments:Sf(t.segments,e.id,e=>({...e,status:`blocked`,summary:B(`toolBlocked`)}))}:t)}));break;case`system_tool:start`:p({role:`system`,text:`${e.name||`System`}: ${e.summary||``}`,timestamp:new Date().toISOString()});break;case`plan:steps`:{let t=(e.steps||[]).map((e,t)=>({index:e.index??t,title:e.title,role:e.role,status:`pending`}));o.current=!0,s.current=new Map,g(null),f({planSteps:t,pendingPlanApproval:null});break}case`plan:progress`:{let{step:t,status:r}=e;n(e=>({...e,planSteps:e.planSteps.map((e,n)=>n===t-1?{...e,status:r}:e)}));break}case`plan:step_start`:{o.current=!0,r.current.pendingPlanApproval&&f({pendingPlanApproval:null});let t=String(e.step),i=s.current.get(t);if(i)n(e=>({...e,messages:e.messages.map(e=>e.id===i?{...e,isComplete:!1,planStep:{...e.planStep||{},status:`running`}}:e)}));else{let r=Wf(e);i=r.id,s.current.set(t,i),n(e=>({...e,messages:[...Lf(e.messages,`waiting-response`),r]}))}g(i),f({stage:`tooling`,busy:!0,live:!0,stageLabel:`${e.role||`agent`}: ${e.title||``}`.trim()});break}case`plan:step_done`:{let t=s.current.get(String(e.step));t&&n(n=>({...n,messages:n.messages.map(n=>n.id===t?{...n,segments:Of(n.segments).map(e=>e.type===`text`?{...e,isStreaming:!1}:e),isComplete:!0,planStep:{...n.planStep||{},status:e.status||`done`,summary:e.summary||``}}:n)}));break}case`plan:pending_approval`:n(t=>({...t,messages:[...Lf(t.messages,[`plan-waiting-review`,`waiting-response`]).filter(e=>!Rf(e.text)),{id:`msg-${Date.now()}-${Math.random().toString(36).slice(2,8)}`,role:`system`,text:B(`planWaitingReview`),segments:[{type:`text`,text:B(`planWaitingReview`),isStreaming:!1}],skillBadges:[],fileChanges:[],transientKey:`plan-waiting-review`,timestamp:new Date().toISOString()}],pendingPlanApproval:{goal:e.goal,summary:e.summary,filePath:e.filePath,steps:e.steps||[]}}));break;case`plan:approval_cleared`:n(e=>({...e,pendingPlanApproval:null,messages:Lf(e.messages,`plan-waiting-review`)}));break;case`reflect:pending_approval`:h({key:`reflect`,status:`running`,emoji:r.current.pendingReflectApproval?`📝`:`🪞`,label:r.current.pendingReflectApproval?B(`runtimeActivityReflectRevised`):B(`runtimeActivityReflectPending`),detail:e.draft?.name?`/${e.draft.name}`:``}),f({pendingReflectApproval:e.draft||null});break;case`reflect:approval_cleared`:f({pendingReflectApproval:null});break;case`skill:start`:c&&n(t=>({...t,messages:t.messages.map(t=>t.id===c?{...t,skillBadges:[...t.skillBadges,{name:e.name,status:`running`}]}:t)}));break;case`skill:end`:c&&n(t=>({...t,messages:t.messages.map(t=>t.id===c?{...t,skillBadges:t.skillBadges.map(t=>t.name===e.name?{...t,status:`done`}:t)}:t)}));break;case`skill:error`:c&&n(t=>({...t,messages:t.messages.map(t=>t.id===c?{...t,skillBadges:t.skillBadges.map(t=>t.name===e.name?{...t,status:`error`}:t)}:t)}));break;case`skill:auto`:if(c){let t=(e.names||[]).join(`, `);n(e=>({...e,messages:e.messages.map(e=>e.id===c?{...e,skillBadges:[...e.skillBadges,{name:t,status:`auto`}]}:e)}))}break;case`compact:auto`:h({key:`compact`,status:`done`,emoji:`🧳`,label:B(`runtimeActivityCompactDone`),detail:`${e.mode||`auto`} ${e.threshold?`${e.threshold}%`:``}`.trim()}),p({role:`divider`,dividerType:`compact`,text:`以上内容已压缩 (${e.mode||``}, ${e.threshold||``}%)`,timestamp:new Date().toISOString()});break;case`dream:auto`:{let e=r.current.runtimeActivities.find(e=>e.key===`dream`);if(e&&e.status!==`running`&&Date.now()-Date.parse(e.timestamp||``)<1e4)break}h({key:`dream`,status:`running`,emoji:`💤`,label:B(`runtimeActivityDreamRunning`),clearAfterMs:1800*1e3}),p({role:`system`,text:`Dream triggered...`,timestamp:new Date().toISOString()});break;case`dream:complete`:h({key:`dream`,status:e.report?.ok===!1?`error`:`done`,emoji:e.report?.ok===!1?`⚠️`:`🌙`,label:e.report?.ok===!1?B(`runtimeActivityDreamError`):B(`runtimeActivityDreamDone`),detail:e.report?.error||``,clearAfterMs:2500}),p({role:`system`,text:`Dream complete`,timestamp:new Date().toISOString()});break;case`approval:request`:f({approvalRequest:e});break;case`submit:done`:{let t=e.result||{};if(c&&a.current.length&&(n(e=>({...e,messages:e.messages.map(e=>e.id===c?{...e,fileChanges:[...e.fileChanges,...a.current]}:e)})),a.current=[]),c&&n(e=>({...e,messages:e.messages.map(e=>e.id===c?{...e,isComplete:!0,segments:Of(e.segments).map(e=>e.type===`text`?{...e,isStreaming:!1}:e)}:e)})),t.type===`system`&&t.text){let e=Bf(t.text);e&&h(e),!r.current.pendingPlanApproval&&!r.current.pendingReflectApproval&&!Rf(t.text)&&!zf(t.text)&&p({role:`system`,text:t.text,timestamp:new Date().toISOString()})}t.type===`error`&&t.text&&p({role:`error`,text:`Failed: ${t.text}`,timestamp:new Date().toISOString()}),g(null),o.current=!1,s.current=new Map,n(e=>({...e,stage:`idle`,busy:!1,live:!1,stageLabel:``,messages:Lf(e.messages,r.current.pendingPlanApproval?`waiting-response`:[`waiting-response`,`plan-waiting-review`])})),S(),C();let i=r.current.runtimeState;i?.sessionId&&r.current.currentView===`chat`&&yf(`chat`,i.sessionId,{replace:!0});break}case`mode:changed`:{let t=e;f({runtimeState:{...r.current.runtimeState,mode:t.mode,...t}});break}case`runtime:state`:{let t=e.state||{};f({runtimeState:{...r.current.runtimeState,...t},pendingPlanApproval:t?.pendingPlanApproval||null,pendingReflectApproval:t?.pendingReflectSkill||null,busy:!!t.busy,live:!!t.busy,stage:t.busy?r.current.stage:`idle`,stageLabel:t.busy?r.current.stageLabel:``});break}case`runtime:switched`:n(e=>({...e,messages:[],planSteps:[],pendingPlanApproval:null,pendingReflectApproval:null,runtimeActivities:[]})),i.current=null,a.current=[],v(),b(),S(),E(),C(),r.current.currentView!==`codewiki`&&yf(`chat`,e.sessionId);break;case`session:title`:e.sessionId&&e.title&&n(t=>({...t,sessions:t.sessions.map(t=>t.id===e.sessionId?{...t,title:e.title}:t)}));break}},[p,f,h,S,C,v,E]),O=(0,d.useCallback)(()=>{l.current&&l.current.close();let e=new EventSource(`/api/events`);e.onmessage=e=>{try{D(JSON.parse(e.data))}catch(e){console.error(`SSE:`,e)}},e.onerror=()=>{e.close(),clearTimeout(u.current),u.current=setTimeout(O,3e3)},l.current=e},[D]);(0,d.useEffect)(()=>{(async()=>{let e=_f();if(f({currentView:e.view,codewikiProjectPath:e.view===`codewiki`?e.projectPath||``:r.current.codewikiProjectPath}),e.sessionId)try{(await Ed()).sessionId!==e.sessionId&&await Id(e.sessionId)}catch{}else e.view===`codewiki`&&e.projectPath&&await w(e.projectPath);await y({openIfRequired:!0});try{let e=await Dd();for(let t of e)if(!(!t||gf(t))&&(t.type===`system_tool`||t.type===`tool`)){let e=t.summary||``;(e||t.name)&&p({role:`system`,text:e?`${t.name}: ${e}`:t.name,timestamp:new Date().toISOString(),startupTodos:t.arguments?.todos})}}catch{}let t=await v();if(e.view===`chat`&&t?.sessionId)yf(`chat`,t.sessionId,{replace:!0});else if(e.view===`codewiki`){let n=e.projectPath||t?.cwd||``;f({currentView:`codewiki`,codewikiProjectPath:n}),n&&yf(`codewiki`,null,{replace:!0,projectPath:n})}await E(),S(),C(),T(),b();try{f({versionInfo:await wd()})}catch{}f({initialLoading:!1}),O()})();let e=async()=>{let e=_f();if(f({currentView:e.view,codewikiProjectPath:e.view===`codewiki`?e.projectPath||``:r.current.codewikiProjectPath}),e.sessionId)try{(await Ed()).sessionId!==e.sessionId&&(f({messagesLoading:!0}),n(e=>({...e,messages:[]})),await Id(e.sessionId),await v(),await E(),C(),b())}catch{f({messagesLoading:!1})}else if(e.view===`codewiki`){e.projectPath&&await w(e.projectPath);let t=await v();f({currentView:`codewiki`,codewikiProjectPath:e.projectPath||t?.cwd||``}),C(),b()}};return window.addEventListener(`popstate`,e),()=>{l.current&&l.current.close(),clearTimeout(u.current);for(let e of c.current.values())clearTimeout(e);c.current.clear(),window.removeEventListener(`popstate`,e)}},[p,O,y,b,S,E,C,T,v,w,f]);let ee={state:t,actions:{submit:async(e,t={})=>{if(!e.trim())return;r.current.currentView!==`chat`&&!t.stayInView&&f({currentView:`chat`});let i=!!r.current.pendingPlanApproval&&Hf(e);i&&(o.current=!0),i||p({role:`you`,text:e,timestamp:new Date().toISOString()});let a=i?null:p({role:`system`,text:B(`waitingResponse`),timestamp:new Date().toISOString(),transientKey:`waiting-response`});f({busy:!0,live:!0,stage:`thinking`,stageLabel:B(`waitingResponse`)});try{let n=await(await Md(e,{readOnlyCodeWiki:t.readOnlyCodeWiki===!0})).json().catch(()=>({}));if(n?.code===`CONFIG_REQUIRED`)throw f({configOpen:!0,configStatus:n.configStatus||r.current.configStatus}),Error(B(`configRequired`));if(n?.error)throw Error(n.message||`Request failed`)}catch(e){i&&(o.current=!1),a&&n(e=>({...e,messages:e.messages.filter(e=>e.id!==a)})),p({role:`error`,text:`Failed: ${e.message}`,timestamp:new Date().toISOString()}),f({busy:!1,live:!1})}},abort:async()=>{try{await Nd()}catch{}},approve:async(e,t)=>{f({approvalRequest:null});try{await Fd(e,t)}catch{}},approvePlan:async(e,t)=>{if(r.current.pendingPlanApproval){o.current=e===`approve`,e===`reject`&&f({pendingPlanApproval:null}),f({busy:!0,live:!0,stage:`thinking`,stageLabel:B(`waitingResponse`)});try{let n=e===`approve`?`/yes`:e===`reject`?`/reject`:t?.trim()?`/edit ${t.trim()}`:``;if(!n){f({busy:!1,live:!1,stage:`idle`,stageLabel:``});return}let r=await(await Md(n)).json().catch(()=>({}));if(r?.error)throw Error(r.message||`Request failed`)}catch(e){o.current=!1,p({role:`error`,text:`Failed: ${e.message}`,timestamp:new Date().toISOString()}),f({busy:!1,live:!1,stage:`idle`,stageLabel:``})}}},approveReflect:async(e,t)=>{let n=r.current.pendingReflectApproval;if(n){h({key:`reflect`,status:`running`,emoji:e===`approve`?`💾`:e===`reject`?`🗑️`:`📝`,label:B(e===`approve`?`runtimeActivityReflectSaving`:e===`reject`?`runtimeActivityReflectDiscarding`:`runtimeActivityReflectRevising`),detail:n.name?`/${n.name}`:``}),e===`reject`&&f({pendingReflectApproval:null}),f({busy:!0,live:!0,stage:`thinking`,stageLabel:B(`waitingResponse`)});try{let n=e===`approve`?`/yes`:e===`reject`?`/no`:t?.trim()?`/edit ${t.trim()}`:``;if(!n){f({busy:!1,live:!1,stage:`idle`,stageLabel:``});return}let r=await(await Md(n)).json().catch(()=>({}));if(r?.error)throw Error(r.message||`Request failed`)}catch(e){p({role:`error`,text:`Failed: ${e.message}`,timestamp:new Date().toISOString()}),f({busy:!1,live:!1,stage:`idle`,stageLabel:``})}}},switchSession:async e=>{let t=r.current.runtimeState?.sessionId;if(!(!e||e===t)){f({currentView:`chat`,messagesLoading:!0}),n(e=>({...e,messages:[]}));try{(await Id(e)).ok?(yf(`chat`,e),await v(),await E(),C(),b()):f({messagesLoading:!1})}catch{f({messagesLoading:!1})}}},deleteSession:async e=>{try{let t=e===r.current.runtimeState?.sessionId,i=await Ld(e);return i?.error?i:(n(t=>({...t,sessions:t.sessions.filter(t=>t.id!==e)})),t&&(f({currentView:`chat`,messagesLoading:!0}),i.sessionId&&yf(`chat`,i.sessionId,{replace:!0}),await v(),n(e=>({...e,messages:[]})),await E(),b()),await C(),i)}catch(e){return{error:!0,message:e.message}}},newSession:async()=>{f({currentView:`chat`,messagesLoading:!0}),n(e=>({...e,messages:[]}));try{let e=await Rd();e.ok?(e.sessionId&&yf(`chat`,e.sessionId),await v(),C(),f({messagesLoading:!1})):f({messagesLoading:!1})}catch{f({messagesLoading:!1})}},openProject:async(e,t={})=>{let i=t.view||`chat`,a=i===`codewiki`?e:r.current.codewikiProjectPath;f({currentView:i,projectOpen:!1,messagesLoading:i===`chat`,codewikiProjectPath:a}),i===`chat`&&n(e=>({...e,messages:[]}));try{let t=await Kd(e);if(t.ok){let n=i===`codewiki`?t.cwd||e:r.current.codewikiProjectPath;f({currentView:i,projectOpen:!1,codewikiProjectPath:n}),i===`codewiki`?yf(`codewiki`,null,{projectPath:n}):t.sessionId&&yf(`chat`,t.sessionId),await v(),C(),b(),i===`chat`&&f({messagesLoading:!1})}else i===`chat`&&f({messagesLoading:!1})}catch{i===`chat`&&f({messagesLoading:!1})}},switchView:(e,t={})=>{let n=e===`codewiki`?t.projectPath||r.current.codewikiProjectPath||r.current.runtimeState?.cwd||``:r.current.codewikiProjectPath;if(f({currentView:e,codewikiProjectPath:n}),e===`codewiki`&&yf(e,null,{projectPath:n}),e===`chat`){let e=r.current.runtimeState;yf(`chat`,e?.sessionId)}},toggleTheme:()=>{let e={light:`dark`,dark:`auto`,auto:`light`}[localStorage.getItem(`codemini-theme`)||`auto`]||`auto`;appActions.setTheme(e)},setTheme:e=>{localStorage.setItem(`codemini-theme`,e);let t=window.matchMedia&&window.matchMedia(`(prefers-color-scheme: dark)`),n=e===`auto`?t&&t.matches?`dark`:`light`:e;document.documentElement.dataset.theme=n},setConfigOpen:e=>f({configOpen:e}),refreshConfigStatus:()=>y(),setProjectOpen:e=>f({projectOpen:e}),setSkillsOpen:e=>f({skillsOpen:e}),setSoulsOpen:e=>f({soulsOpen:e}),setAboutOpen:e=>f({aboutOpen:e}),setGitDiffOpen:e=>f({gitDiffOpen:e}),checkVersion:async()=>{try{f({versionInfo:await wd()})}catch{}},runUpdate:async()=>{f({updateStatus:`updating`});try{(await Td()).ok?f({updateStatus:`done`}):f({updateStatus:`error`})}catch{f({updateStatus:`error`})}}}};return(0,_.jsx)(hf.Provider,{value:ee,children:e})}function Yf(){let e=(0,d.useContext)(hf);if(!e)throw Error(`useApp must be used within AppProvider`);return e}var Xf=(...e)=>e.filter((e,t,n)=>!!e&&e.trim()!==``&&n.indexOf(e)===t).join(` `).trim(),Zf=e=>e.replace(/([a-z0-9])([A-Z])/g,`$1-$2`).toLowerCase(),Qf=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,n)=>n?n.toUpperCase():t.toLowerCase()),$f=e=>{let t=Qf(e);return t.charAt(0).toUpperCase()+t.slice(1)},ep={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`},tp=e=>{for(let t in e)if(t.startsWith(`aria-`)||t===`role`||t===`title`)return!0;return!1},np=(0,d.createContext)({}),rp=()=>(0,d.useContext)(np),ip=(0,d.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:f=!1,color:p=`currentColor`,className:m=``}=rp()??{},h=r??f?Number(n??u)*24/Number(t??l):n??u;return(0,d.createElement)(`svg`,{ref:c,...ep,width:t??l??ep.width,height:t??l??ep.height,stroke:e??p,strokeWidth:h,className:Xf(`lucide`,m,i),...!a&&!tp(s)&&{"aria-hidden":`true`},...s},[...o.map(([e,t])=>(0,d.createElement)(e,t)),...Array.isArray(a)?a:[a]])}),H=(e,t)=>{let n=(0,d.forwardRef)(({className:n,...r},i)=>(0,d.createElement)(ip,{ref:i,iconNode:t,className:Xf(`lucide-${Zf($f(e))}`,`lucide-${e}`,n),...r}));return n.displayName=$f(e),n},ap=H(`archive`,[[`rect`,{width:`20`,height:`5`,x:`2`,y:`3`,rx:`1`,key:`1wp1u1`}],[`path`,{d:`M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8`,key:`1s80jp`}],[`path`,{d:`M10 12h4`,key:`a56b0p`}]]),op=H(`arrow-down`,[[`path`,{d:`M12 5v14`,key:`s699le`}],[`path`,{d:`m19 12-7 7-7-7`,key:`1idqje`}]]),sp=H(`arrow-up`,[[`path`,{d:`m5 12 7-7 7 7`,key:`hav0vg`}],[`path`,{d:`M12 19V5`,key:`x0mq9r`}]]),cp=H(`book-open-text`,[[`path`,{d:`M12 7v14`,key:`1akyts`}],[`path`,{d:`M16 12h2`,key:`7q9ll5`}],[`path`,{d:`M16 8h2`,key:`msurwy`}],[`path`,{d:`M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z`,key:`ruj8y`}],[`path`,{d:`M6 12h2`,key:`32wvfc`}],[`path`,{d:`M6 8h2`,key:`30oboj`}]]),lp=H(`brain-circuit`,[[`path`,{d:`M12 5a3 3 0 1 0-5.997.125 4 4 0 0 0-2.526 5.77 4 4 0 0 0 .556 6.588A4 4 0 1 0 12 18Z`,key:`l5xja`}],[`path`,{d:`M9 13a4.5 4.5 0 0 0 3-4`,key:`10igwf`}],[`path`,{d:`M6.003 5.125A3 3 0 0 0 6.401 6.5`,key:`105sqy`}],[`path`,{d:`M3.477 10.896a4 4 0 0 1 .585-.396`,key:`ql3yin`}],[`path`,{d:`M6 18a4 4 0 0 1-1.967-.516`,key:`2e4loj`}],[`path`,{d:`M12 13h4`,key:`1ku699`}],[`path`,{d:`M12 18h6a2 2 0 0 1 2 2v1`,key:`105ag5`}],[`path`,{d:`M12 8h8`,key:`1lhi5i`}],[`path`,{d:`M16 8V5a2 2 0 0 1 2-2`,key:`u6izg6`}],[`circle`,{cx:`16`,cy:`13`,r:`.5`,key:`ry7gng`}],[`circle`,{cx:`18`,cy:`3`,r:`.5`,key:`1aiba7`}],[`circle`,{cx:`20`,cy:`21`,r:`.5`,key:`yhc1fs`}],[`circle`,{cx:`20`,cy:`8`,r:`.5`,key:`1e43v0`}]]),up=H(`brain`,[[`path`,{d:`M12 18V5`,key:`adv99a`}],[`path`,{d:`M15 13a4.17 4.17 0 0 1-3-4 4.17 4.17 0 0 1-3 4`,key:`1e3is1`}],[`path`,{d:`M17.598 6.5A3 3 0 1 0 12 5a3 3 0 1 0-5.598 1.5`,key:`1gqd8o`}],[`path`,{d:`M17.997 5.125a4 4 0 0 1 2.526 5.77`,key:`iwvgf7`}],[`path`,{d:`M18 18a4 4 0 0 0 2-7.464`,key:`efp6ie`}],[`path`,{d:`M19.967 17.483A4 4 0 1 1 12 18a4 4 0 1 1-7.967-.517`,key:`1gq6am`}],[`path`,{d:`M6 18a4 4 0 0 1-2-7.464`,key:`k1g0md`}],[`path`,{d:`M6.003 5.125a4 4 0 0 0-2.526 5.77`,key:`q97ue3`}]]),dp=H(`camera`,[[`path`,{d:`M13.997 4a2 2 0 0 1 1.76 1.05l.486.9A2 2 0 0 0 18.003 7H20a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V9a2 2 0 0 1 2-2h1.997a2 2 0 0 0 1.759-1.048l.489-.904A2 2 0 0 1 10.004 4z`,key:`18u6gg`}],[`circle`,{cx:`12`,cy:`13`,r:`3`,key:`1vg3eu`}]]),fp=H(`chart-no-axes-combined`,[[`path`,{d:`M12 16v5`,key:`zza2cw`}],[`path`,{d:`M16 14v7`,key:`1g90b9`}],[`path`,{d:`M20 10v11`,key:`1iqoj0`}],[`path`,{d:`m22 3-8.646 8.646a.5.5 0 0 1-.708 0L9.354 8.354a.5.5 0 0 0-.707 0L2 15`,key:`1fw8x9`}],[`path`,{d:`M4 18v3`,key:`1yp0dc`}],[`path`,{d:`M8 14v7`,key:`n3cwzv`}]]),pp=H(`check`,[[`path`,{d:`M20 6 9 17l-5-5`,key:`1gmf2c`}]]),mp=H(`chevron-down`,[[`path`,{d:`m6 9 6 6 6-6`,key:`qrunsl`}]]),hp=H(`chevron-right`,[[`path`,{d:`m9 18 6-6-6-6`,key:`mthhwq`}]]),gp=H(`circle-alert`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`line`,{x1:`12`,x2:`12`,y1:`8`,y2:`12`,key:`1pkeuh`}],[`line`,{x1:`12`,x2:`12.01`,y1:`16`,y2:`16`,key:`4dfq90`}]]),_p=H(`circle-check`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`m9 12 2 2 4-4`,key:`dzmm74`}]]),vp=H(`circle-question-mark`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3`,key:`1u773s`}],[`path`,{d:`M12 17h.01`,key:`p32p05`}]]),yp=H(`circle-x`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`m15 9-6 6`,key:`1uzhvr`}],[`path`,{d:`m9 9 6 6`,key:`z0biqf`}]]),bp=H(`copy`,[[`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,key:`17jyea`}],[`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,key:`zix9uf`}]]),xp=H(`database`,[[`ellipse`,{cx:`12`,cy:`5`,rx:`9`,ry:`3`,key:`msslwz`}],[`path`,{d:`M3 5V19A9 3 0 0 0 21 19V5`,key:`1wlel7`}],[`path`,{d:`M3 12A9 3 0 0 0 21 12`,key:`mv7ke4`}]]),Sp=H(`download`,[[`path`,{d:`M12 15V3`,key:`m9g1x1`}],[`path`,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,key:`ih7n3h`}],[`path`,{d:`m7 10 5 5 5-5`,key:`brsn70`}]]),Cp=H(`drama`,[[`path`,{d:`M10 11h.01`,key:`d2at3l`}],[`path`,{d:`M14 6h.01`,key:`k028ub`}],[`path`,{d:`M18 6h.01`,key:`1v4wsw`}],[`path`,{d:`M6.5 13.1h.01`,key:`1748ia`}],[`path`,{d:`M22 5c0 9-4 12-6 12s-6-3-6-12c0-2 2-3 6-3s6 1 6 3`,key:`172yzv`}],[`path`,{d:`M17.4 9.9c-.8.8-2 .8-2.8 0`,key:`1obv0w`}],[`path`,{d:`M10.1 7.1C9 7.2 7.7 7.7 6 8.6c-3.5 2-4.7 3.9-3.7 5.6 4.5 7.8 9.5 8.4 11.2 7.4.9-.5 1.9-2.1 1.9-4.7`,key:`rqjl8i`}],[`path`,{d:`M9.1 16.5c.3-1.1 1.4-1.7 2.4-1.4`,key:`1mr6wy`}]]),wp=H(`ellipsis`,[[`circle`,{cx:`12`,cy:`12`,r:`1`,key:`41hilf`}],[`circle`,{cx:`19`,cy:`12`,r:`1`,key:`1wjl8i`}],[`circle`,{cx:`5`,cy:`12`,r:`1`,key:`1pcz8c`}]]),Tp=H(`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`}]]),Ep=H(`file-code-corner`,[[`path`,{d:`M4 12.15V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.706.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2h-3.35`,key:`1wthlu`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`m5 16-3 3 3 3`,key:`331omg`}],[`path`,{d:`m9 22 3-3-3-3`,key:`lsp7cz`}]]),Dp=H(`file-pen-line`,[[`path`,{d:`M14.364 13.634a2 2 0 0 0-.506.854l-.837 2.87a.5.5 0 0 0 .62.62l2.87-.837a2 2 0 0 0 .854-.506l4.013-4.009a1 1 0 0 0-3.004-3.004z`,key:`ukzhwg`}],[`path`,{d:`M14.487 7.858A1 1 0 0 1 14 7V2`,key:`1klhew`}],[`path`,{d:`M20 19.645V20a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l2.516 2.516`,key:`rxaxab`}],[`path`,{d:`M8 18h1`,key:`13wk12`}]]),Op=H(`file-text`,[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`M10 9H8`,key:`b1mrlr`}],[`path`,{d:`M16 13H8`,key:`t4e002`}],[`path`,{d:`M16 17H8`,key:`z1uh3a`}]]),kp=H(`folder`,[[`path`,{d:`M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z`,key:`1kt360`}]]),Ap=H(`git-branch`,[[`path`,{d:`M15 6a9 9 0 0 0-9 9V3`,key:`1cii5b`}],[`circle`,{cx:`18`,cy:`6`,r:`3`,key:`1h7g24`}],[`circle`,{cx:`6`,cy:`18`,r:`3`,key:`fqmcym`}]]),jp=H(`git-compare`,[[`circle`,{cx:`18`,cy:`18`,r:`3`,key:`1xkwt0`}],[`circle`,{cx:`6`,cy:`6`,r:`3`,key:`1lh9wr`}],[`path`,{d:`M13 6h3a2 2 0 0 1 2 2v7`,key:`1yeb86`}],[`path`,{d:`M11 18H8a2 2 0 0 1-2-2V9`,key:`19pyzm`}]]),Mp=H(`globe`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20`,key:`13o1zl`}],[`path`,{d:`M2 12h20`,key:`9i4pu4`}]]),Np=H(`grip-vertical`,[[`circle`,{cx:`9`,cy:`12`,r:`1`,key:`1vctgf`}],[`circle`,{cx:`9`,cy:`5`,r:`1`,key:`hp0tcf`}],[`circle`,{cx:`9`,cy:`19`,r:`1`,key:`fkjjf6`}],[`circle`,{cx:`15`,cy:`12`,r:`1`,key:`1tmaij`}],[`circle`,{cx:`15`,cy:`5`,r:`1`,key:`19l28e`}],[`circle`,{cx:`15`,cy:`19`,r:`1`,key:`f4zoj3`}]]),Pp=H(`hammer`,[[`path`,{d:`m15 12-9.373 9.373a1 1 0 0 1-3.001-3L12 9`,key:`1hayfq`}],[`path`,{d:`m18 15 4-4`,key:`16gjal`}],[`path`,{d:`m21.5 11.5-1.914-1.914A2 2 0 0 1 19 8.172v-.344a2 2 0 0 0-.586-1.414l-1.657-1.657A6 6 0 0 0 12.516 3H9l1.243 1.243A6 6 0 0 1 12 8.485V10l2 2h1.172a2 2 0 0 1 1.414.586L18.5 14.5`,key:`15ts47`}]]),Fp=H(`inbox`,[[`polyline`,{points:`22 12 16 12 14 15 10 15 8 12 2 12`,key:`o97t9d`}],[`path`,{d:`M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z`,key:`oot6mr`}]]),Ip=H(`info`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 16v-4`,key:`1dtifu`}],[`path`,{d:`M12 8h.01`,key:`e9boi3`}]]),Lp=H(`list-checks`,[[`path`,{d:`M13 5h8`,key:`a7qcls`}],[`path`,{d:`M13 12h8`,key:`h98zly`}],[`path`,{d:`M13 19h8`,key:`c3s6r1`}],[`path`,{d:`m3 17 2 2 4-4`,key:`1jhpwq`}],[`path`,{d:`m3 7 2 2 4-4`,key:`1obspn`}]]),Rp=H(`loader-circle`,[[`path`,{d:`M21 12a9 9 0 1 1-6.219-8.56`,key:`13zald`}]]),zp=H(`message-circle`,[[`path`,{d:`M2.992 16.342a2 2 0 0 1 .094 1.167l-1.065 3.29a1 1 0 0 0 1.236 1.168l3.413-.998a2 2 0 0 1 1.099.092 10 10 0 1 0-4.777-4.719`,key:`1sd12s`}]]),Bp=H(`message-square-text`,[[`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:`M7 11h10`,key:`1twpyw`}],[`path`,{d:`M7 15h6`,key:`d9of3u`}],[`path`,{d:`M7 7h8`,key:`af5zfr`}]]),Vp=H(`minus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}]]),Hp=H(`monitor`,[[`rect`,{width:`20`,height:`14`,x:`2`,y:`3`,rx:`2`,key:`48i651`}],[`line`,{x1:`8`,x2:`16`,y1:`21`,y2:`21`,key:`1svkeh`}],[`line`,{x1:`12`,x2:`12`,y1:`17`,y2:`21`,key:`vw1qmm`}]]),Up=H(`moon`,[[`path`,{d:`M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401`,key:`kfwtm`}]]),Wp=H(`palette`,[[`path`,{d:`M12 22a1 1 0 0 1 0-20 10 9 0 0 1 10 9 5 5 0 0 1-5 5h-2.25a1.75 1.75 0 0 0-1.4 2.8l.3.4a1.75 1.75 0 0 1-1.4 2.8z`,key:`e79jfc`}],[`circle`,{cx:`13.5`,cy:`6.5`,r:`.5`,fill:`currentColor`,key:`1okk4w`}],[`circle`,{cx:`17.5`,cy:`10.5`,r:`.5`,fill:`currentColor`,key:`f64h9f`}],[`circle`,{cx:`6.5`,cy:`12.5`,r:`.5`,fill:`currentColor`,key:`qy21gx`}],[`circle`,{cx:`8.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`fotxhn`}]]),Gp=H(`paperclip`,[[`path`,{d:`m16 6-8.414 8.586a2 2 0 0 0 2.829 2.829l8.414-8.586a4 4 0 1 0-5.657-5.657l-8.379 8.551a6 6 0 1 0 8.485 8.485l8.379-8.551`,key:`1miecu`}]]),Kp=H(`pencil`,[[`path`,{d:`M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z`,key:`1a8usu`}],[`path`,{d:`m15 5 4 4`,key:`1mk7zo`}]]),qp=H(`plus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`M12 5v14`,key:`s699le`}]]),Jp=H(`plug`,[[`path`,{d:`M12 22v-5`,key:`1ega77`}],[`path`,{d:`M15 8V2`,key:`18g5xt`}],[`path`,{d:`M17 8a1 1 0 0 1 1 1v4a4 4 0 0 1-4 4h-4a4 4 0 0 1-4-4V9a1 1 0 0 1 1-1z`,key:`1xoxul`}],[`path`,{d:`M9 8V2`,key:`14iosj`}]]),Yp=H(`refresh-cw`,[[`path`,{d:`M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8`,key:`v9h5vc`}],[`path`,{d:`M21 3v5h-5`,key:`1q7to0`}],[`path`,{d:`M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16`,key:`3uifl3`}],[`path`,{d:`M8 16H3v5`,key:`1cv678`}]]),Xp=H(`rotate-ccw`,[[`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`}]]),Zp=H(`search`,[[`path`,{d:`m21 21-4.34-4.34`,key:`14j7rj`}],[`circle`,{cx:`11`,cy:`11`,r:`8`,key:`4ej97u`}]]),Qp=H(`send-horizontal`,[[`path`,{d:`M3.714 3.048a.498.498 0 0 0-.683.627l2.843 7.627a2 2 0 0 1 0 1.396l-2.842 7.627a.498.498 0 0 0 .682.627l18-8.5a.5.5 0 0 0 0-.904z`,key:`117uat`}],[`path`,{d:`M6 12h16`,key:`s4cdu5`}]]),$p=H(`settings-2`,[[`path`,{d:`M14 17H5`,key:`gfn3mx`}],[`path`,{d:`M19 7h-9`,key:`6i9tg`}],[`circle`,{cx:`17`,cy:`17`,r:`3`,key:`18b49y`}],[`circle`,{cx:`7`,cy:`7`,r:`3`,key:`dfmy0x`}]]),em=H(`settings`,[[`path`,{d:`M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915`,key:`1i5ecw`}],[`circle`,{cx:`12`,cy:`12`,r:`3`,key:`1v7zrd`}]]),tm=H(`sliders-horizontal`,[[`path`,{d:`M10 5H3`,key:`1qgfaw`}],[`path`,{d:`M12 19H3`,key:`yhmn1j`}],[`path`,{d:`M14 3v4`,key:`1sua03`}],[`path`,{d:`M16 17v4`,key:`1q0r14`}],[`path`,{d:`M21 12h-9`,key:`1o4lsq`}],[`path`,{d:`M21 19h-5`,key:`1rlt1p`}],[`path`,{d:`M21 5h-7`,key:`1oszz2`}],[`path`,{d:`M8 10v4`,key:`tgpxqk`}],[`path`,{d:`M8 12H3`,key:`a7s4jb`}]]),nm=H(`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`}]]),rm=H(`sun`,[[`circle`,{cx:`12`,cy:`12`,r:`4`,key:`4exip2`}],[`path`,{d:`M12 2v2`,key:`tus03m`}],[`path`,{d:`M12 20v2`,key:`1lh1kg`}],[`path`,{d:`m4.93 4.93 1.41 1.41`,key:`149t6j`}],[`path`,{d:`m17.66 17.66 1.41 1.41`,key:`ptbguv`}],[`path`,{d:`M2 12h2`,key:`1t8f8n`}],[`path`,{d:`M20 12h2`,key:`1q8mjw`}],[`path`,{d:`m6.34 17.66-1.41 1.41`,key:`1m8zz5`}],[`path`,{d:`m19.07 4.93-1.41 1.41`,key:`1shlcs`}]]),im=H(`terminal`,[[`path`,{d:`M12 19h8`,key:`baeox8`}],[`path`,{d:`m4 17 6-6-6-6`,key:`1yngyt`}]]),am=H(`trash-2`,[[`path`,{d:`M10 11v6`,key:`nco0om`}],[`path`,{d:`M14 11v6`,key:`outv1u`}],[`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`}]]),om=H(`workflow`,[[`rect`,{width:`8`,height:`8`,x:`3`,y:`3`,rx:`2`,key:`by2w9f`}],[`path`,{d:`M7 11v4a2 2 0 0 0 2 2h4`,key:`xkn7yn`}],[`rect`,{width:`8`,height:`8`,x:`13`,y:`13`,rx:`2`,key:`1cgmvn`}]]),sm=H(`wrench`,[[`path`,{d:`M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z`,key:`1ngwbx`}]]),cm=H(`x`,[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]);function lm({className:e,orientation:t=`horizontal`,decorative:n=!0,...r}){return(0,_.jsx)(el,{"data-slot":`separator`,decorative:n,orientation:t,className:z(`shrink-0 bg-border data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px`,e),...r})}function um({...e}){return(0,_.jsx)(_o,{"data-slot":`popover`,...e})}function dm({...e}){return(0,_.jsx)(vo,{"data-slot":`popover-trigger`,...e})}function fm({className:e,align:t=`center`,sideOffset:n=4,...r}){return(0,_.jsx)(yo,{children:(0,_.jsx)(bo,{"data-slot":`popover-content`,align:t,sideOffset:n,className:z(`z-50 w-72 origin-(--radix-popover-content-transform-origin) rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-hidden data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95`,e),...r})})}var pm=e=>typeof e==`boolean`?`${e}`:e===0?`0`:e,mm=Ul,hm=(e,t)=>n=>{if(t?.variants==null)return mm(e,n?.class,n?.className);let{variants:r,defaultVariants:i}=t,a=Object.keys(r).map(e=>{let t=n?.[e],a=i?.[e];if(t===null)return null;let o=pm(t)||pm(a);return r[e][o]}),o=n&&Object.entries(n).reduce((e,t)=>{let[n,r]=t;return r===void 0||(e[n]=r),e},{});return mm(e,a,t?.compoundVariants?.reduce((e,t)=>{let{class:n,className:r,...a}=t;return Object.entries(a).every(e=>{let[t,n]=e;return Array.isArray(n)?n.includes({...i,...o}[t]):{...i,...o}[t]===n})?[...e,n,r]:e},[]),n?.class,n?.className)},gm=hm(`inline-flex shrink-0 items-center justify-center gap-2 rounded-md text-sm font-medium whitespace-nowrap transition-all outline-none cursor-pointer disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,{variants:{variant:{default:`bg-primary text-primary-foreground shadow-xs hover:bg-primary/90`,destructive:`bg-destructive text-destructive-foreground shadow-xs hover:bg-destructive/90`,outline:`border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground`,secondary:`bg-secondary text-secondary-foreground shadow-xs hover:bg-secondary/80`,ghost:`hover:bg-accent hover:text-accent-foreground`,link:`text-primary underline-offset-4 hover:underline`},size:{default:`h-8 px-3.5 py-1.5 text-[13px] has-[>svg]:px-2.5`,xs:`h-6 gap-1 rounded-md px-2 text-xs has-[>svg]:px-1.5 [&_svg:not([class*='size-'])]:size-3`,sm:`h-7 gap-1.5 rounded-md px-3 text-[13px] has-[>svg]:px-2`,lg:`h-10 rounded-md px-6 has-[>svg]:px-4`,icon:`size-8`,"icon-xs":`size-6 rounded-md [&_svg:not([class*='size-'])]:size-3`,"icon-sm":`size-7`,"icon-lg":`size-10`}},defaultVariants:{variant:`default`,size:`default`}});function _m({className:e,variant:t=`default`,size:n=`default`,asChild:r=!1,...i}){return(0,_.jsx)(r?y:`button`,{"data-slot":`button`,"data-variant":t,"data-size":n,className:z(gm({variant:t,size:n,className:e})),...i})}function vm({...e}){return(0,_.jsx)(Zn,{"data-slot":`dialog`,...e})}function ym({...e}){return(0,_.jsx)(Qn,{"data-slot":`dialog-portal`,...e})}function bm({className:e,...t}){return(0,_.jsx)($n,{"data-slot":`dialog-overlay`,className:z(`fixed inset-0 z-50 bg-black/40 backdrop-blur-[2px] data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:animate-in data-[state=open]:fade-in-0`,e),...t})}function xm({className:e,children:t,...n}){return(0,_.jsxs)(ym,{"data-slot":`dialog-portal`,children:[(0,_.jsx)(bm,{}),(0,_.jsx)(er,{"data-slot":`dialog-content`,className:z(`fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-xl border border-(--border-default) bg-(--bg-primary) text-(--text-primary) p-6 shadow-lg duration-200 outline-none data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 sm:max-w-lg`,e),...n,children:t})]})}function Sm({className:e,showCloseButton:t=!0,children:n,...r}){return(0,_.jsxs)(`div`,{"data-slot":`dialog-header`,className:z(`flex flex-row items-center justify-between gap-2 text-center sm:text-left`,e),...r,children:[(0,_.jsx)(`div`,{className:`flex-1 min-w-0`,children:n}),t&&(0,_.jsxs)(rr,{"data-slot":`dialog-close`,className:`shrink-0 rounded-xs opacity-70 text-(--text-muted) transition-opacity hover:opacity-100 hover:text-(--text-primary) focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,children:[(0,_.jsx)(cm,{}),(0,_.jsx)(`span`,{className:`sr-only`,children:`Close`})]})]})}function Cm({className:e,showCloseButton:t=!1,children:n,...r}){return(0,_.jsxs)(`div`,{"data-slot":`dialog-footer`,className:z(`flex flex-col-reverse gap-2 sm:flex-row sm:justify-end`,e),...r,children:[n,t&&(0,_.jsx)(rr,{asChild:!0,children:(0,_.jsx)(_m,{variant:`outline`,children:`Close`})})]})}function wm({className:e,...t}){return(0,_.jsx)(tr,{"data-slot":`dialog-title`,className:z(`text-base font-semibold text-(--text-primary)`,e),...t})}function Tm({className:e,...t}){return(0,_.jsx)(nr,{"data-slot":`dialog-description`,className:z(`text-sm text-(--text-secondary)`,e),...t})}function Em({open:e,title:t,description:n,confirmLabel:r,cancelLabel:i,loading:a=!1,onOpenChange:o,onConfirm:s}){return(0,_.jsx)(vm,{open:e,onOpenChange:e=>!a&&o?.(e),children:(0,_.jsxs)(xm,{className:`sm:max-w-[380px]`,children:[(0,_.jsxs)(Sm,{showCloseButton:!a,children:[(0,_.jsx)(wm,{children:t}),(0,_.jsx)(Tm,{className:`leading-6`,children:n})]}),(0,_.jsxs)(Cm,{children:[(0,_.jsx)(_m,{type:`button`,variant:`outline`,disabled:a,onClick:()=>o?.(!1),children:i||B(`cancel`)}),(0,_.jsx)(_m,{type:`button`,variant:`destructive`,disabled:a,onClick:s,children:a?B(`deleting`):r||B(`delete`)})]})]})})}function Dm({className:e}){return(0,_.jsxs)(`span`,{role:`status`,className:z(`loading-dots text-(--text-muted)`,e),children:[(0,_.jsx)(`span`,{}),(0,_.jsx)(`span`,{}),(0,_.jsx)(`span`,{})]})}var Om=`__codemini_general__`;function km(e){return e?.projectDir||`unknown`}function Am(e,t){return t?B(`generalChat`):!e||e===`unknown`?B(`unknownProject`):String(e).split(/[/\\]/).filter(Boolean).pop()||e}function jm({size:e=14,className:t,...n}){return(0,_.jsx)(`svg`,{viewBox:`0 0 24 24`,width:e,height:e,fill:`currentColor`,"aria-hidden":`true`,className:t,...n,children:(0,_.jsx)(`path`,{d:`M12 .5C5.65.5.5 5.65.5 12c0 5.09 3.29 9.4 7.86 10.93.58.1.79-.25.79-.56v-2.18c-3.2.69-3.87-1.36-3.87-1.36-.52-1.33-1.28-1.68-1.28-1.68-1.05-.72.08-.7.08-.7 1.16.08 1.77 1.19 1.77 1.19 1.03 1.76 2.7 1.25 3.36.96.1-.75.4-1.25.73-1.54-2.55-.29-5.23-1.27-5.23-5.67 0-1.25.45-2.27 1.18-3.07-.12-.29-.51-1.46.11-3.03 0 0 .97-.31 3.16 1.17A10.98 10.98 0 0 1 12 6.07c.98 0 1.96.13 2.88.39 2.19-1.48 3.15-1.17 3.15-1.17.63 1.57.24 2.74.12 3.03.74.8 1.18 1.82 1.18 3.07 0 4.41-2.69 5.38-5.25 5.66.42.36.78 1.06.78 2.14v3.18c0 .31.21.67.8.56A11.51 11.51 0 0 0 23.5 12C23.5 5.65 18.35.5 12 .5Z`})})}function Mm(e){return e?.title||e?.preview||(e?.messageCount>0?`${e.messageCount} ${B(`messages`)}`:B(`emptyChat`))}function Nm(e){let t=Date.parse(e||``);if(!Number.isFinite(t))return``;let n=Date.now()-t;if(n<6e4)return B(`justNow`);let r=Math.floor(n/6e4);if(r<60)return`${r}${B(`minutesAgo`)}`;let i=Math.floor(r/60);if(i<24)return`${i}${B(`hoursAgo`)}`;let a=Math.floor(i/24);return a<30?`${a}${B(`daysAgo`)}`:new Date(t).toLocaleDateString(void 0,{month:`numeric`,day:`numeric`})}var Pm=[{id:`default`,labelKey:`themeDefault`,swatches:[`#0a0a0a`,`#f5f5f5`,`#60a5fa`]},{id:`catppuccin`,labelKey:`themeCatppuccin`,swatches:[`#1e1e2e`,`#cba6f7`,`#89b4fa`]},{id:`tokyonight`,labelKey:`themeTokyoNight`,swatches:[`#1a1b26`,`#7aa2f7`,`#bb9af7`]},{id:`one`,labelKey:`themeOne`,swatches:[`#282c34`,`#61afef`,`#c678dd`]},{id:`github`,labelKey:`themeGithub`,swatches:[`#ffffff`,`#0969da`,`#24292f`]},{id:`vscode`,labelKey:`themeVSCode`,swatches:[`#1e1e1e`,`#007acc`,`#d4d4d4`]}];function Fm({sessions:e,sessionsLoading:t,currentSessionId:n,onNewSession:r,onSwitchSession:i,onToggleTheme:a,onSetTheme:o,onOpenSettings:s,onOpenSkills:c,onOpenSouls:l,onOpenAbout:u,gitBatch:f,versionInfo:p,onUpdate:m,updateStatus:h,currentView:g,onSwitchView:v,onOpenProject:y,onDeleteSession:b}){let[x,S]=(0,d.useState)(new Set),[C,w]=(0,d.useState)(null),[T,E]=(0,d.useState)(!1),[D,O]=(0,d.useState)(()=>typeof document>`u`?`default`:document.documentElement.dataset.palette||`default`),[ee,te]=(0,d.useState)(()=>typeof document>`u`?`light`:document.documentElement.dataset.theme||`light`),[k,A]=(0,d.useState)(()=>typeof window>`u`?`auto`:localStorage.getItem(`codemini-theme`)||`auto`);(0,d.useEffect)(()=>{let e=window.matchMedia&&window.matchMedia(`(prefers-color-scheme: dark)`),t=()=>{te(document.documentElement.dataset.theme||`light`),A(localStorage.getItem(`codemini-theme`)||`auto`)},n=new MutationObserver(t);return n.observe(document.documentElement,{attributes:!0,attributeFilter:[`data-theme`]}),e&&e.addEventListener(`change`,t),()=>{n.disconnect(),e&&e.removeEventListener(`change`,t)}},[]);let j=ee===`dark`,M=Array.isArray(e)?e:[],ne=M.find(e=>e.id===n),N=!!ne?.isGeneral,P=ne?km(ne):null,re=M.filter(e=>e.isGeneral),ie=M.filter(e=>!e.isGeneral),ae=new Map;for(let e of ie){let t=km(e);ae.has(t)||ae.set(t,[]),ae.get(t).push(e)}let oe=e=>{S(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n})},F=e=>{let t=Pm.some(t=>t.id===e)?e:`default`;document.documentElement.dataset.palette=t,localStorage.setItem(`codemini-theme-palette`,t),window.dispatchEvent(new CustomEvent(`codemini-theme-palette-change`,{detail:{palette:t}})),O(t)},I=async(e,t)=>{if(e.stopPropagation(),t&&t!==`unknown`&&t!==P&&y){await y(t,{view:`codewiki`});return}v?.(`codewiki`,{projectPath:t})},se=async(e,t)=>{if(e.stopPropagation(),!(!t||t===`unknown`)){if(t===P){await r?.();return}await y?.(t,{view:`chat`})}},ce=async()=>{if(N){await r?.();return}await y?.(Om,{view:`chat`})};return(0,_.jsxs)(`aside`,{className:`w-[260px] shrink-0 flex flex-col bg-(--bg-secondary)`,children:[(0,_.jsxs)(`div`,{className:`shrink-0 px-2.5 pt-3 flex flex-col gap-0.5`,children:[(0,_.jsxs)(`div`,{className:`mb-2 flex h-10 items-center gap-2.5 px-2`,children:[(0,_.jsx)(`img`,{src:`/logos/codemini_logo.png`,alt:``,className:`size-6 shrink-0 rounded-md`,draggable:!1}),(0,_.jsx)(`div`,{className:`min-w-0 truncate text-[23px] font-semibold leading-6 text-(--text-primary)`,children:B(`brand`)})]}),(0,_.jsxs)(`button`,{className:`w-full border-0 bg-transparent flex items-center gap-2.5 h-[32px] px-2 rounded-lg cursor-pointer text-left text-[13px] hover:bg-(--bg-hover) text-(--text-primary)`,onClick:r,children:[(0,_.jsx)(qp,{size:15,strokeWidth:2,className:`text-(--text-secondary) shrink-0`}),(0,_.jsx)(`span`,{className:`truncate`,children:B(`newChat`)})]}),(0,_.jsxs)(`button`,{className:`w-full border-0 bg-transparent flex items-center gap-2.5 h-[32px] px-2 rounded-lg cursor-pointer text-left text-[13px] hover:bg-(--bg-hover) text-(--text-primary)`,onClick:c,children:[(0,_.jsx)(Pp,{size:15,strokeWidth:2,className:`text-(--text-secondary) shrink-0`}),(0,_.jsx)(`span`,{className:`truncate`,children:B(`skills`)})]}),(0,_.jsxs)(`button`,{className:`w-full border-0 bg-transparent flex items-center gap-2.5 h-[32px] px-2 rounded-lg cursor-pointer text-left text-[13px] hover:bg-(--bg-hover) text-(--text-primary)`,onClick:l,children:[(0,_.jsx)(Cp,{size:15,strokeWidth:2,className:`text-(--text-secondary) shrink-0`}),(0,_.jsx)(`span`,{className:`truncate`,children:B(`souls`)})]}),(0,_.jsx)(lm,{className:`my-2 bg-(--border-default)`})]}),(0,_.jsxs)(`nav`,{className:`shrink-0 max-h-[52vh] flex flex-col px-2.5 pb-1 gap-0.5 overflow-y-auto`,style:{scrollbarWidth:`thin`},children:[Array.from(ae.entries()).map(([e,t])=>{let r=x.has(e)||ae.size===1,a=f?.[e],o=e===P,s=e!==`unknown`;return(0,_.jsxs)(`div`,{children:[(0,_.jsxs)(`div`,{className:z(`w-full border-0 bg-transparent flex items-center gap-1 h-[28px] px-1.5 rounded-md text-left text-[12px] font-medium tracking-[0.2px] hover:bg-(--bg-hover)`,o?`text-(--text-primary)`:`text-(--text-muted) hover:text-(--text-secondary)`),title:e===`unknown`?``:e,children:[(0,_.jsxs)(`button`,{className:`min-w-0 flex-1 border-0 bg-transparent flex items-center gap-2 text-left text-inherit cursor-pointer`,onClick:()=>oe(e),children:[(0,_.jsx)(kp,{size:13,className:`shrink-0`}),(0,_.jsx)(`span`,{className:`truncate flex-1`,children:Am(e)})]}),s&&(0,_.jsx)(`button`,{type:`button`,className:`inline-flex size-6 shrink-0 items-center justify-center rounded-md border-0 bg-transparent text-(--text-muted) cursor-pointer hover:bg-(--bg-active) hover:text-(--text-primary)`,title:B(`newSessionInProject`),"aria-label":`${B(`newSessionInProject`)} ${Am(e)}`,onClick:t=>se(t,e),children:(0,_.jsx)(qp,{size:13,strokeWidth:2.1})}),s&&(0,_.jsx)(`button`,{type:`button`,className:z(`inline-flex size-6 shrink-0 items-center justify-center rounded-md border-0 bg-transparent text-(--text-muted) cursor-pointer hover:bg-(--bg-active) hover:text-(--text-primary)`,g===`codewiki`&&o&&`bg-(--bg-active) text-(--text-primary)`),title:B(`openCodeWiki`),"aria-label":`${B(`openCodeWiki`)} ${Am(e)}`,onClick:t=>I(t,e),children:(0,_.jsx)(cp,{size:13,strokeWidth:1.9})}),a?.isGit&&(0,_.jsx)(jm,{size:11,className:`shrink-0 text-(--text-muted)`}),(0,_.jsx)(`span`,{className:`text-[11px] px-2`,children:t.length}),(0,_.jsx)(`button`,{type:`button`,className:`border-0 bg-transparent inline-flex size-5 shrink-0 items-center justify-center rounded-md text-inherit cursor-pointer hover:bg-(--bg-active)`,onClick:()=>oe(e),"aria-label":B(r?`collapseProject`:`expandProject`),children:(0,_.jsx)(mp,{size:13,className:z(`transition-transform`,!r&&`-rotate-90`)})})]}),r&&(0,_.jsx)(`div`,{className:`flex flex-col gap-1.5 py-1 pl-2`,children:t.slice(0,30).map(e=>(0,_.jsxs)(`div`,{onClick:()=>{e.id===n?g!==`chat`&&v?.(`chat`):i(e.id)},className:z(`group w-full border-0 bg-transparent flex items-center gap-2 h-[30px] px-2 rounded-md cursor-pointer text-left text-[13px] truncate`,e.id===n?`bg-(--bg-active) text-(--text-primary)`:`text-(--text-secondary) hover:bg-(--bg-hover) hover:text-(--text-primary)`),children:[(0,_.jsx)(`span`,{className:`truncate flex-1`,title:Mm(e),children:Mm(e)}),e.updatedAt&&(0,_.jsx)(`span`,{className:`text-[11px] text-(--text-muted) shrink-0 tabular-nums`,children:Nm(e.updatedAt)}),(0,_.jsxs)(um,{children:[(0,_.jsx)(dm,{asChild:!0,children:(0,_.jsx)(`button`,{type:`button`,className:`inline-flex size-6 shrink-0 items-center justify-center rounded-md text-(--text-muted) opacity-0 hover:bg-(--bg-active) hover:text-(--text-primary) group-hover:opacity-100 focus:opacity-100`,onClick:e=>e.stopPropagation(),"aria-label":B(`sessionActions`),children:(0,_.jsx)(wp,{size:14})})}),(0,_.jsx)(fm,{align:`end`,className:`w-36 border-(--border-default) bg-(--bg-primary) p-1 text-(--text-primary)`,onClick:e=>e.stopPropagation(),children:(0,_.jsx)(`button`,{type:`button`,className:`w-full rounded-md px-2.5 py-2 text-left text-[13px] text-(--accent-red) hover:bg-(--accent-red-bg)`,onClick:()=>w(e),children:B(`deleteSession`)})})]})]},e.id))})]},e)}),t&&M.length===0&&(0,_.jsx)(`div`,{className:`px-3 py-4 text-center`,children:(0,_.jsx)(Dm,{className:`justify-center`})}),!t&&ie.length===0&&re.length===0&&(0,_.jsx)(`div`,{className:`px-3 py-4 text-[12px] text-(--text-muted) text-center`,children:B(`noSessions`)})]}),(0,_.jsxs)(`section`,{className:`shrink-0 px-2.5 pb-2`,children:[(0,_.jsx)(lm,{className:`my-2 bg-(--border-default)`}),(0,_.jsxs)(`div`,{className:`flex items-center gap-2 px-1.5 pb-1.5`,children:[(0,_.jsx)(`span`,{className:`min-w-0 flex-1 text-[12px] font-medium text-(--text-muted)`,children:B(`conversations`)}),(0,_.jsx)(`button`,{type:`button`,className:`inline-flex size-7 shrink-0 items-center justify-center rounded-md border-0 bg-transparent text-(--text-muted) cursor-pointer hover:bg-(--bg-hover) hover:text-(--text-primary)`,title:B(`newChat`),"aria-label":B(`newChat`),onClick:ce,children:(0,_.jsx)(qp,{size:14,strokeWidth:1.9})})]}),(0,_.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[re.slice(0,6).map(e=>(0,_.jsxs)(`div`,{onClick:()=>{e.id===n?g!==`chat`&&v?.(`chat`):i(e.id)},className:z(`group flex h-[34px] w-full cursor-pointer items-center gap-2 rounded-lg border-0 px-2 text-left text-[13px]`,e.id===n&&g===`chat`?`bg-(--bg-active) text-(--text-primary)`:`text-(--text-secondary) hover:bg-(--bg-hover) hover:text-(--text-primary)`),children:[(0,_.jsx)(`span`,{className:`min-w-0 flex-1 truncate font-medium`,title:Mm(e),children:Mm(e)}),e.updatedAt&&(0,_.jsx)(`span`,{className:`shrink-0 text-[11px] tabular-nums text-(--text-muted)`,children:Nm(e.updatedAt)}),(0,_.jsxs)(um,{children:[(0,_.jsx)(dm,{asChild:!0,children:(0,_.jsx)(`button`,{type:`button`,className:`inline-flex size-6 shrink-0 items-center justify-center rounded-md text-(--text-muted) opacity-0 hover:bg-(--bg-active) hover:text-(--text-primary) group-hover:opacity-100 focus:opacity-100`,onClick:e=>e.stopPropagation(),"aria-label":B(`sessionActions`),children:(0,_.jsx)(wp,{size:14})})}),(0,_.jsx)(fm,{align:`end`,className:`w-36 border-(--border-default) bg-(--bg-primary) p-1 text-(--text-primary)`,onClick:e=>e.stopPropagation(),children:(0,_.jsx)(`button`,{type:`button`,className:`w-full rounded-md px-2.5 py-2 text-left text-[13px] text-(--accent-red) hover:bg-(--accent-red-bg)`,onClick:()=>w(e),children:B(`deleteSession`)})})]})]},e.id)),!t&&re.length===0&&(0,_.jsx)(`button`,{type:`button`,onClick:ce,className:`h-[34px] rounded-lg border-0 bg-transparent px-2 text-left text-[13px] text-(--text-muted) hover:bg-(--bg-hover) hover:text-(--text-primary)`,children:B(`noConversations`)})]})]}),(0,_.jsxs)(`div`,{className:`mt-auto px-2.5 py-2 flex flex-col gap-0`,children:[(0,_.jsx)(lm,{className:`my-2 bg-(--border-default)`}),p?.latest&&p.latest!==p.current&&(0,_.jsx)(`button`,{className:`w-full border-0 bg-(--bg-tertiary) rounded-md px-2.5 py-1.5 cursor-pointer text-[11px] text-(--text-secondary) hover:bg-(--bg-hover) hover:text-(--text-primary) flex items-center justify-center gap-1.5`,onClick:h===`updating`?void 0:m,disabled:h===`updating`,children:h===`updating`?(0,_.jsx)(_.Fragment,{children:B(`updating`)}):h===`done`?(0,_.jsx)(_.Fragment,{children:B(`updatedRestart`)}):(0,_.jsx)(_.Fragment,{children:B(`updateAvailable`)})}),(0,_.jsxs)(`div`,{className:`flex items-center justify-center gap-1`,children:[(0,_.jsx)(`button`,{className:`border-0 bg-transparent inline-flex items-center justify-center size-8 rounded-lg cursor-pointer hover:bg-(--bg-hover) hover:text-(--text-primary) text-(--text-secondary)`,onClick:u,title:B(`about`),"aria-label":B(`about`),children:(0,_.jsx)(Ip,{size:15,strokeWidth:1.8})}),(0,_.jsx)(`a`,{href:`https://github.com/havingautism/Codemini-CLI`,target:`_blank`,rel:`noreferrer`,className:`border-0 bg-transparent inline-flex items-center justify-center size-8 rounded-lg cursor-pointer hover:bg-(--bg-hover) hover:text-(--text-primary) text-(--text-secondary)`,title:B(`projectRepository`),"aria-label":B(`projectRepository`),children:(0,_.jsx)(jm,{size:15})}),(0,_.jsxs)(um,{children:[(0,_.jsx)(dm,{asChild:!0,children:(0,_.jsx)(`button`,{className:`border-0 bg-transparent inline-flex items-center justify-center size-8 rounded-lg cursor-pointer hover:bg-(--bg-hover) hover:text-(--text-primary) text-(--text-secondary)`,title:B(`switchThemePalette`),"aria-label":B(`switchThemePalette`),children:(0,_.jsx)(Wp,{size:15,strokeWidth:1.8})})}),(0,_.jsx)(fm,{align:`center`,side:`top`,className:`w-44 border-(--border-default) bg-(--bg-primary) p-1 text-(--text-primary)`,children:Pm.map(e=>(0,_.jsxs)(`button`,{type:`button`,className:z(`w-full rounded-md px-2.5 py-2 text-left text-[13px] flex items-center gap-2 hover:bg-(--bg-hover)`,D===e.id&&`text-(--text-primary) font-medium`),onClick:()=>F(e.id),children:[(0,_.jsx)(`span`,{className:`flex shrink-0 -space-x-1`,children:e.swatches.map(e=>(0,_.jsx)(`span`,{className:`size-3 rounded-full border border-(--border-default)`,style:{backgroundColor:e}},e))}),(0,_.jsx)(`span`,{className:`min-w-0 flex-1 truncate`,children:B(e.labelKey)}),D===e.id&&(0,_.jsx)(pp,{size:13})]},e.id))})]}),(0,_.jsxs)(um,{children:[(0,_.jsx)(dm,{asChild:!0,children:(0,_.jsx)(`button`,{className:`border-0 bg-transparent inline-flex items-center justify-center size-8 rounded-lg cursor-pointer hover:bg-(--bg-hover) hover:text-(--text-primary) text-(--text-secondary)`,title:B(`switchLanguage`),"aria-label":B(`switchLanguage`),children:(0,_.jsx)(Mp,{size:15,strokeWidth:1.8})})}),(0,_.jsx)(fm,{align:`center`,side:`top`,className:`w-30 border-(--border-default) bg-(--bg-primary) p-1 text-(--text-primary)`,children:[`zh`,`en`].map(e=>(0,_.jsxs)(`button`,{type:`button`,className:z(`w-full rounded-md px-2.5 py-1.5 text-left text-[13px] flex items-center justify-between hover:bg-(--bg-hover)`,Sd()===e&&`text-(--text-primary) font-medium`),onClick:()=>{Sd()!==e&&(xd(e),window.location.reload())},children:[(0,_.jsx)(`span`,{children:e===`zh`?`中文`:`English`}),Sd()===e&&(0,_.jsx)(pp,{size:13})]},e))})]}),(0,_.jsxs)(um,{children:[(0,_.jsx)(dm,{asChild:!0,children:(0,_.jsx)(`button`,{className:`border-0 bg-transparent inline-flex items-center justify-center size-8 rounded-lg cursor-pointer hover:bg-(--bg-hover) hover:text-(--text-primary) text-(--text-secondary)`,title:B(`switchTheme`),"aria-label":B(`switchTheme`),children:j?(0,_.jsx)(Up,{size:15,strokeWidth:1.8}):(0,_.jsx)(rm,{size:15,strokeWidth:1.8})})}),(0,_.jsx)(fm,{align:`center`,side:`top`,className:`w-30 border-(--border-default) bg-(--bg-primary) p-1 text-(--text-primary)`,children:[{mode:`light`,icon:rm,label:B(`lightMode`)},{mode:`dark`,icon:Up,label:B(`darkMode`)},{mode:`auto`,icon:Hp,label:B(`autoModeTheme`)}].map(({mode:e,icon:t,label:n})=>(0,_.jsxs)(`button`,{type:`button`,className:z(`w-full rounded-md px-2.5 py-1.5 text-left text-[13px] flex items-center justify-between hover:bg-(--bg-hover)`,k===e&&`text-(--text-primary) font-medium`),onClick:()=>o(e),children:[(0,_.jsxs)(`span`,{className:`flex items-center gap-1.5`,children:[(0,_.jsx)(t,{size:13,strokeWidth:1.8}),(0,_.jsx)(`span`,{children:n})]}),k===e&&(0,_.jsx)(pp,{size:13})]},e))})]}),(0,_.jsx)(`button`,{className:`border-0 bg-transparent inline-flex items-center justify-center size-8 rounded-lg cursor-pointer hover:bg-(--bg-hover) hover:text-(--text-primary) text-(--text-secondary)`,onClick:s,title:B(`settings`),"aria-label":B(`settings`),children:(0,_.jsx)(em,{size:15,strokeWidth:1.8})})]})]}),(0,_.jsx)(Em,{open:!!C,title:B(`deleteSessionConfirm`),description:C?B(`deleteSessionDescription`).replace(`{{session}}`,C.title||C.preview||C.id||``):``,loading:T,onOpenChange:e=>!e&&w(null),onConfirm:async()=>{if(!C)return;E(!0);let e=await b?.(C.id);E(!1),e?.error||w(null)}})]})}function Im(e){if(e==null||e<0)return``;if(e<1e3)return`${e}ms`;let t=e/1e3;return t<60?`${t.toFixed(1)}s`:`${Math.floor(t/60)}m ${Math.floor(t%60)}s`}function Lm(e){let t=typeof e==`string`?new Date(e):e,n=new Date,r=t.toDateString()===n.toDateString(),i=t.toLocaleTimeString([],{hour:`2-digit`,minute:`2-digit`});return r?i:t.toLocaleDateString([],{month:`short`,day:`numeric`})+` `+i}var Rm={read:Op,edit:Dp,write:Dp,delete:am,run:im,grep:Zp,glob:kp,list:kp,web_fetch:Mp,web_search:Zp,default:sm};function zm(e){let t=String(e).match(/^(\w+)/);return t?t[1]:e}function Bm(e,t){if(!e)return``;let n=e;if(typeof e==`string`)try{n=JSON.parse(e)}catch{return e}if(typeof n!=`object`)return String(n);let r={read:`path`,edit:`path`,write:`path`,delete:`path`,run:`command`,grep:`pattern`,glob:`pattern`,list:`path`,web_fetch:`url`,web_search:`query`}[t];if(r&&n[r]!=null)return String(n[r]);for(let e of Object.values(n))if(typeof e==`string`&&e.length>0&&e.length<200)return e;return``}function Vm(e){if(typeof e!=`string`)return JSON.stringify(e,null,2);let t=e.trim();if(!t)return``;try{return JSON.stringify(JSON.parse(t),null,2)}catch{return e}}function Hm(e){if(!e)return null;if(typeof e==`object`)return e;if(typeof e!=`string`)return null;try{return JSON.parse(e)}catch{return null}}function Um(e){let t=String(e||``).replace(/\\/g,`/`);return t.split(`/`).filter(Boolean).pop()||t}function Wm(e){return!e||typeof e!=`object`?{}:e.edit&&typeof e.edit==`object`?e.edit:e}function Gm(e,t,n,r){if(![`edit`,`write`,`delete`].includes(e))return null;let i=Hm(t)||{},a=Hm(n)||{},o=Wm(i),s=a.path||i.path||i.file||i.file_path||``,c=Number(a.lines_added??a.linesAdded??0),l=Number(a.lines_removed??a.linesRemoved??0),u=o.old_text??o.old_string??i.old_text,d=o.new_text??o.new_string??o.new_content??o.content??i.new_text??i.content,f=Number(a.changed_line||i.line||0);return{path:String(s||Bm(t,e)||``),action:String(a.action||(e===`write`?`write`:e)),added:c,removed:l,changedLine:f,diffPreview:String(a.diff_preview||``),oldText:typeof u==`string`?u:``,newText:typeof d==`string`?d:``,summary:String(r||``)}}function Km(e){if(!e)return[];if(e.oldText||e.newText){let t=e.oldText?e.oldText.split(/\r?\n/):[],n=e.newText?e.newText.split(/\r?\n/):[];return[...t.map((t,n)=>({type:`remove`,number:e.changedLine?e.changedLine+n:``,text:t})),...n.map((t,n)=>({type:`add`,number:e.changedLine?e.changedLine+n:``,text:t}))]}let t=e.diffPreview||e.summary.split(`
66
- `).slice(1).join(`
67
- `);return String(t||``).split(/\r?\n/).filter(Boolean).map(e=>{let t=e.match(/^(\d+)\|\s?(.*)$/);return{type:`add`,number:t?t[1]:``,text:t?t[2]:e}})}function qm({meta:e}){let t=Km(e);return t.length?(0,_.jsxs)(`div`,{className:`mt-2 overflow-hidden rounded-md border border-(--border-default) bg-(--bg-secondary)`,children:[(0,_.jsxs)(`div`,{className:`flex items-center gap-2 border-b border-(--border-default) px-3 py-2 font-mono text-xs`,children:[(0,_.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-(--text-primary)`,children:Um(e.path)||`file`}),e.added>0&&(0,_.jsxs)(`span`,{className:`text-(--accent-green)`,children:[`+`,e.added]}),e.removed>0&&(0,_.jsxs)(`span`,{className:`text-(--accent-red)`,children:[`-`,e.removed]})]}),(0,_.jsx)(`div`,{className:`max-h-64 overflow-auto font-mono text-xs leading-6`,children:t.map((e,t)=>(0,_.jsxs)(`div`,{className:z(`grid grid-cols-[42px_1fr] border-l-3 px-0`,e.type===`remove`?`border-(--accent-red) bg-(--accent-red-bg)`:`border-(--accent-green) bg-(--accent-green-bg)`),children:[(0,_.jsx)(`span`,{className:`select-none pr-3 text-right text-(--text-muted)`,children:e.number}),(0,_.jsx)(`span`,{className:`min-w-0 overflow-hidden text-ellipsis whitespace-pre text-(--text-primary)`,children:e.text||` `})]},t))})]}):null}var Jm={running:`bg-[var(--accent-blue)] animate-pulse`,done:`bg-[var(--accent-green)]`,error:`bg-[var(--accent-red)]`,blocked:`bg-[var(--accent-orange)]`},Ym=`flex cursor-pointer select-none items-center gap-2 rounded-md px-3 py-2 text-[13px] hover:bg-[var(--bg-hover)]`,Xm=`size-[14px] shrink-0 text-(--text-muted)`,Zm=`flex size-[18px] shrink-0 items-center justify-center rounded text-(--text-muted)`;function Qm({card:e}){let[t,n]=(0,d.useState)(!1),r=zm(e.name),i=Rm[r]||Rm.default,a=Bm(e.arguments,r),o=Gm(r,e.arguments,e.result,e.summary),s=o?.path||a||e.name,c=[];return e.arguments!=null&&e.arguments!==``&&c.push([`Arguments`,Vm(e.arguments)]),e.summary&&!o&&c.push([`Summary`,String(e.summary)]),e.result&&!o&&c.push([`Result`,Vm(e.result)]),(0,_.jsxs)(`div`,{className:z(`overflow-hidden bg-transparent`,e.status===`error`&&`rounded-md ring-1 ring-[var(--accent-red)]/25`,e.status===`blocked`&&`rounded-md ring-1 ring-[var(--accent-orange)]/25`),children:[(0,_.jsxs)(`div`,{className:Ym,onClick:()=>n(!t),children:[t?(0,_.jsx)(mp,{size:14,className:Xm}):(0,_.jsx)(hp,{size:14,className:Xm}),(0,_.jsx)(`span`,{className:Zm,children:(0,_.jsx)(i,{size:14})}),(0,_.jsx)(`span`,{className:`font-medium capitalize text-(--text-secondary)`,children:r}),(0,_.jsx)(`span`,{className:`min-w-0 flex-1 overflow-hidden text-ellipsis whitespace-nowrap font-mono text-xs font-normal text-(--text-muted)`,children:s}),o?.added>0&&(0,_.jsxs)(`span`,{className:`font-mono text-xs text-(--accent-green)`,children:[`+`,o.added]}),o?.removed>0&&(0,_.jsxs)(`span`,{className:`font-mono text-xs text-(--accent-red)`,children:[`-`,o.removed]}),e.durationMs!=null&&(0,_.jsx)(`span`,{className:`text-[11px] text-[var(--text-muted)] font-mono ml-auto shrink-0`,children:Im(e.durationMs)}),(0,_.jsx)(`span`,{className:z(`w-1.5 h-1.5 rounded-full shrink-0`,Jm[e.status]||`bg-[var(--muted)]`)})]}),t&&(0,_.jsx)(`div`,{className:`pb-2 pl-8 pr-2`,children:o?(0,_.jsxs)(_.Fragment,{children:[o.summary&&(0,_.jsx)(`div`,{className:`text-xs text-(--text-muted) pt-1`,children:o.summary.split(`
68
- `)[0]}),(0,_.jsx)(qm,{meta:o})]}):c.length===0?(0,_.jsx)(`div`,{className:`text-xs text-[var(--text-muted)]`,children:`No details yet`}):c.map(([e,t],n)=>(0,_.jsxs)(`div`,{children:[(0,_.jsx)(`div`,{className:`mt-2 mb-1 text-[10px] font-bold uppercase tracking-[0.4px] text-[var(--text-muted)]`,children:e}),(0,_.jsx)(`pre`,{className:`m-0 p-2 rounded bg-[var(--bg-tertiary)] text-[var(--text-primary)] font-mono text-xs leading-relaxed max-h-100 overflow-x-auto whitespace-pre-wrap break-words`,children:t})]},n))})]})}var $m=(function(e){if(e==null)return ih;if(typeof e==`function`)return rh(e);if(typeof e==`object`)return Array.isArray(e)?eh(e):th(e);if(typeof e==`string`)return nh(e);throw Error(`Expected function, string, or object as test`)});function eh(e){let t=[],n=-1;for(;++n<e.length;)t[n]=$m(e[n]);return rh(r);function r(...e){let n=-1;for(;++n<t.length;)if(t[n].apply(this,e))return!0;return!1}}function th(e){let t=e;return rh(n);function n(n){let r=n,i;for(i in e)if(r[i]!==t[i])return!1;return!0}}function nh(e){return rh(t);function t(t){return t&&t.type===e}}function rh(e){return t;function t(t,n,r){return!!(ah(t)&&e.call(this,t,typeof n==`number`?n:void 0,r||void 0))}}function ih(){return!0}function ah(e){return typeof e==`object`&&!!e&&`type`in e}function oh(e){return e}var sh=[],ch=`skip`;function lh(e,t,n,r){let i;typeof t==`function`&&typeof n!=`function`?(r=n,n=t):i=t;let a=$m(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 (`+oh(e.type+(t?`<`+t+`>`:``))+`)`})}return u;function u(){let l=sh,u,d,f;if((!t||a(e,i,c[c.length-1]||void 0))&&(l=uh(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 uh(e){return Array.isArray(e)?e:typeof e==`number`?[!0,e]:e==null?sh:[e]}function dh(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),lh(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 fh={indicator:`indicator`,textOnly:`text-only`,remove:`remove`};function ph({defaultOrigin:e=``,allowedLinkPrefixes:t=[],allowedImagePrefixes:n=[],allowDataImages:r=!1,allowedProtocols:i=[],blockedImageClass:a=`inline-block bg-gray-200 dark:bg-gray-700 text-gray-600 dark:text-gray-400 px-3 py-1 rounded text-sm`,blockedLinkClass:o=`text-gray-500`,linkBlockPolicy:s=fh.indicator,imageBlockPolicy:c=fh.indicator}){let l=t.length&&!t.every(e=>e===`*`),u=n.length&&!n.every(e=>e===`*`);if(!e&&(l||u))throw Error(`defaultOrigin is required when allowedLinkPrefixes or allowedImagePrefixes are provided`);return l=>{let u=Ch(e,t,n,r,i,a,o,s,c);yh(l),dh(l,u)}}function mh(e,t){if(typeof e!=`string`)return null;try{return new URL(e)}catch{if(t)try{return new URL(e,t)}catch{return null}if(e.startsWith(`/`)||e.startsWith(`./`)||e.startsWith(`../`))try{return new URL(e,`http://example.com`)}catch{return null}return null}}function hh(e){return typeof e==`string`?e.startsWith(`/`)||e.startsWith(`./`)||e.startsWith(`../`):!1}var gh=new Set([`https:`,`http:`,`irc:`,`ircs:`,`mailto:`,`xmpp:`,`blob:`]),_h=new Set([`javascript:`,`data:`,`file:`,`vbscript:`]);function vh(e,t,n,r=!1,i=!1,a=[]){if(!e)return null;if(typeof e==`string`&&e.startsWith(`#`)&&!i)try{if(new URL(e,`http://example.com`).hash===e)return e}catch{}if(typeof e==`string`&&e.startsWith(`data:`))return i&&r&&e.startsWith(`data:image/`)?e:null;if(typeof e==`string`&&e.startsWith(`blob:`)){try{if(new URL(e).protocol===`blob:`&&e.length>5){let t=e.substring(5);if(t&&t.length>0&&t!==`invalid`)return e}}catch{return null}return null}let o=mh(e,n);if(!o||_h.has(o.protocol)||!(gh.has(o.protocol)||a.includes(o.protocol)||a.includes(`*`)))return null;if(o.protocol===`mailto:`||!o.protocol.match(/^https?:$/))return o.href;let s=hh(e);return o&&t.some(e=>{let t=mh(e,n);return!t||t.origin!==o.origin?!1:o.href.startsWith(t.href)})?s?o.pathname+o.search+o.hash:o.href:t.includes(`*`)?o.protocol!==`https:`&&o.protocol!==`http:`?null:s?o.pathname+o.search+o.hash:o.href:null}function yh(e){if(`children`in e&&Array.isArray(e.children)){e.children=e.children.filter(e=>e!=null);for(let t of e.children)yh(t)}}var bh=Symbol(`node-seen`);function xh(e,t,n){return t===fh.remove?{type:`remove`}:t===fh.textOnly?{type:`replace`,element:{type:`element`,tagName:`span`,properties:{},children:[...e.children]}}:{type:`replace`,element:{type:`element`,tagName:`span`,properties:{title:`Blocked URL: `+String(e.properties.href),class:n},children:[...e.children,{type:`text`,value:` [blocked]`}]}}}function Sh(e,t,n){if(t===fh.remove)return{type:`remove`};if(t===fh.textOnly){let t=String(e.properties.alt||``);return t?{type:`replace`,element:{type:`element`,tagName:`span`,properties:{},children:[{type:`text`,value:t}]}}:{type:`remove`}}return{type:`replace`,element:{type:`element`,tagName:`span`,properties:{class:n},children:[{type:`text`,value:`[Image blocked: `+String(e.properties.alt||`No description`)+`]`}]}}}var Ch=(e,t,n,r,i,a,o,s,c)=>{let l=(u,d,f)=>{if(u.type!==`element`||u[bh])return!0;if(u.tagName===`a`){let n=vh(u.properties.href,t,e,!1,!1,i);if(n===null){if(u[bh]=!0,dh(u,l),f&&typeof d==`number`){let e=xh(u,s,o);if(e.type===`remove`)return f.children.splice(d,1),[ch,d];f.children[d]=e.element}return ch}else return u.properties.href=n,u.properties.target=`_blank`,u.properties.rel=`noopener noreferrer`,!0}if(u.tagName===`img`){let t=vh(u.properties.src,n,e,r,!0,i);if(t===null){if(u[bh]=!0,dh(u,l),f&&typeof d==`number`){let e=Sh(u,c,a);if(e.type===`remove`)return f.children.splice(d,1),[ch,d];f.children[d]=e.element}return ch}else return u.properties.src=t,!0}return!0};return l},wh=typeof self==`object`?self:globalThis,Th=(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(new wh[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(new wh[a](o),i)};return r},Eh=e=>Th(new Map,e)(0),Dh=``,{toString:Oh}={},{keys:kh}=Object,Ah=e=>{let t=typeof e;if(t!==`object`||!e)return[0,t];let n=Oh.call(e).slice(8,-1);switch(n){case`Array`:return[1,Dh];case`Object`:return[2,Dh];case`Date`:return[3,Dh];case`RegExp`:return[4,Dh];case`Map`:return[5,Dh];case`Set`:return[6,Dh];case`DataView`:return[1,n]}return n.includes(`Array`)?[1,n]:n.includes(`Error`)?[7,n]:[2,n]},jh=([e,t])=>e===0&&(t===`function`||t===`symbol`),Mh=(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]=Ah(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 kh(r))(e||!jh(Ah(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||!(jh(Ah(n))||jh(Ah(i))))&&t.push([a(n),a(i)]);return n}case 6:{let t=[],n=i([o,t],r);for(let n of r)(e||!jh(Ah(n)))&&t.push(a(n));return n}}let{message:c}=r;return i([o,{name:s,message:c}],r)};return a},Nh=(e,{json:t,lossy:n}={})=>{let r=[];return Mh(!(t||n),!!t,new Map,r)(e),r},Ph=typeof structuredClone==`function`?(e,t)=>t&&(`json`in t||`lossy`in t)?Eh(Nh(e,t)):structuredClone(e):(e,t)=>Eh(Nh(e,t)),Fh=class{constructor(e,t,n){this.normal=t,this.property=e,n&&(this.space=n)}};Fh.prototype.normal={},Fh.prototype.property={},Fh.prototype.space=void 0;function Ih(e,t){let n={},r={};for(let t of e)Object.assign(n,t.property),Object.assign(r,t.normal);return new Fh(n,r,t)}function Lh(e){return e.toLowerCase()}var Rh=class{constructor(e,t){this.attribute=t,this.property=e}};Rh.prototype.attribute=``,Rh.prototype.booleanish=!1,Rh.prototype.boolean=!1,Rh.prototype.commaOrSpaceSeparated=!1,Rh.prototype.commaSeparated=!1,Rh.prototype.defined=!1,Rh.prototype.mustUseProperty=!1,Rh.prototype.number=!1,Rh.prototype.overloadedBoolean=!1,Rh.prototype.property=``,Rh.prototype.spaceSeparated=!1,Rh.prototype.space=void 0;var zh=e({boolean:()=>Vh,booleanish:()=>Hh,commaOrSpaceSeparated:()=>Kh,commaSeparated:()=>Gh,number:()=>U,overloadedBoolean:()=>Uh,spaceSeparated:()=>Wh}),Bh=0,Vh=qh(),Hh=qh(),Uh=qh(),U=qh(),Wh=qh(),Gh=qh(),Kh=qh();function qh(){return 2**++Bh}var Jh=Object.keys(zh),Yh=class extends Rh{constructor(e,t,n,r){let i=-1;if(super(e,t),Xh(this,`space`,r),typeof n==`number`)for(;++i<Jh.length;){let e=Jh[i];Xh(this,Jh[i],(n&zh[e])===zh[e])}}};Yh.prototype.defined=!0;function Xh(e,t,n){n&&(e[t]=n)}function Zh(e){let t={},n={};for(let[r,i]of Object.entries(e.properties)){let a=new Yh(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[Lh(r)]=r,n[Lh(a.attribute)]=r}return new Fh(t,n,e.space)}var Qh=Zh({properties:{ariaActiveDescendant:null,ariaAtomic:Hh,ariaAutoComplete:null,ariaBusy:Hh,ariaChecked:Hh,ariaColCount:U,ariaColIndex:U,ariaColSpan:U,ariaControls:Wh,ariaCurrent:null,ariaDescribedBy:Wh,ariaDetails:null,ariaDisabled:Hh,ariaDropEffect:Wh,ariaErrorMessage:null,ariaExpanded:Hh,ariaFlowTo:Wh,ariaGrabbed:Hh,ariaHasPopup:null,ariaHidden:Hh,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:Wh,ariaLevel:U,ariaLive:null,ariaModal:Hh,ariaMultiLine:Hh,ariaMultiSelectable:Hh,ariaOrientation:null,ariaOwns:Wh,ariaPlaceholder:null,ariaPosInSet:U,ariaPressed:Hh,ariaReadOnly:Hh,ariaRelevant:null,ariaRequired:Hh,ariaRoleDescription:Wh,ariaRowCount:U,ariaRowIndex:U,ariaRowSpan:U,ariaSelected:Hh,ariaSetSize:U,ariaSort:null,ariaValueMax:U,ariaValueMin:U,ariaValueNow:U,ariaValueText:null,role:null},transform(e,t){return t===`role`?t:`aria-`+t.slice(4).toLowerCase()}});function $h(e,t){return t in e?e[t]:t}function eg(e,t){return $h(e,t.toLowerCase())}var tg=Zh({attributes:{acceptcharset:`accept-charset`,classname:`class`,htmlfor:`for`,httpequiv:`http-equiv`},mustUseProperty:[`checked`,`multiple`,`muted`,`selected`],properties:{abbr:null,accept:Gh,acceptCharset:Wh,accessKey:Wh,action:null,allow:null,allowFullScreen:Vh,allowPaymentRequest:Vh,allowUserMedia:Vh,alt:null,as:null,async:Vh,autoCapitalize:null,autoComplete:Wh,autoFocus:Vh,autoPlay:Vh,blocking:Wh,capture:null,charSet:null,checked:Vh,cite:null,className:Wh,cols:U,colSpan:null,content:null,contentEditable:Hh,controls:Vh,controlsList:Wh,coords:U|Gh,crossOrigin:null,data:null,dateTime:null,decoding:null,default:Vh,defer:Vh,dir:null,dirName:null,disabled:Vh,download:Uh,draggable:Hh,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:Vh,formTarget:null,headers:Wh,height:U,hidden:Uh,high:U,href:null,hrefLang:null,htmlFor:Wh,httpEquiv:Wh,id:null,imageSizes:null,imageSrcSet:null,inert:Vh,inputMode:null,integrity:null,is:null,isMap:Vh,itemId:null,itemProp:Wh,itemRef:Wh,itemScope:Vh,itemType:Wh,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:Vh,low:U,manifest:null,max:null,maxLength:U,media:null,method:null,min:null,minLength:U,multiple:Vh,muted:Vh,name:null,nonce:null,noModule:Vh,noValidate:Vh,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:Vh,optimum:U,pattern:null,ping:Wh,placeholder:null,playsInline:Vh,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:Vh,referrerPolicy:null,rel:Wh,required:Vh,reversed:Vh,rows:U,rowSpan:U,sandbox:Wh,scope:null,scoped:Vh,seamless:Vh,selected:Vh,shadowRootClonable:Vh,shadowRootDelegatesFocus:Vh,shadowRootMode:null,shape:null,size:U,sizes:null,slot:null,span:U,spellCheck:Hh,src:null,srcDoc:null,srcLang:null,srcSet:null,start:U,step:null,style:null,tabIndex:U,target:null,title:null,translate:null,type:null,typeMustMatch:Vh,useMap:null,value:Hh,width:U,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:Wh,axis:null,background:null,bgColor:null,border:U,borderColor:null,bottomMargin:U,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:Vh,declare:Vh,event:null,face:null,frame:null,frameBorder:null,hSpace:U,leftMargin:U,link:null,longDesc:null,lowSrc:null,marginHeight:U,marginWidth:U,noResize:Vh,noHref:Vh,noShade:Vh,noWrap:Vh,object:null,profile:null,prompt:null,rev:null,rightMargin:U,rules:null,scheme:null,scrolling:Hh,standby:null,summary:null,text:null,topMargin:U,valueType:null,version:null,vAlign:null,vLink:null,vSpace:U,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:Vh,disableRemotePlayback:Vh,prefix:null,property:null,results:U,security:null,unselectable:null},space:`html`,transform:eg}),ng=Zh({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:Kh,accentHeight:U,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:U,amplitude:U,arabicForm:null,ascent:U,attributeName:null,attributeType:null,azimuth:U,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:U,by:null,calcMode:null,capHeight:U,className:Wh,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:U,diffuseConstant:U,direction:null,display:null,dur:null,divisor:U,dominantBaseline:null,download:Vh,dx:null,dy:null,edgeMode:null,editable:null,elevation:U,enableBackground:null,end:null,event:null,exponent:U,externalResourcesRequired:null,fill:null,fillOpacity:U,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:Gh,g2:Gh,glyphName:Gh,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:U,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:U,horizOriginX:U,horizOriginY:U,id:null,ideographic:U,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:U,k:U,k1:U,k2:U,k3:U,k4:U,kernelMatrix:Kh,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:U,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:U,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:U,overlineThickness:U,paintOrder:null,panose1:null,path:null,pathLength:U,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:Wh,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:U,pointsAtY:U,pointsAtZ:U,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Kh,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Kh,rev:Kh,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Kh,requiredFeatures:Kh,requiredFonts:Kh,requiredFormats:Kh,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:U,specularExponent:U,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:U,strikethroughThickness:U,string:null,stroke:null,strokeDashArray:Kh,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:U,strokeOpacity:U,strokeWidth:null,style:null,surfaceScale:U,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Kh,tabIndex:U,tableValues:null,target:null,targetX:U,targetY:U,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Kh,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:U,underlineThickness:U,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:U,values:null,vAlphabetic:U,vMathematical:U,vectorEffect:null,vHanging:U,vIdeographic:U,version:null,vertAdvY:U,vertOriginX:U,vertOriginY:U,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:U,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:`svg`,transform:$h}),rg=Zh({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()}}),ig=Zh({attributes:{xmlnsxlink:`xmlns:xlink`},properties:{xmlnsXLink:null,xmlns:null},space:`xmlns`,transform:eg}),ag=Zh({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:`xml`,transform(e,t){return`xml:`+t.slice(3).toLowerCase()}}),og={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`},sg=/[A-Z]/g,cg=/-[a-z]/g,lg=/^data[-\w.:]+$/i;function ug(e,t){let n=Lh(t),r=t,i=Rh;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)===`data`&&lg.test(t)){if(t.charAt(4)===`-`){let e=t.slice(5).replace(cg,fg);r=`data`+e.charAt(0).toUpperCase()+e.slice(1)}else{let e=t.slice(4);if(!cg.test(e)){let n=e.replace(sg,dg);n.charAt(0)!==`-`&&(n=`-`+n),t=`data`+n}}i=Yh}return new i(r,t)}function dg(e){return`-`+e.toLowerCase()}function fg(e){return e.charAt(1).toUpperCase()}var pg=Ih([Qh,tg,rg,ig,ag],`html`),mg=Ih([Qh,ng,rg,ig,ag],`svg`);function hg(e){let t=[],n=String(e||``),r=n.indexOf(`,`),i=0,a=!1;for(;!a;){r===-1&&(r=n.length,a=!0);let e=n.slice(i,r).trim();(e||!a)&&t.push(e),i=r+1,r=n.indexOf(`,`,i)}return t}function gg(e,t){let n=t||{};return(e[e.length-1]===``?[...e,``]:e).join((n.padRight?` `:``)+`,`+(n.padLeft===!1?``:` `)).trim()}var _g=/[#.]/g;function vg(e,t){let n=e||``,r={},i=0,a,o;for(;i<n.length;){_g.lastIndex=i;let e=_g.exec(n),t=n.slice(i,e?e.index:n.length);t&&(a?a===`#`?r.id=t:Array.isArray(r.className)?r.className.push(t):r.className=[t]:o=t,i+=t.length),e&&(a=e[0],i++)}return{type:`element`,tagName:o||t||`div`,properties:r,children:[]}}function yg(e){let t=String(e||``).trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function bg(e){return e.join(` `).trim()}function xg(e,t,n){let r=n?Dg(n):void 0;function i(n,i,...a){let o;if(n==null){o={type:`root`,children:[]};let e=i;a.unshift(e)}else{o=vg(n,t);let s=o.tagName.toLowerCase(),c=r?r.get(s):void 0;if(o.tagName=c||s,Sg(i))a.unshift(i);else for(let[t,n]of Object.entries(i))Cg(e,o.properties,t,n)}for(let e of a)wg(o.children,e);return o.type===`element`&&o.tagName===`template`&&(o.content={type:`root`,children:o.children},o.children=[]),o}return i}function Sg(e){if(typeof e!=`object`||!e||Array.isArray(e))return!0;if(typeof e.type!=`string`)return!1;let t=e,n=Object.keys(e);for(let e of n){let n=t[e];if(n&&typeof n==`object`){if(!Array.isArray(n))return!0;let e=n;for(let t of e)if(typeof t!=`number`&&typeof t!=`string`)return!0}}return!!(`children`in e&&Array.isArray(e.children))}function Cg(e,t,n,r){let i=ug(e,n),a;if(r!=null){if(typeof r==`number`){if(Number.isNaN(r))return;a=r}else a=typeof r==`boolean`?r:typeof r==`string`?i.spaceSeparated?yg(r):i.commaSeparated?hg(r):i.commaOrSpaceSeparated?yg(hg(r).join(` `)):Tg(i,i.property,r):Array.isArray(r)?[...r]:i.property===`style`?Eg(r):String(r);if(Array.isArray(a)){let e=[];for(let t of a)e.push(Tg(i,i.property,t));a=e}i.property===`className`&&Array.isArray(t.className)&&(a=t.className.concat(a)),t[i.property]=a}}function wg(e,t){if(t!=null)if(typeof t==`number`||typeof t==`string`)e.push({type:`text`,value:String(t)});else if(Array.isArray(t))for(let n of t)wg(e,n);else if(typeof t==`object`&&`type`in t)t.type===`root`?wg(e,t.children):e.push(t);else throw Error("Expected node, nodes, or string, got `"+t+"`")}function Tg(e,t,n){if(typeof n==`string`){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===``||Lh(n)===Lh(t)))return!0}return n}function Eg(e){let t=[];for(let[n,r]of Object.entries(e))t.push([n,r].join(`: `));return t.join(`; `)}function Dg(e){let t=new Map;for(let n of e)t.set(n.toLowerCase(),n);return t}var Og=`altGlyph.altGlyphDef.altGlyphItem.animateColor.animateMotion.animateTransform.clipPath.feBlend.feColorMatrix.feComponentTransfer.feComposite.feConvolveMatrix.feDiffuseLighting.feDisplacementMap.feDistantLight.feDropShadow.feFlood.feFuncA.feFuncB.feFuncG.feFuncR.feGaussianBlur.feImage.feMerge.feMergeNode.feMorphology.feOffset.fePointLight.feSpecularLighting.feSpotLight.feTile.feTurbulence.foreignObject.glyphRef.linearGradient.radialGradient.solidColor.textArea.textPath`.split(`.`),kg=xg(pg,`div`),Ag=xg(mg,`g`,Og);function jg(e){let t=String(e),n=[];return{toOffset:i,toPoint:r};function r(e){if(typeof e==`number`&&e>-1&&e<=t.length){let r=0;for(;;){let i=n[r];if(i===void 0){let e=Mg(t,n[r-1]);i=e===-1?t.length+1:e+1,n[r]=i}if(i>e)return{line:r+1,column:e-(r>0?n[r-1]:0)+1,offset:e};r++}}}function i(e){if(e&&typeof e.line==`number`&&typeof e.column==`number`&&!Number.isNaN(e.line)&&!Number.isNaN(e.column)){for(;n.length<e.line;){let e=n[n.length-1],r=Mg(t,e),i=r===-1?t.length+1:r+1;if(e===i)break;n.push(i)}let r=(e.line>1?n[e.line-2]:0)+e.column-1;if(r<n[e.line-1])return r}}}function Mg(e,t){let n=e.indexOf(`\r`,t),r=e.indexOf(`
69
- `,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}var Ng={html:`http://www.w3.org/1999/xhtml`,mathml:`http://www.w3.org/1998/Math/MathML`,svg:`http://www.w3.org/2000/svg`,xlink:`http://www.w3.org/1999/xlink`,xml:`http://www.w3.org/XML/1998/namespace`,xmlns:`http://www.w3.org/2000/xmlns/`},Pg={}.hasOwnProperty,Fg=Object.prototype;function Ig(e,t){let n=t||{};return Lg({file:n.file||void 0,location:!1,schema:n.space===`svg`?mg:pg,verbose:n.verbose||!1},e)}function Lg(e,t){let n;switch(t.nodeName){case`#comment`:{let r=t;return n={type:`comment`,value:r.data},Bg(e,r,n),n}case`#document`:case`#document-fragment`:{let r=t,i=`mode`in r?r.mode===`quirks`||r.mode===`limited-quirks`:!1;if(n={type:`root`,children:Rg(e,t.childNodes),data:{quirksMode:i}},e.file&&e.location){let t=String(e.file),r=jg(t),i=r.toPoint(0),a=r.toPoint(t.length);n.position={start:i,end:a}}return n}case`#documentType`:{let r=t;return n={type:`doctype`},Bg(e,r,n),n}case`#text`:{let r=t;return n={type:`text`,value:r.value},Bg(e,r,n),n}default:return n=zg(e,t),n}}function Rg(e,t){let n=-1,r=[];for(;++n<t.length;){let i=Lg(e,t[n]);r.push(i)}return r}function zg(e,t){let n=e.schema;e.schema=t.namespaceURI===Ng.svg?mg:pg;let r=-1,i={};for(;++r<t.attrs.length;){let e=t.attrs[r],n=(e.prefix?e.prefix+`:`:``)+e.name;Pg.call(Fg,n)||(i[n]=e.value)}let a=(e.schema.space===`svg`?Ag:kg)(t.tagName,i,Rg(e,t.childNodes));if(Bg(e,t,a),a.tagName===`template`){let n=t,r=n.sourceCodeLocation,i=r&&r.startTag&&Hg(r.startTag),o=r&&r.endTag&&Hg(r.endTag),s=Lg(e,n.content);i&&o&&e.file&&(s.position={start:i.end,end:o.start}),a.content=s}return e.schema=n,a}function Bg(e,t,n){if(`sourceCodeLocation`in t&&t.sourceCodeLocation&&e.file){let r=Vg(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function Vg(e,t,n){let r=Hg(n);if(t.type===`element`){let i=t.children[t.children.length-1];if(r&&!n.endTag&&i&&i.position&&i.position.end&&(r.end=Object.assign({},i.position.end)),e.verbose){let r={},i;if(n.attrs)for(i in n.attrs)Pg.call(n.attrs,i)&&(r[ug(e.schema,i).property]=Hg(n.attrs[i]));n.startTag;let a=Hg(n.startTag),o=n.endTag?Hg(n.endTag):void 0,s={opening:a};o&&(s.closing=o),s.properties=r,t.data={position:s}}}return r}function Hg(e){let t=Ug({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=Ug({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function Ug(e){return e.line&&e.column?e:void 0}var Wg={}.hasOwnProperty;function Gg(e,t){let n=t||{};function r(t,...n){let i=r.invalid,a=r.handlers;if(t&&Wg.call(t,e)){let n=String(t[e]);i=Wg.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 Kg={},qg={}.hasOwnProperty,Jg=Gg(`type`,{handlers:{root:Xg,element:t_,text:$g,comment:e_,doctype:Qg}});function Yg(e,t){let n=(t||Kg).space;return Jg(e,n===`svg`?mg:pg)}function Xg(e,t){let n={nodeName:`#document`,mode:(e.data||{}).quirksMode?`quirks`:`no-quirks`,childNodes:[]};return n.childNodes=r_(e.children,n,t),i_(e,n),n}function Zg(e,t){let n={nodeName:`#document-fragment`,childNodes:[]};return n.childNodes=r_(e.children,n,t),i_(e,n),n}function Qg(e){let t={nodeName:`#documentType`,name:`html`,publicId:``,systemId:``,parentNode:null};return i_(e,t),t}function $g(e){let t={nodeName:`#text`,value:e.value,parentNode:null};return i_(e,t),t}function e_(e){let t={nodeName:`#comment`,data:e.value,parentNode:null};return i_(e,t),t}function t_(e,t){let n=t,r=n;e.type===`element`&&e.tagName.toLowerCase()===`svg`&&n.space===`html`&&(r=mg);let i=[],a;if(e.properties){for(a in e.properties)if(a!==`children`&&qg.call(e.properties,a)){let t=n_(r,a,e.properties[a]);t&&i.push(t)}}let o=r.space,s={nodeName:e.tagName,tagName:e.tagName,attrs:i,namespaceURI:Ng[o],childNodes:[],parentNode:null};return s.childNodes=r_(e.children,s,r),i_(e,s),e.tagName===`template`&&e.content&&(s.content=Zg(e.content,r)),s}function n_(e,t,n){let r=ug(e,t);if(n===!1||n==null||typeof n==`number`&&Number.isNaN(n)||!n&&r.boolean)return;Array.isArray(n)&&(n=r.commaSeparated?gg(n):bg(n));let i={name:r.attribute,value:n===!0?``:String(n)};if(r.space&&r.space!==`html`&&r.space!==`svg`){let e=i.name.indexOf(`:`);e<0?i.prefix=``:(i.name=i.name.slice(e+1),i.prefix=r.attribute.slice(0,e)),i.namespace=Ng[r.space]}return i}function r_(e,t,n){let r=-1,i=[];if(e)for(;++r<e.length;){let a=Jg(e[r],n);a.parentNode=t,i.push(a)}return i}function i_(e,t){let n=e.position;n&&n.start&&n.end&&(n.start.offset,n.end.offset,t.sourceCodeLocation={startLine:n.start.line,startCol:n.start.column,startOffset:n.start.offset,endLine:n.end.line,endCol:n.end.column,endOffset:n.end.offset})}var a_=[`area`,`base`,`basefont`,`bgsound`,`br`,`col`,`command`,`embed`,`frame`,`hr`,`image`,`img`,`input`,`keygen`,`link`,`meta`,`param`,`source`,`track`,`wbr`],o_=new Set([65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111]),W;(function(e){e[e.EOF=-1]=`EOF`,e[e.NULL=0]=`NULL`,e[e.TABULATION=9]=`TABULATION`,e[e.CARRIAGE_RETURN=13]=`CARRIAGE_RETURN`,e[e.LINE_FEED=10]=`LINE_FEED`,e[e.FORM_FEED=12]=`FORM_FEED`,e[e.SPACE=32]=`SPACE`,e[e.EXCLAMATION_MARK=33]=`EXCLAMATION_MARK`,e[e.QUOTATION_MARK=34]=`QUOTATION_MARK`,e[e.AMPERSAND=38]=`AMPERSAND`,e[e.APOSTROPHE=39]=`APOSTROPHE`,e[e.HYPHEN_MINUS=45]=`HYPHEN_MINUS`,e[e.SOLIDUS=47]=`SOLIDUS`,e[e.DIGIT_0=48]=`DIGIT_0`,e[e.DIGIT_9=57]=`DIGIT_9`,e[e.SEMICOLON=59]=`SEMICOLON`,e[e.LESS_THAN_SIGN=60]=`LESS_THAN_SIGN`,e[e.EQUALS_SIGN=61]=`EQUALS_SIGN`,e[e.GREATER_THAN_SIGN=62]=`GREATER_THAN_SIGN`,e[e.QUESTION_MARK=63]=`QUESTION_MARK`,e[e.LATIN_CAPITAL_A=65]=`LATIN_CAPITAL_A`,e[e.LATIN_CAPITAL_Z=90]=`LATIN_CAPITAL_Z`,e[e.RIGHT_SQUARE_BRACKET=93]=`RIGHT_SQUARE_BRACKET`,e[e.GRAVE_ACCENT=96]=`GRAVE_ACCENT`,e[e.LATIN_SMALL_A=97]=`LATIN_SMALL_A`,e[e.LATIN_SMALL_Z=122]=`LATIN_SMALL_Z`})(W||={});var s_={DASH_DASH:`--`,CDATA_START:`[CDATA[`,DOCTYPE:`doctype`,SCRIPT:`script`,PUBLIC:`public`,SYSTEM:`system`};function c_(e){return e>=55296&&e<=57343}function l_(e){return e>=56320&&e<=57343}function u_(e,t){return(e-55296)*1024+9216+t}function d_(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function f_(e){return e>=64976&&e<=65007||o_.has(e)}var G;(function(e){e.controlCharacterInInputStream=`control-character-in-input-stream`,e.noncharacterInInputStream=`noncharacter-in-input-stream`,e.surrogateInInputStream=`surrogate-in-input-stream`,e.nonVoidHtmlElementStartTagWithTrailingSolidus=`non-void-html-element-start-tag-with-trailing-solidus`,e.endTagWithAttributes=`end-tag-with-attributes`,e.endTagWithTrailingSolidus=`end-tag-with-trailing-solidus`,e.unexpectedSolidusInTag=`unexpected-solidus-in-tag`,e.unexpectedNullCharacter=`unexpected-null-character`,e.unexpectedQuestionMarkInsteadOfTagName=`unexpected-question-mark-instead-of-tag-name`,e.invalidFirstCharacterOfTagName=`invalid-first-character-of-tag-name`,e.unexpectedEqualsSignBeforeAttributeName=`unexpected-equals-sign-before-attribute-name`,e.missingEndTagName=`missing-end-tag-name`,e.unexpectedCharacterInAttributeName=`unexpected-character-in-attribute-name`,e.unknownNamedCharacterReference=`unknown-named-character-reference`,e.missingSemicolonAfterCharacterReference=`missing-semicolon-after-character-reference`,e.unexpectedCharacterAfterDoctypeSystemIdentifier=`unexpected-character-after-doctype-system-identifier`,e.unexpectedCharacterInUnquotedAttributeValue=`unexpected-character-in-unquoted-attribute-value`,e.eofBeforeTagName=`eof-before-tag-name`,e.eofInTag=`eof-in-tag`,e.missingAttributeValue=`missing-attribute-value`,e.missingWhitespaceBetweenAttributes=`missing-whitespace-between-attributes`,e.missingWhitespaceAfterDoctypePublicKeyword=`missing-whitespace-after-doctype-public-keyword`,e.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers=`missing-whitespace-between-doctype-public-and-system-identifiers`,e.missingWhitespaceAfterDoctypeSystemKeyword=`missing-whitespace-after-doctype-system-keyword`,e.missingQuoteBeforeDoctypePublicIdentifier=`missing-quote-before-doctype-public-identifier`,e.missingQuoteBeforeDoctypeSystemIdentifier=`missing-quote-before-doctype-system-identifier`,e.missingDoctypePublicIdentifier=`missing-doctype-public-identifier`,e.missingDoctypeSystemIdentifier=`missing-doctype-system-identifier`,e.abruptDoctypePublicIdentifier=`abrupt-doctype-public-identifier`,e.abruptDoctypeSystemIdentifier=`abrupt-doctype-system-identifier`,e.cdataInHtmlContent=`cdata-in-html-content`,e.incorrectlyOpenedComment=`incorrectly-opened-comment`,e.eofInScriptHtmlCommentLikeText=`eof-in-script-html-comment-like-text`,e.eofInDoctype=`eof-in-doctype`,e.nestedComment=`nested-comment`,e.abruptClosingOfEmptyComment=`abrupt-closing-of-empty-comment`,e.eofInComment=`eof-in-comment`,e.incorrectlyClosedComment=`incorrectly-closed-comment`,e.eofInCdata=`eof-in-cdata`,e.absenceOfDigitsInNumericCharacterReference=`absence-of-digits-in-numeric-character-reference`,e.nullCharacterReference=`null-character-reference`,e.surrogateCharacterReference=`surrogate-character-reference`,e.characterReferenceOutsideUnicodeRange=`character-reference-outside-unicode-range`,e.controlCharacterReference=`control-character-reference`,e.noncharacterCharacterReference=`noncharacter-character-reference`,e.missingWhitespaceBeforeDoctypeName=`missing-whitespace-before-doctype-name`,e.missingDoctypeName=`missing-doctype-name`,e.invalidCharacterSequenceAfterDoctypeName=`invalid-character-sequence-after-doctype-name`,e.duplicateAttribute=`duplicate-attribute`,e.nonConformingDoctype=`non-conforming-doctype`,e.missingDoctype=`missing-doctype`,e.misplacedDoctype=`misplaced-doctype`,e.endTagWithoutMatchingOpenElement=`end-tag-without-matching-open-element`,e.closingOfElementWithOpenChildElements=`closing-of-element-with-open-child-elements`,e.disallowedContentInNoscriptInHead=`disallowed-content-in-noscript-in-head`,e.openElementsLeftAfterEof=`open-elements-left-after-eof`,e.abandonedHeadElementChild=`abandoned-head-element-child`,e.misplacedStartTagForHeadElement=`misplaced-start-tag-for-head-element`,e.nestedNoscriptInHead=`nested-noscript-in-head`,e.eofInElementThatCanContainOnlyText=`eof-in-element-that-can-contain-only-text`})(G||={});var p_=65536,m_=class{constructor(e){this.handler=e,this.html=``,this.pos=-1,this.lastGapPos=-2,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=p_,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.line=1,this.lastErrOffset=-1}get col(){return this.pos-this.lineStartPos+Number(this.lastGapPos!==this.pos)}get offset(){return this.droppedBufferSize+this.pos}getError(e,t){let{line:n,col:r,offset:i}=this,a=r+t,o=i+t;return{code:e,startLine:n,endLine:n,startCol:a,endCol:a,startOffset:o,endOffset:o}}_err(e){this.handler.onParseError&&this.lastErrOffset!==this.offset&&(this.lastErrOffset=this.offset,this.handler.onParseError(this.getError(e,0)))}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(e){if(this.pos!==this.html.length-1){let t=this.html.charCodeAt(this.pos+1);if(l_(t))return this.pos++,this._addGap(),u_(e,t)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,W.EOF;return this._err(G.surrogateInInputStream),e}willDropParsedChunk(){return this.pos>this.bufferWaterline}dropParsedChunk(){this.willDropParsedChunk()&&(this.html=this.html.substring(this.pos),this.lineStartPos-=this.pos,this.droppedBufferSize+=this.pos,this.pos=0,this.lastGapPos=-2,this.gapStack.length=0)}write(e,t){this.html.length>0?this.html+=e:this.html=e,this.endOfChunkHit=!1,this.lastChunkWritten=t}insertHtmlAtCurrentPos(e){this.html=this.html.substring(0,this.pos+1)+e+this.html.substring(this.pos+1),this.endOfChunkHit=!1}startsWith(e,t){if(this.pos+e.length>this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,!1;if(t)return this.html.startsWith(e,this.pos);for(let t=0;t<e.length;t++)if((this.html.charCodeAt(this.pos+t)|32)!==e.charCodeAt(t))return!1;return!0}peek(e){let t=this.pos+e;if(t>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,W.EOF;let n=this.html.charCodeAt(t);return n===W.CARRIAGE_RETURN?W.LINE_FEED:n}advance(){if(this.pos++,this.isEol&&(this.isEol=!1,this.line++,this.lineStartPos=this.pos),this.pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,W.EOF;let e=this.html.charCodeAt(this.pos);return e===W.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,W.LINE_FEED):e===W.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,c_(e)&&(e=this._processSurrogate(e)),this.handler.onParseError===null||e>31&&e<127||e===W.LINE_FEED||e===W.CARRIAGE_RETURN||e>159&&e<64976||this._checkForProblematicCharacters(e),e)}_checkForProblematicCharacters(e){d_(e)?this._err(G.controlCharacterInInputStream):f_(e)&&this._err(G.noncharacterInInputStream)}retreat(e){for(this.pos-=e;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}},h_;(function(e){e[e.CHARACTER=0]=`CHARACTER`,e[e.NULL_CHARACTER=1]=`NULL_CHARACTER`,e[e.WHITESPACE_CHARACTER=2]=`WHITESPACE_CHARACTER`,e[e.START_TAG=3]=`START_TAG`,e[e.END_TAG=4]=`END_TAG`,e[e.COMMENT=5]=`COMMENT`,e[e.DOCTYPE=6]=`DOCTYPE`,e[e.EOF=7]=`EOF`,e[e.HIBERNATION=8]=`HIBERNATION`})(h_||={});function g_(e,t){for(let n=e.attrs.length-1;n>=0;n--)if(e.attrs[n].name===t)return e.attrs[n].value;return null}var __=new Uint16Array(`ᵁ<Õıʊҝջאٵ۞ޢߖࠏ੊ઑඡ๭༉༦჊ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ὾⁠↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms„‹•˜¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲ΂ϏϢϸontourIntegraìȹoɴ͹\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՗՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲ׌y;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱cò׋؀JTabcdfgorstר׬ׯ׺؀ؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d׷׸䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇܎ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ޷޼߂ߐĀiyޱ޵rc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄΀HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶߻dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣ঳সে্਷ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗ࡜ࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४Ānrࢃ࢏gleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpw৔ਖਛgȀLRlr৞৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼੝੠੷੼અઋ઎p;椅y;䐜Ādl੥੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑ඗ඞcy;䐊cute;䅃ƀaey઴હાron;䅇dil;䅅;䐝ƀgswે૰଎ativeƀMTV૓૟૨ediumSpace;怋hiĀcn૦૘ë૙eryThiî૙tedĀGL૸ଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷ଺reak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪୼஡௫ఄ౞಄ದ೘ൡඅ櫬Āou୛୤ngruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊ஛ement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater΀;EFGLSTஶஷ஽௉௓௘௥扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲௽ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ೒拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨೹setĀ;E೰ೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂ෉෕ෛ෠෧෼ขภยา฿ไlig;䅒cute耻Ó䃓Āiy෎ීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲ෶cr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬื฼de耻Õ䃕es;樷ml耻Ö䃖erĀBP๋๠Āar๐๓r;怾acĀek๚๜;揞et;掴arenthesis;揜Ҁacfhilors๿ງຊຏຒດຝະ໼rtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ໠໤檻cedesȀ;EST່້໏໚扺qual;檯lantEqual;扼ilde;找me;怳Ādp໩໮uct;戏ortionĀ;aȥ໹l;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬؀BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁࿫࿳ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL࿜࿝࿡憒ar;懥eftArrow;懄eiling;按oǵ࿹\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»࿝pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄ቉ቕ቞ቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHc቎ቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗Āeiቻ኉Dzኀ\0ኇefore;戴a;䎘Ācn኎ኘkSpace;쀀  Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0᏿ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0጖y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻፿on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtè૙a;䎖r;愨pf;愤cr;쀀𝒵௡ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚΀;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒΀;Eaeiop዁ᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;e዁ᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;e዁ᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰ᜼ᝃᝈ᝸᝽០៦ᠹᡐᜍ᤽᥈ᥰot;櫭Ācrᛶ᜞kȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e᜚᜛戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;t፜᜷brk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓ᝛ᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯ᝱ᝳ;䎲;愶een;扬r;쀀𝔟g΀costuvwឍឝឳេ៕៛៞ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀako៭ᠦᠵĀcn៲ᠣkƀlst៺֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘᠝斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈؀DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬ᣿ᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教΀;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ᣷᣹᣻᣽;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ᤟;敛;敘;攘;攔΀;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģ᥂bar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;e᜚᜜lƀ;bhᥨᥩᥫ䁜;槅sub;柈Ŭᥴ᥾lĀ;e᥹᥺怢t»᥺pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭍᭒\0᯽\0ᰌƀcpr᦭ᦲ᧝ute;䄇̀;abcdsᦿᧀᧄ᧊᧕᧙戩nd;橄rcup;橉Āau᧏᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r΀;Ecefms᩟᩠ᩢᩫ᪤᪪᪮旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖᪚᪟»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇᫔᫺\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ᫙\0\0᫢aĀ;t᫞᫟䀬;䁀ƀ;fl᫨᫩᫫戁îᅠeĀmx᫱᫶ent»᫩eóɍǧ᫾\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯΀delprvw᭠᭬᭷ᮂᮬᯔ᯹arrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;p᭿ᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰸᰻᰿ᱝᱩᱵᲊᲞᲬᲷ᳻᳿ᴍᵻᶑᶫᶻ᷆᷍rò΁ar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂͸᳖᳜᳠mƀ;oș᳊᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄ὎὚ĀDoḆᴴoôᲉĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»Ṻƀaeiἒ἖Ἒls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙ῜ῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao‌⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧‪‬\0‮耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₟₥₰₴⃰⃵⃺⃿℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕ₝ute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽⃉ƀ;qsؾٌ⃄lanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqr׮ⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0↎proø₞r;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢␧␭␱␵␻ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀஀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼rò৆òΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonó྘quigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d྘➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ᠛旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐௏쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop඄⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roø඄urĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻\xA0ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓΀;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨í஘istĀ;s஠டr;쀀𝔫ȀEest௅⩦⩹⩼ƀ;qs஼⩭௡ƀ;qs஼௅⩴lanô௢ií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚΀AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs఻⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs఻⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast୻⭕⭚⭟lleì୻l;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖ΀chimpqu⮽⯍⯙⬄୸⯤⯯Ȁ;cerല⯆ഷ⯉uå൅;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭å೸åഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñ೗Ā;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰⳴ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥ⵲ⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;c᪞ⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācr⵩⵭ir;榿;쀀𝔬ͯ⵹\0\0⵼\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕ⶘ⶥⶨrò᪀Āir⶝ⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔ⷗ǒr;榷rp;榹΀;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ⹞\0⹽\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ⹧⹲຅脀¶;l⹭⹮䂶leìЃɩ⹸\0\0⹻m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳⻴ᤈ⻹⻽⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp໬⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t໻⾴ï໻rel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⿚⋢⿟⿥⿫⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei⿾々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔઀ABHabcdefhilmnoprstux぀けさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤΀cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstw࿜ガクシスゼゾダッデナp;極Ā;f࿠ゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes㄂㄄;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ì࿲âヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘㇤㇮rrowĀ;t࿜ㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowó࿪arpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓rò࿪aòՑ;怏oustĀ;a㈞㈟掱che»㈟mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦΀Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼਴t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì⹯耻­䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;q኱ኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫ਩war;椪lig耻ß䃟௡㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rë๟ƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproø዁im»ኬsðኞĀas㚺㚮ð዁rn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈ΀adempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xô᝷headĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜΀eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roð໻tré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚΀cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜ៟tré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌`.split(``).map(e=>e.charCodeAt(0))),v_=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]);String.fromCodePoint;function y_(e){return e>=55296&&e<=57343||e>1114111?65533:v_.get(e)??e}var b_;(function(e){e[e.NUM=35]=`NUM`,e[e.SEMI=59]=`SEMI`,e[e.EQUALS=61]=`EQUALS`,e[e.ZERO=48]=`ZERO`,e[e.NINE=57]=`NINE`,e[e.LOWER_A=97]=`LOWER_A`,e[e.LOWER_F=102]=`LOWER_F`,e[e.LOWER_X=120]=`LOWER_X`,e[e.LOWER_Z=122]=`LOWER_Z`,e[e.UPPER_A=65]=`UPPER_A`,e[e.UPPER_F=70]=`UPPER_F`,e[e.UPPER_Z=90]=`UPPER_Z`})(b_||={});var x_=32,S_;(function(e){e[e.VALUE_LENGTH=49152]=`VALUE_LENGTH`,e[e.BRANCH_LENGTH=16256]=`BRANCH_LENGTH`,e[e.JUMP_TABLE=127]=`JUMP_TABLE`})(S_||={});function C_(e){return e>=b_.ZERO&&e<=b_.NINE}function w_(e){return e>=b_.UPPER_A&&e<=b_.UPPER_F||e>=b_.LOWER_A&&e<=b_.LOWER_F}function T_(e){return e>=b_.UPPER_A&&e<=b_.UPPER_Z||e>=b_.LOWER_A&&e<=b_.LOWER_Z||C_(e)}function E_(e){return e===b_.EQUALS||T_(e)}var D_;(function(e){e[e.EntityStart=0]=`EntityStart`,e[e.NumericStart=1]=`NumericStart`,e[e.NumericDecimal=2]=`NumericDecimal`,e[e.NumericHex=3]=`NumericHex`,e[e.NamedEntity=4]=`NamedEntity`})(D_||={});var O_;(function(e){e[e.Legacy=0]=`Legacy`,e[e.Strict=1]=`Strict`,e[e.Attribute=2]=`Attribute`})(O_||={});var k_=class{constructor(e,t,n){this.decodeTree=e,this.emitCodePoint=t,this.errors=n,this.state=D_.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=O_.Strict}startEntity(e){this.decodeMode=e,this.state=D_.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(e,t){switch(this.state){case D_.EntityStart:return e.charCodeAt(t)===b_.NUM?(this.state=D_.NumericStart,this.consumed+=1,this.stateNumericStart(e,t+1)):(this.state=D_.NamedEntity,this.stateNamedEntity(e,t));case D_.NumericStart:return this.stateNumericStart(e,t);case D_.NumericDecimal:return this.stateNumericDecimal(e,t);case D_.NumericHex:return this.stateNumericHex(e,t);case D_.NamedEntity:return this.stateNamedEntity(e,t)}}stateNumericStart(e,t){return t>=e.length?-1:(e.charCodeAt(t)|x_)===b_.LOWER_X?(this.state=D_.NumericHex,this.consumed+=1,this.stateNumericHex(e,t+1)):(this.state=D_.NumericDecimal,this.stateNumericDecimal(e,t))}addToNumericResult(e,t,n,r){if(t!==n){let i=n-t;this.result=this.result*r**+i+Number.parseInt(e.substr(t,i),r),this.consumed+=i}}stateNumericHex(e,t){let n=t;for(;t<e.length;){let r=e.charCodeAt(t);if(C_(r)||w_(r))t+=1;else return this.addToNumericResult(e,n,t,16),this.emitNumericEntity(r,3)}return this.addToNumericResult(e,n,t,16),-1}stateNumericDecimal(e,t){let n=t;for(;t<e.length;){let r=e.charCodeAt(t);if(C_(r))t+=1;else return this.addToNumericResult(e,n,t,10),this.emitNumericEntity(r,2)}return this.addToNumericResult(e,n,t,10),-1}emitNumericEntity(e,t){var n;if(this.consumed<=t)return(n=this.errors)==null||n.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(e===b_.SEMI)this.consumed+=1;else if(this.decodeMode===O_.Strict)return 0;return this.emitCodePoint(y_(this.result),this.consumed),this.errors&&(e!==b_.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(e,t){let{decodeTree:n}=this,r=n[this.treeIndex],i=(r&S_.VALUE_LENGTH)>>14;for(;t<e.length;t++,this.excess++){let a=e.charCodeAt(t);if(this.treeIndex=A_(n,r,this.treeIndex+Math.max(1,i),a),this.treeIndex<0)return this.result===0||this.decodeMode===O_.Attribute&&(i===0||E_(a))?0:this.emitNotTerminatedNamedEntity();if(r=n[this.treeIndex],i=(r&S_.VALUE_LENGTH)>>14,i!==0){if(a===b_.SEMI)return this.emitNamedEntityData(this.treeIndex,i,this.consumed+this.excess);this.decodeMode!==O_.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var e;let{result:t,decodeTree:n}=this,r=(n[t]&S_.VALUE_LENGTH)>>14;return this.emitNamedEntityData(t,r,this.consumed),(e=this.errors)==null||e.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(e,t,n){let{decodeTree:r}=this;return this.emitCodePoint(t===1?r[e]&~S_.VALUE_LENGTH:r[e+1],n),t===3&&this.emitCodePoint(r[e+2],n),n}end(){var e;switch(this.state){case D_.NamedEntity:return this.result!==0&&(this.decodeMode!==O_.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case D_.NumericDecimal:return this.emitNumericEntity(0,2);case D_.NumericHex:return this.emitNumericEntity(0,3);case D_.NumericStart:return(e=this.errors)==null||e.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case D_.EntityStart:return 0}}};function A_(e,t,n,r){let i=(t&S_.BRANCH_LENGTH)>>7,a=t&S_.JUMP_TABLE;if(i===0)return a!==0&&r===a?n:-1;if(a){let t=r-a;return t<0||t>=i?-1:e[n+t]-1}let o=n,s=o+i-1;for(;o<=s;){let t=o+s>>>1,n=e[t];if(n<r)o=t+1;else if(n>r)s=t-1;else return e[t+i]}return-1}var K;(function(e){e.HTML=`http://www.w3.org/1999/xhtml`,e.MATHML=`http://www.w3.org/1998/Math/MathML`,e.SVG=`http://www.w3.org/2000/svg`,e.XLINK=`http://www.w3.org/1999/xlink`,e.XML=`http://www.w3.org/XML/1998/namespace`,e.XMLNS=`http://www.w3.org/2000/xmlns/`})(K||={});var j_;(function(e){e.TYPE=`type`,e.ACTION=`action`,e.ENCODING=`encoding`,e.PROMPT=`prompt`,e.NAME=`name`,e.COLOR=`color`,e.FACE=`face`,e.SIZE=`size`})(j_||={});var M_;(function(e){e.NO_QUIRKS=`no-quirks`,e.QUIRKS=`quirks`,e.LIMITED_QUIRKS=`limited-quirks`})(M_||={});var q;(function(e){e.A=`a`,e.ADDRESS=`address`,e.ANNOTATION_XML=`annotation-xml`,e.APPLET=`applet`,e.AREA=`area`,e.ARTICLE=`article`,e.ASIDE=`aside`,e.B=`b`,e.BASE=`base`,e.BASEFONT=`basefont`,e.BGSOUND=`bgsound`,e.BIG=`big`,e.BLOCKQUOTE=`blockquote`,e.BODY=`body`,e.BR=`br`,e.BUTTON=`button`,e.CAPTION=`caption`,e.CENTER=`center`,e.CODE=`code`,e.COL=`col`,e.COLGROUP=`colgroup`,e.DD=`dd`,e.DESC=`desc`,e.DETAILS=`details`,e.DIALOG=`dialog`,e.DIR=`dir`,e.DIV=`div`,e.DL=`dl`,e.DT=`dt`,e.EM=`em`,e.EMBED=`embed`,e.FIELDSET=`fieldset`,e.FIGCAPTION=`figcaption`,e.FIGURE=`figure`,e.FONT=`font`,e.FOOTER=`footer`,e.FOREIGN_OBJECT=`foreignObject`,e.FORM=`form`,e.FRAME=`frame`,e.FRAMESET=`frameset`,e.H1=`h1`,e.H2=`h2`,e.H3=`h3`,e.H4=`h4`,e.H5=`h5`,e.H6=`h6`,e.HEAD=`head`,e.HEADER=`header`,e.HGROUP=`hgroup`,e.HR=`hr`,e.HTML=`html`,e.I=`i`,e.IMG=`img`,e.IMAGE=`image`,e.INPUT=`input`,e.IFRAME=`iframe`,e.KEYGEN=`keygen`,e.LABEL=`label`,e.LI=`li`,e.LINK=`link`,e.LISTING=`listing`,e.MAIN=`main`,e.MALIGNMARK=`malignmark`,e.MARQUEE=`marquee`,e.MATH=`math`,e.MENU=`menu`,e.META=`meta`,e.MGLYPH=`mglyph`,e.MI=`mi`,e.MO=`mo`,e.MN=`mn`,e.MS=`ms`,e.MTEXT=`mtext`,e.NAV=`nav`,e.NOBR=`nobr`,e.NOFRAMES=`noframes`,e.NOEMBED=`noembed`,e.NOSCRIPT=`noscript`,e.OBJECT=`object`,e.OL=`ol`,e.OPTGROUP=`optgroup`,e.OPTION=`option`,e.P=`p`,e.PARAM=`param`,e.PLAINTEXT=`plaintext`,e.PRE=`pre`,e.RB=`rb`,e.RP=`rp`,e.RT=`rt`,e.RTC=`rtc`,e.RUBY=`ruby`,e.S=`s`,e.SCRIPT=`script`,e.SEARCH=`search`,e.SECTION=`section`,e.SELECT=`select`,e.SOURCE=`source`,e.SMALL=`small`,e.SPAN=`span`,e.STRIKE=`strike`,e.STRONG=`strong`,e.STYLE=`style`,e.SUB=`sub`,e.SUMMARY=`summary`,e.SUP=`sup`,e.TABLE=`table`,e.TBODY=`tbody`,e.TEMPLATE=`template`,e.TEXTAREA=`textarea`,e.TFOOT=`tfoot`,e.TD=`td`,e.TH=`th`,e.THEAD=`thead`,e.TITLE=`title`,e.TR=`tr`,e.TRACK=`track`,e.TT=`tt`,e.U=`u`,e.UL=`ul`,e.SVG=`svg`,e.VAR=`var`,e.WBR=`wbr`,e.XMP=`xmp`})(q||={});var J;(function(e){e[e.UNKNOWN=0]=`UNKNOWN`,e[e.A=1]=`A`,e[e.ADDRESS=2]=`ADDRESS`,e[e.ANNOTATION_XML=3]=`ANNOTATION_XML`,e[e.APPLET=4]=`APPLET`,e[e.AREA=5]=`AREA`,e[e.ARTICLE=6]=`ARTICLE`,e[e.ASIDE=7]=`ASIDE`,e[e.B=8]=`B`,e[e.BASE=9]=`BASE`,e[e.BASEFONT=10]=`BASEFONT`,e[e.BGSOUND=11]=`BGSOUND`,e[e.BIG=12]=`BIG`,e[e.BLOCKQUOTE=13]=`BLOCKQUOTE`,e[e.BODY=14]=`BODY`,e[e.BR=15]=`BR`,e[e.BUTTON=16]=`BUTTON`,e[e.CAPTION=17]=`CAPTION`,e[e.CENTER=18]=`CENTER`,e[e.CODE=19]=`CODE`,e[e.COL=20]=`COL`,e[e.COLGROUP=21]=`COLGROUP`,e[e.DD=22]=`DD`,e[e.DESC=23]=`DESC`,e[e.DETAILS=24]=`DETAILS`,e[e.DIALOG=25]=`DIALOG`,e[e.DIR=26]=`DIR`,e[e.DIV=27]=`DIV`,e[e.DL=28]=`DL`,e[e.DT=29]=`DT`,e[e.EM=30]=`EM`,e[e.EMBED=31]=`EMBED`,e[e.FIELDSET=32]=`FIELDSET`,e[e.FIGCAPTION=33]=`FIGCAPTION`,e[e.FIGURE=34]=`FIGURE`,e[e.FONT=35]=`FONT`,e[e.FOOTER=36]=`FOOTER`,e[e.FOREIGN_OBJECT=37]=`FOREIGN_OBJECT`,e[e.FORM=38]=`FORM`,e[e.FRAME=39]=`FRAME`,e[e.FRAMESET=40]=`FRAMESET`,e[e.H1=41]=`H1`,e[e.H2=42]=`H2`,e[e.H3=43]=`H3`,e[e.H4=44]=`H4`,e[e.H5=45]=`H5`,e[e.H6=46]=`H6`,e[e.HEAD=47]=`HEAD`,e[e.HEADER=48]=`HEADER`,e[e.HGROUP=49]=`HGROUP`,e[e.HR=50]=`HR`,e[e.HTML=51]=`HTML`,e[e.I=52]=`I`,e[e.IMG=53]=`IMG`,e[e.IMAGE=54]=`IMAGE`,e[e.INPUT=55]=`INPUT`,e[e.IFRAME=56]=`IFRAME`,e[e.KEYGEN=57]=`KEYGEN`,e[e.LABEL=58]=`LABEL`,e[e.LI=59]=`LI`,e[e.LINK=60]=`LINK`,e[e.LISTING=61]=`LISTING`,e[e.MAIN=62]=`MAIN`,e[e.MALIGNMARK=63]=`MALIGNMARK`,e[e.MARQUEE=64]=`MARQUEE`,e[e.MATH=65]=`MATH`,e[e.MENU=66]=`MENU`,e[e.META=67]=`META`,e[e.MGLYPH=68]=`MGLYPH`,e[e.MI=69]=`MI`,e[e.MO=70]=`MO`,e[e.MN=71]=`MN`,e[e.MS=72]=`MS`,e[e.MTEXT=73]=`MTEXT`,e[e.NAV=74]=`NAV`,e[e.NOBR=75]=`NOBR`,e[e.NOFRAMES=76]=`NOFRAMES`,e[e.NOEMBED=77]=`NOEMBED`,e[e.NOSCRIPT=78]=`NOSCRIPT`,e[e.OBJECT=79]=`OBJECT`,e[e.OL=80]=`OL`,e[e.OPTGROUP=81]=`OPTGROUP`,e[e.OPTION=82]=`OPTION`,e[e.P=83]=`P`,e[e.PARAM=84]=`PARAM`,e[e.PLAINTEXT=85]=`PLAINTEXT`,e[e.PRE=86]=`PRE`,e[e.RB=87]=`RB`,e[e.RP=88]=`RP`,e[e.RT=89]=`RT`,e[e.RTC=90]=`RTC`,e[e.RUBY=91]=`RUBY`,e[e.S=92]=`S`,e[e.SCRIPT=93]=`SCRIPT`,e[e.SEARCH=94]=`SEARCH`,e[e.SECTION=95]=`SECTION`,e[e.SELECT=96]=`SELECT`,e[e.SOURCE=97]=`SOURCE`,e[e.SMALL=98]=`SMALL`,e[e.SPAN=99]=`SPAN`,e[e.STRIKE=100]=`STRIKE`,e[e.STRONG=101]=`STRONG`,e[e.STYLE=102]=`STYLE`,e[e.SUB=103]=`SUB`,e[e.SUMMARY=104]=`SUMMARY`,e[e.SUP=105]=`SUP`,e[e.TABLE=106]=`TABLE`,e[e.TBODY=107]=`TBODY`,e[e.TEMPLATE=108]=`TEMPLATE`,e[e.TEXTAREA=109]=`TEXTAREA`,e[e.TFOOT=110]=`TFOOT`,e[e.TD=111]=`TD`,e[e.TH=112]=`TH`,e[e.THEAD=113]=`THEAD`,e[e.TITLE=114]=`TITLE`,e[e.TR=115]=`TR`,e[e.TRACK=116]=`TRACK`,e[e.TT=117]=`TT`,e[e.U=118]=`U`,e[e.UL=119]=`UL`,e[e.SVG=120]=`SVG`,e[e.VAR=121]=`VAR`,e[e.WBR=122]=`WBR`,e[e.XMP=123]=`XMP`})(J||={});var N_=new Map([[q.A,J.A],[q.ADDRESS,J.ADDRESS],[q.ANNOTATION_XML,J.ANNOTATION_XML],[q.APPLET,J.APPLET],[q.AREA,J.AREA],[q.ARTICLE,J.ARTICLE],[q.ASIDE,J.ASIDE],[q.B,J.B],[q.BASE,J.BASE],[q.BASEFONT,J.BASEFONT],[q.BGSOUND,J.BGSOUND],[q.BIG,J.BIG],[q.BLOCKQUOTE,J.BLOCKQUOTE],[q.BODY,J.BODY],[q.BR,J.BR],[q.BUTTON,J.BUTTON],[q.CAPTION,J.CAPTION],[q.CENTER,J.CENTER],[q.CODE,J.CODE],[q.COL,J.COL],[q.COLGROUP,J.COLGROUP],[q.DD,J.DD],[q.DESC,J.DESC],[q.DETAILS,J.DETAILS],[q.DIALOG,J.DIALOG],[q.DIR,J.DIR],[q.DIV,J.DIV],[q.DL,J.DL],[q.DT,J.DT],[q.EM,J.EM],[q.EMBED,J.EMBED],[q.FIELDSET,J.FIELDSET],[q.FIGCAPTION,J.FIGCAPTION],[q.FIGURE,J.FIGURE],[q.FONT,J.FONT],[q.FOOTER,J.FOOTER],[q.FOREIGN_OBJECT,J.FOREIGN_OBJECT],[q.FORM,J.FORM],[q.FRAME,J.FRAME],[q.FRAMESET,J.FRAMESET],[q.H1,J.H1],[q.H2,J.H2],[q.H3,J.H3],[q.H4,J.H4],[q.H5,J.H5],[q.H6,J.H6],[q.HEAD,J.HEAD],[q.HEADER,J.HEADER],[q.HGROUP,J.HGROUP],[q.HR,J.HR],[q.HTML,J.HTML],[q.I,J.I],[q.IMG,J.IMG],[q.IMAGE,J.IMAGE],[q.INPUT,J.INPUT],[q.IFRAME,J.IFRAME],[q.KEYGEN,J.KEYGEN],[q.LABEL,J.LABEL],[q.LI,J.LI],[q.LINK,J.LINK],[q.LISTING,J.LISTING],[q.MAIN,J.MAIN],[q.MALIGNMARK,J.MALIGNMARK],[q.MARQUEE,J.MARQUEE],[q.MATH,J.MATH],[q.MENU,J.MENU],[q.META,J.META],[q.MGLYPH,J.MGLYPH],[q.MI,J.MI],[q.MO,J.MO],[q.MN,J.MN],[q.MS,J.MS],[q.MTEXT,J.MTEXT],[q.NAV,J.NAV],[q.NOBR,J.NOBR],[q.NOFRAMES,J.NOFRAMES],[q.NOEMBED,J.NOEMBED],[q.NOSCRIPT,J.NOSCRIPT],[q.OBJECT,J.OBJECT],[q.OL,J.OL],[q.OPTGROUP,J.OPTGROUP],[q.OPTION,J.OPTION],[q.P,J.P],[q.PARAM,J.PARAM],[q.PLAINTEXT,J.PLAINTEXT],[q.PRE,J.PRE],[q.RB,J.RB],[q.RP,J.RP],[q.RT,J.RT],[q.RTC,J.RTC],[q.RUBY,J.RUBY],[q.S,J.S],[q.SCRIPT,J.SCRIPT],[q.SEARCH,J.SEARCH],[q.SECTION,J.SECTION],[q.SELECT,J.SELECT],[q.SOURCE,J.SOURCE],[q.SMALL,J.SMALL],[q.SPAN,J.SPAN],[q.STRIKE,J.STRIKE],[q.STRONG,J.STRONG],[q.STYLE,J.STYLE],[q.SUB,J.SUB],[q.SUMMARY,J.SUMMARY],[q.SUP,J.SUP],[q.TABLE,J.TABLE],[q.TBODY,J.TBODY],[q.TEMPLATE,J.TEMPLATE],[q.TEXTAREA,J.TEXTAREA],[q.TFOOT,J.TFOOT],[q.TD,J.TD],[q.TH,J.TH],[q.THEAD,J.THEAD],[q.TITLE,J.TITLE],[q.TR,J.TR],[q.TRACK,J.TRACK],[q.TT,J.TT],[q.U,J.U],[q.UL,J.UL],[q.SVG,J.SVG],[q.VAR,J.VAR],[q.WBR,J.WBR],[q.XMP,J.XMP]]);function P_(e){return N_.get(e)??J.UNKNOWN}var Y=J,F_={[K.HTML]:new Set([Y.ADDRESS,Y.APPLET,Y.AREA,Y.ARTICLE,Y.ASIDE,Y.BASE,Y.BASEFONT,Y.BGSOUND,Y.BLOCKQUOTE,Y.BODY,Y.BR,Y.BUTTON,Y.CAPTION,Y.CENTER,Y.COL,Y.COLGROUP,Y.DD,Y.DETAILS,Y.DIR,Y.DIV,Y.DL,Y.DT,Y.EMBED,Y.FIELDSET,Y.FIGCAPTION,Y.FIGURE,Y.FOOTER,Y.FORM,Y.FRAME,Y.FRAMESET,Y.H1,Y.H2,Y.H3,Y.H4,Y.H5,Y.H6,Y.HEAD,Y.HEADER,Y.HGROUP,Y.HR,Y.HTML,Y.IFRAME,Y.IMG,Y.INPUT,Y.LI,Y.LINK,Y.LISTING,Y.MAIN,Y.MARQUEE,Y.MENU,Y.META,Y.NAV,Y.NOEMBED,Y.NOFRAMES,Y.NOSCRIPT,Y.OBJECT,Y.OL,Y.P,Y.PARAM,Y.PLAINTEXT,Y.PRE,Y.SCRIPT,Y.SECTION,Y.SELECT,Y.SOURCE,Y.STYLE,Y.SUMMARY,Y.TABLE,Y.TBODY,Y.TD,Y.TEMPLATE,Y.TEXTAREA,Y.TFOOT,Y.TH,Y.THEAD,Y.TITLE,Y.TR,Y.TRACK,Y.UL,Y.WBR,Y.XMP]),[K.MATHML]:new Set([Y.MI,Y.MO,Y.MN,Y.MS,Y.MTEXT,Y.ANNOTATION_XML]),[K.SVG]:new Set([Y.TITLE,Y.FOREIGN_OBJECT,Y.DESC]),[K.XLINK]:new Set,[K.XML]:new Set,[K.XMLNS]:new Set},I_=new Set([Y.H1,Y.H2,Y.H3,Y.H4,Y.H5,Y.H6]);new Set([q.STYLE,q.SCRIPT,q.XMP,q.IFRAME,q.NOEMBED,q.NOFRAMES,q.PLAINTEXT]);var X;(function(e){e[e.DATA=0]=`DATA`,e[e.RCDATA=1]=`RCDATA`,e[e.RAWTEXT=2]=`RAWTEXT`,e[e.SCRIPT_DATA=3]=`SCRIPT_DATA`,e[e.PLAINTEXT=4]=`PLAINTEXT`,e[e.TAG_OPEN=5]=`TAG_OPEN`,e[e.END_TAG_OPEN=6]=`END_TAG_OPEN`,e[e.TAG_NAME=7]=`TAG_NAME`,e[e.RCDATA_LESS_THAN_SIGN=8]=`RCDATA_LESS_THAN_SIGN`,e[e.RCDATA_END_TAG_OPEN=9]=`RCDATA_END_TAG_OPEN`,e[e.RCDATA_END_TAG_NAME=10]=`RCDATA_END_TAG_NAME`,e[e.RAWTEXT_LESS_THAN_SIGN=11]=`RAWTEXT_LESS_THAN_SIGN`,e[e.RAWTEXT_END_TAG_OPEN=12]=`RAWTEXT_END_TAG_OPEN`,e[e.RAWTEXT_END_TAG_NAME=13]=`RAWTEXT_END_TAG_NAME`,e[e.SCRIPT_DATA_LESS_THAN_SIGN=14]=`SCRIPT_DATA_LESS_THAN_SIGN`,e[e.SCRIPT_DATA_END_TAG_OPEN=15]=`SCRIPT_DATA_END_TAG_OPEN`,e[e.SCRIPT_DATA_END_TAG_NAME=16]=`SCRIPT_DATA_END_TAG_NAME`,e[e.SCRIPT_DATA_ESCAPE_START=17]=`SCRIPT_DATA_ESCAPE_START`,e[e.SCRIPT_DATA_ESCAPE_START_DASH=18]=`SCRIPT_DATA_ESCAPE_START_DASH`,e[e.SCRIPT_DATA_ESCAPED=19]=`SCRIPT_DATA_ESCAPED`,e[e.SCRIPT_DATA_ESCAPED_DASH=20]=`SCRIPT_DATA_ESCAPED_DASH`,e[e.SCRIPT_DATA_ESCAPED_DASH_DASH=21]=`SCRIPT_DATA_ESCAPED_DASH_DASH`,e[e.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN=22]=`SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN`,e[e.SCRIPT_DATA_ESCAPED_END_TAG_OPEN=23]=`SCRIPT_DATA_ESCAPED_END_TAG_OPEN`,e[e.SCRIPT_DATA_ESCAPED_END_TAG_NAME=24]=`SCRIPT_DATA_ESCAPED_END_TAG_NAME`,e[e.SCRIPT_DATA_DOUBLE_ESCAPE_START=25]=`SCRIPT_DATA_DOUBLE_ESCAPE_START`,e[e.SCRIPT_DATA_DOUBLE_ESCAPED=26]=`SCRIPT_DATA_DOUBLE_ESCAPED`,e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH=27]=`SCRIPT_DATA_DOUBLE_ESCAPED_DASH`,e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH=28]=`SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH`,e[e.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN=29]=`SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN`,e[e.SCRIPT_DATA_DOUBLE_ESCAPE_END=30]=`SCRIPT_DATA_DOUBLE_ESCAPE_END`,e[e.BEFORE_ATTRIBUTE_NAME=31]=`BEFORE_ATTRIBUTE_NAME`,e[e.ATTRIBUTE_NAME=32]=`ATTRIBUTE_NAME`,e[e.AFTER_ATTRIBUTE_NAME=33]=`AFTER_ATTRIBUTE_NAME`,e[e.BEFORE_ATTRIBUTE_VALUE=34]=`BEFORE_ATTRIBUTE_VALUE`,e[e.ATTRIBUTE_VALUE_DOUBLE_QUOTED=35]=`ATTRIBUTE_VALUE_DOUBLE_QUOTED`,e[e.ATTRIBUTE_VALUE_SINGLE_QUOTED=36]=`ATTRIBUTE_VALUE_SINGLE_QUOTED`,e[e.ATTRIBUTE_VALUE_UNQUOTED=37]=`ATTRIBUTE_VALUE_UNQUOTED`,e[e.AFTER_ATTRIBUTE_VALUE_QUOTED=38]=`AFTER_ATTRIBUTE_VALUE_QUOTED`,e[e.SELF_CLOSING_START_TAG=39]=`SELF_CLOSING_START_TAG`,e[e.BOGUS_COMMENT=40]=`BOGUS_COMMENT`,e[e.MARKUP_DECLARATION_OPEN=41]=`MARKUP_DECLARATION_OPEN`,e[e.COMMENT_START=42]=`COMMENT_START`,e[e.COMMENT_START_DASH=43]=`COMMENT_START_DASH`,e[e.COMMENT=44]=`COMMENT`,e[e.COMMENT_LESS_THAN_SIGN=45]=`COMMENT_LESS_THAN_SIGN`,e[e.COMMENT_LESS_THAN_SIGN_BANG=46]=`COMMENT_LESS_THAN_SIGN_BANG`,e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH=47]=`COMMENT_LESS_THAN_SIGN_BANG_DASH`,e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH=48]=`COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH`,e[e.COMMENT_END_DASH=49]=`COMMENT_END_DASH`,e[e.COMMENT_END=50]=`COMMENT_END`,e[e.COMMENT_END_BANG=51]=`COMMENT_END_BANG`,e[e.DOCTYPE=52]=`DOCTYPE`,e[e.BEFORE_DOCTYPE_NAME=53]=`BEFORE_DOCTYPE_NAME`,e[e.DOCTYPE_NAME=54]=`DOCTYPE_NAME`,e[e.AFTER_DOCTYPE_NAME=55]=`AFTER_DOCTYPE_NAME`,e[e.AFTER_DOCTYPE_PUBLIC_KEYWORD=56]=`AFTER_DOCTYPE_PUBLIC_KEYWORD`,e[e.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER=57]=`BEFORE_DOCTYPE_PUBLIC_IDENTIFIER`,e[e.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED=58]=`DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED`,e[e.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED=59]=`DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED`,e[e.AFTER_DOCTYPE_PUBLIC_IDENTIFIER=60]=`AFTER_DOCTYPE_PUBLIC_IDENTIFIER`,e[e.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS=61]=`BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS`,e[e.AFTER_DOCTYPE_SYSTEM_KEYWORD=62]=`AFTER_DOCTYPE_SYSTEM_KEYWORD`,e[e.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER=63]=`BEFORE_DOCTYPE_SYSTEM_IDENTIFIER`,e[e.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED=64]=`DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED`,e[e.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED=65]=`DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED`,e[e.AFTER_DOCTYPE_SYSTEM_IDENTIFIER=66]=`AFTER_DOCTYPE_SYSTEM_IDENTIFIER`,e[e.BOGUS_DOCTYPE=67]=`BOGUS_DOCTYPE`,e[e.CDATA_SECTION=68]=`CDATA_SECTION`,e[e.CDATA_SECTION_BRACKET=69]=`CDATA_SECTION_BRACKET`,e[e.CDATA_SECTION_END=70]=`CDATA_SECTION_END`,e[e.CHARACTER_REFERENCE=71]=`CHARACTER_REFERENCE`,e[e.AMBIGUOUS_AMPERSAND=72]=`AMBIGUOUS_AMPERSAND`})(X||={});var L_={DATA:X.DATA,RCDATA:X.RCDATA,RAWTEXT:X.RAWTEXT,SCRIPT_DATA:X.SCRIPT_DATA,PLAINTEXT:X.PLAINTEXT,CDATA_SECTION:X.CDATA_SECTION};function R_(e){return e>=W.DIGIT_0&&e<=W.DIGIT_9}function z_(e){return e>=W.LATIN_CAPITAL_A&&e<=W.LATIN_CAPITAL_Z}function B_(e){return e>=W.LATIN_SMALL_A&&e<=W.LATIN_SMALL_Z}function V_(e){return B_(e)||z_(e)}function H_(e){return V_(e)||R_(e)}function U_(e){return e+32}function W_(e){return e===W.SPACE||e===W.LINE_FEED||e===W.TABULATION||e===W.FORM_FEED}function G_(e){return W_(e)||e===W.SOLIDUS||e===W.GREATER_THAN_SIGN}function K_(e){return e===W.NULL?G.nullCharacterReference:e>1114111?G.characterReferenceOutsideUnicodeRange:c_(e)?G.surrogateCharacterReference:f_(e)?G.noncharacterCharacterReference:d_(e)||e===W.CARRIAGE_RETURN?G.controlCharacterReference:null}var q_=class{constructor(e,t){this.options=e,this.handler=t,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName=``,this.active=!1,this.state=X.DATA,this.returnState=X.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:``,value:``},this.preprocessor=new m_(t),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new k_(__,(e,t)=>{this.preprocessor.pos=this.entityStartPos+t-1,this._flushCodePointConsumedAsCharacterReference(e)},t.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(G.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:e=>{this._err(G.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+e)},validateNumericCharacterReference:e=>{let t=K_(e);t&&this._err(t,1)}}:void 0)}_err(e,t=0){var n,r;(r=(n=this.handler).onParseError)==null||r.call(n,this.preprocessor.getError(e,t))}getCurrentLocation(e){return this.options.sourceCodeLocationInfo?{startLine:this.preprocessor.line,startCol:this.preprocessor.col-e,startOffset:this.preprocessor.offset-e,endLine:-1,endCol:-1,endOffset:-1}:null}_runParsingLoop(){if(!this.inLoop){for(this.inLoop=!0;this.active&&!this.paused;){this.consumedAfterSnapshot=0;let e=this._consume();this._ensureHibernation()||this._callState(e)}this.inLoop=!1}}pause(){this.paused=!0}resume(e){if(!this.paused)throw Error(`Parser was already resumed`);this.paused=!1,!this.inLoop&&(this._runParsingLoop(),this.paused||e?.())}write(e,t,n){this.active=!0,this.preprocessor.write(e,t),this._runParsingLoop(),this.paused||n?.()}insertHtmlAtCurrentPos(e){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(e),this._runParsingLoop()}_ensureHibernation(){return this.preprocessor.endOfChunkHit?(this.preprocessor.retreat(this.consumedAfterSnapshot),this.consumedAfterSnapshot=0,this.active=!1,!0):!1}_consume(){return this.consumedAfterSnapshot++,this.preprocessor.advance()}_advanceBy(e){this.consumedAfterSnapshot+=e;for(let t=0;t<e;t++)this.preprocessor.advance()}_consumeSequenceIfMatch(e,t){return this.preprocessor.startsWith(e,t)?(this._advanceBy(e.length-1),!0):!1}_createStartTagToken(){this.currentToken={type:h_.START_TAG,tagName:``,tagID:J.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:h_.END_TAG,tagName:``,tagID:J.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(e){this.currentToken={type:h_.COMMENT,data:``,location:this.getCurrentLocation(e)}}_createDoctypeToken(e){this.currentToken={type:h_.DOCTYPE,name:e,forceQuirks:!1,publicId:null,systemId:null,location:this.currentLocation}}_createCharacterToken(e,t){this.currentCharacterToken={type:e,chars:t,location:this.currentLocation}}_createAttr(e){this.currentAttr={name:e,value:``},this.currentLocation=this.getCurrentLocation(0)}_leaveAttrName(){var e;let t=this.currentToken;if(g_(t,this.currentAttr.name)===null){if(t.attrs.push(this.currentAttr),t.location&&this.currentLocation){let n=(e=t.location).attrs??(e.attrs=Object.create(null));n[this.currentAttr.name]=this.currentLocation,this._leaveAttrValue()}}else this._err(G.duplicateAttribute)}_leaveAttrValue(){this.currentLocation&&(this.currentLocation.endLine=this.preprocessor.line,this.currentLocation.endCol=this.preprocessor.col,this.currentLocation.endOffset=this.preprocessor.offset)}prepareToken(e){this._emitCurrentCharacterToken(e.location),this.currentToken=null,e.location&&(e.location.endLine=this.preprocessor.line,e.location.endCol=this.preprocessor.col+1,e.location.endOffset=this.preprocessor.offset+1),this.currentLocation=this.getCurrentLocation(-1)}emitCurrentTagToken(){let e=this.currentToken;this.prepareToken(e),e.tagID=P_(e.tagName),e.type===h_.START_TAG?(this.lastStartTagName=e.tagName,this.handler.onStartTag(e)):(e.attrs.length>0&&this._err(G.endTagWithAttributes),e.selfClosing&&this._err(G.endTagWithTrailingSolidus),this.handler.onEndTag(e)),this.preprocessor.dropParsedChunk()}emitCurrentComment(e){this.prepareToken(e),this.handler.onComment(e),this.preprocessor.dropParsedChunk()}emitCurrentDoctype(e){this.prepareToken(e),this.handler.onDoctype(e),this.preprocessor.dropParsedChunk()}_emitCurrentCharacterToken(e){if(this.currentCharacterToken){switch(e&&this.currentCharacterToken.location&&(this.currentCharacterToken.location.endLine=e.startLine,this.currentCharacterToken.location.endCol=e.startCol,this.currentCharacterToken.location.endOffset=e.startOffset),this.currentCharacterToken.type){case h_.CHARACTER:this.handler.onCharacter(this.currentCharacterToken);break;case h_.NULL_CHARACTER:this.handler.onNullCharacter(this.currentCharacterToken);break;case h_.WHITESPACE_CHARACTER:this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}this.currentCharacterToken=null}}_emitEOFToken(){let e=this.getCurrentLocation(0);e&&(e.endLine=e.startLine,e.endCol=e.startCol,e.endOffset=e.startOffset),this._emitCurrentCharacterToken(e),this.handler.onEof({type:h_.EOF,location:e}),this.active=!1}_appendCharToCurrentCharacterToken(e,t){if(this.currentCharacterToken)if(this.currentCharacterToken.type===e){this.currentCharacterToken.chars+=t;return}else this.currentLocation=this.getCurrentLocation(0),this._emitCurrentCharacterToken(this.currentLocation),this.preprocessor.dropParsedChunk();this._createCharacterToken(e,t)}_emitCodePoint(e){let t=W_(e)?h_.WHITESPACE_CHARACTER:e===W.NULL?h_.NULL_CHARACTER:h_.CHARACTER;this._appendCharToCurrentCharacterToken(t,String.fromCodePoint(e))}_emitChars(e){this._appendCharToCurrentCharacterToken(h_.CHARACTER,e)}_startCharacterReference(){this.returnState=this.state,this.state=X.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?O_.Attribute:O_.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===X.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===X.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===X.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(e){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(e):this._emitCodePoint(e)}_callState(e){switch(this.state){case X.DATA:this._stateData(e);break;case X.RCDATA:this._stateRcdata(e);break;case X.RAWTEXT:this._stateRawtext(e);break;case X.SCRIPT_DATA:this._stateScriptData(e);break;case X.PLAINTEXT:this._statePlaintext(e);break;case X.TAG_OPEN:this._stateTagOpen(e);break;case X.END_TAG_OPEN:this._stateEndTagOpen(e);break;case X.TAG_NAME:this._stateTagName(e);break;case X.RCDATA_LESS_THAN_SIGN:this._stateRcdataLessThanSign(e);break;case X.RCDATA_END_TAG_OPEN:this._stateRcdataEndTagOpen(e);break;case X.RCDATA_END_TAG_NAME:this._stateRcdataEndTagName(e);break;case X.RAWTEXT_LESS_THAN_SIGN:this._stateRawtextLessThanSign(e);break;case X.RAWTEXT_END_TAG_OPEN:this._stateRawtextEndTagOpen(e);break;case X.RAWTEXT_END_TAG_NAME:this._stateRawtextEndTagName(e);break;case X.SCRIPT_DATA_LESS_THAN_SIGN:this._stateScriptDataLessThanSign(e);break;case X.SCRIPT_DATA_END_TAG_OPEN:this._stateScriptDataEndTagOpen(e);break;case X.SCRIPT_DATA_END_TAG_NAME:this._stateScriptDataEndTagName(e);break;case X.SCRIPT_DATA_ESCAPE_START:this._stateScriptDataEscapeStart(e);break;case X.SCRIPT_DATA_ESCAPE_START_DASH:this._stateScriptDataEscapeStartDash(e);break;case X.SCRIPT_DATA_ESCAPED:this._stateScriptDataEscaped(e);break;case X.SCRIPT_DATA_ESCAPED_DASH:this._stateScriptDataEscapedDash(e);break;case X.SCRIPT_DATA_ESCAPED_DASH_DASH:this._stateScriptDataEscapedDashDash(e);break;case X.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:this._stateScriptDataEscapedLessThanSign(e);break;case X.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:this._stateScriptDataEscapedEndTagOpen(e);break;case X.SCRIPT_DATA_ESCAPED_END_TAG_NAME:this._stateScriptDataEscapedEndTagName(e);break;case X.SCRIPT_DATA_DOUBLE_ESCAPE_START:this._stateScriptDataDoubleEscapeStart(e);break;case X.SCRIPT_DATA_DOUBLE_ESCAPED:this._stateScriptDataDoubleEscaped(e);break;case X.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:this._stateScriptDataDoubleEscapedDash(e);break;case X.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:this._stateScriptDataDoubleEscapedDashDash(e);break;case X.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:this._stateScriptDataDoubleEscapedLessThanSign(e);break;case X.SCRIPT_DATA_DOUBLE_ESCAPE_END:this._stateScriptDataDoubleEscapeEnd(e);break;case X.BEFORE_ATTRIBUTE_NAME:this._stateBeforeAttributeName(e);break;case X.ATTRIBUTE_NAME:this._stateAttributeName(e);break;case X.AFTER_ATTRIBUTE_NAME:this._stateAfterAttributeName(e);break;case X.BEFORE_ATTRIBUTE_VALUE:this._stateBeforeAttributeValue(e);break;case X.ATTRIBUTE_VALUE_DOUBLE_QUOTED:this._stateAttributeValueDoubleQuoted(e);break;case X.ATTRIBUTE_VALUE_SINGLE_QUOTED:this._stateAttributeValueSingleQuoted(e);break;case X.ATTRIBUTE_VALUE_UNQUOTED:this._stateAttributeValueUnquoted(e);break;case X.AFTER_ATTRIBUTE_VALUE_QUOTED:this._stateAfterAttributeValueQuoted(e);break;case X.SELF_CLOSING_START_TAG:this._stateSelfClosingStartTag(e);break;case X.BOGUS_COMMENT:this._stateBogusComment(e);break;case X.MARKUP_DECLARATION_OPEN:this._stateMarkupDeclarationOpen(e);break;case X.COMMENT_START:this._stateCommentStart(e);break;case X.COMMENT_START_DASH:this._stateCommentStartDash(e);break;case X.COMMENT:this._stateComment(e);break;case X.COMMENT_LESS_THAN_SIGN:this._stateCommentLessThanSign(e);break;case X.COMMENT_LESS_THAN_SIGN_BANG:this._stateCommentLessThanSignBang(e);break;case X.COMMENT_LESS_THAN_SIGN_BANG_DASH:this._stateCommentLessThanSignBangDash(e);break;case X.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:this._stateCommentLessThanSignBangDashDash(e);break;case X.COMMENT_END_DASH:this._stateCommentEndDash(e);break;case X.COMMENT_END:this._stateCommentEnd(e);break;case X.COMMENT_END_BANG:this._stateCommentEndBang(e);break;case X.DOCTYPE:this._stateDoctype(e);break;case X.BEFORE_DOCTYPE_NAME:this._stateBeforeDoctypeName(e);break;case X.DOCTYPE_NAME:this._stateDoctypeName(e);break;case X.AFTER_DOCTYPE_NAME:this._stateAfterDoctypeName(e);break;case X.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._stateAfterDoctypePublicKeyword(e);break;case X.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:this._stateBeforeDoctypePublicIdentifier(e);break;case X.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:this._stateDoctypePublicIdentifierDoubleQuoted(e);break;case X.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:this._stateDoctypePublicIdentifierSingleQuoted(e);break;case X.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:this._stateAfterDoctypePublicIdentifier(e);break;case X.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:this._stateBetweenDoctypePublicAndSystemIdentifiers(e);break;case X.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._stateAfterDoctypeSystemKeyword(e);break;case X.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:this._stateBeforeDoctypeSystemIdentifier(e);break;case X.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:this._stateDoctypeSystemIdentifierDoubleQuoted(e);break;case X.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:this._stateDoctypeSystemIdentifierSingleQuoted(e);break;case X.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:this._stateAfterDoctypeSystemIdentifier(e);break;case X.BOGUS_DOCTYPE:this._stateBogusDoctype(e);break;case X.CDATA_SECTION:this._stateCdataSection(e);break;case X.CDATA_SECTION_BRACKET:this._stateCdataSectionBracket(e);break;case X.CDATA_SECTION_END:this._stateCdataSectionEnd(e);break;case X.CHARACTER_REFERENCE:this._stateCharacterReference();break;case X.AMBIGUOUS_AMPERSAND:this._stateAmbiguousAmpersand(e);break;default:throw Error(`Unknown state`)}}_stateData(e){switch(e){case W.LESS_THAN_SIGN:this.state=X.TAG_OPEN;break;case W.AMPERSAND:this._startCharacterReference();break;case W.NULL:this._err(G.unexpectedNullCharacter),this._emitCodePoint(e);break;case W.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateRcdata(e){switch(e){case W.AMPERSAND:this._startCharacterReference();break;case W.LESS_THAN_SIGN:this.state=X.RCDATA_LESS_THAN_SIGN;break;case W.NULL:this._err(G.unexpectedNullCharacter),this._emitChars(`�`);break;case W.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateRawtext(e){switch(e){case W.LESS_THAN_SIGN:this.state=X.RAWTEXT_LESS_THAN_SIGN;break;case W.NULL:this._err(G.unexpectedNullCharacter),this._emitChars(`�`);break;case W.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateScriptData(e){switch(e){case W.LESS_THAN_SIGN:this.state=X.SCRIPT_DATA_LESS_THAN_SIGN;break;case W.NULL:this._err(G.unexpectedNullCharacter),this._emitChars(`�`);break;case W.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_statePlaintext(e){switch(e){case W.NULL:this._err(G.unexpectedNullCharacter),this._emitChars(`�`);break;case W.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateTagOpen(e){if(V_(e))this._createStartTagToken(),this.state=X.TAG_NAME,this._stateTagName(e);else switch(e){case W.EXCLAMATION_MARK:this.state=X.MARKUP_DECLARATION_OPEN;break;case W.SOLIDUS:this.state=X.END_TAG_OPEN;break;case W.QUESTION_MARK:this._err(G.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=X.BOGUS_COMMENT,this._stateBogusComment(e);break;case W.EOF:this._err(G.eofBeforeTagName),this._emitChars(`<`),this._emitEOFToken();break;default:this._err(G.invalidFirstCharacterOfTagName),this._emitChars(`<`),this.state=X.DATA,this._stateData(e)}}_stateEndTagOpen(e){if(V_(e))this._createEndTagToken(),this.state=X.TAG_NAME,this._stateTagName(e);else switch(e){case W.GREATER_THAN_SIGN:this._err(G.missingEndTagName),this.state=X.DATA;break;case W.EOF:this._err(G.eofBeforeTagName),this._emitChars(`</`),this._emitEOFToken();break;default:this._err(G.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=X.BOGUS_COMMENT,this._stateBogusComment(e)}}_stateTagName(e){let t=this.currentToken;switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:this.state=X.BEFORE_ATTRIBUTE_NAME;break;case W.SOLIDUS:this.state=X.SELF_CLOSING_START_TAG;break;case W.GREATER_THAN_SIGN:this.state=X.DATA,this.emitCurrentTagToken();break;case W.NULL:this._err(G.unexpectedNullCharacter),t.tagName+=`�`;break;case W.EOF:this._err(G.eofInTag),this._emitEOFToken();break;default:t.tagName+=String.fromCodePoint(z_(e)?U_(e):e)}}_stateRcdataLessThanSign(e){e===W.SOLIDUS?this.state=X.RCDATA_END_TAG_OPEN:(this._emitChars(`<`),this.state=X.RCDATA,this._stateRcdata(e))}_stateRcdataEndTagOpen(e){V_(e)?(this.state=X.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(e)):(this._emitChars(`</`),this.state=X.RCDATA,this._stateRcdata(e))}handleSpecialEndTag(e){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();let t=this.currentToken;switch(t.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=X.BEFORE_ATTRIBUTE_NAME,!1;case W.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=X.SELF_CLOSING_START_TAG,!1;case W.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=X.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(e){this.handleSpecialEndTag(e)&&(this._emitChars(`</`),this.state=X.RCDATA,this._stateRcdata(e))}_stateRawtextLessThanSign(e){e===W.SOLIDUS?this.state=X.RAWTEXT_END_TAG_OPEN:(this._emitChars(`<`),this.state=X.RAWTEXT,this._stateRawtext(e))}_stateRawtextEndTagOpen(e){V_(e)?(this.state=X.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(e)):(this._emitChars(`</`),this.state=X.RAWTEXT,this._stateRawtext(e))}_stateRawtextEndTagName(e){this.handleSpecialEndTag(e)&&(this._emitChars(`</`),this.state=X.RAWTEXT,this._stateRawtext(e))}_stateScriptDataLessThanSign(e){switch(e){case W.SOLIDUS:this.state=X.SCRIPT_DATA_END_TAG_OPEN;break;case W.EXCLAMATION_MARK:this.state=X.SCRIPT_DATA_ESCAPE_START,this._emitChars(`<!`);break;default:this._emitChars(`<`),this.state=X.SCRIPT_DATA,this._stateScriptData(e)}}_stateScriptDataEndTagOpen(e){V_(e)?(this.state=X.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(e)):(this._emitChars(`</`),this.state=X.SCRIPT_DATA,this._stateScriptData(e))}_stateScriptDataEndTagName(e){this.handleSpecialEndTag(e)&&(this._emitChars(`</`),this.state=X.SCRIPT_DATA,this._stateScriptData(e))}_stateScriptDataEscapeStart(e){e===W.HYPHEN_MINUS?(this.state=X.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars(`-`)):(this.state=X.SCRIPT_DATA,this._stateScriptData(e))}_stateScriptDataEscapeStartDash(e){e===W.HYPHEN_MINUS?(this.state=X.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars(`-`)):(this.state=X.SCRIPT_DATA,this._stateScriptData(e))}_stateScriptDataEscaped(e){switch(e){case W.HYPHEN_MINUS:this.state=X.SCRIPT_DATA_ESCAPED_DASH,this._emitChars(`-`);break;case W.LESS_THAN_SIGN:this.state=X.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break;case W.NULL:this._err(G.unexpectedNullCharacter),this._emitChars(`�`);break;case W.EOF:this._err(G.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateScriptDataEscapedDash(e){switch(e){case W.HYPHEN_MINUS:this.state=X.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars(`-`);break;case W.LESS_THAN_SIGN:this.state=X.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break;case W.NULL:this._err(G.unexpectedNullCharacter),this.state=X.SCRIPT_DATA_ESCAPED,this._emitChars(`�`);break;case W.EOF:this._err(G.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this.state=X.SCRIPT_DATA_ESCAPED,this._emitCodePoint(e)}}_stateScriptDataEscapedDashDash(e){switch(e){case W.HYPHEN_MINUS:this._emitChars(`-`);break;case W.LESS_THAN_SIGN:this.state=X.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break;case W.GREATER_THAN_SIGN:this.state=X.SCRIPT_DATA,this._emitChars(`>`);break;case W.NULL:this._err(G.unexpectedNullCharacter),this.state=X.SCRIPT_DATA_ESCAPED,this._emitChars(`�`);break;case W.EOF:this._err(G.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this.state=X.SCRIPT_DATA_ESCAPED,this._emitCodePoint(e)}}_stateScriptDataEscapedLessThanSign(e){e===W.SOLIDUS?this.state=X.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:V_(e)?(this._emitChars(`<`),this.state=X.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(e)):(this._emitChars(`<`),this.state=X.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(e))}_stateScriptDataEscapedEndTagOpen(e){V_(e)?(this.state=X.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(e)):(this._emitChars(`</`),this.state=X.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(e))}_stateScriptDataEscapedEndTagName(e){this.handleSpecialEndTag(e)&&(this._emitChars(`</`),this.state=X.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(e))}_stateScriptDataDoubleEscapeStart(e){if(this.preprocessor.startsWith(s_.SCRIPT,!1)&&G_(this.preprocessor.peek(s_.SCRIPT.length))){this._emitCodePoint(e);for(let e=0;e<s_.SCRIPT.length;e++)this._emitCodePoint(this._consume());this.state=X.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=X.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(e))}_stateScriptDataDoubleEscaped(e){switch(e){case W.HYPHEN_MINUS:this.state=X.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars(`-`);break;case W.LESS_THAN_SIGN:this.state=X.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars(`<`);break;case W.NULL:this._err(G.unexpectedNullCharacter),this._emitChars(`�`);break;case W.EOF:this._err(G.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateScriptDataDoubleEscapedDash(e){switch(e){case W.HYPHEN_MINUS:this.state=X.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars(`-`);break;case W.LESS_THAN_SIGN:this.state=X.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars(`<`);break;case W.NULL:this._err(G.unexpectedNullCharacter),this.state=X.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(`�`);break;case W.EOF:this._err(G.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this.state=X.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(e)}}_stateScriptDataDoubleEscapedDashDash(e){switch(e){case W.HYPHEN_MINUS:this._emitChars(`-`);break;case W.LESS_THAN_SIGN:this.state=X.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars(`<`);break;case W.GREATER_THAN_SIGN:this.state=X.SCRIPT_DATA,this._emitChars(`>`);break;case W.NULL:this._err(G.unexpectedNullCharacter),this.state=X.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(`�`);break;case W.EOF:this._err(G.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this.state=X.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(e)}}_stateScriptDataDoubleEscapedLessThanSign(e){e===W.SOLIDUS?(this.state=X.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars(`/`)):(this.state=X.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(e))}_stateScriptDataDoubleEscapeEnd(e){if(this.preprocessor.startsWith(s_.SCRIPT,!1)&&G_(this.preprocessor.peek(s_.SCRIPT.length))){this._emitCodePoint(e);for(let e=0;e<s_.SCRIPT.length;e++)this._emitCodePoint(this._consume());this.state=X.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=X.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(e))}_stateBeforeAttributeName(e){switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:break;case W.SOLIDUS:case W.GREATER_THAN_SIGN:case W.EOF:this.state=X.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(e);break;case W.EQUALS_SIGN:this._err(G.unexpectedEqualsSignBeforeAttributeName),this._createAttr(`=`),this.state=X.ATTRIBUTE_NAME;break;default:this._createAttr(``),this.state=X.ATTRIBUTE_NAME,this._stateAttributeName(e)}}_stateAttributeName(e){switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:case W.SOLIDUS:case W.GREATER_THAN_SIGN:case W.EOF:this._leaveAttrName(),this.state=X.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(e);break;case W.EQUALS_SIGN:this._leaveAttrName(),this.state=X.BEFORE_ATTRIBUTE_VALUE;break;case W.QUOTATION_MARK:case W.APOSTROPHE:case W.LESS_THAN_SIGN:this._err(G.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(e);break;case W.NULL:this._err(G.unexpectedNullCharacter),this.currentAttr.name+=`�`;break;default:this.currentAttr.name+=String.fromCodePoint(z_(e)?U_(e):e)}}_stateAfterAttributeName(e){switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:break;case W.SOLIDUS:this.state=X.SELF_CLOSING_START_TAG;break;case W.EQUALS_SIGN:this.state=X.BEFORE_ATTRIBUTE_VALUE;break;case W.GREATER_THAN_SIGN:this.state=X.DATA,this.emitCurrentTagToken();break;case W.EOF:this._err(G.eofInTag),this._emitEOFToken();break;default:this._createAttr(``),this.state=X.ATTRIBUTE_NAME,this._stateAttributeName(e)}}_stateBeforeAttributeValue(e){switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:break;case W.QUOTATION_MARK:this.state=X.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break;case W.APOSTROPHE:this.state=X.ATTRIBUTE_VALUE_SINGLE_QUOTED;break;case W.GREATER_THAN_SIGN:this._err(G.missingAttributeValue),this.state=X.DATA,this.emitCurrentTagToken();break;default:this.state=X.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(e)}}_stateAttributeValueDoubleQuoted(e){switch(e){case W.QUOTATION_MARK:this.state=X.AFTER_ATTRIBUTE_VALUE_QUOTED;break;case W.AMPERSAND:this._startCharacterReference();break;case W.NULL:this._err(G.unexpectedNullCharacter),this.currentAttr.value+=`�`;break;case W.EOF:this._err(G.eofInTag),this._emitEOFToken();break;default:this.currentAttr.value+=String.fromCodePoint(e)}}_stateAttributeValueSingleQuoted(e){switch(e){case W.APOSTROPHE:this.state=X.AFTER_ATTRIBUTE_VALUE_QUOTED;break;case W.AMPERSAND:this._startCharacterReference();break;case W.NULL:this._err(G.unexpectedNullCharacter),this.currentAttr.value+=`�`;break;case W.EOF:this._err(G.eofInTag),this._emitEOFToken();break;default:this.currentAttr.value+=String.fromCodePoint(e)}}_stateAttributeValueUnquoted(e){switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:this._leaveAttrValue(),this.state=X.BEFORE_ATTRIBUTE_NAME;break;case W.AMPERSAND:this._startCharacterReference();break;case W.GREATER_THAN_SIGN:this._leaveAttrValue(),this.state=X.DATA,this.emitCurrentTagToken();break;case W.NULL:this._err(G.unexpectedNullCharacter),this.currentAttr.value+=`�`;break;case W.QUOTATION_MARK:case W.APOSTROPHE:case W.LESS_THAN_SIGN:case W.EQUALS_SIGN:case W.GRAVE_ACCENT:this._err(G.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(e);break;case W.EOF:this._err(G.eofInTag),this._emitEOFToken();break;default:this.currentAttr.value+=String.fromCodePoint(e)}}_stateAfterAttributeValueQuoted(e){switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:this._leaveAttrValue(),this.state=X.BEFORE_ATTRIBUTE_NAME;break;case W.SOLIDUS:this._leaveAttrValue(),this.state=X.SELF_CLOSING_START_TAG;break;case W.GREATER_THAN_SIGN:this._leaveAttrValue(),this.state=X.DATA,this.emitCurrentTagToken();break;case W.EOF:this._err(G.eofInTag),this._emitEOFToken();break;default:this._err(G.missingWhitespaceBetweenAttributes),this.state=X.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(e)}}_stateSelfClosingStartTag(e){switch(e){case W.GREATER_THAN_SIGN:{let e=this.currentToken;e.selfClosing=!0,this.state=X.DATA,this.emitCurrentTagToken();break}case W.EOF:this._err(G.eofInTag),this._emitEOFToken();break;default:this._err(G.unexpectedSolidusInTag),this.state=X.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(e)}}_stateBogusComment(e){let t=this.currentToken;switch(e){case W.GREATER_THAN_SIGN:this.state=X.DATA,this.emitCurrentComment(t);break;case W.EOF:this.emitCurrentComment(t),this._emitEOFToken();break;case W.NULL:this._err(G.unexpectedNullCharacter),t.data+=`�`;break;default:t.data+=String.fromCodePoint(e)}}_stateMarkupDeclarationOpen(e){this._consumeSequenceIfMatch(s_.DASH_DASH,!0)?(this._createCommentToken(s_.DASH_DASH.length+1),this.state=X.COMMENT_START):this._consumeSequenceIfMatch(s_.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(s_.DOCTYPE.length+1),this.state=X.DOCTYPE):this._consumeSequenceIfMatch(s_.CDATA_START,!0)?this.inForeignNode?this.state=X.CDATA_SECTION:(this._err(G.cdataInHtmlContent),this._createCommentToken(s_.CDATA_START.length+1),this.currentToken.data=`[CDATA[`,this.state=X.BOGUS_COMMENT):this._ensureHibernation()||(this._err(G.incorrectlyOpenedComment),this._createCommentToken(2),this.state=X.BOGUS_COMMENT,this._stateBogusComment(e))}_stateCommentStart(e){switch(e){case W.HYPHEN_MINUS:this.state=X.COMMENT_START_DASH;break;case W.GREATER_THAN_SIGN:{this._err(G.abruptClosingOfEmptyComment),this.state=X.DATA;let e=this.currentToken;this.emitCurrentComment(e);break}default:this.state=X.COMMENT,this._stateComment(e)}}_stateCommentStartDash(e){let t=this.currentToken;switch(e){case W.HYPHEN_MINUS:this.state=X.COMMENT_END;break;case W.GREATER_THAN_SIGN:this._err(G.abruptClosingOfEmptyComment),this.state=X.DATA,this.emitCurrentComment(t);break;case W.EOF:this._err(G.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+=`-`,this.state=X.COMMENT,this._stateComment(e)}}_stateComment(e){let t=this.currentToken;switch(e){case W.HYPHEN_MINUS:this.state=X.COMMENT_END_DASH;break;case W.LESS_THAN_SIGN:t.data+=`<`,this.state=X.COMMENT_LESS_THAN_SIGN;break;case W.NULL:this._err(G.unexpectedNullCharacter),t.data+=`�`;break;case W.EOF:this._err(G.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+=String.fromCodePoint(e)}}_stateCommentLessThanSign(e){let t=this.currentToken;switch(e){case W.EXCLAMATION_MARK:t.data+=`!`,this.state=X.COMMENT_LESS_THAN_SIGN_BANG;break;case W.LESS_THAN_SIGN:t.data+=`<`;break;default:this.state=X.COMMENT,this._stateComment(e)}}_stateCommentLessThanSignBang(e){e===W.HYPHEN_MINUS?this.state=X.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=X.COMMENT,this._stateComment(e))}_stateCommentLessThanSignBangDash(e){e===W.HYPHEN_MINUS?this.state=X.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=X.COMMENT_END_DASH,this._stateCommentEndDash(e))}_stateCommentLessThanSignBangDashDash(e){e!==W.GREATER_THAN_SIGN&&e!==W.EOF&&this._err(G.nestedComment),this.state=X.COMMENT_END,this._stateCommentEnd(e)}_stateCommentEndDash(e){let t=this.currentToken;switch(e){case W.HYPHEN_MINUS:this.state=X.COMMENT_END;break;case W.EOF:this._err(G.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+=`-`,this.state=X.COMMENT,this._stateComment(e)}}_stateCommentEnd(e){let t=this.currentToken;switch(e){case W.GREATER_THAN_SIGN:this.state=X.DATA,this.emitCurrentComment(t);break;case W.EXCLAMATION_MARK:this.state=X.COMMENT_END_BANG;break;case W.HYPHEN_MINUS:t.data+=`-`;break;case W.EOF:this._err(G.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+=`--`,this.state=X.COMMENT,this._stateComment(e)}}_stateCommentEndBang(e){let t=this.currentToken;switch(e){case W.HYPHEN_MINUS:t.data+=`--!`,this.state=X.COMMENT_END_DASH;break;case W.GREATER_THAN_SIGN:this._err(G.incorrectlyClosedComment),this.state=X.DATA,this.emitCurrentComment(t);break;case W.EOF:this._err(G.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+=`--!`,this.state=X.COMMENT,this._stateComment(e)}}_stateDoctype(e){switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:this.state=X.BEFORE_DOCTYPE_NAME;break;case W.GREATER_THAN_SIGN:this.state=X.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(e);break;case W.EOF:{this._err(G.eofInDoctype),this._createDoctypeToken(null);let e=this.currentToken;e.forceQuirks=!0,this.emitCurrentDoctype(e),this._emitEOFToken();break}default:this._err(G.missingWhitespaceBeforeDoctypeName),this.state=X.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(e)}}_stateBeforeDoctypeName(e){if(z_(e))this._createDoctypeToken(String.fromCharCode(U_(e))),this.state=X.DOCTYPE_NAME;else switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:break;case W.NULL:this._err(G.unexpectedNullCharacter),this._createDoctypeToken(`�`),this.state=X.DOCTYPE_NAME;break;case W.GREATER_THAN_SIGN:{this._err(G.missingDoctypeName),this._createDoctypeToken(null);let e=this.currentToken;e.forceQuirks=!0,this.emitCurrentDoctype(e),this.state=X.DATA;break}case W.EOF:{this._err(G.eofInDoctype),this._createDoctypeToken(null);let e=this.currentToken;e.forceQuirks=!0,this.emitCurrentDoctype(e),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(e)),this.state=X.DOCTYPE_NAME}}_stateDoctypeName(e){let t=this.currentToken;switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:this.state=X.AFTER_DOCTYPE_NAME;break;case W.GREATER_THAN_SIGN:this.state=X.DATA,this.emitCurrentDoctype(t);break;case W.NULL:this._err(G.unexpectedNullCharacter),t.name+=`�`;break;case W.EOF:this._err(G.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.name+=String.fromCodePoint(z_(e)?U_(e):e)}}_stateAfterDoctypeName(e){let t=this.currentToken;switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:break;case W.GREATER_THAN_SIGN:this.state=X.DATA,this.emitCurrentDoctype(t);break;case W.EOF:this._err(G.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._consumeSequenceIfMatch(s_.PUBLIC,!1)?this.state=X.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(s_.SYSTEM,!1)?this.state=X.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(G.invalidCharacterSequenceAfterDoctypeName),t.forceQuirks=!0,this.state=X.BOGUS_DOCTYPE,this._stateBogusDoctype(e))}}_stateAfterDoctypePublicKeyword(e){let t=this.currentToken;switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:this.state=X.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break;case W.QUOTATION_MARK:this._err(G.missingWhitespaceAfterDoctypePublicKeyword),t.publicId=``,this.state=X.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break;case W.APOSTROPHE:this._err(G.missingWhitespaceAfterDoctypePublicKeyword),t.publicId=``,this.state=X.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break;case W.GREATER_THAN_SIGN:this._err(G.missingDoctypePublicIdentifier),t.forceQuirks=!0,this.state=X.DATA,this.emitCurrentDoctype(t);break;case W.EOF:this._err(G.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(G.missingQuoteBeforeDoctypePublicIdentifier),t.forceQuirks=!0,this.state=X.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateBeforeDoctypePublicIdentifier(e){let t=this.currentToken;switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:break;case W.QUOTATION_MARK:t.publicId=``,this.state=X.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break;case W.APOSTROPHE:t.publicId=``,this.state=X.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break;case W.GREATER_THAN_SIGN:this._err(G.missingDoctypePublicIdentifier),t.forceQuirks=!0,this.state=X.DATA,this.emitCurrentDoctype(t);break;case W.EOF:this._err(G.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(G.missingQuoteBeforeDoctypePublicIdentifier),t.forceQuirks=!0,this.state=X.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateDoctypePublicIdentifierDoubleQuoted(e){let t=this.currentToken;switch(e){case W.QUOTATION_MARK:this.state=X.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break;case W.NULL:this._err(G.unexpectedNullCharacter),t.publicId+=`�`;break;case W.GREATER_THAN_SIGN:this._err(G.abruptDoctypePublicIdentifier),t.forceQuirks=!0,this.emitCurrentDoctype(t),this.state=X.DATA;break;case W.EOF:this._err(G.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.publicId+=String.fromCodePoint(e)}}_stateDoctypePublicIdentifierSingleQuoted(e){let t=this.currentToken;switch(e){case W.APOSTROPHE:this.state=X.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break;case W.NULL:this._err(G.unexpectedNullCharacter),t.publicId+=`�`;break;case W.GREATER_THAN_SIGN:this._err(G.abruptDoctypePublicIdentifier),t.forceQuirks=!0,this.emitCurrentDoctype(t),this.state=X.DATA;break;case W.EOF:this._err(G.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.publicId+=String.fromCodePoint(e)}}_stateAfterDoctypePublicIdentifier(e){let t=this.currentToken;switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:this.state=X.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break;case W.GREATER_THAN_SIGN:this.state=X.DATA,this.emitCurrentDoctype(t);break;case W.QUOTATION_MARK:this._err(G.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),t.systemId=``,this.state=X.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break;case W.APOSTROPHE:this._err(G.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),t.systemId=``,this.state=X.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break;case W.EOF:this._err(G.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(G.missingQuoteBeforeDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=X.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateBetweenDoctypePublicAndSystemIdentifiers(e){let t=this.currentToken;switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:break;case W.GREATER_THAN_SIGN:this.emitCurrentDoctype(t),this.state=X.DATA;break;case W.QUOTATION_MARK:t.systemId=``,this.state=X.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break;case W.APOSTROPHE:t.systemId=``,this.state=X.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break;case W.EOF:this._err(G.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(G.missingQuoteBeforeDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=X.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateAfterDoctypeSystemKeyword(e){let t=this.currentToken;switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:this.state=X.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break;case W.QUOTATION_MARK:this._err(G.missingWhitespaceAfterDoctypeSystemKeyword),t.systemId=``,this.state=X.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break;case W.APOSTROPHE:this._err(G.missingWhitespaceAfterDoctypeSystemKeyword),t.systemId=``,this.state=X.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break;case W.GREATER_THAN_SIGN:this._err(G.missingDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=X.DATA,this.emitCurrentDoctype(t);break;case W.EOF:this._err(G.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(G.missingQuoteBeforeDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=X.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateBeforeDoctypeSystemIdentifier(e){let t=this.currentToken;switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:break;case W.QUOTATION_MARK:t.systemId=``,this.state=X.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break;case W.APOSTROPHE:t.systemId=``,this.state=X.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break;case W.GREATER_THAN_SIGN:this._err(G.missingDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=X.DATA,this.emitCurrentDoctype(t);break;case W.EOF:this._err(G.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(G.missingQuoteBeforeDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=X.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateDoctypeSystemIdentifierDoubleQuoted(e){let t=this.currentToken;switch(e){case W.QUOTATION_MARK:this.state=X.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break;case W.NULL:this._err(G.unexpectedNullCharacter),t.systemId+=`�`;break;case W.GREATER_THAN_SIGN:this._err(G.abruptDoctypeSystemIdentifier),t.forceQuirks=!0,this.emitCurrentDoctype(t),this.state=X.DATA;break;case W.EOF:this._err(G.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.systemId+=String.fromCodePoint(e)}}_stateDoctypeSystemIdentifierSingleQuoted(e){let t=this.currentToken;switch(e){case W.APOSTROPHE:this.state=X.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break;case W.NULL:this._err(G.unexpectedNullCharacter),t.systemId+=`�`;break;case W.GREATER_THAN_SIGN:this._err(G.abruptDoctypeSystemIdentifier),t.forceQuirks=!0,this.emitCurrentDoctype(t),this.state=X.DATA;break;case W.EOF:this._err(G.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.systemId+=String.fromCodePoint(e)}}_stateAfterDoctypeSystemIdentifier(e){let t=this.currentToken;switch(e){case W.SPACE:case W.LINE_FEED:case W.TABULATION:case W.FORM_FEED:break;case W.GREATER_THAN_SIGN:this.emitCurrentDoctype(t),this.state=X.DATA;break;case W.EOF:this._err(G.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(G.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=X.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateBogusDoctype(e){let t=this.currentToken;switch(e){case W.GREATER_THAN_SIGN:this.emitCurrentDoctype(t),this.state=X.DATA;break;case W.NULL:this._err(G.unexpectedNullCharacter);break;case W.EOF:this.emitCurrentDoctype(t),this._emitEOFToken();break;default:}}_stateCdataSection(e){switch(e){case W.RIGHT_SQUARE_BRACKET:this.state=X.CDATA_SECTION_BRACKET;break;case W.EOF:this._err(G.eofInCdata),this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateCdataSectionBracket(e){e===W.RIGHT_SQUARE_BRACKET?this.state=X.CDATA_SECTION_END:(this._emitChars(`]`),this.state=X.CDATA_SECTION,this._stateCdataSection(e))}_stateCdataSectionEnd(e){switch(e){case W.GREATER_THAN_SIGN:this.state=X.DATA;break;case W.RIGHT_SQUARE_BRACKET:this._emitChars(`]`);break;default:this._emitChars(`]]`),this.state=X.CDATA_SECTION,this._stateCdataSection(e)}}_stateCharacterReference(){let e=this.entityDecoder.write(this.preprocessor.html,this.preprocessor.pos);if(e<0)if(this.preprocessor.lastChunkWritten)e=this.entityDecoder.end();else{this.active=!1,this.preprocessor.pos=this.preprocessor.html.length-1,this.consumedAfterSnapshot=0,this.preprocessor.endOfChunkHit=!0;return}e===0?(this.preprocessor.pos=this.entityStartPos,this._flushCodePointConsumedAsCharacterReference(W.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&H_(this.preprocessor.peek(1))?X.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(e){H_(e)?this._flushCodePointConsumedAsCharacterReference(e):(e===W.SEMICOLON&&this._err(G.unknownNamedCharacterReference),this.state=this.returnState,this._callState(e))}},J_=new Set([J.DD,J.DT,J.LI,J.OPTGROUP,J.OPTION,J.P,J.RB,J.RP,J.RT,J.RTC]),Y_=new Set([...J_,J.CAPTION,J.COLGROUP,J.TBODY,J.TD,J.TFOOT,J.TH,J.THEAD,J.TR]),X_=new Set([J.APPLET,J.CAPTION,J.HTML,J.MARQUEE,J.OBJECT,J.TABLE,J.TD,J.TEMPLATE,J.TH]),Z_=new Set([...X_,J.OL,J.UL]),Q_=new Set([...X_,J.BUTTON]),$_=new Set([J.ANNOTATION_XML,J.MI,J.MN,J.MO,J.MS,J.MTEXT]),ev=new Set([J.DESC,J.FOREIGN_OBJECT,J.TITLE]),tv=new Set([J.TR,J.TEMPLATE,J.HTML]),nv=new Set([J.TBODY,J.TFOOT,J.THEAD,J.TEMPLATE,J.HTML]),rv=new Set([J.TABLE,J.TEMPLATE,J.HTML]),iv=new Set([J.TD,J.TH]),av=class{get currentTmplContentOrNode(){return this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):this.current}constructor(e,t,n){this.treeAdapter=t,this.handler=n,this.items=[],this.tagIDs=[],this.stackTop=-1,this.tmplCount=0,this.currentTagId=J.UNKNOWN,this.current=e}_indexOf(e){return this.items.lastIndexOf(e,this.stackTop)}_isInTemplate(){return this.currentTagId===J.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===K.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagId=this.tagIDs[this.stackTop]}push(e,t){this.stackTop++,this.items[this.stackTop]=e,this.current=e,this.tagIDs[this.stackTop]=t,this.currentTagId=t,this._isInTemplate()&&this.tmplCount++,this.handler.onItemPush(e,t,!0)}pop(){let e=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(e,!0)}replace(e,t){let n=this._indexOf(e);this.items[n]=t,n===this.stackTop&&(this.current=t)}insertAfter(e,t,n){let r=this._indexOf(e)+1;this.items.splice(r,0,t),this.tagIDs.splice(r,0,n),this.stackTop++,r===this.stackTop&&this._updateCurrentElement(),this.current&&this.currentTagId!==void 0&&this.handler.onItemPush(this.current,this.currentTagId,r===this.stackTop)}popUntilTagNamePopped(e){let t=this.stackTop+1;do t=this.tagIDs.lastIndexOf(e,t-1);while(t>0&&this.treeAdapter.getNamespaceURI(this.items[t])!==K.HTML);this.shortenToLength(Math.max(t,0))}shortenToLength(e){for(;this.stackTop>=e;){let t=this.current;this.tmplCount>0&&this._isInTemplate()&&--this.tmplCount,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,this.stackTop<e)}}popUntilElementPopped(e){let t=this._indexOf(e);this.shortenToLength(Math.max(t,0))}popUntilPopped(e,t){let n=this._indexOfTagNames(e,t);this.shortenToLength(Math.max(n,0))}popUntilNumberedHeaderPopped(){this.popUntilPopped(I_,K.HTML)}popUntilTableCellPopped(){this.popUntilPopped(iv,K.HTML)}popAllUpToHtmlElement(){this.tmplCount=0,this.shortenToLength(1)}_indexOfTagNames(e,t){for(let n=this.stackTop;n>=0;n--)if(e.has(this.tagIDs[n])&&this.treeAdapter.getNamespaceURI(this.items[n])===t)return n;return-1}clearBackTo(e,t){let n=this._indexOfTagNames(e,t);this.shortenToLength(n+1)}clearBackToTableContext(){this.clearBackTo(rv,K.HTML)}clearBackToTableBodyContext(){this.clearBackTo(nv,K.HTML)}clearBackToTableRowContext(){this.clearBackTo(tv,K.HTML)}remove(e){let t=this._indexOf(e);t>=0&&(t===this.stackTop?this.pop():(this.items.splice(t,1),this.tagIDs.splice(t,1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(e,!1)))}tryPeekProperlyNestedBodyElement(){return this.stackTop>=1&&this.tagIDs[1]===J.BODY?this.items[1]:null}contains(e){return this._indexOf(e)>-1}getCommonAncestor(e){let t=this._indexOf(e)-1;return t>=0?this.items[t]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===J.HTML}hasInDynamicScope(e,t){for(let n=this.stackTop;n>=0;n--){let r=this.tagIDs[n];switch(this.treeAdapter.getNamespaceURI(this.items[n])){case K.HTML:if(r===e)return!0;if(t.has(r))return!1;break;case K.SVG:if(ev.has(r))return!1;break;case K.MATHML:if($_.has(r))return!1;break}}return!0}hasInScope(e){return this.hasInDynamicScope(e,X_)}hasInListItemScope(e){return this.hasInDynamicScope(e,Z_)}hasInButtonScope(e){return this.hasInDynamicScope(e,Q_)}hasNumberedHeaderInScope(){for(let e=this.stackTop;e>=0;e--){let t=this.tagIDs[e];switch(this.treeAdapter.getNamespaceURI(this.items[e])){case K.HTML:if(I_.has(t))return!0;if(X_.has(t))return!1;break;case K.SVG:if(ev.has(t))return!1;break;case K.MATHML:if($_.has(t))return!1;break}}return!0}hasInTableScope(e){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===K.HTML)switch(this.tagIDs[t]){case e:return!0;case J.TABLE:case J.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let e=this.stackTop;e>=0;e--)if(this.treeAdapter.getNamespaceURI(this.items[e])===K.HTML)switch(this.tagIDs[e]){case J.TBODY:case J.THEAD:case J.TFOOT:return!0;case J.TABLE:case J.HTML:return!1}return!0}hasInSelectScope(e){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===K.HTML)switch(this.tagIDs[t]){case e:return!0;case J.OPTION:case J.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;this.currentTagId!==void 0&&J_.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&Y_.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(e){for(;this.currentTagId!==void 0&&this.currentTagId!==e&&Y_.has(this.currentTagId);)this.pop()}},ov=3,sv;(function(e){e[e.Marker=0]=`Marker`,e[e.Element=1]=`Element`})(sv||={});var cv={type:sv.Marker},lv=class{constructor(e){this.treeAdapter=e,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(e,t){let n=[],r=t.length,i=this.treeAdapter.getTagName(e),a=this.treeAdapter.getNamespaceURI(e);for(let e=0;e<this.entries.length;e++){let t=this.entries[e];if(t.type===sv.Marker)break;let{element:o}=t;if(this.treeAdapter.getTagName(o)===i&&this.treeAdapter.getNamespaceURI(o)===a){let t=this.treeAdapter.getAttrList(o);t.length===r&&n.push({idx:e,attrs:t})}}return n}_ensureNoahArkCondition(e){if(this.entries.length<ov)return;let t=this.treeAdapter.getAttrList(e),n=this._getNoahArkConditionCandidates(e,t);if(n.length<ov)return;let r=new Map(t.map(e=>[e.name,e.value])),i=0;for(let e=0;e<n.length;e++){let t=n[e];t.attrs.every(e=>r.get(e.name)===e.value)&&(i+=1,i>=ov&&this.entries.splice(t.idx,1))}}insertMarker(){this.entries.unshift(cv)}pushElement(e,t){this._ensureNoahArkCondition(e),this.entries.unshift({type:sv.Element,element:e,token:t})}insertElementAfterBookmark(e,t){let n=this.entries.indexOf(this.bookmark);this.entries.splice(n,0,{type:sv.Element,element:e,token:t})}removeEntry(e){let t=this.entries.indexOf(e);t!==-1&&this.entries.splice(t,1)}clearToLastMarker(){let e=this.entries.indexOf(cv);e===-1?this.entries.length=0:this.entries.splice(0,e+1)}getElementEntryInScopeWithTagName(e){let t=this.entries.find(t=>t.type===sv.Marker||this.treeAdapter.getTagName(t.element)===e);return t&&t.type===sv.Element?t:null}getElementEntry(e){return this.entries.find(t=>t.type===sv.Element&&t.element===e)}},uv={createDocument(){return{nodeName:`#document`,mode:M_.NO_QUIRKS,childNodes:[]}},createDocumentFragment(){return{nodeName:`#document-fragment`,childNodes:[]}},createElement(e,t,n){return{nodeName:e,tagName:e,attrs:n,namespaceURI:t,childNodes:[],parentNode:null}},createCommentNode(e){return{nodeName:`#comment`,data:e,parentNode:null}},createTextNode(e){return{nodeName:`#text`,value:e,parentNode:null}},appendChild(e,t){e.childNodes.push(t),t.parentNode=e},insertBefore(e,t,n){let r=e.childNodes.indexOf(n);e.childNodes.splice(r,0,t),t.parentNode=e},setTemplateContent(e,t){e.content=t},getTemplateContent(e){return e.content},setDocumentType(e,t,n,r){let i=e.childNodes.find(e=>e.nodeName===`#documentType`);if(i)i.name=t,i.publicId=n,i.systemId=r;else{let i={nodeName:`#documentType`,name:t,publicId:n,systemId:r,parentNode:null};uv.appendChild(e,i)}},setDocumentMode(e,t){e.mode=t},getDocumentMode(e){return e.mode},detachNode(e){if(e.parentNode){let t=e.parentNode.childNodes.indexOf(e);e.parentNode.childNodes.splice(t,1),e.parentNode=null}},insertText(e,t){if(e.childNodes.length>0){let n=e.childNodes[e.childNodes.length-1];if(uv.isTextNode(n)){n.value+=t;return}}uv.appendChild(e,uv.createTextNode(t))},insertTextBefore(e,t,n){let r=e.childNodes[e.childNodes.indexOf(n)-1];r&&uv.isTextNode(r)?r.value+=t:uv.insertBefore(e,uv.createTextNode(t),n)},adoptAttributes(e,t){let n=new Set(e.attrs.map(e=>e.name));for(let r=0;r<t.length;r++)n.has(t[r].name)||e.attrs.push(t[r])},getFirstChild(e){return e.childNodes[0]},getChildNodes(e){return e.childNodes},getParentNode(e){return e.parentNode},getAttrList(e){return e.attrs},getTagName(e){return e.tagName},getNamespaceURI(e){return e.namespaceURI},getTextNodeContent(e){return e.value},getCommentNodeContent(e){return e.data},getDocumentTypeNodeName(e){return e.name},getDocumentTypeNodePublicId(e){return e.publicId},getDocumentTypeNodeSystemId(e){return e.systemId},isTextNode(e){return e.nodeName===`#text`},isCommentNode(e){return e.nodeName===`#comment`},isDocumentTypeNode(e){return e.nodeName===`#documentType`},isElementNode(e){return Object.prototype.hasOwnProperty.call(e,`tagName`)},setNodeSourceCodeLocation(e,t){e.sourceCodeLocation=t},getNodeSourceCodeLocation(e){return e.sourceCodeLocation},updateNodeSourceCodeLocation(e,t){e.sourceCodeLocation={...e.sourceCodeLocation,...t}}},dv=`html`,fv=`about:legacy-compat`,pv=`http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd`,mv=`+//silmaril//dtd html pro v0r11 19970101//,-//as//dtd html 3.0 aswedit + extensions//,-//advasoft ltd//dtd html 3.0 aswedit + extensions//,-//ietf//dtd html 2.0 level 1//,-//ietf//dtd html 2.0 level 2//,-//ietf//dtd html 2.0 strict level 1//,-//ietf//dtd html 2.0 strict level 2//,-//ietf//dtd html 2.0 strict//,-//ietf//dtd html 2.0//,-//ietf//dtd html 2.1e//,-//ietf//dtd html 3.0//,-//ietf//dtd html 3.2 final//,-//ietf//dtd html 3.2//,-//ietf//dtd html 3//,-//ietf//dtd html level 0//,-//ietf//dtd html level 1//,-//ietf//dtd html level 2//,-//ietf//dtd html level 3//,-//ietf//dtd html strict level 0//,-//ietf//dtd html strict level 1//,-//ietf//dtd html strict level 2//,-//ietf//dtd html strict level 3//,-//ietf//dtd html strict//,-//ietf//dtd html//,-//metrius//dtd metrius presentational//,-//microsoft//dtd internet explorer 2.0 html strict//,-//microsoft//dtd internet explorer 2.0 html//,-//microsoft//dtd internet explorer 2.0 tables//,-//microsoft//dtd internet explorer 3.0 html strict//,-//microsoft//dtd internet explorer 3.0 html//,-//microsoft//dtd internet explorer 3.0 tables//,-//netscape comm. corp.//dtd html//,-//netscape comm. corp.//dtd strict html//,-//o'reilly and associates//dtd html 2.0//,-//o'reilly and associates//dtd html extended 1.0//,-//o'reilly and associates//dtd html extended relaxed 1.0//,-//sq//dtd html 2.0 hotmetal + extensions//,-//softquad software//dtd hotmetal pro 6.0::19990601::extensions to html 4.0//,-//softquad//dtd hotmetal pro 4.0::19971010::extensions to html 4.0//,-//spyglass//dtd html 2.0 extended//,-//sun microsystems corp.//dtd hotjava html//,-//sun microsystems corp.//dtd hotjava strict html//,-//w3c//dtd html 3 1995-03-24//,-//w3c//dtd html 3.2 draft//,-//w3c//dtd html 3.2 final//,-//w3c//dtd html 3.2//,-//w3c//dtd html 3.2s draft//,-//w3c//dtd html 4.0 frameset//,-//w3c//dtd html 4.0 transitional//,-//w3c//dtd html experimental 19960712//,-//w3c//dtd html experimental 970421//,-//w3c//dtd w3 html//,-//w3o//dtd w3 html 3.0//,-//webtechs//dtd mozilla html 2.0//,-//webtechs//dtd mozilla html//`.split(`,`),hv=[...mv,`-//w3c//dtd html 4.01 frameset//`,`-//w3c//dtd html 4.01 transitional//`],gv=new Set([`-//w3o//dtd w3 html strict 3.0//en//`,`-/w3c/dtd html 4.0 transitional/en`,`html`]),_v=[`-//w3c//dtd xhtml 1.0 frameset//`,`-//w3c//dtd xhtml 1.0 transitional//`],vv=[..._v,`-//w3c//dtd html 4.01 frameset//`,`-//w3c//dtd html 4.01 transitional//`];function yv(e,t){return t.some(t=>e.startsWith(t))}function bv(e){return e.name===dv&&e.publicId===null&&(e.systemId===null||e.systemId===fv)}function xv(e){if(e.name!==dv)return M_.QUIRKS;let{systemId:t}=e;if(t&&t.toLowerCase()===pv)return M_.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),gv.has(n))return M_.QUIRKS;let e=t===null?hv:mv;if(yv(n,e))return M_.QUIRKS;if(e=t===null?_v:vv,yv(n,e))return M_.LIMITED_QUIRKS}return M_.NO_QUIRKS}var Sv={TEXT_HTML:`text/html`,APPLICATION_XML:`application/xhtml+xml`},Cv=`definitionurl`,wv=`definitionURL`,Tv=new Map(`attributeName.attributeType.baseFrequency.baseProfile.calcMode.clipPathUnits.diffuseConstant.edgeMode.filterUnits.glyphRef.gradientTransform.gradientUnits.kernelMatrix.kernelUnitLength.keyPoints.keySplines.keyTimes.lengthAdjust.limitingConeAngle.markerHeight.markerUnits.markerWidth.maskContentUnits.maskUnits.numOctaves.pathLength.patternContentUnits.patternTransform.patternUnits.pointsAtX.pointsAtY.pointsAtZ.preserveAlpha.preserveAspectRatio.primitiveUnits.refX.refY.repeatCount.repeatDur.requiredExtensions.requiredFeatures.specularConstant.specularExponent.spreadMethod.startOffset.stdDeviation.stitchTiles.surfaceScale.systemLanguage.tableValues.targetX.targetY.textLength.viewBox.viewTarget.xChannelSelector.yChannelSelector.zoomAndPan`.split(`.`).map(e=>[e.toLowerCase(),e])),Ev=new Map([[`xlink:actuate`,{prefix:`xlink`,name:`actuate`,namespace:K.XLINK}],[`xlink:arcrole`,{prefix:`xlink`,name:`arcrole`,namespace:K.XLINK}],[`xlink:href`,{prefix:`xlink`,name:`href`,namespace:K.XLINK}],[`xlink:role`,{prefix:`xlink`,name:`role`,namespace:K.XLINK}],[`xlink:show`,{prefix:`xlink`,name:`show`,namespace:K.XLINK}],[`xlink:title`,{prefix:`xlink`,name:`title`,namespace:K.XLINK}],[`xlink:type`,{prefix:`xlink`,name:`type`,namespace:K.XLINK}],[`xml:lang`,{prefix:`xml`,name:`lang`,namespace:K.XML}],[`xml:space`,{prefix:`xml`,name:`space`,namespace:K.XML}],[`xmlns`,{prefix:``,name:`xmlns`,namespace:K.XMLNS}],[`xmlns:xlink`,{prefix:`xmlns`,name:`xlink`,namespace:K.XMLNS}]]),Dv=new Map(`altGlyph.altGlyphDef.altGlyphItem.animateColor.animateMotion.animateTransform.clipPath.feBlend.feColorMatrix.feComponentTransfer.feComposite.feConvolveMatrix.feDiffuseLighting.feDisplacementMap.feDistantLight.feFlood.feFuncA.feFuncB.feFuncG.feFuncR.feGaussianBlur.feImage.feMerge.feMergeNode.feMorphology.feOffset.fePointLight.feSpecularLighting.feSpotLight.feTile.feTurbulence.foreignObject.glyphRef.linearGradient.radialGradient.textPath`.split(`.`).map(e=>[e.toLowerCase(),e])),Ov=new Set([J.B,J.BIG,J.BLOCKQUOTE,J.BODY,J.BR,J.CENTER,J.CODE,J.DD,J.DIV,J.DL,J.DT,J.EM,J.EMBED,J.H1,J.H2,J.H3,J.H4,J.H5,J.H6,J.HEAD,J.HR,J.I,J.IMG,J.LI,J.LISTING,J.MENU,J.META,J.NOBR,J.OL,J.P,J.PRE,J.RUBY,J.S,J.SMALL,J.SPAN,J.STRONG,J.STRIKE,J.SUB,J.SUP,J.TABLE,J.TT,J.U,J.UL,J.VAR]);function kv(e){let t=e.tagID;return t===J.FONT&&e.attrs.some(({name:e})=>e===j_.COLOR||e===j_.SIZE||e===j_.FACE)||Ov.has(t)}function Av(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===Cv){e.attrs[t].name=wv;break}}function jv(e){for(let t=0;t<e.attrs.length;t++){let n=Tv.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function Mv(e){for(let t=0;t<e.attrs.length;t++){let n=Ev.get(e.attrs[t].name);n&&(e.attrs[t].prefix=n.prefix,e.attrs[t].name=n.name,e.attrs[t].namespace=n.namespace)}}function Nv(e){let t=Dv.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=P_(e.tagName))}function Pv(e,t){return t===K.MATHML&&(e===J.MI||e===J.MO||e===J.MN||e===J.MS||e===J.MTEXT)}function Fv(e,t,n){if(t===K.MATHML&&e===J.ANNOTATION_XML){for(let e=0;e<n.length;e++)if(n[e].name===j_.ENCODING){let t=n[e].value.toLowerCase();return t===Sv.TEXT_HTML||t===Sv.APPLICATION_XML}}return t===K.SVG&&(e===J.FOREIGN_OBJECT||e===J.DESC||e===J.TITLE)}function Iv(e,t,n,r){return(!r||r===K.HTML)&&Fv(e,t,n)||(!r||r===K.MATHML)&&Pv(e,t)}var Lv=`hidden`,Rv=8,zv=3,Z;(function(e){e[e.INITIAL=0]=`INITIAL`,e[e.BEFORE_HTML=1]=`BEFORE_HTML`,e[e.BEFORE_HEAD=2]=`BEFORE_HEAD`,e[e.IN_HEAD=3]=`IN_HEAD`,e[e.IN_HEAD_NO_SCRIPT=4]=`IN_HEAD_NO_SCRIPT`,e[e.AFTER_HEAD=5]=`AFTER_HEAD`,e[e.IN_BODY=6]=`IN_BODY`,e[e.TEXT=7]=`TEXT`,e[e.IN_TABLE=8]=`IN_TABLE`,e[e.IN_TABLE_TEXT=9]=`IN_TABLE_TEXT`,e[e.IN_CAPTION=10]=`IN_CAPTION`,e[e.IN_COLUMN_GROUP=11]=`IN_COLUMN_GROUP`,e[e.IN_TABLE_BODY=12]=`IN_TABLE_BODY`,e[e.IN_ROW=13]=`IN_ROW`,e[e.IN_CELL=14]=`IN_CELL`,e[e.IN_SELECT=15]=`IN_SELECT`,e[e.IN_SELECT_IN_TABLE=16]=`IN_SELECT_IN_TABLE`,e[e.IN_TEMPLATE=17]=`IN_TEMPLATE`,e[e.AFTER_BODY=18]=`AFTER_BODY`,e[e.IN_FRAMESET=19]=`IN_FRAMESET`,e[e.AFTER_FRAMESET=20]=`AFTER_FRAMESET`,e[e.AFTER_AFTER_BODY=21]=`AFTER_AFTER_BODY`,e[e.AFTER_AFTER_FRAMESET=22]=`AFTER_AFTER_FRAMESET`})(Z||={});var Bv={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},Vv=new Set([J.TABLE,J.TBODY,J.TFOOT,J.THEAD,J.TR]),Hv={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:uv,onParseError:null},Uv=class{constructor(e,t,n=null,r=null){this.fragmentContext=n,this.scriptHandler=r,this.currentToken=null,this.stopped=!1,this.insertionMode=Z.INITIAL,this.originalInsertionMode=Z.INITIAL,this.headElement=null,this.formElement=null,this.currentNotInHTML=!1,this.tmplInsertionModeStack=[],this.pendingCharacterTokens=[],this.hasNonWhitespacePendingCharacterToken=!1,this.framesetOk=!0,this.skipNextNewLine=!1,this.fosterParentingEnabled=!1,this.options={...Hv,...e},this.treeAdapter=this.options.treeAdapter,this.onParseError=this.options.onParseError,this.onParseError&&(this.options.sourceCodeLocationInfo=!0),this.document=t??this.treeAdapter.createDocument(),this.tokenizer=new q_(this.options,this),this.activeFormattingElements=new lv(this.treeAdapter),this.fragmentContextID=n?P_(this.treeAdapter.getTagName(n)):J.UNKNOWN,this._setContextModes(n??this.document,this.fragmentContextID),this.openElements=new av(this.document,this.treeAdapter,this)}static parse(e,t){let n=new this(t);return n.tokenizer.write(e,!0),n.document}static getFragmentParser(e,t){let n={...Hv,...t};e??=n.treeAdapter.createElement(q.TEMPLATE,K.HTML,[]);let r=n.treeAdapter.createElement(`documentmock`,K.HTML,[]),i=new this(n,r,e);return i.fragmentContextID===J.TEMPLATE&&i.tmplInsertionModeStack.unshift(Z.IN_TEMPLATE),i._initTokenizerForFragmentParsing(),i._insertFakeRootElement(),i._resetInsertionMode(),i._findFormInFragmentContext(),i}getFragment(){let e=this.treeAdapter.getFirstChild(this.document),t=this.treeAdapter.createDocumentFragment();return this._adoptNodes(e,t),t}_err(e,t,n){if(!this.onParseError)return;let r=e.location??Bv,i={code:t,startLine:r.startLine,startCol:r.startCol,startOffset:r.startOffset,endLine:n?r.startLine:r.endLine,endCol:n?r.startCol:r.endCol,endOffset:n?r.startOffset:r.endOffset};this.onParseError(i)}onItemPush(e,t,n){var r,i;(i=(r=this.treeAdapter).onItemPush)==null||i.call(r,e),n&&this.openElements.stackTop>0&&this._setContextModes(e,t)}onItemPop(e,t){var n,r;if(this.options.sourceCodeLocationInfo&&this._setEndLocation(e,this.currentToken),(r=(n=this.treeAdapter).onItemPop)==null||r.call(n,e,this.openElements.current),t){let e,t;this.openElements.stackTop===0&&this.fragmentContext?(e=this.fragmentContext,t=this.fragmentContextID):{current:e,currentTagId:t}=this.openElements,this._setContextModes(e,t)}}_setContextModes(e,t){let n=e===this.document||e&&this.treeAdapter.getNamespaceURI(e)===K.HTML;this.currentNotInHTML=!n,this.tokenizer.inForeignNode=!n&&e!==void 0&&t!==void 0&&!this._isIntegrationPoint(t,e)}_switchToTextParsing(e,t){this._insertElement(e,K.HTML),this.tokenizer.state=t,this.originalInsertionMode=this.insertionMode,this.insertionMode=Z.TEXT}switchToPlaintextParsing(){this.insertionMode=Z.TEXT,this.originalInsertionMode=Z.IN_BODY,this.tokenizer.state=L_.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let e=this.fragmentContext;for(;e;){if(this.treeAdapter.getTagName(e)===q.FORM){this.formElement=e;break}e=this.treeAdapter.getParentNode(e)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==K.HTML))switch(this.fragmentContextID){case J.TITLE:case J.TEXTAREA:this.tokenizer.state=L_.RCDATA;break;case J.STYLE:case J.XMP:case J.IFRAME:case J.NOEMBED:case J.NOFRAMES:case J.NOSCRIPT:this.tokenizer.state=L_.RAWTEXT;break;case J.SCRIPT:this.tokenizer.state=L_.SCRIPT_DATA;break;case J.PLAINTEXT:this.tokenizer.state=L_.PLAINTEXT;break;default:}}_setDocumentType(e){let t=e.name||``,n=e.publicId||``,r=e.systemId||``;if(this.treeAdapter.setDocumentType(this.document,t,n,r),e.location){let t=this.treeAdapter.getChildNodes(this.document).find(e=>this.treeAdapter.isDocumentTypeNode(e));t&&this.treeAdapter.setNodeSourceCodeLocation(t,e.location)}}_attachElementToTree(e,t){if(this.options.sourceCodeLocationInfo){let n=t&&{...t,startTag:t};this.treeAdapter.setNodeSourceCodeLocation(e,n)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(e);else{let t=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(t??this.document,e)}}_appendElement(e,t){let n=this.treeAdapter.createElement(e.tagName,t,e.attrs);this._attachElementToTree(n,e.location)}_insertElement(e,t){let n=this.treeAdapter.createElement(e.tagName,t,e.attrs);this._attachElementToTree(n,e.location),this.openElements.push(n,e.tagID)}_insertFakeElement(e,t){let n=this.treeAdapter.createElement(e,K.HTML,[]);this._attachElementToTree(n,null),this.openElements.push(n,t)}_insertTemplate(e){let t=this.treeAdapter.createElement(e.tagName,K.HTML,e.attrs),n=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(t,n),this._attachElementToTree(t,e.location),this.openElements.push(t,e.tagID),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(n,null)}_insertFakeRootElement(){let e=this.treeAdapter.createElement(q.HTML,K.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(e,null),this.treeAdapter.appendChild(this.openElements.current,e),this.openElements.push(e,J.HTML)}_appendCommentNode(e,t){let n=this.treeAdapter.createCommentNode(e.data);this.treeAdapter.appendChild(t,n),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(n,e.location)}_insertCharacters(e){let t,n;if(this._shouldFosterParentOnInsertion()?({parent:t,beforeElement:n}=this._findFosterParentingLocation(),n?this.treeAdapter.insertTextBefore(t,e.chars,n):this.treeAdapter.insertText(t,e.chars)):(t=this.openElements.currentTmplContentOrNode,this.treeAdapter.insertText(t,e.chars)),!e.location)return;let r=this.treeAdapter.getChildNodes(t),i=r[(n?r.lastIndexOf(n):r.length)-1];if(this.treeAdapter.getNodeSourceCodeLocation(i)){let{endLine:t,endCol:n,endOffset:r}=e.location;this.treeAdapter.updateNodeSourceCodeLocation(i,{endLine:t,endCol:n,endOffset:r})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(i,e.location)}_adoptNodes(e,t){for(let n=this.treeAdapter.getFirstChild(e);n;n=this.treeAdapter.getFirstChild(e))this.treeAdapter.detachNode(n),this.treeAdapter.appendChild(t,n)}_setEndLocation(e,t){if(this.treeAdapter.getNodeSourceCodeLocation(e)&&t.location){let n=t.location,r=this.treeAdapter.getTagName(e),i=t.type===h_.END_TAG&&r===t.tagName?{endTag:{...n},endLine:n.endLine,endCol:n.endCol,endOffset:n.endOffset}:{endLine:n.startLine,endCol:n.startCol,endOffset:n.startOffset};this.treeAdapter.updateNodeSourceCodeLocation(e,i)}}shouldProcessStartTagTokenInForeignContent(e){if(!this.currentNotInHTML)return!1;let t,n;return this.openElements.stackTop===0&&this.fragmentContext?(t=this.fragmentContext,n=this.fragmentContextID):{current:t,currentTagId:n}=this.openElements,e.tagID===J.SVG&&this.treeAdapter.getTagName(t)===q.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(t)===K.MATHML?!1:this.tokenizer.inForeignNode||(e.tagID===J.MGLYPH||e.tagID===J.MALIGNMARK)&&n!==void 0&&!this._isIntegrationPoint(n,t,K.HTML)}_processToken(e){switch(e.type){case h_.CHARACTER:this.onCharacter(e);break;case h_.NULL_CHARACTER:this.onNullCharacter(e);break;case h_.COMMENT:this.onComment(e);break;case h_.DOCTYPE:this.onDoctype(e);break;case h_.START_TAG:this._processStartTag(e);break;case h_.END_TAG:this.onEndTag(e);break;case h_.EOF:this.onEof(e);break;case h_.WHITESPACE_CHARACTER:this.onWhitespaceCharacter(e);break}}_isIntegrationPoint(e,t,n){return Iv(e,this.treeAdapter.getNamespaceURI(t),this.treeAdapter.getAttrList(t),n)}_reconstructActiveFormattingElements(){let e=this.activeFormattingElements.entries.length;if(e){let t=this.activeFormattingElements.entries.findIndex(e=>e.type===sv.Marker||this.openElements.contains(e.element)),n=t===-1?e-1:t-1;for(let e=n;e>=0;e--){let t=this.activeFormattingElements.entries[e];this._insertElement(t.token,this.treeAdapter.getNamespaceURI(t.element)),t.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=Z.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(J.P),this.openElements.popUntilTagNamePopped(J.P)}_resetInsertionMode(){for(let e=this.openElements.stackTop;e>=0;e--)switch(e===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[e]){case J.TR:this.insertionMode=Z.IN_ROW;return;case J.TBODY:case J.THEAD:case J.TFOOT:this.insertionMode=Z.IN_TABLE_BODY;return;case J.CAPTION:this.insertionMode=Z.IN_CAPTION;return;case J.COLGROUP:this.insertionMode=Z.IN_COLUMN_GROUP;return;case J.TABLE:this.insertionMode=Z.IN_TABLE;return;case J.BODY:this.insertionMode=Z.IN_BODY;return;case J.FRAMESET:this.insertionMode=Z.IN_FRAMESET;return;case J.SELECT:this._resetInsertionModeForSelect(e);return;case J.TEMPLATE:this.insertionMode=this.tmplInsertionModeStack[0];return;case J.HTML:this.insertionMode=this.headElement?Z.AFTER_HEAD:Z.BEFORE_HEAD;return;case J.TD:case J.TH:if(e>0){this.insertionMode=Z.IN_CELL;return}break;case J.HEAD:if(e>0){this.insertionMode=Z.IN_HEAD;return}break}this.insertionMode=Z.IN_BODY}_resetInsertionModeForSelect(e){if(e>0)for(let t=e-1;t>0;t--){let e=this.openElements.tagIDs[t];if(e===J.TEMPLATE)break;if(e===J.TABLE){this.insertionMode=Z.IN_SELECT_IN_TABLE;return}}this.insertionMode=Z.IN_SELECT}_isElementCausesFosterParenting(e){return Vv.has(e)}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this.openElements.currentTagId!==void 0&&this._isElementCausesFosterParenting(this.openElements.currentTagId)}_findFosterParentingLocation(){for(let e=this.openElements.stackTop;e>=0;e--){let t=this.openElements.items[e];switch(this.openElements.tagIDs[e]){case J.TEMPLATE:if(this.treeAdapter.getNamespaceURI(t)===K.HTML)return{parent:this.treeAdapter.getTemplateContent(t),beforeElement:null};break;case J.TABLE:{let n=this.treeAdapter.getParentNode(t);return n?{parent:n,beforeElement:t}:{parent:this.openElements.items[e-1],beforeElement:null}}default:}}return{parent:this.openElements.items[0],beforeElement:null}}_fosterParentElement(e){let t=this._findFosterParentingLocation();t.beforeElement?this.treeAdapter.insertBefore(t.parent,e,t.beforeElement):this.treeAdapter.appendChild(t.parent,e)}_isSpecialElement(e,t){return F_[this.treeAdapter.getNamespaceURI(e)].has(t)}onCharacter(e){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){sx(this,e);return}switch(this.insertionMode){case Z.INITIAL:ny(this,e);break;case Z.BEFORE_HTML:ay(this,e);break;case Z.BEFORE_HEAD:cy(this,e);break;case Z.IN_HEAD:fy(this,e);break;case Z.IN_HEAD_NO_SCRIPT:hy(this,e);break;case Z.AFTER_HEAD:vy(this,e);break;case Z.IN_BODY:case Z.IN_CAPTION:case Z.IN_CELL:case Z.IN_TEMPLATE:xy(this,e);break;case Z.TEXT:case Z.IN_SELECT:case Z.IN_SELECT_IN_TABLE:this._insertCharacters(e);break;case Z.IN_TABLE:case Z.IN_TABLE_BODY:case Z.IN_ROW:gb(this,e);break;case Z.IN_TABLE_TEXT:kb(this,e);break;case Z.IN_COLUMN_GROUP:Ib(this,e);break;case Z.AFTER_BODY:Qb(this,e);break;case Z.AFTER_AFTER_BODY:ix(this,e);break;default:}}onNullCharacter(e){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){ox(this,e);return}switch(this.insertionMode){case Z.INITIAL:ny(this,e);break;case Z.BEFORE_HTML:ay(this,e);break;case Z.BEFORE_HEAD:cy(this,e);break;case Z.IN_HEAD:fy(this,e);break;case Z.IN_HEAD_NO_SCRIPT:hy(this,e);break;case Z.AFTER_HEAD:vy(this,e);break;case Z.TEXT:this._insertCharacters(e);break;case Z.IN_TABLE:case Z.IN_TABLE_BODY:case Z.IN_ROW:gb(this,e);break;case Z.IN_COLUMN_GROUP:Ib(this,e);break;case Z.AFTER_BODY:Qb(this,e);break;case Z.AFTER_AFTER_BODY:ix(this,e);break;default:}}onComment(e){if(this.skipNextNewLine=!1,this.currentNotInHTML){Zv(this,e);return}switch(this.insertionMode){case Z.INITIAL:case Z.BEFORE_HTML:case Z.BEFORE_HEAD:case Z.IN_HEAD:case Z.IN_HEAD_NO_SCRIPT:case Z.AFTER_HEAD:case Z.IN_BODY:case Z.IN_TABLE:case Z.IN_CAPTION:case Z.IN_COLUMN_GROUP:case Z.IN_TABLE_BODY:case Z.IN_ROW:case Z.IN_CELL:case Z.IN_SELECT:case Z.IN_SELECT_IN_TABLE:case Z.IN_TEMPLATE:case Z.IN_FRAMESET:case Z.AFTER_FRAMESET:Zv(this,e);break;case Z.IN_TABLE_TEXT:Ab(this,e);break;case Z.AFTER_BODY:Qv(this,e);break;case Z.AFTER_AFTER_BODY:case Z.AFTER_AFTER_FRAMESET:$v(this,e);break;default:}}onDoctype(e){switch(this.skipNextNewLine=!1,this.insertionMode){case Z.INITIAL:ty(this,e);break;case Z.BEFORE_HEAD:case Z.IN_HEAD:case Z.IN_HEAD_NO_SCRIPT:case Z.AFTER_HEAD:this._err(e,G.misplacedDoctype);break;case Z.IN_TABLE_TEXT:Ab(this,e);break;default:}}onStartTag(e){this.skipNextNewLine=!1,this.currentToken=e,this._processStartTag(e),e.selfClosing&&!e.ackSelfClosing&&this._err(e,G.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(e){this.shouldProcessStartTagTokenInForeignContent(e)?lx(this,e):this._startTagOutsideForeignContent(e)}_startTagOutsideForeignContent(e){switch(this.insertionMode){case Z.INITIAL:ny(this,e);break;case Z.BEFORE_HTML:ry(this,e);break;case Z.BEFORE_HEAD:oy(this,e);break;case Z.IN_HEAD:ly(this,e);break;case Z.IN_HEAD_NO_SCRIPT:py(this,e);break;case Z.AFTER_HEAD:gy(this,e);break;case Z.IN_BODY:eb(this,e);break;case Z.IN_TABLE:Tb(this,e);break;case Z.IN_TABLE_TEXT:Ab(this,e);break;case Z.IN_CAPTION:Mb(this,e);break;case Z.IN_COLUMN_GROUP:Pb(this,e);break;case Z.IN_TABLE_BODY:Lb(this,e);break;case Z.IN_ROW:zb(this,e);break;case Z.IN_CELL:Vb(this,e);break;case Z.IN_SELECT:Ub(this,e);break;case Z.IN_SELECT_IN_TABLE:Gb(this,e);break;case Z.IN_TEMPLATE:qb(this,e);break;case Z.AFTER_BODY:Xb(this,e);break;case Z.IN_FRAMESET:$b(this,e);break;case Z.AFTER_FRAMESET:tx(this,e);break;case Z.AFTER_AFTER_BODY:rx(this,e);break;case Z.AFTER_AFTER_FRAMESET:ax(this,e);break;default:}}onEndTag(e){this.skipNextNewLine=!1,this.currentToken=e,this.currentNotInHTML?ux(this,e):this._endTagOutsideForeignContent(e)}_endTagOutsideForeignContent(e){switch(this.insertionMode){case Z.INITIAL:ny(this,e);break;case Z.BEFORE_HTML:iy(this,e);break;case Z.BEFORE_HEAD:sy(this,e);break;case Z.IN_HEAD:uy(this,e);break;case Z.IN_HEAD_NO_SCRIPT:my(this,e);break;case Z.AFTER_HEAD:_y(this,e);break;case Z.IN_BODY:fb(this,e);break;case Z.TEXT:mb(this,e);break;case Z.IN_TABLE:Eb(this,e);break;case Z.IN_TABLE_TEXT:Ab(this,e);break;case Z.IN_CAPTION:Nb(this,e);break;case Z.IN_COLUMN_GROUP:Fb(this,e);break;case Z.IN_TABLE_BODY:Rb(this,e);break;case Z.IN_ROW:Bb(this,e);break;case Z.IN_CELL:Hb(this,e);break;case Z.IN_SELECT:Wb(this,e);break;case Z.IN_SELECT_IN_TABLE:Kb(this,e);break;case Z.IN_TEMPLATE:Jb(this,e);break;case Z.AFTER_BODY:Zb(this,e);break;case Z.IN_FRAMESET:ex(this,e);break;case Z.AFTER_FRAMESET:nx(this,e);break;case Z.AFTER_AFTER_BODY:ix(this,e);break;default:}}onEof(e){switch(this.insertionMode){case Z.INITIAL:ny(this,e);break;case Z.BEFORE_HTML:ay(this,e);break;case Z.BEFORE_HEAD:cy(this,e);break;case Z.IN_HEAD:fy(this,e);break;case Z.IN_HEAD_NO_SCRIPT:hy(this,e);break;case Z.AFTER_HEAD:vy(this,e);break;case Z.IN_BODY:case Z.IN_TABLE:case Z.IN_CAPTION:case Z.IN_COLUMN_GROUP:case Z.IN_TABLE_BODY:case Z.IN_ROW:case Z.IN_CELL:case Z.IN_SELECT:case Z.IN_SELECT_IN_TABLE:pb(this,e);break;case Z.TEXT:hb(this,e);break;case Z.IN_TABLE_TEXT:Ab(this,e);break;case Z.IN_TEMPLATE:Yb(this,e);break;case Z.AFTER_BODY:case Z.IN_FRAMESET:case Z.AFTER_FRAMESET:case Z.AFTER_AFTER_BODY:case Z.AFTER_AFTER_FRAMESET:ey(this,e);break;default:}}onWhitespaceCharacter(e){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,e.chars.charCodeAt(0)===W.LINE_FEED)){if(e.chars.length===1)return;e.chars=e.chars.substr(1)}if(this.tokenizer.inForeignNode){this._insertCharacters(e);return}switch(this.insertionMode){case Z.IN_HEAD:case Z.IN_HEAD_NO_SCRIPT:case Z.AFTER_HEAD:case Z.TEXT:case Z.IN_COLUMN_GROUP:case Z.IN_SELECT:case Z.IN_SELECT_IN_TABLE:case Z.IN_FRAMESET:case Z.AFTER_FRAMESET:this._insertCharacters(e);break;case Z.IN_BODY:case Z.IN_CAPTION:case Z.IN_CELL:case Z.IN_TEMPLATE:case Z.AFTER_BODY:case Z.AFTER_AFTER_BODY:case Z.AFTER_AFTER_FRAMESET:by(this,e);break;case Z.IN_TABLE:case Z.IN_TABLE_BODY:case Z.IN_ROW:gb(this,e);break;case Z.IN_TABLE_TEXT:Ob(this,e);break;default:}}};function Wv(e,t){let n=e.activeFormattingElements.getElementEntryInScopeWithTagName(t.tagName);return n?e.openElements.contains(n.element)?e.openElements.hasInScope(t.tagID)||(n=null):(e.activeFormattingElements.removeEntry(n),n=null):db(e,t),n}function Gv(e,t){let n=null,r=e.openElements.stackTop;for(;r>=0;r--){let i=e.openElements.items[r];if(i===t.element)break;e._isSpecialElement(i,e.openElements.tagIDs[r])&&(n=i)}return n||(e.openElements.shortenToLength(Math.max(r,0)),e.activeFormattingElements.removeEntry(t)),n}function Kv(e,t,n){let r=t,i=e.openElements.getCommonAncestor(t);for(let a=0,o=i;o!==n;a++,o=i){i=e.openElements.getCommonAncestor(o);let n=e.activeFormattingElements.getElementEntry(o),s=n&&a>=zv;!n||s?(s&&e.activeFormattingElements.removeEntry(n),e.openElements.remove(o)):(o=qv(e,n),r===t&&(e.activeFormattingElements.bookmark=n),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(o,r),r=o)}return r}function qv(e,t){let n=e.treeAdapter.getNamespaceURI(t.element),r=e.treeAdapter.createElement(t.token.tagName,n,t.token.attrs);return e.openElements.replace(t.element,r),t.element=r,r}function Jv(e,t,n){let r=P_(e.treeAdapter.getTagName(t));if(e._isElementCausesFosterParenting(r))e._fosterParentElement(n);else{let i=e.treeAdapter.getNamespaceURI(t);r===J.TEMPLATE&&i===K.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function Yv(e,t,n){let r=e.treeAdapter.getNamespaceURI(n.element),{token:i}=n,a=e.treeAdapter.createElement(i.tagName,r,i.attrs);e._adoptNodes(t,a),e.treeAdapter.appendChild(t,a),e.activeFormattingElements.insertElementAfterBookmark(a,i),e.activeFormattingElements.removeEntry(n),e.openElements.remove(n.element),e.openElements.insertAfter(t,a,i.tagID)}function Xv(e,t){for(let n=0;n<Rv;n++){let n=Wv(e,t);if(!n)break;let r=Gv(e,n);if(!r)break;e.activeFormattingElements.bookmark=n;let i=Kv(e,r,n.element),a=e.openElements.getCommonAncestor(n.element);e.treeAdapter.detachNode(i),a&&Jv(e,a,i),Yv(e,r,n)}}function Zv(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function Qv(e,t){e._appendCommentNode(t,e.openElements.items[0])}function $v(e,t){e._appendCommentNode(t,e.document)}function ey(e,t){if(e.stopped=!0,t.location){let n=e.fragmentContext?0:2;for(let r=e.openElements.stackTop;r>=n;r--)e._setEndLocation(e.openElements.items[r],t);if(!e.fragmentContext&&e.openElements.stackTop>=0){let n=e.openElements.items[0],r=e.treeAdapter.getNodeSourceCodeLocation(n);if(r&&!r.endTag&&(e._setEndLocation(n,t),e.openElements.stackTop>=1)){let n=e.openElements.items[1],r=e.treeAdapter.getNodeSourceCodeLocation(n);r&&!r.endTag&&e._setEndLocation(n,t)}}}}function ty(e,t){e._setDocumentType(t);let n=t.forceQuirks?M_.QUIRKS:xv(t);bv(t)||e._err(t,G.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=Z.BEFORE_HTML}function ny(e,t){e._err(t,G.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,M_.QUIRKS),e.insertionMode=Z.BEFORE_HTML,e._processToken(t)}function ry(e,t){t.tagID===J.HTML?(e._insertElement(t,K.HTML),e.insertionMode=Z.BEFORE_HEAD):ay(e,t)}function iy(e,t){let n=t.tagID;(n===J.HTML||n===J.HEAD||n===J.BODY||n===J.BR)&&ay(e,t)}function ay(e,t){e._insertFakeRootElement(),e.insertionMode=Z.BEFORE_HEAD,e._processToken(t)}function oy(e,t){switch(t.tagID){case J.HTML:eb(e,t);break;case J.HEAD:e._insertElement(t,K.HTML),e.headElement=e.openElements.current,e.insertionMode=Z.IN_HEAD;break;default:cy(e,t)}}function sy(e,t){let n=t.tagID;n===J.HEAD||n===J.BODY||n===J.HTML||n===J.BR?cy(e,t):e._err(t,G.endTagWithoutMatchingOpenElement)}function cy(e,t){e._insertFakeElement(q.HEAD,J.HEAD),e.headElement=e.openElements.current,e.insertionMode=Z.IN_HEAD,e._processToken(t)}function ly(e,t){switch(t.tagID){case J.HTML:eb(e,t);break;case J.BASE:case J.BASEFONT:case J.BGSOUND:case J.LINK:case J.META:e._appendElement(t,K.HTML),t.ackSelfClosing=!0;break;case J.TITLE:e._switchToTextParsing(t,L_.RCDATA);break;case J.NOSCRIPT:e.options.scriptingEnabled?e._switchToTextParsing(t,L_.RAWTEXT):(e._insertElement(t,K.HTML),e.insertionMode=Z.IN_HEAD_NO_SCRIPT);break;case J.NOFRAMES:case J.STYLE:e._switchToTextParsing(t,L_.RAWTEXT);break;case J.SCRIPT:e._switchToTextParsing(t,L_.SCRIPT_DATA);break;case J.TEMPLATE:e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=Z.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(Z.IN_TEMPLATE);break;case J.HEAD:e._err(t,G.misplacedStartTagForHeadElement);break;default:fy(e,t)}}function uy(e,t){switch(t.tagID){case J.HEAD:e.openElements.pop(),e.insertionMode=Z.AFTER_HEAD;break;case J.BODY:case J.BR:case J.HTML:fy(e,t);break;case J.TEMPLATE:dy(e,t);break;default:e._err(t,G.endTagWithoutMatchingOpenElement)}}function dy(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==J.TEMPLATE&&e._err(t,G.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(J.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,G.endTagWithoutMatchingOpenElement)}function fy(e,t){e.openElements.pop(),e.insertionMode=Z.AFTER_HEAD,e._processToken(t)}function py(e,t){switch(t.tagID){case J.HTML:eb(e,t);break;case J.BASEFONT:case J.BGSOUND:case J.HEAD:case J.LINK:case J.META:case J.NOFRAMES:case J.STYLE:ly(e,t);break;case J.NOSCRIPT:e._err(t,G.nestedNoscriptInHead);break;default:hy(e,t)}}function my(e,t){switch(t.tagID){case J.NOSCRIPT:e.openElements.pop(),e.insertionMode=Z.IN_HEAD;break;case J.BR:hy(e,t);break;default:e._err(t,G.endTagWithoutMatchingOpenElement)}}function hy(e,t){let n=t.type===h_.EOF?G.openElementsLeftAfterEof:G.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=Z.IN_HEAD,e._processToken(t)}function gy(e,t){switch(t.tagID){case J.HTML:eb(e,t);break;case J.BODY:e._insertElement(t,K.HTML),e.framesetOk=!1,e.insertionMode=Z.IN_BODY;break;case J.FRAMESET:e._insertElement(t,K.HTML),e.insertionMode=Z.IN_FRAMESET;break;case J.BASE:case J.BASEFONT:case J.BGSOUND:case J.LINK:case J.META:case J.NOFRAMES:case J.SCRIPT:case J.STYLE:case J.TEMPLATE:case J.TITLE:e._err(t,G.abandonedHeadElementChild),e.openElements.push(e.headElement,J.HEAD),ly(e,t),e.openElements.remove(e.headElement);break;case J.HEAD:e._err(t,G.misplacedStartTagForHeadElement);break;default:vy(e,t)}}function _y(e,t){switch(t.tagID){case J.BODY:case J.HTML:case J.BR:vy(e,t);break;case J.TEMPLATE:dy(e,t);break;default:e._err(t,G.endTagWithoutMatchingOpenElement)}}function vy(e,t){e._insertFakeElement(q.BODY,J.BODY),e.insertionMode=Z.IN_BODY,yy(e,t)}function yy(e,t){switch(t.type){case h_.CHARACTER:xy(e,t);break;case h_.WHITESPACE_CHARACTER:by(e,t);break;case h_.COMMENT:Zv(e,t);break;case h_.START_TAG:eb(e,t);break;case h_.END_TAG:fb(e,t);break;case h_.EOF:pb(e,t);break;default:}}function by(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function xy(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function Sy(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function Cy(e,t){let n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function wy(e,t){let n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,K.HTML),e.insertionMode=Z.IN_FRAMESET)}function Ty(e,t){e.openElements.hasInButtonScope(J.P)&&e._closePElement(),e._insertElement(t,K.HTML)}function Ey(e,t){e.openElements.hasInButtonScope(J.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&I_.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,K.HTML)}function Dy(e,t){e.openElements.hasInButtonScope(J.P)&&e._closePElement(),e._insertElement(t,K.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function Oy(e,t){let n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(J.P)&&e._closePElement(),e._insertElement(t,K.HTML),n||(e.formElement=e.openElements.current))}function ky(e,t){e.framesetOk=!1;let n=t.tagID;for(let t=e.openElements.stackTop;t>=0;t--){let r=e.openElements.tagIDs[t];if(n===J.LI&&r===J.LI||(n===J.DD||n===J.DT)&&(r===J.DD||r===J.DT)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.popUntilTagNamePopped(r);break}if(r!==J.ADDRESS&&r!==J.DIV&&r!==J.P&&e._isSpecialElement(e.openElements.items[t],r))break}e.openElements.hasInButtonScope(J.P)&&e._closePElement(),e._insertElement(t,K.HTML)}function Ay(e,t){e.openElements.hasInButtonScope(J.P)&&e._closePElement(),e._insertElement(t,K.HTML),e.tokenizer.state=L_.PLAINTEXT}function jy(e,t){e.openElements.hasInScope(J.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(J.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,K.HTML),e.framesetOk=!1}function My(e,t){let n=e.activeFormattingElements.getElementEntryInScopeWithTagName(q.A);n&&(Xv(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,K.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Ny(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,K.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Py(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(J.NOBR)&&(Xv(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,K.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Fy(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,K.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function Iy(e,t){e.treeAdapter.getDocumentMode(e.document)!==M_.QUIRKS&&e.openElements.hasInButtonScope(J.P)&&e._closePElement(),e._insertElement(t,K.HTML),e.framesetOk=!1,e.insertionMode=Z.IN_TABLE}function Ly(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,K.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function Ry(e){let t=g_(e,j_.TYPE);return t!=null&&t.toLowerCase()===Lv}function zy(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,K.HTML),Ry(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function By(e,t){e._appendElement(t,K.HTML),t.ackSelfClosing=!0}function Vy(e,t){e.openElements.hasInButtonScope(J.P)&&e._closePElement(),e._appendElement(t,K.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function Hy(e,t){t.tagName=q.IMG,t.tagID=J.IMG,Ly(e,t)}function Uy(e,t){e._insertElement(t,K.HTML),e.skipNextNewLine=!0,e.tokenizer.state=L_.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=Z.TEXT}function Wy(e,t){e.openElements.hasInButtonScope(J.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,L_.RAWTEXT)}function Gy(e,t){e.framesetOk=!1,e._switchToTextParsing(t,L_.RAWTEXT)}function Ky(e,t){e._switchToTextParsing(t,L_.RAWTEXT)}function qy(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,K.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===Z.IN_TABLE||e.insertionMode===Z.IN_CAPTION||e.insertionMode===Z.IN_TABLE_BODY||e.insertionMode===Z.IN_ROW||e.insertionMode===Z.IN_CELL?Z.IN_SELECT_IN_TABLE:Z.IN_SELECT}function Jy(e,t){e.openElements.currentTagId===J.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,K.HTML)}function Yy(e,t){e.openElements.hasInScope(J.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,K.HTML)}function Xy(e,t){e.openElements.hasInScope(J.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(J.RTC),e._insertElement(t,K.HTML)}function Zy(e,t){e._reconstructActiveFormattingElements(),Av(t),Mv(t),t.selfClosing?e._appendElement(t,K.MATHML):e._insertElement(t,K.MATHML),t.ackSelfClosing=!0}function Qy(e,t){e._reconstructActiveFormattingElements(),jv(t),Mv(t),t.selfClosing?e._appendElement(t,K.SVG):e._insertElement(t,K.SVG),t.ackSelfClosing=!0}function $y(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,K.HTML)}function eb(e,t){switch(t.tagID){case J.I:case J.S:case J.B:case J.U:case J.EM:case J.TT:case J.BIG:case J.CODE:case J.FONT:case J.SMALL:case J.STRIKE:case J.STRONG:Ny(e,t);break;case J.A:My(e,t);break;case J.H1:case J.H2:case J.H3:case J.H4:case J.H5:case J.H6:Ey(e,t);break;case J.P:case J.DL:case J.OL:case J.UL:case J.DIV:case J.DIR:case J.NAV:case J.MAIN:case J.MENU:case J.ASIDE:case J.CENTER:case J.FIGURE:case J.FOOTER:case J.HEADER:case J.HGROUP:case J.DIALOG:case J.DETAILS:case J.ADDRESS:case J.ARTICLE:case J.SEARCH:case J.SECTION:case J.SUMMARY:case J.FIELDSET:case J.BLOCKQUOTE:case J.FIGCAPTION:Ty(e,t);break;case J.LI:case J.DD:case J.DT:ky(e,t);break;case J.BR:case J.IMG:case J.WBR:case J.AREA:case J.EMBED:case J.KEYGEN:Ly(e,t);break;case J.HR:Vy(e,t);break;case J.RB:case J.RTC:Yy(e,t);break;case J.RT:case J.RP:Xy(e,t);break;case J.PRE:case J.LISTING:Dy(e,t);break;case J.XMP:Wy(e,t);break;case J.SVG:Qy(e,t);break;case J.HTML:Sy(e,t);break;case J.BASE:case J.LINK:case J.META:case J.STYLE:case J.TITLE:case J.SCRIPT:case J.BGSOUND:case J.BASEFONT:case J.TEMPLATE:ly(e,t);break;case J.BODY:Cy(e,t);break;case J.FORM:Oy(e,t);break;case J.NOBR:Py(e,t);break;case J.MATH:Zy(e,t);break;case J.TABLE:Iy(e,t);break;case J.INPUT:zy(e,t);break;case J.PARAM:case J.TRACK:case J.SOURCE:By(e,t);break;case J.IMAGE:Hy(e,t);break;case J.BUTTON:jy(e,t);break;case J.APPLET:case J.OBJECT:case J.MARQUEE:Fy(e,t);break;case J.IFRAME:Gy(e,t);break;case J.SELECT:qy(e,t);break;case J.OPTION:case J.OPTGROUP:Jy(e,t);break;case J.NOEMBED:case J.NOFRAMES:Ky(e,t);break;case J.FRAMESET:wy(e,t);break;case J.TEXTAREA:Uy(e,t);break;case J.NOSCRIPT:e.options.scriptingEnabled?Ky(e,t):$y(e,t);break;case J.PLAINTEXT:Ay(e,t);break;case J.COL:case J.TH:case J.TD:case J.TR:case J.HEAD:case J.FRAME:case J.TBODY:case J.TFOOT:case J.THEAD:case J.CAPTION:case J.COLGROUP:break;default:$y(e,t)}}function tb(e,t){if(e.openElements.hasInScope(J.BODY)&&(e.insertionMode=Z.AFTER_BODY,e.options.sourceCodeLocationInfo)){let n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function nb(e,t){e.openElements.hasInScope(J.BODY)&&(e.insertionMode=Z.AFTER_BODY,Zb(e,t))}function rb(e,t){let n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function ib(e){let t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(J.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(J.FORM):n&&e.openElements.remove(n))}function ab(e){e.openElements.hasInButtonScope(J.P)||e._insertFakeElement(q.P,J.P),e._closePElement()}function ob(e){e.openElements.hasInListItemScope(J.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(J.LI),e.openElements.popUntilTagNamePopped(J.LI))}function sb(e,t){let n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function cb(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function lb(e,t){let n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function ub(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(q.BR,J.BR),e.openElements.pop(),e.framesetOk=!1}function db(e,t){let n=t.tagName,r=t.tagID;for(let t=e.openElements.stackTop;t>0;t--){let i=e.openElements.items[t],a=e.openElements.tagIDs[t];if(r===a&&(r!==J.UNKNOWN||e.treeAdapter.getTagName(i)===n)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.stackTop>=t&&e.openElements.shortenToLength(t);break}if(e._isSpecialElement(i,a))break}}function fb(e,t){switch(t.tagID){case J.A:case J.B:case J.I:case J.S:case J.U:case J.EM:case J.TT:case J.BIG:case J.CODE:case J.FONT:case J.NOBR:case J.SMALL:case J.STRIKE:case J.STRONG:Xv(e,t);break;case J.P:ab(e);break;case J.DL:case J.UL:case J.OL:case J.DIR:case J.DIV:case J.NAV:case J.PRE:case J.MAIN:case J.MENU:case J.ASIDE:case J.BUTTON:case J.CENTER:case J.FIGURE:case J.FOOTER:case J.HEADER:case J.HGROUP:case J.DIALOG:case J.ADDRESS:case J.ARTICLE:case J.DETAILS:case J.SEARCH:case J.SECTION:case J.SUMMARY:case J.LISTING:case J.FIELDSET:case J.BLOCKQUOTE:case J.FIGCAPTION:rb(e,t);break;case J.LI:ob(e);break;case J.DD:case J.DT:sb(e,t);break;case J.H1:case J.H2:case J.H3:case J.H4:case J.H5:case J.H6:cb(e);break;case J.BR:ub(e);break;case J.BODY:tb(e,t);break;case J.HTML:nb(e,t);break;case J.FORM:ib(e);break;case J.APPLET:case J.OBJECT:case J.MARQUEE:lb(e,t);break;case J.TEMPLATE:dy(e,t);break;default:db(e,t)}}function pb(e,t){e.tmplInsertionModeStack.length>0?Yb(e,t):ey(e,t)}function mb(e,t){var n;t.tagID===J.SCRIPT&&((n=e.scriptHandler)==null||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function hb(e,t){e._err(t,G.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function gb(e,t){if(e.openElements.currentTagId!==void 0&&Vv.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=Z.IN_TABLE_TEXT,t.type){case h_.CHARACTER:kb(e,t);break;case h_.WHITESPACE_CHARACTER:Ob(e,t);break}else Db(e,t)}function _b(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,K.HTML),e.insertionMode=Z.IN_CAPTION}function vb(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,K.HTML),e.insertionMode=Z.IN_COLUMN_GROUP}function yb(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(q.COLGROUP,J.COLGROUP),e.insertionMode=Z.IN_COLUMN_GROUP,Pb(e,t)}function bb(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,K.HTML),e.insertionMode=Z.IN_TABLE_BODY}function xb(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(q.TBODY,J.TBODY),e.insertionMode=Z.IN_TABLE_BODY,Lb(e,t)}function Sb(e,t){e.openElements.hasInTableScope(J.TABLE)&&(e.openElements.popUntilTagNamePopped(J.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function Cb(e,t){Ry(t)?e._appendElement(t,K.HTML):Db(e,t),t.ackSelfClosing=!0}function wb(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,K.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function Tb(e,t){switch(t.tagID){case J.TD:case J.TH:case J.TR:xb(e,t);break;case J.STYLE:case J.SCRIPT:case J.TEMPLATE:ly(e,t);break;case J.COL:yb(e,t);break;case J.FORM:wb(e,t);break;case J.TABLE:Sb(e,t);break;case J.TBODY:case J.TFOOT:case J.THEAD:bb(e,t);break;case J.INPUT:Cb(e,t);break;case J.CAPTION:_b(e,t);break;case J.COLGROUP:vb(e,t);break;default:Db(e,t)}}function Eb(e,t){switch(t.tagID){case J.TABLE:e.openElements.hasInTableScope(J.TABLE)&&(e.openElements.popUntilTagNamePopped(J.TABLE),e._resetInsertionMode());break;case J.TEMPLATE:dy(e,t);break;case J.BODY:case J.CAPTION:case J.COL:case J.COLGROUP:case J.HTML:case J.TBODY:case J.TD:case J.TFOOT:case J.TH:case J.THEAD:case J.TR:break;default:Db(e,t)}}function Db(e,t){let n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,yy(e,t),e.fosterParentingEnabled=n}function Ob(e,t){e.pendingCharacterTokens.push(t)}function kb(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function Ab(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)Db(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}var jb=new Set([J.CAPTION,J.COL,J.COLGROUP,J.TBODY,J.TD,J.TFOOT,J.TH,J.THEAD,J.TR]);function Mb(e,t){let n=t.tagID;jb.has(n)?e.openElements.hasInTableScope(J.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(J.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=Z.IN_TABLE,Tb(e,t)):eb(e,t)}function Nb(e,t){let n=t.tagID;switch(n){case J.CAPTION:case J.TABLE:e.openElements.hasInTableScope(J.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(J.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=Z.IN_TABLE,n===J.TABLE&&Eb(e,t));break;case J.BODY:case J.COL:case J.COLGROUP:case J.HTML:case J.TBODY:case J.TD:case J.TFOOT:case J.TH:case J.THEAD:case J.TR:break;default:fb(e,t)}}function Pb(e,t){switch(t.tagID){case J.HTML:eb(e,t);break;case J.COL:e._appendElement(t,K.HTML),t.ackSelfClosing=!0;break;case J.TEMPLATE:ly(e,t);break;default:Ib(e,t)}}function Fb(e,t){switch(t.tagID){case J.COLGROUP:e.openElements.currentTagId===J.COLGROUP&&(e.openElements.pop(),e.insertionMode=Z.IN_TABLE);break;case J.TEMPLATE:dy(e,t);break;case J.COL:break;default:Ib(e,t)}}function Ib(e,t){e.openElements.currentTagId===J.COLGROUP&&(e.openElements.pop(),e.insertionMode=Z.IN_TABLE,e._processToken(t))}function Lb(e,t){switch(t.tagID){case J.TR:e.openElements.clearBackToTableBodyContext(),e._insertElement(t,K.HTML),e.insertionMode=Z.IN_ROW;break;case J.TH:case J.TD:e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(q.TR,J.TR),e.insertionMode=Z.IN_ROW,zb(e,t);break;case J.CAPTION:case J.COL:case J.COLGROUP:case J.TBODY:case J.TFOOT:case J.THEAD:e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=Z.IN_TABLE,Tb(e,t));break;default:Tb(e,t)}}function Rb(e,t){let n=t.tagID;switch(t.tagID){case J.TBODY:case J.TFOOT:case J.THEAD:e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=Z.IN_TABLE);break;case J.TABLE:e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=Z.IN_TABLE,Eb(e,t));break;case J.BODY:case J.CAPTION:case J.COL:case J.COLGROUP:case J.HTML:case J.TD:case J.TH:case J.TR:break;default:Eb(e,t)}}function zb(e,t){switch(t.tagID){case J.TH:case J.TD:e.openElements.clearBackToTableRowContext(),e._insertElement(t,K.HTML),e.insertionMode=Z.IN_CELL,e.activeFormattingElements.insertMarker();break;case J.CAPTION:case J.COL:case J.COLGROUP:case J.TBODY:case J.TFOOT:case J.THEAD:case J.TR:e.openElements.hasInTableScope(J.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=Z.IN_TABLE_BODY,Lb(e,t));break;default:Tb(e,t)}}function Bb(e,t){switch(t.tagID){case J.TR:e.openElements.hasInTableScope(J.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=Z.IN_TABLE_BODY);break;case J.TABLE:e.openElements.hasInTableScope(J.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=Z.IN_TABLE_BODY,Rb(e,t));break;case J.TBODY:case J.TFOOT:case J.THEAD:(e.openElements.hasInTableScope(t.tagID)||e.openElements.hasInTableScope(J.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=Z.IN_TABLE_BODY,Rb(e,t));break;case J.BODY:case J.CAPTION:case J.COL:case J.COLGROUP:case J.HTML:case J.TD:case J.TH:break;default:Eb(e,t)}}function Vb(e,t){let n=t.tagID;jb.has(n)?(e.openElements.hasInTableScope(J.TD)||e.openElements.hasInTableScope(J.TH))&&(e._closeTableCell(),zb(e,t)):eb(e,t)}function Hb(e,t){let n=t.tagID;switch(n){case J.TD:case J.TH:e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=Z.IN_ROW);break;case J.TABLE:case J.TBODY:case J.TFOOT:case J.THEAD:case J.TR:e.openElements.hasInTableScope(n)&&(e._closeTableCell(),Bb(e,t));break;case J.BODY:case J.CAPTION:case J.COL:case J.COLGROUP:case J.HTML:break;default:fb(e,t)}}function Ub(e,t){switch(t.tagID){case J.HTML:eb(e,t);break;case J.OPTION:e.openElements.currentTagId===J.OPTION&&e.openElements.pop(),e._insertElement(t,K.HTML);break;case J.OPTGROUP:e.openElements.currentTagId===J.OPTION&&e.openElements.pop(),e.openElements.currentTagId===J.OPTGROUP&&e.openElements.pop(),e._insertElement(t,K.HTML);break;case J.HR:e.openElements.currentTagId===J.OPTION&&e.openElements.pop(),e.openElements.currentTagId===J.OPTGROUP&&e.openElements.pop(),e._appendElement(t,K.HTML),t.ackSelfClosing=!0;break;case J.INPUT:case J.KEYGEN:case J.TEXTAREA:case J.SELECT:e.openElements.hasInSelectScope(J.SELECT)&&(e.openElements.popUntilTagNamePopped(J.SELECT),e._resetInsertionMode(),t.tagID!==J.SELECT&&e._processStartTag(t));break;case J.SCRIPT:case J.TEMPLATE:ly(e,t);break;default:}}function Wb(e,t){switch(t.tagID){case J.OPTGROUP:e.openElements.stackTop>0&&e.openElements.currentTagId===J.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===J.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===J.OPTGROUP&&e.openElements.pop();break;case J.OPTION:e.openElements.currentTagId===J.OPTION&&e.openElements.pop();break;case J.SELECT:e.openElements.hasInSelectScope(J.SELECT)&&(e.openElements.popUntilTagNamePopped(J.SELECT),e._resetInsertionMode());break;case J.TEMPLATE:dy(e,t);break;default:}}function Gb(e,t){let n=t.tagID;n===J.CAPTION||n===J.TABLE||n===J.TBODY||n===J.TFOOT||n===J.THEAD||n===J.TR||n===J.TD||n===J.TH?(e.openElements.popUntilTagNamePopped(J.SELECT),e._resetInsertionMode(),e._processStartTag(t)):Ub(e,t)}function Kb(e,t){let n=t.tagID;n===J.CAPTION||n===J.TABLE||n===J.TBODY||n===J.TFOOT||n===J.THEAD||n===J.TR||n===J.TD||n===J.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(J.SELECT),e._resetInsertionMode(),e.onEndTag(t)):Wb(e,t)}function qb(e,t){switch(t.tagID){case J.BASE:case J.BASEFONT:case J.BGSOUND:case J.LINK:case J.META:case J.NOFRAMES:case J.SCRIPT:case J.STYLE:case J.TEMPLATE:case J.TITLE:ly(e,t);break;case J.CAPTION:case J.COLGROUP:case J.TBODY:case J.TFOOT:case J.THEAD:e.tmplInsertionModeStack[0]=Z.IN_TABLE,e.insertionMode=Z.IN_TABLE,Tb(e,t);break;case J.COL:e.tmplInsertionModeStack[0]=Z.IN_COLUMN_GROUP,e.insertionMode=Z.IN_COLUMN_GROUP,Pb(e,t);break;case J.TR:e.tmplInsertionModeStack[0]=Z.IN_TABLE_BODY,e.insertionMode=Z.IN_TABLE_BODY,Lb(e,t);break;case J.TD:case J.TH:e.tmplInsertionModeStack[0]=Z.IN_ROW,e.insertionMode=Z.IN_ROW,zb(e,t);break;default:e.tmplInsertionModeStack[0]=Z.IN_BODY,e.insertionMode=Z.IN_BODY,eb(e,t)}}function Jb(e,t){t.tagID===J.TEMPLATE&&dy(e,t)}function Yb(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(J.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):ey(e,t)}function Xb(e,t){t.tagID===J.HTML?eb(e,t):Qb(e,t)}function Zb(e,t){if(t.tagID===J.HTML){if(e.fragmentContext||(e.insertionMode=Z.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===J.HTML){e._setEndLocation(e.openElements.items[0],t);let n=e.openElements.items[1];n&&!e.treeAdapter.getNodeSourceCodeLocation(n)?.endTag&&e._setEndLocation(n,t)}}else Qb(e,t)}function Qb(e,t){e.insertionMode=Z.IN_BODY,yy(e,t)}function $b(e,t){switch(t.tagID){case J.HTML:eb(e,t);break;case J.FRAMESET:e._insertElement(t,K.HTML);break;case J.FRAME:e._appendElement(t,K.HTML),t.ackSelfClosing=!0;break;case J.NOFRAMES:ly(e,t);break;default:}}function ex(e,t){t.tagID===J.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==J.FRAMESET&&(e.insertionMode=Z.AFTER_FRAMESET))}function tx(e,t){switch(t.tagID){case J.HTML:eb(e,t);break;case J.NOFRAMES:ly(e,t);break;default:}}function nx(e,t){t.tagID===J.HTML&&(e.insertionMode=Z.AFTER_AFTER_FRAMESET)}function rx(e,t){t.tagID===J.HTML?eb(e,t):ix(e,t)}function ix(e,t){e.insertionMode=Z.IN_BODY,yy(e,t)}function ax(e,t){switch(t.tagID){case J.HTML:eb(e,t);break;case J.NOFRAMES:ly(e,t);break;default:}}function ox(e,t){t.chars=`�`,e._insertCharacters(t)}function sx(e,t){e._insertCharacters(t),e.framesetOk=!1}function cx(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==K.HTML&&e.openElements.currentTagId!==void 0&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function lx(e,t){if(kv(t))cx(e),e._startTagOutsideForeignContent(t);else{let n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===K.MATHML?Av(t):r===K.SVG&&(Nv(t),jv(t)),Mv(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function ux(e,t){if(t.tagID===J.P||t.tagID===J.BR){cx(e),e._endTagOutsideForeignContent(t);return}for(let n=e.openElements.stackTop;n>0;n--){let r=e.openElements.items[n];if(e.treeAdapter.getNamespaceURI(r)===K.HTML){e._endTagOutsideForeignContent(t);break}let i=e.treeAdapter.getTagName(r);if(i.toLowerCase()===t.tagName){t.tagName=i,e.openElements.shortenToLength(n);break}}}new Set([q.AREA,q.BASE,q.BASEFONT,q.BGSOUND,q.BR,q.COL,q.EMBED,q.FRAME,q.HR,q.IMG,q.INPUT,q.KEYGEN,q.LINK,q.META,q.PARAM,q.SOURCE,q.TRACK,q.WBR]);var dx=px(`end`),fx=px(`start`);function px(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 mx(e){let t=fx(e),n=dx(e);if(t&&n)return{start:t,end:n}}var hx=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,gx=new Set([`mdxFlowExpression`,`mdxJsxFlowElement`,`mdxJsxTextElement`,`mdxTextExpression`,`mdxjsEsm`]),_x={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function vx(e,t){let n=Mx(e),r=Gg(`type`,{handlers:{root:bx,element:xx,text:Sx,comment:Tx,doctype:Cx,raw:Ex},unknown:Dx}),i={parser:n?new Uv(_x):Uv.getFragmentParser(void 0,_x),handle(e){r(e,i)},stitches:!1,options:t||{}};r(e,i),Ox(i,fx());let a=Ig(n?i.parser.document:i.parser.getFragment(),{file:i.options.file});return i.stitches&&dh(a,`comment`,function(e,t,n){let r=e;if(r.value.stitch&&n&&t!==void 0){let e=n.children;return e[t]=r.value.stitch,t}}),a.type===`root`&&a.children.length===1&&a.children[0].type===e.type?a.children[0]:a}function yx(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function bx(e,t){yx(e.children,t)}function xx(e,t){Ax(e,t),yx(e.children,t),jx(e,t)}function Sx(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);let n={type:h_.CHARACTER,chars:e.value,location:Nx(e)};Ox(t,fx(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function Cx(e,t){let n={type:h_.DOCTYPE,name:`html`,forceQuirks:!1,publicId:``,systemId:``,location:Nx(e)};Ox(t,fx(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function wx(e,t){t.stitches=!0;let n=Px(e);`children`in e&&`children`in n&&(n.children=vx({type:`root`,children:e.children},t.options).children),Tx({type:`comment`,value:{stitch:n}},t)}function Tx(e,t){let n=e.value,r={type:h_.COMMENT,data:n,location:Nx(e)};Ox(t,fx(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function Ex(e,t){if(t.parser.tokenizer.preprocessor.html=``,t.parser.tokenizer.preprocessor.pos=-1,t.parser.tokenizer.preprocessor.lastGapPos=-2,t.parser.tokenizer.preprocessor.gapStack=[],t.parser.tokenizer.preprocessor.skipNextNewLine=!1,t.parser.tokenizer.preprocessor.lastChunkWritten=!1,t.parser.tokenizer.preprocessor.endOfChunkHit=!1,t.parser.tokenizer.preprocessor.isEol=!1,kx(t,fx(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(hx,`&lt;$1$2`):e.value,!1),t.parser.tokenizer._runParsingLoop(),t.parser.tokenizer.state===72||t.parser.tokenizer.state===78){t.parser.tokenizer.preprocessor.lastChunkWritten=!0;let e=t.parser.tokenizer._consume();t.parser.tokenizer._callState(e)}}function Dx(e,t){let n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))wx(n,t);else{let e=``;throw gx.has(n.type)&&(e=". It looks like you are using MDX nodes with `hast-util-raw` (or `rehype-raw`). If you use this because you are using remark or rehype plugins that inject `'html'` nodes, then please raise an issue with that plugin, as its a bad and slow idea. If you use this because you are using markdown syntax, then you have to configure this utility (or plugin) to pass through these nodes (see `passThrough` in docs), but you can also migrate to use the MDX syntax"),Error("Cannot compile `"+n.type+"` node"+e)}}function Ox(e,t){kx(e,t);let n=e.parser.tokenizer.currentCharacterToken;n&&n.location&&(n.location.endLine=e.parser.tokenizer.preprocessor.line,n.location.endCol=e.parser.tokenizer.preprocessor.col+1,n.location.endOffset=e.parser.tokenizer.preprocessor.offset+1,e.parser.currentToken=n,e.parser._processToken(e.parser.currentToken)),e.parser.tokenizer.paused=!1,e.parser.tokenizer.inLoop=!1,e.parser.tokenizer.active=!1,e.parser.tokenizer.returnState=L_.DATA,e.parser.tokenizer.charRefCode=-1,e.parser.tokenizer.consumedAfterSnapshot=-1,e.parser.tokenizer.currentLocation=null,e.parser.tokenizer.currentCharacterToken=null,e.parser.tokenizer.currentToken=null,e.parser.tokenizer.currentAttr={name:``,value:``}}function kx(e,t){if(t&&t.offset!==void 0){let n={startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:-1,endCol:-1,endOffset:-1};e.parser.tokenizer.preprocessor.lineStartPos=-t.column+1,e.parser.tokenizer.preprocessor.droppedBufferSize=t.offset,e.parser.tokenizer.preprocessor.line=t.line,e.parser.tokenizer.currentLocation=n}}function Ax(e,t){let n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===L_.PLAINTEXT)return;Ox(t,fx(e));let r=t.parser.openElements.current,i=`namespaceURI`in r?r.namespaceURI:Ng.html;i===Ng.html&&n===`svg`&&(i=Ng.svg);let a=Yg({...e,children:[]},{space:i===Ng.svg?`svg`:`html`}),o={type:h_.START_TAG,tagName:n,tagID:P_(n),selfClosing:!1,ackSelfClosing:!1,attrs:`attrs`in a?a.attrs:[],location:Nx(e)};t.parser.currentToken=o,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function jx(e,t){let n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&a_.includes(n)||t.parser.tokenizer.state===L_.PLAINTEXT)return;Ox(t,dx(e));let r={type:h_.END_TAG,tagName:n,tagID:P_(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:Nx(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===L_.RCDATA||t.parser.tokenizer.state===L_.RAWTEXT||t.parser.tokenizer.state===L_.SCRIPT_DATA)&&(t.parser.tokenizer.state=L_.DATA)}function Mx(e){let t=e.type===`root`?e.children[0]:e;return!!(t&&(t.type===`doctype`||t.type===`element`&&t.tagName.toLowerCase()===`html`))}function Nx(e){let t=fx(e)||{line:void 0,column:void 0,offset:void 0},n=dx(e)||{line:void 0,column:void 0,offset:void 0};return{startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:n.line,endCol:n.column,endOffset:n.offset}}function Px(e){return`children`in e?Ph({...e,children:[]}):Ph(e)}function Fx(e){return function(t,n){return vx(t,{...e,file:n})}}var Ix=[`ariaDescribedBy`,`ariaLabel`,`ariaLabelledBy`],Lx={ancestors:{tbody:[`table`],td:[`table`],th:[`table`],thead:[`table`],tfoot:[`table`],tr:[`table`]},attributes:{a:[...Ix,`dataFootnoteBackref`,`dataFootnoteRef`,[`className`,`data-footnote-backref`],`href`],blockquote:[`cite`],code:[[`className`,/^language-./]],del:[`cite`],div:[`itemScope`,`itemType`],dl:[...Ix],h2:[[`className`,`sr-only`]],img:[...Ix,`longDesc`,`src`],input:[[`disabled`,!0],[`type`,`checkbox`]],ins:[`cite`],li:[[`className`,`task-list-item`]],ol:[...Ix,[`className`,`contains-task-list`]],q:[`cite`],section:[`dataFootnotes`,[`className`,`footnotes`]],source:[`srcSet`],summary:[...Ix],table:[...Ix],ul:[...Ix,[`className`,`contains-task-list`]],"*":`abbr.accept.acceptCharset.accessKey.action.align.alt.axis.border.cellPadding.cellSpacing.char.charOff.charSet.checked.clear.colSpan.color.cols.compact.coords.dateTime.dir.encType.frame.hSpace.headers.height.hrefLang.htmlFor.id.isMap.itemProp.label.lang.maxLength.media.method.multiple.name.noHref.noShade.noWrap.open.prompt.readOnly.rev.rowSpan.rows.rules.scope.selected.shape.size.span.start.summary.tabIndex.title.useMap.vAlign.value.width`.split(`.`)},clobber:[`ariaDescribedBy`,`ariaLabelledBy`,`id`,`name`],clobberPrefix:`user-content-`,protocols:{cite:[`http`,`https`],href:[`http`,`https`,`irc`,`ircs`,`mailto`,`xmpp`],longDesc:[`http`,`https`],src:[`http`,`https`]},required:{input:{disabled:!0,type:`checkbox`}},strip:[`script`],tagNames:`a.b.blockquote.br.code.dd.del.details.div.dl.dt.em.h1.h2.h3.h4.h5.h6.hr.i.img.input.ins.kbd.li.ol.p.picture.pre.q.rp.rt.ruby.s.samp.section.source.span.strike.strong.sub.summary.sup.table.tbody.td.tfoot.th.thead.tr.tt.ul.var`.split(`.`)},Rx={}.hasOwnProperty;function zx(e,t){let n={type:`root`,children:[]},r=Bx({schema:t?{...Lx,...t}:Lx,stack:[]},e);return r&&(Array.isArray(r)?r.length===1?n=r[0]:n.children=r:n=r),n}function Bx(e,t){if(t&&typeof t==`object`){let n=t;switch(typeof n.type==`string`?n.type:``){case`comment`:return Vx(e,n);case`doctype`:return Hx(e,n);case`element`:return Ux(e,n);case`root`:return Wx(e,n);case`text`:return Gx(e,n);default:}}}function Vx(e,t){if(e.schema.allowComments){let e=typeof t.value==`string`?t.value:``,n=e.indexOf(`-->`),r={type:`comment`,value:n<0?e:e.slice(0,n)};return Qx(r,t),r}}function Hx(e,t){if(e.schema.allowDoctypes){let e={type:`doctype`};return Qx(e,t),e}}function Ux(e,t){let n=typeof t.tagName==`string`?t.tagName:``;e.stack.push(n);let r=Kx(e,t.children),i=qx(e,t.properties);e.stack.pop();let a=!1;if(n&&n!==`*`&&(!e.schema.tagNames||e.schema.tagNames.includes(n))&&(a=!0,e.schema.ancestors&&Rx.call(e.schema.ancestors,n))){let t=e.schema.ancestors[n],r=-1;for(a=!1;++r<t.length;)e.stack.includes(t[r])&&(a=!0)}if(!a)return e.schema.strip&&!e.schema.strip.includes(n)?r:void 0;let o={type:`element`,tagName:n,properties:i,children:r};return Qx(o,t),o}function Wx(e,t){let n={type:`root`,children:Kx(e,t.children)};return Qx(n,t),n}function Gx(e,t){let n={type:`text`,value:typeof t.value==`string`?t.value:``};return Qx(n,t),n}function Kx(e,t){let n=[];if(Array.isArray(t)){let r=t,i=-1;for(;++i<r.length;){let t=Bx(e,r[i]);t&&(Array.isArray(t)?n.push(...t):n.push(t))}}return n}function qx(e,t){let n=e.stack[e.stack.length-1],r=e.schema.attributes,i=e.schema.required,a=r&&Rx.call(r,n)?r[n]:void 0,o=r&&Rx.call(r,`*`)?r[`*`]:void 0,s=t&&typeof t==`object`?t:{},c={},l;for(l in s)if(Rx.call(s,l)){let t=s[l],n=Jx(e,$x(a,l),l,t);n??=Jx(e,$x(o,l),l,t),n!=null&&(c[l]=n)}if(i&&Rx.call(i,n)){let e=i[n];for(l in e)Rx.call(e,l)&&!Rx.call(c,l)&&(c[l]=e[l])}return c}function Jx(e,t,n,r){return t?Array.isArray(r)?Yx(e,t,n,r):Xx(e,t,n,r):void 0}function Yx(e,t,n,r){let i=-1,a=[];for(;++i<r.length;){let o=Xx(e,t,n,r[i]);(typeof o==`number`||typeof o==`string`)&&a.push(o)}return a}function Xx(e,t,n,r){if(!(typeof r!=`boolean`&&typeof r!=`number`&&typeof r!=`string`)&&Zx(e,n,r)){if(typeof t==`object`&&t.length>1){let e=!1,n=0;for(;++n<t.length;){let i=t[n];if(i&&typeof i==`object`&&`flags`in i){if(i.test(String(r))){e=!0;break}}else if(i===r){e=!0;break}}if(!e)return}return e.schema.clobber&&e.schema.clobberPrefix&&e.schema.clobber.includes(n)?e.schema.clobberPrefix+r:r}}function Zx(e,t,n){let r=e.schema.protocols&&Rx.call(e.schema.protocols,t)?e.schema.protocols[t]:void 0;if(!r||r.length===0)return!0;let i=String(n),a=i.indexOf(`:`),o=i.indexOf(`?`),s=i.indexOf(`#`),c=i.indexOf(`/`);if(a<0||c>-1&&a>c||o>-1&&a>o||s>-1&&a>s)return!0;let l=-1;for(;++l<r.length;){let e=r[l];if(a===e.length&&i.slice(0,e.length)===e)return!0}return!1}function Qx(e,t){let n=mx(t);t.data&&(e.data=Ph(t.data)),n&&(e.position=n)}function $x(e,t){let n,r=-1;if(e)for(;++r<e.length;){let i=e[r],a=typeof i==`string`?i:i[0];if(a===t)return i;a===`data*`&&(n=i)}if(t.length>4&&t.slice(0,4).toLowerCase()===`data`)return n}function eS(e){return function(t){return zx(t,e)}}function tS(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}var nS=pS(/[A-Za-z]/),rS=pS(/[\dA-Za-z]/),iS=pS(/[#-'*+\--9=?A-Z^-~]/);function aS(e){return e!==null&&(e<32||e===127)}var oS=pS(/\d/),sS=pS(/[\dA-Fa-f]/),cS=pS(/[!-/:-@[-`{-~]/);function Q(e){return e!==null&&e<-2}function lS(e){return e!==null&&(e<0||e===32)}function uS(e){return e===-2||e===-1||e===32}var dS=pS(/\p{P}|\p{S}/u),fS=pS(/\s/);function pS(e){return t;function t(t){return t!==null&&t>-1&&e.test(String.fromCharCode(t))}}function mS(e){if(typeof e!=`string`)throw TypeError(`Expected a string`);return e.replace(/[|\\{}()[\]^$+*?.]/g,`\\$&`).replace(/-/g,`\\x2d`)}function hS(e,t,n){let r=$m((n||{}).ignore||[]),i=gS(t),a=-1;for(;++a<i.length;)lh(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 gS(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([_S(e[0]),vS(e[1])])}return t}function _S(e){return typeof e==`string`?new RegExp(mS(e),`g`):e}function vS(e){return typeof e==`function`?e:function(){return e}}var yS=`phrasing`,bS=[`autolink`,`link`,`image`,`label`];function xS(){return{transforms:[kS],enter:{literalAutolink:CS,literalAutolinkEmail:wS,literalAutolinkHttp:wS,literalAutolinkWww:wS},exit:{literalAutolink:OS,literalAutolinkEmail:DS,literalAutolinkHttp:TS,literalAutolinkWww:ES}}}function SS(){return{unsafe:[{character:`@`,before:`[+\\-.\\w]`,after:`[\\-.\\w]`,inConstruct:yS,notInConstruct:bS},{character:`.`,before:`[Ww]`,after:`[\\-.\\w]`,inConstruct:yS,notInConstruct:bS},{character:`:`,before:`[ps]`,after:`\\/`,inConstruct:yS,notInConstruct:bS}]}}function CS(e){this.enter({type:`link`,title:null,url:``,children:[]},e)}function wS(e){this.config.enter.autolinkProtocol.call(this,e)}function TS(e){this.config.exit.autolinkProtocol.call(this,e)}function ES(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 DS(e){this.config.exit.autolinkEmail.call(this,e)}function OS(e){this.exit(e)}function kS(e){hS(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,AS],[/(?<=^|\s|\p{P}|\p{S})([-.\w+]+)@([-\w]+(?:\.[-\w]+)+)/gu,jS]],{ignore:[`link`,`linkReference`]})}function AS(e,t,n,r,i){let a=``;if(!PS(i)||(/^w/i.test(t)&&(n=t+n,t=``,a=`http://`),!MS(n)))return!1;let o=NS(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 jS(e,t,n,r){return!PS(r,!0)||/[-\d_]$/.test(n)?!1:{type:`link`,title:null,url:`mailto:`+t+`@`+n,children:[{type:`text`,value:t+`@`+n}]}}function MS(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 NS(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=tS(e,`(`),a=tS(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 PS(e,t){let n=e.input.charCodeAt(e.index-1);return(e.index===0||fS(n)||dS(n))&&(!t||n!==47)}function FS(e){return e.replace(/[\t\n\r ]+/g,` `).replace(/^ | $/g,``).toLowerCase().toUpperCase()}GS.peek=WS;function IS(){this.buffer()}function LS(e){this.enter({type:`footnoteReference`,identifier:``,label:``},e)}function RS(){this.buffer()}function zS(e){this.enter({type:`footnoteDefinition`,identifier:``,label:``,children:[]},e)}function BS(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=FS(this.sliceSerialize(e)).toLowerCase(),n.label=t}function VS(e){this.exit(e)}function HS(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=FS(this.sliceSerialize(e)).toLowerCase(),n.label=t}function US(e){this.exit(e)}function WS(){return`[`}function GS(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 KS(){return{enter:{gfmFootnoteCallString:IS,gfmFootnoteCall:LS,gfmFootnoteDefinitionLabelString:RS,gfmFootnoteDefinition:zS},exit:{gfmFootnoteCallString:BS,gfmFootnoteCall:VS,gfmFootnoteDefinitionLabelString:HS,gfmFootnoteDefinition:US}}}function qS(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:GS},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?`
70
- `:` `)+r.indentLines(r.containerFlow(e,a.current()),t?YS:JS))),s(),o}}function JS(e,t,n){return t===0?e:YS(e,t,n)}function YS(e,t,n){return(n?``:` `)+e}var XS=[`autolink`,`destinationLiteral`,`destinationRaw`,`reference`,`titleQuote`,`titleApostrophe`];tC.peek=nC;function ZS(){return{canContainEols:[`delete`],enter:{strikethrough:$S},exit:{strikethrough:eC}}}function QS(){return{unsafe:[{character:`~`,inConstruct:`phrasing`,notInConstruct:XS}],handlers:{delete:tC}}}function $S(e){this.enter({type:`delete`,children:[]},e)}function eC(e){this.exit(e)}function tC(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 nC(){return`~`}function rC(e){return e.length}function iC(e,t){let n=t||{},r=(n.align||[]).concat(),i=n.stringLength||rC,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=aC(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]=oC(r[d]);else{let e=oC(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(`
71
- `)}function aC(e){return e==null?``:String(e)}function oC(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 sC(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()),cC);return i(),o}function cC(e,t,n){return`>`+(n?``:` `)+e}function lC(e,t){return uC(e,t.inConstruct,!0)&&!uC(e,t.notInConstruct,!1)}function uC(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 dC(e,t,n,r){let i=-1;for(;++i<n.unsafe.length;)if(n.unsafe[i].character===`
72
- `&&lC(n.stack,n.unsafe[i]))return/[ \t]/.test(r.before)?``:` `;return`\\
73
- `}function fC(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 pC(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 mC(e){let t=e.options.fence||"`";if(t!=="`"&&t!==`~`)throw Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}function hC(e,t,n,r){let i=mC(n),a=e.value||``,o=i==="`"?`GraveAccent`:`Tilde`;if(pC(e,n)){let e=n.enter(`codeIndented`),t=n.indentLines(a,gC);return e(),t}let s=n.createTracker(r),c=i.repeat(Math.max(fC(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:`
74
- `,encode:["`"],...s.current()})),t()}return u+=s.move(`
75
- `),a&&(u+=s.move(a+`
76
- `)),u+=s.move(c),l(),u}function gC(e,t,n){return(n?``:` `)+e}function _C(e){let t=e.options.quote||`"`;if(t!==`"`&&t!==`'`)throw Error("Cannot serialize title with `"+t+"` for `options.quote`, expected `\"`, or `'`");return t}function vC(e,t,n,r){let i=_C(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?` `:`
77
- `,...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 yC(e){let t=e.options.emphasis||`*`;if(t!==`*`&&t!==`_`)throw Error("Cannot serialize emphasis with `"+t+"` for `options.emphasis`, expected `*`, or `_`");return t}function bC(e){return`&#x`+e.toString(16).toUpperCase()+`;`}function xC(e){if(e===null||lS(e)||fS(e))return 1;if(dS(e))return 2}function SC(e,t,n){let r=xC(e),i=xC(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}}CC.peek=wC;function CC(e,t,n,r){let i=yC(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=SC(r.before.charCodeAt(r.before.length-1),l,i);u.inside&&(c=bC(l)+c.slice(1));let d=c.charCodeAt(c.length-1),f=SC(r.after.charCodeAt(0),d,i);f.inside&&(c=c.slice(0,-1)+bC(d));let p=o.move(i);return a(),n.attentionEncodeSurroundingInfo={after:f.outside,before:u.outside},s+c+p}function wC(e,t,n){return n.options.emphasis||`*`}var TC={};function EC(e,t){let n=t||TC;return DC(e,typeof n.includeImageAlt==`boolean`?n.includeImageAlt:!0,typeof n.includeHtml==`boolean`?n.includeHtml:!0)}function DC(e,t,n){if(kC(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 OC(e.children,t,n)}return Array.isArray(e)?OC(e,t,n):``}function OC(e,t,n){let r=[],i=-1;for(;++i<e.length;)r[i]=DC(e[i],t,n);return r.join(``)}function kC(e){return!!(e&&typeof e==`object`)}function AC(e,t){let n=!1;return dh(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)&&EC(e)&&(t.options.setext||n))}function jC(e,t,n,r){let i=Math.max(Math.min(6,e.depth||1),1),a=n.createTracker(r);if(AC(e,n)){let t=n.enter(`headingSetext`),r=n.enter(`phrasing`),o=n.containerPhrasing(e,{...a.current(),before:`
78
- `,after:`
79
- `});return r(),t(),o+`
80
- `+(i===1?`=`:`-`).repeat(o.length-(Math.max(o.lastIndexOf(`\r`),o.lastIndexOf(`
81
- `))+1))}let o=`#`.repeat(i),s=n.enter(`headingAtx`),c=n.enter(`phrasing`);a.move(o+` `);let l=n.containerPhrasing(e,{before:`# `,after:`
82
- `,...a.current()});return/^[\t ]/.test(l)&&(l=bC(l.charCodeAt(0))+l.slice(1)),l=l?o+` `+l:o,n.options.closeAtx&&(l+=` `+o),c(),s(),l}MC.peek=NC;function MC(e){return e.value||``}function NC(){return`<`}PC.peek=FC;function PC(e,t,n,r){let i=_C(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 FC(){return`!`}IC.peek=LC;function IC(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 LC(){return`!`}RC.peek=zC;function RC(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 zC(){return"`"}function BC(e,t){let n=EC(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))}VC.peek=HC;function VC(e,t,n,r){let i=_C(n),a=i===`"`?`Quote`:`Apostrophe`,o=n.createTracker(r),s,c;if(BC(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 HC(e,t,n){return BC(e,n)?`<`:`[`}UC.peek=WC;function UC(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 WC(){return`[`}function GC(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 KC(e){let t=GC(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 qC(e){let t=e.options.bulletOrdered||`.`;if(t!==`.`&&t!==`)`)throw Error("Cannot serialize items with `"+t+"` for `options.bulletOrdered`, expected `.` or `)`");return t}function JC(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 YC(e,t,n,r){let i=n.enter(`list`),a=n.bulletCurrent,o=e.ordered?qC(n):GC(n),s=e.ordered?o===`.`?`)`:`.`:KC(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),JC(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 XC(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 ZC(e,t,n,r){let i=XC(n),a=n.bulletCurrent||GC(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 QC(e,t,n,r){let i=n.enter(`paragraph`),a=n.enter(`phrasing`),o=n.containerPhrasing(e,r);return a(),i(),o}var $C=$m([`break`,`delete`,`emphasis`,`footnote`,`footnoteReference`,`image`,`imageReference`,`inlineCode`,`inlineMath`,`link`,`linkReference`,`mdxJsxTextElement`,`mdxTextExpression`,`strong`,`text`,`textDirective`]);function ew(e,t,n,r){return(e.children.some(function(e){return $C(e)})?n.containerPhrasing:n.containerFlow).call(n,e,r)}function tw(e){let t=e.options.strong||`*`;if(t!==`*`&&t!==`_`)throw Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}nw.peek=rw;function nw(e,t,n,r){let i=tw(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=SC(r.before.charCodeAt(r.before.length-1),l,i);u.inside&&(c=bC(l)+c.slice(1));let d=c.charCodeAt(c.length-1),f=SC(r.after.charCodeAt(0),d,i);f.inside&&(c=c.slice(0,-1)+bC(d));let p=o.move(i+i);return a(),n.attentionEncodeSurroundingInfo={after:f.outside,before:u.outside},s+c+p}function rw(e,t,n){return n.options.strong||`*`}function iw(e,t,n,r){return n.safe(e.value,r)}function aw(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 ow(e,t,n){let r=(JC(n)+(n.options.ruleSpaces?` `:``)).repeat(aw(n));return n.options.ruleSpaces?r.slice(0,-1):r}var sw={blockquote:sC,break:dC,code:hC,definition:vC,emphasis:CC,hardBreak:dC,heading:jC,html:MC,image:PC,imageReference:IC,inlineCode:RC,link:VC,linkReference:UC,list:YC,listItem:ZC,paragraph:QC,root:ew,strong:nw,text:iw,thematicBreak:ow},cw=document.createElement(`i`);function lw(e){let t=`&`+e+`;`;cw.innerHTML=t;let n=cw.textContent;return n.charCodeAt(n.length-1)===59&&e!==`semi`||n===t?!1:n}function uw(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)}var dw=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function fw(e){return e.replace(dw,pw)}function pw(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){let e=n.charCodeAt(1),t=e===120||e===88;return uw(n.slice(t?2:1),t?16:10)}return lw(n)||e}function mw(){return{enter:{table:hw,tableData:yw,tableHeader:yw,tableRow:_w},exit:{codeText:bw,table:gw,tableData:vw,tableHeader:vw,tableRow:vw}}}function hw(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 gw(e){this.exit(e),this.data.inTable=void 0}function _w(e){this.enter({type:`tableRow`,children:[]},e)}function vw(e){this.exit(e)}function yw(e){this.enter({type:`tableCell`,children:[]},e)}function bw(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,xw));let n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function xw(e,t){return t===`|`?t:e}function Sw(e){let t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,i=t.stringLength,a=n?` `:`|`;return{unsafe:[{character:`\r`,inConstruct:`tableCell`},{character:`
83
- `,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(`
84
- `))}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 iC(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=sw.inlineCode(e,t,n);return n.stack.includes(`tableCell`)&&(r=r.replace(/\|/g,`\\$&`)),r}}function Cw(){return{exit:{taskListCheckValueChecked:Tw,taskListCheckValueUnchecked:Tw,paragraph:Ew}}}function ww(){return{unsafe:[{atBreak:!0,character:`-`,after:`[:|-]`}],handlers:{listItem:Dw}}}function Tw(e){let t=this.stack[this.stack.length-2];t.type,t.checked=e.type===`taskListCheckValueChecked`}function Ew(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 Dw(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=sw.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 Ow(){return[xS(),KS(),ZS(),mw(),Cw()]}function kw(e){return{extensions:[SS(),qS(e),QS(),Sw(e),ww()]}}function Aw(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 jw(e,t){return e.length>0?(Aw(e,e.length,0,t),e):t}var Mw={}.hasOwnProperty;function Nw(e){let t={},n=-1;for(;++n<e.length;)Pw(t,e[n]);return t}function Pw(e,t){let n;for(n in t){let r=(Mw.call(e,n)?e[n]:void 0)||(e[n]={}),i=t[n],a;if(i)for(a in i){Mw.call(r,a)||(r[a]=[]);let e=i[a];Fw(r[a],Array.isArray(e)?e:e?[e]:[])}}}function Fw(e,t){let n=-1,r=[];for(;++n<t.length;)(t[n].add===`after`?e:r).push(t[n]);Aw(e,0,0,r)}var Iw={tokenize:Xw,partial:!0},Lw={tokenize:Zw,partial:!0},Rw={tokenize:Qw,partial:!0},zw={tokenize:$w,partial:!0},Bw={tokenize:eT,partial:!0},Vw={name:`wwwAutolink`,tokenize:Jw,previous:tT},Hw={name:`protocolAutolink`,tokenize:Yw,previous:nT},Uw={name:`emailAutolink`,tokenize:qw,previous:rT},Ww={};function Gw(){return{text:Ww}}for(var Kw=48;Kw<123;)Ww[Kw]=Uw,Kw++,Kw===58?Kw=65:Kw===91&&(Kw=97);Ww[43]=Uw,Ww[45]=Uw,Ww[46]=Uw,Ww[95]=Uw,Ww[72]=[Uw,Hw],Ww[104]=[Uw,Hw],Ww[87]=[Uw,Vw],Ww[119]=[Uw,Vw];function qw(e,t,n){let r=this,i,a;return o;function o(t){return!iT(t)||!rT.call(r,r.previous)||aT(r.events)?n(t):(e.enter(`literalAutolink`),e.enter(`literalAutolinkEmail`),s(t))}function s(t){return iT(t)?(e.consume(t),s):t===64?(e.consume(t),c):n(t)}function c(t){return t===46?e.check(Bw,u,l)(t):t===45||t===95||rS(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&&nS(r.previous)?(e.exit(`literalAutolinkEmail`),e.exit(`literalAutolink`),t(o)):n(o)}}function Jw(e,t,n){let r=this;return i;function i(t){return t!==87&&t!==119||!tT.call(r,r.previous)||aT(r.events)?n(t):(e.enter(`literalAutolink`),e.enter(`literalAutolinkWww`),e.check(Iw,e.attempt(Lw,e.attempt(Rw,a),n),n)(t))}function a(n){return e.exit(`literalAutolinkWww`),e.exit(`literalAutolink`),t(n)}}function Yw(e,t,n){let r=this,i=``,a=!1;return o;function o(t){return(t===72||t===104)&&nT.call(r,r.previous)&&!aT(r.events)?(e.enter(`literalAutolink`),e.enter(`literalAutolinkHttp`),i+=String.fromCodePoint(t),e.consume(t),s):n(t)}function s(t){if(nS(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||aS(t)||lS(t)||fS(t)||dS(t)?n(t):e.attempt(Lw,e.attempt(Rw,u),n)(t)}function u(n){return e.exit(`literalAutolinkHttp`),e.exit(`literalAutolink`),t(n)}}function Xw(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 Zw(e,t,n){let r,i,a;return o;function o(t){return t===46||t===95?e.check(zw,c,s)(t):t===null||lS(t)||fS(t)||t!==45&&dS(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 Qw(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(zw,t,a)(o):o===null||lS(o)||fS(o)?t(o):(e.consume(o),i)}function a(t){return t===41&&r++,e.consume(t),i}}function $w(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||lS(o)||fS(o)?t(o):n(o)}function i(e){return e===null||e===40||e===91||lS(e)||fS(e)?t(e):r(e)}function a(e){return nS(e)?o(e):n(e)}function o(t){return t===59?(e.consume(t),r):nS(t)?(e.consume(t),o):n(t)}}function eT(e,t,n){return r;function r(t){return e.consume(t),i}function i(e){return rS(e)?n(e):t(e)}}function tT(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||lS(e)}function nT(e){return!nS(e)}function rT(e){return!(e===47||iT(e))}function iT(e){return e===43||e===45||e===46||e===95||rS(e)}function aT(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}function oT(e){let t=[],n=-1,r=0,i=0;for(;++n<e.length;){let a=e.charCodeAt(n),o=``;if(a===37&&rS(e.charCodeAt(n+1))&&rS(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 sT(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 cT={name:`attention`,resolveAll:lT,tokenize:uT};function lT(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};dT(d,-c),dT(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=jw(l,[[`enter`,e[r][1],t],[`exit`,e[r][1],t]])),l=jw(l,[[`enter`,i,t],[`enter`,o,t],[`exit`,o,t],[`enter`,a,t]]),l=jw(l,sT(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),l=jw(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=jw(l,[[`enter`,e[n][1],t],[`exit`,e[n][1],t]])):u=0,Aw(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 uT(e,t){let n=this.parser.constructs.attentionMarkers.null,r=this.previous,i=xC(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=xC(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 dT(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}var fT={name:`autolink`,tokenize:pT};function pT(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 nS(t)?(e.consume(t),o):t===64?n(t):l(t)}function o(e){return e===43||e===45||e===46||rS(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||rS(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||aS(r)?n(r):(e.consume(r),c)}function l(t){return t===64?(e.consume(t),u):iS(t)?(e.consume(t),l):n(t)}function u(e){return rS(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||rS(t))&&r++<63){let n=t===45?f:d;return e.consume(t),n}return n(t)}}function mT(e,t,n,r){let i=r?r-1:1/0,a=0;return o;function o(r){return uS(r)?(e.enter(n),s(r)):t(r)}function s(r){return uS(r)&&a++<i?(e.consume(r),s):(e.exit(n),t(r))}}var hT={partial:!0,tokenize:gT};function gT(e,t,n){return r;function r(t){return uS(t)?mT(e,i,`linePrefix`)(t):i(t)}function i(e){return e===null||Q(e)?t(e):n(e)}}var _T={continuation:{tokenize:yT},exit:bT,name:`blockQuote`,tokenize:vT};function vT(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 uS(n)?(e.enter(`blockQuotePrefixWhitespace`),e.consume(n),e.exit(`blockQuotePrefixWhitespace`),e.exit(`blockQuotePrefix`),t):(e.exit(`blockQuotePrefix`),t(n))}}function yT(e,t,n){let r=this;return i;function i(t){return uS(t)?mT(e,a,`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(t):a(t)}function a(r){return e.attempt(_T,t,n)(r)}}function bT(e){e.exit(`blockQuote`)}var xT={name:`characterEscape`,tokenize:ST};function ST(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 cS(r)?(e.enter(`characterEscapeValue`),e.consume(r),e.exit(`characterEscapeValue`),e.exit(`characterEscape`),t):n(r)}}var CT={name:`characterReference`,tokenize:wT};function wT(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=rS,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=sS,u):(e.enter(`characterReferenceValue`),a=7,o=oS,u(t))}function u(s){if(s===59&&i){let i=e.exit(`characterReferenceValue`);return o===rS&&!lw(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 TT={partial:!0,tokenize:OT},ET={concrete:!0,name:`codeFenced`,tokenize:DT};function DT(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`),uS(t)?mT(e,d,`whitespace`)(t):d(t))}function d(n){return n===null||Q(n)?(e.exit(`codeFencedFence`),r.interrupt?t(n):e.check(TT,h,b)(n)):(e.enter(`codeFencedFenceInfo`),e.enter(`chunkString`,{contentType:`string`}),f(n))}function f(t){return t===null||Q(t)?(e.exit(`chunkString`),e.exit(`codeFencedFenceInfo`),d(t)):uS(t)?(e.exit(`chunkString`),e.exit(`codeFencedFenceInfo`),mT(e,p,`whitespace`)(t)):t===96&&t===s?n(t):(e.consume(t),f)}function p(t){return t===null||Q(t)?d(t):(e.enter(`codeFencedFenceMeta`),e.enter(`chunkString`,{contentType:`string`}),m(t))}function m(t){return t===null||Q(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&&uS(t)?mT(e,v,`linePrefix`,a+1)(t):v(t)}function v(t){return t===null||Q(t)?e.check(TT,h,b)(t):(e.enter(`codeFlowValue`),y(t))}function y(t){return t===null||Q(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`),uS(t)?mT(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`),uS(t)?mT(e,d,`whitespace`)(t):d(t)):n(t)}function d(r){return r===null||Q(r)?(e.exit(`codeFencedFence`),t(r)):n(r)}}}function OT(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 kT={name:`codeIndented`,tokenize:jT},AT={partial:!0,tokenize:MT};function jT(e,t,n){let r=this;return i;function i(t){return e.enter(`codeIndented`),mT(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):Q(t)?e.attempt(AT,o,c)(t):(e.enter(`codeFlowValue`),s(t))}function s(t){return t===null||Q(t)?(e.exit(`codeFlowValue`),o(t)):(e.consume(t),s)}function c(n){return e.exit(`codeIndented`),t(n)}}function MT(e,t,n){let r=this;return i;function i(t){return r.parser.lazy[r.now().line]?n(t):Q(t)?(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),i):mT(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):Q(e)?i(e):n(e)}}var NT={name:`codeText`,previous:FT,resolve:PT,tokenize:IT};function PT(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 FT(e){return e!==96||this.events[this.events.length-1][1].type===`characterEscape`}function IT(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)):Q(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||Q(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 LT=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&&RT(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),RT(this.left,e)}unshift(e){this.setCursor(0),this.right.push(e)}unshiftMany(e){this.setCursor(0),RT(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);RT(this.right,t.reverse())}else{let t=this.right.splice(this.left.length+this.right.length-e,1/0);RT(this.left,t.reverse())}}};function RT(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 zT(e){let t={},n=-1,r,i,a,o,s,c,l,u=new LT(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,BT(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 Aw(e,0,1/0,u.slice(0)),!l}function BT(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 VT={resolve:UT,tokenize:WT},HT={partial:!0,tokenize:GT};function UT(e){return zT(e),e}function WT(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):Q(t)?e.check(HT,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 GT(e,t,n){let r=this;return i;function i(t){return e.exit(`chunkContent`),e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),mT(e,a,`linePrefix`)}function a(i){if(i===null||Q(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 KT(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||aS(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||Q(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||lS(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||aS(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 qT(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):Q(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||Q(t)||s++>999?(e.exit(`chunkString`),u(t)):(e.consume(t),c||=!uS(t),t===92?f:d)}function f(t){return t===91||t===92||t===93?(e.consume(t),s++,d):d(t)}}function JT(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):Q(t)?(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),mT(e,l,`linePrefix`)):(e.enter(`chunkString`,{contentType:`string`}),u(t))}function u(t){return t===o||t===null||Q(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 YT(e,t){let n;return r;function r(i){return Q(i)?(e.enter(`lineEnding`),e.consume(i),e.exit(`lineEnding`),n=!0,r):uS(i)?mT(e,r,n?`linePrefix`:`lineSuffix`)(i):t(i)}}var XT={name:`definition`,tokenize:QT},ZT={partial:!0,tokenize:$T};function QT(e,t,n){let r=this,i;return a;function a(t){return e.enter(`definition`),o(t)}function o(t){return qT.call(r,e,s,n,`definitionLabel`,`definitionLabelMarker`,`definitionLabelString`)(t)}function s(t){return i=FS(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 lS(t)?YT(e,l)(t):l(t)}function l(t){return KT(e,u,n,`definitionDestination`,`definitionDestinationLiteral`,`definitionDestinationLiteralMarker`,`definitionDestinationRaw`,`definitionDestinationString`)(t)}function u(t){return e.attempt(ZT,d,d)(t)}function d(t){return uS(t)?mT(e,f,`whitespace`)(t):f(t)}function f(a){return a===null||Q(a)?(e.exit(`definition`),r.parser.defined.push(i),t(a)):n(a)}}function $T(e,t,n){return r;function r(t){return lS(t)?YT(e,i)(t):n(t)}function i(t){return JT(e,a,n,`definitionTitle`,`definitionTitleMarker`,`definitionTitleString`)(t)}function a(t){return uS(t)?mT(e,o,`whitespace`)(t):o(t)}function o(e){return e===null||Q(e)?t(e):n(e)}}var eE={name:`hardBreakEscape`,tokenize:tE};function tE(e,t,n){return r;function r(t){return e.enter(`hardBreakEscape`),e.consume(t),i}function i(r){return Q(r)?(e.exit(`hardBreakEscape`),t(r)):n(r)}}var nE={name:`headingAtx`,resolve:rE,tokenize:iE};function rE(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`},Aw(e,r,n-r+1,[[`enter`,i,t],[`enter`,a,t],[`exit`,a,t],[`exit`,i,t]])),e}function iE(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||lS(t)?(e.exit(`atxHeadingSequence`),s(t)):n(t)}function s(n){return n===35?(e.enter(`atxHeadingSequence`),c(n)):n===null||Q(n)?(e.exit(`atxHeading`),t(n)):uS(n)?mT(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||lS(t)?(e.exit(`atxHeadingText`),s(t)):(e.consume(t),l)}}var aE=`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(`.`),oE=[`pre`,`script`,`style`,`textarea`],sE={concrete:!0,name:`htmlFlow`,resolveTo:uE,tokenize:dE},cE={partial:!0,tokenize:pE},lE={partial:!0,tokenize:fE};function uE(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 dE(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:N):nS(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):nS(a)?(e.consume(a),i=4,r.interrupt?t:N):n(a)}function p(i){return i===45?(e.consume(i),r.interrupt?t:N):n(i)}function m(i){return i===`CDATA[`.charCodeAt(s++)?(e.consume(i),s===6?r.interrupt?t:O:m):n(i)}function h(t){return nS(t)?(e.consume(t),o=String.fromCharCode(t),g):n(t)}function g(s){if(s===null||s===47||s===62||lS(s)){let c=s===47,l=o.toLowerCase();return!c&&!a&&oE.includes(l)?(i=1,r.interrupt?t(s):O(s)):aE.includes(o.toLowerCase())?(i=6,c?(e.consume(s),_):r.interrupt?t(s):O(s)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(s):a?v(s):y(s))}return s===45||rS(s)?(e.consume(s),o+=String.fromCharCode(s),g):n(s)}function _(i){return i===62?(e.consume(i),r.interrupt?t:O):n(i)}function v(t){return uS(t)?(e.consume(t),v):E(t)}function y(t){return t===47?(e.consume(t),E):t===58||t===95||nS(t)?(e.consume(t),b):uS(t)?(e.consume(t),y):E(t)}function b(t){return t===45||t===46||t===58||t===95||rS(t)?(e.consume(t),b):x(t)}function x(t){return t===61?(e.consume(t),S):uS(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):uS(t)?(e.consume(t),S):w(t)}function C(t){return t===c?(e.consume(t),c=null,T):t===null||Q(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||lS(t)?x(t):(e.consume(t),w)}function T(e){return e===47||e===62||uS(e)?y(e):n(e)}function E(t){return t===62?(e.consume(t),D):n(t)}function D(t){return t===null||Q(t)?O(t):uS(t)?(e.consume(t),D):n(t)}function O(t){return t===45&&i===2?(e.consume(t),A):t===60&&i===1?(e.consume(t),j):t===62&&i===4?(e.consume(t),P):t===63&&i===3?(e.consume(t),N):t===93&&i===5?(e.consume(t),ne):Q(t)&&(i===6||i===7)?(e.exit(`htmlFlowData`),e.check(cE,re,ee)(t)):t===null||Q(t)?(e.exit(`htmlFlowData`),ee(t)):(e.consume(t),O)}function ee(t){return e.check(lE,te,re)(t)}function te(t){return e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),k}function k(t){return t===null||Q(t)?ee(t):(e.enter(`htmlFlowData`),O(t))}function A(t){return t===45?(e.consume(t),N):O(t)}function j(t){return t===47?(e.consume(t),o=``,M):O(t)}function M(t){if(t===62){let n=o.toLowerCase();return oE.includes(n)?(e.consume(t),P):O(t)}return nS(t)&&o.length<8?(e.consume(t),o+=String.fromCharCode(t),M):O(t)}function ne(t){return t===93?(e.consume(t),N):O(t)}function N(t){return t===62?(e.consume(t),P):t===45&&i===2?(e.consume(t),N):O(t)}function P(t){return t===null||Q(t)?(e.exit(`htmlFlowData`),re(t)):(e.consume(t),P)}function re(n){return e.exit(`htmlFlow`),t(n)}}function fE(e,t,n){let r=this;return i;function i(t){return Q(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 pE(e,t,n){return r;function r(r){return e.enter(`lineEnding`),e.consume(r),e.exit(`lineEnding`),e.attempt(hT,t,n)}}var mE={name:`htmlText`,tokenize:hE};function hE(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):nS(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):nS(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):Q(t)?(o=d,j(t)):(e.consume(t),d)}function f(t){return t===45?(e.consume(t),p):d(t)}function p(e){return e===62?A(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):Q(t)?(o=h,j(t)):(e.consume(t),h)}function g(t){return t===93?(e.consume(t),_):h(t)}function _(t){return t===62?A(t):t===93?(e.consume(t),_):h(t)}function v(t){return t===null||t===62?A(t):Q(t)?(o=v,j(t)):(e.consume(t),v)}function y(t){return t===null?n(t):t===63?(e.consume(t),b):Q(t)?(o=y,j(t)):(e.consume(t),y)}function b(e){return e===62?A(e):y(e)}function x(t){return nS(t)?(e.consume(t),S):n(t)}function S(t){return t===45||rS(t)?(e.consume(t),S):C(t)}function C(t){return Q(t)?(o=C,j(t)):uS(t)?(e.consume(t),C):A(t)}function w(t){return t===45||rS(t)?(e.consume(t),w):t===47||t===62||lS(t)?T(t):n(t)}function T(t){return t===47?(e.consume(t),A):t===58||t===95||nS(t)?(e.consume(t),E):Q(t)?(o=T,j(t)):uS(t)?(e.consume(t),T):A(t)}function E(t){return t===45||t===46||t===58||t===95||rS(t)?(e.consume(t),E):D(t)}function D(t){return t===61?(e.consume(t),O):Q(t)?(o=D,j(t)):uS(t)?(e.consume(t),D):T(t)}function O(t){return t===null||t===60||t===61||t===62||t===96?n(t):t===34||t===39?(e.consume(t),i=t,ee):Q(t)?(o=O,j(t)):uS(t)?(e.consume(t),O):(e.consume(t),te)}function ee(t){return t===i?(e.consume(t),i=void 0,k):t===null?n(t):Q(t)?(o=ee,j(t)):(e.consume(t),ee)}function te(t){return t===null||t===34||t===39||t===60||t===61||t===96?n(t):t===47||t===62||lS(t)?T(t):(e.consume(t),te)}function k(e){return e===47||e===62||lS(e)?T(e):n(e)}function A(r){return r===62?(e.consume(r),e.exit(`htmlTextData`),e.exit(`htmlText`),t):n(r)}function j(t){return e.exit(`htmlTextData`),e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),M}function M(t){return uS(t)?mT(e,ne,`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(t):ne(t)}function ne(t){return e.enter(`htmlTextData`),o(t)}}var gE={name:`labelEnd`,resolveAll:bE,resolveTo:xE,tokenize:SE},_E={tokenize:CE},vE={tokenize:wE},yE={tokenize:TE};function bE(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&&Aw(e,0,e.length,n),e}function xE(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=jw(s,e.slice(a+1,a+r+3)),s=jw(s,[[`enter`,u,t]]),s=jw(s,sT(t.parser.constructs.insideSpan.null,e.slice(a+r+4,o-3),t)),s=jw(s,[[`exit`,u,t],e[o-2],e[o-1],[`exit`,l,t]]),s=jw(s,e.slice(o+1)),s=jw(s,[[`exit`,c,t]]),Aw(e,a,e.length,s),e}function SE(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(FS(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(_E,u,o?u:d)(t):t===91?e.attempt(vE,u,o?l:d)(t):o?u(t):d(t)}function l(t){return e.attempt(yE,u,d)(t)}function u(e){return t(e)}function d(e){return a._balanced=!0,n(e)}}function CE(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 lS(t)?YT(e,a)(t):a(t)}function a(t){return t===41?u(t):KT(e,o,s,`resourceDestination`,`resourceDestinationLiteral`,`resourceDestinationLiteralMarker`,`resourceDestinationRaw`,`resourceDestinationString`,32)(t)}function o(t){return lS(t)?YT(e,c)(t):u(t)}function s(e){return n(e)}function c(t){return t===34||t===39||t===40?JT(e,l,n,`resourceTitle`,`resourceTitleMarker`,`resourceTitleString`)(t):u(t)}function l(t){return lS(t)?YT(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 wE(e,t,n){let r=this;return i;function i(t){return qT.call(r,e,a,o,`reference`,`referenceMarker`,`referenceString`)(t)}function a(e){return r.parser.defined.includes(FS(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(e):n(e)}function o(e){return n(e)}}function TE(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 EE={name:`labelStartImage`,resolveAll:gE.resolveAll,tokenize:DE};function DE(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 OE={name:`labelStartLink`,resolveAll:gE.resolveAll,tokenize:kE};function kE(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 AE={name:`lineEnding`,tokenize:jE};function jE(e,t){return n;function n(n){return e.enter(`lineEnding`),e.consume(n),e.exit(`lineEnding`),mT(e,t,`linePrefix`)}}var ME={name:`thematicBreak`,tokenize:NE};function NE(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||Q(a))?(e.exit(`thematicBreak`),t(a)):n(a)}function c(t){return t===i?(e.consume(t),r++,c):(e.exit(`thematicBreakSequence`),uS(t)?mT(e,s,`whitespace`)(t):s(t))}}var PE={continuation:{tokenize:RE},exit:BE,name:`list`,tokenize:LE},FE={partial:!0,tokenize:VE},IE={partial:!0,tokenize:zE};function LE(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:oS(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(ME,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 oS(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(hT,r.interrupt?n:u,e.attempt(FE,f,d))}function u(e){return r.containerState.initialBlankLine=!0,a++,f(e)}function d(t){return uS(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 RE(e,t,n){let r=this;return r.containerState._closeFlow=void 0,e.check(hT,i,a);function i(n){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,mT(e,t,`listItemIndent`,r.containerState.size+1)(n)}function a(n){return r.containerState.furtherBlankLines||!uS(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(IE,t,o)(n))}function o(i){return r.containerState._closeFlow=!0,r.interrupt=void 0,mT(e,e.attempt(PE,t,n),`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(i)}}function zE(e,t,n){let r=this;return mT(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 BE(e){e.exit(this.containerState.type)}function VE(e,t,n){let r=this;return mT(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!uS(e)&&i&&i[1].type===`listItemPrefixWhitespace`?t(e):n(e)}}var HE={name:`setextUnderline`,resolveTo:UE,tokenize:WE};function UE(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 WE(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`),uS(t)?mT(e,c,`lineSuffix`)(t):c(t))}function c(r){return r===null||Q(r)?(e.exit(`setextHeadingLine`),t(r)):n(r)}}var GE={tokenize:$E,partial:!0};function KE(){return{document:{91:{name:`gfmFootnoteDefinition`,tokenize:XE,continuation:{tokenize:ZE},exit:QE}},text:{91:{name:`gfmFootnoteCall`,tokenize:YE},93:{name:`gfmPotentialFootnoteCall`,add:`after`,tokenize:qE,resolveTo:JE}}}}function qE(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=FS(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 JE(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 YE(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||lS(s))return n(s);if(s===93){e.exit(`chunkString`);let a=e.exit(`gfmFootnoteCallString`);return i.includes(FS(r.sliceSerialize(a)))?(e.enter(`gfmFootnoteCallLabelMarker`),e.consume(s),e.exit(`gfmFootnoteCallLabelMarker`),e.exit(`gfmFootnoteCall`),t):n(s)}return lS(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 XE(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||lS(t))return n(t);if(t===93){e.exit(`chunkString`);let n=e.exit(`gfmFootnoteDefinitionLabelString`);return a=FS(r.sliceSerialize(n)),e.enter(`gfmFootnoteDefinitionLabelMarker`),e.consume(t),e.exit(`gfmFootnoteDefinitionLabelMarker`),e.exit(`gfmFootnoteDefinitionLabel`),f}return lS(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),mT(e,p,`gfmFootnoteDefinitionWhitespace`)):n(t)}function p(e){return t(e)}}function ZE(e,t,n){return e.check(hT,t,e.attempt(GE,t,n))}function QE(e){e.exit(`gfmFootnoteDefinition`)}function $E(e,t,n){let r=this;return mT(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 eD(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&&Aw(o,o.length,0,sT(s,e.slice(r+1,n),t)),Aw(o,o.length,0,[[`exit`,a,t],[`enter`,e[n][1],t],[`exit`,e[n][1],t],[`exit`,i,t]]),Aw(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=xC(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=xC(a);return l._open=!u||u===2&&!!s,l._close=!s||s===2&&!!u,n(a)}}}var tD=class{constructor(){this.map=[]}add(e,t,n){nD(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 nD(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 rD(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 iD(){return{flow:{null:{name:`table`,tokenize:aD,resolveAll:oD}}}}function aD(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):Q(t)?a>1?(a=0,r.interrupt=!0,e.exit(`tableRow`),e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),p):n(t):uS(t)?mT(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||lS(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,uS(t)?mT(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 uS(t)?mT(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||Q(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 uS(t)?mT(e,b,`whitespace`)(t):b(t)}function b(n){return n===124?m(n):n===null||Q(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||Q(n)?(e.exit(`tableRow`),t(n)):uS(n)?mT(e,C,`whitespace`)(n):(e.enter(`data`),w(n))}function w(t){return t===null||t===124||lS(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 oD(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 tD;for(;++n<e.length;){let p=e[n],m=p[1];p[0]===`enter`?m.type===`tableHead`?(s=!1,c!==0&&(cD(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=sD(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=sD(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=sD(f,t,o,i,n,d)):(o[0]=o[1],d=sD(f,t,a,i,n,d)),i=0):i&&(m.type===`data`||m.type===`tableDelimiterMarker`||m.type===`tableDelimiterFiller`)&&(o[3]=n)}for(c!==0&&cD(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=rD(t.events,n))}return e}function sD(e,t,n,r,i,a){let o=r===1?`tableHeader`:r===2?`tableDelimiter`:`tableData`;n[0]!==0&&(a.end=Object.assign({},lD(t.events,n[0])),e.add(n[0],0,[[`exit`,a,t]]));let s=lD(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=lD(t.events,n[2]),a=lD(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({},lD(t.events,i)),e.add(i,0,[[`exit`,a,t]]),a=void 0),a}function cD(e,t,n,r,i){let a=[],o=lD(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 lD(e,t){let n=e[t],r=n[0]===`enter`?`start`:`end`;return n[1][r]}var uD={name:`tasklistCheck`,tokenize:fD};function dD(){return{text:{91:uD}}}function fD(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 lS(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 Q(r)?t(r):uS(r)?e.check({tokenize:pD},t,n)(r):n(r)}}function pD(e,t,n){return mT(e,r,`whitespace`);function r(e){return e===null?n(e):t(e)}}function mD(e){return Nw([Gw(),KE(),eD(e),iD(),dD()])}var hD={};function gD(e){let t=this,n=e||hD,r=t.data(),i=r.micromarkExtensions||=[],a=r.fromMarkdownExtensions||=[],o=r.toMarkdownExtensions||=[];i.push(mD(n)),a.push(Ow()),o.push(kw(n))}var _D=Object.defineProperty,vD=Object.defineProperties,yD=Object.getOwnPropertyDescriptors,bD=Object.getOwnPropertySymbols,xD=Object.prototype.hasOwnProperty,SD=Object.prototype.propertyIsEnumerable,CD=(e,t,n)=>t in e?_D(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,wD=(e,t)=>{for(var n in t||={})xD.call(t,n)&&CD(e,n,t[n]);if(bD)for(var n of bD(t))SD.call(t,n)&&CD(e,n,t[n]);return e},TD=(e,t)=>vD(e,yD(t)),ED=(e,t)=>{let n=!1,r=!1;for(let i=0;i<t;i+=1){if(e[i]===`\\`&&i+1<e.length&&e[i+1]==="`"){i+=1;continue}if(e.substring(i,i+3)==="```"){r=!r,i+=2;continue}!r&&e[i]==="`"&&(n=!n)}return n||r},DD=(e,t)=>{let n=e.substring(t,t+3)==="```",r=t>0&&e.substring(t-1,t+2)==="```",i=t>1&&e.substring(t-2,t+1)==="```";return n||r||i},OD=e=>{let t=0;for(let n=0;n<e.length;n+=1){if(e[n]===`\\`&&n+1<e.length&&e[n+1]==="`"){n+=1;continue}e[n]==="`"&&!DD(e,n)&&(t+=1)}return t},kD=(e,t)=>{let n=!1,r=!1,i=-1;for(let a=0;a<e.length;a+=1){if(e[a]===`\\`&&a+1<e.length&&e[a+1]==="`"){a+=1;continue}if(e.substring(a,a+3)==="```"){r=!r,a+=2;continue}if(!r&&e[a]==="`")if(n){if(i<t&&t<a)return!0;n=!1,i=-1}else n=!0,i=a}return!1},AD=/^(\s*(?:[-*+]|\d+[.)]) +)>(=?\s*[$]?\d)/gm,jD=e=>!e||typeof e!=`string`||!e.includes(`>`)?e:e.replace(AD,(t,n,r,i)=>ED(e,i)?t:`${n}\\>${r}`),MD=/(\*\*)([^*]*\*?)$/,ND=/(__)([^_]*?)$/,PD=/(\*\*\*)([^*]*?)$/,FD=/(\*)([^*]*?)$/,ID=/(_)([^_]*?)$/,LD=/(`)([^`]*?)$/,RD=/(~~)([^~]*?)$/,zD=/^[\s_~*`]*$/,BD=/^[\s]*[-*+][\s]+$/,VD=/[\p{L}\p{N}_]/u,HD=/^```[^`\n]*```?$/,UD=/^\*{4,}$/,WD=/(__)([^_]+)_$/,GD=/(~~)([^~]+)~$/,KD=/~~/g,qD=e=>{if(!e)return!1;let t=e.charCodeAt(0);return t>=48&&t<=57||t>=65&&t<=90||t>=97&&t<=122||t===95?!0:VD.test(e)},JD=(e,t)=>{let n=1;for(let r=t-1;r>=0;--r)if(e[r]===`]`)n+=1;else if(e[r]===`[`&&(--n,n===0))return r;return-1},YD=(e,t)=>{let n=1;for(let r=t+1;r<e.length;r+=1)if(e[r]===`[`)n+=1;else if(e[r]===`]`&&(--n,n===0))return r;return-1},XD=(e,t)=>{let n=!1,r=!1;for(let i=0;i<e.length&&i<t;i+=1){if(e[i]===`\\`&&e[i+1]===`$`){i+=1;continue}e[i]===`$`&&(e[i+1]===`$`?(r=!r,i+=1,n=!1):r||(n=!n))}return n||r},ZD=(e,t)=>{for(let n=t;n<e.length;n+=1){if(e[n]===`)`)return!0;if(e[n]===`
85
- `)return!1}return!1},QD=(e,t)=>{for(let n=t-1;n>=0;--n){if(e[n]===`)`)return!1;if(e[n]===`(`)return n>0&&e[n-1]===`]`?ZD(e,t):!1;if(e[n]===`
86
- `)return!1}return!1},$D=(e,t)=>{for(let n=t-1;n>=0;--n){if(e[n]===`>`)return!1;if(e[n]===`<`){let t=n+1<e.length?e[n+1]:``;return t>=`a`&&t<=`z`||t>=`A`&&t<=`Z`||t===`/`}if(e[n]===`
87
- `)return!1}return!1},eO=(e,t,n)=>{let r=0;for(let n=t-1;n>=0;--n)if(e[n]===`
88
- `){r=n+1;break}let i=e.length;for(let n=t;n<e.length;n+=1)if(e[n]===`
89
- `){i=n;break}let a=e.substring(r,i),o=0,s=!1;for(let e of a)if(e===n)o+=1;else if(e!==` `&&e!==` `){s=!0;break}return o>=3&&!s},tO=(e,t,n,r)=>n===`\\`||e.includes(`$`)&&XD(e,t)?!0:n!==`*`&&r===`*`?(t<e.length-2?e[t+2]:``)!==`*`:!!(n===`*`||n&&r&&qD(n)&&qD(r)||(!n||n===` `||n===` `||n===`
90
- `)&&(!r||r===` `||r===` `||r===`
91
- `)),nO=e=>{let t=0,n=!1,r=e.length;for(let i=0;i<r;i+=1){if(e[i]==="`"&&i+2<r&&e[i+1]==="`"&&e[i+2]==="`"){n=!n,i+=2;continue}if(n||e[i]!==`*`)continue;let a=i>0?e[i-1]:``,o=i<r-1?e[i+1]:``;tO(e,i,a,o)||(t+=1)}return t},rO=(e,t,n,r)=>!!(n===`\\`||e.includes(`$`)&&XD(e,t)||QD(e,t)||$D(e,t)||n===`_`||r===`_`||n&&r&&qD(n)&&qD(r)),iO=e=>{let t=0,n=!1,r=e.length;for(let i=0;i<r;i+=1){if(e[i]==="`"&&i+2<r&&e[i+1]==="`"&&e[i+2]==="`"){n=!n,i+=2;continue}if(n||e[i]!==`_`)continue;let a=i>0?e[i-1]:``,o=i<r-1?e[i+1]:``;rO(e,i,a,o)||(t+=1)}return t},aO=e=>{let t=0,n=0,r=!1;for(let i=0;i<e.length;i+=1){if(e[i]==="`"&&i+2<e.length&&e[i+1]==="`"&&e[i+2]==="`"){n>=3&&(t+=Math.floor(n/3)),n=0,r=!r,i+=2;continue}r||(e[i]===`*`?n+=1:(n>=3&&(t+=Math.floor(n/3)),n=0))}return n>=3&&(t+=Math.floor(n/3)),t},oO=e=>{let t=0,n=!1;for(let r=0;r<e.length;r+=1){if(e[r]==="`"&&r+2<e.length&&e[r+1]==="`"&&e[r+2]==="`"){n=!n,r+=2;continue}n||e[r]===`*`&&r+1<e.length&&e[r+1]===`*`&&(t+=1,r+=1)}return t},sO=e=>{let t=0,n=!1;for(let r=0;r<e.length;r+=1){if(e[r]==="`"&&r+2<e.length&&e[r+1]==="`"&&e[r+2]==="`"){n=!n,r+=2;continue}n||e[r]===`_`&&r+1<e.length&&e[r+1]===`_`&&(t+=1,r+=1)}return t},cO=(e,t,n)=>{if(!t||zD.test(t))return!0;let r=e.substring(0,n).lastIndexOf(`
92
- `),i=r===-1?0:r+1,a=e.substring(i,n);return BD.test(a)&&t.includes(`
93
- `)?!0:eO(e,n,`*`)},lO=e=>{let t=e.match(MD);if(!t)return e;let n=t[2],r=e.lastIndexOf(t[1]);return ED(e,r)||kD(e,r)||cO(e,n,r)?e:oO(e)%2==1?n.endsWith(`*`)?`${e}*`:`${e}**`:e},uO=(e,t,n)=>{if(!t||zD.test(t))return!0;let r=e.substring(0,n).lastIndexOf(`
94
- `),i=r===-1?0:r+1,a=e.substring(i,n);return BD.test(a)&&t.includes(`
95
- `)?!0:eO(e,n,`_`)},dO=e=>{let t=e.match(ND);if(!t){let t=e.match(WD);if(t){let n=e.lastIndexOf(t[1]);if(!(ED(e,n)||kD(e,n))&&sO(e)%2==1)return`${e}_`}return e}let n=t[2],r=e.lastIndexOf(t[1]);return ED(e,r)||kD(e,r)||uO(e,n,r)?e:sO(e)%2==1?`${e}__`:e},fO=e=>{let t=!1;for(let n=0;n<e.length;n+=1){if(e[n]==="`"&&n+2<e.length&&e[n+1]==="`"&&e[n+2]==="`"){t=!t,n+=2;continue}if(!t&&e[n]===`*`&&e[n-1]!==`*`&&e[n+1]!==`*`&&e[n-1]!==`\\`&&!XD(e,n)){let t=n>0?e[n-1]:``,r=n<e.length-1?e[n+1]:``;if((!t||t===` `||t===` `||t===`
96
- `)&&(!r||r===` `||r===` `||r===`
97
- `)||t&&r&&qD(t)&&qD(r))continue;return n}}return-1},pO=e=>{if(!e.match(FD))return e;let t=fO(e);if(t===-1||ED(e,t)||kD(e,t))return e;let n=e.substring(t+1);return!n||zD.test(n)?e:nO(e)%2==1?`${e}*`:e},mO=e=>{let t=!1;for(let n=0;n<e.length;n+=1){if(e[n]==="`"&&n+2<e.length&&e[n+1]==="`"&&e[n+2]==="`"){t=!t,n+=2;continue}if(!t&&e[n]===`_`&&e[n-1]!==`_`&&e[n+1]!==`_`&&e[n-1]!==`\\`&&!XD(e,n)&&!QD(e,n)){let t=n>0?e[n-1]:``,r=n<e.length-1?e[n+1]:``;if(t&&r&&qD(t)&&qD(r))continue;return n}}return-1},hO=e=>{let t=e.length;for(;t>0&&e[t-1]===`
98
- `;)--t;return t<e.length?`${e.slice(0,t)}_${e.slice(t)}`:`${e}_`},gO=e=>{if(!e.endsWith(`**`))return null;let t=e.slice(0,-2);if(oO(t)%2!=1)return null;let n=t.indexOf(`**`),r=mO(t);return n!==-1&&r!==-1&&n<r?`${t}_**`:null},_O=e=>{if(!e.match(ID))return e;let t=mO(e);if(t===-1)return e;let n=e.substring(t+1);if(!n||zD.test(n)||ED(e,t)||kD(e,t))return e;if(iO(e)%2==1){let t=gO(e);return t===null?hO(e):t}return e},vO=e=>{let t=oO(e),n=nO(e);return t%2==0&&n%2==0},yO=(e,t,n)=>!t||zD.test(t)||ED(e,n)||kD(e,n)?!0:eO(e,n,`*`),bO=e=>{if(UD.test(e))return e;let t=e.match(PD);if(!t)return e;let n=t[2];return yO(e,n,e.lastIndexOf(t[1]))?e:aO(e)%2==1?vO(e)?e:`${e}***`:e},xO=/<[a-zA-Z/][^>]*$/,SO=e=>{let t=e.match(xO);return!t||t.index===void 0||ED(e,t.index)?e:e.substring(0,t.index).trimEnd()},CO=e=>!e.match(HD)||e.includes(`
99
- `)?null:e.endsWith("``")&&!e.endsWith("```")?`${e}\``:e,wO=e=>(e.match(/```/g)||[]).length%2==1,TO=e=>{let t=CO(e);if(t!==null)return t;let n=e.match(LD);if(n&&!wO(e)){let t=n[2];if(!t||zD.test(t))return e;if(OD(e)%2==1)return`${e}\``}return e},EO=(e,t)=>t>=2&&e.substring(t-2,t+1)==="```"||t>=1&&e.substring(t-1,t+2)==="```"||t<=e.length-3&&e.substring(t,t+3)==="```",DO=e=>{let t=0,n=!1;for(let r=0;r<e.length-1;r+=1)e[r]==="`"&&!EO(e,r)&&(n=!n),!n&&e[r]===`$`&&e[r+1]===`$`&&(t+=1,r+=1);return t},OO=e=>{let t=0,n=!1;for(let r=0;r<e.length;r+=1){if(e[r]===`\\`){r+=1;continue}if(e[r]==="`"&&!EO(e,r)){n=!n;continue}!n&&e[r]===`$`&&(r+1<e.length&&e[r+1]===`$`?r+=1:t+=1)}return t},kO=e=>{if(e.endsWith(`$`)&&!e.endsWith(`$$`))return`${e}$`;let t=e.indexOf(`$$`);return t!==-1&&e.indexOf(`
100
- `,t)!==-1&&!e.endsWith(`
101
- `)?`${e}
102
- $$`:`${e}$$`},AO=e=>DO(e)%2==0?e:kO(e),jO=e=>OO(e)%2==1?`${e}$`:e,MO=(e,t,n)=>{if(e.substring(t+2).includes(`)`))return null;let r=JD(e,t);if(r===-1||ED(e,r))return null;let i=r>0&&e[r-1]===`!`,a=i?r-1:r,o=e.substring(0,a);if(i)return o;let s=e.substring(r+1,t);return n===`text-only`?`${o}${s}`:`${o}[${s}](streamdown:incomplete-link)`},NO=(e,t)=>{for(let n=0;n<t;n++)if(e[n]===`[`&&!ED(e,n)){if(n>0&&e[n-1]===`!`)continue;let t=YD(e,n);if(t===-1)return n;if(t+1<e.length&&e[t+1]===`(`){let r=e.indexOf(`)`,t+2);r!==-1&&(n=r)}}return t},PO=(e,t,n)=>{let r=t>0&&e[t-1]===`!`,i=r?t-1:t;if(!e.substring(t+1).includes(`]`)){let a=e.substring(0,i);if(r)return a;if(n===`text-only`){let n=NO(e,t);return e.substring(0,n)+e.substring(n+1)}return`${e}](streamdown:incomplete-link)`}if(YD(e,t)===-1){let a=e.substring(0,i);if(r)return a;if(n===`text-only`){let n=NO(e,t);return e.substring(0,n)+e.substring(n+1)}return`${e}](streamdown:incomplete-link)`}return null},FO=(e,t=`protocol`)=>{let n=e.lastIndexOf(`](`);if(n!==-1&&!ED(e,n)){let r=MO(e,n,t);if(r!==null)return r}for(let n=e.length-1;n>=0;--n)if(e[n]===`[`&&!ED(e,n)){let r=PO(e,n,t);if(r!==null)return r}return e},IO=/^-{1,2}$/,LO=/^[\s]*-{1,2}[\s]+$/,RO=/^={1,2}$/,zO=/^[\s]*={1,2}[\s]+$/,BO=e=>{if(!e||typeof e!=`string`)return e;let t=e.lastIndexOf(`
103
- `);if(t===-1)return e;let n=e.substring(t+1),r=e.substring(0,t),i=n.trim();if(IO.test(i)&&!n.match(LO)){let t=r.split(`
104
- `).at(-1);if(t&&t.trim().length>0)return`${e}\u200B`}if(RO.test(i)&&!n.match(zO)){let t=r.split(`
105
- `).at(-1);if(t&&t.trim().length>0)return`${e}\u200B`}return e},VO=RegExp(`(?<=[\\p{L}\\p{N}_])~(?!~)(?=[\\p{L}\\p{N}_])`,`gu`),HO=e=>!e||typeof e!=`string`||!e.includes(`~`)?e:e.replace(VO,(t,n)=>ED(e,n)?t:`\\~`),UO=e=>{let t=e.match(RD);if(t){let n=t[2];if(!n||zD.test(n))return e;let r=e.lastIndexOf(t[1]);if(ED(e,r)||kD(e,r))return e;if(e.match(KD)?.length%2==1)return`${e}~~`}else{let t=e.match(GD);if(t){let n=e.lastIndexOf(t[0].slice(0,2));if(ED(e,n)||kD(e,n))return e;if(e.match(KD)?.length%2==1)return`${e}~`}}return e},WO=e=>e!==!1,GO=e=>e===!0,KO={SINGLE_TILDE:0,COMPARISON_OPERATORS:5,HTML_TAGS:10,SETEXT_HEADINGS:15,LINKS:20,BOLD_ITALIC:30,BOLD:35,ITALIC_DOUBLE_UNDERSCORE:40,ITALIC_SINGLE_ASTERISK:41,ITALIC_SINGLE_UNDERSCORE:42,INLINE_CODE:50,STRIKETHROUGH:60,KATEX:70,INLINE_KATEX:75,DEFAULT:100},qO=[{handler:{name:`singleTilde`,handle:HO,priority:KO.SINGLE_TILDE},optionKey:`singleTilde`},{handler:{name:`comparisonOperators`,handle:jD,priority:KO.COMPARISON_OPERATORS},optionKey:`comparisonOperators`},{handler:{name:`htmlTags`,handle:SO,priority:KO.HTML_TAGS},optionKey:`htmlTags`},{handler:{name:`setextHeadings`,handle:BO,priority:KO.SETEXT_HEADINGS},optionKey:`setextHeadings`},{handler:{name:`links`,handle:FO,priority:KO.LINKS},optionKey:`links`,earlyReturn:e=>e.endsWith(`](streamdown:incomplete-link)`)},{handler:{name:`boldItalic`,handle:bO,priority:KO.BOLD_ITALIC},optionKey:`boldItalic`},{handler:{name:`bold`,handle:lO,priority:KO.BOLD},optionKey:`bold`},{handler:{name:`italicDoubleUnderscore`,handle:dO,priority:KO.ITALIC_DOUBLE_UNDERSCORE},optionKey:`italic`},{handler:{name:`italicSingleAsterisk`,handle:pO,priority:KO.ITALIC_SINGLE_ASTERISK},optionKey:`italic`},{handler:{name:`italicSingleUnderscore`,handle:_O,priority:KO.ITALIC_SINGLE_UNDERSCORE},optionKey:`italic`},{handler:{name:`inlineCode`,handle:TO,priority:KO.INLINE_CODE},optionKey:`inlineCode`},{handler:{name:`strikethrough`,handle:UO,priority:KO.STRIKETHROUGH},optionKey:`strikethrough`},{handler:{name:`katex`,handle:AO,priority:KO.KATEX},optionKey:`katex`},{handler:{name:`inlineKatex`,handle:jO,priority:KO.INLINE_KATEX},optionKey:`inlineKatex`}],JO=e=>{let t=e?.linkMode??`protocol`;return qO.filter(({handler:t,optionKey:n})=>t.name===`links`?WO(e?.links)||WO(e?.images):t.name===`inlineKatex`?GO(e?.inlineKatex):WO(e?.[n])).map(({handler:e,earlyReturn:n})=>e.name===`links`?{handler:TD(wD({},e),{handle:e=>FO(e,t)}),earlyReturn:t===`protocol`?n:void 0}:{handler:e,earlyReturn:n})},YO=(e,t)=>{if(!e||typeof e!=`string`)return e;let n=e.endsWith(` `)&&!e.endsWith(` `)?e.slice(0,-1):e,r=JO(t),i=(t?.handlers??[]).map(e=>({handler:TD(wD({},e),{priority:e.priority??KO.DEFAULT}),earlyReturn:void 0})),a=[...r,...i].sort((e,t)=>(e.handler.priority??0)-(t.handler.priority??0));for(let{handler:e,earlyReturn:t}of a)if(n=e.handle(n),t!=null&&t(n))return n;return n},XO=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,ZO=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,QO={};function $O(e,t){return((t||QO).jsx?ZO:XO).test(e)}var ek=/[ \t\n\f\r]/g;function tk(e){return typeof e==`object`?e.type===`text`?nk(e.value):!1:nk(e)}function nk(e){return e.replace(ek,``)===``}var rk=n(((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,u=`
106
- `,d=`/`,f=`*`,p=``,m=`comment`,h=`declaration`;function g(e,t){if(typeof e!=`string`)throw TypeError(`First argument must be a string`);if(!e)return[];t||={};var l=1,g=1;function v(e){var t=e.match(r);t&&(l+=t.length);var n=e.lastIndexOf(u);g=~n?e.length-n:g+e.length}function y(){var e={line:l,column:g};return function(t){return t.position=new b(e),C(),t}}function b(e){this.start=e,this.end={line:l,column:g},this.source=t.source}b.prototype.content=e;function x(n){var r=Error(t.source+`:`+l+`:`+g+`: `+n);if(r.reason=n,r.filename=t.source,r.line=l,r.column=g,r.source=e,!t.silent)throw r}function S(t){var n=t.exec(e);if(n){var r=n[0];return v(r),e=e.slice(r.length),n}}function C(){S(i)}function w(e){var t;for(e||=[];t=T();)t!==!1&&e.push(t);return e}function T(){var t=y();if(!(d!=e.charAt(0)||f!=e.charAt(1))){for(var n=2;p!=e.charAt(n)&&(f!=e.charAt(n)||d!=e.charAt(n+1));)++n;if(n+=2,p===e.charAt(n-1))return x(`End of comment missing`);var r=e.slice(2,n-2);return g+=2,v(r),e=e.slice(n),g+=2,t({type:m,comment:r})}}function E(){var e=y(),t=S(a);if(t){if(T(),!S(o))return x(`property missing ':'`);var r=S(s),i=e({type:h,property:_(t[0].replace(n,p)),value:r?_(r[0].replace(n,p)):p});return S(c),i}}function D(){var e=[];w(e);for(var t;t=E();)t!==!1&&(e.push(t),w(e));return e}return C(),D()}function _(e){return e?e.replace(l,p):p}t.exports=g})),ik=n((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(rk());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}})),ak=n((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))}})),ok=n(((e,t)=>{var n=(e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(ik()),r=ak();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}));function sk(e){return!e||typeof e!=`object`?``:`position`in e||`type`in e?lk(e.position):`start`in e||`end`in e?lk(e):`line`in e||`column`in e?ck(e):``}function ck(e){return uk(e&&e.line)+`:`+uk(e&&e.column)}function lk(e){return ck(e&&e.start)+`-`+ck(e&&e.end)}function uk(e){return e&&typeof e==`number`?e:1}var dk=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=sk(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}};dk.prototype.file=``,dk.prototype.name=``,dk.prototype.reason=``,dk.prototype.message=``,dk.prototype.stack=``,dk.prototype.column=void 0,dk.prototype.line=void 0,dk.prototype.ancestors=void 0,dk.prototype.cause=void 0,dk.prototype.fatal=void 0,dk.prototype.place=void 0,dk.prototype.ruleId=void 0,dk.prototype.source=void 0;var fk=t(ok(),1),pk={}.hasOwnProperty,mk=new Map,hk=/[A-Z]/g,gk=new Set([`table`,`tbody`,`thead`,`tfoot`,`tr`]),_k=new Set([`td`,`th`]),vk=`https://github.com/syntax-tree/hast-util-to-jsx-runtime`;function yk(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=Ak(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=kk(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`?mg:pg,stylePropertyNameCase:t.stylePropertyNameCase||`dom`,tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=bk(i,e,void 0);return a&&typeof a!=`string`?a:i.create(e,i.Fragment,{children:a||void 0},void 0)}function bk(e,t,n){if(t.type===`element`)return xk(e,t,n);if(t.type===`mdxFlowExpression`||t.type===`mdxTextExpression`)return Sk(e,t);if(t.type===`mdxJsxFlowElement`||t.type===`mdxJsxTextElement`)return wk(e,t,n);if(t.type===`mdxjsEsm`)return Ck(e,t);if(t.type===`root`)return Tk(e,t,n);if(t.type===`text`)return Ek(e,t)}function xk(e,t,n){let r=e.schema,i=r;t.tagName.toLowerCase()===`svg`&&r.space===`html`&&(i=mg,e.schema=i),e.ancestors.push(t);let a=Ik(e,t.tagName,!1),o=jk(e,t),s=Nk(e,t);return gk.has(t.tagName)&&(s=s.filter(function(e){return typeof e==`string`?!tk(e):!0})),Dk(e,o,a,t),Ok(o,s),e.ancestors.pop(),e.schema=r,e.create(t,a,o,n)}function Sk(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)}Lk(e,t.position)}function Ck(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);Lk(e,t.position)}function wk(e,t,n){let r=e.schema,i=r;t.name===`svg`&&r.space===`html`&&(i=mg,e.schema=i),e.ancestors.push(t);let a=t.name===null?e.Fragment:Ik(e,t.name,!0),o=Mk(e,t),s=Nk(e,t);return Dk(e,o,a,t),Ok(o,s),e.ancestors.pop(),e.schema=r,e.create(t,a,o,n)}function Tk(e,t,n){let r={};return Ok(r,Nk(e,t)),e.create(t,e.Fragment,r,n)}function Ek(e,t){return t.value}function Dk(e,t,n,r){typeof n!=`string`&&n!==e.Fragment&&e.passNode&&(t.node=r)}function Ok(e,t){if(t.length>0){let n=t.length>1?t:t[0];n&&(e.children=n)}}function kk(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 Ak(e,t){return n;function n(n,r,i,a){let o=Array.isArray(i.children),s=fx(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 jk(e,t){let n={},r,i;for(i in t.properties)if(i!==`children`&&pk.call(t.properties,i)){let a=Pk(e,i,t.properties[i]);if(a){let[i,o]=a;e.tableCellAlignToStyle&&i===`align`&&typeof o==`string`&&_k.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 Mk(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 Lk(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 Lk(e,t.position);else a=r.value===null?!0:r.value;n[i]=a}return n}function Nk(e,t){let n=[],r=-1,i=e.passKeys?new Map:mk;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=bk(e,a,o);s!==void 0&&n.push(s)}return n}function Pk(e,t,n){let r=ug(e.schema,t);if(!(n==null||typeof n==`number`&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?gg(n):bg(n)),r.property===`style`){let t=typeof n==`object`?n:Fk(e,String(n));return e.stylePropertyNameCase===`css`&&(t=Rk(t)),[`style`,t]}return[e.elementAttributeNameCase===`react`&&r.space?og[r.property]||r.property:r.attribute,n]}}function Fk(e,t){try{return(0,fk.default)(t,{reactCompat:!0})}catch(t){if(e.ignoreInvalidStyle)return{};let n=t,r=new dk("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=vk+`#cannot-parse-style-attribute`,r}}function Ik(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=$O(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=$O(t)&&!/^[a-z]/.test(t)?{type:`Identifier`,name:t}:{type:`Literal`,value:t};if(r.type===`Literal`){let t=r.value;return pk.call(e.components,t)?e.components[t]:t}if(e.evaluater)return e.evaluater.evaluateExpression(r);Lk(e)}function Lk(e,t){let n=new dk("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=vk+`#cannot-handle-mdx-estrees-without-createevaluater`,n}function Rk(e){let t={},n;for(n in e)pk.call(e,n)&&(t[zk(n)]=e[n]);return t}function zk(e){let t=e.replace(hk,Bk);return t.slice(0,3)===`ms-`&&(t=`-`+t),t}function Bk(e){return`-`+e.toLowerCase()}var Vk={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`]},Hk={tokenize:Uk};function Uk(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`),mT(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 Q(t)?(e.consume(t),e.exit(`chunkText`),a):(e.consume(t),o)}}var Wk={tokenize:Kk},Gk={tokenize:qk};function Kk(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 Aw(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(Gk,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(Gk,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 Q(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++;Aw(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 qk(e,t,n){return mT(e,e.attempt(this.parser.constructs.document,t,n),`linePrefix`,this.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)}var Jk={tokenize:Yk};function Yk(e){let t=this,n=e.attempt(hT,r,e.attempt(this.parser.constructs.flowInitial,i,mT(e,e.attempt(this.parser.constructs.flow,i,e.attempt(VT,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 Xk={resolveAll:eA()},Zk=$k(`string`),Qk=$k(`text`);function $k(e){return{resolveAll:eA(e===`text`?tA: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 eA(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 tA(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 nA=e({attentionMarkers:()=>uA,contentInitial:()=>iA,disable:()=>dA,document:()=>rA,flow:()=>oA,flowInitial:()=>aA,insideSpan:()=>lA,string:()=>sA,text:()=>cA}),rA={42:PE,43:PE,45:PE,48:PE,49:PE,50:PE,51:PE,52:PE,53:PE,54:PE,55:PE,56:PE,57:PE,62:_T},iA={91:XT},aA={[-2]:kT,[-1]:kT,32:kT},oA={35:nE,42:ME,45:[HE,ME],60:sE,61:HE,95:ME,96:ET,126:ET},sA={38:CT,92:xT},cA={[-5]:AE,[-4]:AE,[-3]:AE,33:EE,38:CT,42:cT,60:[fT,mE],91:OE,92:[eE,xT],93:gE,95:cT,96:NT},lA={null:[cT,Xk]},uA={null:[42,95]},dA={null:[]};function fA(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=jw(o,e),g(),o[o.length-1]===null?(w(t,0),l.events=sT(a,l.events,l),l.events):[]}function f(e,t){return mA(p(e),t)}function p(e){return pA(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){Q(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&&Aw(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 pA(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 mA(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=`
107
- `;break;case-3:o=`\r
108
- `;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 hA(e){let t={constructs:Nw([nA,...(e||{}).extensions||[]]),content:n(Hk),defined:[],document:n(Wk),flow:n(Jk),lazy:{},string:n(Zk),text:n(Qk)};return t;function n(e){return n;function n(n){return fA(t,e,n)}}}function gA(e){for(;!zT(e););return e}var _A=/[\0\t\n\r]/g;function vA(){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(_A.lastIndex=u,c=_A.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 yA={}.hasOwnProperty;function bA(e,t,n){return t&&typeof t==`object`&&(n=t,t=void 0),xA(n)(gA(hA(n).document().write(vA()(e,t,!0))))}function xA(e){let t={transforms:[],canContainEols:[`emphasis`,`fragment`,`heading`,`paragraph`,`strong`],enter:{autolink:a(ve),autolinkProtocol:T,autolinkEmail:T,atxHeading:a(me),blockQuote:a(le),characterEscape:T,characterReference:T,codeFenced:a(ue),codeFencedFenceInfo:o,codeFencedFenceMeta:o,codeIndented:a(ue,o),codeText:a(de,o),codeTextData:T,data:T,codeFlowValue:T,definition:a(fe),definitionDestinationString:o,definitionLabelString:o,definitionTitleString:o,emphasis:a(pe),hardBreakEscape:a(he),hardBreakTrailing:a(he),htmlFlow:a(ge,o),htmlFlowData:T,htmlText:a(ge,o),htmlTextData:T,image:a(_e),label:o,link:a(ve),listItem:a(be),listItemValue:f,listOrdered:a(ye,d),listUnordered:a(ye),paragraph:a(xe),reference:ie,referenceString:o,resourceDestinationString:o,resourceTitleString:o,setextHeading:a(me),strong:a(Se),thematicBreak:a(we)},exit:{atxHeading:c(),atxHeadingSequence:x,autolink:c(),autolinkEmail:ce,autolinkProtocol:se,blockQuote:c(),characterEscapeValue:E,characterReferenceMarkerHexadecimal:oe,characterReferenceMarkerNumeric:oe,characterReferenceValue:F,characterReference:I,codeFenced:c(g),codeFencedFence:h,codeFencedFenceInfo:p,codeFencedFenceMeta:m,codeFlowValue:E,codeIndented:c(_),codeText:c(k),codeTextData:E,data:E,definition:c(),definitionDestinationString:b,definitionLabelString:v,definitionTitleString:y,emphasis:c(),hardBreakEscape:c(O),hardBreakTrailing:c(O),htmlFlow:c(ee),htmlFlowData:E,htmlText:c(te),htmlTextData:E,image:c(j),label:ne,labelText:M,lineEnding:D,link:c(A),listItem:c(),listOrdered:c(),listUnordered:c(),paragraph:c(),referenceString:ae,resourceDestinationString:N,resourceTitleString:P,resource:re,setextHeading:c(w),setextHeadingLineSequence:C,setextHeadingText:S,strong:c(),thematicBreak:c()}};CA(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]];yA.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]||TA).call(a,void 0,e[0])}for(r.position={start:SA(e.length>0?e[0][1].start:{line:1,column:1,offset:0}),end:SA(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:SA(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]||TA).call(this,e,r[0]));else throw Error("Cannot close `"+e.type+"` ("+sk({start:e.start,end:e.end})+`): it’s not open`);n.position.end=SA(e.end)}function u(){return EC(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=FS(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=Ce(),n.position={start:SA(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=SA(e.end)}function D(e){let n=this.stack[this.stack.length-1];if(this.data.atHardBreak){let t=n.children[n.children.length-1];t.position.end=SA(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 O(){this.data.atHardBreak=!0}function ee(){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 k(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function A(){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 j(){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 M(e){let t=this.sliceSerialize(e),n=this.stack[this.stack.length-2];n.label=fw(t),n.identifier=FS(t).toLowerCase()}function ne(){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 N(){let e=this.resume(),t=this.stack[this.stack.length-1];t.url=e}function P(){let e=this.resume(),t=this.stack[this.stack.length-1];t.title=e}function re(){this.data.inReference=void 0}function ie(){this.data.referenceType=`collapsed`}function ae(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=FS(this.sliceSerialize(e)).toLowerCase(),this.data.referenceType=`full`}function oe(e){this.data.characterReferenceType=e.type}function F(e){let t=this.sliceSerialize(e),n=this.data.characterReferenceType,r;n?(r=uw(t,n===`characterReferenceMarkerNumeric`?10:16),this.data.characterReferenceType=void 0):r=lw(t);let i=this.stack[this.stack.length-1];i.value+=r}function I(e){let t=this.stack.pop();t.position.end=SA(e.end)}function se(e){E.call(this,e);let t=this.stack[this.stack.length-1];t.url=this.sliceSerialize(e)}function ce(e){E.call(this,e);let t=this.stack[this.stack.length-1];t.url=`mailto:`+this.sliceSerialize(e)}function le(){return{type:`blockquote`,children:[]}}function ue(){return{type:`code`,lang:null,meta:null,value:``}}function de(){return{type:`inlineCode`,value:``}}function fe(){return{type:`definition`,identifier:``,label:null,title:null,url:``}}function pe(){return{type:`emphasis`,children:[]}}function me(){return{type:`heading`,depth:0,children:[]}}function he(){return{type:`break`}}function ge(){return{type:`html`,value:``}}function _e(){return{type:`image`,title:null,url:``,alt:null}}function ve(){return{type:`link`,title:null,url:``,children:[]}}function ye(e){return{type:`list`,ordered:e.type===`listOrdered`,start:null,spread:e._spread,children:[]}}function be(e){return{type:`listItem`,spread:e._spread,checked:null,children:[]}}function xe(){return{type:`paragraph`,children:[]}}function Se(){return{type:`strong`,children:[]}}function Ce(){return{type:`text`,value:``}}function we(){return{type:`thematicBreak`}}}function SA(e){return{line:e.line,column:e.column,offset:e.offset}}function CA(e,t){let n=-1;for(;++n<t.length;){let r=t[n];Array.isArray(r)?CA(e,r):wA(e,r)}}function wA(e,t){let n;for(n in t)if(yA.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 TA(e,t){throw Error(e?"Cannot close `"+e.type+"` ("+sk({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+sk({start:t.start,end:t.end})+`) is open`:"Cannot close document, a token (`"+t.type+"`, "+sk({start:t.start,end:t.end})+`) is still open`)}function EA(e){let t=this;t.parser=n;function n(n){return bA(n,{...t.data(`settings`),...e,extensions:t.data(`micromarkExtensions`)||[],mdastExtensions:t.data(`fromMarkdownExtensions`)||[]})}}function DA(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 OA(e,t){let n={type:`element`,tagName:`br`,properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:`text`,value:`
109
- `}]}function kA(e,t){let n=t.value?t.value+`
110
- `:``,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 AA(e,t){let n={type:`element`,tagName:`del`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function jA(e,t){let n={type:`element`,tagName:`em`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function MA(e,t){let n=typeof e.options.clobberPrefix==`string`?e.options.clobberPrefix:`user-content-`,r=String(t.identifier).toUpperCase(),i=oT(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 NA(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 PA(e,t){if(e.options.allowDangerousHtml){let n={type:`raw`,value:t.value};return e.patch(t,n),e.applyData(t,n)}}function FA(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 IA(e,t){let n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return FA(e,t);let i={src:oT(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 LA(e,t){let n={src:oT(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 RA(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 zA(e,t){let n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return FA(e,t);let i={href:oT(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 BA(e,t){let n={href:oT(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 VA(e,t,n){let r=e.all(t),i=n?HA(n):UA(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:`
111
- `}),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:`
112
- `});let l={type:`element`,tagName:`li`,properties:a,children:o};return e.patch(t,l),e.applyData(t,l)}function HA(e){let t=!1;if(e.type===`list`){t=e.spread||!1;let n=e.children,r=-1;for(;!t&&++r<n.length;)t=UA(n[r])}return t}function UA(e){return e.spread??e.children.length>1}function WA(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 GA(e,t){let n={type:`element`,tagName:`p`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function KA(e,t){let n={type:`root`,children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function qA(e,t){let n={type:`element`,tagName:`strong`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function JA(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=fx(t.children[1]),o=dx(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 YA(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 XA(e,t){let n={type:`element`,tagName:`td`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}var ZA=9,QA=32;function $A(e){let t=String(e),n=/\r?\n|\r/g,r=n.exec(t),i=0,a=[];for(;r;)a.push(ej(t.slice(i,r.index),i>0,!0),r[0]),i=r.index+r[0].length,r=n.exec(t);return a.push(ej(t.slice(i),i>0,!1)),a.join(``)}function ej(e,t,n){let r=0,i=e.length;if(t){let t=e.codePointAt(r);for(;t===ZA||t===QA;)r++,t=e.codePointAt(r)}if(n){let t=e.codePointAt(i-1);for(;t===ZA||t===QA;)i--,t=e.codePointAt(i-1)}return i>r?e.slice(r,i):``}function tj(e,t){let n={type:`text`,value:$A(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function nj(e,t){let n={type:`element`,tagName:`hr`,properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}var rj={blockquote:DA,break:OA,code:kA,delete:AA,emphasis:jA,footnoteReference:MA,heading:NA,html:PA,imageReference:IA,image:LA,inlineCode:RA,linkReference:zA,link:BA,listItem:VA,list:WA,paragraph:GA,root:KA,strong:qA,table:JA,tableCell:XA,tableRow:YA,text:tj,thematicBreak:nj,toml:ij,yaml:ij,definition:ij,footnoteDefinition:ij};function ij(){}function aj(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 oj(e,t){return`Back to reference `+(e+1)+(t>1?`-`+t:``)}function sj(e){let t=typeof e.options.clobberPrefix==`string`?e.options.clobberPrefix:`user-content-`,n=e.options.footnoteBackContent||aj,r=e.options.footnoteBackLabel||oj,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=oT(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:{...Ph(o),id:`footnote-label`},children:[{type:`text`,value:i}]},{type:`text`,value:`
113
- `},{type:`element`,tagName:`ol`,properties:{},children:e.wrap(s,!0)},{type:`text`,value:`
114
- `}]}}var cj={}.hasOwnProperty,lj={};function uj(e,t){let n=t||lj,r=new Map,i=new Map,a={all:s,applyData:fj,definitionById:r,footnoteById:i,footnoteCounts:new Map,footnoteOrder:[],handlers:{...rj,...n.handlers},one:o,options:n,patch:dj,wrap:mj};return dh(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(cj.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=Ph(n);return r.children=a.all(e),r}return Ph(e)}return(a.options.unknownHandler||pj)(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=hj(i.value)),!Array.isArray(i)&&i.type===`element`)){let e=i.children[0];e&&e.type===`text`&&(e.value=hj(e.value))}Array.isArray(i)?t.push(...i):t.push(i)}}}return t}}function dj(e,t){e.position&&(t.position=mx(e))}function fj(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,Ph(i)),`children`in n&&n.children&&r!=null&&(n.children=r)}return n}function pj(e,t){let n=t.data||{},r=`value`in t&&!(cj.call(n,`hProperties`)||cj.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 mj(e,t){let n=[],r=-1;for(t&&n.push({type:`text`,value:`
115
- `});++r<e.length;)r&&n.push({type:`text`,value:`
116
- `}),n.push(e[r]);return t&&e.length>0&&n.push({type:`text`,value:`
117
- `}),n}function hj(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function gj(e,t){let n=uj(e,t),r=n.one(e,void 0),i=sj(n),a=Array.isArray(r)?{type:`root`,children:r}:r||{type:`root`,children:[]};return i&&(`children`in a,a.children.push({type:`text`,value:`
118
- `},i)),a}function _j(e,t){return e&&`run`in e?async function(n,r){let i=gj(n,{file:r,...t});await e.run(i,r)}:function(n,r){return gj(n,{file:r,...e||t})}}function vj(e){if(e)throw e}var yj=n(((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 bj(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 xj(){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?Sj(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 Sj(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 Cj={basename:wj,dirname:Tj,extname:Ej,join:Dj,sep:`/`};function wj(e,t){if(t!==void 0&&typeof t!=`string`)throw TypeError(`"ext" argument must be a string`);Aj(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 Tj(e){if(Aj(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 Ej(e){Aj(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 Dj(...e){let t=-1,n;for(;++t<e.length;)Aj(e[t]),e[t]&&(n=n===void 0?e[t]:n+`/`+e[t]);return n===void 0?`.`:Oj(n)}function Oj(e){Aj(e);let t=e.codePointAt(0)===47,n=kj(e,!t);return n.length===0&&!t&&(n=`.`),n.length>0&&e.codePointAt(e.length-1)===47&&(n+=`/`),t?`/`+n:n}function kj(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 Aj(e){if(typeof e!=`string`)throw TypeError(`Path must be a string. Received `+JSON.stringify(e))}var jj={cwd:Mj};function Mj(){return`/`}function Nj(e){return!!(typeof e==`object`&&e&&`href`in e&&e.href&&`protocol`in e&&e.protocol&&e.auth===void 0)}function Pj(e){if(typeof e==`string`)e=new URL(e);else if(!Nj(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 Fj(e)}function Fj(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 Ij=[`history`,`path`,`basename`,`stem`,`extname`,`dirname`],Lj=class{constructor(e){let t;t=e?Nj(e)?{path:e}:typeof e==`string`||Vj(e)?{value:e}:e:{},this.cwd=`cwd`in t?``:jj.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let n=-1;for(;++n<Ij.length;){let e=Ij[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)Ij.includes(r)||(this[r]=t[r])}get basename(){return typeof this.path==`string`?Cj.basename(this.path):void 0}set basename(e){zj(e,`basename`),Rj(e,`basename`),this.path=Cj.join(this.dirname||``,e)}get dirname(){return typeof this.path==`string`?Cj.dirname(this.path):void 0}set dirname(e){Bj(this.basename,`dirname`),this.path=Cj.join(e||``,this.basename)}get extname(){return typeof this.path==`string`?Cj.extname(this.path):void 0}set extname(e){if(Rj(e,`extname`),Bj(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=Cj.join(this.dirname,this.stem+(e||``))}get path(){return this.history[this.history.length-1]}set path(e){Nj(e)&&(e=Pj(e)),zj(e,`path`),this.path!==e&&this.history.push(e)}get stem(){return typeof this.path==`string`?Cj.basename(this.path,this.extname):void 0}set stem(e){zj(e,`stem`),Rj(e,`stem`),this.path=Cj.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 dk(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 Rj(e,t){if(e&&e.includes(Cj.sep))throw Error("`"+t+"` cannot be a path: did not expect `"+Cj.sep+"`")}function zj(e,t){if(!e)throw Error("`"+t+"` cannot be empty")}function Bj(e,t){if(!e)throw Error("Setting `"+t+"` requires `path` to be set too")}function Vj(e){return!!(e&&typeof e==`object`&&`byteLength`in e&&`byteOffset`in e)}var Hj=(function(e){let t=this.constructor.prototype,n=t[e],r=function(){return n.apply(r,arguments)};return Object.setPrototypeOf(r,t),r}),Uj=t(yj(),1),Wj={}.hasOwnProperty,Gj=new class e extends Hj{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=xj()}copy(){let t=new e,n=-1;for(;++n<this.attachers.length;){let e=this.attachers[n];t.use(...e)}return t.data((0,Uj.default)(!0,{},this.namespace)),t}data(e,t){return typeof e==`string`?arguments.length===2?(Jj(`data`,this.frozen),this.namespace[e]=t,this):Wj.call(this.namespace,e)&&this.namespace[e]||void 0:e?(Jj(`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=Zj(e),n=this.parser||this.Parser;return Kj(`parse`,n),n(String(t),t)}process(e,t){let n=this;return this.freeze(),Kj(`process`,this.parser||this.Parser),qj(`process`,this.compiler||this.Compiler),t?r(void 0,t):new Promise(r);function r(r,i){let a=Zj(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);$j(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(),Kj(`processSync`,this.parser||this.Parser),qj(`processSync`,this.compiler||this.Compiler),this.process(e,r),Xj(`processSync`,`process`,t),n;function r(e,r){t=!0,vj(e),n=r}}run(e,t,n){Yj(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=Zj(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),Xj(`runSync`,`run`,n),r;function i(e,t){vj(e),r=t,n=!0}}stringify(e,t){this.freeze();let n=Zj(t),r=this.compiler||this.Compiler;return qj(`stringify`,r),Yj(e),r(e,n)}use(e,...t){let n=this.attachers,r=this.namespace;if(Jj(`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,Uj.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];bj(o)&&bj(r)&&(r=(0,Uj.default)(!0,o,r)),n[i]=[e,r,...a]}}}}().freeze();function Kj(e,t){if(typeof t!=`function`)throw TypeError("Cannot `"+e+"` without `parser`")}function qj(e,t){if(typeof t!=`function`)throw TypeError("Cannot `"+e+"` without `compiler`")}function Jj(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 Yj(e){if(!bj(e)||typeof e.type!=`string`)throw TypeError("Expected node, got `"+e+"`")}function Xj(e,t,n){if(!n)throw Error("`"+e+"` finished async. Use `"+t+"` instead")}function Zj(e){return Qj(e)?e:new Lj(e)}function Qj(e){return!!(e&&typeof e==`object`&&`message`in e&&`messages`in e)}function $j(e){return typeof e==`string`||eM(e)}function eM(e){return!!(e&&typeof e==`object`&&`byteLength`in e&&`byteOffset`in e)}function tM(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var nM=tM();function rM(e){nM=e}var iM={exec:()=>null};function aM(e,t=``){let n=typeof e==`string`?e:e.source,r={replace:(e,t)=>{let i=typeof t==`string`?t:t.source;return i=i.replace(sM.caret,`$1`),n=n.replace(e,i),r},getRegex:()=>new RegExp(n,t)};return r}var oM=(()=>{try{return!0}catch{return!1}})(),sM={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] +\S/,listReplaceTask:/^\[[ xX]\] +/,listTaskCheckbox:/\[[ xX]\]/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}#`),htmlBeginRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}<(?:[a-z].*>|!--)`,`i`),blockquoteBeginRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}>`)},cM=/^(?:[ \t]*(?:\n|$))+/,lM=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,uM=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,dM=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,fM=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,pM=/ {0,3}(?:[*+-]|\d{1,9}[.)])/,mM=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,hM=aM(mM).replace(/bull/g,pM).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,``).getRegex(),gM=aM(mM).replace(/bull/g,pM).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),_M=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,vM=/^[^\n]+/,yM=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,bM=aM(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace(`label`,yM).replace(`title`,/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),xM=aM(/^(bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,pM).getRegex(),SM=`address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul`,CM=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,wM=aM(`^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))`,`i`).replace(`comment`,CM).replace(`tag`,SM).replace(`attribute`,/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),TM=aM(_M).replace(`hr`,dM).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`|lheading`,``).replace(`|table`,``).replace(`blockquote`,` {0,3}>`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace(`list`,` {0,3}(?:[*+-]|1[.)])[ \\t]`).replace(`html`,`</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,SM).getRegex(),EM={blockquote:aM(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace(`paragraph`,TM).getRegex(),code:lM,def:bM,fences:uM,heading:fM,hr:dM,html:wM,lheading:hM,list:xM,newline:cM,paragraph:TM,table:iM,text:vM},DM=aM(`^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)`).replace(`hr`,dM).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`blockquote`,` {0,3}>`).replace(`code`,`(?: {4}| {0,3} )[^\\n]`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace(`list`,` {0,3}(?:[*+-]|1[.)])[ \\t]`).replace(`html`,`</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,SM).getRegex(),OM={...EM,lheading:gM,table:DM,paragraph:aM(_M).replace(`hr`,dM).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`|lheading`,``).replace(`table`,DM).replace(`blockquote`,` {0,3}>`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace(`list`,` {0,3}(?:[*+-]|1[.)])[ \\t]`).replace(`html`,`</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,SM).getRegex()},kM={...EM,html:aM(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace(`comment`,CM).replace(/tag/g,`(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b`).getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:iM,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:aM(_M).replace(`hr`,dM).replace(`heading`,` *#{1,6} *[^
119
- ]`).replace(`lheading`,hM).replace(`|table`,``).replace(`blockquote`,` {0,3}>`).replace(`|fences`,``).replace(`|list`,``).replace(`|html`,``).replace(`|tag`,``).getRegex()},AM=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,jM=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,MM=/^( {2,}|\\)\n(?!\s*$)/,NM=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,PM=/[\p{P}\p{S}]/u,FM=/[\s\p{P}\p{S}]/u,IM=/[^\s\p{P}\p{S}]/u,LM=aM(/^((?![*_])punctSpace)/,`u`).replace(/punctSpace/g,FM).getRegex(),RM=/(?!~)[\p{P}\p{S}]/u,zM=/(?!~)[\s\p{P}\p{S}]/u,BM=/(?:[^\s\p{P}\p{S}]|~)/u,VM=aM(/link|precode-code|html/,`g`).replace(`link`,/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace(`precode-`,oM?"(?<!`)()":"(^^|[^`])").replace(`code`,/(?<b>`+)[^`]+\k<b>(?!`)/).replace(`html`,/<(?! )[^<>]*?>/).getRegex(),HM=/^(?:\*+(?:((?!\*)punct)|([^\s*]))?)|^_+(?:((?!_)punct)|([^\s_]))?/,UM=aM(HM,`u`).replace(/punct/g,PM).getRegex(),WM=aM(HM,`u`).replace(/punct/g,RM).getRegex(),GM=`^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)`,KM=aM(GM,`gu`).replace(/notPunctSpace/g,IM).replace(/punctSpace/g,FM).replace(/punct/g,PM).getRegex(),qM=aM(GM,`gu`).replace(/notPunctSpace/g,BM).replace(/punctSpace/g,zM).replace(/punct/g,RM).getRegex(),JM=aM(`^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)`,`gu`).replace(/notPunctSpace/g,IM).replace(/punctSpace/g,FM).replace(/punct/g,PM).getRegex(),YM=aM(/^~~?(?:((?!~)punct)|[^\s~])/,`u`).replace(/punct/g,PM).getRegex(),XM=aM(`^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)`,`gu`).replace(/notPunctSpace/g,IM).replace(/punctSpace/g,FM).replace(/punct/g,PM).getRegex(),ZM=aM(/\\(punct)/,`gu`).replace(/punct/g,PM).getRegex(),QM=aM(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace(`scheme`,/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace(`email`,/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),$M=aM(CM).replace(`(?:-->|$)`,`-->`).getRegex(),eN=aM(`^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>`).replace(`comment`,$M).replace(`attribute`,/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),tN=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\])|[^\[\]\\`])*?/,nN=aM(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]+(?:\n[ \t]*)?|\n[ \t]*)(title))?\s*\)/).replace(`label`,tN).replace(`href`,/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace(`title`,/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),rN=aM(/^!?\[(label)\]\[(ref)\]/).replace(`label`,tN).replace(`ref`,yM).getRegex(),iN=aM(/^!?\[(ref)\](?:\[\])?/).replace(`ref`,yM).getRegex(),aN=aM(`reflink|nolink(?!\\()`,`g`).replace(`reflink`,rN).replace(`nolink`,iN).getRegex(),oN=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,sN={_backpedal:iM,anyPunctuation:ZM,autolink:QM,blockSkip:VM,br:MM,code:jM,del:iM,delLDelim:iM,delRDelim:iM,emStrongLDelim:UM,emStrongRDelimAst:KM,emStrongRDelimUnd:JM,escape:AM,link:nN,nolink:iN,punctuation:LM,reflink:rN,reflinkSearch:aN,tag:eN,text:NM,url:iM},cN={...sN,link:aM(/^!?\[(label)\]\((.*?)\)/).replace(`label`,tN).getRegex(),reflink:aM(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace(`label`,tN).getRegex()},lN={...sN,emStrongRDelimAst:qM,emStrongLDelim:WM,delLDelim:YM,delRDelim:XM,url:aM(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace(`protocol`,oN).replace(`email`,/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:aM(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace(`protocol`,oN).getRegex()},uN={...lN,br:aM(MM).replace(`{2,}`,`*`).getRegex(),text:aM(lN.text).replace(`\\b_`,`\\b_| {2,}\\n`).replace(/\{2,\}/g,`*`).getRegex()},dN={normal:EM,gfm:OM,pedantic:kM},fN={normal:sN,gfm:lN,breaks:uN,pedantic:cN},pN={"&":`&amp;`,"<":`&lt;`,">":`&gt;`,'"':`&quot;`,"'":`&#39;`},mN=e=>pN[e];function hN(e,t){if(t){if(sM.escapeTest.test(e))return e.replace(sM.escapeReplace,mN)}else if(sM.escapeTestNoEncode.test(e))return e.replace(sM.escapeReplaceNoEncode,mN);return e}function gN(e){try{e=encodeURI(e).replace(sM.percentDecode,`%`)}catch{return null}return e}function _N(e,t){let n=e.replace(sM.findPipe,(e,t,n)=>{let r=!1,i=t;for(;--i>=0&&n[i]===`\\`;)r=!r;return r?`|`:` |`}).split(sM.splitPipe),r=0;if(n[0].trim()||n.shift(),n.length>0&&!n.at(-1)?.trim()&&n.pop(),t)if(n.length>t)n.splice(t);else for(;n.length<t;)n.push(``);for(;r<n.length;r++)n[r]=n[r].trim().replace(sM.slashPipe,`|`);return n}function vN(e,t,n){let r=e.length;if(r===0)return``;let i=0;for(;i<r;){let a=e.charAt(r-i-1);if(a===t&&!n)i++;else if(a!==t&&n)i++;else break}return e.slice(0,r-i)}function yN(e,t){if(e.indexOf(t[1])===-1)return-1;let n=0;for(let r=0;r<e.length;r++)if(e[r]===`\\`)r++;else if(e[r]===t[0])n++;else if(e[r]===t[1]&&(n--,n<0))return r;return n>0?-2:-1}function bN(e,t=0){let n=t,r=``;for(let t of e)if(t===` `){let e=4-n%4;r+=` `.repeat(e),n+=e}else r+=t,n++;return r}function xN(e,t,n,r,i){let a=t.href,o=t.title||null,s=e[1].replace(i.other.outputLinkReplace,`$1`);r.state.inLink=!0;let c={type:e[0].charAt(0)===`!`?`image`:`link`,raw:n,href:a,title:o,text:s,tokens:r.inlineTokens(s)};return r.state.inLink=!1,c}function SN(e,t,n){let r=e.match(n.other.indentCodeCompensation);if(r===null)return t;let i=r[1];return t.split(`
120
- `).map(e=>{let t=e.match(n.other.beginningSpace);if(t===null)return e;let[r]=t;return r.length>=i.length?e.slice(i.length):e}).join(`
121
- `)}var CN=class{options;rules;lexer;constructor(e){this.options=e||nM}space(e){let t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:`space`,raw:t[0]}}code(e){let t=this.rules.block.code.exec(e);if(t){let e=t[0].replace(this.rules.other.codeRemoveIndent,``);return{type:`code`,raw:t[0],codeBlockStyle:`indented`,text:this.options.pedantic?e:vN(e,`
122
- `)}}}fences(e){let t=this.rules.block.fences.exec(e);if(t){let e=t[0],n=SN(e,t[3]||``,this.rules);return{type:`code`,raw:e,lang:t[2]?t[2].trim().replace(this.rules.inline.anyPunctuation,`$1`):t[2],text:n}}}heading(e){let t=this.rules.block.heading.exec(e);if(t){let e=t[2].trim();if(this.rules.other.endingHash.test(e)){let t=vN(e,`#`);(this.options.pedantic||!t||this.rules.other.endingSpaceChar.test(t))&&(e=t.trim())}return{type:`heading`,raw:t[0],depth:t[1].length,text:e,tokens:this.lexer.inline(e)}}}hr(e){let t=this.rules.block.hr.exec(e);if(t)return{type:`hr`,raw:vN(t[0],`
123
- `)}}blockquote(e){let t=this.rules.block.blockquote.exec(e);if(t){let e=vN(t[0],`
124
- `).split(`
125
- `),n=``,r=``,i=[];for(;e.length>0;){let t=!1,a=[],o;for(o=0;o<e.length;o++)if(this.rules.other.blockquoteStart.test(e[o]))a.push(e[o]),t=!0;else if(!t)a.push(e[o]);else break;e=e.slice(o);let s=a.join(`
126
- `),c=s.replace(this.rules.other.blockquoteSetextReplace,`
127
- $1`).replace(this.rules.other.blockquoteSetextReplace2,``);n=n?`${n}
128
- ${s}`:s,r=r?`${r}
129
- ${c}`:c;let l=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(c,i,!0),this.lexer.state.top=l,e.length===0)break;let u=i.at(-1);if(u?.type===`code`)break;if(u?.type===`blockquote`){let t=u,a=t.raw+`
130
- `+e.join(`
131
- `),o=this.blockquote(a);i[i.length-1]=o,n=n.substring(0,n.length-t.raw.length)+o.raw,r=r.substring(0,r.length-t.text.length)+o.text;break}else if(u?.type===`list`){let t=u,a=t.raw+`
132
- `+e.join(`
133
- `),o=this.list(a);i[i.length-1]=o,n=n.substring(0,n.length-u.raw.length)+o.raw,r=r.substring(0,r.length-t.raw.length)+o.raw,e=a.substring(i.at(-1).raw.length).split(`
134
- `);continue}}return{type:`blockquote`,raw:n,tokens:i,text:r}}}list(e){let t=this.rules.block.list.exec(e);if(t){let n=t[1].trim(),r=n.length>1,i={type:`list`,raw:``,ordered:r,start:r?+n.slice(0,-1):``,loose:!1,items:[]};n=r?`\\d{1,9}\\${n.slice(-1)}`:`\\${n}`,this.options.pedantic&&(n=r?n:`[*+-]`);let a=this.rules.other.listItemRegex(n),o=!1;for(;e;){let n=!1,r=``,s=``;if(!(t=a.exec(e))||this.rules.block.hr.test(e))break;r=t[0],e=e.substring(r.length);let c=bN(t[2].split(`
135
- `,1)[0],t[1].length),l=e.split(`
136
- `,1)[0],u=!c.trim(),d=0;if(this.options.pedantic?(d=2,s=c.trimStart()):u?d=t[1].length+1:(d=c.search(this.rules.other.nonSpaceChar),d=d>4?1:d,s=c.slice(d),d+=t[1].length),u&&this.rules.other.blankLine.test(l)&&(r+=l+`
137
- `,e=e.substring(l.length+1),n=!0),!n){let t=this.rules.other.nextBulletRegex(d),n=this.rules.other.hrRegex(d),i=this.rules.other.fencesBeginRegex(d),a=this.rules.other.headingBeginRegex(d),o=this.rules.other.htmlBeginRegex(d),f=this.rules.other.blockquoteBeginRegex(d);for(;e;){let p=e.split(`
138
- `,1)[0],m;if(l=p,this.options.pedantic?(l=l.replace(this.rules.other.listReplaceNesting,` `),m=l):m=l.replace(this.rules.other.tabCharGlobal,` `),i.test(l)||a.test(l)||o.test(l)||f.test(l)||t.test(l)||n.test(l))break;if(m.search(this.rules.other.nonSpaceChar)>=d||!l.trim())s+=`
139
- `+m.slice(d);else{if(u||c.replace(this.rules.other.tabCharGlobal,` `).search(this.rules.other.nonSpaceChar)>=4||i.test(c)||a.test(c)||n.test(c))break;s+=`
140
- `+l}u=!l.trim(),r+=p+`
141
- `,e=e.substring(p.length+1),c=m.slice(d)}}i.loose||(o?i.loose=!0:this.rules.other.doubleBlankLine.test(r)&&(o=!0)),i.items.push({type:`list_item`,raw:r,task:!!this.options.gfm&&this.rules.other.listIsTask.test(s),loose:!1,text:s,tokens:[]}),i.raw+=r}let s=i.items.at(-1);if(s)s.raw=s.raw.trimEnd(),s.text=s.text.trimEnd();else return;i.raw=i.raw.trimEnd();for(let e of i.items){if(this.lexer.state.top=!1,e.tokens=this.lexer.blockTokens(e.text,[]),e.task){if(e.text=e.text.replace(this.rules.other.listReplaceTask,``),e.tokens[0]?.type===`text`||e.tokens[0]?.type===`paragraph`){e.tokens[0].raw=e.tokens[0].raw.replace(this.rules.other.listReplaceTask,``),e.tokens[0].text=e.tokens[0].text.replace(this.rules.other.listReplaceTask,``);for(let e=this.lexer.inlineQueue.length-1;e>=0;e--)if(this.rules.other.listIsTask.test(this.lexer.inlineQueue[e].src)){this.lexer.inlineQueue[e].src=this.lexer.inlineQueue[e].src.replace(this.rules.other.listReplaceTask,``);break}}let t=this.rules.other.listTaskCheckbox.exec(e.raw);if(t){let n={type:`checkbox`,raw:t[0]+` `,checked:t[0]!==`[ ]`};e.checked=n.checked,i.loose?e.tokens[0]&&[`paragraph`,`text`].includes(e.tokens[0].type)&&`tokens`in e.tokens[0]&&e.tokens[0].tokens?(e.tokens[0].raw=n.raw+e.tokens[0].raw,e.tokens[0].text=n.raw+e.tokens[0].text,e.tokens[0].tokens.unshift(n)):e.tokens.unshift({type:`paragraph`,raw:n.raw,text:n.raw,tokens:[n]}):e.tokens.unshift(n)}}if(!i.loose){let t=e.tokens.filter(e=>e.type===`space`);i.loose=t.length>0&&t.some(e=>this.rules.other.anyLine.test(e.raw))}}if(i.loose)for(let e of i.items){e.loose=!0;for(let t of e.tokens)t.type===`text`&&(t.type=`paragraph`)}return i}}html(e){let t=this.rules.block.html.exec(e);if(t)return{type:`html`,block:!0,raw:t[0],pre:t[1]===`pre`||t[1]===`script`||t[1]===`style`,text:t[0]}}def(e){let t=this.rules.block.def.exec(e);if(t){let e=t[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal,` `),n=t[2]?t[2].replace(this.rules.other.hrefBrackets,`$1`).replace(this.rules.inline.anyPunctuation,`$1`):``,r=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline.anyPunctuation,`$1`):t[3];return{type:`def`,tag:e,raw:t[0],href:n,title:r}}}table(e){let t=this.rules.block.table.exec(e);if(!t||!this.rules.other.tableDelimiter.test(t[2]))return;let n=_N(t[1]),r=t[2].replace(this.rules.other.tableAlignChars,``).split(`|`),i=t[3]?.trim()?t[3].replace(this.rules.other.tableRowBlankLine,``).split(`
142
- `):[],a={type:`table`,raw:t[0],header:[],align:[],rows:[]};if(n.length===r.length){for(let e of r)this.rules.other.tableAlignRight.test(e)?a.align.push(`right`):this.rules.other.tableAlignCenter.test(e)?a.align.push(`center`):this.rules.other.tableAlignLeft.test(e)?a.align.push(`left`):a.align.push(null);for(let e=0;e<n.length;e++)a.header.push({text:n[e],tokens:this.lexer.inline(n[e]),header:!0,align:a.align[e]});for(let e of i)a.rows.push(_N(e,a.header.length).map((e,t)=>({text:e,tokens:this.lexer.inline(e),header:!1,align:a.align[t]})));return a}}lheading(e){let t=this.rules.block.lheading.exec(e);if(t){let e=t[1].trim();return{type:`heading`,raw:t[0],depth:t[2].charAt(0)===`=`?1:2,text:e,tokens:this.lexer.inline(e)}}}paragraph(e){let t=this.rules.block.paragraph.exec(e);if(t){let e=t[1].charAt(t[1].length-1)===`
143
- `?t[1].slice(0,-1):t[1];return{type:`paragraph`,raw:t[0],text:e,tokens:this.lexer.inline(e)}}}text(e){let t=this.rules.block.text.exec(e);if(t)return{type:`text`,raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){let t=this.rules.inline.escape.exec(e);if(t)return{type:`escape`,raw:t[0],text:t[1]}}tag(e){let t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:`html`,raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){let t=this.rules.inline.link.exec(e);if(t){let e=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(e)){if(!this.rules.other.endAngleBracket.test(e))return;let t=vN(e.slice(0,-1),`\\`);if((e.length-t.length)%2==0)return}else{let e=yN(t[2],`()`);if(e===-2)return;if(e>-1){let n=(t[0].indexOf(`!`)===0?5:4)+t[1].length+e;t[2]=t[2].substring(0,e),t[0]=t[0].substring(0,n).trim(),t[3]=``}}let n=t[2],r=``;if(this.options.pedantic){let e=this.rules.other.pedanticHrefTitle.exec(n);e&&(n=e[1],r=e[3])}else r=t[3]?t[3].slice(1,-1):``;return n=n.trim(),this.rules.other.startAngleBracket.test(n)&&(n=this.options.pedantic&&!this.rules.other.endAngleBracket.test(e)?n.slice(1):n.slice(1,-1)),xN(t,{href:n&&n.replace(this.rules.inline.anyPunctuation,`$1`),title:r&&r.replace(this.rules.inline.anyPunctuation,`$1`)},t[0],this.lexer,this.rules)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){let e=t[(n[2]||n[1]).replace(this.rules.other.multipleSpaceGlobal,` `).toLowerCase()];if(!e){let e=n[0].charAt(0);return{type:`text`,raw:e,text:e}}return xN(n,e,n[0],this.lexer,this.rules)}}emStrong(e,t,n=``){let r=this.rules.inline.emStrongLDelim.exec(e);if(!(!r||!r[1]&&!r[2]&&!r[3]&&!r[4]||r[4]&&n.match(this.rules.other.unicodeAlphaNumeric))&&(!(r[1]||r[3])||!n||this.rules.inline.punctuation.exec(n))){let n=[...r[0]].length-1,i,a,o=n,s=0,c=r[0][0]===`*`?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(c.lastIndex=0,t=t.slice(-1*e.length+n);(r=c.exec(t))!==null;){if(i=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!i)continue;if(a=[...i].length,r[3]||r[4]){o+=a;continue}else if((r[5]||r[6])&&n%3&&!((n+a)%3)){s+=a;continue}if(o-=a,o>0)continue;a=Math.min(a,a+o+s);let t=[...r[0]][0].length,c=e.slice(0,n+r.index+t+a);if(Math.min(n,a)%2){let e=c.slice(1,-1);return{type:`em`,raw:c,text:e,tokens:this.lexer.inlineTokens(e)}}let l=c.slice(2,-2);return{type:`strong`,raw:c,text:l,tokens:this.lexer.inlineTokens(l)}}}}codespan(e){let t=this.rules.inline.code.exec(e);if(t){let e=t[2].replace(this.rules.other.newLineCharGlobal,` `),n=this.rules.other.nonSpaceChar.test(e),r=this.rules.other.startingSpaceChar.test(e)&&this.rules.other.endingSpaceChar.test(e);return n&&r&&(e=e.substring(1,e.length-1)),{type:`codespan`,raw:t[0],text:e}}}br(e){let t=this.rules.inline.br.exec(e);if(t)return{type:`br`,raw:t[0]}}del(e,t,n=``){let r=this.rules.inline.delLDelim.exec(e);if(r&&(!r[1]||!n||this.rules.inline.punctuation.exec(n))){let n=[...r[0]].length-1,i,a,o=n,s=this.rules.inline.delRDelim;for(s.lastIndex=0,t=t.slice(-1*e.length+n);(r=s.exec(t))!==null;){if(i=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!i||(a=[...i].length,a!==n))continue;if(r[3]||r[4]){o+=a;continue}if(o-=a,o>0)continue;a=Math.min(a,a+o);let t=[...r[0]][0].length,s=e.slice(0,n+r.index+t+a),c=s.slice(n,-n);return{type:`del`,raw:s,text:c,tokens:this.lexer.inlineTokens(c)}}}}autolink(e){let t=this.rules.inline.autolink.exec(e);if(t){let e,n;return t[2]===`@`?(e=t[1],n=`mailto:`+e):(e=t[1],n=e),{type:`link`,raw:t[0],text:e,href:n,tokens:[{type:`text`,raw:e,text:e}]}}}url(e){let t;if(t=this.rules.inline.url.exec(e)){let e,n;if(t[2]===`@`)e=t[0],n=`mailto:`+e;else{let r;do r=t[0],t[0]=this.rules.inline._backpedal.exec(t[0])?.[0]??``;while(r!==t[0]);e=t[0],n=t[1]===`www.`?`http://`+t[0]:t[0]}return{type:`link`,raw:t[0],text:e,href:n,tokens:[{type:`text`,raw:e,text:e}]}}}inlineText(e){let t=this.rules.inline.text.exec(e);if(t){let e=this.lexer.state.inRawBlock;return{type:`text`,raw:t[0],text:t[0],escaped:e}}}},wN=class e{tokens;options;state;inlineQueue;tokenizer;constructor(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||nM,this.options.tokenizer=this.options.tokenizer||new CN,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let t={other:sM,block:dN.normal,inline:fN.normal};this.options.pedantic?(t.block=dN.pedantic,t.inline=fN.pedantic):this.options.gfm&&(t.block=dN.gfm,this.options.breaks?t.inline=fN.breaks:t.inline=fN.gfm),this.tokenizer.rules=t}static get rules(){return{block:dN,inline:fN}}static lex(t,n){return new e(n).lex(t)}static lexInline(t,n){return new e(n).inlineTokens(t)}lex(e){e=e.replace(sM.carriageReturn,`
144
- `),this.blockTokens(e,this.tokens);for(let e=0;e<this.inlineQueue.length;e++){let t=this.inlineQueue[e];this.inlineTokens(t.src,t.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(e,t=[],n=!1){for(this.tokenizer.lexer=this,this.options.pedantic&&(e=e.replace(sM.tabCharGlobal,` `).replace(sM.spaceLine,``));e;){let r;if(this.options.extensions?.block?.some(n=>(r=n.call({lexer:this},e,t))?(e=e.substring(r.raw.length),t.push(r),!0):!1))continue;if(r=this.tokenizer.space(e)){e=e.substring(r.raw.length);let n=t.at(-1);r.raw.length===1&&n!==void 0?n.raw+=`
145
- `:t.push(r);continue}if(r=this.tokenizer.code(e)){e=e.substring(r.raw.length);let n=t.at(-1);n?.type===`paragraph`||n?.type===`text`?(n.raw+=(n.raw.endsWith(`
146
- `)?``:`
147
- `)+r.raw,n.text+=`
148
- `+r.text,this.inlineQueue.at(-1).src=n.text):t.push(r);continue}if(r=this.tokenizer.fences(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.heading(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.hr(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.blockquote(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.list(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.html(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.def(e)){e=e.substring(r.raw.length);let n=t.at(-1);n?.type===`paragraph`||n?.type===`text`?(n.raw+=(n.raw.endsWith(`
149
- `)?``:`
150
- `)+r.raw,n.text+=`
151
- `+r.raw,this.inlineQueue.at(-1).src=n.text):this.tokens.links[r.tag]||(this.tokens.links[r.tag]={href:r.href,title:r.title},t.push(r));continue}if(r=this.tokenizer.table(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.lheading(e)){e=e.substring(r.raw.length),t.push(r);continue}let i=e;if(this.options.extensions?.startBlock){let t=1/0,n=e.slice(1),r;this.options.extensions.startBlock.forEach(e=>{r=e.call({lexer:this},n),typeof r==`number`&&r>=0&&(t=Math.min(t,r))}),t<1/0&&t>=0&&(i=e.substring(0,t+1))}if(this.state.top&&(r=this.tokenizer.paragraph(i))){let a=t.at(-1);n&&a?.type===`paragraph`?(a.raw+=(a.raw.endsWith(`
152
- `)?``:`
153
- `)+r.raw,a.text+=`
154
- `+r.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=a.text):t.push(r),n=i.length!==e.length,e=e.substring(r.raw.length);continue}if(r=this.tokenizer.text(e)){e=e.substring(r.raw.length);let n=t.at(-1);n?.type===`text`?(n.raw+=(n.raw.endsWith(`
155
- `)?``:`
156
- `)+r.raw,n.text+=`
157
- `+r.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=n.text):t.push(r);continue}if(e){let t=`Infinite loop on byte: `+e.charCodeAt(0);if(this.options.silent){console.error(t);break}else throw Error(t)}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}inlineTokens(e,t=[]){this.tokenizer.lexer=this;let n=e,r=null;if(this.tokens.links){let e=Object.keys(this.tokens.links);if(e.length>0)for(;(r=this.tokenizer.rules.inline.reflinkSearch.exec(n))!==null;)e.includes(r[0].slice(r[0].lastIndexOf(`[`)+1,-1))&&(n=n.slice(0,r.index)+`[`+`a`.repeat(r[0].length-2)+`]`+n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(r=this.tokenizer.rules.inline.anyPunctuation.exec(n))!==null;)n=n.slice(0,r.index)+`++`+n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);let i;for(;(r=this.tokenizer.rules.inline.blockSkip.exec(n))!==null;)i=r[2]?r[2].length:0,n=n.slice(0,r.index+i)+`[`+`a`.repeat(r[0].length-i-2)+`]`+n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);n=this.options.hooks?.emStrongMask?.call({lexer:this},n)??n;let a=!1,o=``;for(;e;){a||(o=``),a=!1;let r;if(this.options.extensions?.inline?.some(n=>(r=n.call({lexer:this},e,t))?(e=e.substring(r.raw.length),t.push(r),!0):!1))continue;if(r=this.tokenizer.escape(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.tag(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.link(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(r.raw.length);let n=t.at(-1);r.type===`text`&&n?.type===`text`?(n.raw+=r.raw,n.text+=r.text):t.push(r);continue}if(r=this.tokenizer.emStrong(e,n,o)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.codespan(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.br(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.del(e,n,o)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.autolink(e)){e=e.substring(r.raw.length),t.push(r);continue}if(!this.state.inLink&&(r=this.tokenizer.url(e))){e=e.substring(r.raw.length),t.push(r);continue}let i=e;if(this.options.extensions?.startInline){let t=1/0,n=e.slice(1),r;this.options.extensions.startInline.forEach(e=>{r=e.call({lexer:this},n),typeof r==`number`&&r>=0&&(t=Math.min(t,r))}),t<1/0&&t>=0&&(i=e.substring(0,t+1))}if(r=this.tokenizer.inlineText(i)){e=e.substring(r.raw.length),r.raw.slice(-1)!==`_`&&(o=r.raw.slice(-1)),a=!0;let n=t.at(-1);n?.type===`text`?(n.raw+=r.raw,n.text+=r.text):t.push(r);continue}if(e){let t=`Infinite loop on byte: `+e.charCodeAt(0);if(this.options.silent){console.error(t);break}else throw Error(t)}}return t}},TN=class{options;parser;constructor(e){this.options=e||nM}space(e){return``}code({text:e,lang:t,escaped:n}){let r=(t||``).match(sM.notSpaceStart)?.[0],i=e.replace(sM.endingNewline,``)+`
158
- `;return r?`<pre><code class="language-`+hN(r)+`">`+(n?i:hN(i,!0))+`</code></pre>
159
- `:`<pre><code>`+(n?i:hN(i,!0))+`</code></pre>
160
- `}blockquote({tokens:e}){return`<blockquote>
161
- ${this.parser.parse(e)}</blockquote>
162
- `}html({text:e}){return e}def(e){return``}heading({tokens:e,depth:t}){return`<h${t}>${this.parser.parseInline(e)}</h${t}>
163
- `}hr(e){return`<hr>
164
- `}list(e){let t=e.ordered,n=e.start,r=``;for(let t=0;t<e.items.length;t++){let n=e.items[t];r+=this.listitem(n)}let i=t?`ol`:`ul`,a=t&&n!==1?` start="`+n+`"`:``;return`<`+i+a+`>
165
- `+r+`</`+i+`>
166
- `}listitem(e){return`<li>${this.parser.parse(e.tokens)}</li>
167
- `}checkbox({checked:e}){return`<input `+(e?`checked="" `:``)+`disabled="" type="checkbox"> `}paragraph({tokens:e}){return`<p>${this.parser.parseInline(e)}</p>
168
- `}table(e){let t=``,n=``;for(let t=0;t<e.header.length;t++)n+=this.tablecell(e.header[t]);t+=this.tablerow({text:n});let r=``;for(let t=0;t<e.rows.length;t++){let i=e.rows[t];n=``;for(let e=0;e<i.length;e++)n+=this.tablecell(i[e]);r+=this.tablerow({text:n})}return r&&=`<tbody>${r}</tbody>`,`<table>
169
- <thead>
170
- `+t+`</thead>
171
- `+r+`</table>
172
- `}tablerow({text:e}){return`<tr>
173
- ${e}</tr>
174
- `}tablecell(e){let t=this.parser.parseInline(e.tokens),n=e.header?`th`:`td`;return(e.align?`<${n} align="${e.align}">`:`<${n}>`)+t+`</${n}>
175
- `}strong({tokens:e}){return`<strong>${this.parser.parseInline(e)}</strong>`}em({tokens:e}){return`<em>${this.parser.parseInline(e)}</em>`}codespan({text:e}){return`<code>${hN(e,!0)}</code>`}br(e){return`<br>`}del({tokens:e}){return`<del>${this.parser.parseInline(e)}</del>`}link({href:e,title:t,tokens:n}){let r=this.parser.parseInline(n),i=gN(e);if(i===null)return r;e=i;let a=`<a href="`+e+`"`;return t&&(a+=` title="`+hN(t)+`"`),a+=`>`+r+`</a>`,a}image({href:e,title:t,text:n,tokens:r}){r&&(n=this.parser.parseInline(r,this.parser.textRenderer));let i=gN(e);if(i===null)return hN(n);e=i;let a=`<img src="${e}" alt="${hN(n)}"`;return t&&(a+=` title="${hN(t)}"`),a+=`>`,a}text(e){return`tokens`in e&&e.tokens?this.parser.parseInline(e.tokens):`escaped`in e&&e.escaped?e.text:hN(e.text)}},EN=class{strong({text:e}){return e}em({text:e}){return e}codespan({text:e}){return e}del({text:e}){return e}html({text:e}){return e}text({text:e}){return e}link({text:e}){return``+e}image({text:e}){return``+e}br(){return``}checkbox({raw:e}){return e}},DN=class e{options;renderer;textRenderer;constructor(e){this.options=e||nM,this.options.renderer=this.options.renderer||new TN,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new EN}static parse(t,n){return new e(n).parse(t)}static parseInline(t,n){return new e(n).parseInline(t)}parse(e){this.renderer.parser=this;let t=``;for(let n=0;n<e.length;n++){let r=e[n];if(this.options.extensions?.renderers?.[r.type]){let e=r,n=this.options.extensions.renderers[e.type].call({parser:this},e);if(n!==!1||![`space`,`hr`,`heading`,`code`,`table`,`blockquote`,`list`,`html`,`def`,`paragraph`,`text`].includes(e.type)){t+=n||``;continue}}let i=r;switch(i.type){case`space`:t+=this.renderer.space(i);break;case`hr`:t+=this.renderer.hr(i);break;case`heading`:t+=this.renderer.heading(i);break;case`code`:t+=this.renderer.code(i);break;case`table`:t+=this.renderer.table(i);break;case`blockquote`:t+=this.renderer.blockquote(i);break;case`list`:t+=this.renderer.list(i);break;case`checkbox`:t+=this.renderer.checkbox(i);break;case`html`:t+=this.renderer.html(i);break;case`def`:t+=this.renderer.def(i);break;case`paragraph`:t+=this.renderer.paragraph(i);break;case`text`:t+=this.renderer.text(i);break;default:{let e=`Token with "`+i.type+`" type was not found.`;if(this.options.silent)return console.error(e),``;throw Error(e)}}}return t}parseInline(e,t=this.renderer){this.renderer.parser=this;let n=``;for(let r=0;r<e.length;r++){let i=e[r];if(this.options.extensions?.renderers?.[i.type]){let e=this.options.extensions.renderers[i.type].call({parser:this},i);if(e!==!1||![`escape`,`html`,`link`,`image`,`strong`,`em`,`codespan`,`br`,`del`,`text`].includes(i.type)){n+=e||``;continue}}let a=i;switch(a.type){case`escape`:n+=t.text(a);break;case`html`:n+=t.html(a);break;case`link`:n+=t.link(a);break;case`image`:n+=t.image(a);break;case`checkbox`:n+=t.checkbox(a);break;case`strong`:n+=t.strong(a);break;case`em`:n+=t.em(a);break;case`codespan`:n+=t.codespan(a);break;case`br`:n+=t.br(a);break;case`del`:n+=t.del(a);break;case`text`:n+=t.text(a);break;default:{let e=`Token with "`+a.type+`" type was not found.`;if(this.options.silent)return console.error(e),``;throw Error(e)}}}return n}},ON=class{options;block;constructor(e){this.options=e||nM}static passThroughHooks=new Set([`preprocess`,`postprocess`,`processAllTokens`,`emStrongMask`]);static passThroughHooksRespectAsync=new Set([`preprocess`,`postprocess`,`processAllTokens`]);preprocess(e){return e}postprocess(e){return e}processAllTokens(e){return e}emStrongMask(e){return e}provideLexer(e=this.block){return e?wN.lex:wN.lexInline}provideParser(e=this.block){return e?DN.parse:DN.parseInline}},kN=new class{defaults=tM();options=this.setOptions;parse=this.parseMarkdown(!0);parseInline=this.parseMarkdown(!1);Parser=DN;Renderer=TN;TextRenderer=EN;Lexer=wN;Tokenizer=CN;Hooks=ON;constructor(...e){this.use(...e)}walkTokens(e,t){let n=[];for(let r of e)switch(n=n.concat(t.call(this,r)),r.type){case`table`:{let e=r;for(let r of e.header)n=n.concat(this.walkTokens(r.tokens,t));for(let r of e.rows)for(let e of r)n=n.concat(this.walkTokens(e.tokens,t));break}case`list`:{let e=r;n=n.concat(this.walkTokens(e.items,t));break}default:{let e=r;this.defaults.extensions?.childTokens?.[e.type]?this.defaults.extensions.childTokens[e.type].forEach(r=>{let i=e[r].flat(1/0);n=n.concat(this.walkTokens(i,t))}):e.tokens&&(n=n.concat(this.walkTokens(e.tokens,t)))}}return n}use(...e){let t=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(e=>{let n={...e};if(n.async=this.defaults.async||n.async||!1,e.extensions&&(e.extensions.forEach(e=>{if(!e.name)throw Error(`extension name required`);if(`renderer`in e){let n=t.renderers[e.name];n?t.renderers[e.name]=function(...t){let r=e.renderer.apply(this,t);return r===!1&&(r=n.apply(this,t)),r}:t.renderers[e.name]=e.renderer}if(`tokenizer`in e){if(!e.level||e.level!==`block`&&e.level!==`inline`)throw Error(`extension level must be 'block' or 'inline'`);let n=t[e.level];n?n.unshift(e.tokenizer):t[e.level]=[e.tokenizer],e.start&&(e.level===`block`?t.startBlock?t.startBlock.push(e.start):t.startBlock=[e.start]:e.level===`inline`&&(t.startInline?t.startInline.push(e.start):t.startInline=[e.start]))}`childTokens`in e&&e.childTokens&&(t.childTokens[e.name]=e.childTokens)}),n.extensions=t),e.renderer){let t=this.defaults.renderer||new TN(this.defaults);for(let n in e.renderer){if(!(n in t))throw Error(`renderer '${n}' does not exist`);if([`options`,`parser`].includes(n))continue;let r=n,i=e.renderer[r],a=t[r];t[r]=(...e)=>{let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n||``}}n.renderer=t}if(e.tokenizer){let t=this.defaults.tokenizer||new CN(this.defaults);for(let n in e.tokenizer){if(!(n in t))throw Error(`tokenizer '${n}' does not exist`);if([`options`,`rules`,`lexer`].includes(n))continue;let r=n,i=e.tokenizer[r],a=t[r];t[r]=(...e)=>{let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n}}n.tokenizer=t}if(e.hooks){let t=this.defaults.hooks||new ON;for(let n in e.hooks){if(!(n in t))throw Error(`hook '${n}' does not exist`);if([`options`,`block`].includes(n))continue;let r=n,i=e.hooks[r],a=t[r];ON.passThroughHooks.has(n)?t[r]=e=>{if(this.defaults.async&&ON.passThroughHooksRespectAsync.has(n))return(async()=>{let n=await i.call(t,e);return a.call(t,n)})();let r=i.call(t,e);return a.call(t,r)}:t[r]=(...e)=>{if(this.defaults.async)return(async()=>{let n=await i.apply(t,e);return n===!1&&(n=await a.apply(t,e)),n})();let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n}}n.hooks=t}if(e.walkTokens){let t=this.defaults.walkTokens,r=e.walkTokens;n.walkTokens=function(e){let n=[];return n.push(r.call(this,e)),t&&(n=n.concat(t.call(this,e))),n}}this.defaults={...this.defaults,...n}}),this}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return wN.lex(e,t??this.defaults)}parser(e,t){return DN.parse(e,t??this.defaults)}parseMarkdown(e){return(t,n)=>{let r={...n},i={...this.defaults,...r},a=this.onError(!!i.silent,!!i.async);if(this.defaults.async===!0&&r.async===!1)return a(Error(`marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise.`));if(typeof t>`u`||t===null)return a(Error(`marked(): input parameter is undefined or null`));if(typeof t!=`string`)return a(Error(`marked(): input parameter is of type `+Object.prototype.toString.call(t)+`, string expected`));if(i.hooks&&(i.hooks.options=i,i.hooks.block=e),i.async)return(async()=>{let n=i.hooks?await i.hooks.preprocess(t):t,r=await(i.hooks?await i.hooks.provideLexer(e):e?wN.lex:wN.lexInline)(n,i),a=i.hooks?await i.hooks.processAllTokens(r):r;i.walkTokens&&await Promise.all(this.walkTokens(a,i.walkTokens));let o=await(i.hooks?await i.hooks.provideParser(e):e?DN.parse:DN.parseInline)(a,i);return i.hooks?await i.hooks.postprocess(o):o})().catch(a);try{i.hooks&&(t=i.hooks.preprocess(t));let n=(i.hooks?i.hooks.provideLexer(e):e?wN.lex:wN.lexInline)(t,i);i.hooks&&(n=i.hooks.processAllTokens(n)),i.walkTokens&&this.walkTokens(n,i.walkTokens);let r=(i.hooks?i.hooks.provideParser(e):e?DN.parse:DN.parseInline)(n,i);return i.hooks&&(r=i.hooks.postprocess(r)),r}catch(e){return a(e)}}}onError(e,t){return n=>{if(n.message+=`
176
- Please report this to https://github.com/markedjs/marked.`,e){let e=`<p>An error occurred:</p><pre>`+hN(n.message+``,!0)+`</pre>`;return t?Promise.resolve(e):e}if(t)return Promise.reject(n);throw n}}};function AN(e,t){return kN.parse(e,t)}AN.options=AN.setOptions=function(e){return kN.setOptions(e),AN.defaults=kN.defaults,rM(AN.defaults),AN},AN.getDefaults=tM,AN.defaults=nM,AN.use=function(...e){return kN.use(...e),AN.defaults=kN.defaults,rM(AN.defaults),AN},AN.walkTokens=function(e,t){return kN.walkTokens(e,t)},AN.parseInline=kN.parseInline,AN.Parser=DN,AN.parser=DN.parse,AN.Renderer=TN,AN.TextRenderer=EN,AN.Lexer=wN,AN.lexer=wN.lex,AN.Tokenizer=CN,AN.Hooks=ON,AN.parse=AN,AN.options,AN.setOptions,AN.use,AN.walkTokens,AN.parseInline,DN.parse,wN.lex;var jN=`modulepreload`,MN=function(e){return`/`+e},NN={},$=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}))))}r=o(t.map(t=>{if(t=MN(t,n),t in NN)return;NN[t]=!0;let r=t.endsWith(`.css`),i=r?`[rel="stylesheet"]`:``;if(n)for(let n=e.length-1;n>=0;n--){let i=e[n];if(i.href===t&&(!r||i.rel===`stylesheet`))return}else if(document.querySelector(`link[href="${t}"]${i}`))return;let o=document.createElement(`link`);if(o.rel=r?`stylesheet`:jN,r||(o.as=`script`),o.crossOrigin=``,o.href=t,a&&o.setAttribute(`nonce`,a),document.head.appendChild(o),r)return new Promise((e,n)=>{o.addEventListener(`load`,e),o.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)})},PN=300,FN=`300px`,IN=500;function LN(e={}){let{immediate:t=!1,debounceDelay:n=PN,rootMargin:r=FN,idleTimeout:i=IN}=e,[a,o]=(0,d.useState)(!1),s=(0,d.useRef)(null),c=(0,d.useRef)(null),l=(0,d.useRef)(null),u=(0,d.useMemo)(()=>e=>{let t=Date.now();return window.setTimeout(()=>{e({didTimeout:!1,timeRemaining:()=>Math.max(0,50-(Date.now()-t))})},1)},[]),f=(0,d.useMemo)(()=>typeof window<`u`&&window.requestIdleCallback?(e,t)=>window.requestIdleCallback(e,t):u,[u]),p=(0,d.useMemo)(()=>typeof window<`u`&&window.cancelIdleCallback?e=>window.cancelIdleCallback(e):e=>{clearTimeout(e)},[]);return(0,d.useEffect)(()=>{if(t){o(!0);return}let e=s.current;if(!e)return;c.current&&=(clearTimeout(c.current),null),l.current&&=(p(l.current),null);let a=()=>{c.current&&=(clearTimeout(c.current),null),l.current&&=(p(l.current),null)},u=e=>{l.current=f(t=>{t.timeRemaining()>0||t.didTimeout?(o(!0),e.disconnect()):l.current=f(()=>{o(!0),e.disconnect()},{timeout:i/2})},{timeout:i})},d=e=>{a(),c.current=window.setTimeout(()=>{var t;let n=e.takeRecords();(n.length===0||(t=n.at(-1)?.isIntersecting)!=null&&t)&&u(e)},n)},m=(e,t)=>{e.isIntersecting?d(t):a()},h=new IntersectionObserver(e=>{for(let t of e)m(t,h)},{rootMargin:r,threshold:0});return h.observe(e),()=>{c.current&&clearTimeout(c.current),l.current&&p(l.current),h.disconnect()}},[t,n,r,i,p,f]),{shouldRender:a,containerRef:s}}var RN=/\s/,zN=/^\s+$/,BN=new Set([`code`,`pre`,`svg`,`math`,`annotation`]),VN=e=>typeof e==`object`&&!!e&&`type`in e&&e.type===`element`,HN=e=>e.some(e=>VN(e)&&BN.has(e.tagName)),UN=e=>{let t=[],n=``,r=!1;for(let i of e){let e=RN.test(i);e!==r&&n&&(t.push(n),n=``),n+=i,r=e}return n&&t.push(n),t},WN=e=>{let t=[],n=``;for(let r of e)RN.test(r)?n+=r:(n&&=(t.push(n),``),t.push(r));return n&&t.push(n),t},GN=(e,t,n,r,i,a)=>{let o=`--sd-animation:sd-${t};--sd-duration:${i?0:n}ms;--sd-easing:${r}`;return a&&(o+=`;--sd-delay:${a}ms`),{type:`element`,tagName:`span`,properties:{"data-sd-animate":!0,style:o},children:[{type:`text`,value:e}]}},KN=(e,t,n,r,i)=>{let a=t.at(-1);if(!(a&&`children`in a))return;if(HN(t))return ch;let o=a,s=o.children.indexOf(e);if(s===-1)return;let c=e.value;if(!c.trim()){i.count+=c.length;return}let l=n.sep===`char`?WN(c):UN(c),u=r.prevContentLength,d=l.map(e=>{let t=i.count;if(i.count+=e.length,zN.test(e))return{type:`text`,value:e};let r=u>0&&t<u,a=r?0:i.newIndex++*n.stagger;return GN(e,n.animation,n.duration,n.easing,r,a)});return o.children.splice(s,1,...d),s+d.length},qN=0;function JN(e){let t={animation:e?.animation??`fadeIn`,duration:e?.duration??150,easing:e?.easing??`ease`,sep:e?.sep??`word`,stagger:e?.stagger??40},n={prevContentLength:0,lastRenderCharCount:0},r=qN++,i=()=>e=>{let r={count:0,newIndex:0};lh(e,`text`,(e,i)=>KN(e,i,t,n,r)),n.lastRenderCharCount=r.count,n.prevContentLength=0};return Object.defineProperty(i,`name`,{value:`rehypeAnimate$${r}`}),{name:`animate`,type:`animate`,rehypePlugin:i,setPrevContentLength(e){n.prevContentLength=e},getLastRenderCharCount(){let e=n.lastRenderCharCount;return n.lastRenderCharCount=0,e}}}JN();var YN=(0,d.createContext)(!1),XN=()=>(0,d.useContext)(YN),ZN=(...e)=>pd(Ul(e)),QN=(e,t)=>{if(!e||!t)return t;let n=`${e}:`;return t.split(/\s+/).filter(Boolean).map(t=>t.startsWith(n)?t:`${e}:${t}`).join(` `)},$N=e=>e?(...t)=>QN(e,pd(Ul(t))):ZN,eP=(e,t,n)=>{let r=typeof t==`string`&&n.startsWith(`text/csv`)?``:``,i=typeof t==`string`?new Blob([r+t],{type:n}):t,a=URL.createObjectURL(i),o=document.createElement(`a`);o.href=a,o.download=e,document.body.appendChild(o),o.click(),document.body.removeChild(o),URL.revokeObjectURL(a)},tP=(0,d.createContext)(ZN),nP=()=>(0,d.useContext)(tP),rP=ZN(`block`,`before:content-[counter(line)]`,`before:inline-block`,`before:[counter-increment:line]`,`before:w-6`,`before:mr-4`,`before:text-[13px]`,`before:text-right`,`before:text-muted-foreground/50`,`before:font-mono`,`before:select-none`),iP=e=>{let t={};for(let n of e.split(`;`)){let e=n.indexOf(`:`);if(e>0){let r=n.slice(0,e).trim(),i=n.slice(e+1).trim();r&&i&&(t[r]=i)}}return t},aP=(0,d.memo)(({children:e,result:t,language:n,className:r,startLine:i,lineNumbers:a=!0,...o})=>{let s=nP(),c=(0,d.useMemo)(()=>s(rP),[s]),l=(0,d.useMemo)(()=>{let e={};return t.bg&&(e[`--sdm-bg`]=t.bg),t.fg&&(e[`--sdm-fg`]=t.fg),t.rootStyle&&Object.assign(e,iP(t.rootStyle)),e},[t.bg,t.fg,t.rootStyle]);return(0,_.jsx)(`div`,{className:s(r,`overflow-x-auto rounded-md border border-border bg-background p-4 text-sm`),"data-language":n,"data-streamdown":`code-block-body`,...o,children:(0,_.jsx)(`pre`,{className:s(r,`bg-[var(--sdm-bg,inherit]`,`dark:bg-[var(--shiki-dark-bg,var(--sdm-bg,inherit)]`),style:l,children:(0,_.jsx)(`code`,{className:a?s(`[counter-increment:line_0] [counter-reset:line]`):void 0,style:a&&i&&i>1?{counterReset:`line ${i-1}`}:void 0,children:t.tokens.map((e,t)=>(0,_.jsx)(`span`,{className:a?c:void 0,children:e.length===0||e.length===1&&e[0].content===``?`
177
- `:e.map((e,t)=>{let n={},r=!!e.bgColor;if(e.color&&(n[`--sdm-c`]=e.color),e.bgColor&&(n[`--sdm-tbg`]=e.bgColor),e.htmlStyle)for(let[t,i]of Object.entries(e.htmlStyle))t===`color`?n[`--sdm-c`]=i:t===`background-color`?(n[`--sdm-tbg`]=i,r=!0):n[t]=i;return(0,_.jsx)(`span`,{className:s(`text-[var(--sdm-c,inherit)]`,`dark:text-[var(--shiki-dark,var(--sdm-c,inherit))]`,r&&`bg-[var(--sdm-tbg)]`,r&&`dark:bg-[var(--shiki-dark-bg,var(--sdm-tbg))]`),style:n,...e.htmlAttrs,children:e.content},t)})},t))})})})},(e,t)=>e.result===t.result&&e.language===t.language&&e.className===t.className&&e.startLine===t.startLine&&e.lineNumbers===t.lineNumbers),oP=({className:e,language:t,style:n,isIncomplete:r,...i})=>(0,_.jsx)(`div`,{className:nP()(`my-4 flex w-full flex-col gap-2 rounded-xl border border-border bg-sidebar p-2`,e),"data-incomplete":r||void 0,"data-language":t,"data-streamdown":`code-block`,style:{contentVisibility:`auto`,containIntrinsicSize:`auto 200px`,...n},...i}),sP=(0,d.createContext)({code:``}),cP=()=>(0,d.useContext)(sP),lP=({language:e})=>{let t=nP();return(0,_.jsx)(`div`,{className:t(`flex h-8 items-center text-muted-foreground text-xs`),"data-language":e,"data-streamdown":`code-block-header`,children:(0,_.jsx)(`span`,{className:t(`ml-1 font-mono lowercase`),children:e})})},uP=e=>{let t=e.length;for(;t>0&&e[t-1]===`
178
- `;)t--;return e.slice(0,t)},dP=(0,d.lazy)(()=>$(()=>import(`./highlighted-body-OFNGDK62-DaefZcrn.js`).then(e=>({default:e.HighlightedCodeBlockBody})),__vite__mapDeps([0,1]))),fP=({code:e,language:t,className:n,children:r,isIncomplete:i=!1,startLine:a,lineNumbers:o,...s})=>{let c=nP(),l=(0,d.useMemo)(()=>uP(e),[e]),u=(0,d.useMemo)(()=>({bg:`transparent`,fg:`inherit`,tokens:l.split(`
179
- `).map(e=>[{content:e,color:`inherit`,bgColor:`transparent`,htmlStyle:{},offset:0}])}),[l]);return(0,_.jsx)(sP.Provider,{value:{code:e},children:(0,_.jsxs)(oP,{isIncomplete:i,language:t,children:[(0,_.jsx)(lP,{language:t}),r?(0,_.jsx)(`div`,{className:c(`pointer-events-none sticky top-2 z-10 -mt-10 flex h-8 items-center justify-end`),children:(0,_.jsx)(`div`,{className:c(`pointer-events-auto flex shrink-0 items-center gap-2 rounded-md border border-sidebar bg-sidebar/80 px-1.5 py-1 supports-[backdrop-filter]:bg-sidebar/70 supports-[backdrop-filter]:backdrop-blur`),"data-streamdown":`code-block-actions`,children:r})}):null,(0,_.jsx)(d.Suspense,{fallback:(0,_.jsx)(aP,{className:n,language:t,lineNumbers:o,result:u,startLine:a,...s}),children:(0,_.jsx)(dP,{className:n,code:l,language:t,lineNumbers:o,raw:u,startLine:a,...s})})]})})},pP={CheckIcon:e=>(0,_.jsx)(`svg`,{color:`currentColor`,height:16,strokeLinejoin:`round`,viewBox:`0 0 16 16`,width:16,...e,children:(0,_.jsx)(`path`,{clipRule:`evenodd`,d:`M15.5607 3.99999L15.0303 4.53032L6.23744 13.3232C5.55403 14.0066 4.44599 14.0066 3.76257 13.3232L4.2929 12.7929L3.76257 13.3232L0.969676 10.5303L0.439346 9.99999L1.50001 8.93933L2.03034 9.46966L4.82323 12.2626C4.92086 12.3602 5.07915 12.3602 5.17678 12.2626L13.9697 3.46966L14.5 2.93933L15.5607 3.99999Z`,fill:`currentColor`,fillRule:`evenodd`})}),CopyIcon:e=>(0,_.jsx)(`svg`,{color:`currentColor`,height:16,strokeLinejoin:`round`,viewBox:`0 0 16 16`,width:16,...e,children:(0,_.jsx)(`path`,{clipRule:`evenodd`,d:`M2.75 0.5C1.7835 0.5 1 1.2835 1 2.25V9.75C1 10.7165 1.7835 11.5 2.75 11.5H3.75H4.5V10H3.75H2.75C2.61193 10 2.5 9.88807 2.5 9.75V2.25C2.5 2.11193 2.61193 2 2.75 2H8.25C8.38807 2 8.5 2.11193 8.5 2.25V3H10V2.25C10 1.2835 9.2165 0.5 8.25 0.5H2.75ZM7.75 4.5C6.7835 4.5 6 5.2835 6 6.25V13.75C6 14.7165 6.7835 15.5 7.75 15.5H13.25C14.2165 15.5 15 14.7165 15 13.75V6.25C15 5.2835 14.2165 4.5 13.25 4.5H7.75ZM7.5 6.25C7.5 6.11193 7.61193 6 7.75 6H13.25C13.3881 6 13.5 6.11193 13.5 6.25V13.75C13.5 13.8881 13.3881 14 13.25 14H7.75C7.61193 14 7.5 13.8881 7.5 13.75V6.25Z`,fill:`currentColor`,fillRule:`evenodd`})}),DownloadIcon:e=>(0,_.jsx)(`svg`,{color:`currentColor`,height:16,strokeLinejoin:`round`,viewBox:`0 0 16 16`,width:16,...e,children:(0,_.jsx)(`path`,{clipRule:`evenodd`,d:`M8.75 1V1.75V8.68934L10.7197 6.71967L11.25 6.18934L12.3107 7.25L11.7803 7.78033L8.70711 10.8536C8.31658 11.2441 7.68342 11.2441 7.29289 10.8536L4.21967 7.78033L3.68934 7.25L4.75 6.18934L5.28033 6.71967L7.25 8.68934V1.75V1H8.75ZM13.5 9.25V13.5H2.5V9.25V8.5H1V9.25V14C1 14.5523 1.44771 15 2 15H14C14.5523 15 15 14.5523 15 14V9.25V8.5H13.5V9.25Z`,fill:`currentColor`,fillRule:`evenodd`})}),ExternalLinkIcon:e=>(0,_.jsx)(`svg`,{color:`currentColor`,height:16,strokeLinejoin:`round`,viewBox:`0 0 16 16`,width:16,...e,children:(0,_.jsx)(`path`,{clipRule:`evenodd`,d:`M13.5 10.25V13.25C13.5 13.3881 13.3881 13.5 13.25 13.5H2.75C2.61193 13.5 2.5 13.3881 2.5 13.25L2.5 2.75C2.5 2.61193 2.61193 2.5 2.75 2.5H5.75H6.5V1H5.75H2.75C1.7835 1 1 1.7835 1 2.75V13.25C1 14.2165 1.7835 15 2.75 15H13.25C14.2165 15 15 14.2165 15 13.25V10.25V9.5H13.5V10.25ZM9 1H9.75H14.2495C14.6637 1 14.9995 1.33579 14.9995 1.75V6.25V7H13.4995V6.25V3.56066L8.53033 8.52978L8 9.06011L6.93934 7.99945L7.46967 7.46912L12.4388 2.5H9.75H9V1Z`,fill:`currentColor`,fillRule:`evenodd`})}),Loader2Icon:e=>(0,_.jsxs)(`svg`,{color:`currentColor`,height:16,strokeLinejoin:`round`,viewBox:`0 0 16 16`,width:16,...e,children:[(0,_.jsx)(`path`,{d:`M8 0V4`,stroke:`currentColor`,strokeWidth:`1.5`}),(0,_.jsx)(`path`,{d:`M8 16V12`,opacity:`0.5`,stroke:`currentColor`,strokeWidth:`1.5`}),(0,_.jsx)(`path`,{d:`M3.29773 1.52783L5.64887 4.7639`,opacity:`0.9`,stroke:`currentColor`,strokeWidth:`1.5`}),(0,_.jsx)(`path`,{d:`M12.7023 1.52783L10.3511 4.7639`,opacity:`0.1`,stroke:`currentColor`,strokeWidth:`1.5`}),(0,_.jsx)(`path`,{d:`M12.7023 14.472L10.3511 11.236`,opacity:`0.4`,stroke:`currentColor`,strokeWidth:`1.5`}),(0,_.jsx)(`path`,{d:`M3.29773 14.472L5.64887 11.236`,opacity:`0.6`,stroke:`currentColor`,strokeWidth:`1.5`}),(0,_.jsx)(`path`,{d:`M15.6085 5.52783L11.8043 6.7639`,opacity:`0.2`,stroke:`currentColor`,strokeWidth:`1.5`}),(0,_.jsx)(`path`,{d:`M0.391602 10.472L4.19583 9.23598`,opacity:`0.7`,stroke:`currentColor`,strokeWidth:`1.5`}),(0,_.jsx)(`path`,{d:`M15.6085 10.4722L11.8043 9.2361`,opacity:`0.3`,stroke:`currentColor`,strokeWidth:`1.5`}),(0,_.jsx)(`path`,{d:`M0.391602 5.52783L4.19583 6.7639`,opacity:`0.8`,stroke:`currentColor`,strokeWidth:`1.5`})]}),Maximize2Icon:e=>(0,_.jsx)(`svg`,{color:`currentColor`,height:16,strokeLinejoin:`round`,viewBox:`0 0 16 16`,width:16,...e,children:(0,_.jsx)(`path`,{clipRule:`evenodd`,d:`M1 5.25V6H2.5V5.25V2.5H5.25H6V1H5.25H2C1.44772 1 1 1.44772 1 2V5.25ZM5.25 14.9994H6V13.4994H5.25H2.5V10.7494V9.99939H1V10.7494V13.9994C1 14.5517 1.44772 14.9994 2 14.9994H5.25ZM15 10V10.75V14C15 14.5523 14.5523 15 14 15H10.75H10V13.5H10.75H13.5V10.75V10H15ZM10.75 1H10V2.5H10.75H13.5V5.25V6H15V5.25V2C15 1.44772 14.5523 1 14 1H10.75Z`,fill:`currentColor`,fillRule:`evenodd`})}),RotateCcwIcon:e=>(0,_.jsx)(`svg`,{color:`currentColor`,height:16,strokeLinejoin:`round`,viewBox:`0 0 16 16`,width:16,...e,children:(0,_.jsx)(`path`,{clipRule:`evenodd`,d:`M13.5 8C13.5 4.96643 11.0257 2.5 7.96452 2.5C5.42843 2.5 3.29365 4.19393 2.63724 6.5H5.25H6V8H5.25H0.75C0.335787 8 0 7.66421 0 7.25V2.75V2H1.5V2.75V5.23347C2.57851 2.74164 5.06835 1 7.96452 1C11.8461 1 15 4.13001 15 8C15 11.87 11.8461 15 7.96452 15C5.62368 15 3.54872 13.8617 2.27046 12.1122L1.828 11.5066L3.03915 10.6217L3.48161 11.2273C4.48831 12.6051 6.12055 13.5 7.96452 13.5C11.0257 13.5 13.5 11.0336 13.5 8Z`,fill:`currentColor`,fillRule:`evenodd`})}),XIcon:e=>(0,_.jsx)(`svg`,{color:`currentColor`,height:16,strokeLinejoin:`round`,viewBox:`0 0 16 16`,width:16,...e,children:(0,_.jsx)(`path`,{clipRule:`evenodd`,d:`M12.4697 13.5303L13 14.0607L14.0607 13L13.5303 12.4697L9.06065 7.99999L13.5303 3.53032L14.0607 2.99999L13 1.93933L12.4697 2.46966L7.99999 6.93933L3.53032 2.46966L2.99999 1.93933L1.93933 2.99999L2.46966 3.53032L6.93933 7.99999L2.46966 12.4697L1.93933 13L2.99999 14.0607L3.53032 13.5303L7.99999 9.06065L12.4697 13.5303Z`,fill:`currentColor`,fillRule:`evenodd`})}),ZoomInIcon:e=>(0,_.jsx)(`svg`,{color:`currentColor`,height:16,strokeLinejoin:`round`,viewBox:`0 0 16 16`,width:16,...e,children:(0,_.jsx)(`path`,{clipRule:`evenodd`,d:`M1.5 6.5C1.5 3.73858 3.73858 1.5 6.5 1.5C9.26142 1.5 11.5 3.73858 11.5 6.5C11.5 9.26142 9.26142 11.5 6.5 11.5C3.73858 11.5 1.5 9.26142 1.5 6.5ZM6.5 0C2.91015 0 0 2.91015 0 6.5C0 10.0899 2.91015 13 6.5 13C8.02469 13 9.42677 12.475 10.5353 11.596L13.9697 15.0303L14.5 15.5607L15.5607 14.5L15.0303 13.9697L11.596 10.5353C12.475 9.42677 13 8.02469 13 6.5C13 2.91015 10.0899 0 6.5 0ZM4.125 5.875H4.75H5.875V4.75V4.125H7.125V4.75V5.875H8.25H8.875V7.125H8.25H7.125V8.25V8.875H5.875V8.25V7.125H4.75H4.125V5.875Z`,fill:`currentColor`,fillRule:`evenodd`})}),ZoomOutIcon:e=>(0,_.jsx)(`svg`,{color:`currentColor`,height:16,strokeLinejoin:`round`,viewBox:`0 0 16 16`,width:16,...e,children:(0,_.jsx)(`path`,{clipRule:`evenodd`,d:`M1.5 6.5C1.5 3.73858 3.73858 1.5 6.5 1.5C9.26142 1.5 11.5 3.73858 11.5 6.5C11.5 9.26142 9.26142 11.5 6.5 11.5C3.73858 11.5 1.5 9.26142 1.5 6.5ZM6.5 0C2.91015 0 0 2.91015 0 6.5C0 10.0899 2.91015 13 6.5 13C8.02469 13 9.42677 12.475 10.5353 11.596L13.9697 15.0303L14.5 15.5607L15.5607 14.5L15.0303 13.9697L11.596 10.5353C12.475 9.42677 13 8.02469 13 6.5C13 2.91015 10.0899 0 6.5 0ZM4.125 5.875H4.75H8.25H8.875V7.125H8.25H4.75H4.125V5.875Z`,fill:`currentColor`,fillRule:`evenodd`})})},mP=(0,d.createContext)(pP),hP=(e,t)=>{if(e===t)return!0;if(!(e&&t))return e===t;let n=Object.keys(e),r=Object.keys(t);return n.length===r.length?n.every(n=>e[n]===t[n]):!1},gP=({icons:e,children:t})=>{let n=(0,d.useRef)(e),r=(0,d.useRef)(e?{...pP,...e}:pP);hP(n.current,e)||(n.current=e,r.current=e?{...pP,...e}:pP);let i=r.current;return(0,_.jsx)(mP.Provider,{value:i,children:t})},_P=()=>(0,d.useContext)(mP),vP={copyCode:`Copy Code`,downloadFile:`Download file`,downloadDiagram:`Download diagram`,downloadDiagramAsSvg:`Download diagram as SVG`,downloadDiagramAsPng:`Download diagram as PNG`,downloadDiagramAsMmd:`Download diagram as MMD`,viewFullscreen:`View fullscreen`,exitFullscreen:`Exit fullscreen`,mermaidFormatSvg:`SVG`,mermaidFormatPng:`PNG`,mermaidFormatMmd:`MMD`,copyTable:`Copy table`,copyTableAsMarkdown:`Copy table as Markdown`,copyTableAsCsv:`Copy table as CSV`,copyTableAsTsv:`Copy table as TSV`,downloadTable:`Download table`,downloadTableAsCsv:`Download table as CSV`,downloadTableAsMarkdown:`Download table as Markdown`,tableFormatMarkdown:`Markdown`,tableFormatCsv:`CSV`,tableFormatTsv:`TSV`,imageNotAvailable:`Image not available`,downloadImage:`Download image`,openExternalLink:`Open external link?`,externalLinkWarning:`You're about to visit an external website.`,close:`Close`,copyLink:`Copy link`,copied:`Copied`,openLink:`Open link`},yP=(0,d.createContext)(vP),bP=()=>(0,d.useContext)(yP),xP=({onCopy:e,onError:t,timeout:n=2e3,children:r,className:i,code:a,...o})=>{let s=nP(),[c,l]=(0,d.useState)(!1),u=(0,d.useRef)(0),{code:f}=cP(),{isAnimating:p}=(0,d.useContext)(DI),m=bP(),h=a??f,g=async()=>{var r;if(typeof window>`u`||!((r=navigator==null?void 0:navigator.clipboard)!=null&&r.writeText)){t?.(Error(`Clipboard API not available`));return}try{c||(await navigator.clipboard.writeText(h),l(!0),e?.(),u.current=window.setTimeout(()=>l(!1),n))}catch(e){t?.(e)}};(0,d.useEffect)(()=>()=>{window.clearTimeout(u.current)},[]);let v=_P(),y=c?v.CheckIcon:v.CopyIcon;return(0,_.jsx)(`button`,{className:s(`cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50`,i),"data-streamdown":`code-block-copy-button`,disabled:p,onClick:g,title:m.copyCode,type:`button`,...o,children:r??(0,_.jsx)(y,{size:14})})},SP={"1c":`1c`,"1c-query":`1cq`,abap:`abap`,"actionscript-3":`as`,ada:`ada`,adoc:`adoc`,"angular-html":`html`,"angular-ts":`ts`,apache:`conf`,apex:`cls`,apl:`apl`,applescript:`applescript`,ara:`ara`,asciidoc:`adoc`,asm:`asm`,astro:`astro`,awk:`awk`,ballerina:`bal`,bash:`sh`,bat:`bat`,batch:`bat`,be:`be`,beancount:`beancount`,berry:`berry`,bibtex:`bib`,bicep:`bicep`,blade:`blade.php`,bsl:`bsl`,c:`c`,"c#":`cs`,"c++":`cpp`,cadence:`cdc`,cairo:`cairo`,cdc:`cdc`,clarity:`clar`,clj:`clj`,clojure:`clj`,"closure-templates":`soy`,cmake:`cmake`,cmd:`cmd`,cobol:`cob`,codeowners:`CODEOWNERS`,codeql:`ql`,coffee:`coffee`,coffeescript:`coffee`,"common-lisp":`lisp`,console:`sh`,coq:`v`,cpp:`cpp`,cql:`cql`,crystal:`cr`,cs:`cs`,csharp:`cs`,css:`css`,csv:`csv`,cue:`cue`,cypher:`cql`,d:`d`,dart:`dart`,dax:`dax`,desktop:`desktop`,diff:`diff`,docker:`dockerfile`,dockerfile:`dockerfile`,dotenv:`env`,"dream-maker":`dm`,edge:`edge`,elisp:`el`,elixir:`ex`,elm:`elm`,"emacs-lisp":`el`,erb:`erb`,erl:`erl`,erlang:`erl`,f:`f`,"f#":`fs`,f03:`f03`,f08:`f08`,f18:`f18`,f77:`f77`,f90:`f90`,f95:`f95`,fennel:`fnl`,fish:`fish`,fluent:`ftl`,for:`for`,"fortran-fixed-form":`f`,"fortran-free-form":`f90`,fs:`fs`,fsharp:`fs`,fsl:`fsl`,ftl:`ftl`,gdresource:`tres`,gdscript:`gd`,gdshader:`gdshader`,genie:`gs`,gherkin:`feature`,"git-commit":`gitcommit`,"git-rebase":`gitrebase`,gjs:`js`,gleam:`gleam`,"glimmer-js":`js`,"glimmer-ts":`ts`,glsl:`glsl`,gnuplot:`plt`,go:`go`,gql:`gql`,graphql:`graphql`,groovy:`groovy`,gts:`gts`,hack:`hack`,haml:`haml`,handlebars:`hbs`,haskell:`hs`,haxe:`hx`,hbs:`hbs`,hcl:`hcl`,hjson:`hjson`,hlsl:`hlsl`,hs:`hs`,html:`html`,"html-derivative":`html`,http:`http`,hxml:`hxml`,hy:`hy`,imba:`imba`,ini:`ini`,jade:`jade`,java:`java`,javascript:`js`,jinja:`jinja`,jison:`jison`,jl:`jl`,js:`js`,json:`json`,json5:`json5`,jsonc:`jsonc`,jsonl:`jsonl`,jsonnet:`jsonnet`,jssm:`jssm`,jsx:`jsx`,julia:`jl`,kotlin:`kt`,kql:`kql`,kt:`kt`,kts:`kts`,kusto:`kql`,latex:`tex`,lean:`lean`,lean4:`lean`,less:`less`,liquid:`liquid`,lisp:`lisp`,lit:`lit`,llvm:`ll`,log:`log`,logo:`logo`,lua:`lua`,luau:`luau`,make:`mak`,makefile:`mak`,markdown:`md`,marko:`marko`,matlab:`m`,md:`md`,mdc:`mdc`,mdx:`mdx`,mediawiki:`wiki`,mermaid:`mmd`,mips:`s`,mipsasm:`s`,mmd:`mmd`,mojo:`mojo`,move:`move`,nar:`nar`,narrat:`narrat`,nextflow:`nf`,nf:`nf`,nginx:`conf`,nim:`nim`,nix:`nix`,nu:`nu`,nushell:`nu`,objc:`m`,"objective-c":`m`,"objective-cpp":`mm`,ocaml:`ml`,pascal:`pas`,perl:`pl`,perl6:`p6`,php:`php`,plsql:`pls`,po:`po`,polar:`polar`,postcss:`pcss`,pot:`pot`,potx:`potx`,powerquery:`pq`,powershell:`ps1`,prisma:`prisma`,prolog:`pl`,properties:`properties`,proto:`proto`,protobuf:`proto`,ps:`ps`,ps1:`ps1`,pug:`pug`,puppet:`pp`,purescript:`purs`,py:`py`,python:`py`,ql:`ql`,qml:`qml`,qmldir:`qmldir`,qss:`qss`,r:`r`,racket:`rkt`,raku:`raku`,razor:`cshtml`,rb:`rb`,reg:`reg`,regex:`regex`,regexp:`regexp`,rel:`rel`,riscv:`s`,rs:`rs`,rst:`rst`,ruby:`rb`,rust:`rs`,sas:`sas`,sass:`sass`,scala:`scala`,scheme:`scm`,scss:`scss`,sdbl:`sdbl`,sh:`sh`,shader:`shader`,shaderlab:`shader`,shell:`sh`,shellscript:`sh`,shellsession:`sh`,smalltalk:`st`,solidity:`sol`,soy:`soy`,sparql:`rq`,spl:`spl`,splunk:`spl`,sql:`sql`,"ssh-config":`config`,stata:`do`,styl:`styl`,stylus:`styl`,svelte:`svelte`,swift:`swift`,"system-verilog":`sv`,systemd:`service`,talon:`talon`,talonscript:`talon`,tasl:`tasl`,tcl:`tcl`,templ:`templ`,terraform:`tf`,tex:`tex`,tf:`tf`,tfvars:`tfvars`,toml:`toml`,ts:`ts`,"ts-tags":`ts`,tsp:`tsp`,tsv:`tsv`,tsx:`tsx`,turtle:`ttl`,twig:`twig`,typ:`typ`,typescript:`ts`,typespec:`tsp`,typst:`typ`,v:`v`,vala:`vala`,vb:`vb`,verilog:`v`,vhdl:`vhdl`,vim:`vim`,viml:`vim`,vimscript:`vim`,vue:`vue`,"vue-html":`html`,"vue-vine":`vine`,vy:`vy`,vyper:`vy`,wasm:`wasm`,wenyan:`wy`,wgsl:`wgsl`,wiki:`wiki`,wikitext:`wiki`,wit:`wit`,wl:`wl`,wolfram:`wl`,xml:`xml`,xsl:`xsl`,yaml:`yaml`,yml:`yml`,zenscript:`zs`,zig:`zig`,zsh:`zsh`,文言:`wy`},CP=({onDownload:e,onError:t,language:n,children:r,className:i,code:a,...o})=>{let s=nP(),{code:c}=cP(),{isAnimating:l}=(0,d.useContext)(DI),u=bP(),f=_P(),p=a??c,m=`file.${n&&n in SP?SP[n]:`txt`}`;return(0,_.jsx)(`button`,{className:s(`cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50`,i),"data-streamdown":`code-block-download-button`,disabled:l,onClick:()=>{try{eP(m,p,`text/plain`),e?.()}catch(e){t?.(e)}},title:u.downloadFile,type:`button`,...o,children:r??(0,_.jsx)(f.DownloadIcon,{size:14})})},wP=()=>{let{Loader2Icon:e}=_P(),t=nP();return(0,_.jsxs)(`div`,{className:t(`w-full divide-y divide-border overflow-hidden rounded-xl border border-border`),children:[(0,_.jsx)(`div`,{className:t(`h-[46px] w-full bg-muted/80`)}),(0,_.jsx)(`div`,{className:t(`flex w-full items-center justify-center p-4`),children:(0,_.jsx)(e,{className:t(`size-4 animate-spin`)})})]})},TP=/\.[^/.]+$/,EP=({node:e,className:t,src:n,alt:r,onLoad:i,onError:a,...o})=>{let{DownloadIcon:s}=_P(),c=nP(),l=(0,d.useRef)(null),[u,f]=(0,d.useState)(!1),[p,m]=(0,d.useState)(!1),h=bP(),g=o.width!=null||o.height!=null,v=(u||g)&&!p,y=p&&!g;(0,d.useEffect)(()=>{let e=l.current;if(e!=null&&e.complete){let t=e.naturalWidth>0;f(t),m(!t)}},[]);let b=(0,d.useCallback)(e=>{f(!0),m(!1),i?.(e)},[i]),x=(0,d.useCallback)(e=>{f(!1),m(!0),a?.(e)},[a]),S=async()=>{if(n)try{let e=await(await fetch(n)).blob(),t=new URL(n,window.location.origin).pathname.split(`/`).pop()||``,i=t.split(`.`).pop(),a=t.includes(`.`)&&i!==void 0&&i.length<=4,o=``;if(a)o=t;else{let n=e.type,i=`png`;n.includes(`jpeg`)||n.includes(`jpg`)?i=`jpg`:n.includes(`png`)?i=`png`:n.includes(`svg`)?i=`svg`:n.includes(`gif`)?i=`gif`:n.includes(`webp`)&&(i=`webp`),o=`${(r||t||`image`).replace(TP,``)}.${i}`}eP(o,e,e.type)}catch{window.open(n,`_blank`)}};return n?(0,_.jsxs)(`div`,{className:c(`group relative my-4 inline-block`),"data-streamdown":`image-wrapper`,children:[(0,_.jsx)(`img`,{alt:r,className:c(`max-w-full rounded-lg`,y&&`hidden`,t),"data-streamdown":`image`,onError:x,onLoad:b,ref:l,src:n,...o}),y&&(0,_.jsx)(`span`,{className:c(`text-muted-foreground text-xs italic`),"data-streamdown":`image-fallback`,children:h.imageNotAvailable}),(0,_.jsx)(`div`,{className:c(`pointer-events-none absolute inset-0 hidden rounded-lg bg-black/10 group-hover:block`)}),v&&(0,_.jsx)(`button`,{className:c(`absolute right-2 bottom-2 flex h-8 w-8 cursor-pointer items-center justify-center rounded-md border border-border bg-background/90 shadow-sm backdrop-blur-sm transition-all duration-200 hover:bg-background`,`opacity-0 group-hover:opacity-100`),onClick:S,title:h.downloadImage,type:`button`,children:(0,_.jsx)(s,{size:14})})]}):null},DP=0,OP=()=>{DP+=1,DP===1&&(document.body.style.overflow=`hidden`)},kP=()=>{DP=Math.max(0,DP-1),DP===0&&(document.body.style.overflow=``)},AP=({url:e,isOpen:t,onClose:n,onConfirm:r})=>{let{CheckIcon:i,CopyIcon:a,ExternalLinkIcon:o,XIcon:s}=_P(),c=nP(),[l,u]=(0,d.useState)(!1),f=bP(),p=(0,d.useCallback)(async()=>{try{await navigator.clipboard.writeText(e),u(!0),setTimeout(()=>u(!1),2e3)}catch{}},[e]),m=(0,d.useCallback)(()=>{r(),n()},[r,n]);return(0,d.useEffect)(()=>{if(t){OP();let e=e=>{e.key===`Escape`&&n()};return document.addEventListener(`keydown`,e),()=>{document.removeEventListener(`keydown`,e),kP()}}},[t,n]),t?(0,_.jsx)(`div`,{className:c(`fixed inset-0 z-50 flex items-center justify-center bg-background/50 backdrop-blur-sm`),"data-streamdown":`link-safety-modal`,onClick:n,onKeyDown:e=>{e.key===`Escape`&&n()},role:`button`,tabIndex:0,children:(0,_.jsxs)(`div`,{className:c(`relative mx-4 flex w-full max-w-md flex-col gap-4 rounded-xl border bg-background p-6 shadow-lg`),onClick:e=>e.stopPropagation(),onKeyDown:e=>e.stopPropagation(),role:`presentation`,children:[(0,_.jsx)(`button`,{className:c(`absolute top-4 right-4 rounded-md p-1 text-muted-foreground transition-all hover:bg-muted hover:text-foreground`),onClick:n,title:f.close,type:`button`,children:(0,_.jsx)(s,{size:16})}),(0,_.jsxs)(`div`,{className:c(`flex flex-col gap-2`),children:[(0,_.jsxs)(`div`,{className:c(`flex items-center gap-2 font-semibold text-lg`),children:[(0,_.jsx)(o,{size:20}),(0,_.jsx)(`span`,{children:f.openExternalLink})]}),(0,_.jsx)(`p`,{className:c(`text-muted-foreground text-sm`),children:f.externalLinkWarning})]}),(0,_.jsx)(`div`,{className:c(`break-all rounded-md bg-muted p-3 font-mono text-sm`,e.length>100&&`max-h-32 overflow-y-auto`),children:e}),(0,_.jsxs)(`div`,{className:c(`flex gap-2`),children:[(0,_.jsx)(`button`,{className:c(`flex flex-1 items-center justify-center gap-2 rounded-md border bg-background px-4 py-2 font-medium text-sm transition-all hover:bg-muted`),onClick:p,type:`button`,children:l?(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(i,{size:14}),(0,_.jsx)(`span`,{children:f.copied})]}):(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(a,{size:14}),(0,_.jsx)(`span`,{children:f.copyLink})]})}),(0,_.jsxs)(`button`,{className:c(`flex flex-1 items-center justify-center gap-2 rounded-md bg-primary px-4 py-2 font-medium text-primary-foreground text-sm transition-all hover:bg-primary/90`),onClick:m,type:`button`,children:[(0,_.jsx)(o,{size:14}),(0,_.jsx)(`span`,{children:f.openLink})]})]})]})}):null},jP=(0,d.createContext)(null),MP=()=>(0,d.useContext)(jP),NP=()=>MP()?.code??null,PP=()=>MP()?.mermaid??null,FP=e=>{var t;let n=MP();return n!=null&&n.renderers&&e&&(t=n.renderers.find(t=>Array.isArray(t.language)?t.language.includes(e):t.language===e))!=null?t:null},IP=(e,t)=>new Promise((t,n)=>{let r=`data:image/svg+xml;base64,`+btoa(unescape(encodeURIComponent(e))),i=new Image;i.crossOrigin=`anonymous`,i.onload=()=>{let e=document.createElement(`canvas`),r=i.width*5,a=i.height*5;e.width=r,e.height=a;let o=e.getContext(`2d`);if(!o){n(Error(`Failed to create 2D canvas context for PNG export`));return}o.drawImage(i,0,0,r,a),e.toBlob(e=>{if(!e){n(Error(`Failed to create PNG blob`));return}t(e)},`image/png`)},i.onerror=()=>n(Error(`Failed to load SVG image`)),i.src=r}),LP=({chart:e,children:t,className:n,onDownload:r,config:i,onError:a})=>{let o=nP(),[s,c]=(0,d.useState)(!1),l=(0,d.useRef)(null),{isAnimating:u}=(0,d.useContext)(DI),f=_P(),p=PP(),m=bP(),h=async t=>{try{if(t===`mmd`){eP(`diagram.mmd`,e,`text/plain`),c(!1),r?.(t);return}if(!p){a?.(Error(`Mermaid plugin not available`));return}let n=p.getMermaid(i),o=e.split(``).reduce((e,t)=>(e<<5)-e+t.charCodeAt(0)|0,0),s=`mermaid-${Math.abs(o)}-${Date.now()}-${Math.random().toString(36).substring(2,9)}`,{svg:l}=await n.render(s,e);if(!l){a?.(Error(`SVG not found. Please wait for the diagram to render.`));return}if(t===`svg`){eP(`diagram.svg`,l,`image/svg+xml`),c(!1),r?.(t);return}if(t===`png`){eP(`diagram.png`,await IP(l),`image/png`),r?.(t),c(!1);return}}catch(e){a?.(e)}};return(0,d.useEffect)(()=>{let e=e=>{let t=e.composedPath();l.current&&!t.includes(l.current)&&c(!1)};return document.addEventListener(`mousedown`,e),()=>{document.removeEventListener(`mousedown`,e)}},[]),(0,_.jsxs)(`div`,{className:o(`relative`),ref:l,children:[(0,_.jsx)(`button`,{className:o(`cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50`,n),disabled:u,onClick:()=>c(!s),title:m.downloadDiagram,type:`button`,children:t??(0,_.jsx)(f.DownloadIcon,{size:14})}),s?(0,_.jsxs)(`div`,{className:o(`absolute top-full right-0 z-10 mt-1 min-w-[120px] overflow-hidden rounded-md border border-border bg-background shadow-lg`),children:[(0,_.jsx)(`button`,{className:o(`w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40`),onClick:()=>h(`svg`),title:m.downloadDiagramAsSvg,type:`button`,children:m.mermaidFormatSvg}),(0,_.jsx)(`button`,{className:o(`w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40`),onClick:()=>h(`png`),title:m.downloadDiagramAsPng,type:`button`,children:m.mermaidFormatPng}),(0,_.jsx)(`button`,{className:o(`w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40`),onClick:()=>h(`mmd`),title:m.downloadDiagramAsMmd,type:`button`,children:m.mermaidFormatMmd})]}):null]})},RP=({chart:e,config:t,onFullscreen:n,onExit:r,className:i,...a})=>{let{Maximize2Icon:o,XIcon:s}=_P(),c=nP(),[l,u]=(0,d.useState)(!1),{isAnimating:f,controls:p}=(0,d.useContext)(DI),m=bP(),h=(()=>{if(typeof p==`boolean`)return p;let e=p.mermaid;return e===!1?!1:e===!0||e===void 0?!0:e.panZoom!==!1})(),g=()=>{u(!l)};return(0,d.useEffect)(()=>{if(l){OP();let e=e=>{e.key===`Escape`&&u(!1)};return document.addEventListener(`keydown`,e),()=>{document.removeEventListener(`keydown`,e),kP()}}},[l]),(0,d.useEffect)(()=>{l?n?.():r&&r()},[l,n,r]),(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(`button`,{className:c(`cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50`,i),disabled:f,onClick:g,title:m.viewFullscreen,type:`button`,...a,children:(0,_.jsx)(o,{size:14})}),l?(0,E.createPortal)((0,_.jsxs)(`div`,{className:c(`fixed inset-0 z-50 flex items-center justify-center bg-background/95 backdrop-blur-sm`),onClick:g,onKeyDown:e=>{e.key===`Escape`&&g()},role:`button`,tabIndex:0,children:[(0,_.jsx)(`button`,{className:c(`absolute top-4 right-4 z-10 rounded-md p-2 text-muted-foreground transition-all hover:bg-muted hover:text-foreground`),onClick:g,title:m.exitFullscreen,type:`button`,children:(0,_.jsx)(s,{size:20})}),(0,_.jsx)(`div`,{className:c(`flex size-full items-center justify-center p-4`),onClick:e=>e.stopPropagation(),onKeyDown:e=>e.stopPropagation(),role:`presentation`,children:(0,_.jsx)(jI,{chart:e,className:c(`size-full [&_svg]:h-auto [&_svg]:w-auto`),config:t,fullscreen:!0,showControls:h})})]}),document.body):null]})},zP=e=>{let t=[],n=[],r=e.querySelectorAll(`thead th`);for(let e of r)t.push(e.textContent?.trim()||``);let i=e.querySelectorAll(`tbody tr`);for(let e of i){let t=[],r=e.querySelectorAll(`td`);for(let e of r)t.push(e.textContent?.trim()||``);n.push(t)}return{headers:t,rows:n}},BP=e=>{let{headers:t,rows:n}=e,r=e=>{let t=!1,n=!1;for(let r of e){if(r===`"`){t=!0,n=!0;break}(r===`,`||r===`
180
- `)&&(t=!0)}return t?n?`"${e.replace(/"/g,`""`)}"`:`"${e}"`:e},i=t.length>0?n.length+1:n.length,a=Array(i),o=0;t.length>0&&(a[o]=t.map(r).join(`,`),o+=1);for(let e of n)a[o]=e.map(r).join(`,`),o+=1;return a.join(`
181
- `)},VP=e=>{let{headers:t,rows:n}=e,r=e=>{let t=!1;for(let n of e)if(n===` `||n===`
182
- `||n===`\r`){t=!0;break}if(!t)return e;let n=[];for(let t of e)t===` `?n.push(`\\t`):t===`
183
- `?n.push(`\\n`):t===`\r`?n.push(`\\r`):n.push(t);return n.join(``)},i=t.length>0?n.length+1:n.length,a=Array(i),o=0;t.length>0&&(a[o]=t.map(r).join(` `),o+=1);for(let e of n)a[o]=e.map(r).join(` `),o+=1;return a.join(`
184
- `)},HP=e=>{let t=!1;for(let n of e)if(n===`\\`||n===`|`){t=!0;break}if(!t)return e;let n=[];for(let t of e)t===`\\`?n.push(`\\\\`):t===`|`?n.push(`\\|`):n.push(t);return n.join(``)},UP=e=>{let{headers:t,rows:n}=e;if(t.length===0)return``;let r=Array(n.length+2),i=0;r[i]=`| ${t.map(e=>HP(e)).join(` | `)} |`,i+=1;let a=Array(t.length);for(let e=0;e<t.length;e+=1)a[e]=`---`;r[i]=`| ${a.join(` | `)} |`,i+=1;for(let e of n)if(e.length<t.length){let n=Array(t.length);for(let r=0;r<t.length;r+=1)n[r]=r<e.length?HP(e[r]):``;r[i]=`| ${n.join(` | `)} |`,i+=1}else r[i]=`| ${e.map(e=>HP(e)).join(` | `)} |`,i+=1;return r.join(`
185
- `)},WP=({children:e,className:t,onCopy:n,onError:r,timeout:i=2e3})=>{let a=nP(),[o,s]=(0,d.useState)(!1),[c,l]=(0,d.useState)(!1),u=(0,d.useRef)(null),f=(0,d.useRef)(0),{isAnimating:p}=(0,d.useContext)(DI),m=bP(),h=async e=>{var t;if(typeof window>`u`||!((t=navigator==null?void 0:navigator.clipboard)!=null&&t.write)){r?.(Error(`Clipboard API not available`));return}try{let t=(u.current?.closest(`[data-streamdown="table-wrapper"]`))?.querySelector(`table`);if(!t){r?.(Error(`Table not found`));return}let a=zP(t),o=({csv:BP,tsv:VP,md:UP}[e]||UP)(a),c=new ClipboardItem({"text/plain":new Blob([o],{type:`text/plain`}),"text/html":new Blob([t.outerHTML],{type:`text/html`})});await navigator.clipboard.write([c]),l(!0),s(!1),n?.(e),f.current=window.setTimeout(()=>l(!1),i)}catch(e){r?.(e)}};(0,d.useEffect)(()=>{let e=e=>{let t=e.composedPath();u.current&&!t.includes(u.current)&&s(!1)};return document.addEventListener(`mousedown`,e),()=>{document.removeEventListener(`mousedown`,e),window.clearTimeout(f.current)}},[]);let g=_P(),v=c?g.CheckIcon:g.CopyIcon;return(0,_.jsxs)(`div`,{className:a(`relative`),ref:u,children:[(0,_.jsx)(`button`,{className:a(`cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50`,t),disabled:p,onClick:()=>s(!o),title:m.copyTable,type:`button`,children:e??(0,_.jsx)(v,{height:14,width:14})}),o?(0,_.jsxs)(`div`,{className:a(`absolute top-full right-0 z-20 mt-1 min-w-[120px] overflow-hidden rounded-md border border-border bg-background shadow-lg`),children:[(0,_.jsx)(`button`,{className:a(`w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40`),onClick:()=>h(`md`),title:m.copyTableAsMarkdown,type:`button`,children:m.tableFormatMarkdown}),(0,_.jsx)(`button`,{className:a(`w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40`),onClick:()=>h(`csv`),title:m.copyTableAsCsv,type:`button`,children:m.tableFormatCsv}),(0,_.jsx)(`button`,{className:a(`w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40`),onClick:()=>h(`tsv`),title:m.copyTableAsTsv,type:`button`,children:m.tableFormatTsv})]}):null]})},GP=({children:e,className:t,onDownload:n,onError:r})=>{let i=nP(),[a,o]=(0,d.useState)(!1),s=(0,d.useRef)(null),{isAnimating:c}=(0,d.useContext)(DI),l=bP(),u=_P(),f=e=>{try{let t=(s.current?.closest(`[data-streamdown="table-wrapper"]`))?.querySelector(`table`);if(!t){r?.(Error(`Table not found`));return}let i=zP(t),a=e===`csv`?BP(i):UP(i);eP(`table.${e===`csv`?`csv`:`md`}`,a,e===`csv`?`text/csv`:`text/markdown`),o(!1),n?.(e)}catch(e){r?.(e)}};return(0,d.useEffect)(()=>{let e=e=>{let t=e.composedPath();s.current&&!t.includes(s.current)&&o(!1)};return document.addEventListener(`mousedown`,e),()=>{document.removeEventListener(`mousedown`,e)}},[]),(0,_.jsxs)(`div`,{className:i(`relative`),ref:s,children:[(0,_.jsx)(`button`,{className:i(`cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50`,t),disabled:c,onClick:()=>o(!a),title:l.downloadTable,type:`button`,children:e??(0,_.jsx)(u.DownloadIcon,{size:14})}),a?(0,_.jsxs)(`div`,{className:i(`absolute top-full right-0 z-20 mt-1 min-w-[120px] overflow-hidden rounded-md border border-border bg-background shadow-lg`),children:[(0,_.jsx)(`button`,{className:i(`w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40`),onClick:()=>f(`csv`),title:l.downloadTableAsCsv,type:`button`,children:l.tableFormatCsv}),(0,_.jsx)(`button`,{className:i(`w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40`),onClick:()=>f(`markdown`),title:l.downloadTableAsMarkdown,type:`button`,children:l.tableFormatMarkdown})]}):null]})},KP=({children:e,className:t,showCopy:n=!0,showDownload:r=!0})=>{let{Maximize2Icon:i,XIcon:a}=_P(),o=nP(),[s,c]=(0,d.useState)(!1),{isAnimating:l}=(0,d.useContext)(DI),u=bP(),f=()=>{c(!0)},p=()=>{c(!1)};return(0,d.useEffect)(()=>{if(s){OP();let e=e=>{e.key===`Escape`&&c(!1)};return document.addEventListener(`keydown`,e),()=>{document.removeEventListener(`keydown`,e),kP()}}},[s]),(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(`button`,{className:o(`cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50`,t),disabled:l,onClick:f,title:u.viewFullscreen,type:`button`,children:(0,_.jsx)(i,{size:14})}),s?(0,E.createPortal)((0,_.jsx)(`div`,{"aria-label":u.viewFullscreen,"aria-modal":`true`,className:o(`fixed inset-0 z-50 flex flex-col bg-background`),"data-streamdown":`table-fullscreen`,onClick:p,onKeyDown:e=>{e.key===`Escape`&&p()},role:`dialog`,children:(0,_.jsxs)(`div`,{className:o(`flex h-full flex-col`),onClick:e=>e.stopPropagation(),onKeyDown:e=>e.stopPropagation(),role:`presentation`,children:[(0,_.jsxs)(`div`,{className:o(`flex items-center justify-end gap-1 p-4`),children:[n?(0,_.jsx)(WP,{}):null,r?(0,_.jsx)(GP,{}):null,(0,_.jsx)(`button`,{className:o(`rounded-md p-1 text-muted-foreground transition-all hover:bg-muted hover:text-foreground`),onClick:p,title:u.exitFullscreen,type:`button`,children:(0,_.jsx)(a,{size:20})})]}),(0,_.jsx)(`div`,{className:o(`flex-1 overflow-auto p-4 pt-0 [&_thead]:sticky [&_thead]:top-0 [&_thead]:z-10`),children:(0,_.jsx)(`table`,{className:o(`w-full border-collapse border border-border`),"data-streamdown":`table`,children:e})})]})}),document.body):null]})},qP=({children:e,className:t,showControls:n,showCopy:r=!0,showDownload:i=!0,showFullscreen:a=!0,...o})=>{let s=nP(),c=n&&r,l=n&&i,u=n&&a,d=c||l||u;return(0,_.jsxs)(`div`,{className:s(`my-4 flex flex-col gap-2 rounded-lg border border-border bg-sidebar p-2`),"data-streamdown":`table-wrapper`,children:[d?(0,_.jsxs)(`div`,{className:s(`flex items-center justify-end gap-1`),children:[c?(0,_.jsx)(WP,{}):null,l?(0,_.jsx)(GP,{}):null,u?(0,_.jsx)(KP,{showCopy:c,showDownload:l,children:e}):null]}):null,(0,_.jsx)(`div`,{className:s(`border-collapse overflow-x-auto overflow-y-auto rounded-md border border-border bg-background`),children:(0,_.jsx)(`table`,{className:s(`w-full divide-y divide-border`,t),"data-streamdown":`table`,...o,children:e})})]})},JP=/startLine=(\d+)/,YP=/\bnoLineNumbers\b/,XP=(0,d.lazy)(()=>$(()=>import(`./mermaid-GHXKKRXX-BSt5tun0.js`).then(e=>({default:e.Mermaid})),[])),ZP=/language-([^\s]+)/;function QP(e,t){if(!(e!=null&&e.position||t!=null&&t.position))return!0;if(!(e!=null&&e.position&&t!=null&&t.position))return!1;let n=e.position.start,r=t.position.start,i=e.position.end,a=t.position.end;return n?.line===r?.line&&n?.column===r?.column&&i?.line===a?.line&&i?.column===a?.column}function $P(e,t){return e.className===t.className&&QP(e.node,t.node)}var eF=(e,t)=>typeof e==`boolean`?e:e[t]!==!1,tF=(e,t)=>{if(typeof e==`boolean`)return e;let n=e.table;return n===!1?!1:n===!0||n===void 0?!0:n[t]!==!1},nF=(e,t)=>{if(typeof e==`boolean`)return e;let n=e.code;return n===!1?!1:n===!0||n===void 0?!0:n[t]!==!1},rF=(e,t)=>{if(typeof e==`boolean`)return e;let n=e.mermaid;return n===!1?!1:n===!0||n===void 0?!0:n[t]!==!1},iF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`ol`,{className:nP()(`list-inside list-decimal whitespace-normal [li_&]:pl-6`,t),"data-streamdown":`ordered-list`,...r,children:e}),(e,t)=>$P(e,t));iF.displayName=`MarkdownOl`;var aF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`li`,{className:nP()(`py-1 [&>p]:inline`,t),"data-streamdown":`list-item`,...r,children:e}),(e,t)=>e.className===t.className&&QP(e.node,t.node));aF.displayName=`MarkdownLi`;var oF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`ul`,{className:nP()(`list-inside list-disc whitespace-normal [li_&]:pl-6`,t),"data-streamdown":`unordered-list`,...r,children:e}),(e,t)=>$P(e,t));oF.displayName=`MarkdownUl`;var sF=(0,d.memo)(({className:e,node:t,...n})=>(0,_.jsx)(`hr`,{className:nP()(`my-6 border-border`,e),"data-streamdown":`horizontal-rule`,...n}),(e,t)=>$P(e,t));sF.displayName=`MarkdownHr`;var cF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`span`,{className:nP()(`font-semibold`,t),"data-streamdown":`strong`,...r,children:e}),(e,t)=>$P(e,t));cF.displayName=`MarkdownStrong`;var lF=(0,d.memo)(({children:e,className:t,href:n,node:r,...i})=>{let a=nP(),{linkSafety:o}=(0,d.useContext)(DI),[s,c]=(0,d.useState)(!1),l=n===`streamdown:incomplete-link`,u=(0,d.useCallback)(async e=>{if(!(!(o!=null&&o.enabled&&n)||l)){if(e.preventDefault(),o.onLinkCheck&&await o.onLinkCheck(n)){window.open(n,`_blank`,`noreferrer`);return}c(!0)}},[o,n,l]),f=(0,d.useCallback)(()=>{n&&window.open(n,`_blank`,`noreferrer`)},[n]),p=(0,d.useCallback)(()=>{c(!1)},[]),m={url:n??``,isOpen:s,onClose:p,onConfirm:f};return o!=null&&o.enabled&&n?(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(`button`,{className:a(`wrap-anywhere appearance-none text-left font-medium text-primary underline`,t),"data-incomplete":l,"data-streamdown":`link`,onClick:u,type:`button`,children:e}),o.renderModal?o.renderModal(m):(0,_.jsx)(AP,{...m})]}):(0,_.jsx)(`a`,{className:a(`wrap-anywhere font-medium text-primary underline`,t),"data-incomplete":l,"data-streamdown":`link`,href:n,rel:`noreferrer`,target:`_blank`,...i,children:e})},(e,t)=>$P(e,t)&&e.href===t.href);lF.displayName=`MarkdownA`;var uF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`h1`,{className:nP()(`mt-6 mb-2 font-semibold text-3xl`,t),"data-streamdown":`heading-1`,...r,children:e}),(e,t)=>$P(e,t));uF.displayName=`MarkdownH1`;var dF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`h2`,{className:nP()(`mt-6 mb-2 font-semibold text-2xl`,t),"data-streamdown":`heading-2`,...r,children:e}),(e,t)=>$P(e,t));dF.displayName=`MarkdownH2`;var fF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`h3`,{className:nP()(`mt-6 mb-2 font-semibold text-xl`,t),"data-streamdown":`heading-3`,...r,children:e}),(e,t)=>$P(e,t));fF.displayName=`MarkdownH3`;var pF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`h4`,{className:nP()(`mt-6 mb-2 font-semibold text-lg`,t),"data-streamdown":`heading-4`,...r,children:e}),(e,t)=>$P(e,t));pF.displayName=`MarkdownH4`;var mF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`h5`,{className:nP()(`mt-6 mb-2 font-semibold text-base`,t),"data-streamdown":`heading-5`,...r,children:e}),(e,t)=>$P(e,t));mF.displayName=`MarkdownH5`;var hF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`h6`,{className:nP()(`mt-6 mb-2 font-semibold text-sm`,t),"data-streamdown":`heading-6`,...r,children:e}),(e,t)=>$P(e,t));hF.displayName=`MarkdownH6`;var gF=(0,d.memo)(({children:e,className:t,node:n,...r})=>{let{controls:i}=(0,d.useContext)(DI);return(0,_.jsx)(qP,{className:t,showControls:eF(i,`table`),showCopy:tF(i,`copy`),showDownload:tF(i,`download`),showFullscreen:tF(i,`fullscreen`),...r,children:e})},(e,t)=>$P(e,t));gF.displayName=`MarkdownTable`;var _F=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`thead`,{className:nP()(`bg-muted/80`,t),"data-streamdown":`table-header`,...r,children:e}),(e,t)=>$P(e,t));_F.displayName=`MarkdownThead`;var vF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`tbody`,{className:nP()(`divide-y divide-border`,t),"data-streamdown":`table-body`,...r,children:e}),(e,t)=>$P(e,t));vF.displayName=`MarkdownTbody`;var yF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`tr`,{className:nP()(`border-border`,t),"data-streamdown":`table-row`,...r,children:e}),(e,t)=>$P(e,t));yF.displayName=`MarkdownTr`;var bF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`th`,{className:nP()(`whitespace-nowrap px-4 py-2 text-left font-semibold text-sm`,t),"data-streamdown":`table-header-cell`,...r,children:e}),(e,t)=>$P(e,t));bF.displayName=`MarkdownTh`;var xF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`td`,{className:nP()(`px-4 py-2 text-sm`,t),"data-streamdown":`table-cell`,...r,children:e}),(e,t)=>$P(e,t));xF.displayName=`MarkdownTd`;var SF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`blockquote`,{className:nP()(`my-4 border-muted-foreground/30 border-l-4 pl-4 text-muted-foreground italic`,t),"data-streamdown":`blockquote`,...r,children:e}),(e,t)=>$P(e,t));SF.displayName=`MarkdownBlockquote`;var CF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`sup`,{className:nP()(`text-sm`,t),"data-streamdown":`superscript`,...r,children:e}),(e,t)=>$P(e,t));CF.displayName=`MarkdownSup`;var wF=(0,d.memo)(({children:e,className:t,node:n,...r})=>(0,_.jsx)(`sub`,{className:nP()(`text-sm`,t),"data-streamdown":`subscript`,...r,children:e}),(e,t)=>$P(e,t));wF.displayName=`MarkdownSub`;var TF=(0,d.memo)(({children:e,className:t,node:n,...r})=>{if(`data-footnotes`in r){let n=e=>{if(!(0,d.isValidElement)(e))return!1;let t=Array.isArray(e.props.children)?e.props.children:[e.props.children],n=!1,r=!1;for(let e of t)if(e){if(typeof e==`string`)e.trim()!==``&&(n=!0);else if((0,d.isValidElement)(e))if(e.props?.[`data-footnote-backref`]!==void 0)r=!0;else{let t=Array.isArray(e.props.children)?e.props.children:[e.props.children];for(let e of t){if(typeof e==`string`&&e.trim()!==``){n=!0;break}if((0,d.isValidElement)(e)&&e.props?.[`data-footnote-backref`]===void 0){n=!0;break}}}}return r&&!n},i=Array.isArray(e)?e.map(e=>{if(!(0,d.isValidElement)(e))return e;if(e.type===iF){let t=(Array.isArray(e.props.children)?e.props.children:[e.props.children]).filter(e=>!n(e));return t.length===0?null:{...e,props:{...e.props,children:t}}}return e}):e;return(Array.isArray(i)?i.some(e=>e!==null):i!==null)?(0,_.jsx)(`section`,{className:t,...r,children:i}):null}return(0,_.jsx)(`section`,{className:t,...r,children:e})},(e,t)=>$P(e,t));TF.displayName=`MarkdownSection`;var EF=(0,d.memo)(({node:e,className:t,children:n,...r})=>{let i=nP(),a=!(`data-block`in r),{mermaid:o,controls:s,lineNumbers:c}=(0,d.useContext)(DI),l=PP(),u=XN(),f=(t?.match(ZP))?.at(1)??``,p=FP(f);if(a)return(0,_.jsx)(`code`,{className:i(`rounded bg-muted px-1.5 py-0.5 font-mono text-sm`,t),"data-streamdown":`inline-code`,...r,children:n});let m=e?.properties?.metastring,h=m?.match(JP),g=h?Number.parseInt(h[1],10):void 0,v=g!==void 0&&g>=1?g:void 0,y=!(m&&YP.test(m))&&c!==!1,b=``;if((0,d.isValidElement)(n)&&n.props&&typeof n.props==`object`&&`children`in n.props&&typeof n.props.children==`string`?b=n.props.children:typeof n==`string`&&(b=n),p){let e=p.component;return(0,_.jsx)(d.Suspense,{fallback:(0,_.jsx)(wP,{}),children:(0,_.jsx)(e,{code:b,isIncomplete:u,language:f,meta:m})})}if(f===`mermaid`&&l){let e=eF(s,`mermaid`),n=rF(s,`download`),r=rF(s,`copy`),a=rF(s,`fullscreen`),c=rF(s,`panZoom`),l=e&&(n||r||a);return(0,_.jsx)(d.Suspense,{fallback:(0,_.jsx)(wP,{}),children:(0,_.jsxs)(`div`,{className:i(`group relative my-4 flex w-full flex-col gap-2 rounded-xl border border-border bg-sidebar p-2`,t),"data-streamdown":`mermaid-block`,children:[(0,_.jsx)(`div`,{className:i(`flex h-8 items-center text-muted-foreground text-xs`),children:(0,_.jsx)(`span`,{className:i(`ml-1 font-mono lowercase`),children:`mermaid`})}),l?(0,_.jsx)(`div`,{className:i(`pointer-events-none sticky top-2 z-10 -mt-10 flex h-8 items-center justify-end`),children:(0,_.jsxs)(`div`,{className:i(`pointer-events-auto flex shrink-0 items-center gap-2 rounded-md border border-sidebar bg-sidebar/80 px-1.5 py-1 supports-[backdrop-filter]:bg-sidebar/70 supports-[backdrop-filter]:backdrop-blur`),"data-streamdown":`mermaid-block-actions`,children:[n?(0,_.jsx)(LP,{chart:b,config:o?.config}):null,r?(0,_.jsx)(xP,{code:b}):null,a?(0,_.jsx)(RP,{chart:b,config:o?.config}):null]})}):null,(0,_.jsx)(`div`,{className:i(`rounded-md border border-border bg-background`),children:(0,_.jsx)(XP,{chart:b,config:o?.config,showControls:c})})]})})}let x=eF(s,`code`),S=nF(s,`download`),C=nF(s,`copy`);return(0,_.jsx)(fP,{className:t,code:b,isIncomplete:u,language:f,lineNumbers:y,startLine:v,children:x?(0,_.jsxs)(_.Fragment,{children:[S?(0,_.jsx)(CP,{code:b,language:f}):null,C?(0,_.jsx)(xP,{}):null]}):null})},(e,t)=>e.className===t.className&&QP(e.node,t.node));EF.displayName=`MarkdownCode`;var DF=(0,d.memo)(EP,(e,t)=>e.className===t.className&&QP(e.node,t.node));DF.displayName=`MarkdownImg`;var OF=(0,d.memo)(({children:e,node:t,...n})=>{let r=(Array.isArray(e)?e:[e]).filter(e=>e!=null&&e!==``);if(r.length===1&&(0,d.isValidElement)(r[0])){let t=r[0].props.node?.tagName;if(t===`img`||t===`code`&&`data-block`in r[0].props)return(0,_.jsx)(_.Fragment,{children:e})}return(0,_.jsx)(`p`,{...n,children:e})},(e,t)=>$P(e,t));OF.displayName=`MarkdownParagraph`;var kF={ol:iF,li:aF,ul:oF,hr:sF,strong:cF,a:lF,h1:uF,h2:dF,h3:fF,h4:pF,h5:mF,h6:hF,table:gF,thead:_F,tbody:vF,tr:yF,th:bF,td:xF,blockquote:SF,code:EF,img:DF,pre:({children:e})=>(0,d.isValidElement)(e)?(0,d.cloneElement)(e,{"data-block":`true`}):e,sup:CF,sub:wF,p:OF,section:TF},AF=/[\u0590-\u08FF\uFB1D-\uFDFF\uFE70-\uFEFF]/,jF=/\p{L}/u;function MF(e){let t=e.replace(/^#{1,6}\s+/gm,``).replace(/(\*{1,3}|_{1,3})/g,``).replace(/`[^`]*`/g,``).replace(/\[([^\]]*)\]\([^)]*\)/g,`$1`).replace(/^[\s>*\-+\d.]+/gm,``);for(let e of t){if(AF.test(e))return`rtl`;if(jF.test(e))return`ltr`}return`ltr`}var NF=/^[ \t]{0,3}(`{3,}|~{3,})/,PF=/^\|?[ \t]*:?-{1,}:?[ \t]*(\|[ \t]*:?-{1,}:?[ \t]*)*\|?$/,FF=e=>{let t=e.split(`
186
- `),n=null,r=0;for(let e of t){let t=NF.exec(e);if(n===null){if(t){let e=t[1];n=e[0],r=e.length}}else if(t){let e=t[1],i=e[0],a=e.length;i===n&&a>=r&&(n=null,r=0)}}return n!==null},IF=e=>{let t=e.split(`
187
- `);for(let e of t){let t=e.trim();if(t.length>0&&t.includes(`|`)&&PF.test(t))return!0}return!1},LF=()=>e=>{dh(e,`html`,(e,t,n)=>{!n||typeof t!=`number`||(n.children[t]={type:`text`,value:e.value})})},RF=[],zF={allowDangerousHtml:!0},BF=new WeakMap,VF=new class{constructor(){this.cache=new Map,this.keyCache=new WeakMap,this.maxSize=100}generateCacheKey(e){let t=this.keyCache.get(e);if(t)return t;let n=e.rehypePlugins,r=e.remarkPlugins,i=e.remarkRehypeOptions;if(!(n||r||i)){let t=`default`;return this.keyCache.set(e,t),t}let a=e=>{if(!e||e.length===0)return``;let t=``;for(let n=0;n<e.length;n+=1){let r=e[n];if(n>0&&(t+=`,`),Array.isArray(r)){let[e,n]=r;if(typeof e==`function`){let n=BF.get(e);n||(n=e.name,BF.set(e,n)),t+=n}else t+=String(e);t+=`:`,t+=JSON.stringify(n)}else if(typeof r==`function`){let e=BF.get(r);e||(e=r.name,BF.set(r,e)),t+=e}else t+=String(r)}return t},o=a(n),s=`${a(r)}::${o}::${i?JSON.stringify(i):``}`;return this.keyCache.set(e,s),s}get(e){let t=this.generateCacheKey(e),n=this.cache.get(t);return n&&(this.cache.delete(t),this.cache.set(t,n)),n}set(e,t){let n=this.generateCacheKey(e);if(this.cache.size>=this.maxSize){let e=this.cache.keys().next().value;e&&this.cache.delete(e)}this.cache.set(n,t)}clear(){this.cache.clear()}},HF=e=>{let t=UF(e),n=e.children||``;return XF(t.runSync(t.parse(n),n),e)},UF=e=>{let t=VF.get(e);if(t)return t;let n=GF(e);return VF.set(e,n),n},WF=e=>e.some(e=>Array.isArray(e)?e[0]===Fx:e===Fx),GF=e=>{let t=e.rehypePlugins||RF,n=e.remarkPlugins||RF,r=WF(t)?n:[...n,LF],i=e.remarkRehypeOptions?{...zF,...e.remarkRehypeOptions}:zF;return Gj().use(EA).use(r).use(_j,i).use(t)},KF=e=>e,qF=(e,t,n,r)=>{n?e.children.splice(t,1):e.children[t]={type:`text`,value:r}},JF=(e,t)=>{for(let n in Vk)if(Object.hasOwn(Vk,n)&&Object.hasOwn(e.properties,n)){let r=e.properties[n],i=Vk[n];(i===null||i.includes(e.tagName))&&(e.properties[n]=t(String(r||``),n,e)??void 0)}},YF=(e,t,n,r,i,a)=>{let o=!1;return r?o=!r.includes(e.tagName):i&&(o=i.includes(e.tagName)),!o&&a&&typeof t==`number`&&(o=!a(e,t,n)),o},XF=(e,t)=>{let{allowElement:n,allowedElements:r,disallowedElements:i,skipHtml:a,unwrapDisallowed:o,urlTransform:s}=t;if(n||r||i||a||s){let t=s||KF;dh(e,(e,s,c)=>{if(e.type===`raw`&&c&&typeof s==`number`)return qF(c,s,a,e.value),s;if(e.type===`element`&&(JF(e,t),YF(e,s,c,r,i,n)&&c&&typeof s==`number`))return o&&e.children?c.children.splice(s,1,...e.children):c.children.splice(s,1),s})}return yk(e,{Fragment:_.Fragment,components:t.components,ignoreInvalidStyle:!0,jsx:_.jsx,jsxs:_.jsxs,passKeys:!0,passNode:!0})},ZF=/\[\^[\w-]{1,200}\](?!:)/,QF=/\[\^[\w-]{1,200}\]:/,$F=/<(\w+)[\s>]/,eI=new Set([`area`,`base`,`br`,`col`,`embed`,`hr`,`img`,`input`,`link`,`meta`,`param`,`source`,`track`,`wbr`]),tI=new Map,nI=new Map,rI=e=>{let t=e.toLowerCase(),n=tI.get(t);if(n)return n;let r=RegExp(`<${t}(?=[\\s>/])[^>]*>`,`gi`);return tI.set(t,r),r},iI=e=>{let t=e.toLowerCase(),n=nI.get(t);if(n)return n;let r=RegExp(`</${t}(?=[\\s>])[^>]*>`,`gi`);return nI.set(t,r),r},aI=(e,t)=>{if(eI.has(t.toLowerCase()))return 0;let n=e.match(rI(t));if(!n)return 0;let r=0;for(let e of n)e.trimEnd().endsWith(`/>`)||(r+=1);return r},oI=(e,t)=>{let n=e.match(iI(t));return n?n.length:0},sI=e=>{let t=0;for(let n=0;n<e.length-1;n+=1)e[n]===`$`&&e[n+1]===`$`&&(t+=1,n+=1);return t},cI=e=>{let t=ZF.test(e),n=QF.test(e);if(t||n)return[e];let r=wN.lex(e,{gfm:!0}),i=[],a=[],o=!1;for(let e of r){let t=e.raw,n=i.length;if(a.length>0){i[n-1]+=t;let e=a.at(-1),r=aI(t,e),o=oI(t,e);for(let t=0;t<r;t+=1)a.push(e);for(let t=0;t<o;t+=1)a.length>0&&a.at(-1)===e&&a.pop();continue}if(e.type===`html`&&e.block){let e=t.match($F);if(e){let n=e[1];aI(t,n)>oI(t,n)&&a.push(n)}}if(n>0&&!o){let e=i[n-1];if(sI(e)%2==1){i[n-1]=e+t;continue}}i.push(t),e.type!==`space`&&(o=e.type===`code`)}return i},lI=(e,t)=>{if(!t.length)return e;let n=e;for(let e of t){let t=RegExp(`(<${e}(?=[\\s>/])[^>]*>)([\\s\\S]*?)(</${e}\\s*>)`,`gi`);n=n.replace(t,(e,t,n,r)=>{if(!n.includes(`
188
-
189
- `))return t+n+r;let i=n.replace(/\n\n/g,`
190
- <!---->
191
- `);return`${t}${(i.startsWith(`
192
- `)?``:`
193
- `)+i+(i.endsWith(`
194
- `)?``:`
195
- `)}${r}
196
-
197
- `})}return n},uI=/([\\`*_~[\]|])/g,dI=e=>e.replace(uI,`\\$1`),fI=(e,t)=>{if(!t.length)return e;let n=e;for(let e of t){let t=RegExp(`(<${e}(?=[\\s>/])[^>]*>)([\\s\\S]*?)(</${e}\\s*>)`,`gi`);n=n.replace(t,(e,t,n,r)=>t+dI(n).replace(/\n\n/g,`&#10;&#10;`)+r)}return n},pI=e=>e.type===`text`?e.value:`children`in e&&Array.isArray(e.children)?e.children.map(pI).join(``):``,mI=e=>t=>{if(!e||e.length===0)return;let n=new Set(e.map(e=>e.toLowerCase()));dh(t,`element`,e=>{if(n.has(e.tagName.toLowerCase())){let t=pI(e);e.children=t?[{type:`text`,value:t}]:[]}})},hI=()=>e=>{dh(e,`code`,e=>{e.meta&&(e.data=e.data??{},e.data.hProperties={...e.data.hProperties??{},metastring:e.meta})})},gI=/^[ \t]*<[\w!/?-]/,_I=/(^|\n)[ \t]{4,}(?=<[\w!/?-])/g,vI=e=>typeof e!=`string`||e.length===0||!gI.test(e)?e:e.replace(_I,`$1`),yI={...Lx,protocols:{...Lx.protocols,href:[...Lx.protocols?.href??[],`tel`]},attributes:{...Lx.attributes,code:[...Lx.attributes?.code??[],`metastring`]}},bI={raw:Fx,sanitize:[eS,yI],harden:[ph,{allowedImagePrefixes:[`*`],allowedLinkPrefixes:[`*`],allowedProtocols:[`*`],defaultOrigin:void 0,allowDataImages:!0}]},xI={gfm:[gD,{}],codeMeta:hI},SI=Object.values(bI),CI=Object.values(xI),wI={block:` ▋`,circle:` ●`},TI=[`github-light`,`github-dark`],EI={enabled:!0},DI=(0,d.createContext)({shikiTheme:TI,controls:!0,isAnimating:!1,lineNumbers:!0,mode:`streaming`,mermaid:void 0,linkSafety:EI}),OI=(0,d.memo)(({content:e,shouldParseIncompleteMarkdown:t,shouldNormalizeHtmlIndentation:n,index:r,isIncomplete:i,dir:a,animatePlugin:o,...s})=>{if(o){let e=o.getLastRenderCharCount();o.setPrevContentLength(e)}let c=typeof e==`string`&&n?vI(e):e,l=(0,_.jsx)(HF,{...s,children:c});return(0,_.jsx)(YN.Provider,{value:i,children:a?(0,_.jsx)(`div`,{dir:a,style:{display:`contents`},children:l}):l})},(e,t)=>{if(e.content!==t.content||e.shouldNormalizeHtmlIndentation!==t.shouldNormalizeHtmlIndentation||e.index!==t.index||e.isIncomplete!==t.isIncomplete||e.dir!==t.dir)return!1;if(e.components!==t.components){let n=Object.keys(e.components||{}),r=Object.keys(t.components||{});if(n.length!==r.length||n.some(n=>e.components?.[n]!==t.components?.[n]))return!1}return!(e.rehypePlugins!==t.rehypePlugins||e.remarkPlugins!==t.remarkPlugins)});OI.displayName=`Block`;var kI=(0,d.memo)(({children:e,mode:t=`streaming`,dir:n,parseIncompleteMarkdown:r=!0,normalizeHtmlIndentation:i=!1,components:a,rehypePlugins:o=SI,remarkPlugins:s=CI,className:c,shikiTheme:l=TI,mermaid:u,controls:f=!0,isAnimating:p=!1,animated:m,BlockComponent:h=OI,parseMarkdownIntoBlocksFn:g=cI,caret:v,plugins:y,remend:b,linkSafety:x=EI,lineNumbers:S=!0,allowedTags:C,literalTagContent:w,translations:T,icons:E,prefix:D,onAnimationStart:O,onAnimationEnd:ee,...te})=>{let k=(0,d.useId)(),[A,j]=(0,d.useTransition)(),M=(0,d.useMemo)(()=>$N(D),[D]),ne=(0,d.useRef)(null),N=(0,d.useRef)(O),P=(0,d.useRef)(ee);N.current=O,P.current=ee,(0,d.useEffect)(()=>{var e,n,r;if(t===`static`)return;let i=ne.current;if(ne.current=p,i===null){p&&((e=N.current)==null||e.call(N));return}p&&!i?(n=N.current)==null||n.call(N):!p&&i&&((r=P.current)==null||r.call(P))},[p,t]);let re=(0,d.useMemo)(()=>C?Object.keys(C):[],[C]),ie=(0,d.useMemo)(()=>{if(typeof e!=`string`)return``;let n=t===`streaming`&&r?YO(e,b):e;return w&&w.length>0&&(n=fI(n,w)),re.length>0&&(n=lI(n,re)),n},[e,t,r,b,re,w]),ae=(0,d.useMemo)(()=>g(ie),[ie,g]),[oe,F]=(0,d.useState)(ae);(0,d.useEffect)(()=>{t===`streaming`&&!ue?j(()=>{F(ae)}):F(ae)},[ae,t]);let I=t===`streaming`?oe:ae,se=(0,d.useMemo)(()=>n===`auto`?I.map(MF):void 0,[I,n]),ce=(0,d.useMemo)(()=>I.map((e,t)=>`${k}-${t}`),[I.length,k]),le=(0,d.useMemo)(()=>m===!0?`true`:m?JSON.stringify(m):``,[m]),ue=(0,d.useMemo)(()=>le?le===`true`?JN():JN(m):null,[le]),de=(0,d.useMemo)(()=>({shikiTheme:(y?.code)?.getThemes()??l,controls:f,isAnimating:p,lineNumbers:S,mode:t,mermaid:u,linkSafety:x}),[l,f,p,S,t,u,x,y?.code]),fe=(0,d.useMemo)(()=>({...vP,...T}),[(0,d.useMemo)(()=>T?JSON.stringify(T):``,[T])]),pe=(0,d.useMemo)(()=>{let{inlineCode:e,...t}=a??{},n={...kF,...t};if(e){let t=n.code;n.code=n=>`data-block`in n?t?(0,d.createElement)(t,n):null:(0,d.createElement)(e,n)}return n},[a]),me=(0,d.useMemo)(()=>{let e=[];return y!=null&&y.cjk&&(e=[...e,...y.cjk.remarkPluginsBefore]),e=[...e,...s],y!=null&&y.cjk&&(e=[...e,...y.cjk.remarkPluginsAfter]),y!=null&&y.math&&(e=[...e,y.math.remarkPlugin]),e},[s,y?.math,y?.cjk]),he=(0,d.useMemo)(()=>{let e=o;if(C&&Object.keys(C).length>0&&o===SI){let t={...yI,tagNames:[...yI.tagNames??[],...Object.keys(C)],attributes:{...yI.attributes,...C}};e=[bI.raw,[eS,t],bI.harden]}return w&&w.length>0&&(e=[...e,[mI,w]]),y!=null&&y.math&&(e=[...e,y.math.rehypePlugin]),ue&&p&&(e=[...e,ue.rehypePlugin]),e},[o,y?.math,ue,p,C,w]),ge=(0,d.useMemo)(()=>{if(!p||I.length===0)return!1;let e=I.at(-1);return FF(e)||IF(e)},[p,I]),_e=(0,d.useMemo)(()=>v&&p&&!ge?{"--streamdown-caret":`"${wI[v]}"`}:void 0,[v,p,ge]);return t===`static`?(0,_.jsx)(yP.Provider,{value:fe,children:(0,_.jsx)(jP.Provider,{value:y??null,children:(0,_.jsx)(DI.Provider,{value:de,children:(0,_.jsx)(gP,{icons:E,children:(0,_.jsx)(tP.Provider,{value:M,children:(0,_.jsx)(`div`,{className:M(`space-y-4 whitespace-normal [&>*:first-child]:mt-0 [&>*:last-child]:mb-0`,c),dir:n===`auto`?MF(ie):n,children:(0,_.jsx)(HF,{components:pe,rehypePlugins:he,remarkPlugins:me,...te,children:ie})})})})})})}):(0,_.jsx)(yP.Provider,{value:fe,children:(0,_.jsx)(jP.Provider,{value:y??null,children:(0,_.jsx)(DI.Provider,{value:de,children:(0,_.jsx)(gP,{icons:E,children:(0,_.jsx)(tP.Provider,{value:M,children:(0,_.jsxs)(`div`,{className:M(`space-y-4 whitespace-normal [&>*:first-child]:mt-0 [&>*:last-child]:mb-0`,v&&!ge?`[&>*:last-child]:after:inline [&>*:last-child]:after:align-baseline [&>*:last-child]:after:content-[var(--streamdown-caret)]`:null,c),style:_e,children:[I.length===0&&v&&p&&(0,_.jsx)(`span`,{}),I.map((e,t)=>{let a=t===I.length-1,o=p&&a&&FF(e);return(0,_.jsx)(h,{animatePlugin:ue,components:pe,content:e,dir:se?.[t]??(n===`auto`?void 0:n),index:t,isIncomplete:o,rehypePlugins:he,remarkPlugins:me,shouldNormalizeHtmlIndentation:i,shouldParseIncompleteMarkdown:r,...te},ce[t])})]})})})})})})},(e,t)=>e.children===t.children&&e.shikiTheme===t.shikiTheme&&e.isAnimating===t.isAnimating&&e.animated===t.animated&&e.mode===t.mode&&e.plugins===t.plugins&&e.className===t.className&&e.linkSafety===t.linkSafety&&e.lineNumbers===t.lineNumbers&&e.normalizeHtmlIndentation===t.normalizeHtmlIndentation&&e.literalTagContent===t.literalTagContent&&JSON.stringify(e.translations)===JSON.stringify(t.translations)&&e.prefix===t.prefix&&e.dir===t.dir);kI.displayName=`Streamdown`;var AI=({children:e,className:t,minZoom:n=.5,maxZoom:r=3,zoomStep:i=.1,showControls:a=!0,initialZoom:o=1,fullscreen:s=!1})=>{let{RotateCcwIcon:c,ZoomInIcon:l,ZoomOutIcon:u}=_P(),f=nP(),p=(0,d.useRef)(null),m=(0,d.useRef)(null),[h,g]=(0,d.useState)(o),[v,y]=(0,d.useState)({x:0,y:0}),[b,x]=(0,d.useState)(!1),[S,C]=(0,d.useState)({x:0,y:0}),[w,T]=(0,d.useState)({x:0,y:0}),E=(0,d.useCallback)(e=>{g(t=>Math.max(n,Math.min(r,t+e)))},[n,r]),D=(0,d.useCallback)(()=>{E(i)},[E,i]),O=(0,d.useCallback)(()=>{E(-i)},[E,i]),ee=(0,d.useCallback)(()=>{g(o),y({x:0,y:0})},[o]),te=(0,d.useCallback)(e=>{e.preventDefault(),E(e.deltaY>0?-i:i)},[E,i]),k=(0,d.useCallback)(e=>{if(e.button!==0||e.isPrimary===!1)return;x(!0),C({x:e.clientX,y:e.clientY}),T(v);let t=e.currentTarget;t instanceof HTMLElement&&t.setPointerCapture(e.pointerId)},[v]),A=(0,d.useCallback)(e=>{if(!b)return;e.preventDefault();let t=e.clientX-S.x,n=e.clientY-S.y;y({x:w.x+t,y:w.y+n})},[b,S,w]),j=(0,d.useCallback)(e=>{x(!1);let t=e.currentTarget;t instanceof HTMLElement&&t.releasePointerCapture(e.pointerId)},[]);return(0,d.useEffect)(()=>{let e=p.current;if(e)return e.addEventListener(`wheel`,te,{passive:!1}),()=>{e.removeEventListener(`wheel`,te)}},[te]),(0,d.useEffect)(()=>{let e=m.current;if(e&&b)return document.body.style.userSelect=`none`,e.addEventListener(`pointermove`,A,{passive:!1}),e.addEventListener(`pointerup`,j),e.addEventListener(`pointercancel`,j),()=>{document.body.style.userSelect=``,e.removeEventListener(`pointermove`,A),e.removeEventListener(`pointerup`,j),e.removeEventListener(`pointercancel`,j)}},[b,A,j]),(0,_.jsxs)(`div`,{className:f(`relative flex flex-col`,s?`h-full w-full`:`min-h-28 w-full`,t),ref:p,style:{cursor:b?`grabbing`:`grab`},children:[a?(0,_.jsxs)(`div`,{className:f(`absolute z-10 flex flex-col gap-1 rounded-md border border-border bg-background/80 p-1 supports-[backdrop-filter]:bg-background/70 supports-[backdrop-filter]:backdrop-blur-sm`,s?`bottom-4 left-4`:`bottom-2 left-2`),children:[(0,_.jsx)(`button`,{className:f(`flex items-center justify-center rounded p-1.5 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50`),disabled:h>=r,onClick:D,title:`Zoom in`,type:`button`,children:(0,_.jsx)(l,{size:16})}),(0,_.jsx)(`button`,{className:f(`flex items-center justify-center rounded p-1.5 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50`),disabled:h<=n,onClick:O,title:`Zoom out`,type:`button`,children:(0,_.jsx)(u,{size:16})}),(0,_.jsx)(`button`,{className:f(`flex items-center justify-center rounded p-1.5 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground`),onClick:ee,title:`Reset zoom and pan`,type:`button`,children:(0,_.jsx)(c,{size:16})})]}):null,(0,_.jsx)(`div`,{className:f(`flex-1 origin-center transition-transform duration-150 ease-out`,s?`flex h-full w-full items-center justify-center`:`flex w-full items-center justify-center`),onPointerDown:k,ref:m,role:`application`,style:{transform:`translate(${v.x}px, ${v.y}px) scale(${h})`,transformOrigin:`center center`,touchAction:`none`,willChange:`transform`},children:e})]})},jI=({chart:e,className:t,config:n,fullscreen:r=!1,showControls:i=!0})=>{let a=nP(),[o,s]=(0,d.useState)(null),[c,l]=(0,d.useState)(!1),[u,f]=(0,d.useState)(``),[p,m]=(0,d.useState)(``),[h,g]=(0,d.useState)(0),{mermaid:v}=(0,d.useContext)(DI),y=PP(),b=v?.errorComponent,{shouldRender:x,containerRef:S}=LN({immediate:r});if((0,d.useEffect)(()=>{if(x){if(!y){s(`Mermaid plugin not available. Please add the mermaid plugin to enable diagram rendering.`);return}(async()=>{try{s(null),l(!0);let t=y.getMermaid(n),r=e.split(``).reduce((e,t)=>(e<<5)-e+t.charCodeAt(0)|0,0),i=`mermaid-${Math.abs(r)}-${Date.now()}-${Math.random().toString(36).substring(2,9)}`,{svg:a}=await t.render(i,e);f(a),m(a)}catch(e){p||u||s(e instanceof Error?e.message:`Failed to render Mermaid chart`)}finally{l(!1)}})()}},[e,n,h,x,y]),!(x||u||p))return(0,_.jsx)(`div`,{className:a(`my-4 min-h-[200px]`,t),ref:S});if(c&&!u&&!p)return(0,_.jsx)(`div`,{className:a(`my-4 flex justify-center p-4`,t),ref:S,children:(0,_.jsxs)(`div`,{className:a(`flex items-center space-x-2 text-muted-foreground`),children:[(0,_.jsx)(`div`,{className:a(`h-4 w-4 animate-spin rounded-full border-current border-b-2`)}),(0,_.jsx)(`span`,{className:a(`text-sm`),children:`Loading diagram...`})]})});if(o&&!u&&!p)return b?(0,_.jsx)(`div`,{ref:S,children:(0,_.jsx)(b,{chart:e,error:o,retry:()=>g(e=>e+1)})}):(0,_.jsxs)(`div`,{className:a(`rounded-md bg-red-50 p-4`,t),ref:S,children:[(0,_.jsxs)(`p`,{className:a(`font-mono text-red-700 text-sm`),children:[`Mermaid Error: `,o]}),(0,_.jsxs)(`details`,{className:a(`mt-2`),children:[(0,_.jsx)(`summary`,{className:a(`cursor-pointer text-red-600 text-xs`),children:`Show Code`}),(0,_.jsx)(`pre`,{className:a(`mt-2 overflow-x-auto rounded bg-red-100 p-2 text-red-800 text-xs`),children:e})]})]});let C=u||p;return(0,_.jsx)(`div`,{className:a(`size-full`,t),"data-streamdown":`mermaid`,ref:S,children:(0,_.jsx)(AI,{className:a(r?`size-full overflow-hidden`:`overflow-hidden`,t),fullscreen:r,maxZoom:3,minZoom:.5,showControls:i,zoomStep:.1,children:(0,_.jsx)(`div`,{"aria-label":`Mermaid chart`,className:a(`flex justify-center`,r?`size-full items-center`:null),dangerouslySetInnerHTML:{__html:C},role:`img`})})})},MI=Object.defineProperty,NI=Object.getOwnPropertyDescriptor,PI=Object.getOwnPropertyNames,FI=Object.prototype.hasOwnProperty,II=(e,t)=>{let n={};for(var r in e)MI(n,r,{get:e[r],enumerable:!0});return t||MI(n,Symbol.toStringTag,{value:`Module`}),n},LI=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var i=PI(t),a=0,o=i.length,s;a<o;a++)s=i[a],!FI.call(e,s)&&s!==n&&MI(e,s,{get:(e=>t[e]).bind(null,s),enumerable:!(r=NI(t,s))||r.enumerable});return e},RI=(e,t,n)=>(LI(e,t,`default`),n&&LI(n,t,`default`)),zI=[{id:`abap`,name:`ABAP`,import:(()=>$(()=>import(`./abap-9R7RjkQK.js`),[]))},{id:`actionscript-3`,name:`ActionScript`,import:(()=>$(()=>import(`./actionscript-3-CNowah7a.js`),[]))},{id:`ada`,name:`Ada`,import:(()=>$(()=>import(`./ada-D5HmrmpD.js`),[]))},{id:`angular-html`,name:`Angular HTML`,import:(()=>$(()=>import(`./angular-html-DlSp9HPG.js`).then(e=>e.n),__vite__mapDeps([2,1,3,4,5])))},{id:`angular-ts`,name:`Angular TypeScript`,import:(()=>$(()=>import(`./angular-ts-B29Ypg6B.js`),__vite__mapDeps([6,2,1,3,4,5,7])))},{id:`apache`,name:`Apache Conf`,import:(()=>$(()=>import(`./apache-D37U8o0r.js`),[]))},{id:`apex`,name:`Apex`,import:(()=>$(()=>import(`./apex-CszkG4lQ.js`),[]))},{id:`apl`,name:`APL`,import:(()=>$(()=>import(`./apl-BASZ7uB_.js`),__vite__mapDeps([8,4,1,3,5,9,10,11])))},{id:`applescript`,name:`AppleScript`,import:(()=>$(()=>import(`./applescript-Ajt9gmC_.js`),[]))},{id:`ara`,name:`Ara`,import:(()=>$(()=>import(`./ara-DpGk8XWf.js`),[]))},{id:`asciidoc`,name:`AsciiDoc`,aliases:[`adoc`],import:(()=>$(()=>import(`./asciidoc-BdDORSgx.js`),[]))},{id:`asm`,name:`Assembly`,import:(()=>$(()=>import(`./asm-DGLRM3OU.js`),[]))},{id:`astro`,name:`Astro`,import:(()=>$(()=>import(`./astro-l-XABzN2.js`),__vite__mapDeps([12,4,1,5,9,13,14,15])))},{id:`awk`,name:`AWK`,import:(()=>$(()=>import(`./awk-B-J9te9x.js`),[]))},{id:`ballerina`,name:`Ballerina`,import:(()=>$(()=>import(`./ballerina-CZ8CAKmi.js`),[]))},{id:`bat`,name:`Batch File`,aliases:[`batch`],import:(()=>$(()=>import(`./bat-fNtaIqKE.js`),[]))},{id:`beancount`,name:`Beancount`,import:(()=>$(()=>import(`./beancount-9imagnS2.js`),[]))},{id:`berry`,name:`Berry`,aliases:[`be`],import:(()=>$(()=>import(`./berry-QTBYpUPn.js`),[]))},{id:`bibtex`,name:`BibTeX`,import:(()=>$(()=>import(`./bibtex-CzFWvn9u.js`),[]))},{id:`bicep`,name:`Bicep`,import:(()=>$(()=>import(`./bicep-DLWEubga.js`),[]))},{id:`bird2`,name:`BIRD2 Configuration`,aliases:[`bird`],import:(()=>$(()=>import(`./bird2-VVa6lZ01.js`),[]))},{id:`blade`,name:`Blade`,import:(()=>$(()=>import(`./blade-B3_bxlV2.js`),__vite__mapDeps([16,4,1,17,3,5,9,18,10,11])))},{id:`bsl`,name:`1C (Enterprise)`,aliases:[`1c`],import:(()=>$(()=>import(`./bsl-D3u1l2dW.js`),__vite__mapDeps([19,20])))},{id:`c`,name:`C`,import:(()=>$(()=>import(`./c-CgTSul4N.js`).then(e=>e.n),__vite__mapDeps([21,1])))},{id:`c3`,name:`C3`,import:(()=>$(()=>import(`./c3-SmmwBAzR.js`),[]))},{id:`cadence`,name:`Cadence`,aliases:[`cdc`],import:(()=>$(()=>import(`./cadence-DVNAI4pJ.js`),[]))},{id:`cairo`,name:`Cairo`,import:(()=>$(()=>import(`./cairo-CoQzhJ_o.js`),__vite__mapDeps([22,23])))},{id:`clarity`,name:`Clarity`,import:(()=>$(()=>import(`./clarity-BJs8u8xG.js`),[]))},{id:`clojure`,name:`Clojure`,aliases:[`clj`],import:(()=>$(()=>import(`./clojure-DpYoDXXl.js`),[]))},{id:`cmake`,name:`CMake`,import:(()=>$(()=>import(`./cmake-CdseusyP.js`),[]))},{id:`cobol`,name:`COBOL`,import:(()=>$(()=>import(`./cobol-D_kesMA-.js`),__vite__mapDeps([24,3,1,4,5,11])))},{id:`codeowners`,name:`CODEOWNERS`,import:(()=>$(()=>import(`./codeowners-5EAeZxPo.js`),[]))},{id:`codeql`,name:`CodeQL`,aliases:[`ql`],import:(()=>$(()=>import(`./codeql-OkUuMGe9.js`),[]))},{id:`coffee`,name:`CoffeeScript`,aliases:[`coffeescript`],import:(()=>$(()=>import(`./coffee-DF15_0rk.js`),__vite__mapDeps([25,5,1])))},{id:`common-lisp`,name:`Common Lisp`,aliases:[`lisp`],import:(()=>$(()=>import(`./common-lisp-DCRDlc4V.js`),[]))},{id:`coq`,name:`Coq`,import:(()=>$(()=>import(`./coq-acwo70uY.js`),[]))},{id:`cpp`,name:`C++`,aliases:[`c++`],import:(()=>$(()=>import(`./cpp-Cudwe5mG.js`).then(e=>e.n),__vite__mapDeps([26,1,27,21,28,18])))},{id:`crystal`,name:`Crystal`,import:(()=>$(()=>import(`./crystal-DV9Nijjb.js`),__vite__mapDeps([29,21,1,4,3,5,30,18])))},{id:`csharp`,name:`C#`,aliases:[`c#`,`cs`],import:(()=>$(()=>import(`./csharp-Cqz84DXU.js`),[]))},{id:`css`,name:`CSS`,import:(()=>$(()=>import(`./css-Dr0v2l-V.js`).then(e=>e.n),__vite__mapDeps([4,1])))},{id:`csv`,name:`CSV`,import:(()=>$(()=>import(`./csv-CqpUSPyF.js`),[]))},{id:`cue`,name:`CUE`,import:(()=>$(()=>import(`./cue-D4-Hq7Jx.js`),[]))},{id:`cypher`,name:`Cypher`,aliases:[`cql`],import:(()=>$(()=>import(`./cypher-CXMVfSpG.js`),[]))},{id:`d`,name:`D`,import:(()=>$(()=>import(`./d-Cc_KoyiC.js`),[]))},{id:`dart`,name:`Dart`,import:(()=>$(()=>import(`./dart-BIyV3H7V.js`),[]))},{id:`dax`,name:`DAX`,import:(()=>$(()=>import(`./dax-DtoJMuz5.js`),[]))},{id:`desktop`,name:`Desktop`,import:(()=>$(()=>import(`./desktop-BkIJ2CMP.js`),[]))},{id:`diff`,name:`Diff`,import:(()=>$(()=>import(`./diff-RUsawely.js`),[]))},{id:`docker`,name:`Dockerfile`,aliases:[`dockerfile`],import:(()=>$(()=>import(`./docker-CDpVZYy7.js`),[]))},{id:`dotenv`,name:`dotEnv`,import:(()=>$(()=>import(`./dotenv-DWnlamm2.js`),[]))},{id:`dream-maker`,name:`Dream Maker`,import:(()=>$(()=>import(`./dream-maker-MNBsfIGU.js`),[]))},{id:`edge`,name:`Edge`,import:(()=>$(()=>import(`./edge-BosfXYh1.js`),__vite__mapDeps([31,17,3,1,4,5,15])))},{id:`elixir`,name:`Elixir`,import:(()=>$(()=>import(`./elixir-Dw_vsdUl.js`),__vite__mapDeps([32,3,1,4,5])))},{id:`elm`,name:`Elm`,import:(()=>$(()=>import(`./elm-DPfFNNkG.js`),__vite__mapDeps([33,27,1,21])))},{id:`emacs-lisp`,name:`Emacs Lisp`,aliases:[`elisp`],import:(()=>$(()=>import(`./emacs-lisp-CVlPXEEa.js`),[]))},{id:`erb`,name:`ERB`,import:(()=>$(()=>import(`./erb-DZuoCU5t.js`),__vite__mapDeps([34,3,1,4,5,35,21,26,27,28,18,36,37,14,15,38,39,30,10,11,40])))},{id:`erlang`,name:`Erlang`,aliases:[`erl`],import:(()=>$(()=>import(`./erlang-CqHCISqs.js`),__vite__mapDeps([41,42])))},{id:`fennel`,name:`Fennel`,import:(()=>$(()=>import(`./fennel-BsP4yvxI.js`),[]))},{id:`fish`,name:`Fish`,import:(()=>$(()=>import(`./fish-CimYqIk1.js`),[]))},{id:`fluent`,name:`Fluent`,aliases:[`ftl`],import:(()=>$(()=>import(`./fluent-O-Iic89O.js`),[]))},{id:`fortran-fixed-form`,name:`Fortran (Fixed Form)`,aliases:[`f`,`for`,`f77`],import:(()=>$(()=>import(`./fortran-fixed-form-60ZQAHDk.js`),__vite__mapDeps([43,44])))},{id:`fortran-free-form`,name:`Fortran (Free Form)`,aliases:[`f90`,`f95`,`f03`,`f08`,`f18`],import:(()=>$(()=>import(`./fortran-free-form-BVNtEstX.js`),[]))},{id:`fsharp`,name:`F#`,aliases:[`f#`,`fs`],import:(()=>$(()=>import(`./fsharp-Ch5ZVinn.js`),__vite__mapDeps([45,42])))},{id:`gdresource`,name:`GDResource`,aliases:[`tscn`,`tres`],import:(()=>$(()=>import(`./gdresource-CqNLhJW1.js`),__vite__mapDeps([46,47,48])))},{id:`gdscript`,name:`GDScript`,aliases:[`gd`],import:(()=>$(()=>import(`./gdscript-D-FJCTl3.js`),[]))},{id:`gdshader`,name:`GDShader`,import:(()=>$(()=>import(`./gdshader-Czvzt8dR.js`),[]))},{id:`genie`,name:`Genie`,import:(()=>$(()=>import(`./genie-Mnf_jXpg.js`),[]))},{id:`gherkin`,name:`Gherkin`,import:(()=>$(()=>import(`./gherkin-DzkYuFEO.js`),[]))},{id:`git-commit`,name:`Git Commit Message`,import:(()=>$(()=>import(`./git-commit-CSWECvqq.js`),__vite__mapDeps([49,50])))},{id:`git-rebase`,name:`Git Rebase Message`,import:(()=>$(()=>import(`./git-rebase-MUvuytPe.js`),__vite__mapDeps([51,30,1])))},{id:`gleam`,name:`Gleam`,import:(()=>$(()=>import(`./gleam-MAXpOqqF.js`),[]))},{id:`glimmer-js`,name:`Glimmer JS`,aliases:[`gjs`],import:(()=>$(()=>import(`./glimmer-js-HDDEErW7.js`),__vite__mapDeps([52,4,1,3,5,15])))},{id:`glimmer-ts`,name:`Glimmer TS`,aliases:[`gts`],import:(()=>$(()=>import(`./glimmer-ts-Dq0_BflX.js`),__vite__mapDeps([53,4,1,3,5,15])))},{id:`glsl`,name:`GLSL`,import:(()=>$(()=>import(`./glsl-C4rvog10.js`).then(e=>e.n),__vite__mapDeps([27,1,21])))},{id:`gn`,name:`GN`,import:(()=>$(()=>import(`./gn-BNADkWgR.js`),[]))},{id:`gnuplot`,name:`Gnuplot`,import:(()=>$(()=>import(`./gnuplot-BRQvwTQM.js`),[]))},{id:`go`,name:`Go`,import:(()=>$(()=>import(`./go-D6k5URxL.js`),[]))},{id:`graphql`,name:`GraphQL`,aliases:[`gql`],import:(()=>$(()=>import(`./graphql-Dg0Ewf8Q.js`).then(e=>e.n),__vite__mapDeps([36,1,5,37,14,15])))},{id:`groovy`,name:`Groovy`,import:(()=>$(()=>import(`./groovy-CxG1cXrE.js`),[]))},{id:`hack`,name:`Hack`,import:(()=>$(()=>import(`./hack-DjE76gIx.js`),__vite__mapDeps([54,3,1,4,5,18])))},{id:`haml`,name:`Ruby Haml`,import:(()=>$(()=>import(`./haml-DyIc_iO2.js`).then(e=>e.n),__vite__mapDeps([38,1,4,5])))},{id:`handlebars`,name:`Handlebars`,aliases:[`hbs`],import:(()=>$(()=>import(`./handlebars-DQ4X08Zf.js`),__vite__mapDeps([55,4,1,3,5,40])))},{id:`haskell`,name:`Haskell`,aliases:[`hs`],import:(()=>$(()=>import(`./haskell-BZ8bGMYA.js`),[]))},{id:`haxe`,name:`Haxe`,import:(()=>$(()=>import(`./haxe-1eAUKQ0B.js`),[]))},{id:`hcl`,name:`HashiCorp HCL`,import:(()=>$(()=>import(`./hcl-DQqvKq2I.js`),[]))},{id:`hjson`,name:`Hjson`,import:(()=>$(()=>import(`./hjson-DNWMSWLN.js`),[]))},{id:`hlsl`,name:`HLSL`,import:(()=>$(()=>import(`./hlsl-Df5oFh9i.js`),[]))},{id:`html`,name:`HTML`,import:(()=>$(()=>import(`./html-GfHBuoLs.js`).then(e=>e.n),__vite__mapDeps([3,1,4,5])))},{id:`html-derivative`,name:`HTML (Derivative)`,import:(()=>$(()=>import(`./html-derivative-ChSmSZXY.js`),__vite__mapDeps([17,3,1,4,5])))},{id:`http`,name:`HTTP`,import:(()=>$(()=>import(`./http-DMTBhQm8.js`),__vite__mapDeps([56,36,1,5,37,14,15,9,30,10,11])))},{id:`hurl`,name:`Hurl`,import:(()=>$(()=>import(`./hurl-XIpACwjS.js`),__vite__mapDeps([57,58,36,1,5,37,14,15,10,11])))},{id:`hxml`,name:`HXML`,import:(()=>$(()=>import(`./hxml-PnV_FpS-.js`),__vite__mapDeps([59,60])))},{id:`hy`,name:`Hy`,import:(()=>$(()=>import(`./hy-DaILHjW8.js`),[]))},{id:`imba`,name:`Imba`,import:(()=>$(()=>import(`./imba-BA6_JyKt.js`),[]))},{id:`ini`,name:`INI`,aliases:[`properties`],import:(()=>$(()=>import(`./ini-DqXMcqXm.js`),[]))},{id:`java`,name:`Java`,import:(()=>$(()=>import(`./java-Ds1cyVrp.js`).then(e=>e.n),__vite__mapDeps([11,1])))},{id:`javascript`,name:`JavaScript`,aliases:[`js`,`cjs`,`mjs`],import:(()=>$(()=>import(`./javascript-Cx8CXBJR.js`).then(e=>e.n),__vite__mapDeps([5,1])))},{id:`jinja`,name:`Jinja`,import:(()=>$(()=>import(`./jinja-8ATGhxJO.js`),__vite__mapDeps([61,3,1,4,5])))},{id:`jison`,name:`Jison`,import:(()=>$(()=>import(`./jison-CSsYnr7O.js`),__vite__mapDeps([62,5,1])))},{id:`json`,name:`JSON`,import:(()=>$(()=>import(`./json-CY14kIzN.js`).then(e=>e.n),__vite__mapDeps([9,1])))},{id:`json5`,name:`JSON5`,import:(()=>$(()=>import(`./json5-Cus7zL-r.js`),[]))},{id:`jsonc`,name:`JSON with Comments`,import:(()=>$(()=>import(`./jsonc-RzqrtWTz.js`),[]))},{id:`jsonl`,name:`JSON Lines`,import:(()=>$(()=>import(`./jsonl-CLcLUtvq.js`),[]))},{id:`jsonnet`,name:`Jsonnet`,import:(()=>$(()=>import(`./jsonnet--7yRuAzt.js`),[]))},{id:`jssm`,name:`JSSM`,aliases:[`fsl`],import:(()=>$(()=>import(`./jssm-Cid5Rr2Y.js`),[]))},{id:`jsx`,name:`JSX`,import:(()=>$(()=>import(`./jsx-DmH5dwMF.js`).then(e=>e.n),__vite__mapDeps([37,1])))},{id:`julia`,name:`Julia`,aliases:[`jl`],import:(()=>$(()=>import(`./julia-vjG00jwO.js`),__vite__mapDeps([63,26,1,27,21,28,18,5,23,64])))},{id:`just`,name:`Just`,import:(()=>$(()=>import(`./just-C7G3KFgN.js`),__vite__mapDeps([65,5,1,66,4,3,18,10,11,23,35,21,26,27,28,36,37,14,15,38,39,30,40])))},{id:`kdl`,name:`KDL`,import:(()=>$(()=>import(`./kdl-D2MbAIKj.js`),[]))},{id:`kotlin`,name:`Kotlin`,aliases:[`kt`,`kts`],import:(()=>$(()=>import(`./kotlin-fpq87Jdo.js`),[]))},{id:`kusto`,name:`Kusto`,aliases:[`kql`],import:(()=>$(()=>import(`./kusto-B1r4va-8.js`),[]))},{id:`latex`,name:`LaTeX`,import:(()=>$(()=>import(`./latex-D8-NgtPj.js`),__vite__mapDeps([67,68,64,1])))},{id:`lean`,name:`Lean 4`,aliases:[`lean4`],import:(()=>$(()=>import(`./lean-B9Xp-kaJ.js`),[]))},{id:`less`,name:`Less`,import:(()=>$(()=>import(`./less-BKjOc0Gl.js`),[]))},{id:`liquid`,name:`Liquid`,import:(()=>$(()=>import(`./liquid-D2m0XXrV.js`),__vite__mapDeps([69,4,1,3,5,9])))},{id:`llvm`,name:`LLVM IR`,import:(()=>$(()=>import(`./llvm-XDy97SdL.js`),[]))},{id:`log`,name:`Log file`,import:(()=>$(()=>import(`./log-tjGJZ7jx.js`),[]))},{id:`logo`,name:`Logo`,import:(()=>$(()=>import(`./logo-rCQwad-6.js`),[]))},{id:`lua`,name:`Lua`,import:(()=>$(()=>import(`./lua-BeSXusec.js`).then(e=>e.n),__vite__mapDeps([39,1,21])))},{id:`luau`,name:`Luau`,import:(()=>$(()=>import(`./luau-C0wE4YeK.js`),[]))},{id:`make`,name:`Makefile`,aliases:[`makefile`],import:(()=>$(()=>import(`./make-DZENZd8z.js`),[]))},{id:`markdown`,name:`Markdown`,aliases:[`md`],import:(()=>$(()=>import(`./markdown-CbgVmtS5.js`),[]))},{id:`marko`,name:`Marko`,import:(()=>$(()=>import(`./marko-DPnRthJQ.js`),__vite__mapDeps([70,4,1,71,7,15])))},{id:`matlab`,name:`MATLAB`,import:(()=>$(()=>import(`./matlab-BJwkjxyL.js`),[]))},{id:`mdc`,name:`MDC`,import:(()=>$(()=>import(`./mdc-BLdFHYKv.js`),__vite__mapDeps([72,17,3,1,4,5,42,40])))},{id:`mdx`,name:`MDX`,import:(()=>$(()=>import(`./mdx-BvkytFG9.js`),[]))},{id:`mermaid`,name:`Mermaid`,aliases:[`mmd`],import:(()=>$(()=>import(`./mermaid-Ctx7uNrT.js`),[]))},{id:`mipsasm`,name:`MIPS Assembly`,aliases:[`mips`],import:(()=>$(()=>import(`./mipsasm-ByaU0dEX.js`),[]))},{id:`mojo`,name:`Mojo`,import:(()=>$(()=>import(`./mojo-CqhYERP_.js`),[]))},{id:`moonbit`,name:`MoonBit`,aliases:[`mbt`,`mbti`],import:(()=>$(()=>import(`./moonbit-C4BfwLm6.js`),[]))},{id:`move`,name:`Move`,import:(()=>$(()=>import(`./move-DOj5FawL.js`),[]))},{id:`narrat`,name:`Narrat Language`,aliases:[`nar`],import:(()=>$(()=>import(`./narrat-CDHYPJWr.js`),[]))},{id:`nextflow`,name:`Nextflow`,aliases:[`nf`],import:(()=>$(()=>import(`./nextflow-c8YCPRRb.js`),__vite__mapDeps([73,74])))},{id:`nextflow-groovy`,name:`Nextflow Groovy`,import:(()=>$(()=>import(`./nextflow-groovy-o7ZjyFmf.js`),[]))},{id:`nginx`,name:`Nginx`,import:(()=>$(()=>import(`./nginx-u-hq5m-a.js`),__vite__mapDeps([75,39,1,21])))},{id:`nim`,name:`Nim`,import:(()=>$(()=>import(`./nim-B5b6_jZr.js`),__vite__mapDeps([76,21,1,4,27,3,5,42,10,11])))},{id:`nix`,name:`Nix`,import:(()=>$(()=>import(`./nix-Csr5leD-.js`),[]))},{id:`nushell`,name:`nushell`,aliases:[`nu`],import:(()=>$(()=>import(`./nushell-IZVQdI7Z.js`),[]))},{id:`objective-c`,name:`Objective-C`,aliases:[`objc`],import:(()=>$(()=>import(`./objective-c-DD1i5sf2.js`),[]))},{id:`objective-cpp`,name:`Objective-C++`,import:(()=>$(()=>import(`./objective-cpp-CtzOCe2w.js`),[]))},{id:`ocaml`,name:`OCaml`,import:(()=>$(()=>import(`./ocaml-BlMDMjEj.js`),[]))},{id:`odin`,name:`Odin`,import:(()=>$(()=>import(`./odin-CoWSDSNi.js`),[]))},{id:`openscad`,name:`OpenSCAD`,aliases:[`scad`],import:(()=>$(()=>import(`./openscad-D3gRRPUh.js`),[]))},{id:`pascal`,name:`Pascal`,import:(()=>$(()=>import(`./pascal-G3gJIkHz.js`),[]))},{id:`perl`,name:`Perl`,import:(()=>$(()=>import(`./perl-DdF12AsD.js`),__vite__mapDeps([66,4,1,3,5,18,10,11])))},{id:`php`,name:`PHP`,import:(()=>$(()=>import(`./php-CyQZnE0l.js`),__vite__mapDeps([77,4,1,3,5,9,18,10,11])))},{id:`pkl`,name:`Pkl`,import:(()=>$(()=>import(`./pkl-DdsryWcC.js`),[]))},{id:`plsql`,name:`PL/SQL`,import:(()=>$(()=>import(`./plsql-C2yEtnCG.js`),[]))},{id:`po`,name:`Gettext PO`,aliases:[`pot`,`potx`],import:(()=>$(()=>import(`./po-Dy7ytuR1.js`),[]))},{id:`polar`,name:`Polar`,import:(()=>$(()=>import(`./polar-CjLVWIyd.js`),[]))},{id:`postcss`,name:`PostCSS`,import:(()=>$(()=>import(`./postcss-DiNtjF5e.js`),[]))},{id:`powerquery`,name:`PowerQuery`,import:(()=>$(()=>import(`./powerquery-iC4Ra9LJ.js`),[]))},{id:`powershell`,name:`PowerShell`,aliases:[`ps`,`ps1`],import:(()=>$(()=>import(`./powershell-Ch2YpFAx.js`),[]))},{id:`prisma`,name:`Prisma`,import:(()=>$(()=>import(`./prisma-HWctQCpn.js`),[]))},{id:`prolog`,name:`Prolog`,import:(()=>$(()=>import(`./prolog-DHAsH4Hf.js`),[]))},{id:`proto`,name:`Protocol Buffer 3`,aliases:[`protobuf`],import:(()=>$(()=>import(`./proto-mTghX89X.js`),[]))},{id:`pug`,name:`Pug`,aliases:[`jade`],import:(()=>$(()=>import(`./pug-HwoxZo9M.js`),__vite__mapDeps([78,4,1,3,5])))},{id:`puppet`,name:`Puppet`,import:(()=>$(()=>import(`./puppet-D1Zcnrr5.js`),[]))},{id:`purescript`,name:`PureScript`,import:(()=>$(()=>import(`./purescript-s82m5f0Y.js`),[]))},{id:`python`,name:`Python`,aliases:[`py`],import:(()=>$(()=>import(`./python-BhsI1K6K.js`),[]))},{id:`qml`,name:`QML`,import:(()=>$(()=>import(`./qml-CysuucQ6.js`),__vite__mapDeps([79,5,1])))},{id:`qmldir`,name:`QML Directory`,import:(()=>$(()=>import(`./qmldir-Bzkc2Njy.js`),[]))},{id:`qss`,name:`Qt Style Sheets`,import:(()=>$(()=>import(`./qss-CKbozdtF.js`),[]))},{id:`r`,name:`R`,import:(()=>$(()=>import(`./r-BKej5r_k.js`).then(e=>e.n),__vite__mapDeps([64,1])))},{id:`racket`,name:`Racket`,import:(()=>$(()=>import(`./racket-CUDoXUwy.js`),[]))},{id:`raku`,name:`Raku`,aliases:[`perl6`],import:(()=>$(()=>import(`./raku-XPAjN9OU.js`),[]))},{id:`razor`,name:`ASP.NET Razor`,import:(()=>$(()=>import(`./razor-ZpEr_C9H.js`),__vite__mapDeps([80,81,3,1,4,5])))},{id:`reg`,name:`Windows Registry Script`,import:(()=>$(()=>import(`./reg-B0B_plbq.js`),[]))},{id:`regexp`,name:`RegExp`,aliases:[`regex`],import:(()=>$(()=>import(`./regexp-CK-1EP63.js`).then(e=>e.n),__vite__mapDeps([28,1])))},{id:`rel`,name:`Rel`,import:(()=>$(()=>import(`./rel-DhoFe2Y7.js`),[]))},{id:`riscv`,name:`RISC-V`,import:(()=>$(()=>import(`./riscv-CKx_Jisq.js`),[]))},{id:`ron`,name:`RON`,import:(()=>$(()=>import(`./ron-qyvgw9vu.js`),[]))},{id:`rosmsg`,name:`ROS Interface`,import:(()=>$(()=>import(`./rosmsg-Dy_ItAfo.js`),[]))},{id:`rst`,name:`reStructuredText`,import:(()=>$(()=>import(`./rst-CjO4XFKz.js`),__vite__mapDeps([82,83,26,1,27,21,28,18,17,3,4,5,23,35,36,37,14,15,38,39,30,10,11,40])))},{id:`ruby`,name:`Ruby`,aliases:[`rb`],import:(()=>$(()=>import(`./ruby-CZgIYPlP.js`),__vite__mapDeps([35,21,1,26,27,28,18,4,36,5,37,14,15,38,3,39,30,10,11,40])))},{id:`rust`,name:`Rust`,aliases:[`rs`],import:(()=>$(()=>import(`./rust-CNEVkiWF.js`),[]))},{id:`sas`,name:`SAS`,import:(()=>$(()=>import(`./sas-DPGT0TjQ.js`),__vite__mapDeps([84,18,1])))},{id:`sass`,name:`Sass`,import:(()=>$(()=>import(`./sass-D2nye32F.js`),[]))},{id:`scala`,name:`Scala`,import:(()=>$(()=>import(`./scala-B8greAnE.js`),[]))},{id:`scheme`,name:`Scheme`,import:(()=>$(()=>import(`./scheme-Ci_aquns.js`),[]))},{id:`scss`,name:`SCSS`,import:(()=>$(()=>import(`./scss-YARKxu2i.js`).then(e=>e.n),__vite__mapDeps([7,1,4])))},{id:`sdbl`,name:`1C (Query)`,aliases:[`1c-query`],import:(()=>$(()=>import(`./sdbl-D4tJqBiC.js`),[]))},{id:`shaderlab`,name:`ShaderLab`,aliases:[`shader`],import:(()=>$(()=>import(`./shaderlab-JWcsxey4.js`),__vite__mapDeps([85,86])))},{id:`shellscript`,name:`Shell`,aliases:[`bash`,`sh`,`shell`,`zsh`],import:(()=>$(()=>import(`./shellscript-CxhArCCJ.js`).then(e=>e.n),__vite__mapDeps([30,1])))},{id:`shellsession`,name:`Shell Session`,aliases:[`console`],import:(()=>$(()=>import(`./shellsession-DYmuifdt.js`),__vite__mapDeps([87,30,1])))},{id:`smalltalk`,name:`Smalltalk`,import:(()=>$(()=>import(`./smalltalk-BwSireXb.js`),[]))},{id:`solidity`,name:`Solidity`,import:(()=>$(()=>import(`./solidity-CIUlntDs.js`),[]))},{id:`soy`,name:`Closure Templates`,aliases:[`closure-templates`],import:(()=>$(()=>import(`./soy-7iHZG9Jz.js`),__vite__mapDeps([88,3,1,4,5])))},{id:`sparql`,name:`SPARQL`,import:(()=>$(()=>import(`./sparql-BGRSvFxd.js`),__vite__mapDeps([89,90])))},{id:`splunk`,name:`Splunk Query Language`,aliases:[`spl`],import:(()=>$(()=>import(`./splunk-DueVPk5k.js`),[]))},{id:`sql`,name:`SQL`,import:(()=>$(()=>import(`./sql-Q6zkgi_w.js`).then(e=>e.n),__vite__mapDeps([18,1])))},{id:`ssh-config`,name:`SSH Config`,import:(()=>$(()=>import(`./ssh-config-DKIMErlp.js`),[]))},{id:`stata`,name:`Stata`,import:(()=>$(()=>import(`./stata-lXN9BRaz.js`),__vite__mapDeps([91,18,1])))},{id:`stylus`,name:`Stylus`,aliases:[`styl`],import:(()=>$(()=>import(`./stylus-oqceM0yt.js`),[]))},{id:`surrealql`,name:`SurrealQL`,aliases:[`surql`],import:(()=>$(()=>import(`./surrealql-l0SGzwOs.js`),__vite__mapDeps([92,5,1])))},{id:`svelte`,name:`Svelte`,import:(()=>$(()=>import(`./svelte-BM89dRu0.js`),__vite__mapDeps([93,4,1,5,13,15])))},{id:`swift`,name:`Swift`,import:(()=>$(()=>import(`./swift-foA31xPc.js`),[]))},{id:`system-verilog`,name:`SystemVerilog`,import:(()=>$(()=>import(`./system-verilog-CCSGcM60.js`),[]))},{id:`systemd`,name:`Systemd Units`,import:(()=>$(()=>import(`./systemd-BymS_eIJ.js`),[]))},{id:`talonscript`,name:`TalonScript`,aliases:[`talon`],import:(()=>$(()=>import(`./talonscript-Ccc0122j.js`),[]))},{id:`tasl`,name:`Tasl`,import:(()=>$(()=>import(`./tasl-o38sfjeU.js`),[]))},{id:`tcl`,name:`Tcl`,import:(()=>$(()=>import(`./tcl-DISPE-5Q.js`),[]))},{id:`templ`,name:`Templ`,import:(()=>$(()=>import(`./templ-D1GoDFsp.js`),__vite__mapDeps([94,4,1,95,5])))},{id:`terraform`,name:`Terraform`,aliases:[`tf`,`tfvars`],import:(()=>$(()=>import(`./terraform-V85Kewcz.js`),[]))},{id:`tex`,name:`TeX`,import:(()=>$(()=>import(`./tex-CxEkh6NI.js`),__vite__mapDeps([68,64,1])))},{id:`toml`,name:`TOML`,import:(()=>$(()=>import(`./toml-uEjeW8NC.js`),[]))},{id:`ts-tags`,name:`TypeScript with Tags`,aliases:[`lit`],import:(()=>$(()=>import(`./ts-tags-B88Nbzcl.js`),__vite__mapDeps([96,4,1,27,21,3,5,18,15,10,11])))},{id:`tsv`,name:`TSV`,import:(()=>$(()=>import(`./tsv-DjGwUc04.js`),[]))},{id:`tsx`,name:`TSX`,import:(()=>$(()=>import(`./tsx-5O-M05V0.js`).then(e=>e.n),__vite__mapDeps([14,1])))},{id:`turtle`,name:`Turtle`,import:(()=>$(()=>import(`./turtle-PTxTluYn.js`),[]))},{id:`twig`,name:`Twig`,import:(()=>$(()=>import(`./twig-B3Kws0Fb.js`),__vite__mapDeps([97,4,1,5,77,3,9,18,10,11,23,35,21,26,27,28,36,37,14,15,38,39,30,40,7])))},{id:`typescript`,name:`TypeScript`,aliases:[`ts`,`cts`,`mts`],import:(()=>$(()=>import(`./typescript-hRweav8r.js`).then(e=>e.n),__vite__mapDeps([15,1])))},{id:`typespec`,name:`TypeSpec`,aliases:[`tsp`],import:(()=>$(()=>import(`./typespec-N7-U_jBZ.js`),[]))},{id:`typst`,name:`Typst`,aliases:[`typ`],import:(()=>$(()=>import(`./typst-DSQh9HII.js`),[]))},{id:`v`,name:`V`,import:(()=>$(()=>import(`./v-obK6h_YW.js`),[]))},{id:`vala`,name:`Vala`,import:(()=>$(()=>import(`./vala-DXa9jSo-.js`),[]))},{id:`vb`,name:`Visual Basic`,aliases:[`cmd`],import:(()=>$(()=>import(`./vb-DEPbtYq-.js`),[]))},{id:`verilog`,name:`Verilog`,import:(()=>$(()=>import(`./verilog-Bs-185hK.js`),[]))},{id:`vhdl`,name:`VHDL`,import:(()=>$(()=>import(`./vhdl-CBukgB2Z.js`),[]))},{id:`viml`,name:`Vim Script`,aliases:[`vim`,`vimscript`],import:(()=>$(()=>import(`./viml-C1cRY0x6.js`),[]))},{id:`vue`,name:`Vue`,import:(()=>$(()=>import(`./vue-CT36qSUr.js`),__vite__mapDeps([98,4,1,17,3,5,9,15])))},{id:`vue-html`,name:`Vue HTML`,import:(()=>$(()=>import(`./vue-html-bJyjqZnI.js`),__vite__mapDeps([99,5,1])))},{id:`vue-vine`,name:`Vue Vine`,import:(()=>$(()=>import(`./vue-vine-BLqV15Pm.js`),__vite__mapDeps([100,4,1,5,71,13,7,101])))},{id:`vyper`,name:`Vyper`,aliases:[`vy`],import:(()=>$(()=>import(`./vyper-BxVot6rR.js`),[]))},{id:`wasm`,name:`WebAssembly`,import:(()=>$(()=>import(`./wasm-o5uYkU9G.js`),[]))},{id:`wenyan`,name:`Wenyan`,aliases:[`文言`],import:(()=>$(()=>import(`./wenyan-MnC4h24X.js`),[]))},{id:`wgsl`,name:`WGSL`,import:(()=>$(()=>import(`./wgsl-BgfkHnVi.js`),[]))},{id:`wikitext`,name:`Wikitext`,aliases:[`mediawiki`,`wiki`],import:(()=>$(()=>import(`./wikitext-DCOnP3yk.js`),[]))},{id:`wit`,name:`WebAssembly Interface Types`,import:(()=>$(()=>import(`./wit-5UDEI7sp.js`),[]))},{id:`wolfram`,name:`Wolfram`,aliases:[`wl`],import:(()=>$(()=>import(`./wolfram-vvgPlu2n.js`),[]))},{id:`xml`,name:`XML`,import:(()=>$(()=>import(`./xml-DyJ3D9rW.js`).then(e=>e.n),__vite__mapDeps([10,1,11])))},{id:`xsl`,name:`XSL`,import:(()=>$(()=>import(`./xsl-BOsdDgv_.js`),__vite__mapDeps([102,10,1,11])))},{id:`yaml`,name:`YAML`,aliases:[`yml`],import:(()=>$(()=>import(`./yaml-C-G727Y6.js`).then(e=>e.n),__vite__mapDeps([40,1])))},{id:`zenscript`,name:`ZenScript`,import:(()=>$(()=>import(`./zenscript-BPjqX0BY.js`),[]))},{id:`zig`,name:`Zig`,import:(()=>$(()=>import(`./zig-Bd91oU8r.js`),[]))}],BI=Object.fromEntries(zI.map(e=>[e.id,e.import])),VI=Object.fromEntries(zI.flatMap(e=>e.aliases?.map(t=>[t,e.import])||[])),HI={...BI,...VI},UI=Object.fromEntries([{id:`andromeeda`,displayName:`Andromeeda`,type:`dark`,import:(()=>$(()=>import(`./andromeeda-i_b3g2bn.js`),[]))},{id:`aurora-x`,displayName:`Aurora X`,type:`dark`,import:(()=>$(()=>import(`./aurora-x-DdfqxvM_.js`),[]))},{id:`ayu-dark`,displayName:`Ayu Dark`,type:`dark`,import:(()=>$(()=>import(`./ayu-dark-BdNJk5qF.js`),[]))},{id:`ayu-light`,displayName:`Ayu Light`,type:`light`,import:(()=>$(()=>import(`./ayu-light-DkLNbAkT.js`),[]))},{id:`ayu-mirage`,displayName:`Ayu Mirage`,type:`dark`,import:(()=>$(()=>import(`./ayu-mirage-BoyGjGHX.js`),[]))},{id:`catppuccin-frappe`,displayName:`Catppuccin Frappé`,type:`dark`,import:(()=>$(()=>import(`./catppuccin-frappe-DXCXlnyU.js`),[]))},{id:`catppuccin-latte`,displayName:`Catppuccin Latte`,type:`light`,import:(()=>$(()=>import(`./catppuccin-latte-BXW2qYGv.js`),[]))},{id:`catppuccin-macchiato`,displayName:`Catppuccin Macchiato`,type:`dark`,import:(()=>$(()=>import(`./catppuccin-macchiato--32cesHH.js`),[]))},{id:`catppuccin-mocha`,displayName:`Catppuccin Mocha`,type:`dark`,import:(()=>$(()=>import(`./catppuccin-mocha-BBRFilGN.js`),[]))},{id:`dark-plus`,displayName:`Dark Plus`,type:`dark`,import:(()=>$(()=>import(`./dark-plus-C0kLyDb3.js`),[]))},{id:`dracula`,displayName:`Dracula Theme`,type:`dark`,import:(()=>$(()=>import(`./dracula-QP8aKUFB.js`),[]))},{id:`dracula-soft`,displayName:`Dracula Theme Soft`,type:`dark`,import:(()=>$(()=>import(`./dracula-soft-BNzyYlRI.js`),[]))},{id:`everforest-dark`,displayName:`Everforest Dark`,type:`dark`,import:(()=>$(()=>import(`./everforest-dark-DSK976eP.js`),[]))},{id:`everforest-light`,displayName:`Everforest Light`,type:`light`,import:(()=>$(()=>import(`./everforest-light-BkaBVm1r.js`),[]))},{id:`github-dark`,displayName:`GitHub Dark`,type:`dark`,import:(()=>$(()=>import(`./github-dark-C98YWDhk.js`),[]))},{id:`github-dark-default`,displayName:`GitHub Dark Default`,type:`dark`,import:(()=>$(()=>import(`./github-dark-default-CDGuVkyn.js`),[]))},{id:`github-dark-dimmed`,displayName:`GitHub Dark Dimmed`,type:`dark`,import:(()=>$(()=>import(`./github-dark-dimmed-CarTohA3.js`),[]))},{id:`github-dark-high-contrast`,displayName:`GitHub Dark High Contrast`,type:`dark`,import:(()=>$(()=>import(`./github-dark-high-contrast-CsjOICAd.js`),[]))},{id:`github-light`,displayName:`GitHub Light`,type:`light`,import:(()=>$(()=>import(`./github-light-D17m3GP4.js`),[]))},{id:`github-light-default`,displayName:`GitHub Light Default`,type:`light`,import:(()=>$(()=>import(`./github-light-default-DiMoa1ZI.js`),[]))},{id:`github-light-high-contrast`,displayName:`GitHub Light High Contrast`,type:`light`,import:(()=>$(()=>import(`./github-light-high-contrast-DGwHD8Ty.js`),[]))},{id:`gruvbox-dark-hard`,displayName:`Gruvbox Dark Hard`,type:`dark`,import:(()=>$(()=>import(`./gruvbox-dark-hard-Cnb1fzry.js`),[]))},{id:`gruvbox-dark-medium`,displayName:`Gruvbox Dark Medium`,type:`dark`,import:(()=>$(()=>import(`./gruvbox-dark-medium-Cu5j8v_d.js`),[]))},{id:`gruvbox-dark-soft`,displayName:`Gruvbox Dark Soft`,type:`dark`,import:(()=>$(()=>import(`./gruvbox-dark-soft-BghHDwrM.js`),[]))},{id:`gruvbox-light-hard`,displayName:`Gruvbox Light Hard`,type:`light`,import:(()=>$(()=>import(`./gruvbox-light-hard-BUhLUxUB.js`),[]))},{id:`gruvbox-light-medium`,displayName:`Gruvbox Light Medium`,type:`light`,import:(()=>$(()=>import(`./gruvbox-light-medium-GXeiXGL9.js`),[]))},{id:`gruvbox-light-soft`,displayName:`Gruvbox Light Soft`,type:`light`,import:(()=>$(()=>import(`./gruvbox-light-soft-pTZgKx7j.js`),[]))},{id:`horizon`,displayName:`Horizon`,type:`dark`,import:(()=>$(()=>import(`./horizon-BCbhfxa1.js`),[]))},{id:`horizon-bright`,displayName:`Horizon Bright`,type:`light`,import:(()=>$(()=>import(`./horizon-bright-CXcxBcih.js`),[]))},{id:`houston`,displayName:`Houston`,type:`dark`,import:(()=>$(()=>import(`./houston-DHnjBE42.js`),[]))},{id:`kanagawa-dragon`,displayName:`Kanagawa Dragon`,type:`dark`,import:(()=>$(()=>import(`./kanagawa-dragon-BxDDNs-7.js`),[]))},{id:`kanagawa-lotus`,displayName:`Kanagawa Lotus`,type:`light`,import:(()=>$(()=>import(`./kanagawa-lotus-BQyifewU.js`),[]))},{id:`kanagawa-wave`,displayName:`Kanagawa Wave`,type:`dark`,import:(()=>$(()=>import(`./kanagawa-wave-BsJGVIZT.js`),[]))},{id:`laserwave`,displayName:`LaserWave`,type:`dark`,import:(()=>$(()=>import(`./laserwave-CrjhMkHv.js`),[]))},{id:`light-plus`,displayName:`Light Plus`,type:`light`,import:(()=>$(()=>import(`./light-plus-DFt9HI_B.js`),[]))},{id:`material-theme`,displayName:`Material Theme`,type:`dark`,import:(()=>$(()=>import(`./material-theme-YhiuxyiP.js`),[]))},{id:`material-theme-darker`,displayName:`Material Theme Darker`,type:`dark`,import:(()=>$(()=>import(`./material-theme-darker-CKeuyK7B.js`),[]))},{id:`material-theme-lighter`,displayName:`Material Theme Lighter`,type:`light`,import:(()=>$(()=>import(`./material-theme-lighter-C56RzTfM.js`),[]))},{id:`material-theme-ocean`,displayName:`Material Theme Ocean`,type:`dark`,import:(()=>$(()=>import(`./material-theme-ocean-DUos8xKe.js`),[]))},{id:`material-theme-palenight`,displayName:`Material Theme Palenight`,type:`dark`,import:(()=>$(()=>import(`./material-theme-palenight-CZBKx4B1.js`),[]))},{id:`min-dark`,displayName:`Min Dark`,type:`dark`,import:(()=>$(()=>import(`./min-dark-BA-rwgF3.js`),[]))},{id:`min-light`,displayName:`Min Light`,type:`light`,import:(()=>$(()=>import(`./min-light-DHUVhXnm.js`),[]))},{id:`monokai`,displayName:`Monokai`,type:`dark`,import:(()=>$(()=>import(`./monokai-D3MyQCxG.js`),[]))},{id:`night-owl`,displayName:`Night Owl`,type:`dark`,import:(()=>$(()=>import(`./night-owl-NHZjGVLB.js`),[]))},{id:`night-owl-light`,displayName:`Night Owl Light`,type:`light`,import:(()=>$(()=>import(`./night-owl-light-DcKosvl7.js`),[]))},{id:`nord`,displayName:`Nord`,type:`dark`,import:(()=>$(()=>import(`./nord-DomFMWpF.js`),[]))},{id:`one-dark-pro`,displayName:`One Dark Pro`,type:`dark`,import:(()=>$(()=>import(`./one-dark-pro-DWENJxB_.js`),[]))},{id:`one-light`,displayName:`One Light`,type:`light`,import:(()=>$(()=>import(`./one-light-CEeF6aqP.js`),[]))},{id:`plastic`,displayName:`Plastic`,type:`dark`,import:(()=>$(()=>import(`./plastic-CwUA_4-2.js`),[]))},{id:`poimandres`,displayName:`Poimandres`,type:`dark`,import:(()=>$(()=>import(`./poimandres-u68WOWhl.js`),[]))},{id:`red`,displayName:`Red`,type:`dark`,import:(()=>$(()=>import(`./red-8aRo80UF.js`),[]))},{id:`rose-pine`,displayName:`Rosé Pine`,type:`dark`,import:(()=>$(()=>import(`./rose-pine-R3f76h4_.js`),[]))},{id:`rose-pine-dawn`,displayName:`Rosé Pine Dawn`,type:`light`,import:(()=>$(()=>import(`./rose-pine-dawn-BS09rtpK.js`),[]))},{id:`rose-pine-moon`,displayName:`Rosé Pine Moon`,type:`dark`,import:(()=>$(()=>import(`./rose-pine-moon-B4Q4DiPG.js`),[]))},{id:`slack-dark`,displayName:`Slack Dark`,type:`dark`,import:(()=>$(()=>import(`./slack-dark-BcN7KJ02.js`),[]))},{id:`slack-ochin`,displayName:`Slack Ochin`,type:`light`,import:(()=>$(()=>import(`./slack-ochin-D4iInQ9w.js`),[]))},{id:`snazzy-light`,displayName:`Snazzy Light`,type:`light`,import:(()=>$(()=>import(`./snazzy-light-B45TfPsv.js`),[]))},{id:`solarized-dark`,displayName:`Solarized Dark`,type:`dark`,import:(()=>$(()=>import(`./solarized-dark-8yYW1wLs.js`),[]))},{id:`solarized-light`,displayName:`Solarized Light`,type:`light`,import:(()=>$(()=>import(`./solarized-light-BY3Hr0Ud.js`),[]))},{id:`synthwave-84`,displayName:`Synthwave '84`,type:`dark`,import:(()=>$(()=>import(`./synthwave-84-B002ZU4p.js`),[]))},{id:`tokyo-night`,displayName:`Tokyo Night`,type:`dark`,import:(()=>$(()=>import(`./tokyo-night-BLn5KNCP.js`),[]))},{id:`vesper`,displayName:`Vesper`,type:`dark`,import:(()=>$(()=>import(`./vesper-B7BneC5G.js`),[]))},{id:`vitesse-black`,displayName:`Vitesse Black`,type:`dark`,import:(()=>$(()=>import(`./vitesse-black-D3_12zni.js`),[]))},{id:`vitesse-dark`,displayName:`Vitesse Dark`,type:`dark`,import:(()=>$(()=>import(`./vitesse-dark-B_iF7INE.js`),[]))},{id:`vitesse-light`,displayName:`Vitesse Light`,type:`light`,import:(()=>$(()=>import(`./vitesse-light-DbrrMtxY.js`),[]))}].map(e=>[e.id,e.import])),WI=e({createOnigurumaEngine:()=>vL,getDefaultWasmLoader:()=>_L,loadWasm:()=>dL,setDefaultWasmLoader:()=>gL}),GI=class extends Error{constructor(e){super(e),this.name=`ShikiError`}};function KI(){return 2147483648}function qI(){return typeof performance<`u`?performance.now():Date.now()}var JI=(e,t)=>e+(t-e%t)%t;async function YI(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=KI();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,JI(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:qI,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 XI=Object.defineProperty,ZI=(e,t,n)=>t in e?XI(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,QI=(e,t,n)=>ZI(e,typeof t==`symbol`?t:t+``,n),$I=null;function eL(e){throw new GI(e.UTF8ToString(e.getLastOnigError()))}var tL=class e{constructor(t){QI(this,`utf16Length`),QI(this,`utf8Length`),QI(this,`utf16Value`),QI(this,`utf8Value`),QI(this,`utf16OffsetToUtf8`),QI(this,`utf8OffsetToUtf16`);let n=t.length,r=e._utf8ByteLength(t),i=r!==n,a=i?new Uint32Array(n+1):null;i&&(a[n]=r);let o=i?new Uint32Array(r+1):null;i&&(o[r]=n);let s=new Uint8Array(r),c=0;for(let e=0;e<n;e++){let r=t.charCodeAt(e),l=r,u=!1;if(r>=55296&&r<=56319&&e+1<n){let n=t.charCodeAt(e+1);n>=56320&&n<=57343&&(l=(r-55296<<10)+65536|n-56320,u=!0)}i&&(a[e]=c,u&&(a[e+1]=c),l<=127?o[c+0]=e:l<=2047?(o[c+0]=e,o[c+1]=e):l<=65535?(o[c+0]=e,o[c+1]=e,o[c+2]=e):(o[c+0]=e,o[c+1]=e,o[c+2]=e,o[c+3]=e)),l<=127?s[c++]=l:l<=2047?(s[c++]=192|(l&1984)>>>6,s[c++]=128|(l&63)>>>0):l<=65535?(s[c++]=224|(l&61440)>>>12,s[c++]=128|(l&4032)>>>6,s[c++]=128|(l&63)>>>0):(s[c++]=240|(l&1835008)>>>18,s[c++]=128|(l&258048)>>>12,s[c++]=128|(l&4032)>>>6,s[c++]=128|(l&63)>>>0),u&&e++}this.utf16Length=n,this.utf8Length=r,this.utf16Value=t,this.utf8Value=s,this.utf16OffsetToUtf8=a,this.utf8OffsetToUtf16=o}static _utf8ByteLength(e){let t=0;for(let n=0,r=e.length;n<r;n++){let i=e.charCodeAt(n),a=i,o=!1;if(i>=55296&&i<=56319&&n+1<r){let t=e.charCodeAt(n+1);t>=56320&&t<=57343&&(a=(i-55296<<10)+65536|t-56320,o=!0)}a<=127?t+=1:a<=2047?t+=2:a<=65535?t+=3:t+=4,o&&n++}return t}createString(e){let t=e.omalloc(this.utf8Length);return e.HEAPU8.set(this.utf8Value,t),t}},nL=class e{constructor(t){if(QI(this,`id`,++e.LAST_ID),QI(this,`_onigBinding`),QI(this,`content`),QI(this,`utf16Length`),QI(this,`utf8Length`),QI(this,`utf16OffsetToUtf8`),QI(this,`utf8OffsetToUtf16`),QI(this,`ptr`),!$I)throw new GI(`Must invoke loadWasm first.`);this._onigBinding=$I,this.content=t;let n=new tL(t);this.utf16Length=n.utf16Length,this.utf8Length=n.utf8Length,this.utf16OffsetToUtf8=n.utf16OffsetToUtf8,this.utf8OffsetToUtf16=n.utf8OffsetToUtf16,this.utf8Length<1e4&&!e._sharedPtrInUse?(e._sharedPtr||=$I.omalloc(1e4),e._sharedPtrInUse=!0,$I.HEAPU8.set(n.utf8Value,e._sharedPtr),this.ptr=e._sharedPtr):this.ptr=n.createString($I)}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)}};QI(nL,`LAST_ID`,0),QI(nL,`_sharedPtr`,0),QI(nL,`_sharedPtrInUse`,!1);var rL=nL,iL=class{constructor(e){if(QI(this,`_onigBinding`),QI(this,`_ptr`),!$I)throw new GI(`Must invoke loadWasm first.`);let t=[],n=[];for(let r=0,i=e.length;r<i;r++){let i=new tL(e[r]);t[r]=i.createString($I),n[r]=i.utf8Length}let r=$I.omalloc(4*e.length);$I.HEAPU32.set(t,r/4);let i=$I.omalloc(4*e.length);$I.HEAPU32.set(n,i/4);let a=$I.createOnigScanner(r,i,e.length);for(let n=0,r=e.length;n<r;n++)$I.ofree(t[n]);$I.ofree(i),$I.ofree(r),a===0&&eL($I),this._onigBinding=$I,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 rL(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 aL(e){return typeof e.instantiator==`function`}function oL(e){return typeof e.default==`function`}function sL(e){return e.data!==void 0}function cL(e){return typeof Response<`u`&&e instanceof Response}function lL(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 uL;function dL(e){if(uL)return uL;async function t(){$I=await YI(async t=>{let n=e;return n=await n,typeof n==`function`&&(n=await n(t)),typeof n==`function`&&(n=await n(t)),aL(n)?n=await n.instantiator(t):oL(n)?n=await n.default(t):(sL(n)&&(n=n.data),cL(n)?n=typeof WebAssembly.instantiateStreaming==`function`?await pL(n)(t):await mL(n)(t):lL(n)||n instanceof WebAssembly.Module?n=await fL(n)(t):`default`in n&&n.default instanceof WebAssembly.Module&&(n=await fL(n.default)(t))),`instance`in n&&(n=n.instance),`exports`in n&&(n=n.exports),n})}return uL=t(),uL}function fL(e){return t=>WebAssembly.instantiate(e,t)}function pL(e){return t=>WebAssembly.instantiateStreaming(e,t)}function mL(e){return async t=>{let n=await e.arrayBuffer();return WebAssembly.instantiate(n,t)}}var hL;function gL(e){hL=e}function _L(){return hL}async function vL(e){return e&&await dL(e),{createScanner(e){return new iL(e.map(e=>typeof e==`string`?e:e.source))},createString(e){return new rL(e)}}}var yL=II({});RI(yL,WI);var bL=class extends Error{constructor(e){super(e),this.name=`ShikiError`}};function xL(e){return SL(e)}function SL(e){return Array.isArray(e)?CL(e):e instanceof RegExp?e:typeof e==`object`?wL(e):e}function CL(e){let t=[];for(let n=0,r=e.length;n<r;n++)t[n]=SL(e[n]);return t}function wL(e){let t={};for(let n in e)t[n]=SL(e[n]);return t}function TL(e,...t){return t.forEach(t=>{for(let n in t)e[n]=t[n]}),e}function EL(e){let t=~e.lastIndexOf(`/`)||~e.lastIndexOf(`\\`);return t===0?e:~t===e.length-1?EL(e.substring(0,e.length-1)):e.substr(~t+1)}var DL=/\$(\d+)|\${(\d+):\/(downcase|upcase)}/g,OL=class{static hasCaptures(e){return e===null?!1:(DL.lastIndex=0,DL.test(e))}static replaceCaptures(e,t,n){return e.replace(DL,(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 kL(e,t){return e<t?-1:+(e>t)}function AL(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=kL(e[r],t[r]);if(n!==0)return n}return 0}return n-r}function jL(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 ML(e){return e.replace(/[\-\\\{\}\*\+\?\|\^\$\.\,\[\]\(\)\#\s]/g,`\\$&`)}var NL=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}},PL=class{constructor(e,t,n){this._colorMap=e,this._defaults=t,this._root=n}static createFromRawTheme(e,t){return this.createFromParsedTheme(zL(e),t)}static createFromParsedTheme(e,t){return HL(e,t)}_cachedMatchRoot=new NL(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=>IL(e.parent,t.parentScopes));return n?new RL(n.fontStyle,n.foreground,n.background):null}},FL=class e{constructor(e,t){this.parent=e,this.scopeName=t}static push(t,n){for(let r of n)t=new e(t,r);return t}static from(...t){let n=null;for(let r=0;r<t.length;r++)n=new e(n,t[r]);return n}push(t){return new e(this,t)}getSegments(){let e=this,t=[];for(;e;)t.push(e.scopeName),e=e.parent;return t.reverse(),t}toString(){return this.getSegments().join(` `)}extends(e){return this===e?!0:this.parent===null?!1:this.parent.extends(e)}getExtensionIfDefined(e){let t=[],n=this;for(;n&&n!==e;)t.push(n.scopeName),n=n.parent;return n===e?t.reverse():void 0}};function IL(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&&!LL(e.scopeName,r);){if(i)return!1;e=e.parent}if(!e)return!1;e=e.parent}return!0}function LL(e,t){return t===e||e.startsWith(t)&&e[t.length]===`.`}var RL=class{constructor(e,t,n){this.fontStyle=e,this.foregroundId=t,this.backgroundId=n}};function zL(e){if(!e||!e.settings||!Array.isArray(e.settings))return[];let t=e.settings,n=[],r=0;for(let e=0,i=t.length;e<i;e++){let i=t[e];if(!i.settings)continue;let a;if(typeof i.scope==`string`){let e=i.scope;e=e.replace(/^[,]+/,``),e=e.replace(/[,]+$/,``),a=e.split(`,`)}else a=Array.isArray(i.scope)?i.scope:[``];let o=-1;if(typeof i.settings.fontStyle==`string`){o=0;let e=i.settings.fontStyle.split(` `);for(let t=0,n=e.length;t<n;t++)switch(e[t]){case`italic`:o|=1;break;case`bold`:o|=2;break;case`underline`:o|=4;break;case`strikethrough`:o|=8;break}}let s=null;typeof i.settings.foreground==`string`&&jL(i.settings.foreground)&&(s=i.settings.foreground);let c=null;typeof i.settings.background==`string`&&jL(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 BL(l,u,e,o,s,c)}}return n}var BL=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}},VL=(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))(VL||{});function HL(e,t){e.sort((e,t)=>{let n=kL(e.scope,t.scope);return n!==0||(n=AL(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 UL(t),o=new RL(n,a.getId(r),a.getId(i)),s=new KL(new GL(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 PL(a,o,s)}var UL=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)}},WL=Object.freeze([]),GL=class e{scopeDepth;parentScopes;fontStyle;foreground;background;constructor(e,t,n,r,i){this.scopeDepth=e,this.parentScopes=t||WL,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)}},KL=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(),GL.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(AL(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 GL(e,t,n,r,i))}},qL=class e{static toBinaryStr(e){return e.toString(2).padStart(32,`0`)}static print(t){let n=e.getLanguageId(t),r=e.getTokenType(t),i=e.getFontStyle(t),a=e.getForeground(t),o=e.getBackground(t);console.log({languageId:n,tokenType:r,fontStyle:i,foreground:a,background:o})}static getLanguageId(e){return(e&255)>>>0}static getTokenType(e){return(e&768)>>>8}static containsBalancedBrackets(e){return(e&1024)!=0}static getFontStyle(e){return(e&30720)>>>11}static getForeground(e){return(e&16744448)>>>15}static getBackground(e){return(e&4278190080)>>>24}static set(t,n,r,i,a,o,s){let c=e.getLanguageId(t),l=e.getTokenType(t),u=+!!e.containsBalancedBrackets(t),d=e.getFontStyle(t),f=e.getForeground(t),p=e.getBackground(t);return n!==0&&(c=n),r!==8&&(l=YL(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 JL(e){return e}function YL(e){return e}function XL(e,t){let n=[],r=QL(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(ZL(i)){let e=[];do e.push(i),i=r.next();while(ZL(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 ZL(e){return!!e&&!!e.match(/[\w\.:]+/)}function QL(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 $L(e){typeof e.dispose==`function`&&e.dispose()}var eR=class{constructor(e){this.scopeName=e}toKey(){return this.scopeName}},tR=class{constructor(e,t){this.scopeName=e,this.ruleName=t}toKey(){return`${this.scopeName}#${this.ruleName}`}},nR=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))}},rR=class{constructor(e,t){this.repo=e,this.initialScopeName=t,this.seenFullScopeRequests.add(this.initialScopeName),this.Q=[new eR(this.initialScopeName)]}seenFullScopeRequests=new Set;seenPartialScopeRequests=new Set;Q;processQueue(){let e=this.Q;this.Q=[];let t=new nR;for(let n of e)iR(n,this.initialScopeName,this.repo,t);for(let e of t.references)if(e instanceof eR){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 iR(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 eR?oR({baseGrammar:a,selfGrammar:i},r):aR(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 eR(e))}function aR(e,t,n){if(t.repository&&t.repository[e]){let r=t.repository[e];sR([r],t,n)}}function oR(e,t){e.selfGrammar.patterns&&Array.isArray(e.selfGrammar.patterns)&&sR(e.selfGrammar.patterns,{...e,repository:e.selfGrammar.repository},t),e.selfGrammar.injections&&sR(Object.values(e.selfGrammar.injections),{...e,repository:e.selfGrammar.repository},t)}function sR(e,t,n){for(let r of e){if(n.visitedRule.has(r))continue;n.visitedRule.add(r);let e=r.repository?TL({},t.repository,r.repository):t.repository;Array.isArray(r.patterns)&&sR(r.patterns,{...t,repository:e},n);let i=r.include;if(!i)continue;let a=pR(i);switch(a.kind){case 0:oR({...t,selfGrammar:t.baseGrammar},n);break;case 1:oR(t,n);break;case 2:aR(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?aR(a.ruleName,i,n):oR(i,n)}else a.kind===4?n.add(new tR(a.scopeName,a.ruleName)):n.add(new eR(a.scopeName));break}}}var cR=class{kind=0},lR=class{kind=1},uR=class{constructor(e){this.ruleName=e}kind=2},dR=class{constructor(e){this.scopeName=e}kind=3},fR=class{constructor(e,t){this.scopeName=e,this.ruleName=t}kind=4};function pR(e){if(e===`$base`)return new cR;if(e===`$self`)return new lR;let t=e.indexOf(`#`);return t===-1?new dR(e):t===0?new uR(e.substring(1)):new fR(e.substring(0,t),e.substring(t+1))}var mR=/\\(\d+)/,hR=/\\(\d+)/g,gR=-1,_R=-2;function vR(e){return e}function yR(e){return e}var bR=class{$location;id;_nameIsCapturing;_name;_contentNameIsCapturing;_contentName;constructor(e,t,n,r){this.$location=e,this.id=t,this._name=n||null,this._nameIsCapturing=OL.hasCaptures(this._name),this._contentName=r||null,this._contentNameIsCapturing=OL.hasCaptures(this._contentName)}get debugName(){let e=this.$location?`${EL(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:OL.replaceCaptures(this._name,e,t)}getContentName(e,t){return!this._contentNameIsCapturing||this._contentName===null?this._contentName:OL.replaceCaptures(this._contentName,e,t)}},xR=class extends bR{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!`)}},SR=class extends bR{_match;captures;_cachedCompiledPatterns;constructor(e,t,n,r,i){super(e,t,n,null),this._match=new DR(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 OR,this.collectPatterns(e,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},CR=class extends bR{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 OR,this.collectPatterns(e,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},wR=class extends bR{_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 DR(i,this.id),this.beginCaptures=a,this._end=new DR(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 OR;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}},TR=class extends bR{_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 DR(i,this.id),this.beginCaptures=a,this.whileCaptures=s,this._while=new DR(o,_R),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 OR;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 OR,this._cachedCompiledWhilePatterns.push(this._while.hasBackReferences?this._while.clone():this._while)),this._while.hasBackReferences&&this._cachedCompiledWhilePatterns.setSource(0,t||`￿`),this._cachedCompiledWhilePatterns}},ER=class e{static createCaptureRule(e,t,n,r,i){return e.registerRule(e=>new xR(t,e,n,r,i))}static getCompiledRuleId(t,n,r){return t.id||n.registerRule(i=>{if(t.id=i,t.match)return new SR(t.$vscodeTextmateLocation,t.id,t.name,t.match,e._compileCaptures(t.captures,n,r));if(t.begin===void 0){t.repository&&(r=TL({},r,t.repository));let i=t.patterns;return i===void 0&&t.include&&(i=[{include:t.include}]),new CR(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,e._compilePatterns(i,n,r))}return t.while?new TR(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 wR(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=pR(o.include);switch(t.kind){case 0:case 1:s=e.getCompiledRuleId(r[o.include],n,r);break;case 2:let i=r[t.ruleName];i&&(s=e.getCompiledRuleId(i,n,r));break;case 3:case 4:let a=t.scopeName,c=t.kind===4?t.ruleName:null,l=n.getExternalGrammar(a,r);if(l)if(c){let t=l.repository[c];t&&(s=e.getCompiledRuleId(t,n,l.repository))}else s=e.getCompiledRuleId(l.repository.$self,n,l.repository);break}}else s=e.getCompiledRuleId(o,n,r);if(s!==-1){let e=n.getRule(s),t=!1;if((e instanceof CR||e instanceof wR||e instanceof TR)&&e.hasMissingPatterns&&e.patterns.length===0&&(t=!0),t)continue;i.push(s)}}return{patterns:i,hasMissingPatterns:(t?t.length:0)!==i.length}}},DR=class e{source;ruleId;hasAnchor;hasBackReferences;_anchorCache;constructor(e,t){if(e&&typeof e==`string`){let t=e.length,n=0,r=[],i=!1;for(let a=0;a<t;a++)if(e.charAt(a)===`\\`&&a+1<t){let t=e.charAt(a+1);t===`z`?(r.push(e.substring(n,a)),r.push(`$(?!\\n)(?<!\\n)`),n=a+2):(t===`A`||t===`G`)&&(i=!0),a++}this.hasAnchor=i,n===0?this.source=e:(r.push(e.substring(n,t)),this.source=r.join(``))}else this.hasAnchor=!1,this.source=e;this.hasAnchor?this._anchorCache=this._buildAnchorCache():this._anchorCache=null,this.ruleId=t,typeof this.source==`string`?this.hasBackReferences=mR.test(this.source):this.hasBackReferences=!1}clone(){return new e(this.source,this.ruleId)}setSource(e){this.source!==e&&(this.source=e,this.hasAnchor&&(this._anchorCache=this._buildAnchorCache()))}resolveBackReferences(e,t){if(typeof this.source!=`string`)throw Error(`This method should only be called if the source is a string`);let n=t.map(t=>e.substring(t.start,t.end));return hR.lastIndex=0,this.source.replace(hR,(e,t)=>ML(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}},OR=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 kR(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 kR(e,this._items.map(e=>e.resolveAnchors(t,n)),this._items.map(e=>e.ruleId))}},kR=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(`
198
- `)}findNextMatchSync(e,t,n){let r=this.scanner.findNextMatchSync(e,t,n);return r?{ruleId:this.rules[r.index],captureIndices:r.captureIndices}:null}},AR=class{constructor(e,t){this.languageId=e,this.tokenType=t}},jR=class e{_defaultAttributes;_embeddedLanguagesMatcher;constructor(e,t){this._defaultAttributes=new AR(e,8),this._embeddedLanguagesMatcher=new MR(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 AR(0,0);_getBasicScopeAttributes=new NL(e=>new AR(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/},MR=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])=>ML(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 NR=!1,PR=class{constructor(e,t){this.stack=e,this.stoppedEarly=t}};function FR(e,t,n,r,i,a,o,s){let c=t.content.length,l=!1,u=-1;if(o){let o=IR(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 PR(i,!0);f()}return new PR(i,!1);function f(){let o=LR(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===gR){let o=i.getRule(e);a.produce(i,s[0].start),i=i.withContentNameScopesList(i.nameScopesList),UR(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 wR){let r=o;UR(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 TR){let r=o;UR(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(UR(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 IR(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 TR&&s.push({rule:n,stack:t})}for(let c=s.pop();c;c=s.pop()){let{ruleScanner:s,findOptions:l}=VR(c.rule,e,c.stack.endRule,n,r===o),u=s.findNextMatchSync(t,r,l);if(u){if(u.ruleId!==_R){i=c.stack.pop();break}u.captureIndices&&u.captureIndices.length&&(a.produce(c.stack,u.captureIndices[0].start),UR(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 LR(e,t,n,r,i,a){let o=RR(e,t,n,r,i,a),s=e.getInjections();if(s.length===0)return o;let c=zR(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 RR(e,t,n,r,i,a){let{ruleScanner:o,findOptions:s}=BR(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 zR(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}=BR(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 BR(e,t,n,r,i){return NR?{ruleScanner:e.compile(t,n),findOptions:HR(r,i)}:{ruleScanner:e.compileAG(t,n,r,i),findOptions:0}}function VR(e,t,n,r,i){return NR?{ruleScanner:e.compileWhile(t,n),findOptions:HR(r,i)}:{ruleScanner:e.compileWhileAG(t,n,r,i),findOptions:0}}function HR(e,t){let n=0;return e||(n|=1),t||(n|=4),n}function UR(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));FR(e,p,n&&d.start===0,d.start,f,i,!1,0),$L(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 WR(t,d.end))}}for(;l.length>0;)i.produceFromScopes(l[l.length-1].scopes,l[l.length-1].endPos),l.pop()}var WR=class{scopes;endPos;constructor(e,t){this.scopes=e,this.endPos=t}};function GR(e,t,n,r,i,a,o,s){return new YR(e,t,n,r,i,a,o,s)}function KR(e,t,n,r,i){let a=XL(t,qR),o=ER.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 qR(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(JR(t[r],e))return n=r+1,!0;return!1})}function JR(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 jR(n,r),this._rootId=-1,this._lastRuleId=0,this._ruleId2desc=[null],this._includedGrammars={},this._grammarRepository=o,this._grammar=XR(t,null),this._injections=null,this._tokenTypeMatchers=[],i)for(let e of Object.keys(i)){let t=XL(e,qR);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)KR(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&&KR(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(vR(t));return this._ruleId2desc[t]=n,n}getRule(e){return this._ruleId2desc[yR(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]=XR(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=ER.getCompiledRuleId(this._grammar.repository.$self,this,this._grammar.repository),this.getInjections());let i;if(!t||t===QR.NULL){i=!0;let e=this._basicScopeAttributesProvider.getDefaultAttributes(),n=this.themeProvider.getDefaults(),r=qL.set(0,e.languageId,e.tokenType,null,n.fontStyle,n.foregroundId,n.backgroundId),a=this.getRule(this._rootId).getName(null,null),o;o=a?ZR.createRootAndLookUpScopeName(a,r,this):ZR.createRoot(`unknown`,r),t=new QR(null,this._rootId,-1,-1,!1,null,o,o)}else i=!1,t.reset();e+=`
199
- `;let a=this.createOnigString(e),o=a.content.length,s=new ez(n,e,this._tokenTypeMatchers,this.balancedBracketSelectors),c=FR(this,a,i,0,t,s,!0,r);return $L(a),{lineLength:o,lineTokens:s,ruleStack:c.stack,stoppedEarly:c.stoppedEarly}}};function XR(e,t){return e=xL(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 ZR=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=FL.push(i,t.scopeNames),r=new e(r,i,t.encodedTokenAttributes);return r}static createRoot(t,n){return new e(null,new FL(null,t),n)}static createRootAndLookUpScopeName(t,n,r){let i=r.getMetadataForScope(t),a=new FL(null,t),o=r.themeProvider.themeMatch(a);return new e(null,a,e.mergeAttributes(n,i,o))}get scopeName(){return this.scopePath.scopeName}toString(){return this.getScopeNames().join(` `)}equals(t){return e.equals(this,t)}static equals(e,t){do{if(e===t||!e&&!t)return!0;if(!e||!t||e.scopeName!==t.scopeName||e.tokenAttributes!==t.tokenAttributes)return!1;e=e.parent,t=t.parent}while(!0)}static mergeAttributes(e,t,n){let r=-1,i=0,a=0;return n!==null&&(r=n.fontStyle,i=n.foregroundId,a=n.backgroundId),qL.set(e,t.languageId,t.tokenType,null,r,i,a)}pushAttributed(t,n){if(t===null)return this;if(t.indexOf(` `)===-1)return e._pushAttributed(this,t,n);let r=t.split(/ /g),i=this;for(let t of r)i=e._pushAttributed(i,t,n);return i}static _pushAttributed(t,n,r){let i=r.getMetadataForScope(n),a=t.scopePath.push(n),o=r.themeProvider.themeMatch(a);return new e(t,a,e.mergeAttributes(t.tokenAttributes,i,o))}getScopeNames(){return this.scopePath.getSegments()}getExtensionIfDefined(e){let t=[],n=this;for(;n&&n!==e;)t.push({encodedTokenAttributes:n.tokenAttributes,scopeNames:n.scopePath.getExtensionIfDefined(n.parent?.scopePath??null)}),n=n.parent;return n===e?t.reverse():void 0}},QR=class e{constructor(e,t,n,r,i,a,o,s){this.parent=e,this.ruleId=t,this.beginRuleCapturedEOL=i,this.endRule=a,this.nameScopesList=o,this.contentNameScopesList=s,this.depth=this.parent?this.parent.depth+1:1,this._enterPos=n,this._anchorPos=r}_stackElementBrand=void 0;static NULL=new e(null,0,0,0,!1,null,null,null);_enterPos;_anchorPos;depth;equals(t){return t===null?!1:e._equals(this,t)}static _equals(e,t){return e===t?!0:this._structuralEquals(e,t)?ZR.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:yR(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=ZR.fromExtension(t?.nameScopesList??null,n.nameScopesList);return new e(t,vR(n.ruleId),n.enterPos??-1,n.anchorPos??-1,n.beginRuleCapturedEOL,n.endRule,r,ZR.fromExtension(r,n.contentNameScopesList))}},$R=class{balancedBracketScopes;unbalancedBracketScopes;allowAny=!1;constructor(e,t){this.balancedBracketScopes=e.flatMap(e=>e===`*`?(this.allowAny=!0,[]):XL(e,qR).map(e=>e.matcher)),this.unbalancedBracketScopes=t.flatMap(e=>XL(e,qR).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}},ez=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=qL.set(n,0,JL(e.type),null,-1,0,0));this.balancedBracketSelectors&&(r=this.balancedBracketSelectors.match(t))}if(r&&(n=qL.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}},tz=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,GR(e,a,t,n,r,i,this,this._onigLib))}return this._grammars.get(e)}},nz=class{_options;_syncRegistry;_ensureGrammarCache;constructor(e){this._options=e,this._syncRegistry=new tz(PL.createFromRawTheme(e.theme,e.colorMap),e.onigLib),this._ensureGrammarCache=new Map}dispose(){this._syncRegistry.dispose()}setTheme(e,t){this._syncRegistry.setTheme(PL.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 $R(n.balancedBracketSelectors||[],n.unbalancedBracketSelectors||[]))}loadGrammar(e){return this._loadGrammar(e,0,null,null,null)}_loadGrammar(e,t,n,r,i){let a=new rR(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)}},rz=QR.NULL;function iz(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 az(e,t){return e&&(t?.[e?.toLowerCase()]||e)}function oz(e){return Array.isArray(e)?e:[e]}async function sz(e){return Promise.resolve(typeof e==`function`?e():e).then(e=>e.default||e)}function cz(e){return!e||[`plaintext`,`txt`,`text`,`plain`].includes(e)}function lz(e){return e===`ansi`||cz(e)}function uz(e){return e===`none`}function dz(e){return uz(e)}function fz(e,t=!1){if(e.length===0)return[[``,0]];let n=e.split(/(\r?\n)/g),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 pz={light:`#333333`,dark:`#bbbbbb`},mz={light:`#fffffe`,dark:`#1e1e1e`},hz=`__shiki_resolved`;function gz(e){if(e?.[hz])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`?pz.light:pz.dark,n||=t.type===`light`?mz.light:mz.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,hz,{enumerable:!1,writable:!1,value:!0}),t}async function _z(e){return Array.from(new Set((await Promise.all(e.filter(e=>!lz(e)).map(async e=>await sz(e).then(e=>Array.isArray(e)?e:[e])))).flat()))}async function vz(e){return(await Promise.all(e.map(async e=>dz(e)?null:gz(await sz(e))))).filter(e=>!!e)}function yz(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 bL(`Circular alias \`${Array.from(n).join(` -> `)} -> ${e}\``);n.add(e)}}return e}var bz=class extends nz{_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=gz(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=PL.createFromRawTheme(e),this._textmateThemeCache.set(e,t)),this._syncRegistry.setTheme(t)}getGrammar(e){return e=yz(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=Array.from(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 bL(`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))}},xz=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}},Sz=0;function Cz(e){Sz+=1,e.warnings!==!1&&Sz>=10&&Sz%10==0&&console.warn(`[Shiki] ${Sz} 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 bL("`engine` option is required for synchronous mode");let n=(e.langs||[]).flat(1),r=(e.themes||[]).flat(1).map(gz),i=new bz(new xz(e.engine,n),r,n,e.langAlias),a;function o(t){return yz(t,e.langAlias)}function s(e){g();let t=i.getGrammar(typeof e==`string`?e:e.name);if(!t)throw new bL(`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 bL(`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 _z(e))}function m(...e){g();for(let t of e.flat(1))i.loadTheme(t)}async function h(...e){return g(),m(await vz(e))}function g(){if(t)throw new bL(`Shiki instance has been disposed`)}function _(){t||(t=!0,i.dispose(),--Sz)}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 wz(e){e.engine||console.warn("`engine` option is required. Use `createOnigurumaEngine` or `createJavaScriptRegexEngine` to create an engine.");let[t,n,r]=await Promise.all([vz(e.themes||[]),_z(e.langs||[]),e.engine]);return Cz({...e,themes:t,langs:n,engine:r})}var Tz=new WeakMap;function Ez(e,t){Tz.set(e,t)}function Dz(e){return Tz.get(e)}var Oz=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(oz(n).map(e=>[e,rz])),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 kz(this._stacks[e])}toJSON(){return{lang:this.lang,theme:this.theme,themes:this.themes,scopes:this.getScopes()}}};function kz(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 Az(e,t){if(!(e instanceof Oz))throw new bL(`Invalid grammar state`);return e.getInternalStack(t)}function jz(e,t,n={}){let{theme:r=e.getLoadedThemes()[0]}=n;if(cz(e.resolveLangAlias(n.lang||`text`))||uz(r))return fz(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 bL(`Grammar state language "${n.grammarState.lang}" does not match highlight language "${o.name}"`);if(!n.grammarState.themes.includes(i.name))throw new bL(`Grammar state themes "${n.grammarState.themes}" do not contain highlight theme "${i.name}"`)}return Nz(t,o,i,a,n)}function Mz(...e){if(e.length===2)return Dz(e[1]);let[t,n,r={}]=e,{lang:i=`text`,theme:a=t.getLoadedThemes()[0]}=r;if(cz(i)||uz(a))throw new bL(`Plain language does not have grammar state`);if(i===`ansi`)throw new bL(`ANSI language does not have grammar state`);let{theme:o,colorMap:s}=t.setTheme(a),c=t.getLanguage(i);return new Oz(Pz(n,c,o,s,r).stateStack,c.name,o.name)}function Nz(e,t,n,r,i){let a=Pz(e,t,n,r,i),o=new Oz(a.stateStack,t.name,n.name);return Ez(a.tokens,o),a.tokens}function Pz(e,t,n,r,i){let a=iz(n,i),{tokenizeMaxLineLength:o=0,tokenizeTimeLimit:s=500}=i,c=fz(e),l=i.grammarState?Az(i.grammarState,n.name)??rz:i.grammarContextCode==null?rz:Pz(i.grammarContextCode,t,n,r,{...i,grammarState:void 0,grammarContextCode:void 0}).stateStack,u=[],d=[];for(let e=0,f=c.length;e<f;e++){let[f,p]=c[e];if(f===``){u=[],d.push([]);continue}if(o>0&&f.length>=o){u=[],d.push([{content:f,offset:p,color:``,fontStyle:0}]);continue}let m,h,g;i.includeExplanation&&(m=t.tokenizeLine(f,l,s),h=m.tokens,g=0);let _=t.tokenizeLine2(f,l,s),v=_.tokens.length/2;for(let e=0;e<v;e++){let t=_.tokens[2*e],o=e+1<v?_.tokens[2*e+2]:f.length;if(t===o)continue;let s=_.tokens[2*e+1],c=az(r[qL.getForeground(s)],a),l=qL.getFontStyle(s),d={content:f.substring(t,o),offset:p+t,color:c,fontStyle:l};if(i.includeExplanation){let e=[];if(i.includeExplanation!==`scopeName`)for(let t of n.settings){let n;switch(typeof t.scope){case`string`:n=t.scope.split(/,/).map(e=>e.trim());break;case`object`:n=t.scope;break;default:continue}e.push({settings:t,selectors:n.map(e=>e.split(/ /))})}d.explanation=[];let r=0;for(;t+r<o;){let t=h[g],n=f.substring(t.startIndex,t.endIndex);r+=n.length,d.explanation.push({content:n,scopes:i.includeExplanation===`scopeName`?Fz(t.scopes):Iz(e,t.scopes)}),g+=1}}u.push(d)}d.push(u),u=[],l=_.ruleStack}return{tokens:d,stateStack:l}}function Fz(e){return e.map(e=>({scopeName:e}))}function Iz(e,t){let n=[];for(let r=0,i=t.length;r<i;r++){let i=t[r];n[r]={scopeName:i,themeMatches:zz(e,i,t.slice(0,r))}}return n}function Lz(e,t){return e===t||t.substring(0,e.length)===e&&t[e.length]===`.`}function Rz(e,t,n){if(!Lz(e[e.length-1],t))return!1;let r=e.length-2,i=n.length-1;for(;r>=0&&i>=0;)Lz(e[r],n[i])&&--r,--i;return r===-1}function zz(e,t,n){let r=[];for(let{selectors:i,settings:a}of e)for(let e of i)if(Rz(e,t,n)){r.push(a);break}return r}function Bz(e,t,n,r=jz){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:Dz(a),theme:typeof i.theme==`string`?i.theme:i.theme.name}}),o=Vz(...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 Oz(Object.fromEntries(a.map(e=>[e.theme,e.state?.getInternalStack(e.theme)])),a[0].state.lang):void 0;return c&&Ez(s,c),s}function Vz(...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 Hz=/["&'<>`]/g,Uz=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,Wz=/[\x01-\t\v\f\x0E-\x1F\x7F\x81\x8D\x8F\x90\x9D\xA0-\uFFFF]/g,Gz=/[|\\{}()[\]^$+*?.]/g,Kz=new WeakMap;function qz(e,t){if(e=e.replace(t.subset?Jz(t.subset):Hz,r),t.subset||t.escapeOnly)return e;return e.replace(Uz,n).replace(Wz,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 Jz(e){let t=Kz.get(e);return t||(t=Yz(e),Kz.set(e,t)),t}function Yz(e){let t=[],n=-1;for(;++n<e.length;)t.push(e[n].replace(Gz,`\\$&`));return RegExp(`(?:`+t.join(`|`)+`)`,`g`)}var Xz=/[\dA-Fa-f]/;function Zz(e,t,n){let r=`&#x`+e.toString(16).toUpperCase();return n&&t&&!Xz.test(String.fromCharCode(t))?r:r+`;`}var Qz=/\d/;function $z(e,t,n){let r=`&#`+String(e);return n&&t&&!Qz.test(String.fromCharCode(t))?r:r+`;`}var eB=`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(`.`),tB={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:`€`},nB=[`cent`,`copy`,`divide`,`gt`,`lt`,`not`,`para`,`times`],rB={}.hasOwnProperty,iB={},aB;for(aB in tB)rB.call(tB,aB)&&(iB[tB[aB]]=aB);var oB=/[^\dA-Za-z]/;function sB(e,t,n,r){let i=String.fromCharCode(e);if(rB.call(iB,i)){let e=iB[i],a=`&`+e;return n&&eB.includes(e)&&!nB.includes(e)&&(!r||t&&t!==61&&oB.test(String.fromCharCode(t)))?a:a+`;`}return``}function cB(e,t,n){let r=Zz(e,t,n.omitOptionalSemicolons),i;if((n.useNamedReferences||n.useShortestReferences)&&(i=sB(e,t,n.omitOptionalSemicolons,n.attribute)),(n.useShortestReferences||!i)&&n.useShortestReferences){let i=$z(e,t,n.omitOptionalSemicolons);i.length<r.length&&(r=i)}return i&&(!n.useShortestReferences||i.length<r.length)?i:r}function lB(e,t){return qz(e,Object.assign({format:cB},t))}var uB=/^>|^->|<!--|-->|--!>|<!-$/g,dB=[`>`],fB=[`<`,`>`];function pB(e,t,n,r){return r.settings.bogusComments?`<?`+lB(e.value,Object.assign({},r.settings.characterReferences,{subset:dB}))+`>`:`<!--`+e.value.replace(uB,i)+`-->`;function i(e){return lB(e,Object.assign({},r.settings.characterReferences,{subset:fB}))}}function mB(e,t,n,r){return`<!`+(r.settings.upperDoctype?`DOCTYPE`:`doctype`)+(r.settings.tightDoctype?``:` `)+`html>`}var hB=vB(1),gB=vB(-1),_B=[];function vB(e){return t;function t(t,n,r){let i=t?t.children:_B,a=(n||0)+e,o=i[a];if(!r)for(;o&&tk(o);)a+=e,o=i[a];return o}}var yB={}.hasOwnProperty;function bB(e){return t;function t(t,n,r){return yB.call(e,t.tagName)&&e[t.tagName](t,n,r)}}var xB=bB({body:wB,caption:SB,colgroup:SB,dd:OB,dt:DB,head:SB,html:CB,li:EB,optgroup:AB,option:jB,p:TB,rp:kB,rt:kB,tbody:NB,td:IB,tfoot:PB,th:IB,thead:MB,tr:FB});function SB(e,t,n){let r=hB(n,t,!0);return!r||r.type!==`comment`&&!(r.type===`text`&&tk(r.value.charAt(0)))}function CB(e,t,n){let r=hB(n,t);return!r||r.type!==`comment`}function wB(e,t,n){let r=hB(n,t);return!r||r.type!==`comment`}function TB(e,t,n){let r=hB(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 EB(e,t,n){let r=hB(n,t);return!r||r.type===`element`&&r.tagName===`li`}function DB(e,t,n){let r=hB(n,t);return!!(r&&r.type===`element`&&(r.tagName===`dt`||r.tagName===`dd`))}function OB(e,t,n){let r=hB(n,t);return!r||r.type===`element`&&(r.tagName===`dt`||r.tagName===`dd`)}function kB(e,t,n){let r=hB(n,t);return!r||r.type===`element`&&(r.tagName===`rp`||r.tagName===`rt`)}function AB(e,t,n){let r=hB(n,t);return!r||r.type===`element`&&r.tagName===`optgroup`}function jB(e,t,n){let r=hB(n,t);return!r||r.type===`element`&&(r.tagName===`option`||r.tagName===`optgroup`)}function MB(e,t,n){let r=hB(n,t);return!!(r&&r.type===`element`&&(r.tagName===`tbody`||r.tagName===`tfoot`))}function NB(e,t,n){let r=hB(n,t);return!r||r.type===`element`&&(r.tagName===`tbody`||r.tagName===`tfoot`)}function PB(e,t,n){return!hB(n,t)}function FB(e,t,n){let r=hB(n,t);return!r||r.type===`element`&&r.tagName===`tr`}function IB(e,t,n){let r=hB(n,t);return!r||r.type===`element`&&(r.tagName===`td`||r.tagName===`th`)}var LB=bB({body:BB,colgroup:VB,head:zB,html:RB,tbody:HB});function RB(e){let t=hB(e,-1);return!t||t.type!==`comment`}function zB(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 BB(e){let t=hB(e,-1,!0);return!t||t.type!==`comment`&&!(t.type===`text`&&tk(t.value.charAt(0)))&&!(t.type===`element`&&(t.tagName===`meta`||t.tagName===`link`||t.tagName===`script`||t.tagName===`style`||t.tagName===`template`))}function VB(e,t,n){let r=gB(n,t),i=hB(e,-1,!0);return n&&r&&r.type===`element`&&r.tagName===`colgroup`&&xB(r,n.children.indexOf(r),n)?!1:!!(i&&i.type===`element`&&i.tagName===`col`)}function HB(e,t,n){let r=gB(n,t),i=hB(e,-1);return n&&r&&r.type===`element`&&(r.tagName===`thead`||r.tagName===`tbody`)&&xB(r,n.children.indexOf(r),n)?!1:!!(i&&i.type===`element`&&i.tagName===`tr`)}var UB={name:[[`
200
- \f\r &/=>`.split(``),`
201
- \f\r "&'/=>\``.split(``)],[`\0
202
- \f\r "&'/<=>`.split(``),`\0
203
- \f\r "&'/<=>\``.split(``)]],unquoted:[[`
204
- \f\r &>`.split(``),`\0
205
- \f\r "&'<=>\``.split(``)],[`\0
206
- \f\r "&'<=>\``.split(``),`\0
207
- \f\r "&'<=>\``.split(``)]],single:[[`&'`.split(``),`"&'\``.split(``)],[`\0&'`.split(``),`\0"&'\``.split(``)]],double:[[`"&`.split(``),`"&'\``.split(``)],[`\0"&`.split(``),`\0"&'\``.split(``)]]};function WB(e,t,n,r){let i=r.schema,a=i.space===`svg`?!1:r.settings.omitOptionalTags,o=i.space===`svg`?r.settings.closeEmptyElements:r.settings.voids.includes(e.tagName.toLowerCase()),s=[],c;i.space===`html`&&e.tagName===`svg`&&(r.schema=mg);let l=GB(r,e.properties),u=r.all(i.space===`html`&&e.tagName===`template`?e.content:e);return r.schema=i,u&&(o=!1),(l||!a||!LB(e,t,n))&&(s.push(`<`,e.tagName,l?` `+l:``),o&&(i.space===`svg`||r.settings.closeSelfClosing)&&(c=l.charAt(l.length-1),(!r.settings.tightSelfClosing||c===`/`||c&&c!==`"`&&c!==`'`)&&s.push(` `),s.push(`/`)),s.push(`>`)),s.push(u),!o&&(!a||!xB(e,t,n))&&s.push(`</`+e.tagName+`>`),s.join(``)}function GB(e,t){let n=[],r=-1,i;if(t){for(i in t)if(t[i]!==null&&t[i]!==void 0){let r=KB(e,i,t[i]);r&&n.push(r)}}for(;++r<n.length;){let t=e.settings.tightAttributes?n[r].charAt(n[r].length-1):void 0;r!==n.length-1&&t!==`"`&&t!==`'`&&(n[r]+=` `)}return n.join(``)}function KB(e,t,n){let r=ug(e.schema,t),i=e.settings.allowParseErrors&&e.schema.space===`html`?0:1,a=+!e.settings.allowDangerousCharacters,o=e.quote,s;if(r.overloadedBoolean&&(n===r.attribute||n===``)?n=!0:(r.boolean||r.overloadedBoolean)&&(typeof n!=`string`||n===r.attribute||n===``)&&(n=!!n),n==null||n===!1||typeof n==`number`&&Number.isNaN(n))return``;let c=lB(r.attribute,Object.assign({},e.settings.characterReferences,{subset:UB.name[i][a]}));return n===!0||(n=Array.isArray(n)?(r.commaSeparated?gg:bg)(n,{padLeft:!e.settings.tightCommaSeparatedLists}):String(n),e.settings.collapseEmptyAttributes&&!n)?c:(e.settings.preferUnquoted&&(s=lB(n,Object.assign({},e.settings.characterReferences,{attribute:!0,subset:UB.unquoted[i][a]}))),s!==n&&(e.settings.quoteSmart&&tS(n,o)>tS(n,e.alternative)&&(o=e.alternative),s=o+lB(n,Object.assign({},e.settings.characterReferences,{subset:(o===`'`?UB.single:UB.double)[i][a],attribute:!0}))+o),c+(s&&`=`+s))}var qB=[`<`,`&`];function JB(e,t,n,r){return n&&n.type===`element`&&(n.tagName===`script`||n.tagName===`style`)?e.value:lB(e.value,Object.assign({},r.settings.characterReferences,{subset:qB}))}function YB(e,t,n,r){return r.settings.allowDangerousHtml?e.value:JB(e,t,n,r)}function XB(e,t,n,r){return r.all(e)}var ZB=Gg(`type`,{invalid:QB,unknown:$B,handlers:{comment:pB,doctype:mB,element:WB,raw:YB,root:XB,text:JB}});function QB(e){throw Error("Expected node, not `"+e+"`")}function $B(e){throw Error("Cannot compile unknown node `"+e.type+"`")}var eV={},tV={},nV=[];function rV(e,t){let n=t||eV,r=n.quote||`"`,i=r===`"`?`'`:`"`;if(r!==`"`&&r!==`'`)throw Error("Invalid quote `"+r+"`, expected `'` or `\"`");return{one:iV,all:aV,settings:{omitOptionalTags:n.omitOptionalTags||!1,allowParseErrors:n.allowParseErrors||!1,allowDangerousCharacters:n.allowDangerousCharacters||!1,quoteSmart:n.quoteSmart||!1,preferUnquoted:n.preferUnquoted||!1,tightAttributes:n.tightAttributes||!1,upperDoctype:n.upperDoctype||!1,tightDoctype:n.tightDoctype||!1,bogusComments:n.bogusComments||!1,tightCommaSeparatedLists:n.tightCommaSeparatedLists||!1,tightSelfClosing:n.tightSelfClosing||!1,collapseEmptyAttributes:n.collapseEmptyAttributes||!1,allowDangerousHtml:n.allowDangerousHtml||!1,voids:n.voids||a_,characterReferences:n.characterReferences||tV,closeSelfClosing:n.closeSelfClosing||!1,closeEmptyElements:n.closeEmptyElements||!1},schema:n.space===`svg`?mg:pg,quote:r,alternative:i}.one(Array.isArray(e)?{type:`root`,children:e}:e,void 0,void 0)}function iV(e,t,n){return ZB(e,t,n,this)}function aV(e){let t=[],n=e&&e.children||nV,r=-1;for(;++r<n.length;)t[r]=this.one(n[r],r,e);return t.join(``)}function oV(e,t){if(!t)return e;e.properties||={},e.properties.class||=[],typeof e.properties.class==`string`&&(e.properties.class=e.properties.class.split(/\s+/g)),Array.isArray(e.properties.class)||(e.properties.class=[]);let n=Array.isArray(t)?t:t.split(/\s+/g);for(let t of n)t&&!e.properties.class.includes(t)&&e.properties.class.push(t);return e}function sV(e){let t=fz(e,!0).map(([e])=>e);function n(n){if(n===e.length)return{line:t.length-1,character:t[t.length-1].length};let r=n,i=0;for(let e of t){if(r<e.length)break;r-=e.length,i++}return{line:i,character:r}}function r(e,n){let r=0;for(let n=0;n<e;n++)r+=t[n].length;return r+=n,r}return{lines:t,indexToPos:n,posToIndex:r}}function cV(e,t,n){let r=new Set;for(let t of e.matchAll(/:?lang=["']([^"']+)["']/g)){let e=t[1].toLowerCase().trim();e&&r.add(e)}for(let t of e.matchAll(/(?:```|~~~)([\w-]+)/g)){let e=t[1].toLowerCase().trim();e&&r.add(e)}for(let t of e.matchAll(/\\begin\{([\w-]+)\}/g)){let e=t[1].toLowerCase().trim();e&&r.add(e)}for(let t of e.matchAll(/<script\s+(?:type|lang)=["']([^"']+)["']/gi)){let e=t[1].toLowerCase().trim(),n=e.includes(`/`)?e.split(`/`).pop():e;n&&r.add(n)}if(!n)return Array.from(r);let i=n.getBundledLanguages();return Array.from(r).filter(e=>e&&i[e])}var lV=`light-dark()`,uV=[`color`,`background-color`];function dV(e,t){let n=0,r=[];for(let i of t)i>n&&r.push({...e,content:e.content.slice(n,i),offset:e.offset+n}),n=i;return n<e.content.length&&r.push({...e,content:e.content.slice(n),offset:e.offset+n}),r}function fV(e,t){let n=Array.from(t instanceof Set?t:new Set(t)).sort((e,t)=>e-t);return n.length?e.map(e=>e.flatMap(e=>{let t=n.filter(t=>e.offset<t&&t<e.offset+e.content.length).map(t=>t-e.offset).sort((e,t)=>e-t);return t.length?dV(e,t):e})):e}function pV(e,t,n,r,i=`css-vars`){let a={content:e.content,explanation:e.explanation,offset:e.offset},o=t.map(t=>mV(e.variants[t])),s=new Set(o.flatMap(e=>Object.keys(e))),c={},l=(e,r)=>{let i=r===`color`?``:r===`background-color`?`-bg`:`-${r}`;return n+t[e]+(r===`color`?``:i)};return o.forEach((e,n)=>{for(let a of s){let s=e[a]||`inherit`;if(n===0&&r&&uV.includes(a))if(r===lV&&o.length>1){let e=t.findIndex(e=>e===`light`),r=t.findIndex(e=>e===`dark`);if(e===-1||r===-1)throw new bL('When using `defaultColor: "light-dark()"`, you must provide both `light` and `dark` themes');c[a]=`light-dark(${o[e][a]||`inherit`}, ${o[r][a]||`inherit`})`,i===`css-vars`&&(c[l(n,a)]=s)}else c[a]=s;else i===`css-vars`&&(c[l(n,a)]=s)}}),a.htmlStyle=c,a}function mV(e){let t={};if(e.color&&(t.color=e.color),e.bgColor&&(t[`background-color`]=e.bgColor),e.fontStyle){e.fontStyle&VL.Italic&&(t[`font-style`]=`italic`),e.fontStyle&VL.Bold&&(t[`font-weight`]=`bold`);let n=[];e.fontStyle&VL.Underline&&n.push(`underline`),e.fontStyle&VL.Strikethrough&&n.push(`line-through`),n.length&&(t[`text-decoration`]=n.join(` `))}return t}function hV(e){return typeof e==`string`?e:Object.entries(e).map(([e,t])=>`${e}:${t}`).join(`;`)}function gV(){let e=new WeakMap;function t(t){if(!e.has(t.meta)){let n=sV(t.source);function r(e){if(typeof e==`number`){if(e<0||e>t.source.length)throw new bL(`Invalid decoration offset: ${e}. Code length: ${t.source.length}`);return{...n.indexToPos(e),offset:e}}else{let t=n.lines[e.line];if(t===void 0)throw new bL(`Invalid decoration position ${JSON.stringify(e)}. Lines length: ${n.lines.length}`);let r=e.character;if(r<0&&(r=t.length+r),r<0||r>t.length)throw new bL(`Invalid decoration position ${JSON.stringify(e)}. Line ${e.line} length: ${t.length}`);return{...e,character:r,offset:n.posToIndex(e.line,r)}}}let i=(t.options.decorations||[]).map(e=>({...e,start:r(e.start),end:r(e.end)}));_V(i),e.set(t.meta,{decorations:i,converter:n,source:t.source})}return e.get(t.meta)}return{name:`shiki:decorations`,tokens(e){if(this.options.decorations?.length)return fV(e,t(this).decorations.flatMap(e=>[e.start.offset,e.end.offset]))},code(e){if(!this.options.decorations?.length)return;let n=t(this),r=Array.from(e.children).filter(e=>e.type===`element`&&e.tagName===`span`);if(r.length!==n.converter.lines.length)throw new bL(`Number of lines in code element (${r.length}) does not match the number of lines in the source (${n.converter.lines.length}). Failed to apply decorations.`);function i(e,t,n,i){let a=r[e],s=``,c=-1,l=-1;if(t===0&&(c=0),n===0&&(l=0),n===1/0&&(l=a.children.length),c===-1||l===-1)for(let e=0;e<a.children.length;e++)s+=vV(a.children[e]),c===-1&&s.length===t&&(c=e+1),l===-1&&s.length===n&&(l=e+1);if(c===-1)throw new bL(`Failed to find start index for decoration ${JSON.stringify(i.start)}`);if(l===-1)throw new bL(`Failed to find end index for decoration ${JSON.stringify(i.end)}`);let u=a.children.slice(c,l);if(!i.alwaysWrap&&u.length===a.children.length)o(a,i,`line`);else if(!i.alwaysWrap&&u.length===1&&u[0].type===`element`)o(u[0],i,`token`);else{let e={type:`element`,tagName:`span`,properties:{},children:u};o(e,i,`wrapper`),a.children.splice(c,u.length,e)}}function a(e,t){r[e]=o(r[e],t,`line`)}function o(e,t,n){let r=t.properties||{},i=t.transform||(e=>e);return e.tagName=t.tagName||`span`,e.properties={...e.properties,...r,class:e.properties.class},t.properties?.class&&oV(e,t.properties.class),e=i(e,n)||e,e}let s=[],c=n.decorations.sort((e,t)=>t.start.offset-e.start.offset||e.end.offset-t.end.offset);for(let e of c){let{start:t,end:n}=e;if(t.line===n.line)i(t.line,t.character,n.character,e);else if(t.line<n.line){i(t.line,t.character,1/0,e);for(let r=t.line+1;r<n.line;r++)s.unshift(()=>a(r,e));i(n.line,0,n.character,e)}}s.forEach(e=>e())}}}function _V(e){for(let t=0;t<e.length;t++){let n=e[t];if(n.start.offset>n.end.offset)throw new bL(`Invalid decoration range: ${JSON.stringify(n.start)} - ${JSON.stringify(n.end)}`);for(let r=t+1;r<e.length;r++){let t=e[r],i=n.start.offset<=t.start.offset&&t.start.offset<n.end.offset,a=n.start.offset<t.end.offset&&t.end.offset<=n.end.offset,o=t.start.offset<=n.start.offset&&n.start.offset<t.end.offset,s=t.start.offset<n.end.offset&&n.end.offset<=t.end.offset;if(i||a||o||s){if(i&&a||o&&s||o&&n.start.offset===n.end.offset||a&&t.start.offset===t.end.offset)continue;throw new bL(`Decorations ${JSON.stringify(n.start)} and ${JSON.stringify(t.start)} intersect.`)}}}}function vV(e){return e.type===`text`?e.value:e.type===`element`?e.children.map(vV).join(``):``}var yV=[gV()];function bV(e){let t=xV(e.transformers||[]);return[...t.pre,...t.normal,...t.post,...yV]}function xV(e){let t=[],n=[],r=[];for(let i of e)switch(i.enforce){case`pre`:t.push(i);break;case`post`:n.push(i);break;default:r.push(i)}return{pre:t,post:n,normal:r}}var SV=[`black`,`red`,`green`,`yellow`,`blue`,`magenta`,`cyan`,`white`,`brightBlack`,`brightRed`,`brightGreen`,`brightYellow`,`brightBlue`,`brightMagenta`,`brightCyan`,`brightWhite`],CV={1:`bold`,2:`dim`,3:`italic`,4:`underline`,7:`reverse`,8:`hidden`,9:`strikethrough`};function wV(e,t){let n=e.indexOf(`\x1B`,t);if(n!==-1&&e[n+1]===`[`){let t=e.indexOf(`m`,n);if(t!==-1)return{sequence:e.substring(n+2,t).split(`;`),startPosition:n,position:t+1}}return{position:e.length}}function TV(e){let t=e.shift();if(t===`2`){let t=e.splice(0,3).map(e=>Number.parseInt(e));return t.length!==3||t.some(e=>Number.isNaN(e))?void 0:{type:`rgb`,rgb:t}}else if(t===`5`){let t=e.shift();if(t)return{type:`table`,index:Number(t)}}}function EV(e){let t=[];for(;e.length>0;){let n=e.shift();if(!n)continue;let r=Number.parseInt(n);if(!Number.isNaN(r))if(r===0)t.push({type:`resetAll`});else if(r<=9)CV[r]&&t.push({type:`setDecoration`,value:CV[r]});else if(r<=29){let e=CV[r-20];e&&(t.push({type:`resetDecoration`,value:e}),e===`dim`&&t.push({type:`resetDecoration`,value:`bold`}))}else if(r<=37)t.push({type:`setForegroundColor`,value:{type:`named`,name:SV[r-30]}});else if(r===38){let n=TV(e);n&&t.push({type:`setForegroundColor`,value:n})}else if(r===39)t.push({type:`resetForegroundColor`});else if(r<=47)t.push({type:`setBackgroundColor`,value:{type:`named`,name:SV[r-40]}});else if(r===48){let n=TV(e);n&&t.push({type:`setBackgroundColor`,value:n})}else r===49?t.push({type:`resetBackgroundColor`}):r===53?t.push({type:`setDecoration`,value:`overline`}):r===55?t.push({type:`resetDecoration`,value:`overline`}):r>=90&&r<=97?t.push({type:`setForegroundColor`,value:{type:`named`,name:SV[r-90+8]}}):r>=100&&r<=107&&t.push({type:`setBackgroundColor`,value:{type:`named`,name:SV[r-100+8]}})}return t}function DV(){let e=null,t=null,n=new Set;return{parse(r){let i=[],a=0;do{let o=wV(r,a),s=o.sequence?r.substring(a,o.startPosition):r.substring(a);if(s.length>0&&i.push({value:s,foreground:e,background:t,decorations:new Set(n)}),o.sequence){let r=EV(o.sequence);for(let i of r)i.type===`resetAll`?(e=null,t=null,n.clear()):i.type===`resetForegroundColor`?e=null:i.type===`resetBackgroundColor`?t=null:i.type===`resetDecoration`&&n.delete(i.value);for(let i of r)i.type===`setForegroundColor`?e=i.value:i.type===`setBackgroundColor`?t=i.value:i.type===`setDecoration`&&n.add(i.value)}a=o.position}while(a<r.length);return i}}}var OV={black:`#000000`,red:`#bb0000`,green:`#00bb00`,yellow:`#bbbb00`,blue:`#0000bb`,magenta:`#ff00ff`,cyan:`#00bbbb`,white:`#eeeeee`,brightBlack:`#555555`,brightRed:`#ff5555`,brightGreen:`#00ff00`,brightYellow:`#ffff55`,brightBlue:`#5555ff`,brightMagenta:`#ff55ff`,brightCyan:`#55ffff`,brightWhite:`#ffffff`};function kV(e=OV){function t(t){return e[t]}function n(e){return`#${e.map(e=>Math.max(0,Math.min(e,255)).toString(16).padStart(2,`0`)).join(``)}`}let r;function i(){if(r)return r;r=[];for(let e=0;e<SV.length;e++)r.push(t(SV[e]));let e=[0,95,135,175,215,255];for(let t=0;t<6;t++)for(let i=0;i<6;i++)for(let a=0;a<6;a++)r.push(n([e[t],e[i],e[a]]));let i=8;for(let e=0;e<24;e++,i+=10)r.push(n([i,i,i]));return r}function a(e){return i()[e]}function o(e){switch(e.type){case`named`:return t(e.name);case`rgb`:return n(e.rgb);case`table`:return a(e.index)}}return{value:o}}var AV={black:`#000000`,red:`#cd3131`,green:`#0DBC79`,yellow:`#E5E510`,blue:`#2472C8`,magenta:`#BC3FBC`,cyan:`#11A8CD`,white:`#E5E5E5`,brightBlack:`#666666`,brightRed:`#F14C4C`,brightGreen:`#23D18B`,brightYellow:`#F5F543`,brightBlue:`#3B8EEA`,brightMagenta:`#D670D6`,brightCyan:`#29B8DB`,brightWhite:`#FFFFFF`};function jV(e,t,n){let r=iz(e,n),i=fz(t),a=kV(Object.fromEntries(SV.map(t=>{let n=`terminal.ansi${t[0].toUpperCase()}${t.substring(1)}`;return[t,e.colors?.[n]||AV[t]]}))),o=DV();return i.map(t=>o.parse(t[0]).map(n=>{let i,o;n.decorations.has(`reverse`)?(i=n.background?a.value(n.background):e.bg,o=n.foreground?a.value(n.foreground):e.fg):(i=n.foreground?a.value(n.foreground):e.fg,o=n.background?a.value(n.background):void 0),i=az(i,r),o=az(o,r),n.decorations.has(`dim`)&&(i=MV(i));let s=VL.None;return n.decorations.has(`bold`)&&(s|=VL.Bold),n.decorations.has(`italic`)&&(s|=VL.Italic),n.decorations.has(`underline`)&&(s|=VL.Underline),n.decorations.has(`strikethrough`)&&(s|=VL.Strikethrough),{content:n.value,offset:t[1],color:i,bgColor:o,fontStyle:s}}))}function MV(e){let t=e.match(/#([0-9a-f]{3,8})/i);if(t){let e=t[1];if(e.length===8){let t=Math.round(Number.parseInt(e.slice(6,8),16)/2).toString(16).padStart(2,`0`);return`#${e.slice(0,6)}${t}`}else if(e.length===6)return`#${e}80`;else if(e.length===4){let t=e[0],n=e[1],r=e[2],i=e[3];return`#${t}${t}${n}${n}${r}${r}${Math.round(Number.parseInt(`${i}${i}`,16)/2).toString(16).padStart(2,`0`)}`}else if(e.length===3){let t=e[0],n=e[1],r=e[2];return`#${t}${t}${n}${n}${r}${r}80`}}let n=e.match(/var\((--[\w-]+-ansi-[\w-]+)\)/);return n?`var(${n[1]}-dim)`:e}function NV(e,t,n={}){let r=e.resolveLangAlias(n.lang||`text`),{theme:i=e.getLoadedThemes()[0]}=n;if(!cz(r)&&!uz(i)&&r===`ansi`){let{theme:r}=e.setTheme(i);return jV(r,t,n)}return jz(e,t,n)}function PV(e,t,n){let r,i,a,o,s,c;if(`themes`in n){let{defaultColor:l=`light`,cssVariablePrefix:u=`--shiki-`,colorsRendering:d=`css-vars`}=n,f=Object.entries(n.themes).filter(e=>e[1]).map(e=>({color:e[0],theme:e[1]})).sort((e,t)=>e.color===l?-1:+(t.color===l));if(f.length===0)throw new bL("`themes` option must not be empty");let p=Bz(e,t,n,NV);if(c=Dz(p),l&&lV!==l&&!f.find(e=>e.color===l))throw new bL(`\`themes\` option must contain the defaultColor key \`${l}\``);let m=f.map(t=>e.getTheme(t.theme)),h=f.map(e=>e.color);a=p.map(e=>e.map(e=>pV(e,h,u,l,d))),c&&Ez(a,c);let g=f.map(e=>iz(e.theme,n));i=FV(f,m,g,u,l,`fg`,d),r=FV(f,m,g,u,l,`bg`,d),o=`shiki-themes ${m.map(e=>e.name).join(` `)}`,s=l?void 0:[i,r].join(`;`)}else if(`theme`in n){let s=iz(n.theme,n);a=NV(e,t,n);let l=e.getTheme(n.theme);r=az(l.bg,s),i=az(l.fg,s),o=l.name,c=Dz(a)}else throw new bL("Invalid options, either `theme` or `themes` must be provided");return{tokens:a,fg:i,bg:r,themeName:o,rootStyle:s,grammarState:c}}function FV(e,t,n,r,i,a,o){return e.map((s,c)=>{let l=az(t[c][a],n[c])||`inherit`,u=`${r+s.color}${a===`bg`?`-bg`:``}:${l}`;if(c===0&&i){if(i===lV&&e.length>1){let r=e.findIndex(e=>e.color===`light`),i=e.findIndex(e=>e.color===`dark`);if(r===-1||i===-1)throw new bL('When using `defaultColor: "light-dark()"`, you must provide both `light` and `dark` themes');return`light-dark(${az(t[r][a],n[r])||`inherit`}, ${az(t[i][a],n[i])||`inherit`});${u}`}return l}return o===`css-vars`?u:null}).filter(e=>!!e).join(`;`)}function IV(e,t,n,r={meta:{},options:n,codeToHast:(t,n)=>IV(e,t,n),codeToTokens:(t,n)=>PV(e,t,n)}){let i=t;for(let e of bV(n))i=e.preprocess?.call(r,i,n)||i;let{tokens:a,fg:o,bg:s,themeName:c,rootStyle:l,grammarState:u}=PV(e,i,n),{mergeWhitespaces:d=!0,mergeSameStyleTokens:f=!1}=n;d===!0?a=RV(a):d===`never`&&(a=zV(a)),f&&(a=BV(a));let p={...r,get source(){return i}};for(let e of bV(n))a=e.tokens?.call(p,a)||a;return LV(a,{...n,fg:o,bg:s,themeName:c,rootStyle:n.rootStyle===!1?!1:n.rootStyle??l},p,u)}function LV(e,t,n,r=Dz(e)){let i=bV(t),a=[],o={type:`root`,children:[]},{structure:s=`classic`,tabindex:c=`0`}=t,l={class:`shiki ${t.themeName||``}`};t.rootStyle!==!1&&(t.rootStyle==null?l.style=`background-color:${t.bg};color:${t.fg}`:l.style=t.rootStyle),c!==!1&&c!=null&&(l.tabindex=c.toString());for(let[e,n]of Object.entries(t.meta||{}))e.startsWith(`_`)||(l[e]=n);let u={type:`element`,tagName:`pre`,properties:l,children:[],data:t.data},d={type:`element`,tagName:`code`,properties:{},children:a},f=[],p={...n,structure:s,addClassToHast:oV,get source(){return n.source},get tokens(){return e},get options(){return t},get root(){return o},get pre(){return u},get code(){return d},get lines(){return f}};if(e.forEach((e,t)=>{t&&(s===`inline`?o.children.push({type:`element`,tagName:`br`,properties:{},children:[]}):s===`classic`&&a.push({type:`text`,value:`
208
- `}));let n={type:`element`,tagName:`span`,properties:{class:`line`},children:[]},r=0;for(let a of e){let e={type:`element`,tagName:`span`,properties:{...a.htmlAttrs},children:[{type:`text`,value:a.content}]},c=hV(a.htmlStyle||mV(a));c&&(e.properties.style=c);for(let o of i)e=o?.span?.call(p,e,t+1,r,n,a)||e;s===`inline`?o.children.push(e):s===`classic`&&n.children.push(e),r+=a.content.length}if(s===`classic`){for(let e of i)n=e?.line?.call(p,n,t+1)||n;f.push(n),a.push(n)}else s===`inline`&&f.push(n)}),s===`classic`){for(let e of i)d=e?.code?.call(p,d)||d;u.children.push(d);for(let e of i)u=e?.pre?.call(p,u)||u;o.children.push(u)}else if(s===`inline`){let e=[],t={type:`element`,tagName:`span`,properties:{class:`line`},children:[]};for(let n of o.children)n.type===`element`&&n.tagName===`br`?(e.push(t),t={type:`element`,tagName:`span`,properties:{class:`line`},children:[]}):(n.type===`element`||n.type===`text`)&&t.children.push(n);e.push(t);let n={type:`element`,tagName:`code`,properties:{},children:e};for(let e of i)n=e?.code?.call(p,n)||n;o.children=[];for(let e=0;e<n.children.length;e++){e>0&&o.children.push({type:`element`,tagName:`br`,properties:{},children:[]});let t=n.children[e];t.type===`element`&&o.children.push(...t.children)}}let m=o;for(let e of i)m=e?.root?.call(p,m)||m;return r&&Ez(m,r),m}function RV(e){return e.map(e=>{let t=[],n=``,r;return e.forEach((i,a)=>{let o=!(i.fontStyle&&(i.fontStyle&VL.Underline||i.fontStyle&VL.Strikethrough));o&&i.content.match(/^\s+$/)&&e[a+1]?(r===void 0&&(r=i.offset),n+=i.content):n?(o?t.push({...i,offset:r,content:n+i.content}):t.push({content:n,offset:r},i),r=void 0,n=``):t.push(i)}),t})}function zV(e){return e.map(e=>e.flatMap(e=>{if(e.content.match(/^\s+$/))return e;let t=e.content.match(/^(\s*)(.*?)(\s*)$/);if(!t)return e;let[,n,r,i]=t;if(!n&&!i)return e;let a=[{...e,offset:e.offset+n.length,content:r}];return n&&a.unshift({content:n,offset:e.offset}),i&&a.push({content:i,offset:e.offset+n.length+r.length}),a}))}function BV(e){return e.map(e=>{let t=[];for(let n of e){if(t.length===0){t.push({...n});continue}let e=t[t.length-1],r=hV(e.htmlStyle||mV(e)),i=hV(n.htmlStyle||mV(n)),a=e.fontStyle&&(e.fontStyle&VL.Underline||e.fontStyle&VL.Strikethrough),o=n.fontStyle&&(n.fontStyle&VL.Underline||n.fontStyle&VL.Strikethrough);!a&&!o&&r===i?e.content+=n.content:t.push({...n})}return t})}var VV=rV;function HV(e,t,n){let r={meta:{},options:n,codeToHast:(t,n)=>IV(e,t,n),codeToTokens:(t,n)=>PV(e,t,n)},i=VV(IV(e,t,n,r));for(let e of bV(n))i=e.postprocess?.call(r,i,n)||i;return i}async function UV(e){let t=await wz(e);return{getLastGrammarState:(...e)=>Mz(t,...e),codeToTokensBase:(e,n)=>NV(t,e,n),codeToTokensWithThemes:(e,n)=>Bz(t,e,n),codeToTokens:(e,n)=>PV(t,e,n),codeToHast:(e,n)=>IV(t,e,n),codeToHtml:(e,n)=>HV(t,e,n),getBundledLanguages:()=>({}),getBundledThemes:()=>({}),...t,getInternalContext:()=>t}}function WV(e){let t=e.langs,n=e.themes,r=e.engine;async function i(e){function i(n){if(typeof n==`string`){if(n=e.langAlias?.[n]||n,lz(n))return[];let r=t[n];if(!r)throw new bL(`Language \`${n}\` is not included in this bundle. You may want to load it from external source.`);return r}return n}function a(e){if(dz(e))return`none`;if(typeof e==`string`){let t=n[e];if(!t)throw new bL(`Theme \`${e}\` is not included in this bundle. You may want to load it from external source.`);return t}return e}let o=(e.themes??[]).map(e=>a(e)),s=(e.langs??[]).map(e=>i(e)),c=await UV({engine:e.engine??r(),...e,themes:o,langs:s});return{...c,loadLanguage(...e){return c.loadLanguage(...e.map(i))},loadTheme(...e){return c.loadTheme(...e.map(a))},getBundledLanguages(){return t},getBundledThemes(){return n}}}return i}function GV(e){let t;async function n(n={}){if(t){let e=await t;return await Promise.all([e.loadTheme(...n.themes||[]),e.loadLanguage(...n.langs||[])]),e}else{t=e({...n,themes:[],langs:[]});let r=await t;return await Promise.all([r.loadTheme(...n.themes||[]),r.loadLanguage(...n.langs||[])]),r}}return n}function KV(e,t){let n=GV(e);async function r(e,r){let i=await n({langs:[r.lang],themes:`theme`in r?[r.theme]:Object.values(r.themes)}),a=await t?.guessEmbeddedLanguages?.(e,r.lang,i);return a&&await i.loadLanguage(...a),i}return{getSingletonHighlighter(e){return n(e)},async codeToHtml(e,t){return(await r(e,t)).codeToHtml(e,t)},async codeToHast(e,t){return(await r(e,t)).codeToHast(e,t)},async codeToTokens(e,t){return(await r(e,t)).codeToTokens(e,t)},async codeToTokensBase(e,t){return(await r(e,t)).codeToTokensBase(e,t)},async codeToTokensWithThemes(e,t){return(await r(e,t)).codeToTokensWithThemes(e,t)},async getLastGrammarState(e,t){return(await n({langs:[t.lang],themes:[t.theme]})).getLastGrammarState(e,t)}}}var qV=WV({langs:HI,themes:UI,engine:()=>(0,yL.createOnigurumaEngine)($(()=>import(`./wasm-BNTPmfEI.js`),[]))}),{codeToHtml:JV,codeToHast:YV,codeToTokens:XV,codeToTokensBase:ZV,codeToTokensWithThemes:QV,getSingletonHighlighter:$V,getLastGrammarState:eH}=KV(qV,{guessEmbeddedLanguages:cV});function tH(e){if([...e].length!==1)throw Error(`Expected "${e}" to be a single code point`);return e.codePointAt(0)}function nH(e,t,n){return e.has(t)||e.set(t,n),e.get(t)}var rH=new Set([`alnum`,`alpha`,`ascii`,`blank`,`cntrl`,`digit`,`graph`,`lower`,`print`,`punct`,`space`,`upper`,`word`,`xdigit`]),iH=String.raw;function aH(e,t){if(e==null)throw Error(t??`Value expected`);return e}var oH=iH`\[\^?`,sH=`c.? | C(?:-.?)?|${iH`[pP]\{(?:\^?[-\x20_]*[A-Za-z][-\x20\w]*\})?`}|${iH`x[89A-Fa-f]\p{AHex}(?:\\x[89A-Fa-f]\p{AHex})*`}|${iH`u(?:\p{AHex}{4})? | x\{[^\}]*\}? | x\p{AHex}{0,2}`}|${iH`o\{[^\}]*\}?`}|${iH`\d{1,3}`}`,cH=/[?*+][?+]?|\{(?:\d+(?:,\d*)?|,\d+)\}\??/,lH=new RegExp(iH`
209
- \\ (?:
210
- ${sH}
211
- | [gk]<[^>]*>?
212
- | [gk]'[^']*'?
213
- | .
214
- )
215
- | \( (?:
216
- \? (?:
217
- [:=!>({]
218
- | <[=!]
219
- | <[^>]*>
220
- | '[^']*'
221
- | ~\|?
222
- | #(?:[^)\\]|\\.?)*
223
- | [^:)]*[:)]
224
- )?
225
- | \*[^\)]*\)?
226
- )?
227
- | (?:${cH.source})+
228
- | ${oH}
229
- | .
230
- `.replace(/\s+/g,``),`gsu`),uH=new RegExp(iH`
231
- \\ (?:
232
- ${sH}
233
- | .
234
- )
235
- | \[:(?:\^?\p{Alpha}+|\^):\]
236
- | ${oH}
237
- | &&
238
- | .
239
- `.replace(/\s+/g,``),`gsu`);function dH(e,t={}){let n={flags:``,...t,rules:{captureGroup:!1,singleline:!1,...t.rules}};if(typeof e!=`string`)throw Error(`String expected as pattern`);let r=VH(n.flags),i=[r.extended],a={captureGroup:n.rules.captureGroup,getCurrentModX(){return i.at(-1)},numOpenGroups:0,popModX(){i.pop()},pushModX(e){i.push(e)},replaceCurrentModX(e){i[i.length-1]=e},singleline:n.rules.singleline},o=[],s;for(lH.lastIndex=0;s=lH.exec(e);){let t=fH(a,e,s[0],lH.lastIndex);t.tokens?o.push(...t.tokens):t.token&&o.push(t.token),t.lastIndex!==void 0&&(lH.lastIndex=t.lastIndex)}let c=[],l=0;o.filter(e=>e.type===`GroupOpen`).forEach(e=>{e.kind===`capturing`?e.number=++l:e.raw===`(`&&c.push(e)}),l||c.forEach((e,t)=>{e.kind=`capturing`,e.number=t+1});let u=l||c.length;return{tokens:o.map(e=>e.type===`EscapedNumber`?UH(e,u):e).flat(),flags:r}}function fH(e,t,n,r){let[i,a]=n;if(n===`[`||n===`[^`){let e=pH(t,n,r);return{tokens:e.tokens,lastIndex:e.lastIndex}}if(i===`\\`){if(`AbBGyYzZ`.includes(a))return{token:_H(n,n)};if(/^\\g[<']/.test(n)){if(!/^\\g(?:<[^>]+>|'[^']+')$/.test(n))throw Error(`Invalid group name "${n}"`);return{token:jH(n)}}if(/^\\k[<']/.test(n)){if(!/^\\k(?:<[^>]+>|'[^']+')$/.test(n))throw Error(`Invalid group name "${n}"`);return{token:vH(n)}}if(a===`K`)return{token:TH(`keep`,n)};if(a===`N`||a===`R`)return{token:wH(`newline`,n,{negate:a===`N`})};if(a===`O`)return{token:wH(`any`,n)};if(a===`X`)return{token:wH(`text_segment`,n)};let e=hH(n,{inCharClass:!1});return Array.isArray(e)?{tokens:e}:{token:e}}if(i===`(`){if(a===`*`)return{token:IH(n)};if(n===`(?{`)throw Error(`Unsupported callout "${n}"`);if(n.startsWith(`(?#`)){if(t[r]!==`)`)throw Error(`Unclosed comment group "(?#"`);return{lastIndex:r+1}}if(/^\(\?[-imx]+[:)]$/.test(n))return{token:FH(n,e)};if(e.pushModX(e.getCurrentModX()),e.numOpenGroups++,n===`(`&&!e.captureGroup||n===`(?:`)return{token:OH(`group`,n)};if(n===`(?>`)return{token:OH(`atomic`,n)};if(n===`(?=`||n===`(?!`||n===`(?<=`||n===`(?<!`)return{token:OH(n[2]===`<`?`lookbehind`:`lookahead`,n,{negate:n.endsWith(`!`)})};if(n===`(`&&e.captureGroup||n.startsWith(`(?<`)&&n.endsWith(`>`)||n.startsWith(`(?'`)&&n.endsWith(`'`))return{token:OH(`capturing`,n,{...n!==`(`&&{name:n.slice(3,-1)}})};if(n.startsWith(`(?~`)){if(n===`(?~|`)throw Error(`Unsupported absence function kind "${n}"`);return{token:OH(`absence_repeater`,n)}}throw Error(n===`(?(`?`Unsupported conditional "${n}"`:`Invalid or unsupported group option "${n}"`)}if(n===`)`){if(e.popModX(),e.numOpenGroups--,e.numOpenGroups<0)throw Error(`Unmatched ")"`);return{token:DH(n)}}if(e.getCurrentModX()){if(n===`#`){let e=t.indexOf(`
240
- `,r);return{lastIndex:e===-1?t.length:e}}if(/^\s$/.test(n)){let e=/\s+/y;return e.lastIndex=r,{lastIndex:e.exec(t)?e.lastIndex:r}}}return n===`.`?{token:wH(`dot`,n)}:n===`^`||n===`$`?{token:_H(e.singleline?{"^":iH`\A`,$:iH`\Z`}[n]:n,n)}:n===`|`?{token:gH(n)}:cH.test(n)?{tokens:WH(n)}:{token:yH(tH(n),n)}}function pH(e,t,n){let r=[CH(t[1]===`^`,t)],i=1,a;for(uH.lastIndex=n;a=uH.exec(e);){let e=a[0];if(e[0]===`[`&&e[1]!==`:`)i++,r.push(CH(e[1]===`^`,e));else if(e===`]`){if(r.at(-1).type===`CharacterClassOpen`)r.push(yH(93,e));else if(i--,r.push(bH(e)),!i)break}else{let t=mH(e);Array.isArray(t)?r.push(...t):r.push(t)}}return{tokens:r,lastIndex:uH.lastIndex||e.length}}function mH(e){if(e[0]===`\\`)return hH(e,{inCharClass:!0});if(e[0]===`[`){let t=/\[:(?<negate>\^?)(?<name>[a-z]+):\]/.exec(e);if(!t||!rH.has(t.groups.name))throw Error(`Invalid POSIX class "${e}"`);return wH(`posix`,e,{value:t.groups.name,negate:!!t.groups.negate})}return e===`-`?xH(e):e===`&&`?SH(e):yH(tH(e),e)}function hH(e,{inCharClass:t}){let n=e[1];if(n===`c`||n===`C`)return PH(e);if(`dDhHsSwW`.includes(n))return RH(e);if(e.startsWith(iH`\o{`))throw Error(`Incomplete, invalid, or unsupported octal code point "${e}"`);if(/^\\[pP]\{/.test(e)){if(e.length===3)throw Error(`Incomplete or invalid Unicode property "${e}"`);return zH(e)}if(/^\\x[89A-Fa-f]\p{AHex}/u.test(e))try{let t=e.split(/\\x/).slice(1).map(e=>parseInt(e,16)),n=new TextDecoder(`utf-8`,{ignoreBOM:!0,fatal:!0}).decode(new Uint8Array(t)),r=new TextEncoder;return[...n].map(e=>{let t=[...r.encode(e)].map(e=>`\\x${e.toString(16)}`).join(``);return yH(tH(e),t)})}catch{throw Error(`Multibyte code "${e}" incomplete or invalid in Oniguruma`)}if(n===`u`||n===`x`)return yH(HH(e),e);if(NH.has(n))return yH(NH.get(n),e);if(/\d/.test(n))return EH(t,e);if(e===`\\`)throw Error(iH`Incomplete escape "\"`);if(n===`M`)throw Error(`Unsupported meta "${e}"`);if([...e].length===2)return yH(e.codePointAt(1),e);throw Error(`Unexpected escape "${e}"`)}function gH(e){return{type:`Alternator`,raw:e}}function _H(e,t){return{type:`Assertion`,kind:e,raw:t}}function vH(e){return{type:`Backreference`,raw:e}}function yH(e,t){return{type:`Character`,value:e,raw:t}}function bH(e){return{type:`CharacterClassClose`,raw:e}}function xH(e){return{type:`CharacterClassHyphen`,raw:e}}function SH(e){return{type:`CharacterClassIntersector`,raw:e}}function CH(e,t){return{type:`CharacterClassOpen`,negate:e,raw:t}}function wH(e,t,n={}){return{type:`CharacterSet`,kind:e,...n,raw:t}}function TH(e,t,n={}){return e===`keep`?{type:`Directive`,kind:e,raw:t}:{type:`Directive`,kind:e,flags:aH(n.flags),raw:t}}function EH(e,t){return{type:`EscapedNumber`,inCharClass:e,raw:t}}function DH(e){return{type:`GroupClose`,raw:e}}function OH(e,t,n={}){return{type:`GroupOpen`,kind:e,...n,raw:t}}function kH(e,t,n,r){return{type:`NamedCallout`,kind:e,tag:t,arguments:n,raw:r}}function AH(e,t,n,r){return{type:`Quantifier`,kind:e,min:t,max:n,raw:r}}function jH(e){return{type:`Subroutine`,raw:e}}var MH=new Set([`COUNT`,`CMP`,`ERROR`,`FAIL`,`MAX`,`MISMATCH`,`SKIP`,`TOTAL_COUNT`]),NH=new Map([[`a`,7],[`b`,8],[`e`,27],[`f`,12],[`n`,10],[`r`,13],[`t`,9],[`v`,11]]);function PH(e){let t=e[1]===`c`?e[2]:e[3];if(!t||!/[A-Za-z]/.test(t))throw Error(`Unsupported control character "${e}"`);return yH(tH(t.toUpperCase())-64,e)}function FH(e,t){let{on:n,off:r}=/^\(\?(?<on>[imx]*)(?:-(?<off>[-imx]*))?/.exec(e).groups;r??=``;let i=(t.getCurrentModX()||n.includes(`x`))&&!r.includes(`x`),a=BH(n),o=BH(r),s={};if(a&&(s.enable=a),o&&(s.disable=o),e.endsWith(`)`))return t.replaceCurrentModX(i),TH(`flags`,e,{flags:s});if(e.endsWith(`:`))return t.pushModX(i),t.numOpenGroups++,OH(`group`,e,{...(a||o)&&{flags:s}});throw Error(`Unexpected flag modifier "${e}"`)}function IH(e){let t=/\(\*(?<name>[A-Za-z_]\w*)?(?:\[(?<tag>(?:[A-Za-z_]\w*)?)\])?(?:\{(?<args>[^}]*)\})?\)/.exec(e);if(!t)throw Error(`Incomplete or invalid named callout "${e}"`);let{name:n,tag:r,args:i}=t.groups;if(!n)throw Error(`Invalid named callout "${e}"`);if(r===``)throw Error(`Named callout tag with empty value not allowed "${e}"`);let a=i?i.split(`,`).filter(e=>e!==``).map(e=>/^[+-]?\d+$/.test(e)?+e:e):[],[o,s,c]=a,l=MH.has(n)?n.toLowerCase():`custom`;switch(l){case`fail`:case`mismatch`:case`skip`:if(a.length>0)throw Error(`Named callout arguments not allowed "${a}"`);break;case`error`:if(a.length>1)throw Error(`Named callout allows only one argument "${a}"`);if(typeof o==`string`)throw Error(`Named callout argument must be a number "${o}"`);break;case`max`:if(!a.length||a.length>2)throw Error(`Named callout must have one or two arguments "${a}"`);if(typeof o==`string`&&!/^[A-Za-z_]\w*$/.test(o))throw Error(`Named callout argument one must be a tag or number "${o}"`);if(a.length===2&&(typeof s==`number`||!/^[<>X]$/.test(s)))throw Error(`Named callout optional argument two must be '<', '>', or 'X' "${s}"`);break;case`count`:case`total_count`:if(a.length>1)throw Error(`Named callout allows only one argument "${a}"`);if(a.length===1&&(typeof o==`number`||!/^[<>X]$/.test(o)))throw Error(`Named callout optional argument must be '<', '>', or 'X' "${o}"`);break;case`cmp`:if(a.length!==3)throw Error(`Named callout must have three arguments "${a}"`);if(typeof o==`string`&&!/^[A-Za-z_]\w*$/.test(o))throw Error(`Named callout argument one must be a tag or number "${o}"`);if(typeof s==`number`||!/^(?:[<>!=]=|[<>])$/.test(s))throw Error(`Named callout argument two must be '==', '!=', '>', '<', '>=', or '<=' "${s}"`);if(typeof c==`string`&&!/^[A-Za-z_]\w*$/.test(c))throw Error(`Named callout argument three must be a tag or number "${c}"`);break;case`custom`:throw Error(`Undefined callout name "${n}"`);default:throw Error(`Unexpected named callout kind "${l}"`)}return kH(l,r??null,i?.split(`,`)??null,e)}function LH(e){let t=null,n,r;if(e[0]===`{`){let{minStr:i,maxStr:a}=/^\{(?<minStr>\d*)(?:,(?<maxStr>\d*))?/.exec(e).groups,o=1e5;if(+i>o||a&&+a>o)throw Error(`Quantifier value unsupported in Oniguruma`);if(n=+i,r=a===void 0?+i:a===``?1/0:+a,n>r&&(t=`possessive`,[n,r]=[r,n]),e.endsWith(`?`)){if(t===`possessive`)throw Error(`Unsupported possessive interval quantifier chain with "?"`);t=`lazy`}else t||=`greedy`}else n=+(e[0]===`+`),r=e[0]===`?`?1:1/0,t=e[1]===`+`?`possessive`:e[1]===`?`?`lazy`:`greedy`;return AH(t,n,r,e)}function RH(e){let t=e[1].toLowerCase();return wH({d:`digit`,h:`hex`,s:`space`,w:`word`}[t],e,{negate:e[1]!==t})}function zH(e){let{p:t,neg:n,value:r}=/^\\(?<p>[pP])\{(?<neg>\^?)(?<value>[^}]+)/.exec(e).groups;return wH(`property`,e,{value:r,negate:t===`P`&&!n||t===`p`&&!!n})}function BH(e){let t={};return e.includes(`i`)&&(t.ignoreCase=!0),e.includes(`m`)&&(t.dotAll=!0),e.includes(`x`)&&(t.extended=!0),Object.keys(t).length?t:null}function VH(e){let t={ignoreCase:!1,dotAll:!1,extended:!1,digitIsAscii:!1,posixIsAscii:!1,spaceIsAscii:!1,wordIsAscii:!1,textSegmentMode:null};for(let n=0;n<e.length;n++){let r=e[n];if(!`imxDPSWy`.includes(r))throw Error(`Invalid flag "${r}"`);if(r===`y`){if(!/^y{[gw]}/.test(e.slice(n)))throw Error(`Invalid or unspecified flag "y" mode`);t.textSegmentMode=e[n+2]===`g`?`grapheme`:`word`,n+=3;continue}t[{i:`ignoreCase`,m:`dotAll`,x:`extended`,D:`digitIsAscii`,P:`posixIsAscii`,S:`spaceIsAscii`,W:`wordIsAscii`}[r]]=!0}return t}function HH(e){if(/^(?:\\u(?!\p{AHex}{4})|\\x(?!\p{AHex}{1,2}|\{\p{AHex}{1,8}\}))/u.test(e))throw Error(`Incomplete or invalid escape "${e}"`);let t=e[2]===`{`?/^\\x\{\s*(?<hex>\p{AHex}+)/u.exec(e).groups.hex:e.slice(2);return parseInt(t,16)}function UH(e,t){let{raw:n,inCharClass:r}=e,i=n.slice(1);if(!r&&(i!==`0`&&i.length===1||i[0]!==`0`&&+i<=t))return[vH(n)];let a=[],o=i.match(/^[0-7]+|\d/g);for(let e=0;e<o.length;e++){let t=o[e],r;if(e===0&&t!==`8`&&t!==`9`){if(r=parseInt(t,8),r>127)throw Error(iH`Octal encoded byte above 177 unsupported "${n}"`)}else r=tH(t);a.push(yH(r,(e===0?`\\`:``)+t))}return a}function WH(e){let t=[],n=new RegExp(cH,`gy`),r;for(;r=n.exec(e);){let e=r[0];if(e[0]===`{`){let r=/^\{(?<min>\d+),(?<max>\d+)\}\??$/.exec(e);if(r){let{min:i,max:a}=r.groups;if(+i>+a&&e.endsWith(`?`)){n.lastIndex--,t.push(LH(e.slice(0,-1)));continue}}}t.push(LH(e))}return t}function GH(e,t){if(!Array.isArray(e.body))throw Error(`Expected node with body array`);if(e.body.length!==1)return!1;let n=e.body[0];return!t||Object.keys(t).every(e=>t[e]===n[e])}function KH(e){return qH.has(e.type)}var qH=new Set([`AbsenceFunction`,`Backreference`,`CapturingGroup`,`Character`,`CharacterClass`,`CharacterSet`,`Group`,`Quantifier`,`Subroutine`]);function JH(e,t={}){let n={flags:``,normalizeUnknownPropertyNames:!1,skipBackrefValidation:!1,skipLookbehindValidation:!1,skipPropertyNameValidation:!1,unicodePropertyMap:null,...t,rules:{captureGroup:!1,singleline:!1,...t.rules}},r=dH(e,{flags:n.flags,rules:{captureGroup:n.rules.captureGroup,singleline:n.rules.singleline}}),i=(e,t)=>{let n=r.tokens[a.nextIndex];switch(a.parent=e,a.nextIndex++,n.type){case`Alternator`:return iU();case`Assertion`:return YH(n);case`Backreference`:return XH(n,a);case`Character`:return cU(n.value,{useLastValid:!!t.isCheckingRangeEnd});case`CharacterClassHyphen`:return ZH(n,a,t);case`CharacterClassOpen`:return QH(n,a,t);case`CharacterSet`:return $H(n,a);case`Directive`:return fU(n.kind,{flags:n.flags});case`GroupOpen`:return eU(n,a,t);case`NamedCallout`:return gU(n.kind,n.tag,n.arguments);case`Quantifier`:return tU(n,a);case`Subroutine`:return nU(n,a);default:throw Error(`Unexpected token type "${n.type}"`)}},a={capturingGroups:[],hasNumberedRef:!1,namedGroupsByName:new Map,nextIndex:0,normalizeUnknownPropertyNames:n.normalizeUnknownPropertyNames,parent:null,skipBackrefValidation:n.skipBackrefValidation,skipLookbehindValidation:n.skipLookbehindValidation,skipPropertyNameValidation:n.skipPropertyNameValidation,subroutines:[],tokens:r.tokens,unicodePropertyMap:n.unicodePropertyMap,walk:i},o=yU(pU(r.flags)),s=o.body[0];for(;a.nextIndex<r.tokens.length;){let e=i(s,{});e.type===`Alternative`?(o.body.push(e),s=e):s.body.push(e)}let{capturingGroups:c,hasNumberedRef:l,namedGroupsByName:u,subroutines:d}=a;if(l&&u.size&&!n.rules.captureGroup)throw Error(`Numbered backref/subroutine not allowed when using named capture`);for(let{ref:e}of d)if(typeof e==`number`){if(e>c.length)throw Error(`Subroutine uses a group number that's not defined`);e&&(c[e-1].isSubroutined=!0)}else if(u.has(e)){if(u.get(e).length>1)throw Error(iH`Subroutine uses a duplicate group name "\g<${e}>"`);u.get(e)[0].isSubroutined=!0}else throw Error(iH`Subroutine uses a group name that's not defined "\g<${e}>"`);return o}function YH({kind:e}){return aU(aH({"^":`line_start`,$:`line_end`,"\\A":`string_start`,"\\b":`word_boundary`,"\\B":`word_boundary`,"\\G":`search_start`,"\\y":`text_segment_boundary`,"\\Y":`text_segment_boundary`,"\\z":`string_end`,"\\Z":`string_end_newline`}[e],`Unexpected assertion kind "${e}"`),{negate:e===iH`\B`||e===iH`\Y`})}function XH({raw:e},t){let n=/^\\k[<']/.test(e),r=n?e.slice(3,-1):e.slice(1),i=(n,r=!1)=>{let i=t.capturingGroups.length,a=!1;if(n>i)if(t.skipBackrefValidation)a=!0;else throw Error(`Not enough capturing groups defined to the left "${e}"`);return t.hasNumberedRef=!0,oU(r?i+1-n:n,{orphan:a})};if(n){let n=/^(?<sign>-?)0*(?<num>[1-9]\d*)$/.exec(r);if(n)return i(+n.groups.num,!!n.groups.sign);if(/[-+]/.test(r))throw Error(`Invalid backref name "${e}"`);if(!t.namedGroupsByName.has(r))throw Error(`Group name not defined to the left "${e}"`);return oU(r)}return i(+r)}function ZH(e,t,n){let{tokens:r,walk:i}=t,a=t.parent,o=a.body.at(-1),s=r[t.nextIndex];if(!n.isCheckingRangeEnd&&o&&o.type!==`CharacterClass`&&o.type!==`CharacterClassRange`&&s&&s.type!==`CharacterClassOpen`&&s.type!==`CharacterClassClose`&&s.type!==`CharacterClassIntersector`){let e=i(a,{...n,isCheckingRangeEnd:!0});if(o.type===`Character`&&e.type===`Character`)return a.body.pop(),uU(o,e);throw Error(`Invalid character class range`)}return cU(tH(`-`))}function QH({negate:e},t,n){let{tokens:r,walk:i}=t,a=[lU()],o=r[t.nextIndex],s=AU(o);for(;s.type!==`CharacterClassClose`;){if(s.type===`CharacterClassIntersector`)a.push(lU()),t.nextIndex++;else{let e=a.at(-1);e.body.push(i(e,n))}s=AU(r[t.nextIndex],o)}let c=lU({negate:e});return a.length===1?c.body=a[0].body:(c.kind=`intersection`,c.body=a.map(e=>e.body.length===1?e.body[0]:e)),t.nextIndex++,c}function $H({kind:e,negate:t,value:n},r){let{normalizeUnknownPropertyNames:i,skipPropertyNameValidation:a,unicodePropertyMap:o}=r;if(e===`property`){let r=kU(n);if(rH.has(r)&&!o?.has(r))e=`posix`,n=r;else return xU(n,{negate:t,normalizeUnknownPropertyNames:i,skipPropertyNameValidation:a,unicodePropertyMap:o})}return e===`posix`?_U(n,{negate:t}):dU(e,{negate:t})}function eU(e,t,n){let{tokens:r,capturingGroups:i,namedGroupsByName:a,skipLookbehindValidation:o,walk:s}=t,c=SU(e),l=c.type===`AbsenceFunction`,u=EU(c),d=u&&c.negate;if(c.type===`CapturingGroup`&&(i.push(c),c.name&&nH(a,c.name,[]).push(c)),l&&n.isInAbsenceFunction)throw Error(`Nested absence function not supported by Oniguruma`);let f=jU(r[t.nextIndex]);for(;f.type!==`GroupClose`;){if(f.type===`Alternator`)c.body.push(iU()),t.nextIndex++;else{let e=c.body.at(-1),t=s(e,{...n,isInAbsenceFunction:n.isInAbsenceFunction||l,isInLookbehind:n.isInLookbehind||u,isInNegLookbehind:n.isInNegLookbehind||d});if(e.body.push(t),(u||n.isInLookbehind)&&!o){let e=`Lookbehind includes a pattern not allowed by Oniguruma`;if(d||n.isInNegLookbehind){if(TU(t)||t.type===`CapturingGroup`)throw Error(e)}else if(TU(t)||EU(t)&&t.negate)throw Error(e)}}f=jU(r[t.nextIndex])}return t.nextIndex++,c}function tU({kind:e,min:t,max:n},r){let i=r.parent,a=i.body.at(-1);if(!a||!KH(a))throw Error(`Quantifier requires a repeatable token`);let o=vU(e,t,n,a);return i.body.pop(),o}function nU({raw:e},t){let{capturingGroups:n,subroutines:r}=t,i=e.slice(3,-1),a=/^(?<sign>[-+]?)0*(?<num>[1-9]\d*)$/.exec(i);if(a){let e=+a.groups.num,r=n.length;if(t.hasNumberedRef=!0,i={"":e,"+":r+e,"-":r+1-e}[a.groups.sign],i<1)throw Error(`Invalid subroutine number`)}else i===`0`&&(i=0);let o=bU(i);return r.push(o),o}function rU(e,t){if(e!==`repeater`)throw Error(`Unexpected absence function kind "${e}"`);return{type:`AbsenceFunction`,kind:e,body:CU(t?.body)}}function iU(e){return{type:`Alternative`,body:wU(e?.body)}}function aU(e,t){let n={type:`Assertion`,kind:e};return(e===`word_boundary`||e===`text_segment_boundary`)&&(n.negate=!!t?.negate),n}function oU(e,t){let n=!!t?.orphan;return{type:`Backreference`,ref:e,...n&&{orphan:n}}}function sU(e,t){let n={name:void 0,isSubroutined:!1,...t};if(n.name!==void 0&&!DU(n.name))throw Error(`Group name "${n.name}" invalid in Oniguruma`);return{type:`CapturingGroup`,number:e,...n.name&&{name:n.name},...n.isSubroutined&&{isSubroutined:n.isSubroutined},body:CU(t?.body)}}function cU(e,t){let n={useLastValid:!1,...t};if(e>1114111){let t=e.toString(16);if(n.useLastValid)e=1114111;else throw Error(e>1310719?`Invalid code point out of range "\\x{${t}}"`:`Invalid code point out of range in JS "\\x{${t}}"`)}return{type:`Character`,value:e}}function lU(e){let t={kind:`union`,negate:!1,...e};return{type:`CharacterClass`,kind:t.kind,negate:t.negate,body:wU(e?.body)}}function uU(e,t){if(t.value<e.value)throw Error(`Character class range out of order`);return{type:`CharacterClassRange`,min:e,max:t}}function dU(e,t){let n=!!t?.negate,r={type:`CharacterSet`,kind:e};return(e===`digit`||e===`hex`||e===`newline`||e===`space`||e===`word`)&&(r.negate=n),(e===`text_segment`||e===`newline`&&!n)&&(r.variableLength=!0),r}function fU(e,t={}){if(e===`keep`)return{type:`Directive`,kind:e};if(e===`flags`)return{type:`Directive`,kind:e,flags:aH(t.flags)};throw Error(`Unexpected directive kind "${e}"`)}function pU(e){return{type:`Flags`,...e}}function mU(e){let t=e?.atomic,n=e?.flags;if(t&&n)throw Error(`Atomic group cannot have flags`);return{type:`Group`,...t&&{atomic:t},...n&&{flags:n},body:CU(e?.body)}}function hU(e){let t={behind:!1,negate:!1,...e};return{type:`LookaroundAssertion`,kind:t.behind?`lookbehind`:`lookahead`,negate:t.negate,body:CU(e?.body)}}function gU(e,t,n){return{type:`NamedCallout`,kind:e,tag:t,arguments:n}}function _U(e,t){let n=!!t?.negate;if(!rH.has(e))throw Error(`Invalid POSIX class "${e}"`);return{type:`CharacterSet`,kind:`posix`,value:e,negate:n}}function vU(e,t,n,r){if(t>n)throw Error(`Invalid reversed quantifier range`);return{type:`Quantifier`,kind:e,min:t,max:n,body:r}}function yU(e,t){return{type:`Regex`,body:CU(t?.body),flags:e}}function bU(e){return{type:`Subroutine`,ref:e}}function xU(e,t){let n={negate:!1,normalizeUnknownPropertyNames:!1,skipPropertyNameValidation:!1,unicodePropertyMap:null,...t},r=n.unicodePropertyMap?.get(kU(e));if(!r){if(n.normalizeUnknownPropertyNames)r=OU(e);else if(n.unicodePropertyMap&&!n.skipPropertyNameValidation)throw Error(iH`Invalid Unicode property "\p{${e}}"`)}return{type:`CharacterSet`,kind:`property`,value:r??e,negate:n.negate}}function SU({flags:e,kind:t,name:n,negate:r,number:i}){switch(t){case`absence_repeater`:return rU(`repeater`);case`atomic`:return mU({atomic:!0});case`capturing`:return sU(i,{name:n});case`group`:return mU({flags:e});case`lookahead`:case`lookbehind`:return hU({behind:t===`lookbehind`,negate:r});default:throw Error(`Unexpected group kind "${t}"`)}}function CU(e){if(e===void 0)e=[iU()];else if(!Array.isArray(e)||!e.length||!e.every(e=>e.type===`Alternative`))throw Error(`Invalid body; expected array of one or more Alternative nodes`);return e}function wU(e){if(e===void 0)e=[];else if(!Array.isArray(e)||!e.every(e=>!!e.type))throw Error(`Invalid body; expected array of nodes`);return e}function TU(e){return e.type===`LookaroundAssertion`&&e.kind===`lookahead`}function EU(e){return e.type===`LookaroundAssertion`&&e.kind===`lookbehind`}function DU(e){return/^[\p{Alpha}\p{Pc}][^)]*$/u.test(e)}function OU(e){return e.trim().replace(/[- _]+/g,`_`).replace(/[A-Z][a-z]+(?=[A-Z])/g,`$&_`).replace(/[A-Za-z]+/g,e=>e[0].toUpperCase()+e.slice(1).toLowerCase())}function kU(e){return e.replace(/[- _]+/g,``).toLowerCase()}function AU(e,t){let n=t;return aH(e,`Unclosed character class${n?.type===`Character`&&n.value===93&&n.raw===`]`?` (started with "]")`:``}`)}function jU(e){return aH(e,`Unclosed group`)}function MU(e,t,n=null){function r(e,t){for(let n=0;n<e.length;n++){let r=i(e[n],t,n,e);n=Math.max(-1,n+r)}}function i(a,o=null,s=null,c=null){let l=0,u=!1,d={node:a,parent:o,key:s,container:c,root:e,remove(){NU(c).splice(Math.max(0,PU(s)+l),1),l--,u=!0},removeAllNextSiblings(){return NU(c).splice(PU(s)+1)},removeAllPrevSiblings(){let e=PU(s)+l;return l-=e,NU(c).splice(0,Math.max(0,e))},replaceWith(e,t={}){let n=!!t.traverse;c?c[Math.max(0,PU(s)+l)]=e:aH(o,`Can't replace root node`)[s]=e,n&&i(e,o,s,c),u=!0},replaceWithMultiple(e,t={}){let n=!!t.traverse;if(NU(c).splice(Math.max(0,PU(s)+l),1,...e),l+=e.length-1,n){let t=0;for(let n=0;n<e.length;n++)t+=i(e[n],o,PU(s)+n+t,c)}u=!0},skip(){u=!0}},{type:f}=a,p=t[`*`],m=t[f],h=typeof p==`function`?p:p?.enter,g=typeof m==`function`?m:m?.enter;if(h?.(d,n),g?.(d,n),!u)switch(f){case`AbsenceFunction`:case`Alternative`:case`CapturingGroup`:case`CharacterClass`:case`Group`:case`LookaroundAssertion`:r(a.body,a);break;case`Assertion`:case`Backreference`:case`Character`:case`CharacterSet`:case`Directive`:case`Flags`:case`NamedCallout`:case`Subroutine`:break;case`CharacterClassRange`:i(a.min,a,`min`),i(a.max,a,`max`);break;case`Quantifier`:i(a.body,a,`body`);break;case`Regex`:r(a.body,a),i(a.flags,a,`flags`);break;default:throw Error(`Unexpected node type "${f}"`)}return m?.exit?.(d,n),p?.exit?.(d,n),l}return i(e),e}function NU(e){if(!Array.isArray(e))throw Error(`Container expected`);return e}function PU(e){if(typeof e!=`number`)throw Error(`Numeric key expected`);return e}var FU=String.raw`\(\?(?:[:=!>A-Za-z\-]|<[=!]|\(DEFINE\))`;function IU(e,t){for(let n=0;n<e.length;n++)e[n]>=t&&e[n]++}function LU(e,t,n,r){return e.slice(0,t)+r+e.slice(t+n.length)}var RU=Object.freeze({DEFAULT:`DEFAULT`,CHAR_CLASS:`CHAR_CLASS`});function zU(e,t,n,r){let i=new RegExp(String.raw`${t}|(?<$skip>\[\^?|\\?.)`,`gsu`),a=[!1],o=0,s=``;for(let t of e.matchAll(i)){let{0:e,groups:{$skip:i}}=t;if(!i&&(!r||r===RU.DEFAULT==!o)){n instanceof Function?s+=n(t,{context:o?RU.CHAR_CLASS:RU.DEFAULT,negated:a[a.length-1]}):s+=n;continue}e[0]===`[`?(o++,a.push(e[1]===`^`)):e===`]`&&o&&(o--,a.pop()),s+=e}return s}function BU(e,t,n,r){zU(e,t,n,r)}function VU(e,t,n=0,r){if(!new RegExp(t,`su`).test(e))return null;let i=RegExp(`${t}|(?<$skip>\\\\?.)`,`gsu`);i.lastIndex=n;let a=0,o;for(;o=i.exec(e);){let{0:e,groups:{$skip:t}}=o;if(!t&&(!r||r===RU.DEFAULT==!a))return o;e===`[`?a++:e===`]`&&a&&a--,i.lastIndex==o.index&&i.lastIndex++}return null}function HU(e,t,n){return!!VU(e,t,0,n)}function UU(e,t){let n=/\\?./gsu;n.lastIndex=t;let r=e.length,i=0,a=1,o;for(;o=n.exec(e);){let[e]=o;if(e===`[`)i++;else if(i)e===`]`&&i--;else if(e===`(`)a++;else if(e===`)`&&(a--,!a)){r=o.index;break}}return e.slice(t,r)}var WU=new RegExp(String.raw`(?<noncapturingStart>${FU})|(?<capturingStart>\((?:\?<[^>]+>)?)|\\?.`,`gsu`);function GU(e,t){let n=t?.hiddenCaptures??[],r=t?.captureTransfers??new Map;if(!/\(\?>/.test(e))return{pattern:e,captureTransfers:r,hiddenCaptures:n};let i=[0],a=[],o=0,s=0,c=NaN,l;do{l=!1;let t=0,u=0,d=!1,f;for(WU.lastIndex=Number.isNaN(c)?0:c+7;f=WU.exec(e);){let{0:p,index:m,groups:{capturingStart:h,noncapturingStart:g}}=f;if(p===`[`)t++;else if(t)p===`]`&&t--;else if(p===`(?>`&&!d)c=m,d=!0;else if(d&&g)u++;else if(h)d?u++:(o++,i.push(o+s));else if(p===`)`&&d){if(!u){s++;let t=o+s;if(e=`${e.slice(0,c)}(?:(?=(${e.slice(c+3,m)}))<$$${t}>)${e.slice(m+1)}`,l=!0,a.push(t),IU(n,t),r.size){let e=new Map;r.forEach((n,r)=>{e.set(r>=t?r+1:r,n.map(e=>e>=t?e+1:e))}),r=e}break}u--}}}while(l);return n.push(...a),e=zU(e,String.raw`\\(?<backrefNum>[1-9]\d*)|<\$\$(?<wrappedBackrefNum>\d+)>`,({0:e,groups:{backrefNum:t,wrappedBackrefNum:n}})=>{if(t){let n=+t;if(n>i.length-1)throw Error(`Backref "${e}" greater than number of captures`);return`\\${i[n]}`}return`\\${n}`},RU.DEFAULT),{pattern:e,captureTransfers:r,hiddenCaptures:n}}var KU=String.raw`(?:[?*+]|\{\d+(?:,\d*)?\})`,qU=new RegExp(String.raw`
241
- \\(?: \d+
242
- | c[A-Za-z]
243
- | [gk]<[^>]+>
244
- | [pPu]\{[^\}]+\}
245
- | u[A-Fa-f\d]{4}
246
- | x[A-Fa-f\d]{2}
247
- )
248
- | \((?: \? (?: [:=!>]
249
- | <(?:[=!]|[^>]+>)
250
- | [A-Za-z\-]+:
251
- | \(DEFINE\)
252
- ))?
253
- | (?<qBase>${KU})(?<qMod>[?+]?)(?<invalidQ>[?*+\{]?)
254
- | \\?.
255
- `.replace(/\s+/g,``),`gsu`);function JU(e){if(!RegExp(`${KU}\\+`).test(e))return{pattern:e};let t=[],n=null,r=null,i=``,a=0,o;for(qU.lastIndex=0;o=qU.exec(e);){let{0:s,index:c,groups:{qBase:l,qMod:u,invalidQ:d}}=o;if(s===`[`)a||(r=c),a++;else if(s===`]`)a?a--:r=null;else if(!a)if(u===`+`&&i&&!i.startsWith(`(`)){if(d)throw Error(`Invalid quantifier "${s}"`);let t=-1;if(/^\{\d+\}$/.test(l))e=LU(e,c+l.length,u,``);else{if(i===`)`||i===`]`){let t=i===`)`?n:r;if(t===null)throw Error(`Invalid unmatched "${i}"`);e=`${e.slice(0,t)}(?>${e.slice(t,c)}${l})${e.slice(c+s.length)}`}else e=`${e.slice(0,c-i.length)}(?>${i}${l})${e.slice(c+s.length)}`;t+=4}qU.lastIndex+=t}else s[0]===`(`?t.push(c):s===`)`&&(n=t.length?t.pop():null);i=s}return{pattern:e}}var YU=String.raw,XU=YU`\(\?R=(?<rDepth>[^\)]+)\)|${YU`\\g<(?<gRNameOrNum>[^>&]+)&R=(?<gRDepth>[^>]+)>`}`,ZU=YU`\(\?<(?![=!])(?<captureName>[^>]+)>`,QU=YU`${ZU}|(?<unnamed>\()(?!\?)`,$U=new RegExp(YU`${ZU}|${XU}|\(\?|\\?.`,`gsu`),eW=`Cannot use multiple overlapping recursions`;function tW(e,t){let{hiddenCaptures:n,mode:r}={hiddenCaptures:[],mode:`plugin`,...t},i=t?.captureTransfers??new Map;if(!new RegExp(XU,`su`).test(e))return{pattern:e,captureTransfers:i,hiddenCaptures:n};if(r===`plugin`&&HU(e,YU`\(\?\(DEFINE\)`,RU.DEFAULT))throw Error(`DEFINE groups cannot be used with recursion`);let a=[],o=HU(e,YU`\\[1-9]`,RU.DEFAULT),s=new Map,c=[],l=!1,u=0,d=0,f;for($U.lastIndex=0;f=$U.exec(e);){let{0:t,groups:{captureName:p,rDepth:m,gRNameOrNum:h,gRDepth:g}}=f;if(t===`[`)u++;else if(u)t===`]`&&u--;else if(m){if(nW(m),l)throw Error(eW);if(o)throw Error(`${r===`external`?`Backrefs`:`Numbered backrefs`} cannot be used with global recursion`);let t=e.slice(0,f.index),s=e.slice($U.lastIndex);if(HU(s,XU,RU.DEFAULT))throw Error(eW);let c=m-1;e=rW(t,s,c,!1,n,a,d),i=oW(i,t,c,a.length,0,d);break}else if(h){nW(g);let u=!1;for(let e of c)if(e.name===h||e.num===+h){if(u=!0,e.hasRecursedWithin)throw Error(eW);break}if(!u)throw Error(YU`Recursive \g cannot be used outside the referenced group "${r===`external`?h:YU`\g<${h}&R=${g}>`}"`);let p=s.get(h),m=UU(e,p);if(o&&HU(m,YU`${ZU}|\((?!\?)`,RU.DEFAULT))throw Error(`${r===`external`?`Backrefs`:`Numbered backrefs`} cannot be used with recursion of capturing groups`);let _=e.slice(p,f.index),v=m.slice(_.length+t.length),y=a.length,b=g-1,x=rW(_,v,b,!0,n,a,d);i=oW(i,_,b,a.length-y,y,d),e=`${e.slice(0,p)}${x}${e.slice(p+m.length)}`,$U.lastIndex+=x.length-t.length-_.length-v.length,c.forEach(e=>e.hasRecursedWithin=!0),l=!0}else if(p)d++,s.set(String(d),$U.lastIndex),s.set(p,$U.lastIndex),c.push({num:d,name:p});else if(t[0]===`(`){let e=t===`(`;e&&(d++,s.set(String(d),$U.lastIndex)),c.push(e?{num:d}:{})}else t===`)`&&c.pop()}return n.push(...a),{pattern:e,captureTransfers:i,hiddenCaptures:n}}function nW(e){let t=`Max depth must be integer between 2 and 100; used ${e}`;if(!/^[1-9]\d*$/.test(e)||(e=+e,e<2||e>100))throw Error(t)}function rW(e,t,n,r,i,a,o){let s=new Set;r&&BU(e+t,ZU,({groups:{captureName:e}})=>{s.add(e)},RU.DEFAULT);let c=[n,r?s:null,i,a,o];return`${e}${iW(`(?:${e}`,`forward`,...c)}(?:)${iW(`${t})`,`backward`,...c)}${t}`}function iW(e,t,n,r,i,a,o){let s=e=>t===`forward`?e+2:n-e+2-1,c=``;for(let t=0;t<n;t++){let n=s(t);c+=zU(e,YU`${QU}|\\k<(?<backref>[^>]+)>`,({0:e,groups:{captureName:t,unnamed:s,backref:c}})=>{if(c&&r&&!r.has(c))return e;let l=`_$${n}`;if(s||t){let n=o+a.length+1;return a.push(n),aW(i,n),s?e:`(?<${t}${l}>`}return YU`\k<${c}${l}>`},RU.DEFAULT)}return c}function aW(e,t){for(let n=0;n<e.length;n++)e[n]>=t&&e[n]++}function oW(e,t,n,r,i,a){if(e.size&&r){let o=0;BU(t,QU,()=>o++,RU.DEFAULT);let s=a-o+i,c=new Map;return e.forEach((e,t)=>{let i=(r-o*n)/n,a=o*n,l=t>s+o?t+r:t,u=[];for(let t of e)if(t<=s)u.push(t);else if(t>s+o+i)u.push(t+r);else if(t<=s+o)for(let e=0;e<=n;e++)u.push(t+o*e);else for(let e=0;e<=n;e++)u.push(t+a+i*e);c.set(l,u)}),c}return e}var sW=String.fromCodePoint,cW=String.raw,lW={},uW=globalThis.RegExp;lW.flagGroups=(()=>{try{new uW(`(?i:)`)}catch{return!1}return!0})(),lW.unicodeSets=(()=>{try{new uW(`[[]]`,`v`)}catch{return!1}return!0})(),lW.bugFlagVLiteralHyphenIsRange=lW.unicodeSets?(()=>{try{new uW(cW`[\d\-a]`,`v`)}catch{return!0}return!1})():!1,lW.bugNestedClassIgnoresNegation=lW.unicodeSets&&new uW(`[[^a]]`,`v`).test(`a`);function dW(e,{enable:t,disable:n}){return{dotAll:!n?.dotAll&&!!(t?.dotAll||e.dotAll),ignoreCase:!n?.ignoreCase&&!!(t?.ignoreCase||e.ignoreCase)}}function fW(e,t,n){return e.has(t)||e.set(t,n),e.get(t)}function pW(e,t){return hW[e]>=hW[t]}function mW(e,t){if(e==null)throw Error(t??`Value expected`);return e}var hW={ES2025:2025,ES2024:2024,ES2018:2018},gW={auto:`auto`,ES2025:`ES2025`,ES2024:`ES2024`,ES2018:`ES2018`};function _W(e={}){if({}.toString.call(e)!==`[object Object]`)throw Error(`Unexpected options`);if(e.target!==void 0&&!gW[e.target])throw Error(`Unexpected target "${e.target}"`);let t={accuracy:`default`,avoidSubclass:!1,flags:``,global:!1,hasIndices:!1,lazyCompileLength:1/0,target:`auto`,verbose:!1,...e,rules:{allowOrphanBackrefs:!1,asciiWordBoundaries:!1,captureGroup:!1,recursionLimit:20,singleline:!1,...e.rules}};return t.target===`auto`&&(t.target=lW.flagGroups?`ES2025`:lW.unicodeSets?`ES2024`:`ES2018`),t}var vW=`[ -\r ]`,yW=new Set([sW(304),sW(305)]),bW=cW`[\p{L}\p{M}\p{N}\p{Pc}]`;function xW(e){if(yW.has(e))return[e];let t=new Set,n=e.toLowerCase(),r=n.toUpperCase(),i=TW.get(n),a=CW.get(n),o=wW.get(n);return[...r].length===1&&t.add(r),o&&t.add(o),i&&t.add(i),t.add(n),a&&t.add(a),[...t]}var SW=new Map(`C Other
256
- Cc Control cntrl
257
- Cf Format
258
- Cn Unassigned
259
- Co Private_Use
260
- Cs Surrogate
261
- L Letter
262
- LC Cased_Letter
263
- Ll Lowercase_Letter
264
- Lm Modifier_Letter
265
- Lo Other_Letter
266
- Lt Titlecase_Letter
267
- Lu Uppercase_Letter
268
- M Mark Combining_Mark
269
- Mc Spacing_Mark
270
- Me Enclosing_Mark
271
- Mn Nonspacing_Mark
272
- N Number
273
- Nd Decimal_Number digit
274
- Nl Letter_Number
275
- No Other_Number
276
- P Punctuation punct
277
- Pc Connector_Punctuation
278
- Pd Dash_Punctuation
279
- Pe Close_Punctuation
280
- Pf Final_Punctuation
281
- Pi Initial_Punctuation
282
- Po Other_Punctuation
283
- Ps Open_Punctuation
284
- S Symbol
285
- Sc Currency_Symbol
286
- Sk Modifier_Symbol
287
- Sm Math_Symbol
288
- So Other_Symbol
289
- Z Separator
290
- Zl Line_Separator
291
- Zp Paragraph_Separator
292
- Zs Space_Separator
293
- ASCII
294
- ASCII_Hex_Digit AHex
295
- Alphabetic Alpha
296
- Any
297
- Assigned
298
- Bidi_Control Bidi_C
299
- Bidi_Mirrored Bidi_M
300
- Case_Ignorable CI
301
- Cased
302
- Changes_When_Casefolded CWCF
303
- Changes_When_Casemapped CWCM
304
- Changes_When_Lowercased CWL
305
- Changes_When_NFKC_Casefolded CWKCF
306
- Changes_When_Titlecased CWT
307
- Changes_When_Uppercased CWU
308
- Dash
309
- Default_Ignorable_Code_Point DI
310
- Deprecated Dep
311
- Diacritic Dia
312
- Emoji
313
- Emoji_Component EComp
314
- Emoji_Modifier EMod
315
- Emoji_Modifier_Base EBase
316
- Emoji_Presentation EPres
317
- Extended_Pictographic ExtPict
318
- Extender Ext
319
- Grapheme_Base Gr_Base
320
- Grapheme_Extend Gr_Ext
321
- Hex_Digit Hex
322
- IDS_Binary_Operator IDSB
323
- IDS_Trinary_Operator IDST
324
- ID_Continue IDC
325
- ID_Start IDS
326
- Ideographic Ideo
327
- Join_Control Join_C
328
- Logical_Order_Exception LOE
329
- Lowercase Lower
330
- Math
331
- Noncharacter_Code_Point NChar
332
- Pattern_Syntax Pat_Syn
333
- Pattern_White_Space Pat_WS
334
- Quotation_Mark QMark
335
- Radical
336
- Regional_Indicator RI
337
- Sentence_Terminal STerm
338
- Soft_Dotted SD
339
- Terminal_Punctuation Term
340
- Unified_Ideograph UIdeo
341
- Uppercase Upper
342
- Variation_Selector VS
343
- White_Space space
344
- XID_Continue XIDC
345
- XID_Start XIDS`.split(/\s/).map(e=>[kU(e),e])),CW=new Map([[`s`,sW(383)],[sW(383),`s`]]),wW=new Map([[sW(223),sW(7838)],[sW(107),sW(8490)],[sW(229),sW(8491)],[sW(969),sW(8486)]]),TW=new Map([OW(453),OW(456),OW(459),OW(498),...kW(8072,8079),...kW(8088,8095),...kW(8104,8111),OW(8124),OW(8140),OW(8188)]),EW=new Map([[`alnum`,cW`[\p{Alpha}\p{Nd}]`],[`alpha`,cW`\p{Alpha}`],[`ascii`,cW`\p{ASCII}`],[`blank`,cW`[\p{Zs}\t]`],[`cntrl`,cW`\p{Cc}`],[`digit`,cW`\p{Nd}`],[`graph`,cW`[\P{space}&&\P{Cc}&&\P{Cn}&&\P{Cs}]`],[`lower`,cW`\p{Lower}`],[`print`,cW`[[\P{space}&&\P{Cc}&&\P{Cn}&&\P{Cs}]\p{Zs}]`],[`punct`,cW`[\p{P}\p{S}]`],[`space`,cW`\p{space}`],[`upper`,cW`\p{Upper}`],[`word`,cW`[\p{Alpha}\p{M}\p{Nd}\p{Pc}]`],[`xdigit`,cW`\p{AHex}`]]);function DW(e,t){let n=[];for(let r=e;r<=t;r++)n.push(r);return n}function OW(e){let t=sW(e);return[t.toLowerCase(),t]}function kW(e,t){return DW(e,t).map(e=>OW(e))}var AW=new Set([`Lower`,`Lowercase`,`Upper`,`Uppercase`,`Ll`,`Lowercase_Letter`,`Lt`,`Titlecase_Letter`,`Lu`,`Uppercase_Letter`]);function jW(e,t){let n={accuracy:`default`,asciiWordBoundaries:!1,avoidSubclass:!1,bestEffortTarget:`ES2025`,...t};FW(e);let r={accuracy:n.accuracy,asciiWordBoundaries:n.asciiWordBoundaries,avoidSubclass:n.avoidSubclass,flagDirectivesByAlt:new Map,jsGroupNameMap:new Map,minTargetEs2024:pW(n.bestEffortTarget,`ES2024`),passedLookbehind:!1,strategy:null,subroutineRefMap:new Map,supportedGNodes:new Set,digitIsAscii:e.flags.digitIsAscii,spaceIsAscii:e.flags.spaceIsAscii,wordIsAscii:e.flags.wordIsAscii};MU(e,MW,r);let i={dotAll:e.flags.dotAll,ignoreCase:e.flags.ignoreCase},a={currentFlags:i,prevFlags:null,globalFlags:i,groupOriginByCopy:new Map,groupsByName:new Map,multiplexCapturesToLeftByRef:new Map,openRefs:new Map,reffedNodesByReferencer:new Map,subroutineRefMap:r.subroutineRefMap};return MU(e,NW,a),MU(e,PW,{groupsByName:a.groupsByName,highestOrphanBackref:0,numCapturesToLeft:0,reffedNodesByReferencer:a.reffedNodesByReferencer}),e._originMap=a.groupOriginByCopy,e._strategy=r.strategy,e}var MW={AbsenceFunction({node:e,parent:t,replaceWith:n}){let{body:r,kind:i}=e;if(i===`repeater`){let e=mU();e.body[0].body.push(hU({negate:!0,body:r}),xU(`Any`));let i=mU();i.body[0].body.push(vU(`greedy`,0,1/0,e)),n(eG(i,t),{traverse:!0})}else throw Error(`Unsupported absence function "(?~|"`)},Alternative:{enter({node:e,parent:t,key:n},{flagDirectivesByAlt:r}){let i=e.body.filter(e=>e.kind===`flags`);for(let e=n+1;e<t.body.length;e++){let n=t.body[e];fW(r,n,[]).push(...i)}},exit({node:e},{flagDirectivesByAlt:t}){if(t.get(e)?.length){let n=HW(t.get(e));if(n){let t=mU({flags:n});t.body[0].body=e.body,e.body=[eG(t,e)]}}}},Assertion({node:e,parent:t,key:n,container:r,root:i,remove:a,replaceWith:o},s){let{kind:c,negate:l}=e,{asciiWordBoundaries:u,avoidSubclass:d,supportedGNodes:f,wordIsAscii:p}=s;if(c===`text_segment_boundary`)throw Error(`Unsupported text segment boundary "\\${l?`Y`:`y`}"`);if(c===`line_end`)o(eG(hU({body:[iU({body:[aU(`string_end`)]}),iU({body:[cU(10)]})]}),t));else if(c===`line_start`)o(eG(ZW(cW`(?<=\A|\n(?!\z))`,{skipLookbehindValidation:!0}),t));else if(c===`search_start`)if(f.has(e))i.flags.sticky=!0,a();else{let e=r[n-1];if(e&&JW(e))o(eG(hU({negate:!0}),t));else if(d)throw Error(cW`Uses "\G" in a way that requires a subclass`);else o($W(aU(`string_start`),t)),s.strategy=`clip_search`}else if(!(c===`string_end`||c===`string_start`))if(c===`string_end_newline`)o(eG(ZW(cW`(?=\n?\z)`),t));else if(c===`word_boundary`){if(!p&&!u){let e=`(?:(?<=${bW})(?!${bW})|(?<!${bW})(?=${bW}))`,n=`(?:(?<=${bW})(?=${bW})|(?<!${bW})(?!${bW}))`;o(eG(ZW(l?n:e),t))}}else throw Error(`Unexpected assertion kind "${c}"`)},Backreference({node:e},{jsGroupNameMap:t}){let{ref:n}=e;typeof n==`string`&&!XW(n)&&(n=VW(n,t),e.ref=n)},CapturingGroup({node:e},{jsGroupNameMap:t,subroutineRefMap:n}){let{name:r}=e;r&&!XW(r)&&(r=VW(r,t),e.name=r),n.set(e.number,e),r&&n.set(r,e)},CharacterClassRange({node:e,parent:t,replaceWith:n}){t.kind===`intersection`&&n(eG(lU({body:[e]}),t),{traverse:!0})},CharacterSet({node:e,parent:t,replaceWith:n},{accuracy:r,minTargetEs2024:i,digitIsAscii:a,spaceIsAscii:o,wordIsAscii:s}){let{kind:c,negate:l,value:u}=e;if(a&&(c===`digit`||u===`digit`)){n($W(dU(`digit`,{negate:l}),t));return}if(o&&(c===`space`||u===`space`)){n(eG(QW(ZW(vW),l),t));return}if(s&&(c===`word`||u===`word`)){n($W(dU(`word`,{negate:l}),t));return}if(c===`any`)n($W(xU(`Any`),t));else if(c===`digit`)n($W(xU(`Nd`,{negate:l}),t));else if(c!==`dot`)if(c===`text_segment`){if(r===`strict`)throw Error(cW`Use of "\X" requires non-strict accuracy`);let e=`\\p{Emoji}(?:\\p{EMod}|\\uFE0F\\u20E3?|[\\x{E0020}-\\x{E007E}]+\\x{E007F})?`,a=cW`\p{RI}{2}|${e}(?:\u200D${e})*`;n(eG(ZW(cW`(?>\r\n|${i?cW`\p{RGI_Emoji}`:a}|\P{M}\p{M}*)`,{skipPropertyNameValidation:!0}),t))}else if(c===`hex`)n($W(xU(`AHex`,{negate:l}),t));else if(c===`newline`)n(eG(ZW(l?`[^
346
- ]`:`(?>\r
347
- ?|[
348
- \v\f…\u2028\u2029])`),t));else if(c===`posix`)if(!i&&(u===`graph`||u===`print`)){if(r===`strict`)throw Error(`POSIX class "${u}" requires min target ES2024 or non-strict accuracy`);let e={graph:`!-~`,print:` -~`}[u];l&&(e=`\0-${sW(e.codePointAt(0)-1)}${sW(e.codePointAt(2)+1)}-\u{10FFFF}`),n(eG(ZW(`[${e}]`),t))}else n(eG(QW(ZW(EW.get(u)),l),t));else if(c===`property`)SW.has(kU(u))||(e.key=`sc`);else if(c===`space`)n($W(xU(`space`,{negate:l}),t));else if(c===`word`)n(eG(QW(ZW(bW),l),t));else throw Error(`Unexpected character set kind "${c}"`)},Directive({node:e,parent:t,root:n,remove:r,replaceWith:i,removeAllPrevSiblings:a,removeAllNextSiblings:o}){let{kind:s,flags:c}=e;if(s===`flags`)if(!c.enable&&!c.disable)r();else{let e=mU({flags:c});e.body[0].body=o(),i(eG(e,t),{traverse:!0})}else if(s===`keep`){let e=n.body[0],r=n.body.length===1&&GH(e,{type:`Group`})&&e.body[0].body.length===1?e.body[0]:n;if(t.parent!==r||r.body.length>1)throw Error(cW`Uses "\K" in a way that's unsupported`);let o=hU({behind:!0});o.body[0].body=a(),i(eG(o,t))}else throw Error(`Unexpected directive kind "${s}"`)},Flags({node:e,parent:t}){if(e.posixIsAscii)throw Error(`Unsupported flag "P"`);if(e.textSegmentMode===`word`)throw Error(`Unsupported flag "y{w}"`);[`digitIsAscii`,`extended`,`posixIsAscii`,`spaceIsAscii`,`wordIsAscii`,`textSegmentMode`].forEach(t=>delete e[t]),Object.assign(e,{global:!1,hasIndices:!1,multiline:!1,sticky:e.sticky??!1}),t.options={disable:{x:!0,n:!0},force:{v:!0}}},Group({node:e}){if(!e.flags)return;let{enable:t,disable:n}=e.flags;t?.extended&&delete t.extended,n?.extended&&delete n.extended,t?.dotAll&&n?.dotAll&&delete t.dotAll,t?.ignoreCase&&n?.ignoreCase&&delete t.ignoreCase,t&&!Object.keys(t).length&&delete e.flags.enable,n&&!Object.keys(n).length&&delete e.flags.disable,!e.flags.enable&&!e.flags.disable&&delete e.flags},LookaroundAssertion({node:e},t){let{kind:n}=e;n===`lookbehind`&&(t.passedLookbehind=!0)},NamedCallout({node:e,parent:t,replaceWith:n}){let{kind:r}=e;if(r===`fail`)n(eG(hU({negate:!0}),t));else throw Error(`Unsupported named callout "(*${r.toUpperCase()}"`)},Quantifier({node:e}){if(e.body.type===`Quantifier`){let t=mU();t.body[0].body.push(e.body),e.body=eG(t,e)}},Regex:{enter({node:e},{supportedGNodes:t}){let n=[],r=!1,i=!1;for(let t of e.body)if(t.body.length===1&&t.body[0].kind===`search_start`)t.body.pop();else{let e=GW(t.body);e?(r=!0,Array.isArray(e)?n.push(...e):n.push(e)):i=!0}r&&!i&&n.forEach(e=>t.add(e))},exit(e,{accuracy:t,passedLookbehind:n,strategy:r}){if(t===`strict`&&n&&r)throw Error(cW`Uses "\G" in a way that requires non-strict accuracy`)}},Subroutine({node:e},{jsGroupNameMap:t}){let{ref:n}=e;typeof n==`string`&&!XW(n)&&(n=VW(n,t),e.ref=n)}},NW={Backreference({node:e},{multiplexCapturesToLeftByRef:t,reffedNodesByReferencer:n}){let{orphan:r,ref:i}=e;r||n.set(e,[...t.get(i).map(({node:e})=>e)])},CapturingGroup:{enter({node:e,parent:t,replaceWith:n,skip:r},{groupOriginByCopy:i,groupsByName:a,multiplexCapturesToLeftByRef:o,openRefs:s,reffedNodesByReferencer:c}){let l=i.get(e);if(l&&s.has(e.number)){let r=$W(zW(e.number),t);c.set(r,s.get(e.number)),n(r);return}s.set(e.number,e),o.set(e.number,[]),e.name&&fW(o,e.name,[]);let u=o.get(e.name??e.number);for(let t=0;t<u.length;t++){let n=u[t];if(l===n.node||l&&l===n.origin||e===n.origin){u.splice(t,1);break}}if(o.get(e.number).push({node:e,origin:l}),e.name&&o.get(e.name).push({node:e,origin:l}),e.name){let t=fW(a,e.name,new Map),n=!1;if(l)n=!0;else for(let e of t.values())if(!e.hasDuplicateNameToRemove){n=!0;break}a.get(e.name).set(e,{node:e,hasDuplicateNameToRemove:n})}},exit({node:e},{openRefs:t}){t.get(e.number)===e&&t.delete(e.number)}},Group:{enter({node:e},t){t.prevFlags=t.currentFlags,e.flags&&(t.currentFlags=dW(t.currentFlags,e.flags))},exit(e,t){t.currentFlags=t.prevFlags}},Subroutine({node:e,parent:t,replaceWith:n},r){let{isRecursive:i,ref:a}=e;if(i){let n=t;for(;(n=n.parent)&&!(n.type===`CapturingGroup`&&(n.name===a||n.number===a)););r.reffedNodesByReferencer.set(e,n);return}let o=r.subroutineRefMap.get(a),s=a===0,c=s?zW(0):RW(o,r.groupOriginByCopy,null),l=c;if(!s){let e=HW(BW(o,e=>e.type===`Group`&&!!e.flags)),t=e?dW(r.globalFlags,e):r.globalFlags;IW(t,r.currentFlags)||(l=mU({flags:UW(t)}),l.body[0].body.push(c))}n(eG(l,t),{traverse:!s})}},PW={Backreference({node:e,parent:t,replaceWith:n},r){if(e.orphan){r.highestOrphanBackref=Math.max(r.highestOrphanBackref,e.ref);return}let i=r.reffedNodesByReferencer.get(e).filter(t=>LW(t,e));i.length?i.length>1?n(eG(mU({atomic:!0,body:i.reverse().map(e=>iU({body:[oU(e.number)]}))}),t)):e.ref=i[0].number:n(eG(hU({negate:!0}),t))},CapturingGroup({node:e},t){e.number=++t.numCapturesToLeft,e.name&&t.groupsByName.get(e.name).get(e).hasDuplicateNameToRemove&&delete e.name},Regex:{exit({node:e},t){let n=Math.max(t.highestOrphanBackref-t.numCapturesToLeft,0);for(let t=0;t<n;t++){let t=sU();e.body.at(-1).body.push(t)}}},Subroutine({node:e},t){!e.isRecursive||e.ref===0||(e.ref=t.reffedNodesByReferencer.get(e).number)}};function FW(e){MU(e,{"*"({node:e,parent:t}){e.parent=t}})}function IW(e,t){return e.dotAll===t.dotAll&&e.ignoreCase===t.ignoreCase}function LW(e,t){let n=t;do{if(n.type===`Regex`)return!1;if(n.type===`Alternative`)continue;if(n===e)return!1;let t=WW(n.parent);for(let r of t){if(r===n)break;if(r===e||KW(r,e))return!0}}while(n=n.parent);throw Error(`Unexpected path`)}function RW(e,t,n,r){let i=Array.isArray(e)?[]:{};for(let[a,o]of Object.entries(e))a===`parent`?i.parent=Array.isArray(n)?r:n:o&&typeof o==`object`?i[a]=RW(o,t,i,n):(a===`type`&&o===`CapturingGroup`&&t.set(i,t.get(e)??e),i[a]=o);return i}function zW(e){let t=bU(e);return t.isRecursive=!0,t}function BW(e,t){let n=[];for(;e=e.parent;)(!t||t(e))&&n.push(e);return n}function VW(e,t){if(t.has(e))return t.get(e);let n=`$${t.size}_${e.replace(/^[^$_\p{IDS}]|[^$\u200C\u200D\p{IDC}]/gu,`_`)}`;return t.set(e,n),n}function HW(e){let t=[`dotAll`,`ignoreCase`],n={enable:{},disable:{}};return e.forEach(({flags:e})=>{t.forEach(t=>{e.enable?.[t]&&(delete n.disable[t],n.enable[t]=!0),e.disable?.[t]&&(n.disable[t]=!0)})}),Object.keys(n.enable).length||delete n.enable,Object.keys(n.disable).length||delete n.disable,n.enable||n.disable?n:null}function UW({dotAll:e,ignoreCase:t}){let n={};return(e||t)&&(n.enable={},e&&(n.enable.dotAll=!0),t&&(n.enable.ignoreCase=!0)),(!e||!t)&&(n.disable={},!e&&(n.disable.dotAll=!0),!t&&(n.disable.ignoreCase=!0)),n}function WW(e){if(!e)throw Error(`Node expected`);let{body:t}=e;return Array.isArray(t)?t:t?[t]:null}function GW(e){let t=e.find(e=>e.kind===`search_start`||YW(e,{negate:!1})||!qW(e));if(!t)return null;if(t.kind===`search_start`)return t;if(t.type===`LookaroundAssertion`)return t.body[0].body[0];if(t.type===`CapturingGroup`||t.type===`Group`){let e=[];for(let n of t.body){let t=GW(n.body);if(!t)return null;Array.isArray(t)?e.push(...t):e.push(t)}return e}return null}function KW(e,t){let n=WW(e)??[];for(let e of n)if(e===t||KW(e,t))return!0;return!1}function qW({type:e}){return e===`Assertion`||e===`Directive`||e===`LookaroundAssertion`}function JW(e){let t=[`Character`,`CharacterClass`,`CharacterSet`];return t.includes(e.type)||e.type===`Quantifier`&&e.min&&t.includes(e.body.type)}function YW(e,t){let n={negate:null,...t};return e.type===`LookaroundAssertion`&&(n.negate===null||e.negate===n.negate)&&e.body.length===1&&GH(e.body[0],{type:`Assertion`,kind:`search_start`})}function XW(e){return/^[$_\p{IDS}][$\u200C\u200D\p{IDC}]*$/u.test(e)}function ZW(e,t){let n=JH(e,{...t,unicodePropertyMap:SW}).body;return n.length>1||n[0].body.length>1?mU({body:n}):n[0].body[0]}function QW(e,t){return e.negate=t,e}function $W(e,t){return e.parent=t,e}function eG(e,t){return FW(e),e.parent=t,e}function tG(e,t){let n=_W(t),r=pW(n.target,`ES2024`),i=pW(n.target,`ES2025`),a=n.rules.recursionLimit;if(!Number.isInteger(a)||a<2||a>20)throw Error(`Invalid recursionLimit; use 2-20`);let o=null,s=null;if(!i){let t=[e.flags.ignoreCase];MU(e,nG,{getCurrentModI:()=>t.at(-1),popModI(){t.pop()},pushModI(e){t.push(e)},setHasCasedChar(){t.at(-1)?o=!0:s=!0}})}let c={dotAll:e.flags.dotAll,ignoreCase:!!((e.flags.ignoreCase||o)&&!s)},l=e,u={accuracy:n.accuracy,appliedGlobalFlags:c,captureMap:new Map,currentFlags:{dotAll:e.flags.dotAll,ignoreCase:e.flags.ignoreCase},inCharClass:!1,lastNode:l,originMap:e._originMap,recursionLimit:a,useAppliedIgnoreCase:!!(!i&&o&&s),useFlagMods:i,useFlagV:r,verbose:n.verbose};function d(e){return u.lastNode=l,l=e,mW(rG[e.type],`Unexpected node type "${e.type}"`)(e,u,d)}let f={pattern:e.body.map(d).join(`|`),flags:d(e.flags),options:{...e.options}};return r||(delete f.options.force.v,f.options.disable.v=!0,f.options.unicodeSetsPlugin=null),f._captureTransfers=new Map,f._hiddenCaptures=[],u.captureMap.forEach((e,t)=>{e.hidden&&f._hiddenCaptures.push(t),e.transferTo&&fW(f._captureTransfers,e.transferTo,[]).push(t)}),f}var nG={"*":{enter({node:e},t){if(hG(e)){let n=t.getCurrentModI();t.pushModI(e.flags?dW({ignoreCase:n},e.flags).ignoreCase:n)}},exit({node:e},t){hG(e)&&t.popModI()}},Backreference(e,t){t.setHasCasedChar()},Character({node:e},t){lG(sW(e.value))&&t.setHasCasedChar()},CharacterClassRange({node:e,skip:t},n){t(),uG(e,{firstOnly:!0}).length&&n.setHasCasedChar()},CharacterSet({node:e},t){e.kind===`property`&&AW.has(e.value)&&t.setHasCasedChar()}},rG={Alternative({body:e},t,n){return e.map(n).join(``)},Assertion({kind:e,negate:t}){if(e===`string_end`)return`$`;if(e===`string_start`)return`^`;if(e===`word_boundary`)return t?cW`\B`:cW`\b`;throw Error(`Unexpected assertion kind "${e}"`)},Backreference({ref:e},t){if(typeof e!=`number`)throw Error(`Unexpected named backref in transformed AST`);if(!t.useFlagMods&&t.accuracy===`strict`&&t.currentFlags.ignoreCase&&!t.captureMap.get(e).ignoreCase)throw Error(`Use of case-insensitive backref to case-sensitive group requires target ES2025 or non-strict accuracy`);return`\\`+e},CapturingGroup(e,t,n){let{body:r,name:i,number:a}=e,o={ignoreCase:t.currentFlags.ignoreCase},s=t.originMap.get(e);return s&&(o.hidden=!0,a>s.number&&(o.transferTo=s.number)),t.captureMap.set(a,o),`(${i?`?<${i}>`:``}${r.map(n).join(`|`)})`},Character({value:e},t){let n=sW(e),r=dG(e,{escDigit:t.lastNode.type===`Backreference`,inCharClass:t.inCharClass,useFlagV:t.useFlagV});if(r!==n)return r;if(t.useAppliedIgnoreCase&&t.currentFlags.ignoreCase&&lG(n)){let e=xW(n);return t.inCharClass?e.join(``):e.length>1?`[${e.join(``)}]`:e[0]}return n},CharacterClass(e,t,n){let{kind:r,negate:i,parent:a}=e,{body:o}=e;if(r===`intersection`&&!t.useFlagV)throw Error(`Use of character class intersection requires min target ES2024`);lW.bugFlagVLiteralHyphenIsRange&&t.useFlagV&&o.some(_G)&&(o=[cU(45),...o.filter(e=>!_G(e))]);let s=()=>`[${i?`^`:``}${o.map(n).join(r===`intersection`?`&&`:``)}]`;if(!t.inCharClass){if((!t.useFlagV||lW.bugNestedClassIgnoresNegation)&&!i){let t=o.filter(e=>e.type===`CharacterClass`&&e.kind===`union`&&e.negate);if(t.length){let r=mU(),i=r.body[0];return r.parent=a,i.parent=r,o=o.filter(e=>!t.includes(e)),e.body=o,o.length?(e.parent=i,i.body.push(e)):r.body.pop(),t.forEach(e=>{let t=iU({body:[e]});e.parent=t,t.parent=r,r.body.push(t)}),n(r)}}t.inCharClass=!0;let r=s();return t.inCharClass=!1,r}let c=o[0];if(r===`union`&&!i&&c&&((!t.useFlagV||!t.verbose)&&a.kind===`union`&&!(lW.bugFlagVLiteralHyphenIsRange&&t.useFlagV)||!t.verbose&&a.kind===`intersection`&&o.length===1&&c.type!==`CharacterClassRange`))return o.map(n).join(``);if(!t.useFlagV&&a.type===`CharacterClass`)throw Error(`Uses nested character class in a way that requires min target ES2024`);return s()},CharacterClassRange(e,t){let n=e.min.value,r=e.max.value,i={escDigit:!1,inCharClass:!0,useFlagV:t.useFlagV},a=dG(n,i),o=dG(r,i),s=new Set;return t.useAppliedIgnoreCase&&t.currentFlags.ignoreCase&&fG(uG(e)).forEach(e=>{s.add(Array.isArray(e)?`${dG(e[0],i)}-${dG(e[1],i)}`:dG(e,i))}),`${a}-${o}${[...s].join(``)}`},CharacterSet({kind:e,negate:t,value:n,key:r},i){if(e===`dot`)return i.currentFlags.dotAll?i.appliedGlobalFlags.dotAll||i.useFlagMods?`.`:`[^]`:cW`[^\n]`;if(e===`digit`)return t?cW`\D`:cW`\d`;if(e===`property`){if(i.useAppliedIgnoreCase&&i.currentFlags.ignoreCase&&AW.has(n))throw Error(`Unicode property "${n}" can't be case-insensitive when other chars have specific case`);return`${t?cW`\P`:cW`\p`}{${r?`${r}=`:``}${n}}`}if(e===`word`)return t?cW`\W`:cW`\w`;throw Error(`Unexpected character set kind "${e}"`)},Flags(e,t){return(t.appliedGlobalFlags.ignoreCase?`i`:``)+(e.dotAll?`s`:``)+(e.sticky?`y`:``)},Group({atomic:e,body:t,flags:n,parent:r},i,a){let o=i.currentFlags;n&&(i.currentFlags=dW(o,n));let s=t.map(a).join(`|`),c=!i.verbose&&t.length===1&&r.type!==`Quantifier`&&!e&&(!i.useFlagMods||!n)?s:`(?${pG(e,n,i.useFlagMods)}${s})`;return i.currentFlags=o,c},LookaroundAssertion({body:e,kind:t,negate:n},r,i){return`(?${`${t===`lookahead`?``:`<`}${n?`!`:`=`}`}${e.map(i).join(`|`)})`},Quantifier(e,t,n){return n(e.body)+mG(e)},Subroutine({isRecursive:e,ref:t},n){if(!e)throw Error(`Unexpected non-recursive subroutine in transformed AST`);let r=n.recursionLimit;return t===0?`(?R=${r})`:cW`\g<${t}&R=${r}>`}},iG=new Set([`$`,`(`,`)`,`*`,`+`,`.`,`?`,`[`,`\\`,`]`,`^`,`{`,`|`,`}`]),aG=new Set([`-`,`\\`,`]`,`^`,`[`]),oG=new Set("()-/[\\]^{|}!#$%&*+,.:;<=>?@`~".split(``)),sG=new Map([[9,cW`\t`],[10,cW`\n`],[11,cW`\v`],[12,cW`\f`],[13,cW`\r`],[8232,cW`\u2028`],[8233,cW`\u2029`],[65279,cW`\uFEFF`]]),cG=/^\p{Cased}$/u;function lG(e){return cG.test(e)}function uG(e,t){let n=!!t?.firstOnly,r=e.min.value,i=e.max.value,a=[];if(r<65&&(i===65535||i>=131071)||r===65536&&i>=131071)return a;for(let e=r;e<=i;e++){let t=sW(e);if(!lG(t))continue;let o=xW(t).filter(e=>{let t=e.codePointAt(0);return t<r||t>i});if(o.length&&(a.push(...o),n))break}return a}function dG(e,{escDigit:t,inCharClass:n,useFlagV:r}){if(sG.has(e))return sG.get(e);if(e<32||e>126&&e<160||e>262143||t&&gG(e))return e>255?`\\u{${e.toString(16).toUpperCase()}}`:`\\x${e.toString(16).toUpperCase().padStart(2,`0`)}`;let i=n?r?oG:aG:iG,a=sW(e);return(i.has(a)?`\\`:``)+a}function fG(e){let t=e.map(e=>e.codePointAt(0)).sort((e,t)=>e-t),n=[],r=null;for(let e=0;e<t.length;e++)t[e+1]===t[e]+1?r??=t[e]:r===null?n.push(t[e]):(n.push([r,t[e]]),r=null);return n}function pG(e,t,n){if(e)return`>`;let r=``;if(t&&n){let{enable:e,disable:n}=t;r=(e?.ignoreCase?`i`:``)+(e?.dotAll?`s`:``)+(n?`-`:``)+(n?.ignoreCase?`i`:``)+(n?.dotAll?`s`:``)}return`${r}:`}function mG({kind:e,max:t,min:n}){let r;return r=!n&&t===1?`?`:!n&&t===1/0?`*`:n===1&&t===1/0?`+`:n===t?`{${n}}`:`{${n},${t===1/0?``:t}}`,r+{greedy:``,lazy:`?`,possessive:`+`}[e]}function hG({type:e}){return e===`CapturingGroup`||e===`Group`||e===`LookaroundAssertion`}function gG(e){return e>47&&e<58}function _G({type:e,value:t}){return e===`Character`&&t===45}var vG=class e extends RegExp{#e=new Map;#t=null;#n;#r=null;#i=null;rawOptions={};get source(){return this.#n||`(?:)`}constructor(t,n,r){let i=!!r?.lazyCompile;if(t instanceof RegExp){if(r)throw Error(`Cannot provide options when copying a regexp`);let i=t;super(i,n),this.#n=i.source,i instanceof e&&(this.#e=i.#e,this.#r=i.#r,this.#i=i.#i,this.rawOptions=i.rawOptions)}else{let e={hiddenCaptures:[],strategy:null,transfers:[],...r};super(i?``:t,n),this.#n=t,this.#e=bG(e.hiddenCaptures,e.transfers),this.#i=e.strategy,this.rawOptions=r??{}}i||(this.#t=this)}exec(t){if(!this.#t){let{lazyCompile:t,...n}=this.rawOptions;this.#t=new e(this.#n,this.flags,n)}let n=this.global||this.sticky,r=this.lastIndex;if(this.#i===`clip_search`&&n&&r){this.lastIndex=0;let e=this.#a(t.slice(r));return e&&(yG(e,r,t,this.hasIndices),this.lastIndex+=r),e}return this.#a(t)}#a(e){this.#t.lastIndex=this.lastIndex;let t=super.exec.call(this.#t,e);if(this.lastIndex=this.#t.lastIndex,!t||!this.#e.size)return t;let n=[...t];t.length=1;let r;this.hasIndices&&(r=[...t.indices],t.indices.length=1);let i=[0];for(let e=1;e<n.length;e++){let{hidden:a,transferTo:o}=this.#e.get(e)??{};if(a?i.push(null):(i.push(t.length),t.push(n[e]),this.hasIndices&&t.indices.push(r[e])),o&&n[e]!==void 0){let a=i[o];if(!a)throw Error(`Invalid capture transfer to "${a}"`);if(t[a]=n[e],this.hasIndices&&(t.indices[a]=r[e]),t.groups){this.#r||=xG(this.source);let i=this.#r.get(o);i&&(t.groups[i]=n[e],this.hasIndices&&(t.indices.groups[i]=r[e]))}}}return t}};function yG(e,t,n,r){if(e.index+=t,e.input=n,r){let n=e.indices;for(let e=0;e<n.length;e++){let r=n[e];r&&(n[e]=[r[0]+t,r[1]+t])}let r=n.groups;r&&Object.keys(r).forEach(e=>{let n=r[e];n&&(r[e]=[n[0]+t,n[1]+t])})}}function bG(e,t){let n=new Map;for(let t of e)n.set(t,{hidden:!0});for(let[e,r]of t)for(let t of r)fW(n,t,{}).transferTo=e;return n}function xG(e){let t=/(?<capture>\((?:\?<(?![=!])(?<name>[^>]+)>|(?!\?)))|\\?./gsu,n=new Map,r=0,i=0,a;for(;a=t.exec(e);){let{0:e,groups:{capture:t,name:o}}=a;e===`[`?r++:r?e===`]`&&r--:t&&(i++,o&&n.set(i,o))}return n}function SG(e,t){let n=CG(e,t);return n.options?new vG(n.pattern,n.flags,n.options):new RegExp(n.pattern,n.flags)}function CG(e,t){let n=_W(t),r=jW(JH(e,{flags:n.flags,normalizeUnknownPropertyNames:!0,rules:{captureGroup:n.rules.captureGroup,singleline:n.rules.singleline},skipBackrefValidation:n.rules.allowOrphanBackrefs,unicodePropertyMap:SW}),{accuracy:n.accuracy,asciiWordBoundaries:n.rules.asciiWordBoundaries,avoidSubclass:n.avoidSubclass,bestEffortTarget:n.target}),i=tG(r,n),a=tW(i.pattern,{captureTransfers:i._captureTransfers,hiddenCaptures:i._hiddenCaptures,mode:`external`}),o=GU(JU(a.pattern).pattern,{captureTransfers:a.captureTransfers,hiddenCaptures:a.hiddenCaptures}),s={pattern:o.pattern,flags:`${n.hasIndices?`d`:``}${n.global?`g`:``}${i.flags}${i.options.disable.v?`u`:`v`}`};if(n.avoidSubclass){if(n.lazyCompileLength!==1/0)throw Error(`Lazy compilation requires subclass`)}else{let e=o.hiddenCaptures.sort((e,t)=>e-t),t=Array.from(o.captureTransfers),i=r._strategy,a=s.pattern.length>=n.lazyCompileLength;(e.length||t.length||i||a)&&(s.options={...e.length&&{hiddenCaptures:e},...t.length&&{transfers:t},...i&&{strategy:i},...a&&{lazyCompile:a}})}return s}var wG=[`github-light`,`github-dark`,`catppuccin-latte`,`catppuccin-mocha`,`tokyo-night`,`one-light`,`one-dark-pro`,`github-light-default`,`github-dark-default`,`light-plus`,`dark-plus`],TG=null,EG=null;function DG(){return EG?Promise.resolve(EG):(TG||=qV({themes:wG,langs:[]}).then(e=>(EG=e,e)),TG)}var OG=new Set;typeof window<`u`&&window.addEventListener(`codemini-theme-palette-change`,()=>{TG=null,EG=null,OG.clear()});async function kG(e){if(!e||OG.has(e))return;let t=await DG();try{t.getLoadedLanguages().includes(e)||await t.loadLanguage(e),OG.add(e)}catch{OG.add(e)}}function AG(){return DG().catch(()=>{}),{name:`shiki`,type:`code-highlighter`,getThemes:()=>wG,getSupportedLanguages:()=>EG?EG.getLoadedLanguages():[],supportsLanguage:e=>EG?EG.getLoadedLanguages().includes(e):!1,highlight:(e,t)=>{let{code:n,language:r}=e;return MG(n,r)||(kG(r).then(()=>{t&&t(MG(n,r)||jG(n))}),jG(n))}}}function jG(e){return{fg:void 0,bg:void 0,rootStyle:void 0,tokens:String(e??``).split(/\r?\n/).map(e=>[{content:e}])}}function MG(e,t){if(!EG)return null;try{if(!EG.getLoadedLanguages().includes(t))return null;let n=EG.codeToTokens(e,{lang:t,themes:NG(),defaultColor:!1});return{fg:n.fg,bg:n.bg,rootStyle:n.rootStyle,tokens:n.tokens}}catch{return null}}function NG(){if(typeof document>`u`)return{light:`github-light`,dark:`github-dark`};let e=document.documentElement.dataset.palette||`default`;return e===`catppuccin`?{light:`catppuccin-latte`,dark:`catppuccin-mocha`}:e===`tokyonight`?{light:`github-light`,dark:`tokyo-night`}:e===`one`?{light:`one-light`,dark:`one-dark-pro`}:e===`github`?{light:`github-light-default`,dark:`github-dark-default`}:e===`vscode`?{light:`light-plus`,dark:`dark-plus`}:{light:`github-light`,dark:`github-dark`}}var PG=AG(),FG=class extends d.Component{state={hasError:!1,retryCount:0};retryTimer=null;static getDerivedStateFromError(){return{hasError:!0}}componentDidCatch(e){console.warn(`Streamdown render failed; retrying with markdown renderer.`,e),!(this.state.retryCount>=2)&&(clearTimeout(this.retryTimer),this.retryTimer=window.setTimeout(()=>{this.setState(e=>({hasError:!1,retryCount:e.retryCount+1}))},80))}componentDidUpdate(e){(e.fallbackText!==this.props.fallbackText||e.resetKey!==this.props.resetKey)&&(this.state.hasError||this.state.retryCount)&&(clearTimeout(this.retryTimer),this.setState({hasError:!1,retryCount:0}))}componentWillUnmount(){clearTimeout(this.retryTimer)}render(){return this.state.hasError?(0,_.jsx)(`div`,{className:`msg-body whitespace-pre-wrap text-(--text-primary)`,children:this.props.fallbackText}):this.props.children}};function IG({text:e,streaming:t,className:n}){let r=typeof e==`string`?e:String(e||``);if(!r)return null;let i=t?`streaming`:`static`;return(0,_.jsx)(FG,{fallbackText:r,resetKey:i,children:(0,_.jsx)(`div`,{className:z(`msg-body`,t&&`streaming-cursor`,n),children:(0,_.jsx)(kI,{mode:i,isAnimating:t,parseIncompleteMarkdown:!0,showLineNumbers:!1,plugins:{code:PG},controls:{tables:!0,codeBlocks:!0,mermaid:{display:!0,wrap:!0}},children:r})})})}function LG({todos:e}){return e?.length?(0,_.jsx)(`div`,{className:`space-y-1 mt-2`,children:e.map((e,t)=>{let n=e.status===`completed`?`✓`:e.status===`in_progress`?`●`:``;return(0,_.jsxs)(`div`,{className:z(`flex items-center gap-2 text-[13px] py-0.5`,e.status===`completed`&&`text-(--accent-green)`,e.status===`in_progress`&&`text-(--accent-blue)`,e.status===`pending`&&`text-(--muted-foreground)`),children:[(0,_.jsx)(`span`,{className:`w-4 text-center shrink-0`,children:n}),(0,_.jsx)(`span`,{children:e.content||e.activeForm})]},t)})}):null}var RG={you:{badge:`bg-(--accent-blue-bg) text-(--accent-blue)`,label:`You`},general:{badge:`bg-(--accent-green-bg) text-(--accent-green)`,label:`General`},coder:{badge:`bg-(--accent-green-bg) text-(--accent-green)`,label:`Coder`},advisor:{badge:`bg-(--accent-blue-bg) text-(--accent-blue)`,label:`Advisor`},planner:{badge:`bg-(--accent-purple-bg) text-(--accent-purple)`,label:`Planner`},reviewer:{badge:`bg-(--accent-orange-bg) text-(--accent-orange)`,label:`Reviewer`},tester:{badge:`bg-(--accent-blue-bg) text-(--accent-blue)`,label:`Tester`},summarizer:{badge:`bg-(--accent-cyan-bg) text-(--accent-cyan)`,label:`Summarizer`},system:{badge:`bg-(--muted) text-(--muted-foreground)`,label:`System`},error:{badge:`bg-(--accent-red-bg) text-(--accent-red)`,label:`Error`},pending:{badge:`bg-(--accent-cyan-bg) text-(--accent-cyan)`,label:`Pending`}},zG={running:`bg-(--accent-blue-bg) text-(--accent-blue)`,done:`bg-(--accent-green-bg) text-(--accent-green)`,error:`bg-(--accent-red-bg) text-(--accent-red)`,auto:`bg-(--accent-purple-bg) text-(--accent-purple)`},BG=1,VG=`flex w-full cursor-pointer items-center gap-2 rounded-md border-0 bg-transparent px-3 py-2 text-left text-[12px] text-(--text-secondary) hover:bg-(--bg-hover)`,HG=`size-[14px] shrink-0 text-(--text-muted)`,UG=`flex size-[18px] shrink-0 items-center justify-center`;function WG(e){if(!Number.isFinite(Number(e)))return``;let t=Math.max(0,Math.round(Number(e)/1e3));if(t<60)return`${t}s`;let n=Math.floor(t/60),r=t%60;return r?`${n}m ${r}s`:`${n}m`}function GG(e){let t=Number(e);return!Number.isFinite(t)||t<=0?``:t<1e3?`${Math.max(1,Math.round(t))}ms`:WG(t)}function KG(e,t){if(!e.isStreaming&&Number.isFinite(Number(e.durationMs)))return Math.max(0,Number(e.durationMs));let n=Date.parse(e.startedAt||``);if(!Number.isFinite(n))return null;let r=e.isStreaming?t:Date.parse(e.endedAt||``);return Number.isFinite(r)?Math.max(0,r-n):null}function qG({segment:e}){let[t,n]=(0,d.useState)(!1),[r,i]=(0,d.useState)(Date.now());(0,d.useEffect)(()=>{if(!e.isStreaming)return;let t=window.setInterval(()=>i(Date.now()),1e3);return()=>window.clearInterval(t)},[e.isStreaming]);let a=WG(KG(e,r)),o=e.isStreaming?B(`thinkingNow`):a?B(`thoughtFor`).replace(`{{duration}}`,a):B(`thought`);return(0,_.jsxs)(`div`,{className:`my-3 text-(--text-primary)`,children:[(0,_.jsxs)(`button`,{type:`button`,onClick:()=>n(e=>!e),className:z(VG,`font-medium`),"aria-expanded":t,children:[(0,_.jsx)(hp,{size:14,className:z(HG,`transition-transform`,t&&`rotate-90`)}),(0,_.jsx)(`span`,{className:UG,children:e.isStreaming?(0,_.jsx)(Rp,{size:14,className:`animate-spin text-(--accent-cyan)`}):(0,_.jsx)(up,{size:15})}),(0,_.jsx)(`span`,{children:o}),e.isStreaming&&a&&(0,_.jsx)(`span`,{children:a})]}),t&&(0,_.jsx)(`div`,{className:`relative ml-4.5 mt-1.5 pl-8 before:absolute before:left-0 before:top-0 before:bottom-1 before:w-px before:bg-(--border-default)`,children:(0,_.jsx)(IG,{text:e.text,streaming:e.isStreaming,className:`pl-5 text-[13px] italic leading-5 text-(--text-secondary)`})})]})}function JG(e=[]){return e.reduce((e,t)=>{let n=Number(t?.durationMs);return Number.isFinite(n)?e+Math.max(0,n):e},0)}function YG(e){let t=Number(e?.durationMs);return Number.isFinite(t)?Math.max(0,t):KG(e,Date.now())||0}function XG(e){return e?.type===`thinking`||e?.type===`tools`}function ZG(e){return e?.type===`thinking`?e.isStreaming:e?.type===`tools`?(e.cards||[]).some(e=>e.status===`running`):!1}function QG(e){return e?.type===`thinking`?1:e?.type===`tools`?Math.max(1,e.cards?.length||0):0}function $G(e){return e?.type===`thinking`?YG(e):e?.type===`tools`?JG(e.cards||[]):0}function eK(e){if(!e.length||e.some(ZG))return!1;let t=e.reduce((e,t)=>e+QG(t),0),n=e.reduce((e,t)=>t.type===`tools`?e+Math.max(1,t.cards?.length||0):e,0);return t>=4||n>=2&&e.length>=3}function tK(e,{disabled:t=!1}={}){if(t)return e;let n=[],r=[],i=()=>{r.length&&(eK(r)?n.push({type:`process`,groups:r,durationMs:r.reduce((e,t)=>e+$G(t),0)}):n.push(...r),r=[])};for(let t of e){if(XG(t)){r.push(t);continue}i(),n.push(t)}return i(),n}function nK(e){let t=String(e||``);return t===`Dream triggered...`?{status:`running`,title:`Dream started`,description:`Auto memory consolidation is running in the background.`}:t===`Dream complete`?{status:`done`,title:`Dream complete`,description:`Memory consolidation finished.`}:t.startsWith(`Dream done`)?{status:`done`,title:t,description:`Memory inbox and stale buckets were consolidated.`}:t.startsWith(`Dream failed:`)?{status:`error`,title:`Dream failed`,description:t.slice(13).trim()||`Unknown error.`}:null}function rK({notice:e}){let t=e.status===`running`?Rp:e.status===`error`?yp:_p;return(0,_.jsx)(`div`,{className:`py-2 px-6`,children:(0,_.jsx)(`div`,{className:`max-w-[860px] mx-auto flex justify-center`,children:(0,_.jsxs)(`div`,{className:z(`inline-flex max-w-full items-center gap-2 rounded-lg border px-3 py-2 text-left text-xs shadow-sm`,e.status===`error`?`border-(--accent-red)/30 bg-(--accent-red-bg) text-(--accent-red)`:`border-(--border-default) bg-(--bg-secondary) text-(--text-secondary)`),children:[(0,_.jsx)(t,{size:14,className:z(`shrink-0`,e.status===`running`&&`animate-spin text-(--accent-cyan)`,e.status===`done`&&`text-(--accent-green)`)}),(0,_.jsxs)(`div`,{className:`min-w-0`,children:[(0,_.jsx)(`div`,{className:`font-medium text-(--text-primary) truncate`,children:e.title}),e.description&&(0,_.jsx)(`div`,{className:`mt-0.5 text-(--text-muted) truncate`,children:e.description})]})]})})})}function iK({cards:e}){let[t,n]=(0,d.useState)(!1),r=e.length,i=e.some(e=>e.status===`running`),a=r>BG,o=e.filter(e=>{let t=String(e.name||``).toLowerCase();return t===`run`||t.startsWith(`run(`)}).length===r?B(`toolGroupCommands`).replace(`{{count}}`,r):B(`toolGroupTools`).replace(`{{count}}`,r);return(0,_.jsxs)(`div`,{className:`my-2`,children:[a&&(0,_.jsxs)(`button`,{type:`button`,className:VG,onClick:()=>n(e=>!e),"aria-expanded":t,children:[t?(0,_.jsx)(mp,{size:14,className:HG}):(0,_.jsx)(hp,{size:14,className:HG}),(0,_.jsx)(`span`,{className:UG,children:(0,_.jsx)(`span`,{className:z(`inline-block size-1.5 rounded-full`,i?`animate-pulse bg-(--accent-blue)`:`bg-(--accent-green)`)})}),(0,_.jsx)(`span`,{className:`font-medium`,children:o})]}),(!a||t)&&(0,_.jsx)(`div`,{className:z(`space-y-1`,a&&`relative ml-4.5 pl-6 mt-2 before:absolute before:left-0 before:top-0 before:bottom-1 before:w-px before:bg-(--border-default)`),children:e.map(e=>(0,_.jsx)(Qm,{card:e},e.id))}),i&&(0,_.jsxs)(`div`,{className:`flex items-center gap-2 px-3 py-1.5 text-[11px] text-(--text-muted)`,children:[(0,_.jsx)(Dm,{className:`text-(--accent-cyan)`}),(0,_.jsx)(`span`,{children:B(`tooling`)})]})]})}function aK({group:e}){let[t,n]=(0,d.useState)(!1),r=GG(e.durationMs),i=r?B(`processedFor`).replace(`{{duration}}`,r):B(`processed`),a=e.groups.reduce((e,t)=>t.type===`tools`?e+Math.max(1,t.cards?.length||0):e,0),o=e.groups.filter(e=>e.type===`thinking`).length;return(0,_.jsxs)(`div`,{className:`my-3`,children:[(0,_.jsxs)(`button`,{type:`button`,onClick:()=>n(e=>!e),className:VG,"aria-expanded":t,children:[t?(0,_.jsx)(mp,{size:14,className:HG}):(0,_.jsx)(hp,{size:14,className:HG}),(0,_.jsx)(`span`,{className:UG,children:(0,_.jsx)(`span`,{className:`inline-block size-1.5 rounded-full bg-(--accent-green)`})}),(0,_.jsx)(`span`,{className:`font-medium`,children:i}),(0,_.jsx)(`span`,{className:`min-w-0 truncate text-(--text-muted)`,children:B(`processedDetails`).replace(`{{thoughts}}`,o).replace(`{{tools}}`,a)})]}),t&&(0,_.jsx)(`div`,{className:`relative ml-4.5 mt-2 space-y-1 pl-6 before:absolute before:left-0 before:top-0 before:bottom-1 before:w-px before:bg-(--border-default)`,children:e.groups.map((e,t)=>e.type===`thinking`?(0,_.jsx)(qG,{segment:e},`p-th-${t}`):e.type===`tools`?(0,_.jsx)(iK,{cards:e.cards},`p-tg-${t}`):null)})]})}function oK(e=[]){let t=new Map,n=[],r={delete:3,create:2,edit:1};for(let i of e){let e=String(i?.path||``);if(!e)continue;t.has(e)||(t.set(e,{...i,linesAdded:0,linesRemoved:0}),n.push(e));let a=t.get(e);a.linesAdded+=Number(i.linesAdded||0),a.linesRemoved+=Number(i.linesRemoved||0);let o=r[a.action]||0;(r[i.action]||0)>o&&(a.action=i.action),!a.diffPreview&&i.diffPreview&&(a.diffPreview=i.diffPreview,a.changedLine=i.changedLine)}return n.map(e=>t.get(e))}function sK(e){if(!e)return null;if(typeof e==`object`)return e;if(typeof e!=`string`)return null;try{return JSON.parse(e)}catch{return null}}function cK(e){return String(e||``).split(`.`)[0].toLowerCase()}function lK(e){let t=cK(e?.name);if(![`edit`,`write`,`delete`].includes(t))return null;if(e?.fileChange?.path)return e.fileChange;let n=sK(e?.result);if(!n||typeof n!=`object`)return null;if(n.deleted){let e=String(n.path||``);return e?{path:e,action:`delete`,linesAdded:0,linesRemoved:0}:null}if(!(`path`in n)||!(`action`in n))return null;let r=String(n.path||``);return r?{path:r,action:String(n.action||``)===`create`?`create`:`edit`,linesAdded:Number(n.lines_added??n.linesAdded??0),linesRemoved:Number(n.lines_removed??n.linesRemoved??0),changedLine:Number(n.changed_line??n.changedLine??0),diffPreview:String(n.diff_preview??n.diffPreview??``)}:null}function uK(e=[]){let t=[];for(let n of Array.isArray(e)?e:[]){if(n?.type===`tools`)for(let e of Array.isArray(n.cards)?n.cards:[]){let n=lK(e);n?.path&&t.push(n)}if(n?.type===`process`)for(let e of Array.isArray(n.groups)?n.groups:[])t.push(...uK([e]))}return t}function dK(e){return String(e?.diffPreview||``).split(/\r?\n/).filter(Boolean).map(t=>{let n=t.match(/^(\d+)\|\s?(.*)$/);return{number:n?n[1]:``,text:n?n[2]:t,type:e.action===`delete`?`remove`:`add`}})}function fK({change:e}){let t=dK(e);return t.length?(0,_.jsx)(`div`,{className:`overflow-hidden bg-(--bg-primary)`,children:(0,_.jsx)(`div`,{className:`max-h-[420px] overflow-auto font-mono text-xs leading-6`,children:t.map((e,t)=>(0,_.jsxs)(`div`,{className:z(`grid min-w-full grid-cols-[52px_max-content] border-l-3`,e.type===`remove`?`border-(--accent-red) bg-(--accent-red-bg)`:`border-(--accent-green) bg-(--accent-green-bg)`),children:[(0,_.jsx)(`span`,{className:`select-none pr-3 text-right text-(--text-muted)`,children:e.number}),(0,_.jsx)(`span`,{className:`whitespace-pre pr-4 text-(--text-primary)`,children:e.text||` `})]},t))})}):null}function pK({changes:e}){let[t,n]=(0,d.useState)(()=>new Set),r={edit:`bg-(--accent-blue-bg) text-(--accent-blue)`,create:`bg-(--accent-green-bg) text-(--accent-green)`,delete:`bg-(--accent-red-bg) text-(--accent-red)`};return(0,_.jsx)(`div`,{className:`mt-2 overflow-hidden rounded-lg border border-(--border-default) bg-(--bg-secondary)`,children:e.map((e,i)=>{let a=`${e.path}-${i}`,o=t.has(a),s=!!e.diffPreview;return(0,_.jsxs)(`div`,{className:`border-t border-(--border-default) first:border-t-0`,children:[(0,_.jsxs)(`button`,{type:`button`,onClick:()=>{s&&n(e=>{let t=new Set(e);return t.has(a)?t.delete(a):t.add(a),t})},className:z(`flex w-full items-center gap-2 border-0 bg-transparent px-3 py-2.5 text-left font-mono text-xs`,s?`cursor-pointer hover:bg-(--bg-hover)`:`cursor-default`),children:[s?o?(0,_.jsx)(mp,{size:13,className:`shrink-0 text-(--text-muted)`}):(0,_.jsx)(hp,{size:13,className:`shrink-0 text-(--text-muted)`}):(0,_.jsx)(`span`,{className:`w-[13px] shrink-0`}),(0,_.jsx)(`span`,{className:z(`rounded px-[5px] py-px text-[10px] font-semibold`,r[e.action]||`bg-(--muted) text-(--text-muted)`),children:e.action?.toUpperCase()}),(0,_.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-(--text-primary)`,children:e.path}),e.linesAdded!=null&&(0,_.jsxs)(`span`,{className:`text-[11px] text-(--accent-green)`,children:[`+`,e.linesAdded]}),e.linesRemoved!=null&&(0,_.jsxs)(`span`,{className:`text-[11px] text-(--accent-red)`,children:[`-`,e.linesRemoved]})]}),o&&(0,_.jsx)(`div`,{className:`border-t border-(--border-default)`,children:(0,_.jsx)(fK,{change:e})})]},a)})})}function mK(e){let t=[],n=[],r=()=>{n.length>0&&(t.push({type:`tools`,cards:n}),n=[])};for(let i of e)i.type===`tools`?n.push(...i.cards):i.type===`text`?i.text&&(r(),t.push({type:`text`,text:i.text,isStreaming:i.isStreaming})):i.type===`thinking`&&i.text&&(r(),t.push({type:`thinking`,...i}));return r(),t}function hK({text:e,skills:t=[]}){let n=String(e||``).match(/^(\/([A-Za-z0-9_-]+))(\s+[\s\S]*)?$/);if(!n)return(0,_.jsx)(IG,{text:e,streaming:!1});let[,r,i,a=``]=n;if(i===`dream`)return(0,_.jsxs)(`div`,{className:`msg-body whitespace-pre-wrap text-(--text-primary)`,children:[(0,_.jsxs)(hd,{children:[(0,_.jsx)(gd,{asChild:!0,children:(0,_.jsxs)(`span`,{className:`inline-flex items-center gap-1 rounded-md bg-(--accent-cyan-bg) px-1.5 py-0.5 text-(--accent-cyan) font-mono text-[0.92em] cursor-help align-baseline`,children:[(0,_.jsx)(Up,{size:13}),r]})}),(0,_.jsxs)(_d,{side:`top`,sideOffset:8,className:`max-w-75 px-4 py-3 leading-relaxed whitespace-normal`,children:[(0,_.jsx)(`div`,{className:`font-semibold mb-1.5`,children:`Dream`}),(0,_.jsx)(`div`,{className:`text-(--text-secondary)`,children:`Consolidates memory inbox entries and stale memory buckets. It can run manually with /dream or automatically when the inbox threshold is reached.`})]})]}),a]});let o=t.find(e=>e.name===i);return o?(0,_.jsxs)(`div`,{className:`msg-body whitespace-pre-wrap text-(--text-primary)`,children:[(0,_.jsxs)(hd,{children:[(0,_.jsx)(gd,{asChild:!0,children:(0,_.jsx)(`span`,{className:`inline-flex items-center rounded-md bg-(--accent-purple-bg) px-1.5 py-0.5 text-accent-purple font-mono text-[0.92em] cursor-help align-baseline`,children:r})}),(0,_.jsxs)(_d,{side:`top`,sideOffset:8,className:`max-w-75 px-4 py-3 leading-relaxed whitespace-normal`,children:[(0,_.jsx)(`div`,{className:`font-semibold mb-1.5`,children:o.name}),(0,_.jsx)(`div`,{className:`text-(--text-secondary)`,children:o.description||`No description`})]})]}),a]}):(0,_.jsx)(IG,{text:e,streaming:!1})}function gK(e){return String(e?.text||``)||(e?.segments||[]).filter(e=>e.type===`text`).map(e=>String(e.text||``)).join(``)}async function _K(e){let t=String(e||``);if(!t)return!1;if(navigator.clipboard?.writeText)return await navigator.clipboard.writeText(t),!0;let n=document.createElement(`textarea`);n.value=t,n.setAttribute(`readonly`,``),n.style.position=`fixed`,n.style.left=`-9999px`,n.style.top=`0`,document.body.appendChild(n),n.select();let r=document.execCommand(`copy`);return document.body.removeChild(n),r}function vK({label:e,copiedLabel:t,copied:n=!1,disabled:r=!1,onClick:i,children:a}){return(0,_.jsxs)(hd,{children:[(0,_.jsx)(gd,{asChild:!0,children:(0,_.jsx)(`button`,{type:`button`,"aria-label":n&&t||e,disabled:r,onClick:i,className:`inline-flex size-8 items-center justify-center rounded-md border-0 bg-transparent text-(--text-muted) transition-colors hover:bg-(--bg-hover) hover:text-(--text-primary) disabled:cursor-not-allowed disabled:opacity-45`,children:n?(0,_.jsx)(pp,{size:17}):a})}),(0,_.jsx)(_d,{side:`bottom`,sideOffset:6,children:n&&t||e})]})}function yK(e){let t=Number(e);return Number.isFinite(t)?t>=1e6?`${(t/1e6).toFixed(t>=1e7?0:1)}M`:t>=1e3?`${(t/1e3).toFixed(t>=1e4?0:1)}k`:String(Math.round(t)):`0`}function bK(e){if(!e||typeof e!=`object`)return null;let t=Number(e.totalTokens||0),n=Number(e.inputTokens||0),r=Number(e.outputTokens||0),i=Number(e.cachedInputTokens||0),a=Number(e.cacheMissInputTokens||0),o=Number(e.cacheWriteInputTokens||0),s=Number(e.reasoningOutputTokens||0),c=Number(e.requests||0);if(![t,n,r,i,o,s].some(e=>Number.isFinite(e)&&e>0))return null;let l=a>0||o>0?i+a+o:n,u=l>0?i/l*100:0,d=[`${yK(t||n+r)} ${B(`usageTokens`)}`];(i>0||n>0)&&d.push(`${B(`usageCache`)} ${yK(i)} (${u.toFixed(1)}%)`);let f=[`${B(`usageInput`)} ${yK(n)}`,`${B(`usageOutput`)} ${yK(r)}`,`${B(`usageTotal`)} ${yK(t||n+r)}`];return(i>0||n>0)&&f.push(`${B(`usageCacheHit`)} ${yK(i)} (${u.toFixed(1)}%)`),a>0&&f.push(`${B(`usageCacheMiss`)} ${yK(a)}`),o>0&&f.push(`${B(`usageCacheWrite`)} ${yK(o)}`),s>0&&f.push(`${B(`usageReasoning`)} ${yK(s)}`),c>1&&f.push(B(`usageRequests`).replace(`{{count}}`,c)),{label:d.join(` · `),details:f.join(` · `)}}function xK({usage:e}){let t=bK(e);return t?(0,_.jsxs)(hd,{children:[(0,_.jsx)(gd,{asChild:!0,children:(0,_.jsx)(`span`,{className:`inline-flex h-8 max-w-full items-center truncate rounded-md px-1.5 text-[11px] text-(--text-muted)`,children:t.label})}),(0,_.jsx)(_d,{side:`bottom`,sideOffset:6,children:t.details})]}):null}function SK(e,t=[]){if(e?.isComplete===!1||e?.planStep&&![`done`,`failed`].includes(String(e.planStep.status||``)))return!1;let n=Array.isArray(t)?t:[],r=e=>!e||typeof e!=`object`?!1:e.isStreaming?!0:e.type===`tools`?(e.cards||[]).some(e=>e.status===`running`):e.type===`process`?(e.groups||[]).some(r):!1;return!n.some(r)}function CK(e,t){if(!t)return!1;let n=e?.planStep;return n?String(n.role||``).toLowerCase()===`summarizer`&&Number(n.step)===Number(n.total):!0}function wK({text:e,usage:t=null,showUsage:n=!0,align:r=`left`,className:i}){let[a,o]=(0,d.useState)(!1);async function s(){await _K(e)&&(o(!0),window.setTimeout(()=>o(!1),1200))}return(0,_.jsxs)(`div`,{className:z(`flex items-center gap-1`,r===`right`?`justify-end`:`justify-start`,i),children:[(0,_.jsx)(vK,{label:B(`copyMessage`),copiedLabel:B(`copied`),copied:a,disabled:!e,onClick:s,children:(0,_.jsx)(bp,{size:17})}),n&&(0,_.jsx)(xK,{usage:t})]})}function TK({message:e,skills:t=[]}){let{role:n,segments:r,skillBadges:i,fileChanges:a,startupTodos:o,text:s,timestamp:c,planStep:l,usage:u}=e,f=RG[n]||RG.general,p=c?Lm(c):``,m=(0,d.useMemo)(()=>{let t=mK(r||[]),n=t.some(e=>e.type===`text`&&e.isStreaming),i=e?.isComplete===!1||e?.planStep&&![`done`,`failed`].includes(String(e.planStep.status||``));return tK(t,{disabled:n||i})},[e?.isComplete,e?.planStep,r]),h=(0,d.useMemo)(()=>oK([...a||[],...uK(r||[])]),[a,r]);if(n===`divider`)return(0,_.jsx)(`div`,{"data-message-id":e.id,className:`py-3 px-6 text-center`,children:(0,_.jsxs)(`div`,{className:`max-w-[860px] mx-auto relative`,children:[(0,_.jsx)(`div`,{className:`border-t border-border`}),(0,_.jsx)(`span`,{className:`text-xs text-(--text-muted) bg-(--bg-primary) px-2 absolute -top-2.5 left-1/2 -translate-x-1/2 whitespace-nowrap`,children:s||`以上内容已压缩`})]})});if(n===`system`){let t=nK(s);return t?(0,_.jsx)(rK,{notice:t}):s?.includes(`等待计划审阅`)||s?.includes(`Waiting for plan review`)?null:(0,_.jsx)(`div`,{"data-message-id":e.id,className:`py-2 px-6 text-xs text-(--text-muted) text-center`,children:(0,_.jsxs)(`div`,{className:`max-w-[860px] mx-auto px-3 py-1`,children:[s,o&&(0,_.jsx)(LG,{todos:o})]})})}let g=n===`you`&&(s||r?.filter(e=>e.type===`text`).map(e=>e.text).join(``))||``,v=n===`you`?g:gK(e),y=n===`you`||SK(e,m),b=CK(e,y);return(0,_.jsx)(`div`,{"data-message-id":e.id,className:z(`py-2 my-[22px] group/message`,n===`you`&&`flex justify-end`),children:n===`you`?(0,_.jsxs)(`div`,{className:`flex w-fit max-w-full flex-col items-end`,children:[(0,_.jsxs)(`div`,{className:`w-fit max-w-full bg-(--bg-tertiary) rounded-2xl px-4 py-3`,children:[g&&(0,_.jsx)(hK,{text:g,skills:t}),o&&(0,_.jsx)(LG,{todos:o})]}),(0,_.jsx)(wK,{text:v,usage:u,showUsage:y,align:`right`,className:z(`mt-1 min-h-8 opacity-0 pointer-events-none transition-opacity group-hover/message:pointer-events-auto group-hover/message:opacity-100 group-focus-within/message:pointer-events-auto group-focus-within/message:opacity-100`,!b&&`hidden`)})]}):(0,_.jsxs)(`div`,{children:[(0,_.jsxs)(`div`,{className:`flex items-center gap-2 mb-1.5`,children:[(0,_.jsx)(`span`,{className:z(`inline-flex items-center px-2 py-px rounded-full text-[11px] font-semibold uppercase tracking-[0.3px]`,f.badge),children:f.label}),p&&(0,_.jsx)(`span`,{className:`text-[11px] text-(--text-muted)`,children:p})]}),m.map((e,t)=>e.type===`text`?(0,_.jsx)(IG,{text:e.text,streaming:e.isStreaming},`t-${t}-${e.isStreaming?`s`:`d`}`):e.type===`tools`?(0,_.jsx)(iK,{cards:e.cards},`tg-${t}`):e.type===`thinking`?(0,_.jsx)(qG,{segment:e},`th-${t}`):e.type===`process`?(0,_.jsx)(aK,{group:e},`pg-${t}`):null),l&&m.length===0&&l.status!==`done`&&l.status!==`failed`&&(0,_.jsxs)(`div`,{className:`text-[12px] text-(--text-muted) inline-flex items-center gap-1.5`,children:[(0,_.jsx)(`span`,{className:`inline-block size-1 rounded-full bg-(--accent-blue) animate-pulse`}),(0,_.jsx)(`span`,{children:`等待工具调用或模型输出…`})]}),i?.length>0&&(0,_.jsx)(`div`,{className:`flex flex-wrap gap-1 mt-2`,children:i.map((e,t)=>(0,_.jsx)(`span`,{className:z(`inline-flex items-center gap-1 px-2 py-0.5 rounded-full text-[11px] font-medium`,zG[e.status]),children:e.status===`auto`?`${B(`skillAuto`)}: ${e.name}`:`${e.name} - ${B(`skill`+e.status.charAt(0).toUpperCase()+e.status.slice(1))}`},t))}),h.length>0&&(0,_.jsx)(pK,{changes:h}),(0,_.jsx)(wK,{text:v,usage:u,showUsage:b,className:z(`mt-2 min-h-8`,!b&&`hidden`)})]})})}function EK(e,t=36){let n=String(e||``).replace(/\n/g,` `).trim();return n.length>t?n.slice(0,t)+`...`:n}function DK(){return(0,_.jsxs)(`div`,{className:`codemini-press`,"aria-hidden":`true`,children:[(0,_.jsx)(`div`,{className:`sheet`}),(0,_.jsx)(`div`,{className:`roll`}),(0,_.jsx)(`div`,{className:`sheet`}),(0,_.jsx)(`div`,{className:`roll`}),(0,_.jsx)(`div`,{className:`sheet`}),(0,_.jsx)(`div`,{className:`roll`}),(0,_.jsx)(`div`,{className:`sheet`}),(0,_.jsx)(`div`,{className:`sheet`}),(0,_.jsx)(`div`,{className:`sheet`}),(0,_.jsx)(`div`,{className:`sheet`}),(0,_.jsx)(`div`,{className:`sheet`}),(0,_.jsx)(`div`,{className:`roll`})]})}function OK({userMessages:e,activeNavIndex:t,scrollToMessage:n}){let[r,i]=(0,d.useState)(!1),[a,o]=(0,d.useState)(-1),s=(0,d.useRef)(null),c=(0,d.useCallback)(()=>{clearTimeout(s.current),i(!0)},[]),l=(0,d.useCallback)(()=>{s.current=setTimeout(()=>{i(!1),o(-1)},150)},[]);return(0,d.useEffect)(()=>()=>clearTimeout(s.current),[]),e.length<=1?null:(0,_.jsxs)(`div`,{className:`fixed right-5 top-1/2 -translate-y-1/2 pointer-events-auto z-30 flex items-center gap-1`,onMouseEnter:c,onMouseLeave:l,children:[r&&(0,_.jsx)(`div`,{className:`flex flex-col gap-px rounded-lg bg-(--bg-primary) border border-(--border-default) p-1.5 max-w-[180px] max-h-[60vh] overflow-y-auto shadow-lg`,children:e.map((e,r)=>(0,_.jsx)(`button`,{onClick:()=>n(e.id),onMouseEnter:()=>o(r),onMouseLeave:()=>o(-1),className:z(`text-left text-[11px] leading-tight px-2 py-1 rounded-md truncate transition-colors cursor-pointer max-w-full`,r===t?`text-primary`:`text-(--text-muted)`,a===r&&`bg-primary/10 text-primary`),children:e.text||`...`},e.id))}),(0,_.jsx)(`div`,{className:`flex flex-col items-end gap-6 py-1`,children:e.map((e,r)=>(0,_.jsx)(`button`,{onClick:()=>n(e.id),className:z(`h-0.5 rounded-sm transition-all duration-150 cursor-pointer`,r===t?`w-5 bg-primary`:a===r?`w-4 bg-primary/50`:`w-3 bg-(--text-muted)`)},e.id))})]})}function kK({messages:e,projectCwd:t,skills:n=[],gitInfo:r,messagesLoading:i,isGeneral:a=!1}){let o=(0,d.useRef)(null),[s,c]=(0,d.useState)(!0),[l,u]=(0,d.useState)(!1),[f,p]=(0,d.useState)(-1),m=(0,d.useMemo)(()=>e.filter(e=>e.role===`you`).map(e=>({id:e.id,text:EK(e.text||e.segments?.filter(e=>e.type===`text`).map(e=>e.text).join(``)||``)})),[e]),h=(0,d.useCallback)(e=>{let t=o.current?.querySelector(`[data-message-id="${e}"]`);t&&t.scrollIntoView({behavior:`smooth`,block:`center`})},[]);return(0,d.useEffect)(()=>{let e=o.current;if(!e)return;let t=()=>{let t=e.scrollHeight-e.scrollTop-e.clientHeight<80;c(t),u(!t&&e.scrollTop>100);let n=e.querySelectorAll(`[data-message-id][class*="justify-end"]`);if(n.length===0){p(-1);return}let r=e.scrollTop+e.clientHeight*.4,i=-1;n.forEach((e,t)=>{e.offsetTop<=r&&(i=t)}),p(i)};return e.addEventListener(`scroll`,t),()=>e.removeEventListener(`scroll`,t)},[]),(0,d.useEffect)(()=>{s&&o.current&&requestAnimationFrame(()=>{o.current&&(o.current.scrollTop=o.current.scrollHeight)})},[e,s]),(0,_.jsxs)(`div`,{className:`flex-1 relative overflow-hidden`,children:[i&&e.length===0&&(0,_.jsx)(`div`,{className:`absolute inset-0 flex items-center justify-center pointer-events-none`,children:(0,_.jsx)(Dm,{})}),!i&&e.length===0&&(0,_.jsx)(`div`,{className:`absolute left-1/2 top-[38%] -translate-x-1/2 -translate-y-1/2 w-[min(760px,calc(100%-48px))] text-center pointer-events-none`,children:a?(0,_.jsxs)(`div`,{className:`flex flex-col items-center`,children:[(0,_.jsx)(`div`,{className:`mb-7 w-[min(560px,100%)]`,children:(0,_.jsx)(DK,{})}),(0,_.jsx)(`h1`,{className:`text-[clamp(24px,2.4vw,36px)] font-medium leading-tight tracking-normal`,children:B(`askAnythingGeneral`)})]}):(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(`h1`,{className:`text-[clamp(24px,2.4vw,36px)] font-medium leading-tight tracking-normal`,children:B(`buildInProject`).replace(`{{project}}`,t||`qurio-coder`)}),r?.isGit&&(0,_.jsxs)(`div`,{className:`mt-4 flex items-center justify-center gap-3 text-[13px] text-(--text-muted)`,children:[(0,_.jsxs)(`span`,{className:`inline-flex items-center gap-1.5`,children:[(0,_.jsx)(Ap,{size:13}),(0,_.jsx)(`span`,{children:r.branch})]}),r.dirty?(0,_.jsxs)(_.Fragment,{children:[r.staged>0&&(0,_.jsxs)(`span`,{className:`inline-flex items-center gap-1 text-green-600 dark:text-green-400`,children:[(0,_.jsx)(`span`,{className:`w-1.5 h-1.5 rounded-full bg-current`}),B(`gitStaged`),` `,r.staged]}),r.modified>0&&(0,_.jsxs)(`span`,{className:`inline-flex items-center gap-1 text-amber-600 dark:text-amber-400`,children:[(0,_.jsx)(`span`,{className:`w-1.5 h-1.5 rounded-full bg-current`}),B(`gitModified`),` `,r.modified]}),r.untracked>0&&(0,_.jsxs)(`span`,{className:`inline-flex items-center gap-1`,children:[(0,_.jsx)(`span`,{className:`w-1.5 h-1.5 rounded-full bg-current`}),B(`gitUntracked`),` `,r.untracked]})]}):(0,_.jsxs)(`span`,{className:`inline-flex items-center gap-1`,children:[(0,_.jsx)(`span`,{className:`w-1.5 h-1.5 rounded-full bg-emerald-500`}),B(`gitClean`)]})]})]})}),(0,_.jsx)(`div`,{ref:o,className:`h-full overflow-y-auto py-[44px_0_28px] scroll-smooth`,style:{scrollbarWidth:`thin`},children:(0,_.jsx)(`div`,{className:`relative`,children:(0,_.jsx)(`div`,{className:`w-[min(960px,calc(100%-96px))] mx-auto`,children:e.map(e=>(0,_.jsx)(TK,{message:e,skills:n},e.id))})})}),(0,_.jsx)(OK,{userMessages:m,activeNavIndex:f,scrollToMessage:h}),(0,_.jsx)(`div`,{className:`absolute right-7 bottom-0 flex flex-col gap-2 z-20`,children:l&&(0,_.jsx)(`button`,{className:`w-9 h-9 rounded-full bg-(--bg-primary) dark:bg-(--bg-secondary) border border-(--border-default) cursor-pointer flex items-center justify-center text-(--text-secondary) hover:bg-(--bg-hover) hover:text-(--text-primary) animate-in fade-in-0 zoom-in-95`,onClick:()=>{c(!0),o.current?.scrollTo({top:o.current.scrollHeight,behavior:`smooth`})},children:(0,_.jsx)(op,{size:16})})})]})}var AK=new Set([`superpowers-lite`]);function jK(){return[{value:`normal`,label:B(`normalExecutionMode`),desc:B(`normalModeDesc`),icon:zp},{value:`auto`,label:B(`autoMode`),desc:B(`autoModeDesc`),icon:nm},{value:`plan`,label:B(`planMode`),desc:B(`planModeDesc`),icon:Lp}]}var MK=[{name:`dream`,insert:`/dream `,icon:Up,description:`Run memory consolidation now. Auto dream still runs in the background when needed.`},{name:`compact`,insert:`/compact `,icon:ap,description:`Compress the current conversation context while keeping the useful working summary.`},{name:`memory`,insert:`/memory `,icon:xp,description:`Inspect or manage remembered project and user context.`},{name:`capture`,insert:`/capture `,icon:dp,description:`Capture an explicit note into the memory inbox for later consolidation.`},{name:`inbox`,insert:`/inbox `,icon:Fp,description:`Review pending memory inbox entries.`},{name:`reflect`,insert:`/reflect `,icon:nm,description:`Draft or update a reusable skill from the current workflow.`},{name:`retry`,insert:`/retry `,icon:Xp,description:`Retry the last assistant turn.`}],NK=new Set(MK.map(e=>e.name)),PK=`border border-(--border-default) bg-(--bg-primary)/30 text-(--text-secondary) h-8 rounded-full inline-flex items-center justify-center gap-1.5 shrink-0 cursor-pointer text-[13px] whitespace-nowrap transition-colors hover:border-(--border-strong) hover:bg-(--bg-hover) hover:text-(--text-primary)`;function FK({current:e,disabled:t=!1}){let[n,r]=(0,d.useState)(!1),[i,a]=(0,d.useState)(!1),o=jK(),s=o.find(t=>t.value===e)||o[0],c=s.icon,l=async n=>{if(!(n===e||i||t)){a(!0);try{let e=await Pd(n);if(e?.error)throw Error(e.message||`Failed to switch mode`)}catch{}finally{a(!1)}r(!1)}};return(0,_.jsxs)(um,{open:n,onOpenChange:e=>!t&&r(e),children:[(0,_.jsx)(dm,{asChild:!0,children:(0,_.jsxs)(`button`,{type:`button`,className:z(PK,`px-3 hover:border-(--accent-blue)/55 hover:bg-(--accent-blue-bg) hover:text-(--accent-blue)`,(i||t)&&`opacity-50 pointer-events-none`),disabled:t,title:B(t?`switchModeDisabled`:`switchMode`),children:[(0,_.jsx)(c,{size:13}),(0,_.jsx)(`span`,{className:`truncate`,children:s.label}),(0,_.jsx)(mp,{size:11})]})}),(0,_.jsxs)(fm,{side:`top`,align:`start`,sideOffset:6,className:`w-70 p-1 rounded-lg bg-(--bg-primary) border border-(--border-default) shadow-lg`,children:[(0,_.jsx)(`div`,{className:`text-[11px] text-(--text-muted) px-2 py-1.5 font-medium`,children:B(`executionMode`)}),(0,_.jsx)(`div`,{className:`flex flex-col gap-0.5`,children:o.map(n=>{let r=n.icon;return(0,_.jsxs)(`button`,{disabled:t||i,className:z(`w-full border-0 rounded-md px-2 py-1.5 text-left text-[12px] cursor-pointer flex items-center gap-2`,(t||i)&&`opacity-50 cursor-not-allowed`,e===n.value?`bg-(--bg-active) text-(--text-primary) font-medium`:`bg-transparent text-(--text-secondary) hover:bg-(--bg-hover) hover:text-(--text-primary)`),onClick:()=>l(n.value),children:[(0,_.jsx)(r,{size:13,className:`shrink-0 text-(--text-muted)`}),(0,_.jsx)(`span`,{className:`shrink-0`,children:n.label}),(0,_.jsx)(`span`,{className:`text-[10px] text-(--text-muted) min-w-0 text-right leading-4`,children:n.desc})]},n.value)})})]})]})}function IK(){let[e,t]=(0,d.useState)([]),[n,r]=(0,d.useState)(``),[i,a]=(0,d.useState)(!1),o=(0,d.useCallback)(async()=>{try{let e=await nf(),n=Array.isArray(e)?e:[];t(n);let i=n.find(e=>e.active);r(i?i.name:``)}catch{}},[]);(0,d.useEffect)(()=>{o()},[o]);let s=async e=>{await cf(e),r(e),a(!1),o()};return(0,_.jsxs)(um,{open:i,onOpenChange:a,children:[(0,_.jsx)(dm,{asChild:!0,children:(0,_.jsxs)(`button`,{type:`button`,className:z(PK,`px-3`),title:B(`soulSwitch`),children:[(0,_.jsx)(Cp,{size:13}),(0,_.jsx)(`span`,{className:`truncate max-w-[60px]`,children:n||`default`}),(0,_.jsx)(mp,{size:11})]})}),(0,_.jsxs)(fm,{side:`top`,align:`start`,sideOffset:6,className:`w-52 p-1 rounded-lg bg-(--bg-primary) border border-(--border-default) shadow-lg`,children:[(0,_.jsx)(`div`,{className:`text-[11px] text-(--text-muted) px-2 py-1.5 font-medium`,children:B(`switchSoul`)}),(0,_.jsx)(`div`,{className:`flex flex-col gap-0.5`,children:e.map(e=>(0,_.jsxs)(`button`,{className:z(`w-full border-0 rounded-md px-2 py-1.5 text-left text-[12px] cursor-pointer flex items-center gap-2`,e.active?`bg-(--bg-active) text-(--text-primary) font-medium`:`bg-transparent text-(--text-secondary) hover:bg-(--bg-hover) hover:text-(--text-primary)`),onClick:()=>s(e.name),children:[(0,_.jsx)(`span`,{className:`truncate flex-1`,children:e.name}),(0,_.jsx)(`span`,{className:`text-[10px] text-(--text-muted) shrink-0`,children:e.scope===`builtin`?B(`builtin`):B(`custom`)})]},`${e.scope}-${e.name}`))})]})]})}function LK({query:e,onSelect:t,visible:n}){let[r,i]=(0,d.useState)([]),[a,o]=(0,d.useState)(null);(0,d.useEffect)(()=>{n&&Jd().then(e=>{i(Array.isArray(e)?e.filter(e=>e.enabled!==!1&&!AK.has(e.name)&&!NK.has(e.name)):[])}).catch(()=>{})},[n]);let s=e.trim().toLowerCase(),c=(0,d.useMemo)(()=>MK.filter(e=>!s||e.name.includes(s)||e.description.toLowerCase().includes(s)).map(e=>({...e,kind:`action`,key:`action-${e.name}`})),[s]),l=(0,d.useMemo)(()=>r.filter(e=>!s||e.name.toLowerCase().includes(s)||(e.description||``).toLowerCase().includes(s)).map(e=>({name:e.name,insert:`/${e.name} `,icon:Pp,description:e.description||`Manual skill`,kind:`skill`,key:`skill-${e.name}`})),[r,s]);if(!n)return null;let u=c.length>0||l.length>0,f=(e,n)=>n.length?(0,_.jsxs)(`div`,{className:`py-1`,children:[(0,_.jsx)(`div`,{className:`px-2.5 py-1 text-[10px] font-semibold uppercase tracking-[0.45px] text-(--text-muted)`,children:e}),(0,_.jsx)(`div`,{className:`flex flex-col gap-0.5`,children:n.map(e=>{let n=e.icon,r=a===e.key;return(0,_.jsxs)(`button`,{className:z(`w-full border-0 rounded-md px-2.5 py-2 text-left cursor-pointer grid grid-cols-[22px_minmax(96px,180px)_minmax(0,1fr)_auto] items-start gap-2 text-[12px] transition-colors`,r?`bg-(--bg-hover) text-(--text-primary)`:`bg-transparent text-(--text-secondary) hover:bg-(--bg-hover) hover:text-(--text-primary)`),onClick:()=>t(e.insert),onMouseEnter:()=>o(e.key),onMouseLeave:()=>o(null),children:[(0,_.jsx)(`span`,{className:z(`mt-0.5 inline-flex size-5 items-center justify-center rounded-md transition-colors`,e.kind===`action`?`bg-(--accent-cyan-bg) text-(--accent-cyan)`:`bg-(--accent-purple-bg) text-(--accent-purple)`,!r&&`opacity-80`),children:(0,_.jsx)(n,{size:12})}),(0,_.jsxs)(`span`,{className:`truncate font-medium leading-5 font-mono`,children:[`/`,e.name]}),(0,_.jsx)(`span`,{className:`text-(--text-muted) text-[11px] leading-5 overflow-hidden`,style:{display:`-webkit-box`,WebkitLineClamp:2,WebkitBoxOrient:`vertical`},children:e.description}),(0,_.jsx)(`span`,{className:z(`mt-0.5 rounded-full border px-1.5 py-0.5 text-[10px] uppercase leading-none`,e.kind===`action`?`border-(--accent-cyan)/25 text-(--accent-cyan)`:`border-(--accent-purple)/25 text-(--accent-purple)`),children:e.kind})]},e.key)})})]}):null;return(0,_.jsxs)(`div`,{className:`absolute bottom-full left-0 right-0 mb-1.5 max-h-[360px] overflow-y-auto rounded-xl border border-(--border-default) bg-(--bg-primary) shadow-lg z-50 animate-in fade-in-0 zoom-in-95 slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95`,style:{scrollbarWidth:`thin`},children:[!u&&(0,_.jsx)(`div`,{className:`px-2.5 py-5 text-[12px] text-(--text-muted) text-center`,children:`No matching commands`}),f(`Actions`,c),c.length>0&&l.length>0&&(0,_.jsx)(lm,{className:` my-1 bg-(--border-default)`}),f(`Skills`,l)]})}function RK({onSubmit:e,onAbort:t,busy:n,disabled:r=!1,disabledReason:i=``,runtimeState:a,history:o,onCompletionRequest:s,onOpenProject:c,projectCwd:l}){let[u,f]=(0,d.useState)(``),[p,m]=(0,d.useState)([]),[h,g]=(0,d.useState)(-1),[v,y]=(0,d.useState)(``),[b,x]=(0,d.useState)(!1),[S,C]=(0,d.useState)(``),w=(0,d.useRef)(null),T=(a||{}).mode||`normal`,E=n||r,D=l===`__codemini_general__`;(0,d.useEffect)(()=>{o&&o.length&&p.length===0&&m([...o].reverse())},[o]),(0,d.useEffect)(()=>{E&&x(!1)},[E]);let O=(0,d.useCallback)(()=>{let t=u.trim();!t||E||(e(t),f(``),x(!1),g(-1),w.current&&(w.current.style.height=`auto`))},[u,E,e]),ee=(0,d.useCallback)(e=>{if(e.key===`Enter`&&!e.shiftKey){if(b){e.preventDefault();return}e.preventDefault(),O();return}if(b&&e.key===`Escape`){e.preventDefault(),x(!1);return}if(e.key===`ArrowUp`&&p.length>0&&!b){e.preventDefault(),h===-1&&y(u);let t=Math.min(h+1,p.length-1);g(t),f(p[t]);return}if(e.key===`ArrowDown`&&h!==-1&&!b){e.preventDefault();let t=h-1;g(t),f(t<0?v:p[t]);return}e.key===`Tab`&&e.preventDefault()},[u,p,h,v,O,b]),te=(0,d.useCallback)(e=>{let t=e.target.value;f(t),e.target.style.height=`auto`,e.target.style.height=Math.min(e.target.scrollHeight,160)+`px`,t===`/`?(x(!0),C(``)):t.startsWith(`/`)&&!t.includes(` `)?(x(!0),C(t.slice(1))):x(!1),t.startsWith(`/`)&&s&&s(t)},[s]);return(0,_.jsxs)(`div`,{className:`w-full relative`,children:[(0,_.jsx)(LK,{query:S,onSelect:(0,d.useCallback)(e=>{f(e),x(!1),w.current?.focus()},[]),visible:b}),(0,_.jsxs)(`div`,{className:`flex flex-col gap-4 rounded-[28px] px-3 py-2 transition-colors bg-(--bg-primary/50) dark:bg-(--bg-secondary) shadow-(--shadow-default) dark:shadow-none`,children:[(0,_.jsx)(`div`,{className:`flex min-h-[58px]`,children:(0,_.jsx)(`textarea`,{ref:w,value:u,onChange:te,onKeyDown:ee,placeholder:n?B(`inputDisabled`):r?i||B(`inputDisabled`):B(`sendMessageToCodeminiWithSlash`),disabled:E,rows:1,className:`flex-1 resize-none border-0 outline-none bg-transparent text-(--text-primary) min-h-[34px] max-h-[160px] p-1 leading-[1.55] text-[16px] placeholder:text-(--text-muted) disabled:opacity-50 disabled:cursor-not-allowed`,style:{height:`auto`}})}),(0,_.jsxs)(`div`,{className:`flex items-center gap-2 min-h-9 flex-wrap`,children:[(0,_.jsxs)(`div`,{className:`flex items-center gap-2 min-w-0`,children:[(0,_.jsxs)(`button`,{type:`button`,className:z(PK,`px-3`),title:B(`switchWorkspace`),onClick:c,children:[D?(0,_.jsx)(Bp,{size:13,className:`shrink-0`}):(0,_.jsx)(kp,{size:13,className:`shrink-0`}),(0,_.jsx)(`span`,{className:`truncate max-w-[80px]`,children:D?B(`generalChat`):l||`...`}),(0,_.jsx)(mp,{size:11})]}),(0,_.jsx)(FK,{current:T,disabled:E}),(0,_.jsx)(IK,{})]}),(0,_.jsxs)(`div`,{className:`flex items-center gap-2 ml-auto`,children:[(0,_.jsx)(`button`,{type:`button`,className:`border-0 bg-transparent text-(--text-secondary) min-w-9 h-9 rounded-full inline-flex items-center justify-center shrink-0 cursor-pointer transition-colors hover:bg-(--bg-hover) hover:text-(--text-primary)`,title:B(`addContext`),children:(0,_.jsx)(Gp,{size:18})}),n?(0,_.jsx)(`button`,{type:`button`,className:`border-0 text-(--accent-red) min-w-9 h-9 rounded-full inline-flex items-center justify-center shrink-0 cursor-pointer bg-(--accent-red-bg) transition-opacity hover:opacity-80`,onClick:t,title:B(`abort`),children:(0,_.jsx)(Vp,{size:14})}):(0,_.jsx)(`button`,{type:`button`,className:z(`border-0 min-w-10 w-10 h-10 rounded-full inline-flex items-center justify-center shrink-0 cursor-pointer transition-all`,u.trim()&&!E?`bg-(--accent-blue) text-white hover:bg-(--accent-hover)`:`bg-(--text-muted)/25 text-(--text-muted) cursor-not-allowed`),onClick:O,disabled:!u.trim()||E,title:B(`sending`),children:(0,_.jsx)(sp,{size:16})})]})]})]})]})}var zK={thinking:`bg-(--accent-blue)`,streaming:`bg-(--accent-green)`,tooling:`bg-(--accent-orange)`,live:`bg-(--accent-cyan)`},BK=[{pattern:/\bdeepseek\b/i,logo:`/logos/deepseek-color.svg`},{pattern:/\bopenai\b/i,logo:`/logos/openai.svg`},{pattern:/\bgpt\b/i,logo:`/logos/openai.svg`},{pattern:/\bo[134]\b/i,logo:`/logos/openai.svg`},{pattern:/\bgemini\b/i,logo:`/logos/gemini-color.svg`},{pattern:/\bqwen\b/i,logo:`/logos/qwen-color.svg`},{pattern:/\bchatglm\b/i,logo:`/logos/chatglm-color.svg`},{pattern:/\bglm-/i,logo:`/logos/glm-color.svg`},{pattern:/\bkimi\b/i,logo:`/logos/kimi-color.svg`},{pattern:/\bminimax\b/i,logo:`/logos/minimax-color.svg`},{pattern:/\bmoonshot\b/i,logo:`/logos/moonshot.svg`},{pattern:/\bnvidia\b/i,logo:`/logos/nvidia-color.svg`},{pattern:/\bzhipu\b/i,logo:`/logos/zhipu-color.svg`},{pattern:/\bclaude\b/i,logo:`/logos/claude-color.svg`}],VK={"openai-compatible":`/logos/openai.svg`,anthropic:`/logos/claude-color.svg`};function HK(e){if(!e)return null;for(let{pattern:t,logo:n}of BK)if(t.test(e))return n;return null}function UK({src:e,size:t=13}){return e?(0,_.jsx)(`img`,{src:e,alt:``,width:t,height:t,className:`shrink-0 rounded-sm object-contain`}):null}function WK({runtimeState:e,live:t,stageLabel:n}){let r=e||{};r.mode;let i=r.currentContextTokens||0,a=r.maxContextTokens||0,o=a?Math.round(i/a*100):0,s=o<40?`bg-(--accent-green)`:o<75?`bg-(--accent-orange)`:`bg-(--accent-red)`,c=Object.keys(zK).find(e=>(n||``).includes(e))||`live`,l=HK(r.model),u=VK[r.sdkProvider];return(0,_.jsxs)(`div`,{className:`flex items-center gap-3 flex-1 min-w-0 text-[12px] text-(--text-muted) overflow-hidden`,children:[(0,_.jsxs)(`span`,{className:`inline-flex items-center gap-1 whitespace-nowrap`,children:[l?(0,_.jsx)(UK,{src:l}):(0,_.jsx)(up,{size:13,className:`shrink-0 opacity-70`}),(0,_.jsx)(`span`,{children:r.model?.toUpperCase()||`-`})]}),(0,_.jsxs)(`span`,{className:`inline-flex items-center gap-1 whitespace-nowrap`,children:[u?(0,_.jsx)(UK,{src:u}):(0,_.jsx)(Jp,{size:13,className:`shrink-0 opacity-70`}),(0,_.jsx)(`span`,{children:r.sdkProvider?.toUpperCase()||`-`})]}),a>0&&(0,_.jsxs)(`span`,{className:`inline-flex items-center gap-1 whitespace-nowrap`,children:[(0,_.jsx)(fp,{size:13,className:`shrink-0 opacity-70`}),(0,_.jsx)(`span`,{children:`CTX`}),(0,_.jsx)(`span`,{className:`w-12 h-1 bg-(--muted) rounded-full overflow-hidden`,children:(0,_.jsx)(`span`,{className:z(`block h-full rounded-full transition-all`,s),style:{width:`${o}%`}})}),(0,_.jsxs)(`span`,{children:[o,`%`]})]}),(0,_.jsxs)(`span`,{className:`inline-flex items-center gap-1 ml-auto whitespace-nowrap`,children:[(0,_.jsx)(`span`,{className:z(`w-1.5 h-1.5 rounded-full shrink-0`,t?zK[c]:`bg-(--text-muted)`,t&&`animate-pulse`)}),(0,_.jsx)(`span`,{children:t?n:B(`idle`)})]})]})}function GK({className:e,value:t,...n}){return(0,_.jsx)(Lo,{"data-slot":`progress`,className:z(`relative h-2 w-full overflow-hidden rounded-full bg-primary/20`,e),...n,children:(0,_.jsx)(Ro,{"data-slot":`progress-indicator`,className:`h-full w-full flex-1 bg-primary transition-all`,style:{transform:`translateX(-${100-(t||0)}%)`}})})}var KK=`codemini:codewiki:qa-width`,qK=320,JK=760,YK=420,XK=!1;function ZK(){if(typeof window>`u`)return YK;let e=Number(window.localStorage.getItem(KK));return Number.isFinite(e)?Math.min(JK,Math.max(qK,e)):YK}function QK(){return[{value:`fast`,label:B(`generationDepthFast`)},{value:`standard`,label:B(`generationDepthStandard`)},{value:`deep`,label:B(`generationDepthDeep`)}]}function $K(e){if(!e)return``;try{return new Intl.DateTimeFormat(`zh-CN`,{month:`short`,day:`numeric`,hour:`2-digit`,minute:`2-digit`}).format(new Date(e))}catch{return``}}function eq(e){let t=Number(e||0);return!Number.isFinite(t)||t<=0?``:t<1024?`${t} B`:t<1024*1024?`${Math.round(t/1024)} KB`:`${(t/1024/1024).toFixed(1)} MB`}function tq(e,t){let n=Array.isArray(e)?e:[];if(!n.length)return{done:0,total:0,pct:8,label:t||B(`startingAnalysis`),detail:B(`preparingScan`)};let r=n.filter(e=>e.status===`done`).length,i=n.find(e=>e.status===`failed`),a=n.find(e=>e.status===`running`)||n.find(e=>e.status===`in_progress`)||n.find(e=>e.status===`pending`)||n[n.length-1];return{done:r,total:n.length,pct:Math.max(8,Math.round(r/n.length*100)),label:i?B(`generationFailed`):a?.title||t||B(`generatingCodeWiki`),detail:i?i.title:`${r}/${n.length} ${B(`stepsCompleted`)}${a?.role?` · ${a.role.toUpperCase()}`:``}`}}function nq({steps:e,stageLabel:t,compact:n=!1}){let r=tq(e,t);return(0,_.jsxs)(`div`,{className:z(`rounded-lg border border-(--border-default) bg-(--bg-primary) p-3 text-left`,n?`mt-3`:`mt-5 w-full max-w-md`),children:[(0,_.jsxs)(`div`,{className:`flex items-center justify-between gap-3`,children:[(0,_.jsx)(`span`,{className:`truncate text-[12px] font-medium text-(--text-primary)`,children:r.label}),r.total>0&&(0,_.jsxs)(`span`,{className:`shrink-0 text-[11px] text-(--text-muted)`,children:[r.done,`/`,r.total]})]}),(0,_.jsx)(GK,{value:r.pct,className:`mt-2 h-1.5`}),(0,_.jsx)(`p`,{className:`mt-2 truncate text-[11px] text-(--text-muted)`,children:r.detail})]})}function rq(e,t){if(!Array.isArray(e)||e.length===0)return[{type:`tools`,cards:[t]}];let n=e[e.length-1];return n.type===`tools`?[...e.slice(0,-1),{...n,cards:[...n.cards,t]}]:[...e,{type:`tools`,cards:[t]}]}function iq(e,t,n){return(Array.isArray(e)?e:[]).map(e=>{if(e.type!==`tools`)return e;let r=e.cards.findIndex(e=>e.id===t);if(r===-1)return e;let i=[...e.cards];return i[r]=n(i[r]),{...e,cards:i}})}function aq(e){let t=Array.isArray(e)?e:[];return t.length===0?[{type:`text`,text:``,isStreaming:!1}]:t[t.length-1].type===`text`?t:[...t,{type:`text`,text:``,isStreaming:!1}]}function oq(e,t){let n=String(t||``);if(!n)return Array.isArray(e)?e:[];let r=aq(e),i=r[r.length-1];return[...r.slice(0,-1),{...i,text:`${i.text||``}${n}`,isStreaming:!0}]}function sq(e,t){let n=aq(e),r=n.length-1;return n.map((e,n)=>n===r&&e.type===`text`?{...e,text:t,isStreaming:!1}:e)}function cq(e){return(Array.isArray(e)?e:[]).map(e=>e.type===`text`?{...e,isStreaming:!1}:e)}function lq(e,t){switch(t?.type){case`assistant:delta`:return{...e,segments:oq(e.segments,t.text)};case`assistant:response`:return{...e,segments:t.text?sq(e.segments,t.text):cq(e.segments)};case`tool:start`:return{...e,segments:rq(e.segments,{id:t.id,name:t.name,arguments:t.arguments,status:`running`,durationMs:null,summary:``,result:``})};case`tool:result`:return{...e,segments:iq(e.segments,t.id,e=>({...e,result:t.content||e.result||``}))};case`tool:end`:return{...e,segments:iq(e.segments,t.id,e=>({...e,status:`done`,durationMs:t.durationMs,summary:t.summary||e.summary||``}))};case`tool:error`:return{...e,segments:iq(e.segments,t.id,e=>({...e,status:`error`,durationMs:t.durationMs,summary:t.summary||e.summary||``}))};case`tool:blocked`:return{...e,segments:iq(e.segments,t.id,e=>({...e,status:`blocked`,summary:e.summary||`Tool blocked`}))};case`codewiki:done`:return{...e,loading:!1,segments:cq(e.segments)};case`codewiki:error`:return{...e,role:`error`,loading:!1,segments:[{type:`text`,text:t.message||B(`codewikiFailed`),isStreaming:!1}]};default:return e}}function uq({projectCwd:e,projectKey:t,busy:n,planSteps:r=[],stageLabel:i=``}){let[a,o]=(0,d.useState)([]),[s,c]=(0,d.useState)(``),[l,u]=(0,d.useState)(`report`),[f,p]=(0,d.useState)(!0),[m,h]=(0,d.useState)(!1),[g,v]=(0,d.useState)(``),[y,b]=(0,d.useState)(null),[x,S]=(0,d.useState)(!1),[C,w]=(0,d.useState)(``),[T,E]=(0,d.useState)(!1),[D,O]=(0,d.useState)(``),[ee,te]=(0,d.useState)(``),[k,A]=(0,d.useState)(!1),[j,M]=(0,d.useState)(null),[ne,N]=(0,d.useState)(!1),[P,re]=(0,d.useState)(`standard`),[ie,ae]=(0,d.useState)([]),[oe,F]=(0,d.useState)(!1),[I,se]=(0,d.useState)(ZK),[ce,le]=(0,d.useState)(!1),ue=(0,d.useRef)(null),de=(0,d.useRef)({startX:0,startWidth:YK}),fe=(0,d.useMemo)(()=>a.find(e=>e.file===s)||null,[a,s]),pe=fe?`/api/codewiki/report/${encodeURIComponent(fe.file)}${t?`?project=${encodeURIComponent(t)}`:``}`:``,me=(0,d.useCallback)(async()=>{h(!0),v(``);try{let e=await df(t);b(e),e?.error&&v(e.error)}catch(e){v(e?.message||`Failed to load code graph`)}finally{h(!1)}},[t]),he=(0,d.useCallback)(async({preferNewest:e=!1}={})=>{p(!0),w(``);try{let n=await uf(t),r=[...Array.isArray(n?.reports)?n.reports:[]].sort((e,t)=>new Date(t.mtime||0)-new Date(e.mtime||0));o(r),c(t=>e&&r[0]?r[0].file:r.some(e=>e.file===t)?t:r[0]?.file||``)}catch(e){w(e?.message||B(`failedToLoad`))}finally{p(!1)}},[t]);(0,d.useEffect)(()=>{o([]),c(``),u(`report`),E(!1),O(``),te(``),ae([]),F(!1),b(null),v(``),he({preferNewest:!0})},[he,me,t]),(0,d.useEffect)(()=>{let e=ue.current;e&&requestAnimationFrame(()=>{e.scrollTop=e.scrollHeight})},[ie,oe]),(0,d.useEffect)(()=>{x&&n&&A(!0)},[n,x]),(0,d.useEffect)(()=>{!x||n||!k||(he({preferNewest:!0}),S(!1),A(!1))},[n,x,he,k]),(0,d.useEffect)(()=>{window.localStorage.setItem(KK,String(I))},[I]);let ge=(0,d.useCallback)(e=>{e.preventDefault(),le(!0),de.current={startX:e.clientX,startWidth:I};let t=e=>{let t=de.current.startX-e.clientX,n=Math.max(qK,Math.min(JK,window.innerWidth-720));se(Math.min(n,Math.max(qK,de.current.startWidth+t)))},n=()=>{le(!1),document.body.style.cursor=``,document.body.style.userSelect=``,window.removeEventListener(`mousemove`,t),window.removeEventListener(`mouseup`,n)};document.body.style.cursor=`col-resize`,document.body.style.userSelect=`none`,window.addEventListener(`mousemove`,t),window.addEventListener(`mouseup`,n)},[I]),_e=async()=>{if(!(n||x)){w(``),S(!0),A(!1);try{let e=await ff(P,t);e?.error&&(S(!1),w(e.message||B(`failedToStart`)))}catch(e){S(!1),w(e?.message||B(`failedToStart`))}}},ve=async e=>{e.preventDefault();let n=D.trim();if(!n||be||oe)return;let r=Date.now(),i=`cw-assistant-${r}`;te(n),O(``),w(``),ae(e=>[...e,{id:`cw-user-${r}`,role:`you`,text:n,segments:[{type:`text`,text:n,isStreaming:!1}],timestamp:new Date().toISOString()},{id:i,role:`general`,text:``,segments:[],timestamp:new Date().toISOString(),loading:!0}]),F(!0);try{await pf({question:n,reportFile:fe?.file||``,project:t,onEvent:e=>{ae(t=>t.map(t=>t.id===i?lq(t,e):t))}})}catch(e){ae(t=>t.map(t=>t.id===i?{...t,role:`error`,loading:!1,segments:[{type:`text`,text:e?.message||B(`codewikiFailed`),isStreaming:!1}]}:t))}finally{F(!1)}},ye=async()=>{if(j){N(!0),w(``);try{let e=await mf(j.file,t);e?.error?w(e.message||B(`failedToDelete`)):(M(null),E(!1),await he({preferNewest:!1}))}catch(e){w(e?.message||B(`failedToDelete`))}finally{N(!1)}}},be=n||x,xe=be||oe;return(0,_.jsxs)(`div`,{className:`flex-1 min-h-0 bg-(--bg-primary) rounded-[18px] border border-(--border-default) border-b-0 overflow-hidden my-1 mx-1`,children:[(0,_.jsxs)(`div`,{className:`codewiki-layout h-full min-h-0`,style:{"--codewiki-qa-width":`${I}px`},children:[(0,_.jsxs)(`aside`,{className:`border-r border-(--border-default) bg-(--bg-secondary) min-h-0 flex flex-col max-lg:hidden`,children:[(0,_.jsxs)(`div`,{className:`p-4 border-b border-(--border-default)`,children:[(0,_.jsxs)(`div`,{className:`flex items-center gap-2 text-(--text-primary)`,children:[(0,_.jsx)(cp,{size:18}),(0,_.jsx)(`span`,{className:`font-semibold text-[15px]`,children:`CodeWiki`})]}),(0,_.jsx)(`p`,{className:`mt-2 text-[12px] leading-5 text-(--text-muted) truncate`,title:e||``,children:e||B(`currentProject`)}),(0,_.jsx)(`div`,{className:`mt-4 grid grid-cols-3 gap-1 rounded-lg border border-(--border-default) bg-(--bg-primary) p-1`,children:QK().map(e=>(0,_.jsx)(`button`,{type:`button`,className:z(`h-7 rounded-md text-[12px] text-(--text-muted) hover:bg-(--bg-hover) hover:text-(--text-primary) disabled:cursor-not-allowed disabled:opacity-60`,P===e.value&&`bg-(--bg-active) text-(--text-primary)`),disabled:be,onClick:()=>re(e.value),children:e.label},e.value))}),(0,_.jsxs)(`button`,{className:`mt-3 w-full h-9 rounded-lg border border-(--border-default) bg-(--bg-primary) text-[13px] text-(--text-primary) inline-flex items-center justify-center gap-2 hover:bg-(--bg-hover) disabled:cursor-not-allowed disabled:opacity-60`,onClick:_e,disabled:be,children:[x?(0,_.jsx)(Rp,{size:15,className:`animate-spin`}):(0,_.jsx)(nm,{size:15}),B(x?`generating`:`generateNew`)]}),x&&(0,_.jsx)(nq,{steps:r,stageLabel:i,compact:!0})]}),(0,_.jsxs)(`div`,{className:`flex items-center justify-between px-4 py-3`,children:[(0,_.jsx)(`span`,{className:`text-[12px] font-medium text-(--text-muted)`,children:`Documents`}),(0,_.jsx)(`button`,{className:`inline-flex size-7 items-center justify-center rounded-md text-(--text-muted) hover:bg-(--bg-hover) hover:text-(--text-primary)`,onClick:()=>{he({preferNewest:!0})},title:`Refresh`,"aria-label":`Refresh`,children:(0,_.jsx)(Yp,{size:14})})]}),(0,_.jsxs)(`div`,{className:`flex-1 overflow-y-auto px-2 pb-4`,children:[XK,f&&(0,_.jsxs)(`div`,{className:`px-3 py-6 text-[12px] text-(--text-muted) inline-flex items-center gap-2`,children:[(0,_.jsx)(Rp,{size:14,className:`animate-spin`}),B(`loadingReport`)]}),!f&&a.length===0&&(0,_.jsx)(`div`,{className:`mx-2 rounded-lg border border-dashed border-(--border-default) px-3 py-4 text-[12px] leading-5 text-(--text-muted)`,children:B(`noReportYet`)}),(0,_.jsx)(`div`,{className:`flex flex-col gap-1`,children:a.map(e=>(0,_.jsxs)(`div`,{className:z(`group w-full rounded-lg px-3 py-2 text-left hover:bg-(--bg-hover) cursor-pointer`,l===`report`&&s===e.file&&`bg-(--bg-active)`),onClick:()=>{u(`report`),c(e.file),E(!1)},children:[(0,_.jsxs)(`span`,{className:`flex items-start gap-2 text-[13px] text-(--text-primary)`,children:[(0,_.jsx)(Op,{size:14,className:`shrink-0 mt-0.5 text-(--text-muted)`}),(0,_.jsx)(`span`,{className:`min-w-0 flex-1 break-words`,children:e.file}),(0,_.jsxs)(um,{children:[(0,_.jsx)(dm,{asChild:!0,children:(0,_.jsx)(`button`,{type:`button`,className:`inline-flex size-6 shrink-0 items-center justify-center rounded-md text-(--text-muted) opacity-0 hover:bg-(--bg-active) hover:text-(--text-primary) group-hover:opacity-100 focus:opacity-100`,onClick:e=>e.stopPropagation(),"aria-label":B(`reportActions`),children:(0,_.jsx)(wp,{size:14})})}),(0,_.jsx)(fm,{align:`end`,className:`w-36 border-(--border-default) bg-(--bg-primary) p-1 text-(--text-primary)`,onClick:e=>e.stopPropagation(),children:(0,_.jsx)(`button`,{type:`button`,className:`w-full rounded-md px-2.5 py-2 text-left text-[13px] text-(--accent-red) hover:bg-(--accent-red-bg)`,onClick:()=>M(e),children:B(`deleteReport`)})})]})]}),(0,_.jsxs)(`span`,{className:`mt-1 block truncate pl-6 text-[11px] text-(--text-muted)`,children:[$K(e.mtime),eq(e.size)?` · ${eq(e.size)}`:``]})]},e.file))})]})]}),(0,_.jsxs)(`main`,{className:`min-w-0 min-h-0 flex flex-col bg-(--bg-primary)`,children:[C&&(0,_.jsxs)(`div`,{className:`mx-5 mt-4 rounded-lg border border-red-500/30 bg-red-500/10 px-3 py-2 text-[12px] text-red-400 inline-flex items-center gap-2`,children:[(0,_.jsx)(gp,{size:14}),C]}),(0,_.jsx)(`div`,{className:`flex-1 min-h-0 p-4`,children:!fe&&!f?(0,_.jsxs)(`div`,{className:`h-full min-h-[420px] rounded-xl border border-dashed border-(--border-default) bg-(--bg-secondary) flex flex-col items-center justify-center text-center px-8`,children:[(0,_.jsx)(cp,{size:34,className:`text-(--text-muted)`}),(0,_.jsx)(`h2`,{className:`mt-4 text-[18px] font-semibold text-(--text-primary)`,children:B(`noCodeWiki`)}),(0,_.jsx)(`p`,{className:`mt-2 max-w-md text-[13px] leading-6 text-(--text-muted)`,children:B(`reportWillShow`)}),(0,_.jsxs)(`button`,{className:`mt-5 h-10 rounded-lg bg-(--text-primary) px-4 text-[13px] font-medium text-(--bg-primary) inline-flex items-center gap-2 disabled:cursor-not-allowed disabled:opacity-60`,onClick:_e,disabled:be,children:[x?(0,_.jsx)(Rp,{size:16,className:`animate-spin`}):(0,_.jsx)(nm,{size:16}),B(x?`generating`:`generateNew`)]}),(0,_.jsx)(`div`,{className:`mt-3 grid w-full max-w-xs grid-cols-3 gap-1 rounded-lg border border-(--border-default) bg-(--bg-primary) p-1`,children:QK().map(e=>(0,_.jsx)(`button`,{type:`button`,className:z(`h-7 rounded-md text-[12px] text-(--text-muted) hover:bg-(--bg-hover) hover:text-(--text-primary) disabled:cursor-not-allowed disabled:opacity-60`,P===e.value&&`bg-(--bg-active) text-(--text-primary)`),disabled:be,onClick:()=>re(e.value),children:e.label},e.value))}),x&&(0,_.jsx)(nq,{steps:r,stageLabel:i})]}):(0,_.jsx)(`div`,{className:`h-full min-h-[420px] overflow-hidden rounded-xl border border-(--border-default) bg-(--bg-secondary)`,children:T?(0,_.jsxs)(`div`,{className:`h-full flex flex-col items-center justify-center px-8 text-center`,children:[(0,_.jsx)(gp,{size:28,className:`text-(--text-muted)`}),(0,_.jsx)(`p`,{className:`mt-3 text-[13px] text-(--text-secondary)`,children:B(`reportLoadFailed`)}),(0,_.jsx)(`button`,{className:`mt-4 h-8 rounded-md border border-(--border-default) px-3 text-[12px] text-(--text-primary) hover:bg-(--bg-hover)`,onClick:()=>E(!1),children:B(`retry`)})]}):fe?(0,_.jsx)(`iframe`,{title:`CodeWiki ${fe.file}`,src:pe,sandbox:`allow-scripts`,className:`h-full w-full border-0 bg-white`,onLoad:()=>E(!1),onError:()=>E(!0)},fe.file):(0,_.jsxs)(`div`,{className:`h-full flex items-center justify-center text-[13px] text-(--text-muted)`,children:[(0,_.jsx)(Rp,{size:16,className:`mr-2 animate-spin`}),B(`loading`)]})})})]}),(0,_.jsx)(`div`,{className:`codewiki-resizer max-xl:hidden`,role:`separator`,"aria-orientation":`vertical`,"aria-label":`Resize CodeWiki Q&A panel`,title:`Drag to resize`,onMouseDown:ge,children:(0,_.jsx)(`span`,{className:`codewiki-resizer-handle`,children:(0,_.jsx)(Np,{size:14,"aria-hidden":`true`})})}),(0,_.jsxs)(`aside`,{className:`bg-(--bg-secondary) min-h-0 flex flex-col max-xl:hidden`,children:[(0,_.jsx)(`div`,{className:`p-4 border-b border-(--border-default)`,children:(0,_.jsx)(`p`,{className:`mt-2 text-[12px] leading-5 text-(--text-muted)`,children:B(x?`noQuestionsDuringGeneration`:`tempReadOnlyQa`)})}),(0,_.jsx)(`div`,{ref:ue,className:`flex-1 min-h-0 overflow-y-auto px-4 py-3`,children:ie.length===0?(0,_.jsxs)(`div`,{className:`rounded-xl border border-(--border-default) bg-(--bg-primary) p-4`,children:[(0,_.jsx)(`p`,{className:`text-[13px] font-medium text-(--text-primary)`,children:B(x?`generatingCodeWiki`:oe||n?`processingQuestion`:`canAskAboutProject`)}),(0,_.jsx)(`p`,{className:`mt-2 text-[12px] leading-5 text-(--text-muted)`,children:x?B(`askAfterGeneration`):ee||B(`exampleQuestions`)})]}):(0,_.jsx)(`div`,{className:`flex flex-col`,children:ie.map(e=>(0,_.jsxs)(`div`,{children:[(0,_.jsx)(TK,{message:e}),e.loading&&(!e.segments||e.segments.length===0)&&(0,_.jsxs)(`div`,{className:`mt-[-12px] mb-3 ml-1 inline-flex items-center gap-2 rounded-xl border border-(--border-default) bg-(--bg-primary) px-3 py-2 text-[12px] text-(--text-muted)`,children:[(0,_.jsx)(Rp,{size:14,className:`animate-spin`}),B(`answering`)]})]},e.id))})}),(0,_.jsx)(`form`,{className:`p-4 border-t border-(--border-default)`,onSubmit:ve,children:(0,_.jsxs)(`div`,{className:`flex items-center gap-2 rounded-full border border-(--border-default) bg-(--bg-primary) px-3 py-2`,children:[(0,_.jsx)(`input`,{value:D,onChange:e=>O(e.target.value),placeholder:x?B(`generatingCodeWiki`):oe||n?B(`answering`):`Ask about this repository`,disabled:xe,className:`min-w-0 flex-1 border-0 bg-transparent text-[13px] text-(--text-primary) outline-none placeholder:text-(--text-muted) disabled:opacity-60`}),(0,_.jsx)(`button`,{type:`submit`,className:`inline-flex size-7 items-center justify-center rounded-full text-(--text-muted) hover:bg-(--bg-hover) hover:text-(--text-primary) disabled:cursor-not-allowed disabled:opacity-50`,disabled:xe||!D.trim(),"aria-label":B(`sendingQuestion`),children:oe?(0,_.jsx)(Rp,{size:15,className:`animate-spin`}):(0,_.jsx)(Qp,{size:15})})]})})]})]}),ce&&(0,_.jsx)(`div`,{className:`codewiki-resize-overlay`}),(0,_.jsx)(Em,{open:!!j,title:B(`deleteReportConfirm`),description:B(`deleteReportDescription`).replace(`{{report}}`,j?.title||j?.file||``),loading:ne,onOpenChange:e=>!e&&M(null),onConfirm:ye})]})}function dq(e,t){return e===`delete`?`delete`:e===`run`?`run`:e===`edit`?`edit`:e===`write`?`write`:t?.planApproval?`plan`:t?.reflectApproval?`reflect`:`generic`}function fq(e){if(!e)return{};try{let t=typeof e==`string`?JSON.parse(e):e;return{...t,_raw:JSON.stringify(t,null,2)}}catch{return{_raw:String(e)}}}function pq(e,t=520){let n=String(e??``);return n.length<=t?n:`${n.slice(0,t)}...`}function mq({label:e,value:t}){return(0,_.jsxs)(`div`,{className:`flex gap-3 py-1.5 min-w-0`,children:[(0,_.jsx)(`span`,{className:`text-[13px] font-medium text-(--text-muted) w-20 shrink-0`,children:e}),(0,_.jsx)(`span`,{className:`text-[13px] font-mono min-w-0 break-words text-(--text-primary)`,children:String(t)})]})}function hq({label:e,value:t}){return t==null||t===``?null:(0,_.jsxs)(`div`,{className:`py-1.5 min-w-0`,children:[(0,_.jsx)(`div`,{className:`mb-1 text-[13px] font-medium text-(--text-muted)`,children:e}),(0,_.jsx)(`pre`,{className:`max-h-40 overflow-auto rounded-md border border-(--border-default) bg-(--bg-secondary) px-2.5 py-2 text-[12px] leading-5 text-(--text-primary) whitespace-pre-wrap break-words`,children:pq(t)})]})}function gq({variant:e,args:t,details:n}){let r=fq(t);if(e===`delete`)return(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(mq,{label:`File`,value:r.path||r.name||`-`}),(0,_.jsx)(mq,{label:`Type`,value:r.type||`file`})]});if(e===`run`)return(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(mq,{label:`Command`,value:r.command||`-`}),n?.risk&&(0,_.jsx)(mq,{label:`Risk`,value:n.risk}),n?.description&&(0,_.jsx)(mq,{label:`Info`,value:n.description})]});if(e===`edit`){let e=r.edit&&typeof r.edit==`object`?r.edit:{},t=r.kind||e.kind||r.mode||`edit`;return(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(mq,{label:`Tool`,value:`edit`}),(0,_.jsx)(mq,{label:`File`,value:r.file||r.path||`-`}),(0,_.jsx)(mq,{label:`Action`,value:t}),(0,_.jsx)(hq,{label:`Old`,value:r.old_text||e.old_text}),(0,_.jsx)(hq,{label:`New`,value:r.new_text||e.new_text||e.new_content||r.content})]})}return e===`write`?(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(mq,{label:`Tool`,value:`write`}),(0,_.jsx)(mq,{label:`File`,value:r.file||r.path||`-`}),(0,_.jsx)(hq,{label:`Content`,value:r.content||r.text||r.body})]}):e===`plan`?(0,_.jsxs)(_.Fragment,{children:[n?.title&&(0,_.jsx)(`p`,{className:`text-sm mb-2`,children:n.title}),n?.steps&&(0,_.jsx)(`ol`,{className:`list-decimal list-inside space-y-1`,children:n.steps.map((e,t)=>(0,_.jsxs)(`li`,{className:`text-sm`,children:[e.role||``,`: `,e.title||``]},t))})]}):e===`reflect`?(0,_.jsxs)(_.Fragment,{children:[n?.scope&&(0,_.jsx)(mq,{label:`Scope`,value:n.scope}),n?.skillName&&(0,_.jsx)(mq,{label:`Skill`,value:n.skillName}),n?.targetPath&&(0,_.jsx)(mq,{label:`Path`,value:n.targetPath})]}):(0,_.jsx)(hq,{label:`Arguments`,value:r._raw||`-`})}function _q({request:e,open:t,onDecision:n}){if(!e)return null;let{id:r,toolName:i,displayName:a,arguments:o,details:s}=e,c=dq(i,s);return(0,_.jsx)(vm,{open:t,onOpenChange:e=>{e||n(r,!1)},children:(0,_.jsxs)(xm,{className:`sm:max-w-xl max-h-[82vh] grid-rows-[auto_minmax(0,1fr)_auto] overflow-hidden`,children:[(0,_.jsx)(Sm,{children:(0,_.jsx)(wm,{children:{delete:B(`deleteApproval`),run:B(`runApproval`),plan:B(`planApproval`),reflect:B(`reflectApproval`),generic:B(`approveTitle`)}[c]||B(`approveTitle`)})}),(0,_.jsx)(`div`,{className:`min-h-0 overflow-y-auto py-1 pr-1`,children:(0,_.jsx)(gq,{variant:c,args:o,details:s})}),(0,_.jsxs)(Cm,{className:`gap-2`,children:[(0,_.jsx)(_m,{variant:`outline`,onClick:()=>n(r,!1),children:B(`deny`)}),(0,_.jsx)(_m,{onClick:()=>n(r,!0),children:B(`approve`)})]})]})})}var vq=hm(`inline-flex w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-full border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3`,{variants:{variant:{default:`bg-primary text-primary-foreground [a&]:hover:bg-primary/90`,secondary:`bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90`,destructive:`bg-destructive text-white focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40 [a&]:hover:bg-destructive/90`,outline:`border-border text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground`,ghost:`[a&]:hover:bg-accent [a&]:hover:text-accent-foreground`,link:`text-primary underline-offset-4 [a&]:hover:underline`}},defaultVariants:{variant:`default`}});function yq({className:e,variant:t=`default`,asChild:n=!1,...r}){return(0,_.jsx)(n?y:`span`,{"data-slot":`badge`,"data-variant":t,className:z(vq({variant:t}),e),...r})}function bq({className:e,...t}){return(0,_.jsx)(`textarea`,{"data-slot":`textarea`,className:z(`flex field-sizing-content min-h-16 w-full rounded-md border border-input bg-transparent px-3 py-2 text-base shadow-xs transition-[color,box-shadow] outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:aria-invalid:ring-destructive/40`,e),...t})}var xq={planner:`bg-(--accent-purple-bg) text-(--accent-purple)`,coder:`bg-(--accent-green-bg) text-(--accent-green)`,reviewer:`bg-(--accent-orange-bg) text-(--accent-orange)`,tester:`bg-(--accent-blue-bg) text-(--accent-blue)`,advisor:`bg-(--accent-blue-bg) text-(--accent-blue)`,summarizer:`bg-(--accent-cyan-bg) text-(--accent-cyan)`};function Sq({steps:e}){if(!e?.length)return null;let t=e.filter(e=>e.status===`done`).length,n=t===e.length,r=Math.round(t/e.length*100);return(0,_.jsxs)(`div`,{className:`border border-(--border-default) rounded-lg p-3 my-2 max-w-3xl mx-auto bg-(--bg-secondary)`,children:[(0,_.jsxs)(`div`,{className:`flex items-center justify-between mb-2`,children:[(0,_.jsx)(`span`,{className:`text-[13px] font-medium text-(--text-primary)`,children:B(`planTitle`)}),(0,_.jsx)(yq,{className:z(`text-[11px]`,n?`bg-(--accent-green-bg) text-(--accent-green)`:`bg-(--accent-blue-bg) text-(--accent-blue)`),children:n?B(`planDone`):`${t}/${e.length}`})]}),(0,_.jsx)(GK,{value:r,className:`h-1.5 mb-3`}),(0,_.jsx)(`div`,{className:`space-y-1.5`,children:e.map((e,t)=>(0,_.jsxs)(`div`,{className:`flex items-center gap-2 text-[13px]`,children:[(0,_.jsx)(`span`,{className:z(`w-5 h-5 rounded-full flex items-center justify-center text-[11px] font-medium shrink-0`,e.status===`done`&&`bg-(--accent-green-bg) text-(--accent-green)`,e.status===`failed`&&`bg-(--accent-red-bg) text-(--accent-red)`,e.status===`running`&&`bg-(--accent-blue-bg) text-(--accent-blue)`,e.status===`pending`&&`bg-(--muted) text-(--muted-foreground)`),children:e.status===`done`?`✓`:e.status===`failed`?`✗`:e.status===`running`?`▶`:t+1}),(0,_.jsx)(yq,{variant:`outline`,className:z(`text-[11px] px-1.5 py-0`,xq[e.role]||`bg-(--muted) text-(--muted-foreground)`),children:e.role?.toUpperCase()}),(0,_.jsx)(`span`,{className:`truncate text-(--text-secondary)`,children:e.title})]},t))})]})}function Cq({plan:e,onAction:t,disabled:n=!1}){let[r,i]=(0,d.useState)(!1),[a,o]=(0,d.useState)(``);if(!e)return null;let s=Array.isArray(e.steps)?e.steps:[];return(0,_.jsxs)(`div`,{className:`border border-(--border-default) rounded-lg p-3 max-w-3xl mx-auto bg-(--bg-secondary) space-y-2.5`,children:[(0,_.jsxs)(`div`,{className:`flex items-center justify-between`,children:[(0,_.jsx)(`span`,{className:`text-[13px] font-medium text-(--text-primary)`,children:B(`planReviewTitle`)}),(0,_.jsx)(yq,{className:`text-[11px] bg-(--accent-orange-bg) text-(--accent-orange)`,children:B(`planReviewStatus`)})]}),(0,_.jsx)(`p`,{className:`text-[13px] text-(--text-secondary) leading-relaxed`,children:e.goal}),e.summary&&(0,_.jsx)(`p`,{className:`text-[12px] text-(--text-muted) leading-relaxed`,children:e.summary}),(0,_.jsx)(`div`,{className:`space-y-1.5`,children:s.map((e,t)=>(0,_.jsxs)(`div`,{className:`flex items-center gap-2 text-[13px]`,children:[(0,_.jsx)(`span`,{className:`w-5 h-5 rounded-full bg-(--muted) text-(--muted-foreground) flex items-center justify-center text-[11px] font-medium shrink-0`,children:t+1}),(0,_.jsx)(yq,{variant:`outline`,className:z(`text-[11px] px-1.5 py-0 shrink-0`,xq[e.role||``]||`bg-(--muted) text-(--muted-foreground)`),children:String(e.role||`step`).toUpperCase()}),(0,_.jsx)(`span`,{className:`truncate text-(--text-secondary)`,children:e.title})]},t))}),r&&(0,_.jsx)(bq,{value:a,onChange:e=>o(e.target.value),placeholder:B(`planEditPlaceholder`),className:`min-h-[64px] text-[13px]`,autoFocus:!0}),(0,_.jsxs)(`div`,{className:`flex items-center gap-2 pt-1`,children:[(0,_.jsx)(_m,{variant:`destructive`,size:`xs`,disabled:n,onClick:()=>t(`reject`),children:B(`planReject`)}),(0,_.jsx)(_m,{variant:`outline`,size:`xs`,disabled:n||r&&!a.trim(),onClick:()=>{r?(a.trim()&&t(`edit`,a),a.trim()&&(i(!1),o(``))):i(!0)},children:B(r?`planSubmitFeedback`:`planEdit`)}),(0,_.jsx)(_m,{size:`xs`,disabled:n,onClick:()=>t(`approve`),children:B(`planApprove`)})]})]})}function wq(e){let t=Number(e);return Number.isFinite(t)?t.toFixed(2):`0.75`}function Tq({draft:e,onAction:t,disabled:n=!1}){let[r,i]=(0,d.useState)(!1),[a,o]=(0,d.useState)(``);if(!e)return null;let s=()=>{let e=a.trim();e&&(t(`edit`,e),i(!1),o(``))};return(0,_.jsxs)(`div`,{className:`border border-(--border-default) rounded-lg p-3 max-w-3xl mx-auto bg-(--bg-secondary) space-y-3 shadow-sm`,children:[(0,_.jsx)(`div`,{className:`flex items-start justify-between gap-3`,children:(0,_.jsxs)(`div`,{className:`min-w-0`,children:[(0,_.jsxs)(`div`,{className:`flex items-center gap-2 min-w-0`,children:[(0,_.jsx)(`span`,{className:`text-[13px] font-medium text-(--text-primary)`,children:B(`reflectReviewTitle`)}),(0,_.jsx)(yq,{className:`text-[11px] bg-(--accent-purple-bg) text-accent-purple`,children:B(`reflectReviewStatus`)})]}),(0,_.jsxs)(`div`,{className:`mt-1 flex flex-wrap items-center gap-2 text-[12px] text-(--text-muted)`,children:[(0,_.jsxs)(`span`,{children:[B(`reflectScope`),`: `,e.scope||`project`]}),(0,_.jsxs)(`span`,{children:[B(`reflectConfidence`),`: `,wq(e.confidence)]})]})]})}),(0,_.jsxs)(`div`,{className:`space-y-1`,children:[(0,_.jsxs)(`div`,{className:`text-[14px] font-medium text-(--text-primary) break-words`,children:[`/`,e.name||`reflected-skill`]}),e.description&&(0,_.jsx)(`p`,{className:`text-[13px] leading-relaxed text-(--text-secondary)`,children:e.description}),e.targetPath&&(0,_.jsx)(`p`,{className:`text-[12px] font-mono break-all text-(--text-muted)`,children:e.targetPath})]}),e.content&&(0,_.jsx)(`pre`,{className:`max-h-56 overflow-auto rounded-md border border-(--border-default) bg-(--bg-primary) p-3 text-[12px] leading-relaxed text-(--text-secondary) whitespace-pre-wrap`,children:e.content}),r&&(0,_.jsx)(bq,{value:a,onChange:e=>o(e.target.value),placeholder:B(`reflectEditPlaceholder`),className:`min-h-[68px] text-[13px]`,autoFocus:!0}),(0,_.jsxs)(`div`,{className:`flex items-center gap-2 pt-1`,children:[(0,_.jsx)(_m,{variant:`destructive`,size:`xs`,disabled:n,onClick:()=>t(`reject`),children:B(`reflectReject`)}),(0,_.jsx)(_m,{variant:`outline`,size:`xs`,disabled:n||r&&!a.trim(),onClick:()=>r?s():i(!0),children:B(r?`reflectSubmitFeedback`:`reflectEdit`)}),(0,_.jsx)(_m,{size:`xs`,disabled:n,onClick:()=>t(`approve`),children:B(`reflectApprove`)})]})]})}var Eq={running:{icon:Rp,className:`border-(--accent-cyan)/30 bg-(--accent-cyan-bg) text-(--accent-cyan)`,iconClassName:`animate-spin`},done:{icon:_p,className:`border-(--accent-green)/30 bg-(--accent-green-bg) text-(--accent-green)`,iconClassName:``},error:{icon:yp,className:`border-(--accent-red)/30 bg-(--accent-red-bg) text-(--accent-red)`,iconClassName:``}};function Dq({activities:e=[]}){let t=e.slice(0,3);return t.length?(0,_.jsx)(`div`,{className:`mb-2 flex flex-wrap items-center justify-center gap-2`,children:t.map(e=>{let t=Eq[e.status]||Eq.done,n=t.icon;return(0,_.jsxs)(`div`,{className:z(`inline-flex max-w-full items-center gap-1.5 rounded-full border px-2.5 py-1 text-[12px] leading-none shadow-sm`,t.className),children:[(0,_.jsx)(`span`,{className:`shrink-0`,"aria-hidden":`true`,children:e.emoji}),(0,_.jsx)(n,{size:13,className:z(`shrink-0`,t.iconClassName)}),(0,_.jsx)(`span`,{className:`truncate text-(--text-primary)`,children:e.label}),e.detail&&(0,_.jsx)(`span`,{className:`max-w-[180px] truncate text-(--text-muted)`,children:e.detail})]},e.id)})}):null}function Oq({className:e,type:t,...n}){return(0,_.jsx)(`input`,{type:t,"data-slot":`input`,className:z(`h-8 w-full min-w-0 rounded-md border border-(--border-default) bg-transparent px-3 py-1 text-[13px] transition-colors outline-none placeholder:text-(--text-muted) disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50`,`focus-visible:border-(--text-secondary) focus-visible:ring-0`,e),...n})}function kq({...e}){return(0,_.jsx)(Lc,{"data-slot":`select`,...e})}function Aq({...e}){return(0,_.jsx)(zc,{"data-slot":`select-value`,...e})}function jq({className:e,size:t,children:n,...r}){return(0,_.jsxs)(Rc,{"data-slot":`select-trigger`,"data-size":t,className:z(`flex w-fit items-center justify-between gap-2 rounded-md border border-(--border-default) bg-transparent px-3 py-1 text-[13px] whitespace-nowrap transition-colors outline-none focus-visible:border-(--text-secondary) focus-visible:ring-0 disabled:cursor-not-allowed disabled:opacity-50 data-[placeholder]:text-(--text-muted) h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-(--text-muted)`,e),...r,children:[n,(0,_.jsx)(Bc,{asChild:!0,children:(0,_.jsx)(mp,{className:`size-3.5 opacity-50`})})]})}function Mq({className:e,children:t,position:n=`item-aligned`,align:r=`center`,...i}){return(0,_.jsx)(Vc,{children:(0,_.jsxs)(Hc,{"data-slot":`select-content`,className:z(`relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-lg border border-(--border-default) bg-(--bg-primary) text-(--text-primary) shadow-md data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95`,n===`popper`&&`data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1`,e),position:n,align:r,...i,children:[(0,_.jsx)(Pq,{}),(0,_.jsx)(Uc,{className:z(`p-1`,n===`popper`&&`h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]`),children:t}),(0,_.jsx)(Fq,{})]})})}function Nq({className:e,children:t,...n}){return(0,_.jsxs)(Wc,{"data-slot":`select-item`,className:z(`relative flex w-full cursor-pointer items-center gap-2 rounded-md py-1.5 pr-8 pl-2 text-[13px] outline-hidden select-none hover:bg-(--bg-hover) data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-(--text-muted) *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2`,e),...n,children:[(0,_.jsx)(`span`,{"data-slot":`select-item-indicator`,className:`absolute right-2 flex size-3.5 items-center justify-center`,children:(0,_.jsx)(Kc,{children:(0,_.jsx)(pp,{className:`size-4`})})}),(0,_.jsx)(Gc,{children:t})]})}function Pq({className:e,...t}){return(0,_.jsx)(qc,{"data-slot":`select-scroll-up-button`,className:z(`flex cursor-default items-center justify-center py-1`,e),...t,children:(0,_.jsx)(mp,{className:`size-4 rotate-180`})})}function Fq({className:e,...t}){return(0,_.jsx)(Jc,{"data-slot":`select-scroll-down-button`,className:z(`flex cursor-default items-center justify-center py-1`,e),...t,children:(0,_.jsx)(mp,{className:`size-4`})})}function Iq(e,t){return t.split(`.`).reduce((e,t)=>e?.[t],e)}function Lq({open:e,onOpenChange:t,status:n=null,onSaved:r}){let i=[{title:B(`gateway`),keys:[{path:`gateway.base_url`,label:B(`baseUrl`),placeholder:`http://127.0.0.1:8000/v1`},{path:`gateway.api_key`,label:B(`apiKey`),type:`password`,placeholder:`sk-...`},{path:`gateway.timeout_ms`,label:B(`timeout`),type:`number`},{path:`gateway.max_retries`,label:B(`maxRetries`),type:`number`}]},{title:B(`sdk`),keys:[{path:`sdk.provider`,label:B(`provider`),options:[`openai-compatible`,`anthropic`],optionLogos:{"openai-compatible":`/logos/openai.svg`,anthropic:`/logos/claude-color.svg`}}]},{title:B(`model`),keys:[{path:`model.name`,label:B(`modelName`),placeholder:`gpt-4.1-mini`},{path:`model.fast_name`,label:B(`fastModel`),placeholder:`fallback to Model Name when empty`},{path:`model.max_context_tokens`,label:B(`maxContextTokens`),type:`number`}]},{title:B(`execution`),keys:[{path:`execution.mode`,label:B(`mode`),options:[`normal`,`auto`,`plan`],optionLabels:{normal:B(`normalExecutionMode`),auto:B(`autoMode`),plan:B(`planMode`)}},{path:`execution.max_steps`,label:B(`maxSteps`),type:`number`},{path:`ui.reply_language`,label:B(`replyLanguage`),options:[`zh`,`en`]}]},{title:B(`context`),keys:[{path:`context.preflight_trigger_pct`,label:B(`preflightTrigger`),type:`number`,placeholder:`60`},{path:`context.hard_limit_pct`,label:B(`hardLimit`),type:`number`,placeholder:`98`},{path:`context.tool_result_max_chars`,label:B(`toolResultMaxChars`),type:`number`,placeholder:`12000`},{path:`context.microcompact_enabled`,label:B(`microcompactEnabled`),options:[`true`,`false`]},{path:`context.microcompact_keep_recent`,label:B(`microcompactKeepRecent`),type:`number`,placeholder:`5`}]},{title:B(`shell`),keys:[{path:`shell.default`,label:B(`defaultShell`),options:[`bash`,`powershell`,`zsh`,`cmd`]}]},{title:B(`policy`),keys:[{path:`policy.safe_mode`,label:B(`safeMode`),options:[`true`,`false`]},{path:`policy.allowed_paths`,label:B(`allowedPaths`),placeholder:`["D:\\\\shared-assets","E:\\\\sibling-repo"]`,help:B(`allowedPathsHelp`)},{path:`policy.allow_dangerous_commands`,label:B(`allowDangerousCommands`),options:[`false`,`true`]}]}],[a,o]=(0,d.useState)(null),[s,c]=(0,d.useState)({}),[l,u]=(0,d.useState)(!1);(0,d.useEffect)(()=>{e&&(u(!0),zd().then(e=>{o(e),c({})}).catch(()=>{}).finally(()=>u(!1)))},[e]);let f=(e,t)=>{c(n=>({...n,[e]:t}))},p=e=>{if(e in s)return s[e];let t=a?Iq(a,e):``;return Array.isArray(t)||t&&typeof t==`object`?JSON.stringify(t):String(t??``)},m=Object.keys(s).length>0;return(0,_.jsx)(vm,{open:e,onOpenChange:t,children:(0,_.jsxs)(xm,{className:`sm:max-w-[640px] max-h-[80vh] flex flex-col`,children:[(0,_.jsx)(Sm,{className:`shrink-0`,children:(0,_.jsx)(wm,{children:B(`settingsTitle`)})}),(0,_.jsxs)(`div`,{className:`space-y-5 px-2.5 py-1 overflow-y-auto flex-1 min-h-0`,children:[n?.setupRequired&&(0,_.jsxs)(`div`,{className:`rounded-md border border-(--border-default) bg-(--bg-secondary) px-3 py-2 text-[13px] text-(--text-primary)`,children:[(0,_.jsx)(`div`,{className:`font-medium`,children:B(`configRequiredTitle`)}),(0,_.jsx)(`div`,{className:`mt-1 text-(--text-secondary)`,children:B(`configRequiredDesc`)})]}),l?(0,_.jsx)(`div`,{className:`flex items-center justify-center py-12`,children:(0,_.jsx)(Dm,{})}):i.map((e,t)=>(0,_.jsxs)(`div`,{children:[(0,_.jsx)(`div`,{className:`text-[13px] font-semibold text-(--text-secondary) mb-2.5 uppercase tracking-[0.3px]`,children:e.title}),(0,_.jsx)(`div`,{className:`space-y-2.5`,children:e.keys.map(e=>(0,_.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,_.jsxs)(`label`,{className:`text-[13px] text-(--text-muted) w-32 shrink-0`,children:[(0,_.jsx)(`span`,{children:e.label}),e.help&&(0,_.jsxs)(hd,{children:[(0,_.jsx)(gd,{asChild:!0,children:(0,_.jsx)(`button`,{type:`button`,className:`ml-1 inline-flex align-[-2px] text-(--text-muted) hover:text-(--text-primary)`,"aria-label":e.help,children:(0,_.jsx)(vp,{size:13,strokeWidth:1.8})})}),(0,_.jsx)(_d,{side:`right`,className:`max-w-[300px] leading-relaxed`,children:e.help})]})]}),e.options?(0,_.jsxs)(kq,{value:p(e.path),onValueChange:t=>f(e.path,t),children:[(0,_.jsx)(jq,{className:`flex-1 h-8 text-[13px]`,children:(0,_.jsx)(Aq,{})}),(0,_.jsx)(Mq,{children:e.options.map(t=>(0,_.jsx)(Nq,{value:t,children:(0,_.jsxs)(`span`,{className:`inline-flex items-center gap-1.5`,children:[e.optionLogos?.[t]&&(0,_.jsx)(`img`,{src:e.optionLogos[t],alt:``,width:13,height:13,className:`shrink-0 rounded-sm object-contain`}),e.optionLabels?.[t]||(e.optionLogos?t.toUpperCase():t)]})},t))})]}):(0,_.jsx)(Oq,{type:e.type||`text`,value:p(e.path),onChange:t=>f(e.path,t.target.value),placeholder:e.placeholder||``,className:`flex-1 h-8 text-[13px]`})]},e.path))}),t<i.length-1&&(0,_.jsx)(lm,{className:`mt-4 bg-(--border-default)`})]},e.title))]}),(0,_.jsxs)(Cm,{className:`gap-2 shrink-0`,children:[(0,_.jsx)(_m,{variant:`outline`,onClick:()=>t(!1),className:`text-[13px]`,children:B(`cancel`)}),(0,_.jsx)(_m,{onClick:async()=>{try{for(let[e,t]of Object.entries(s))await Vd(e,i.flatMap(e=>e.keys).find(t=>t.path===e)?.type===`number`?Number(t):t);await r?.(),c({}),t(!1)}catch(e){console.error(`Config save failed:`,e)}},disabled:!m,className:`text-[13px]`,children:B(`saveChanges`)})]})]})})}function Rq({className:e,children:t,...n}){return(0,_.jsxs)(xs,{"data-slot":`scroll-area`,className:z(`relative`,e),...n,children:[(0,_.jsx)(Ss,{"data-slot":`scroll-area-viewport`,className:`size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:ring-ring/50 focus-visible:outline-1`,children:t}),(0,_.jsx)(zq,{}),(0,_.jsx)(Cs,{})]})}function zq({className:e,orientation:t=`vertical`,...n}){return(0,_.jsx)(Yo,{"data-slot":`scroll-area-scrollbar`,orientation:t,className:z(`flex touch-none p-px transition-colors select-none`,t===`vertical`&&`h-full w-2.5 border-l border-l-transparent`,t===`horizontal`&&`h-2.5 flex-col border-t border-t-transparent`,e),...n,children:(0,_.jsx)(os,{"data-slot":`scroll-area-thumb`,className:`relative flex-1 rounded-full bg-border`})})}var Bq=`__codemini_general__`,Vq=[{value:`general`,label:B(`generalChat`)},{value:`project`,label:B(`projectTask`)}];function Hq({open:e,onOpenChange:t,onOpenProject:n}){let[r,i]=(0,d.useState)(`project`),[a,o]=(0,d.useState)(!1),[s,c]=(0,d.useState)(``),[l,u]=(0,d.useState)(null),[f,p]=(0,d.useState)(``);(0,d.useEffect)(()=>{e&&Hd().then(e=>{let t=e.cwd||``;e.isGeneral?(i(`general`),c(``),p(``),m(``)):(i(`project`),c(t),p(t||``),m(t||``))}).catch(()=>{})},[e]);let m=async e=>{try{let t=await qd(e),n=!e&&!t.path&&t.roots?.[0]?.path;if(n){let e=await qd(n);u(e),p(e.path??n),c(e.path??n);return}u(t),p(t.path??e)}catch{}},h=()=>{if(r===`general`){t(!1),n(Bq);return}let e=s.trim();e&&(t(!1),n(e))},g=(f||``).replace(/\\/g,`/`),v=/^[A-Za-z]:($|\/)/.test(g),y=g.startsWith(`/`)||v,b=g.split(`/`).filter(Boolean),x=e=>e.length?/^[A-Za-z]:$/.test(e[0])?e.length===1?`${e[0]}/`:`${e[0]}/${e.slice(1).join(`/`)}`:`${y?`/`:``}${e.join(`/`)}`:``,S=l?.roots||[],C=e=>String(e||``).replace(/\\/g,`/`).toLowerCase(),w=S.slice().sort((e,t)=>C(t.path).length-C(e.path).length).find(e=>{let t=C(e.path),n=C(f||s);return t&&(n===t||n.startsWith(t.endsWith(`/`)?t:`${t}/`))}),T=Vq.find(e=>e.value===r)||Vq[1];return(0,_.jsx)(vm,{open:e,onOpenChange:t,children:(0,_.jsxs)(xm,{className:`sm:max-w-lg`,children:[(0,_.jsx)(Sm,{children:(0,_.jsx)(wm,{children:B(`selectProject`)})}),(0,_.jsxs)(`div`,{className:`relative`,children:[(0,_.jsxs)(`button`,{type:`button`,onClick:()=>o(!a),className:`w-full flex items-center justify-between h-9 px-3 rounded-lg border border-(--border-default) bg-(--bg-input) text-[13px] text-(--text-primary) cursor-pointer hover:bg-(--bg-hover)`,children:[(0,_.jsx)(`span`,{className:`font-medium`,children:T.label}),(0,_.jsx)(mp,{size:14,className:`text-(--text-muted)`})]}),a&&(0,_.jsx)(`div`,{className:`absolute top-full left-0 right-0 mt-1 rounded-lg border border-(--border-default) bg-(--bg-primary) shadow-lg z-50 p-1`,children:Vq.map(e=>(0,_.jsx)(`button`,{className:z(`w-full text-left px-3 py-2 my-1 text-[13px] rounded-md cursor-pointer border-0`,r===e.value?`bg-(--bg-active) text-(--text-primary) font-medium`:`bg-transparent text-(--text-secondary) hover:bg-(--bg-hover)`),onClick:()=>{i(e.value),o(!1)},children:e.label},e.value))})]}),r===`general`?(0,_.jsxs)(`div`,{className:`flex flex-col items-center gap-4 py-8 text-(--text-muted) text-[13px]`,children:[(0,_.jsx)(`span`,{children:B(`generalChatDesc`)}),(0,_.jsx)(_m,{onClick:h,className:`text-[13px] h-8`,children:B(`enterGeneral`)})]}):(0,_.jsxs)(_.Fragment,{children:[(0,_.jsxs)(`div`,{className:`flex gap-2`,children:[S.length>0&&(0,_.jsxs)(kq,{value:w?.path||S[0]?.path,onValueChange:e=>{c(e),m(e)},children:[(0,_.jsx)(jq,{className:`w-[132px] h-8 bg-(--bg-input) text-(--text-primary)`,children:(0,_.jsx)(Aq,{})}),(0,_.jsx)(Mq,{align:`start`,children:S.map(e=>(0,_.jsxs)(Nq,{value:e.path,children:[(0,_.jsx)(`span`,{className:`font-medium`,children:e.name}),(0,_.jsx)(`span`,{className:`text-(--text-muted) truncate`,children:e.path})]},e.path))})]}),(0,_.jsx)(Oq,{value:s,onChange:e=>c(e.target.value),placeholder:B(`enterOrBrowse`),onKeyDown:e=>e.key===`Enter`&&h(),className:`flex-1 h-8 text-[13px]`}),(0,_.jsx)(_m,{onClick:h,className:`text-[13px] h-8`,children:B(`select`)})]}),(0,_.jsxs)(`div`,{className:`border border-(--border-default) rounded-lg overflow-hidden`,children:[(0,_.jsx)(`div`,{className:`flex items-center gap-1 text-[12px] px-3 py-2 border-b border-(--border-default) bg-(--bg-secondary) flex-wrap text-(--text-secondary)`,children:b.map((e,t)=>{let n=x(b.slice(0,t+1));return(0,_.jsxs)(`span`,{className:`flex items-center gap-1`,children:[t>0&&(0,_.jsx)(`span`,{className:`text-(--text-muted)`,children:`/`}),(0,_.jsx)(`button`,{onClick:()=>{c(n),m(n)},className:z(`hover:underline cursor-pointer border-0 bg-transparent`,t===b.length-1?`text-(--text-primary) font-medium`:`text-(--accent-blue)`),children:e})]},t)})}),(0,_.jsx)(Rq,{className:`h-[240px]`,children:l&&(0,_.jsxs)(`div`,{className:`p-2`,children:[b.length>0&&(0,_.jsx)(`button`,{className:`w-full text-left px-2 py-1.5 text-[13px] hover:bg-(--bg-hover) rounded cursor-pointer flex items-center gap-2 border-0 bg-transparent text-(--text-secondary)`,onClick:()=>{let e=x(b.slice(0,-1));c(e),m(e)},children:(0,_.jsx)(`span`,{children:`..`})}),(l.dirs||[]).map(e=>(0,_.jsxs)(`button`,{className:`w-full text-left px-2 py-1.5 text-[13px] hover:bg-(--bg-hover) rounded cursor-pointer flex items-center gap-2 border-0 bg-transparent text-(--text-secondary)`,onClick:()=>{c(e.path),m(e.path)},children:[(0,_.jsx)(`span`,{className:`flex-1 truncate`,children:e.name}),e.isGit&&(0,_.jsx)(`span`,{className:`text-[11px] text-(--text-muted) bg-(--bg-tertiary) px-1.5 py-0.5 rounded`,children:`git`})]},e.path)),!(l.roots||[]).length&&!(l.dirs||[]).length&&!l.error&&(0,_.jsx)(`div`,{className:`text-center text-[12px] text-(--text-muted) py-4`,children:B(`noSubDirs`)})]})})]})]})]})})}var Uq=[`all`,`enabled`,`builtin`,`custom`],Wq=[`always`,`auto_attach`,`agent_requested`,`manual`];function Gq({checked:e,onClick:t,title:n}){return(0,_.jsx)(`button`,{type:`button`,onClick:t,title:n,"aria-pressed":e,className:z(`relative h-5 w-9 rounded-full border shadow-inner transition-colors`,e?`border-(--text-primary) bg-(--text-primary)`:`border-(--border-strong) bg-(--bg-hover)`),children:(0,_.jsx)(`span`,{className:z(`absolute left-0.5 top-0.5 size-3.5 rounded-full transition-transform`,e?`bg-(--bg-primary)`:`bg-(--text-muted)`,e?`translate-x-4`:`translate-x-0`)})})}function Kq(e){return B(e===`builtin`?`builtin`:e===`global`?`globalScope`:`projectScope`)}function qq(e){return e?.scope===`builtin`}function Jq(e){return e?.enabled!==!1}function Yq({skill:e,onSave:t,onCancel:n}){let[r,i]=(0,d.useState)(e?.name||``),[a,o]=(0,d.useState)(e?.description||``),[s,c]=(0,d.useState)(e?.scope||`project`),[l,u]=(0,d.useState)(e?.mode||`agent_requested`),[f,p]=(0,d.useState)((e?.triggers||[]).join(`, `)),[m,h]=(0,d.useState)(e?.priority??50),[g,v]=(0,d.useState)(Jq(e)),[y,b]=(0,d.useState)(``),[x,S]=(0,d.useState)(!1),C=!e,w=qq(e);return(0,d.useEffect)(()=>{if(i(e?.name||``),o(e?.description||``),c(e?.scope||`project`),u(e?.mode||`agent_requested`),p((e?.triggers||[]).join(`, `)),h(e?.priority??50),v(Jq(e)),!e){b(``);return}S(!0),Yd(e.name).then(e=>b(e.content||``)).catch(()=>{}).finally(()=>S(!1))},[e]),(0,_.jsxs)(`div`,{className:`flex min-h-0 flex-1 flex-col`,children:[(0,_.jsxs)(`div`,{className:`min-h-0 flex-1 overflow-y-auto pr-1`,children:[(0,_.jsxs)(`div`,{className:`mb-3 flex items-start justify-between gap-3`,children:[(0,_.jsxs)(`div`,{children:[(0,_.jsx)(`div`,{className:`text-[13px] font-medium text-(--text-primary)`,children:B(C?`newSkill`:`editSkill`)}),(0,_.jsx)(`div`,{className:`mt-0.5 text-[11px] text-(--text-muted)`,children:B(`skillEditorHint`)})]}),(0,_.jsx)(yq,{variant:`outline`,className:`rounded-md px-1.5 py-0 text-[10px]`,children:Kq(s)})]}),(0,_.jsxs)(`div`,{className:`grid gap-3`,children:[(C||!qq(e))&&(0,_.jsxs)(`div`,{className:`grid gap-1.5`,children:[(0,_.jsx)(`label`,{className:`text-[12px] text-(--text-muted)`,children:B(`skillScope`)}),(0,_.jsxs)(kq,{value:s,onValueChange:c,children:[(0,_.jsx)(jq,{className:`h-8 w-full bg-(--bg-primary) text-[13px]`,children:(0,_.jsx)(Aq,{})}),(0,_.jsxs)(Mq,{align:`start`,children:[(0,_.jsx)(Nq,{value:`project`,children:B(`projectScope`)}),(0,_.jsx)(Nq,{value:`global`,children:B(`globalScope`)})]})]})]}),(0,_.jsxs)(`div`,{className:`grid gap-1.5`,children:[(0,_.jsx)(`label`,{className:`text-[12px] text-(--text-muted)`,children:B(`name`)}),(0,_.jsx)(Oq,{value:r,onChange:e=>i(e.target.value),disabled:!C,placeholder:`my-skill`,className:`h-8 text-[13px]`})]}),(0,_.jsxs)(`div`,{className:`grid gap-1.5`,children:[(0,_.jsx)(`label`,{className:`text-[12px] text-(--text-muted)`,children:B(`description`)}),(0,_.jsx)(Oq,{value:a,onChange:e=>o(e.target.value),placeholder:B(`skillDescriptionPlaceholder`),className:`h-8 text-[13px]`})]}),(0,_.jsxs)(`div`,{className:`rounded-md border border-(--border-default) bg-(--bg-secondary) p-3`,children:[(0,_.jsxs)(`div`,{className:`mb-2 flex items-center gap-2 text-[12px] font-medium text-(--text-primary)`,children:[(0,_.jsx)(tm,{size:13}),B(`skillRoutingSettings`)]}),(0,_.jsxs)(`div`,{className:`grid gap-3 sm:grid-cols-2`,children:[(0,_.jsxs)(`div`,{className:`grid gap-1.5`,children:[(0,_.jsx)(`label`,{className:`text-[12px] text-(--text-muted)`,children:B(`skillMode`)}),(0,_.jsxs)(kq,{value:l,onValueChange:u,children:[(0,_.jsx)(jq,{className:`h-8 w-full bg-(--bg-primary) text-[13px]`,children:(0,_.jsx)(Aq,{})}),(0,_.jsx)(Mq,{align:`start`,children:Wq.map(e=>(0,_.jsx)(Nq,{value:e,children:B(`skillMode_${e}`)},e))})]})]}),(0,_.jsxs)(`div`,{className:`grid gap-1.5`,children:[(0,_.jsx)(`label`,{className:`text-[12px] text-(--text-muted)`,children:B(`skillPriority`)}),(0,_.jsx)(Oq,{type:`number`,min:`0`,max:`100`,value:m,onChange:e=>h(e.target.value),className:`h-8 text-[13px]`})]}),(0,_.jsxs)(`div`,{className:`grid gap-1.5 sm:col-span-2`,children:[(0,_.jsx)(`label`,{className:`text-[12px] text-(--text-muted)`,children:B(`skillTriggers`)}),(0,_.jsx)(Oq,{value:f,onChange:e=>p(e.target.value),placeholder:`after_edit, before_final`,className:`h-8 text-[13px]`})]}),(0,_.jsxs)(`div`,{className:`flex items-center justify-between rounded-md border border-(--border-default) bg-(--bg-primary) px-2 py-1.5 sm:col-span-2`,children:[(0,_.jsx)(`span`,{className:`text-[12px] text-(--text-muted)`,children:B(g?`enabled`:`disabled`)}),(0,_.jsx)(Gq,{checked:g,onClick:()=>v(e=>!e),title:B(g?`disable`:`enable`)})]})]})]}),(0,_.jsxs)(`div`,{className:`grid gap-1.5`,children:[(0,_.jsx)(`label`,{className:`text-[12px] text-(--text-muted)`,children:B(`skillContent`)}),x?(0,_.jsxs)(`div`,{className:`rounded-md border border-(--border-default) py-8 text-center text-[12px] text-(--text-muted)`,children:[B(`loading`),`...`]}):(0,_.jsx)(bq,{value:y,onChange:e=>b(e.target.value),disabled:w,className:`min-h-[360px] resize-y text-[13px] font-mono leading-5`,placeholder:`---
349
- name: my-skill
350
- description: ...
351
- ---
352
-
353
- Skill instructions...`})]})]})]}),(0,_.jsxs)(`div`,{className:`mt-3 flex shrink-0 justify-end gap-2 border-t border-(--border-default) bg-(--bg-primary) pt-3`,children:[(0,_.jsx)(_m,{variant:`outline`,onClick:n,size:`sm`,children:B(`cancel`)}),(0,_.jsx)(_m,{onClick:async()=>{let n={description:a,scope:s,mode:l,triggers:f.split(`,`).map(e=>e.trim()).filter(Boolean),enabled:g,priority:Number(m)||0};C?(await Xd({name:r,description:a,content:y,scope:s}),await $d(r,n)):(await $d(e.name,n),w||await Qd(e.name,y)),t()},disabled:x||!w&&!y.trim()||C&&!r.trim(),size:`sm`,children:B(C?`create`:`save`)})]})]})}function Xq({skill:e,open:t,onSave:n,onOpenChange:r}){return(0,_.jsx)(vm,{open:t,onOpenChange:r,children:(0,_.jsxs)(xm,{className:`sm:max-w-[760px] h-[86vh] max-h-[86vh] flex flex-col overflow-hidden`,children:[(0,_.jsx)(Sm,{className:`shrink-0`,children:(0,_.jsx)(wm,{children:B(e?`editSkill`:`newSkill`)})}),(0,_.jsx)(Yq,{skill:e,onSave:n,onCancel:()=>r(!1)})]})})}function Zq({skill:e,open:t,onOpenChange:n}){let[r,i]=(0,d.useState)(``),[a,o]=(0,d.useState)(!1);return(0,d.useEffect)(()=>{!t||!e||(o(!0),Yd(e.name).then(e=>i(e.content||``)).catch(()=>{}).finally(()=>o(!1)))},[t,e]),(0,_.jsx)(vm,{open:t,onOpenChange:n,children:(0,_.jsxs)(xm,{className:`sm:max-w-[720px] max-h-[82vh] flex flex-col overflow-hidden`,children:[(0,_.jsx)(Sm,{className:`shrink-0`,children:(0,_.jsxs)(wm,{children:[e?.name,` `,B(`contentPreview`)]})}),(0,_.jsx)(`div`,{className:`flex-1 overflow-y-auto min-h-0 pr-1`,children:a?(0,_.jsxs)(`div`,{className:`py-8 text-center text-[12px] text-(--text-muted)`,children:[B(`loading`),`...`]}):(0,_.jsx)(`pre`,{className:`rounded-lg bg-(--bg-secondary) p-3 text-[13px] whitespace-pre-wrap break-words font-mono leading-5`,children:r})}),(0,_.jsx)(Cm,{className:`shrink-0`,children:(0,_.jsx)(_m,{variant:`outline`,onClick:()=>n(!1),size:`sm`,children:B(`close`)})})]})})}function Qq(){let[e,t]=(0,d.useState)([]),[n,r]=(0,d.useState)(!0),[i,a]=(0,d.useState)(null),[o,s]=(0,d.useState)(null),[c,l]=(0,d.useState)(``),[u,f]=(0,d.useState)(`all`),[p,m]=(0,d.useState)(``),[h,g]=(0,d.useState)(`project`),[v,y]=(0,d.useState)(!1),[b,x]=(0,d.useState)(``),S=(0,d.useCallback)(async()=>{r(!0);try{let e=await Jd();t(Array.isArray(e)?e:[])}catch{}r(!1)},[]);(0,d.useEffect)(()=>{S()},[S]);let C=async(e,t)=>{await tf(e,t),S()},w=async e=>{await ef(e),S()},T=()=>{a(null),S()},E=async()=>{let e=p.trim();if(e){y(!0),x(``);try{let t=await Zd({source:e,scope:h});if(t?.error)throw Error(t.message||`Install failed`);m(``),await S()}catch(e){x(e.message||`Install failed`)}finally{y(!1)}}};e.filter(Jq).length,e.filter(e=>!qq(e)).length;let D=(0,d.useMemo)(()=>{let t=c.trim().toLowerCase();return e.filter(e=>u===`enabled`&&!Jq(e)||u===`builtin`&&e.scope!==`builtin`||u===`custom`&&e.scope===`builtin`?!1:t?e.name.toLowerCase().includes(t):!0)},[e,c,u]);return n?(0,_.jsxs)(`div`,{className:`py-8 text-center text-[12px] text-(--text-muted)`,children:[B(`loading`),`...`]}):(0,_.jsxs)(`div`,{className:`space-y-3`,children:[(0,_.jsx)(`div`,{className:`rounded-lg border border-(--border-default) bg-(--bg-secondary) p-3`,children:(0,_.jsxs)(`div`,{className:`flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between`,children:[(0,_.jsxs)(`div`,{className:`min-w-0`,children:[(0,_.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,_.jsx)(Ep,{size:14,className:`text-(--text-muted)`}),(0,_.jsx)(`span`,{className:`text-[13px] font-medium text-(--text-primary)`,children:B(`skillLibrary`)})]}),(0,_.jsx)(`div`,{className:`mt-1 text-[11px] text-(--text-muted)`,children:B(`skillPanelHint`)})]}),(0,_.jsx)(`div`,{className:`flex flex-wrap items-center gap-2`,children:(0,_.jsxs)(_m,{onClick:()=>a(`new`),size:`sm`,children:[(0,_.jsx)(qp,{size:13}),B(`addSkill`)]})})]})}),(0,_.jsxs)(`div`,{className:`rounded-lg border border-(--border-default) bg-(--bg-secondary) p-3`,children:[(0,_.jsxs)(`div`,{className:`grid gap-2 sm:grid-cols-[1fr_auto_auto] sm:items-center`,children:[(0,_.jsx)(Oq,{value:p,onChange:e=>m(e.target.value),placeholder:B(`skillInstallPlaceholder`),className:`h-8 text-[13px]`}),(0,_.jsxs)(kq,{value:h,onValueChange:g,children:[(0,_.jsx)(jq,{className:`h-8 w-full bg-(--bg-primary) text-[13px] sm:w-[104px]`,children:(0,_.jsx)(Aq,{})}),(0,_.jsxs)(Mq,{align:`start`,children:[(0,_.jsx)(Nq,{value:`project`,children:B(`projectScope`)}),(0,_.jsx)(Nq,{value:`global`,children:B(`globalScope`)})]})]}),(0,_.jsxs)(_m,{onClick:E,disabled:v||!p.trim(),size:`sm`,children:[(0,_.jsx)(Sp,{size:13}),B(v?`installing`:`installSkill`)]})]}),b&&(0,_.jsx)(`div`,{className:`mt-2 text-[11px] text-(--accent-red)`,children:b})]}),(0,_.jsxs)(`div`,{className:`flex flex-col gap-2 sm:flex-row sm:items-center`,children:[(0,_.jsxs)(`div`,{className:`relative flex-1`,children:[(0,_.jsx)(Zp,{size:13,className:`pointer-events-none absolute left-2.5 top-1/2 -translate-y-1/2 text-(--text-muted)`}),(0,_.jsx)(Oq,{value:c,onChange:e=>l(e.target.value),placeholder:B(`searchSkills`),className:`h-8 pl-8 text-[13px]`})]}),(0,_.jsx)(`div`,{className:`flex shrink-0 rounded-md border border-(--border-default) p-0.5`,children:Uq.map(e=>(0,_.jsx)(_m,{type:`button`,variant:u===e?`secondary`:`ghost`,size:`xs`,onClick:()=>f(e),className:`px-2`,children:B(`filter_${e}`)},e))})]}),(0,_.jsx)(lm,{className:`bg-(--border-default)`}),e.length===0&&!i&&(0,_.jsxs)(`div`,{className:`rounded-lg border border-dashed border-(--border-default) py-8 text-center`,children:[(0,_.jsx)(`div`,{className:`text-[13px] text-(--text-primary)`,children:B(`noSkills`)}),(0,_.jsx)(`div`,{className:`mt-1 text-[11px] text-(--text-muted)`,children:B(`noSkillsHint`)})]}),e.length>0&&D.length===0&&(0,_.jsx)(`div`,{className:`py-8 text-center text-[12px] text-(--text-muted)`,children:B(`noMatches`)}),(0,_.jsx)(`div`,{className:`grid max-h-[420px] gap-2 overflow-y-auto pr-1`,children:D.map(e=>{let t=Jq(e);return(0,_.jsx)(`div`,{className:z(`rounded-lg border p-3 transition-colors`,t?`border-(--border-default) bg-(--bg-primary) hover:bg-(--bg-hover)`:`border-(--border-default) bg-(--bg-secondary) opacity-75`),children:(0,_.jsxs)(`div`,{className:`flex items-start justify-between gap-3`,children:[(0,_.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,_.jsxs)(`div`,{className:`flex flex-wrap items-center gap-1.5`,children:[(0,_.jsx)(`span`,{className:`truncate text-[13px] font-medium text-(--text-primary)`,children:e.name}),(0,_.jsx)(yq,{variant:qq(e)?`secondary`:`outline`,className:`h-4 rounded-md px-1.5 py-0 text-[10px]`,children:Kq(e.scope)}),(0,_.jsx)(yq,{variant:t?`outline`:`secondary`,className:`h-4 rounded-md px-1.5 py-0 text-[10px]`,children:B(t?`enabled`:`disabled`)}),e.version&&e.version!==`0.0.0`&&(0,_.jsxs)(`span`,{className:`text-[10px] text-(--text-muted)`,children:[`v`,e.version]}),e.mode&&(0,_.jsx)(yq,{variant:`outline`,className:`h-4 rounded-md px-1.5 py-0 text-[10px]`,children:B(`skillMode_${e.mode}`)})]}),(0,_.jsx)(`div`,{className:`mt-1 line-clamp-2 text-[11px] leading-4 text-(--text-muted)`,children:e.description||B(`noDescription`)}),e.triggers?.length>0&&(0,_.jsxs)(`div`,{className:`mt-1 truncate text-[10px] text-(--text-muted)`,children:[B(`skillTriggers`),`: `,e.triggers.join(`, `)]})]}),(0,_.jsxs)(`div`,{className:`flex shrink-0 items-center gap-1`,children:[(0,_.jsx)(_m,{variant:`ghost`,size:`icon-xs`,onClick:()=>s(e),title:B(`view`),children:(0,_.jsx)(Tp,{size:13})}),(0,_.jsx)(Gq,{checked:t,onClick:()=>C(e.name,!t),title:B(t?`disable`:`enable`)}),(0,_.jsx)(_m,{variant:`ghost`,size:`icon-xs`,onClick:()=>a(e),title:qq(e)?B(`skillRoutingSettings`):B(`edit`),children:qq(e)?(0,_.jsx)(tm,{size:13}):(0,_.jsx)(Kp,{size:13})}),!qq(e)&&(0,_.jsx)(_.Fragment,{children:(0,_.jsx)(_m,{variant:`ghost`,size:`icon-xs`,onClick:()=>{confirm(B(`confirmDeleteSkill`).replace(`{{name}}`,e.name))&&w(e.name)},title:B(`delete`),className:`text-(--accent-red) hover:text-(--accent-red)`,children:(0,_.jsx)(am,{size:13})})})]})]})},e.name)})}),(0,_.jsx)(Zq,{skill:o,open:!!o,onOpenChange:e=>{e||s(null)}}),(0,_.jsx)(Xq,{skill:i===`new`?null:i,open:!!i,onSave:T,onOpenChange:e=>{e||a(null)}})]})}function $q({open:e,onOpenChange:t}){return(0,_.jsx)(vm,{open:e,onOpenChange:t,children:(0,_.jsxs)(xm,{className:`sm:max-w-[800px] max-h-[86vh] overflow-hidden flex flex-col`,children:[(0,_.jsx)(Sm,{children:(0,_.jsx)(wm,{children:B(`skills`)})}),(0,_.jsx)(`div`,{className:`flex-1 overflow-y-auto min-h-0 pr-1`,children:(0,_.jsx)(Qq,{})})]})})}var eJ=[`all`,`builtin`,`custom`];function tJ({checked:e,onClick:t,title:n}){return(0,_.jsx)(`button`,{type:`button`,onClick:t,title:n,"aria-pressed":e,className:z(`relative h-5 w-9 rounded-full border shadow-inner transition-colors`,e?`border-(--text-primary) bg-(--text-primary)`:`border-(--border-strong) bg-(--bg-hover)`),children:(0,_.jsx)(`span`,{className:z(`absolute left-0.5 top-0.5 size-3.5 rounded-full transition-transform`,e?`bg-(--bg-primary)`:`bg-(--text-muted)`,e?`translate-x-4`:`translate-x-0`)})})}function nJ(e){return B(e===`builtin`?`builtin`:`custom`)}function rJ({soul:e,onSave:t,onCancel:n}){let[r,i]=(0,d.useState)(e?.name||``),[a,o]=(0,d.useState)(``),[s,c]=(0,d.useState)(!1),l=!e;return(0,d.useEffect)(()=>{if(i(e?.name||``),!e){o(``);return}c(!0),rf(e.name).then(e=>o(e.content||``)).catch(()=>{}).finally(()=>c(!1))},[e]),(0,_.jsxs)(`div`,{className:`space-y-3`,children:[(0,_.jsxs)(`div`,{className:`mb-3 flex items-start justify-between gap-3`,children:[(0,_.jsxs)(`div`,{children:[(0,_.jsx)(`div`,{className:`text-[13px] font-medium text-(--text-primary)`,children:B(l?`newSoul`:`editSoul`)}),(0,_.jsx)(`div`,{className:`mt-0.5 text-[11px] text-(--text-muted)`,children:B(`soulEditorHint`)})]}),(0,_.jsx)(yq,{variant:`outline`,className:`rounded-md px-1.5 py-0 text-[10px]`,children:l?B(`custom`):nJ(e.scope)})]}),(0,_.jsxs)(`div`,{className:`grid gap-3`,children:[(0,_.jsxs)(`div`,{className:`grid gap-1.5`,children:[(0,_.jsx)(`label`,{className:`text-[12px] text-(--text-muted)`,children:B(`name`)}),(0,_.jsx)(Oq,{value:r,onChange:e=>i(e.target.value),disabled:!l,placeholder:`my-soul`,className:`h-8 text-[13px]`})]}),(0,_.jsxs)(`div`,{className:`grid gap-1.5`,children:[(0,_.jsx)(`label`,{className:`text-[12px] text-(--text-muted)`,children:B(`soulContent`)}),s?(0,_.jsxs)(`div`,{className:`rounded-md border border-(--border-default) py-8 text-center text-[12px] text-(--text-muted)`,children:[B(`loading`),`...`]}):(0,_.jsx)(bq,{value:a,onChange:e=>o(e.target.value),className:`min-h-[220px] resize-y text-[13px] font-mono leading-5`,placeholder:B(`soulPlaceholder`)})]})]}),(0,_.jsxs)(`div`,{className:`mt-3 flex justify-end gap-2`,children:[(0,_.jsx)(_m,{variant:`outline`,onClick:n,size:`sm`,children:B(`cancel`)}),(0,_.jsx)(_m,{onClick:async()=>{l?await af({name:r,content:a}):await of(e.name,a),t()},disabled:s||!a.trim()||l&&!r.trim(),size:`sm`,children:B(l?`create`:`save`)})]})]})}function iJ({soul:e,open:t,onSave:n,onOpenChange:r}){return(0,_.jsx)(vm,{open:t,onOpenChange:r,children:(0,_.jsxs)(xm,{className:`sm:max-w-[720px] max-h-[86vh] flex flex-col overflow-hidden`,children:[(0,_.jsx)(Sm,{className:`shrink-0`,children:(0,_.jsx)(wm,{children:B(e?`editSoul`:`newSoul`)})}),(0,_.jsx)(`div`,{className:`flex-1 overflow-y-auto min-h-0 pr-1`,children:(0,_.jsx)(rJ,{soul:e,onSave:n,onCancel:()=>r(!1)})})]})})}function aJ({soul:e,open:t,onOpenChange:n}){let[r,i]=(0,d.useState)(``),[a,o]=(0,d.useState)(!1);return(0,d.useEffect)(()=>{!t||!e||(o(!0),rf(e.name).then(e=>i(e.content||``)).catch(()=>{}).finally(()=>o(!1)))},[t,e]),(0,_.jsx)(vm,{open:t,onOpenChange:n,children:(0,_.jsxs)(xm,{className:`sm:max-w-[680px] max-h-[82vh] flex flex-col overflow-hidden`,children:[(0,_.jsx)(Sm,{className:`shrink-0`,children:(0,_.jsxs)(wm,{children:[e?.name,` `,B(`contentPreview`)]})}),(0,_.jsx)(`div`,{className:`flex-1 overflow-y-auto min-h-0 pr-1`,children:a?(0,_.jsxs)(`div`,{className:`py-8 text-center text-[12px] text-(--text-muted)`,children:[B(`loading`),`...`]}):(0,_.jsx)(`pre`,{className:`rounded-lg bg-(--bg-secondary) p-3 text-[13px] whitespace-pre-wrap break-words font-mono leading-5`,children:r})}),(0,_.jsx)(Cm,{className:`shrink-0`,children:(0,_.jsx)(_m,{variant:`outline`,onClick:()=>n(!1),size:`sm`,children:B(`close`)})})]})})}function oJ(){let[e,t]=(0,d.useState)([]),[n,r]=(0,d.useState)(!0),[i,a]=(0,d.useState)(null),[o,s]=(0,d.useState)(null),[c,l]=(0,d.useState)(``),[u,f]=(0,d.useState)(`all`),p=(0,d.useCallback)(async()=>{r(!0);try{let e=await nf();t(Array.isArray(e)?e:[])}catch{}r(!1)},[]);(0,d.useEffect)(()=>{p()},[p]);let m=e.find(e=>e.active);e.filter(e=>e.scope!==`builtin`).length;let h=(0,d.useMemo)(()=>{let t=c.trim().toLowerCase();return e.filter(e=>u!==`all`&&e.scope!==u?!1:t?e.name.toLowerCase().includes(t):!0)},[e,c,u]),g=async e=>{await cf(e),p()},v=async e=>{await sf(e),p()};return n?(0,_.jsxs)(`div`,{className:`py-8 text-center text-[12px] text-(--text-muted)`,children:[B(`loading`),`...`]}):(0,_.jsxs)(`div`,{className:`space-y-3`,children:[(0,_.jsx)(`div`,{className:`rounded-lg border border-(--border-default) bg-(--bg-secondary) p-3`,children:(0,_.jsxs)(`div`,{className:`flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between`,children:[(0,_.jsxs)(`div`,{className:`min-w-0`,children:[(0,_.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,_.jsx)(Cp,{size:14,className:`text-(--text-muted)`}),(0,_.jsx)(`span`,{className:`text-[13px] font-medium text-(--text-primary)`,children:m?.name||B(`noActiveSoul`)}),m&&(0,_.jsx)(yq,{className:`h-4 rounded-md border-0 bg-(--text-primary) px-1.5 py-0 text-[10px] text-(--bg-primary)`,children:B(`current`)})]}),(0,_.jsx)(`div`,{className:`mt-1 text-[11px] text-(--text-muted)`,children:B(`soulPanelHint`)})]}),(0,_.jsx)(`div`,{className:`flex items-center gap-2`,children:(0,_.jsxs)(_m,{onClick:()=>a(`new`),size:`sm`,children:[(0,_.jsx)(qp,{size:13}),B(`addSoul`)]})})]})}),(0,_.jsxs)(`div`,{className:`flex flex-col gap-2 sm:flex-row sm:items-center`,children:[(0,_.jsxs)(`div`,{className:`relative flex-1`,children:[(0,_.jsx)(Zp,{size:13,className:`pointer-events-none absolute left-2.5 top-1/2 -translate-y-1/2 text-(--text-muted)`}),(0,_.jsx)(Oq,{value:c,onChange:e=>l(e.target.value),placeholder:B(`searchSouls`),className:`h-8 pl-8 text-[13px]`})]}),(0,_.jsx)(`div`,{className:`flex shrink-0 rounded-md border border-(--border-default) p-0.5`,children:eJ.map(e=>(0,_.jsx)(_m,{type:`button`,variant:u===e?`secondary`:`ghost`,size:`xs`,onClick:()=>f(e),className:`px-2`,children:B(`filter_${e}`)},e))})]}),(0,_.jsx)(lm,{className:`bg-(--border-default)`}),e.length===0&&!i&&(0,_.jsxs)(`div`,{className:`rounded-lg border border-dashed border-(--border-default) py-8 text-center`,children:[(0,_.jsx)(`div`,{className:`text-[13px] text-(--text-primary)`,children:B(`noSouls`)}),(0,_.jsx)(`div`,{className:`mt-1 text-[11px] text-(--text-muted)`,children:B(`noSoulsHint`)})]}),e.length>0&&h.length===0&&(0,_.jsx)(`div`,{className:`py-8 text-center text-[12px] text-(--text-muted)`,children:B(`noMatches`)}),(0,_.jsx)(`div`,{className:`grid max-h-[420px] gap-2 overflow-y-auto pr-1`,children:h.map(e=>(0,_.jsx)(`div`,{className:z(`rounded-lg border p-3 transition-colors`,e.active?`border-(--border-strong) bg-(--bg-active)`:`border-(--border-default) bg-(--bg-primary) hover:bg-(--bg-hover)`),children:(0,_.jsxs)(`div`,{className:`flex items-start justify-between gap-3`,children:[(0,_.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,_.jsxs)(`div`,{className:`flex flex-wrap items-center gap-1.5`,children:[(0,_.jsx)(`span`,{className:`truncate text-[13px] font-medium text-(--text-primary)`,children:e.name}),(0,_.jsx)(yq,{variant:`outline`,className:`h-4 rounded-md px-1.5 py-0 text-[10px]`,children:nJ(e.scope)}),e.active&&(0,_.jsx)(yq,{className:`h-4 rounded-md border-0 bg-(--text-primary) px-1.5 py-0 text-[10px] text-(--bg-primary)`,children:B(`current`)})]}),(0,_.jsx)(`div`,{className:`mt-1 line-clamp-2 text-[11px] leading-4 text-(--text-muted)`,children:e.preview||B(`noPreview`)})]}),(0,_.jsxs)(`div`,{className:`flex shrink-0 items-center gap-1`,children:[(0,_.jsx)(_m,{variant:`ghost`,size:`icon-xs`,onClick:()=>s(e),title:B(`view`),children:(0,_.jsx)(Tp,{size:13})}),(0,_.jsx)(tJ,{checked:!!e.active,onClick:()=>{e.active||g(e.name)},title:e.active?B(`current`):B(`activate`)}),e.scope!==`builtin`&&(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(_m,{variant:`ghost`,size:`icon-xs`,onClick:()=>a(e),title:B(`edit`),children:(0,_.jsx)(Kp,{size:13})}),(0,_.jsx)(_m,{variant:`ghost`,size:`icon-xs`,onClick:()=>{confirm(B(`confirmDeleteSoul`).replace(`{{name}}`,e.name))&&v(e.name)},title:B(`delete`),className:`text-(--accent-red) hover:text-(--accent-red)`,children:(0,_.jsx)(am,{size:13})})]})]})]})},`${e.scope}-${e.name}`))}),(0,_.jsx)(aJ,{soul:o,open:!!o,onOpenChange:e=>{e||s(null)}}),(0,_.jsx)(iJ,{soul:i===`new`?null:i,open:!!i,onSave:()=>{a(null),p()},onOpenChange:e=>{e||a(null)}})]})}function sJ({open:e,onOpenChange:t}){return(0,_.jsx)(vm,{open:e,onOpenChange:t,children:(0,_.jsxs)(xm,{className:`sm:max-w-[760px] max-h-[86vh] overflow-hidden flex flex-col`,children:[(0,_.jsx)(Sm,{children:(0,_.jsx)(wm,{children:B(`souls`)})}),(0,_.jsx)(`div`,{className:`flex-1 overflow-y-auto min-h-0 pr-1`,children:(0,_.jsx)(oJ,{})})]})})}var cJ=[{icon:om,title:`aboutFeatureRuntime`,text:`aboutFeatureRuntimeDesc`},{icon:_p,title:`aboutFeatureApprovals`,text:`aboutFeatureApprovalsDesc`},{icon:lp,title:`aboutFeatureMemory`,text:`aboutFeatureMemoryDesc`},{icon:$p,title:`aboutFeatureConfig`,text:`aboutFeatureConfigDesc`}];function lJ({open:e,onOpenChange:t,version:n}){return(0,_.jsx)(vm,{open:e,onOpenChange:t,children:(0,_.jsxs)(xm,{className:`sm:max-w-2xl max-h-[86vh] overflow-y-auto`,children:[(0,_.jsx)(Sm,{children:(0,_.jsx)(wm,{className:`sr-only`,children:B(`aboutTitle`)})}),(0,_.jsxs)(`div`,{className:`space-y-5`,children:[(0,_.jsxs)(`div`,{className:`flex items-start gap-4`,children:[(0,_.jsx)(`img`,{src:`/logos/codemini_logo.png`,alt:`Codemini`,className:`h-16 w-16 shrink-0 rounded-[14px] border border-(--border-default) bg-(--bg-secondary) p-2`}),(0,_.jsxs)(`div`,{className:`min-w-0`,children:[(0,_.jsx)(`h2`,{className:`mt-1 text-[24px] font-semibold leading-tight text-(--text-primary)`,children:`Codemini CLI`}),(0,_.jsx)(`p`,{className:`mt-2 max-w-xl text-[13px] leading-relaxed text-(--text-secondary)`,children:B(`aboutTagline`)})]})]}),(0,_.jsx)(`div`,{className:`grid grid-cols-1 gap-2.5 sm:grid-cols-2`,children:cJ.map(({icon:e,title:t,text:n})=>(0,_.jsxs)(`div`,{className:`rounded-md border border-(--border-default) bg-(--bg-secondary) px-3 py-3`,children:[(0,_.jsxs)(`div`,{className:`flex items-center gap-2 text-[13px] font-semibold text-(--text-primary)`,children:[(0,_.jsx)(e,{size:15}),(0,_.jsx)(`span`,{children:B(t)})]}),(0,_.jsx)(`p`,{className:`mt-1.5 text-[12px] leading-relaxed text-(--text-muted)`,children:B(n)})]},t))}),(0,_.jsx)(lm,{className:`bg-(--border-default)`}),(0,_.jsxs)(`div`,{className:`grid gap-3 sm:grid-cols-2`,children:[(0,_.jsxs)(`div`,{children:[(0,_.jsxs)(`h3`,{className:`mb-1.5 flex items-center gap-2 text-[13px] font-semibold text-(--text-primary)`,children:[(0,_.jsx)(im,{size:14}),B(`installation`)]}),(0,_.jsx)(`pre`,{className:`bg-(--bg-secondary) rounded-md border border-(--border-default) px-3 py-2 text-[12px] font-mono overflow-x-auto`,children:`npm install -g codemini-cli`})]}),(0,_.jsxs)(`div`,{children:[(0,_.jsxs)(`h3`,{className:`mb-1.5 flex items-center gap-2 text-[13px] font-semibold text-(--text-primary)`,children:[(0,_.jsx)(im,{size:14}),B(`startWebUI`)]}),(0,_.jsx)(`pre`,{className:`bg-(--bg-secondary) rounded-md border border-(--border-default) px-3 py-2 text-[12px] font-mono overflow-x-auto`,children:`codemini --web`})]})]}),(0,_.jsx)(lm,{className:`bg-(--border-default)`}),(0,_.jsxs)(`div`,{children:[(0,_.jsx)(`h3`,{className:`text-[13px] font-semibold text-(--text-primary) mb-2`,children:B(`basicUsage`)}),(0,_.jsxs)(`div`,{className:`grid gap-2 text-[12px] sm:grid-cols-2`,children:[(0,_.jsxs)(`div`,{className:`rounded-md bg-(--bg-secondary) px-3 py-2`,children:[(0,_.jsx)(`span`,{className:`font-medium text-(--text-primary)`,children:B(`newChat`)}),(0,_.jsx)(`p`,{className:`mt-1 text-(--text-muted)`,children:B(`chatUsage`)})]}),(0,_.jsxs)(`div`,{className:`rounded-md bg-(--bg-secondary) px-3 py-2`,children:[(0,_.jsx)(`span`,{className:`font-medium text-(--text-primary)`,children:B(`skills`)}),(0,_.jsx)(`p`,{className:`mt-1 text-(--text-muted)`,children:B(`skillUsage`)})]}),(0,_.jsxs)(`div`,{className:`rounded-md bg-(--bg-secondary) px-3 py-2`,children:[(0,_.jsx)(`span`,{className:`font-medium text-(--text-primary)`,children:B(`souls`)}),(0,_.jsx)(`p`,{className:`mt-1 text-(--text-muted)`,children:B(`soulUsage`)})]}),(0,_.jsxs)(`div`,{className:`rounded-md bg-(--bg-secondary) px-3 py-2`,children:[(0,_.jsx)(`span`,{className:`font-medium text-(--text-primary)`,children:B(`workspace`)}),(0,_.jsx)(`p`,{className:`mt-1 text-(--text-muted)`,children:B(`workspaceUsage`)})]})]})]}),(0,_.jsx)(lm,{className:`bg-(--border-default)`}),(0,_.jsxs)(`div`,{children:[(0,_.jsx)(`h3`,{className:`text-[13px] font-semibold text-(--text-primary) mb-1.5`,children:B(`configureModel`)}),(0,_.jsxs)(`pre`,{className:`bg-(--bg-secondary) rounded-md border border-(--border-default) px-3 py-2 text-[12px] font-mono overflow-x-auto`,children:[`codemini config set gateway.base_url <url>`,`
354
- `,`codemini config set gateway.api_key <token>`,`
355
- `,`codemini config set model.name <model-id>`]}),(0,_.jsx)(`p`,{className:`mt-1.5 text-[12px] text-(--text-muted)`,children:B(`configureModelDesc`)})]})]}),(0,_.jsxs)(`div`,{className:`text-center text-[11px] text-(--text-muted) pt-1`,children:[`Codemini CLI`,n?`@${n}`:``,` - Coding assistant An extremely restrained coding + tasks CLI. Every platform. Every terminal. Minimal by design.`]})]})})}var uJ={position:`absolute`,top:0,bottom:0,textAlign:`center`},dJ={display:`contents`};function fJ(){return null}var pJ=`diffs-container`,mJ=/(?=^From [a-f0-9]+ .+$)/m,hJ=/(?=^diff --git)/gm,gJ=/(?=^---\s+\S)/gm,_J=/(?=^@@ )/gm,vJ=/^@@ -(\d+)(?:,(\d+))? \+(\d+)(?:,(\d+))? @@(?: (.*))?/m,yJ=/(?<=\n)/,bJ=/^(---|\+\+\+)\s+([^\t\r\n]+)/,xJ=/^(---|\+\+\+)\s+[ab]\/([^\t\r\n]+)/,SJ=/^diff --git (?:"a\/(.+?)"|a\/(.+?)) (?:"b\/(.+?)"|b\/(.+?))$/,CJ=/^index ([0-9a-f]+)\.\.([0-9a-f]+)(?: (\d+))?$/i,wJ=`header-prefix`,TJ=`header-metadata`,EJ=`header-custom`,DJ={dark:`pierre-dark`,light:`pierre-light`},OJ=`data-theme-css`,kJ=`data-unsafe-css`,AJ={hunkLineCount:50,lineHeight:20,diffHeaderHeight:44,hunkSeparatorHeight:32,fileGap:8},jJ=Object.freeze({fromStart:0,fromEnd:0}),MJ={startingLine:0,totalLines:1/0,bufferBefore:0,bufferAfter:0},NJ={startingLine:0,totalLines:0,bufferBefore:0,bufferAfter:0};function PJ(e){return`annotation-${`side`in e?`${e.side}-`:``}${e.lineNumber}`}function FJ(e,t){return typeof window>`u`&&t!=null?(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(`template`,{shadowrootmode:`open`,dangerouslySetInnerHTML:{__html:t}}),e]}):(0,_.jsx)(_.Fragment,{children:e})}var IJ=(0,d.createContext)(void 0);function LJ(){return(0,d.useContext)(IJ)}var RJ=new Map,zJ=new Map,BJ=new Map,VJ=new Set;function HJ(e,t){e=Array.isArray(e)?e:[e];for(let n of e){let e;if(typeof n==`string`){if(e=RJ.get(n),e==null)throw Error(`loadResolvedThemes: ${n} is not resolved, you must resolve it before calling loadResolvedThemes`)}else e=n,n=n.name,RJ.has(n)||RJ.set(n,e);VJ.has(n)||(VJ.add(n),t.loadThemeSync(e))}}var UJ=new Map,WJ=new Map,GJ=new Map,KJ=new Set;function qJ(e,t){e=Array.isArray(e)?e:[e];for(let n of e){if(KJ.has(n.name))continue;let e=UJ.get(n.name);e??(e=n,UJ.set(n.name,e)),KJ.add(e.name),t.loadLanguageSync(e.data)}}function JJ(){return typeof WorkerGlobalScope<`u`&&typeof self<`u`&&self instanceof WorkerGlobalScope}var YJ=class extends Error{constructor(e){super(e),this.name=`ShikiError`}};function XJ(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 ZJ(e,t){return e&&(t?.[e?.toLowerCase()]||e)}function QJ(e){return Array.isArray(e)?e:[e]}async function $J(e){return Promise.resolve(typeof e==`function`?e():e).then(e=>e.default||e)}function eY(e){return!e||[`plaintext`,`txt`,`text`,`plain`].includes(e)}function tY(e){return e===`ansi`||eY(e)}function nY(e){return e===`none`}function rY(e){return nY(e)}function iY(e,t){if(!t)return e;e.properties||={},e.properties.class||=[],typeof e.properties.class==`string`&&(e.properties.class=e.properties.class.split(/\s+/g)),Array.isArray(e.properties.class)||(e.properties.class=[]);let n=Array.isArray(t)?t:t.split(/\s+/g);for(let t of n)t&&!e.properties.class.includes(t)&&e.properties.class.push(t);return e}function aY(e,t=!1){if(e.length===0)return[[``,0]];let n=e.split(/(\r?\n)/g),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}function oY(e){let t=aY(e,!0).map(([e])=>e);function n(n){if(n===e.length)return{line:t.length-1,character:t[t.length-1].length};let r=n,i=0;for(let e of t){if(r<e.length)break;r-=e.length,i++}return{line:i,character:r}}function r(e,n){let r=0;for(let n=0;n<e;n++)r+=t[n].length;return r+=n,r}return{lines:t,indexToPos:n,posToIndex:r}}function sY(e,t,n){let r=new Set;for(let t of e.matchAll(/:?lang=["']([^"']+)["']/g)){let e=t[1].toLowerCase().trim();e&&r.add(e)}for(let t of e.matchAll(/(?:```|~~~)([\w-]+)/g)){let e=t[1].toLowerCase().trim();e&&r.add(e)}for(let t of e.matchAll(/\\begin\{([\w-]+)\}/g)){let e=t[1].toLowerCase().trim();e&&r.add(e)}for(let t of e.matchAll(/<script\s+(?:type|lang)=["']([^"']+)["']/gi)){let e=t[1].toLowerCase().trim(),n=e.includes(`/`)?e.split(`/`).pop():e;n&&r.add(n)}if(!n)return Array.from(r);let i=n.getBundledLanguages();return Array.from(r).filter(e=>e&&i[e])}var cY=`light-dark()`,lY=[`color`,`background-color`];function uY(e,t){let n=0,r=[];for(let i of t)i>n&&r.push({...e,content:e.content.slice(n,i),offset:e.offset+n}),n=i;return n<e.content.length&&r.push({...e,content:e.content.slice(n),offset:e.offset+n}),r}function dY(e,t){let n=Array.from(t instanceof Set?t:new Set(t)).sort((e,t)=>e-t);return n.length?e.map(e=>e.flatMap(e=>{let t=n.filter(t=>e.offset<t&&t<e.offset+e.content.length).map(t=>t-e.offset).sort((e,t)=>e-t);return t.length?uY(e,t):e})):e}function fY(e,t,n,r,i=`css-vars`){let a={content:e.content,explanation:e.explanation,offset:e.offset},o=t.map(t=>pY(e.variants[t])),s=new Set(o.flatMap(e=>Object.keys(e))),c={},l=(e,r)=>{let i=r===`color`?``:r===`background-color`?`-bg`:`-${r}`;return n+t[e]+(r===`color`?``:i)};return o.forEach((e,n)=>{for(let a of s){let s=e[a]||`inherit`;if(n===0&&r&&lY.includes(a))if(r===cY&&o.length>1){let e=t.findIndex(e=>e===`light`),r=t.findIndex(e=>e===`dark`);if(e===-1||r===-1)throw new YJ('When using `defaultColor: "light-dark()"`, you must provide both `light` and `dark` themes');c[a]=`light-dark(${o[e][a]||`inherit`}, ${o[r][a]||`inherit`})`,i===`css-vars`&&(c[l(n,a)]=s)}else c[a]=s;else i===`css-vars`&&(c[l(n,a)]=s)}}),a.htmlStyle=c,a}function pY(e){let t={};if(e.color&&(t.color=e.color),e.bgColor&&(t[`background-color`]=e.bgColor),e.fontStyle){e.fontStyle&VL.Italic&&(t[`font-style`]=`italic`),e.fontStyle&VL.Bold&&(t[`font-weight`]=`bold`);let n=[];e.fontStyle&VL.Underline&&n.push(`underline`),e.fontStyle&VL.Strikethrough&&n.push(`line-through`),n.length&&(t[`text-decoration`]=n.join(` `))}return t}function mY(e){return typeof e==`string`?e:Object.entries(e).map(([e,t])=>`${e}:${t}`).join(`;`)}var hY=new WeakMap;function gY(e,t){hY.set(e,t)}function _Y(e){return hY.get(e)}var vY=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(QJ(n).map(e=>[e,rz])),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 yY(this._stacks[e])}toJSON(){return{lang:this.lang,theme:this.theme,themes:this.themes,scopes:this.getScopes()}}};function yY(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 bY(e,t){if(!(e instanceof vY))throw new YJ(`Invalid grammar state`);return e.getInternalStack(t)}function xY(){let e=new WeakMap;function t(t){if(!e.has(t.meta)){let n=function(e){if(typeof e==`number`){if(e<0||e>t.source.length)throw new YJ(`Invalid decoration offset: ${e}. Code length: ${t.source.length}`);return{...r.indexToPos(e),offset:e}}else{let t=r.lines[e.line];if(t===void 0)throw new YJ(`Invalid decoration position ${JSON.stringify(e)}. Lines length: ${r.lines.length}`);let n=e.character;if(n<0&&(n=t.length+n),n<0||n>t.length)throw new YJ(`Invalid decoration position ${JSON.stringify(e)}. Line ${e.line} length: ${t.length}`);return{...e,character:n,offset:r.posToIndex(e.line,n)}}},r=oY(t.source),i=(t.options.decorations||[]).map(e=>({...e,start:n(e.start),end:n(e.end)}));SY(i),e.set(t.meta,{decorations:i,converter:r,source:t.source})}return e.get(t.meta)}return{name:`shiki:decorations`,tokens(e){if(this.options.decorations?.length)return dY(e,t(this).decorations.flatMap(e=>[e.start.offset,e.end.offset]))},code(e){if(!this.options.decorations?.length)return;let n=t(this),r=Array.from(e.children).filter(e=>e.type===`element`&&e.tagName===`span`);if(r.length!==n.converter.lines.length)throw new YJ(`Number of lines in code element (${r.length}) does not match the number of lines in the source (${n.converter.lines.length}). Failed to apply decorations.`);function i(e,t,n,i){let a=r[e],s=``,c=-1,l=-1;if(t===0&&(c=0),n===0&&(l=0),n===1/0&&(l=a.children.length),c===-1||l===-1)for(let e=0;e<a.children.length;e++)s+=CY(a.children[e]),c===-1&&s.length===t&&(c=e+1),l===-1&&s.length===n&&(l=e+1);if(c===-1)throw new YJ(`Failed to find start index for decoration ${JSON.stringify(i.start)}`);if(l===-1)throw new YJ(`Failed to find end index for decoration ${JSON.stringify(i.end)}`);let u=a.children.slice(c,l);if(!i.alwaysWrap&&u.length===a.children.length)o(a,i,`line`);else if(!i.alwaysWrap&&u.length===1&&u[0].type===`element`)o(u[0],i,`token`);else{let e={type:`element`,tagName:`span`,properties:{},children:u};o(e,i,`wrapper`),a.children.splice(c,u.length,e)}}function a(e,t){r[e]=o(r[e],t,`line`)}function o(e,t,n){let r=t.properties||{},i=t.transform||(e=>e);return e.tagName=t.tagName||`span`,e.properties={...e.properties,...r,class:e.properties.class},t.properties?.class&&iY(e,t.properties.class),e=i(e,n)||e,e}let s=[],c=n.decorations.sort((e,t)=>t.start.offset-e.start.offset||e.end.offset-t.end.offset);for(let e of c){let{start:t,end:n}=e;if(t.line===n.line)i(t.line,t.character,n.character,e);else if(t.line<n.line){i(t.line,t.character,1/0,e);for(let r=t.line+1;r<n.line;r++)s.unshift(()=>a(r,e));i(n.line,0,n.character,e)}}s.forEach(e=>e())}}}function SY(e){for(let t=0;t<e.length;t++){let n=e[t];if(n.start.offset>n.end.offset)throw new YJ(`Invalid decoration range: ${JSON.stringify(n.start)} - ${JSON.stringify(n.end)}`);for(let r=t+1;r<e.length;r++){let t=e[r],i=n.start.offset<=t.start.offset&&t.start.offset<n.end.offset,a=n.start.offset<t.end.offset&&t.end.offset<=n.end.offset,o=t.start.offset<=n.start.offset&&n.start.offset<t.end.offset,s=t.start.offset<n.end.offset&&n.end.offset<=t.end.offset;if(i||a||o||s){if(i&&a||o&&s||o&&n.start.offset===n.end.offset||a&&t.start.offset===t.end.offset)continue;throw new YJ(`Decorations ${JSON.stringify(n.start)} and ${JSON.stringify(t.start)} intersect.`)}}}}function CY(e){return e.type===`text`?e.value:e.type===`element`?e.children.map(CY).join(``):``}var wY=[xY()];function TY(e){let t=EY(e.transformers||[]);return[...t.pre,...t.normal,...t.post,...wY]}function EY(e){let t=[],n=[],r=[];for(let i of e)switch(i.enforce){case`pre`:t.push(i);break;case`post`:n.push(i);break;default:r.push(i)}return{pre:t,post:n,normal:r}}var DY=[`black`,`red`,`green`,`yellow`,`blue`,`magenta`,`cyan`,`white`,`brightBlack`,`brightRed`,`brightGreen`,`brightYellow`,`brightBlue`,`brightMagenta`,`brightCyan`,`brightWhite`],OY={1:`bold`,2:`dim`,3:`italic`,4:`underline`,7:`reverse`,8:`hidden`,9:`strikethrough`};function kY(e,t){let n=e.indexOf(`\x1B`,t);if(n!==-1&&e[n+1]===`[`){let t=e.indexOf(`m`,n);if(t!==-1)return{sequence:e.substring(n+2,t).split(`;`),startPosition:n,position:t+1}}return{position:e.length}}function AY(e){let t=e.shift();if(t===`2`){let t=e.splice(0,3).map(e=>Number.parseInt(e));return t.length!==3||t.some(e=>Number.isNaN(e))?void 0:{type:`rgb`,rgb:t}}else if(t===`5`){let t=e.shift();if(t)return{type:`table`,index:Number(t)}}}function jY(e){let t=[];for(;e.length>0;){let n=e.shift();if(!n)continue;let r=Number.parseInt(n);if(!Number.isNaN(r))if(r===0)t.push({type:`resetAll`});else if(r<=9)OY[r]&&t.push({type:`setDecoration`,value:OY[r]});else if(r<=29){let e=OY[r-20];e&&(t.push({type:`resetDecoration`,value:e}),e===`dim`&&t.push({type:`resetDecoration`,value:`bold`}))}else if(r<=37)t.push({type:`setForegroundColor`,value:{type:`named`,name:DY[r-30]}});else if(r===38){let n=AY(e);n&&t.push({type:`setForegroundColor`,value:n})}else if(r===39)t.push({type:`resetForegroundColor`});else if(r<=47)t.push({type:`setBackgroundColor`,value:{type:`named`,name:DY[r-40]}});else if(r===48){let n=AY(e);n&&t.push({type:`setBackgroundColor`,value:n})}else r===49?t.push({type:`resetBackgroundColor`}):r===53?t.push({type:`setDecoration`,value:`overline`}):r===55?t.push({type:`resetDecoration`,value:`overline`}):r>=90&&r<=97?t.push({type:`setForegroundColor`,value:{type:`named`,name:DY[r-90+8]}}):r>=100&&r<=107&&t.push({type:`setBackgroundColor`,value:{type:`named`,name:DY[r-100+8]}})}return t}function MY(){let e=null,t=null,n=new Set;return{parse(r){let i=[],a=0;do{let o=kY(r,a),s=o.sequence?r.substring(a,o.startPosition):r.substring(a);if(s.length>0&&i.push({value:s,foreground:e,background:t,decorations:new Set(n)}),o.sequence){let r=jY(o.sequence);for(let i of r)i.type===`resetAll`?(e=null,t=null,n.clear()):i.type===`resetForegroundColor`?e=null:i.type===`resetBackgroundColor`?t=null:i.type===`resetDecoration`&&n.delete(i.value);for(let i of r)i.type===`setForegroundColor`?e=i.value:i.type===`setBackgroundColor`?t=i.value:i.type===`setDecoration`&&n.add(i.value)}a=o.position}while(a<r.length);return i}}}var NY={black:`#000000`,red:`#bb0000`,green:`#00bb00`,yellow:`#bbbb00`,blue:`#0000bb`,magenta:`#ff00ff`,cyan:`#00bbbb`,white:`#eeeeee`,brightBlack:`#555555`,brightRed:`#ff5555`,brightGreen:`#00ff00`,brightYellow:`#ffff55`,brightBlue:`#5555ff`,brightMagenta:`#ff55ff`,brightCyan:`#55ffff`,brightWhite:`#ffffff`};function PY(e=NY){function t(t){return e[t]}function n(e){return`#${e.map(e=>Math.max(0,Math.min(e,255)).toString(16).padStart(2,`0`)).join(``)}`}let r;function i(){if(r)return r;r=[];for(let e=0;e<DY.length;e++)r.push(t(DY[e]));let e=[0,95,135,175,215,255];for(let t=0;t<6;t++)for(let i=0;i<6;i++)for(let a=0;a<6;a++)r.push(n([e[t],e[i],e[a]]));let i=8;for(let e=0;e<24;e++,i+=10)r.push(n([i,i,i]));return r}function a(e){return i()[e]}function o(e){switch(e.type){case`named`:return t(e.name);case`rgb`:return n(e.rgb);case`table`:return a(e.index)}}return{value:o}}var FY={black:`#000000`,red:`#cd3131`,green:`#0DBC79`,yellow:`#E5E510`,blue:`#2472C8`,magenta:`#BC3FBC`,cyan:`#11A8CD`,white:`#E5E5E5`,brightBlack:`#666666`,brightRed:`#F14C4C`,brightGreen:`#23D18B`,brightYellow:`#F5F543`,brightBlue:`#3B8EEA`,brightMagenta:`#D670D6`,brightCyan:`#29B8DB`,brightWhite:`#FFFFFF`};function IY(e,t,n){let r=XJ(e,n),i=aY(t),a=PY(Object.fromEntries(DY.map(t=>{let n=`terminal.ansi${t[0].toUpperCase()}${t.substring(1)}`;return[t,e.colors?.[n]||FY[t]]}))),o=MY();return i.map(t=>o.parse(t[0]).map(n=>{let i,o;n.decorations.has(`reverse`)?(i=n.background?a.value(n.background):e.bg,o=n.foreground?a.value(n.foreground):e.fg):(i=n.foreground?a.value(n.foreground):e.fg,o=n.background?a.value(n.background):void 0),i=ZJ(i,r),o=ZJ(o,r),n.decorations.has(`dim`)&&(i=LY(i));let s=VL.None;return n.decorations.has(`bold`)&&(s|=VL.Bold),n.decorations.has(`italic`)&&(s|=VL.Italic),n.decorations.has(`underline`)&&(s|=VL.Underline),n.decorations.has(`strikethrough`)&&(s|=VL.Strikethrough),{content:n.value,offset:t[1],color:i,bgColor:o,fontStyle:s}}))}function LY(e){let t=e.match(/#([0-9a-f]{3,8})/i);if(t){let e=t[1];if(e.length===8){let t=Math.round(Number.parseInt(e.slice(6,8),16)/2).toString(16).padStart(2,`0`);return`#${e.slice(0,6)}${t}`}else if(e.length===6)return`#${e}80`;else if(e.length===4){let t=e[0],n=e[1],r=e[2],i=e[3];return`#${t}${t}${n}${n}${r}${r}${Math.round(Number.parseInt(`${i}${i}`,16)/2).toString(16).padStart(2,`0`)}`}else if(e.length===3){let t=e[0],n=e[1],r=e[2];return`#${t}${t}${n}${n}${r}${r}80`}}let n=e.match(/var\((--[\w-]+-ansi-[\w-]+)\)/);return n?`var(${n[1]}-dim)`:e}function RY(e,t,n={}){let{theme:r=e.getLoadedThemes()[0]}=n,i=e.resolveLangAlias(n.lang||`text`);if(eY(i)||nY(r))return aY(t).map(e=>[{content:e[0],offset:e[1]}]);let{theme:a,colorMap:o}=e.setTheme(r);if(i===`ansi`)return IY(a,t,n);let s=e.getLanguage(n.lang||`text`);if(n.grammarState){if(n.grammarState.lang!==s.name)throw new YJ(`Grammar state language "${n.grammarState.lang}" does not match highlight language "${s.name}"`);if(!n.grammarState.themes.includes(a.name))throw new YJ(`Grammar state themes "${n.grammarState.themes}" do not contain highlight theme "${a.name}"`)}return BY(t,s,a,o,n)}function zY(...e){if(e.length===2)return _Y(e[1]);let[t,n,r={}]=e,{lang:i=`text`,theme:a=t.getLoadedThemes()[0]}=r;if(eY(i)||nY(a))throw new YJ(`Plain language does not have grammar state`);if(i===`ansi`)throw new YJ(`ANSI language does not have grammar state`);let{theme:o,colorMap:s}=t.setTheme(a),c=t.getLanguage(i);return new vY(VY(n,c,o,s,r).stateStack,c.name,o.name)}function BY(e,t,n,r,i){let a=VY(e,t,n,r,i),o=new vY(a.stateStack,t.name,n.name);return gY(a.tokens,o),a.tokens}function VY(e,t,n,r,i){let a=XJ(n,i),{tokenizeMaxLineLength:o=0,tokenizeTimeLimit:s=500}=i,c=aY(e),l=i.grammarState?bY(i.grammarState,n.name)??rz:i.grammarContextCode==null?rz:VY(i.grammarContextCode,t,n,r,{...i,grammarState:void 0,grammarContextCode:void 0}).stateStack,u=[],d=[];for(let e=0,f=c.length;e<f;e++){let[f,p]=c[e];if(f===``){u=[],d.push([]);continue}if(o>0&&f.length>=o){u=[],d.push([{content:f,offset:p,color:``,fontStyle:0}]);continue}let m,h,g;i.includeExplanation&&(m=t.tokenizeLine(f,l,s),h=m.tokens,g=0);let _=t.tokenizeLine2(f,l,s),v=_.tokens.length/2;for(let e=0;e<v;e++){let t=_.tokens[2*e],o=e+1<v?_.tokens[2*e+2]:f.length;if(t===o)continue;let s=_.tokens[2*e+1],c=ZJ(r[qL.getForeground(s)],a),l=qL.getFontStyle(s),d={content:f.substring(t,o),offset:p+t,color:c,fontStyle:l};if(i.includeExplanation){let e=[];if(i.includeExplanation!==`scopeName`)for(let t of n.settings){let n;switch(typeof t.scope){case`string`:n=t.scope.split(/,/).map(e=>e.trim());break;case`object`:n=t.scope;break;default:continue}e.push({settings:t,selectors:n.map(e=>e.split(/ /))})}d.explanation=[];let r=0;for(;t+r<o;){let t=h[g],n=f.substring(t.startIndex,t.endIndex);r+=n.length,d.explanation.push({content:n,scopes:i.includeExplanation===`scopeName`?HY(t.scopes):UY(e,t.scopes)}),g+=1}}u.push(d)}d.push(u),u=[],l=_.ruleStack}return{tokens:d,stateStack:l}}function HY(e){return e.map(e=>({scopeName:e}))}function UY(e,t){let n=[];for(let r=0,i=t.length;r<i;r++){let i=t[r];n[r]={scopeName:i,themeMatches:KY(e,i,t.slice(0,r))}}return n}function WY(e,t){return e===t||t.substring(0,e.length)===e&&t[e.length]===`.`}function GY(e,t,n){if(!WY(e[e.length-1],t))return!1;let r=e.length-2,i=n.length-1;for(;r>=0&&i>=0;)WY(e[r],n[i])&&--r,--i;return r===-1}function KY(e,t,n){let r=[];for(let{selectors:i,settings:a}of e)for(let e of i)if(GY(e,t,n)){r.push(a);break}return r}function qY(e,t,n){let r=Object.entries(n.themes).filter(e=>e[1]).map(e=>({color:e[0],theme:e[1]})),i=r.map(r=>{let i=RY(e,t,{...n,theme:r.theme});return{tokens:i,state:_Y(i),theme:typeof r.theme==`string`?r.theme:r.theme.name}}),a=JY(...i.map(e=>e.tokens)),o=a[0].map((e,t)=>e.map((e,i)=>{let o={content:e.content,variants:{},offset:e.offset};return`includeExplanation`in n&&n.includeExplanation&&(o.explanation=e.explanation),a.forEach((e,n)=>{let{content:a,explanation:s,offset:c,...l}=e[t][i];o.variants[r[n].color]=l}),o})),s=i[0].state?new vY(Object.fromEntries(i.map(e=>[e.theme,e.state?.getInternalStack(e.theme)])),i[0].state.lang):void 0;return s&&gY(o,s),o}function JY(...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}function YY(e,t,n){let r,i,a,o,s,c;if(`themes`in n){let{defaultColor:l=`light`,cssVariablePrefix:u=`--shiki-`,colorsRendering:d=`css-vars`}=n,f=Object.entries(n.themes).filter(e=>e[1]).map(e=>({color:e[0],theme:e[1]})).sort((e,t)=>e.color===l?-1:+(t.color===l));if(f.length===0)throw new YJ("`themes` option must not be empty");let p=qY(e,t,n);if(c=_Y(p),l&&cY!==l&&!f.find(e=>e.color===l))throw new YJ(`\`themes\` option must contain the defaultColor key \`${l}\``);let m=f.map(t=>e.getTheme(t.theme)),h=f.map(e=>e.color);a=p.map(e=>e.map(e=>fY(e,h,u,l,d))),c&&gY(a,c);let g=f.map(e=>XJ(e.theme,n));i=XY(f,m,g,u,l,`fg`,d),r=XY(f,m,g,u,l,`bg`,d),o=`shiki-themes ${m.map(e=>e.name).join(` `)}`,s=l?void 0:[i,r].join(`;`)}else if(`theme`in n){let s=XJ(n.theme,n);a=RY(e,t,n);let l=e.getTheme(n.theme);r=ZJ(l.bg,s),i=ZJ(l.fg,s),o=l.name,c=_Y(a)}else throw new YJ("Invalid options, either `theme` or `themes` must be provided");return{tokens:a,fg:i,bg:r,themeName:o,rootStyle:s,grammarState:c}}function XY(e,t,n,r,i,a,o){return e.map((s,c)=>{let l=ZJ(t[c][a],n[c])||`inherit`,u=`${r+s.color}${a===`bg`?`-bg`:``}:${l}`;if(c===0&&i){if(i===cY&&e.length>1){let r=e.findIndex(e=>e.color===`light`),i=e.findIndex(e=>e.color===`dark`);if(r===-1||i===-1)throw new YJ('When using `defaultColor: "light-dark()"`, you must provide both `light` and `dark` themes');return`light-dark(${ZJ(t[r][a],n[r])||`inherit`}, ${ZJ(t[i][a],n[i])||`inherit`});${u}`}return l}return o===`css-vars`?u:null}).filter(e=>!!e).join(`;`)}function ZY(e,t,n,r={meta:{},options:n,codeToHast:(t,n)=>ZY(e,t,n),codeToTokens:(t,n)=>YY(e,t,n)}){let i=t;for(let e of TY(n))i=e.preprocess?.call(r,i,n)||i;let{tokens:a,fg:o,bg:s,themeName:c,rootStyle:l,grammarState:u}=YY(e,i,n),{mergeWhitespaces:d=!0,mergeSameStyleTokens:f=!1}=n;d===!0?a=$Y(a):d===`never`&&(a=eX(a)),f&&(a=tX(a));let p={...r,get source(){return i}};for(let e of TY(n))a=e.tokens?.call(p,a)||a;return QY(a,{...n,fg:o,bg:s,themeName:c,rootStyle:n.rootStyle===!1?!1:n.rootStyle??l},p,u)}function QY(e,t,n,r=_Y(e)){let i=TY(t),a=[],o={type:`root`,children:[]},{structure:s=`classic`,tabindex:c=`0`}=t,l={class:`shiki ${t.themeName||``}`};t.rootStyle!==!1&&(t.rootStyle==null?l.style=`background-color:${t.bg};color:${t.fg}`:l.style=t.rootStyle),c!==!1&&c!=null&&(l.tabindex=c.toString());for(let[e,n]of Object.entries(t.meta||{}))e.startsWith(`_`)||(l[e]=n);let u={type:`element`,tagName:`pre`,properties:l,children:[],data:t.data},d={type:`element`,tagName:`code`,properties:{},children:a},f=[],p={...n,structure:s,addClassToHast:iY,get source(){return n.source},get tokens(){return e},get options(){return t},get root(){return o},get pre(){return u},get code(){return d},get lines(){return f}};if(e.forEach((e,t)=>{t&&(s===`inline`?o.children.push({type:`element`,tagName:`br`,properties:{},children:[]}):s===`classic`&&a.push({type:`text`,value:`
356
- `}));let n={type:`element`,tagName:`span`,properties:{class:`line`},children:[]},r=0;for(let a of e){let e={type:`element`,tagName:`span`,properties:{...a.htmlAttrs},children:[{type:`text`,value:a.content}]},c=mY(a.htmlStyle||pY(a));c&&(e.properties.style=c);for(let o of i)e=o?.span?.call(p,e,t+1,r,n,a)||e;s===`inline`?o.children.push(e):s===`classic`&&n.children.push(e),r+=a.content.length}if(s===`classic`){for(let e of i)n=e?.line?.call(p,n,t+1)||n;f.push(n),a.push(n)}else s===`inline`&&f.push(n)}),s===`classic`){for(let e of i)d=e?.code?.call(p,d)||d;u.children.push(d);for(let e of i)u=e?.pre?.call(p,u)||u;o.children.push(u)}else if(s===`inline`){let e=[],t={type:`element`,tagName:`span`,properties:{class:`line`},children:[]};for(let n of o.children)n.type===`element`&&n.tagName===`br`?(e.push(t),t={type:`element`,tagName:`span`,properties:{class:`line`},children:[]}):(n.type===`element`||n.type===`text`)&&t.children.push(n);e.push(t);let n={type:`element`,tagName:`code`,properties:{},children:e};for(let e of i)n=e?.code?.call(p,n)||n;o.children=[];for(let e=0;e<n.children.length;e++){e>0&&o.children.push({type:`element`,tagName:`br`,properties:{},children:[]});let t=n.children[e];t.type===`element`&&o.children.push(...t.children)}}let m=o;for(let e of i)m=e?.root?.call(p,m)||m;return r&&gY(m,r),m}function $Y(e){return e.map(e=>{let t=[],n=``,r;return e.forEach((i,a)=>{let o=!(i.fontStyle&&(i.fontStyle&VL.Underline||i.fontStyle&VL.Strikethrough));o&&i.content.match(/^\s+$/)&&e[a+1]?(r===void 0&&(r=i.offset),n+=i.content):n?(o?t.push({...i,offset:r,content:n+i.content}):t.push({content:n,offset:r},i),r=void 0,n=``):t.push(i)}),t})}function eX(e){return e.map(e=>e.flatMap(e=>{if(e.content.match(/^\s+$/))return e;let t=e.content.match(/^(\s*)(.*?)(\s*)$/);if(!t)return e;let[,n,r,i]=t;if(!n&&!i)return e;let a=[{...e,offset:e.offset+n.length,content:r}];return n&&a.unshift({content:n,offset:e.offset}),i&&a.push({content:i,offset:e.offset+n.length+r.length}),a}))}function tX(e){return e.map(e=>{let t=[];for(let n of e){if(t.length===0){t.push({...n});continue}let e=t[t.length-1],r=mY(e.htmlStyle||pY(e)),i=mY(n.htmlStyle||pY(n)),a=e.fontStyle&&(e.fontStyle&VL.Underline||e.fontStyle&VL.Strikethrough),o=n.fontStyle&&(n.fontStyle&VL.Underline||n.fontStyle&VL.Strikethrough);!a&&!o&&r===i?e.content+=n.content:t.push({...n})}return t})}var nX=rV;function rX(e,t,n){let r={meta:{},options:n,codeToHast:(t,n)=>ZY(e,t,n),codeToTokens:(t,n)=>YY(e,t,n)},i=nX(ZY(e,t,n,r));for(let e of TY(n))i=e.postprocess?.call(r,i,n)||i;return i}var iX={light:`#333333`,dark:`#bbbbbb`},aX={light:`#fffffe`,dark:`#1e1e1e`},oX=`__shiki_resolved`;function sX(e){if(e?.[oX])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`?iX.light:iX.dark,n||=t.type===`light`?aX.light:aX.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,oX,{enumerable:!1,writable:!1,value:!0}),t}async function cX(e){return Array.from(new Set((await Promise.all(e.filter(e=>!tY(e)).map(async e=>await $J(e).then(e=>Array.isArray(e)?e:[e])))).flat()))}async function lX(e){return(await Promise.all(e.map(async e=>rY(e)?null:sX(await $J(e))))).filter(e=>!!e)}var uX=3,dX=!1;function fX(e,t=3){if(uX&&!(typeof uX==`number`&&t>uX)){if(dX)throw Error(`[SHIKI DEPRECATE]: ${e}`);console.trace(`[SHIKI DEPRECATE]: ${e}`)}}var pX=class extends Error{constructor(e){super(e),this.name=`ShikiError`}};function mX(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 pX(`Circular alias \`${Array.from(n).join(` -> `)} -> ${e}\``);n.add(e)}}return e}var hX=class extends nz{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)}_resolvedThemes=new Map;_resolvedGrammars=new Map;_langMap=new Map;_langGraph=new Map;_textmateThemeCache=new WeakMap;_loadedThemesCache=null;_loadedLanguagesCache=null;getTheme(e){return typeof e==`string`?this._resolvedThemes.get(e):this.loadTheme(e)}loadTheme(e){let t=sX(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=PL.createFromRawTheme(e),this._textmateThemeCache.set(e,t)),this._syncRegistry.setTheme(t)}getGrammar(e){return e=mX(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=Array.from(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 pX(`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))}},gX=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}},_X=0;function vX(e){_X+=1,e.warnings!==!1&&_X>=10&&_X%10==0&&console.warn(`[Shiki] ${_X} 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 pX("`engine` option is required for synchronous mode");let n=(e.langs||[]).flat(1),r=(e.themes||[]).flat(1).map(sX),i=new hX(new gX(e.engine,n),r,n,e.langAlias),a;function o(t){return mX(t,e.langAlias)}function s(e){g();let t=i.getGrammar(typeof e==`string`?e:e.name);if(!t)throw new pX(`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 pX(`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 cX(e))}function m(...e){g();for(let t of e.flat(1))i.loadTheme(t)}async function h(...e){return g(),m(await lX(e))}function g(){if(t)throw new pX(`Shiki instance has been disposed`)}function _(){t||(t=!0,i.dispose(),--_X)}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 yX(e){e.engine||fX("`engine` option is required. Use `createOnigurumaEngine` or `createJavaScriptRegexEngine` to create an engine.");let[t,n,r]=await Promise.all([lX(e.themes||[]),cX(e.langs||[]),e.engine]);return vX({...e,themes:t,langs:n,engine:r})}async function bX(e){let t=await yX(e);return{getLastGrammarState:(...e)=>zY(t,...e),codeToTokensBase:(e,n)=>RY(t,e,n),codeToTokensWithThemes:(e,n)=>qY(t,e,n),codeToTokens:(e,n)=>YY(t,e,n),codeToHast:(e,n)=>ZY(t,e,n),codeToHtml:(e,n)=>rX(t,e,n),getBundledLanguages:()=>({}),getBundledThemes:()=>({}),...t,getInternalContext:()=>t}}function xX(e){let t=e.langs,n=e.themes,r=e.engine;async function i(e){function i(n){if(typeof n==`string`){if(n=e.langAlias?.[n]||n,tY(n))return[];let r=t[n];if(!r)throw new YJ(`Language \`${n}\` is not included in this bundle. You may want to load it from external source.`);return r}return n}function a(e){if(rY(e))return`none`;if(typeof e==`string`){let t=n[e];if(!t)throw new YJ(`Theme \`${e}\` is not included in this bundle. You may want to load it from external source.`);return t}return e}let o=(e.themes??[]).map(e=>a(e)),s=(e.langs??[]).map(e=>i(e)),c=await bX({engine:e.engine??r(),...e,themes:o,langs:s});return{...c,loadLanguage(...e){return c.loadLanguage(...e.map(i))},loadTheme(...e){return c.loadTheme(...e.map(a))},getBundledLanguages(){return t},getBundledThemes(){return n}}}return i}function SX(e){let t;async function n(n={}){if(t){let e=await t;return await Promise.all([e.loadTheme(...n.themes||[]),e.loadLanguage(...n.langs||[])]),e}else{t=e({...n,themes:[],langs:[]});let r=await t;return await Promise.all([r.loadTheme(...n.themes||[]),r.loadLanguage(...n.langs||[])]),r}}return n}function CX(e,t){let n=SX(e);async function r(e,r){let i=await n({langs:[r.lang],themes:`theme`in r?[r.theme]:Object.values(r.themes)}),a=await t?.guessEmbeddedLanguages?.(e,r.lang,i);return a&&await i.loadLanguage(...a),i}return{getSingletonHighlighter(e){return n(e)},async codeToHtml(e,t){return(await r(e,t)).codeToHtml(e,t)},async codeToHast(e,t){return(await r(e,t)).codeToHast(e,t)},async codeToTokens(e,t){return(await r(e,t)).codeToTokens(e,t)},async codeToTokensBase(e,t){return(await r(e,t)).codeToTokensBase(e,t)},async codeToTokensWithThemes(e,t){return(await r(e,t)).codeToTokensWithThemes(e,t)},async getLastGrammarState(e,t){return(await n({langs:[t.lang],themes:[t.theme]})).getLastGrammarState(e,t)}}}var wX=[{id:`abap`,name:`ABAP`,import:(()=>$(()=>import(`./abap-BRbAAyvE.js`),[]))},{id:`actionscript-3`,name:`ActionScript`,import:(()=>$(()=>import(`./actionscript-3-Cj-0sM4g.js`),[]))},{id:`ada`,name:`Ada`,import:(()=>$(()=>import(`./ada-DhEA_nP5.js`),[]))},{id:`angular-html`,name:`Angular HTML`,import:(()=>$(()=>import(`./angular-html-CHsdtmkx.js`).then(e=>e.n),__vite__mapDeps([103,1,104,105,106])))},{id:`angular-ts`,name:`Angular TypeScript`,import:(()=>$(()=>import(`./angular-ts-JNDGGWj0.js`),__vite__mapDeps([107,103,1,104,105,106,108])))},{id:`apache`,name:`Apache Conf`,import:(()=>$(()=>import(`./apache-D5R2GKIs.js`),[]))},{id:`apex`,name:`Apex`,import:(()=>$(()=>import(`./apex-Qu8W4hal.js`),[]))},{id:`apl`,name:`APL`,import:(()=>$(()=>import(`./apl-Byuv-g-O.js`),__vite__mapDeps([109,105,1,104,106,110,111,112])))},{id:`applescript`,name:`AppleScript`,import:(()=>$(()=>import(`./applescript-CBey3ErE.js`),[]))},{id:`ara`,name:`Ara`,import:(()=>$(()=>import(`./ara-CRKnUAN1.js`),[]))},{id:`asciidoc`,name:`AsciiDoc`,aliases:[`adoc`],import:(()=>$(()=>import(`./asciidoc-1KYZEB6-.js`),[]))},{id:`asm`,name:`Assembly`,import:(()=>$(()=>import(`./asm-DAaViY0U.js`),[]))},{id:`astro`,name:`Astro`,import:(()=>$(()=>import(`./astro-CTzEugGW.js`),__vite__mapDeps([113,105,1,106,110,114,115,116])))},{id:`awk`,name:`AWK`,import:(()=>$(()=>import(`./awk-ButuPTaW.js`),[]))},{id:`ballerina`,name:`Ballerina`,import:(()=>$(()=>import(`./ballerina-DodmBVwR.js`),[]))},{id:`bat`,name:`Batch File`,aliases:[`batch`],import:(()=>$(()=>import(`./bat-jA-YqDhG.js`),[]))},{id:`beancount`,name:`Beancount`,import:(()=>$(()=>import(`./beancount-BCkjWTs-.js`),[]))},{id:`berry`,name:`Berry`,aliases:[`be`],import:(()=>$(()=>import(`./berry-DjEHm1kC.js`),[]))},{id:`bibtex`,name:`BibTeX`,import:(()=>$(()=>import(`./bibtex-aOfmXHFj.js`),[]))},{id:`bicep`,name:`Bicep`,import:(()=>$(()=>import(`./bicep-BZLx0b6B.js`),[]))},{id:`bird2`,name:`BIRD2 Configuration`,aliases:[`bird`],import:(()=>$(()=>import(`./bird2-V7dWeQhQ.js`),[]))},{id:`blade`,name:`Blade`,import:(()=>$(()=>import(`./blade-Dt6km9YT.js`),__vite__mapDeps([117,105,1,118,104,106,110,119,111,112])))},{id:`bsl`,name:`1C (Enterprise)`,aliases:[`1c`],import:(()=>$(()=>import(`./bsl-CPV9KqsG.js`),__vite__mapDeps([120,121])))},{id:`c`,name:`C`,import:(()=>$(()=>import(`./c-Bv0tI3pq.js`).then(e=>e.n),__vite__mapDeps([122,1])))},{id:`c3`,name:`C3`,import:(()=>$(()=>import(`./c3-BDcFIiRd.js`),[]))},{id:`cadence`,name:`Cadence`,aliases:[`cdc`],import:(()=>$(()=>import(`./cadence-DaglWUgA.js`),[]))},{id:`cairo`,name:`Cairo`,import:(()=>$(()=>import(`./cairo-CyiRuu7R.js`),__vite__mapDeps([123,124])))},{id:`clarity`,name:`Clarity`,import:(()=>$(()=>import(`./clarity-DS5YLe8G.js`),[]))},{id:`clojure`,name:`Clojure`,aliases:[`clj`],import:(()=>$(()=>import(`./clojure-BVGPdaE2.js`),[]))},{id:`cmake`,name:`CMake`,import:(()=>$(()=>import(`./cmake-CCC7tP43.js`),[]))},{id:`cobol`,name:`COBOL`,import:(()=>$(()=>import(`./cobol-DqhY5el-.js`),__vite__mapDeps([125,104,1,105,106,112])))},{id:`codeowners`,name:`CODEOWNERS`,import:(()=>$(()=>import(`./codeowners-DXhoR5Ap.js`),[]))},{id:`codeql`,name:`CodeQL`,aliases:[`ql`],import:(()=>$(()=>import(`./codeql-BGjlu3KC.js`),[]))},{id:`coffee`,name:`CoffeeScript`,aliases:[`coffeescript`],import:(()=>$(()=>import(`./coffee-rY-gkJy7.js`),__vite__mapDeps([126,106,1])))},{id:`common-lisp`,name:`Common Lisp`,aliases:[`lisp`],import:(()=>$(()=>import(`./common-lisp-BE6wRQeA.js`),[]))},{id:`coq`,name:`Coq`,import:(()=>$(()=>import(`./coq-CRT8yML1.js`),[]))},{id:`cpp`,name:`C++`,aliases:[`c++`],import:(()=>$(()=>import(`./cpp-Bw-qV0P6.js`).then(e=>e.n),__vite__mapDeps([127,1,128,122,129,119])))},{id:`crystal`,name:`Crystal`,import:(()=>$(()=>import(`./crystal-Bw1_1hFA.js`),__vite__mapDeps([130,122,1,105,104,106,131,119])))},{id:`csharp`,name:`C#`,aliases:[`c#`,`cs`],import:(()=>$(()=>import(`./csharp-Ca2kU4Te.js`),[]))},{id:`css`,name:`CSS`,import:(()=>$(()=>import(`./css-z2ijrDWT.js`).then(e=>e.n),__vite__mapDeps([105,1])))},{id:`csv`,name:`CSV`,import:(()=>$(()=>import(`./csv-DUpZC5ZD.js`),[]))},{id:`cue`,name:`CUE`,import:(()=>$(()=>import(`./cue-DlXQ7arx.js`),[]))},{id:`cypher`,name:`Cypher`,aliases:[`cql`],import:(()=>$(()=>import(`./cypher-D6dhuZbo.js`),[]))},{id:`d`,name:`D`,import:(()=>$(()=>import(`./d-BUgyoY6k.js`),[]))},{id:`dart`,name:`Dart`,import:(()=>$(()=>import(`./dart-CVd7TDni.js`),[]))},{id:`dax`,name:`DAX`,import:(()=>$(()=>import(`./dax-sEzq00Tq.js`),[]))},{id:`desktop`,name:`Desktop`,import:(()=>$(()=>import(`./desktop-3VGbzlmJ.js`),[]))},{id:`diff`,name:`Diff`,import:(()=>$(()=>import(`./diff-D4HSRbRn.js`),[]))},{id:`docker`,name:`Dockerfile`,aliases:[`dockerfile`],import:(()=>$(()=>import(`./docker-DkLGgDMo.js`),[]))},{id:`dotenv`,name:`dotEnv`,import:(()=>$(()=>import(`./dotenv-BWp1FaLo.js`),[]))},{id:`dream-maker`,name:`Dream Maker`,import:(()=>$(()=>import(`./dream-maker-DtLD6KM3.js`),[]))},{id:`edge`,name:`Edge`,import:(()=>$(()=>import(`./edge-r5NIe9Lp.js`),__vite__mapDeps([132,118,104,1,105,106,116])))},{id:`elixir`,name:`Elixir`,import:(()=>$(()=>import(`./elixir-B04apOJS.js`),__vite__mapDeps([133,104,1,105,106])))},{id:`elm`,name:`Elm`,import:(()=>$(()=>import(`./elm-Cezz_HNz.js`),__vite__mapDeps([134,128,1,122])))},{id:`emacs-lisp`,name:`Emacs Lisp`,aliases:[`elisp`],import:(()=>$(()=>import(`./emacs-lisp-BHIDiQRU.js`),[]))},{id:`erb`,name:`ERB`,import:(()=>$(()=>import(`./erb-BNioEFKQ.js`),__vite__mapDeps([135,104,1,105,106,136,122,127,128,129,119,137,138,115,116,139,140,131,111,112,141])))},{id:`erlang`,name:`Erlang`,aliases:[`erl`],import:(()=>$(()=>import(`./erlang-BC8wryba.js`),__vite__mapDeps([142,143])))},{id:`fennel`,name:`Fennel`,import:(()=>$(()=>import(`./fennel-Cd-BhZ0S.js`),[]))},{id:`fish`,name:`Fish`,import:(()=>$(()=>import(`./fish-CpsjJ6FK.js`),[]))},{id:`fluent`,name:`Fluent`,aliases:[`ftl`],import:(()=>$(()=>import(`./fluent-D1peBFgx.js`),[]))},{id:`fortran-fixed-form`,name:`Fortran (Fixed Form)`,aliases:[`f`,`for`,`f77`],import:(()=>$(()=>import(`./fortran-fixed-form-CyrImzNA.js`),__vite__mapDeps([144,145])))},{id:`fortran-free-form`,name:`Fortran (Free Form)`,aliases:[`f90`,`f95`,`f03`,`f08`,`f18`],import:(()=>$(()=>import(`./fortran-free-form-CIAQqF5W.js`),[]))},{id:`fsharp`,name:`F#`,aliases:[`f#`,`fs`],import:(()=>$(()=>import(`./fsharp-OCW_PZ4J.js`),__vite__mapDeps([146,143])))},{id:`gdresource`,name:`GDResource`,aliases:[`tscn`,`tres`],import:(()=>$(()=>import(`./gdresource-Cl3bohRI.js`),__vite__mapDeps([147,148,149])))},{id:`gdscript`,name:`GDScript`,aliases:[`gd`],import:(()=>$(()=>import(`./gdscript-B_XVILZe.js`),[]))},{id:`gdshader`,name:`GDShader`,import:(()=>$(()=>import(`./gdshader-BOrkFM_X.js`),[]))},{id:`genie`,name:`Genie`,import:(()=>$(()=>import(`./genie-BE7nKhIq.js`),[]))},{id:`gherkin`,name:`Gherkin`,import:(()=>$(()=>import(`./gherkin-DzGJhdqS.js`),[]))},{id:`git-commit`,name:`Git Commit Message`,import:(()=>$(()=>import(`./git-commit-DJZpdBwB.js`),__vite__mapDeps([150,151])))},{id:`git-rebase`,name:`Git Rebase Message`,import:(()=>$(()=>import(`./git-rebase-BJE30GTP.js`),__vite__mapDeps([152,131,1])))},{id:`gleam`,name:`Gleam`,import:(()=>$(()=>import(`./gleam-B9ISJjDl.js`),[]))},{id:`glimmer-js`,name:`Glimmer JS`,aliases:[`gjs`],import:(()=>$(()=>import(`./glimmer-js-Dn6vjgHP.js`),__vite__mapDeps([153,105,1,104,106,116])))},{id:`glimmer-ts`,name:`Glimmer TS`,aliases:[`gts`],import:(()=>$(()=>import(`./glimmer-ts-mq-Q_zEE.js`),__vite__mapDeps([154,105,1,104,106,116])))},{id:`glsl`,name:`GLSL`,import:(()=>$(()=>import(`./glsl-C8VPaAWs.js`).then(e=>e.n),__vite__mapDeps([128,1,122])))},{id:`gn`,name:`GN`,import:(()=>$(()=>import(`./gn-RQRMslrP.js`),[]))},{id:`gnuplot`,name:`Gnuplot`,import:(()=>$(()=>import(`./gnuplot-CfIGZWjt.js`),[]))},{id:`go`,name:`Go`,import:(()=>$(()=>import(`./go-iV8pwUYW.js`),[]))},{id:`graphql`,name:`GraphQL`,aliases:[`gql`],import:(()=>$(()=>import(`./graphql-WZCiqIl-.js`).then(e=>e.n),__vite__mapDeps([137,1,106,138,115,116])))},{id:`groovy`,name:`Groovy`,import:(()=>$(()=>import(`./groovy-lvGC2zUz.js`),[]))},{id:`hack`,name:`Hack`,import:(()=>$(()=>import(`./hack-DeD259o6.js`),__vite__mapDeps([155,104,1,105,106,119])))},{id:`haml`,name:`Ruby Haml`,import:(()=>$(()=>import(`./haml-B8MRe8CS.js`).then(e=>e.n),__vite__mapDeps([139,1,105,106])))},{id:`handlebars`,name:`Handlebars`,aliases:[`hbs`],import:(()=>$(()=>import(`./handlebars-GoJyzhp1.js`),__vite__mapDeps([156,105,1,104,106,141])))},{id:`haskell`,name:`Haskell`,aliases:[`hs`],import:(()=>$(()=>import(`./haskell-DdaZtXdd.js`),[]))},{id:`haxe`,name:`Haxe`,import:(()=>$(()=>import(`./haxe-Df79h8x1.js`),[]))},{id:`hcl`,name:`HashiCorp HCL`,import:(()=>$(()=>import(`./hcl-BibREsa1.js`),[]))},{id:`hjson`,name:`Hjson`,import:(()=>$(()=>import(`./hjson-D-iSecYq.js`),[]))},{id:`hlsl`,name:`HLSL`,import:(()=>$(()=>import(`./hlsl-CckLjo_3.js`),[]))},{id:`html`,name:`HTML`,import:(()=>$(()=>import(`./html-B7kk5NVw.js`).then(e=>e.n),__vite__mapDeps([104,1,105,106])))},{id:`html-derivative`,name:`HTML (Derivative)`,import:(()=>$(()=>import(`./html-derivative-Ba28nVB3.js`),__vite__mapDeps([118,104,1,105,106])))},{id:`http`,name:`HTTP`,import:(()=>$(()=>import(`./http-Deln4Vyb.js`),__vite__mapDeps([157,137,1,106,138,115,116,110,131,111,112])))},{id:`hurl`,name:`Hurl`,import:(()=>$(()=>import(`./hurl-CYSuhGkj.js`),__vite__mapDeps([158,159,137,1,106,138,115,116,111,112])))},{id:`hxml`,name:`HXML`,import:(()=>$(()=>import(`./hxml-BmF7ngDz.js`),__vite__mapDeps([160,161])))},{id:`hy`,name:`Hy`,import:(()=>$(()=>import(`./hy-6acR1htR.js`),[]))},{id:`imba`,name:`Imba`,import:(()=>$(()=>import(`./imba-I9bJJvhi.js`),[]))},{id:`ini`,name:`INI`,aliases:[`properties`],import:(()=>$(()=>import(`./ini-ovi-wMtM.js`),[]))},{id:`java`,name:`Java`,import:(()=>$(()=>import(`./java-X0I2c5Az.js`).then(e=>e.n),__vite__mapDeps([112,1])))},{id:`javascript`,name:`JavaScript`,aliases:[`js`,`cjs`,`mjs`],import:(()=>$(()=>import(`./javascript-WC6XFf_S.js`).then(e=>e.n),__vite__mapDeps([106,1])))},{id:`jinja`,name:`Jinja`,import:(()=>$(()=>import(`./jinja-Dx5IcFSt.js`),__vite__mapDeps([162,104,1,105,106])))},{id:`jison`,name:`Jison`,import:(()=>$(()=>import(`./jison-DuNOGix6.js`),__vite__mapDeps([163,106,1])))},{id:`json`,name:`JSON`,import:(()=>$(()=>import(`./json-CmuSmrUv.js`).then(e=>e.n),__vite__mapDeps([110,1])))},{id:`json5`,name:`JSON5`,import:(()=>$(()=>import(`./json5-JNG5kh3j.js`),[]))},{id:`jsonc`,name:`JSON with Comments`,import:(()=>$(()=>import(`./jsonc-Bo6bgSpa.js`),[]))},{id:`jsonl`,name:`JSON Lines`,import:(()=>$(()=>import(`./jsonl-eDmbsRcr.js`),[]))},{id:`jsonnet`,name:`Jsonnet`,import:(()=>$(()=>import(`./jsonnet-BrmnmEy9.js`),[]))},{id:`jssm`,name:`JSSM`,aliases:[`fsl`],import:(()=>$(()=>import(`./jssm-C-QfdDgD.js`),[]))},{id:`jsx`,name:`JSX`,import:(()=>$(()=>import(`./jsx-Bl4e1-KE.js`).then(e=>e.n),__vite__mapDeps([138,1])))},{id:`julia`,name:`Julia`,aliases:[`jl`],import:(()=>$(()=>import(`./julia-Cqc1ADyw.js`),__vite__mapDeps([164,127,1,128,122,129,119,106,124,165])))},{id:`just`,name:`Just`,import:(()=>$(()=>import(`./just-BlUYrdKb.js`),__vite__mapDeps([166,106,1,167,105,104,119,111,112,124,136,122,127,128,129,137,138,115,116,139,140,131,141])))},{id:`kdl`,name:`KDL`,import:(()=>$(()=>import(`./kdl-CPujEk7a.js`),[]))},{id:`kotlin`,name:`Kotlin`,aliases:[`kt`,`kts`],import:(()=>$(()=>import(`./kotlin-GNGS6f4G.js`),[]))},{id:`kusto`,name:`Kusto`,aliases:[`kql`],import:(()=>$(()=>import(`./kusto-BcKmLn2p.js`),[]))},{id:`latex`,name:`LaTeX`,import:(()=>$(()=>import(`./latex-BEPTKliI.js`),__vite__mapDeps([168,169,165,1])))},{id:`lean`,name:`Lean 4`,aliases:[`lean4`],import:(()=>$(()=>import(`./lean-CQ4oht2M.js`),[]))},{id:`less`,name:`Less`,import:(()=>$(()=>import(`./less-DgluPI4Z.js`),[]))},{id:`liquid`,name:`Liquid`,import:(()=>$(()=>import(`./liquid-BUh7yINm.js`),__vite__mapDeps([170,105,1,104,106,110])))},{id:`llvm`,name:`LLVM IR`,import:(()=>$(()=>import(`./llvm-C_Bk8N51.js`),[]))},{id:`log`,name:`Log file`,import:(()=>$(()=>import(`./log-Cqyx7kYB.js`),[]))},{id:`logo`,name:`Logo`,import:(()=>$(()=>import(`./logo-BMyACSNp.js`),[]))},{id:`lua`,name:`Lua`,import:(()=>$(()=>import(`./lua-BroxvhVt.js`).then(e=>e.n),__vite__mapDeps([140,1,122])))},{id:`luau`,name:`Luau`,import:(()=>$(()=>import(`./luau-Dw3qkd4h.js`),[]))},{id:`make`,name:`Makefile`,aliases:[`makefile`],import:(()=>$(()=>import(`./make-DRoG6w-e.js`),[]))},{id:`markdown`,name:`Markdown`,aliases:[`md`],import:(()=>$(()=>import(`./markdown-DMIvNSB1.js`),[]))},{id:`marko`,name:`Marko`,import:(()=>$(()=>import(`./marko-Dm8xPXkG.js`),__vite__mapDeps([171,105,1,172,108,116])))},{id:`matlab`,name:`MATLAB`,import:(()=>$(()=>import(`./matlab-Buftnej6.js`),[]))},{id:`mdc`,name:`MDC`,import:(()=>$(()=>import(`./mdc-Dzipcsdb.js`),__vite__mapDeps([173,118,104,1,105,106,143,141])))},{id:`mdx`,name:`MDX`,import:(()=>$(()=>import(`./mdx-COL7Vpwq.js`),[]))},{id:`mermaid`,name:`Mermaid`,aliases:[`mmd`],import:(()=>$(()=>import(`./mermaid-tvyj1ZQ2.js`),[]))},{id:`mipsasm`,name:`MIPS Assembly`,aliases:[`mips`],import:(()=>$(()=>import(`./mipsasm-C6fvALrw.js`),[]))},{id:`mojo`,name:`Mojo`,import:(()=>$(()=>import(`./mojo-B3qnM1a8.js`),[]))},{id:`moonbit`,name:`MoonBit`,aliases:[`mbt`,`mbti`],import:(()=>$(()=>import(`./moonbit-Cjo3d0oi.js`),[]))},{id:`move`,name:`Move`,import:(()=>$(()=>import(`./move-BZSDQnwS.js`),[]))},{id:`narrat`,name:`Narrat Language`,aliases:[`nar`],import:(()=>$(()=>import(`./narrat-DY5cg5OF.js`),[]))},{id:`nextflow`,name:`Nextflow`,aliases:[`nf`],import:(()=>$(()=>import(`./nextflow-BRiWOV-p.js`),__vite__mapDeps([174,175])))},{id:`nextflow-groovy`,name:`nextflow-groovy`,import:(()=>$(()=>import(`./nextflow-groovy-D6rYlJlL.js`),[]))},{id:`nginx`,name:`Nginx`,import:(()=>$(()=>import(`./nginx-Da_Uewgc.js`),__vite__mapDeps([176,140,1,122])))},{id:`nim`,name:`Nim`,import:(()=>$(()=>import(`./nim-CvgRYLO2.js`),__vite__mapDeps([177,122,1,105,128,104,106,143,111,112])))},{id:`nix`,name:`Nix`,import:(()=>$(()=>import(`./nix-C2G-gZoY.js`),[]))},{id:`nushell`,name:`nushell`,aliases:[`nu`],import:(()=>$(()=>import(`./nushell-S11HUHTG.js`),[]))},{id:`objective-c`,name:`Objective-C`,aliases:[`objc`],import:(()=>$(()=>import(`./objective-c-D9GKvYFi.js`),[]))},{id:`objective-cpp`,name:`Objective-C++`,import:(()=>$(()=>import(`./objective-cpp-SqrtXFXh.js`),[]))},{id:`ocaml`,name:`OCaml`,import:(()=>$(()=>import(`./ocaml-C_PTi_Pz.js`),[]))},{id:`odin`,name:`Odin`,import:(()=>$(()=>import(`./odin-BWpZDKBG.js`),[]))},{id:`openscad`,name:`OpenSCAD`,aliases:[`scad`],import:(()=>$(()=>import(`./openscad-BM4fjXzn.js`),[]))},{id:`pascal`,name:`Pascal`,import:(()=>$(()=>import(`./pascal-DYsRufgb.js`),[]))},{id:`perl`,name:`Perl`,import:(()=>$(()=>import(`./perl-BIcNvyL6.js`),__vite__mapDeps([167,105,1,104,106,119,111,112])))},{id:`php`,name:`PHP`,import:(()=>$(()=>import(`./php-BP-3TkW_.js`),__vite__mapDeps([178,105,1,104,106,110,119,111,112])))},{id:`pkl`,name:`Pkl`,import:(()=>$(()=>import(`./pkl-Djf8ANrI.js`),[]))},{id:`plsql`,name:`PL/SQL`,import:(()=>$(()=>import(`./plsql-B1bmZxUF.js`),[]))},{id:`po`,name:`Gettext PO`,aliases:[`pot`,`potx`],import:(()=>$(()=>import(`./po-BvnTR3_f.js`),[]))},{id:`polar`,name:`Polar`,import:(()=>$(()=>import(`./polar-CAj5SJyd.js`),[]))},{id:`postcss`,name:`PostCSS`,import:(()=>$(()=>import(`./postcss-DrpvRGGG.js`),[]))},{id:`powerquery`,name:`PowerQuery`,import:(()=>$(()=>import(`./powerquery-I1Ei5hrS.js`),[]))},{id:`powershell`,name:`PowerShell`,aliases:[`ps`,`ps1`],import:(()=>$(()=>import(`./powershell-Coc0WruX.js`),[]))},{id:`prisma`,name:`Prisma`,import:(()=>$(()=>import(`./prisma-Ojgxt2lx.js`),[]))},{id:`prolog`,name:`Prolog`,import:(()=>$(()=>import(`./prolog-C1UOAv4v.js`),[]))},{id:`proto`,name:`Protocol Buffer 3`,aliases:[`protobuf`],import:(()=>$(()=>import(`./proto-D07RTuB5.js`),[]))},{id:`pug`,name:`Pug`,aliases:[`jade`],import:(()=>$(()=>import(`./pug-_XoIcKf3.js`),__vite__mapDeps([179,105,1,104,106])))},{id:`puppet`,name:`Puppet`,import:(()=>$(()=>import(`./puppet-D_zyrMo2.js`),[]))},{id:`purescript`,name:`PureScript`,import:(()=>$(()=>import(`./purescript-CV-DVmZj.js`),[]))},{id:`python`,name:`Python`,aliases:[`py`],import:(()=>$(()=>import(`./python-DcnbpNOV.js`),[]))},{id:`qml`,name:`QML`,import:(()=>$(()=>import(`./qml-DWxWu28U.js`),__vite__mapDeps([180,106,1])))},{id:`qmldir`,name:`QML Directory`,import:(()=>$(()=>import(`./qmldir-BBNnU9RJ.js`),[]))},{id:`qss`,name:`Qt Style Sheets`,import:(()=>$(()=>import(`./qss-CC0PKRbL.js`),[]))},{id:`r`,name:`R`,import:(()=>$(()=>import(`./r-B4lG5syH.js`).then(e=>e.n),__vite__mapDeps([165,1])))},{id:`racket`,name:`Racket`,import:(()=>$(()=>import(`./racket-Cbwns2Cq.js`),[]))},{id:`raku`,name:`Raku`,aliases:[`perl6`],import:(()=>$(()=>import(`./raku-CeV6tH_x.js`),[]))},{id:`razor`,name:`ASP.NET Razor`,import:(()=>$(()=>import(`./razor-DQ6FV4WL.js`),__vite__mapDeps([181,182,104,1,105,106])))},{id:`reg`,name:`Windows Registry Script`,import:(()=>$(()=>import(`./reg-C_WE1pkC.js`),[]))},{id:`regexp`,name:`RegExp`,aliases:[`regex`],import:(()=>$(()=>import(`./regexp-da3KYCEG.js`).then(e=>e.n),__vite__mapDeps([129,1])))},{id:`rel`,name:`Rel`,import:(()=>$(()=>import(`./rel-CpHQF4b7.js`),[]))},{id:`riscv`,name:`RISC-V`,import:(()=>$(()=>import(`./riscv-Co5eiPIZ.js`),[]))},{id:`ron`,name:`RON`,import:(()=>$(()=>import(`./ron-CgTit1dG.js`),[]))},{id:`rosmsg`,name:`ROS Interface`,import:(()=>$(()=>import(`./rosmsg-C0tpzWlc.js`),[]))},{id:`rst`,name:`reStructuredText`,import:(()=>$(()=>import(`./rst-DDrWKQ9c.js`),__vite__mapDeps([183,184,127,1,128,122,129,119,118,104,105,106,124,136,137,138,115,116,139,140,131,111,112,141])))},{id:`ruby`,name:`Ruby`,aliases:[`rb`],import:(()=>$(()=>import(`./ruby-BOVYgV5O.js`),__vite__mapDeps([136,122,1,127,128,129,119,105,137,106,138,115,116,139,104,140,131,111,112,141])))},{id:`rust`,name:`Rust`,aliases:[`rs`],import:(()=>$(()=>import(`./rust-BWAfVMY4.js`),[]))},{id:`sas`,name:`SAS`,import:(()=>$(()=>import(`./sas-DYNukvU9.js`),__vite__mapDeps([185,119,1])))},{id:`sass`,name:`Sass`,import:(()=>$(()=>import(`./sass-MovLey2R.js`),[]))},{id:`scala`,name:`Scala`,import:(()=>$(()=>import(`./scala-C2w7y2mZ.js`),[]))},{id:`scheme`,name:`Scheme`,import:(()=>$(()=>import(`./scheme-Bf85FNnm.js`),[]))},{id:`scss`,name:`SCSS`,import:(()=>$(()=>import(`./scss-CaciJ0Gl.js`).then(e=>e.n),__vite__mapDeps([108,1,105])))},{id:`sdbl`,name:`1C (Query)`,aliases:[`1c-query`],import:(()=>$(()=>import(`./sdbl-DoQ_zDzo.js`),[]))},{id:`shaderlab`,name:`ShaderLab`,aliases:[`shader`],import:(()=>$(()=>import(`./shaderlab-TbUUdmUb.js`),__vite__mapDeps([186,187])))},{id:`shellscript`,name:`Shell`,aliases:[`bash`,`sh`,`shell`,`zsh`],import:(()=>$(()=>import(`./shellscript-KUJZnuCi.js`).then(e=>e.n),__vite__mapDeps([131,1])))},{id:`shellsession`,name:`Shell Session`,aliases:[`console`],import:(()=>$(()=>import(`./shellsession-BeWGuVoR.js`),__vite__mapDeps([188,131,1])))},{id:`smalltalk`,name:`Smalltalk`,import:(()=>$(()=>import(`./smalltalk-Mlf5-xbr.js`),[]))},{id:`solidity`,name:`Solidity`,import:(()=>$(()=>import(`./solidity-DYHGECBw.js`),[]))},{id:`soy`,name:`Closure Templates`,aliases:[`closure-templates`],import:(()=>$(()=>import(`./soy-h0dQKbQs.js`),__vite__mapDeps([189,104,1,105,106])))},{id:`sparql`,name:`SPARQL`,import:(()=>$(()=>import(`./sparql-DIFvSn1n.js`),__vite__mapDeps([190,191])))},{id:`splunk`,name:`Splunk Query Language`,aliases:[`spl`],import:(()=>$(()=>import(`./splunk-DOdklC0I.js`),[]))},{id:`sql`,name:`SQL`,import:(()=>$(()=>import(`./sql-CZAMrWdL.js`).then(e=>e.n),__vite__mapDeps([119,1])))},{id:`ssh-config`,name:`SSH Config`,import:(()=>$(()=>import(`./ssh-config-DwwFW7AS.js`),[]))},{id:`stata`,name:`Stata`,import:(()=>$(()=>import(`./stata-C5mLa_ER.js`),__vite__mapDeps([192,119,1])))},{id:`stylus`,name:`Stylus`,aliases:[`styl`],import:(()=>$(()=>import(`./stylus-BO6mlOab.js`),[]))},{id:`surrealql`,name:`SurrealQL`,aliases:[`surql`],import:(()=>$(()=>import(`./surrealql-DyoUfV6n.js`),__vite__mapDeps([193,106,1])))},{id:`svelte`,name:`Svelte`,import:(()=>$(()=>import(`./svelte-CijnRGul.js`),__vite__mapDeps([194,105,1,106,114,116])))},{id:`swift`,name:`Swift`,import:(()=>$(()=>import(`./swift-D9A08YU9.js`),[]))},{id:`system-verilog`,name:`SystemVerilog`,import:(()=>$(()=>import(`./system-verilog-DjR3sN6w.js`),[]))},{id:`systemd`,name:`Systemd Units`,import:(()=>$(()=>import(`./systemd-CJWuVSJU.js`),[]))},{id:`talonscript`,name:`TalonScript`,aliases:[`talon`],import:(()=>$(()=>import(`./talonscript-CXqq0wX-.js`),[]))},{id:`tasl`,name:`Tasl`,import:(()=>$(()=>import(`./tasl-GVNf7pB7.js`),[]))},{id:`tcl`,name:`Tcl`,import:(()=>$(()=>import(`./tcl-DNlfRSl5.js`),[]))},{id:`templ`,name:`Templ`,import:(()=>$(()=>import(`./templ-CNjJl440.js`),__vite__mapDeps([195,105,1,196,106])))},{id:`terraform`,name:`Terraform`,aliases:[`tf`,`tfvars`],import:(()=>$(()=>import(`./terraform-DUK0FOOj.js`),[]))},{id:`tex`,name:`TeX`,import:(()=>$(()=>import(`./tex-ezg8IclB.js`),__vite__mapDeps([169,165,1])))},{id:`toml`,name:`TOML`,import:(()=>$(()=>import(`./toml-X5n3zjEH.js`),[]))},{id:`ts-tags`,name:`TypeScript with Tags`,aliases:[`lit`],import:(()=>$(()=>import(`./ts-tags-DV6nguf9.js`),__vite__mapDeps([197,105,1,128,122,104,106,119,116,111,112])))},{id:`tsv`,name:`TSV`,import:(()=>$(()=>import(`./tsv-Bqs_rchc.js`),[]))},{id:`tsx`,name:`TSX`,import:(()=>$(()=>import(`./tsx-CfyUE2pW.js`).then(e=>e.n),__vite__mapDeps([115,1])))},{id:`turtle`,name:`Turtle`,import:(()=>$(()=>import(`./turtle-BsUuoeVK.js`),[]))},{id:`twig`,name:`Twig`,import:(()=>$(()=>import(`./twig-BROkIZLg.js`),__vite__mapDeps([198,105,1,106,178,104,110,119,111,112,124,136,122,127,128,129,137,138,115,116,139,140,131,141,108])))},{id:`typescript`,name:`TypeScript`,aliases:[`ts`,`cts`,`mts`],import:(()=>$(()=>import(`./typescript-C6LvTgbf.js`).then(e=>e.n),__vite__mapDeps([116,1])))},{id:`typespec`,name:`TypeSpec`,aliases:[`tsp`],import:(()=>$(()=>import(`./typespec-CKEcF6Kw.js`),[]))},{id:`typst`,name:`Typst`,aliases:[`typ`],import:(()=>$(()=>import(`./typst-CPL77SDw.js`),[]))},{id:`v`,name:`V`,import:(()=>$(()=>import(`./v-CoJD3IPx.js`),[]))},{id:`vala`,name:`Vala`,import:(()=>$(()=>import(`./vala-C42IfotU.js`),[]))},{id:`vb`,name:`Visual Basic`,aliases:[`cmd`],import:(()=>$(()=>import(`./vb-CVMKTK26.js`),[]))},{id:`verilog`,name:`Verilog`,import:(()=>$(()=>import(`./verilog-P63PhzSt.js`),[]))},{id:`vhdl`,name:`VHDL`,import:(()=>$(()=>import(`./vhdl-2WwUdgX8.js`),[]))},{id:`viml`,name:`Vim Script`,aliases:[`vim`,`vimscript`],import:(()=>$(()=>import(`./viml-CGPGWJA6.js`),[]))},{id:`vue`,name:`Vue`,import:(()=>$(()=>import(`./vue-BUQP_8VF.js`),__vite__mapDeps([199,105,1,118,104,106,110,116])))},{id:`vue-html`,name:`Vue HTML`,import:(()=>$(()=>import(`./vue-html-Bx2Sgp8M.js`),__vite__mapDeps([200,106,1])))},{id:`vue-vine`,name:`Vue Vine`,import:(()=>$(()=>import(`./vue-vine-RK3AHrhp.js`),__vite__mapDeps([201,105,1,106,172,114,108,202])))},{id:`vyper`,name:`Vyper`,aliases:[`vy`],import:(()=>$(()=>import(`./vyper-DP_vqZO9.js`),[]))},{id:`wasm`,name:`WebAssembly`,import:(()=>$(()=>import(`./wasm-Db7VBw0n.js`),[]))},{id:`wenyan`,name:`Wenyan`,aliases:[`文言`],import:(()=>$(()=>import(`./wenyan-ZEcjghA1.js`),[]))},{id:`wgsl`,name:`WGSL`,import:(()=>$(()=>import(`./wgsl-CdusuPLe.js`),[]))},{id:`wikitext`,name:`Wikitext`,aliases:[`mediawiki`,`wiki`],import:(()=>$(()=>import(`./wikitext-CBIB6hmW.js`),[]))},{id:`wit`,name:`WebAssembly Interface Types`,import:(()=>$(()=>import(`./wit-ZhUbVeze.js`),[]))},{id:`wolfram`,name:`Wolfram`,aliases:[`wl`],import:(()=>$(()=>import(`./wolfram-HyMOyERF.js`),[]))},{id:`xml`,name:`XML`,import:(()=>$(()=>import(`./xml-BkdunjRC.js`).then(e=>e.n),__vite__mapDeps([111,1,112])))},{id:`xsl`,name:`XSL`,import:(()=>$(()=>import(`./xsl-C66i1pDH.js`),__vite__mapDeps([203,111,1,112])))},{id:`yaml`,name:`YAML`,aliases:[`yml`],import:(()=>$(()=>import(`./yaml-D_uvhEF7.js`).then(e=>e.n),__vite__mapDeps([141,1])))},{id:`zenscript`,name:`ZenScript`,import:(()=>$(()=>import(`./zenscript-C6ZuzgrL.js`),[]))},{id:`zig`,name:`Zig`,import:(()=>$(()=>import(`./zig-Do2h8XKj.js`),[]))}],TX=Object.fromEntries(wX.map(e=>[e.id,e.import])),EX=Object.fromEntries(wX.flatMap(e=>e.aliases?.map(t=>[t,e.import])||[])),DX={...TX,...EX},OX=Object.fromEntries([{id:`andromeeda`,displayName:`Andromeeda`,type:`dark`,import:(()=>$(()=>import(`./andromeeda-CWmR-N6V.js`),[]))},{id:`aurora-x`,displayName:`Aurora X`,type:`dark`,import:(()=>$(()=>import(`./aurora-x-LPpmXm4i.js`),[]))},{id:`ayu-dark`,displayName:`Ayu Dark`,type:`dark`,import:(()=>$(()=>import(`./ayu-dark-Dv4ngVMP.js`),[]))},{id:`ayu-light`,displayName:`Ayu Light`,type:`light`,import:(()=>$(()=>import(`./ayu-light-CxeOePuA.js`),[]))},{id:`ayu-mirage`,displayName:`Ayu Mirage`,type:`dark`,import:(()=>$(()=>import(`./ayu-mirage-i2YLXKmY.js`),[]))},{id:`catppuccin-frappe`,displayName:`Catppuccin Frappé`,type:`dark`,import:(()=>$(()=>import(`./catppuccin-frappe-CSAC76is.js`),[]))},{id:`catppuccin-latte`,displayName:`Catppuccin Latte`,type:`light`,import:(()=>$(()=>import(`./catppuccin-latte-Jt6sqtds.js`),[]))},{id:`catppuccin-macchiato`,displayName:`Catppuccin Macchiato`,type:`dark`,import:(()=>$(()=>import(`./catppuccin-macchiato-HM96_05s.js`),[]))},{id:`catppuccin-mocha`,displayName:`Catppuccin Mocha`,type:`dark`,import:(()=>$(()=>import(`./catppuccin-mocha-CXgIAGBL.js`),[]))},{id:`dark-plus`,displayName:`Dark Plus`,type:`dark`,import:(()=>$(()=>import(`./dark-plus-DNkJKrcZ.js`),[]))},{id:`dracula`,displayName:`Dracula Theme`,type:`dark`,import:(()=>$(()=>import(`./dracula-Donvxzd6.js`),[]))},{id:`dracula-soft`,displayName:`Dracula Theme Soft`,type:`dark`,import:(()=>$(()=>import(`./dracula-soft-BqL-kkUg.js`),[]))},{id:`everforest-dark`,displayName:`Everforest Dark`,type:`dark`,import:(()=>$(()=>import(`./everforest-dark-pZNhY4MK.js`),[]))},{id:`everforest-light`,displayName:`Everforest Light`,type:`light`,import:(()=>$(()=>import(`./everforest-light-BijKClkf.js`),[]))},{id:`github-dark`,displayName:`GitHub Dark`,type:`dark`,import:(()=>$(()=>import(`./github-dark-BB9G20EV.js`),[]))},{id:`github-dark-default`,displayName:`GitHub Dark Default`,type:`dark`,import:(()=>$(()=>import(`./github-dark-default-CBFNEU03.js`),[]))},{id:`github-dark-dimmed`,displayName:`GitHub Dark Dimmed`,type:`dark`,import:(()=>$(()=>import(`./github-dark-dimmed-sQhEp72S.js`),[]))},{id:`github-dark-high-contrast`,displayName:`GitHub Dark High Contrast`,type:`dark`,import:(()=>$(()=>import(`./github-dark-high-contrast-C8GVvrcM.js`),[]))},{id:`github-light`,displayName:`GitHub Light`,type:`light`,import:(()=>$(()=>import(`./github-light-pT7U8Cnd.js`),[]))},{id:`github-light-default`,displayName:`GitHub Light Default`,type:`light`,import:(()=>$(()=>import(`./github-light-default-iyEXWnoa.js`),[]))},{id:`github-light-high-contrast`,displayName:`GitHub Light High Contrast`,type:`light`,import:(()=>$(()=>import(`./github-light-high-contrast-DLnsZL7l.js`),[]))},{id:`gruvbox-dark-hard`,displayName:`Gruvbox Dark Hard`,type:`dark`,import:(()=>$(()=>import(`./gruvbox-dark-hard-CC38iqQ4.js`),[]))},{id:`gruvbox-dark-medium`,displayName:`Gruvbox Dark Medium`,type:`dark`,import:(()=>$(()=>import(`./gruvbox-dark-medium-DaS0IqFN.js`),[]))},{id:`gruvbox-dark-soft`,displayName:`Gruvbox Dark Soft`,type:`dark`,import:(()=>$(()=>import(`./gruvbox-dark-soft-C4niJipy.js`),[]))},{id:`gruvbox-light-hard`,displayName:`Gruvbox Light Hard`,type:`light`,import:(()=>$(()=>import(`./gruvbox-light-hard-DTfv4LmB.js`),[]))},{id:`gruvbox-light-medium`,displayName:`Gruvbox Light Medium`,type:`light`,import:(()=>$(()=>import(`./gruvbox-light-medium-m1VBpvsE.js`),[]))},{id:`gruvbox-light-soft`,displayName:`Gruvbox Light Soft`,type:`light`,import:(()=>$(()=>import(`./gruvbox-light-soft-CiE1IJdk.js`),[]))},{id:`horizon`,displayName:`Horizon`,type:`dark`,import:(()=>$(()=>import(`./horizon-BG-OH9yH.js`),[]))},{id:`horizon-bright`,displayName:`Horizon Bright`,type:`dark`,import:(()=>$(()=>import(`./horizon-bright-B0vmEjwb.js`),[]))},{id:`houston`,displayName:`Houston`,type:`dark`,import:(()=>$(()=>import(`./houston-C8DdNIgg.js`),[]))},{id:`kanagawa-dragon`,displayName:`Kanagawa Dragon`,type:`dark`,import:(()=>$(()=>import(`./kanagawa-dragon-Dc8jzBf8.js`),[]))},{id:`kanagawa-lotus`,displayName:`Kanagawa Lotus`,type:`light`,import:(()=>$(()=>import(`./kanagawa-lotus-DglQpAHb.js`),[]))},{id:`kanagawa-wave`,displayName:`Kanagawa Wave`,type:`dark`,import:(()=>$(()=>import(`./kanagawa-wave-CTxJC692.js`),[]))},{id:`laserwave`,displayName:`LaserWave`,type:`dark`,import:(()=>$(()=>import(`./laserwave-BLDq6SCM.js`),[]))},{id:`light-plus`,displayName:`Light Plus`,type:`light`,import:(()=>$(()=>import(`./light-plus-Ce6vIMrA.js`),[]))},{id:`material-theme`,displayName:`Material Theme`,type:`dark`,import:(()=>$(()=>import(`./material-theme-D1yzOeFY.js`),[]))},{id:`material-theme-darker`,displayName:`Material Theme Darker`,type:`dark`,import:(()=>$(()=>import(`./material-theme-darker-DhWqiNtj.js`),[]))},{id:`material-theme-lighter`,displayName:`Material Theme Lighter`,type:`light`,import:(()=>$(()=>import(`./material-theme-lighter-PKoq0Soa.js`),[]))},{id:`material-theme-ocean`,displayName:`Material Theme Ocean`,type:`dark`,import:(()=>$(()=>import(`./material-theme-ocean-TtH-ZZAj.js`),[]))},{id:`material-theme-palenight`,displayName:`Material Theme Palenight`,type:`dark`,import:(()=>$(()=>import(`./material-theme-palenight-DPEAidnA.js`),[]))},{id:`min-dark`,displayName:`Min Dark`,type:`dark`,import:(()=>$(()=>import(`./min-dark-D66g901Q.js`),[]))},{id:`min-light`,displayName:`Min Light`,type:`light`,import:(()=>$(()=>import(`./min-light-CMnDj2iG.js`),[]))},{id:`monokai`,displayName:`Monokai`,type:`dark`,import:(()=>$(()=>import(`./monokai-DCoxt20T.js`),[]))},{id:`night-owl`,displayName:`Night Owl`,type:`dark`,import:(()=>$(()=>import(`./night-owl-DuMFo77c.js`),[]))},{id:`night-owl-light`,displayName:`Night Owl Light`,type:`light`,import:(()=>$(()=>import(`./night-owl-light-DihOYNub.js`),[]))},{id:`nord`,displayName:`Nord`,type:`dark`,import:(()=>$(()=>import(`./nord-CqZqLQaJ.js`),[]))},{id:`one-dark-pro`,displayName:`One Dark Pro`,type:`dark`,import:(()=>$(()=>import(`./one-dark-pro-DpWTHpwg.js`),[]))},{id:`one-light`,displayName:`One Light`,type:`light`,import:(()=>$(()=>import(`./one-light-Cu0d64Hp.js`),[]))},{id:`plastic`,displayName:`Plastic`,type:`dark`,import:(()=>$(()=>import(`./plastic-CmjIC4JL.js`),[]))},{id:`poimandres`,displayName:`Poimandres`,type:`dark`,import:(()=>$(()=>import(`./poimandres-BTndTogr.js`),[]))},{id:`red`,displayName:`Red`,type:`dark`,import:(()=>$(()=>import(`./red-CVEaJbMR.js`),[]))},{id:`rose-pine`,displayName:`Rosé Pine`,type:`dark`,import:(()=>$(()=>import(`./rose-pine-BDTwvYHf.js`),[]))},{id:`rose-pine-dawn`,displayName:`Rosé Pine Dawn`,type:`light`,import:(()=>$(()=>import(`./rose-pine-dawn-CAIk_wLV.js`),[]))},{id:`rose-pine-moon`,displayName:`Rosé Pine Moon`,type:`dark`,import:(()=>$(()=>import(`./rose-pine-moon-C5gdiznP.js`),[]))},{id:`slack-dark`,displayName:`Slack Dark`,type:`dark`,import:(()=>$(()=>import(`./slack-dark-BnOYKTBJ.js`),[]))},{id:`slack-ochin`,displayName:`Slack Ochin`,type:`light`,import:(()=>$(()=>import(`./slack-ochin-43udxtUg.js`),[]))},{id:`snazzy-light`,displayName:`Snazzy Light`,type:`light`,import:(()=>$(()=>import(`./snazzy-light-kw-pZEiM.js`),[]))},{id:`solarized-dark`,displayName:`Solarized Dark`,type:`dark`,import:(()=>$(()=>import(`./solarized-dark-BDezFa9V.js`),[]))},{id:`solarized-light`,displayName:`Solarized Light`,type:`light`,import:(()=>$(()=>import(`./solarized-light-CkoenhS2.js`),[]))},{id:`synthwave-84`,displayName:`Synthwave '84`,type:`dark`,import:(()=>$(()=>import(`./synthwave-84-C69NN2j9.js`),[]))},{id:`tokyo-night`,displayName:`Tokyo Night`,type:`dark`,import:(()=>$(()=>import(`./tokyo-night-DWTtuXS3.js`),[]))},{id:`vesper`,displayName:`Vesper`,type:`dark`,import:(()=>$(()=>import(`./vesper-BGr95374.js`),[]))},{id:`vitesse-black`,displayName:`Vitesse Black`,type:`dark`,import:(()=>$(()=>import(`./vitesse-black-cI0k84-I.js`),[]))},{id:`vitesse-dark`,displayName:`Vitesse Dark`,type:`dark`,import:(()=>$(()=>import(`./vitesse-dark-SouM0FMW.js`),[]))},{id:`vitesse-light`,displayName:`Vitesse Light`,type:`light`,import:(()=>$(()=>import(`./vitesse-light-WiCy6lDO.js`),[]))}].map(e=>[e.id,e.import])),kX=class extends Error{constructor(e){super(e),this.name=`ShikiError`}};function AX(){return 2147483648}function jX(){return typeof performance<`u`?performance.now():Date.now()}var MX=(e,t)=>e+(t-e%t)%t;async function NX(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=AX();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,MX(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:jX,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 PX=Object.defineProperty,FX=(e,t,n)=>t in e?PX(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,IX=(e,t,n)=>FX(e,typeof t==`symbol`?t:t+``,n),LX=null;function RX(e){throw new kX(e.UTF8ToString(e.getLastOnigError()))}var zX=class e{constructor(t){IX(this,`utf16Length`),IX(this,`utf8Length`),IX(this,`utf16Value`),IX(this,`utf8Value`),IX(this,`utf16OffsetToUtf8`),IX(this,`utf8OffsetToUtf16`);let n=t.length,r=e._utf8ByteLength(t),i=r!==n,a=i?new Uint32Array(n+1):null;i&&(a[n]=r);let o=i?new Uint32Array(r+1):null;i&&(o[r]=n);let s=new Uint8Array(r),c=0;for(let e=0;e<n;e++){let r=t.charCodeAt(e),l=r,u=!1;if(r>=55296&&r<=56319&&e+1<n){let n=t.charCodeAt(e+1);n>=56320&&n<=57343&&(l=(r-55296<<10)+65536|n-56320,u=!0)}i&&(a[e]=c,u&&(a[e+1]=c),l<=127?o[c+0]=e:l<=2047?(o[c+0]=e,o[c+1]=e):l<=65535?(o[c+0]=e,o[c+1]=e,o[c+2]=e):(o[c+0]=e,o[c+1]=e,o[c+2]=e,o[c+3]=e)),l<=127?s[c++]=l:l<=2047?(s[c++]=192|(l&1984)>>>6,s[c++]=128|(l&63)>>>0):l<=65535?(s[c++]=224|(l&61440)>>>12,s[c++]=128|(l&4032)>>>6,s[c++]=128|(l&63)>>>0):(s[c++]=240|(l&1835008)>>>18,s[c++]=128|(l&258048)>>>12,s[c++]=128|(l&4032)>>>6,s[c++]=128|(l&63)>>>0),u&&e++}this.utf16Length=n,this.utf8Length=r,this.utf16Value=t,this.utf8Value=s,this.utf16OffsetToUtf8=a,this.utf8OffsetToUtf16=o}static _utf8ByteLength(e){let t=0;for(let n=0,r=e.length;n<r;n++){let i=e.charCodeAt(n),a=i,o=!1;if(i>=55296&&i<=56319&&n+1<r){let t=e.charCodeAt(n+1);t>=56320&&t<=57343&&(a=(i-55296<<10)+65536|t-56320,o=!0)}a<=127?t+=1:a<=2047?t+=2:a<=65535?t+=3:t+=4,o&&n++}return t}createString(e){let t=e.omalloc(this.utf8Length);return e.HEAPU8.set(this.utf8Value,t),t}},BX=class e{constructor(t){if(IX(this,`id`,++e.LAST_ID),IX(this,`_onigBinding`),IX(this,`content`),IX(this,`utf16Length`),IX(this,`utf8Length`),IX(this,`utf16OffsetToUtf8`),IX(this,`utf8OffsetToUtf16`),IX(this,`ptr`),!LX)throw new kX(`Must invoke loadWasm first.`);this._onigBinding=LX,this.content=t;let n=new zX(t);this.utf16Length=n.utf16Length,this.utf8Length=n.utf8Length,this.utf16OffsetToUtf8=n.utf16OffsetToUtf8,this.utf8OffsetToUtf16=n.utf8OffsetToUtf16,this.utf8Length<1e4&&!e._sharedPtrInUse?(e._sharedPtr||=LX.omalloc(1e4),e._sharedPtrInUse=!0,LX.HEAPU8.set(n.utf8Value,e._sharedPtr),this.ptr=e._sharedPtr):this.ptr=n.createString(LX)}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)}};IX(BX,`LAST_ID`,0),IX(BX,`_sharedPtr`,0),IX(BX,`_sharedPtrInUse`,!1);var VX=BX,HX=class{constructor(e){if(IX(this,`_onigBinding`),IX(this,`_ptr`),!LX)throw new kX(`Must invoke loadWasm first.`);let t=[],n=[];for(let r=0,i=e.length;r<i;r++){let i=new zX(e[r]);t[r]=i.createString(LX),n[r]=i.utf8Length}let r=LX.omalloc(4*e.length);LX.HEAPU32.set(t,r/4);let i=LX.omalloc(4*e.length);LX.HEAPU32.set(n,i/4);let a=LX.createOnigScanner(r,i,e.length);for(let n=0,r=e.length;n<r;n++)LX.ofree(t[n]);LX.ofree(i),LX.ofree(r),a===0&&RX(LX),this._onigBinding=LX,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 VX(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 UX(e){return typeof e.instantiator==`function`}function WX(e){return typeof e.default==`function`}function GX(e){return e.data!==void 0}function KX(e){return typeof Response<`u`&&e instanceof Response}function qX(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 JX;function YX(e){if(JX)return JX;async function t(){LX=await NX(async t=>{let n=e;return n=await n,typeof n==`function`&&(n=await n(t)),typeof n==`function`&&(n=await n(t)),UX(n)?n=await n.instantiator(t):WX(n)?n=await n.default(t):(GX(n)&&(n=n.data),KX(n)?n=typeof WebAssembly.instantiateStreaming==`function`?await ZX(n)(t):await QX(n)(t):qX(n)||n instanceof WebAssembly.Module?n=await XX(n)(t):`default`in n&&n.default instanceof WebAssembly.Module&&(n=await XX(n.default)(t))),`instance`in n&&(n=n.instance),`exports`in n&&(n=n.exports),n})}return JX=t(),JX}function XX(e){return t=>WebAssembly.instantiate(e,t)}function ZX(e){return t=>WebAssembly.instantiateStreaming(e,t)}function QX(e){return async t=>{let n=await e.arrayBuffer();return WebAssembly.instantiate(n,t)}}async function $X(e){return e&&await YX(e),{createScanner(e){return new HX(e.map(e=>typeof e==`string`?e:e.source))},createString(e){return new VX(e)}}}var eZ=xX({langs:DX,themes:OX,engine:()=>$X($(()=>import(`./wasm-DiIFv9DE.js`),[]))}),{codeToHtml:tZ,codeToHast:nZ,codeToTokens:rZ,codeToTokensBase:iZ,codeToTokensWithThemes:aZ,getSingletonHighlighter:oZ,getLastGrammarState:sZ}=CX(eZ,{guessEmbeddedLanguages:sY}),cZ=4294967295,lZ=class{constructor(e,t={}){this.patterns=e,this.options=t;let{forgiving:n=!1,cache:r,regexConstructor:i}=t;if(!i)throw Error("Option `regexConstructor` is not provided");this.regexps=e.map(e=>{if(typeof e!=`string`)return e;let t=r?.get(e);if(t){if(t instanceof RegExp)return t;if(n)return null;throw t}try{let t=i(e);return r?.set(e,t),t}catch(t){if(r?.set(e,t),n)return null;throw t}})}regexps;findNextMatchSync(e,t,n){let r=typeof e==`string`?e:e.content,i=[];function a(e,t,n=0){return{index:e,captureIndices:t.indices.map(e=>e==null?{start:cZ,end:cZ,length:0}:{start:e[0]+n,end:e[1]+n,length:e[1]-e[0]})}}for(let e=0;e<this.regexps.length;e++){let n=this.regexps[e];if(n)try{n.lastIndex=t;let o=n.exec(r);if(!o)continue;if(o.index===t)return a(e,o,0);i.push([e,o,0])}catch(e){if(this.options.forgiving)continue;throw e}}if(i.length){let e=Math.min(...i.map(e=>e[1].index));for(let[t,n,r]of i)if(n.index===e)return a(t,n,r)}return null}};function uZ(e,t){return SG(e,{global:!0,hasIndices:!0,lazyCompileLength:3e3,rules:{allowOrphanBackrefs:!0,asciiWordBoundaries:!0,captureGroup:!0,recursionLimit:5,singleline:!0},...t})}function dZ(e={}){let t=Object.assign({target:`auto`,cache:new Map},e);return t.regexConstructor||=e=>uZ(e,{target:t.target}),{createScanner(e){return new lZ(e,t)},createString(e){return{content:e}}}}async function fZ(e){if(JJ())throw Error(`resolveLanguage("${e}") cannot be called from a worker context. Languages must be pre-resolved on the main thread and passed to the worker via the resolvedLanguages parameter.`);let t=WJ.get(e);if(t!=null)return t;try{let t=GJ.get(e);if(t==null&&Object.prototype.hasOwnProperty.call(DX,e)&&(t=DX[e]),t==null)throw Error(`resolveLanguage: "${e}" not found in bundled or custom languages`);let n=t().then(({default:t})=>{let n={name:e,data:t};return UJ.has(e)||UJ.set(e,n),n});return WJ.set(e,n),await n}finally{WJ.delete(e)}}function pZ(e){return UJ.get(e)??fZ(e)}async function mZ(e){if(JJ())throw Error(`resolveTheme("${e}") cannot be called from a worker context. Themes must be pre-resolved on the main thread and passed to the worker via the resolvedLanguages parameter.`);let t=zJ.get(e);if(t!=null)return t;try{let t=BJ.get(e)??OX[e];if(t==null)throw Error(`resolveTheme: No valid loader for ${e}`);let n=t().then(t=>hZ(e,`default`in t?t.default:t));zJ.set(e,n);let r=await n;if(r.name!==e)throw Error(`resolvedTheme: themeName: ${e} does not match theme.name: ${r.name}`);return RJ.set(r.name,r),r}finally{zJ.delete(e)}}function hZ(e,t){return RJ.get(e)??(t=sX(t),RJ.set(e,t),t)}function gZ(e){return RJ.get(e)??mZ(e)}function _Z(e,t){if(BJ.has(e)){console.error(`SharedHighlight.registerCustomTheme: theme name already registered`,e);return}BJ.set(e,t)}var vZ;async function yZ({themes:e,langs:t,preferredHighlighter:n=`shiki-js`}){vZ??=eZ({themes:[],langs:[`text`],engine:n===`shiki-wasm`?$X($(()=>import(`./wasm-DiIFv9DE.js`),[])):dZ()});let r=xZ(vZ)?await vZ:vZ;vZ=r;let i=[];for(let e of t){if(e===`text`||e===`ansi`)continue;let t=pZ(e);`then`in t?i.push(t):qJ(t,r)}let a=[];for(let t of e){let e=gZ(t);`then`in e?a.push(e):HJ(e,vZ)}return(i.length>0||a.length>0)&&await Promise.all([Promise.all(i).then(e=>{qJ(e,r)}),Promise.all(a).then(e=>{HJ(e,r)})]),r}function bZ(){if(vZ!=null&&!(`then`in vZ))return vZ}function xZ(e=vZ){return e!=null&&`then`in e}_Z(`pierre-dark`,async()=>{let{default:e}=await $(async()=>{let{default:e}=await import(`./pierre-dark-CBqOR10c.js`);return{default:e}},[]);return{...e,name:`pierre-dark`}}),_Z(`pierre-light`,async()=>{let{default:e}=await $(async()=>{let{default:e}=await import(`./pierre-light-sgwdVCEP.js`);return{default:e}},[]);return{...e,name:`pierre-light`}});function SZ(e=DJ){let t=[];return typeof e==`string`?t.push(e):(t.push(e.dark),t.push(e.light)),t}function CZ(e,t){return e==null||t==null||typeof e==`string`||typeof t==`string`?e===t:e.dark===t.dark&&e.light===t.light}var wZ=new Map,TZ={"1c":`1c`,abap:`abap`,as:`actionscript-3`,ada:`ada`,adb:`ada`,ads:`ada`,adoc:`asciidoc`,asciidoc:`asciidoc`,"component.html":`angular-html`,"component.ts":`angular-ts`,conf:`nginx`,htaccess:`apache`,cls:`tex`,trigger:`apex`,apl:`apl`,applescript:`applescript`,scpt:`applescript`,ara:`ara`,asm:`asm`,s:`riscv`,astro:`astro`,awk:`awk`,bal:`ballerina`,sh:`zsh`,bash:`zsh`,bat:`cmd`,cmd:`cmd`,be:`berry`,beancount:`beancount`,bib:`bibtex`,bicep:`bicep`,"blade.php":`blade`,bsl:`bsl`,c:`c`,h:`objective-cpp`,cs:`csharp`,cpp:`cpp`,hpp:`cpp`,cc:`cpp`,cxx:`cpp`,hh:`cpp`,cdc:`cdc`,cairo:`cairo`,clar:`clarity`,clj:`clojure`,cljs:`clojure`,cljc:`clojure`,soy:`soy`,cmake:`cmake`,"CMakeLists.txt":`cmake`,cob:`cobol`,cbl:`cobol`,cobol:`cobol`,CODEOWNERS:`codeowners`,ql:`ql`,coffee:`coffeescript`,lisp:`lisp`,cl:`lisp`,lsp:`lisp`,log:`log`,v:`verilog`,cql:`cql`,cr:`crystal`,css:`css`,csv:`csv`,cue:`cue`,cypher:`cypher`,cyp:`cypher`,d:`d`,dart:`dart`,dax:`dax`,desktop:`desktop`,diff:`diff`,patch:`diff`,Dockerfile:`dockerfile`,dockerfile:`dockerfile`,env:`dotenv`,dm:`dream-maker`,edge:`edge`,el:`emacs-lisp`,ex:`elixir`,exs:`elixir`,elm:`elm`,erb:`erb`,erl:`erlang`,hrl:`erlang`,f:`fortran-fixed-form`,for:`fortran-fixed-form`,fs:`fsharp`,fsi:`fsharp`,fsx:`fsharp`,f03:`f03`,f08:`f08`,f18:`f18`,f77:`f77`,f90:`fortran-free-form`,f95:`fortran-free-form`,fnl:`fennel`,fish:`fish`,ftl:`ftl`,tres:`gdresource`,res:`gdresource`,gd:`gdscript`,gdshader:`gdshader`,gs:`genie`,feature:`gherkin`,COMMIT_EDITMSG:`git-commit`,"git-rebase-todo":`git-rebase`,gjs:`glimmer-js`,gleam:`gleam`,gts:`glimmer-ts`,glsl:`glsl`,vert:`glsl`,frag:`glsl`,shader:`shaderlab`,gp:`gnuplot`,plt:`gnuplot`,gnuplot:`gnuplot`,go:`go`,graphql:`graphql`,gql:`graphql`,groovy:`groovy`,gvy:`groovy`,hack:`hack`,haml:`haml`,hbs:`handlebars`,handlebars:`handlebars`,hs:`haskell`,lhs:`haskell`,hx:`haxe`,hcl:`hcl`,hjson:`hjson`,hlsl:`hlsl`,fx:`hlsl`,html:`html`,htm:`html`,http:`http`,rest:`http`,hxml:`hxml`,hy:`hy`,imba:`imba`,ini:`ini`,cfg:`ini`,jade:`pug`,pug:`pug`,java:`java`,js:`javascript`,mjs:`javascript`,cjs:`javascript`,jinja:`jinja`,jinja2:`jinja`,j2:`jinja`,jison:`jison`,jl:`julia`,json:`json`,json5:`json5`,jsonc:`jsonc`,jsonl:`jsonl`,jsonnet:`jsonnet`,libsonnet:`jsonnet`,jssm:`jssm`,jsx:`jsx`,kt:`kotlin`,kts:`kts`,kql:`kusto`,tex:`tex`,ltx:`tex`,lean:`lean4`,less:`less`,liquid:`liquid`,lit:`lit`,ll:`llvm`,logo:`logo`,lua:`lua`,luau:`luau`,Makefile:`makefile`,mk:`makefile`,makefile:`makefile`,md:`markdown`,markdown:`markdown`,marko:`marko`,m:`wolfram`,mat:`matlab`,mdc:`mdc`,mdx:`mdx`,wiki:`wikitext`,mediawiki:`wikitext`,mmd:`mermaid`,mermaid:`mermaid`,mips:`mipsasm`,mojo:`mojo`,"🔥":`mojo`,move:`move`,nar:`narrat`,nf:`nextflow`,nim:`nim`,nims:`nim`,nimble:`nim`,nix:`nix`,nu:`nushell`,mm:`objective-cpp`,ml:`ocaml`,mli:`ocaml`,mll:`ocaml`,mly:`ocaml`,pas:`pascal`,p:`pascal`,pl:`prolog`,pm:`perl`,t:`perl`,raku:`raku`,p6:`raku`,pl6:`raku`,php:`php`,phtml:`php`,pls:`plsql`,sql:`sql`,po:`po`,polar:`polar`,pcss:`postcss`,pot:`pot`,potx:`potx`,pq:`powerquery`,pqm:`powerquery`,ps1:`powershell`,psm1:`powershell`,psd1:`powershell`,prisma:`prisma`,pro:`prolog`,P:`prolog`,properties:`properties`,proto:`protobuf`,pp:`puppet`,purs:`purescript`,py:`python`,pyw:`python`,pyi:`python`,qml:`qml`,qmldir:`qmldir`,qss:`qss`,r:`r`,R:`r`,rkt:`racket`,rktl:`racket`,razor:`razor`,cshtml:`razor`,rb:`ruby`,rbw:`ruby`,reg:`reg`,regex:`regexp`,rel:`rel`,rs:`rust`,rst:`rst`,rake:`ruby`,gemspec:`ruby`,sas:`sas`,sass:`sass`,scala:`scala`,sc:`scala`,scm:`scheme`,ss:`scheme`,sld:`scheme`,scss:`scss`,sdbl:`sdbl`,shadergraph:`shader`,st:`smalltalk`,sol:`solidity`,sparql:`sparql`,rq:`sparql`,spl:`splunk`,config:`ssh-config`,do:`stata`,ado:`stata`,dta:`stata`,styl:`stylus`,stylus:`stylus`,svelte:`svelte`,swift:`swift`,sv:`system-verilog`,svh:`system-verilog`,service:`systemd`,socket:`systemd`,device:`systemd`,timer:`systemd`,talon:`talonscript`,tasl:`tasl`,tcl:`tcl`,templ:`templ`,tf:`tf`,tfvars:`tfvars`,toml:`toml`,ts:`typescript`,tsp:`typespec`,tsv:`tsv`,tsx:`tsx`,ttl:`turtle`,twig:`twig`,typ:`typst`,vv:`v`,vala:`vala`,vapi:`vala`,vb:`vb`,vbs:`vb`,bas:`vb`,vh:`verilog`,vhd:`vhdl`,vhdl:`vhdl`,vim:`vimscript`,vue:`vue`,"vine.ts":`vue-vine`,vy:`vyper`,wasm:`wasm`,wat:`wasm`,wy:`文言`,wgsl:`wgsl`,wit:`wit`,wl:`wolfram`,nb:`wolfram`,xml:`xml`,xsl:`xsl`,xslt:`xsl`,yaml:`yaml`,yml:`yml`,zs:`zenscript`,zig:`zig`,zsh:`zsh`,sty:`tex`};function EZ(e){if(wZ.has(e))return wZ.get(e)??`text`;if(TZ[e]!=null)return TZ[e];let t=e.match(/\.([^/\\]+\.[^/\\]+)$/);if(t!=null){if(wZ.has(t[1]))return wZ.get(t[1])??`text`;if(TZ[t[1]]!=null)return TZ[t[1]]??`text`}let n=e.match(/\.([^.]+)$/)?.[1]??``;return wZ.has(n)?wZ.get(n)??`text`:TZ[n]??`text`}function DZ(e){return e.replace(/\n$|\r\n$/,``)}function OZ(e){return{type:`text`,value:e}}function kZ({tagName:e,children:t=[],properties:n={}}){return{type:`element`,tagName:e,properties:n,children:t}}function AZ({name:e,width:t=16,height:n=16,properties:r}){return kZ({tagName:`svg`,properties:{width:t,height:n,viewBox:`0 0 16 16`,...r},children:[kZ({tagName:`use`,properties:{href:`#${e.replace(/^#/,``)}`}})]})}function jZ(e){let t=e.children[0];for(;t!=null;){if(t.type===`element`&&t.tagName===`code`)return t;t=`children`in t?t.children[0]:null}}function MZ(e){return kZ({tagName:`div`,properties:{"data-gutter":``},children:e})}function NZ(e,t,n,r={}){return kZ({tagName:`div`,properties:{"data-line-type":e,"data-column-number":t,"data-line-index":n,...r},children:t==null?void 0:[kZ({tagName:`span`,properties:{"data-line-number-content":``},children:[OZ(`${t}`)]})]})}function PZ(e,t,n){return kZ({tagName:`div`,properties:{"data-gutter-buffer":t,"data-buffer-size":n,"data-line-type":t===`annotation`?void 0:e,style:t===`annotation`?`grid-row: span ${n};`:`grid-row: span ${n};min-height:calc(${n} * 1lh);`}})}function FZ(e,t,n){let r=typeof n.lineInfo==`function`?n.lineInfo(t):n.lineInfo[t-1];if(r==null){let r=`processLine: line ${t}, contains no state.lineInfo`;throw console.error(r,{node:e,line:t,state:n}),Error(r)}return e.tagName=`div`,e.properties[`data-line`]=r.lineNumber,e.properties[`data-alt-line`]=r.altLineNumber,e.properties[`data-line-type`]=r.type,e.properties[`data-line-index`]=r.lineIndex,e.children.length===0&&e.children.push(OZ(`
357
- `)),e}var IZ=Symbol(`no-token`),LZ=Symbol(`multiple-tokens`);function RZ(e){let t=zZ(e);if(t!=null)return t;let n=IZ,r=[],i=[],a,o=()=>{if(i.length===0||a==null){i=[],a=void 0;return}if(i.length===1){let e=i[0];if(e?.type===`element`){VZ(e,a);for(let t of e.children)BZ(t)}else BZ(e);r.push(e),i=[],a=void 0;return}for(let e of i)BZ(e);r.push(kZ({tagName:`span`,properties:{"data-char":a},children:i})),i=[],a=void 0},s=e=>{if(e!==IZ){if(e===LZ){n=LZ;return}if(n===IZ){n=e;return}n!==e&&(n=LZ)}};for(let t of e.children){let e=t.type===`element`?RZ(t):IZ;if(s(e),typeof e!=`number`){o(),r.push(t);continue}a!=null&&a!==e&&o(),a??=e,i.push(t)}return o(),e.children=r,n}function zZ(e){let t=e.properties[`data-char`];if(typeof t==`number`)return t}function BZ(e){if(e.type===`element`){e.properties[`data-char`]=void 0;for(let t of e.children)BZ(t)}}function VZ(e,t){e.properties[`data-char`]=t}function HZ(e={}){let{classPrefix:t=`__shiki_`,classSuffix:n=``,classReplacer:r=e=>e}=e,i=new Map;function a(e){return Object.entries(e).map(([e,t])=>`${e}:${t}`).join(`;`)}function o(e){let o=t+UZ(typeof e==`string`?e:a(e))+n;return o=r(o),i.has(o)||i.set(o,typeof e==`string`?e:{...e}),o}return{name:`@shikijs/transformers:style-to-class`,pre(e){if(!e.properties.style)return;let t=o(e.properties.style);delete e.properties.style,this.addClassToHast(e,t)},tokens(e){for(let t of e)for(let e of t){if(!e.htmlStyle)continue;let t=o(e.htmlStyle);e.htmlStyle={},e.htmlAttrs||={},e.htmlAttrs.class?e.htmlAttrs.class+=` ${t}`:e.htmlAttrs.class=t}},getClassRegistry(){return i},getCSS(){let e=``;for(let[t,n]of i.entries())e+=`.${t}{${typeof n==`string`?n:a(n)}}`;return e},clearRegistry(){i.clear()}}}function UZ(e,t=0){let n=3735928559^t,r=1103547991^t;for(let t=0,i;t<e.length;t++)i=e.charCodeAt(t),n=Math.imul(n^i,2654435761),r=Math.imul(r^i,1597334677);return n=Math.imul(n^n>>>16,2246822507),n^=Math.imul(r^r>>>13,3266489909),r=Math.imul(r^r>>>16,2246822507),r^=Math.imul(n^n>>>13,3266489909),(4294967296*(2097151&r)+(n>>>0)).toString(36).slice(0,6)}function WZ(e=!1,t=!1){let n={lineInfo:[]},r=[{line(e){return delete e.properties.class,e},pre(t){let r=jZ(t),i=[];if(r!=null){let t=1;for(let a of r.children)a.type===`element`&&(e&&RZ(a),i.push(FZ(a,t,n)),t++);r.children=i}return t},...e?{tokens(e){for(let t of e){let e=0;for(let n of t){let t=n;t.__lineChar??=e,e+=n.content.length}}},preprocess(e,t){t.mergeWhitespaces=`never`},span(e,t,n,r,i){if(i?.offset!=null&&i.content!=null){let t=i.__lineChar;return t!=null&&(e.properties[`data-char`]=t),e}return e}}:null}];return t&&r.push(KZ,GZ),{state:n,transformers:r,toClass:GZ}}var GZ=HZ({classPrefix:`hl-`}),KZ={name:`token-style-normalizer`,tokens(e){for(let t of e)for(let e of t){if(e.htmlStyle!=null)continue;let t={};e.color!=null&&(t.color=e.color),e.bgColor!=null&&(t[`background-color`]=e.bgColor),e.fontStyle!=null&&e.fontStyle!==0&&(e.fontStyle&1&&(t[`font-style`]=`italic`),e.fontStyle&2&&(t[`font-weight`]=`bold`),e.fontStyle&4&&(t[`text-decoration`]=`underline`)),Object.keys(t).length>0&&(e.htmlStyle=t)}}};function qZ(e){return`--${e===`token`?`diffs-token`:`diffs`}-`}function JZ({theme:e=DJ,highlighter:t,prefix:n}){let r=``;if(typeof e==`string`){let i=t.getTheme(e);r+=`color:${i.fg};`,r+=`background-color:${i.bg};`,r+=`${qZ(`global`)}fg:${i.fg};`,r+=`${qZ(`global`)}bg:${i.bg};`,r+=YZ(i,n)}else{let n=t.getTheme(e.dark);r+=`${qZ(`global`)}dark:${n.fg};`,r+=`${qZ(`global`)}dark-bg:${n.bg};`,r+=YZ(n,`dark`),n=t.getTheme(e.light),r+=`${qZ(`global`)}light:${n.fg};`,r+=`${qZ(`global`)}light-bg:${n.bg};`,r+=YZ(n,`light`)}return r}function YZ(e,t){t=t==null?``:`${t}-`;let n=``,r=e.colors?.[`gitDecoration.addedResourceForeground`]??e.colors?.[`terminal.ansiGreen`];r!=null&&(n+=`${qZ(`global`)}${t}addition-color:${r};`);let i=e.colors?.[`gitDecoration.deletedResourceForeground`]??e.colors?.[`terminal.ansiRed`];i!=null&&(n+=`${qZ(`global`)}${t}deletion-color:${i};`);let a=e.colors?.[`gitDecoration.modifiedResourceForeground`]??e.colors?.[`terminal.ansiBlue`];return a!=null&&(n+=`${qZ(`global`)}${t}modified-color:${a};`),n}function XZ(e){let t=e.children[0];for(;t!=null;){if(t.type===`element`&&t.tagName===`code`)return t.children;t=`children`in t?t.children[0]:null}throw console.error(e),Error(`getLineNodes: Unable to find children`)}function ZZ(e,t){return e?.cacheKey===t?.cacheKey&&e?.contents===t?.contents&&e?.name===t?.name&&e?.lang===t?.lang}function QZ(e,t){return CZ(e.theme,t.theme)&&e.useTokenTransformer===t.useTokenTransformer&&e.tokenizeMaxLineLength===t.tokenizeMaxLineLength&&e.lineDiffType===t.lineDiffType&&e.maxLineDiffLength===t.maxLineDiffLength}function $Z(e){let t=e.lang??EZ(e.name),n=e.lang??(e.prevName==null?`text`:EZ(e.prevName));return t===`text`&&n===`text`}function eQ({diff:e,diffStyle:t,startingLine:n=0,totalLines:r=1/0,expandedHunks:i,collapsedContextThreshold:a=1,callback:o}){let s={finalHunk:e.hunks.at(-1),viewportStart:n,viewportEnd:n+r,isWindowedHighlight:n>0||r<1/0,splitCount:0,unifiedCount:0,shouldBreak(){if(!s.isWindowedHighlight)return!1;let e=s.unifiedCount>=n+r,i=s.splitCount>=n+r;return t===`unified`?e:(t===`split`||e)&&i},shouldSkip(e,r){if(!s.isWindowedHighlight)return!1;let i=s.unifiedCount+e<n,a=s.splitCount+r<n;return t===`unified`?i:(t===`split`||i)&&a},incrementCounts(e,n){(t===`unified`||t===`both`)&&(s.unifiedCount+=e),(t===`split`||t===`both`)&&(s.splitCount+=n)},isInWindow(e,n){if(!s.isWindowedHighlight)return!0;let r=s.isInUnifiedWindow(e),i=s.isInSplitWindow(n);return t===`unified`?r:t===`split`?i:r||i},isInUnifiedWindow(e){return!s.isWindowedHighlight||s.unifiedCount>=n-e&&s.unifiedCount<n+r},isInSplitWindow(e){return!s.isWindowedHighlight||s.splitCount>=n-e&&s.splitCount<n+r},emit(e,n=!1){return n||(t===`unified`?s.incrementCounts(1,0):t===`split`?s.incrementCounts(0,1):s.incrementCounts(1,1)),o(e)??!1}};hunkIterator:for(let[n,r]of e.hunks.entries()){if(s.shouldBreak())break;let o=tQ(e.isPartial,r.collapsedBefore,i,n,a),c=(()=>{if(r!==s.finalHunk||!nQ(e))return;let t=e.additionLines.length-(r.additionLineIndex+r.additionCount),n=e.deletionLines.length-(r.deletionLineIndex+r.deletionCount);if(t!==n)throw Error(`iterateOverDiff: trailing context mismatch (additions=${t}, deletions=${n}) for ${e.name}`);let o=Math.min(t,n);return tQ(e.isPartial,o,i,e.hunks.length,a)})(),l=o.fromStart+o.fromEnd;function u(e,n){return c==null||c.collapsedLines<=0||c.fromStart+c.fromEnd>0?0:t===`unified`?e===r.unifiedLineStart+r.unifiedLineCount-1?c.collapsedLines:0:n===r.splitLineStart+r.splitLineCount-1?c.collapsedLines:0}function d(){if(o.collapsedLines===0)return 0;let e=o.collapsedLines;return o.collapsedLines=0,e}if(s.shouldSkip(l,l))s.incrementCounts(l,l),d();else{let e=r.unifiedLineStart-o.rangeSize,t=r.splitLineStart-o.rangeSize,i=r.deletionLineIndex-o.rangeSize,a=r.additionLineIndex-o.rangeSize,c=r.deletionStart-o.rangeSize,l=r.additionStart-o.rangeSize,u=0;for(;u<o.fromStart;){if(s.isInWindow(0,0)){if(s.emit({hunkIndex:n,hunk:r,collapsedBefore:0,collapsedAfter:0,type:`context-expanded`,deletionLine:{lineNumber:c+u,lineIndex:i+u,noEOFCR:!1,unifiedLineIndex:e+u,splitLineIndex:t+u},additionLine:{unifiedLineIndex:e+u,splitLineIndex:t+u,lineIndex:a+u,lineNumber:l+u,noEOFCR:!1}}))break hunkIterator}else s.incrementCounts(1,1);u++}for(e=r.unifiedLineStart-o.fromEnd,t=r.splitLineStart-o.fromEnd,i=r.deletionLineIndex-o.fromEnd,a=r.additionLineIndex-o.fromEnd,c=r.deletionStart-o.fromEnd,l=r.additionStart-o.fromEnd,u=0;u<o.fromEnd;){if(s.isInWindow(0,0)){if(s.emit({hunkIndex:n,hunk:r,collapsedBefore:d(),collapsedAfter:0,type:`context-expanded`,deletionLine:{lineNumber:c+u,lineIndex:i+u,noEOFCR:!1,unifiedLineIndex:e+u,splitLineIndex:t+u},additionLine:{unifiedLineIndex:e+u,splitLineIndex:t+u,lineIndex:a+u,lineNumber:l+u,noEOFCR:!1}}))break hunkIterator}else s.incrementCounts(1,1);u++}}let f=r.unifiedLineStart,p=r.splitLineStart,m=r.deletionLineIndex,h=r.additionLineIndex,g=r.deletionStart,_=r.additionStart,v=r.hunkContent.at(-1);for(let e of r.hunkContent){if(s.shouldBreak())break hunkIterator;let i=e===v;if(e.type===`context`){if(s.shouldSkip(e.lines,e.lines))s.incrementCounts(e.lines,e.lines),d();else{let t=0;for(;t<e.lines;){if(s.isInWindow(0,0)){let a=i&&t===e.lines-1,o=f+t,c=p+t;if(s.emit({hunkIndex:n,hunk:r,collapsedBefore:d(),collapsedAfter:u(o,c),type:`context`,deletionLine:{lineNumber:g+t,lineIndex:m+t,noEOFCR:a&&r.noEOFCRDeletions,unifiedLineIndex:o,splitLineIndex:c},additionLine:{unifiedLineIndex:o,splitLineIndex:c,lineIndex:h+t,lineNumber:_+t,noEOFCR:a&&r.noEOFCRAdditions}}))break hunkIterator}else s.incrementCounts(1,1);t++}}f+=e.lines,p+=e.lines,m+=e.lines,h+=e.lines,g+=e.lines,_+=e.lines}else{let a=Math.max(e.deletions,e.additions),o=e.deletions+e.additions;if(!s.shouldSkip(o,a)){let c=rQ(s,e,t);for(let[l,v]of c)for(let c=l;c<v;c++){let l=u(f+c,t===`unified`?p+(c<e.deletions?c:c-e.deletions):p+c);if(s.emit(iQ({hunkIndex:n,hunk:r,collapsedBefore:d(),collapsedAfter:l,diffStyle:t,index:c,unifiedLineIndex:f,splitLineIndex:p,additionLineIndex:h,deletionLineIndex:m,additionLineNumber:_,deletionLineNumber:g,content:e,isLastContent:i,unifiedCount:o,splitCount:a}),!0))break hunkIterator}}d(),s.incrementCounts(o,a),f+=o,p+=a,m+=e.deletions,h+=e.additions,g+=e.deletions,_+=e.additions}}if(c!=null){let{collapsedLines:t,fromStart:n,fromEnd:r}=c,i=n+r,a=0;for(;a<i;){if(s.shouldBreak())break hunkIterator;if(s.isInWindow(0,0)){let n=a===i-1;if(s.emit({hunkIndex:e.hunks.length,hunk:void 0,collapsedBefore:0,collapsedAfter:n?t:0,type:`context-expanded`,deletionLine:{lineNumber:g+a,lineIndex:m+a,noEOFCR:!1,unifiedLineIndex:f+a,splitLineIndex:p+a},additionLine:{unifiedLineIndex:f+a,splitLineIndex:p+a,lineIndex:h+a,lineNumber:_+a,noEOFCR:!1}}))break hunkIterator}else s.incrementCounts(1,1);a++}}}}function tQ(e,t,n,r,i){if(t=Math.max(t,0),t===0||e)return{fromStart:0,fromEnd:0,rangeSize:t,collapsedLines:Math.max(t,0)};if(n===!0||t<=i)return{fromStart:t,fromEnd:0,rangeSize:t,collapsedLines:0};let a=n?.get(r),o=Math.min(Math.max(a?.fromStart??0,0),t),s=Math.min(Math.max(a?.fromEnd??0,0),t),c=o+s,l=c>=t;return{fromStart:l?t:o,fromEnd:l?0:s,rangeSize:t,collapsedLines:Math.max(t-c,0)}}function nQ(e){let t=e.hunks.at(-1);return t==null||e.isPartial||e.additionLines.length===0||e.deletionLines.length===0?!1:t.additionLineIndex+t.additionCount<e.additionLines.length||t.deletionLineIndex+t.deletionCount<e.deletionLines.length}function rQ(e,t,n){if(!e.isWindowedHighlight)return[[0,n===`unified`?t.deletions+t.additions:Math.max(t.deletions,t.additions)]];let r=n!==`split`,i=n!==`unified`,a=n===`unified`?`unified`:`split`,o=[];function s(t,n){if(t+n<=e.viewportStart||t>=e.viewportEnd)return;let r=Math.max(0,e.viewportStart-t),i=Math.min(n,e.viewportEnd-t);return i>r?[r,i]:void 0}function c(e,n){return a===`split`?e:n===`additions`?[e[0]+t.deletions,e[1]+t.deletions]:e}function l(e,t){if(e==null)return;let[n,r]=c(e,t);r>n&&o.push([n,r])}if(r&&(l(s(e.unifiedCount,t.deletions),`deletions`),l(s(e.unifiedCount+t.deletions,t.additions),`additions`)),i&&(l(s(e.splitCount,t.deletions),`deletions`),l(s(e.splitCount,t.additions),`additions`)),o.length===0)return o;o.sort((e,t)=>e[0]-t[0]);let u=[o[0]];for(let[e,t]of o.slice(1)){let n=u[u.length-1];e<=n[1]?n[1]=Math.max(n[1],t):u.push([e,t])}return u}function iQ({hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,diffStyle:i,index:a,unifiedLineIndex:o,splitLineIndex:s,additionLineIndex:c,deletionLineIndex:l,additionLineNumber:u,deletionLineNumber:d,content:f,isLastContent:p,unifiedCount:m,splitCount:h}){let g=a<f.deletions?o+a:void 0,_=i===`unified`?a>=f.deletions?o+a:void 0:a<f.additions?o+f.deletions+a:void 0,v=i===`unified`?s+(a<f.deletions?a:a-f.deletions):s+a,y=a<f.deletions?l+a:void 0,b=a<f.deletions?d+a:void 0,x=i===`unified`?a>=f.deletions?c+(a-f.deletions):void 0:a<f.additions?c+a:void 0,S=i===`unified`?a>=f.deletions?u+(a-f.deletions):void 0:a<f.additions?u+a:void 0,C=i===`unified`?p&&a===f.deletions-1&&t.noEOFCRDeletions:p&&a===h-1&&t.noEOFCRDeletions,w=i===`unified`?p&&a===m-1&&t.noEOFCRAdditions:p&&a===h-1&&t.noEOFCRAdditions,T=y!=null&&b!=null&&g!=null?{lineNumber:b,lineIndex:y,noEOFCR:C,unifiedLineIndex:g,splitLineIndex:v}:void 0,E=x!=null&&S!=null&&_!=null?{unifiedLineIndex:_,splitLineIndex:v,lineIndex:x,lineNumber:S,noEOFCR:w}:void 0;if(T==null&&E!=null)return{type:`change`,hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:void 0,additionLine:E};if(T!=null&&E==null)return{type:`change`,hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:T,additionLine:void 0};if(T==null||E==null)throw Error(`iterateOverDiff: missing change line data`);return{type:`change`,hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:T,additionLine:E}}var aQ=class{diff(e,t,n={}){let r;typeof n==`function`?(r=n,n={}):`callback`in n&&(r=n.callback);let i=this.castInput(e,n),a=this.castInput(t,n),o=this.removeEmpty(this.tokenize(i,n)),s=this.removeEmpty(this.tokenize(a,n));return this.diffWithOptionsObj(o,s,n,r)}diffWithOptionsObj(e,t,n,r){let i=e=>{if(e=this.postProcess(e,n),r){setTimeout(function(){r(e)},0);return}else return e},a=t.length,o=e.length,s=1,c=a+o;n.maxEditLength!=null&&(c=Math.min(c,n.maxEditLength));let l=n.timeout??1/0,u=Date.now()+l,d=[{oldPos:-1,lastComponent:void 0}],f=this.extractCommon(d[0],t,e,0,n);if(d[0].oldPos+1>=o&&f+1>=a)return i(this.buildValues(d[0].lastComponent,t,e));let p=-1/0,m=1/0,h=()=>{for(let r=Math.max(p,-s);r<=Math.min(m,s);r+=2){let s,c=d[r-1],l=d[r+1];c&&(d[r-1]=void 0);let u=!1;if(l){let e=l.oldPos-r;u=l&&0<=e&&e<a}let h=c&&c.oldPos+1<o;if(!u&&!h){d[r]=void 0;continue}if(s=!h||u&&c.oldPos<l.oldPos?this.addToPath(l,!0,!1,0,n):this.addToPath(c,!1,!0,1,n),f=this.extractCommon(s,t,e,r,n),s.oldPos+1>=o&&f+1>=a)return i(this.buildValues(s.lastComponent,t,e))||!0;d[r]=s,s.oldPos+1>=o&&(m=Math.min(m,r-1)),f+1>=a&&(p=Math.max(p,r+1))}s++};if(r)(function e(){setTimeout(function(){if(s>c||Date.now()>u)return r(void 0);h()||e()},0)})();else for(;s<=c&&Date.now()<=u;){let e=h();if(e)return e}}addToPath(e,t,n,r,i){let a=e.lastComponent;return a&&!i.oneChangePerToken&&a.added===t&&a.removed===n?{oldPos:e.oldPos+r,lastComponent:{count:a.count+1,added:t,removed:n,previousComponent:a.previousComponent}}:{oldPos:e.oldPos+r,lastComponent:{count:1,added:t,removed:n,previousComponent:a}}}extractCommon(e,t,n,r,i){let a=t.length,o=n.length,s=e.oldPos,c=s-r,l=0;for(;c+1<a&&s+1<o&&this.equals(n[s+1],t[c+1],i);)c++,s++,l++,i.oneChangePerToken&&(e.lastComponent={count:1,previousComponent:e.lastComponent,added:!1,removed:!1});return l&&!i.oneChangePerToken&&(e.lastComponent={count:l,previousComponent:e.lastComponent,added:!1,removed:!1}),e.oldPos=s,c}equals(e,t,n){return n.comparator?n.comparator(e,t):e===t||!!n.ignoreCase&&e.toLowerCase()===t.toLowerCase()}removeEmpty(e){let t=[];for(let n=0;n<e.length;n++)e[n]&&t.push(e[n]);return t}castInput(e,t){return e}tokenize(e,t){return Array.from(e)}join(e){return e.join(``)}postProcess(e,t){return e}get useLongestToken(){return!1}buildValues(e,t,n){let r=[],i;for(;e;)r.push(e),i=e.previousComponent,delete e.previousComponent,e=i;r.reverse();let a=r.length,o=0,s=0,c=0;for(;o<a;o++){let e=r[o];if(e.removed)e.value=this.join(n.slice(c,c+e.count)),c+=e.count;else{if(!e.added&&this.useLongestToken){let r=t.slice(s,s+e.count);r=r.map(function(e,t){let r=n[c+t];return r.length>e.length?r:e}),e.value=this.join(r)}else e.value=this.join(t.slice(s,s+e.count));s+=e.count,e.added||(c+=e.count)}}return r}},oQ=new class extends aQ{};function sQ(e,t,n){return oQ.diff(e,t,n)}function cQ(e,t){let n;for(n=0;n<e.length&&n<t.length;n++)if(e[n]!=t[n])return e.slice(0,n);return e.slice(0,n)}function lQ(e,t){let n;if(!e||!t||e[e.length-1]!=t[t.length-1])return``;for(n=0;n<e.length&&n<t.length;n++)if(e[e.length-(n+1)]!=t[t.length-(n+1)])return e.slice(-n);return e.slice(-n)}function uQ(e,t,n){if(e.slice(0,t.length)!=t)throw Error(`string ${JSON.stringify(e)} doesn't start with prefix ${JSON.stringify(t)}; this is a bug`);return n+e.slice(t.length)}function dQ(e,t,n){if(!t)return e+n;if(e.slice(-t.length)!=t)throw Error(`string ${JSON.stringify(e)} doesn't end with suffix ${JSON.stringify(t)}; this is a bug`);return e.slice(0,-t.length)+n}function fQ(e,t){return uQ(e,t,``)}function pQ(e,t){return dQ(e,t,``)}function mQ(e,t){return t.slice(0,hQ(e,t))}function hQ(e,t){let n=0;e.length>t.length&&(n=e.length-t.length);let r=t.length;e.length<t.length&&(r=e.length);let i=Array(r),a=0;i[0]=0;for(let e=1;e<r;e++){for(t[e]==t[a]?i[e]=i[a]:i[e]=a;a>0&&t[e]!=t[a];)a=i[a];t[e]==t[a]&&a++}a=0;for(let r=n;r<e.length;r++){for(;a>0&&e[r]!=t[a];)a=i[a];e[r]==t[a]&&a++}return a}function gQ(e){let t;for(t=e.length-1;t>=0&&e[t].match(/\s/);t--);return e.substring(t+1)}function _Q(e){let t=e.match(/^\s*/);return t?t[0]:``}var vQ=`a-zA-Z0-9_\\u{AD}\\u{C0}-\\u{D6}\\u{D8}-\\u{F6}\\u{F8}-\\u{2C6}\\u{2C8}-\\u{2D7}\\u{2DE}-\\u{2FF}\\u{1E00}-\\u{1EFF}`,yQ=RegExp(`[${vQ}]+|\\s+|[^${vQ}]`,`ug`);new class extends aQ{equals(e,t,n){return n.ignoreCase&&(e=e.toLowerCase(),t=t.toLowerCase()),e.trim()===t.trim()}tokenize(e,t={}){let n;if(t.intlSegmenter){let r=t.intlSegmenter;if(r.resolvedOptions().granularity!=`word`)throw Error(`The segmenter passed must have a granularity of "word"`);n=[];for(let t of Array.from(r.segment(e))){let e=t.segment;n.length&&/\s/.test(n[n.length-1])&&/\s/.test(e)?n[n.length-1]+=e:n.push(e)}}else n=e.match(yQ)||[];let r=[],i=null;return n.forEach(e=>{/\s/.test(e)?i==null?r.push(e):r.push(r.pop()+e):i!=null&&/\s/.test(i)?r[r.length-1]==i?r.push(r.pop()+e):r.push(i+e):r.push(e),i=e}),r}join(e){return e.map((e,t)=>t==0?e:e.replace(/^\s+/,``)).join(``)}postProcess(e,t){if(!e||t.oneChangePerToken)return e;let n=null,r=null,i=null;return e.forEach(e=>{e.added?r=e:e.removed?i=e:((r||i)&&bQ(n,i,r,e),n=e,r=null,i=null)}),(r||i)&&bQ(n,i,r,null),e}};function bQ(e,t,n,r){if(t&&n){let i=_Q(t.value),a=gQ(t.value),o=_Q(n.value),s=gQ(n.value);if(e){let r=cQ(i,o);e.value=dQ(e.value,o,r),t.value=fQ(t.value,r),n.value=fQ(n.value,r)}if(r){let e=lQ(a,s);r.value=uQ(r.value,s,e),t.value=pQ(t.value,e),n.value=pQ(n.value,e)}}else if(n){if(e){let e=_Q(n.value);n.value=n.value.substring(e.length)}if(r){let e=_Q(r.value);r.value=r.value.substring(e.length)}}else if(e&&r){let n=_Q(r.value),i=_Q(t.value),a=gQ(t.value),o=cQ(n,i);t.value=fQ(t.value,o);let s=lQ(fQ(n,o),a);t.value=pQ(t.value,s),r.value=uQ(r.value,n,s),e.value=dQ(e.value,n,n.slice(0,n.length-s.length))}else if(r){let e=_Q(r.value),n=mQ(gQ(t.value),e);t.value=pQ(t.value,n)}else if(e){let n=mQ(gQ(e.value),_Q(t.value));t.value=fQ(t.value,n)}}var xQ=new class extends aQ{tokenize(e){let t=RegExp(`(\\r?\\n)|[${vQ}]+|[^\\S\\n\\r]+|[^${vQ}]`,`ug`);return e.match(t)||[]}};function SQ(e,t,n){return xQ.diff(e,t,n)}var CQ=new class extends aQ{constructor(){super(...arguments),this.tokenize=TQ}equals(e,t,n){return n.ignoreWhitespace?((!n.newlineIsToken||!e.includes(`
358
- `))&&(e=e.trim()),(!n.newlineIsToken||!t.includes(`
359
- `))&&(t=t.trim())):n.ignoreNewlineAtEof&&!n.newlineIsToken&&(e.endsWith(`
360
- `)&&(e=e.slice(0,-1)),t.endsWith(`
361
- `)&&(t=t.slice(0,-1))),super.equals(e,t,n)}};function wQ(e,t,n){return CQ.diff(e,t,n)}function TQ(e,t){t.stripTrailingCr&&(e=e.replace(/\r\n/g,`
362
- `));let n=[],r=e.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(let e=0;e<r.length;e++){let i=r[e];e%2&&!t.newlineIsToken?n[n.length-1]+=i:n.push(i)}return n}function EQ(e){return e==`.`||e==`!`||e==`?`}new class extends aQ{tokenize(e){let t=[],n=0;for(let r=0;r<e.length;r++){if(r==e.length-1){t.push(e.slice(n));break}if(EQ(e[r])&&e[r+1].match(/\s/)){for(t.push(e.slice(n,r+1)),r=n=r+1;e[r+1]?.match(/\s/);)r++;t.push(e.slice(n,r+1)),n=r+1}}return t}},new class extends aQ{tokenize(e){return e.split(/([{}:;,]|\s+)/)}},new class extends aQ{constructor(){super(...arguments),this.tokenize=TQ}get useLongestToken(){return!0}castInput(e,t){let{undefinedReplacement:n,stringifyReplacer:r=(e,t)=>t===void 0?n:t}=t;return typeof e==`string`?e:JSON.stringify(DQ(e,null,null,r),null,` `)}equals(e,t,n){return super.equals(e.replace(/,([\r\n])/g,`$1`),t.replace(/,([\r\n])/g,`$1`),n)}};function DQ(e,t,n,r,i){t||=[],n||=[],r&&(e=r(i===void 0?``:i,e));let a;for(a=0;a<t.length;a+=1)if(t[a]===e)return n[a];let o;if(Object.prototype.toString.call(e)===`[object Array]`){for(t.push(e),o=Array(e.length),n.push(o),a=0;a<e.length;a+=1)o[a]=DQ(e[a],t,n,r,String(a));return t.pop(),n.pop(),o}if(e&&e.toJSON&&(e=e.toJSON()),typeof e==`object`&&e){t.push(e),o={},n.push(o);let i=[],s;for(s in e)Object.prototype.hasOwnProperty.call(e,s)&&i.push(s);for(i.sort(),a=0;a<i.length;a+=1)s=i[a],o[s]=DQ(e[s],t,n,r,s);t.pop(),n.pop()}else o=e;return o}new class extends aQ{tokenize(e){return e.slice()}join(e){return e}removeEmpty(e){return e}};var OQ={includeIndex:!0,includeUnderline:!0,includeFileHeaders:!0};function kQ(e,t,n,r,i,a,o){let s;s=o?typeof o==`function`?{callback:o}:o:{},s.context===void 0&&(s.context=4);let c=s.context;if(s.newlineIsToken)throw Error(`newlineIsToken may not be used with patch-generation functions, only with diffing functions`);if(s.callback){let{callback:e}=s;wQ(n,r,Object.assign(Object.assign({},s),{callback:t=>{e(l(t))}}))}else return l(wQ(n,r,s));function l(n){if(!n)return;n.push({value:``,lines:[]});function r(e){return e.map(function(e){return` `+e})}let o=[],s=0,l=0,u=[],d=1,f=1;for(let e=0;e<n.length;e++){let t=n[e],i=t.lines||MQ(t.value);if(t.lines=i,t.added||t.removed){if(!s){let t=n[e-1];s=d,l=f,t&&(u=c>0?r(t.lines.slice(-c)):[],s-=u.length,l-=u.length)}for(let e of i)u.push((t.added?`+`:`-`)+e);t.added?f+=i.length:d+=i.length}else{if(s)if(i.length<=c*2&&e<n.length-2)for(let e of r(i))u.push(e);else{let e=Math.min(i.length,c);for(let t of r(i.slice(0,e)))u.push(t);let t={oldStart:s,oldLines:d-s+e,newStart:l,newLines:f-l+e,lines:u};o.push(t),s=0,l=0,u=[]}d+=i.length,f+=i.length}}for(let e of o)for(let t=0;t<e.lines.length;t++)e.lines[t].endsWith(`
363
- `)?e.lines[t]=e.lines[t].slice(0,-1):(e.lines.splice(t+1,0,`\`),t++);return{oldFileName:e,newFileName:t,oldHeader:i,newHeader:a,hunks:o}}}function AQ(e,t){if(t||=OQ,Array.isArray(e)){if(e.length>1&&!t.includeFileHeaders)throw Error(`Cannot omit file headers on a multi-file patch. (The result would be unparseable; how would a tool trying to apply the patch know which changes are to which file?)`);return e.map(e=>AQ(e,t)).join(`
364
- `)}let n=[];t.includeIndex&&e.oldFileName==e.newFileName&&n.push(`Index: `+e.oldFileName),t.includeUnderline&&n.push(`===================================================================`),t.includeFileHeaders&&(n.push(`--- `+e.oldFileName+(e.oldHeader===void 0?``:` `+e.oldHeader)),n.push(`+++ `+e.newFileName+(e.newHeader===void 0?``:` `+e.newHeader)));for(let t=0;t<e.hunks.length;t++){let r=e.hunks[t];r.oldLines===0&&--r.oldStart,r.newLines===0&&--r.newStart,n.push(`@@ -`+r.oldStart+`,`+r.oldLines+` +`+r.newStart+`,`+r.newLines+` @@`);for(let e of r.lines)n.push(e)}return n.join(`
365
- `)+`
366
- `}function jQ(e,t,n,r,i,a,o){if(typeof o==`function`&&(o={callback:o}),o?.callback){let{callback:s}=o;kQ(e,t,n,r,i,a,Object.assign(Object.assign({},o),{callback:e=>{s(e?AQ(e,o.headerOptions):void 0)}}))}else{let s=kQ(e,t,n,r,i,a,o);return s?AQ(s,o?.headerOptions):void 0}}function MQ(e){let t=e.endsWith(`
367
- `),n=e.split(`
368
- `).map(e=>e+`
369
- `);return t?n.pop():n.push(n.pop().slice(0,-1)),n}function NQ({line:e,spanStart:t,spanLength:n}){return{start:{line:e,character:t},end:{line:e,character:t+n},properties:{"data-diff-span":``},alwaysWrap:!0}}function PQ({item:e,arr:t,enableJoin:n,isNeutral:r=!1,isLastItem:i=!1}){let a=t[t.length-1];if(a==null||i||!n){t.push([+!r,e.value]);return}let o=a[0]===0;if(r===o||r&&e.value.length===1&&!o){a[1]+=e.value;return}t.push([+!r,e.value])}var FQ={forcePlainText:!1};function IQ(e,t,n,{forcePlainText:r,startingLine:i,totalLines:a,expandedHunks:o,collapsedContextThreshold:s=1}=FQ){r?(i??=0,a??=1/0):(i=0,a=1/0);let c=i>0||a<1/0,l=typeof n.theme==`string`?t.getTheme(n.theme).type:void 0,u=JZ({theme:n.theme,highlighter:t}),d=r&&!c&&(e.unifiedLineCount>1e3||e.splitLineCount>1e3)?`none`:n.lineDiffType,f={deletionLines:[],additionLines:[]},{maxLineDiffLength:p}=n,m=!r&&!e.isPartial,h=r?o:void 0,g=new Map;function _(e){let t=m?0:e,n=g.get(t)??RQ();return g.set(t,n),n}function v(e,t,n,r){if(c){let e=n.at(-1);(e==null||e.targetIndex+e.count!==t)&&(e={targetIndex:t,originalOffset:r.length,count:0},n.push(e)),e.count++}r.push(e)}eQ({diff:e,diffStyle:`both`,startingLine:i,totalLines:a,expandedHunks:c?h:!0,collapsedContextThreshold:s,callback:({hunkIndex:t,additionLine:n,deletionLine:r,type:i})=>{let a=_(t),o=n==null?r.splitLineIndex:n.splitLineIndex;i===`change`&&n!=null&&r!=null&&LQ({additionLine:e.additionLines[n.lineIndex],deletionLine:e.deletionLines[r.lineIndex],deletionLineIndex:a.deletionContent.length,additionLineIndex:a.additionContent.length,deletionDecorations:a.deletionDecorations,additionDecorations:a.additionDecorations,lineDiffType:d,maxLineDiffLength:p}),r!=null&&(v(e.deletionLines[r.lineIndex],r.lineIndex,a.deletionSegments,a.deletionContent),a.deletionInfo.push({type:i===`change`?`change-deletion`:i,lineNumber:r.lineNumber,altLineNumber:i===`change`?void 0:n.lineNumber??void 0,lineIndex:`${r.unifiedLineIndex},${o}`})),n!=null&&(v(e.additionLines[n.lineIndex],n.lineIndex,a.additionSegments,a.additionContent),a.additionInfo.push({type:i===`change`?`change-addition`:i,lineNumber:n.lineNumber,altLineNumber:i===`change`?void 0:r.lineNumber??void 0,lineIndex:`${n.unifiedLineIndex},${o}`}))}});for(let i of g.values()){if(i.deletionContent.length===0&&i.additionContent.length===0)continue;let a={name:e.prevName??e.name,contents:i.deletionContent.value},o={name:e.name,contents:i.additionContent.value},{deletionLines:s,additionLines:c}=zQ({deletionFile:a,deletionInfo:i.deletionInfo,deletionDecorations:i.deletionDecorations,additionFile:o,additionInfo:i.additionInfo,additionDecorations:i.additionDecorations,highlighter:t,options:n,languageOverride:r?`text`:e.lang});if(m){f.deletionLines=s,f.additionLines=c;continue}if(i.deletionSegments.length>0)for(let e of i.deletionSegments)for(let t=0;t<e.count;t++)f.deletionLines[e.targetIndex+t]=s[e.originalOffset+t];else f.deletionLines.push(...s);if(i.additionSegments.length>0)for(let e of i.additionSegments)for(let t=0;t<e.count;t++)f.additionLines[e.targetIndex+t]=c[e.originalOffset+t];else f.additionLines.push(...c)}return{code:f,themeStyles:u,baseThemeType:l}}function LQ({deletionLine:e,additionLine:t,deletionLineIndex:n,additionLineIndex:r,deletionDecorations:i,additionDecorations:a,lineDiffType:o,maxLineDiffLength:s}){if(e==null||t==null||o===`none`||(e=DZ(e),t=DZ(t),e.length>s||t.length>s))return;let c=o===`char`?sQ(e,t):SQ(e,t),l=[],u=[],d=o===`word-alt`,f=c.at(-1);for(let e of c){let t=e===f;!e.added&&!e.removed?(PQ({item:e,arr:l,enableJoin:d,isNeutral:!0,isLastItem:t}),PQ({item:e,arr:u,enableJoin:d,isNeutral:!0,isLastItem:t})):e.removed?PQ({item:e,arr:l,enableJoin:d,isLastItem:t}):PQ({item:e,arr:u,enableJoin:d,isLastItem:t})}let p=0;for(let e of l)e[0]===1&&i.push(NQ({line:n,spanStart:p,spanLength:e[1].length})),p+=e[1].length;p=0;for(let e of u)e[0]===1&&a.push(NQ({line:r,spanStart:p,spanLength:e[1].length})),p+=e[1].length}function RQ(){return{deletionContent:{push(e){this.value+=e,this.length++},value:``,length:0},additionContent:{push(e){this.value+=e,this.length++},value:``,length:0},deletionInfo:[],additionInfo:[],deletionDecorations:[],additionDecorations:[],deletionSegments:[],additionSegments:[]}}function zQ({deletionFile:e,additionFile:t,deletionInfo:n,additionInfo:r,highlighter:i,deletionDecorations:a,additionDecorations:o,languageOverride:s,options:{theme:c=DJ,...l}}){let u=s??EZ(e.name),d=s??EZ(t.name),{state:f,transformers:p}=WZ(l.useTokenTransformer),m=typeof c==`string`?{...l,lang:`text`,theme:c,transformers:p,decorations:void 0,defaultColor:!1,cssVariablePrefix:qZ(`token`)}:{...l,lang:`text`,themes:c,transformers:p,decorations:void 0,defaultColor:!1,cssVariablePrefix:qZ(`token`)};return{deletionLines:e.contents===``?[]:(m.lang=u,f.lineInfo=n,m.decorations=a,XZ(i.codeToHast(DZ(e.contents),m))),additionLines:t.contents===``?[]:(m.lang=d,m.decorations=o,f.lineInfo=r,XZ(i.codeToHast(DZ(t.contents),m)))}}var BQ=(0,d.createContext)(void 0);function VQ(e){let t=(0,d.useRef)(e);return(0,d.useInsertionEffect)(()=>void(t.current=e)),(0,d.useCallback)((...e)=>t.current(...e),[])}function HQ(e,t){return e.lineNumber===t.lineNumber&&e.side===t.side}function UQ(e,t){return e?.start===t?.start&&e?.end===t?.end&&e?.side===t?.side&&e?.endSide===t?.endSide}function WQ(){return kZ({tagName:`button`,properties:{"data-utility-button":``,type:`button`},children:[AZ({name:`diffs-icon-plus`,properties:{"data-icon":``}})]})}var GQ=class{hoveredLine;hoveredToken;pre;gutterUtilityContainer;gutterUtilityButton;gutterUtilitySlot;interactiveLinesAttr=!1;interactiveLineNumbersAttr=!1;hasPointerListeners=!1;hasDocumentPointerListeners=!1;selectedRange=null;renderedSelectionRange;selectionAnchor;queuedSelectionRender;pointerSession={mode:`idle`};constructor(e,t){this.mode=e,this.options=t}setOptions(e){this.options=e}cleanUp(){this.pre?.removeEventListener(`click`,this.handlePointerClick),this.pre?.removeEventListener(`pointerdown`,this.handlePointerDown),this.pre?.removeEventListener(`pointermove`,this.handlePointerMove),this.pre?.removeEventListener(`pointerleave`,this.handlePointerLeave),this.pre?.removeAttribute(`data-interactive-lines`),this.pre?.removeAttribute(`data-interactive-line-numbers`),this.pre=void 0,this.gutterUtilityContainer?.remove(),this.gutterUtilityContainer=void 0,this.gutterUtilityButton=void 0,this.gutterUtilitySlot=void 0,this.clearHoveredLine(),this.clearHoveredToken(),this.detachDocumentPointerListeners(),this.clearPointerSession(),this.queuedSelectionRender!=null&&(cancelAnimationFrame(this.queuedSelectionRender),this.queuedSelectionRender=void 0),this.interactiveLinesAttr=!1,this.interactiveLineNumbersAttr=!1,this.hasPointerListeners=!1}setup(e){this.setSelectionDirty();let{usesCustomGutterUtility:t=!1,enableGutterUtility:n=!1}=this.options;this.pre!==e&&(this.cleanUp(),this.pre=e),n?this.ensureGutterUtilityNode(t):this.gutterUtilityContainer!=null&&(this.gutterUtilityContainer.remove(),this.gutterUtilityContainer=void 0,this.gutterUtilityButton=void 0,this.gutterUtilitySlot=void 0,this.pointerSession.mode===`gutterSelecting`&&(this.clearPointerSession(),this.detachDocumentPointerListeners())),this.syncPointerListeners(e),this.updateInteractiveLineAttributes(),this.renderSelection()}setSelectionDirty(){this.renderedSelectionRange=void 0}isSelectionDirty(){return this.renderedSelectionRange===null}setSelection(e){let t=!(e===this.selectedRange||UQ(e??void 0,this.selectedRange??void 0));!this.isSelectionDirty()&&!t||(this.selectedRange=e,this.renderSelection(),t&&this.notifySelectionCommitted())}getSelection(){return this.selectedRange}getHoveredLine=()=>{if(this.hoveredLine!=null){if(this.mode===`diff`&&this.hoveredLine.type===`diff-line`)return{lineNumber:this.hoveredLine.lineNumber,side:this.hoveredLine.annotationSide};if(this.mode===`file`&&this.hoveredLine.type===`line`)return{lineNumber:this.hoveredLine.lineNumber}}};handlePointerClick=e=>{let{onHunkExpand:t,onLineClick:n,onLineNumberClick:r,onTokenClick:i,onMergeConflictActionClick:a}=this.options;t==null&&n==null&&r==null&&a==null&&i==null||this.options.onGutterUtilityClick!=null&&r$(e.composedPath())||(i$(this.options.__debugPointerEvents,`click`,`FileDiff.DEBUG.handlePointerClick:`,e),this.handlePointerEvent({eventType:`click`,event:e}))};handlePointerMove=e=>{let{lineHoverHighlight:t=`disabled`,onLineEnter:n,onLineLeave:r,onTokenEnter:i,onTokenLeave:a,enableGutterUtility:o=!1}=this.options;t===`disabled`&&!o&&n==null&&r==null&&i==null&&a==null||(i$(this.options.__debugPointerEvents,`move`,`FileDiff.DEBUG.handlePointerMove:`,e),this.handlePointerEvent({eventType:`move`,event:e}))};handlePointerLeave=e=>{let{__debugPointerEvents:t}=this.options;if(i$(t,`move`,`FileDiff.DEBUG.handlePointerLeave: no event`),this.hoveredLine==null&&this.hoveredToken==null){i$(t,`move`,`FileDiff.DEBUG.handlePointerLeave: returned early, no hovered line or token`);return}this.gutterUtilityContainer?.remove(),this.hoveredToken!=null&&(this.options.onTokenLeave?.(this.hoveredToken,e),this.clearHoveredToken()),this.hoveredLine!=null&&(this.options.onLineLeave?.({...this.hoveredLine,event:e}),this.clearHoveredLine())};handlePointerEvent({eventType:e,event:t}){let{__debugPointerEvents:n}=this.options,r=t.composedPath();i$(n,e,`FileDiff.DEBUG.handlePointerEvent:`,{eventType:e,composedPath:r});let i=this.resolvePointerTarget(r);i$(n,e,`FileDiff.DEBUG.handlePointerEvent: resolvePointerTarget result:`,i);let{onLineClick:a,onLineNumberClick:o,onLineEnter:s,onLineLeave:c,onTokenClick:l,onTokenEnter:u,onTokenLeave:d,onHunkExpand:f,onMergeConflictActionClick:p}=this.options;switch(e){case`move`:{let e=XQ(i)&&this.hoveredLine?.lineElement===i.lineElement;YQ(i)&&this.hoveredToken?.tokenElement===i.tokenElement||(this.hoveredToken!=null&&(d?.(this.hoveredToken,t),this.clearHoveredToken()),YQ(i)&&(this.setHoveredToken(this.toTokenEventBaseProps(i)),u?.(this.hoveredToken,t))),e||(this.hoveredLine!=null&&(this.gutterUtilityContainer?.remove(),c?.({...this.hoveredLine,event:t}),this.clearHoveredLine()),XQ(i)&&(this.setHoveredLine(this.toEventBaseProps(i)),this.gutterUtilityContainer!=null&&i.numberElement.appendChild(this.gutterUtilityContainer),s?.({...this.hoveredLine,event:t})));break}case`click`:{if(i==null)break;if(QQ(i)&&p!=null){p(i);break}if(ZQ(i)&&f!=null){f(i.hunkIndex,i.all||t.shiftKey?`both`:i.direction,i.all||t.shiftKey?1/0:void 0);break}if(!XQ(i))break;YQ(i)&&l!=null&&l(this.toTokenEventBaseProps(i),t);let e=this.toEventBaseProps(i);o!=null&&i.numberColumn?o({...e,event:t}):a?.({...e,event:t});break}}}syncPointerListeners(e){let{__debugPointerEvents:t,lineHoverHighlight:n=`disabled`,onLineClick:r,onLineNumberClick:i,onLineEnter:a,onLineLeave:o,onTokenClick:s,onTokenEnter:c,onTokenLeave:l,onHunkExpand:u,onMergeConflictActionClick:d,enableGutterUtility:f=!1,enableLineSelection:p=!1,onGutterUtilityClick:m}=this.options,h=m!=null,g=n!==`disabled`||r!=null||i!=null||a!=null||o!=null||s!=null||c!=null||l!=null||u!=null||d!=null||f||p||h;g&&!this.hasPointerListeners?(e.addEventListener(`click`,this.handlePointerClick),e.addEventListener(`pointerdown`,this.handlePointerDown),e.addEventListener(`pointermove`,this.handlePointerMove),e.addEventListener(`pointerleave`,this.handlePointerLeave),this.hasPointerListeners=!0,i$(t,`click`,`FileDiff.DEBUG.attachEventListeners: Attaching click events for:`,(()=>{let e=[];return(t===`both`||t===`click`)&&(r!=null&&e.push(`onLineClick`),i!=null&&e.push(`onLineNumberClick`),u!=null&&e.push(`expandable hunk separators`),d!=null&&e.push(`merge conflict actions`)),e})()),i$(t,`move`,`FileDiff.DEBUG.attachEventListeners: Attaching pointer move event`),i$(t,`move`,`FileDiff.DEBUG.attachEventListeners: Attaching pointer leave event`)):!g&&this.hasPointerListeners&&(e.removeEventListener(`click`,this.handlePointerClick),e.removeEventListener(`pointerdown`,this.handlePointerDown),e.removeEventListener(`pointermove`,this.handlePointerMove),e.removeEventListener(`pointerleave`,this.handlePointerLeave),this.hasPointerListeners=!1);let _=this.pointerSession.mode===`selecting`||this.pointerSession.mode===`pendingSingleLineUnselect`,v=this.pointerSession.mode===`gutterSelecting`;(!p&&_||!h&&v)&&(this.clearPointerSession(),this.detachDocumentPointerListeners(),this.selectionAnchor=void 0,this.clearPendingSingleLineState())}updateInteractiveLineAttributes(){if(this.pre==null)return;let{onLineClick:e,onLineNumberClick:t,enableLineSelection:n=!1}=this.options,r=e!=null,i=t!=null||n;r&&!this.interactiveLinesAttr?(this.pre.setAttribute(`data-interactive-lines`,``),this.interactiveLinesAttr=!0):!r&&this.interactiveLinesAttr&&(this.pre.removeAttribute(`data-interactive-lines`),this.interactiveLinesAttr=!1),i&&!this.interactiveLineNumbersAttr?(this.pre.setAttribute(`data-interactive-line-numbers`,``),this.interactiveLineNumbersAttr=!0):!i&&this.interactiveLineNumbersAttr&&(this.pre.removeAttribute(`data-interactive-line-numbers`),this.interactiveLineNumbersAttr=!1)}handlePointerDown=e=>{if(e.pointerType===`mouse`&&e.button!==0||this.pre==null||this.pointerSession.mode!==`idle`)return;let t=e.composedPath();r$(t)&&this.options.onGutterUtilityClick!=null?this.startGutterSelectionFromPointerDown(e,t):this.startLineSelectionFromPointerDown(e,t)};startLineSelectionFromPointerDown(e,t){let{enableLineSelection:n=!1}=this.options;if(!n)return;let r=this.getSelectionPointerInfo(t,!0);if(r==null)return;let{pre:i}=this;if(i==null)return;e.preventDefault();let{lineNumber:a,eventSide:o,lineIndex:s}=r;if(e.shiftKey&&this.selectedRange!=null){let t=this.getIndexesFromSelection(this.selectedRange,i.getAttribute(`data-diff-type`)===`split`);if(t==null)return;let n=t.start<=t.end?s>=t.start:s<=t.end;this.selectionAnchor={lineNumber:n?this.selectedRange.start:this.selectedRange.end,side:n?this.selectedRange.side:this.selectedRange.endSide??this.selectedRange.side},this.updateSelection(a,o,!1),this.notifySelectionStart(this.selectedRange),this.pointerSession={mode:`selecting`,pointerId:e.pointerId},this.attachDocumentPointerListeners();return}if(this.selectedRange?.start===a&&this.selectedRange?.end===a){let t={lineNumber:a,side:o};this.selectionAnchor=t,this.pointerSession={mode:`pendingSingleLineUnselect`,pointerId:e.pointerId,anchor:t,pending:t},this.attachDocumentPointerListeners();return}this.selectedRange=null,this.selectionAnchor={lineNumber:a,side:o},this.updateSelection(a,o,!1),this.notifySelectionStart(this.selectedRange),this.pointerSession={mode:`selecting`,pointerId:e.pointerId},this.attachDocumentPointerListeners()}startGutterSelectionFromPointerDown(e,t){let{enableLineSelection:n=!1,onGutterUtilityClick:r}=this.options;if(r==null)return;let i=this.getSelectionPointFromPath(t);i!=null&&(e.preventDefault(),e.stopPropagation(),this.pointerSession={mode:`gutterSelecting`,pointerId:e.pointerId,anchor:i,current:i},n&&(this.selectionAnchor={lineNumber:i.lineNumber,side:i.side},this.updateSelection(i.lineNumber,i.side,!1),this.notifySelectionStart(this.selectedRange)),this.attachDocumentPointerListeners())}handleDocumentPointerMove=e=>{let{enableLineSelection:t=!1}=this.options;switch(this.pointerSession.mode){case`idle`:return;case`gutterSelecting`:{if(e.pointerId!==this.pointerSession.pointerId)return;let n=this.getSelectionPointFromPath(e.composedPath());if(n==null)return;this.pointerSession.current=n,t===!0&&this.updateSelection(n.lineNumber,n.side);return}case`selecting`:{if(e.pointerId!==this.pointerSession.pointerId)return;let t=this.getSelectionPointerInfo(e.composedPath(),!1);if(t==null||this.selectionAnchor==null)return;this.updateSelection(t.lineNumber,t.eventSide);return}case`pendingSingleLineUnselect`:{if(e.pointerId!==this.pointerSession.pointerId)return;let t=this.getSelectionPointerInfo(e.composedPath(),!1);if(t==null||this.selectionAnchor==null)return;let n={lineNumber:t.lineNumber,side:t.eventSide};if(HQ(this.pointerSession.pending,n))return;this.updateSelection(t.lineNumber,t.eventSide,!1),this.notifySelectionStart(this.selectedRange),this.notifySelectionChangeDelta(),this.pointerSession={mode:`selecting`,pointerId:e.pointerId};return}}};handleDocumentPointerUp=e=>{let{enableLineSelection:t=!1,onGutterUtilityClick:n}=this.options;switch(this.pointerSession.mode){case`idle`:return;case`gutterSelecting`:{if(e.pointerId!==this.pointerSession.pointerId)return;let r=this.getSelectionPointFromPath(e.composedPath());r!=null&&(this.pointerSession.current=r,t&&this.updateSelection(r.lineNumber,r.side)),n?.(this.buildSelectedLineRange(this.pointerSession.anchor,this.pointerSession.current)),this.selectionAnchor=void 0,t&&(this.notifySelectionEnd(this.selectedRange),this.notifySelectionCommitted()),this.clearPointerSession(),this.detachDocumentPointerListeners();return}case`pendingSingleLineUnselect`:if(e.pointerId!==this.pointerSession.pointerId)return;this.updateSelection(null,void 0,!1),this.selectionAnchor=void 0,this.clearPendingSingleLineState(),this.detachDocumentPointerListeners(),this.notifySelectionEnd(this.selectedRange),this.notifySelectionCommitted();return;case`selecting`:if(e.pointerId!==this.pointerSession.pointerId)return;this.selectionAnchor=void 0,this.detachDocumentPointerListeners(),this.clearPointerSession(),this.notifySelectionEnd(this.selectedRange),this.notifySelectionCommitted()}};handleDocumentPointerCancel=e=>{switch(this.pointerSession.mode){case`idle`:return;case`gutterSelecting`:case`selecting`:case`pendingSingleLineUnselect`:if(`pointerId`in this.pointerSession&&e.pointerId!==this.pointerSession.pointerId)return;this.selectionAnchor=void 0,this.clearPendingSingleLineState(),this.clearPointerSession(),this.detachDocumentPointerListeners()}};clearHoveredLine(){this.hoveredLine!=null&&(this.hoveredLine.lineElement.removeAttribute(`data-hovered`),this.hoveredLine.numberElement.removeAttribute(`data-hovered`),this.hoveredLine=void 0)}setHoveredLine(e){let{lineHoverHighlight:t=`disabled`}=this.options;this.hoveredLine!=null&&this.clearHoveredLine(),this.hoveredLine=e,t!==`disabled`&&((t===`both`||t===`line`)&&this.hoveredLine.lineElement.setAttribute(`data-hovered`,``),(t===`both`||t===`number`)&&this.hoveredLine.numberElement.setAttribute(`data-hovered`,``))}clearHoveredToken(){this.hoveredToken!=null&&(this.hoveredToken=void 0)}setHoveredToken(e){this.hoveredToken!=null&&this.clearHoveredToken(),this.hoveredToken=e}ensureGutterUtilityNode(e){if(this.gutterUtilityContainer??(this.gutterUtilityContainer=document.createElement(`div`),this.gutterUtilityContainer.setAttribute(`data-gutter-utility-slot`,``)),e)this.gutterUtilityButton!=null&&(this.gutterUtilityButton.remove(),this.gutterUtilityButton=void 0),this.gutterUtilitySlot??(this.gutterUtilitySlot=document.createElement(`slot`),this.gutterUtilitySlot.name=`gutter-utility-slot`),this.gutterUtilitySlot.parentNode!==this.gutterUtilityContainer&&this.gutterUtilityContainer.replaceChildren(this.gutterUtilitySlot);else{if(this.gutterUtilitySlot?.remove(),this.gutterUtilitySlot=void 0,this.gutterUtilityButton==null){let e=document.createElement(`div`);e.innerHTML=rV(WQ());let t=e.firstElementChild;if(!(t instanceof HTMLButtonElement))throw Error(`InteractionManager.ensureGutterUtilityNode: Node element should be a button`);t.remove(),this.gutterUtilityButton=t}this.gutterUtilityButton.parentNode!==this.gutterUtilityContainer&&this.gutterUtilityContainer.replaceChildren(this.gutterUtilityButton)}}attachDocumentPointerListeners(){this.hasDocumentPointerListeners||=(document.addEventListener(`pointermove`,this.handleDocumentPointerMove),document.addEventListener(`pointerup`,this.handleDocumentPointerUp),document.addEventListener(`pointercancel`,this.handleDocumentPointerCancel),!0)}detachDocumentPointerListeners(){this.hasDocumentPointerListeners&&=(document.removeEventListener(`pointermove`,this.handleDocumentPointerMove),document.removeEventListener(`pointerup`,this.handleDocumentPointerUp),document.removeEventListener(`pointercancel`,this.handleDocumentPointerCancel),!1)}clearPointerSession(){this.pointerSession={mode:`idle`}}clearPendingSingleLineState(){this.pointerSession.mode===`pendingSingleLineUnselect`&&(this.pointerSession={mode:`idle`})}getSelectionPointerInfo(e,t){let n=this.resolvePointerTarget(e);if(JQ(n)&&!(t&&!n.numberColumn)&&n.splitLineIndex!=null)return{lineIndex:n.splitLineIndex,lineNumber:n.lineNumber,eventSide:this.mode===`diff`?n.side:void 0}}getSelectionPointFromPath(e){let t=this.resolvePointerTarget(e);if(JQ(t))return{lineNumber:t.lineNumber,side:this.mode===`diff`?t.side:void 0}}getLineIndex(e,t){let{getLineIndex:n}=this.options;return n==null?[e-1,e-1]:n(e,t)}updateSelection(e,t,n=!0){let{selectedRange:r}=this,i;if(e==null)i=null;else{let n=this.selectionAnchor?.side??t,r=this.selectionAnchor?.lineNumber??e;i=this.buildSelectionRange(r,e,n,t)}UQ(r??void 0,i??void 0)||(this.selectedRange=i,n&&this.notifySelectionChangeDelta(),this.queuedSelectionRender??=requestAnimationFrame(this.renderSelection))}getIndexesFromSelection(e,t){if(this.pre==null)return;let n=this.getLineIndex(e.start,e.side),r=this.getLineIndex(e.end,e.endSide??e.side);return n!=null&&r!=null?{start:t?n[1]:n[0],end:t?r[1]:r[0]}:void 0}renderSelection=()=>{if(this.queuedSelectionRender!=null&&(cancelAnimationFrame(this.queuedSelectionRender),this.queuedSelectionRender=void 0),this.pre==null||this.renderedSelectionRange===this.selectedRange)return;let e=this.pre.querySelectorAll(`[data-selected-line]`);for(let t of e)t.removeAttribute(`data-selected-line`);if(this.renderedSelectionRange=this.selectedRange,this.selectedRange==null)return;let{children:t}=this.pre;if(t.length===0)return;if(t.length>2)throw console.error(t),Error(`InteractionManager.renderSelection: Somehow there are more than 2 code elements...`);let n=this.pre.getAttribute(`data-diff-type`)===`split`,r=this.getIndexesFromSelection(this.selectedRange,n);if(r==null)throw console.error({rowRange:r,selectedRange:this.selectedRange}),Error(`InteractionManager.renderSelection: No valid rowRange`);let i=r.start===r.end,a=Math.min(r.start,r.end),o=Math.max(r.start,r.end);for(let e of t){let[t,r]=e.children,s=r.children.length;if(s!==t.children.length)throw Error(`InteractionManager.renderSelection: gutter and content children dont match, something is wrong`);for(let e=0;e<s;e++){let s=r.children[e],c=t.children[e];if(!(s instanceof HTMLElement)||!(c instanceof HTMLElement))continue;let l=this.parseLineIndex(s,n);if((l??0)>o)break;if(l==null||l<a)continue;let u=i?`single`:l===a?`first`:l===o?`last`:``;s.setAttribute(`data-selected-line`,u),c.setAttribute(`data-selected-line`,u),c.nextSibling instanceof HTMLElement&&s.nextSibling instanceof HTMLElement&&(s.nextSibling.hasAttribute(`data-line-annotation`)||s.nextSibling.hasAttribute(`data-merge-conflict-actions`))&&(i?(u=`last`,s.setAttribute(`data-selected-line`,`first`)):l===a?u=``:l===o&&s.setAttribute(`data-selected-line`,``),s.nextSibling.setAttribute(`data-selected-line`,u),c.nextSibling.setAttribute(`data-selected-line`,u))}}};notifySelectionCommitted(){this.options.onLineSelected?.(this.selectedRange??null)}notifySelectionChangeDelta(){this.options.onLineSelectionChange?.(this.selectedRange??null)}notifySelectionStart(e){this.options.onLineSelectionStart?.(e)}notifySelectionEnd(e){this.options.onLineSelectionEnd?.(e)}toEventBaseProps(e){return this.mode===`file`?{type:`line`,lineElement:e.lineElement,lineNumber:e.lineNumber,numberColumn:e.numberColumn,numberElement:e.numberElement}:{type:`diff-line`,annotationSide:e.side,lineType:e.lineType,lineElement:e.lineElement,numberElement:e.numberElement,lineNumber:e.lineNumber,numberColumn:e.numberColumn}}toTokenEventBaseProps({lineCharEnd:e,lineCharStart:t,lineNumber:n,side:r,tokenElement:i,tokenText:a}){return this.mode===`file`?{type:`token`,lineCharEnd:e,lineCharStart:t,lineNumber:n,tokenElement:i,tokenText:a}:{type:`token`,lineCharEnd:e,lineCharStart:t,lineNumber:n,side:r,tokenElement:i,tokenText:a}}buildSelectedLineRange(e,t){return this.buildSelectionRange(e.lineNumber,t.lineNumber,e.side,t.side)}buildSelectionRange(e,t,n,r){return{start:e,end:t,...n==null?{}:{side:n},...n!==r&&r!=null?{endSide:r}:{}}}resolvePointerTarget(e){let t=!1,n,r,i,a,o,s,c,l,u,d;for(let f of e){if(!(f instanceof HTMLElement))continue;if(d==null&&f.hasAttribute(`data-merge-conflict-action`)){let e=f.getAttribute(`data-merge-conflict-action`)??void 0,t=f.getAttribute(`data-merge-conflict-conflict-index`)??void 0,n=t==null?NaN:Number.parseInt(t,10);$Q(e)&&Number.isFinite(n)&&(d={kind:`merge-conflict-action`,resolution:e,conflictIndex:n})}if(s==null&&f.hasAttribute(`data-char`)){s=f;let e=f.getAttribute(`data-char`);if(e!=null){let t=Number.parseInt(e,10);if(!Number.isNaN(t)){let e=f.textContent??``,n=t+e.length;(e.trim()!==``||this.options.enableTokenInteractionsOnWhitespace===!0)&&(c={tokenElement:s,lineCharStart:t,lineCharEnd:n,tokenText:e});continue}}}let e=o==null?f.getAttribute(`data-column-number`)??void 0:void 0;if(e!=null){o=f,u=Number.parseInt(e,10),t=!0,n=n$(f),a=f.getAttribute(`data-line-index`)??void 0;continue}let p=i==null?f.getAttribute(`data-line`)??void 0:void 0;if(p!=null){i=f,u=Number.parseInt(p,10),n=n$(f),a=f.getAttribute(`data-line-index`)??void 0;continue}if(l==null&&(f.hasAttribute(`data-expand-button`)||f.hasAttribute(`data-unmodified-lines`))){l={hunkIndex:void 0,direction:f.hasAttribute(`data-expand-up`)?`up`:f.hasAttribute(`data-expand-down`)?`down`:`both`,all:f.hasAttribute(`data-expand-all-button`)};continue}let m=l==null?void 0:f.getAttribute(`data-expand-index`)??void 0;if(l!=null&&m!=null){let e=Number.parseInt(m,10);Number.isNaN(e)||(l.hunkIndex=e);continue}if(r==null&&f.hasAttribute(`data-code`)){r=f;break}}if(d!=null)return d;if(l?.hunkIndex!=null)return{type:`line-info`,hunkIndex:l.hunkIndex,direction:l.direction,all:l.all};if(i??=a==null?void 0:e$(r,`[data-line][data-line-index="${a}"]`),o??=a==null?void 0:e$(r,`[data-column-number][data-line-index="${a}"]`),r==null||i==null||o==null||n==null||u==null||Number.isNaN(u))return;let f=this.parseLineIndex(i,this.isSplitDiff());return c==null?this.mode===`file`?{kind:`line`,lineType:n,lineElement:i,lineNumber:u,numberColumn:t,numberElement:o,side:void 0,splitLineIndex:f}:{kind:`line`,lineType:n,lineElement:i,lineNumber:u,numberColumn:t,numberElement:o,side:t$(n,r),splitLineIndex:f}:this.mode===`file`?{kind:`token`,lineType:n,lineElement:i,lineNumber:u,numberColumn:t,numberElement:o,side:void 0,splitLineIndex:f,...c}:{kind:`token`,lineType:n,lineElement:i,lineNumber:u,numberColumn:t,numberElement:o,side:t$(n,r),splitLineIndex:f,...c}}isSplitDiff(){return this.pre?.getAttribute(`data-diff-type`)===`split`}parseLineIndex(e,t){let n=(e.getAttribute(`data-line-index`)??``).split(`,`).map(e=>Number.parseInt(e,10)).filter(e=>!Number.isNaN(e));if(t&&n.length===2)return n[1];if(!t)return n[0]}};function KQ({enableTokenInteractionsOnWhitespace:e,enableGutterUtility:t,enableHoverUtility:n,lineHoverHighlight:r,onGutterUtilityClick:i,onLineClick:a,onLineEnter:o,onLineLeave:s,onLineNumberClick:c,onTokenClick:l,onTokenEnter:u,onTokenLeave:d,renderGutterUtility:f,renderHoverUtility:p,__debugPointerEvents:m,enableLineSelection:h,onLineSelected:g,onLineSelectionStart:_,onLineSelectionChange:v,onLineSelectionEnd:y},b,x,S){return{enableTokenInteractionsOnWhitespace:e,enableGutterUtility:qQ({enableGutterUtility:t,enableHoverUtility:n,renderGutterUtility:f,renderHoverUtility:p,onGutterUtilityClick:i}),usesCustomGutterUtility:f!=null||p!=null,lineHoverHighlight:r,onGutterUtilityClick:i,onHunkExpand:b,onMergeConflictActionClick:S,onLineClick:a,onLineEnter:o,onLineLeave:s,onLineNumberClick:c,onTokenClick:l,onTokenEnter:u,onTokenLeave:d,__debugPointerEvents:m,enableLineSelection:h,onLineSelected:g,onLineSelectionStart:_,onLineSelectionChange:v,onLineSelectionEnd:y,getLineIndex:x}}function qQ({enableGutterUtility:e,enableHoverUtility:t,renderGutterUtility:n,renderHoverUtility:r,onGutterUtilityClick:i}){if(e!==void 0&&t!==void 0)throw Error(`Cannot use both 'enableGutterUtility' and deprecated 'enableHoverUtility'. Use only 'enableGutterUtility'.`);if(n!=null&&r!=null)throw Error(`Cannot use both 'renderGutterUtility' and deprecated 'renderHoverUtility'. Use only 'renderGutterUtility'.`);if(i!=null&&(n!=null||r!=null))throw Error(`Cannot use both 'onGutterUtilityClick' and render utility callbacks ('renderGutterUtility'/'renderHoverUtility'). Use only one gutter utility API.`);return e??t??!1}function JQ(e){return e!=null&&`kind`in e&&e.kind===`line`}function YQ(e){return e!=null&&`kind`in e&&e.kind===`token`}function XQ(e){return JQ(e)||YQ(e)}function ZQ(e){return`type`in e&&e.type===`line-info`}function QQ(e){return`kind`in e&&e.kind===`merge-conflict-action`}function $Q(e){return e===`current`||e===`incoming`||e===`both`}function e$(e,t){let n=e?.querySelector(t);return n instanceof HTMLElement?n:void 0}function t$(e,t){switch(e){case`change-deletion`:return`deletions`;case`change-addition`:return`additions`;default:return t.hasAttribute(`data-deletions`)?`deletions`:`additions`}}function n$(e){let t=e.getAttribute(`data-line-type`);if(t!=null)switch(t){case`change-deletion`:case`change-addition`:case`context`:case`context-expanded`:return t;default:return}}function r$(e){for(let t of e)if(t instanceof HTMLElement&&t.hasAttribute(`data-utility-button`))return!0;return!1}function i$(e=`none`,t,...n){switch(e){case`none`:return;case`both`:break;case`click`:if(t!==`click`)return;break;case`move`:if(t!==`move`)return;break}console.log(...n)}var a$=class{observedNodes=new Map;queuedUpdates=new Map;cleanUp(){this.resizeObserver?.disconnect(),this.observedNodes.clear(),this.queuedUpdates.clear()}resizeObserver;setup(e,t){this.resizeObserver??=new ResizeObserver(this.handleResizeObserver);let n=e.querySelectorAll(`code`),r=new Map(this.observedNodes);this.observedNodes.clear();for(let e of n){let t=r.get(e);if(t!=null&&t.type!==`code`)throw Error(`ResizeManager.setup: somehow a code node is being used for an annotation, should be impossible`);let n=e.firstElementChild;n instanceof HTMLElement||(n=null),t==null?(t={type:`code`,codeElement:e,numberElement:n,codeWidth:`auto`,numberWidth:0},this.observedNodes.set(e,t),this.resizeObserver.observe(e),n!=null&&(this.observedNodes.set(n,t),this.resizeObserver.observe(n))):(this.observedNodes.set(e,t),r.delete(e),t.numberElement===n?t.numberElement!=null&&(r.delete(t.numberElement),this.observedNodes.set(t.numberElement,t)):(t.numberElement!=null&&this.resizeObserver.unobserve(t.numberElement),n!=null&&(this.resizeObserver.observe(n),r.delete(n),this.observedNodes.set(n,t)),t.numberElement=n))}if(n.length>1&&!t){let t=e.querySelectorAll(`[data-line-annotation*=","]`),n=new Map;for(let e of t){if(!(e instanceof HTMLElement))continue;let{lineAnnotation:t=``}=e.dataset;if(!/^\d+,\d+$/.test(t)){console.error(`DiffFileRenderer.setupResizeObserver: Invalid element or annotation`,{lineAnnotation:t,element:e});continue}let r=n.get(t);r??(r=[],n.set(t,r)),r.push(e)}for(let[e,t]of n){if(t.length!==2){console.error(`DiffFileRenderer.setupResizeObserver: Bad Pair`,e,t);continue}let[n,i]=t,a=n.firstElementChild,o=i.firstElementChild;if(!(n instanceof HTMLElement)||!(i instanceof HTMLElement)||!(a instanceof HTMLElement)||!(o instanceof HTMLElement))continue;let s=r.get(a);if(s!=null){this.observedNodes.set(a,s),this.observedNodes.set(o,s),r.delete(a),r.delete(o);continue}s={type:`annotations`,column1:{container:n,child:a,childHeight:a.getBoundingClientRect().height},column2:{container:i,child:o,childHeight:o.getBoundingClientRect().height},currentHeight:`auto`};let c=Math.max(s.column1.childHeight,s.column2.childHeight);this.applyNewHeight(s,c),this.observedNodes.set(a,s),this.observedNodes.set(o,s),this.resizeObserver.observe(a),this.resizeObserver.observe(o)}}for(let e of r.keys())e.isConnected&&(e.style.removeProperty(`--diffs-column-content-width`),e.style.removeProperty(`--diffs-column-number-width`),e.style.removeProperty(`--diffs-column-width`),e.parentElement instanceof HTMLElement&&e.parentElement.style.removeProperty(`--diffs-annotation-min-height`)),this.resizeObserver.unobserve(e);r.clear()}handleResizeObserver=e=>{for(let t of e){let{target:e,borderBoxSize:n,contentBoxSize:r}=t;if(!(e instanceof HTMLElement)){console.error(`FileDiff.handleResizeObserver: Invalid element for ResizeObserver`,t);continue}let i=this.observedNodes.get(e);if(i==null){console.error(`FileDiff.handleResizeObserver: Not a valid observed node`,t);continue}if(i.type===`annotations`){let t=(()=>{if(e===i.column1.child)return i.column1;if(e===i.column2.child)return i.column2})();if(t==null){console.error(`FileDiff.handleResizeObserver: Couldn't find a column for`,{item:i,target:e});continue}t.childHeight=n[0].blockSize;let r=Math.max(i.column1.childHeight,i.column2.childHeight);this.applyNewHeight(i,r)}else if(i.type===`code`){let t=[e,r[0].inlineSize],n=this.queuedUpdates.get(i)??[];n.push(t),this.queuedUpdates.set(i,n)}}this.handleColumnChange()};handleColumnChange=()=>{for(let[e,t]of this.queuedUpdates)for(let[n,r]of t)if(n===e.codeElement){let n=Math.max(Math.floor(r),0);if(n!==e.codeWidth){let t=Math.max(n-e.numberWidth,0);e.codeWidth=n===0?`auto`:n,e.codeElement.style.setProperty(`--diffs-column-content-width`,`${t>0?`${t}px`:`auto`}`),e.codeElement.style.setProperty(`--diffs-column-width`,`${typeof e.codeWidth==`number`?`${e.codeWidth}px`:`auto`}`)}e.numberElement!=null&&typeof e.codeWidth==`number`&&e.numberWidth===0&&t.push([e.numberElement,e.numberElement.getBoundingClientRect().width])}else if(n===e.numberElement){let t=Math.max(Math.ceil(r),0);if(t!==e.numberWidth&&(e.numberWidth=t,e.codeElement.style.setProperty(`--diffs-column-number-width`,`${e.numberWidth===0?`auto`:`${e.numberWidth}px`}`),e.codeWidth!==`auto`)){let t=Math.max(e.codeWidth-e.numberWidth,0);e.codeElement.style.setProperty(`--diffs-column-content-width`,`${t===0?`auto`:`${t}px`}`)}}this.queuedUpdates.clear()};applyNewHeight(e,t){t!==e.currentHeight&&(e.currentHeight=Math.max(t,0),e.column1.container.style.setProperty(`--diffs-annotation-min-height`,`${e.currentHeight}px`),e.column2.container.style.setProperty(`--diffs-annotation-min-height`,`${e.currentHeight}px`))}};function o$(e,t){return e==null||t==null?e===t:e.startingLine===t.startingLine&&e.totalLines===t.totalLines&&e.bufferBefore===t.bufferBefore&&e.bufferAfter===t.bufferAfter}function s$(e){for(let t of Array.isArray(e)?e:[e])if(!(t===`text`||t===`ansi`)&&!KJ.has(t))return!1;return!0}function c$(e){for(let t of SZ(e))if(!VJ.has(t))return!1;return!0}function l$(e){return kZ({tagName:`div`,children:[kZ({tagName:`div`,children:e.annotations?.map(e=>kZ({tagName:`slot`,properties:{name:e}})),properties:{"data-annotation-content":``}})],properties:{"data-line-annotation":`${e.hunkIndex},${e.lineIndex}`}})}function u$(e,t){return kZ({tagName:`div`,children:e,properties:{"data-content":``,style:`grid-row: span ${t}`}})}function d$(e){switch(e){case`file`:return`diffs-icon-file-code`;case`change`:return`diffs-icon-symbol-modified`;case`new`:return`diffs-icon-symbol-added`;case`deleted`:return`diffs-icon-symbol-deleted`;case`rename-pure`:case`rename-changed`:return`diffs-icon-symbol-moved`}}function f$({fileOrDiff:e,mode:t}){let n=`type`in e?e:void 0,r={"data-diffs-header":t,"data-change-type":n?.type};return kZ({tagName:`div`,children:[t===`custom`?kZ({tagName:`slot`,properties:{name:EJ}}):p$({name:e.name,prevName:`prevName`in e?e.prevName:void 0,iconType:n?.type??`file`}),...t===`custom`?[]:[m$(n)]],properties:r})}function p$({name:e,prevName:t,iconType:n}){let r=[kZ({tagName:`slot`,properties:{name:wJ}}),AZ({name:d$(n),properties:{"data-change-icon":n}})];return t!=null&&(r.push(kZ({tagName:`div`,children:[kZ({tagName:`bdi`,children:[OZ(t)]})],properties:{"data-prev-name":``}})),r.push(AZ({name:`diffs-icon-arrow-right-short`,properties:{"data-rename-icon":``}}))),r.push(kZ({tagName:`div`,children:[kZ({tagName:`bdi`,children:[OZ(e)]})],properties:{"data-title":``}})),kZ({tagName:`div`,children:r,properties:{"data-header-content":``}})}function m$(e){let t=[];if(e!=null){let n=0,r=0;for(let t of e.hunks)n+=t.additionLines,r+=t.deletionLines;(r>0||n===0)&&t.push(kZ({tagName:`span`,children:[OZ(`-${r}`)],properties:{"data-deletions-count":``}})),(n>0||r===0)&&t.push(kZ({tagName:`span`,children:[OZ(`+${n}`)],properties:{"data-additions-count":``}}))}return t.push(kZ({tagName:`slot`,properties:{name:TJ}})),kZ({tagName:`div`,children:t,properties:{"data-metadata":``}})}function h$(e){return kZ({tagName:`pre`,properties:g$(e)})}function g$({diffIndicators:e,disableBackground:t,disableLineNumbers:n,overflow:r,split:i,totalLines:a,type:o,customProperties:s}){return{...s,"data-diff":o===`diff`?``:void 0,"data-file":o===`file`?``:void 0,"data-diff-type":o===`diff`?i?`split`:`single`:void 0,"data-overflow":r,"data-disable-line-numbers":n?``:void 0,"data-background":t?void 0:``,"data-indicators":e===`bars`||e===`classic`?e:void 0,tabIndex:0,style:`--diffs-min-number-column-width-default:${`${a}`.length}ch;`}}function _$(e,{theme:t,preferredHighlighter:n=`shiki-js`}){return{langs:[e??`text`],themes:SZ(t),preferredHighlighter:n}}function v$(e){return e.useTokenTransformer===!0||e.onTokenClick!=null||e.onTokenEnter!=null||e.onTokenLeave!=null}var y$=`<svg data-icon-sprite aria-hidden="true" width="0" height="0">
370
- <symbol id="diffs-icon-arrow-right-short" viewBox="0 0 16 16">
371
- <path d="M8.47 4.22a.75.75 0 0 0 0 1.06l1.97 1.97H3.75a.75.75 0 0 0 0 1.5h6.69l-1.97 1.97a.75.75 0 1 0 1.06 1.06l3.25-3.25a.75.75 0 0 0 0-1.06L9.53 4.22a.75.75 0 0 0-1.06 0"/>
372
- </symbol>
373
- <symbol id="diffs-icon-brand-github" viewBox="0 0 16 16">
374
- <path d="M8 0c4.42 0 8 3.58 8 8a8.01 8.01 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27s-1.36.09-2 .27c-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8"/>
375
- </symbol>
376
- <symbol id="diffs-icon-chevron" viewBox="0 0 16 16">
377
- <path d="M1.47 4.47a.75.75 0 0 1 1.06 0L8 9.94l5.47-5.47a.75.75 0 1 1 1.06 1.06l-6 6a.75.75 0 0 1-1.06 0l-6-6a.75.75 0 0 1 0-1.06"/>
378
- </symbol>
379
- <symbol id="diffs-icon-chevrons-narrow" viewBox="0 0 10 16">
380
- <path d="M4.47 2.22a.75.75 0 0 1 1.06 0l3.25 3.25a.75.75 0 0 1-1.06 1.06L5 3.81 2.28 6.53a.75.75 0 0 1-1.06-1.06zM1.22 9.47a.75.75 0 0 1 1.06 0L5 12.19l2.72-2.72a.75.75 0 0 1 1.06 1.06l-3.25 3.25a.75.75 0 0 1-1.06 0l-3.25-3.25a.75.75 0 0 1 0-1.06"/>
381
- </symbol>
382
- <symbol id="diffs-icon-diff-split" viewBox="0 0 16 16">
383
- <path d="M14 0H8.5v16H14a2 2 0 0 0 2-2V2a2 2 0 0 0-2-2m-1.5 6.5v1h1a.5.5 0 0 1 0 1h-1v1a.5.5 0 0 1-1 0v-1h-1a.5.5 0 0 1 0-1h1v-1a.5.5 0 0 1 1 0"/><path d="M2 0a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h5.5V0zm.5 7.5h3a.5.5 0 0 1 0 1h-3a.5.5 0 0 1 0-1" opacity=".3"/>
384
- </symbol>
385
- <symbol id="diffs-icon-diff-unified" viewBox="0 0 16 16">
386
- <path fill-rule="evenodd" d="M16 14a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V8.5h16zm-8-4a.5.5 0 0 0-.5.5v1h-1a.5.5 0 0 0 0 1h1v1a.5.5 0 0 0 1 0v-1h1a.5.5 0 0 0 0-1h-1v-1A.5.5 0 0 0 8 10" clip-rule="evenodd"/><path fill-rule="evenodd" d="M14 0a2 2 0 0 1 2 2v5.5H0V2a2 2 0 0 1 2-2zM6.5 3.5a.5.5 0 0 0 0 1h3a.5.5 0 0 0 0-1z" clip-rule="evenodd" opacity=".4"/>
387
- </symbol>
388
- <symbol id="diffs-icon-expand" viewBox="0 0 16 16">
389
- <path d="M3.47 5.47a.75.75 0 0 1 1.06 0L8 8.94l3.47-3.47a.75.75 0 1 1 1.06 1.06l-4 4a.75.75 0 0 1-1.06 0l-4-4a.75.75 0 0 1 0-1.06"/>
390
- </symbol>
391
- <symbol id="diffs-icon-expand-all" viewBox="0 0 16 16">
392
- <path d="M11.47 9.47a.75.75 0 1 1 1.06 1.06l-4 4a.75.75 0 0 1-1.06 0l-4-4a.75.75 0 1 1 1.06-1.06L8 12.94zM7.526 1.418a.75.75 0 0 1 1.004.052l4 4a.75.75 0 1 1-1.06 1.06L8 3.06 4.53 6.53a.75.75 0 1 1-1.06-1.06l4-4z"/>
393
- </symbol>
394
- <symbol id="diffs-icon-file-code" viewBox="0 0 16 16">
395
- <path d="M10.75 0c.199 0 .39.08.53.22l3.5 3.5c.14.14.22.331.22.53v9A2.75 2.75 0 0 1 12.25 16h-8.5A2.75 2.75 0 0 1 1 13.25V2.75A2.75 2.75 0 0 1 3.75 0zm-7 1.5c-.69 0-1.25.56-1.25 1.25v10.5c0 .69.56 1.25 1.25 1.25h8.5c.69 0 1.25-.56 1.25-1.25V5h-1.25A2.25 2.25 0 0 1 10 2.75V1.5z"/><path d="M7.248 6.19a.75.75 0 0 1 .063 1.058L5.753 9l1.558 1.752a.75.75 0 0 1-1.122.996l-2-2.25a.75.75 0 0 1 0-.996l2-2.25a.75.75 0 0 1 1.06-.063M8.69 7.248a.75.75 0 1 1 1.12-.996l2 2.25a.75.75 0 0 1 0 .996l-2 2.25a.75.75 0 1 1-1.12-.996L10.245 9z"/>
396
- </symbol>
397
- <symbol id="diffs-icon-plus" viewBox="0 0 16 16">
398
- <path d="M8 3a.75.75 0 0 1 .75.75v3.5h3.5a.75.75 0 0 1 0 1.5h-3.5v3.5a.75.75 0 0 1-1.5 0v-3.5h-3.5a.75.75 0 0 1 0-1.5h3.5v-3.5A.75.75 0 0 1 8 3"/>
399
- </symbol>
400
- <symbol id="diffs-icon-symbol-added" viewBox="0 0 16 16">
401
- <path d="M8 4a.75.75 0 0 1 .75.75v2.5h2.5a.75.75 0 0 1 0 1.5h-2.5v2.5a.75.75 0 0 1-1.5 0v-2.5h-2.5a.75.75 0 0 1 0-1.5h2.5v-2.5A.75.75 0 0 1 8 4"/><path d="M1.788 4.296c.196-.88.478-1.381.802-1.706s.826-.606 1.706-.802C5.194 1.588 6.387 1.5 8 1.5s2.806.088 3.704.288c.88.196 1.381.478 1.706.802s.607.826.802 1.706c.2.898.288 2.091.288 3.704s-.088 2.806-.288 3.704c-.195.88-.478 1.381-.802 1.706s-.826.607-1.706.802c-.898.2-2.091.288-3.704.288s-2.806-.088-3.704-.288c-.88-.195-1.381-.478-1.706-.802s-.606-.826-.802-1.706C1.588 10.806 1.5 9.613 1.5 8s.088-2.806.288-3.704M8 0C1.412 0 0 1.412 0 8s1.412 8 8 8 8-1.412 8-8-1.412-8-8-8"/>
402
- </symbol>
403
- <symbol id="diffs-icon-symbol-deleted" viewBox="0 0 16 16">
404
- <path d="M4 8a.75.75 0 0 1 .75-.75h6.5a.75.75 0 0 1 0 1.5h-6.5A.75.75 0 0 1 4 8"/><path d="M1.788 4.296c.196-.88.478-1.381.802-1.706s.826-.606 1.706-.802C5.194 1.588 6.387 1.5 8 1.5s2.806.088 3.704.288c.88.196 1.381.478 1.706.802s.607.826.802 1.706c.2.898.288 2.091.288 3.704s-.088 2.806-.288 3.704c-.195.88-.478 1.381-.802 1.706s-.826.607-1.706.802c-.898.2-2.091.288-3.704.288s-2.806-.088-3.704-.288c-.88-.195-1.381-.478-1.706-.802s-.606-.826-.802-1.706C1.588 10.806 1.5 9.613 1.5 8s.088-2.806.288-3.704M8 0C1.412 0 0 1.412 0 8s1.412 8 8 8 8-1.412 8-8-1.412-8-8-8"/>
405
- </symbol>
406
- <symbol id="diffs-icon-symbol-diffstat" viewBox="0 0 16 16">
407
- <path d="M1.788 4.296c.196-.88.478-1.381.802-1.706s.826-.606 1.706-.802C5.194 1.588 6.387 1.5 8 1.5s2.806.088 3.704.288c.88.196 1.381.478 1.706.802s.607.826.802 1.706c.2.898.288 2.091.288 3.704s-.088 2.806-.288 3.704c-.195.88-.478 1.381-.802 1.706s-.826.607-1.706.802c-.898.2-2.091.288-3.704.288s-2.806-.088-3.704-.288c-.88-.195-1.381-.478-1.706-.802s-.606-.826-.802-1.706C1.588 10.806 1.5 9.613 1.5 8s.088-2.806.288-3.704M8 0C1.412 0 0 1.412 0 8s1.412 8 8 8 8-1.412 8-8-1.412-8-8-8"/><path d="M8.75 4.296a.75.75 0 0 0-1.5 0V6.25h-2a.75.75 0 0 0 0 1.5h2v1.5h1.5v-1.5h2a.75.75 0 0 0 0-1.5h-2zM5.25 10a.75.75 0 0 0 0 1.5h5.5a.75.75 0 0 0 0-1.5z"/>
408
- </symbol>
409
- <symbol id="diffs-icon-symbol-ignored" viewBox="0 0 16 16">
410
- <path d="M1.5 8c0 1.613.088 2.806.288 3.704.196.88.478 1.381.802 1.706s.826.607 1.706.802c.898.2 2.091.288 3.704.288s2.806-.088 3.704-.288c.88-.195 1.381-.478 1.706-.802s.607-.826.802-1.706c.2-.898.288-2.091.288-3.704s-.088-2.806-.288-3.704c-.195-.88-.478-1.381-.802-1.706s-.826-.606-1.706-.802C10.806 1.588 9.613 1.5 8 1.5s-2.806.088-3.704.288c-.88.196-1.381.478-1.706.802s-.606.826-.802 1.706C1.588 5.194 1.5 6.387 1.5 8M0 8c0-6.588 1.412-8 8-8s8 1.412 8 8-1.412 8-8 8-8-1.412-8-8m11.53-2.47a.75.75 0 0 0-1.06-1.06l-6 6a.75.75 0 1 0 1.06 1.06z"/>
411
- </symbol>
412
- <symbol id="diffs-icon-symbol-modified" viewBox="0 0 16 16">
413
- <path d="M1.5 8c0 1.613.088 2.806.288 3.704.196.88.478 1.381.802 1.706s.826.607 1.706.802c.898.2 2.091.288 3.704.288s2.806-.088 3.704-.288c.88-.195 1.381-.478 1.706-.802s.607-.826.802-1.706c.2-.898.288-2.091.288-3.704s-.088-2.806-.288-3.704c-.195-.88-.478-1.381-.802-1.706s-.826-.606-1.706-.802C10.806 1.588 9.613 1.5 8 1.5s-2.806.088-3.704.288c-.88.196-1.381.478-1.706.802s-.606.826-.802 1.706C1.588 5.194 1.5 6.387 1.5 8M0 8c0-6.588 1.412-8 8-8s8 1.412 8 8-1.412 8-8 8-8-1.412-8-8m8 3a3 3 0 1 0 0-6 3 3 0 0 0 0 6"/>
414
- </symbol>
415
- <symbol id="diffs-icon-symbol-moved" viewBox="0 0 16 16">
416
- <path d="M1.788 4.296c.196-.88.478-1.381.802-1.706s.826-.606 1.706-.802C5.194 1.588 6.387 1.5 8 1.5s2.806.088 3.704.288c.88.196 1.381.478 1.706.802s.607.826.802 1.706c.2.898.288 2.091.288 3.704s-.088 2.806-.288 3.704c-.195.88-.478 1.381-.802 1.706s-.826.607-1.706.802c-.898.2-2.091.288-3.704.288s-2.806-.088-3.704-.288c-.88-.195-1.381-.478-1.706-.802s-.606-.826-.802-1.706C1.588 10.806 1.5 9.613 1.5 8s.088-2.806.288-3.704M8 0C1.412 0 0 1.412 0 8s1.412 8 8 8 8-1.412 8-8-1.412-8-8-8"/><path d="M8.495 4.695a.75.75 0 0 0-.05 1.06L10.486 8l-2.041 2.246a.75.75 0 0 0 1.11 1.008l2.5-2.75a.75.75 0 0 0 0-1.008l-2.5-2.75a.75.75 0 0 0-1.06-.051m-4 0a.75.75 0 0 0-.05 1.06l2.044 2.248-1.796 1.995a.75.75 0 0 0 1.114 1.004l2.25-2.5a.75.75 0 0 0-.002-1.007l-2.5-2.75a.75.75 0 0 0-1.06-.05"/>
417
- </symbol>
418
- <symbol id="diffs-icon-symbol-ref" viewBox="0 0 16 16">
419
- <path d="M1.5 8c0 1.613.088 2.806.288 3.704.196.88.478 1.381.802 1.706.286.286.71.54 1.41.73V1.86c-.7.19-1.124.444-1.41.73-.324.325-.606.826-.802 1.706C1.588 5.194 1.5 6.387 1.5 8m4 6.397c.697.07 1.522.103 2.5.103 1.613 0 2.806-.088 3.704-.288.88-.195 1.381-.478 1.706-.802s.607-.826.802-1.706c.2-.898.288-2.091.288-3.704s-.088-2.806-.288-3.704c-.195-.88-.478-1.381-.802-1.706s-.826-.606-1.706-.802C10.806 1.588 9.613 1.5 8 1.5c-.978 0-1.803.033-2.5.103zM0 8c0-6.588 1.412-8 8-8s8 1.412 8 8-1.412 8-8 8-8-1.412-8-8m7-2a1 1 0 0 1 1-1h3a1 1 0 0 1 1 1v1a1 1 0 0 1-1 1H8a1 1 0 0 1-1-1z"/>
420
- </symbol>
421
- </svg>`;function b$(e,t){return e==null||t==null?e===t:S$(e.customProperties,t.customProperties)&&e.type===t.type&&e.diffIndicators===t.diffIndicators&&e.disableBackground===t.disableBackground&&e.disableLineNumbers===t.disableLineNumbers&&e.overflow===t.overflow&&e.split===t.split&&e.totalLines===t.totalLines}var x$={};function S$(e=x$,t=x$){if(e===t)return!0;let n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(let r of n)if(e[r]!==t[r])return!1;return!0}function C$(e){let t=document.createElement(`div`);return t.dataset.annotationSlot=``,t.slot=e,t.style.whiteSpace=`normal`,t}function w$(){let e=document.createElement(`div`);return e.slot=`gutter-utility-slot`,e.style.position=`absolute`,e.style.top=`0`,e.style.bottom=`0`,e.style.textAlign=`center`,e.style.whiteSpace=`normal`,e}function T$(){let e=document.createElement(`style`);return e.setAttribute(kJ,``),e}var E$=`@layer base,theme,rendered,unsafe;@layer base{:host{--diffs-font-fallback:"SF Mono", Monaco, Consolas, "Ubuntu Mono", "Liberation Mono", "Courier New", monospace;--diffs-header-font-fallback:system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif;--diffs-mixer:light-dark(#000,#fff);--diffs-gap-fallback:8px;--diffs-added-light:#0dbe4e;--diffs-added-dark:#5ecc71;--diffs-modified-light:#009fff;--diffs-modified-dark:#69b1ff;--diffs-deleted-light:#ff2e3f;--diffs-deleted-dark:#ff6762;color-scheme:light dark;font-family:var(--diffs-header-font-family,var(--diffs-header-font-fallback));font-size:var(--diffs-font-size,13px);line-height:var(--diffs-line-height,20px);font-feature-settings:var(--diffs-font-features);--diffs-bg:light-dark(var(--diffs-light-bg,#fff),var(--diffs-dark-bg,#000));--diffs-bg-buffer:var(--diffs-bg-buffer-override,light-dark(color-mix(in lab, var(--diffs-bg) 92%, var(--diffs-mixer)),color-mix(in lab, var(--diffs-bg) 92%, var(--diffs-mixer))));--diffs-bg-context:var(--diffs-bg-context-override,light-dark(color-mix(in lab, var(--diffs-bg) 98.5%, var(--diffs-mixer)),color-mix(in lab, var(--diffs-bg) 92.5%, var(--diffs-mixer))));--diffs-bg-context-gutter:var(--diffs-bg-context-gutter-override,light-dark(color-mix(in lab, var(--diffs-bg-context) 90%, var(--diffs-bg)),color-mix(in lab, var(--diffs-bg-context) 45%, var(--diffs-bg))));--diffs-bg-separator:var(--diffs-bg-separator-override,light-dark(color-mix(in lab, var(--diffs-bg) 96%, var(--diffs-mixer)),color-mix(in lab, var(--diffs-bg) 85%, var(--diffs-mixer))));--diffs-fg:light-dark(var(--diffs-light,#000),var(--diffs-dark,#fff));--diffs-fg-number:var(--diffs-fg-number-override,light-dark(color-mix(in lab, var(--diffs-fg) 65%, var(--diffs-bg)),color-mix(in lab, var(--diffs-fg) 65%, var(--diffs-bg))));--diffs-fg-conflict-marker:var(--diffs-fg-conflict-marker-override,var(--diffs-fg-number));--diffs-deletion-base:var(--diffs-deletion-color-override,light-dark(var(--diffs-light-deletion-color,var(--diffs-deletion-color,var(--diffs-deleted-light))),var(--diffs-dark-deletion-color,var(--diffs-deletion-color,var(--diffs-deleted-dark)))));--diffs-addition-base:var(--diffs-addition-color-override,light-dark(var(--diffs-light-addition-color,var(--diffs-addition-color,var(--diffs-added-light))),var(--diffs-dark-addition-color,var(--diffs-addition-color,var(--diffs-added-dark)))));--diffs-modified-base:var(--diffs-modified-color-override,light-dark(var(--diffs-light-modified-color,var(--diffs-modified-color,var(--diffs-modified-light))),var(--diffs-dark-modified-color,var(--diffs-modified-color,var(--diffs-modified-dark)))));--diffs-bg-deletion:var(--diffs-bg-deletion-override,light-dark(color-mix(in lab, var(--diffs-bg) 88%, var(--diffs-deletion-base)),color-mix(in lab, var(--diffs-bg) 80%, var(--diffs-deletion-base))));--diffs-bg-deletion-emphasis:var(--diffs-bg-deletion-emphasis-override,light-dark(rgb(from var(--diffs-deletion-base) r g b / .15),rgb(from var(--diffs-deletion-base) r g b / .2)));--diffs-bg-addition:var(--diffs-bg-addition-override,light-dark(color-mix(in lab, var(--diffs-bg) 88%, var(--diffs-addition-base)),color-mix(in lab, var(--diffs-bg) 80%, var(--diffs-addition-base))));--diffs-bg-addition-emphasis:var(--diffs-bg-addition-emphasis-override,light-dark(rgb(from var(--diffs-addition-base) r g b / .15),rgb(from var(--diffs-addition-base) r g b / .2)));--diffs-selection-base:var(--diffs-modified-base);--diffs-selection-number-fg:light-dark(color-mix(in lab, var(--diffs-selection-base) 65%, var(--diffs-mixer)),color-mix(in lab, var(--diffs-selection-base) 75%, var(--diffs-mixer)));background-color:var(--diffs-bg);color:var(--diffs-fg);display:block}pre,code,[data-error-wrapper]{isolation:isolate;font-family:var(--diffs-font-family,var(--diffs-font-fallback));outline:none;margin:0;padding:0;display:block}pre,code{background-color:var(--diffs-bg)}code{contain:content}*,:before,:after{box-sizing:border-box}[data-icon-sprite]{display:none}[data-diffs-header],[data-separator]{font-family:var(--diffs-header-font-family,var(--diffs-header-font-fallback))}[data-file-info]{color:var(--fg);background-color:color-mix(in lab, var(--bg) 98%, var(--fg));border-block:1px solid color-mix(in lab, var(--bg) 95%, var(--fg));padding:10px;font-weight:700}[data-diff],[data-file]{--diffs-grid-number-column-width:minmax(min-content, max-content);--diffs-code-grid:var(--diffs-grid-number-column-width) 1fr}[data-dehydrated]:is([data-diff],[data-file]){--diffs-code-grid:var(--diffs-grid-number-column-width) minmax(0, 1fr)}:is([data-diff],[data-file]):hover [data-code]::-webkit-scrollbar-thumb{background-color:var(--diffs-bg-context)}[data-line] span{color:light-dark(var(--diffs-token-light,var(--diffs-light)),var(--diffs-token-dark,var(--diffs-dark)));background-color:light-dark(var(--diffs-token-light-bg,inherit),var(--diffs-token-dark-bg,inherit));font-weight:light-dark(var(--diffs-token-light-font-weight,inherit),var(--diffs-token-dark-font-weight,inherit));font-style:light-dark(var(--diffs-token-light-font-style,inherit),var(--diffs-token-dark-font-style,inherit));-webkit-text-decoration:light-dark(var(--diffs-token-light-text-decoration,inherit),var(--diffs-token-dark-text-decoration,inherit));text-decoration:light-dark(var(--diffs-token-light-text-decoration,inherit),var(--diffs-token-dark-text-decoration,inherit))}[data-line],[data-gutter-buffer],[data-column-number],[data-line-annotation],[data-no-newline],[data-merge-conflict],[data-merge-conflict-actions]{--diffs-computed-decoration-bg:var(--diffs-bg);--diffs-computed-diff-line-bg:var(--diffs-bg);--diffs-computed-selected-line-bg:var(--diffs-bg);color:var(--diffs-fg);background-color:var(--diffs-line-bg,var(--diffs-bg))}@media (pointer:fine){:is([data-line],[data-gutter-buffer],[data-column-number],[data-line-annotation],[data-no-newline],[data-merge-conflict],[data-merge-conflict-actions]):where([data-hovered]){--diffs-computed-hovered-line-bg:light-dark(color-mix(in lab, var(--diffs-computed-selected-line-bg) 97%, var(--diffs-bg-hover-override,var(--diffs-mixer))),color-mix(in lab, var(--diffs-computed-selected-line-bg) 91%, var(--diffs-bg-hover-override,var(--diffs-mixer))));--diffs-line-bg:var(--diffs-computed-hovered-line-bg,inherit)}}[data-decoration-bg]:is([data-line],[data-no-newline]){--mix-deco-light:92%;--mix-deco-dark:85%}[data-decoration-bg][data-decoration-bg-depth="2"]:is([data-line],[data-no-newline]){--mix-deco-light:88%;--mix-deco-dark:80%}[data-decoration-bg][data-decoration-bg-depth="3"]:is([data-line],[data-no-newline]){--mix-deco-light:85%;--mix-deco-dark:78%}@media (pointer:fine){[data-decoration-bg][data-hovered]:is([data-line],[data-no-newline]):not([data-selected-line]){--mix-deco-light:85%;--mix-deco-dark:85%}[data-decoration-bg][data-hovered][data-decoration-bg-depth="2"]:is([data-line],[data-no-newline]):not([data-selected-line]){--mix-deco-light:83%;--mix-deco-dark:83%}[data-decoration-bg][data-hovered][data-decoration-bg-depth="3"]:is([data-line],[data-no-newline]):not([data-selected-line]){--mix-deco-light:81%;--mix-deco-dark:81%}}[data-decoration-bg]:is([data-line],[data-no-newline]){--diffs-computed-decoration-bg:light-dark(color-mix(in lab, var(--diffs-bg) var(--mix-deco-light), var(--diffs-decoration-bg)),color-mix(in lab, var(--diffs-bg) var(--mix-deco-dark), var(--diffs-decoration-bg)));--diffs-computed-diff-line-bg:var(--diffs-computed-decoration-bg);--diffs-computed-selected-line-bg:var(--diffs-computed-decoration-bg);--diffs-line-bg:var(--diffs-computed-decoration-bg)}[data-line-annotation],[data-gutter-buffer=annotation]{--diffs-annotation-bg:var(--diffs-bg-context);--diffs-computed-decoration-bg:var(--diffs-annotation-bg);--diffs-computed-diff-line-bg:var(--diffs-annotation-bg);--diffs-computed-selected-line-bg:var(--diffs-annotation-bg);--diffs-line-bg:var(--diffs-annotation-bg)}[data-merge-conflict-actions],[data-gutter-buffer=merge-conflict-action],[data-gutter-buffer=merge-conflict-marker-base],[data-gutter-buffer=merge-conflict-marker-separator],[data-merge-conflict=marker-base],[data-merge-conflict=marker-separator]{--diffs-computed-decoration-bg:var(--diffs-bg-context);--diffs-computed-diff-line-bg:var(--diffs-bg-context);--diffs-computed-selected-line-bg:var(--diffs-bg-context);--diffs-line-bg:var(--diffs-bg-context)}[data-gutter-buffer=merge-conflict-marker-start],[data-merge-conflict=marker-start]{--diffs-computed-decoration-bg:light-dark(color-mix(in lab, var(--diffs-bg) 78%, var(--conflict-bg-current-header-override,var(--diffs-addition-base))),color-mix(in lab, var(--diffs-bg) 68%, var(--conflict-bg-current-header-override,var(--diffs-addition-base))));--diffs-computed-diff-line-bg:var(--diffs-computed-decoration-bg);--diffs-computed-selected-line-bg:var(--diffs-computed-decoration-bg);--diffs-line-bg:var(--diffs-computed-decoration-bg)}[data-gutter-buffer=merge-conflict-marker-end],[data-merge-conflict=marker-end]{--diffs-computed-decoration-bg:light-dark(color-mix(in lab, var(--diffs-bg) 78%, var(--conflict-bg-incoming-header-override,var(--diffs-modified-base))),color-mix(in lab, var(--diffs-bg) 68%, var(--conflict-bg-incoming-header-override,var(--diffs-modified-base))));--diffs-computed-diff-line-bg:var(--diffs-computed-decoration-bg);--diffs-computed-selected-line-bg:var(--diffs-computed-decoration-bg);--diffs-line-bg:var(--diffs-computed-decoration-bg)}[data-has-merge-conflict] [data-line-annotation],[data-has-merge-conflict] [data-gutter-buffer=annotation]{--diffs-computed-decoration-bg:var(--diffs-bg);--diffs-computed-diff-line-bg:var(--diffs-bg);--diffs-computed-selected-line-bg:var(--diffs-bg);--diffs-line-bg:var(--diffs-bg)}:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number]{--mix-light:91%;--mix-dark:85%}:where([data-background]) [data-line],:where([data-background]) [data-no-newline]{--mix-light:88%;--mix-dark:80%}:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]{--diffs-diff-line-mix-target:var(--diffs-bg)}[data-line-type=change-deletion]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]){--diffs-diff-line-mix-target:var(--diffs-bg-deletion-override,var(--diffs-deletion-base))}@media (pointer:fine){[data-line-type=change-deletion][data-hovered]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]){--mix-light:80%;--mix-dark:75%}}[data-line-type=change-deletion]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]):where([data-gutter-buffer],[data-column-number]){color:var(--diffs-fg-number-deletion-override,var(--diffs-deletion-base));--diffs-diff-line-mix-target:var(--diffs-bg-deletion-number-override,var(--diffs-deletion-base))}[data-line-type=change-deletion]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]){--diffs-computed-diff-line-bg:light-dark(color-mix(in lab, var(--diffs-computed-decoration-bg) var(--mix-light), var(--diffs-diff-line-mix-target)),color-mix(in lab, var(--diffs-computed-decoration-bg) var(--mix-dark), var(--diffs-diff-line-mix-target)));--diffs-computed-selected-line-bg:var(--diffs-computed-diff-line-bg);--diffs-line-bg:var(--diffs-computed-diff-line-bg,inherit)}[data-line-type=change-addition]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]){--diffs-diff-line-mix-target:var(--diffs-bg-addition-override,var(--diffs-addition-base))}@media (pointer:fine){[data-line-type=change-addition][data-hovered]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]){--mix-light:80%;--mix-dark:70%}}[data-line-type=change-addition]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]):where([data-gutter-buffer],[data-column-number]){color:var(--diffs-fg-number-addition-override,var(--diffs-addition-base));--diffs-diff-line-mix-target:var(--diffs-bg-addition-number-override,var(--diffs-addition-base))}[data-line-type=change-addition]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]){--diffs-computed-diff-line-bg:light-dark(color-mix(in lab, var(--diffs-computed-decoration-bg) var(--mix-light), var(--diffs-diff-line-mix-target)),color-mix(in lab, var(--diffs-computed-decoration-bg) var(--mix-dark), var(--diffs-diff-line-mix-target)));--diffs-computed-selected-line-bg:var(--diffs-computed-diff-line-bg);--diffs-line-bg:var(--diffs-computed-diff-line-bg,inherit)}[data-merge-conflict=current]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]){--diffs-diff-line-mix-target:var(--conflict-bg-current-override,var(--diffs-addition-base))}[data-merge-conflict=current]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]):where([data-gutter-buffer],[data-column-number]){color:var(--diffs-fg-number-addition-override,var(--diffs-addition-base));--diffs-diff-line-mix-target:var(--conflict-bg-current-number-override,var(--diffs-addition-base))}@media (pointer:fine){[data-merge-conflict=current][data-hovered]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]){--mix-light:80%;--mix-dark:70%}}[data-merge-conflict=current]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]){--diffs-computed-diff-line-bg:light-dark(color-mix(in lab, var(--diffs-computed-decoration-bg) var(--mix-light), var(--diffs-diff-line-mix-target)),color-mix(in lab, var(--diffs-computed-decoration-bg) var(--mix-dark), var(--diffs-diff-line-mix-target)));--diffs-computed-selected-line-bg:var(--diffs-computed-diff-line-bg);--diffs-line-bg:var(--diffs-computed-diff-line-bg,inherit)}[data-merge-conflict=incoming]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]){--diffs-diff-line-mix-target:var(--conflict-bg-incoming-override,var(--diffs-modified-base))}[data-merge-conflict=incoming]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]):where([data-gutter-buffer],[data-column-number]){color:var(--diffs-modified-base);--diffs-diff-line-mix-target:var(--conflict-bg-incoming-number-override,var(--diffs-modified-base))}@media (pointer:fine){[data-merge-conflict=incoming][data-hovered]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]){--mix-light:80%;--mix-dark:70%}}[data-merge-conflict=incoming]:is(:where([data-background]) [data-gutter-buffer],:where([data-background]) [data-column-number],:where([data-background]) [data-line],:where([data-background]) [data-no-newline]){--diffs-computed-diff-line-bg:light-dark(color-mix(in lab, var(--diffs-computed-decoration-bg) var(--mix-light), var(--diffs-diff-line-mix-target)),color-mix(in lab, var(--diffs-computed-decoration-bg) var(--mix-dark), var(--diffs-diff-line-mix-target)));--diffs-computed-selected-line-bg:var(--diffs-computed-diff-line-bg);--diffs-line-bg:var(--diffs-computed-diff-line-bg,inherit)}[data-gutter-buffer],[data-column-number],[data-line],[data-line-annotation],[data-merge-conflict],[data-merge-conflict-actions],[data-no-newline]{--diffs-selection-mix-target:var(--diffs-bg-selection-override,var(--diffs-selection-base))}[data-selected-line]:is([data-gutter-buffer],[data-column-number],[data-line],[data-line-annotation],[data-merge-conflict],[data-merge-conflict-actions],[data-no-newline]):where([data-line],[data-line-annotation],[data-merge-conflict],[data-merge-conflict-actions],[data-no-newline]){--mix-selection-light:82%;--mix-selection-dark:75%}@media (pointer:fine){[data-selected-line][data-hovered]:is([data-gutter-buffer],[data-column-number],[data-line],[data-line-annotation],[data-merge-conflict],[data-merge-conflict-actions],[data-no-newline]):where([data-line],[data-line-annotation],[data-merge-conflict],[data-merge-conflict-actions],[data-no-newline]):not([data-merge-conflict],[data-line-type=change-addition],[data-line-type=change-deletion]){--mix-selection-light:75%;--mix-selection-dark:70%}}[data-selected-line]:is([data-gutter-buffer],[data-column-number],[data-line],[data-line-annotation],[data-merge-conflict],[data-merge-conflict-actions],[data-no-newline]):where([data-gutter-buffer],[data-column-number]){--mix-selection-light:75%;--mix-selection-dark:60%;--diffs-selection-mix-target:var(--diffs-bg-selection-number-override,var(--diffs-selection-base))}@media (pointer:fine){[data-selected-line][data-hovered]:is([data-gutter-buffer],[data-column-number],[data-line],[data-line-annotation],[data-merge-conflict],[data-merge-conflict-actions],[data-no-newline]):where([data-gutter-buffer],[data-column-number]):not([data-merge-conflict],[data-line-type=change-addition],[data-line-type=change-deletion]){--mix-selection-light:70%;--mix-selection-dark:55%}}[data-selected-line]:is([data-gutter-buffer],[data-column-number],[data-line],[data-line-annotation],[data-merge-conflict],[data-merge-conflict-actions],[data-no-newline]){--diffs-computed-selected-line-bg:light-dark(color-mix(in lab, var(--diffs-computed-diff-line-bg) var(--mix-selection-light), var(--diffs-selection-mix-target)),color-mix(in lab, var(--diffs-computed-diff-line-bg) var(--mix-selection-dark), var(--diffs-selection-mix-target)));--diffs-line-bg:var(--diffs-computed-selected-line-bg,inherit)}[data-selected-line]:is([data-gutter-buffer],[data-column-number]){color:var(--diffs-selection-number-fg)}[data-no-newline]{-webkit-user-select:none;user-select:none}[data-no-newline] span{opacity:.6}[data-diff-type=split][data-overflow=scroll]{grid-template-columns:1fr 1fr;display:grid}[data-diff-type=split][data-overflow=scroll] [data-additions]{border-left:1px solid var(--diffs-bg)}[data-diff-type=split][data-overflow=scroll] [data-deletions]{border-right:1px solid var(--diffs-bg)}[data-code]{grid-auto-flow:dense;grid-template-columns:var(--diffs-code-grid);overscroll-behavior-x:none;tab-size:var(--diffs-tab-size,2);padding-top:var(--diffs-gap-block,var(--diffs-gap-fallback));padding-bottom:max(0px, calc(var(--diffs-gap-block,var(--diffs-gap-fallback)) - 6px));align-self:flex-start;display:grid;overflow:scroll clip}[data-container-size]{container-type:inline-size}[data-code]::-webkit-scrollbar{width:0;height:6px}[data-code]::-webkit-scrollbar-track{background:0 0}[data-code]::-webkit-scrollbar-thumb{background-color:#0000;background-clip:content-box;border:1px solid #0000;border-radius:3px}[data-code]::-webkit-scrollbar-corner{background-color:#0000}@supports ((-moz-appearance:none)){[data-code]{scrollbar-width:thin;scrollbar-color:var(--diffs-bg-context) transparent;padding-bottom:var(--diffs-gap-block,var(--diffs-gap-fallback))}}:is([data-diffs-header]~[data-diff],[data-diffs-header]~[data-file]) [data-code],[data-overflow=wrap]:is([data-diffs-header]~[data-diff],[data-diffs-header]~[data-file]){padding-top:0}[data-gutter]{grid-template-rows:subgrid;grid-template-columns:subgrid;z-index:3;background-color:var(--diffs-bg);grid-column:1;display:grid;position:relative}[data-gutter] [data-gutter-buffer],[data-gutter] [data-column-number]{border-right:var(--diffs-gap-style,2px solid var(--diffs-bg))}[data-content]{grid-template-rows:subgrid;grid-template-columns:subgrid;background-color:var(--diffs-bg);grid-column:2;min-width:0;display:grid}[data-diff-type=split][data-overflow=wrap]{grid-auto-flow:dense;grid-template-columns:repeat(2, var(--diffs-code-grid));padding-block:var(--diffs-gap-block,var(--diffs-gap-fallback));display:grid}[data-diff-type=split][data-overflow=wrap] [data-deletions]{display:contents}:is([data-diff-type=split][data-overflow=wrap] [data-deletions]) [data-gutter]{grid-column:1}:is([data-diff-type=split][data-overflow=wrap] [data-deletions]) [data-content]{border-right:1px solid var(--diffs-bg);grid-column:2}[data-diff-type=split][data-overflow=wrap] [data-additions]{display:contents}:is([data-diff-type=split][data-overflow=wrap] [data-additions]) [data-gutter]{border-left:1px solid var(--diffs-bg);grid-column:3}:is([data-diff-type=split][data-overflow=wrap] [data-additions]) [data-content]{grid-column:4}[data-overflow=scroll] [data-gutter]{position:sticky;left:0}[data-interactive-lines] [data-line]{cursor:pointer}[data-content-buffer],[data-gutter-buffer]{-webkit-user-select:none;user-select:none;min-height:1lh;position:relative}[data-gutter-buffer=annotation]{--diffs-annotation-bg:var(--diffs-bg-context-gutter);min-height:0}[data-gutter-buffer=buffer]{--diffs-line-bg:var(--diffs-bg-context-gutter)}[data-content-buffer]{background-position:5px 0;background-size:8px 8px;background-origin:border-box;background-image:repeating-linear-gradient(-45deg, transparent, transparent 4.242px, var(--diffs-bg-buffer) 4.242px, var(--diffs-bg-buffer) 5.656px);grid-column:1}[data-separator]{box-sizing:content-box;background-color:var(--diffs-bg)}[data-separator=simple]{min-height:4px}[data-separator=line-info],[data-separator=line-info-basic],[data-separator=metadata],[data-separator=simple]{background-color:var(--diffs-bg-separator)}[data-separator=line-info],[data-separator=line-info-basic],[data-separator=metadata]{height:32px;position:relative}[data-separator-wrapper]{-webkit-user-select:none;user-select:none;fill:currentColor;background-color:var(--diffs-bg);align-items:center;height:100%;display:flex;position:absolute;inset-inline:0}[data-content] [data-separator-wrapper]{display:none}[data-separator=metadata] [data-separator-wrapper]{background-color:var(--diffs-bg-separator);height:100%;color:var(--diffs-fg-number);white-space:nowrap;text-overflow:ellipsis;min-width:min-content;padding-inline:1ch;inset-inline:100% auto;overflow:hidden}[data-separator=line-info]{margin-block:var(--diffs-gap-block,var(--diffs-gap-fallback))}[data-separator=line-info] [data-separator-wrapper]{min-width:16px}[data-separator=line-info-basic],[data-separator=metadata]{margin-block:0}[data-separator=line-info][data-separator-first]{margin-top:0}[data-separator=line-info][data-separator-last]{margin-bottom:0}[data-expand-index] [data-separator-wrapper]{grid-template-columns:32px auto;display:grid}[data-expand-index] [data-separator-wrapper][data-separator-multi-button]{grid-template-columns:32px 32px auto}[data-expand-button],[data-separator-content]{background-color:var(--diffs-bg-separator);flex:none;align-items:center;display:flex}[data-expand-index] [data-separator-content]:hover{cursor:pointer;text-decoration:underline}[data-expand-button]{cursor:pointer;min-width:32px;color:var(--diffs-fg-number);border-right:2px solid var(--diffs-bg);flex-shrink:0;justify-content:center;align-self:stretch}[data-expand-button]:hover{color:var(--diffs-fg)}[data-expand-button][data-expand-all-button]{display:none}[data-expand-down] [data-icon]{transform:scaleY(-1)}[data-separator-content]{height:100%;color:var(--diffs-fg-number);flex:auto;justify-content:flex-start;padding:0 1ch;overflow:hidden}:is([data-separator=line-info],[data-separator=line-info-basic]) [data-separator-content]{-webkit-user-select:none;user-select:none;height:100%;overflow:clip}[data-unmodified-lines]{text-overflow:ellipsis;white-space:nowrap;flex:0 auto;min-width:0;display:block;overflow:hidden}@supports (width:1cqi){[data-unified] [data-separator=line-info] [data-separator-wrapper]{padding-inline:var(--diffs-gap-inline,var(--diffs-gap-fallback));width:100cqi}:is([data-unified] [data-separator=line-info] [data-separator-wrapper]) [data-separator-content]{border-radius:6px}[data-unified] [data-separator=line-info][data-expand-index] [data-separator-wrapper] [data-separator-content]{border-top-left-radius:unset;border-bottom-left-radius:unset}[data-gutter] [data-separator=line-info] [data-separator-wrapper]{padding-left:var(--diffs-gap-inline,var(--diffs-gap-fallback))}[data-gutter] [data-separator=line-info] [data-separator-content]{border-top-left-radius:6px;border-bottom-left-radius:6px}[data-gutter] [data-separator=line-info][data-expand-index] [data-separator-content]{border-top-left-radius:unset;border-bottom-left-radius:unset}[data-additions] [data-content] [data-separator=line-info]{background-color:var(--diffs-bg)}:is([data-additions] [data-content] [data-separator=line-info]) [data-separator-wrapper]{display:none}[data-additions] [data-gutter] [data-separator=line-info] [data-separator-wrapper]{background-color:var(--diffs-bg-separator);border-top-right-radius:6px;border-bottom-right-radius:6px;height:100%;display:block}:is([data-additions] [data-gutter] [data-separator=line-info] [data-separator-wrapper]) [data-separator-content],:is([data-additions] [data-gutter] [data-separator=line-info] [data-separator-wrapper]) [data-expand-button]{display:none}[data-overflow=scroll] [data-additions] [data-gutter] [data-separator=line-info] [data-separator-wrapper]{width:calc(100cqi - var(--diffs-gap-inline,var(--diffs-gap-fallback)))}[data-overflow=wrap] [data-additions] [data-content] [data-separator=line-info] [data-separator-wrapper]{background-color:var(--diffs-bg-separator);height:100%;margin-right:var(--diffs-gap-inline,var(--diffs-gap-fallback));border-top-right-radius:6px;border-bottom-right-radius:6px;display:block}:is([data-overflow=wrap] [data-additions] [data-content] [data-separator=line-info] [data-separator-wrapper]) [data-separator-content],:is([data-overflow=wrap] [data-additions] [data-content] [data-separator=line-info] [data-separator-wrapper]) [data-expand-button]{display:none}:is([data-separator=line-info] [data-separator-wrapper]) [data-expand-both],:is([data-separator=line-info] [data-separator-wrapper]) [data-expand-down],:is([data-separator=line-info] [data-separator-wrapper]) [data-expand-up]{border-top-left-radius:6px;border-bottom-left-radius:6px}@media (pointer:fine){[data-separator-multi-button]:is([data-separator=line-info] [data-separator-wrapper]) [data-expand-up]{border-top-left-radius:6px;border-bottom-left-radius:unset}[data-separator-multi-button]:is([data-separator=line-info] [data-separator-wrapper]) [data-expand-down]{border-bottom-left-radius:6px;border-top-left-radius:unset}}}@media (pointer:coarse){[data-separator=line-info-basic] [data-separator-wrapper][data-separator-multi-button]{grid-template-columns:34px 34px auto}:is([data-separator=line-info-basic] [data-separator-wrapper][data-separator-multi-button]) [data-separator-content]{grid-column:unset;grid-row:unset}@supports (width:1cqi){:is([data-separator=line-info] [data-separator-wrapper]) [data-expand-both],:is([data-separator=line-info] [data-separator-wrapper]) [data-expand-down],:is([data-separator=line-info] [data-separator-wrapper]) [data-expand-up],[data-separator-multi-button]:is([data-separator=line-info] [data-separator-wrapper]) [data-expand-up]{border-top-left-radius:6px;border-bottom-left-radius:6px}[data-separator-multi-button]:is([data-separator=line-info] [data-separator-wrapper]) [data-expand-down]{border-bottom-left-radius:unset;border-top-left-radius:unset}}}@media (pointer:fine){[data-separator-wrapper][data-separator-multi-button]{grid-template-rows:50% 50%;display:grid}[data-separator-wrapper][data-separator-multi-button] [data-separator-content]{grid-area:1/2/-1;min-width:min-content}[data-separator-wrapper][data-separator-multi-button] [data-expand-button]{grid-column:1}[data-separator=line-info] [data-separator-wrapper],[data-separator=line-info] [data-separator-wrapper][data-separator-multi-button]{grid-template-columns:34px auto}[data-separator=line-info-basic][data-expand-index] [data-separator-wrapper]{grid-template-columns:100% auto}:is(:is([data-separator=line-info],[data-separator=line-info-basic]) [data-separator-multi-button]) [data-expand-up]{border-bottom:1px solid var(--diffs-bg);border-right:2px solid var(--diffs-bg)}:is(:is([data-separator=line-info],[data-separator=line-info-basic]) [data-separator-multi-button]) [data-expand-down]{border-top:1px solid var(--diffs-bg);border-right:2px solid var(--diffs-bg)}}[data-additions] [data-gutter] [data-separator-wrapper],[data-additions] [data-separator=line-info-basic] [data-separator-wrapper],[data-content] [data-separator-wrapper]{display:none}[data-line-annotation]{min-height:var(--diffs-annotation-min-height,0);z-index:2}[data-merge-conflict-actions]{z-index:2}[data-separator=custom]{grid-template-columns:subgrid;display:grid}[data-line],[data-column-number],[data-no-newline]{padding-inline:1ch;position:relative}[data-indicators=classic] [data-line]{padding-inline-start:2ch}:is([data-no-newline]:is([data-indicators=classic] [data-line-type=change-addition],[data-indicators=classic] [data-line-type=change-deletion]),[data-line]:is([data-indicators=classic] [data-line-type=change-addition],[data-indicators=classic] [data-line-type=change-deletion])):before{-webkit-user-select:none;user-select:none;width:1ch;height:1lh;display:inline-block;position:absolute;top:0;left:0}:is([data-line]:is([data-indicators=classic] [data-line-type=change-addition]),[data-no-newline]:is([data-indicators=classic] [data-line-type=change-addition])):before{content:"+";color:var(--diffs-addition-base)}:is([data-line]:is([data-indicators=classic] [data-line-type=change-deletion]),[data-no-newline]:is([data-indicators=classic] [data-line-type=change-deletion])):before{content:"-";color:var(--diffs-deletion-base)}[data-column-number]:is([data-indicators=bars] [data-line-type=change-deletion],[data-indicators=bars] [data-line-type=change-addition]):before{content:"";-webkit-user-select:none;user-select:none;contain:strict;width:4px;height:100%;display:block;position:absolute;top:0;left:0}[data-column-number]:is([data-indicators=bars] [data-line-type=change-deletion]):before{background-image:linear-gradient(0deg, var(--diffs-bg-deletion) 50%, var(--diffs-deletion-base) 50%);background-repeat:repeat;background-size:2px 2px;background-size:calc(1lh/round(1lh / 2px)) calc(1lh/round(1lh / 2px))}[data-column-number]:is([data-indicators=bars] [data-line-type=change-addition]):before{background-color:var(--diffs-addition-base)}[data-overflow=wrap] [data-line],[data-overflow=wrap] [data-annotation-content]{white-space:pre-wrap;word-break:break-word}[data-overflow=scroll] [data-line]{white-space:pre;min-height:1lh}[data-column-number]{box-sizing:content-box;text-align:right;-webkit-user-select:none;user-select:none;color:var(--diffs-fg-number);padding-left:2ch}[data-line-number-content]{min-width:var(--diffs-min-number-column-width,var(--diffs-min-number-column-width-default,3ch));z-index:1;display:inline-block;position:relative}[data-disable-line-numbers] [data-gutter-buffer],[data-disable-line-numbers] [data-column-number]{min-width:4px;padding:0}:is([data-disable-line-numbers] [data-gutter-buffer],[data-disable-line-numbers] [data-column-number]):before{min-width:0}[data-disable-line-numbers] [data-line-number-content]{display:none}[data-disable-line-numbers] [data-gutter-utility-slot]{right:unset;justify-content:flex-start;left:0}[data-disable-line-numbers][data-indicators=bars] [data-gutter-utility-slot]{left:6px}[data-file][data-disable-line-numbers] [data-gutter-buffer],[data-file][data-disable-line-numbers] [data-column-number]{border-right:0;min-width:0}[data-interactive-line-numbers] [data-column-number]{cursor:pointer}[data-diff-span]{-webkit-box-decoration-break:clone;box-decoration-break:clone;border-radius:3px}[data-line-type=change-addition] [data-diff-span]{background-color:var(--diffs-bg-addition-emphasis)}[data-line-type=change-deletion] [data-diff-span]{background-color:var(--diffs-bg-deletion-emphasis)}[data-merge-conflict=marker-start],[data-merge-conflict=marker-base],[data-merge-conflict=marker-separator],[data-merge-conflict=marker-end]{color:var(--diffs-fg);padding-left:1ch}[data-merge-conflict=marker-start],[data-merge-conflict=marker-end]{align-items:center;display:flex}:is([data-merge-conflict=marker-start],[data-merge-conflict=marker-end]):after{color:var(--diffs-fg-conflict-marker);font-size:.75rem;font-style:normal;line-height:1.25rem;font-family:var(--diffs-header-font-family,var(--diffs-header-font-fallback));padding-left:1ch}[data-merge-conflict=marker-start]:after{content:"(Current Change)"}[data-merge-conflict=marker-end]:after{content:"(Incoming Change)"}[data-merge-conflict-actions-content]{min-height:1.75rem;font-family:var(--diffs-header-font-family,var(--diffs-header-font-fallback));color:var(--diffs-fg);align-items:center;gap:.25rem;padding-inline:.5rem;font-size:.75rem;line-height:1.2;display:flex}[data-merge-conflict-action]{appearance:none;color:var(--diffs-fg-number);font:inherit;cursor:pointer;background:0 0;border:0;padding:0;font-style:normal}[data-merge-conflict-action]:hover{color:var(--diffs-fg)}[data-merge-conflict-action=current]:hover{color:var(--diffs-addition-base)}[data-merge-conflict-action=incoming]:hover{color:var(--diffs-modified-base)}[data-merge-conflict-action-separator]{color:var(--diffs-fg-number);opacity:.6;-webkit-user-select:none;user-select:none}[data-diffs-header=default]{background-color:var(--diffs-bg);justify-content:space-between;align-items:center;gap:var(--diffs-gap-inline,var(--diffs-gap-fallback));min-height:calc(1lh + var(--diffs-gap-block,var(--diffs-gap-fallback))*3);z-index:2;flex-direction:row;padding-inline:16px;display:flex;position:relative;top:0}[data-header-content]{align-items:center;gap:var(--diffs-gap-inline,var(--diffs-gap-fallback));white-space:nowrap;flex-direction:row;min-width:0;display:flex}[data-header-content] [data-prev-name],[data-header-content] [data-title]{text-overflow:ellipsis;white-space:nowrap;direction:rtl;min-width:0;overflow:hidden}[data-prev-name]{opacity:.7}[data-rename-icon]{fill:currentColor;flex-grow:0;flex-shrink:0}[data-diffs-header=default] [data-metadata]{white-space:nowrap;align-items:center;gap:1ch;display:flex}[data-diffs-header=default] [data-additions-count]{font-family:var(--diffs-font-family,var(--diffs-font-fallback));color:var(--diffs-addition-base)}[data-diffs-header=default] [data-deletions-count]{font-family:var(--diffs-font-family,var(--diffs-font-fallback));color:var(--diffs-deletion-base)}[data-change-icon]{fill:currentColor;flex-shrink:0}[data-change-icon=change],[data-change-icon=rename-pure],[data-change-icon=rename-changed]{color:var(--diffs-modified-base)}[data-change-icon=new]{color:var(--diffs-addition-base)}[data-change-icon=deleted]{color:var(--diffs-deletion-base)}[data-change-icon=file]{opacity:.6}[data-annotation-content]{z-index:2;isolation:isolate;align-self:flex-start;min-width:0;display:flow-root;position:relative}[data-overflow=scroll] [data-annotation-content],[data-overflow=scroll] [data-merge-conflict-actions-content]{width:var(--diffs-column-content-width,auto);left:var(--diffs-column-number-width,0);position:sticky}[data-annotation-slot]{text-wrap-mode:wrap;word-break:normal;white-space-collapse:collapse}[data-gutter-utility-slot]{justify-content:flex-end;display:flex;position:absolute;top:0;bottom:0;right:0}[data-utility-button]{appearance:none;cursor:pointer;width:1lh;height:1lh;font-size:var(--diffs-font-size,13px);line-height:var(--diffs-line-height,20px);background-color:var(--diffs-modified-base);color:var(--diffs-bg);fill:currentColor;z-index:4;border:none;border-radius:4px;justify-content:center;align-items:center;margin-right:calc(1ch - 1lh);padding:0;display:flex;position:relative}[data-decoration-bar-stack]{pointer-events:none;isolation:isolate;z-index:1;background-color:var(--diffs-decoration-bar-color,transparent);box-sizing:content-box;border-left:2px solid var(--diffs-bg);border-right:2px solid var(--diffs-bg);width:6px;position:absolute;top:0;bottom:0;right:-2px}[data-decoration-bar-depth="1"] [data-decoration-bar-stack]{background-color:color-mix(in lab, var(--diffs-bg) 20%, var(--diffs-decoration-bar-color,transparent))}[data-decoration-bar-depth="2"] [data-decoration-bar-stack]{background-color:color-mix(in lab, var(--diffs-bg) 45%, var(--diffs-decoration-bar-color,transparent))}[data-decoration-bar-depth="3"] [data-decoration-bar-stack]{background-color:color-mix(in lab, var(--diffs-bg) 65%, var(--diffs-decoration-bar-color,transparent))}[data-decoration-bar-start] [data-decoration-bar-stack]{border-top-left-radius:5px;border-top-right-radius:5px}[data-decoration-bar-end] [data-decoration-bar-stack]{z-index:3;border-bottom-right-radius:5px;border-bottom-left-radius:5px}[data-placeholder]{contain:strict}[data-error-wrapper]{padding:var(--diffs-gap-block,var(--diffs-gap-fallback)) var(--diffs-gap-inline,var(--diffs-gap-fallback));scrollbar-width:none;max-height:400px;overflow:auto}[data-error-wrapper] [data-error-message]{color:var(--diffs-deletion-base);font-size:18px;font-weight:700}[data-error-wrapper] [data-error-stack]{color:var(--diffs-fg-number)}}@layer theme,rendered,unsafe;`,D$=`@layer base, theme, rendered, unsafe;`;function O$(e){return`${D$}
422
- @layer unsafe {
423
- ${e}
424
- }`}function k$(e,t=`system`){return`${D$}
425
- @layer rendered {
426
- :host {${t===`system`?``:`
427
- color-scheme: ${t};`}
428
- ${e}
429
- }
430
- }`}function A$({code:e,pre:t,columnType:n,rowSpan:r,containerSize:i=!1}={}){return e??(e=document.createElement(`code`),e.setAttribute(`data-code`,``),n!=null&&e.setAttribute(`data-${n}`,``),t?.appendChild(e)),r==null?e.style.removeProperty(`grid-row`):e.style.setProperty(`grid-row`,`span ${r}`),i?e.setAttribute(`data-container-size`,``):e.removeAttribute(`data-container-size`),e}function j$({shadowRoot:e,currentNode:t,themeCSS:n}){if(n.trim()===``){t?.remove();return}return t??=M$(),t.textContent=n,t.parentNode!==e&&e.appendChild(t),t}function M$(){let e=document.createElement(`style`);return e.setAttribute(OJ,``),e}function N$(e,t){if(t==null)return;let n=e.shadowRoot??e.attachShadow({mode:`open`});n.innerHTML===``&&(n.innerHTML=t)}function P$(e,{type:t,diffIndicators:n,disableBackground:r,disableLineNumbers:i,overflow:a,split:o,totalLines:s,customProperties:c}){if(c!=null)for(let t in c){let n=c[t];n!=null&&e.setAttribute(t,`${n}`)}switch(t===`diff`?(e.setAttribute(`data-diff`,``),e.removeAttribute(`data-file`)):(e.setAttribute(`data-file`,``),e.removeAttribute(`data-diff`)),n){case`bars`:case`classic`:e.setAttribute(`data-indicators`,n);break;case`none`:e.removeAttribute(`data-indicators`);break}return i?e.setAttribute(`data-disable-line-numbers`,``):e.removeAttribute(`data-disable-line-numbers`),r?e.removeAttribute(`data-background`):e.setAttribute(`data-background`,``),t===`diff`?e.setAttribute(`data-diff-type`,o?`split`:`single`):e.removeAttribute(`data-diff-type`),e.setAttribute(`data-overflow`,a),e.tabIndex=0,e.style.setProperty(`--diffs-min-number-column-width-default`,`${`${s}`.length}ch`),e}if(typeof HTMLElement<`u`&&customElements.get(`diffs-container`)==null){let e;class t extends HTMLElement{constructor(){if(super(),this.shadowRoot!=null)return;let t=this.attachShadow({mode:`open`});e??(e=new CSSStyleSheet,e.replaceSync(E$)),t.adoptedStyleSheets=[e]}}customElements.define(pJ,t)}function F$(e,t,n){if(e===t||e==null||t==null)return e===t;let r=new Set(n),i=Object.keys(e),a=new Set(Object.keys(t));for(let n of i)if(a.delete(n),!r.has(n)&&(!(n in t)||e[n]!==t[n]))return!1;for(let e of Array.from(a))if(!r.has(e))return!1;return!0}function I$(e,t){let n=e?.theme??DJ,r=t?.theme??DJ,i=L$(e),a=L$(t);return CZ(n,r)&&F$(e,t,[`theme`,`parseDiffOptions`])&&F$(i,a)}function L$(e){if(e!=null&&`parseDiffOptions`in e)return e.parseDiffOptions}function R$({hunkIndex:e,lineIndex:t,conflictIndex:n}){return`merge-conflict-action-${e}-${t}-${n}`}function z$(e,t){let n=t.hunks[e.hunkIndex];if(n!=null)return{hunkIndex:e.hunkIndex,lineIndex:B$(n,e.startContentIndex)}}function B$(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 V$({fileDiff:e,actions:t,renderCustomHeader:n,renderHeaderPrefix:r,renderHeaderMetadata:i,renderAnnotation:a,renderGutterUtility:o,renderHoverUtility:s,renderMergeConflictUtility:c,lineAnnotations:l,getHoveredLine:u,getInstance:d}){let f=o??s,p=n?.(e),m=r?.(e),h=i?.(e);return(0,_.jsxs)(_.Fragment,{children:[p==null?(0,_.jsxs)(_.Fragment,{children:[m!=null&&(0,_.jsx)(`div`,{slot:`header-prefix`,children:m}),h!=null&&(0,_.jsx)(`div`,{slot:`header-metadata`,children:h})]}):(0,_.jsx)(`div`,{slot:EJ,children:p}),a!=null&&l?.map((e,t)=>(0,_.jsx)(`div`,{slot:PJ(e),children:a(e)},t)),t!=null&&c!=null&&d!=null&&t.map(t=>{if(t==null)return;let n=H$(t,e);return(0,_.jsx)(`div`,{slot:n,style:dJ,children:c(t,d)},n)}),f!=null&&(0,_.jsx)(`div`,{slot:`gutter-utility-slot`,style:uJ,children:f(u)})]})}function H$(e,t){let n=z$(e,t);return n==null?void 0:R$({hunkIndex:n.hunkIndex,lineIndex:n.lineIndex,conflictIndex:e.conflictIndex})}var U$=class{isDeletionsScrolling=!1;isAdditionsScrolling=!1;timeoutId=-1;codeDeletions;codeAdditions;enabled=!1;cleanUp(){this.enabled&&=(this.codeDeletions?.removeEventListener(`scroll`,this.handleDeletionsScroll),this.codeAdditions?.removeEventListener(`scroll`,this.handleAdditionsScroll),clearTimeout(this.timeoutId),this.codeDeletions=void 0,this.codeAdditions=void 0,!1)}setup(e,t,n){if(t==null||n==null)for(let r of e.children??[])r instanceof HTMLElement&&(`deletions`in r.dataset?t=r:`additions`in r.dataset&&(n=r));if(n==null||t==null){this.cleanUp();return}this.codeDeletions!==t&&(this.codeDeletions?.removeEventListener(`scroll`,this.handleDeletionsScroll),this.codeDeletions=t,t.addEventListener(`scroll`,this.handleDeletionsScroll,{passive:!0})),this.codeAdditions!==n&&(this.codeAdditions?.removeEventListener(`scroll`,this.handleAdditionsScroll),this.codeAdditions=n,n.addEventListener(`scroll`,this.handleAdditionsScroll,{passive:!0})),this.enabled=!0}handleDeletionsScroll=()=>{this.isAdditionsScrolling||(this.isDeletionsScrolling=!0,clearTimeout(this.timeoutId),this.timeoutId=setTimeout(()=>{this.isDeletionsScrolling=!1},300),this.codeAdditions?.scrollTo({left:this.codeDeletions?.scrollLeft}))};handleAdditionsScroll=()=>{this.isDeletionsScrolling||(this.isAdditionsScrolling=!0,clearTimeout(this.timeoutId),this.timeoutId=setTimeout(()=>{this.isAdditionsScrolling=!1},300),this.codeDeletions?.scrollTo({left:this.codeAdditions?.scrollLeft}))}};function W$(e){return kZ({tagName:`div`,properties:{"data-content-buffer":``,"data-buffer-size":e,style:`grid-row: span ${e};min-height:calc(${e} * 1lh)`}})}function G$(e){return kZ({tagName:`div`,children:[kZ({tagName:`span`,children:[OZ(`No newline at end of file`)]})],properties:{"data-no-newline":``,"data-line-type":e,"data-column-content":``}})}function K$(e){return kZ({tagName:`div`,children:[AZ({name:e===`both`?`diffs-icon-expand-all`:`diffs-icon-expand`,properties:{"data-icon":``}})],properties:{role:`button`,"data-expand-button":``,"data-expand-both":e===`both`?``:void 0,"data-expand-up":e===`up`?``:void 0,"data-expand-down":e===`down`?``:void 0}})}function q$({type:e,content:t,expandIndex:n,chunked:r=!1,slotName:i,isFirstHunk:a,isLastHunk:o}){let s=0,c=[];if(e===`metadata`&&t!=null&&c.push(kZ({tagName:`div`,children:[OZ(t)],properties:{"data-separator-wrapper":``}})),(e===`line-info`||e===`line-info-basic`)&&t!=null){let e=[];n!=null&&(r?(a||(e.push(K$(`up`)),s++),o||(e.push(K$(`down`)),s++)):(e.push(K$(!a&&!o?`both`:a?`down`:`up`)),s++)),e.push(kZ({tagName:`div`,children:[kZ({tagName:`span`,children:[OZ(t)],properties:{"data-unmodified-lines":``}})],properties:{"data-separator-content":``}})),r&&n!=null&&e.push(kZ({tagName:`div`,children:[OZ(`Expand all`)],properties:{role:`button`,"data-expand-button":``,"data-expand-all-button":``}})),c.push(kZ({tagName:`div`,children:e,properties:{"data-separator-wrapper":``,"data-separator-multi-button":s>1?``:void 0}}))}return e===`custom`&&i!=null&&c.push(kZ({tagName:`slot`,properties:{name:i}})),kZ({tagName:`div`,children:c,properties:{"data-separator":c.length===0?`simple`:e,"data-expand-index":n,"data-separator-first":a?``:void 0,"data-separator-last":o?``:void 0}})}function J$(e,t){return`hunk-separator-${e}-${t}`}function Y$(e){let t=e.at(-1);return t==null?0:Math.max(t.additionStart+t.additionCount,t.deletionStart+t.deletionCount)}function X$(e){return e.startingLine===0&&e.totalLines===1/0&&e.bufferBefore===0&&e.bufferAfter===0}var Z$=-1,Q$=class{__id=`diff-hunks-renderer:${++Z$}`;highlighter;diff;expandedHunks=new Map;deletionAnnotations={};additionAnnotations={};computedLang=`text`;renderCache;constructor(e={theme:DJ},t,n){this.options=e,this.onRenderUpdate=t,this.workerManager=n,n?.isWorkingPool()!==!0&&(this.highlighter=c$(e.theme??DJ)?bZ():void 0)}cleanUp(){this.highlighter=void 0,this.diff=void 0,this.renderCache=void 0,this.workerManager?.cleanUpPendingTasks(this),this.workerManager=void 0,this.onRenderUpdate=void 0}recycle(){this.highlighter=void 0,this.diff=void 0,this.renderCache=void 0,this.workerManager?.cleanUpPendingTasks(this)}setOptions(e){this.options=e}mergeOptions(e){this.options={...this.options,...e}}expandHunk(e,t,n=this.getOptionsWithDefaults().expansionLineCount){let r={...this.expandedHunks.get(e)??{fromStart:0,fromEnd:0}};(t===`up`||t===`both`)&&(r.fromStart+=n),(t===`down`||t===`both`)&&(r.fromEnd+=n),this.renderCache?.highlighted!==!0&&(this.renderCache=void 0),this.expandedHunks.set(e,r)}getExpandedHunk(e){return this.expandedHunks.get(e)??jJ}getExpandedHunksMap(){return this.expandedHunks}setLineAnnotations(e){this.additionAnnotations={},this.deletionAnnotations={};for(let t of e){let e=(()=>{switch(t.side){case`deletions`:return this.deletionAnnotations;case`additions`:return this.additionAnnotations}})(),n=e[t.lineNumber]??[];e[t.lineNumber]=n,n.push(t)}}getUnifiedLineDecoration({lineType:e}){return{gutterLineType:e}}getSplitLineDecoration({side:e,type:t}){return t===`change`?{gutterLineType:e===`deletions`?`change-deletion`:`change-addition`}:{gutterLineType:t}}createAnnotationElement(e){return l$(e)}getOptionsWithDefaults(){let{diffIndicators:e=`bars`,diffStyle:t=`split`,disableBackground:n=!1,disableFileHeader:r=!1,disableLineNumbers:i=!1,disableVirtualizationBuffers:a=!1,collapsed:o=!1,expandUnchanged:s=!1,collapsedContextThreshold:c=1,expansionLineCount:l=100,hunkSeparators:u=`line-info`,lineDiffType:d=`word-alt`,maxLineDiffLength:f=1e3,overflow:p=`scroll`,theme:m=DJ,headerRenderMode:h=`default`,tokenizeMaxLineLength:g=1e3,useTokenTransformer:_=!1,useCSSClasses:v=!1}=this.options;return{diffIndicators:e,diffStyle:t,disableBackground:n,disableFileHeader:r,disableLineNumbers:i,disableVirtualizationBuffers:a,collapsed:o,expandUnchanged:s,collapsedContextThreshold:c,expansionLineCount:l,hunkSeparators:u,lineDiffType:d,maxLineDiffLength:f,overflow:p,theme:this.workerManager?.getDiffRenderOptions().theme??m,headerRenderMode:h,tokenizeMaxLineLength:g,useTokenTransformer:_,useCSSClasses:v}}async initializeHighlighter(){return this.highlighter=await yZ(_$(this.computedLang,this.options)),this.highlighter}hydrate(e){if(e==null)return;this.diff=e;let{options:t}=this.getRenderOptions(e),n=this.workerManager?.getDiffResultCache(e);n!=null&&!QZ(t,n.options)&&(n=void 0),this.renderCache??={diff:e,highlighted:!$Z(e),options:t,result:n?.result,renderRange:void 0},this.workerManager?.isWorkingPool()===!0?this.renderCache.result??this.workerManager.highlightDiffAST(this,this.diff):this.highlighter??(this.computedLang=e.lang??EZ(e.name),this.initializeHighlighter())}getRenderOptions(e){let t=(()=>{if(this.workerManager?.isWorkingPool()===!0)return this.workerManager.getDiffRenderOptions();let{theme:e,tokenizeMaxLineLength:t,lineDiffType:n,maxLineDiffLength:r}=this.getOptionsWithDefaults();return{theme:e,useTokenTransformer:v$(this.options),tokenizeMaxLineLength:t,lineDiffType:n,maxLineDiffLength:r}})();this.getOptionsWithDefaults();let{renderCache:n}=this;return n?.result==null||e!==n.diff||!QZ(t,n.options)?{options:t,forceRender:!0}:{options:t,forceRender:!1}}renderDiff(e=this.renderCache?.diff,t=MJ){if(e==null)return;let{expandUnchanged:n=!1,collapsedContextThreshold:r}=this.getOptionsWithDefaults(),i=this.workerManager?.getDiffResultCache(e);i!=null&&this.renderCache==null&&(this.renderCache={diff:e,highlighted:!0,renderRange:void 0,...i});let{options:a,forceRender:o}=this.getRenderOptions(e);if(this.renderCache??={diff:e,highlighted:!1,options:a,result:void 0,renderRange:void 0},this.workerManager?.isWorkingPool()===!0)(this.renderCache.result==null||!this.renderCache.highlighted&&(e!==this.renderCache.diff||!o$(this.renderCache.renderRange,t)))&&(this.renderCache.diff=e,this.renderCache.result=this.workerManager.getPlainDiffAST(e,t.startingLine,t.totalLines,X$(t)||n?!0:this.expandedHunks,r),this.renderCache.renderRange=t),t.totalLines>0&&(!this.renderCache.highlighted||o)&&this.workerManager.highlightDiffAST(this,e);else{this.computedLang=e.lang??EZ(e.name);let t=this.highlighter!=null&&c$(a.theme),n=this.highlighter!=null&&s$(this.computedLang);if(this.highlighter!=null&&t&&(o||!this.renderCache.highlighted&&n||this.renderCache.result==null)){let{result:t,options:r}=this.renderDiffWithHighlighter(e,this.highlighter,!n);this.renderCache={diff:e,options:r,highlighted:n,result:t,renderRange:void 0}}(!t||!n)&&this.asyncHighlight(e).then(({result:t,options:n})=>{this.renderCache!=null&&(this.renderCache.highlighted=!1),this.onHighlightSuccess(e,t,n)})}return this.renderCache.result==null?void 0:this.processDiffResult(this.renderCache.diff,t,this.renderCache.result)}async asyncRender(e,t=MJ){let{result:n}=await this.asyncHighlight(e);return this.processDiffResult(e,t,n)}createPreElement(e,t,n){let{diffIndicators:r,disableBackground:i,disableLineNumbers:a,overflow:o}=this.getOptionsWithDefaults();return h$({type:`diff`,diffIndicators:r,disableBackground:i,disableLineNumbers:a,overflow:o,split:e,totalLines:t,customProperties:n})}async asyncHighlight(e){this.computedLang=e.lang??EZ(e.name);let t=this.highlighter!=null&&c$(this.options.theme??DJ),n=this.highlighter!=null&&s$(this.computedLang);return(this.highlighter==null||!t||!n)&&(this.highlighter=await this.initializeHighlighter()),this.renderDiffWithHighlighter(e,this.highlighter)}renderDiffWithHighlighter(e,t,n=!1){let{options:r}=this.getRenderOptions(e),{collapsedContextThreshold:i}=this.getOptionsWithDefaults();return{result:IQ(e,t,r,{forcePlainText:n,expandedHunks:n?!0:void 0,collapsedContextThreshold:i}),options:r}}onHighlightSuccess(e,t,n){if(this.renderCache==null)return;let r=!this.renderCache.highlighted||!QZ(this.renderCache.options,n)||this.renderCache.diff!==e;this.renderCache={diff:e,options:n,highlighted:!0,result:t,renderRange:void 0},r&&this.onRenderUpdate?.()}onHighlightError(e){console.error(e)}processDiffResult(e,t,{code:n,themeStyles:r,baseThemeType:i}){let{diffStyle:a,disableFileHeader:o,expandUnchanged:s,expansionLineCount:c,collapsedContextThreshold:l,hunkSeparators:u}=this.getOptionsWithDefaults();this.diff=e;let d=a===`unified`,f=[],p=[],m=[],h=[],{additionLines:g,deletionLines:_}=n,v={rowCount:0,hunkSeparators:u,additionsContentAST:f,deletionsContentAST:p,unifiedContentAST:m,unifiedGutterAST:MZ(),deletionsGutterAST:MZ(),additionsGutterAST:MZ(),expansionLineCount:c,hunkData:h,incrementRowCount(e=1){v.rowCount+=e},pushToGutter(e,t){switch(e){case`unified`:v.unifiedGutterAST.children.push(t);break;case`deletions`:v.deletionsGutterAST.children.push(t);break;case`additions`:v.additionsGutterAST.children.push(t);break}}},y=a1(e),b={size:0,side:void 0,increment(){this.size+=1},flush(){if(a!==`unified`){if(this.size<=0||this.side==null){this.side=void 0,this.size=0;return}this.side===`additions`?(v.pushToGutter(`additions`,PZ(void 0,`buffer`,this.size)),f?.push(W$(this.size))):(v.pushToGutter(`deletions`,PZ(void 0,`buffer`,this.size)),p?.push(W$(this.size))),this.size=0,this.side=void 0}}},x=(e,t,n,r,i)=>{v.pushToGutter(e,NZ(t,n,r,i))};function S(e){b.flush(),a===`unified`?r1(`unified`,e,v):(r1(`deletions`,e,v),r1(`additions`,e,v))}eQ({diff:e,diffStyle:a,startingLine:t.startingLine,totalLines:t.totalLines,expandedHunks:s?!0:this.expandedHunks,collapsedContextThreshold:l,callback:({hunkIndex:t,hunk:n,collapsedBefore:r,collapsedAfter:i,additionLine:o,deletionLine:s,type:c})=>{let l=s==null?o.splitLineIndex:s.splitLineIndex,d=o==null?s.unifiedLineIndex:o.unifiedLineIndex;a===`split`&&c!==`change`&&b.flush(),r>0&&S({hunkIndex:t,collapsedLines:r,rangeSize:Math.max(n?.collapsedBefore??0,0),hunkSpecs:n?.hunkSpecs,isFirstHunk:t===0,isLastHunk:!1,isExpandable:!e.isPartial});let f=a===`unified`?d:l,p={type:c,hunkIndex:t,lineIndex:f,unifiedLineIndex:d,splitLineIndex:l,deletionLine:s,additionLine:o};if(a===`unified`){let n=this.getUnifiedInjectedRowsForLine?.(p);n?.before!=null&&e1(n.before,v);let r=s==null?void 0:_[s.lineIndex],i=o==null?void 0:g[o.lineIndex];if(r==null&&i==null){let t=`DiffHunksRenderer.processDiffResult: deletionLine and additionLine are null, something is wrong`;throw console.error(t,{file:e.name}),Error(t)}let a=c===`change`?o==null?`change-deletion`:`change-addition`:c,u=this.getUnifiedLineDecoration({type:c,lineType:a,additionLineIndex:o?.lineIndex,deletionLineIndex:s?.lineIndex});x(`unified`,u.gutterLineType,o==null?s.lineNumber:o.lineNumber,`${d},${l}`,u.gutterProperties),i==null?r!=null&&(r=i1(r,u.contentProperties)):i=i1(i,u.contentProperties),n1({diffStyle:`unified`,type:c,deletionLine:r,additionLine:i,unifiedSpan:this.getAnnotations(`unified`,s?.lineNumber,o?.lineNumber,t,f),createAnnotationElement:e=>this.createAnnotationElement(e),context:v}),n?.after!=null&&e1(n.after,v)}else{let n=this.getSplitInjectedRowsForLine?.(p);n?.before!=null&&t1(n.before,v,b);let r=s==null?void 0:_[s.lineIndex],i=o==null?void 0:g[o.lineIndex],a=this.getSplitLineDecoration({side:`deletions`,type:c,lineIndex:s?.lineIndex}),u=this.getSplitLineDecoration({side:`additions`,type:c,lineIndex:o?.lineIndex});if(r==null&&i==null){let t=`DiffHunksRenderer.processDiffResult: deletionLine and additionLine are null, something is wrong`;throw console.error(t,{file:e.name}),Error(t)}let d=(()=>{if(c===`change`){if(i==null)return`additions`;if(r==null)return`deletions`}})();if(d!=null){if(b.side!=null&&b.side!==d)throw Error(`DiffHunksRenderer.processDiffResult: iterateOverDiff, invalid pending splits`);b.side=d,b.increment()}let m=this.getAnnotations(`split`,s?.lineNumber,o?.lineNumber,t,f);if(m!=null&&b.size>0&&b.flush(),s!=null){let e=i1(r,a.contentProperties);x(`deletions`,a.gutterLineType,s.lineNumber,`${s.unifiedLineIndex},${l}`,a.gutterProperties),e!=null&&(r=e)}if(o!=null){let e=i1(i,u.contentProperties);x(`additions`,u.gutterLineType,o.lineNumber,`${o.unifiedLineIndex},${l}`,u.gutterProperties),e!=null&&(i=e)}n1({diffStyle:`split`,type:c,additionLine:i,deletionLine:r,...m,createAnnotationElement:e=>this.createAnnotationElement(e),context:v}),n?.after!=null&&t1(n.after,v,b)}let m=s?.noEOFCR??!1,h=o?.noEOFCR??!1;if(h||m){if(m){let e=c===`context`||c===`context-expanded`?c:`change-deletion`;a===`unified`?(v.unifiedContentAST.push(G$(e)),v.pushToGutter(`unified`,PZ(e,`metadata`,1))):(v.deletionsContentAST.push(G$(e)),v.pushToGutter(`deletions`,PZ(e,`metadata`,1)),h||(v.pushToGutter(`additions`,PZ(void 0,`buffer`,1)),v.additionsContentAST.push(W$(1))))}if(h){let e=c===`context`||c===`context-expanded`?c:`change-addition`;a===`unified`?(v.unifiedContentAST.push(G$(e)),v.pushToGutter(`unified`,PZ(e,`metadata`,1))):(v.additionsContentAST.push(G$(e)),v.pushToGutter(`additions`,PZ(e,`metadata`,1)),m||(v.pushToGutter(`deletions`,PZ(void 0,`buffer`,1)),v.deletionsContentAST.push(W$(1))))}v.incrementRowCount(1)}i>0&&u!==`simple`&&S({hunkIndex:c===`context-expanded`?t:t+1,collapsedLines:i,rangeSize:y,hunkSpecs:void 0,isFirstHunk:!1,isLastHunk:!0,isExpandable:!e.isPartial}),v.incrementRowCount(1)}}),a===`split`&&b.flush();let C=Math.max(Y$(e.hunks),e.additionLines.length??0,e.deletionLines.length??0),w=t.bufferBefore>0||t.bufferAfter>0,T=!d&&e.type!==`deleted`,E=!d&&e.type!==`new`,D=v.rowCount>0||w;f=T&&D?f:void 0,p=E&&D?p:void 0,m=d&&D?m:void 0;let O=this.createPreElement(p!=null&&f!=null,C);return{unifiedGutterAST:d&&D?v.unifiedGutterAST.children:void 0,unifiedContentAST:m,deletionsGutterAST:E&&D?v.deletionsGutterAST.children:void 0,deletionsContentAST:p,additionsGutterAST:T&&D?v.additionsGutterAST.children:void 0,additionsContentAST:f,hunkData:h,preNode:O,themeStyles:r,baseThemeType:i,headerElement:o?void 0:this.renderHeader(this.diff),totalLines:C,rowCount:v.rowCount,bufferBefore:t.bufferBefore,bufferAfter:t.bufferAfter,css:``}}renderCodeAST(e,t){let n=e===`unified`?t.unifiedGutterAST:e===`deletions`?t.deletionsGutterAST:t.additionsGutterAST,r=e===`unified`?t.unifiedContentAST:e===`deletions`?t.deletionsContentAST:t.additionsContentAST;if(n==null||r==null)return;let i=MZ(n);return i.properties.style=`grid-row: span ${t.rowCount}`,[i,u$(r,t.rowCount)]}renderFullAST(e,t=[]){let n=this.getOptionsWithDefaults().hunkSeparators===`line-info`,r=this.renderCodeAST(`unified`,e);if(r!=null)return t.push(kZ({tagName:`code`,children:r,properties:{"data-code":``,"data-container-size":n?``:void 0,"data-unified":``}})),{...e.preNode,children:t};let i=this.renderCodeAST(`deletions`,e);i!=null&&t.push(kZ({tagName:`code`,children:i,properties:{"data-code":``,"data-container-size":n?``:void 0,"data-deletions":``}}));let a=this.renderCodeAST(`additions`,e);return a!=null&&t.push(kZ({tagName:`code`,children:a,properties:{"data-code":``,"data-container-size":n?``:void 0,"data-additions":``}})),{...e.preNode,children:t}}renderFullHTML(e,t=[]){return rV(this.renderFullAST(e,t))}renderPartialHTML(e,t){return rV(t==null?e:kZ({tagName:`code`,children:e,properties:{"data-code":``,"data-container-size":this.getOptionsWithDefaults().hunkSeparators===`line-info`?``:void 0,[`data-${t}`]:``}}))}getAnnotations(e,t,n,r,i){let a={type:`annotation`,hunkIndex:r,lineIndex:i,annotations:[]};if(t!=null)for(let e of this.deletionAnnotations[t]??[])a.annotations.push(PJ(e));let o={type:`annotation`,hunkIndex:r,lineIndex:i,annotations:[]};if(n!=null)for(let t of this.additionAnnotations[n]??[])(e===`unified`?a:o).annotations.push(PJ(t));if(e===`unified`)return a.annotations.length>0?a:void 0;if(!(o.annotations.length===0&&a.annotations.length===0))return{deletionSpan:a,additionSpan:o}}renderHeader(e){let{headerRenderMode:t}=this.getOptionsWithDefaults();return f$({fileOrDiff:e,mode:t})}};function $$(e){return`${e} unmodified line${e>1?`s`:``}`}function e1(e,t){for(let n of e)t.unifiedContentAST.push(n.content),t.pushToGutter(`unified`,n.gutter),t.incrementRowCount(1)}function t1(e,t,n){for(let{deletion:r,addition:i}of e){if(r==null&&i==null)continue;let e=r!=null&&i!=null?void 0:r==null?`deletions`:`additions`;(e==null||n.side!==e)&&n.flush(),r!=null&&(t.deletionsContentAST.push(r.content),t.pushToGutter(`deletions`,r.gutter)),i!=null&&(t.additionsContentAST.push(i.content),t.pushToGutter(`additions`,i.gutter)),e!=null&&(n.side=e,n.increment()),t.incrementRowCount(1)}}function n1({diffStyle:e,type:t,deletionLine:n,additionLine:r,unifiedSpan:i,deletionSpan:a,additionSpan:o,createAnnotationElement:s,context:c}){let l=!1;if(e===`unified`){if(r==null?n!=null&&c.unifiedContentAST.push(n):c.unifiedContentAST.push(r),i!=null){let e=t===`change`?n==null?`change-addition`:`change-deletion`:t;c.unifiedContentAST.push(s(i)),c.pushToGutter(`unified`,PZ(e,`annotation`,1)),l=!0}}else if(e===`split`){if(n!=null&&c.deletionsContentAST.push(n),r!=null&&c.additionsContentAST.push(r),a!=null){let e=t===`change`?n==null?`context`:`change-deletion`:t;c.deletionsContentAST.push(s(a)),c.pushToGutter(`deletions`,PZ(e,`annotation`,1)),l=!0}if(o!=null){let e=t===`change`?r==null?`context`:`change-addition`:t;c.additionsContentAST.push(s(o)),c.pushToGutter(`additions`,PZ(e,`annotation`,1)),l=!0}}l&&c.incrementRowCount(1)}function r1(e,{hunkIndex:t,collapsedLines:n,rangeSize:r,hunkSpecs:i,isFirstHunk:a,isLastHunk:o,isExpandable:s},c){if(n<=0)return;let l=e===`unified`?c.unifiedContentAST:e===`deletions`?c.deletionsContentAST:c.additionsContentAST;if(c.hunkSeparators===`metadata`){i!=null&&(c.pushToGutter(e,q$({type:`metadata`,content:i,isFirstHunk:a,isLastHunk:o})),l.push(q$({type:`metadata`,content:i,isFirstHunk:a,isLastHunk:o})),e!==`additions`&&c.incrementRowCount(1));return}if(c.hunkSeparators===`simple`){t>0&&(c.pushToGutter(e,q$({type:`simple`,isFirstHunk:a,isLastHunk:!1})),l.push(q$({type:`simple`,isFirstHunk:a,isLastHunk:!1})),e!==`additions`&&c.incrementRowCount(1));return}let u=J$(e,t),d=r>c.expansionLineCount,f=s?t:void 0;c.pushToGutter(e,q$({type:c.hunkSeparators,content:$$(n),expandIndex:f,chunked:d,slotName:u,isFirstHunk:a,isLastHunk:o})),l.push(q$({type:c.hunkSeparators,content:$$(n),expandIndex:f,chunked:d,slotName:u,isFirstHunk:a,isLastHunk:o})),e!==`additions`&&c.incrementRowCount(1),c.hunkData.push({slotName:u,hunkIndex:t,lines:n,type:e,expandable:s?{up:!a,down:!o,chunked:d}:void 0})}function i1(e,t){return e==null||e.type!==`element`||t==null?e:{...e,properties:{...e.properties,...t}}}function a1(e){let t=e.hunks.at(-1);if(t==null||e.isPartial||e.additionLines.length===0||e.deletionLines.length===0)return 0;let n=e.additionLines.length-(t.additionLineIndex+t.additionCount),r=e.deletionLines.length-(t.deletionLineIndex+t.deletionCount);if(n!==r)throw Error(`DiffHunksRenderer.processDiffResult: trailing context mismatch (additions=${n}, deletions=${r}) for ${e.name}`);return Math.min(n,r)}function o1(e,t){return e.lineNumber===t.lineNumber&&e.side===t.side&&e.metadata===t.metadata}function s1(e,t){return e.slotName===t.slotName&&e.hunkIndex===t.hunkIndex&&e.lines===t.lines&&e.type===t.type&&e.expandable?.chunked===t.expandable?.chunked&&e.expandable?.up===t.expandable?.up&&e.expandable?.down===t.expandable?.down}function c1(e){let t=e[0];if(t!==`+`&&t!==`-`&&t!==` `&&t!==`\\`){console.error(`parseLineType: Invalid firstChar: "${t}", full line: "${e}"`);return}let n=e.substring(1);return{line:n===``?`
431
- `:n,type:t===` `?`context`:t===`\\`?`metadata`:t===`+`?`addition`:`deletion`}}function l1(e,t,n=!1){let r=hJ.test(e),i=e.split(r?hJ:gJ),a,o=[];for(let e of i){if(r&&!hJ.test(e)){if(a==null)a=e;else if(n)throw Error(`parsePatchContent: unknown file blob`);else console.error(`parsePatchContent: unknown file blob:`,e);continue}else if(!r&&!gJ.test(e)){if(a==null)a=e;else if(n)throw Error(`parsePatchContent: unknown file blob`);else console.error(`parsePatchContent: unknown file blob:`,e);continue}let i=u1(e,{cacheKey:t==null?void 0:`${t}-${o.length}`,isGitDiff:r,throwOnError:n});i!=null&&o.push(i)}return{patchMetadata:a,files:o}}function u1(e,{cacheKey:t,isGitDiff:n=hJ.test(e),oldFile:r,newFile:i,throwOnError:a=!1}={}){let o=0,s=e.split(_J),c,l=r==null||i==null,u=0,d=0;for(let e of s){let s=e.split(yJ),f=s.shift();if(f==null){if(a)throw Error(`parsePatchContent: invalid hunk`);console.error(`parsePatchContent: invalid hunk`,e);continue}let p=f.match(vJ),m=0,h=0;if(p==null||c==null){if(c!=null){if(a)throw Error(`parsePatchContent: Invalid hunk`);console.error(`parsePatchContent: Invalid hunk`,e);continue}c={name:``,type:`change`,hunks:[],splitLineCount:0,unifiedLineCount:0,isPartial:l,additionLines:!l&&r!=null&&i!=null?i.contents.split(yJ):[],deletionLines:!l&&r!=null&&i!=null?r.contents.split(yJ):[],cacheKey:t},c.additionLines.length===1&&i?.contents===``&&(c.additionLines.length=0),c.deletionLines.length===1&&r?.contents===``&&(c.deletionLines.length=0),s.unshift(f);for(let e of s){let t=e.match(n?xJ:bJ);if(e.startsWith(`diff --git`)){let[,,t,,n]=e.trim().match(SJ)??[];c.name=n.trim(),t!==n&&(c.prevName=t.trim())}else if(t!=null){let[,e,n]=t;e===`---`&&n!==`/dev/null`?(c.prevName=n.trim(),c.name=n.trim()):e===`+++`&&n!==`/dev/null`&&(c.name=n.trim())}else if(n){if(e.startsWith(`new mode `)&&(c.mode=e.replace(`new mode`,``).trim()),e.startsWith(`old mode `)&&(c.prevMode=e.replace(`old mode`,``).trim()),e.startsWith(`new file mode`)&&(c.type=`new`,c.mode=e.replace(`new file mode`,``).trim()),e.startsWith(`deleted file mode`)&&(c.type=`deleted`,c.mode=e.replace(`deleted file mode`,``).trim()),e.startsWith(`similarity index`)&&(e.startsWith(`similarity index 100%`)?c.type=`rename-pure`:c.type=`rename-changed`),e.startsWith(`index `)){let[,t,n,r]=e.trim().match(CJ)??[];t!=null&&(c.prevObjectId=t),n!=null&&(c.newObjectId=n),r!=null&&(c.mode=r)}e.startsWith(`rename from `)&&(c.prevName=e.replace(`rename from `,``).trim()),e.startsWith(`rename to `)&&(c.name=e.replace(`rename to `,``).trim())}}continue}let g,_;for(;s.length>0&&(s[s.length-1]===`
432
- `||s[s.length-1]===`\r`||s[s.length-1]===`\r
433
- `||s[s.length-1]===``);)s.pop();let v=parseInt(p[3]),y=parseInt(p[1]);u=l?u:y-1,d=l?d:v-1;let b={collapsedBefore:0,splitLineCount:0,splitLineStart:0,unifiedLineCount:0,unifiedLineStart:0,additionCount:parseInt(p[4]??`1`),additionStart:v,additionLines:m,deletionCount:parseInt(p[2]??`1`),deletionStart:y,deletionLines:h,deletionLineIndex:u,additionLineIndex:d,hunkContent:[],hunkContext:p[5],hunkSpecs:f,noEOFCRAdditions:!1,noEOFCRDeletions:!1};if(isNaN(b.additionCount)||isNaN(b.deletionCount)||isNaN(b.additionStart)||isNaN(b.deletionStart)){if(a)throw Error(`parsePatchContent: invalid hunk metadata`);console.error(`parsePatchContent: invalid hunk metadata`,b);continue}let x=0,S=0;for(let e of s){if(d1({additionCount:b.additionCount,parsedAdditionLines:x,deletionCount:b.deletionCount,parsedDeletionLines:S})&&!e.startsWith(`\\`))break;let t=c1(e);if(t==null){console.error(`processFile: invalid rawLine:`,e);continue}let{type:n,line:r}=t;if(n===`addition`)(g==null||g.type!==`change`)&&(g=p1(`change`,u,d),b.hunkContent.push(g)),d++,x++,l&&c.additionLines.push(r),g.additions++,m++,_=`addition`;else if(n===`deletion`)(g==null||g.type!==`change`)&&(g=p1(`change`,u,d),b.hunkContent.push(g)),u++,S++,l&&c.deletionLines.push(r),g.deletions++,h++,_=`deletion`;else if(n===`context`)(g==null||g.type!==`context`)&&(g=p1(`context`,u,d),b.hunkContent.push(g)),d++,u++,x++,S++,l&&(c.deletionLines.push(r),c.additionLines.push(r)),g.lines++,_=`context`;else if(n===`metadata`&&g!=null){if(g.type===`context`?(b.noEOFCRAdditions=!0,b.noEOFCRDeletions=!0):_===`deletion`?b.noEOFCRDeletions=!0:_===`addition`&&(b.noEOFCRAdditions=!0),l&&(_===`addition`||_===`context`)){let e=c.additionLines.length-1;e>=0&&(c.additionLines[e]=DZ(c.additionLines[e]))}if(l&&(_===`deletion`||_===`context`)){let e=c.deletionLines.length-1;e>=0&&(c.deletionLines[e]=DZ(c.deletionLines[e]))}}}b.additionLines=m,b.deletionLines=h,b.collapsedBefore=Math.max(b.additionStart-1-o,0),c.hunks.push(b),o=b.additionStart+b.additionCount-1;for(let e of b.hunkContent)e.type===`context`?(b.splitLineCount+=e.lines,b.unifiedLineCount+=e.lines):(b.splitLineCount+=Math.max(e.additions,e.deletions),b.unifiedLineCount+=e.deletions+e.additions);b.splitLineStart=c.splitLineCount+b.collapsedBefore,b.unifiedLineStart=c.unifiedLineCount+b.collapsedBefore,c.splitLineCount+=b.collapsedBefore+b.splitLineCount,c.unifiedLineCount+=b.collapsedBefore+b.unifiedLineCount}if(c!=null){if(c.hunks.length>0&&!l&&c.additionLines.length>0&&c.deletionLines.length>0){let e=c.hunks[c.hunks.length-1],t=e.additionStart+e.additionCount-1,n=c.additionLines.length,r=Math.max(n-t,0);c.splitLineCount+=r,c.unifiedLineCount+=r}return n||(c.prevName!=null&&c.name!==c.prevName?c.hunks.length>0?c.type=`rename-changed`:c.type=`rename-pure`:(r==null||r.contents===``)&&i!=null&&i.contents!==``?c.type=`new`:r!=null&&r.contents!==``&&(i==null||i.contents===``)&&(c.type=`deleted`)),c.type!==`rename-pure`&&c.type!==`rename-changed`&&(c.prevName=void 0),c}}function d1({additionCount:e,parsedAdditionLines:t,deletionCount:n,parsedDeletionLines:r}){return t>=e&&r>=n}function f1(e,t,n=!1){let r=[];for(let i of e.split(mJ))try{r.push(l1(i,t==null?void 0:`${t}-${r.length}`,n))}catch(e){if(n)throw e;console.error(e)}return r}function p1(e,t,n){return e===`change`?{type:`change`,additions:0,deletions:0,additionLineIndex:n,deletionLineIndex:t}:{type:`context`,lines:0,additionLineIndex:n,deletionLineIndex:t}}function m1(e,t,n,r=!1){let i=u1(jQ(e.name,t.name,e.contents,t.contents,e.header,t.header,n),{cacheKey:(()=>{if(e.cacheKey!=null&&t.cacheKey!=null)return`${e.cacheKey}:${t.cacheKey}`})(),oldFile:e,newFile:t,throwOnError:r});if(i==null)throw Error(`parseDiffFrom: FileInvalid diff -- probably need to fix something -- if the files are the same maybe?`);return t.lang!=null&&(i.lang=t.lang),i}var h1=-1,g1=class{static LoadedCustomComponent=!0;__id=`file-diff:${++h1}`;fileContainer;spriteSVG;pre;codeUnified;codeDeletions;codeAdditions;bufferBefore;bufferAfter;themeCSSStyle;appliedThemeCSS;unsafeCSSStyle;appliedUnsafeCSS;gutterUtilityContent;headerElement;headerPrefix;headerMetadata;headerCustom;separatorCache=new Map;errorWrapper;placeHolder;hunksRenderer;resizeManager;scrollSyncManager;interactionManager;annotationCache=new Map;lineAnnotations=[];deletionFile;additionFile;fileDiff;renderRange;appliedPreAttributes;lastRenderedHeaderHTML;lastRowCount;enabled=!0;constructor(e={theme:DJ},t,n=!1){this.options=e,this.workerManager=t,this.isContainerManaged=n,this.hunksRenderer=this.createHunksRenderer(e),this.resizeManager=new a$,this.scrollSyncManager=new U$,this.interactionManager=new GQ(`diff`,KQ(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{...e,headerRenderMode:e.renderCustomHeader==null?`default`:`custom`,hunkSeparators:typeof e.hunkSeparators==`function`?`custom`:e.hunkSeparators}}createHunksRenderer(e){return new Q$(this.getHunksRendererOptions(e),this.handleHighlightRender,this.workerManager)}getLineIndex=(e,t=`additions`)=>{if(this.fileDiff==null)return;let n=this.fileDiff.hunks.at(-1),r,i;hunkIterator:for(let a of this.fileDiff.hunks){let o=t===`deletions`?a.deletionStart:a.additionStart,s=t===`deletions`?a.deletionCount:a.additionCount,c=a.splitLineStart,l=a.unifiedLineStart;if(e<o){let t=o-e;r=Math.max(l-t,0),i=Math.max(c-t,0);break hunkIterator}if(e>=o+s){if(a===n){let t=e-(o+s);r=l+a.unifiedLineCount+t,i=c+a.splitLineCount+t;break hunkIterator}continue}for(let n of a.hunkContent)if(n.type===`context`)if(e<o+n.lines){let t=e-o;i=c+t,r=l+t;break hunkIterator}else o+=n.lines,c+=n.lines,l+=n.lines;else{let a=t===`deletions`?n.deletions:n.additions;if(e<o+a){let a=e-o;r=l+(t===`additions`?n.deletions:0)+a,i=c+a;break hunkIterator}else o+=a,c+=Math.max(n.deletions,n.additions),l+=n.deletions+n.additions}break hunkIterator}if(!(r==null||i==null))return[r,i]};setOptions(e){e!=null&&(this.options=e,this.hunksRenderer.setOptions(this.getHunksRendererOptions(e)),this.interactionManager.setOptions(KQ(e,typeof e.hunkSeparators==`function`||(e.hunkSeparators??`line-info`)===`line-info`||e.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}),!(typeof this.options.theme==`string`||this.fileContainer==null||this.appliedThemeCSS==null)&&this.applyThemeState(this.fileContainer,this.appliedThemeCSS.themeStyles,e,this.appliedThemeCSS.baseThemeType))}getHoveredLine=()=>this.interactionManager.getHoveredLine();setLineAnnotations(e){this.lineAnnotations=e}canPartiallyRender(e,t,n){return!(e||t||n||typeof this.options.hunkSeparators==`function`)}setSelectedLines(e){this.interactionManager.setSelection(e)}cleanUp(e=!1){this.resizeManager.cleanUp(),this.interactionManager.cleanUp(),this.scrollSyncManager.cleanUp(),this.workerManager?.unsubscribeToThemeChanges(this),this.renderRange=void 0,this.isContainerManaged||this.fileContainer?.remove(),this.fileContainer?.shadowRoot!=null&&(this.fileContainer.shadowRoot.innerHTML=``),this.fileContainer=void 0,this.pre!=null&&(this.pre.innerHTML=``,this.pre=void 0),this.codeUnified=void 0,this.codeDeletions=void 0,this.codeAdditions=void 0,this.bufferBefore=void 0,this.bufferAfter=void 0,this.appliedPreAttributes=void 0,this.headerElement=void 0,this.headerPrefix=void 0,this.headerMetadata=void 0,this.headerCustom=void 0,this.lastRenderedHeaderHTML=void 0,this.errorWrapper=void 0,this.spriteSVG=void 0,this.lastRowCount=void 0,this.themeCSSStyle=void 0,this.appliedThemeCSS=void 0,this.unsafeCSSStyle=void 0,this.appliedUnsafeCSS=void 0,e?this.hunksRenderer.recycle():(this.hunksRenderer.cleanUp(),this.workerManager=void 0,this.fileDiff=void 0,this.deletionFile=void 0,this.additionFile=void 0),this.enabled=!1}virtualizedSetup(){this.enabled=!0,this.workerManager?.subscribeToThemeChanges(this)}hydrate(e){let{fileContainer:t,prerenderedHTML:n,preventEmit:r=!1,lineAnnotations:i,oldFile:a,newFile:o,fileDiff:s}=e;this.hydrateElements(t,n),y1(this.pre,_1({fileDiff:s,oldFile:a,newFile:o}),this.options.collapsed)||b1(this.headerElement,v1({fileDiff:s,oldFile:a,newFile:o}),this.options.disableFileHeader)?this.render({...e,preventEmit:!0}):this.hydrationSetup({fileDiff:s,oldFile:a,newFile:o,lineAnnotations:i}),r||this.emitPostRender()}hydrateElements(e,t){N$(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}hydrationSetup({fileDiff:e,oldFile:t,newFile:n,lineAnnotations:r}){let{diffStyle:i=`split`,overflow:a=`scroll`}=this.options;this.lineAnnotations=r??this.lineAnnotations,this.additionFile=n,this.deletionFile=t,this.fileDiff=e??(t!=null&&n!=null?m1(t,n,this.options.parseDiffOptions):void 0),this.pre!=null&&(this.hunksRenderer.hydrate(this.fileDiff),this.renderAnnotations(),this.renderGutterUtility(),this.injectUnsafeCSS(),this.interactionManager.setup(this.pre),this.resizeManager.setup(this.pre,a===`wrap`),a===`scroll`&&i===`split`&&this.scrollSyncManager.setup(this.pre,this.codeDeletions,this.codeAdditions))}rerender(){!this.enabled||this.fileDiff==null&&this.additionFile==null&&this.deletionFile==null||this.render({forceRender:!0,renderRange:this.renderRange})}handleExpandHunk=(e,t,n)=>{this.expandHunk(e,t,n)};expandHunk=(e,t,n)=>{this.hunksRenderer.expandHunk(e,t,n),this.rerender()};render({oldFile:e,newFile:t,fileDiff:n,forceRender:r=!1,preventEmit:i=!1,lineAnnotations:a,fileContainer:o,containerWrapper:s,renderRange:c}){if(!this.enabled)throw Error(`FileDiff.render: attempting to call render after cleaned up`);let{collapsed:l=!1}=this.options,u=l?void 0:c,d=e!=null&&t!=null&&(!ZZ(e,this.deletionFile)||!ZZ(t,this.additionFile)),f=n!=null&&n!==this.fileDiff,p=a!=null&&(a.length>0||this.lineAnnotations.length>0)?a!==this.lineAnnotations:!1;if(!l&&o$(u,this.renderRange)&&!r&&!p&&(n!=null&&n===this.fileDiff||n==null&&!d))return!1;let{renderRange:m}=this;if(this.renderRange=u,this.deletionFile=e,this.additionFile=t,n==null?e!=null&&t!=null&&d&&(f=!0,this.fileDiff=m1(e,t,this.options.parseDiffOptions)):this.fileDiff=n,a!=null&&this.setLineAnnotations(a),this.fileDiff==null)return!1;this.hunksRenderer.setOptions(this.getHunksRendererOptions(this.options)),this.hunksRenderer.setLineAnnotations(this.lineAnnotations);let{diffStyle:h=`split`,disableErrorHandling:g=!1,disableFileHeader:_=!1,overflow:v=`scroll`,themeType:y=`system`}=this.options;if(_&&(this.headerElement!=null&&(this.headerElement.remove(),this.headerElement=void 0,this.lastRenderedHeaderHTML=void 0),this.clearHeaderSlots()),o=this.getOrCreateFileContainer(o,s),l){this.removeRenderedCode(),this.clearAuxiliaryNodes();try{let e=this.hunksRenderer.renderDiff(this.fileDiff,NJ);e!=null&&this.applyThemeState(o,e.themeStyles,y,e.baseThemeType),e?.headerElement!=null&&this.applyHeaderToDOM(e.headerElement,o),this.renderSeparators([]),this.injectUnsafeCSS()}catch(e){if(g)throw e;console.error(e),e instanceof Error&&this.applyErrorToDOM(e,o)}return i||this.emitPostRender(),!0}try{let e=this.getOrCreatePreNode(o);if(!(this.canPartiallyRender(r,p,d||f)&&this.applyPartialRender({previousRenderRange:m,renderRange:u}))){let t=this.hunksRenderer.renderDiff(this.fileDiff,u);if(t==null)return this.workerManager?.isInitialized()===!1&&this.workerManager.initialize().then(()=>this.rerender()),!1;this.applyThemeState(o,t.themeStyles,y,t.baseThemeType),t.headerElement!=null&&this.applyHeaderToDOM(t.headerElement,o),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,u),this.injectUnsafeCSS(),this.renderAnnotations(),this.renderGutterUtility(),this.interactionManager.setup(e),this.resizeManager.setup(e,v===`wrap`),v===`scroll`&&h===`split`?this.scrollSyncManager.setup(e,this.codeDeletions,this.codeAdditions):this.scrollSyncManager.cleanUp()}catch(e){if(g)throw e;console.error(e),e instanceof Error&&this.applyErrorToDOM(e,o)}return i||this.emitPostRender(),!0}emitPostRender(){this.fileContainer!=null&&this.options.onPostRender?.(this.fileContainer,this)}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.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}cleanChildNodes(){this.resizeManager.cleanUp(),this.scrollSyncManager.cleanUp(),this.interactionManager.cleanUp(),this.bufferAfter?.remove(),this.bufferBefore?.remove(),this.codeAdditions?.remove(),this.codeDeletions?.remove(),this.codeUnified?.remove(),this.errorWrapper?.remove(),this.headerElement?.remove(),this.gutterUtilityContent?.remove(),this.headerPrefix?.remove(),this.headerMetadata?.remove(),this.headerCustom?.remove(),this.pre?.remove(),this.spriteSVG?.remove(),this.themeCSSStyle?.remove(),this.unsafeCSSStyle?.remove(),this.bufferAfter=void 0,this.bufferBefore=void 0,this.codeAdditions=void 0,this.codeDeletions=void 0,this.codeUnified=void 0,this.errorWrapper=void 0,this.headerElement=void 0,this.gutterUtilityContent=void 0,this.headerPrefix=void 0,this.headerMetadata=void 0,this.headerCustom=void 0,this.pre=void 0,this.spriteSVG=void 0,this.themeCSSStyle=void 0,this.appliedThemeCSS=void 0,this.unsafeCSSStyle=void 0,this.appliedUnsafeCSS=void 0,this.lastRenderedHeaderHTML=void 0,this.lastRowCount=void 0}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||!s1(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}-${PJ(r)}`,a=this.annotationCache.get(i);if(a==null||!o1(r,a.annotation)){a?.element.remove();let e=t(r);if(e==null)continue;a={element:C$(PJ(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 e=this.options.renderGutterUtility??this.options.renderHoverUtility;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=w$();n.appendChild(t),this.fileContainer.appendChild(n),this.gutterUtilityContent=n}getOrCreateFileContainer(e,t){let n=this.fileContainer;if(this.fileContainer=e??this.fileContainer??document.createElement(`diffs-container`),n!=null&&n!==this.fileContainer&&(this.lastRenderedHeaderHTML=void 0,this.headerElement=void 0),t!=null&&this.fileContainer.parentNode!==t&&t.appendChild(this.fileContainer),this.spriteSVG==null){let e=document.createElement(`div`);e.innerHTML=y$;let t=e.firstChild;t instanceof SVGElement&&(this.spriteSVG=t,this.fileContainer.shadowRoot?.appendChild(this.spriteSVG))}return this.fileContainer}getFileContainer(){return this.fileContainer}getOrCreatePreNode(e){let t=e.shadowRoot??e.attachShadow({mode:`open`});return this.pre==null?(this.pre=document.createElement(`pre`),this.appliedPreAttributes=void 0,this.codeUnified=void 0,this.codeDeletions=void 0,this.codeAdditions=void 0,t.appendChild(this.pre)):this.pre.parentNode!==t&&(t.appendChild(this.pre),this.appliedPreAttributes=void 0),this.placeHolder?.remove(),this.placeHolder=void 0,this.pre}syncCodeNodesFromPre(e){this.codeUnified=void 0,this.codeDeletions=void 0,this.codeAdditions=void 0;for(let t of Array.from(e.children))t instanceof HTMLElement&&(t.hasAttribute(`data-unified`)?this.codeUnified=t:t.hasAttribute(`data-deletions`)?this.codeDeletions=t:t.hasAttribute(`data-additions`)&&(this.codeAdditions=t))}applyHeaderToDOM(e,t){this.cleanupErrorWrapper(),this.placeHolder?.remove(),this.placeHolder=void 0;let{fileDiff:n}=this,r=rV(e);if(r!==this.lastRenderedHeaderHTML){let e=document.createElement(`div`);e.innerHTML=r;let n=e.firstElementChild;if(!(n instanceof HTMLElement))return;this.headerElement==null?t.shadowRoot?.prepend(n):t.shadowRoot?.replaceChild(n,this.headerElement),this.headerElement=n,this.lastRenderedHeaderHTML=r}if(this.isContainerManaged||n==null)return;let{renderCustomHeader:i,renderHeaderPrefix:a,renderHeaderMetadata:o}=this.options;if(i!=null){let e=i(n)??void 0;this.headerCustom=this.upsertHeaderSlotElement(t,this.headerCustom,EJ,e),this.headerPrefix?.remove(),this.headerMetadata?.remove(),this.headerPrefix=void 0,this.headerMetadata=void 0;return}let s=a?.(n)??void 0,c=o?.(n)??void 0;this.headerPrefix=this.upsertHeaderSlotElement(t,this.headerPrefix,wJ,s),this.headerMetadata=this.upsertHeaderSlotElement(t,this.headerMetadata,TJ,c),this.headerCustom?.remove(),this.headerCustom=void 0}clearHeaderSlots(){this.headerPrefix?.remove(),this.headerMetadata?.remove(),this.headerCustom?.remove(),this.headerPrefix=void 0,this.headerMetadata=void 0,this.headerCustom=void 0}upsertHeaderSlotElement(e,t,n,r){if(r==null){t?.remove();return}let i=t??this.createHeaderSlotElement(n);return t??e.appendChild(i),this.replaceHeaderSlotContent(i,r),i}replaceHeaderSlotContent(e,t){e.replaceChildren(),t instanceof Element?e.appendChild(t):e.innerText=`${t}`}createHeaderSlotElement(e){let t=document.createElement(`div`);return t.slot=e,t}injectUnsafeCSS(){let{unsafeCSS:e}=this.options,t=this.fileContainer?.shadowRoot;if(t!=null){if(e==null||e===``){this.unsafeCSSStyle!=null&&(this.unsafeCSSStyle.remove(),this.unsafeCSSStyle=void 0),this.appliedUnsafeCSS=void 0;return}this.unsafeCSSStyle?.parentNode===t&&this.appliedUnsafeCSS===e||(this.unsafeCSSStyle??=T$(),this.unsafeCSSStyle.parentNode!==t&&t.appendChild(this.unsafeCSSStyle),this.unsafeCSSStyle.textContent=O$(e),this.appliedUnsafeCSS=e)}}applyThemeState(e,t,n,r){let i=e.shadowRoot??e.attachShadow({mode:`open`}),a=r??n;this.themeCSSStyle?.parentNode===i&&this.appliedThemeCSS?.themeStyles===t&&this.appliedThemeCSS.themeType===a||(this.themeCSSStyle=j$({shadowRoot:i,currentNode:this.themeCSSStyle,themeCSS:k$(t,a)}),this.appliedThemeCSS=this.themeCSSStyle==null?void 0:{themeStyles:t,themeType:a,baseThemeType:r})}applyHunksToDOM(e,t){let{overflow:n=`scroll`}=this.options,r=(this.options.hunkSeparators??`line-info`)===`line-info`,i=n===`wrap`?t.rowCount:void 0;this.cleanupErrorWrapper(),this.applyPreNodeAttributes(e,t);let a=!1,o=[],s=this.hunksRenderer.renderCodeAST(`unified`,t),c=this.hunksRenderer.renderCodeAST(`deletions`,t),l=this.hunksRenderer.renderCodeAST(`additions`,t);s==null?c!=null||l!=null?(c==null?(this.codeDeletions?.remove(),this.codeDeletions=void 0):(a=this.codeDeletions==null||this.codeUnified!=null,this.codeUnified?.remove(),this.codeUnified=void 0,this.codeDeletions=A$({code:this.codeDeletions,columnType:`deletions`,rowSpan:i,containerSize:r}),this.codeDeletions.innerHTML=this.hunksRenderer.renderPartialHTML(c),o.push(this.codeDeletions)),l==null?(this.codeAdditions?.remove(),this.codeAdditions=void 0):(a=a||this.codeAdditions==null||this.codeUnified!=null,this.codeUnified?.remove(),this.codeUnified=void 0,this.codeAdditions=A$({code:this.codeAdditions,columnType:`additions`,rowSpan:i,containerSize:r}),this.codeAdditions.innerHTML=this.hunksRenderer.renderPartialHTML(l),o.push(this.codeAdditions))):(this.codeUnified?.remove(),this.codeUnified=void 0,this.codeDeletions?.remove(),this.codeDeletions=void 0,this.codeAdditions?.remove(),this.codeAdditions=void 0):(a=this.codeUnified==null||this.codeAdditions!=null||this.codeDeletions!=null,this.codeDeletions?.remove(),this.codeDeletions=void 0,this.codeAdditions?.remove(),this.codeAdditions=void 0,this.codeUnified=A$({code:this.codeUnified,columnType:`unified`,rowSpan:i,containerSize:r}),this.codeUnified.innerHTML=this.hunksRenderer.renderPartialHTML(s),o.push(this.codeUnified)),o.length===0?e.textContent=``:a&&e.replaceChildren(...o),this.lastRowCount=t.rowCount}applyPartialRender({previousRenderRange:e,renderRange:t}){let{pre:n,codeUnified:r,codeAdditions:i,codeDeletions:a,options:{diffStyle:o=`split`}}=this;if(n==null||e==null||t==null||!Number.isFinite(e.totalLines)||!Number.isFinite(t.totalLines)||this.lastRowCount==null)return!1;let s=this.getCodeColumns(o,r,a,i);if(s==null)return!1;let c=e.startingLine,l=t.startingLine,u=c+e.totalLines,d=l+t.totalLines,f=Math.max(c,l),p=Math.min(u,d);if(p<=f)return!1;let m=Math.max(0,f-c),h=Math.max(0,u-p),g=this.trimColumns({columns:s,trimStart:m,trimEnd:h,previousStart:c,overlapStart:f,overlapEnd:p,diffStyle:o});if(g<0)throw Error(`applyPartialRender: failed to trim to overlap`);if(this.lastRowCount<g)throw Error(`applyPartialRender: trimmed beyond DOM row count`);let _=this.lastRowCount-g,v=(e,t)=>{if(!(t<=0||this.fileDiff==null))return this.hunksRenderer.renderDiff(this.fileDiff,{startingLine:e,totalLines:t,bufferBefore:0,bufferAfter:0})},y=v(l,Math.max(f-l,0));if(y==null&&l<f)return!1;let b=v(p,Math.max(d-p,0));if(b==null&&d>p)return!1;let x=(e,t)=>{if(e!=null){if(o===`unified`&&!Array.isArray(s))this.insertPartialHTML(o,s,e,t);else if(o===`split`&&Array.isArray(s))this.insertPartialHTML(o,s,e,t);else throw Error(`FileDiff.applyPartialRender.applyChunk: invalid chunk application`);_+=e.rowCount}};return this.cleanupErrorWrapper(),x(y,`afterbegin`),x(b,`beforeend`),this.lastRowCount!==_&&(this.applyRowSpan(o,s,_),this.lastRowCount=_),!0}insertPartialHTML(e,t,n,r){if(e===`unified`&&!Array.isArray(t)){let e=this.hunksRenderer.renderCodeAST(`unified`,n);this.renderPartialColumn(t,e,r)}else if(e===`split`&&Array.isArray(t)){let e=this.hunksRenderer.renderCodeAST(`deletions`,n),i=this.hunksRenderer.renderCodeAST(`additions`,n);this.renderPartialColumn(t[0],e,r),this.renderPartialColumn(t[1],i,r)}else throw Error(`FileDiff.insertPartialHTML: Invalid argument composition`)}renderPartialColumn(e,t,n){if(e==null||t==null)return;let r=x1(t[0]),i=x1(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}else if(s){let t=r,o=r+a-1;if(n<=t)e.remove(),u.remove(),i+=a;else if(n<=o){let t=o-n+1,r=a-t;this.updateBufferSize(e,r),this.updateBufferSize(u,r),i+=t}}r+=a;continue}throw console.error({gutterElement:e,contentElement:u}),Error(`FileDiff.trimColumnRows: unknown row elements`)}return i}trimColumns({columns:e,diffStyle:t,overlapEnd:n,overlapStart:r,previousStart:i,trimEnd:a,trimStart:o}){let s=Math.max(0,r-i),c=n-i;if(c<0)throw Error(`FileDiff.trimColumns: overlap ends before previous`);let l=o>0,u=a>0;if(!l&&!u)return 0;let d=l?s:0,f=u?c:-1;if(t===`unified`&&!Array.isArray(e))return this.trimColumnRows(e,d,f);if(t===`split`&&Array.isArray(e)){let t=this.trimColumnRows(e[0],d,f),n=this.trimColumnRows(e[1],d,f);if(e[0]!=null&&e[1]!=null&&t!==n)throw Error(`FileDiff.trimColumns: split columns out of sync`);return e[0]==null?n:t}else throw console.error({diffStyle:t,columns:e}),Error(`FileDiff.trimColumns: Invalid columns for diffType`)}getBufferSize(e){let t=Number.parseInt(e?.bufferSize??``,10);return Number.isNaN(t)?void 0:t}updateBufferSize(e,t){e.dataset.bufferSize=`${t}`,e.style.setProperty(`grid-row`,`span ${t}`),e.style.setProperty(`min-height`,`calc(${t} * 1lh)`)}getCodeColumns(e,t,n,r){function i(e){if(e==null)return;let t=e.children[0],n=e.children[1];if(!(!(t instanceof HTMLElement)||!(n instanceof HTMLElement)||t.dataset.gutter==null||n.dataset.content==null))return{gutter:t,content:n}}if(e===`unified`)return i(t);{let e=i(n),t=i(r);return e!=null||t!=null?[e,t]:void 0}}applyBuffers(e,t){let{disableVirtualizationBuffers:n=!1}=this.options;if(n||t==null){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)}applyPreNodeAttributes(e,{additionsContentAST:t,deletionsContentAST:n,totalLines:r},i){let{diffIndicators:a=`bars`,disableBackground:o=!1,disableLineNumbers:s=!1,overflow:c=`scroll`,diffStyle:l=`split`}=this.options,u={type:`diff`,diffIndicators:a,disableBackground:o,disableLineNumbers:s,overflow:c,split:l===`unified`?!1:t!=null&&n!=null,totalLines:r,customProperties:i};b$(u,this.appliedPreAttributes)||(P$(e,u),this.appliedPreAttributes=u)}applyErrorToDOM(e,t){this.cleanupErrorWrapper();let n=this.getOrCreatePreNode(t);n.innerHTML=``,n.remove(),this.pre=void 0,this.appliedPreAttributes=void 0;let r=t.shadowRoot??t.attachShadow({mode:`open`});this.errorWrapper??=document.createElement(`div`),this.errorWrapper.dataset.errorWrapper=``,this.errorWrapper.innerHTML=``,r.appendChild(this.errorWrapper);let i=document.createElement(`div`);i.dataset.errorMessage=``,i.innerText=e.message,this.errorWrapper.appendChild(i);let a=document.createElement(`pre`);a.dataset.errorStack=``,a.innerText=e.stack??`No Error Stack`,this.errorWrapper.appendChild(a)}cleanupErrorWrapper(){this.errorWrapper?.remove(),this.errorWrapper=void 0}};function _1({fileDiff:e,oldFile:t,newFile:n}){return e!=null&&e.hunks.length>0||t!=null||n!=null}function v1({fileDiff:e,oldFile:t,newFile:n}){return e!=null||t!=null||n!=null}function y1(e,t,n=!1){return!n&&e==null&&t}function b1(e,t,n=!1){return e==null&&t&&!n}function x1(e){if(!(e==null||e.type!==`element`))return e.children??[]}function S1(e,t){let n={...AJ,...t};return n.hunkSeparatorHeight=C1(e,t?.hunkSeparatorHeight),n}function C1(e,t){if(t!=null)return t;switch(e){case`simple`:return 4;case`metadata`:case`line-info`:case`line-info-basic`:case`custom`:return 32}}var w1=-1,T1=class extends g1{__id=`little-virtualized-file-diff:${++w1}`;top;height=0;metrics;heightCache=new Map;isVisible=!1;isSetup=!1;virtualizer;constructor(e,t,n,r,i=!1){super(e,r,i);let{hunkSeparators:a=`line-info`}=this.options;this.virtualizer=t,this.metrics=S1(typeof a==`function`?`custom`:a,n)}getLineHeight(e,t=!1){let n=this.heightCache.get(e);if(n!=null)return n;let r=t?2:1;return this.metrics.lineHeight*r}setOptions(e){if(e==null)return;let t=this.options.diffStyle,n=this.options.overflow,r=this.options.collapsed;super.setOptions(e),(t!==this.options.diffStyle||n!==this.options.overflow||r!==this.options.collapsed)&&(this.heightCache.clear(),this.computeApproximateSize(),this.renderRange=void 0),this.virtualizer.instanceChanged(this)}reconcileHeights(){let{overflow:e=`scroll`}=this.options;if(this.fileContainer!=null&&(this.top=this.virtualizer.getOffsetInScrollContainer(this.fileContainer)),this.fileContainer==null||this.fileDiff==null){this.height=0;return}if(e===`scroll`&&this.lineAnnotations.length===0&&!this.virtualizer.config.resizeDebugging)return;let t=this.getDiffStyle(),n=!1,r=t===`split`?[this.codeDeletions,this.codeAdditions]:[this.codeUnified];for(let e of r){if(e==null)continue;let r=e.children[1];if(r instanceof HTMLElement)for(let e of r.children){if(!(e instanceof HTMLElement))continue;let r=e.dataset.lineIndex;if(r==null)continue;let i=D1(r,t),a=e.getBoundingClientRect().height,o=!1;e.nextElementSibling instanceof HTMLElement&&(`lineAnnotation`in e.nextElementSibling.dataset||`noNewline`in e.nextElementSibling.dataset)&&(`noNewline`in e.nextElementSibling.dataset&&(o=!0),a+=e.nextElementSibling.getBoundingClientRect().height);let s=this.getLineHeight(i,o);a!==s&&(n=!0,a===this.metrics.lineHeight*(o?2:1)?this.heightCache.delete(i):this.heightCache.set(i,a))}}(n||this.virtualizer.config.resizeDebugging)&&this.computeApproximateSize()}onRender=e=>this.fileContainer==null?!1:(e&&(this.top=this.virtualizer.getOffsetInScrollContainer(this.fileContainer)),this.render());cleanUp(){this.fileContainer!=null&&this.virtualizer.disconnect(this.fileContainer),this.isSetup=!1,super.cleanUp()}expandHunk=(e,t,n)=>{this.hunksRenderer.expandHunk(e,t,n),this.computeApproximateSize(),this.renderRange=void 0,this.virtualizer.instanceChanged(this)};setVisibility(e){this.fileContainer!=null&&(this.renderRange=void 0,e&&!this.isVisible?(this.top=this.virtualizer.getOffsetInScrollContainer(this.fileContainer),this.isVisible=!0):!e&&this.isVisible&&(this.isVisible=!1,this.rerender()))}computeApproximateSize(){let e=this.height===0;if(this.height=0,this.fileDiff==null)return;let{disableFileHeader:t=!1,expandUnchanged:n=!1,collapsed:r=!1,collapsedContextThreshold:i=1,hunkSeparators:a=`line-info`}=this.options,{diffHeaderHeight:o,fileGap:s,hunkSeparatorHeight:c}=this.metrics,l=this.getDiffStyle(),u=a!==`simple`&&a!==`metadata`&&a!==`line-info-basic`?s:0;if(t?a!==`simple`&&a!==`metadata`&&(this.height+=s):this.height+=o,!r&&(eQ({diff:this.fileDiff,diffStyle:l,expandedHunks:n?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:i,callback:({hunkIndex:e,collapsedBefore:t,collapsedAfter:n,deletionLine:r,additionLine:i})=>{let o=i==null?r.splitLineIndex:i.splitLineIndex,s=i==null?r.unifiedLineIndex:i.unifiedLineIndex,d=(i?.noEOFCR??!1)||(r?.noEOFCR??!1);t>0&&(e>0&&(this.height+=u),this.height+=c+u),this.height+=this.getLineHeight(l===`split`?o:s,d),n>0&&a!==`simple`&&(this.height+=u+c)}}),this.fileDiff.hunks.length>0&&(this.height+=s),this.fileContainer!=null&&this.virtualizer.config.resizeDebugging&&!e)){let e=this.fileContainer.getBoundingClientRect();e.height===this.height?console.log(`VirtualizedFileDiff.computeApproximateSize: computed height IS CORRECT`):console.log(`VirtualizedFileDiff.computeApproximateSize: computed height doesnt match`,{name:this.fileDiff.name,elementHeight:e.height,computedHeight:this.height})}}render({fileContainer:e,oldFile:t,newFile:n,fileDiff:r,...i}={}){let{isSetup:a}=this;if(this.fileDiff??=r??(t!=null&&n!=null?m1(t,n,this.options.parseDiffOptions):void 0),e=this.getOrCreateFileContainer(e),this.fileDiff==null)return console.error(`VirtualizedFileDiff.render: attempting to virtually render when we dont have the correct data`),!1;if(a?this.top??=this.virtualizer.getOffsetInScrollContainer(e):(this.computeApproximateSize(),this.virtualizer.connect(e,this),this.top??=this.virtualizer.getOffsetInScrollContainer(e),this.isVisible=this.virtualizer.isInstanceVisible(this.top,this.height),this.isSetup=!0),!this.isVisible)return this.renderPlaceholder(this.height);let o=this.virtualizer.getWindowSpecs(),s=this.computeRenderRangeFromWindow(this.fileDiff,this.top,o);return super.render({fileDiff:this.fileDiff,fileContainer:e,renderRange:s,oldFile:t,newFile:n,...i})}getDiffStyle(){return this.options.diffStyle??`split`}getExpandedRegion(e,t,n){if(n<=0||e)return{fromStart:0,fromEnd:0,collapsedLines:Math.max(n,0),renderAll:!1};let{expandUnchanged:r=!1,collapsedContextThreshold:i=1}=this.options;if(r||n<=i)return{fromStart:n,fromEnd:0,collapsedLines:0,renderAll:!0};let a=this.hunksRenderer.getExpandedHunk(t),o=Math.min(Math.max(a.fromStart,0),n),s=Math.min(Math.max(a.fromEnd,0),n),c=o+s,l=c>=n;return{fromStart:o,fromEnd:s,collapsedLines:Math.max(n-c,0),renderAll:l}}getExpandedLineCount(e,t){let n=0;if(e.isPartial){for(let r of e.hunks)n+=t===`split`?r.splitLineCount:r.unifiedLineCount;return n}for(let[r,i]of e.hunks.entries()){let a=t===`split`?i.splitLineCount:i.unifiedLineCount;n+=a;let o=Math.max(i.collapsedBefore,0),{fromStart:s,fromEnd:c,renderAll:l}=this.getExpandedRegion(e.isPartial,r,o);o>0&&(n+=l?o:s+c)}let r=e.hunks.at(-1);if(r!=null&&E1(e)){let t=e.additionLines.length-(r.additionLineIndex+r.additionCount),i=e.deletionLines.length-(r.deletionLineIndex+r.deletionCount);if(r!=null&&t!==i)throw Error(`VirtualizedFileDiff: trailing context mismatch (additions=${t}, deletions=${i}) for ${e.name}`);let a=Math.min(t,i);if(r!=null&&a>0){let{fromStart:t,renderAll:r}=this.getExpandedRegion(e.isPartial,e.hunks.length,a);n+=r?a:t}}return n}computeRenderRangeFromWindow(e,t,{top:n,bottom:r}){let{disableFileHeader:i=!1,expandUnchanged:a=!1,collapsedContextThreshold:o=1,hunkSeparators:s=`line-info`}=this.options,{diffHeaderHeight:c,fileGap:l,hunkLineCount:u,hunkSeparatorHeight:d,lineHeight:f}=this.metrics,p=this.getDiffStyle(),m=this.height,h=this.getExpandedLineCount(e,p),g=i?l:c;if(t<n-m||t>r)return{startingLine:0,totalLines:0,bufferBefore:0,bufferAfter:m-g-l};if(h<=u||e.hunks.length===0)return{startingLine:0,totalLines:u,bufferBefore:0,bufferAfter:0};let _=Math.ceil(Math.max(r-n,0)/f),v=Math.ceil(_/u)*u+u,y=v/u,b=y,x=[],S=(n+r)/2,C=s===`simple`||s===`metadata`||s===`line-info-basic`?0:l,w=t+g,T=0,E,D,O;if(eQ({diff:e,diffStyle:p,expandedHunks:a?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:o,callback:({hunkIndex:e,collapsedBefore:i,collapsedAfter:a,deletionLine:o,additionLine:c})=>{let l=c==null?o.splitLineIndex:c.splitLineIndex,f=c==null?o.unifiedLineIndex:c.unifiedLineIndex,m=(c?.noEOFCR??!1)||(o?.noEOFCR??!1),h=i>0?d+C+(e>0?C:0):0;e===0&&s===`simple`&&(h=0),w+=h;let _=T%u===0;if(_&&(x.push(w-(t+g+h)),O!=null)){if(O<=0)return!0;O--}let v=this.getLineHeight(p===`split`?l:f,m),y=Math.floor(T/u);return w>n-v&&w<r&&(E??=y),D==null&&w+v>S&&(D=y),O==null&&w>=r&&_&&(O=b),T++,w+=v,a>0&&s!==`simple`&&(w+=d+C),!1}}),E==null)return{startingLine:0,totalLines:0,bufferBefore:0,bufferAfter:m-g-l};let ee=x.length;D??=E;let te=Math.round(D-y/2),k=Math.max(0,ee-y),A=Math.max(0,Math.min(te,k)),j=A*u,M=te<0?v+te*u:v,ne=x[A]??0,N=A+M/u;return{startingLine:j,totalLines:M,bufferBefore:ne,bufferAfter:N<x.length?m-g-x[N]-l:m-(w-t)-l}}};function E1(e){let t=e.hunks.at(-1);return t==null||e.isPartial||e.additionLines.length===0||e.deletionLines.length===0?!1:t.additionLineIndex+t.additionCount<e.additionLines.length||t.deletionLineIndex+t.deletionCount<e.deletionLines.length}function D1(e,t){let[n,r]=e.split(`,`).map(Number);return t===`split`?r:n}var O1=typeof window>`u`?d.useEffect:d.useLayoutEffect;function k1({fileDiff:e,options:t,lineAnnotations:n,selectedLines:r,prerenderedHTML:i,metrics:a,hasGutterRenderUtility:o,hasCustomHeader:s,disableWorkerPool:c}){let l=LJ(),u=(0,d.useContext)(BQ),f=(0,d.useRef)(null),p=VQ(r=>{if(r!=null){if(f.current!=null)throw Error(`useFileDiffInstance: An instance should not already exist when a node is created`);l==null?f.current=new g1(A1({hasCustomHeader:s,hasGutterRenderUtility:o,options:t}),c?void 0:u,!0):f.current=new T1(A1({hasCustomHeader:s,hasGutterRenderUtility:o,options:t}),l,a,c?void 0:u,!0),f.current.hydrate({fileDiff:e,fileContainer:r,lineAnnotations:n,prerenderedHTML:i})}else{if(f.current==null)throw Error(`useFileDiffInstance: A FileDiff instance should exist when unmounting`);f.current.cleanUp(),f.current=null}});return O1(()=>{let{current:i}=f;if(i==null)return;let a=A1({hasCustomHeader:s,hasGutterRenderUtility:o,options:t}),c=!I$(i.options,a);i.setOptions(a),i.render({forceRender:c,fileDiff:e,lineAnnotations:n}),r!==void 0&&i.setSelectedLines(r)}),{ref:p,getHoveredLine:(0,d.useCallback)(()=>f.current?.getHoveredLine(),[])}}function A1({options:e,hasCustomHeader:t,hasGutterRenderUtility:n}){return n||t?{...e,renderCustomHeader:t?fJ:void 0,renderGutterUtility:n?fJ:void 0}:e}function j1(e){let t=f1(e);if(t.length!==1)throw console.error(t),Error(`PatchDiff: Provided patch must include only 1 patch, with 1 diff`);let{files:n}=t[0];if(n.length!==1)throw console.error(n),Error(`FileDiff: Provided patch must contain exactly 1 file diff`);return n[0]}function M1({patch:e,options:t,metrics:n,lineAnnotations:r,selectedLines:i,className:a,style:o,prerenderedHTML:s,renderAnnotation:c,renderCustomHeader:l,renderHeaderPrefix:u,renderHeaderMetadata:d,renderGutterUtility:f,renderHoverUtility:p,disableWorkerPool:m=!1}){let h=N1(e),{ref:g,getHoveredLine:v}=k1({fileDiff:h,options:t,metrics:n,lineAnnotations:r,selectedLines:i,prerenderedHTML:s,hasGutterRenderUtility:f!=null||p!=null,hasCustomHeader:l!=null,disableWorkerPool:m});return(0,_.jsx)(pJ,{ref:g,className:a,style:o,children:FJ(V$({fileDiff:h,renderCustomHeader:l,renderHeaderPrefix:u,renderHeaderMetadata:d,renderAnnotation:c,lineAnnotations:r,renderGutterUtility:f,renderHoverUtility:p,getHoveredLine:v}),s)})}function N1(e){return(0,d.useMemo)(()=>j1(e),[e])}var P1={M:`text-amber-600 dark:text-amber-400`,A:`text-green-600 dark:text-green-400`,D:`text-red-600 dark:text-red-400`,"?":`text-(--text-muted)`};function F1({open:e,onOpenChange:t}){let[n,r]=(0,d.useState)(null),[i,a]=(0,d.useState)(!1),[o,s]=(0,d.useState)(null),c=(0,d.useCallback)(()=>document.documentElement.classList.contains(`dark`)||document.documentElement.dataset.theme===`dark`,[]),[l,u]=(0,d.useState)(c);(0,d.useEffect)(()=>{if(typeof window>`u`)return;let e=new MutationObserver(()=>u(c()));return e.observe(document.documentElement,{attributes:!0,attributeFilter:[`class`,`data-theme`]}),()=>e.disconnect()},[c]);let f=(0,d.useCallback)(e=>{if(!n?.patch||!e)return``;let t=n.patch.split(`
434
- `),r=[],i=!1;for(let n of t)if(n.startsWith(`diff --git `)){let t=n.match(/^diff --git a\/(.+) b\/(.+)$/);t&&(t[1]===e||t[2]===e)?(i=!0,r.push(n)):i=!1}else i&&r.push(n);return r.join(`
435
- `)},[n?.patch]),p=(0,d.useMemo)(()=>Array.isArray(n?.files)?n.files.filter(e=>f(e.path).trim()):[],[n?.files,f]);(0,d.useEffect)(()=>{if(!e){r(null),s(null);return}a(!0),Wd().then(e=>{r(e)}).finally(()=>a(!1))},[e]),(0,d.useEffect)(()=>{if(e){if(!p.length){s(null);return}(!o||!p.some(e=>e.path===o))&&s(p[0].path)}},[p,e,o]);let m=(0,d.useMemo)(()=>f(o),[f,o]);return(0,_.jsx)(vm,{open:e,onOpenChange:t,children:(0,_.jsxs)(xm,{className:`sm:max-w-5xl h-[80vh] flex flex-col p-0 gap-0`,children:[(0,_.jsx)(Sm,{className:`px-5 pt-5 pb-3 shrink-0`,children:(0,_.jsx)(wm,{children:B(`gitDiffTitle`)})}),i?(0,_.jsx)(`div`,{className:`flex-1 flex items-center justify-center py-12 text-(--text-muted) text-[13px]`,children:B(`gitDiffLoading`)}):p.length?(0,_.jsxs)(`div`,{className:`flex-1 flex min-h-0 border-t border-(--border-default)`,children:[(0,_.jsx)(`div`,{className:`w-[220px] shrink-0 border-r border-(--border-default) overflow-y-auto py-1`,children:p.map(e=>(0,_.jsxs)(`button`,{onClick:()=>s(e.path),className:z(`w-full text-left px-1 m-1 py-1.5 text-[12px] rounded-md cursor-pointer flex items-center gap-2 border-0 bg-transparent`,o===e.path?`bg-(--bg-hover) text-(--text-primary)`:`text-(--text-secondary) hover:bg-(--bg-hover)`),children:[(0,_.jsx)(`span`,{className:z(`shrink-0 text-[11px] font-mono w-[14px] text-center`,P1[e.status]||``),children:e.status===`?`?`U`:e.status}),(0,_.jsx)(`span`,{className:`truncate`,children:e.path})]},e.path))}),(0,_.jsx)(`div`,{className:`flex-1 overflow-auto`,children:m?(0,_.jsx)(M1,{patch:m,options:{theme:{dark:`pierre-dark`,light:`pierre-light`},themeType:l?`dark`:`light`,diffStyle:`unified`}}):(0,_.jsx)(`div`,{className:`flex items-center justify-center h-full text-(--text-muted) text-[12px]`,children:B(`gitDiffNoDiffAvailable`)})})]}):(0,_.jsx)(`div`,{className:`flex-1 flex items-center justify-center py-12 text-(--text-muted) text-[13px]`,children:B(`gitDiffNoChanges`)})]})})}function I1({size:e=14,className:t,...n}){return(0,_.jsx)(`svg`,{viewBox:`0 0 24 24`,width:e,height:e,fill:`currentColor`,"aria-hidden":`true`,className:t,...n,children:(0,_.jsx)(`path`,{d:`M12 .5C5.65.5.5 5.65.5 12c0 5.09 3.29 9.4 7.86 10.93.58.1.79-.25.79-.56v-2.18c-3.2.69-3.87-1.36-3.87-1.36-.52-1.33-1.28-1.68-1.28-1.68-1.05-.72.08-.7.08-.7 1.16.08 1.77 1.19 1.77 1.19 1.03 1.76 2.7 1.25 3.36.96.1-.75.4-1.25.73-1.54-2.55-.29-5.23-1.27-5.23-5.67 0-1.25.45-2.27 1.18-3.07-.12-.29-.51-1.46.11-3.03 0 0 .97-.31 3.16 1.17A10.98 10.98 0 0 1 12 6.07c.98 0 1.96.13 2.88.39 2.19-1.48 3.15-1.17 3.15-1.17.63 1.57.24 2.74.12 3.03.74.8 1.18 1.82 1.18 3.07 0 4.41-2.69 5.38-5.25 5.66.42.36.78 1.06.78 2.14v3.18c0 .31.21.67.8.56A11.51 11.51 0 0 0 23.5 12C23.5 5.65 18.35.5 12 .5Z`})})}var L1=class extends d.Component{state={error:null};static getDerivedStateFromError(e){return{error:e}}render(){return this.state.error?(0,_.jsxs)(`div`,{style:{padding:32,color:`#d84f4f`,fontFamily:`monospace`,fontSize:13},children:[(0,_.jsx)(`p`,{style:{fontWeight:600,marginBottom:8},children:B(`renderError`)}),(0,_.jsx)(`pre`,{style:{whiteSpace:`pre-wrap`,opacity:.8},children:this.state.error?.message||String(this.state.error)}),(0,_.jsx)(`button`,{onClick:()=>this.setState({error:null}),style:{marginTop:12,padding:`6px 16px`,borderRadius:6,border:`1px solid #d84f4f`,background:`transparent`,color:`#d84f4f`,cursor:`pointer`},children:B(`retry`)})]}):this.props.children}};function R1(){let{state:e,actions:t}=Yf(),n=(e.runtimeState||{}).sessionId;return(0,_.jsxs)(`div`,{className:`flex h-screen bg-(--bg-primary) text-(--text-primary)`,children:[(0,_.jsx)(Fm,{sessions:e.sessions,sessionsLoading:e.sessionsLoading,currentSessionId:n,onNewSession:t.newSession,onSwitchSession:t.switchSession,onToggleTheme:t.toggleTheme,onSetTheme:t.setTheme,onOpenSettings:()=>t.setConfigOpen(!0),onOpenSkills:()=>t.setSkillsOpen(!0),onOpenSouls:()=>t.setSoulsOpen(!0),onOpenAbout:()=>t.setAboutOpen(!0),gitBatch:e.gitBatch,versionInfo:e.versionInfo,onUpdate:t.runUpdate,updateStatus:e.updateStatus,currentView:e.currentView,onSwitchView:t.switchView,onOpenProject:t.openProject,onDeleteSession:t.deleteSession}),(0,_.jsx)(`div`,{className:`flex-1 flex flex-col min-w-0 bg-(--bg-secondary)`,children:e.currentView===`codewiki`?(0,_.jsx)(uq,{projectCwd:e.codewikiProjectPath?.split(/[/\\]/).pop()||e.projectCwd,projectKey:e.codewikiProjectPath||e.runtimeState?.cwd||e.projectCwd||``,busy:e.busy,planSteps:e.planSteps,stageLabel:e.stageLabel}):(0,_.jsxs)(`div`,{className:`flex-1 flex flex-col min-h-0 bg-(--bg-primary) rounded-[18px] border border-(--border-default) border-b-0 relative overflow-hidden my-1 mx-1`,children:[(0,_.jsxs)(`div`,{className:`flex items-center justify-between h-[52px] px-5 shrink-0 border-b border-(--border-default)`,children:[(0,_.jsxs)(`div`,{className:`flex items-center gap-2.5 min-w-0`,children:[(0,_.jsx)(`span`,{className:`font-medium text-[14px] text-(--text-primary) truncate`,children:e.isGeneral?B(`generalChat`):e.projectCwd||`qurio-coder`}),e.gitInfo?.isGit&&(0,_.jsxs)(`span`,{className:`inline-flex items-center gap-1 text-[12px] text-(--text-muted) shrink-0`,children:[(0,_.jsx)(I1,{size:13}),(0,_.jsx)(`span`,{children:e.gitInfo.branch})]}),e.gitInfo?.isGit&&e.gitInfo?.dirty&&(0,_.jsx)(`button`,{onClick:()=>t.setGitDiffOpen(!0),className:`inline-flex items-center gap-1 text-[12px] text-(--text-muted) shrink-0 border-0 bg-transparent cursor-pointer hover:text-(--text-primary) p-0`,children:(0,_.jsx)(jp,{size:13})})]}),(0,_.jsx)(`button`,{className:`border-0 bg-transparent text-(--text-muted) rounded-md p-1.5 cursor-pointer hover:bg-(--bg-hover) hover:text-(--text-primary) shrink-0`,children:(0,_.jsx)(wp,{size:16})})]}),e.planSteps?.length>0&&!e.pendingPlanApproval&&(0,_.jsx)(`div`,{className:`px-4`,children:(0,_.jsx)(Sq,{steps:e.planSteps})}),(0,_.jsx)(kK,{messages:e.messages,projectCwd:e.projectCwd,skills:e.skills,gitInfo:e.gitInfo,messagesLoading:e.messagesLoading,isGeneral:e.isGeneral}),(0,_.jsxs)(`div`,{className:`w-[min(980px,calc(100%-64px))] mx-auto mb-4 shrink-0 z-30 bg-transparent relative`,children:[(0,_.jsx)(Dq,{activities:e.runtimeActivities}),e.pendingPlanApproval&&(0,_.jsx)(`div`,{className:`mb-3`,children:(0,_.jsx)(Cq,{plan:e.pendingPlanApproval,onAction:t.approvePlan,disabled:e.busy})}),e.pendingReflectApproval&&(0,_.jsx)(`div`,{className:`mb-3`,children:(0,_.jsx)(Tq,{draft:e.pendingReflectApproval,onAction:t.approveReflect,disabled:e.busy})}),(0,_.jsx)(RK,{onSubmit:t.submit,onAbort:t.abort,busy:e.busy,disabled:!!e.pendingPlanApproval||!!e.pendingReflectApproval,disabledReason:e.pendingReflectApproval?B(`reflectReviewFirst`):B(`planReviewFirst`),runtimeState:e.runtimeState,history:e.history,onCompletionRequest:async e=>{try{await(await fetch(`/api/completions?q=${encodeURIComponent(e)}`)).json()}catch{}},onOpenProject:()=>t.setProjectOpen(!0),projectCwd:e.projectCwd}),(0,_.jsxs)(`div`,{className:`flex items-center gap-3 pt-2 px-3 min-h-[28px] overflow-hidden`,children:[e.versionInfo?.current&&(0,_.jsxs)(`span`,{className:`inline-flex items-center gap-1 text-[11px] text-(--text-muted) shrink-0`,children:[(0,_.jsx)(`span`,{className:`inline-flex h-3 w-3.5 items-center justify-center rounded-[3px] bg-black text-white dark:bg-white dark:text-black`,children:(0,_.jsx)(im,{size:12,strokeWidth:2.5})}),`Codemini CLI@`,e.versionInfo.current]}),(0,_.jsx)(WK,{runtimeState:e.runtimeState,live:e.live,stageLabel:e.stageLabel})]})]})]})}),(0,_.jsx)(_q,{request:e.approvalRequest,open:!!e.approvalRequest,onDecision:t.approve}),(0,_.jsx)(Lq,{open:e.configOpen,onOpenChange:t.setConfigOpen,status:e.configStatus,onSaved:t.refreshConfigStatus}),(0,_.jsx)($q,{open:e.skillsOpen,onOpenChange:t.setSkillsOpen}),(0,_.jsx)(sJ,{open:e.soulsOpen,onOpenChange:t.setSoulsOpen}),(0,_.jsx)(lJ,{open:e.aboutOpen,onOpenChange:t.setAboutOpen,version:e.versionInfo?.current}),(0,_.jsx)(F1,{open:e.gitDiffOpen,onOpenChange:t.setGitDiffOpen}),(0,_.jsx)(Hq,{open:e.projectOpen,onOpenChange:t.setProjectOpen,onOpenProject:t.openProject})]})}function z1(){return(0,_.jsx)(L1,{children:(0,_.jsx)(md,{children:(0,_.jsx)(Jf,{children:(0,_.jsx)(R1,{})})})})}(0,Vl.createRoot)(document.getElementById(`root`)).render((0,_.jsx)(z1,{}));export{g as a,jI as i,NP as n,i as o,DI as r,aP as t};