@fatdoge/wtree 0.2.1 → 0.3.0

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 (319) hide show
  1. package/api/routes/worktrees.ts +50 -1
  2. package/dist/assets/abap-BdImnpbu.js +1 -0
  3. package/dist/assets/actionscript-3-CoDkCxhg.js +1 -0
  4. package/dist/assets/ada-bCR0ucgS.js +1 -0
  5. package/dist/assets/andromeeda-C4gqWexZ.js +1 -0
  6. package/dist/assets/angular-html-CU67Zn6k.js +1 -0
  7. package/dist/assets/angular-ts-BwZT4LLn.js +1 -0
  8. package/dist/assets/apache-Pmp26Uib.js +1 -0
  9. package/dist/assets/apex-D8_7TLub.js +1 -0
  10. package/dist/assets/apl-dKokRX4l.js +1 -0
  11. package/dist/assets/applescript-Co6uUVPk.js +1 -0
  12. package/dist/assets/ara-BRHolxvo.js +1 -0
  13. package/dist/assets/asciidoc-Ve4PFQV2.js +1 -0
  14. package/dist/assets/asm-D_Q5rh1f.js +1 -0
  15. package/dist/assets/astro-CbQHKStN.js +1 -0
  16. package/dist/assets/aurora-x-D-2ljcwZ.js +1 -0
  17. package/dist/assets/awk-DMzUqQB5.js +1 -0
  18. package/dist/assets/ayu-dark-DYE7WIF3.js +1 -0
  19. package/dist/assets/ayu-light-BA47KaF1.js +1 -0
  20. package/dist/assets/ayu-mirage-32ctXXKs.js +1 -0
  21. package/dist/assets/ballerina-BFfxhgS-.js +1 -0
  22. package/dist/assets/bat-BkioyH1T.js +1 -0
  23. package/dist/assets/beancount-k_qm7-4y.js +1 -0
  24. package/dist/assets/berry-uYugtg8r.js +1 -0
  25. package/dist/assets/bibtex-CHM0blh-.js +1 -0
  26. package/dist/assets/bicep-Bmn6On1c.js +1 -0
  27. package/dist/assets/bird2-DPOp833l.js +1 -0
  28. package/dist/assets/blade-D4QpJJKB.js +1 -0
  29. package/dist/assets/bsl-BO_Y6i37.js +1 -0
  30. package/dist/assets/c-BIGW1oBm.js +1 -0
  31. package/dist/assets/c3-eo99z4R2.js +1 -0
  32. package/dist/assets/cadence-Bv_4Rxtq.js +1 -0
  33. package/dist/assets/cairo-KRGpt6FW.js +1 -0
  34. package/dist/assets/catppuccin-frappe-DFWUc33u.js +1 -0
  35. package/dist/assets/catppuccin-latte-C9dUb6Cb.js +1 -0
  36. package/dist/assets/catppuccin-macchiato-DQyhUUbL.js +1 -0
  37. package/dist/assets/catppuccin-mocha-D87Tk5Gz.js +1 -0
  38. package/dist/assets/clarity-D53aC0YG.js +1 -0
  39. package/dist/assets/clojure-P80f7IUj.js +1 -0
  40. package/dist/assets/cmake-D1j8_8rp.js +1 -0
  41. package/dist/assets/cobol-nwyudZeR.js +1 -0
  42. package/dist/assets/codeowners-Bp6g37R7.js +1 -0
  43. package/dist/assets/codeql-DsOJ9woJ.js +1 -0
  44. package/dist/assets/coffee-Ch7k5sss.js +1 -0
  45. package/dist/assets/common-lisp-Cg-RD9OK.js +1 -0
  46. package/dist/assets/coq-DkFqJrB1.js +1 -0
  47. package/dist/assets/cpp-CofmeUqb.js +1 -0
  48. package/dist/assets/crystal-tKQVLTB8.js +1 -0
  49. package/dist/assets/csharp-COcwbKMJ.js +1 -0
  50. package/dist/assets/css-DPfMkruS.js +1 -0
  51. package/dist/assets/csv-fuZLfV_i.js +1 -0
  52. package/dist/assets/cue-D82EKSYY.js +1 -0
  53. package/dist/assets/cypher-COkxafJQ.js +1 -0
  54. package/dist/assets/d-85-TOEBH.js +1 -0
  55. package/dist/assets/dark-plus-C3mMm8J8.js +1 -0
  56. package/dist/assets/dart-CF10PKvl.js +1 -0
  57. package/dist/assets/dax-CEL-wOlO.js +1 -0
  58. package/dist/assets/desktop-BmXAJ9_W.js +1 -0
  59. package/dist/assets/diff-D97Zzqfu.js +1 -0
  60. package/dist/assets/docker-BcOcwvcX.js +1 -0
  61. package/dist/assets/dotenv-Da5cRb03.js +1 -0
  62. package/dist/assets/dracula-BzJJZx-M.js +1 -0
  63. package/dist/assets/dracula-soft-BXkSAIEj.js +1 -0
  64. package/dist/assets/dream-maker-BtqSS_iP.js +1 -0
  65. package/dist/assets/edge-BkV0erSs.js +1 -0
  66. package/dist/assets/elixir-CDX3lj18.js +1 -0
  67. package/dist/assets/elm-DbKCFpqz.js +1 -0
  68. package/dist/assets/emacs-lisp-C9XAeP06.js +1 -0
  69. package/dist/assets/erb-B12qg9BL.js +1 -0
  70. package/dist/assets/erlang-DsQrWhSR.js +1 -0
  71. package/dist/assets/everforest-dark-BgDCqdQA.js +1 -0
  72. package/dist/assets/everforest-light-C8M2exoo.js +1 -0
  73. package/dist/assets/fennel-BYunw83y.js +1 -0
  74. package/dist/assets/fish-BvzEVeQv.js +1 -0
  75. package/dist/assets/fluent-C4IJs8-o.js +1 -0
  76. package/dist/assets/fortran-fixed-form-CkoXwp7k.js +1 -0
  77. package/dist/assets/fortran-free-form-BxgE0vQu.js +1 -0
  78. package/dist/assets/fsharp-CXgrBDvD.js +1 -0
  79. package/dist/assets/gdresource-BOOCDP_w.js +1 -0
  80. package/dist/assets/gdscript-C5YyOfLZ.js +1 -0
  81. package/dist/assets/gdshader-DkwncUOv.js +1 -0
  82. package/dist/assets/genie-D0YGMca9.js +1 -0
  83. package/dist/assets/gherkin-DyxjwDmM.js +1 -0
  84. package/dist/assets/git-commit-F4YmCXRG.js +1 -0
  85. package/dist/assets/git-rebase-r7XF79zn.js +1 -0
  86. package/dist/assets/github-dark-DHJKELXO.js +1 -0
  87. package/dist/assets/github-dark-default-Cuk6v7N8.js +1 -0
  88. package/dist/assets/github-dark-dimmed-DH5Ifo-i.js +1 -0
  89. package/dist/assets/github-dark-high-contrast-E3gJ1_iC.js +1 -0
  90. package/dist/assets/github-light-DAi9KRSo.js +1 -0
  91. package/dist/assets/github-light-default-D7oLnXFd.js +1 -0
  92. package/dist/assets/github-light-high-contrast-BfjtVDDH.js +1 -0
  93. package/dist/assets/gleam-BspZqrRM.js +1 -0
  94. package/dist/assets/glimmer-js-Rg0-pVw9.js +1 -0
  95. package/dist/assets/glimmer-ts-U6CK756n.js +1 -0
  96. package/dist/assets/glsl-DplSGwfg.js +1 -0
  97. package/dist/assets/gn-n2N0HUVH.js +1 -0
  98. package/dist/assets/gnuplot-DdkO51Og.js +1 -0
  99. package/dist/assets/go-CxLEBnE3.js +1 -0
  100. package/dist/assets/graphql-ChdNCCLP.js +1 -0
  101. package/dist/assets/groovy-gcz8RCvz.js +1 -0
  102. package/dist/assets/gruvbox-dark-hard-CFHQjOhq.js +1 -0
  103. package/dist/assets/gruvbox-dark-medium-GsRaNv29.js +1 -0
  104. package/dist/assets/gruvbox-dark-soft-CVdnzihN.js +1 -0
  105. package/dist/assets/gruvbox-light-hard-CH1njM8p.js +1 -0
  106. package/dist/assets/gruvbox-light-medium-DRw_LuNl.js +1 -0
  107. package/dist/assets/gruvbox-light-soft-hJgmCMqR.js +1 -0
  108. package/dist/assets/hack-CaT9iCJl.js +1 -0
  109. package/dist/assets/haml-B8DHNrY2.js +1 -0
  110. package/dist/assets/handlebars-BL8al0AC.js +1 -0
  111. package/dist/assets/haskell-Df6bDoY_.js +1 -0
  112. package/dist/assets/haxe-CzTSHFRz.js +1 -0
  113. package/dist/assets/hcl-BWvSN4gD.js +1 -0
  114. package/dist/assets/hjson-D5-asLiD.js +1 -0
  115. package/dist/assets/hlsl-D3lLCCz7.js +1 -0
  116. package/dist/assets/horizon-BUw7H-hv.js +1 -0
  117. package/dist/assets/horizon-bright-Cn-bp-IR.js +1 -0
  118. package/dist/assets/houston-DnULxvSX.js +1 -0
  119. package/dist/assets/html-GMplVEZG.js +1 -0
  120. package/dist/assets/html-derivative-BFtXZ54Q.js +1 -0
  121. package/dist/assets/http-jrhK8wxY.js +1 -0
  122. package/dist/assets/hurl-irOxFIW8.js +1 -0
  123. package/dist/assets/hxml-Bvhsp5Yf.js +1 -0
  124. package/dist/assets/hy-DFXneXwc.js +1 -0
  125. package/dist/assets/imba-DGztddWO.js +1 -0
  126. package/dist/assets/index-bLnnvz_q.css +1 -0
  127. package/dist/assets/index-sP_n0D3A.js +2246 -0
  128. package/dist/assets/ini-BEwlwnbL.js +1 -0
  129. package/dist/assets/java-CylS5w8V.js +1 -0
  130. package/dist/assets/javascript-wDzz0qaB.js +1 -0
  131. package/dist/assets/jinja-4LBKfQ-Z.js +1 -0
  132. package/dist/assets/jison-wvAkD_A8.js +1 -0
  133. package/dist/assets/json-Cp-IABpG.js +1 -0
  134. package/dist/assets/json5-C9tS-k6U.js +1 -0
  135. package/dist/assets/jsonc-Des-eS-w.js +1 -0
  136. package/dist/assets/jsonl-DcaNXYhu.js +1 -0
  137. package/dist/assets/jsonnet-DFQXde-d.js +1 -0
  138. package/dist/assets/jssm-C2t-YnRu.js +1 -0
  139. package/dist/assets/jsx-g9-lgVsj.js +1 -0
  140. package/dist/assets/julia-CxzCAyBv.js +1 -0
  141. package/dist/assets/just-Cw27pwNe.js +1 -0
  142. package/dist/assets/kanagawa-dragon-CkXjmgJE.js +1 -0
  143. package/dist/assets/kanagawa-lotus-CfQXZHmo.js +1 -0
  144. package/dist/assets/kanagawa-wave-DWedfzmr.js +1 -0
  145. package/dist/assets/kdl-DV7GczEv.js +1 -0
  146. package/dist/assets/kotlin-BdnUsdx6.js +1 -0
  147. package/dist/assets/kusto-DZf3V79B.js +1 -0
  148. package/dist/assets/laserwave-DUszq2jm.js +1 -0
  149. package/dist/assets/latex-CWtU0Tv5.js +1 -0
  150. package/dist/assets/lean-BZvkOJ9d.js +1 -0
  151. package/dist/assets/less-B1dDrJ26.js +1 -0
  152. package/dist/assets/light-plus-B7mTdjB0.js +1 -0
  153. package/dist/assets/liquid-DYVedYrR.js +1 -0
  154. package/dist/assets/llvm-DjAJT7YJ.js +1 -0
  155. package/dist/assets/log-2UxHyX5q.js +1 -0
  156. package/dist/assets/logo-BtOb2qkB.js +1 -0
  157. package/dist/assets/lua-BaeVxFsk.js +1 -0
  158. package/dist/assets/luau-C-HG3fhB.js +1 -0
  159. package/dist/assets/make-CHLpvVh8.js +1 -0
  160. package/dist/assets/markdown-Cvjx9yec.js +1 -0
  161. package/dist/assets/marko-CnJfTvn9.js +1 -0
  162. package/dist/assets/material-theme-D5KoaKCx.js +1 -0
  163. package/dist/assets/material-theme-darker-BfHTSMKl.js +1 -0
  164. package/dist/assets/material-theme-lighter-B0m2ddpp.js +1 -0
  165. package/dist/assets/material-theme-ocean-CyktbL80.js +1 -0
  166. package/dist/assets/material-theme-palenight-Csfq5Kiy.js +1 -0
  167. package/dist/assets/matlab-D7o27uSR.js +1 -0
  168. package/dist/assets/mdc-BMNejdWA.js +1 -0
  169. package/dist/assets/mdx-Cmh6b_Ma.js +1 -0
  170. package/dist/assets/mermaid-mWjccvbQ.js +1 -0
  171. package/dist/assets/min-dark-CafNBF8u.js +1 -0
  172. package/dist/assets/min-light-CTRr51gU.js +1 -0
  173. package/dist/assets/mipsasm-CKIfxQSi.js +1 -0
  174. package/dist/assets/mojo-rZm6bMo-.js +1 -0
  175. package/dist/assets/monokai-D4h5O-jR.js +1 -0
  176. package/dist/assets/moonbit-_H4v1dQx.js +1 -0
  177. package/dist/assets/move-IF9eRakj.js +1 -0
  178. package/dist/assets/narrat-DRg8JJMk.js +1 -0
  179. package/dist/assets/nextflow-Zz6hmt5N.js +1 -0
  180. package/dist/assets/nextflow-groovy-BeH2EWoN.js +1 -0
  181. package/dist/assets/nginx-BpAMiNFr.js +1 -0
  182. package/dist/assets/night-owl-C39BiMTA.js +1 -0
  183. package/dist/assets/night-owl-light-CMTm3GFP.js +1 -0
  184. package/dist/assets/nim-CVrawwO9.js +1 -0
  185. package/dist/assets/nix-CwoSXNpI.js +1 -0
  186. package/dist/assets/nord-Ddv68eIx.js +1 -0
  187. package/dist/assets/nushell-Cz2AlsmD.js +1 -0
  188. package/dist/assets/objective-c-DXmwc3jG.js +1 -0
  189. package/dist/assets/objective-cpp-CLxacb5B.js +1 -0
  190. package/dist/assets/ocaml-C0hk2d4L.js +1 -0
  191. package/dist/assets/odin-BBf5iR-q.js +1 -0
  192. package/dist/assets/one-dark-pro-DVMEJ2y_.js +1 -0
  193. package/dist/assets/one-light-C3Wv6jpd.js +1 -0
  194. package/dist/assets/openscad-C4EeE6gA.js +1 -0
  195. package/dist/assets/pascal-D93ZcfNL.js +1 -0
  196. package/dist/assets/perl-C0TMdlhV.js +1 -0
  197. package/dist/assets/php-Dhbhpdrm.js +1 -0
  198. package/dist/assets/pierre-dark-DF2SEV7i.js +1 -0
  199. package/dist/assets/pierre-light-DOlZxES8.js +1 -0
  200. package/dist/assets/pkl-u5AG7uiY.js +1 -0
  201. package/dist/assets/plastic-3e1v2bzS.js +1 -0
  202. package/dist/assets/plsql-ChMvpjG-.js +1 -0
  203. package/dist/assets/po-BTJTHyun.js +1 -0
  204. package/dist/assets/poimandres-CS3Unz2-.js +1 -0
  205. package/dist/assets/polar-C0HS_06l.js +1 -0
  206. package/dist/assets/postcss-CXtECtnM.js +1 -0
  207. package/dist/assets/powerquery-CEu0bR-o.js +1 -0
  208. package/dist/assets/powershell-Dpen1YoG.js +1 -0
  209. package/dist/assets/prisma-Dd19v3D-.js +1 -0
  210. package/dist/assets/prolog-CbFg5uaA.js +1 -0
  211. package/dist/assets/proto-C7zT0LnQ.js +1 -0
  212. package/dist/assets/pug-CGlum2m_.js +1 -0
  213. package/dist/assets/puppet-BMWR74SV.js +1 -0
  214. package/dist/assets/purescript-CklMAg4u.js +1 -0
  215. package/dist/assets/python-B6aJPvgy.js +1 -0
  216. package/dist/assets/qml-3beO22l8.js +1 -0
  217. package/dist/assets/qmldir-C8lEn-DE.js +1 -0
  218. package/dist/assets/qss-IeuSbFQv.js +1 -0
  219. package/dist/assets/r-Dspwwk_N.js +1 -0
  220. package/dist/assets/racket-BqYA7rlc.js +1 -0
  221. package/dist/assets/raku-DXvB9xmW.js +1 -0
  222. package/dist/assets/razor-Uh8Bk_45.js +1 -0
  223. package/dist/assets/red-bN70gL4F.js +1 -0
  224. package/dist/assets/reg-C-SQnVFl.js +1 -0
  225. package/dist/assets/regexp-CDVJQ6XC.js +1 -0
  226. package/dist/assets/rel-C3B-1QV4.js +1 -0
  227. package/dist/assets/riscv-BM1_JUlF.js +1 -0
  228. package/dist/assets/ron-D8l8udqQ.js +1 -0
  229. package/dist/assets/rose-pine-dawn-DHQR4-dF.js +1 -0
  230. package/dist/assets/rose-pine-moon-D4_iv3hh.js +1 -0
  231. package/dist/assets/rose-pine-qdsjHGoJ.js +1 -0
  232. package/dist/assets/rosmsg-BJDFO7_C.js +1 -0
  233. package/dist/assets/rst-BrH8l1NY.js +1 -0
  234. package/dist/assets/ruby-Dw2BHqvy.js +1 -0
  235. package/dist/assets/rust-B1yitclQ.js +1 -0
  236. package/dist/assets/sas-cz2c8ADy.js +1 -0
  237. package/dist/assets/sass-Cj5Yp3dK.js +1 -0
  238. package/dist/assets/scala-C151Ov-r.js +1 -0
  239. package/dist/assets/scheme-C98Dy4si.js +1 -0
  240. package/dist/assets/scss-OYdSNvt2.js +1 -0
  241. package/dist/assets/sdbl-DVxCFoDh.js +1 -0
  242. package/dist/assets/shaderlab-Dg9Lc6iA.js +1 -0
  243. package/dist/assets/shellscript-Yzrsuije.js +1 -0
  244. package/dist/assets/shellsession-BADoaaVG.js +1 -0
  245. package/dist/assets/slack-dark-BthQWCQV.js +1 -0
  246. package/dist/assets/slack-ochin-DqwNpetd.js +1 -0
  247. package/dist/assets/smalltalk-BERRCDM3.js +1 -0
  248. package/dist/assets/snazzy-light-Bw305WKR.js +1 -0
  249. package/dist/assets/solarized-dark-DXbdFlpD.js +1 -0
  250. package/dist/assets/solarized-light-L9t79GZl.js +1 -0
  251. package/dist/assets/solidity-rGO070M0.js +1 -0
  252. package/dist/assets/soy-Brmx7dQM.js +1 -0
  253. package/dist/assets/sparql-rVzFXLq3.js +1 -0
  254. package/dist/assets/splunk-BtCnVYZw.js +1 -0
  255. package/dist/assets/sql-BLtJtn59.js +1 -0
  256. package/dist/assets/ssh-config-_ykCGR6B.js +1 -0
  257. package/dist/assets/stata-BH5u7GGu.js +1 -0
  258. package/dist/assets/stylus-BEDo0Tqx.js +1 -0
  259. package/dist/assets/surrealql-Bq5Q-fJD.js +1 -0
  260. package/dist/assets/svelte-C_ipcX3V.js +1 -0
  261. package/dist/assets/swift-D82vCrfD.js +1 -0
  262. package/dist/assets/synthwave-84-CbfX1IO0.js +1 -0
  263. package/dist/assets/system-verilog-CnnmHF94.js +1 -0
  264. package/dist/assets/systemd-4A_iFExJ.js +1 -0
  265. package/dist/assets/talonscript-CkByrt1z.js +1 -0
  266. package/dist/assets/tasl-QIJgUcNo.js +1 -0
  267. package/dist/assets/tcl-dwOrl1Do.js +1 -0
  268. package/dist/assets/templ-P3uqSqPl.js +1 -0
  269. package/dist/assets/terraform-BETggiCN.js +1 -0
  270. package/dist/assets/tex-idrVyKtj.js +1 -0
  271. package/dist/assets/tokyo-night-hegEt444.js +1 -0
  272. package/dist/assets/toml-vGWfd6FD.js +1 -0
  273. package/dist/assets/ts-tags-zn1MmPIZ.js +1 -0
  274. package/dist/assets/tsv-B_m7g4N7.js +1 -0
  275. package/dist/assets/tsx-COt5Ahok.js +1 -0
  276. package/dist/assets/turtle-BsS91CYL.js +1 -0
  277. package/dist/assets/twig-DNn4PbVi.js +1 -0
  278. package/dist/assets/typescript-BPQ3VLAy.js +1 -0
  279. package/dist/assets/typespec-BGHnOYBU.js +1 -0
  280. package/dist/assets/typst-DHCkPAjA.js +1 -0
  281. package/dist/assets/v-BcVCzyr7.js +1 -0
  282. package/dist/assets/vala-CsfeWuGM.js +1 -0
  283. package/dist/assets/vb-D17OF-Vu.js +1 -0
  284. package/dist/assets/verilog-BQ8w6xss.js +1 -0
  285. package/dist/assets/vesper-DU1UobuO.js +1 -0
  286. package/dist/assets/vhdl-CeAyd5Ju.js +1 -0
  287. package/dist/assets/viml-CJc9bBzg.js +1 -0
  288. package/dist/assets/vitesse-black-Bkuqu6BP.js +1 -0
  289. package/dist/assets/vitesse-dark-D0r3Knsf.js +1 -0
  290. package/dist/assets/vitesse-light-CVO1_9PV.js +1 -0
  291. package/dist/assets/vue-DN_0RTcg.js +1 -0
  292. package/dist/assets/vue-html-AaS7Mt5G.js +1 -0
  293. package/dist/assets/vue-vine-CQOfvN7w.js +1 -0
  294. package/dist/assets/vyper-CDx5xZoG.js +1 -0
  295. package/dist/assets/wasm-CG6Dc4jp.js +1 -0
  296. package/dist/assets/wasm-MzD3tlZU.js +1 -0
  297. package/dist/assets/wenyan-BV7otONQ.js +1 -0
  298. package/dist/assets/wgsl-Dx-B1_4e.js +1 -0
  299. package/dist/assets/wikitext-BhOHFoWU.js +1 -0
  300. package/dist/assets/wit-5i3qLPDT.js +1 -0
  301. package/dist/assets/wolfram-lXgVvXCa.js +1 -0
  302. package/dist/assets/xml-sdJ4AIDG.js +1 -0
  303. package/dist/assets/xsl-CtQFsRM5.js +1 -0
  304. package/dist/assets/yaml-Buea-lGh.js +1 -0
  305. package/dist/assets/zenscript-DVFEvuxE.js +1 -0
  306. package/dist/assets/zig-VOosw3JB.js +1 -0
  307. package/dist/index.html +2 -2
  308. package/dist-node/api/routes/worktrees.js +40 -1
  309. package/package.json +3 -1
  310. package/shared/wtui-types.ts +20 -0
  311. package/skills/wtree/SKILL.md +21 -2
  312. package/src/components/DiffPreviewModal.tsx +381 -0
  313. package/src/components/Modal.tsx +11 -2
  314. package/src/i18n/locales/en.json +17 -0
  315. package/src/i18n/locales/zh.json +17 -0
  316. package/src/pages/Worktrees.tsx +55 -1
  317. package/src/stores/worktreeStore.ts +7 -1
  318. package/dist/assets/index-C78PMV-C.js +0 -179
  319. package/dist/assets/index-CR9jga1C.css +0 -1
@@ -0,0 +1,2246 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/angular-html-CU67Zn6k.js","assets/html-GMplVEZG.js","assets/javascript-wDzz0qaB.js","assets/css-DPfMkruS.js","assets/angular-ts-BwZT4LLn.js","assets/scss-OYdSNvt2.js","assets/apl-dKokRX4l.js","assets/xml-sdJ4AIDG.js","assets/java-CylS5w8V.js","assets/json-Cp-IABpG.js","assets/astro-CbQHKStN.js","assets/typescript-BPQ3VLAy.js","assets/postcss-CXtECtnM.js","assets/tsx-COt5Ahok.js","assets/blade-D4QpJJKB.js","assets/html-derivative-BFtXZ54Q.js","assets/sql-BLtJtn59.js","assets/bsl-BO_Y6i37.js","assets/sdbl-DVxCFoDh.js","assets/cairo-KRGpt6FW.js","assets/python-B6aJPvgy.js","assets/cobol-nwyudZeR.js","assets/coffee-Ch7k5sss.js","assets/cpp-CofmeUqb.js","assets/regexp-CDVJQ6XC.js","assets/glsl-DplSGwfg.js","assets/c-BIGW1oBm.js","assets/crystal-tKQVLTB8.js","assets/shellscript-Yzrsuije.js","assets/edge-BkV0erSs.js","assets/elixir-CDX3lj18.js","assets/elm-DbKCFpqz.js","assets/erb-B12qg9BL.js","assets/ruby-Dw2BHqvy.js","assets/haml-B8DHNrY2.js","assets/graphql-ChdNCCLP.js","assets/jsx-g9-lgVsj.js","assets/lua-BaeVxFsk.js","assets/yaml-Buea-lGh.js","assets/erlang-DsQrWhSR.js","assets/markdown-Cvjx9yec.js","assets/fortran-fixed-form-CkoXwp7k.js","assets/fortran-free-form-BxgE0vQu.js","assets/fsharp-CXgrBDvD.js","assets/gdresource-BOOCDP_w.js","assets/gdshader-DkwncUOv.js","assets/gdscript-C5YyOfLZ.js","assets/git-commit-F4YmCXRG.js","assets/diff-D97Zzqfu.js","assets/git-rebase-r7XF79zn.js","assets/glimmer-js-Rg0-pVw9.js","assets/glimmer-ts-U6CK756n.js","assets/hack-CaT9iCJl.js","assets/handlebars-BL8al0AC.js","assets/http-jrhK8wxY.js","assets/hurl-irOxFIW8.js","assets/csv-fuZLfV_i.js","assets/hxml-Bvhsp5Yf.js","assets/haxe-CzTSHFRz.js","assets/jinja-4LBKfQ-Z.js","assets/jison-wvAkD_A8.js","assets/julia-CxzCAyBv.js","assets/r-Dspwwk_N.js","assets/just-Cw27pwNe.js","assets/perl-C0TMdlhV.js","assets/latex-CWtU0Tv5.js","assets/tex-idrVyKtj.js","assets/liquid-DYVedYrR.js","assets/marko-CnJfTvn9.js","assets/less-B1dDrJ26.js","assets/mdc-BMNejdWA.js","assets/nextflow-Zz6hmt5N.js","assets/nextflow-groovy-BeH2EWoN.js","assets/nginx-BpAMiNFr.js","assets/nim-CVrawwO9.js","assets/php-Dhbhpdrm.js","assets/pug-CGlum2m_.js","assets/qml-3beO22l8.js","assets/razor-Uh8Bk_45.js","assets/csharp-COcwbKMJ.js","assets/rst-BrH8l1NY.js","assets/cmake-D1j8_8rp.js","assets/sas-cz2c8ADy.js","assets/shaderlab-Dg9Lc6iA.js","assets/hlsl-D3lLCCz7.js","assets/shellsession-BADoaaVG.js","assets/soy-Brmx7dQM.js","assets/sparql-rVzFXLq3.js","assets/turtle-BsS91CYL.js","assets/stata-BH5u7GGu.js","assets/surrealql-Bq5Q-fJD.js","assets/svelte-C_ipcX3V.js","assets/templ-P3uqSqPl.js","assets/go-CxLEBnE3.js","assets/ts-tags-zn1MmPIZ.js","assets/twig-DNn4PbVi.js","assets/vue-DN_0RTcg.js","assets/vue-html-AaS7Mt5G.js","assets/vue-vine-CQOfvN7w.js","assets/stylus-BEDo0Tqx.js","assets/xsl-CtQFsRM5.js"])))=>i.map(i=>d[i]);
2
+ var wC=Object.defineProperty;var bC=Object.getPrototypeOf;var xC=Reflect.get;var av=e=>{throw TypeError(e)};var _C=(e,t,n)=>t in e?wC(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var F=(e,t,n)=>_C(e,typeof t!="symbol"?t+"":t,n),qp=(e,t,n)=>t.has(e)||av("Cannot "+n);var x=(e,t,n)=>(qp(e,t,"read from private field"),n?n.call(e):t.get(e)),ye=(e,t,n)=>t.has(e)?av("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),Y=(e,t,n,r)=>(qp(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),V=(e,t,n)=>(qp(e,t,"access private method"),n);var lv=(e,t,n)=>xC(bC(e),n,t);(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const s of i)if(s.type==="childList")for(const l of s.addedNodes)l.tagName==="LINK"&&l.rel==="modulepreload"&&r(l)}).observe(document,{childList:!0,subtree:!0});function n(i){const s={};return i.integrity&&(s.integrity=i.integrity),i.referrerPolicy&&(s.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?s.credentials="include":i.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function r(i){if(i.ep)return;i.ep=!0;const s=n(i);fetch(i.href,s)}})();function jb(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Kp={exports:{}},Sc={},Xp={exports:{}},Ze={};/**
3
+ * @license React
4
+ * react.production.min.js
5
+ *
6
+ * Copyright (c) Facebook, Inc. and its affiliates.
7
+ *
8
+ * This source code is licensed under the MIT license found in the
9
+ * LICENSE file in the root directory of this source tree.
10
+ */var cv;function kC(){if(cv)return Ze;cv=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),l=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),f=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),h=Symbol.iterator;function g(O){return O===null||typeof O!="object"?null:(O=h&&O[h]||O["@@iterator"],typeof O=="function"?O:null)}var y={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},w=Object.assign,_={};function C(O,J,fe){this.props=O,this.context=J,this.refs=_,this.updater=fe||y}C.prototype.isReactComponent={},C.prototype.setState=function(O,J){if(typeof O!="object"&&typeof O!="function"&&O!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,O,J,"setState")},C.prototype.forceUpdate=function(O){this.updater.enqueueForceUpdate(this,O,"forceUpdate")};function I(){}I.prototype=C.prototype;function E(O,J,fe){this.props=O,this.context=J,this.refs=_,this.updater=fe||y}var S=E.prototype=new I;S.constructor=E,w(S,C.prototype),S.isPureReactComponent=!0;var L=Array.isArray,A=Object.prototype.hasOwnProperty,R={current:null},U={key:!0,ref:!0,__self:!0,__source:!0};function X(O,J,fe){var we,be={},Pe=null,Ne=null;if(J!=null)for(we in J.ref!==void 0&&(Ne=J.ref),J.key!==void 0&&(Pe=""+J.key),J)A.call(J,we)&&!U.hasOwnProperty(we)&&(be[we]=J[we]);var he=arguments.length-2;if(he===1)be.children=fe;else if(1<he){for(var Te=Array(he),Qe=0;Qe<he;Qe++)Te[Qe]=arguments[Qe+2];be.children=Te}if(O&&O.defaultProps)for(we in he=O.defaultProps,he)be[we]===void 0&&(be[we]=he[we]);return{$$typeof:e,type:O,key:Pe,ref:Ne,props:be,_owner:R.current}}function H(O,J){return{$$typeof:e,type:O.type,key:J,ref:O.ref,props:O.props,_owner:O._owner}}function re(O){return typeof O=="object"&&O!==null&&O.$$typeof===e}function de(O){var J={"=":"=0",":":"=2"};return"$"+O.replace(/[=:]/g,function(fe){return J[fe]})}var te=/\/+/g;function Q(O,J){return typeof O=="object"&&O!==null&&O.key!=null?de(""+O.key):J.toString(36)}function ee(O,J,fe,we,be){var Pe=typeof O;(Pe==="undefined"||Pe==="boolean")&&(O=null);var Ne=!1;if(O===null)Ne=!0;else switch(Pe){case"string":case"number":Ne=!0;break;case"object":switch(O.$$typeof){case e:case t:Ne=!0}}if(Ne)return Ne=O,be=be(Ne),O=we===""?"."+Q(Ne,0):we,L(be)?(fe="",O!=null&&(fe=O.replace(te,"$&/")+"/"),ee(be,J,fe,"",function(Qe){return Qe})):be!=null&&(re(be)&&(be=H(be,fe+(!be.key||Ne&&Ne.key===be.key?"":(""+be.key).replace(te,"$&/")+"/")+O)),J.push(be)),1;if(Ne=0,we=we===""?".":we+":",L(O))for(var he=0;he<O.length;he++){Pe=O[he];var Te=we+Q(Pe,he);Ne+=ee(Pe,J,fe,Te,be)}else if(Te=g(O),typeof Te=="function")for(O=Te.call(O),he=0;!(Pe=O.next()).done;)Pe=Pe.value,Te=we+Q(Pe,he++),Ne+=ee(Pe,J,fe,Te,be);else if(Pe==="object")throw J=String(O),Error("Objects are not valid as a React child (found: "+(J==="[object Object]"?"object with keys {"+Object.keys(O).join(", ")+"}":J)+"). If you meant to render a collection of children, use an array instead.");return Ne}function K(O,J,fe){if(O==null)return O;var we=[],be=0;return ee(O,we,"","",function(Pe){return J.call(fe,Pe,be++)}),we}function oe(O){if(O._status===-1){var J=O._result;J=J(),J.then(function(fe){(O._status===0||O._status===-1)&&(O._status=1,O._result=fe)},function(fe){(O._status===0||O._status===-1)&&(O._status=2,O._result=fe)}),O._status===-1&&(O._status=0,O._result=J)}if(O._status===1)return O._result.default;throw O._result}var ie={current:null},W={transition:null},ce={ReactCurrentDispatcher:ie,ReactCurrentBatchConfig:W,ReactCurrentOwner:R};function le(){throw Error("act(...) is not supported in production builds of React.")}return Ze.Children={map:K,forEach:function(O,J,fe){K(O,function(){J.apply(this,arguments)},fe)},count:function(O){var J=0;return K(O,function(){J++}),J},toArray:function(O){return K(O,function(J){return J})||[]},only:function(O){if(!re(O))throw Error("React.Children.only expected to receive a single React element child.");return O}},Ze.Component=C,Ze.Fragment=n,Ze.Profiler=i,Ze.PureComponent=E,Ze.StrictMode=r,Ze.Suspense=d,Ze.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=ce,Ze.act=le,Ze.cloneElement=function(O,J,fe){if(O==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+O+".");var we=w({},O.props),be=O.key,Pe=O.ref,Ne=O._owner;if(J!=null){if(J.ref!==void 0&&(Pe=J.ref,Ne=R.current),J.key!==void 0&&(be=""+J.key),O.type&&O.type.defaultProps)var he=O.type.defaultProps;for(Te in J)A.call(J,Te)&&!U.hasOwnProperty(Te)&&(we[Te]=J[Te]===void 0&&he!==void 0?he[Te]:J[Te])}var Te=arguments.length-2;if(Te===1)we.children=fe;else if(1<Te){he=Array(Te);for(var Qe=0;Qe<Te;Qe++)he[Qe]=arguments[Qe+2];we.children=he}return{$$typeof:e,type:O.type,key:be,ref:Pe,props:we,_owner:Ne}},Ze.createContext=function(O){return O={$$typeof:l,_currentValue:O,_currentValue2:O,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},O.Provider={$$typeof:s,_context:O},O.Consumer=O},Ze.createElement=X,Ze.createFactory=function(O){var J=X.bind(null,O);return J.type=O,J},Ze.createRef=function(){return{current:null}},Ze.forwardRef=function(O){return{$$typeof:c,render:O}},Ze.isValidElement=re,Ze.lazy=function(O){return{$$typeof:m,_payload:{_status:-1,_result:O},_init:oe}},Ze.memo=function(O,J){return{$$typeof:f,type:O,compare:J===void 0?null:J}},Ze.startTransition=function(O){var J=W.transition;W.transition={};try{O()}finally{W.transition=J}},Ze.unstable_act=le,Ze.useCallback=function(O,J){return ie.current.useCallback(O,J)},Ze.useContext=function(O){return ie.current.useContext(O)},Ze.useDebugValue=function(){},Ze.useDeferredValue=function(O){return ie.current.useDeferredValue(O)},Ze.useEffect=function(O,J){return ie.current.useEffect(O,J)},Ze.useId=function(){return ie.current.useId()},Ze.useImperativeHandle=function(O,J,fe){return ie.current.useImperativeHandle(O,J,fe)},Ze.useInsertionEffect=function(O,J){return ie.current.useInsertionEffect(O,J)},Ze.useLayoutEffect=function(O,J){return ie.current.useLayoutEffect(O,J)},Ze.useMemo=function(O,J){return ie.current.useMemo(O,J)},Ze.useReducer=function(O,J,fe){return ie.current.useReducer(O,J,fe)},Ze.useRef=function(O){return ie.current.useRef(O)},Ze.useState=function(O){return ie.current.useState(O)},Ze.useSyncExternalStore=function(O,J,fe){return ie.current.useSyncExternalStore(O,J,fe)},Ze.useTransition=function(){return ie.current.useTransition()},Ze.version="18.3.1",Ze}var uv;function rh(){return uv||(uv=1,Xp.exports=kC()),Xp.exports}/**
11
+ * @license React
12
+ * react-jsx-runtime.production.min.js
13
+ *
14
+ * Copyright (c) Facebook, Inc. and its affiliates.
15
+ *
16
+ * This source code is licensed under the MIT license found in the
17
+ * LICENSE file in the root directory of this source tree.
18
+ */var dv;function SC(){if(dv)return Sc;dv=1;var e=rh(),t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,i=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s={key:!0,ref:!0,__self:!0,__source:!0};function l(c,d,f){var m,h={},g=null,y=null;f!==void 0&&(g=""+f),d.key!==void 0&&(g=""+d.key),d.ref!==void 0&&(y=d.ref);for(m in d)r.call(d,m)&&!s.hasOwnProperty(m)&&(h[m]=d[m]);if(c&&c.defaultProps)for(m in d=c.defaultProps,d)h[m]===void 0&&(h[m]=d[m]);return{$$typeof:t,type:c,key:g,ref:y,props:h,_owner:i.current}}return Sc.Fragment=n,Sc.jsx=l,Sc.jsxs=l,Sc}var fv;function CC(){return fv||(fv=1,Kp.exports=SC()),Kp.exports}var P=CC(),B=rh();const ge=jb(B);var Bd={},Qp={exports:{}},Gn={},Yp={exports:{}},Jp={};/**
19
+ * @license React
20
+ * scheduler.production.min.js
21
+ *
22
+ * Copyright (c) Facebook, Inc. and its affiliates.
23
+ *
24
+ * This source code is licensed under the MIT license found in the
25
+ * LICENSE file in the root directory of this source tree.
26
+ */var hv;function EC(){return hv||(hv=1,(function(e){function t(W,ce){var le=W.length;W.push(ce);e:for(;0<le;){var O=le-1>>>1,J=W[O];if(0<i(J,ce))W[O]=ce,W[le]=J,le=O;else break e}}function n(W){return W.length===0?null:W[0]}function r(W){if(W.length===0)return null;var ce=W[0],le=W.pop();if(le!==ce){W[0]=le;e:for(var O=0,J=W.length,fe=J>>>1;O<fe;){var we=2*(O+1)-1,be=W[we],Pe=we+1,Ne=W[Pe];if(0>i(be,le))Pe<J&&0>i(Ne,be)?(W[O]=Ne,W[Pe]=le,O=Pe):(W[O]=be,W[we]=le,O=we);else if(Pe<J&&0>i(Ne,le))W[O]=Ne,W[Pe]=le,O=Pe;else break e}}return ce}function i(W,ce){var le=W.sortIndex-ce.sortIndex;return le!==0?le:W.id-ce.id}if(typeof performance=="object"&&typeof performance.now=="function"){var s=performance;e.unstable_now=function(){return s.now()}}else{var l=Date,c=l.now();e.unstable_now=function(){return l.now()-c}}var d=[],f=[],m=1,h=null,g=3,y=!1,w=!1,_=!1,C=typeof setTimeout=="function"?setTimeout:null,I=typeof clearTimeout=="function"?clearTimeout:null,E=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function S(W){for(var ce=n(f);ce!==null;){if(ce.callback===null)r(f);else if(ce.startTime<=W)r(f),ce.sortIndex=ce.expirationTime,t(d,ce);else break;ce=n(f)}}function L(W){if(_=!1,S(W),!w)if(n(d)!==null)w=!0,oe(A);else{var ce=n(f);ce!==null&&ie(L,ce.startTime-W)}}function A(W,ce){w=!1,_&&(_=!1,I(X),X=-1),y=!0;var le=g;try{for(S(ce),h=n(d);h!==null&&(!(h.expirationTime>ce)||W&&!de());){var O=h.callback;if(typeof O=="function"){h.callback=null,g=h.priorityLevel;var J=O(h.expirationTime<=ce);ce=e.unstable_now(),typeof J=="function"?h.callback=J:h===n(d)&&r(d),S(ce)}else r(d);h=n(d)}if(h!==null)var fe=!0;else{var we=n(f);we!==null&&ie(L,we.startTime-ce),fe=!1}return fe}finally{h=null,g=le,y=!1}}var R=!1,U=null,X=-1,H=5,re=-1;function de(){return!(e.unstable_now()-re<H)}function te(){if(U!==null){var W=e.unstable_now();re=W;var ce=!0;try{ce=U(!0,W)}finally{ce?Q():(R=!1,U=null)}}else R=!1}var Q;if(typeof E=="function")Q=function(){E(te)};else if(typeof MessageChannel<"u"){var ee=new MessageChannel,K=ee.port2;ee.port1.onmessage=te,Q=function(){K.postMessage(null)}}else Q=function(){C(te,0)};function oe(W){U=W,R||(R=!0,Q())}function ie(W,ce){X=C(function(){W(e.unstable_now())},ce)}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(W){W.callback=null},e.unstable_continueExecution=function(){w||y||(w=!0,oe(A))},e.unstable_forceFrameRate=function(W){0>W||125<W?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):H=0<W?Math.floor(1e3/W):5},e.unstable_getCurrentPriorityLevel=function(){return g},e.unstable_getFirstCallbackNode=function(){return n(d)},e.unstable_next=function(W){switch(g){case 1:case 2:case 3:var ce=3;break;default:ce=g}var le=g;g=ce;try{return W()}finally{g=le}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(W,ce){switch(W){case 1:case 2:case 3:case 4:case 5:break;default:W=3}var le=g;g=W;try{return ce()}finally{g=le}},e.unstable_scheduleCallback=function(W,ce,le){var O=e.unstable_now();switch(typeof le=="object"&&le!==null?(le=le.delay,le=typeof le=="number"&&0<le?O+le:O):le=O,W){case 1:var J=-1;break;case 2:J=250;break;case 5:J=1073741823;break;case 4:J=1e4;break;default:J=5e3}return J=le+J,W={id:m++,callback:ce,priorityLevel:W,startTime:le,expirationTime:J,sortIndex:-1},le>O?(W.sortIndex=le,t(f,W),n(d)===null&&W===n(f)&&(_?(I(X),X=-1):_=!0,ie(L,le-O))):(W.sortIndex=J,t(d,W),w||y||(w=!0,oe(A))),W},e.unstable_shouldYield=de,e.unstable_wrapCallback=function(W){var ce=g;return function(){var le=g;g=ce;try{return W.apply(this,arguments)}finally{g=le}}}})(Jp)),Jp}var pv;function IC(){return pv||(pv=1,Yp.exports=EC()),Yp.exports}/**
27
+ * @license React
28
+ * react-dom.production.min.js
29
+ *
30
+ * Copyright (c) Facebook, Inc. and its affiliates.
31
+ *
32
+ * This source code is licensed under the MIT license found in the
33
+ * LICENSE file in the root directory of this source tree.
34
+ */var mv;function PC(){if(mv)return Gn;mv=1;var e=rh(),t=IC();function n(o){for(var a="https://reactjs.org/docs/error-decoder.html?invariant="+o,u=1;u<arguments.length;u++)a+="&args[]="+encodeURIComponent(arguments[u]);return"Minified React error #"+o+"; visit "+a+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var r=new Set,i={};function s(o,a){l(o,a),l(o+"Capture",a)}function l(o,a){for(i[o]=a,o=0;o<a.length;o++)r.add(a[o])}var c=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),d=Object.prototype.hasOwnProperty,f=/^[: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]*$/,m={},h={};function g(o){return d.call(h,o)?!0:d.call(m,o)?!1:f.test(o)?h[o]=!0:(m[o]=!0,!1)}function y(o,a,u,p){if(u!==null&&u.type===0)return!1;switch(typeof a){case"function":case"symbol":return!0;case"boolean":return p?!1:u!==null?!u.acceptsBooleans:(o=o.toLowerCase().slice(0,5),o!=="data-"&&o!=="aria-");default:return!1}}function w(o,a,u,p){if(a===null||typeof a>"u"||y(o,a,u,p))return!0;if(p)return!1;if(u!==null)switch(u.type){case 3:return!a;case 4:return a===!1;case 5:return isNaN(a);case 6:return isNaN(a)||1>a}return!1}function _(o,a,u,p,v,b,k){this.acceptsBooleans=a===2||a===3||a===4,this.attributeName=p,this.attributeNamespace=v,this.mustUseProperty=u,this.propertyName=o,this.type=a,this.sanitizeURL=b,this.removeEmptyString=k}var C={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(o){C[o]=new _(o,0,!1,o,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(o){var a=o[0];C[a]=new _(a,1,!1,o[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(o){C[o]=new _(o,2,!1,o.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(o){C[o]=new _(o,2,!1,o,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(o){C[o]=new _(o,3,!1,o.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(o){C[o]=new _(o,3,!0,o,null,!1,!1)}),["capture","download"].forEach(function(o){C[o]=new _(o,4,!1,o,null,!1,!1)}),["cols","rows","size","span"].forEach(function(o){C[o]=new _(o,6,!1,o,null,!1,!1)}),["rowSpan","start"].forEach(function(o){C[o]=new _(o,5,!1,o.toLowerCase(),null,!1,!1)});var I=/[\-:]([a-z])/g;function E(o){return o[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(o){var a=o.replace(I,E);C[a]=new _(a,1,!1,o,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(o){var a=o.replace(I,E);C[a]=new _(a,1,!1,o,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(o){var a=o.replace(I,E);C[a]=new _(a,1,!1,o,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(o){C[o]=new _(o,1,!1,o.toLowerCase(),null,!1,!1)}),C.xlinkHref=new _("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(o){C[o]=new _(o,1,!1,o.toLowerCase(),null,!0,!0)});function S(o,a,u,p){var v=C.hasOwnProperty(a)?C[a]:null;(v!==null?v.type!==0:p||!(2<a.length)||a[0]!=="o"&&a[0]!=="O"||a[1]!=="n"&&a[1]!=="N")&&(w(a,u,v,p)&&(u=null),p||v===null?g(a)&&(u===null?o.removeAttribute(a):o.setAttribute(a,""+u)):v.mustUseProperty?o[v.propertyName]=u===null?v.type===3?!1:"":u:(a=v.attributeName,p=v.attributeNamespace,u===null?o.removeAttribute(a):(v=v.type,u=v===3||v===4&&u===!0?"":""+u,p?o.setAttributeNS(p,a,u):o.setAttribute(a,u))))}var L=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,A=Symbol.for("react.element"),R=Symbol.for("react.portal"),U=Symbol.for("react.fragment"),X=Symbol.for("react.strict_mode"),H=Symbol.for("react.profiler"),re=Symbol.for("react.provider"),de=Symbol.for("react.context"),te=Symbol.for("react.forward_ref"),Q=Symbol.for("react.suspense"),ee=Symbol.for("react.suspense_list"),K=Symbol.for("react.memo"),oe=Symbol.for("react.lazy"),ie=Symbol.for("react.offscreen"),W=Symbol.iterator;function ce(o){return o===null||typeof o!="object"?null:(o=W&&o[W]||o["@@iterator"],typeof o=="function"?o:null)}var le=Object.assign,O;function J(o){if(O===void 0)try{throw Error()}catch(u){var a=u.stack.trim().match(/\n( *(at )?)/);O=a&&a[1]||""}return`
35
+ `+O+o}var fe=!1;function we(o,a){if(!o||fe)return"";fe=!0;var u=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(a)if(a=function(){throw Error()},Object.defineProperty(a.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(a,[])}catch(q){var p=q}Reflect.construct(o,[],a)}else{try{a.call()}catch(q){p=q}o.call(a.prototype)}else{try{throw Error()}catch(q){p=q}o()}}catch(q){if(q&&p&&typeof q.stack=="string"){for(var v=q.stack.split(`
36
+ `),b=p.stack.split(`
37
+ `),k=v.length-1,T=b.length-1;1<=k&&0<=T&&v[k]!==b[T];)T--;for(;1<=k&&0<=T;k--,T--)if(v[k]!==b[T]){if(k!==1||T!==1)do if(k--,T--,0>T||v[k]!==b[T]){var M=`
38
+ `+v[k].replace(" at new "," at ");return o.displayName&&M.includes("<anonymous>")&&(M=M.replace("<anonymous>",o.displayName)),M}while(1<=k&&0<=T);break}}}finally{fe=!1,Error.prepareStackTrace=u}return(o=o?o.displayName||o.name:"")?J(o):""}function be(o){switch(o.tag){case 5:return J(o.type);case 16:return J("Lazy");case 13:return J("Suspense");case 19:return J("SuspenseList");case 0:case 2:case 15:return o=we(o.type,!1),o;case 11:return o=we(o.type.render,!1),o;case 1:return o=we(o.type,!0),o;default:return""}}function Pe(o){if(o==null)return null;if(typeof o=="function")return o.displayName||o.name||null;if(typeof o=="string")return o;switch(o){case U:return"Fragment";case R:return"Portal";case H:return"Profiler";case X:return"StrictMode";case Q:return"Suspense";case ee:return"SuspenseList"}if(typeof o=="object")switch(o.$$typeof){case de:return(o.displayName||"Context")+".Consumer";case re:return(o._context.displayName||"Context")+".Provider";case te:var a=o.render;return o=o.displayName,o||(o=a.displayName||a.name||"",o=o!==""?"ForwardRef("+o+")":"ForwardRef"),o;case K:return a=o.displayName||null,a!==null?a:Pe(o.type)||"Memo";case oe:a=o._payload,o=o._init;try{return Pe(o(a))}catch{}}return null}function Ne(o){var a=o.type;switch(o.tag){case 24:return"Cache";case 9:return(a.displayName||"Context")+".Consumer";case 10:return(a._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return o=a.render,o=o.displayName||o.name||"",a.displayName||(o!==""?"ForwardRef("+o+")":"ForwardRef");case 7:return"Fragment";case 5:return a;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Pe(a);case 8:return a===X?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof a=="function")return a.displayName||a.name||null;if(typeof a=="string")return a}return null}function he(o){switch(typeof o){case"boolean":case"number":case"string":case"undefined":return o;case"object":return o;default:return""}}function Te(o){var a=o.type;return(o=o.nodeName)&&o.toLowerCase()==="input"&&(a==="checkbox"||a==="radio")}function Qe(o){var a=Te(o)?"checked":"value",u=Object.getOwnPropertyDescriptor(o.constructor.prototype,a),p=""+o[a];if(!o.hasOwnProperty(a)&&typeof u<"u"&&typeof u.get=="function"&&typeof u.set=="function"){var v=u.get,b=u.set;return Object.defineProperty(o,a,{configurable:!0,get:function(){return v.call(this)},set:function(k){p=""+k,b.call(this,k)}}),Object.defineProperty(o,a,{enumerable:u.enumerable}),{getValue:function(){return p},setValue:function(k){p=""+k},stopTracking:function(){o._valueTracker=null,delete o[a]}}}}function pt(o){o._valueTracker||(o._valueTracker=Qe(o))}function mt(o){if(!o)return!1;var a=o._valueTracker;if(!a)return!0;var u=a.getValue(),p="";return o&&(p=Te(o)?o.checked?"true":"false":o.value),o=p,o!==u?(a.setValue(o),!0):!1}function ct(o){if(o=o||(typeof document<"u"?document:void 0),typeof o>"u")return null;try{return o.activeElement||o.body}catch{return o.body}}function mn(o,a){var u=a.checked;return le({},a,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:u??o._wrapperState.initialChecked})}function Je(o,a){var u=a.defaultValue==null?"":a.defaultValue,p=a.checked!=null?a.checked:a.defaultChecked;u=he(a.value!=null?a.value:u),o._wrapperState={initialChecked:p,initialValue:u,controlled:a.type==="checkbox"||a.type==="radio"?a.checked!=null:a.value!=null}}function Oi(o,a){a=a.checked,a!=null&&S(o,"checked",a,!1)}function Mr(o,a){Oi(o,a);var u=he(a.value),p=a.type;if(u!=null)p==="number"?(u===0&&o.value===""||o.value!=u)&&(o.value=""+u):o.value!==""+u&&(o.value=""+u);else if(p==="submit"||p==="reset"){o.removeAttribute("value");return}a.hasOwnProperty("value")?$t(o,a.type,u):a.hasOwnProperty("defaultValue")&&$t(o,a.type,he(a.defaultValue)),a.checked==null&&a.defaultChecked!=null&&(o.defaultChecked=!!a.defaultChecked)}function vs(o,a,u){if(a.hasOwnProperty("value")||a.hasOwnProperty("defaultValue")){var p=a.type;if(!(p!=="submit"&&p!=="reset"||a.value!==void 0&&a.value!==null))return;a=""+o._wrapperState.initialValue,u||a===o.value||(o.value=a),o.defaultValue=a}u=o.name,u!==""&&(o.name=""),o.defaultChecked=!!o._wrapperState.initialChecked,u!==""&&(o.name=u)}function $t(o,a,u){(a!=="number"||ct(o.ownerDocument)!==o)&&(u==null?o.defaultValue=""+o._wrapperState.initialValue:o.defaultValue!==""+u&&(o.defaultValue=""+u))}var $i=Array.isArray;function oi(o,a,u,p){if(o=o.options,a){a={};for(var v=0;v<u.length;v++)a["$"+u[v]]=!0;for(u=0;u<o.length;u++)v=a.hasOwnProperty("$"+o[u].value),o[u].selected!==v&&(o[u].selected=v),v&&p&&(o[u].defaultSelected=!0)}else{for(u=""+he(u),a=null,v=0;v<o.length;v++){if(o[v].value===u){o[v].selected=!0,p&&(o[v].defaultSelected=!0);return}a!==null||o[v].disabled||(a=o[v])}a!==null&&(a.selected=!0)}}function Fe(o,a){if(a.dangerouslySetInnerHTML!=null)throw Error(n(91));return le({},a,{value:void 0,defaultValue:void 0,children:""+o._wrapperState.initialValue})}function er(o,a){var u=a.value;if(u==null){if(u=a.children,a=a.defaultValue,u!=null){if(a!=null)throw Error(n(92));if($i(u)){if(1<u.length)throw Error(n(93));u=u[0]}a=u}a==null&&(a=""),u=a}o._wrapperState={initialValue:he(u)}}function si(o,a){var u=he(a.value),p=he(a.defaultValue);u!=null&&(u=""+u,u!==o.value&&(o.value=u),a.defaultValue==null&&o.defaultValue!==u&&(o.defaultValue=u)),p!=null&&(o.defaultValue=""+p)}function Bi(o){var a=o.textContent;a===o._wrapperState.initialValue&&a!==""&&a!==null&&(o.value=a)}function tr(o){switch(o){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function Or(o,a){return o==null||o==="http://www.w3.org/1999/xhtml"?tr(a):o==="http://www.w3.org/2000/svg"&&a==="foreignObject"?"http://www.w3.org/1999/xhtml":o}var nr,ji=(function(o){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(a,u,p,v){MSApp.execUnsafeLocalFunction(function(){return o(a,u,p,v)})}:o})(function(o,a){if(o.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in o)o.innerHTML=a;else{for(nr=nr||document.createElement("div"),nr.innerHTML="<svg>"+a.valueOf().toString()+"</svg>",a=nr.firstChild;o.firstChild;)o.removeChild(o.firstChild);for(;a.firstChild;)o.appendChild(a.firstChild)}});function gn(o,a){if(a){var u=o.firstChild;if(u&&u===o.lastChild&&u.nodeType===3){u.nodeValue=a;return}}o.textContent=a}var ai={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},mr=["Webkit","ms","Moz","O"];Object.keys(ai).forEach(function(o){mr.forEach(function(a){a=a+o.charAt(0).toUpperCase()+o.substring(1),ai[a]=ai[o]})});function da(o,a,u){return a==null||typeof a=="boolean"||a===""?"":u||typeof a!="number"||a===0||ai.hasOwnProperty(o)&&ai[o]?(""+a).trim():a+"px"}function ys(o,a){o=o.style;for(var u in a)if(a.hasOwnProperty(u)){var p=u.indexOf("--")===0,v=da(u,a[u],p);u==="float"&&(u="cssFloat"),p?o.setProperty(u,v):o[u]=v}}var fa=le({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Vi(o,a){if(a){if(fa[o]&&(a.children!=null||a.dangerouslySetInnerHTML!=null))throw Error(n(137,o));if(a.dangerouslySetInnerHTML!=null){if(a.children!=null)throw Error(n(60));if(typeof a.dangerouslySetInnerHTML!="object"||!("__html"in a.dangerouslySetInnerHTML))throw Error(n(61))}if(a.style!=null&&typeof a.style!="object")throw Error(n(62))}}function _o(o,a){if(o.indexOf("-")===-1)return typeof a.is=="string";switch(o){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 $r=null;function $n(o){return o=o.target||o.srcElement||window,o.correspondingUseElement&&(o=o.correspondingUseElement),o.nodeType===3?o.parentNode:o}var ws=null,li=null,Br=null;function zt(o){if(o=cc(o)){if(typeof ws!="function")throw Error(n(280));var a=o.stateNode;a&&(a=ed(a),ws(o.stateNode,o.type,a))}}function je(o){li?Br?Br.push(o):Br=[o]:li=o}function ft(){if(li){var o=li,a=Br;if(Br=li=null,zt(o),a)for(o=0;o<a.length;o++)zt(a[o])}}function Nt(o,a){return o(a)}function sn(){}var ci=!1;function Ft(o,a,u){if(ci)return o(a,u);ci=!0;try{return Nt(o,a,u)}finally{ci=!1,(li!==null||Br!==null)&&(sn(),ft())}}function Ht(o,a){var u=o.stateNode;if(u===null)return null;var p=ed(u);if(p===null)return null;u=p[a];e:switch(a){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(p=!p.disabled)||(o=o.type,p=!(o==="button"||o==="input"||o==="select"||o==="textarea")),o=!p;break e;default:o=!1}if(o)return null;if(u&&typeof u!="function")throw Error(n(231,a,typeof u));return u}var Bn=!1;if(c)try{var Wt={};Object.defineProperty(Wt,"passive",{get:function(){Bn=!0}}),window.addEventListener("test",Wt,Wt),window.removeEventListener("test",Wt,Wt)}catch{Bn=!1}function kn(o,a,u,p,v,b,k,T,M){var q=Array.prototype.slice.call(arguments,3);try{a.apply(u,q)}catch(ae){this.onError(ae)}}var jn=!1,Yt=null,Ui=!1,gr=null,kh={onError:function(o){jn=!0,Yt=o}};function et(o,a,u,p,v,b,k,T,M){jn=!1,Yt=null,kn.apply(kh,arguments)}function dt(o,a,u,p,v,b,k,T,M){if(et.apply(this,arguments),jn){if(jn){var q=Yt;jn=!1,Yt=null}else throw Error(n(198));Ui||(Ui=!0,gr=q)}}function vn(o){var a=o,u=o;if(o.alternate)for(;a.return;)a=a.return;else{o=a;do a=o,(a.flags&4098)!==0&&(u=a.return),o=a.return;while(o)}return a.tag===3?u:null}function vr(o){if(o.tag===13){var a=o.memoizedState;if(a===null&&(o=o.alternate,o!==null&&(a=o.memoizedState)),a!==null)return a.dehydrated}return null}function Tu(o){if(vn(o)!==o)throw Error(n(188))}function Sh(o){var a=o.alternate;if(!a){if(a=vn(o),a===null)throw Error(n(188));return a!==o?null:o}for(var u=o,p=a;;){var v=u.return;if(v===null)break;var b=v.alternate;if(b===null){if(p=v.return,p!==null){u=p;continue}break}if(v.child===b.child){for(b=v.child;b;){if(b===u)return Tu(v),o;if(b===p)return Tu(v),a;b=b.sibling}throw Error(n(188))}if(u.return!==p.return)u=v,p=b;else{for(var k=!1,T=v.child;T;){if(T===u){k=!0,u=v,p=b;break}if(T===p){k=!0,p=v,u=b;break}T=T.sibling}if(!k){for(T=b.child;T;){if(T===u){k=!0,u=b,p=v;break}if(T===p){k=!0,p=b,u=v;break}T=T.sibling}if(!k)throw Error(n(189))}}if(u.alternate!==p)throw Error(n(190))}if(u.tag!==3)throw Error(n(188));return u.stateNode.current===u?o:a}function ko(o){return o=Sh(o),o!==null?Ul(o):null}function Ul(o){if(o.tag===5||o.tag===6)return o;for(o=o.child;o!==null;){var a=Ul(o);if(a!==null)return a;o=o.sibling}return null}var Ru=t.unstable_scheduleCallback,Nu=t.unstable_cancelCallback,Gt=t.unstable_shouldYield,ha=t.unstable_requestPaint,tt=t.unstable_now,rr=t.unstable_getCurrentPriorityLevel,zi=t.unstable_ImmediatePriority,zl=t.unstable_UserBlockingPriority,jr=t.unstable_NormalPriority,bs=t.unstable_LowPriority,xs=t.unstable_IdlePriority,So=null,yr=null;function Fu(o){if(yr&&typeof yr.onCommitFiberRoot=="function")try{yr.onCommitFiberRoot(So,o,void 0,(o.current.flags&128)===128)}catch{}}var Sn=Math.clz32?Math.clz32:Hl,Mu=Math.log,Co=Math.LN2;function Hl(o){return o>>>=0,o===0?32:31-(Mu(o)/Co|0)|0}var yn=64,ui=4194304;function Eo(o){switch(o&-o){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: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 o&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return o&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return o}}function pa(o,a){var u=o.pendingLanes;if(u===0)return 0;var p=0,v=o.suspendedLanes,b=o.pingedLanes,k=u&268435455;if(k!==0){var T=k&~v;T!==0?p=Eo(T):(b&=k,b!==0&&(p=Eo(b)))}else k=u&~v,k!==0?p=Eo(k):b!==0&&(p=Eo(b));if(p===0)return 0;if(a!==0&&a!==p&&(a&v)===0&&(v=p&-p,b=a&-a,v>=b||v===16&&(b&4194240)!==0))return a;if((p&4)!==0&&(p|=u&16),a=o.entangledLanes,a!==0)for(o=o.entanglements,a&=p;0<a;)u=31-Sn(a),v=1<<u,p|=o[u],a&=~v;return p}function ma(o,a){switch(o){case 1:case 2:case 4:return a+250;case 8:case 16:case 32:case 64: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 a+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Ch(o,a){for(var u=o.suspendedLanes,p=o.pingedLanes,v=o.expirationTimes,b=o.pendingLanes;0<b;){var k=31-Sn(b),T=1<<k,M=v[k];M===-1?((T&u)===0||(T&p)!==0)&&(v[k]=ma(T,a)):M<=a&&(o.expiredLanes|=T),b&=~T}}function ga(o){return o=o.pendingLanes&-1073741825,o!==0?o:o&1073741824?1073741824:0}function Ou(){var o=yn;return yn<<=1,(yn&4194240)===0&&(yn=64),o}function wr(o){for(var a=[],u=0;31>u;u++)a.push(o);return a}function di(o,a,u){o.pendingLanes|=a,a!==536870912&&(o.suspendedLanes=0,o.pingedLanes=0),o=o.eventTimes,a=31-Sn(a),o[a]=u}function _s(o,a){var u=o.pendingLanes&~a;o.pendingLanes=a,o.suspendedLanes=0,o.pingedLanes=0,o.expiredLanes&=a,o.mutableReadLanes&=a,o.entangledLanes&=a,a=o.entanglements;var p=o.eventTimes;for(o=o.expirationTimes;0<u;){var v=31-Sn(u),b=1<<v;a[v]=0,p[v]=-1,o[v]=-1,u&=~b}}function va(o,a){var u=o.entangledLanes|=a;for(o=o.entanglements;u;){var p=31-Sn(u),v=1<<p;v&a|o[p]&a&&(o[p]|=a),u&=~v}}var nt=0;function ks(o){return o&=-o,1<o?4<o?(o&268435455)!==0?16:536870912:4:1}var ya,wa,Wl,$u,Bu,Gl=!1,Ss=[],Vr=null,fi=null,hi=null,Cs=new Map,Es=new Map,pi=[],Hi="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 submit".split(" ");function ql(o,a){switch(o){case"focusin":case"focusout":Vr=null;break;case"dragenter":case"dragleave":fi=null;break;case"mouseover":case"mouseout":hi=null;break;case"pointerover":case"pointerout":Cs.delete(a.pointerId);break;case"gotpointercapture":case"lostpointercapture":Es.delete(a.pointerId)}}function Is(o,a,u,p,v,b){return o===null||o.nativeEvent!==b?(o={blockedOn:a,domEventName:u,eventSystemFlags:p,nativeEvent:b,targetContainers:[v]},a!==null&&(a=cc(a),a!==null&&wa(a)),o):(o.eventSystemFlags|=p,a=o.targetContainers,v!==null&&a.indexOf(v)===-1&&a.push(v),o)}function Eh(o,a,u,p,v){switch(a){case"focusin":return Vr=Is(Vr,o,a,u,p,v),!0;case"dragenter":return fi=Is(fi,o,a,u,p,v),!0;case"mouseover":return hi=Is(hi,o,a,u,p,v),!0;case"pointerover":var b=v.pointerId;return Cs.set(b,Is(Cs.get(b)||null,o,a,u,p,v)),!0;case"gotpointercapture":return b=v.pointerId,Es.set(b,Is(Es.get(b)||null,o,a,u,p,v)),!0}return!1}function ju(o){var a=Ts(o.target);if(a!==null){var u=vn(a);if(u!==null){if(a=u.tag,a===13){if(a=vr(u),a!==null){o.blockedOn=a,Bu(o.priority,function(){Wl(u)});return}}else if(a===3&&u.stateNode.current.memoizedState.isDehydrated){o.blockedOn=u.tag===3?u.stateNode.containerInfo:null;return}}}o.blockedOn=null}function ba(o){if(o.blockedOn!==null)return!1;for(var a=o.targetContainers;0<a.length;){var u=_a(o.domEventName,o.eventSystemFlags,a[0],o.nativeEvent);if(u===null){u=o.nativeEvent;var p=new u.constructor(u.type,u);$r=p,u.target.dispatchEvent(p),$r=null}else return a=cc(u),a!==null&&wa(a),o.blockedOn=u,!1;a.shift()}return!0}function Vu(o,a,u){ba(o)&&u.delete(a)}function xa(){Gl=!1,Vr!==null&&ba(Vr)&&(Vr=null),fi!==null&&ba(fi)&&(fi=null),hi!==null&&ba(hi)&&(hi=null),Cs.forEach(Vu),Es.forEach(Vu)}function Ps(o,a){o.blockedOn===a&&(o.blockedOn=null,Gl||(Gl=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,xa)))}function Io(o){function a(v){return Ps(v,o)}if(0<Ss.length){Ps(Ss[0],o);for(var u=1;u<Ss.length;u++){var p=Ss[u];p.blockedOn===o&&(p.blockedOn=null)}}for(Vr!==null&&Ps(Vr,o),fi!==null&&Ps(fi,o),hi!==null&&Ps(hi,o),Cs.forEach(a),Es.forEach(a),u=0;u<pi.length;u++)p=pi[u],p.blockedOn===o&&(p.blockedOn=null);for(;0<pi.length&&(u=pi[0],u.blockedOn===null);)ju(u),u.blockedOn===null&&pi.shift()}var Po=L.ReactCurrentBatchConfig,ir=!0;function Uu(o,a,u,p){var v=nt,b=Po.transition;Po.transition=null;try{nt=1,Kl(o,a,u,p)}finally{nt=v,Po.transition=b}}function mi(o,a,u,p){var v=nt,b=Po.transition;Po.transition=null;try{nt=4,Kl(o,a,u,p)}finally{nt=v,Po.transition=b}}function Kl(o,a,u,p){if(ir){var v=_a(o,a,u,p);if(v===null)Oh(o,a,p,gi,u),ql(o,p);else if(Eh(v,o,a,u,p))p.stopPropagation();else if(ql(o,p),a&4&&-1<Hi.indexOf(o)){for(;v!==null;){var b=cc(v);if(b!==null&&ya(b),b=_a(o,a,u,p),b===null&&Oh(o,a,p,gi,u),b===v)break;v=b}v!==null&&p.stopPropagation()}else Oh(o,a,p,null,u)}}var gi=null;function _a(o,a,u,p){if(gi=null,o=$n(p),o=Ts(o),o!==null)if(a=vn(o),a===null)o=null;else if(u=a.tag,u===13){if(o=vr(a),o!==null)return o;o=null}else if(u===3){if(a.stateNode.current.memoizedState.isDehydrated)return a.tag===3?a.stateNode.containerInfo:null;o=null}else a!==o&&(o=null);return gi=o,null}function zu(o){switch(o){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"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 1;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"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(rr()){case zi:return 1;case zl:return 4;case jr:case bs:return 16;case xs:return 536870912;default:return 16}default:return 16}}var vi=null,Xl=null,ka=null;function Lo(){if(ka)return ka;var o,a=Xl,u=a.length,p,v="value"in vi?vi.value:vi.textContent,b=v.length;for(o=0;o<u&&a[o]===v[o];o++);var k=u-o;for(p=1;p<=k&&a[u-p]===v[b-p];p++);return ka=v.slice(o,1<p?1-p:void 0)}function Do(o){var a=o.keyCode;return"charCode"in o?(o=o.charCode,o===0&&a===13&&(o=13)):o=a,o===10&&(o=13),32<=o||o===13?o:0}function Sa(){return!0}function Ls(){return!1}function Cn(o){function a(u,p,v,b,k){this._reactName=u,this._targetInst=v,this.type=p,this.nativeEvent=b,this.target=k,this.currentTarget=null;for(var T in o)o.hasOwnProperty(T)&&(u=o[T],this[T]=u?u(b):b[T]);return this.isDefaultPrevented=(b.defaultPrevented!=null?b.defaultPrevented:b.returnValue===!1)?Sa:Ls,this.isPropagationStopped=Ls,this}return le(a.prototype,{preventDefault:function(){this.defaultPrevented=!0;var u=this.nativeEvent;u&&(u.preventDefault?u.preventDefault():typeof u.returnValue!="unknown"&&(u.returnValue=!1),this.isDefaultPrevented=Sa)},stopPropagation:function(){var u=this.nativeEvent;u&&(u.stopPropagation?u.stopPropagation():typeof u.cancelBubble!="unknown"&&(u.cancelBubble=!0),this.isPropagationStopped=Sa)},persist:function(){},isPersistent:Sa}),a}var Ao={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(o){return o.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Ql=Cn(Ao),Ds=le({},Ao,{view:0,detail:0}),Ih=Cn(Ds),To,Yl,Ro,As=le({},Ds,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:ht,button:0,buttons:0,relatedTarget:function(o){return o.relatedTarget===void 0?o.fromElement===o.srcElement?o.toElement:o.fromElement:o.relatedTarget},movementX:function(o){return"movementX"in o?o.movementX:(o!==Ro&&(Ro&&o.type==="mousemove"?(To=o.screenX-Ro.screenX,Yl=o.screenY-Ro.screenY):Yl=To=0,Ro=o),To)},movementY:function(o){return"movementY"in o?o.movementY:Yl}}),Jl=Cn(As),Hu=le({},As,{dataTransfer:0}),Wu=Cn(Hu),Gu=le({},Ds,{relatedTarget:0}),Ca=Cn(Gu),N=le({},Ao,{animationName:0,elapsedTime:0,pseudoElement:0}),ne=Cn(N),xe=le({},Ao,{clipboardData:function(o){return"clipboardData"in o?o.clipboardData:window.clipboardData}}),ve=Cn(xe),_e=le({},Ao,{data:0}),Se=Cn(_e),We={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Oe={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"},Ve={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function ut(o){var a=this.nativeEvent;return a.getModifierState?a.getModifierState(o):(o=Ve[o])?!!a[o]:!1}function ht(){return ut}var Pt=le({},Ds,{key:function(o){if(o.key){var a=We[o.key]||o.key;if(a!=="Unidentified")return a}return o.type==="keypress"?(o=Do(o),o===13?"Enter":String.fromCharCode(o)):o.type==="keydown"||o.type==="keyup"?Oe[o.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:ht,charCode:function(o){return o.type==="keypress"?Do(o):0},keyCode:function(o){return o.type==="keydown"||o.type==="keyup"?o.keyCode:0},which:function(o){return o.type==="keypress"?Do(o):o.type==="keydown"||o.type==="keyup"?o.keyCode:0}}),wt=Cn(Pt),br=le({},As,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),_t=Cn(br),Jt=le({},Ds,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:ht}),rt=Cn(Jt),Ur=le({},Ao,{propertyName:0,elapsedTime:0,pseudoElement:0}),zr=Cn(Ur),Ea=le({},As,{deltaX:function(o){return"deltaX"in o?o.deltaX:"wheelDeltaX"in o?-o.wheelDeltaX:0},deltaY:function(o){return"deltaY"in o?o.deltaY:"wheelDeltaY"in o?-o.wheelDeltaY:"wheelDelta"in o?-o.wheelDelta:0},deltaZ:0,deltaMode:0}),gt=Cn(Ea),yi=[9,13,27,32],Zl=c&&"CompositionEvent"in window,ec=null;c&&"documentMode"in document&&(ec=document.documentMode);var mS=c&&"TextEvent"in window&&!ec,Z0=c&&(!Zl||ec&&8<ec&&11>=ec),e1=" ",t1=!1;function n1(o,a){switch(o){case"keyup":return yi.indexOf(a.keyCode)!==-1;case"keydown":return a.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function r1(o){return o=o.detail,typeof o=="object"&&"data"in o?o.data:null}var Ia=!1;function gS(o,a){switch(o){case"compositionend":return r1(a);case"keypress":return a.which!==32?null:(t1=!0,e1);case"textInput":return o=a.data,o===e1&&t1?null:o;default:return null}}function vS(o,a){if(Ia)return o==="compositionend"||!Zl&&n1(o,a)?(o=Lo(),ka=Xl=vi=null,Ia=!1,o):null;switch(o){case"paste":return null;case"keypress":if(!(a.ctrlKey||a.altKey||a.metaKey)||a.ctrlKey&&a.altKey){if(a.char&&1<a.char.length)return a.char;if(a.which)return String.fromCharCode(a.which)}return null;case"compositionend":return Z0&&a.locale!=="ko"?null:a.data;default:return null}}var yS={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 i1(o){var a=o&&o.nodeName&&o.nodeName.toLowerCase();return a==="input"?!!yS[o.type]:a==="textarea"}function o1(o,a,u,p){je(p),a=Yu(a,"onChange"),0<a.length&&(u=new Ql("onChange","change",null,u,p),o.push({event:u,listeners:a}))}var tc=null,nc=null;function wS(o){k1(o,0)}function qu(o){var a=Ta(o);if(mt(a))return o}function bS(o,a){if(o==="change")return a}var s1=!1;if(c){var Ph;if(c){var Lh="oninput"in document;if(!Lh){var a1=document.createElement("div");a1.setAttribute("oninput","return;"),Lh=typeof a1.oninput=="function"}Ph=Lh}else Ph=!1;s1=Ph&&(!document.documentMode||9<document.documentMode)}function l1(){tc&&(tc.detachEvent("onpropertychange",c1),nc=tc=null)}function c1(o){if(o.propertyName==="value"&&qu(nc)){var a=[];o1(a,nc,o,$n(o)),Ft(wS,a)}}function xS(o,a,u){o==="focusin"?(l1(),tc=a,nc=u,tc.attachEvent("onpropertychange",c1)):o==="focusout"&&l1()}function _S(o){if(o==="selectionchange"||o==="keyup"||o==="keydown")return qu(nc)}function kS(o,a){if(o==="click")return qu(a)}function SS(o,a){if(o==="input"||o==="change")return qu(a)}function CS(o,a){return o===a&&(o!==0||1/o===1/a)||o!==o&&a!==a}var Hr=typeof Object.is=="function"?Object.is:CS;function rc(o,a){if(Hr(o,a))return!0;if(typeof o!="object"||o===null||typeof a!="object"||a===null)return!1;var u=Object.keys(o),p=Object.keys(a);if(u.length!==p.length)return!1;for(p=0;p<u.length;p++){var v=u[p];if(!d.call(a,v)||!Hr(o[v],a[v]))return!1}return!0}function u1(o){for(;o&&o.firstChild;)o=o.firstChild;return o}function d1(o,a){var u=u1(o);o=0;for(var p;u;){if(u.nodeType===3){if(p=o+u.textContent.length,o<=a&&p>=a)return{node:u,offset:a-o};o=p}e:{for(;u;){if(u.nextSibling){u=u.nextSibling;break e}u=u.parentNode}u=void 0}u=u1(u)}}function f1(o,a){return o&&a?o===a?!0:o&&o.nodeType===3?!1:a&&a.nodeType===3?f1(o,a.parentNode):"contains"in o?o.contains(a):o.compareDocumentPosition?!!(o.compareDocumentPosition(a)&16):!1:!1}function h1(){for(var o=window,a=ct();a instanceof o.HTMLIFrameElement;){try{var u=typeof a.contentWindow.location.href=="string"}catch{u=!1}if(u)o=a.contentWindow;else break;a=ct(o.document)}return a}function Dh(o){var a=o&&o.nodeName&&o.nodeName.toLowerCase();return a&&(a==="input"&&(o.type==="text"||o.type==="search"||o.type==="tel"||o.type==="url"||o.type==="password")||a==="textarea"||o.contentEditable==="true")}function ES(o){var a=h1(),u=o.focusedElem,p=o.selectionRange;if(a!==u&&u&&u.ownerDocument&&f1(u.ownerDocument.documentElement,u)){if(p!==null&&Dh(u)){if(a=p.start,o=p.end,o===void 0&&(o=a),"selectionStart"in u)u.selectionStart=a,u.selectionEnd=Math.min(o,u.value.length);else if(o=(a=u.ownerDocument||document)&&a.defaultView||window,o.getSelection){o=o.getSelection();var v=u.textContent.length,b=Math.min(p.start,v);p=p.end===void 0?b:Math.min(p.end,v),!o.extend&&b>p&&(v=p,p=b,b=v),v=d1(u,b);var k=d1(u,p);v&&k&&(o.rangeCount!==1||o.anchorNode!==v.node||o.anchorOffset!==v.offset||o.focusNode!==k.node||o.focusOffset!==k.offset)&&(a=a.createRange(),a.setStart(v.node,v.offset),o.removeAllRanges(),b>p?(o.addRange(a),o.extend(k.node,k.offset)):(a.setEnd(k.node,k.offset),o.addRange(a)))}}for(a=[],o=u;o=o.parentNode;)o.nodeType===1&&a.push({element:o,left:o.scrollLeft,top:o.scrollTop});for(typeof u.focus=="function"&&u.focus(),u=0;u<a.length;u++)o=a[u],o.element.scrollLeft=o.left,o.element.scrollTop=o.top}}var IS=c&&"documentMode"in document&&11>=document.documentMode,Pa=null,Ah=null,ic=null,Th=!1;function p1(o,a,u){var p=u.window===u?u.document:u.nodeType===9?u:u.ownerDocument;Th||Pa==null||Pa!==ct(p)||(p=Pa,"selectionStart"in p&&Dh(p)?p={start:p.selectionStart,end:p.selectionEnd}:(p=(p.ownerDocument&&p.ownerDocument.defaultView||window).getSelection(),p={anchorNode:p.anchorNode,anchorOffset:p.anchorOffset,focusNode:p.focusNode,focusOffset:p.focusOffset}),ic&&rc(ic,p)||(ic=p,p=Yu(Ah,"onSelect"),0<p.length&&(a=new Ql("onSelect","select",null,a,u),o.push({event:a,listeners:p}),a.target=Pa)))}function Ku(o,a){var u={};return u[o.toLowerCase()]=a.toLowerCase(),u["Webkit"+o]="webkit"+a,u["Moz"+o]="moz"+a,u}var La={animationend:Ku("Animation","AnimationEnd"),animationiteration:Ku("Animation","AnimationIteration"),animationstart:Ku("Animation","AnimationStart"),transitionend:Ku("Transition","TransitionEnd")},Rh={},m1={};c&&(m1=document.createElement("div").style,"AnimationEvent"in window||(delete La.animationend.animation,delete La.animationiteration.animation,delete La.animationstart.animation),"TransitionEvent"in window||delete La.transitionend.transition);function Xu(o){if(Rh[o])return Rh[o];if(!La[o])return o;var a=La[o],u;for(u in a)if(a.hasOwnProperty(u)&&u in m1)return Rh[o]=a[u];return o}var g1=Xu("animationend"),v1=Xu("animationiteration"),y1=Xu("animationstart"),w1=Xu("transitionend"),b1=new Map,x1="abort auxClick 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(" ");function No(o,a){b1.set(o,a),s(a,[o])}for(var Nh=0;Nh<x1.length;Nh++){var Fh=x1[Nh],PS=Fh.toLowerCase(),LS=Fh[0].toUpperCase()+Fh.slice(1);No(PS,"on"+LS)}No(g1,"onAnimationEnd"),No(v1,"onAnimationIteration"),No(y1,"onAnimationStart"),No("dblclick","onDoubleClick"),No("focusin","onFocus"),No("focusout","onBlur"),No(w1,"onTransitionEnd"),l("onMouseEnter",["mouseout","mouseover"]),l("onMouseLeave",["mouseout","mouseover"]),l("onPointerEnter",["pointerout","pointerover"]),l("onPointerLeave",["pointerout","pointerover"]),s("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),s("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),s("onBeforeInput",["compositionend","keypress","textInput","paste"]),s("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),s("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),s("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var oc="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(" "),DS=new Set("cancel close invalid load scroll toggle".split(" ").concat(oc));function _1(o,a,u){var p=o.type||"unknown-event";o.currentTarget=u,dt(p,a,void 0,o),o.currentTarget=null}function k1(o,a){a=(a&4)!==0;for(var u=0;u<o.length;u++){var p=o[u],v=p.event;p=p.listeners;e:{var b=void 0;if(a)for(var k=p.length-1;0<=k;k--){var T=p[k],M=T.instance,q=T.currentTarget;if(T=T.listener,M!==b&&v.isPropagationStopped())break e;_1(v,T,q),b=M}else for(k=0;k<p.length;k++){if(T=p[k],M=T.instance,q=T.currentTarget,T=T.listener,M!==b&&v.isPropagationStopped())break e;_1(v,T,q),b=M}}}if(Ui)throw o=gr,Ui=!1,gr=null,o}function kt(o,a){var u=a[zh];u===void 0&&(u=a[zh]=new Set);var p=o+"__bubble";u.has(p)||(S1(a,o,2,!1),u.add(p))}function Mh(o,a,u){var p=0;a&&(p|=4),S1(u,o,p,a)}var Qu="_reactListening"+Math.random().toString(36).slice(2);function sc(o){if(!o[Qu]){o[Qu]=!0,r.forEach(function(u){u!=="selectionchange"&&(DS.has(u)||Mh(u,!1,o),Mh(u,!0,o))});var a=o.nodeType===9?o:o.ownerDocument;a===null||a[Qu]||(a[Qu]=!0,Mh("selectionchange",!1,a))}}function S1(o,a,u,p){switch(zu(a)){case 1:var v=Uu;break;case 4:v=mi;break;default:v=Kl}u=v.bind(null,a,u,o),v=void 0,!Bn||a!=="touchstart"&&a!=="touchmove"&&a!=="wheel"||(v=!0),p?v!==void 0?o.addEventListener(a,u,{capture:!0,passive:v}):o.addEventListener(a,u,!0):v!==void 0?o.addEventListener(a,u,{passive:v}):o.addEventListener(a,u,!1)}function Oh(o,a,u,p,v){var b=p;if((a&1)===0&&(a&2)===0&&p!==null)e:for(;;){if(p===null)return;var k=p.tag;if(k===3||k===4){var T=p.stateNode.containerInfo;if(T===v||T.nodeType===8&&T.parentNode===v)break;if(k===4)for(k=p.return;k!==null;){var M=k.tag;if((M===3||M===4)&&(M=k.stateNode.containerInfo,M===v||M.nodeType===8&&M.parentNode===v))return;k=k.return}for(;T!==null;){if(k=Ts(T),k===null)return;if(M=k.tag,M===5||M===6){p=b=k;continue e}T=T.parentNode}}p=p.return}Ft(function(){var q=b,ae=$n(u),ue=[];e:{var se=b1.get(o);if(se!==void 0){var ke=Ql,Ie=o;switch(o){case"keypress":if(Do(u)===0)break e;case"keydown":case"keyup":ke=wt;break;case"focusin":Ie="focus",ke=Ca;break;case"focusout":Ie="blur",ke=Ca;break;case"beforeblur":case"afterblur":ke=Ca;break;case"click":if(u.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":ke=Jl;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":ke=Wu;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":ke=rt;break;case g1:case v1:case y1:ke=ne;break;case w1:ke=zr;break;case"scroll":ke=Ih;break;case"wheel":ke=gt;break;case"copy":case"cut":case"paste":ke=ve;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":ke=_t}var Le=(a&4)!==0,Bt=!Le&&o==="scroll",z=Le?se!==null?se+"Capture":null:se;Le=[];for(var j=q,G;j!==null;){G=j;var me=G.stateNode;if(G.tag===5&&me!==null&&(G=me,z!==null&&(me=Ht(j,z),me!=null&&Le.push(ac(j,me,G)))),Bt)break;j=j.return}0<Le.length&&(se=new ke(se,Ie,null,u,ae),ue.push({event:se,listeners:Le}))}}if((a&7)===0){e:{if(se=o==="mouseover"||o==="pointerover",ke=o==="mouseout"||o==="pointerout",se&&u!==$r&&(Ie=u.relatedTarget||u.fromElement)&&(Ts(Ie)||Ie[Wi]))break e;if((ke||se)&&(se=ae.window===ae?ae:(se=ae.ownerDocument)?se.defaultView||se.parentWindow:window,ke?(Ie=u.relatedTarget||u.toElement,ke=q,Ie=Ie?Ts(Ie):null,Ie!==null&&(Bt=vn(Ie),Ie!==Bt||Ie.tag!==5&&Ie.tag!==6)&&(Ie=null)):(ke=null,Ie=q),ke!==Ie)){if(Le=Jl,me="onMouseLeave",z="onMouseEnter",j="mouse",(o==="pointerout"||o==="pointerover")&&(Le=_t,me="onPointerLeave",z="onPointerEnter",j="pointer"),Bt=ke==null?se:Ta(ke),G=Ie==null?se:Ta(Ie),se=new Le(me,j+"leave",ke,u,ae),se.target=Bt,se.relatedTarget=G,me=null,Ts(ae)===q&&(Le=new Le(z,j+"enter",Ie,u,ae),Le.target=G,Le.relatedTarget=Bt,me=Le),Bt=me,ke&&Ie)t:{for(Le=ke,z=Ie,j=0,G=Le;G;G=Da(G))j++;for(G=0,me=z;me;me=Da(me))G++;for(;0<j-G;)Le=Da(Le),j--;for(;0<G-j;)z=Da(z),G--;for(;j--;){if(Le===z||z!==null&&Le===z.alternate)break t;Le=Da(Le),z=Da(z)}Le=null}else Le=null;ke!==null&&C1(ue,se,ke,Le,!1),Ie!==null&&Bt!==null&&C1(ue,Bt,Ie,Le,!0)}}e:{if(se=q?Ta(q):window,ke=se.nodeName&&se.nodeName.toLowerCase(),ke==="select"||ke==="input"&&se.type==="file")var Ae=bS;else if(i1(se))if(s1)Ae=SS;else{Ae=_S;var $e=xS}else(ke=se.nodeName)&&ke.toLowerCase()==="input"&&(se.type==="checkbox"||se.type==="radio")&&(Ae=kS);if(Ae&&(Ae=Ae(o,q))){o1(ue,Ae,u,ae);break e}$e&&$e(o,se,q),o==="focusout"&&($e=se._wrapperState)&&$e.controlled&&se.type==="number"&&$t(se,"number",se.value)}switch($e=q?Ta(q):window,o){case"focusin":(i1($e)||$e.contentEditable==="true")&&(Pa=$e,Ah=q,ic=null);break;case"focusout":ic=Ah=Pa=null;break;case"mousedown":Th=!0;break;case"contextmenu":case"mouseup":case"dragend":Th=!1,p1(ue,u,ae);break;case"selectionchange":if(IS)break;case"keydown":case"keyup":p1(ue,u,ae)}var Be;if(Zl)e:{switch(o){case"compositionstart":var Ue="onCompositionStart";break e;case"compositionend":Ue="onCompositionEnd";break e;case"compositionupdate":Ue="onCompositionUpdate";break e}Ue=void 0}else Ia?n1(o,u)&&(Ue="onCompositionEnd"):o==="keydown"&&u.keyCode===229&&(Ue="onCompositionStart");Ue&&(Z0&&u.locale!=="ko"&&(Ia||Ue!=="onCompositionStart"?Ue==="onCompositionEnd"&&Ia&&(Be=Lo()):(vi=ae,Xl="value"in vi?vi.value:vi.textContent,Ia=!0)),$e=Yu(q,Ue),0<$e.length&&(Ue=new Se(Ue,o,null,u,ae),ue.push({event:Ue,listeners:$e}),Be?Ue.data=Be:(Be=r1(u),Be!==null&&(Ue.data=Be)))),(Be=mS?gS(o,u):vS(o,u))&&(q=Yu(q,"onBeforeInput"),0<q.length&&(ae=new Se("onBeforeInput","beforeinput",null,u,ae),ue.push({event:ae,listeners:q}),ae.data=Be))}k1(ue,a)})}function ac(o,a,u){return{instance:o,listener:a,currentTarget:u}}function Yu(o,a){for(var u=a+"Capture",p=[];o!==null;){var v=o,b=v.stateNode;v.tag===5&&b!==null&&(v=b,b=Ht(o,u),b!=null&&p.unshift(ac(o,b,v)),b=Ht(o,a),b!=null&&p.push(ac(o,b,v))),o=o.return}return p}function Da(o){if(o===null)return null;do o=o.return;while(o&&o.tag!==5);return o||null}function C1(o,a,u,p,v){for(var b=a._reactName,k=[];u!==null&&u!==p;){var T=u,M=T.alternate,q=T.stateNode;if(M!==null&&M===p)break;T.tag===5&&q!==null&&(T=q,v?(M=Ht(u,b),M!=null&&k.unshift(ac(u,M,T))):v||(M=Ht(u,b),M!=null&&k.push(ac(u,M,T)))),u=u.return}k.length!==0&&o.push({event:a,listeners:k})}var AS=/\r\n?/g,TS=/\u0000|\uFFFD/g;function E1(o){return(typeof o=="string"?o:""+o).replace(AS,`
39
+ `).replace(TS,"")}function Ju(o,a,u){if(a=E1(a),E1(o)!==a&&u)throw Error(n(425))}function Zu(){}var $h=null,Bh=null;function jh(o,a){return o==="textarea"||o==="noscript"||typeof a.children=="string"||typeof a.children=="number"||typeof a.dangerouslySetInnerHTML=="object"&&a.dangerouslySetInnerHTML!==null&&a.dangerouslySetInnerHTML.__html!=null}var Vh=typeof setTimeout=="function"?setTimeout:void 0,RS=typeof clearTimeout=="function"?clearTimeout:void 0,I1=typeof Promise=="function"?Promise:void 0,NS=typeof queueMicrotask=="function"?queueMicrotask:typeof I1<"u"?function(o){return I1.resolve(null).then(o).catch(FS)}:Vh;function FS(o){setTimeout(function(){throw o})}function Uh(o,a){var u=a,p=0;do{var v=u.nextSibling;if(o.removeChild(u),v&&v.nodeType===8)if(u=v.data,u==="/$"){if(p===0){o.removeChild(v),Io(a);return}p--}else u!=="$"&&u!=="$?"&&u!=="$!"||p++;u=v}while(u);Io(a)}function Fo(o){for(;o!=null;o=o.nextSibling){var a=o.nodeType;if(a===1||a===3)break;if(a===8){if(a=o.data,a==="$"||a==="$!"||a==="$?")break;if(a==="/$")return null}}return o}function P1(o){o=o.previousSibling;for(var a=0;o;){if(o.nodeType===8){var u=o.data;if(u==="$"||u==="$!"||u==="$?"){if(a===0)return o;a--}else u==="/$"&&a++}o=o.previousSibling}return null}var Aa=Math.random().toString(36).slice(2),wi="__reactFiber$"+Aa,lc="__reactProps$"+Aa,Wi="__reactContainer$"+Aa,zh="__reactEvents$"+Aa,MS="__reactListeners$"+Aa,OS="__reactHandles$"+Aa;function Ts(o){var a=o[wi];if(a)return a;for(var u=o.parentNode;u;){if(a=u[Wi]||u[wi]){if(u=a.alternate,a.child!==null||u!==null&&u.child!==null)for(o=P1(o);o!==null;){if(u=o[wi])return u;o=P1(o)}return a}o=u,u=o.parentNode}return null}function cc(o){return o=o[wi]||o[Wi],!o||o.tag!==5&&o.tag!==6&&o.tag!==13&&o.tag!==3?null:o}function Ta(o){if(o.tag===5||o.tag===6)return o.stateNode;throw Error(n(33))}function ed(o){return o[lc]||null}var Hh=[],Ra=-1;function Mo(o){return{current:o}}function St(o){0>Ra||(o.current=Hh[Ra],Hh[Ra]=null,Ra--)}function bt(o,a){Ra++,Hh[Ra]=o.current,o.current=a}var Oo={},En=Mo(Oo),Vn=Mo(!1),Rs=Oo;function Na(o,a){var u=o.type.contextTypes;if(!u)return Oo;var p=o.stateNode;if(p&&p.__reactInternalMemoizedUnmaskedChildContext===a)return p.__reactInternalMemoizedMaskedChildContext;var v={},b;for(b in u)v[b]=a[b];return p&&(o=o.stateNode,o.__reactInternalMemoizedUnmaskedChildContext=a,o.__reactInternalMemoizedMaskedChildContext=v),v}function Un(o){return o=o.childContextTypes,o!=null}function td(){St(Vn),St(En)}function L1(o,a,u){if(En.current!==Oo)throw Error(n(168));bt(En,a),bt(Vn,u)}function D1(o,a,u){var p=o.stateNode;if(a=a.childContextTypes,typeof p.getChildContext!="function")return u;p=p.getChildContext();for(var v in p)if(!(v in a))throw Error(n(108,Ne(o)||"Unknown",v));return le({},u,p)}function nd(o){return o=(o=o.stateNode)&&o.__reactInternalMemoizedMergedChildContext||Oo,Rs=En.current,bt(En,o),bt(Vn,Vn.current),!0}function A1(o,a,u){var p=o.stateNode;if(!p)throw Error(n(169));u?(o=D1(o,a,Rs),p.__reactInternalMemoizedMergedChildContext=o,St(Vn),St(En),bt(En,o)):St(Vn),bt(Vn,u)}var Gi=null,rd=!1,Wh=!1;function T1(o){Gi===null?Gi=[o]:Gi.push(o)}function $S(o){rd=!0,T1(o)}function $o(){if(!Wh&&Gi!==null){Wh=!0;var o=0,a=nt;try{var u=Gi;for(nt=1;o<u.length;o++){var p=u[o];do p=p(!0);while(p!==null)}Gi=null,rd=!1}catch(v){throw Gi!==null&&(Gi=Gi.slice(o+1)),Ru(zi,$o),v}finally{nt=a,Wh=!1}}return null}var Fa=[],Ma=0,id=null,od=0,xr=[],_r=0,Ns=null,qi=1,Ki="";function Fs(o,a){Fa[Ma++]=od,Fa[Ma++]=id,id=o,od=a}function R1(o,a,u){xr[_r++]=qi,xr[_r++]=Ki,xr[_r++]=Ns,Ns=o;var p=qi;o=Ki;var v=32-Sn(p)-1;p&=~(1<<v),u+=1;var b=32-Sn(a)+v;if(30<b){var k=v-v%5;b=(p&(1<<k)-1).toString(32),p>>=k,v-=k,qi=1<<32-Sn(a)+v|u<<v|p,Ki=b+o}else qi=1<<b|u<<v|p,Ki=o}function Gh(o){o.return!==null&&(Fs(o,1),R1(o,1,0))}function qh(o){for(;o===id;)id=Fa[--Ma],Fa[Ma]=null,od=Fa[--Ma],Fa[Ma]=null;for(;o===Ns;)Ns=xr[--_r],xr[_r]=null,Ki=xr[--_r],xr[_r]=null,qi=xr[--_r],xr[_r]=null}var or=null,sr=null,Lt=!1,Wr=null;function N1(o,a){var u=Er(5,null,null,0);u.elementType="DELETED",u.stateNode=a,u.return=o,a=o.deletions,a===null?(o.deletions=[u],o.flags|=16):a.push(u)}function F1(o,a){switch(o.tag){case 5:var u=o.type;return a=a.nodeType!==1||u.toLowerCase()!==a.nodeName.toLowerCase()?null:a,a!==null?(o.stateNode=a,or=o,sr=Fo(a.firstChild),!0):!1;case 6:return a=o.pendingProps===""||a.nodeType!==3?null:a,a!==null?(o.stateNode=a,or=o,sr=null,!0):!1;case 13:return a=a.nodeType!==8?null:a,a!==null?(u=Ns!==null?{id:qi,overflow:Ki}:null,o.memoizedState={dehydrated:a,treeContext:u,retryLane:1073741824},u=Er(18,null,null,0),u.stateNode=a,u.return=o,o.child=u,or=o,sr=null,!0):!1;default:return!1}}function Kh(o){return(o.mode&1)!==0&&(o.flags&128)===0}function Xh(o){if(Lt){var a=sr;if(a){var u=a;if(!F1(o,a)){if(Kh(o))throw Error(n(418));a=Fo(u.nextSibling);var p=or;a&&F1(o,a)?N1(p,u):(o.flags=o.flags&-4097|2,Lt=!1,or=o)}}else{if(Kh(o))throw Error(n(418));o.flags=o.flags&-4097|2,Lt=!1,or=o}}}function M1(o){for(o=o.return;o!==null&&o.tag!==5&&o.tag!==3&&o.tag!==13;)o=o.return;or=o}function sd(o){if(o!==or)return!1;if(!Lt)return M1(o),Lt=!0,!1;var a;if((a=o.tag!==3)&&!(a=o.tag!==5)&&(a=o.type,a=a!=="head"&&a!=="body"&&!jh(o.type,o.memoizedProps)),a&&(a=sr)){if(Kh(o))throw O1(),Error(n(418));for(;a;)N1(o,a),a=Fo(a.nextSibling)}if(M1(o),o.tag===13){if(o=o.memoizedState,o=o!==null?o.dehydrated:null,!o)throw Error(n(317));e:{for(o=o.nextSibling,a=0;o;){if(o.nodeType===8){var u=o.data;if(u==="/$"){if(a===0){sr=Fo(o.nextSibling);break e}a--}else u!=="$"&&u!=="$!"&&u!=="$?"||a++}o=o.nextSibling}sr=null}}else sr=or?Fo(o.stateNode.nextSibling):null;return!0}function O1(){for(var o=sr;o;)o=Fo(o.nextSibling)}function Oa(){sr=or=null,Lt=!1}function Qh(o){Wr===null?Wr=[o]:Wr.push(o)}var BS=L.ReactCurrentBatchConfig;function uc(o,a,u){if(o=u.ref,o!==null&&typeof o!="function"&&typeof o!="object"){if(u._owner){if(u=u._owner,u){if(u.tag!==1)throw Error(n(309));var p=u.stateNode}if(!p)throw Error(n(147,o));var v=p,b=""+o;return a!==null&&a.ref!==null&&typeof a.ref=="function"&&a.ref._stringRef===b?a.ref:(a=function(k){var T=v.refs;k===null?delete T[b]:T[b]=k},a._stringRef=b,a)}if(typeof o!="string")throw Error(n(284));if(!u._owner)throw Error(n(290,o))}return o}function ad(o,a){throw o=Object.prototype.toString.call(a),Error(n(31,o==="[object Object]"?"object with keys {"+Object.keys(a).join(", ")+"}":o))}function $1(o){var a=o._init;return a(o._payload)}function B1(o){function a(z,j){if(o){var G=z.deletions;G===null?(z.deletions=[j],z.flags|=16):G.push(j)}}function u(z,j){if(!o)return null;for(;j!==null;)a(z,j),j=j.sibling;return null}function p(z,j){for(z=new Map;j!==null;)j.key!==null?z.set(j.key,j):z.set(j.index,j),j=j.sibling;return z}function v(z,j){return z=Go(z,j),z.index=0,z.sibling=null,z}function b(z,j,G){return z.index=G,o?(G=z.alternate,G!==null?(G=G.index,G<j?(z.flags|=2,j):G):(z.flags|=2,j)):(z.flags|=1048576,j)}function k(z){return o&&z.alternate===null&&(z.flags|=2),z}function T(z,j,G,me){return j===null||j.tag!==6?(j=Vp(G,z.mode,me),j.return=z,j):(j=v(j,G),j.return=z,j)}function M(z,j,G,me){var Ae=G.type;return Ae===U?ae(z,j,G.props.children,me,G.key):j!==null&&(j.elementType===Ae||typeof Ae=="object"&&Ae!==null&&Ae.$$typeof===oe&&$1(Ae)===j.type)?(me=v(j,G.props),me.ref=uc(z,j,G),me.return=z,me):(me=Ad(G.type,G.key,G.props,null,z.mode,me),me.ref=uc(z,j,G),me.return=z,me)}function q(z,j,G,me){return j===null||j.tag!==4||j.stateNode.containerInfo!==G.containerInfo||j.stateNode.implementation!==G.implementation?(j=Up(G,z.mode,me),j.return=z,j):(j=v(j,G.children||[]),j.return=z,j)}function ae(z,j,G,me,Ae){return j===null||j.tag!==7?(j=zs(G,z.mode,me,Ae),j.return=z,j):(j=v(j,G),j.return=z,j)}function ue(z,j,G){if(typeof j=="string"&&j!==""||typeof j=="number")return j=Vp(""+j,z.mode,G),j.return=z,j;if(typeof j=="object"&&j!==null){switch(j.$$typeof){case A:return G=Ad(j.type,j.key,j.props,null,z.mode,G),G.ref=uc(z,null,j),G.return=z,G;case R:return j=Up(j,z.mode,G),j.return=z,j;case oe:var me=j._init;return ue(z,me(j._payload),G)}if($i(j)||ce(j))return j=zs(j,z.mode,G,null),j.return=z,j;ad(z,j)}return null}function se(z,j,G,me){var Ae=j!==null?j.key:null;if(typeof G=="string"&&G!==""||typeof G=="number")return Ae!==null?null:T(z,j,""+G,me);if(typeof G=="object"&&G!==null){switch(G.$$typeof){case A:return G.key===Ae?M(z,j,G,me):null;case R:return G.key===Ae?q(z,j,G,me):null;case oe:return Ae=G._init,se(z,j,Ae(G._payload),me)}if($i(G)||ce(G))return Ae!==null?null:ae(z,j,G,me,null);ad(z,G)}return null}function ke(z,j,G,me,Ae){if(typeof me=="string"&&me!==""||typeof me=="number")return z=z.get(G)||null,T(j,z,""+me,Ae);if(typeof me=="object"&&me!==null){switch(me.$$typeof){case A:return z=z.get(me.key===null?G:me.key)||null,M(j,z,me,Ae);case R:return z=z.get(me.key===null?G:me.key)||null,q(j,z,me,Ae);case oe:var $e=me._init;return ke(z,j,G,$e(me._payload),Ae)}if($i(me)||ce(me))return z=z.get(G)||null,ae(j,z,me,Ae,null);ad(j,me)}return null}function Ie(z,j,G,me){for(var Ae=null,$e=null,Be=j,Ue=j=0,cn=null;Be!==null&&Ue<G.length;Ue++){Be.index>Ue?(cn=Be,Be=null):cn=Be.sibling;var st=se(z,Be,G[Ue],me);if(st===null){Be===null&&(Be=cn);break}o&&Be&&st.alternate===null&&a(z,Be),j=b(st,j,Ue),$e===null?Ae=st:$e.sibling=st,$e=st,Be=cn}if(Ue===G.length)return u(z,Be),Lt&&Fs(z,Ue),Ae;if(Be===null){for(;Ue<G.length;Ue++)Be=ue(z,G[Ue],me),Be!==null&&(j=b(Be,j,Ue),$e===null?Ae=Be:$e.sibling=Be,$e=Be);return Lt&&Fs(z,Ue),Ae}for(Be=p(z,Be);Ue<G.length;Ue++)cn=ke(Be,z,Ue,G[Ue],me),cn!==null&&(o&&cn.alternate!==null&&Be.delete(cn.key===null?Ue:cn.key),j=b(cn,j,Ue),$e===null?Ae=cn:$e.sibling=cn,$e=cn);return o&&Be.forEach(function(qo){return a(z,qo)}),Lt&&Fs(z,Ue),Ae}function Le(z,j,G,me){var Ae=ce(G);if(typeof Ae!="function")throw Error(n(150));if(G=Ae.call(G),G==null)throw Error(n(151));for(var $e=Ae=null,Be=j,Ue=j=0,cn=null,st=G.next();Be!==null&&!st.done;Ue++,st=G.next()){Be.index>Ue?(cn=Be,Be=null):cn=Be.sibling;var qo=se(z,Be,st.value,me);if(qo===null){Be===null&&(Be=cn);break}o&&Be&&qo.alternate===null&&a(z,Be),j=b(qo,j,Ue),$e===null?Ae=qo:$e.sibling=qo,$e=qo,Be=cn}if(st.done)return u(z,Be),Lt&&Fs(z,Ue),Ae;if(Be===null){for(;!st.done;Ue++,st=G.next())st=ue(z,st.value,me),st!==null&&(j=b(st,j,Ue),$e===null?Ae=st:$e.sibling=st,$e=st);return Lt&&Fs(z,Ue),Ae}for(Be=p(z,Be);!st.done;Ue++,st=G.next())st=ke(Be,z,Ue,st.value,me),st!==null&&(o&&st.alternate!==null&&Be.delete(st.key===null?Ue:st.key),j=b(st,j,Ue),$e===null?Ae=st:$e.sibling=st,$e=st);return o&&Be.forEach(function(yC){return a(z,yC)}),Lt&&Fs(z,Ue),Ae}function Bt(z,j,G,me){if(typeof G=="object"&&G!==null&&G.type===U&&G.key===null&&(G=G.props.children),typeof G=="object"&&G!==null){switch(G.$$typeof){case A:e:{for(var Ae=G.key,$e=j;$e!==null;){if($e.key===Ae){if(Ae=G.type,Ae===U){if($e.tag===7){u(z,$e.sibling),j=v($e,G.props.children),j.return=z,z=j;break e}}else if($e.elementType===Ae||typeof Ae=="object"&&Ae!==null&&Ae.$$typeof===oe&&$1(Ae)===$e.type){u(z,$e.sibling),j=v($e,G.props),j.ref=uc(z,$e,G),j.return=z,z=j;break e}u(z,$e);break}else a(z,$e);$e=$e.sibling}G.type===U?(j=zs(G.props.children,z.mode,me,G.key),j.return=z,z=j):(me=Ad(G.type,G.key,G.props,null,z.mode,me),me.ref=uc(z,j,G),me.return=z,z=me)}return k(z);case R:e:{for($e=G.key;j!==null;){if(j.key===$e)if(j.tag===4&&j.stateNode.containerInfo===G.containerInfo&&j.stateNode.implementation===G.implementation){u(z,j.sibling),j=v(j,G.children||[]),j.return=z,z=j;break e}else{u(z,j);break}else a(z,j);j=j.sibling}j=Up(G,z.mode,me),j.return=z,z=j}return k(z);case oe:return $e=G._init,Bt(z,j,$e(G._payload),me)}if($i(G))return Ie(z,j,G,me);if(ce(G))return Le(z,j,G,me);ad(z,G)}return typeof G=="string"&&G!==""||typeof G=="number"?(G=""+G,j!==null&&j.tag===6?(u(z,j.sibling),j=v(j,G),j.return=z,z=j):(u(z,j),j=Vp(G,z.mode,me),j.return=z,z=j),k(z)):u(z,j)}return Bt}var $a=B1(!0),j1=B1(!1),ld=Mo(null),cd=null,Ba=null,Yh=null;function Jh(){Yh=Ba=cd=null}function Zh(o){var a=ld.current;St(ld),o._currentValue=a}function ep(o,a,u){for(;o!==null;){var p=o.alternate;if((o.childLanes&a)!==a?(o.childLanes|=a,p!==null&&(p.childLanes|=a)):p!==null&&(p.childLanes&a)!==a&&(p.childLanes|=a),o===u)break;o=o.return}}function ja(o,a){cd=o,Yh=Ba=null,o=o.dependencies,o!==null&&o.firstContext!==null&&((o.lanes&a)!==0&&(zn=!0),o.firstContext=null)}function kr(o){var a=o._currentValue;if(Yh!==o)if(o={context:o,memoizedValue:a,next:null},Ba===null){if(cd===null)throw Error(n(308));Ba=o,cd.dependencies={lanes:0,firstContext:o}}else Ba=Ba.next=o;return a}var Ms=null;function tp(o){Ms===null?Ms=[o]:Ms.push(o)}function V1(o,a,u,p){var v=a.interleaved;return v===null?(u.next=u,tp(a)):(u.next=v.next,v.next=u),a.interleaved=u,Xi(o,p)}function Xi(o,a){o.lanes|=a;var u=o.alternate;for(u!==null&&(u.lanes|=a),u=o,o=o.return;o!==null;)o.childLanes|=a,u=o.alternate,u!==null&&(u.childLanes|=a),u=o,o=o.return;return u.tag===3?u.stateNode:null}var Bo=!1;function np(o){o.updateQueue={baseState:o.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function U1(o,a){o=o.updateQueue,a.updateQueue===o&&(a.updateQueue={baseState:o.baseState,firstBaseUpdate:o.firstBaseUpdate,lastBaseUpdate:o.lastBaseUpdate,shared:o.shared,effects:o.effects})}function Qi(o,a){return{eventTime:o,lane:a,tag:0,payload:null,callback:null,next:null}}function jo(o,a,u){var p=o.updateQueue;if(p===null)return null;if(p=p.shared,(it&2)!==0){var v=p.pending;return v===null?a.next=a:(a.next=v.next,v.next=a),p.pending=a,Xi(o,u)}return v=p.interleaved,v===null?(a.next=a,tp(p)):(a.next=v.next,v.next=a),p.interleaved=a,Xi(o,u)}function ud(o,a,u){if(a=a.updateQueue,a!==null&&(a=a.shared,(u&4194240)!==0)){var p=a.lanes;p&=o.pendingLanes,u|=p,a.lanes=u,va(o,u)}}function z1(o,a){var u=o.updateQueue,p=o.alternate;if(p!==null&&(p=p.updateQueue,u===p)){var v=null,b=null;if(u=u.firstBaseUpdate,u!==null){do{var k={eventTime:u.eventTime,lane:u.lane,tag:u.tag,payload:u.payload,callback:u.callback,next:null};b===null?v=b=k:b=b.next=k,u=u.next}while(u!==null);b===null?v=b=a:b=b.next=a}else v=b=a;u={baseState:p.baseState,firstBaseUpdate:v,lastBaseUpdate:b,shared:p.shared,effects:p.effects},o.updateQueue=u;return}o=u.lastBaseUpdate,o===null?u.firstBaseUpdate=a:o.next=a,u.lastBaseUpdate=a}function dd(o,a,u,p){var v=o.updateQueue;Bo=!1;var b=v.firstBaseUpdate,k=v.lastBaseUpdate,T=v.shared.pending;if(T!==null){v.shared.pending=null;var M=T,q=M.next;M.next=null,k===null?b=q:k.next=q,k=M;var ae=o.alternate;ae!==null&&(ae=ae.updateQueue,T=ae.lastBaseUpdate,T!==k&&(T===null?ae.firstBaseUpdate=q:T.next=q,ae.lastBaseUpdate=M))}if(b!==null){var ue=v.baseState;k=0,ae=q=M=null,T=b;do{var se=T.lane,ke=T.eventTime;if((p&se)===se){ae!==null&&(ae=ae.next={eventTime:ke,lane:0,tag:T.tag,payload:T.payload,callback:T.callback,next:null});e:{var Ie=o,Le=T;switch(se=a,ke=u,Le.tag){case 1:if(Ie=Le.payload,typeof Ie=="function"){ue=Ie.call(ke,ue,se);break e}ue=Ie;break e;case 3:Ie.flags=Ie.flags&-65537|128;case 0:if(Ie=Le.payload,se=typeof Ie=="function"?Ie.call(ke,ue,se):Ie,se==null)break e;ue=le({},ue,se);break e;case 2:Bo=!0}}T.callback!==null&&T.lane!==0&&(o.flags|=64,se=v.effects,se===null?v.effects=[T]:se.push(T))}else ke={eventTime:ke,lane:se,tag:T.tag,payload:T.payload,callback:T.callback,next:null},ae===null?(q=ae=ke,M=ue):ae=ae.next=ke,k|=se;if(T=T.next,T===null){if(T=v.shared.pending,T===null)break;se=T,T=se.next,se.next=null,v.lastBaseUpdate=se,v.shared.pending=null}}while(!0);if(ae===null&&(M=ue),v.baseState=M,v.firstBaseUpdate=q,v.lastBaseUpdate=ae,a=v.shared.interleaved,a!==null){v=a;do k|=v.lane,v=v.next;while(v!==a)}else b===null&&(v.shared.lanes=0);Bs|=k,o.lanes=k,o.memoizedState=ue}}function H1(o,a,u){if(o=a.effects,a.effects=null,o!==null)for(a=0;a<o.length;a++){var p=o[a],v=p.callback;if(v!==null){if(p.callback=null,p=u,typeof v!="function")throw Error(n(191,v));v.call(p)}}}var dc={},bi=Mo(dc),fc=Mo(dc),hc=Mo(dc);function Os(o){if(o===dc)throw Error(n(174));return o}function rp(o,a){switch(bt(hc,a),bt(fc,o),bt(bi,dc),o=a.nodeType,o){case 9:case 11:a=(a=a.documentElement)?a.namespaceURI:Or(null,"");break;default:o=o===8?a.parentNode:a,a=o.namespaceURI||null,o=o.tagName,a=Or(a,o)}St(bi),bt(bi,a)}function Va(){St(bi),St(fc),St(hc)}function W1(o){Os(hc.current);var a=Os(bi.current),u=Or(a,o.type);a!==u&&(bt(fc,o),bt(bi,u))}function ip(o){fc.current===o&&(St(bi),St(fc))}var At=Mo(0);function fd(o){for(var a=o;a!==null;){if(a.tag===13){var u=a.memoizedState;if(u!==null&&(u=u.dehydrated,u===null||u.data==="$?"||u.data==="$!"))return a}else if(a.tag===19&&a.memoizedProps.revealOrder!==void 0){if((a.flags&128)!==0)return a}else if(a.child!==null){a.child.return=a,a=a.child;continue}if(a===o)break;for(;a.sibling===null;){if(a.return===null||a.return===o)return null;a=a.return}a.sibling.return=a.return,a=a.sibling}return null}var op=[];function sp(){for(var o=0;o<op.length;o++)op[o]._workInProgressVersionPrimary=null;op.length=0}var hd=L.ReactCurrentDispatcher,ap=L.ReactCurrentBatchConfig,$s=0,Tt=null,Zt=null,an=null,pd=!1,pc=!1,mc=0,jS=0;function In(){throw Error(n(321))}function lp(o,a){if(a===null)return!1;for(var u=0;u<a.length&&u<o.length;u++)if(!Hr(o[u],a[u]))return!1;return!0}function cp(o,a,u,p,v,b){if($s=b,Tt=a,a.memoizedState=null,a.updateQueue=null,a.lanes=0,hd.current=o===null||o.memoizedState===null?HS:WS,o=u(p,v),pc){b=0;do{if(pc=!1,mc=0,25<=b)throw Error(n(301));b+=1,an=Zt=null,a.updateQueue=null,hd.current=GS,o=u(p,v)}while(pc)}if(hd.current=vd,a=Zt!==null&&Zt.next!==null,$s=0,an=Zt=Tt=null,pd=!1,a)throw Error(n(300));return o}function up(){var o=mc!==0;return mc=0,o}function xi(){var o={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return an===null?Tt.memoizedState=an=o:an=an.next=o,an}function Sr(){if(Zt===null){var o=Tt.alternate;o=o!==null?o.memoizedState:null}else o=Zt.next;var a=an===null?Tt.memoizedState:an.next;if(a!==null)an=a,Zt=o;else{if(o===null)throw Error(n(310));Zt=o,o={memoizedState:Zt.memoizedState,baseState:Zt.baseState,baseQueue:Zt.baseQueue,queue:Zt.queue,next:null},an===null?Tt.memoizedState=an=o:an=an.next=o}return an}function gc(o,a){return typeof a=="function"?a(o):a}function dp(o){var a=Sr(),u=a.queue;if(u===null)throw Error(n(311));u.lastRenderedReducer=o;var p=Zt,v=p.baseQueue,b=u.pending;if(b!==null){if(v!==null){var k=v.next;v.next=b.next,b.next=k}p.baseQueue=v=b,u.pending=null}if(v!==null){b=v.next,p=p.baseState;var T=k=null,M=null,q=b;do{var ae=q.lane;if(($s&ae)===ae)M!==null&&(M=M.next={lane:0,action:q.action,hasEagerState:q.hasEagerState,eagerState:q.eagerState,next:null}),p=q.hasEagerState?q.eagerState:o(p,q.action);else{var ue={lane:ae,action:q.action,hasEagerState:q.hasEagerState,eagerState:q.eagerState,next:null};M===null?(T=M=ue,k=p):M=M.next=ue,Tt.lanes|=ae,Bs|=ae}q=q.next}while(q!==null&&q!==b);M===null?k=p:M.next=T,Hr(p,a.memoizedState)||(zn=!0),a.memoizedState=p,a.baseState=k,a.baseQueue=M,u.lastRenderedState=p}if(o=u.interleaved,o!==null){v=o;do b=v.lane,Tt.lanes|=b,Bs|=b,v=v.next;while(v!==o)}else v===null&&(u.lanes=0);return[a.memoizedState,u.dispatch]}function fp(o){var a=Sr(),u=a.queue;if(u===null)throw Error(n(311));u.lastRenderedReducer=o;var p=u.dispatch,v=u.pending,b=a.memoizedState;if(v!==null){u.pending=null;var k=v=v.next;do b=o(b,k.action),k=k.next;while(k!==v);Hr(b,a.memoizedState)||(zn=!0),a.memoizedState=b,a.baseQueue===null&&(a.baseState=b),u.lastRenderedState=b}return[b,p]}function G1(){}function q1(o,a){var u=Tt,p=Sr(),v=a(),b=!Hr(p.memoizedState,v);if(b&&(p.memoizedState=v,zn=!0),p=p.queue,hp(Q1.bind(null,u,p,o),[o]),p.getSnapshot!==a||b||an!==null&&an.memoizedState.tag&1){if(u.flags|=2048,vc(9,X1.bind(null,u,p,v,a),void 0,null),ln===null)throw Error(n(349));($s&30)!==0||K1(u,a,v)}return v}function K1(o,a,u){o.flags|=16384,o={getSnapshot:a,value:u},a=Tt.updateQueue,a===null?(a={lastEffect:null,stores:null},Tt.updateQueue=a,a.stores=[o]):(u=a.stores,u===null?a.stores=[o]:u.push(o))}function X1(o,a,u,p){a.value=u,a.getSnapshot=p,Y1(a)&&J1(o)}function Q1(o,a,u){return u(function(){Y1(a)&&J1(o)})}function Y1(o){var a=o.getSnapshot;o=o.value;try{var u=a();return!Hr(o,u)}catch{return!0}}function J1(o){var a=Xi(o,1);a!==null&&Xr(a,o,1,-1)}function Z1(o){var a=xi();return typeof o=="function"&&(o=o()),a.memoizedState=a.baseState=o,o={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:gc,lastRenderedState:o},a.queue=o,o=o.dispatch=zS.bind(null,Tt,o),[a.memoizedState,o]}function vc(o,a,u,p){return o={tag:o,create:a,destroy:u,deps:p,next:null},a=Tt.updateQueue,a===null?(a={lastEffect:null,stores:null},Tt.updateQueue=a,a.lastEffect=o.next=o):(u=a.lastEffect,u===null?a.lastEffect=o.next=o:(p=u.next,u.next=o,o.next=p,a.lastEffect=o)),o}function e2(){return Sr().memoizedState}function md(o,a,u,p){var v=xi();Tt.flags|=o,v.memoizedState=vc(1|a,u,void 0,p===void 0?null:p)}function gd(o,a,u,p){var v=Sr();p=p===void 0?null:p;var b=void 0;if(Zt!==null){var k=Zt.memoizedState;if(b=k.destroy,p!==null&&lp(p,k.deps)){v.memoizedState=vc(a,u,b,p);return}}Tt.flags|=o,v.memoizedState=vc(1|a,u,b,p)}function t2(o,a){return md(8390656,8,o,a)}function hp(o,a){return gd(2048,8,o,a)}function n2(o,a){return gd(4,2,o,a)}function r2(o,a){return gd(4,4,o,a)}function i2(o,a){if(typeof a=="function")return o=o(),a(o),function(){a(null)};if(a!=null)return o=o(),a.current=o,function(){a.current=null}}function o2(o,a,u){return u=u!=null?u.concat([o]):null,gd(4,4,i2.bind(null,a,o),u)}function pp(){}function s2(o,a){var u=Sr();a=a===void 0?null:a;var p=u.memoizedState;return p!==null&&a!==null&&lp(a,p[1])?p[0]:(u.memoizedState=[o,a],o)}function a2(o,a){var u=Sr();a=a===void 0?null:a;var p=u.memoizedState;return p!==null&&a!==null&&lp(a,p[1])?p[0]:(o=o(),u.memoizedState=[o,a],o)}function l2(o,a,u){return($s&21)===0?(o.baseState&&(o.baseState=!1,zn=!0),o.memoizedState=u):(Hr(u,a)||(u=Ou(),Tt.lanes|=u,Bs|=u,o.baseState=!0),a)}function VS(o,a){var u=nt;nt=u!==0&&4>u?u:4,o(!0);var p=ap.transition;ap.transition={};try{o(!1),a()}finally{nt=u,ap.transition=p}}function c2(){return Sr().memoizedState}function US(o,a,u){var p=Ho(o);if(u={lane:p,action:u,hasEagerState:!1,eagerState:null,next:null},u2(o))d2(a,u);else if(u=V1(o,a,u,p),u!==null){var v=Nn();Xr(u,o,p,v),f2(u,a,p)}}function zS(o,a,u){var p=Ho(o),v={lane:p,action:u,hasEagerState:!1,eagerState:null,next:null};if(u2(o))d2(a,v);else{var b=o.alternate;if(o.lanes===0&&(b===null||b.lanes===0)&&(b=a.lastRenderedReducer,b!==null))try{var k=a.lastRenderedState,T=b(k,u);if(v.hasEagerState=!0,v.eagerState=T,Hr(T,k)){var M=a.interleaved;M===null?(v.next=v,tp(a)):(v.next=M.next,M.next=v),a.interleaved=v;return}}catch{}finally{}u=V1(o,a,v,p),u!==null&&(v=Nn(),Xr(u,o,p,v),f2(u,a,p))}}function u2(o){var a=o.alternate;return o===Tt||a!==null&&a===Tt}function d2(o,a){pc=pd=!0;var u=o.pending;u===null?a.next=a:(a.next=u.next,u.next=a),o.pending=a}function f2(o,a,u){if((u&4194240)!==0){var p=a.lanes;p&=o.pendingLanes,u|=p,a.lanes=u,va(o,u)}}var vd={readContext:kr,useCallback:In,useContext:In,useEffect:In,useImperativeHandle:In,useInsertionEffect:In,useLayoutEffect:In,useMemo:In,useReducer:In,useRef:In,useState:In,useDebugValue:In,useDeferredValue:In,useTransition:In,useMutableSource:In,useSyncExternalStore:In,useId:In,unstable_isNewReconciler:!1},HS={readContext:kr,useCallback:function(o,a){return xi().memoizedState=[o,a===void 0?null:a],o},useContext:kr,useEffect:t2,useImperativeHandle:function(o,a,u){return u=u!=null?u.concat([o]):null,md(4194308,4,i2.bind(null,a,o),u)},useLayoutEffect:function(o,a){return md(4194308,4,o,a)},useInsertionEffect:function(o,a){return md(4,2,o,a)},useMemo:function(o,a){var u=xi();return a=a===void 0?null:a,o=o(),u.memoizedState=[o,a],o},useReducer:function(o,a,u){var p=xi();return a=u!==void 0?u(a):a,p.memoizedState=p.baseState=a,o={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:o,lastRenderedState:a},p.queue=o,o=o.dispatch=US.bind(null,Tt,o),[p.memoizedState,o]},useRef:function(o){var a=xi();return o={current:o},a.memoizedState=o},useState:Z1,useDebugValue:pp,useDeferredValue:function(o){return xi().memoizedState=o},useTransition:function(){var o=Z1(!1),a=o[0];return o=VS.bind(null,o[1]),xi().memoizedState=o,[a,o]},useMutableSource:function(){},useSyncExternalStore:function(o,a,u){var p=Tt,v=xi();if(Lt){if(u===void 0)throw Error(n(407));u=u()}else{if(u=a(),ln===null)throw Error(n(349));($s&30)!==0||K1(p,a,u)}v.memoizedState=u;var b={value:u,getSnapshot:a};return v.queue=b,t2(Q1.bind(null,p,b,o),[o]),p.flags|=2048,vc(9,X1.bind(null,p,b,u,a),void 0,null),u},useId:function(){var o=xi(),a=ln.identifierPrefix;if(Lt){var u=Ki,p=qi;u=(p&~(1<<32-Sn(p)-1)).toString(32)+u,a=":"+a+"R"+u,u=mc++,0<u&&(a+="H"+u.toString(32)),a+=":"}else u=jS++,a=":"+a+"r"+u.toString(32)+":";return o.memoizedState=a},unstable_isNewReconciler:!1},WS={readContext:kr,useCallback:s2,useContext:kr,useEffect:hp,useImperativeHandle:o2,useInsertionEffect:n2,useLayoutEffect:r2,useMemo:a2,useReducer:dp,useRef:e2,useState:function(){return dp(gc)},useDebugValue:pp,useDeferredValue:function(o){var a=Sr();return l2(a,Zt.memoizedState,o)},useTransition:function(){var o=dp(gc)[0],a=Sr().memoizedState;return[o,a]},useMutableSource:G1,useSyncExternalStore:q1,useId:c2,unstable_isNewReconciler:!1},GS={readContext:kr,useCallback:s2,useContext:kr,useEffect:hp,useImperativeHandle:o2,useInsertionEffect:n2,useLayoutEffect:r2,useMemo:a2,useReducer:fp,useRef:e2,useState:function(){return fp(gc)},useDebugValue:pp,useDeferredValue:function(o){var a=Sr();return Zt===null?a.memoizedState=o:l2(a,Zt.memoizedState,o)},useTransition:function(){var o=fp(gc)[0],a=Sr().memoizedState;return[o,a]},useMutableSource:G1,useSyncExternalStore:q1,useId:c2,unstable_isNewReconciler:!1};function Gr(o,a){if(o&&o.defaultProps){a=le({},a),o=o.defaultProps;for(var u in o)a[u]===void 0&&(a[u]=o[u]);return a}return a}function mp(o,a,u,p){a=o.memoizedState,u=u(p,a),u=u==null?a:le({},a,u),o.memoizedState=u,o.lanes===0&&(o.updateQueue.baseState=u)}var yd={isMounted:function(o){return(o=o._reactInternals)?vn(o)===o:!1},enqueueSetState:function(o,a,u){o=o._reactInternals;var p=Nn(),v=Ho(o),b=Qi(p,v);b.payload=a,u!=null&&(b.callback=u),a=jo(o,b,v),a!==null&&(Xr(a,o,v,p),ud(a,o,v))},enqueueReplaceState:function(o,a,u){o=o._reactInternals;var p=Nn(),v=Ho(o),b=Qi(p,v);b.tag=1,b.payload=a,u!=null&&(b.callback=u),a=jo(o,b,v),a!==null&&(Xr(a,o,v,p),ud(a,o,v))},enqueueForceUpdate:function(o,a){o=o._reactInternals;var u=Nn(),p=Ho(o),v=Qi(u,p);v.tag=2,a!=null&&(v.callback=a),a=jo(o,v,p),a!==null&&(Xr(a,o,p,u),ud(a,o,p))}};function h2(o,a,u,p,v,b,k){return o=o.stateNode,typeof o.shouldComponentUpdate=="function"?o.shouldComponentUpdate(p,b,k):a.prototype&&a.prototype.isPureReactComponent?!rc(u,p)||!rc(v,b):!0}function p2(o,a,u){var p=!1,v=Oo,b=a.contextType;return typeof b=="object"&&b!==null?b=kr(b):(v=Un(a)?Rs:En.current,p=a.contextTypes,b=(p=p!=null)?Na(o,v):Oo),a=new a(u,b),o.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=yd,o.stateNode=a,a._reactInternals=o,p&&(o=o.stateNode,o.__reactInternalMemoizedUnmaskedChildContext=v,o.__reactInternalMemoizedMaskedChildContext=b),a}function m2(o,a,u,p){o=a.state,typeof a.componentWillReceiveProps=="function"&&a.componentWillReceiveProps(u,p),typeof a.UNSAFE_componentWillReceiveProps=="function"&&a.UNSAFE_componentWillReceiveProps(u,p),a.state!==o&&yd.enqueueReplaceState(a,a.state,null)}function gp(o,a,u,p){var v=o.stateNode;v.props=u,v.state=o.memoizedState,v.refs={},np(o);var b=a.contextType;typeof b=="object"&&b!==null?v.context=kr(b):(b=Un(a)?Rs:En.current,v.context=Na(o,b)),v.state=o.memoizedState,b=a.getDerivedStateFromProps,typeof b=="function"&&(mp(o,a,b,u),v.state=o.memoizedState),typeof a.getDerivedStateFromProps=="function"||typeof v.getSnapshotBeforeUpdate=="function"||typeof v.UNSAFE_componentWillMount!="function"&&typeof v.componentWillMount!="function"||(a=v.state,typeof v.componentWillMount=="function"&&v.componentWillMount(),typeof v.UNSAFE_componentWillMount=="function"&&v.UNSAFE_componentWillMount(),a!==v.state&&yd.enqueueReplaceState(v,v.state,null),dd(o,u,v,p),v.state=o.memoizedState),typeof v.componentDidMount=="function"&&(o.flags|=4194308)}function Ua(o,a){try{var u="",p=a;do u+=be(p),p=p.return;while(p);var v=u}catch(b){v=`
40
+ Error generating stack: `+b.message+`
41
+ `+b.stack}return{value:o,source:a,stack:v,digest:null}}function vp(o,a,u){return{value:o,source:null,stack:u??null,digest:a??null}}function yp(o,a){try{console.error(a.value)}catch(u){setTimeout(function(){throw u})}}var qS=typeof WeakMap=="function"?WeakMap:Map;function g2(o,a,u){u=Qi(-1,u),u.tag=3,u.payload={element:null};var p=a.value;return u.callback=function(){Cd||(Cd=!0,Rp=p),yp(o,a)},u}function v2(o,a,u){u=Qi(-1,u),u.tag=3;var p=o.type.getDerivedStateFromError;if(typeof p=="function"){var v=a.value;u.payload=function(){return p(v)},u.callback=function(){yp(o,a)}}var b=o.stateNode;return b!==null&&typeof b.componentDidCatch=="function"&&(u.callback=function(){yp(o,a),typeof p!="function"&&(Uo===null?Uo=new Set([this]):Uo.add(this));var k=a.stack;this.componentDidCatch(a.value,{componentStack:k!==null?k:""})}),u}function y2(o,a,u){var p=o.pingCache;if(p===null){p=o.pingCache=new qS;var v=new Set;p.set(a,v)}else v=p.get(a),v===void 0&&(v=new Set,p.set(a,v));v.has(u)||(v.add(u),o=aC.bind(null,o,a,u),a.then(o,o))}function w2(o){do{var a;if((a=o.tag===13)&&(a=o.memoizedState,a=a!==null?a.dehydrated!==null:!0),a)return o;o=o.return}while(o!==null);return null}function b2(o,a,u,p,v){return(o.mode&1)===0?(o===a?o.flags|=65536:(o.flags|=128,u.flags|=131072,u.flags&=-52805,u.tag===1&&(u.alternate===null?u.tag=17:(a=Qi(-1,1),a.tag=2,jo(u,a,1))),u.lanes|=1),o):(o.flags|=65536,o.lanes=v,o)}var KS=L.ReactCurrentOwner,zn=!1;function Rn(o,a,u,p){a.child=o===null?j1(a,null,u,p):$a(a,o.child,u,p)}function x2(o,a,u,p,v){u=u.render;var b=a.ref;return ja(a,v),p=cp(o,a,u,p,b,v),u=up(),o!==null&&!zn?(a.updateQueue=o.updateQueue,a.flags&=-2053,o.lanes&=~v,Yi(o,a,v)):(Lt&&u&&Gh(a),a.flags|=1,Rn(o,a,p,v),a.child)}function _2(o,a,u,p,v){if(o===null){var b=u.type;return typeof b=="function"&&!jp(b)&&b.defaultProps===void 0&&u.compare===null&&u.defaultProps===void 0?(a.tag=15,a.type=b,k2(o,a,b,p,v)):(o=Ad(u.type,null,p,a,a.mode,v),o.ref=a.ref,o.return=a,a.child=o)}if(b=o.child,(o.lanes&v)===0){var k=b.memoizedProps;if(u=u.compare,u=u!==null?u:rc,u(k,p)&&o.ref===a.ref)return Yi(o,a,v)}return a.flags|=1,o=Go(b,p),o.ref=a.ref,o.return=a,a.child=o}function k2(o,a,u,p,v){if(o!==null){var b=o.memoizedProps;if(rc(b,p)&&o.ref===a.ref)if(zn=!1,a.pendingProps=p=b,(o.lanes&v)!==0)(o.flags&131072)!==0&&(zn=!0);else return a.lanes=o.lanes,Yi(o,a,v)}return wp(o,a,u,p,v)}function S2(o,a,u){var p=a.pendingProps,v=p.children,b=o!==null?o.memoizedState:null;if(p.mode==="hidden")if((a.mode&1)===0)a.memoizedState={baseLanes:0,cachePool:null,transitions:null},bt(Ha,ar),ar|=u;else{if((u&1073741824)===0)return o=b!==null?b.baseLanes|u:u,a.lanes=a.childLanes=1073741824,a.memoizedState={baseLanes:o,cachePool:null,transitions:null},a.updateQueue=null,bt(Ha,ar),ar|=o,null;a.memoizedState={baseLanes:0,cachePool:null,transitions:null},p=b!==null?b.baseLanes:u,bt(Ha,ar),ar|=p}else b!==null?(p=b.baseLanes|u,a.memoizedState=null):p=u,bt(Ha,ar),ar|=p;return Rn(o,a,v,u),a.child}function C2(o,a){var u=a.ref;(o===null&&u!==null||o!==null&&o.ref!==u)&&(a.flags|=512,a.flags|=2097152)}function wp(o,a,u,p,v){var b=Un(u)?Rs:En.current;return b=Na(a,b),ja(a,v),u=cp(o,a,u,p,b,v),p=up(),o!==null&&!zn?(a.updateQueue=o.updateQueue,a.flags&=-2053,o.lanes&=~v,Yi(o,a,v)):(Lt&&p&&Gh(a),a.flags|=1,Rn(o,a,u,v),a.child)}function E2(o,a,u,p,v){if(Un(u)){var b=!0;nd(a)}else b=!1;if(ja(a,v),a.stateNode===null)bd(o,a),p2(a,u,p),gp(a,u,p,v),p=!0;else if(o===null){var k=a.stateNode,T=a.memoizedProps;k.props=T;var M=k.context,q=u.contextType;typeof q=="object"&&q!==null?q=kr(q):(q=Un(u)?Rs:En.current,q=Na(a,q));var ae=u.getDerivedStateFromProps,ue=typeof ae=="function"||typeof k.getSnapshotBeforeUpdate=="function";ue||typeof k.UNSAFE_componentWillReceiveProps!="function"&&typeof k.componentWillReceiveProps!="function"||(T!==p||M!==q)&&m2(a,k,p,q),Bo=!1;var se=a.memoizedState;k.state=se,dd(a,p,k,v),M=a.memoizedState,T!==p||se!==M||Vn.current||Bo?(typeof ae=="function"&&(mp(a,u,ae,p),M=a.memoizedState),(T=Bo||h2(a,u,T,p,se,M,q))?(ue||typeof k.UNSAFE_componentWillMount!="function"&&typeof k.componentWillMount!="function"||(typeof k.componentWillMount=="function"&&k.componentWillMount(),typeof k.UNSAFE_componentWillMount=="function"&&k.UNSAFE_componentWillMount()),typeof k.componentDidMount=="function"&&(a.flags|=4194308)):(typeof k.componentDidMount=="function"&&(a.flags|=4194308),a.memoizedProps=p,a.memoizedState=M),k.props=p,k.state=M,k.context=q,p=T):(typeof k.componentDidMount=="function"&&(a.flags|=4194308),p=!1)}else{k=a.stateNode,U1(o,a),T=a.memoizedProps,q=a.type===a.elementType?T:Gr(a.type,T),k.props=q,ue=a.pendingProps,se=k.context,M=u.contextType,typeof M=="object"&&M!==null?M=kr(M):(M=Un(u)?Rs:En.current,M=Na(a,M));var ke=u.getDerivedStateFromProps;(ae=typeof ke=="function"||typeof k.getSnapshotBeforeUpdate=="function")||typeof k.UNSAFE_componentWillReceiveProps!="function"&&typeof k.componentWillReceiveProps!="function"||(T!==ue||se!==M)&&m2(a,k,p,M),Bo=!1,se=a.memoizedState,k.state=se,dd(a,p,k,v);var Ie=a.memoizedState;T!==ue||se!==Ie||Vn.current||Bo?(typeof ke=="function"&&(mp(a,u,ke,p),Ie=a.memoizedState),(q=Bo||h2(a,u,q,p,se,Ie,M)||!1)?(ae||typeof k.UNSAFE_componentWillUpdate!="function"&&typeof k.componentWillUpdate!="function"||(typeof k.componentWillUpdate=="function"&&k.componentWillUpdate(p,Ie,M),typeof k.UNSAFE_componentWillUpdate=="function"&&k.UNSAFE_componentWillUpdate(p,Ie,M)),typeof k.componentDidUpdate=="function"&&(a.flags|=4),typeof k.getSnapshotBeforeUpdate=="function"&&(a.flags|=1024)):(typeof k.componentDidUpdate!="function"||T===o.memoizedProps&&se===o.memoizedState||(a.flags|=4),typeof k.getSnapshotBeforeUpdate!="function"||T===o.memoizedProps&&se===o.memoizedState||(a.flags|=1024),a.memoizedProps=p,a.memoizedState=Ie),k.props=p,k.state=Ie,k.context=M,p=q):(typeof k.componentDidUpdate!="function"||T===o.memoizedProps&&se===o.memoizedState||(a.flags|=4),typeof k.getSnapshotBeforeUpdate!="function"||T===o.memoizedProps&&se===o.memoizedState||(a.flags|=1024),p=!1)}return bp(o,a,u,p,b,v)}function bp(o,a,u,p,v,b){C2(o,a);var k=(a.flags&128)!==0;if(!p&&!k)return v&&A1(a,u,!1),Yi(o,a,b);p=a.stateNode,KS.current=a;var T=k&&typeof u.getDerivedStateFromError!="function"?null:p.render();return a.flags|=1,o!==null&&k?(a.child=$a(a,o.child,null,b),a.child=$a(a,null,T,b)):Rn(o,a,T,b),a.memoizedState=p.state,v&&A1(a,u,!0),a.child}function I2(o){var a=o.stateNode;a.pendingContext?L1(o,a.pendingContext,a.pendingContext!==a.context):a.context&&L1(o,a.context,!1),rp(o,a.containerInfo)}function P2(o,a,u,p,v){return Oa(),Qh(v),a.flags|=256,Rn(o,a,u,p),a.child}var xp={dehydrated:null,treeContext:null,retryLane:0};function _p(o){return{baseLanes:o,cachePool:null,transitions:null}}function L2(o,a,u){var p=a.pendingProps,v=At.current,b=!1,k=(a.flags&128)!==0,T;if((T=k)||(T=o!==null&&o.memoizedState===null?!1:(v&2)!==0),T?(b=!0,a.flags&=-129):(o===null||o.memoizedState!==null)&&(v|=1),bt(At,v&1),o===null)return Xh(a),o=a.memoizedState,o!==null&&(o=o.dehydrated,o!==null)?((a.mode&1)===0?a.lanes=1:o.data==="$!"?a.lanes=8:a.lanes=1073741824,null):(k=p.children,o=p.fallback,b?(p=a.mode,b=a.child,k={mode:"hidden",children:k},(p&1)===0&&b!==null?(b.childLanes=0,b.pendingProps=k):b=Td(k,p,0,null),o=zs(o,p,u,null),b.return=a,o.return=a,b.sibling=o,a.child=b,a.child.memoizedState=_p(u),a.memoizedState=xp,o):kp(a,k));if(v=o.memoizedState,v!==null&&(T=v.dehydrated,T!==null))return XS(o,a,k,p,T,v,u);if(b){b=p.fallback,k=a.mode,v=o.child,T=v.sibling;var M={mode:"hidden",children:p.children};return(k&1)===0&&a.child!==v?(p=a.child,p.childLanes=0,p.pendingProps=M,a.deletions=null):(p=Go(v,M),p.subtreeFlags=v.subtreeFlags&14680064),T!==null?b=Go(T,b):(b=zs(b,k,u,null),b.flags|=2),b.return=a,p.return=a,p.sibling=b,a.child=p,p=b,b=a.child,k=o.child.memoizedState,k=k===null?_p(u):{baseLanes:k.baseLanes|u,cachePool:null,transitions:k.transitions},b.memoizedState=k,b.childLanes=o.childLanes&~u,a.memoizedState=xp,p}return b=o.child,o=b.sibling,p=Go(b,{mode:"visible",children:p.children}),(a.mode&1)===0&&(p.lanes=u),p.return=a,p.sibling=null,o!==null&&(u=a.deletions,u===null?(a.deletions=[o],a.flags|=16):u.push(o)),a.child=p,a.memoizedState=null,p}function kp(o,a){return a=Td({mode:"visible",children:a},o.mode,0,null),a.return=o,o.child=a}function wd(o,a,u,p){return p!==null&&Qh(p),$a(a,o.child,null,u),o=kp(a,a.pendingProps.children),o.flags|=2,a.memoizedState=null,o}function XS(o,a,u,p,v,b,k){if(u)return a.flags&256?(a.flags&=-257,p=vp(Error(n(422))),wd(o,a,k,p)):a.memoizedState!==null?(a.child=o.child,a.flags|=128,null):(b=p.fallback,v=a.mode,p=Td({mode:"visible",children:p.children},v,0,null),b=zs(b,v,k,null),b.flags|=2,p.return=a,b.return=a,p.sibling=b,a.child=p,(a.mode&1)!==0&&$a(a,o.child,null,k),a.child.memoizedState=_p(k),a.memoizedState=xp,b);if((a.mode&1)===0)return wd(o,a,k,null);if(v.data==="$!"){if(p=v.nextSibling&&v.nextSibling.dataset,p)var T=p.dgst;return p=T,b=Error(n(419)),p=vp(b,p,void 0),wd(o,a,k,p)}if(T=(k&o.childLanes)!==0,zn||T){if(p=ln,p!==null){switch(k&-k){case 4:v=2;break;case 16:v=8;break;case 64: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:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:v=32;break;case 536870912:v=268435456;break;default:v=0}v=(v&(p.suspendedLanes|k))!==0?0:v,v!==0&&v!==b.retryLane&&(b.retryLane=v,Xi(o,v),Xr(p,o,v,-1))}return Bp(),p=vp(Error(n(421))),wd(o,a,k,p)}return v.data==="$?"?(a.flags|=128,a.child=o.child,a=lC.bind(null,o),v._reactRetry=a,null):(o=b.treeContext,sr=Fo(v.nextSibling),or=a,Lt=!0,Wr=null,o!==null&&(xr[_r++]=qi,xr[_r++]=Ki,xr[_r++]=Ns,qi=o.id,Ki=o.overflow,Ns=a),a=kp(a,p.children),a.flags|=4096,a)}function D2(o,a,u){o.lanes|=a;var p=o.alternate;p!==null&&(p.lanes|=a),ep(o.return,a,u)}function Sp(o,a,u,p,v){var b=o.memoizedState;b===null?o.memoizedState={isBackwards:a,rendering:null,renderingStartTime:0,last:p,tail:u,tailMode:v}:(b.isBackwards=a,b.rendering=null,b.renderingStartTime=0,b.last=p,b.tail=u,b.tailMode=v)}function A2(o,a,u){var p=a.pendingProps,v=p.revealOrder,b=p.tail;if(Rn(o,a,p.children,u),p=At.current,(p&2)!==0)p=p&1|2,a.flags|=128;else{if(o!==null&&(o.flags&128)!==0)e:for(o=a.child;o!==null;){if(o.tag===13)o.memoizedState!==null&&D2(o,u,a);else if(o.tag===19)D2(o,u,a);else if(o.child!==null){o.child.return=o,o=o.child;continue}if(o===a)break e;for(;o.sibling===null;){if(o.return===null||o.return===a)break e;o=o.return}o.sibling.return=o.return,o=o.sibling}p&=1}if(bt(At,p),(a.mode&1)===0)a.memoizedState=null;else switch(v){case"forwards":for(u=a.child,v=null;u!==null;)o=u.alternate,o!==null&&fd(o)===null&&(v=u),u=u.sibling;u=v,u===null?(v=a.child,a.child=null):(v=u.sibling,u.sibling=null),Sp(a,!1,v,u,b);break;case"backwards":for(u=null,v=a.child,a.child=null;v!==null;){if(o=v.alternate,o!==null&&fd(o)===null){a.child=v;break}o=v.sibling,v.sibling=u,u=v,v=o}Sp(a,!0,u,null,b);break;case"together":Sp(a,!1,null,null,void 0);break;default:a.memoizedState=null}return a.child}function bd(o,a){(a.mode&1)===0&&o!==null&&(o.alternate=null,a.alternate=null,a.flags|=2)}function Yi(o,a,u){if(o!==null&&(a.dependencies=o.dependencies),Bs|=a.lanes,(u&a.childLanes)===0)return null;if(o!==null&&a.child!==o.child)throw Error(n(153));if(a.child!==null){for(o=a.child,u=Go(o,o.pendingProps),a.child=u,u.return=a;o.sibling!==null;)o=o.sibling,u=u.sibling=Go(o,o.pendingProps),u.return=a;u.sibling=null}return a.child}function QS(o,a,u){switch(a.tag){case 3:I2(a),Oa();break;case 5:W1(a);break;case 1:Un(a.type)&&nd(a);break;case 4:rp(a,a.stateNode.containerInfo);break;case 10:var p=a.type._context,v=a.memoizedProps.value;bt(ld,p._currentValue),p._currentValue=v;break;case 13:if(p=a.memoizedState,p!==null)return p.dehydrated!==null?(bt(At,At.current&1),a.flags|=128,null):(u&a.child.childLanes)!==0?L2(o,a,u):(bt(At,At.current&1),o=Yi(o,a,u),o!==null?o.sibling:null);bt(At,At.current&1);break;case 19:if(p=(u&a.childLanes)!==0,(o.flags&128)!==0){if(p)return A2(o,a,u);a.flags|=128}if(v=a.memoizedState,v!==null&&(v.rendering=null,v.tail=null,v.lastEffect=null),bt(At,At.current),p)break;return null;case 22:case 23:return a.lanes=0,S2(o,a,u)}return Yi(o,a,u)}var T2,Cp,R2,N2;T2=function(o,a){for(var u=a.child;u!==null;){if(u.tag===5||u.tag===6)o.appendChild(u.stateNode);else if(u.tag!==4&&u.child!==null){u.child.return=u,u=u.child;continue}if(u===a)break;for(;u.sibling===null;){if(u.return===null||u.return===a)return;u=u.return}u.sibling.return=u.return,u=u.sibling}},Cp=function(){},R2=function(o,a,u,p){var v=o.memoizedProps;if(v!==p){o=a.stateNode,Os(bi.current);var b=null;switch(u){case"input":v=mn(o,v),p=mn(o,p),b=[];break;case"select":v=le({},v,{value:void 0}),p=le({},p,{value:void 0}),b=[];break;case"textarea":v=Fe(o,v),p=Fe(o,p),b=[];break;default:typeof v.onClick!="function"&&typeof p.onClick=="function"&&(o.onclick=Zu)}Vi(u,p);var k;u=null;for(q in v)if(!p.hasOwnProperty(q)&&v.hasOwnProperty(q)&&v[q]!=null)if(q==="style"){var T=v[q];for(k in T)T.hasOwnProperty(k)&&(u||(u={}),u[k]="")}else q!=="dangerouslySetInnerHTML"&&q!=="children"&&q!=="suppressContentEditableWarning"&&q!=="suppressHydrationWarning"&&q!=="autoFocus"&&(i.hasOwnProperty(q)?b||(b=[]):(b=b||[]).push(q,null));for(q in p){var M=p[q];if(T=v!=null?v[q]:void 0,p.hasOwnProperty(q)&&M!==T&&(M!=null||T!=null))if(q==="style")if(T){for(k in T)!T.hasOwnProperty(k)||M&&M.hasOwnProperty(k)||(u||(u={}),u[k]="");for(k in M)M.hasOwnProperty(k)&&T[k]!==M[k]&&(u||(u={}),u[k]=M[k])}else u||(b||(b=[]),b.push(q,u)),u=M;else q==="dangerouslySetInnerHTML"?(M=M?M.__html:void 0,T=T?T.__html:void 0,M!=null&&T!==M&&(b=b||[]).push(q,M)):q==="children"?typeof M!="string"&&typeof M!="number"||(b=b||[]).push(q,""+M):q!=="suppressContentEditableWarning"&&q!=="suppressHydrationWarning"&&(i.hasOwnProperty(q)?(M!=null&&q==="onScroll"&&kt("scroll",o),b||T===M||(b=[])):(b=b||[]).push(q,M))}u&&(b=b||[]).push("style",u);var q=b;(a.updateQueue=q)&&(a.flags|=4)}},N2=function(o,a,u,p){u!==p&&(a.flags|=4)};function yc(o,a){if(!Lt)switch(o.tailMode){case"hidden":a=o.tail;for(var u=null;a!==null;)a.alternate!==null&&(u=a),a=a.sibling;u===null?o.tail=null:u.sibling=null;break;case"collapsed":u=o.tail;for(var p=null;u!==null;)u.alternate!==null&&(p=u),u=u.sibling;p===null?a||o.tail===null?o.tail=null:o.tail.sibling=null:p.sibling=null}}function Pn(o){var a=o.alternate!==null&&o.alternate.child===o.child,u=0,p=0;if(a)for(var v=o.child;v!==null;)u|=v.lanes|v.childLanes,p|=v.subtreeFlags&14680064,p|=v.flags&14680064,v.return=o,v=v.sibling;else for(v=o.child;v!==null;)u|=v.lanes|v.childLanes,p|=v.subtreeFlags,p|=v.flags,v.return=o,v=v.sibling;return o.subtreeFlags|=p,o.childLanes=u,a}function YS(o,a,u){var p=a.pendingProps;switch(qh(a),a.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Pn(a),null;case 1:return Un(a.type)&&td(),Pn(a),null;case 3:return p=a.stateNode,Va(),St(Vn),St(En),sp(),p.pendingContext&&(p.context=p.pendingContext,p.pendingContext=null),(o===null||o.child===null)&&(sd(a)?a.flags|=4:o===null||o.memoizedState.isDehydrated&&(a.flags&256)===0||(a.flags|=1024,Wr!==null&&(Mp(Wr),Wr=null))),Cp(o,a),Pn(a),null;case 5:ip(a);var v=Os(hc.current);if(u=a.type,o!==null&&a.stateNode!=null)R2(o,a,u,p,v),o.ref!==a.ref&&(a.flags|=512,a.flags|=2097152);else{if(!p){if(a.stateNode===null)throw Error(n(166));return Pn(a),null}if(o=Os(bi.current),sd(a)){p=a.stateNode,u=a.type;var b=a.memoizedProps;switch(p[wi]=a,p[lc]=b,o=(a.mode&1)!==0,u){case"dialog":kt("cancel",p),kt("close",p);break;case"iframe":case"object":case"embed":kt("load",p);break;case"video":case"audio":for(v=0;v<oc.length;v++)kt(oc[v],p);break;case"source":kt("error",p);break;case"img":case"image":case"link":kt("error",p),kt("load",p);break;case"details":kt("toggle",p);break;case"input":Je(p,b),kt("invalid",p);break;case"select":p._wrapperState={wasMultiple:!!b.multiple},kt("invalid",p);break;case"textarea":er(p,b),kt("invalid",p)}Vi(u,b),v=null;for(var k in b)if(b.hasOwnProperty(k)){var T=b[k];k==="children"?typeof T=="string"?p.textContent!==T&&(b.suppressHydrationWarning!==!0&&Ju(p.textContent,T,o),v=["children",T]):typeof T=="number"&&p.textContent!==""+T&&(b.suppressHydrationWarning!==!0&&Ju(p.textContent,T,o),v=["children",""+T]):i.hasOwnProperty(k)&&T!=null&&k==="onScroll"&&kt("scroll",p)}switch(u){case"input":pt(p),vs(p,b,!0);break;case"textarea":pt(p),Bi(p);break;case"select":case"option":break;default:typeof b.onClick=="function"&&(p.onclick=Zu)}p=v,a.updateQueue=p,p!==null&&(a.flags|=4)}else{k=v.nodeType===9?v:v.ownerDocument,o==="http://www.w3.org/1999/xhtml"&&(o=tr(u)),o==="http://www.w3.org/1999/xhtml"?u==="script"?(o=k.createElement("div"),o.innerHTML="<script><\/script>",o=o.removeChild(o.firstChild)):typeof p.is=="string"?o=k.createElement(u,{is:p.is}):(o=k.createElement(u),u==="select"&&(k=o,p.multiple?k.multiple=!0:p.size&&(k.size=p.size))):o=k.createElementNS(o,u),o[wi]=a,o[lc]=p,T2(o,a,!1,!1),a.stateNode=o;e:{switch(k=_o(u,p),u){case"dialog":kt("cancel",o),kt("close",o),v=p;break;case"iframe":case"object":case"embed":kt("load",o),v=p;break;case"video":case"audio":for(v=0;v<oc.length;v++)kt(oc[v],o);v=p;break;case"source":kt("error",o),v=p;break;case"img":case"image":case"link":kt("error",o),kt("load",o),v=p;break;case"details":kt("toggle",o),v=p;break;case"input":Je(o,p),v=mn(o,p),kt("invalid",o);break;case"option":v=p;break;case"select":o._wrapperState={wasMultiple:!!p.multiple},v=le({},p,{value:void 0}),kt("invalid",o);break;case"textarea":er(o,p),v=Fe(o,p),kt("invalid",o);break;default:v=p}Vi(u,v),T=v;for(b in T)if(T.hasOwnProperty(b)){var M=T[b];b==="style"?ys(o,M):b==="dangerouslySetInnerHTML"?(M=M?M.__html:void 0,M!=null&&ji(o,M)):b==="children"?typeof M=="string"?(u!=="textarea"||M!=="")&&gn(o,M):typeof M=="number"&&gn(o,""+M):b!=="suppressContentEditableWarning"&&b!=="suppressHydrationWarning"&&b!=="autoFocus"&&(i.hasOwnProperty(b)?M!=null&&b==="onScroll"&&kt("scroll",o):M!=null&&S(o,b,M,k))}switch(u){case"input":pt(o),vs(o,p,!1);break;case"textarea":pt(o),Bi(o);break;case"option":p.value!=null&&o.setAttribute("value",""+he(p.value));break;case"select":o.multiple=!!p.multiple,b=p.value,b!=null?oi(o,!!p.multiple,b,!1):p.defaultValue!=null&&oi(o,!!p.multiple,p.defaultValue,!0);break;default:typeof v.onClick=="function"&&(o.onclick=Zu)}switch(u){case"button":case"input":case"select":case"textarea":p=!!p.autoFocus;break e;case"img":p=!0;break e;default:p=!1}}p&&(a.flags|=4)}a.ref!==null&&(a.flags|=512,a.flags|=2097152)}return Pn(a),null;case 6:if(o&&a.stateNode!=null)N2(o,a,o.memoizedProps,p);else{if(typeof p!="string"&&a.stateNode===null)throw Error(n(166));if(u=Os(hc.current),Os(bi.current),sd(a)){if(p=a.stateNode,u=a.memoizedProps,p[wi]=a,(b=p.nodeValue!==u)&&(o=or,o!==null))switch(o.tag){case 3:Ju(p.nodeValue,u,(o.mode&1)!==0);break;case 5:o.memoizedProps.suppressHydrationWarning!==!0&&Ju(p.nodeValue,u,(o.mode&1)!==0)}b&&(a.flags|=4)}else p=(u.nodeType===9?u:u.ownerDocument).createTextNode(p),p[wi]=a,a.stateNode=p}return Pn(a),null;case 13:if(St(At),p=a.memoizedState,o===null||o.memoizedState!==null&&o.memoizedState.dehydrated!==null){if(Lt&&sr!==null&&(a.mode&1)!==0&&(a.flags&128)===0)O1(),Oa(),a.flags|=98560,b=!1;else if(b=sd(a),p!==null&&p.dehydrated!==null){if(o===null){if(!b)throw Error(n(318));if(b=a.memoizedState,b=b!==null?b.dehydrated:null,!b)throw Error(n(317));b[wi]=a}else Oa(),(a.flags&128)===0&&(a.memoizedState=null),a.flags|=4;Pn(a),b=!1}else Wr!==null&&(Mp(Wr),Wr=null),b=!0;if(!b)return a.flags&65536?a:null}return(a.flags&128)!==0?(a.lanes=u,a):(p=p!==null,p!==(o!==null&&o.memoizedState!==null)&&p&&(a.child.flags|=8192,(a.mode&1)!==0&&(o===null||(At.current&1)!==0?en===0&&(en=3):Bp())),a.updateQueue!==null&&(a.flags|=4),Pn(a),null);case 4:return Va(),Cp(o,a),o===null&&sc(a.stateNode.containerInfo),Pn(a),null;case 10:return Zh(a.type._context),Pn(a),null;case 17:return Un(a.type)&&td(),Pn(a),null;case 19:if(St(At),b=a.memoizedState,b===null)return Pn(a),null;if(p=(a.flags&128)!==0,k=b.rendering,k===null)if(p)yc(b,!1);else{if(en!==0||o!==null&&(o.flags&128)!==0)for(o=a.child;o!==null;){if(k=fd(o),k!==null){for(a.flags|=128,yc(b,!1),p=k.updateQueue,p!==null&&(a.updateQueue=p,a.flags|=4),a.subtreeFlags=0,p=u,u=a.child;u!==null;)b=u,o=p,b.flags&=14680066,k=b.alternate,k===null?(b.childLanes=0,b.lanes=o,b.child=null,b.subtreeFlags=0,b.memoizedProps=null,b.memoizedState=null,b.updateQueue=null,b.dependencies=null,b.stateNode=null):(b.childLanes=k.childLanes,b.lanes=k.lanes,b.child=k.child,b.subtreeFlags=0,b.deletions=null,b.memoizedProps=k.memoizedProps,b.memoizedState=k.memoizedState,b.updateQueue=k.updateQueue,b.type=k.type,o=k.dependencies,b.dependencies=o===null?null:{lanes:o.lanes,firstContext:o.firstContext}),u=u.sibling;return bt(At,At.current&1|2),a.child}o=o.sibling}b.tail!==null&&tt()>Wa&&(a.flags|=128,p=!0,yc(b,!1),a.lanes=4194304)}else{if(!p)if(o=fd(k),o!==null){if(a.flags|=128,p=!0,u=o.updateQueue,u!==null&&(a.updateQueue=u,a.flags|=4),yc(b,!0),b.tail===null&&b.tailMode==="hidden"&&!k.alternate&&!Lt)return Pn(a),null}else 2*tt()-b.renderingStartTime>Wa&&u!==1073741824&&(a.flags|=128,p=!0,yc(b,!1),a.lanes=4194304);b.isBackwards?(k.sibling=a.child,a.child=k):(u=b.last,u!==null?u.sibling=k:a.child=k,b.last=k)}return b.tail!==null?(a=b.tail,b.rendering=a,b.tail=a.sibling,b.renderingStartTime=tt(),a.sibling=null,u=At.current,bt(At,p?u&1|2:u&1),a):(Pn(a),null);case 22:case 23:return $p(),p=a.memoizedState!==null,o!==null&&o.memoizedState!==null!==p&&(a.flags|=8192),p&&(a.mode&1)!==0?(ar&1073741824)!==0&&(Pn(a),a.subtreeFlags&6&&(a.flags|=8192)):Pn(a),null;case 24:return null;case 25:return null}throw Error(n(156,a.tag))}function JS(o,a){switch(qh(a),a.tag){case 1:return Un(a.type)&&td(),o=a.flags,o&65536?(a.flags=o&-65537|128,a):null;case 3:return Va(),St(Vn),St(En),sp(),o=a.flags,(o&65536)!==0&&(o&128)===0?(a.flags=o&-65537|128,a):null;case 5:return ip(a),null;case 13:if(St(At),o=a.memoizedState,o!==null&&o.dehydrated!==null){if(a.alternate===null)throw Error(n(340));Oa()}return o=a.flags,o&65536?(a.flags=o&-65537|128,a):null;case 19:return St(At),null;case 4:return Va(),null;case 10:return Zh(a.type._context),null;case 22:case 23:return $p(),null;case 24:return null;default:return null}}var xd=!1,Ln=!1,ZS=typeof WeakSet=="function"?WeakSet:Set,Ee=null;function za(o,a){var u=o.ref;if(u!==null)if(typeof u=="function")try{u(null)}catch(p){Mt(o,a,p)}else u.current=null}function Ep(o,a,u){try{u()}catch(p){Mt(o,a,p)}}var F2=!1;function eC(o,a){if($h=ir,o=h1(),Dh(o)){if("selectionStart"in o)var u={start:o.selectionStart,end:o.selectionEnd};else e:{u=(u=o.ownerDocument)&&u.defaultView||window;var p=u.getSelection&&u.getSelection();if(p&&p.rangeCount!==0){u=p.anchorNode;var v=p.anchorOffset,b=p.focusNode;p=p.focusOffset;try{u.nodeType,b.nodeType}catch{u=null;break e}var k=0,T=-1,M=-1,q=0,ae=0,ue=o,se=null;t:for(;;){for(var ke;ue!==u||v!==0&&ue.nodeType!==3||(T=k+v),ue!==b||p!==0&&ue.nodeType!==3||(M=k+p),ue.nodeType===3&&(k+=ue.nodeValue.length),(ke=ue.firstChild)!==null;)se=ue,ue=ke;for(;;){if(ue===o)break t;if(se===u&&++q===v&&(T=k),se===b&&++ae===p&&(M=k),(ke=ue.nextSibling)!==null)break;ue=se,se=ue.parentNode}ue=ke}u=T===-1||M===-1?null:{start:T,end:M}}else u=null}u=u||{start:0,end:0}}else u=null;for(Bh={focusedElem:o,selectionRange:u},ir=!1,Ee=a;Ee!==null;)if(a=Ee,o=a.child,(a.subtreeFlags&1028)!==0&&o!==null)o.return=a,Ee=o;else for(;Ee!==null;){a=Ee;try{var Ie=a.alternate;if((a.flags&1024)!==0)switch(a.tag){case 0:case 11:case 15:break;case 1:if(Ie!==null){var Le=Ie.memoizedProps,Bt=Ie.memoizedState,z=a.stateNode,j=z.getSnapshotBeforeUpdate(a.elementType===a.type?Le:Gr(a.type,Le),Bt);z.__reactInternalSnapshotBeforeUpdate=j}break;case 3:var G=a.stateNode.containerInfo;G.nodeType===1?G.textContent="":G.nodeType===9&&G.documentElement&&G.removeChild(G.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(me){Mt(a,a.return,me)}if(o=a.sibling,o!==null){o.return=a.return,Ee=o;break}Ee=a.return}return Ie=F2,F2=!1,Ie}function wc(o,a,u){var p=a.updateQueue;if(p=p!==null?p.lastEffect:null,p!==null){var v=p=p.next;do{if((v.tag&o)===o){var b=v.destroy;v.destroy=void 0,b!==void 0&&Ep(a,u,b)}v=v.next}while(v!==p)}}function _d(o,a){if(a=a.updateQueue,a=a!==null?a.lastEffect:null,a!==null){var u=a=a.next;do{if((u.tag&o)===o){var p=u.create;u.destroy=p()}u=u.next}while(u!==a)}}function Ip(o){var a=o.ref;if(a!==null){var u=o.stateNode;switch(o.tag){case 5:o=u;break;default:o=u}typeof a=="function"?a(o):a.current=o}}function M2(o){var a=o.alternate;a!==null&&(o.alternate=null,M2(a)),o.child=null,o.deletions=null,o.sibling=null,o.tag===5&&(a=o.stateNode,a!==null&&(delete a[wi],delete a[lc],delete a[zh],delete a[MS],delete a[OS])),o.stateNode=null,o.return=null,o.dependencies=null,o.memoizedProps=null,o.memoizedState=null,o.pendingProps=null,o.stateNode=null,o.updateQueue=null}function O2(o){return o.tag===5||o.tag===3||o.tag===4}function $2(o){e:for(;;){for(;o.sibling===null;){if(o.return===null||O2(o.return))return null;o=o.return}for(o.sibling.return=o.return,o=o.sibling;o.tag!==5&&o.tag!==6&&o.tag!==18;){if(o.flags&2||o.child===null||o.tag===4)continue e;o.child.return=o,o=o.child}if(!(o.flags&2))return o.stateNode}}function Pp(o,a,u){var p=o.tag;if(p===5||p===6)o=o.stateNode,a?u.nodeType===8?u.parentNode.insertBefore(o,a):u.insertBefore(o,a):(u.nodeType===8?(a=u.parentNode,a.insertBefore(o,u)):(a=u,a.appendChild(o)),u=u._reactRootContainer,u!=null||a.onclick!==null||(a.onclick=Zu));else if(p!==4&&(o=o.child,o!==null))for(Pp(o,a,u),o=o.sibling;o!==null;)Pp(o,a,u),o=o.sibling}function Lp(o,a,u){var p=o.tag;if(p===5||p===6)o=o.stateNode,a?u.insertBefore(o,a):u.appendChild(o);else if(p!==4&&(o=o.child,o!==null))for(Lp(o,a,u),o=o.sibling;o!==null;)Lp(o,a,u),o=o.sibling}var wn=null,qr=!1;function Vo(o,a,u){for(u=u.child;u!==null;)B2(o,a,u),u=u.sibling}function B2(o,a,u){if(yr&&typeof yr.onCommitFiberUnmount=="function")try{yr.onCommitFiberUnmount(So,u)}catch{}switch(u.tag){case 5:Ln||za(u,a);case 6:var p=wn,v=qr;wn=null,Vo(o,a,u),wn=p,qr=v,wn!==null&&(qr?(o=wn,u=u.stateNode,o.nodeType===8?o.parentNode.removeChild(u):o.removeChild(u)):wn.removeChild(u.stateNode));break;case 18:wn!==null&&(qr?(o=wn,u=u.stateNode,o.nodeType===8?Uh(o.parentNode,u):o.nodeType===1&&Uh(o,u),Io(o)):Uh(wn,u.stateNode));break;case 4:p=wn,v=qr,wn=u.stateNode.containerInfo,qr=!0,Vo(o,a,u),wn=p,qr=v;break;case 0:case 11:case 14:case 15:if(!Ln&&(p=u.updateQueue,p!==null&&(p=p.lastEffect,p!==null))){v=p=p.next;do{var b=v,k=b.destroy;b=b.tag,k!==void 0&&((b&2)!==0||(b&4)!==0)&&Ep(u,a,k),v=v.next}while(v!==p)}Vo(o,a,u);break;case 1:if(!Ln&&(za(u,a),p=u.stateNode,typeof p.componentWillUnmount=="function"))try{p.props=u.memoizedProps,p.state=u.memoizedState,p.componentWillUnmount()}catch(T){Mt(u,a,T)}Vo(o,a,u);break;case 21:Vo(o,a,u);break;case 22:u.mode&1?(Ln=(p=Ln)||u.memoizedState!==null,Vo(o,a,u),Ln=p):Vo(o,a,u);break;default:Vo(o,a,u)}}function j2(o){var a=o.updateQueue;if(a!==null){o.updateQueue=null;var u=o.stateNode;u===null&&(u=o.stateNode=new ZS),a.forEach(function(p){var v=cC.bind(null,o,p);u.has(p)||(u.add(p),p.then(v,v))})}}function Kr(o,a){var u=a.deletions;if(u!==null)for(var p=0;p<u.length;p++){var v=u[p];try{var b=o,k=a,T=k;e:for(;T!==null;){switch(T.tag){case 5:wn=T.stateNode,qr=!1;break e;case 3:wn=T.stateNode.containerInfo,qr=!0;break e;case 4:wn=T.stateNode.containerInfo,qr=!0;break e}T=T.return}if(wn===null)throw Error(n(160));B2(b,k,v),wn=null,qr=!1;var M=v.alternate;M!==null&&(M.return=null),v.return=null}catch(q){Mt(v,a,q)}}if(a.subtreeFlags&12854)for(a=a.child;a!==null;)V2(a,o),a=a.sibling}function V2(o,a){var u=o.alternate,p=o.flags;switch(o.tag){case 0:case 11:case 14:case 15:if(Kr(a,o),_i(o),p&4){try{wc(3,o,o.return),_d(3,o)}catch(Le){Mt(o,o.return,Le)}try{wc(5,o,o.return)}catch(Le){Mt(o,o.return,Le)}}break;case 1:Kr(a,o),_i(o),p&512&&u!==null&&za(u,u.return);break;case 5:if(Kr(a,o),_i(o),p&512&&u!==null&&za(u,u.return),o.flags&32){var v=o.stateNode;try{gn(v,"")}catch(Le){Mt(o,o.return,Le)}}if(p&4&&(v=o.stateNode,v!=null)){var b=o.memoizedProps,k=u!==null?u.memoizedProps:b,T=o.type,M=o.updateQueue;if(o.updateQueue=null,M!==null)try{T==="input"&&b.type==="radio"&&b.name!=null&&Oi(v,b),_o(T,k);var q=_o(T,b);for(k=0;k<M.length;k+=2){var ae=M[k],ue=M[k+1];ae==="style"?ys(v,ue):ae==="dangerouslySetInnerHTML"?ji(v,ue):ae==="children"?gn(v,ue):S(v,ae,ue,q)}switch(T){case"input":Mr(v,b);break;case"textarea":si(v,b);break;case"select":var se=v._wrapperState.wasMultiple;v._wrapperState.wasMultiple=!!b.multiple;var ke=b.value;ke!=null?oi(v,!!b.multiple,ke,!1):se!==!!b.multiple&&(b.defaultValue!=null?oi(v,!!b.multiple,b.defaultValue,!0):oi(v,!!b.multiple,b.multiple?[]:"",!1))}v[lc]=b}catch(Le){Mt(o,o.return,Le)}}break;case 6:if(Kr(a,o),_i(o),p&4){if(o.stateNode===null)throw Error(n(162));v=o.stateNode,b=o.memoizedProps;try{v.nodeValue=b}catch(Le){Mt(o,o.return,Le)}}break;case 3:if(Kr(a,o),_i(o),p&4&&u!==null&&u.memoizedState.isDehydrated)try{Io(a.containerInfo)}catch(Le){Mt(o,o.return,Le)}break;case 4:Kr(a,o),_i(o);break;case 13:Kr(a,o),_i(o),v=o.child,v.flags&8192&&(b=v.memoizedState!==null,v.stateNode.isHidden=b,!b||v.alternate!==null&&v.alternate.memoizedState!==null||(Tp=tt())),p&4&&j2(o);break;case 22:if(ae=u!==null&&u.memoizedState!==null,o.mode&1?(Ln=(q=Ln)||ae,Kr(a,o),Ln=q):Kr(a,o),_i(o),p&8192){if(q=o.memoizedState!==null,(o.stateNode.isHidden=q)&&!ae&&(o.mode&1)!==0)for(Ee=o,ae=o.child;ae!==null;){for(ue=Ee=ae;Ee!==null;){switch(se=Ee,ke=se.child,se.tag){case 0:case 11:case 14:case 15:wc(4,se,se.return);break;case 1:za(se,se.return);var Ie=se.stateNode;if(typeof Ie.componentWillUnmount=="function"){p=se,u=se.return;try{a=p,Ie.props=a.memoizedProps,Ie.state=a.memoizedState,Ie.componentWillUnmount()}catch(Le){Mt(p,u,Le)}}break;case 5:za(se,se.return);break;case 22:if(se.memoizedState!==null){H2(ue);continue}}ke!==null?(ke.return=se,Ee=ke):H2(ue)}ae=ae.sibling}e:for(ae=null,ue=o;;){if(ue.tag===5){if(ae===null){ae=ue;try{v=ue.stateNode,q?(b=v.style,typeof b.setProperty=="function"?b.setProperty("display","none","important"):b.display="none"):(T=ue.stateNode,M=ue.memoizedProps.style,k=M!=null&&M.hasOwnProperty("display")?M.display:null,T.style.display=da("display",k))}catch(Le){Mt(o,o.return,Le)}}}else if(ue.tag===6){if(ae===null)try{ue.stateNode.nodeValue=q?"":ue.memoizedProps}catch(Le){Mt(o,o.return,Le)}}else if((ue.tag!==22&&ue.tag!==23||ue.memoizedState===null||ue===o)&&ue.child!==null){ue.child.return=ue,ue=ue.child;continue}if(ue===o)break e;for(;ue.sibling===null;){if(ue.return===null||ue.return===o)break e;ae===ue&&(ae=null),ue=ue.return}ae===ue&&(ae=null),ue.sibling.return=ue.return,ue=ue.sibling}}break;case 19:Kr(a,o),_i(o),p&4&&j2(o);break;case 21:break;default:Kr(a,o),_i(o)}}function _i(o){var a=o.flags;if(a&2){try{e:{for(var u=o.return;u!==null;){if(O2(u)){var p=u;break e}u=u.return}throw Error(n(160))}switch(p.tag){case 5:var v=p.stateNode;p.flags&32&&(gn(v,""),p.flags&=-33);var b=$2(o);Lp(o,b,v);break;case 3:case 4:var k=p.stateNode.containerInfo,T=$2(o);Pp(o,T,k);break;default:throw Error(n(161))}}catch(M){Mt(o,o.return,M)}o.flags&=-3}a&4096&&(o.flags&=-4097)}function tC(o,a,u){Ee=o,U2(o)}function U2(o,a,u){for(var p=(o.mode&1)!==0;Ee!==null;){var v=Ee,b=v.child;if(v.tag===22&&p){var k=v.memoizedState!==null||xd;if(!k){var T=v.alternate,M=T!==null&&T.memoizedState!==null||Ln;T=xd;var q=Ln;if(xd=k,(Ln=M)&&!q)for(Ee=v;Ee!==null;)k=Ee,M=k.child,k.tag===22&&k.memoizedState!==null?W2(v):M!==null?(M.return=k,Ee=M):W2(v);for(;b!==null;)Ee=b,U2(b),b=b.sibling;Ee=v,xd=T,Ln=q}z2(o)}else(v.subtreeFlags&8772)!==0&&b!==null?(b.return=v,Ee=b):z2(o)}}function z2(o){for(;Ee!==null;){var a=Ee;if((a.flags&8772)!==0){var u=a.alternate;try{if((a.flags&8772)!==0)switch(a.tag){case 0:case 11:case 15:Ln||_d(5,a);break;case 1:var p=a.stateNode;if(a.flags&4&&!Ln)if(u===null)p.componentDidMount();else{var v=a.elementType===a.type?u.memoizedProps:Gr(a.type,u.memoizedProps);p.componentDidUpdate(v,u.memoizedState,p.__reactInternalSnapshotBeforeUpdate)}var b=a.updateQueue;b!==null&&H1(a,b,p);break;case 3:var k=a.updateQueue;if(k!==null){if(u=null,a.child!==null)switch(a.child.tag){case 5:u=a.child.stateNode;break;case 1:u=a.child.stateNode}H1(a,k,u)}break;case 5:var T=a.stateNode;if(u===null&&a.flags&4){u=T;var M=a.memoizedProps;switch(a.type){case"button":case"input":case"select":case"textarea":M.autoFocus&&u.focus();break;case"img":M.src&&(u.src=M.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(a.memoizedState===null){var q=a.alternate;if(q!==null){var ae=q.memoizedState;if(ae!==null){var ue=ae.dehydrated;ue!==null&&Io(ue)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(n(163))}Ln||a.flags&512&&Ip(a)}catch(se){Mt(a,a.return,se)}}if(a===o){Ee=null;break}if(u=a.sibling,u!==null){u.return=a.return,Ee=u;break}Ee=a.return}}function H2(o){for(;Ee!==null;){var a=Ee;if(a===o){Ee=null;break}var u=a.sibling;if(u!==null){u.return=a.return,Ee=u;break}Ee=a.return}}function W2(o){for(;Ee!==null;){var a=Ee;try{switch(a.tag){case 0:case 11:case 15:var u=a.return;try{_d(4,a)}catch(M){Mt(a,u,M)}break;case 1:var p=a.stateNode;if(typeof p.componentDidMount=="function"){var v=a.return;try{p.componentDidMount()}catch(M){Mt(a,v,M)}}var b=a.return;try{Ip(a)}catch(M){Mt(a,b,M)}break;case 5:var k=a.return;try{Ip(a)}catch(M){Mt(a,k,M)}}}catch(M){Mt(a,a.return,M)}if(a===o){Ee=null;break}var T=a.sibling;if(T!==null){T.return=a.return,Ee=T;break}Ee=a.return}}var nC=Math.ceil,kd=L.ReactCurrentDispatcher,Dp=L.ReactCurrentOwner,Cr=L.ReactCurrentBatchConfig,it=0,ln=null,qt=null,bn=0,ar=0,Ha=Mo(0),en=0,bc=null,Bs=0,Sd=0,Ap=0,xc=null,Hn=null,Tp=0,Wa=1/0,Ji=null,Cd=!1,Rp=null,Uo=null,Ed=!1,zo=null,Id=0,_c=0,Np=null,Pd=-1,Ld=0;function Nn(){return(it&6)!==0?tt():Pd!==-1?Pd:Pd=tt()}function Ho(o){return(o.mode&1)===0?1:(it&2)!==0&&bn!==0?bn&-bn:BS.transition!==null?(Ld===0&&(Ld=Ou()),Ld):(o=nt,o!==0||(o=window.event,o=o===void 0?16:zu(o.type)),o)}function Xr(o,a,u,p){if(50<_c)throw _c=0,Np=null,Error(n(185));di(o,u,p),((it&2)===0||o!==ln)&&(o===ln&&((it&2)===0&&(Sd|=u),en===4&&Wo(o,bn)),Wn(o,p),u===1&&it===0&&(a.mode&1)===0&&(Wa=tt()+500,rd&&$o()))}function Wn(o,a){var u=o.callbackNode;Ch(o,a);var p=pa(o,o===ln?bn:0);if(p===0)u!==null&&Nu(u),o.callbackNode=null,o.callbackPriority=0;else if(a=p&-p,o.callbackPriority!==a){if(u!=null&&Nu(u),a===1)o.tag===0?$S(q2.bind(null,o)):T1(q2.bind(null,o)),NS(function(){(it&6)===0&&$o()}),u=null;else{switch(ks(p)){case 1:u=zi;break;case 4:u=zl;break;case 16:u=jr;break;case 536870912:u=xs;break;default:u=jr}u=tv(u,G2.bind(null,o))}o.callbackPriority=a,o.callbackNode=u}}function G2(o,a){if(Pd=-1,Ld=0,(it&6)!==0)throw Error(n(327));var u=o.callbackNode;if(Ga()&&o.callbackNode!==u)return null;var p=pa(o,o===ln?bn:0);if(p===0)return null;if((p&30)!==0||(p&o.expiredLanes)!==0||a)a=Dd(o,p);else{a=p;var v=it;it|=2;var b=X2();(ln!==o||bn!==a)&&(Ji=null,Wa=tt()+500,Vs(o,a));do try{oC();break}catch(T){K2(o,T)}while(!0);Jh(),kd.current=b,it=v,qt!==null?a=0:(ln=null,bn=0,a=en)}if(a!==0){if(a===2&&(v=ga(o),v!==0&&(p=v,a=Fp(o,v))),a===1)throw u=bc,Vs(o,0),Wo(o,p),Wn(o,tt()),u;if(a===6)Wo(o,p);else{if(v=o.current.alternate,(p&30)===0&&!rC(v)&&(a=Dd(o,p),a===2&&(b=ga(o),b!==0&&(p=b,a=Fp(o,b))),a===1))throw u=bc,Vs(o,0),Wo(o,p),Wn(o,tt()),u;switch(o.finishedWork=v,o.finishedLanes=p,a){case 0:case 1:throw Error(n(345));case 2:Us(o,Hn,Ji);break;case 3:if(Wo(o,p),(p&130023424)===p&&(a=Tp+500-tt(),10<a)){if(pa(o,0)!==0)break;if(v=o.suspendedLanes,(v&p)!==p){Nn(),o.pingedLanes|=o.suspendedLanes&v;break}o.timeoutHandle=Vh(Us.bind(null,o,Hn,Ji),a);break}Us(o,Hn,Ji);break;case 4:if(Wo(o,p),(p&4194240)===p)break;for(a=o.eventTimes,v=-1;0<p;){var k=31-Sn(p);b=1<<k,k=a[k],k>v&&(v=k),p&=~b}if(p=v,p=tt()-p,p=(120>p?120:480>p?480:1080>p?1080:1920>p?1920:3e3>p?3e3:4320>p?4320:1960*nC(p/1960))-p,10<p){o.timeoutHandle=Vh(Us.bind(null,o,Hn,Ji),p);break}Us(o,Hn,Ji);break;case 5:Us(o,Hn,Ji);break;default:throw Error(n(329))}}}return Wn(o,tt()),o.callbackNode===u?G2.bind(null,o):null}function Fp(o,a){var u=xc;return o.current.memoizedState.isDehydrated&&(Vs(o,a).flags|=256),o=Dd(o,a),o!==2&&(a=Hn,Hn=u,a!==null&&Mp(a)),o}function Mp(o){Hn===null?Hn=o:Hn.push.apply(Hn,o)}function rC(o){for(var a=o;;){if(a.flags&16384){var u=a.updateQueue;if(u!==null&&(u=u.stores,u!==null))for(var p=0;p<u.length;p++){var v=u[p],b=v.getSnapshot;v=v.value;try{if(!Hr(b(),v))return!1}catch{return!1}}}if(u=a.child,a.subtreeFlags&16384&&u!==null)u.return=a,a=u;else{if(a===o)break;for(;a.sibling===null;){if(a.return===null||a.return===o)return!0;a=a.return}a.sibling.return=a.return,a=a.sibling}}return!0}function Wo(o,a){for(a&=~Ap,a&=~Sd,o.suspendedLanes|=a,o.pingedLanes&=~a,o=o.expirationTimes;0<a;){var u=31-Sn(a),p=1<<u;o[u]=-1,a&=~p}}function q2(o){if((it&6)!==0)throw Error(n(327));Ga();var a=pa(o,0);if((a&1)===0)return Wn(o,tt()),null;var u=Dd(o,a);if(o.tag!==0&&u===2){var p=ga(o);p!==0&&(a=p,u=Fp(o,p))}if(u===1)throw u=bc,Vs(o,0),Wo(o,a),Wn(o,tt()),u;if(u===6)throw Error(n(345));return o.finishedWork=o.current.alternate,o.finishedLanes=a,Us(o,Hn,Ji),Wn(o,tt()),null}function Op(o,a){var u=it;it|=1;try{return o(a)}finally{it=u,it===0&&(Wa=tt()+500,rd&&$o())}}function js(o){zo!==null&&zo.tag===0&&(it&6)===0&&Ga();var a=it;it|=1;var u=Cr.transition,p=nt;try{if(Cr.transition=null,nt=1,o)return o()}finally{nt=p,Cr.transition=u,it=a,(it&6)===0&&$o()}}function $p(){ar=Ha.current,St(Ha)}function Vs(o,a){o.finishedWork=null,o.finishedLanes=0;var u=o.timeoutHandle;if(u!==-1&&(o.timeoutHandle=-1,RS(u)),qt!==null)for(u=qt.return;u!==null;){var p=u;switch(qh(p),p.tag){case 1:p=p.type.childContextTypes,p!=null&&td();break;case 3:Va(),St(Vn),St(En),sp();break;case 5:ip(p);break;case 4:Va();break;case 13:St(At);break;case 19:St(At);break;case 10:Zh(p.type._context);break;case 22:case 23:$p()}u=u.return}if(ln=o,qt=o=Go(o.current,null),bn=ar=a,en=0,bc=null,Ap=Sd=Bs=0,Hn=xc=null,Ms!==null){for(a=0;a<Ms.length;a++)if(u=Ms[a],p=u.interleaved,p!==null){u.interleaved=null;var v=p.next,b=u.pending;if(b!==null){var k=b.next;b.next=v,p.next=k}u.pending=p}Ms=null}return o}function K2(o,a){do{var u=qt;try{if(Jh(),hd.current=vd,pd){for(var p=Tt.memoizedState;p!==null;){var v=p.queue;v!==null&&(v.pending=null),p=p.next}pd=!1}if($s=0,an=Zt=Tt=null,pc=!1,mc=0,Dp.current=null,u===null||u.return===null){en=1,bc=a,qt=null;break}e:{var b=o,k=u.return,T=u,M=a;if(a=bn,T.flags|=32768,M!==null&&typeof M=="object"&&typeof M.then=="function"){var q=M,ae=T,ue=ae.tag;if((ae.mode&1)===0&&(ue===0||ue===11||ue===15)){var se=ae.alternate;se?(ae.updateQueue=se.updateQueue,ae.memoizedState=se.memoizedState,ae.lanes=se.lanes):(ae.updateQueue=null,ae.memoizedState=null)}var ke=w2(k);if(ke!==null){ke.flags&=-257,b2(ke,k,T,b,a),ke.mode&1&&y2(b,q,a),a=ke,M=q;var Ie=a.updateQueue;if(Ie===null){var Le=new Set;Le.add(M),a.updateQueue=Le}else Ie.add(M);break e}else{if((a&1)===0){y2(b,q,a),Bp();break e}M=Error(n(426))}}else if(Lt&&T.mode&1){var Bt=w2(k);if(Bt!==null){(Bt.flags&65536)===0&&(Bt.flags|=256),b2(Bt,k,T,b,a),Qh(Ua(M,T));break e}}b=M=Ua(M,T),en!==4&&(en=2),xc===null?xc=[b]:xc.push(b),b=k;do{switch(b.tag){case 3:b.flags|=65536,a&=-a,b.lanes|=a;var z=g2(b,M,a);z1(b,z);break e;case 1:T=M;var j=b.type,G=b.stateNode;if((b.flags&128)===0&&(typeof j.getDerivedStateFromError=="function"||G!==null&&typeof G.componentDidCatch=="function"&&(Uo===null||!Uo.has(G)))){b.flags|=65536,a&=-a,b.lanes|=a;var me=v2(b,T,a);z1(b,me);break e}}b=b.return}while(b!==null)}Y2(u)}catch(Ae){a=Ae,qt===u&&u!==null&&(qt=u=u.return);continue}break}while(!0)}function X2(){var o=kd.current;return kd.current=vd,o===null?vd:o}function Bp(){(en===0||en===3||en===2)&&(en=4),ln===null||(Bs&268435455)===0&&(Sd&268435455)===0||Wo(ln,bn)}function Dd(o,a){var u=it;it|=2;var p=X2();(ln!==o||bn!==a)&&(Ji=null,Vs(o,a));do try{iC();break}catch(v){K2(o,v)}while(!0);if(Jh(),it=u,kd.current=p,qt!==null)throw Error(n(261));return ln=null,bn=0,en}function iC(){for(;qt!==null;)Q2(qt)}function oC(){for(;qt!==null&&!Gt();)Q2(qt)}function Q2(o){var a=ev(o.alternate,o,ar);o.memoizedProps=o.pendingProps,a===null?Y2(o):qt=a,Dp.current=null}function Y2(o){var a=o;do{var u=a.alternate;if(o=a.return,(a.flags&32768)===0){if(u=YS(u,a,ar),u!==null){qt=u;return}}else{if(u=JS(u,a),u!==null){u.flags&=32767,qt=u;return}if(o!==null)o.flags|=32768,o.subtreeFlags=0,o.deletions=null;else{en=6,qt=null;return}}if(a=a.sibling,a!==null){qt=a;return}qt=a=o}while(a!==null);en===0&&(en=5)}function Us(o,a,u){var p=nt,v=Cr.transition;try{Cr.transition=null,nt=1,sC(o,a,u,p)}finally{Cr.transition=v,nt=p}return null}function sC(o,a,u,p){do Ga();while(zo!==null);if((it&6)!==0)throw Error(n(327));u=o.finishedWork;var v=o.finishedLanes;if(u===null)return null;if(o.finishedWork=null,o.finishedLanes=0,u===o.current)throw Error(n(177));o.callbackNode=null,o.callbackPriority=0;var b=u.lanes|u.childLanes;if(_s(o,b),o===ln&&(qt=ln=null,bn=0),(u.subtreeFlags&2064)===0&&(u.flags&2064)===0||Ed||(Ed=!0,tv(jr,function(){return Ga(),null})),b=(u.flags&15990)!==0,(u.subtreeFlags&15990)!==0||b){b=Cr.transition,Cr.transition=null;var k=nt;nt=1;var T=it;it|=4,Dp.current=null,eC(o,u),V2(u,o),ES(Bh),ir=!!$h,Bh=$h=null,o.current=u,tC(u),ha(),it=T,nt=k,Cr.transition=b}else o.current=u;if(Ed&&(Ed=!1,zo=o,Id=v),b=o.pendingLanes,b===0&&(Uo=null),Fu(u.stateNode),Wn(o,tt()),a!==null)for(p=o.onRecoverableError,u=0;u<a.length;u++)v=a[u],p(v.value,{componentStack:v.stack,digest:v.digest});if(Cd)throw Cd=!1,o=Rp,Rp=null,o;return(Id&1)!==0&&o.tag!==0&&Ga(),b=o.pendingLanes,(b&1)!==0?o===Np?_c++:(_c=0,Np=o):_c=0,$o(),null}function Ga(){if(zo!==null){var o=ks(Id),a=Cr.transition,u=nt;try{if(Cr.transition=null,nt=16>o?16:o,zo===null)var p=!1;else{if(o=zo,zo=null,Id=0,(it&6)!==0)throw Error(n(331));var v=it;for(it|=4,Ee=o.current;Ee!==null;){var b=Ee,k=b.child;if((Ee.flags&16)!==0){var T=b.deletions;if(T!==null){for(var M=0;M<T.length;M++){var q=T[M];for(Ee=q;Ee!==null;){var ae=Ee;switch(ae.tag){case 0:case 11:case 15:wc(8,ae,b)}var ue=ae.child;if(ue!==null)ue.return=ae,Ee=ue;else for(;Ee!==null;){ae=Ee;var se=ae.sibling,ke=ae.return;if(M2(ae),ae===q){Ee=null;break}if(se!==null){se.return=ke,Ee=se;break}Ee=ke}}}var Ie=b.alternate;if(Ie!==null){var Le=Ie.child;if(Le!==null){Ie.child=null;do{var Bt=Le.sibling;Le.sibling=null,Le=Bt}while(Le!==null)}}Ee=b}}if((b.subtreeFlags&2064)!==0&&k!==null)k.return=b,Ee=k;else e:for(;Ee!==null;){if(b=Ee,(b.flags&2048)!==0)switch(b.tag){case 0:case 11:case 15:wc(9,b,b.return)}var z=b.sibling;if(z!==null){z.return=b.return,Ee=z;break e}Ee=b.return}}var j=o.current;for(Ee=j;Ee!==null;){k=Ee;var G=k.child;if((k.subtreeFlags&2064)!==0&&G!==null)G.return=k,Ee=G;else e:for(k=j;Ee!==null;){if(T=Ee,(T.flags&2048)!==0)try{switch(T.tag){case 0:case 11:case 15:_d(9,T)}}catch(Ae){Mt(T,T.return,Ae)}if(T===k){Ee=null;break e}var me=T.sibling;if(me!==null){me.return=T.return,Ee=me;break e}Ee=T.return}}if(it=v,$o(),yr&&typeof yr.onPostCommitFiberRoot=="function")try{yr.onPostCommitFiberRoot(So,o)}catch{}p=!0}return p}finally{nt=u,Cr.transition=a}}return!1}function J2(o,a,u){a=Ua(u,a),a=g2(o,a,1),o=jo(o,a,1),a=Nn(),o!==null&&(di(o,1,a),Wn(o,a))}function Mt(o,a,u){if(o.tag===3)J2(o,o,u);else for(;a!==null;){if(a.tag===3){J2(a,o,u);break}else if(a.tag===1){var p=a.stateNode;if(typeof a.type.getDerivedStateFromError=="function"||typeof p.componentDidCatch=="function"&&(Uo===null||!Uo.has(p))){o=Ua(u,o),o=v2(a,o,1),a=jo(a,o,1),o=Nn(),a!==null&&(di(a,1,o),Wn(a,o));break}}a=a.return}}function aC(o,a,u){var p=o.pingCache;p!==null&&p.delete(a),a=Nn(),o.pingedLanes|=o.suspendedLanes&u,ln===o&&(bn&u)===u&&(en===4||en===3&&(bn&130023424)===bn&&500>tt()-Tp?Vs(o,0):Ap|=u),Wn(o,a)}function Z2(o,a){a===0&&((o.mode&1)===0?a=1:(a=ui,ui<<=1,(ui&130023424)===0&&(ui=4194304)));var u=Nn();o=Xi(o,a),o!==null&&(di(o,a,u),Wn(o,u))}function lC(o){var a=o.memoizedState,u=0;a!==null&&(u=a.retryLane),Z2(o,u)}function cC(o,a){var u=0;switch(o.tag){case 13:var p=o.stateNode,v=o.memoizedState;v!==null&&(u=v.retryLane);break;case 19:p=o.stateNode;break;default:throw Error(n(314))}p!==null&&p.delete(a),Z2(o,u)}var ev;ev=function(o,a,u){if(o!==null)if(o.memoizedProps!==a.pendingProps||Vn.current)zn=!0;else{if((o.lanes&u)===0&&(a.flags&128)===0)return zn=!1,QS(o,a,u);zn=(o.flags&131072)!==0}else zn=!1,Lt&&(a.flags&1048576)!==0&&R1(a,od,a.index);switch(a.lanes=0,a.tag){case 2:var p=a.type;bd(o,a),o=a.pendingProps;var v=Na(a,En.current);ja(a,u),v=cp(null,a,p,o,v,u);var b=up();return a.flags|=1,typeof v=="object"&&v!==null&&typeof v.render=="function"&&v.$$typeof===void 0?(a.tag=1,a.memoizedState=null,a.updateQueue=null,Un(p)?(b=!0,nd(a)):b=!1,a.memoizedState=v.state!==null&&v.state!==void 0?v.state:null,np(a),v.updater=yd,a.stateNode=v,v._reactInternals=a,gp(a,p,o,u),a=bp(null,a,p,!0,b,u)):(a.tag=0,Lt&&b&&Gh(a),Rn(null,a,v,u),a=a.child),a;case 16:p=a.elementType;e:{switch(bd(o,a),o=a.pendingProps,v=p._init,p=v(p._payload),a.type=p,v=a.tag=dC(p),o=Gr(p,o),v){case 0:a=wp(null,a,p,o,u);break e;case 1:a=E2(null,a,p,o,u);break e;case 11:a=x2(null,a,p,o,u);break e;case 14:a=_2(null,a,p,Gr(p.type,o),u);break e}throw Error(n(306,p,""))}return a;case 0:return p=a.type,v=a.pendingProps,v=a.elementType===p?v:Gr(p,v),wp(o,a,p,v,u);case 1:return p=a.type,v=a.pendingProps,v=a.elementType===p?v:Gr(p,v),E2(o,a,p,v,u);case 3:e:{if(I2(a),o===null)throw Error(n(387));p=a.pendingProps,b=a.memoizedState,v=b.element,U1(o,a),dd(a,p,null,u);var k=a.memoizedState;if(p=k.element,b.isDehydrated)if(b={element:p,isDehydrated:!1,cache:k.cache,pendingSuspenseBoundaries:k.pendingSuspenseBoundaries,transitions:k.transitions},a.updateQueue.baseState=b,a.memoizedState=b,a.flags&256){v=Ua(Error(n(423)),a),a=P2(o,a,p,u,v);break e}else if(p!==v){v=Ua(Error(n(424)),a),a=P2(o,a,p,u,v);break e}else for(sr=Fo(a.stateNode.containerInfo.firstChild),or=a,Lt=!0,Wr=null,u=j1(a,null,p,u),a.child=u;u;)u.flags=u.flags&-3|4096,u=u.sibling;else{if(Oa(),p===v){a=Yi(o,a,u);break e}Rn(o,a,p,u)}a=a.child}return a;case 5:return W1(a),o===null&&Xh(a),p=a.type,v=a.pendingProps,b=o!==null?o.memoizedProps:null,k=v.children,jh(p,v)?k=null:b!==null&&jh(p,b)&&(a.flags|=32),C2(o,a),Rn(o,a,k,u),a.child;case 6:return o===null&&Xh(a),null;case 13:return L2(o,a,u);case 4:return rp(a,a.stateNode.containerInfo),p=a.pendingProps,o===null?a.child=$a(a,null,p,u):Rn(o,a,p,u),a.child;case 11:return p=a.type,v=a.pendingProps,v=a.elementType===p?v:Gr(p,v),x2(o,a,p,v,u);case 7:return Rn(o,a,a.pendingProps,u),a.child;case 8:return Rn(o,a,a.pendingProps.children,u),a.child;case 12:return Rn(o,a,a.pendingProps.children,u),a.child;case 10:e:{if(p=a.type._context,v=a.pendingProps,b=a.memoizedProps,k=v.value,bt(ld,p._currentValue),p._currentValue=k,b!==null)if(Hr(b.value,k)){if(b.children===v.children&&!Vn.current){a=Yi(o,a,u);break e}}else for(b=a.child,b!==null&&(b.return=a);b!==null;){var T=b.dependencies;if(T!==null){k=b.child;for(var M=T.firstContext;M!==null;){if(M.context===p){if(b.tag===1){M=Qi(-1,u&-u),M.tag=2;var q=b.updateQueue;if(q!==null){q=q.shared;var ae=q.pending;ae===null?M.next=M:(M.next=ae.next,ae.next=M),q.pending=M}}b.lanes|=u,M=b.alternate,M!==null&&(M.lanes|=u),ep(b.return,u,a),T.lanes|=u;break}M=M.next}}else if(b.tag===10)k=b.type===a.type?null:b.child;else if(b.tag===18){if(k=b.return,k===null)throw Error(n(341));k.lanes|=u,T=k.alternate,T!==null&&(T.lanes|=u),ep(k,u,a),k=b.sibling}else k=b.child;if(k!==null)k.return=b;else for(k=b;k!==null;){if(k===a){k=null;break}if(b=k.sibling,b!==null){b.return=k.return,k=b;break}k=k.return}b=k}Rn(o,a,v.children,u),a=a.child}return a;case 9:return v=a.type,p=a.pendingProps.children,ja(a,u),v=kr(v),p=p(v),a.flags|=1,Rn(o,a,p,u),a.child;case 14:return p=a.type,v=Gr(p,a.pendingProps),v=Gr(p.type,v),_2(o,a,p,v,u);case 15:return k2(o,a,a.type,a.pendingProps,u);case 17:return p=a.type,v=a.pendingProps,v=a.elementType===p?v:Gr(p,v),bd(o,a),a.tag=1,Un(p)?(o=!0,nd(a)):o=!1,ja(a,u),p2(a,p,v),gp(a,p,v,u),bp(null,a,p,!0,o,u);case 19:return A2(o,a,u);case 22:return S2(o,a,u)}throw Error(n(156,a.tag))};function tv(o,a){return Ru(o,a)}function uC(o,a,u,p){this.tag=o,this.key=u,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=a,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=p,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Er(o,a,u,p){return new uC(o,a,u,p)}function jp(o){return o=o.prototype,!(!o||!o.isReactComponent)}function dC(o){if(typeof o=="function")return jp(o)?1:0;if(o!=null){if(o=o.$$typeof,o===te)return 11;if(o===K)return 14}return 2}function Go(o,a){var u=o.alternate;return u===null?(u=Er(o.tag,a,o.key,o.mode),u.elementType=o.elementType,u.type=o.type,u.stateNode=o.stateNode,u.alternate=o,o.alternate=u):(u.pendingProps=a,u.type=o.type,u.flags=0,u.subtreeFlags=0,u.deletions=null),u.flags=o.flags&14680064,u.childLanes=o.childLanes,u.lanes=o.lanes,u.child=o.child,u.memoizedProps=o.memoizedProps,u.memoizedState=o.memoizedState,u.updateQueue=o.updateQueue,a=o.dependencies,u.dependencies=a===null?null:{lanes:a.lanes,firstContext:a.firstContext},u.sibling=o.sibling,u.index=o.index,u.ref=o.ref,u}function Ad(o,a,u,p,v,b){var k=2;if(p=o,typeof o=="function")jp(o)&&(k=1);else if(typeof o=="string")k=5;else e:switch(o){case U:return zs(u.children,v,b,a);case X:k=8,v|=8;break;case H:return o=Er(12,u,a,v|2),o.elementType=H,o.lanes=b,o;case Q:return o=Er(13,u,a,v),o.elementType=Q,o.lanes=b,o;case ee:return o=Er(19,u,a,v),o.elementType=ee,o.lanes=b,o;case ie:return Td(u,v,b,a);default:if(typeof o=="object"&&o!==null)switch(o.$$typeof){case re:k=10;break e;case de:k=9;break e;case te:k=11;break e;case K:k=14;break e;case oe:k=16,p=null;break e}throw Error(n(130,o==null?o:typeof o,""))}return a=Er(k,u,a,v),a.elementType=o,a.type=p,a.lanes=b,a}function zs(o,a,u,p){return o=Er(7,o,p,a),o.lanes=u,o}function Td(o,a,u,p){return o=Er(22,o,p,a),o.elementType=ie,o.lanes=u,o.stateNode={isHidden:!1},o}function Vp(o,a,u){return o=Er(6,o,null,a),o.lanes=u,o}function Up(o,a,u){return a=Er(4,o.children!==null?o.children:[],o.key,a),a.lanes=u,a.stateNode={containerInfo:o.containerInfo,pendingChildren:null,implementation:o.implementation},a}function fC(o,a,u,p,v){this.tag=a,this.containerInfo=o,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=wr(0),this.expirationTimes=wr(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=wr(0),this.identifierPrefix=p,this.onRecoverableError=v,this.mutableSourceEagerHydrationData=null}function zp(o,a,u,p,v,b,k,T,M){return o=new fC(o,a,u,T,M),a===1?(a=1,b===!0&&(a|=8)):a=0,b=Er(3,null,null,a),o.current=b,b.stateNode=o,b.memoizedState={element:p,isDehydrated:u,cache:null,transitions:null,pendingSuspenseBoundaries:null},np(b),o}function hC(o,a,u){var p=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:R,key:p==null?null:""+p,children:o,containerInfo:a,implementation:u}}function nv(o){if(!o)return Oo;o=o._reactInternals;e:{if(vn(o)!==o||o.tag!==1)throw Error(n(170));var a=o;do{switch(a.tag){case 3:a=a.stateNode.context;break e;case 1:if(Un(a.type)){a=a.stateNode.__reactInternalMemoizedMergedChildContext;break e}}a=a.return}while(a!==null);throw Error(n(171))}if(o.tag===1){var u=o.type;if(Un(u))return D1(o,u,a)}return a}function rv(o,a,u,p,v,b,k,T,M){return o=zp(u,p,!0,o,v,b,k,T,M),o.context=nv(null),u=o.current,p=Nn(),v=Ho(u),b=Qi(p,v),b.callback=a??null,jo(u,b,v),o.current.lanes=v,di(o,v,p),Wn(o,p),o}function Rd(o,a,u,p){var v=a.current,b=Nn(),k=Ho(v);return u=nv(u),a.context===null?a.context=u:a.pendingContext=u,a=Qi(b,k),a.payload={element:o},p=p===void 0?null:p,p!==null&&(a.callback=p),o=jo(v,a,k),o!==null&&(Xr(o,v,k,b),ud(o,v,k)),k}function Nd(o){if(o=o.current,!o.child)return null;switch(o.child.tag){case 5:return o.child.stateNode;default:return o.child.stateNode}}function iv(o,a){if(o=o.memoizedState,o!==null&&o.dehydrated!==null){var u=o.retryLane;o.retryLane=u!==0&&u<a?u:a}}function Hp(o,a){iv(o,a),(o=o.alternate)&&iv(o,a)}function pC(){return null}var ov=typeof reportError=="function"?reportError:function(o){console.error(o)};function Wp(o){this._internalRoot=o}Fd.prototype.render=Wp.prototype.render=function(o){var a=this._internalRoot;if(a===null)throw Error(n(409));Rd(o,a,null,null)},Fd.prototype.unmount=Wp.prototype.unmount=function(){var o=this._internalRoot;if(o!==null){this._internalRoot=null;var a=o.containerInfo;js(function(){Rd(null,o,null,null)}),a[Wi]=null}};function Fd(o){this._internalRoot=o}Fd.prototype.unstable_scheduleHydration=function(o){if(o){var a=$u();o={blockedOn:null,target:o,priority:a};for(var u=0;u<pi.length&&a!==0&&a<pi[u].priority;u++);pi.splice(u,0,o),u===0&&ju(o)}};function Gp(o){return!(!o||o.nodeType!==1&&o.nodeType!==9&&o.nodeType!==11)}function Md(o){return!(!o||o.nodeType!==1&&o.nodeType!==9&&o.nodeType!==11&&(o.nodeType!==8||o.nodeValue!==" react-mount-point-unstable "))}function sv(){}function mC(o,a,u,p,v){if(v){if(typeof p=="function"){var b=p;p=function(){var q=Nd(k);b.call(q)}}var k=rv(a,p,o,0,null,!1,!1,"",sv);return o._reactRootContainer=k,o[Wi]=k.current,sc(o.nodeType===8?o.parentNode:o),js(),k}for(;v=o.lastChild;)o.removeChild(v);if(typeof p=="function"){var T=p;p=function(){var q=Nd(M);T.call(q)}}var M=zp(o,0,!1,null,null,!1,!1,"",sv);return o._reactRootContainer=M,o[Wi]=M.current,sc(o.nodeType===8?o.parentNode:o),js(function(){Rd(a,M,u,p)}),M}function Od(o,a,u,p,v){var b=u._reactRootContainer;if(b){var k=b;if(typeof v=="function"){var T=v;v=function(){var M=Nd(k);T.call(M)}}Rd(a,k,o,v)}else k=mC(u,a,o,v,p);return Nd(k)}ya=function(o){switch(o.tag){case 3:var a=o.stateNode;if(a.current.memoizedState.isDehydrated){var u=Eo(a.pendingLanes);u!==0&&(va(a,u|1),Wn(a,tt()),(it&6)===0&&(Wa=tt()+500,$o()))}break;case 13:js(function(){var p=Xi(o,1);if(p!==null){var v=Nn();Xr(p,o,1,v)}}),Hp(o,1)}},wa=function(o){if(o.tag===13){var a=Xi(o,134217728);if(a!==null){var u=Nn();Xr(a,o,134217728,u)}Hp(o,134217728)}},Wl=function(o){if(o.tag===13){var a=Ho(o),u=Xi(o,a);if(u!==null){var p=Nn();Xr(u,o,a,p)}Hp(o,a)}},$u=function(){return nt},Bu=function(o,a){var u=nt;try{return nt=o,a()}finally{nt=u}},ws=function(o,a,u){switch(a){case"input":if(Mr(o,u),a=u.name,u.type==="radio"&&a!=null){for(u=o;u.parentNode;)u=u.parentNode;for(u=u.querySelectorAll("input[name="+JSON.stringify(""+a)+'][type="radio"]'),a=0;a<u.length;a++){var p=u[a];if(p!==o&&p.form===o.form){var v=ed(p);if(!v)throw Error(n(90));mt(p),Mr(p,v)}}}break;case"textarea":si(o,u);break;case"select":a=u.value,a!=null&&oi(o,!!u.multiple,a,!1)}},Nt=Op,sn=js;var gC={usingClientEntryPoint:!1,Events:[cc,Ta,ed,je,ft,Op]},kc={findFiberByHostInstance:Ts,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},vC={bundleType:kc.bundleType,version:kc.version,rendererPackageName:kc.rendererPackageName,rendererConfig:kc.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:L.ReactCurrentDispatcher,findHostInstanceByFiber:function(o){return o=ko(o),o===null?null:o.stateNode},findFiberByHostInstance:kc.findFiberByHostInstance||pC,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var $d=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!$d.isDisabled&&$d.supportsFiber)try{So=$d.inject(vC),yr=$d}catch{}}return Gn.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=gC,Gn.createPortal=function(o,a){var u=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Gp(a))throw Error(n(200));return hC(o,a,null,u)},Gn.createRoot=function(o,a){if(!Gp(o))throw Error(n(299));var u=!1,p="",v=ov;return a!=null&&(a.unstable_strictMode===!0&&(u=!0),a.identifierPrefix!==void 0&&(p=a.identifierPrefix),a.onRecoverableError!==void 0&&(v=a.onRecoverableError)),a=zp(o,1,!1,null,null,u,!1,p,v),o[Wi]=a.current,sc(o.nodeType===8?o.parentNode:o),new Wp(a)},Gn.findDOMNode=function(o){if(o==null)return null;if(o.nodeType===1)return o;var a=o._reactInternals;if(a===void 0)throw typeof o.render=="function"?Error(n(188)):(o=Object.keys(o).join(","),Error(n(268,o)));return o=ko(a),o=o===null?null:o.stateNode,o},Gn.flushSync=function(o){return js(o)},Gn.hydrate=function(o,a,u){if(!Md(a))throw Error(n(200));return Od(null,o,a,!0,u)},Gn.hydrateRoot=function(o,a,u){if(!Gp(o))throw Error(n(405));var p=u!=null&&u.hydratedSources||null,v=!1,b="",k=ov;if(u!=null&&(u.unstable_strictMode===!0&&(v=!0),u.identifierPrefix!==void 0&&(b=u.identifierPrefix),u.onRecoverableError!==void 0&&(k=u.onRecoverableError)),a=rv(a,null,o,1,u??null,v,!1,b,k),o[Wi]=a.current,sc(o),p)for(o=0;o<p.length;o++)u=p[o],v=u._getVersion,v=v(u._source),a.mutableSourceEagerHydrationData==null?a.mutableSourceEagerHydrationData=[u,v]:a.mutableSourceEagerHydrationData.push(u,v);return new Fd(a)},Gn.render=function(o,a,u){if(!Md(a))throw Error(n(200));return Od(null,o,a,!1,u)},Gn.unmountComponentAtNode=function(o){if(!Md(o))throw Error(n(40));return o._reactRootContainer?(js(function(){Od(null,null,o,!1,function(){o._reactRootContainer=null,o[Wi]=null})}),!0):!1},Gn.unstable_batchedUpdates=Op,Gn.unstable_renderSubtreeIntoContainer=function(o,a,u,p){if(!Md(u))throw Error(n(200));if(o==null||o._reactInternals===void 0)throw Error(n(38));return Od(o,a,u,!1,p)},Gn.version="18.3.1-next-f1338f8080-20240426",Gn}var gv;function Vb(){if(gv)return Qp.exports;gv=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),Qp.exports=PC(),Qp.exports}var vv;function LC(){if(vv)return Bd;vv=1;var e=Vb();return Bd.createRoot=e.createRoot,Bd.hydrateRoot=e.hydrateRoot,Bd}var DC=LC();/**
42
+ * react-router v7.13.1
43
+ *
44
+ * Copyright (c) Remix Software Inc.
45
+ *
46
+ * This source code is licensed under the MIT license found in the
47
+ * LICENSE.md file in the root directory of this source tree.
48
+ *
49
+ * @license MIT
50
+ */var yv="popstate";function wv(e){return typeof e=="object"&&e!=null&&"pathname"in e&&"search"in e&&"hash"in e&&"state"in e&&"key"in e}function AC(e={}){function t(r,i){var f;let s=(f=i.state)==null?void 0:f.masked,{pathname:l,search:c,hash:d}=s||r.location;return qm("",{pathname:l,search:c,hash:d},i.state&&i.state.usr||null,i.state&&i.state.key||"default",s?{pathname:r.location.pathname,search:r.location.search,hash:r.location.hash}:void 0)}function n(r,i){return typeof i=="string"?i:qc(i)}return RC(t,n,null,e)}function Rt(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function Mi(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function TC(){return Math.random().toString(36).substring(2,10)}function bv(e,t){return{usr:e.state,key:e.key,idx:t,masked:e.unstable_mask?{pathname:e.pathname,search:e.search,hash:e.hash}:void 0}}function qm(e,t,n=null,r,i){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?Nl(t):t,state:n,key:t&&t.key||r||TC(),unstable_mask:i}}function qc({pathname:e="/",search:t="",hash:n=""}){return t&&t!=="?"&&(e+=t.charAt(0)==="?"?t:"?"+t),n&&n!=="#"&&(e+=n.charAt(0)==="#"?n:"#"+n),e}function Nl(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substring(r),e=e.substring(0,r)),e&&(t.pathname=e)}return t}function RC(e,t,n,r={}){let{window:i=document.defaultView,v5Compat:s=!1}=r,l=i.history,c="POP",d=null,f=m();f==null&&(f=0,l.replaceState({...l.state,idx:f},""));function m(){return(l.state||{idx:null}).idx}function h(){c="POP";let C=m(),I=C==null?null:C-f;f=C,d&&d({action:c,location:_.location,delta:I})}function g(C,I){c="PUSH";let E=wv(C)?C:qm(_.location,C,I);f=m()+1;let S=bv(E,f),L=_.createHref(E.unstable_mask||E);try{l.pushState(S,"",L)}catch(A){if(A instanceof DOMException&&A.name==="DataCloneError")throw A;i.location.assign(L)}s&&d&&d({action:c,location:_.location,delta:1})}function y(C,I){c="REPLACE";let E=wv(C)?C:qm(_.location,C,I);f=m();let S=bv(E,f),L=_.createHref(E.unstable_mask||E);l.replaceState(S,"",L),s&&d&&d({action:c,location:_.location,delta:0})}function w(C){return NC(C)}let _={get action(){return c},get location(){return e(i,l)},listen(C){if(d)throw new Error("A history only accepts one active listener");return i.addEventListener(yv,h),d=C,()=>{i.removeEventListener(yv,h),d=null}},createHref(C){return t(i,C)},createURL:w,encodeLocation(C){let I=w(C);return{pathname:I.pathname,search:I.search,hash:I.hash}},push:g,replace:y,go(C){return l.go(C)}};return _}function NC(e,t=!1){let n="http://localhost";typeof window<"u"&&(n=window.location.origin!=="null"?window.location.origin:window.location.href),Rt(n,"No window.location.(origin|href) available to create URL");let r=typeof e=="string"?e:qc(e);return r=r.replace(/ $/,"%20"),!t&&r.startsWith("//")&&(r=n+r),new URL(r,n)}function Ub(e,t,n="/"){return FC(e,t,n,!1)}function FC(e,t,n,r){let i=typeof t=="string"?Nl(t):t,s=bo(i.pathname||"/",n);if(s==null)return null;let l=zb(e);MC(l);let c=null;for(let d=0;c==null&&d<l.length;++d){let f=qC(s);c=WC(l[d],f,r)}return c}function zb(e,t=[],n=[],r="",i=!1){let s=(l,c,d=i,f)=>{let m={relativePath:f===void 0?l.path||"":f,caseSensitive:l.caseSensitive===!0,childrenIndex:c,route:l};if(m.relativePath.startsWith("/")){if(!m.relativePath.startsWith(r)&&d)return;Rt(m.relativePath.startsWith(r),`Absolute route path "${m.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),m.relativePath=m.relativePath.slice(r.length)}let h=Ri([r,m.relativePath]),g=n.concat(m);l.children&&l.children.length>0&&(Rt(l.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${h}".`),zb(l.children,t,g,h,d)),!(l.path==null&&!l.index)&&t.push({path:h,score:zC(h,l.index),routesMeta:g})};return e.forEach((l,c)=>{var d;if(l.path===""||!((d=l.path)!=null&&d.includes("?")))s(l,c);else for(let f of Hb(l.path))s(l,c,!0,f)}),t}function Hb(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,i=n.endsWith("?"),s=n.replace(/\?$/,"");if(r.length===0)return i?[s,""]:[s];let l=Hb(r.join("/")),c=[];return c.push(...l.map(d=>d===""?s:[s,d].join("/"))),i&&c.push(...l),c.map(d=>e.startsWith("/")&&d===""?"/":d)}function MC(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:HC(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}var OC=/^:[\w-]+$/,$C=3,BC=2,jC=1,VC=10,UC=-2,xv=e=>e==="*";function zC(e,t){let n=e.split("/"),r=n.length;return n.some(xv)&&(r+=UC),t&&(r+=BC),n.filter(i=>!xv(i)).reduce((i,s)=>i+(OC.test(s)?$C:s===""?jC:VC),r)}function HC(e,t){return e.length===t.length&&e.slice(0,-1).every((r,i)=>r===t[i])?e[e.length-1]-t[t.length-1]:0}function WC(e,t,n=!1){let{routesMeta:r}=e,i={},s="/",l=[];for(let c=0;c<r.length;++c){let d=r[c],f=c===r.length-1,m=s==="/"?t:t.slice(s.length)||"/",h=Rf({path:d.relativePath,caseSensitive:d.caseSensitive,end:f},m),g=d.route;if(!h&&f&&n&&!r[r.length-1].route.index&&(h=Rf({path:d.relativePath,caseSensitive:d.caseSensitive,end:!1},m)),!h)return null;Object.assign(i,h.params),l.push({params:i,pathname:Ri([s,h.pathname]),pathnameBase:YC(Ri([s,h.pathnameBase])),route:g}),h.pathnameBase!=="/"&&(s=Ri([s,h.pathnameBase]))}return l}function Rf(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=GC(e.path,e.caseSensitive,e.end),i=t.match(n);if(!i)return null;let s=i[0],l=s.replace(/(.)\/+$/,"$1"),c=i.slice(1);return{params:r.reduce((f,{paramName:m,isOptional:h},g)=>{if(m==="*"){let w=c[g]||"";l=s.slice(0,s.length-w.length).replace(/(.)\/+$/,"$1")}const y=c[g];return h&&!y?f[m]=void 0:f[m]=(y||"").replace(/%2F/g,"/"),f},{}),pathname:s,pathnameBase:l,pattern:e}}function GC(e,t=!1,n=!0){Mi(e==="*"||!e.endsWith("*")||e.endsWith("/*"),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,"/*")}".`);let r=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(l,c,d,f,m)=>{if(r.push({paramName:c,isOptional:d!=null}),d){let h=m.charAt(f+l.length);return h&&h!=="/"?"/([^\\/]*)":"(?:/([^\\/]*))?"}return"/([^\\/]+)"}).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return e.endsWith("*")?(r.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),r]}function qC(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Mi(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function bo(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}var KC=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i;function XC(e,t="/"){let{pathname:n,search:r="",hash:i=""}=typeof e=="string"?Nl(e):e,s;return n?(n=n.replace(/\/\/+/g,"/"),n.startsWith("/")?s=_v(n.substring(1),"/"):s=_v(n,t)):s=t,{pathname:s,search:JC(r),hash:ZC(i)}}function _v(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(i=>{i===".."?n.length>1&&n.pop():i!=="."&&n.push(i)}),n.length>1?n.join("/"):"/"}function Zp(e,t,n,r){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(r)}]. Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function QC(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function Wb(e){let t=QC(e);return t.map((n,r)=>r===t.length-1?n.pathname:n.pathnameBase)}function u0(e,t,n,r=!1){let i;typeof e=="string"?i=Nl(e):(i={...e},Rt(!i.pathname||!i.pathname.includes("?"),Zp("?","pathname","search",i)),Rt(!i.pathname||!i.pathname.includes("#"),Zp("#","pathname","hash",i)),Rt(!i.search||!i.search.includes("#"),Zp("#","search","hash",i)));let s=e===""||i.pathname==="",l=s?"/":i.pathname,c;if(l==null)c=n;else{let h=t.length-1;if(!r&&l.startsWith("..")){let g=l.split("/");for(;g[0]==="..";)g.shift(),h-=1;i.pathname=g.join("/")}c=h>=0?t[h]:"/"}let d=XC(i,c),f=l&&l!=="/"&&l.endsWith("/"),m=(s||l===".")&&n.endsWith("/");return!d.pathname.endsWith("/")&&(f||m)&&(d.pathname+="/"),d}var Ri=e=>e.join("/").replace(/\/\/+/g,"/"),YC=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),JC=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,ZC=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e,eE=class{constructor(e,t,n,r=!1){this.status=e,this.statusText=t||"",this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}};function tE(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}function nE(e){return e.map(t=>t.route.path).filter(Boolean).join("/").replace(/\/\/*/g,"/")||"/"}var Gb=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function qb(e,t){let n=e;if(typeof n!="string"||!KC.test(n))return{absoluteURL:void 0,isExternal:!1,to:n};let r=n,i=!1;if(Gb)try{let s=new URL(window.location.href),l=n.startsWith("//")?new URL(s.protocol+n):new URL(n),c=bo(l.pathname,t);l.origin===s.origin&&c!=null?n=c+l.search+l.hash:i=!0}catch{Mi(!1,`<Link to="${n}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:r,isExternal:i,to:n}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var Kb=["POST","PUT","PATCH","DELETE"];new Set(Kb);var rE=["GET",...Kb];new Set(rE);var Fl=B.createContext(null);Fl.displayName="DataRouter";var ih=B.createContext(null);ih.displayName="DataRouterState";var iE=B.createContext(!1),Xb=B.createContext({isTransitioning:!1});Xb.displayName="ViewTransition";var oE=B.createContext(new Map);oE.displayName="Fetchers";var sE=B.createContext(null);sE.displayName="Await";var Fr=B.createContext(null);Fr.displayName="Navigation";var Su=B.createContext(null);Su.displayName="Location";var xo=B.createContext({outlet:null,matches:[],isDataRoute:!1});xo.displayName="Route";var d0=B.createContext(null);d0.displayName="RouteError";var Qb="REACT_ROUTER_ERROR",aE="REDIRECT",lE="ROUTE_ERROR_RESPONSE";function cE(e){if(e.startsWith(`${Qb}:${aE}:{`))try{let t=JSON.parse(e.slice(28));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.location=="string"&&typeof t.reloadDocument=="boolean"&&typeof t.replace=="boolean")return t}catch{}}function uE(e){if(e.startsWith(`${Qb}:${lE}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string")return new eE(t.status,t.statusText,t.data)}catch{}}function dE(e,{relative:t}={}){Rt(Cu(),"useHref() may be used only in the context of a <Router> component.");let{basename:n,navigator:r}=B.useContext(Fr),{hash:i,pathname:s,search:l}=Eu(e,{relative:t}),c=s;return n!=="/"&&(c=s==="/"?n:Ri([n,s])),r.createHref({pathname:c,search:l,hash:i})}function Cu(){return B.useContext(Su)!=null}function gs(){return Rt(Cu(),"useLocation() may be used only in the context of a <Router> component."),B.useContext(Su).location}var Yb="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function Jb(e){B.useContext(Fr).static||B.useLayoutEffect(e)}function Zb(){let{isDataRoute:e}=B.useContext(xo);return e?SE():fE()}function fE(){Rt(Cu(),"useNavigate() may be used only in the context of a <Router> component.");let e=B.useContext(Fl),{basename:t,navigator:n}=B.useContext(Fr),{matches:r}=B.useContext(xo),{pathname:i}=gs(),s=JSON.stringify(Wb(r)),l=B.useRef(!1);return Jb(()=>{l.current=!0}),B.useCallback((d,f={})=>{if(Mi(l.current,Yb),!l.current)return;if(typeof d=="number"){n.go(d);return}let m=u0(d,JSON.parse(s),i,f.relative==="path");e==null&&t!=="/"&&(m.pathname=m.pathname==="/"?t:Ri([t,m.pathname])),(f.replace?n.replace:n.push)(m,f.state,f)},[t,n,s,i,e])}B.createContext(null);function Eu(e,{relative:t}={}){let{matches:n}=B.useContext(xo),{pathname:r}=gs(),i=JSON.stringify(Wb(n));return B.useMemo(()=>u0(e,JSON.parse(i),r,t==="path"),[e,i,r,t])}function hE(e,t){return ex(e,t)}function ex(e,t,n){var C;Rt(Cu(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:r}=B.useContext(Fr),{matches:i}=B.useContext(xo),s=i[i.length-1],l=s?s.params:{},c=s?s.pathname:"/",d=s?s.pathnameBase:"/",f=s&&s.route;{let I=f&&f.path||"";nx(c,!f||I.endsWith("*")||I.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${c}" (under <Route path="${I}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
51
+
52
+ Please change the parent <Route path="${I}"> to <Route path="${I==="/"?"*":`${I}/*`}">.`)}let m=gs(),h;if(t){let I=typeof t=="string"?Nl(t):t;Rt(d==="/"||((C=I.pathname)==null?void 0:C.startsWith(d)),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${d}" but pathname "${I.pathname}" was given in the \`location\` prop.`),h=I}else h=m;let g=h.pathname||"/",y=g;if(d!=="/"){let I=d.replace(/^\//,"").split("/");y="/"+g.replace(/^\//,"").split("/").slice(I.length).join("/")}let w=Ub(e,{pathname:y});Mi(f||w!=null,`No routes matched location "${h.pathname}${h.search}${h.hash}" `),Mi(w==null||w[w.length-1].route.element!==void 0||w[w.length-1].route.Component!==void 0||w[w.length-1].route.lazy!==void 0,`Matched leaf route at location "${h.pathname}${h.search}${h.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let _=yE(w&&w.map(I=>Object.assign({},I,{params:Object.assign({},l,I.params),pathname:Ri([d,r.encodeLocation?r.encodeLocation(I.pathname.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:I.pathname]),pathnameBase:I.pathnameBase==="/"?d:Ri([d,r.encodeLocation?r.encodeLocation(I.pathnameBase.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:I.pathnameBase])})),i,n);return t&&_?B.createElement(Su.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",unstable_mask:void 0,...h},navigationType:"POP"}},_):_}function pE(){let e=kE(),t=tE(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,r="rgba(200,200,200, 0.5)",i={padding:"0.5rem",backgroundColor:r},s={padding:"2px 4px",backgroundColor:r},l=null;return console.error("Error handled by React Router default ErrorBoundary:",e),l=B.createElement(B.Fragment,null,B.createElement("p",null,"💿 Hey developer 👋"),B.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",B.createElement("code",{style:s},"ErrorBoundary")," or"," ",B.createElement("code",{style:s},"errorElement")," prop on your route.")),B.createElement(B.Fragment,null,B.createElement("h2",null,"Unexpected Application Error!"),B.createElement("h3",{style:{fontStyle:"italic"}},t),n?B.createElement("pre",{style:i},n):null,l)}var mE=B.createElement(pE,null),tx=class extends B.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error!==void 0?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error("React Router caught the following error during render",e)}render(){let e=this.state.error;if(this.context&&typeof e=="object"&&e&&"digest"in e&&typeof e.digest=="string"){const n=uE(e.digest);n&&(e=n)}let t=e!==void 0?B.createElement(xo.Provider,{value:this.props.routeContext},B.createElement(d0.Provider,{value:e,children:this.props.component})):this.props.children;return this.context?B.createElement(gE,{error:e},t):t}};tx.contextType=iE;var em=new WeakMap;function gE({children:e,error:t}){let{basename:n}=B.useContext(Fr);if(typeof t=="object"&&t&&"digest"in t&&typeof t.digest=="string"){let r=cE(t.digest);if(r){let i=em.get(t);if(i)throw i;let s=qb(r.location,n);if(Gb&&!em.get(t))if(s.isExternal||r.reloadDocument)window.location.href=s.absoluteURL||s.to;else{const l=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(s.to,{replace:r.replace}));throw em.set(t,l),l}return B.createElement("meta",{httpEquiv:"refresh",content:`0;url=${s.absoluteURL||s.to}`})}}return e}function vE({routeContext:e,match:t,children:n}){let r=B.useContext(Fl);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),B.createElement(xo.Provider,{value:e},n)}function yE(e,t=[],n){let r=n==null?void 0:n.state;if(e==null){if(!r)return null;if(r.errors)e=r.matches;else if(t.length===0&&!r.initialized&&r.matches.length>0)e=r.matches;else return null}let i=e,s=r==null?void 0:r.errors;if(s!=null){let m=i.findIndex(h=>h.route.id&&(s==null?void 0:s[h.route.id])!==void 0);Rt(m>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(s).join(",")}`),i=i.slice(0,Math.min(i.length,m+1))}let l=!1,c=-1;if(n&&r){l=r.renderFallback;for(let m=0;m<i.length;m++){let h=i[m];if((h.route.HydrateFallback||h.route.hydrateFallbackElement)&&(c=m),h.route.id){let{loaderData:g,errors:y}=r,w=h.route.loader&&!g.hasOwnProperty(h.route.id)&&(!y||y[h.route.id]===void 0);if(h.route.lazy||w){n.isStatic&&(l=!0),c>=0?i=i.slice(0,c+1):i=[i[0]];break}}}}let d=n==null?void 0:n.onError,f=r&&d?(m,h)=>{var g,y;d(m,{location:r.location,params:((y=(g=r.matches)==null?void 0:g[0])==null?void 0:y.params)??{},unstable_pattern:nE(r.matches),errorInfo:h})}:void 0;return i.reduceRight((m,h,g)=>{let y,w=!1,_=null,C=null;r&&(y=s&&h.route.id?s[h.route.id]:void 0,_=h.route.errorElement||mE,l&&(c<0&&g===0?(nx("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),w=!0,C=null):c===g&&(w=!0,C=h.route.hydrateFallbackElement||null)));let I=t.concat(i.slice(0,g+1)),E=()=>{let S;return y?S=_:w?S=C:h.route.Component?S=B.createElement(h.route.Component,null):h.route.element?S=h.route.element:S=m,B.createElement(vE,{match:h,routeContext:{outlet:m,matches:I,isDataRoute:r!=null},children:S})};return r&&(h.route.ErrorBoundary||h.route.errorElement||g===0)?B.createElement(tx,{location:r.location,revalidation:r.revalidation,component:_,error:y,children:E(),routeContext:{outlet:null,matches:I,isDataRoute:!0},onError:f}):E()},null)}function f0(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function wE(e){let t=B.useContext(Fl);return Rt(t,f0(e)),t}function bE(e){let t=B.useContext(ih);return Rt(t,f0(e)),t}function xE(e){let t=B.useContext(xo);return Rt(t,f0(e)),t}function h0(e){let t=xE(e),n=t.matches[t.matches.length-1];return Rt(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function _E(){return h0("useRouteId")}function kE(){var r;let e=B.useContext(d0),t=bE("useRouteError"),n=h0("useRouteError");return e!==void 0?e:(r=t.errors)==null?void 0:r[n]}function SE(){let{router:e}=wE("useNavigate"),t=h0("useNavigate"),n=B.useRef(!1);return Jb(()=>{n.current=!0}),B.useCallback(async(i,s={})=>{Mi(n.current,Yb),n.current&&(typeof i=="number"?await e.navigate(i):await e.navigate(i,{fromRouteId:t,...s}))},[e,t])}var kv={};function nx(e,t,n){!t&&!kv[e]&&(kv[e]=!0,Mi(!1,n))}B.memo(CE);function CE({routes:e,future:t,state:n,isStatic:r,onError:i}){return ex(e,void 0,{state:n,isStatic:r,onError:i})}function Rc(e){Rt(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}function EE({basename:e="/",children:t=null,location:n,navigationType:r="POP",navigator:i,static:s=!1,unstable_useTransitions:l}){Rt(!Cu(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let c=e.replace(/^\/*/,"/"),d=B.useMemo(()=>({basename:c,navigator:i,static:s,unstable_useTransitions:l,future:{}}),[c,i,s,l]);typeof n=="string"&&(n=Nl(n));let{pathname:f="/",search:m="",hash:h="",state:g=null,key:y="default",unstable_mask:w}=n,_=B.useMemo(()=>{let C=bo(f,c);return C==null?null:{location:{pathname:C,search:m,hash:h,state:g,key:y,unstable_mask:w},navigationType:r}},[c,f,m,h,g,y,r,w]);return Mi(_!=null,`<Router basename="${c}"> is not able to match the URL "${f}${m}${h}" because it does not start with the basename, so the <Router> won't render anything.`),_==null?null:B.createElement(Fr.Provider,{value:d},B.createElement(Su.Provider,{children:t,value:_}))}function IE({children:e,location:t}){return hE(Km(e),t)}function Km(e,t=[]){let n=[];return B.Children.forEach(e,(r,i)=>{if(!B.isValidElement(r))return;let s=[...t,i];if(r.type===B.Fragment){n.push.apply(n,Km(r.props.children,s));return}Rt(r.type===Rc,`[${typeof r.type=="string"?r.type:r.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),Rt(!r.props.index||!r.props.children,"An index route cannot have child routes.");let l={id:r.props.id||s.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,middleware:r.props.middleware,loader:r.props.loader,action:r.props.action,hydrateFallbackElement:r.props.hydrateFallbackElement,HydrateFallback:r.props.HydrateFallback,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.hasErrorBoundary===!0||r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(l.children=Km(r.props.children,s)),n.push(l)}),n}var cf="get",uf="application/x-www-form-urlencoded";function oh(e){return typeof HTMLElement<"u"&&e instanceof HTMLElement}function PE(e){return oh(e)&&e.tagName.toLowerCase()==="button"}function LE(e){return oh(e)&&e.tagName.toLowerCase()==="form"}function DE(e){return oh(e)&&e.tagName.toLowerCase()==="input"}function AE(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function TE(e,t){return e.button===0&&(!t||t==="_self")&&!AE(e)}var jd=null;function RE(){if(jd===null)try{new FormData(document.createElement("form"),0),jd=!1}catch{jd=!0}return jd}var NE=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function tm(e){return e!=null&&!NE.has(e)?(Mi(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${uf}"`),null):e}function FE(e,t){let n,r,i,s,l;if(LE(e)){let c=e.getAttribute("action");r=c?bo(c,t):null,n=e.getAttribute("method")||cf,i=tm(e.getAttribute("enctype"))||uf,s=new FormData(e)}else if(PE(e)||DE(e)&&(e.type==="submit"||e.type==="image")){let c=e.form;if(c==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let d=e.getAttribute("formaction")||c.getAttribute("action");if(r=d?bo(d,t):null,n=e.getAttribute("formmethod")||c.getAttribute("method")||cf,i=tm(e.getAttribute("formenctype"))||tm(c.getAttribute("enctype"))||uf,s=new FormData(c,e),!RE()){let{name:f,type:m,value:h}=e;if(m==="image"){let g=f?`${f}.`:"";s.append(`${g}x`,"0"),s.append(`${g}y`,"0")}else f&&s.append(f,h)}}else{if(oh(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');n=cf,r=null,i=uf,l=e}return s&&i==="text/plain"&&(l=s,s=void 0),{action:r,method:n.toLowerCase(),encType:i,formData:s,body:l}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function p0(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function ME(e,t,n,r){let i=typeof e=="string"?new URL(e,typeof window>"u"?"server://singlefetch/":window.location.origin):e;return n?i.pathname.endsWith("/")?i.pathname=`${i.pathname}_.${r}`:i.pathname=`${i.pathname}.${r}`:i.pathname==="/"?i.pathname=`_root.${r}`:t&&bo(i.pathname,t)==="/"?i.pathname=`${t.replace(/\/$/,"")}/_root.${r}`:i.pathname=`${i.pathname.replace(/\/$/,"")}.${r}`,i}async function OE(e,t){if(e.id in t)return t[e.id];try{let n=await import(e.module);return t[e.id]=n,n}catch(n){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(n),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function $E(e){return e==null?!1:e.href==null?e.rel==="preload"&&typeof e.imageSrcSet=="string"&&typeof e.imageSizes=="string":typeof e.rel=="string"&&typeof e.href=="string"}async function BE(e,t,n){let r=await Promise.all(e.map(async i=>{let s=t.routes[i.route.id];if(s){let l=await OE(s,n);return l.links?l.links():[]}return[]}));return zE(r.flat(1).filter($E).filter(i=>i.rel==="stylesheet"||i.rel==="preload").map(i=>i.rel==="stylesheet"?{...i,rel:"prefetch",as:"style"}:{...i,rel:"prefetch"}))}function Sv(e,t,n,r,i,s){let l=(d,f)=>n[f]?d.route.id!==n[f].route.id:!0,c=(d,f)=>{var m;return n[f].pathname!==d.pathname||((m=n[f].route.path)==null?void 0:m.endsWith("*"))&&n[f].params["*"]!==d.params["*"]};return s==="assets"?t.filter((d,f)=>l(d,f)||c(d,f)):s==="data"?t.filter((d,f)=>{var h;let m=r.routes[d.route.id];if(!m||!m.hasLoader)return!1;if(l(d,f)||c(d,f))return!0;if(d.route.shouldRevalidate){let g=d.route.shouldRevalidate({currentUrl:new URL(i.pathname+i.search+i.hash,window.origin),currentParams:((h=n[0])==null?void 0:h.params)||{},nextUrl:new URL(e,window.origin),nextParams:d.params,defaultShouldRevalidate:!0});if(typeof g=="boolean")return g}return!0}):[]}function jE(e,t,{includeHydrateFallback:n}={}){return VE(e.map(r=>{let i=t.routes[r.route.id];if(!i)return[];let s=[i.module];return i.clientActionModule&&(s=s.concat(i.clientActionModule)),i.clientLoaderModule&&(s=s.concat(i.clientLoaderModule)),n&&i.hydrateFallbackModule&&(s=s.concat(i.hydrateFallbackModule)),i.imports&&(s=s.concat(i.imports)),s}).flat(1))}function VE(e){return[...new Set(e)]}function UE(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}function zE(e,t){let n=new Set;return new Set(t),e.reduce((r,i)=>{let s=JSON.stringify(UE(i));return n.has(s)||(n.add(s),r.push({key:s,link:i})),r},[])}function rx(){let e=B.useContext(Fl);return p0(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}function HE(){let e=B.useContext(ih);return p0(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}var m0=B.createContext(void 0);m0.displayName="FrameworkContext";function ix(){let e=B.useContext(m0);return p0(e,"You must render this element inside a <HydratedRouter> element"),e}function WE(e,t){let n=B.useContext(m0),[r,i]=B.useState(!1),[s,l]=B.useState(!1),{onFocus:c,onBlur:d,onMouseEnter:f,onMouseLeave:m,onTouchStart:h}=t,g=B.useRef(null);B.useEffect(()=>{if(e==="render"&&l(!0),e==="viewport"){let _=I=>{I.forEach(E=>{l(E.isIntersecting)})},C=new IntersectionObserver(_,{threshold:.5});return g.current&&C.observe(g.current),()=>{C.disconnect()}}},[e]),B.useEffect(()=>{if(r){let _=setTimeout(()=>{l(!0)},100);return()=>{clearTimeout(_)}}},[r]);let y=()=>{i(!0)},w=()=>{i(!1),l(!1)};return n?e!=="intent"?[s,g,{}]:[s,g,{onFocus:Cc(c,y),onBlur:Cc(d,w),onMouseEnter:Cc(f,y),onMouseLeave:Cc(m,w),onTouchStart:Cc(h,y)}]:[!1,g,{}]}function Cc(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function GE({page:e,...t}){let{router:n}=rx(),r=B.useMemo(()=>Ub(n.routes,e,n.basename),[n.routes,e,n.basename]);return r?B.createElement(KE,{page:e,matches:r,...t}):null}function qE(e){let{manifest:t,routeModules:n}=ix(),[r,i]=B.useState([]);return B.useEffect(()=>{let s=!1;return BE(e,t,n).then(l=>{s||i(l)}),()=>{s=!0}},[e,t,n]),r}function KE({page:e,matches:t,...n}){let r=gs(),{future:i,manifest:s,routeModules:l}=ix(),{basename:c}=rx(),{loaderData:d,matches:f}=HE(),m=B.useMemo(()=>Sv(e,t,f,s,r,"data"),[e,t,f,s,r]),h=B.useMemo(()=>Sv(e,t,f,s,r,"assets"),[e,t,f,s,r]),g=B.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let _=new Set,C=!1;if(t.forEach(E=>{var L;let S=s.routes[E.route.id];!S||!S.hasLoader||(!m.some(A=>A.route.id===E.route.id)&&E.route.id in d&&((L=l[E.route.id])!=null&&L.shouldRevalidate)||S.hasClientLoader?C=!0:_.add(E.route.id))}),_.size===0)return[];let I=ME(e,c,i.unstable_trailingSlashAwareDataRequests,"data");return C&&_.size>0&&I.searchParams.set("_routes",t.filter(E=>_.has(E.route.id)).map(E=>E.route.id).join(",")),[I.pathname+I.search]},[c,i.unstable_trailingSlashAwareDataRequests,d,r,s,m,t,e,l]),y=B.useMemo(()=>jE(h,s),[h,s]),w=qE(h);return B.createElement(B.Fragment,null,g.map(_=>B.createElement("link",{key:_,rel:"prefetch",as:"fetch",href:_,...n})),y.map(_=>B.createElement("link",{key:_,rel:"modulepreload",href:_,...n})),w.map(({key:_,link:C})=>B.createElement("link",{key:_,nonce:n.nonce,...C,crossOrigin:C.crossOrigin??n.crossOrigin})))}function XE(...e){return t=>{e.forEach(n=>{typeof n=="function"?n(t):n!=null&&(n.current=t)})}}var QE=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{QE&&(window.__reactRouterVersion="7.13.1")}catch{}function YE({basename:e,children:t,unstable_useTransitions:n,window:r}){let i=B.useRef();i.current==null&&(i.current=AC({window:r,v5Compat:!0}));let s=i.current,[l,c]=B.useState({action:s.action,location:s.location}),d=B.useCallback(f=>{n===!1?c(f):B.startTransition(()=>c(f))},[n]);return B.useLayoutEffect(()=>s.listen(d),[s,d]),B.createElement(EE,{basename:e,children:t,location:l.location,navigationType:l.action,navigator:s,unstable_useTransitions:n})}var ox=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,wo=B.forwardRef(function({onClick:t,discover:n="render",prefetch:r="none",relative:i,reloadDocument:s,replace:l,unstable_mask:c,state:d,target:f,to:m,preventScrollReset:h,viewTransition:g,unstable_defaultShouldRevalidate:y,...w},_){let{basename:C,navigator:I,unstable_useTransitions:E}=B.useContext(Fr),S=typeof m=="string"&&ox.test(m),L=qb(m,C);m=L.to;let A=dE(m,{relative:i}),R=gs(),U=null;if(c){let K=u0(c,[],R.unstable_mask?R.unstable_mask.pathname:"/",!0);C!=="/"&&(K.pathname=K.pathname==="/"?C:Ri([C,K.pathname])),U=I.createHref(K)}let[X,H,re]=WE(r,w),de=t5(m,{replace:l,unstable_mask:c,state:d,target:f,preventScrollReset:h,relative:i,viewTransition:g,unstable_defaultShouldRevalidate:y,unstable_useTransitions:E});function te(K){t&&t(K),K.defaultPrevented||de(K)}let Q=!(L.isExternal||s),ee=B.createElement("a",{...w,...re,href:(Q?U:void 0)||L.absoluteURL||A,onClick:Q?te:t,ref:XE(_,H),target:f,"data-discover":!S&&n==="render"?"true":void 0});return X&&!S?B.createElement(B.Fragment,null,ee,B.createElement(GE,{page:A})):ee});wo.displayName="Link";var JE=B.forwardRef(function({"aria-current":t="page",caseSensitive:n=!1,className:r="",end:i=!1,style:s,to:l,viewTransition:c,children:d,...f},m){let h=Eu(l,{relative:f.relative}),g=gs(),y=B.useContext(ih),{navigator:w,basename:_}=B.useContext(Fr),C=y!=null&&s5(h)&&c===!0,I=w.encodeLocation?w.encodeLocation(h).pathname:h.pathname,E=g.pathname,S=y&&y.navigation&&y.navigation.location?y.navigation.location.pathname:null;n||(E=E.toLowerCase(),S=S?S.toLowerCase():null,I=I.toLowerCase()),S&&_&&(S=bo(S,_)||S);const L=I!=="/"&&I.endsWith("/")?I.length-1:I.length;let A=E===I||!i&&E.startsWith(I)&&E.charAt(L)==="/",R=S!=null&&(S===I||!i&&S.startsWith(I)&&S.charAt(I.length)==="/"),U={isActive:A,isPending:R,isTransitioning:C},X=A?t:void 0,H;typeof r=="function"?H=r(U):H=[r,A?"active":null,R?"pending":null,C?"transitioning":null].filter(Boolean).join(" ");let re=typeof s=="function"?s(U):s;return B.createElement(wo,{...f,"aria-current":X,className:H,ref:m,style:re,to:l,viewTransition:c},typeof d=="function"?d(U):d)});JE.displayName="NavLink";var ZE=B.forwardRef(({discover:e="render",fetcherKey:t,navigate:n,reloadDocument:r,replace:i,state:s,method:l=cf,action:c,onSubmit:d,relative:f,preventScrollReset:m,viewTransition:h,unstable_defaultShouldRevalidate:g,...y},w)=>{let{unstable_useTransitions:_}=B.useContext(Fr),C=i5(),I=o5(c,{relative:f}),E=l.toLowerCase()==="get"?"get":"post",S=typeof c=="string"&&ox.test(c),L=A=>{if(d&&d(A),A.defaultPrevented)return;A.preventDefault();let R=A.nativeEvent.submitter,U=(R==null?void 0:R.getAttribute("formmethod"))||l,X=()=>C(R||A.currentTarget,{fetcherKey:t,method:U,navigate:n,replace:i,state:s,relative:f,preventScrollReset:m,viewTransition:h,unstable_defaultShouldRevalidate:g});_&&n!==!1?B.startTransition(()=>X()):X()};return B.createElement("form",{ref:w,method:E,action:I,onSubmit:r?d:L,...y,"data-discover":!S&&e==="render"?"true":void 0})});ZE.displayName="Form";function e5(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function sx(e){let t=B.useContext(Fl);return Rt(t,e5(e)),t}function t5(e,{target:t,replace:n,unstable_mask:r,state:i,preventScrollReset:s,relative:l,viewTransition:c,unstable_defaultShouldRevalidate:d,unstable_useTransitions:f}={}){let m=Zb(),h=gs(),g=Eu(e,{relative:l});return B.useCallback(y=>{if(TE(y,t)){y.preventDefault();let w=n!==void 0?n:qc(h)===qc(g),_=()=>m(e,{replace:w,unstable_mask:r,state:i,preventScrollReset:s,relative:l,viewTransition:c,unstable_defaultShouldRevalidate:d});f?B.startTransition(()=>_()):_()}},[h,m,g,n,r,i,t,e,s,l,c,d,f])}var n5=0,r5=()=>`__${String(++n5)}__`;function i5(){let{router:e}=sx("useSubmit"),{basename:t}=B.useContext(Fr),n=_E(),r=e.fetch,i=e.navigate;return B.useCallback(async(s,l={})=>{let{action:c,method:d,encType:f,formData:m,body:h}=FE(s,t);if(l.navigate===!1){let g=l.fetcherKey||r5();await r(g,n,l.action||c,{unstable_defaultShouldRevalidate:l.unstable_defaultShouldRevalidate,preventScrollReset:l.preventScrollReset,formData:m,body:h,formMethod:l.method||d,formEncType:l.encType||f,flushSync:l.flushSync})}else await i(l.action||c,{unstable_defaultShouldRevalidate:l.unstable_defaultShouldRevalidate,preventScrollReset:l.preventScrollReset,formData:m,body:h,formMethod:l.method||d,formEncType:l.encType||f,replace:l.replace,state:l.state,fromRouteId:n,flushSync:l.flushSync,viewTransition:l.viewTransition})},[r,i,t,n])}function o5(e,{relative:t}={}){let{basename:n}=B.useContext(Fr),r=B.useContext(xo);Rt(r,"useFormAction must be used inside a RouteContext");let[i]=r.matches.slice(-1),s={...Eu(e||".",{relative:t})},l=gs();if(e==null){s.search=l.search;let c=new URLSearchParams(s.search),d=c.getAll("index");if(d.some(m=>m==="")){c.delete("index"),d.filter(h=>h).forEach(h=>c.append("index",h));let m=c.toString();s.search=m?`?${m}`:""}}return(!e||e===".")&&i.route.index&&(s.search=s.search?s.search.replace(/^\?/,"?index&"):"?index"),n!=="/"&&(s.pathname=s.pathname==="/"?n:Ri([n,s.pathname])),qc(s)}function s5(e,{relative:t}={}){let n=B.useContext(Xb);Rt(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=sx("useViewTransitionState"),i=Eu(e,{relative:t});if(!n.isTransitioning)return!1;let s=bo(n.currentLocation.pathname,r)||n.currentLocation.pathname,l=bo(n.nextLocation.pathname,r)||n.nextLocation.pathname;return Rf(i.pathname,l)!=null||Rf(i.pathname,s)!=null}var a5=Vb();const l5=jb(a5);/**
53
+ * @license lucide-react v0.511.0 - ISC
54
+ *
55
+ * This source code is licensed under the ISC license.
56
+ * See the LICENSE file in the root directory of this source tree.
57
+ */const c5=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),u5=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,n,r)=>r?r.toUpperCase():n.toLowerCase()),Cv=e=>{const t=u5(e);return t.charAt(0).toUpperCase()+t.slice(1)},ax=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim(),d5=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};/**
58
+ * @license lucide-react v0.511.0 - ISC
59
+ *
60
+ * This source code is licensed under the ISC license.
61
+ * See the LICENSE file in the root directory of this source tree.
62
+ */var f5={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"};/**
63
+ * @license lucide-react v0.511.0 - ISC
64
+ *
65
+ * This source code is licensed under the ISC license.
66
+ * See the LICENSE file in the root directory of this source tree.
67
+ */const h5=B.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:i="",children:s,iconNode:l,...c},d)=>B.createElement("svg",{ref:d,...f5,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:ax("lucide",i),...!s&&!d5(c)&&{"aria-hidden":"true"},...c},[...l.map(([f,m])=>B.createElement(f,m)),...Array.isArray(s)?s:[s]]));/**
68
+ * @license lucide-react v0.511.0 - ISC
69
+ *
70
+ * This source code is licensed under the ISC license.
71
+ * See the LICENSE file in the root directory of this source tree.
72
+ */const Dt=(e,t)=>{const n=B.forwardRef(({className:r,...i},s)=>B.createElement(h5,{ref:s,iconNode:t,className:ax(`lucide-${c5(Cv(e))}`,`lucide-${e}`,r),...i}));return n.displayName=Cv(e),n};/**
73
+ * @license lucide-react v0.511.0 - ISC
74
+ *
75
+ * This source code is licensed under the ISC license.
76
+ * See the LICENSE file in the root directory of this source tree.
77
+ */const p5=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],g0=Dt("arrow-left",p5);/**
78
+ * @license lucide-react v0.511.0 - ISC
79
+ *
80
+ * This source code is licensed under the ISC license.
81
+ * See the LICENSE file in the root directory of this source tree.
82
+ */const m5=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],g5=Dt("chevron-down",m5);/**
83
+ * @license lucide-react v0.511.0 - ISC
84
+ *
85
+ * This source code is licensed under the ISC license.
86
+ * See the LICENSE file in the root directory of this source tree.
87
+ */const v5=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],y5=Dt("chevron-right",v5);/**
88
+ * @license lucide-react v0.511.0 - ISC
89
+ *
90
+ * This source code is licensed under the ISC license.
91
+ * See the LICENSE file in the root directory of this source tree.
92
+ */const w5=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],b5=Dt("circle-check",w5);/**
93
+ * @license lucide-react v0.511.0 - ISC
94
+ *
95
+ * This source code is licensed under the ISC license.
96
+ * See the LICENSE file in the root directory of this source tree.
97
+ */const x5=[["path",{d:"m16 18 6-6-6-6",key:"eg8j8"}],["path",{d:"m8 6-6 6 6 6",key:"ppft3o"}]],_5=Dt("code",x5);/**
98
+ * @license lucide-react v0.511.0 - ISC
99
+ *
100
+ * This source code is licensed under the ISC license.
101
+ * See the LICENSE file in the root directory of this source tree.
102
+ */const k5=[["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"}]],Xm=Dt("copy",k5);/**
103
+ * @license lucide-react v0.511.0 - ISC
104
+ *
105
+ * This source code is licensed under the ISC license.
106
+ * See the LICENSE file in the root directory of this source tree.
107
+ */const S5=[["path",{d:"m7 21-4.3-4.3c-1-1-1-2.5 0-3.4l9.6-9.6c1-1 2.5-1 3.4 0l5.6 5.6c1 1 1 2.5 0 3.4L13 21",key:"182aya"}],["path",{d:"M22 21H7",key:"t4ddhn"}],["path",{d:"m5 11 9 9",key:"1mo9qw"}]],C5=Dt("eraser",S5);/**
108
+ * @license lucide-react v0.511.0 - ISC
109
+ *
110
+ * This source code is licensed under the ISC license.
111
+ * See the LICENSE file in the root directory of this source tree.
112
+ */const E5=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],Ev=Dt("external-link",E5);/**
113
+ * @license lucide-react v0.511.0 - ISC
114
+ *
115
+ * This source code is licensed under the ISC license.
116
+ * See the LICENSE file in the root directory of this source tree.
117
+ */const I5=[["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}],["line",{x1:"3",x2:"9",y1:"12",y2:"12",key:"1dyftd"}],["line",{x1:"15",x2:"21",y1:"12",y2:"12",key:"oup4p8"}]],P5=Dt("git-commit-horizontal",I5);/**
118
+ * @license lucide-react v0.511.0 - ISC
119
+ *
120
+ * This source code is licensed under the ISC license.
121
+ * See the LICENSE file in the root directory of this source tree.
122
+ */const L5=[["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"}]],Iv=Dt("git-compare",L5);/**
123
+ * @license lucide-react v0.511.0 - ISC
124
+ *
125
+ * This source code is licensed under the ISC license.
126
+ * See the LICENSE file in the root directory of this source tree.
127
+ */const D5=[["path",{d:"m5 8 6 6",key:"1wu5hv"}],["path",{d:"m4 14 6-6 2-3",key:"1k1g8d"}],["path",{d:"M2 5h12",key:"or177f"}],["path",{d:"M7 2h1",key:"1t2jsx"}],["path",{d:"m22 22-5-10-5 10",key:"don7ne"}],["path",{d:"M14 18h6",key:"1m8k6r"}]],Pv=Dt("languages",D5);/**
128
+ * @license lucide-react v0.511.0 - ISC
129
+ *
130
+ * This source code is licensed under the ISC license.
131
+ * See the LICENSE file in the root directory of this source tree.
132
+ */const A5=[["path",{d:"M18 5a2 2 0 0 1 2 2v8.526a2 2 0 0 0 .212.897l1.068 2.127a1 1 0 0 1-.9 1.45H3.62a1 1 0 0 1-.9-1.45l1.068-2.127A2 2 0 0 0 4 15.526V7a2 2 0 0 1 2-2z",key:"1pdavp"}],["path",{d:"M20.054 15.987H3.946",key:"14rxg9"}]],T5=Dt("laptop",A5);/**
133
+ * @license lucide-react v0.511.0 - ISC
134
+ *
135
+ * This source code is licensed under the ISC license.
136
+ * See the LICENSE file in the root directory of this source tree.
137
+ */const R5=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],Lv=Dt("loader-circle",R5);/**
138
+ * @license lucide-react v0.511.0 - ISC
139
+ *
140
+ * This source code is licensed under the ISC license.
141
+ * See the LICENSE file in the root directory of this source tree.
142
+ */const N5=[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 9.9-1",key:"1mm8w8"}]],F5=Dt("lock-open",N5);/**
143
+ * @license lucide-react v0.511.0 - ISC
144
+ *
145
+ * This source code is licensed under the ISC license.
146
+ * See the LICENSE file in the root directory of this source tree.
147
+ */const M5=[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]],O5=Dt("lock",M5);/**
148
+ * @license lucide-react v0.511.0 - ISC
149
+ *
150
+ * This source code is licensed under the ISC license.
151
+ * See the LICENSE file in the root directory of this source tree.
152
+ */const $5=[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]],B5=Dt("moon",$5);/**
153
+ * @license lucide-react v0.511.0 - ISC
154
+ *
155
+ * This source code is licensed under the ISC license.
156
+ * See the LICENSE file in the root directory of this source tree.
157
+ */const j5=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],V5=Dt("plus",j5);/**
158
+ * @license lucide-react v0.511.0 - ISC
159
+ *
160
+ * This source code is licensed under the ISC license.
161
+ * See the LICENSE file in the root directory of this source tree.
162
+ */const U5=[["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"}]],z5=Dt("refresh-cw",U5);/**
163
+ * @license lucide-react v0.511.0 - ISC
164
+ *
165
+ * This source code is licensed under the ISC license.
166
+ * See the LICENSE file in the root directory of this source tree.
167
+ */const H5=[["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"}]],W5=Dt("rotate-ccw",H5);/**
168
+ * @license lucide-react v0.511.0 - ISC
169
+ *
170
+ * This source code is licensed under the ISC license.
171
+ * See the LICENSE file in the root directory of this source tree.
172
+ */const G5=[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]],q5=Dt("save",G5);/**
173
+ * @license lucide-react v0.511.0 - ISC
174
+ *
175
+ * This source code is licensed under the ISC license.
176
+ * See the LICENSE file in the root directory of this source tree.
177
+ */const K5=[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],X5=Dt("settings",K5);/**
178
+ * @license lucide-react v0.511.0 - ISC
179
+ *
180
+ * This source code is licensed under the ISC license.
181
+ * See the LICENSE file in the root directory of this source tree.
182
+ */const Q5=[["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"}]],Y5=Dt("sun",Q5);/**
183
+ * @license lucide-react v0.511.0 - ISC
184
+ *
185
+ * This source code is licensed under the ISC license.
186
+ * See the LICENSE file in the root directory of this source tree.
187
+ */const J5=[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]],Z5=Dt("trash-2",J5);/**
188
+ * @license lucide-react v0.511.0 - ISC
189
+ *
190
+ * This source code is licensed under the ISC license.
191
+ * See the LICENSE file in the root directory of this source tree.
192
+ */const e3=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],t3=Dt("x",e3),He=e=>typeof e=="string",Ec=()=>{let e,t;const n=new Promise((r,i)=>{e=r,t=i});return n.resolve=e,n.reject=t,n},Dv=e=>e==null?"":""+e,n3=(e,t,n)=>{e.forEach(r=>{t[r]&&(n[r]=t[r])})},r3=/###/g,Av=e=>e&&e.indexOf("###")>-1?e.replace(r3,"."):e,Tv=e=>!e||He(e),jc=(e,t,n)=>{const r=He(t)?t.split("."):t;let i=0;for(;i<r.length-1;){if(Tv(e))return{};const s=Av(r[i]);!e[s]&&n&&(e[s]=new n),Object.prototype.hasOwnProperty.call(e,s)?e=e[s]:e={},++i}return Tv(e)?{}:{obj:e,k:Av(r[i])}},Rv=(e,t,n)=>{const{obj:r,k:i}=jc(e,t,Object);if(r!==void 0||t.length===1){r[i]=n;return}let s=t[t.length-1],l=t.slice(0,t.length-1),c=jc(e,l,Object);for(;c.obj===void 0&&l.length;)s=`${l[l.length-1]}.${s}`,l=l.slice(0,l.length-1),c=jc(e,l,Object),c!=null&&c.obj&&typeof c.obj[`${c.k}.${s}`]<"u"&&(c.obj=void 0);c.obj[`${c.k}.${s}`]=n},i3=(e,t,n,r)=>{const{obj:i,k:s}=jc(e,t,Object);i[s]=i[s]||[],i[s].push(n)},Nf=(e,t)=>{const{obj:n,k:r}=jc(e,t);if(n&&Object.prototype.hasOwnProperty.call(n,r))return n[r]},o3=(e,t,n)=>{const r=Nf(e,n);return r!==void 0?r:Nf(t,n)},lx=(e,t,n)=>{for(const r in t)r!=="__proto__"&&r!=="constructor"&&(r in e?He(e[r])||e[r]instanceof String||He(t[r])||t[r]instanceof String?n&&(e[r]=t[r]):lx(e[r],t[r],n):e[r]=t[r]);return e},Hs=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var s3={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#x2F;"};const a3=e=>He(e)?e.replace(/[&<>"'\/]/g,t=>s3[t]):e;class l3{constructor(t){this.capacity=t,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(t){const n=this.regExpMap.get(t);if(n!==void 0)return n;const r=new RegExp(t);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(t,r),this.regExpQueue.push(t),r}}const c3=[" ",",","?","!",";"],u3=new l3(20),d3=(e,t,n)=>{t=t||"",n=n||"";const r=c3.filter(l=>t.indexOf(l)<0&&n.indexOf(l)<0);if(r.length===0)return!0;const i=u3.getRegExp(`(${r.map(l=>l==="?"?"\\?":l).join("|")})`);let s=!i.test(e);if(!s){const l=e.indexOf(n);l>0&&!i.test(e.substring(0,l))&&(s=!0)}return s},Qm=(e,t,n=".")=>{if(!e)return;if(e[t])return Object.prototype.hasOwnProperty.call(e,t)?e[t]:void 0;const r=t.split(n);let i=e;for(let s=0;s<r.length;){if(!i||typeof i!="object")return;let l,c="";for(let d=s;d<r.length;++d)if(d!==s&&(c+=n),c+=r[d],l=i[c],l!==void 0){if(["string","number","boolean"].indexOf(typeof l)>-1&&d<r.length-1)continue;s+=d-s+1;break}i=l}return i},Kc=e=>e==null?void 0:e.replace(/_/g,"-"),f3={type:"logger",log(e){this.output("log",e)},warn(e){this.output("warn",e)},error(e){this.output("error",e)},output(e,t){var n,r;(r=(n=console==null?void 0:console[e])==null?void 0:n.apply)==null||r.call(n,console,t)}};class Ff{constructor(t,n={}){this.init(t,n)}init(t,n={}){this.prefix=n.prefix||"i18next:",this.logger=t||f3,this.options=n,this.debug=n.debug}log(...t){return this.forward(t,"log","",!0)}warn(...t){return this.forward(t,"warn","",!0)}error(...t){return this.forward(t,"error","")}deprecate(...t){return this.forward(t,"warn","WARNING DEPRECATED: ",!0)}forward(t,n,r,i){return i&&!this.debug?null:(He(t[0])&&(t[0]=`${r}${this.prefix} ${t[0]}`),this.logger[n](t))}create(t){return new Ff(this.logger,{prefix:`${this.prefix}:${t}:`,...this.options})}clone(t){return t=t||this.options,t.prefix=t.prefix||this.prefix,new Ff(this.logger,t)}}var Di=new Ff;class sh{constructor(){this.observers={}}on(t,n){return t.split(" ").forEach(r=>{this.observers[r]||(this.observers[r]=new Map);const i=this.observers[r].get(n)||0;this.observers[r].set(n,i+1)}),this}off(t,n){if(this.observers[t]){if(!n){delete this.observers[t];return}this.observers[t].delete(n)}}emit(t,...n){this.observers[t]&&Array.from(this.observers[t].entries()).forEach(([i,s])=>{for(let l=0;l<s;l++)i(...n)}),this.observers["*"]&&Array.from(this.observers["*"].entries()).forEach(([i,s])=>{for(let l=0;l<s;l++)i.apply(i,[t,...n])})}}class Nv extends sh{constructor(t,n={ns:["translation"],defaultNS:"translation"}){super(),this.data=t||{},this.options=n,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.options.ignoreJSONStructure===void 0&&(this.options.ignoreJSONStructure=!0)}addNamespaces(t){this.options.ns.indexOf(t)<0&&this.options.ns.push(t)}removeNamespaces(t){const n=this.options.ns.indexOf(t);n>-1&&this.options.ns.splice(n,1)}getResource(t,n,r,i={}){var f,m;const s=i.keySeparator!==void 0?i.keySeparator:this.options.keySeparator,l=i.ignoreJSONStructure!==void 0?i.ignoreJSONStructure:this.options.ignoreJSONStructure;let c;t.indexOf(".")>-1?c=t.split("."):(c=[t,n],r&&(Array.isArray(r)?c.push(...r):He(r)&&s?c.push(...r.split(s)):c.push(r)));const d=Nf(this.data,c);return!d&&!n&&!r&&t.indexOf(".")>-1&&(t=c[0],n=c[1],r=c.slice(2).join(".")),d||!l||!He(r)?d:Qm((m=(f=this.data)==null?void 0:f[t])==null?void 0:m[n],r,s)}addResource(t,n,r,i,s={silent:!1}){const l=s.keySeparator!==void 0?s.keySeparator:this.options.keySeparator;let c=[t,n];r&&(c=c.concat(l?r.split(l):r)),t.indexOf(".")>-1&&(c=t.split("."),i=n,n=c[1]),this.addNamespaces(n),Rv(this.data,c,i),s.silent||this.emit("added",t,n,r,i)}addResources(t,n,r,i={silent:!1}){for(const s in r)(He(r[s])||Array.isArray(r[s]))&&this.addResource(t,n,s,r[s],{silent:!0});i.silent||this.emit("added",t,n,r)}addResourceBundle(t,n,r,i,s,l={silent:!1,skipCopy:!1}){let c=[t,n];t.indexOf(".")>-1&&(c=t.split("."),i=r,r=n,n=c[1]),this.addNamespaces(n);let d=Nf(this.data,c)||{};l.skipCopy||(r=JSON.parse(JSON.stringify(r))),i?lx(d,r,s):d={...d,...r},Rv(this.data,c,d),l.silent||this.emit("added",t,n,r)}removeResourceBundle(t,n){this.hasResourceBundle(t,n)&&delete this.data[t][n],this.removeNamespaces(n),this.emit("removed",t,n)}hasResourceBundle(t,n){return this.getResource(t,n)!==void 0}getResourceBundle(t,n){return n||(n=this.options.defaultNS),this.getResource(t,n)}getDataByLanguage(t){return this.data[t]}hasLanguageSomeTranslations(t){const n=this.getDataByLanguage(t);return!!(n&&Object.keys(n)||[]).find(i=>n[i]&&Object.keys(n[i]).length>0)}toJSON(){return this.data}}var cx={processors:{},addPostProcessor(e){this.processors[e.name]=e},handle(e,t,n,r,i){return e.forEach(s=>{var l;t=((l=this.processors[s])==null?void 0:l.process(t,n,r,i))??t}),t}};const ux=Symbol("i18next/PATH_KEY");function h3(){const e=[],t=Object.create(null);let n;return t.get=(r,i)=>{var s;return(s=n==null?void 0:n.revoke)==null||s.call(n),i===ux?e:(e.push(i),n=Proxy.revocable(r,t),n.proxy)},Proxy.revocable(Object.create(null),t).proxy}function Ym(e,t){const{[ux]:n}=e(h3()),r=(t==null?void 0:t.keySeparator)??".",i=(t==null?void 0:t.nsSeparator)??":";if(n.length>1&&i){const s=t==null?void 0:t.ns;if((s?Array.isArray(s)?s:[s]:[]).includes(n[0]))return`${n[0]}${i}${n.slice(1).join(r)}`}return n.join(r)}const Fv={},nm=e=>!He(e)&&typeof e!="boolean"&&typeof e!="number";class Mf extends sh{constructor(t,n={}){super(),n3(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],t,this),this.options=n,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.logger=Di.create("translator")}changeLanguage(t){t&&(this.language=t)}exists(t,n={interpolation:{}}){const r={...n};if(t==null)return!1;const i=this.resolve(t,r);if((i==null?void 0:i.res)===void 0)return!1;const s=nm(i.res);return!(r.returnObjects===!1&&s)}extractFromKey(t,n){let r=n.nsSeparator!==void 0?n.nsSeparator:this.options.nsSeparator;r===void 0&&(r=":");const i=n.keySeparator!==void 0?n.keySeparator:this.options.keySeparator;let s=n.ns||this.options.defaultNS||[];const l=r&&t.indexOf(r)>-1,c=!this.options.userDefinedKeySeparator&&!n.keySeparator&&!this.options.userDefinedNsSeparator&&!n.nsSeparator&&!d3(t,r,i);if(l&&!c){const d=t.match(this.interpolator.nestingRegexp);if(d&&d.length>0)return{key:t,namespaces:He(s)?[s]:s};const f=t.split(r);(r!==i||r===i&&this.options.ns.indexOf(f[0])>-1)&&(s=f.shift()),t=f.join(i)}return{key:t,namespaces:He(s)?[s]:s}}translate(t,n,r){let i=typeof n=="object"?{...n}:n;if(typeof i!="object"&&this.options.overloadTranslationOptionHandler&&(i=this.options.overloadTranslationOptionHandler(arguments)),typeof i=="object"&&(i={...i}),i||(i={}),t==null)return"";typeof t=="function"&&(t=Ym(t,{...this.options,...i})),Array.isArray(t)||(t=[String(t)]);const s=i.returnDetails!==void 0?i.returnDetails:this.options.returnDetails,l=i.keySeparator!==void 0?i.keySeparator:this.options.keySeparator,{key:c,namespaces:d}=this.extractFromKey(t[t.length-1],i),f=d[d.length-1];let m=i.nsSeparator!==void 0?i.nsSeparator:this.options.nsSeparator;m===void 0&&(m=":");const h=i.lng||this.language,g=i.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if((h==null?void 0:h.toLowerCase())==="cimode")return g?s?{res:`${f}${m}${c}`,usedKey:c,exactUsedKey:c,usedLng:h,usedNS:f,usedParams:this.getUsedParamsDetails(i)}:`${f}${m}${c}`:s?{res:c,usedKey:c,exactUsedKey:c,usedLng:h,usedNS:f,usedParams:this.getUsedParamsDetails(i)}:c;const y=this.resolve(t,i);let w=y==null?void 0:y.res;const _=(y==null?void 0:y.usedKey)||c,C=(y==null?void 0:y.exactUsedKey)||c,I=["[object Number]","[object Function]","[object RegExp]"],E=i.joinArrays!==void 0?i.joinArrays:this.options.joinArrays,S=!this.i18nFormat||this.i18nFormat.handleAsObject,L=i.count!==void 0&&!He(i.count),A=Mf.hasDefaultValue(i),R=L?this.pluralResolver.getSuffix(h,i.count,i):"",U=i.ordinal&&L?this.pluralResolver.getSuffix(h,i.count,{ordinal:!1}):"",X=L&&!i.ordinal&&i.count===0,H=X&&i[`defaultValue${this.options.pluralSeparator}zero`]||i[`defaultValue${R}`]||i[`defaultValue${U}`]||i.defaultValue;let re=w;S&&!w&&A&&(re=H);const de=nm(re),te=Object.prototype.toString.apply(re);if(S&&re&&de&&I.indexOf(te)<0&&!(He(E)&&Array.isArray(re))){if(!i.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const Q=this.options.returnedObjectHandler?this.options.returnedObjectHandler(_,re,{...i,ns:d}):`key '${c} (${this.language})' returned an object instead of string.`;return s?(y.res=Q,y.usedParams=this.getUsedParamsDetails(i),y):Q}if(l){const Q=Array.isArray(re),ee=Q?[]:{},K=Q?C:_;for(const oe in re)if(Object.prototype.hasOwnProperty.call(re,oe)){const ie=`${K}${l}${oe}`;A&&!w?ee[oe]=this.translate(ie,{...i,defaultValue:nm(H)?H[oe]:void 0,joinArrays:!1,ns:d}):ee[oe]=this.translate(ie,{...i,joinArrays:!1,ns:d}),ee[oe]===ie&&(ee[oe]=re[oe])}w=ee}}else if(S&&He(E)&&Array.isArray(w))w=w.join(E),w&&(w=this.extendTranslation(w,t,i,r));else{let Q=!1,ee=!1;!this.isValidLookup(w)&&A&&(Q=!0,w=H),this.isValidLookup(w)||(ee=!0,w=c);const oe=(i.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&ee?void 0:w,ie=A&&H!==w&&this.options.updateMissing;if(ee||Q||ie){if(this.logger.log(ie?"updateKey":"missingKey",h,f,c,ie?H:w),l){const O=this.resolve(c,{...i,keySeparator:!1});O&&O.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}let W=[];const ce=this.languageUtils.getFallbackCodes(this.options.fallbackLng,i.lng||this.language);if(this.options.saveMissingTo==="fallback"&&ce&&ce[0])for(let O=0;O<ce.length;O++)W.push(ce[O]);else this.options.saveMissingTo==="all"?W=this.languageUtils.toResolveHierarchy(i.lng||this.language):W.push(i.lng||this.language);const le=(O,J,fe)=>{var be;const we=A&&fe!==w?fe:oe;this.options.missingKeyHandler?this.options.missingKeyHandler(O,f,J,we,ie,i):(be=this.backendConnector)!=null&&be.saveMissing&&this.backendConnector.saveMissing(O,f,J,we,ie,i),this.emit("missingKey",O,f,J,w)};this.options.saveMissing&&(this.options.saveMissingPlurals&&L?W.forEach(O=>{const J=this.pluralResolver.getSuffixes(O,i);X&&i[`defaultValue${this.options.pluralSeparator}zero`]&&J.indexOf(`${this.options.pluralSeparator}zero`)<0&&J.push(`${this.options.pluralSeparator}zero`),J.forEach(fe=>{le([O],c+fe,i[`defaultValue${fe}`]||H)})}):le(W,c,H))}w=this.extendTranslation(w,t,i,y,r),ee&&w===c&&this.options.appendNamespaceToMissingKey&&(w=`${f}${m}${c}`),(ee||Q)&&this.options.parseMissingKeyHandler&&(w=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${f}${m}${c}`:c,Q?w:void 0,i))}return s?(y.res=w,y.usedParams=this.getUsedParamsDetails(i),y):w}extendTranslation(t,n,r,i,s){var d,f;if((d=this.i18nFormat)!=null&&d.parse)t=this.i18nFormat.parse(t,{...this.options.interpolation.defaultVariables,...r},r.lng||this.language||i.usedLng,i.usedNS,i.usedKey,{resolved:i});else if(!r.skipInterpolation){r.interpolation&&this.interpolator.init({...r,interpolation:{...this.options.interpolation,...r.interpolation}});const m=He(t)&&(((f=r==null?void 0:r.interpolation)==null?void 0:f.skipOnVariables)!==void 0?r.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let h;if(m){const y=t.match(this.interpolator.nestingRegexp);h=y&&y.length}let g=r.replace&&!He(r.replace)?r.replace:r;if(this.options.interpolation.defaultVariables&&(g={...this.options.interpolation.defaultVariables,...g}),t=this.interpolator.interpolate(t,g,r.lng||this.language||i.usedLng,r),m){const y=t.match(this.interpolator.nestingRegexp),w=y&&y.length;h<w&&(r.nest=!1)}!r.lng&&i&&i.res&&(r.lng=this.language||i.usedLng),r.nest!==!1&&(t=this.interpolator.nest(t,(...y)=>(s==null?void 0:s[0])===y[0]&&!r.context?(this.logger.warn(`It seems you are nesting recursively key: ${y[0]} in key: ${n[0]}`),null):this.translate(...y,n),r)),r.interpolation&&this.interpolator.reset()}const l=r.postProcess||this.options.postProcess,c=He(l)?[l]:l;return t!=null&&(c!=null&&c.length)&&r.applyPostProcessor!==!1&&(t=cx.handle(c,t,n,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...i,usedParams:this.getUsedParamsDetails(r)},...r}:r,this)),t}resolve(t,n={}){let r,i,s,l,c;return He(t)&&(t=[t]),t.forEach(d=>{if(this.isValidLookup(r))return;const f=this.extractFromKey(d,n),m=f.key;i=m;let h=f.namespaces;this.options.fallbackNS&&(h=h.concat(this.options.fallbackNS));const g=n.count!==void 0&&!He(n.count),y=g&&!n.ordinal&&n.count===0,w=n.context!==void 0&&(He(n.context)||typeof n.context=="number")&&n.context!=="",_=n.lngs?n.lngs:this.languageUtils.toResolveHierarchy(n.lng||this.language,n.fallbackLng);h.forEach(C=>{var I,E;this.isValidLookup(r)||(c=C,!Fv[`${_[0]}-${C}`]&&((I=this.utils)!=null&&I.hasLoadedNamespace)&&!((E=this.utils)!=null&&E.hasLoadedNamespace(c))&&(Fv[`${_[0]}-${C}`]=!0,this.logger.warn(`key "${i}" for languages "${_.join(", ")}" won't get resolved as namespace "${c}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),_.forEach(S=>{var R;if(this.isValidLookup(r))return;l=S;const L=[m];if((R=this.i18nFormat)!=null&&R.addLookupKeys)this.i18nFormat.addLookupKeys(L,m,S,C,n);else{let U;g&&(U=this.pluralResolver.getSuffix(S,n.count,n));const X=`${this.options.pluralSeparator}zero`,H=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(g&&(n.ordinal&&U.indexOf(H)===0&&L.push(m+U.replace(H,this.options.pluralSeparator)),L.push(m+U),y&&L.push(m+X)),w){const re=`${m}${this.options.contextSeparator||"_"}${n.context}`;L.push(re),g&&(n.ordinal&&U.indexOf(H)===0&&L.push(re+U.replace(H,this.options.pluralSeparator)),L.push(re+U),y&&L.push(re+X))}}let A;for(;A=L.pop();)this.isValidLookup(r)||(s=A,r=this.getResource(S,C,A,n))}))})}),{res:r,usedKey:i,exactUsedKey:s,usedLng:l,usedNS:c}}isValidLookup(t){return t!==void 0&&!(!this.options.returnNull&&t===null)&&!(!this.options.returnEmptyString&&t==="")}getResource(t,n,r,i={}){var s;return(s=this.i18nFormat)!=null&&s.getResource?this.i18nFormat.getResource(t,n,r,i):this.resourceStore.getResource(t,n,r,i)}getUsedParamsDetails(t={}){const n=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],r=t.replace&&!He(t.replace);let i=r?t.replace:t;if(r&&typeof t.count<"u"&&(i.count=t.count),this.options.interpolation.defaultVariables&&(i={...this.options.interpolation.defaultVariables,...i}),!r){i={...i};for(const s of n)delete i[s]}return i}static hasDefaultValue(t){const n="defaultValue";for(const r in t)if(Object.prototype.hasOwnProperty.call(t,r)&&n===r.substring(0,n.length)&&t[r]!==void 0)return!0;return!1}}class Mv{constructor(t){this.options=t,this.supportedLngs=this.options.supportedLngs||!1,this.logger=Di.create("languageUtils")}getScriptPartFromCode(t){if(t=Kc(t),!t||t.indexOf("-")<0)return null;const n=t.split("-");return n.length===2||(n.pop(),n[n.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(n.join("-"))}getLanguagePartFromCode(t){if(t=Kc(t),!t||t.indexOf("-")<0)return t;const n=t.split("-");return this.formatLanguageCode(n[0])}formatLanguageCode(t){if(He(t)&&t.indexOf("-")>-1){let n;try{n=Intl.getCanonicalLocales(t)[0]}catch{}return n&&this.options.lowerCaseLng&&(n=n.toLowerCase()),n||(this.options.lowerCaseLng?t.toLowerCase():t)}return this.options.cleanCode||this.options.lowerCaseLng?t.toLowerCase():t}isSupportedCode(t){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(t=this.getLanguagePartFromCode(t)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(t)>-1}getBestMatchFromCodes(t){if(!t)return null;let n;return t.forEach(r=>{if(n)return;const i=this.formatLanguageCode(r);(!this.options.supportedLngs||this.isSupportedCode(i))&&(n=i)}),!n&&this.options.supportedLngs&&t.forEach(r=>{if(n)return;const i=this.getScriptPartFromCode(r);if(this.isSupportedCode(i))return n=i;const s=this.getLanguagePartFromCode(r);if(this.isSupportedCode(s))return n=s;n=this.options.supportedLngs.find(l=>{if(l===s)return l;if(!(l.indexOf("-")<0&&s.indexOf("-")<0)&&(l.indexOf("-")>0&&s.indexOf("-")<0&&l.substring(0,l.indexOf("-"))===s||l.indexOf(s)===0&&s.length>1))return l})}),n||(n=this.getFallbackCodes(this.options.fallbackLng)[0]),n}getFallbackCodes(t,n){if(!t)return[];if(typeof t=="function"&&(t=t(n)),He(t)&&(t=[t]),Array.isArray(t))return t;if(!n)return t.default||[];let r=t[n];return r||(r=t[this.getScriptPartFromCode(n)]),r||(r=t[this.formatLanguageCode(n)]),r||(r=t[this.getLanguagePartFromCode(n)]),r||(r=t.default),r||[]}toResolveHierarchy(t,n){const r=this.getFallbackCodes((n===!1?[]:n)||this.options.fallbackLng||[],t),i=[],s=l=>{l&&(this.isSupportedCode(l)?i.push(l):this.logger.warn(`rejecting language code not found in supportedLngs: ${l}`))};return He(t)&&(t.indexOf("-")>-1||t.indexOf("_")>-1)?(this.options.load!=="languageOnly"&&s(this.formatLanguageCode(t)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&s(this.getScriptPartFromCode(t)),this.options.load!=="currentOnly"&&s(this.getLanguagePartFromCode(t))):He(t)&&s(this.formatLanguageCode(t)),r.forEach(l=>{i.indexOf(l)<0&&s(this.formatLanguageCode(l))}),i}}const Ov={zero:0,one:1,two:2,few:3,many:4,other:5},$v={select:e=>e===1?"one":"other",resolvedOptions:()=>({pluralCategories:["one","other"]})};class p3{constructor(t,n={}){this.languageUtils=t,this.options=n,this.logger=Di.create("pluralResolver"),this.pluralRulesCache={}}clearCache(){this.pluralRulesCache={}}getRule(t,n={}){const r=Kc(t==="dev"?"en":t),i=n.ordinal?"ordinal":"cardinal",s=JSON.stringify({cleanedCode:r,type:i});if(s in this.pluralRulesCache)return this.pluralRulesCache[s];let l;try{l=new Intl.PluralRules(r,{type:i})}catch{if(typeof Intl>"u")return this.logger.error("No Intl support, please use an Intl polyfill!"),$v;if(!t.match(/-|_/))return $v;const d=this.languageUtils.getLanguagePartFromCode(t);l=this.getRule(d,n)}return this.pluralRulesCache[s]=l,l}needsPlural(t,n={}){let r=this.getRule(t,n);return r||(r=this.getRule("dev",n)),(r==null?void 0:r.resolvedOptions().pluralCategories.length)>1}getPluralFormsOfKey(t,n,r={}){return this.getSuffixes(t,r).map(i=>`${n}${i}`)}getSuffixes(t,n={}){let r=this.getRule(t,n);return r||(r=this.getRule("dev",n)),r?r.resolvedOptions().pluralCategories.sort((i,s)=>Ov[i]-Ov[s]).map(i=>`${this.options.prepend}${n.ordinal?`ordinal${this.options.prepend}`:""}${i}`):[]}getSuffix(t,n,r={}){const i=this.getRule(t,r);return i?`${this.options.prepend}${r.ordinal?`ordinal${this.options.prepend}`:""}${i.select(n)}`:(this.logger.warn(`no plural rule found for: ${t}`),this.getSuffix("dev",n,r))}}const Bv=(e,t,n,r=".",i=!0)=>{let s=o3(e,t,n);return!s&&i&&He(n)&&(s=Qm(e,n,r),s===void 0&&(s=Qm(t,n,r))),s},rm=e=>e.replace(/\$/g,"$$$$");class jv{constructor(t={}){var n;this.logger=Di.create("interpolator"),this.options=t,this.format=((n=t==null?void 0:t.interpolation)==null?void 0:n.format)||(r=>r),this.init(t)}init(t={}){t.interpolation||(t.interpolation={escapeValue:!0});const{escape:n,escapeValue:r,useRawValueToEscape:i,prefix:s,prefixEscaped:l,suffix:c,suffixEscaped:d,formatSeparator:f,unescapeSuffix:m,unescapePrefix:h,nestingPrefix:g,nestingPrefixEscaped:y,nestingSuffix:w,nestingSuffixEscaped:_,nestingOptionsSeparator:C,maxReplaces:I,alwaysFormat:E}=t.interpolation;this.escape=n!==void 0?n:a3,this.escapeValue=r!==void 0?r:!0,this.useRawValueToEscape=i!==void 0?i:!1,this.prefix=s?Hs(s):l||"{{",this.suffix=c?Hs(c):d||"}}",this.formatSeparator=f||",",this.unescapePrefix=m?"":h||"-",this.unescapeSuffix=this.unescapePrefix?"":m||"",this.nestingPrefix=g?Hs(g):y||Hs("$t("),this.nestingSuffix=w?Hs(w):_||Hs(")"),this.nestingOptionsSeparator=C||",",this.maxReplaces=I||1e3,this.alwaysFormat=E!==void 0?E:!1,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const t=(n,r)=>(n==null?void 0:n.source)===r?(n.lastIndex=0,n):new RegExp(r,"g");this.regexp=t(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=t(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=t(this.nestingRegexp,`${this.nestingPrefix}((?:[^()"']+|"[^"]*"|'[^']*'|\\((?:[^()]|"[^"]*"|'[^']*')*\\))*?)${this.nestingSuffix}`)}interpolate(t,n,r,i){var y;let s,l,c;const d=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},f=w=>{if(w.indexOf(this.formatSeparator)<0){const E=Bv(n,d,w,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(E,void 0,r,{...i,...n,interpolationkey:w}):E}const _=w.split(this.formatSeparator),C=_.shift().trim(),I=_.join(this.formatSeparator).trim();return this.format(Bv(n,d,C,this.options.keySeparator,this.options.ignoreJSONStructure),I,r,{...i,...n,interpolationkey:C})};this.resetRegExp();const m=(i==null?void 0:i.missingInterpolationHandler)||this.options.missingInterpolationHandler,h=((y=i==null?void 0:i.interpolation)==null?void 0:y.skipOnVariables)!==void 0?i.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:w=>rm(w)},{regex:this.regexp,safeValue:w=>this.escapeValue?rm(this.escape(w)):rm(w)}].forEach(w=>{for(c=0;s=w.regex.exec(t);){const _=s[1].trim();if(l=f(_),l===void 0)if(typeof m=="function"){const I=m(t,s,i);l=He(I)?I:""}else if(i&&Object.prototype.hasOwnProperty.call(i,_))l="";else if(h){l=s[0];continue}else this.logger.warn(`missed to pass in variable ${_} for interpolating ${t}`),l="";else!He(l)&&!this.useRawValueToEscape&&(l=Dv(l));const C=w.safeValue(l);if(t=t.replace(s[0],C),h?(w.regex.lastIndex+=l.length,w.regex.lastIndex-=s[0].length):w.regex.lastIndex=0,c++,c>=this.maxReplaces)break}}),t}nest(t,n,r={}){let i,s,l;const c=(d,f)=>{const m=this.nestingOptionsSeparator;if(d.indexOf(m)<0)return d;const h=d.split(new RegExp(`${Hs(m)}[ ]*{`));let g=`{${h[1]}`;d=h[0],g=this.interpolate(g,l);const y=g.match(/'/g),w=g.match(/"/g);(((y==null?void 0:y.length)??0)%2===0&&!w||((w==null?void 0:w.length)??0)%2!==0)&&(g=g.replace(/'/g,'"'));try{l=JSON.parse(g),f&&(l={...f,...l})}catch(_){return this.logger.warn(`failed parsing options string in nesting for key ${d}`,_),`${d}${m}${g}`}return l.defaultValue&&l.defaultValue.indexOf(this.prefix)>-1&&delete l.defaultValue,d};for(;i=this.nestingRegexp.exec(t);){let d=[];l={...r},l=l.replace&&!He(l.replace)?l.replace:l,l.applyPostProcessor=!1,delete l.defaultValue;const f=/{.*}/.test(i[1])?i[1].lastIndexOf("}")+1:i[1].indexOf(this.formatSeparator);if(f!==-1&&(d=i[1].slice(f).split(this.formatSeparator).map(m=>m.trim()).filter(Boolean),i[1]=i[1].slice(0,f)),s=n(c.call(this,i[1].trim(),l),l),s&&i[0]===t&&!He(s))return s;He(s)||(s=Dv(s)),s||(this.logger.warn(`missed to resolve ${i[1]} for nesting ${t}`),s=""),d.length&&(s=d.reduce((m,h)=>this.format(m,h,r.lng,{...r,interpolationkey:i[1].trim()}),s.trim())),t=t.replace(i[0],s),this.regexp.lastIndex=0}return t}}const m3=e=>{let t=e.toLowerCase().trim();const n={};if(e.indexOf("(")>-1){const r=e.split("(");t=r[0].toLowerCase().trim();const i=r[1].substring(0,r[1].length-1);t==="currency"&&i.indexOf(":")<0?n.currency||(n.currency=i.trim()):t==="relativetime"&&i.indexOf(":")<0?n.range||(n.range=i.trim()):i.split(";").forEach(l=>{if(l){const[c,...d]=l.split(":"),f=d.join(":").trim().replace(/^'+|'+$/g,""),m=c.trim();n[m]||(n[m]=f),f==="false"&&(n[m]=!1),f==="true"&&(n[m]=!0),isNaN(f)||(n[m]=parseInt(f,10))}})}return{formatName:t,formatOptions:n}},Vv=e=>{const t={};return(n,r,i)=>{let s=i;i&&i.interpolationkey&&i.formatParams&&i.formatParams[i.interpolationkey]&&i[i.interpolationkey]&&(s={...s,[i.interpolationkey]:void 0});const l=r+JSON.stringify(s);let c=t[l];return c||(c=e(Kc(r),i),t[l]=c),c(n)}},g3=e=>(t,n,r)=>e(Kc(n),r)(t);class v3{constructor(t={}){this.logger=Di.create("formatter"),this.options=t,this.init(t)}init(t,n={interpolation:{}}){this.formatSeparator=n.interpolation.formatSeparator||",";const r=n.cacheInBuiltFormats?Vv:g3;this.formats={number:r((i,s)=>{const l=new Intl.NumberFormat(i,{...s});return c=>l.format(c)}),currency:r((i,s)=>{const l=new Intl.NumberFormat(i,{...s,style:"currency"});return c=>l.format(c)}),datetime:r((i,s)=>{const l=new Intl.DateTimeFormat(i,{...s});return c=>l.format(c)}),relativetime:r((i,s)=>{const l=new Intl.RelativeTimeFormat(i,{...s});return c=>l.format(c,s.range||"day")}),list:r((i,s)=>{const l=new Intl.ListFormat(i,{...s});return c=>l.format(c)})}}add(t,n){this.formats[t.toLowerCase().trim()]=n}addCached(t,n){this.formats[t.toLowerCase().trim()]=Vv(n)}format(t,n,r,i={}){const s=n.split(this.formatSeparator);if(s.length>1&&s[0].indexOf("(")>1&&s[0].indexOf(")")<0&&s.find(c=>c.indexOf(")")>-1)){const c=s.findIndex(d=>d.indexOf(")")>-1);s[0]=[s[0],...s.splice(1,c)].join(this.formatSeparator)}return s.reduce((c,d)=>{var h;const{formatName:f,formatOptions:m}=m3(d);if(this.formats[f]){let g=c;try{const y=((h=i==null?void 0:i.formatParams)==null?void 0:h[i.interpolationkey])||{},w=y.locale||y.lng||i.locale||i.lng||r;g=this.formats[f](c,w,{...m,...i,...y})}catch(y){this.logger.warn(y)}return g}else this.logger.warn(`there was no format function for ${f}`);return c},t)}}const y3=(e,t)=>{e.pending[t]!==void 0&&(delete e.pending[t],e.pendingCount--)};class w3 extends sh{constructor(t,n,r,i={}){var s,l;super(),this.backend=t,this.store=n,this.services=r,this.languageUtils=r.languageUtils,this.options=i,this.logger=Di.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=i.maxParallelReads||10,this.readingCalls=0,this.maxRetries=i.maxRetries>=0?i.maxRetries:5,this.retryTimeout=i.retryTimeout>=1?i.retryTimeout:350,this.state={},this.queue=[],(l=(s=this.backend)==null?void 0:s.init)==null||l.call(s,r,i.backend,i)}queueLoad(t,n,r,i){const s={},l={},c={},d={};return t.forEach(f=>{let m=!0;n.forEach(h=>{const g=`${f}|${h}`;!r.reload&&this.store.hasResourceBundle(f,h)?this.state[g]=2:this.state[g]<0||(this.state[g]===1?l[g]===void 0&&(l[g]=!0):(this.state[g]=1,m=!1,l[g]===void 0&&(l[g]=!0),s[g]===void 0&&(s[g]=!0),d[h]===void 0&&(d[h]=!0)))}),m||(c[f]=!0)}),(Object.keys(s).length||Object.keys(l).length)&&this.queue.push({pending:l,pendingCount:Object.keys(l).length,loaded:{},errors:[],callback:i}),{toLoad:Object.keys(s),pending:Object.keys(l),toLoadLanguages:Object.keys(c),toLoadNamespaces:Object.keys(d)}}loaded(t,n,r){const i=t.split("|"),s=i[0],l=i[1];n&&this.emit("failedLoading",s,l,n),!n&&r&&this.store.addResourceBundle(s,l,r,void 0,void 0,{skipCopy:!0}),this.state[t]=n?-1:2,n&&r&&(this.state[t]=0);const c={};this.queue.forEach(d=>{i3(d.loaded,[s],l),y3(d,t),n&&d.errors.push(n),d.pendingCount===0&&!d.done&&(Object.keys(d.loaded).forEach(f=>{c[f]||(c[f]={});const m=d.loaded[f];m.length&&m.forEach(h=>{c[f][h]===void 0&&(c[f][h]=!0)})}),d.done=!0,d.errors.length?d.callback(d.errors):d.callback())}),this.emit("loaded",c),this.queue=this.queue.filter(d=>!d.done)}read(t,n,r,i=0,s=this.retryTimeout,l){if(!t.length)return l(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:t,ns:n,fcName:r,tried:i,wait:s,callback:l});return}this.readingCalls++;const c=(f,m)=>{if(this.readingCalls--,this.waitingReads.length>0){const h=this.waitingReads.shift();this.read(h.lng,h.ns,h.fcName,h.tried,h.wait,h.callback)}if(f&&m&&i<this.maxRetries){setTimeout(()=>{this.read.call(this,t,n,r,i+1,s*2,l)},s);return}l(f,m)},d=this.backend[r].bind(this.backend);if(d.length===2){try{const f=d(t,n);f&&typeof f.then=="function"?f.then(m=>c(null,m)).catch(c):c(null,f)}catch(f){c(f)}return}return d(t,n,c)}prepareLoading(t,n,r={},i){if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),i&&i();He(t)&&(t=this.languageUtils.toResolveHierarchy(t)),He(n)&&(n=[n]);const s=this.queueLoad(t,n,r,i);if(!s.toLoad.length)return s.pending.length||i(),null;s.toLoad.forEach(l=>{this.loadOne(l)})}load(t,n,r){this.prepareLoading(t,n,{},r)}reload(t,n,r){this.prepareLoading(t,n,{reload:!0},r)}loadOne(t,n=""){const r=t.split("|"),i=r[0],s=r[1];this.read(i,s,"read",void 0,void 0,(l,c)=>{l&&this.logger.warn(`${n}loading namespace ${s} for language ${i} failed`,l),!l&&c&&this.logger.log(`${n}loaded namespace ${s} for language ${i}`,c),this.loaded(t,l,c)})}saveMissing(t,n,r,i,s,l={},c=()=>{}){var d,f,m,h,g;if((f=(d=this.services)==null?void 0:d.utils)!=null&&f.hasLoadedNamespace&&!((h=(m=this.services)==null?void 0:m.utils)!=null&&h.hasLoadedNamespace(n))){this.logger.warn(`did not save key "${r}" as the namespace "${n}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");return}if(!(r==null||r==="")){if((g=this.backend)!=null&&g.create){const y={...l,isUpdate:s},w=this.backend.create.bind(this.backend);if(w.length<6)try{let _;w.length===5?_=w(t,n,r,i,y):_=w(t,n,r,i),_&&typeof _.then=="function"?_.then(C=>c(null,C)).catch(c):c(null,_)}catch(_){c(_)}else w(t,n,r,i,c,y)}!t||!t[0]||this.store.addResource(t[0],n,r,i)}}}const im=()=>({debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let t={};if(typeof e[1]=="object"&&(t=e[1]),He(e[1])&&(t.defaultValue=e[1]),He(e[2])&&(t.tDescription=e[2]),typeof e[2]=="object"||typeof e[3]=="object"){const n=e[3]||e[2];Object.keys(n).forEach(r=>{t[r]=n[r]})}return t},interpolation:{escapeValue:!0,format:e=>e,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0},cacheInBuiltFormats:!0}),Uv=e=>{var t,n;return He(e.ns)&&(e.ns=[e.ns]),He(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),He(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),((n=(t=e.supportedLngs)==null?void 0:t.indexOf)==null?void 0:n.call(t,"cimode"))<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),typeof e.initImmediate=="boolean"&&(e.initAsync=e.initImmediate),e},Vd=()=>{},b3=e=>{Object.getOwnPropertyNames(Object.getPrototypeOf(e)).forEach(n=>{typeof e[n]=="function"&&(e[n]=e[n].bind(e))})},dx="__i18next_supportNoticeShown",x3=()=>typeof globalThis<"u"&&!!globalThis[dx],_3=()=>{typeof globalThis<"u"&&(globalThis[dx]=!0)},k3=e=>{var t,n,r,i,s,l,c,d,f,m,h,g,y;return!!(((r=(n=(t=e==null?void 0:e.modules)==null?void 0:t.backend)==null?void 0:n.name)==null?void 0:r.indexOf("Locize"))>0||((c=(l=(s=(i=e==null?void 0:e.modules)==null?void 0:i.backend)==null?void 0:s.constructor)==null?void 0:l.name)==null?void 0:c.indexOf("Locize"))>0||(f=(d=e==null?void 0:e.options)==null?void 0:d.backend)!=null&&f.backends&&e.options.backend.backends.some(w=>{var _,C,I;return((_=w==null?void 0:w.name)==null?void 0:_.indexOf("Locize"))>0||((I=(C=w==null?void 0:w.constructor)==null?void 0:C.name)==null?void 0:I.indexOf("Locize"))>0})||(h=(m=e==null?void 0:e.options)==null?void 0:m.backend)!=null&&h.projectId||(y=(g=e==null?void 0:e.options)==null?void 0:g.backend)!=null&&y.backendOptions&&e.options.backend.backendOptions.some(w=>w==null?void 0:w.projectId))};class Vc extends sh{constructor(t={},n){if(super(),this.options=Uv(t),this.services={},this.logger=Di,this.modules={external:[]},b3(this),n&&!this.isInitialized&&!t.isClone){if(!this.options.initAsync)return this.init(t,n),this;setTimeout(()=>{this.init(t,n)},0)}}init(t={},n){this.isInitializing=!0,typeof t=="function"&&(n=t,t={}),t.defaultNS==null&&t.ns&&(He(t.ns)?t.defaultNS=t.ns:t.ns.indexOf("translation")<0&&(t.defaultNS=t.ns[0]));const r=im();this.options={...r,...this.options,...Uv(t)},this.options.interpolation={...r.interpolation,...this.options.interpolation},t.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=t.keySeparator),t.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=t.nsSeparator),typeof this.options.overloadTranslationOptionHandler!="function"&&(this.options.overloadTranslationOptionHandler=r.overloadTranslationOptionHandler),this.options.showSupportNotice!==!1&&!k3(this)&&!x3()&&(typeof console<"u"&&typeof console.info<"u"&&console.info("🌐 i18next is made possible by our own product, Locize — consider powering your project with managed localization (AI, CDN, integrations): https://locize.com 💙"),_3());const i=f=>f?typeof f=="function"?new f:f:null;if(!this.options.isClone){this.modules.logger?Di.init(i(this.modules.logger),this.options):Di.init(null,this.options);let f;this.modules.formatter?f=this.modules.formatter:f=v3;const m=new Mv(this.options);this.store=new Nv(this.options.resources,this.options);const h=this.services;h.logger=Di,h.resourceStore=this.store,h.languageUtils=m,h.pluralResolver=new p3(m,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),this.options.interpolation.format&&this.options.interpolation.format!==r.interpolation.format&&this.logger.deprecate("init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting"),f&&(!this.options.interpolation.format||this.options.interpolation.format===r.interpolation.format)&&(h.formatter=i(f),h.formatter.init&&h.formatter.init(h,this.options),this.options.interpolation.format=h.formatter.format.bind(h.formatter)),h.interpolator=new jv(this.options),h.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},h.backendConnector=new w3(i(this.modules.backend),h.resourceStore,h,this.options),h.backendConnector.on("*",(y,...w)=>{this.emit(y,...w)}),this.modules.languageDetector&&(h.languageDetector=i(this.modules.languageDetector),h.languageDetector.init&&h.languageDetector.init(h,this.options.detection,this.options)),this.modules.i18nFormat&&(h.i18nFormat=i(this.modules.i18nFormat),h.i18nFormat.init&&h.i18nFormat.init(this)),this.translator=new Mf(this.services,this.options),this.translator.on("*",(y,...w)=>{this.emit(y,...w)}),this.modules.external.forEach(y=>{y.init&&y.init(this)})}if(this.format=this.options.interpolation.format,n||(n=Vd),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const f=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);f.length>0&&f[0]!=="dev"&&(this.options.lng=f[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined"),["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(f=>{this[f]=(...m)=>this.store[f](...m)}),["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(f=>{this[f]=(...m)=>(this.store[f](...m),this)});const c=Ec(),d=()=>{const f=(m,h)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),c.resolve(h),n(m,h)};if(this.languages&&!this.isInitialized)return f(null,this.t.bind(this));this.changeLanguage(this.options.lng,f)};return this.options.resources||!this.options.initAsync?d():setTimeout(d,0),c}loadResources(t,n=Vd){var s,l;let r=n;const i=He(t)?t:this.language;if(typeof t=="function"&&(r=t),!this.options.resources||this.options.partialBundledLanguages){if((i==null?void 0:i.toLowerCase())==="cimode"&&(!this.options.preload||this.options.preload.length===0))return r();const c=[],d=f=>{if(!f||f==="cimode")return;this.services.languageUtils.toResolveHierarchy(f).forEach(h=>{h!=="cimode"&&c.indexOf(h)<0&&c.push(h)})};i?d(i):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(m=>d(m)),(l=(s=this.options.preload)==null?void 0:s.forEach)==null||l.call(s,f=>d(f)),this.services.backendConnector.load(c,this.options.ns,f=>{!f&&!this.resolvedLanguage&&this.language&&this.setResolvedLanguage(this.language),r(f)})}else r(null)}reloadResources(t,n,r){const i=Ec();return typeof t=="function"&&(r=t,t=void 0),typeof n=="function"&&(r=n,n=void 0),t||(t=this.languages),n||(n=this.options.ns),r||(r=Vd),this.services.backendConnector.reload(t,n,s=>{i.resolve(),r(s)}),i}use(t){if(!t)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!t.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return t.type==="backend"&&(this.modules.backend=t),(t.type==="logger"||t.log&&t.warn&&t.error)&&(this.modules.logger=t),t.type==="languageDetector"&&(this.modules.languageDetector=t),t.type==="i18nFormat"&&(this.modules.i18nFormat=t),t.type==="postProcessor"&&cx.addPostProcessor(t),t.type==="formatter"&&(this.modules.formatter=t),t.type==="3rdParty"&&this.modules.external.push(t),this}setResolvedLanguage(t){if(!(!t||!this.languages)&&!(["cimode","dev"].indexOf(t)>-1)){for(let n=0;n<this.languages.length;n++){const r=this.languages[n];if(!(["cimode","dev"].indexOf(r)>-1)&&this.store.hasLanguageSomeTranslations(r)){this.resolvedLanguage=r;break}}!this.resolvedLanguage&&this.languages.indexOf(t)<0&&this.store.hasLanguageSomeTranslations(t)&&(this.resolvedLanguage=t,this.languages.unshift(t))}}changeLanguage(t,n){this.isLanguageChangingTo=t;const r=Ec();this.emit("languageChanging",t);const i=c=>{this.language=c,this.languages=this.services.languageUtils.toResolveHierarchy(c),this.resolvedLanguage=void 0,this.setResolvedLanguage(c)},s=(c,d)=>{d?this.isLanguageChangingTo===t&&(i(d),this.translator.changeLanguage(d),this.isLanguageChangingTo=void 0,this.emit("languageChanged",d),this.logger.log("languageChanged",d)):this.isLanguageChangingTo=void 0,r.resolve((...f)=>this.t(...f)),n&&n(c,(...f)=>this.t(...f))},l=c=>{var m,h;!t&&!c&&this.services.languageDetector&&(c=[]);const d=He(c)?c:c&&c[0],f=this.store.hasLanguageSomeTranslations(d)?d:this.services.languageUtils.getBestMatchFromCodes(He(c)?[c]:c);f&&(this.language||i(f),this.translator.language||this.translator.changeLanguage(f),(h=(m=this.services.languageDetector)==null?void 0:m.cacheUserLanguage)==null||h.call(m,f)),this.loadResources(f,g=>{s(g,f)})};return!t&&this.services.languageDetector&&!this.services.languageDetector.async?l(this.services.languageDetector.detect()):!t&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(l):this.services.languageDetector.detect(l):l(t),r}getFixedT(t,n,r){const i=(s,l,...c)=>{let d;typeof l!="object"?d=this.options.overloadTranslationOptionHandler([s,l].concat(c)):d={...l},d.lng=d.lng||i.lng,d.lngs=d.lngs||i.lngs,d.ns=d.ns||i.ns,d.keyPrefix!==""&&(d.keyPrefix=d.keyPrefix||r||i.keyPrefix);const f=this.options.keySeparator||".";let m;return d.keyPrefix&&Array.isArray(s)?m=s.map(h=>(typeof h=="function"&&(h=Ym(h,{...this.options,...l})),`${d.keyPrefix}${f}${h}`)):(typeof s=="function"&&(s=Ym(s,{...this.options,...l})),m=d.keyPrefix?`${d.keyPrefix}${f}${s}`:s),this.t(m,d)};return He(t)?i.lng=t:i.lngs=t,i.ns=n,i.keyPrefix=r,i}t(...t){var n;return(n=this.translator)==null?void 0:n.translate(...t)}exists(...t){var n;return(n=this.translator)==null?void 0:n.exists(...t)}setDefaultNamespace(t){this.options.defaultNS=t}hasLoadedNamespace(t,n={}){if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;const r=n.lng||this.resolvedLanguage||this.languages[0],i=this.options?this.options.fallbackLng:!1,s=this.languages[this.languages.length-1];if(r.toLowerCase()==="cimode")return!0;const l=(c,d)=>{const f=this.services.backendConnector.state[`${c}|${d}`];return f===-1||f===0||f===2};if(n.precheck){const c=n.precheck(this,l);if(c!==void 0)return c}return!!(this.hasResourceBundle(r,t)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||l(r,t)&&(!i||l(s,t)))}loadNamespaces(t,n){const r=Ec();return this.options.ns?(He(t)&&(t=[t]),t.forEach(i=>{this.options.ns.indexOf(i)<0&&this.options.ns.push(i)}),this.loadResources(i=>{r.resolve(),n&&n(i)}),r):(n&&n(),Promise.resolve())}loadLanguages(t,n){const r=Ec();He(t)&&(t=[t]);const i=this.options.preload||[],s=t.filter(l=>i.indexOf(l)<0&&this.services.languageUtils.isSupportedCode(l));return s.length?(this.options.preload=i.concat(s),this.loadResources(l=>{r.resolve(),n&&n(l)}),r):(n&&n(),Promise.resolve())}dir(t){var i,s;if(t||(t=this.resolvedLanguage||(((i=this.languages)==null?void 0:i.length)>0?this.languages[0]:this.language)),!t)return"rtl";try{const l=new Intl.Locale(t);if(l&&l.getTextInfo){const c=l.getTextInfo();if(c&&c.direction)return c.direction}}catch{}const n=["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"],r=((s=this.services)==null?void 0:s.languageUtils)||new Mv(im());return t.toLowerCase().indexOf("-latn")>1?"ltr":n.indexOf(r.getLanguagePartFromCode(t))>-1||t.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(t={},n){const r=new Vc(t,n);return r.createInstance=Vc.createInstance,r}cloneInstance(t={},n=Vd){const r=t.forkResourceStore;r&&delete t.forkResourceStore;const i={...this.options,...t,isClone:!0},s=new Vc(i);if((t.debug!==void 0||t.prefix!==void 0)&&(s.logger=s.logger.clone(t)),["store","services","language"].forEach(c=>{s[c]=this[c]}),s.services={...this.services},s.services.utils={hasLoadedNamespace:s.hasLoadedNamespace.bind(s)},r){const c=Object.keys(this.store.data).reduce((d,f)=>(d[f]={...this.store.data[f]},d[f]=Object.keys(d[f]).reduce((m,h)=>(m[h]={...d[f][h]},m),d[f]),d),{});s.store=new Nv(c,i),s.services.resourceStore=s.store}if(t.interpolation){const d={...im().interpolation,...this.options.interpolation,...t.interpolation},f={...i,interpolation:d};s.services.interpolator=new jv(f)}return s.translator=new Mf(s.services,i),s.translator.on("*",(c,...d)=>{s.emit(c,...d)}),s.init(i,n),s.translator.options=i,s.translator.backendConnector.services.utils={hasLoadedNamespace:s.hasLoadedNamespace.bind(s)},s}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const On=Vc.createInstance();On.createInstance;On.dir;On.init;On.loadResources;On.reloadResources;On.use;On.changeLanguage;On.getFixedT;On.t;On.exists;On.setDefaultNamespace;On.hasLoadedNamespace;On.loadNamespaces;On.loadLanguages;const S3=(e,t,n,r)=>{var s,l,c,d;const i=[n,{code:t,...r||{}}];if((l=(s=e==null?void 0:e.services)==null?void 0:s.logger)!=null&&l.forward)return e.services.logger.forward(i,"warn","react-i18next::",!0);oa(i[0])&&(i[0]=`react-i18next:: ${i[0]}`),(d=(c=e==null?void 0:e.services)==null?void 0:c.logger)!=null&&d.warn?e.services.logger.warn(...i):console!=null&&console.warn&&console.warn(...i)},zv={},fx=(e,t,n,r)=>{oa(n)&&zv[n]||(oa(n)&&(zv[n]=new Date),S3(e,t,n,r))},hx=(e,t)=>()=>{if(e.isInitialized)t();else{const n=()=>{setTimeout(()=>{e.off("initialized",n)},0),t()};e.on("initialized",n)}},Jm=(e,t,n)=>{e.loadNamespaces(t,hx(e,n))},Hv=(e,t,n,r)=>{if(oa(n)&&(n=[n]),e.options.preload&&e.options.preload.indexOf(t)>-1)return Jm(e,n,r);n.forEach(i=>{e.options.ns.indexOf(i)<0&&e.options.ns.push(i)}),e.loadLanguages(t,hx(e,r))},C3=(e,t,n={})=>!t.languages||!t.languages.length?(fx(t,"NO_LANGUAGES","i18n.languages were undefined or empty",{languages:t.languages}),!0):t.hasLoadedNamespace(e,{lng:n.lng,precheck:(r,i)=>{if(n.bindI18n&&n.bindI18n.indexOf("languageChanging")>-1&&r.services.backendConnector.backend&&r.isLanguageChangingTo&&!i(r.isLanguageChangingTo,e))return!1}}),oa=e=>typeof e=="string",E3=e=>typeof e=="object"&&e!==null,I3=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,P3={"&amp;":"&","&#38;":"&","&lt;":"<","&#60;":"<","&gt;":">","&#62;":">","&apos;":"'","&#39;":"'","&quot;":'"',"&#34;":'"',"&nbsp;":" ","&#160;":" ","&copy;":"©","&#169;":"©","&reg;":"®","&#174;":"®","&hellip;":"…","&#8230;":"…","&#x2F;":"/","&#47;":"/"},L3=e=>P3[e],D3=e=>e.replace(I3,L3);let Zm={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:D3,transDefaultProps:void 0};const A3=(e={})=>{Zm={...Zm,...e}},T3=()=>Zm;let px;const R3=e=>{px=e},N3=()=>px,F3={type:"3rdParty",init(e){A3(e.options.react),R3(e)}},M3=B.createContext();class O3{constructor(){this.usedNamespaces={}}addUsedNamespaces(t){t.forEach(n=>{this.usedNamespaces[n]||(this.usedNamespaces[n]=!0)})}getUsedNamespaces(){return Object.keys(this.usedNamespaces)}}var om={exports:{}},sm={};/**
193
+ * @license React
194
+ * use-sync-external-store-shim.production.js
195
+ *
196
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
197
+ *
198
+ * This source code is licensed under the MIT license found in the
199
+ * LICENSE file in the root directory of this source tree.
200
+ */var Wv;function $3(){if(Wv)return sm;Wv=1;var e=rh();function t(h,g){return h===g&&(h!==0||1/h===1/g)||h!==h&&g!==g}var n=typeof Object.is=="function"?Object.is:t,r=e.useState,i=e.useEffect,s=e.useLayoutEffect,l=e.useDebugValue;function c(h,g){var y=g(),w=r({inst:{value:y,getSnapshot:g}}),_=w[0].inst,C=w[1];return s(function(){_.value=y,_.getSnapshot=g,d(_)&&C({inst:_})},[h,y,g]),i(function(){return d(_)&&C({inst:_}),h(function(){d(_)&&C({inst:_})})},[h]),l(y),y}function d(h){var g=h.getSnapshot;h=h.value;try{var y=g();return!n(h,y)}catch{return!0}}function f(h,g){return g()}var m=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?f:c;return sm.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:m,sm}var Gv;function B3(){return Gv||(Gv=1,om.exports=$3()),om.exports}var j3=B3();const V3=(e,t)=>oa(t)?t:E3(t)&&oa(t.defaultValue)?t.defaultValue:Array.isArray(e)?e[e.length-1]:e,U3={t:V3,ready:!1},z3=()=>()=>{},Iu=(e,t={})=>{var H,re,de;const{i18n:n}=t,{i18n:r,defaultNS:i}=B.useContext(M3)||{},s=n||r||N3();s&&!s.reportNamespaces&&(s.reportNamespaces=new O3),s||fx(s,"NO_I18NEXT_INSTANCE","useTranslation: You will need to pass in an i18next instance by using initReactI18next");const l=B.useMemo(()=>{var te;return{...T3(),...(te=s==null?void 0:s.options)==null?void 0:te.react,...t}},[s,t]),{useSuspense:c,keyPrefix:d}=l,f=i||((H=s==null?void 0:s.options)==null?void 0:H.defaultNS),m=oa(f)?[f]:f||["translation"],h=B.useMemo(()=>m,m);(de=(re=s==null?void 0:s.reportNamespaces)==null?void 0:re.addUsedNamespaces)==null||de.call(re,h);const g=B.useRef(0),y=B.useCallback(te=>{if(!s)return z3;const{bindI18n:Q,bindI18nStore:ee}=l,K=()=>{g.current+=1,te()};return Q&&s.on(Q,K),ee&&s.store.on(ee,K),()=>{Q&&Q.split(" ").forEach(oe=>s.off(oe,K)),ee&&ee.split(" ").forEach(oe=>s.store.off(oe,K))}},[s,l]),w=B.useRef(),_=B.useCallback(()=>{if(!s)return U3;const te=!!(s.isInitialized||s.initializedStoreOnce)&&h.every(W=>C3(W,s,l)),Q=t.lng||s.language,ee=g.current,K=w.current;if(K&&K.ready===te&&K.lng===Q&&K.keyPrefix===d&&K.revision===ee)return K;const ie={t:s.getFixedT(Q,l.nsMode==="fallback"?h:h[0],d),ready:te,lng:Q,keyPrefix:d,revision:ee};return w.current=ie,ie},[s,h,d,l,t.lng]),[C,I]=B.useState(0),{t:E,ready:S}=j3.useSyncExternalStore(y,_,_);B.useEffect(()=>{if(s&&!S&&!c){const te=()=>I(Q=>Q+1);t.lng?Hv(s,t.lng,h,te):Jm(s,h,te)}},[s,t.lng,h,S,c,C]);const L=s||{},A=B.useRef(null),R=B.useRef(),U=te=>{const Q=Object.getOwnPropertyDescriptors(te);Q.__original&&delete Q.__original;const ee=Object.create(Object.getPrototypeOf(te),Q);if(!Object.prototype.hasOwnProperty.call(ee,"__original"))try{Object.defineProperty(ee,"__original",{value:te,writable:!1,enumerable:!1,configurable:!1})}catch{}return ee},X=B.useMemo(()=>{const te=L,Q=te==null?void 0:te.language;let ee=te;te&&(A.current&&A.current.__original===te?R.current!==Q?(ee=U(te),A.current=ee,R.current=Q):ee=A.current:(ee=U(te),A.current=ee,R.current=Q));const K=[E,ee,S];return K.t=E,K.i18n=ee,K.ready=S,K},[E,L,S,L.resolvedLanguage,L.language,L.languages]);if(s&&c&&!S)throw new Promise(te=>{const Q=()=>te();t.lng?Hv(s,t.lng,h,Q):Jm(s,h,Q)});return X};function ot({variant:e="primary",size:t="md",className:n="",...r}){const i="inline-flex items-center justify-center rounded-lg font-medium transition-colors focus:outline-none focus:ring-2 focus:ring-slate-400 focus:ring-offset-2 dark:focus:ring-slate-700 disabled:opacity-50 disabled:cursor-not-allowed gap-2",s={primary:"bg-indigo-600 text-white hover:bg-indigo-700 dark:bg-indigo-500 dark:hover:bg-indigo-600",secondary:"bg-slate-100 text-slate-900 hover:bg-slate-200 dark:bg-slate-800 dark:text-slate-100 dark:hover:bg-slate-700",danger:"bg-rose-600 text-white hover:bg-rose-700 dark:bg-rose-500 dark:hover:bg-rose-600",ghost:"text-slate-600 hover:bg-slate-100 hover:text-slate-900 dark:text-slate-400 dark:hover:bg-slate-800 dark:hover:text-slate-100"},l={sm:"text-xs px-3 py-1.5",md:"text-sm px-4 py-2",lg:"text-base px-6 py-3"},c=`${i} ${s[e]} ${l[t]} ${n}`;return P.jsx("button",{"trae-inspector-start-line":"32","trae-inspector-start-column":"9","trae-inspector-end-line":"32","trae-inspector-end-column":"46","trae-inspector-file-path":"src/components/Button.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:c,...r})}const H3={md:"max-w-md",lg:"max-w-2xl",xl:"max-w-4xl","2xl":"max-w-6xl",full:"max-w-[calc(100vw-2rem)]"};function mx({open:e,onClose:t,title:n,children:r,footer:i,size:s="md"}){return e?P.jsx("div",{"trae-inspector-start-line":"25","trae-inspector-start-column":"4","trae-inspector-end-line":"40","trae-inspector-end-column":"10","trae-inspector-file-path":"src/components/Modal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"fixed inset-0 z-50 flex items-center justify-center bg-slate-900/50 p-4 backdrop-blur-sm dark:bg-black/50",children:P.jsxs("div",{"trae-inspector-start-line":"26","trae-inspector-start-column":"6","trae-inspector-end-line":"39","trae-inspector-end-column":"12","trae-inspector-file-path":"src/components/Modal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:`w-full ${H3[s]} rounded-xl border border-slate-200 bg-white shadow-xl dark:border-slate-800 dark:bg-slate-950`,children:[P.jsxs("div",{"trae-inspector-start-line":"27","trae-inspector-start-column":"8","trae-inspector-end-line":"32","trae-inspector-end-column":"14","trae-inspector-file-path":"src/components/Modal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex items-center justify-between border-b border-slate-100 px-4 py-3 dark:border-slate-800",children:[P.jsx("div",{"trae-inspector-start-line":"28","trae-inspector-start-column":"10","trae-inspector-end-line":"28","trae-inspector-end-column":"89","trae-inspector-file-path":"src/components/Modal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"font-semibold text-slate-900 dark:text-slate-100",children:n}),P.jsx("button",{"trae-inspector-start-line":"29","trae-inspector-start-column":"10","trae-inspector-end-line":"31","trae-inspector-end-column":"19","trae-inspector-file-path":"src/components/Modal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",onClick:t,className:"text-slate-400 hover:text-slate-600 dark:hover:text-slate-200",children:P.jsx(t3,{className:"h-4 w-4"})})]}),P.jsx("div",{"trae-inspector-start-line":"33","trae-inspector-start-column":"8","trae-inspector-end-line":"33","trae-inspector-end-column":"45","trae-inspector-file-path":"src/components/Modal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"p-4",children:r}),i?P.jsx("div",{"trae-inspector-start-line":"35","trae-inspector-start-column":"10","trae-inspector-end-line":"37","trae-inspector-end-column":"16","trae-inspector-file-path":"src/components/Modal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex justify-end gap-2 border-t border-slate-100 px-4 py-3 dark:border-slate-800",children:i}):null]})}):null}const W3={position:"absolute",top:0,bottom:0,textAlign:"center"},G3={display:"contents"};function qv(){return null}const Of="diffs-container",q3=/(?=^From [a-f0-9]+ .+$)/m,df=/(?=^diff --git)/gm,Kv=/(?=^---\s+\S)/gm,K3=/(?=^@@ )/gm,X3=/^@@ -(\d+)(?:,(\d+))? \+(\d+)(?:,(\d+))? @@(?: (.*))?/m,am=new RegExp("(?<=\\n)"),Q3=/^(---|\+\+\+)\s+([^\t\r\n]+)/,Y3=/^(---|\+\+\+)\s+[ab]\/([^\t\r\n]+)/,J3=/^diff --git (?:"a\/(.+?)"|a\/(.+?)) (?:"b\/(.+?)"|b\/(.+?))$/,Z3=/^index ([0-9a-f]+)\.\.([0-9a-f]+)(?: (\d+))?$/i,v0="header-prefix",y0="header-metadata",w0="header-custom",Ai={dark:"pierre-dark",light:"pierre-light"},gx="data-theme-css",vx="data-unsafe-css",ll=1,eI={hunkLineCount:50,lineHeight:20,diffHeaderHeight:44,hunkSeparatorHeight:32,fileGap:8},tI=Object.freeze({fromStart:0,fromEnd:0}),Xv={startingLine:0,totalLines:1/0,bufferBefore:0,bufferAfter:0},nI={startingLine:0,totalLines:0,bufferBefore:0,bufferAfter:0};function Xc(e){return`annotation-${"side"in e?`${e.side}-`:""}${e.lineNumber}`}function rI(e,t){return typeof window>"u"&&t!=null?P.jsxs(P.Fragment,{children:[P.jsx("template",{shadowrootmode:"open",dangerouslySetInnerHTML:{__html:t}}),e]}):P.jsx(P.Fragment,{children:e})}const iI=B.createContext(void 0);function oI(){return B.useContext(iI)}const ra=new Map,lm=new Map,eg=new Map,tg=new Set;function Qv(e,t){e=Array.isArray(e)?e:[e];for(let n of e){let r;if(typeof n=="string"){if(r=ra.get(n),r==null)throw new Error(`loadResolvedThemes: ${n} is not resolved, you must resolve it before calling loadResolvedThemes`)}else r=n,n=n.name,ra.has(n)||ra.set(n,r);tg.has(n)||(tg.add(n),t.loadThemeSync(r))}}const sI="modulepreload",aI=function(e){return"/"+e},Yv={},D=function(t,n,r){let i=Promise.resolve();if(n&&n.length>0){let l=function(f){return Promise.all(f.map(m=>Promise.resolve(m).then(h=>({status:"fulfilled",value:h}),h=>({status:"rejected",reason:h}))))};document.getElementsByTagName("link");const c=document.querySelector("meta[property=csp-nonce]"),d=(c==null?void 0:c.nonce)||(c==null?void 0:c.getAttribute("nonce"));i=l(n.map(f=>{if(f=aI(f),f in Yv)return;Yv[f]=!0;const m=f.endsWith(".css"),h=m?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${f}"]${h}`))return;const g=document.createElement("link");if(g.rel=m?"stylesheet":sI,m||(g.as="script"),g.crossOrigin="",g.href=f,d&&g.setAttribute("nonce",d),document.head.appendChild(g),m)return new Promise((y,w)=>{g.addEventListener("load",y),g.addEventListener("error",()=>w(new Error(`Unable to preload CSS for ${f}`)))})}))}function s(l){const c=new Event("vite:preloadError",{cancelable:!0});if(c.payload=l,window.dispatchEvent(c),!c.defaultPrevented)throw l}return i.then(l=>{for(const c of l||[])c.status==="rejected"&&s(c.reason);return t().catch(s)})},Qc=new Map,cm=new Map,lI=new Map,ng=new Set;function Jv(e,t){e=Array.isArray(e)?e:[e];for(const n of e){if(ng.has(n.name))continue;let r=Qc.get(n.name);r==null&&(r=n,Qc.set(n.name,r)),ng.add(r.name),t.loadLanguageSync(r.data)}}function yx(){return typeof WorkerGlobalScope<"u"&&typeof self<"u"&&self instanceof WorkerGlobalScope}let Xt=class extends Error{constructor(t){super(t),this.name="ShikiError"}};function cI(e){return b0(e)}function b0(e){return Array.isArray(e)?uI(e):e instanceof RegExp?e:typeof e=="object"?dI(e):e}function uI(e){let t=[];for(let n=0,r=e.length;n<r;n++)t[n]=b0(e[n]);return t}function dI(e){let t={};for(let n in e)t[n]=b0(e[n]);return t}function wx(e,...t){return t.forEach(n=>{for(let r in n)e[r]=n[r]}),e}function bx(e){const t=~e.lastIndexOf("/")||~e.lastIndexOf("\\");return t===0?e:~t===e.length-1?bx(e.substring(0,e.length-1)):e.substr(~t+1)}var um=/\$(\d+)|\${(\d+):\/(downcase|upcase)}/g,Ud=class{static hasCaptures(e){return e===null?!1:(um.lastIndex=0,um.test(e))}static replaceCaptures(e,t,n){return e.replace(um,(r,i,s,l)=>{let c=n[parseInt(i||s,10)];if(c){let d=t.substring(c.start,c.end);for(;d[0]===".";)d=d.substring(1);switch(l){case"downcase":return d.toLowerCase();case"upcase":return d.toUpperCase();default:return d}}else return r})}};function xx(e,t){return e<t?-1:e>t?1:0}function _x(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 i=0;i<n;i++){let s=xx(e[i],t[i]);if(s!==0)return s}return 0}return n-r}function Zv(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 kx(e){return e.replace(/[\-\\\{\}\*\+\?\|\^\$\.\,\[\]\(\)\#\s]/g,"\\$&")}var Sx=class{constructor(e){F(this,"cache",new Map);this.fn=e}get(e){if(this.cache.has(e))return this.cache.get(e);const t=this.fn(e);return this.cache.set(e,t),t}},$f=class{constructor(e,t,n){F(this,"_cachedMatchRoot",new Sx(e=>this._root.match(e)));this._colorMap=e,this._defaults=t,this._root=n}static createFromRawTheme(e,t){return this.createFromParsedTheme(pI(e),t)}static createFromParsedTheme(e,t){return gI(e,t)}getColorMap(){return this._colorMap.getColorMap()}getDefaults(){return this._defaults}match(e){if(e===null)return this._defaults;const t=e.scopeName,r=this._cachedMatchRoot.get(t).find(i=>fI(e.parent,i.parentScopes));return r?new Cx(r.fontStyle,r.foreground,r.background):null}},dm=class ff{constructor(t,n){this.parent=t,this.scopeName=n}static push(t,n){for(const r of n)t=new ff(t,r);return t}static from(...t){let n=null;for(let r=0;r<t.length;r++)n=new ff(n,t[r]);return n}push(t){return new ff(this,t)}getSegments(){let t=this;const n=[];for(;t;)n.push(t.scopeName),t=t.parent;return n.reverse(),n}toString(){return this.getSegments().join(" ")}extends(t){return this===t?!0:this.parent===null?!1:this.parent.extends(t)}getExtensionIfDefined(t){const n=[];let r=this;for(;r&&r!==t;)n.push(r.scopeName),r=r.parent;return r===t?n.reverse():void 0}};function fI(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&&!hI(e.scopeName,r);){if(i)return!1;e=e.parent}if(!e)return!1;e=e.parent}return!0}function hI(e,t){return t===e||e.startsWith(t)&&e[t.length]==="."}var Cx=class{constructor(e,t,n){this.fontStyle=e,this.foregroundId=t,this.backgroundId=n}};function pI(e){if(!e)return[];if(!e.settings||!Array.isArray(e.settings))return[];let t=e.settings,n=[],r=0;for(let i=0,s=t.length;i<s;i++){let l=t[i];if(!l.settings)continue;let c;if(typeof l.scope=="string"){let h=l.scope;h=h.replace(/^[,]+/,""),h=h.replace(/[,]+$/,""),c=h.split(",")}else Array.isArray(l.scope)?c=l.scope:c=[""];let d=-1;if(typeof l.settings.fontStyle=="string"){d=0;let h=l.settings.fontStyle.split(" ");for(let g=0,y=h.length;g<y;g++)switch(h[g]){case"italic":d=d|1;break;case"bold":d=d|2;break;case"underline":d=d|4;break;case"strikethrough":d=d|8;break}}let f=null;typeof l.settings.foreground=="string"&&Zv(l.settings.foreground)&&(f=l.settings.foreground);let m=null;typeof l.settings.background=="string"&&Zv(l.settings.background)&&(m=l.settings.background);for(let h=0,g=c.length;h<g;h++){let w=c[h].trim().split(" "),_=w[w.length-1],C=null;w.length>1&&(C=w.slice(0,w.length-1),C.reverse()),n[r++]=new mI(_,C,i,d,f,m)}}return n}var mI=class{constructor(e,t,n,r,i,s){this.scope=e,this.parentScopes=t,this.index=n,this.fontStyle=r,this.foreground=i,this.background=s}},Tn=(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))(Tn||{});function gI(e,t){e.sort((d,f)=>{let m=xx(d.scope,f.scope);return m!==0||(m=_x(d.parentScopes,f.parentScopes),m!==0)?m:d.index-f.index});let n=0,r="#000000",i="#ffffff";for(;e.length>=1&&e[0].scope==="";){let d=e.shift();d.fontStyle!==-1&&(n=d.fontStyle),d.foreground!==null&&(r=d.foreground),d.background!==null&&(i=d.background)}let s=new vI(t),l=new Cx(n,s.getId(r),s.getId(i)),c=new wI(new rg(0,null,-1,0,0),[]);for(let d=0,f=e.length;d<f;d++){let m=e[d];c.insert(0,m.scope,m.parentScopes,m.fontStyle,s.getId(m.foreground),s.getId(m.background))}return new $f(s,l,c)}var vI=class{constructor(e){F(this,"_isFrozen");F(this,"_lastColorId");F(this,"_id2color");F(this,"_color2id");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 new 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)}},yI=Object.freeze([]),rg=class Ex{constructor(t,n,r,i,s){F(this,"scopeDepth");F(this,"parentScopes");F(this,"fontStyle");F(this,"foreground");F(this,"background");this.scopeDepth=t,this.parentScopes=n||yI,this.fontStyle=r,this.foreground=i,this.background=s}clone(){return new Ex(this.scopeDepth,this.parentScopes,this.fontStyle,this.foreground,this.background)}static cloneArr(t){let n=[];for(let r=0,i=t.length;r<i;r++)n[r]=t[r].clone();return n}acceptOverwrite(t,n,r,i){this.scopeDepth>t?console.log("how did this happen?"):this.scopeDepth=t,n!==-1&&(this.fontStyle=n),r!==0&&(this.foreground=r),i!==0&&(this.background=i)}},wI=class ig{constructor(t,n=[],r={}){F(this,"_rulesWithParentScopes");this._mainRule=t,this._children=r,this._rulesWithParentScopes=n}static _cmpBySpecificity(t,n){if(t.scopeDepth!==n.scopeDepth)return n.scopeDepth-t.scopeDepth;let r=0,i=0;for(;t.parentScopes[r]===">"&&r++,n.parentScopes[i]===">"&&i++,!(r>=t.parentScopes.length||i>=n.parentScopes.length);){const s=n.parentScopes[i].length-t.parentScopes[r].length;if(s!==0)return s;r++,i++}return n.parentScopes.length-t.parentScopes.length}match(t){if(t!==""){let r=t.indexOf("."),i,s;if(r===-1?(i=t,s=""):(i=t.substring(0,r),s=t.substring(r+1)),this._children.hasOwnProperty(i))return this._children[i].match(s)}const n=this._rulesWithParentScopes.concat(this._mainRule);return n.sort(ig._cmpBySpecificity),n}insert(t,n,r,i,s,l){if(n===""){this._doInsertHere(t,r,i,s,l);return}let c=n.indexOf("."),d,f;c===-1?(d=n,f=""):(d=n.substring(0,c),f=n.substring(c+1));let m;this._children.hasOwnProperty(d)?m=this._children[d]:(m=new ig(this._mainRule.clone(),rg.cloneArr(this._rulesWithParentScopes)),this._children[d]=m),m.insert(t+1,f,r,i,s,l)}_doInsertHere(t,n,r,i,s){if(n===null){this._mainRule.acceptOverwrite(t,r,i,s);return}for(let l=0,c=this._rulesWithParentScopes.length;l<c;l++){let d=this._rulesWithParentScopes[l];if(_x(d.parentScopes,n)===0){d.acceptOverwrite(t,r,i,s);return}}r===-1&&(r=this._mainRule.fontStyle),i===0&&(i=this._mainRule.foreground),s===0&&(s=this._mainRule.background),this._rulesWithParentScopes.push(new rg(t,n,r,i,s))}},Ll=class Ir{static toBinaryStr(t){return t.toString(2).padStart(32,"0")}static print(t){const n=Ir.getLanguageId(t),r=Ir.getTokenType(t),i=Ir.getFontStyle(t),s=Ir.getForeground(t),l=Ir.getBackground(t);console.log({languageId:n,tokenType:r,fontStyle:i,foreground:s,background:l})}static getLanguageId(t){return(t&255)>>>0}static getTokenType(t){return(t&768)>>>8}static containsBalancedBrackets(t){return(t&1024)!==0}static getFontStyle(t){return(t&30720)>>>11}static getForeground(t){return(t&16744448)>>>15}static getBackground(t){return(t&4278190080)>>>24}static set(t,n,r,i,s,l,c){let d=Ir.getLanguageId(t),f=Ir.getTokenType(t),m=Ir.containsBalancedBrackets(t)?1:0,h=Ir.getFontStyle(t),g=Ir.getForeground(t),y=Ir.getBackground(t);return n!==0&&(d=n),r!==8&&(f=r),i!==null&&(m=i?1:0),s!==-1&&(h=s),l!==0&&(g=l),c!==0&&(y=c),(d<<0|f<<8|m<<10|h<<11|g<<15|y<<24)>>>0}};function Bf(e,t){const n=[],r=bI(e);let i=r.next();for(;i!==null;){let d=0;if(i.length===2&&i.charAt(1)===":"){switch(i.charAt(0)){case"R":d=1;break;case"L":d=-1;break;default:console.log(`Unknown priority ${i} in scope selector`)}i=r.next()}let f=l();if(n.push({matcher:f,priority:d}),i!==",")break;i=r.next()}return n;function s(){if(i==="-"){i=r.next();const d=s();return f=>!!d&&!d(f)}if(i==="("){i=r.next();const d=c();return i===")"&&(i=r.next()),d}if(ey(i)){const d=[];do d.push(i),i=r.next();while(ey(i));return f=>t(d,f)}return null}function l(){const d=[];let f=s();for(;f;)d.push(f),f=s();return m=>d.every(h=>h(m))}function c(){const d=[];let f=l();for(;f&&(d.push(f),i==="|"||i===",");){do i=r.next();while(i==="|"||i===",");f=l()}return m=>d.some(h=>h(m))}}function ey(e){return!!e&&!!e.match(/[\w\.:]+/)}function bI(e){let t=/([LR]:|[\w\.:][\w\.:\-]*|[\,\|\-\(\)])/g,n=t.exec(e);return{next:()=>{if(!n)return null;const r=n[0];return n=t.exec(e),r}}}function Ix(e){typeof e.dispose=="function"&&e.dispose()}var Yc=class{constructor(e){this.scopeName=e}toKey(){return this.scopeName}},xI=class{constructor(e,t){this.scopeName=e,this.ruleName=t}toKey(){return`${this.scopeName}#${this.ruleName}`}},_I=class{constructor(){F(this,"_references",[]);F(this,"_seenReferenceKeys",new Set);F(this,"visitedRule",new Set)}get references(){return this._references}add(e){const t=e.toKey();this._seenReferenceKeys.has(t)||(this._seenReferenceKeys.add(t),this._references.push(e))}},kI=class{constructor(e,t){F(this,"seenFullScopeRequests",new Set);F(this,"seenPartialScopeRequests",new Set);F(this,"Q");this.repo=e,this.initialScopeName=t,this.seenFullScopeRequests.add(this.initialScopeName),this.Q=[new Yc(this.initialScopeName)]}processQueue(){const e=this.Q;this.Q=[];const t=new _I;for(const n of e)SI(n,this.initialScopeName,this.repo,t);for(const n of t.references)if(n instanceof Yc){if(this.seenFullScopeRequests.has(n.scopeName))continue;this.seenFullScopeRequests.add(n.scopeName),this.Q.push(n)}else{if(this.seenFullScopeRequests.has(n.scopeName)||this.seenPartialScopeRequests.has(n.toKey()))continue;this.seenPartialScopeRequests.add(n.toKey()),this.Q.push(n)}}};function SI(e,t,n,r){const i=n.lookup(e.scopeName);if(!i){if(e.scopeName===t)throw new Error(`No grammar provided for <${t}>`);return}const s=n.lookup(t);e instanceof Yc?hf({baseGrammar:s,selfGrammar:i},r):og(e.ruleName,{baseGrammar:s,selfGrammar:i,repository:i.repository},r);const l=n.injections(e.scopeName);if(l)for(const c of l)r.add(new Yc(c))}function og(e,t,n){if(t.repository&&t.repository[e]){const r=t.repository[e];jf([r],t,n)}}function hf(e,t){e.selfGrammar.patterns&&Array.isArray(e.selfGrammar.patterns)&&jf(e.selfGrammar.patterns,{...e,repository:e.selfGrammar.repository},t),e.selfGrammar.injections&&jf(Object.values(e.selfGrammar.injections),{...e,repository:e.selfGrammar.repository},t)}function jf(e,t,n){for(const r of e){if(n.visitedRule.has(r))continue;n.visitedRule.add(r);const i=r.repository?wx({},t.repository,r.repository):t.repository;Array.isArray(r.patterns)&&jf(r.patterns,{...t,repository:i},n);const s=r.include;if(!s)continue;const l=Px(s);switch(l.kind){case 0:hf({...t,selfGrammar:t.baseGrammar},n);break;case 1:hf(t,n);break;case 2:og(l.ruleName,{...t,repository:i},n);break;case 3:case 4:const c=l.scopeName===t.selfGrammar.scopeName?t.selfGrammar:l.scopeName===t.baseGrammar.scopeName?t.baseGrammar:void 0;if(c){const d={baseGrammar:t.baseGrammar,selfGrammar:c,repository:i};l.kind===4?og(l.ruleName,d,n):hf(d,n)}else l.kind===4?n.add(new xI(l.scopeName,l.ruleName)):n.add(new Yc(l.scopeName));break}}}var CI=class{constructor(){F(this,"kind",0)}},EI=class{constructor(){F(this,"kind",1)}},II=class{constructor(e){F(this,"kind",2);this.ruleName=e}},PI=class{constructor(e){F(this,"kind",3);this.scopeName=e}},LI=class{constructor(e,t){F(this,"kind",4);this.scopeName=e,this.ruleName=t}};function Px(e){if(e==="$base")return new CI;if(e==="$self")return new EI;const t=e.indexOf("#");if(t===-1)return new PI(e);if(t===0)return new II(e.substring(1));{const n=e.substring(0,t),r=e.substring(t+1);return new LI(n,r)}}var DI=/\\(\d+)/,ty=/\\(\d+)/g,AI=-1,Lx=-2;var Pu=class{constructor(e,t,n,r){F(this,"$location");F(this,"id");F(this,"_nameIsCapturing");F(this,"_name");F(this,"_contentNameIsCapturing");F(this,"_contentName");this.$location=e,this.id=t,this._name=n||null,this._nameIsCapturing=Ud.hasCaptures(this._name),this._contentName=r||null,this._contentNameIsCapturing=Ud.hasCaptures(this._contentName)}get debugName(){const e=this.$location?`${bx(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:Ud.replaceCaptures(this._name,e,t)}getContentName(e,t){return!this._contentNameIsCapturing||this._contentName===null?this._contentName:Ud.replaceCaptures(this._contentName,e,t)}},TI=class extends Pu{constructor(t,n,r,i,s){super(t,n,r,i);F(this,"retokenizeCapturedWithRuleId");this.retokenizeCapturedWithRuleId=s}dispose(){}collectPatterns(t,n){throw new Error("Not supported!")}compile(t,n){throw new Error("Not supported!")}compileAG(t,n,r,i){throw new Error("Not supported!")}},RI=class extends Pu{constructor(t,n,r,i,s){super(t,n,r,null);F(this,"_match");F(this,"captures");F(this,"_cachedCompiledPatterns");this._match=new Jc(i,this.id),this.captures=s,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}get debugMatchRegExp(){return`${this._match.source}`}collectPatterns(t,n){n.push(this._match)}compile(t,n){return this._getCachedCompiledPatterns(t).compile(t)}compileAG(t,n,r,i){return this._getCachedCompiledPatterns(t).compileAG(t,r,i)}_getCachedCompiledPatterns(t){return this._cachedCompiledPatterns||(this._cachedCompiledPatterns=new Zc,this.collectPatterns(t,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},ny=class extends Pu{constructor(t,n,r,i,s){super(t,n,r,i);F(this,"hasMissingPatterns");F(this,"patterns");F(this,"_cachedCompiledPatterns");this.patterns=s.patterns,this.hasMissingPatterns=s.hasMissingPatterns,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}collectPatterns(t,n){for(const r of this.patterns)t.getRule(r).collectPatterns(t,n)}compile(t,n){return this._getCachedCompiledPatterns(t).compile(t)}compileAG(t,n,r,i){return this._getCachedCompiledPatterns(t).compileAG(t,r,i)}_getCachedCompiledPatterns(t){return this._cachedCompiledPatterns||(this._cachedCompiledPatterns=new Zc,this.collectPatterns(t,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},sg=class extends Pu{constructor(t,n,r,i,s,l,c,d,f,m){super(t,n,r,i);F(this,"_begin");F(this,"beginCaptures");F(this,"_end");F(this,"endHasBackReferences");F(this,"endCaptures");F(this,"applyEndPatternLast");F(this,"hasMissingPatterns");F(this,"patterns");F(this,"_cachedCompiledPatterns");this._begin=new Jc(s,this.id),this.beginCaptures=l,this._end=new Jc(c||"￿",-1),this.endHasBackReferences=this._end.hasBackReferences,this.endCaptures=d,this.applyEndPatternLast=f||!1,this.patterns=m.patterns,this.hasMissingPatterns=m.hasMissingPatterns,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}get debugBeginRegExp(){return`${this._begin.source}`}get debugEndRegExp(){return`${this._end.source}`}getEndWithResolvedBackReferences(t,n){return this._end.resolveBackReferences(t,n)}collectPatterns(t,n){n.push(this._begin)}compile(t,n){return this._getCachedCompiledPatterns(t,n).compile(t)}compileAG(t,n,r,i){return this._getCachedCompiledPatterns(t,n).compileAG(t,r,i)}_getCachedCompiledPatterns(t,n){if(!this._cachedCompiledPatterns){this._cachedCompiledPatterns=new Zc;for(const r of this.patterns)t.getRule(r).collectPatterns(t,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,n):this._cachedCompiledPatterns.setSource(0,n)),this._cachedCompiledPatterns}},Vf=class extends Pu{constructor(t,n,r,i,s,l,c,d,f){super(t,n,r,i);F(this,"_begin");F(this,"beginCaptures");F(this,"whileCaptures");F(this,"_while");F(this,"whileHasBackReferences");F(this,"hasMissingPatterns");F(this,"patterns");F(this,"_cachedCompiledPatterns");F(this,"_cachedCompiledWhilePatterns");this._begin=new Jc(s,this.id),this.beginCaptures=l,this.whileCaptures=d,this._while=new Jc(c,Lx),this.whileHasBackReferences=this._while.hasBackReferences,this.patterns=f.patterns,this.hasMissingPatterns=f.hasMissingPatterns,this._cachedCompiledPatterns=null,this._cachedCompiledWhilePatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null),this._cachedCompiledWhilePatterns&&(this._cachedCompiledWhilePatterns.dispose(),this._cachedCompiledWhilePatterns=null)}get debugBeginRegExp(){return`${this._begin.source}`}get debugWhileRegExp(){return`${this._while.source}`}getWhileWithResolvedBackReferences(t,n){return this._while.resolveBackReferences(t,n)}collectPatterns(t,n){n.push(this._begin)}compile(t,n){return this._getCachedCompiledPatterns(t).compile(t)}compileAG(t,n,r,i){return this._getCachedCompiledPatterns(t).compileAG(t,r,i)}_getCachedCompiledPatterns(t){if(!this._cachedCompiledPatterns){this._cachedCompiledPatterns=new Zc;for(const n of this.patterns)t.getRule(n).collectPatterns(t,this._cachedCompiledPatterns)}return this._cachedCompiledPatterns}compileWhile(t,n){return this._getCachedCompiledWhilePatterns(t,n).compile(t)}compileWhileAG(t,n,r,i){return this._getCachedCompiledWhilePatterns(t,n).compileAG(t,r,i)}_getCachedCompiledWhilePatterns(t,n){return this._cachedCompiledWhilePatterns||(this._cachedCompiledWhilePatterns=new Zc,this._cachedCompiledWhilePatterns.push(this._while.hasBackReferences?this._while.clone():this._while)),this._while.hasBackReferences&&this._cachedCompiledWhilePatterns.setSource(0,n||"￿"),this._cachedCompiledWhilePatterns}},Dx=class An{static createCaptureRule(t,n,r,i,s){return t.registerRule(l=>new TI(n,l,r,i,s))}static getCompiledRuleId(t,n,r){return t.id||n.registerRule(i=>{if(t.id=i,t.match)return new RI(t.$vscodeTextmateLocation,t.id,t.name,t.match,An._compileCaptures(t.captures,n,r));if(typeof t.begin>"u"){t.repository&&(r=wx({},r,t.repository));let s=t.patterns;return typeof s>"u"&&t.include&&(s=[{include:t.include}]),new ny(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,An._compilePatterns(s,n,r))}return t.while?new Vf(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,t.begin,An._compileCaptures(t.beginCaptures||t.captures,n,r),t.while,An._compileCaptures(t.whileCaptures||t.captures,n,r),An._compilePatterns(t.patterns,n,r)):new sg(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,t.begin,An._compileCaptures(t.beginCaptures||t.captures,n,r),t.end,An._compileCaptures(t.endCaptures||t.captures,n,r),t.applyEndPatternLast,An._compilePatterns(t.patterns,n,r))}),t.id}static _compileCaptures(t,n,r){let i=[];if(t){let s=0;for(const l in t){if(l==="$vscodeTextmateLocation")continue;const c=parseInt(l,10);c>s&&(s=c)}for(let l=0;l<=s;l++)i[l]=null;for(const l in t){if(l==="$vscodeTextmateLocation")continue;const c=parseInt(l,10);let d=0;t[l].patterns&&(d=An.getCompiledRuleId(t[l],n,r)),i[c]=An.createCaptureRule(n,t[l].$vscodeTextmateLocation,t[l].name,t[l].contentName,d)}}return i}static _compilePatterns(t,n,r){let i=[];if(t)for(let s=0,l=t.length;s<l;s++){const c=t[s];let d=-1;if(c.include){const f=Px(c.include);switch(f.kind){case 0:case 1:d=An.getCompiledRuleId(r[c.include],n,r);break;case 2:let m=r[f.ruleName];m&&(d=An.getCompiledRuleId(m,n,r));break;case 3:case 4:const h=f.scopeName,g=f.kind===4?f.ruleName:null,y=n.getExternalGrammar(h,r);if(y)if(g){let w=y.repository[g];w&&(d=An.getCompiledRuleId(w,n,y.repository))}else d=An.getCompiledRuleId(y.repository.$self,n,y.repository);break}}else d=An.getCompiledRuleId(c,n,r);if(d!==-1){const f=n.getRule(d);let m=!1;if((f instanceof ny||f instanceof sg||f instanceof Vf)&&f.hasMissingPatterns&&f.patterns.length===0&&(m=!0),m)continue;i.push(d)}}return{patterns:i,hasMissingPatterns:(t?t.length:0)!==i.length}}},Jc=class Ax{constructor(t,n){F(this,"source");F(this,"ruleId");F(this,"hasAnchor");F(this,"hasBackReferences");F(this,"_anchorCache");if(t&&typeof t=="string"){const r=t.length;let i=0,s=[],l=!1;for(let c=0;c<r;c++)if(t.charAt(c)==="\\"&&c+1<r){const f=t.charAt(c+1);f==="z"?(s.push(t.substring(i,c)),s.push("$(?!\\n)(?<!\\n)"),i=c+2):(f==="A"||f==="G")&&(l=!0),c++}this.hasAnchor=l,i===0?this.source=t:(s.push(t.substring(i,r)),this.source=s.join(""))}else this.hasAnchor=!1,this.source=t;this.hasAnchor?this._anchorCache=this._buildAnchorCache():this._anchorCache=null,this.ruleId=n,typeof this.source=="string"?this.hasBackReferences=DI.test(this.source):this.hasBackReferences=!1}clone(){return new Ax(this.source,this.ruleId)}setSource(t){this.source!==t&&(this.source=t,this.hasAnchor&&(this._anchorCache=this._buildAnchorCache()))}resolveBackReferences(t,n){if(typeof this.source!="string")throw new Error("This method should only be called if the source is a string");let r=n.map(i=>t.substring(i.start,i.end));return ty.lastIndex=0,this.source.replace(ty,(i,s)=>kx(r[parseInt(s,10)]||""))}_buildAnchorCache(){if(typeof this.source!="string")throw new Error("This method should only be called if the source is a string");let t=[],n=[],r=[],i=[],s,l,c,d;for(s=0,l=this.source.length;s<l;s++)c=this.source.charAt(s),t[s]=c,n[s]=c,r[s]=c,i[s]=c,c==="\\"&&s+1<l&&(d=this.source.charAt(s+1),d==="A"?(t[s+1]="￿",n[s+1]="￿",r[s+1]="A",i[s+1]="A"):d==="G"?(t[s+1]="￿",n[s+1]="G",r[s+1]="￿",i[s+1]="G"):(t[s+1]=d,n[s+1]=d,r[s+1]=d,i[s+1]=d),s++);return{A0_G0:t.join(""),A0_G1:n.join(""),A1_G0:r.join(""),A1_G1:i.join("")}}resolveAnchors(t,n){return!this.hasAnchor||!this._anchorCache||typeof this.source!="string"?this.source:t?n?this._anchorCache.A1_G1:this._anchorCache.A1_G0:n?this._anchorCache.A0_G1:this._anchorCache.A0_G0}},Zc=class{constructor(){F(this,"_items");F(this,"_hasAnchors");F(this,"_cached");F(this,"_anchorCache");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(),this._cached=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(n=>n.source);this._cached=new ry(e,t,this._items.map(n=>n.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){let r=this._items.map(i=>i.resolveAnchors(t,n));return new ry(e,r,this._items.map(i=>i.ruleId))}},ry=class{constructor(e,t,n){F(this,"scanner");this.regExps=t,this.rules=n,this.scanner=e.createOnigScanner(t)}dispose(){typeof this.scanner.dispose=="function"&&this.scanner.dispose()}toString(){const e=[];for(let t=0,n=this.rules.length;t<n;t++)e.push(" - "+this.rules[t]+": "+this.regExps[t]);return e.join(`
201
+ `)}findNextMatchSync(e,t,n){const r=this.scanner.findNextMatchSync(e,t,n);return r?{ruleId:this.rules[r.index],captureIndices:r.captureIndices}:null}},fm=class{constructor(e,t){this.languageId=e,this.tokenType=t}},vo,NI=(vo=class{constructor(t,n){F(this,"_defaultAttributes");F(this,"_embeddedLanguagesMatcher");F(this,"_getBasicScopeAttributes",new Sx(t=>{const n=this._scopeToLanguage(t),r=this._toStandardTokenType(t);return new fm(n,r)}));this._defaultAttributes=new fm(t,8),this._embeddedLanguagesMatcher=new FI(Object.entries(n||{}))}getDefaultAttributes(){return this._defaultAttributes}getBasicScopeAttributes(t){return t===null?vo._NULL_SCOPE_METADATA:this._getBasicScopeAttributes.get(t)}_scopeToLanguage(t){return this._embeddedLanguagesMatcher.match(t)||0}_toStandardTokenType(t){const n=t.match(vo.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 new Error("Unexpected match for standard token type!")}},F(vo,"_NULL_SCOPE_METADATA",new fm(0,0)),F(vo,"STANDARD_TOKEN_TYPE_REGEXP",/\b(comment|string|regex|meta\.embedded)\b/),vo),FI=class{constructor(e){F(this,"values");F(this,"scopesRegExp");if(e.length===0)this.values=null,this.scopesRegExp=null;else{this.values=new Map(e);const t=e.map(([n,r])=>kx(n));t.sort(),t.reverse(),this.scopesRegExp=new RegExp(`^((${t.join(")|(")}))($|\\.)`,"")}}match(e){if(!this.scopesRegExp)return;const t=e.match(this.scopesRegExp);if(t)return this.values.get(t[1])}},iy=class{constructor(e,t){this.stack=e,this.stoppedEarly=t}};function Tx(e,t,n,r,i,s,l,c){const d=t.content.length;let f=!1,m=-1;if(l){const y=MI(e,t,n,r,i,s);i=y.stack,r=y.linePos,n=y.isFirstLine,m=y.anchorPosition}const h=Date.now();for(;!f;){if(c!==0&&Date.now()-h>c)return new iy(i,!0);g()}return new iy(i,!1);function g(){const y=OI(e,t,n,r,i,m);if(!y){s.produce(i,d),f=!0;return}const w=y.captureIndices,_=y.matchedRuleId,C=w&&w.length>0?w[0].end>r:!1;if(_===AI){const I=i.getRule(e);s.produce(i,w[0].start),i=i.withContentNameScopesList(i.nameScopesList),Nc(e,t,n,i,s,I.endCaptures,w),s.produce(i,w[0].end);const E=i;if(i=i.parent,m=E.getAnchorPos(),!C&&E.getEnterPos()===r){i=E,s.produce(i,d),f=!0;return}}else{const I=e.getRule(_);s.produce(i,w[0].start);const E=i,S=I.getName(t.content,w),L=i.contentNameScopesList.pushAttributed(S,e);if(i=i.push(_,r,m,w[0].end===d,null,L,L),I instanceof sg){const A=I;Nc(e,t,n,i,s,A.beginCaptures,w),s.produce(i,w[0].end),m=w[0].end;const R=A.getContentName(t.content,w),U=L.pushAttributed(R,e);if(i=i.withContentNameScopesList(U),A.endHasBackReferences&&(i=i.withEndRule(A.getEndWithResolvedBackReferences(t.content,w))),!C&&E.hasSameRuleAs(i)){i=i.pop(),s.produce(i,d),f=!0;return}}else if(I instanceof Vf){const A=I;Nc(e,t,n,i,s,A.beginCaptures,w),s.produce(i,w[0].end),m=w[0].end;const R=A.getContentName(t.content,w),U=L.pushAttributed(R,e);if(i=i.withContentNameScopesList(U),A.whileHasBackReferences&&(i=i.withEndRule(A.getWhileWithResolvedBackReferences(t.content,w))),!C&&E.hasSameRuleAs(i)){i=i.pop(),s.produce(i,d),f=!0;return}}else if(Nc(e,t,n,i,s,I.captures,w),s.produce(i,w[0].end),i=i.pop(),!C){i=i.safePop(),s.produce(i,d),f=!0;return}}w[0].end>r&&(r=w[0].end,n=!1)}}function MI(e,t,n,r,i,s){let l=i.beginRuleCapturedEOL?0:-1;const c=[];for(let d=i;d;d=d.pop()){const f=d.getRule(e);f instanceof Vf&&c.push({rule:f,stack:d})}for(let d=c.pop();d;d=c.pop()){const{ruleScanner:f,findOptions:m}=jI(d.rule,e,d.stack.endRule,n,r===l),h=f.findNextMatchSync(t,r,m);if(h){if(h.ruleId!==Lx){i=d.stack.pop();break}h.captureIndices&&h.captureIndices.length&&(s.produce(d.stack,h.captureIndices[0].start),Nc(e,t,n,d.stack,s,d.rule.whileCaptures,h.captureIndices),s.produce(d.stack,h.captureIndices[0].end),l=h.captureIndices[0].end,h.captureIndices[0].end>r&&(r=h.captureIndices[0].end,n=!1))}else{i=d.stack.pop();break}}return{stack:i,linePos:r,anchorPosition:l,isFirstLine:n}}function OI(e,t,n,r,i,s){const l=$I(e,t,n,r,i,s),c=e.getInjections();if(c.length===0)return l;const d=BI(c,e,t,n,r,i,s);if(!d)return l;if(!l)return d;const f=l.captureIndices[0].start,m=d.captureIndices[0].start;return m<f||d.priorityMatch&&m===f?d:l}function $I(e,t,n,r,i,s){const l=i.getRule(e),{ruleScanner:c,findOptions:d}=Rx(l,e,i.endRule,n,r===s),f=c.findNextMatchSync(t,r,d);return f?{captureIndices:f.captureIndices,matchedRuleId:f.ruleId}:null}function BI(e,t,n,r,i,s,l){let c=Number.MAX_VALUE,d=null,f,m=0;const h=s.contentNameScopesList.getScopeNames();for(let g=0,y=e.length;g<y;g++){const w=e[g];if(!w.matcher(h))continue;const _=t.getRule(w.ruleId),{ruleScanner:C,findOptions:I}=Rx(_,t,null,r,i===l),E=C.findNextMatchSync(n,i,I);if(!E)continue;const S=E.captureIndices[0].start;if(!(S>=c)&&(c=S,d=E.captureIndices,f=E.ruleId,m=w.priority,c===i))break}return d?{priorityMatch:m===-1,captureIndices:d,matchedRuleId:f}:null}function Rx(e,t,n,r,i){return{ruleScanner:e.compileAG(t,n,r,i),findOptions:0}}function jI(e,t,n,r,i){return{ruleScanner:e.compileWhileAG(t,n,r,i),findOptions:0}}function Nc(e,t,n,r,i,s,l){if(s.length===0)return;const c=t.content,d=Math.min(s.length,l.length),f=[],m=l[0].end;for(let h=0;h<d;h++){const g=s[h];if(g===null)continue;const y=l[h];if(y.length===0)continue;if(y.start>m)break;for(;f.length>0&&f[f.length-1].endPos<=y.start;)i.produceFromScopes(f[f.length-1].scopes,f[f.length-1].endPos),f.pop();if(f.length>0?i.produceFromScopes(f[f.length-1].scopes,y.start):i.produce(r,y.start),g.retokenizeCapturedWithRuleId){const _=g.getName(c,l),C=r.contentNameScopesList.pushAttributed(_,e),I=g.getContentName(c,l),E=C.pushAttributed(I,e),S=r.push(g.retokenizeCapturedWithRuleId,y.start,-1,!1,null,C,E),L=e.createOnigString(c.substring(0,y.end));Tx(e,L,n&&y.start===0,y.start,S,i,!1,0),Ix(L);continue}const w=g.getName(c,l);if(w!==null){const C=(f.length>0?f[f.length-1].scopes:r.contentNameScopesList).pushAttributed(w,e);f.push(new VI(C,y.end))}}for(;f.length>0;)i.produceFromScopes(f[f.length-1].scopes,f[f.length-1].endPos),f.pop()}var VI=class{constructor(e,t){F(this,"scopes");F(this,"endPos");this.scopes=e,this.endPos=t}};function UI(e,t,n,r,i,s,l,c){return new HI(e,t,n,r,i,s,l,c)}function oy(e,t,n,r,i){const s=Bf(t,Uf),l=Dx.getCompiledRuleId(n,r,i.repository);for(const c of s)e.push({debugSelector:t,matcher:c.matcher,ruleId:l,grammar:i,priority:c.priority})}function Uf(e,t){if(t.length<e.length)return!1;let n=0;return e.every(r=>{for(let i=n;i<t.length;i++)if(zI(t[i],r))return n=i+1,!0;return!1})}function zI(e,t){if(!e)return!1;if(e===t)return!0;const n=t.length;return e.length>n&&e.substr(0,n)===t&&e[n]==="."}var HI=class{constructor(e,t,n,r,i,s,l,c){F(this,"_rootId");F(this,"_lastRuleId");F(this,"_ruleId2desc");F(this,"_includedGrammars");F(this,"_grammarRepository");F(this,"_grammar");F(this,"_injections");F(this,"_basicScopeAttributesProvider");F(this,"_tokenTypeMatchers");if(this._rootScopeName=e,this.balancedBracketSelectors=s,this._onigLib=c,this._basicScopeAttributesProvider=new NI(n,r),this._rootId=-1,this._lastRuleId=0,this._ruleId2desc=[null],this._includedGrammars={},this._grammarRepository=l,this._grammar=sy(t,null),this._injections=null,this._tokenTypeMatchers=[],i)for(const d of Object.keys(i)){const f=Bf(d,Uf);for(const m of f)this._tokenTypeMatchers.push({matcher:m.matcher,type:i[d]})}}get themeProvider(){return this._grammarRepository}dispose(){for(const e of this._ruleId2desc)e&&e.dispose()}createOnigScanner(e){return this._onigLib.createOnigScanner(e)}createOnigString(e){return this._onigLib.createOnigString(e)}getMetadataForScope(e){return this._basicScopeAttributesProvider.getBasicScopeAttributes(e)}_collectInjections(){const e={lookup:i=>i===this._rootScopeName?this._grammar:this.getExternalGrammar(i),injections:i=>this._grammarRepository.injections(i)},t=[],n=this._rootScopeName,r=e.lookup(n);if(r){const i=r.injections;if(i)for(let l in i)oy(t,l,i[l],this,r);const s=this._grammarRepository.injections(n);s&&s.forEach(l=>{const c=this.getExternalGrammar(l);if(c){const d=c.injectionSelector;d&&oy(t,d,c,this,c)}})}return t.sort((i,s)=>i.priority-s.priority),t}getInjections(){return this._injections===null&&(this._injections=this._collectInjections()),this._injections}registerRule(e){const t=++this._lastRuleId,n=e(t);return this._ruleId2desc[t]=n,n}getRule(e){return this._ruleId2desc[e]}getExternalGrammar(e,t){if(this._includedGrammars[e])return this._includedGrammars[e];if(this._grammarRepository){const n=this._grammarRepository.lookup(e);if(n)return this._includedGrammars[e]=sy(n,t&&t.$base),this._includedGrammars[e]}}tokenizeLine(e,t,n=0){const 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){const 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=Dx.getCompiledRuleId(this._grammar.repository.$self,this,this._grammar.repository),this.getInjections());let i;if(!t||t===ag.NULL){i=!0;const f=this._basicScopeAttributesProvider.getDefaultAttributes(),m=this.themeProvider.getDefaults(),h=Ll.set(0,f.languageId,f.tokenType,null,m.fontStyle,m.foregroundId,m.backgroundId),g=this.getRule(this._rootId).getName(null,null);let y;g?y=Uc.createRootAndLookUpScopeName(g,h,this):y=Uc.createRoot("unknown",h),t=new ag(null,this._rootId,-1,-1,!1,null,y,y)}else i=!1,t.reset();e=e+`
202
+ `;const s=this.createOnigString(e),l=s.content.length,c=new GI(n,e,this._tokenTypeMatchers,this.balancedBracketSelectors),d=Tx(this,s,i,0,t,c,!0,r);return Ix(s),{lineLength:l,lineTokens:c,ruleStack:d.stack,stoppedEarly:d.stoppedEarly}}};function sy(e,t){return e=cI(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 Uc=class Ci{constructor(t,n,r){this.parent=t,this.scopePath=n,this.tokenAttributes=r}static fromExtension(t,n){let r=t,i=(t==null?void 0:t.scopePath)??null;for(const s of n)i=dm.push(i,s.scopeNames),r=new Ci(r,i,s.encodedTokenAttributes);return r}static createRoot(t,n){return new Ci(null,new dm(null,t),n)}static createRootAndLookUpScopeName(t,n,r){const i=r.getMetadataForScope(t),s=new dm(null,t),l=r.themeProvider.themeMatch(s),c=Ci.mergeAttributes(n,i,l);return new Ci(null,s,c)}get scopeName(){return this.scopePath.scopeName}toString(){return this.getScopeNames().join(" ")}equals(t){return Ci.equals(this,t)}static equals(t,n){do{if(t===n||!t&&!n)return!0;if(!t||!n||t.scopeName!==n.scopeName||t.tokenAttributes!==n.tokenAttributes)return!1;t=t.parent,n=n.parent}while(!0)}static mergeAttributes(t,n,r){let i=-1,s=0,l=0;return r!==null&&(i=r.fontStyle,s=r.foregroundId,l=r.backgroundId),Ll.set(t,n.languageId,n.tokenType,null,i,s,l)}pushAttributed(t,n){if(t===null)return this;if(t.indexOf(" ")===-1)return Ci._pushAttributed(this,t,n);const r=t.split(/ /g);let i=this;for(const s of r)i=Ci._pushAttributed(i,s,n);return i}static _pushAttributed(t,n,r){const i=r.getMetadataForScope(n),s=t.scopePath.push(n),l=r.themeProvider.themeMatch(s),c=Ci.mergeAttributes(t.tokenAttributes,i,l);return new Ci(t,s,c)}getScopeNames(){return this.scopePath.getSegments()}getExtensionIfDefined(t){var i;const n=[];let r=this;for(;r&&r!==t;)n.push({encodedTokenAttributes:r.tokenAttributes,scopeNames:r.scopePath.getExtensionIfDefined(((i=r.parent)==null?void 0:i.scopePath)??null)}),r=r.parent;return r===t?n.reverse():void 0}},Ar,ag=(Ar=class{constructor(t,n,r,i,s,l,c,d){F(this,"_stackElementBrand");F(this,"_enterPos");F(this,"_anchorPos");F(this,"depth");this.parent=t,this.ruleId=n,this.beginRuleCapturedEOL=s,this.endRule=l,this.nameScopesList=c,this.contentNameScopesList=d,this.depth=this.parent?this.parent.depth+1:1,this._enterPos=r,this._anchorPos=i}equals(t){return t===null?!1:Ar._equals(this,t)}static _equals(t,n){return t===n?!0:this._structuralEquals(t,n)?Uc.equals(t.contentNameScopesList,n.contentNameScopesList):!1}static _structuralEquals(t,n){do{if(t===n||!t&&!n)return!0;if(!t||!n||t.depth!==n.depth||t.ruleId!==n.ruleId||t.endRule!==n.endRule)return!1;t=t.parent,n=n.parent}while(!0)}clone(){return this}static _reset(t){for(;t;)t._enterPos=-1,t._anchorPos=-1,t=t.parent}reset(){Ar._reset(this)}pop(){return this.parent}safePop(){return this.parent?this.parent:this}push(t,n,r,i,s,l,c){return new Ar(this,t,n,r,i,s,l,c)}getEnterPos(){return this._enterPos}getAnchorPos(){return this._anchorPos}getRule(t){return t.getRule(this.ruleId)}toString(){const t=[];return this._writeString(t,0),"["+t.join(",")+"]"}_writeString(t,n){var r,i;return this.parent&&(n=this.parent._writeString(t,n)),t[n++]=`(${this.ruleId}, ${(r=this.nameScopesList)==null?void 0:r.toString()}, ${(i=this.contentNameScopesList)==null?void 0:i.toString()})`,n}withContentNameScopesList(t){return this.contentNameScopesList===t?this:this.parent.push(this.ruleId,this._enterPos,this._anchorPos,this.beginRuleCapturedEOL,this.endRule,this.nameScopesList,t)}withEndRule(t){return this.endRule===t?this:new Ar(this.parent,this.ruleId,this._enterPos,this._anchorPos,this.beginRuleCapturedEOL,t,this.nameScopesList,this.contentNameScopesList)}hasSameRuleAs(t){let n=this;for(;n&&n._enterPos===t._enterPos;){if(n.ruleId===t.ruleId)return!0;n=n.parent}return!1}toStateStackFrame(){var t,n,r;return{ruleId:this.ruleId,beginRuleCapturedEOL:this.beginRuleCapturedEOL,endRule:this.endRule,nameScopesList:((n=this.nameScopesList)==null?void 0:n.getExtensionIfDefined(((t=this.parent)==null?void 0:t.nameScopesList)??null))??[],contentNameScopesList:((r=this.contentNameScopesList)==null?void 0:r.getExtensionIfDefined(this.nameScopesList))??[]}}static pushFrame(t,n){const r=Uc.fromExtension((t==null?void 0:t.nameScopesList)??null,n.nameScopesList);return new Ar(t,n.ruleId,n.enterPos??-1,n.anchorPos??-1,n.beginRuleCapturedEOL,n.endRule,r,Uc.fromExtension(r,n.contentNameScopesList))}},F(Ar,"NULL",new Ar(null,0,0,0,!1,null,null,null)),Ar),WI=class{constructor(e,t){F(this,"balancedBracketScopes");F(this,"unbalancedBracketScopes");F(this,"allowAny",!1);this.balancedBracketScopes=e.flatMap(n=>n==="*"?(this.allowAny=!0,[]):Bf(n,Uf).map(r=>r.matcher)),this.unbalancedBracketScopes=t.flatMap(n=>Bf(n,Uf).map(r=>r.matcher))}get matchesAlways(){return this.allowAny&&this.unbalancedBracketScopes.length===0}get matchesNever(){return this.balancedBracketScopes.length===0&&!this.allowAny}match(e){for(const t of this.unbalancedBracketScopes)if(t(e))return!1;for(const t of this.balancedBracketScopes)if(t(e))return!0;return this.allowAny}},GI=class{constructor(e,t,n,r){F(this,"_emitBinaryTokens");F(this,"_lineText");F(this,"_tokens");F(this,"_binaryTokens");F(this,"_lastTokenEndIndex");F(this,"_tokenTypeOverrides");this.balancedBracketSelectors=r,this._emitBinaryTokens=e,this._tokenTypeOverrides=n,this._lineText=null,this._tokens=[],this._binaryTokens=[],this._lastTokenEndIndex=0}produce(e,t){this.produceFromScopes(e.contentNameScopesList,t)}produceFromScopes(e,t){var r;if(this._lastTokenEndIndex>=t)return;if(this._emitBinaryTokens){let i=(e==null?void 0:e.tokenAttributes)??0,s=!1;if((r=this.balancedBracketSelectors)!=null&&r.matchesAlways&&(s=!0),this._tokenTypeOverrides.length>0||this.balancedBracketSelectors&&!this.balancedBracketSelectors.matchesAlways&&!this.balancedBracketSelectors.matchesNever){const l=(e==null?void 0:e.getScopeNames())??[];for(const c of this._tokenTypeOverrides)c.matcher(l)&&(i=Ll.set(i,0,c.type,null,-1,0,0));this.balancedBracketSelectors&&(s=this.balancedBracketSelectors.match(l))}if(s&&(i=Ll.set(i,0,8,s,-1,0,0)),this._binaryTokens.length>0&&this._binaryTokens[this._binaryTokens.length-1]===i){this._lastTokenEndIndex=t;return}this._binaryTokens.push(this._lastTokenEndIndex),this._binaryTokens.push(i),this._lastTokenEndIndex=t;return}const n=(e==null?void 0: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);const n=new Uint32Array(this._binaryTokens.length);for(let r=0,i=this._binaryTokens.length;r<i;r++)n[r]=this._binaryTokens[r];return n}},qI=class{constructor(e,t){F(this,"_grammars",new Map);F(this,"_rawGrammars",new Map);F(this,"_injectionGrammars",new Map);F(this,"_theme");this._onigLib=t,this._theme=e}dispose(){for(const 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 s=this._rawGrammars.get(e);if(!s)return null;this._grammars.set(e,UI(e,s,t,n,r,i,this,this._onigLib))}return this._grammars.get(e)}},KI=class{constructor(t){F(this,"_options");F(this,"_syncRegistry");F(this,"_ensureGrammarCache");this._options=t,this._syncRegistry=new qI($f.createFromRawTheme(t.theme,t.colorMap),t.onigLib),this._ensureGrammarCache=new Map}dispose(){this._syncRegistry.dispose()}setTheme(t,n){this._syncRegistry.setTheme($f.createFromRawTheme(t,n))}getColorMap(){return this._syncRegistry.getColorMap()}loadGrammarWithEmbeddedLanguages(t,n,r){return this.loadGrammarWithConfiguration(t,n,{embeddedLanguages:r})}loadGrammarWithConfiguration(t,n,r){return this._loadGrammar(t,n,r.embeddedLanguages,r.tokenTypes,new WI(r.balancedBracketSelectors||[],r.unbalancedBracketSelectors||[]))}loadGrammar(t){return this._loadGrammar(t,0,null,null,null)}_loadGrammar(t,n,r,i,s){const l=new kI(this._syncRegistry,t);for(;l.Q.length>0;)l.Q.map(c=>this._loadSingleGrammar(c.scopeName)),l.processQueue();return this._grammarForScopeName(t,n,r,i,s)}_loadSingleGrammar(t){this._ensureGrammarCache.has(t)||(this._doLoadSingleGrammar(t),this._ensureGrammarCache.set(t,!0))}_doLoadSingleGrammar(t){const n=this._options.loadGrammar(t);if(n){const r=typeof this._options.getInjections=="function"?this._options.getInjections(t):void 0;this._syncRegistry.addGrammar(n,r)}}addGrammar(t,n=[],r=0,i=null){return this._syncRegistry.addGrammar(t,n),this._grammarForScopeName(t.scopeName,r,i)}_grammarForScopeName(t,n=0,r=null,i=null,s=null){return this._syncRegistry.grammarForScopeName(t,n,r,i,s)}},lg=ag.NULL;const XI=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"];class Lu{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}}Lu.prototype.normal={};Lu.prototype.property={};Lu.prototype.space=void 0;function Nx(e,t){const n={},r={};for(const i of e)Object.assign(n,i.property),Object.assign(r,i.normal);return new Lu(n,r,t)}function cg(e){return e.toLowerCase()}class Zn{constructor(t,n){this.attribute=n,this.property=t}}Zn.prototype.attribute="";Zn.prototype.booleanish=!1;Zn.prototype.boolean=!1;Zn.prototype.commaOrSpaceSeparated=!1;Zn.prototype.commaSeparated=!1;Zn.prototype.defined=!1;Zn.prototype.mustUseProperty=!1;Zn.prototype.number=!1;Zn.prototype.overloadedBoolean=!1;Zn.prototype.property="";Zn.prototype.spaceSeparated=!1;Zn.prototype.space=void 0;let QI=0;const Ke=ca(),Kt=ca(),ug=ca(),pe=ca(),xt=ca(),cl=ca(),cr=ca();function ca(){return 2**++QI}const dg=Object.freeze(Object.defineProperty({__proto__:null,boolean:Ke,booleanish:Kt,commaOrSpaceSeparated:cr,commaSeparated:cl,number:pe,overloadedBoolean:ug,spaceSeparated:xt},Symbol.toStringTag,{value:"Module"})),hm=Object.keys(dg);class x0 extends Zn{constructor(t,n,r,i){let s=-1;if(super(t,n),ay(this,"space",i),typeof r=="number")for(;++s<hm.length;){const l=hm[s];ay(this,hm[s],(r&dg[l])===dg[l])}}}x0.prototype.defined=!0;function ay(e,t,n){n&&(e[t]=n)}function Ml(e){const t={},n={};for(const[r,i]of Object.entries(e.properties)){const s=new x0(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(s.mustUseProperty=!0),t[r]=s,n[cg(r)]=r,n[cg(s.attribute)]=r}return new Lu(t,n,e.space)}const Fx=Ml({properties:{ariaActiveDescendant:null,ariaAtomic:Kt,ariaAutoComplete:null,ariaBusy:Kt,ariaChecked:Kt,ariaColCount:pe,ariaColIndex:pe,ariaColSpan:pe,ariaControls:xt,ariaCurrent:null,ariaDescribedBy:xt,ariaDetails:null,ariaDisabled:Kt,ariaDropEffect:xt,ariaErrorMessage:null,ariaExpanded:Kt,ariaFlowTo:xt,ariaGrabbed:Kt,ariaHasPopup:null,ariaHidden:Kt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:xt,ariaLevel:pe,ariaLive:null,ariaModal:Kt,ariaMultiLine:Kt,ariaMultiSelectable:Kt,ariaOrientation:null,ariaOwns:xt,ariaPlaceholder:null,ariaPosInSet:pe,ariaPressed:Kt,ariaReadOnly:Kt,ariaRelevant:null,ariaRequired:Kt,ariaRoleDescription:xt,ariaRowCount:pe,ariaRowIndex:pe,ariaRowSpan:pe,ariaSelected:Kt,ariaSetSize:pe,ariaSort:null,ariaValueMax:pe,ariaValueMin:pe,ariaValueNow:pe,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function Mx(e,t){return t in e?e[t]:t}function Ox(e,t){return Mx(e,t.toLowerCase())}const YI=Ml({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:cl,acceptCharset:xt,accessKey:xt,action:null,allow:null,allowFullScreen:Ke,allowPaymentRequest:Ke,allowUserMedia:Ke,alt:null,as:null,async:Ke,autoCapitalize:null,autoComplete:xt,autoFocus:Ke,autoPlay:Ke,blocking:xt,capture:null,charSet:null,checked:Ke,cite:null,className:xt,cols:pe,colSpan:null,content:null,contentEditable:Kt,controls:Ke,controlsList:xt,coords:pe|cl,crossOrigin:null,data:null,dateTime:null,decoding:null,default:Ke,defer:Ke,dir:null,dirName:null,disabled:Ke,download:ug,draggable:Kt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:Ke,formTarget:null,headers:xt,height:pe,hidden:ug,high:pe,href:null,hrefLang:null,htmlFor:xt,httpEquiv:xt,id:null,imageSizes:null,imageSrcSet:null,inert:Ke,inputMode:null,integrity:null,is:null,isMap:Ke,itemId:null,itemProp:xt,itemRef:xt,itemScope:Ke,itemType:xt,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:Ke,low:pe,manifest:null,max:null,maxLength:pe,media:null,method:null,min:null,minLength:pe,multiple:Ke,muted:Ke,name:null,nonce:null,noModule:Ke,noValidate:Ke,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:Ke,optimum:pe,pattern:null,ping:xt,placeholder:null,playsInline:Ke,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:Ke,referrerPolicy:null,rel:xt,required:Ke,reversed:Ke,rows:pe,rowSpan:pe,sandbox:xt,scope:null,scoped:Ke,seamless:Ke,selected:Ke,shadowRootClonable:Ke,shadowRootDelegatesFocus:Ke,shadowRootMode:null,shape:null,size:pe,sizes:null,slot:null,span:pe,spellCheck:Kt,src:null,srcDoc:null,srcLang:null,srcSet:null,start:pe,step:null,style:null,tabIndex:pe,target:null,title:null,translate:null,type:null,typeMustMatch:Ke,useMap:null,value:Kt,width:pe,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:xt,axis:null,background:null,bgColor:null,border:pe,borderColor:null,bottomMargin:pe,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:Ke,declare:Ke,event:null,face:null,frame:null,frameBorder:null,hSpace:pe,leftMargin:pe,link:null,longDesc:null,lowSrc:null,marginHeight:pe,marginWidth:pe,noResize:Ke,noHref:Ke,noShade:Ke,noWrap:Ke,object:null,profile:null,prompt:null,rev:null,rightMargin:pe,rules:null,scheme:null,scrolling:Kt,standby:null,summary:null,text:null,topMargin:pe,valueType:null,version:null,vAlign:null,vLink:null,vSpace:pe,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:Ke,disableRemotePlayback:Ke,prefix:null,property:null,results:pe,security:null,unselectable:null},space:"html",transform:Ox}),JI=Ml({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:cr,accentHeight:pe,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:pe,amplitude:pe,arabicForm:null,ascent:pe,attributeName:null,attributeType:null,azimuth:pe,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:pe,by:null,calcMode:null,capHeight:pe,className:xt,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:pe,diffuseConstant:pe,direction:null,display:null,dur:null,divisor:pe,dominantBaseline:null,download:Ke,dx:null,dy:null,edgeMode:null,editable:null,elevation:pe,enableBackground:null,end:null,event:null,exponent:pe,externalResourcesRequired:null,fill:null,fillOpacity:pe,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:cl,g2:cl,glyphName:cl,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:pe,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:pe,horizOriginX:pe,horizOriginY:pe,id:null,ideographic:pe,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:pe,k:pe,k1:pe,k2:pe,k3:pe,k4:pe,kernelMatrix:cr,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:pe,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:pe,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:pe,overlineThickness:pe,paintOrder:null,panose1:null,path:null,pathLength:pe,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:xt,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:pe,pointsAtY:pe,pointsAtZ:pe,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:cr,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:cr,rev:cr,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:cr,requiredFeatures:cr,requiredFonts:cr,requiredFormats:cr,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:pe,specularExponent:pe,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:pe,strikethroughThickness:pe,string:null,stroke:null,strokeDashArray:cr,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:pe,strokeOpacity:pe,strokeWidth:null,style:null,surfaceScale:pe,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:cr,tabIndex:pe,tableValues:null,target:null,targetX:pe,targetY:pe,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:cr,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:pe,underlineThickness:pe,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:pe,values:null,vAlphabetic:pe,vMathematical:pe,vectorEffect:null,vHanging:pe,vIdeographic:pe,version:null,vertAdvY:pe,vertOriginX:pe,vertOriginY:pe,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:pe,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:Mx}),$x=Ml({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()}}),Bx=Ml({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:Ox}),jx=Ml({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),ZI=/[A-Z]/g,ly=/-[a-z]/g,e4=/^data[-\w.:]+$/i;function t4(e,t){const n=cg(t);let r=t,i=Zn;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&e4.test(t)){if(t.charAt(4)==="-"){const s=t.slice(5).replace(ly,r4);r="data"+s.charAt(0).toUpperCase()+s.slice(1)}else{const s=t.slice(4);if(!ly.test(s)){let l=s.replace(ZI,n4);l.charAt(0)!=="-"&&(l="-"+l),t="data"+l}}i=x0}return new i(r,t)}function n4(e){return"-"+e.toLowerCase()}function r4(e){return e.charAt(1).toUpperCase()}const i4=Nx([Fx,YI,$x,Bx,jx],"html"),Vx=Nx([Fx,JI,$x,Bx,jx],"svg"),cy={}.hasOwnProperty;function o4(e,t){const n=t||{};function r(i,...s){let l=r.invalid;const c=r.handlers;if(i&&cy.call(i,e)){const d=String(i[e]);l=cy.call(c,d)?c[d]:r.unknown}if(l)return l.call(this,i,...s)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}const s4=/["&'<>`]/g,a4=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,l4=/[\x01-\t\v\f\x0E-\x1F\x7F\x81\x8D\x8F\x90\x9D\xA0-\uFFFF]/g,c4=/[|\\{}()[\]^$+*?.]/g,uy=new WeakMap;function u4(e,t){if(e=e.replace(t.subset?d4(t.subset):s4,r),t.subset||t.escapeOnly)return e;return e.replace(a4,n).replace(l4,r);function n(i,s,l){return t.format((i.charCodeAt(0)-55296)*1024+i.charCodeAt(1)-56320+65536,l.charCodeAt(s+2),t)}function r(i,s,l){return t.format(i.charCodeAt(0),l.charCodeAt(s+1),t)}}function d4(e){let t=uy.get(e);return t||(t=f4(e),uy.set(e,t)),t}function f4(e){const t=[];let n=-1;for(;++n<e.length;)t.push(e[n].replace(c4,"\\$&"));return new RegExp("(?:"+t.join("|")+")","g")}const h4=/[\dA-Fa-f]/;function p4(e,t,n){const r="&#x"+e.toString(16).toUpperCase();return n&&t&&!h4.test(String.fromCharCode(t))?r:r+";"}const m4=/\d/;function g4(e,t,n){const r="&#"+String(e);return n&&t&&!m4.test(String.fromCharCode(t))?r:r+";"}const v4=["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"],pm={nbsp:" ",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:"€"},y4=["cent","copy","divide","gt","lt","not","para","times"],Ux={}.hasOwnProperty,fg={};let zd;for(zd in pm)Ux.call(pm,zd)&&(fg[pm[zd]]=zd);const w4=/[^\dA-Za-z]/;function b4(e,t,n,r){const i=String.fromCharCode(e);if(Ux.call(fg,i)){const s=fg[i],l="&"+s;return n&&v4.includes(s)&&!y4.includes(s)&&(!r||t&&t!==61&&w4.test(String.fromCharCode(t)))?l:l+";"}return""}function x4(e,t,n){let r=p4(e,t,n.omitOptionalSemicolons),i;if((n.useNamedReferences||n.useShortestReferences)&&(i=b4(e,t,n.omitOptionalSemicolons,n.attribute)),(n.useShortestReferences||!i)&&n.useShortestReferences){const s=g4(e,t,n.omitOptionalSemicolons);s.length<r.length&&(r=s)}return i&&(!n.useShortestReferences||i.length<r.length)?i:r}function ul(e,t){return u4(e,Object.assign({format:x4},t))}const _4=/^>|^->|<!--|-->|--!>|<!-$/g,k4=[">"],S4=["<",">"];function C4(e,t,n,r){return r.settings.bogusComments?"<?"+ul(e.value,Object.assign({},r.settings.characterReferences,{subset:k4}))+">":"<!--"+e.value.replace(_4,i)+"-->";function i(s){return ul(s,Object.assign({},r.settings.characterReferences,{subset:S4}))}}function E4(e,t,n,r){return"<!"+(r.settings.upperDoctype?"DOCTYPE":"doctype")+(r.settings.tightDoctype?"":" ")+"html>"}function dy(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let r=0,i=n.indexOf(t);for(;i!==-1;)r++,i=n.indexOf(t,i+t.length);return r}function I4(e,t){const n=t||{};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}function P4(e){return e.join(" ").trim()}const L4=/[ \t\n\f\r]/g;function _0(e){return typeof e=="object"?e.type==="text"?fy(e.value):!1:fy(e)}function fy(e){return e.replace(L4,"")===""}const on=Hx(1),zx=Hx(-1),D4=[];function Hx(e){return t;function t(n,r,i){const s=n?n.children:D4;let l=(r||0)+e,c=s[l];if(!i)for(;c&&_0(c);)l+=e,c=s[l];return c}}const A4={}.hasOwnProperty;function Wx(e){return t;function t(n,r,i){return A4.call(e,n.tagName)&&e[n.tagName](n,r,i)}}const k0=Wx({body:R4,caption:mm,colgroup:mm,dd:O4,dt:M4,head:mm,html:T4,li:F4,optgroup:$4,option:B4,p:N4,rp:hy,rt:hy,tbody:V4,td:py,tfoot:U4,th:py,thead:j4,tr:z4});function mm(e,t,n){const r=on(n,t,!0);return!r||r.type!=="comment"&&!(r.type==="text"&&_0(r.value.charAt(0)))}function T4(e,t,n){const r=on(n,t);return!r||r.type!=="comment"}function R4(e,t,n){const r=on(n,t);return!r||r.type!=="comment"}function N4(e,t,n){const r=on(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 F4(e,t,n){const r=on(n,t);return!r||r.type==="element"&&r.tagName==="li"}function M4(e,t,n){const r=on(n,t);return!!(r&&r.type==="element"&&(r.tagName==="dt"||r.tagName==="dd"))}function O4(e,t,n){const r=on(n,t);return!r||r.type==="element"&&(r.tagName==="dt"||r.tagName==="dd")}function hy(e,t,n){const r=on(n,t);return!r||r.type==="element"&&(r.tagName==="rp"||r.tagName==="rt")}function $4(e,t,n){const r=on(n,t);return!r||r.type==="element"&&r.tagName==="optgroup"}function B4(e,t,n){const r=on(n,t);return!r||r.type==="element"&&(r.tagName==="option"||r.tagName==="optgroup")}function j4(e,t,n){const r=on(n,t);return!!(r&&r.type==="element"&&(r.tagName==="tbody"||r.tagName==="tfoot"))}function V4(e,t,n){const r=on(n,t);return!r||r.type==="element"&&(r.tagName==="tbody"||r.tagName==="tfoot")}function U4(e,t,n){return!on(n,t)}function z4(e,t,n){const r=on(n,t);return!r||r.type==="element"&&r.tagName==="tr"}function py(e,t,n){const r=on(n,t);return!r||r.type==="element"&&(r.tagName==="td"||r.tagName==="th")}const H4=Wx({body:q4,colgroup:K4,head:G4,html:W4,tbody:X4});function W4(e){const t=on(e,-1);return!t||t.type!=="comment"}function G4(e){const t=new Set;for(const r of e.children)if(r.type==="element"&&(r.tagName==="base"||r.tagName==="title")){if(t.has(r.tagName))return!1;t.add(r.tagName)}const n=e.children[0];return!n||n.type==="element"}function q4(e){const t=on(e,-1,!0);return!t||t.type!=="comment"&&!(t.type==="text"&&_0(t.value.charAt(0)))&&!(t.type==="element"&&(t.tagName==="meta"||t.tagName==="link"||t.tagName==="script"||t.tagName==="style"||t.tagName==="template"))}function K4(e,t,n){const r=zx(n,t),i=on(e,-1,!0);return n&&r&&r.type==="element"&&r.tagName==="colgroup"&&k0(r,n.children.indexOf(r),n)?!1:!!(i&&i.type==="element"&&i.tagName==="col")}function X4(e,t,n){const r=zx(n,t),i=on(e,-1);return n&&r&&r.type==="element"&&(r.tagName==="thead"||r.tagName==="tbody")&&k0(r,n.children.indexOf(r),n)?!1:!!(i&&i.type==="element"&&i.tagName==="tr")}const Hd={name:[[`
203
+ \f\r &/=>`.split(""),`
204
+ \f\r "&'/=>\``.split("")],[`\0
205
+ \f\r "&'/<=>`.split(""),`\0
206
+ \f\r "&'/<=>\``.split("")]],unquoted:[[`
207
+ \f\r &>`.split(""),`\0
208
+ \f\r "&'<=>\``.split("")],[`\0
209
+ \f\r "&'<=>\``.split(""),`\0
210
+ \f\r "&'<=>\``.split("")]],single:[["&'".split(""),"\"&'`".split("")],["\0&'".split(""),"\0\"&'`".split("")]],double:[['"&'.split(""),"\"&'`".split("")],['\0"&'.split(""),"\0\"&'`".split("")]]};function Q4(e,t,n,r){const i=r.schema,s=i.space==="svg"?!1:r.settings.omitOptionalTags;let l=i.space==="svg"?r.settings.closeEmptyElements:r.settings.voids.includes(e.tagName.toLowerCase());const c=[];let d;i.space==="html"&&e.tagName==="svg"&&(r.schema=Vx);const f=Y4(r,e.properties),m=r.all(i.space==="html"&&e.tagName==="template"?e.content:e);return r.schema=i,m&&(l=!1),(f||!s||!H4(e,t,n))&&(c.push("<",e.tagName,f?" "+f:""),l&&(i.space==="svg"||r.settings.closeSelfClosing)&&(d=f.charAt(f.length-1),(!r.settings.tightSelfClosing||d==="/"||d&&d!=='"'&&d!=="'")&&c.push(" "),c.push("/")),c.push(">")),c.push(m),!l&&(!s||!k0(e,t,n))&&c.push("</"+e.tagName+">"),c.join("")}function Y4(e,t){const n=[];let r=-1,i;if(t){for(i in t)if(t[i]!==null&&t[i]!==void 0){const s=J4(e,i,t[i]);s&&n.push(s)}}for(;++r<n.length;){const s=e.settings.tightAttributes?n[r].charAt(n[r].length-1):void 0;r!==n.length-1&&s!=='"'&&s!=="'"&&(n[r]+=" ")}return n.join("")}function J4(e,t,n){const r=t4(e.schema,t),i=e.settings.allowParseErrors&&e.schema.space==="html"?0:1,s=e.settings.allowDangerousCharacters?0:1;let l=e.quote,c;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"";const d=ul(r.attribute,Object.assign({},e.settings.characterReferences,{subset:Hd.name[i][s]}));return n===!0||(n=Array.isArray(n)?(r.commaSeparated?I4:P4)(n,{padLeft:!e.settings.tightCommaSeparatedLists}):String(n),e.settings.collapseEmptyAttributes&&!n)?d:(e.settings.preferUnquoted&&(c=ul(n,Object.assign({},e.settings.characterReferences,{attribute:!0,subset:Hd.unquoted[i][s]}))),c!==n&&(e.settings.quoteSmart&&dy(n,l)>dy(n,e.alternative)&&(l=e.alternative),c=l+ul(n,Object.assign({},e.settings.characterReferences,{subset:(l==="'"?Hd.single:Hd.double)[i][s],attribute:!0}))+l),d+(c&&"="+c))}const Z4=["<","&"];function Gx(e,t,n,r){return n&&n.type==="element"&&(n.tagName==="script"||n.tagName==="style")?e.value:ul(e.value,Object.assign({},r.settings.characterReferences,{subset:Z4}))}function eP(e,t,n,r){return r.settings.allowDangerousHtml?e.value:Gx(e,t,n,r)}function tP(e,t,n,r){return r.all(e)}const nP=o4("type",{invalid:rP,unknown:iP,handlers:{comment:C4,doctype:E4,element:Q4,raw:eP,root:tP,text:Gx}});function rP(e){throw new Error("Expected node, not `"+e+"`")}function iP(e){const t=e;throw new Error("Cannot compile unknown node `"+t.type+"`")}const oP={},sP={},aP=[];function dl(e,t){const n=t||oP,r=n.quote||'"',i=r==='"'?"'":'"';if(r!=='"'&&r!=="'")throw new Error("Invalid quote `"+r+"`, expected `'` or `\"`");return{one:lP,all:cP,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||XI,characterReferences:n.characterReferences||sP,closeSelfClosing:n.closeSelfClosing||!1,closeEmptyElements:n.closeEmptyElements||!1},schema:n.space==="svg"?Vx:i4,quote:r,alternative:i}.one(Array.isArray(e)?{type:"root",children:e}:e,void 0,void 0)}function lP(e,t,n){return nP(e,t,n,this)}function cP(e){const t=[],n=e&&e.children||aP;let r=-1;for(;++r<n.length;)t[r]=this.one(n[r],r,e);return t.join("")}function zf(e,t){const n=typeof e=="string"?{}:{...e.colorReplacements},r=typeof e=="string"?e:e.name;for(const[i,s]of Object.entries((t==null?void 0:t.colorReplacements)||{}))typeof s=="string"?n[i]=s:i===r&&Object.assign(n,s);return n}function fs(e,t){return e&&((t==null?void 0:t[e==null?void 0:e.toLowerCase()])||e)}function uP(e){return Array.isArray(e)?e:[e]}async function qx(e){return Promise.resolve(typeof e=="function"?e():e).then(t=>t.default||t)}function S0(e){return!e||["plaintext","txt","text","plain"].includes(e)}function Kx(e){return e==="ansi"||S0(e)}function C0(e){return e==="none"}function Xx(e){return C0(e)}function Qx(e,t){var r;if(!t)return e;e.properties||(e.properties={}),(r=e.properties).class||(r.class=[]),typeof e.properties.class=="string"&&(e.properties.class=e.properties.class.split(/\s+/g)),Array.isArray(e.properties.class)||(e.properties.class=[]);const n=Array.isArray(t)?t:t.split(/\s+/g);for(const i of n)i&&!e.properties.class.includes(i)&&e.properties.class.push(i);return e}function ah(e,t=!1){var s;if(e.length===0)return[["",0]];const n=e.split(/(\r?\n)/g);let r=0;const i=[];for(let l=0;l<n.length;l+=2){const c=t?n[l]+(n[l+1]||""):n[l];i.push([c,r]),r+=n[l].length,r+=((s=n[l+1])==null?void 0:s.length)||0}return i}function dP(e){const t=ah(e,!0).map(([i])=>i);function n(i){if(i===e.length)return{line:t.length-1,character:t[t.length-1].length};let s=i,l=0;for(const c of t){if(s<c.length)break;s-=c.length,l++}return{line:l,character:s}}function r(i,s){let l=0;for(let c=0;c<i;c++)l+=t[c].length;return l+=s,l}return{lines:t,indexToPos:n,posToIndex:r}}const E0="light-dark()",fP=["color","background-color"];function hP(e,t){let n=0;const r=[];for(const 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 pP(e,t){const n=Array.from(t instanceof Set?t:new Set(t)).sort((r,i)=>r-i);return n.length?e.map(r=>r.flatMap(i=>{const s=n.filter(l=>i.offset<l&&l<i.offset+i.content.length).map(l=>l-i.offset).sort((l,c)=>l-c);return s.length?hP(i,s):i})):e}function mP(e,t,n,r,i="css-vars"){const s={content:e.content,explanation:e.explanation,offset:e.offset},l=t.map(m=>Hf(e.variants[m])),c=new Set(l.flatMap(m=>Object.keys(m))),d={},f=(m,h)=>{const g=h==="color"?"":h==="background-color"?"-bg":`-${h}`;return n+t[m]+(h==="color"?"":g)};return l.forEach((m,h)=>{for(const g of c){const y=m[g]||"inherit";if(h===0&&r&&fP.includes(g))if(r===E0&&l.length>1){const w=t.findIndex(E=>E==="light"),_=t.findIndex(E=>E==="dark");if(w===-1||_===-1)throw new Xt('When using `defaultColor: "light-dark()"`, you must provide both `light` and `dark` themes');const C=l[w][g]||"inherit",I=l[_][g]||"inherit";d[g]=`light-dark(${C}, ${I})`,i==="css-vars"&&(d[f(h,g)]=y)}else d[g]=y;else i==="css-vars"&&(d[f(h,g)]=y)}}),s.htmlStyle=d,s}function Hf(e){const t={};if(e.color&&(t.color=e.color),e.bgColor&&(t["background-color"]=e.bgColor),e.fontStyle){e.fontStyle&Tn.Italic&&(t["font-style"]="italic"),e.fontStyle&Tn.Bold&&(t["font-weight"]="bold");const n=[];e.fontStyle&Tn.Underline&&n.push("underline"),e.fontStyle&Tn.Strikethrough&&n.push("line-through"),n.length&&(t["text-decoration"]=n.join(" "))}return t}function hg(e){return typeof e=="string"?e:Object.entries(e).map(([t,n])=>`${t}:${n}`).join(";")}const Yx=new WeakMap;function lh(e,t){Yx.set(e,t)}function eu(e){return Yx.get(e)}class Ol{constructor(...t){F(this,"_stacks",{});F(this,"lang");if(t.length===2){const[n,r]=t;this.lang=r,this._stacks=n}else{const[n,r,i]=t;this.lang=r,this._stacks={[i]:n}}}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 Ol(Object.fromEntries(uP(n).map(r=>[r,lg])),t)}getInternalStack(t=this.theme){return this._stacks[t]}getScopes(t=this.theme){return gP(this._stacks[t])}toJSON(){return{lang:this.lang,theme:this.theme,themes:this.themes,scopes:this.getScopes()}}}function gP(e){const t=[],n=new Set;function r(i){var l;if(n.has(i))return;n.add(i);const s=(l=i==null?void 0:i.nameScopesList)==null?void 0:l.scopeName;s&&t.push(s),i.parent&&r(i.parent)}return r(e),t}function vP(e,t){if(!(e instanceof Ol))throw new Xt("Invalid grammar state");return e.getInternalStack(t)}function yP(){const e=new WeakMap;function t(n){if(!e.has(n.meta)){let r=function(l){if(typeof l=="number"){if(l<0||l>n.source.length)throw new Xt(`Invalid decoration offset: ${l}. Code length: ${n.source.length}`);return{...i.indexToPos(l),offset:l}}else{const c=i.lines[l.line];if(c===void 0)throw new Xt(`Invalid decoration position ${JSON.stringify(l)}. Lines length: ${i.lines.length}`);let d=l.character;if(d<0&&(d=c.length+d),d<0||d>c.length)throw new Xt(`Invalid decoration position ${JSON.stringify(l)}. Line ${l.line} length: ${c.length}`);return{...l,character:d,offset:i.posToIndex(l.line,d)}}};const i=dP(n.source),s=(n.options.decorations||[]).map(l=>({...l,start:r(l.start),end:r(l.end)}));wP(s),e.set(n.meta,{decorations:s,converter:i,source:n.source})}return e.get(n.meta)}return{name:"shiki:decorations",tokens(n){var l;if(!((l=this.options.decorations)!=null&&l.length))return;const i=t(this).decorations.flatMap(c=>[c.start.offset,c.end.offset]);return pP(n,i)},code(n){var m;if(!((m=this.options.decorations)!=null&&m.length))return;const r=t(this),i=Array.from(n.children).filter(h=>h.type==="element"&&h.tagName==="span");if(i.length!==r.converter.lines.length)throw new Xt(`Number of lines in code element (${i.length}) does not match the number of lines in the source (${r.converter.lines.length}). Failed to apply decorations.`);function s(h,g,y,w){const _=i[h];let C="",I=-1,E=-1;if(g===0&&(I=0),y===0&&(E=0),y===Number.POSITIVE_INFINITY&&(E=_.children.length),I===-1||E===-1)for(let L=0;L<_.children.length;L++)C+=Jx(_.children[L]),I===-1&&C.length===g&&(I=L+1),E===-1&&C.length===y&&(E=L+1);if(I===-1)throw new Xt(`Failed to find start index for decoration ${JSON.stringify(w.start)}`);if(E===-1)throw new Xt(`Failed to find end index for decoration ${JSON.stringify(w.end)}`);const S=_.children.slice(I,E);if(!w.alwaysWrap&&S.length===_.children.length)c(_,w,"line");else if(!w.alwaysWrap&&S.length===1&&S[0].type==="element")c(S[0],w,"token");else{const L={type:"element",tagName:"span",properties:{},children:S};c(L,w,"wrapper"),_.children.splice(I,S.length,L)}}function l(h,g){i[h]=c(i[h],g,"line")}function c(h,g,y){var C;const w=g.properties||{},_=g.transform||(I=>I);return h.tagName=g.tagName||"span",h.properties={...h.properties,...w,class:h.properties.class},(C=g.properties)!=null&&C.class&&Qx(h,g.properties.class),h=_(h,y)||h,h}const d=[],f=r.decorations.sort((h,g)=>g.start.offset-h.start.offset||h.end.offset-g.end.offset);for(const h of f){const{start:g,end:y}=h;if(g.line===y.line)s(g.line,g.character,y.character,h);else if(g.line<y.line){s(g.line,g.character,Number.POSITIVE_INFINITY,h);for(let w=g.line+1;w<y.line;w++)d.unshift(()=>l(w,h));s(y.line,0,y.character,h)}}d.forEach(h=>h())}}}function wP(e){for(let t=0;t<e.length;t++){const n=e[t];if(n.start.offset>n.end.offset)throw new Xt(`Invalid decoration range: ${JSON.stringify(n.start)} - ${JSON.stringify(n.end)}`);for(let r=t+1;r<e.length;r++){const i=e[r],s=n.start.offset<=i.start.offset&&i.start.offset<n.end.offset,l=n.start.offset<i.end.offset&&i.end.offset<=n.end.offset,c=i.start.offset<=n.start.offset&&n.start.offset<i.end.offset,d=i.start.offset<n.end.offset&&n.end.offset<=i.end.offset;if(s||l||c||d){if(s&&l||c&&d||c&&n.start.offset===n.end.offset||l&&i.start.offset===i.end.offset)continue;throw new Xt(`Decorations ${JSON.stringify(n.start)} and ${JSON.stringify(i.start)} intersect.`)}}}}function Jx(e){return e.type==="text"?e.value:e.type==="element"?e.children.map(Jx).join(""):""}const bP=[yP()];function Wf(e){const t=xP(e.transformers||[]);return[...t.pre,...t.normal,...t.post,...bP]}function xP(e){const t=[],n=[],r=[];for(const 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 Xs=["black","red","green","yellow","blue","magenta","cyan","white","brightBlack","brightRed","brightGreen","brightYellow","brightBlue","brightMagenta","brightCyan","brightWhite"],gm={1:"bold",2:"dim",3:"italic",4:"underline",7:"reverse",8:"hidden",9:"strikethrough"};function _P(e,t){const n=e.indexOf("\x1B",t);if(n!==-1&&e[n+1]==="["){const r=e.indexOf("m",n);if(r!==-1)return{sequence:e.substring(n+2,r).split(";"),startPosition:n,position:r+1}}return{position:e.length}}function my(e){const t=e.shift();if(t==="2"){const n=e.splice(0,3).map(r=>Number.parseInt(r));return n.length!==3||n.some(r=>Number.isNaN(r))?void 0:{type:"rgb",rgb:n}}else if(t==="5"){const n=e.shift();if(n)return{type:"table",index:Number(n)}}}function kP(e){const t=[];for(;e.length>0;){const n=e.shift();if(!n)continue;const r=Number.parseInt(n);if(!Number.isNaN(r))if(r===0)t.push({type:"resetAll"});else if(r<=9)gm[r]&&t.push({type:"setDecoration",value:gm[r]});else if(r<=29){const i=gm[r-20];i&&(t.push({type:"resetDecoration",value:i}),i==="dim"&&t.push({type:"resetDecoration",value:"bold"}))}else if(r<=37)t.push({type:"setForegroundColor",value:{type:"named",name:Xs[r-30]}});else if(r===38){const i=my(e);i&&t.push({type:"setForegroundColor",value:i})}else if(r===39)t.push({type:"resetForegroundColor"});else if(r<=47)t.push({type:"setBackgroundColor",value:{type:"named",name:Xs[r-40]}});else if(r===48){const i=my(e);i&&t.push({type:"setBackgroundColor",value:i})}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:Xs[r-90+8]}}):r>=100&&r<=107&&t.push({type:"setBackgroundColor",value:{type:"named",name:Xs[r-100+8]}})}return t}function SP(){let e=null,t=null,n=new Set;return{parse(r){const i=[];let s=0;do{const l=_P(r,s),c=l.sequence?r.substring(s,l.startPosition):r.substring(s);if(c.length>0&&i.push({value:c,foreground:e,background:t,decorations:new Set(n)}),l.sequence){const d=kP(l.sequence);for(const f of d)f.type==="resetAll"?(e=null,t=null,n.clear()):f.type==="resetForegroundColor"?e=null:f.type==="resetBackgroundColor"?t=null:f.type==="resetDecoration"&&n.delete(f.value);for(const f of d)f.type==="setForegroundColor"?e=f.value:f.type==="setBackgroundColor"?t=f.value:f.type==="setDecoration"&&n.add(f.value)}s=l.position}while(s<r.length);return i}}}var CP={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 EP(e=CP){function t(c){return e[c]}function n(c){return`#${c.map(d=>Math.max(0,Math.min(d,255)).toString(16).padStart(2,"0")).join("")}`}let r;function i(){if(r)return r;r=[];for(let f=0;f<Xs.length;f++)r.push(t(Xs[f]));let c=[0,95,135,175,215,255];for(let f=0;f<6;f++)for(let m=0;m<6;m++)for(let h=0;h<6;h++)r.push(n([c[f],c[m],c[h]]));let d=8;for(let f=0;f<24;f++,d+=10)r.push(n([d,d,d]));return r}function s(c){return i()[c]}function l(c){switch(c.type){case"named":return t(c.name);case"rgb":return n(c.rgb);case"table":return s(c.index)}}return{value:l}}const IP={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 PP(e,t,n){const r=zf(e,n),i=ah(t),s=Object.fromEntries(Xs.map(d=>{var h;const f=`terminal.ansi${d[0].toUpperCase()}${d.substring(1)}`,m=(h=e.colors)==null?void 0:h[f];return[d,m||IP[d]]})),l=EP(s),c=SP();return i.map(d=>c.parse(d[0]).map(f=>{let m,h;f.decorations.has("reverse")?(m=f.background?l.value(f.background):e.bg,h=f.foreground?l.value(f.foreground):e.fg):(m=f.foreground?l.value(f.foreground):e.fg,h=f.background?l.value(f.background):void 0),m=fs(m,r),h=fs(h,r),f.decorations.has("dim")&&(m=LP(m));let g=Tn.None;return f.decorations.has("bold")&&(g|=Tn.Bold),f.decorations.has("italic")&&(g|=Tn.Italic),f.decorations.has("underline")&&(g|=Tn.Underline),f.decorations.has("strikethrough")&&(g|=Tn.Strikethrough),{content:f.value,offset:d[1],color:m,bgColor:h,fontStyle:g}}))}function LP(e){const t=e.match(/#([0-9a-f]{3,8})/i);if(t){const r=t[1];if(r.length===8){const i=Math.round(Number.parseInt(r.slice(6,8),16)/2).toString(16).padStart(2,"0");return`#${r.slice(0,6)}${i}`}else{if(r.length===6)return`#${r}80`;if(r.length===4){const i=r[0],s=r[1],l=r[2],c=r[3],d=Math.round(Number.parseInt(`${c}${c}`,16)/2).toString(16).padStart(2,"0");return`#${i}${i}${s}${s}${l}${l}${d}`}else if(r.length===3){const i=r[0],s=r[1],l=r[2];return`#${i}${i}${s}${s}${l}${l}80`}}}const n=e.match(/var\((--[\w-]+-ansi-[\w-]+)\)/);return n?`var(${n[1]}-dim)`:e}function I0(e,t,n={}){const{theme:r=e.getLoadedThemes()[0]}=n,i=e.resolveLangAlias(n.lang||"text");if(S0(i)||C0(r))return ah(t).map(d=>[{content:d[0],offset:d[1]}]);const{theme:s,colorMap:l}=e.setTheme(r);if(i==="ansi")return PP(s,t,n);const c=e.getLanguage(n.lang||"text");if(n.grammarState){if(n.grammarState.lang!==c.name)throw new Xt(`Grammar state language "${n.grammarState.lang}" does not match highlight language "${c.name}"`);if(!n.grammarState.themes.includes(s.name))throw new Xt(`Grammar state themes "${n.grammarState.themes}" do not contain highlight theme "${s.name}"`)}return AP(t,c,s,l,n)}function DP(...e){if(e.length===2)return eu(e[1]);const[t,n,r={}]=e,{lang:i="text",theme:s=t.getLoadedThemes()[0]}=r;if(S0(i)||C0(s))throw new Xt("Plain language does not have grammar state");if(i==="ansi")throw new Xt("ANSI language does not have grammar state");const{theme:l,colorMap:c}=t.setTheme(s),d=t.getLanguage(i);return new Ol(P0(n,d,l,c,r).stateStack,d.name,l.name)}function AP(e,t,n,r,i){const s=P0(e,t,n,r,i),l=new Ol(s.stateStack,t.name,n.name);return lh(s.tokens,l),s.tokens}function P0(e,t,n,r,i){const s=zf(n,i),{tokenizeMaxLineLength:l=0,tokenizeTimeLimit:c=500}=i,d=ah(e);let f=i.grammarState?vP(i.grammarState,n.name)??lg:i.grammarContextCode!=null?P0(i.grammarContextCode,t,n,r,{...i,grammarState:void 0,grammarContextCode:void 0}).stateStack:lg,m=[];const h=[];for(let g=0,y=d.length;g<y;g++){const[w,_]=d[g];if(w===""){m=[],h.push([]);continue}if(l>0&&w.length>=l){m=[],h.push([{content:w,offset:_,color:"",fontStyle:0}]);continue}let C,I,E;i.includeExplanation&&(C=t.tokenizeLine(w,f,c),I=C.tokens,E=0);const S=t.tokenizeLine2(w,f,c),L=S.tokens.length/2;for(let A=0;A<L;A++){const R=S.tokens[2*A],U=A+1<L?S.tokens[2*A+2]:w.length;if(R===U)continue;const X=S.tokens[2*A+1],H=fs(r[Ll.getForeground(X)],s),re=Ll.getFontStyle(X),de={content:w.substring(R,U),offset:_+R,color:H,fontStyle:re};if(i.includeExplanation){const te=[];if(i.includeExplanation!=="scopeName")for(const ee of n.settings){let K;switch(typeof ee.scope){case"string":K=ee.scope.split(/,/).map(oe=>oe.trim());break;case"object":K=ee.scope;break;default:continue}te.push({settings:ee,selectors:K.map(oe=>oe.split(/ /))})}de.explanation=[];let Q=0;for(;R+Q<U;){const ee=I[E],K=w.substring(ee.startIndex,ee.endIndex);Q+=K.length,de.explanation.push({content:K,scopes:i.includeExplanation==="scopeName"?TP(ee.scopes):RP(te,ee.scopes)}),E+=1}}m.push(de)}h.push(m),m=[],f=S.ruleStack}return{tokens:h,stateStack:f}}function TP(e){return e.map(t=>({scopeName:t}))}function RP(e,t){const n=[];for(let r=0,i=t.length;r<i;r++){const s=t[r];n[r]={scopeName:s,themeMatches:FP(e,s,t.slice(0,r))}}return n}function gy(e,t){return e===t||t.substring(0,e.length)===e&&t[e.length]==="."}function NP(e,t,n){if(!gy(e[e.length-1],t))return!1;let r=e.length-2,i=n.length-1;for(;r>=0&&i>=0;)gy(e[r],n[i])&&(r-=1),i-=1;return r===-1}function FP(e,t,n){const r=[];for(const{selectors:i,settings:s}of e)for(const l of i)if(NP(l,t,n)){r.push(s);break}return r}function Zx(e,t,n){const r=Object.entries(n.themes).filter(d=>d[1]).map(d=>({color:d[0],theme:d[1]})),i=r.map(d=>{const f=I0(e,t,{...n,theme:d.theme}),m=eu(f),h=typeof d.theme=="string"?d.theme:d.theme.name;return{tokens:f,state:m,theme:h}}),s=MP(...i.map(d=>d.tokens)),l=s[0].map((d,f)=>d.map((m,h)=>{const g={content:m.content,variants:{},offset:m.offset};return"includeExplanation"in n&&n.includeExplanation&&(g.explanation=m.explanation),s.forEach((y,w)=>{const{content:_,explanation:C,offset:I,...E}=y[f][h];g.variants[r[w].color]=E}),g})),c=i[0].state?new Ol(Object.fromEntries(i.map(d=>{var f;return[d.theme,(f=d.state)==null?void 0:f.getInternalStack(d.theme)]})),i[0].state.lang):void 0;return c&&lh(l,c),l}function MP(...e){const t=e.map(()=>[]),n=e.length;for(let r=0;r<e[0].length;r++){const i=e.map(d=>d[r]),s=t.map(()=>[]);t.forEach((d,f)=>d.push(s[f]));const l=i.map(()=>0),c=i.map(d=>d[0]);for(;c.every(d=>d);){const d=Math.min(...c.map(f=>f.content.length));for(let f=0;f<n;f++){const m=c[f];m.content.length===d?(s[f].push(m),l[f]+=1,c[f]=i[f][l[f]]):(s[f].push({...m,content:m.content.slice(0,d)}),c[f]={...m,content:m.content.slice(d),offset:m.offset+d})}}}return t}function Gf(e,t,n){let r,i,s,l,c,d;if("themes"in n){const{defaultColor:f="light",cssVariablePrefix:m="--shiki-",colorsRendering:h="css-vars"}=n,g=Object.entries(n.themes).filter(I=>I[1]).map(I=>({color:I[0],theme:I[1]})).sort((I,E)=>I.color===f?-1:E.color===f?1:0);if(g.length===0)throw new Xt("`themes` option must not be empty");const y=Zx(e,t,n);if(d=eu(y),f&&E0!==f&&!g.find(I=>I.color===f))throw new Xt(`\`themes\` option must contain the defaultColor key \`${f}\``);const w=g.map(I=>e.getTheme(I.theme)),_=g.map(I=>I.color);s=y.map(I=>I.map(E=>mP(E,_,m,f,h))),d&&lh(s,d);const C=g.map(I=>zf(I.theme,n));i=vy(g,w,C,m,f,"fg",h),r=vy(g,w,C,m,f,"bg",h),l=`shiki-themes ${w.map(I=>I.name).join(" ")}`,c=f?void 0:[i,r].join(";")}else if("theme"in n){const f=zf(n.theme,n);s=I0(e,t,n);const m=e.getTheme(n.theme);r=fs(m.bg,f),i=fs(m.fg,f),l=m.name,d=eu(s)}else throw new Xt("Invalid options, either `theme` or `themes` must be provided");return{tokens:s,fg:i,bg:r,themeName:l,rootStyle:c,grammarState:d}}function vy(e,t,n,r,i,s,l){return e.map((c,d)=>{const f=fs(t[d][s],n[d])||"inherit",m=`${r+c.color}${s==="bg"?"-bg":""}:${f}`;if(d===0&&i){if(i===E0&&e.length>1){const h=e.findIndex(_=>_.color==="light"),g=e.findIndex(_=>_.color==="dark");if(h===-1||g===-1)throw new Xt('When using `defaultColor: "light-dark()"`, you must provide both `light` and `dark` themes');const y=fs(t[h][s],n[h])||"inherit",w=fs(t[g][s],n[g])||"inherit";return`light-dark(${y}, ${w});${m}`}return f}return l==="css-vars"?m:null}).filter(c=>!!c).join(";")}function qf(e,t,n,r={meta:{},options:n,codeToHast:(i,s)=>qf(e,i,s),codeToTokens:(i,s)=>Gf(e,i,s)}){var w,_;let i=t;for(const C of Wf(n))i=((w=C.preprocess)==null?void 0:w.call(r,i,n))||i;let{tokens:s,fg:l,bg:c,themeName:d,rootStyle:f,grammarState:m}=Gf(e,i,n);const{mergeWhitespaces:h=!0,mergeSameStyleTokens:g=!1}=n;h===!0?s=$P(s):h==="never"&&(s=BP(s)),g&&(s=jP(s));const y={...r,get source(){return i}};for(const C of Wf(n))s=((_=C.tokens)==null?void 0:_.call(y,s))||s;return OP(s,{...n,fg:l,bg:c,themeName:d,rootStyle:n.rootStyle===!1?!1:n.rootStyle??f},y,m)}function OP(e,t,n,r=eu(e)){var _,C,I,E;const i=Wf(t),s=[],l={type:"root",children:[]},{structure:c="classic",tabindex:d="0"}=t,f={class:`shiki ${t.themeName||""}`};t.rootStyle!==!1&&(t.rootStyle!=null?f.style=t.rootStyle:f.style=`background-color:${t.bg};color:${t.fg}`),d!==!1&&d!=null&&(f.tabindex=d.toString());for(const[S,L]of Object.entries(t.meta||{}))S.startsWith("_")||(f[S]=L);let m={type:"element",tagName:"pre",properties:f,children:[],data:t.data},h={type:"element",tagName:"code",properties:{},children:s};const g=[],y={...n,structure:c,addClassToHast:Qx,get source(){return n.source},get tokens(){return e},get options(){return t},get root(){return l},get pre(){return m},get code(){return h},get lines(){return g}};if(e.forEach((S,L)=>{var U,X;L&&(c==="inline"?l.children.push({type:"element",tagName:"br",properties:{},children:[]}):c==="classic"&&s.push({type:"text",value:`
211
+ `}));let A={type:"element",tagName:"span",properties:{class:"line"},children:[]},R=0;for(const H of S){let re={type:"element",tagName:"span",properties:{...H.htmlAttrs},children:[{type:"text",value:H.content}]};const de=hg(H.htmlStyle||Hf(H));de&&(re.properties.style=de);for(const te of i)re=((U=te==null?void 0:te.span)==null?void 0:U.call(y,re,L+1,R,A,H))||re;c==="inline"?l.children.push(re):c==="classic"&&A.children.push(re),R+=H.content.length}if(c==="classic"){for(const H of i)A=((X=H==null?void 0:H.line)==null?void 0:X.call(y,A,L+1))||A;g.push(A),s.push(A)}else c==="inline"&&g.push(A)}),c==="classic"){for(const S of i)h=((_=S==null?void 0:S.code)==null?void 0:_.call(y,h))||h;m.children.push(h);for(const S of i)m=((C=S==null?void 0:S.pre)==null?void 0:C.call(y,m))||m;l.children.push(m)}else if(c==="inline"){const S=[];let L={type:"element",tagName:"span",properties:{class:"line"},children:[]};for(const U of l.children)U.type==="element"&&U.tagName==="br"?(S.push(L),L={type:"element",tagName:"span",properties:{class:"line"},children:[]}):(U.type==="element"||U.type==="text")&&L.children.push(U);S.push(L);let R={type:"element",tagName:"code",properties:{},children:S};for(const U of i)R=((I=U==null?void 0:U.code)==null?void 0:I.call(y,R))||R;l.children=[];for(let U=0;U<R.children.length;U++){U>0&&l.children.push({type:"element",tagName:"br",properties:{},children:[]});const X=R.children[U];X.type==="element"&&l.children.push(...X.children)}}let w=l;for(const S of i)w=((E=S==null?void 0:S.root)==null?void 0:E.call(y,w))||w;return r&&lh(w,r),w}function $P(e){return e.map(t=>{const n=[];let r="",i;return t.forEach((s,l)=>{const d=!(s.fontStyle&&(s.fontStyle&Tn.Underline||s.fontStyle&Tn.Strikethrough));d&&s.content.match(/^\s+$/)&&t[l+1]?(i===void 0&&(i=s.offset),r+=s.content):r?(d?n.push({...s,offset:i,content:r+s.content}):n.push({content:r,offset:i},s),i=void 0,r=""):n.push(s)}),n})}function BP(e){return e.map(t=>t.flatMap(n=>{if(n.content.match(/^\s+$/))return n;const r=n.content.match(/^(\s*)(.*?)(\s*)$/);if(!r)return n;const[,i,s,l]=r;if(!i&&!l)return n;const c=[{...n,offset:n.offset+i.length,content:s}];return i&&c.unshift({content:i,offset:n.offset}),l&&c.push({content:l,offset:n.offset+i.length+s.length}),c}))}function jP(e){return e.map(t=>{const n=[];for(const r of t){if(n.length===0){n.push({...r});continue}const i=n[n.length-1],s=hg(i.htmlStyle||Hf(i)),l=hg(r.htmlStyle||Hf(r)),c=i.fontStyle&&(i.fontStyle&Tn.Underline||i.fontStyle&Tn.Strikethrough),d=r.fontStyle&&(r.fontStyle&Tn.Underline||r.fontStyle&Tn.Strikethrough);!c&&!d&&s===l?i.content+=r.content:n.push({...r})}return n})}const VP=dl;function UP(e,t,n){var s;const r={meta:{},options:n,codeToHast:(l,c)=>qf(e,l,c),codeToTokens:(l,c)=>Gf(e,l,c)};let i=VP(qf(e,t,n,r));for(const l of Wf(n))i=((s=l.postprocess)==null?void 0:s.call(r,i,n))||i;return i}const yy={light:"#333333",dark:"#bbbbbb"},wy={light:"#fffffe",dark:"#1e1e1e"},by="__shiki_resolved";function ch(e){var c,d,f,m,h;if(e!=null&&e[by])return e;const t={...e};t.tokenColors&&!t.settings&&(t.settings=t.tokenColors,delete t.tokenColors),t.type||(t.type="dark"),t.colorReplacements={...t.colorReplacements},t.settings||(t.settings=[]);let{bg:n,fg:r}=t;if(!n||!r){const g=t.settings?t.settings.find(y=>!y.name&&!y.scope):void 0;(c=g==null?void 0:g.settings)!=null&&c.foreground&&(r=g.settings.foreground),(d=g==null?void 0:g.settings)!=null&&d.background&&(n=g.settings.background),!r&&((f=t==null?void 0:t.colors)!=null&&f["editor.foreground"])&&(r=t.colors["editor.foreground"]),!n&&((m=t==null?void 0:t.colors)!=null&&m["editor.background"])&&(n=t.colors["editor.background"]),r||(r=t.type==="light"?yy.light:yy.dark),n||(n=t.type==="light"?wy.light:wy.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;const s=new Map;function l(g){var w;if(s.has(g))return s.get(g);i+=1;const y=`#${i.toString(16).padStart(8,"0").toLowerCase()}`;return(w=t.colorReplacements)!=null&&w[`#${y}`]?l(g):(s.set(g,y),y)}t.settings=t.settings.map(g=>{var C,I;const y=((C=g.settings)==null?void 0:C.foreground)&&!g.settings.foreground.startsWith("#"),w=((I=g.settings)==null?void 0:I.background)&&!g.settings.background.startsWith("#");if(!y&&!w)return g;const _={...g,settings:{...g.settings}};if(y){const E=l(g.settings.foreground);t.colorReplacements[E]=g.settings.foreground,_.settings.foreground=E}if(w){const E=l(g.settings.background);t.colorReplacements[E]=g.settings.background,_.settings.background=E}return _});for(const g of Object.keys(t.colors||{}))if((g==="editor.foreground"||g==="editor.background"||g.startsWith("terminal.ansi"))&&!((h=t.colors[g])!=null&&h.startsWith("#"))){const y=l(t.colors[g]);t.colorReplacements[y]=t.colors[g],t.colors[g]=y}return Object.defineProperty(t,by,{enumerable:!1,writable:!1,value:!0}),t}async function e_(e){return Array.from(new Set((await Promise.all(e.filter(t=>!Kx(t)).map(async t=>await qx(t).then(n=>Array.isArray(n)?n:[n])))).flat()))}async function t_(e){return(await Promise.all(e.map(async n=>Xx(n)?null:ch(await qx(n))))).filter(n=>!!n)}let zP=3;function HP(e,t=3){t>zP||console.trace(`[SHIKI DEPRECATE]: ${e}`)}let sl=class extends Error{constructor(t){super(t),this.name="ShikiError"}};function n_(e,t){if(!t)return e;if(t[e]){const n=new Set([e]);for(;t[e];){if(e=t[e],n.has(e))throw new sl(`Circular alias \`${Array.from(n).join(" -> ")} -> ${e}\``);n.add(e)}}return e}class WP extends KI{constructor(n,r,i,s={}){super(n);F(this,"_resolvedThemes",new Map);F(this,"_resolvedGrammars",new Map);F(this,"_langMap",new Map);F(this,"_langGraph",new Map);F(this,"_textmateThemeCache",new WeakMap);F(this,"_loadedThemesCache",null);F(this,"_loadedLanguagesCache",null);this._resolver=n,this._themes=r,this._langs=i,this._alias=s,this._themes.map(l=>this.loadTheme(l)),this.loadLanguages(this._langs)}getTheme(n){return typeof n=="string"?this._resolvedThemes.get(n):this.loadTheme(n)}loadTheme(n){const r=ch(n);return r.name&&(this._resolvedThemes.set(r.name,r),this._loadedThemesCache=null),r}getLoadedThemes(){return this._loadedThemesCache||(this._loadedThemesCache=[...this._resolvedThemes.keys()]),this._loadedThemesCache}setTheme(n){let r=this._textmateThemeCache.get(n);r||(r=$f.createFromRawTheme(n),this._textmateThemeCache.set(n,r)),this._syncRegistry.setTheme(r)}getGrammar(n){return n=n_(n,this._alias),this._resolvedGrammars.get(n)}loadLanguage(n){var l,c,d,f;if(this.getGrammar(n.name))return;const r=new Set([...this._langMap.values()].filter(m=>{var h;return(h=m.embeddedLangsLazy)==null?void 0:h.includes(n.name)}));this._resolver.addLanguage(n);const i={balancedBracketSelectors:n.balancedBracketSelectors||["*"],unbalancedBracketSelectors:n.unbalancedBracketSelectors||[]};this._syncRegistry._rawGrammars.set(n.scopeName,n);const s=this.loadGrammarWithConfiguration(n.scopeName,1,i);if(s.name=n.name,this._resolvedGrammars.set(n.name,s),n.aliases&&n.aliases.forEach(m=>{this._alias[m]=n.name}),this._loadedLanguagesCache=null,r.size)for(const m of r)this._resolvedGrammars.delete(m.name),this._loadedLanguagesCache=null,(c=(l=this._syncRegistry)==null?void 0:l._injectionGrammars)==null||c.delete(m.scopeName),(f=(d=this._syncRegistry)==null?void 0:d._grammars)==null||f.delete(m.scopeName),this.loadLanguage(this._langMap.get(m.name))}dispose(){super.dispose(),this._resolvedThemes.clear(),this._resolvedGrammars.clear(),this._langMap.clear(),this._langGraph.clear(),this._loadedThemesCache=null}loadLanguages(n){for(const s of n)this.resolveEmbeddedLanguages(s);const r=Array.from(this._langGraph.entries()),i=r.filter(([s,l])=>!l);if(i.length){const s=r.filter(([l,c])=>{if(!c)return!1;const d=c.embeddedLanguages||c.embeddedLangs;return d==null?void 0:d.some(f=>i.map(([m])=>m).includes(f))}).filter(l=>!i.includes(l));throw new sl(`Missing languages ${i.map(([l])=>`\`${l}\``).join(", ")}, required by ${s.map(([l])=>`\`${l}\``).join(", ")}`)}for(const[s,l]of r)this._resolver.addLanguage(l);for(const[s,l]of r)this.loadLanguage(l)}getLoadedLanguages(){return this._loadedLanguagesCache||(this._loadedLanguagesCache=[...new Set([...this._resolvedGrammars.keys(),...Object.keys(this._alias)])]),this._loadedLanguagesCache}resolveEmbeddedLanguages(n){this._langMap.set(n.name,n),this._langGraph.set(n.name,n);const r=n.embeddedLanguages??n.embeddedLangs;if(r)for(const i of r)this._langGraph.set(i,this._langMap.get(i))}}class GP{constructor(t,n){F(this,"_langs",new Map);F(this,"_scopeToLang",new Map);F(this,"_injections",new Map);F(this,"_onigLib");this._onigLib={createOnigScanner:r=>t.createScanner(r),createOnigString:r=>t.createString(r)},n.forEach(r=>this.addLanguage(r))}get onigLib(){return this._onigLib}getLangRegistration(t){return this._langs.get(t)}loadGrammar(t){return this._scopeToLang.get(t)}addLanguage(t){this._langs.set(t.name,t),t.aliases&&t.aliases.forEach(n=>{this._langs.set(n,t)}),this._scopeToLang.set(t.scopeName,t),t.injectTo&&t.injectTo.forEach(n=>{this._injections.get(n)||this._injections.set(n,[]),this._injections.get(n).push(t.scopeName)})}getInjections(t){const n=t.split(".");let r=[];for(let i=1;i<=n.length;i++){const s=n.slice(0,i).join(".");r=[...r,...this._injections.get(s)||[]]}return r}}let Ic=0;function qP(e){Ic+=1,e.warnings!==!1&&Ic>=10&&Ic%10===0&&console.warn(`[Shiki] ${Ic} 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 sl("`engine` option is required for synchronous mode");const n=(e.langs||[]).flat(1),r=(e.themes||[]).flat(1).map(ch),i=new GP(e.engine,n),s=new WP(i,r,n,e.langAlias);let l;function c(S){return n_(S,e.langAlias)}function d(S){I();const L=s.getGrammar(typeof S=="string"?S:S.name);if(!L)throw new sl(`Language \`${S}\` not found, you may need to load it first`);return L}function f(S){if(S==="none")return{bg:"",fg:"",name:"none",settings:[],type:"dark"};I();const L=s.getTheme(S);if(!L)throw new sl(`Theme \`${S}\` not found, you may need to load it first`);return L}function m(S){I();const L=f(S);l!==S&&(s.setTheme(L),l=S);const A=s.getColorMap();return{theme:L,colorMap:A}}function h(){return I(),s.getLoadedThemes()}function g(){return I(),s.getLoadedLanguages()}function y(...S){I(),s.loadLanguages(S.flat(1))}async function w(...S){return y(await e_(S))}function _(...S){I();for(const L of S.flat(1))s.loadTheme(L)}async function C(...S){return I(),_(await t_(S))}function I(){if(t)throw new sl("Shiki instance has been disposed")}function E(){t||(t=!0,s.dispose(),Ic-=1)}return{setTheme:m,getTheme:f,getLanguage:d,getLoadedThemes:h,getLoadedLanguages:g,resolveLangAlias:c,loadLanguage:w,loadLanguageSync:y,loadTheme:C,loadThemeSync:_,dispose:E,[Symbol.dispose]:E}}async function KP(e){e.engine||HP("`engine` option is required. Use `createOnigurumaEngine` or `createJavaScriptRegexEngine` to create an engine.");const[t,n,r]=await Promise.all([t_(e.themes||[]),e_(e.langs||[]),e.engine]);return qP({...e,themes:t,langs:n,engine:r})}async function XP(e){const t=await KP(e);return{getLastGrammarState:(...n)=>DP(t,...n),codeToTokensBase:(n,r)=>I0(t,n,r),codeToTokensWithThemes:(n,r)=>Zx(t,n,r),codeToTokens:(n,r)=>Gf(t,n,r),codeToHast:(n,r)=>qf(t,n,r),codeToHtml:(n,r)=>UP(t,n,r),getBundledLanguages:()=>({}),getBundledThemes:()=>({}),...t,getInternalContext:()=>t}}function QP(e){const t=e.langs,n=e.themes,r=e.engine;async function i(s){function l(h){var g;if(typeof h=="string"){if(h=((g=s.langAlias)==null?void 0:g[h])||h,Kx(h))return[];const y=t[h];if(!y)throw new Xt(`Language \`${h}\` is not included in this bundle. You may want to load it from external source.`);return y}return h}function c(h){if(Xx(h))return"none";if(typeof h=="string"){const g=n[h];if(!g)throw new Xt(`Theme \`${h}\` is not included in this bundle. You may want to load it from external source.`);return g}return h}const d=(s.themes??[]).map(h=>c(h)),f=(s.langs??[]).map(h=>l(h)),m=await XP({engine:s.engine??r(),...s,themes:d,langs:f});return{...m,loadLanguage(...h){return m.loadLanguage(...h.map(l))},loadTheme(...h){return m.loadTheme(...h.map(c))},getBundledLanguages(){return t},getBundledThemes(){return n}}}return i}const r_=[{id:"abap",name:"ABAP",import:(()=>D(()=>import("./abap-BdImnpbu.js"),[]))},{id:"actionscript-3",name:"ActionScript",import:(()=>D(()=>import("./actionscript-3-CoDkCxhg.js"),[]))},{id:"ada",name:"Ada",import:(()=>D(()=>import("./ada-bCR0ucgS.js"),[]))},{id:"angular-html",name:"Angular HTML",import:(()=>D(()=>import("./angular-html-CU67Zn6k.js").then(e=>e.f),__vite__mapDeps([0,1,2,3])))},{id:"angular-ts",name:"Angular TypeScript",import:(()=>D(()=>import("./angular-ts-BwZT4LLn.js"),__vite__mapDeps([4,0,1,2,3,5])))},{id:"apache",name:"Apache Conf",import:(()=>D(()=>import("./apache-Pmp26Uib.js"),[]))},{id:"apex",name:"Apex",import:(()=>D(()=>import("./apex-D8_7TLub.js"),[]))},{id:"apl",name:"APL",import:(()=>D(()=>import("./apl-dKokRX4l.js"),__vite__mapDeps([6,1,2,3,7,8,9])))},{id:"applescript",name:"AppleScript",import:(()=>D(()=>import("./applescript-Co6uUVPk.js"),[]))},{id:"ara",name:"Ara",import:(()=>D(()=>import("./ara-BRHolxvo.js"),[]))},{id:"asciidoc",name:"AsciiDoc",aliases:["adoc"],import:(()=>D(()=>import("./asciidoc-Ve4PFQV2.js"),[]))},{id:"asm",name:"Assembly",import:(()=>D(()=>import("./asm-D_Q5rh1f.js"),[]))},{id:"astro",name:"Astro",import:(()=>D(()=>import("./astro-CbQHKStN.js"),__vite__mapDeps([10,9,2,11,3,12,13])))},{id:"awk",name:"AWK",import:(()=>D(()=>import("./awk-DMzUqQB5.js"),[]))},{id:"ballerina",name:"Ballerina",import:(()=>D(()=>import("./ballerina-BFfxhgS-.js"),[]))},{id:"bat",name:"Batch File",aliases:["batch"],import:(()=>D(()=>import("./bat-BkioyH1T.js"),[]))},{id:"beancount",name:"Beancount",import:(()=>D(()=>import("./beancount-k_qm7-4y.js"),[]))},{id:"berry",name:"Berry",aliases:["be"],import:(()=>D(()=>import("./berry-uYugtg8r.js"),[]))},{id:"bibtex",name:"BibTeX",import:(()=>D(()=>import("./bibtex-CHM0blh-.js"),[]))},{id:"bicep",name:"Bicep",import:(()=>D(()=>import("./bicep-Bmn6On1c.js"),[]))},{id:"bird2",name:"BIRD2 Configuration",aliases:["bird"],import:(()=>D(()=>import("./bird2-DPOp833l.js"),[]))},{id:"blade",name:"Blade",import:(()=>D(()=>import("./blade-D4QpJJKB.js"),__vite__mapDeps([14,15,1,2,3,7,8,16,9])))},{id:"bsl",name:"1C (Enterprise)",aliases:["1c"],import:(()=>D(()=>import("./bsl-BO_Y6i37.js"),__vite__mapDeps([17,18])))},{id:"c",name:"C",import:(()=>D(()=>import("./c-BIGW1oBm.js"),[]))},{id:"c3",name:"C3",import:(()=>D(()=>import("./c3-eo99z4R2.js"),[]))},{id:"cadence",name:"Cadence",aliases:["cdc"],import:(()=>D(()=>import("./cadence-Bv_4Rxtq.js"),[]))},{id:"cairo",name:"Cairo",import:(()=>D(()=>import("./cairo-KRGpt6FW.js"),__vite__mapDeps([19,20])))},{id:"clarity",name:"Clarity",import:(()=>D(()=>import("./clarity-D53aC0YG.js"),[]))},{id:"clojure",name:"Clojure",aliases:["clj"],import:(()=>D(()=>import("./clojure-P80f7IUj.js"),[]))},{id:"cmake",name:"CMake",import:(()=>D(()=>import("./cmake-D1j8_8rp.js"),[]))},{id:"cobol",name:"COBOL",import:(()=>D(()=>import("./cobol-nwyudZeR.js"),__vite__mapDeps([21,1,2,3,8])))},{id:"codeowners",name:"CODEOWNERS",import:(()=>D(()=>import("./codeowners-Bp6g37R7.js"),[]))},{id:"codeql",name:"CodeQL",aliases:["ql"],import:(()=>D(()=>import("./codeql-DsOJ9woJ.js"),[]))},{id:"coffee",name:"CoffeeScript",aliases:["coffeescript"],import:(()=>D(()=>import("./coffee-Ch7k5sss.js"),__vite__mapDeps([22,2])))},{id:"common-lisp",name:"Common Lisp",aliases:["lisp"],import:(()=>D(()=>import("./common-lisp-Cg-RD9OK.js"),[]))},{id:"coq",name:"Coq",import:(()=>D(()=>import("./coq-DkFqJrB1.js"),[]))},{id:"cpp",name:"C++",aliases:["c++"],import:(()=>D(()=>import("./cpp-CofmeUqb.js"),__vite__mapDeps([23,24,25,26,16])))},{id:"crystal",name:"Crystal",import:(()=>D(()=>import("./crystal-tKQVLTB8.js"),__vite__mapDeps([27,1,2,3,16,26,28])))},{id:"csharp",name:"C#",aliases:["c#","cs"],import:(()=>D(()=>import("./csharp-COcwbKMJ.js"),[]))},{id:"css",name:"CSS",import:(()=>D(()=>import("./css-DPfMkruS.js"),[]))},{id:"csv",name:"CSV",import:(()=>D(()=>import("./csv-fuZLfV_i.js"),[]))},{id:"cue",name:"CUE",import:(()=>D(()=>import("./cue-D82EKSYY.js"),[]))},{id:"cypher",name:"Cypher",aliases:["cql"],import:(()=>D(()=>import("./cypher-COkxafJQ.js"),[]))},{id:"d",name:"D",import:(()=>D(()=>import("./d-85-TOEBH.js"),[]))},{id:"dart",name:"Dart",import:(()=>D(()=>import("./dart-CF10PKvl.js"),[]))},{id:"dax",name:"DAX",import:(()=>D(()=>import("./dax-CEL-wOlO.js"),[]))},{id:"desktop",name:"Desktop",import:(()=>D(()=>import("./desktop-BmXAJ9_W.js"),[]))},{id:"diff",name:"Diff",import:(()=>D(()=>import("./diff-D97Zzqfu.js"),[]))},{id:"docker",name:"Dockerfile",aliases:["dockerfile"],import:(()=>D(()=>import("./docker-BcOcwvcX.js"),[]))},{id:"dotenv",name:"dotEnv",import:(()=>D(()=>import("./dotenv-Da5cRb03.js"),[]))},{id:"dream-maker",name:"Dream Maker",import:(()=>D(()=>import("./dream-maker-BtqSS_iP.js"),[]))},{id:"edge",name:"Edge",import:(()=>D(()=>import("./edge-BkV0erSs.js"),__vite__mapDeps([29,11,1,2,3,15])))},{id:"elixir",name:"Elixir",import:(()=>D(()=>import("./elixir-CDX3lj18.js"),__vite__mapDeps([30,1,2,3])))},{id:"elm",name:"Elm",import:(()=>D(()=>import("./elm-DbKCFpqz.js"),__vite__mapDeps([31,25,26])))},{id:"emacs-lisp",name:"Emacs Lisp",aliases:["elisp"],import:(()=>D(()=>import("./emacs-lisp-C9XAeP06.js"),[]))},{id:"erb",name:"ERB",import:(()=>D(()=>import("./erb-B12qg9BL.js"),__vite__mapDeps([32,1,2,3,33,34,7,8,16,35,11,36,13,23,24,25,26,28,37,38])))},{id:"erlang",name:"Erlang",aliases:["erl"],import:(()=>D(()=>import("./erlang-DsQrWhSR.js"),__vite__mapDeps([39,40])))},{id:"fennel",name:"Fennel",import:(()=>D(()=>import("./fennel-BYunw83y.js"),[]))},{id:"fish",name:"Fish",import:(()=>D(()=>import("./fish-BvzEVeQv.js"),[]))},{id:"fluent",name:"Fluent",aliases:["ftl"],import:(()=>D(()=>import("./fluent-C4IJs8-o.js"),[]))},{id:"fortran-fixed-form",name:"Fortran (Fixed Form)",aliases:["f","for","f77"],import:(()=>D(()=>import("./fortran-fixed-form-CkoXwp7k.js"),__vite__mapDeps([41,42])))},{id:"fortran-free-form",name:"Fortran (Free Form)",aliases:["f90","f95","f03","f08","f18"],import:(()=>D(()=>import("./fortran-free-form-BxgE0vQu.js"),[]))},{id:"fsharp",name:"F#",aliases:["f#","fs"],import:(()=>D(()=>import("./fsharp-CXgrBDvD.js"),__vite__mapDeps([43,40])))},{id:"gdresource",name:"GDResource",aliases:["tscn","tres"],import:(()=>D(()=>import("./gdresource-BOOCDP_w.js"),__vite__mapDeps([44,45,46])))},{id:"gdscript",name:"GDScript",aliases:["gd"],import:(()=>D(()=>import("./gdscript-C5YyOfLZ.js"),[]))},{id:"gdshader",name:"GDShader",import:(()=>D(()=>import("./gdshader-DkwncUOv.js"),[]))},{id:"genie",name:"Genie",import:(()=>D(()=>import("./genie-D0YGMca9.js"),[]))},{id:"gherkin",name:"Gherkin",import:(()=>D(()=>import("./gherkin-DyxjwDmM.js"),[]))},{id:"git-commit",name:"Git Commit Message",import:(()=>D(()=>import("./git-commit-F4YmCXRG.js"),__vite__mapDeps([47,48])))},{id:"git-rebase",name:"Git Rebase Message",import:(()=>D(()=>import("./git-rebase-r7XF79zn.js"),__vite__mapDeps([49,28])))},{id:"gleam",name:"Gleam",import:(()=>D(()=>import("./gleam-BspZqrRM.js"),[]))},{id:"glimmer-js",name:"Glimmer JS",aliases:["gjs"],import:(()=>D(()=>import("./glimmer-js-Rg0-pVw9.js"),__vite__mapDeps([50,2,11,3,1])))},{id:"glimmer-ts",name:"Glimmer TS",aliases:["gts"],import:(()=>D(()=>import("./glimmer-ts-U6CK756n.js"),__vite__mapDeps([51,11,3,2,1])))},{id:"glsl",name:"GLSL",import:(()=>D(()=>import("./glsl-DplSGwfg.js"),__vite__mapDeps([25,26])))},{id:"gn",name:"GN",import:(()=>D(()=>import("./gn-n2N0HUVH.js"),[]))},{id:"gnuplot",name:"Gnuplot",import:(()=>D(()=>import("./gnuplot-DdkO51Og.js"),[]))},{id:"go",name:"Go",import:(()=>D(()=>import("./go-CxLEBnE3.js"),[]))},{id:"graphql",name:"GraphQL",aliases:["gql"],import:(()=>D(()=>import("./graphql-ChdNCCLP.js"),__vite__mapDeps([35,2,11,36,13])))},{id:"groovy",name:"Groovy",import:(()=>D(()=>import("./groovy-gcz8RCvz.js"),[]))},{id:"hack",name:"Hack",import:(()=>D(()=>import("./hack-CaT9iCJl.js"),__vite__mapDeps([52,1,2,3,16])))},{id:"haml",name:"Ruby Haml",import:(()=>D(()=>import("./haml-B8DHNrY2.js"),__vite__mapDeps([34,2,3])))},{id:"handlebars",name:"Handlebars",aliases:["hbs"],import:(()=>D(()=>import("./handlebars-BL8al0AC.js"),__vite__mapDeps([53,1,2,3,38])))},{id:"haskell",name:"Haskell",aliases:["hs"],import:(()=>D(()=>import("./haskell-Df6bDoY_.js"),[]))},{id:"haxe",name:"Haxe",import:(()=>D(()=>import("./haxe-CzTSHFRz.js"),[]))},{id:"hcl",name:"HashiCorp HCL",import:(()=>D(()=>import("./hcl-BWvSN4gD.js"),[]))},{id:"hjson",name:"Hjson",import:(()=>D(()=>import("./hjson-D5-asLiD.js"),[]))},{id:"hlsl",name:"HLSL",import:(()=>D(()=>import("./hlsl-D3lLCCz7.js"),[]))},{id:"html",name:"HTML",import:(()=>D(()=>import("./html-GMplVEZG.js"),__vite__mapDeps([1,2,3])))},{id:"html-derivative",name:"HTML (Derivative)",import:(()=>D(()=>import("./html-derivative-BFtXZ54Q.js"),__vite__mapDeps([15,1,2,3])))},{id:"http",name:"HTTP",import:(()=>D(()=>import("./http-jrhK8wxY.js"),__vite__mapDeps([54,28,9,7,8,35,2,11,36,13])))},{id:"hurl",name:"Hurl",import:(()=>D(()=>import("./hurl-irOxFIW8.js"),__vite__mapDeps([55,35,2,11,36,13,7,8,56])))},{id:"hxml",name:"HXML",import:(()=>D(()=>import("./hxml-Bvhsp5Yf.js"),__vite__mapDeps([57,58])))},{id:"hy",name:"Hy",import:(()=>D(()=>import("./hy-DFXneXwc.js"),[]))},{id:"imba",name:"Imba",import:(()=>D(()=>import("./imba-DGztddWO.js"),[]))},{id:"ini",name:"INI",aliases:["properties"],import:(()=>D(()=>import("./ini-BEwlwnbL.js"),[]))},{id:"java",name:"Java",import:(()=>D(()=>import("./java-CylS5w8V.js"),[]))},{id:"javascript",name:"JavaScript",aliases:["js","cjs","mjs"],import:(()=>D(()=>import("./javascript-wDzz0qaB.js"),[]))},{id:"jinja",name:"Jinja",import:(()=>D(()=>import("./jinja-4LBKfQ-Z.js"),__vite__mapDeps([59,1,2,3])))},{id:"jison",name:"Jison",import:(()=>D(()=>import("./jison-wvAkD_A8.js"),__vite__mapDeps([60,2])))},{id:"json",name:"JSON",import:(()=>D(()=>import("./json-Cp-IABpG.js"),[]))},{id:"json5",name:"JSON5",import:(()=>D(()=>import("./json5-C9tS-k6U.js"),[]))},{id:"jsonc",name:"JSON with Comments",import:(()=>D(()=>import("./jsonc-Des-eS-w.js"),[]))},{id:"jsonl",name:"JSON Lines",import:(()=>D(()=>import("./jsonl-DcaNXYhu.js"),[]))},{id:"jsonnet",name:"Jsonnet",import:(()=>D(()=>import("./jsonnet-DFQXde-d.js"),[]))},{id:"jssm",name:"JSSM",aliases:["fsl"],import:(()=>D(()=>import("./jssm-C2t-YnRu.js"),[]))},{id:"jsx",name:"JSX",import:(()=>D(()=>import("./jsx-g9-lgVsj.js"),[]))},{id:"julia",name:"Julia",aliases:["jl"],import:(()=>D(()=>import("./julia-CxzCAyBv.js"),__vite__mapDeps([61,23,24,25,26,16,20,2,62])))},{id:"just",name:"Just",import:(()=>D(()=>import("./just-Cw27pwNe.js"),__vite__mapDeps([63,28,2,11,64,1,3,7,8,16,20,33,34,35,36,13,23,24,25,26,37,38])))},{id:"kdl",name:"KDL",import:(()=>D(()=>import("./kdl-DV7GczEv.js"),[]))},{id:"kotlin",name:"Kotlin",aliases:["kt","kts"],import:(()=>D(()=>import("./kotlin-BdnUsdx6.js"),[]))},{id:"kusto",name:"Kusto",aliases:["kql"],import:(()=>D(()=>import("./kusto-DZf3V79B.js"),[]))},{id:"latex",name:"LaTeX",import:(()=>D(()=>import("./latex-CWtU0Tv5.js"),__vite__mapDeps([65,66,62])))},{id:"lean",name:"Lean 4",aliases:["lean4"],import:(()=>D(()=>import("./lean-BZvkOJ9d.js"),[]))},{id:"less",name:"Less",import:(()=>D(()=>import("./less-B1dDrJ26.js"),[]))},{id:"liquid",name:"Liquid",import:(()=>D(()=>import("./liquid-DYVedYrR.js"),__vite__mapDeps([67,1,2,3,9])))},{id:"llvm",name:"LLVM IR",import:(()=>D(()=>import("./llvm-DjAJT7YJ.js"),[]))},{id:"log",name:"Log file",import:(()=>D(()=>import("./log-2UxHyX5q.js"),[]))},{id:"logo",name:"Logo",import:(()=>D(()=>import("./logo-BtOb2qkB.js"),[]))},{id:"lua",name:"Lua",import:(()=>D(()=>import("./lua-BaeVxFsk.js"),__vite__mapDeps([37,26])))},{id:"luau",name:"Luau",import:(()=>D(()=>import("./luau-C-HG3fhB.js"),[]))},{id:"make",name:"Makefile",aliases:["makefile"],import:(()=>D(()=>import("./make-CHLpvVh8.js"),[]))},{id:"markdown",name:"Markdown",aliases:["md"],import:(()=>D(()=>import("./markdown-Cvjx9yec.js"),[]))},{id:"marko",name:"Marko",import:(()=>D(()=>import("./marko-CnJfTvn9.js"),__vite__mapDeps([68,3,69,5,11])))},{id:"matlab",name:"MATLAB",import:(()=>D(()=>import("./matlab-D7o27uSR.js"),[]))},{id:"mdc",name:"MDC",import:(()=>D(()=>import("./mdc-BMNejdWA.js"),__vite__mapDeps([70,40,38,15,1,2,3])))},{id:"mdx",name:"MDX",import:(()=>D(()=>import("./mdx-Cmh6b_Ma.js"),[]))},{id:"mermaid",name:"Mermaid",aliases:["mmd"],import:(()=>D(()=>import("./mermaid-mWjccvbQ.js"),[]))},{id:"mipsasm",name:"MIPS Assembly",aliases:["mips"],import:(()=>D(()=>import("./mipsasm-CKIfxQSi.js"),[]))},{id:"mojo",name:"Mojo",import:(()=>D(()=>import("./mojo-rZm6bMo-.js"),[]))},{id:"moonbit",name:"MoonBit",aliases:["mbt","mbti"],import:(()=>D(()=>import("./moonbit-_H4v1dQx.js"),[]))},{id:"move",name:"Move",import:(()=>D(()=>import("./move-IF9eRakj.js"),[]))},{id:"narrat",name:"Narrat Language",aliases:["nar"],import:(()=>D(()=>import("./narrat-DRg8JJMk.js"),[]))},{id:"nextflow",name:"Nextflow",aliases:["nf"],import:(()=>D(()=>import("./nextflow-Zz6hmt5N.js"),__vite__mapDeps([71,72])))},{id:"nextflow-groovy",name:"nextflow-groovy",import:(()=>D(()=>import("./nextflow-groovy-BeH2EWoN.js"),[]))},{id:"nginx",name:"Nginx",import:(()=>D(()=>import("./nginx-BpAMiNFr.js"),__vite__mapDeps([73,37,26])))},{id:"nim",name:"Nim",import:(()=>D(()=>import("./nim-CVrawwO9.js"),__vite__mapDeps([74,26,1,2,3,7,8,25,40])))},{id:"nix",name:"Nix",import:(()=>D(()=>import("./nix-CwoSXNpI.js"),[]))},{id:"nushell",name:"nushell",aliases:["nu"],import:(()=>D(()=>import("./nushell-Cz2AlsmD.js"),[]))},{id:"objective-c",name:"Objective-C",aliases:["objc"],import:(()=>D(()=>import("./objective-c-DXmwc3jG.js"),[]))},{id:"objective-cpp",name:"Objective-C++",import:(()=>D(()=>import("./objective-cpp-CLxacb5B.js"),[]))},{id:"ocaml",name:"OCaml",import:(()=>D(()=>import("./ocaml-C0hk2d4L.js"),[]))},{id:"odin",name:"Odin",import:(()=>D(()=>import("./odin-BBf5iR-q.js"),[]))},{id:"openscad",name:"OpenSCAD",aliases:["scad"],import:(()=>D(()=>import("./openscad-C4EeE6gA.js"),[]))},{id:"pascal",name:"Pascal",import:(()=>D(()=>import("./pascal-D93ZcfNL.js"),[]))},{id:"perl",name:"Perl",import:(()=>D(()=>import("./perl-C0TMdlhV.js"),__vite__mapDeps([64,1,2,3,7,8,16])))},{id:"php",name:"PHP",import:(()=>D(()=>import("./php-Dhbhpdrm.js"),__vite__mapDeps([75,1,2,3,7,8,16,9])))},{id:"pkl",name:"Pkl",import:(()=>D(()=>import("./pkl-u5AG7uiY.js"),[]))},{id:"plsql",name:"PL/SQL",import:(()=>D(()=>import("./plsql-ChMvpjG-.js"),[]))},{id:"po",name:"Gettext PO",aliases:["pot","potx"],import:(()=>D(()=>import("./po-BTJTHyun.js"),[]))},{id:"polar",name:"Polar",import:(()=>D(()=>import("./polar-C0HS_06l.js"),[]))},{id:"postcss",name:"PostCSS",import:(()=>D(()=>import("./postcss-CXtECtnM.js"),[]))},{id:"powerquery",name:"PowerQuery",import:(()=>D(()=>import("./powerquery-CEu0bR-o.js"),[]))},{id:"powershell",name:"PowerShell",aliases:["ps","ps1"],import:(()=>D(()=>import("./powershell-Dpen1YoG.js"),[]))},{id:"prisma",name:"Prisma",import:(()=>D(()=>import("./prisma-Dd19v3D-.js"),[]))},{id:"prolog",name:"Prolog",import:(()=>D(()=>import("./prolog-CbFg5uaA.js"),[]))},{id:"proto",name:"Protocol Buffer 3",aliases:["protobuf"],import:(()=>D(()=>import("./proto-C7zT0LnQ.js"),[]))},{id:"pug",name:"Pug",aliases:["jade"],import:(()=>D(()=>import("./pug-CGlum2m_.js"),__vite__mapDeps([76,2,3,1])))},{id:"puppet",name:"Puppet",import:(()=>D(()=>import("./puppet-BMWR74SV.js"),[]))},{id:"purescript",name:"PureScript",import:(()=>D(()=>import("./purescript-CklMAg4u.js"),[]))},{id:"python",name:"Python",aliases:["py"],import:(()=>D(()=>import("./python-B6aJPvgy.js"),[]))},{id:"qml",name:"QML",import:(()=>D(()=>import("./qml-3beO22l8.js"),__vite__mapDeps([77,2])))},{id:"qmldir",name:"QML Directory",import:(()=>D(()=>import("./qmldir-C8lEn-DE.js"),[]))},{id:"qss",name:"Qt Style Sheets",import:(()=>D(()=>import("./qss-IeuSbFQv.js"),[]))},{id:"r",name:"R",import:(()=>D(()=>import("./r-Dspwwk_N.js"),[]))},{id:"racket",name:"Racket",import:(()=>D(()=>import("./racket-BqYA7rlc.js"),[]))},{id:"raku",name:"Raku",aliases:["perl6"],import:(()=>D(()=>import("./raku-DXvB9xmW.js"),[]))},{id:"razor",name:"ASP.NET Razor",import:(()=>D(()=>import("./razor-Uh8Bk_45.js"),__vite__mapDeps([78,1,2,3,79])))},{id:"reg",name:"Windows Registry Script",import:(()=>D(()=>import("./reg-C-SQnVFl.js"),[]))},{id:"regexp",name:"RegExp",aliases:["regex"],import:(()=>D(()=>import("./regexp-CDVJQ6XC.js"),[]))},{id:"rel",name:"Rel",import:(()=>D(()=>import("./rel-C3B-1QV4.js"),[]))},{id:"riscv",name:"RISC-V",import:(()=>D(()=>import("./riscv-BM1_JUlF.js"),[]))},{id:"ron",name:"RON",import:(()=>D(()=>import("./ron-D8l8udqQ.js"),[]))},{id:"rosmsg",name:"ROS Interface",import:(()=>D(()=>import("./rosmsg-BJDFO7_C.js"),[]))},{id:"rst",name:"reStructuredText",import:(()=>D(()=>import("./rst-BrH8l1NY.js"),__vite__mapDeps([80,15,1,2,3,23,24,25,26,16,20,28,38,81,33,34,7,8,35,11,36,13,37])))},{id:"ruby",name:"Ruby",aliases:["rb"],import:(()=>D(()=>import("./ruby-Dw2BHqvy.js"),__vite__mapDeps([33,1,2,3,34,7,8,16,35,11,36,13,23,24,25,26,28,37,38])))},{id:"rust",name:"Rust",aliases:["rs"],import:(()=>D(()=>import("./rust-B1yitclQ.js"),[]))},{id:"sas",name:"SAS",import:(()=>D(()=>import("./sas-cz2c8ADy.js"),__vite__mapDeps([82,16])))},{id:"sass",name:"Sass",import:(()=>D(()=>import("./sass-Cj5Yp3dK.js"),[]))},{id:"scala",name:"Scala",import:(()=>D(()=>import("./scala-C151Ov-r.js"),[]))},{id:"scheme",name:"Scheme",import:(()=>D(()=>import("./scheme-C98Dy4si.js"),[]))},{id:"scss",name:"SCSS",import:(()=>D(()=>import("./scss-OYdSNvt2.js"),__vite__mapDeps([5,3])))},{id:"sdbl",name:"1C (Query)",aliases:["1c-query"],import:(()=>D(()=>import("./sdbl-DVxCFoDh.js"),[]))},{id:"shaderlab",name:"ShaderLab",aliases:["shader"],import:(()=>D(()=>import("./shaderlab-Dg9Lc6iA.js"),__vite__mapDeps([83,84])))},{id:"shellscript",name:"Shell",aliases:["bash","sh","shell","zsh"],import:(()=>D(()=>import("./shellscript-Yzrsuije.js"),[]))},{id:"shellsession",name:"Shell Session",aliases:["console"],import:(()=>D(()=>import("./shellsession-BADoaaVG.js"),__vite__mapDeps([85,28])))},{id:"smalltalk",name:"Smalltalk",import:(()=>D(()=>import("./smalltalk-BERRCDM3.js"),[]))},{id:"solidity",name:"Solidity",import:(()=>D(()=>import("./solidity-rGO070M0.js"),[]))},{id:"soy",name:"Closure Templates",aliases:["closure-templates"],import:(()=>D(()=>import("./soy-Brmx7dQM.js"),__vite__mapDeps([86,1,2,3])))},{id:"sparql",name:"SPARQL",import:(()=>D(()=>import("./sparql-rVzFXLq3.js"),__vite__mapDeps([87,88])))},{id:"splunk",name:"Splunk Query Language",aliases:["spl"],import:(()=>D(()=>import("./splunk-BtCnVYZw.js"),[]))},{id:"sql",name:"SQL",import:(()=>D(()=>import("./sql-BLtJtn59.js"),[]))},{id:"ssh-config",name:"SSH Config",import:(()=>D(()=>import("./ssh-config-_ykCGR6B.js"),[]))},{id:"stata",name:"Stata",import:(()=>D(()=>import("./stata-BH5u7GGu.js"),__vite__mapDeps([89,16])))},{id:"stylus",name:"Stylus",aliases:["styl"],import:(()=>D(()=>import("./stylus-BEDo0Tqx.js"),[]))},{id:"surrealql",name:"SurrealQL",aliases:["surql"],import:(()=>D(()=>import("./surrealql-Bq5Q-fJD.js"),__vite__mapDeps([90,2])))},{id:"svelte",name:"Svelte",import:(()=>D(()=>import("./svelte-C_ipcX3V.js"),__vite__mapDeps([91,2,11,3,12])))},{id:"swift",name:"Swift",import:(()=>D(()=>import("./swift-D82vCrfD.js"),[]))},{id:"system-verilog",name:"SystemVerilog",import:(()=>D(()=>import("./system-verilog-CnnmHF94.js"),[]))},{id:"systemd",name:"Systemd Units",import:(()=>D(()=>import("./systemd-4A_iFExJ.js"),[]))},{id:"talonscript",name:"TalonScript",aliases:["talon"],import:(()=>D(()=>import("./talonscript-CkByrt1z.js"),[]))},{id:"tasl",name:"Tasl",import:(()=>D(()=>import("./tasl-QIJgUcNo.js"),[]))},{id:"tcl",name:"Tcl",import:(()=>D(()=>import("./tcl-dwOrl1Do.js"),[]))},{id:"templ",name:"Templ",import:(()=>D(()=>import("./templ-P3uqSqPl.js"),__vite__mapDeps([92,93,2,3])))},{id:"terraform",name:"Terraform",aliases:["tf","tfvars"],import:(()=>D(()=>import("./terraform-BETggiCN.js"),[]))},{id:"tex",name:"TeX",import:(()=>D(()=>import("./tex-idrVyKtj.js"),__vite__mapDeps([66,62])))},{id:"toml",name:"TOML",import:(()=>D(()=>import("./toml-vGWfd6FD.js"),[]))},{id:"ts-tags",name:"TypeScript with Tags",aliases:["lit"],import:(()=>D(()=>import("./ts-tags-zn1MmPIZ.js"),__vite__mapDeps([94,11,3,2,25,26,1,16,7,8])))},{id:"tsv",name:"TSV",import:(()=>D(()=>import("./tsv-B_m7g4N7.js"),[]))},{id:"tsx",name:"TSX",import:(()=>D(()=>import("./tsx-COt5Ahok.js"),[]))},{id:"turtle",name:"Turtle",import:(()=>D(()=>import("./turtle-BsS91CYL.js"),[]))},{id:"twig",name:"Twig",import:(()=>D(()=>import("./twig-DNn4PbVi.js"),__vite__mapDeps([95,3,2,5,75,1,7,8,16,9,20,33,34,35,11,36,13,23,24,25,26,28,37,38])))},{id:"typescript",name:"TypeScript",aliases:["ts","cts","mts"],import:(()=>D(()=>import("./typescript-BPQ3VLAy.js"),[]))},{id:"typespec",name:"TypeSpec",aliases:["tsp"],import:(()=>D(()=>import("./typespec-BGHnOYBU.js"),[]))},{id:"typst",name:"Typst",aliases:["typ"],import:(()=>D(()=>import("./typst-DHCkPAjA.js"),[]))},{id:"v",name:"V",import:(()=>D(()=>import("./v-BcVCzyr7.js"),[]))},{id:"vala",name:"Vala",import:(()=>D(()=>import("./vala-CsfeWuGM.js"),[]))},{id:"vb",name:"Visual Basic",aliases:["cmd"],import:(()=>D(()=>import("./vb-D17OF-Vu.js"),[]))},{id:"verilog",name:"Verilog",import:(()=>D(()=>import("./verilog-BQ8w6xss.js"),[]))},{id:"vhdl",name:"VHDL",import:(()=>D(()=>import("./vhdl-CeAyd5Ju.js"),[]))},{id:"viml",name:"Vim Script",aliases:["vim","vimscript"],import:(()=>D(()=>import("./viml-CJc9bBzg.js"),[]))},{id:"vue",name:"Vue",import:(()=>D(()=>import("./vue-DN_0RTcg.js"),__vite__mapDeps([96,3,2,11,9,1,15])))},{id:"vue-html",name:"Vue HTML",import:(()=>D(()=>import("./vue-html-AaS7Mt5G.js"),__vite__mapDeps([97,2])))},{id:"vue-vine",name:"Vue Vine",import:(()=>D(()=>import("./vue-vine-CQOfvN7w.js"),__vite__mapDeps([98,3,5,69,99,12,2])))},{id:"vyper",name:"Vyper",aliases:["vy"],import:(()=>D(()=>import("./vyper-CDx5xZoG.js"),[]))},{id:"wasm",name:"WebAssembly",import:(()=>D(()=>import("./wasm-MzD3tlZU.js"),[]))},{id:"wenyan",name:"Wenyan",aliases:["文言"],import:(()=>D(()=>import("./wenyan-BV7otONQ.js"),[]))},{id:"wgsl",name:"WGSL",import:(()=>D(()=>import("./wgsl-Dx-B1_4e.js"),[]))},{id:"wikitext",name:"Wikitext",aliases:["mediawiki","wiki"],import:(()=>D(()=>import("./wikitext-BhOHFoWU.js"),[]))},{id:"wit",name:"WebAssembly Interface Types",import:(()=>D(()=>import("./wit-5i3qLPDT.js"),[]))},{id:"wolfram",name:"Wolfram",aliases:["wl"],import:(()=>D(()=>import("./wolfram-lXgVvXCa.js"),[]))},{id:"xml",name:"XML",import:(()=>D(()=>import("./xml-sdJ4AIDG.js"),__vite__mapDeps([7,8])))},{id:"xsl",name:"XSL",import:(()=>D(()=>import("./xsl-CtQFsRM5.js"),__vite__mapDeps([100,7,8])))},{id:"yaml",name:"YAML",aliases:["yml"],import:(()=>D(()=>import("./yaml-Buea-lGh.js"),[]))},{id:"zenscript",name:"ZenScript",import:(()=>D(()=>import("./zenscript-DVFEvuxE.js"),[]))},{id:"zig",name:"Zig",import:(()=>D(()=>import("./zig-VOosw3JB.js"),[]))}],YP=Object.fromEntries(r_.map(e=>[e.id,e.import])),JP=Object.fromEntries(r_.flatMap(e=>{var t;return((t=e.aliases)==null?void 0:t.map(n=>[n,e.import]))||[]})),pg={...YP,...JP},ZP=[{id:"andromeeda",displayName:"Andromeeda",type:"dark",import:(()=>D(()=>import("./andromeeda-C4gqWexZ.js"),[]))},{id:"aurora-x",displayName:"Aurora X",type:"dark",import:(()=>D(()=>import("./aurora-x-D-2ljcwZ.js"),[]))},{id:"ayu-dark",displayName:"Ayu Dark",type:"dark",import:(()=>D(()=>import("./ayu-dark-DYE7WIF3.js"),[]))},{id:"ayu-light",displayName:"Ayu Light",type:"light",import:(()=>D(()=>import("./ayu-light-BA47KaF1.js"),[]))},{id:"ayu-mirage",displayName:"Ayu Mirage",type:"dark",import:(()=>D(()=>import("./ayu-mirage-32ctXXKs.js"),[]))},{id:"catppuccin-frappe",displayName:"Catppuccin Frappé",type:"dark",import:(()=>D(()=>import("./catppuccin-frappe-DFWUc33u.js"),[]))},{id:"catppuccin-latte",displayName:"Catppuccin Latte",type:"light",import:(()=>D(()=>import("./catppuccin-latte-C9dUb6Cb.js"),[]))},{id:"catppuccin-macchiato",displayName:"Catppuccin Macchiato",type:"dark",import:(()=>D(()=>import("./catppuccin-macchiato-DQyhUUbL.js"),[]))},{id:"catppuccin-mocha",displayName:"Catppuccin Mocha",type:"dark",import:(()=>D(()=>import("./catppuccin-mocha-D87Tk5Gz.js"),[]))},{id:"dark-plus",displayName:"Dark Plus",type:"dark",import:(()=>D(()=>import("./dark-plus-C3mMm8J8.js"),[]))},{id:"dracula",displayName:"Dracula Theme",type:"dark",import:(()=>D(()=>import("./dracula-BzJJZx-M.js"),[]))},{id:"dracula-soft",displayName:"Dracula Theme Soft",type:"dark",import:(()=>D(()=>import("./dracula-soft-BXkSAIEj.js"),[]))},{id:"everforest-dark",displayName:"Everforest Dark",type:"dark",import:(()=>D(()=>import("./everforest-dark-BgDCqdQA.js"),[]))},{id:"everforest-light",displayName:"Everforest Light",type:"light",import:(()=>D(()=>import("./everforest-light-C8M2exoo.js"),[]))},{id:"github-dark",displayName:"GitHub Dark",type:"dark",import:(()=>D(()=>import("./github-dark-DHJKELXO.js"),[]))},{id:"github-dark-default",displayName:"GitHub Dark Default",type:"dark",import:(()=>D(()=>import("./github-dark-default-Cuk6v7N8.js"),[]))},{id:"github-dark-dimmed",displayName:"GitHub Dark Dimmed",type:"dark",import:(()=>D(()=>import("./github-dark-dimmed-DH5Ifo-i.js"),[]))},{id:"github-dark-high-contrast",displayName:"GitHub Dark High Contrast",type:"dark",import:(()=>D(()=>import("./github-dark-high-contrast-E3gJ1_iC.js"),[]))},{id:"github-light",displayName:"GitHub Light",type:"light",import:(()=>D(()=>import("./github-light-DAi9KRSo.js"),[]))},{id:"github-light-default",displayName:"GitHub Light Default",type:"light",import:(()=>D(()=>import("./github-light-default-D7oLnXFd.js"),[]))},{id:"github-light-high-contrast",displayName:"GitHub Light High Contrast",type:"light",import:(()=>D(()=>import("./github-light-high-contrast-BfjtVDDH.js"),[]))},{id:"gruvbox-dark-hard",displayName:"Gruvbox Dark Hard",type:"dark",import:(()=>D(()=>import("./gruvbox-dark-hard-CFHQjOhq.js"),[]))},{id:"gruvbox-dark-medium",displayName:"Gruvbox Dark Medium",type:"dark",import:(()=>D(()=>import("./gruvbox-dark-medium-GsRaNv29.js"),[]))},{id:"gruvbox-dark-soft",displayName:"Gruvbox Dark Soft",type:"dark",import:(()=>D(()=>import("./gruvbox-dark-soft-CVdnzihN.js"),[]))},{id:"gruvbox-light-hard",displayName:"Gruvbox Light Hard",type:"light",import:(()=>D(()=>import("./gruvbox-light-hard-CH1njM8p.js"),[]))},{id:"gruvbox-light-medium",displayName:"Gruvbox Light Medium",type:"light",import:(()=>D(()=>import("./gruvbox-light-medium-DRw_LuNl.js"),[]))},{id:"gruvbox-light-soft",displayName:"Gruvbox Light Soft",type:"light",import:(()=>D(()=>import("./gruvbox-light-soft-hJgmCMqR.js"),[]))},{id:"horizon",displayName:"Horizon",type:"dark",import:(()=>D(()=>import("./horizon-BUw7H-hv.js"),[]))},{id:"horizon-bright",displayName:"Horizon Bright",type:"dark",import:(()=>D(()=>import("./horizon-bright-Cn-bp-IR.js"),[]))},{id:"houston",displayName:"Houston",type:"dark",import:(()=>D(()=>import("./houston-DnULxvSX.js"),[]))},{id:"kanagawa-dragon",displayName:"Kanagawa Dragon",type:"dark",import:(()=>D(()=>import("./kanagawa-dragon-CkXjmgJE.js"),[]))},{id:"kanagawa-lotus",displayName:"Kanagawa Lotus",type:"light",import:(()=>D(()=>import("./kanagawa-lotus-CfQXZHmo.js"),[]))},{id:"kanagawa-wave",displayName:"Kanagawa Wave",type:"dark",import:(()=>D(()=>import("./kanagawa-wave-DWedfzmr.js"),[]))},{id:"laserwave",displayName:"LaserWave",type:"dark",import:(()=>D(()=>import("./laserwave-DUszq2jm.js"),[]))},{id:"light-plus",displayName:"Light Plus",type:"light",import:(()=>D(()=>import("./light-plus-B7mTdjB0.js"),[]))},{id:"material-theme",displayName:"Material Theme",type:"dark",import:(()=>D(()=>import("./material-theme-D5KoaKCx.js"),[]))},{id:"material-theme-darker",displayName:"Material Theme Darker",type:"dark",import:(()=>D(()=>import("./material-theme-darker-BfHTSMKl.js"),[]))},{id:"material-theme-lighter",displayName:"Material Theme Lighter",type:"light",import:(()=>D(()=>import("./material-theme-lighter-B0m2ddpp.js"),[]))},{id:"material-theme-ocean",displayName:"Material Theme Ocean",type:"dark",import:(()=>D(()=>import("./material-theme-ocean-CyktbL80.js"),[]))},{id:"material-theme-palenight",displayName:"Material Theme Palenight",type:"dark",import:(()=>D(()=>import("./material-theme-palenight-Csfq5Kiy.js"),[]))},{id:"min-dark",displayName:"Min Dark",type:"dark",import:(()=>D(()=>import("./min-dark-CafNBF8u.js"),[]))},{id:"min-light",displayName:"Min Light",type:"light",import:(()=>D(()=>import("./min-light-CTRr51gU.js"),[]))},{id:"monokai",displayName:"Monokai",type:"dark",import:(()=>D(()=>import("./monokai-D4h5O-jR.js"),[]))},{id:"night-owl",displayName:"Night Owl",type:"dark",import:(()=>D(()=>import("./night-owl-C39BiMTA.js"),[]))},{id:"night-owl-light",displayName:"Night Owl Light",type:"light",import:(()=>D(()=>import("./night-owl-light-CMTm3GFP.js"),[]))},{id:"nord",displayName:"Nord",type:"dark",import:(()=>D(()=>import("./nord-Ddv68eIx.js"),[]))},{id:"one-dark-pro",displayName:"One Dark Pro",type:"dark",import:(()=>D(()=>import("./one-dark-pro-DVMEJ2y_.js"),[]))},{id:"one-light",displayName:"One Light",type:"light",import:(()=>D(()=>import("./one-light-C3Wv6jpd.js"),[]))},{id:"plastic",displayName:"Plastic",type:"dark",import:(()=>D(()=>import("./plastic-3e1v2bzS.js"),[]))},{id:"poimandres",displayName:"Poimandres",type:"dark",import:(()=>D(()=>import("./poimandres-CS3Unz2-.js"),[]))},{id:"red",displayName:"Red",type:"dark",import:(()=>D(()=>import("./red-bN70gL4F.js"),[]))},{id:"rose-pine",displayName:"Rosé Pine",type:"dark",import:(()=>D(()=>import("./rose-pine-qdsjHGoJ.js"),[]))},{id:"rose-pine-dawn",displayName:"Rosé Pine Dawn",type:"light",import:(()=>D(()=>import("./rose-pine-dawn-DHQR4-dF.js"),[]))},{id:"rose-pine-moon",displayName:"Rosé Pine Moon",type:"dark",import:(()=>D(()=>import("./rose-pine-moon-D4_iv3hh.js"),[]))},{id:"slack-dark",displayName:"Slack Dark",type:"dark",import:(()=>D(()=>import("./slack-dark-BthQWCQV.js"),[]))},{id:"slack-ochin",displayName:"Slack Ochin",type:"light",import:(()=>D(()=>import("./slack-ochin-DqwNpetd.js"),[]))},{id:"snazzy-light",displayName:"Snazzy Light",type:"light",import:(()=>D(()=>import("./snazzy-light-Bw305WKR.js"),[]))},{id:"solarized-dark",displayName:"Solarized Dark",type:"dark",import:(()=>D(()=>import("./solarized-dark-DXbdFlpD.js"),[]))},{id:"solarized-light",displayName:"Solarized Light",type:"light",import:(()=>D(()=>import("./solarized-light-L9t79GZl.js"),[]))},{id:"synthwave-84",displayName:"Synthwave '84",type:"dark",import:(()=>D(()=>import("./synthwave-84-CbfX1IO0.js"),[]))},{id:"tokyo-night",displayName:"Tokyo Night",type:"dark",import:(()=>D(()=>import("./tokyo-night-hegEt444.js"),[]))},{id:"vesper",displayName:"Vesper",type:"dark",import:(()=>D(()=>import("./vesper-DU1UobuO.js"),[]))},{id:"vitesse-black",displayName:"Vitesse Black",type:"dark",import:(()=>D(()=>import("./vitesse-black-Bkuqu6BP.js"),[]))},{id:"vitesse-dark",displayName:"Vitesse Dark",type:"dark",import:(()=>D(()=>import("./vitesse-dark-D0r3Knsf.js"),[]))},{id:"vitesse-light",displayName:"Vitesse Light",type:"light",import:(()=>D(()=>import("./vitesse-light-CVO1_9PV.js"),[]))}],i_=Object.fromEntries(ZP.map(e=>[e.id,e.import]));class L0 extends Error{constructor(t){super(t),this.name="ShikiError"}}function e8(){return 2147483648}function t8(){return typeof performance<"u"?performance.now():Date.now()}const n8=(e,t)=>e+(t-e%t)%t;async function r8(e){let t,n;const r={};function i(y){n=y,r.HEAPU8=new Uint8Array(y),r.HEAPU32=new Uint32Array(y)}function s(y,w,_){r.HEAPU8.copyWithin(y,w,w+_)}function l(y){try{return t.grow(y-n.byteLength+65535>>>16),i(t.buffer),1}catch{}}function c(y){const w=r.HEAPU8.length;y=y>>>0;const _=e8();if(y>_)return!1;for(let C=1;C<=4;C*=2){let I=w*(1+.2/C);I=Math.min(I,y+100663296);const E=Math.min(_,n8(Math.max(y,I),65536));if(l(E))return!0}return!1}const d=typeof TextDecoder<"u"?new TextDecoder("utf8"):void 0;function f(y,w,_=1024){const C=w+_;let I=w;for(;y[I]&&!(I>=C);)++I;if(I-w>16&&y.buffer&&d)return d.decode(y.subarray(w,I));let E="";for(;w<I;){let S=y[w++];if(!(S&128)){E+=String.fromCharCode(S);continue}const L=y[w++]&63;if((S&224)===192){E+=String.fromCharCode((S&31)<<6|L);continue}const A=y[w++]&63;if((S&240)===224?S=(S&15)<<12|L<<6|A:S=(S&7)<<18|L<<12|A<<6|y[w++]&63,S<65536)E+=String.fromCharCode(S);else{const R=S-65536;E+=String.fromCharCode(55296|R>>10,56320|R&1023)}}return E}function m(y,w){return y?f(r.HEAPU8,y,w):""}const h={emscripten_get_now:t8,emscripten_memcpy_big:s,emscripten_resize_heap:c,fd_write:()=>0};async function g(){const w=await e({env:h,wasi_snapshot_preview1:h});t=w.memory,i(t.buffer),Object.assign(r,w),r.UTF8ToString=m}return await g(),r}var i8=Object.defineProperty,o8=(e,t,n)=>t in e?i8(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nn=(e,t,n)=>o8(e,typeof t!="symbol"?t+"":t,n);let hn=null;function s8(e){throw new L0(e.UTF8ToString(e.getLastOnigError()))}class uh{constructor(t){nn(this,"utf16Length"),nn(this,"utf8Length"),nn(this,"utf16Value"),nn(this,"utf8Value"),nn(this,"utf16OffsetToUtf8"),nn(this,"utf8OffsetToUtf16");const n=t.length,r=uh._utf8ByteLength(t),i=r!==n,s=i?new Uint32Array(n+1):null;i&&(s[n]=r);const l=i?new Uint32Array(r+1):null;i&&(l[r]=n);const c=new Uint8Array(r);let d=0;for(let f=0;f<n;f++){const m=t.charCodeAt(f);let h=m,g=!1;if(m>=55296&&m<=56319&&f+1<n){const y=t.charCodeAt(f+1);y>=56320&&y<=57343&&(h=(m-55296<<10)+65536|y-56320,g=!0)}i&&(s[f]=d,g&&(s[f+1]=d),h<=127?l[d+0]=f:h<=2047?(l[d+0]=f,l[d+1]=f):h<=65535?(l[d+0]=f,l[d+1]=f,l[d+2]=f):(l[d+0]=f,l[d+1]=f,l[d+2]=f,l[d+3]=f)),h<=127?c[d++]=h:h<=2047?(c[d++]=192|(h&1984)>>>6,c[d++]=128|(h&63)>>>0):h<=65535?(c[d++]=224|(h&61440)>>>12,c[d++]=128|(h&4032)>>>6,c[d++]=128|(h&63)>>>0):(c[d++]=240|(h&1835008)>>>18,c[d++]=128|(h&258048)>>>12,c[d++]=128|(h&4032)>>>6,c[d++]=128|(h&63)>>>0),g&&f++}this.utf16Length=n,this.utf8Length=r,this.utf16Value=t,this.utf8Value=c,this.utf16OffsetToUtf8=s,this.utf8OffsetToUtf16=l}static _utf8ByteLength(t){let n=0;for(let r=0,i=t.length;r<i;r++){const s=t.charCodeAt(r);let l=s,c=!1;if(s>=55296&&s<=56319&&r+1<i){const d=t.charCodeAt(r+1);d>=56320&&d<=57343&&(l=(s-55296<<10)+65536|d-56320,c=!0)}l<=127?n+=1:l<=2047?n+=2:l<=65535?n+=3:n+=4,c&&r++}return n}createString(t){const n=t.omalloc(this.utf8Length);return t.HEAPU8.set(this.utf8Value,n),n}}const dh=class Ei{constructor(t){if(nn(this,"id",++Ei.LAST_ID),nn(this,"_onigBinding"),nn(this,"content"),nn(this,"utf16Length"),nn(this,"utf8Length"),nn(this,"utf16OffsetToUtf8"),nn(this,"utf8OffsetToUtf16"),nn(this,"ptr"),!hn)throw new L0("Must invoke loadWasm first.");this._onigBinding=hn,this.content=t;const n=new uh(t);this.utf16Length=n.utf16Length,this.utf8Length=n.utf8Length,this.utf16OffsetToUtf8=n.utf16OffsetToUtf8,this.utf8OffsetToUtf16=n.utf8OffsetToUtf16,this.utf8Length<1e4&&!Ei._sharedPtrInUse?(Ei._sharedPtr||(Ei._sharedPtr=hn.omalloc(1e4)),Ei._sharedPtrInUse=!0,hn.HEAPU8.set(n.utf8Value,Ei._sharedPtr),this.ptr=Ei._sharedPtr):this.ptr=n.createString(hn)}convertUtf8OffsetToUtf16(t){return this.utf8OffsetToUtf16?t<0?0:t>this.utf8Length?this.utf16Length:this.utf8OffsetToUtf16[t]:t}convertUtf16OffsetToUtf8(t){return this.utf16OffsetToUtf8?t<0?0:t>this.utf16Length?this.utf8Length:this.utf16OffsetToUtf8[t]:t}dispose(){this.ptr===Ei._sharedPtr?Ei._sharedPtrInUse=!1:this._onigBinding.ofree(this.ptr)}};nn(dh,"LAST_ID",0);nn(dh,"_sharedPtr",0);nn(dh,"_sharedPtrInUse",!1);let o_=dh;class a8{constructor(t){if(nn(this,"_onigBinding"),nn(this,"_ptr"),!hn)throw new L0("Must invoke loadWasm first.");const n=[],r=[];for(let c=0,d=t.length;c<d;c++){const f=new uh(t[c]);n[c]=f.createString(hn),r[c]=f.utf8Length}const i=hn.omalloc(4*t.length);hn.HEAPU32.set(n,i/4);const s=hn.omalloc(4*t.length);hn.HEAPU32.set(r,s/4);const l=hn.createOnigScanner(i,s,t.length);for(let c=0,d=t.length;c<d;c++)hn.ofree(n[c]);hn.ofree(s),hn.ofree(i),l===0&&s8(hn),this._onigBinding=hn,this._ptr=l}dispose(){this._onigBinding.freeOnigScanner(this._ptr)}findNextMatchSync(t,n,r){let i=0;if(typeof r=="number"&&(i=r),typeof t=="string"){t=new o_(t);const s=this._findNextMatchSync(t,n,!1,i);return t.dispose(),s}return this._findNextMatchSync(t,n,!1,i)}_findNextMatchSync(t,n,r,i){const s=this._onigBinding,l=s.findNextOnigScannerMatch(this._ptr,t.id,t.ptr,t.utf8Length,t.convertUtf16OffsetToUtf8(n),i);if(l===0)return null;const c=s.HEAPU32;let d=l/4;const f=c[d++],m=c[d++],h=[];for(let g=0;g<m;g++){const y=t.convertUtf8OffsetToUtf16(c[d++]),w=t.convertUtf8OffsetToUtf16(c[d++]);h[g]={start:y,end:w,length:w-y}}return{index:f,captureIndices:h}}}function l8(e){return typeof e.instantiator=="function"}function c8(e){return typeof e.default=="function"}function u8(e){return typeof e.data<"u"}function d8(e){return typeof Response<"u"&&e instanceof Response}function f8(e){var t;return typeof ArrayBuffer<"u"&&(e instanceof ArrayBuffer||ArrayBuffer.isView(e))||typeof Buffer<"u"&&((t=Buffer.isBuffer)==null?void 0:t.call(Buffer,e))||typeof SharedArrayBuffer<"u"&&e instanceof SharedArrayBuffer||typeof Uint32Array<"u"&&e instanceof Uint32Array}let Wd;function h8(e){if(Wd)return Wd;async function t(){hn=await r8(async n=>{let r=e;return r=await r,typeof r=="function"&&(r=await r(n)),typeof r=="function"&&(r=await r(n)),l8(r)?r=await r.instantiator(n):c8(r)?r=await r.default(n):(u8(r)&&(r=r.data),d8(r)?typeof WebAssembly.instantiateStreaming=="function"?r=await p8(r)(n):r=await m8(r)(n):f8(r)?r=await vm(r)(n):r instanceof WebAssembly.Module?r=await vm(r)(n):"default"in r&&r.default instanceof WebAssembly.Module&&(r=await vm(r.default)(n))),"instance"in r&&(r=r.instance),"exports"in r&&(r=r.exports),r})}return Wd=t(),Wd}function vm(e){return t=>WebAssembly.instantiate(e,t)}function p8(e){return t=>WebAssembly.instantiateStreaming(e,t)}function m8(e){return async t=>{const n=await e.arrayBuffer();return WebAssembly.instantiate(n,t)}}async function s_(e){return e&&await h8(e),{createScanner(t){return new a8(t.map(n=>typeof n=="string"?n:n.source))},createString(t){return new o_(t)}}}const g8=QP({langs:pg,themes:i_,engine:()=>s_(D(()=>import("./wasm-CG6Dc4jp.js"),[]))});function $l(e){if([...e].length!==1)throw new Error(`Expected "${e}" to be a single code point`);return e.codePointAt(0)}function v8(e,t,n){return e.has(t)||e.set(t,n),e.get(t)}const D0=new Set(["alnum","alpha","ascii","blank","cntrl","digit","graph","lower","print","punct","space","upper","word","xdigit"]),pn=String.raw;function Bl(e,t){if(e==null)throw new Error(t??"Value expected");return e}const a_=pn`\[\^?`,l_=`c.? | C(?:-.?)?|${pn`[pP]\{(?:\^?[-\x20_]*[A-Za-z][-\x20\w]*\})?`}|${pn`x[89A-Fa-f]\p{AHex}(?:\\x[89A-Fa-f]\p{AHex})*`}|${pn`u(?:\p{AHex}{4})? | x\{[^\}]*\}? | x\p{AHex}{0,2}`}|${pn`o\{[^\}]*\}?`}|${pn`\d{1,3}`}`,A0=/[?*+][?+]?|\{(?:\d+(?:,\d*)?|,\d+)\}\??/,Gd=new RegExp(pn`
212
+ \\ (?:
213
+ ${l_}
214
+ | [gk]<[^>]*>?
215
+ | [gk]'[^']*'?
216
+ | .
217
+ )
218
+ | \( (?:
219
+ \? (?:
220
+ [:=!>({]
221
+ | <[=!]
222
+ | <[^>]*>
223
+ | '[^']*'
224
+ | ~\|?
225
+ | #(?:[^)\\]|\\.?)*
226
+ | [^:)]*[:)]
227
+ )?
228
+ | \*[^\)]*\)?
229
+ )?
230
+ | (?:${A0.source})+
231
+ | ${a_}
232
+ | .
233
+ `.replace(/\s+/g,""),"gsu"),ym=new RegExp(pn`
234
+ \\ (?:
235
+ ${l_}
236
+ | .
237
+ )
238
+ | \[:(?:\^?\p{Alpha}+|\^):\]
239
+ | ${a_}
240
+ | &&
241
+ | .
242
+ `.replace(/\s+/g,""),"gsu");function y8(e,t={}){const n={flags:"",...t,rules:{captureGroup:!1,singleline:!1,...t.rules}};if(typeof e!="string")throw new Error("String expected as pattern");const r=O8(n.flags),i=[r.extended],s={captureGroup:n.rules.captureGroup,getCurrentModX(){return i.at(-1)},numOpenGroups:0,popModX(){i.pop()},pushModX(h){i.push(h)},replaceCurrentModX(h){i[i.length-1]=h},singleline:n.rules.singleline};let l=[],c;for(Gd.lastIndex=0;c=Gd.exec(e);){const h=w8(s,e,c[0],Gd.lastIndex);h.tokens?l.push(...h.tokens):h.token&&l.push(h.token),h.lastIndex!==void 0&&(Gd.lastIndex=h.lastIndex)}const d=[];let f=0;l.filter(h=>h.type==="GroupOpen").forEach(h=>{h.kind==="capturing"?h.number=++f:h.raw==="("&&d.push(h)}),f||d.forEach((h,g)=>{h.kind="capturing",h.number=g+1});const m=f||d.length;return{tokens:l.map(h=>h.type==="EscapedNumber"?B8(h,m):h).flat(),flags:r}}function w8(e,t,n,r){const[i,s]=n;if(n==="["||n==="[^"){const l=b8(t,n,r);return{tokens:l.tokens,lastIndex:l.lastIndex}}if(i==="\\"){if("AbBGyYzZ".includes(s))return{token:xy(n,n)};if(/^\\g[<']/.test(n)){if(!/^\\g(?:<[^>]+>|'[^']+')$/.test(n))throw new Error(`Invalid group name "${n}"`);return{token:D8(n)}}if(/^\\k[<']/.test(n)){if(!/^\\k(?:<[^>]+>|'[^']+')$/.test(n))throw new Error(`Invalid group name "${n}"`);return{token:u_(n)}}if(s==="K")return{token:d_("keep",n)};if(s==="N"||s==="R")return{token:Qs("newline",n,{negate:s==="N"})};if(s==="O")return{token:Qs("any",n)};if(s==="X")return{token:Qs("text_segment",n)};const l=c_(n,{inCharClass:!1});return Array.isArray(l)?{tokens:l}:{token:l}}if(i==="("){if(s==="*")return{token:N8(n)};if(n==="(?{")throw new Error(`Unsupported callout "${n}"`);if(n.startsWith("(?#")){if(t[r]!==")")throw new Error('Unclosed comment group "(?#"');return{lastIndex:r+1}}if(/^\(\?[-imx]+[:)]$/.test(n))return{token:R8(n,e)};if(e.pushModX(e.getCurrentModX()),e.numOpenGroups++,n==="("&&!e.captureGroup||n==="(?:")return{token:el("group",n)};if(n==="(?>")return{token:el("atomic",n)};if(n==="(?="||n==="(?!"||n==="(?<="||n==="(?<!")return{token:el(n[2]==="<"?"lookbehind":"lookahead",n,{negate:n.endsWith("!")})};if(n==="("&&e.captureGroup||n.startsWith("(?<")&&n.endsWith(">")||n.startsWith("(?'")&&n.endsWith("'"))return{token:el("capturing",n,{...n!=="("&&{name:n.slice(3,-1)}})};if(n.startsWith("(?~")){if(n==="(?~|")throw new Error(`Unsupported absence function kind "${n}"`);return{token:el("absence_repeater",n)}}throw n==="(?("?new Error(`Unsupported conditional "${n}"`):new Error(`Invalid or unsupported group option "${n}"`)}if(n===")"){if(e.popModX(),e.numOpenGroups--,e.numOpenGroups<0)throw new Error('Unmatched ")"');return{token:I8(n)}}if(e.getCurrentModX()){if(n==="#"){const l=t.indexOf(`
243
+ `,r);return{lastIndex:l===-1?t.length:l}}if(/^\s$/.test(n)){const l=/\s+/y;return l.lastIndex=r,{lastIndex:l.exec(t)?l.lastIndex:r}}}if(n===".")return{token:Qs("dot",n)};if(n==="^"||n==="$"){const l=e.singleline?{"^":pn`\A`,$:pn`\Z`}[n]:n;return{token:xy(l,n)}}return n==="|"?{token:_8(n)}:A0.test(n)?{tokens:j8(n)}:{token:yo($l(n),n)}}function b8(e,t,n){const r=[_y(t[1]==="^",t)];let i=1,s;for(ym.lastIndex=n;s=ym.exec(e);){const l=s[0];if(l[0]==="["&&l[1]!==":")i++,r.push(_y(l[1]==="^",l));else if(l==="]"){if(r.at(-1).type==="CharacterClassOpen")r.push(yo(93,l));else if(i--,r.push(k8(l)),!i)break}else{const c=x8(l);Array.isArray(c)?r.push(...c):r.push(c)}}return{tokens:r,lastIndex:ym.lastIndex||e.length}}function x8(e){if(e[0]==="\\")return c_(e,{inCharClass:!0});if(e[0]==="["){const t=/\[:(?<negate>\^?)(?<name>[a-z]+):\]/.exec(e);if(!t||!D0.has(t.groups.name))throw new Error(`Invalid POSIX class "${e}"`);return Qs("posix",e,{value:t.groups.name,negate:!!t.groups.negate})}return e==="-"?S8(e):e==="&&"?C8(e):yo($l(e),e)}function c_(e,{inCharClass:t}){const n=e[1];if(n==="c"||n==="C")return T8(e);if("dDhHsSwW".includes(n))return F8(e);if(e.startsWith(pn`\o{`))throw new Error(`Incomplete, invalid, or unsupported octal code point "${e}"`);if(/^\\[pP]\{/.test(e)){if(e.length===3)throw new Error(`Incomplete or invalid Unicode property "${e}"`);return M8(e)}if(new RegExp("^\\\\x[89A-Fa-f]\\p{AHex}","u").test(e))try{const r=e.split(/\\x/).slice(1).map(l=>parseInt(l,16)),i=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}).decode(new Uint8Array(r)),s=new TextEncoder;return[...i].map(l=>{const c=[...s.encode(l)].map(d=>`\\x${d.toString(16)}`).join("");return yo($l(l),c)})}catch{throw new Error(`Multibyte code "${e}" incomplete or invalid in Oniguruma`)}if(n==="u"||n==="x")return yo($8(e),e);if(ky.has(n))return yo(ky.get(n),e);if(/\d/.test(n))return E8(t,e);if(e==="\\")throw new Error(pn`Incomplete escape "\"`);if(n==="M")throw new Error(`Unsupported meta "${e}"`);if([...e].length===2)return yo(e.codePointAt(1),e);throw new Error(`Unexpected escape "${e}"`)}function _8(e){return{type:"Alternator",raw:e}}function xy(e,t){return{type:"Assertion",kind:e,raw:t}}function u_(e){return{type:"Backreference",raw:e}}function yo(e,t){return{type:"Character",value:e,raw:t}}function k8(e){return{type:"CharacterClassClose",raw:e}}function S8(e){return{type:"CharacterClassHyphen",raw:e}}function C8(e){return{type:"CharacterClassIntersector",raw:e}}function _y(e,t){return{type:"CharacterClassOpen",negate:e,raw:t}}function Qs(e,t,n={}){return{type:"CharacterSet",kind:e,...n,raw:t}}function d_(e,t,n={}){return e==="keep"?{type:"Directive",kind:e,raw:t}:{type:"Directive",kind:e,flags:Bl(n.flags),raw:t}}function E8(e,t){return{type:"EscapedNumber",inCharClass:e,raw:t}}function I8(e){return{type:"GroupClose",raw:e}}function el(e,t,n={}){return{type:"GroupOpen",kind:e,...n,raw:t}}function P8(e,t,n,r){return{type:"NamedCallout",kind:e,tag:t,arguments:n,raw:r}}function L8(e,t,n,r){return{type:"Quantifier",kind:e,min:t,max:n,raw:r}}function D8(e){return{type:"Subroutine",raw:e}}const A8=new Set(["COUNT","CMP","ERROR","FAIL","MAX","MISMATCH","SKIP","TOTAL_COUNT"]),ky=new Map([["a",7],["b",8],["e",27],["f",12],["n",10],["r",13],["t",9],["v",11]]);function T8(e){const t=e[1]==="c"?e[2]:e[3];if(!t||!/[A-Za-z]/.test(t))throw new Error(`Unsupported control character "${e}"`);return yo($l(t.toUpperCase())-64,e)}function R8(e,t){let{on:n,off:r}=/^\(\?(?<on>[imx]*)(?:-(?<off>[-imx]*))?/.exec(e).groups;r??(r="");const i=(t.getCurrentModX()||n.includes("x"))&&!r.includes("x"),s=Cy(n),l=Cy(r),c={};if(s&&(c.enable=s),l&&(c.disable=l),e.endsWith(")"))return t.replaceCurrentModX(i),d_("flags",e,{flags:c});if(e.endsWith(":"))return t.pushModX(i),t.numOpenGroups++,el("group",e,{...(s||l)&&{flags:c}});throw new Error(`Unexpected flag modifier "${e}"`)}function N8(e){const t=/\(\*(?<name>[A-Za-z_]\w*)?(?:\[(?<tag>(?:[A-Za-z_]\w*)?)\])?(?:\{(?<args>[^}]*)\})?\)/.exec(e);if(!t)throw new Error(`Incomplete or invalid named callout "${e}"`);const{name:n,tag:r,args:i}=t.groups;if(!n)throw new Error(`Invalid named callout "${e}"`);if(r==="")throw new Error(`Named callout tag with empty value not allowed "${e}"`);const s=i?i.split(",").filter(m=>m!=="").map(m=>/^[+-]?\d+$/.test(m)?+m:m):[],[l,c,d]=s,f=A8.has(n)?n.toLowerCase():"custom";switch(f){case"fail":case"mismatch":case"skip":if(s.length>0)throw new Error(`Named callout arguments not allowed "${s}"`);break;case"error":if(s.length>1)throw new Error(`Named callout allows only one argument "${s}"`);if(typeof l=="string")throw new Error(`Named callout argument must be a number "${l}"`);break;case"max":if(!s.length||s.length>2)throw new Error(`Named callout must have one or two arguments "${s}"`);if(typeof l=="string"&&!/^[A-Za-z_]\w*$/.test(l))throw new Error(`Named callout argument one must be a tag or number "${l}"`);if(s.length===2&&(typeof c=="number"||!/^[<>X]$/.test(c)))throw new Error(`Named callout optional argument two must be '<', '>', or 'X' "${c}"`);break;case"count":case"total_count":if(s.length>1)throw new Error(`Named callout allows only one argument "${s}"`);if(s.length===1&&(typeof l=="number"||!/^[<>X]$/.test(l)))throw new Error(`Named callout optional argument must be '<', '>', or 'X' "${l}"`);break;case"cmp":if(s.length!==3)throw new Error(`Named callout must have three arguments "${s}"`);if(typeof l=="string"&&!/^[A-Za-z_]\w*$/.test(l))throw new Error(`Named callout argument one must be a tag or number "${l}"`);if(typeof c=="number"||!/^(?:[<>!=]=|[<>])$/.test(c))throw new Error(`Named callout argument two must be '==', '!=', '>', '<', '>=', or '<=' "${c}"`);if(typeof d=="string"&&!/^[A-Za-z_]\w*$/.test(d))throw new Error(`Named callout argument three must be a tag or number "${d}"`);break;case"custom":throw new Error(`Undefined callout name "${n}"`);default:throw new Error(`Unexpected named callout kind "${f}"`)}return P8(f,r??null,(i==null?void 0:i.split(","))??null,e)}function Sy(e){let t=null,n,r;if(e[0]==="{"){const{minStr:i,maxStr:s}=/^\{(?<minStr>\d*)(?:,(?<maxStr>\d*))?/.exec(e).groups,l=1e5;if(+i>l||s&&+s>l)throw new Error("Quantifier value unsupported in Oniguruma");if(n=+i,r=s===void 0?+i:s===""?1/0:+s,n>r&&(t="possessive",[n,r]=[r,n]),e.endsWith("?")){if(t==="possessive")throw new Error('Unsupported possessive interval quantifier chain with "?"');t="lazy"}else t||(t="greedy")}else n=e[0]==="+"?1:0,r=e[0]==="?"?1:1/0,t=e[1]==="+"?"possessive":e[1]==="?"?"lazy":"greedy";return L8(t,n,r,e)}function F8(e){const t=e[1].toLowerCase();return Qs({d:"digit",h:"hex",s:"space",w:"word"}[t],e,{negate:e[1]!==t})}function M8(e){const{p:t,neg:n,value:r}=/^\\(?<p>[pP])\{(?<neg>\^?)(?<value>[^}]+)/.exec(e).groups;return Qs("property",e,{value:r,negate:t==="P"&&!n||t==="p"&&!!n})}function Cy(e){const 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 O8(e){const 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++){const r=e[n];if(!"imxDPSWy".includes(r))throw new Error(`Invalid flag "${r}"`);if(r==="y"){if(!/^y{[gw]}/.test(e.slice(n)))throw new 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 $8(e){if(new RegExp("^(?:\\\\u(?!\\p{AHex}{4})|\\\\x(?!\\p{AHex}{1,2}|\\{\\p{AHex}{1,8}\\}))","u").test(e))throw new Error(`Incomplete or invalid escape "${e}"`);const t=e[2]==="{"?new RegExp("^\\\\x\\{\\s*(?<hex>\\p{AHex}+)","u").exec(e).groups.hex:e.slice(2);return parseInt(t,16)}function B8(e,t){const{raw:n,inCharClass:r}=e,i=n.slice(1);if(!r&&(i!=="0"&&i.length===1||i[0]!=="0"&&+i<=t))return[u_(n)];const s=[],l=i.match(/^[0-7]+|\d/g);for(let c=0;c<l.length;c++){const d=l[c];let f;if(c===0&&d!=="8"&&d!=="9"){if(f=parseInt(d,8),f>127)throw new Error(pn`Octal encoded byte above 177 unsupported "${n}"`)}else f=$l(d);s.push(yo(f,(c===0?"\\":"")+d))}return s}function j8(e){const t=[],n=new RegExp(A0,"gy");let r;for(;r=n.exec(e);){const i=r[0];if(i[0]==="{"){const s=/^\{(?<min>\d+),(?<max>\d+)\}\??$/.exec(i);if(s){const{min:l,max:c}=s.groups;if(+l>+c&&i.endsWith("?")){n.lastIndex--,t.push(Sy(i.slice(0,-1)));continue}}}t.push(Sy(i))}return t}function f_(e,t){if(!Array.isArray(e.body))throw new Error("Expected node with body array");if(e.body.length!==1)return!1;const n=e.body[0];return!t||Object.keys(t).every(r=>t[r]===n[r])}function V8(e){return U8.has(e.type)}const U8=new Set(["AbsenceFunction","Backreference","CapturingGroup","Character","CharacterClass","CharacterSet","Group","Quantifier","Subroutine"]);function h_(e,t={}){const n={flags:"",normalizeUnknownPropertyNames:!1,skipBackrefValidation:!1,skipLookbehindValidation:!1,skipPropertyNameValidation:!1,unicodePropertyMap:null,...t,rules:{captureGroup:!1,singleline:!1,...t.rules}},r=y8(e,{flags:n.flags,rules:{captureGroup:n.rules.captureGroup,singleline:n.rules.singleline}}),i=(g,y)=>{const w=r.tokens[s.nextIndex];switch(s.parent=g,s.nextIndex++,w.type){case"Alternator":return sa();case"Assertion":return z8(w);case"Backreference":return H8(w,s);case"Character":return fh(w.value,{useLastValid:!!y.isCheckingRangeEnd});case"CharacterClassHyphen":return W8(w,s,y);case"CharacterClassOpen":return G8(w,s,y);case"CharacterSet":return q8(w,s);case"Directive":return Z8(w.kind,{flags:w.flags});case"GroupOpen":return K8(w,s,y);case"NamedCallout":return t6(w.kind,w.tag,w.arguments);case"Quantifier":return X8(w,s);case"Subroutine":return Q8(w,s);default:throw new Error(`Unexpected token type "${w.type}"`)}},s={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},l=r6(e6(r.flags));let c=l.body[0];for(;s.nextIndex<r.tokens.length;){const g=i(c,{});g.type==="Alternative"?(l.body.push(g),c=g):c.body.push(g)}const{capturingGroups:d,hasNumberedRef:f,namedGroupsByName:m,subroutines:h}=s;if(f&&m.size&&!n.rules.captureGroup)throw new Error("Numbered backref/subroutine not allowed when using named capture");for(const{ref:g}of h)if(typeof g=="number"){if(g>d.length)throw new Error("Subroutine uses a group number that's not defined");g&&(d[g-1].isSubroutined=!0)}else if(m.has(g)){if(m.get(g).length>1)throw new Error(pn`Subroutine uses a duplicate group name "\g<${g}>"`);m.get(g)[0].isSubroutined=!0}else throw new Error(pn`Subroutine uses a group name that's not defined "\g<${g}>"`);return l}function z8({kind:e}){return mg(Bl({"^":"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===pn`\B`||e===pn`\Y`})}function H8({raw:e},t){const n=/^\\k[<']/.test(e),r=n?e.slice(3,-1):e.slice(1),i=(s,l=!1)=>{const c=t.capturingGroups.length;let d=!1;if(s>c)if(t.skipBackrefValidation)d=!0;else throw new Error(`Not enough capturing groups defined to the left "${e}"`);return t.hasNumberedRef=!0,gg(l?c+1-s:s,{orphan:d})};if(n){const s=/^(?<sign>-?)0*(?<num>[1-9]\d*)$/.exec(r);if(s)return i(+s.groups.num,!!s.groups.sign);if(/[-+]/.test(r))throw new Error(`Invalid backref name "${e}"`);if(!t.namedGroupsByName.has(r))throw new Error(`Group name not defined to the left "${e}"`);return gg(r)}return i(+r)}function W8(e,t,n){const{tokens:r,walk:i}=t,s=t.parent,l=s.body.at(-1),c=r[t.nextIndex];if(!n.isCheckingRangeEnd&&l&&l.type!=="CharacterClass"&&l.type!=="CharacterClassRange"&&c&&c.type!=="CharacterClassOpen"&&c.type!=="CharacterClassClose"&&c.type!=="CharacterClassIntersector"){const d=i(s,{...n,isCheckingRangeEnd:!0});if(l.type==="Character"&&d.type==="Character")return s.body.pop(),J8(l,d);throw new Error("Invalid character class range")}return fh($l("-"))}function G8({negate:e},t,n){const{tokens:r,walk:i}=t,s=[pf()],l=r[t.nextIndex];let c=Py(l);for(;c.type!=="CharacterClassClose";){if(c.type==="CharacterClassIntersector")s.push(pf()),t.nextIndex++;else{const f=s.at(-1);f.body.push(i(f,n))}c=Py(r[t.nextIndex],l)}const d=pf({negate:e});return s.length===1?d.body=s[0].body:(d.kind="intersection",d.body=s.map(f=>f.body.length===1?f.body[0]:f)),t.nextIndex++,d}function q8({kind:e,negate:t,value:n},r){const{normalizeUnknownPropertyNames:i,skipPropertyNameValidation:s,unicodePropertyMap:l}=r;if(e==="property"){const c=hh(n);if(D0.has(c)&&!(l!=null&&l.has(c)))e="posix",n=c;else return tl(n,{negate:t,normalizeUnknownPropertyNames:i,skipPropertyNameValidation:s,unicodePropertyMap:l})}return e==="posix"?n6(n,{negate:t}):vg(e,{negate:t})}function K8(e,t,n){const{tokens:r,capturingGroups:i,namedGroupsByName:s,skipLookbehindValidation:l,walk:c}=t,d=i6(e),f=d.type==="AbsenceFunction",m=Iy(d),h=m&&d.negate;if(d.type==="CapturingGroup"&&(i.push(d),d.name&&v8(s,d.name,[]).push(d)),f&&n.isInAbsenceFunction)throw new Error("Nested absence function not supported by Oniguruma");let g=Ly(r[t.nextIndex]);for(;g.type!=="GroupClose";){if(g.type==="Alternator")d.body.push(sa()),t.nextIndex++;else{const y=d.body.at(-1),w=c(y,{...n,isInAbsenceFunction:n.isInAbsenceFunction||f,isInLookbehind:n.isInLookbehind||m,isInNegLookbehind:n.isInNegLookbehind||h});if(y.body.push(w),(m||n.isInLookbehind)&&!l){const _="Lookbehind includes a pattern not allowed by Oniguruma";if(h||n.isInNegLookbehind){if(Ey(w)||w.type==="CapturingGroup")throw new Error(_)}else if(Ey(w)||Iy(w)&&w.negate)throw new Error(_)}}g=Ly(r[t.nextIndex])}return t.nextIndex++,d}function X8({kind:e,min:t,max:n},r){const i=r.parent,s=i.body.at(-1);if(!s||!V8(s))throw new Error("Quantifier requires a repeatable token");const l=m_(e,t,n,s);return i.body.pop(),l}function Q8({raw:e},t){const{capturingGroups:n,subroutines:r}=t;let i=e.slice(3,-1);const s=/^(?<sign>[-+]?)0*(?<num>[1-9]\d*)$/.exec(i);if(s){const c=+s.groups.num,d=n.length;if(t.hasNumberedRef=!0,i={"":c,"+":d+c,"-":d+1-c}[s.groups.sign],i<1)throw new Error("Invalid subroutine number")}else i==="0"&&(i=0);const l=g_(i);return r.push(l),l}function Y8(e,t){return{type:"AbsenceFunction",kind:e,body:Du(t==null?void 0:t.body)}}function sa(e){return{type:"Alternative",body:v_(e==null?void 0:e.body)}}function mg(e,t){const n={type:"Assertion",kind:e};return(e==="word_boundary"||e==="text_segment_boundary")&&(n.negate=!!(t!=null&&t.negate)),n}function gg(e,t){const n=!!(t!=null&&t.orphan);return{type:"Backreference",ref:e,...n&&{orphan:n}}}function p_(e,t){const n={name:void 0,isSubroutined:!1,...t};if(n.name!==void 0&&!o6(n.name))throw new Error(`Group name "${n.name}" invalid in Oniguruma`);return{type:"CapturingGroup",number:e,...n.name&&{name:n.name},...n.isSubroutined&&{isSubroutined:n.isSubroutined},body:Du(t==null?void 0:t.body)}}function fh(e,t){const n={useLastValid:!1,...t};if(e>1114111){const r=e.toString(16);if(n.useLastValid)e=1114111;else throw e>1310719?new Error(`Invalid code point out of range "\\x{${r}}"`):new Error(`Invalid code point out of range in JS "\\x{${r}}"`)}return{type:"Character",value:e}}function pf(e){const t={kind:"union",negate:!1,...e};return{type:"CharacterClass",kind:t.kind,negate:t.negate,body:v_(e==null?void 0:e.body)}}function J8(e,t){if(t.value<e.value)throw new Error("Character class range out of order");return{type:"CharacterClassRange",min:e,max:t}}function vg(e,t){const n=!!(t!=null&&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 Z8(e,t={}){if(e==="keep")return{type:"Directive",kind:e};if(e==="flags")return{type:"Directive",kind:e,flags:Bl(t.flags)};throw new Error(`Unexpected directive kind "${e}"`)}function e6(e){return{type:"Flags",...e}}function ti(e){const t=e==null?void 0:e.atomic,n=e==null?void 0:e.flags;if(t&&n)throw new Error("Atomic group cannot have flags");return{type:"Group",...t&&{atomic:t},...n&&{flags:n},body:Du(e==null?void 0:e.body)}}function qs(e){const t={behind:!1,negate:!1,...e};return{type:"LookaroundAssertion",kind:t.behind?"lookbehind":"lookahead",negate:t.negate,body:Du(e==null?void 0:e.body)}}function t6(e,t,n){return{type:"NamedCallout",kind:e,tag:t,arguments:n}}function n6(e,t){const n=!!(t!=null&&t.negate);if(!D0.has(e))throw new Error(`Invalid POSIX class "${e}"`);return{type:"CharacterSet",kind:"posix",value:e,negate:n}}function m_(e,t,n,r){if(t>n)throw new Error("Invalid reversed quantifier range");return{type:"Quantifier",kind:e,min:t,max:n,body:r}}function r6(e,t){return{type:"Regex",body:Du(t==null?void 0:t.body),flags:e}}function g_(e){return{type:"Subroutine",ref:e}}function tl(e,t){var i;const n={negate:!1,normalizeUnknownPropertyNames:!1,skipPropertyNameValidation:!1,unicodePropertyMap:null,...t};let r=(i=n.unicodePropertyMap)==null?void 0:i.get(hh(e));if(!r){if(n.normalizeUnknownPropertyNames)r=s6(e);else if(n.unicodePropertyMap&&!n.skipPropertyNameValidation)throw new Error(pn`Invalid Unicode property "\p{${e}}"`)}return{type:"CharacterSet",kind:"property",value:r??e,negate:n.negate}}function i6({flags:e,kind:t,name:n,negate:r,number:i}){switch(t){case"absence_repeater":return Y8("repeater");case"atomic":return ti({atomic:!0});case"capturing":return p_(i,{name:n});case"group":return ti({flags:e});case"lookahead":case"lookbehind":return qs({behind:t==="lookbehind",negate:r});default:throw new Error(`Unexpected group kind "${t}"`)}}function Du(e){if(e===void 0)e=[sa()];else if(!Array.isArray(e)||!e.length||!e.every(t=>t.type==="Alternative"))throw new Error("Invalid body; expected array of one or more Alternative nodes");return e}function v_(e){if(e===void 0)e=[];else if(!Array.isArray(e)||!e.every(t=>!!t.type))throw new Error("Invalid body; expected array of nodes");return e}function Ey(e){return e.type==="LookaroundAssertion"&&e.kind==="lookahead"}function Iy(e){return e.type==="LookaroundAssertion"&&e.kind==="lookbehind"}function o6(e){return/^[\p{Alpha}\p{Pc}][^)]*$/u.test(e)}function s6(e){return e.trim().replace(/[- _]+/g,"_").replace(/[A-Z][a-z]+(?=[A-Z])/g,"$&_").replace(/[A-Za-z]+/g,t=>t[0].toUpperCase()+t.slice(1).toLowerCase())}function hh(e){return e.replace(/[- _]+/g,"").toLowerCase()}function Py(e,t){const n=t;return Bl(e,`Unclosed character class${(n==null?void 0:n.type)==="Character"&&n.value===93&&n.raw==="]"?' (started with "]")':""}`)}function Ly(e){return Bl(e,"Unclosed group")}function zc(e,t,n=null){function r(s,l){for(let c=0;c<s.length;c++){const d=i(s[c],l,c,s);c=Math.max(-1,c+d)}}function i(s,l=null,c=null,d=null){var I,E;let f=0,m=!1;const h={node:s,parent:l,key:c,container:d,root:e,remove(){qd(d).splice(Math.max(0,qa(c)+f),1),f--,m=!0},removeAllNextSiblings(){return qd(d).splice(qa(c)+1)},removeAllPrevSiblings(){const S=qa(c)+f;return f-=S,qd(d).splice(0,Math.max(0,S))},replaceWith(S,L={}){const A=!!L.traverse;d?d[Math.max(0,qa(c)+f)]=S:Bl(l,"Can't replace root node")[c]=S,A&&i(S,l,c,d),m=!0},replaceWithMultiple(S,L={}){const A=!!L.traverse;if(qd(d).splice(Math.max(0,qa(c)+f),1,...S),f+=S.length-1,A){let R=0;for(let U=0;U<S.length;U++)R+=i(S[U],l,qa(c)+U+R,d)}m=!0},skip(){m=!0}},{type:g}=s,y=t["*"],w=t[g],_=typeof y=="function"?y:y==null?void 0:y.enter,C=typeof w=="function"?w:w==null?void 0:w.enter;if(_==null||_(h,n),C==null||C(h,n),!m)switch(g){case"AbsenceFunction":case"Alternative":case"CapturingGroup":case"CharacterClass":case"Group":case"LookaroundAssertion":r(s.body,s);break;case"Assertion":case"Backreference":case"Character":case"CharacterSet":case"Directive":case"Flags":case"NamedCallout":case"Subroutine":break;case"CharacterClassRange":i(s.min,s,"min"),i(s.max,s,"max");break;case"Quantifier":i(s.body,s,"body");break;case"Regex":r(s.body,s),i(s.flags,s,"flags");break;default:throw new Error(`Unexpected node type "${g}"`)}return(I=w==null?void 0:w.exit)==null||I.call(w,h,n),(E=y==null?void 0:y.exit)==null||E.call(y,h,n),f}return i(e),e}function qd(e){if(!Array.isArray(e))throw new Error("Container expected");return e}function qa(e){if(typeof e!="number")throw new Error("Numeric key expected");return e}const a6=String.raw`\(\?(?:[:=!>A-Za-z\-]|<[=!]|\(DEFINE\))`;function l6(e,t){for(let n=0;n<e.length;n++)e[n]>=t&&e[n]++}function c6(e,t,n,r){return e.slice(0,t)+r+e.slice(t+n.length)}const Rr=Object.freeze({DEFAULT:"DEFAULT",CHAR_CLASS:"CHAR_CLASS"});function T0(e,t,n,r){const i=new RegExp(String.raw`${t}|(?<$skip>\[\^?|\\?.)`,"gsu"),s=[!1];let l=0,c="";for(const d of e.matchAll(i)){const{0:f,groups:{$skip:m}}=d;if(!m&&(!r||r===Rr.DEFAULT==!l)){n instanceof Function?c+=n(d,{context:l?Rr.CHAR_CLASS:Rr.DEFAULT,negated:s[s.length-1]}):c+=n;continue}f[0]==="["?(l++,s.push(f[1]==="^")):f==="]"&&l&&(l--,s.pop()),c+=f}return c}function y_(e,t,n,r){T0(e,t,n,r)}function u6(e,t,n=0,r){if(!new RegExp(t,"su").test(e))return null;const i=new RegExp(`${t}|(?<$skip>\\\\?.)`,"gsu");i.lastIndex=n;let s=0,l;for(;l=i.exec(e);){const{0:c,groups:{$skip:d}}=l;if(!d&&(!r||r===Rr.DEFAULT==!s))return l;c==="["?s++:c==="]"&&s&&s--,i.lastIndex==l.index&&i.lastIndex++}return null}function Kd(e,t,n){return!!u6(e,t,0,n)}function d6(e,t){const n=/\\?./gsu;n.lastIndex=t;let r=e.length,i=0,s=1,l;for(;l=n.exec(e);){const[c]=l;if(c==="[")i++;else if(i)c==="]"&&i--;else if(c==="(")s++;else if(c===")"&&(s--,!s)){r=l.index;break}}return e.slice(t,r)}const Dy=new RegExp(String.raw`(?<noncapturingStart>${a6})|(?<capturingStart>\((?:\?<[^>]+>)?)|\\?.`,"gsu");function f6(e,t){const n=(t==null?void 0:t.hiddenCaptures)??[];let r=(t==null?void 0:t.captureTransfers)??new Map;if(!/\(\?>/.test(e))return{pattern:e,captureTransfers:r,hiddenCaptures:n};const i="(?>",s="(?:(?=(",l=[0],c=[];let d=0,f=0,m=NaN,h;do{h=!1;let g=0,y=0,w=!1,_;for(Dy.lastIndex=Number.isNaN(m)?0:m+s.length;_=Dy.exec(e);){const{0:C,index:I,groups:{capturingStart:E,noncapturingStart:S}}=_;if(C==="[")g++;else if(g)C==="]"&&g--;else if(C===i&&!w)m=I,w=!0;else if(w&&S)y++;else if(E)w?y++:(d++,l.push(d+f));else if(C===")"&&w){if(!y){f++;const L=d+f;if(e=`${e.slice(0,m)}${s}${e.slice(m+i.length,I)}))<$$${L}>)${e.slice(I+1)}`,h=!0,c.push(L),l6(n,L),r.size){const A=new Map;r.forEach((R,U)=>{A.set(U>=L?U+1:U,R.map(X=>X>=L?X+1:X))}),r=A}break}y--}}}while(h);return n.push(...c),e=T0(e,String.raw`\\(?<backrefNum>[1-9]\d*)|<\$\$(?<wrappedBackrefNum>\d+)>`,({0:g,groups:{backrefNum:y,wrappedBackrefNum:w}})=>{if(y){const _=+y;if(_>l.length-1)throw new Error(`Backref "${g}" greater than number of captures`);return`\\${l[_]}`}return`\\${w}`},Rr.DEFAULT),{pattern:e,captureTransfers:r,hiddenCaptures:n}}const w_=String.raw`(?:[?*+]|\{\d+(?:,\d*)?\})`,wm=new RegExp(String.raw`
244
+ \\(?: \d+
245
+ | c[A-Za-z]
246
+ | [gk]<[^>]+>
247
+ | [pPu]\{[^\}]+\}
248
+ | u[A-Fa-f\d]{4}
249
+ | x[A-Fa-f\d]{2}
250
+ )
251
+ | \((?: \? (?: [:=!>]
252
+ | <(?:[=!]|[^>]+>)
253
+ | [A-Za-z\-]+:
254
+ | \(DEFINE\)
255
+ ))?
256
+ | (?<qBase>${w_})(?<qMod>[?+]?)(?<invalidQ>[?*+\{]?)
257
+ | \\?.
258
+ `.replace(/\s+/g,""),"gsu");function h6(e){if(!new RegExp(`${w_}\\+`).test(e))return{pattern:e};const t=[];let n=null,r=null,i="",s=0,l;for(wm.lastIndex=0;l=wm.exec(e);){const{0:c,index:d,groups:{qBase:f,qMod:m,invalidQ:h}}=l;if(c==="[")s||(r=d),s++;else if(c==="]")s?s--:r=null;else if(!s)if(m==="+"&&i&&!i.startsWith("(")){if(h)throw new Error(`Invalid quantifier "${c}"`);let g=-1;if(/^\{\d+\}$/.test(f))e=c6(e,d+f.length,m,"");else{if(i===")"||i==="]"){const y=i===")"?n:r;if(y===null)throw new Error(`Invalid unmatched "${i}"`);e=`${e.slice(0,y)}(?>${e.slice(y,d)}${f})${e.slice(d+c.length)}`}else e=`${e.slice(0,d-i.length)}(?>${i}${f})${e.slice(d+c.length)}`;g+=4}wm.lastIndex+=g}else c[0]==="("?t.push(d):c===")"&&(n=t.length?t.pop():null);i=c}return{pattern:e}}const Tr=String.raw,p6=Tr`\\g<(?<gRNameOrNum>[^>&]+)&R=(?<gRDepth>[^>]+)>`,yg=Tr`\(\?R=(?<rDepth>[^\)]+)\)|${p6}`,ph=Tr`\(\?<(?![=!])(?<captureName>[^>]+)>`,b_=Tr`${ph}|(?<unnamed>\()(?!\?)`,Ws=new RegExp(Tr`${ph}|${yg}|\(\?|\\?.`,"gsu"),bm="Cannot use multiple overlapping recursions";function m6(e,t){const{hiddenCaptures:n,mode:r}={hiddenCaptures:[],mode:"plugin",...t};let i=(t==null?void 0:t.captureTransfers)??new Map;if(!new RegExp(yg,"su").test(e))return{pattern:e,captureTransfers:i,hiddenCaptures:n};if(r==="plugin"&&Kd(e,Tr`\(\?\(DEFINE\)`,Rr.DEFAULT))throw new Error("DEFINE groups cannot be used with recursion");const s=[],l=Kd(e,Tr`\\[1-9]`,Rr.DEFAULT),c=new Map,d=[];let f=!1,m=0,h=0,g;for(Ws.lastIndex=0;g=Ws.exec(e);){const{0:y,groups:{captureName:w,rDepth:_,gRNameOrNum:C,gRDepth:I}}=g;if(y==="[")m++;else if(m)y==="]"&&m--;else if(_){if(Ay(_),f)throw new Error(bm);if(l)throw new Error(`${r==="external"?"Backrefs":"Numbered backrefs"} cannot be used with global recursion`);const E=e.slice(0,g.index),S=e.slice(Ws.lastIndex);if(Kd(S,yg,Rr.DEFAULT))throw new Error(bm);const L=+_-1;e=Ty(E,S,L,!1,n,s,h),i=Ny(i,E,L,s.length,0,h);break}else if(C){Ay(I);let E=!1;for(const te of d)if(te.name===C||te.num===+C){if(E=!0,te.hasRecursedWithin)throw new Error(bm);break}if(!E)throw new Error(Tr`Recursive \g cannot be used outside the referenced group "${r==="external"?C:Tr`\g<${C}&R=${I}>`}"`);const S=c.get(C),L=d6(e,S);if(l&&Kd(L,Tr`${ph}|\((?!\?)`,Rr.DEFAULT))throw new Error(`${r==="external"?"Backrefs":"Numbered backrefs"} cannot be used with recursion of capturing groups`);const A=e.slice(S,g.index),R=L.slice(A.length+y.length),U=s.length,X=+I-1,H=Ty(A,R,X,!0,n,s,h);i=Ny(i,A,X,s.length-U,U,h);const re=e.slice(0,S),de=e.slice(S+L.length);e=`${re}${H}${de}`,Ws.lastIndex+=H.length-y.length-A.length-R.length,d.forEach(te=>te.hasRecursedWithin=!0),f=!0}else if(w)h++,c.set(String(h),Ws.lastIndex),c.set(w,Ws.lastIndex),d.push({num:h,name:w});else if(y[0]==="("){const E=y==="(";E&&(h++,c.set(String(h),Ws.lastIndex)),d.push(E?{num:h}:{})}else y===")"&&d.pop()}return n.push(...s),{pattern:e,captureTransfers:i,hiddenCaptures:n}}function Ay(e){const t=`Max depth must be integer between 2 and 100; used ${e}`;if(!/^[1-9]\d*$/.test(e))throw new Error(t);if(e=+e,e<2||e>100)throw new Error(t)}function Ty(e,t,n,r,i,s,l){const c=new Set;r&&y_(e+t,ph,({groups:{captureName:f}})=>{c.add(f)},Rr.DEFAULT);const d=[n,r?c:null,i,s,l];return`${e}${Ry(`(?:${e}`,"forward",...d)}(?:)${Ry(`${t})`,"backward",...d)}${t}`}function Ry(e,t,n,r,i,s,l){const d=m=>t==="forward"?m+2:n-m+2-1;let f="";for(let m=0;m<n;m++){const h=d(m);f+=T0(e,Tr`${b_}|\\k<(?<backref>[^>]+)>`,({0:g,groups:{captureName:y,unnamed:w,backref:_}})=>{if(_&&r&&!r.has(_))return g;const C=`_$${h}`;if(w||y){const I=l+s.length+1;return s.push(I),g6(i,I),w?g:`(?<${y}${C}>`}return Tr`\k<${_}${C}>`},Rr.DEFAULT)}return f}function g6(e,t){for(let n=0;n<e.length;n++)e[n]>=t&&e[n]++}function Ny(e,t,n,r,i,s){if(e.size&&r){let l=0;y_(t,b_,()=>l++,Rr.DEFAULT);const c=s-l+i,d=new Map;return e.forEach((f,m)=>{const h=(r-l*n)/n,g=l*n,y=m>c+l?m+r:m,w=[];for(const _ of f)if(_<=c)w.push(_);else if(_>c+l+h)w.push(_+r);else if(_<=c+l)for(let C=0;C<=n;C++)w.push(_+l*C);else for(let C=0;C<=n;C++)w.push(_+g+h*C);d.set(y,w)}),d}return e}var rn=String.fromCodePoint,Ge=String.raw,ii={},mh=globalThis.RegExp;ii.flagGroups=(()=>{try{new mh("(?i:)")}catch{return!1}return!0})();ii.unicodeSets=(()=>{try{new mh("[[]]","v")}catch{return!1}return!0})();ii.bugFlagVLiteralHyphenIsRange=ii.unicodeSets?(()=>{try{new mh(Ge`[\d\-a]`,"v")}catch{return!0}return!1})():!1;ii.bugNestedClassIgnoresNegation=ii.unicodeSets&&new mh("[[^a]]","v").test("a");function Kf(e,{enable:t,disable:n}){return{dotAll:!(n!=null&&n.dotAll)&&!!(t!=null&&t.dotAll||e.dotAll),ignoreCase:!(n!=null&&n.ignoreCase)&&!!(t!=null&&t.ignoreCase||e.ignoreCase)}}function tu(e,t,n){return e.has(t)||e.set(t,n),e.get(t)}function wg(e,t){return Fy[e]>=Fy[t]}function v6(e,t){if(e==null)throw new Error(t??"Value expected");return e}var Fy={ES2025:2025,ES2024:2024,ES2018:2018},y6={auto:"auto",ES2025:"ES2025",ES2024:"ES2024",ES2018:"ES2018"};function x_(e={}){if({}.toString.call(e)!=="[object Object]")throw new Error("Unexpected options");if(e.target!==void 0&&!y6[e.target])throw new Error(`Unexpected target "${e.target}"`);const 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=ii.flagGroups?"ES2025":ii.unicodeSets?"ES2024":"ES2018"),t}var w6="[ -\r ]",b6=new Set([rn(304),rn(305)]),Zi=Ge`[\p{L}\p{M}\p{N}\p{Pc}]`;function __(e){if(b6.has(e))return[e];const t=new Set,n=e.toLowerCase(),r=n.toUpperCase(),i=k6.get(n),s=x6.get(n),l=_6.get(n);return[...r].length===1&&t.add(r),l&&t.add(l),i&&t.add(i),t.add(n),s&&t.add(s),[...t]}var R0=new Map(`C Other
259
+ Cc Control cntrl
260
+ Cf Format
261
+ Cn Unassigned
262
+ Co Private_Use
263
+ Cs Surrogate
264
+ L Letter
265
+ LC Cased_Letter
266
+ Ll Lowercase_Letter
267
+ Lm Modifier_Letter
268
+ Lo Other_Letter
269
+ Lt Titlecase_Letter
270
+ Lu Uppercase_Letter
271
+ M Mark Combining_Mark
272
+ Mc Spacing_Mark
273
+ Me Enclosing_Mark
274
+ Mn Nonspacing_Mark
275
+ N Number
276
+ Nd Decimal_Number digit
277
+ Nl Letter_Number
278
+ No Other_Number
279
+ P Punctuation punct
280
+ Pc Connector_Punctuation
281
+ Pd Dash_Punctuation
282
+ Pe Close_Punctuation
283
+ Pf Final_Punctuation
284
+ Pi Initial_Punctuation
285
+ Po Other_Punctuation
286
+ Ps Open_Punctuation
287
+ S Symbol
288
+ Sc Currency_Symbol
289
+ Sk Modifier_Symbol
290
+ Sm Math_Symbol
291
+ So Other_Symbol
292
+ Z Separator
293
+ Zl Line_Separator
294
+ Zp Paragraph_Separator
295
+ Zs Space_Separator
296
+ ASCII
297
+ ASCII_Hex_Digit AHex
298
+ Alphabetic Alpha
299
+ Any
300
+ Assigned
301
+ Bidi_Control Bidi_C
302
+ Bidi_Mirrored Bidi_M
303
+ Case_Ignorable CI
304
+ Cased
305
+ Changes_When_Casefolded CWCF
306
+ Changes_When_Casemapped CWCM
307
+ Changes_When_Lowercased CWL
308
+ Changes_When_NFKC_Casefolded CWKCF
309
+ Changes_When_Titlecased CWT
310
+ Changes_When_Uppercased CWU
311
+ Dash
312
+ Default_Ignorable_Code_Point DI
313
+ Deprecated Dep
314
+ Diacritic Dia
315
+ Emoji
316
+ Emoji_Component EComp
317
+ Emoji_Modifier EMod
318
+ Emoji_Modifier_Base EBase
319
+ Emoji_Presentation EPres
320
+ Extended_Pictographic ExtPict
321
+ Extender Ext
322
+ Grapheme_Base Gr_Base
323
+ Grapheme_Extend Gr_Ext
324
+ Hex_Digit Hex
325
+ IDS_Binary_Operator IDSB
326
+ IDS_Trinary_Operator IDST
327
+ ID_Continue IDC
328
+ ID_Start IDS
329
+ Ideographic Ideo
330
+ Join_Control Join_C
331
+ Logical_Order_Exception LOE
332
+ Lowercase Lower
333
+ Math
334
+ Noncharacter_Code_Point NChar
335
+ Pattern_Syntax Pat_Syn
336
+ Pattern_White_Space Pat_WS
337
+ Quotation_Mark QMark
338
+ Radical
339
+ Regional_Indicator RI
340
+ Sentence_Terminal STerm
341
+ Soft_Dotted SD
342
+ Terminal_Punctuation Term
343
+ Unified_Ideograph UIdeo
344
+ Uppercase Upper
345
+ Variation_Selector VS
346
+ White_Space space
347
+ XID_Continue XIDC
348
+ XID_Start XIDS`.split(/\s/).map(e=>[hh(e),e])),x6=new Map([["s",rn(383)],[rn(383),"s"]]),_6=new Map([[rn(223),rn(7838)],[rn(107),rn(8490)],[rn(229),rn(8491)],[rn(969),rn(8486)]]),k6=new Map([Ko(453),Ko(456),Ko(459),Ko(498),...xm(8072,8079),...xm(8088,8095),...xm(8104,8111),Ko(8124),Ko(8140),Ko(8188)]),S6=new Map([["alnum",Ge`[\p{Alpha}\p{Nd}]`],["alpha",Ge`\p{Alpha}`],["ascii",Ge`\p{ASCII}`],["blank",Ge`[\p{Zs}\t]`],["cntrl",Ge`\p{Cc}`],["digit",Ge`\p{Nd}`],["graph",Ge`[\P{space}&&\P{Cc}&&\P{Cn}&&\P{Cs}]`],["lower",Ge`\p{Lower}`],["print",Ge`[[\P{space}&&\P{Cc}&&\P{Cn}&&\P{Cs}]\p{Zs}]`],["punct",Ge`[\p{P}\p{S}]`],["space",Ge`\p{space}`],["upper",Ge`\p{Upper}`],["word",Ge`[\p{Alpha}\p{M}\p{Nd}\p{Pc}]`],["xdigit",Ge`\p{AHex}`]]);function C6(e,t){const n=[];for(let r=e;r<=t;r++)n.push(r);return n}function Ko(e){const t=rn(e);return[t.toLowerCase(),t]}function xm(e,t){return C6(e,t).map(n=>Ko(n))}var k_=new Set(["Lower","Lowercase","Upper","Uppercase","Ll","Lowercase_Letter","Lt","Titlecase_Letter","Lu","Uppercase_Letter"]);function E6(e,t){const n={accuracy:"default",asciiWordBoundaries:!1,avoidSubclass:!1,bestEffortTarget:"ES2025",...t};S_(e);const r={accuracy:n.accuracy,asciiWordBoundaries:n.asciiWordBoundaries,avoidSubclass:n.avoidSubclass,flagDirectivesByAlt:new Map,jsGroupNameMap:new Map,minTargetEs2024:wg(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};zc(e,I6,r);const i={dotAll:e.flags.dotAll,ignoreCase:e.flags.ignoreCase},s={currentFlags:i,prevFlags:null,globalFlags:i,groupOriginByCopy:new Map,groupsByName:new Map,multiplexCapturesToLeftByRef:new Map,openRefs:new Map,reffedNodesByReferencer:new Map,subroutineRefMap:r.subroutineRefMap};zc(e,P6,s);const l={groupsByName:s.groupsByName,highestOrphanBackref:0,numCapturesToLeft:0,reffedNodesByReferencer:s.reffedNodesByReferencer};return zc(e,L6,l),e._originMap=s.groupOriginByCopy,e._strategy=r.strategy,e}var I6={AbsenceFunction({node:e,parent:t,replaceWith:n}){const{body:r,kind:i}=e;if(i==="repeater"){const s=ti();s.body[0].body.push(qs({negate:!0,body:r}),tl("Any"));const l=ti();l.body[0].body.push(m_("greedy",0,1/0,s)),n(jt(l,t),{traverse:!0})}else throw new Error('Unsupported absence function "(?~|"')},Alternative:{enter({node:e,parent:t,key:n},{flagDirectivesByAlt:r}){const i=e.body.filter(s=>s.kind==="flags");for(let s=n+1;s<t.body.length;s++){const l=t.body[s];tu(r,l,[]).push(...i)}},exit({node:e},{flagDirectivesByAlt:t}){var n;if((n=t.get(e))!=null&&n.length){const r=E_(t.get(e));if(r){const i=ti({flags:r});i.body[0].body=e.body,e.body=[jt(i,e)]}}}},Assertion({node:e,parent:t,key:n,container:r,root:i,remove:s,replaceWith:l},c){const{kind:d,negate:f}=e,{asciiWordBoundaries:m,avoidSubclass:h,supportedGNodes:g,wordIsAscii:y}=c;if(d==="text_segment_boundary")throw new Error(`Unsupported text segment boundary "\\${f?"Y":"y"}"`);if(d==="line_end")l(jt(qs({body:[sa({body:[mg("string_end")]}),sa({body:[fh(10)]})]}),t));else if(d==="line_start")l(jt(eo(Ge`(?<=\A|\n(?!\z))`,{skipLookbehindValidation:!0}),t));else if(d==="search_start")if(g.has(e))i.flags.sticky=!0,s();else{const w=r[n-1];if(w&&F6(w))l(jt(qs({negate:!0}),t));else{if(h)throw new Error(Ge`Uses "\G" in a way that requires a subclass`);l(Xo(mg("string_start"),t)),c.strategy="clip_search"}}else if(!(d==="string_end"||d==="string_start"))if(d==="string_end_newline")l(jt(eo(Ge`(?=\n?\z)`),t));else if(d==="word_boundary"){if(!y&&!m){const w=`(?:(?<=${Zi})(?!${Zi})|(?<!${Zi})(?=${Zi}))`,_=`(?:(?<=${Zi})(?=${Zi})|(?<!${Zi})(?!${Zi}))`;l(jt(eo(f?_:w),t))}}else throw new Error(`Unexpected assertion kind "${d}"`)},Backreference({node:e},{jsGroupNameMap:t}){let{ref:n}=e;typeof n=="string"&&!km(n)&&(n=_m(n,t),e.ref=n)},CapturingGroup({node:e},{jsGroupNameMap:t,subroutineRefMap:n}){let{name:r}=e;r&&!km(r)&&(r=_m(r,t),e.name=r),n.set(e.number,e),r&&n.set(r,e)},CharacterClassRange({node:e,parent:t,replaceWith:n}){if(t.kind==="intersection"){const r=pf({body:[e]});n(jt(r,t),{traverse:!0})}},CharacterSet({node:e,parent:t,replaceWith:n},{accuracy:r,minTargetEs2024:i,digitIsAscii:s,spaceIsAscii:l,wordIsAscii:c}){const{kind:d,negate:f,value:m}=e;if(s&&(d==="digit"||m==="digit")){n(Xo(vg("digit",{negate:f}),t));return}if(l&&(d==="space"||m==="space")){n(jt(Sm(eo(w6),f),t));return}if(c&&(d==="word"||m==="word")){n(Xo(vg("word",{negate:f}),t));return}if(d==="any")n(Xo(tl("Any"),t));else if(d==="digit")n(Xo(tl("Nd",{negate:f}),t));else if(d!=="dot")if(d==="text_segment"){if(r==="strict")throw new Error(Ge`Use of "\X" requires non-strict accuracy`);const h="\\p{Emoji}(?:\\p{EMod}|\\uFE0F\\u20E3?|[\\x{E0020}-\\x{E007E}]+\\x{E007F})?",g=Ge`\p{RI}{2}|${h}(?:\u200D${h})*`;n(jt(eo(Ge`(?>\r\n|${i?Ge`\p{RGI_Emoji}`:g}|\P{M}\p{M}*)`,{skipPropertyNameValidation:!0}),t))}else if(d==="hex")n(Xo(tl("AHex",{negate:f}),t));else if(d==="newline")n(jt(eo(f?`[^
349
+ ]`:`(?>\r
350
+ ?|[
351
+ \v\f…\u2028\u2029])`),t));else if(d==="posix")if(!i&&(m==="graph"||m==="print")){if(r==="strict")throw new Error(`POSIX class "${m}" requires min target ES2024 or non-strict accuracy`);let h={graph:"!-~",print:" -~"}[m];f&&(h=`\0-${rn(h.codePointAt(0)-1)}${rn(h.codePointAt(2)+1)}-􏿿`),n(jt(eo(`[${h}]`),t))}else n(jt(Sm(eo(S6.get(m)),f),t));else if(d==="property")R0.has(hh(m))||(e.key="sc");else if(d==="space")n(Xo(tl("space",{negate:f}),t));else if(d==="word")n(jt(Sm(eo(Zi),f),t));else throw new Error(`Unexpected character set kind "${d}"`)},Directive({node:e,parent:t,root:n,remove:r,replaceWith:i,removeAllPrevSiblings:s,removeAllNextSiblings:l}){const{kind:c,flags:d}=e;if(c==="flags")if(!d.enable&&!d.disable)r();else{const f=ti({flags:d});f.body[0].body=l(),i(jt(f,t),{traverse:!0})}else if(c==="keep"){const f=n.body[0],h=n.body.length===1&&f_(f,{type:"Group"})&&f.body[0].body.length===1?f.body[0]:n;if(t.parent!==h||h.body.length>1)throw new Error(Ge`Uses "\K" in a way that's unsupported`);const g=qs({behind:!0});g.body[0].body=s(),i(jt(g,t))}else throw new Error(`Unexpected directive kind "${c}"`)},Flags({node:e,parent:t}){if(e.posixIsAscii)throw new Error('Unsupported flag "P"');if(e.textSegmentMode==="word")throw new Error('Unsupported flag "y{w}"');["digitIsAscii","extended","posixIsAscii","spaceIsAscii","wordIsAscii","textSegmentMode"].forEach(n=>delete e[n]),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;const{enable:t,disable:n}=e.flags;t!=null&&t.extended&&delete t.extended,n!=null&&n.extended&&delete n.extended,t!=null&&t.dotAll&&(n!=null&&n.dotAll)&&delete t.dotAll,t!=null&&t.ignoreCase&&(n!=null&&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){const{kind:n}=e;n==="lookbehind"&&(t.passedLookbehind=!0)},NamedCallout({node:e,parent:t,replaceWith:n}){const{kind:r}=e;if(r==="fail")n(jt(qs({negate:!0}),t));else throw new Error(`Unsupported named callout "(*${r.toUpperCase()}"`)},Quantifier({node:e}){if(e.body.type==="Quantifier"){const t=ti();t.body[0].body.push(e.body),e.body=jt(t,e)}},Regex:{enter({node:e},{supportedGNodes:t}){const n=[];let r=!1,i=!1;for(const s of e.body)if(s.body.length===1&&s.body[0].kind==="search_start")s.body.pop();else{const l=P_(s.body);l?(r=!0,Array.isArray(l)?n.push(...l):n.push(l)):i=!0}r&&!i&&n.forEach(s=>t.add(s))},exit(e,{accuracy:t,passedLookbehind:n,strategy:r}){if(t==="strict"&&n&&r)throw new Error(Ge`Uses "\G" in a way that requires non-strict accuracy`)}},Subroutine({node:e},{jsGroupNameMap:t}){let{ref:n}=e;typeof n=="string"&&!km(n)&&(n=_m(n,t),e.ref=n)}},P6={Backreference({node:e},{multiplexCapturesToLeftByRef:t,reffedNodesByReferencer:n}){const{orphan:r,ref:i}=e;r||n.set(e,[...t.get(i).map(({node:s})=>s)])},CapturingGroup:{enter({node:e,parent:t,replaceWith:n,skip:r},{groupOriginByCopy:i,groupsByName:s,multiplexCapturesToLeftByRef:l,openRefs:c,reffedNodesByReferencer:d}){const f=i.get(e);if(f&&c.has(e.number)){const h=Xo(My(e.number),t);d.set(h,c.get(e.number)),n(h);return}c.set(e.number,e),l.set(e.number,[]),e.name&&tu(l,e.name,[]);const m=l.get(e.name??e.number);for(let h=0;h<m.length;h++){const g=m[h];if(f===g.node||f&&f===g.origin||e===g.origin){m.splice(h,1);break}}if(l.get(e.number).push({node:e,origin:f}),e.name&&l.get(e.name).push({node:e,origin:f}),e.name){const h=tu(s,e.name,new Map);let g=!1;if(f)g=!0;else for(const y of h.values())if(!y.hasDuplicateNameToRemove){g=!0;break}s.get(e.name).set(e,{node:e,hasDuplicateNameToRemove:g})}},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=Kf(t.currentFlags,e.flags))},exit(e,t){t.currentFlags=t.prevFlags}},Subroutine({node:e,parent:t,replaceWith:n},r){const{isRecursive:i,ref:s}=e;if(i){let m=t;for(;(m=m.parent)&&!(m.type==="CapturingGroup"&&(m.name===s||m.number===s)););r.reffedNodesByReferencer.set(e,m);return}const l=r.subroutineRefMap.get(s),c=s===0,d=c?My(0):C_(l,r.groupOriginByCopy,null);let f=d;if(!c){const m=E_(T6(l,g=>g.type==="Group"&&!!g.flags)),h=m?Kf(r.globalFlags,m):r.globalFlags;D6(h,r.currentFlags)||(f=ti({flags:R6(h)}),f.body[0].body.push(d))}n(jt(f,t),{traverse:!c})}},L6={Backreference({node:e,parent:t,replaceWith:n},r){if(e.orphan){r.highestOrphanBackref=Math.max(r.highestOrphanBackref,e.ref);return}const s=r.reffedNodesByReferencer.get(e).filter(l=>A6(l,e));if(!s.length)n(jt(qs({negate:!0}),t));else if(s.length>1){const l=ti({atomic:!0,body:s.reverse().map(c=>sa({body:[gg(c.number)]}))});n(jt(l,t))}else e.ref=s[0].number},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){const n=Math.max(t.highestOrphanBackref-t.numCapturesToLeft,0);for(let r=0;r<n;r++){const i=p_();e.body.at(-1).body.push(i)}}},Subroutine({node:e},t){!e.isRecursive||e.ref===0||(e.ref=t.reffedNodesByReferencer.get(e).number)}};function S_(e){zc(e,{"*"({node:t,parent:n}){t.parent=n}})}function D6(e,t){return e.dotAll===t.dotAll&&e.ignoreCase===t.ignoreCase}function A6(e,t){let n=t;do{if(n.type==="Regex")return!1;if(n.type==="Alternative")continue;if(n===e)return!1;const r=I_(n.parent);for(const i of r){if(i===n)break;if(i===e||L_(i,e))return!0}}while(n=n.parent);throw new Error("Unexpected path")}function C_(e,t,n,r){const i=Array.isArray(e)?[]:{};for(const[s,l]of Object.entries(e))s==="parent"?i.parent=Array.isArray(n)?r:n:l&&typeof l=="object"?i[s]=C_(l,t,i,n):(s==="type"&&l==="CapturingGroup"&&t.set(i,t.get(e)??e),i[s]=l);return i}function My(e){const t=g_(e);return t.isRecursive=!0,t}function T6(e,t){const n=[];for(;e=e.parent;)(!t||t(e))&&n.push(e);return n}function _m(e,t){if(t.has(e))return t.get(e);const n=`$${t.size}_${e.replace(/^[^$_\p{IDS}]|[^$\u200C\u200D\p{IDC}]/ug,"_")}`;return t.set(e,n),n}function E_(e){const t=["dotAll","ignoreCase"],n={enable:{},disable:{}};return e.forEach(({flags:r})=>{t.forEach(i=>{var s,l;(s=r.enable)!=null&&s[i]&&(delete n.disable[i],n.enable[i]=!0),(l=r.disable)!=null&&l[i]&&(n.disable[i]=!0)})}),Object.keys(n.enable).length||delete n.enable,Object.keys(n.disable).length||delete n.disable,n.enable||n.disable?n:null}function R6({dotAll:e,ignoreCase:t}){const 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 I_(e){if(!e)throw new Error("Node expected");const{body:t}=e;return Array.isArray(t)?t:t?[t]:null}function P_(e){const t=e.find(n=>n.kind==="search_start"||M6(n,{negate:!1})||!N6(n));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"){const n=[];for(const r of t.body){const i=P_(r.body);if(!i)return null;Array.isArray(i)?n.push(...i):n.push(i)}return n}return null}function L_(e,t){const n=I_(e)??[];for(const r of n)if(r===t||L_(r,t))return!0;return!1}function N6({type:e}){return e==="Assertion"||e==="Directive"||e==="LookaroundAssertion"}function F6(e){const t=["Character","CharacterClass","CharacterSet"];return t.includes(e.type)||e.type==="Quantifier"&&e.min&&t.includes(e.body.type)}function M6(e,t){const n={negate:null,...t};return e.type==="LookaroundAssertion"&&(n.negate===null||e.negate===n.negate)&&e.body.length===1&&f_(e.body[0],{type:"Assertion",kind:"search_start"})}function km(e){return/^[$_\p{IDS}][$\u200C\u200D\p{IDC}]*$/u.test(e)}function eo(e,t){const r=h_(e,{...t,unicodePropertyMap:R0}).body;return r.length>1||r[0].body.length>1?ti({body:r}):r[0].body[0]}function Sm(e,t){return e.negate=t,e}function Xo(e,t){return e.parent=t,e}function jt(e,t){return S_(e),e.parent=t,e}function O6(e,t){const n=x_(t),r=wg(n.target,"ES2024"),i=wg(n.target,"ES2025"),s=n.rules.recursionLimit;if(!Number.isInteger(s)||s<2||s>20)throw new Error("Invalid recursionLimit; use 2-20");let l=null,c=null;if(!i){const y=[e.flags.ignoreCase];zc(e,$6,{getCurrentModI:()=>y.at(-1),popModI(){y.pop()},pushModI(w){y.push(w)},setHasCasedChar(){y.at(-1)?l=!0:c=!0}})}const d={dotAll:e.flags.dotAll,ignoreCase:!!((e.flags.ignoreCase||l)&&!c)};let f=e;const m={accuracy:n.accuracy,appliedGlobalFlags:d,captureMap:new Map,currentFlags:{dotAll:e.flags.dotAll,ignoreCase:e.flags.ignoreCase},inCharClass:!1,lastNode:f,originMap:e._originMap,recursionLimit:s,useAppliedIgnoreCase:!!(!i&&l&&c),useFlagMods:i,useFlagV:r,verbose:n.verbose};function h(y){return m.lastNode=f,f=y,v6(B6[y.type],`Unexpected node type "${y.type}"`)(y,m,h)}const g={pattern:e.body.map(h).join("|"),flags:h(e.flags),options:{...e.options}};return r||(delete g.options.force.v,g.options.disable.v=!0,g.options.unicodeSetsPlugin=null),g._captureTransfers=new Map,g._hiddenCaptures=[],m.captureMap.forEach((y,w)=>{y.hidden&&g._hiddenCaptures.push(w),y.transferTo&&tu(g._captureTransfers,y.transferTo,[]).push(w)}),g}var $6={"*":{enter({node:e},t){if($y(e)){const n=t.getCurrentModI();t.pushModI(e.flags?Kf({ignoreCase:n},e.flags).ignoreCase:n)}},exit({node:e},t){$y(e)&&t.popModI()}},Backreference(e,t){t.setHasCasedChar()},Character({node:e},t){N0(rn(e.value))&&t.setHasCasedChar()},CharacterClassRange({node:e,skip:t},n){t(),D_(e,{firstOnly:!0}).length&&n.setHasCasedChar()},CharacterSet({node:e},t){e.kind==="property"&&k_.has(e.value)&&t.setHasCasedChar()}},B6={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?Ge`\B`:Ge`\b`;throw new Error(`Unexpected assertion kind "${e}"`)},Backreference({ref:e},t){if(typeof e!="number")throw new Error("Unexpected named backref in transformed AST");if(!t.useFlagMods&&t.accuracy==="strict"&&t.currentFlags.ignoreCase&&!t.captureMap.get(e).ignoreCase)throw new Error("Use of case-insensitive backref to case-sensitive group requires target ES2025 or non-strict accuracy");return"\\"+e},CapturingGroup(e,t,n){const{body:r,name:i,number:s}=e,l={ignoreCase:t.currentFlags.ignoreCase},c=t.originMap.get(e);return c&&(l.hidden=!0,s>c.number&&(l.transferTo=c.number)),t.captureMap.set(s,l),`(${i?`?<${i}>`:""}${r.map(n).join("|")})`},Character({value:e},t){const n=rn(e),r=Ka(e,{escDigit:t.lastNode.type==="Backreference",inCharClass:t.inCharClass,useFlagV:t.useFlagV});if(r!==n)return r;if(t.useAppliedIgnoreCase&&t.currentFlags.ignoreCase&&N0(n)){const i=__(n);return t.inCharClass?i.join(""):i.length>1?`[${i.join("")}]`:i[0]}return n},CharacterClass(e,t,n){const{kind:r,negate:i,parent:s}=e;let{body:l}=e;if(r==="intersection"&&!t.useFlagV)throw new Error("Use of character class intersection requires min target ES2024");ii.bugFlagVLiteralHyphenIsRange&&t.useFlagV&&l.some(By)&&(l=[fh(45),...l.filter(f=>!By(f))]);const c=()=>`[${i?"^":""}${l.map(n).join(r==="intersection"?"&&":"")}]`;if(!t.inCharClass){if((!t.useFlagV||ii.bugNestedClassIgnoresNegation)&&!i){const m=l.filter(h=>h.type==="CharacterClass"&&h.kind==="union"&&h.negate);if(m.length){const h=ti(),g=h.body[0];return h.parent=s,g.parent=h,l=l.filter(y=>!m.includes(y)),e.body=l,l.length?(e.parent=g,g.body.push(e)):h.body.pop(),m.forEach(y=>{const w=sa({body:[y]});y.parent=w,w.parent=h,h.body.push(w)}),n(h)}}t.inCharClass=!0;const f=c();return t.inCharClass=!1,f}const d=l[0];if(r==="union"&&!i&&d&&((!t.useFlagV||!t.verbose)&&s.kind==="union"&&!(ii.bugFlagVLiteralHyphenIsRange&&t.useFlagV)||!t.verbose&&s.kind==="intersection"&&l.length===1&&d.type!=="CharacterClassRange"))return l.map(n).join("");if(!t.useFlagV&&s.type==="CharacterClass")throw new Error("Uses nested character class in a way that requires min target ES2024");return c()},CharacterClassRange(e,t){const n=e.min.value,r=e.max.value,i={escDigit:!1,inCharClass:!0,useFlagV:t.useFlagV},s=Ka(n,i),l=Ka(r,i),c=new Set;if(t.useAppliedIgnoreCase&&t.currentFlags.ignoreCase){const d=D_(e);H6(d).forEach(m=>{c.add(Array.isArray(m)?`${Ka(m[0],i)}-${Ka(m[1],i)}`:Ka(m,i))})}return`${s}-${l}${[...c].join("")}`},CharacterSet({kind:e,negate:t,value:n,key:r},i){if(e==="dot")return i.currentFlags.dotAll?i.appliedGlobalFlags.dotAll||i.useFlagMods?".":"[^]":Ge`[^\n]`;if(e==="digit")return t?Ge`\D`:Ge`\d`;if(e==="property"){if(i.useAppliedIgnoreCase&&i.currentFlags.ignoreCase&&k_.has(n))throw new Error(`Unicode property "${n}" can't be case-insensitive when other chars have specific case`);return`${t?Ge`\P`:Ge`\p`}{${r?`${r}=`:""}${n}}`}if(e==="word")return t?Ge`\W`:Ge`\w`;throw new 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,s){const l=i.currentFlags;n&&(i.currentFlags=Kf(l,n));const c=t.map(s).join("|"),d=!i.verbose&&t.length===1&&r.type!=="Quantifier"&&!e&&(!i.useFlagMods||!n)?c:`(?${W6(e,n,i.useFlagMods)}${c})`;return i.currentFlags=l,d},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)+G6(e)},Subroutine({isRecursive:e,ref:t},n){if(!e)throw new Error("Unexpected non-recursive subroutine in transformed AST");const r=n.recursionLimit;return t===0?`(?R=${r})`:Ge`\g<${t}&R=${r}>`}},j6=new Set(["$","(",")","*","+",".","?","[","\\","]","^","{","|","}"]),V6=new Set(["-","\\","]","^","["]),U6=new Set(["(",")","-","/","[","\\","]","^","{","|","}","!","#","$","%","&","*","+",",",".",":",";","<","=",">","?","@","`","~"]),Oy=new Map([[9,Ge`\t`],[10,Ge`\n`],[11,Ge`\v`],[12,Ge`\f`],[13,Ge`\r`],[8232,Ge`\u2028`],[8233,Ge`\u2029`],[65279,Ge`\uFEFF`]]),z6=new RegExp("^\\p{Cased}$","u");function N0(e){return z6.test(e)}function D_(e,t){const n=!!(t!=null&&t.firstOnly),r=e.min.value,i=e.max.value,s=[];if(r<65&&(i===65535||i>=131071)||r===65536&&i>=131071)return s;for(let l=r;l<=i;l++){const c=rn(l);if(!N0(c))continue;const d=__(c).filter(f=>{const m=f.codePointAt(0);return m<r||m>i});if(d.length&&(s.push(...d),n))break}return s}function Ka(e,{escDigit:t,inCharClass:n,useFlagV:r}){if(Oy.has(e))return Oy.get(e);if(e<32||e>126&&e<160||e>262143||t&&q6(e))return e>255?`\\u{${e.toString(16).toUpperCase()}}`:`\\x${e.toString(16).toUpperCase().padStart(2,"0")}`;const i=n?r?U6:V6:j6,s=rn(e);return(i.has(s)?"\\":"")+s}function H6(e){const t=e.map(i=>i.codePointAt(0)).sort((i,s)=>i-s),n=[];let r=null;for(let i=0;i<t.length;i++)t[i+1]===t[i]+1?r??(r=t[i]):r===null?n.push(t[i]):(n.push([r,t[i]]),r=null);return n}function W6(e,t,n){if(e)return">";let r="";if(t&&n){const{enable:i,disable:s}=t;r=(i!=null&&i.ignoreCase?"i":"")+(i!=null&&i.dotAll?"s":"")+(s?"-":"")+(s!=null&&s.ignoreCase?"i":"")+(s!=null&&s.dotAll?"s":"")}return`${r}:`}function G6({kind:e,max:t,min:n}){let r;return!n&&t===1?r="?":!n&&t===1/0?r="*":n===1&&t===1/0?r="+":n===t?r=`{${n}}`:r=`{${n},${t===1/0?"":t}}`,r+{greedy:"",lazy:"?",possessive:"+"}[e]}function $y({type:e}){return e==="CapturingGroup"||e==="Group"||e==="LookaroundAssertion"}function q6(e){return e>47&&e<58}function By({type:e,value:t}){return e==="Character"&&t===45}var Zo,oo,Ys,es,Js,uu,bg,ps,K6=(ps=class extends RegExp{constructor(n,r,i){var t=(...JM)=>(super(...JM),ye(this,uu),ye(this,Zo,new Map),ye(this,oo,null),ye(this,Ys),ye(this,es,null),ye(this,Js,null),F(this,"rawOptions",{}),this);const s=!!(i!=null&&i.lazyCompile);if(n instanceof RegExp){if(i)throw new Error("Cannot provide options when copying a regexp");const l=n;t(l,r),Y(this,Ys,l.source),l instanceof ps&&(Y(this,Zo,x(l,Zo)),Y(this,es,x(l,es)),Y(this,Js,x(l,Js)),this.rawOptions=l.rawOptions)}else{const l={hiddenCaptures:[],strategy:null,transfers:[],...i};t(s?"":n,r),Y(this,Ys,n),Y(this,Zo,Q6(l.hiddenCaptures,l.transfers)),Y(this,Js,l.strategy),this.rawOptions=i??{}}s||Y(this,oo,this)}get source(){return x(this,Ys)||"(?:)"}exec(n){if(!x(this,oo)){const{lazyCompile:s,...l}=this.rawOptions;Y(this,oo,new ps(x(this,Ys),this.flags,l))}const r=this.global||this.sticky,i=this.lastIndex;if(x(this,Js)==="clip_search"&&r&&i){this.lastIndex=0;const s=V(this,uu,bg).call(this,n.slice(i));return s&&(X6(s,i,n,this.hasIndices),this.lastIndex+=i),s}return V(this,uu,bg).call(this,n)}},Zo=new WeakMap,oo=new WeakMap,Ys=new WeakMap,es=new WeakMap,Js=new WeakMap,uu=new WeakSet,bg=function(n){x(this,oo).lastIndex=this.lastIndex;const r=lv(ps.prototype,this,"exec").call(x(this,oo),n);if(this.lastIndex=x(this,oo).lastIndex,!r||!x(this,Zo).size)return r;const i=[...r];r.length=1;let s;this.hasIndices&&(s=[...r.indices],r.indices.length=1);const l=[0];for(let c=1;c<i.length;c++){const{hidden:d,transferTo:f}=x(this,Zo).get(c)??{};if(d?l.push(null):(l.push(r.length),r.push(i[c]),this.hasIndices&&r.indices.push(s[c])),f&&i[c]!==void 0){const m=l[f];if(!m)throw new Error(`Invalid capture transfer to "${m}"`);if(r[m]=i[c],this.hasIndices&&(r.indices[m]=s[c]),r.groups){x(this,es)||Y(this,es,Y6(this.source));const h=x(this,es).get(f);h&&(r.groups[h]=i[c],this.hasIndices&&(r.indices.groups[h]=s[c]))}}}return r},ps);function X6(e,t,n,r){if(e.index+=t,e.input=n,r){const i=e.indices;for(let l=0;l<i.length;l++){const c=i[l];c&&(i[l]=[c[0]+t,c[1]+t])}const s=i.groups;s&&Object.keys(s).forEach(l=>{const c=s[l];c&&(s[l]=[c[0]+t,c[1]+t])})}}function Q6(e,t){const n=new Map;for(const r of e)n.set(r,{hidden:!0});for(const[r,i]of t)for(const s of i)tu(n,s,{}).transferTo=r;return n}function Y6(e){const t=/(?<capture>\((?:\?<(?![=!])(?<name>[^>]+)>|(?!\?)))|\\?./gsu,n=new Map;let r=0,i=0,s;for(;s=t.exec(e);){const{0:l,groups:{capture:c,name:d}}=s;l==="["?r++:r?l==="]"&&r--:c&&(i++,d&&n.set(i,d))}return n}function J6(e,t){const n=Z6(e,t);return n.options?new K6(n.pattern,n.flags,n.options):new RegExp(n.pattern,n.flags)}function Z6(e,t){const n=x_(t),r=h_(e,{flags:n.flags,normalizeUnknownPropertyNames:!0,rules:{captureGroup:n.rules.captureGroup,singleline:n.rules.singleline},skipBackrefValidation:n.rules.allowOrphanBackrefs,unicodePropertyMap:R0}),i=E6(r,{accuracy:n.accuracy,asciiWordBoundaries:n.rules.asciiWordBoundaries,avoidSubclass:n.avoidSubclass,bestEffortTarget:n.target}),s=O6(i,n),l=m6(s.pattern,{captureTransfers:s._captureTransfers,hiddenCaptures:s._hiddenCaptures,mode:"external"}),c=h6(l.pattern),d=f6(c.pattern,{captureTransfers:l.captureTransfers,hiddenCaptures:l.hiddenCaptures}),f={pattern:d.pattern,flags:`${n.hasIndices?"d":""}${n.global?"g":""}${s.flags}${s.options.disable.v?"u":"v"}`};if(n.avoidSubclass){if(n.lazyCompileLength!==1/0)throw new Error("Lazy compilation requires subclass")}else{const m=d.hiddenCaptures.sort((w,_)=>w-_),h=Array.from(d.captureTransfers),g=i._strategy,y=f.pattern.length>=n.lazyCompileLength;(m.length||h.length||g||y)&&(f.options={...m.length&&{hiddenCaptures:m},...h.length&&{transfers:h},...g&&{strategy:g},...y&&{lazyCompile:y}})}return f}const jy=4294967295;class eL{constructor(t,n={}){F(this,"regexps");this.patterns=t,this.options=n;const{forgiving:r=!1,cache:i,regexConstructor:s}=n;if(!s)throw new Error("Option `regexConstructor` is not provided");this.regexps=t.map(l=>{if(typeof l!="string")return l;const c=i==null?void 0:i.get(l);if(c){if(c instanceof RegExp)return c;if(r)return null;throw c}try{const d=s(l);return i==null||i.set(l,d),d}catch(d){if(i==null||i.set(l,d),r)return null;throw d}})}findNextMatchSync(t,n,r){const i=typeof t=="string"?t:t.content,s=[];function l(c,d,f=0){return{index:c,captureIndices:d.indices.map(m=>m==null?{start:jy,end:jy,length:0}:{start:m[0]+f,end:m[1]+f,length:m[1]-m[0]})}}for(let c=0;c<this.regexps.length;c++){const d=this.regexps[c];if(d)try{d.lastIndex=n;const f=d.exec(i);if(!f)continue;if(f.index===n)return l(c,f,0);s.push([c,f,0])}catch(f){if(this.options.forgiving)continue;throw f}}if(s.length){const c=Math.min(...s.map(d=>d[1].index));for(const[d,f,m]of s)if(f.index===c)return l(d,f,m)}return null}}function tL(e,t){return J6(e,{global:!0,hasIndices:!0,lazyCompileLength:3e3,rules:{allowOrphanBackrefs:!0,asciiWordBoundaries:!0,captureGroup:!0,recursionLimit:5,singleline:!0},...t})}function nL(e={}){const t=Object.assign({target:"auto",cache:new Map},e);return t.regexConstructor||(t.regexConstructor=n=>tL(n,{target:t.target})),{createScanner(n){return new eL(n,t)},createString(n){return{content:n}}}}async function rL(e){if(yx())throw new Error(`resolveLanguage("${e}") cannot be called from a worker context. Languages must be pre-resolved on the main thread and passed to the worker via the resolvedLanguages parameter.`);const t=cm.get(e);if(t!=null)return t;try{let n=lI.get(e);if(n==null&&Object.prototype.hasOwnProperty.call(pg,e)&&(n=pg[e]),n==null)throw new Error(`resolveLanguage: "${e}" not found in bundled or custom languages`);const r=n().then(({default:i})=>{const s={name:e,data:i};return Qc.has(e)||Qc.set(e,s),s});return cm.set(e,r),await r}finally{cm.delete(e)}}function iL(e){return Qc.get(e)??rL(e)}async function oL(e){if(yx())throw new Error(`resolveTheme("${e}") cannot be called from a worker context. Themes must be pre-resolved on the main thread and passed to the worker via the resolvedLanguages parameter.`);const t=lm.get(e);if(t!=null)return t;try{const n=eg.get(e)??i_[e];if(n==null)throw new Error(`resolveTheme: No valid loader for ${e}`);const r=n().then(s=>sL(e,"default"in s?s.default:s));lm.set(e,r);const i=await r;if(i.name!==e)throw new Error(`resolvedTheme: themeName: ${e} does not match theme.name: ${i.name}`);return ra.set(i.name,i),i}finally{lm.delete(e)}}function sL(e,t){const n=ra.get(e);return n??(t=ch(t),ra.set(e,t),t)}function aL(e){return ra.get(e)??oL(e)}function A_(e,t){if(eg.has(e)){console.error("SharedHighlight.registerCustomTheme: theme name already registered",e);return}eg.set(e,t)}let Li;async function lL({themes:e,langs:t,preferredHighlighter:n="shiki-js"}){Li??(Li=g8({themes:[],langs:["text"],engine:n==="shiki-wasm"?s_(D(()=>import("./wasm-CG6Dc4jp.js"),[])):nL()}));const r=uL(Li)?await Li:Li;Li=r;const i=[];for(const l of t){if(l==="text"||l==="ansi")continue;const c=iL(l);"then"in c?i.push(c):Jv(c,r)}const s=[];for(const l of e){const c=aL(l);"then"in c?s.push(c):Qv(c,Li)}return(i.length>0||s.length>0)&&await Promise.all([Promise.all(i).then(l=>{Jv(l,r)}),Promise.all(s).then(l=>{Qv(l,r)})]),r}function cL(){if(Li!=null&&!("then"in Li))return Li}function uL(e=Li){return e!=null&&"then"in e}A_("pierre-dark",async()=>{const{default:e}=await D(async()=>{const{default:t}=await import("./pierre-dark-DF2SEV7i.js");return{default:t}},[]);return{...e,name:"pierre-dark"}});A_("pierre-light",async()=>{const{default:e}=await D(async()=>{const{default:t}=await import("./pierre-light-DOlZxES8.js");return{default:t}},[]);return{...e,name:"pierre-light"}});function T_(e=Ai){const t=[];return typeof e=="string"?t.push(e):(t.push(e.dark),t.push(e.light)),t}function R_(e,t){return e==null||t==null||typeof e=="string"||typeof t=="string"?e===t:e.dark===t.dark&&e.light===t.light}const Xa=new Map,Pc={"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 ia(e){var r;if(Xa.has(e))return Xa.get(e)??"text";if(Pc[e]!=null)return Pc[e];const t=e.match(/\.([^/\\]+\.[^/\\]+)$/);if(t!=null){if(Xa.has(t[1]))return Xa.get(t[1])??"text";if(Pc[t[1]]!=null)return Pc[t[1]]??"text"}const n=((r=e.match(/\.([^.]+)$/))==null?void 0:r[1])??"";return Xa.has(n)?Xa.get(n)??"text":Pc[n]??"text"}function Dl(e){return e.replace(/\n$|\r\n$/,"")}function Ni(e){return{type:"text",value:e}}function Ye({tagName:e,children:t=[],properties:n={}}){return{type:"element",tagName:e,properties:n,children:t}}function Xf({name:e,width:t=16,height:n=16,properties:r}){return Ye({tagName:"svg",properties:{width:t,height:n,viewBox:"0 0 16 16",...r},children:[Ye({tagName:"use",properties:{href:`#${e.replace(/^#/,"")}`}})]})}function dL(e){let t=e.children[0];for(;t!=null;){if(t.type==="element"&&t.tagName==="code")return t;"children"in t?t=t.children[0]:t=null}}function Xd(e){return Ye({tagName:"div",properties:{"data-gutter":""},children:e})}function fL(e,t,n,r={}){return Ye({tagName:"div",properties:{"data-line-type":e,"data-column-number":t,"data-line-index":n,...r},children:t!=null?[Ye({tagName:"span",properties:{"data-line-number-content":""},children:[Ni(`${t}`)]})]:void 0})}function Jr(e,t,n){return Ye({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 hL(e,t,n){const r=typeof n.lineInfo=="function"?n.lineInfo(t):n.lineInfo[t-1];if(r==null){const i=`processLine: line ${t}, contains no state.lineInfo`;throw console.error(i,{node:e,line:t,state:n}),new Error(i)}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(Ni(`
352
+ `)),e}const Qd=Symbol("no-token"),Cm=Symbol("multiple-tokens");function N_(e){const t=pL(e);if(t!=null)return t;let n=Qd;const r=[];let i=[],s;const l=()=>{if(i.length===0||s==null){i=[],s=void 0;return}if(i.length===1){const d=i[0];if((d==null?void 0:d.type)==="element"){mL(d,s);for(const f of d.children)mf(f)}else mf(d);r.push(d),i=[],s=void 0;return}for(const d of i)mf(d);r.push(Ye({tagName:"span",properties:{"data-char":s},children:i})),i=[],s=void 0},c=d=>{if(d!==Qd){if(d===Cm){n=Cm;return}if(n===Qd){n=d;return}n!==d&&(n=Cm)}};for(const d of e.children){const f=d.type==="element"?N_(d):Qd;if(c(f),typeof f!="number"){l(),r.push(d);continue}s!=null&&s!==f&&l(),s??(s=f),i.push(d)}return l(),e.children=r,n}function pL(e){const t=e.properties["data-char"];if(typeof t=="number")return t}function mf(e){if(e.type==="element"){e.properties["data-char"]=void 0;for(const t of e.children)mf(t)}}function mL(e,t){e.properties["data-char"]=t}function gL(e={}){const{classPrefix:t="__shiki_",classSuffix:n="",classReplacer:r=c=>c}=e,i=new Map;function s(c){return Object.entries(c).map(([d,f])=>`${d}:${f}`).join(";")}function l(c){const d=typeof c=="string"?c:s(c);let f=t+vL(d)+n;return f=r(f),i.has(f)||i.set(f,typeof c=="string"?c:{...c}),f}return{name:"@shikijs/transformers:style-to-class",pre(c){if(!c.properties.style)return;const d=l(c.properties.style);delete c.properties.style,this.addClassToHast(c,d)},tokens(c){for(const d of c)for(const f of d){if(!f.htmlStyle)continue;const m=l(f.htmlStyle);f.htmlStyle={},f.htmlAttrs||(f.htmlAttrs={}),f.htmlAttrs.class?f.htmlAttrs.class+=` ${m}`:f.htmlAttrs.class=m}},getClassRegistry(){return i},getCSS(){let c="";for(const[d,f]of i.entries())c+=`.${d}{${typeof f=="string"?f:s(f)}}`;return c},clearRegistry(){i.clear()}}}function vL(e,t=0){let n=3735928559^t,r=1103547991^t;for(let i=0,s;i<e.length;i++)s=e.charCodeAt(i),n=Math.imul(n^s,2654435761),r=Math.imul(r^s,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 yL(e=!1,t=!1){const n={lineInfo:[]},r=[{line(i){return delete i.properties.class,i},pre(i){const s=dL(i),l=[];if(s!=null){let c=1;for(const d of s.children)d.type==="element"&&(e&&N_(d),l.push(hL(d,c,n)),c++);s.children=l}return i},...e?{tokens(i){for(const s of i){let l=0;for(const c of s){const d=c;d.__lineChar??(d.__lineChar=l),l+=c.content.length}}},preprocess(i,s){s.mergeWhitespaces="never"},span(i,s,l,c,d){if((d==null?void 0:d.offset)!=null&&d.content!=null){const f=d.__lineChar;return f!=null&&(i.properties["data-char"]=f),i}return i}}:null}];return t&&r.push(wL,Vy),{state:n,transformers:r,toClass:Vy}}const Vy=gL({classPrefix:"hl-"}),wL={name:"token-style-normalizer",tokens(e){for(const t of e)for(const n of t){if(n.htmlStyle!=null)continue;const r={};n.color!=null&&(r.color=n.color),n.bgColor!=null&&(r["background-color"]=n.bgColor),n.fontStyle!=null&&n.fontStyle!==0&&((n.fontStyle&1)!==0&&(r["font-style"]="italic"),(n.fontStyle&2)!==0&&(r["font-weight"]="bold"),(n.fontStyle&4)!==0&&(r["text-decoration"]="underline")),Object.keys(r).length>0&&(n.htmlStyle=r)}}};function ei(e){return`--${e==="token"?"diffs-token":"diffs"}-`}function bL({theme:e=Ai,highlighter:t,prefix:n}){let r="";if(typeof e=="string"){const i=t.getTheme(e);r+=`color:${i.fg};`,r+=`background-color:${i.bg};`,r+=`${ei("global")}fg:${i.fg};`,r+=`${ei("global")}bg:${i.bg};`,r+=Em(i,n)}else{let i=t.getTheme(e.dark);r+=`${ei("global")}dark:${i.fg};`,r+=`${ei("global")}dark-bg:${i.bg};`,r+=Em(i,"dark"),i=t.getTheme(e.light),r+=`${ei("global")}light:${i.fg};`,r+=`${ei("global")}light-bg:${i.bg};`,r+=Em(i,"light")}return r}function Em(e,t){var l,c,d,f,m,h;t=t!=null?`${t}-`:"";let n="";const r=((l=e.colors)==null?void 0:l["gitDecoration.addedResourceForeground"])??((c=e.colors)==null?void 0:c["terminal.ansiGreen"]);r!=null&&(n+=`${ei("global")}${t}addition-color:${r};`);const i=((d=e.colors)==null?void 0:d["gitDecoration.deletedResourceForeground"])??((f=e.colors)==null?void 0:f["terminal.ansiRed"]);i!=null&&(n+=`${ei("global")}${t}deletion-color:${i};`);const s=((m=e.colors)==null?void 0:m["gitDecoration.modifiedResourceForeground"])??((h=e.colors)==null?void 0:h["terminal.ansiBlue"]);return s!=null&&(n+=`${ei("global")}${t}modified-color:${s};`),n}function Uy(e){let t=e.children[0];for(;t!=null;){if(t.type==="element"&&t.tagName==="code")return t.children;"children"in t?t=t.children[0]:t=null}throw console.error(e),new Error("getLineNodes: Unable to find children")}function zy(e,t){return(e==null?void 0:e.cacheKey)===(t==null?void 0:t.cacheKey)&&(e==null?void 0:e.contents)===(t==null?void 0:t.contents)&&(e==null?void 0:e.name)===(t==null?void 0:t.name)&&(e==null?void 0:e.lang)===(t==null?void 0:t.lang)}function Im(e,t){return R_(e.theme,t.theme)&&e.useTokenTransformer===t.useTokenTransformer&&e.tokenizeMaxLineLength===t.tokenizeMaxLineLength&&e.lineDiffType===t.lineDiffType&&e.maxLineDiffLength===t.maxLineDiffLength}function xL(e){const t=e.lang??ia(e.name),n=e.lang??(e.prevName!=null?ia(e.prevName):"text");return t==="text"&&n==="text"}function Qf({diff:e,diffStyle:t,startingLine:n=0,totalLines:r=1/0,expandedHunks:i,collapsedContextThreshold:s=ll,callback:l}){const c={finalHunk:e.hunks.at(-1),viewportStart:n,viewportEnd:n+r,isWindowedHighlight:n>0||r<1/0,splitCount:0,unifiedCount:0,shouldBreak(){if(!c.isWindowedHighlight)return!1;const m=c.unifiedCount>=n+r,h=c.splitCount>=n+r;return t==="unified"?m:(t==="split"||m)&&h},shouldSkip(m,h){if(!c.isWindowedHighlight)return!1;const g=c.unifiedCount+m<n,y=c.splitCount+h<n;return t==="unified"?g:(t==="split"||g)&&y},incrementCounts(m,h){(t==="unified"||t==="both")&&(c.unifiedCount+=m),(t==="split"||t==="both")&&(c.splitCount+=h)},isInWindow(m,h){if(!c.isWindowedHighlight)return!0;const g=c.isInUnifiedWindow(m),y=c.isInSplitWindow(h);return t==="unified"?g:t==="split"?y:g||y},isInUnifiedWindow(m){return!c.isWindowedHighlight||c.unifiedCount>=n-m&&c.unifiedCount<n+r},isInSplitWindow(m){return!c.isWindowedHighlight||c.splitCount>=n-m&&c.splitCount<n+r},emit(m,h=!1){return h||(t==="unified"?c.incrementCounts(1,0):t==="split"?c.incrementCounts(0,1):c.incrementCounts(1,1)),l(m)??!1}};e:for(const[m,h]of e.hunks.entries()){let _=function(X,H){return y==null||y.collapsedLines<=0||y.fromStart+y.fromEnd>0?0:t==="unified"?X===h.unifiedLineStart+h.unifiedLineCount-1?y.collapsedLines:0:H===h.splitLineStart+h.splitLineCount-1?y.collapsedLines:0},C=function(){if(g.collapsedLines===0)return 0;const X=g.collapsedLines;return g.collapsedLines=0,X};var d=_,f=C;if(c.shouldBreak())break;const g=Hy(e.isPartial,h.collapsedBefore,i,m,s),y=(()=>{if(h!==c.finalHunk||!_L(e))return;const X=e.additionLines.length-(h.additionLineIndex+h.additionCount),H=e.deletionLines.length-(h.deletionLineIndex+h.deletionCount);if(X!==H)throw new Error(`iterateOverDiff: trailing context mismatch (additions=${X}, deletions=${H}) for ${e.name}`);const re=Math.min(X,H);return Hy(e.isPartial,re,i,e.hunks.length,s)})(),w=g.fromStart+g.fromEnd;if(c.shouldSkip(w,w))c.incrementCounts(w,w),C();else{let X=h.unifiedLineStart-g.rangeSize,H=h.splitLineStart-g.rangeSize,re=h.deletionLineIndex-g.rangeSize,de=h.additionLineIndex-g.rangeSize,te=h.deletionStart-g.rangeSize,Q=h.additionStart-g.rangeSize,ee=0;for(;ee<g.fromStart;){if(c.isInWindow(0,0)){if(c.emit({hunkIndex:m,hunk:h,collapsedBefore:0,collapsedAfter:0,type:"context-expanded",deletionLine:{lineNumber:te+ee,lineIndex:re+ee,noEOFCR:!1,unifiedLineIndex:X+ee,splitLineIndex:H+ee},additionLine:{unifiedLineIndex:X+ee,splitLineIndex:H+ee,lineIndex:de+ee,lineNumber:Q+ee,noEOFCR:!1}}))break e}else c.incrementCounts(1,1);ee++}for(X=h.unifiedLineStart-g.fromEnd,H=h.splitLineStart-g.fromEnd,re=h.deletionLineIndex-g.fromEnd,de=h.additionLineIndex-g.fromEnd,te=h.deletionStart-g.fromEnd,Q=h.additionStart-g.fromEnd,ee=0;ee<g.fromEnd;){if(c.isInWindow(0,0)){if(c.emit({hunkIndex:m,hunk:h,collapsedBefore:C(),collapsedAfter:0,type:"context-expanded",deletionLine:{lineNumber:te+ee,lineIndex:re+ee,noEOFCR:!1,unifiedLineIndex:X+ee,splitLineIndex:H+ee},additionLine:{unifiedLineIndex:X+ee,splitLineIndex:H+ee,lineIndex:de+ee,lineNumber:Q+ee,noEOFCR:!1}}))break e}else c.incrementCounts(1,1);ee++}}let I=h.unifiedLineStart,E=h.splitLineStart,S=h.deletionLineIndex,L=h.additionLineIndex,A=h.deletionStart,R=h.additionStart;const U=h.hunkContent.at(-1);for(const X of h.hunkContent){if(c.shouldBreak())break e;const H=X===U;if(X.type==="context"){if(c.shouldSkip(X.lines,X.lines))c.incrementCounts(X.lines,X.lines),C();else{let re=0;for(;re<X.lines;){if(c.isInWindow(0,0)){const de=H&&re===X.lines-1,te=I+re,Q=E+re;if(c.emit({hunkIndex:m,hunk:h,collapsedBefore:C(),collapsedAfter:_(te,Q),type:"context",deletionLine:{lineNumber:A+re,lineIndex:S+re,noEOFCR:de&&h.noEOFCRDeletions,unifiedLineIndex:te,splitLineIndex:Q},additionLine:{unifiedLineIndex:te,splitLineIndex:Q,lineIndex:L+re,lineNumber:R+re,noEOFCR:de&&h.noEOFCRAdditions}}))break e}else c.incrementCounts(1,1);re++}}I+=X.lines,E+=X.lines,S+=X.lines,L+=X.lines,A+=X.lines,R+=X.lines}else{const re=Math.max(X.deletions,X.additions),de=X.deletions+X.additions;if(!c.shouldSkip(de,re)){const te=kL(c,X,t);for(const[Q,ee]of te)for(let K=Q;K<ee;K++){const oe=_(I+K,t==="unified"?E+(K<X.deletions?K:K-X.deletions):E+K);if(c.emit(SL({hunkIndex:m,hunk:h,collapsedBefore:C(),collapsedAfter:oe,diffStyle:t,index:K,unifiedLineIndex:I,splitLineIndex:E,additionLineIndex:L,deletionLineIndex:S,additionLineNumber:R,deletionLineNumber:A,content:X,isLastContent:H,unifiedCount:de,splitCount:re}),!0))break e}}C(),c.incrementCounts(de,re),I+=de,E+=re,S+=X.deletions,L+=X.additions,A+=X.deletions,R+=X.additions}}if(y!=null){const{collapsedLines:X,fromStart:H,fromEnd:re}=y,de=H+re;let te=0;for(;te<de;){if(c.shouldBreak())break e;if(c.isInWindow(0,0)){const Q=te===de-1;if(c.emit({hunkIndex:e.hunks.length,hunk:void 0,collapsedBefore:0,collapsedAfter:Q?X:0,type:"context-expanded",deletionLine:{lineNumber:A+te,lineIndex:S+te,noEOFCR:!1,unifiedLineIndex:I+te,splitLineIndex:E+te},additionLine:{unifiedLineIndex:I+te,splitLineIndex:E+te,lineIndex:L+te,lineNumber:R+te,noEOFCR:!1}}))break e}else c.incrementCounts(1,1);te++}}}}function Hy(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};const s=n==null?void 0:n.get(r),l=Math.min(Math.max((s==null?void 0:s.fromStart)??0,0),t),c=Math.min(Math.max((s==null?void 0:s.fromEnd)??0,0),t),d=l+c,f=d>=t;return{fromStart:f?t:l,fromEnd:f?0:c,rangeSize:t,collapsedLines:Math.max(t-d,0)}}function _L(e){const 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 kL(e,t,n){if(!e.isWindowedHighlight)return[[0,n==="unified"?t.deletions+t.additions:Math.max(t.deletions,t.additions)]];const r=n!=="split",i=n!=="unified",s=n==="unified"?"unified":"split",l=[];function c(h,g){if(h+g<=e.viewportStart||h>=e.viewportEnd)return;const y=Math.max(0,e.viewportStart-h),w=Math.min(g,e.viewportEnd-h);return w>y?[y,w]:void 0}function d(h,g){return s==="split"?h:g==="additions"?[h[0]+t.deletions,h[1]+t.deletions]:h}function f(h,g){if(h==null)return;const[y,w]=d(h,g);w>y&&l.push([y,w])}if(r&&(f(c(e.unifiedCount,t.deletions),"deletions"),f(c(e.unifiedCount+t.deletions,t.additions),"additions")),i&&(f(c(e.splitCount,t.deletions),"deletions"),f(c(e.splitCount,t.additions),"additions")),l.length===0)return l;l.sort((h,g)=>h[0]-g[0]);const m=[l[0]];for(const[h,g]of l.slice(1)){const y=m[m.length-1];h<=y[1]?y[1]=Math.max(y[1],g):m.push([h,g])}return m}function SL({hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,diffStyle:i,index:s,unifiedLineIndex:l,splitLineIndex:c,additionLineIndex:d,deletionLineIndex:f,additionLineNumber:m,deletionLineNumber:h,content:g,isLastContent:y,unifiedCount:w,splitCount:_}){const C=s<g.deletions?l+s:void 0,I=i==="unified"?s>=g.deletions?l+s:void 0:s<g.additions?l+g.deletions+s:void 0,E=i==="unified"?c+(s<g.deletions?s:s-g.deletions):c+s,S=s<g.deletions?f+s:void 0,L=s<g.deletions?h+s:void 0,A=i==="unified"?s>=g.deletions?d+(s-g.deletions):void 0:s<g.additions?d+s:void 0,R=i==="unified"?s>=g.deletions?m+(s-g.deletions):void 0:s<g.additions?m+s:void 0,U=i==="unified"?y&&s===g.deletions-1&&t.noEOFCRDeletions:y&&s===_-1&&t.noEOFCRDeletions,X=i==="unified"?y&&s===w-1&&t.noEOFCRAdditions:y&&s===_-1&&t.noEOFCRAdditions,H=S!=null&&L!=null&&C!=null?{lineNumber:L,lineIndex:S,noEOFCR:U,unifiedLineIndex:C,splitLineIndex:E}:void 0,re=A!=null&&R!=null&&I!=null?{unifiedLineIndex:I,splitLineIndex:E,lineIndex:A,lineNumber:R,noEOFCR:X}:void 0;if(H==null&&re!=null)return{type:"change",hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:void 0,additionLine:re};if(H!=null&&re==null)return{type:"change",hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:H,additionLine:void 0};if(H==null||re==null)throw new Error("iterateOverDiff: missing change line data");return{type:"change",hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:H,additionLine:re}}class F0{diff(t,n,r={}){let i;typeof r=="function"?(i=r,r={}):"callback"in r&&(i=r.callback);const s=this.castInput(t,r),l=this.castInput(n,r),c=this.removeEmpty(this.tokenize(s,r)),d=this.removeEmpty(this.tokenize(l,r));return this.diffWithOptionsObj(c,d,r,i)}diffWithOptionsObj(t,n,r,i){var s;const l=E=>{if(E=this.postProcess(E,r),i){setTimeout(function(){i(E)},0);return}else return E},c=n.length,d=t.length;let f=1,m=c+d;r.maxEditLength!=null&&(m=Math.min(m,r.maxEditLength));const h=(s=r.timeout)!==null&&s!==void 0?s:1/0,g=Date.now()+h,y=[{oldPos:-1,lastComponent:void 0}];let w=this.extractCommon(y[0],n,t,0,r);if(y[0].oldPos+1>=d&&w+1>=c)return l(this.buildValues(y[0].lastComponent,n,t));let _=-1/0,C=1/0;const I=()=>{for(let E=Math.max(_,-f);E<=Math.min(C,f);E+=2){let S;const L=y[E-1],A=y[E+1];L&&(y[E-1]=void 0);let R=!1;if(A){const X=A.oldPos-E;R=A&&0<=X&&X<c}const U=L&&L.oldPos+1<d;if(!R&&!U){y[E]=void 0;continue}if(!U||R&&L.oldPos<A.oldPos?S=this.addToPath(A,!0,!1,0,r):S=this.addToPath(L,!1,!0,1,r),w=this.extractCommon(S,n,t,E,r),S.oldPos+1>=d&&w+1>=c)return l(this.buildValues(S.lastComponent,n,t))||!0;y[E]=S,S.oldPos+1>=d&&(C=Math.min(C,E-1)),w+1>=c&&(_=Math.max(_,E+1))}f++};if(i)(function E(){setTimeout(function(){if(f>m||Date.now()>g)return i(void 0);I()||E()},0)})();else for(;f<=m&&Date.now()<=g;){const E=I();if(E)return E}}addToPath(t,n,r,i,s){const l=t.lastComponent;return l&&!s.oneChangePerToken&&l.added===n&&l.removed===r?{oldPos:t.oldPos+i,lastComponent:{count:l.count+1,added:n,removed:r,previousComponent:l.previousComponent}}:{oldPos:t.oldPos+i,lastComponent:{count:1,added:n,removed:r,previousComponent:l}}}extractCommon(t,n,r,i,s){const l=n.length,c=r.length;let d=t.oldPos,f=d-i,m=0;for(;f+1<l&&d+1<c&&this.equals(r[d+1],n[f+1],s);)f++,d++,m++,s.oneChangePerToken&&(t.lastComponent={count:1,previousComponent:t.lastComponent,added:!1,removed:!1});return m&&!s.oneChangePerToken&&(t.lastComponent={count:m,previousComponent:t.lastComponent,added:!1,removed:!1}),t.oldPos=d,f}equals(t,n,r){return r.comparator?r.comparator(t,n):t===n||!!r.ignoreCase&&t.toLowerCase()===n.toLowerCase()}removeEmpty(t){const n=[];for(let r=0;r<t.length;r++)t[r]&&n.push(t[r]);return n}castInput(t,n){return t}tokenize(t,n){return Array.from(t)}join(t){return t.join("")}postProcess(t,n){return t}get useLongestToken(){return!1}buildValues(t,n,r){const i=[];let s;for(;t;)i.push(t),s=t.previousComponent,delete t.previousComponent,t=s;i.reverse();const l=i.length;let c=0,d=0,f=0;for(;c<l;c++){const m=i[c];if(m.removed)m.value=this.join(r.slice(f,f+m.count)),f+=m.count;else{if(!m.added&&this.useLongestToken){let h=n.slice(d,d+m.count);h=h.map(function(g,y){const w=r[f+y];return w.length>g.length?w:g}),m.value=this.join(h)}else m.value=this.join(n.slice(d,d+m.count));d+=m.count,m.added||(f+=m.count)}}return i}}class CL extends F0{}const EL=new CL;function IL(e,t,n){return EL.diff(e,t,n)}const Wy="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}";class PL extends F0{tokenize(t){const n=new RegExp(`(\\r?\\n)|[${Wy}]+|[^\\S\\n\\r]+|[^${Wy}]`,"ug");return t.match(n)||[]}}const LL=new PL;function DL(e,t,n){return LL.diff(e,t,n)}class AL extends F0{constructor(){super(...arguments),this.tokenize=RL}equals(t,n,r){return r.ignoreWhitespace?((!r.newlineIsToken||!t.includes(`
353
+ `))&&(t=t.trim()),(!r.newlineIsToken||!n.includes(`
354
+ `))&&(n=n.trim())):r.ignoreNewlineAtEof&&!r.newlineIsToken&&(t.endsWith(`
355
+ `)&&(t=t.slice(0,-1)),n.endsWith(`
356
+ `)&&(n=n.slice(0,-1))),super.equals(t,n,r)}}const TL=new AL;function Gy(e,t,n){return TL.diff(e,t,n)}function RL(e,t){t.stripTrailingCr&&(e=e.replace(/\r\n/g,`
357
+ `));const n=[],r=e.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(let i=0;i<r.length;i++){const s=r[i];i%2&&!t.newlineIsToken?n[n.length-1]+=s:n.push(s)}return n}const NL={includeIndex:!0,includeUnderline:!0,includeFileHeaders:!0};function qy(e,t,n,r,i,s,l){let c;l?typeof l=="function"?c={callback:l}:c=l:c={},typeof c.context>"u"&&(c.context=4);const d=c.context;if(c.newlineIsToken)throw new Error("newlineIsToken may not be used with patch-generation functions, only with diffing functions");if(c.callback){const{callback:m}=c;Gy(n,r,Object.assign(Object.assign({},c),{callback:h=>{const g=f(h);m(g)}}))}else return f(Gy(n,r,c));function f(m){if(!m)return;m.push({value:"",lines:[]});function h(E){return E.map(function(S){return" "+S})}const g=[];let y=0,w=0,_=[],C=1,I=1;for(let E=0;E<m.length;E++){const S=m[E],L=S.lines||ML(S.value);if(S.lines=L,S.added||S.removed){if(!y){const A=m[E-1];y=C,w=I,A&&(_=d>0?h(A.lines.slice(-d)):[],y-=_.length,w-=_.length)}for(const A of L)_.push((S.added?"+":"-")+A);S.added?I+=L.length:C+=L.length}else{if(y)if(L.length<=d*2&&E<m.length-2)for(const A of h(L))_.push(A);else{const A=Math.min(L.length,d);for(const U of h(L.slice(0,A)))_.push(U);const R={oldStart:y,oldLines:C-y+A,newStart:w,newLines:I-w+A,lines:_};g.push(R),y=0,w=0,_=[]}C+=L.length,I+=L.length}}for(const E of g)for(let S=0;S<E.lines.length;S++)E.lines[S].endsWith(`
358
+ `)?E.lines[S]=E.lines[S].slice(0,-1):(E.lines.splice(S+1,0,"\"),S++);return{oldFileName:e,newFileName:t,oldHeader:i,newHeader:s,hunks:g}}}function xg(e,t){if(t||(t=NL),Array.isArray(e)){if(e.length>1&&!t.includeFileHeaders)throw new 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(r=>xg(r,t)).join(`
359
+ `)}const n=[];t.includeIndex&&e.oldFileName==e.newFileName&&n.push("Index: "+e.oldFileName),t.includeUnderline&&n.push("==================================================================="),t.includeFileHeaders&&(n.push("--- "+e.oldFileName+(typeof e.oldHeader>"u"?"":" "+e.oldHeader)),n.push("+++ "+e.newFileName+(typeof e.newHeader>"u"?"":" "+e.newHeader)));for(let r=0;r<e.hunks.length;r++){const i=e.hunks[r];i.oldLines===0&&(i.oldStart-=1),i.newLines===0&&(i.newStart-=1),n.push("@@ -"+i.oldStart+","+i.oldLines+" +"+i.newStart+","+i.newLines+" @@");for(const s of i.lines)n.push(s)}return n.join(`
360
+ `)+`
361
+ `}function FL(e,t,n,r,i,s,l){if(typeof l=="function"&&(l={callback:l}),l!=null&&l.callback){const{callback:c}=l;qy(e,t,n,r,i,s,Object.assign(Object.assign({},l),{callback:d=>{c(d?xg(d,l.headerOptions):void 0)}}))}else{const c=qy(e,t,n,r,i,s,l);return c?xg(c,l==null?void 0:l.headerOptions):void 0}}function ML(e){const t=e.endsWith(`
362
+ `),n=e.split(`
363
+ `).map(r=>r+`
364
+ `);return t?n.pop():n.push(n.pop().slice(0,-1)),n}function Ky({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 Yd({item:e,arr:t,enableJoin:n,isNeutral:r=!1,isLastItem:i=!1}){const s=t[t.length-1];if(s==null||i||!n){t.push([r?0:1,e.value]);return}const l=s[0]===0;if(r===l||r&&e.value.length===1&&!l){s[1]+=e.value;return}t.push([r?0:1,e.value])}const OL={forcePlainText:!1};function $L(e,t,n,{forcePlainText:r,startingLine:i,totalLines:s,expandedHunks:l,collapsedContextThreshold:c=ll}=OL){r?(i??(i=0),s??(s=1/0)):(i=0,s=1/0);const d=i>0||s<1/0,f=typeof n.theme=="string"?t.getTheme(n.theme).type:void 0,m=bL({theme:n.theme,highlighter:t}),h=r&&!d&&(e.unifiedLineCount>1e3||e.splitLineCount>1e3)?"none":n.lineDiffType,g={deletionLines:[],additionLines:[]},{maxLineDiffLength:y}=n,w=!r&&!e.isPartial,_=r?l:void 0,C=new Map;function I(S){const L=w?0:S,A=C.get(L)??jL();return C.set(L,A),A}function E(S,L,A,R){if(d){let U=A.at(-1);(U==null||U.targetIndex+U.count!==L)&&(U={targetIndex:L,originalOffset:R.length,count:0},A.push(U)),U.count++}R.push(S)}Qf({diff:e,diffStyle:"both",startingLine:i,totalLines:s,expandedHunks:d?_:!0,collapsedContextThreshold:c,callback:({hunkIndex:S,additionLine:L,deletionLine:A,type:R})=>{const U=I(S),X=L!=null?L.splitLineIndex:A.splitLineIndex;R==="change"&&L!=null&&A!=null&&BL({additionLine:e.additionLines[L.lineIndex],deletionLine:e.deletionLines[A.lineIndex],deletionLineIndex:U.deletionContent.length,additionLineIndex:U.additionContent.length,deletionDecorations:U.deletionDecorations,additionDecorations:U.additionDecorations,lineDiffType:h,maxLineDiffLength:y}),A!=null&&(E(e.deletionLines[A.lineIndex],A.lineIndex,U.deletionSegments,U.deletionContent),U.deletionInfo.push({type:R==="change"?"change-deletion":R,lineNumber:A.lineNumber,altLineNumber:R==="change"?void 0:L.lineNumber??void 0,lineIndex:`${A.unifiedLineIndex},${X}`})),L!=null&&(E(e.additionLines[L.lineIndex],L.lineIndex,U.additionSegments,U.additionContent),U.additionInfo.push({type:R==="change"?"change-addition":R,lineNumber:L.lineNumber,altLineNumber:R==="change"?void 0:A.lineNumber??void 0,lineIndex:`${L.unifiedLineIndex},${X}`}))}});for(const S of C.values()){if(S.deletionContent.length===0&&S.additionContent.length===0)continue;const L={name:e.prevName??e.name,contents:S.deletionContent.value},A={name:e.name,contents:S.additionContent.value},{deletionLines:R,additionLines:U}=VL({deletionFile:L,deletionInfo:S.deletionInfo,deletionDecorations:S.deletionDecorations,additionFile:A,additionInfo:S.additionInfo,additionDecorations:S.additionDecorations,highlighter:t,options:n,languageOverride:r?"text":e.lang});if(w){g.deletionLines=R,g.additionLines=U;continue}if(S.deletionSegments.length>0)for(const X of S.deletionSegments)for(let H=0;H<X.count;H++)g.deletionLines[X.targetIndex+H]=R[X.originalOffset+H];else g.deletionLines.push(...R);if(S.additionSegments.length>0)for(const X of S.additionSegments)for(let H=0;H<X.count;H++)g.additionLines[X.targetIndex+H]=U[X.originalOffset+H];else g.additionLines.push(...U)}return{code:g,themeStyles:m,baseThemeType:f}}function BL({deletionLine:e,additionLine:t,deletionLineIndex:n,additionLineIndex:r,deletionDecorations:i,additionDecorations:s,lineDiffType:l,maxLineDiffLength:c}){if(e==null||t==null||l==="none"||(e=Dl(e),t=Dl(t),e.length>c||t.length>c))return;const d=l==="char"?IL(e,t):DL(e,t),f=[],m=[],h=l==="word-alt",g=d.at(-1);for(const w of d){const _=w===g;!w.added&&!w.removed?(Yd({item:w,arr:f,enableJoin:h,isNeutral:!0,isLastItem:_}),Yd({item:w,arr:m,enableJoin:h,isNeutral:!0,isLastItem:_})):w.removed?Yd({item:w,arr:f,enableJoin:h,isLastItem:_}):Yd({item:w,arr:m,enableJoin:h,isLastItem:_})}let y=0;for(const w of f)w[0]===1&&i.push(Ky({line:n,spanStart:y,spanLength:w[1].length})),y+=w[1].length;y=0;for(const w of m)w[0]===1&&s.push(Ky({line:r,spanStart:y,spanLength:w[1].length})),y+=w[1].length}function jL(){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 VL({deletionFile:e,additionFile:t,deletionInfo:n,additionInfo:r,highlighter:i,deletionDecorations:s,additionDecorations:l,languageOverride:c,options:{theme:d=Ai,...f}}){const m=c??ia(e.name),h=c??ia(t.name),{state:g,transformers:y}=yL(f.useTokenTransformer),w=typeof d=="string"?{...f,lang:"text",theme:d,transformers:y,decorations:void 0,defaultColor:!1,cssVariablePrefix:ei("token")}:{...f,lang:"text",themes:d,transformers:y,decorations:void 0,defaultColor:!1,cssVariablePrefix:ei("token")};return{deletionLines:e.contents===""?[]:(w.lang=m,g.lineInfo=n,w.decorations=s,Uy(i.codeToHast(Dl(e.contents),w))),additionLines:t.contents===""?[]:(w.lang=h,w.decorations=l,g.lineInfo=r,Uy(i.codeToHast(Dl(t.contents),w)))}}const UL=B.createContext(void 0);function zL(e){const t=B.useRef(e);return B.useInsertionEffect(()=>void(t.current=e)),B.useCallback((...n)=>t.current(...n),[])}function HL(e,t){return e.lineNumber===t.lineNumber&&e.side===t.side}function Xy(e,t){return(e==null?void 0:e.start)===(t==null?void 0:t.start)&&(e==null?void 0:e.end)===(t==null?void 0:t.end)&&(e==null?void 0:e.side)===(t==null?void 0:t.side)&&(e==null?void 0:e.endSide)===(t==null?void 0:t.endSide)}function WL(){return Ye({tagName:"button",properties:{"data-utility-button":"",type:"button"},children:[Xf({name:"diffs-icon-plus",properties:{"data-icon":""}})]})}var GL=class{constructor(e,t){F(this,"hoveredLine");F(this,"hoveredToken");F(this,"pre");F(this,"gutterUtilityContainer");F(this,"gutterUtilityButton");F(this,"gutterUtilitySlot");F(this,"interactiveLinesAttr",!1);F(this,"interactiveLineNumbersAttr",!1);F(this,"hasPointerListeners",!1);F(this,"hasDocumentPointerListeners",!1);F(this,"selectedRange",null);F(this,"renderedSelectionRange");F(this,"selectionAnchor");F(this,"queuedSelectionRender");F(this,"pointerSession",{mode:"idle"});F(this,"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}}});F(this,"handlePointerClick",e=>{const{onHunkExpand:t,onLineClick:n,onLineNumberClick:r,onTokenClick:i,onMergeConflictActionClick:s}=this.options;t==null&&n==null&&r==null&&s==null&&i==null||this.options.onGutterUtilityClick!=null&&ew(e.composedPath())||(to(this.options.__debugPointerEvents,"click","FileDiff.DEBUG.handlePointerClick:",e),this.handlePointerEvent({eventType:"click",event:e}))});F(this,"handlePointerMove",e=>{const{lineHoverHighlight:t="disabled",onLineEnter:n,onLineLeave:r,onTokenEnter:i,onTokenLeave:s,enableGutterUtility:l=!1}=this.options;t==="disabled"&&!l&&n==null&&r==null&&i==null&&s==null||(to(this.options.__debugPointerEvents,"move","FileDiff.DEBUG.handlePointerMove:",e),this.handlePointerEvent({eventType:"move",event:e}))});F(this,"handlePointerLeave",e=>{var n,r,i,s,l;const{__debugPointerEvents:t}=this.options;if(to(t,"move","FileDiff.DEBUG.handlePointerLeave: no event"),this.hoveredLine==null&&this.hoveredToken==null){to(t,"move","FileDiff.DEBUG.handlePointerLeave: returned early, no hovered line or token");return}(n=this.gutterUtilityContainer)==null||n.remove(),this.hoveredToken!=null&&((i=(r=this.options).onTokenLeave)==null||i.call(r,this.hoveredToken,e),this.clearHoveredToken()),this.hoveredLine!=null&&((l=(s=this.options).onLineLeave)==null||l.call(s,{...this.hoveredLine,event:e}),this.clearHoveredLine())});F(this,"handlePointerDown",e=>{if(e.pointerType==="mouse"&&e.button!==0||this.pre==null||this.pointerSession.mode!=="idle")return;const t=e.composedPath();ew(t)&&this.options.onGutterUtilityClick!=null?this.startGutterSelectionFromPointerDown(e,t):this.startLineSelectionFromPointerDown(e,t)});F(this,"handleDocumentPointerMove",e=>{const{enableLineSelection:t=!1}=this.options;switch(this.pointerSession.mode){case"idle":return;case"gutterSelecting":{if(e.pointerId!==this.pointerSession.pointerId)return;const 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;const n=this.getSelectionPointerInfo(e.composedPath(),!1);if(n==null||this.selectionAnchor==null)return;this.updateSelection(n.lineNumber,n.eventSide);return}case"pendingSingleLineUnselect":{if(e.pointerId!==this.pointerSession.pointerId)return;const n=this.getSelectionPointerInfo(e.composedPath(),!1);if(n==null||this.selectionAnchor==null)return;const r={lineNumber:n.lineNumber,side:n.eventSide};if(HL(this.pointerSession.pending,r))return;this.updateSelection(n.lineNumber,n.eventSide,!1),this.notifySelectionStart(this.selectedRange),this.notifySelectionChangeDelta(),this.pointerSession={mode:"selecting",pointerId:e.pointerId};return}}});F(this,"handleDocumentPointerUp",e=>{const{enableLineSelection:t=!1,onGutterUtilityClick:n}=this.options;switch(this.pointerSession.mode){case"idle":return;case"gutterSelecting":{if(e.pointerId!==this.pointerSession.pointerId)return;const r=this.getSelectionPointFromPath(e.composedPath());r!=null&&(this.pointerSession.current=r,t&&this.updateSelection(r.lineNumber,r.side)),n==null||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()}});F(this,"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()}});F(this,"renderSelection",()=>{if(this.queuedSelectionRender!=null&&(cancelAnimationFrame(this.queuedSelectionRender),this.queuedSelectionRender=void 0),this.pre==null||this.renderedSelectionRange===this.selectedRange)return;const e=this.pre.querySelectorAll("[data-selected-line]");for(const c of e)c.removeAttribute("data-selected-line");if(this.renderedSelectionRange=this.selectedRange,this.selectedRange==null)return;const{children:t}=this.pre;if(t.length===0)return;if(t.length>2)throw console.error(t),new Error("InteractionManager.renderSelection: Somehow there are more than 2 code elements...");const 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}),new Error("InteractionManager.renderSelection: No valid rowRange");const i=r.start===r.end,s=Math.min(r.start,r.end),l=Math.max(r.start,r.end);for(const c of t){const[d,f]=c.children,m=f.children.length;if(m!==d.children.length)throw new Error("InteractionManager.renderSelection: gutter and content children dont match, something is wrong");for(let h=0;h<m;h++){const g=f.children[h],y=d.children[h];if(!(g instanceof HTMLElement)||!(y instanceof HTMLElement))continue;const w=this.parseLineIndex(g,n);if((w??0)>l)break;if(w==null||w<s)continue;let _=i?"single":w===s?"first":w===l?"last":"";g.setAttribute("data-selected-line",_),y.setAttribute("data-selected-line",_),y.nextSibling instanceof HTMLElement&&g.nextSibling instanceof HTMLElement&&(g.nextSibling.hasAttribute("data-line-annotation")||g.nextSibling.hasAttribute("data-merge-conflict-actions"))&&(i?(_="last",g.setAttribute("data-selected-line","first")):w===s?_="":w===l&&g.setAttribute("data-selected-line",""),g.nextSibling.setAttribute("data-selected-line",_),y.nextSibling.setAttribute("data-selected-line",_))}}});this.mode=e,this.options=t}setOptions(e){this.options=e}cleanUp(){var e,t,n,r,i,s,l;(e=this.pre)==null||e.removeEventListener("click",this.handlePointerClick),(t=this.pre)==null||t.removeEventListener("pointerdown",this.handlePointerDown),(n=this.pre)==null||n.removeEventListener("pointermove",this.handlePointerMove),(r=this.pre)==null||r.removeEventListener("pointerleave",this.handlePointerLeave),(i=this.pre)==null||i.removeAttribute("data-interactive-lines"),(s=this.pre)==null||s.removeAttribute("data-interactive-line-numbers"),this.pre=void 0,(l=this.gutterUtilityContainer)==null||l.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();const{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){const t=!(e===this.selectedRange||Xy(e??void 0,this.selectedRange??void 0));!this.isSelectionDirty()&&!t||(this.selectedRange=e,this.renderSelection(),t&&this.notifySelectionCommitted())}getSelection(){return this.selectedRange}handlePointerEvent({eventType:e,event:t}){var w,_,C;const{__debugPointerEvents:n}=this.options,r=t.composedPath();to(n,e,"FileDiff.DEBUG.handlePointerEvent:",{eventType:e,composedPath:r});const i=this.resolvePointerTarget(r);to(n,e,"FileDiff.DEBUG.handlePointerEvent: resolvePointerTarget result:",i);const{onLineClick:s,onLineNumberClick:l,onLineEnter:c,onLineLeave:d,onTokenClick:f,onTokenEnter:m,onTokenLeave:h,onHunkExpand:g,onMergeConflictActionClick:y}=this.options;switch(e){case"move":{const I=Pm(i)&&((w=this.hoveredLine)==null?void 0:w.lineElement)===i.lineElement;gf(i)&&((_=this.hoveredToken)==null?void 0:_.tokenElement)===i.tokenElement||(this.hoveredToken!=null&&(h==null||h(this.hoveredToken,t),this.clearHoveredToken()),gf(i)&&(this.setHoveredToken(this.toTokenEventBaseProps(i)),m==null||m(this.hoveredToken,t))),I||(this.hoveredLine!=null&&((C=this.gutterUtilityContainer)==null||C.remove(),d==null||d({...this.hoveredLine,event:t}),this.clearHoveredLine()),Pm(i)&&(this.setHoveredLine(this.toEventBaseProps(i)),this.gutterUtilityContainer!=null&&i.numberElement.appendChild(this.gutterUtilityContainer),c==null||c({...this.hoveredLine,event:t})));break}case"click":{if(i==null)break;if(XL(i)&&y!=null){y(i);break}if(KL(i)&&g!=null){g(i.hunkIndex,i.all||t.shiftKey?"both":i.direction,i.all||t.shiftKey?Number.POSITIVE_INFINITY:void 0);break}if(!Pm(i))break;gf(i)&&f!=null&&f(this.toTokenEventBaseProps(i),t);const I=this.toEventBaseProps(i);l!=null&&i.numberColumn?l({...I,event:t}):s!=null&&s({...I,event:t});break}}}syncPointerListeners(e){const{__debugPointerEvents:t,lineHoverHighlight:n="disabled",onLineClick:r,onLineNumberClick:i,onLineEnter:s,onLineLeave:l,onTokenClick:c,onTokenEnter:d,onTokenLeave:f,onHunkExpand:m,onMergeConflictActionClick:h,enableGutterUtility:g=!1,enableLineSelection:y=!1,onGutterUtilityClick:w}=this.options,_=w!=null,C=n!=="disabled"||r!=null||i!=null||s!=null||l!=null||c!=null||d!=null||f!=null||m!=null||h!=null||g||y||_;C&&!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,to(t,"click","FileDiff.DEBUG.attachEventListeners: Attaching click events for:",(()=>{const S=[];return(t==="both"||t==="click")&&(r!=null&&S.push("onLineClick"),i!=null&&S.push("onLineNumberClick"),m!=null&&S.push("expandable hunk separators"),h!=null&&S.push("merge conflict actions")),S})()),to(t,"move","FileDiff.DEBUG.attachEventListeners: Attaching pointer move event"),to(t,"move","FileDiff.DEBUG.attachEventListeners: Attaching pointer leave event")):!C&&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);const I=this.pointerSession.mode==="selecting"||this.pointerSession.mode==="pendingSingleLineUnselect",E=this.pointerSession.mode==="gutterSelecting";(!y&&I||!_&&E)&&(this.clearPointerSession(),this.detachDocumentPointerListeners(),this.selectionAnchor=void 0,this.clearPendingSingleLineState())}updateInteractiveLineAttributes(){if(this.pre==null)return;const{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)}startLineSelectionFromPointerDown(e,t){var d,f;const{enableLineSelection:n=!1}=this.options;if(!n)return;const r=this.getSelectionPointerInfo(t,!0);if(r==null)return;const{pre:i}=this;if(i==null)return;e.preventDefault();const{lineNumber:s,eventSide:l,lineIndex:c}=r;if(e.shiftKey&&this.selectedRange!=null){const m=this.getIndexesFromSelection(this.selectedRange,i.getAttribute("data-diff-type")==="split");if(m==null)return;const h=m.start<=m.end?c>=m.start:c<=m.end;this.selectionAnchor={lineNumber:h?this.selectedRange.start:this.selectedRange.end,side:h?this.selectedRange.side:this.selectedRange.endSide??this.selectedRange.side},this.updateSelection(s,l,!1),this.notifySelectionStart(this.selectedRange),this.pointerSession={mode:"selecting",pointerId:e.pointerId},this.attachDocumentPointerListeners();return}if(((d=this.selectedRange)==null?void 0:d.start)===s&&((f=this.selectedRange)==null?void 0:f.end)===s){const m={lineNumber:s,side:l};this.selectionAnchor=m,this.pointerSession={mode:"pendingSingleLineUnselect",pointerId:e.pointerId,anchor:m,pending:m},this.attachDocumentPointerListeners();return}this.selectedRange=null,this.selectionAnchor={lineNumber:s,side:l},this.updateSelection(s,l,!1),this.notifySelectionStart(this.selectedRange),this.pointerSession={mode:"selecting",pointerId:e.pointerId},this.attachDocumentPointerListeners()}startGutterSelectionFromPointerDown(e,t){const{enableLineSelection:n=!1,onGutterUtilityClick:r}=this.options;if(r==null)return;const 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())}clearHoveredLine(){this.hoveredLine!=null&&(this.hoveredLine.lineElement.removeAttribute("data-hovered"),this.hoveredLine.numberElement.removeAttribute("data-hovered"),this.hoveredLine=void 0)}setHoveredLine(e){const{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){var t;if(this.gutterUtilityContainer==null&&(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==null&&(this.gutterUtilitySlot=document.createElement("slot"),this.gutterUtilitySlot.name="gutter-utility-slot"),this.gutterUtilitySlot.parentNode!==this.gutterUtilityContainer&&this.gutterUtilityContainer.replaceChildren(this.gutterUtilitySlot);else{if((t=this.gutterUtilitySlot)==null||t.remove(),this.gutterUtilitySlot=void 0,this.gutterUtilityButton==null){const n=document.createElement("div");n.innerHTML=dl(WL());const r=n.firstElementChild;if(!(r instanceof HTMLButtonElement))throw new Error("InteractionManager.ensureGutterUtilityNode: Node element should be a button");r.remove(),this.gutterUtilityButton=r}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),this.hasDocumentPointerListeners=!0)}detachDocumentPointerListeners(){this.hasDocumentPointerListeners&&(document.removeEventListener("pointermove",this.handleDocumentPointerMove),document.removeEventListener("pointerup",this.handleDocumentPointerUp),document.removeEventListener("pointercancel",this.handleDocumentPointerCancel),this.hasDocumentPointerListeners=!1)}clearPointerSession(){this.pointerSession={mode:"idle"}}clearPendingSingleLineState(){this.pointerSession.mode==="pendingSingleLineUnselect"&&(this.pointerSession={mode:"idle"})}getSelectionPointerInfo(e,t){const n=this.resolvePointerTarget(e);if(_g(n)&&!(t&&!n.numberColumn)&&n.splitLineIndex!=null)return{lineIndex:n.splitLineIndex,lineNumber:n.lineNumber,eventSide:this.mode==="diff"?n.side:void 0}}getSelectionPointFromPath(e){const t=this.resolvePointerTarget(e);if(_g(t))return{lineNumber:t.lineNumber,side:this.mode==="diff"?t.side:void 0}}getLineIndex(e,t){const{getLineIndex:n}=this.options;return n!=null?n(e,t):[e-1,e-1]}updateSelection(e,t,n=!0){var s,l;const{selectedRange:r}=this;let i;if(e==null)i=null;else{const c=((s=this.selectionAnchor)==null?void 0:s.side)??t,d=((l=this.selectionAnchor)==null?void 0:l.lineNumber)??e;i=this.buildSelectionRange(d,e,c,t)}Xy(r??void 0,i??void 0)||(this.selectedRange=i,n&&this.notifySelectionChangeDelta(),this.queuedSelectionRender??(this.queuedSelectionRender=requestAnimationFrame(this.renderSelection)))}getIndexesFromSelection(e,t){if(this.pre==null)return;const 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}notifySelectionCommitted(){var e,t;(t=(e=this.options).onLineSelected)==null||t.call(e,this.selectedRange??null)}notifySelectionChangeDelta(){var e,t;(t=(e=this.options).onLineSelectionChange)==null||t.call(e,this.selectedRange??null)}notifySelectionStart(e){var t,n;(n=(t=this.options).onLineSelectionStart)==null||n.call(t,e)}notifySelectionEnd(e){var t,n;(n=(t=this.options).onLineSelectionEnd)==null||n.call(t,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:s}){return this.mode==="file"?{type:"token",lineCharEnd:e,lineCharStart:t,lineNumber:n,tokenElement:i,tokenText:s}:{type:"token",lineCharEnd:e,lineCharStart:t,lineNumber:n,side:r,tokenElement:i,tokenText:s}}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,s,l,c,d,f,m,h;for(const y of e){if(!(y instanceof HTMLElement))continue;if(h==null&&y.hasAttribute("data-merge-conflict-action")){const I=y.getAttribute("data-merge-conflict-action")??void 0,E=y.getAttribute("data-merge-conflict-conflict-index")??void 0,S=E!=null?Number.parseInt(E,10):NaN;QL(I)&&Number.isFinite(S)&&(h={kind:"merge-conflict-action",resolution:I,conflictIndex:S})}if(c==null&&y.hasAttribute("data-char")){c=y;const I=y.getAttribute("data-char");if(I!=null){const E=Number.parseInt(I,10);if(!Number.isNaN(E)){const S=y.textContent??"",L=E+S.length;(S.trim()!==""||this.options.enableTokenInteractionsOnWhitespace===!0)&&(d={tokenElement:c,lineCharStart:E,lineCharEnd:L,tokenText:S});continue}}}const w=l==null?y.getAttribute("data-column-number")??void 0:void 0;if(w!=null){l=y,m=Number.parseInt(w,10),t=!0,n=Zy(y),s=y.getAttribute("data-line-index")??void 0;continue}const _=i==null?y.getAttribute("data-line")??void 0:void 0;if(_!=null){i=y,m=Number.parseInt(_,10),n=Zy(y),s=y.getAttribute("data-line-index")??void 0;continue}if(f==null&&(y.hasAttribute("data-expand-button")||y.hasAttribute("data-unmodified-lines"))){f={hunkIndex:void 0,direction:y.hasAttribute("data-expand-up")?"up":y.hasAttribute("data-expand-down")?"down":"both",all:y.hasAttribute("data-expand-all-button")};continue}const C=f!=null?y.getAttribute("data-expand-index")??void 0:void 0;if(f!=null&&C!=null){const I=Number.parseInt(C,10);Number.isNaN(I)||(f.hunkIndex=I);continue}if(r==null&&y.hasAttribute("data-code")){r=y;break}}if(h!=null)return h;if((f==null?void 0:f.hunkIndex)!=null)return{type:"line-info",hunkIndex:f.hunkIndex,direction:f.direction,all:f.all};if(i??(i=s!=null?Yy(r,`[data-line][data-line-index="${s}"]`):void 0),l??(l=s!=null?Yy(r,`[data-column-number][data-line-index="${s}"]`):void 0),r==null||i==null||l==null||n==null||m==null||Number.isNaN(m))return;const g=this.parseLineIndex(i,this.isSplitDiff());return d!=null?this.mode==="file"?{kind:"token",lineType:n,lineElement:i,lineNumber:m,numberColumn:t,numberElement:l,side:void 0,splitLineIndex:g,...d}:{kind:"token",lineType:n,lineElement:i,lineNumber:m,numberColumn:t,numberElement:l,side:Jy(n,r),splitLineIndex:g,...d}:this.mode==="file"?{kind:"line",lineType:n,lineElement:i,lineNumber:m,numberColumn:t,numberElement:l,side:void 0,splitLineIndex:g}:{kind:"line",lineType:n,lineElement:i,lineNumber:m,numberColumn:t,numberElement:l,side:Jy(n,r),splitLineIndex:g}}isSplitDiff(){var e;return((e=this.pre)==null?void 0:e.getAttribute("data-diff-type"))==="split"}parseLineIndex(e,t){const n=(e.getAttribute("data-line-index")??"").split(",").map(r=>Number.parseInt(r,10)).filter(r=>!Number.isNaN(r));if(t&&n.length===2)return n[1];if(!t)return n[0]}};function Qy({enableTokenInteractionsOnWhitespace:e,enableGutterUtility:t,enableHoverUtility:n,lineHoverHighlight:r,onGutterUtilityClick:i,onLineClick:s,onLineEnter:l,onLineLeave:c,onLineNumberClick:d,onTokenClick:f,onTokenEnter:m,onTokenLeave:h,renderGutterUtility:g,renderHoverUtility:y,__debugPointerEvents:w,enableLineSelection:_,onLineSelected:C,onLineSelectionStart:I,onLineSelectionChange:E,onLineSelectionEnd:S},L,A,R){return{enableTokenInteractionsOnWhitespace:e,enableGutterUtility:qL({enableGutterUtility:t,enableHoverUtility:n,renderGutterUtility:g,renderHoverUtility:y,onGutterUtilityClick:i}),usesCustomGutterUtility:g!=null||y!=null,lineHoverHighlight:r,onGutterUtilityClick:i,onHunkExpand:L,onMergeConflictActionClick:R,onLineClick:s,onLineEnter:l,onLineLeave:c,onLineNumberClick:d,onTokenClick:f,onTokenEnter:m,onTokenLeave:h,__debugPointerEvents:w,enableLineSelection:_,onLineSelected:C,onLineSelectionStart:I,onLineSelectionChange:E,onLineSelectionEnd:S,getLineIndex:A}}function qL({enableGutterUtility:e,enableHoverUtility:t,renderGutterUtility:n,renderHoverUtility:r,onGutterUtilityClick:i}){if(e!==void 0&&t!==void 0)throw new Error("Cannot use both 'enableGutterUtility' and deprecated 'enableHoverUtility'. Use only 'enableGutterUtility'.");if(n!=null&&r!=null)throw new Error("Cannot use both 'renderGutterUtility' and deprecated 'renderHoverUtility'. Use only 'renderGutterUtility'.");if(i!=null&&(n!=null||r!=null))throw new Error("Cannot use both 'onGutterUtilityClick' and render utility callbacks ('renderGutterUtility'/'renderHoverUtility'). Use only one gutter utility API.");return e??t??!1}function _g(e){return e!=null&&"kind"in e&&e.kind==="line"}function gf(e){return e!=null&&"kind"in e&&e.kind==="token"}function Pm(e){return _g(e)||gf(e)}function KL(e){return"type"in e&&e.type==="line-info"}function XL(e){return"kind"in e&&e.kind==="merge-conflict-action"}function QL(e){return e==="current"||e==="incoming"||e==="both"}function Yy(e,t){const n=e==null?void 0:e.querySelector(t);return n instanceof HTMLElement?n:void 0}function Jy(e,t){switch(e){case"change-deletion":return"deletions";case"change-addition":return"additions";default:return t.hasAttribute("data-deletions")?"deletions":"additions"}}function Zy(e){const 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 ew(e){for(const t of e)if(t instanceof HTMLElement&&t.hasAttribute("data-utility-button"))return!0;return!1}function to(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 YL=class{constructor(){F(this,"observedNodes",new Map);F(this,"queuedUpdates",new Map);F(this,"resizeObserver");F(this,"handleResizeObserver",e=>{for(const t of e){const{target:n,borderBoxSize:r,contentBoxSize:i}=t;if(!(n instanceof HTMLElement)){console.error("FileDiff.handleResizeObserver: Invalid element for ResizeObserver",t);continue}const s=this.observedNodes.get(n);if(s==null){console.error("FileDiff.handleResizeObserver: Not a valid observed node",t);continue}if(s.type==="annotations"){const l=(()=>{if(n===s.column1.child)return s.column1;if(n===s.column2.child)return s.column2})();if(l==null){console.error("FileDiff.handleResizeObserver: Couldn't find a column for",{item:s,target:n});continue}l.childHeight=r[0].blockSize;const c=Math.max(s.column1.childHeight,s.column2.childHeight);this.applyNewHeight(s,c)}else if(s.type==="code"){const l=[n,i[0].inlineSize],c=this.queuedUpdates.get(s)??[];c.push(l),this.queuedUpdates.set(s,c)}}this.handleColumnChange()});F(this,"handleColumnChange",()=>{for(const[e,t]of this.queuedUpdates)for(const[n,r]of t)if(n===e.codeElement){const i=Math.max(Math.floor(r),0);if(i!==e.codeWidth){const s=Math.max(i-e.numberWidth,0);e.codeWidth=i===0?"auto":i,e.codeElement.style.setProperty("--diffs-column-content-width",`${s>0?`${s}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){const i=Math.max(Math.ceil(r),0);if(i!==e.numberWidth&&(e.numberWidth=i,e.codeElement.style.setProperty("--diffs-column-number-width",`${e.numberWidth===0?"auto":`${e.numberWidth}px`}`),e.codeWidth!=="auto")){const s=Math.max(e.codeWidth-e.numberWidth,0);e.codeElement.style.setProperty("--diffs-column-content-width",`${s===0?"auto":`${s}px`}`)}}this.queuedUpdates.clear()})}cleanUp(){var e;(e=this.resizeObserver)==null||e.disconnect(),this.observedNodes.clear(),this.queuedUpdates.clear()}setup(e,t){this.resizeObserver??(this.resizeObserver=new ResizeObserver(this.handleResizeObserver));const n=e.querySelectorAll("code"),r=new Map(this.observedNodes);this.observedNodes.clear();for(const i of n){let s=r.get(i);if(s!=null&&s.type!=="code")throw new Error("ResizeManager.setup: somehow a code node is being used for an annotation, should be impossible");let l=i.firstElementChild;l instanceof HTMLElement||(l=null),s!=null?(this.observedNodes.set(i,s),r.delete(i),s.numberElement!==l?(s.numberElement!=null&&this.resizeObserver.unobserve(s.numberElement),l!=null&&(this.resizeObserver.observe(l),r.delete(l),this.observedNodes.set(l,s)),s.numberElement=l):s.numberElement!=null&&(r.delete(s.numberElement),this.observedNodes.set(s.numberElement,s))):(s={type:"code",codeElement:i,numberElement:l,codeWidth:"auto",numberWidth:0},this.observedNodes.set(i,s),this.resizeObserver.observe(i),l!=null&&(this.observedNodes.set(l,s),this.resizeObserver.observe(l)))}if(n.length>1&&!t){const i=e.querySelectorAll('[data-line-annotation*=","]'),s=new Map;for(const l of i){if(!(l instanceof HTMLElement))continue;const{lineAnnotation:c=""}=l.dataset;if(!/^\d+,\d+$/.test(c)){console.error("DiffFileRenderer.setupResizeObserver: Invalid element or annotation",{lineAnnotation:c,element:l});continue}let d=s.get(c);d==null&&(d=[],s.set(c,d)),d.push(l)}for(const[l,c]of s){if(c.length!==2){console.error("DiffFileRenderer.setupResizeObserver: Bad Pair",l,c);continue}const[d,f]=c,m=d.firstElementChild,h=f.firstElementChild;if(!(d instanceof HTMLElement)||!(f instanceof HTMLElement)||!(m instanceof HTMLElement)||!(h instanceof HTMLElement))continue;let g=r.get(m);if(g!=null){this.observedNodes.set(m,g),this.observedNodes.set(h,g),r.delete(m),r.delete(h);continue}g={type:"annotations",column1:{container:d,child:m,childHeight:m.getBoundingClientRect().height},column2:{container:f,child:h,childHeight:h.getBoundingClientRect().height},currentHeight:"auto"};const y=Math.max(g.column1.childHeight,g.column2.childHeight);this.applyNewHeight(g,y),this.observedNodes.set(m,g),this.observedNodes.set(h,g),this.resizeObserver.observe(m),this.resizeObserver.observe(h)}}for(const i of r.keys())i.isConnected&&(i.style.removeProperty("--diffs-column-content-width"),i.style.removeProperty("--diffs-column-number-width"),i.style.removeProperty("--diffs-column-width"),i.parentElement instanceof HTMLElement&&i.parentElement.style.removeProperty("--diffs-annotation-min-height")),this.resizeObserver.unobserve(i);r.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 F_(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 tw(e){for(const t of Array.isArray(e)?e:[e])if(!(t==="text"||t==="ansi")&&!ng.has(t))return!1;return!0}function Lm(e){for(const t of T_(e))if(!tg.has(t))return!1;return!0}function JL(e){var t;return Ye({tagName:"div",children:[Ye({tagName:"div",children:(t=e.annotations)==null?void 0:t.map(n=>Ye({tagName:"slot",properties:{name:n}})),properties:{"data-annotation-content":""}})],properties:{"data-line-annotation":`${e.hunkIndex},${e.lineIndex}`}})}function ZL(e,t){return Ye({tagName:"div",children:e,properties:{"data-content":"",style:`grid-row: span ${t}`}})}function eD(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 tD({fileOrDiff:e,mode:t}){const n="type"in e?e:void 0,r={"data-diffs-header":t,"data-change-type":n==null?void 0:n.type};return Ye({tagName:"div",children:[t==="custom"?Ye({tagName:"slot",properties:{name:w0}}):nD({name:e.name,prevName:"prevName"in e?e.prevName:void 0,iconType:(n==null?void 0:n.type)??"file"}),...t==="custom"?[]:[rD(n)]],properties:r})}function nD({name:e,prevName:t,iconType:n}){const r=[Ye({tagName:"slot",properties:{name:v0}}),Xf({name:eD(n),properties:{"data-change-icon":n}})];return t!=null&&(r.push(Ye({tagName:"div",children:[Ye({tagName:"bdi",children:[Ni(t)]})],properties:{"data-prev-name":""}})),r.push(Xf({name:"diffs-icon-arrow-right-short",properties:{"data-rename-icon":""}}))),r.push(Ye({tagName:"div",children:[Ye({tagName:"bdi",children:[Ni(e)]})],properties:{"data-title":""}})),Ye({tagName:"div",children:r,properties:{"data-header-content":""}})}function rD(e){const t=[];if(e!=null){let n=0,r=0;for(const i of e.hunks)n+=i.additionLines,r+=i.deletionLines;(r>0||n===0)&&t.push(Ye({tagName:"span",children:[Ni(`-${r}`)],properties:{"data-deletions-count":""}})),(n>0||r===0)&&t.push(Ye({tagName:"span",children:[Ni(`+${n}`)],properties:{"data-additions-count":""}}))}return t.push(Ye({tagName:"slot",properties:{name:y0}})),Ye({tagName:"div",children:t,properties:{"data-metadata":""}})}function iD(e){return Ye({tagName:"pre",properties:oD(e)})}function oD({diffIndicators:e,disableBackground:t,disableLineNumbers:n,overflow:r,split:i,totalLines:s,type:l,customProperties:c}){return{...c,"data-diff":l==="diff"?"":void 0,"data-file":l==="file"?"":void 0,"data-diff-type":l==="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:${`${s}`.length}ch;`}}function sD(e,{theme:t,preferredHighlighter:n="shiki-js"}){return{langs:[e??"text"],themes:T_(t),preferredHighlighter:n}}function aD(e){return e.useTokenTransformer===!0||e.onTokenClick!=null||e.onTokenEnter!=null||e.onTokenLeave!=null}const lD=`<svg data-icon-sprite aria-hidden="true" width="0" height="0">
365
+ <symbol id="diffs-icon-arrow-right-short" viewBox="0 0 16 16">
366
+ <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"/>
367
+ </symbol>
368
+ <symbol id="diffs-icon-brand-github" viewBox="0 0 16 16">
369
+ <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"/>
370
+ </symbol>
371
+ <symbol id="diffs-icon-chevron" viewBox="0 0 16 16">
372
+ <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"/>
373
+ </symbol>
374
+ <symbol id="diffs-icon-chevrons-narrow" viewBox="0 0 10 16">
375
+ <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"/>
376
+ </symbol>
377
+ <symbol id="diffs-icon-diff-split" viewBox="0 0 16 16">
378
+ <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"/>
379
+ </symbol>
380
+ <symbol id="diffs-icon-diff-unified" viewBox="0 0 16 16">
381
+ <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"/>
382
+ </symbol>
383
+ <symbol id="diffs-icon-expand" viewBox="0 0 16 16">
384
+ <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"/>
385
+ </symbol>
386
+ <symbol id="diffs-icon-expand-all" viewBox="0 0 16 16">
387
+ <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"/>
388
+ </symbol>
389
+ <symbol id="diffs-icon-file-code" viewBox="0 0 16 16">
390
+ <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"/>
391
+ </symbol>
392
+ <symbol id="diffs-icon-plus" viewBox="0 0 16 16">
393
+ <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"/>
394
+ </symbol>
395
+ <symbol id="diffs-icon-symbol-added" viewBox="0 0 16 16">
396
+ <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"/>
397
+ </symbol>
398
+ <symbol id="diffs-icon-symbol-deleted" viewBox="0 0 16 16">
399
+ <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"/>
400
+ </symbol>
401
+ <symbol id="diffs-icon-symbol-diffstat" viewBox="0 0 16 16">
402
+ <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"/>
403
+ </symbol>
404
+ <symbol id="diffs-icon-symbol-ignored" viewBox="0 0 16 16">
405
+ <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"/>
406
+ </symbol>
407
+ <symbol id="diffs-icon-symbol-modified" viewBox="0 0 16 16">
408
+ <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"/>
409
+ </symbol>
410
+ <symbol id="diffs-icon-symbol-moved" viewBox="0 0 16 16">
411
+ <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"/>
412
+ </symbol>
413
+ <symbol id="diffs-icon-symbol-ref" viewBox="0 0 16 16">
414
+ <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"/>
415
+ </symbol>
416
+ </svg>`;function cD(e,t){return e==null||t==null?e===t:uD(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}const nw={};function uD(e=nw,t=nw){if(e===t)return!0;const n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(const i of n)if(e[i]!==t[i])return!1;return!0}function dD(e){const t=document.createElement("div");return t.dataset.annotationSlot="",t.slot=e,t.style.whiteSpace="normal",t}function fD(){const 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 hD(){const e=document.createElement("style");return e.setAttribute(vx,""),e}var pD='@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;';const M_="@layer base, theme, rendered, unsafe;";function mD(e){return`${M_}
417
+ @layer unsafe {
418
+ ${e}
419
+ }`}function gD(e,t="system"){return`${M_}
420
+ @layer rendered {
421
+ :host {${t==="system"?"":`
422
+ color-scheme: ${t};`}
423
+ ${e}
424
+ }
425
+ }`}function Dm({code:e,pre:t,columnType:n,rowSpan:r,containerSize:i=!1}={}){return e==null&&(e=document.createElement("code"),e.setAttribute("data-code",""),n!=null&&e.setAttribute(`data-${n}`,""),t==null||t.appendChild(e)),r!=null?e.style.setProperty("grid-row",`span ${r}`):e.style.removeProperty("grid-row"),i?e.setAttribute("data-container-size",""):e.removeAttribute("data-container-size"),e}function vD({shadowRoot:e,currentNode:t,themeCSS:n}){if(n.trim()===""){t==null||t.remove();return}return t??(t=yD()),t.textContent=n,t.parentNode!==e&&e.appendChild(t),t}function yD(){const e=document.createElement("style");return e.setAttribute(gx,""),e}function wD(e,t){if(t==null)return;const n=e.shadowRoot??e.attachShadow({mode:"open"});n.innerHTML===""&&(n.innerHTML=t)}function bD(e,{type:t,diffIndicators:n,disableBackground:r,disableLineNumbers:i,overflow:s,split:l,totalLines:c,customProperties:d}){if(d!=null)for(const f in d){const m=d[f];m!=null&&e.setAttribute(f,`${m}`)}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",l?"split":"single"):e.removeAttribute("data-diff-type"),e.setAttribute("data-overflow",s),e.tabIndex=0,e.style.setProperty("--diffs-min-number-column-width-default",`${`${c}`.length}ch`),e}if(typeof HTMLElement<"u"&&customElements.get(Of)==null){let e;class t extends HTMLElement{constructor(){if(super(),this.shadowRoot!=null)return;const r=this.attachShadow({mode:"open"});e==null&&(e=new CSSStyleSheet,e.replaceSync(pD)),r.adoptedStyleSheets=[e]}}customElements.define(Of,t)}const xD=!0;function rw(e,t,n){if(e===t||e==null||t==null)return e===t;const r=new Set(n),i=Object.keys(e),s=new Set(Object.keys(t));for(const l of i)if(s.delete(l),!r.has(l)&&(!(l in t)||e[l]!==t[l]))return!1;for(const l of Array.from(s))if(!r.has(l))return!1;return!0}function _D(e,t){const n=(e==null?void 0:e.theme)??Ai,r=(t==null?void 0:t.theme)??Ai,i=iw(e),s=iw(t);return R_(n,r)&&rw(e,t,["theme","parseDiffOptions"])&&rw(i,s)}function iw(e){if(e!=null&&"parseDiffOptions"in e)return e.parseDiffOptions}function kD({hunkIndex:e,lineIndex:t,conflictIndex:n}){return`merge-conflict-action-${e}-${t}-${n}`}function SD(e,t){const n=t.hunks[e.hunkIndex];if(n!=null)return{hunkIndex:e.hunkIndex,lineIndex:CD(n,e.startContentIndex)}}function CD(e,t){let n=e.unifiedLineStart;for(let r=0;r<t;r++){const i=e.hunkContent[r];n+=i.type==="context"?i.lines:i.deletions+i.additions}return n}function ED({fileDiff:e,actions:t,renderCustomHeader:n,renderHeaderPrefix:r,renderHeaderMetadata:i,renderAnnotation:s,renderGutterUtility:l,renderHoverUtility:c,renderMergeConflictUtility:d,lineAnnotations:f,getHoveredLine:m,getInstance:h}){const g=l??c,y=n==null?void 0:n(e),w=r==null?void 0:r(e),_=i==null?void 0:i(e);return P.jsxs(P.Fragment,{children:[y!=null?P.jsx("div",{slot:w0,children:y}):P.jsxs(P.Fragment,{children:[w!=null&&P.jsx("div",{slot:v0,children:w}),_!=null&&P.jsx("div",{slot:y0,children:_})]}),s!=null&&(f==null?void 0:f.map((C,I)=>P.jsx("div",{slot:Xc(C),children:s(C)},I))),t!=null&&d!=null&&h!=null&&t.map(C=>{if(C==null)return;const I=ID(C,e);return P.jsx("div",{slot:I,style:G3,children:d(C,h)},I)}),g!=null&&P.jsx("div",{slot:"gutter-utility-slot",style:W3,children:g(m)})]})}function ID(e,t){const n=SD(e,t);return n!=null?kD({hunkIndex:n.hunkIndex,lineIndex:n.lineIndex,conflictIndex:e.conflictIndex}):void 0}var PD=class{constructor(){F(this,"isDeletionsScrolling",!1);F(this,"isAdditionsScrolling",!1);F(this,"timeoutId",-1);F(this,"codeDeletions");F(this,"codeAdditions");F(this,"enabled",!1);F(this,"handleDeletionsScroll",()=>{var e,t;this.isAdditionsScrolling||(this.isDeletionsScrolling=!0,clearTimeout(this.timeoutId),this.timeoutId=setTimeout(()=>{this.isDeletionsScrolling=!1},300),(t=this.codeAdditions)==null||t.scrollTo({left:(e=this.codeDeletions)==null?void 0:e.scrollLeft}))});F(this,"handleAdditionsScroll",()=>{var e,t;this.isDeletionsScrolling||(this.isAdditionsScrolling=!0,clearTimeout(this.timeoutId),this.timeoutId=setTimeout(()=>{this.isAdditionsScrolling=!1},300),(t=this.codeDeletions)==null||t.scrollTo({left:(e=this.codeAdditions)==null?void 0:e.scrollLeft}))})}cleanUp(){var e,t;this.enabled&&((e=this.codeDeletions)==null||e.removeEventListener("scroll",this.handleDeletionsScroll),(t=this.codeAdditions)==null||t.removeEventListener("scroll",this.handleAdditionsScroll),clearTimeout(this.timeoutId),this.codeDeletions=void 0,this.codeAdditions=void 0,this.enabled=!1)}setup(e,t,n){var r,i;if(t==null||n==null)for(const s of e.children??[])s instanceof HTMLElement&&("deletions"in s.dataset?t=s:"additions"in s.dataset&&(n=s));if(n==null||t==null){this.cleanUp();return}this.codeDeletions!==t&&((r=this.codeDeletions)==null||r.removeEventListener("scroll",this.handleDeletionsScroll),this.codeDeletions=t,t.addEventListener("scroll",this.handleDeletionsScroll,{passive:!0})),this.codeAdditions!==n&&((i=this.codeAdditions)==null||i.removeEventListener("scroll",this.handleAdditionsScroll),this.codeAdditions=n,n.addEventListener("scroll",this.handleAdditionsScroll,{passive:!0})),this.enabled=!0}};function Jd(e){return Ye({tagName:"div",properties:{"data-content-buffer":"","data-buffer-size":e,style:`grid-row: span ${e};min-height:calc(${e} * 1lh)`}})}function Zd(e){return Ye({tagName:"div",children:[Ye({tagName:"span",children:[Ni("No newline at end of file")]})],properties:{"data-no-newline":"","data-line-type":e,"data-column-content":""}})}function Am(e){return Ye({tagName:"div",children:[Xf({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 Qa({type:e,content:t,expandIndex:n,chunked:r=!1,slotName:i,isFirstHunk:s,isLastHunk:l}){let c=0;const d=[];if(e==="metadata"&&t!=null&&d.push(Ye({tagName:"div",children:[Ni(t)],properties:{"data-separator-wrapper":""}})),(e==="line-info"||e==="line-info-basic")&&t!=null){const f=[];n!=null&&(r?(s||(f.push(Am("up")),c++),l||(f.push(Am("down")),c++)):(f.push(Am(!s&&!l?"both":s?"down":"up")),c++)),f.push(Ye({tagName:"div",children:[Ye({tagName:"span",children:[Ni(t)],properties:{"data-unmodified-lines":""}})],properties:{"data-separator-content":""}})),r&&n!=null&&f.push(Ye({tagName:"div",children:[Ni("Expand all")],properties:{role:"button","data-expand-button":"","data-expand-all-button":""}})),d.push(Ye({tagName:"div",children:f,properties:{"data-separator-wrapper":"","data-separator-multi-button":c>1?"":void 0}}))}return e==="custom"&&i!=null&&d.push(Ye({tagName:"slot",properties:{name:i}})),Ye({tagName:"div",children:d,properties:{"data-separator":d.length===0?"simple":e,"data-expand-index":n,"data-separator-first":s?"":void 0,"data-separator-last":l?"":void 0}})}function LD(e,t){return`hunk-separator-${e}-${t}`}function DD(e){const t=e.at(-1);return t==null?0:Math.max(t.additionStart+t.additionCount,t.deletionStart+t.deletionCount)}function AD(e){return e.startingLine===0&&e.totalLines===1/0&&e.bufferBefore===0&&e.bufferAfter===0}let TD=-1;var RD=class{constructor(e={theme:Ai},t,n){F(this,"__id",`diff-hunks-renderer:${++TD}`);F(this,"highlighter");F(this,"diff");F(this,"expandedHunks",new Map);F(this,"deletionAnnotations",{});F(this,"additionAnnotations",{});F(this,"computedLang","text");F(this,"renderCache");this.options=e,this.onRenderUpdate=t,this.workerManager=n,(n==null?void 0:n.isWorkingPool())!==!0&&(this.highlighter=Lm(e.theme??Ai)?cL():void 0)}cleanUp(){var e;this.highlighter=void 0,this.diff=void 0,this.renderCache=void 0,(e=this.workerManager)==null||e.cleanUpPendingTasks(this),this.workerManager=void 0,this.onRenderUpdate=void 0}recycle(){var e;this.highlighter=void 0,this.diff=void 0,this.renderCache=void 0,(e=this.workerManager)==null||e.cleanUpPendingTasks(this)}setOptions(e){this.options=e}mergeOptions(e){this.options={...this.options,...e}}expandHunk(e,t,n=this.getOptionsWithDefaults().expansionLineCount){var i;const r={...this.expandedHunks.get(e)??{fromStart:0,fromEnd:0}};(t==="up"||t==="both")&&(r.fromStart+=n),(t==="down"||t==="both")&&(r.fromEnd+=n),((i=this.renderCache)==null?void 0:i.highlighted)!==!0&&(this.renderCache=void 0),this.expandedHunks.set(e,r)}getExpandedHunk(e){return this.expandedHunks.get(e)??tI}getExpandedHunksMap(){return this.expandedHunks}setLineAnnotations(e){this.additionAnnotations={},this.deletionAnnotations={};for(const t of e){const n=(()=>{switch(t.side){case"deletions":return this.deletionAnnotations;case"additions":return this.additionAnnotations}})(),r=n[t.lineNumber]??[];n[t.lineNumber]=r,r.push(t)}}getUnifiedLineDecoration({lineType:e}){return{gutterLineType:e}}getSplitLineDecoration({side:e,type:t}){return t!=="change"?{gutterLineType:t}:{gutterLineType:e==="deletions"?"change-deletion":"change-addition"}}createAnnotationElement(e){return JL(e)}getOptionsWithDefaults(){var S;const{diffIndicators:e="bars",diffStyle:t="split",disableBackground:n=!1,disableFileHeader:r=!1,disableLineNumbers:i=!1,disableVirtualizationBuffers:s=!1,collapsed:l=!1,expandUnchanged:c=!1,collapsedContextThreshold:d=ll,expansionLineCount:f=100,hunkSeparators:m="line-info",lineDiffType:h="word-alt",maxLineDiffLength:g=1e3,overflow:y="scroll",theme:w=Ai,headerRenderMode:_="default",tokenizeMaxLineLength:C=1e3,useTokenTransformer:I=!1,useCSSClasses:E=!1}=this.options;return{diffIndicators:e,diffStyle:t,disableBackground:n,disableFileHeader:r,disableLineNumbers:i,disableVirtualizationBuffers:s,collapsed:l,expandUnchanged:c,collapsedContextThreshold:d,expansionLineCount:f,hunkSeparators:m,lineDiffType:h,maxLineDiffLength:g,overflow:y,theme:((S=this.workerManager)==null?void 0:S.getDiffRenderOptions().theme)??w,headerRenderMode:_,tokenizeMaxLineLength:C,useTokenTransformer:I,useCSSClasses:E}}async initializeHighlighter(){return this.highlighter=await lL(sD(this.computedLang,this.options)),this.highlighter}hydrate(e){var r,i;if(e==null)return;this.diff=e;const{options:t}=this.getRenderOptions(e);let n=(r=this.workerManager)==null?void 0:r.getDiffResultCache(e);n!=null&&!Im(t,n.options)&&(n=void 0),this.renderCache??(this.renderCache={diff:e,highlighted:!xL(e),options:t,result:n==null?void 0:n.result,renderRange:void 0}),((i=this.workerManager)==null?void 0:i.isWorkingPool())===!0?this.renderCache.result==null&&this.workerManager.highlightDiffAST(this,this.diff):this.highlighter==null&&(this.computedLang=e.lang??ia(e.name),this.initializeHighlighter())}getRenderOptions(e){const t=(()=>{var c;if(((c=this.workerManager)==null?void 0:c.isWorkingPool())===!0)return this.workerManager.getDiffRenderOptions();const{theme:r,tokenizeMaxLineLength:i,lineDiffType:s,maxLineDiffLength:l}=this.getOptionsWithDefaults();return{theme:r,useTokenTransformer:aD(this.options),tokenizeMaxLineLength:i,lineDiffType:s,maxLineDiffLength:l}})();this.getOptionsWithDefaults();const{renderCache:n}=this;return(n==null?void 0:n.result)==null?{options:t,forceRender:!0}:e!==n.diff||!Im(t,n.options)?{options:t,forceRender:!0}:{options:t,forceRender:!1}}renderDiff(e=(n=>(n=this.renderCache)==null?void 0:n.diff)(),t=Xv){var d,f;if(e==null)return;const{expandUnchanged:r=!1,collapsedContextThreshold:i}=this.getOptionsWithDefaults(),s=(d=this.workerManager)==null?void 0:d.getDiffResultCache(e);s!=null&&this.renderCache==null&&(this.renderCache={diff:e,highlighted:!0,renderRange:void 0,...s});const{options:l,forceRender:c}=this.getRenderOptions(e);if(this.renderCache??(this.renderCache={diff:e,highlighted:!1,options:l,result:void 0,renderRange:void 0}),((f=this.workerManager)==null?void 0:f.isWorkingPool())===!0)(this.renderCache.result==null||!this.renderCache.highlighted&&(e!==this.renderCache.diff||!F_(this.renderCache.renderRange,t)))&&(this.renderCache.diff=e,this.renderCache.result=this.workerManager.getPlainDiffAST(e,t.startingLine,t.totalLines,AD(t)||r?!0:this.expandedHunks,i),this.renderCache.renderRange=t),t.totalLines>0&&(!this.renderCache.highlighted||c)&&this.workerManager.highlightDiffAST(this,e);else{this.computedLang=e.lang??ia(e.name);const m=this.highlighter!=null&&Lm(l.theme),h=this.highlighter!=null&&tw(this.computedLang);if(this.highlighter!=null&&m&&(c||!this.renderCache.highlighted&&h||this.renderCache.result==null)){const{result:g,options:y}=this.renderDiffWithHighlighter(e,this.highlighter,!h);this.renderCache={diff:e,options:y,highlighted:h,result:g,renderRange:void 0}}(!m||!h)&&this.asyncHighlight(e).then(({result:g,options:y})=>{this.renderCache!=null&&(this.renderCache.highlighted=!1),this.onHighlightSuccess(e,g,y)})}return this.renderCache.result!=null?this.processDiffResult(this.renderCache.diff,t,this.renderCache.result):void 0}async asyncRender(e,t=Xv){const{result:n}=await this.asyncHighlight(e);return this.processDiffResult(e,t,n)}createPreElement(e,t,n){const{diffIndicators:r,disableBackground:i,disableLineNumbers:s,overflow:l}=this.getOptionsWithDefaults();return iD({type:"diff",diffIndicators:r,disableBackground:i,disableLineNumbers:s,overflow:l,split:e,totalLines:t,customProperties:n})}async asyncHighlight(e){this.computedLang=e.lang??ia(e.name);const t=this.highlighter!=null&&Lm(this.options.theme??Ai),n=this.highlighter!=null&&tw(this.computedLang);return(this.highlighter==null||!t||!n)&&(this.highlighter=await this.initializeHighlighter()),this.renderDiffWithHighlighter(e,this.highlighter)}renderDiffWithHighlighter(e,t,n=!1){const{options:r}=this.getRenderOptions(e),{collapsedContextThreshold:i}=this.getOptionsWithDefaults();return{result:$L(e,t,r,{forcePlainText:n,expandedHunks:n?!0:void 0,collapsedContextThreshold:i}),options:r}}onHighlightSuccess(e,t,n){var i;if(this.renderCache==null)return;const r=!this.renderCache.highlighted||!Im(this.renderCache.options,n)||this.renderCache.diff!==e;this.renderCache={diff:e,options:n,highlighted:!0,result:t,renderRange:void 0},r&&((i=this.onRenderUpdate)==null||i.call(this))}onHighlightError(e){console.error(e)}processDiffResult(e,t,{code:n,themeStyles:r,baseThemeType:i}){const{diffStyle:s,disableFileHeader:l,expandUnchanged:c,expansionLineCount:d,collapsedContextThreshold:f,hunkSeparators:m}=this.getOptionsWithDefaults();this.diff=e;const h=s==="unified";let g=[],y=[],w=[];const _=[],{additionLines:C,deletionLines:I}=n,E={rowCount:0,hunkSeparators:m,additionsContentAST:g,deletionsContentAST:y,unifiedContentAST:w,unifiedGutterAST:Xd(),deletionsGutterAST:Xd(),additionsGutterAST:Xd(),expansionLineCount:d,hunkData:_,incrementRowCount(Q=1){E.rowCount+=Q},pushToGutter(Q,ee){switch(Q){case"unified":E.unifiedGutterAST.children.push(ee);break;case"deletions":E.deletionsGutterAST.children.push(ee);break;case"additions":E.additionsGutterAST.children.push(ee);break}}},S=ND(e),L={size:0,side:void 0,increment(){this.size+=1},flush(){if(s!=="unified"){if(this.size<=0||this.side==null){this.side=void 0,this.size=0;return}this.side==="additions"?(E.pushToGutter("additions",Jr(void 0,"buffer",this.size)),g==null||g.push(Jd(this.size))):(E.pushToGutter("deletions",Jr(void 0,"buffer",this.size)),y==null||y.push(Jd(this.size))),this.size=0,this.side=void 0}}},A=(Q,ee,K,oe,ie)=>{E.pushToGutter(Q,fL(ee,K,oe,ie))};function R(Q){L.flush(),s==="unified"?Tm("unified",Q,E):(Tm("deletions",Q,E),Tm("additions",Q,E))}Qf({diff:e,diffStyle:s,startingLine:t.startingLine,totalLines:t.totalLines,expandedHunks:c?!0:this.expandedHunks,collapsedContextThreshold:f,callback:({hunkIndex:Q,hunk:ee,collapsedBefore:K,collapsedAfter:oe,additionLine:ie,deletionLine:W,type:ce})=>{var Pe,Ne;const le=W!=null?W.splitLineIndex:ie.splitLineIndex,O=ie!=null?ie.unifiedLineIndex:W.unifiedLineIndex;s==="split"&&ce!=="change"&&L.flush(),K>0&&R({hunkIndex:Q,collapsedLines:K,rangeSize:Math.max((ee==null?void 0:ee.collapsedBefore)??0,0),hunkSpecs:ee==null?void 0:ee.hunkSpecs,isFirstHunk:Q===0,isLastHunk:!1,isExpandable:!e.isPartial});const J=s==="unified"?O:le,fe={type:ce,hunkIndex:Q,lineIndex:J,unifiedLineIndex:O,splitLineIndex:le,deletionLine:W,additionLine:ie};if(s==="unified"){const he=(Pe=this.getUnifiedInjectedRowsForLine)==null?void 0:Pe.call(this,fe);(he==null?void 0:he.before)!=null&&sw(he.before,E);let Te=W!=null?I[W.lineIndex]:void 0,Qe=ie!=null?C[ie.lineIndex]:void 0;if(Te==null&&Qe==null){const ct="DiffHunksRenderer.processDiffResult: deletionLine and additionLine are null, something is wrong";throw console.error(ct,{file:e.name}),new Error(ct)}const pt=ce==="change"?ie!=null?"change-addition":"change-deletion":ce,mt=this.getUnifiedLineDecoration({type:ce,lineType:pt,additionLineIndex:ie==null?void 0:ie.lineIndex,deletionLineIndex:W==null?void 0:W.lineIndex});A("unified",mt.gutterLineType,ie!=null?ie.lineNumber:W.lineNumber,`${O},${le}`,mt.gutterProperties),Qe!=null?Qe=ef(Qe,mt.contentProperties):Te!=null&&(Te=ef(Te,mt.contentProperties)),lw({diffStyle:"unified",type:ce,deletionLine:Te,additionLine:Qe,unifiedSpan:this.getAnnotations("unified",W==null?void 0:W.lineNumber,ie==null?void 0:ie.lineNumber,Q,J),createAnnotationElement:ct=>this.createAnnotationElement(ct),context:E}),(he==null?void 0:he.after)!=null&&sw(he.after,E)}else{const he=(Ne=this.getSplitInjectedRowsForLine)==null?void 0:Ne.call(this,fe);(he==null?void 0:he.before)!=null&&aw(he.before,E,L);let Te=W!=null?I[W.lineIndex]:void 0,Qe=ie!=null?C[ie.lineIndex]:void 0;const pt=this.getSplitLineDecoration({side:"deletions",type:ce,lineIndex:W==null?void 0:W.lineIndex}),mt=this.getSplitLineDecoration({side:"additions",type:ce,lineIndex:ie==null?void 0:ie.lineIndex});if(Te==null&&Qe==null){const Je="DiffHunksRenderer.processDiffResult: deletionLine and additionLine are null, something is wrong";throw console.error(Je,{file:e.name}),new Error(Je)}const ct=(()=>{if(ce==="change"){if(Qe==null)return"additions";if(Te==null)return"deletions"}})();if(ct!=null){if(L.side!=null&&L.side!==ct)throw new Error("DiffHunksRenderer.processDiffResult: iterateOverDiff, invalid pending splits");L.side=ct,L.increment()}const mn=this.getAnnotations("split",W==null?void 0:W.lineNumber,ie==null?void 0:ie.lineNumber,Q,J);if(mn!=null&&L.size>0&&L.flush(),W!=null){const Je=ef(Te,pt.contentProperties);A("deletions",pt.gutterLineType,W.lineNumber,`${W.unifiedLineIndex},${le}`,pt.gutterProperties),Je!=null&&(Te=Je)}if(ie!=null){const Je=ef(Qe,mt.contentProperties);A("additions",mt.gutterLineType,ie.lineNumber,`${ie.unifiedLineIndex},${le}`,mt.gutterProperties),Je!=null&&(Qe=Je)}lw({diffStyle:"split",type:ce,additionLine:Qe,deletionLine:Te,...mn,createAnnotationElement:Je=>this.createAnnotationElement(Je),context:E}),(he==null?void 0:he.after)!=null&&aw(he.after,E,L)}const we=(W==null?void 0:W.noEOFCR)??!1,be=(ie==null?void 0:ie.noEOFCR)??!1;if(be||we){if(we){const he=ce==="context"||ce==="context-expanded"?ce:"change-deletion";s==="unified"?(E.unifiedContentAST.push(Zd(he)),E.pushToGutter("unified",Jr(he,"metadata",1))):(E.deletionsContentAST.push(Zd(he)),E.pushToGutter("deletions",Jr(he,"metadata",1)),be||(E.pushToGutter("additions",Jr(void 0,"buffer",1)),E.additionsContentAST.push(Jd(1))))}if(be){const he=ce==="context"||ce==="context-expanded"?ce:"change-addition";s==="unified"?(E.unifiedContentAST.push(Zd(he)),E.pushToGutter("unified",Jr(he,"metadata",1))):(E.additionsContentAST.push(Zd(he)),E.pushToGutter("additions",Jr(he,"metadata",1)),we||(E.pushToGutter("deletions",Jr(void 0,"buffer",1)),E.deletionsContentAST.push(Jd(1))))}E.incrementRowCount(1)}oe>0&&m!=="simple"&&R({hunkIndex:ce==="context-expanded"?Q:Q+1,collapsedLines:oe,rangeSize:S,hunkSpecs:void 0,isFirstHunk:!1,isLastHunk:!0,isExpandable:!e.isPartial}),E.incrementRowCount(1)}}),s==="split"&&L.flush();const U=Math.max(DD(e.hunks),e.additionLines.length??0,e.deletionLines.length??0),X=t.bufferBefore>0||t.bufferAfter>0,H=!h&&e.type!=="deleted",re=!h&&e.type!=="new",de=E.rowCount>0||X;g=H&&de?g:void 0,y=re&&de?y:void 0,w=h&&de?w:void 0;const te=this.createPreElement(y!=null&&g!=null,U);return{unifiedGutterAST:h&&de?E.unifiedGutterAST.children:void 0,unifiedContentAST:w,deletionsGutterAST:re&&de?E.deletionsGutterAST.children:void 0,deletionsContentAST:y,additionsGutterAST:H&&de?E.additionsGutterAST.children:void 0,additionsContentAST:g,hunkData:_,preNode:te,themeStyles:r,baseThemeType:i,headerElement:l?void 0:this.renderHeader(this.diff),totalLines:U,rowCount:E.rowCount,bufferBefore:t.bufferBefore,bufferAfter:t.bufferAfter,css:""}}renderCodeAST(e,t){const 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;const i=Xd(n);return i.properties.style=`grid-row: span ${t.rowCount}`,[i,ZL(r,t.rowCount)]}renderFullAST(e,t=[]){const n=this.getOptionsWithDefaults().hunkSeparators==="line-info",r=this.renderCodeAST("unified",e);if(r!=null)return t.push(Ye({tagName:"code",children:r,properties:{"data-code":"","data-container-size":n?"":void 0,"data-unified":""}})),{...e.preNode,children:t};const i=this.renderCodeAST("deletions",e);i!=null&&t.push(Ye({tagName:"code",children:i,properties:{"data-code":"","data-container-size":n?"":void 0,"data-deletions":""}}));const s=this.renderCodeAST("additions",e);return s!=null&&t.push(Ye({tagName:"code",children:s,properties:{"data-code":"","data-container-size":n?"":void 0,"data-additions":""}})),{...e.preNode,children:t}}renderFullHTML(e,t=[]){return dl(this.renderFullAST(e,t))}renderPartialHTML(e,t){return t==null?dl(e):dl(Ye({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){const s={type:"annotation",hunkIndex:r,lineIndex:i,annotations:[]};if(t!=null)for(const c of this.deletionAnnotations[t]??[])s.annotations.push(Xc(c));const l={type:"annotation",hunkIndex:r,lineIndex:i,annotations:[]};if(n!=null)for(const c of this.additionAnnotations[n]??[])(e==="unified"?s:l).annotations.push(Xc(c));if(e==="unified")return s.annotations.length>0?s:void 0;if(!(l.annotations.length===0&&s.annotations.length===0))return{deletionSpan:s,additionSpan:l}}renderHeader(e){const{headerRenderMode:t}=this.getOptionsWithDefaults();return tD({fileOrDiff:e,mode:t})}};function ow(e){return`${e} unmodified line${e>1?"s":""}`}function sw(e,t){for(const n of e)t.unifiedContentAST.push(n.content),t.pushToGutter("unified",n.gutter),t.incrementRowCount(1)}function aw(e,t,n){for(const{deletion:r,addition:i}of e){if(r==null&&i==null)continue;const s=r!=null&&i!=null?void 0:r==null?"deletions":"additions";(s==null||n.side!==s)&&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)),s!=null&&(n.side=s,n.increment()),t.incrementRowCount(1)}}function lw({diffStyle:e,type:t,deletionLine:n,additionLine:r,unifiedSpan:i,deletionSpan:s,additionSpan:l,createAnnotationElement:c,context:d}){let f=!1;if(e==="unified"){if(r!=null?d.unifiedContentAST.push(r):n!=null&&d.unifiedContentAST.push(n),i!=null){const m=t==="change"?n!=null?"change-deletion":"change-addition":t;d.unifiedContentAST.push(c(i)),d.pushToGutter("unified",Jr(m,"annotation",1)),f=!0}}else if(e==="split"){if(n!=null&&d.deletionsContentAST.push(n),r!=null&&d.additionsContentAST.push(r),s!=null){const m=t==="change"?n!=null?"change-deletion":"context":t;d.deletionsContentAST.push(c(s)),d.pushToGutter("deletions",Jr(m,"annotation",1)),f=!0}if(l!=null){const m=t==="change"?r!=null?"change-addition":"context":t;d.additionsContentAST.push(c(l)),d.pushToGutter("additions",Jr(m,"annotation",1)),f=!0}}f&&d.incrementRowCount(1)}function Tm(e,{hunkIndex:t,collapsedLines:n,rangeSize:r,hunkSpecs:i,isFirstHunk:s,isLastHunk:l,isExpandable:c},d){if(n<=0)return;const f=e==="unified"?d.unifiedContentAST:e==="deletions"?d.deletionsContentAST:d.additionsContentAST;if(d.hunkSeparators==="metadata"){i!=null&&(d.pushToGutter(e,Qa({type:"metadata",content:i,isFirstHunk:s,isLastHunk:l})),f.push(Qa({type:"metadata",content:i,isFirstHunk:s,isLastHunk:l})),e!=="additions"&&d.incrementRowCount(1));return}if(d.hunkSeparators==="simple"){t>0&&(d.pushToGutter(e,Qa({type:"simple",isFirstHunk:s,isLastHunk:!1})),f.push(Qa({type:"simple",isFirstHunk:s,isLastHunk:!1})),e!=="additions"&&d.incrementRowCount(1));return}const m=LD(e,t),h=r>d.expansionLineCount,g=c?t:void 0;d.pushToGutter(e,Qa({type:d.hunkSeparators,content:ow(n),expandIndex:g,chunked:h,slotName:m,isFirstHunk:s,isLastHunk:l})),f.push(Qa({type:d.hunkSeparators,content:ow(n),expandIndex:g,chunked:h,slotName:m,isFirstHunk:s,isLastHunk:l})),e!=="additions"&&d.incrementRowCount(1),d.hunkData.push({slotName:m,hunkIndex:t,lines:n,type:e,expandable:c?{up:!s,down:!l,chunked:h}:void 0})}function ef(e,t){return e==null||e.type!=="element"||t==null?e:{...e,properties:{...e.properties,...t}}}function ND(e){const t=e.hunks.at(-1);if(t==null||e.isPartial||e.additionLines.length===0||e.deletionLines.length===0)return 0;const n=e.additionLines.length-(t.additionLineIndex+t.additionCount),r=e.deletionLines.length-(t.deletionLineIndex+t.deletionCount);if(n!==r)throw new Error(`DiffHunksRenderer.processDiffResult: trailing context mismatch (additions=${n}, deletions=${r}) for ${e.name}`);return Math.min(n,r)}function FD(e,t){return e.lineNumber===t.lineNumber&&e.side===t.side&&e.metadata===t.metadata}function MD(e,t){var n,r,i,s,l,c;return e.slotName===t.slotName&&e.hunkIndex===t.hunkIndex&&e.lines===t.lines&&e.type===t.type&&((n=e.expandable)==null?void 0:n.chunked)===((r=t.expandable)==null?void 0:r.chunked)&&((i=e.expandable)==null?void 0:i.up)===((s=t.expandable)==null?void 0:s.up)&&((l=e.expandable)==null?void 0:l.down)===((c=t.expandable)==null?void 0:c.down)}function OD(e){const t=e[0];if(t!=="+"&&t!=="-"&&t!==" "&&t!=="\\"){console.error(`parseLineType: Invalid firstChar: "${t}", full line: "${e}"`);return}const n=e.substring(1);return{line:n===""?`
426
+ `:n,type:t===" "?"context":t==="\\"?"metadata":t==="+"?"addition":"deletion"}}function $D(e,t,n=!1){const r=df.test(e),i=e.split(r?df:Kv);let s;const l=[];for(const c of i){if(r&&!df.test(c)){if(s==null)s=c;else{if(n)throw Error("parsePatchContent: unknown file blob");console.error("parsePatchContent: unknown file blob:",c)}continue}else if(!r&&!Kv.test(c)){if(s==null)s=c;else{if(n)throw Error("parsePatchContent: unknown file blob");console.error("parsePatchContent: unknown file blob:",c)}continue}const d=O_(c,{cacheKey:void 0,isGitDiff:r,throwOnError:n});d!=null&&l.push(d)}return{patchMetadata:s,files:l}}function O_(e,{cacheKey:t,isGitDiff:n=df.test(e),oldFile:r,newFile:i,throwOnError:s=!1}={}){let l=0;const c=e.split(K3);let d;const f=r==null||i==null;let m=0,h=0;for(const g of c){const y=g.split(am),w=y.shift();if(w==null){if(s)throw Error("parsePatchContent: invalid hunk");console.error("parsePatchContent: invalid hunk",g);continue}const _=w.match(X3);let C=0,I=0;if(_==null||d==null){if(d!=null){if(s)throw Error("parsePatchContent: Invalid hunk");console.error("parsePatchContent: Invalid hunk",g);continue}d={name:"",type:"change",hunks:[],splitLineCount:0,unifiedLineCount:0,isPartial:f,additionLines:!f&&r!=null&&i!=null?i.contents.split(am):[],deletionLines:!f&&r!=null&&i!=null?r.contents.split(am):[],cacheKey:t},d.additionLines.length===1&&(i==null?void 0:i.contents)===""&&(d.additionLines.length=0),d.deletionLines.length===1&&(r==null?void 0:r.contents)===""&&(d.deletionLines.length=0),y.unshift(w);for(const H of y){const re=H.match(n?Y3:Q3);if(H.startsWith("diff --git")){const[,,de,,te]=H.trim().match(J3)??[];d.name=te.trim(),de!==te&&(d.prevName=de.trim())}else if(re!=null){const[,de,te]=re;de==="---"&&te!=="/dev/null"?(d.prevName=te.trim(),d.name=te.trim()):de==="+++"&&te!=="/dev/null"&&(d.name=te.trim())}else if(n){if(H.startsWith("new mode ")&&(d.mode=H.replace("new mode","").trim()),H.startsWith("old mode ")&&(d.prevMode=H.replace("old mode","").trim()),H.startsWith("new file mode")&&(d.type="new",d.mode=H.replace("new file mode","").trim()),H.startsWith("deleted file mode")&&(d.type="deleted",d.mode=H.replace("deleted file mode","").trim()),H.startsWith("similarity index")&&(H.startsWith("similarity index 100%")?d.type="rename-pure":d.type="rename-changed"),H.startsWith("index ")){const[,de,te,Q]=H.trim().match(Z3)??[];de!=null&&(d.prevObjectId=de),te!=null&&(d.newObjectId=te),Q!=null&&(d.mode=Q)}H.startsWith("rename from ")&&(d.prevName=H.replace("rename from ","").trim()),H.startsWith("rename to ")&&(d.name=H.replace("rename to ","").trim())}}continue}let E,S;for(;y.length>0&&(y[y.length-1]===`
427
+ `||y[y.length-1]==="\r"||y[y.length-1]===`\r
428
+ `||y[y.length-1]==="");)y.pop();const L=parseInt(_[3]),A=parseInt(_[1]);m=f?m:A-1,h=f?h:L-1;const R={collapsedBefore:0,splitLineCount:0,splitLineStart:0,unifiedLineCount:0,unifiedLineStart:0,additionCount:parseInt(_[4]??"1"),additionStart:L,additionLines:C,deletionCount:parseInt(_[2]??"1"),deletionStart:A,deletionLines:I,deletionLineIndex:m,additionLineIndex:h,hunkContent:[],hunkContext:_[5],hunkSpecs:w,noEOFCRAdditions:!1,noEOFCRDeletions:!1};if(isNaN(R.additionCount)||isNaN(R.deletionCount)||isNaN(R.additionStart)||isNaN(R.deletionStart)){if(s)throw Error("parsePatchContent: invalid hunk metadata");console.error("parsePatchContent: invalid hunk metadata",R);continue}let U=0,X=0;for(const H of y){if(BD({additionCount:R.additionCount,parsedAdditionLines:U,deletionCount:R.deletionCount,parsedDeletionLines:X})&&!H.startsWith("\\"))break;const re=OD(H);if(re==null){console.error("processFile: invalid rawLine:",H);continue}const{type:de,line:te}=re;if(de==="addition")(E==null||E.type!=="change")&&(E=Rm("change",m,h),R.hunkContent.push(E)),h++,U++,f&&d.additionLines.push(te),E.additions++,C++,S="addition";else if(de==="deletion")(E==null||E.type!=="change")&&(E=Rm("change",m,h),R.hunkContent.push(E)),m++,X++,f&&d.deletionLines.push(te),E.deletions++,I++,S="deletion";else if(de==="context")(E==null||E.type!=="context")&&(E=Rm("context",m,h),R.hunkContent.push(E)),h++,m++,U++,X++,f&&(d.deletionLines.push(te),d.additionLines.push(te)),E.lines++,S="context";else if(de==="metadata"&&E!=null){if(E.type==="context"?(R.noEOFCRAdditions=!0,R.noEOFCRDeletions=!0):S==="deletion"?R.noEOFCRDeletions=!0:S==="addition"&&(R.noEOFCRAdditions=!0),f&&(S==="addition"||S==="context")){const Q=d.additionLines.length-1;Q>=0&&(d.additionLines[Q]=Dl(d.additionLines[Q]))}if(f&&(S==="deletion"||S==="context")){const Q=d.deletionLines.length-1;Q>=0&&(d.deletionLines[Q]=Dl(d.deletionLines[Q]))}}}R.additionLines=C,R.deletionLines=I,R.collapsedBefore=Math.max(R.additionStart-1-l,0),d.hunks.push(R),l=R.additionStart+R.additionCount-1;for(const H of R.hunkContent)H.type==="context"?(R.splitLineCount+=H.lines,R.unifiedLineCount+=H.lines):(R.splitLineCount+=Math.max(H.additions,H.deletions),R.unifiedLineCount+=H.deletions+H.additions);R.splitLineStart=d.splitLineCount+R.collapsedBefore,R.unifiedLineStart=d.unifiedLineCount+R.collapsedBefore,d.splitLineCount+=R.collapsedBefore+R.splitLineCount,d.unifiedLineCount+=R.collapsedBefore+R.unifiedLineCount}if(d!=null){if(d.hunks.length>0&&!f&&d.additionLines.length>0&&d.deletionLines.length>0){const g=d.hunks[d.hunks.length-1],y=g.additionStart+g.additionCount-1,w=d.additionLines.length,_=Math.max(w-y,0);d.splitLineCount+=_,d.unifiedLineCount+=_}return n||(d.prevName!=null&&d.name!==d.prevName?d.hunks.length>0?d.type="rename-changed":d.type="rename-pure":(r==null||r.contents==="")&&i!=null&&i.contents!==""?d.type="new":r!=null&&r.contents!==""&&(i==null||i.contents==="")&&(d.type="deleted")),d.type!=="rename-pure"&&d.type!=="rename-changed"&&(d.prevName=void 0),d}}function BD({additionCount:e,parsedAdditionLines:t,deletionCount:n,parsedDeletionLines:r}){return t>=e&&r>=n}function jD(e,t,n=!1){const r=[];for(const i of e.split(q3))try{r.push($D(i,t!=null?`${t}-${r.length}`:void 0,n))}catch(s){if(n)throw s;console.error(s)}return r}function Rm(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 kg(e,t,n,r=!1){const i=O_(FL(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 new 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}let VD=-1;var Wm,$_=(Wm=class{constructor(e={theme:Ai},t,n=!1){F(this,"__id",`file-diff:${++VD}`);F(this,"fileContainer");F(this,"spriteSVG");F(this,"pre");F(this,"codeUnified");F(this,"codeDeletions");F(this,"codeAdditions");F(this,"bufferBefore");F(this,"bufferAfter");F(this,"themeCSSStyle");F(this,"appliedThemeCSS");F(this,"unsafeCSSStyle");F(this,"appliedUnsafeCSS");F(this,"gutterUtilityContent");F(this,"headerElement");F(this,"headerPrefix");F(this,"headerMetadata");F(this,"headerCustom");F(this,"separatorCache",new Map);F(this,"errorWrapper");F(this,"placeHolder");F(this,"hunksRenderer");F(this,"resizeManager");F(this,"scrollSyncManager");F(this,"interactionManager");F(this,"annotationCache",new Map);F(this,"lineAnnotations",[]);F(this,"deletionFile");F(this,"additionFile");F(this,"fileDiff");F(this,"renderRange");F(this,"appliedPreAttributes");F(this,"lastRenderedHeaderHTML");F(this,"lastRowCount");F(this,"enabled",!0);F(this,"handleHighlightRender",()=>{this.rerender()});F(this,"getLineIndex",(e,t="additions")=>{if(this.fileDiff==null)return;const n=this.fileDiff.hunks.at(-1);let r,i;e:for(const s of this.fileDiff.hunks){let l=t==="deletions"?s.deletionStart:s.additionStart;const c=t==="deletions"?s.deletionCount:s.additionCount;let d=s.splitLineStart,f=s.unifiedLineStart;if(e<l){const m=l-e;r=Math.max(f-m,0),i=Math.max(d-m,0);break e}if(e>=l+c){if(s===n){const m=e-(l+c);r=f+s.unifiedLineCount+m,i=d+s.splitLineCount+m;break e}continue}for(const m of s.hunkContent)if(m.type==="context")if(e<l+m.lines){const h=e-l;i=d+h,r=f+h;break e}else l+=m.lines,d+=m.lines,f+=m.lines;else{const h=t==="deletions"?m.deletions:m.additions;if(e<l+h){const g=e-l;r=f+(t==="additions"?m.deletions:0)+g,i=d+g;break e}else l+=h,d+=Math.max(m.deletions,m.additions),f+=m.deletions+m.additions}break e}if(!(r==null||i==null))return[r,i]});F(this,"getHoveredLine",()=>this.interactionManager.getHoveredLine());F(this,"handleExpandHunk",(e,t,n)=>{this.expandHunk(e,t,n)});F(this,"expandHunk",(e,t,n)=>{this.hunksRenderer.expandHunk(e,t,n),this.rerender()});var r;this.options=e,this.workerManager=t,this.isContainerManaged=n,this.hunksRenderer=this.createHunksRenderer(e),this.resizeManager=new YL,this.scrollSyncManager=new PD,this.interactionManager=new GL("diff",Qy(e,typeof e.hunkSeparators=="function"||(e.hunkSeparators??"line-info")==="line-info"||e.hunkSeparators==="line-info-basic"?this.handleExpandHunk:void 0,this.getLineIndex)),(r=this.workerManager)==null||r.subscribeToThemeChanges(this),this.enabled=!0}getHunksRendererOptions(e){return{...e,headerRenderMode:e.renderCustomHeader!=null?"custom":"default",hunkSeparators:typeof e.hunkSeparators=="function"?"custom":e.hunkSeparators}}createHunksRenderer(e){return new RD(this.getHunksRendererOptions(e),this.handleHighlightRender,this.workerManager)}setOptions(e){e!=null&&(this.options=e,this.hunksRenderer.setOptions(this.getHunksRendererOptions(e)),this.interactionManager.setOptions(Qy(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))}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){var t,n,r;this.resizeManager.cleanUp(),this.interactionManager.cleanUp(),this.scrollSyncManager.cleanUp(),(t=this.workerManager)==null||t.unsubscribeToThemeChanges(this),this.renderRange=void 0,this.isContainerManaged||(n=this.fileContainer)==null||n.remove(),((r=this.fileContainer)==null?void 0:r.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(){var e;this.enabled=!0,(e=this.workerManager)==null||e.subscribeToThemeChanges(this)}hydrate(e){const{fileContainer:t,prerenderedHTML:n,preventEmit:r=!1,lineAnnotations:i,oldFile:s,newFile:l,fileDiff:c}=e;this.hydrateElements(t,n),HD(this.pre,UD({fileDiff:c,oldFile:s,newFile:l}),this.options.collapsed)||WD(this.headerElement,zD({fileDiff:c,oldFile:s,newFile:l}),this.options.disableFileHeader)?this.render({...e,preventEmit:!0}):this.hydrationSetup({fileDiff:c,oldFile:s,newFile:l,lineAnnotations:i}),r||this.emitPostRender()}hydrateElements(e,t){var n;wD(e,t);for(const r of((n=e.shadowRoot)==null?void 0:n.children)??[]){if(r instanceof SVGElement){this.spriteSVG=r;continue}if(r instanceof HTMLElement){if(r instanceof HTMLPreElement){this.pre=r;for(const i of r.children)!(i instanceof HTMLElement)||i.tagName.toLowerCase()!=="code"||("deletions"in i.dataset&&(this.codeDeletions=i),"additions"in i.dataset&&(this.codeAdditions=i),"unified"in i.dataset&&(this.codeUnified=i));continue}if("diffsHeader"in r.dataset){this.headerElement=r;continue}if(r instanceof HTMLStyleElement&&r.hasAttribute(gx)){this.themeCSSStyle=r;continue}if(r instanceof HTMLStyleElement&&r.hasAttribute(vx)){this.unsafeCSSStyle=r,this.appliedUnsafeCSS=r.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}){const{diffStyle:i="split",overflow:s="scroll"}=this.options;this.lineAnnotations=r??this.lineAnnotations,this.additionFile=n,this.deletionFile=t,this.fileDiff=e??(t!=null&&n!=null?kg(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,s==="wrap"),s==="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})}render({oldFile:e,newFile:t,fileDiff:n,forceRender:r=!1,preventEmit:i=!1,lineAnnotations:s,fileContainer:l,containerWrapper:c,renderRange:d}){var L;if(!this.enabled)throw new Error("FileDiff.render: attempting to call render after cleaned up");const{collapsed:f=!1}=this.options,m=f?void 0:d,h=e!=null&&t!=null&&(!zy(e,this.deletionFile)||!zy(t,this.additionFile));let g=n!=null&&n!==this.fileDiff;const y=s!=null&&(s.length>0||this.lineAnnotations.length>0)?s!==this.lineAnnotations:!1;if(!f&&F_(m,this.renderRange)&&!r&&!y&&(n!=null&&n===this.fileDiff||n==null&&!h))return!1;const{renderRange:w}=this;if(this.renderRange=m,this.deletionFile=e,this.additionFile=t,n!=null?this.fileDiff=n:e!=null&&t!=null&&h&&(g=!0,this.fileDiff=kg(e,t,this.options.parseDiffOptions)),s!=null&&this.setLineAnnotations(s),this.fileDiff==null)return!1;this.hunksRenderer.setOptions(this.getHunksRendererOptions(this.options)),this.hunksRenderer.setLineAnnotations(this.lineAnnotations);const{diffStyle:_="split",disableErrorHandling:C=!1,disableFileHeader:I=!1,overflow:E="scroll",themeType:S="system"}=this.options;if(I&&(this.headerElement!=null&&(this.headerElement.remove(),this.headerElement=void 0,this.lastRenderedHeaderHTML=void 0),this.clearHeaderSlots()),l=this.getOrCreateFileContainer(l,c),f){this.removeRenderedCode(),this.clearAuxiliaryNodes();try{const A=this.hunksRenderer.renderDiff(this.fileDiff,nI);A!=null&&this.applyThemeState(l,A.themeStyles,S,A.baseThemeType),(A==null?void 0:A.headerElement)!=null&&this.applyHeaderToDOM(A.headerElement,l),this.renderSeparators([]),this.injectUnsafeCSS()}catch(A){if(C)throw A;console.error(A),A instanceof Error&&this.applyErrorToDOM(A,l)}return i||this.emitPostRender(),!0}try{const A=this.getOrCreatePreNode(l);if(!(this.canPartiallyRender(r,y,h||g)&&this.applyPartialRender({previousRenderRange:w,renderRange:m}))){const R=this.hunksRenderer.renderDiff(this.fileDiff,m);if(R==null)return((L=this.workerManager)==null?void 0:L.isInitialized())===!1&&this.workerManager.initialize().then(()=>this.rerender()),!1;this.applyThemeState(l,R.themeStyles,S,R.baseThemeType),R.headerElement!=null&&this.applyHeaderToDOM(R.headerElement,l),R.additionsContentAST!=null||R.deletionsContentAST!=null||R.unifiedContentAST!=null?this.applyHunksToDOM(A,R):this.pre!=null&&(this.pre.remove(),this.pre=void 0),this.renderSeparators(R.hunkData)}this.applyBuffers(A,m),this.injectUnsafeCSS(),this.renderAnnotations(),this.renderGutterUtility(),this.interactionManager.setup(A),this.resizeManager.setup(A,E==="wrap"),E==="scroll"&&_==="split"?this.scrollSyncManager.setup(A,this.codeDeletions,this.codeAdditions):this.scrollSyncManager.cleanUp()}catch(A){if(C)throw A;console.error(A),A instanceof Error&&this.applyErrorToDOM(A,l)}return i||this.emitPostRender(),!0}emitPostRender(){var e,t;this.fileContainer!=null&&((t=(e=this.options).onPostRender)==null||t.call(e,this.fileContainer,this))}removeRenderedCode(){var e,t,n,r,i,s;this.resizeManager.cleanUp(),this.scrollSyncManager.cleanUp(),this.interactionManager.cleanUp(),(e=this.bufferBefore)==null||e.remove(),this.bufferBefore=void 0,(t=this.bufferAfter)==null||t.remove(),this.bufferAfter=void 0,(n=this.codeUnified)==null||n.remove(),this.codeUnified=void 0,(r=this.codeDeletions)==null||r.remove(),this.codeDeletions=void 0,(i=this.codeAdditions)==null||i.remove(),this.codeAdditions=void 0,(s=this.pre)==null||s.remove(),this.pre=void 0,this.appliedPreAttributes=void 0,this.lastRowCount=void 0}clearAuxiliaryNodes(){var e;for(const{element:t}of this.separatorCache.values())t.remove();this.separatorCache.clear();for(const{element:t}of this.annotationCache.values())t.remove();this.annotationCache.clear(),(e=this.gutterUtilityContent)==null||e.remove(),this.gutterUtilityContent=void 0}renderPlaceholder(e){if(this.fileContainer==null)return!1;if(this.cleanChildNodes(),this.placeHolder==null){const t=this.fileContainer.shadowRoot??this.fileContainer.attachShadow({mode:"open"});this.placeHolder=document.createElement("div"),this.placeHolder.dataset.placeholder="",t.appendChild(this.placeHolder)}return this.placeHolder.style.setProperty("height",`${e}px`),!0}cleanChildNodes(){var e,t,n,r,i,s,l,c,d,f,m,h,g,y,w;this.resizeManager.cleanUp(),this.scrollSyncManager.cleanUp(),this.interactionManager.cleanUp(),(e=this.bufferAfter)==null||e.remove(),(t=this.bufferBefore)==null||t.remove(),(n=this.codeAdditions)==null||n.remove(),(r=this.codeDeletions)==null||r.remove(),(i=this.codeUnified)==null||i.remove(),(s=this.errorWrapper)==null||s.remove(),(l=this.headerElement)==null||l.remove(),(c=this.gutterUtilityContent)==null||c.remove(),(d=this.headerPrefix)==null||d.remove(),(f=this.headerMetadata)==null||f.remove(),(m=this.headerCustom)==null||m.remove(),(h=this.pre)==null||h.remove(),(g=this.spriteSVG)==null||g.remove(),(y=this.themeCSSStyle)==null||y.remove(),(w=this.unsafeCSSStyle)==null||w.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){const{hunkSeparators:t}=this.options;if(this.isContainerManaged||this.fileContainer==null||typeof t!="function"){for(const{element:r}of this.separatorCache.values())r.remove();this.separatorCache.clear();return}const n=new Map(this.separatorCache);for(const r of e){const i=r.slotName;let s=this.separatorCache.get(i);if(s==null||!MD(r,s.hunkData)){s==null||s.element.remove();const l=document.createElement("div");l.style.display="contents",l.slot=r.slotName;const c=t(r,this);c!=null&&l.appendChild(c),this.fileContainer.appendChild(l),s={element:l,hunkData:r},this.separatorCache.set(i,s)}n.delete(i)}for(const[r,{element:i}]of n.entries())this.separatorCache.delete(r),i.remove()}renderAnnotations(){if(this.isContainerManaged||this.fileContainer==null){for(const{element:n}of this.annotationCache.values())n.remove();this.annotationCache.clear();return}const e=new Map(this.annotationCache),{renderAnnotation:t}=this.options;if(t!=null&&this.lineAnnotations.length>0)for(const[n,r]of this.lineAnnotations.entries()){const i=`${n}-${Xc(r)}`;let s=this.annotationCache.get(i);if(s==null||!FD(r,s.annotation)){s==null||s.element.remove();const l=t(r);if(l==null)continue;s={element:dD(Xc(r)),annotation:r},s.element.appendChild(l),this.fileContainer.appendChild(s.element),this.annotationCache.set(i,s)}e.delete(i)}for(const[n,{element:r}]of e.entries())this.annotationCache.delete(n),r.remove()}renderGutterUtility(){var r,i;const e=this.options.renderGutterUtility??this.options.renderHoverUtility;if(this.fileContainer==null||e==null){(r=this.gutterUtilityContent)==null||r.remove(),this.gutterUtilityContent=void 0;return}const t=e(this.interactionManager.getHoveredLine);if(t!=null&&this.gutterUtilityContent!=null)return;if(t==null){(i=this.gutterUtilityContent)==null||i.remove(),this.gutterUtilityContent=void 0;return}const n=fD();n.appendChild(t),this.fileContainer.appendChild(n),this.gutterUtilityContent=n}getOrCreateFileContainer(e,t){var r;const n=this.fileContainer;if(this.fileContainer=e??this.fileContainer??document.createElement(Of),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){const i=document.createElement("div");i.innerHTML=lD;const s=i.firstChild;s instanceof SVGElement&&(this.spriteSVG=s,(r=this.fileContainer.shadowRoot)==null||r.appendChild(this.spriteSVG))}return this.fileContainer}getFileContainer(){return this.fileContainer}getOrCreatePreNode(e){var n;const 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),(n=this.placeHolder)==null||n.remove(),this.placeHolder=void 0,this.pre}syncCodeNodesFromPre(e){this.codeUnified=void 0,this.codeDeletions=void 0,this.codeAdditions=void 0;for(const 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){var f,m,h,g,y,w;this.cleanupErrorWrapper(),(f=this.placeHolder)==null||f.remove(),this.placeHolder=void 0;const{fileDiff:n}=this,r=dl(e);if(r!==this.lastRenderedHeaderHTML){const _=document.createElement("div");_.innerHTML=r;const C=_.firstElementChild;if(!(C instanceof HTMLElement))return;this.headerElement!=null?(m=t.shadowRoot)==null||m.replaceChild(C,this.headerElement):(h=t.shadowRoot)==null||h.prepend(C),this.headerElement=C,this.lastRenderedHeaderHTML=r}if(this.isContainerManaged||n==null)return;const{renderCustomHeader:i,renderHeaderPrefix:s,renderHeaderMetadata:l}=this.options;if(i!=null){const _=i(n)??void 0;this.headerCustom=this.upsertHeaderSlotElement(t,this.headerCustom,w0,_),(g=this.headerPrefix)==null||g.remove(),(y=this.headerMetadata)==null||y.remove(),this.headerPrefix=void 0,this.headerMetadata=void 0;return}const c=(s==null?void 0:s(n))??void 0,d=(l==null?void 0:l(n))??void 0;this.headerPrefix=this.upsertHeaderSlotElement(t,this.headerPrefix,v0,c),this.headerMetadata=this.upsertHeaderSlotElement(t,this.headerMetadata,y0,d),(w=this.headerCustom)==null||w.remove(),this.headerCustom=void 0}clearHeaderSlots(){var e,t,n;(e=this.headerPrefix)==null||e.remove(),(t=this.headerMetadata)==null||t.remove(),(n=this.headerCustom)==null||n.remove(),this.headerPrefix=void 0,this.headerMetadata=void 0,this.headerCustom=void 0}upsertHeaderSlotElement(e,t,n,r){if(r==null){t==null||t.remove();return}const i=t??this.createHeaderSlotElement(n);return t==null&&e.appendChild(i),this.replaceHeaderSlotContent(i,r),i}replaceHeaderSlotContent(e,t){e.replaceChildren(),t instanceof Element?e.appendChild(t):e.innerText=`${t}`}createHeaderSlotElement(e){const t=document.createElement("div");return t.slot=e,t}injectUnsafeCSS(){var n,r;const{unsafeCSS:e}=this.options,t=(n=this.fileContainer)==null?void 0:n.shadowRoot;if(t!=null){if(e==null||e===""){this.unsafeCSSStyle!=null&&(this.unsafeCSSStyle.remove(),this.unsafeCSSStyle=void 0),this.appliedUnsafeCSS=void 0;return}((r=this.unsafeCSSStyle)==null?void 0:r.parentNode)===t&&this.appliedUnsafeCSS===e||(this.unsafeCSSStyle??(this.unsafeCSSStyle=hD()),this.unsafeCSSStyle.parentNode!==t&&t.appendChild(this.unsafeCSSStyle),this.unsafeCSSStyle.textContent=mD(e),this.appliedUnsafeCSS=e)}}applyThemeState(e,t,n,r){var l,c;const i=e.shadowRoot??e.attachShadow({mode:"open"}),s=r??n;((l=this.themeCSSStyle)==null?void 0:l.parentNode)===i&&((c=this.appliedThemeCSS)==null?void 0:c.themeStyles)===t&&this.appliedThemeCSS.themeType===s||(this.themeCSSStyle=vD({shadowRoot:i,currentNode:this.themeCSSStyle,themeCSS:gD(t,s)}),this.appliedThemeCSS=this.themeCSSStyle!=null?{themeStyles:t,themeType:s,baseThemeType:r}:void 0)}applyHunksToDOM(e,t){var m,h,g,y,w,_,C,I,E;const{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 s=!1;const l=[],c=this.hunksRenderer.renderCodeAST("unified",t),d=this.hunksRenderer.renderCodeAST("deletions",t),f=this.hunksRenderer.renderCodeAST("additions",t);c!=null?(s=this.codeUnified==null||this.codeAdditions!=null||this.codeDeletions!=null,(m=this.codeDeletions)==null||m.remove(),this.codeDeletions=void 0,(h=this.codeAdditions)==null||h.remove(),this.codeAdditions=void 0,this.codeUnified=Dm({code:this.codeUnified,columnType:"unified",rowSpan:i,containerSize:r}),this.codeUnified.innerHTML=this.hunksRenderer.renderPartialHTML(c),l.push(this.codeUnified)):d!=null||f!=null?(d!=null?(s=this.codeDeletions==null||this.codeUnified!=null,(g=this.codeUnified)==null||g.remove(),this.codeUnified=void 0,this.codeDeletions=Dm({code:this.codeDeletions,columnType:"deletions",rowSpan:i,containerSize:r}),this.codeDeletions.innerHTML=this.hunksRenderer.renderPartialHTML(d),l.push(this.codeDeletions)):((y=this.codeDeletions)==null||y.remove(),this.codeDeletions=void 0),f!=null?(s=s||this.codeAdditions==null||this.codeUnified!=null,(w=this.codeUnified)==null||w.remove(),this.codeUnified=void 0,this.codeAdditions=Dm({code:this.codeAdditions,columnType:"additions",rowSpan:i,containerSize:r}),this.codeAdditions.innerHTML=this.hunksRenderer.renderPartialHTML(f),l.push(this.codeAdditions)):((_=this.codeAdditions)==null||_.remove(),this.codeAdditions=void 0)):((C=this.codeUnified)==null||C.remove(),this.codeUnified=void 0,(I=this.codeDeletions)==null||I.remove(),this.codeDeletions=void 0,(E=this.codeAdditions)==null||E.remove(),this.codeAdditions=void 0),l.length===0?e.textContent="":s&&e.replaceChildren(...l),this.lastRowCount=t.rowCount}applyPartialRender({previousRenderRange:e,renderRange:t}){const{pre:n,codeUnified:r,codeAdditions:i,codeDeletions:s,options:{diffStyle:l="split"}}=this;if(n==null||e==null||t==null||!Number.isFinite(e.totalLines)||!Number.isFinite(t.totalLines)||this.lastRowCount==null)return!1;const c=this.getCodeColumns(l,r,s,i);if(c==null)return!1;const d=e.startingLine,f=t.startingLine,m=d+e.totalLines,h=f+t.totalLines,g=Math.max(d,f),y=Math.min(m,h);if(y<=g)return!1;const w=Math.max(0,g-d),_=Math.max(0,m-y),C=this.trimColumns({columns:c,trimStart:w,trimEnd:_,previousStart:d,overlapStart:g,overlapEnd:y,diffStyle:l});if(C<0)throw new Error("applyPartialRender: failed to trim to overlap");if(this.lastRowCount<C)throw new Error("applyPartialRender: trimmed beyond DOM row count");let I=this.lastRowCount-C;const E=(R,U)=>{if(!(U<=0||this.fileDiff==null))return this.hunksRenderer.renderDiff(this.fileDiff,{startingLine:R,totalLines:U,bufferBefore:0,bufferAfter:0})},S=E(f,Math.max(g-f,0));if(S==null&&f<g)return!1;const L=E(y,Math.max(h-y,0));if(L==null&&h>y)return!1;const A=(R,U)=>{if(R!=null){if(l==="unified"&&!Array.isArray(c))this.insertPartialHTML(l,c,R,U);else if(l==="split"&&Array.isArray(c))this.insertPartialHTML(l,c,R,U);else throw new Error("FileDiff.applyPartialRender.applyChunk: invalid chunk application");I+=R.rowCount}};return this.cleanupErrorWrapper(),A(S,"afterbegin"),A(L,"beforeend"),this.lastRowCount!==I&&(this.applyRowSpan(l,c,I),this.lastRowCount=I),!0}insertPartialHTML(e,t,n,r){if(e==="unified"&&!Array.isArray(t)){const i=this.hunksRenderer.renderCodeAST("unified",n);this.renderPartialColumn(t,i,r)}else if(e==="split"&&Array.isArray(t)){const i=this.hunksRenderer.renderCodeAST("deletions",n),s=this.hunksRenderer.renderCodeAST("additions",n);this.renderPartialColumn(t[0],i,r),this.renderPartialColumn(t[1],s,r)}else throw new Error("FileDiff.insertPartialHTML: Invalid argument composition")}renderPartialColumn(e,t,n){if(e==null||t==null)return;const r=cw(t[0]),i=cw(t[1]);if(r==null||i==null)throw new Error("FileDiff.insertPartialHTML: Unexpected AST structure");const s=i.at(0);n==="beforeend"&&(s==null?void 0:s.type)==="element"&&typeof s.properties["data-buffer-size"]=="number"&&this.mergeBuffersIfNecessary(s.properties["data-buffer-size"],e.content.children[e.content.children.length-1],e.gutter.children[e.gutter.children.length-1],r,i,!0);const l=i.at(-1);n==="afterbegin"&&(l==null?void 0:l.type)==="element"&&typeof l.properties["data-buffer-size"]=="number"&&this.mergeBuffersIfNecessary(l.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,s){if(!(t instanceof HTMLElement)||!(n instanceof HTMLElement))return;const l=this.getBufferSize(t.dataset);l!=null&&(s?(r.shift(),i.shift()):(r.pop(),i.pop()),this.updateBufferSize(t,l+e),this.updateBufferSize(n,l+e))}applyRowSpan(e,t,n){const r=i=>{i!=null&&(i.gutter.style.setProperty("grid-row",`span ${n}`),i.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 new Error("dun fuuuuked up")}trimColumnRows(e,t,n){let r=0,i=0,s=0,l=!1;const c=n>=0;if(e==null)return 0;const d=Array.from(e.content.children),f=Array.from(e.gutter.children);if(d.length!==f.length)throw new Error("FileDiff.trimColumnRows: columns do not match");for(;s<d.length&&!(t<=0&&!c&&!l);){const m=f[s],h=d[s];if(s++,!(m instanceof HTMLElement)||!(h instanceof HTMLElement))throw console.error({gutterElement:m,contentElement:h}),new Error("FileDiff.trimColumnRows: invalid row elements");if(l&&(l=!1,m.dataset.gutterBuffer==="annotation"&&"lineAnnotation"in h.dataset||m.dataset.gutterBuffer==="metadata"&&"noNewline"in h.dataset)){m.remove(),h.remove(),i++;continue}if("lineIndex"in m.dataset&&"lineIndex"in h.dataset){(t>0||c&&r>=n)&&(m.remove(),h.remove(),t>0&&(t--,t===0&&(l=!0)),i++),r++;continue}if("separator"in m.dataset&&"separator"in h.dataset){(t>0||c&&r>=n)&&(m.remove(),h.remove(),i++);continue}if(m.dataset.gutterBuffer==="annotation"&&"lineAnnotation"in h.dataset){(t>0||c&&r>=n)&&(m.remove(),h.remove(),i++);continue}if(m.dataset.gutterBuffer==="metadata"&&"noNewline"in h.dataset){(t>0||c&&r>=n)&&(m.remove(),h.remove(),i++);continue}if(m.dataset.gutterBuffer==="buffer"&&"contentBuffer"in h.dataset){const g=this.getBufferSize(h.dataset);if(g==null)throw new Error("FileDiff.trimColumnRows: invalid element");if(t>0){const y=Math.min(t,g),w=g-y;w>0?(this.updateBufferSize(m,w),this.updateBufferSize(h,w),i+=y):(m.remove(),h.remove(),i+=g),t-=y}else if(c){const y=r,w=r+g-1;if(n<=y)m.remove(),h.remove(),i+=g;else if(n<=w){const _=w-n+1,C=g-_;this.updateBufferSize(m,C),this.updateBufferSize(h,C),i+=_}}r+=g;continue}throw console.error({gutterElement:m,contentElement:h}),new Error("FileDiff.trimColumnRows: unknown row elements")}return i}trimColumns({columns:e,diffStyle:t,overlapEnd:n,overlapStart:r,previousStart:i,trimEnd:s,trimStart:l}){const c=Math.max(0,r-i),d=n-i;if(d<0)throw new Error("FileDiff.trimColumns: overlap ends before previous");const f=l>0,m=s>0;if(!f&&!m)return 0;const h=f?c:0,g=m?d:-1;if(t==="unified"&&!Array.isArray(e))return this.trimColumnRows(e,h,g);if(t==="split"&&Array.isArray(e)){const y=this.trimColumnRows(e[0],h,g),w=this.trimColumnRows(e[1],h,g);if(e[0]!=null&&e[1]!=null&&y!==w)throw new Error("FileDiff.trimColumns: split columns out of sync");return e[0]!=null?y:w}else throw console.error({diffStyle:t,columns:e}),new Error("FileDiff.trimColumns: Invalid columns for diffType")}getBufferSize(e){const t=Number.parseInt((e==null?void 0: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(s){if(s==null)return;const l=s.children[0],c=s.children[1];if(!(!(l instanceof HTMLElement)||!(c instanceof HTMLElement)||l.dataset.gutter==null||c.dataset.content==null))return{gutter:l,content:c}}if(e==="unified")return i(t);{const s=i(n),l=i(r);return s!=null||l!=null?[s,l]:void 0}}applyBuffers(e,t){const{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==null&&(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==null&&(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){const{diffIndicators:s="bars",disableBackground:l=!1,disableLineNumbers:c=!1,overflow:d="scroll",diffStyle:f="split"}=this.options,m={type:"diff",diffIndicators:s,disableBackground:l,disableLineNumbers:c,overflow:d,split:f==="unified"?!1:t!=null&&n!=null,totalLines:r,customProperties:i};cD(m,this.appliedPreAttributes)||(bD(e,m),this.appliedPreAttributes=m)}applyErrorToDOM(e,t){this.cleanupErrorWrapper();const n=this.getOrCreatePreNode(t);n.innerHTML="",n.remove(),this.pre=void 0,this.appliedPreAttributes=void 0;const r=t.shadowRoot??t.attachShadow({mode:"open"});this.errorWrapper??(this.errorWrapper=document.createElement("div")),this.errorWrapper.dataset.errorWrapper="",this.errorWrapper.innerHTML="",r.appendChild(this.errorWrapper);const i=document.createElement("div");i.dataset.errorMessage="",i.innerText=e.message,this.errorWrapper.appendChild(i);const s=document.createElement("pre");s.dataset.errorStack="",s.innerText=e.stack??"No Error Stack",this.errorWrapper.appendChild(s)}cleanupErrorWrapper(){var e;(e=this.errorWrapper)==null||e.remove(),this.errorWrapper=void 0}},F(Wm,"LoadedCustomComponent",xD),Wm);function UD({fileDiff:e,oldFile:t,newFile:n}){return e!=null&&e.hunks.length>0||t!=null||n!=null}function zD({fileDiff:e,oldFile:t,newFile:n}){return e!=null||t!=null||n!=null}function HD(e,t,n=!1){return!n&&e==null&&t}function WD(e,t,n=!1){return e==null&&t&&!n}function cw(e){if(!(e==null||e.type!=="element"))return e.children??[]}function GD(e,t){const n={...eI,...t};return n.hunkSeparatorHeight=qD(e,t==null?void 0:t.hunkSeparatorHeight),n}function qD(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}}let KD=-1;var XD=class extends $_{constructor(t,n,r,i,s=!1){super(t,i,s);F(this,"__id",`little-virtualized-file-diff:${++KD}`);F(this,"top");F(this,"height",0);F(this,"metrics");F(this,"heightCache",new Map);F(this,"isVisible",!1);F(this,"isSetup",!1);F(this,"virtualizer");F(this,"onRender",t=>this.fileContainer==null?!1:(t&&(this.top=this.virtualizer.getOffsetInScrollContainer(this.fileContainer)),this.render()));F(this,"expandHunk",(t,n,r)=>{this.hunksRenderer.expandHunk(t,n,r),this.computeApproximateSize(),this.renderRange=void 0,this.virtualizer.instanceChanged(this)});const{hunkSeparators:l="line-info"}=this.options;this.virtualizer=n,this.metrics=GD(typeof l=="function"?"custom":l,r)}getLineHeight(t,n=!1){const r=this.heightCache.get(t);if(r!=null)return r;const i=n?2:1;return this.metrics.lineHeight*i}setOptions(t){if(t==null)return;const n=this.options.diffStyle,r=this.options.overflow,i=this.options.collapsed;super.setOptions(t),(n!==this.options.diffStyle||r!==this.options.overflow||i!==this.options.collapsed)&&(this.heightCache.clear(),this.computeApproximateSize(),this.renderRange=void 0),this.virtualizer.instanceChanged(this)}reconcileHeights(){const{overflow:t="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(t==="scroll"&&this.lineAnnotations.length===0&&!this.virtualizer.config.resizeDebugging)return;const n=this.getDiffStyle();let r=!1;const i=n==="split"?[this.codeDeletions,this.codeAdditions]:[this.codeUnified];for(const s of i){if(s==null)continue;const l=s.children[1];if(l instanceof HTMLElement)for(const c of l.children){if(!(c instanceof HTMLElement))continue;const d=c.dataset.lineIndex;if(d==null)continue;const f=YD(d,n);let m=c.getBoundingClientRect().height,h=!1;c.nextElementSibling instanceof HTMLElement&&("lineAnnotation"in c.nextElementSibling.dataset||"noNewline"in c.nextElementSibling.dataset)&&("noNewline"in c.nextElementSibling.dataset&&(h=!0),m+=c.nextElementSibling.getBoundingClientRect().height);const g=this.getLineHeight(f,h);m!==g&&(r=!0,m===this.metrics.lineHeight*(h?2:1)?this.heightCache.delete(f):this.heightCache.set(f,m))}}(r||this.virtualizer.config.resizeDebugging)&&this.computeApproximateSize()}cleanUp(){this.fileContainer!=null&&this.virtualizer.disconnect(this.fileContainer),this.isSetup=!1,super.cleanUp()}setVisibility(t){this.fileContainer!=null&&(this.renderRange=void 0,t&&!this.isVisible?(this.top=this.virtualizer.getOffsetInScrollContainer(this.fileContainer),this.isVisible=!0):!t&&this.isVisible&&(this.isVisible=!1,this.rerender()))}computeApproximateSize(){const t=this.height===0;if(this.height=0,this.fileDiff==null)return;const{disableFileHeader:n=!1,expandUnchanged:r=!1,collapsed:i=!1,collapsedContextThreshold:s=ll,hunkSeparators:l="line-info"}=this.options,{diffHeaderHeight:c,fileGap:d,hunkSeparatorHeight:f}=this.metrics,m=this.getDiffStyle(),h=l!=="simple"&&l!=="metadata"&&l!=="line-info-basic"?d:0;if(n?l!=="simple"&&l!=="metadata"&&(this.height+=d):this.height+=c,!i&&(Qf({diff:this.fileDiff,diffStyle:m,expandedHunks:r?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:s,callback:({hunkIndex:g,collapsedBefore:y,collapsedAfter:w,deletionLine:_,additionLine:C})=>{const I=C!=null?C.splitLineIndex:_.splitLineIndex,E=C!=null?C.unifiedLineIndex:_.unifiedLineIndex,S=((C==null?void 0:C.noEOFCR)??!1)||((_==null?void 0:_.noEOFCR)??!1);y>0&&(g>0&&(this.height+=h),this.height+=f+h),this.height+=this.getLineHeight(m==="split"?I:E,S),w>0&&l!=="simple"&&(this.height+=h+f)}}),this.fileDiff.hunks.length>0&&(this.height+=d),this.fileContainer!=null&&this.virtualizer.config.resizeDebugging&&!t)){const g=this.fileContainer.getBoundingClientRect();g.height!==this.height?console.log("VirtualizedFileDiff.computeApproximateSize: computed height doesnt match",{name:this.fileDiff.name,elementHeight:g.height,computedHeight:this.height}):console.log("VirtualizedFileDiff.computeApproximateSize: computed height IS CORRECT")}}render({fileContainer:t,oldFile:n,newFile:r,fileDiff:i,...s}={}){const{isSetup:l}=this;if(this.fileDiff??(this.fileDiff=i??(n!=null&&r!=null?kg(n,r,this.options.parseDiffOptions):void 0)),t=this.getOrCreateFileContainer(t),this.fileDiff==null)return console.error("VirtualizedFileDiff.render: attempting to virtually render when we dont have the correct data"),!1;if(l?this.top??(this.top=this.virtualizer.getOffsetInScrollContainer(t)):(this.computeApproximateSize(),this.virtualizer.connect(t,this),this.top??(this.top=this.virtualizer.getOffsetInScrollContainer(t)),this.isVisible=this.virtualizer.isInstanceVisible(this.top,this.height),this.isSetup=!0),!this.isVisible)return this.renderPlaceholder(this.height);const c=this.virtualizer.getWindowSpecs(),d=this.computeRenderRangeFromWindow(this.fileDiff,this.top,c);return super.render({fileDiff:this.fileDiff,fileContainer:t,renderRange:d,oldFile:n,newFile:r,...s})}getDiffStyle(){return this.options.diffStyle??"split"}getExpandedRegion(t,n,r){if(r<=0||t)return{fromStart:0,fromEnd:0,collapsedLines:Math.max(r,0),renderAll:!1};const{expandUnchanged:i=!1,collapsedContextThreshold:s=ll}=this.options;if(i||r<=s)return{fromStart:r,fromEnd:0,collapsedLines:0,renderAll:!0};const l=this.hunksRenderer.getExpandedHunk(n),c=Math.min(Math.max(l.fromStart,0),r),d=Math.min(Math.max(l.fromEnd,0),r),f=c+d,m=f>=r;return{fromStart:c,fromEnd:d,collapsedLines:Math.max(r-f,0),renderAll:m}}getExpandedLineCount(t,n){let r=0;if(t.isPartial){for(const s of t.hunks)r+=n==="split"?s.splitLineCount:s.unifiedLineCount;return r}for(const[s,l]of t.hunks.entries()){const c=n==="split"?l.splitLineCount:l.unifiedLineCount;r+=c;const d=Math.max(l.collapsedBefore,0),{fromStart:f,fromEnd:m,renderAll:h}=this.getExpandedRegion(t.isPartial,s,d);d>0&&(r+=h?d:f+m)}const i=t.hunks.at(-1);if(i!=null&&QD(t)){const s=t.additionLines.length-(i.additionLineIndex+i.additionCount),l=t.deletionLines.length-(i.deletionLineIndex+i.deletionCount);if(i!=null&&s!==l)throw new Error(`VirtualizedFileDiff: trailing context mismatch (additions=${s}, deletions=${l}) for ${t.name}`);const c=Math.min(s,l);if(i!=null&&c>0){const{fromStart:d,renderAll:f}=this.getExpandedRegion(t.isPartial,t.hunks.length,c);r+=f?c:d}}return r}computeRenderRangeFromWindow(t,n,{top:r,bottom:i}){const{disableFileHeader:s=!1,expandUnchanged:l=!1,collapsedContextThreshold:c=ll,hunkSeparators:d="line-info"}=this.options,{diffHeaderHeight:f,fileGap:m,hunkLineCount:h,hunkSeparatorHeight:g,lineHeight:y}=this.metrics,w=this.getDiffStyle(),_=this.height,C=this.getExpandedLineCount(t,w),I=s?m:f;if(n<r-_||n>i)return{startingLine:0,totalLines:0,bufferBefore:0,bufferAfter:_-I-m};if(C<=h||t.hunks.length===0)return{startingLine:0,totalLines:h,bufferBefore:0,bufferAfter:0};const E=Math.ceil(Math.max(i-r,0)/y),S=Math.ceil(E/h)*h+h,L=S/h,A=L,R=[],U=(r+i)/2,X=d==="simple"||d==="metadata"||d==="line-info-basic"?0:m;let H=n+I,re=0,de,te,Q;if(Qf({diff:t,diffStyle:w,expandedHunks:l?!0:this.hunksRenderer.getExpandedHunksMap(),collapsedContextThreshold:c,callback:({hunkIndex:J,collapsedBefore:fe,collapsedAfter:we,deletionLine:be,additionLine:Pe})=>{const Ne=Pe!=null?Pe.splitLineIndex:be.splitLineIndex,he=Pe!=null?Pe.unifiedLineIndex:be.unifiedLineIndex,Te=((Pe==null?void 0:Pe.noEOFCR)??!1)||((be==null?void 0:be.noEOFCR)??!1);let Qe=fe>0?g+X+(J>0?X:0):0;J===0&&d==="simple"&&(Qe=0),H+=Qe;const pt=re%h===0;if(pt&&(R.push(H-(n+I+Qe)),Q!=null)){if(Q<=0)return!0;Q--}const mt=this.getLineHeight(w==="split"?Ne:he,Te),ct=Math.floor(re/h);return H>r-mt&&H<i&&(de??(de=ct)),te==null&&H+mt>U&&(te=ct),Q==null&&H>=i&&pt&&(Q=A),re++,H+=mt,we>0&&d!=="simple"&&(H+=g+X),!1}}),de==null)return{startingLine:0,totalLines:0,bufferBefore:0,bufferAfter:_-I-m};const ee=R.length;te??(te=de);const K=Math.round(te-L/2),oe=Math.max(0,ee-L),ie=Math.max(0,Math.min(K,oe)),W=ie*h,ce=K<0?S+K*h:S,le=R[ie]??0,O=ie+ce/h;return{startingLine:W,totalLines:ce,bufferBefore:le,bufferAfter:O<R.length?_-I-R[O]-m:_-(H-n)-m}}};function QD(e){const 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 YD(e,t){const[n,r]=e.split(",").map(Number);return t==="split"?r:n}const JD=typeof window>"u"?B.useEffect:B.useLayoutEffect;function ZD({fileDiff:e,options:t,lineAnnotations:n,selectedLines:r,prerenderedHTML:i,metrics:s,hasGutterRenderUtility:l,hasCustomHeader:c,disableWorkerPool:d}){const f=oI(),m=B.useContext(UL),h=B.useRef(null),g=zL(y=>{if(y!=null){if(h.current!=null)throw new Error("useFileDiffInstance: An instance should not already exist when a node is created");f!=null?h.current=new XD(Nm({hasCustomHeader:c,hasGutterRenderUtility:l,options:t}),f,s,d?void 0:m,!0):h.current=new $_(Nm({hasCustomHeader:c,hasGutterRenderUtility:l,options:t}),d?void 0:m,!0),h.current.hydrate({fileDiff:e,fileContainer:y,lineAnnotations:n,prerenderedHTML:i})}else{if(h.current==null)throw new Error("useFileDiffInstance: A FileDiff instance should exist when unmounting");h.current.cleanUp(),h.current=null}});return JD(()=>{const{current:y}=h;if(y==null)return;const w=Nm({hasCustomHeader:c,hasGutterRenderUtility:l,options:t}),_=!_D(y.options,w);y.setOptions(w),y.render({forceRender:_,fileDiff:e,lineAnnotations:n}),r!==void 0&&y.setSelectedLines(r)}),{ref:g,getHoveredLine:B.useCallback(()=>{var y;return(y=h.current)==null?void 0:y.getHoveredLine()},[])}}function Nm({options:e,hasCustomHeader:t,hasGutterRenderUtility:n}){return n||t?{...e,renderCustomHeader:t?qv:void 0,renderGutterUtility:n?qv:void 0}:e}function e7(e){const t=jD(e);if(t.length!==1)throw console.error(t),new Error("PatchDiff: Provided patch must include only 1 patch, with 1 diff");const{files:n}=t[0];if(n.length!==1)throw console.error(n),new Error("FileDiff: Provided patch must contain exactly 1 file diff");return n[0]}function t7({patch:e,options:t,metrics:n,lineAnnotations:r,selectedLines:i,className:s,style:l,prerenderedHTML:c,renderAnnotation:d,renderCustomHeader:f,renderHeaderPrefix:m,renderHeaderMetadata:h,renderGutterUtility:g,renderHoverUtility:y,disableWorkerPool:w=!1}){const _=n7(e),{ref:C,getHoveredLine:I}=ZD({fileDiff:_,options:t,metrics:n,lineAnnotations:r,selectedLines:i,prerenderedHTML:c,hasGutterRenderUtility:g!=null||y!=null,hasCustomHeader:f!=null,disableWorkerPool:w});return P.jsx(Of,{ref:C,className:s,style:l,children:rI(ED({fileDiff:_,renderCustomHeader:f,renderHeaderPrefix:m,renderHeaderMetadata:h,renderAnnotation:d,lineAnnotations:r,renderGutterUtility:g,renderHoverUtility:y,getHoveredLine:I}),c)})}function n7(e){return B.useMemo(()=>e7(e),[e])}const Hc="file-tree-container",Fm="data-file-tree-style",uw="data-file-tree-unsafe-css",r7="data-file-tree-scrollbar-measure",dw="data-file-tree-scrollbar-gutter-measured",i7="--trees-scrollbar-gutter-measured",fw="f::",Yf="header",al="context-menu",Sg="context-menu-trigger",hw=typeof window>"u"?B.useEffect:B.useLayoutEffect;function o7(e,t,n){const r=e!=null?P.jsx("div",{slot:Yf,children:e}):null,i=t!=null&&n!=null?P.jsx("div",{slot:al,children:t(n.item,n.context)}):null;return r==null&&i==null?null:P.jsxs(P.Fragment,{children:[r,i]})}function s7(e,t){return typeof window>"u"&&t!=null?P.jsxs(P.Fragment,{children:[P.jsx("template",{shadowrootmode:"open",dangerouslySetInnerHTML:{__html:t.shadowHtml}}),e]}):P.jsx(P.Fragment,{children:e})}function a7(e){const t=e.shadowRoot;return(t==null?void 0:t.querySelector("[data-file-tree-id]"))instanceof HTMLElement||(t==null?void 0:t.querySelector("[data-file-tree-id]"))instanceof SVGElement?!0:e.querySelector('template[shadowrootmode="open"]')instanceof HTMLTemplateElement}function l7(e,t,n,r,i){const s={...e??{}};if(t!=null&&delete s.header,n){const l=e==null?void 0:e.contextMenu,c=l==null?void 0:l.onClose,d=l==null?void 0:l.onOpen;s.contextMenu={...l??{},enabled:!0,onClose:()=>{c==null||c(),r()},onOpen:(f,m)=>{i(f,m),d==null||d(f,m)}},delete s.contextMenu.render}return s.header!=null||s.contextMenu!=null?s:void 0}function c7({header:e,id:t,model:n,preloadedData:r,renderContextMenu:i,...s}){const[l,c]=B.useState(null),[d,f]=B.useState(null),m=B.useRef(n.getComposition()),h=B.useRef(n);h.current!==n&&(h.current=n,m.current=n.getComposition());const g=i!=null,y=B.useCallback(()=>{c(null)},[]),w=B.useCallback((A,R)=>{c({context:R,item:A})},[]),_=m.current,C=B.useMemo(()=>l7(_,e,g,y,w),[_,y,w,g,e]),I=B.useCallback(A=>{f(A)},[]);B.useEffect(()=>{g||c(null)},[g]),hw(()=>{n.setComposition(C)},[C,n]),hw(()=>{if(d!=null)return r!=null&&a7(d)?n.hydrate({fileTreeContainer:d}):n.render({fileTreeContainer:d}),()=>{n.unmount(),n.setComposition(_)}},[_,d,n,r]);const E=s7(o7(e,i,l),r),S=t??(r==null?void 0:r.id),L={"--trees-item-height":`${String(n.getItemHeight())}px`,"--trees-density-override":n.getDensityFactor(),...s.style};return P.jsx(Hc,{...s,id:S,ref:I,style:L,suppressHydrationWarning:r!=null,children:E})}const B_=`<svg data-icon-sprite aria-hidden="true" width="0" height="0">
429
+ <symbol id="file-tree-icon-chevron" viewBox="0 0 16 16">
430
+ <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" fill="currentcolor"/>
431
+ </symbol>
432
+ <symbol id="file-tree-icon-dot" viewBox="0 0 6 6">
433
+ <circle cx="3" cy="3" r="3" />
434
+ </symbol>
435
+ <symbol id="file-tree-icon-file" viewBox="0 0 16 16">
436
+ <path fill="currentColor" d="M8 1v3a3 3 0 0 0 3 3h3v5.5a2.5 2.5 0 0 1-2.5 2.5h-7A2.5 2.5 0 0 1 2 12.5v-9A2.5 2.5 0 0 1 4.5 1z" class="bg" opacity=".5"/>
437
+ <path fill="currentColor" d="M9.5 1a.5.5 0 0 1 .354.146l4 4A.5.5 0 0 1 14 5.5V6h-3a2 2 0 0 1-2-2V1z" class="fg"/>
438
+ </symbol>
439
+ <symbol id="file-tree-icon-lock" viewBox="0 0 16 16">
440
+ <path fill="currentcolor" d="M4 5.336V4a4 4 0 1 1 8 0v1.336c1.586.54 2 1.843 2 4.664v1c0 4.118-.883 5-5 5H7c-4.117 0-5-.883-5-5v-1c0-2.821.414-4.124 2-4.664M5.5 4v1.054Q6.166 4.998 7 5h2q.834-.002 1.5.054V4a2.5 2.5 0 0 0-5 0m-2 6v1c0 .995.055 1.692.167 2.193.107.483.246.686.35.79s.307.243.79.35c.5.112 1.198.167 2.193.167h2c.995 0 1.692-.055 2.193-.166.483-.108.686-.247.79-.35.104-.105.243-.308.35-.791.112-.5.167-1.198.167-2.193v-1c0-.995-.055-1.692-.166-2.193-.108-.483-.247-.686-.35-.79-.105-.104-.308-.243-.791-.35C10.693 6.555 9.995 6.5 9 6.5H7c-.995 0-1.692.055-2.193.167-.483.107-.686.246-.79.35s-.243.307-.35.79C3.555 8.307 3.5 9.005 3.5 10" />
441
+ </symbol>
442
+ <symbol id="file-tree-icon-ellipsis" viewBox="0 0 16 16">
443
+ <path d="M5 8.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0M9.5 8.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0M14 8.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0" />
444
+ </symbol>
445
+ </svg>`,u7=`<symbol id="file-tree-builtin-astro" viewBox="0 0 16 16">
446
+ <path fill="currentColor" d="M6.08 13.92c-.63-.57-.81-1.79-.55-2.67.45.56 1.08.73 1.73.83 1 .15 1.99.1 2.92-.37l.32-.19q.13.38.08.78a2.1 2.1 0 0 1-.9 1.5q-.3.24-.61.43c-.64.44-.81.95-.57 1.69l.02.08a1.7 1.7 0 0 1-.74-.64 2 2 0 0 1-.3-.98q0-.27-.02-.52-.07-.61-.61-.62a.7.7 0 0 0-.75.6z" class="bg" opacity=".6"/>
447
+ <path fill="currentColor" d="M2.5 11.1s1.86-.9 3.72-.9l1.4-4.39c.05-.21.2-.36.38-.36s.33.15.38.36l1.4 4.38c2.2 0 3.72.92 3.72.92l-3.16-8.69q-.13-.4-.45-.42H6.11q-.3.02-.45.42z" class="fg"/>
448
+ </symbol>`,d7=`<symbol id="file-tree-builtin-babel" viewBox="0 0 16 16">
449
+ <path fill="currentColor" fill-rule="evenodd" d="M9.49.5q1.92.05 2.66.54 1.27.6 1.35 1.52v.23a4 4 0 0 1-.53 1.9l-1.38 1.24q-.74.38-.72.63c.77.82 1.33 1.29.85 2.42q-.47 1.1-2.04 2.28c-.5.32-1.88 1.35-2.96 1.86-1.64.77-3.1 1.4-4.65 1.89-.51.16-1.5.16-1.5.16L.5 15A76 76 0 0 0 5.76 3.49q-.1-.08-.1-.2.1 0 .32-.35l-.03-.09q-1.17.39-2.38 1.3l-.13.03q0-.1-.21-.16-.46.31-.82.7l-.13-.19.16-.06-.03-.16-.34.29L2 4.5q.36-.48.72-.54l.04-.1V3.8q.16 0 .15-.06l.13-.06a6 6 0 0 0 1.13-.9v-.03H4.1l-.12.07q0-.1-.1-.1l-.15.07-.04-.1q.93-.52 1.63-1.05Q7.89.65 9.5.5M8.46 7.83l-.32.04c-1.31.54-2.31.82-2.91.88a71 71 0 0 0-2.2 4.54h.07q.58-.04 3.04-1.42.13 0 1.66-1.05L9.18 9.7v.03q.45-.2.81-1.3v-.2q-.5-.46-1.53-.4m.28-5.75c-.5.1-.75.19-.72.38l-1.16 2.6q-.17.1-.34.95-.3.48-.25.77v.1l.22.05A15 15 0 0 1 8.86 6c1.1-.71 2.12-1.38 2.8-2.54q.24-.33.21-.54-.02-.33-.4-.54c-.54 0-1.07-.34-1.63-.28l-.94-.03z" clip-rule="evenodd"/>
450
+ </symbol>`,f7=`<symbol id="file-tree-builtin-bash" viewBox="0 0 16 16">
451
+ <path fill="currentColor" d="M8 1C2.24 1 1 2.24 1 8s1.24 7 7 7 7-1.24 7-7-1.24-7-7-7" class="bg" opacity=".2"/>
452
+ <path fill="currentColor" d="M11.5 11a.5.5 0 0 1 0 1h-3a.5.5 0 0 1 0-1zM7 6.75C7 6.42 6.64 6 6 6s-1 .42-1 .75q-.01.25.22.41.26.21.89.35.74.14 1.28.53c.37.29.61.7.61 1.21 0 .87-.68 1.5-1.5 1.7v.55a.5.5 0 0 1-1 0v-.56c-.82-.18-1.5-.82-1.5-1.69a.5.5 0 0 1 1 0c0 .33.36.75 1 .75s1-.42 1-.75q.01-.25-.22-.41a2 2 0 0 0-.89-.35q-.74-.14-1.28-.53A1.5 1.5 0 0 1 4 6.75c0-.87.68-1.5 1.5-1.7V4.5a.5.5 0 0 1 1 0v.56c.82.18 1.5.82 1.5 1.69a.5.5 0 0 1-1 0" class="fg-stroke"/>
453
+ </symbol>`,h7=`<symbol id="file-tree-builtin-biome" viewBox="0 0 16 16">
454
+ <path fill="currentColor" d="M8 2 4.88 7.35a7 7 0 0 1 3.7-.13l1.04.25-.99 4.16-1.05-.25a2.7 2.7 0 0 0-3.07 1.45l-.98-.47a4 4 0 0 1 1.07-1.31 3.8 3.8 0 0 1 3.23-.71l.5-2.08a6 6 0 0 0-5.07 1.12A5.9 5.9 0 0 0 1 14h14z"/>
455
+ </symbol>`,p7=`<symbol id="file-tree-builtin-bootstrap" viewBox="0 0 16 16">
456
+ <path fill="currentColor" fill-rule="evenodd" d="M11.72 1.5A2.5 2.5 0 0 1 14.2 4q.02 1.08.3 2.09c.22.73.56 1.24 1.08 1.45.22.08.4.27.4.5s-.18.43-.4.51q-.76.34-1.08 1.45c-.2.65-.27 1.32-.3 2a2.5 2.5 0 0 1-2.48 2.5H4.25A2.6 2.6 0 0 1 1.7 12c-.04-.85-.1-1.68-.22-2.04C1.26 9.23.92 8.7.4 8.5.18 8.42 0 8.23 0 8s.18-.42.4-.5q.77-.35 1.09-1.46c.1-.36.17-1.19.2-2.04a2.6 2.6 0 0 1 2.56-2.5z" class="bg" clip-rule="evenodd" opacity=".2"/>
457
+ <path fill="currentColor" fill-rule="evenodd" d="M8.47 4.54c1.23 0 2.04.68 2.04 1.73 0 .73-.55 1.39-1.24 1.5v.04c.94.1 1.58.77 1.58 1.7 0 1.2-.9 1.95-2.37 1.95H5.97a.3.3 0 0 1-.2-.08.3.3 0 0 1-.08-.2V4.82a.3.3 0 0 1 .08-.2.3.3 0 0 1 .2-.08zm-1.7 6.04h1.49q1.47-.01 1.49-1.15Q9.74 8.31 8.2 8.3H6.77zm0-5.16v2.06h1.21c.93 0 1.45-.38 1.45-1.06 0-.65-.44-1-1.22-1z" class="fg" clip-rule="evenodd"/>
458
+ </symbol>`,m7=`<symbol id="file-tree-builtin-browserslist" viewBox="0 0 16 16">
459
+ <path fill="currentColor" d="M8.88 6.96c0 3.82 3.72 4.7 5.7 3.74-.23.9-1.04 1.67-2.35 1.93-.02.4.42 1.28.82 1.63-.9.35-1.94-.12-2.51-.48a5 5 0 0 0-.32 1.87c-.68 0-1.57-1-1.8-1.37-.3.18-.85 1.15-.96 1.72a2.4 2.4 0 0 1-.81-.86 2.4 2.4 0 0 1-.3-1.15c-.38.27-1.48.95-1.99 1.18-.25-.58-.15-1.3 0-2.06-.21.12-1.8.27-2.43.12.32-.36.75-1.19.94-1.57A4.5 4.5 0 0 1 .44 10.6c.48-.22.97-.53 1.49-1.06C1.26 9.17.24 8.64 0 7.7a6 6 0 0 0 1.79-.32C1.28 7.08.44 6.15.6 5.01c.42.21 1.3.37 1.73.3a3.4 3.4 0 0 1-.25-2.75 5 5 0 0 0 1.48 1c-.08-.8.3-2.31.8-2.71.2.46.73 1.21 1.08 1.4.09-.61.87-2.06 1.57-2.25 0 .5.27 1.4.5 1.67.51-.54 2.25-1.44 3.64-1.13-.43.45-.75.61-.86.98 1.05 0 2.78.34 4.27 1.93-2.34-.89-5.69.56-5.69 3.5" class="bg" opacity=".5"/>
460
+ <path fill="currentColor" d="M11.21 3.59a4.1 4.1 0 0 0 2.47 2.89c.24-.22.61-.38.95-.19.76.44.2 1.26-.34 1.66l-.07.06a13 13 0 0 1-4.49 1.61l-.3-.43a10.5 10.5 0 0 0 4.13-1.31 1 1 0 0 0 .23-.25.5.5 0 0 0-.21-.69l-.15-.06a4.5 4.5 0 0 1-1.77-1.31 4.5 4.5 0 0 1-.88-1.77q.2-.12.43-.21"/>
461
+ <path fill="currentColor" d="M10.36 5.18a.4.4 0 0 0-.03.38c.09.2.3.3.46.23s.24-.3.15-.5l-.01-.02q.23.13.34.39a.83.83 0 0 1-.43 1.08.8.8 0 0 1-1.08-.43.83.83 0 0 1 .6-1.13"/>
462
+ </symbol>`,g7=`<symbol id="file-tree-builtin-bun" viewBox="0 0 16 16">
463
+ <path fill="currentColor" d="M8 14c3.87 0 7-2.46 7-5.49 0-1.88-1.2-3.53-3.04-4.52q-1.1-.61-1.84-1.07C9.2 2.35 8.64 2 8 2s-1.36.45-2.31 1.03A29 29 0 0 1 4.04 4C2.2 4.98 1 6.63 1 8.51 1 11.54 4.13 14 8 14M7.18 3.88q.3-.66.3-1.37c0-.08.11-.1.13-.01.38 1.57-.53 2.35-1.2 2.61-.08.03-.12-.07-.06-.12a3 3 0 0 0 .83-1.12m1.2-.05a3 3 0 0 0-.45-1.3V2.5c-.04-.07.05-.15.1-.1 1.15 1.2.77 2.3.33 2.87-.05.05-.13 0-.11-.08q.21-.67.13-1.37m1.04-.32a3 3 0 0 0-.94-1.02v-.01c-.06-.05-.01-.16.07-.12 1.51.61 1.61 1.8 1.43 2.5l-.03.03a.07.07 0 0 1-.1-.06 3 3 0 0 0-.43-1.32m-2.97.32c-.36.3-.74.43-1.2.56q-.11 0-.1-.1a3.5 3.5 0 0 0 1.76-1.57s.09-.07.1.04c0 .18-.2.76-.56 1.07m2.89 6.36q-.13.52-.55.88a1.3 1.3 0 0 1-.75.35 1.3 1.3 0 0 1-.77-.35 1.7 1.7 0 0 1-.54-.88.13.13 0 0 1 .15-.15h2.31a.14.14 0 0 1 .15.15M6.15 8.95a1.1 1.1 0 0 1-1.39-.14A1.1 1.1 0 0 1 5.12 7a1.1 1.1 0 0 1 1.2.25 1.1 1.1 0 0 1-.17 1.69m4.96 0a1.1 1.1 0 0 1-1.4-.14 1.1 1.1 0 0 1 .37-1.8 1.1 1.1 0 0 1 1.2.25 1.1 1.1 0 0 1 .24 1.2 1 1 0 0 1-.41.5"/>
464
+ </symbol>`,v7=`<symbol id="file-tree-builtin-claude" viewBox="0 0 16 16">
465
+ <path fill="currentColor" d="M3.75 10.31 6.5 8.77l.04-.14-.04-.07h-.14l-.46-.03-1.57-.04-1.38-.07-1.33-.07-.34-.07L1 7.86l.03-.21.28-.18.4.03.89.07 1.33.08.97.06 1.43.16h.22l.03-.1-.07-.05-.06-.06-1.39-.92-1.48-.98-.79-.57-.42-.28-.2-.28-.1-.6.39-.41.52.04.12.03.52.4 1.12.86L6.2 6.04l.2.17.09-.06.01-.04-.1-.15-.76-1.46-.85-1.46-.37-.6-.1-.36a1 1 0 0 1-.06-.42l.42-.59.25-.07.6.08.22.2.36.84.58 1.3.9 1.77.29.53.14.47.04.14h.1v-.07l.07-1 .14-1.22.14-1.57.04-.45.23-.53.42-.28.36.15.28.41-.04.25-.16 1.08-.36 1.7-.21 1.14h.12l.14-.15.58-.76.97-1.2.42-.5.5-.51.32-.25h.6l.44.66-.2.68-.61.79-.52.65-.74 1-.45.8.04.05h.1l1.68-.36.9-.16 1.06-.18.5.23.05.22-.2.48-1.15.28-1.34.28-2 .46-.04.01.03.04.9.09.4.03h.94l1.77.14.46.28.27.37-.04.28-.72.37-.95-.23-2.24-.53-.76-.18h-.11v.06l.64.63L12 10.86l1.48 1.35.07.34-.18.28-.2-.03-1.29-.98-.5-.42-1.12-.95h-.07v.1l.25.38 1.37 2.05.07.63-.1.2-.36.14-.38-.08-.8-1.12-.85-1.26-.66-1.15-.07.05-.4 4.23-.19.21-.42.17-.35-.28-.2-.42.2-.87.23-1.12.18-.9.17-1.1.1-.36v-.03h-.1l-.84 1.16-1.27 1.72-1 1.07-.24.1-.42-.22.04-.39.22-.32 1.4-1.8.84-1.1.57-.64-.02-.07h-.04l-3.7 2.4-.66.09-.28-.28.03-.42.14-.14 1.12-.77z"/>
466
+ </symbol>`,y7=`<symbol id="file-tree-builtin-css" viewBox="0 0 16 16">
467
+ <path fill="currentColor" d="M8 15c-5.76 0-7-1.24-7-7V2a1 1 0 0 1 1-1h6c5.77 0 7 1.24 7 7s-1.24 7-7 7" class="vector" opacity=".2"/>
468
+ <path fill="currentColor" d="M10.1 9.19h.73c.03.49.22.6 1 .6.76 0 .93-.12.93-.68 0-.52-.17-.67-.94-.85-1.38-.3-1.68-.56-1.68-1.47 0-1.05.3-1.29 1.67-1.29 1.29 0 1.57.2 1.6 1.13h-.74c-.01-.34-.17-.42-.85-.42-.77 0-.94.1-.94.58 0 .42.17.55.96.73 1.36.3 1.66.58 1.66 1.59 0 1.14-.31 1.39-1.73 1.39-1.39 0-1.69-.24-1.67-1.31m-3.9 0h.74c.03.49.21.6.99.6.76 0 .93-.12.93-.68 0-.52-.17-.67-.93-.85-1.39-.3-1.69-.56-1.69-1.47 0-1.05.3-1.29 1.67-1.29 1.3 0 1.58.2 1.6 1.13h-.73c-.02-.34-.18-.42-.85-.42-.78 0-.95.1-.95.58 0 .42.17.55.96.73 1.37.3 1.67.58 1.67 1.59 0 1.14-.32 1.39-1.74 1.39-1.38 0-1.68-.24-1.66-1.31m-1.22 0h.75c-.09 1.07-.37 1.31-1.56 1.31-1.37 0-1.68-.45-1.68-2.5 0-1.96.36-2.5 1.68-2.5 1.16 0 1.44.25 1.52 1.35h-.76c-.08-.52-.22-.64-.76-.64-.74 0-.9.33-.9 1.78 0 1.47.16 1.8.9 1.8.58 0 .74-.11.8-.6"/>
469
+ </symbol>`,w7=`<symbol id="file-tree-builtin-database" viewBox="0 0 16 16">
470
+ <path fill="currentColor" d="M14.953 9.733a12.4 12.4 0 0 1-.244 1.936c-.207.933-.532 1.58-.996 2.044s-1.11.789-2.044.996C10.73 14.918 9.533 15 8 15s-2.73-.082-3.669-.291c-.933-.207-1.58-.532-2.044-.996s-.789-1.11-.996-2.044c-.122-.547-.2-1.182-.244-1.92q.23.364.532.667c.64.639 1.482 1.031 2.533 1.265 1.046.232 2.33.315 3.884.315 1.555 0 2.838-.083 3.884-.315 1.051-.234 1.893-.626 2.532-1.265a4 4 0 0 0 .541-.683"/>
471
+ <path fill="currentColor" d="M14.93 5.924c-.046.663-.118 1.24-.23 1.743-.207.932-.532 1.579-.995 2.042s-1.11.789-2.042.996c-.938.209-2.135.291-3.667.291-1.531 0-2.729-.082-3.667-.29-.932-.208-1.579-.534-2.042-.997s-.789-1.11-.996-2.042a12 12 0 0 1-.227-1.683l.016-.188a4 4 0 0 0 .5.62c.638.639 1.48 1.031 2.532 1.265 1.046.232 2.33.315 3.884.315 1.555 0 2.838-.083 3.884-.315 1.051-.234 1.893-.626 2.532-1.265.192-.192.357-.404.506-.633z"/>
472
+ <path fill="currentColor" d="M8 1c1.533 0 2.73.082 3.669.291.933.207 1.58.533 2.044.996.403.404.904.944.91 1.695.004.764-.509 1.318-.918 1.727-.463.463-1.11.789-2.042.996-.938.209-2.135.291-3.667.291-1.531 0-2.729-.082-3.667-.29-.932-.208-1.579-.534-2.042-.997-.406-.406-.915-.953-.915-1.71 0-.758.509-1.305.915-1.712.464-.463 1.11-.789 2.044-.996C5.27 1.082 6.467 1 8 1"/>
473
+ </symbol>`,b7=`<symbol id="file-tree-builtin-default" viewBox="0 0 16 16">
474
+ <path fill="currentColor" d="M8 1v3a3 3 0 0 0 3 3h3v5.5a2.5 2.5 0 0 1-2.5 2.5h-7A2.5 2.5 0 0 1 2 12.5v-9A2.5 2.5 0 0 1 4.5 1z" class="bg" opacity=".4"/>
475
+ <path fill="currentColor" d="M9.5 1a.5.5 0 0 1 .354.146l4 4A.5.5 0 0 1 14 5.5V6h-3a2 2 0 0 1-2-2V1z" class="fg"/>
476
+ </symbol>`,x7=`<symbol id="file-tree-builtin-docker" viewBox="0 0 16 16">
477
+ <path fill="currentColor" d="M15.85 6.54c-.05-.04-.45-.36-1.31-.36q-.34 0-.68.06a2.7 2.7 0 0 0-1.14-1.79l-.23-.14-.15.23a3 3 0 0 0-.4 1q-.24 1.01.26 1.84c-.4.24-1.03.3-1.17.3H.5a.5.5 0 0 0-.5.52q-.01 1.46.46 2.83.55 1.5 1.6 2.18c.79.5 2.08.79 3.54.79q.96 0 1.94-.18a8 8 0 0 0 2.55-.97 7 7 0 0 0 1.73-1.5 10 10 0 0 0 1.7-3.06h.15a2.4 2.4 0 0 0 1.8-.7 2 2 0 0 0 .47-.74l.06-.2z"/>
478
+ <path fill="currentColor" d="M1.48 7.36h1.4a.14.14 0 0 0 .14-.13V5.91q-.01-.12-.13-.14H1.48a.13.13 0 0 0-.13.14v1.32q.02.13.13.13m1.94 0h1.41a.14.14 0 0 0 .13-.13V5.91q-.01-.12-.13-.14h-1.4a.13.13 0 0 0-.13.14v1.32q0 .13.12.13m1.98 0h1.4q.13 0 .14-.13V5.91a.13.13 0 0 0-.14-.14H5.4q-.1.01-.12.14v1.32q0 .13.12.13m1.95 0h1.42q.1 0 .12-.13V5.91q0-.12-.12-.14H7.35q-.1.01-.12.14v1.32q.01.13.12.13M3.42 5.5h1.41c.07 0 .13-.08.13-.15V4.03a.13.13 0 0 0-.13-.14h-1.4q-.12 0-.13.14v1.31q0 .13.12.15m1.98 0h1.4c.08 0 .14-.08.14-.15V4.03q0-.13-.14-.14H5.4q-.1 0-.12.14v1.31q0 .13.12.15m1.95 0h1.42c.06 0 .12-.08.12-.15V4.03q-.01-.13-.12-.14H7.35q-.1 0-.12.14v1.31q.01.13.12.15m0-1.9h1.42q.1-.02.12-.14v-1.3Q8.88 2 8.77 2H7.35q-.1 0-.12.14v1.3q.01.13.12.14m1.97 3.78h1.4a.13.13 0 0 0 .14-.13V5.91q-.01-.12-.13-.14H9.32q-.1.01-.12.14v1.32q.01.13.12.13" opacity=".5"/>
479
+ </symbol>`,_7=`<symbol id="file-tree-builtin-eslint" viewBox="0 0 16 16">
480
+ <path fill="currentColor" d="M11.16 6.1 8.12 4.35a.3.3 0 0 0-.24 0L4.84 6.1a.3.3 0 0 0-.12.2v3.5q0 .14.12.22l3.04 1.74q.12.08.24 0l3.04-1.74a.2.2 0 0 0 .13-.22V6.3a.3.3 0 0 0-.13-.2" opacity=".5"/>
481
+ <path fill="currentColor" d="m.1 7.69 3.63-6.3A.8.8 0 0 1 4.37 1h7.26c.26 0 .5.17.64.4l3.63 6.27a.8.8 0 0 1 0 .75l-3.63 6.24a.7.7 0 0 1-.64.34H4.37a.7.7 0 0 1-.64-.34L.1 8.41a.7.7 0 0 1 0-.72m3 3.02q.01.15.14.23l4.63 2.66q.13.06.26 0l4.63-2.66a.3.3 0 0 0 .14-.23V5.4a.3.3 0 0 0-.14-.23L8.13 2.52a.3.3 0 0 0-.26 0L3.24 5.17a.3.3 0 0 0-.14.23z"/>
482
+ </symbol>`,k7=`<symbol id="file-tree-builtin-font" viewBox="0 0 16 16">
483
+ <path fill="currentColor" d="M12.3 13c-1.59 0-2.68-.99-2.68-2.5 0-1.43 1-2.34 2.88-2.35h2.16v-.83c0-1.08-.62-1.68-1.73-1.68-1.05 0-1.66.54-1.73 1.36H9.93c.09-1.43 1.06-2.48 3.05-2.48 1.75 0 3.02.95 3.02 2.68v5.66h-1.29v-1.02h-.04c-.41.66-1.16 1.16-2.37 1.16m.36-1.12c1.14 0 2-.72 2-1.74v-.96H12.6c-1.12 0-1.6.54-1.6 1.28 0 .97.8 1.42 1.66 1.42m-11.24.98H0L3.8 2h1.39l3.8 10.86H7.54l-1.08-3.2H2.5zm3.09-9.25h-.04l-1.6 4.95H6.1z"/>
484
+ </symbol>`,S7=`<symbol id="file-tree-builtin-git" viewBox="0 0 16 16">
485
+ <path fill="currentColor" d="M14.74 7.38 8.62 1.26a.9.9 0 0 0-1.27 0L6.08 2.53l1.61 1.61a1.07 1.07 0 0 1 1.36 1.37l1.55 1.55a1.07 1.07 0 0 1 1.1 1.77 1.07 1.07 0 0 1-1.74-1.16L8.5 6.22v3.8a1.07 1.07 0 1 1-.89-.02V6.15a1.07 1.07 0 0 1-.58-1.4l-1.58-1.6-4.2 4.2a.9.9 0 0 0 0 1.27l6.12 6.12a.9.9 0 0 0 1.27 0l6.09-6.09a.9.9 0 0 0 0-1.27"/>
486
+ </symbol>`,C7=`<symbol id="file-tree-builtin-go" viewBox="0 0 16 16">
487
+ <path fill="currentColor" fill-rule="evenodd" d="M4.41 4.57A3.2 3.2 0 0 1 6.87 5q.74.49 1.08 1.29.08.12-.1.16l-1.55.4c-.14.03-.15.04-.27-.1a1 1 0 0 0-.44-.34 1.6 1.6 0 0 0-1.68.14q-.95.61-.94 1.73c0 .73.52 1.33 1.25 1.43q.95.1 1.58-.6l.25-.34h-1.8c-.19 0-.24-.12-.17-.27.12-.28.34-.76.47-1a.3.3 0 0 1 .24-.14h2.98a4 4 0 0 1 .64-1.19 4 4 0 0 1 2.6-1.52 3.5 3.5 0 0 1 2.64.46q1.13.73 1.31 2.04a3.5 3.5 0 0 1-1.06 3.09q-.93.92-2.23 1.17l-.74.08a3.5 3.5 0 0 1-2.27-.8 3 3 0 0 1-.93-1.42 4 4 0 0 1-.39.61 4 4 0 0 1-2.64 1.56 3.3 3.3 0 0 1-2.5-.6 3 3 0 0 1-1.18-2.03 3.5 3.5 0 0 1 .8-2.67 4 4 0 0 1 2.6-1.58M13.1 7.5a1.53 1.53 0 0 0-1.9-1.21q-1.3.3-1.62 1.59a1.5 1.5 0 0 0 .85 1.72q.77.33 1.52-.05a2 2 0 0 0 1.18-1.74q0-.17-.03-.3" clip-rule="evenodd"/>
488
+ </symbol>`,E7=`<symbol id="file-tree-builtin-graphql" viewBox="0 0 16 16">
489
+ <path fill="currentColor" fill-rule="evenodd" d="M8 1a1.25 1.25 0 0 1 1.18 1.65l2.8 1.61q.33-.25.77-.26a1.25 1.25 0 0 1 .48 2.4v3.2a1.25 1.25 0 1 1-1.25 2.13l-2.8 1.62A1.25 1.25 0 0 1 8 15a1.25 1.25 0 0 1-1.18-1.65l-2.8-1.62q-.33.26-.77.27a1.25 1.25 0 0 1-.48-2.4V6.4a1.25 1.25 0 1 1 1.25-2.14l2.8-1.61A1.25 1.25 0 0 1 8 1M4.44 11.14l-.06.13 2.75 1.58a1.25 1.25 0 0 1 1.74 0l2.74-1.58-.05-.13zm3.89-7.68a1.3 1.3 0 0 1-.66 0L4.03 9.77q.37.3.45.78h7.04q.08-.48.45-.78zM4.38 4.73a1.24 1.24 0 0 1-1.02 1.76v3.02l.13.01 3.67-6.35-.03-.02zm4.46-1.56 3.67 6.35.13-.01V6.49a1.25 1.25 0 0 1-1.03-1.76L8.87 3.15z" clip-rule="evenodd"/>
490
+ </symbol>`,I7=`<symbol id="file-tree-builtin-html" viewBox="0 0 16 16">
491
+ <path fill="currentColor" d="M8 1C2.24 1 1 2.24 1 8s1.24 7 7 7 7-1.24 7-7-1.24-7-7-7" class="bg" opacity=".2"/>
492
+ <path fill="currentColor" d="M10.48 3.76a.5.5 0 0 1 .4.58L10.6 5.8h1.14a.5.5 0 0 1 0 1h-1.32L10 9.2h1.08a.5.5 0 0 1 0 1H9.8l-.3 1.64a.5.5 0 1 1-.98-.18l.27-1.46H6.4l-.3 1.64a.5.5 0 1 1-.98-.18l.27-1.46H4.25a.5.5 0 0 1 0-1h1.32L6 6.8H4.93a.5.5 0 0 1 0-1H6.2l.3-1.64a.5.5 0 1 1 .98.18L7.2 5.8h2.4l.3-1.64a.5.5 0 0 1 .58-.4M6.58 9.2h2.4l.44-2.4h-2.4z" class="fg"/>
493
+ </symbol>`,P7=`<symbol id="file-tree-builtin-image" viewBox="0 0 16 16">
494
+ <path fill="currentColor" d="M12.5 2A2.5 2.5 0 0 1 15 4.5v4.67l-4.05-3.54-4.08 4.08-3-2L1 10.6V4.5A2.5 2.5 0 0 1 3.5 2z" opacity=".3"/>
495
+ <path fill="currentColor" d="M15 10.5v1a2.5 2.5 0 0 1-2.5 2.5h-9a2.5 2.5 0 0 1-2.46-2.04L4 9l3 2 4-4zm-7-5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0"/>
496
+ </symbol>`,L7=`<symbol id="file-tree-builtin-javascript" viewBox="0 0 16 16">
497
+ <path fill="currentColor" d="M8 1C2.24 1 1 2.24 1 8s1.24 7 7 7 7-1.24 7-7-1.24-7-7-7" class="bg" opacity=".2"/>
498
+ <path fill="currentColor" d="M8.1 9.64h.95c.04.62.28.76 1.28.76s1.2-.14 1.2-.85c0-.66-.2-.85-1.2-1.07-1.79-.38-2.18-.7-2.18-1.86C8.15 5.3 8.54 5 10.31 5c1.67 0 2.04.26 2.07 1.42h-.95c-.02-.43-.23-.53-1.1-.53-1 0-1.22.14-1.22.74 0 .52.22.7 1.24.92 1.76.38 2.15.73 2.15 2 0 1.44-.4 1.75-2.24 1.75-1.8 0-2.18-.3-2.15-1.66M3.5 9.5h.98c0 .76.15.92.85.92.77 0 .94-.18.94-1.02V5.1h1v4.34c0 1.54-.35 1.87-1.92 1.87-1.55 0-1.89-.32-1.86-1.8"/>
499
+ </symbol>`,D7=`<symbol id="file-tree-builtin-json" viewBox="0 0 16 16">
500
+ <path fill="currentColor" d="M13.25 11.5V9.75a.5.5 0 0 1 .36-.48l.55-.15a1.16 1.16 0 0 0 0-2.24l-.55-.15a.5.5 0 0 1-.36-.48V4.5a2.5 2.5 0 0 0-2.5-2.5h-.25a.5.5 0 0 0 0 1h.25a1.5 1.5 0 0 1 1.5 1.5v1.75a1.5 1.5 0 0 0 1.09 1.44l.54.15a.16.16 0 0 1 0 .32l-.54.15a1.5 1.5 0 0 0-1.09 1.44v1.75a1.5 1.5 0 0 1-1.5 1.5h-.25a.5.5 0 0 0 0 1h.25a2.5 2.5 0 0 0 2.5-2.5m-10.5 0V9.75a.5.5 0 0 0-.36-.48l-.55-.15a1.16 1.16 0 0 1 0-2.24l.55-.15a.5.5 0 0 0 .36-.48V4.5A2.5 2.5 0 0 1 5.25 2h.25a.5.5 0 0 1 0 1h-.25a1.5 1.5 0 0 0-1.5 1.5v1.75a1.5 1.5 0 0 1-1.09 1.44l-.54.15a.16.16 0 0 0 0 .32l.54.15a1.5 1.5 0 0 1 1.09 1.45v1.74a1.5 1.5 0 0 0 1.5 1.5h.25a.5.5 0 0 1 0 1h-.25a2.5 2.5 0 0 1-2.5-2.5"/>
501
+ </symbol>`,A7=`<symbol id="file-tree-builtin-markdown" viewBox="0 0 16 16">
502
+ <path fill="currentColor" d="M1 12V4h2l2 2.5L7 4h2v8H7V7.5l-2 2-2-2V12zm9-3 3 3.5L16 9h-2V4h-2v5z"/>
503
+ </symbol>`,T7=`<symbol id="file-tree-builtin-mcp" viewBox="0 0 16 16">
504
+ <path fill="currentColor" d="M9.26-.04a3 3 0 0 1 2 .82 2.8 2.8 0 0 1 .8 2.35 2.9 2.9 0 0 1 2.41.8l.03.02a2.74 2.74 0 0 1 0 3.94l-5.8 5.69-.04.06-.02.07q0 .04.02.07.01.04.04.06l1.2 1.17a.55.55 0 0 1 0 .79.6.6 0 0 1-.81 0l-1.2-1.17a1.3 1.3 0 0 1 0-1.84L13.7 7.1a1.65 1.65 0 0 0 .37-1.82 2 2 0 0 0-.37-.54l-.03-.03a1.73 1.73 0 0 0-2.4 0L6.47 9.4l-.07.06a.58.58 0 0 1-.92-.18.6.6 0 0 1 .12-.6l4.85-4.76a1.65 1.65 0 0 0 0-2.36 1.73 1.73 0 0 0-2.4 0l-6.43 6.3a.6.6 0 0 1-.8 0 .55.55 0 0 1 0-.8L7.25.79a3 3 0 0 1 2-.82"/>
505
+ <path fill="currentColor" d="M9.26 2.19a.6.6 0 0 1 .52.34.6.6 0 0 1 0 .43l-.12.18L4.9 7.79a1.65 1.65 0 0 0 0 2.36 1.73 1.73 0 0 0 2.4 0l4.75-4.66a.58.58 0 0 1 .93.18.6.6 0 0 1-.12.61l-4.75 4.66a2.9 2.9 0 0 1-4.01 0 2.75 2.75 0 0 1-.62-3.04A3 3 0 0 1 4.1 7l4.74-4.65a.6.6 0 0 1 .4-.16"/>
506
+ </symbol>`,R7=`<symbol id="file-tree-builtin-nextjs" viewBox="0 0 16 16">
507
+ <defs>
508
+ <linearGradient id="a" x1="4.522" x2="14" y1="3.943" y2="16" gradientUnits="userSpaceOnUse">
509
+ <stop stop-color="currentColor"/>
510
+ <stop offset="1" stop-color="currentColor" stop-opacity="0"/>
511
+ </linearGradient>
512
+ </defs>
513
+ <path fill="currentColor" d="M3 2h1.522v9.09H3z"/>
514
+ <path fill="url(#a)" d="M4.903 2 15 15.075q-.565.5-1.195.925L4.522 3.943z"/>
515
+ <path fill="currentColor" d="M12.172 2h-1.508v9.094h1.508z"/>
516
+ </symbol>`,N7=`<symbol id="file-tree-builtin-npm" viewBox="0 0 16 16">
517
+ <path fill="currentColor" d="M2 1a1 1 0 0 0-1 1v12a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1V2a1 1 0 0 0-1-1z" class="vector" opacity=".2"/>
518
+ <path fill="currentColor" d="M10.5 13H13V3H3v10h5V5.5h2.5z"/>
519
+ </symbol>`,F7=`<symbol id="file-tree-builtin-oxc" viewBox="0 0 16 16">
520
+ <path fill="currentColor" d="M9.5 1a.5.5 0 0 1 .5.5V3h3.5a.5.5 0 0 1 .38.83L10.5 7.69v1.44q.41.04.95-.16a4 4 0 0 0 .72-.35l.04-.03h.01a.5.5 0 0 1 .67.1l2 2.5a.5.5 0 0 1 0 .62c-.76.96-3.14 2.69-6.89 2.69s-6.13-1.73-6.89-2.69a.5.5 0 0 1 0-.62l2-2.5a.5.5 0 0 1 .67-.1l.05.03.16.09q.22.13.56.26.54.2.95.16V7.69L2.12 3.83A.5.5 0 0 1 2.5 3H6V1.5a.5.5 0 0 1 .5-.5zM7 3.5a.5.5 0 0 1-.5.5H3.6l2.78 3.17a.5.5 0 0 1 .12.33v2a.5.5 0 0 1-.28.45c-.7.35-1.5.15-2.02-.05a5 5 0 0 1-.58-.26l-1.46 1.84c.82.78 2.8 2.02 5.84 2.02s5.02-1.24 5.84-2.02l-1.46-1.83a5 5 0 0 1-.58.26c-.52.2-1.33.39-2.02.04a.5.5 0 0 1-.28-.45v-2a.5.5 0 0 1 .12-.33L12.4 4H9.5a.5.5 0 0 1-.5-.5V2H7z"/>
521
+ </symbol>`,M7=`<symbol id="file-tree-builtin-postcss" viewBox="0 0 16 16">
522
+ <path fill="currentColor" d="M14.5 8a6.5 6.5 0 0 0-5.9-6.47l5.42 8.93A7 7 0 0 0 14.5 8M2.88 12A6.5 6.5 0 0 0 8 14.5c2.08 0 3.93-.98 5.12-2.5zm8.62-1h1.68L11.5 8.24zm-1-.55a4 4 0 0 1-.7.55h.7zM8 5.5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5M5.5 11h.7a4 4 0 0 1-.7-.55zm-2.68 0H4.5V8.24zm3.76-6.2A4 4 0 0 1 8 4.5q.76 0 1.42.3L8 2.46zM1.5 8q0 1.31.48 2.46L7.4 1.53A6.5 6.5 0 0 0 1.5 8m14 0a7.5 7.5 0 0 1-.99 3.72l-.01.03-.02.03A7.5 7.5 0 0 1 8 15.5a7.5 7.5 0 0 1-6.5-3.75l-.01-.03A7.5 7.5 0 1 1 15.5 8"/>
523
+ </symbol>`,O7=`<symbol id="file-tree-builtin-prettier" viewBox="0 0 16 16">
524
+ <path fill="currentColor" d="M6 12v1H4.93v-1zm1-2v1H2v-1zm6-4v1h-3V6zm-1-4v1H9V2z"/>
525
+ <path fill="currentColor" d="M11.5 10v1H8v-1zM5 6v1H2V6zm5-2v1H9V4z" opacity=".8"/>
526
+ <path fill="currentColor" d="M6 14v1H2v-1zm-.5-6v1H2V8zM13 4v1h-3V4zM4.93 2v1H2V2z" opacity=".6"/>
527
+ <path fill="currentColor" d="M4.93 12v1H2v-1zM13 8v1H9V8zM5.5 4v1H2V4zM9 2v1H4.93V2z" opacity=".4"/>
528
+ </symbol>`,$7=`<symbol id="file-tree-builtin-python" viewBox="0 0 16 16">
529
+ <path fill="currentColor" d="M8.33 8.4H10c1.16 0 1.9-.73 1.9-1.86V5.08q0-.24.25-.24h.74c.75 0 1.33.32 1.66.97q.4.73.41 1.46c.09.9.09 1.78-.24 2.67-.25.73-.75 1.3-1.58 1.46h-4.8c-.08 0-.25 0-.25.08v.4s.17.09.25.09h2.82q.34-.02.33.32v1.06c0 .56-.25.97-.75 1.13-.41.16-.83.33-1.24.4a7 7 0 0 1-2.98-.07 3 3 0 0 1-1.16-.49c-.33-.32-.58-.65-.5-1.14v-2.91c0-1.13.67-1.78 1.82-1.78q.89-.1 1.66-.08m2.32 4.86a.65.65 0 0 0-.66-.65c-.34 0-.67.33-.67.65s.33.57.67.65a.65.65 0 0 0 .66-.65" class="bg" opacity=".8"/>
530
+ <path fill="currentColor" d="M7.67 7.6H6c-1.16 0-1.9.73-1.9 1.86v1.46q0 .24-.25.24h-.74c-.75 0-1.33-.32-1.66-.97a3 3 0 0 1-.41-1.46 6 6 0 0 1 .24-2.67c.25-.73.75-1.3 1.58-1.46h4.8c.08 0 .25 0 .25-.08v-.4s-.17-.09-.25-.09H4.85c-.24 0-.33-.08-.33-.32V2.65c0-.56.25-.97.75-1.13.41-.16.83-.33 1.24-.4a7 7 0 0 1 2.98.07c.41.09.83.25 1.16.49.33.32.58.65.5 1.13v2.92c0 1.14-.67 1.78-1.82 1.78-.58.08-1.16.08-1.66.08M5.35 2.73c0 .33.25.65.66.65.33 0 .66-.32.66-.65 0-.32-.33-.56-.66-.64a.65.65 0 0 0-.66.64" class="fg"/>
531
+ </symbol>`,B7=`<symbol id="file-tree-builtin-react" viewBox="0 0 16 16">
532
+ <path fill="currentColor" d="M8 6.65c.73 0 1.31.6 1.31 1.35S8.73 9.35 8 9.35 6.69 8.75 6.69 8 7.27 6.65 8 6.65"/>
533
+ <path fill="currentColor" fill-rule="evenodd" d="M8 2.55c1.3-.99 2.59-1.34 3.5-.8.92.55 1.27 1.87 1.08 3.53C14.06 5.94 15 6.9 15 8s-.94 2.06-2.42 2.72c.19 1.65-.16 2.98-1.08 3.52-.91.55-2.2.2-3.5-.8-1.3 1-2.58 1.35-3.5.8-.91-.54-1.27-1.87-1.08-3.52C1.94 10.06 1 9.1 1 8s.94-2.06 2.42-2.72c-.19-1.66.17-2.98 1.08-3.52s2.2-.2 3.5.8M4.26 11.2c-.08 1.34.28 2.03.68 2.26s1.15.22 2.25-.52l.11-.09a12 12 0 0 1-1.24-1.39 11 11 0 0 1-1.8-.41zm7.47-.15q-.83.27-1.79.41-.6.8-1.24 1.4l.11.08c1.1.74 1.86.76 2.25.52.4-.23.76-.92.68-2.26zm-3.04.54a14 14 0 0 1-1.38 0q.34.38.69.7.35-.32.7-.7M8 5.29q-.76 0-1.47.1A13 13 0 0 0 5.07 8a14 14 0 0 0 1.46 2.62 13 13 0 0 0 2.94 0A13 13 0 0 0 10.93 8a14 14 0 0 0-1.46-2.62A13 13 0 0 0 8 5.3M4.64 9.18q-.15.5-.25.96.44.16.94.27a15 15 0 0 1-.7-1.23m6.73 0a15 15 0 0 1-.7 1.23q.5-.11.95-.27a10 10 0 0 0-.25-.96M3.44 6.26C2.27 6.86 1.87 7.53 1.87 8s.4 1.14 1.57 1.74l.13.07q.18-.88.55-1.81a12 12 0 0 1-.55-1.8q-.07.02-.13.06m8.99-.07A12 12 0 0 1 11.88 8q.36.94.55 1.8l.13-.06c1.17-.6 1.56-1.27 1.56-1.74s-.39-1.14-1.56-1.74zm-7.1-.6q-.5.11-.94.27.1.46.25.96a15 15 0 0 1 .69-1.23m5.34 0a15 15 0 0 1 .7 1.23q.14-.5.24-.96-.44-.15-.94-.27M7.18 3.06c-1.09-.74-1.85-.76-2.24-.52s-.76.92-.69 2.26l.01.15a11 11 0 0 1 1.8-.41q.6-.8 1.24-1.4zm3.88-.52c-.4-.24-1.15-.22-2.25.52l-.12.08q.65.6 1.25 1.4.96.15 1.8.41v-.14c.08-1.35-.28-2.04-.68-2.27M8 3.7a10 10 0 0 0-.7.7 14 14 0 0 1 1.4 0 10 10 0 0 0-.7-.7" clip-rule="evenodd"/>
534
+ </symbol>`,j7=`<symbol id="file-tree-builtin-ruby" viewBox="0 0 16 16">
535
+ <path fill="currentColor" fill-rule="evenodd" d="M11.04 2c.48 0 .92.23 1.18.6l2.54 3.65c.37.52.3 1.23-.15 1.69l-5.58 5.64a1.47 1.47 0 0 1-2.06 0L1.39 7.94a1.3 1.3 0 0 1-.15-1.7l2.54-3.63q.2-.3.5-.45.33-.16.68-.16zm.84 2.17a.5.5 0 0 0-.7-.05L8 6.84 4.83 4.12a.5.5 0 0 0-.65.76L6.65 7H3.5a.5.5 0 0 0 0 1h9a.5.5 0 0 0 0-1H9.35l2.48-2.12a.5.5 0 0 0 .05-.7" clip-rule="evenodd"/>
536
+ </symbol>`,V7=`<symbol id="file-tree-builtin-rust" viewBox="0 0 16 16">
537
+ <path fill="currentColor" fill-rule="evenodd" d="M8 .8a.2.2 0 0 1 .18.1l.38.6.16.02.5-.53.01-.01a.2.2 0 0 1 .33.08l.25.68.16.05.59-.43h.02a.2.2 0 0 1 .3.14l.12.71.15.08.65-.3a.2.2 0 0 1 .2.02.2.2 0 0 1 .1.18l-.03.72.12.1.71-.16a.2.2 0 0 1 .25.25l-.17.7q.06.06.1.13l.73-.03A.2.2 0 0 1 14 4a.2.2 0 0 1 .02.2l-.3.66.08.14.71.12a.2.2 0 0 1 .14.32l-.43.59.05.16.68.25a.2.2 0 0 1 .07.35l-.53.49.01.16.62.38a.2.2 0 0 1 0 .36l-.62.38-.01.16.53.5a.2.2 0 0 1-.07.34l-.68.25-.05.16.43.59a.2.2 0 0 1-.14.32l-.72.12-.07.15.3.65a.2.2 0 0 1-.02.2.2.2 0 0 1-.18.1l-.72-.03-.1.13.16.7a.2.2 0 0 1-.25.25l-.7-.17-.13.1.03.73a.2.2 0 0 1-.1.18.2.2 0 0 1-.2.02l-.66-.3-.14.08-.12.71a.2.2 0 0 1-.32.14l-.59-.43-.16.05-.25.68a.2.2 0 0 1-.34.07l-.5-.53-.16.01-.38.62a.2.2 0 0 1-.36 0l-.38-.62-.16-.01-.5.53a.2.2 0 0 1-.34-.07l-.25-.68-.16-.05-.59.43a.2.2 0 0 1-.32-.14L5 13.78l-.15-.07-.65.3a.2.2 0 0 1-.2-.02.2.2 0 0 1-.1-.18l.03-.72-.13-.1-.7.16a.2.2 0 0 1-.25-.25l.17-.7-.1-.13-.73.03a.2.2 0 0 1-.2-.3l.3-.66-.08-.14-.71-.12a.2.2 0 0 1-.14-.32l.43-.59-.05-.16-.68-.25A.2.2 0 0 1 1 9.22l.53-.5-.02-.16-.6-.38A.2.2 0 0 1 .8 8a.2.2 0 0 1 .1-.18l.6-.38.02-.16-.53-.5a.2.2 0 0 1 .07-.34l.68-.25.05-.16-.43-.59a.2.2 0 0 1 .14-.32L2.2 5l.08-.15L2 4.2a.2.2 0 0 1 .2-.3l.72.03.1-.13-.16-.7a.2.2 0 0 1 .25-.25l.7.16.13-.1-.03-.72A.2.2 0 0 1 4 2a.2.2 0 0 1 .2-.02l.65.3L5 2.2l.12-.71v-.03a.2.2 0 0 1 .32-.1l.59.41.16-.04.25-.68.01-.02A.2.2 0 0 1 6.8.99l.49.53.16-.02.38-.61.02-.02A.2.2 0 0 1 8 .79M6.8 9.45h1.26l.06.01q.03.01.03.05v1.52q0 .07-.09.06h-4.5A5.4 5.4 0 0 0 8 13.42a5.4 5.4 0 0 0 4.45-2.33h-2.42c-.36 0-.68-.5-.77-.75-.08-.22-.2-.91-.25-1.12-.15-.61-.59-.71-.78-.73H6.8zM8 2.58a5.4 5.4 0 0 0-4.07 1.85h5.74l.17.02c.23.03.6.12.96.35.34.23.83.68.83 1.4 0 .66-.55 1.16-1.08 1.5.42.33.7.53.86 1.44.04.17.34.32.62.29.29-.03.62-.16.62-.75v-.24q0-.1.07-.1h.68A5.43 5.43 0 0 0 8 2.59M2.96 6.03a5.4 5.4 0 0 0-.19 3.37h1.66V6.03zM6.8 7.06h1.66c.35 0 .77-.12.77-.47 0-.42-.55-.53-.65-.53H6.8z" clip-rule="evenodd"/>
538
+ </symbol>`,U7=`<symbol id="file-tree-builtin-sass" viewBox="0 0 16 16">
539
+ <path fill="currentColor" fill-rule="evenodd" d="M8.08 1.44c2.41-.91 4.96-.37 5.35 1.27.39 1.62-.92 3.56-2.6 4.25a5 5 0 0 1-3.26.35c-.58-.2-.92-.62-1-.85-.03-.09-.09-.24 0-.3.05-.03.08-.02.22.15s.7.6 1.75.48c2.78-.34 4.45-2.64 3.92-3.88-.37-.87-2.5-1.26-5.18.16C4.03 4.81 3.85 6.24 3.82 6.8c-.08 1.5 1.73 2.28 2.7 3.4q.04.03.07.08c.3-.12.7-.19 1.35-.2 1.58-.03 2.47 1.08 2.43 2.08-.03.78-.7 1.1-.82 1.13-.1.01-.14.02-.15-.06q-.03-.06.13-.15c.16-.09.42-.3.48-.72.05-.43-.24-1.44-1.76-1.63a3 3 0 0 0-1.33.08c.27.62.32 1.87-.29 2.83-.63 1-1.8 1.61-2.93 1.27-.37-.1-.93-.92-.45-2.05.46-1.07 2.4-2.12 2.66-2.26-.9-.83-3.08-1.95-3.4-3.65-.08-.49.13-1.65 1.46-2.98a12 12 0 0 1 4.11-2.52m-1.88 9.7c-.01.01-.9.47-1.52 1.17-.59.66-.75 1.48-.43 1.69.3.18 1-.04 1.51-.62a3 3 0 0 0 .5-.9q.2-.64.02-1.39z" clip-rule="evenodd"/>
540
+ </symbol>`,z7=`<symbol id="file-tree-builtin-stylelint" viewBox="0 0 16 16">
541
+ <path fill="currentColor" d="M4 3v3.5l1.5-1L7 15 .5 6l1-1.5L0 3l2.5-2h1zm12 0-1.5 1.5 1 1.5L9 15l1.5-9.5 1.5 1V3l.5-2h1zm-8 8.5a.5.5 0 1 1 0 1 .5.5 0 0 1 0-1m0-3a.5.5 0 1 1 0 1 .5.5 0 0 1 0-1m0-3a.5.5 0 1 1 0 1 .5.5 0 0 1 0-1"/>
542
+ <path fill="currentColor" d="M6.5 2.5V4l-2 1.5v-4zm5 3L9.5 4V2.5l2-1zM9 4H7V2.5h2z"/>
543
+ </symbol>`,H7=`<symbol id="file-tree-builtin-svelte" viewBox="0 0 16 16">
544
+ <path fill="currentColor" d="m3.98 3.7 3.36-2.08a4.5 4.5 0 0 1 5.9 1.23 4 4 0 0 1 .7 3.02q-.16.75-.58 1.4c.42.77.56 1.66.4 2.52a3.7 3.7 0 0 1-1.57 2.4l-.17.1-3.36 2.09a4.5 4.5 0 0 1-5.9-1.23 4 4 0 0 1-.66-1.44 4 4 0 0 1-.04-1.58 4 4 0 0 1 .58-1.4 4 4 0 0 1-.4-2.52 3.7 3.7 0 0 1 1.57-2.4zl3.36-2.08zm7.87 0a2.7 2.7 0 0 0-1.26-.95 2.7 2.7 0 0 0-1.6-.07 3 3 0 0 0-.52.2l-.16.09-3.36 2.08a2 2 0 0 0-.69.64 2 2 0 0 0-.36.86 2.3 2.3 0 0 0 .42 1.81A2.7 2.7 0 0 0 7.18 9.4q.28-.06.53-.2l.16-.09 1.28-.79.2-.09a.8.8 0 0 1 .87.31.7.7 0 0 1 .13.55.7.7 0 0 1-.24.4l-.08.05-3.36 2.08-.2.09a1 1 0 0 1-.49-.02 1 1 0 0 1-.38-.3 1 1 0 0 1-.13-.37v-.1l.01-.13-.13-.03a4 4 0 0 1-1.1-.5l-.2-.14-.18-.12-.07.18-.08.3a2.3 2.3 0 0 0 .43 1.82q.45.64 1.19.93.73.28 1.51.14l.16-.04q.27-.07.52-.2l.16-.09 3.36-2.08q.4-.25.69-.64.27-.4.36-.86a2.3 2.3 0 0 0-.42-1.82 2.7 2.7 0 0 0-1.27-.95 2.7 2.7 0 0 0-1.6-.08q-.27.07-.52.2l-.16.1-1.28.79-.2.09a1 1 0 0 1-.49-.03 1 1 0 0 1-.38-.29.7.7 0 0 1-.13-.54.7.7 0 0 1 .24-.4l.08-.06L9.33 4.4l.2-.1a.8.8 0 0 1 .87.32 1 1 0 0 1 .13.38v.22l.11.04q.6.18 1.12.5l.2.14.17.12.06-.19.08-.3a2.3 2.3 0 0 0-.42-1.81z"/>
545
+ </symbol>`,W7=`<symbol id="file-tree-builtin-svg" viewBox="0 0 16 16">
546
+ <path fill="currentColor" d="M5 7a2 2 0 0 1 2-2h6a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2z"/>
547
+ <path fill="currentColor" d="M6 1a5 5 0 0 1 4.58 3H7a3 3 0 0 0-3 3v3.58A5 5 0 0 1 6 1" opacity=".5"/>
548
+ </symbol>`,G7=`<symbol id="file-tree-builtin-svgo" viewBox="0 0 16 16">
549
+ <path fill="currentColor" d="M9.43 4.8A.6.6 0 1 1 9.19 6l-.56.96a1.2 1.2 0 0 1 .32 1.58l.7.53a.89.89 0 1 1-.17.22l-.7-.52a1.2 1.2 0 0 1-1.4.25l-.56.87a.75.75 0 1 1-.57-.2 1 1 0 0 1 .32.05l.56-.87a1.2 1.2 0 0 1-.4-1.24l-1.2-.47a.56.56 0 1 1 .1-.28v.02l1.2.47a1.2 1.2 0 0 1 1.56-.55l.56-.97a.6.6 0 0 1-.15-.64.6.6 0 0 1 .63-.4"/>
550
+ <path fill="currentColor" fill-rule="evenodd" d="M9.17 1q.16.63.27 1.26a6 6 0 0 1 1.61.67q.52-.38 1.08-.71l1.65 1.64q-.32.56-.68 1.05.48.78.72 1.67.6.09 1.18.25v2.32q-.55.15-1.11.24a6 6 0 0 1-.7 1.82q.31.44.59.91l-1.65 1.65-.85-.55a6 6 0 0 1-1.9.83q-.08.47-.2.95H6.84q-.12-.46-.2-.93a6 6 0 0 1-1.96-.81q-.39.27-.8.51l-1.65-1.65q.25-.43.53-.84a6 6 0 0 1-.75-1.9L1 9.16V6.83q.54-.14 1.09-.24a6 6 0 0 1 .77-1.74q-.33-.47-.63-.98l1.65-1.65q.54.32 1.03.68a6 6 0 0 1 1.66-.66q.1-.61.26-1.24zM7.96 3.73a4 4 0 0 0-1.74.36 4.5 4.5 0 0 0-2.3 2.3 4.4 4.4 0 0 0-.1 3.29l.03.06a4.4 4.4 0 0 0 2.4 2.47 4.4 4.4 0 0 0 3.48-.02l.03-.02a4.4 4.4 0 0 0 2.3-2.42l.06-.14a4.4 4.4 0 0 0-.2-3.4 4.4 4.4 0 0 0-2.13-2.07L9.47 4a4 4 0 0 0-1.51-.27" clip-rule="evenodd"/>
551
+ </symbol>`,q7=`<symbol id="file-tree-builtin-swift" viewBox="0 0 16 16">
552
+ <path fill="currentColor" d="M9.63 1c6.15 4.35 4.16 9.15 4.16 9.15s1.75 2.05 1.04 3.85c0 0-.72-1.26-1.93-1.26-1.17 0-1.85 1.26-4.2 1.26C3.47 14 1 9.46 1 9.46c4.71 3.22 7.93.94 7.93.94C6.8 9.12 2.29 3 2.29 3c3.93 3.47 5.63 4.39 5.63 4.39-1.01-.87-3.86-5.13-3.86-5.13C6.34 4.66 10.86 8 10.86 8c1.28-3.7-1.23-7-1.23-7"/>
553
+ </symbol>`,K7=`<symbol id="file-tree-builtin-table" viewBox="0 0 16 16">
554
+ <path fill="currentColor" d="M8 4a3 3 0 0 0 3 3h3v5.5a2.5 2.5 0 0 1-2.5 2.5h-7A2.5 2.5 0 0 1 2 12.5v-9A2.5 2.5 0 0 1 4.5 1H8z" class="bg" opacity=".4"/>
555
+ <path fill="currentColor" d="M11.5 8a.5.5 0 0 1 .5.5v4a.5.5 0 0 1-.5.5h-7a.5.5 0 0 1-.5-.5v-4a.5.5 0 0 1 .5-.5zM5 12h2.5v-1H5zm3.5 0H11v-1H8.5zM5 10h2.5V9H5zm3.5 0H11V9H8.5zm1-9a.5.5 0 0 1 .354.146l4 4A.5.5 0 0 1 14 5.5V6h-3a2 2 0 0 1-2-2V1z" class="fg"/>
556
+ </symbol>`,X7=`<symbol id="file-tree-builtin-tailwind" viewBox="0 0 16 16">
557
+ <path fill="currentColor" fill-rule="evenodd" d="M8 4Q5.2 4 4.5 6.67q1.05-1.34 2.45-1c.53.12.91.5 1.33.9C8.98 7.23 9.77 8 11.5 8q2.8 0 3.5-2.67-1.05 1.34-2.45 1c-.53-.12-.91-.5-1.33-.9C10.52 4.77 9.73 4 8 4M4.5 8Q1.7 8 1 10.67q1.05-1.34 2.45-1c.53.12.91.5 1.33.9C5.48 11.23 6.26 12 8 12q2.8 0 3.5-2.67-1.05 1.34-2.45 1c-.53-.12-.91-.5-1.33-.9C7.02 8.77 6.24 8 4.5 8" clip-rule="evenodd"/>
558
+ </symbol>`,Q7=`<symbol id="file-tree-builtin-terraform" viewBox="0 0 16 16">
559
+ <path fill="currentColor" d="M1 0v5.05l4.35 2.53V2.53zm9.18 5.34L5.83 2.82v5.05l4.35 2.53zm.47 5.06V5.34L15 2.82v5.05zm-.48 5.6-4.35-2.53V8.42l4.35 2.53z"/>
560
+ </symbol>`,Y7=`<symbol id="file-tree-builtin-text" viewBox="0 0 16 16">
561
+ <path fill="currentColor" fill-rule="evenodd" d="M8 4a3 3 0 0 0 3 3h3v5.5a2.5 2.5 0 0 1-2.5 2.5h-7A2.5 2.5 0 0 1 2 12.5v-9A2.5 2.5 0 0 1 4.5 1H8z" class="bg" clip-rule="evenodd" opacity=".4"/>
562
+ <path fill="currentColor" d="M8.5 11a.5.5 0 0 1 0 1h-3a.5.5 0 0 1 0-1zm2-2a.5.5 0 0 1 0 1h-5a.5.5 0 0 1 0-1zm-1-8a.5.5 0 0 1 .354.146l4 4A.5.5 0 0 1 14 5.5V6h-3a2 2 0 0 1-2-2V1z"/>
563
+ </symbol>`,J7=`<symbol id="file-tree-builtin-typescript" viewBox="0 0 16 16">
564
+ <path fill="currentColor" d="M8 1C2.24 1 1 2.24 1 8s1.24 7 7 7 7-1.24 7-7-1.24-7-7-7" class="bg" opacity=".2"/>
565
+ <path fill="currentColor" d="M8.1 9.64h.95c.04.62.28.76 1.28.76s1.2-.14 1.2-.85c0-.66-.2-.85-1.2-1.07-1.79-.38-2.18-.7-2.18-1.86C8.15 5.3 8.54 5 10.31 5c1.67 0 2.04.26 2.07 1.42h-.95c-.02-.43-.23-.53-1.1-.53-1 0-1.22.14-1.22.74 0 .52.22.7 1.24.92 1.76.38 2.15.73 2.15 2 0 1.44-.4 1.75-2.24 1.75-1.8 0-2.18-.3-2.15-1.66m-3 1.57V5.99H3.5v-.9h4.21v.9H6.1v5.22z"/>
566
+ </symbol>`,Z7=`<symbol id="file-tree-builtin-vite" viewBox="0 0 16 16">
567
+ <path fill="currentColor" d="M8.57 14.87c-.18.26-.55.11-.55-.22v-3.18l-.05-.27-.13-.22-.2-.15-.24-.06H4.29c-.26 0-.4-.32-.26-.55L6.08 7c.3-.46 0-1.1-.5-1.1H1.8c-.25 0-.4-.32-.25-.56l2.65-4.2A.3.3 0 0 1 4.46 1h7.9c.26 0 .4.32.26.55l-2.05 3.23c-.29.46 0 1.1.5 1.1h3.12c.26 0 .4.34.24.57z"/>
568
+ </symbol>`,eA=`<symbol id="file-tree-builtin-vscode" viewBox="0 0 16 16">
569
+ <path fill="currentColor" d="m5.11 9.68-2.4 1.84a.6.6 0 0 1-.75-.04l-.77-.7a.6.6 0 0 1 0-.87L3.28 8zm5.52-8.42a.51.51 0 0 1 .87.36V4.8L7.32 8 5.1 6.32z" opacity=".75"/>
570
+ <path fill="currentColor" d="M11.1 14.99h.03zM1.96 4.52a.6.6 0 0 1 .75-.04l8.8 6.71v3.19a.51.51 0 0 1-.88.36L1.19 6.1a.6.6 0 0 1 0-.87z" opacity=".65"/>
571
+ <path fill="currentColor" d="M11.62 14.91a.9.9 0 0 1-1-.17.51.51 0 0 0 .88-.36V1.62a.51.51 0 0 0-.87-.36.9.9 0 0 1 1-.17l2.87 1.39a.9.9 0 0 1 .5.8v9.44a.9.9 0 0 1-.5.8z"/>
572
+ </symbol>`,tA=`<symbol id="file-tree-builtin-vue" viewBox="0 0 16 16">
573
+ <path fill="currentColor" d="M9.62 2.25 8 5.02 6.38 2.25H1l7 12 7-12z" opacity=".5"/>
574
+ <path fill="currentColor" d="M9.54 2.25 8 4.95l-1.54-2.7H4l4 7 4-7z"/>
575
+ </symbol>`,nA=`<symbol id="file-tree-builtin-wasm" viewBox="0 0 16 16">
576
+ <path fill="currentColor" d="M13 1a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H3a2 2 0 0 1-2-2V3a2 2 0 0 1 2-2h3a2 2 0 1 0 4 0z" class="subtract" opacity=".2"/>
577
+ <path fill="currentColor" d="M4.64 11.4h.02l.8-3.4h.91l.73 3.45L7.88 8h.96l-1.25 5h-.97L5.9 9.6 5.1 13h-1L3 8h.98z"/>
578
+ <path fill="currentColor" fill-rule="evenodd" d="M13 13h-1.02l-.33-1.11H9.9L9.64 13h-.97l1.26-5h1.54zm-2.49-3.77-.42 1.84h1.32l-.49-1.84z" clip-rule="evenodd"/>
579
+ </symbol>`,rA=`<symbol id="file-tree-builtin-webpack" viewBox="0 0 16 16">
580
+ <path fill="currentColor" d="M14.1 11.79 8.26 15v-2.5l3.64-1.94zm.4-.35V4.73l-2.14 1.2v4.3zm-12.6.35L7.74 15v-2.5L4.1 10.56zm-.4-.35V4.73l2.14 1.2v4.3zm.25-7.15 6-3.29v2.42L3.9 5.47l-.03.01zm12.5 0L8.25 1v2.42l3.85 2.05.03.01z" class="bg" opacity=".4"/>
581
+ <path fill="currentColor" d="m7.74 11.93-3.59-1.92v-3.8l3.6 2.02zm.52 0 3.59-1.92v-3.8l-3.6 2.02zM4.4 5.77 8 3.85l3.6 1.93L8 7.8z" class="fg"/>
582
+ </symbol>`,iA=`<symbol id="file-tree-builtin-yml" viewBox="0 0 16 16">
583
+ <path fill="currentColor" d="M7.5 2A1.5 1.5 0 0 1 9 3.5v3A1.5 1.5 0 0 1 7.5 8h-2v2A1.5 1.5 0 0 0 7 11.5v-1A1.5 1.5 0 0 1 8.5 9h5a1.5 1.5 0 0 1 1.5 1.5v3a1.5 1.5 0 0 1-1.5 1.5h-5A1.5 1.5 0 0 1 7 13.5v-1A2.5 2.5 0 0 1 4.5 10V8h-2A1.5 1.5 0 0 1 1 6.5v-3A1.5 1.5 0 0 1 2.5 2zm1 8a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h5a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5zm-6-7a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h5a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5z"/>
584
+ </symbol>`,oA=`<symbol id="file-tree-builtin-zig" viewBox="0 0 16 16">
585
+ <path fill="currentColor" d="m14.73 1.5-7.29 8.82h4.17l-1.73 2.04H5.76L1.27 14.5l7.3-8.91H4.39l1.73-2.05h4.12z"/>
586
+ <path fill="currentColor" d="M5.21 3.54 3.56 5.6h-.55v4.73h.83L2.1 12.36H1V3.54zm9.79 0v8.82h-4.3l1.74-2.04h.55V5.68h-.83l1.74-2.14z"/>
587
+ </symbol>`,sA=[f7,y7,w7,b7,k7,S7,C7,I7,P7,L7,D7,A7,T7,$7,j7,V7,q7,K7,Y7,J7,`<symbol id="file-tree-builtin-zip" viewBox="0 0 16 16">
588
+ <path fill="currentColor" d="M4.585 2a2 2 0 0 1 1.028.285l1.788 1.072a1 1 0 0 0 .514.143H12A2 2 0 0 1 13.935 5H0V4a2 2 0 0 1 2-2z" class="bg" opacity=".5"/>
589
+ <path fill="currentColor" fill-rule="evenodd" d="M14 12a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2v-1.25h1v-1H0V6h14zM9.9 8.25c-.883 0-1.9.5-1.9.5H7v1h1v1s1.017.5 1.9.5c.884 0 1.6-.672 1.6-1.5s-.716-1.5-1.6-1.5M2 9.75v1h1v-1zm2 0v1h1v-1zm2 0v1h1v-1zm-5-1v1h1v-1zm2 0v1h1v-1zm2 0v1h1v-1z" class="fg" clip-rule="evenodd"/>
590
+ </symbol>`],aA=[u7,d7,h7,p7,m7,g7,v7,x7,_7,E7,R7,N7,F7,M7,O7,B7,U7,z7,H7,W7,G7,X7,Q7,Z7,eA,tA,nA,rA,iA,oA];function j_(e,t){return t.length===0?e:e.replace("</svg>",`
591
+ ${t.join(`
592
+ `)}
593
+ </svg>`)}const pw=j_(B_,sA),lA={minimal:B_,standard:pw,complete:j_(pw,aA)},cA={".babelrc":"babel",".babelrc.json":"babel",".bash_profile":"bash",".bashrc":"bash",".browserslistrc":"browserslist",".dockerignore":"docker",".eslintignore":"eslint",".eslintrc":"eslint",".eslintrc.cjs":"eslint",".eslintrc.js":"eslint",".eslintrc.json":"eslint",".eslintrc.yaml":"eslint",".eslintrc.yml":"eslint",".gitattributes":"git",".gitignore":"git",".gitkeep":"git",".gitmodules":"git",".oxlintrc.json":"oxc",".postcssrc":"postcss",".postcssrc.json":"postcss",".postcssrc.yaml":"postcss",".postcssrc.yml":"postcss",".prettierignore":"prettier",".prettierrc":"prettier",".prettierrc.cjs":"prettier",".prettierrc.js":"prettier",".prettierrc.json":"prettier",".prettierrc.mjs":"prettier",".prettierrc.toml":"prettier",".prettierrc.yaml":"prettier",".prettierrc.yml":"prettier",".stylelintignore":"stylelint",".stylelintrc":"stylelint",".stylelintrc.cjs":"stylelint",".stylelintrc.js":"stylelint",".stylelintrc.json":"stylelint",".stylelintrc.mjs":"stylelint",".stylelintrc.yaml":"stylelint",".stylelintrc.yml":"stylelint",".terraform.lock.hcl":"terraform",".zprofile":"bash",".zshenv":"bash",".zshrc":"bash","babel.config.cjs":"babel","babel.config.js":"babel","babel.config.json":"babel","babel.config.mjs":"babel","biome.json":"biome","biome.jsonc":"biome","bootstrap.bundle.js":"bootstrap","bootstrap.bundle.min.js":"bootstrap","bootstrap.css":"bootstrap","bootstrap.js":"bootstrap","bootstrap.min.css":"bootstrap","bootstrap.min.js":"bootstrap","bun.lock":"bun","bun.lockb":"bun","bunfig.toml":"bun","claude.md":"claude","compose.yaml":"docker","compose.yml":"docker","docker-compose.override.yml":"docker","docker-compose.yaml":"docker","docker-compose.yml":"docker",dockerfile:"docker","eslint.config.cjs":"eslint","eslint.config.js":"eslint","eslint.config.mjs":"eslint","eslint.config.mts":"eslint","eslint.config.ts":"eslint",gemfile:"ruby","next.config.js":"nextjs","next.config.mjs":"nextjs","next.config.mts":"nextjs","next.config.ts":"nextjs","postcss.config.cjs":"postcss","postcss.config.js":"postcss","postcss.config.mjs":"postcss","postcss.config.ts":"postcss","prettier.config.cjs":"prettier","prettier.config.js":"prettier","prettier.config.mjs":"prettier",rakefile:"ruby","readme.md":"markdown","stylelint.config.cjs":"stylelint","stylelint.config.js":"stylelint","stylelint.config.mjs":"stylelint","svgo.config.cjs":"svgo","svgo.config.js":"svgo","svgo.config.mjs":"svgo","svgo.config.ts":"svgo","tailwind.config.cjs":"tailwind","tailwind.config.js":"tailwind","tailwind.config.mjs":"tailwind","tailwind.config.ts":"tailwind","vite.config.js":"vite","vite.config.mjs":"vite","vite.config.mts":"vite","vite.config.ts":"vite","webpack.config.babel.js":"webpack","webpack.config.cjs":"webpack","webpack.config.js":"webpack","webpack.config.mjs":"webpack","webpack.config.ts":"webpack"},uA={"7z":"zip",astro:"astro",AUTHORS:"text",avif:"image",bash:"bash",bmp:"image",bz2:"zip",cfg:"text",CHANGELOG:"text",cjs:"javascript","code-workspace":"vscode",conf:"text",CONTRIBUTORS:"text",csh:"bash",css:"css",csv:"table",cts:"typescript",db:"database",editorconfig:"text",env:"text","env.development":"text","env.local":"text","env.production":"text",eot:"font",erb:"ruby",fish:"bash",gemspec:"ruby",gif:"image",go:"go",gql:"graphql",graphql:"graphql",gz:"zip",htm:"html",html:"html",icns:"image",ico:"image",ini:"text",jar:"zip",jpeg:"image",jpg:"image",js:"javascript",json:"json",json5:"json",jsonc:"json",jsonl:"json",jsx:"javascript",ksh:"bash",less:"css",LICENSE:"text",log:"text",markdown:"markdown",mcp:"mcp",md:"markdown",mdx:"markdown","mdx.tsx":"markdown",mjs:"javascript",mts:"typescript",ods:"table",otf:"font",png:"image",postcss:"css",py:"python",pyi:"python",pyw:"python",pyx:"python",rake:"ruby",rar:"zip",rb:"ruby",rs:"rust",rst:"text",rtf:"text",sass:"css",scss:"css",sh:"bash",sql:"database",sqlite:"database",sqlite3:"database",styl:"css",svelte:"svelte",svg:"svg",swift:"swift",tar:"zip",tf:"terraform",tfstate:"terraform",tfvars:"terraform",tgz:"zip",tif:"image",tiff:"image",ts:"typescript",tsv:"table",tsx:"typescript",ttf:"font",txt:"text",vue:"vue",war:"zip",wasm:"wasm",wast:"wasm",wat:"wasm",webp:"image",woff:"font",woff2:"font",xhtml:"html",xls:"table",xlsx:"table",xz:"zip",yaml:"yml",yml:"yml",zig:"zig",zip:"zip",zsh:"bash"},dA={jsx:"react",sass:"sass",scss:"sass",tsx:"react"},mw=new Set(["bash","css","database","default","font","git","go","html","image","javascript","json","markdown","mcp","python","ruby","rust","swift","table","text","typescript","zip"]),fA=new Set(["complete"]);function hA(e){return lA[e==="none"?"minimal":e]}function pA(e){return`file-tree-builtin-${e}`}function mA(e){return e!=="none"&&fA.has(e)}function gA(e,t,n){if(e==="minimal"||e==="none")return;const r=e==="complete",i=cA[t.toLowerCase()];if(i!=null&&(r||mw.has(i)))return i;for(const s of n){if(r){const c=dA[s];if(c!=null)return c}const l=uA[s];if(l!=null&&(r||mw.has(l)))return l}return"default"}function vA(e){return e.spriteSheet!=null||e.remap!=null||e.byFileName!=null||e.byFileExtension!=null||e.byFileNameContains!=null}function vf(e){return e==null?{set:"complete",colored:!0}:typeof e=="string"?{set:e,colored:!0}:{...e,set:e.set??(vA(e)?"none":"complete"),colored:e.colored??!0}}const Cg={compact:{itemHeight:24,factor:.8},default:{itemHeight:30,factor:1},relaxed:{itemHeight:36,factor:1.2}};function yA(e,t){if(typeof e=="number")return{itemHeight:t??Cg.default.itemHeight,factor:e};const n=Cg[e??"default"];return{itemHeight:t??n.itemHeight,factor:n.factor}}const V_=Cg.default.itemHeight,wA=10,U_=420;var gw=`@layer base, theme, unsafe;
594
+
595
+ @layer base {
596
+ :host {
597
+ /*
598
+ CSS variables use a fallback stack to ensure user and theme colors slot
599
+ in with ease. User colors take precedence over theme colors, which take
600
+ precedence over defaults.
601
+
602
+ Fallback order:
603
+
604
+ 1. --trees-*-override (explicit)
605
+ 2. --trees-theme-* (e.g. Shiki/VS Code tokens)
606
+ 3. defaults
607
+
608
+ Theme variable names mirror Shiki/VS Code theme file JSON tokens.
609
+
610
+ // Available CSS Color Overrides
611
+ --trees-fg-override
612
+ --trees-fg-muted-override
613
+ --trees-bg-override
614
+ --trees-bg-muted-override
615
+ --trees-accent-override
616
+ --trees-border-color-override
617
+
618
+ --trees-focus-ring-color-override
619
+ --trees-focus-ring-width-override
620
+ --trees-focus-ring-offset-override
621
+
622
+ --trees-search-fg-override
623
+ --trees-search-font-weight-override
624
+ --trees-search-bg-override
625
+
626
+ --trees-selected-fg-override
627
+ --trees-selected-bg-override
628
+ --trees-selected-focused-border-color-override
629
+
630
+ // Git Status Color Overrides
631
+ --trees-status-added-override
632
+ --trees-status-ignored-override
633
+ --trees-status-modified-override
634
+ --trees-status-renamed-override
635
+ --trees-status-untracked-override
636
+ --trees-status-deleted-override
637
+ --trees-git-added-color-override
638
+ --trees-git-ignored-color-override
639
+ --trees-git-modified-color-override
640
+ --trees-git-renamed-color-override
641
+ --trees-git-untracked-color-override
642
+ --trees-git-deleted-color-override
643
+
644
+ // Built-in File Icon Color Overrides
645
+ --trees-file-icon-color
646
+ --trees-file-icon-color-astro
647
+ --trees-file-icon-color-babel
648
+ --trees-file-icon-color-bash
649
+ --trees-file-icon-color-biome
650
+ --trees-file-icon-color-bootstrap
651
+ --trees-file-icon-color-browserslist
652
+ --trees-file-icon-color-bun
653
+ --trees-file-icon-color-claude
654
+ --trees-file-icon-color-css
655
+ --trees-file-icon-color-database
656
+ --trees-file-icon-color-default
657
+ --trees-file-icon-color-docker
658
+ --trees-file-icon-color-eslint
659
+ --trees-file-icon-color-git
660
+ --trees-file-icon-color-go
661
+ --trees-file-icon-color-graphql
662
+ --trees-file-icon-color-html
663
+ --trees-file-icon-color-image
664
+ --trees-file-icon-color-javascript
665
+ --trees-file-icon-color-json
666
+ --trees-file-icon-color-markdown
667
+ --trees-file-icon-color-mcp
668
+ --trees-file-icon-color-npm
669
+ --trees-file-icon-color-oxc
670
+ --trees-file-icon-color-postcss
671
+ --trees-file-icon-color-prettier
672
+ --trees-file-icon-color-python
673
+ --trees-file-icon-color-react
674
+ --trees-file-icon-color-ruby
675
+ --trees-file-icon-color-rust
676
+ --trees-file-icon-color-sass
677
+ --trees-file-icon-color-svg
678
+ --trees-file-icon-color-svelte
679
+ --trees-file-icon-color-svgo
680
+ --trees-file-icon-color-swift
681
+ --trees-file-icon-color-table
682
+ --trees-file-icon-color-text
683
+ --trees-file-icon-color-tailwind
684
+ --trees-file-icon-color-terraform
685
+ --trees-file-icon-color-typescript
686
+ --trees-file-icon-color-vite
687
+ --trees-file-icon-color-vscode
688
+ --trees-file-icon-color-vue
689
+ --trees-file-icon-color-wasm
690
+ --trees-file-icon-color-webpack
691
+ --trees-file-icon-color-yml
692
+ --trees-file-icon-color-zig
693
+ --trees-file-icon-color-zip
694
+
695
+ // Density
696
+ //
697
+ // A unitless scale factor for padding, gaps, and indentation. Usually
698
+ // set via \`density\` on useFileTree. Individual overrides take precedence.
699
+ //
700
+ // Compact: 0.8
701
+ // Default: 1
702
+ // Relaxed: 1.2
703
+ //
704
+ --trees-density-override
705
+
706
+ // Available CSS Layout Overrides
707
+ --trees-gap-override
708
+ --trees-border-radius-override
709
+ --trees-font-family-override
710
+ --trees-font-size-override
711
+ --trees-font-weight-regular-override
712
+ --trees-font-weight-semibold-override
713
+ --trees-level-gap-override
714
+ --trees-item-padding-x-override
715
+ --trees-item-margin-x-override
716
+ --trees-item-row-gap-override
717
+ --trees-icon-width-override
718
+ --trees-icon-nudge-override
719
+ --trees-scrollbar-gutter-override
720
+ --trees-padding-inline-override
721
+ */
722
+
723
+ --trees-accent: var(--trees-accent-override, #009fff);
724
+ --trees-fg: var(
725
+ --trees-fg-override,
726
+ var(--trees-theme-sidebar-fg, light-dark(#6c6c71, #adadb1))
727
+ );
728
+ --trees-fg-muted: var(
729
+ --trees-fg-muted-override,
730
+ var(--trees-theme-sidebar-header-fg, light-dark(#84848a, #84848a))
731
+ );
732
+ --trees-bg: var(
733
+ --trees-bg-override,
734
+ var(--trees-theme-sidebar-bg, light-dark(#f8f8f8, #141415))
735
+ );
736
+ /* var(--trees-theme-list-hover-bg, light-dark(#dfebff59, #19283c59)) */
737
+ --trees-bg-muted: var(
738
+ --trees-bg-muted-override,
739
+ var(
740
+ --trees-theme-list-hover-bg,
741
+ light-dark(
742
+ color-mix(
743
+ in lab,
744
+ var(--trees-accent) var(--trees-bg-alpha-light, 8%),
745
+ var(--trees-bg)
746
+ ),
747
+ color-mix(
748
+ in lab,
749
+ var(--trees-accent) var(--trees-bg-alpha-dark, 10%),
750
+ var(--trees-bg)
751
+ )
752
+ )
753
+ )
754
+ );
755
+ --trees-input-bg: var(
756
+ --trees-input-bg-override,
757
+ light-dark(#f8f8f8, #070707)
758
+ );
759
+
760
+ --trees-added-light: #16a994;
761
+ --trees-added-dark: #00cab1;
762
+ --trees-ignored-light: #adadb1;
763
+ --trees-ignored-dark: #4a4a4e;
764
+ --trees-modified-light: #1ca1c7;
765
+ --trees-modified-dark: #08c0ef;
766
+ --trees-renamed-light: #d5a910;
767
+ --trees-renamed-dark: #ffd452;
768
+ --trees-untracked-light: #16a994;
769
+ --trees-untracked-dark: #00cab1;
770
+ --trees-deleted-light: #ff2e3f;
771
+ --trees-deleted-dark: #ff6762;
772
+
773
+ --trees-border-color: var(
774
+ --trees-border-color-override,
775
+ var(--trees-theme-sidebar-border, light-dark(#eeeeef, #070707))
776
+ );
777
+ --trees-indent-guide-bg: var(
778
+ --trees-indent-guide-bg-override,
779
+ color-mix(in lab, var(--trees-fg-muted) 25%, transparent)
780
+ );
781
+ --trees-density: var(--trees-density-override, 1);
782
+ --trees-border-radius: var(
783
+ --trees-border-radius-override,
784
+ calc(6px * var(--trees-density))
785
+ );
786
+
787
+ --trees-font-family: var(--trees-font-family-override, system-ui);
788
+ --trees-font-size: var(--trees-font-size-override, 13px);
789
+ --trees-font-weight-regular: var(--trees-font-weight-regular-override, 400);
790
+ --trees-font-weight-semibold: var(
791
+ --trees-font-weight-semibold-override,
792
+ 600
793
+ );
794
+
795
+ --trees-focus-ring-color: var(
796
+ --trees-focus-ring-color-override,
797
+ var(--trees-theme-focus-ring, var(--trees-accent))
798
+ );
799
+ --trees-focus-ring-width: var(--trees-focus-ring-width-override, 1px);
800
+ --trees-focus-ring-offset: var(--trees-focus-ring-offset-override, -1px);
801
+
802
+ --trees-search-fg: var(
803
+ --trees-search-fg-override,
804
+ var(--trees-theme-input-fg, var(--trees-fg))
805
+ );
806
+ --trees-search-font-weight: var(--trees-search-font-weight-override, 600);
807
+ --trees-search-bg: var(
808
+ --trees-search-bg-override,
809
+ var(--trees-theme-input-bg, var(--trees-input-bg))
810
+ );
811
+
812
+ --trees-scrollbar-thumb: var(
813
+ --trees-scrollbar-thumb-override,
814
+ var(
815
+ --trees-theme-scrollbar-thumb,
816
+ color-mix(in lab, var(--trees-fg) 25%, var(--trees-bg))
817
+ )
818
+ );
819
+
820
+ --trees-selected-fg: var(
821
+ --trees-selected-fg-override,
822
+ var(--trees-theme-list-active-selection-fg, var(--trees-fg))
823
+ );
824
+ --trees-selected-bg: var(
825
+ --trees-selected-bg-override,
826
+ var(
827
+ --trees-theme-list-active-selection-bg,
828
+ light-dark(
829
+ color-mix(in lab, var(--trees-accent) 12%, var(--trees-bg)),
830
+ color-mix(in lab, var(--trees-accent) 15%, var(--trees-bg))
831
+ )
832
+ )
833
+ );
834
+ --trees-selected-focused-border-color: var(
835
+ --trees-selected-focused-border-color-override,
836
+ var(--trees-theme-focus-ring, var(--trees-accent))
837
+ );
838
+
839
+ /* Git status (e.g. from Shiki theme gitDecoration.*) */
840
+ --trees-status-added: var(
841
+ --trees-status-added-override,
842
+ var(
843
+ --trees-theme-git-added-fg,
844
+ light-dark(var(--trees-added-light), var(--trees-added-dark))
845
+ )
846
+ );
847
+ --trees-status-ignored: var(
848
+ --trees-status-ignored-override,
849
+ var(
850
+ --trees-theme-git-ignored-fg,
851
+ light-dark(var(--trees-ignored-light), var(--trees-ignored-dark))
852
+ )
853
+ );
854
+ --trees-status-modified: var(
855
+ --trees-status-modified-override,
856
+ var(
857
+ --trees-theme-git-modified-fg,
858
+ light-dark(var(--trees-modified-light), var(--trees-modified-dark))
859
+ )
860
+ );
861
+ --trees-status-renamed: var(
862
+ --trees-status-renamed-override,
863
+ var(
864
+ --trees-theme-git-renamed-fg,
865
+ light-dark(var(--trees-renamed-light), var(--trees-renamed-dark))
866
+ )
867
+ );
868
+ --trees-status-untracked: var(
869
+ --trees-status-untracked-override,
870
+ var(
871
+ --trees-theme-git-untracked-fg,
872
+ light-dark(var(--trees-untracked-light), var(--trees-untracked-dark))
873
+ )
874
+ );
875
+ --trees-status-deleted: var(
876
+ --trees-status-deleted-override,
877
+ var(
878
+ --trees-theme-git-deleted-fg,
879
+ light-dark(var(--trees-deleted-light), var(--trees-deleted-dark))
880
+ )
881
+ );
882
+ --trees-git-modified-color: var(
883
+ --trees-git-modified-color-override,
884
+ var(--trees-status-modified)
885
+ );
886
+ --trees-git-added-color: var(
887
+ --trees-git-added-color-override,
888
+ var(--trees-status-added)
889
+ );
890
+ --trees-git-ignored-color: var(
891
+ --trees-git-ignored-color-override,
892
+ var(--trees-status-ignored)
893
+ );
894
+ --trees-git-deleted-color: var(
895
+ --trees-git-deleted-color-override,
896
+ var(--trees-status-deleted)
897
+ );
898
+ --trees-git-renamed-color: var(
899
+ --trees-git-renamed-color-override,
900
+ var(--trees-status-renamed)
901
+ );
902
+ --trees-git-untracked-color: var(
903
+ --trees-git-untracked-color-override,
904
+ var(--trees-status-untracked)
905
+ );
906
+
907
+ --trees-icon-gray: light-dark(#84848a, #adadb1);
908
+ --trees-icon-red: light-dark(#d52c36, #ff6762);
909
+ --trees-icon-vermilion: light-dark(#ff8c5b, #d5512f);
910
+ --trees-icon-orange: light-dark(#d47628, #ffa359);
911
+ --trees-icon-yellow: light-dark(#d5a910, #ffd452);
912
+ --trees-icon-green: light-dark(#199f43, #5ecc71);
913
+ --trees-icon-teal: light-dark(#17a5af, #64d1db);
914
+ --trees-icon-cyan: light-dark(#1ca1c7, #68cdf2);
915
+ --trees-icon-blue: light-dark(#1a85d4, #69b1ff);
916
+ --trees-icon-indigo: light-dark(#693acf, #9d6afb);
917
+ --trees-icon-purple: light-dark(#a631be, #d568ea);
918
+ --trees-icon-pink: light-dark(#d32a61, #ff678d);
919
+ --trees-icon-mauve: light-dark(#594c5b, #79697b);
920
+
921
+ --trees-file-icon-color-default: var(
922
+ --trees-file-icon-color,
923
+ var(--trees-icon-gray)
924
+ );
925
+ --trees-file-icon-color-astro: var(
926
+ --trees-file-icon-color,
927
+ var(--trees-icon-purple)
928
+ );
929
+ --trees-file-icon-color-babel: var(
930
+ --trees-file-icon-color,
931
+ var(--trees-icon-yellow)
932
+ );
933
+ --trees-file-icon-color-bash: var(
934
+ --trees-file-icon-color,
935
+ var(--trees-icon-green)
936
+ );
937
+ --trees-file-icon-color-biome: var(
938
+ --trees-file-icon-color,
939
+ var(--trees-icon-blue)
940
+ );
941
+ --trees-file-icon-color-bootstrap: var(
942
+ --trees-file-icon-color,
943
+ var(--trees-icon-indigo)
944
+ );
945
+ --trees-file-icon-color-browserslist: var(
946
+ --trees-file-icon-color,
947
+ var(--trees-icon-yellow)
948
+ );
949
+ --trees-file-icon-color-bun: var(
950
+ --trees-file-icon-color,
951
+ var(--trees-icon-mauve)
952
+ );
953
+ --trees-file-icon-color-claude: var(
954
+ --trees-file-icon-color,
955
+ var(--trees-icon-orange)
956
+ );
957
+ --trees-file-icon-color-css: var(
958
+ --trees-file-icon-color,
959
+ var(--trees-icon-indigo)
960
+ );
961
+ --trees-file-icon-color-database: var(
962
+ --trees-file-icon-color,
963
+ var(--trees-icon-purple)
964
+ );
965
+ --trees-file-icon-color-docker: var(
966
+ --trees-file-icon-color,
967
+ var(--trees-icon-blue)
968
+ );
969
+ --trees-file-icon-color-eslint: var(
970
+ --trees-file-icon-color,
971
+ var(--trees-icon-indigo)
972
+ );
973
+ --trees-file-icon-color-git: var(
974
+ --trees-file-icon-vermilion,
975
+ var(--trees-icon-vermilion)
976
+ );
977
+ --trees-file-icon-color-go: var(
978
+ --trees-file-icon-color,
979
+ var(--trees-icon-cyan)
980
+ );
981
+ --trees-file-icon-color-graphql: var(
982
+ --trees-file-icon-color,
983
+ var(--trees-icon-pink)
984
+ );
985
+ --trees-file-icon-color-html: var(
986
+ --trees-file-icon-color,
987
+ var(--trees-icon-orange)
988
+ );
989
+ --trees-file-icon-color-image: var(
990
+ --trees-file-icon-color,
991
+ var(--trees-icon-pink)
992
+ );
993
+ --trees-file-icon-color-javascript: var(
994
+ --trees-file-icon-color,
995
+ var(--trees-icon-yellow)
996
+ );
997
+ --trees-file-icon-color-json: var(
998
+ --trees-file-icon-color,
999
+ var(--trees-icon-orange)
1000
+ );
1001
+ --trees-file-icon-color-markdown: var(
1002
+ --trees-file-icon-color,
1003
+ var(--trees-icon-green)
1004
+ );
1005
+ --trees-file-icon-color-mcp: var(
1006
+ --trees-file-icon-color,
1007
+ var(--trees-icon-teal)
1008
+ );
1009
+ --trees-file-icon-color-npm: var(
1010
+ --trees-file-icon-color,
1011
+ var(--trees-icon-red)
1012
+ );
1013
+ --trees-file-icon-color-oxc: var(
1014
+ --trees-file-icon-cyan,
1015
+ var(--trees-icon-cyan)
1016
+ );
1017
+ --trees-file-icon-color-postcss: var(
1018
+ --trees-file-icon-color,
1019
+ var(--trees-icon-red)
1020
+ );
1021
+ --trees-file-icon-color-prettier: var(
1022
+ --trees-file-icon-color,
1023
+ var(--trees-icon-teal)
1024
+ );
1025
+ --trees-file-icon-color-python: var(
1026
+ --trees-file-icon-color,
1027
+ var(--trees-icon-blue)
1028
+ );
1029
+ --trees-file-icon-color-react: var(
1030
+ --trees-file-icon-color,
1031
+ var(--trees-icon-cyan)
1032
+ );
1033
+ --trees-file-icon-color-ruby: var(
1034
+ --trees-file-icon-color,
1035
+ var(--trees-icon-red)
1036
+ );
1037
+ --trees-file-icon-color-rust: var(
1038
+ --trees-file-icon-color,
1039
+ var(--trees-icon-orange)
1040
+ );
1041
+ --trees-file-icon-color-sass: var(
1042
+ --trees-file-icon-color,
1043
+ var(--trees-icon-pink)
1044
+ );
1045
+ --trees-file-icon-color-svg: var(
1046
+ --trees-file-icon-color,
1047
+ var(--trees-icon-orange)
1048
+ );
1049
+ --trees-file-icon-color-svelte: var(
1050
+ --trees-file-icon-color,
1051
+ var(--trees-icon-red)
1052
+ );
1053
+ --trees-file-icon-color-svgo: var(
1054
+ --trees-file-icon-color,
1055
+ var(--trees-icon-green)
1056
+ );
1057
+ --trees-file-icon-color-swift: var(
1058
+ --trees-file-icon-color,
1059
+ var(--trees-icon-orange)
1060
+ );
1061
+ --trees-file-icon-color-table: var(
1062
+ --trees-file-icon-color,
1063
+ var(--trees-icon-teal)
1064
+ );
1065
+ --trees-file-icon-color-text: var(
1066
+ --trees-file-icon-color,
1067
+ var(--trees-icon-gray)
1068
+ );
1069
+ --trees-file-icon-color-tailwind: var(
1070
+ --trees-file-icon-color,
1071
+ var(--trees-icon-cyan)
1072
+ );
1073
+ --trees-file-icon-color-terraform: var(
1074
+ --trees-file-icon-color,
1075
+ var(--trees-icon-indigo)
1076
+ );
1077
+ --trees-file-icon-color-typescript: var(
1078
+ --trees-file-icon-color,
1079
+ var(--trees-icon-blue)
1080
+ );
1081
+ --trees-file-icon-color-vite: var(
1082
+ --trees-file-icon-color,
1083
+ var(--trees-icon-purple)
1084
+ );
1085
+ --trees-file-icon-color-vscode: var(
1086
+ --trees-file-icon-color,
1087
+ var(--trees-icon-blue)
1088
+ );
1089
+ --trees-file-icon-color-vue: var(
1090
+ --trees-file-icon-color,
1091
+ var(--trees-icon-green)
1092
+ );
1093
+ --trees-file-icon-color-wasm: var(
1094
+ --trees-file-icon-color,
1095
+ var(--trees-icon-indigo)
1096
+ );
1097
+ --trees-file-icon-color-webpack: var(
1098
+ --trees-file-icon-color,
1099
+ var(--trees-icon-blue)
1100
+ );
1101
+ --trees-file-icon-color-yml: var(
1102
+ --trees-file-icon-color,
1103
+ var(--trees-icon-red)
1104
+ );
1105
+ --trees-file-icon-color-zig: var(
1106
+ --trees-file-icon-color,
1107
+ var(--trees-icon-orange)
1108
+ );
1109
+ --trees-file-icon-color-zip: var(
1110
+ --trees-file-icon-color,
1111
+ var(--trees-icon-orange)
1112
+ );
1113
+
1114
+ --trees-level-gap: var(
1115
+ --trees-level-gap-override,
1116
+ calc(8px * var(--trees-density))
1117
+ );
1118
+ --trees-item-padding-x: var(
1119
+ --trees-item-padding-x-override,
1120
+ calc(8px * var(--trees-density))
1121
+ );
1122
+ --trees-item-margin-x: var(
1123
+ --trees-item-margin-x-override,
1124
+ calc(2px * var(--trees-density))
1125
+ );
1126
+ --trees-item-row-gap: var(
1127
+ --trees-item-row-gap-override,
1128
+ calc(6px * var(--trees-density))
1129
+ );
1130
+ --trees-icon-width: var(--trees-icon-width-override, 16px);
1131
+ --trees-icon-nudge: var(
1132
+ --trees-icon-nudge-override,
1133
+ calc(1px * var(--trees-density))
1134
+ );
1135
+ --trees-row-height: var(--trees-item-height, 30px);
1136
+ --trees-git-lane-width: var(--trees-git-lane-width-override, 12px);
1137
+ --trees-action-lane-width: var(
1138
+ --trees-action-lane-width-override,
1139
+ calc(var(--trees-icon-width) + 2px)
1140
+ );
1141
+ /* Keep the floating trigger aligned with the row's action lane. Going in
1142
+ from the root's right edge: the scroll container reserves
1143
+ \`--trees-padding-inline\` of effective inset on each side (its asymmetric
1144
+ padding formula cancels the scrollbar gutter on the right), the row
1145
+ sits inside that inset, and its trailing \`--trees-item-padding-x\` is the
1146
+ action lane itself. The trigger's own focus-ring margin then trims one
1147
+ pixel back so the button's visible right edge lines up with the lane. */
1148
+ --trees-context-menu-trigger-inline-offset: calc(
1149
+ var(--trees-padding-inline) + var(--trees-item-padding-x) -
1150
+ var(--trees-focus-ring-width)
1151
+ );
1152
+
1153
+ --trees-scrollbar-gutter: var(--trees-scrollbar-gutter-override, 6px);
1154
+ --trees-padding-inline: var(--trees-padding-inline-override, 16px);
1155
+
1156
+ color-scheme: light dark;
1157
+ display: flex;
1158
+ flex-direction: column;
1159
+ font-size: var(--trees-font-size);
1160
+ color: var(--trees-fg);
1161
+ background-color: var(--trees-bg);
1162
+ --truncate-marker-background-color: var(--trees-bg);
1163
+ --truncate-marker-background-overlay-color: transparent;
1164
+ font-family: var(--trees-font-family);
1165
+ font-weight: var(--trees-font-weight-regular);
1166
+ }
1167
+
1168
+ :host([data-file-tree-virtualized='true']) {
1169
+ height: 100%;
1170
+ overflow: hidden;
1171
+ }
1172
+
1173
+ [data-file-tree-virtualized-wrapper='true'] {
1174
+ height: 100%;
1175
+ overflow: hidden;
1176
+ display: flex;
1177
+ flex-direction: column;
1178
+ }
1179
+
1180
+ [data-file-tree-virtualized-root='true'] {
1181
+ height: 100%;
1182
+ display: flex;
1183
+ flex-direction: column;
1184
+ overflow: hidden;
1185
+ }
1186
+
1187
+ [data-file-tree-virtualized-scroll='true'],
1188
+ [data-file-tree-scrollbar-measure='true'] {
1189
+ overflow-y: auto;
1190
+ scrollbar-gutter: stable;
1191
+
1192
+ &::-webkit-scrollbar {
1193
+ width: var(--trees-scrollbar-gutter);
1194
+ height: var(--trees-scrollbar-gutter);
1195
+ }
1196
+
1197
+ &::-webkit-scrollbar-track {
1198
+ background: transparent;
1199
+ }
1200
+
1201
+ &::-webkit-scrollbar-thumb {
1202
+ background-color: var(--trees-scrollbar-thumb);
1203
+ border: 1px solid transparent;
1204
+ background-clip: content-box;
1205
+ border-radius: calc(var(--trees-scrollbar-gutter) / 2);
1206
+ }
1207
+
1208
+ &::-webkit-scrollbar-corner {
1209
+ background-color: transparent;
1210
+ }
1211
+ }
1212
+
1213
+ /* These are styles for a temporarily generated element to measure the size
1214
+ * of the scrollbar. It's intended to be somewhat similar in scrollbar style
1215
+ * scope to the scrollable tree so \`--trees-scrollbar-gutter-measured\` is an
1216
+ * accurate reflection of the size the scrollbar gutter takes up. */
1217
+ [data-file-tree-scrollbar-measure='true'] {
1218
+ position: absolute;
1219
+ top: 0;
1220
+ left: 0;
1221
+ visibility: hidden;
1222
+ pointer-events: none;
1223
+ width: 100px;
1224
+ height: 100px;
1225
+ }
1226
+
1227
+ @supports (-moz-appearance: none) {
1228
+ [data-file-tree-virtualized-scroll='true'],
1229
+ [data-file-tree-scrollbar-measure='true'] {
1230
+ scrollbar-width: thin;
1231
+ scrollbar-color: var(--trees-scrollbar-thumb) transparent;
1232
+ }
1233
+ }
1234
+
1235
+ [data-file-tree-virtualized-scroll='true'] {
1236
+ position: relative;
1237
+ overflow-y: auto;
1238
+ flex: 1 1 0;
1239
+ min-height: 0;
1240
+ padding-inline: max(
1241
+ calc(var(--trees-padding-inline) - var(--trees-item-margin-x)),
1242
+ 0px
1243
+ )
1244
+ /* NOTE(amadeus): We can assume that all Webkit based browser gutters
1245
+ * will align to the value of '--trees-scrollbar-gutter', however if not, then
1246
+ * \`--trees-scrollbar-gutter-measured\` should correct it. Mostly we are
1247
+ * hoping to avoid SSR alignment jumps if possible. In non-SSR'd environments
1248
+ * \`--trees-scrollbar-gutter-measured\` should always be immediately available.
1249
+ */
1250
+ max(
1251
+ calc(
1252
+ var(--trees-padding-inline) - var(--trees-item-margin-x) -
1253
+ var(
1254
+ --trees-scrollbar-gutter-measured,
1255
+ var(--trees-scrollbar-gutter)
1256
+ )
1257
+ ),
1258
+ 0px
1259
+ );
1260
+ }
1261
+
1262
+ @supports (-moz-appearance: none) {
1263
+ [data-file-tree-virtualized-scroll='true'] {
1264
+ padding-inline: max(
1265
+ calc(var(--trees-padding-inline) - var(--trees-item-margin-x)),
1266
+ 0px
1267
+ )
1268
+ /* NOTE(amadeus): However on Firefox it can vary a little bit, but most
1269
+ * likely the majority of cases will default to a 0px width scrollbar lets
1270
+ * inherit that first to avoid SSR jumps. In non-SSR'd environments
1271
+ * \`--trees-scrollbar-gutter-measured\` should always be immediately available.
1272
+ */
1273
+ max(
1274
+ calc(
1275
+ var(--trees-padding-inline) - var(--trees-item-margin-x) -
1276
+ var(--trees-scrollbar-gutter-measured, 0px)
1277
+ ),
1278
+ 0px
1279
+ );
1280
+ }
1281
+ }
1282
+
1283
+ [data-file-tree-sticky-overlay='true'] {
1284
+ position: sticky;
1285
+ top: 0;
1286
+ height: 0;
1287
+ z-index: 4;
1288
+ overflow: visible;
1289
+ pointer-events: none;
1290
+ }
1291
+
1292
+ /* The overlay DOM is kept populated even at scrollTop=0 so the browser has
1293
+ * the rendered rows on hand the moment scrolling begins — otherwise the
1294
+ * compositor paints a scrolled frame before React can mount the overlay,
1295
+ * and the topmost sticky folder jumps up by a couple of pixels before it
1296
+ * "snaps" into its pinned position. We hide it via CSS whenever the scroll
1297
+ * is at the top and no scroll is in progress, so the preview doesn't leak
1298
+ * through at rest. \`data-overlay-reveal\` is stamped on the root only when
1299
+ * the user initiates a scroll while already at the top — exactly the case
1300
+ * where we need the pre-mounted overlay to be visible through the first
1301
+ * compositor frame. It is deliberately distinct from the general
1302
+ * \`data-is-scrolling\` flag so a scroll that ends at the top (e.g. ArrowUp
1303
+ * navigation) re-hides the overlay the instant the scroll lands, rather
1304
+ * than waiting for the hover-suppression timer to elapse. */
1305
+ [data-file-tree-virtualized-root='true'][data-scroll-at-top='true']:not(
1306
+ [data-overlay-reveal]
1307
+ )
1308
+ [data-file-tree-sticky-overlay='true'] {
1309
+ visibility: hidden;
1310
+ }
1311
+
1312
+ [data-file-tree-sticky-overlay-content='true'] {
1313
+ background-color: var(--trees-bg);
1314
+ position: relative;
1315
+ pointer-events: none;
1316
+ }
1317
+
1318
+ [data-file-tree-virtualized-list='true'] {
1319
+ background-color: var(--trees-bg);
1320
+ position: relative;
1321
+ min-height: 100%;
1322
+ width: 100%;
1323
+ overflow-anchor: none;
1324
+
1325
+ &[data-is-scrolling] {
1326
+ pointer-events: none;
1327
+ }
1328
+ }
1329
+
1330
+ [data-file-tree-virtualized-sticky-offset='true'] {
1331
+ contain: layout size;
1332
+ }
1333
+
1334
+ [data-file-tree-virtualized-sticky='true'] {
1335
+ position: sticky;
1336
+ top: 0;
1337
+ width: 100%;
1338
+ display: flex;
1339
+ flex-direction: column;
1340
+ isolation: isolate;
1341
+ /* Promote to its own compositor layer so text inside the window is
1342
+ * rasterized once and GPU-translated during scroll. Without this, the
1343
+ * browser re-paints the window (and its text) at every scroll frame,
1344
+ * which produces visible 1px shake / character tearing. */
1345
+ will-change: transform;
1346
+ }
1347
+
1348
+ [data-file-tree-search-container] {
1349
+ display: flex;
1350
+ padding: 0;
1351
+ padding-inline: var(--trees-padding-inline);
1352
+ margin-bottom: var(--trees-item-row-gap);
1353
+ }
1354
+
1355
+ [data-file-tree-search-input] {
1356
+ --trees-focus-ring-width: 2px;
1357
+ font-family: var(--trees-font-family);
1358
+ font-size: var(--trees-font-size);
1359
+ flex: 1;
1360
+ height: var(--trees-row-height);
1361
+ /* 1px breathing room so the focus-visible outline isn't clipped when the
1362
+ * input sits flush against the top of the scroll container. */
1363
+ margin-block: 1px;
1364
+ padding-inline: var(--trees-item-padding-x);
1365
+ line-height: var(--trees-row-height);
1366
+ color: var(--trees-search-fg);
1367
+ background-color: var(--trees-search-bg);
1368
+ border: 1px solid var(--trees-border-color);
1369
+ border-radius: var(--trees-border-radius);
1370
+ outline: none;
1371
+
1372
+ &::placeholder {
1373
+ color: color-mix(
1374
+ in lab,
1375
+ var(--trees-search-fg) 65%,
1376
+ var(--trees-search-bg)
1377
+ );
1378
+ }
1379
+
1380
+ &:focus-visible,
1381
+ &[data-file-tree-search-input-fake-focus='true'] {
1382
+ outline: var(--trees-focus-ring-width) solid var(--trees-focus-ring-color);
1383
+ outline-offset: var(--trees-focus-ring-offset);
1384
+ }
1385
+ }
1386
+
1387
+ /* The wrapper for the tree items */
1388
+ [role='tree'] {
1389
+ position: relative;
1390
+ display: flex;
1391
+ flex-direction: column;
1392
+ gap: var(--trees-gap-override, 0);
1393
+ }
1394
+
1395
+ /* LIST ITEM */
1396
+ [data-type='item'] {
1397
+ color: inherit;
1398
+ font-family: var(--trees-font-family);
1399
+ font-size: var(--trees-font-size);
1400
+ text-align: start;
1401
+ outline: none;
1402
+ background-color: var(--trees-bg);
1403
+ border: none;
1404
+ position: relative;
1405
+
1406
+ padding: 0 var(--trees-item-padding-x);
1407
+ margin: 0 var(--trees-item-margin-x);
1408
+ cursor: pointer;
1409
+ -webkit-user-select: none;
1410
+ user-select: none;
1411
+ -webkit-touch-callout: none;
1412
+ touch-action: manipulation;
1413
+ display: flex;
1414
+ flex: 0 0 var(--trees-row-height);
1415
+ align-items: center;
1416
+ height: var(--trees-row-height);
1417
+ line-height: var(--trees-row-height);
1418
+ gap: var(--trees-item-row-gap);
1419
+ border-radius: var(--trees-border-radius);
1420
+ /* Row states may be translucent, so markers paint the tree background first
1421
+ * and then the state color on top to avoid compositing the same alpha twice. */
1422
+ --truncate-marker-background-color: var(--trees-bg);
1423
+ --truncate-marker-background-overlay-color: transparent;
1424
+ --truncate-marker-block-inset: 0px;
1425
+
1426
+ &:hover,
1427
+ &[data-item-context-hover='true'] {
1428
+ background-color: var(--trees-bg-muted);
1429
+ --truncate-marker-background-overlay-color: var(--trees-bg-muted);
1430
+ }
1431
+
1432
+ &[data-item-focused='true'],
1433
+ &:focus-visible {
1434
+ z-index: 2;
1435
+
1436
+ /* Flattened segment markers sit high enough to cover the row outline unless
1437
+ * their painted background is inset by the focus ring width. */
1438
+ [data-item-flattened-subitems] {
1439
+ --truncate-marker-block-inset: var(--trees-focus-ring-width);
1440
+ }
1441
+
1442
+ &::before {
1443
+ position: absolute;
1444
+ inset: 0;
1445
+ content: '';
1446
+ display: block;
1447
+ border-radius: var(--trees-border-radius);
1448
+ outline: var(--trees-focus-ring-width) solid
1449
+ var(--trees-focus-ring-color);
1450
+ outline-offset: var(--trees-focus-ring-offset);
1451
+ pointer-events: none;
1452
+ }
1453
+
1454
+ &[data-item-selected='true']::before {
1455
+ outline-color: var(--trees-selected-focused-border-color);
1456
+ }
1457
+ }
1458
+
1459
+ &[data-item-selected='true'] {
1460
+ color: var(--trees-selected-fg);
1461
+ background-color: var(--trees-selected-bg);
1462
+ --truncate-marker-background-overlay-color: var(--trees-selected-bg);
1463
+ z-index: 3;
1464
+
1465
+ [data-item-section='icon'] {
1466
+ color: var(--trees-selected-fg);
1467
+ }
1468
+ }
1469
+
1470
+ &[data-item-search-match='true'] {
1471
+ font-weight: var(--trees-search-font-weight);
1472
+ }
1473
+ }
1474
+
1475
+ [data-type='item'][data-file-tree-sticky-row='true'] {
1476
+ pointer-events: auto;
1477
+ }
1478
+
1479
+ /* Sticky rows opt back into pointer events because the overlay wrapper is
1480
+ * inert. During scroll, put them back under the same hover suppression as
1481
+ * the virtualized list so translucent hover states and menu triggers do not
1482
+ * paint over rows moving beneath the sticky stack. */
1483
+ [data-file-tree-virtualized-root='true'][data-is-scrolling]
1484
+ [data-type='item'][data-file-tree-sticky-row='true'] {
1485
+ pointer-events: none;
1486
+ }
1487
+
1488
+ [data-file-tree-virtualized-root='true'][data-is-scrolling]
1489
+ [data-type='item'][data-file-tree-sticky-row='true']:hover:not(
1490
+ [data-item-selected='true']
1491
+ ),
1492
+ [data-file-tree-virtualized-root='true'][data-is-scrolling]
1493
+ [data-type='item'][data-file-tree-sticky-row='true'][data-item-context-hover='true']:not(
1494
+ [data-item-selected='true']
1495
+ ) {
1496
+ background-color: var(--trees-bg);
1497
+ --truncate-marker-background-overlay-color: transparent;
1498
+ }
1499
+
1500
+ [data-item-selected='true']:has(+ [data-item-selected='true']) {
1501
+ border-bottom-left-radius: 0;
1502
+ border-bottom-right-radius: 0;
1503
+ }
1504
+
1505
+ [data-item-selected='true'] + [data-item-selected='true'] {
1506
+ border-top-left-radius: 0;
1507
+ border-top-right-radius: 0;
1508
+ }
1509
+
1510
+ /* Flattened Directory Parts */
1511
+ [data-item-flattened-subitems] {
1512
+ display: inline-flex;
1513
+ align-items: center;
1514
+ gap: 2px;
1515
+ }
1516
+ [data-item-flattened-subitem]:hover,
1517
+ [data-item-flattened-subitem-drag-target='true'] {
1518
+ text-decoration: underline;
1519
+ }
1520
+
1521
+ /* Icon for each item */
1522
+ [data-item-section='icon'] {
1523
+ flex-shrink: 0;
1524
+ display: flex;
1525
+ align-items: center;
1526
+ justify-content: center;
1527
+ color: var(--trees-fg-muted);
1528
+ fill: currentColor;
1529
+ width: var(--trees-icon-width);
1530
+ }
1531
+
1532
+ :where([data-item-section='icon'] > [data-icon-token]) {
1533
+ color: var(--trees-fg-muted);
1534
+ }
1535
+
1536
+ [data-file-tree-colored-icons='true'] {
1537
+ [data-icon-token='astro'] {
1538
+ color: var(--trees-file-icon-color-astro);
1539
+ }
1540
+ [data-icon-token='babel'] {
1541
+ color: var(--trees-file-icon-color-babel);
1542
+ }
1543
+ [data-icon-token='bash'] {
1544
+ color: var(--trees-file-icon-color-bash);
1545
+ }
1546
+ [data-icon-token='biome'] {
1547
+ color: var(--trees-file-icon-color-biome);
1548
+ }
1549
+ [data-icon-token='bootstrap'] {
1550
+ color: var(--trees-file-icon-color-bootstrap);
1551
+ }
1552
+ [data-icon-token='browserslist'] {
1553
+ color: var(--trees-file-icon-color-browserslist);
1554
+ }
1555
+ [data-icon-token='bun'] {
1556
+ color: var(--trees-file-icon-color-bun);
1557
+ }
1558
+ [data-icon-token='claude'] {
1559
+ color: var(--trees-file-icon-color-claude);
1560
+ }
1561
+ [data-icon-token='css'] {
1562
+ color: var(--trees-file-icon-color-css);
1563
+ }
1564
+ [data-icon-token='database'] {
1565
+ color: var(--trees-file-icon-color-database);
1566
+ }
1567
+ [data-icon-token='default'] {
1568
+ color: var(--trees-file-icon-color-default);
1569
+ }
1570
+ [data-icon-token='docker'] {
1571
+ color: var(--trees-file-icon-color-docker);
1572
+ }
1573
+ [data-icon-token='eslint'] {
1574
+ color: var(--trees-file-icon-color-eslint);
1575
+ }
1576
+ [data-icon-token='git'] {
1577
+ color: var(--trees-file-icon-color-git);
1578
+ }
1579
+ [data-icon-token='go'] {
1580
+ color: var(--trees-file-icon-color-go);
1581
+ }
1582
+ [data-icon-token='graphql'] {
1583
+ color: var(--trees-file-icon-color-graphql);
1584
+ }
1585
+ [data-icon-token='html'] {
1586
+ color: var(--trees-file-icon-color-html);
1587
+ }
1588
+ [data-icon-token='image'] {
1589
+ color: var(--trees-file-icon-color-image);
1590
+ }
1591
+ [data-icon-token='javascript'] {
1592
+ color: var(--trees-file-icon-color-javascript);
1593
+ }
1594
+ [data-icon-token='json'] {
1595
+ color: var(--trees-file-icon-color-json);
1596
+ }
1597
+ [data-icon-token='markdown'] {
1598
+ color: var(--trees-file-icon-color-markdown);
1599
+ }
1600
+ [data-icon-token='mcp'] {
1601
+ color: var(--trees-file-icon-color-mcp);
1602
+ }
1603
+ [data-icon-token='npm'] {
1604
+ color: var(--trees-file-icon-color-npm);
1605
+ }
1606
+ [data-icon-token='oxc'] {
1607
+ color: var(--trees-file-icon-color-oxc);
1608
+ }
1609
+ [data-icon-token='postcss'] {
1610
+ color: var(--trees-file-icon-color-postcss);
1611
+ }
1612
+ [data-icon-token='prettier'] {
1613
+ color: var(--trees-file-icon-color-prettier);
1614
+ }
1615
+ [data-icon-token='python'] {
1616
+ color: var(--trees-file-icon-color-python);
1617
+ }
1618
+ [data-icon-token='react'] {
1619
+ color: var(--trees-file-icon-color-react);
1620
+ }
1621
+ [data-icon-token='ruby'] {
1622
+ color: var(--trees-file-icon-color-ruby);
1623
+ }
1624
+ [data-icon-token='rust'] {
1625
+ color: var(--trees-file-icon-color-rust);
1626
+ }
1627
+ [data-icon-token='sass'] {
1628
+ color: var(--trees-file-icon-color-sass);
1629
+ }
1630
+ [data-icon-token='svg'] {
1631
+ color: var(--trees-file-icon-color-svg);
1632
+ }
1633
+ [data-icon-token='svelte'] {
1634
+ color: var(--trees-file-icon-color-svelte);
1635
+ }
1636
+ [data-icon-token='svgo'] {
1637
+ color: var(--trees-file-icon-color-svgo);
1638
+ }
1639
+ [data-icon-token='swift'] {
1640
+ color: var(--trees-file-icon-color-swift);
1641
+ }
1642
+ [data-icon-token='table'] {
1643
+ color: var(--trees-file-icon-color-table);
1644
+ }
1645
+ [data-icon-token='text'] {
1646
+ color: var(--trees-file-icon-color-text);
1647
+ }
1648
+ [data-icon-token='tailwind'] {
1649
+ color: var(--trees-file-icon-color-tailwind);
1650
+ }
1651
+ [data-icon-token='terraform'] {
1652
+ color: var(--trees-file-icon-color-terraform);
1653
+ }
1654
+ [data-icon-token='typescript'] {
1655
+ color: var(--trees-file-icon-color-typescript);
1656
+ }
1657
+ [data-icon-token='vite'] {
1658
+ color: var(--trees-file-icon-color-vite);
1659
+ }
1660
+ [data-icon-token='vscode'] {
1661
+ color: var(--trees-file-icon-color-vscode);
1662
+ }
1663
+ [data-icon-token='vue'] {
1664
+ color: var(--trees-file-icon-color-vue);
1665
+ }
1666
+ [data-icon-token='wasm'] {
1667
+ color: var(--trees-file-icon-color-wasm);
1668
+ }
1669
+ [data-icon-token='webpack'] {
1670
+ color: var(--trees-file-icon-color-webpack);
1671
+ }
1672
+ [data-icon-token='yml'] {
1673
+ color: var(--trees-file-icon-color-yml);
1674
+ }
1675
+ [data-icon-token='zig'] {
1676
+ color: var(--trees-file-icon-color-zig);
1677
+ }
1678
+ [data-icon-token='zip'] {
1679
+ color: var(--trees-file-icon-color-zip);
1680
+ }
1681
+ }
1682
+
1683
+ /* Chevron rotation and visual alignment */
1684
+ /* Chevron pointing down */
1685
+ [data-icon-name='file-tree-icon-chevron'] {
1686
+ &[data-align-capitals='false'] {
1687
+ transform: translate(0, var(--trees-icon-nudge));
1688
+ }
1689
+ &[data-align-capitals='true'] {
1690
+ transform: translate(0, 0);
1691
+ }
1692
+ }
1693
+
1694
+ [data-item-section='content'] {
1695
+ flex: 0 1 auto;
1696
+ text-align: start;
1697
+ min-width: 0;
1698
+ max-width: 100%;
1699
+ overflow: hidden;
1700
+ text-overflow: ellipsis;
1701
+ /* Breaks middle truncate component to also set this */
1702
+ /* white-space: nowrap; */
1703
+ }
1704
+
1705
+ [data-item-section='decoration'] {
1706
+ flex: 1 1 0;
1707
+ min-width: 0;
1708
+ display: flex;
1709
+ justify-content: flex-end;
1710
+ text-align: end;
1711
+ overflow: hidden;
1712
+ color: var(--trees-fg-muted);
1713
+ }
1714
+
1715
+ [data-item-section='decoration'] > span {
1716
+ min-width: 0;
1717
+ max-width: 100%;
1718
+ display: inline-flex;
1719
+ align-items: center;
1720
+ justify-content: flex-end;
1721
+ overflow: hidden;
1722
+ text-overflow: ellipsis;
1723
+ white-space: nowrap;
1724
+ }
1725
+
1726
+ [data-item-section='git'],
1727
+ [data-item-section='action'] {
1728
+ flex: 0 0 auto;
1729
+ display: flex;
1730
+ align-items: center;
1731
+ justify-content: center;
1732
+ }
1733
+
1734
+ [data-item-section='git'] {
1735
+ width: var(--trees-git-lane-width);
1736
+ }
1737
+
1738
+ [data-item-section='action'] {
1739
+ width: var(--trees-action-lane-width);
1740
+ color: var(--trees-fg-muted);
1741
+ fill: currentColor;
1742
+ pointer-events: none;
1743
+ }
1744
+
1745
+ [data-item-section='git'] > span,
1746
+ [data-item-section='action'] > span {
1747
+ width: 100%;
1748
+ display: inline-flex;
1749
+ align-items: center;
1750
+ justify-content: center;
1751
+ }
1752
+
1753
+ [data-item-action-affordance='decorative'] {
1754
+ opacity: 0.85;
1755
+ }
1756
+
1757
+ [data-item-rename-input] {
1758
+ appearance: none;
1759
+ width: 100%;
1760
+ min-width: 0;
1761
+ height: calc(var(--trees-row-height) - 4px);
1762
+ font-family: inherit;
1763
+ font-size: inherit;
1764
+ /* line-height: calc(var(--trees-row-height) - 8px); */
1765
+ color: inherit;
1766
+ background-color: transparent;
1767
+ border: 0;
1768
+ padding-inline: 6px;
1769
+ outline: none;
1770
+ box-sizing: border-box;
1771
+ }
1772
+
1773
+ [data-item-section='content']:has([data-item-rename-input])
1774
+ ~ [data-item-section='action'],
1775
+ [data-item-section='content']:has([data-item-rename-input])
1776
+ ~ [data-item-section='decoration'] {
1777
+ display: none;
1778
+ }
1779
+
1780
+ /* Chevron pointing right */
1781
+ [aria-expanded='false'][data-item-type='folder']
1782
+ > [data-item-section='icon']
1783
+ > [data-icon-name='file-tree-icon-chevron'] {
1784
+ &[data-align-capitals='true'] {
1785
+ transform: rotate(-90deg)
1786
+ translate(
1787
+ calc(var(--trees-icon-nudge) / 2),
1788
+ calc(var(--trees-icon-nudge) / 2)
1789
+ );
1790
+ }
1791
+ &[data-align-capitals='false'] {
1792
+ transform: rotate(-90deg)
1793
+ translate(
1794
+ calc(var(--trees-icon-nudge) / 2 * -1),
1795
+ calc(var(--trees-icon-nudge) / 2)
1796
+ );
1797
+ }
1798
+ }
1799
+
1800
+ /* LIST IDENTATION */
1801
+ /* Spacing container */
1802
+ [data-item-section='spacing'] {
1803
+ display: flex;
1804
+ flex-direction: row;
1805
+ align-items: center;
1806
+ justify-content: center;
1807
+ height: var(--trees-row-height);
1808
+ padding-left: calc(calc(var(--trees-icon-width) / 2) - 0.5px);
1809
+
1810
+ &:empty {
1811
+ padding-left: 0;
1812
+ }
1813
+ }
1814
+
1815
+ /* Spacing per level */
1816
+ [data-item-section='spacing-item'] {
1817
+ transform: translateX(-0.25px);
1818
+ display: inline-block;
1819
+ border-left: 1px solid var(--trees-indent-guide-bg);
1820
+ height: 100%;
1821
+ margin-right: calc(var(--trees-level-gap) - 1px);
1822
+ opacity: 0;
1823
+ transition: opacity 150ms ease;
1824
+
1825
+ & + & {
1826
+ margin-left: calc(
1827
+ var(--trees-item-row-gap) + calc(var(--trees-icon-width) / 2) - 0.5px
1828
+ );
1829
+ }
1830
+ }
1831
+
1832
+ :host(:hover) [data-item-section='spacing-item'] {
1833
+ opacity: 0.75;
1834
+ }
1835
+
1836
+ /* Git status indicator */
1837
+
1838
+ /* This is a folder that contains a git change */
1839
+ [data-item-contains-git-change='true'] > [data-item-section='git'] {
1840
+ color: var(--trees-git-modified-color);
1841
+ opacity: 0.5;
1842
+ fill: currentColor;
1843
+ }
1844
+
1845
+ /* These are files that have a git change */
1846
+ [data-item-git-status] {
1847
+ &
1848
+ > :where([data-item-section='icon'])
1849
+ > :where(:not([data-icon-name='file-tree-icon-chevron'])) {
1850
+ color: var(--trees-item-git-status-color);
1851
+ }
1852
+ & > [data-item-section='content'] {
1853
+ color: var(--trees-item-git-status-color);
1854
+ }
1855
+ & > [data-item-section='git'] {
1856
+ color: var(--trees-item-git-status-color);
1857
+ font-weight: var(--trees-font-weight-semibold);
1858
+ }
1859
+ }
1860
+
1861
+ [data-item-git-status='added'] {
1862
+ --trees-item-git-status-color: var(--trees-git-added-color);
1863
+ }
1864
+
1865
+ [data-item-git-status='deleted'] {
1866
+ --trees-item-git-status-color: var(--trees-git-deleted-color);
1867
+ }
1868
+
1869
+ [data-item-git-status='ignored'] {
1870
+ --trees-item-git-status-color: var(--trees-git-ignored-color);
1871
+
1872
+ & > [data-item-section='icon'] {
1873
+ opacity: 0.5;
1874
+ }
1875
+ }
1876
+
1877
+ [data-item-section='git'] [data-icon-name='file-tree-icon-dot'] {
1878
+ /* this is a nudge to align the dot with the likely lowercase text. it's slightly
1879
+ generalizable, but other fonts are gonna need other nudges i assume */
1880
+ transform: translateY(calc(0.65ex - 50%));
1881
+ }
1882
+
1883
+ [data-item-git-status='modified'] {
1884
+ --trees-item-git-status-color: var(--trees-git-modified-color);
1885
+ }
1886
+
1887
+ [data-item-git-status='renamed'] {
1888
+ --trees-item-git-status-color: var(--trees-git-renamed-color);
1889
+ }
1890
+
1891
+ [data-item-git-status='untracked'] {
1892
+ --trees-item-git-status-color: var(--trees-git-untracked-color);
1893
+ }
1894
+
1895
+ /* Drag and drop */
1896
+ [data-item-drag-target='true'] {
1897
+ background-color: var(--trees-selected-bg);
1898
+ }
1899
+
1900
+ [data-item-dragging='true'] {
1901
+ opacity: 0.5;
1902
+ }
1903
+
1904
+ /* Lock icon for locked paths (sibling of content) */
1905
+ [data-item-section='lock'] {
1906
+ flex: 0 0 auto;
1907
+ margin-left: auto;
1908
+ display: flex;
1909
+ align-items: center;
1910
+ color: var(--trees-fg-muted);
1911
+ }
1912
+ [data-item-section='lock'] svg {
1913
+ display: block;
1914
+ }
1915
+
1916
+ [data-type='header-slot'] {
1917
+ display: block;
1918
+ flex: 0 0 auto;
1919
+ }
1920
+
1921
+ [data-type='context-menu-wash'] {
1922
+ position: absolute;
1923
+ inset: 0;
1924
+ z-index: 3;
1925
+ background-color: transparent;
1926
+ touch-action: none;
1927
+ }
1928
+
1929
+ [data-type='context-menu-anchor'] {
1930
+ position: absolute;
1931
+ top: 0;
1932
+ right: var(--trees-context-menu-trigger-inline-offset);
1933
+ z-index: 4;
1934
+ display: none;
1935
+ align-items: center;
1936
+
1937
+ &[data-visible='true'] {
1938
+ display: flex;
1939
+ }
1940
+ }
1941
+
1942
+ /* Hide the floating trigger while the scroll container is actively moving.
1943
+ * The anchor is positioned against the root, not the scroll content, so its
1944
+ * \`top\` follows the row via a React state update — one frame behind the
1945
+ * compositor. That delay is visible as the trigger hovering over the wrong
1946
+ * row during the first frame of a scroll. The \`data-is-scrolling\` flag on
1947
+ * the root is flipped synchronously on \`wheel\`/\`touchmove\`/\`keydown\` before
1948
+ * the compositor commits the next paint, so this selector hides the anchor
1949
+ * in the same frame the scroll begins. */
1950
+ [data-file-tree-virtualized-root='true'][data-is-scrolling]
1951
+ [data-type='context-menu-anchor'] {
1952
+ display: none;
1953
+ }
1954
+
1955
+ [data-type='context-menu-anchor'] > slot[name='context-menu'] {
1956
+ display: block;
1957
+ width: 0;
1958
+ min-width: 0;
1959
+ flex: 0 0 0;
1960
+ overflow: visible;
1961
+ }
1962
+
1963
+ /* Single floating context menu trigger */
1964
+ [data-type='context-menu-trigger'] {
1965
+ all: unset;
1966
+ align-items: center;
1967
+ justify-content: center;
1968
+ width: var(--trees-action-lane-width);
1969
+ color: var(--trees-fg-muted);
1970
+ fill: currentColor;
1971
+ cursor: pointer;
1972
+ font-family: var(--trees-font-family);
1973
+ font-size: var(--trees-font-size);
1974
+ border-top-right-radius: var(--trees-border-radius);
1975
+ border-bottom-right-radius: var(--trees-border-radius);
1976
+ margin: var(--trees-focus-ring-width);
1977
+ height: calc(var(--trees-row-height) - var(--trees-focus-ring-width) * 2);
1978
+ border-width: 0;
1979
+ transition: color 120ms ease;
1980
+
1981
+ display: flex;
1982
+ }
1983
+
1984
+ [data-type='context-menu-trigger']:hover,
1985
+ [data-type='context-menu-trigger'][aria-expanded='true'] {
1986
+ color: var(--trees-fg);
1987
+ }
1988
+
1989
+ /** @pierre/truncate css here, manually copy pasted for now */
1990
+ [data-truncate-container] {
1991
+ /* CUSTOM TO TREES, TO SUPPORT THE OUTLINE */
1992
+ margin-top: -1px;
1993
+ margin-bottom: -1px;
1994
+
1995
+ /* Width of the fade from default marker to text */
1996
+ --truncate-internal-marker-fade-width: var(
1997
+ --truncate-marker-fade-width,
1998
+ 2px
1999
+ );
2000
+ /* Width of the solid color between the fade from the default marker to the text */
2001
+ --truncate-internal-marker-gap: var(--truncate-marker-gap, 0px);
2002
+ /* Opacity of the marker 'color' property, not of the element itself */
2003
+ --truncate-internal-marker-opacity: var(--truncate-marker-opacity, 50%);
2004
+ /* Opacity of the marker 'color' property specifically for the middle truncate, not opacity of the element itself */
2005
+ --truncate-internal-middle-marker-opacity: var(
2006
+ --truncate-middle-marker-opacity,
2007
+ 80%
2008
+ );
2009
+ /* Background color of the default marker */
2010
+ --truncate-internal-marker-background-color: var(
2011
+ --truncate-marker-background-color,
2012
+ light-dark(white, black)
2013
+ );
2014
+ --truncate-internal-marker-background-overlay-color: var(
2015
+ --truncate-marker-background-overlay-color,
2016
+ transparent
2017
+ );
2018
+ --truncate-internal-marker-block-inset: var(
2019
+ --truncate-marker-block-inset,
2020
+ 0px
2021
+ );
2022
+ /* Duration of the fade out animation for the marker */
2023
+ --truncate-internal-marker-fade-out-duration: var(
2024
+ --truncate-marker-fade-out-duration,
2025
+ 0ms
2026
+ );
2027
+ /* Duration of the fade in animation for the marker */
2028
+ --truncate-internal-marker-fade-in-duration: var(
2029
+ --truncate-marker-fade-in-duration,
2030
+ 100ms
2031
+ );
2032
+
2033
+ /* FADE Variant specifics */
2034
+ --truncate-internal-fade-marker-color: var(
2035
+ --truncate-fade-marker-color,
2036
+ #000
2037
+ );
2038
+ --truncate-internal-fade-marker-width: var(
2039
+ --truncate-fade-marker-width,
2040
+ 0.2lh
2041
+ );
2042
+
2043
+ /*
2044
+ In some special cases people might be adding spacing in other ways
2045
+ that would benefit from being able to override this, however the container
2046
+ query below can't use this and would need to be redeclared with the overridden
2047
+ value. It's a bad time, but better than nothing.
2048
+ */
2049
+ --truncate-internal-single-line-height: 1lh;
2050
+
2051
+ height: var(--truncate-internal-single-line-height);
2052
+ min-width: 0;
2053
+ overflow: hidden;
2054
+ }
2055
+
2056
+ [data-truncate-marker] {
2057
+ display: flex;
2058
+ position: absolute;
2059
+ height: var(--truncate-internal-single-line-height);
2060
+ padding-block: var(--truncate-internal-marker-block-inset);
2061
+ box-sizing: border-box;
2062
+ align-items: center;
2063
+ background-clip: content-box;
2064
+ z-index: 2;
2065
+ color: color-mix(
2066
+ in srgb,
2067
+ currentColor var(--truncate-internal-marker-opacity),
2068
+ transparent
2069
+ );
2070
+
2071
+ /* Core trick for hiding the marker until overflow occurs */
2072
+ opacity: 0;
2073
+ transition: opacity var(--truncate-internal-marker-fade-out-duration)
2074
+ ease-in-out;
2075
+ }
2076
+
2077
+ @container measure (height > 1lh) {
2078
+ [data-truncate-marker] {
2079
+ opacity: 1;
2080
+ transition: opacity var(--truncate-internal-marker-fade-in-duration)
2081
+ ease-in-out;
2082
+ }
2083
+ }
2084
+
2085
+ [data-truncate-grid] {
2086
+ display: grid;
2087
+ position: relative;
2088
+ }
2089
+
2090
+ [data-truncate-content='visible'] {
2091
+ white-space: nowrap;
2092
+ }
2093
+
2094
+ [data-truncate-content='overflow'] {
2095
+ opacity: 0;
2096
+ pointer-events: none;
2097
+ -webkit-user-select: none;
2098
+ user-select: none;
2099
+ word-break: break-all;
2100
+ margin-top: calc(-1 * var(--truncate-internal-single-line-height));
2101
+ }
2102
+
2103
+ [data-truncate-marker-cell] {
2104
+ container: measure / size;
2105
+ overflow: visible;
2106
+ -webkit-user-select: none;
2107
+ user-select: none;
2108
+ pointer-events: none;
2109
+ }
2110
+
2111
+ [data-truncate-container='truncate'] {
2112
+ & [data-truncate-grid] {
2113
+ grid-template-columns: minmax(0, max-content) 0;
2114
+ }
2115
+ & [data-truncate-marker] {
2116
+ right: 0;
2117
+ }
2118
+ & [data-truncate-fade] {
2119
+ margin-right: calc(-2 * var(--truncate-internal-fade-marker-width));
2120
+ }
2121
+ }
2122
+
2123
+ [data-truncate-container='fruncate'] {
2124
+ & [data-truncate-grid] {
2125
+ grid-template-columns: 0 minmax(0, max-content) auto;
2126
+ }
2127
+ & [data-truncate-content] {
2128
+ direction: rtl;
2129
+ }
2130
+ & [data-truncate-content] > span {
2131
+ unicode-bidi: plaintext;
2132
+ }
2133
+ & [data-truncate-fade] {
2134
+ margin-left: calc(-2 * var(--truncate-internal-fade-marker-width));
2135
+ }
2136
+ }
2137
+
2138
+ [data-truncate-variant='default'] {
2139
+ & [data-truncate-marker] {
2140
+ background-color: var(--truncate-internal-marker-background-color);
2141
+ background-image: linear-gradient(
2142
+ var(--truncate-internal-marker-background-overlay-color),
2143
+ var(--truncate-internal-marker-background-overlay-color)
2144
+ );
2145
+ }
2146
+ & [data-truncate-marker]::after,
2147
+ & [data-truncate-marker]::before {
2148
+ content: '';
2149
+ position: absolute;
2150
+ width: calc(
2151
+ var(--truncate-internal-marker-fade-width) +
2152
+ var(--truncate-internal-marker-gap)
2153
+ );
2154
+ inset-block-start: var(--truncate-internal-marker-block-inset);
2155
+ height: max(
2156
+ 0px,
2157
+ calc(
2158
+ var(--truncate-internal-single-line-height) -
2159
+ var(--truncate-internal-marker-block-inset) * 2
2160
+ )
2161
+ );
2162
+ background-color: var(--truncate-internal-marker-background-color);
2163
+ background-image: linear-gradient(
2164
+ var(--truncate-internal-marker-background-overlay-color),
2165
+ var(--truncate-internal-marker-background-overlay-color)
2166
+ );
2167
+ mask-image: linear-gradient(
2168
+ var(--truncate-internal-fade-dir),
2169
+ #000 0%,
2170
+ #000 var(--truncate-internal-marker-gap),
2171
+ transparent 100%
2172
+ );
2173
+ }
2174
+ & [data-truncate-marker]::after {
2175
+ --truncate-internal-fade-dir: to right;
2176
+ right: calc(
2177
+ -1 *
2178
+ (
2179
+ var(--truncate-internal-marker-fade-width) +
2180
+ var(--truncate-internal-marker-gap)
2181
+ )
2182
+ );
2183
+ }
2184
+ & [data-truncate-marker]::before {
2185
+ --truncate-internal-fade-dir: to left;
2186
+ left: calc(
2187
+ -1 *
2188
+ (
2189
+ var(--truncate-internal-marker-fade-width) +
2190
+ var(--truncate-internal-marker-gap)
2191
+ )
2192
+ );
2193
+ }
2194
+ }
2195
+
2196
+ [data-truncate-variant='fade'] {
2197
+ & [data-truncate-marker] {
2198
+ background: transparent;
2199
+ }
2200
+ }
2201
+
2202
+ [data-truncate-fade] {
2203
+ box-shadow:
2204
+ 0 0 calc(var(--truncate-internal-fade-marker-width) / 2)
2205
+ var(--truncate-internal-fade-marker-color),
2206
+ 0 0 var(--truncate-internal-fade-marker-width)
2207
+ var(--truncate-internal-fade-marker-color);
2208
+ width: calc(var(--truncate-internal-fade-marker-width) * 2);
2209
+ height: calc(
2210
+ var(--truncate-internal-single-line-height) -
2211
+ (var(--truncate-internal-fade-marker-width) * 2)
2212
+ );
2213
+ margin: var(--truncate-internal-fade-marker-width) 0;
2214
+ }
2215
+
2216
+ [data-truncate-group-container='middle'] {
2217
+ & [data-truncate-container] {
2218
+ --truncate-marker-opacity: var(--truncate-internal-middle-marker-opacity);
2219
+ }
2220
+
2221
+ display: flex;
2222
+ min-width: 0;
2223
+
2224
+ & > div {
2225
+ min-width: 0;
2226
+ }
2227
+
2228
+ & > div[data-truncate-segment-priority='1'] {
2229
+ flex: 0 1 max-content;
2230
+ }
2231
+ & > div[data-truncate-segment-priority='2'] {
2232
+ flex: 0 999999 max-content;
2233
+ }
2234
+ }
2235
+ }
2236
+ `;const z_="@layer base, unsafe;";function vw(e){return`${z_}
2237
+ @layer base {
2238
+ ${e}
2239
+ }`}function bA(e){return`${z_}
2240
+ @layer unsafe {
2241
+ ${e}
2242
+ }`}const yw=new WeakMap;function xA(e){const t=yw.get(e);if(t!=null)return t;const n=document.createElement("div");n.setAttribute(r7,"true");const r=document.createElement("div");r.style.position="relative",r.style.height="200%",n.appendChild(r),e.appendChild(n);const i=Math.max(n.offsetWidth-n.clientWidth,0);return n.remove(),yw.set(e,i),i}function _A(e,t){if(!e.isConnected)return;const n=xA(t);if(n==null)return;const r=t.querySelector(`style[${dw}]`),i=r instanceof HTMLStyleElement?r:document.createElement("style");r instanceof HTMLStyleElement||(i.setAttribute(dw,""),t.appendChild(i)),i.textContent=`:host { ${i7}: ${n}px; }`}let tf;function kA(e){var t;if(typeof CSSStyleSheet<"u"&&typeof CSSStyleSheet.prototype.replaceSync=="function"&&"adoptedStyleSheets"in e){tf==null&&(tf=new CSSStyleSheet,tf.replaceSync(vw(gw)));let n=!1;try{e.adoptedStyleSheets=[tf],n=!0}catch{}if(n){(t=e.querySelector(`style[${Fm}]`))==null||t.remove();return}}if(e.querySelector(`style[${Fm}]`)==null){const n=document.createElement("style");n.setAttribute(Fm,""),n.textContent=vw(gw),e.prepend(n)}}function Eg(e,t){SA(e,t),kA(t),_A(e,t)}function SA(e,t){const n=e.querySelector('template[shadowrootmode="open"], template[data-file-tree-shadowrootmode="open"]');n instanceof HTMLTemplateElement&&(t.childNodes.length>0||(t.appendChild(n.content.cloneNode(!0)),n.hasAttribute("shadowrootmode")&&n.remove()))}if(typeof HTMLElement<"u"&&customElements.get(Hc)==null){class e extends HTMLElement{constructor(){super()}connectedCallback(){const n=this.shadowRoot??this.attachShadow({mode:"open"});Eg(this,n)}}if(customElements.define(Hc,e),typeof document<"u")for(const t of Array.from(document.querySelectorAll(Hc)))t instanceof HTMLElement&&Eg(t,t.shadowRoot??t.attachShadow({mode:"open"}))}const CA=!0,nu=5,gh=1<<nu,H_=gh*4,EA=H_;function Fc(){return{childIdByNameId:new Map,childIds:[],childPositionById:new Map,childVisibleChunkSums:null,totalChildSubtreeNodeCount:0,totalChildVisibleSubtreeCount:0}}function ww(){return{childIdByNameId:null,childIds:[],childPositionById:null,childVisibleChunkSums:null,totalChildSubtreeNodeCount:0,totalChildVisibleSubtreeCount:0}}function ua(e,t){if(t.childIdByNameId!=null)return t.childIdByNameId;const n=new Map;for(const r of t.childIds){const i=e[r];i!=null&&n.set(i.nameId,r)}return t.childIdByNameId=n,n}function vh(e){if(e.childPositionById!=null)return e.childPositionById;const t=new Map;for(let n=0;n<e.childIds.length;n++){const r=e.childIds[n];r!=null&&t.set(r,n)}return e.childPositionById=t,t}function Lc(e,t){e.childPositionById!=null&&e.childPositionById.set(t,e.childIds.length),e.childIds.push(t)}function W_(e,t){if(e.childPositionById!=null)for(let n=t;n<e.childIds.length;n++){const r=e.childIds[n];r!=null&&e.childPositionById.set(r,n)}}function Jf(e,t){let n=0,r=0;for(const i of t.childIds){const s=e[i];s!=null&&(n+=s.subtreeNodeCount,r+=s.visibleSubtreeCount)}t.totalChildSubtreeNodeCount=n,t.totalChildVisibleSubtreeCount=r,ru(e,t)}function M0(e,t,n,r){if(e.totalChildSubtreeNodeCount+=n,e.totalChildVisibleSubtreeCount+=r,e.childVisibleChunkSums==null||r===0)return;const i=vh(e).get(t);if(i===void 0)return;const s=i>>nu;e.childVisibleChunkSums[s]+=r}function Ig(e,t,n){const r=t.childVisibleChunkSums;if(r!=null){let s=n,l=0;for(const c of r){if(s<c){const d=PA(e,t,l,s);return{...d,childVisibleIndex:n-d.localVisibleIndex}}s-=c,l+=gh}throw new Error(`Visible child index ${String(n)} is out of range`)}let i=n;for(let s=0;s<t.childIds.length;s++){const l=t.childIds[s];if(l==null)continue;const c=e[l];if(c!=null){if(i<c.visibleSubtreeCount)return{childIndex:s,childVisibleIndex:n-i,localVisibleIndex:i};i-=c.visibleSubtreeCount}}throw new Error(`Visible child index ${String(n)} is out of range`)}function IA(e,t,n){let r=0;const i=t.childVisibleChunkSums;let s=0;if(i!=null){const l=n>>nu;for(let c=0;c<l;c+=1)r+=i[c]??0;s=l<<nu}for(let l=s;l<n;l+=1){const c=t.childIds[l];if(c==null)continue;const d=e[c];d!=null&&(r+=d.visibleSubtreeCount)}return r}function ru(e,t){if(t.childIds.length<H_){t.childVisibleChunkSums=null;return}const n=Math.ceil(t.childIds.length/gh),r=new Int32Array(n);for(let i=0;i<t.childIds.length;i++){const s=t.childIds[i];if(s==null)continue;const l=e[s];l!=null&&(r[i>>nu]+=l.visibleSubtreeCount)}t.childVisibleChunkSums=r}function PA(e,t,n,r){const i=Math.min(t.childIds.length,n+gh);let s=r;for(let l=n;l<i;l++){const c=t.childIds[l];if(c==null)continue;const d=e[c];if(d!=null){if(s<d.visibleSubtreeCount)return{childIndex:l,localVisibleIndex:s};s-=d.visibleSubtreeCount}}throw new Error(`Visible child index ${String(r)} is out of range`)}const G_=0,ni=1,ms=1,Jn=2,iu=4,LA=Jn|5,O0=3,q_=1<<O0,K_=4;function hr(e,t,n=G_){return e<<K_|n<<O0|t}function Ti(e){return e.depthAndFlags>>>K_}function yh(e){return(e.depthAndFlags&q_)>>O0}function Me(e){return(e.depthAndFlags&q_)!==0}function X_(e){return e.depthAndFlags&LA}function Qt(e,t){return(X_(e)&t)!==0}function wh(e,t){e.depthAndFlags|=t}function DA(e,t){e.depthAndFlags=hr(t,X_(e),yh(e))}const Q_=Symbol("benchmarkInstrumentation");function AA(e,t){return t==null||Object.defineProperty(e,Q_,{configurable:!0,enumerable:!1,value:t,writable:!1}),e}function $0(e){return e==null?null:e[Q_]??null}function De(e,t,n){return e==null?n():e.measurePhase(t,n)}function yf(e,t,n){!Number.isFinite(n)||e==null||e.setCounter(t,n)}function bw(e){return e>=48&&e<=57}function TA(e){const t=[];let n=0,r=0;for(;r<e.length;){for(;r<e.length&&!bw(e.charCodeAt(r));)r+=1;if(r>=e.length)break;r>n&&t.push(e.slice(n,r));let i=0;for(;r<e.length&&bw(e.charCodeAt(r));)i=i*10+(e.charCodeAt(r)-48),r+=1;t.push(i),n=r}return(n<e.length||t.length===0)&&t.push(e.slice(n)),t}function Au(e){const t=e.toLowerCase();return{lowerValue:t,tokens:TA(t)}}function RA(e,t){const n=Math.min(e.length,t.length);for(let r=0;r<n;r++){const i=e[r],s=t[r];if(i===s)continue;if(typeof i=="number"&&typeof s=="number")return i<s?-1:1;const l=String(i),c=String(s);if(l!==c)return l<c?-1:1}return e.length!==t.length?e.length<t.length?-1:1:0}function B0(e,t){if(e.tokens.length===1&&t.tokens.length===1&&typeof e.tokens[0]=="string"&&typeof t.tokens[0]=="string")return e.lowerValue===t.lowerValue?0:e.lowerValue<t.lowerValue?-1:1;const n=RA(e.tokens,t.tokens);return n!==0?n:e.lowerValue!==t.lowerValue?e.lowerValue<t.lowerValue?-1:1:0}function Y_(e,t,n){const r=B0(n(e),n(t));return r!==0?r:e===t?0:e<t?-1:1}function NA(e,t){return Y_(e,t,Au)}function Zf(e,t){return t!==e.segments.length-1||e.isDirectory?ni:G_}function FA(e,t){const n=Math.min(e.segments.length,t.segments.length);for(let r=0;r<n;r++){const i=e.segments[r],s=t.segments[r];if(i===s)continue;const l=Zf(e,r);return l!==Zf(t,r)?l===ni?-1:1:NA(i,s)}return e.segments.length!==t.segments.length?e.segments.length<t.segments.length?-1:1:e.isDirectory===t.isDirectory?0:e.isDirectory?-1:1}function MA(e,t){return FA(e,t)}function OA(e,t,n){const r=s=>{const l=n.get(s);if(l!=null)return l;const c=Au(s);return n.set(s,c),c},i=Math.min(e.segments.length,t.segments.length);for(let s=0;s<i;s++){const l=e.segments[s],c=t.segments[s];if(l===c)continue;const d=Zf(e,s);return d!==Zf(t,s)?d===ni?-1:1:Y_(l,c,r)}return e.segments.length!==t.segments.length?e.segments.length<t.segments.length?-1:1:e.isDirectory===t.isDirectory?0:e.isDirectory?-1:1}function Pg(e,t){const n=e.sortKeyById[t];if(n!==void 0)return n;const r=e.valueById[t],i=Au(r);return e.sortKeyById[t]=i,i}function J_(e={}){return{flattenEmptyDirectories:e.flattenEmptyDirectories!==!1,sort:e.sort??"default"}}function Z_(e){const t=e.length>0&&e.charCodeAt(e.length-1)===47,n=t?e.length-1:e.length,r=[];let i=0;for(let s=0;s<n;s++)e.charCodeAt(s)===47&&(r.push(e.slice(i,s)),i=s+1);return r.push(e.slice(i,n)),{hasTrailingSlash:t,segments:r}}function Wc(e){const{hasTrailingSlash:t,segments:n}=Z_(e);return{basename:n[n.length-1]??"",isDirectory:t,path:e,segments:n}}function Lg(e){if(e.length===0)return{requiresDirectory:!1,segments:[]};const{hasTrailingSlash:t,segments:n}=Z_(e);return{requiresDirectory:t,segments:n}}const Mm="";function ek(){const e=new Map;return e.set(Mm,0),{idByValue:e,valueById:[Mm],sortKeyById:[Au(Mm)]}}function us(e,t){const n=e.idByValue.get(t);if(n!==void 0)return n;const r=e.valueById.length;return e.idByValue.set(t,r),e.valueById.push(t),r}function Fi(e,t){const n=e.valueById[t];if(n===void 0)throw new Error(`Unknown segment ID: ${String(t)}`);return n}const j0=Symbol("pathStorePreparedInputKind");function tk(e,t){return e[j0]=t,e}function xw(e){return{basename:e.basename,depth:e.segments.length,isDirectory:e.isDirectory,path:e.path,segments:e.segments}}function nk(e,t,n){return n==="default"?MA(e,t):n(xw(e),xw(t))}function $A(){return{depthAndFlags:hr(0,ms|Jn,ni),nameId:0,parentId:0,subtreeNodeCount:1,visibleSubtreeCount:1}}function BA(e,t){const n=Math.min(e.length,t.length);for(let r=0;r<n;r++)if(e[r]!==t[r])return r;return n}function _w(e){return e.isDirectory?e.segments.length:e.segments.length-1}function jA(e){return Array.isArray(e)&&e.every(t=>t!=null&&typeof t=="object"&&typeof t.path=="string"&&Array.isArray(t.segments)&&typeof t.basename=="string"&&typeof t.isDirectory=="boolean")}function VA(e){return Array.isArray(e)&&e.every(t=>typeof t=="string")}function UA(e,t={}){return V0(e,t).map(n=>n.path)}function zA(e,t={}){const n=V0(e,t);return tk({paths:n.map(r=>r.path),preparedPaths:n},"prepared")}function HA(e){const t=e.length;let n=!1;for(let r=0;r<t;r+=1){const i=e[r];if(i.length>0&&i.charCodeAt(i.length-1)===47){n=!0;break}}return tk({paths:e,presortedPaths:e,presortedPathsContainDirectories:n},"presorted")}function WA(e){const t=e,n=t.preparedPaths;if(t[j0]==="prepared"&&n!=null)return n;if(!jA(n))throw new Error("preparedInput must come from PathStore.prepareInput()");return n}function GA(e){const t=e;return t[j0]==="presorted"&&t.presortedPaths!=null||VA(t.presortedPaths)?t.presortedPaths:null}function qA(e){const t=e;return typeof t.presortedPathsContainDirectories=="boolean"?t.presortedPathsContainDirectories:null}function V0(e,t={}){const n=J_(t),r=$0(t);yf(r,"workload.inputFiles",e.length);const i=De(r,"store.preparePathEntries.parse",()=>e.map(s=>Wc(s)));return De(r,"store.preparePathEntries.sort",()=>i.sort((s,l)=>nk(s,l,n.sort))),i}var rk=class{constructor(e={}){F(this,"directories",new Map);F(this,"directoryStack",[0]);F(this,"presortedDirectoryNodeIds",[]);F(this,"initialExpandedPathSet");F(this,"createdDirectoriesAllExpanded",!1);F(this,"createdDirectoryCount",0);F(this,"lastPreparedPath",null);F(this,"nodes",[$A()]);F(this,"options");F(this,"instrumentation");F(this,"segmentSortKeyCache",new Map);F(this,"segmentTable",ek());F(this,"hasDeferredDirectoryIndexes",!1);this.instrumentation=$0(e),this.options=J_(e);const t=e.initialExpandedPaths??null;if(t==null||t.length===0)this.initialExpandedPathSet=null;else{const n=new Set,r=t.length;for(let i=0;i<r;i+=1){const s=t[i],l=s.length;n.add(l>0&&s.charCodeAt(l-1)===47?s.slice(0,l-1):s)}this.initialExpandedPathSet=n,this.createdDirectoriesAllExpanded=!0}this.directories.set(0,Fc())}appendPaths(e){return De(this.instrumentation,"store.builder.appendPaths.parse",()=>this.appendPreparedPaths(e.map(t=>Wc(t))))}appendPreparedPaths(e,t=!0){return this.createdDirectoriesAllExpanded=!1,De(this.instrumentation,"store.builder.appendPreparedPaths",()=>{for(const n of e)this.appendPreparedPath(n,t)}),this}appendPresortedPaths(e,t=null){return De(this.instrumentation,"store.builder.appendPresortedPaths",()=>{if(t===!1){this.appendPresortedFilePaths(e);return}this.createdDirectoriesAllExpanded=!1;let n=null,r=0;const i=this.nodes,s=this.segmentTable,l=s.idByValue,c=s.valueById,d=this.directoryStack;let f=0,m="",h=0;for(const g of e){if(n===g)throw new Error(`Duplicate path: "${g}"`);const y=g.length>0&&g.charCodeAt(g.length-1)===47,w=y?g.length-1:g.length;let _=0,C=0;if(n!=null)if(m.length>0&&g.length>m.length&&g.startsWith(m))_=h,C=m.length;else{const S=Math.min(w,n.length);let L=!0;for(let A=0;A<S;A++){const R=g.charCodeAt(A);if(R!==n.charCodeAt(A)){L=!1;break}R===47&&(_++,C=A+1)}L&&y&&S===w&&n.length>w&&n.charCodeAt(w)===47&&(_++,C=w+1)}f=_,r=_;let I=C,E=g.indexOf("/",I);for(;E>=0&&E<w;){const S=d[f];if(S===void 0)throw new Error("Directory stack underflow while building the path store");r++;const L=g.slice(I,E);let A=l.get(L);A===void 0&&(A=c.length,l.set(L,A),c.push(L));const R=i.length;i.push({depthAndFlags:hr(r,0,ni),nameId:A,parentId:S,subtreeNodeCount:1,visibleSubtreeCount:1}),this.recordCreatedDirectoryPath(g.slice(0,E)),f++,d[f]=R,I=E+1,E=g.indexOf("/",I)}if(y){if(I<w){const L=d[f];if(L===void 0)throw new Error(`Unable to resolve directory parent for "${g}"`);r++;const A=g.slice(I,w);let R=l.get(A);R===void 0&&(R=c.length,l.set(A,R),c.push(A));const U=i.length;i.push({depthAndFlags:hr(r,0,ni),nameId:R,parentId:L,subtreeNodeCount:1,visibleSubtreeCount:1}),f++,d[f]=U}const S=d[f];if(S===void 0)throw new Error(`Unable to resolve directory node for "${g}"`);this.promoteDirectoryToExplicit(S,g)}else{const S=d[f];if(S===void 0)throw new Error(`Unable to resolve file parent for "${g}"`);const L=g.slice(I);let A=l.get(L);A===void 0&&(A=c.length,l.set(L,A),c.push(L)),i.push({depthAndFlags:hr(r+1,0),nameId:A,parentId:S,subtreeNodeCount:1,visibleSubtreeCount:1})}I!==m.length&&(m=g.substring(0,I),h=r),n=g}d.length=f+1,n!=null&&(this.lastPreparedPath=Wc(n)),this.hasDeferredDirectoryIndexes=!0}),this}appendPresortedFilePaths(e){let t=null,n=0;const r=this.nodes,i=this.segmentTable,s=i.idByValue,l=i.valueById,c=this.directoryStack;let d=0,f="",m=0;for(const h of e){if(t===h)throw new Error(`Duplicate path: "${h}"`);const g=h.length;let y=0,w=0;if(t!=null)if(f.length>0&&h.length>f.length&&h.startsWith(f))y=m,w=f.length;else{const L=Math.min(g,t.length);for(let A=0;A<L;A++){const R=h.charCodeAt(A);if(R!==t.charCodeAt(A))break;R===47&&(y++,w=A+1)}}d=y,n=y;let _=w,C=h.indexOf("/",_);for(;C>=0;){const L=c[d];if(L===void 0)throw new Error("Directory stack underflow while building the path store");n++;const A=h.slice(_,C);let R=s.get(A);R===void 0&&(R=l.length,s.set(A,R),l.push(A));const U=r.length;r.push({depthAndFlags:hr(n,0,ni),nameId:R,parentId:L,subtreeNodeCount:1,visibleSubtreeCount:1}),this.recordCreatedDirectoryPath(h.slice(0,C)),this.presortedDirectoryNodeIds.push(U),d++,c[d]=U,_=C+1,C=h.indexOf("/",_)}const I=c[d];if(I===void 0)throw new Error(`Unable to resolve file parent for "${h}"`);const E=h.slice(_);let S=s.get(E);S===void 0&&(S=l.length,s.set(E,S),l.push(E)),r.push({depthAndFlags:hr(n+1,0),nameId:S,parentId:I,subtreeNodeCount:1,visibleSubtreeCount:1}),_!==f.length&&(f=h.substring(0,_),m=n),t=h}c.length=d+1,t!=null&&(this.lastPreparedPath=Wc(t)),this.hasDeferredDirectoryIndexes=!0}finish(e={}){const t=e.skipSubtreeCountPass===!0;return this.hasDeferredDirectoryIndexes?(De(this.instrumentation,"store.builder.buildDirectoryIndexes",()=>this.buildPresortedFinish(t)),this.hasDeferredDirectoryIndexes=!1):t||De(this.instrumentation,"store.builder.computeSubtreeCounts",()=>this.computeSubtreeCounts(0)),{directories:this.directories,nodes:this.nodes,options:this.options,rootId:0,segmentTable:this.segmentTable,presortedDirectoryNodeIds:this.presortedDirectoryNodeIds.length>0?this.presortedDirectoryNodeIds:null}}didMatchAllInitialExpandedPaths(){return this.createdDirectoriesAllExpanded&&this.initialExpandedPathSet!=null&&this.createdDirectoryCount===this.initialExpandedPathSet.size}appendPreparedPath(e,t){if(this.hasDeferredDirectoryIndexes&&(this.buildDirectoryIndexes(),this.hasDeferredDirectoryIndexes=!1),this.lastPreparedPath!=null){if(e.path===this.lastPreparedPath.path)throw new Error(`Duplicate path: "${e.path}"`);if(t&&(this.options.sort==="default"?OA(this.lastPreparedPath,e,this.segmentSortKeyCache):nk(this.lastPreparedPath,e,this.options.sort))>0)throw new Error(`Builder input must be sorted before appendPaths(): "${e.path}"`)}const n=this.lastPreparedPath,r=_w(e),i=n==null?0:_w(n),s=n==null?0:BA(n.segments,e.segments),l=Math.min(s,r,i);this.directoryStack.length=l+1;for(let d=l;d<r;d++){const f=this.directoryStack[this.directoryStack.length-1];if(f===void 0)throw new Error("Directory stack underflow while building the path store");const m=t?this.getOrCreateDirectoryChild(f,e.segments[d]):this.createDirectoryChild(f,e.segments[d]);this.directoryStack.push(m)}if(e.isDirectory){const d=this.directoryStack[this.directoryStack.length-1];if(d===void 0)throw new Error(`Unable to resolve directory node for "${e.path}"`);this.promoteDirectoryToExplicit(d,e.path),this.lastPreparedPath=e;return}const c=this.directoryStack[this.directoryStack.length-1];if(c===void 0)throw new Error(`Unable to resolve file parent for "${e.path}"`);t?this.createFileChild(c,e.basename,e.path):this.createFileChildUnchecked(c,e.basename),this.lastPreparedPath=e}recordCreatedDirectoryPath(e){!this.createdDirectoriesAllExpanded||this.initialExpandedPathSet==null||(this.createdDirectoryCount+=1,this.initialExpandedPathSet.has(e)||(this.createdDirectoriesAllExpanded=!1))}createFileChild(e,t,n){const r=us(this.segmentTable,t),i=this.getDirectoryIndex(e),s=i.childIdByNameId;if(s!=null&&s.get(r)!==void 0)throw new Error(`Path collides with an existing entry: "${n}"`);const l=this.nodes[e];if(l===void 0)throw new Error(`Unknown parent node ID: ${String(e)}`);const c=this.nodes.length;return this.nodes.push({depthAndFlags:hr(Ti(l)+1,0),nameId:r,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),s!=null&&s.set(r,c),Lc(i,c),c}createFileChildUnchecked(e,t){const n=us(this.segmentTable,t),r=this.getDirectoryIndex(e),i=this.nodes[e];if(i===void 0)throw new Error(`Unknown parent node ID: ${String(e)}`);const s=this.nodes.length;return this.nodes.push({depthAndFlags:hr(Ti(i)+1,0),nameId:n,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),r.childIdByNameId!=null&&r.childIdByNameId.set(n,s),Lc(r,s),s}getOrCreateDirectoryChild(e,t){const n=us(this.segmentTable,t),r=this.getDirectoryIndex(e);if(r.childIdByNameId!=null){const l=r.childIdByNameId.get(n);if(l!==void 0){const c=this.nodes[l];if(c!=null&&!Me(c))throw new Error(`Path collides with an existing file while creating directory "${t}"`);return l}}const i=this.nodes[e];if(i===void 0)throw new Error(`Unknown parent node ID: ${String(e)}`);const s=this.nodes.length;return this.nodes.push({depthAndFlags:hr(Ti(i)+1,0,ni),nameId:n,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),r.childIdByNameId!=null&&r.childIdByNameId.set(n,s),Lc(r,s),this.directories.set(s,Fc()),s}createDirectoryChild(e,t){const n=us(this.segmentTable,t),r=this.getDirectoryIndex(e),i=this.nodes[e];if(i===void 0)throw new Error(`Unknown parent node ID: ${String(e)}`);const s=this.nodes.length;return this.nodes.push({depthAndFlags:hr(Ti(i)+1,0,ni),nameId:n,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),r.childIdByNameId!=null&&r.childIdByNameId.set(n,s),Lc(r,s),this.directories.set(s,Fc()),s}promoteDirectoryToExplicit(e,t){const n=this.nodes[e];if(n===void 0)throw new Error(`Unknown directory node ID: ${String(e)}`);if(!Me(n))throw new Error(`Path is not a directory: "${t}"`);if(Qt(n,ms))throw new Error(`Duplicate path: "${t}"`);wh(n,ms)}getDirectoryIndex(e){const t=this.directories.get(e);if(t!==void 0)return t;throw new Error(`Unknown directory child index for node ${String(e)}`)}buildPresortedFinish(e){const t=this.nodes,n=this.directories;n.set(0,ww());let r=-1,i=null;for(let s=1;s<t.length;s++){const l=t[s];if(l==null)continue;if(Me(l)){const d=ww();n.set(s,d),r=s,i=d}let c;l.parentId===r?c=i:(c=n.get(l.parentId),r=l.parentId,i=c??null),c!=null&&c.childIds.push(s)}if(!e)for(let s=t.length-1;s>=1;s--){const l=t[s];if(l==null)continue;const c=t[l.parentId];c!=null&&(c.subtreeNodeCount+=l.subtreeNodeCount,c.visibleSubtreeCount+=l.visibleSubtreeCount)}}buildDirectoryIndexes(){const e=this.nodes;for(let t=1;t<e.length;t++){const n=e[t];if(n==null)continue;Me(n)&&this.directories.set(t,Fc());const r=this.directories.get(n.parentId);r!=null&&(r.childIdByNameId!=null&&r.childIdByNameId.set(n.nameId,t),Lc(r,t))}}computeSubtreeCounts(e){const t=this.nodes[e];if(t===void 0)throw new Error(`Unknown node ID: ${String(e)}`);if(!Me(t))return t.subtreeNodeCount=1,t.visibleSubtreeCount=1,1;const n=this.getDirectoryIndex(e);let r=1;for(const i of n.childIds)r+=this.computeSubtreeCounts(i);return Jf(this.nodes,n),t.subtreeNodeCount=r,t.visibleSubtreeCount=r,r}};function KA(e,t="closed",n=null){const r=QA(t);return{activeNodeCount:e.nodes.length-1,collapsedDirectoryIds:new Set,collapseNewDirectoriesByDefault:!1,defaultExpansion:r,directoriesOpenByDefault:r==="open",hasCollapsedDirectoryOverrides:!1,directoryLoadInfoById:new Map,expandedDirectoryIds:new Set,instrumentation:n,listeners:new Map,pathCacheByNodeId:new Map([[e.rootId,{path:"",version:0}]]),pathCacheVersion:0,snapshot:e,transactionStack:[]}}function XA(){return{affectedAncestorIds:new Set,affectedNodeIds:new Set,events:[]}}function QA(e){if(typeof e!="number")return e;if(!Number.isInteger(e)||e<0)throw new Error(`initialExpansion must be "open", "closed", or a non-negative integer depth. Received: ${String(e)}`);return e}function ik(e,t){return Qt(t,Jn)||e.defaultExpansion==="open"?!0:e.defaultExpansion==="closed"?!1:Ti(t)<=e.defaultExpansion}function Mn(e,t,n=e.snapshot.nodes[t]){return n==null||!Me(n)?!1:e.directoriesOpenByDefault&&!e.hasCollapsedDirectoryOverrides?!0:e.collapsedDirectoryIds.has(t)?!1:e.expandedDirectoryIds.has(t)?!0:ik(e,n)}function ou(e,t,n,r=e.snapshot.nodes[t]){if(r==null||!Me(r))return;const i=ik(e,r);if(n){if(i){e.collapsedDirectoryIds.delete(t),e.hasCollapsedDirectoryOverrides=e.collapsedDirectoryIds.size>0;return}e.expandedDirectoryIds.add(t);return}if(i){e.collapsedDirectoryIds.add(t),e.hasCollapsedDirectoryOverrides=!0;return}e.expandedDirectoryIds.delete(t)}function ok(e,t){const n=e.directoryLoadInfoById.get(t);if(n!=null)return n;const r={activeAttemptId:null,errorMessage:null,nextAttemptId:1,state:"loaded"};return e.directoryLoadInfoById.set(t,r),r}function su(e,t){var n;return((n=e.directoryLoadInfoById.get(t))==null?void 0:n.state)??"loaded"}function YA(e,t){const n=ok(e,t);if(n.state==="loading"&&n.activeAttemptId!=null)return{attemptId:n.activeAttemptId,nodeId:t,reused:!0};const r=n.nextAttemptId;return n.activeAttemptId=r,n.errorMessage=null,n.nextAttemptId+=1,n.state="loading",{attemptId:r,nodeId:t,reused:!1}}function JA(e,t){const n=ok(e,t);n.activeAttemptId=null,n.errorMessage=null,n.state="unloaded"}function ZA(e,t,n){const r=e.directoryLoadInfoById.get(t);return r==null||r.activeAttemptId!==n?!1:(r.activeAttemptId=null,r.errorMessage=null,r.state="loaded",!0)}function eT(e,t,n){var r;return((r=e.directoryLoadInfoById.get(t))==null?void 0:r.activeAttemptId)===n}function tT(e,t,n,r){const i=e.directoryLoadInfoById.get(t);return i==null||i.activeAttemptId!==n?!1:(i.activeAttemptId=null,i.errorMessage=r??null,i.state="error",!0)}function nT(e,t){e.directoryLoadInfoById.delete(t)}function rT(e,t,n){const r=n,i=e.listeners.get(t);return i!=null?i.add(r):e.listeners.set(t,new Set([r])),()=>{const s=e.listeners.get(t);s!=null&&(s.delete(r),s.size===0&&e.listeners.delete(t))}}function iT(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!0,operation:"add",path:e.path,projectionChanged:e.projectionChanged,visibleCountDelta:null}}function oT(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!0,operation:"remove",path:e.path,projectionChanged:e.projectionChanged,recursive:e.recursive,visibleCountDelta:null}}function sT(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!0,from:e.from,operation:"move",projectionChanged:e.projectionChanged,to:e.to,visibleCountDelta:null}}function aT(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!1,operation:"expand",path:e.path,projectionChanged:!0,visibleCountDelta:null}}function lT(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!1,operation:"collapse",path:e.path,projectionChanged:!0,visibleCountDelta:null}}function cT(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!1,operation:"mark-directory-unloaded",path:e.path,projectionChanged:e.projectionChanged,visibleCountDelta:null}}function uT(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],attemptId:e.attemptId,canonicalChanged:!1,operation:"begin-child-load",path:e.path,projectionChanged:e.projectionChanged,reused:e.reused,visibleCountDelta:null}}function dT(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],attemptId:e.attemptId,canonicalChanged:e.childEvents.some(t=>t.canonicalChanged),childEvents:e.childEvents,operation:"apply-child-patch",path:e.path,projectionChanged:e.projectionChanged,visibleCountDelta:null}}function fT(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],attemptId:e.attemptId,canonicalChanged:!1,operation:"complete-child-load",path:e.path,projectionChanged:e.projectionChanged,stale:e.stale,visibleCountDelta:null}}function hT(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],attemptId:e.attemptId,canonicalChanged:!1,errorMessage:e.errorMessage,operation:"fail-child-load",path:e.path,projectionChanged:e.projectionChanged,stale:e.stale,visibleCountDelta:null}}function pT(e){return{activeNodeCountAfter:e.activeNodeCountAfter,activeNodeCountBefore:e.activeNodeCountBefore,affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],cachedPathEntryCountAfter:e.cachedPathEntryCountAfter,cachedPathEntryCountBefore:e.cachedPathEntryCountBefore,canonicalChanged:!1,idsPreserved:e.idsPreserved,loadInfoEntryCountAfter:e.loadInfoEntryCountAfter,loadInfoEntryCountBefore:e.loadInfoEntryCountBefore,mode:e.mode,operation:"cleanup",projectionChanged:e.projectionChanged,reclaimedCachedPathEntryCount:e.reclaimedCachedPathEntryCount,reclaimedLoadInfoEntryCount:e.reclaimedLoadInfoEntryCount,reclaimedNodeSlotCount:e.reclaimedNodeSlotCount,reclaimedSegmentCount:e.reclaimedSegmentCount,segmentCountAfter:e.segmentCountAfter,segmentCountBefore:e.segmentCountBefore,totalNodeSlotCountAfter:e.totalNodeSlotCountAfter,totalNodeSlotCountBefore:e.totalNodeSlotCountBefore,visibleCountDelta:null}}function qn(e,t,n){return{...n,visibleCountDelta:Ag(e)-t}}function mT(e,t){const n=Ag(e),r=XA();e.transactionStack.push(r);try{t()}catch(i){throw Sw(e,r,!1),i}Sw(e,r,!0,Ag(e)-n)}function Qr(e,t){const n=e.instrumentation;if(n==null){kw(e,t);return}De(n,"store.events.record",()=>kw(e,t))}function kw(e,t){const n=e.transactionStack[e.transactionStack.length-1]??null;if(n==null){Dg(e,t);return}n.events.push(t),yT(n,t)}function Sw(e,t,n,r=null){if(e.transactionStack.pop()!==t)throw new Error("Transaction stack underflow");if(!n)return;const i=e.transactionStack[e.transactionStack.length-1]??null;if(i!=null){const c=e.instrumentation;c==null?Cw(i,t):De(c,"store.events.batch.merge",()=>Cw(i,t));return}const s=gT(t,r),l=e.instrumentation;if(l==null){Dg(e,s);return}De(l,"store.events.batch.commit",()=>Dg(e,s))}function gT(e,t){return{affectedAncestorIds:[...e.affectedAncestorIds],affectedNodeIds:[...e.affectedNodeIds],canonicalChanged:e.events.some(n=>n.canonicalChanged),events:[...e.events],operation:"batch",projectionChanged:e.events.some(n=>n.projectionChanged),visibleCountDelta:t}}function vT(e,t){for(const n of t.affectedAncestorIds)e.affectedAncestorIds.add(n);for(const n of t.affectedNodeIds)e.affectedNodeIds.add(n)}function Cw(e,t){for(const n of t.events)e.events.push(n);vT(e,t)}function yT(e,t){for(const n of t.affectedNodeIds)e.affectedNodeIds.add(n);for(const n of t.affectedAncestorIds)e.affectedAncestorIds.add(n)}function Dg(e,t){const n=e.instrumentation;if(n==null){Ew(e,t);return}De(n,"store.events.emit",()=>Ew(e,t))}function Ew(e,t){var n,r;(n=e.listeners.get(t.operation))==null||n.forEach(i=>i(t)),(r=e.listeners.get("*"))==null||r.forEach(i=>i(t))}function Ag(e){var t;return((t=e.snapshot.nodes[e.snapshot.rootId])==null?void 0:t.visibleSubtreeCount)??0}function jl(e,t){if(e.snapshot.options.flattenEmptyDirectories!==!0)return null;const n=e.snapshot.nodes[t];if(n==null||!Me(n)||Qt(n,Jn))return null;const r=e.snapshot.directories.get(t);if(r==null||r.childIds.length!==1)return null;const i=r.childIds[0];if(i==null)return null;const s=e.snapshot.nodes[i];return s==null||!Me(s)?null:i}function aa(e,t){let n=t;for(;;){const r=jl(e,n);if(r==null)return n;n=r}}function eh(e,t){const n=[t];let r=t;for(;;){const i=jl(e,r);if(i==null)return n;n.push(i),r=i}}function sk(e,t){const n=t==null?e.snapshot.rootId:Nr(e,t);return n==null?[]:bT(e,n)}function Iw(e,t){const n=Wc(t),r=n.isDirectory?n.segments:n.segments.slice(0,-1),i=ds(e,LT(e,r)),{createdNodeIds:s,directoryId:l}=xT(e,r),c=new Set(s);let d=l;if(n.isDirectory){const m=Re(e,l);if(Qt(m,ms))throw new Error(`Path already exists: "${t}"`);wh(m,ms),e.pathCacheByNodeId.set(l,{path:t,version:e.pathCacheVersion}),c.add(l)}else d=kT(e,l,n.basename),c.add(d);la(e,l);const f=ds(e,l);return iT({affectedAncestorIds:ri(e,d),affectedNodeIds:[...c],path:t,projectionChanged:ck(i,f)})}function Pw(e,t,n){const r=Nr(e,t);if(r==null)throw new Error(`Path does not exist: "${t}"`);const i=Re(e,r);if(Qt(i,Jn))throw new Error("The root node cannot be removed");if(Me(i)&&It(e,r).childIds.length>0&&n.recursive!==!0)throw new Error(`Cannot remove a non-empty directory without recursive: "${t}"`);const s=i.parentId,l=ds(e,s),c=lk(e,r);H0(e,s,r,i.nameId),W0(e,s),la(e,s);const d=ds(e,s);return oT({affectedAncestorIds:ri(e,s),affectedNodeIds:c,path:t,projectionChanged:ck(l,d),recursive:n.recursive===!0})}function Lw(e,t,n,r){const i=Nr(e,t);if(i==null)throw new Error(`Source path does not exist: "${t}"`);const s=Re(e,i);if(Qt(s,Jn))throw new Error("The root node cannot be moved");const l=r.collision??"error",c=IT(e,i,n),d=ds(e,s.parentId),f=ds(e,c.parentId),m=Fi(e.snapshot.segmentTable,s.nameId),h=us(e.snapshot.segmentTable,c.basename);if(c.parentId===s.parentId&&m===c.basename)return null;if(Me(s)&&AT(e,i,c.parentId))throw new Error("Cannot move a directory into one of its descendants");const g=ua(e.snapshot.nodes,It(e,c.parentId)).get(h),y=c.existingNodeId??g??null;if(y!=null&&y!==i&&PT(e,y,l,yh(s))==="skip")return null;const w=s.parentId;H0(e,w,i,s.nameId),s.parentId=c.parentId,s.nameId=h,e.pathCacheByNodeId.delete(i),dk(e,i),z0(e,c.parentId,i),W0(e,w),e.pathCacheVersion++,la(e,w),c.parentId!==w&&la(e,c.parentId);const _=ds(e,w),C=ds(e,c.parentId);return sT({affectedAncestorIds:[...new Set([...ri(e,w),...ri(e,c.parentId)])],affectedNodeIds:[i],from:t,projectionChanged:uk([d,f],[_,C]),to:Et(e,i)})}function wT(e,t){const n=e.pathCacheByNodeId.get(t);return n!=null&&n.version===e.pathCacheVersion?n.path:null}function Dw(e,t,n){return e.pathCacheByNodeId.set(t,{path:n,version:e.pathCacheVersion}),n}function Et(e,t){const n=Re(e,t),r=wT(e,t);if(r!=null)return r;if(Qt(n,Jn))return Dw(e,t,"");const i=Et(e,n.parentId),s=Fi(e.snapshot.segmentTable,n.nameId),l=i.length===0?s:`${i}${s}`;return Dw(e,t,Me(n)?`${l}/`:l)}function la(e,t){const n=e.instrumentation;if(n==null){Tw(e,t);return}De(n,"store.recomputeCountsUpwardFrom",()=>Tw(e,t))}function U0(e,t){const n=[[t,0]],{nodes:r,directories:i}=e.snapshot;for(;n.length>0;){const s=n[n.length-1],l=s[0],c=r[l];if(c==null||!Me(c)){Tg(e,l,c,!0),n.pop();continue}const d=i.get(l);if(d==null||s[1]>=d.childIds.length){Tg(e,l,c,!0),n.pop();continue}const f=d.childIds[s[1]++];n.push([f,0])}}function ri(e,t){const n=[];let r=t;for(;r!=null;){const i=Re(e,r);if(n.push(r),r===e.snapshot.rootId)break;r=i.parentId}return n}function Nr(e,t){if(t.length===0)return e.snapshot.rootId;const n=Lg(t);return ak(e,n.segments,n.requiresDirectory)}function ak(e,t,n){let r=e.snapshot.rootId;for(const s of t){const l=e.snapshot.segmentTable.idByValue.get(s);if(l===void 0)return null;const c=It(e,r),d=ua(e.snapshot.nodes,c).get(l);if(d===void 0)return null;r=d}const i=Re(e,r);return n&&!Me(i)?null:r}function It(e,t){const n=e.snapshot.directories.get(t);if(n===void 0)throw new Error(`Unknown directory child index for node ${String(t)}`);return n}function Re(e,t){const n=e.snapshot.nodes[t];if(n===void 0||Qt(n,iu))throw new Error(`Unknown node ID: ${String(t)}`);return n}function bT(e,t){const n=e.snapshot.nodes[t];if(n===void 0||Qt(n,iu))return[];if(!Me(n))return[Et(e,t)];if(It(e,t).childIds.length===0)return Qt(n,ms)&&!Qt(n,Jn)?[Et(e,t)]:[];const r=[],i=[{childIndex:0,nodeId:t}];for(;i.length>0;){const s=i[i.length-1];if(s==null)break;const l=e.snapshot.nodes[s.nodeId];if(l===void 0||Qt(l,iu)){i.pop();continue}if(!Me(l)){r.push(Et(e,s.nodeId)),i.pop();continue}const c=It(e,s.nodeId);if(c.childIds.length===0){Qt(l,ms)&&!Qt(l,Jn)&&r.push(Et(e,s.nodeId)),i.pop();continue}const d=c.childIds[s.childIndex];if(d==null){i.pop();continue}s.childIndex++,i.push({childIndex:0,nodeId:d})}return r}function xT(e,t){const n=[];let r=e.snapshot.rootId;for(const i of t){const s=us(e.snapshot.segmentTable,i),l=It(e,r),c=ua(e.snapshot.nodes,l).get(s);if(c!==void 0){if(!Me(Re(e,c)))throw new Error(`Cannot create a directory that collides with an existing file: "${i}"`);r=c;continue}r=_T(e,r,s),n.push(r)}return{createdNodeIds:n,directoryId:r}}function _T(e,t,n){const r=Re(e,t),i=e.snapshot.nodes.length;return e.snapshot.nodes.push({depthAndFlags:hr(Ti(r)+1,0,ni),nameId:n,parentId:t,subtreeNodeCount:1,visibleSubtreeCount:1}),e.snapshot.directories.set(i,Fc()),z0(e,t,i),e.collapseNewDirectoriesByDefault&&(e.collapsedDirectoryIds.add(i),e.hasCollapsedDirectoryOverrides=!0),e.activeNodeCount++,i}function kT(e,t,n){const r=us(e.snapshot.segmentTable,n),i=It(e,t);if(ua(e.snapshot.nodes,i).has(r))throw new Error(`Path already exists: "${TT(e,t,n)}"`);const s=Re(e,t),l=e.snapshot.nodes.length;return e.snapshot.nodes.push({depthAndFlags:hr(Ti(s)+1,0),nameId:r,parentId:t,subtreeNodeCount:1,visibleSubtreeCount:1}),z0(e,t,l),e.activeNodeCount++,l}function ST(e,t,n){let r=0,i=t.childIds.length;for(;r<i;){const s=r+i>>>1,l=t.childIds[s];if(l==null){i=s;continue}CT(e,n,l)<0?i=s:r=s+1}return r}function z0(e,t,n){const r=It(e,t),i=Re(e,n);ua(e.snapshot.nodes,r).set(i.nameId,n),M0(r,n,i.subtreeNodeCount,i.visibleSubtreeCount);const s=ST(e,r,n);r.childIds.splice(s,0,n),W_(r,s),ru(e.snapshot.nodes,r)}function H0(e,t,n,r){const i=It(e,t),s=vh(i),l=s.get(n)??-1;ua(e.snapshot.nodes,i).delete(r),s.delete(n);const c=e.snapshot.nodes[n];c!=null&&M0(i,n,-c.subtreeNodeCount,-c.visibleSubtreeCount),l>=0&&(i.childIds.splice(l,1),W_(i,l),ru(e.snapshot.nodes,i))}function CT(e,t,n){const r=e.snapshot.options.sort;return r==="default"?ET(e,t,n):r(Aw(e,t),Aw(e,n))}function ET(e,t,n){const r=Re(e,t),i=Re(e,n),s=Me(r);if(s!==Me(i))return s?-1:1;const l=B0(Pg(e.snapshot.segmentTable,r.nameId),Pg(e.snapshot.segmentTable,i.nameId));if(l!==0)return l;const c=Fi(e.snapshot.segmentTable,r.nameId),d=Fi(e.snapshot.segmentTable,i.nameId);return c!==d?c<d?-1:1:t<n?-1:1}function Aw(e,t){const n=Re(e,t),r=Et(e,t),i=Me(n),s=i?r.slice(0,-1):r;return{basename:Fi(e.snapshot.segmentTable,n.nameId),depth:Ti(n),isDirectory:i,path:r,segments:s.length===0?[]:s.split("/")}}function IT(e,t,n){const r=Re(e,t),i=Nr(e,n);if(i!=null){const f=Re(e,i);if(Me(f))return{basename:Fi(e.snapshot.segmentTable,r.nameId),existingNodeId:null,parentId:i};const m=Lg(n).segments;return{basename:m[m.length-1]??"",existingNodeId:i,parentId:f.parentId}}const s=Lg(n),l=s.segments[s.segments.length-1]??"",c=s.segments.slice(0,-1),d=c.length===0?e.snapshot.rootId:ak(e,c,!0);if(d==null)throw new Error(`Destination parent does not exist: "${n}"`);return{basename:l,existingNodeId:null,parentId:d}}function PT(e,t,n,r){if(n==="skip")return"skip";if(n==="error")throw new Error(`Destination already exists: "${Et(e,t)}"`);const i=Re(e,t);if(yh(i)!==r)throw new Error("replace collision requires the same source and destination kinds");if(Me(i)&&It(e,t).childIds.length>0)throw new Error("replace collision does not support non-empty directories");const s=i.parentId,l=i.nameId;return lk(e,t),H0(e,s,t,l),W0(e,s),la(e,s),"handled"}function lk(e,t){const n=[],r=[{nodeId:t,visitedChildren:!1}];for(;r.length>0;){const i=r.pop();if(i==null)break;const s=Re(e,i.nodeId);if(i.visitedChildren||!Me(s)){Me(s)&&e.snapshot.directories.delete(i.nodeId),wh(s,iu),e.pathCacheByNodeId.delete(i.nodeId),e.collapsedDirectoryIds.delete(i.nodeId)&&(e.hasCollapsedDirectoryOverrides=e.collapsedDirectoryIds.size>0),e.expandedDirectoryIds.delete(i.nodeId),nT(e,i.nodeId),e.activeNodeCount--,n.push(i.nodeId);continue}r.push({nodeId:i.nodeId,visitedChildren:!0});const l=It(e,i.nodeId);for(let c=l.childIds.length-1;c>=0;c--){const d=l.childIds[c];d!=null&&r.push({nodeId:d,visitedChildren:!1})}}return n}function W0(e,t){let n=t;for(;n!=null;){const r=Re(e,n);if(!Me(r)||Qt(r,Jn)||It(e,n).childIds.length>0)return;wh(r,ms),n=r.parentId===n?null:r.parentId}}function LT(e,t){let n=e.snapshot.rootId;for(const r of t){const i=e.snapshot.segmentTable.idByValue.get(r);if(i==null)break;const s=ua(e.snapshot.nodes,It(e,n)).get(i);if(s==null||!Me(Re(e,s)))break;n=s}return n}function ds(e,t){const n=DT(e,t);if(n==null)return null;const r=aa(e,n),i=Re(e,r),s=n===r?null:eh(e,n).map(l=>Et(e,l));return JSON.stringify({flattenedSegmentPaths:s,hasChildren:It(e,r).childIds.length>0,path:Et(e,r),terminalKind:yh(i)})}function ck(e,t){return uk([e],[t])}function uk(e,t){for(let n=0;n<e.length;n+=1){const r=e[n],i=t[n];if(r==null||i==null||r!==i)return!0}return!1}function DT(e,t){let n=t;for(;n!=null;){const r=Re(e,n);if(!Me(r)||Qt(r,Jn))return null;if(!Mn(e,n,r))return n;n=r.parentId}return null}function dk(e,t){const n=Re(e,t);if(DA(n,(t===e.snapshot.rootId?-1:Ti(Re(e,n.parentId)))+1),!Me(n))return;const r=It(e,t);for(const i of r.childIds)dk(e,i)}function AT(e,t,n){let r=n;for(;r!=null;){if(r===t)return!0;const i=Re(e,r);if(r===e.snapshot.rootId)return!1;r=i.parentId}return!1}function Tg(e,t,n=Re(e,t),r=!1){const i=e.instrumentation;if(i==null){Rw(e,t,n,r);return}De(i,"store.recomputeNodeCounts",()=>Rw(e,t,n,r))}function Tw(e,t){let n=t;for(;n!=null;){const r=Re(e,n),i=r.subtreeNodeCount,s=r.visibleSubtreeCount;if(Tg(e,n,r),n===e.snapshot.rootId)return;const l=r.subtreeNodeCount-i,c=r.visibleSubtreeCount-s,d=r.parentId;(l!==0||c!==0)&&M0(It(e,d),n,l,c),n=d}}function Rw(e,t,n,r){if(!Me(n)){n.subtreeNodeCount=1,n.visibleSubtreeCount=1;return}const i=It(e,t);if(r){const c=e.instrumentation;c==null?Jf(e.snapshot.nodes,i):De(c,"store.recomputeNodeCounts.rebuildChildAggregates",()=>Jf(e.snapshot.nodes,i))}const s=1+i.totalChildSubtreeNodeCount,l=i.totalChildVisibleSubtreeCount;if(n.subtreeNodeCount=s,Qt(n,Jn)){n.visibleSubtreeCount=l;return}n.visibleSubtreeCount=jl(e,t)!=null?l:Mn(e,t,n)?1+l:1}function TT(e,t,n){const r=Et(e,t);return r.length===0?n:`${r}${n}`}function Al(e){return e!=null&&!Qt(e,iu)}function th(e,t){const n=e.snapshot.nodes[t];return!Al(n)||!Me(n)||Qt(n,Jn)?null:n}function RT(e){let t=0;for(const[n,r]of e.pathCacheByNodeId)r.version===e.pathCacheVersion&&Al(e.snapshot.nodes[n])&&(t+=1);return t}function NT(e){return Math.max(0,e.valueById.length-1)}function Nw(e){return{activeNodeCount:e.activeNodeCount,cachedPathEntryCount:RT(e),loadInfoEntryCount:e.directoryLoadInfoById.size,segmentCount:NT(e.snapshot.segmentTable),totalNodeSlotCount:Math.max(0,e.snapshot.nodes.length-1)}}function FT(e,t,n,r){return{activeNodeCountAfter:r.activeNodeCount,activeNodeCountBefore:n.activeNodeCount,cachedPathEntryCountAfter:r.cachedPathEntryCount,cachedPathEntryCountBefore:n.cachedPathEntryCount,idsPreserved:t,loadInfoEntryCountAfter:r.loadInfoEntryCount,loadInfoEntryCountBefore:n.loadInfoEntryCount,mode:e,reclaimedCachedPathEntryCount:n.cachedPathEntryCount-r.cachedPathEntryCount,reclaimedLoadInfoEntryCount:n.loadInfoEntryCount-r.loadInfoEntryCount,reclaimedNodeSlotCount:n.totalNodeSlotCount-r.totalNodeSlotCount,reclaimedSegmentCount:n.segmentCount-r.segmentCount,segmentCountAfter:r.segmentCount,segmentCountBefore:n.segmentCount,totalNodeSlotCountAfter:r.totalNodeSlotCount,totalNodeSlotCountBefore:n.totalNodeSlotCount}}function fk(e){const t=[],n=[];for(const r of e.collapsedDirectoryIds)th(e,r)!=null&&t.push(Et(e,r));for(const r of e.expandedDirectoryIds)th(e,r)!=null&&n.push(Et(e,r));return{collapsedPaths:t,expandedPaths:n}}function hk(e){const t=[];for(const[n,r]of e.directoryLoadInfoById)th(e,n)==null||su(e,n)==="loaded"||t.push({info:{activeAttemptId:null,errorMessage:r.errorMessage,nextAttemptId:r.nextAttemptId,state:r.state},path:Et(e,n)});return t}function pk(e,t){e.collapsedDirectoryIds.clear(),e.hasCollapsedDirectoryOverrides=!1,e.expandedDirectoryIds.clear();for(const n of t.expandedPaths){const r=Nr(e,n);r!=null&&ou(e,r,!0,Re(e,r))}for(const n of t.collapsedPaths){const r=Nr(e,n);r!=null&&ou(e,r,!1,Re(e,r))}}function mk(e,t){e.directoryLoadInfoById.clear();for(const n of t){const r=Nr(e,n.path);r!=null&&th(e,r)!=null&&e.directoryLoadInfoById.set(r,{activeAttemptId:null,errorMessage:n.info.errorMessage,nextAttemptId:n.info.nextAttemptId,state:n.info.state})}}function MT(e){e.pathCacheVersion+=1,e.pathCacheByNodeId.clear(),e.pathCacheByNodeId.set(e.snapshot.rootId,{path:"",version:e.pathCacheVersion})}function OT(e){const t=e.snapshot.segmentTable,n=ek();for(const r of e.snapshot.nodes)if(Al(r)){if(Qt(r,Jn)){r.nameId=0;continue}r.nameId=us(n,Fi(t,r.nameId))}e.snapshot.segmentTable=n}function $T(e){for(const[t,n]of e.snapshot.directories){const r=e.snapshot.nodes[t];if(!Al(r)||!Me(r)){e.snapshot.directories.delete(t);continue}const i=n.childIds.filter(s=>{const l=e.snapshot.nodes[s];return Al(l)&&l.parentId===t});n.childIds=i,n.childIdByNameId=new Map(i.map(s=>[Re(e,s).nameId,s])),n.childPositionById=new Map(i.map((s,l)=>[s,l])),Jf(e.snapshot.nodes,n)}}function BT(e){let t=e.snapshot.nodes.length-1;for(;t>e.snapshot.rootId;){const n=e.snapshot.nodes[t];if(Al(n))break;t-=1}e.snapshot.nodes.length=t+1}function jT(e){const t=fk(e),n=hk(e);De(e.instrumentation,"store.cleanup.stable.clearPathCaches",()=>MT(e)),De(e.instrumentation,"store.cleanup.stable.rebuildSegmentTable",()=>OT(e)),De(e.instrumentation,"store.cleanup.stable.rebuildDirectoryIndexes",()=>$T(e)),De(e.instrumentation,"store.cleanup.stable.trimTrailingRemovedNodeSlots",()=>BT(e)),De(e.instrumentation,"store.cleanup.stable.restoreExpansionOverrides",()=>pk(e,t)),De(e.instrumentation,"store.cleanup.stable.restoreDirectoryLoadInfos",()=>mk(e,n)),De(e.instrumentation,"store.cleanup.stable.recomputeCounts",()=>U0(e,e.snapshot.rootId))}function VT(e){const t=fk(e),n=hk(e),r=De(e.instrumentation,"store.cleanup.aggressive.listPaths",()=>sk(e)),i=AA({...e.snapshot.options},e.instrumentation),s=De(e.instrumentation,"store.cleanup.aggressive.rebuildSnapshot",()=>{const l=new rk(i);return l.appendPaths(r),l.finish()});e.snapshot=s,e.activeNodeCount=s.nodes.length-1,e.pathCacheByNodeId=new Map([[s.rootId,{path:"",version:0}]]),e.pathCacheVersion=0,De(e.instrumentation,"store.cleanup.aggressive.restoreExpansionOverrides",()=>pk(e,t)),De(e.instrumentation,"store.cleanup.aggressive.restoreDirectoryLoadInfos",()=>mk(e,n)),De(e.instrumentation,"store.cleanup.aggressive.recomputeCounts",()=>U0(e,e.snapshot.rootId))}function UT(e){for(const t of e.directoryLoadInfoById.values())if(t.state==="loading"&&t.activeAttemptId!=null)return!0;return!1}function zT(e,t){const n=Nw(e);t==="stable"?De(e.instrumentation,"store.cleanup.stable",()=>jT(e)):De(e.instrumentation,"store.cleanup.aggressive",()=>VT(e));const r=Nw(e);return FT(t,t==="stable",n,r)}const HT=64;function WT(e,t){const n=t+2;if(n<=e.length)return e;let r=e.length;for(;r<n;)r*=2;const i=new Int32Array(r);return i.fill(-1),i.set(e),i}function _n(e){return Re(e,e.snapshot.rootId).visibleSubtreeCount}function gk(e,t,n,r){const i=Re(e,t.terminalNodeId),s=Math.max(1,i.visibleSubtreeCount);return Math.min(r-1,n+s-1)}function GT(e,t,n,r){return{ancestorPaths:r,index:t.index,posInSet:t.posInSet,row:au(e,t.cursor),setSize:t.setSize,subtreeEndIndex:gk(e,t.cursor,t.index,n)}}function vk(e,t,n,r,i,s){const l=It(e,t),{childIndex:c,childVisibleIndex:d,localVisibleIndex:f}=Ig(e.snapshot.nodes,l,n),m=l.childIds[c];if(m==null)throw new Error(`Visible index ${String(n)} is out of range`);return qT(e,m,f,r+d,i+1,c,l.childIds.length,s)}function qT(e,t,n,r,i,s,l,c){if(!Me(Re(e,t))){if(n===0)return{ancestors:c,cursor:{headNodeId:t,terminalNodeId:t,visibleDepth:i},index:r,posInSet:s,setSize:l};throw new Error(`Visible index ${String(n)} is out of range for file`)}const d=bk(e,t,i);if(n===0)return{ancestors:c,cursor:d,index:r,posInSet:s,setSize:l};const f=Re(e,d.terminalNodeId);if(!Me(f)||!Mn(e,d.terminalNodeId,f))throw new Error(`Visible index ${String(n)} is out of range for collapsed directory`);return vk(e,d.terminalNodeId,n-1,r+1,d.visibleDepth,[...c,{cursor:d,index:r,posInSet:s,setSize:l}])}function KT(e,t){const n=_n(e);if(t<0||t>=n)return null;const r=vk(e,e.snapshot.rootId,t,0,-1,[]),i=r.ancestors.map(l=>Et(e,l.cursor.terminalNodeId));let s=null;return{ancestorPaths:i,get ancestorRows(){if(s!=null)return s;const l=[],c=[];for(const d of r.ancestors){const f=GT(e,d,n,[...c]);l.push(f),c.push(f.row.path)}return s=l,s},index:r.index,posInSet:r.posInSet,row:au(e,r.cursor),setSize:r.setSize,subtreeEndIndex:gk(e,r.cursor,r.index,n)}}function XT(e,t,n){var h;const r=e.instrumentation,i=_n(e);if(i<=0||n<t)return[];const s=Math.max(0,Math.min(t,i-1)),l=Math.max(s,Math.min(n,i-1));if(r==null){if(s===0)return nR(e,l+1);const g=[];let y=Fw(e,s);for(let w=s;w<=l&&y!=null;w++){const _=au(e,y);g.push(_),y=Mw(e,y)}return g}const c=[];let d=0,f=0,m=De(r,"store.getVisibleSlice.selectFirstRow",()=>Fw(e,s));for(let g=s;g<=l&&m!=null;g++){const y=De(r,"store.getVisibleSlice.materializeRow",()=>au(e,m));c.push(y),y.isFlattened&&(d++,f+=((h=y.flattenedSegments)==null?void 0:h.length)??0),m=De(r,"store.getVisibleSlice.advanceCursor",()=>Mw(e,m))}return yf(r,"workload.visibleRowsRead",c.length),yf(r,"workload.flattenedRowsRead",d),yf(r,"workload.flattenedSegmentsRead",f),c}function yk(e,t=_n(e)){const n=e.instrumentation;return n==null?Ow(e,t):De(n,"store.getVisibleTreeProjection",()=>Ow(e,t))}function QT(e){return tR(yk(e))}function YT(e,t){const n=Nr(e,t);if(n==null||n===e.snapshot.rootId||Me(Re(e,n))&&aa(e,n)!==n)return null;let r=0,i=n;const{nodes:s,rootId:l}=e.snapshot;for(;i!==l;){const c=Re(e,i).parentId,d=It(e,c),f=vh(d).get(i);if(f==null)throw new Error(`Child ${String(i)} was not found in its parent index`);if(r+=IA(s,d,f),c!==l){const m=Re(e,c),h=jl(e,c);if(!Mn(e,c,m)&&h!==i)return null;aa(e,c)===c&&(r+=1)}i=c}return r}function JT(e,t){const n=Nr(e,t);if(n==null)throw new Error(`Path does not exist: "${t}"`);const r=Re(e,n);if(!Me(r))throw new Error(`Path is not a directory: "${t}"`);return Mn(e,n,r)?null:(ou(e,n,!0,r),la(e,n),aT({affectedAncestorIds:ri(e,n),affectedNodeIds:[n],path:t}))}function ZT(e,t){const n=Nr(e,t);if(n==null)throw new Error(`Path does not exist: "${t}"`);const r=Re(e,n);if(!Me(r))throw new Error(`Path is not a directory: "${t}"`);return Mn(e,n,r)?(ou(e,n,!1,r),la(e,n),lT({affectedAncestorIds:ri(e,n),affectedNodeIds:[n],path:t})):null}function Fw(e,t){return t<0||t>=_n(e)?null:wk(e,e.snapshot.rootId,t,-1)}function wk(e,t,n,r){const i=It(e,t),s=e.instrumentation,{childIndex:l,localVisibleIndex:c}=s==null?Ig(e.snapshot.nodes,i,n):De(s,"store.getVisibleSlice.selectChildIndex",()=>Ig(e.snapshot.nodes,i,n)),d=i.childIds[l];if(d!=null)return Rg(e,d,c,r+1);throw new Error(`Visible index ${String(n)} is out of range`)}function Rg(e,t,n,r){if(!Me(Re(e,t))){if(n===0)return{headNodeId:t,terminalNodeId:t,visibleDepth:r};throw new Error(`Visible index ${String(n)} is out of range for file`)}const i=bk(e,t,r);if(n===0)return i;const s=Re(e,i.terminalNodeId);if(!Me(s)||!Mn(e,i.terminalNodeId,s))throw new Error(`Visible index ${String(n)} is out of range for collapsed directory`);return wk(e,i.terminalNodeId,n-1,i.visibleDepth)}function bk(e,t,n){return Me(Re(e,t))?e.instrumentation==null?{headNodeId:t,terminalNodeId:aa(e,t),visibleDepth:n}:{headNodeId:t,terminalNodeId:De(e.instrumentation,"store.getVisibleSlice.flatten.resolveTerminalDirectory",()=>aa(e,t)),visibleDepth:n}:{headNodeId:t,terminalNodeId:t,visibleDepth:n}}function eR(e,t){const n=Re(e,t);if(!Me(n))return!0;const r=n.parentId;return r===e.snapshot.rootId?!0:jl(e,r)!==t}function Mw(e,t){const n=Re(e,t.terminalNodeId);if(Me(n)){const s=It(e,t.terminalNodeId);if(Mn(e,t.terminalNodeId,n)&&s.childIds.length>0){const l=s.childIds[0];return l==null?null:Rg(e,l,0,t.visibleDepth+1)}}let r=t.terminalNodeId,i=t.visibleDepth;for(;;){const s=Re(e,r);if(r===e.snapshot.rootId)return null;const l=s.parentId,c=It(e,l),d=vh(c).get(r)??-1;if(d<0)throw new Error(`Child ${String(r)} was not found in its parent index`);const f=c.childIds[d+1]??null;if(f!=null)return Rg(e,f,0,i);eR(e,r)&&i--,r=l}}function tR(e){const t=e.paths.length,n=new Array(t);for(let r=0;r<t;r+=1){const i=e.getParentIndex(r);n[r]={index:r,parentPath:i>=0?e.paths[i]??null:null,path:e.paths[r]??"",posInSet:e.posInSetByIndex[r]??0,setSize:e.setSizeByIndex[r]??0}}return{getParentIndex:e.getParentIndex,rows:n,get visibleIndexByPath(){return e.visibleIndexByPath}}}function Ow(e,t){const n=new Array(t),r=new Int32Array(t),i=new Int32Array(t),s=new Int32Array(t);let l=new Int32Array(HT);l.fill(-1);let c=0;const{nodes:d,directories:f,segmentTable:m}=e.snapshot,h=[[f.get(e.snapshot.rootId),0,-1,""]],g=e.snapshot.options.flattenEmptyDirectories,y=e.pathCacheByNodeId,w=e.pathCacheVersion,_=m.valueById;for(;h.length>0&&c<t;){const L=h[h.length-1],A=L[0];if(L[1]>=A.childIds.length){h.pop();continue}const R=L[1],U=A.childIds[L[1]++],X=d[U],H=L[2]+1,re=L[3];l=WT(l,H);let de,te=U;if(Me(X))te=g?aa(e,U):U,de=te===U?`${re}${_[X.nameId]}/`:Et(e,te);else{const ee=y.get(U);de=ee!=null&&ee.version===w?ee.path:`${re}${_[X.nameId]}`}r[c]=l[H],n[c]=de,i[c]=R,s[c]=A.childIds.length,l[H+1]=c,c+=1;const Q=d[te];Q!=null&&Me(Q)&&Mn(e,te,Q)&&h.push([f.get(te),0,H,de])}c<t&&(n.length=c);const C=r.subarray(0,c),I=i.subarray(0,c),E=s.subarray(0,c);let S=null;return{getParentIndex(L){return L<0||L>=c?-1:C[L]??-1},paths:n,posInSetByIndex:I,setSizeByIndex:E,get visibleIndexByPath(){if(S==null){S=new Map;for(let L=0;L<c;L+=1)S.set(n[L]??"",L)}return S}}}function nR(e,t){const n=new Array(t);let r=0;const{nodes:i,directories:s,segmentTable:l}=e.snapshot,c=[[s.get(e.snapshot.rootId),0,-1]],d=l.valueById,f=e.snapshot.options.flattenEmptyDirectories,m=e.pathCacheByNodeId,h=e.pathCacheVersion;for(;c.length>0&&r<t;){const g=c[c.length-1],y=g[0];if(g[1]>=y.childIds.length){c.pop();continue}const w=y.childIds[g[1]++],_=i[w],C=g[2]+1;if(!Me(_)){const L=m.get(w);n[r++]={depth:C,flattenedSegments:void 0,hasChildren:!1,id:w,isExpanded:!1,isFlattened:!1,isLoading:!1,kind:"file",loadState:void 0,name:d[_.nameId],path:L!=null&&L.version===h?L.path:Et(e,w)};continue}const I=f?aa(e,w):w,E={headNodeId:w,terminalNodeId:I,visibleDepth:C};n[r++]=au(e,E);const S=i[I];S!=null&&Me(S)&&Mn(e,I,S)&&c.push([s.get(I),0,C])}return r<t&&(n.length=r),n}function au(e,t){const n=Re(e,t.terminalNodeId),r=Me(n)?rR(e,t):null,i=Et(e,t.terminalNodeId),s=Fi(e.snapshot.segmentTable,n.nameId),l=Me(n)&&It(e,t.terminalNodeId).childIds.length>0,c=t.headNodeId!==t.terminalNodeId,d=e.instrumentation,f=c?d==null?eh(e,t.headNodeId).map(m=>{const h=Re(e,m);return{isTerminal:m===t.terminalNodeId,name:Fi(e.snapshot.segmentTable,h.nameId),nodeId:m,path:Et(e,m)}}):De(d,"store.getVisibleSlice.flatten.collectSegments",()=>eh(e,t.headNodeId).map(m=>{const h=Re(e,m);return{isTerminal:m===t.terminalNodeId,name:Fi(e.snapshot.segmentTable,h.nameId),nodeId:m,path:Et(e,m)}})):void 0;return{depth:t.visibleDepth,flattenedSegments:f,hasChildren:l,id:t.terminalNodeId,isExpanded:Me(n)&&Mn(e,t.terminalNodeId,n),isFlattened:c,isLoading:r==="loading",kind:Me(n)?"directory":"file",loadState:r==null||r==="loaded"?void 0:r,name:s,path:i}}function rR(e,t){if(t.headNodeId===t.terminalNodeId)return su(e,t.terminalNodeId);const n=eh(e,t.headNodeId);let r=!1,i=!1;for(const s of n){const l=su(e,s);if(l==="loading")return"loading";if(l==="error"){i=!0;continue}l==="unloaded"&&(r=!0)}return i?"error":r?"unloaded":"loaded"}function iR(e){const{directories:t,nodes:n,options:r,rootId:i,presortedDirectoryNodeIds:s}=e.snapshot,l=r.flattenEmptyDirectories===!0,c=y=>{const w=n[y];if(w==null||!Me(w))return;const _=t.get(y);if(_==null)throw new Error(`Unknown directory child index for node ${String(y)}`);const C=_.childIds,I=C.length;let E=0,S=0;for(let A=0;A<I;A++){const R=C[A];if(R==null)continue;const U=n[R];E+=U.subtreeNodeCount,S+=U.visibleSubtreeCount}_.totalChildSubtreeNodeCount=E,_.totalChildVisibleSubtreeCount=S,I>=EA&&ru(n,_),w.subtreeNodeCount=1+E;let L;if(l&&I===1){const A=n[C[0]];L=A!=null&&Me(A)?S:1+S}else L=1+S;w.visibleSubtreeCount=L};if(s!=null)for(let y=s.length-1;y>=0;y--)c(s[y]);else for(let y=n.length-1;y>=1;y--)c(y);const d=n[i],f=t.get(i);if(d==null||f==null)return;const m=f.childIds;let h=0,g=0;for(let y=0;y<m.length;y++){const w=m[y];if(w==null)continue;const _=n[w];h+=_.subtreeNodeCount,g+=_.visibleSubtreeCount}f.totalChildSubtreeNodeCount=h,f.totalChildVisibleSubtreeCount=g,ru(n,f),d.subtreeNodeCount=1+h,d.visibleSubtreeCount=g}function oR(e){return e.initialExpansion==="open"&&(e.initialExpandedPaths==null||e.initialExpandedPaths.length===0)}var Z,pl,xk=(pl=class{constructor(t={}){ye(this,Z);var c;const n=$0(t),r=De(n,"store.builder.create",()=>new rk(t));if(t.preparedInput!=null){const d=GA(t.preparedInput);d!=null?r.appendPresortedPaths(d,qA(t.preparedInput)):r.appendPreparedPaths(WA(t.preparedInput),!1)}else{const d=t.paths??[];t.presorted===!0?r.appendPaths(d):r.appendPreparedPaths(De(n,"store.preparePathEntries",()=>V0(d,t)))}const i=De(n,"store.builder.finish",()=>r.finish({skipSubtreeCountPass:!0})),s=De(n,"store.state.detectAllDirectoriesExpanded",()=>(t.initialExpansion??"closed")==="closed"&&r.didMatchAllInitialExpandedPaths());Y(this,Z,De(n,"store.state.create",()=>KA(i,s?"open":t.initialExpansion??"closed",n))),s&&(x(this,Z).collapseNewDirectoriesByDefault=!0);const l=s?x(this,Z).snapshot.directories.size-1:De(n,"store.state.initializeExpandedPaths",()=>this.initializeExpandedPaths(t.initialExpandedPaths));s||oR(t)||(t.initialExpansion??"closed")==="closed"&&l===x(this,Z).snapshot.directories.size-1||(((c=t.initialExpandedPaths)==null?void 0:c.length)??0)>0&&De(n,"store.state.checkAllDirectoriesExpanded",()=>this.hasAllDirectoriesExpanded())?De(n,"store.state.initializeOpenVisibleCounts",()=>iR(x(this,Z))):De(n,"store.state.recomputeCounts",()=>U0(x(this,Z),x(this,Z).snapshot.rootId))}static preparePaths(t,n={}){return UA(t,n)}static prepareInput(t,n={}){return zA(t,n)}static preparePresortedInput(t){return HA(t)}list(t){return De(x(this,Z).instrumentation,"store.list",()=>sk(x(this,Z),t))}add(t){De(x(this,Z).instrumentation,"store.add",()=>{const n=_n(x(this,Z));Qr(x(this,Z),qn(x(this,Z),n,Iw(x(this,Z),t)))})}remove(t,n={}){De(x(this,Z).instrumentation,"store.remove",()=>{const r=_n(x(this,Z));Qr(x(this,Z),qn(x(this,Z),r,Pw(x(this,Z),t,n)))})}move(t,n,r={}){De(x(this,Z).instrumentation,"store.move",()=>{const i=_n(x(this,Z)),s=Lw(x(this,Z),t,n,r);s!=null&&Qr(x(this,Z),qn(x(this,Z),i,s))})}batch(t){mT(x(this,Z),()=>{if(typeof t=="function"){t(this);return}for(const n of t)switch(n.type){case"add":this.add(n.path);break;case"remove":this.remove(n.path,{recursive:n.recursive});break;case"move":this.move(n.from,n.to,{collision:n.collision});break}})}getVisibleCount(){return De(x(this,Z).instrumentation,"store.getVisibleCount",()=>_n(x(this,Z)))}getVisibleSlice(t,n){return De(x(this,Z).instrumentation,"store.getVisibleSlice",()=>XT(x(this,Z),t,n))}getVisibleRowContext(t){return De(x(this,Z).instrumentation,"store.getVisibleRowContext",()=>KT(x(this,Z),t))}getVisibleTreeProjection(){return QT(x(this,Z))}getVisibleTreeProjectionData(t){return yk(x(this,Z),t)}getVisibleIndex(t){return De(x(this,Z).instrumentation,"store.getVisibleIndex",()=>YT(x(this,Z),t))}getPathInfo(t){return De(x(this,Z).instrumentation,"store.getPathInfo",()=>{const n=Nr(x(this,Z),t);if(n==null)return null;const r=Re(x(this,Z),n);return{depth:Ti(r),kind:Me(r)?"directory":"file",path:Et(x(this,Z),n)}})}isExpanded(t){return De(x(this,Z).instrumentation,"store.isExpanded",()=>{const n=this.requireDirectoryNodeId(t),r=Re(x(this,Z),n);return Mn(x(this,Z),n,r)})}expand(t){De(x(this,Z).instrumentation,"store.expand",()=>{const n=_n(x(this,Z)),r=JT(x(this,Z),t);r!=null&&Qr(x(this,Z),qn(x(this,Z),n,r))})}collapse(t){De(x(this,Z).instrumentation,"store.collapse",()=>{const n=_n(x(this,Z)),r=ZT(x(this,Z),t);r!=null&&Qr(x(this,Z),qn(x(this,Z),n,r))})}on(t,n){return rT(x(this,Z),t,n)}getDirectoryLoadState(t){const n=this.requireDirectoryNodeId(t);return su(x(this,Z),n)}markDirectoryUnloaded(t){De(x(this,Z).instrumentation,"store.markDirectoryUnloaded",()=>{const n=this.requireDirectoryNodeId(t);if(It(x(this,Z),n).childIds.length>0)throw new Error(`Cannot mark a directory with known children as unloaded: "${t}"`);const r=_n(x(this,Z));JA(x(this,Z),n),Qr(x(this,Z),qn(x(this,Z),r,cT({affectedAncestorIds:ri(x(this,Z),n),affectedNodeIds:[n],path:t,projectionChanged:this.isDirectoryProjectionVisible(n)})))})}beginChildLoad(t){return De(x(this,Z).instrumentation,"store.beginChildLoad",()=>{const n=this.requireDirectoryNodeId(t),r=_n(x(this,Z)),i=YA(x(this,Z),n);return Qr(x(this,Z),qn(x(this,Z),r,uT({affectedAncestorIds:ri(x(this,Z),n),affectedNodeIds:[n],attemptId:i.attemptId,path:t,projectionChanged:this.isDirectoryProjectionVisible(n),reused:i.reused}))),i})}applyChildPatch(t,n){return De(x(this,Z).instrumentation,"store.applyChildPatch",()=>{const r=this.resolveActiveDirectoryNodeId(t.nodeId);if(r==null||su(x(this,Z),r)!=="loading"||!eT(x(this,Z),r,t.attemptId))return!1;const i=Et(x(this,Z),r);this.validateChildPatch(i,n);const s=_n(x(this,Z)),l=[];for(const d of n.operations){sR(i,d);const f=_n(x(this,Z));switch(d.type){case"add":l.push(qn(x(this,Z),f,Iw(x(this,Z),d.path)));break;case"remove":l.push(qn(x(this,Z),f,Pw(x(this,Z),d.path,{recursive:d.recursive})));break;case"move":{const m=Lw(x(this,Z),d.from,d.to,{collision:d.collision});m!=null&&l.push(qn(x(this,Z),f,m));break}}}const c=l.some(d=>d.projectionChanged)||this.isDirectoryProjectionVisible(r);return Qr(x(this,Z),qn(x(this,Z),s,dT({affectedAncestorIds:ri(x(this,Z),r),affectedNodeIds:[r],attemptId:t.attemptId,childEvents:l,path:Et(x(this,Z),r),projectionChanged:c}))),!0})}completeChildLoad(t){return De(x(this,Z).instrumentation,"store.completeChildLoad",()=>{const n=this.resolveActiveDirectoryNodeId(t.nodeId);if(n==null)return!1;const r=_n(x(this,Z)),i=ZA(x(this,Z),n,t.attemptId);return Qr(x(this,Z),qn(x(this,Z),r,fT({affectedAncestorIds:ri(x(this,Z),n),affectedNodeIds:[n],attemptId:t.attemptId,path:Et(x(this,Z),n),projectionChanged:this.isDirectoryProjectionVisible(n),stale:!i}))),i})}failChildLoad(t,n){return De(x(this,Z).instrumentation,"store.failChildLoad",()=>{const r=this.resolveActiveDirectoryNodeId(t.nodeId);if(r==null)return!1;const i=_n(x(this,Z)),s=tT(x(this,Z),r,t.attemptId,n);return Qr(x(this,Z),qn(x(this,Z),i,hT({affectedAncestorIds:ri(x(this,Z),r),affectedNodeIds:[r],attemptId:t.attemptId,errorMessage:n,path:Et(x(this,Z),r),projectionChanged:this.isDirectoryProjectionVisible(r),stale:!s}))),s})}cleanup(t={}){return De(x(this,Z).instrumentation,"store.cleanup",()=>{if(x(this,Z).transactionStack.length>0)throw new Error("Cleanup cannot run during an open batch or transaction.");if(UT(x(this,Z)))throw new Error("Cleanup cannot run while directory loads are active.");const n=_n(x(this,Z)),r=zT(x(this,Z),t.mode??"stable");return Qr(x(this,Z),qn(x(this,Z),n,pT({...r,affectedAncestorIds:[],affectedNodeIds:[],projectionChanged:r.idsPreserved===!1}))),r})}getNodeCount(){return x(this,Z).activeNodeCount}initializeExpandedPaths(t){if(t==null||t.length===0)return 0;let n=0;const r=[],i=[];let s=0,l=null;const c=x(this,Z).snapshot.segmentTable,d=c.valueById,f=x(this,Z).snapshot.nodes,m=new Map;for(const h of t){l!=null&&h<l&&(l=null,s=0,r.length=0,i.length=0);const g=h.length>0&&h.charCodeAt(h.length-1)===47?h.length-1:h.length;if(g===0){l=h,s=g,r.length=0,i.length=0;continue}let y=0,w=0;if(l!=null){const S=Math.min(g,s);let L=!0;for(let A=0;A<S;A+=1){const R=h.charCodeAt(A);if(R!==l.charCodeAt(A)){L=!1;break}R===47&&(y+=1,w=A+1)}L&&(S===s&&g>S&&h.charCodeAt(S)===47?(y+=1,w=S+1):S===g&&s>S&&l.charCodeAt(S)===47&&(y+=1,w=g+1)),y=Math.min(y,i.length)}let _=y===0?x(this,Z).snapshot.rootId:i[y-1]??x(this,Z).snapshot.rootId,C=y,I=!0,E=w;for(;E<=g;){const S=h.indexOf("/",E),L=S===-1||S>g?g:S,A=h.slice(E,L),R=It(x(this,Z),_).childIds,U=C===y?r[C]??0:0;let X=U,H;const re=m.get(A)??Au(A);m.set(A,re);const de=(te,Q)=>{for(X=te;X<Q;X+=1){const ee=R[X],K=f[ee],oe=d[K.nameId];if(oe===A)return H=ee,!0;const ie=B0(Pg(c,K.nameId),re);if(ie>0||ie===0&&oe>A)return!1}return!1};if(!de(U,R.length)&&U>0&&de(0,U),H===void 0){I=!1;break}if(!Me(Re(x(this,Z),H))){I=!1;break}if(r[C]=X,i[C]=H,_=H,C+=1,L===g)break;E=L+1}if(l=h,s=g,r.length=C,i.length=C,!I){l=null,s=0,r.length=0,i.length=0;continue}for(let S=y;S<C;S+=1){const L=i[S];if(L==null)continue;const A=Re(x(this,Z),L);Mn(x(this,Z),L,A)||(ou(x(this,Z),L,!0,A),n+=1)}}return n}hasAllDirectoriesExpanded(){for(const t of x(this,Z).snapshot.directories.keys()){if(t===x(this,Z).snapshot.rootId)continue;const n=Re(x(this,Z),t);if(!Mn(x(this,Z),t,n))return!1}return!0}requireDirectoryNodeId(t){const n=Nr(x(this,Z),t);if(n==null)throw new Error(`Path does not exist: "${t}"`);if(!Me(Re(x(this,Z),n)))throw new Error(`Path is not a directory: "${t}"`);return n}resolveActiveDirectoryNodeId(t){try{if(!Me(Re(x(this,Z),t)))throw new Error(`Node is not a directory: ${String(t)}`);return t}catch{return null}}isDirectoryProjectionVisible(t){let n=t;for(;n!==x(this,Z).snapshot.rootId;){const r=Re(x(this,Z),n).parentId;if(r!==x(this,Z).snapshot.rootId){const i=Re(x(this,Z),r),s=jl(x(this,Z),r);if(!Mn(x(this,Z),r,i)&&s!==n)return!1}n=r}return!0}validateChildPatch(t,n){new pl({paths:this.list(t),presorted:!0,sort:x(this,Z).snapshot.options.sort}).batch(n.operations)}},Z=new WeakMap,pl);function sR(e,t){switch(t.type){case"add":case"remove":if(!t.path.startsWith(e)||t.path===e)throw new Error(`Child patch operation must stay within ${e}: "${t.path}"`);break;case"move":if(!t.from.startsWith(e)||!t.to.startsWith(e)||t.from===e||t.to===e)throw new Error(`Child patch move must stay within ${e}: "${t.from}" -> "${t.to}"`);break}}const aR=e=>e.startsWith(fw)?e.slice(fw.length):e;function lR(e){const t=e.lastIndexOf("/");return t<0?{parentPath:"",baseName:e}:{parentPath:e.slice(0,t),baseName:e.slice(t+1)}}function cR(e,t){return e===""?t:`${e}/${t}`}function uR({files:e,path:t,isFolder:n,nextBasename:r}){const i=aR(t),s=r.trim();if(s.length===0)return{error:"Name cannot be empty."};if(s.includes("/"))return{error:'Name cannot include "/".'};const{parentPath:l,baseName:c}=lR(i);if(s===c)return{nextFiles:e,sourcePath:i,destinationPath:i,isFolder:n};const d=cR(l,s),f=new Array(e.length),m=new Set;if(!n){const w=`${d}/`;let _=!1;for(let C=0;C<e.length;C++){const I=e[C];if(I!==i&&I.startsWith(w))return{error:`"${d}" already exists.`};const E=I===i?d:I;if(m.has(E))return{error:`"${d}" already exists.`};m.add(E),f[C]=E,I===i&&(_=!0)}return _?{nextFiles:f,sourcePath:i,destinationPath:d,isFolder:n}:{error:"Could not find the selected file to rename."}}const h=`${i}/`,g=`${d}/`;let y=0;for(let w=0;w<e.length;w++){const _=e[w],C=_===i||_.startsWith(h);if(!C&&(_===d||_.startsWith(g)))return{error:`"${d}" already exists.`};const I=C?`${d}${_.slice(i.length)}`:_;if(m.has(I))return{error:`"${d}" already exists.`};m.add(I),f[w]=I,C&&y++}return y===0?{error:"Could not find the selected folder to rename."}:{nextFiles:f,sourcePath:i,destinationPath:d,isFolder:n}}function dR(e){return e.endsWith("/")}function fR(e){const t=e.endsWith("/")?e.slice(0,-1):e,n=t.lastIndexOf("/"),r=n<0?t:t.slice(n+1);return e.endsWith("/")?`${r}/`:r}function hR(e){const t=[],n=new Set;for(const i of e)n.has(i)||(n.add(i),t.push(i));const r=new Set;for(const i of t.toSorted((s,l)=>s.length!==l.length?s.length-l.length:s.localeCompare(l))){const s=(i.endsWith("/")?i.slice(0,-1):i).split("/");let l=!1;for(let c=0;c<s.length-1;c+=1){const d=`${s.slice(0,c+1).join("/")}/`;if(r.has(d)){l=!0;break}}l||r.add(i)}return t.filter(i=>r.has(i))}function pR(e,t){return t.includes(e)?hR(t):[e]}function mR(e,t){return e===t?!0:e==null||t==null?!1:e.kind===t.kind&&e.directoryPath===t.directoryPath&&e.flattenedSegmentPath===t.flattenedSegmentPath&&e.hoveredPath===t.hoveredPath}function $w(e,t){return{draggedPaths:e,target:t}}function Bw(e,t){if(t.kind!=="directory"||t.directoryPath==null)return!1;for(const n of e)if(dR(n)&&(t.directoryPath===n||t.directoryPath.startsWith(n)))return!0;return!1}function gR(e,t){return t.kind==="root"||t.directoryPath==null?fR(e):t.directoryPath}function vR(e,t){const n=e.map(r=>{const i=gR(r,t);return i===r?null:{from:r,to:i,type:"move"}}).filter(r=>r!=null);return n.length===0?null:{operations:n,result:{draggedPaths:e,operation:n.length===1?"move":"batch",target:t}}}const _k=Symbol("FILE_TREE_RENAME_VIEW");function jw(e){return e.operation==="add"||e.operation==="remove"||e.operation==="move"||e.operation==="batch"}const yR=512,wR=512;function Om(e,t){if(e.size!==t.length)return!1;for(const n of t)if(!e.has(n))return!1;return!0}function Yo(e){const t=e.endsWith("/")?e.slice(0,-1):e;if(t.length===0)return[];const n=t.split("/");return n.slice(0,-1).map((r,i)=>`${n.slice(0,i+1).join("/")}/`)}function $m(e){return Yo(e).at(-1)??null}function Vw(e,t){return t==null?e:e.startsWith(t)?e.slice(t.length):e}const bR=e=>{const t=e.trim();return t.length===0?"":(t.includes("\\")?t.replaceAll("\\","/"):t).toLowerCase()},Uw=e=>e.toLowerCase();function nf(e){return e.endsWith("/")}function xR(e){const t=e.endsWith("/")?e.slice(0,-1):e,n=t.lastIndexOf("/");return n<0?t:t.slice(n+1)}function zw(e){return e.endsWith("/")?e.slice(0,-1):e}function Hw(e,t){return t&&!e.endsWith("/")?`${e}/`:e}function _R(e,t,n){if(e===t)return n;const r=t.endsWith("/")?t:`${t}/`;return e.startsWith(r)?`${n.endsWith("/")?n:`${n}/`}${e.slice(r.length)}`:e}function kR(e,t){if(e===t)return!0;const n=t.endsWith("/")?t:`${t}/`;return e.startsWith(n)}function Mc(e,t,n=!1){if(e==null)return null;switch(t.operation){case"add":case"expand":case"collapse":case"mark-directory-unloaded":case"begin-child-load":case"apply-child-patch":case"complete-child-load":case"fail-child-load":case"cleanup":return e;case"remove":return kR(e,t.path)?n?e:null:e;case"move":return _R(e,t.from,t.to);case"batch":{let r=e;for(const i of t.events)if(r=Mc(r,i,n),r==null)return null;return r}}}function wf(e){return{canonicalChanged:e.canonicalChanged,projectionChanged:e.projectionChanged,visibleCountDelta:e.visibleCountDelta}}function SR(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let n=0;n<e.length;n+=1)if(e[n]!==t[n])return!1;return!0}function Ww(e,t,n){const{paths:r,preparedInput:i}=e;if(i==null){if(r==null)throw new Error("FileTree requires paths or preparedInput");return{paths:r,preparedInput:void 0}}const s=i.paths;if(r==null)return{paths:s,preparedInput:i};if(!SR(xk.preparePaths(r,n==null?{}:{sort:n}),s))throw new Error(`FileTree ${t} received paths and preparedInput for different path lists`);return{paths:s,preparedInput:i}}function kk(e){switch(e.operation){case"add":return{...wf(e),operation:"add",path:e.path};case"remove":return{...wf(e),operation:"remove",path:e.path,recursive:e.recursive};case"move":return{...wf(e),from:e.from,operation:"move",to:e.to}}}function CR(e){return{...wf(e),events:e.events.filter(t=>t.operation==="add"||t.operation==="remove"||t.operation==="move").map(t=>kk(t)),operation:"batch"}}function ER(e){switch(e.operation){case"add":case"remove":case"move":return kk(e);case"batch":return CR(e);default:return null}}function IR(e,t,n){if(e===0)return-1;if(n!=null){const r=t(n);if(r!=null)return r;const i=Yo(n);for(let s=i.length-1;s>=0;s-=1){const l=i[s];if(l==null)continue;const c=t(l);if(c!=null)return c}}return 0}function PR(e,t,n){if(e.paths.length===0)return{focusedIndex:-1,getParentIndex:e.getParentIndex,paths:e.paths,posInSetByIndex:e.posInSetByIndex,setSizeByIndex:e.setSizeByIndex};if(t==null)return{focusedIndex:0,getParentIndex:e.getParentIndex,paths:e.paths,posInSetByIndex:e.posInSetByIndex,setSizeByIndex:e.setSizeByIndex};const r=n??(i=>e.visibleIndexByPath.get(i)??null);return{focusedIndex:IR(e.paths.length,r,t),getParentIndex:e.getParentIndex,paths:e.paths,posInSetByIndex:e.posInSetByIndex,setSizeByIndex:e.setSizeByIndex}}var ml,Zs,Ii,Lr,dn,gl,vl,ur,at,so,du,ts,ns,rs,is,os,ss,fu,hu,yl,dr,pu,mu,gu,vu,tn,Kn,Pi,ao,wl,ea,ta,Vt,na,bl,Zr,xl,Fn,vt,as,ze,yu,_l,fn,ls,$,Sk,Ck,Ek,Ik,Gs,Ng,bf,Fg,Mg,Og,$g,Bg,Pr,Pk,Lk,Dk,xf,_f,Ak,Tk,Oc,Rk,kf,Nk,jg,Vg,Fk,Yr,Ug,$c,zg,nl,Hg,un,Wg,Gg,qg,Qo,Kg,no,rl,ro,io,Mk,Xg,Ok,$b,LR=($b=class{constructor(e){ye(this,$);ye(this,ml);ye(this,Zs,new Set);ye(this,Ii,new Map);ye(this,Lr,null);ye(this,dn,null);ye(this,gl,new Map);ye(this,vl,new Map);ye(this,ur,-1);ye(this,at,null);ye(this,so,!1);ye(this,du,e=>-1);ye(this,ts,new Map);ye(this,ns,null);ye(this,rs,null);ye(this,is,null);ye(this,os,null);ye(this,ss,null);ye(this,fu);ye(this,hu);ye(this,yl);ye(this,dr,[]);ye(this,pu,new Int32Array(0));ye(this,mu,new Int32Array(0));ye(this,gu);ye(this,vu,!1);ye(this,tn,null);ye(this,Kn,"");ye(this,Pi,!1);ye(this,ao,new Set);ye(this,wl,[]);ye(this,ea);ye(this,ta,null);ye(this,Vt,null);ye(this,na,null);ye(this,bl,null);ye(this,Zr,null);ye(this,xl,null);ye(this,Fn,null);ye(this,vt,new Set);ye(this,as,0);ye(this,ze);ye(this,yu,0);ye(this,_l,!1);ye(this,fn,0);ye(this,ls);const{dragAndDrop:t,fileTreeSearchMode:n,initialSearchQuery:r,initialSelectedPaths:i,renaming:s,onSearchChange:l,paths:c,preparedInput:d,...f}=e,m=Ww({paths:c,preparedInput:d},"constructor",f.sort);Y(this,ml,f),t!=null&&t!==!1&&Y(this,Lr,t===!0?{}:t),Y(this,vu,s!=null&&s!==!1),s!=null&&s!==!1&&s!==!0&&(Y(this,gu,s.canRename),Y(this,hu,s.onError),Y(this,fu,s.onRename)),Y(this,yl,l),Y(this,ea,n??"hide-non-matches"),Y(this,ze,V(this,$,xf).call(this,m.paths,m.preparedInput));const h=(i==null?void 0:i.map(y=>V(this,$,no).call(this,y)).filter(y=>y!=null))??[],g=h.at(-1)??null;h.length>0&&(Y(this,vt,new Set(h)),Y(this,Fn,g),Y(this,as,1)),V(this,$,Qo).call(this,g,!1),r!=null&&V(this,$,nl).call(this,r,!1),Y(this,ls,V(this,$,Xg).call(this))}destroy(){var e;(e=x(this,ls))==null||e.call(this),Y(this,ls,null),x(this,Ii).clear(),x(this,Zs).clear(),x(this,ts).clear(),Y(this,dn,null),V(this,$,kf).call(this)}focusFirstItem(){V(this,$,Yr).call(this).length>0&&V(this,$,ro).call(this,0)}focusLastItem(){x(this,fn)<=0||(V(this,$,io).call(this),V(this,$,ro).call(this,x(this,fn)-1))}focusNextItem(){V(this,$,qg).call(this,1)}focusParentItem(){if(x(this,at)==null)return;const e=$m(x(this,at));if(e==null)return;const t=V(this,$,Gs).call(this,e);t>=0&&V(this,$,ro).call(this,t)}focusPath(e){var r;const t=((r=x(this,ze).getPathInfo(e))==null?void 0:r.path)??null;if(t==null)return;V(this,$,io).call(this);const n=V(this,$,Gs).call(this,t);n>=0&&V(this,$,ro).call(this,n)}focusNearestPath(e){const t=this.resolveNearestVisiblePath(e);if(t==null)return null;const n=V(this,$,Gs).call(this,t);return n>=0?(V(this,$,ro).call(this,n),V(this,$,Yr).call(this)[n]??t):null}focusPreviousItem(){V(this,$,qg).call(this,-1)}getFocusedIndex(){return x(this,ur)}getFocusedItem(){return x(this,at)==null?null:V(this,$,Ng).call(this,x(this,at))}getFocusedPath(){return x(this,at)}resolveNearestVisiblePath(e){var s;const t=V(this,$,Yr).call(this);if(x(this,fn)===0)return null;if(e==null)return x(this,at)??t[0]??null;const n=((s=x(this,ze).getPathInfo(e))==null?void 0:s.path)??e,r=V(this,$,Gs).call(this,n);if(r>=0)return t[r]??n;const i=V(this,$,Ik).call(this,n);return i??x(this,at)??t[0]??null}getSelectedPaths(){return[...x(this,vt)]}getSelectionVersion(){return x(this,as)}getVisibleCount(){return x(this,fn)}getVisibleRows(e,t){if(t<e||x(this,fn)===0)return[];const n=Math.max(0,e),r=Math.min(x(this,fn)-1,t);if(r<n)return[];const i=r-n+1;if(x(this,Zr)==null&&!x(this,so)&&r>=x(this,dr).length&&i<=wR){const s=[];for(let l=n;l<=r;l+=1){const c=x(this,ze).getVisibleRowContext(l);if(c==null)break;s.push(V(this,$,Fg).call(this,c))}return s}if(!x(this,so)&&r>=x(this,dr).length&&V(this,$,io).call(this),x(this,Zr)!=null){const s=Array.from({length:r-n+1},(f,m)=>V(this,$,Ug).call(this,n+m)),l=new Map;let c=s[0]??-1,d=c;for(let f=1;f<=s.length;f+=1){const m=s[f];if(m!=null&&m===d+1){d=m;continue}if(c>=0&&x(this,ze).getVisibleSlice(c,d).forEach((h,g)=>{l.set(c+g,h)}),m==null){c=-1,d=-1;continue}c=m,d=m}return Array.from({length:r-n+1},(f,m)=>{const h=n+m,g=V(this,$,Ug).call(this,h),y=l.get(g),w=x(this,dr)[g];if(y==null||w==null)throw new Error(`Missing projection row for filtered visible index ${String(h)}`);return V(this,$,bf).call(this,y,h,g,{ancestorPaths:V(this,$,$g).call(this,g),path:w})})}return x(this,ze).getVisibleSlice(n,r).map((s,l)=>{const c=n+l,d=x(this,dr)[c];if(d==null)throw new Error(`Missing projection path for visible index ${String(c)}`);return V(this,$,bf).call(this,s,c,c,{ancestorPaths:V(this,$,$g).call(this,c),path:d})})}getStickyRowCandidates(e,t){if(x(this,Zr)!=null)return null;if(x(this,fn)===0||e<=0||t<=0)return[];const n=[];for(let r=0;r<x(this,fn);r+=1){const i=e+r*t,s=Math.min(x(this,fn)-1,Math.floor(i/t)),l=V(this,$,Mg).call(this,s,r)??(s>0?V(this,$,Mg).call(this,s-1,r):void 0);if(l==null)break;n.push({row:V(this,$,Fg).call(this,l),subtreeEndIndex:l.subtreeEndIndex})}return n}getItem(e){const t=x(this,ze).getPathInfo(e);return t==null?null:V(this,$,Ng).call(this,t.path,t)}selectAllVisiblePaths(){V(this,$,io).call(this);const e=[...V(this,$,Yr).call(this)];V(this,$,Pr).call(this,e,x(this,at)??x(this,Fn))}selectOnlyPath(e){const t=V(this,$,no).call(this,e);t!=null&&V(this,$,Pr).call(this,[t],t)}selectPath(e){const t=V(this,$,no).call(this,e);t==null||x(this,vt).has(t)||V(this,$,Pr).call(this,[...x(this,vt),t])}deselectPath(e){const t=V(this,$,no).call(this,e);t==null||!x(this,vt).has(t)||V(this,$,Pr).call(this,[...x(this,vt)].filter(n=>n!==t))}toggleFocusedSelection(){x(this,at)!=null&&this.togglePathSelectionFromInput(x(this,at))}togglePathSelection(e){const t=V(this,$,no).call(this,e);if(t!=null){if(x(this,vt).has(t)){this.deselectPath(t);return}this.selectPath(t)}}togglePathSelectionFromInput(e){const t=V(this,$,no).call(this,e);if(t!=null){if(x(this,vt).has(t)){V(this,$,Pr).call(this,[...x(this,vt)].filter(n=>n!==t),t);return}V(this,$,Pr).call(this,[...x(this,vt),t],t)}}selectPathRange(e,t){const n=V(this,$,no).call(this,e);if(n==null)return;V(this,$,io).call(this);const r=x(this,Fn),i=r==null?-1:V(this,$,$c).call(this,r),s=V(this,$,$c).call(this,n);if(i===-1||s===-1){const m=t?[...x(this,vt),n]:[n];V(this,$,Pr).call(this,m,n);return}const[l,c]=i<=s?[i,s]:[s,i],d=V(this,$,Yr).call(this).slice(l,c+1),f=t?[...x(this,vt),...d]:d;V(this,$,Pr).call(this,f,r)}extendSelectionFromFocused(e){if(x(this,at)==null)return;const t=x(this,ur);if(t===-1)return;const n=Math.min(x(this,fn)-1,Math.max(0,t+e));if(n===t)return;!x(this,so)&&n>=x(this,dr).length&&V(this,$,io).call(this);const r=V(this,$,Yr).call(this),i=r[t]??null,s=r[n]??null;if(i==null||s==null)return;const l=new Set(x(this,vt));l.has(i)&&l.has(s)?l.delete(i):l.add(s),V(this,$,Pr).call(this,[...l],x(this,Fn)??i,!1),V(this,$,ro).call(this,n)}getDragAndDropConfig(){return x(this,Lr)}isDragAndDropEnabled(){return x(this,Lr)!=null}getDragSession(){return x(this,dn)==null?null:{draggedPaths:[...x(this,dn).draggedPaths],primaryPath:x(this,dn).primaryPath,target:x(this,dn).target==null?null:{...x(this,dn).target}}}startDrag(e){var i,s;if(x(this,Lr)==null)return!1;const t=V(this,$,no).call(this,e);if(t==null||x(this,Vt)!=null&&x(this,Vt).length>0)return!1;const n=this.getSelectedPaths(),r=pR(t,n);return((s=(i=x(this,Lr)).canDrag)==null?void 0:s.call(i,r))===!1?!1:(n.includes(t)||V(this,$,Pr).call(this,[t],t,!1),V(this,$,rl).call(this,t),Y(this,dn,{draggedPaths:r,primaryPath:t,target:null}),V(this,$,un).call(this),!0)}setDragTarget(e){var r,i;const t=x(this,dn);if(t==null)return;let n=e;if(n!=null){const s=$w(t.draggedPaths,n);(Bw(t.draggedPaths,n)||((i=(r=x(this,Lr))==null?void 0:r.canDrop)==null?void 0:i.call(r,s))===!1)&&(n=null)}mR(t.target,n)||(Y(this,dn,{...t,target:n}),V(this,$,un).call(this))}cancelDrag(){x(this,dn)!=null&&(Y(this,dn,null),V(this,$,un).call(this))}completeDrag(){var i,s,l,c,d,f;const e=x(this,dn);if(e==null)return!1;Y(this,dn,null);const t=e.target==null?null:{...e.target};if(t==null)return V(this,$,un).call(this),!1;const n=$w(e.draggedPaths,t);if(Bw(e.draggedPaths,t)||((s=(i=x(this,Lr))==null?void 0:i.canDrop)==null?void 0:s.call(i,n))===!1)return V(this,$,un).call(this),!1;const r=vR(e.draggedPaths,t);if(r==null)return V(this,$,un).call(this),!1;try{if(r.operations.length===1){const m=r.operations[0];if(m==null||m.type!=="move")throw new Error("Expected a single move operation for one-item drops");x(this,ze).move(m.from,m.to,{collision:m.collision})}else V(this,$,Dk).call(this,r.operations),x(this,ze).batch(r.operations)}catch(m){return V(this,$,un).call(this),(c=(l=x(this,Lr))==null?void 0:l.onDropError)==null||c.call(l,m instanceof Error?m.message:String(m),n),!1}return(f=(d=x(this,Lr))==null?void 0:d.onDropComplete)==null||f.call(d,r.result),!0}subscribe(e){return x(this,Zs).add(e),e(),()=>{x(this,Zs).delete(e)}}add(e){x(this,ze).add(e)}remove(e,t={}){x(this,ze).remove(e,t)}move(e,t,n={}){x(this,ze).move(e,t,n)}batch(e){x(this,ze).batch(e)}onMutation(e,t){const n=e,r=t;let i=x(this,Ii).get(n);return i==null&&(i=new Set,x(this,Ii).set(n,i)),i.add(r),()=>{const s=x(this,Ii).get(n);s==null||s.delete(r),(s==null?void 0:s.size)===0&&x(this,Ii).delete(n)}}setSearch(e){V(this,$,nl).call(this,e,!0)}openSearch(e=""){V(this,$,nl).call(this,e,!0)}closeSearch(){V(this,$,nl).call(this,null,!0)}isSearchOpen(){return x(this,Vt)!==null}getSearchValue(){return x(this,Vt)??""}getSearchMatchingPaths(){return x(this,wl)}focusNextSearchMatch(){V(this,$,zg).call(this,1)}focusPreviousSearchMatch(){V(this,$,zg).call(this,-1)}startRenaming(e=x(this,at)??"",t={}){var l,c;if(!x(this,vu))return!1;const n=x(this,ze).getPathInfo(e);if(n==null)return!1;const r=n.path,i=nf(r),s=zw(r);if(((l=x(this,gu))==null?void 0:l.call(this,{isFolder:i,path:s}))===!1)return!1;for(const d of Yo(r))x(this,ze).isExpanded(d)||x(this,ze).expand(d);return V(this,$,Pr).call(this,[r],r,!1),x(this,Vt)!=null&&(V(this,$,nl).call(this,null,!1),(c=x(this,yl))==null||c.call(this,x(this,Vt))),V(this,$,rl).call(this,r),Y(this,tn,r),Y(this,Kn,xR(r)),Y(this,Pi,t.removeIfCanceled??!1),V(this,$,un).call(this),!0}[_k](){return{cancel:()=>{V(this,$,Sk).call(this)},commit:()=>{V(this,$,Ck).call(this)},getPath:()=>x(this,tn),getValue:()=>x(this,Kn),isActive:()=>x(this,tn)!=null,setValue:e=>{V(this,$,Ek).call(this,e)}}}resetPaths(e,t={}){var g,y,w;const n=x(this,ze).list().length,r=x(this,fn),i=Ww({paths:e,preparedInput:t.preparedInput},"resetPaths",x(this,ml).sort),s=V(this,$,xf).call(this,i.paths,i.preparedInput,t.initialExpandedPaths),l=x(this,at),c=x(this,tn),d=this.getSelectedPaths(),f=x(this,Fn);(g=x(this,ls))==null||g.call(this),Y(this,ze,s),x(this,ts).clear(),V(this,$,kf).call(this);const m=d.map(_=>{var C;return((C=s.getPathInfo(_))==null?void 0:C.path)??null}).filter(_=>_!=null),h=!Om(x(this,vt),m);Y(this,vt,new Set(m)),h&&Y(this,as,x(this,as)+1),Y(this,Fn,f==null?null:((y=s.getPathInfo(f))==null?void 0:y.path)??null),Y(this,tn,c==null?null:((w=s.getPathInfo(c))==null?void 0:w.path)??null),x(this,tn)==null&&(Y(this,Kn,""),Y(this,Pi,!1)),V(this,$,Qo).call(this,l,l!=null||m.length>0||x(this,Fn)!=null),Y(this,ls,V(this,$,Xg).call(this)),V(this,$,un).call(this),V(this,$,Wg).call(this,{canonicalChanged:!0,operation:"reset",pathCountAfter:i.paths.length,pathCountBefore:n,projectionChanged:!0,usedPreparedInput:t.preparedInput!=null,visibleCountDelta:x(this,fn)-r})}},ml=new WeakMap,Zs=new WeakMap,Ii=new WeakMap,Lr=new WeakMap,dn=new WeakMap,gl=new WeakMap,vl=new WeakMap,ur=new WeakMap,at=new WeakMap,so=new WeakMap,du=new WeakMap,ts=new WeakMap,ns=new WeakMap,rs=new WeakMap,is=new WeakMap,os=new WeakMap,ss=new WeakMap,fu=new WeakMap,hu=new WeakMap,yl=new WeakMap,dr=new WeakMap,pu=new WeakMap,mu=new WeakMap,gu=new WeakMap,vu=new WeakMap,tn=new WeakMap,Kn=new WeakMap,Pi=new WeakMap,ao=new WeakMap,wl=new WeakMap,ea=new WeakMap,ta=new WeakMap,Vt=new WeakMap,na=new WeakMap,bl=new WeakMap,Zr=new WeakMap,xl=new WeakMap,Fn=new WeakMap,vt=new WeakMap,as=new WeakMap,ze=new WeakMap,yu=new WeakMap,_l=new WeakMap,fn=new WeakMap,ls=new WeakMap,$=new WeakSet,Sk=function(){if(x(this,tn)==null)return;const e=x(this,tn),t=x(this,Pi);if(Y(this,tn,null),Y(this,Kn,""),Y(this,Pi,!1),t){this.remove(e,nf(e)?{recursive:!0}:void 0);return}V(this,$,rl).call(this,e),V(this,$,un).call(this)},Ck=function(){var r,i;const e=x(this,tn);if(e==null)return;if(x(this,Pi)&&x(this,Kn).trim().length===0){Y(this,tn,null),Y(this,Kn,""),Y(this,Pi,!1),this.remove(e,nf(e)?{recursive:!0}:void 0);return}const t=nf(e),n=uR({files:x(this,ze).list(),isFolder:t,nextBasename:x(this,Kn),path:zw(e)});if(Y(this,tn,null),Y(this,Kn,""),Y(this,Pi,!1),"error"in n){V(this,$,rl).call(this,e),(r=x(this,hu))==null||r.call(this,n.error),V(this,$,un).call(this);return}if(n.sourcePath===n.destinationPath){V(this,$,rl).call(this,e),V(this,$,un).call(this);return}(i=x(this,fu))==null||i.call(this,{destinationPath:n.destinationPath,isFolder:n.isFolder,sourcePath:n.sourcePath}),this.move(Hw(n.sourcePath,t),Hw(n.destinationPath,t))},Ek=function(e){x(this,tn)==null||x(this,Kn)===e||(Y(this,Kn,e),V(this,$,un).call(this))},Ik=function(e){V(this,$,io).call(this);const t=$m(e),n=Vw(e,t);let r=null,i=null;for(const s of V(this,$,Yr).call(this)){if($m(s)!==t)continue;const l=Vw(s,t);if(l<n){r=s;continue}if(l>n){i=s;break}}return r??i},Gs=function(e){const t=V(this,$,$c).call(this,e);if(t!==-1)return t;const n=Yo(e);for(let r=n.length-1;r>=0;r-=1){const i=n[r];if(i==null)continue;const s=V(this,$,$c).call(this,i);if(s!==-1)return s}return V(this,$,Yr).call(this).length>0?0:-1},Ng=function(e,t){const n=x(this,ts).get(e);if(n!=null)return n;const r=t??x(this,ze).getPathInfo(e);if(r==null)return null;const i=r.kind==="directory"?V(this,$,Pk).call(this,r.path):V(this,$,Lk).call(this,r.path);return x(this,ts).set(r.path,i),i},bf=function(e,t,n,r){var i;return{ancestorPaths:r.ancestorPaths,depth:e.depth,flattenedSegments:(i=e.flattenedSegments)==null?void 0:i.map(s=>({isTerminal:s.isTerminal,name:s.name,path:s.path})),hasChildren:e.hasChildren,index:t,isExpanded:e.isExpanded,isFlattened:e.isFlattened,isFocused:r.path===x(this,at),isSelected:x(this,vt).has(r.path),kind:e.kind,level:e.depth,name:e.name,path:r.path,posInSet:r.posInSet??x(this,pu)[n]??0,setSize:r.setSize??x(this,mu)[n]??0}},Fg=function(e){return V(this,$,bf).call(this,e.row,e.index,e.index,{ancestorPaths:e.ancestorPaths,path:e.row.path,posInSet:e.posInSet,setSize:e.setSize})},Mg=function(e,t){const n=x(this,ze).getVisibleRowContext(e);if(n==null)return;const r=n.ancestorRows[t];return r??(t===n.ancestorRows.length&&n.row.kind==="directory"&&n.row.isExpanded?n:void 0)},Og=function(e){const t=x(this,gl).get(e);if(t!=null)return t;const n=x(this,du).call(this,e),r=n<0?[]:[...V(this,$,Og).call(this,n),n];return x(this,gl).set(e,r),r},$g=function(e){const t=x(this,vl).get(e);if(t!=null)return t;const n=V(this,$,Og).call(this,e).map(r=>x(this,dr)[r]??"").filter(r=>r!=="");return x(this,vl).set(e,n),n},Bg=function(e){x(this,ze).collapse(e)},Pr=function(e,t=x(this,Fn),n=!0){const r=[...new Set(e)],i=!Om(x(this,vt),r),s=x(this,Fn)!==t;!i&&!s||(Y(this,vt,new Set(r)),Y(this,Fn,t),i&&Y(this,as,x(this,as)+1),n&&V(this,$,un).call(this))},Pk=function(e){return{collapse:()=>{V(this,$,Bg).call(this,e)},deselect:()=>{this.deselectPath(e)},expand:()=>{V(this,$,Gg).call(this,e)},focus:()=>{this.focusPath(e)},getPath:()=>e,isDirectory:()=>!0,isExpanded:()=>x(this,ze).isExpanded(e),isFocused:()=>x(this,at)===e,isSelected:()=>x(this,vt).has(e),select:()=>{this.selectPath(e)},toggleSelect:()=>{this.togglePathSelection(e)},toggle:()=>{V(this,$,Ok).call(this,e)}}},Lk=function(e){return{deselect:()=>{this.deselectPath(e)},focus:()=>{this.focusPath(e)},getPath:()=>e,isDirectory:()=>!1,isFocused:()=>x(this,at)===e,isSelected:()=>x(this,vt).has(e),select:()=>{this.selectPath(e)},toggleSelect:()=>{this.togglePathSelection(e)}}},Dk=function(e){const t=x(this,ze).list();V(this,$,xf).call(this,t).batch(e)},xf=function(e,t,n){return new xk({...x(this,ml),paths:e,preparedInput:t??void 0,...n!==void 0?{initialExpandedPaths:n}:{}})},_f=function(){return x(this,os)!=null?x(this,os):(Y(this,os,x(this,ze).list()),x(this,os))},Ak=function(){if(x(this,is)!=null)return x(this,is);const e=new Set;for(const t of V(this,$,_f).call(this)){e.add(t);for(const n of Yo(t))e.add(n)}return Y(this,is,[...e].sort()),x(this,is)},Tk=function(){return x(this,ss)!=null?x(this,ss):(Y(this,ss,V(this,$,_f).call(this).map(Uw)),x(this,ss))},Oc=function(){return x(this,ns)!=null?x(this,ns):(Y(this,ns,V(this,$,Ak).call(this).filter(e=>e.endsWith("/"))),x(this,ns))},Rk=function(){return x(this,rs)!=null?x(this,rs):(Y(this,rs,V(this,$,Oc).call(this).map(Uw)),x(this,rs))},kf=function(){Y(this,ns,null),Y(this,rs,null),Y(this,is,null),Y(this,os,null),Y(this,ss,null)},Nk=function(){return V(this,$,Oc).call(this).filter(e=>x(this,ze).isExpanded(e))},jg=function(e){const t=new Set(x(this,ta)??[]);if(e)for(const n of x(this,vt))for(const r of Yo(n))t.add(r);V(this,$,Vg).call(this,t)},Vg=function(e){Y(this,_l,!0);try{for(const t of V(this,$,Oc).call(this)){const n=e.has(t),r=x(this,ze).isExpanded(t);n&&!r?x(this,ze).expand(t):!n&&r&&x(this,ze).collapse(t)}}finally{Y(this,_l,!1)}},Fk=function(){var i;const e=x(this,dr);if(Y(this,wl,e.filter(s=>x(this,ao).has(s))),x(this,Vt)==null||x(this,Vt).length===0||x(this,ea)!=="hide-non-matches"||x(this,ao).size===0){Y(this,Zr,null),Y(this,xl,null),Y(this,bl,null),Y(this,fn,x(this,yu));return}const t=[],n=[],r=new Map;for(const[s,l]of e.entries())((i=x(this,na))==null?void 0:i.has(l))===!0&&(r.set(l,n.length),t.push(s),n.push(l));Y(this,Zr,t),Y(this,xl,n),Y(this,bl,r),Y(this,fn,n.length)},Yr=function(){return x(this,xl)??x(this,dr)},Ug=function(e){var t;return((t=x(this,Zr))==null?void 0:t[e])??e},$c=function(e){var n;const t=(n=x(this,bl))==null?void 0:n.get(e);return t??x(this,ze).getVisibleIndex(e)??-1},zg=function(e){const t=x(this,wl);if(t.length===0)return;const n=x(this,at),r=n==null?-1:t.indexOf(n),i=t[r<0?e>0?0:t.length-1:Math.min(t.length-1,Math.max(0,r+e))];i!=null&&this.focusPath(i)},nl=function(e,t){var i;const n=e==null?null:bR(e),r=x(this,Vt);if(r!==n){if(r==null&&n!=null&&Y(this,ta,V(this,$,Nk).call(this)),Y(this,Vt,n),n==null)V(this,$,jg).call(this,!0),Y(this,ta,null),x(this,ao).clear(),Y(this,na,null),V(this,$,Qo).call(this,x(this,at),!0);else if(n.length===0)V(this,$,jg).call(this,!1),x(this,ao).clear(),Y(this,na,null),V(this,$,Qo).call(this,x(this,at),!0);else{const s=V(this,$,Hg).call(this);V(this,$,Qo).call(this,s,!0)}t&&((i=x(this,yl))==null||i.call(this,x(this,Vt)),V(this,$,un).call(this))}},Hg=function(){if(x(this,Vt)==null||x(this,Vt).length===0)return x(this,ao).clear(),x(this,at);const e=x(this,Vt),t=V(this,$,_f).call(this),n=V(this,$,Tk).call(this),r=[],i=new Set;let s=null;for(let m=0;m<t.length;m+=1){if(!n[m].includes(e))continue;const h=t[m];r.push(h),i.add(h),s??(s=h)}const l=V(this,$,Oc).call(this),c=V(this,$,Rk).call(this);for(let m=0;m<l.length;m+=1){if(!c[m].includes(e))continue;const h=l[m];i.has(h)||(r.push(h),i.add(h),s??(s=h))}Y(this,ao,i);const d=x(this,ea)==="hide-non-matches"&&r.length>0?new Set:null;Y(this,na,d);const f=x(this,ea)==="expand-matches"?new Set(x(this,ta)??[]):new Set;for(const m of r){d!=null&&d.add(m),m.endsWith("/")&&f.add(m);for(const h of Yo(m))f.add(h),d!=null&&d.add(h)}return V(this,$,Vg).call(this,f),s??x(this,at)},un=function(){for(const e of x(this,Zs))e()},Wg=function(e){var t,n;(t=x(this,Ii).get(e.operation))==null||t.forEach(r=>{r(e)}),(n=x(this,Ii).get("*"))==null||n.forEach(r=>{r(e)})},Gg=function(e){for(const t of Yo(e))x(this,ze).isExpanded(t)||x(this,ze).expand(t);x(this,ze).isExpanded(e)||x(this,ze).expand(e)},qg=function(e){const t=x(this,fn);if(t===0)return;const n=x(this,ur)===-1?0:x(this,ur),r=Math.min(t-1,Math.max(0,n+e));(r!==n||x(this,ur)===-1)&&(!x(this,so)&&x(this,Zr)==null&&r>=x(this,dr).length&&V(this,$,io).call(this),V(this,$,ro).call(this,r))},Qo=function(e,t=!0){const n=x(this,ze).getVisibleCount();Y(this,yu,n);const r=PR(x(this,ze).getVisibleTreeProjectionData(t?void 0:Math.min(n,yR)),e,t?i=>x(this,ze).getVisibleIndex(i):void 0);x(this,gl).clear(),x(this,vl).clear(),Y(this,so,r.paths.length>=n),Y(this,du,r.getParentIndex),Y(this,dr,r.paths),Y(this,pu,r.posInSetByIndex),Y(this,mu,r.setSizeByIndex),V(this,$,Fk).call(this),Y(this,ur,e==null?V(this,$,Yr).call(this).length>0?0:-1:V(this,$,Gs).call(this,e)),Y(this,at,x(this,ur)<0?null:V(this,$,Kg).call(this,x(this,ur)))},Kg=function(e){var n;const t=V(this,$,Yr).call(this)[e];return t??(x(this,Zr)!=null?null:((n=x(this,ze).getVisibleRowContext(e))==null?void 0:n.row.path)??null)},no=function(e){var t;return((t=x(this,ze).getPathInfo(e))==null?void 0:t.path)??null},rl=function(e){if(e==null)return;const t=V(this,$,Gs).call(this,e);t>=0&&V(this,$,ro).call(this,t,!1)},ro=function(e,t=!0){const n=V(this,$,Kg).call(this,e);n!=null&&(x(this,ur)===e&&x(this,at)===n||(Y(this,ur,e),Y(this,at,n),t&&V(this,$,un).call(this)))},io=function(){x(this,so)||V(this,$,Qo).call(this,x(this,at),!0)},Mk=function(e){var c;const t=Mc(x(this,tn),e);t==null&&x(this,tn)!=null&&Y(this,Kn,""),Y(this,tn,t);const n=Mc(x(this,at),e,!0),r=[...x(this,vt)].map(d=>Mc(d,e)).filter(d=>d!=null).map(d=>{var f;return((f=x(this,ze).getPathInfo(d))==null?void 0:f.path)??null}).filter(d=>d!=null),i=Mc(x(this,Fn),e),s=i==null?null:((c=x(this,ze).getPathInfo(i))==null?void 0:c.path)??null,l=[...new Set(r)];return Om(x(this,vt),l)||(Y(this,vt,new Set(l)),Y(this,as,x(this,as)+1)),Y(this,Fn,s),n},Xg=function(){return x(this,ze).on("*",e=>{if(x(this,_l))return;e.canonicalChanged&&(x(this,ts).clear(),V(this,$,kf).call(this)),x(this,dn)!=null&&jw(e)&&Y(this,dn,null);const t=jw(e)?V(this,$,Mk).call(this,e):x(this,at),n=x(this,Vt)!=null&&x(this,Vt).length>0?V(this,$,Hg).call(this):x(this,Vt)===""?x(this,at):t,r=x(this,Vt)!=null||e.operation!=="expand"&&e.operation!=="collapse";V(this,$,Qo).call(this,n,r),V(this,$,un).call(this);const i=ER(e);i!=null&&V(this,$,Wg).call(this,i)})},Ok=function(e){if(x(this,ze).isExpanded(e)){V(this,$,Bg).call(this,e);return}V(this,$,Gg).call(this,e)},$b);const DR=e=>{if(e==null||e.length===0)return"0";let t=`${e.length}`;for(const n of e)t+=`\0${n.path}\0${n.status}`;return t};function AR(e){const t=e.endsWith("/");let n="",r=-1;for(let i=0;i<=e.length;i+=1){if(!(e[i]==="/"||i===e.length)){r===-1&&(r=i);continue}r!==-1&&(n!==""&&(n+="/"),n+=e.slice(r,i),r=-1)}return n===""?null:{isDirectory:t,path:n}}function TR(e){const t=e.endsWith("/")?e.slice(0,-1):e;if(t.length===0)return[];const n=t.split("/");return n.slice(0,-1).map((r,i)=>`${n.slice(0,i+1).join("/")}/`)}function RR(e,t){return t?`${e}/`:e}function Gw(e,t=null){const n=DR(e==null?void 0:[...e]);if(n==="0")return null;if((t==null?void 0:t.signature)===n)return t;const r=new Map,i=new Set,s=new Set;for(const l of e??[]){const c=AR(l.path);if(c==null)continue;const d=RR(c.path,c.isDirectory);r.set(d,l.status),l.status==="ignored"&&c.isDirectory?s.add(d):c.isDirectory&&s.delete(d);for(const f of TR(c.path))i.add(f)}return{directoriesWithChanges:i,ignoredDirectoryPaths:s,signature:n,statusByPath:r}}const NR=e=>e.trim().toLowerCase(),FR=e=>e.split("/").at(-1)??e,MR=e=>{const t=e.toLowerCase().split("."),n=[];for(let r=1;r<t.length;r+=1)n.push(t.slice(r).join("."));return n};function rf(e,t){return typeof e=="string"?{name:e,remappedFrom:t}:{...e,remappedFrom:t}}function OR(e){const t=vf(e),n=t.remap,r=new Map;for(const[c,d]of Object.entries(t.byFileName??{}))r.set(c.toLowerCase(),d);const i=new Map;for(const[c,d]of Object.entries(t.byFileExtension??{}))i.set(NR(c),d);const s=Object.entries(t.byFileNameContains??{}).map(([c,d])=>[c.toLowerCase(),d]);return{resolveIcon:(c,d)=>{if(c==="file-tree-icon-file"&&d!=null){const m=FR(d),h=m.toLowerCase(),g=r.get(h);if(g!=null)return rf(g,c);for(const[_,C]of s)if(h.includes(_))return rf(C,c);const y=MR(m);for(const _ of y){const C=i.get(_);if(C!=null)return rf(C,c)}const w=gA(t.set,m,y);if(w!=null&&t.set!=="none")return{name:pA(w),remappedFrom:c,token:w}}const f=n==null?void 0:n[c];return f==null?{name:c}:rf(f,c)}}}var yt,$k,Ks,qw,nh,Bk,jk,G0,Qg,Yg,lu={},Vk=[],bh=Array.isArray,q0=Vk.slice,hs=Object.assign;function K0(e){e&&e.parentNode&&e.remove()}function Jg(e,t,n){var r,i,s,l={};for(s in t)s=="key"?r=t[s]:s=="ref"&&typeof e!="function"?i=t[s]:l[s]=t[s];return arguments.length>2&&(l.children=arguments.length>3?q0.call(arguments,2):n),Sf(e,l,r,i,null)}function Sf(e,t,n,r,i){var s={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:i??++$k,__i:-1,__u:0};return i==null&&yt.vnode!=null&&yt.vnode(s),s}function Vl(e){return e.children}function Cf(e,t){this.props=e,this.context=t,this.__g=0}function Tl(e,t){if(t==null)return e.__?Tl(e.__,e.__i+1):null;for(var n;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null)return n.__e;return typeof e.type=="function"?Tl(e):null}function Uk(e){var t,n;if((e=e.__)!=null&&e.__c!=null){for(e.__e=null,t=0;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null){e.__e=n.__e;break}return Uk(e)}}function Kw(e){(8&e.__g||!(e.__g|=8)||!Ks.push(e)||nh++)&&qw==yt.debounceRendering||((qw=yt.debounceRendering)||queueMicrotask)($R)}function $R(){for(var e,t,n,r,i,s,l,c,d=1;Ks.length;)Ks.length>d&&Ks.sort(Bk),e=Ks.shift(),d=Ks.length,8&e.__g&&(n=void 0,i=(r=(t=e).__v).__e,s=[],l=[],(c=t.__P)&&((n=hs({},r)).__v=r.__v+1,yt.vnode&&yt.vnode(n),X0(c,n,r,t.__n,c.namespaceURI,32&r.__u?[i]:null,s,i??Tl(r),!!(32&r.__u),l,c.ownerDocument),n.__v=r.__v,n.__.__k[n.__i]=n,Wk(s,n,l),n.__e!=i&&Uk(n)));nh=0}function zk(e,t,n,r,i,s,l,c,d,f,m,h){var g,y,w,_,C,I,E,S=r&&r.__k||Vk,L=t.length;for(d=BR(n,t,S,d,L),g=0;g<L;g++)(w=n.__k[g])!=null&&(y=w.__i==-1?lu:S[w.__i]||lu,w.__i=g,I=X0(e,w,y,i,s,l,c,d,f,m,h),_=w.__e,w.ref&&y.ref!=w.ref&&(y.ref&&Q0(y.ref,null,w),m.push(w.ref,w.__c||_,w)),C==null&&_!=null&&(C=_),(E=!!(4&w.__u))||y.__k===w.__k?d=Hk(w,d,e,E):typeof w.type=="function"&&I!==void 0?d=I:_&&(d=_.nextSibling),w.__u&=-7);return n.__e=C,d}function BR(e,t,n,r,i){var s,l,c,d,f,m=n.length,h=m,g=0;for(e.__k=new Array(i),s=0;s<i;s++)(l=t[s])!=null&&typeof l!="boolean"&&typeof l!="function"?(d=s+g,(l=e.__k[s]=typeof l=="string"||typeof l=="number"||typeof l=="bigint"||l.constructor==String?Sf(null,l,null,null,null):bh(l)?Sf(Vl,{children:l},null,null,null):l.constructor==null&&l.__b>0?Sf(l.type,l.props,l.key,l.ref?l.ref:null,l.__v):l).__=e,l.__b=e.__b+1,c=null,(f=l.__i=jR(l,n,d,h))!=-1&&(h--,(c=n[f])&&(c.__u|=2)),c==null||c.__v==null?(f==-1&&(i>m?g--:i<m&&g++),typeof l.type!="function"&&(l.__u|=4)):f!=d&&(f==d-1?g--:f==d+1?g++:(f>d?g--:g++,l.__u|=4))):e.__k[s]=null;if(h)for(s=0;s<m;s++)(c=n[s])!=null&&(2&c.__u)==0&&(c.__e==r&&(r=Tl(c)),qk(c,c));return r}function Hk(e,t,n,r){var i,s;if(typeof e.type=="function"){for(i=e.__k,s=0;i&&s<i.length;s++)i[s]&&(i[s].__=e,t=Hk(i[s],t,n,r));return t}e.__e!=t&&(r&&(t&&e.type&&!t.parentNode&&(t=Tl(e)),n.insertBefore(e.__e,t||null)),t=e.__e);do t=t&&t.nextSibling;while(t!=null&&t.nodeType==8);return t}function jR(e,t,n,r){var i,s,l,c=e.key,d=e.type,f=t[n],m=f!=null&&(2&f.__u)==0;if(f===null&&e.key==null||m&&c==f.key&&d==f.type)return n;if(r>(m?1:0)){for(i=n-1,s=n+1;i>=0||s<t.length;)if((f=t[l=i>=0?i--:s++])!=null&&(2&f.__u)==0&&c==f.key&&d==f.type)return l}return-1}function Xw(e,t,n){t[0]=="-"?e.setProperty(t,n??""):e[t]=n??""}function of(e,t,n,r,i){var s;e:if(t=="style")if(typeof n=="string")e.style.cssText=n;else{if(typeof r=="string"&&(e.style.cssText=r=""),r)for(t in r)n&&t in n||Xw(e.style,t,"");if(n)for(t in n)r&&n[t]==r[t]||Xw(e.style,t,n[t])}else if(t[0]=="o"&&t[1]=="n")s=t!=(t=t.replace(jk,"$1")),(t=t.slice(2))[0].toLowerCase()!=t[0]&&(t=t.toLowerCase()),e.__l||(e.__l={}),e.__l[t+s]=n,n?r?n.l=r.l:(n.l=G0,e.addEventListener(t,s?Yg:Qg,s)):e.removeEventListener(t,s?Yg:Qg,s);else{if(i=="http://www.w3.org/2000/svg")t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(t!="width"&&t!="height"&&t!="href"&&t!="list"&&t!="form"&&t!="tabIndex"&&t!="download"&&t!="rowSpan"&&t!="colSpan"&&t!="role"&&t!="popover"&&t in e)try{e[t]=n??"";break e}catch{}typeof n=="function"||(n==null||n===!1&&t[4]!="-"?e.removeAttribute(t):e.setAttribute(t,t=="popover"&&n==1?"":n))}}function Qw(e){return function(t){if(this.__l){var n=this.__l[t.type+e];if(t.u==null)t.u=G0++;else if(t.u<n.l)return;return n(yt.event?yt.event(t):t)}}}function X0(e,t,n,r,i,s,l,c,d,f,m){var h,g,y,w,_,C,I,E,S,L,A,R,U,X,H,re,de,te,Q,ee,K,oe=t.type;if(t.constructor!=null)return null;128&n.__u&&(d=!!(32&n.__u),n.__c.__z&&(c=t.__e=n.__e=(s=n.__c.__z)[0],n.__c.__z=null)),(h=yt.__b)&&h(t);e:if(typeof oe=="function")try{if(E=t.props,S="prototype"in oe&&oe.prototype.render,L=(h=oe.contextType)&&r[h.__c],A=h?L?L.props.value:h.__:r,n.__c?2&(g=t.__c=n.__c).__g&&(g.__g|=1,I=!0):(S?t.__c=g=new oe(E,A):(t.__c=g=new Cf(E,A),g.constructor=oe,g.render=UR),L&&L.sub(g),g.props=E,g.state||(g.state={}),g.context=A,g.__n=r,y=!0,g.__g|=8,g.__h=[],g._sb=[]),S&&g.__s==null&&(g.__s=g.state),S&&oe.getDerivedStateFromProps!=null&&(g.__s==g.state&&(g.__s=hs({},g.__s)),hs(g.__s,oe.getDerivedStateFromProps(E,g.__s))),w=g.props,_=g.state,g.__v=t,y)S&&oe.getDerivedStateFromProps==null&&g.componentWillMount!=null&&g.componentWillMount(),S&&g.componentDidMount!=null&&g.__h.push(g.componentDidMount);else{if(S&&oe.getDerivedStateFromProps==null&&E!==w&&g.componentWillReceiveProps!=null&&g.componentWillReceiveProps(E,A),!(4&g.__g)&&g.shouldComponentUpdate!=null&&g.shouldComponentUpdate(E,g.__s,A)===!1||t.__v==n.__v){for(t.__v!=n.__v&&(g.props=E,g.state=g.__s,g.__g&=-9),t.__e=n.__e,t.__k=n.__k,t.__k.some(function(ie){ie&&(ie.__=t)}),R=0;R<g._sb.length;R++)g.__h.push(g._sb[R]);g._sb=[],g.__h.length&&l.push(g);break e}g.componentWillUpdate!=null&&g.componentWillUpdate(E,g.__s,A),S&&g.componentDidUpdate!=null&&g.__h.push(function(){g.componentDidUpdate(w,_,C)})}if(g.context=A,g.props=E,g.__P=e,g.__g&=-5,U=yt.__r,X=0,S){for(g.state=g.__s,g.__g&=-9,U&&U(t),h=g.render(g.props,g.state,g.context),H=0;H<g._sb.length;H++)g.__h.push(g._sb[H]);g._sb=[]}else do g.__g&=-9,U&&U(t),h=g.render(g.props,g.state,g.context),g.state=g.__s;while(8&g.__g&&++X<25);g.state=g.__s,g.getChildContext!=null&&(r=hs({},r,g.getChildContext())),S&&!y&&g.getSnapshotBeforeUpdate!=null&&(C=g.getSnapshotBeforeUpdate(w,_)),re=h,h!=null&&h.type===Vl&&h.key==null&&(re=Gk(h.props.children)),c=zk(e,bh(re)?re:[re],t,n,r,i,s,l,c,d,f,m),t.__u&=-161,g.__h.length&&l.push(g),I&&(g.__g&=-4)}catch(ie){if(t.__v=null,d||s!=null)if(ie.then){for(de=0,te=!1,t.__u|=d?160:128,t.__c.__z=[],Q=0;Q<s.length;Q++)(ee=s[Q])==null||te||(ee.nodeType==8&&ee.data=="$s"?(de>0&&t.__c.__z.push(ee),de++,s[Q]=null):ee.nodeType==8&&ee.data=="/$s"?(--de>0&&t.__c.__z.push(ee),te=de===0,c=s[Q],s[Q]=null):de>0&&(t.__c.__z.push(ee),s[Q]=null));if(!te){for(;c&&c.nodeType==8&&c.nextSibling;)c=c.nextSibling;s[s.indexOf(c)]=null,t.__c.__z=[c]}t.__e=c}else{for(K=s.length;K--;)K0(s[K]);Zg(t)}else t.__e=n.__e,t.__k=n.__k,ie.then||Zg(t);yt.__e(ie,t,n)}else c=t.__e=VR(n.__e,t,n,r,i,s,l,d,f,m);return(h=yt.diffed)&&h(t),128&t.__u?void 0:c}function Zg(e){e&&e.__c&&(e.__c.__g|=4),e&&e.__k&&e.__k.forEach(Zg)}function Wk(e,t,n){for(var r=0;r<n.length;r++)Q0(n[r],n[++r],n[++r]);yt.__c&&yt.__c(t,e),e.some(function(i){try{e=i.__h,i.__h=[],e.some(function(s){s.call(i)})}catch(s){yt.__e(s,i.__v)}})}function Gk(e){return typeof e!="object"||e==null||e.__b&&e.__b>0?e:bh(e)?e.map(Gk):hs({},e)}function VR(e,t,n,r,i,s,l,c,d,f){var m,h,g,y,w,_,C,I,E=n.props,S=t.props,L=t.type;if(L=="svg"?i="http://www.w3.org/2000/svg":L=="math"?i="http://www.w3.org/1998/Math/MathML":i||(i="http://www.w3.org/1999/xhtml"),s!=null){for(m=0;m<s.length;m++)if((w=s[m])&&"setAttribute"in w==!!L&&(L?w.localName==L:w.nodeType==3)){e=w,s[m]=null;break}}if(e==null){if(L==null)return f.createTextNode(S);e=f.createElementNS(i,L,S.is&&S),c&&(yt.__m&&yt.__m(t,s),c=!1),s=null}if(L==null)E===S||c&&e.data==S||(e.data=S);else{if(s=s&&q0.call(e.childNodes),E=n.props||lu,!c&&s!=null)for(E={},m=0;m<e.attributes.length;m++)E[(w=e.attributes[m]).name]=w.value;for(m in E)if(w=E[m],m!="children"){if(m=="dangerouslySetInnerHTML")g=w;else if(!(m in S)){if(m=="value"&&"defaultValue"in S||m=="checked"&&"defaultChecked"in S)continue;of(e,m,null,w,i)}}for(m in I=1&n.__u,S)w=S[m],m=="children"?y=w:m=="dangerouslySetInnerHTML"?h=w:m=="value"?_=w:m=="checked"?C=w:c&&typeof w!="function"||E[m]===w&&!I||of(e,m,w,E[m],i);if(h)c||g&&(h.__html==g.__html||h.__html==e.innerHTML)||(e.innerHTML=h.__html),t.__k=[];else if(g&&(e.innerHTML=""),zk(L=="template"?e.content:e,bh(y)?y:[y],t,n,r,L=="foreignObject"?"http://www.w3.org/1999/xhtml":i,s,l,s?s[0]:n.__k&&Tl(n,0),c,d,f),s!=null)for(m=s.length;m--;)K0(s[m]);c||(m="value",L=="progress"&&_==null?e.removeAttribute("value"):_==null||_===e[m]&&(L!=="progress"||_)||of(e,m,_,E[m],i),m="checked",C!=null&&C!=e[m]&&of(e,m,C,E[m],i))}return e}function Q0(e,t,n){try{if(typeof e=="function"){var r=typeof e.__u=="function";r&&e.__u(),r&&t==null||(e.__u=e(t))}else e.current=t}catch(i){yt.__e(i,n)}}function qk(e,t,n){var r,i;if(yt.unmount&&yt.unmount(e),(r=e.ref)&&(r.current&&r.current!=e.__e||Q0(r,null,t)),(r=e.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(s){yt.__e(s,t)}r.__P=null}if(r=e.__k)for(i=0;i<r.length;i++)r[i]&&qk(r[i],t,n||typeof e.type!="function");n||K0(e.__e),e.__e&&e.__e.__l&&(e.__e.__l=null),e.__e=e.__c=e.__=null}function UR(e,t,n){return this.constructor(e,n)}function e0(e,t){var n,r,i,s;t==document&&(t=document.documentElement),yt.__&&yt.__(e,t),r=(n=!!(e&&32&e.__u))?null:t.__k,e=t.__k=Jg(Vl,null,[e]),i=[],s=[],X0(t,e,r||lu,lu,t.namespaceURI,r?null:t.firstChild?q0.call(t.childNodes):null,i,r?r.__e:t.firstChild,n,s,t.ownerDocument),Wk(i,e,s)}function zR(e,t){e.__u|=32,e0(e,t)}yt={__e:function(e,t,n,r){for(var i,s,l;t=t.__;)if((i=t.__c)&&!(1&i.__g)){i.__g|=4;try{if((s=i.constructor)&&s.getDerivedStateFromError!=null&&(i.setState(s.getDerivedStateFromError(e)),l=8&i.__g),i.componentDidCatch!=null&&(i.componentDidCatch(e,r||{}),l=8&i.__g),l)return void(i.__g|=2)}catch(c){e=c}}throw nh=0,e}},$k=0,Cf.prototype.setState=function(e,t){var n;n=this.__s!=null&&this.__s!=this.state?this.__s:this.__s=hs({},this.state),typeof e=="function"&&(e=e(hs({},n),this.props)),e&&hs(n,e),e!=null&&this.__v&&(t&&this._sb.push(t),Kw(this))},Cf.prototype.forceUpdate=function(e){this.__v&&(this.__g|=4,e&&this.__h.push(e),Kw(this))},Cf.prototype.render=Vl,Ks=[],nh=0,Bk=function(e,t){return e.__v.__b-t.__v.__b},jk=/(PointerCapture)$|Capture$/i,G0=0,Qg=Qw(!1),Yg=Qw(!0);var HR=0;function Ce(e,t,n,r,i,s){t||(t={});var l,c,d=t;if("ref"in d&&typeof e!="function")for(c in d={},t)c=="ref"?l=t[c]:d[c]=t[c];var f={type:e,props:d,key:n,ref:l,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:--HR,__i:-1,__u:0,__source:i,__self:s};return yt.vnode&&yt.vnode(f),f}const WR=16,GR=16,qR={};function Gc({name:e,remappedFrom:t,token:n,width:r,height:i,viewBox:s,label:l,alignCapitals:c=!1}){"use no memo";const d=`#${e.replace(/^#/,"")}`,{width:f,height:m,viewBox:h}=qR[e]??{width:WR,height:GR},g=r??f,y=i??m,w=s??h??`0 0 ${f} ${m}`,_=l!=null?{"aria-label":l,role:"img"}:{"aria-hidden":!0};return Ce("svg",{"data-icon-name":t??e,"data-icon-token":n,"data-align-capitals":c,..._,viewBox:w,width:g,height:y,children:Ce("use",{href:d})})}const Yw=e=>{if(e.length<2)return[e,""];const t=Math.ceil(e.length/2);return[e.slice(0,t),e.slice(t)]},KR=e=>{if(e.length<4)return[e,""];const t=e.lastIndexOf(".")+1,n=e.length-t>10,r=t>=1&&!n?t:Math.ceil(e.length/2);return[e.slice(0,r),e.slice(r)]},XR=e=>{if(e.length<4)return[e,""];const t=e.lastIndexOf("/")+1,n=e.length-t>25,r=t>=1&&!n?t:Math.ceil(e.length/2);return[e.slice(0,r),e.slice(r)]},QR=(e,{splitIndex:t}={})=>{if(typeof t!="number"){const n=Math.ceil(e.length/2);return[e.slice(0,n),e.slice(n)]}return[e.slice(0,t),e.slice(t)]},YR=(e,{splitOffset:t}={})=>{if(typeof t!="number"||t<=0||t>=e.length){const r=Math.ceil(e.length/2);return[e.slice(0,r),e.slice(r)]}const n=e.length-t;return[e.slice(0,n),e.slice(n)]},JR=(e,{splitOffset:t}={})=>{if(typeof t!="number"||t<=0||t>=e.length){const r=Math.ceil(e.length/2);return[e.slice(0,r),e.slice(r)]}const n=t;return[e.slice(0,n),e.slice(n)]};function ZR({children:e,marker:t,variant:n="default"}){"use no memo";return Ce("div",{"aria-hidden":!0,"data-truncate-marker-cell":!0,children:Ce("div",{"data-truncate-marker":!0,children:typeof t=="function"?t({children:e}):n==="fade"?Ce("span",{"data-truncate-fade":!0}):t})})}function eN(e){"use no memo";const{mode:t,children:n}=e;return Ce("div",{children:[Ce("div",{"data-truncate-content":"visible",children:t==="fruncate"?Ce("span",{children:n}):n}),Ce("div",{"data-truncate-content":"overflow","aria-hidden":!0,children:t==="fruncate"?Ce("span",{children:n}):n})]})}function Kk({children:e,mode:t="truncate",marker:n="…",variant:r="default",...i}){"use no memo";const s=Ce(eN,{mode:t,children:e},"content"),l=Ce(ZR,{marker:n,mode:t,variant:r},"marker");return Ce("div",{"data-truncate-container":t,"data-truncate-variant":r,...i,children:Ce("div",{"data-truncate-grid":!0,children:t==="truncate"?[s,l]:[l,s,Ce("div",{"data-truncate-fill":!0},"fill")]})})}function Ef({children:e,...t}){"use no memo";return Ce(Kk,{mode:"truncate",...t,children:e})}function Bm({children:e,...t}){"use no memo";return Ce(Kk,{mode:"fruncate",...t,children:e})}function tN({children:e,contents:t,priority:n="end",split:r="center",minimumLength:i=12,className:s,style:l,...c}){"use no memo";let d=null,f=null;if(Array.isArray(t)){if(t.length!==2)return console.error("MiddleTruncate: contents must be an array of two items"),null;d=Ce(Ef,{...c,children:t[0]}),f=Ce(Bm,{...c,children:t[1]})}else{if(typeof e!="string")return console.error("MiddleTruncate: children must be a string"),null;if(e.length===0)return Ce("div",{className:s,style:l});if(e.length<i)return n==="end"?Ce(Bm,{...c,className:s,style:l,children:e}):Ce(Ef,{...c,className:s,style:l,children:e});let m=null,h=null,g=null;if(typeof r=="string")r==="center"?m=Yw:r==="extension"?m=KR:r==="leaf-path"&&(m=XR);else if(typeof r=="number")m=QR,h=r;else if(Array.isArray(r)){const[L,A]=r;g=A,L==="last"?m=YR:L==="first"&&(m=JR)}else typeof r=="function"&&(m=r);m??(m=Yw);const[y,w]=m(e,{priority:n,variant:c.variant,splitIndex:typeof h=="number"?h:void 0,splitOffset:typeof g=="number"?g:void 0}),_=y.length>=w.length,C=n==="equal"&&!_,I=n==="equal"&&_,E={},S={};C&&(E.marker=""),I&&(S.marker=""),d=Ce(Ef,{...c,...E,children:y}),f=Ce(Bm,{...c,...S,children:w})}return Ce("div",{"data-truncate-group-container":"middle",className:s,style:l,children:[Ce("div",{"data-truncate-segment-priority":n==="start"||n==="equal"?"1":"2",children:d}),Ce("div",{"data-truncate-segment-priority":n==="end"||n==="equal"?"1":"2",children:f})]})}const t0={endIndex:-1,startIndex:-1};function nN(e,t,n){return Math.min(Math.max(e,t),n)}function Jw(e,t){return e<0||t<e?t0:{endIndex:t,startIndex:e}}function n0(e){return e.startIndex<0||e.endIndex<e.startIndex}function rN(e,t){return n0(e)?0:(e.endIndex-e.startIndex+1)*t}function Zw(e,t,n){if(t<=0)return-1;const r=t*n;return e<=0?0:e>=r?t:Math.floor(e/n)}function iN(e,t,n){return t<=0||e<=0?-1:e>=t*n?t-1:Math.ceil(e/n)-1}function oN(e){const t=new Map;return e.forEach((n,r)=>{if(n.kind!=="directory"||!n.isExpanded)return;const i=n.ancestorPaths.length,s=t.get(i);if(s==null){t.set(i,[r]);return}s.push(r)}),t}function sN(e,t){let n=0,r=e.length-1,i=-1;for(;n<=r;){const s=Math.floor((n+r)/2),l=e[s];if(l==null)break;if(l<=t){i=s,n=s+1;continue}r=s-1}return i}function aN(e){const t=new Map,n=[];for(let i=0;i<e.length;i+=1){const s=e[i];if(s==null)continue;const l=s.kind==="directory"&&s.isExpanded?[...s.ancestorPaths,s.path]:s.ancestorPaths;let c=0;for(;c<n.length&&c<l.length&&n[c]===l[c];)c+=1;for(let d=n.length-1;d>=c;d-=1){const f=n[d];f!=null&&t.set(f,i-1)}n.length=c;for(let d=c;d<l.length;d+=1){const f=l[d];f!=null&&n.push(f)}}const r=e.length-1;for(const i of n)t.set(i,r);return t}function Xk(e,t,n){var l;if(e.length===0||t<=0)return[];const r=aN(e),i=oN(e),s=[];for(let c=0;c<e.length;c+=1){const d=i.get(c);if(d==null||d.length===0)break;const f=t+c*n;let m=sN(d,Math.min(e.length-1,Math.floor(f/n))),h=null;for(;m>=0;){const g=d[m],y=g==null?null:e[g]??null;if(y!=null&&(c===0||y.ancestorPaths[c-1]===((l=s[c-1])==null?void 0:l.path))){h=y;break}m-=1}if(h==null)break;s.push(h)}return s.map((c,d)=>{const f=d*n,m=(r.get(c.path)??e.length-1)+1;if(m>=e.length)return{row:c,top:f};const h=m*n-t;return{row:c,top:Math.min(f,h-n)}}).filter(c=>c.top+n>0)}function lN(e,t){const n=t.totalRowCount??e.length,r=n*t.itemHeight,i=Math.max(0,t.viewportHeight),s=Math.max(0,Math.floor(t.overscan)),l=Math.max(0,r-i),c=nN(t.scrollTop,0,l),d=t.stickyRows??Xk(e,c,t.itemHeight),f=d.reduce((R,U)=>Math.max(R,U.top+t.itemHeight),0),m=Math.min(r,c+f),h=Math.max(0,i-f),g=Math.max(0,r-m),y=Zw(c,n,t.itemHeight),w=Zw(m,n,t.itemHeight),_=f<=0||y<0||y>=n?-1:y,C=_===-1?-1:Math.min(n-1,w-1),I=_===-1||C<_?0:C-_+1,E=h<=0||w>=n?t0:Jw(w,iN(m+h,n,t.itemHeight)),S=C+1,L=n0(E)?t0:Jw(Math.max(S,E.startIndex-s),Math.min(n-1,E.endIndex+s)),A=rN(L,t.itemHeight);return{occlusion:{firstOccludedIndex:_,lastOccludedIndex:C,occludedCount:I},physical:{itemHeight:t.itemHeight,maxScrollTop:l,overscan:s,scrollTop:c,totalHeight:r,totalRowCount:n,viewportHeight:i},projected:{contentHeight:g,paneHeight:h,paneTop:m},sticky:{height:f,rows:d},visible:E,window:{endIndex:L.endIndex,height:A,offsetTop:n0(L)?0:L.startIndex*t.itemHeight,startIndex:L.startIndex}}}const cN={added:"A",deleted:"D",ignored:null,modified:"M",renamed:"R",untracked:"U"},uN={added:"Git status: added",deleted:"Git status: deleted",ignored:"Git status: ignored",modified:"Git status: modified",renamed:"Git status: renamed",untracked:"Git status: untracked"},dN="Contains git status items";function fN(e){const{renamingPath:t,previousRenamingPath:n,hasRenderedInput:r}=e;return t==null?"reset":r?n===t?"ignore":"focus-input":"reveal-canonical"}function hN(e){const{row:t,mode:n,targetPath:r,ariaLabel:i,domId:s,isParked:l,itemHeight:c,features:d,state:f,extraStyle:m}=e,h=n==="sticky",g=t.ancestorPaths.at(-1)??"",y={};return f.isFocusRinged&&(y["data-item-focused"]=!0),t.isSelected&&(y["data-item-selected"]=!0),f.isContextHovered&&(y["data-item-context-hover"]="true"),f.isDragTarget&&(y["data-item-drag-target"]=!0),f.isDragging&&(y["data-item-dragging"]=!0),f.effectiveGitStatus!=null&&(y["data-item-git-status"]=f.effectiveGitStatus),f.containsGitChange&&(y["data-item-contains-git-change"]="true"),{"aria-expanded":!h&&t.kind==="directory"?t.isExpanded:void 0,"aria-haspopup":d.contextMenuEnabled?"menu":void 0,"aria-label":i,"aria-level":h?void 0:t.level+1,"aria-posinset":h?void 0:t.posInSet+1,"aria-selected":h?void 0:t.isSelected?"true":"false","aria-setsize":h?void 0:t.setSize,"data-file-tree-sticky-path":h?r:void 0,"data-file-tree-sticky-row":h?"true":void 0,"data-item-context-menu-button-visibility":d.actionLaneEnabled?d.contextMenuButtonVisibility:void 0,"data-item-context-menu-trigger-mode":d.contextMenuEnabled?d.contextMenuTriggerMode:void 0,"data-item-has-context-menu-action-lane":d.actionLaneEnabled?"true":void 0,"data-item-has-git-lane":d.gitLaneActive?"true":void 0,"data-item-parent-path":g.length>0?g:void 0,"data-item-parked":l?"true":void 0,"data-item-path":r,"data-item-type":t.kind==="directory"?"folder":"file","data-type":"item",id:h?void 0:s,role:h?void 0:"treeitem",style:{minHeight:`${c}px`,...m},tabIndex:!h&&t.isFocused?0:-1,...y}}function pN(e){const{event:t,mode:n,isSearchOpen:r,isDirectory:i}=e,s=t.ctrlKey||t.metaKey,l=t.shiftKey||s,c=t.shiftKey?{additive:s,kind:"range"}:s?{kind:"toggle"}:{kind:"single"};return{closeSearch:r,revealCanonical:n==="sticky",selection:c,toggleDirectory:!l&&i}}function mN(e){const{currentScrollTop:t,focusedIndex:n,itemHeight:r,topInset:i=0,viewportHeight:s}=e;if(n<0)return null;const l=Math.max(0,i),c=n*r,d=c+r;if(c<t+l){const f=Math.max(0,c-l);return f===t?null:f}if(d>t+s){const f=d-s;return f===t?null:f}return null}function gN(e){const{currentScrollTop:t,focusedIndex:n,itemHeight:r,targetViewportOffset:i,totalHeight:s,viewportHeight:l}=e;if(n<0)return null;const c=Math.max(0,i),d=n*r,f=d+r,m=t+c,h=t+l;if(d>=m&&f<=h)return null;const g=Math.max(0,s-l),y=Math.max(0,Math.min(d-c,g));return y===t?null:y}var Rl,Ot,jm,eb,r0=Object.is,cu=0,Qk=[],Ut=yt,tb=Ut.__b,nb=Ut.__r,rb=Ut.diffed,ib=Ut.__c,ob=Ut.unmount,sb=Ut.__;function xh(e,t){Ut.__h&&Ut.__h(Ot,e,cu||t),cu=0;var n=Ot.__H||(Ot.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({}),n.__[e]}function ki(e){return cu=1,vN(Yk,e)}function vN(e,t,n){var r=xh(Rl++,2);if(r.t=e,!r.__c&&(r.__=[Yk(void 0,t),function(c){var d=r.__N?r.__N[0]:r.__[0],f=r.t(d,c);r0(d,f)||(r.__N=[f,r.__[1]],r.__c.setState({}))}],r.__c=Ot,!Ot.__f)){var i=function(c,d,f){if(!r.__c.__H)return!0;var m=r.__c.__H.__.filter(function(g){return!!g.__c});if(m.every(function(g){return!g.__N}))return!s||s.call(this,c,d,f);var h=r.__c.props!==c;return m.forEach(function(g){if(g.__N){var y=g.__[0];g.__=g.__N,g.__N=void 0,r0(y,g.__[0])||(h=!0)}}),s&&s.call(this,c,d,f)||h};Ot.__f=!0;var s=Ot.shouldComponentUpdate,l=Ot.componentWillUpdate;Ot.componentWillUpdate=function(c,d,f){if(4&this.__g){var m=s;s=void 0,i(c,d,f),s=m}l&&l.call(this,c,d,f)},Ot.shouldComponentUpdate=i}return r.__N||r.__}function ab(e,t){var n=xh(Rl++,3);!Ut.__s&&Y0(n.__H,t)&&(n.__=e,n.u=t,Ot.__H.__h.push(n))}function lr(e,t){var n=xh(Rl++,4);!Ut.__s&&Y0(n.__H,t)&&(n.__=e,n.u=t,Ot.__h.push(n))}function qe(e){return cu=5,Jo(function(){return{current:e}},[])}function Jo(e,t){var n=xh(Rl++,7);return Y0(n.__H,t)&&(n.__=e(),n.__H=t,n.__h=e),n.__}function Dn(e,t){return cu=8,Jo(function(){return e},t)}function yN(){for(var e;e=Qk.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(If),e.__H.__h.forEach(i0),e.__H.__h=[]}catch(t){e.__H.__h=[],Ut.__e(t,e.__v)}}Ut.__b=function(e){Ot=null,tb&&tb(e)},Ut.__=function(e,t){e&&t.__k&&t.__k.__m&&(e.__m=t.__k.__m),sb&&sb(e,t)},Ut.__r=function(e){nb&&nb(e),Rl=0;var t=(Ot=e.__c).__H;t&&(jm===Ot?(t.__h=[],Ot.__h=[],t.__.forEach(function(n){n.__N&&(n.__=n.__N),n.u=n.__N=void 0})):(t.__h.forEach(If),t.__h.forEach(i0),t.__h=[],Rl=0)),jm=Ot},Ut.diffed=function(e){rb&&rb(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(Qk.push(t)!==1&&eb===Ut.requestAnimationFrame||((eb=Ut.requestAnimationFrame)||wN)(yN)),t.__H.__.forEach(function(n){n.u&&(n.__H=n.u),n.u=void 0})),jm=Ot=null},Ut.__c=function(e,t){t.some(function(n){try{n.__h.forEach(If),n.__h=n.__h.filter(function(r){return!r.__||i0(r)})}catch(r){t.some(function(i){i.__h&&(i.__h=[])}),t=[],Ut.__e(r,n.__v)}}),ib&&ib(e,t)},Ut.unmount=function(e){ob&&ob(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach(function(r){try{If(r)}catch(i){t=i}}),n.__H=void 0,t&&Ut.__e(t,n.__v))};var lb=typeof requestAnimationFrame=="function";function wN(e){var t,n=function(){clearTimeout(r),lb&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,35);lb&&(t=requestAnimationFrame(n))}function If(e){var t=Ot,n=e.__c;typeof n=="function"&&(e.__c=void 0,n()),Ot=t}function i0(e){var t=Ot;e.__c=e.__(),Ot=t}function Y0(e,t){return!e||e.length!==t.length||t.some(function(n,r){return!r0(n,e[r])})}function Yk(e,t){return typeof t=="function"?t(e):t}function il(e){if(e==null||!e.isConnected||e===document.body||e===document.documentElement)return!1;e.focus({preventScroll:!0});const t=e.getRootNode();return t instanceof ShadowRoot?t.activeElement===e:document.activeElement===e}function sf(e){const t=e.getRootNode();if(t instanceof ShadowRoot){const r=t.activeElement;return r instanceof HTMLElement?r:null}const n=document.activeElement;return n instanceof HTMLElement&&e.contains(n)?n:null}function bN({ariaLabel:e,isFlattened:t=!1,ref:n,value:r,onBlur:i,onInput:s}){return Ce("input",{ref:n,"data-item-rename-input":!0,...t?{"data-item-flattened-rename-input":!0}:{},"aria-label":e,value:r,onBlur:i,onInput:s,onClick:l=>l.stopPropagation(),onMouseDown:l=>l.stopPropagation(),onPointerDown:l=>l.stopPropagation()})}function xN(e,t=null,n=null){"use no memo";const r=e.flattenedSegments;return r==null||r.length===0?t??e.name:Ce("span",{"data-item-flattened-subitems":!0,children:r.map((i,s)=>{const l=s===r.length-1;return Ce(Vl,{children:[Ce("span",{"data-item-flattened-subitem":i.path,"data-item-flattened-subitem-drag-target":n===i.path?"true":void 0,children:l&&t!=null?t:Ce(Ef,{children:i.name})}),s<r.length-1?" / ":""]},i.path)})})}function fl(e){var t,n;return e.isFlattened?((n=(t=e.flattenedSegments)==null?void 0:t.findLast(r=>r.isTerminal))==null?void 0:n.path)??e.path:e.path}function o0(e){const t=e.flattenedSegments;return t==null||t.length===0?e.name:t.map(n=>n.name).join(" / ")}function cb(e,t,n,r){return e.map((i,s)=>{const l=s*n,c=i.subtreeEndIndex+1;if(c>=r)return{row:i.row,top:l};const d=c*n-t;return{row:i.row,top:Math.min(l,d-n)}}).filter(i=>i.top+n>0)}function Vm({controller:e,itemHeight:t,overscan:n,scrollTop:r,stickyFolders:i,viewportHeight:s}){const l=e.getVisibleCount(),c=i&&l>0?e.getStickyRowCandidates(r,t):[],d=c==null&&i&&l>0?e.getVisibleRows(0,l-1):[],f=lN(d,{itemHeight:t,overscan:n,scrollTop:r,stickyRows:c==null?void 0:cb(c,r,t,l),totalRowCount:l,viewportHeight:s}),m=i&&r<=0&&l>0?e.getStickyRowCandidates(1,t):[],h=m!=null&&r<=0?cb(m,1,t,l):i&&r<=0&&d.length>0?Xk(d,1,t):f.sticky.rows;return{overlayHeight:h.reduce((g,y)=>Math.max(g,y.top+t),0),overlayRows:h,snapshot:f,visibleRows:d}}const _N=400,ub=10,Ya=40,db=18;function kN(e,t,n){var l,c;const r=e,i=((l=document.elementFromPoint)==null?void 0:l.bind(document))??null,s=((c=r.elementFromPoint)==null?void 0:c.call(r,t,n))??(i==null?void 0:i(t,n))??null;return e instanceof ShadowRoot&&(s==null||!e.contains(s))?SN(e,t,n):s instanceof HTMLElement?s:null}function SN(e,t,n){const r=Array.from(e.querySelectorAll('[data-type="item"], [data-item-flattened-subitem]'));for(let i=r.length-1;i>=0;i--){const s=r[i],l=s.getBoundingClientRect();if(t>=l.left&&t<=l.right&&n>=l.top&&n<=l.bottom)return s}return null}function fb(e){var l,c;const t=(l=e==null?void 0:e.closest)==null?void 0:l.call(e,'[data-type="item"]');if(!(t instanceof HTMLElement))return null;const n=t.dataset.itemPath??null;if(n==null)return null;const r=(c=e==null?void 0:e.closest)==null?void 0:c.call(e,"[data-item-flattened-subitem]"),i=r instanceof HTMLElement?r.getAttribute("data-item-flattened-subitem")??null:null;if(i!=null&&i.endsWith("/"))return{directoryPath:i,flattenedSegmentPath:i,hoveredPath:n,kind:"directory"};if(t.dataset.itemType==="folder")return{directoryPath:n,flattenedSegmentPath:null,hoveredPath:n,kind:"directory"};const s=t.dataset.itemParentPath??null;return s==null||s.length===0?{directoryPath:null,flattenedSegmentPath:null,hoveredPath:n,kind:"root"}:{directoryPath:s,flattenedSegmentPath:null,hoveredPath:n,kind:"directory"}}function hb(e){const t=e.cloneNode(!0);return t.removeAttribute("id"),t.dataset.fileTreeDragPreview="true",t.setAttribute("aria-hidden","true"),t.tabIndex=-1,Object.assign(t.style,{boxShadow:"0 4px 12px rgba(0, 0, 0, 0.15)",left:"0px",margin:"0",pointerEvents:"none",position:"fixed",top:"0px",willChange:"transform",zIndex:"10000"}),t}function CN(){return navigator.vendor!=="Apple Computer, Inc."}function EN(e,t){const n=e-t.top;if(n<Ya){const i=Math.max(0,n);return-Math.ceil((Ya-i)/Ya*db)}const r=t.bottom-e;if(r<Ya){const i=Math.max(0,r);return Math.ceil((Ya-i)/Ya*db)}return 0}function IN(e,t){if(e!=null){const n=cN[e];return n==null?null:{text:n,title:uN[e]}}return t?{icon:{name:"file-tree-icon-dot",width:6,height:6},title:dN}:null}function PN(e,t,n){if(t==null||t.size===0)return null;const r=[];for(let i=e.length-1;i>=0;i-=1){const s=e[i],l=n.get(s);if(l!=null){for(const c of r)n.set(c,l);return l?"ignored":null}if(t.has(s)){n.set(s,!0);for(const c of r)n.set(c,!0);return"ignored"}r.push(s)}for(const i of r)n.set(i,!1);return null}function Um(e){return e!=null&&"toggle"in e}function Jk(e){return e.code==="Space"||e.key===" "||e.key==="Spacebar"}function LN(e){return e.key.length===1&&/^[\p{L}\p{N}]$/u.test(e.key)&&!e.ctrlKey&&!e.metaKey&&!e.altKey}function Dc(e,t){if(e==null)return t;const n=e.getBoundingClientRect().height;return n>0?n:e.clientHeight>0?e.clientHeight:t}function DN(e,t){return e!=null&&e>0?e:t}function AN(e){const t=e.borderBoxSize,n=Array.isArray(t)?t[0]:t;return n!=null&&Number.isFinite(n.blockSize)&&n.blockSize>0?n.blockSize:e.contentRect.height>0?e.contentRect.height:null}function TN(e,t,n,r,i=0){const s=mN({currentScrollTop:e.scrollTop,focusedIndex:t,itemHeight:n,topInset:i,viewportHeight:r});return s==null?!1:(e.scrollTop=s,!0)}function Ac(e,t,n,r,i,s){const l=gN({currentScrollTop:e.scrollTop,focusedIndex:t,itemHeight:n,targetViewportOffset:s,totalHeight:i,viewportHeight:r});return l==null?!1:(e.scrollTop=l,!0)}function pb(e,t,n,r){return n.end<n.start?null:e<n.start?-t:e>n.end?r:null}function RN(e){return e==null?"":`[data-item-section="spacing-item"][data-ancestor-path="${e.replaceAll("\\","\\\\").replaceAll('"','\\"')}"] { opacity: 1; }`}function Zk(e){return e.shiftKey&&e.key==="F10"||e.key==="ContextMenu"}function NN(e,t){return t&&Zk(e)||(e.ctrlKey||e.metaKey)&&Jk(e)?!0:e.key==="ArrowDown"||e.key==="ArrowLeft"||e.key==="ArrowRight"||e.key==="ArrowUp"}const FN=new Set(["ArrowDown","ArrowLeft","ArrowRight","ArrowUp","End","Home","PageDown","PageUp"]);function mb(e){for(const t of e.composedPath())if(t instanceof HTMLElement&&(t.dataset.fileTreeContextMenuRoot==="true"||t.dataset.type==="context-menu-anchor"||t.dataset.type===Sg||t.getAttribute("slot")===al))return!0;return!1}function MN(e){return{bottom:e.bottom,height:e.height,left:e.left,right:e.right,top:e.top,width:e.width,x:e.x,y:e.y}}function ON(e,t){return{bottom:t,height:0,left:e,right:e,top:t,width:0,x:e,y:t}}function $N(e,t){if(e==null)return t.offsetTop;const n=t.getBoundingClientRect(),r=e.getBoundingClientRect();return n.top-r.top}function gb(e,t,n){if(n==null){e.delete(t);return}e.set(t,n)}function vb(e,t,n){if(e==null)return null;const r=t.get(e)??null;if(r!=null)return r;const i=n.get(e)??null;return(i==null?void 0:i.dataset.itemParked)==="true"?null:i}function BN(e){if(e==null)return[];const t=[];for(const n of e.querySelectorAll('button[data-file-tree-sticky-row="true"]')){if(!(n instanceof HTMLElement))continue;const r=n.dataset.fileTreeStickyPath;r!=null&&t.push(r)}return t}function jN(e,t){if(e==null||t==null)return null;for(const n of e.querySelectorAll('button[data-item-focused="true"][data-item-parked="true"]'))if(n instanceof HTMLElement&&n.dataset.itemPath===t)return n;return null}function VN(e,t,n,r,i,s,l){const c=Math.max(0,s-i),d=(t==null?void 0:t.getBoundingClientRect())??null,f=d==null||n==null?null:n.getBoundingClientRect().top-d.top,m=jN(e,r),h=d==null||m==null?null:m.getBoundingClientRect().top-d.top;return Math.max(0,Math.min(h??Math.max(f??0,c),Math.max(0,l-i)))}function yb(e,t){return{kind:e.kind,name:o0(e),path:t}}function UN(e){return e==null?void 0:`${e}__tree`}function eS(e,t,n){if(e!=null)return`${e}__focused-item-${encodeURIComponent(t)}${n?"__parked":""}`}function wb(e){return e==="file-tree-icon-chevron"||e==="file-tree-icon-dot"||e==="file-tree-icon-file"||e==="file-tree-icon-lock"}function bb(e,t){if(e==null)return null;if("text"in e)return Ce("span",{title:e.title,children:e.text});const n=typeof e.icon=="string"?wb(e.icon)?t(e.icon):{name:e.icon}:wb(e.icon.name)?(()=>{const r=t(e.icon.name),{name:i,...s}=e.icon;return{...r,...s}})():e.icon;return Ce("span",{title:e.title,children:Ce(Gc,{...n})})}function xb(e){e!=null&&il(e.querySelector(["button:not([disabled])","[href]","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(", "))??e)}function zN(e,t,{actionLaneEnabled:n=!1,customDecoration:r=null,decorationLaneEnabled:i=!1,dragTargetFlattenedSegmentPath:s=null,gitDecoration:l=null,gitLaneActive:c=!1,renameInput:d=null,showDecorativeActionAffordance:f=!1}={}){const m=fl(e);return Ce(Vl,{children:[e.depth>0?Ce("div",{"data-item-section":"spacing",children:Array.from({length:e.depth}).map((h,g)=>Ce("div",{"data-item-section":"spacing-item","data-ancestor-path":e.ancestorPaths[g]},g))}):null,Ce("div",{"data-item-section":"icon",children:e.kind==="directory"?Ce(Gc,{...t("file-tree-icon-chevron")}):Ce(Gc,{...t("file-tree-icon-file",m)})}),Ce("div",{"data-item-section":"content",children:e.isFlattened?xN(e,d,s):d??Ce(tN,{minimumLength:5,split:"extension",children:e.name})}),i?Ce("div",{"data-item-section":"decoration",children:r!=null?bb(r,t):null}):null,c?Ce("div",{"data-item-section":"git",children:bb(l,t)}):null,n?Ce("div",{"data-item-section":"action",children:f?Ce("span",{"aria-hidden":"true","data-item-action-affordance":"decorative",children:Ce(Gc,{...t("file-tree-icon-ellipsis")})}):null}):null]})}function Pf(e,t,n,r={}){const{controller:i,renameView:s,visualFocusPath:l,contextHoverPath:c,draggedPathSet:d,dragTarget:f,dragAndDropEnabled:m,shouldSuppressContextMenu:h,handleRowDragStart:g,handleRowDragEnd:y,handleRowTouchStart:w,instanceId:_,itemHeight:C,gitStatusByPath:I,ignoredGitDirectories:E,ignoredInheritanceCache:S,directoriesWithGitChanges:L,gitLaneActive:A,contextMenuEnabled:R,contextMenuTriggerMode:U,contextMenuButtonTriggerEnabled:X,contextMenuButtonVisibility:H,contextMenuRightClickEnabled:re,registerRenameInput:de,registerButton:te,resolveIcon:Q,renderDecorationForRow:ee,openContextMenuForRow:K,onRowClick:oe,onKeyDown:ie}=e,W=fl(t),{isParked:ce=!1,mode:le="flow",style:O}=r,J=le==="sticky",fe=(I==null?void 0:I.get(W))??null??PN(t.ancestorPaths,E,S),we=t.kind==="directory"&&((L==null?void 0:L.has(W))??!1),be=ee(t,W),Pe=IN(fe,we),Ne=R&&X,he=be!=null||A||Ne,Te=Ne&&H==="always",Qe=s.getPath()===W,pt=Qe?s.getValue():"",mt=J||!Qe?null:Ce(bN,{ref:de,ariaLabel:`Rename ${o0(t)}`,isFlattened:t.isFlattened,value:pt,onBlur:()=>{s.commit()},onInput:Je=>{s.setValue(Je.currentTarget.value)}}),ct=zN(t,Q,{actionLaneEnabled:Ne,customDecoration:be,decorationLaneEnabled:he,dragTargetFlattenedSegmentPath:(f==null?void 0:f.flattenedSegmentPath)??null,gitDecoration:Pe,gitLaneActive:A,renameInput:mt,showDecorativeActionAffordance:Te}),mn={...hN({ariaLabel:o0(t),domId:t.isFocused?eS(_,W,ce):void 0,extraStyle:O,features:{actionLaneEnabled:Ne,contextMenuButtonVisibility:Ne?H:null,contextMenuEnabled:R,contextMenuTriggerMode:R?U:null,gitLaneActive:A},isParked:ce,itemHeight:C,mode:le,row:t,state:{containsGitChange:we,effectiveGitStatus:fe,isContextHovered:c===W,isDragTarget:(f==null?void 0:f.kind)==="directory"&&f.directoryPath===W,isDragging:(d==null?void 0:d.has(W))===!0,isFocusRinged:t.isFocused&&l===W},targetPath:W}),key:n,onContextMenu:R||m?Je=>{if(h()){Je.preventDefault();return}R&&(Je.preventDefault(),re&&(i.focusPath(W),K(t,W,{anchorRect:ON(Je.clientX,Je.clientY),source:"right-click"})))}:void 0,onFocus:J?void 0:()=>{i.focusPath(W)},onKeyDown:J?void 0:ie,ref:Je=>{te(W,Je)}};return!J&&Qe?Ce("div",{...mn,children:ct}):Ce("button",{...mn,type:"button",draggable:m&&!ce,onDragEnd:m&&!ce?y:void 0,onDragStart:m&&!ce?Je=>{g(Je,t,W)}:void 0,onMouseDown:Je=>{if(J){Je.preventDefault();return}i.isSearchOpen()&&Je.preventDefault()},onTouchStart:m&&!ce?Je=>{w(Je,t,W)}:void 0,onClick:Je=>{oe(Je,t,W,le)},children:ct})}function HN(e,t,n){return t.end<t.start?[]:e.controller.getVisibleRows(t.start,t.end).filter(r=>!n.has(fl(r))).map((r,i)=>Pf(e,r,t.start+i))}function _b({composition:e,controller:t,gitStatusByPath:n,ignoredGitDirectories:r,directoriesWithGitChanges:i,icons:s,instanceId:l,itemHeight:c=V_,overscan:d=wA,renamingEnabled:f=!1,renderRowDecoration:m,searchBlurBehavior:h="close",searchEnabled:g=!1,searchFakeFocus:y=!1,slotHost:w,stickyFolders:_=!1,initialViewportHeight:C=U_}){"use no memo";var Ro,As,Jl,Hu,Wu,Gu,Ca;const I=qe(null),E=qe(null),S=qe(!1),L=qe(null),A=qe(null),R=qe(null),U=qe(null),X=qe(null),H=qe(new Map),re=qe(new Map),de=qe(()=>{}),te=qe(null),Q=qe(!1),ee=qe(null),K=qe(null),oe=qe(!1),ie=qe(null),W=qe(null),ce=qe(null),le=qe(null),O=qe(null),J=qe(null),fe=qe(null),we=qe(null),be=qe(!1),Pe=qe(null),Ne=qe(null),he=qe(null),Te=qe(null),Qe=Jo(()=>new Map,[]),[,pt]=ki(0),[mt,ct]=ki(null),[mn,Je]=ki(null),[Oi,Mr]=ki(null),[vs,$t]=ki(null),[$i,oi]=ki(0),[Fe,er]=ki(null),si=qe(Fe);si.current=Fe;const Bi=qe(null),tr=qe(null),Or=qe(null),nr=qe(null),ji=qe(null),gn=qe(!1),ai=()=>{tr.current=null,Or.current=null,nr.current=null},mr=(N,ne)=>{tr.current=N,Or.current=null,nr.current=ne==null?null:{path:N,scrollTop:ne}},da=(N,ne)=>{tr.current=null,Or.current={path:N,viewportOffset:ne},nr.current=null},ys=qe(h==="retain"&&t.isSearchOpen()),[fa,Vi]=ki(y);ab(()=>{y||Vi(!1)},[y]);const _o=qe(!1),$r=Dn(()=>{_o.current=!0,Vi(N=>N&&!1)},[]),[$n,ws]=ki(()=>Vm({controller:t,itemHeight:c,overscan:d,scrollTop:0,stickyFolders:_,viewportHeight:C})),[li,Br]=ki(!1);ab(()=>{Br(!0)},[]);const zt=((Ro=e==null?void 0:e.contextMenu)==null?void 0:Ro.enabled)===!0||((As=e==null?void 0:e.contextMenu)==null?void 0:As.render)!=null||((Jl=e==null?void 0:e.contextMenu)==null?void 0:Jl.onOpen)!=null||((Hu=e==null?void 0:e.contextMenu)==null?void 0:Hu.onClose)!=null,je=((Wu=e==null?void 0:e.contextMenu)==null?void 0:Wu.triggerMode)??(zt?"right-click":"both"),ft=je==="both"||je==="button",Nt=((Gu=e==null?void 0:e.contextMenu)==null?void 0:Gu.buttonVisibility)??"when-needed",sn=je==="both"||je==="right-click";lr(()=>{const N=R.current;if(N==null)return;const ne=ve=>{var Se;if(!(ve instanceof CustomEvent))return;const _e=((Se=ve.detail)==null?void 0:Se.path)??null;ji.current=_e,Je(_e),$t(_e==null?null:"pointer")},xe=ve=>{var _e;ve instanceof CustomEvent&&(gn.current=((_e=ve.detail)==null?void 0:_e.disabled)===!0)};return N.addEventListener("file-tree-debug-set-context-menu-trigger",ne),N.addEventListener("file-tree-debug-set-scroll-suppression",xe),()=>{N.removeEventListener("file-tree-debug-set-context-menu-trigger",ne),N.removeEventListener("file-tree-debug-set-scroll-suppression",xe)}},[]);const ci=Dn((N,ne)=>{gb(H.current,N,ne)},[]),Ft=Dn((N,ne)=>{gb(re.current,N,ne)},[]),Ht=Dn(N=>{A.current=N},[]),Bn=Dn(N=>vb(N,re.current,H.current),[]),Wt=n!=null||r!=null||i!=null,{resolveIcon:kn}=Jo(()=>OR(s),[s]),jn=t[_k](),Yt=jn.getPath(),Ui=Yt!=null,gr=t.isSearchOpen(),kh=t.getSearchValue(),et=t.getFocusedPath(),dt=t.getFocusedIndex(),vn=t.isDragAndDropEnabled(),vr=t.getDragSession(),Tu=Jo(()=>vr==null?null:new Set(vr.draggedPaths),[vr]),Sh=(vr==null?void 0:vr.target)??null,ko=(vr==null?void 0:vr.primaryPath)??null,Ul=UN(l),{overlayHeight:Ru,overlayRows:Nu,snapshot:Gt,visibleRows:ha}=$n,tt=Gt.physical.viewportHeight,rr=Jo(()=>({end:Gt.window.endIndex,start:Gt.window.startIndex}),[Gt.window.endIndex,Gt.window.startIndex]),zi=Nu,zl=Gt.sticky.rows,jr=Gt.physical.totalHeight,bs=Gt.sticky.height,xs=Jo(()=>new Set(zl.map(N=>fl(N.row))),[zl]),So=dt>=0&&dt>=rr.start&&dt<=rr.end,yr=Dn((N,ne)=>(m==null?void 0:m({item:yb(N,ne),row:N}))??null,[m]),Fu=Dn(N=>il(N==null?null:H.current.get(N)??null)?!0:il(R.current),[]),Sn=Dn(N=>{Fu(t.focusNearestPath(N))},[t,Fu]),Mu=qe(Sn);Mu.current=Sn;const Co=qe(!0),Hl=qe(()=>{}),yn=Dn((N=!0)=>{var xe,ve;const ne=si.current;ne!=null&&(Co.current=Co.current&&N,er(null),(ve=(xe=e==null?void 0:e.contextMenu)==null?void 0:xe.onClose)==null||ve.call(xe),Co.current&&Sn(ne.path))},[e==null?void 0:e.contextMenu,Sn]);Hl.current=yn;const ui=Dn(N=>{const ne=N==null?null:$N(R.current,N);Mr(xe=>xe===ne?xe:ne)},[]),Eo=Dn((N,ne,xe)=>{const ve=t.getItem(ne);if(ve==null)return;const _e=Bn(ne);if((_e==null?void 0:_e.dataset.fileTreeStickyRow)==="true"){const Se=U.current;mr(ne,(Se==null?void 0:Se.scrollTop)??null),Q.current=!0,ct(We=>We===ne?We:ne)}ve.focus(),ui(_e),Co.current=!0,er({anchorRect:(xe==null?void 0:xe.anchorRect)??null,item:yb(N,ne),path:ne,source:(xe==null?void 0:xe.source)??"keyboard"})},[t,Bn,ui]),pa=Dn(N=>{if(f){if(t.isSearchOpen()){const ne=U.current,xe=Dc(ne,tt);ie.current=dt<0||ne==null?null:Math.max(0,Math.min(dt*c-ne.scrollTop,Math.max(0,xe-c))),oe.current=!0}t.startRenaming(N)!==!1&&($t("focus"),pt(ne=>ne+1))}},[t,dt,c,f,tt]),ma=Dn((N,{restoreTreeFocus:ne=!0,targetOffset:xe="live-overlay"}={})=>{const ve=U.current;if(ve==null)return!1;t.focusPath(N);const _e=t.getFocusedIndex();if(_e<0)return!1;const Se=t.getVisibleRows(_e,_e)[0]??null;if(Se==null)return!1;const We=Dc(ve,tt),Oe=t.getVisibleCount()*c,Ve=xe==="sticky-parents"?Se.ancestorPaths.length*c:Vm({controller:t,itemHeight:c,overscan:d,scrollTop:ve.scrollTop,stickyFolders:_,viewportHeight:We}).snapshot.sticky.height;return Q.current=!0,Ac(ve,_e,c,We,Oe,Ve),de.current(),Bi.current=ne?N:null,!0},[t,c,d,tt,_]),Ch=()=>S.current===!0||Te.current!=null||be.current===!0,ga=N=>typeof window.requestAnimationFrame=="function"?window.requestAnimationFrame(()=>{N()}):window.setTimeout(N,16),Ou=N=>{if(N!=null){if(typeof window.cancelAnimationFrame=="function"){window.cancelAnimationFrame(N);return}window.clearTimeout(N)}},wr=()=>{le.current!=null&&(clearTimeout(le.current),le.current=null),ce.current=null},di=()=>{var N;(N=J.current)==null||N.remove(),J.current=null},_s=()=>{Ou(W.current),W.current=null,O.current=null},va=N=>{var xe;const ne=(xe=R.current)==null?void 0:xe.getRootNode();if(ne instanceof ShadowRoot){ne.append(N);return}document.body.append(N)},nt=()=>{var N;(N=we.current)==null||N.call(we),we.current=null,Te.current!=null&&(clearTimeout(Te.current),Te.current=null),be.current=!1,Pe.current=null,he.current=null,Ne.current!=null&&(Ne.current.setAttribute("draggable","true"),Ne.current.style.removeProperty("touch-action"),Ne.current=null),di(),wr(),_s(),fe.current=null},ks=(N,ne)=>{var _e,Se;const xe=(_e=R.current)==null?void 0:_e.getRootNode(),ve=fb(kN(xe instanceof ShadowRoot?xe:document,N,ne));return t.setDragTarget(ve),((Se=t.getDragSession())==null?void 0:Se.target)??null},ya=N=>{var Se;const ne=((Se=t.getDragAndDropConfig())==null?void 0:Se.openOnDropDelay)??800;if(N==null||N.kind!=="directory"||N.directoryPath==null||ne<=0){wr();return}const xe=t.getItem(N.directoryPath),ve=Um(xe)?xe:null;if(ve==null||ve.isExpanded()){wr();return}const _e=`${N.directoryPath}::${N.flattenedSegmentPath??""}`;ce.current!==_e&&(wr(),ce.current=_e,le.current=setTimeout(()=>{var Oe;const We=(Oe=t.getDragSession())==null?void 0:Oe.target;(We==null?void 0:We.kind)!=="directory"||We.directoryPath!==N.directoryPath||We.flattenedSegmentPath!==N.flattenedSegmentPath||ve.expand()},ne))},wa=()=>{W.current=null;const N=O.current,ne=U.current;if(N==null||ne==null||t.getDragSession()==null)return;const xe=ne.getBoundingClientRect(),ve=EN(N.clientY,xe);if(ve===0)return;const _e=Math.max(0,ne.scrollHeight-ne.clientHeight),Se=Math.max(0,Math.min(_e,ne.scrollTop+ve));Se!==ne.scrollTop&&(ne.scrollTop=Se,de.current()),ya(ks(N.clientX,N.clientY)),W.current=ga(wa)},Wl=(N,ne)=>{O.current={clientX:N,clientY:ne},W.current??(W.current=ga(wa))},$u=(N,ne,xe)=>{const ve=N.currentTarget;if(ve!=null){if(nt(),di(),wr(),_s(),t.startDrag(xe)===!1){N.preventDefault();return}if(fe.current=ne,N.dataTransfer!=null&&(N.dataTransfer.effectAllowed="move",N.dataTransfer.dropEffect="move",N.dataTransfer.setData("text/plain",xe),CN())){const _e=hb(ve),Se=ve.getBoundingClientRect();Object.assign(_e.style,{height:`${Se.height}px`,opacity:"0.85",transform:"translate3d(-9999px, 0px, 0)",width:`${Se.width}px`}),va(_e),J.current=_e,N.dataTransfer.setDragImage(_e,Math.max(0,N.clientX-Se.left),Math.max(0,N.clientY-Se.top))}}},Bu=()=>{di(),wr(),_s(),fe.current=null,t.cancelDrag()},Gl=(N,ne,xe)=>{if(Te.current!=null||be.current)return;const ve=N.touches[0],_e=N.currentTarget;if(ve==null||_e==null)return;he.current={clientX:ve.clientX,clientY:ve.clientY},Ne.current=_e,_e.setAttribute("draggable","false");const Se=(Ve={})=>{const ut=Ve.restoreNativeDraggable??!be.current;Te.current!=null&&(clearTimeout(Te.current),Te.current=null),document.removeEventListener("touchmove",We),document.removeEventListener("touchend",Oe),document.removeEventListener("touchcancel",Oe),we.current===Se&&(we.current=null),ut&&(_e.setAttribute("draggable","true"),Ne.current===_e&&(Ne.current=null),he.current=null)},We=Ve=>{const ut=Ve.touches[0],ht=he.current;if(ut==null||ht==null)return;const Pt=ut.clientX-ht.clientX,wt=ut.clientY-ht.clientY;Pt*Pt+wt*wt<=ub*ub||Se()},Oe=()=>{Se()};document.addEventListener("touchmove",We,{passive:!0}),document.addEventListener("touchend",Oe),document.addEventListener("touchcancel",Oe),we.current=Se,Te.current=setTimeout(()=>{if(Se({restoreNativeDraggable:!1}),t.startDrag(xe)===!1){_e.setAttribute("draggable","true"),Ne.current===_e&&(Ne.current=null),he.current=null;return}be.current=!0,Ne.current=_e,_e.setAttribute("draggable","false"),_e.style.setProperty("touch-action","none"),fe.current=ne;const Ve=_e.getBoundingClientRect(),ut=hb(_e);Object.assign(ut.style,{height:`${Ve.height}px`,opacity:"0.85",transform:`translate3d(${Ve.left}px, ${Ve.top}px, 0)`,width:`${Ve.width}px`}),va(ut),J.current=ut,Pe.current={x:ve.clientX-Ve.left,y:ve.clientY-Ve.top};const ht=br=>{const _t=br.touches[0];if(_t==null)return;br.preventDefault();const Jt=Pe.current;Jt!=null&&J.current!=null&&(J.current.style.transform=`translate3d(${_t.clientX-Jt.x}px, ${_t.clientY-Jt.y}px, 0)`),ya(ks(_t.clientX,_t.clientY)),Wl(_t.clientX,_t.clientY)},Pt=br=>{const _t=br.changedTouches[0];_t!=null&&ks(_t.clientX,_t.clientY),t.completeDrag(),nt()},wt=()=>{t.cancelDrag(),nt()};we.current=()=>{document.removeEventListener("touchmove",ht),document.removeEventListener("touchend",Pt),document.removeEventListener("touchcancel",wt)},document.addEventListener("touchmove",ht,{passive:!1}),document.addEventListener("touchend",Pt),document.addEventListener("touchcancel",wt)},_N)},Ss=N=>{if(Fe!=null){if(N.key==="Escape"){yn(),N.preventDefault(),N.stopPropagation();return}FN.has(N.key)&&(N.preventDefault(),N.stopPropagation());return}if(jn.isActive()){if(N.key==="Escape")jn.cancel();else if(N.key==="Enter")jn.commit();else return;$t("focus"),pt(gt=>gt+1),N.preventDefault(),N.stopPropagation();return}if(f&&N.key==="F2"){pa(et??void 0),N.preventDefault(),N.stopPropagation();return}if(gr){if(N.key==="Escape")oe.current=!1,ie.current=null,t.closeSearch();else if(N.key==="Enter"){const gt=t.getFocusedPath();gt!=null&&t.selectOnlyPath(gt);const yi=U.current,Zl=Dc(yi,tt);ie.current=dt<0||yi==null?null:Math.max(0,Math.min(dt*c-yi.scrollTop,Math.max(0,Zl-c))),oe.current=!0,t.closeSearch()}else if(N.key==="ArrowDown")t.focusNextSearchMatch();else if(N.key==="ArrowUp")t.focusPreviousSearchMatch();else return;$t("focus"),pt(gt=>gt+1),N.preventDefault(),N.stopPropagation();return}if(g&&LN(N)){t.openSearch(N.key),pt(gt=>gt+1),N.preventDefault(),N.stopPropagation();return}const ne=zt&&Zk(N),xe=NN(N,zt),ve=xe&&R.current!=null?sf(R.current):null,_e=xe?new Set(BN(R.current)):new Set,Se=(ve==null?void 0:ve.dataset.fileTreeStickyPath)??null,We=(ve==null?void 0:ve.dataset.fileTreeStickyRow)==="true"&&Se!=null;if(We&&Se!==et&&_e.has(Se)){const gt=U.current;mr(Se,(gt==null?void 0:gt.scrollTop)??null),t.focusPath(Se)}const Oe=t.getFocusedPath(),Ve=t.getFocusedIndex(),ut=t.getFocusedItem();if(ut==null)return;const ht=Um(ut)?ut:null,Pt=Oe!=null&&(xs.has(Oe)||We&&Se===Oe&&_e.has(Oe)),wt=N.key==="ArrowDown"||N.key==="ArrowUp"||N.key==="ArrowRight"&&ht!=null&&ht.isExpanded(),br=N.key==="ArrowLeft"&&Pt&&ht!=null&&ht.isExpanded(),_t=U.current;let Jt=!0;if(N.shiftKey&&N.key==="ArrowDown")t.extendSelectionFromFocused(1);else if(N.shiftKey&&N.key==="ArrowUp")t.extendSelectionFromFocused(-1);else if(ne&&Oe!=null&&Ve>=0){const gt=t.getVisibleRows(Ve,Ve)[0]??null,yi=vb(Oe,re.current,H.current);gt==null||yi==null?Jt=!1:Eo(gt,Oe)}else if((N.ctrlKey||N.metaKey)&&Jk(N))t.toggleFocusedSelection();else if((N.ctrlKey||N.metaKey)&&N.key.toLowerCase()==="a")t.selectAllVisiblePaths();else switch(N.key){case"ArrowDown":t.focusNextItem();break;case"ArrowUp":t.focusPreviousItem();break;case"ArrowRight":ht==null||ht.isExpanded()?t.focusNextItem():ht.expand();break;case"ArrowLeft":ht!=null&&ht.isExpanded()?ht.collapse():t.focusParentItem();break;case"Home":t.focusFirstItem();break;case"End":t.focusLastItem();break;default:Jt=!1}if(!Jt)return;$t("focus");const rt=t.getFocusedPath(),Ur=rt!=null&&(xs.has(rt)||_e.has(rt)),zr=wt&&rt!==Oe,Ea=ne&&We&&Se===Oe&&rt===Oe;if((Pt||Ea)&&rt!=null&&(zr&&Ur||Ea))mr(rt,(_t==null?void 0:_t.scrollTop)??null),Q.current=!0,ct(gt=>gt===rt?gt:rt);else{const gt=N.key==="ArrowUp"&&Pt&&rt!==Oe;rt!=null&&(gt||br&&rt===Oe)?(da(rt,VN(R.current,_t,ve,Oe,c,bs,tt)),Q.current=!0,ct(yi=>yi===rt?yi:rt)):ai()}pt(gt=>gt+1),N.preventDefault(),N.stopPropagation()};lr(()=>{if(!(!g||!gr)){if(ys.current){ys.current=!1;return}il(X.current)}},[gr,g]),lr(()=>{const N=A.current;switch(fN({hasRenderedInput:N!=null,previousRenamingPath:K.current,renamingPath:Yt})){case"reset":K.current=null;return;case"reveal-canonical":Yt!=null&&ma(Yt,{restoreTreeFocus:!1,targetOffset:"live-overlay"});return;case"ignore":return;case"focus-input":N!=null&&(Bi.current=null,K.current=Yt,il(N),N.select());return}},[rr.end,rr.start,Yt,ma,xs]),lr(()=>{const N=R.current;if(N==null)return;let ne=null;const xe=()=>{ne!=null&&(clearTimeout(ne),ne=null)},ve=()=>{var Oe;const We=((Oe=sf(N))==null?void 0:Oe.dataset.itemPath)??null;ct(Ve=>Ve===We?Ve:We)},_e=()=>{xe(),Q.current=!0,ve()},Se=We=>{const Oe=We.relatedTarget;if(Oe==null){xe(),ne=setTimeout(()=>{if(ne=null,sf(N)!=null){ve();return}Q.current=!1,ct(null)},0);return}if(!(Oe instanceof Node)||!N.contains(Oe)){xe(),Q.current=!1,ct(null);return}const Ve=Oe instanceof HTMLElement?Oe.dataset.itemPath??null:null;ct(ut=>ut===Ve?ut:Ve)};return N.addEventListener("focusin",_e),N.addEventListener("focusout",Se),()=>{xe(),N.removeEventListener("focusin",_e),N.removeEventListener("focusout",Se)}},[]),lr(()=>{const N=R.current;N!=null&&(Gt.physical.scrollTop<=0?N.dataset.scrollAtTop="true":delete N.dataset.scrollAtTop)},[Gt.physical.scrollTop]),lr(()=>{let N=null;const ne=U.current,xe=L.current,ve=R.current;if(ne==null)return;te.current=Dc(ne,C);const _e=()=>{const rt=t.getVisibleCount(),Ur=DN(te.current,C),zr=Math.max(0,rt*c-Ur);ne.scrollTop>zr&&(ne.scrollTop=zr),ws(Vm({controller:t,itemHeight:c,overscan:d,scrollTop:Math.min(ne.scrollTop,zr),stickyFolders:_,viewportHeight:Ur}))};de.current=_e;let Se=!1;const We=t.subscribe(()=>{Se?pt(rt=>rt+1):Se=!0,_e()}),Oe=()=>{var rt,Ur;gn.current!==!0&&(xe!=null&&((rt=xe.dataset).isScrolling??(rt.isScrolling="")),ve!=null&&((Ur=ve.dataset).isScrolling??(Ur.isScrolling="")),S.current=!0,N!=null&&clearTimeout(N),N=setTimeout(()=>{xe!=null&&delete xe.dataset.isScrolling,ve!=null&&delete ve.dataset.isScrolling,S.current=!1,oi(zr=>zr+1),N=null},50))};let Ve=null;const ut=()=>{ve!=null&&delete ve.dataset.overlayReveal,Ve!=null&&(clearTimeout(Ve),Ve=null)},ht=()=>{ve==null||gn.current===!0||ne.scrollTop>0||(ve.dataset.overlayReveal="true",Ve!=null&&clearTimeout(Ve),Ve=setTimeout(()=>{ut()},200))},Pt=()=>{if(_e(),ne.scrollTop>0&&ut(),si.current!=null&&S.current&&Hl.current(),gn.current===!0){S.current=!1;return}Je(rt=>rt==null?rt:null),Oe()},wt=()=>{Oe(),ht()},br=new Set(["ArrowUp","ArrowDown","ArrowLeft","ArrowRight","PageUp","PageDown","Home","End"," ","Spacebar"]),_t=rt=>{br.has(rt.key)&&wt()};ne.addEventListener("scroll",Pt,{passive:!0}),ne.addEventListener("wheel",wt,{passive:!0}),ne.addEventListener("touchmove",wt,{passive:!0}),ne.addEventListener("keydown",_t);const Jt=typeof ResizeObserver<"u"?new ResizeObserver(rt=>{te.current=(rt[0]==null?null:AN(rt[0]))??Dc(ne,C),_e()}):null;return Jt==null||Jt.observe(ne),()=>{de.current=()=>{},We(),ne.removeEventListener("scroll",Pt),ne.removeEventListener("wheel",wt),ne.removeEventListener("touchmove",wt),ne.removeEventListener("keydown",_t),N!=null&&clearTimeout(N),Ve!=null&&clearTimeout(Ve),xe!=null&&delete xe.dataset.isScrolling,ve!=null&&(delete ve.dataset.isScrolling,delete ve.dataset.overlayReveal),S.current=!1,te.current=null,Jt==null||Jt.disconnect()}},[t,C,c,d,_]),lr(()=>{zt||Fe==null||yn(!1)},[yn,zt,Fe]);const Vr=Jo(()=>Fe==null?null:`${Fe.path}::${Fe.source}`,[Fe]);lr(()=>{var _e,Se,We,Oe;if(Vr==null){w==null||w.clearSlotContent(al);return}const N=si.current;if(N==null)return;const ne=E.current??I.current;if(ne==null)return;const xe={anchorElement:ne,anchorRect:N.anchorRect??MN(ne.getBoundingClientRect()),close:Ve=>{Hl.current((Ve==null?void 0:Ve.restoreFocus)??!0)},restoreFocus:()=>{var Ve;Co.current&&Mu.current(((Ve=si.current)==null?void 0:Ve.path)??null)}},ve=((Se=(_e=e==null?void 0:e.contextMenu)==null?void 0:_e.render)==null?void 0:Se.call(_e,N.item,xe))??null;return w==null||w.setSlotContent(al,ve),(Oe=(We=e==null?void 0:e.contextMenu)==null?void 0:We.onOpen)==null||Oe.call(We,N.item,xe),xb(ve),queueMicrotask(()=>{ve==null||!ve.isConnected||document.activeElement===ve&&xb(ve)}),()=>{w==null||w.clearSlotContent(al)}},[Vr,e==null?void 0:e.contextMenu,w]),lr(()=>{Fe!=null&&t.getItem(Fe.path)==null&&yn()},[yn,Fe,t]),lr(()=>{var _e;if(Fe==null)return;const N=(_e=R.current)==null?void 0:_e.getRootNode(),ne=N instanceof ShadowRoot?N.host:R.current,xe=Se=>{var Oe;const We=Se.target;We instanceof Node&&(mb(Se)||((Oe=I.current)==null?void 0:Oe.contains(We))!==!0&&(ne==null?void 0:ne.contains(We))!==!0&&yn())},ve=Se=>{Se.key==="Escape"&&(Se.preventDefault(),Se.stopPropagation(),yn())};return document.addEventListener("mousedown",xe,!0),document.addEventListener("keydown",ve,!0),()=>{document.removeEventListener("mousedown",xe,!0),document.removeEventListener("keydown",ve,!0)}},[yn,Fe]),lr(()=>{const N=U.current,ne=R.current;if(N==null||ne==null){ee.current=et;return}const xe=et==null?null:H.current.get(et)??null,ve=sf(ne),_e=(ve==null?void 0:ve.dataset.itemPath)??null,Se=Ui&&A.current===ve,We=g&&X.current===ve,Oe=oe.current&&!gr,Ve=ie.current??0,ut=Bi.current,ht=tr.current,Pt=Or.current,wt=nr.current,br=ve!=null,_t=Q.current||br,Jt=ee.current!==et,rt=ht!=null&&ht===et&&et!=null,Ur=Oe&&Ac(N,dt,c,tt,jr,Ve),zr=ut!=null&&ut===et&&Ac(N,dt,c,tt,jr,bs),Ea=Pt!=null&&Pt.path===et&&Ac(N,dt,c,tt,jr,Pt.viewportOffset),gt=wt!=null&&wt.path===et&&N.scrollTop!==wt.scrollTop;if(gt&&(N.scrollTop=wt.scrollTop),(gt||zr||Ea||Ur||_t&&Jt&&ut!==et&&!rt&&TN(N,dt,c,tt,bs))&&de.current(),!_t){ee.current=et;return}if(Se){ee.current=et;return}if(We&&!Oe){ee.current=et;return}if(xe==null){Oe&&dt>=0&&(Ac(N,dt,c,tt,jr,Ve),de.current()),ee.current=et;return}(Jt||Oe||ut===et||ht===et||(Pt==null?void 0:Pt.path)===et||(wt==null?void 0:wt.path)===et||_e==null||_e!==et)&&(il(xe),ut===et&&(Bi.current=null),ht===et&&(tr.current=null),(Pt==null?void 0:Pt.path)===et&&(Or.current=null),(wt==null?void 0:wt.path)===et&&(nr.current=null),oe.current=!1,ie.current=null),ee.current=et},[t,dt,et,So,c,Ui,gr,rr,tt,g,bs,jr,ha]);const fi=dt>=0&&dt>=Gt.visible.startIndex&&dt<=Gt.visible.endIndex,hi=et!=null&&zi.some(N=>fl(N.row)===et),Cs=fi||hi,Es=ft&&Q.current===!0&&Cs?et:null,pi=vs==="pointer"?mn:null,Hi=(Fe==null?void 0:Fe.path)??ji.current??pi??Es??mn,ql=(Fe==null?void 0:Fe.source)==="right-click";lr(()=>{S.current&&Fe==null||ui(Bn(Hi))},[Fe,Bn,rr,tt,$i,zi,Hi,ui,ha]);const Is=Dn(N=>{var Se,We,Oe;if(S.current||mb(N))return;const ne=N.target;if(!(ne instanceof HTMLElement)||((Se=ne.closest)==null?void 0:Se.call(ne,`[data-type="${Sg}"]`))!=null)return;const xe=(We=ne.closest)==null?void 0:We.call(ne,'[data-file-tree-sticky-row="true"]'),ve=(Oe=ne.closest)==null?void 0:Oe.call(ne,'[data-type="item"]'),_e=xe instanceof HTMLElement?xe.dataset.fileTreeStickyPath??null:ve instanceof HTMLElement?ve.dataset.itemPath??null:null;_e!=null&&$t(Ve=>Ve==="pointer"?Ve:"pointer"),Je(Ve=>Ve===_e?Ve:_e)},[]),Eh=Dn(()=>{Je(null)},[]);lr(()=>{if(!vn)return;const N=()=>{nt(),t.cancelDrag()};return window.addEventListener("dragend",N),()=>{window.removeEventListener("dragend",N),nt(),t.cancelDrag()}},[t,vn]);const ju=N=>{var xe;if(!vn||t.getDragSession()==null||be.current)return;const ne=fb(N.target instanceof HTMLElement?N.target:null);t.setDragTarget(ne),ya(((xe=t.getDragSession())==null?void 0:xe.target)??null),Wl(N.clientX,N.clientY),N.dataTransfer!=null&&(N.dataTransfer.dropEffect="move"),N.preventDefault()},ba=N=>{var xe;if(!vn||t.getDragSession()==null||be.current)return;const ne=N.relatedTarget;ne instanceof Node&&((xe=R.current)==null?void 0:xe.contains(ne))===!0||(wr(),_s(),t.setDragTarget(null))},Vu=N=>{!vn||t.getDragSession()==null||be.current||(N.preventDefault(),ks(N.clientX,N.clientY),t.completeDrag(),di(),wr(),_s(),fe.current=null)},xa=Gt.window.height,Ps=Gt.window.offsetTop,Io=Math.min(0,tt-xa-bs),Po=mt===et||oe.current,ir=et!=null&&Po&&!So&&dt>=0?ha[dt]??t.getVisibleRows(dt,dt)[0]??null:null,Uu=ir==null?null:pb(dt,c,rr,xa),mi=fe.current,Kl=ko!=null&&mi!=null&&mi.path===ko&&mi.index>=rr.start&&mi.index<=rr.end,gi=ko!=null&&mi!=null&&mi.path===ko&&!Kl&&mi.path!==(ir==null?void 0:ir.path)?mi:null,_a=gi==null?null:pb(gi.index,c,rr,xa),zu=RN(((Ca=dt>=0?ha[dt]??t.getVisibleRows(dt,dt)[0]??null:null)==null?void 0:Ca.ancestorPaths.at(-1))??null),vi=gr&&et!=null?eS(l,et,!So):void 0,Xl=(Fe==null?void 0:Fe.path)??(gr?et:mt),ka=(Fe==null?void 0:Fe.path)??mn,Lo=Bn(Hi),Do=zt&&ft&&!ql&&!Ui&&Lo!=null&&Oi!=null&&Hi!=null,Sa=zt&&(Do||Fe!=null),Ls=Fe==null?void 0:Fe.anchorRect,Cn=Ls==null&&Lo!=null&&Oi!=null&&(Fe!=null||Do)?Oi:null,Ao=Ls!=null?{left:`${Ls.left}px`,position:"fixed",right:"auto",top:`${Ls.top}px`}:Cn!=null?{top:`${Cn}px`}:void 0,Ql=ql?{opacity:"0"}:void 0,Ds=Dn((N,ne,xe,ve)=>{const _e=t.getItem(xe),Se=pN({event:{ctrlKey:N.ctrlKey,metaKey:N.metaKey,shiftKey:N.shiftKey},isDirectory:ne.kind==="directory",isSearchOpen:t.isSearchOpen(),mode:ve});switch(Se.selection.kind){case"range":t.selectPathRange(xe,Se.selection.additive);break;case"toggle":t.togglePathSelectionFromInput(xe);break;case"single":t.selectOnlyPath(xe);break}const We=N.currentTarget instanceof HTMLElement?N.currentTarget:null,Oe=ne.index>=Gt.visible.startIndex&&ne.index<=Gt.visible.endIndex,Ve=ve==="flow"&&Oe&&We!=null&&We.dataset.itemParked!=="true";_e==null||_e.focus(),Ve&&(Q.current=!0,ct(ut=>ut===xe?ut:xe),$t("focus")),Se.toggleDirectory&&Um(_e)&&_e.toggle(),Se.closeSearch&&t.closeSearch(),Se.revealCanonical&&ma(xe,{targetOffset:"sticky-parents"})},[t,Gt.visible.endIndex,Gt.visible.startIndex,ma]),Ih=()=>{if(S.current||!ft||Hi==null||Lo==null)return;const N=t.getItem(Hi);N!=null&&(ui(Lo),Co.current=!0,er({anchorRect:null,item:{kind:N.isDirectory()?"directory":"file",name:Lo.getAttribute("aria-label")??Hi,path:N.getPath()},path:N.getPath(),source:"button"}))},To={contextHoverPath:ka,contextMenuButtonTriggerEnabled:ft,contextMenuButtonVisibility:Nt,contextMenuEnabled:zt,contextMenuRightClickEnabled:sn,contextMenuTriggerMode:je,controller:t,directoriesWithGitChanges:i,dragAndDropEnabled:vn,draggedPathSet:Tu,dragTarget:Sh,gitLaneActive:Wt,gitStatusByPath:n,handleRowDragEnd:Bu,handleRowDragStart:$u,handleRowTouchStart:Gl,ignoredGitDirectories:r,ignoredInheritanceCache:Qe,instanceId:l,itemHeight:c,onKeyDown:Ss,onRowClick:Ds,openContextMenuForRow:Eo,registerButton:ci,registerRenameInput:Ht,renameView:jn,renderDecorationForRow:yr,resolveIcon:kn,shouldSuppressContextMenu:Ch,visualFocusPath:Xl},Yl={...To,registerButton:Ft};return Ce("div",{ref:R,id:Ul,"data-file-tree-context-menu-button-visibility":zt&&ft?Nt:void 0,"data-file-tree-context-menu-trigger-mode":zt?je:void 0,"data-file-tree-has-context-menu-action-lane":zt&&ft?"true":void 0,"data-file-tree-has-git-lane":Wt?"true":void 0,"data-file-tree-virtualized-root":"true",onDragLeave:vn?ba:void 0,onDragOver:vn?ju:void 0,onDrop:vn?Vu:void 0,onKeyDown:Ss,onPointerLeave:zt?Eh:void 0,onPointerOver:zt?Is:void 0,role:"tree",tabIndex:-1,style:{outline:"none",position:"relative"},children:[Ce("style",{"data-file-tree-guide-style":"true",dangerouslySetInnerHTML:{__html:zu}}),Ce("slot",{name:Yf,"data-type":"header-slot"}),g?Ce("div",{"data-file-tree-search-container":!0,"data-open":gr?"true":"false",children:Ce("input",{ref:X,"aria-activedescendant":vi,"aria-controls":Ul,placeholder:"Search…","data-file-tree-search-input":!0,"data-file-tree-search-input-fake-focus":fa?"true":void 0,value:kh,onBlur:()=>{h==="retain"&&!_o.current||t.closeSearch()},onFocus:$r,onPointerDown:$r,onInput:N=>{$r();const ne=N.currentTarget;t.setSearch(ne.value)}})}):null,Ce("div",{ref:U,"data-file-tree-virtualized-scroll":"true",children:[_&&li&&zi.length>0?Ce("div",{"aria-hidden":"true","data-file-tree-sticky-overlay":"true",children:Ce("div",{"data-file-tree-sticky-overlay-content":"true",style:{height:`${Ru}px`},children:zi.map((N,ne)=>Pf(Yl,N.row,`sticky:${fl(N.row)}`,{mode:"sticky",style:{left:"0",position:"absolute",right:"0",top:`${N.top}px`,zIndex:`${zi.length-ne}`}}))})}):null,Ce("div",{ref:L,"data-file-tree-virtualized-list":"true",style:{height:`${jr}px`},children:[Ce("div",{"data-file-tree-virtualized-sticky-offset":"true","aria-hidden":"true",style:{height:`${Ps}px`}}),Ce("div",{"data-file-tree-virtualized-sticky":"true",style:{height:`${xa}px`,top:`${Io}px`,bottom:`${Io}px`},children:[HN(To,rr,xs),ir!=null&&Uu!=null?Pf(To,ir,`parked:${ir.path}`,{isParked:!0,style:{left:"0",opacity:"0",pointerEvents:ko===ir.path?"none":void 0,position:"absolute",right:"0",top:`${Uu}px`}}):null,gi!=null&&_a!=null?Pf(To,gi,`parked-drag:${gi.path}`,{isParked:!0,style:{left:"0",opacity:"0",pointerEvents:"none",position:"absolute",right:"0",top:`${_a}px`}}):null]})]})]}),zt?Ce("div",{ref:I,"data-type":"context-menu-anchor","data-visible":Sa?"true":"false",style:Ao,children:[Ce("button",{ref:E,type:"button","data-type":Sg,"aria-label":"Options","aria-haspopup":"menu","aria-expanded":Fe!=null?"true":"false","data-visible":Do?"true":"false",onMouseDown:N=>{N.preventDefault()},onClick:N=>{if(N.preventDefault(),N.stopPropagation(),Fe!=null){yn();return}Ih()},tabIndex:-1,style:Ql,children:Ce(Gc,{...kn("file-tree-icon-ellipsis")})}),Fe!=null?Ce("slot",{name:al}):null]}):null,Fe!=null?Ce("div",{"data-type":"context-menu-wash","aria-hidden":"true",onMouseDownCapture:N=>{N.preventDefault(),yn()},onTouchStartCapture:N=>{N.preventDefault(),N.stopPropagation(),yn()},onTouchMoveCapture:N=>{N.preventDefault(),N.stopPropagation()},onWheelCapture:N=>{N.preventDefault(),N.stopPropagation()}}):null]})}const J0={hydrateRoot:(e,t)=>{zR(Jg(_b,t),e)},renderRoot:(e,t)=>{e0(Jg(_b,t),e)},unmountRoot:e=>{e0(null,e)}};function af(e,t){J0.renderRoot(e,t)}function WN(e,t){J0.hydrateRoot(e,t)}function GN(e){J0.unmountRoot(e)}var Xn,cs,pr,Lf,Bc,tS,Bb,qN=(Bb=class{constructor(){ye(this,pr);ye(this,Xn,new Map);ye(this,cs,null)}clearAll(){for(const e of x(this,Xn).values())e.remove();x(this,Xn).clear()}clearSlotContent(e){const t=V(this,pr,Lf).call(this,e);t!=null&&(t.remove(),x(this,Xn).delete(e))}setHost(e){if(Y(this,cs,e),e!=null){V(this,pr,tS).call(this,e);for(const[t,n]of x(this,Xn))V(this,pr,Bc).call(this,t,n)}}setSlotContent(e,t){const n=V(this,pr,Lf).call(this,e);if(n===t){t!=null&&(x(this,Xn).set(e,t),V(this,pr,Bc).call(this,e,t));return}if(n==null||n.remove(),t==null){x(this,Xn).delete(e);return}x(this,Xn).set(e,t),V(this,pr,Bc).call(this,e,t)}setSlotHtml(e,t){const n=(t==null?void 0:t.trim())??"";if(n.length===0){this.setSlotContent(e,null);return}const r=V(this,pr,Lf).call(this,e);if(r!=null&&r.innerHTML===n){x(this,Xn).set(e,r),V(this,pr,Bc).call(this,e,r);return}const i=document.createElement("div");i.innerHTML=n,this.setSlotContent(e,i)}},Xn=new WeakMap,cs=new WeakMap,pr=new WeakSet,Lf=function(e){const t=x(this,Xn).get(e)??null;if(t!=null)return t;const n=x(this,cs);if(n==null)return null;for(const r of Array.from(n.children))if(r instanceof HTMLElement&&r.dataset.fileTreeManagedSlot===e)return r;return null},Bc=function(e,t){t.slot=e,t.dataset.fileTreeManagedSlot=e,x(this,cs)!=null&&t.parentNode!==x(this,cs)&&x(this,cs).appendChild(t)},tS=function(e){for(const t of Array.from(e.children)){if(!(t instanceof HTMLElement))continue;const n=t.dataset.fileTreeManagedSlot;n==null||x(this,Xn).has(n)||x(this,Xn).set(n,t)}},Bb);let kb=0;function KN(e){return e!=null&&e.length>0?e:(kb+=1,`pst_ft_${kb}`)}function XN({initialVisibleRowCount:e,itemHeight:t}){return e==null?U_:Math.max(0,e)*(t??V_)}function Sb(e){if(typeof document>"u")return;const t=document.createElement("div");t.innerHTML=e;const n=t.querySelector("svg");return n instanceof SVGElement?n:void 0}function Cb(e){return e.querySelector("#file-tree-icon-chevron")instanceof SVGElement&&e.querySelector("#file-tree-icon-file")instanceof SVGElement&&e.querySelector("#file-tree-icon-dot")instanceof SVGElement&&e.querySelector("#file-tree-icon-lock")instanceof SVGElement}function Eb(e){return Array.from(e.children).filter(t=>t instanceof SVGElement)}var Gm,lo,lt,co,kl,wu,bu,xu,_u,ku,uo,fo,ho,Dr,po,mo,go,fr,Sl,Cl,El,xn,Il,Pl,Xe,nS,ol,Df,s0,rS,Af,iS,oS,sS,aS,a0,l0,lS,cS,QN=(Gm=class{constructor(e){ye(this,Xe);ye(this,lo);ye(this,lt);ye(this,co);ye(this,kl);ye(this,wu);ye(this,bu);ye(this,xu);ye(this,_u);ye(this,ku);ye(this,uo,new qN);ye(this,fo);ye(this,ho);ye(this,Dr);ye(this,po);ye(this,mo);ye(this,go);ye(this,fr);ye(this,Sl);ye(this,Cl);ye(this,El,null);ye(this,xn);ye(this,Il,!1);ye(this,Pl,!1);const{composition:t,density:n,fileTreeSearchMode:r,gitStatus:i,id:s,initialSearchQuery:l,icons:c,itemHeight:d,onSearchChange:f,onSelectionChange:m,overscan:h,renderRowDecoration:g,renaming:y,search:w,searchBlurBehavior:_,searchFakeFocus:C,stickyFolders:I,unsafeCSS:E,initialVisibleRowCount:S,...L}=e;Y(this,lo,t),Y(this,co,KN(s)),Y(this,po,Gw(i)),Y(this,mo,c),Y(this,go,E),Y(this,kl,m),Y(this,wu,g),Y(this,bu,y!=null&&y!==!1),Y(this,xu,_),Y(this,_u,w===!0),Y(this,ku,C===!0),Y(this,fo,yA(n,d)),Y(this,ho,{itemHeight:x(this,fo).itemHeight,overscan:h,stickyFolders:I,initialVisibleRowCount:S}),Y(this,lt,new LR({...L,fileTreeSearchMode:r,initialSearchQuery:l,onSearchChange:f,renaming:y})),Y(this,Cl,x(this,lt).getSelectionVersion()),Y(this,El,x(this,kl)==null?null:this.subscribe(()=>{V(this,Xe,rS).call(this)}))}unmount(){x(this,xn)!=null&&(GN(x(this,xn)),delete x(this,xn).dataset.fileTreeVirtualizedWrapper,Y(this,xn,void 0)),x(this,uo).clearAll(),x(this,uo).setHost(null),x(this,Dr)!=null&&(delete x(this,Dr).dataset.fileTreeVirtualized,V(this,Xe,cS).call(this,x(this,Dr)),Y(this,Dr,void 0))}cleanUp(){var e;this.unmount(),(e=x(this,El))==null||e.call(this),Y(this,El,null),x(this,lt).destroy()}getFileTreeContainer(){return x(this,Dr)}getItem(e){return x(this,lt).getItem(e)}getFocusedItem(){return x(this,lt).getFocusedItem()}getFocusedPath(){return x(this,lt).getFocusedPath()}getSelectedPaths(){return x(this,lt).getSelectedPaths()}getComposition(){return x(this,lo)}getItemHeight(){return x(this,fo).itemHeight}getDensityFactor(){return x(this,fo).factor}subscribe(e){let t=!1;return x(this,lt).subscribe(()=>{if(!t){t=!0;return}e()})}focusPath(e){x(this,lt).focusPath(e)}focusNearestPath(e){return x(this,lt).focusNearestPath(e)}add(e){x(this,lt).add(e)}batch(e){x(this,lt).batch(e)}move(e,t,n){x(this,lt).move(e,t,n)}onMutation(e,t){return x(this,lt).onMutation(e,t)}setSearch(e){x(this,lt).setSearch(e)}openSearch(e){x(this,lt).openSearch(e)}closeSearch(){x(this,lt).closeSearch()}isSearchOpen(){return x(this,lt).isSearchOpen()}getSearchValue(){return x(this,lt).getSearchValue()}getSearchMatchingPaths(){return x(this,lt).getSearchMatchingPaths()}focusNextSearchMatch(){x(this,lt).focusNextSearchMatch()}focusPreviousSearchMatch(){x(this,lt).focusPreviousSearchMatch()}startRenaming(e,t){return x(this,lt).startRenaming(e,t)}remove(e,t){x(this,lt).remove(e,t)}resetPaths(e,t){x(this,lt).resetPaths(e,t)}setComposition(e){Y(this,lo,e);const t=V(this,Xe,Df).call(this);t!=null&&(V(this,Xe,Af).call(this),af(t.wrapper,V(this,Xe,ol).call(this)))}setGitStatus(e){Y(this,po,Gw(e,x(this,po)));const t=V(this,Xe,Df).call(this);t!=null&&af(t.wrapper,V(this,Xe,ol).call(this))}setIcons(e){Y(this,mo,e);const t=V(this,Xe,Df).call(this);t!=null&&(V(this,Xe,s0).call(this,t.host,t.wrapper),af(t.wrapper,V(this,Xe,ol).call(this)))}hydrate({fileTreeContainer:e}){const t=V(this,Xe,l0).call(this,e),n=V(this,Xe,a0).call(this,t);V(this,Xe,Af).call(this),WN(n,V(this,Xe,ol).call(this))}render({containerWrapper:e,fileTreeContainer:t}){const n=V(this,Xe,l0).call(this,t??x(this,Dr),e),r=V(this,Xe,a0).call(this,n);V(this,Xe,Af).call(this),af(r,V(this,Xe,ol).call(this))}},lo=new WeakMap,lt=new WeakMap,co=new WeakMap,kl=new WeakMap,wu=new WeakMap,bu=new WeakMap,xu=new WeakMap,_u=new WeakMap,ku=new WeakMap,uo=new WeakMap,fo=new WeakMap,ho=new WeakMap,Dr=new WeakMap,po=new WeakMap,mo=new WeakMap,go=new WeakMap,fr=new WeakMap,Sl=new WeakMap,Cl=new WeakMap,El=new WeakMap,xn=new WeakMap,Il=new WeakMap,Pl=new WeakMap,Xe=new WeakSet,nS=function(){return{initialViewportHeight:XN({initialVisibleRowCount:x(this,ho).initialVisibleRowCount,itemHeight:x(this,ho).itemHeight}),itemHeight:x(this,ho).itemHeight,overscan:x(this,ho).overscan,stickyFolders:x(this,ho).stickyFolders}},ol=function(){var e,t,n;return{composition:x(this,lo),controller:x(this,lt),gitStatusByPath:(e=x(this,po))==null?void 0:e.statusByPath,ignoredGitDirectories:(t=x(this,po))==null?void 0:t.ignoredDirectoryPaths,directoriesWithGitChanges:(n=x(this,po))==null?void 0:n.directoriesWithChanges,icons:x(this,mo),instanceId:x(this,co),renamingEnabled:x(this,bu),renderRowDecoration:x(this,wu),searchBlurBehavior:x(this,xu),searchEnabled:x(this,_u),searchFakeFocus:x(this,ku),slotHost:x(this,uo),...V(this,Xe,nS).call(this)}},Df=function(){const e=x(this,Dr),t=x(this,xn);return e==null||t==null?null:{host:e,wrapper:t}},s0=function(e,t){const n=e.shadowRoot;n!=null&&(V(this,Xe,iS).call(this,n),V(this,Xe,oS).call(this,n)),V(this,Xe,sS).call(this,t)},rS=function(){const e=x(this,kl);if(e==null)return;const t=x(this,lt).getSelectionVersion();t!==x(this,Cl)&&(Y(this,Cl,t),e(x(this,lt).getSelectedPaths()))},Af=function(){var t,n,r,i;const e=(n=(t=x(this,lo))==null?void 0:t.header)==null?void 0:n.render;if(e!=null){x(this,uo).setSlotContent(Yf,e());return}x(this,uo).setSlotHtml(Yf,((i=(r=x(this,lo))==null?void 0:r.header)==null?void 0:i.html)??null)},iS=function(e){const t=Eb(e).find(r=>Cb(r)),n=Sb(hA(vf(x(this,mo)).set));n!=null&&(t!=null&&t.outerHTML===n.outerHTML||(t!=null?t.replaceWith(n):e.prepend(n)))},oS=function(e){var l;const t=Eb(e),n=t.find(c=>Cb(c)),r=t.filter(c=>c!==n),i=((l=vf(x(this,mo)).spriteSheet)==null?void 0:l.trim())??"";if(i.length===0){for(const c of r)c.remove();return}const s=Sb(i);if(s==null){for(const c of r)c.remove();return}if(!(r.length===1&&r[0].outerHTML===s.outerHTML)){for(const c of r)c.remove();e.appendChild(s)}},sS=function(e){const t=vf(x(this,mo));t.colored&&mA(t.set)?e.dataset.fileTreeColoredIcons="true":delete e.dataset.fileTreeColoredIcons},aS=function(e){var n,r;const t=e.querySelector(`style[${uw}]`);if(x(this,fr)==null&&t instanceof HTMLStyleElement&&Y(this,fr,t),x(this,go)==null||x(this,go)===""){(n=x(this,fr))==null||n.remove(),Y(this,fr,void 0),Y(this,Sl,void 0);return}((r=x(this,fr))==null?void 0:r.parentNode)===e&&x(this,Sl)===x(this,go)||(x(this,fr)??Y(this,fr,document.createElement("style")),x(this,fr).setAttribute(uw,""),x(this,fr).parentNode!==e&&e.appendChild(x(this,fr)),x(this,fr).textContent=bA(x(this,go)),Y(this,Sl,x(this,go)))},a0=function(e){if(x(this,xn)!=null)return x(this,xn);const t=e.shadowRoot;if(t==null)throw new Error("FileTree requires a shadow root");const n=Array.from(t.children).filter(i=>i instanceof HTMLDivElement&&typeof i.dataset.fileTreeId=="string"&&i.dataset.fileTreeId.length>0),r=n.find(i=>i.dataset.fileTreeId===x(this,co))??n[0];return r!=null&&Y(this,co,r.dataset.fileTreeId??x(this,co)),Y(this,xn,r??document.createElement("div")),x(this,xn).dataset.fileTreeId=x(this,co),x(this,xn).dataset.fileTreeVirtualizedWrapper="true",V(this,Xe,s0).call(this,e,x(this,xn)),x(this,xn).parentNode!==t&&t.appendChild(x(this,xn)),x(this,xn)},l0=function(e,t){const n=e??x(this,Dr)??document.createElement(Hc);t!=null&&n.parentNode!==t&&t.appendChild(n);const r=n.shadowRoot??n.attachShadow({mode:"open"});return Eg(n,r),V(this,Xe,aS).call(this,r),n.dataset.fileTreeVirtualized="true",n.style.display="flex",V(this,Xe,lS).call(this,n),x(this,uo).setHost(n),Y(this,Dr,n),n},lS=function(e){e.style.getPropertyValue("--trees-item-height")===""&&(e.style.setProperty("--trees-item-height",`${String(x(this,fo).itemHeight)}px`),Y(this,Il,!0)),e.style.getPropertyValue("--trees-density-override")===""&&(e.style.setProperty("--trees-density-override",String(x(this,fo).factor)),Y(this,Pl,!0))},cS=function(e){x(this,Il)&&(e.style.removeProperty("--trees-item-height"),Y(this,Il,!1)),x(this,Pl)&&(e.style.removeProperty("--trees-density-override"),Y(this,Pl,!1))},F(Gm,"LoadedCustomComponent",CA),Gm);function YN(e){const t=B.useRef(null);return t.current??(t.current=new QN(e)),B.useEffect(()=>{const n=t.current;return()=>{n==null||n.cleanUp(),t.current=null}},[]),{model:t.current}}function JN(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}const ZN=e=>{switch(e){case"success":return nF;case"info":return iF;case"warning":return rF;case"error":return oF;default:return null}},eF=Array(12).fill(0),tF=({visible:e,className:t})=>ge.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},ge.createElement("div",{className:"sonner-spinner"},eF.map((n,r)=>ge.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),nF=ge.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},ge.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),rF=ge.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},ge.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),iF=ge.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},ge.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),oF=ge.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},ge.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),sF=ge.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},ge.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),ge.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),aF=()=>{const[e,t]=ge.useState(document.hidden);return ge.useEffect(()=>{const n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e};let c0=1;class lF{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const n=this.subscribers.indexOf(t);this.subscribers.splice(n,1)}),this.publish=t=>{this.subscribers.forEach(n=>n(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var n;const{message:r,...i}=t,s=typeof(t==null?void 0:t.id)=="number"||((n=t.id)==null?void 0:n.length)>0?t.id:c0++,l=this.toasts.find(d=>d.id===s),c=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(s)&&this.dismissedToasts.delete(s),l?this.toasts=this.toasts.map(d=>d.id===s?(this.publish({...d,...t,id:s,title:r}),{...d,...t,id:s,dismissible:c,title:r}):d):this.addToast({title:r,...i,dismissible:c,id:s}),s},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(n=>n({id:t,dismiss:!0})))):this.toasts.forEach(n=>{this.subscribers.forEach(r=>r({id:n.id,dismiss:!0}))}),t),this.message=(t,n)=>this.create({...n,message:t}),this.error=(t,n)=>this.create({...n,message:t,type:"error"}),this.success=(t,n)=>this.create({...n,type:"success",message:t}),this.info=(t,n)=>this.create({...n,type:"info",message:t}),this.warning=(t,n)=>this.create({...n,type:"warning",message:t}),this.loading=(t,n)=>this.create({...n,type:"loading",message:t}),this.promise=(t,n)=>{if(!n)return;let r;n.loading!==void 0&&(r=this.create({...n,promise:t,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));const i=Promise.resolve(t instanceof Function?t():t);let s=r!==void 0,l;const c=i.then(async f=>{if(l=["resolve",f],ge.isValidElement(f))s=!1,this.create({id:r,type:"default",message:f});else if(uF(f)&&!f.ok){s=!1;const h=typeof n.error=="function"?await n.error(`HTTP error! status: ${f.status}`):n.error,g=typeof n.description=="function"?await n.description(`HTTP error! status: ${f.status}`):n.description,w=typeof h=="object"&&!ge.isValidElement(h)?h:{message:h};this.create({id:r,type:"error",description:g,...w})}else if(f instanceof Error){s=!1;const h=typeof n.error=="function"?await n.error(f):n.error,g=typeof n.description=="function"?await n.description(f):n.description,w=typeof h=="object"&&!ge.isValidElement(h)?h:{message:h};this.create({id:r,type:"error",description:g,...w})}else if(n.success!==void 0){s=!1;const h=typeof n.success=="function"?await n.success(f):n.success,g=typeof n.description=="function"?await n.description(f):n.description,w=typeof h=="object"&&!ge.isValidElement(h)?h:{message:h};this.create({id:r,type:"success",description:g,...w})}}).catch(async f=>{if(l=["reject",f],n.error!==void 0){s=!1;const m=typeof n.error=="function"?await n.error(f):n.error,h=typeof n.description=="function"?await n.description(f):n.description,y=typeof m=="object"&&!ge.isValidElement(m)?m:{message:m};this.create({id:r,type:"error",description:h,...y})}}).finally(()=>{s&&(this.dismiss(r),r=void 0),n.finally==null||n.finally.call(n)}),d=()=>new Promise((f,m)=>c.then(()=>l[0]==="reject"?m(l[1]):f(l[1])).catch(m));return typeof r!="string"&&typeof r!="number"?{unwrap:d}:Object.assign(r,{unwrap:d})},this.custom=(t,n)=>{const r=(n==null?void 0:n.id)||c0++;return this.create({jsx:t(r),id:r,...n}),r},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const Yn=new lF,cF=(e,t)=>{const n=(t==null?void 0:t.id)||c0++;return Yn.addToast({title:e,...t,id:n}),n},uF=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",dF=cF,fF=()=>Yn.toasts,hF=()=>Yn.getActiveToasts(),Ct=Object.assign(dF,{success:Yn.success,info:Yn.info,warning:Yn.warning,error:Yn.error,custom:Yn.custom,message:Yn.message,promise:Yn.promise,dismiss:Yn.dismiss,loading:Yn.loading},{getHistory:fF,getToasts:hF});JN("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function lf(e){return e.label!==void 0}const pF=3,mF="24px",gF="16px",Ib=4e3,vF=356,yF=14,wF=45,bF=200;function Si(...e){return e.filter(Boolean).join(" ")}function xF(e){const[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}const _F=e=>{var t,n,r,i,s,l,c,d,f;const{invert:m,toast:h,unstyled:g,interacting:y,setHeights:w,visibleToasts:_,heights:C,index:I,toasts:E,expanded:S,removeToast:L,defaultRichColors:A,closeButton:R,style:U,cancelButtonStyle:X,actionButtonStyle:H,className:re="",descriptionClassName:de="",duration:te,position:Q,gap:ee,expandByDefault:K,classNames:oe,icons:ie,closeButtonAriaLabel:W="Close toast"}=e,[ce,le]=ge.useState(null),[O,J]=ge.useState(null),[fe,we]=ge.useState(!1),[be,Pe]=ge.useState(!1),[Ne,he]=ge.useState(!1),[Te,Qe]=ge.useState(!1),[pt,mt]=ge.useState(!1),[ct,mn]=ge.useState(0),[Je,Oi]=ge.useState(0),Mr=ge.useRef(h.duration||te||Ib),vs=ge.useRef(null),$t=ge.useRef(null),$i=I===0,oi=I+1<=_,Fe=h.type,er=h.dismissible!==!1,si=h.className||"",Bi=h.descriptionClassName||"",tr=ge.useMemo(()=>C.findIndex(je=>je.toastId===h.id)||0,[C,h.id]),Or=ge.useMemo(()=>{var je;return(je=h.closeButton)!=null?je:R},[h.closeButton,R]),nr=ge.useMemo(()=>h.duration||te||Ib,[h.duration,te]),ji=ge.useRef(0),gn=ge.useRef(0),ai=ge.useRef(0),mr=ge.useRef(null),[da,ys]=Q.split("-"),fa=ge.useMemo(()=>C.reduce((je,ft,Nt)=>Nt>=tr?je:je+ft.height,0),[C,tr]),Vi=aF(),_o=h.invert||m,$r=Fe==="loading";gn.current=ge.useMemo(()=>tr*ee+fa,[tr,fa]),ge.useEffect(()=>{Mr.current=nr},[nr]),ge.useEffect(()=>{we(!0)},[]),ge.useEffect(()=>{const je=$t.current;if(je){const ft=je.getBoundingClientRect().height;return Oi(ft),w(Nt=>[{toastId:h.id,height:ft,position:h.position},...Nt]),()=>w(Nt=>Nt.filter(sn=>sn.toastId!==h.id))}},[w,h.id]),ge.useLayoutEffect(()=>{if(!fe)return;const je=$t.current,ft=je.style.height;je.style.height="auto";const Nt=je.getBoundingClientRect().height;je.style.height=ft,Oi(Nt),w(sn=>sn.find(Ft=>Ft.toastId===h.id)?sn.map(Ft=>Ft.toastId===h.id?{...Ft,height:Nt}:Ft):[{toastId:h.id,height:Nt,position:h.position},...sn])},[fe,h.title,h.description,w,h.id,h.jsx,h.action,h.cancel]);const $n=ge.useCallback(()=>{Pe(!0),mn(gn.current),w(je=>je.filter(ft=>ft.toastId!==h.id)),setTimeout(()=>{L(h)},bF)},[h,L,w,gn]);ge.useEffect(()=>{if(h.promise&&Fe==="loading"||h.duration===1/0||h.type==="loading")return;let je;return S||y||Vi?(()=>{if(ai.current<ji.current){const sn=new Date().getTime()-ji.current;Mr.current=Mr.current-sn}ai.current=new Date().getTime()})():(()=>{Mr.current!==1/0&&(ji.current=new Date().getTime(),je=setTimeout(()=>{h.onAutoClose==null||h.onAutoClose.call(h,h),$n()},Mr.current))})(),()=>clearTimeout(je)},[S,y,h,Fe,Vi,$n]),ge.useEffect(()=>{h.delete&&($n(),h.onDismiss==null||h.onDismiss.call(h,h))},[$n,h.delete]);function ws(){var je;if(ie!=null&&ie.loading){var ft;return ge.createElement("div",{className:Si(oe==null?void 0:oe.loader,h==null||(ft=h.classNames)==null?void 0:ft.loader,"sonner-loader"),"data-visible":Fe==="loading"},ie.loading)}return ge.createElement(tF,{className:Si(oe==null?void 0:oe.loader,h==null||(je=h.classNames)==null?void 0:je.loader),visible:Fe==="loading"})}const li=h.icon||(ie==null?void 0:ie[Fe])||ZN(Fe);var Br,zt;return ge.createElement("li",{tabIndex:0,ref:$t,className:Si(re,si,oe==null?void 0:oe.toast,h==null||(t=h.classNames)==null?void 0:t.toast,oe==null?void 0:oe.default,oe==null?void 0:oe[Fe],h==null||(n=h.classNames)==null?void 0:n[Fe]),"data-sonner-toast":"","data-rich-colors":(Br=h.richColors)!=null?Br:A,"data-styled":!(h.jsx||h.unstyled||g),"data-mounted":fe,"data-promise":!!h.promise,"data-swiped":pt,"data-removed":be,"data-visible":oi,"data-y-position":da,"data-x-position":ys,"data-index":I,"data-front":$i,"data-swiping":Ne,"data-dismissible":er,"data-type":Fe,"data-invert":_o,"data-swipe-out":Te,"data-swipe-direction":O,"data-expanded":!!(S||K&&fe),"data-testid":h.testId,style:{"--index":I,"--toasts-before":I,"--z-index":E.length-I,"--offset":`${be?ct:gn.current}px`,"--initial-height":K?"auto":`${Je}px`,...U,...h.style},onDragEnd:()=>{he(!1),le(null),mr.current=null},onPointerDown:je=>{je.button!==2&&($r||!er||(vs.current=new Date,mn(gn.current),je.target.setPointerCapture(je.pointerId),je.target.tagName!=="BUTTON"&&(he(!0),mr.current={x:je.clientX,y:je.clientY})))},onPointerUp:()=>{var je,ft,Nt;if(Te||!er)return;mr.current=null;const sn=Number(((je=$t.current)==null?void 0:je.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),ci=Number(((ft=$t.current)==null?void 0:ft.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),Ft=new Date().getTime()-((Nt=vs.current)==null?void 0:Nt.getTime()),Ht=ce==="x"?sn:ci,Bn=Math.abs(Ht)/Ft;if(Math.abs(Ht)>=wF||Bn>.11){mn(gn.current),h.onDismiss==null||h.onDismiss.call(h,h),J(ce==="x"?sn>0?"right":"left":ci>0?"down":"up"),$n(),Qe(!0);return}else{var Wt,kn;(Wt=$t.current)==null||Wt.style.setProperty("--swipe-amount-x","0px"),(kn=$t.current)==null||kn.style.setProperty("--swipe-amount-y","0px")}mt(!1),he(!1),le(null)},onPointerMove:je=>{var ft,Nt,sn;if(!mr.current||!er||((ft=window.getSelection())==null?void 0:ft.toString().length)>0)return;const Ft=je.clientY-mr.current.y,Ht=je.clientX-mr.current.x;var Bn;const Wt=(Bn=e.swipeDirections)!=null?Bn:xF(Q);!ce&&(Math.abs(Ht)>1||Math.abs(Ft)>1)&&le(Math.abs(Ht)>Math.abs(Ft)?"x":"y");let kn={x:0,y:0};const jn=Yt=>1/(1.5+Math.abs(Yt)/20);if(ce==="y"){if(Wt.includes("top")||Wt.includes("bottom"))if(Wt.includes("top")&&Ft<0||Wt.includes("bottom")&&Ft>0)kn.y=Ft;else{const Yt=Ft*jn(Ft);kn.y=Math.abs(Yt)<Math.abs(Ft)?Yt:Ft}}else if(ce==="x"&&(Wt.includes("left")||Wt.includes("right")))if(Wt.includes("left")&&Ht<0||Wt.includes("right")&&Ht>0)kn.x=Ht;else{const Yt=Ht*jn(Ht);kn.x=Math.abs(Yt)<Math.abs(Ht)?Yt:Ht}(Math.abs(kn.x)>0||Math.abs(kn.y)>0)&&mt(!0),(Nt=$t.current)==null||Nt.style.setProperty("--swipe-amount-x",`${kn.x}px`),(sn=$t.current)==null||sn.style.setProperty("--swipe-amount-y",`${kn.y}px`)}},Or&&!h.jsx&&Fe!=="loading"?ge.createElement("button",{"aria-label":W,"data-disabled":$r,"data-close-button":!0,onClick:$r||!er?()=>{}:()=>{$n(),h.onDismiss==null||h.onDismiss.call(h,h)},className:Si(oe==null?void 0:oe.closeButton,h==null||(r=h.classNames)==null?void 0:r.closeButton)},(zt=ie==null?void 0:ie.close)!=null?zt:sF):null,(Fe||h.icon||h.promise)&&h.icon!==null&&((ie==null?void 0:ie[Fe])!==null||h.icon)?ge.createElement("div",{"data-icon":"",className:Si(oe==null?void 0:oe.icon,h==null||(i=h.classNames)==null?void 0:i.icon)},h.promise||h.type==="loading"&&!h.icon?h.icon||ws():null,h.type!=="loading"?li:null):null,ge.createElement("div",{"data-content":"",className:Si(oe==null?void 0:oe.content,h==null||(s=h.classNames)==null?void 0:s.content)},ge.createElement("div",{"data-title":"",className:Si(oe==null?void 0:oe.title,h==null||(l=h.classNames)==null?void 0:l.title)},h.jsx?h.jsx:typeof h.title=="function"?h.title():h.title),h.description?ge.createElement("div",{"data-description":"",className:Si(de,Bi,oe==null?void 0:oe.description,h==null||(c=h.classNames)==null?void 0:c.description)},typeof h.description=="function"?h.description():h.description):null),ge.isValidElement(h.cancel)?h.cancel:h.cancel&&lf(h.cancel)?ge.createElement("button",{"data-button":!0,"data-cancel":!0,style:h.cancelButtonStyle||X,onClick:je=>{lf(h.cancel)&&er&&(h.cancel.onClick==null||h.cancel.onClick.call(h.cancel,je),$n())},className:Si(oe==null?void 0:oe.cancelButton,h==null||(d=h.classNames)==null?void 0:d.cancelButton)},h.cancel.label):null,ge.isValidElement(h.action)?h.action:h.action&&lf(h.action)?ge.createElement("button",{"data-button":!0,"data-action":!0,style:h.actionButtonStyle||H,onClick:je=>{lf(h.action)&&(h.action.onClick==null||h.action.onClick.call(h.action,je),!je.defaultPrevented&&$n())},className:Si(oe==null?void 0:oe.actionButton,h==null||(f=h.classNames)==null?void 0:f.actionButton)},h.action.label):null)};function Pb(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function kF(e,t){const n={};return[e,t].forEach((r,i)=>{const s=i===1,l=s?"--mobile-offset":"--offset",c=s?gF:mF;function d(f){["top","right","bottom","left"].forEach(m=>{n[`${l}-${m}`]=typeof f=="number"?`${f}px`:f})}typeof r=="number"||typeof r=="string"?d(r):typeof r=="object"?["top","right","bottom","left"].forEach(f=>{r[f]===void 0?n[`${l}-${f}`]=c:n[`${l}-${f}`]=typeof r[f]=="number"?`${r[f]}px`:r[f]}):d(c)}),n}const SF=ge.forwardRef(function(t,n){const{id:r,invert:i,position:s="bottom-right",hotkey:l=["altKey","KeyT"],expand:c,closeButton:d,className:f,offset:m,mobileOffset:h,theme:g="light",richColors:y,duration:w,style:_,visibleToasts:C=pF,toastOptions:I,dir:E=Pb(),gap:S=yF,icons:L,containerAriaLabel:A="Notifications"}=t,[R,U]=ge.useState([]),X=ge.useMemo(()=>r?R.filter(fe=>fe.toasterId===r):R.filter(fe=>!fe.toasterId),[R,r]),H=ge.useMemo(()=>Array.from(new Set([s].concat(X.filter(fe=>fe.position).map(fe=>fe.position)))),[X,s]),[re,de]=ge.useState([]),[te,Q]=ge.useState(!1),[ee,K]=ge.useState(!1),[oe,ie]=ge.useState(g!=="system"?g:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),W=ge.useRef(null),ce=l.join("+").replace(/Key/g,"").replace(/Digit/g,""),le=ge.useRef(null),O=ge.useRef(!1),J=ge.useCallback(fe=>{U(we=>{var be;return(be=we.find(Pe=>Pe.id===fe.id))!=null&&be.delete||Yn.dismiss(fe.id),we.filter(({id:Pe})=>Pe!==fe.id)})},[]);return ge.useEffect(()=>Yn.subscribe(fe=>{if(fe.dismiss){requestAnimationFrame(()=>{U(we=>we.map(be=>be.id===fe.id?{...be,delete:!0}:be))});return}setTimeout(()=>{l5.flushSync(()=>{U(we=>{const be=we.findIndex(Pe=>Pe.id===fe.id);return be!==-1?[...we.slice(0,be),{...we[be],...fe},...we.slice(be+1)]:[fe,...we]})})})}),[R]),ge.useEffect(()=>{if(g!=="system"){ie(g);return}if(g==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?ie("dark"):ie("light")),typeof window>"u")return;const fe=window.matchMedia("(prefers-color-scheme: dark)");try{fe.addEventListener("change",({matches:we})=>{ie(we?"dark":"light")})}catch{fe.addListener(({matches:be})=>{try{ie(be?"dark":"light")}catch(Pe){console.error(Pe)}})}},[g]),ge.useEffect(()=>{R.length<=1&&Q(!1)},[R]),ge.useEffect(()=>{const fe=we=>{var be;if(l.every(he=>we[he]||we.code===he)){var Ne;Q(!0),(Ne=W.current)==null||Ne.focus()}we.code==="Escape"&&(document.activeElement===W.current||(be=W.current)!=null&&be.contains(document.activeElement))&&Q(!1)};return document.addEventListener("keydown",fe),()=>document.removeEventListener("keydown",fe)},[l]),ge.useEffect(()=>{if(W.current)return()=>{le.current&&(le.current.focus({preventScroll:!0}),le.current=null,O.current=!1)}},[W.current]),ge.createElement("section",{ref:n,"aria-label":`${A} ${ce}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},H.map((fe,we)=>{var be;const[Pe,Ne]=fe.split("-");return X.length?ge.createElement("ol",{key:fe,dir:E==="auto"?Pb():E,tabIndex:-1,ref:W,className:f,"data-sonner-toaster":!0,"data-sonner-theme":oe,"data-y-position":Pe,"data-x-position":Ne,style:{"--front-toast-height":`${((be=re[0])==null?void 0:be.height)||0}px`,"--width":`${vF}px`,"--gap":`${S}px`,..._,...kF(m,h)},onBlur:he=>{O.current&&!he.currentTarget.contains(he.relatedTarget)&&(O.current=!1,le.current&&(le.current.focus({preventScroll:!0}),le.current=null))},onFocus:he=>{he.target instanceof HTMLElement&&he.target.dataset.dismissible==="false"||O.current||(O.current=!0,le.current=he.relatedTarget)},onMouseEnter:()=>Q(!0),onMouseMove:()=>Q(!0),onMouseLeave:()=>{ee||Q(!1)},onDragEnd:()=>Q(!1),onPointerDown:he=>{he.target instanceof HTMLElement&&he.target.dataset.dismissible==="false"||K(!0)},onPointerUp:()=>K(!1)},X.filter(he=>!he.position&&we===0||he.position===fe).map((he,Te)=>{var Qe,pt;return ge.createElement(_F,{key:he.id,icons:L,index:Te,toast:he,defaultRichColors:y,duration:(Qe=I==null?void 0:I.duration)!=null?Qe:w,className:I==null?void 0:I.className,descriptionClassName:I==null?void 0:I.descriptionClassName,invert:i,visibleToasts:C,closeButton:(pt=I==null?void 0:I.closeButton)!=null?pt:d,interacting:ee,position:fe,style:I==null?void 0:I.style,unstyled:I==null?void 0:I.unstyled,classNames:I==null?void 0:I.classNames,cancelButtonStyle:I==null?void 0:I.cancelButtonStyle,actionButtonStyle:I==null?void 0:I.actionButtonStyle,closeButtonAriaLabel:I==null?void 0:I.closeButtonAriaLabel,removeToast:J,toasts:X.filter(mt=>mt.position==he.position),heights:re.filter(mt=>mt.position==he.position),setHeights:de,expandByDefault:c,gap:S,expanded:te,swipeDirections:t.swipeDirections})})):null}))}),Lb=e=>{let t;const n=new Set,r=(f,m)=>{const h=typeof f=="function"?f(t):f;if(!Object.is(h,t)){const g=t;t=m??(typeof h!="object"||h===null)?h:Object.assign({},t,h),n.forEach(y=>y(t,g))}},i=()=>t,c={setState:r,getState:i,getInitialState:()=>d,subscribe:f=>(n.add(f),()=>n.delete(f))},d=t=e(r,i,c);return c},CF=(e=>e?Lb(e):Lb),EF=e=>e;function IF(e,t=EF){const n=ge.useSyncExternalStore(e.subscribe,ge.useCallback(()=>t(e.getState()),[e,t]),ge.useCallback(()=>t(e.getInitialState()),[e,t]));return ge.useDebugValue(n),n}const Db=e=>{const t=CF(e),n=r=>IF(t,r);return Object.assign(n,t),n},uS=(e=>e?Db(e):Db);function zm(e){const t=window.document.documentElement;if(t.classList.remove("light","dark"),e==="system"){const n=window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light";t.classList.add(n)}else t.classList.add(e)}const _h=uS(e=>({theme:localStorage.getItem("wtui-theme")||"system",setTheme:t=>{localStorage.setItem("wtui-theme",t),e({theme:t}),zm(t)},initTheme:()=>{const t=localStorage.getItem("wtui-theme")||"system";zm(t);const n=window.matchMedia("(prefers-color-scheme: dark)"),r=()=>{_h.getState().theme==="system"&&zm("system")};n.addEventListener("change",r)}}));function Ab(e){const t=new Map;if(!e)return t;const n=e.split(`
2243
+ `);let r=[],i="";const s=()=>{i&&r.length>0&&t.set(i,r.join(`
2244
+ `)),r=[],i=""};for(const l of n){if(l.startsWith("diff --git ")){s();const c=l.match(/^diff --git a\/.+ b\/(.+)$/);i=(c==null?void 0:c[1])??""}r.push(l)}return s(),t}const PF={A:"added",M:"modified",D:"deleted",R:"renamed",C:"added",U:"untracked","?":"untracked"},LF={colorScheme:"light","--trees-theme-sidebar-bg":"#ffffff","--trees-theme-sidebar-fg":"#1e293b","--trees-theme-sidebar-border":"#e2e8f0","--trees-theme-list-hover-bg":"#f8fafc","--trees-theme-list-active-selection-bg":"#eff6ff","--trees-theme-list-active-selection-fg":"#1e293b","--trees-theme-git-added-fg":"#16a34a","--trees-theme-git-modified-fg":"#2563eb","--trees-theme-git-deleted-fg":"#dc2626"},DF={colorScheme:"dark","--trees-theme-sidebar-bg":"#0f172a","--trees-theme-sidebar-fg":"#e2e8f0","--trees-theme-sidebar-border":"#1e293b","--trees-theme-list-hover-bg":"rgba(15,23,42,0.4)","--trees-theme-list-active-selection-bg":"rgba(30,58,138,0.3)","--trees-theme-list-active-selection-fg":"#e2e8f0","--trees-theme-git-added-fg":"#4ade80","--trees-theme-git-modified-fg":"#60a5fa","--trees-theme-git-deleted-fg":"#f87171"};function Hm({title:e,titleColor:t,icon:n,count:r,defaultOpen:i=!0,children:s}){const[l,c]=B.useState(i);return P.jsxs("div",{"trae-inspector-start-line":"94","trae-inspector-start-column":"4","trae-inspector-end-line":"105","trae-inspector-end-column":"10","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",children:[P.jsxs("button",{"trae-inspector-start-line":"95","trae-inspector-start-column":"6","trae-inspector-end-line":"103","trae-inspector-end-column":"15","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",onClick:()=>c(!l),className:`w-full flex items-center gap-1 px-2 py-1 text-[11px] font-semibold uppercase tracking-wide ${t} hover:bg-slate-50 dark:hover:bg-slate-900/40 shrink-0`,children:[l?P.jsx(g5,{className:"h-3 w-3"}):P.jsx(y5,{className:"h-3 w-3"}),n,e,r!=null&&P.jsx("span",{"trae-inspector-start-line":"102","trae-inspector-start-column":"26","trae-inspector-end-line":"102","trae-inspector-end-column":"125","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"ml-auto font-normal text-slate-400 dark:text-slate-500 normal-case",children:r})]}),l&&s]})}function Tb({files:e,isDark:t,onSelect:n,group:r}){const i=B.useMemo(()=>e.map(f=>f.path),[e]),s=B.useMemo(()=>e.map(f=>{var m;return{path:f.path,status:PF[(m=f.status[0])==null?void 0:m.toUpperCase()]??"modified"}}),[e]),{model:l}=YN({paths:i,gitStatus:s,initialExpansion:"open",flattenEmptyDirectories:!0,density:"compact",icons:{set:"standard",colored:!0},initialVisibleRowCount:i.length+10,onSelectionChange:B.useCallback(f=>{const m=f[0];m&&e.some(h=>h.path===m)&&n({path:m,group:r})},[e,n,r])}),c=new Set(e.map(f=>f.path.substring(0,f.path.lastIndexOf("/"))).filter(Boolean)).size,d=Math.max((e.length+c)*24,48);return P.jsx(c7,{model:l,style:{height:`${d}px`,...t?DF:LF}})}function AF({graphText:e}){if(!e)return null;const t=e.split(`
2245
+ `).filter(n=>n.length>0);return P.jsx("pre",{"trae-inspector-start-line":"171","trae-inspector-start-column":"4","trae-inspector-end-line":"188","trae-inspector-end-column":"10","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"font-mono text-[11px] leading-5 px-1 py-1 text-slate-700 dark:text-slate-300 whitespace-pre overflow-x-auto",children:t.map((n,r)=>{const i=n.match(/^([* |/\\]+?)(\s[a-f0-9]{7,}.*)$/i);return i?P.jsxs("div",{"trae-inspector-start-line":"177","trae-inspector-start-column":"12","trae-inspector-end-line":"180","trae-inspector-end-column":"18","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",children:[P.jsx("span",{"trae-inspector-start-line":"178","trae-inspector-start-column":"14","trae-inspector-end-line":"178","trae-inspector-end-column":"82","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-blue-400 dark:text-blue-500",children:i[1]}),P.jsx("span",{"trae-inspector-start-line":"179","trae-inspector-start-column":"14","trae-inspector-end-line":"179","trae-inspector-end-column":"37","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",children:i[2]})]},r):P.jsx("div",{"trae-inspector-start-line":"185","trae-inspector-start-column":"10","trae-inspector-end-line":"185","trae-inspector-end-column":"80","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-blue-400 dark:text-blue-500",children:n},r)})})}function TF(e,t,n){const[r,i]=B.useState(e),s=B.useRef(!1),l=B.useRef(0),c=B.useRef(0),d=B.useCallback(f=>{f.preventDefault(),s.current=!0,l.current=f.clientX,c.current=r;const m=g=>{if(!s.current)return;const y=g.clientX-l.current;i(Math.max(t,Math.min(n,c.current+y)))},h=()=>{s.current=!1,document.removeEventListener("mousemove",m),document.removeEventListener("mouseup",h),document.body.style.cursor="",document.body.style.userSelect=""};document.body.style.cursor="col-resize",document.body.style.userSelect="none",document.addEventListener("mousemove",m),document.addEventListener("mouseup",h)},[r,t,n]);return{width:r,onMouseDown:d}}function RF({open:e,onClose:t,worktreePath:n,diffInfo:r,loading:i}){const{t:s}=Iu(),l=_h(R=>R.theme),[c,d]=B.useState(null),{width:f,onMouseDown:m}=TF(260,160,640),h=l==="system"?"system":l==="dark"?"dark":"light",g=l==="dark"||l==="system"&&typeof window<"u"&&window.matchMedia("(prefers-color-scheme: dark)").matches,y=r==null?void 0:r.staged,w=r==null?void 0:r.unstaged,_=(r==null?void 0:r.commitGraph)??"",C=[y==null?void 0:y.diff,w==null?void 0:w.diff].filter(Boolean).join(`
2246
+ `),I=((y==null?void 0:y.files.length)??0)>0||((w==null?void 0:w.files.length)??0)>0,E=B.useMemo(()=>Ab((y==null?void 0:y.diff)??""),[y==null?void 0:y.diff]),S=B.useMemo(()=>Ab((w==null?void 0:w.diff)??""),[w==null?void 0:w.diff]);B.useEffect(()=>{if(!r){d(null);return}const R=r.staged.files[0]??r.unstaged.files[0];d(R?{path:R.path,group:r.staged.files[0]?"staged":"unstaged"}:null)},[r]);const L=B.useMemo(()=>c?(c.group==="staged"?E:S).get(c.path)??null:null,[c,E,S]),A=async()=>{try{await navigator.clipboard.writeText(L||C),Ct.success(s("diff.toast.copied"))}catch{Ct.error(s("diff.toast.copyFailed"))}};return P.jsx(mx,{title:s("diff.title"),open:e,onClose:t,size:"full",footer:P.jsxs(P.Fragment,{children:[P.jsxs(ot,{variant:"secondary",size:"sm",onClick:A,disabled:!C,children:[P.jsx(Xm,{className:"h-4 w-4"}),s("diff.copyDiff")]}),P.jsx(ot,{variant:"secondary",size:"sm",onClick:t,children:s("diff.close")})]}),children:P.jsxs("div",{"trae-inspector-start-line":"292","trae-inspector-start-column":"6","trae-inspector-end-line":"378","trae-inspector-end-column":"12","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"max-h-[75vh]",children:[P.jsx("div",{"trae-inspector-start-line":"293","trae-inspector-start-column":"8","trae-inspector-end-line":"293","trae-inspector-end-column":"112","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-xs font-mono text-slate-500 dark:text-slate-400 truncate mb-2",children:n}),i?P.jsxs("div",{"trae-inspector-start-line":"296","trae-inspector-start-column":"10","trae-inspector-end-line":"299","trae-inspector-end-column":"16","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"space-y-2",children:[P.jsx("div",{"trae-inspector-start-line":"297","trae-inspector-start-column":"12","trae-inspector-end-line":"297","trae-inspector-end-column":"88","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"h-5 animate-pulse rounded bg-slate-100 dark:bg-slate-900"}),P.jsx("div",{"trae-inspector-start-line":"298","trae-inspector-start-column":"12","trae-inspector-end-line":"298","trae-inspector-end-column":"94","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"h-5 animate-pulse rounded bg-slate-100 dark:bg-slate-900 w-3/4"})]}):!I&&!_?P.jsx("div",{"trae-inspector-start-line":"301","trae-inspector-start-column":"10","trae-inspector-end-line":"301","trae-inspector-end-column":"97","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-sm text-slate-500 dark:text-slate-400",children:s("diff.noChanges")}):P.jsxs("div",{"trae-inspector-start-line":"303","trae-inspector-start-column":"10","trae-inspector-end-line":"376","trae-inspector-end-column":"16","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex rounded-lg border border-slate-200 dark:border-slate-800 overflow-hidden",style:{height:"calc(75vh - 40px)"},children:[P.jsxs("div",{"trae-inspector-start-line":"305","trae-inspector-start-column":"12","trae-inspector-end-line":"347","trae-inspector-end-column":"18","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"shrink-0 flex flex-col bg-white dark:bg-slate-950",style:{width:`${f}px`},children:[P.jsxs("div",{"trae-inspector-start-line":"307","trae-inspector-start-column":"14","trae-inspector-end-line":"330","trae-inspector-end-column":"20","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex-1 overflow-y-auto min-h-0",children:[y&&y.files.length>0&&P.jsx(Hm,{title:s("diff.stagedFiles"),titleColor:"text-emerald-600 dark:text-emerald-400",count:y.files.length,children:P.jsx(Tb,{files:y.files,isDark:g,onSelect:d,group:"staged"})}),w&&w.files.length>0&&P.jsxs(P.Fragment,{children:[y&&y.files.length>0&&P.jsx("div",{"trae-inspector-start-line":"320","trae-inspector-start-column":"58","trae-inspector-end-line":"320","trae-inspector-end-column":"125","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"border-t border-slate-200 dark:border-slate-800"}),P.jsx(Hm,{title:s("diff.unstagedFiles"),titleColor:"text-amber-600 dark:text-amber-400",count:w.files.length,children:P.jsx(Tb,{files:w.files,isDark:g,onSelect:d,group:"unstaged"})})]})]}),_&&P.jsx("div",{"trae-inspector-start-line":"334","trae-inspector-start-column":"16","trae-inspector-end-line":"345","trae-inspector-end-column":"22","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"shrink-0 border-t border-slate-200 dark:border-slate-800",children:P.jsx(Hm,{title:s("diff.commits"),titleColor:"text-slate-500 dark:text-slate-400",icon:P.jsx(P5,{className:"h-3 w-3"}),defaultOpen:!I,children:P.jsx("div",{"trae-inspector-start-line":"341","trae-inspector-start-column":"20","trae-inspector-end-line":"343","trae-inspector-end-column":"26","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"max-h-64 overflow-auto",children:P.jsx(AF,{graphText:_})})})})]}),P.jsx("div",{"trae-inspector-start-line":"350","trae-inspector-start-column":"12","trae-inspector-end-line":"353","trae-inspector-end-column":"14","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"w-1 shrink-0 cursor-col-resize bg-slate-200 dark:bg-slate-800 hover:bg-blue-400 dark:hover:bg-blue-500 transition-colors",onMouseDown:m}),P.jsx("div",{"trae-inspector-start-line":"356","trae-inspector-start-column":"12","trae-inspector-end-line":"375","trae-inspector-end-column":"18","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex-1 min-w-0 overflow-auto bg-white dark:bg-slate-950",children:L?P.jsx(t7,{patch:L,disableWorkerPool:!0,options:{theme:{dark:"github-dark",light:"github-light"},themeType:h}}):c?P.jsx("div",{"trae-inspector-start-line":"367","trae-inspector-start-column":"16","trae-inspector-end-line":"369","trae-inspector-end-column":"22","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex items-center justify-center h-full text-sm text-slate-400 dark:text-slate-500",children:s("diff.noDiffContent")}):P.jsx("div",{"trae-inspector-start-line":"371","trae-inspector-start-column":"16","trae-inspector-end-line":"373","trae-inspector-end-column":"22","trae-inspector-file-path":"src/components/DiffPreviewModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex items-center justify-center h-full text-sm text-slate-400 dark:text-slate-500",children:s("diff.selectFile")})})]})]})})}async function Tf(e){return await(await fetch(e)).json()}async function Tc(e,t){return await(await fetch(e,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)})).json()}async function Rb(e,t){return await(await fetch(e,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)})).json()}async function NF(e){return await(await fetch(e,{method:"DELETE"})).json()}const Qn=uS((e,t)=>({loading:!1,items:[],branches:[],selectedId:void 0,select:n=>e({selectedId:n}),refresh:async()=>{e({loading:!0});try{const n=await Tf("/api/worktrees");if(n.ok){e({items:n.data});const r=t().selectedId;r&&!n.data.some(i=>i.id===r)&&e({selectedId:void 0})}}finally{e({loading:!1})}},create:async n=>{const r=await Tc("/api/worktrees",n);return r.ok?(await t().refresh(),r.data):null},remove:async(n,r)=>{const i=r?`/api/worktrees/${encodeURIComponent(n)}?force=1`:`/api/worktrees/${encodeURIComponent(n)}`,s=await NF(i);if(!s.ok){const l=s.error;return{success:!1,error:l.details||l.message}}return await t().refresh(),{success:!0}},open:async(n,r)=>(await Tc(`/api/worktrees/${encodeURIComponent(n)}/open`,{type:r||"folder"})).ok,lock:async n=>(await Tc(`/api/worktrees/${encodeURIComponent(n)}/lock`,{})).ok?(await t().refresh(),!0):!1,unlock:async n=>(await Tc(`/api/worktrees/${encodeURIComponent(n)}/unlock`,{})).ok?(await t().refresh(),!0):!1,prune:async()=>(await Tc("/api/worktrees/prune",{})).ok?(await t().refresh(),!0):!1,fetchBranches:async()=>{const n=await Tf("/api/branches");n.ok&&e({branches:n.data})},fetchStagedDiff:async n=>{const r=await Tf(`/api/worktrees/${encodeURIComponent(n)}/staged`);return r.ok?r.data:null}}));function FF(e){return e.length<=70?e:`${e.slice(0,28)}…${e.slice(-38)}`}function MF(){const{t:e}=Iu(),t=Qn(K=>K.loading),n=Qn(K=>K.items),r=Qn(K=>K.selectedId),i=Qn(K=>K.refresh),s=Qn(K=>K.select),l=Qn(K=>K.remove),c=Qn(K=>K.open),d=Qn(K=>K.lock),f=Qn(K=>K.unlock),m=Qn(K=>K.fetchStagedDiff),[h,g]=B.useState(null),[y,w]=B.useState(!1),[_,C]=B.useState(!1),[I,E]=B.useState(null),[S,L]=B.useState(null),[A,R]=B.useState(!1),U=B.useMemo(()=>n.find(K=>K.id===r),[n,r]),X=B.useMemo(()=>n.find(K=>K.id===h),[n,h]),H=B.useMemo(()=>n.find(K=>K.id===I),[n,I]);B.useEffect(()=>{i()},[i]);const re=()=>{g(null),w(!1),C(!1)},de=async K=>{E(K),L(null),R(!0);try{const oe=await m(K);oe&&L(oe)}finally{R(!1)}},te=()=>{E(null),L(null)},Q=async()=>{if(h){C(!0);try{const K=await l(h,y);if(K.success)Ct.success(e(y?"worktrees.toast.forceDeleteSuccess":"worktrees.toast.deleteSuccess")),re();else{const oe=K.error||"";oe.toLowerCase().includes("force")||oe.includes("modified")||oe.includes("untracked")?(w(!0),Ct.error(e("worktrees.toast.deleteFailed"),{description:e("worktrees.toast.deleteWarning")})):Ct.error(e("worktrees.toast.deleteFailed"),{description:oe})}}catch(K){const oe=K instanceof Error?K.message:String(K);Ct.error(e("worktrees.toast.deleteFailed"),{description:oe})}finally{C(!1)}}},ee=async K=>{try{await navigator.clipboard.writeText(K),Ct.success(e("worktrees.toast.copySuccess"))}catch{Ct.error(e("worktrees.toast.copyFailed"))}};return P.jsxs("div",{"trae-inspector-start-line":"104","trae-inspector-start-column":"4","trae-inspector-end-line":"390","trae-inspector-end-column":"10","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mx-auto w-full max-w-screen-xl px-4 py-6",children:[P.jsxs("div",{"trae-inspector-start-line":"105","trae-inspector-start-column":"6","trae-inspector-end-line":"125","trae-inspector-end-column":"12","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex items-start justify-between gap-4",children:[P.jsxs("div",{"trae-inspector-start-line":"106","trae-inspector-start-column":"8","trae-inspector-end-line":"109","trae-inspector-end-column":"14","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"min-w-0",children:[P.jsx("div",{"trae-inspector-start-line":"107","trae-inspector-start-column":"10","trae-inspector-end-line":"107","trae-inspector-end-column":"112","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-lg font-semibold text-slate-900 dark:text-slate-100",children:e("worktrees.title")}),P.jsx("div",{"trae-inspector-start-line":"108","trae-inspector-start-column":"10","trae-inspector-end-line":"108","trae-inspector-end-column":"115","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-1 truncate text-xs text-slate-500 dark:text-slate-400",children:e("worktrees.subtitle")})]}),P.jsxs("div",{"trae-inspector-start-line":"110","trae-inspector-start-column":"8","trae-inspector-end-line":"124","trae-inspector-end-column":"14","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex shrink-0 items-center gap-2",children:[P.jsx(wo,{to:"/settings",children:P.jsx(ot,{variant:"ghost",size:"sm",children:P.jsx(X5,{className:"h-4 w-4"})})}),P.jsx(ot,{variant:"secondary",size:"sm",onClick:i,disabled:t,children:P.jsx(z5,{className:t?"h-4 w-4 animate-spin":"h-4 w-4"})}),P.jsx(wo,{to:"/create",children:P.jsx(ot,{variant:"primary",size:"sm",children:P.jsx(V5,{className:"h-4 w-4"})})})]})]}),P.jsxs("div",{"trae-inspector-start-line":"127","trae-inspector-start-column":"6","trae-inspector-end-line":"348","trae-inspector-end-column":"12","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-5 grid grid-cols-12 gap-4",children:[P.jsx("div",{"trae-inspector-start-line":"128","trae-inspector-start-column":"8","trae-inspector-end-line":"250","trae-inspector-end-column":"14","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12 lg:col-span-9 order-2 lg:order-1",children:P.jsxs("div",{"trae-inspector-start-line":"129","trae-inspector-start-column":"10","trae-inspector-end-line":"249","trae-inspector-end-column":"16","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"overflow-hidden rounded-xl border border-slate-200 bg-white dark:border-slate-800 dark:bg-slate-950",children:[P.jsxs("div",{"trae-inspector-start-line":"130","trae-inspector-start-column":"12","trae-inspector-end-line":"135","trae-inspector-end-column":"18","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"hidden md:grid grid-cols-12 gap-2 border-b border-slate-100 dark:border-slate-800 px-3 py-2 text-xs text-slate-500 dark:text-slate-400",children:[P.jsx("div",{"trae-inspector-start-line":"131","trae-inspector-start-column":"14","trae-inspector-end-line":"131","trae-inspector-end-column":"75","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-5",children:e("worktrees.table.path")}),P.jsx("div",{"trae-inspector-start-line":"132","trae-inspector-start-column":"14","trae-inspector-end-line":"132","trae-inspector-end-column":"77","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-3",children:e("worktrees.table.branch")}),P.jsx("div",{"trae-inspector-start-line":"133","trae-inspector-start-column":"14","trae-inspector-end-line":"133","trae-inspector-end-column":"76","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-2",children:e("worktrees.table.flags")}),P.jsx("div",{"trae-inspector-start-line":"134","trae-inspector-start-column":"14","trae-inspector-end-line":"134","trae-inspector-end-column":"89","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-2 text-right",children:e("worktrees.table.actions")})]}),t?P.jsx("div",{"trae-inspector-start-line":"138","trae-inspector-start-column":"14","trae-inspector-end-line":"140","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"p-4",children:P.jsx("div",{"trae-inspector-start-line":"139","trae-inspector-start-column":"16","trae-inspector-end-line":"139","trae-inspector-end-column":"96","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"h-10 animate-pulse rounded-lg bg-slate-100 dark:bg-slate-900"})}):n.length===0?P.jsx("div",{"trae-inspector-start-line":"142","trae-inspector-start-column":"14","trae-inspector-end-line":"142","trae-inspector-end-column":"106","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"p-6 text-sm text-slate-500 dark:text-slate-300",children:e("worktrees.empty")}):P.jsx("div",{"trae-inspector-start-line":"144","trae-inspector-start-column":"14","trae-inspector-end-line":"247","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"max-h-[520px] overflow-auto",children:n.map(K=>{const oe=K.id===r,ie=[K.isMain?"Main":null,K.isLocked?"Locked":null].filter(Boolean);return P.jsxs("div",{"trae-inspector-start-line":"153","trae-inspector-start-column":"20","trae-inspector-end-line":"244","trae-inspector-end-column":"26","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:oe?"flex flex-col md:grid md:grid-cols-12 gap-2 bg-slate-100 dark:bg-slate-900/60 px-3 py-3 md:py-2 text-sm border-b md:border-b-0 border-slate-100 dark:border-slate-800/50":"flex flex-col md:grid md:grid-cols-12 gap-2 px-3 py-3 md:py-2 text-sm hover:bg-slate-50 dark:hover:bg-slate-900/40 border-b md:border-b-0 border-slate-100 dark:border-slate-800/50",onClick:()=>s(K.id),role:"button",tabIndex:0,children:[P.jsxs("div",{"trae-inspector-start-line":"164","trae-inspector-start-column":"22","trae-inspector-end-line":"169","trae-inspector-end-column":"28","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-5 min-w-0",children:[P.jsx("div",{"trae-inspector-start-line":"165","trae-inspector-start-column":"24","trae-inspector-end-line":"165","trae-inspector-end-column":"134","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"md:hidden text-xs text-slate-500 dark:text-slate-400 mb-0.5",children:e("worktrees.table.path")}),P.jsx("div",{"trae-inspector-start-line":"166","trae-inspector-start-column":"24","trae-inspector-end-line":"168","trae-inspector-end-column":"30","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"truncate font-mono text-xs text-slate-900 dark:text-slate-100",title:K.path,children:FF(K.path)})]}),P.jsxs("div",{"trae-inspector-start-line":"170","trae-inspector-start-column":"22","trae-inspector-end-line":"179","trae-inspector-end-column":"28","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-3 min-w-0 mt-2 md:mt-0",children:[P.jsxs("div",{"trae-inspector-start-line":"171","trae-inspector-start-column":"24","trae-inspector-end-line":"174","trae-inspector-end-column":"30","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"md:hidden flex items-center gap-2 mb-0.5",children:[P.jsx("span",{"trae-inspector-start-line":"172","trae-inspector-start-column":"26","trae-inspector-end-line":"172","trae-inspector-end-column":"123","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-xs text-slate-500 dark:text-slate-400",children:e("worktrees.table.branch")}),P.jsx("span",{"trae-inspector-start-line":"173","trae-inspector-start-column":"26","trae-inspector-end-line":"173","trae-inspector-end-column":"106","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"font-mono text-xs text-slate-500",children:K.head.slice(0,10)})]}),P.jsx("div",{"trae-inspector-start-line":"175","trae-inspector-start-column":"24","trae-inspector-end-line":"177","trae-inspector-end-column":"30","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"truncate text-slate-900 dark:text-slate-100",children:K.branch?K.branch:"HEAD"}),P.jsx("div",{"trae-inspector-start-line":"178","trae-inspector-start-column":"24","trae-inspector-end-line":"178","trae-inspector-end-column":"127","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"hidden md:block truncate font-mono text-xs text-slate-500",children:K.head.slice(0,10)})]}),P.jsx("div",{"trae-inspector-start-line":"180","trae-inspector-start-column":"22","trae-inspector-end-line":"193","trae-inspector-end-column":"28","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-2 flex flex-wrap items-center gap-1 mt-2 md:mt-0",children:ie.length===0?P.jsx("span",{"trae-inspector-start-line":"182","trae-inspector-start-column":"26","trae-inspector-end-line":"182","trae-inspector-end-column":"112","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22%E2%80%94%22%2C%22textStartLine%22%3A%22182%22%2C%22textStartColumn%22%3A%22104%22%2C%22textEndLine%22%3A%22182%22%2C%22textEndColumn%22%3A%22105%22%2C%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-xs text-slate-400 dark:text-slate-500 hidden md:inline",children:"—"}):ie.map(W=>P.jsx("span",{"trae-inspector-start-line":"185","trae-inspector-start-column":"28","trae-inspector-end-line":"190","trae-inspector-end-column":"35","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded border border-slate-200 dark:border-slate-700 bg-slate-100 dark:bg-slate-900 px-1.5 py-0.5 text-[11px] text-slate-600 dark:text-slate-300",children:W},W))}),P.jsxs("div",{"trae-inspector-start-line":"194","trae-inspector-start-column":"22","trae-inspector-end-line":"243","trae-inspector-end-column":"28","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-2 mt-3 md:mt-0 flex md:justify-end gap-1",children:[P.jsx(ot,{variant:"ghost",size:"sm",onClick:W=>{W.stopPropagation(),de(K.id)},title:e("diff.viewStaged"),children:P.jsx(Iv,{className:"h-4 w-4"})}),P.jsx(ot,{variant:"ghost",size:"sm",onClick:W=>{W.stopPropagation(),c(K.id).then(ce=>ce?Ct.success(e("worktrees.toast.folderSuccess")):Ct.error(e("worktrees.toast.folderFailed")))},children:P.jsx(Ev,{className:"h-4 w-4"})}),P.jsx(ot,{variant:"ghost",size:"sm",onClick:W=>{W.stopPropagation(),ee(K.path)},title:e("worktrees.actions.copy"),children:P.jsx(Xm,{className:"h-4 w-4"})}),P.jsx(ot,{variant:"ghost",size:"sm",disabled:K.isMain,onClick:W=>{W.stopPropagation(),g(K.id)},title:e("worktrees.actions.delete"),children:P.jsx(Z5,{className:"h-4 w-4"})})]})]},K.id)})})]})}),P.jsxs("div",{"trae-inspector-start-line":"252","trae-inspector-start-column":"8","trae-inspector-end-line":"347","trae-inspector-end-column":"14","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12 lg:col-span-3 order-1 lg:order-2 mb-4 lg:mb-0",children:[P.jsxs("div",{"trae-inspector-start-line":"253","trae-inspector-start-column":"10","trae-inspector-end-line":"336","trae-inspector-end-column":"16","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-xl border border-slate-200 bg-white dark:border-slate-800 dark:bg-slate-950 p-4",children:[P.jsx("div",{"trae-inspector-start-line":"254","trae-inspector-start-column":"12","trae-inspector-end-line":"254","trae-inspector-end-column":"116","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-sm font-semibold text-slate-900 dark:text-slate-100",children:e("worktrees.details")}),U?P.jsxs("div",{"trae-inspector-start-line":"256","trae-inspector-start-column":"14","trae-inspector-end-line":"332","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-3 space-y-2 text-xs",children:[P.jsxs("div",{"trae-inspector-start-line":"257","trae-inspector-start-column":"16","trae-inspector-end-line":"260","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",children:[P.jsx("div",{"trae-inspector-start-line":"258","trae-inspector-start-column":"18","trae-inspector-end-line":"258","trae-inspector-end-column":"110","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-slate-500 dark:text-slate-400",children:e("worktrees.detailsPanel.path")}),P.jsx("div",{"trae-inspector-start-line":"259","trae-inspector-start-column":"18","trae-inspector-end-line":"259","trae-inspector-end-column":"116","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-1 break-all font-mono text-slate-900 dark:text-slate-100",children:U.path})]}),P.jsxs("div",{"trae-inspector-start-line":"261","trae-inspector-start-column":"16","trae-inspector-end-line":"270","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"grid grid-cols-2 gap-2",children:[P.jsxs("div",{"trae-inspector-start-line":"262","trae-inspector-start-column":"18","trae-inspector-end-line":"265","trae-inspector-end-column":"24","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",children:[P.jsx("div",{"trae-inspector-start-line":"263","trae-inspector-start-column":"20","trae-inspector-end-line":"263","trae-inspector-end-column":"114","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-slate-500 dark:text-slate-400",children:e("worktrees.detailsPanel.branch")}),P.jsx("div",{"trae-inspector-start-line":"264","trae-inspector-start-column":"20","trae-inspector-end-line":"264","trae-inspector-end-column":"153","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-1 truncate text-slate-900 dark:text-slate-100",title:U.branch||"HEAD",children:U.branch||"HEAD"})]}),P.jsxs("div",{"trae-inspector-start-line":"266","trae-inspector-start-column":"18","trae-inspector-end-line":"269","trae-inspector-end-column":"24","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",children:[P.jsx("div",{"trae-inspector-start-line":"267","trae-inspector-start-column":"20","trae-inspector-end-line":"267","trae-inspector-end-column":"112","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-slate-500 dark:text-slate-400",children:e("worktrees.detailsPanel.main")}),P.jsx("div",{"trae-inspector-start-line":"268","trae-inspector-start-column":"20","trae-inspector-end-line":"268","trae-inspector-end-column":"167","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-1 text-slate-900 dark:text-slate-100",children:U.isMain?e("worktrees.detailsPanel.yes"):e("worktrees.detailsPanel.no")})]})]}),P.jsxs("div",{"trae-inspector-start-line":"271","trae-inspector-start-column":"16","trae-inspector-end-line":"274","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",children:[P.jsx("div",{"trae-inspector-start-line":"272","trae-inspector-start-column":"18","trae-inspector-end-line":"272","trae-inspector-end-column":"110","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-slate-500 dark:text-slate-400",children:e("worktrees.detailsPanel.head")}),P.jsx("div",{"trae-inspector-start-line":"273","trae-inspector-start-column":"18","trae-inspector-end-line":"273","trae-inspector-end-column":"116","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-1 break-all font-mono text-slate-900 dark:text-slate-100",children:U.head})]}),P.jsxs("div",{"trae-inspector-start-line":"275","trae-inspector-start-column":"16","trae-inspector-end-line":"331","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex flex-col sm:flex-row flex-wrap gap-2 pt-2",children:[P.jsxs(ot,{className:"w-full sm:w-auto",variant:"secondary",size:"sm",onClick:()=>ee(U.path),children:[P.jsx(Xm,{className:"h-4 w-4"}),e("worktrees.actions.copy")]}),P.jsxs(ot,{className:"w-full sm:w-auto",variant:"secondary",size:"sm",onClick:()=>{const K=U.isLocked?f:d,oe=U.isLocked?e("worktrees.toast.unlockSuccess"):e("worktrees.toast.lockSuccess"),ie=U.isLocked?e("worktrees.toast.unlockFailed"):e("worktrees.toast.lockFailed");K(U.id).then(W=>W?Ct.success(oe):Ct.error(ie))},children:[U.isLocked?P.jsx(F5,{className:"h-4 w-4"}):P.jsx(O5,{className:"h-4 w-4"}),U.isLocked?e("worktrees.actions.unlock"):e("worktrees.actions.lock")]}),P.jsxs(ot,{className:"w-full sm:w-auto",variant:"primary",size:"sm",onClick:()=>c(U.id,"editor").then(K=>K?Ct.success(e("worktrees.toast.ideSuccess")):Ct.error(e("worktrees.toast.ideFailed"))),children:[P.jsx(_5,{className:"h-4 w-4"}),e("worktrees.actions.ide")]}),P.jsxs(ot,{className:"w-full sm:w-auto",variant:"secondary",size:"sm",onClick:()=>c(U.id,"folder").then(K=>K?Ct.success(e("worktrees.toast.folderSuccess")):Ct.error(e("worktrees.toast.folderFailed"))),children:[P.jsx(Ev,{className:"h-4 w-4"}),e("worktrees.actions.folder")]}),P.jsxs(ot,{className:"w-full sm:w-auto",variant:"secondary",size:"sm",onClick:()=>de(U.id),children:[P.jsx(Iv,{className:"h-4 w-4"}),e("diff.viewStaged")]})]})]}):P.jsx("div",{"trae-inspector-start-line":"334","trae-inspector-start-column":"14","trae-inspector-end-line":"334","trae-inspector-end-column":"114","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-3 text-xs text-slate-500 dark:text-slate-400",children:e("worktrees.selectToView")})]}),P.jsxs("div",{"trae-inspector-start-line":"338","trae-inspector-start-column":"10","trae-inspector-end-line":"346","trae-inspector-end-column":"16","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-3 rounded-xl border border-slate-200 bg-white dark:border-slate-800 dark:bg-slate-950 p-4",children:[P.jsx("div",{"trae-inspector-start-line":"339","trae-inspector-start-column":"12","trae-inspector-end-line":"339","trae-inspector-end-column":"119","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-sm font-semibold text-slate-900 dark:text-slate-100",children:e("worktrees.help.title")}),P.jsx("div",{"trae-inspector-start-line":"340","trae-inspector-start-column":"12","trae-inspector-end-line":"340","trae-inspector-end-column":"109","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2 text-xs text-slate-500 dark:text-slate-400",children:e("worktrees.help.desc")}),P.jsx("div",{"trae-inspector-start-line":"341","trae-inspector-start-column":"12","trae-inspector-end-line":"345","trae-inspector-end-column":"18","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-3",children:P.jsx(wo,{to:"/help",children:P.jsx(ot,{variant:"secondary",size:"sm",children:e("worktrees.help.viewCommands")})})})]})]})]}),P.jsx(RF,{open:!!I,onClose:te,worktreePath:(H==null?void 0:H.path)??"",diffInfo:S,loading:A}),P.jsxs(mx,{title:e(y?"worktrees.deleteModal.forceTitle":"worktrees.deleteModal.title"),open:!!h,onClose:re,footer:P.jsxs(P.Fragment,{children:[P.jsx(ot,{variant:"secondary",size:"sm",onClick:re,disabled:_,children:e("worktrees.deleteModal.cancel")}),P.jsx(ot,{variant:"danger",size:"sm",onClick:Q,disabled:_,children:e(_?"worktrees.deleteModal.deleting":y?"worktrees.deleteModal.forceConfirm":"worktrees.deleteModal.confirm")})]}),children:[P.jsx("div",{"trae-inspector-start-line":"378","trae-inspector-start-column":"8","trae-inspector-end-line":"378","trae-inspector-end-column":"107","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-xs text-slate-600 dark:text-slate-300",children:e("worktrees.deleteModal.desc")}),P.jsx("div",{"trae-inspector-start-line":"379","trae-inspector-start-column":"8","trae-inspector-end-line":"381","trae-inspector-end-column":"14","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2 rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2 font-mono text-xs text-slate-900 dark:text-slate-100",children:X?X.path:"—"}),y?P.jsx("div",{"trae-inspector-start-line":"383","trae-inspector-start-column":"10","trae-inspector-end-line":"385","trae-inspector-end-column":"16","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2 rounded bg-rose-100 dark:bg-rose-500/10 px-2 py-1 text-xs text-rose-600 dark:text-rose-400",children:e("worktrees.deleteModal.warning")}):P.jsx("div",{"trae-inspector-start-line":"387","trae-inspector-start-column":"10","trae-inspector-end-line":"387","trae-inspector-end-column":"120","trae-inspector-file-path":"src/pages/Worktrees.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2 text-xs text-slate-500 dark:text-slate-400",children:e("worktrees.deleteModal.normalNote")})]})]})}function dS(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=dS(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function OF(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=dS(e))&&(r&&(r+=" "),r+=t);return r}function hl({className:e,...t}){return P.jsx("input",{"trae-inspector-start-line":"6","trae-inspector-start-column":"4","trae-inspector-end-line":"13","trae-inspector-end-column":"6","trae-inspector-file-path":"src/components/Input.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:OF("w-full rounded-md border border-slate-300 bg-white px-3 py-1.5 text-sm text-slate-900 placeholder:text-slate-400 focus:border-indigo-500 focus:outline-none focus:ring-1 focus:ring-indigo-500","dark:border-slate-700 dark:bg-slate-900 dark:text-slate-100 dark:placeholder:text-slate-500 dark:focus:border-indigo-500 dark:focus:ring-indigo-500",e),...t})}function $F(){const{t:e}=Iu(),t=Zb(),n=Qn(L=>L.create),r=Qn(L=>L.branches),i=Qn(L=>L.fetchBranches);B.useEffect(()=>{i()},[i]);const[s,l]=B.useState("existing"),[c,d]=B.useState(""),[f,m]=B.useState(""),[h,g]=B.useState(""),[y,w]=B.useState(!1),[_,C]=B.useState(null),I=B.useMemo(()=>{const L=h.trim()?h.trim():"<path>";return s==="new"&&f.trim()?`git branch ${f.trim()} ${c.trim()||"<ref>"} && git worktree add ${L} ${f.trim()}`:`git worktree add ${L} ${c.trim()||"<ref>"}`},[s,f,h,c]),E=c.trim().length>0&&h.trim().length>0&&(!s||s==="existing"||f.trim().length>0),S=async()=>{if(E){w(!0),C(null);try{const L={ref:c.trim(),path:h.trim(),...s==="new"?{newBranch:f.trim()}:{}},A=await n(L);if(!A){Ct.error("创建失败");return}C(A.path),Ct.success("创建成功")}catch(L){const A=L instanceof Error?L.message:String(L);Ct.error("创建失败",{description:A})}finally{w(!1)}}};return P.jsxs("div",{"trae-inspector-start-line":"67","trae-inspector-start-column":"4","trae-inspector-end-line":"178","trae-inspector-end-column":"10","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mx-auto w-full max-w-screen-xl px-4 py-6",children:[P.jsxs("div",{"trae-inspector-start-line":"68","trae-inspector-start-column":"6","trae-inspector-end-line":"79","trae-inspector-end-column":"12","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex items-center justify-between gap-4",children:[P.jsxs("div",{"trae-inspector-start-line":"69","trae-inspector-start-column":"8","trae-inspector-end-line":"77","trae-inspector-end-column":"14","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex items-center gap-2",children:[P.jsx(wo,{to:"/",children:P.jsxs(ot,{variant:"ghost",size:"sm",children:[P.jsx(g0,{className:"h-4 w-4"}),e("create.back")]})}),P.jsx("div",{"trae-inspector-start-line":"76","trae-inspector-start-column":"10","trae-inspector-end-line":"76","trae-inspector-end-column":"109","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-lg font-semibold text-slate-900 dark:text-slate-100",children:e("create.title")})]}),P.jsx(ot,{variant:"secondary",size:"sm",onClick:()=>t("/help"),children:e("create.help")})]}),P.jsxs("div",{"trae-inspector-start-line":"81","trae-inspector-start-column":"6","trae-inspector-end-line":"177","trae-inspector-end-column":"12","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-5 grid grid-cols-12 gap-4",children:[P.jsx("div",{"trae-inspector-start-line":"82","trae-inspector-start-column":"8","trae-inspector-end-line":"139","trae-inspector-end-column":"14","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12 lg:col-span-7",children:P.jsxs("div",{"trae-inspector-start-line":"83","trae-inspector-start-column":"10","trae-inspector-end-line":"138","trae-inspector-end-column":"16","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-xl border border-slate-200 bg-white dark:border-slate-800 dark:bg-slate-950 p-4",children:[P.jsxs("div",{"trae-inspector-start-line":"84","trae-inspector-start-column":"12","trae-inspector-end-line":"95","trae-inspector-end-column":"18","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex gap-2",children:[P.jsx(ot,{size:"sm",variant:s==="existing"?"primary":"secondary",onClick:()=>l("existing"),children:e("create.tabs.existing")}),P.jsx(ot,{size:"sm",variant:s==="new"?"primary":"secondary",onClick:()=>l("new"),children:e("create.tabs.new")})]}),P.jsxs("div",{"trae-inspector-start-line":"97","trae-inspector-start-column":"12","trae-inspector-end-line":"130","trae-inspector-end-column":"18","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-4 grid grid-cols-12 gap-3",children:[P.jsxs("div",{"trae-inspector-start-line":"98","trae-inspector-start-column":"14","trae-inspector-end-line":"113","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12",children:[P.jsx("div",{"trae-inspector-start-line":"99","trae-inspector-start-column":"16","trae-inspector-end-line":"99","trae-inspector-end-column":"118","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-xs font-medium text-slate-600 dark:text-slate-300",children:e("create.fields.ref")}),P.jsxs("div",{"trae-inspector-start-line":"100","trae-inspector-start-column":"16","trae-inspector-end-line":"112","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-1",children:[P.jsx(hl,{value:c,onChange:L=>d(L.target.value),placeholder:e("create.fields.refPlaceholder"),list:"branch-list"}),P.jsx("datalist",{"trae-inspector-start-line":"107","trae-inspector-start-column":"18","trae-inspector-end-line":"111","trae-inspector-end-column":"29","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",id:"branch-list",children:r.map(L=>P.jsx("option",{"trae-inspector-start-line":"109","trae-inspector-start-column":"22","trae-inspector-end-line":"109","trae-inspector-end-column":"50","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",value:L},L))})]})]}),s==="new"?P.jsxs("div",{"trae-inspector-start-line":"116","trae-inspector-start-column":"16","trae-inspector-end-line":"121","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12",children:[P.jsx("div",{"trae-inspector-start-line":"117","trae-inspector-start-column":"18","trae-inspector-end-line":"117","trae-inspector-end-column":"126","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-xs font-medium text-slate-600 dark:text-slate-300",children:e("create.fields.newBranch")}),P.jsx("div",{"trae-inspector-start-line":"118","trae-inspector-start-column":"18","trae-inspector-end-line":"120","trae-inspector-end-column":"24","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-1",children:P.jsx(hl,{value:f,onChange:L=>m(L.target.value),placeholder:e("create.fields.newBranchPlaceholder")})})]}):null,P.jsxs("div",{"trae-inspector-start-line":"124","trae-inspector-start-column":"14","trae-inspector-end-line":"129","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12",children:[P.jsx("div",{"trae-inspector-start-line":"125","trae-inspector-start-column":"16","trae-inspector-end-line":"125","trae-inspector-end-column":"119","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-xs font-medium text-slate-600 dark:text-slate-300",children:e("create.fields.path")}),P.jsx("div",{"trae-inspector-start-line":"126","trae-inspector-start-column":"16","trae-inspector-end-line":"128","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-1",children:P.jsx(hl,{value:h,onChange:L=>g(L.target.value),placeholder:e("create.fields.pathPlaceholder")})})]})]}),P.jsx("div",{"trae-inspector-start-line":"132","trae-inspector-start-column":"12","trae-inspector-end-line":"137","trae-inspector-end-column":"18","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-4 flex flex-col sm:flex-row items-center justify-end gap-2",children:P.jsxs(ot,{className:"w-full sm:w-auto",variant:"primary",size:"sm",disabled:!E||y,onClick:S,children:[y?P.jsx(Lv,{className:"h-4 w-4 animate-spin"}):null,e("create.submit")]})})]})}),P.jsxs("div",{"trae-inspector-start-line":"141","trae-inspector-start-column":"8","trae-inspector-end-line":"176","trae-inspector-end-column":"14","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12 lg:col-span-5",children:[P.jsxs("div",{"trae-inspector-start-line":"142","trae-inspector-start-column":"10","trae-inspector-end-line":"148","trae-inspector-end-column":"16","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-xl border border-slate-200 bg-white dark:border-slate-800 dark:bg-slate-950 p-4",children:[P.jsx("div",{"trae-inspector-start-line":"143","trae-inspector-start-column":"12","trae-inspector-end-line":"143","trae-inspector-end-column":"119","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-sm font-semibold text-slate-900 dark:text-slate-100",children:e("create.preview.title")}),P.jsx("div",{"trae-inspector-start-line":"144","trae-inspector-start-column":"12","trae-inspector-end-line":"146","trae-inspector-end-column":"18","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2 rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2 font-mono text-xs text-slate-900 dark:text-slate-100",children:I}),P.jsx("div",{"trae-inspector-start-line":"147","trae-inspector-start-column":"12","trae-inspector-end-line":"147","trae-inspector-end-column":"109","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2 text-xs text-slate-500 dark:text-slate-400",children:e("create.preview.desc")})]}),P.jsxs("div",{"trae-inspector-start-line":"150","trae-inspector-start-column":"10","trae-inspector-end-line":"175","trae-inspector-end-column":"16","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-3 rounded-xl border border-slate-200 bg-white dark:border-slate-800 dark:bg-slate-950 p-4",children:[P.jsx("div",{"trae-inspector-start-line":"151","trae-inspector-start-column":"12","trae-inspector-end-line":"151","trae-inspector-end-column":"118","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-sm font-semibold text-slate-900 dark:text-slate-100",children:e("create.result.title")}),y?P.jsxs("div",{"trae-inspector-start-line":"153","trae-inspector-start-column":"14","trae-inspector-end-line":"156","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2 flex items-center gap-2 text-xs text-slate-600 dark:text-slate-300",children:[P.jsx(Lv,{className:"h-4 w-4 animate-spin"}),e("create.result.creating")]}):_?P.jsxs("div",{"trae-inspector-start-line":"158","trae-inspector-start-column":"14","trae-inspector-end-line":"171","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2",children:[P.jsxs("div",{"trae-inspector-start-line":"159","trae-inspector-start-column":"16","trae-inspector-end-line":"162","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex items-center gap-2 text-xs text-emerald-600 dark:text-emerald-400",children:[P.jsx(b5,{className:"h-4 w-4"}),e("create.result.success")]}),P.jsx("div",{"trae-inspector-start-line":"163","trae-inspector-start-column":"16","trae-inspector-end-line":"165","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2 rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2 font-mono text-xs text-slate-900 dark:text-slate-100",children:_}),P.jsx("div",{"trae-inspector-start-line":"166","trae-inspector-start-column":"16","trae-inspector-end-line":"170","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-3",children:P.jsx(wo,{to:"/",children:P.jsx(ot,{variant:"secondary",size:"sm",children:e("create.result.backToList")})})})]}):P.jsx("div",{"trae-inspector-start-line":"173","trae-inspector-start-column":"14","trae-inspector-end-line":"173","trae-inspector-end-column":"111","trae-inspector-file-path":"src/pages/CreateWorktree.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2 text-xs text-slate-500 dark:text-slate-400",children:e("create.result.empty")})]})]})]})]})}function BF(){const{t:e,i18n:t}=Iu(),n=Qn(w=>w.prune),{theme:r,setTheme:i}=_h(),[s,l]=B.useState({}),[c,d]=B.useState(!1),[f,m]=B.useState(!1);B.useEffect(()=>{d(!0),Tf("/api/config").then(w=>{w.ok&&l(w.data)}).finally(()=>d(!1))},[]);const h=async()=>{d(!0);try{const w=await Rb("/api/config",s);if(!w.ok){const _=w.error.message;Ct.error(e("settings.toast.saveFailed"),{description:_});return}l(w.data),Ct.success(e("settings.toast.saveSuccess"))}finally{d(!1)}},g=async()=>{l({}),d(!0);try{const w=await Rb("/api/config",{});if(!w.ok){const _=w.error.message;Ct.error(e("settings.toast.resetFailed","重置失败"),{description:_});return}l(w.data),Ct.info(e("settings.toast.resetSuccess","已重置"))}finally{d(!1)}},y=async()=>{m(!0);try{await n()?Ct.success(e("settings.toast.pruneSuccess")):Ct.error(e("settings.toast.pruneFailed"))}finally{m(!1)}};return P.jsxs("div",{"trae-inspector-start-line":"78","trae-inspector-start-column":"4","trae-inspector-end-line":"219","trae-inspector-end-column":"10","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mx-auto w-full max-w-screen-xl px-4 py-6",children:[P.jsxs("div",{"trae-inspector-start-line":"79","trae-inspector-start-column":"6","trae-inspector-end-line":"99","trae-inspector-end-column":"12","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex items-center justify-between gap-4",children:[P.jsxs("div",{"trae-inspector-start-line":"80","trae-inspector-start-column":"8","trae-inspector-end-line":"88","trae-inspector-end-column":"14","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex items-center gap-2",children:[P.jsx(wo,{to:"/",children:P.jsxs(ot,{variant:"ghost",size:"sm",children:[P.jsx(g0,{className:"h-4 w-4"}),e("create.back")]})}),P.jsx("div",{"trae-inspector-start-line":"87","trae-inspector-start-column":"10","trae-inspector-end-line":"87","trae-inspector-end-column":"111","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-lg font-semibold text-slate-900 dark:text-slate-100",children:e("settings.title")})]}),P.jsxs("div",{"trae-inspector-start-line":"89","trae-inspector-start-column":"8","trae-inspector-end-line":"98","trae-inspector-end-column":"14","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex flex-col sm:flex-row items-center sm:justify-end gap-2",children:[P.jsxs(ot,{className:"w-full sm:w-auto",variant:"secondary",size:"sm",onClick:g,disabled:c,children:[P.jsx(W5,{className:"h-4 w-4"}),e("settings.cli.reset")]}),P.jsxs(ot,{className:"w-full sm:w-auto",variant:"primary",size:"sm",onClick:h,disabled:c,children:[P.jsx(q5,{className:"h-4 w-4"}),e("settings.cli.save")]})]})]}),P.jsxs("div",{"trae-inspector-start-line":"101","trae-inspector-start-column":"6","trae-inspector-end-line":"218","trae-inspector-end-column":"12","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-5 grid grid-cols-12 gap-4",children:[P.jsxs("div",{"trae-inspector-start-line":"102","trae-inspector-start-column":"8","trae-inspector-end-line":"208","trae-inspector-end-column":"14","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12 lg:col-span-7",children:[P.jsxs("div",{"trae-inspector-start-line":"103","trae-inspector-start-column":"10","trae-inspector-end-line":"158","trae-inspector-end-column":"16","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-xl border border-slate-200 bg-white p-4 dark:border-slate-800 dark:bg-slate-950",children:[P.jsx("div",{"trae-inspector-start-line":"104","trae-inspector-start-column":"12","trae-inspector-end-line":"104","trae-inspector-end-column":"125","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-sm font-semibold text-slate-900 dark:text-slate-100",children:e("settings.preferences.title")}),P.jsxs("div",{"trae-inspector-start-line":"105","trae-inspector-start-column":"12","trae-inspector-end-line":"157","trae-inspector-end-column":"18","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-4 grid grid-cols-12 gap-4",children:[P.jsxs("div",{"trae-inspector-start-line":"106","trae-inspector-start-column":"14","trae-inspector-end-line":"134","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12 lg:col-span-6",children:[P.jsx("div",{"trae-inspector-start-line":"107","trae-inspector-start-column":"16","trae-inspector-end-line":"107","trae-inspector-end-column":"127","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-xs font-medium text-slate-600 dark:text-slate-300",children:e("settings.preferences.theme")}),P.jsxs("div",{"trae-inspector-start-line":"108","trae-inspector-start-column":"16","trae-inspector-end-line":"133","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2 flex gap-2",children:[P.jsxs(ot,{size:"sm",variant:r==="light"?"primary":"secondary",onClick:()=>i("light"),children:[P.jsx(Y5,{className:"h-4 w-4"}),e("settings.preferences.light")]}),P.jsxs(ot,{size:"sm",variant:r==="dark"?"primary":"secondary",onClick:()=>i("dark"),children:[P.jsx(B5,{className:"h-4 w-4"}),e("settings.preferences.dark")]}),P.jsxs(ot,{size:"sm",variant:r==="system"?"primary":"secondary",onClick:()=>i("system"),children:[P.jsx(T5,{className:"h-4 w-4"}),e("settings.preferences.system")]})]})]}),P.jsxs("div",{"trae-inspector-start-line":"136","trae-inspector-start-column":"14","trae-inspector-end-line":"156","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12 lg:col-span-6",children:[P.jsx("div",{"trae-inspector-start-line":"137","trae-inspector-start-column":"16","trae-inspector-end-line":"137","trae-inspector-end-column":"130","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-xs font-medium text-slate-600 dark:text-slate-300",children:e("settings.preferences.language")}),P.jsxs("div",{"trae-inspector-start-line":"138","trae-inspector-start-column":"16","trae-inspector-end-line":"155","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2 flex gap-2",children:[P.jsxs(ot,{size:"sm",variant:t.language.startsWith("en")?"primary":"secondary",onClick:()=>t.changeLanguage("en"),children:[P.jsx(Pv,{className:"h-4 w-4"}),e("settings.preferences.en")]}),P.jsxs(ot,{size:"sm",variant:t.language.startsWith("zh")?"primary":"secondary",onClick:()=>t.changeLanguage("zh"),children:[P.jsx(Pv,{className:"h-4 w-4"}),e("settings.preferences.zh")]})]})]})]})]}),P.jsxs("div",{"trae-inspector-start-line":"160","trae-inspector-start-column":"10","trae-inspector-end-line":"194","trae-inspector-end-column":"16","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-4 rounded-xl border border-slate-200 bg-white p-4 dark:border-slate-800 dark:bg-slate-950",children:[P.jsx("div",{"trae-inspector-start-line":"161","trae-inspector-start-column":"12","trae-inspector-end-line":"161","trae-inspector-end-column":"117","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-sm font-semibold text-slate-900 dark:text-slate-100",children:e("settings.cli.title")}),P.jsxs("div",{"trae-inspector-start-line":"162","trae-inspector-start-column":"12","trae-inspector-end-line":"193","trae-inspector-end-column":"18","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-4 grid grid-cols-12 gap-3",children:[P.jsxs("div",{"trae-inspector-start-line":"163","trae-inspector-start-column":"14","trae-inspector-end-line":"172","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12",children:[P.jsx("div",{"trae-inspector-start-line":"164","trae-inspector-start-column":"16","trae-inspector-end-line":"164","trae-inspector-end-column":"121","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-xs font-medium text-slate-600 dark:text-slate-300",children:e("settings.cli.baseDir")}),P.jsx("div",{"trae-inspector-start-line":"165","trae-inspector-start-column":"16","trae-inspector-end-line":"171","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-1",children:P.jsx(hl,{value:s.baseDir||"",onChange:w=>l(_=>({..._,baseDir:w.target.value})),placeholder:e("settings.cli.baseDirPlaceholder")})})]}),P.jsxs("div",{"trae-inspector-start-line":"173","trae-inspector-start-column":"14","trae-inspector-end-line":"182","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12",children:[P.jsx("div",{"trae-inspector-start-line":"174","trae-inspector-start-column":"16","trae-inspector-end-line":"174","trae-inspector-end-column":"125","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-xs font-medium text-slate-600 dark:text-slate-300",children:e("settings.cli.openCommand")}),P.jsx("div",{"trae-inspector-start-line":"175","trae-inspector-start-column":"16","trae-inspector-end-line":"181","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-1",children:P.jsx(hl,{value:s.openCommand||"",onChange:w=>l(_=>({..._,openCommand:w.target.value})),placeholder:e("settings.cli.openCommandPlaceholder")})})]}),P.jsxs("div",{"trae-inspector-start-line":"183","trae-inspector-start-column":"14","trae-inspector-end-line":"192","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12",children:[P.jsx("div",{"trae-inspector-start-line":"184","trae-inspector-start-column":"16","trae-inspector-end-line":"184","trae-inspector-end-column":"127","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-xs font-medium text-slate-600 dark:text-slate-300",children:e("settings.cli.editorCommand")}),P.jsx("div",{"trae-inspector-start-line":"185","trae-inspector-start-column":"16","trae-inspector-end-line":"191","trae-inspector-end-column":"22","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-1",children:P.jsx(hl,{value:s.editorCommand||"",onChange:w=>l(_=>({..._,editorCommand:w.target.value})),placeholder:e("settings.cli.editorCommandPlaceholder")})})]})]})]}),P.jsxs("div",{"trae-inspector-start-line":"196","trae-inspector-start-column":"10","trae-inspector-end-line":"207","trae-inspector-end-column":"16","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-4 rounded-xl border border-slate-200 bg-white p-4 dark:border-slate-800 dark:bg-slate-950",children:[P.jsx("div",{"trae-inspector-start-line":"197","trae-inspector-start-column":"12","trae-inspector-end-line":"197","trae-inspector-end-column":"125","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-sm font-semibold text-slate-900 dark:text-slate-100",children:e("settings.maintenance.title")}),P.jsxs("div",{"trae-inspector-start-line":"198","trae-inspector-start-column":"12","trae-inspector-end-line":"206","trae-inspector-end-column":"18","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-3",children:[P.jsxs(ot,{className:"w-full sm:w-auto",variant:"secondary",size:"sm",onClick:y,disabled:f,children:[P.jsx(C5,{className:"h-4 w-4"}),e("settings.maintenance.prune")]}),P.jsx("div",{"trae-inspector-start-line":"203","trae-inspector-start-column":"14","trae-inspector-end-line":"205","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2 text-xs text-slate-500 dark:text-slate-400",children:e("settings.maintenance.pruneDesc")})]})]})]}),P.jsx("div",{"trae-inspector-start-line":"210","trae-inspector-start-column":"8","trae-inspector-end-line":"217","trae-inspector-end-column":"14","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12 lg:col-span-5",children:P.jsxs("div",{"trae-inspector-start-line":"211","trae-inspector-start-column":"10","trae-inspector-end-line":"216","trae-inspector-end-column":"16","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-xl border border-slate-200 bg-white p-4 dark:border-slate-800 dark:bg-slate-950",children:[P.jsx("div",{"trae-inspector-start-line":"212","trae-inspector-start-column":"12","trae-inspector-end-line":"212","trae-inspector-end-column":"118","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-sm font-semibold text-slate-900 dark:text-slate-100",children:e("settings.note.title")}),P.jsx("div",{"trae-inspector-start-line":"213","trae-inspector-start-column":"12","trae-inspector-end-line":"215","trae-inspector-end-column":"18","trae-inspector-file-path":"src/pages/SettingsPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2 text-xs text-slate-500 dark:text-slate-400",children:e("settings.note.desc")})]})})]})]})}function jF(){const{t:e}=Iu();return P.jsxs("div",{"trae-inspector-start-line":"9","trae-inspector-start-column":"4","trae-inspector-end-line":"65","trae-inspector-end-column":"10","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mx-auto w-full max-w-screen-xl px-4 py-6",children:[P.jsxs("div",{"trae-inspector-start-line":"10","trae-inspector-start-column":"6","trae-inspector-end-line":"18","trae-inspector-end-column":"12","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"flex items-center gap-2",children:[P.jsx(wo,{to:"/",children:P.jsxs(ot,{variant:"ghost",size:"sm",children:[P.jsx(g0,{className:"h-4 w-4"}),e("create.back")]})}),P.jsx("div",{"trae-inspector-start-line":"17","trae-inspector-start-column":"8","trae-inspector-end-line":"17","trae-inspector-end-column":"109","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-lg font-semibold text-slate-900 dark:text-slate-100",children:e("helpPage.title")})]}),P.jsxs("div",{"trae-inspector-start-line":"20","trae-inspector-start-column":"6","trae-inspector-end-line":"64","trae-inspector-end-column":"12","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-5 grid grid-cols-12 gap-4",children:[P.jsx("div",{"trae-inspector-start-line":"21","trae-inspector-start-column":"8","trae-inspector-end-line":"43","trae-inspector-end-column":"14","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12 lg:col-span-7",children:P.jsxs("div",{"trae-inspector-start-line":"22","trae-inspector-start-column":"10","trae-inspector-end-line":"42","trae-inspector-end-column":"16","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-xl border border-slate-200 bg-white dark:border-slate-800 dark:bg-slate-950 p-4",children:[P.jsx("div",{"trae-inspector-start-line":"23","trae-inspector-start-column":"12","trae-inspector-end-line":"23","trae-inspector-end-column":"116","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-sm font-semibold text-slate-900 dark:text-slate-100",children:e("helpPage.commands")}),P.jsxs("div",{"trae-inspector-start-line":"24","trae-inspector-start-column":"12","trae-inspector-end-line":"38","trae-inspector-end-column":"18","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-3 space-y-2 font-mono text-xs text-slate-700 dark:text-slate-200",children:[P.jsx("div",{"trae-inspector-start-line":"25","trae-inspector-start-column":"14","trae-inspector-end-line":"25","trae-inspector-end-column":"139","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22wtree%22%2C%22textStartLine%22%3A%2225%22%2C%22textStartColumn%22%3A%22128%22%2C%22textEndLine%22%3A%2225%22%2C%22textEndColumn%22%3A%22133%22%2C%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2",children:"wtree"}),P.jsx("div",{"trae-inspector-start-line":"26","trae-inspector-start-column":"14","trae-inspector-end-line":"26","trae-inspector-end-column":"144","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22wtree%20list%22%2C%22textStartLine%22%3A%2226%22%2C%22textStartColumn%22%3A%22128%22%2C%22textEndLine%22%3A%2226%22%2C%22textEndColumn%22%3A%22138%22%2C%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2",children:"wtree list"}),P.jsx("div",{"trae-inspector-start-line":"27","trae-inspector-start-column":"14","trae-inspector-end-line":"27","trae-inspector-end-column":"161","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22wtree%20create%20%3Cbranch%3E%22%2C%22textStartLine%22%3A%2227%22%2C%22textStartColumn%22%3A%22128%22%2C%22textEndLine%22%3A%2227%22%2C%22textEndColumn%22%3A%22155%22%2C%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2",children:"wtree create <branch>"}),P.jsx("div",{"trae-inspector-start-line":"28","trae-inspector-start-column":"14","trae-inspector-end-line":"28","trae-inspector-end-column":"146","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22wtree%20delete%22%2C%22textStartLine%22%3A%2228%22%2C%22textStartColumn%22%3A%22128%22%2C%22textEndLine%22%3A%2228%22%2C%22textEndColumn%22%3A%22140%22%2C%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2",children:"wtree delete"}),P.jsx("div",{"trae-inspector-start-line":"29","trae-inspector-start-column":"14","trae-inspector-end-line":"29","trae-inspector-end-column":"164","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22wtree%20open%20%3Cpath%7Cbranch%3E%22%2C%22textStartLine%22%3A%2229%22%2C%22textStartColumn%22%3A%22128%22%2C%22textEndLine%22%3A%2229%22%2C%22textEndColumn%22%3A%22158%22%2C%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2",children:"wtree open <path|branch>"}),P.jsx("div",{"trae-inspector-start-line":"30","trae-inspector-start-column":"14","trae-inspector-end-line":"30","trae-inspector-end-column":"164","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22wtree%20lock%20%3Cpath%7Cbranch%3E%22%2C%22textStartLine%22%3A%2230%22%2C%22textStartColumn%22%3A%22128%22%2C%22textEndLine%22%3A%2230%22%2C%22textEndColumn%22%3A%22158%22%2C%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2",children:"wtree lock <path|branch>"}),P.jsx("div",{"trae-inspector-start-line":"31","trae-inspector-start-column":"14","trae-inspector-end-line":"31","trae-inspector-end-column":"166","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22wtree%20unlock%20%3Cpath%7Cbranch%3E%22%2C%22textStartLine%22%3A%2231%22%2C%22textStartColumn%22%3A%22128%22%2C%22textEndLine%22%3A%2231%22%2C%22textEndColumn%22%3A%22160%22%2C%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2",children:"wtree unlock <path|branch>"}),P.jsx("div",{"trae-inspector-start-line":"32","trae-inspector-start-column":"14","trae-inspector-end-line":"32","trae-inspector-end-column":"145","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22wtree%20prune%22%2C%22textStartLine%22%3A%2232%22%2C%22textStartColumn%22%3A%22128%22%2C%22textEndLine%22%3A%2232%22%2C%22textEndColumn%22%3A%22139%22%2C%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2",children:"wtree prune"}),P.jsx("div",{"trae-inspector-start-line":"33","trae-inspector-start-column":"14","trae-inspector-end-line":"33","trae-inspector-end-column":"146","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22wtree%20config%22%2C%22textStartLine%22%3A%2233%22%2C%22textStartColumn%22%3A%22128%22%2C%22textEndLine%22%3A%2233%22%2C%22textEndColumn%22%3A%22140%22%2C%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2",children:"wtree config"}),P.jsx("div",{"trae-inspector-start-line":"34","trae-inspector-start-column":"14","trae-inspector-end-line":"34","trae-inspector-end-column":"162","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22wtree%20config%20get%20%3Ckey%3E%22%2C%22textStartLine%22%3A%2234%22%2C%22textStartColumn%22%3A%22128%22%2C%22textEndLine%22%3A%2234%22%2C%22textEndColumn%22%3A%22156%22%2C%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2",children:"wtree config get <key>"}),P.jsx("div",{"trae-inspector-start-line":"35","trae-inspector-start-column":"14","trae-inspector-end-line":"35","trae-inspector-end-column":"176","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22wtree%20config%20set%20%3Ckey%3E%20%3Cvalue%3E%22%2C%22textStartLine%22%3A%2235%22%2C%22textStartColumn%22%3A%22128%22%2C%22textEndLine%22%3A%2235%22%2C%22textEndColumn%22%3A%22170%22%2C%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2",children:"wtree config set <key> <value>"}),P.jsx("div",{"trae-inspector-start-line":"36","trae-inspector-start-column":"14","trae-inspector-end-line":"36","trae-inspector-end-column":"144","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22wtree%20--ui%22%2C%22textStartLine%22%3A%2236%22%2C%22textStartColumn%22%3A%22128%22%2C%22textEndLine%22%3A%2236%22%2C%22textEndColumn%22%3A%22138%22%2C%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2",children:"wtree --ui"}),P.jsx("div",{"trae-inspector-start-line":"37","trae-inspector-start-column":"14","trae-inspector-end-line":"37","trae-inspector-end-column":"166","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22wtree%20--ui%20--no-open%20--port%205173%22%2C%22textStartLine%22%3A%2237%22%2C%22textStartColumn%22%3A%22128%22%2C%22textEndLine%22%3A%2237%22%2C%22textEndColumn%22%3A%22160%22%2C%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-md border border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900 px-3 py-2",children:"wtree --ui --no-open --port 5173"})]}),P.jsx("div",{"trae-inspector-start-line":"39","trae-inspector-start-column":"14","trae-inspector-end-line":"41","trae-inspector-end-column":"18","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-3 text-xs text-slate-500 dark:text-slate-400",children:e("helpPage.commandsDesc")})]})}),P.jsx("div",{"trae-inspector-start-line":"45","trae-inspector-start-column":"8","trae-inspector-end-line":"63","trae-inspector-end-column":"14","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"col-span-12 lg:col-span-5",children:P.jsxs("div",{"trae-inspector-start-line":"46","trae-inspector-start-column":"10","trae-inspector-end-line":"62","trae-inspector-end-column":"16","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"rounded-xl border border-slate-200 bg-white dark:border-slate-800 dark:bg-slate-950 p-4",children:[P.jsx("div",{"trae-inspector-start-line":"47","trae-inspector-start-column":"12","trae-inspector-end-line":"47","trae-inspector-end-column":"117","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-sm font-semibold text-slate-900 dark:text-slate-100",children:e("helpPage.faq.title")}),P.jsxs("div",{"trae-inspector-start-line":"48","trae-inspector-start-column":"12","trae-inspector-end-line":"61","trae-inspector-end-column":"18","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-2 space-y-2 text-xs text-slate-500 dark:text-slate-400",children:[P.jsxs("div",{"trae-inspector-start-line":"49","trae-inspector-start-column":"14","trae-inspector-end-line":"52","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",children:[P.jsx("div",{"trae-inspector-start-line":"50","trae-inspector-start-column":"16","trae-inspector-end-line":"50","trae-inspector-end-column":"96","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-slate-700 dark:text-slate-200",children:e("helpPage.faq.q1")}),P.jsx("div",{"trae-inspector-start-line":"51","trae-inspector-start-column":"16","trae-inspector-end-line":"51","trae-inspector-end-column":"66","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-1",children:e("helpPage.faq.a1")})]}),P.jsxs("div",{"trae-inspector-start-line":"53","trae-inspector-start-column":"14","trae-inspector-end-line":"56","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",children:[P.jsx("div",{"trae-inspector-start-line":"54","trae-inspector-start-column":"16","trae-inspector-end-line":"54","trae-inspector-end-column":"96","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-slate-700 dark:text-slate-200",children:e("helpPage.faq.q2")}),P.jsx("div",{"trae-inspector-start-line":"55","trae-inspector-start-column":"16","trae-inspector-end-line":"55","trae-inspector-end-column":"66","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-1",children:e("helpPage.faq.a2")})]}),P.jsxs("div",{"trae-inspector-start-line":"57","trae-inspector-start-column":"14","trae-inspector-end-line":"60","trae-inspector-end-column":"20","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",children:[P.jsx("div",{"trae-inspector-start-line":"58","trae-inspector-start-column":"16","trae-inspector-end-line":"58","trae-inspector-end-column":"96","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"text-slate-700 dark:text-slate-200",children:e("helpPage.faq.q3")}),P.jsx("div",{"trae-inspector-start-line":"59","trae-inspector-start-column":"16","trae-inspector-end-line":"59","trae-inspector-end-column":"66","trae-inspector-file-path":"src/pages/HelpPage.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fbytedance%2FDocuments%2Fworktree-manager%22%7D",className:"mt-1",children:e("helpPage.faq.a3")})]})]})]})})]})]})}function VF(){const e=_h(t=>t.initTheme);return B.useEffect(()=>{e()},[e]),P.jsxs(YE,{children:[P.jsx(SF,{position:"top-right",richColors:!0,theme:"system"}),P.jsxs(IE,{children:[P.jsx(Rc,{path:"/",element:P.jsx(MF,{})}),P.jsx(Rc,{path:"/create",element:P.jsx($F,{})}),P.jsx(Rc,{path:"/settings",element:P.jsx(BF,{})}),P.jsx(Rc,{path:"/help",element:P.jsx(jF,{})})]})]})}const{slice:UF,forEach:zF}=[];function HF(e){return zF.call(UF.call(arguments,1),t=>{if(t)for(const n in t)e[n]===void 0&&(e[n]=t[n])}),e}function WF(e){return typeof e!="string"?!1:[/<\s*script.*?>/i,/<\s*\/\s*script\s*>/i,/<\s*img.*?on\w+\s*=/i,/<\s*\w+\s*on\w+\s*=.*?>/i,/javascript\s*:/i,/vbscript\s*:/i,/expression\s*\(/i,/eval\s*\(/i,/alert\s*\(/i,/document\.cookie/i,/document\.write\s*\(/i,/window\.location/i,/innerHTML/i].some(n=>n.test(e))}const Nb=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,GF=function(e,t){const r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{path:"/"},i=encodeURIComponent(t);let s=`${e}=${i}`;if(r.maxAge>0){const l=r.maxAge-0;if(Number.isNaN(l))throw new Error("maxAge should be a Number");s+=`; Max-Age=${Math.floor(l)}`}if(r.domain){if(!Nb.test(r.domain))throw new TypeError("option domain is invalid");s+=`; Domain=${r.domain}`}if(r.path){if(!Nb.test(r.path))throw new TypeError("option path is invalid");s+=`; Path=${r.path}`}if(r.expires){if(typeof r.expires.toUTCString!="function")throw new TypeError("option expires is invalid");s+=`; Expires=${r.expires.toUTCString()}`}if(r.httpOnly&&(s+="; HttpOnly"),r.secure&&(s+="; Secure"),r.sameSite)switch(typeof r.sameSite=="string"?r.sameSite.toLowerCase():r.sameSite){case!0:s+="; SameSite=Strict";break;case"lax":s+="; SameSite=Lax";break;case"strict":s+="; SameSite=Strict";break;case"none":s+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}return r.partitioned&&(s+="; Partitioned"),s},Fb={create(e,t,n,r){let i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{path:"/",sameSite:"strict"};n&&(i.expires=new Date,i.expires.setTime(i.expires.getTime()+n*60*1e3)),r&&(i.domain=r),document.cookie=GF(e,t,i)},read(e){const t=`${e}=`,n=document.cookie.split(";");for(let r=0;r<n.length;r++){let i=n[r];for(;i.charAt(0)===" ";)i=i.substring(1,i.length);if(i.indexOf(t)===0)return i.substring(t.length,i.length)}return null},remove(e,t){this.create(e,"",-1,t)}};var qF={name:"cookie",lookup(e){let{lookupCookie:t}=e;if(t&&typeof document<"u")return Fb.read(t)||void 0},cacheUserLanguage(e,t){let{lookupCookie:n,cookieMinutes:r,cookieDomain:i,cookieOptions:s}=t;n&&typeof document<"u"&&Fb.create(n,e,r,i,s)}},KF={name:"querystring",lookup(e){var r;let{lookupQuerystring:t}=e,n;if(typeof window<"u"){let{search:i}=window.location;!window.location.search&&((r=window.location.hash)==null?void 0:r.indexOf("?"))>-1&&(i=window.location.hash.substring(window.location.hash.indexOf("?")));const l=i.substring(1).split("&");for(let c=0;c<l.length;c++){const d=l[c].indexOf("=");d>0&&l[c].substring(0,d)===t&&(n=l[c].substring(d+1))}}return n}},XF={name:"hash",lookup(e){var i;let{lookupHash:t,lookupFromHashIndex:n}=e,r;if(typeof window<"u"){const{hash:s}=window.location;if(s&&s.length>2){const l=s.substring(1);if(t){const c=l.split("&");for(let d=0;d<c.length;d++){const f=c[d].indexOf("=");f>0&&c[d].substring(0,f)===t&&(r=c[d].substring(f+1))}}if(r)return r;if(!r&&n>-1){const c=s.match(/\/([a-zA-Z-]*)/g);return Array.isArray(c)?(i=c[typeof n=="number"?n:0])==null?void 0:i.replace("/",""):void 0}}}return r}};let Ja=null;const Mb=()=>{if(Ja!==null)return Ja;try{if(Ja=typeof window<"u"&&window.localStorage!==null,!Ja)return!1;const e="i18next.translate.boo";window.localStorage.setItem(e,"foo"),window.localStorage.removeItem(e)}catch{Ja=!1}return Ja};var QF={name:"localStorage",lookup(e){let{lookupLocalStorage:t}=e;if(t&&Mb())return window.localStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupLocalStorage:n}=t;n&&Mb()&&window.localStorage.setItem(n,e)}};let Za=null;const Ob=()=>{if(Za!==null)return Za;try{if(Za=typeof window<"u"&&window.sessionStorage!==null,!Za)return!1;const e="i18next.translate.boo";window.sessionStorage.setItem(e,"foo"),window.sessionStorage.removeItem(e)}catch{Za=!1}return Za};var YF={name:"sessionStorage",lookup(e){let{lookupSessionStorage:t}=e;if(t&&Ob())return window.sessionStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupSessionStorage:n}=t;n&&Ob()&&window.sessionStorage.setItem(n,e)}},JF={name:"navigator",lookup(e){const t=[];if(typeof navigator<"u"){const{languages:n,userLanguage:r,language:i}=navigator;if(n)for(let s=0;s<n.length;s++)t.push(n[s]);r&&t.push(r),i&&t.push(i)}return t.length>0?t:void 0}},ZF={name:"htmlTag",lookup(e){let{htmlTag:t}=e,n;const r=t||(typeof document<"u"?document.documentElement:null);return r&&typeof r.getAttribute=="function"&&(n=r.getAttribute("lang")),n}},eM={name:"path",lookup(e){var i;let{lookupFromPathIndex:t}=e;if(typeof window>"u")return;const n=window.location.pathname.match(/\/([a-zA-Z-]*)/g);return Array.isArray(n)?(i=n[typeof t=="number"?t:0])==null?void 0:i.replace("/",""):void 0}},tM={name:"subdomain",lookup(e){var i,s;let{lookupFromSubdomainIndex:t}=e;const n=typeof t=="number"?t+1:1,r=typeof window<"u"&&((s=(i=window.location)==null?void 0:i.hostname)==null?void 0:s.match(/^(\w{2,5})\.(([a-z0-9-]{1,63}\.[a-z]{2,6})|localhost)/i));if(r)return r[n]}};let fS=!1;try{document.cookie,fS=!0}catch{}const hS=["querystring","cookie","localStorage","sessionStorage","navigator","htmlTag"];fS||hS.splice(1,1);const nM=()=>({order:hS,lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"],convertDetectedLanguage:e=>e});class pS{constructor(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.type="languageDetector",this.detectors={},this.init(t,n)}init(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{languageUtils:{}},n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=t,this.options=HF(n,this.options||{},nM()),typeof this.options.convertDetectedLanguage=="string"&&this.options.convertDetectedLanguage.indexOf("15897")>-1&&(this.options.convertDetectedLanguage=i=>i.replace("-","_")),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=r,this.addDetector(qF),this.addDetector(KF),this.addDetector(QF),this.addDetector(YF),this.addDetector(JF),this.addDetector(ZF),this.addDetector(eM),this.addDetector(tM),this.addDetector(XF)}addDetector(t){return this.detectors[t.name]=t,this}detect(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.options.order,n=[];return t.forEach(r=>{if(this.detectors[r]){let i=this.detectors[r].lookup(this.options);i&&typeof i=="string"&&(i=[i]),i&&(n=n.concat(i))}}),n=n.filter(r=>r!=null&&!WF(r)).map(r=>this.options.convertDetectedLanguage(r)),this.services&&this.services.languageUtils&&this.services.languageUtils.getBestMatchFromCodes?n:n.length>0?n[0]:null}cacheUserLanguage(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.options.caches;n&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(t)>-1||n.forEach(r=>{this.detectors[r]&&this.detectors[r].cacheUserLanguage(t,this.options)}))}}pS.type="languageDetector";const rM={title:"TreeLab",subtitle:"Manage git worktrees in current repository via UI",table:{path:"Path",branch:"Branch / HEAD",flags:"Flags",actions:"Actions"},empty:"No worktrees found. Make sure you started UI in a git repository.",details:"Details",detailsPanel:{path:"Path",branch:"Branch",main:"Main Worktree",yes:"Yes",no:"No",head:"HEAD"},selectToView:"Select a worktree to view details.",help:{title:"Help",desc:"Check target path before deletion. Main worktree cannot be deleted.",viewCommands:"View Commands Reference"},actions:{copy:"Copy",lock:"Lock",unlock:"Unlock",ide:"IDE",folder:"Folder",delete:"Delete"},toast:{copySuccess:"Path copied",copyFailed:"Copy failed",lockSuccess:"Locked",lockFailed:"Lock failed",unlockSuccess:"Unlocked",unlockFailed:"Unlock failed",ideSuccess:"Opened in IDE",ideFailed:"Failed to open IDE",folderSuccess:"Folder opened",folderFailed:"Failed to open folder",deleteSuccess:"Deleted",forceDeleteSuccess:"Force deleted",deleteFailed:"Delete failed",deleteWarning:"Uncommitted changes or untracked files detected. Please confirm if you want to force delete."},deleteModal:{title:"Confirm Deletion",forceTitle:"Force Delete Confirmation",desc:"The following worktree will be removed:",warning:"Uncommitted changes detected. Force deletion will lose these changes!",normalNote:"Git may refuse to delete if there are uncommitted changes.",cancel:"Cancel",confirm:"Delete",forceConfirm:"Force Delete",deleting:"Deleting..."}},iM={title:"Create Worktree",back:"Back",help:"Help",tabs:{existing:"Existing Branch/Commit",new:"New Branch"},fields:{ref:"Ref (Branch name or commit)",refPlaceholder:"e.g. main / feature/x / 3a2f...",newBranch:"New Branch",newBranchPlaceholder:"e.g. feature/awesome",path:"Path (Relative to repo root or absolute path)",pathPlaceholder:"e.g. worktrees/feature-x"},submit:"Create",preview:{title:"Will Execute",desc:"UI only calls local API, actual git commands are executed on your machine."},result:{title:"Result",creating:"Creating...",success:"Created successfully",backToList:"Back to list",empty:"Results will be shown here after creation."}},oM={title:"Settings",preferences:{title:"Preferences",theme:"Theme Mode",language:"Language",light:"Light",dark:"Dark",system:"System",en:"English",zh:"中文"},cli:{title:"CLI Configuration",baseDir:"baseDir",baseDirPlaceholder:"Default storage location, e.g. ../",openCommand:"openCommand",openCommandPlaceholder:"Leave empty for auto-detect (open / start / xdg-open)",editorCommand:"editorCommand",editorCommandPlaceholder:"e.g. code / cursor / trae",reset:"Reset",save:"Save Config"},maintenance:{title:"Maintenance",prune:"Prune Invalid Worktrees",pruneDesc:"Executes `git worktree prune` to remove worktree records that no longer exist."},note:{title:"Note",desc:"Settings are saved in `~/.config/wtree/config.json`, UI reads and writes via local API."},toast:{saveSuccess:"Configuration saved",saveFailed:"Failed to save configuration",pruneSuccess:"Prune completed",pruneFailed:"Prune failed"}},sM={title:"Changes",viewStaged:"Diff",stagedFiles:"Staged",unstagedFiles:"Unstaged",diffPreview:"Diff preview",noChanges:"No changes in this worktree.",selectFile:"Select a file to view diff",noDiffContent:"No diff content for this file",commits:"Commits",copyDiff:"Copy Diff",close:"Close",toast:{copied:"Diff copied to clipboard",copyFailed:"Failed to copy diff"}},aM={title:"Help",commands:"Commands Reference",commandsDesc:"Running without parameters will enter interactive CLI; adding --ui will start local UI.",faq:{title:"FAQ",q1:"Not in a git repository?",a1:"Run inside a repository, or use `wtree --repo /path/to/repo` to specify path.",q2:"Port already in use?",a2:"Use `wtree --ui --port 0` to let system auto-assign a port.",q3:"Delete failed (uncommitted changes)?",a3:"Force Delete is supported in both CLI and UI modes, but please note that uncommitted changes will be lost."}},lM={worktrees:rM,create:iM,settings:oM,diff:sM,helpPage:aM},cM={title:"TreeLab",subtitle:"通过 UI 管理当前仓库的 git worktree",table:{path:"路径",branch:"分支 / HEAD",flags:"标志",actions:"操作"},empty:"未读取到 worktree。确认你在 git 仓库中启动了 UI。",details:"详情",detailsPanel:{path:"路径",branch:"分支",main:"主 Worktree",yes:"是",no:"否",head:"HEAD"},selectToView:"选择一个 worktree 查看详情。",help:{title:"帮助",desc:"删除前确认目标路径,主 worktree 无法删除。",viewCommands:"查看命令速查"},actions:{copy:"复制",lock:"锁定",unlock:"解锁",ide:"IDE",folder:"文件夹",delete:"删除"},toast:{copySuccess:"已复制路径",copyFailed:"复制失败",lockSuccess:"已锁定",lockFailed:"锁定失败",unlockSuccess:"已解锁",unlockFailed:"解锁失败",ideSuccess:"已在 IDE 打开",ideFailed:"打开 IDE 失败",folderSuccess:"已打开文件夹",folderFailed:"打开文件夹失败",deleteSuccess:"已删除",forceDeleteSuccess:"已强制删除",deleteFailed:"删除失败",deleteWarning:"存在未提交更改或未跟踪文件。请确认是否强制删除。"},deleteModal:{title:"确认删除",forceTitle:"强制删除确认",desc:"将移除以下 worktree:",warning:"检测到未提交更改。强制删除将丢失这些更改!",normalNote:"如果存在未提交更改,git 可能会拒绝删除。",cancel:"取消",confirm:"删除",forceConfirm:"强制删除",deleting:"删除中..."}},uM={title:"创建 Worktree",back:"返回",help:"帮助",tabs:{existing:"现有分支/提交",new:"新分支"},fields:{ref:"Ref(分支名或 commit)",refPlaceholder:"例如 main / feature/x / 3a2f...",newBranch:"New Branch",newBranchPlaceholder:"例如 feature/awesome",path:"Path(相对 repo root 或绝对路径)",pathPlaceholder:"例如 worktrees/feature-x"},submit:"创建",preview:{title:"将执行",desc:"UI 仅调用本地 API,实际执行 git 命令发生在你的机器上。"},result:{title:"结果",creating:"正在创建…",success:"创建成功",backToList:"回到列表",empty:"提交创建后会在这里显示结果。"}},dM={title:"设置",preferences:{title:"偏好设置",theme:"主题模式",language:"语言",light:"浅色",dark:"深色",system:"跟随系统",en:"English",zh:"中文"},cli:{title:"CLI 配置",baseDir:"baseDir",baseDirPlaceholder:"默认存放在哪里,例如 ../",openCommand:"openCommand",openCommandPlaceholder:"留空自动检测 (open / start / xdg-open)",editorCommand:"editorCommand",editorCommandPlaceholder:"例如 code / cursor / trae",reset:"重置",save:"保存配置"},maintenance:{title:"维护",prune:"清理无效 Worktree (Prune)",pruneDesc:"执行 `git worktree prune`,移除已不存在的 worktree 记录。"},note:{title:"说明",desc:"设置保存在 `~/.config/wtree/config.json`,UI 通过本地 API 读写。"},toast:{saveSuccess:"已保存配置",saveFailed:"保存失败",pruneSuccess:"清理完成",pruneFailed:"清理失败"}},fM={title:"变更",viewStaged:"Diff",stagedFiles:"已暂存",unstagedFiles:"未暂存",diffPreview:"Diff 预览",noChanges:"该 worktree 没有变动。",selectFile:"选择文件查看 diff",noDiffContent:"该文件没有 diff 内容",commits:"提交记录",copyDiff:"复制 Diff",close:"关闭",toast:{copied:"Diff 已复制到剪贴板",copyFailed:"复制 Diff 失败"}},hM={title:"帮助",commands:"命令速查",commandsDesc:"默认不带参数会进入交互式命令行;加上 --ui 会启动本地 UI。",faq:{title:"常见问题",q1:"不在 git 仓库目录?",a1:"在仓库内运行,或用 `wtree --repo /path/to/repo` 指定路径。",q2:"端口被占用?",a2:"使用 `wtree --ui --port 0` 让系统自动分配端口。",q3:"删除失败(有未提交更改)?",a3:"在 CLI 模式和 UI 模式下均已支持强制删除(Force Delete),但请注意未提交的更改会丢失。"}},pM={worktrees:cM,create:uM,settings:dM,diff:fM,helpPage:hM};On.use(pS).use(F3).init({resources:{en:{translation:lM},zh:{translation:pM}},fallbackLng:"en",interpolation:{escapeValue:!1}});DC.createRoot(document.getElementById("root")).render(P.jsx(B.StrictMode,{children:P.jsx(VF,{})}));