@dayinxisheng/zreadbrow 1.11.0 → 1.17.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (417) hide show
  1. package/bin/zreadbrow.js +14 -2
  2. package/dist/public/assets/AIPanel-C-YfdAam.js +40 -0
  3. package/dist/public/assets/MermaidBlock-CPVuAdRJ.js +1 -0
  4. package/dist/public/assets/MermaidViewerModal-BRk7-q4K.js +33 -0
  5. package/dist/public/assets/ReferenceModal-B916Di7q.js +52 -0
  6. package/dist/public/assets/SettingsModal-CTBLFFSS.js +23 -0
  7. package/dist/public/assets/_baseUniq-m7cimItk.js +1 -0
  8. package/dist/public/assets/abap-BdImnpbu.js +1 -0
  9. package/dist/public/assets/actionscript-3-CoDkCxhg.js +1 -0
  10. package/dist/public/assets/ada-bCR0ucgS.js +1 -0
  11. package/dist/public/assets/andromeeda-C4gqWexZ.js +1 -0
  12. package/dist/public/assets/angular-html-CU67Zn6k.js +1 -0
  13. package/dist/public/assets/angular-ts-BwZT4LLn.js +1 -0
  14. package/dist/public/assets/apache-Pmp26Uib.js +1 -0
  15. package/dist/public/assets/apex-D8_7TLub.js +1 -0
  16. package/dist/public/assets/apl-dKokRX4l.js +1 -0
  17. package/dist/public/assets/applescript-Co6uUVPk.js +1 -0
  18. package/dist/public/assets/ara-BRHolxvo.js +1 -0
  19. package/dist/public/assets/architectureDiagram-Q4EWVU46-DtqSqMGf.js +36 -0
  20. package/dist/public/assets/asciidoc-Ve4PFQV2.js +1 -0
  21. package/dist/public/assets/asm-D_Q5rh1f.js +1 -0
  22. package/dist/public/assets/astro-CbQHKStN.js +1 -0
  23. package/dist/public/assets/aurora-x-D-2ljcwZ.js +1 -0
  24. package/dist/public/assets/awk-DMzUqQB5.js +1 -0
  25. package/dist/public/assets/ayu-dark-DYE7WIF3.js +1 -0
  26. package/dist/public/assets/ayu-light-BA47KaF1.js +1 -0
  27. package/dist/public/assets/ayu-mirage-32ctXXKs.js +1 -0
  28. package/dist/public/assets/ballerina-BFfxhgS-.js +1 -0
  29. package/dist/public/assets/bat-BkioyH1T.js +1 -0
  30. package/dist/public/assets/beancount-k_qm7-4y.js +1 -0
  31. package/dist/public/assets/berry-uYugtg8r.js +1 -0
  32. package/dist/public/assets/bibtex-CHM0blh-.js +1 -0
  33. package/dist/public/assets/bicep-Bmn6On1c.js +1 -0
  34. package/dist/public/assets/bird2-DPOp833l.js +1 -0
  35. package/dist/public/assets/blade-D4QpJJKB.js +1 -0
  36. package/dist/public/assets/{blockDiagram-DXYQGD6D-3nHn8zf8.js → blockDiagram-DXYQGD6D-CgFuSL-z.js} +5 -5
  37. package/dist/public/assets/bsl-BO_Y6i37.js +1 -0
  38. package/dist/public/assets/c-BIGW1oBm.js +1 -0
  39. package/dist/public/assets/c3-eo99z4R2.js +1 -0
  40. package/dist/public/assets/{c4Diagram-AHTNJAMY-C_avfzvA.js → c4Diagram-AHTNJAMY-CUE7rn2p.js} +1 -1
  41. package/dist/public/assets/cadence-Bv_4Rxtq.js +1 -0
  42. package/dist/public/assets/cairo-KRGpt6FW.js +1 -0
  43. package/dist/public/assets/catppuccin-frappe-DFWUc33u.js +1 -0
  44. package/dist/public/assets/catppuccin-latte-C9dUb6Cb.js +1 -0
  45. package/dist/public/assets/catppuccin-macchiato-DQyhUUbL.js +1 -0
  46. package/dist/public/assets/catppuccin-mocha-D87Tk5Gz.js +1 -0
  47. package/dist/public/assets/chunk-4BX2VUAB-zMHqNRcr.js +1 -0
  48. package/dist/public/assets/{chunk-4TB4RGXK-CtC9TRDU.js → chunk-4TB4RGXK-BpV3pxqF.js} +1 -1
  49. package/dist/public/assets/chunk-55IACEB6-1YjEpZd0.js +1 -0
  50. package/dist/public/assets/chunk-EDXVE4YY-CeBjdSJX.js +1 -0
  51. package/dist/public/assets/{chunk-FMBD7UC4-5FxcCMNb.js → chunk-FMBD7UC4-oyXy72V1.js} +1 -1
  52. package/dist/public/assets/{chunk-OYMX7WX6-l29TJ9n4.js → chunk-OYMX7WX6-CQB5A9wm.js} +1 -1
  53. package/dist/public/assets/chunk-QZHKN3VN-C6V5KhDH.js +1 -0
  54. package/dist/public/assets/chunk-YZCP3GAM-Cvl0MM85.js +1 -0
  55. package/dist/public/assets/clarity-D53aC0YG.js +1 -0
  56. package/dist/public/assets/classDiagram-6PBFFD2Q-DHxKXnDK.js +1 -0
  57. package/dist/public/assets/classDiagram-v2-HSJHXN6E-DHxKXnDK.js +1 -0
  58. package/dist/public/assets/clojure-P80f7IUj.js +1 -0
  59. package/dist/public/assets/clone-B_44hGXQ.js +1 -0
  60. package/dist/public/assets/cmake-D1j8_8rp.js +1 -0
  61. package/dist/public/assets/cobol-nwyudZeR.js +1 -0
  62. package/dist/public/assets/codeowners-Bp6g37R7.js +1 -0
  63. package/dist/public/assets/codeql-DsOJ9woJ.js +1 -0
  64. package/dist/public/assets/coffee-Ch7k5sss.js +1 -0
  65. package/dist/public/assets/common-lisp-Cg-RD9OK.js +1 -0
  66. package/dist/public/assets/coq-DkFqJrB1.js +1 -0
  67. package/dist/public/assets/cose-bilkent-S5V4N54A-tP2GUtP-.js +1 -0
  68. package/dist/public/assets/cpp-CofmeUqb.js +1 -0
  69. package/dist/public/assets/crystal-tKQVLTB8.js +1 -0
  70. package/dist/public/assets/csharp-COcwbKMJ.js +1 -0
  71. package/dist/public/assets/css-DPfMkruS.js +1 -0
  72. package/dist/public/assets/csv-fuZLfV_i.js +1 -0
  73. package/dist/public/assets/cue-D82EKSYY.js +1 -0
  74. package/dist/public/assets/cypher-COkxafJQ.js +1 -0
  75. package/dist/public/assets/d-85-TOEBH.js +1 -0
  76. package/dist/public/assets/dagre-KV5264BT-Evq-yC-H.js +4 -0
  77. package/dist/public/assets/dark-plus-C3mMm8J8.js +1 -0
  78. package/dist/public/assets/dart-CF10PKvl.js +1 -0
  79. package/dist/public/assets/dax-CEL-wOlO.js +1 -0
  80. package/dist/public/assets/desktop-BmXAJ9_W.js +1 -0
  81. package/dist/public/assets/diagram-5BDNPKRD-C9IEP2hE.js +10 -0
  82. package/dist/public/assets/diagram-G4DWMVQ6-BCLMvrx-.js +24 -0
  83. package/dist/public/assets/diagram-MMDJMWI5-DxJ3dga5.js +43 -0
  84. package/dist/public/assets/diagram-TYMM5635-BOJIcEla.js +24 -0
  85. package/dist/public/assets/diff-D97Zzqfu.js +1 -0
  86. package/dist/public/assets/docker-BcOcwvcX.js +1 -0
  87. package/dist/public/assets/dotenv-Da5cRb03.js +1 -0
  88. package/dist/public/assets/dracula-BzJJZx-M.js +1 -0
  89. package/dist/public/assets/dracula-soft-BXkSAIEj.js +1 -0
  90. package/dist/public/assets/dream-maker-BtqSS_iP.js +1 -0
  91. package/dist/public/assets/edge-BkV0erSs.js +1 -0
  92. package/dist/public/assets/elixir-CDX3lj18.js +1 -0
  93. package/dist/public/assets/elm-DbKCFpqz.js +1 -0
  94. package/dist/public/assets/emacs-lisp-C9XAeP06.js +1 -0
  95. package/dist/public/assets/{erDiagram-SMLLAGMA-BDyPv2cw.js → erDiagram-SMLLAGMA-aXA9Q1fI.js} +4 -4
  96. package/dist/public/assets/erb-B12qg9BL.js +1 -0
  97. package/dist/public/assets/erlang-DsQrWhSR.js +1 -0
  98. package/dist/public/assets/everforest-dark-BgDCqdQA.js +1 -0
  99. package/dist/public/assets/everforest-light-C8M2exoo.js +1 -0
  100. package/dist/public/assets/fennel-BYunw83y.js +1 -0
  101. package/dist/public/assets/fish-BvzEVeQv.js +1 -0
  102. package/dist/public/assets/{flowDiagram-DWJPFMVM-Br4kn9xF.js → flowDiagram-DWJPFMVM-BjEk7JcK.js} +4 -4
  103. package/dist/public/assets/fluent-C4IJs8-o.js +1 -0
  104. package/dist/public/assets/fortran-fixed-form-CkoXwp7k.js +1 -0
  105. package/dist/public/assets/fortran-free-form-BxgE0vQu.js +1 -0
  106. package/dist/public/assets/fsharp-CXgrBDvD.js +1 -0
  107. package/dist/public/assets/ganttDiagram-T4ZO3ILL-D3u7X5y3.js +292 -0
  108. package/dist/public/assets/gdresource-BOOCDP_w.js +1 -0
  109. package/dist/public/assets/gdscript-C5YyOfLZ.js +1 -0
  110. package/dist/public/assets/gdshader-DkwncUOv.js +1 -0
  111. package/dist/public/assets/genie-D0YGMca9.js +1 -0
  112. package/dist/public/assets/gherkin-DyxjwDmM.js +1 -0
  113. package/dist/public/assets/git-commit-F4YmCXRG.js +1 -0
  114. package/dist/public/assets/git-rebase-r7XF79zn.js +1 -0
  115. package/dist/public/assets/gitGraphDiagram-UUTBAWPF-oEcGoRSk.js +106 -0
  116. package/dist/public/assets/github-dark-DHJKELXO.js +1 -0
  117. package/dist/public/assets/github-dark-default-Cuk6v7N8.js +1 -0
  118. package/dist/public/assets/github-dark-dimmed-DH5Ifo-i.js +1 -0
  119. package/dist/public/assets/github-dark-high-contrast-E3gJ1_iC.js +1 -0
  120. package/dist/public/assets/github-light-DAi9KRSo.js +1 -0
  121. package/dist/public/assets/github-light-default-D7oLnXFd.js +1 -0
  122. package/dist/public/assets/github-light-high-contrast-BfjtVDDH.js +1 -0
  123. package/dist/public/assets/gleam-BspZqrRM.js +1 -0
  124. package/dist/public/assets/glimmer-js-Rg0-pVw9.js +1 -0
  125. package/dist/public/assets/glimmer-ts-U6CK756n.js +1 -0
  126. package/dist/public/assets/glsl-DplSGwfg.js +1 -0
  127. package/dist/public/assets/gn-n2N0HUVH.js +1 -0
  128. package/dist/public/assets/gnuplot-DdkO51Og.js +1 -0
  129. package/dist/public/assets/go-CxLEBnE3.js +1 -0
  130. package/dist/public/assets/graph-lVZ_cjbT.js +1 -0
  131. package/dist/public/assets/graphql-ChdNCCLP.js +1 -0
  132. package/dist/public/assets/groovy-gcz8RCvz.js +1 -0
  133. package/dist/public/assets/gruvbox-dark-hard-CFHQjOhq.js +1 -0
  134. package/dist/public/assets/gruvbox-dark-medium-GsRaNv29.js +1 -0
  135. package/dist/public/assets/gruvbox-dark-soft-CVdnzihN.js +1 -0
  136. package/dist/public/assets/gruvbox-light-hard-CH1njM8p.js +1 -0
  137. package/dist/public/assets/gruvbox-light-medium-DRw_LuNl.js +1 -0
  138. package/dist/public/assets/gruvbox-light-soft-hJgmCMqR.js +1 -0
  139. package/dist/public/assets/hack-CaT9iCJl.js +1 -0
  140. package/dist/public/assets/haml-B8DHNrY2.js +1 -0
  141. package/dist/public/assets/handlebars-BL8al0AC.js +1 -0
  142. package/dist/public/assets/haskell-Df6bDoY_.js +1 -0
  143. package/dist/public/assets/haxe-CzTSHFRz.js +1 -0
  144. package/dist/public/assets/hcl-BWvSN4gD.js +1 -0
  145. package/dist/public/assets/highlighted-body-OFNGDK62-DkdBx1s2.js +1 -0
  146. package/dist/public/assets/hjson-D5-asLiD.js +1 -0
  147. package/dist/public/assets/hlsl-D3lLCCz7.js +1 -0
  148. package/dist/public/assets/horizon-BUw7H-hv.js +1 -0
  149. package/dist/public/assets/horizon-bright-Cn-bp-IR.js +1 -0
  150. package/dist/public/assets/houston-DnULxvSX.js +1 -0
  151. package/dist/public/assets/html-GMplVEZG.js +1 -0
  152. package/dist/public/assets/html-derivative-BFtXZ54Q.js +1 -0
  153. package/dist/public/assets/http-jrhK8wxY.js +1 -0
  154. package/dist/public/assets/hurl-irOxFIW8.js +1 -0
  155. package/dist/public/assets/hxml-Bvhsp5Yf.js +1 -0
  156. package/dist/public/assets/hy-DFXneXwc.js +1 -0
  157. package/dist/public/assets/imba-DGztddWO.js +1 -0
  158. package/dist/public/assets/index-BmQ-wOlB.js +482 -0
  159. package/dist/public/assets/index-F37uDERb.css +1 -0
  160. package/dist/public/assets/infoDiagram-42DDH7IO-C28F97oa.js +2 -0
  161. package/dist/public/assets/ini-BEwlwnbL.js +1 -0
  162. package/dist/public/assets/{ishikawaDiagram-UXIWVN3A-DfjfB3Z9.js → ishikawaDiagram-UXIWVN3A-D59D4ZGk.js} +5 -5
  163. package/dist/public/assets/java-CylS5w8V.js +1 -0
  164. package/dist/public/assets/javascript-wDzz0qaB.js +1 -0
  165. package/dist/public/assets/jinja-4LBKfQ-Z.js +1 -0
  166. package/dist/public/assets/jison-wvAkD_A8.js +1 -0
  167. package/dist/public/assets/{journeyDiagram-VCZTEJTY-Cv4XDTnO.js → journeyDiagram-VCZTEJTY-DshaLFkN.js} +6 -6
  168. package/dist/public/assets/json-Cp-IABpG.js +1 -0
  169. package/dist/public/assets/json5-C9tS-k6U.js +1 -0
  170. package/dist/public/assets/jsonc-Des-eS-w.js +1 -0
  171. package/dist/public/assets/jsonl-DcaNXYhu.js +1 -0
  172. package/dist/public/assets/jsonnet-DFQXde-d.js +1 -0
  173. package/dist/public/assets/jssm-C2t-YnRu.js +1 -0
  174. package/dist/public/assets/jsx-g9-lgVsj.js +1 -0
  175. package/dist/public/assets/julia-CxzCAyBv.js +1 -0
  176. package/dist/public/assets/just-Cw27pwNe.js +1 -0
  177. package/dist/public/assets/kanagawa-dragon-CkXjmgJE.js +1 -0
  178. package/dist/public/assets/kanagawa-lotus-CfQXZHmo.js +1 -0
  179. package/dist/public/assets/kanagawa-wave-DWedfzmr.js +1 -0
  180. package/dist/public/assets/{kanban-definition-6JOO6SKY-DVuIyZC8.js → kanban-definition-6JOO6SKY-C2g7cjfd.js} +7 -7
  181. package/dist/public/assets/kdl-DV7GczEv.js +1 -0
  182. package/dist/public/assets/kotlin-BdnUsdx6.js +1 -0
  183. package/dist/public/assets/kusto-DZf3V79B.js +1 -0
  184. package/dist/public/assets/laserwave-DUszq2jm.js +1 -0
  185. package/dist/public/assets/latex-CWtU0Tv5.js +1 -0
  186. package/dist/public/assets/layout-CnqOUuXe.js +1 -0
  187. package/dist/public/assets/lean-BZvkOJ9d.js +1 -0
  188. package/dist/public/assets/less-B1dDrJ26.js +1 -0
  189. package/dist/public/assets/light-plus-B7mTdjB0.js +1 -0
  190. package/dist/public/assets/liquid-DYVedYrR.js +1 -0
  191. package/dist/public/assets/llvm-DjAJT7YJ.js +1 -0
  192. package/dist/public/assets/log-2UxHyX5q.js +1 -0
  193. package/dist/public/assets/logo-BtOb2qkB.js +1 -0
  194. package/dist/public/assets/lua-BaeVxFsk.js +1 -0
  195. package/dist/public/assets/luau-C-HG3fhB.js +1 -0
  196. package/dist/public/assets/make-CHLpvVh8.js +1 -0
  197. package/dist/public/assets/markdown-Cvjx9yec.js +1 -0
  198. package/dist/public/assets/marko-CnJfTvn9.js +1 -0
  199. package/dist/public/assets/material-theme-D5KoaKCx.js +1 -0
  200. package/dist/public/assets/material-theme-darker-BfHTSMKl.js +1 -0
  201. package/dist/public/assets/material-theme-lighter-B0m2ddpp.js +1 -0
  202. package/dist/public/assets/material-theme-ocean-CyktbL80.js +1 -0
  203. package/dist/public/assets/material-theme-palenight-Csfq5Kiy.js +1 -0
  204. package/dist/public/assets/matlab-D7o27uSR.js +1 -0
  205. package/dist/public/assets/mdc-BMNejdWA.js +1 -0
  206. package/dist/public/assets/mdx-Cmh6b_Ma.js +1 -0
  207. package/dist/public/assets/mermaid-CF-QbALk.js +309 -0
  208. package/dist/public/assets/mermaid-mWjccvbQ.js +1 -0
  209. package/dist/public/assets/min-DIoUV2Ll.js +1 -0
  210. package/dist/public/assets/min-dark-CafNBF8u.js +1 -0
  211. package/dist/public/assets/min-light-CTRr51gU.js +1 -0
  212. package/dist/public/assets/{mindmap-definition-QFDTVHPH-CKXc6pGW.js → mindmap-definition-QFDTVHPH-Cuart2gs.js} +3 -3
  213. package/dist/public/assets/mipsasm-CKIfxQSi.js +1 -0
  214. package/dist/public/assets/mojo-rZm6bMo-.js +1 -0
  215. package/dist/public/assets/monokai-D4h5O-jR.js +1 -0
  216. package/dist/public/assets/moonbit-_H4v1dQx.js +1 -0
  217. package/dist/public/assets/move-IF9eRakj.js +1 -0
  218. package/dist/public/assets/narrat-DRg8JJMk.js +1 -0
  219. package/dist/public/assets/nextflow-Zz6hmt5N.js +1 -0
  220. package/dist/public/assets/nextflow-groovy-BeH2EWoN.js +1 -0
  221. package/dist/public/assets/nginx-BpAMiNFr.js +1 -0
  222. package/dist/public/assets/night-owl-C39BiMTA.js +1 -0
  223. package/dist/public/assets/night-owl-light-CMTm3GFP.js +1 -0
  224. package/dist/public/assets/nim-CVrawwO9.js +1 -0
  225. package/dist/public/assets/nix-CwoSXNpI.js +1 -0
  226. package/dist/public/assets/nord-Ddv68eIx.js +1 -0
  227. package/dist/public/assets/nushell-Cz2AlsmD.js +1 -0
  228. package/dist/public/assets/objective-c-DXmwc3jG.js +1 -0
  229. package/dist/public/assets/objective-cpp-CLxacb5B.js +1 -0
  230. package/dist/public/assets/ocaml-C0hk2d4L.js +1 -0
  231. package/dist/public/assets/odin-BBf5iR-q.js +1 -0
  232. package/dist/public/assets/one-dark-pro-DVMEJ2y_.js +1 -0
  233. package/dist/public/assets/one-light-C3Wv6jpd.js +1 -0
  234. package/dist/public/assets/openscad-C4EeE6gA.js +1 -0
  235. package/dist/public/assets/pascal-D93ZcfNL.js +1 -0
  236. package/dist/public/assets/perl-C0TMdlhV.js +1 -0
  237. package/dist/public/assets/php-Dhbhpdrm.js +1 -0
  238. package/dist/public/assets/pieDiagram-DEJITSTG-DDYdBumO.js +30 -0
  239. package/dist/public/assets/pkl-u5AG7uiY.js +1 -0
  240. package/dist/public/assets/plastic-3e1v2bzS.js +1 -0
  241. package/dist/public/assets/plsql-ChMvpjG-.js +1 -0
  242. package/dist/public/assets/po-BTJTHyun.js +1 -0
  243. package/dist/public/assets/poimandres-CS3Unz2-.js +1 -0
  244. package/dist/public/assets/polar-C0HS_06l.js +1 -0
  245. package/dist/public/assets/postcss-CXtECtnM.js +1 -0
  246. package/dist/public/assets/powerquery-CEu0bR-o.js +1 -0
  247. package/dist/public/assets/powershell-Dpen1YoG.js +1 -0
  248. package/dist/public/assets/prisma-Dd19v3D-.js +1 -0
  249. package/dist/public/assets/prolog-CbFg5uaA.js +1 -0
  250. package/dist/public/assets/proto-C7zT0LnQ.js +1 -0
  251. package/dist/public/assets/pug-CGlum2m_.js +1 -0
  252. package/dist/public/assets/puppet-BMWR74SV.js +1 -0
  253. package/dist/public/assets/purescript-CklMAg4u.js +1 -0
  254. package/dist/public/assets/python-B6aJPvgy.js +1 -0
  255. package/dist/public/assets/qml-3beO22l8.js +1 -0
  256. package/dist/public/assets/qmldir-C8lEn-DE.js +1 -0
  257. package/dist/public/assets/qss-IeuSbFQv.js +1 -0
  258. package/dist/public/assets/{quadrantDiagram-34T5L4WZ-DybJJDPI.js → quadrantDiagram-34T5L4WZ-1M4jQ4aT.js} +2 -2
  259. package/dist/public/assets/r-Dspwwk_N.js +1 -0
  260. package/dist/public/assets/racket-BqYA7rlc.js +1 -0
  261. package/dist/public/assets/raku-DXvB9xmW.js +1 -0
  262. package/dist/public/assets/razor-Uh8Bk_45.js +1 -0
  263. package/dist/public/assets/red-bN70gL4F.js +1 -0
  264. package/dist/public/assets/reg-C-SQnVFl.js +1 -0
  265. package/dist/public/assets/regexp-CDVJQ6XC.js +1 -0
  266. package/dist/public/assets/rel-C3B-1QV4.js +1 -0
  267. package/dist/public/assets/{requirementDiagram-MS252O5E-Bf2NfnQO.js → requirementDiagram-MS252O5E-cbWppHFa.js} +3 -3
  268. package/dist/public/assets/riscv-BM1_JUlF.js +1 -0
  269. package/dist/public/assets/ron-D8l8udqQ.js +1 -0
  270. package/dist/public/assets/rose-pine-dawn-DHQR4-dF.js +1 -0
  271. package/dist/public/assets/rose-pine-moon-D4_iv3hh.js +1 -0
  272. package/dist/public/assets/rose-pine-qdsjHGoJ.js +1 -0
  273. package/dist/public/assets/rosmsg-BJDFO7_C.js +1 -0
  274. package/dist/public/assets/rst-BrH8l1NY.js +1 -0
  275. package/dist/public/assets/ruby-Dw2BHqvy.js +1 -0
  276. package/dist/public/assets/rust-B1yitclQ.js +1 -0
  277. package/dist/public/assets/sankeyDiagram-XADWPNL6-4D4rvcjw.js +10 -0
  278. package/dist/public/assets/sas-cz2c8ADy.js +1 -0
  279. package/dist/public/assets/sass-Cj5Yp3dK.js +1 -0
  280. package/dist/public/assets/scala-C151Ov-r.js +1 -0
  281. package/dist/public/assets/scheme-C98Dy4si.js +1 -0
  282. package/dist/public/assets/scss-OYdSNvt2.js +1 -0
  283. package/dist/public/assets/sdbl-DVxCFoDh.js +1 -0
  284. package/dist/public/assets/{sequenceDiagram-FGHM5R23-BKsfKx1K.js → sequenceDiagram-FGHM5R23-ComC2-Sc.js} +1 -1
  285. package/dist/public/assets/shaderlab-Dg9Lc6iA.js +1 -0
  286. package/dist/public/assets/shellscript-Yzrsuije.js +1 -0
  287. package/dist/public/assets/shellsession-BADoaaVG.js +1 -0
  288. package/dist/public/assets/slack-dark-BthQWCQV.js +1 -0
  289. package/dist/public/assets/slack-ochin-DqwNpetd.js +1 -0
  290. package/dist/public/assets/smalltalk-BERRCDM3.js +1 -0
  291. package/dist/public/assets/snazzy-light-Bw305WKR.js +1 -0
  292. package/dist/public/assets/solarized-dark-DXbdFlpD.js +1 -0
  293. package/dist/public/assets/solarized-light-L9t79GZl.js +1 -0
  294. package/dist/public/assets/solidity-rGO070M0.js +1 -0
  295. package/dist/public/assets/soy-Brmx7dQM.js +1 -0
  296. package/dist/public/assets/sparql-rVzFXLq3.js +1 -0
  297. package/dist/public/assets/splunk-BtCnVYZw.js +1 -0
  298. package/dist/public/assets/sql-BLtJtn59.js +1 -0
  299. package/dist/public/assets/ssh-config-_ykCGR6B.js +1 -0
  300. package/dist/public/assets/stata-BH5u7GGu.js +1 -0
  301. package/dist/public/assets/stateDiagram-FHFEXIEX-8nR4RqyL.js +1 -0
  302. package/dist/public/assets/stateDiagram-v2-QKLJ7IA2-sni4Ws2p.js +1 -0
  303. package/dist/public/assets/stylus-BEDo0Tqx.js +1 -0
  304. package/dist/public/assets/surrealql-Bq5Q-fJD.js +1 -0
  305. package/dist/public/assets/svelte-C_ipcX3V.js +1 -0
  306. package/dist/public/assets/swift-D82vCrfD.js +1 -0
  307. package/dist/public/assets/synthwave-84-CbfX1IO0.js +1 -0
  308. package/dist/public/assets/system-verilog-CnnmHF94.js +1 -0
  309. package/dist/public/assets/systemd-4A_iFExJ.js +1 -0
  310. package/dist/public/assets/talonscript-CkByrt1z.js +1 -0
  311. package/dist/public/assets/tasl-QIJgUcNo.js +1 -0
  312. package/dist/public/assets/tcl-dwOrl1Do.js +1 -0
  313. package/dist/public/assets/templ-P3uqSqPl.js +1 -0
  314. package/dist/public/assets/terraform-BETggiCN.js +1 -0
  315. package/dist/public/assets/tex-idrVyKtj.js +1 -0
  316. package/dist/public/assets/{timeline-definition-GMOUNBTQ-DvnJe1xm.js → timeline-definition-GMOUNBTQ-CWEAkGhb.js} +4 -4
  317. package/dist/public/assets/tokyo-night-hegEt444.js +1 -0
  318. package/dist/public/assets/toml-vGWfd6FD.js +1 -0
  319. package/dist/public/assets/ts-tags-zn1MmPIZ.js +1 -0
  320. package/dist/public/assets/tsv-B_m7g4N7.js +1 -0
  321. package/dist/public/assets/tsx-COt5Ahok.js +1 -0
  322. package/dist/public/assets/turtle-BsS91CYL.js +1 -0
  323. package/dist/public/assets/twig-DNn4PbVi.js +1 -0
  324. package/dist/public/assets/typescript-BPQ3VLAy.js +1 -0
  325. package/dist/public/assets/typespec-BGHnOYBU.js +1 -0
  326. package/dist/public/assets/typst-DHCkPAjA.js +1 -0
  327. package/dist/public/assets/v-BcVCzyr7.js +1 -0
  328. package/dist/public/assets/vala-CsfeWuGM.js +1 -0
  329. package/dist/public/assets/vb-D17OF-Vu.js +1 -0
  330. package/dist/public/assets/vennDiagram-DHZGUBPP-BCUB4Y59.js +34 -0
  331. package/dist/public/assets/verilog-BQ8w6xss.js +1 -0
  332. package/dist/public/assets/vesper-DU1UobuO.js +1 -0
  333. package/dist/public/assets/vhdl-CeAyd5Ju.js +1 -0
  334. package/dist/public/assets/viml-CJc9bBzg.js +1 -0
  335. package/dist/public/assets/vitesse-black-Bkuqu6BP.js +1 -0
  336. package/dist/public/assets/vitesse-dark-D0r3Knsf.js +1 -0
  337. package/dist/public/assets/vitesse-light-CVO1_9PV.js +1 -0
  338. package/dist/public/assets/vue-DN_0RTcg.js +1 -0
  339. package/dist/public/assets/vue-html-AaS7Mt5G.js +1 -0
  340. package/dist/public/assets/vue-vine-CQOfvN7w.js +1 -0
  341. package/dist/public/assets/vyper-CDx5xZoG.js +1 -0
  342. package/dist/public/assets/{wardley-RL74JXVD-D2KKM-ae.js → wardley-RL74JXVD-fcUo-Wrg.js} +1 -1
  343. package/dist/public/assets/{wardleyDiagram-NUSXRM2D-CgU6PntZ.js → wardleyDiagram-NUSXRM2D-q0nyo3Bx.js} +2 -2
  344. package/dist/public/assets/wasm-CG6Dc4jp.js +1 -0
  345. package/dist/public/assets/wasm-MzD3tlZU.js +1 -0
  346. package/dist/public/assets/wenyan-BV7otONQ.js +1 -0
  347. package/dist/public/assets/wgsl-Dx-B1_4e.js +1 -0
  348. package/dist/public/assets/wikitext-BhOHFoWU.js +1 -0
  349. package/dist/public/assets/wit-5i3qLPDT.js +1 -0
  350. package/dist/public/assets/wolfram-lXgVvXCa.js +1 -0
  351. package/dist/public/assets/xml-sdJ4AIDG.js +1 -0
  352. package/dist/public/assets/xsl-CtQFsRM5.js +1 -0
  353. package/dist/public/assets/xychartDiagram-5P7HB3ND-tZNDsxpi.js +7 -0
  354. package/dist/public/assets/yaml-Buea-lGh.js +1 -0
  355. package/dist/public/assets/zenscript-DVFEvuxE.js +1 -0
  356. package/dist/public/assets/zig-VOosw3JB.js +1 -0
  357. package/dist/public/index.html +3 -2
  358. package/dist/server/index.js +1 -1
  359. package/dist/server/middleware/errorHandler.js +1 -1
  360. package/dist/server/middleware/requestId.js +1 -0
  361. package/dist/server/routes/ai.js +1 -1
  362. package/dist/server/routes/config.js +1 -1
  363. package/dist/server/routes/files.js +1 -1
  364. package/dist/server/routes/projects.js +1 -1
  365. package/dist/server/routes/scan.js +1 -1
  366. package/dist/server/routes/search.js +1 -1
  367. package/dist/server/routes/wiki.js +1 -1
  368. package/dist/server/services/ai.js +1 -1
  369. package/dist/server/services/cache.js +1 -0
  370. package/dist/server/services/config.js +1 -1
  371. package/dist/server/services/jieba.js +1 -0
  372. package/dist/server/services/logger.js +1 -1
  373. package/dist/server/services/scanner.js +1 -1
  374. package/dist/server/services/search-db.js +1 -0
  375. package/dist/server/services/search-index.js +1 -0
  376. package/dist/server/services/search-query.js +1 -0
  377. package/dist/server/services/tokenizer.js +1 -0
  378. package/dist/server/services/wiki-loader.js +1 -1
  379. package/dist/server/services/wire-reader.js +1 -1
  380. package/package.json +7 -2
  381. package/dist/public/assets/_baseUniq-CIRdfd93.js +0 -1
  382. package/dist/public/assets/arc-B4HYSrvA.js +0 -1
  383. package/dist/public/assets/architectureDiagram-Q4EWVU46-0_RoxIgJ.js +0 -36
  384. package/dist/public/assets/channel-C_s5gQOv.js +0 -1
  385. package/dist/public/assets/chunk-4BX2VUAB-BMX7hm6-.js +0 -1
  386. package/dist/public/assets/chunk-55IACEB6-4D0opfow.js +0 -1
  387. package/dist/public/assets/chunk-EDXVE4YY-BTYCYeSV.js +0 -1
  388. package/dist/public/assets/chunk-QZHKN3VN-g-pg8y3p.js +0 -1
  389. package/dist/public/assets/chunk-YZCP3GAM-BxtZpO--.js +0 -1
  390. package/dist/public/assets/classDiagram-6PBFFD2Q-CCnUlGd6.js +0 -1
  391. package/dist/public/assets/classDiagram-v2-HSJHXN6E-CCnUlGd6.js +0 -1
  392. package/dist/public/assets/clone-BS2Igb5a.js +0 -1
  393. package/dist/public/assets/cose-bilkent-S5V4N54A-5D-AKbEI.js +0 -1
  394. package/dist/public/assets/dagre-KV5264BT-Bl_Le1O-.js +0 -4
  395. package/dist/public/assets/defaultLocale-DX6XiGOO.js +0 -1
  396. package/dist/public/assets/diagram-5BDNPKRD-CzudIMvW.js +0 -10
  397. package/dist/public/assets/diagram-G4DWMVQ6-DNJC7zTX.js +0 -24
  398. package/dist/public/assets/diagram-MMDJMWI5-ClyZac9f.js +0 -43
  399. package/dist/public/assets/diagram-TYMM5635-C2VtQrAC.js +0 -24
  400. package/dist/public/assets/ganttDiagram-T4ZO3ILL-CCZKa7FC.js +0 -292
  401. package/dist/public/assets/gitGraphDiagram-UUTBAWPF-CN-Jq39o.js +0 -106
  402. package/dist/public/assets/graph-D5eDsOmP.js +0 -1
  403. package/dist/public/assets/index-BWRrOkja.js +0 -642
  404. package/dist/public/assets/index-BjF0IeXr.css +0 -1
  405. package/dist/public/assets/infoDiagram-42DDH7IO-Be00z2FM.js +0 -2
  406. package/dist/public/assets/init-Gi6I4Gst.js +0 -1
  407. package/dist/public/assets/layout-De98Fcvm.js +0 -1
  408. package/dist/public/assets/linear-DfyVEr5l.js +0 -1
  409. package/dist/public/assets/min-DAsKehOd.js +0 -1
  410. package/dist/public/assets/ordinal-Cboi1Yqb.js +0 -1
  411. package/dist/public/assets/pieDiagram-DEJITSTG-CEFpX8n7.js +0 -30
  412. package/dist/public/assets/sankeyDiagram-XADWPNL6-dcULupfk.js +0 -10
  413. package/dist/public/assets/stateDiagram-FHFEXIEX-CC3CoOpe.js +0 -1
  414. package/dist/public/assets/stateDiagram-v2-QKLJ7IA2-zQUzTqNB.js +0 -1
  415. package/dist/public/assets/vennDiagram-DHZGUBPP-CzmFX1Iv.js +0 -34
  416. package/dist/public/assets/xychartDiagram-5P7HB3ND-CU6AHPc5.js +0 -7
  417. package/dist/server/services/search.js +0 -1
@@ -0,0 +1,309 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/dagre-KV5264BT-Evq-yC-H.js","assets/graph-lVZ_cjbT.js","assets/_baseUniq-m7cimItk.js","assets/layout-CnqOUuXe.js","assets/min-DIoUV2Ll.js","assets/clone-B_44hGXQ.js","assets/cose-bilkent-S5V4N54A-tP2GUtP-.js","assets/cytoscape.esm-DxGcaOPV.js","assets/c4Diagram-AHTNJAMY-CUE7rn2p.js","assets/chunk-YZCP3GAM-Cvl0MM85.js","assets/flowDiagram-DWJPFMVM-BjEk7JcK.js","assets/chunk-FMBD7UC4-oyXy72V1.js","assets/chunk-55IACEB6-1YjEpZd0.js","assets/chunk-EDXVE4YY-CeBjdSJX.js","assets/erDiagram-SMLLAGMA-aXA9Q1fI.js","assets/gitGraphDiagram-UUTBAWPF-oEcGoRSk.js","assets/chunk-4BX2VUAB-zMHqNRcr.js","assets/chunk-QZHKN3VN-C6V5KhDH.js","assets/wardley-RL74JXVD-fcUo-Wrg.js","assets/infoDiagram-42DDH7IO-C28F97oa.js","assets/pieDiagram-DEJITSTG-DDYdBumO.js","assets/requirementDiagram-MS252O5E-cbWppHFa.js","assets/sequenceDiagram-FGHM5R23-ComC2-Sc.js","assets/classDiagram-6PBFFD2Q-DHxKXnDK.js","assets/chunk-4TB4RGXK-BpV3pxqF.js","assets/classDiagram-v2-HSJHXN6E-DHxKXnDK.js","assets/stateDiagram-FHFEXIEX-8nR4RqyL.js","assets/chunk-OYMX7WX6-CQB5A9wm.js","assets/stateDiagram-v2-QKLJ7IA2-sni4Ws2p.js","assets/journeyDiagram-VCZTEJTY-DshaLFkN.js","assets/mindmap-definition-QFDTVHPH-Cuart2gs.js","assets/kanban-definition-6JOO6SKY-C2g7cjfd.js","assets/diagram-TYMM5635-BOJIcEla.js","assets/diagram-MMDJMWI5-DxJ3dga5.js","assets/blockDiagram-DXYQGD6D-CgFuSL-z.js","assets/diagram-5BDNPKRD-C9IEP2hE.js","assets/architectureDiagram-Q4EWVU46-DtqSqMGf.js","assets/diagram-G4DWMVQ6-BCLMvrx-.js","assets/wardleyDiagram-NUSXRM2D-q0nyo3Bx.js"])))=>i.map(i=>d[i]);
2
+ var jC=Object.defineProperty;var GC=(e,t,r)=>t in e?jC(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var St=(e,t,r)=>GC(e,typeof t!="symbol"?t+"":t,r);function XC(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function S$(e){if(Object.prototype.hasOwnProperty.call(e,"__esModule"))return e;var t=e.default;if(typeof t=="function"){var r=function i(){return this instanceof i?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(e).forEach(function(i){var a=Object.getOwnPropertyDescriptor(e,i);Object.defineProperty(r,i,a.get?a:{enumerable:!0,get:function(){return e[i]}})}),r}const VC="modulepreload",ZC=function(e){return"/"+e},Fc={},Ct=function(t,r,i){let a=Promise.resolve();if(r&&r.length>0){let o=function(h){return Promise.all(h.map(c=>Promise.resolve(c).then(u=>({status:"fulfilled",value:u}),u=>({status:"rejected",reason:u}))))};document.getElementsByTagName("link");const n=document.querySelector("meta[property=csp-nonce]"),l=(n==null?void 0:n.nonce)||(n==null?void 0:n.getAttribute("nonce"));a=o(r.map(h=>{if(h=ZC(h),h in Fc)return;Fc[h]=!0;const c=h.endsWith(".css"),u=c?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${h}"]${u}`))return;const f=document.createElement("link");if(f.rel=c?"stylesheet":VC,c||(f.as="script"),f.crossOrigin="",f.href=h,l&&f.setAttribute("nonce",l),document.head.appendChild(f),c)return new Promise((d,p)=>{f.addEventListener("load",d),f.addEventListener("error",()=>p(new Error(`Unable to preload CSS for ${h}`)))})}))}function s(o){const n=new Event("vite:preloadError",{cancelable:!0});if(n.payload=o,window.dispatchEvent(n),!n.defaultPrevented)throw o}return a.then(o=>{for(const n of o||[])n.status==="rejected"&&s(n.reason);return t().catch(s)})};var Ss={exports:{}},QC=Ss.exports,Mc;function KC(){return Mc||(Mc=1,(function(e,t){(function(r,i){e.exports=i()})(QC,(function(){var r=1e3,i=6e4,a=36e5,s="millisecond",o="second",n="minute",l="hour",h="day",c="week",u="month",f="quarter",d="year",p="date",g="Invalid Date",m=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,C=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,x={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(M){var $=["th","st","nd","rd"],A=M%100;return"["+M+($[(A-20)%10]||$[A]||$[0])+"]"}},k=function(M,$,A){var O=String(M);return!O||O.length>=$?M:""+Array($+1-O.length).join(A)+M},w={s:k,z:function(M){var $=-M.utcOffset(),A=Math.abs($),O=Math.floor(A/60),F=A%60;return($<=0?"+":"-")+k(O,2,"0")+":"+k(F,2,"0")},m:function M($,A){if($.date()<A.date())return-M(A,$);var O=12*(A.year()-$.year())+(A.month()-$.month()),F=$.clone().add(O,u),H=A-F<0,Y=$.clone().add(O+(H?-1:1),u);return+(-(O+(A-F)/(H?F-Y:Y-F))||0)},a:function(M){return M<0?Math.ceil(M)||0:Math.floor(M)},p:function(M){return{M:u,y:d,w:c,d:h,D:p,h:l,m:n,s:o,ms:s,Q:f}[M]||String(M||"").toLowerCase().replace(/s$/,"")},u:function(M){return M===void 0}},S="en",_={};_[S]=x;var T="$isDayjsObject",B=function(M){return M instanceof N||!(!M||!M[T])},z=function M($,A,O){var F;if(!$)return S;if(typeof $=="string"){var H=$.toLowerCase();_[H]&&(F=H),A&&(_[H]=A,F=H);var Y=$.split("-");if(!F&&Y.length>1)return M(Y[0])}else{var Z=$.name;_[Z]=$,F=Z}return!O&&F&&(S=F),F||!O&&S},I=function(M,$){if(B(M))return M.clone();var A=typeof $=="object"?$:{};return A.date=M,A.args=arguments,new N(A)},E=w;E.l=z,E.i=B,E.w=function(M,$){return I(M,{locale:$.$L,utc:$.$u,x:$.$x,$offset:$.$offset})};var N=(function(){function M(A){this.$L=z(A.locale,null,!0),this.parse(A),this.$x=this.$x||A.x||{},this[T]=!0}var $=M.prototype;return $.parse=function(A){this.$d=(function(O){var F=O.date,H=O.utc;if(F===null)return new Date(NaN);if(E.u(F))return new Date;if(F instanceof Date)return new Date(F);if(typeof F=="string"&&!/Z$/i.test(F)){var Y=F.match(m);if(Y){var Z=Y[2]-1||0,ut=(Y[7]||"0").substring(0,3);return H?new Date(Date.UTC(Y[1],Z,Y[3]||1,Y[4]||0,Y[5]||0,Y[6]||0,ut)):new Date(Y[1],Z,Y[3]||1,Y[4]||0,Y[5]||0,Y[6]||0,ut)}}return new Date(F)})(A),this.init()},$.init=function(){var A=this.$d;this.$y=A.getFullYear(),this.$M=A.getMonth(),this.$D=A.getDate(),this.$W=A.getDay(),this.$H=A.getHours(),this.$m=A.getMinutes(),this.$s=A.getSeconds(),this.$ms=A.getMilliseconds()},$.$utils=function(){return E},$.isValid=function(){return this.$d.toString()!==g},$.isSame=function(A,O){var F=I(A);return this.startOf(O)<=F&&F<=this.endOf(O)},$.isAfter=function(A,O){return I(A)<this.startOf(O)},$.isBefore=function(A,O){return this.endOf(O)<I(A)},$.$g=function(A,O,F){return E.u(A)?this[O]:this.set(F,A)},$.unix=function(){return Math.floor(this.valueOf()/1e3)},$.valueOf=function(){return this.$d.getTime()},$.startOf=function(A,O){var F=this,H=!!E.u(O)||O,Y=E.p(A),Z=function(X,U){var G=E.w(F.$u?Date.UTC(F.$y,U,X):new Date(F.$y,U,X),F);return H?G:G.endOf(h)},ut=function(X,U){return E.w(F.toDate()[X].apply(F.toDate("s"),(H?[0,0,0,0]:[23,59,59,999]).slice(U)),F)},at=this.$W,dt=this.$M,Q=this.$D,xt="set"+(this.$u?"UTC":"");switch(Y){case d:return H?Z(1,0):Z(31,11);case u:return H?Z(1,dt):Z(0,dt+1);case c:var vt=this.$locale().weekStart||0,Bt=(at<vt?at+7:at)-vt;return Z(H?Q-Bt:Q+(6-Bt),dt);case h:case p:return ut(xt+"Hours",0);case l:return ut(xt+"Minutes",1);case n:return ut(xt+"Seconds",2);case o:return ut(xt+"Milliseconds",3);default:return this.clone()}},$.endOf=function(A){return this.startOf(A,!1)},$.$set=function(A,O){var F,H=E.p(A),Y="set"+(this.$u?"UTC":""),Z=(F={},F[h]=Y+"Date",F[p]=Y+"Date",F[u]=Y+"Month",F[d]=Y+"FullYear",F[l]=Y+"Hours",F[n]=Y+"Minutes",F[o]=Y+"Seconds",F[s]=Y+"Milliseconds",F)[H],ut=H===h?this.$D+(O-this.$W):O;if(H===u||H===d){var at=this.clone().set(p,1);at.$d[Z](ut),at.init(),this.$d=at.set(p,Math.min(this.$D,at.daysInMonth())).$d}else Z&&this.$d[Z](ut);return this.init(),this},$.set=function(A,O){return this.clone().$set(A,O)},$.get=function(A){return this[E.p(A)]()},$.add=function(A,O){var F,H=this;A=Number(A);var Y=E.p(O),Z=function(dt){var Q=I(H);return E.w(Q.date(Q.date()+Math.round(dt*A)),H)};if(Y===u)return this.set(u,this.$M+A);if(Y===d)return this.set(d,this.$y+A);if(Y===h)return Z(1);if(Y===c)return Z(7);var ut=(F={},F[n]=i,F[l]=a,F[o]=r,F)[Y]||1,at=this.$d.getTime()+A*ut;return E.w(at,this)},$.subtract=function(A,O){return this.add(-1*A,O)},$.format=function(A){var O=this,F=this.$locale();if(!this.isValid())return F.invalidDate||g;var H=A||"YYYY-MM-DDTHH:mm:ssZ",Y=E.z(this),Z=this.$H,ut=this.$m,at=this.$M,dt=F.weekdays,Q=F.months,xt=F.meridiem,vt=function(U,G,q,ft){return U&&(U[G]||U(O,H))||q[G].slice(0,ft)},Bt=function(U){return E.s(Z%12||12,U,"0")},X=xt||function(U,G,q){var ft=U<12?"AM":"PM";return q?ft.toLowerCase():ft};return H.replace(C,(function(U,G){return G||(function(q){switch(q){case"YY":return String(O.$y).slice(-2);case"YYYY":return E.s(O.$y,4,"0");case"M":return at+1;case"MM":return E.s(at+1,2,"0");case"MMM":return vt(F.monthsShort,at,Q,3);case"MMMM":return vt(Q,at);case"D":return O.$D;case"DD":return E.s(O.$D,2,"0");case"d":return String(O.$W);case"dd":return vt(F.weekdaysMin,O.$W,dt,2);case"ddd":return vt(F.weekdaysShort,O.$W,dt,3);case"dddd":return dt[O.$W];case"H":return String(Z);case"HH":return E.s(Z,2,"0");case"h":return Bt(1);case"hh":return Bt(2);case"a":return X(Z,ut,!0);case"A":return X(Z,ut,!1);case"m":return String(ut);case"mm":return E.s(ut,2,"0");case"s":return String(O.$s);case"ss":return E.s(O.$s,2,"0");case"SSS":return E.s(O.$ms,3,"0");case"Z":return Y}return null})(U)||Y.replace(":","")}))},$.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},$.diff=function(A,O,F){var H,Y=this,Z=E.p(O),ut=I(A),at=(ut.utcOffset()-this.utcOffset())*i,dt=this-ut,Q=function(){return E.m(Y,ut)};switch(Z){case d:H=Q()/12;break;case u:H=Q();break;case f:H=Q()/3;break;case c:H=(dt-at)/6048e5;break;case h:H=(dt-at)/864e5;break;case l:H=dt/a;break;case n:H=dt/i;break;case o:H=dt/r;break;default:H=dt}return F?H:E.a(H)},$.daysInMonth=function(){return this.endOf(u).$D},$.$locale=function(){return _[this.$L]},$.locale=function(A,O){if(!A)return this.$L;var F=this.clone(),H=z(A,O,!0);return H&&(F.$L=H),F},$.clone=function(){return E.w(this.$d,this)},$.toDate=function(){return new Date(this.valueOf())},$.toJSON=function(){return this.isValid()?this.toISOString():null},$.toISOString=function(){return this.$d.toISOString()},$.toString=function(){return this.$d.toUTCString()},M})(),D=N.prototype;return I.prototype=D,[["$ms",s],["$s",o],["$m",n],["$H",l],["$W",h],["$M",u],["$y",d],["$D",p]].forEach((function(M){D[M[1]]=function($){return this.$g($,M[0],M[1])}})),I.extend=function(M,$){return M.$i||(M($,N,I),M.$i=!0),I},I.locale=z,I.isDayjs=B,I.unix=function(M){return I(1e3*M)},I.en=_[S],I.Ls=_,I.p={},I}))})(Ss)),Ss.exports}var JC=KC();const tx=XC(JC);var Hd=Object.defineProperty,y=(e,t)=>Hd(e,"name",{value:t,configurable:!0}),ex=(e,t)=>{for(var r in t)Hd(e,r,{get:t[r],enumerable:!0})},Qe={trace:0,debug:1,info:2,warn:3,error:4,fatal:5},W={trace:y((...e)=>{},"trace"),debug:y((...e)=>{},"debug"),info:y((...e)=>{},"info"),warn:y((...e)=>{},"warn"),error:y((...e)=>{},"error"),fatal:y((...e)=>{},"fatal")},ah=y(function(e="fatal"){let t=Qe.fatal;typeof e=="string"?e.toLowerCase()in Qe&&(t=Qe[e]):typeof e=="number"&&(t=e),W.trace=()=>{},W.debug=()=>{},W.info=()=>{},W.warn=()=>{},W.error=()=>{},W.fatal=()=>{},t<=Qe.fatal&&(W.fatal=console.error?console.error.bind(console,xe("FATAL"),"color: orange"):console.log.bind(console,"\x1B[35m",xe("FATAL"))),t<=Qe.error&&(W.error=console.error?console.error.bind(console,xe("ERROR"),"color: orange"):console.log.bind(console,"\x1B[31m",xe("ERROR"))),t<=Qe.warn&&(W.warn=console.warn?console.warn.bind(console,xe("WARN"),"color: orange"):console.log.bind(console,"\x1B[33m",xe("WARN"))),t<=Qe.info&&(W.info=console.info?console.info.bind(console,xe("INFO"),"color: lightblue"):console.log.bind(console,"\x1B[34m",xe("INFO"))),t<=Qe.debug&&(W.debug=console.debug?console.debug.bind(console,xe("DEBUG"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",xe("DEBUG"))),t<=Qe.trace&&(W.trace=console.debug?console.debug.bind(console,xe("TRACE"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",xe("TRACE")))},"setLogLevel"),xe=y(e=>`%c${tx().format("ss.SSS")} : ${e} : `,"format");const vs={min:{r:0,g:0,b:0,s:0,l:0,a:0},max:{r:255,g:255,b:255,h:360,s:100,l:100,a:1},clamp:{r:e=>e>=255?255:e<0?0:e,g:e=>e>=255?255:e<0?0:e,b:e=>e>=255?255:e<0?0:e,h:e=>e%360,s:e=>e>=100?100:e<0?0:e,l:e=>e>=100?100:e<0?0:e,a:e=>e>=1?1:e<0?0:e},toLinear:e=>{const t=e/255;return e>.03928?Math.pow((t+.055)/1.055,2.4):t/12.92},hue2rgb:(e,t,r)=>(r<0&&(r+=1),r>1&&(r-=1),r<1/6?e+(t-e)*6*r:r<1/2?t:r<2/3?e+(t-e)*(2/3-r)*6:e),hsl2rgb:({h:e,s:t,l:r},i)=>{if(!t)return r*2.55;e/=360,t/=100,r/=100;const a=r<.5?r*(1+t):r+t-r*t,s=2*r-a;switch(i){case"r":return vs.hue2rgb(s,a,e+1/3)*255;case"g":return vs.hue2rgb(s,a,e)*255;case"b":return vs.hue2rgb(s,a,e-1/3)*255}},rgb2hsl:({r:e,g:t,b:r},i)=>{e/=255,t/=255,r/=255;const a=Math.max(e,t,r),s=Math.min(e,t,r),o=(a+s)/2;if(i==="l")return o*100;if(a===s)return 0;const n=a-s,l=o>.5?n/(2-a-s):n/(a+s);if(i==="s")return l*100;switch(a){case e:return((t-r)/n+(t<r?6:0))*60;case t:return((r-e)/n+2)*60;case r:return((e-t)/n+4)*60;default:return-1}}},rx={clamp:(e,t,r)=>t>r?Math.min(t,Math.max(r,e)):Math.min(r,Math.max(t,e)),round:e=>Math.round(e*1e10)/1e10},ix={dec2hex:e=>{const t=Math.round(e).toString(16);return t.length>1?t:`0${t}`}},ct={channel:vs,lang:rx,unit:ix},pr={};for(let e=0;e<=255;e++)pr[e]=ct.unit.dec2hex(e);const Zt={ALL:0,RGB:1,HSL:2};class ax{constructor(){this.type=Zt.ALL}get(){return this.type}set(t){if(this.type&&this.type!==t)throw new Error("Cannot change both RGB and HSL channels at the same time");this.type=t}reset(){this.type=Zt.ALL}is(t){return this.type===t}}class sx{constructor(t,r){this.color=r,this.changed=!1,this.data=t,this.type=new ax}set(t,r){return this.color=r,this.changed=!1,this.data=t,this.type.type=Zt.ALL,this}_ensureHSL(){const t=this.data,{h:r,s:i,l:a}=t;r===void 0&&(t.h=ct.channel.rgb2hsl(t,"h")),i===void 0&&(t.s=ct.channel.rgb2hsl(t,"s")),a===void 0&&(t.l=ct.channel.rgb2hsl(t,"l"))}_ensureRGB(){const t=this.data,{r,g:i,b:a}=t;r===void 0&&(t.r=ct.channel.hsl2rgb(t,"r")),i===void 0&&(t.g=ct.channel.hsl2rgb(t,"g")),a===void 0&&(t.b=ct.channel.hsl2rgb(t,"b"))}get r(){const t=this.data,r=t.r;return!this.type.is(Zt.HSL)&&r!==void 0?r:(this._ensureHSL(),ct.channel.hsl2rgb(t,"r"))}get g(){const t=this.data,r=t.g;return!this.type.is(Zt.HSL)&&r!==void 0?r:(this._ensureHSL(),ct.channel.hsl2rgb(t,"g"))}get b(){const t=this.data,r=t.b;return!this.type.is(Zt.HSL)&&r!==void 0?r:(this._ensureHSL(),ct.channel.hsl2rgb(t,"b"))}get h(){const t=this.data,r=t.h;return!this.type.is(Zt.RGB)&&r!==void 0?r:(this._ensureRGB(),ct.channel.rgb2hsl(t,"h"))}get s(){const t=this.data,r=t.s;return!this.type.is(Zt.RGB)&&r!==void 0?r:(this._ensureRGB(),ct.channel.rgb2hsl(t,"s"))}get l(){const t=this.data,r=t.l;return!this.type.is(Zt.RGB)&&r!==void 0?r:(this._ensureRGB(),ct.channel.rgb2hsl(t,"l"))}get a(){return this.data.a}set r(t){this.type.set(Zt.RGB),this.changed=!0,this.data.r=t}set g(t){this.type.set(Zt.RGB),this.changed=!0,this.data.g=t}set b(t){this.type.set(Zt.RGB),this.changed=!0,this.data.b=t}set h(t){this.type.set(Zt.HSL),this.changed=!0,this.data.h=t}set s(t){this.type.set(Zt.HSL),this.changed=!0,this.data.s=t}set l(t){this.type.set(Zt.HSL),this.changed=!0,this.data.l=t}set a(t){this.changed=!0,this.data.a=t}}const Io=new sx({r:0,g:0,b:0,a:0},"transparent"),gi={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:e=>{if(e.charCodeAt(0)!==35)return;const t=e.match(gi.re);if(!t)return;const r=t[1],i=parseInt(r,16),a=r.length,s=a%4===0,o=a>4,n=o?1:17,l=o?8:4,h=s?0:-1,c=o?255:15;return Io.set({r:(i>>l*(h+3)&c)*n,g:(i>>l*(h+2)&c)*n,b:(i>>l*(h+1)&c)*n,a:s?(i&c)*n/255:1},e)},stringify:e=>{const{r:t,g:r,b:i,a}=e;return a<1?`#${pr[Math.round(t)]}${pr[Math.round(r)]}${pr[Math.round(i)]}${pr[Math.round(a*255)]}`:`#${pr[Math.round(t)]}${pr[Math.round(r)]}${pr[Math.round(i)]}`}},Er={re:/^hsla?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(?:deg|grad|rad|turn)?)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(%)?))?\s*?\)$/i,hueRe:/^(.+?)(deg|grad|rad|turn)$/i,_hue2deg:e=>{const t=e.match(Er.hueRe);if(t){const[,r,i]=t;switch(i){case"grad":return ct.channel.clamp.h(parseFloat(r)*.9);case"rad":return ct.channel.clamp.h(parseFloat(r)*180/Math.PI);case"turn":return ct.channel.clamp.h(parseFloat(r)*360)}}return ct.channel.clamp.h(parseFloat(e))},parse:e=>{const t=e.charCodeAt(0);if(t!==104&&t!==72)return;const r=e.match(Er.re);if(!r)return;const[,i,a,s,o,n]=r;return Io.set({h:Er._hue2deg(i),s:ct.channel.clamp.s(parseFloat(a)),l:ct.channel.clamp.l(parseFloat(s)),a:o?ct.channel.clamp.a(n?parseFloat(o)/100:parseFloat(o)):1},e)},stringify:e=>{const{h:t,s:r,l:i,a}=e;return a<1?`hsla(${ct.lang.round(t)}, ${ct.lang.round(r)}%, ${ct.lang.round(i)}%, ${a})`:`hsl(${ct.lang.round(t)}, ${ct.lang.round(r)}%, ${ct.lang.round(i)}%)`}},wa={colors:{aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyanaqua:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",transparent:"#00000000",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},parse:e=>{e=e.toLowerCase();const t=wa.colors[e];if(t)return gi.parse(t)},stringify:e=>{const t=gi.stringify(e);for(const r in wa.colors)if(wa.colors[r]===t)return r}},ga={re:/^rgba?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?)))?\s*?\)$/i,parse:e=>{const t=e.charCodeAt(0);if(t!==114&&t!==82)return;const r=e.match(ga.re);if(!r)return;const[,i,a,s,o,n,l,h,c]=r;return Io.set({r:ct.channel.clamp.r(a?parseFloat(i)*2.55:parseFloat(i)),g:ct.channel.clamp.g(o?parseFloat(s)*2.55:parseFloat(s)),b:ct.channel.clamp.b(l?parseFloat(n)*2.55:parseFloat(n)),a:h?ct.channel.clamp.a(c?parseFloat(h)/100:parseFloat(h)):1},e)},stringify:e=>{const{r:t,g:r,b:i,a}=e;return a<1?`rgba(${ct.lang.round(t)}, ${ct.lang.round(r)}, ${ct.lang.round(i)}, ${ct.lang.round(a)})`:`rgb(${ct.lang.round(t)}, ${ct.lang.round(r)}, ${ct.lang.round(i)})`}},Me={format:{keyword:wa,hex:gi,rgb:ga,rgba:ga,hsl:Er,hsla:Er},parse:e=>{if(typeof e!="string")return e;const t=gi.parse(e)||ga.parse(e)||Er.parse(e)||wa.parse(e);if(t)return t;throw new Error(`Unsupported color format: "${e}"`)},stringify:e=>!e.changed&&e.color?e.color:e.type.is(Zt.HSL)||e.data.r===void 0?Er.stringify(e):e.a<1||!Number.isInteger(e.r)||!Number.isInteger(e.g)||!Number.isInteger(e.b)?ga.stringify(e):gi.stringify(e)},Ud=(e,t)=>{const r=Me.parse(e);for(const i in t)r[i]=ct.channel.clamp[i](t[i]);return Me.stringify(r)},yr=(e,t,r=0,i=1)=>{if(typeof e!="number")return Ud(e,{a:t});const a=Io.set({r:ct.channel.clamp.r(e),g:ct.channel.clamp.g(t),b:ct.channel.clamp.b(r),a:ct.channel.clamp.a(i)});return Me.stringify(a)},v$=(e,t)=>ct.lang.round(Me.parse(e)[t]),ox=e=>{const{r:t,g:r,b:i}=Me.parse(e),a=.2126*ct.channel.toLinear(t)+.7152*ct.channel.toLinear(r)+.0722*ct.channel.toLinear(i);return ct.lang.round(a)},nx=e=>ox(e)>=.5,Ee=e=>!nx(e),sh=(e,t,r)=>{const i=Me.parse(e),a=i[t],s=ct.channel.clamp[t](a+r);return a!==s&&(i[t]=s),Me.stringify(i)},R=(e,t)=>sh(e,"l",t),P=(e,t)=>sh(e,"l",-t),B$=(e,t)=>sh(e,"a",-t),b=(e,t)=>{const r=Me.parse(e),i={};for(const a in t)t[a]&&(i[a]=r[a]+t[a]);return Ud(e,i)},lx=(e,t,r=50)=>{const{r:i,g:a,b:s,a:o}=Me.parse(e),{r:n,g:l,b:h,a:c}=Me.parse(t),u=r/100,f=u*2-1,d=o-c,g=((f*d===-1?f:(f+d)/(1+f*d))+1)/2,m=1-g,C=i*g+n*m,x=a*g+l*m,k=s*g+h*m,w=o*u+c*(1-u);return yr(C,x,k,w)},L=(e,t=100)=>{const r=Me.parse(e);return r.r=255-r.r,r.g=255-r.g,r.b=255-r.b,lx(r,e,t)};/*! @license DOMPurify 3.3.3 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.3.3/LICENSE */const{entries:Yd,setPrototypeOf:Ac,isFrozen:hx,getPrototypeOf:cx,getOwnPropertyDescriptor:ux}=Object;let{freeze:se,seal:ke,create:Bs}=Object,{apply:Kn,construct:Jn}=typeof Reflect<"u"&&Reflect;se||(se=function(t){return t});ke||(ke=function(t){return t});Kn||(Kn=function(t,r){for(var i=arguments.length,a=new Array(i>2?i-2:0),s=2;s<i;s++)a[s-2]=arguments[s];return t.apply(r,a)});Jn||(Jn=function(t){for(var r=arguments.length,i=new Array(r>1?r-1:0),a=1;a<r;a++)i[a-1]=arguments[a];return new t(...i)});const ls=oe(Array.prototype.forEach),dx=oe(Array.prototype.lastIndexOf),Ec=oe(Array.prototype.pop),Qi=oe(Array.prototype.push),fx=oe(Array.prototype.splice),Ls=oe(String.prototype.toLowerCase),xn=oe(String.prototype.toString),bn=oe(String.prototype.match),Ki=oe(String.prototype.replace),px=oe(String.prototype.indexOf),gx=oe(String.prototype.trim),ge=oe(Object.prototype.hasOwnProperty),re=oe(RegExp.prototype.test),Ji=mx(TypeError);function oe(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var r=arguments.length,i=new Array(r>1?r-1:0),a=1;a<r;a++)i[a-1]=arguments[a];return Kn(e,t,i)}}function mx(e){return function(){for(var t=arguments.length,r=new Array(t),i=0;i<t;i++)r[i]=arguments[i];return Jn(e,r)}}function mt(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Ls;Ac&&Ac(e,null);let i=t.length;for(;i--;){let a=t[i];if(typeof a=="string"){const s=r(a);s!==a&&(hx(t)||(t[i]=s),a=s)}e[a]=!0}return e}function yx(e){for(let t=0;t<e.length;t++)ge(e,t)||(e[t]=null);return e}function Pe(e){const t=Bs(null);for(const[r,i]of Yd(e))ge(e,r)&&(Array.isArray(i)?t[r]=yx(i):i&&typeof i=="object"&&i.constructor===Object?t[r]=Pe(i):t[r]=i);return t}function ta(e,t){for(;e!==null;){const i=ux(e,t);if(i){if(i.get)return oe(i.get);if(typeof i.value=="function")return oe(i.value)}e=cx(e)}function r(){return null}return r}const $c=se(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),kn=se(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),Tn=se(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),Cx=se(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),wn=se(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),xx=se(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Dc=se(["#text"]),Oc=se(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),_n=se(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Ic=se(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),hs=se(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),bx=ke(/\{\{[\w\W]*|[\w\W]*\}\}/gm),kx=ke(/<%[\w\W]*|[\w\W]*%>/gm),Tx=ke(/\$\{[\w\W]*/gm),wx=ke(/^data-[\-\w.\u00B7-\uFFFF]+$/),_x=ke(/^aria-[\-\w]+$/),jd=ke(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Sx=ke(/^(?:\w+script|data):/i),vx=ke(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Gd=ke(/^html$/i),Bx=ke(/^[a-z][.\w]*(-[.\w]+)+$/i);var Pc=Object.freeze({__proto__:null,ARIA_ATTR:_x,ATTR_WHITESPACE:vx,CUSTOM_ELEMENT:Bx,DATA_ATTR:wx,DOCTYPE_NAME:Gd,ERB_EXPR:kx,IS_ALLOWED_URI:jd,IS_SCRIPT_OR_DATA:Sx,MUSTACHE_EXPR:bx,TMPLIT_EXPR:Tx});const ea={element:1,text:3,progressingInstruction:7,comment:8,document:9},Lx=function(){return typeof window>"u"?null:window},Fx=function(t,r){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let i=null;const a="data-tt-policy-suffix";r&&r.hasAttribute(a)&&(i=r.getAttribute(a));const s="dompurify"+(i?"#"+i:"");try{return t.createPolicy(s,{createHTML(o){return o},createScriptURL(o){return o}})}catch{return console.warn("TrustedTypes policy "+s+" could not be created."),null}},Rc=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function Xd(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Lx();const t=st=>Xd(st);if(t.version="3.3.3",t.removed=[],!e||!e.document||e.document.nodeType!==ea.document||!e.Element)return t.isSupported=!1,t;let{document:r}=e;const i=r,a=i.currentScript,{DocumentFragment:s,HTMLTemplateElement:o,Node:n,Element:l,NodeFilter:h,NamedNodeMap:c=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:u,DOMParser:f,trustedTypes:d}=e,p=l.prototype,g=ta(p,"cloneNode"),m=ta(p,"remove"),C=ta(p,"nextSibling"),x=ta(p,"childNodes"),k=ta(p,"parentNode");if(typeof o=="function"){const st=r.createElement("template");st.content&&st.content.ownerDocument&&(r=st.content.ownerDocument)}let w,S="";const{implementation:_,createNodeIterator:T,createDocumentFragment:B,getElementsByTagName:z}=r,{importNode:I}=i;let E=Rc();t.isSupported=typeof Yd=="function"&&typeof k=="function"&&_&&_.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:N,ERB_EXPR:D,TMPLIT_EXPR:M,DATA_ATTR:$,ARIA_ATTR:A,IS_SCRIPT_OR_DATA:O,ATTR_WHITESPACE:F,CUSTOM_ELEMENT:H}=Pc;let{IS_ALLOWED_URI:Y}=Pc,Z=null;const ut=mt({},[...$c,...kn,...Tn,...wn,...Dc]);let at=null;const dt=mt({},[...Oc,..._n,...Ic,...hs]);let Q=Object.seal(Bs(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),xt=null,vt=null;const Bt=Object.seal(Bs(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let X=!0,U=!0,G=!1,q=!0,ft=!1,gt=!0,wt=!1,Ot=!1,Ce=!1,de=!1,rs=!1,is=!1,dc=!0,fc=!1;const RC="user-content-";let un=!0,Vi=!1,ei={},De=null;const dn=mt({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let pc=null;const gc=mt({},["audio","video","img","source","image","track"]);let fn=null;const mc=mt({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),as="http://www.w3.org/1998/Math/MathML",ss="http://www.w3.org/2000/svg",Xe="http://www.w3.org/1999/xhtml";let ri=Xe,pn=!1,gn=null;const NC=mt({},[as,ss,Xe],xn);let os=mt({},["mi","mo","mn","ms","mtext"]),ns=mt({},["annotation-xml"]);const qC=mt({},["title","style","font","a","script"]);let Zi=null;const zC=["application/xhtml+xml","text/html"],WC="text/html";let Rt=null,ii=null;const HC=r.createElement("form"),yc=function(v){return v instanceof RegExp||v instanceof Function},mn=function(){let v=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(ii&&ii===v)){if((!v||typeof v!="object")&&(v={}),v=Pe(v),Zi=zC.indexOf(v.PARSER_MEDIA_TYPE)===-1?WC:v.PARSER_MEDIA_TYPE,Rt=Zi==="application/xhtml+xml"?xn:Ls,Z=ge(v,"ALLOWED_TAGS")?mt({},v.ALLOWED_TAGS,Rt):ut,at=ge(v,"ALLOWED_ATTR")?mt({},v.ALLOWED_ATTR,Rt):dt,gn=ge(v,"ALLOWED_NAMESPACES")?mt({},v.ALLOWED_NAMESPACES,xn):NC,fn=ge(v,"ADD_URI_SAFE_ATTR")?mt(Pe(mc),v.ADD_URI_SAFE_ATTR,Rt):mc,pc=ge(v,"ADD_DATA_URI_TAGS")?mt(Pe(gc),v.ADD_DATA_URI_TAGS,Rt):gc,De=ge(v,"FORBID_CONTENTS")?mt({},v.FORBID_CONTENTS,Rt):dn,xt=ge(v,"FORBID_TAGS")?mt({},v.FORBID_TAGS,Rt):Pe({}),vt=ge(v,"FORBID_ATTR")?mt({},v.FORBID_ATTR,Rt):Pe({}),ei=ge(v,"USE_PROFILES")?v.USE_PROFILES:!1,X=v.ALLOW_ARIA_ATTR!==!1,U=v.ALLOW_DATA_ATTR!==!1,G=v.ALLOW_UNKNOWN_PROTOCOLS||!1,q=v.ALLOW_SELF_CLOSE_IN_ATTR!==!1,ft=v.SAFE_FOR_TEMPLATES||!1,gt=v.SAFE_FOR_XML!==!1,wt=v.WHOLE_DOCUMENT||!1,de=v.RETURN_DOM||!1,rs=v.RETURN_DOM_FRAGMENT||!1,is=v.RETURN_TRUSTED_TYPE||!1,Ce=v.FORCE_BODY||!1,dc=v.SANITIZE_DOM!==!1,fc=v.SANITIZE_NAMED_PROPS||!1,un=v.KEEP_CONTENT!==!1,Vi=v.IN_PLACE||!1,Y=v.ALLOWED_URI_REGEXP||jd,ri=v.NAMESPACE||Xe,os=v.MATHML_TEXT_INTEGRATION_POINTS||os,ns=v.HTML_INTEGRATION_POINTS||ns,Q=v.CUSTOM_ELEMENT_HANDLING||{},v.CUSTOM_ELEMENT_HANDLING&&yc(v.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(Q.tagNameCheck=v.CUSTOM_ELEMENT_HANDLING.tagNameCheck),v.CUSTOM_ELEMENT_HANDLING&&yc(v.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(Q.attributeNameCheck=v.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),v.CUSTOM_ELEMENT_HANDLING&&typeof v.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(Q.allowCustomizedBuiltInElements=v.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),ft&&(U=!1),rs&&(de=!0),ei&&(Z=mt({},Dc),at=Bs(null),ei.html===!0&&(mt(Z,$c),mt(at,Oc)),ei.svg===!0&&(mt(Z,kn),mt(at,_n),mt(at,hs)),ei.svgFilters===!0&&(mt(Z,Tn),mt(at,_n),mt(at,hs)),ei.mathMl===!0&&(mt(Z,wn),mt(at,Ic),mt(at,hs))),ge(v,"ADD_TAGS")||(Bt.tagCheck=null),ge(v,"ADD_ATTR")||(Bt.attributeCheck=null),v.ADD_TAGS&&(typeof v.ADD_TAGS=="function"?Bt.tagCheck=v.ADD_TAGS:(Z===ut&&(Z=Pe(Z)),mt(Z,v.ADD_TAGS,Rt))),v.ADD_ATTR&&(typeof v.ADD_ATTR=="function"?Bt.attributeCheck=v.ADD_ATTR:(at===dt&&(at=Pe(at)),mt(at,v.ADD_ATTR,Rt))),v.ADD_URI_SAFE_ATTR&&mt(fn,v.ADD_URI_SAFE_ATTR,Rt),v.FORBID_CONTENTS&&(De===dn&&(De=Pe(De)),mt(De,v.FORBID_CONTENTS,Rt)),v.ADD_FORBID_CONTENTS&&(De===dn&&(De=Pe(De)),mt(De,v.ADD_FORBID_CONTENTS,Rt)),un&&(Z["#text"]=!0),wt&&mt(Z,["html","head","body"]),Z.table&&(mt(Z,["tbody"]),delete xt.tbody),v.TRUSTED_TYPES_POLICY){if(typeof v.TRUSTED_TYPES_POLICY.createHTML!="function")throw Ji('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof v.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw Ji('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');w=v.TRUSTED_TYPES_POLICY,S=w.createHTML("")}else w===void 0&&(w=Fx(d,a)),w!==null&&typeof S=="string"&&(S=w.createHTML(""));se&&se(v),ii=v}},Cc=mt({},[...kn,...Tn,...Cx]),xc=mt({},[...wn,...xx]),UC=function(v){let j=k(v);(!j||!j.tagName)&&(j={namespaceURI:ri,tagName:"template"});const et=Ls(v.tagName),Ft=Ls(j.tagName);return gn[v.namespaceURI]?v.namespaceURI===ss?j.namespaceURI===Xe?et==="svg":j.namespaceURI===as?et==="svg"&&(Ft==="annotation-xml"||os[Ft]):!!Cc[et]:v.namespaceURI===as?j.namespaceURI===Xe?et==="math":j.namespaceURI===ss?et==="math"&&ns[Ft]:!!xc[et]:v.namespaceURI===Xe?j.namespaceURI===ss&&!ns[Ft]||j.namespaceURI===as&&!os[Ft]?!1:!xc[et]&&(qC[et]||!Cc[et]):!!(Zi==="application/xhtml+xml"&&gn[v.namespaceURI]):!1},Oe=function(v){Qi(t.removed,{element:v});try{k(v).removeChild(v)}catch{m(v)}},Sr=function(v,j){try{Qi(t.removed,{attribute:j.getAttributeNode(v),from:j})}catch{Qi(t.removed,{attribute:null,from:j})}if(j.removeAttribute(v),v==="is")if(de||rs)try{Oe(j)}catch{}else try{j.setAttribute(v,"")}catch{}},bc=function(v){let j=null,et=null;if(Ce)v="<remove></remove>"+v;else{const It=bn(v,/^[\r\n\t ]+/);et=It&&It[0]}Zi==="application/xhtml+xml"&&ri===Xe&&(v='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+v+"</body></html>");const Ft=w?w.createHTML(v):v;if(ri===Xe)try{j=new f().parseFromString(Ft,Zi)}catch{}if(!j||!j.documentElement){j=_.createDocument(ri,"template",null);try{j.documentElement.innerHTML=pn?S:Ft}catch{}}const Xt=j.body||j.documentElement;return v&&et&&Xt.insertBefore(r.createTextNode(et),Xt.childNodes[0]||null),ri===Xe?z.call(j,wt?"html":"body")[0]:wt?j.documentElement:Xt},kc=function(v){return T.call(v.ownerDocument||v,v,h.SHOW_ELEMENT|h.SHOW_COMMENT|h.SHOW_TEXT|h.SHOW_PROCESSING_INSTRUCTION|h.SHOW_CDATA_SECTION,null)},yn=function(v){return v instanceof u&&(typeof v.nodeName!="string"||typeof v.textContent!="string"||typeof v.removeChild!="function"||!(v.attributes instanceof c)||typeof v.removeAttribute!="function"||typeof v.setAttribute!="function"||typeof v.namespaceURI!="string"||typeof v.insertBefore!="function"||typeof v.hasChildNodes!="function")},Tc=function(v){return typeof n=="function"&&v instanceof n};function Ve(st,v,j){ls(st,et=>{et.call(t,v,j,ii)})}const wc=function(v){let j=null;if(Ve(E.beforeSanitizeElements,v,null),yn(v))return Oe(v),!0;const et=Rt(v.nodeName);if(Ve(E.uponSanitizeElement,v,{tagName:et,allowedTags:Z}),gt&&v.hasChildNodes()&&!Tc(v.firstElementChild)&&re(/<[/\w!]/g,v.innerHTML)&&re(/<[/\w!]/g,v.textContent)||v.nodeType===ea.progressingInstruction||gt&&v.nodeType===ea.comment&&re(/<[/\w]/g,v.data))return Oe(v),!0;if(!(Bt.tagCheck instanceof Function&&Bt.tagCheck(et))&&(!Z[et]||xt[et])){if(!xt[et]&&Sc(et)&&(Q.tagNameCheck instanceof RegExp&&re(Q.tagNameCheck,et)||Q.tagNameCheck instanceof Function&&Q.tagNameCheck(et)))return!1;if(un&&!De[et]){const Ft=k(v)||v.parentNode,Xt=x(v)||v.childNodes;if(Xt&&Ft){const It=Xt.length;for(let le=It-1;le>=0;--le){const Ze=g(Xt[le],!0);Ze.__removalCount=(v.__removalCount||0)+1,Ft.insertBefore(Ze,C(v))}}}return Oe(v),!0}return v instanceof l&&!UC(v)||(et==="noscript"||et==="noembed"||et==="noframes")&&re(/<\/no(script|embed|frames)/i,v.innerHTML)?(Oe(v),!0):(ft&&v.nodeType===ea.text&&(j=v.textContent,ls([N,D,M],Ft=>{j=Ki(j,Ft," ")}),v.textContent!==j&&(Qi(t.removed,{element:v.cloneNode()}),v.textContent=j)),Ve(E.afterSanitizeElements,v,null),!1)},_c=function(v,j,et){if(vt[j]||dc&&(j==="id"||j==="name")&&(et in r||et in HC))return!1;if(!(U&&!vt[j]&&re($,j))){if(!(X&&re(A,j))){if(!(Bt.attributeCheck instanceof Function&&Bt.attributeCheck(j,v))){if(!at[j]||vt[j]){if(!(Sc(v)&&(Q.tagNameCheck instanceof RegExp&&re(Q.tagNameCheck,v)||Q.tagNameCheck instanceof Function&&Q.tagNameCheck(v))&&(Q.attributeNameCheck instanceof RegExp&&re(Q.attributeNameCheck,j)||Q.attributeNameCheck instanceof Function&&Q.attributeNameCheck(j,v))||j==="is"&&Q.allowCustomizedBuiltInElements&&(Q.tagNameCheck instanceof RegExp&&re(Q.tagNameCheck,et)||Q.tagNameCheck instanceof Function&&Q.tagNameCheck(et))))return!1}else if(!fn[j]){if(!re(Y,Ki(et,F,""))){if(!((j==="src"||j==="xlink:href"||j==="href")&&v!=="script"&&px(et,"data:")===0&&pc[v])){if(!(G&&!re(O,Ki(et,F,"")))){if(et)return!1}}}}}}}return!0},Sc=function(v){return v!=="annotation-xml"&&bn(v,H)},vc=function(v){Ve(E.beforeSanitizeAttributes,v,null);const{attributes:j}=v;if(!j||yn(v))return;const et={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:at,forceKeepAttr:void 0};let Ft=j.length;for(;Ft--;){const Xt=j[Ft],{name:It,namespaceURI:le,value:Ze}=Xt,ai=Rt(It),Cn=Ze;let Yt=It==="value"?Cn:gx(Cn);if(et.attrName=ai,et.attrValue=Yt,et.keepAttr=!0,et.forceKeepAttr=void 0,Ve(E.uponSanitizeAttribute,v,et),Yt=et.attrValue,fc&&(ai==="id"||ai==="name")&&(Sr(It,v),Yt=RC+Yt),gt&&re(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,Yt)){Sr(It,v);continue}if(ai==="attributename"&&bn(Yt,"href")){Sr(It,v);continue}if(et.forceKeepAttr)continue;if(!et.keepAttr){Sr(It,v);continue}if(!q&&re(/\/>/i,Yt)){Sr(It,v);continue}ft&&ls([N,D,M],Lc=>{Yt=Ki(Yt,Lc," ")});const Bc=Rt(v.nodeName);if(!_c(Bc,ai,Yt)){Sr(It,v);continue}if(w&&typeof d=="object"&&typeof d.getAttributeType=="function"&&!le)switch(d.getAttributeType(Bc,ai)){case"TrustedHTML":{Yt=w.createHTML(Yt);break}case"TrustedScriptURL":{Yt=w.createScriptURL(Yt);break}}if(Yt!==Cn)try{le?v.setAttributeNS(le,It,Yt):v.setAttribute(It,Yt),yn(v)?Oe(v):Ec(t.removed)}catch{Sr(It,v)}}Ve(E.afterSanitizeAttributes,v,null)},YC=function st(v){let j=null;const et=kc(v);for(Ve(E.beforeSanitizeShadowDOM,v,null);j=et.nextNode();)Ve(E.uponSanitizeShadowNode,j,null),wc(j),vc(j),j.content instanceof s&&st(j.content);Ve(E.afterSanitizeShadowDOM,v,null)};return t.sanitize=function(st){let v=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},j=null,et=null,Ft=null,Xt=null;if(pn=!st,pn&&(st="<!-->"),typeof st!="string"&&!Tc(st))if(typeof st.toString=="function"){if(st=st.toString(),typeof st!="string")throw Ji("dirty is not a string, aborting")}else throw Ji("toString is not a function");if(!t.isSupported)return st;if(Ot||mn(v),t.removed=[],typeof st=="string"&&(Vi=!1),Vi){if(st.nodeName){const Ze=Rt(st.nodeName);if(!Z[Ze]||xt[Ze])throw Ji("root node is forbidden and cannot be sanitized in-place")}}else if(st instanceof n)j=bc("<!---->"),et=j.ownerDocument.importNode(st,!0),et.nodeType===ea.element&&et.nodeName==="BODY"||et.nodeName==="HTML"?j=et:j.appendChild(et);else{if(!de&&!ft&&!wt&&st.indexOf("<")===-1)return w&&is?w.createHTML(st):st;if(j=bc(st),!j)return de?null:is?S:""}j&&Ce&&Oe(j.firstChild);const It=kc(Vi?st:j);for(;Ft=It.nextNode();)wc(Ft),vc(Ft),Ft.content instanceof s&&YC(Ft.content);if(Vi)return st;if(de){if(rs)for(Xt=B.call(j.ownerDocument);j.firstChild;)Xt.appendChild(j.firstChild);else Xt=j;return(at.shadowroot||at.shadowrootmode)&&(Xt=I.call(i,Xt,!0)),Xt}let le=wt?j.outerHTML:j.innerHTML;return wt&&Z["!doctype"]&&j.ownerDocument&&j.ownerDocument.doctype&&j.ownerDocument.doctype.name&&re(Gd,j.ownerDocument.doctype.name)&&(le="<!DOCTYPE "+j.ownerDocument.doctype.name+`>
3
+ `+le),ft&&ls([N,D,M],Ze=>{le=Ki(le,Ze," ")}),w&&is?w.createHTML(le):le},t.setConfig=function(){let st=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};mn(st),Ot=!0},t.clearConfig=function(){ii=null,Ot=!1},t.isValidAttribute=function(st,v,j){ii||mn({});const et=Rt(st),Ft=Rt(v);return _c(et,Ft,j)},t.addHook=function(st,v){typeof v=="function"&&Qi(E[st],v)},t.removeHook=function(st,v){if(v!==void 0){const j=dx(E[st],v);return j===-1?void 0:fx(E[st],j,1)[0]}return Ec(E[st])},t.removeHooks=function(st){E[st]=[]},t.removeAllHooks=function(){E=Rc()},t}var $i=Xd(),Vd=/^-{3}\s*[\n\r](.*?)[\n\r]-{3}\s*[\n\r]+/s,_a=/%{2}{\s*(?:(\w+)\s*:|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,Mx=/\s*%%.*\n/gm,xi,Zd=(xi=class extends Error{constructor(t){super(t),this.name="UnknownDiagramError"}},y(xi,"UnknownDiagramError"),xi),Rr={},oh=y(function(e,t){e=e.replace(Vd,"").replace(_a,"").replace(Mx,`
4
+ `);for(const[r,{detector:i}]of Object.entries(Rr))if(i(e,t))return r;throw new Zd(`No diagram type detected matching given configuration for text: ${e}`)},"detectType"),tl=y((...e)=>{for(const{id:t,detector:r,loader:i}of e)Qd(t,r,i)},"registerLazyLoadedDiagrams"),Qd=y((e,t,r)=>{Rr[e]&&W.warn(`Detector with key ${e} already exists. Overwriting.`),Rr[e]={detector:t,loader:r},W.debug(`Detector with key ${e} added${r?" with loader":""}`)},"addDetector"),Ax=y(e=>Rr[e].loader,"getDiagramLoader"),el=y((e,t,{depth:r=2,clobber:i=!1}={})=>{const a={depth:r,clobber:i};return Array.isArray(t)&&!Array.isArray(e)?(t.forEach(s=>el(e,s,a)),e):Array.isArray(t)&&Array.isArray(e)?(t.forEach(s=>{e.includes(s)||e.push(s)}),e):e===void 0||r<=0?e!=null&&typeof e=="object"&&typeof t=="object"?Object.assign(e,t):t:(t!==void 0&&typeof e=="object"&&typeof t=="object"&&Object.keys(t).forEach(s=>{typeof t[s]=="object"&&t[s]!==null&&(e[s]===void 0||typeof e[s]=="object")?(e[s]===void 0&&(e[s]=Array.isArray(t[s])?[]:{}),e[s]=el(e[s],t[s],{depth:r-1,clobber:i})):(i||typeof e[s]!="object"&&typeof t[s]!="object")&&(e[s]=t[s])}),e)},"assignWithDepth"),qt=el,Ue="#ffffff",Ye="#f2f2f2",ht=y((e,t)=>t?b(e,{s:-40,l:10}):b(e,{s:-40,l:-10}),"mkBorder"),bi,Ex=(bi=class{constructor(){this.background="#f4f4f4",this.primaryColor="#fff4dd",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.useGradient=!0,this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,1))"}updateColors(){var r,i,a,s,o,n,l,h,c,u,f,d,p,g,m,C,x,k,w,S,_,T;if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||b(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||b(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ht(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ht(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ht(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ht(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||L(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||L(this.tertiaryColor),this.lineColor=this.lineColor||L(this.background),this.arrowheadColor=this.arrowheadColor||L(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||P(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||L(this.lineColor),this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||R(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.vertLineColor=this.vertLineColor||"navy",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.noteFontWeight=this.noteFontWeight||"normal",this.fontWeight=this.fontWeight||"normal",this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.darkMode?(this.rowOdd=this.rowOdd||P(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||P(this.mainBkg,10)):(this.rowOdd=this.rowOdd||R(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||R(this.mainBkg,5)),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||this.tertiaryColor,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||b(this.primaryColor,{h:30}),this.cScale4=this.cScale4||b(this.primaryColor,{h:60}),this.cScale5=this.cScale5||b(this.primaryColor,{h:90}),this.cScale6=this.cScale6||b(this.primaryColor,{h:120}),this.cScale7=this.cScale7||b(this.primaryColor,{h:150}),this.cScale8=this.cScale8||b(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||b(this.primaryColor,{h:270}),this.cScale10=this.cScale10||b(this.primaryColor,{h:300}),this.cScale11=this.cScale11||b(this.primaryColor,{h:330}),this.darkMode)for(let B=0;B<this.THEME_COLOR_LIMIT;B++)this["cScale"+B]=P(this["cScale"+B],75);else for(let B=0;B<this.THEME_COLOR_LIMIT;B++)this["cScale"+B]=P(this["cScale"+B],25);for(let B=0;B<this.THEME_COLOR_LIMIT;B++)this["cScaleInv"+B]=this["cScaleInv"+B]||L(this["cScale"+B]);for(let B=0;B<this.THEME_COLOR_LIMIT;B++)this.darkMode?this["cScalePeer"+B]=this["cScalePeer"+B]||R(this["cScale"+B],10):this["cScalePeer"+B]=this["cScalePeer"+B]||P(this["cScale"+B],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let B=0;B<this.THEME_COLOR_LIMIT;B++)this["cScaleLabel"+B]=this["cScaleLabel"+B]||this.scaleLabelColor;const t=this.darkMode?-4:-1;for(let B=0;B<5;B++)this["surface"+B]=this["surface"+B]||b(this.mainBkg,{h:180,s:-15,l:t*(5+B*3)}),this["surfacePeer"+B]=this["surfacePeer"+B]||b(this.mainBkg,{h:180,s:-15,l:t*(8+B*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||b(this.primaryColor,{h:64}),this.fillType3=this.fillType3||b(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||b(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||b(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||b(this.primaryColor,{h:128}),this.fillType7=this.fillType7||b(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||b(this.primaryColor,{l:-10}),this.pie5=this.pie5||b(this.secondaryColor,{l:-10}),this.pie6=this.pie6||b(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||b(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||b(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||b(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||b(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||b(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||b(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.venn1=this.venn1??b(this.primaryColor,{l:-30}),this.venn2=this.venn2??b(this.secondaryColor,{l:-30}),this.venn3=this.venn3??b(this.tertiaryColor,{l:-30}),this.venn4=this.venn4??b(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??b(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??b(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??b(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??b(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.radar={axisColor:((r=this.radar)==null?void 0:r.axisColor)||this.lineColor,axisStrokeWidth:((i=this.radar)==null?void 0:i.axisStrokeWidth)||2,axisLabelFontSize:((a=this.radar)==null?void 0:a.axisLabelFontSize)||12,curveOpacity:((s=this.radar)==null?void 0:s.curveOpacity)||.5,curveStrokeWidth:((o=this.radar)==null?void 0:o.curveStrokeWidth)||2,graticuleColor:((n=this.radar)==null?void 0:n.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:((l=this.radar)==null?void 0:l.graticuleStrokeWidth)||1,graticuleOpacity:((h=this.radar)==null?void 0:h.graticuleOpacity)||.3,legendBoxSize:((c=this.radar)==null?void 0:c.legendBoxSize)||12,legendFontSize:((u=this.radar)==null?void 0:u.legendFontSize)||12},this.archEdgeColor=this.archEdgeColor||"#777",this.archEdgeArrowColor=this.archEdgeArrowColor||"#777",this.archEdgeWidth=this.archEdgeWidth||"3",this.archGroupBorderColor=this.archGroupBorderColor||"#000",this.archGroupBorderWidth=this.archGroupBorderWidth||"2px",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Ee(this.quadrant1Fill)?R(this.quadrant1Fill):P(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:((f=this.xyChart)==null?void 0:f.backgroundColor)||this.background,titleColor:((d=this.xyChart)==null?void 0:d.titleColor)||this.primaryTextColor,dataLabelColor:((p=this.xyChart)==null?void 0:p.dataLabelColor)||this.primaryTextColor,xAxisTitleColor:((g=this.xyChart)==null?void 0:g.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((m=this.xyChart)==null?void 0:m.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((C=this.xyChart)==null?void 0:C.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((x=this.xyChart)==null?void 0:x.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((k=this.xyChart)==null?void 0:k.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((w=this.xyChart)==null?void 0:w.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((S=this.xyChart)==null?void 0:S.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((_=this.xyChart)==null?void 0:_.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((T=this.xyChart)==null?void 0:T.plotColorPalette)||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||b(this.primaryColor,{h:-30}),this.git4=this.git4||b(this.primaryColor,{h:-60}),this.git5=this.git5||b(this.primaryColor,{h:-90}),this.git6=this.git6||b(this.primaryColor,{h:60}),this.git7=this.git7||b(this.primaryColor,{h:120}),this.darkMode?(this.git0=R(this.git0,25),this.git1=R(this.git1,25),this.git2=R(this.git2,25),this.git3=R(this.git3,25),this.git4=R(this.git4,25),this.git5=R(this.git5,25),this.git6=R(this.git6,25),this.git7=R(this.git7,25)):(this.git0=P(this.git0,25),this.git1=P(this.git1,25),this.git2=P(this.git2,25),this.git3=P(this.git3,25),this.git4=P(this.git4,25),this.git5=P(this.git5,25),this.git6=P(this.git6,25),this.git7=P(this.git7,25)),this.gitInv0=this.gitInv0||L(this.git0),this.gitInv1=this.gitInv1||L(this.git1),this.gitInv2=this.gitInv2||L(this.git2),this.gitInv3=this.gitInv3||L(this.git3),this.gitInv4=this.gitInv4||L(this.git4),this.gitInv5=this.gitInv5||L(this.git5),this.gitInv6=this.gitInv6||L(this.git6),this.gitInv7=this.gitInv7||L(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Ue,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Ye,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},y(bi,"Theme"),bi),$x=y(e=>{const t=new Ex;return t.calculate(e),t},"getThemeVariables"),ki,Dx=(ki=class{constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=R(this.primaryColor,16),this.tertiaryColor=b(this.primaryColor,{h:-160}),this.primaryBorderColor=L(this.background),this.secondaryBorderColor=ht(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ht(this.tertiaryColor,this.darkMode),this.primaryTextColor=L(this.primaryColor),this.secondaryTextColor=L(this.secondaryColor),this.tertiaryTextColor=L(this.tertiaryColor),this.lineColor=L(this.background),this.textColor=L(this.background),this.mainBkg="#1f2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=R(L("#323D47"),10),this.lineColor="calculated",this.border1="#ccc",this.border2=yr(255,255,255,.25),this.arrowheadColor="calculated",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="#181818",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#F9FFFE",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="calculated",this.activationBkgColor="calculated",this.sequenceNumberColor="black",this.clusterBkg="#302F3D",this.sectionBkgColor=P("#EAE8D9",30),this.altSectionBkgColor="calculated",this.sectionBkgColor2="#EAE8D9",this.excludeBkgColor=P(this.sectionBkgColor,10),this.taskBorderColor=yr(255,255,255,70),this.taskBkgColor="calculated",this.taskTextColor="calculated",this.taskTextLightColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor=yr(255,255,255,50),this.activeTaskBkgColor="#81B1DB",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="grey",this.critBorderColor="#E83737",this.critBkgColor="#E83737",this.taskTextDarkColor="calculated",this.todayLineColor="#DB5757",this.vertLineColor="#00BFFF",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd=this.rowOdd||R(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||P(this.mainBkg,10),this.labelColor="calculated",this.errorBkgColor="#a44141",this.errorTextColor="#ddd",this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,1))",this.noteFontWeight=this.noteFontWeight||"normal",this.fontWeight=this.fontWeight||"normal"}updateColors(){var t,r,i,a,s,o,n,l,h,c,u,f,d,p,g,m,C,x,k,w,S,_;this.secondBkg=R(this.mainBkg,16),this.lineColor=this.mainContrastColor,this.arrowheadColor=this.mainContrastColor,this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.edgeLabelBackground=R(this.labelBackground,25),this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.actorTextColor=this.mainContrastColor,this.actorLineColor=this.actorBorder,this.signalColor=this.mainContrastColor,this.signalTextColor=this.mainContrastColor,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.mainContrastColor,this.loopTextColor=this.mainContrastColor,this.noteBorderColor=this.secondaryBorderColor,this.noteBkgColor=this.secondBkg,this.noteTextColor=this.secondaryTextColor,this.activationBorderColor=this.border1,this.activationBkgColor=this.secondBkg,this.altSectionBkgColor=this.background,this.taskBkgColor=R(this.mainBkg,23),this.taskTextColor=this.darkTextColor,this.taskTextLightColor=this.mainContrastColor,this.taskTextOutsideColor=this.taskTextLightColor,this.gridColor=this.mainContrastColor,this.doneTaskBkgColor=this.mainContrastColor,this.taskTextDarkColor=L(this.doneTaskBkgColor),this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#555",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#f4f4f4",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=b(this.primaryColor,{h:64}),this.fillType3=b(this.secondaryColor,{h:64}),this.fillType4=b(this.primaryColor,{h:-64}),this.fillType5=b(this.secondaryColor,{h:-64}),this.fillType6=b(this.primaryColor,{h:128}),this.fillType7=b(this.secondaryColor,{h:128}),this.cScale1=this.cScale1||"#0b0000",this.cScale2=this.cScale2||"#4d1037",this.cScale3=this.cScale3||"#3f5258",this.cScale4=this.cScale4||"#4f2f1b",this.cScale5=this.cScale5||"#6e0a0a",this.cScale6=this.cScale6||"#3b0048",this.cScale7=this.cScale7||"#995a01",this.cScale8=this.cScale8||"#154706",this.cScale9=this.cScale9||"#161722",this.cScale10=this.cScale10||"#00296f",this.cScale11=this.cScale11||"#01629c",this.cScale12=this.cScale12||"#010029",this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||b(this.primaryColor,{h:30}),this.cScale4=this.cScale4||b(this.primaryColor,{h:60}),this.cScale5=this.cScale5||b(this.primaryColor,{h:90}),this.cScale6=this.cScale6||b(this.primaryColor,{h:120}),this.cScale7=this.cScale7||b(this.primaryColor,{h:150}),this.cScale8=this.cScale8||b(this.primaryColor,{h:210}),this.cScale9=this.cScale9||b(this.primaryColor,{h:270}),this.cScale10=this.cScale10||b(this.primaryColor,{h:300}),this.cScale11=this.cScale11||b(this.primaryColor,{h:330});for(let T=0;T<this.THEME_COLOR_LIMIT;T++)this["cScaleInv"+T]=this["cScaleInv"+T]||L(this["cScale"+T]);for(let T=0;T<this.THEME_COLOR_LIMIT;T++)this["cScalePeer"+T]=this["cScalePeer"+T]||R(this["cScale"+T],10);for(let T=0;T<5;T++)this["surface"+T]=this["surface"+T]||b(this.mainBkg,{h:30,s:-30,l:-(-10+T*4)}),this["surfacePeer"+T]=this["surfacePeer"+T]||b(this.mainBkg,{h:30,s:-30,l:-(-7+T*4)});this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?"black":this.labelTextColor);for(let T=0;T<this.THEME_COLOR_LIMIT;T++)this["cScaleLabel"+T]=this["cScaleLabel"+T]||this.scaleLabelColor;for(let T=0;T<this.THEME_COLOR_LIMIT;T++)this["pie"+T]=this["cScale"+T];this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.mainContrastColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.mainContrastColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7";for(let T=0;T<8;T++)this["venn"+(T+1)]=this["venn"+(T+1)]??R(this["cScale"+T],30);this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Ee(this.quadrant1Fill)?R(this.quadrant1Fill):P(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:((t=this.xyChart)==null?void 0:t.backgroundColor)||this.background,titleColor:((r=this.xyChart)==null?void 0:r.titleColor)||this.primaryTextColor,dataLabelColor:((i=this.xyChart)==null?void 0:i.dataLabelColor)||this.primaryTextColor,xAxisTitleColor:((a=this.xyChart)==null?void 0:a.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((s=this.xyChart)==null?void 0:s.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((o=this.xyChart)==null?void 0:o.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((n=this.xyChart)==null?void 0:n.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((l=this.xyChart)==null?void 0:l.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((h=this.xyChart)==null?void 0:h.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((c=this.xyChart)==null?void 0:c.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((u=this.xyChart)==null?void 0:u.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((f=this.xyChart)==null?void 0:f.plotColorPalette)||"#3498db,#2ecc71,#e74c3c,#f1c40f,#bdc3c7,#ffffff,#34495e,#9b59b6,#1abc9c,#e67e22"},this.packet={startByteColor:this.primaryTextColor,endByteColor:this.primaryTextColor,labelColor:this.primaryTextColor,titleColor:this.primaryTextColor,blockStrokeColor:this.primaryTextColor,blockFillColor:this.background},this.radar={axisColor:((d=this.radar)==null?void 0:d.axisColor)||this.lineColor,axisStrokeWidth:((p=this.radar)==null?void 0:p.axisStrokeWidth)||2,axisLabelFontSize:((g=this.radar)==null?void 0:g.axisLabelFontSize)||12,curveOpacity:((m=this.radar)==null?void 0:m.curveOpacity)||.5,curveStrokeWidth:((C=this.radar)==null?void 0:C.curveStrokeWidth)||2,graticuleColor:((x=this.radar)==null?void 0:x.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:((k=this.radar)==null?void 0:k.graticuleStrokeWidth)||1,graticuleOpacity:((w=this.radar)==null?void 0:w.graticuleOpacity)||.3,legendBoxSize:((S=this.radar)==null?void 0:S.legendBoxSize)||12,legendFontSize:((_=this.radar)==null?void 0:_.legendFontSize)||12},this.classText=this.primaryTextColor,this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=R(this.secondaryColor,20),this.git1=R(this.pie2||this.secondaryColor,20),this.git2=R(this.pie3||this.tertiaryColor,20),this.git3=R(this.pie4||b(this.primaryColor,{h:-30}),20),this.git4=R(this.pie5||b(this.primaryColor,{h:-60}),20),this.git5=R(this.pie6||b(this.primaryColor,{h:-90}),10),this.git6=R(this.pie7||b(this.primaryColor,{h:60}),10),this.git7=R(this.pie8||b(this.primaryColor,{h:120}),20),this.gitInv0=this.gitInv0||L(this.git0),this.gitInv1=this.gitInv1||L(this.git1),this.gitInv2=this.gitInv2||L(this.git2),this.gitInv3=this.gitInv3||L(this.git3),this.gitInv4=this.gitInv4||L(this.git4),this.gitInv5=this.gitInv5||L(this.git5),this.gitInv6=this.gitInv6||L(this.git6),this.gitInv7=this.gitInv7||L(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||L(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||L(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||R(this.background,12),this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||R(this.background,2),this.nodeBorder=this.nodeBorder||"#999"}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},y(ki,"Theme"),ki),Ox=y(e=>{const t=new Dx;return t.calculate(e),t},"getThemeVariables"),Ti,Ix=(Ti=class{constructor(){this.background="#f4f4f4",this.primaryColor="#ECECFF",this.secondaryColor=b(this.primaryColor,{h:120}),this.secondaryColor="#ffffde",this.tertiaryColor=b(this.primaryColor,{h:-160}),this.primaryBorderColor=ht(this.primaryColor,this.darkMode),this.secondaryBorderColor=ht(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ht(this.tertiaryColor,this.darkMode),this.primaryTextColor=L(this.primaryColor),this.secondaryTextColor=L(this.secondaryColor),this.tertiaryTextColor=L(this.tertiaryColor),this.lineColor=L(this.background),this.textColor=L(this.background),this.background="white",this.mainBkg="#ECECFF",this.secondBkg="#ffffde",this.lineColor="#333333",this.border1="#9370DB",this.primaryBorderColor=ht(this.primaryColor,this.darkMode),this.border2="#aaaa33",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="rgba(232,232,232, 0.8)",this.textColor="#333",this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.clusterBkg="#FBFBFF",this.sectionBkgColor="calculated",this.altSectionBkgColor="calculated",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="calculated",this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor="calculated",this.taskTextOutsideColor=this.taskTextDarkColor,this.taskTextClickableColor="calculated",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBorderColor="calculated",this.critBkgColor="calculated",this.todayLineColor="calculated",this.vertLineColor="calculated",this.sectionBkgColor=yr(102,102,255,.49),this.altSectionBkgColor="white",this.sectionBkgColor2="#fff400",this.taskBorderColor="#534fbc",this.taskBkgColor="#8a90dd",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="#534fbc",this.activeTaskBkgColor="#bfc7ff",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.vertLineColor="navy",this.noteFontWeight=this.noteFontWeight||"normal",this.fontWeight=this.fontWeight||"normal",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd="calculated",this.rowEven="calculated",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.useGradient=!1,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow="drop-shadow(1px 2px 2px rgba(185, 185, 185, 1))",this.updateColors()}updateColors(){var t,r,i,a,s,o,n,l,h,c,u,f,d,p,g,m,C,x,k,w,S,_;this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||b(this.primaryColor,{h:30}),this.cScale4=this.cScale4||b(this.primaryColor,{h:60}),this.cScale5=this.cScale5||b(this.primaryColor,{h:90}),this.cScale6=this.cScale6||b(this.primaryColor,{h:120}),this.cScale7=this.cScale7||b(this.primaryColor,{h:150}),this.cScale8=this.cScale8||b(this.primaryColor,{h:210}),this.cScale9=this.cScale9||b(this.primaryColor,{h:270}),this.cScale10=this.cScale10||b(this.primaryColor,{h:300}),this.cScale11=this.cScale11||b(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||P(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||P(this.tertiaryColor,40);for(let T=0;T<this.THEME_COLOR_LIMIT;T++)this["cScale"+T]=P(this["cScale"+T],10),this["cScalePeer"+T]=this["cScalePeer"+T]||P(this["cScale"+T],25);for(let T=0;T<this.THEME_COLOR_LIMIT;T++)this["cScaleInv"+T]=this["cScaleInv"+T]||b(this["cScale"+T],{h:180});for(let T=0;T<5;T++)this["surface"+T]=this["surface"+T]||b(this.mainBkg,{h:30,l:-(5+T*5)}),this["surfacePeer"+T]=this["surfacePeer"+T]||b(this.mainBkg,{h:30,l:-(7+T*5)});if(this.scaleLabelColor=this.scaleLabelColor!=="calculated"&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor,this.labelTextColor!=="calculated"){this.cScaleLabel0=this.cScaleLabel0||L(this.labelTextColor),this.cScaleLabel3=this.cScaleLabel3||L(this.labelTextColor);for(let T=0;T<this.THEME_COLOR_LIMIT;T++)this["cScaleLabel"+T]=this["cScaleLabel"+T]||this.labelTextColor}this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.textColor,this.edgeLabelBackground=this.labelBackground,this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.signalColor=this.textColor,this.signalTextColor=this.textColor,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.rowOdd=this.rowOdd||R(this.primaryColor,75)||"#ffffff",this.rowEven=this.rowEven||R(this.primaryColor,1),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=b(this.primaryColor,{h:64}),this.fillType3=b(this.secondaryColor,{h:64}),this.fillType4=b(this.primaryColor,{h:-64}),this.fillType5=b(this.secondaryColor,{h:-64}),this.fillType6=b(this.primaryColor,{h:128}),this.fillType7=b(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||b(this.tertiaryColor,{l:-40}),this.pie4=this.pie4||b(this.primaryColor,{l:-10}),this.pie5=this.pie5||b(this.secondaryColor,{l:-30}),this.pie6=this.pie6||b(this.tertiaryColor,{l:-20}),this.pie7=this.pie7||b(this.primaryColor,{h:60,l:-20}),this.pie8=this.pie8||b(this.primaryColor,{h:-60,l:-40}),this.pie9=this.pie9||b(this.primaryColor,{h:120,l:-40}),this.pie10=this.pie10||b(this.primaryColor,{h:60,l:-40}),this.pie11=this.pie11||b(this.primaryColor,{h:-90,l:-40}),this.pie12=this.pie12||b(this.primaryColor,{h:120,l:-30}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.venn1=this.venn1??b(this.primaryColor,{l:-30}),this.venn2=this.venn2??b(this.secondaryColor,{l:-30}),this.venn3=this.venn3??b(this.tertiaryColor,{l:-40}),this.venn4=this.venn4??b(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??b(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??b(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??b(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??b(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Ee(this.quadrant1Fill)?R(this.quadrant1Fill):P(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.radar={axisColor:((t=this.radar)==null?void 0:t.axisColor)||this.lineColor,axisStrokeWidth:((r=this.radar)==null?void 0:r.axisStrokeWidth)||2,axisLabelFontSize:((i=this.radar)==null?void 0:i.axisLabelFontSize)||12,curveOpacity:((a=this.radar)==null?void 0:a.curveOpacity)||.5,curveStrokeWidth:((s=this.radar)==null?void 0:s.curveStrokeWidth)||2,graticuleColor:((o=this.radar)==null?void 0:o.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:((n=this.radar)==null?void 0:n.graticuleStrokeWidth)||1,graticuleOpacity:((l=this.radar)==null?void 0:l.graticuleOpacity)||.3,legendBoxSize:((h=this.radar)==null?void 0:h.legendBoxSize)||12,legendFontSize:((c=this.radar)==null?void 0:c.legendFontSize)||12},this.xyChart={backgroundColor:((u=this.xyChart)==null?void 0:u.backgroundColor)||this.background,titleColor:((f=this.xyChart)==null?void 0:f.titleColor)||this.primaryTextColor,dataLabelColor:((d=this.xyChart)==null?void 0:d.dataLabelColor)||this.primaryTextColor,xAxisTitleColor:((p=this.xyChart)==null?void 0:p.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((g=this.xyChart)==null?void 0:g.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((m=this.xyChart)==null?void 0:m.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((C=this.xyChart)==null?void 0:C.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((x=this.xyChart)==null?void 0:x.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((k=this.xyChart)==null?void 0:k.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((w=this.xyChart)==null?void 0:w.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((S=this.xyChart)==null?void 0:S.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((_=this.xyChart)==null?void 0:_.plotColorPalette)||"#ECECFF,#8493A6,#FFC3A0,#DCDDE1,#B8E994,#D1A36F,#C3CDE6,#FFB6C1,#496078,#F8F3E3"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.labelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||b(this.primaryColor,{h:-30}),this.git4=this.git4||b(this.primaryColor,{h:-60}),this.git5=this.git5||b(this.primaryColor,{h:-90}),this.git6=this.git6||b(this.primaryColor,{h:60}),this.git7=this.git7||b(this.primaryColor,{h:120}),this.darkMode?(this.git0=R(this.git0,25),this.git1=R(this.git1,25),this.git2=R(this.git2,25),this.git3=R(this.git3,25),this.git4=R(this.git4,25),this.git5=R(this.git5,25),this.git6=R(this.git6,25),this.git7=R(this.git7,25)):(this.git0=P(this.git0,25),this.git1=P(this.git1,25),this.git2=P(this.git2,25),this.git3=P(this.git3,25),this.git4=P(this.git4,25),this.git5=P(this.git5,25),this.git6=P(this.git6,25),this.git7=P(this.git7,25)),this.gitInv0=this.gitInv0||P(L(this.git0),25),this.gitInv1=this.gitInv1||L(this.git1),this.gitInv2=this.gitInv2||L(this.git2),this.gitInv3=this.gitInv3||L(this.git3),this.gitInv4=this.gitInv4||L(this.git4),this.gitInv5=this.gitInv5||L(this.git5),this.gitInv6=this.gitInv6||L(this.git6),this.gitInv7=this.gitInv7||L(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||L(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||L(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Ue,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Ye}calculate(t){if(Object.keys(this).forEach(i=>{this[i]==="calculated"&&(this[i]=void 0)}),typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},y(Ti,"Theme"),Ti),Px=y(e=>{const t=new Ix;return t.calculate(e),t},"getThemeVariables"),wi,Rx=(wi=class{constructor(){this.background="#f4f4f4",this.primaryColor="#cde498",this.secondaryColor="#cdffb2",this.background="white",this.mainBkg="#cde498",this.secondBkg="#cdffb2",this.lineColor="green",this.border1="#13540c",this.border2="#6eaa49",this.arrowheadColor="green",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.tertiaryColor=R("#cde498",10),this.primaryBorderColor=ht(this.primaryColor,this.darkMode),this.secondaryBorderColor=ht(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ht(this.tertiaryColor,this.darkMode),this.primaryTextColor=L(this.primaryColor),this.secondaryTextColor=L(this.secondaryColor),this.tertiaryTextColor=L(this.primaryColor),this.lineColor=L(this.background),this.textColor=L(this.background),this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#333",this.edgeLabelBackground="#e8e8e8",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="#333",this.signalTextColor="#333",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="#326932",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="#6eaa49",this.altSectionBkgColor="white",this.sectionBkgColor2="#6eaa49",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="#487e3a",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.vertLineColor="#00BFFF",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.noteFontWeight="normal",this.fontWeight="normal",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,0.5))"}updateColors(){var t,r,i,a,s,o,n,l,h,c,u,f,d,p,g,m,C,x,k,w,S,_;this.actorBorder=P(this.mainBkg,20),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||b(this.primaryColor,{h:30}),this.cScale4=this.cScale4||b(this.primaryColor,{h:60}),this.cScale5=this.cScale5||b(this.primaryColor,{h:90}),this.cScale6=this.cScale6||b(this.primaryColor,{h:120}),this.cScale7=this.cScale7||b(this.primaryColor,{h:150}),this.cScale8=this.cScale8||b(this.primaryColor,{h:210}),this.cScale9=this.cScale9||b(this.primaryColor,{h:270}),this.cScale10=this.cScale10||b(this.primaryColor,{h:300}),this.cScale11=this.cScale11||b(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||P(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||P(this.tertiaryColor,40);for(let T=0;T<this.THEME_COLOR_LIMIT;T++)this["cScale"+T]=P(this["cScale"+T],10),this["cScalePeer"+T]=this["cScalePeer"+T]||P(this["cScale"+T],25);for(let T=0;T<this.THEME_COLOR_LIMIT;T++)this["cScaleInv"+T]=this["cScaleInv"+T]||b(this["cScale"+T],{h:180});this.scaleLabelColor=this.scaleLabelColor!=="calculated"&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor;for(let T=0;T<this.THEME_COLOR_LIMIT;T++)this["cScaleLabel"+T]=this["cScaleLabel"+T]||this.scaleLabelColor;for(let T=0;T<5;T++)this["surface"+T]=this["surface"+T]||b(this.mainBkg,{h:30,s:-30,l:-(5+T*5)}),this["surfacePeer"+T]=this["surfacePeer"+T]||b(this.mainBkg,{h:30,s:-30,l:-(8+T*5)});this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.taskBorderColor=this.border1,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.rowOdd=this.rowOdd||R(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||R(this.mainBkg,20),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=b(this.primaryColor,{h:64}),this.fillType3=b(this.secondaryColor,{h:64}),this.fillType4=b(this.primaryColor,{h:-64}),this.fillType5=b(this.secondaryColor,{h:-64}),this.fillType6=b(this.primaryColor,{h:128}),this.fillType7=b(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||b(this.primaryColor,{l:-30}),this.pie5=this.pie5||b(this.secondaryColor,{l:-30}),this.pie6=this.pie6||b(this.tertiaryColor,{h:40,l:-40}),this.pie7=this.pie7||b(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||b(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||b(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||b(this.primaryColor,{h:60,l:-50}),this.pie11=this.pie11||b(this.primaryColor,{h:-60,l:-50}),this.pie12=this.pie12||b(this.primaryColor,{h:120,l:-50}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.venn1=this.venn1??b(this.primaryColor,{l:-30}),this.venn2=this.venn2??b(this.secondaryColor,{l:-30}),this.venn3=this.venn3??b(this.tertiaryColor,{l:-30}),this.venn4=this.venn4??b(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??b(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??b(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??b(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??b(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Ee(this.quadrant1Fill)?R(this.quadrant1Fill):P(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.packet={startByteColor:this.primaryTextColor,endByteColor:this.primaryTextColor,labelColor:this.primaryTextColor,titleColor:this.primaryTextColor,blockStrokeColor:this.primaryTextColor,blockFillColor:this.mainBkg},this.radar={axisColor:((t=this.radar)==null?void 0:t.axisColor)||this.lineColor,axisStrokeWidth:((r=this.radar)==null?void 0:r.axisStrokeWidth)||2,axisLabelFontSize:((i=this.radar)==null?void 0:i.axisLabelFontSize)||12,curveOpacity:((a=this.radar)==null?void 0:a.curveOpacity)||.5,curveStrokeWidth:((s=this.radar)==null?void 0:s.curveStrokeWidth)||2,graticuleColor:((o=this.radar)==null?void 0:o.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:((n=this.radar)==null?void 0:n.graticuleStrokeWidth)||1,graticuleOpacity:((l=this.radar)==null?void 0:l.graticuleOpacity)||.3,legendBoxSize:((h=this.radar)==null?void 0:h.legendBoxSize)||12,legendFontSize:((c=this.radar)==null?void 0:c.legendFontSize)||12},this.xyChart={backgroundColor:((u=this.xyChart)==null?void 0:u.backgroundColor)||this.background,titleColor:((f=this.xyChart)==null?void 0:f.titleColor)||this.primaryTextColor,dataLabelColor:((d=this.xyChart)==null?void 0:d.dataLabelColor)||this.primaryTextColor,xAxisTitleColor:((p=this.xyChart)==null?void 0:p.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((g=this.xyChart)==null?void 0:g.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((m=this.xyChart)==null?void 0:m.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((C=this.xyChart)==null?void 0:C.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((x=this.xyChart)==null?void 0:x.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((k=this.xyChart)==null?void 0:k.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((w=this.xyChart)==null?void 0:w.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((S=this.xyChart)==null?void 0:S.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((_=this.xyChart)==null?void 0:_.plotColorPalette)||"#CDE498,#FF6B6B,#A0D2DB,#D7BDE2,#F0F0F0,#FFC3A0,#7FD8BE,#FF9A8B,#FAF3E0,#FFF176"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||b(this.primaryColor,{h:-30}),this.git4=this.git4||b(this.primaryColor,{h:-60}),this.git5=this.git5||b(this.primaryColor,{h:-90}),this.git6=this.git6||b(this.primaryColor,{h:60}),this.git7=this.git7||b(this.primaryColor,{h:120}),this.darkMode?(this.git0=R(this.git0,25),this.git1=R(this.git1,25),this.git2=R(this.git2,25),this.git3=R(this.git3,25),this.git4=R(this.git4,25),this.git5=R(this.git5,25),this.git6=R(this.git6,25),this.git7=R(this.git7,25)):(this.git0=P(this.git0,25),this.git1=P(this.git1,25),this.git2=P(this.git2,25),this.git3=P(this.git3,25),this.git4=P(this.git4,25),this.git5=P(this.git5,25),this.git6=P(this.git6,25),this.git7=P(this.git7,25)),this.gitInv0=this.gitInv0||L(this.git0),this.gitInv1=this.gitInv1||L(this.git1),this.gitInv2=this.gitInv2||L(this.git2),this.gitInv3=this.gitInv3||L(this.git3),this.gitInv4=this.gitInv4||L(this.git4),this.gitInv5=this.gitInv5||L(this.git5),this.gitInv6=this.gitInv6||L(this.git6),this.gitInv7=this.gitInv7||L(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||L(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||L(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Ue,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Ye}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},y(wi,"Theme"),wi),Nx=y(e=>{const t=new Rx;return t.calculate(e),t},"getThemeVariables"),_i,qx=(_i=class{constructor(){this.primaryColor="#eee",this.contrast="#707070",this.secondaryColor=R(this.contrast,55),this.background="#ffffff",this.tertiaryColor=b(this.primaryColor,{h:-160}),this.primaryBorderColor=ht(this.primaryColor,this.darkMode),this.secondaryBorderColor=ht(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ht(this.tertiaryColor,this.darkMode),this.primaryTextColor=L(this.primaryColor),this.secondaryTextColor=L(this.secondaryColor),this.tertiaryTextColor=L(this.tertiaryColor),this.lineColor=L(this.background),this.textColor=L(this.background),this.mainBkg="#eee",this.secondBkg="calculated",this.lineColor="#666",this.border1="#999",this.border2="calculated",this.note="#ffa",this.text="#333",this.critical="#d42",this.done="#bbb",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="white",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor=this.actorBorder,this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="calculated",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="white",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBkgColor="calculated",this.critBorderColor="calculated",this.todayLineColor="calculated",this.vertLineColor="calculated",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.noteFontWeight="normal",this.fontWeight="normal",this.rowOdd=this.rowOdd||R(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||"#f4f4f4",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,1))"}updateColors(){var t,r,i,a,s,o,n,l,h,c,u,f,d,p,g,m,C,x,k,w,S,_;this.secondBkg=R(this.contrast,55),this.border2=this.contrast,this.actorBorder=R(this.border1,23),this.actorBkg=this.mainBkg,this.actorTextColor=this.text,this.actorLineColor=this.actorBorder,this.signalColor=this.text,this.signalTextColor=this.text,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.text,this.loopTextColor=this.text,this.noteBorderColor="#999",this.noteBkgColor="#666",this.noteTextColor="#fff",this.cScale0=this.cScale0||"#555",this.cScale1=this.cScale1||"#F4F4F4",this.cScale2=this.cScale2||"#555",this.cScale3=this.cScale3||"#BBB",this.cScale4=this.cScale4||"#777",this.cScale5=this.cScale5||"#999",this.cScale6=this.cScale6||"#DDD",this.cScale7=this.cScale7||"#FFF",this.cScale8=this.cScale8||"#DDD",this.cScale9=this.cScale9||"#BBB",this.cScale10=this.cScale10||"#999",this.cScale11=this.cScale11||"#777";for(let T=0;T<this.THEME_COLOR_LIMIT;T++)this["cScaleInv"+T]=this["cScaleInv"+T]||L(this["cScale"+T]);for(let T=0;T<this.THEME_COLOR_LIMIT;T++)this.darkMode?this["cScalePeer"+T]=this["cScalePeer"+T]||R(this["cScale"+T],10):this["cScalePeer"+T]=this["cScalePeer"+T]||P(this["cScale"+T],10);this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?"black":this.labelTextColor),this.cScaleLabel0=this.cScaleLabel0||this.cScale1,this.cScaleLabel2=this.cScaleLabel2||this.cScale1;for(let T=0;T<this.THEME_COLOR_LIMIT;T++)this["cScaleLabel"+T]=this["cScaleLabel"+T]||this.scaleLabelColor;for(let T=0;T<5;T++)this["surface"+T]=this["surface"+T]||b(this.mainBkg,{l:-(5+T*5)}),this["surfacePeer"+T]=this["surfacePeer"+T]||b(this.mainBkg,{l:-(8+T*5)});this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.text,this.sectionBkgColor=R(this.contrast,30),this.sectionBkgColor2=R(this.contrast,30),this.taskBorderColor=P(this.contrast,10),this.taskBkgColor=this.contrast,this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor=this.text,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.gridColor=R(this.border1,30),this.doneTaskBkgColor=this.done,this.doneTaskBorderColor=this.lineColor,this.critBkgColor=this.critical,this.critBorderColor=P(this.critBkgColor,10),this.todayLineColor=this.critBkgColor,this.vertLineColor=this.critBkgColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||"#000",this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f4f4f4",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.stateBorder=this.stateBorder||"#000",this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#222",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=b(this.primaryColor,{h:64}),this.fillType3=b(this.secondaryColor,{h:64}),this.fillType4=b(this.primaryColor,{h:-64}),this.fillType5=b(this.secondaryColor,{h:-64}),this.fillType6=b(this.primaryColor,{h:128}),this.fillType7=b(this.secondaryColor,{h:128});for(let T=0;T<this.THEME_COLOR_LIMIT;T++)this["pie"+T]=this["cScale"+T];this.pie12=this.pie0,this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7";for(let T=0;T<8;T++)this["venn"+(T+1)]=this["venn"+(T+1)]??this["cScale"+T];this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Ee(this.quadrant1Fill)?R(this.quadrant1Fill):P(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:((t=this.xyChart)==null?void 0:t.backgroundColor)||this.background,titleColor:((r=this.xyChart)==null?void 0:r.titleColor)||this.primaryTextColor,dataLabelColor:((i=this.xyChart)==null?void 0:i.dataLabelColor)||this.primaryTextColor,xAxisTitleColor:((a=this.xyChart)==null?void 0:a.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((s=this.xyChart)==null?void 0:s.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((o=this.xyChart)==null?void 0:o.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((n=this.xyChart)==null?void 0:n.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((l=this.xyChart)==null?void 0:l.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((h=this.xyChart)==null?void 0:h.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((c=this.xyChart)==null?void 0:c.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((u=this.xyChart)==null?void 0:u.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((f=this.xyChart)==null?void 0:f.plotColorPalette)||"#EEE,#6BB8E4,#8ACB88,#C7ACD6,#E8DCC2,#FFB2A8,#FFF380,#7E8D91,#FFD8B1,#FAF3E0"},this.radar={axisColor:((d=this.radar)==null?void 0:d.axisColor)||this.lineColor,axisStrokeWidth:((p=this.radar)==null?void 0:p.axisStrokeWidth)||2,axisLabelFontSize:((g=this.radar)==null?void 0:g.axisLabelFontSize)||12,curveOpacity:((m=this.radar)==null?void 0:m.curveOpacity)||.5,curveStrokeWidth:((C=this.radar)==null?void 0:C.curveStrokeWidth)||2,graticuleColor:((x=this.radar)==null?void 0:x.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:((k=this.radar)==null?void 0:k.graticuleStrokeWidth)||1,graticuleOpacity:((w=this.radar)==null?void 0:w.graticuleOpacity)||.3,legendBoxSize:((S=this.radar)==null?void 0:S.legendBoxSize)||12,legendFontSize:((_=this.radar)==null?void 0:_.legendFontSize)||12},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=P(this.pie1,25)||this.primaryColor,this.git1=this.pie2||this.secondaryColor,this.git2=this.pie3||this.tertiaryColor,this.git3=this.pie4||b(this.primaryColor,{h:-30}),this.git4=this.pie5||b(this.primaryColor,{h:-60}),this.git5=this.pie6||b(this.primaryColor,{h:-90}),this.git6=this.pie7||b(this.primaryColor,{h:60}),this.git7=this.pie8||b(this.primaryColor,{h:120}),this.gitInv0=this.gitInv0||L(this.git0),this.gitInv1=this.gitInv1||L(this.git1),this.gitInv2=this.gitInv2||L(this.git2),this.gitInv3=this.gitInv3||L(this.git3),this.gitInv4=this.gitInv4||L(this.git4),this.gitInv5=this.gitInv5||L(this.git5),this.gitInv6=this.gitInv6||L(this.git6),this.gitInv7=this.gitInv7||L(this.git7),this.branchLabelColor=this.branchLabelColor||this.labelTextColor,this.gitBranchLabel0=this.branchLabelColor,this.gitBranchLabel1="white",this.gitBranchLabel2=this.branchLabelColor,this.gitBranchLabel3="white",this.gitBranchLabel4=this.branchLabelColor,this.gitBranchLabel5=this.branchLabelColor,this.gitBranchLabel6=this.branchLabelColor,this.gitBranchLabel7=this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Ue,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Ye}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},y(_i,"Theme"),_i),zx=y(e=>{const t=new qx;return t.calculate(e),t},"getThemeVariables"),Si,Wx=(Si=class{constructor(){this.background="#ffffff",this.primaryColor="#cccccc",this.mainBkg="#ffffff",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.radius=3,this.strokeWidth=2,this.primaryBorderColor=ht(this.primaryColor,this.darkMode),this.fontFamily="arial, sans-serif",this.fontSize="14px",this.nodeBorder="#000000",this.stateBorder="#000000",this.useGradient=!0,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="drop-shadow( 0px 1px 2px rgba(0, 0, 0, 0.25));",this.tertiaryColor="#ffffff",this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.noteFontWeight="normal",this.fontWeight="normal"}updateColors(){var s,o,n,l,h,c,u,f,d,p,g;this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||b(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||b(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ht(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ht(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ht(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ht(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||L(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||L(this.tertiaryColor),this.lineColor=this.lineColor||L(this.background),this.arrowheadColor=this.arrowheadColor||L(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||P(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||L(this.lineColor);const t="#ECECFE",r="#E9E9F1",i=b(t,{h:180,l:5});if(this.sectionBkgColor=this.sectionBkgColor||i,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||r,this.sectionBkgColor2=this.sectionBkgColor2||t,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||t,this.activeTaskBorderColor=this.activeTaskBorderColor||t,this.activeTaskBkgColor=this.activeTaskBkgColor||R(t,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||t,this.cScale1=this.cScale1||r,this.cScale2=this.cScale2||i,this.cScale3=this.cScale3||b(t,{h:30}),this.cScale4=this.cScale4||b(t,{h:60}),this.cScale5=this.cScale5||b(t,{h:90}),this.cScale6=this.cScale6||b(t,{h:120}),this.cScale7=this.cScale7||b(t,{h:150}),this.cScale8=this.cScale8||b(t,{h:210,l:150}),this.cScale9=this.cScale9||b(t,{h:270}),this.cScale10=this.cScale10||b(t,{h:300}),this.cScale11=this.cScale11||b(t,{h:330}),this.darkMode)for(let m=0;m<this.THEME_COLOR_LIMIT;m++)this["cScale"+m]=P(this["cScale"+m],75);else for(let m=0;m<this.THEME_COLOR_LIMIT;m++)this["cScale"+m]=P(this["cScale"+m],25);for(let m=0;m<this.THEME_COLOR_LIMIT;m++)this["cScaleInv"+m]=this["cScaleInv"+m]||L(this["cScale"+m]);for(let m=0;m<this.THEME_COLOR_LIMIT;m++)this.darkMode?this["cScalePeer"+m]=this["cScalePeer"+m]||R(this["cScale"+m],10):this["cScalePeer"+m]=this["cScalePeer"+m]||P(this["cScale"+m],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let m=0;m<this.THEME_COLOR_LIMIT;m++)this["cScaleLabel"+m]=this["cScaleLabel"+m]||this.scaleLabelColor;const a=this.darkMode?-4:-1;for(let m=0;m<5;m++)this["surface"+m]=this["surface"+m]||b(this.mainBkg,{h:180,s:-15,l:a*(5+m*3)}),this["surfacePeer"+m]=this["surfacePeer"+m]||b(this.mainBkg,{h:180,s:-15,l:a*(8+m*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||t,this.fillType1=this.fillType1||r,this.fillType2=this.fillType2||b(t,{h:64}),this.fillType3=this.fillType3||b(r,{h:64}),this.fillType4=this.fillType4||b(t,{h:-64}),this.fillType5=this.fillType5||b(r,{h:-64}),this.fillType6=this.fillType6||b(t,{h:128}),this.fillType7=this.fillType7||b(r,{h:128}),this.pie1=this.pie1||t,this.pie2=this.pie2||r,this.pie3=this.pie3||i,this.pie4=this.pie4||b(t,{l:-10}),this.pie5=this.pie5||b(r,{l:-10}),this.pie6=this.pie6||b(i,{l:-10}),this.pie7=this.pie7||b(t,{h:60,l:-10}),this.pie8=this.pie8||b(t,{h:-60,l:-10}),this.pie9=this.pie9||b(t,{h:120,l:0}),this.pie10=this.pie10||b(t,{h:60,l:-20}),this.pie11=this.pie11||b(t,{h:-60,l:-20}),this.pie12=this.pie12||b(t,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||t,this.quadrant2Fill=this.quadrant2Fill||b(t,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(t,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(t,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Ee(this.quadrant1Fill)?R(this.quadrant1Fill):P(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:((s=this.xyChart)==null?void 0:s.backgroundColor)||this.background,titleColor:((o=this.xyChart)==null?void 0:o.titleColor)||this.primaryTextColor,xAxisTitleColor:((n=this.xyChart)==null?void 0:n.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((l=this.xyChart)==null?void 0:l.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((h=this.xyChart)==null?void 0:h.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((c=this.xyChart)==null?void 0:c.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((u=this.xyChart)==null?void 0:u.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((f=this.xyChart)==null?void 0:f.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((d=this.xyChart)==null?void 0:d.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((p=this.xyChart)==null?void 0:p.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((g=this.xyChart)==null?void 0:g.plotColorPalette)||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||t,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||t,this.git1=this.git1||r,this.git2=this.git2||i,this.git3=this.git3||b(t,{h:-30}),this.git4=this.git4||b(t,{h:-60}),this.git5=this.git5||b(t,{h:-90}),this.git6=this.git6||b(t,{h:60}),this.git7=this.git7||b(t,{h:120}),this.darkMode?(this.git0=R(this.git0,25),this.git1=R(this.git1,25),this.git2=R(this.git2,25),this.git3=R(this.git3,25),this.git4=R(this.git4,25),this.git5=R(this.git5,25),this.git6=R(this.git6,25),this.git7=R(this.git7,25)):(this.git0=P(this.git0,25),this.git1=P(this.git1,25),this.git2=P(this.git2,25),this.git3=P(this.git3,25),this.git4=P(this.git4,25),this.git5=P(this.git5,25),this.git6=P(this.git6,25),this.git7=P(this.git7,25)),this.gitInv0=this.gitInv0||L(this.git0),this.gitInv1=this.gitInv1||L(this.git1),this.gitInv2=this.gitInv2||L(this.git2),this.gitInv3=this.gitInv3||L(this.git3),this.gitInv4=this.gitInv4||L(this.git4),this.gitInv5=this.gitInv5||L(this.git5),this.gitInv6=this.gitInv6||L(this.git6),this.gitInv7=this.gitInv7||L(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Ue,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Ye}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},y(Si,"Theme"),Si),Hx=y(e=>{const t=new Wx;return t.calculate(e),t},"getThemeVariables"),vi,Ux=(vi=class{constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=R(this.primaryColor,16),this.tertiaryColor=b(this.primaryColor,{h:-160}),this.primaryBorderColor=L(this.background),this.secondaryBorderColor=ht(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ht(this.tertiaryColor,this.darkMode),this.primaryTextColor=L(this.primaryColor),this.secondaryTextColor=L(this.secondaryColor),this.tertiaryTextColor=L(this.tertiaryColor),this.mainBkg="#2a2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=R(L("#323D47"),10),this.border1="#ccc",this.border2=yr(255,255,255,.25),this.arrowheadColor=L(this.background),this.fontFamily="arial, sans-serif",this.fontSize="14px",this.labelBackground="#181818",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.radius=3,this.strokeWidth=1,this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.fontFamily="arial, sans-serif",this.fontSize="14px",this.useGradient=!0,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,0.2))",this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.noteFontWeight="normal",this.fontWeight="normal"}updateColors(){var r,i,a,s,o,n,l,h,c,u,f;if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||b(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||b(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ht(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ht(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ht(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ht(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||L(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||L(this.tertiaryColor),this.lineColor=this.lineColor||L(this.background),this.arrowheadColor=this.arrowheadColor||L(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||P(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||L(this.lineColor),this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||R(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||b(this.primaryColor,{h:30}),this.cScale4=this.cScale4||b(this.primaryColor,{h:60}),this.cScale5=this.cScale5||b(this.primaryColor,{h:90}),this.cScale6=this.cScale6||b(this.primaryColor,{h:120}),this.cScale7=this.cScale7||b(this.primaryColor,{h:150}),this.cScale8=this.cScale8||b(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||b(this.primaryColor,{h:270}),this.cScale10=this.cScale10||b(this.primaryColor,{h:300}),this.cScale11=this.cScale11||b(this.primaryColor,{h:330}),this.darkMode)for(let d=0;d<this.THEME_COLOR_LIMIT;d++)this["cScale"+d]=P(this["cScale"+d],75);else for(let d=0;d<this.THEME_COLOR_LIMIT;d++)this["cScale"+d]=P(this["cScale"+d],25);for(let d=0;d<this.THEME_COLOR_LIMIT;d++)this["cScaleInv"+d]=this["cScaleInv"+d]||L(this["cScale"+d]);for(let d=0;d<this.THEME_COLOR_LIMIT;d++)this.darkMode?this["cScalePeer"+d]=this["cScalePeer"+d]||R(this["cScale"+d],10):this["cScalePeer"+d]=this["cScalePeer"+d]||P(this["cScale"+d],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let d=0;d<this.THEME_COLOR_LIMIT;d++)this["cScaleLabel"+d]=this["cScaleLabel"+d]||this.scaleLabelColor;const t=this.darkMode?-4:-1;for(let d=0;d<5;d++)this["surface"+d]=this["surface"+d]||b(this.mainBkg,{h:180,s:-15,l:t*(5+d*3)}),this["surfacePeer"+d]=this["surfacePeer"+d]||b(this.mainBkg,{h:180,s:-15,l:t*(8+d*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||b(this.primaryColor,{h:64}),this.fillType3=this.fillType3||b(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||b(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||b(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||b(this.primaryColor,{h:128}),this.fillType7=this.fillType7||b(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||b(this.primaryColor,{l:-10}),this.pie5=this.pie5||b(this.secondaryColor,{l:-10}),this.pie6=this.pie6||b(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||b(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||b(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||b(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||b(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||b(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||b(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Ee(this.quadrant1Fill)?R(this.quadrant1Fill):P(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:((r=this.xyChart)==null?void 0:r.backgroundColor)||this.background,titleColor:((i=this.xyChart)==null?void 0:i.titleColor)||this.primaryTextColor,xAxisTitleColor:((a=this.xyChart)==null?void 0:a.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((s=this.xyChart)==null?void 0:s.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((o=this.xyChart)==null?void 0:o.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((n=this.xyChart)==null?void 0:n.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((l=this.xyChart)==null?void 0:l.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((h=this.xyChart)==null?void 0:h.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((c=this.xyChart)==null?void 0:c.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((u=this.xyChart)==null?void 0:u.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((f=this.xyChart)==null?void 0:f.plotColorPalette)||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||"#0b0000",this.git1=this.git1||"#4d1037",this.git2=this.git2||"#3f5258",this.git3=this.git3||"#4f2f1b",this.git4=this.git4||"#6e0a0a",this.git5=this.git5||"#3b0048",this.git6=this.git6||"#995a01",this.git7=this.git7||"#154706",this.gitDarkMode=!0,this.gitDarkMode?(this.git0=R(this.git0,25),this.git1=R(this.git1,25),this.git2=R(this.git2,25),this.git3=R(this.git3,25),this.git4=R(this.git4,25),this.git5=R(this.git5,25),this.git6=R(this.git6,25),this.git7=R(this.git7,25)):(this.git0=P(this.git0,25),this.git1=P(this.git1,25),this.git2=P(this.git2,25),this.git3=P(this.git3,25),this.git4=P(this.git4,25),this.git5=P(this.git5,25),this.git6=P(this.git6,25),this.git7=P(this.git7,25)),this.gitInv0=this.gitInv0||L(this.git0),this.gitInv1=this.gitInv1||L(this.git1),this.gitInv2=this.gitInv2||L(this.git2),this.gitInv3=this.gitInv3||L(this.git3),this.gitInv4=this.gitInv4||L(this.git4),this.gitInv5=this.gitInv5||L(this.git5),this.gitInv6=this.gitInv6||L(this.git6),this.gitInv7=this.gitInv7||L(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Ue,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Ye}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},y(vi,"Theme"),vi),Yx=y(e=>{const t=new Ux;return t.calculate(e),t},"getThemeVariables"),Bi,jx=(Bi=class{constructor(){this.background="#ffffff",this.primaryColor="#cccccc",this.mainBkg="#ffffff",this.noteBkgColor="#fff5ad",this.noteTextColor="#28253D",this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.primaryBorderColor=ht("#28253D",this.darkMode),this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.nodeBorder="#28253D",this.stateBorder="#28253D",this.useGradient=!1,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="url(#drop-shadow)",this.nodeShadow=!0,this.tertiaryColor="#ffffff",this.clusterBkg="#F9F9FB",this.clusterBorder="#BDBCCC",this.noteBorderColor="#FACC15",this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.actorBorder="#28253D",this.filterColor="#000000"}updateColors(){var s,o,n,l,h,c,u,f,d,p,g;this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#28253D"),this.secondaryColor=this.secondaryColor||b(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||b(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ht(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ht(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ht(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ht(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#FEF9C3",this.noteTextColor=this.noteTextColor||"#28253D",this.secondaryTextColor=this.secondaryTextColor||L(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||L(this.tertiaryColor),this.lineColor=this.lineColor||L(this.background),this.arrowheadColor=this.arrowheadColor||L(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.noteFontWeight=600,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||P(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||L(this.lineColor);const t="#ECECFE",r="#E9E9F1",i=b(t,{h:180,l:5});this.sectionBkgColor=this.sectionBkgColor||i,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||r,this.sectionBkgColor2=this.sectionBkgColor2||t,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||t,this.activeTaskBorderColor=this.activeTaskBorderColor||t,this.activeTaskBkgColor=this.activeTaskBkgColor||R(t,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.compositeTitleBackground="#F9F9FB",this.altBackground="#F9F9FB",this.stateEdgeLabelBackground="#FFFFFF",this.fontWeight=600,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor;for(let m=0;m<this.THEME_COLOR_LIMIT;m++)this["cScale"+m]=this.mainBkg;if(this.darkMode)for(let m=0;m<this.THEME_COLOR_LIMIT;m++)this["cScale"+m]=P(this["cScale"+m],75);else for(let m=0;m<this.THEME_COLOR_LIMIT;m++)this["cScale"+m]=P(this["cScale"+m],25);for(let m=0;m<this.THEME_COLOR_LIMIT;m++)this["cScaleInv"+m]=this["cScaleInv"+m]||L(this["cScale"+m]);for(let m=0;m<this.THEME_COLOR_LIMIT;m++)this.darkMode?this["cScalePeer"+m]=this["cScalePeer"+m]||R(this["cScale"+m],10):this["cScalePeer"+m]=this["cScalePeer"+m]||P(this["cScale"+m],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let m=0;m<this.THEME_COLOR_LIMIT;m++)this["cScaleLabel"+m]=this["cScaleLabel"+m]||this.scaleLabelColor;const a=this.darkMode?-4:-1;for(let m=0;m<5;m++)this["surface"+m]=this["surface"+m]||b(this.mainBkg,{h:180,s:-15,l:a*(5+m*3)}),this["surfacePeer"+m]=this["surfacePeer"+m]||b(this.mainBkg,{h:180,s:-15,l:a*(8+m*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||t,this.fillType1=this.fillType1||r,this.fillType2=this.fillType2||b(t,{h:64}),this.fillType3=this.fillType3||b(r,{h:64}),this.fillType4=this.fillType4||b(t,{h:-64}),this.fillType5=this.fillType5||b(r,{h:-64}),this.fillType6=this.fillType6||b(t,{h:128}),this.fillType7=this.fillType7||b(r,{h:128}),this.pie1=this.pie1||t,this.pie2=this.pie2||r,this.pie3=this.pie3||i,this.pie4=this.pie4||b(t,{l:-10}),this.pie5=this.pie5||b(r,{l:-10}),this.pie6=this.pie6||b(i,{l:-10}),this.pie7=this.pie7||b(t,{h:60,l:-10}),this.pie8=this.pie8||b(t,{h:-60,l:-10}),this.pie9=this.pie9||b(t,{h:120,l:0}),this.pie10=this.pie10||b(t,{h:60,l:-20}),this.pie11=this.pie11||b(t,{h:-60,l:-20}),this.pie12=this.pie12||b(t,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||t,this.quadrant2Fill=this.quadrant2Fill||b(t,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(t,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(t,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Ee(this.quadrant1Fill)?R(this.quadrant1Fill):P(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:((s=this.xyChart)==null?void 0:s.backgroundColor)||this.background,titleColor:((o=this.xyChart)==null?void 0:o.titleColor)||this.primaryTextColor,xAxisTitleColor:((n=this.xyChart)==null?void 0:n.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((l=this.xyChart)==null?void 0:l.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((h=this.xyChart)==null?void 0:h.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((c=this.xyChart)==null?void 0:c.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((u=this.xyChart)==null?void 0:u.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((f=this.xyChart)==null?void 0:f.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((d=this.xyChart)==null?void 0:d.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((p=this.xyChart)==null?void 0:p.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((g=this.xyChart)==null?void 0:g.plotColorPalette)||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||t,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.requirementEdgeLabelBackground="#FFFFFF",this.git0=this.git0||t,this.git1=this.git1||r,this.git2=this.git2||i,this.git3=this.git3||b(t,{h:-30}),this.git4=this.git4||b(t,{h:-60}),this.git5=this.git5||b(t,{h:-90}),this.git6=this.git6||b(t,{h:60}),this.git7=this.git7||b(t,{h:120}),this.darkMode?(this.git0=R(this.git0,25),this.git1=R(this.git1,25),this.git2=R(this.git2,25),this.git3=R(this.git3,25),this.git4=R(this.git4,25),this.git5=R(this.git5,25),this.git6=R(this.git6,25),this.git7=R(this.git7,25)):(this.git0=P(this.git0,25),this.git1=P(this.git1,25),this.git2=P(this.git2,25),this.git3=P(this.git3,25),this.git4=P(this.git4,25),this.git5=P(this.git5,25),this.git6=P(this.git6,25),this.git7=P(this.git7,25)),this.gitInv0=this.gitInv0||L(this.git0),this.gitInv1=this.gitInv1||L(this.git1),this.gitInv2=this.gitInv2||L(this.git2),this.gitInv3=this.gitInv3||L(this.git3),this.gitInv4=this.gitInv4||L(this.git4),this.gitInv5=this.gitInv5||L(this.git5),this.gitInv6=this.gitInv6||L(this.git6),this.gitInv7=this.gitInv7||L(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.commitLineColor=this.commitLineColor??"#BDBCCC",this.erEdgeLabelBackground="#FFFFFF",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Ue,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Ye}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},y(Bi,"Theme"),Bi),Gx=y(e=>{const t=new jx;return t.calculate(e),t},"getThemeVariables"),Li,Xx=(Li=class{constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=R(this.primaryColor,16),this.tertiaryColor=b(this.primaryColor,{h:-160}),this.primaryBorderColor=L(this.background),this.secondaryBorderColor=ht(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ht(this.tertiaryColor,this.darkMode),this.primaryTextColor=L(this.primaryColor),this.secondaryTextColor=L(this.secondaryColor),this.tertiaryTextColor=L(this.tertiaryColor),this.mainBkg="#111113",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=R(L("#323D47"),10),this.border1="#ccc",this.border2=yr(255,255,255,.25),this.arrowheadColor=L(this.background),this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.labelBackground="#111113",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.noteBkgColor=this.noteBkgColor??"#FEF9C3",this.noteTextColor=this.noteTextColor??"#28253D",this.THEME_COLOR_LIMIT=12,this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.nodeBorder="#FFFFFF",this.stateBorder="#FFFFFF",this.useGradient=!1,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="url(#drop-shadow)",this.nodeShadow=!0,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.clusterBkg="#1E1A2E",this.clusterBorder="#BDBCCC",this.noteBorderColor="#FACC15",this.noteFontWeight=600,this.filterColor="#FFFFFF"}updateColors(){var r,i,a,s,o,n,l,h,c,u,f;if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#FFFFFF"),this.secondaryColor=this.secondaryColor||b(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||b(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ht(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ht(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ht(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ht(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#FFFFFF",this.secondaryTextColor=this.secondaryTextColor||L(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||L(this.tertiaryColor),this.lineColor=this.lineColor||L(this.background),this.arrowheadColor=this.arrowheadColor||L(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder="#FFFFFF",this.signalColor="#FFFFFF",this.labelBoxBorderColor="#BDBCCC",this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||P(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||L(this.lineColor),this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||R(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.compositeBackground="#16141F",this.altBackground="#16141F",this.compositeTitleBackground="#16141F",this.stateEdgeLabelBackground="#16141F",this.fontWeight=600,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||b(this.primaryColor,{h:30}),this.cScale4=this.cScale4||b(this.primaryColor,{h:60}),this.cScale5=this.cScale5||b(this.primaryColor,{h:90}),this.cScale6=this.cScale6||b(this.primaryColor,{h:120}),this.cScale7=this.cScale7||b(this.primaryColor,{h:150}),this.cScale8=this.cScale8||b(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||b(this.primaryColor,{h:270}),this.cScale10=this.cScale10||b(this.primaryColor,{h:300}),this.cScale11=this.cScale11||b(this.primaryColor,{h:330}),this.darkMode)for(let d=0;d<this.THEME_COLOR_LIMIT;d++)this["cScale"+d]=P(this["cScale"+d],75);else for(let d=0;d<this.THEME_COLOR_LIMIT;d++)this["cScale"+d]=P(this["cScale"+d],25);for(let d=0;d<this.THEME_COLOR_LIMIT;d++)this["cScaleInv"+d]=this["cScaleInv"+d]||L(this["cScale"+d]);for(let d=0;d<this.THEME_COLOR_LIMIT;d++)this.darkMode?this["cScalePeer"+d]=this["cScalePeer"+d]||R(this["cScale"+d],10):this["cScalePeer"+d]=this["cScalePeer"+d]||P(this["cScale"+d],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let d=0;d<this.THEME_COLOR_LIMIT;d++)this["cScaleLabel"+d]=this["cScaleLabel"+d]||this.scaleLabelColor;const t=this.darkMode?-4:-1;for(let d=0;d<5;d++)this["surface"+d]=this["surface"+d]||b(this.mainBkg,{h:180,s:-15,l:t*(5+d*3)}),this["surfacePeer"+d]=this["surfacePeer"+d]||b(this.mainBkg,{h:180,s:-15,l:t*(8+d*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||b(this.primaryColor,{h:64}),this.fillType3=this.fillType3||b(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||b(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||b(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||b(this.primaryColor,{h:128}),this.fillType7=this.fillType7||b(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||b(this.primaryColor,{l:-10}),this.pie5=this.pie5||b(this.secondaryColor,{l:-10}),this.pie6=this.pie6||b(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||b(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||b(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||b(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||b(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||b(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||b(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Ee(this.quadrant1Fill)?R(this.quadrant1Fill):P(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:((r=this.xyChart)==null?void 0:r.backgroundColor)||this.background,titleColor:((i=this.xyChart)==null?void 0:i.titleColor)||this.primaryTextColor,xAxisTitleColor:((a=this.xyChart)==null?void 0:a.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((s=this.xyChart)==null?void 0:s.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((o=this.xyChart)==null?void 0:o.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((n=this.xyChart)==null?void 0:n.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((l=this.xyChart)==null?void 0:l.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((h=this.xyChart)==null?void 0:h.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((c=this.xyChart)==null?void 0:c.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((u=this.xyChart)==null?void 0:u.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((f=this.xyChart)==null?void 0:f.plotColorPalette)||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.requirementEdgeLabelBackground="#16141F",this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||b(this.primaryColor,{h:-30}),this.git4=this.git4||b(this.primaryColor,{h:-60}),this.git5=this.git5||b(this.primaryColor,{h:-90}),this.git6=this.git6||b(this.primaryColor,{h:60}),this.git7=this.git7||b(this.primaryColor,{h:120}),this.darkMode?(this.git0=R(this.git0,25),this.git1=R(this.git1,25),this.git2=R(this.git2,25),this.git3=R(this.git3,25),this.git4=R(this.git4,25),this.git5=R(this.git5,25),this.git6=R(this.git6,25),this.git7=R(this.git7,25)):(this.git0=P(this.git0,25),this.git1=P(this.git1,25),this.git2=P(this.git2,25),this.git3=P(this.git3,25),this.git4=P(this.git4,25),this.git5=P(this.git5,25),this.git6=P(this.git6,25),this.git7=P(this.git7,25)),this.gitInv0=this.gitInv0||L(this.git0),this.gitInv1=this.gitInv1||L(this.git1),this.gitInv2=this.gitInv2||L(this.git2),this.gitInv3=this.gitInv3||L(this.git3),this.gitInv4=this.gitInv4||L(this.git4),this.gitInv5=this.gitInv5||L(this.git5),this.gitInv6=this.gitInv6||L(this.git6),this.gitInv7=this.gitInv7||L(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.commitLineColor=this.commitLineColor??"#BDBCCC",this.erEdgeLabelBackground="#16141F",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Ue,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Ye}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},y(Li,"Theme"),Li),Vx=y(e=>{const t=new Xx;return t.calculate(e),t},"getThemeVariables"),Fi,Zx=(Fi=class{constructor(){this.background="#ffffff",this.primaryColor="#cccccc",this.mainBkg="#ffffff",this.noteBkgColor="#fff5ad",this.noteTextColor="#28253D",this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.primaryBorderColor=ht(this.primaryColor,this.darkMode),this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.nodeBorder="#28253D",this.stateBorder="#28253D",this.useGradient=!1,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="url(#drop-shadow)",this.nodeShadow=!0,this.tertiaryColor="#ffffff",this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.actorBorder="#28253D",this.noteBorderColor="#FACC15",this.noteFontWeight=600,this.borderColorArray=["#E879F9","#2DD4BF","#FB923C","#22D3EE","#4ADE80","#A78BFA","#F87171","#FACC15","#818CF8","#A3E635 ","#38BDF8","#FB7185"],this.bkgColorArray=["#FDF4FF","#F0FDFA","#FFF7ED","#ECFEFF","#F0FDF4","#F5F3FF","#FEF2F2","#FEFCE8","#EEF2FF","#F7FEE7","#F0F9FF","#FFF1F2"],this.filterColor="#000000"}updateColors(){var s,o,n,l,h,c,u,f,d,p,g;this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#28253D"),this.secondaryColor=this.secondaryColor||b(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||b(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ht(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ht(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ht(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ht(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#28253D",this.secondaryTextColor=this.secondaryTextColor||L(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||L(this.tertiaryColor),this.lineColor=this.lineColor||L(this.background),this.arrowheadColor=this.arrowheadColor||L(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||P(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||L(this.lineColor);const t="#ECECFE",r="#E9E9F1",i=b(t,{h:180,l:5});this.sectionBkgColor=this.sectionBkgColor||i,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||r,this.sectionBkgColor2=this.sectionBkgColor2||t,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||t,this.activeTaskBorderColor=this.activeTaskBorderColor||t,this.activeTaskBkgColor=this.activeTaskBkgColor||R(t,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||"#f4a8ff",this.cScale1=this.cScale1||"#46ecd5",this.cScale2=this.cScale2||"#ffb86a",this.cScale3=this.cScale3||"#dab2ff",this.cScale4=this.cScale4||"#7bf1a8",this.cScale5=this.cScale5||"#c4b4ff",this.cScale6=this.cScale6||"#ffa2a2",this.cScale7=this.cScale7||"#ffdf20",this.cScale8=this.cScale8||"#a3b3ff",this.cScale9=this.cScale9||"#bbf451",this.cScale10=this.cScale10||"#74d4ff",this.cScale11=this.cScale11||"#ffa1ad";for(let m=0;m<this.THEME_COLOR_LIMIT;m++)this["cScaleInv"+m]=this["cScaleInv"+m]||L(this["cScale"+m]);for(let m=0;m<this.THEME_COLOR_LIMIT;m++)this.darkMode?this["cScalePeer"+m]=this["cScalePeer"+m]||R(this["cScale"+m],10):this["cScalePeer"+m]=this["cScalePeer"+m]||P(this["cScale"+m],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let m=0;m<this.THEME_COLOR_LIMIT;m++)this["cScaleLabel"+m]=this["cScaleLabel"+m]||this.scaleLabelColor;const a=this.darkMode?-4:-1;for(let m=0;m<5;m++)this["surface"+m]=this["surface"+m]||b(this.mainBkg,{h:180,s:-15,l:a*(5+m*3)}),this["surfacePeer"+m]=this["surfacePeer"+m]||b(this.mainBkg,{h:180,s:-15,l:a*(8+m*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||t,this.fillType1=this.fillType1||r,this.fillType2=this.fillType2||b(t,{h:64}),this.fillType3=this.fillType3||b(r,{h:64}),this.fillType4=this.fillType4||b(t,{h:-64}),this.fillType5=this.fillType5||b(r,{h:-64}),this.fillType6=this.fillType6||b(t,{h:128}),this.fillType7=this.fillType7||b(r,{h:128}),this.pie1=this.pie1||t,this.pie2=this.pie2||r,this.pie3=this.pie3||i,this.pie4=this.pie4||b(t,{l:-10}),this.pie5=this.pie5||b(r,{l:-10}),this.pie6=this.pie6||b(i,{l:-10}),this.pie7=this.pie7||b(t,{h:60,l:-10}),this.pie8=this.pie8||b(t,{h:-60,l:-10}),this.pie9=this.pie9||b(t,{h:120,l:0}),this.pie10=this.pie10||b(t,{h:60,l:-20}),this.pie11=this.pie11||b(t,{h:-60,l:-20}),this.pie12=this.pie12||b(t,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||t,this.quadrant2Fill=this.quadrant2Fill||b(t,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(t,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(t,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Ee(this.quadrant1Fill)?R(this.quadrant1Fill):P(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:((s=this.xyChart)==null?void 0:s.backgroundColor)||this.background,titleColor:((o=this.xyChart)==null?void 0:o.titleColor)||this.primaryTextColor,xAxisTitleColor:((n=this.xyChart)==null?void 0:n.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((l=this.xyChart)==null?void 0:l.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((h=this.xyChart)==null?void 0:h.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((c=this.xyChart)==null?void 0:c.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((u=this.xyChart)==null?void 0:u.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((f=this.xyChart)==null?void 0:f.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((d=this.xyChart)==null?void 0:d.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((p=this.xyChart)==null?void 0:p.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((g=this.xyChart)==null?void 0:g.plotColorPalette)||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||t,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||t,this.git1=this.git1||r,this.git2=this.git2||i,this.git3=this.git3||b(t,{h:-30}),this.git4=this.git4||b(t,{h:-60}),this.git5=this.git5||b(t,{h:-90}),this.git6=this.git6||b(t,{h:60}),this.git7=this.git7||b(t,{h:120}),this.darkMode?(this.git0=R(this.git0,25),this.git1=R(this.git1,25),this.git2=R(this.git2,25),this.git3=R(this.git3,25),this.git4=R(this.git4,25),this.git5=R(this.git5,25),this.git6=R(this.git6,25),this.git7=R(this.git7,25)):(this.git0=P(this.git0,25),this.git1=P(this.git1,25),this.git2=P(this.git2,25),this.git3=P(this.git3,25),this.git4=P(this.git4,25),this.git5=P(this.git5,25),this.git6=P(this.git6,25),this.git7=P(this.git7,25)),this.gitInv0=this.gitInv0||L(this.git0),this.gitInv1=this.gitInv1||L(this.git1),this.gitInv2=this.gitInv2||L(this.git2),this.gitInv3=this.gitInv3||L(this.git3),this.gitInv4=this.gitInv4||L(this.git4),this.gitInv5=this.gitInv5||L(this.git5),this.gitInv6=this.gitInv6||L(this.git6),this.gitInv7=this.gitInv7||L(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLineColor=this.commitLineColor??"#BDBCCC",this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.fontWeight=600,this.erEdgeLabelBackground="#FFFFFF",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Ue,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Ye}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},y(Fi,"Theme"),Fi),Qx=y(e=>{const t=new Zx;return t.calculate(e),t},"getThemeVariables"),Mi,Kx=(Mi=class{constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=R(this.primaryColor,16),this.tertiaryColor=b(this.primaryColor,{h:-160}),this.primaryBorderColor=L(this.background),this.secondaryBorderColor=ht(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ht(this.tertiaryColor,this.darkMode),this.primaryTextColor=L(this.primaryColor),this.secondaryTextColor=L(this.secondaryColor),this.tertiaryTextColor=L(this.tertiaryColor),this.mainBkg="#111113",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=R(L("#323D47"),10),this.border1="#ccc",this.border2=yr(255,255,255,.25),this.arrowheadColor=L(this.background),this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.labelBackground="#111113",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.noteBkgColor=this.noteBkgColor??"#FEF9C3",this.noteTextColor=this.noteTextColor??"#28253D",this.THEME_COLOR_LIMIT=12,this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.nodeBorder="#FFFFFF",this.stateBorder="#FFFFFF",this.useGradient=!1,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="url(#drop-shadow)",this.nodeShadow=!0,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.clusterBkg="#1E1A2E",this.clusterBorder="#BDBCCC",this.noteBorderColor="#FACC15",this.noteFontWeight=600,this.borderColorArray=["#E879F9","#2DD4BF","#FB923C","#22D3EE","#4ADE80","#A78BFA","#F87171","#FACC15","#818CF8","#A3E635 ","#38BDF8","#FB7185"],this.bkgColorArray=[],this.filterColor="#FFFFFF"}updateColors(){var r,i,a,s,o,n,l,h,c,u,f;this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#FFFFFF"),this.secondaryColor=this.secondaryColor||b(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||b(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ht(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ht(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ht(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ht(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#FFFFFF",this.secondaryTextColor=this.secondaryTextColor||L(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||L(this.tertiaryColor),this.lineColor=this.lineColor||L(this.background),this.arrowheadColor=this.arrowheadColor||L(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder="#FFFFFF",this.signalColor="#FFFFFF",this.labelBoxBorderColor="#BDBCCC",this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||P(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||L(this.lineColor),this.rootLabelColor="#FFFFFF",this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||R(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||"#f4a8ff",this.cScale1=this.cScale1||"#46ecd5",this.cScale2=this.cScale2||"#ffb86a",this.cScale3=this.cScale3||"#dab2ff",this.cScale4=this.cScale4||"#7bf1a8",this.cScale5=this.cScale5||"#c4b4ff",this.cScale6=this.cScale6||"#ffa2a2",this.cScale7=this.cScale7||"#ffdf20",this.cScale8=this.cScale8||"#a3b3ff",this.cScale9=this.cScale9||"#bbf451",this.cScale10=this.cScale10||"#74d4ff",this.cScale11=this.cScale11||"#ffa1ad";for(let d=0;d<this.THEME_COLOR_LIMIT;d++)this["cScaleInv"+d]=this["cScaleInv"+d]||L(this["cScale"+d]);for(let d=0;d<this.THEME_COLOR_LIMIT;d++)this.darkMode?this["cScalePeer"+d]=this["cScalePeer"+d]||R(this["cScale"+d],10):this["cScalePeer"+d]=this["cScalePeer"+d]||P(this["cScale"+d],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let d=0;d<this.THEME_COLOR_LIMIT;d++)this["cScaleLabel"+d]=P(this["cScale"+d],75);const t=this.darkMode?-4:-1;for(let d=0;d<5;d++)this["surface"+d]=this["surface"+d]||b(this.mainBkg,{h:180,s:-15,l:t*(5+d*3)}),this["surfacePeer"+d]=this["surfacePeer"+d]||b(this.mainBkg,{h:180,s:-15,l:t*(8+d*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||b(this.primaryColor,{h:64}),this.fillType3=this.fillType3||b(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||b(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||b(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||b(this.primaryColor,{h:128}),this.fillType7=this.fillType7||b(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||b(this.primaryColor,{l:-10}),this.pie5=this.pie5||b(this.secondaryColor,{l:-10}),this.pie6=this.pie6||b(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||b(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||b(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||b(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||b(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||b(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||b(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Ee(this.quadrant1Fill)?R(this.quadrant1Fill):P(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:((r=this.xyChart)==null?void 0:r.backgroundColor)||this.background,titleColor:((i=this.xyChart)==null?void 0:i.titleColor)||this.primaryTextColor,xAxisTitleColor:((a=this.xyChart)==null?void 0:a.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((s=this.xyChart)==null?void 0:s.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((o=this.xyChart)==null?void 0:o.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((n=this.xyChart)==null?void 0:n.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((l=this.xyChart)==null?void 0:l.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((h=this.xyChart)==null?void 0:h.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((c=this.xyChart)==null?void 0:c.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((u=this.xyChart)==null?void 0:u.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((f=this.xyChart)==null?void 0:f.plotColorPalette)||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?P(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||b(this.primaryColor,{h:-30}),this.git4=this.git4||b(this.primaryColor,{h:-60}),this.git5=this.git5||b(this.primaryColor,{h:-90}),this.git6=this.git6||b(this.primaryColor,{h:60}),this.git7=this.git7||b(this.primaryColor,{h:120}),this.darkMode?(this.git0=R(this.git0,25),this.git1=R(this.git1,25),this.git2=R(this.git2,25),this.git3=R(this.git3,25),this.git4=R(this.git4,25),this.git5=R(this.git5,25),this.git6=R(this.git6,25),this.git7=R(this.git7,25)):(this.git0=P(this.git0,25),this.git1=P(this.git1,25),this.git2=P(this.git2,25),this.git3=P(this.git3,25),this.git4=P(this.git4,25),this.git5=P(this.git5,25),this.git6=P(this.git6,25),this.git7=P(this.git7,25)),this.gitInv0=this.gitInv0||L(this.git0),this.gitInv1=this.gitInv1||L(this.git1),this.gitInv2=this.gitInv2||L(this.git2),this.gitInv3=this.gitInv3||L(this.git3),this.gitInv4=this.gitInv4||L(this.git4),this.gitInv5=this.gitInv5||L(this.git5),this.gitInv6=this.gitInv6||L(this.git6),this.gitInv7=this.gitInv7||L(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.commitLineColor=this.commitLineColor??"#BDBCCC",this.fontWeight=600,this.erEdgeLabelBackground="#16141F",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Ue,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Ye}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},y(Mi,"Theme"),Mi),Jx=y(e=>{const t=new Kx;return t.calculate(e),t},"getThemeVariables"),ar={base:{getThemeVariables:$x},dark:{getThemeVariables:Ox},default:{getThemeVariables:Px},forest:{getThemeVariables:Nx},neutral:{getThemeVariables:zx},neo:{getThemeVariables:Hx},"neo-dark":{getThemeVariables:Yx},redux:{getThemeVariables:Gx},"redux-dark":{getThemeVariables:Vx},"redux-color":{getThemeVariables:Qx},"redux-dark-color":{getThemeVariables:Jx}},fe={flowchart:{useMaxWidth:!0,titleTopMargin:25,subGraphTitleMargin:{top:0,bottom:0},diagramPadding:8,htmlLabels:null,nodeSpacing:50,rankSpacing:50,curve:"basis",padding:15,defaultRenderer:"dagre-wrapper",wrappingWidth:200,inheritDir:!1},sequence:{useMaxWidth:!0,hideUnusedParticipants:!1,activationWidth:10,diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",mirrorActors:!0,forceMenus:!1,bottomMarginAdj:1,rightAngles:!1,showSequenceNumbers:!1,actorFontSize:14,actorFontFamily:'"Open Sans", sans-serif',actorFontWeight:400,noteFontSize:14,noteFontFamily:'"trebuchet ms", verdana, arial, sans-serif',noteFontWeight:400,noteAlign:"center",messageFontSize:16,messageFontFamily:'"trebuchet ms", verdana, arial, sans-serif',messageFontWeight:400,wrap:!1,wrapPadding:10,labelBoxWidth:50,labelBoxHeight:20},gantt:{useMaxWidth:!0,titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,rightPadding:75,leftPadding:75,gridLineStartPadding:35,fontSize:11,sectionFontSize:11,numberSectionStyles:4,axisFormat:"%Y-%m-%d",topAxis:!1,displayMode:"",weekday:"sunday"},journey:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,maxLabelWidth:360,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],titleColor:"",titleFontFamily:'"trebuchet ms", verdana, arial, sans-serif',titleFontSize:"4ex"},class:{useMaxWidth:!0,titleTopMargin:25,arrowMarkerAbsolute:!1,dividerMargin:10,padding:5,textHeight:10,defaultRenderer:"dagre-wrapper",htmlLabels:!1,hideEmptyMembersBox:!1},state:{useMaxWidth:!0,titleTopMargin:25,dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:"20",compositTitleSize:35,radius:5,defaultRenderer:"dagre-wrapper"},er:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:20,layoutDirection:"TB",minEntityWidth:100,minEntityHeight:75,entityPadding:15,nodeSpacing:140,rankSpacing:80,stroke:"gray",fill:"honeydew",fontSize:12},pie:{useMaxWidth:!0,textPosition:.75},quadrantChart:{useMaxWidth:!0,chartWidth:500,chartHeight:500,titleFontSize:20,titlePadding:10,quadrantPadding:5,xAxisLabelPadding:5,yAxisLabelPadding:5,xAxisLabelFontSize:16,yAxisLabelFontSize:16,quadrantLabelFontSize:16,quadrantTextTopPadding:5,pointTextPadding:5,pointLabelFontSize:12,pointRadius:5,xAxisPosition:"top",yAxisPosition:"left",quadrantInternalBorderStrokeWidth:1,quadrantExternalBorderStrokeWidth:2},xyChart:{useMaxWidth:!0,width:700,height:500,titleFontSize:20,titlePadding:10,showDataLabel:!1,showDataLabelOutsideBar:!1,showTitle:!0,xAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2},yAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2},chartOrientation:"vertical",plotReservedSpacePercent:50},requirement:{useMaxWidth:!0,rect_fill:"#f9f9f9",text_color:"#333",rect_border_size:"0.5px",rect_border_color:"#bbb",rect_min_width:200,rect_min_height:200,fontSize:14,rect_padding:10,line_height:20},mindmap:{useMaxWidth:!0,padding:10,maxNodeWidth:200,layoutAlgorithm:"cose-bilkent"},ishikawa:{useMaxWidth:!0,diagramPadding:20},kanban:{useMaxWidth:!0,padding:8,sectionWidth:200,ticketBaseUrl:""},timeline:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],disableMulticolor:!1},gitGraph:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:8,nodeLabel:{width:75,height:100,x:-25,y:0},mainBranchName:"main",mainBranchOrder:0,showCommitLabel:!0,showBranches:!0,rotateCommitLabel:!0,parallelCommits:!1,arrowMarkerAbsolute:!1},c4:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,c4ShapeMargin:50,c4ShapePadding:20,width:216,height:60,boxMargin:10,c4ShapeInRow:4,nextLinePaddingX:0,c4BoundaryInRow:2,personFontSize:14,personFontFamily:'"Open Sans", sans-serif',personFontWeight:"normal",external_personFontSize:14,external_personFontFamily:'"Open Sans", sans-serif',external_personFontWeight:"normal",systemFontSize:14,systemFontFamily:'"Open Sans", sans-serif',systemFontWeight:"normal",external_systemFontSize:14,external_systemFontFamily:'"Open Sans", sans-serif',external_systemFontWeight:"normal",system_dbFontSize:14,system_dbFontFamily:'"Open Sans", sans-serif',system_dbFontWeight:"normal",external_system_dbFontSize:14,external_system_dbFontFamily:'"Open Sans", sans-serif',external_system_dbFontWeight:"normal",system_queueFontSize:14,system_queueFontFamily:'"Open Sans", sans-serif',system_queueFontWeight:"normal",external_system_queueFontSize:14,external_system_queueFontFamily:'"Open Sans", sans-serif',external_system_queueFontWeight:"normal",boundaryFontSize:14,boundaryFontFamily:'"Open Sans", sans-serif',boundaryFontWeight:"normal",messageFontSize:12,messageFontFamily:'"Open Sans", sans-serif',messageFontWeight:"normal",containerFontSize:14,containerFontFamily:'"Open Sans", sans-serif',containerFontWeight:"normal",external_containerFontSize:14,external_containerFontFamily:'"Open Sans", sans-serif',external_containerFontWeight:"normal",container_dbFontSize:14,container_dbFontFamily:'"Open Sans", sans-serif',container_dbFontWeight:"normal",external_container_dbFontSize:14,external_container_dbFontFamily:'"Open Sans", sans-serif',external_container_dbFontWeight:"normal",container_queueFontSize:14,container_queueFontFamily:'"Open Sans", sans-serif',container_queueFontWeight:"normal",external_container_queueFontSize:14,external_container_queueFontFamily:'"Open Sans", sans-serif',external_container_queueFontWeight:"normal",componentFontSize:14,componentFontFamily:'"Open Sans", sans-serif',componentFontWeight:"normal",external_componentFontSize:14,external_componentFontFamily:'"Open Sans", sans-serif',external_componentFontWeight:"normal",component_dbFontSize:14,component_dbFontFamily:'"Open Sans", sans-serif',component_dbFontWeight:"normal",external_component_dbFontSize:14,external_component_dbFontFamily:'"Open Sans", sans-serif',external_component_dbFontWeight:"normal",component_queueFontSize:14,component_queueFontFamily:'"Open Sans", sans-serif',component_queueFontWeight:"normal",external_component_queueFontSize:14,external_component_queueFontFamily:'"Open Sans", sans-serif',external_component_queueFontWeight:"normal",wrap:!0,wrapPadding:10,person_bg_color:"#08427B",person_border_color:"#073B6F",external_person_bg_color:"#686868",external_person_border_color:"#8A8A8A",system_bg_color:"#1168BD",system_border_color:"#3C7FC0",system_db_bg_color:"#1168BD",system_db_border_color:"#3C7FC0",system_queue_bg_color:"#1168BD",system_queue_border_color:"#3C7FC0",external_system_bg_color:"#999999",external_system_border_color:"#8A8A8A",external_system_db_bg_color:"#999999",external_system_db_border_color:"#8A8A8A",external_system_queue_bg_color:"#999999",external_system_queue_border_color:"#8A8A8A",container_bg_color:"#438DD5",container_border_color:"#3C7FC0",container_db_bg_color:"#438DD5",container_db_border_color:"#3C7FC0",container_queue_bg_color:"#438DD5",container_queue_border_color:"#3C7FC0",external_container_bg_color:"#B3B3B3",external_container_border_color:"#A6A6A6",external_container_db_bg_color:"#B3B3B3",external_container_db_border_color:"#A6A6A6",external_container_queue_bg_color:"#B3B3B3",external_container_queue_border_color:"#A6A6A6",component_bg_color:"#85BBF0",component_border_color:"#78A8D8",component_db_bg_color:"#85BBF0",component_db_border_color:"#78A8D8",component_queue_bg_color:"#85BBF0",component_queue_border_color:"#78A8D8",external_component_bg_color:"#CCCCCC",external_component_border_color:"#BFBFBF",external_component_db_bg_color:"#CCCCCC",external_component_db_border_color:"#BFBFBF",external_component_queue_bg_color:"#CCCCCC",external_component_queue_border_color:"#BFBFBF"},sankey:{useMaxWidth:!0,width:600,height:400,linkColor:"gradient",nodeAlignment:"justify",showValues:!0,prefix:"",suffix:""},block:{useMaxWidth:!0,padding:8},packet:{useMaxWidth:!0,rowHeight:32,bitWidth:32,bitsPerRow:32,showBits:!0,paddingX:5,paddingY:5},treeView:{useMaxWidth:!0,rowIndent:10,paddingX:5,paddingY:5,lineThickness:1},architecture:{useMaxWidth:!0,padding:40,iconSize:80,fontSize:16,randomize:!1},radar:{useMaxWidth:!0,width:600,height:600,marginTop:50,marginRight:50,marginBottom:50,marginLeft:50,axisScaleFactor:1,axisLabelFactor:1.05,curveTension:.17},venn:{useMaxWidth:!0,width:800,height:450,padding:8,useDebugLayout:!1},theme:"default",look:"classic",handDrawnSeed:0,layout:"dagre",maxTextSize:5e4,maxEdges:500,darkMode:!1,fontFamily:'"trebuchet ms", verdana, arial, sans-serif;',logLevel:5,securityLevel:"strict",startOnLoad:!0,arrowMarkerAbsolute:!1,secure:["secure","securityLevel","startOnLoad","maxTextSize","suppressErrorRendering","maxEdges"],legacyMathML:!1,forceLegacyMathML:!1,deterministicIds:!1,fontSize:16,markdownAutoWrap:!0,suppressErrorRendering:!1},Kd={...fe,deterministicIDSeed:void 0,elk:{mergeEdges:!1,nodePlacementStrategy:"BRANDES_KOEPF",forceNodeModelOrder:!1,considerModelOrder:"NODES_AND_EDGES"},themeCSS:void 0,themeVariables:ar.default.getThemeVariables(),sequence:{...fe.sequence,messageFont:y(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont"),noteFont:y(function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},"noteFont"),actorFont:y(function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}},"actorFont")},class:{hideEmptyMembersBox:!1},gantt:{...fe.gantt,tickInterval:void 0,useWidth:void 0},c4:{...fe.c4,useWidth:void 0,personFont:y(function(){return{fontFamily:this.personFontFamily,fontSize:this.personFontSize,fontWeight:this.personFontWeight}},"personFont"),flowchart:{...fe.flowchart,inheritDir:!1},external_personFont:y(function(){return{fontFamily:this.external_personFontFamily,fontSize:this.external_personFontSize,fontWeight:this.external_personFontWeight}},"external_personFont"),systemFont:y(function(){return{fontFamily:this.systemFontFamily,fontSize:this.systemFontSize,fontWeight:this.systemFontWeight}},"systemFont"),external_systemFont:y(function(){return{fontFamily:this.external_systemFontFamily,fontSize:this.external_systemFontSize,fontWeight:this.external_systemFontWeight}},"external_systemFont"),system_dbFont:y(function(){return{fontFamily:this.system_dbFontFamily,fontSize:this.system_dbFontSize,fontWeight:this.system_dbFontWeight}},"system_dbFont"),external_system_dbFont:y(function(){return{fontFamily:this.external_system_dbFontFamily,fontSize:this.external_system_dbFontSize,fontWeight:this.external_system_dbFontWeight}},"external_system_dbFont"),system_queueFont:y(function(){return{fontFamily:this.system_queueFontFamily,fontSize:this.system_queueFontSize,fontWeight:this.system_queueFontWeight}},"system_queueFont"),external_system_queueFont:y(function(){return{fontFamily:this.external_system_queueFontFamily,fontSize:this.external_system_queueFontSize,fontWeight:this.external_system_queueFontWeight}},"external_system_queueFont"),containerFont:y(function(){return{fontFamily:this.containerFontFamily,fontSize:this.containerFontSize,fontWeight:this.containerFontWeight}},"containerFont"),external_containerFont:y(function(){return{fontFamily:this.external_containerFontFamily,fontSize:this.external_containerFontSize,fontWeight:this.external_containerFontWeight}},"external_containerFont"),container_dbFont:y(function(){return{fontFamily:this.container_dbFontFamily,fontSize:this.container_dbFontSize,fontWeight:this.container_dbFontWeight}},"container_dbFont"),external_container_dbFont:y(function(){return{fontFamily:this.external_container_dbFontFamily,fontSize:this.external_container_dbFontSize,fontWeight:this.external_container_dbFontWeight}},"external_container_dbFont"),container_queueFont:y(function(){return{fontFamily:this.container_queueFontFamily,fontSize:this.container_queueFontSize,fontWeight:this.container_queueFontWeight}},"container_queueFont"),external_container_queueFont:y(function(){return{fontFamily:this.external_container_queueFontFamily,fontSize:this.external_container_queueFontSize,fontWeight:this.external_container_queueFontWeight}},"external_container_queueFont"),componentFont:y(function(){return{fontFamily:this.componentFontFamily,fontSize:this.componentFontSize,fontWeight:this.componentFontWeight}},"componentFont"),external_componentFont:y(function(){return{fontFamily:this.external_componentFontFamily,fontSize:this.external_componentFontSize,fontWeight:this.external_componentFontWeight}},"external_componentFont"),component_dbFont:y(function(){return{fontFamily:this.component_dbFontFamily,fontSize:this.component_dbFontSize,fontWeight:this.component_dbFontWeight}},"component_dbFont"),external_component_dbFont:y(function(){return{fontFamily:this.external_component_dbFontFamily,fontSize:this.external_component_dbFontSize,fontWeight:this.external_component_dbFontWeight}},"external_component_dbFont"),component_queueFont:y(function(){return{fontFamily:this.component_queueFontFamily,fontSize:this.component_queueFontSize,fontWeight:this.component_queueFontWeight}},"component_queueFont"),external_component_queueFont:y(function(){return{fontFamily:this.external_component_queueFontFamily,fontSize:this.external_component_queueFontSize,fontWeight:this.external_component_queueFontWeight}},"external_component_queueFont"),boundaryFont:y(function(){return{fontFamily:this.boundaryFontFamily,fontSize:this.boundaryFontSize,fontWeight:this.boundaryFontWeight}},"boundaryFont"),messageFont:y(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont")},pie:{...fe.pie,useWidth:984},xyChart:{...fe.xyChart,useWidth:void 0},requirement:{...fe.requirement,useWidth:void 0},packet:{...fe.packet},treeView:{...fe.treeView,useWidth:void 0},radar:{...fe.radar},ishikawa:{...fe.ishikawa},treemap:{useMaxWidth:!0,padding:10,diagramPadding:8,showValues:!0,nodeWidth:100,nodeHeight:40,borderWidth:1,valueFontSize:12,labelFontSize:14,valueFormat:","},venn:{...fe.venn}},Jd=y((e,t="")=>Object.keys(e).reduce((r,i)=>Array.isArray(e[i])?r:typeof e[i]=="object"&&e[i]!==null?[...r,t+i,...Jd(e[i],"")]:[...r,t+i],[]),"keyify"),t1=new Set(Jd(Kd,"")),tf=Kd,Hs=y(e=>{if(W.debug("sanitizeDirective called with",e),!(typeof e!="object"||e==null)){if(Array.isArray(e)){e.forEach(t=>Hs(t));return}for(const t of Object.keys(e)){if(W.debug("Checking key",t),t.startsWith("__")||t.includes("proto")||t.includes("constr")||!t1.has(t)||e[t]==null){W.debug("sanitize deleting key: ",t),delete e[t];continue}if(typeof e[t]=="object"){W.debug("sanitizing object",t),Hs(e[t]);continue}const r=["themeCSS","fontFamily","altFontFamily"];for(const i of r)t.includes(i)&&(W.debug("sanitizing css option",t),e[t]=e1(e[t]))}if(e.themeVariables)for(const t of Object.keys(e.themeVariables)){const r=e.themeVariables[t];r!=null&&r.match&&!r.match(/^[\d "#%(),.;A-Za-z]+$/)&&(e.themeVariables[t]="")}W.debug("After sanitization",e)}},"sanitizeDirective"),e1=y(e=>{let t=0,r=0;for(const i of e){if(t<r)return"{ /* ERROR: Unbalanced CSS */ }";i==="{"?t++:i==="}"&&r++}return t!==r?"{ /* ERROR: Unbalanced CSS */ }":e},"sanitizeCss"),Di=Object.freeze(tf),cr=y(e=>!(e===!1||["false","null","0"].includes(String(e).trim().toLowerCase())),"evaluate"),ce=qt({},Di),Us,Nr=[],Sa=qt({},Di),Po=y((e,t)=>{let r=qt({},e),i={};for(const a of t)af(a),i=qt(i,a);if(r=qt(r,i),i.theme&&i.theme in ar){const a=qt({},Us),s=qt(a.themeVariables||{},i.themeVariables);r.theme&&r.theme in ar&&(r.themeVariables=ar[r.theme].getThemeVariables(s))}return Sa=r,of(Sa),Sa},"updateCurrentConfig"),r1=y(e=>(ce=qt({},Di),ce=qt(ce,e),e.theme&&ar[e.theme]&&(ce.themeVariables=ar[e.theme].getThemeVariables(e.themeVariables)),Po(ce,Nr),ce),"setSiteConfig"),i1=y(e=>{Us=qt({},e)},"saveConfigFromInitialize"),a1=y(e=>(ce=qt(ce,e),Po(ce,Nr),ce),"updateSiteConfig"),ef=y(()=>qt({},ce),"getSiteConfig"),rf=y(e=>(of(e),qt(Sa,e),At()),"setConfig"),At=y(()=>qt({},Sa),"getConfig"),af=y(e=>{e&&(["secure",...ce.secure??[]].forEach(t=>{Object.hasOwn(e,t)&&(W.debug(`Denied attempt to modify a secure key ${t}`,e[t]),delete e[t])}),Object.keys(e).forEach(t=>{t.startsWith("__")&&delete e[t]}),Object.keys(e).forEach(t=>{typeof e[t]=="string"&&(e[t].includes("<")||e[t].includes(">")||e[t].includes("url(data:"))&&delete e[t],typeof e[t]=="object"&&af(e[t])}))},"sanitize"),s1=y(e=>{var t;Hs(e),e.fontFamily&&!((t=e.themeVariables)!=null&&t.fontFamily)&&(e.themeVariables={...e.themeVariables,fontFamily:e.fontFamily}),Nr.push(e),Po(ce,Nr)},"addDirective"),Ys=y((e=ce)=>{Nr=[],Po(e,Nr)},"reset"),o1={LAZY_LOAD_DEPRECATED:"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead.",FLOWCHART_HTML_LABELS_DEPRECATED:"flowchart.htmlLabels is deprecated. Please use global htmlLabels instead."},Nc={},sf=y(e=>{Nc[e]||(W.warn(o1[e]),Nc[e]=!0)},"issueWarning"),of=y(e=>{e&&(e.lazyLoadedDiagrams||e.loadExternalDiagramsAtStartup)&&sf("LAZY_LOAD_DEPRECATED")},"checkConfig"),L$=y(()=>{let e={};Us&&(e=qt(e,Us));for(const t of Nr)e=qt(e,t);return e},"getUserDefinedConfig"),ne=y(e=>{var t,r;return((t=e.flowchart)==null?void 0:t.htmlLabels)!=null&&sf("FLOWCHART_HTML_LABELS_DEPRECATED"),cr(e.htmlLabels??((r=e.flowchart)==null?void 0:r.htmlLabels)??!0)},"getEffectiveHtmlLabels"),Ua=/<br\s*\/?>/gi,n1=y(e=>e?hf(e).replace(/\\n/g,"#br#").split("#br#"):[""],"getRows"),l1=(()=>{let e=!1;return()=>{e||(nf(),e=!0)}})();function nf(){const e="data-temp-href-target";$i.addHook("beforeSanitizeAttributes",t=>{t.tagName==="A"&&t.hasAttribute("target")&&t.setAttribute(e,t.getAttribute("target")??"")}),$i.addHook("afterSanitizeAttributes",t=>{t.tagName==="A"&&t.hasAttribute(e)&&(t.setAttribute("target",t.getAttribute(e)??""),t.removeAttribute(e),t.getAttribute("target")==="_blank"&&t.setAttribute("rel","noopener"))})}y(nf,"setupDompurifyHooks");var lf=y(e=>(l1(),$i.sanitize(e)),"removeScript"),qc=y((e,t)=>{if(ne(t)){const r=t.securityLevel;r==="antiscript"||r==="strict"||r==="sandbox"?e=lf(e):r!=="loose"&&(e=hf(e),e=e.replace(/</g,"&lt;").replace(/>/g,"&gt;"),e=e.replace(/=/g,"&equals;"),e=d1(e))}return e},"sanitizeMore"),Ae=y((e,t)=>e&&(t.dompurifyConfig?e=$i.sanitize(qc(e,t),t.dompurifyConfig).toString():e=$i.sanitize(qc(e,t),{FORBID_TAGS:["style"]}).toString(),e),"sanitizeText"),h1=y((e,t)=>typeof e=="string"?Ae(e,t):e.flat().map(r=>Ae(r,t)),"sanitizeTextOrArray"),c1=y(e=>Ua.test(e),"hasBreaks"),u1=y(e=>e.split(Ua),"splitBreaks"),d1=y(e=>e.replace(/#br#/g,"<br/>"),"placeholderToBreak"),hf=y(e=>e.replace(Ua,"#br#"),"breakToPlaceholder"),f1=y(e=>{let t="";return e&&(t=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,t=CSS.escape(t)),t},"getUrl"),p1=y(function(...e){const t=e.filter(r=>!isNaN(r));return Math.max(...t)},"getMax"),g1=y(function(...e){const t=e.filter(r=>!isNaN(r));return Math.min(...t)},"getMin"),zc=y(function(e){const t=e.split(/(,)/),r=[];for(let i=0;i<t.length;i++){let a=t[i];if(a===","&&i>0&&i+1<t.length){const s=t[i-1],o=t[i+1];m1(s,o)&&(a=s+","+o,i++,r.pop())}r.push(y1(a))}return r.join("")},"parseGenericTypes"),rl=y((e,t)=>Math.max(0,e.split(t).length-1),"countOccurrence"),m1=y((e,t)=>{const r=rl(e,"~"),i=rl(t,"~");return r===1&&i===1},"shouldCombineSets"),y1=y(e=>{const t=rl(e,"~");let r=!1;if(t<=1)return e;t%2!==0&&e.startsWith("~")&&(e=e.substring(1),r=!0);const i=[...e];let a=i.indexOf("~"),s=i.lastIndexOf("~");for(;a!==-1&&s!==-1&&a!==s;)i[a]="<",i[s]=">",a=i.indexOf("~"),s=i.lastIndexOf("~");return r&&i.unshift("~"),i.join("")},"processSet"),Wc=y(()=>window.MathMLElement!==void 0,"isMathMLSupported"),il=/\$\$(.*)\$\$/g,Ma=y(e=>{var t;return(((t=e.match(il))==null?void 0:t.length)??0)>0},"hasKatex"),F$=y(async(e,t)=>{const r=document.createElement("div");r.innerHTML=await cf(e,t),r.id="katex-temp",r.style.visibility="hidden",r.style.position="absolute",r.style.top="0";const i=document.querySelector("body");i==null||i.insertAdjacentElement("beforeend",r);const a={width:r.clientWidth,height:r.clientHeight};return r.remove(),a},"calculateMathMLDimensions"),C1=y(async(e,t)=>{if(!Ma(e))return e;if(!(Wc()||t.legacyMathML||t.forceLegacyMathML))return e.replace(il,"MathML is unsupported in this environment.");{const{default:r}=await Ct(async()=>{const{default:a}=await import("./katex-DkKDou_j.js");return{default:a}},[]),i=t.forceLegacyMathML||!Wc()&&t.legacyMathML?"htmlAndMathml":"mathml";return e.split(Ua).map(a=>Ma(a)?`<div style="display: flex; align-items: center; justify-content: center; white-space: nowrap;">${a}</div>`:`<div>${a}</div>`).join("").replace(il,(a,s)=>r.renderToString(s,{throwOnError:!0,displayMode:!0,output:i}).replace(/\n/g," ").replace(/<annotation.*<\/annotation>/g,""))}},"renderKatexUnsanitized"),cf=y(async(e,t)=>Ae(await C1(e,t),t),"renderKatexSanitized"),Ya={getRows:n1,sanitizeText:Ae,sanitizeTextOrArray:h1,hasBreaks:c1,splitBreaks:u1,lineBreakRegex:Ua,removeScript:lf,getUrl:f1,evaluate:cr,getMax:p1,getMin:g1},x1=y(function(e,t){for(let r of t)e.attr(r[0],r[1])},"d3Attrs"),b1=y(function(e,t,r){let i=new Map;return r?(i.set("width","100%"),i.set("style",`max-width: ${t}px;`)):(i.set("height",e),i.set("width",t)),i},"calculateSvgSizeAttrs"),uf=y(function(e,t,r,i){const a=b1(t,r,i);x1(e,a)},"configureSvgSize"),k1=y(function(e,t,r,i){const a=t.node().getBBox(),s=a.width,o=a.height;W.info(`SVG bounds: ${s}x${o}`,a);let n=0,l=0;W.info(`Graph bounds: ${n}x${l}`,e),n=s+r*2,l=o+r*2,W.info(`Calculated bounds: ${n}x${l}`),uf(t,l,n,i);const h=`${a.x-r} ${a.y-r} ${a.width+2*r} ${a.height+2*r}`;t.attr("viewBox",h)},"setupGraphViewbox"),Fs={},T1=y((e,t,r,i)=>{let a="";return e in Fs&&Fs[e]?a=Fs[e]({...r,svgId:i}):W.warn(`No theme found for ${e}`),` & {
5
+ font-family: ${r.fontFamily};
6
+ font-size: ${r.fontSize};
7
+ fill: ${r.textColor}
8
+ }
9
+ @keyframes edge-animation-frame {
10
+ from {
11
+ stroke-dashoffset: 0;
12
+ }
13
+ }
14
+ @keyframes dash {
15
+ to {
16
+ stroke-dashoffset: 0;
17
+ }
18
+ }
19
+ & .edge-animation-slow {
20
+ stroke-dasharray: 9,5 !important;
21
+ stroke-dashoffset: 900;
22
+ animation: dash 50s linear infinite;
23
+ stroke-linecap: round;
24
+ }
25
+ & .edge-animation-fast {
26
+ stroke-dasharray: 9,5 !important;
27
+ stroke-dashoffset: 900;
28
+ animation: dash 20s linear infinite;
29
+ stroke-linecap: round;
30
+ }
31
+ /* Classes common for multiple diagrams */
32
+
33
+ & .error-icon {
34
+ fill: ${r.errorBkgColor};
35
+ }
36
+ & .error-text {
37
+ fill: ${r.errorTextColor};
38
+ stroke: ${r.errorTextColor};
39
+ }
40
+
41
+ & .edge-thickness-normal {
42
+ stroke-width: ${r.strokeWidth??1}px;
43
+ }
44
+ & .edge-thickness-thick {
45
+ stroke-width: 3.5px
46
+ }
47
+ & .edge-pattern-solid {
48
+ stroke-dasharray: 0;
49
+ }
50
+ & .edge-thickness-invisible {
51
+ stroke-width: 0;
52
+ fill: none;
53
+ }
54
+ & .edge-pattern-dashed{
55
+ stroke-dasharray: 3;
56
+ }
57
+ .edge-pattern-dotted {
58
+ stroke-dasharray: 2;
59
+ }
60
+
61
+ & .marker {
62
+ fill: ${r.lineColor};
63
+ stroke: ${r.lineColor};
64
+ }
65
+ & .marker.cross {
66
+ stroke: ${r.lineColor};
67
+ }
68
+
69
+ & svg {
70
+ font-family: ${r.fontFamily};
71
+ font-size: ${r.fontSize};
72
+ }
73
+ & p {
74
+ margin: 0
75
+ }
76
+
77
+ ${a}
78
+ .node .neo-node {
79
+ stroke: ${r.nodeBorder};
80
+ }
81
+
82
+ [data-look="neo"].node rect, [data-look="neo"].cluster rect, [data-look="neo"].node polygon {
83
+ stroke: ${r.useGradient?"url("+i+"-gradient)":r.nodeBorder};
84
+ filter: ${r.dropShadow?r.dropShadow.replace("url(#drop-shadow)",`url(${i}-drop-shadow)`):"none"};
85
+ }
86
+
87
+
88
+ [data-look="neo"].node path {
89
+ stroke: ${r.useGradient?"url("+i+"-gradient)":r.nodeBorder};
90
+ stroke-width: ${r.strokeWidth??1}px;
91
+ }
92
+
93
+ [data-look="neo"].node .outer-path {
94
+ filter: ${r.dropShadow?r.dropShadow.replace("url(#drop-shadow)",`url(${i}-drop-shadow)`):"none"};
95
+ }
96
+
97
+ [data-look="neo"].node .neo-line path {
98
+ stroke: ${r.nodeBorder};
99
+ filter: none;
100
+ }
101
+
102
+ [data-look="neo"].node circle{
103
+ stroke: ${r.useGradient?"url("+i+"-gradient)":r.nodeBorder};
104
+ filter: ${r.dropShadow?r.dropShadow.replace("url(#drop-shadow)",`url(${i}-drop-shadow)`):"none"};
105
+ }
106
+
107
+ [data-look="neo"].node circle .state-start{
108
+ fill: #000000;
109
+ }
110
+
111
+ [data-look="neo"].icon-shape .icon {
112
+ fill: ${r.useGradient?"url("+i+"-gradient)":r.nodeBorder};
113
+ filter: ${r.dropShadow?r.dropShadow.replace("url(#drop-shadow)",`url(${i}-drop-shadow)`):"none"};
114
+ }
115
+
116
+ [data-look="neo"].icon-shape .icon-neo path {
117
+ stroke: ${r.useGradient?"url("+i+"-gradient)":r.nodeBorder};
118
+ filter: ${r.dropShadow?r.dropShadow.replace("url(#drop-shadow)",`url(${i}-drop-shadow)`):"none"};
119
+ }
120
+
121
+ ${t}
122
+ `},"getStyles"),w1=y((e,t)=>{t!==void 0&&(Fs[e]=t)},"addStylesForDiagram"),_1=T1,df={};ex(df,{clear:()=>S1,getAccDescription:()=>F1,getAccTitle:()=>B1,getDiagramTitle:()=>A1,setAccDescription:()=>L1,setAccTitle:()=>v1,setDiagramTitle:()=>M1});var nh="",lh="",hh="",ch=y(e=>Ae(e,At()),"sanitizeText"),S1=y(()=>{nh="",hh="",lh=""},"clear"),v1=y(e=>{nh=ch(e).replace(/^\s+/g,"")},"setAccTitle"),B1=y(()=>nh,"getAccTitle"),L1=y(e=>{hh=ch(e).replace(/\n\s+/g,`
123
+ `)},"setAccDescription"),F1=y(()=>hh,"getAccDescription"),M1=y(e=>{lh=ch(e)},"setDiagramTitle"),A1=y(()=>lh,"getDiagramTitle"),Hc=W,E1=ah,bt=At,M$=rf,A$=Di,uh=y(e=>Ae(e,bt()),"sanitizeText"),$1=k1,D1=y(()=>df,"getCommonDb"),js={},Gs=y((e,t,r)=>{var i;js[e]&&Hc.warn(`Diagram with id ${e} already registered. Overwriting.`),js[e]=t,r&&Qd(e,r),w1(e,t.styles),(i=t.injectUtils)==null||i.call(t,Hc,E1,bt,uh,$1,D1(),()=>{})},"registerDiagram"),al=y(e=>{if(e in js)return js[e];throw new O1(e)},"getDiagram"),Ai,O1=(Ai=class extends Error{constructor(t){super(`Diagram ${t} not found.`)}},y(Ai,"DiagramNotFoundError"),Ai);function Ms(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function I1(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function dh(e){let t,r,i;e.length!==2?(t=Ms,r=(n,l)=>Ms(e(n),l),i=(n,l)=>e(n)-l):(t=e===Ms||e===I1?e:P1,r=e,i=e);function a(n,l,h=0,c=n.length){if(h<c){if(t(l,l)!==0)return c;do{const u=h+c>>>1;r(n[u],l)<0?h=u+1:c=u}while(h<c)}return h}function s(n,l,h=0,c=n.length){if(h<c){if(t(l,l)!==0)return c;do{const u=h+c>>>1;r(n[u],l)<=0?h=u+1:c=u}while(h<c)}return h}function o(n,l,h=0,c=n.length){const u=a(n,l,h,c-1);return u>h&&i(n[u-1],l)>-i(n[u],l)?u-1:u}return{left:a,center:o,right:s}}function P1(){return 0}function R1(e){return e===null?NaN:+e}const N1=dh(Ms),q1=N1.right;dh(R1).center;class Uc extends Map{constructor(t,r=H1){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),t!=null)for(const[i,a]of t)this.set(i,a)}get(t){return super.get(Yc(this,t))}has(t){return super.has(Yc(this,t))}set(t,r){return super.set(z1(this,t),r)}delete(t){return super.delete(W1(this,t))}}function Yc({_intern:e,_key:t},r){const i=t(r);return e.has(i)?e.get(i):r}function z1({_intern:e,_key:t},r){const i=t(r);return e.has(i)?e.get(i):(e.set(i,r),r)}function W1({_intern:e,_key:t},r){const i=t(r);return e.has(i)&&(r=e.get(i),e.delete(i)),r}function H1(e){return e!==null&&typeof e=="object"?e.valueOf():e}const U1=Math.sqrt(50),Y1=Math.sqrt(10),j1=Math.sqrt(2);function Xs(e,t,r){const i=(t-e)/Math.max(0,r),a=Math.floor(Math.log10(i)),s=i/Math.pow(10,a),o=s>=U1?10:s>=Y1?5:s>=j1?2:1;let n,l,h;return a<0?(h=Math.pow(10,-a)/o,n=Math.round(e*h),l=Math.round(t*h),n/h<e&&++n,l/h>t&&--l,h=-h):(h=Math.pow(10,a)*o,n=Math.round(e/h),l=Math.round(t/h),n*h<e&&++n,l*h>t&&--l),l<n&&.5<=r&&r<2?Xs(e,t,r*2):[n,l,h]}function G1(e,t,r){if(t=+t,e=+e,r=+r,!(r>0))return[];if(e===t)return[e];const i=t<e,[a,s,o]=i?Xs(t,e,r):Xs(e,t,r);if(!(s>=a))return[];const n=s-a+1,l=new Array(n);if(i)if(o<0)for(let h=0;h<n;++h)l[h]=(s-h)/-o;else for(let h=0;h<n;++h)l[h]=(s-h)*o;else if(o<0)for(let h=0;h<n;++h)l[h]=(a+h)/-o;else for(let h=0;h<n;++h)l[h]=(a+h)*o;return l}function sl(e,t,r){return t=+t,e=+e,r=+r,Xs(e,t,r)[2]}function ol(e,t,r){t=+t,e=+e,r=+r;const i=t<e,a=i?sl(t,e,r):sl(e,t,r);return(i?-1:1)*(a<0?1/-a:a)}function E$(e,t){let r;if(t===void 0)for(const i of e)i!=null&&(r<i||r===void 0&&i>=i)&&(r=i);else{let i=-1;for(let a of e)(a=t(a,++i,e))!=null&&(r<a||r===void 0&&a>=a)&&(r=a)}return r}function $$(e,t){let r;if(t===void 0)for(const i of e)i!=null&&(r>i||r===void 0&&i>=i)&&(r=i);else{let i=-1;for(let a of e)(a=t(a,++i,e))!=null&&(r>a||r===void 0&&a>=a)&&(r=a)}return r}function X1(e,t,r){e=+e,t=+t,r=(a=arguments.length)<2?(t=e,e=0,1):a<3?1:+r;for(var i=-1,a=Math.max(0,Math.ceil((t-e)/r))|0,s=new Array(a);++i<a;)s[i]=e+i*r;return s}function V1(e){return e}var As=1,Sn=2,nl=3,cs=4,jc=1e-6;function Z1(e){return"translate("+e+",0)"}function Q1(e){return"translate(0,"+e+")"}function K1(e){return t=>+e(t)}function J1(e,t){return t=Math.max(0,e.bandwidth()-t*2)/2,e.round()&&(t=Math.round(t)),r=>+e(r)+t}function tb(){return!this.__axis}function ff(e,t){var r=[],i=null,a=null,s=6,o=6,n=3,l=typeof window<"u"&&window.devicePixelRatio>1?0:.5,h=e===As||e===cs?-1:1,c=e===cs||e===Sn?"x":"y",u=e===As||e===nl?Z1:Q1;function f(d){var p=i??(t.ticks?t.ticks.apply(t,r):t.domain()),g=a??(t.tickFormat?t.tickFormat.apply(t,r):V1),m=Math.max(s,0)+n,C=t.range(),x=+C[0]+l,k=+C[C.length-1]+l,w=(t.bandwidth?J1:K1)(t.copy(),l),S=d.selection?d.selection():d,_=S.selectAll(".domain").data([null]),T=S.selectAll(".tick").data(p,t).order(),B=T.exit(),z=T.enter().append("g").attr("class","tick"),I=T.select("line"),E=T.select("text");_=_.merge(_.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),T=T.merge(z),I=I.merge(z.append("line").attr("stroke","currentColor").attr(c+"2",h*s)),E=E.merge(z.append("text").attr("fill","currentColor").attr(c,h*m).attr("dy",e===As?"0em":e===nl?"0.71em":"0.32em")),d!==S&&(_=_.transition(d),T=T.transition(d),I=I.transition(d),E=E.transition(d),B=B.transition(d).attr("opacity",jc).attr("transform",function(N){return isFinite(N=w(N))?u(N+l):this.getAttribute("transform")}),z.attr("opacity",jc).attr("transform",function(N){var D=this.parentNode.__axis;return u((D&&isFinite(D=D(N))?D:w(N))+l)})),B.remove(),_.attr("d",e===cs||e===Sn?o?"M"+h*o+","+x+"H"+l+"V"+k+"H"+h*o:"M"+l+","+x+"V"+k:o?"M"+x+","+h*o+"V"+l+"H"+k+"V"+h*o:"M"+x+","+l+"H"+k),T.attr("opacity",1).attr("transform",function(N){return u(w(N)+l)}),I.attr(c+"2",h*s),E.attr(c,h*m).text(g),S.filter(tb).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",e===Sn?"start":e===cs?"end":"middle"),S.each(function(){this.__axis=w})}return f.scale=function(d){return arguments.length?(t=d,f):t},f.ticks=function(){return r=Array.from(arguments),f},f.tickArguments=function(d){return arguments.length?(r=d==null?[]:Array.from(d),f):r.slice()},f.tickValues=function(d){return arguments.length?(i=d==null?null:Array.from(d),f):i&&i.slice()},f.tickFormat=function(d){return arguments.length?(a=d,f):a},f.tickSize=function(d){return arguments.length?(s=o=+d,f):s},f.tickSizeInner=function(d){return arguments.length?(s=+d,f):s},f.tickSizeOuter=function(d){return arguments.length?(o=+d,f):o},f.tickPadding=function(d){return arguments.length?(n=+d,f):n},f.offset=function(d){return arguments.length?(l=+d,f):l},f}function D$(e){return ff(As,e)}function O$(e){return ff(nl,e)}var eb={value:()=>{}};function pf(){for(var e=0,t=arguments.length,r={},i;e<t;++e){if(!(i=arguments[e]+"")||i in r||/[\s.]/.test(i))throw new Error("illegal type: "+i);r[i]=[]}return new Es(r)}function Es(e){this._=e}function rb(e,t){return e.trim().split(/^|\s+/).map(function(r){var i="",a=r.indexOf(".");if(a>=0&&(i=r.slice(a+1),r=r.slice(0,a)),r&&!t.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:i}})}Es.prototype=pf.prototype={constructor:Es,on:function(e,t){var r=this._,i=rb(e+"",r),a,s=-1,o=i.length;if(arguments.length<2){for(;++s<o;)if((a=(e=i[s]).type)&&(a=ib(r[a],e.name)))return a;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++s<o;)if(a=(e=i[s]).type)r[a]=Gc(r[a],e.name,t);else if(t==null)for(a in r)r[a]=Gc(r[a],e.name,null);return this},copy:function(){var e={},t=this._;for(var r in t)e[r]=t[r].slice();return new Es(e)},call:function(e,t){if((a=arguments.length-2)>0)for(var r=new Array(a),i=0,a,s;i<a;++i)r[i]=arguments[i+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(s=this._[e],i=0,a=s.length;i<a;++i)s[i].value.apply(t,r)},apply:function(e,t,r){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var i=this._[e],a=0,s=i.length;a<s;++a)i[a].value.apply(t,r)}};function ib(e,t){for(var r=0,i=e.length,a;r<i;++r)if((a=e[r]).name===t)return a.value}function Gc(e,t,r){for(var i=0,a=e.length;i<a;++i)if(e[i].name===t){e[i]=eb,e=e.slice(0,i).concat(e.slice(i+1));break}return r!=null&&e.push({name:t,value:r}),e}var ll="http://www.w3.org/1999/xhtml";const Xc={svg:"http://www.w3.org/2000/svg",xhtml:ll,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Ro(e){var t=e+="",r=t.indexOf(":");return r>=0&&(t=e.slice(0,r))!=="xmlns"&&(e=e.slice(r+1)),Xc.hasOwnProperty(t)?{space:Xc[t],local:e}:e}function ab(e){return function(){var t=this.ownerDocument,r=this.namespaceURI;return r===ll&&t.documentElement.namespaceURI===ll?t.createElement(e):t.createElementNS(r,e)}}function sb(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function gf(e){var t=Ro(e);return(t.local?sb:ab)(t)}function ob(){}function fh(e){return e==null?ob:function(){return this.querySelector(e)}}function nb(e){typeof e!="function"&&(e=fh(e));for(var t=this._groups,r=t.length,i=new Array(r),a=0;a<r;++a)for(var s=t[a],o=s.length,n=i[a]=new Array(o),l,h,c=0;c<o;++c)(l=s[c])&&(h=e.call(l,l.__data__,c,s))&&("__data__"in l&&(h.__data__=l.__data__),n[c]=h);return new ye(i,this._parents)}function lb(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function hb(){return[]}function mf(e){return e==null?hb:function(){return this.querySelectorAll(e)}}function cb(e){return function(){return lb(e.apply(this,arguments))}}function ub(e){typeof e=="function"?e=cb(e):e=mf(e);for(var t=this._groups,r=t.length,i=[],a=[],s=0;s<r;++s)for(var o=t[s],n=o.length,l,h=0;h<n;++h)(l=o[h])&&(i.push(e.call(l,l.__data__,h,o)),a.push(l));return new ye(i,a)}function yf(e){return function(){return this.matches(e)}}function Cf(e){return function(t){return t.matches(e)}}var db=Array.prototype.find;function fb(e){return function(){return db.call(this.children,e)}}function pb(){return this.firstElementChild}function gb(e){return this.select(e==null?pb:fb(typeof e=="function"?e:Cf(e)))}var mb=Array.prototype.filter;function yb(){return Array.from(this.children)}function Cb(e){return function(){return mb.call(this.children,e)}}function xb(e){return this.selectAll(e==null?yb:Cb(typeof e=="function"?e:Cf(e)))}function bb(e){typeof e!="function"&&(e=yf(e));for(var t=this._groups,r=t.length,i=new Array(r),a=0;a<r;++a)for(var s=t[a],o=s.length,n=i[a]=[],l,h=0;h<o;++h)(l=s[h])&&e.call(l,l.__data__,h,s)&&n.push(l);return new ye(i,this._parents)}function xf(e){return new Array(e.length)}function kb(){return new ye(this._enter||this._groups.map(xf),this._parents)}function Vs(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}Vs.prototype={constructor:Vs,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function Tb(e){return function(){return e}}function wb(e,t,r,i,a,s){for(var o=0,n,l=t.length,h=s.length;o<h;++o)(n=t[o])?(n.__data__=s[o],i[o]=n):r[o]=new Vs(e,s[o]);for(;o<l;++o)(n=t[o])&&(a[o]=n)}function _b(e,t,r,i,a,s,o){var n,l,h=new Map,c=t.length,u=s.length,f=new Array(c),d;for(n=0;n<c;++n)(l=t[n])&&(f[n]=d=o.call(l,l.__data__,n,t)+"",h.has(d)?a[n]=l:h.set(d,l));for(n=0;n<u;++n)d=o.call(e,s[n],n,s)+"",(l=h.get(d))?(i[n]=l,l.__data__=s[n],h.delete(d)):r[n]=new Vs(e,s[n]);for(n=0;n<c;++n)(l=t[n])&&h.get(f[n])===l&&(a[n]=l)}function Sb(e){return e.__data__}function vb(e,t){if(!arguments.length)return Array.from(this,Sb);var r=t?_b:wb,i=this._parents,a=this._groups;typeof e!="function"&&(e=Tb(e));for(var s=a.length,o=new Array(s),n=new Array(s),l=new Array(s),h=0;h<s;++h){var c=i[h],u=a[h],f=u.length,d=Bb(e.call(c,c&&c.__data__,h,i)),p=d.length,g=n[h]=new Array(p),m=o[h]=new Array(p),C=l[h]=new Array(f);r(c,u,g,m,C,d,t);for(var x=0,k=0,w,S;x<p;++x)if(w=g[x]){for(x>=k&&(k=x+1);!(S=m[k])&&++k<p;);w._next=S||null}}return o=new ye(o,i),o._enter=n,o._exit=l,o}function Bb(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function Lb(){return new ye(this._exit||this._groups.map(xf),this._parents)}function Fb(e,t,r){var i=this.enter(),a=this,s=this.exit();return typeof e=="function"?(i=e(i),i&&(i=i.selection())):i=i.append(e+""),t!=null&&(a=t(a),a&&(a=a.selection())),r==null?s.remove():r(s),i&&a?i.merge(a).order():a}function Mb(e){for(var t=e.selection?e.selection():e,r=this._groups,i=t._groups,a=r.length,s=i.length,o=Math.min(a,s),n=new Array(a),l=0;l<o;++l)for(var h=r[l],c=i[l],u=h.length,f=n[l]=new Array(u),d,p=0;p<u;++p)(d=h[p]||c[p])&&(f[p]=d);for(;l<a;++l)n[l]=r[l];return new ye(n,this._parents)}function Ab(){for(var e=this._groups,t=-1,r=e.length;++t<r;)for(var i=e[t],a=i.length-1,s=i[a],o;--a>=0;)(o=i[a])&&(s&&o.compareDocumentPosition(s)^4&&s.parentNode.insertBefore(o,s),s=o);return this}function Eb(e){e||(e=$b);function t(u,f){return u&&f?e(u.__data__,f.__data__):!u-!f}for(var r=this._groups,i=r.length,a=new Array(i),s=0;s<i;++s){for(var o=r[s],n=o.length,l=a[s]=new Array(n),h,c=0;c<n;++c)(h=o[c])&&(l[c]=h);l.sort(t)}return new ye(a,this._parents).order()}function $b(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function Db(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function Ob(){return Array.from(this)}function Ib(){for(var e=this._groups,t=0,r=e.length;t<r;++t)for(var i=e[t],a=0,s=i.length;a<s;++a){var o=i[a];if(o)return o}return null}function Pb(){let e=0;for(const t of this)++e;return e}function Rb(){return!this.node()}function Nb(e){for(var t=this._groups,r=0,i=t.length;r<i;++r)for(var a=t[r],s=0,o=a.length,n;s<o;++s)(n=a[s])&&e.call(n,n.__data__,s,a);return this}function qb(e){return function(){this.removeAttribute(e)}}function zb(e){return function(){this.removeAttributeNS(e.space,e.local)}}function Wb(e,t){return function(){this.setAttribute(e,t)}}function Hb(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function Ub(e,t){return function(){var r=t.apply(this,arguments);r==null?this.removeAttribute(e):this.setAttribute(e,r)}}function Yb(e,t){return function(){var r=t.apply(this,arguments);r==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,r)}}function jb(e,t){var r=Ro(e);if(arguments.length<2){var i=this.node();return r.local?i.getAttributeNS(r.space,r.local):i.getAttribute(r)}return this.each((t==null?r.local?zb:qb:typeof t=="function"?r.local?Yb:Ub:r.local?Hb:Wb)(r,t))}function bf(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function Gb(e){return function(){this.style.removeProperty(e)}}function Xb(e,t,r){return function(){this.style.setProperty(e,t,r)}}function Vb(e,t,r){return function(){var i=t.apply(this,arguments);i==null?this.style.removeProperty(e):this.style.setProperty(e,i,r)}}function Zb(e,t,r){return arguments.length>1?this.each((t==null?Gb:typeof t=="function"?Vb:Xb)(e,t,r??"")):Oi(this.node(),e)}function Oi(e,t){return e.style.getPropertyValue(t)||bf(e).getComputedStyle(e,null).getPropertyValue(t)}function Qb(e){return function(){delete this[e]}}function Kb(e,t){return function(){this[e]=t}}function Jb(e,t){return function(){var r=t.apply(this,arguments);r==null?delete this[e]:this[e]=r}}function tk(e,t){return arguments.length>1?this.each((t==null?Qb:typeof t=="function"?Jb:Kb)(e,t)):this.node()[e]}function kf(e){return e.trim().split(/^|\s+/)}function ph(e){return e.classList||new Tf(e)}function Tf(e){this._node=e,this._names=kf(e.getAttribute("class")||"")}Tf.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function wf(e,t){for(var r=ph(e),i=-1,a=t.length;++i<a;)r.add(t[i])}function _f(e,t){for(var r=ph(e),i=-1,a=t.length;++i<a;)r.remove(t[i])}function ek(e){return function(){wf(this,e)}}function rk(e){return function(){_f(this,e)}}function ik(e,t){return function(){(t.apply(this,arguments)?wf:_f)(this,e)}}function ak(e,t){var r=kf(e+"");if(arguments.length<2){for(var i=ph(this.node()),a=-1,s=r.length;++a<s;)if(!i.contains(r[a]))return!1;return!0}return this.each((typeof t=="function"?ik:t?ek:rk)(r,t))}function sk(){this.textContent=""}function ok(e){return function(){this.textContent=e}}function nk(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function lk(e){return arguments.length?this.each(e==null?sk:(typeof e=="function"?nk:ok)(e)):this.node().textContent}function hk(){this.innerHTML=""}function ck(e){return function(){this.innerHTML=e}}function uk(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function dk(e){return arguments.length?this.each(e==null?hk:(typeof e=="function"?uk:ck)(e)):this.node().innerHTML}function fk(){this.nextSibling&&this.parentNode.appendChild(this)}function pk(){return this.each(fk)}function gk(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function mk(){return this.each(gk)}function yk(e){var t=typeof e=="function"?e:gf(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function Ck(){return null}function xk(e,t){var r=typeof e=="function"?e:gf(e),i=t==null?Ck:typeof t=="function"?t:fh(t);return this.select(function(){return this.insertBefore(r.apply(this,arguments),i.apply(this,arguments)||null)})}function bk(){var e=this.parentNode;e&&e.removeChild(this)}function kk(){return this.each(bk)}function Tk(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function wk(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function _k(e){return this.select(e?wk:Tk)}function Sk(e){return arguments.length?this.property("__data__",e):this.node().__data__}function vk(e){return function(t){e.call(this,t,this.__data__)}}function Bk(e){return e.trim().split(/^|\s+/).map(function(t){var r="",i=t.indexOf(".");return i>=0&&(r=t.slice(i+1),t=t.slice(0,i)),{type:t,name:r}})}function Lk(e){return function(){var t=this.__on;if(t){for(var r=0,i=-1,a=t.length,s;r<a;++r)s=t[r],(!e.type||s.type===e.type)&&s.name===e.name?this.removeEventListener(s.type,s.listener,s.options):t[++i]=s;++i?t.length=i:delete this.__on}}}function Fk(e,t,r){return function(){var i=this.__on,a,s=vk(t);if(i){for(var o=0,n=i.length;o<n;++o)if((a=i[o]).type===e.type&&a.name===e.name){this.removeEventListener(a.type,a.listener,a.options),this.addEventListener(a.type,a.listener=s,a.options=r),a.value=t;return}}this.addEventListener(e.type,s,r),a={type:e.type,name:e.name,value:t,listener:s,options:r},i?i.push(a):this.__on=[a]}}function Mk(e,t,r){var i=Bk(e+""),a,s=i.length,o;if(arguments.length<2){var n=this.node().__on;if(n){for(var l=0,h=n.length,c;l<h;++l)for(a=0,c=n[l];a<s;++a)if((o=i[a]).type===c.type&&o.name===c.name)return c.value}return}for(n=t?Fk:Lk,a=0;a<s;++a)this.each(n(i[a],t,r));return this}function Sf(e,t,r){var i=bf(e),a=i.CustomEvent;typeof a=="function"?a=new a(t,r):(a=i.document.createEvent("Event"),r?(a.initEvent(t,r.bubbles,r.cancelable),a.detail=r.detail):a.initEvent(t,!1,!1)),e.dispatchEvent(a)}function Ak(e,t){return function(){return Sf(this,e,t)}}function Ek(e,t){return function(){return Sf(this,e,t.apply(this,arguments))}}function $k(e,t){return this.each((typeof t=="function"?Ek:Ak)(e,t))}function*Dk(){for(var e=this._groups,t=0,r=e.length;t<r;++t)for(var i=e[t],a=0,s=i.length,o;a<s;++a)(o=i[a])&&(yield o)}var vf=[null];function ye(e,t){this._groups=e,this._parents=t}function ja(){return new ye([[document.documentElement]],vf)}function Ok(){return this}ye.prototype=ja.prototype={constructor:ye,select:nb,selectAll:ub,selectChild:gb,selectChildren:xb,filter:bb,data:vb,enter:kb,exit:Lb,join:Fb,merge:Mb,selection:Ok,order:Ab,sort:Eb,call:Db,nodes:Ob,node:Ib,size:Pb,empty:Rb,each:Nb,attr:jb,style:Zb,property:tk,classed:ak,text:lk,html:dk,raise:pk,lower:mk,append:yk,insert:xk,remove:kk,clone:_k,datum:Sk,on:Mk,dispatch:$k,[Symbol.iterator]:Dk};function pt(e){return typeof e=="string"?new ye([[document.querySelector(e)]],[document.documentElement]):new ye([[e]],vf)}function Ga(e,t,r){e.prototype=t.prototype=r,r.constructor=e}function No(e,t){var r=Object.create(e.prototype);for(var i in t)r[i]=t[i];return r}function Xr(){}var Aa=.7,Zs=1/Aa,mi="\\s*([+-]?\\d+)\\s*",Ea="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",ze="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Ik=/^#([0-9a-f]{3,8})$/,Pk=new RegExp(`^rgb\\(${mi},${mi},${mi}\\)$`),Rk=new RegExp(`^rgb\\(${ze},${ze},${ze}\\)$`),Nk=new RegExp(`^rgba\\(${mi},${mi},${mi},${Ea}\\)$`),qk=new RegExp(`^rgba\\(${ze},${ze},${ze},${Ea}\\)$`),zk=new RegExp(`^hsl\\(${Ea},${ze},${ze}\\)$`),Wk=new RegExp(`^hsla\\(${Ea},${ze},${ze},${Ea}\\)$`),Vc={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Ga(Xr,qr,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Zc,formatHex:Zc,formatHex8:Hk,formatHsl:Uk,formatRgb:Qc,toString:Qc});function Zc(){return this.rgb().formatHex()}function Hk(){return this.rgb().formatHex8()}function Uk(){return Lf(this).formatHsl()}function Qc(){return this.rgb().formatRgb()}function qr(e){var t,r;return e=(e+"").trim().toLowerCase(),(t=Ik.exec(e))?(r=t[1].length,t=parseInt(t[1],16),r===6?Kc(t):r===3?new Jt(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):r===8?us(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):r===4?us(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=Pk.exec(e))?new Jt(t[1],t[2],t[3],1):(t=Rk.exec(e))?new Jt(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=Nk.exec(e))?us(t[1],t[2],t[3],t[4]):(t=qk.exec(e))?us(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=zk.exec(e))?eu(t[1],t[2]/100,t[3]/100,1):(t=Wk.exec(e))?eu(t[1],t[2]/100,t[3]/100,t[4]):Vc.hasOwnProperty(e)?Kc(Vc[e]):e==="transparent"?new Jt(NaN,NaN,NaN,0):null}function Kc(e){return new Jt(e>>16&255,e>>8&255,e&255,1)}function us(e,t,r,i){return i<=0&&(e=t=r=NaN),new Jt(e,t,r,i)}function Bf(e){return e instanceof Xr||(e=qr(e)),e?(e=e.rgb(),new Jt(e.r,e.g,e.b,e.opacity)):new Jt}function hl(e,t,r,i){return arguments.length===1?Bf(e):new Jt(e,t,r,i??1)}function Jt(e,t,r,i){this.r=+e,this.g=+t,this.b=+r,this.opacity=+i}Ga(Jt,hl,No(Xr,{brighter(e){return e=e==null?Zs:Math.pow(Zs,e),new Jt(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Aa:Math.pow(Aa,e),new Jt(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Jt(Ir(this.r),Ir(this.g),Ir(this.b),Qs(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Jc,formatHex:Jc,formatHex8:Yk,formatRgb:tu,toString:tu}));function Jc(){return`#${$r(this.r)}${$r(this.g)}${$r(this.b)}`}function Yk(){return`#${$r(this.r)}${$r(this.g)}${$r(this.b)}${$r((isNaN(this.opacity)?1:this.opacity)*255)}`}function tu(){const e=Qs(this.opacity);return`${e===1?"rgb(":"rgba("}${Ir(this.r)}, ${Ir(this.g)}, ${Ir(this.b)}${e===1?")":`, ${e})`}`}function Qs(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Ir(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function $r(e){return e=Ir(e),(e<16?"0":"")+e.toString(16)}function eu(e,t,r,i){return i<=0?e=t=r=NaN:r<=0||r>=1?e=t=NaN:t<=0&&(e=NaN),new ve(e,t,r,i)}function Lf(e){if(e instanceof ve)return new ve(e.h,e.s,e.l,e.opacity);if(e instanceof Xr||(e=qr(e)),!e)return new ve;if(e instanceof ve)return e;e=e.rgb();var t=e.r/255,r=e.g/255,i=e.b/255,a=Math.min(t,r,i),s=Math.max(t,r,i),o=NaN,n=s-a,l=(s+a)/2;return n?(t===s?o=(r-i)/n+(r<i)*6:r===s?o=(i-t)/n+2:o=(t-r)/n+4,n/=l<.5?s+a:2-s-a,o*=60):n=l>0&&l<1?0:o,new ve(o,n,l,e.opacity)}function jk(e,t,r,i){return arguments.length===1?Lf(e):new ve(e,t,r,i??1)}function ve(e,t,r,i){this.h=+e,this.s=+t,this.l=+r,this.opacity=+i}Ga(ve,jk,No(Xr,{brighter(e){return e=e==null?Zs:Math.pow(Zs,e),new ve(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Aa:Math.pow(Aa,e),new ve(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,r=this.l,i=r+(r<.5?r:1-r)*t,a=2*r-i;return new Jt(vn(e>=240?e-240:e+120,a,i),vn(e,a,i),vn(e<120?e+240:e-120,a,i),this.opacity)},clamp(){return new ve(ru(this.h),ds(this.s),ds(this.l),Qs(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Qs(this.opacity);return`${e===1?"hsl(":"hsla("}${ru(this.h)}, ${ds(this.s)*100}%, ${ds(this.l)*100}%${e===1?")":`, ${e})`}`}}));function ru(e){return e=(e||0)%360,e<0?e+360:e}function ds(e){return Math.max(0,Math.min(1,e||0))}function vn(e,t,r){return(e<60?t+(r-t)*e/60:e<180?r:e<240?t+(r-t)*(240-e)/60:t)*255}const Gk=Math.PI/180,Xk=180/Math.PI,Ks=18,Ff=.96422,Mf=1,Af=.82521,Ef=4/29,yi=6/29,$f=3*yi*yi,Vk=yi*yi*yi;function Df(e){if(e instanceof We)return new We(e.l,e.a,e.b,e.opacity);if(e instanceof er)return Of(e);e instanceof Jt||(e=Bf(e));var t=Mn(e.r),r=Mn(e.g),i=Mn(e.b),a=Bn((.2225045*t+.7168786*r+.0606169*i)/Mf),s,o;return t===r&&r===i?s=o=a:(s=Bn((.4360747*t+.3850649*r+.1430804*i)/Ff),o=Bn((.0139322*t+.0971045*r+.7141733*i)/Af)),new We(116*a-16,500*(s-a),200*(a-o),e.opacity)}function Zk(e,t,r,i){return arguments.length===1?Df(e):new We(e,t,r,i??1)}function We(e,t,r,i){this.l=+e,this.a=+t,this.b=+r,this.opacity=+i}Ga(We,Zk,No(Xr,{brighter(e){return new We(this.l+Ks*(e??1),this.a,this.b,this.opacity)},darker(e){return new We(this.l-Ks*(e??1),this.a,this.b,this.opacity)},rgb(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,r=isNaN(this.b)?e:e-this.b/200;return t=Ff*Ln(t),e=Mf*Ln(e),r=Af*Ln(r),new Jt(Fn(3.1338561*t-1.6168667*e-.4906146*r),Fn(-.9787684*t+1.9161415*e+.033454*r),Fn(.0719453*t-.2289914*e+1.4052427*r),this.opacity)}}));function Bn(e){return e>Vk?Math.pow(e,1/3):e/$f+Ef}function Ln(e){return e>yi?e*e*e:$f*(e-Ef)}function Fn(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function Mn(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function Qk(e){if(e instanceof er)return new er(e.h,e.c,e.l,e.opacity);if(e instanceof We||(e=Df(e)),e.a===0&&e.b===0)return new er(NaN,0<e.l&&e.l<100?0:NaN,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*Xk;return new er(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}function cl(e,t,r,i){return arguments.length===1?Qk(e):new er(e,t,r,i??1)}function er(e,t,r,i){this.h=+e,this.c=+t,this.l=+r,this.opacity=+i}function Of(e){if(isNaN(e.h))return new We(e.l,0,0,e.opacity);var t=e.h*Gk;return new We(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}Ga(er,cl,No(Xr,{brighter(e){return new er(this.h,this.c,this.l+Ks*(e??1),this.opacity)},darker(e){return new er(this.h,this.c,this.l-Ks*(e??1),this.opacity)},rgb(){return Of(this).rgb()}}));const qo=e=>()=>e;function If(e,t){return function(r){return e+r*t}}function Kk(e,t,r){return e=Math.pow(e,r),t=Math.pow(t,r)-e,r=1/r,function(i){return Math.pow(e+i*t,r)}}function Jk(e,t){var r=t-e;return r?If(e,r>180||r<-180?r-360*Math.round(r/360):r):qo(isNaN(e)?t:e)}function t2(e){return(e=+e)==1?va:function(t,r){return r-t?Kk(t,r,e):qo(isNaN(t)?r:t)}}function va(e,t){var r=t-e;return r?If(e,r):qo(isNaN(e)?t:e)}const Js=(function e(t){var r=t2(t);function i(a,s){var o=r((a=hl(a)).r,(s=hl(s)).r),n=r(a.g,s.g),l=r(a.b,s.b),h=va(a.opacity,s.opacity);return function(c){return a.r=o(c),a.g=n(c),a.b=l(c),a.opacity=h(c),a+""}}return i.gamma=e,i})(1);function e2(e,t){t||(t=[]);var r=e?Math.min(t.length,e.length):0,i=t.slice(),a;return function(s){for(a=0;a<r;++a)i[a]=e[a]*(1-s)+t[a]*s;return i}}function r2(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function i2(e,t){var r=t?t.length:0,i=e?Math.min(r,e.length):0,a=new Array(i),s=new Array(r),o;for(o=0;o<i;++o)a[o]=gh(e[o],t[o]);for(;o<r;++o)s[o]=t[o];return function(n){for(o=0;o<i;++o)s[o]=a[o](n);return s}}function a2(e,t){var r=new Date;return e=+e,t=+t,function(i){return r.setTime(e*(1-i)+t*i),r}}function we(e,t){return e=+e,t=+t,function(r){return e*(1-r)+t*r}}function s2(e,t){var r={},i={},a;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(a in t)a in e?r[a]=gh(e[a],t[a]):i[a]=t[a];return function(s){for(a in r)i[a]=r[a](s);return i}}var ul=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,An=new RegExp(ul.source,"g");function o2(e){return function(){return e}}function n2(e){return function(t){return e(t)+""}}function Pf(e,t){var r=ul.lastIndex=An.lastIndex=0,i,a,s,o=-1,n=[],l=[];for(e=e+"",t=t+"";(i=ul.exec(e))&&(a=An.exec(t));)(s=a.index)>r&&(s=t.slice(r,s),n[o]?n[o]+=s:n[++o]=s),(i=i[0])===(a=a[0])?n[o]?n[o]+=a:n[++o]=a:(n[++o]=null,l.push({i:o,x:we(i,a)})),r=An.lastIndex;return r<t.length&&(s=t.slice(r),n[o]?n[o]+=s:n[++o]=s),n.length<2?l[0]?n2(l[0].x):o2(t):(t=l.length,function(h){for(var c=0,u;c<t;++c)n[(u=l[c]).i]=u.x(h);return n.join("")})}function gh(e,t){var r=typeof t,i;return t==null||r==="boolean"?qo(t):(r==="number"?we:r==="string"?(i=qr(t))?(t=i,Js):Pf:t instanceof qr?Js:t instanceof Date?a2:r2(t)?e2:Array.isArray(t)?i2:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?s2:we)(e,t)}function l2(e,t){return e=+e,t=+t,function(r){return Math.round(e*(1-r)+t*r)}}var iu=180/Math.PI,dl={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Rf(e,t,r,i,a,s){var o,n,l;return(o=Math.sqrt(e*e+t*t))&&(e/=o,t/=o),(l=e*r+t*i)&&(r-=e*l,i-=t*l),(n=Math.sqrt(r*r+i*i))&&(r/=n,i/=n,l/=n),e*i<t*r&&(e=-e,t=-t,l=-l,o=-o),{translateX:a,translateY:s,rotate:Math.atan2(t,e)*iu,skewX:Math.atan(l)*iu,scaleX:o,scaleY:n}}var fs;function h2(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?dl:Rf(t.a,t.b,t.c,t.d,t.e,t.f)}function c2(e){return e==null||(fs||(fs=document.createElementNS("http://www.w3.org/2000/svg","g")),fs.setAttribute("transform",e),!(e=fs.transform.baseVal.consolidate()))?dl:(e=e.matrix,Rf(e.a,e.b,e.c,e.d,e.e,e.f))}function Nf(e,t,r,i){function a(h){return h.length?h.pop()+" ":""}function s(h,c,u,f,d,p){if(h!==u||c!==f){var g=d.push("translate(",null,t,null,r);p.push({i:g-4,x:we(h,u)},{i:g-2,x:we(c,f)})}else(u||f)&&d.push("translate("+u+t+f+r)}function o(h,c,u,f){h!==c?(h-c>180?c+=360:c-h>180&&(h+=360),f.push({i:u.push(a(u)+"rotate(",null,i)-2,x:we(h,c)})):c&&u.push(a(u)+"rotate("+c+i)}function n(h,c,u,f){h!==c?f.push({i:u.push(a(u)+"skewX(",null,i)-2,x:we(h,c)}):c&&u.push(a(u)+"skewX("+c+i)}function l(h,c,u,f,d,p){if(h!==u||c!==f){var g=d.push(a(d)+"scale(",null,",",null,")");p.push({i:g-4,x:we(h,u)},{i:g-2,x:we(c,f)})}else(u!==1||f!==1)&&d.push(a(d)+"scale("+u+","+f+")")}return function(h,c){var u=[],f=[];return h=e(h),c=e(c),s(h.translateX,h.translateY,c.translateX,c.translateY,u,f),o(h.rotate,c.rotate,u,f),n(h.skewX,c.skewX,u,f),l(h.scaleX,h.scaleY,c.scaleX,c.scaleY,u,f),h=c=null,function(d){for(var p=-1,g=f.length,m;++p<g;)u[(m=f[p]).i]=m.x(d);return u.join("")}}}var u2=Nf(h2,"px, ","px)","deg)"),d2=Nf(c2,", ",")",")");function f2(e){return function(t,r){var i=e((t=cl(t)).h,(r=cl(r)).h),a=va(t.c,r.c),s=va(t.l,r.l),o=va(t.opacity,r.opacity);return function(n){return t.h=i(n),t.c=a(n),t.l=s(n),t.opacity=o(n),t+""}}}const I$=f2(Jk);var Ii=0,ma=0,ra=0,qf=1e3,to,ya,eo=0,zr=0,zo=0,$a=typeof performance=="object"&&performance.now?performance:Date,zf=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function mh(){return zr||(zf(p2),zr=$a.now()+zo)}function p2(){zr=0}function ro(){this._call=this._time=this._next=null}ro.prototype=Wf.prototype={constructor:ro,restart:function(e,t,r){if(typeof e!="function")throw new TypeError("callback is not a function");r=(r==null?mh():+r)+(t==null?0:+t),!this._next&&ya!==this&&(ya?ya._next=this:to=this,ya=this),this._call=e,this._time=r,fl()},stop:function(){this._call&&(this._call=null,this._time=1/0,fl())}};function Wf(e,t,r){var i=new ro;return i.restart(e,t,r),i}function g2(){mh(),++Ii;for(var e=to,t;e;)(t=zr-e._time)>=0&&e._call.call(void 0,t),e=e._next;--Ii}function au(){zr=(eo=$a.now())+zo,Ii=ma=0;try{g2()}finally{Ii=0,y2(),zr=0}}function m2(){var e=$a.now(),t=e-eo;t>qf&&(zo-=t,eo=e)}function y2(){for(var e,t=to,r,i=1/0;t;)t._call?(i>t._time&&(i=t._time),e=t,t=t._next):(r=t._next,t._next=null,t=e?e._next=r:to=r);ya=e,fl(i)}function fl(e){if(!Ii){ma&&(ma=clearTimeout(ma));var t=e-zr;t>24?(e<1/0&&(ma=setTimeout(au,e-$a.now()-zo)),ra&&(ra=clearInterval(ra))):(ra||(eo=$a.now(),ra=setInterval(m2,qf)),Ii=1,zf(au))}}function su(e,t,r){var i=new ro;return t=t==null?0:+t,i.restart(a=>{i.stop(),e(a+t)},t,r),i}var C2=pf("start","end","cancel","interrupt"),x2=[],Hf=0,ou=1,pl=2,$s=3,nu=4,gl=5,Ds=6;function Wo(e,t,r,i,a,s){var o=e.__transition;if(!o)e.__transition={};else if(r in o)return;b2(e,r,{name:t,index:i,group:a,on:C2,tween:x2,time:s.time,delay:s.delay,duration:s.duration,ease:s.ease,timer:null,state:Hf})}function yh(e,t){var r=$e(e,t);if(r.state>Hf)throw new Error("too late; already scheduled");return r}function je(e,t){var r=$e(e,t);if(r.state>$s)throw new Error("too late; already running");return r}function $e(e,t){var r=e.__transition;if(!r||!(r=r[t]))throw new Error("transition not found");return r}function b2(e,t,r){var i=e.__transition,a;i[t]=r,r.timer=Wf(s,0,r.time);function s(h){r.state=ou,r.timer.restart(o,r.delay,r.time),r.delay<=h&&o(h-r.delay)}function o(h){var c,u,f,d;if(r.state!==ou)return l();for(c in i)if(d=i[c],d.name===r.name){if(d.state===$s)return su(o);d.state===nu?(d.state=Ds,d.timer.stop(),d.on.call("interrupt",e,e.__data__,d.index,d.group),delete i[c]):+c<t&&(d.state=Ds,d.timer.stop(),d.on.call("cancel",e,e.__data__,d.index,d.group),delete i[c])}if(su(function(){r.state===$s&&(r.state=nu,r.timer.restart(n,r.delay,r.time),n(h))}),r.state=pl,r.on.call("start",e,e.__data__,r.index,r.group),r.state===pl){for(r.state=$s,a=new Array(f=r.tween.length),c=0,u=-1;c<f;++c)(d=r.tween[c].value.call(e,e.__data__,r.index,r.group))&&(a[++u]=d);a.length=u+1}}function n(h){for(var c=h<r.duration?r.ease.call(null,h/r.duration):(r.timer.restart(l),r.state=gl,1),u=-1,f=a.length;++u<f;)a[u].call(e,c);r.state===gl&&(r.on.call("end",e,e.__data__,r.index,r.group),l())}function l(){r.state=Ds,r.timer.stop(),delete i[t];for(var h in i)return;delete e.__transition}}function k2(e,t){var r=e.__transition,i,a,s=!0,o;if(r){t=t==null?null:t+"";for(o in r){if((i=r[o]).name!==t){s=!1;continue}a=i.state>pl&&i.state<gl,i.state=Ds,i.timer.stop(),i.on.call(a?"interrupt":"cancel",e,e.__data__,i.index,i.group),delete r[o]}s&&delete e.__transition}}function T2(e){return this.each(function(){k2(this,e)})}function w2(e,t){var r,i;return function(){var a=je(this,e),s=a.tween;if(s!==r){i=r=s;for(var o=0,n=i.length;o<n;++o)if(i[o].name===t){i=i.slice(),i.splice(o,1);break}}a.tween=i}}function _2(e,t,r){var i,a;if(typeof r!="function")throw new Error;return function(){var s=je(this,e),o=s.tween;if(o!==i){a=(i=o).slice();for(var n={name:t,value:r},l=0,h=a.length;l<h;++l)if(a[l].name===t){a[l]=n;break}l===h&&a.push(n)}s.tween=a}}function S2(e,t){var r=this._id;if(e+="",arguments.length<2){for(var i=$e(this.node(),r).tween,a=0,s=i.length,o;a<s;++a)if((o=i[a]).name===e)return o.value;return null}return this.each((t==null?w2:_2)(r,e,t))}function Ch(e,t,r){var i=e._id;return e.each(function(){var a=je(this,i);(a.value||(a.value={}))[t]=r.apply(this,arguments)}),function(a){return $e(a,i).value[t]}}function Uf(e,t){var r;return(typeof t=="number"?we:t instanceof qr?Js:(r=qr(t))?(t=r,Js):Pf)(e,t)}function v2(e){return function(){this.removeAttribute(e)}}function B2(e){return function(){this.removeAttributeNS(e.space,e.local)}}function L2(e,t,r){var i,a=r+"",s;return function(){var o=this.getAttribute(e);return o===a?null:o===i?s:s=t(i=o,r)}}function F2(e,t,r){var i,a=r+"",s;return function(){var o=this.getAttributeNS(e.space,e.local);return o===a?null:o===i?s:s=t(i=o,r)}}function M2(e,t,r){var i,a,s;return function(){var o,n=r(this),l;return n==null?void this.removeAttribute(e):(o=this.getAttribute(e),l=n+"",o===l?null:o===i&&l===a?s:(a=l,s=t(i=o,n)))}}function A2(e,t,r){var i,a,s;return function(){var o,n=r(this),l;return n==null?void this.removeAttributeNS(e.space,e.local):(o=this.getAttributeNS(e.space,e.local),l=n+"",o===l?null:o===i&&l===a?s:(a=l,s=t(i=o,n)))}}function E2(e,t){var r=Ro(e),i=r==="transform"?d2:Uf;return this.attrTween(e,typeof t=="function"?(r.local?A2:M2)(r,i,Ch(this,"attr."+e,t)):t==null?(r.local?B2:v2)(r):(r.local?F2:L2)(r,i,t))}function $2(e,t){return function(r){this.setAttribute(e,t.call(this,r))}}function D2(e,t){return function(r){this.setAttributeNS(e.space,e.local,t.call(this,r))}}function O2(e,t){var r,i;function a(){var s=t.apply(this,arguments);return s!==i&&(r=(i=s)&&D2(e,s)),r}return a._value=t,a}function I2(e,t){var r,i;function a(){var s=t.apply(this,arguments);return s!==i&&(r=(i=s)&&$2(e,s)),r}return a._value=t,a}function P2(e,t){var r="attr."+e;if(arguments.length<2)return(r=this.tween(r))&&r._value;if(t==null)return this.tween(r,null);if(typeof t!="function")throw new Error;var i=Ro(e);return this.tween(r,(i.local?O2:I2)(i,t))}function R2(e,t){return function(){yh(this,e).delay=+t.apply(this,arguments)}}function N2(e,t){return t=+t,function(){yh(this,e).delay=t}}function q2(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?R2:N2)(t,e)):$e(this.node(),t).delay}function z2(e,t){return function(){je(this,e).duration=+t.apply(this,arguments)}}function W2(e,t){return t=+t,function(){je(this,e).duration=t}}function H2(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?z2:W2)(t,e)):$e(this.node(),t).duration}function U2(e,t){if(typeof t!="function")throw new Error;return function(){je(this,e).ease=t}}function Y2(e){var t=this._id;return arguments.length?this.each(U2(t,e)):$e(this.node(),t).ease}function j2(e,t){return function(){var r=t.apply(this,arguments);if(typeof r!="function")throw new Error;je(this,e).ease=r}}function G2(e){if(typeof e!="function")throw new Error;return this.each(j2(this._id,e))}function X2(e){typeof e!="function"&&(e=yf(e));for(var t=this._groups,r=t.length,i=new Array(r),a=0;a<r;++a)for(var s=t[a],o=s.length,n=i[a]=[],l,h=0;h<o;++h)(l=s[h])&&e.call(l,l.__data__,h,s)&&n.push(l);return new or(i,this._parents,this._name,this._id)}function V2(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,r=e._groups,i=t.length,a=r.length,s=Math.min(i,a),o=new Array(i),n=0;n<s;++n)for(var l=t[n],h=r[n],c=l.length,u=o[n]=new Array(c),f,d=0;d<c;++d)(f=l[d]||h[d])&&(u[d]=f);for(;n<i;++n)o[n]=t[n];return new or(o,this._parents,this._name,this._id)}function Z2(e){return(e+"").trim().split(/^|\s+/).every(function(t){var r=t.indexOf(".");return r>=0&&(t=t.slice(0,r)),!t||t==="start"})}function Q2(e,t,r){var i,a,s=Z2(t)?yh:je;return function(){var o=s(this,e),n=o.on;n!==i&&(a=(i=n).copy()).on(t,r),o.on=a}}function K2(e,t){var r=this._id;return arguments.length<2?$e(this.node(),r).on.on(e):this.each(Q2(r,e,t))}function J2(e){return function(){var t=this.parentNode;for(var r in this.__transition)if(+r!==e)return;t&&t.removeChild(this)}}function tT(){return this.on("end.remove",J2(this._id))}function eT(e){var t=this._name,r=this._id;typeof e!="function"&&(e=fh(e));for(var i=this._groups,a=i.length,s=new Array(a),o=0;o<a;++o)for(var n=i[o],l=n.length,h=s[o]=new Array(l),c,u,f=0;f<l;++f)(c=n[f])&&(u=e.call(c,c.__data__,f,n))&&("__data__"in c&&(u.__data__=c.__data__),h[f]=u,Wo(h[f],t,r,f,h,$e(c,r)));return new or(s,this._parents,t,r)}function rT(e){var t=this._name,r=this._id;typeof e!="function"&&(e=mf(e));for(var i=this._groups,a=i.length,s=[],o=[],n=0;n<a;++n)for(var l=i[n],h=l.length,c,u=0;u<h;++u)if(c=l[u]){for(var f=e.call(c,c.__data__,u,l),d,p=$e(c,r),g=0,m=f.length;g<m;++g)(d=f[g])&&Wo(d,t,r,g,f,p);s.push(f),o.push(c)}return new or(s,o,t,r)}var iT=ja.prototype.constructor;function aT(){return new iT(this._groups,this._parents)}function sT(e,t){var r,i,a;return function(){var s=Oi(this,e),o=(this.style.removeProperty(e),Oi(this,e));return s===o?null:s===r&&o===i?a:a=t(r=s,i=o)}}function Yf(e){return function(){this.style.removeProperty(e)}}function oT(e,t,r){var i,a=r+"",s;return function(){var o=Oi(this,e);return o===a?null:o===i?s:s=t(i=o,r)}}function nT(e,t,r){var i,a,s;return function(){var o=Oi(this,e),n=r(this),l=n+"";return n==null&&(l=n=(this.style.removeProperty(e),Oi(this,e))),o===l?null:o===i&&l===a?s:(a=l,s=t(i=o,n))}}function lT(e,t){var r,i,a,s="style."+t,o="end."+s,n;return function(){var l=je(this,e),h=l.on,c=l.value[s]==null?n||(n=Yf(t)):void 0;(h!==r||a!==c)&&(i=(r=h).copy()).on(o,a=c),l.on=i}}function hT(e,t,r){var i=(e+="")=="transform"?u2:Uf;return t==null?this.styleTween(e,sT(e,i)).on("end.style."+e,Yf(e)):typeof t=="function"?this.styleTween(e,nT(e,i,Ch(this,"style."+e,t))).each(lT(this._id,e)):this.styleTween(e,oT(e,i,t),r).on("end.style."+e,null)}function cT(e,t,r){return function(i){this.style.setProperty(e,t.call(this,i),r)}}function uT(e,t,r){var i,a;function s(){var o=t.apply(this,arguments);return o!==a&&(i=(a=o)&&cT(e,o,r)),i}return s._value=t,s}function dT(e,t,r){var i="style."+(e+="");if(arguments.length<2)return(i=this.tween(i))&&i._value;if(t==null)return this.tween(i,null);if(typeof t!="function")throw new Error;return this.tween(i,uT(e,t,r??""))}function fT(e){return function(){this.textContent=e}}function pT(e){return function(){var t=e(this);this.textContent=t??""}}function gT(e){return this.tween("text",typeof e=="function"?pT(Ch(this,"text",e)):fT(e==null?"":e+""))}function mT(e){return function(t){this.textContent=e.call(this,t)}}function yT(e){var t,r;function i(){var a=e.apply(this,arguments);return a!==r&&(t=(r=a)&&mT(a)),t}return i._value=e,i}function CT(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,yT(e))}function xT(){for(var e=this._name,t=this._id,r=jf(),i=this._groups,a=i.length,s=0;s<a;++s)for(var o=i[s],n=o.length,l,h=0;h<n;++h)if(l=o[h]){var c=$e(l,t);Wo(l,e,r,h,o,{time:c.time+c.delay+c.duration,delay:0,duration:c.duration,ease:c.ease})}return new or(i,this._parents,e,r)}function bT(){var e,t,r=this,i=r._id,a=r.size();return new Promise(function(s,o){var n={value:o},l={value:function(){--a===0&&s()}};r.each(function(){var h=je(this,i),c=h.on;c!==e&&(t=(e=c).copy(),t._.cancel.push(n),t._.interrupt.push(n),t._.end.push(l)),h.on=t}),a===0&&s()})}var kT=0;function or(e,t,r,i){this._groups=e,this._parents=t,this._name=r,this._id=i}function jf(){return++kT}var Ke=ja.prototype;or.prototype={constructor:or,select:eT,selectAll:rT,selectChild:Ke.selectChild,selectChildren:Ke.selectChildren,filter:X2,merge:V2,selection:aT,transition:xT,call:Ke.call,nodes:Ke.nodes,node:Ke.node,size:Ke.size,empty:Ke.empty,each:Ke.each,on:K2,attr:E2,attrTween:P2,style:hT,styleTween:dT,text:gT,textTween:CT,remove:tT,tween:S2,delay:q2,duration:H2,ease:Y2,easeVarying:G2,end:bT,[Symbol.iterator]:Ke[Symbol.iterator]};function TT(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var wT={time:null,delay:0,duration:250,ease:TT};function _T(e,t){for(var r;!(r=e.__transition)||!(r=r[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return r}function ST(e){var t,r;e instanceof or?(t=e._id,e=e._name):(t=jf(),(r=wT).time=mh(),e=e==null?null:e+"");for(var i=this._groups,a=i.length,s=0;s<a;++s)for(var o=i[s],n=o.length,l,h=0;h<n;++h)(l=o[h])&&Wo(l,e,t,h,o,r||_T(l,t));return new or(i,this._parents,e,t)}ja.prototype.interrupt=T2;ja.prototype.transition=ST;const ml=Math.PI,yl=2*ml,Fr=1e-6,vT=yl-Fr;function Gf(e){this._+=e[0];for(let t=1,r=e.length;t<r;++t)this._+=arguments[t]+e[t]}function BT(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return Gf;const r=10**t;return function(i){this._+=i[0];for(let a=1,s=i.length;a<s;++a)this._+=Math.round(arguments[a]*r)/r+i[a]}}class LT{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?Gf:BT(t)}moveTo(t,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,r){this._append`L${this._x1=+t},${this._y1=+r}`}quadraticCurveTo(t,r,i,a){this._append`Q${+t},${+r},${this._x1=+i},${this._y1=+a}`}bezierCurveTo(t,r,i,a,s,o){this._append`C${+t},${+r},${+i},${+a},${this._x1=+s},${this._y1=+o}`}arcTo(t,r,i,a,s){if(t=+t,r=+r,i=+i,a=+a,s=+s,s<0)throw new Error(`negative radius: ${s}`);let o=this._x1,n=this._y1,l=i-t,h=a-r,c=o-t,u=n-r,f=c*c+u*u;if(this._x1===null)this._append`M${this._x1=t},${this._y1=r}`;else if(f>Fr)if(!(Math.abs(u*l-h*c)>Fr)||!s)this._append`L${this._x1=t},${this._y1=r}`;else{let d=i-o,p=a-n,g=l*l+h*h,m=d*d+p*p,C=Math.sqrt(g),x=Math.sqrt(f),k=s*Math.tan((ml-Math.acos((g+f-m)/(2*C*x)))/2),w=k/x,S=k/C;Math.abs(w-1)>Fr&&this._append`L${t+w*c},${r+w*u}`,this._append`A${s},${s},0,0,${+(u*d>c*p)},${this._x1=t+S*l},${this._y1=r+S*h}`}}arc(t,r,i,a,s,o){if(t=+t,r=+r,i=+i,o=!!o,i<0)throw new Error(`negative radius: ${i}`);let n=i*Math.cos(a),l=i*Math.sin(a),h=t+n,c=r+l,u=1^o,f=o?a-s:s-a;this._x1===null?this._append`M${h},${c}`:(Math.abs(this._x1-h)>Fr||Math.abs(this._y1-c)>Fr)&&this._append`L${h},${c}`,i&&(f<0&&(f=f%yl+yl),f>vT?this._append`A${i},${i},0,1,${u},${t-n},${r-l}A${i},${i},0,1,${u},${this._x1=h},${this._y1=c}`:f>Fr&&this._append`A${i},${i},0,${+(f>=ml)},${u},${this._x1=t+i*Math.cos(s)},${this._y1=r+i*Math.sin(s)}`)}rect(t,r,i,a){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}h${i=+i}v${+a}h${-i}Z`}toString(){return this._}}function FT(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function io(e,t){if(!isFinite(e)||e===0)return null;var r=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"),i=e.slice(0,r);return[i.length>1?i[0]+i.slice(2):i,+e.slice(r+1)]}function Pi(e){return e=io(Math.abs(e)),e?e[1]:NaN}function MT(e,t){return function(r,i){for(var a=r.length,s=[],o=0,n=e[0],l=0;a>0&&n>0&&(l+n+1>i&&(n=Math.max(1,i-l)),s.push(r.substring(a-=n,a+n)),!((l+=n+1)>i));)n=e[o=(o+1)%e.length];return s.reverse().join(t)}}function AT(e){return function(t){return t.replace(/[0-9]/g,function(r){return e[+r]})}}var ET=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function ao(e){if(!(t=ET.exec(e)))throw new Error("invalid format: "+e);var t;return new xh({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}ao.prototype=xh.prototype;function xh(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}xh.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function $T(e){t:for(var t=e.length,r=1,i=-1,a;r<t;++r)switch(e[r]){case".":i=a=r;break;case"0":i===0&&(i=r),a=r;break;default:if(!+e[r])break t;i>0&&(i=0);break}return i>0?e.slice(0,i)+e.slice(a+1):e}var so;function DT(e,t){var r=io(e,t);if(!r)return so=void 0,e.toPrecision(t);var i=r[0],a=r[1],s=a-(so=Math.max(-8,Math.min(8,Math.floor(a/3)))*3)+1,o=i.length;return s===o?i:s>o?i+new Array(s-o+1).join("0"):s>0?i.slice(0,s)+"."+i.slice(s):"0."+new Array(1-s).join("0")+io(e,Math.max(0,t+s-1))[0]}function lu(e,t){var r=io(e,t);if(!r)return e+"";var i=r[0],a=r[1];return a<0?"0."+new Array(-a).join("0")+i:i.length>a+1?i.slice(0,a+1)+"."+i.slice(a+1):i+new Array(a-i.length+2).join("0")}const hu={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:FT,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>lu(e*100,t),r:lu,s:DT,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function cu(e){return e}var uu=Array.prototype.map,du=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function OT(e){var t=e.grouping===void 0||e.thousands===void 0?cu:MT(uu.call(e.grouping,Number),e.thousands+""),r=e.currency===void 0?"":e.currency[0]+"",i=e.currency===void 0?"":e.currency[1]+"",a=e.decimal===void 0?".":e.decimal+"",s=e.numerals===void 0?cu:AT(uu.call(e.numerals,String)),o=e.percent===void 0?"%":e.percent+"",n=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function h(u,f){u=ao(u);var d=u.fill,p=u.align,g=u.sign,m=u.symbol,C=u.zero,x=u.width,k=u.comma,w=u.precision,S=u.trim,_=u.type;_==="n"?(k=!0,_="g"):hu[_]||(w===void 0&&(w=12),S=!0,_="g"),(C||d==="0"&&p==="=")&&(C=!0,d="0",p="=");var T=(f&&f.prefix!==void 0?f.prefix:"")+(m==="$"?r:m==="#"&&/[boxX]/.test(_)?"0"+_.toLowerCase():""),B=(m==="$"?i:/[%p]/.test(_)?o:"")+(f&&f.suffix!==void 0?f.suffix:""),z=hu[_],I=/[defgprs%]/.test(_);w=w===void 0?6:/[gprs]/.test(_)?Math.max(1,Math.min(21,w)):Math.max(0,Math.min(20,w));function E(N){var D=T,M=B,$,A,O;if(_==="c")M=z(N)+M,N="";else{N=+N;var F=N<0||1/N<0;if(N=isNaN(N)?l:z(Math.abs(N),w),S&&(N=$T(N)),F&&+N==0&&g!=="+"&&(F=!1),D=(F?g==="("?g:n:g==="-"||g==="("?"":g)+D,M=(_==="s"&&!isNaN(N)&&so!==void 0?du[8+so/3]:"")+M+(F&&g==="("?")":""),I){for($=-1,A=N.length;++$<A;)if(O=N.charCodeAt($),48>O||O>57){M=(O===46?a+N.slice($+1):N.slice($))+M,N=N.slice(0,$);break}}}k&&!C&&(N=t(N,1/0));var H=D.length+N.length+M.length,Y=H<x?new Array(x-H+1).join(d):"";switch(k&&C&&(N=t(Y+N,Y.length?x-M.length:1/0),Y=""),p){case"<":N=D+N+M+Y;break;case"=":N=D+Y+N+M;break;case"^":N=Y.slice(0,H=Y.length>>1)+D+N+M+Y.slice(H);break;default:N=Y+D+N+M;break}return s(N)}return E.toString=function(){return u+""},E}function c(u,f){var d=Math.max(-8,Math.min(8,Math.floor(Pi(f)/3)))*3,p=Math.pow(10,-d),g=h((u=ao(u),u.type="f",u),{suffix:du[8+d/3]});return function(m){return g(p*m)}}return{format:h,formatPrefix:c}}var ps,Xf,Vf;IT({thousands:",",grouping:[3],currency:["$",""]});function IT(e){return ps=OT(e),Xf=ps.format,Vf=ps.formatPrefix,ps}function PT(e){return Math.max(0,-Pi(Math.abs(e)))}function RT(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Pi(t)/3)))*3-Pi(Math.abs(e)))}function NT(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Pi(t)-Pi(e))+1}function qT(e){var t=0,r=e.children,i=r&&r.length;if(!i)t=1;else for(;--i>=0;)t+=r[i].value;e.value=t}function zT(){return this.eachAfter(qT)}function WT(e,t){let r=-1;for(const i of this)e.call(t,i,++r,this);return this}function HT(e,t){for(var r=this,i=[r],a,s,o=-1;r=i.pop();)if(e.call(t,r,++o,this),a=r.children)for(s=a.length-1;s>=0;--s)i.push(a[s]);return this}function UT(e,t){for(var r=this,i=[r],a=[],s,o,n,l=-1;r=i.pop();)if(a.push(r),s=r.children)for(o=0,n=s.length;o<n;++o)i.push(s[o]);for(;r=a.pop();)e.call(t,r,++l,this);return this}function YT(e,t){let r=-1;for(const i of this)if(e.call(t,i,++r,this))return i}function jT(e){return this.eachAfter(function(t){for(var r=+e(t.data)||0,i=t.children,a=i&&i.length;--a>=0;)r+=i[a].value;t.value=r})}function GT(e){return this.eachBefore(function(t){t.children&&t.children.sort(e)})}function XT(e){for(var t=this,r=VT(t,e),i=[t];t!==r;)t=t.parent,i.push(t);for(var a=i.length;e!==r;)i.splice(a,0,e),e=e.parent;return i}function VT(e,t){if(e===t)return e;var r=e.ancestors(),i=t.ancestors(),a=null;for(e=r.pop(),t=i.pop();e===t;)a=e,e=r.pop(),t=i.pop();return a}function ZT(){for(var e=this,t=[e];e=e.parent;)t.push(e);return t}function QT(){return Array.from(this)}function KT(){var e=[];return this.eachBefore(function(t){t.children||e.push(t)}),e}function JT(){var e=this,t=[];return e.each(function(r){r!==e&&t.push({source:r.parent,target:r})}),t}function*tw(){var e=this,t,r=[e],i,a,s;do for(t=r.reverse(),r=[];e=t.pop();)if(yield e,i=e.children)for(a=0,s=i.length;a<s;++a)r.push(i[a]);while(r.length)}function Zf(e,t){e instanceof Map?(e=[void 0,e],t===void 0&&(t=iw)):t===void 0&&(t=rw);for(var r=new oo(e),i,a=[r],s,o,n,l;i=a.pop();)if((o=t(i.data))&&(l=(o=Array.from(o)).length))for(i.children=o,n=l-1;n>=0;--n)a.push(s=o[n]=new oo(o[n])),s.parent=i,s.depth=i.depth+1;return r.eachBefore(sw)}function ew(){return Zf(this).eachBefore(aw)}function rw(e){return e.children}function iw(e){return Array.isArray(e)?e[1]:null}function aw(e){e.data.value!==void 0&&(e.value=e.data.value),e.data=e.data.data}function sw(e){var t=0;do e.height=t;while((e=e.parent)&&e.height<++t)}function oo(e){this.data=e,this.depth=this.height=0,this.parent=null}oo.prototype=Zf.prototype={constructor:oo,count:zT,each:WT,eachAfter:UT,eachBefore:HT,find:YT,sum:jT,sort:GT,path:XT,ancestors:ZT,descendants:QT,leaves:KT,links:JT,copy:ew,[Symbol.iterator]:tw};function ow(e){if(typeof e!="function")throw new Error;return e}function ia(){return 0}function aa(e){return function(){return e}}function nw(e){e.x0=Math.round(e.x0),e.y0=Math.round(e.y0),e.x1=Math.round(e.x1),e.y1=Math.round(e.y1)}function lw(e,t,r,i,a){for(var s=e.children,o,n=-1,l=s.length,h=e.value&&(i-t)/e.value;++n<l;)o=s[n],o.y0=r,o.y1=a,o.x0=t,o.x1=t+=o.value*h}function hw(e,t,r,i,a){for(var s=e.children,o,n=-1,l=s.length,h=e.value&&(a-r)/e.value;++n<l;)o=s[n],o.x0=t,o.x1=i,o.y0=r,o.y1=r+=o.value*h}var cw=(1+Math.sqrt(5))/2;function uw(e,t,r,i,a,s){for(var o=[],n=t.children,l,h,c=0,u=0,f=n.length,d,p,g=t.value,m,C,x,k,w,S,_;c<f;){d=a-r,p=s-i;do m=n[u++].value;while(!m&&u<f);for(C=x=m,S=Math.max(p/d,d/p)/(g*e),_=m*m*S,w=Math.max(x/_,_/C);u<f;++u){if(m+=h=n[u].value,h<C&&(C=h),h>x&&(x=h),_=m*m*S,k=Math.max(x/_,_/C),k>w){m-=h;break}w=k}o.push(l={value:m,dice:d<p,children:n.slice(c,u)}),l.dice?lw(l,r,i,a,g?i+=p*m/g:s):hw(l,r,i,g?r+=d*m/g:a,s),g-=m,c=u}return o}const dw=(function e(t){function r(i,a,s,o,n){uw(t,i,a,s,o,n)}return r.ratio=function(i){return e((i=+i)>1?i:1)},r})(cw);function P$(){var e=dw,t=!1,r=1,i=1,a=[0],s=ia,o=ia,n=ia,l=ia,h=ia;function c(f){return f.x0=f.y0=0,f.x1=r,f.y1=i,f.eachBefore(u),a=[0],t&&f.eachBefore(nw),f}function u(f){var d=a[f.depth],p=f.x0+d,g=f.y0+d,m=f.x1-d,C=f.y1-d;m<p&&(p=m=(p+m)/2),C<g&&(g=C=(g+C)/2),f.x0=p,f.y0=g,f.x1=m,f.y1=C,f.children&&(d=a[f.depth+1]=s(f)/2,p+=h(f)-d,g+=o(f)-d,m-=n(f)-d,C-=l(f)-d,m<p&&(p=m=(p+m)/2),C<g&&(g=C=(g+C)/2),e(f,p,g,m,C))}return c.round=function(f){return arguments.length?(t=!!f,c):t},c.size=function(f){return arguments.length?(r=+f[0],i=+f[1],c):[r,i]},c.tile=function(f){return arguments.length?(e=ow(f),c):e},c.padding=function(f){return arguments.length?c.paddingInner(f).paddingOuter(f):c.paddingInner()},c.paddingInner=function(f){return arguments.length?(s=typeof f=="function"?f:aa(+f),c):s},c.paddingOuter=function(f){return arguments.length?c.paddingTop(f).paddingRight(f).paddingBottom(f).paddingLeft(f):c.paddingTop()},c.paddingTop=function(f){return arguments.length?(o=typeof f=="function"?f:aa(+f),c):o},c.paddingRight=function(f){return arguments.length?(n=typeof f=="function"?f:aa(+f),c):n},c.paddingBottom=function(f){return arguments.length?(l=typeof f=="function"?f:aa(+f),c):l},c.paddingLeft=function(f){return arguments.length?(h=typeof f=="function"?f:aa(+f),c):h},c}function Ho(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}const fu=Symbol("implicit");function Qf(){var e=new Uc,t=[],r=[],i=fu;function a(s){let o=e.get(s);if(o===void 0){if(i!==fu)return i;e.set(s,o=t.push(s)-1)}return r[o%r.length]}return a.domain=function(s){if(!arguments.length)return t.slice();t=[],e=new Uc;for(const o of s)e.has(o)||e.set(o,t.push(o)-1);return a},a.range=function(s){return arguments.length?(r=Array.from(s),a):r.slice()},a.unknown=function(s){return arguments.length?(i=s,a):i},a.copy=function(){return Qf(t,r).unknown(i)},Ho.apply(a,arguments),a}function fw(){var e=Qf().unknown(void 0),t=e.domain,r=e.range,i=0,a=1,s,o,n=!1,l=0,h=0,c=.5;delete e.unknown;function u(){var f=t().length,d=a<i,p=d?a:i,g=d?i:a;s=(g-p)/Math.max(1,f-l+h*2),n&&(s=Math.floor(s)),p+=(g-p-s*(f-l))*c,o=s*(1-l),n&&(p=Math.round(p),o=Math.round(o));var m=X1(f).map(function(C){return p+s*C});return r(d?m.reverse():m)}return e.domain=function(f){return arguments.length?(t(f),u()):t()},e.range=function(f){return arguments.length?([i,a]=f,i=+i,a=+a,u()):[i,a]},e.rangeRound=function(f){return[i,a]=f,i=+i,a=+a,n=!0,u()},e.bandwidth=function(){return o},e.step=function(){return s},e.round=function(f){return arguments.length?(n=!!f,u()):n},e.padding=function(f){return arguments.length?(l=Math.min(1,h=+f),u()):l},e.paddingInner=function(f){return arguments.length?(l=Math.min(1,f),u()):l},e.paddingOuter=function(f){return arguments.length?(h=+f,u()):h},e.align=function(f){return arguments.length?(c=Math.max(0,Math.min(1,f)),u()):c},e.copy=function(){return fw(t(),[i,a]).round(n).paddingInner(l).paddingOuter(h).align(c)},Ho.apply(u(),arguments)}function pw(e){return function(){return e}}function gw(e){return+e}var pu=[0,1];function ui(e){return e}function Cl(e,t){return(t-=e=+e)?function(r){return(r-e)/t}:pw(isNaN(t)?NaN:.5)}function mw(e,t){var r;return e>t&&(r=e,e=t,t=r),function(i){return Math.max(e,Math.min(t,i))}}function yw(e,t,r){var i=e[0],a=e[1],s=t[0],o=t[1];return a<i?(i=Cl(a,i),s=r(o,s)):(i=Cl(i,a),s=r(s,o)),function(n){return s(i(n))}}function Cw(e,t,r){var i=Math.min(e.length,t.length)-1,a=new Array(i),s=new Array(i),o=-1;for(e[i]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++o<i;)a[o]=Cl(e[o],e[o+1]),s[o]=r(t[o],t[o+1]);return function(n){var l=q1(e,n,1,i)-1;return s[l](a[l](n))}}function Kf(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function xw(){var e=pu,t=pu,r=gh,i,a,s,o=ui,n,l,h;function c(){var f=Math.min(e.length,t.length);return o!==ui&&(o=mw(e[0],e[f-1])),n=f>2?Cw:yw,l=h=null,u}function u(f){return f==null||isNaN(f=+f)?s:(l||(l=n(e.map(i),t,r)))(i(o(f)))}return u.invert=function(f){return o(a((h||(h=n(t,e.map(i),we)))(f)))},u.domain=function(f){return arguments.length?(e=Array.from(f,gw),c()):e.slice()},u.range=function(f){return arguments.length?(t=Array.from(f),c()):t.slice()},u.rangeRound=function(f){return t=Array.from(f),r=l2,c()},u.clamp=function(f){return arguments.length?(o=f?!0:ui,c()):o!==ui},u.interpolate=function(f){return arguments.length?(r=f,c()):r},u.unknown=function(f){return arguments.length?(s=f,u):s},function(f,d){return i=f,a=d,c()}}function Jf(){return xw()(ui,ui)}function bw(e,t,r,i){var a=ol(e,t,r),s;switch(i=ao(i??",f"),i.type){case"s":{var o=Math.max(Math.abs(e),Math.abs(t));return i.precision==null&&!isNaN(s=RT(a,o))&&(i.precision=s),Vf(i,o)}case"":case"e":case"g":case"p":case"r":{i.precision==null&&!isNaN(s=NT(a,Math.max(Math.abs(e),Math.abs(t))))&&(i.precision=s-(i.type==="e"));break}case"f":case"%":{i.precision==null&&!isNaN(s=PT(a))&&(i.precision=s-(i.type==="%")*2);break}}return Xf(i)}function kw(e){var t=e.domain;return e.ticks=function(r){var i=t();return G1(i[0],i[i.length-1],r??10)},e.tickFormat=function(r,i){var a=t();return bw(a[0],a[a.length-1],r??10,i)},e.nice=function(r){r==null&&(r=10);var i=t(),a=0,s=i.length-1,o=i[a],n=i[s],l,h,c=10;for(n<o&&(h=o,o=n,n=h,h=a,a=s,s=h);c-- >0;){if(h=sl(o,n,r),h===l)return i[a]=o,i[s]=n,t(i);if(h>0)o=Math.floor(o/h)*h,n=Math.ceil(n/h)*h;else if(h<0)o=Math.ceil(o*h)/h,n=Math.floor(n*h)/h;else break;l=h}return e},e}function Tw(){var e=Jf();return e.copy=function(){return Kf(e,Tw())},Ho.apply(e,arguments),kw(e)}function ww(e,t){e=e.slice();var r=0,i=e.length-1,a=e[r],s=e[i],o;return s<a&&(o=r,r=i,i=o,o=a,a=s,s=o),e[r]=t.floor(a),e[i]=t.ceil(s),e}const En=new Date,$n=new Date;function Wt(e,t,r,i){function a(s){return e(s=arguments.length===0?new Date:new Date(+s)),s}return a.floor=s=>(e(s=new Date(+s)),s),a.ceil=s=>(e(s=new Date(s-1)),t(s,1),e(s),s),a.round=s=>{const o=a(s),n=a.ceil(s);return s-o<n-s?o:n},a.offset=(s,o)=>(t(s=new Date(+s),o==null?1:Math.floor(o)),s),a.range=(s,o,n)=>{const l=[];if(s=a.ceil(s),n=n==null?1:Math.floor(n),!(s<o)||!(n>0))return l;let h;do l.push(h=new Date(+s)),t(s,n),e(s);while(h<s&&s<o);return l},a.filter=s=>Wt(o=>{if(o>=o)for(;e(o),!s(o);)o.setTime(o-1)},(o,n)=>{if(o>=o)if(n<0)for(;++n<=0;)for(;t(o,-1),!s(o););else for(;--n>=0;)for(;t(o,1),!s(o););}),r&&(a.count=(s,o)=>(En.setTime(+s),$n.setTime(+o),e(En),e($n),Math.floor(r(En,$n))),a.every=s=>(s=Math.floor(s),!isFinite(s)||!(s>0)?null:s>1?a.filter(i?o=>i(o)%s===0:o=>a.count(0,o)%s===0):a)),a}const no=Wt(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);no.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?Wt(t=>{t.setTime(Math.floor(t/e)*e)},(t,r)=>{t.setTime(+t+r*e)},(t,r)=>(r-t)/e):no);no.range;const rr=1e3,be=rr*60,ir=be*60,nr=ir*24,bh=nr*7,gu=nr*30,Dn=nr*365,di=Wt(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*rr)},(e,t)=>(t-e)/rr,e=>e.getUTCSeconds());di.range;const kh=Wt(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*rr)},(e,t)=>{e.setTime(+e+t*be)},(e,t)=>(t-e)/be,e=>e.getMinutes());kh.range;const _w=Wt(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*be)},(e,t)=>(t-e)/be,e=>e.getUTCMinutes());_w.range;const Th=Wt(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*rr-e.getMinutes()*be)},(e,t)=>{e.setTime(+e+t*ir)},(e,t)=>(t-e)/ir,e=>e.getHours());Th.range;const Sw=Wt(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*ir)},(e,t)=>(t-e)/ir,e=>e.getUTCHours());Sw.range;const Xa=Wt(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*be)/nr,e=>e.getDate()-1);Xa.range;const wh=Wt(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/nr,e=>e.getUTCDate()-1);wh.range;const vw=Wt(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/nr,e=>Math.floor(e/nr));vw.range;function Vr(e){return Wt(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,r)=>{t.setDate(t.getDate()+r*7)},(t,r)=>(r-t-(r.getTimezoneOffset()-t.getTimezoneOffset())*be)/bh)}const Uo=Vr(0),lo=Vr(1),Bw=Vr(2),Lw=Vr(3),Ri=Vr(4),Fw=Vr(5),Mw=Vr(6);Uo.range;lo.range;Bw.range;Lw.range;Ri.range;Fw.range;Mw.range;function Zr(e){return Wt(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,r)=>{t.setUTCDate(t.getUTCDate()+r*7)},(t,r)=>(r-t)/bh)}const tp=Zr(0),ho=Zr(1),Aw=Zr(2),Ew=Zr(3),Ni=Zr(4),$w=Zr(5),Dw=Zr(6);tp.range;ho.range;Aw.range;Ew.range;Ni.range;$w.range;Dw.range;const _h=Wt(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());_h.range;const Ow=Wt(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());Ow.range;const lr=Wt(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());lr.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Wt(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,r)=>{t.setFullYear(t.getFullYear()+r*e)});lr.range;const Wr=Wt(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());Wr.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Wt(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,r)=>{t.setUTCFullYear(t.getUTCFullYear()+r*e)});Wr.range;function Iw(e,t,r,i,a,s){const o=[[di,1,rr],[di,5,5*rr],[di,15,15*rr],[di,30,30*rr],[s,1,be],[s,5,5*be],[s,15,15*be],[s,30,30*be],[a,1,ir],[a,3,3*ir],[a,6,6*ir],[a,12,12*ir],[i,1,nr],[i,2,2*nr],[r,1,bh],[t,1,gu],[t,3,3*gu],[e,1,Dn]];function n(h,c,u){const f=c<h;f&&([h,c]=[c,h]);const d=u&&typeof u.range=="function"?u:l(h,c,u),p=d?d.range(h,+c+1):[];return f?p.reverse():p}function l(h,c,u){const f=Math.abs(c-h)/u,d=dh(([,,m])=>m).right(o,f);if(d===o.length)return e.every(ol(h/Dn,c/Dn,u));if(d===0)return no.every(Math.max(ol(h,c,u),1));const[p,g]=o[f/o[d-1][2]<o[d][2]/f?d-1:d];return p.every(g)}return[n,l]}const[Pw,Rw]=Iw(lr,_h,Uo,Xa,Th,kh);function On(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function In(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function sa(e,t,r){return{y:e,m:t,d:r,H:0,M:0,S:0,L:0}}function Nw(e){var t=e.dateTime,r=e.date,i=e.time,a=e.periods,s=e.days,o=e.shortDays,n=e.months,l=e.shortMonths,h=oa(a),c=na(a),u=oa(s),f=na(s),d=oa(o),p=na(o),g=oa(n),m=na(n),C=oa(l),x=na(l),k={a:O,A:F,b:H,B:Y,c:null,d:ku,e:ku,f:l_,g:C_,G:b_,H:s_,I:o_,j:n_,L:ep,m:h_,M:c_,p:Z,q:ut,Q:_u,s:Su,S:u_,u:d_,U:f_,V:p_,w:g_,W:m_,x:null,X:null,y:y_,Y:x_,Z:k_,"%":wu},w={a:at,A:dt,b:Q,B:xt,c:null,d:Tu,e:Tu,f:S_,g:O_,G:P_,H:T_,I:w_,j:__,L:ip,m:v_,M:B_,p:vt,q:Bt,Q:_u,s:Su,S:L_,u:F_,U:M_,V:A_,w:E_,W:$_,x:null,X:null,y:D_,Y:I_,Z:R_,"%":wu},S={a:I,A:E,b:N,B:D,c:M,d:xu,e:xu,f:e_,g:Cu,G:yu,H:bu,I:bu,j:Qw,L:t_,m:Zw,M:Kw,p:z,q:Vw,Q:i_,s:a_,S:Jw,u:Uw,U:Yw,V:jw,w:Hw,W:Gw,x:$,X:A,y:Cu,Y:yu,Z:Xw,"%":r_};k.x=_(r,k),k.X=_(i,k),k.c=_(t,k),w.x=_(r,w),w.X=_(i,w),w.c=_(t,w);function _(X,U){return function(G){var q=[],ft=-1,gt=0,wt=X.length,Ot,Ce,de;for(G instanceof Date||(G=new Date(+G));++ft<wt;)X.charCodeAt(ft)===37&&(q.push(X.slice(gt,ft)),(Ce=mu[Ot=X.charAt(++ft)])!=null?Ot=X.charAt(++ft):Ce=Ot==="e"?" ":"0",(de=U[Ot])&&(Ot=de(G,Ce)),q.push(Ot),gt=ft+1);return q.push(X.slice(gt,ft)),q.join("")}}function T(X,U){return function(G){var q=sa(1900,void 0,1),ft=B(q,X,G+="",0),gt,wt;if(ft!=G.length)return null;if("Q"in q)return new Date(q.Q);if("s"in q)return new Date(q.s*1e3+("L"in q?q.L:0));if(U&&!("Z"in q)&&(q.Z=0),"p"in q&&(q.H=q.H%12+q.p*12),q.m===void 0&&(q.m="q"in q?q.q:0),"V"in q){if(q.V<1||q.V>53)return null;"w"in q||(q.w=1),"Z"in q?(gt=In(sa(q.y,0,1)),wt=gt.getUTCDay(),gt=wt>4||wt===0?ho.ceil(gt):ho(gt),gt=wh.offset(gt,(q.V-1)*7),q.y=gt.getUTCFullYear(),q.m=gt.getUTCMonth(),q.d=gt.getUTCDate()+(q.w+6)%7):(gt=On(sa(q.y,0,1)),wt=gt.getDay(),gt=wt>4||wt===0?lo.ceil(gt):lo(gt),gt=Xa.offset(gt,(q.V-1)*7),q.y=gt.getFullYear(),q.m=gt.getMonth(),q.d=gt.getDate()+(q.w+6)%7)}else("W"in q||"U"in q)&&("w"in q||(q.w="u"in q?q.u%7:"W"in q?1:0),wt="Z"in q?In(sa(q.y,0,1)).getUTCDay():On(sa(q.y,0,1)).getDay(),q.m=0,q.d="W"in q?(q.w+6)%7+q.W*7-(wt+5)%7:q.w+q.U*7-(wt+6)%7);return"Z"in q?(q.H+=q.Z/100|0,q.M+=q.Z%100,In(q)):On(q)}}function B(X,U,G,q){for(var ft=0,gt=U.length,wt=G.length,Ot,Ce;ft<gt;){if(q>=wt)return-1;if(Ot=U.charCodeAt(ft++),Ot===37){if(Ot=U.charAt(ft++),Ce=S[Ot in mu?U.charAt(ft++):Ot],!Ce||(q=Ce(X,G,q))<0)return-1}else if(Ot!=G.charCodeAt(q++))return-1}return q}function z(X,U,G){var q=h.exec(U.slice(G));return q?(X.p=c.get(q[0].toLowerCase()),G+q[0].length):-1}function I(X,U,G){var q=d.exec(U.slice(G));return q?(X.w=p.get(q[0].toLowerCase()),G+q[0].length):-1}function E(X,U,G){var q=u.exec(U.slice(G));return q?(X.w=f.get(q[0].toLowerCase()),G+q[0].length):-1}function N(X,U,G){var q=C.exec(U.slice(G));return q?(X.m=x.get(q[0].toLowerCase()),G+q[0].length):-1}function D(X,U,G){var q=g.exec(U.slice(G));return q?(X.m=m.get(q[0].toLowerCase()),G+q[0].length):-1}function M(X,U,G){return B(X,t,U,G)}function $(X,U,G){return B(X,r,U,G)}function A(X,U,G){return B(X,i,U,G)}function O(X){return o[X.getDay()]}function F(X){return s[X.getDay()]}function H(X){return l[X.getMonth()]}function Y(X){return n[X.getMonth()]}function Z(X){return a[+(X.getHours()>=12)]}function ut(X){return 1+~~(X.getMonth()/3)}function at(X){return o[X.getUTCDay()]}function dt(X){return s[X.getUTCDay()]}function Q(X){return l[X.getUTCMonth()]}function xt(X){return n[X.getUTCMonth()]}function vt(X){return a[+(X.getUTCHours()>=12)]}function Bt(X){return 1+~~(X.getUTCMonth()/3)}return{format:function(X){var U=_(X+="",k);return U.toString=function(){return X},U},parse:function(X){var U=T(X+="",!1);return U.toString=function(){return X},U},utcFormat:function(X){var U=_(X+="",w);return U.toString=function(){return X},U},utcParse:function(X){var U=T(X+="",!0);return U.toString=function(){return X},U}}}var mu={"-":"",_:" ",0:"0"},Ut=/^\s*\d+/,qw=/^%/,zw=/[\\^$*+?|[\]().{}]/g;function kt(e,t,r){var i=e<0?"-":"",a=(i?-e:e)+"",s=a.length;return i+(s<r?new Array(r-s+1).join(t)+a:a)}function Ww(e){return e.replace(zw,"\\$&")}function oa(e){return new RegExp("^(?:"+e.map(Ww).join("|")+")","i")}function na(e){return new Map(e.map((t,r)=>[t.toLowerCase(),r]))}function Hw(e,t,r){var i=Ut.exec(t.slice(r,r+1));return i?(e.w=+i[0],r+i[0].length):-1}function Uw(e,t,r){var i=Ut.exec(t.slice(r,r+1));return i?(e.u=+i[0],r+i[0].length):-1}function Yw(e,t,r){var i=Ut.exec(t.slice(r,r+2));return i?(e.U=+i[0],r+i[0].length):-1}function jw(e,t,r){var i=Ut.exec(t.slice(r,r+2));return i?(e.V=+i[0],r+i[0].length):-1}function Gw(e,t,r){var i=Ut.exec(t.slice(r,r+2));return i?(e.W=+i[0],r+i[0].length):-1}function yu(e,t,r){var i=Ut.exec(t.slice(r,r+4));return i?(e.y=+i[0],r+i[0].length):-1}function Cu(e,t,r){var i=Ut.exec(t.slice(r,r+2));return i?(e.y=+i[0]+(+i[0]>68?1900:2e3),r+i[0].length):-1}function Xw(e,t,r){var i=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(r,r+6));return i?(e.Z=i[1]?0:-(i[2]+(i[3]||"00")),r+i[0].length):-1}function Vw(e,t,r){var i=Ut.exec(t.slice(r,r+1));return i?(e.q=i[0]*3-3,r+i[0].length):-1}function Zw(e,t,r){var i=Ut.exec(t.slice(r,r+2));return i?(e.m=i[0]-1,r+i[0].length):-1}function xu(e,t,r){var i=Ut.exec(t.slice(r,r+2));return i?(e.d=+i[0],r+i[0].length):-1}function Qw(e,t,r){var i=Ut.exec(t.slice(r,r+3));return i?(e.m=0,e.d=+i[0],r+i[0].length):-1}function bu(e,t,r){var i=Ut.exec(t.slice(r,r+2));return i?(e.H=+i[0],r+i[0].length):-1}function Kw(e,t,r){var i=Ut.exec(t.slice(r,r+2));return i?(e.M=+i[0],r+i[0].length):-1}function Jw(e,t,r){var i=Ut.exec(t.slice(r,r+2));return i?(e.S=+i[0],r+i[0].length):-1}function t_(e,t,r){var i=Ut.exec(t.slice(r,r+3));return i?(e.L=+i[0],r+i[0].length):-1}function e_(e,t,r){var i=Ut.exec(t.slice(r,r+6));return i?(e.L=Math.floor(i[0]/1e3),r+i[0].length):-1}function r_(e,t,r){var i=qw.exec(t.slice(r,r+1));return i?r+i[0].length:-1}function i_(e,t,r){var i=Ut.exec(t.slice(r));return i?(e.Q=+i[0],r+i[0].length):-1}function a_(e,t,r){var i=Ut.exec(t.slice(r));return i?(e.s=+i[0],r+i[0].length):-1}function ku(e,t){return kt(e.getDate(),t,2)}function s_(e,t){return kt(e.getHours(),t,2)}function o_(e,t){return kt(e.getHours()%12||12,t,2)}function n_(e,t){return kt(1+Xa.count(lr(e),e),t,3)}function ep(e,t){return kt(e.getMilliseconds(),t,3)}function l_(e,t){return ep(e,t)+"000"}function h_(e,t){return kt(e.getMonth()+1,t,2)}function c_(e,t){return kt(e.getMinutes(),t,2)}function u_(e,t){return kt(e.getSeconds(),t,2)}function d_(e){var t=e.getDay();return t===0?7:t}function f_(e,t){return kt(Uo.count(lr(e)-1,e),t,2)}function rp(e){var t=e.getDay();return t>=4||t===0?Ri(e):Ri.ceil(e)}function p_(e,t){return e=rp(e),kt(Ri.count(lr(e),e)+(lr(e).getDay()===4),t,2)}function g_(e){return e.getDay()}function m_(e,t){return kt(lo.count(lr(e)-1,e),t,2)}function y_(e,t){return kt(e.getFullYear()%100,t,2)}function C_(e,t){return e=rp(e),kt(e.getFullYear()%100,t,2)}function x_(e,t){return kt(e.getFullYear()%1e4,t,4)}function b_(e,t){var r=e.getDay();return e=r>=4||r===0?Ri(e):Ri.ceil(e),kt(e.getFullYear()%1e4,t,4)}function k_(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+kt(t/60|0,"0",2)+kt(t%60,"0",2)}function Tu(e,t){return kt(e.getUTCDate(),t,2)}function T_(e,t){return kt(e.getUTCHours(),t,2)}function w_(e,t){return kt(e.getUTCHours()%12||12,t,2)}function __(e,t){return kt(1+wh.count(Wr(e),e),t,3)}function ip(e,t){return kt(e.getUTCMilliseconds(),t,3)}function S_(e,t){return ip(e,t)+"000"}function v_(e,t){return kt(e.getUTCMonth()+1,t,2)}function B_(e,t){return kt(e.getUTCMinutes(),t,2)}function L_(e,t){return kt(e.getUTCSeconds(),t,2)}function F_(e){var t=e.getUTCDay();return t===0?7:t}function M_(e,t){return kt(tp.count(Wr(e)-1,e),t,2)}function ap(e){var t=e.getUTCDay();return t>=4||t===0?Ni(e):Ni.ceil(e)}function A_(e,t){return e=ap(e),kt(Ni.count(Wr(e),e)+(Wr(e).getUTCDay()===4),t,2)}function E_(e){return e.getUTCDay()}function $_(e,t){return kt(ho.count(Wr(e)-1,e),t,2)}function D_(e,t){return kt(e.getUTCFullYear()%100,t,2)}function O_(e,t){return e=ap(e),kt(e.getUTCFullYear()%100,t,2)}function I_(e,t){return kt(e.getUTCFullYear()%1e4,t,4)}function P_(e,t){var r=e.getUTCDay();return e=r>=4||r===0?Ni(e):Ni.ceil(e),kt(e.getUTCFullYear()%1e4,t,4)}function R_(){return"+0000"}function wu(){return"%"}function _u(e){return+e}function Su(e){return Math.floor(+e/1e3)}var si,sp;N_({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function N_(e){return si=Nw(e),sp=si.format,si.parse,si.utcFormat,si.utcParse,si}function q_(e){return new Date(e)}function z_(e){return e instanceof Date?+e:+new Date(+e)}function op(e,t,r,i,a,s,o,n,l,h){var c=Jf(),u=c.invert,f=c.domain,d=h(".%L"),p=h(":%S"),g=h("%I:%M"),m=h("%I %p"),C=h("%a %d"),x=h("%b %d"),k=h("%B"),w=h("%Y");function S(_){return(l(_)<_?d:n(_)<_?p:o(_)<_?g:s(_)<_?m:i(_)<_?a(_)<_?C:x:r(_)<_?k:w)(_)}return c.invert=function(_){return new Date(u(_))},c.domain=function(_){return arguments.length?f(Array.from(_,z_)):f().map(q_)},c.ticks=function(_){var T=f();return e(T[0],T[T.length-1],_??10)},c.tickFormat=function(_,T){return T==null?S:h(T)},c.nice=function(_){var T=f();return(!_||typeof _.range!="function")&&(_=t(T[0],T[T.length-1],_??10)),_?f(ww(T,_)):c},c.copy=function(){return Kf(c,op(e,t,r,i,a,s,o,n,l,h))},c}function R$(){return Ho.apply(op(Pw,Rw,lr,_h,Uo,Xa,Th,kh,di,sp).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function W_(e){for(var t=e.length/6|0,r=new Array(t),i=0;i<t;)r[i]="#"+e.slice(i*6,++i*6);return r}const N$=W_("4e79a7f28e2ce1575976b7b259a14fedc949af7aa1ff9da79c755fbab0ab");function $t(e){return function(){return e}}const vu=Math.abs,Vt=Math.atan2,vr=Math.cos,H_=Math.max,Pn=Math.min,Ie=Math.sin,fi=Math.sqrt,Qt=1e-12,Da=Math.PI,co=Da/2,Os=2*Da;function U_(e){return e>1?0:e<-1?Da:Math.acos(e)}function Bu(e){return e>=1?co:e<=-1?-co:Math.asin(e)}function np(e){let t=3;return e.digits=function(r){if(!arguments.length)return t;if(r==null)t=null;else{const i=Math.floor(r);if(!(i>=0))throw new RangeError(`invalid digits: ${r}`);t=i}return e},()=>new LT(t)}function Y_(e){return e.innerRadius}function j_(e){return e.outerRadius}function G_(e){return e.startAngle}function X_(e){return e.endAngle}function V_(e){return e&&e.padAngle}function Z_(e,t,r,i,a,s,o,n){var l=r-e,h=i-t,c=o-a,u=n-s,f=u*l-c*h;if(!(f*f<Qt))return f=(c*(t-s)-u*(e-a))/f,[e+f*l,t+f*h]}function gs(e,t,r,i,a,s,o){var n=e-r,l=t-i,h=(o?s:-s)/fi(n*n+l*l),c=h*l,u=-h*n,f=e+c,d=t+u,p=r+c,g=i+u,m=(f+p)/2,C=(d+g)/2,x=p-f,k=g-d,w=x*x+k*k,S=a-s,_=f*g-p*d,T=(k<0?-1:1)*fi(H_(0,S*S*w-_*_)),B=(_*k-x*T)/w,z=(-_*x-k*T)/w,I=(_*k+x*T)/w,E=(-_*x+k*T)/w,N=B-m,D=z-C,M=I-m,$=E-C;return N*N+D*D>M*M+$*$&&(B=I,z=E),{cx:B,cy:z,x01:-c,y01:-u,x11:B*(a/S-1),y11:z*(a/S-1)}}function q$(){var e=Y_,t=j_,r=$t(0),i=null,a=G_,s=X_,o=V_,n=null,l=np(h);function h(){var c,u,f=+e.apply(this,arguments),d=+t.apply(this,arguments),p=a.apply(this,arguments)-co,g=s.apply(this,arguments)-co,m=vu(g-p),C=g>p;if(n||(n=c=l()),d<f&&(u=d,d=f,f=u),!(d>Qt))n.moveTo(0,0);else if(m>Os-Qt)n.moveTo(d*vr(p),d*Ie(p)),n.arc(0,0,d,p,g,!C),f>Qt&&(n.moveTo(f*vr(g),f*Ie(g)),n.arc(0,0,f,g,p,C));else{var x=p,k=g,w=p,S=g,_=m,T=m,B=o.apply(this,arguments)/2,z=B>Qt&&(i?+i.apply(this,arguments):fi(f*f+d*d)),I=Pn(vu(d-f)/2,+r.apply(this,arguments)),E=I,N=I,D,M;if(z>Qt){var $=Bu(z/f*Ie(B)),A=Bu(z/d*Ie(B));(_-=$*2)>Qt?($*=C?1:-1,w+=$,S-=$):(_=0,w=S=(p+g)/2),(T-=A*2)>Qt?(A*=C?1:-1,x+=A,k-=A):(T=0,x=k=(p+g)/2)}var O=d*vr(x),F=d*Ie(x),H=f*vr(S),Y=f*Ie(S);if(I>Qt){var Z=d*vr(k),ut=d*Ie(k),at=f*vr(w),dt=f*Ie(w),Q;if(m<Da)if(Q=Z_(O,F,at,dt,Z,ut,H,Y)){var xt=O-Q[0],vt=F-Q[1],Bt=Z-Q[0],X=ut-Q[1],U=1/Ie(U_((xt*Bt+vt*X)/(fi(xt*xt+vt*vt)*fi(Bt*Bt+X*X)))/2),G=fi(Q[0]*Q[0]+Q[1]*Q[1]);E=Pn(I,(f-G)/(U-1)),N=Pn(I,(d-G)/(U+1))}else E=N=0}T>Qt?N>Qt?(D=gs(at,dt,O,F,d,N,C),M=gs(Z,ut,H,Y,d,N,C),n.moveTo(D.cx+D.x01,D.cy+D.y01),N<I?n.arc(D.cx,D.cy,N,Vt(D.y01,D.x01),Vt(M.y01,M.x01),!C):(n.arc(D.cx,D.cy,N,Vt(D.y01,D.x01),Vt(D.y11,D.x11),!C),n.arc(0,0,d,Vt(D.cy+D.y11,D.cx+D.x11),Vt(M.cy+M.y11,M.cx+M.x11),!C),n.arc(M.cx,M.cy,N,Vt(M.y11,M.x11),Vt(M.y01,M.x01),!C))):(n.moveTo(O,F),n.arc(0,0,d,x,k,!C)):n.moveTo(O,F),!(f>Qt)||!(_>Qt)?n.lineTo(H,Y):E>Qt?(D=gs(H,Y,Z,ut,f,-E,C),M=gs(O,F,at,dt,f,-E,C),n.lineTo(D.cx+D.x01,D.cy+D.y01),E<I?n.arc(D.cx,D.cy,E,Vt(D.y01,D.x01),Vt(M.y01,M.x01),!C):(n.arc(D.cx,D.cy,E,Vt(D.y01,D.x01),Vt(D.y11,D.x11),!C),n.arc(0,0,f,Vt(D.cy+D.y11,D.cx+D.x11),Vt(M.cy+M.y11,M.cx+M.x11),C),n.arc(M.cx,M.cy,E,Vt(M.y11,M.x11),Vt(M.y01,M.x01),!C))):n.arc(0,0,f,S,w,C)}if(n.closePath(),c)return n=null,c+""||null}return h.centroid=function(){var c=(+e.apply(this,arguments)+ +t.apply(this,arguments))/2,u=(+a.apply(this,arguments)+ +s.apply(this,arguments))/2-Da/2;return[vr(u)*c,Ie(u)*c]},h.innerRadius=function(c){return arguments.length?(e=typeof c=="function"?c:$t(+c),h):e},h.outerRadius=function(c){return arguments.length?(t=typeof c=="function"?c:$t(+c),h):t},h.cornerRadius=function(c){return arguments.length?(r=typeof c=="function"?c:$t(+c),h):r},h.padRadius=function(c){return arguments.length?(i=c==null?null:typeof c=="function"?c:$t(+c),h):i},h.startAngle=function(c){return arguments.length?(a=typeof c=="function"?c:$t(+c),h):a},h.endAngle=function(c){return arguments.length?(s=typeof c=="function"?c:$t(+c),h):s},h.padAngle=function(c){return arguments.length?(o=typeof c=="function"?c:$t(+c),h):o},h.context=function(c){return arguments.length?(n=c??null,h):n},h}function lp(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function hp(e){this._context=e}hp.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function Ba(e){return new hp(e)}function Q_(e){return e[0]}function K_(e){return e[1]}function J_(e,t){var r=$t(!0),i=null,a=Ba,s=null,o=np(n);e=typeof e=="function"?e:e===void 0?Q_:$t(e),t=typeof t=="function"?t:t===void 0?K_:$t(t);function n(l){var h,c=(l=lp(l)).length,u,f=!1,d;for(i==null&&(s=a(d=o())),h=0;h<=c;++h)!(h<c&&r(u=l[h],h,l))===f&&((f=!f)?s.lineStart():s.lineEnd()),f&&s.point(+e(u,h,l),+t(u,h,l));if(d)return s=null,d+""||null}return n.x=function(l){return arguments.length?(e=typeof l=="function"?l:$t(+l),n):e},n.y=function(l){return arguments.length?(t=typeof l=="function"?l:$t(+l),n):t},n.defined=function(l){return arguments.length?(r=typeof l=="function"?l:$t(!!l),n):r},n.curve=function(l){return arguments.length?(a=l,i!=null&&(s=a(i)),n):a},n.context=function(l){return arguments.length?(l==null?i=s=null:s=a(i=l),n):i},n}function tS(e,t){return t<e?-1:t>e?1:t>=e?0:NaN}function eS(e){return e}function z$(){var e=eS,t=tS,r=null,i=$t(0),a=$t(Os),s=$t(0);function o(n){var l,h=(n=lp(n)).length,c,u,f=0,d=new Array(h),p=new Array(h),g=+i.apply(this,arguments),m=Math.min(Os,Math.max(-Os,a.apply(this,arguments)-g)),C,x=Math.min(Math.abs(m)/h,s.apply(this,arguments)),k=x*(m<0?-1:1),w;for(l=0;l<h;++l)(w=p[d[l]=l]=+e(n[l],l,n))>0&&(f+=w);for(t!=null?d.sort(function(S,_){return t(p[S],p[_])}):r!=null&&d.sort(function(S,_){return r(n[S],n[_])}),l=0,u=f?(m-h*k)/f:0;l<h;++l,g=C)c=d[l],w=p[c],C=g+(w>0?w*u:0)+k,p[c]={data:n[c],index:l,value:w,startAngle:g,endAngle:C,padAngle:x};return p}return o.value=function(n){return arguments.length?(e=typeof n=="function"?n:$t(+n),o):e},o.sortValues=function(n){return arguments.length?(t=n,r=null,o):t},o.sort=function(n){return arguments.length?(r=n,t=null,o):r},o.startAngle=function(n){return arguments.length?(i=typeof n=="function"?n:$t(+n),o):i},o.endAngle=function(n){return arguments.length?(a=typeof n=="function"?n:$t(+n),o):a},o.padAngle=function(n){return arguments.length?(s=typeof n=="function"?n:$t(+n),o):s},o}class cp{constructor(t,r){this._context=t,this._x=r}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(t,r){switch(t=+t,r=+r,this._point){case 0:{this._point=1,this._line?this._context.lineTo(t,r):this._context.moveTo(t,r);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,r,t,r):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+r)/2,t,this._y0,t,r);break}}this._x0=t,this._y0=r}}function up(e){return new cp(e,!0)}function dp(e){return new cp(e,!1)}function xr(){}function uo(e,t,r){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+r)/6)}function Yo(e){this._context=e}Yo.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:uo(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:uo(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function xl(e){return new Yo(e)}function fp(e){this._context=e}fp.prototype={areaStart:xr,areaEnd:xr,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:uo(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function rS(e){return new fp(e)}function pp(e){this._context=e}pp.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var r=(this._x0+4*this._x1+e)/6,i=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(r,i):this._context.moveTo(r,i);break;case 3:this._point=4;default:uo(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function iS(e){return new pp(e)}function gp(e,t){this._basis=new Yo(e),this._beta=t}gp.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,r=e.length-1;if(r>0)for(var i=e[0],a=t[0],s=e[r]-i,o=t[r]-a,n=-1,l;++n<=r;)l=n/r,this._basis.point(this._beta*e[n]+(1-this._beta)*(i+l*s),this._beta*t[n]+(1-this._beta)*(a+l*o));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};const aS=(function e(t){function r(i){return t===1?new Yo(i):new gp(i,t)}return r.beta=function(i){return e(+i)},r})(.85);function fo(e,t,r){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-r),e._x2,e._y2)}function Sh(e,t){this._context=e,this._k=(1-t)/6}Sh.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:fo(this,this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2,this._x1=e,this._y1=t;break;case 2:this._point=3;default:fo(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const mp=(function e(t){function r(i){return new Sh(i,t)}return r.tension=function(i){return e(+i)},r})(0);function vh(e,t){this._context=e,this._k=(1-t)/6}vh.prototype={areaStart:xr,areaEnd:xr,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:fo(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const sS=(function e(t){function r(i){return new vh(i,t)}return r.tension=function(i){return e(+i)},r})(0);function Bh(e,t){this._context=e,this._k=(1-t)/6}Bh.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:fo(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const oS=(function e(t){function r(i){return new Bh(i,t)}return r.tension=function(i){return e(+i)},r})(0);function Lh(e,t,r){var i=e._x1,a=e._y1,s=e._x2,o=e._y2;if(e._l01_a>Qt){var n=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,l=3*e._l01_a*(e._l01_a+e._l12_a);i=(i*n-e._x0*e._l12_2a+e._x2*e._l01_2a)/l,a=(a*n-e._y0*e._l12_2a+e._y2*e._l01_2a)/l}if(e._l23_a>Qt){var h=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,c=3*e._l23_a*(e._l23_a+e._l12_a);s=(s*h+e._x1*e._l23_2a-t*e._l12_2a)/c,o=(o*h+e._y1*e._l23_2a-r*e._l12_2a)/c}e._context.bezierCurveTo(i,a,s,o,e._x2,e._y2)}function yp(e,t){this._context=e,this._alpha=t}yp.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var r=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3;default:Lh(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const Cp=(function e(t){function r(i){return t?new yp(i,t):new Sh(i,0)}return r.alpha=function(i){return e(+i)},r})(.5);function xp(e,t){this._context=e,this._alpha=t}xp.prototype={areaStart:xr,areaEnd:xr,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(e,t){if(e=+e,t=+t,this._point){var r=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:Lh(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const nS=(function e(t){function r(i){return t?new xp(i,t):new vh(i,0)}return r.alpha=function(i){return e(+i)},r})(.5);function bp(e,t){this._context=e,this._alpha=t}bp.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var r=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:Lh(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const lS=(function e(t){function r(i){return t?new bp(i,t):new Bh(i,0)}return r.alpha=function(i){return e(+i)},r})(.5);function kp(e){this._context=e}kp.prototype={areaStart:xr,areaEnd:xr,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function hS(e){return new kp(e)}function Lu(e){return e<0?-1:1}function Fu(e,t,r){var i=e._x1-e._x0,a=t-e._x1,s=(e._y1-e._y0)/(i||a<0&&-0),o=(r-e._y1)/(a||i<0&&-0),n=(s*a+o*i)/(i+a);return(Lu(s)+Lu(o))*Math.min(Math.abs(s),Math.abs(o),.5*Math.abs(n))||0}function Mu(e,t){var r=e._x1-e._x0;return r?(3*(e._y1-e._y0)/r-t)/2:t}function Rn(e,t,r){var i=e._x0,a=e._y0,s=e._x1,o=e._y1,n=(s-i)/3;e._context.bezierCurveTo(i+n,a+n*t,s-n,o-n*r,s,o)}function po(e){this._context=e}po.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:Rn(this,this._t0,Mu(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var r=NaN;if(e=+e,t=+t,!(e===this._x1&&t===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,Rn(this,Mu(this,r=Fu(this,e,t)),r);break;default:Rn(this,this._t0,r=Fu(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=r}}};function Tp(e){this._context=new wp(e)}(Tp.prototype=Object.create(po.prototype)).point=function(e,t){po.prototype.point.call(this,t,e)};function wp(e){this._context=e}wp.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,r,i,a,s){this._context.bezierCurveTo(t,e,i,r,s,a)}};function _p(e){return new po(e)}function Sp(e){return new Tp(e)}function vp(e){this._context=e}vp.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,r=e.length;if(r)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),r===2)this._context.lineTo(e[1],t[1]);else for(var i=Au(e),a=Au(t),s=0,o=1;o<r;++s,++o)this._context.bezierCurveTo(i[0][s],a[0][s],i[1][s],a[1][s],e[o],t[o]);(this._line||this._line!==0&&r===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}};function Au(e){var t,r=e.length-1,i,a=new Array(r),s=new Array(r),o=new Array(r);for(a[0]=0,s[0]=2,o[0]=e[0]+2*e[1],t=1;t<r-1;++t)a[t]=1,s[t]=4,o[t]=4*e[t]+2*e[t+1];for(a[r-1]=2,s[r-1]=7,o[r-1]=8*e[r-1]+e[r],t=1;t<r;++t)i=a[t]/s[t-1],s[t]-=i,o[t]-=i*o[t-1];for(a[r-1]=o[r-1]/s[r-1],t=r-2;t>=0;--t)a[t]=(o[t]-a[t+1])/s[t];for(s[r-1]=(e[r]+a[r-1])/2,t=0;t<r-1;++t)s[t]=2*e[t+1]-a[t+1];return[a,s]}function Bp(e){return new vp(e)}function jo(e,t){this._context=e,this._t=t}jo.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var r=this._x*(1-this._t)+e*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,t)}break}}this._x=e,this._y=t}};function Lp(e){return new jo(e,.5)}function Fp(e){return new jo(e,0)}function Mp(e){return new jo(e,1)}function Ca(e,t,r){this.k=e,this.x=t,this.y=r}Ca.prototype={constructor:Ca,scale:function(e){return e===1?this:new Ca(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new Ca(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};Ca.prototype;var cS=y(e=>{var a;const{securityLevel:t}=bt();let r=pt("body");if(t==="sandbox"){const o=((a=pt(`#i${e}`).node())==null?void 0:a.contentDocument)??document;r=pt(o.body)}return r.select(`#${e}`)},"selectSvgElement");function Fh(e){return typeof e>"u"||e===null}y(Fh,"isNothing");function Ap(e){return typeof e=="object"&&e!==null}y(Ap,"isObject");function Ep(e){return Array.isArray(e)?e:Fh(e)?[]:[e]}y(Ep,"toArray");function $p(e,t){var r,i,a,s;if(t)for(s=Object.keys(t),r=0,i=s.length;r<i;r+=1)a=s[r],e[a]=t[a];return e}y($p,"extend");function Dp(e,t){var r="",i;for(i=0;i<t;i+=1)r+=e;return r}y(Dp,"repeat");function Op(e){return e===0&&Number.NEGATIVE_INFINITY===1/e}y(Op,"isNegativeZero");var uS=Fh,dS=Ap,fS=Ep,pS=Dp,gS=Op,mS=$p,zt={isNothing:uS,isObject:dS,toArray:fS,repeat:pS,isNegativeZero:gS,extend:mS};function Mh(e,t){var r="",i=e.reason||"(unknown reason)";return e.mark?(e.mark.name&&(r+='in "'+e.mark.name+'" '),r+="("+(e.mark.line+1)+":"+(e.mark.column+1)+")",!t&&e.mark.snippet&&(r+=`
124
+
125
+ `+e.mark.snippet),i+" "+r):i}y(Mh,"formatError");function qi(e,t){Error.call(this),this.name="YAMLException",this.reason=e,this.mark=t,this.message=Mh(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}y(qi,"YAMLException$1");qi.prototype=Object.create(Error.prototype);qi.prototype.constructor=qi;qi.prototype.toString=y(function(t){return this.name+": "+Mh(this,t)},"toString");var ue=qi;function Is(e,t,r,i,a){var s="",o="",n=Math.floor(a/2)-1;return i-t>n&&(s=" ... ",t=i-n+s.length),r-i>n&&(o=" ...",r=i+n-o.length),{str:s+e.slice(t,r).replace(/\t/g,"→")+o,pos:i-t+s.length}}y(Is,"getLine");function Ps(e,t){return zt.repeat(" ",t-e.length)+e}y(Ps,"padStart");function Ip(e,t){if(t=Object.create(t||null),!e.buffer)return null;t.maxLength||(t.maxLength=79),typeof t.indent!="number"&&(t.indent=1),typeof t.linesBefore!="number"&&(t.linesBefore=3),typeof t.linesAfter!="number"&&(t.linesAfter=2);for(var r=/\r?\n|\r|\0/g,i=[0],a=[],s,o=-1;s=r.exec(e.buffer);)a.push(s.index),i.push(s.index+s[0].length),e.position<=s.index&&o<0&&(o=i.length-2);o<0&&(o=i.length-1);var n="",l,h,c=Math.min(e.line+t.linesAfter,a.length).toString().length,u=t.maxLength-(t.indent+c+3);for(l=1;l<=t.linesBefore&&!(o-l<0);l++)h=Is(e.buffer,i[o-l],a[o-l],e.position-(i[o]-i[o-l]),u),n=zt.repeat(" ",t.indent)+Ps((e.line-l+1).toString(),c)+" | "+h.str+`
126
+ `+n;for(h=Is(e.buffer,i[o],a[o],e.position,u),n+=zt.repeat(" ",t.indent)+Ps((e.line+1).toString(),c)+" | "+h.str+`
127
+ `,n+=zt.repeat("-",t.indent+c+3+h.pos)+`^
128
+ `,l=1;l<=t.linesAfter&&!(o+l>=a.length);l++)h=Is(e.buffer,i[o+l],a[o+l],e.position-(i[o]-i[o+l]),u),n+=zt.repeat(" ",t.indent)+Ps((e.line+l+1).toString(),c)+" | "+h.str+`
129
+ `;return n.replace(/\n$/,"")}y(Ip,"makeSnippet");var yS=Ip,CS=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],xS=["scalar","sequence","mapping"];function Pp(e){var t={};return e!==null&&Object.keys(e).forEach(function(r){e[r].forEach(function(i){t[String(i)]=r})}),t}y(Pp,"compileStyleAliases");function Rp(e,t){if(t=t||{},Object.keys(t).forEach(function(r){if(CS.indexOf(r)===-1)throw new ue('Unknown option "'+r+'" is met in definition of "'+e+'" YAML type.')}),this.options=t,this.tag=e,this.kind=t.kind||null,this.resolve=t.resolve||function(){return!0},this.construct=t.construct||function(r){return r},this.instanceOf=t.instanceOf||null,this.predicate=t.predicate||null,this.represent=t.represent||null,this.representName=t.representName||null,this.defaultStyle=t.defaultStyle||null,this.multi=t.multi||!1,this.styleAliases=Pp(t.styleAliases||null),xS.indexOf(this.kind)===-1)throw new ue('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')}y(Rp,"Type$1");var te=Rp;function bl(e,t){var r=[];return e[t].forEach(function(i){var a=r.length;r.forEach(function(s,o){s.tag===i.tag&&s.kind===i.kind&&s.multi===i.multi&&(a=o)}),r[a]=i}),r}y(bl,"compileList");function Np(){var e={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}},t,r;function i(a){a.multi?(e.multi[a.kind].push(a),e.multi.fallback.push(a)):e[a.kind][a.tag]=e.fallback[a.tag]=a}for(y(i,"collectType"),t=0,r=arguments.length;t<r;t+=1)arguments[t].forEach(i);return e}y(Np,"compileMap");function go(e){return this.extend(e)}y(go,"Schema$1");go.prototype.extend=y(function(t){var r=[],i=[];if(t instanceof te)i.push(t);else if(Array.isArray(t))i=i.concat(t);else if(t&&(Array.isArray(t.implicit)||Array.isArray(t.explicit)))t.implicit&&(r=r.concat(t.implicit)),t.explicit&&(i=i.concat(t.explicit));else throw new ue("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");r.forEach(function(s){if(!(s instanceof te))throw new ue("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(s.loadKind&&s.loadKind!=="scalar")throw new ue("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(s.multi)throw new ue("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),i.forEach(function(s){if(!(s instanceof te))throw new ue("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var a=Object.create(go.prototype);return a.implicit=(this.implicit||[]).concat(r),a.explicit=(this.explicit||[]).concat(i),a.compiledImplicit=bl(a,"implicit"),a.compiledExplicit=bl(a,"explicit"),a.compiledTypeMap=Np(a.compiledImplicit,a.compiledExplicit),a},"extend");var bS=go,kS=new te("tag:yaml.org,2002:str",{kind:"scalar",construct:y(function(e){return e!==null?e:""},"construct")}),TS=new te("tag:yaml.org,2002:seq",{kind:"sequence",construct:y(function(e){return e!==null?e:[]},"construct")}),wS=new te("tag:yaml.org,2002:map",{kind:"mapping",construct:y(function(e){return e!==null?e:{}},"construct")}),_S=new bS({explicit:[kS,TS,wS]});function qp(e){if(e===null)return!0;var t=e.length;return t===1&&e==="~"||t===4&&(e==="null"||e==="Null"||e==="NULL")}y(qp,"resolveYamlNull");function zp(){return null}y(zp,"constructYamlNull");function Wp(e){return e===null}y(Wp,"isNull");var SS=new te("tag:yaml.org,2002:null",{kind:"scalar",resolve:qp,construct:zp,predicate:Wp,represent:{canonical:y(function(){return"~"},"canonical"),lowercase:y(function(){return"null"},"lowercase"),uppercase:y(function(){return"NULL"},"uppercase"),camelcase:y(function(){return"Null"},"camelcase"),empty:y(function(){return""},"empty")},defaultStyle:"lowercase"});function Hp(e){if(e===null)return!1;var t=e.length;return t===4&&(e==="true"||e==="True"||e==="TRUE")||t===5&&(e==="false"||e==="False"||e==="FALSE")}y(Hp,"resolveYamlBoolean");function Up(e){return e==="true"||e==="True"||e==="TRUE"}y(Up,"constructYamlBoolean");function Yp(e){return Object.prototype.toString.call(e)==="[object Boolean]"}y(Yp,"isBoolean");var vS=new te("tag:yaml.org,2002:bool",{kind:"scalar",resolve:Hp,construct:Up,predicate:Yp,represent:{lowercase:y(function(e){return e?"true":"false"},"lowercase"),uppercase:y(function(e){return e?"TRUE":"FALSE"},"uppercase"),camelcase:y(function(e){return e?"True":"False"},"camelcase")},defaultStyle:"lowercase"});function jp(e){return 48<=e&&e<=57||65<=e&&e<=70||97<=e&&e<=102}y(jp,"isHexCode");function Gp(e){return 48<=e&&e<=55}y(Gp,"isOctCode");function Xp(e){return 48<=e&&e<=57}y(Xp,"isDecCode");function Vp(e){if(e===null)return!1;var t=e.length,r=0,i=!1,a;if(!t)return!1;if(a=e[r],(a==="-"||a==="+")&&(a=e[++r]),a==="0"){if(r+1===t)return!0;if(a=e[++r],a==="b"){for(r++;r<t;r++)if(a=e[r],a!=="_"){if(a!=="0"&&a!=="1")return!1;i=!0}return i&&a!=="_"}if(a==="x"){for(r++;r<t;r++)if(a=e[r],a!=="_"){if(!jp(e.charCodeAt(r)))return!1;i=!0}return i&&a!=="_"}if(a==="o"){for(r++;r<t;r++)if(a=e[r],a!=="_"){if(!Gp(e.charCodeAt(r)))return!1;i=!0}return i&&a!=="_"}}if(a==="_")return!1;for(;r<t;r++)if(a=e[r],a!=="_"){if(!Xp(e.charCodeAt(r)))return!1;i=!0}return!(!i||a==="_")}y(Vp,"resolveYamlInteger");function Zp(e){var t=e,r=1,i;if(t.indexOf("_")!==-1&&(t=t.replace(/_/g,"")),i=t[0],(i==="-"||i==="+")&&(i==="-"&&(r=-1),t=t.slice(1),i=t[0]),t==="0")return 0;if(i==="0"){if(t[1]==="b")return r*parseInt(t.slice(2),2);if(t[1]==="x")return r*parseInt(t.slice(2),16);if(t[1]==="o")return r*parseInt(t.slice(2),8)}return r*parseInt(t,10)}y(Zp,"constructYamlInteger");function Qp(e){return Object.prototype.toString.call(e)==="[object Number]"&&e%1===0&&!zt.isNegativeZero(e)}y(Qp,"isInteger");var BS=new te("tag:yaml.org,2002:int",{kind:"scalar",resolve:Vp,construct:Zp,predicate:Qp,represent:{binary:y(function(e){return e>=0?"0b"+e.toString(2):"-0b"+e.toString(2).slice(1)},"binary"),octal:y(function(e){return e>=0?"0o"+e.toString(8):"-0o"+e.toString(8).slice(1)},"octal"),decimal:y(function(e){return e.toString(10)},"decimal"),hexadecimal:y(function(e){return e>=0?"0x"+e.toString(16).toUpperCase():"-0x"+e.toString(16).toUpperCase().slice(1)},"hexadecimal")},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),LS=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function Kp(e){return!(e===null||!LS.test(e)||e[e.length-1]==="_")}y(Kp,"resolveYamlFloat");function Jp(e){var t,r;return t=e.replace(/_/g,"").toLowerCase(),r=t[0]==="-"?-1:1,"+-".indexOf(t[0])>=0&&(t=t.slice(1)),t===".inf"?r===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:t===".nan"?NaN:r*parseFloat(t,10)}y(Jp,"constructYamlFloat");var FS=/^[-+]?[0-9]+e/;function tg(e,t){var r;if(isNaN(e))switch(t){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(t){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(t){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(zt.isNegativeZero(e))return"-0.0";return r=e.toString(10),FS.test(r)?r.replace("e",".e"):r}y(tg,"representYamlFloat");function eg(e){return Object.prototype.toString.call(e)==="[object Number]"&&(e%1!==0||zt.isNegativeZero(e))}y(eg,"isFloat");var MS=new te("tag:yaml.org,2002:float",{kind:"scalar",resolve:Kp,construct:Jp,predicate:eg,represent:tg,defaultStyle:"lowercase"}),rg=_S.extend({implicit:[SS,vS,BS,MS]}),AS=rg,ig=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),ag=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function sg(e){return e===null?!1:ig.exec(e)!==null||ag.exec(e)!==null}y(sg,"resolveYamlTimestamp");function og(e){var t,r,i,a,s,o,n,l=0,h=null,c,u,f;if(t=ig.exec(e),t===null&&(t=ag.exec(e)),t===null)throw new Error("Date resolve error");if(r=+t[1],i=+t[2]-1,a=+t[3],!t[4])return new Date(Date.UTC(r,i,a));if(s=+t[4],o=+t[5],n=+t[6],t[7]){for(l=t[7].slice(0,3);l.length<3;)l+="0";l=+l}return t[9]&&(c=+t[10],u=+(t[11]||0),h=(c*60+u)*6e4,t[9]==="-"&&(h=-h)),f=new Date(Date.UTC(r,i,a,s,o,n,l)),h&&f.setTime(f.getTime()-h),f}y(og,"constructYamlTimestamp");function ng(e){return e.toISOString()}y(ng,"representYamlTimestamp");var ES=new te("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:sg,construct:og,instanceOf:Date,represent:ng});function lg(e){return e==="<<"||e===null}y(lg,"resolveYamlMerge");var $S=new te("tag:yaml.org,2002:merge",{kind:"scalar",resolve:lg}),Ah=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
130
+ \r`;function hg(e){if(e===null)return!1;var t,r,i=0,a=e.length,s=Ah;for(r=0;r<a;r++)if(t=s.indexOf(e.charAt(r)),!(t>64)){if(t<0)return!1;i+=6}return i%8===0}y(hg,"resolveYamlBinary");function cg(e){var t,r,i=e.replace(/[\r\n=]/g,""),a=i.length,s=Ah,o=0,n=[];for(t=0;t<a;t++)t%4===0&&t&&(n.push(o>>16&255),n.push(o>>8&255),n.push(o&255)),o=o<<6|s.indexOf(i.charAt(t));return r=a%4*6,r===0?(n.push(o>>16&255),n.push(o>>8&255),n.push(o&255)):r===18?(n.push(o>>10&255),n.push(o>>2&255)):r===12&&n.push(o>>4&255),new Uint8Array(n)}y(cg,"constructYamlBinary");function ug(e){var t="",r=0,i,a,s=e.length,o=Ah;for(i=0;i<s;i++)i%3===0&&i&&(t+=o[r>>18&63],t+=o[r>>12&63],t+=o[r>>6&63],t+=o[r&63]),r=(r<<8)+e[i];return a=s%3,a===0?(t+=o[r>>18&63],t+=o[r>>12&63],t+=o[r>>6&63],t+=o[r&63]):a===2?(t+=o[r>>10&63],t+=o[r>>4&63],t+=o[r<<2&63],t+=o[64]):a===1&&(t+=o[r>>2&63],t+=o[r<<4&63],t+=o[64],t+=o[64]),t}y(ug,"representYamlBinary");function dg(e){return Object.prototype.toString.call(e)==="[object Uint8Array]"}y(dg,"isBinary");var DS=new te("tag:yaml.org,2002:binary",{kind:"scalar",resolve:hg,construct:cg,predicate:dg,represent:ug}),OS=Object.prototype.hasOwnProperty,IS=Object.prototype.toString;function fg(e){if(e===null)return!0;var t=[],r,i,a,s,o,n=e;for(r=0,i=n.length;r<i;r+=1){if(a=n[r],o=!1,IS.call(a)!=="[object Object]")return!1;for(s in a)if(OS.call(a,s))if(!o)o=!0;else return!1;if(!o)return!1;if(t.indexOf(s)===-1)t.push(s);else return!1}return!0}y(fg,"resolveYamlOmap");function pg(e){return e!==null?e:[]}y(pg,"constructYamlOmap");var PS=new te("tag:yaml.org,2002:omap",{kind:"sequence",resolve:fg,construct:pg}),RS=Object.prototype.toString;function gg(e){if(e===null)return!0;var t,r,i,a,s,o=e;for(s=new Array(o.length),t=0,r=o.length;t<r;t+=1){if(i=o[t],RS.call(i)!=="[object Object]"||(a=Object.keys(i),a.length!==1))return!1;s[t]=[a[0],i[a[0]]]}return!0}y(gg,"resolveYamlPairs");function mg(e){if(e===null)return[];var t,r,i,a,s,o=e;for(s=new Array(o.length),t=0,r=o.length;t<r;t+=1)i=o[t],a=Object.keys(i),s[t]=[a[0],i[a[0]]];return s}y(mg,"constructYamlPairs");var NS=new te("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:gg,construct:mg}),qS=Object.prototype.hasOwnProperty;function yg(e){if(e===null)return!0;var t,r=e;for(t in r)if(qS.call(r,t)&&r[t]!==null)return!1;return!0}y(yg,"resolveYamlSet");function Cg(e){return e!==null?e:{}}y(Cg,"constructYamlSet");var zS=new te("tag:yaml.org,2002:set",{kind:"mapping",resolve:yg,construct:Cg}),xg=AS.extend({implicit:[ES,$S],explicit:[DS,PS,NS,zS]}),br=Object.prototype.hasOwnProperty,mo=1,bg=2,kg=3,yo=4,Nn=1,WS=2,Eu=3,HS=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,US=/[\x85\u2028\u2029]/,YS=/[,\[\]\{\}]/,Tg=/^(?:!|!!|![a-z\-]+!)$/i,wg=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function kl(e){return Object.prototype.toString.call(e)}y(kl,"_class");function Le(e){return e===10||e===13}y(Le,"is_EOL");function Cr(e){return e===9||e===32}y(Cr,"is_WHITE_SPACE");function ie(e){return e===9||e===32||e===10||e===13}y(ie,"is_WS_OR_EOL");function Dr(e){return e===44||e===91||e===93||e===123||e===125}y(Dr,"is_FLOW_INDICATOR");function _g(e){var t;return 48<=e&&e<=57?e-48:(t=e|32,97<=t&&t<=102?t-97+10:-1)}y(_g,"fromHexCode");function Sg(e){return e===120?2:e===117?4:e===85?8:0}y(Sg,"escapedHexLen");function vg(e){return 48<=e&&e<=57?e-48:-1}y(vg,"fromDecimalCode");function Tl(e){return e===48?"\0":e===97?"\x07":e===98?"\b":e===116||e===9?" ":e===110?`
131
+ `:e===118?"\v":e===102?"\f":e===114?"\r":e===101?"\x1B":e===32?" ":e===34?'"':e===47?"/":e===92?"\\":e===78?"…":e===95?" ":e===76?"\u2028":e===80?"\u2029":""}y(Tl,"simpleEscapeSequence");function Bg(e){return e<=65535?String.fromCharCode(e):String.fromCharCode((e-65536>>10)+55296,(e-65536&1023)+56320)}y(Bg,"charFromCodepoint");function Eh(e,t,r){t==="__proto__"?Object.defineProperty(e,t,{configurable:!0,enumerable:!0,writable:!0,value:r}):e[t]=r}y(Eh,"setProperty");var Lg=new Array(256),Fg=new Array(256);for(Br=0;Br<256;Br++)Lg[Br]=Tl(Br)?1:0,Fg[Br]=Tl(Br);var Br;function Mg(e,t){this.input=e,this.filename=t.filename||null,this.schema=t.schema||xg,this.onWarning=t.onWarning||null,this.legacy=t.legacy||!1,this.json=t.json||!1,this.listener=t.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}y(Mg,"State$1");function $h(e,t){var r={name:e.filename,buffer:e.input.slice(0,-1),position:e.position,line:e.line,column:e.position-e.lineStart};return r.snippet=yS(r),new ue(t,r)}y($h,"generateError");function it(e,t){throw $h(e,t)}y(it,"throwError");function Oa(e,t){e.onWarning&&e.onWarning.call(null,$h(e,t))}y(Oa,"throwWarning");var $u={YAML:y(function(t,r,i){var a,s,o;t.version!==null&&it(t,"duplication of %YAML directive"),i.length!==1&&it(t,"YAML directive accepts exactly one argument"),a=/^([0-9]+)\.([0-9]+)$/.exec(i[0]),a===null&&it(t,"ill-formed argument of the YAML directive"),s=parseInt(a[1],10),o=parseInt(a[2],10),s!==1&&it(t,"unacceptable YAML version of the document"),t.version=i[0],t.checkLineBreaks=o<2,o!==1&&o!==2&&Oa(t,"unsupported YAML version of the document")},"handleYamlDirective"),TAG:y(function(t,r,i){var a,s;i.length!==2&&it(t,"TAG directive accepts exactly two arguments"),a=i[0],s=i[1],Tg.test(a)||it(t,"ill-formed tag handle (first argument) of the TAG directive"),br.call(t.tagMap,a)&&it(t,'there is a previously declared suffix for "'+a+'" tag handle'),wg.test(s)||it(t,"ill-formed tag prefix (second argument) of the TAG directive");try{s=decodeURIComponent(s)}catch{it(t,"tag prefix is malformed: "+s)}t.tagMap[a]=s},"handleTagDirective")};function sr(e,t,r,i){var a,s,o,n;if(t<r){if(n=e.input.slice(t,r),i)for(a=0,s=n.length;a<s;a+=1)o=n.charCodeAt(a),o===9||32<=o&&o<=1114111||it(e,"expected valid JSON character");else HS.test(n)&&it(e,"the stream contains non-printable characters");e.result+=n}}y(sr,"captureSegment");function wl(e,t,r,i){var a,s,o,n;for(zt.isObject(r)||it(e,"cannot merge mappings; the provided source object is unacceptable"),a=Object.keys(r),o=0,n=a.length;o<n;o+=1)s=a[o],br.call(t,s)||(Eh(t,s,r[s]),i[s]=!0)}y(wl,"mergeMappings");function Or(e,t,r,i,a,s,o,n,l){var h,c;if(Array.isArray(a))for(a=Array.prototype.slice.call(a),h=0,c=a.length;h<c;h+=1)Array.isArray(a[h])&&it(e,"nested arrays are not supported inside keys"),typeof a=="object"&&kl(a[h])==="[object Object]"&&(a[h]="[object Object]");if(typeof a=="object"&&kl(a)==="[object Object]"&&(a="[object Object]"),a=String(a),t===null&&(t={}),i==="tag:yaml.org,2002:merge")if(Array.isArray(s))for(h=0,c=s.length;h<c;h+=1)wl(e,t,s[h],r);else wl(e,t,s,r);else!e.json&&!br.call(r,a)&&br.call(t,a)&&(e.line=o||e.line,e.lineStart=n||e.lineStart,e.position=l||e.position,it(e,"duplicated mapping key")),Eh(t,a,s),delete r[a];return t}y(Or,"storeMappingPair");function Go(e){var t;t=e.input.charCodeAt(e.position),t===10?e.position++:t===13?(e.position++,e.input.charCodeAt(e.position)===10&&e.position++):it(e,"a line break is expected"),e.line+=1,e.lineStart=e.position,e.firstTabInLine=-1}y(Go,"readLineBreak");function Dt(e,t,r){for(var i=0,a=e.input.charCodeAt(e.position);a!==0;){for(;Cr(a);)a===9&&e.firstTabInLine===-1&&(e.firstTabInLine=e.position),a=e.input.charCodeAt(++e.position);if(t&&a===35)do a=e.input.charCodeAt(++e.position);while(a!==10&&a!==13&&a!==0);if(Le(a))for(Go(e),a=e.input.charCodeAt(e.position),i++,e.lineIndent=0;a===32;)e.lineIndent++,a=e.input.charCodeAt(++e.position);else break}return r!==-1&&i!==0&&e.lineIndent<r&&Oa(e,"deficient indentation"),i}y(Dt,"skipSeparationSpace");function Va(e){var t=e.position,r;return r=e.input.charCodeAt(t),!!((r===45||r===46)&&r===e.input.charCodeAt(t+1)&&r===e.input.charCodeAt(t+2)&&(t+=3,r=e.input.charCodeAt(t),r===0||ie(r)))}y(Va,"testDocumentSeparator");function Xo(e,t){t===1?e.result+=" ":t>1&&(e.result+=zt.repeat(`
132
+ `,t-1))}y(Xo,"writeFoldedLines");function Ag(e,t,r){var i,a,s,o,n,l,h,c,u=e.kind,f=e.result,d;if(d=e.input.charCodeAt(e.position),ie(d)||Dr(d)||d===35||d===38||d===42||d===33||d===124||d===62||d===39||d===34||d===37||d===64||d===96||(d===63||d===45)&&(a=e.input.charCodeAt(e.position+1),ie(a)||r&&Dr(a)))return!1;for(e.kind="scalar",e.result="",s=o=e.position,n=!1;d!==0;){if(d===58){if(a=e.input.charCodeAt(e.position+1),ie(a)||r&&Dr(a))break}else if(d===35){if(i=e.input.charCodeAt(e.position-1),ie(i))break}else{if(e.position===e.lineStart&&Va(e)||r&&Dr(d))break;if(Le(d))if(l=e.line,h=e.lineStart,c=e.lineIndent,Dt(e,!1,-1),e.lineIndent>=t){n=!0,d=e.input.charCodeAt(e.position);continue}else{e.position=o,e.line=l,e.lineStart=h,e.lineIndent=c;break}}n&&(sr(e,s,o,!1),Xo(e,e.line-l),s=o=e.position,n=!1),Cr(d)||(o=e.position+1),d=e.input.charCodeAt(++e.position)}return sr(e,s,o,!1),e.result?!0:(e.kind=u,e.result=f,!1)}y(Ag,"readPlainScalar");function Eg(e,t){var r,i,a;if(r=e.input.charCodeAt(e.position),r!==39)return!1;for(e.kind="scalar",e.result="",e.position++,i=a=e.position;(r=e.input.charCodeAt(e.position))!==0;)if(r===39)if(sr(e,i,e.position,!0),r=e.input.charCodeAt(++e.position),r===39)i=e.position,e.position++,a=e.position;else return!0;else Le(r)?(sr(e,i,a,!0),Xo(e,Dt(e,!1,t)),i=a=e.position):e.position===e.lineStart&&Va(e)?it(e,"unexpected end of the document within a single quoted scalar"):(e.position++,a=e.position);it(e,"unexpected end of the stream within a single quoted scalar")}y(Eg,"readSingleQuotedScalar");function $g(e,t){var r,i,a,s,o,n;if(n=e.input.charCodeAt(e.position),n!==34)return!1;for(e.kind="scalar",e.result="",e.position++,r=i=e.position;(n=e.input.charCodeAt(e.position))!==0;){if(n===34)return sr(e,r,e.position,!0),e.position++,!0;if(n===92){if(sr(e,r,e.position,!0),n=e.input.charCodeAt(++e.position),Le(n))Dt(e,!1,t);else if(n<256&&Lg[n])e.result+=Fg[n],e.position++;else if((o=Sg(n))>0){for(a=o,s=0;a>0;a--)n=e.input.charCodeAt(++e.position),(o=_g(n))>=0?s=(s<<4)+o:it(e,"expected hexadecimal character");e.result+=Bg(s),e.position++}else it(e,"unknown escape sequence");r=i=e.position}else Le(n)?(sr(e,r,i,!0),Xo(e,Dt(e,!1,t)),r=i=e.position):e.position===e.lineStart&&Va(e)?it(e,"unexpected end of the document within a double quoted scalar"):(e.position++,i=e.position)}it(e,"unexpected end of the stream within a double quoted scalar")}y($g,"readDoubleQuotedScalar");function Dg(e,t){var r=!0,i,a,s,o=e.tag,n,l=e.anchor,h,c,u,f,d,p=Object.create(null),g,m,C,x;if(x=e.input.charCodeAt(e.position),x===91)c=93,d=!1,n=[];else if(x===123)c=125,d=!0,n={};else return!1;for(e.anchor!==null&&(e.anchorMap[e.anchor]=n),x=e.input.charCodeAt(++e.position);x!==0;){if(Dt(e,!0,t),x=e.input.charCodeAt(e.position),x===c)return e.position++,e.tag=o,e.anchor=l,e.kind=d?"mapping":"sequence",e.result=n,!0;r?x===44&&it(e,"expected the node content, but found ','"):it(e,"missed comma between flow collection entries"),m=g=C=null,u=f=!1,x===63&&(h=e.input.charCodeAt(e.position+1),ie(h)&&(u=f=!0,e.position++,Dt(e,!0,t))),i=e.line,a=e.lineStart,s=e.position,Hr(e,t,mo,!1,!0),m=e.tag,g=e.result,Dt(e,!0,t),x=e.input.charCodeAt(e.position),(f||e.line===i)&&x===58&&(u=!0,x=e.input.charCodeAt(++e.position),Dt(e,!0,t),Hr(e,t,mo,!1,!0),C=e.result),d?Or(e,n,p,m,g,C,i,a,s):u?n.push(Or(e,null,p,m,g,C,i,a,s)):n.push(g),Dt(e,!0,t),x=e.input.charCodeAt(e.position),x===44?(r=!0,x=e.input.charCodeAt(++e.position)):r=!1}it(e,"unexpected end of the stream within a flow collection")}y(Dg,"readFlowCollection");function Og(e,t){var r,i,a=Nn,s=!1,o=!1,n=t,l=0,h=!1,c,u;if(u=e.input.charCodeAt(e.position),u===124)i=!1;else if(u===62)i=!0;else return!1;for(e.kind="scalar",e.result="";u!==0;)if(u=e.input.charCodeAt(++e.position),u===43||u===45)Nn===a?a=u===43?Eu:WS:it(e,"repeat of a chomping mode identifier");else if((c=vg(u))>=0)c===0?it(e,"bad explicit indentation width of a block scalar; it cannot be less than one"):o?it(e,"repeat of an indentation width identifier"):(n=t+c-1,o=!0);else break;if(Cr(u)){do u=e.input.charCodeAt(++e.position);while(Cr(u));if(u===35)do u=e.input.charCodeAt(++e.position);while(!Le(u)&&u!==0)}for(;u!==0;){for(Go(e),e.lineIndent=0,u=e.input.charCodeAt(e.position);(!o||e.lineIndent<n)&&u===32;)e.lineIndent++,u=e.input.charCodeAt(++e.position);if(!o&&e.lineIndent>n&&(n=e.lineIndent),Le(u)){l++;continue}if(e.lineIndent<n){a===Eu?e.result+=zt.repeat(`
133
+ `,s?1+l:l):a===Nn&&s&&(e.result+=`
134
+ `);break}for(i?Cr(u)?(h=!0,e.result+=zt.repeat(`
135
+ `,s?1+l:l)):h?(h=!1,e.result+=zt.repeat(`
136
+ `,l+1)):l===0?s&&(e.result+=" "):e.result+=zt.repeat(`
137
+ `,l):e.result+=zt.repeat(`
138
+ `,s?1+l:l),s=!0,o=!0,l=0,r=e.position;!Le(u)&&u!==0;)u=e.input.charCodeAt(++e.position);sr(e,r,e.position,!1)}return!0}y(Og,"readBlockScalar");function _l(e,t){var r,i=e.tag,a=e.anchor,s=[],o,n=!1,l;if(e.firstTabInLine!==-1)return!1;for(e.anchor!==null&&(e.anchorMap[e.anchor]=s),l=e.input.charCodeAt(e.position);l!==0&&(e.firstTabInLine!==-1&&(e.position=e.firstTabInLine,it(e,"tab characters must not be used in indentation")),!(l!==45||(o=e.input.charCodeAt(e.position+1),!ie(o))));){if(n=!0,e.position++,Dt(e,!0,-1)&&e.lineIndent<=t){s.push(null),l=e.input.charCodeAt(e.position);continue}if(r=e.line,Hr(e,t,kg,!1,!0),s.push(e.result),Dt(e,!0,-1),l=e.input.charCodeAt(e.position),(e.line===r||e.lineIndent>t)&&l!==0)it(e,"bad indentation of a sequence entry");else if(e.lineIndent<t)break}return n?(e.tag=i,e.anchor=a,e.kind="sequence",e.result=s,!0):!1}y(_l,"readBlockSequence");function Ig(e,t,r){var i,a,s,o,n,l,h=e.tag,c=e.anchor,u={},f=Object.create(null),d=null,p=null,g=null,m=!1,C=!1,x;if(e.firstTabInLine!==-1)return!1;for(e.anchor!==null&&(e.anchorMap[e.anchor]=u),x=e.input.charCodeAt(e.position);x!==0;){if(!m&&e.firstTabInLine!==-1&&(e.position=e.firstTabInLine,it(e,"tab characters must not be used in indentation")),i=e.input.charCodeAt(e.position+1),s=e.line,(x===63||x===58)&&ie(i))x===63?(m&&(Or(e,u,f,d,p,null,o,n,l),d=p=g=null),C=!0,m=!0,a=!0):m?(m=!1,a=!0):it(e,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),e.position+=1,x=i;else{if(o=e.line,n=e.lineStart,l=e.position,!Hr(e,r,bg,!1,!0))break;if(e.line===s){for(x=e.input.charCodeAt(e.position);Cr(x);)x=e.input.charCodeAt(++e.position);if(x===58)x=e.input.charCodeAt(++e.position),ie(x)||it(e,"a whitespace character is expected after the key-value separator within a block mapping"),m&&(Or(e,u,f,d,p,null,o,n,l),d=p=g=null),C=!0,m=!1,a=!1,d=e.tag,p=e.result;else if(C)it(e,"can not read an implicit mapping pair; a colon is missed");else return e.tag=h,e.anchor=c,!0}else if(C)it(e,"can not read a block mapping entry; a multiline key may not be an implicit key");else return e.tag=h,e.anchor=c,!0}if((e.line===s||e.lineIndent>t)&&(m&&(o=e.line,n=e.lineStart,l=e.position),Hr(e,t,yo,!0,a)&&(m?p=e.result:g=e.result),m||(Or(e,u,f,d,p,g,o,n,l),d=p=g=null),Dt(e,!0,-1),x=e.input.charCodeAt(e.position)),(e.line===s||e.lineIndent>t)&&x!==0)it(e,"bad indentation of a mapping entry");else if(e.lineIndent<t)break}return m&&Or(e,u,f,d,p,null,o,n,l),C&&(e.tag=h,e.anchor=c,e.kind="mapping",e.result=u),C}y(Ig,"readBlockMapping");function Pg(e){var t,r=!1,i=!1,a,s,o;if(o=e.input.charCodeAt(e.position),o!==33)return!1;if(e.tag!==null&&it(e,"duplication of a tag property"),o=e.input.charCodeAt(++e.position),o===60?(r=!0,o=e.input.charCodeAt(++e.position)):o===33?(i=!0,a="!!",o=e.input.charCodeAt(++e.position)):a="!",t=e.position,r){do o=e.input.charCodeAt(++e.position);while(o!==0&&o!==62);e.position<e.length?(s=e.input.slice(t,e.position),o=e.input.charCodeAt(++e.position)):it(e,"unexpected end of the stream within a verbatim tag")}else{for(;o!==0&&!ie(o);)o===33&&(i?it(e,"tag suffix cannot contain exclamation marks"):(a=e.input.slice(t-1,e.position+1),Tg.test(a)||it(e,"named tag handle cannot contain such characters"),i=!0,t=e.position+1)),o=e.input.charCodeAt(++e.position);s=e.input.slice(t,e.position),YS.test(s)&&it(e,"tag suffix cannot contain flow indicator characters")}s&&!wg.test(s)&&it(e,"tag name cannot contain such characters: "+s);try{s=decodeURIComponent(s)}catch{it(e,"tag name is malformed: "+s)}return r?e.tag=s:br.call(e.tagMap,a)?e.tag=e.tagMap[a]+s:a==="!"?e.tag="!"+s:a==="!!"?e.tag="tag:yaml.org,2002:"+s:it(e,'undeclared tag handle "'+a+'"'),!0}y(Pg,"readTagProperty");function Rg(e){var t,r;if(r=e.input.charCodeAt(e.position),r!==38)return!1;for(e.anchor!==null&&it(e,"duplication of an anchor property"),r=e.input.charCodeAt(++e.position),t=e.position;r!==0&&!ie(r)&&!Dr(r);)r=e.input.charCodeAt(++e.position);return e.position===t&&it(e,"name of an anchor node must contain at least one character"),e.anchor=e.input.slice(t,e.position),!0}y(Rg,"readAnchorProperty");function Ng(e){var t,r,i;if(i=e.input.charCodeAt(e.position),i!==42)return!1;for(i=e.input.charCodeAt(++e.position),t=e.position;i!==0&&!ie(i)&&!Dr(i);)i=e.input.charCodeAt(++e.position);return e.position===t&&it(e,"name of an alias node must contain at least one character"),r=e.input.slice(t,e.position),br.call(e.anchorMap,r)||it(e,'unidentified alias "'+r+'"'),e.result=e.anchorMap[r],Dt(e,!0,-1),!0}y(Ng,"readAlias");function Hr(e,t,r,i,a){var s,o,n,l=1,h=!1,c=!1,u,f,d,p,g,m;if(e.listener!==null&&e.listener("open",e),e.tag=null,e.anchor=null,e.kind=null,e.result=null,s=o=n=yo===r||kg===r,i&&Dt(e,!0,-1)&&(h=!0,e.lineIndent>t?l=1:e.lineIndent===t?l=0:e.lineIndent<t&&(l=-1)),l===1)for(;Pg(e)||Rg(e);)Dt(e,!0,-1)?(h=!0,n=s,e.lineIndent>t?l=1:e.lineIndent===t?l=0:e.lineIndent<t&&(l=-1)):n=!1;if(n&&(n=h||a),(l===1||yo===r)&&(mo===r||bg===r?g=t:g=t+1,m=e.position-e.lineStart,l===1?n&&(_l(e,m)||Ig(e,m,g))||Dg(e,g)?c=!0:(o&&Og(e,g)||Eg(e,g)||$g(e,g)?c=!0:Ng(e)?(c=!0,(e.tag!==null||e.anchor!==null)&&it(e,"alias node should not have any properties")):Ag(e,g,mo===r)&&(c=!0,e.tag===null&&(e.tag="?")),e.anchor!==null&&(e.anchorMap[e.anchor]=e.result)):l===0&&(c=n&&_l(e,m))),e.tag===null)e.anchor!==null&&(e.anchorMap[e.anchor]=e.result);else if(e.tag==="?"){for(e.result!==null&&e.kind!=="scalar"&&it(e,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+e.kind+'"'),u=0,f=e.implicitTypes.length;u<f;u+=1)if(p=e.implicitTypes[u],p.resolve(e.result)){e.result=p.construct(e.result),e.tag=p.tag,e.anchor!==null&&(e.anchorMap[e.anchor]=e.result);break}}else if(e.tag!=="!"){if(br.call(e.typeMap[e.kind||"fallback"],e.tag))p=e.typeMap[e.kind||"fallback"][e.tag];else for(p=null,d=e.typeMap.multi[e.kind||"fallback"],u=0,f=d.length;u<f;u+=1)if(e.tag.slice(0,d[u].tag.length)===d[u].tag){p=d[u];break}p||it(e,"unknown tag !<"+e.tag+">"),e.result!==null&&p.kind!==e.kind&&it(e,"unacceptable node kind for !<"+e.tag+'> tag; it should be "'+p.kind+'", not "'+e.kind+'"'),p.resolve(e.result,e.tag)?(e.result=p.construct(e.result,e.tag),e.anchor!==null&&(e.anchorMap[e.anchor]=e.result)):it(e,"cannot resolve a node with !<"+e.tag+"> explicit tag")}return e.listener!==null&&e.listener("close",e),e.tag!==null||e.anchor!==null||c}y(Hr,"composeNode");function qg(e){var t=e.position,r,i,a,s=!1,o;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap=Object.create(null),e.anchorMap=Object.create(null);(o=e.input.charCodeAt(e.position))!==0&&(Dt(e,!0,-1),o=e.input.charCodeAt(e.position),!(e.lineIndent>0||o!==37));){for(s=!0,o=e.input.charCodeAt(++e.position),r=e.position;o!==0&&!ie(o);)o=e.input.charCodeAt(++e.position);for(i=e.input.slice(r,e.position),a=[],i.length<1&&it(e,"directive name must not be less than one character in length");o!==0;){for(;Cr(o);)o=e.input.charCodeAt(++e.position);if(o===35){do o=e.input.charCodeAt(++e.position);while(o!==0&&!Le(o));break}if(Le(o))break;for(r=e.position;o!==0&&!ie(o);)o=e.input.charCodeAt(++e.position);a.push(e.input.slice(r,e.position))}o!==0&&Go(e),br.call($u,i)?$u[i](e,i,a):Oa(e,'unknown document directive "'+i+'"')}if(Dt(e,!0,-1),e.lineIndent===0&&e.input.charCodeAt(e.position)===45&&e.input.charCodeAt(e.position+1)===45&&e.input.charCodeAt(e.position+2)===45?(e.position+=3,Dt(e,!0,-1)):s&&it(e,"directives end mark is expected"),Hr(e,e.lineIndent-1,yo,!1,!0),Dt(e,!0,-1),e.checkLineBreaks&&US.test(e.input.slice(t,e.position))&&Oa(e,"non-ASCII line breaks are interpreted as content"),e.documents.push(e.result),e.position===e.lineStart&&Va(e)){e.input.charCodeAt(e.position)===46&&(e.position+=3,Dt(e,!0,-1));return}if(e.position<e.length-1)it(e,"end of the stream or a document separator is expected");else return}y(qg,"readDocument");function Dh(e,t){e=String(e),t=t||{},e.length!==0&&(e.charCodeAt(e.length-1)!==10&&e.charCodeAt(e.length-1)!==13&&(e+=`
139
+ `),e.charCodeAt(0)===65279&&(e=e.slice(1)));var r=new Mg(e,t),i=e.indexOf("\0");for(i!==-1&&(r.position=i,it(r,"null byte is not allowed in input")),r.input+="\0";r.input.charCodeAt(r.position)===32;)r.lineIndent+=1,r.position+=1;for(;r.position<r.length-1;)qg(r);return r.documents}y(Dh,"loadDocuments");function jS(e,t,r){t!==null&&typeof t=="object"&&typeof r>"u"&&(r=t,t=null);var i=Dh(e,r);if(typeof t!="function")return i;for(var a=0,s=i.length;a<s;a+=1)t(i[a])}y(jS,"loadAll$1");function zg(e,t){var r=Dh(e,t);if(r.length!==0){if(r.length===1)return r[0];throw new ue("expected a single document in the stream, but found more")}}y(zg,"load$1");var GS=zg,XS={load:GS},Wg=Object.prototype.toString,Hg=Object.prototype.hasOwnProperty,Oh=65279,VS=9,Ia=10,ZS=13,QS=32,KS=33,JS=34,Sl=35,tv=37,ev=38,rv=39,iv=42,Ug=44,av=45,Co=58,sv=61,ov=62,nv=63,lv=64,Yg=91,jg=93,hv=96,Gg=123,cv=124,Xg=125,ee={};ee[0]="\\0";ee[7]="\\a";ee[8]="\\b";ee[9]="\\t";ee[10]="\\n";ee[11]="\\v";ee[12]="\\f";ee[13]="\\r";ee[27]="\\e";ee[34]='\\"';ee[92]="\\\\";ee[133]="\\N";ee[160]="\\_";ee[8232]="\\L";ee[8233]="\\P";var uv=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],dv=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function Vg(e,t){var r,i,a,s,o,n,l;if(t===null)return{};for(r={},i=Object.keys(t),a=0,s=i.length;a<s;a+=1)o=i[a],n=String(t[o]),o.slice(0,2)==="!!"&&(o="tag:yaml.org,2002:"+o.slice(2)),l=e.compiledTypeMap.fallback[o],l&&Hg.call(l.styleAliases,n)&&(n=l.styleAliases[n]),r[o]=n;return r}y(Vg,"compileStyleMap");function Zg(e){var t,r,i;if(t=e.toString(16).toUpperCase(),e<=255)r="x",i=2;else if(e<=65535)r="u",i=4;else if(e<=4294967295)r="U",i=8;else throw new ue("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+r+zt.repeat("0",i-t.length)+t}y(Zg,"encodeHex");var fv=1,Pa=2;function Qg(e){this.schema=e.schema||xg,this.indent=Math.max(1,e.indent||2),this.noArrayIndent=e.noArrayIndent||!1,this.skipInvalid=e.skipInvalid||!1,this.flowLevel=zt.isNothing(e.flowLevel)?-1:e.flowLevel,this.styleMap=Vg(this.schema,e.styles||null),this.sortKeys=e.sortKeys||!1,this.lineWidth=e.lineWidth||80,this.noRefs=e.noRefs||!1,this.noCompatMode=e.noCompatMode||!1,this.condenseFlow=e.condenseFlow||!1,this.quotingType=e.quotingType==='"'?Pa:fv,this.forceQuotes=e.forceQuotes||!1,this.replacer=typeof e.replacer=="function"?e.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}y(Qg,"State");function vl(e,t){for(var r=zt.repeat(" ",t),i=0,a=-1,s="",o,n=e.length;i<n;)a=e.indexOf(`
140
+ `,i),a===-1?(o=e.slice(i),i=n):(o=e.slice(i,a+1),i=a+1),o.length&&o!==`
141
+ `&&(s+=r),s+=o;return s}y(vl,"indentString");function xo(e,t){return`
142
+ `+zt.repeat(" ",e.indent*t)}y(xo,"generateNextLine");function Kg(e,t){var r,i,a;for(r=0,i=e.implicitTypes.length;r<i;r+=1)if(a=e.implicitTypes[r],a.resolve(t))return!0;return!1}y(Kg,"testImplicitResolving");function Ra(e){return e===QS||e===VS}y(Ra,"isWhitespace");function zi(e){return 32<=e&&e<=126||161<=e&&e<=55295&&e!==8232&&e!==8233||57344<=e&&e<=65533&&e!==Oh||65536<=e&&e<=1114111}y(zi,"isPrintable");function Bl(e){return zi(e)&&e!==Oh&&e!==ZS&&e!==Ia}y(Bl,"isNsCharOrWhitespace");function Ll(e,t,r){var i=Bl(e),a=i&&!Ra(e);return(r?i:i&&e!==Ug&&e!==Yg&&e!==jg&&e!==Gg&&e!==Xg)&&e!==Sl&&!(t===Co&&!a)||Bl(t)&&!Ra(t)&&e===Sl||t===Co&&a}y(Ll,"isPlainSafe");function Jg(e){return zi(e)&&e!==Oh&&!Ra(e)&&e!==av&&e!==nv&&e!==Co&&e!==Ug&&e!==Yg&&e!==jg&&e!==Gg&&e!==Xg&&e!==Sl&&e!==ev&&e!==iv&&e!==KS&&e!==cv&&e!==sv&&e!==ov&&e!==rv&&e!==JS&&e!==tv&&e!==lv&&e!==hv}y(Jg,"isPlainSafeFirst");function tm(e){return!Ra(e)&&e!==Co}y(tm,"isPlainSafeLast");function pi(e,t){var r=e.charCodeAt(t),i;return r>=55296&&r<=56319&&t+1<e.length&&(i=e.charCodeAt(t+1),i>=56320&&i<=57343)?(r-55296)*1024+i-56320+65536:r}y(pi,"codePointAt");function Ih(e){var t=/^\n* /;return t.test(e)}y(Ih,"needIndentIndicator");var em=1,Fl=2,rm=3,im=4,li=5;function am(e,t,r,i,a,s,o,n){var l,h=0,c=null,u=!1,f=!1,d=i!==-1,p=-1,g=Jg(pi(e,0))&&tm(pi(e,e.length-1));if(t||o)for(l=0;l<e.length;h>=65536?l+=2:l++){if(h=pi(e,l),!zi(h))return li;g=g&&Ll(h,c,n),c=h}else{for(l=0;l<e.length;h>=65536?l+=2:l++){if(h=pi(e,l),h===Ia)u=!0,d&&(f=f||l-p-1>i&&e[p+1]!==" ",p=l);else if(!zi(h))return li;g=g&&Ll(h,c,n),c=h}f=f||d&&l-p-1>i&&e[p+1]!==" "}return!u&&!f?g&&!o&&!a(e)?em:s===Pa?li:Fl:r>9&&Ih(e)?li:o?s===Pa?li:Fl:f?im:rm}y(am,"chooseScalarStyle");function sm(e,t,r,i,a){e.dump=(function(){if(t.length===0)return e.quotingType===Pa?'""':"''";if(!e.noCompatMode&&(uv.indexOf(t)!==-1||dv.test(t)))return e.quotingType===Pa?'"'+t+'"':"'"+t+"'";var s=e.indent*Math.max(1,r),o=e.lineWidth===-1?-1:Math.max(Math.min(e.lineWidth,40),e.lineWidth-s),n=i||e.flowLevel>-1&&r>=e.flowLevel;function l(h){return Kg(e,h)}switch(y(l,"testAmbiguity"),am(t,n,e.indent,o,l,e.quotingType,e.forceQuotes&&!i,a)){case em:return t;case Fl:return"'"+t.replace(/'/g,"''")+"'";case rm:return"|"+Ml(t,e.indent)+Al(vl(t,s));case im:return">"+Ml(t,e.indent)+Al(vl(om(t,o),s));case li:return'"'+nm(t)+'"';default:throw new ue("impossible error: invalid scalar style")}})()}y(sm,"writeScalar");function Ml(e,t){var r=Ih(e)?String(t):"",i=e[e.length-1]===`
143
+ `,a=i&&(e[e.length-2]===`
144
+ `||e===`
145
+ `),s=a?"+":i?"":"-";return r+s+`
146
+ `}y(Ml,"blockHeader");function Al(e){return e[e.length-1]===`
147
+ `?e.slice(0,-1):e}y(Al,"dropEndingNewline");function om(e,t){for(var r=/(\n+)([^\n]*)/g,i=(function(){var h=e.indexOf(`
148
+ `);return h=h!==-1?h:e.length,r.lastIndex=h,El(e.slice(0,h),t)})(),a=e[0]===`
149
+ `||e[0]===" ",s,o;o=r.exec(e);){var n=o[1],l=o[2];s=l[0]===" ",i+=n+(!a&&!s&&l!==""?`
150
+ `:"")+El(l,t),a=s}return i}y(om,"foldString");function El(e,t){if(e===""||e[0]===" ")return e;for(var r=/ [^ ]/g,i,a=0,s,o=0,n=0,l="";i=r.exec(e);)n=i.index,n-a>t&&(s=o>a?o:n,l+=`
151
+ `+e.slice(a,s),a=s+1),o=n;return l+=`
152
+ `,e.length-a>t&&o>a?l+=e.slice(a,o)+`
153
+ `+e.slice(o+1):l+=e.slice(a),l.slice(1)}y(El,"foldLine");function nm(e){for(var t="",r=0,i,a=0;a<e.length;r>=65536?a+=2:a++)r=pi(e,a),i=ee[r],!i&&zi(r)?(t+=e[a],r>=65536&&(t+=e[a+1])):t+=i||Zg(r);return t}y(nm,"escapeString");function lm(e,t,r){var i="",a=e.tag,s,o,n;for(s=0,o=r.length;s<o;s+=1)n=r[s],e.replacer&&(n=e.replacer.call(r,String(s),n)),(He(e,t,n,!1,!1)||typeof n>"u"&&He(e,t,null,!1,!1))&&(i!==""&&(i+=","+(e.condenseFlow?"":" ")),i+=e.dump);e.tag=a,e.dump="["+i+"]"}y(lm,"writeFlowSequence");function $l(e,t,r,i){var a="",s=e.tag,o,n,l;for(o=0,n=r.length;o<n;o+=1)l=r[o],e.replacer&&(l=e.replacer.call(r,String(o),l)),(He(e,t+1,l,!0,!0,!1,!0)||typeof l>"u"&&He(e,t+1,null,!0,!0,!1,!0))&&((!i||a!=="")&&(a+=xo(e,t)),e.dump&&Ia===e.dump.charCodeAt(0)?a+="-":a+="- ",a+=e.dump);e.tag=s,e.dump=a||"[]"}y($l,"writeBlockSequence");function hm(e,t,r){var i="",a=e.tag,s=Object.keys(r),o,n,l,h,c;for(o=0,n=s.length;o<n;o+=1)c="",i!==""&&(c+=", "),e.condenseFlow&&(c+='"'),l=s[o],h=r[l],e.replacer&&(h=e.replacer.call(r,l,h)),He(e,t,l,!1,!1)&&(e.dump.length>1024&&(c+="? "),c+=e.dump+(e.condenseFlow?'"':"")+":"+(e.condenseFlow?"":" "),He(e,t,h,!1,!1)&&(c+=e.dump,i+=c));e.tag=a,e.dump="{"+i+"}"}y(hm,"writeFlowMapping");function cm(e,t,r,i){var a="",s=e.tag,o=Object.keys(r),n,l,h,c,u,f;if(e.sortKeys===!0)o.sort();else if(typeof e.sortKeys=="function")o.sort(e.sortKeys);else if(e.sortKeys)throw new ue("sortKeys must be a boolean or a function");for(n=0,l=o.length;n<l;n+=1)f="",(!i||a!=="")&&(f+=xo(e,t)),h=o[n],c=r[h],e.replacer&&(c=e.replacer.call(r,h,c)),He(e,t+1,h,!0,!0,!0)&&(u=e.tag!==null&&e.tag!=="?"||e.dump&&e.dump.length>1024,u&&(e.dump&&Ia===e.dump.charCodeAt(0)?f+="?":f+="? "),f+=e.dump,u&&(f+=xo(e,t)),He(e,t+1,c,!0,u)&&(e.dump&&Ia===e.dump.charCodeAt(0)?f+=":":f+=": ",f+=e.dump,a+=f));e.tag=s,e.dump=a||"{}"}y(cm,"writeBlockMapping");function Dl(e,t,r){var i,a,s,o,n,l;for(a=r?e.explicitTypes:e.implicitTypes,s=0,o=a.length;s<o;s+=1)if(n=a[s],(n.instanceOf||n.predicate)&&(!n.instanceOf||typeof t=="object"&&t instanceof n.instanceOf)&&(!n.predicate||n.predicate(t))){if(r?n.multi&&n.representName?e.tag=n.representName(t):e.tag=n.tag:e.tag="?",n.represent){if(l=e.styleMap[n.tag]||n.defaultStyle,Wg.call(n.represent)==="[object Function]")i=n.represent(t,l);else if(Hg.call(n.represent,l))i=n.represent[l](t,l);else throw new ue("!<"+n.tag+'> tag resolver accepts not "'+l+'" style');e.dump=i}return!0}return!1}y(Dl,"detectType");function He(e,t,r,i,a,s,o){e.tag=null,e.dump=r,Dl(e,r,!1)||Dl(e,r,!0);var n=Wg.call(e.dump),l=i,h;i&&(i=e.flowLevel<0||e.flowLevel>t);var c=n==="[object Object]"||n==="[object Array]",u,f;if(c&&(u=e.duplicates.indexOf(r),f=u!==-1),(e.tag!==null&&e.tag!=="?"||f||e.indent!==2&&t>0)&&(a=!1),f&&e.usedDuplicates[u])e.dump="*ref_"+u;else{if(c&&f&&!e.usedDuplicates[u]&&(e.usedDuplicates[u]=!0),n==="[object Object]")i&&Object.keys(e.dump).length!==0?(cm(e,t,e.dump,a),f&&(e.dump="&ref_"+u+e.dump)):(hm(e,t,e.dump),f&&(e.dump="&ref_"+u+" "+e.dump));else if(n==="[object Array]")i&&e.dump.length!==0?(e.noArrayIndent&&!o&&t>0?$l(e,t-1,e.dump,a):$l(e,t,e.dump,a),f&&(e.dump="&ref_"+u+e.dump)):(lm(e,t,e.dump),f&&(e.dump="&ref_"+u+" "+e.dump));else if(n==="[object String]")e.tag!=="?"&&sm(e,e.dump,t,s,l);else{if(n==="[object Undefined]")return!1;if(e.skipInvalid)return!1;throw new ue("unacceptable kind of an object to dump "+n)}e.tag!==null&&e.tag!=="?"&&(h=encodeURI(e.tag[0]==="!"?e.tag.slice(1):e.tag).replace(/!/g,"%21"),e.tag[0]==="!"?h="!"+h:h.slice(0,18)==="tag:yaml.org,2002:"?h="!!"+h.slice(18):h="!<"+h+">",e.dump=h+" "+e.dump)}return!0}y(He,"writeNode");function um(e,t){var r=[],i=[],a,s;for(bo(e,r,i),a=0,s=i.length;a<s;a+=1)t.duplicates.push(r[i[a]]);t.usedDuplicates=new Array(s)}y(um,"getDuplicateReferences");function bo(e,t,r){var i,a,s;if(e!==null&&typeof e=="object")if(a=t.indexOf(e),a!==-1)r.indexOf(a)===-1&&r.push(a);else if(t.push(e),Array.isArray(e))for(a=0,s=e.length;a<s;a+=1)bo(e[a],t,r);else for(i=Object.keys(e),a=0,s=i.length;a<s;a+=1)bo(e[i[a]],t,r)}y(bo,"inspectNode");function pv(e,t){t=t||{};var r=new Qg(t);r.noRefs||um(e,r);var i=e;return r.replacer&&(i=r.replacer.call({"":i},"",i)),He(r,0,i,!0,!0)?r.dump+`
154
+ `:""}y(pv,"dump$1");function gv(e,t){return function(){throw new Error("Function yaml."+e+" is removed in js-yaml 4. Use yaml."+t+" instead, which is now safe by default.")}}y(gv,"renamed");var mv=rg,yv=XS.load;/*! Bundled license information:
155
+
156
+ js-yaml/dist/js-yaml.mjs:
157
+ (*! js-yaml 4.1.1 https://github.com/nodeca/js-yaml @license MIT *)
158
+ */var la=y((e,t)=>{if(t)return"translate("+-e.width/2+", "+-e.height/2+")";const r=e.x??0,i=e.y??0;return"translate("+-(r+e.width/2)+", "+-(i+e.height/2)+")"},"computeLabelTransform"),Kt={aggregation:17.25,extension:17.25,composition:17.25,dependency:6,lollipop:13.5,arrow_point:4,arrow_barb:0,arrow_barb_neo:5.5},Du={arrow_point:4,arrow_cross:12.5,arrow_circle:12.5};function xa(e,t){if(e===void 0||t===void 0)return{angle:0,deltaX:0,deltaY:0};e=Mt(e),t=Mt(t);const[r,i]=[e.x,e.y],[a,s]=[t.x,t.y],o=a-r,n=s-i;return{angle:Math.atan(n/o),deltaX:o,deltaY:n}}y(xa,"calculateDeltaAndAngle");var Mt=y(e=>Array.isArray(e)?{x:e[0],y:e[1]}:e,"pointTransformer"),Cv=y(e=>({x:y(function(t,r,i){let a=0;const s=Mt(i[0]).x<Mt(i[i.length-1]).x?"left":"right";if(r===0&&Object.hasOwn(Kt,e.arrowTypeStart)){const{angle:d,deltaX:p}=xa(i[0],i[1]);a=Kt[e.arrowTypeStart]*Math.cos(d)*(p>=0?1:-1)}else if(r===i.length-1&&Object.hasOwn(Kt,e.arrowTypeEnd)){const{angle:d,deltaX:p}=xa(i[i.length-1],i[i.length-2]);a=Kt[e.arrowTypeEnd]*Math.cos(d)*(p>=0?1:-1)}const o=Math.abs(Mt(t).x-Mt(i[i.length-1]).x),n=Math.abs(Mt(t).y-Mt(i[i.length-1]).y),l=Math.abs(Mt(t).x-Mt(i[0]).x),h=Math.abs(Mt(t).y-Mt(i[0]).y),c=Kt[e.arrowTypeStart],u=Kt[e.arrowTypeEnd],f=1;if(o<u&&o>0&&n<u){let d=u+f-o;d*=s==="right"?-1:1,a-=d}if(l<c&&l>0&&h<c){let d=c+f-l;d*=s==="right"?-1:1,a+=d}return Mt(t).x+a},"x"),y:y(function(t,r,i){let a=0;const s=Mt(i[0]).y<Mt(i[i.length-1]).y?"down":"up";if(r===0&&Object.hasOwn(Kt,e.arrowTypeStart)){const{angle:d,deltaY:p}=xa(i[0],i[1]);a=Kt[e.arrowTypeStart]*Math.abs(Math.sin(d))*(p>=0?1:-1)}else if(r===i.length-1&&Object.hasOwn(Kt,e.arrowTypeEnd)){const{angle:d,deltaY:p}=xa(i[i.length-1],i[i.length-2]);a=Kt[e.arrowTypeEnd]*Math.abs(Math.sin(d))*(p>=0?1:-1)}const o=Math.abs(Mt(t).y-Mt(i[i.length-1]).y),n=Math.abs(Mt(t).x-Mt(i[i.length-1]).x),l=Math.abs(Mt(t).y-Mt(i[0]).y),h=Math.abs(Mt(t).x-Mt(i[0]).x),c=Kt[e.arrowTypeStart],u=Kt[e.arrowTypeEnd],f=1;if(o<u&&o>0&&n<u){let d=u+f-o;d*=s==="up"?-1:1,a-=d}if(l<c&&l>0&&h<c){let d=c+f-l;d*=s==="up"?-1:1,a+=d}return Mt(t).y+a},"y")}),"getLineFunctionsWithOffset"),ms={},Nt={},Ou;function xv(){return Ou||(Ou=1,Object.defineProperty(Nt,"__esModule",{value:!0}),Nt.BLANK_URL=Nt.relativeFirstCharacters=Nt.whitespaceEscapeCharsRegex=Nt.urlSchemeRegex=Nt.ctrlCharactersRegex=Nt.htmlCtrlEntityRegex=Nt.htmlEntitiesRegex=Nt.invalidProtocolRegex=void 0,Nt.invalidProtocolRegex=/^([^\w]*)(javascript|data|vbscript)/im,Nt.htmlEntitiesRegex=/&#(\w+)(^\w|;)?/g,Nt.htmlCtrlEntityRegex=/&(newline|tab);/gi,Nt.ctrlCharactersRegex=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim,Nt.urlSchemeRegex=/^.+(:|&colon;)/gim,Nt.whitespaceEscapeCharsRegex=/(\\|%5[cC])((%(6[eE]|72|74))|[nrt])/g,Nt.relativeFirstCharacters=[".","/"],Nt.BLANK_URL="about:blank"),Nt}var Iu;function bv(){if(Iu)return ms;Iu=1,Object.defineProperty(ms,"__esModule",{value:!0}),ms.sanitizeUrl=s;var e=xv();function t(o){return e.relativeFirstCharacters.indexOf(o[0])>-1}function r(o){var n=o.replace(e.ctrlCharactersRegex,"");return n.replace(e.htmlEntitiesRegex,function(l,h){return String.fromCharCode(h)})}function i(o){return URL.canParse(o)}function a(o){try{return decodeURIComponent(o)}catch{return o}}function s(o){if(!o)return e.BLANK_URL;var n,l=a(o.trim());do l=r(l).replace(e.htmlCtrlEntityRegex,"").replace(e.ctrlCharactersRegex,"").replace(e.whitespaceEscapeCharsRegex,"").trim(),l=a(l),n=l.match(e.ctrlCharactersRegex)||l.match(e.htmlEntitiesRegex)||l.match(e.htmlCtrlEntityRegex)||l.match(e.whitespaceEscapeCharsRegex);while(n&&n.length>0);var h=l;if(!h)return e.BLANK_URL;if(t(h))return h;var c=h.trimStart(),u=c.match(e.urlSchemeRegex);if(!u)return h;var f=u[0].toLowerCase().trim();if(e.invalidProtocolRegex.test(f))return e.BLANK_URL;var d=c.replace(/\\/g,"/");if(f==="mailto:"||f.includes("://"))return d;if(f==="http:"||f==="https:"){if(!i(d))return e.BLANK_URL;var p=new URL(d);return p.protocol=p.protocol.toLowerCase(),p.hostname=p.hostname.toLowerCase(),p.toString()}return d}return ms}var kv=bv(),dm=typeof global=="object"&&global&&global.Object===Object&&global,Tv=typeof self=="object"&&self&&self.Object===Object&&self,Ge=dm||Tv||Function("return this")(),ko=Ge.Symbol,fm=Object.prototype,wv=fm.hasOwnProperty,_v=fm.toString,ha=ko?ko.toStringTag:void 0;function Sv(e){var t=wv.call(e,ha),r=e[ha];try{e[ha]=void 0;var i=!0}catch{}var a=_v.call(e);return i&&(t?e[ha]=r:delete e[ha]),a}var vv=Object.prototype,Bv=vv.toString;function Lv(e){return Bv.call(e)}var Fv="[object Null]",Mv="[object Undefined]",Pu=ko?ko.toStringTag:void 0;function Ui(e){return e==null?e===void 0?Mv:Fv:Pu&&Pu in Object(e)?Sv(e):Lv(e)}function Qr(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Av="[object AsyncFunction]",Ev="[object Function]",$v="[object GeneratorFunction]",Dv="[object Proxy]";function Ph(e){if(!Qr(e))return!1;var t=Ui(e);return t==Ev||t==$v||t==Av||t==Dv}var qn=Ge["__core-js_shared__"],Ru=(function(){var e=/[^.]+$/.exec(qn&&qn.keys&&qn.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""})();function Ov(e){return!!Ru&&Ru in e}var Iv=Function.prototype,Pv=Iv.toString;function Kr(e){if(e!=null){try{return Pv.call(e)}catch{}try{return e+""}catch{}}return""}var Rv=/[\\^$.*+?()[\]{}|]/g,Nv=/^\[object .+?Constructor\]$/,qv=Function.prototype,zv=Object.prototype,Wv=qv.toString,Hv=zv.hasOwnProperty,Uv=RegExp("^"+Wv.call(Hv).replace(Rv,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Yv(e){if(!Qr(e)||Ov(e))return!1;var t=Ph(e)?Uv:Nv;return t.test(Kr(e))}function jv(e,t){return e==null?void 0:e[t]}function Jr(e,t){var r=jv(e,t);return Yv(r)?r:void 0}var Na=Jr(Object,"create");function Gv(){this.__data__=Na?Na(null):{},this.size=0}function Xv(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var Vv="__lodash_hash_undefined__",Zv=Object.prototype,Qv=Zv.hasOwnProperty;function Kv(e){var t=this.__data__;if(Na){var r=t[e];return r===Vv?void 0:r}return Qv.call(t,e)?t[e]:void 0}var Jv=Object.prototype,tB=Jv.hasOwnProperty;function eB(e){var t=this.__data__;return Na?t[e]!==void 0:tB.call(t,e)}var rB="__lodash_hash_undefined__";function iB(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=Na&&t===void 0?rB:t,this}function Ur(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}Ur.prototype.clear=Gv;Ur.prototype.delete=Xv;Ur.prototype.get=Kv;Ur.prototype.has=eB;Ur.prototype.set=iB;function aB(){this.__data__=[],this.size=0}function Vo(e,t){return e===t||e!==e&&t!==t}function Zo(e,t){for(var r=e.length;r--;)if(Vo(e[r][0],t))return r;return-1}var sB=Array.prototype,oB=sB.splice;function nB(e){var t=this.__data__,r=Zo(t,e);if(r<0)return!1;var i=t.length-1;return r==i?t.pop():oB.call(t,r,1),--this.size,!0}function lB(e){var t=this.__data__,r=Zo(t,e);return r<0?void 0:t[r][1]}function hB(e){return Zo(this.__data__,e)>-1}function cB(e,t){var r=this.__data__,i=Zo(r,e);return i<0?(++this.size,r.push([e,t])):r[i][1]=t,this}function ur(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}ur.prototype.clear=aB;ur.prototype.delete=nB;ur.prototype.get=lB;ur.prototype.has=hB;ur.prototype.set=cB;var qa=Jr(Ge,"Map");function uB(){this.size=0,this.__data__={hash:new Ur,map:new(qa||ur),string:new Ur}}function dB(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Qo(e,t){var r=e.__data__;return dB(t)?r[typeof t=="string"?"string":"hash"]:r.map}function fB(e){var t=Qo(this,e).delete(e);return this.size-=t?1:0,t}function pB(e){return Qo(this,e).get(e)}function gB(e){return Qo(this,e).has(e)}function mB(e,t){var r=Qo(this,e),i=r.size;return r.set(e,t),this.size+=r.size==i?0:1,this}function wr(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}wr.prototype.clear=uB;wr.prototype.delete=fB;wr.prototype.get=pB;wr.prototype.has=gB;wr.prototype.set=mB;var yB="Expected a function";function Za(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(yB);var r=function(){var i=arguments,a=t?t.apply(this,i):i[0],s=r.cache;if(s.has(a))return s.get(a);var o=e.apply(this,i);return r.cache=s.set(a,o)||s,o};return r.cache=new(Za.Cache||wr),r}Za.Cache=wr;function CB(){this.__data__=new ur,this.size=0}function xB(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function bB(e){return this.__data__.get(e)}function kB(e){return this.__data__.has(e)}var TB=200;function wB(e,t){var r=this.__data__;if(r instanceof ur){var i=r.__data__;if(!qa||i.length<TB-1)return i.push([e,t]),this.size=++r.size,this;r=this.__data__=new wr(i)}return r.set(e,t),this.size=r.size,this}function Yi(e){var t=this.__data__=new ur(e);this.size=t.size}Yi.prototype.clear=CB;Yi.prototype.delete=xB;Yi.prototype.get=bB;Yi.prototype.has=kB;Yi.prototype.set=wB;var To=(function(){try{var e=Jr(Object,"defineProperty");return e({},"",{}),e}catch{}})();function Rh(e,t,r){t=="__proto__"&&To?To(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function Ol(e,t,r){(r!==void 0&&!Vo(e[t],r)||r===void 0&&!(t in e))&&Rh(e,t,r)}function _B(e){return function(t,r,i){for(var a=-1,s=Object(t),o=i(t),n=o.length;n--;){var l=o[++a];if(r(s[l],l,s)===!1)break}return t}}var SB=_B(),pm=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Nu=pm&&typeof module=="object"&&module&&!module.nodeType&&module,vB=Nu&&Nu.exports===pm,qu=vB?Ge.Buffer:void 0,zu=qu?qu.allocUnsafe:void 0;function BB(e,t){if(t)return e.slice();var r=e.length,i=zu?zu(r):new e.constructor(r);return e.copy(i),i}var Wu=Ge.Uint8Array;function LB(e){var t=new e.constructor(e.byteLength);return new Wu(t).set(new Wu(e)),t}function FB(e,t){var r=t?LB(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}function MB(e,t){var r=-1,i=e.length;for(t||(t=Array(i));++r<i;)t[r]=e[r];return t}var Hu=Object.create,AB=(function(){function e(){}return function(t){if(!Qr(t))return{};if(Hu)return Hu(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}})();function gm(e,t){return function(r){return e(t(r))}}var mm=gm(Object.getPrototypeOf,Object),EB=Object.prototype;function Ko(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||EB;return e===r}function $B(e){return typeof e.constructor=="function"&&!Ko(e)?AB(mm(e)):{}}function Qa(e){return e!=null&&typeof e=="object"}var DB="[object Arguments]";function Uu(e){return Qa(e)&&Ui(e)==DB}var ym=Object.prototype,OB=ym.hasOwnProperty,IB=ym.propertyIsEnumerable,wo=Uu((function(){return arguments})())?Uu:function(e){return Qa(e)&&OB.call(e,"callee")&&!IB.call(e,"callee")},_o=Array.isArray,PB=9007199254740991;function Cm(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=PB}function Jo(e){return e!=null&&Cm(e.length)&&!Ph(e)}function RB(e){return Qa(e)&&Jo(e)}function NB(){return!1}var xm=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Yu=xm&&typeof module=="object"&&module&&!module.nodeType&&module,qB=Yu&&Yu.exports===xm,ju=qB?Ge.Buffer:void 0,zB=ju?ju.isBuffer:void 0,Nh=zB||NB,WB="[object Object]",HB=Function.prototype,UB=Object.prototype,bm=HB.toString,YB=UB.hasOwnProperty,jB=bm.call(Object);function GB(e){if(!Qa(e)||Ui(e)!=WB)return!1;var t=mm(e);if(t===null)return!0;var r=YB.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&bm.call(r)==jB}var XB="[object Arguments]",VB="[object Array]",ZB="[object Boolean]",QB="[object Date]",KB="[object Error]",JB="[object Function]",tL="[object Map]",eL="[object Number]",rL="[object Object]",iL="[object RegExp]",aL="[object Set]",sL="[object String]",oL="[object WeakMap]",nL="[object ArrayBuffer]",lL="[object DataView]",hL="[object Float32Array]",cL="[object Float64Array]",uL="[object Int8Array]",dL="[object Int16Array]",fL="[object Int32Array]",pL="[object Uint8Array]",gL="[object Uint8ClampedArray]",mL="[object Uint16Array]",yL="[object Uint32Array]",Lt={};Lt[hL]=Lt[cL]=Lt[uL]=Lt[dL]=Lt[fL]=Lt[pL]=Lt[gL]=Lt[mL]=Lt[yL]=!0;Lt[XB]=Lt[VB]=Lt[nL]=Lt[ZB]=Lt[lL]=Lt[QB]=Lt[KB]=Lt[JB]=Lt[tL]=Lt[eL]=Lt[rL]=Lt[iL]=Lt[aL]=Lt[sL]=Lt[oL]=!1;function CL(e){return Qa(e)&&Cm(e.length)&&!!Lt[Ui(e)]}function xL(e){return function(t){return e(t)}}var km=typeof exports=="object"&&exports&&!exports.nodeType&&exports,La=km&&typeof module=="object"&&module&&!module.nodeType&&module,bL=La&&La.exports===km,zn=bL&&dm.process,Gu=(function(){try{var e=La&&La.require&&La.require("util").types;return e||zn&&zn.binding&&zn.binding("util")}catch{}})(),Xu=Gu&&Gu.isTypedArray,qh=Xu?xL(Xu):CL;function Il(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}var kL=Object.prototype,TL=kL.hasOwnProperty;function wL(e,t,r){var i=e[t];(!(TL.call(e,t)&&Vo(i,r))||r===void 0&&!(t in e))&&Rh(e,t,r)}function _L(e,t,r,i){var a=!r;r||(r={});for(var s=-1,o=t.length;++s<o;){var n=t[s],l=void 0;l===void 0&&(l=e[n]),a?Rh(r,n,l):wL(r,n,l)}return r}function SL(e,t){for(var r=-1,i=Array(e);++r<e;)i[r]=t(r);return i}var vL=9007199254740991,BL=/^(?:0|[1-9]\d*)$/;function Tm(e,t){var r=typeof e;return t=t??vL,!!t&&(r=="number"||r!="symbol"&&BL.test(e))&&e>-1&&e%1==0&&e<t}var LL=Object.prototype,FL=LL.hasOwnProperty;function ML(e,t){var r=_o(e),i=!r&&wo(e),a=!r&&!i&&Nh(e),s=!r&&!i&&!a&&qh(e),o=r||i||a||s,n=o?SL(e.length,String):[],l=n.length;for(var h in e)(t||FL.call(e,h))&&!(o&&(h=="length"||a&&(h=="offset"||h=="parent")||s&&(h=="buffer"||h=="byteLength"||h=="byteOffset")||Tm(h,l)))&&n.push(h);return n}function AL(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var EL=Object.prototype,$L=EL.hasOwnProperty;function DL(e){if(!Qr(e))return AL(e);var t=Ko(e),r=[];for(var i in e)i=="constructor"&&(t||!$L.call(e,i))||r.push(i);return r}function wm(e){return Jo(e)?ML(e,!0):DL(e)}function OL(e){return _L(e,wm(e))}function IL(e,t,r,i,a,s,o){var n=Il(e,r),l=Il(t,r),h=o.get(l);if(h){Ol(e,r,h);return}var c=s?s(n,l,r+"",e,t,o):void 0,u=c===void 0;if(u){var f=_o(l),d=!f&&Nh(l),p=!f&&!d&&qh(l);c=l,f||d||p?_o(n)?c=n:RB(n)?c=MB(n):d?(u=!1,c=BB(l,!0)):p?(u=!1,c=FB(l,!0)):c=[]:GB(l)||wo(l)?(c=n,wo(n)?c=OL(n):(!Qr(n)||Ph(n))&&(c=$B(l))):u=!1}u&&(o.set(l,c),a(c,l,i,s,o),o.delete(l)),Ol(e,r,c)}function _m(e,t,r,i,a){e!==t&&SB(t,function(s,o){if(a||(a=new Yi),Qr(s))IL(e,t,o,r,_m,i,a);else{var n=i?i(Il(e,o),s,o+"",e,t,a):void 0;n===void 0&&(n=s),Ol(e,o,n)}},wm)}function Sm(e){return e}function PL(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}var Vu=Math.max;function RL(e,t,r){return t=Vu(t===void 0?e.length-1:t,0),function(){for(var i=arguments,a=-1,s=Vu(i.length-t,0),o=Array(s);++a<s;)o[a]=i[t+a];a=-1;for(var n=Array(t+1);++a<t;)n[a]=i[a];return n[t]=r(o),PL(e,this,n)}}function NL(e){return function(){return e}}var qL=To?function(e,t){return To(e,"toString",{configurable:!0,enumerable:!1,value:NL(t),writable:!0})}:Sm,zL=800,WL=16,HL=Date.now;function UL(e){var t=0,r=0;return function(){var i=HL(),a=WL-(i-r);if(r=i,a>0){if(++t>=zL)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var YL=UL(qL);function jL(e,t){return YL(RL(e,t,Sm),e+"")}function GL(e,t,r){if(!Qr(r))return!1;var i=typeof t;return(i=="number"?Jo(r)&&Tm(t,r.length):i=="string"&&t in r)?Vo(r[t],e):!1}function XL(e){return jL(function(t,r){var i=-1,a=r.length,s=a>1?r[a-1]:void 0,o=a>2?r[2]:void 0;for(s=e.length>3&&typeof s=="function"?(a--,s):void 0,o&&GL(r[0],r[1],o)&&(s=a<3?void 0:s,a=1),t=Object(t);++i<a;){var n=r[i];n&&e(t,n,i,s)}return t})}var VL=XL(function(e,t,r){_m(e,t,r)}),ZL="​",QL={curveBasis:xl,curveBasisClosed:rS,curveBasisOpen:iS,curveBumpX:up,curveBumpY:dp,curveBundle:aS,curveCardinalClosed:sS,curveCardinalOpen:oS,curveCardinal:mp,curveCatmullRomClosed:nS,curveCatmullRomOpen:lS,curveCatmullRom:Cp,curveLinear:Ba,curveLinearClosed:hS,curveMonotoneX:_p,curveMonotoneY:Sp,curveNatural:Bp,curveStep:Lp,curveStepAfter:Mp,curveStepBefore:Fp},KL=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,JL=y(function(e,t){const r=vm(e,/(?:init\b)|(?:initialize\b)/);let i={};if(Array.isArray(r)){const o=r.map(n=>n.args);Hs(o),i=qt(i,[...o])}else i=r.args;if(!i)return;let a=oh(e,t);const s="config";return i[s]!==void 0&&(a==="flowchart-v2"&&(a="flowchart"),i[a]=i[s],delete i[s]),i},"detectInit"),vm=y(function(e,t=null){var r,i;try{const a=new RegExp(`[%]{2}(?![{]${KL.source})(?=[}][%]{2}).*
159
+ `,"ig");e=e.trim().replace(a,"").replace(/'/gm,'"'),W.debug(`Detecting diagram directive${t!==null?" type:"+t:""} based on the text:${e}`);let s;const o=[];for(;(s=_a.exec(e))!==null;)if(s.index===_a.lastIndex&&_a.lastIndex++,s&&!t||t&&((r=s[1])!=null&&r.match(t))||t&&((i=s[2])!=null&&i.match(t))){const n=s[1]?s[1]:s[2],l=s[3]?s[3].trim():s[4]?JSON.parse(s[4].trim()):null;o.push({type:n,args:l})}return o.length===0?{type:e,args:null}:o.length===1?o[0]:o}catch(a){return W.error(`ERROR: ${a.message} - Unable to parse directive type: '${t}' based on the text: '${e}'`),{type:void 0,args:null}}},"detectDirective"),tF=y(function(e){return e.replace(_a,"")},"removeDirectives"),eF=y(function(e,t){for(const[r,i]of t.entries())if(i.match(e))return r;return-1},"isSubstringInArray");function zh(e,t){if(!e)return t;const r=`curve${e.charAt(0).toUpperCase()+e.slice(1)}`;return QL[r]??t}y(zh,"interpolateToCurve");function Bm(e,t){const r=e.trim();if(r)return t.securityLevel!=="loose"?kv.sanitizeUrl(r):r}y(Bm,"formatUrl");var rF=y((e,...t)=>{const r=e.split("."),i=r.length-1,a=r[i];let s=window;for(let o=0;o<i;o++)if(s=s[r[o]],!s){W.error(`Function name: ${e} not found in window`);return}s[a](...t)},"runFunc");function Wh(e,t){return!e||!t?0:Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))}y(Wh,"distance");function Lm(e){let t,r=0;e.forEach(a=>{r+=Wh(a,t),t=a});const i=r/2;return Hh(e,i)}y(Lm,"traverseEdge");function Fm(e){return e.length===1?e[0]:Lm(e)}y(Fm,"calcLabelPosition");var Zu=y((e,t=2)=>{const r=Math.pow(10,t);return Math.round(e*r)/r},"roundNumber"),Hh=y((e,t)=>{let r,i=t;for(const a of e){if(r){const s=Wh(a,r);if(s===0)return r;if(s<i)i-=s;else{const o=i/s;if(o<=0)return r;if(o>=1)return{x:a.x,y:a.y};if(o>0&&o<1)return{x:Zu((1-o)*r.x+o*a.x,5),y:Zu((1-o)*r.y+o*a.y,5)}}}r=a}throw new Error("Could not find a suitable point for the given distance")},"calculatePoint"),iF=y((e,t,r)=>{W.info(`our points ${JSON.stringify(t)}`),t[0]!==r&&(t=t.reverse());const a=Hh(t,25),s=e?10:5,o=Math.atan2(t[0].y-a.y,t[0].x-a.x),n={x:0,y:0};return n.x=Math.sin(o)*s+(t[0].x+a.x)/2,n.y=-Math.cos(o)*s+(t[0].y+a.y)/2,n},"calcCardinalityPosition");function Mm(e,t,r){const i=structuredClone(r);W.info("our points",i),t!=="start_left"&&t!=="start_right"&&i.reverse();const a=25+e,s=Hh(i,a),o=10+e*.5,n=Math.atan2(i[0].y-s.y,i[0].x-s.x),l={x:0,y:0};return t==="start_left"?(l.x=Math.sin(n+Math.PI)*o+(i[0].x+s.x)/2,l.y=-Math.cos(n+Math.PI)*o+(i[0].y+s.y)/2):t==="end_right"?(l.x=Math.sin(n-Math.PI)*o+(i[0].x+s.x)/2-5,l.y=-Math.cos(n-Math.PI)*o+(i[0].y+s.y)/2-5):t==="end_left"?(l.x=Math.sin(n)*o+(i[0].x+s.x)/2-5,l.y=-Math.cos(n)*o+(i[0].y+s.y)/2-5):(l.x=Math.sin(n)*o+(i[0].x+s.x)/2,l.y=-Math.cos(n)*o+(i[0].y+s.y)/2),l}y(Mm,"calcTerminalLabelPosition");function Am(e){let t="",r="";for(const i of e)i!==void 0&&(i.startsWith("color:")||i.startsWith("text-align:")?r=r+i+";":t=t+i+";");return{style:t,labelStyle:r}}y(Am,"getStylesFromArray");var Qu=0,aF=y(()=>(Qu++,"id-"+Math.random().toString(36).substr(2,12)+"-"+Qu),"generateId");function Em(e){let t="";const r="0123456789abcdef",i=r.length;for(let a=0;a<e;a++)t+=r.charAt(Math.floor(Math.random()*i));return t}y(Em,"makeRandomHex");var sF=y(e=>Em(e.length),"random"),oF=y(function(){return{x:0,y:0,fill:void 0,anchor:"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0,text:""}},"getTextObj"),nF=y(function(e,t){const r=t.text.replace(Ya.lineBreakRegex," "),[,i]=tn(t.fontSize),a=e.append("text");a.attr("x",t.x),a.attr("y",t.y),a.style("text-anchor",t.anchor),a.style("font-family",t.fontFamily),a.style("font-size",i),a.style("font-weight",t.fontWeight),a.attr("fill",t.fill),t.class!==void 0&&a.attr("class",t.class);const s=a.append("tspan");return s.attr("x",t.x+t.textMargin*2),s.attr("fill",t.fill),s.text(r),a},"drawSimpleText"),lF=Za((e,t,r)=>{if(!e||(r=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"<br/>"},r),Ya.lineBreakRegex.test(e)))return e;const i=e.split(" ").filter(Boolean),a=[];let s="";return i.forEach((o,n)=>{const l=hr(`${o} `,r),h=hr(s,r);if(l>t){const{hyphenatedStrings:f,remainingWord:d}=hF(o,t,"-",r);a.push(s,...f),s=d}else h+l>=t?(a.push(s),s=o):s=[s,o].filter(Boolean).join(" ");n+1===i.length&&a.push(s)}),a.filter(o=>o!=="").join(r.joinWith)},(e,t,r)=>`${e}${t}${r.fontSize}${r.fontWeight}${r.fontFamily}${r.joinWith}`),hF=Za((e,t,r="-",i)=>{i=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:0},i);const a=[...e],s=[];let o="";return a.forEach((n,l)=>{const h=`${o}${n}`;if(hr(h,i)>=t){const u=l+1,f=a.length===u,d=`${h}${r}`;s.push(f?h:d),o=""}else o=h}),{hyphenatedStrings:s,remainingWord:o}},(e,t,r="-",i)=>`${e}${t}${r}${i.fontSize}${i.fontWeight}${i.fontFamily}`);function $m(e,t){return Uh(e,t).height}y($m,"calculateTextHeight");function hr(e,t){return Uh(e,t).width}y(hr,"calculateTextWidth");var Uh=Za((e,t)=>{const{fontSize:r=12,fontFamily:i="Arial",fontWeight:a=400}=t;if(!e)return{width:0,height:0};const[,s]=tn(r),o=["sans-serif",i],n=e.split(Ya.lineBreakRegex),l=[],h=pt("body");if(!h.remove)return{width:0,height:0,lineHeight:0};const c=h.append("svg");for(const f of o){let d=0;const p={width:0,height:0,lineHeight:0};for(const g of n){const m=oF();m.text=g||ZL;const C=nF(c,m).style("font-size",s).style("font-weight",a).style("font-family",f),x=(C._groups||C)[0][0].getBBox();if(x.width===0&&x.height===0)throw new Error("svg element not in render tree");p.width=Math.round(Math.max(p.width,x.width)),d=Math.round(x.height),p.height+=d,p.lineHeight=Math.round(Math.max(p.lineHeight,d))}l.push(p)}c.remove();const u=isNaN(l[1].height)||isNaN(l[1].width)||isNaN(l[1].lineHeight)||l[0].height>l[1].height&&l[0].width>l[1].width&&l[0].lineHeight>l[1].lineHeight?0:1;return l[u]},(e,t)=>`${e}${t.fontSize}${t.fontWeight}${t.fontFamily}`),Ei,cF=(Ei=class{constructor(t=!1,r){this.count=0,this.count=r?r.length:0,this.next=t?()=>this.count++:()=>Date.now()}},y(Ei,"InitIDGenerator"),Ei),ys,uF=y(function(e){return ys=ys||document.createElement("div"),e=escape(e).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),ys.innerHTML=e,unescape(ys.textContent)},"entityDecode");function Yh(e){return"str"in e}y(Yh,"isDetailedError");var dF=y((e,t,r,i)=>{var s;if(!i)return;const a=(s=e.node())==null?void 0:s.getBBox();a&&e.append("text").text(i).attr("text-anchor","middle").attr("x",a.x+a.width/2).attr("y",-r).attr("class",t)},"insertTitle"),tn=y(e=>{if(typeof e=="number")return[e,e+"px"];const t=parseInt(e??"",10);return Number.isNaN(t)?[void 0,void 0]:e===String(t)?[t,e+"px"]:[t,e]},"parseFontSize");function jh(e,t){return VL({},e,t)}y(jh,"cleanAndMerge");var Be={assignWithDepth:qt,wrapLabel:lF,calculateTextHeight:$m,calculateTextWidth:hr,calculateTextDimensions:Uh,cleanAndMerge:jh,detectInit:JL,detectDirective:vm,isSubstringInArray:eF,interpolateToCurve:zh,calcLabelPosition:Fm,calcCardinalityPosition:iF,calcTerminalLabelPosition:Mm,formatUrl:Bm,getStylesFromArray:Am,generateId:aF,random:sF,runFunc:rF,entityDecode:uF,insertTitle:dF,isLabelCoordinateInPath:Dm,parseFontSize:tn,InitIDGenerator:cF},fF=y(function(e){let t=e;return t=t.replace(/style.*:\S*#.*;/g,function(r){return r.substring(0,r.length-1)}),t=t.replace(/classDef.*:\S*#.*;/g,function(r){return r.substring(0,r.length-1)}),t=t.replace(/#\w+;/g,function(r){const i=r.substring(1,r.length-1);return/^\+?\d+$/.test(i)?"fl°°"+i+"¶ß":"fl°"+i+"¶ß"}),t},"encodeEntities"),Yr=y(function(e){return e.replace(/fl°°/g,"&#").replace(/fl°/g,"&").replace(/¶ß/g,";")},"decodeEntities"),W$=y((e,t,{counter:r=0,prefix:i,suffix:a},s)=>s||`${i?`${i}_`:""}${e}_${t}_${r}${a?`_${a}`:""}`,"getEdgeId");function Ht(e){return e??null}y(Ht,"handleUndefinedAttr");function Dm(e,t){const r=Math.round(e.x),i=Math.round(e.y),a=t.replace(/(\d+\.\d+)/g,s=>Math.round(parseFloat(s)).toString());return a.includes(r.toString())||a.includes(i.toString())}y(Dm,"isLabelCoordinateInPath");var Gh=y(({flowchart:e})=>{var a,s;const t=((a=e==null?void 0:e.subGraphTitleMargin)==null?void 0:a.top)??0,r=((s=e==null?void 0:e.subGraphTitleMargin)==null?void 0:s.bottom)??0,i=t+r;return{subGraphTitleTopMargin:t,subGraphTitleBottomMargin:r,subGraphTitleTotalMargin:i}},"getSubGraphTitleMargins");async function Om(e,t){const r=e.getElementsByTagName("img");if(!r||r.length===0)return;const i=t.replace(/<img[^>]*>/g,"").trim()==="";await Promise.all([...r].map(a=>new Promise(s=>{function o(){if(a.style.display="flex",a.style.flexDirection="column",i){const n=bt().fontSize?bt().fontSize:window.getComputedStyle(document.body).fontSize,l=5,[h=tf.fontSize]=tn(n),c=h*l+"px";a.style.minWidth=c,a.style.maxWidth=c}else a.style.width="100%";s(a)}y(o,"setupImage"),setTimeout(()=>{a.complete&&o()}),a.addEventListener("error",o),a.addEventListener("load",o)})))}y(Om,"configureLabelImages");var pF=y(e=>{const{handDrawnSeed:t}=bt();return{fill:e,hachureAngle:120,hachureGap:4,fillWeight:2,roughness:.7,stroke:e,seed:t}},"solidStateFill"),ji=y(e=>{const t=gF([...e.cssCompiledStyles||[],...e.cssStyles||[],...e.labelStyle||[]]);return{stylesMap:t,stylesArray:[...t]}},"compileStyles"),gF=y(e=>{const t=new Map;return e.forEach(r=>{const[i,a]=r.split(":");t.set(i.trim(),a==null?void 0:a.trim())}),t},"styles2Map"),Im=y(e=>e==="color"||e==="font-size"||e==="font-family"||e==="font-weight"||e==="font-style"||e==="text-decoration"||e==="text-align"||e==="text-transform"||e==="line-height"||e==="letter-spacing"||e==="word-spacing"||e==="text-shadow"||e==="text-overflow"||e==="white-space"||e==="word-wrap"||e==="word-break"||e==="overflow-wrap"||e==="hyphens","isLabelStyle"),tt=y(e=>{const{stylesArray:t}=ji(e),r=[],i=[],a=[],s=[];return t.forEach(o=>{const n=o[0];Im(n)?r.push(o.join(":")+" !important"):(i.push(o.join(":")+" !important"),n.includes("stroke")&&a.push(o.join(":")+" !important"),n==="fill"&&s.push(o.join(":")+" !important"))}),{labelStyles:r.join(";"),nodeStyles:i.join(";"),stylesArray:t,borderStyles:a,backgroundStyles:s}},"styles2String"),J=y((e,t)=>{var l;const{themeVariables:r,handDrawnSeed:i}=bt(),{nodeBorder:a,mainBkg:s}=r,{stylesMap:o}=ji(e);return Object.assign({roughness:.7,fill:o.get("fill")||s,fillStyle:"hachure",fillWeight:4,hachureGap:5.2,stroke:o.get("stroke")||a,seed:i,strokeWidth:((l=o.get("stroke-width"))==null?void 0:l.replace("px",""))||1.3,fillLineDash:[0,0],strokeLineDash:mF(o.get("stroke-dasharray"))},t)},"userNodeOverrides"),mF=y(e=>{if(!e)return[0,0];const t=e.trim().split(/\s+/).map(Number);if(t.length===1){const a=isNaN(t[0])?0:t[0];return[a,a]}const r=isNaN(t[0])?0:t[0],i=isNaN(t[1])?0:t[1];return[r,i]},"getStrokeDashArray");const yF=Object.freeze({left:0,top:0,width:16,height:16}),So=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),Pm=Object.freeze({...yF,...So}),CF=Object.freeze({...Pm,body:"",hidden:!1}),xF=Object.freeze({width:null,height:null}),bF=Object.freeze({...xF,...So}),kF=(e,t,r,i="")=>{const a=e.split(":");if(e.slice(0,1)==="@"){if(a.length<2||a.length>3)return null;i=a.shift().slice(1)}if(a.length>3||!a.length)return null;if(a.length>1){const n=a.pop(),l=a.pop(),h={provider:a.length>0?a[0]:i,prefix:l,name:n};return Wn(h)?h:null}const s=a[0],o=s.split("-");if(o.length>1){const n={provider:i,prefix:o.shift(),name:o.join("-")};return Wn(n)?n:null}if(r&&i===""){const n={provider:i,prefix:"",name:s};return Wn(n,r)?n:null}return null},Wn=(e,t)=>e?!!((t&&e.prefix===""||e.prefix)&&e.name):!1;function TF(e,t){const r={};!e.hFlip!=!t.hFlip&&(r.hFlip=!0),!e.vFlip!=!t.vFlip&&(r.vFlip=!0);const i=((e.rotate||0)+(t.rotate||0))%4;return i&&(r.rotate=i),r}function Ku(e,t){const r=TF(e,t);for(const i in CF)i in So?i in e&&!(i in r)&&(r[i]=So[i]):i in t?r[i]=t[i]:i in e&&(r[i]=e[i]);return r}function wF(e,t){const r=e.icons,i=e.aliases||Object.create(null),a=Object.create(null);function s(o){if(r[o])return a[o]=[];if(!(o in a)){a[o]=null;const n=i[o]&&i[o].parent,l=n&&s(n);l&&(a[o]=[n].concat(l))}return a[o]}return(t||Object.keys(r).concat(Object.keys(i))).forEach(s),a}function Ju(e,t,r){const i=e.icons,a=e.aliases||Object.create(null);let s={};function o(n){s=Ku(i[n]||a[n],s)}return o(t),r.forEach(o),Ku(e,s)}function _F(e,t){if(e.icons[t])return Ju(e,t,[]);const r=wF(e,[t])[t];return r?Ju(e,t,r):null}const SF=/(-?[0-9.]*[0-9]+[0-9.]*)/g,vF=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function td(e,t,r){if(t===1)return e;if(r=r||100,typeof e=="number")return Math.ceil(e*t*r)/r;if(typeof e!="string")return e;const i=e.split(SF);if(i===null||!i.length)return e;const a=[];let s=i.shift(),o=vF.test(s);for(;;){if(o){const n=parseFloat(s);isNaN(n)?a.push(s):a.push(Math.ceil(n*t*r)/r)}else a.push(s);if(s=i.shift(),s===void 0)return a.join("");o=!o}}function BF(e,t="defs"){let r="";const i=e.indexOf("<"+t);for(;i>=0;){const a=e.indexOf(">",i),s=e.indexOf("</"+t);if(a===-1||s===-1)break;const o=e.indexOf(">",s);if(o===-1)break;r+=e.slice(a+1,s).trim(),e=e.slice(0,i).trim()+e.slice(o+1)}return{defs:r,content:e}}function LF(e,t){return e?"<defs>"+e+"</defs>"+t:t}function FF(e,t,r){const i=BF(e);return LF(i.defs,t+i.content+r)}const MF=e=>e==="unset"||e==="undefined"||e==="none";function AF(e,t){const r={...Pm,...e},i={...bF,...t},a={left:r.left,top:r.top,width:r.width,height:r.height};let s=r.body;[r,i].forEach(g=>{const m=[],C=g.hFlip,x=g.vFlip;let k=g.rotate;C?x?k+=2:(m.push("translate("+(a.width+a.left).toString()+" "+(0-a.top).toString()+")"),m.push("scale(-1 1)"),a.top=a.left=0):x&&(m.push("translate("+(0-a.left).toString()+" "+(a.height+a.top).toString()+")"),m.push("scale(1 -1)"),a.top=a.left=0);let w;switch(k<0&&(k-=Math.floor(k/4)*4),k=k%4,k){case 1:w=a.height/2+a.top,m.unshift("rotate(90 "+w.toString()+" "+w.toString()+")");break;case 2:m.unshift("rotate(180 "+(a.width/2+a.left).toString()+" "+(a.height/2+a.top).toString()+")");break;case 3:w=a.width/2+a.left,m.unshift("rotate(-90 "+w.toString()+" "+w.toString()+")");break}k%2===1&&(a.left!==a.top&&(w=a.left,a.left=a.top,a.top=w),a.width!==a.height&&(w=a.width,a.width=a.height,a.height=w)),m.length&&(s=FF(s,'<g transform="'+m.join(" ")+'">',"</g>"))});const o=i.width,n=i.height,l=a.width,h=a.height;let c,u;o===null?(u=n===null?"1em":n==="auto"?h:n,c=td(u,l/h)):(c=o==="auto"?l:o,u=n===null?td(c,h/l):n==="auto"?h:n);const f={},d=(g,m)=>{MF(m)||(f[g]=m.toString())};d("width",c),d("height",u);const p=[a.left,a.top,l,h];return f.viewBox=p.join(" "),{attributes:f,viewBox:p,body:s}}const EF=/\sid="(\S+)"/g,ed=new Map;function $F(e){e=e.replace(/[0-9]+$/,"")||"a";const t=ed.get(e)||0;return ed.set(e,t+1),t?`${e}${t}`:e}function DF(e){const t=[];let r;for(;r=EF.exec(e);)t.push(r[1]);if(!t.length)return e;const i="suffix"+(Math.random()*16777216|Date.now()).toString(16);return t.forEach(a=>{const s=$F(a),o=a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");e=e.replace(new RegExp('([#;"])('+o+')([")]|\\.[a-z])',"g"),"$1"+s+i+"$3")}),e=e.replace(new RegExp(i,"g"),""),e}function OF(e,t){let r=e.indexOf("xlink:")===-1?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(const i in t)r+=" "+i+'="'+t[i]+'"';return'<svg xmlns="http://www.w3.org/2000/svg"'+r+">"+e+"</svg>"}function Xh(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var ti=Xh();function Rm(e){ti=e}var Fa={exec:()=>null};function Tt(e,t=""){let r=typeof e=="string"?e:e.source,i={replace:(a,s)=>{let o=typeof s=="string"?s:s.source;return o=o.replace(ae.caret,"$1"),r=r.replace(a,o),i},getRegex:()=>new RegExp(r,t)};return i}var IF=(()=>{try{return!!new RegExp("(?<=1)(?<!1)")}catch{return!1}})(),ae={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>new RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}#`),htmlBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}<(?:[a-z].*>|!--)`,"i")},PF=/^(?:[ \t]*(?:\n|$))+/,RF=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,NF=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,Ka=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,qF=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,Vh=/(?:[*+-]|\d{1,9}[.)])/,Nm=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,qm=Tt(Nm).replace(/bull/g,Vh).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),zF=Tt(Nm).replace(/bull/g,Vh).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),Zh=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,WF=/^[^\n]+/,Qh=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,HF=Tt(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",Qh).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),UF=Tt(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,Vh).getRegex(),en="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",Kh=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,YF=Tt("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",Kh).replace("tag",en).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),zm=Tt(Zh).replace("hr",Ka).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",en).getRegex(),jF=Tt(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",zm).getRegex(),Jh={blockquote:jF,code:RF,def:HF,fences:NF,heading:qF,hr:Ka,html:YF,lheading:qm,list:UF,newline:PF,paragraph:zm,table:Fa,text:WF},rd=Tt("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",Ka).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",en).getRegex(),GF={...Jh,lheading:zF,table:rd,paragraph:Tt(Zh).replace("hr",Ka).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",rd).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",en).getRegex()},XF={...Jh,html:Tt(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",Kh).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:Fa,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:Tt(Zh).replace("hr",Ka).replace("heading",` *#{1,6} *[^
160
+ ]`).replace("lheading",qm).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},VF=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,ZF=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,Wm=/^( {2,}|\\)\n(?!\s*$)/,QF=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,rn=/[\p{P}\p{S}]/u,tc=/[\s\p{P}\p{S}]/u,Hm=/[^\s\p{P}\p{S}]/u,KF=Tt(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,tc).getRegex(),Um=/(?!~)[\p{P}\p{S}]/u,JF=/(?!~)[\s\p{P}\p{S}]/u,tM=/(?:[^\s\p{P}\p{S}]|~)/u,eM=Tt(/link|precode-code|html/,"g").replace("link",/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",IF?"(?<!`)()":"(^^|[^`])").replace("code",/(?<b>`+)[^`]+\k<b>(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),Ym=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,rM=Tt(Ym,"u").replace(/punct/g,rn).getRegex(),iM=Tt(Ym,"u").replace(/punct/g,Um).getRegex(),jm="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",aM=Tt(jm,"gu").replace(/notPunctSpace/g,Hm).replace(/punctSpace/g,tc).replace(/punct/g,rn).getRegex(),sM=Tt(jm,"gu").replace(/notPunctSpace/g,tM).replace(/punctSpace/g,JF).replace(/punct/g,Um).getRegex(),oM=Tt("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,Hm).replace(/punctSpace/g,tc).replace(/punct/g,rn).getRegex(),nM=Tt(/\\(punct)/,"gu").replace(/punct/g,rn).getRegex(),lM=Tt(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),hM=Tt(Kh).replace("(?:-->|$)","-->").getRegex(),cM=Tt("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",hM).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),vo=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/,uM=Tt(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",vo).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Gm=Tt(/^!?\[(label)\]\[(ref)\]/).replace("label",vo).replace("ref",Qh).getRegex(),Xm=Tt(/^!?\[(ref)\](?:\[\])?/).replace("ref",Qh).getRegex(),dM=Tt("reflink|nolink(?!\\()","g").replace("reflink",Gm).replace("nolink",Xm).getRegex(),id=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,ec={_backpedal:Fa,anyPunctuation:nM,autolink:lM,blockSkip:eM,br:Wm,code:ZF,del:Fa,emStrongLDelim:rM,emStrongRDelimAst:aM,emStrongRDelimUnd:oM,escape:VF,link:uM,nolink:Xm,punctuation:KF,reflink:Gm,reflinkSearch:dM,tag:cM,text:QF,url:Fa},fM={...ec,link:Tt(/^!?\[(label)\]\((.*?)\)/).replace("label",vo).getRegex(),reflink:Tt(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",vo).getRegex()},Pl={...ec,emStrongRDelimAst:sM,emStrongLDelim:iM,url:Tt(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol",id).replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:Tt(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol",id).getRegex()},pM={...Pl,br:Tt(Wm).replace("{2,}","*").getRegex(),text:Tt(Pl.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},Cs={normal:Jh,gfm:GF,pedantic:XF},ca={normal:ec,gfm:Pl,breaks:pM,pedantic:fM},gM={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},ad=e=>gM[e];function Re(e,t){if(t){if(ae.escapeTest.test(e))return e.replace(ae.escapeReplace,ad)}else if(ae.escapeTestNoEncode.test(e))return e.replace(ae.escapeReplaceNoEncode,ad);return e}function sd(e){try{e=encodeURI(e).replace(ae.percentDecode,"%")}catch{return null}return e}function od(e,t){var s;let r=e.replace(ae.findPipe,(o,n,l)=>{let h=!1,c=n;for(;--c>=0&&l[c]==="\\";)h=!h;return h?"|":" |"}),i=r.split(ae.splitPipe),a=0;if(i[0].trim()||i.shift(),i.length>0&&!((s=i.at(-1))!=null&&s.trim())&&i.pop(),t)if(i.length>t)i.splice(t);else for(;i.length<t;)i.push("");for(;a<i.length;a++)i[a]=i[a].trim().replace(ae.slashPipe,"|");return i}function ua(e,t,r){let i=e.length;if(i===0)return"";let a=0;for(;a<i&&e.charAt(i-a-1)===t;)a++;return e.slice(0,i-a)}function mM(e,t){if(e.indexOf(t[1])===-1)return-1;let r=0;for(let i=0;i<e.length;i++)if(e[i]==="\\")i++;else if(e[i]===t[0])r++;else if(e[i]===t[1]&&(r--,r<0))return i;return r>0?-2:-1}function nd(e,t,r,i,a){let s=t.href,o=t.title||null,n=e[1].replace(a.other.outputLinkReplace,"$1");i.state.inLink=!0;let l={type:e[0].charAt(0)==="!"?"image":"link",raw:r,href:s,title:o,text:n,tokens:i.inlineTokens(n)};return i.state.inLink=!1,l}function yM(e,t,r){let i=e.match(r.other.indentCodeCompensation);if(i===null)return t;let a=i[1];return t.split(`
161
+ `).map(s=>{let o=s.match(r.other.beginningSpace);if(o===null)return s;let[n]=o;return n.length>=a.length?s.slice(a.length):s}).join(`
162
+ `)}var Bo=class{constructor(t){St(this,"options");St(this,"rules");St(this,"lexer");this.options=t||ti}space(t){let r=this.rules.block.newline.exec(t);if(r&&r[0].length>0)return{type:"space",raw:r[0]}}code(t){let r=this.rules.block.code.exec(t);if(r){let i=r[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:r[0],codeBlockStyle:"indented",text:this.options.pedantic?i:ua(i,`
163
+ `)}}}fences(t){let r=this.rules.block.fences.exec(t);if(r){let i=r[0],a=yM(i,r[3]||"",this.rules);return{type:"code",raw:i,lang:r[2]?r[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):r[2],text:a}}}heading(t){let r=this.rules.block.heading.exec(t);if(r){let i=r[2].trim();if(this.rules.other.endingHash.test(i)){let a=ua(i,"#");(this.options.pedantic||!a||this.rules.other.endingSpaceChar.test(a))&&(i=a.trim())}return{type:"heading",raw:r[0],depth:r[1].length,text:i,tokens:this.lexer.inline(i)}}}hr(t){let r=this.rules.block.hr.exec(t);if(r)return{type:"hr",raw:ua(r[0],`
164
+ `)}}blockquote(t){let r=this.rules.block.blockquote.exec(t);if(r){let i=ua(r[0],`
165
+ `).split(`
166
+ `),a="",s="",o=[];for(;i.length>0;){let n=!1,l=[],h;for(h=0;h<i.length;h++)if(this.rules.other.blockquoteStart.test(i[h]))l.push(i[h]),n=!0;else if(!n)l.push(i[h]);else break;i=i.slice(h);let c=l.join(`
167
+ `),u=c.replace(this.rules.other.blockquoteSetextReplace,`
168
+ $1`).replace(this.rules.other.blockquoteSetextReplace2,"");a=a?`${a}
169
+ ${c}`:c,s=s?`${s}
170
+ ${u}`:u;let f=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(u,o,!0),this.lexer.state.top=f,i.length===0)break;let d=o.at(-1);if((d==null?void 0:d.type)==="code")break;if((d==null?void 0:d.type)==="blockquote"){let p=d,g=p.raw+`
171
+ `+i.join(`
172
+ `),m=this.blockquote(g);o[o.length-1]=m,a=a.substring(0,a.length-p.raw.length)+m.raw,s=s.substring(0,s.length-p.text.length)+m.text;break}else if((d==null?void 0:d.type)==="list"){let p=d,g=p.raw+`
173
+ `+i.join(`
174
+ `),m=this.list(g);o[o.length-1]=m,a=a.substring(0,a.length-d.raw.length)+m.raw,s=s.substring(0,s.length-p.raw.length)+m.raw,i=g.substring(o.at(-1).raw.length).split(`
175
+ `);continue}}return{type:"blockquote",raw:a,tokens:o,text:s}}}list(t){let r=this.rules.block.list.exec(t);if(r){let i=r[1].trim(),a=i.length>1,s={type:"list",raw:"",ordered:a,start:a?+i.slice(0,-1):"",loose:!1,items:[]};i=a?`\\d{1,9}\\${i.slice(-1)}`:`\\${i}`,this.options.pedantic&&(i=a?i:"[*+-]");let o=this.rules.other.listItemRegex(i),n=!1;for(;t;){let h=!1,c="",u="";if(!(r=o.exec(t))||this.rules.block.hr.test(t))break;c=r[0],t=t.substring(c.length);let f=r[2].split(`
176
+ `,1)[0].replace(this.rules.other.listReplaceTabs,x=>" ".repeat(3*x.length)),d=t.split(`
177
+ `,1)[0],p=!f.trim(),g=0;if(this.options.pedantic?(g=2,u=f.trimStart()):p?g=r[1].length+1:(g=r[2].search(this.rules.other.nonSpaceChar),g=g>4?1:g,u=f.slice(g),g+=r[1].length),p&&this.rules.other.blankLine.test(d)&&(c+=d+`
178
+ `,t=t.substring(d.length+1),h=!0),!h){let x=this.rules.other.nextBulletRegex(g),k=this.rules.other.hrRegex(g),w=this.rules.other.fencesBeginRegex(g),S=this.rules.other.headingBeginRegex(g),_=this.rules.other.htmlBeginRegex(g);for(;t;){let T=t.split(`
179
+ `,1)[0],B;if(d=T,this.options.pedantic?(d=d.replace(this.rules.other.listReplaceNesting," "),B=d):B=d.replace(this.rules.other.tabCharGlobal," "),w.test(d)||S.test(d)||_.test(d)||x.test(d)||k.test(d))break;if(B.search(this.rules.other.nonSpaceChar)>=g||!d.trim())u+=`
180
+ `+B.slice(g);else{if(p||f.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||w.test(f)||S.test(f)||k.test(f))break;u+=`
181
+ `+d}!p&&!d.trim()&&(p=!0),c+=T+`
182
+ `,t=t.substring(T.length+1),f=B.slice(g)}}s.loose||(n?s.loose=!0:this.rules.other.doubleBlankLine.test(c)&&(n=!0));let m=null,C;this.options.gfm&&(m=this.rules.other.listIsTask.exec(u),m&&(C=m[0]!=="[ ] ",u=u.replace(this.rules.other.listReplaceTask,""))),s.items.push({type:"list_item",raw:c,task:!!m,checked:C,loose:!1,text:u,tokens:[]}),s.raw+=c}let l=s.items.at(-1);if(l)l.raw=l.raw.trimEnd(),l.text=l.text.trimEnd();else return;s.raw=s.raw.trimEnd();for(let h=0;h<s.items.length;h++)if(this.lexer.state.top=!1,s.items[h].tokens=this.lexer.blockTokens(s.items[h].text,[]),!s.loose){let c=s.items[h].tokens.filter(f=>f.type==="space"),u=c.length>0&&c.some(f=>this.rules.other.anyLine.test(f.raw));s.loose=u}if(s.loose)for(let h=0;h<s.items.length;h++)s.items[h].loose=!0;return s}}html(t){let r=this.rules.block.html.exec(t);if(r)return{type:"html",block:!0,raw:r[0],pre:r[1]==="pre"||r[1]==="script"||r[1]==="style",text:r[0]}}def(t){let r=this.rules.block.def.exec(t);if(r){let i=r[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),a=r[2]?r[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",s=r[3]?r[3].substring(1,r[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):r[3];return{type:"def",tag:i,raw:r[0],href:a,title:s}}}table(t){var n;let r=this.rules.block.table.exec(t);if(!r||!this.rules.other.tableDelimiter.test(r[2]))return;let i=od(r[1]),a=r[2].replace(this.rules.other.tableAlignChars,"").split("|"),s=(n=r[3])!=null&&n.trim()?r[3].replace(this.rules.other.tableRowBlankLine,"").split(`
183
+ `):[],o={type:"table",raw:r[0],header:[],align:[],rows:[]};if(i.length===a.length){for(let l of a)this.rules.other.tableAlignRight.test(l)?o.align.push("right"):this.rules.other.tableAlignCenter.test(l)?o.align.push("center"):this.rules.other.tableAlignLeft.test(l)?o.align.push("left"):o.align.push(null);for(let l=0;l<i.length;l++)o.header.push({text:i[l],tokens:this.lexer.inline(i[l]),header:!0,align:o.align[l]});for(let l of s)o.rows.push(od(l,o.header.length).map((h,c)=>({text:h,tokens:this.lexer.inline(h),header:!1,align:o.align[c]})));return o}}lheading(t){let r=this.rules.block.lheading.exec(t);if(r)return{type:"heading",raw:r[0],depth:r[2].charAt(0)==="="?1:2,text:r[1],tokens:this.lexer.inline(r[1])}}paragraph(t){let r=this.rules.block.paragraph.exec(t);if(r){let i=r[1].charAt(r[1].length-1)===`
184
+ `?r[1].slice(0,-1):r[1];return{type:"paragraph",raw:r[0],text:i,tokens:this.lexer.inline(i)}}}text(t){let r=this.rules.block.text.exec(t);if(r)return{type:"text",raw:r[0],text:r[0],tokens:this.lexer.inline(r[0])}}escape(t){let r=this.rules.inline.escape.exec(t);if(r)return{type:"escape",raw:r[0],text:r[1]}}tag(t){let r=this.rules.inline.tag.exec(t);if(r)return!this.lexer.state.inLink&&this.rules.other.startATag.test(r[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(r[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(r[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(r[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:r[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:r[0]}}link(t){let r=this.rules.inline.link.exec(t);if(r){let i=r[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(i)){if(!this.rules.other.endAngleBracket.test(i))return;let o=ua(i.slice(0,-1),"\\");if((i.length-o.length)%2===0)return}else{let o=mM(r[2],"()");if(o===-2)return;if(o>-1){let n=(r[0].indexOf("!")===0?5:4)+r[1].length+o;r[2]=r[2].substring(0,o),r[0]=r[0].substring(0,n).trim(),r[3]=""}}let a=r[2],s="";if(this.options.pedantic){let o=this.rules.other.pedanticHrefTitle.exec(a);o&&(a=o[1],s=o[3])}else s=r[3]?r[3].slice(1,-1):"";return a=a.trim(),this.rules.other.startAngleBracket.test(a)&&(this.options.pedantic&&!this.rules.other.endAngleBracket.test(i)?a=a.slice(1):a=a.slice(1,-1)),nd(r,{href:a&&a.replace(this.rules.inline.anyPunctuation,"$1"),title:s&&s.replace(this.rules.inline.anyPunctuation,"$1")},r[0],this.lexer,this.rules)}}reflink(t,r){let i;if((i=this.rules.inline.reflink.exec(t))||(i=this.rules.inline.nolink.exec(t))){let a=(i[2]||i[1]).replace(this.rules.other.multipleSpaceGlobal," "),s=r[a.toLowerCase()];if(!s){let o=i[0].charAt(0);return{type:"text",raw:o,text:o}}return nd(i,s,i[0],this.lexer,this.rules)}}emStrong(t,r,i=""){let a=this.rules.inline.emStrongLDelim.exec(t);if(!(!a||a[3]&&i.match(this.rules.other.unicodeAlphaNumeric))&&(!(a[1]||a[2])||!i||this.rules.inline.punctuation.exec(i))){let s=[...a[0]].length-1,o,n,l=s,h=0,c=a[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(c.lastIndex=0,r=r.slice(-1*t.length+s);(a=c.exec(r))!=null;){if(o=a[1]||a[2]||a[3]||a[4]||a[5]||a[6],!o)continue;if(n=[...o].length,a[3]||a[4]){l+=n;continue}else if((a[5]||a[6])&&s%3&&!((s+n)%3)){h+=n;continue}if(l-=n,l>0)continue;n=Math.min(n,n+l+h);let u=[...a[0]][0].length,f=t.slice(0,s+a.index+u+n);if(Math.min(s,n)%2){let p=f.slice(1,-1);return{type:"em",raw:f,text:p,tokens:this.lexer.inlineTokens(p)}}let d=f.slice(2,-2);return{type:"strong",raw:f,text:d,tokens:this.lexer.inlineTokens(d)}}}}codespan(t){let r=this.rules.inline.code.exec(t);if(r){let i=r[2].replace(this.rules.other.newLineCharGlobal," "),a=this.rules.other.nonSpaceChar.test(i),s=this.rules.other.startingSpaceChar.test(i)&&this.rules.other.endingSpaceChar.test(i);return a&&s&&(i=i.substring(1,i.length-1)),{type:"codespan",raw:r[0],text:i}}}br(t){let r=this.rules.inline.br.exec(t);if(r)return{type:"br",raw:r[0]}}del(t){let r=this.rules.inline.del.exec(t);if(r)return{type:"del",raw:r[0],text:r[2],tokens:this.lexer.inlineTokens(r[2])}}autolink(t){let r=this.rules.inline.autolink.exec(t);if(r){let i,a;return r[2]==="@"?(i=r[1],a="mailto:"+i):(i=r[1],a=i),{type:"link",raw:r[0],text:i,href:a,tokens:[{type:"text",raw:i,text:i}]}}}url(t){var i;let r;if(r=this.rules.inline.url.exec(t)){let a,s;if(r[2]==="@")a=r[0],s="mailto:"+a;else{let o;do o=r[0],r[0]=((i=this.rules.inline._backpedal.exec(r[0]))==null?void 0:i[0])??"";while(o!==r[0]);a=r[0],r[1]==="www."?s="http://"+r[0]:s=r[0]}return{type:"link",raw:r[0],text:a,href:s,tokens:[{type:"text",raw:a,text:a}]}}}inlineText(t){let r=this.rules.inline.text.exec(t);if(r){let i=this.lexer.state.inRawBlock;return{type:"text",raw:r[0],text:r[0],escaped:i}}}},_e=class Rl{constructor(t){St(this,"tokens");St(this,"options");St(this,"state");St(this,"tokenizer");St(this,"inlineQueue");this.tokens=[],this.tokens.links=Object.create(null),this.options=t||ti,this.options.tokenizer=this.options.tokenizer||new Bo,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let r={other:ae,block:Cs.normal,inline:ca.normal};this.options.pedantic?(r.block=Cs.pedantic,r.inline=ca.pedantic):this.options.gfm&&(r.block=Cs.gfm,this.options.breaks?r.inline=ca.breaks:r.inline=ca.gfm),this.tokenizer.rules=r}static get rules(){return{block:Cs,inline:ca}}static lex(t,r){return new Rl(r).lex(t)}static lexInline(t,r){return new Rl(r).inlineTokens(t)}lex(t){t=t.replace(ae.carriageReturn,`
185
+ `),this.blockTokens(t,this.tokens);for(let r=0;r<this.inlineQueue.length;r++){let i=this.inlineQueue[r];this.inlineTokens(i.src,i.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(t,r=[],i=!1){var a,s,o;for(this.options.pedantic&&(t=t.replace(ae.tabCharGlobal," ").replace(ae.spaceLine,""));t;){let n;if((s=(a=this.options.extensions)==null?void 0:a.block)!=null&&s.some(h=>(n=h.call({lexer:this},t,r))?(t=t.substring(n.raw.length),r.push(n),!0):!1))continue;if(n=this.tokenizer.space(t)){t=t.substring(n.raw.length);let h=r.at(-1);n.raw.length===1&&h!==void 0?h.raw+=`
186
+ `:r.push(n);continue}if(n=this.tokenizer.code(t)){t=t.substring(n.raw.length);let h=r.at(-1);(h==null?void 0:h.type)==="paragraph"||(h==null?void 0:h.type)==="text"?(h.raw+=(h.raw.endsWith(`
187
+ `)?"":`
188
+ `)+n.raw,h.text+=`
189
+ `+n.text,this.inlineQueue.at(-1).src=h.text):r.push(n);continue}if(n=this.tokenizer.fences(t)){t=t.substring(n.raw.length),r.push(n);continue}if(n=this.tokenizer.heading(t)){t=t.substring(n.raw.length),r.push(n);continue}if(n=this.tokenizer.hr(t)){t=t.substring(n.raw.length),r.push(n);continue}if(n=this.tokenizer.blockquote(t)){t=t.substring(n.raw.length),r.push(n);continue}if(n=this.tokenizer.list(t)){t=t.substring(n.raw.length),r.push(n);continue}if(n=this.tokenizer.html(t)){t=t.substring(n.raw.length),r.push(n);continue}if(n=this.tokenizer.def(t)){t=t.substring(n.raw.length);let h=r.at(-1);(h==null?void 0:h.type)==="paragraph"||(h==null?void 0:h.type)==="text"?(h.raw+=(h.raw.endsWith(`
190
+ `)?"":`
191
+ `)+n.raw,h.text+=`
192
+ `+n.raw,this.inlineQueue.at(-1).src=h.text):this.tokens.links[n.tag]||(this.tokens.links[n.tag]={href:n.href,title:n.title},r.push(n));continue}if(n=this.tokenizer.table(t)){t=t.substring(n.raw.length),r.push(n);continue}if(n=this.tokenizer.lheading(t)){t=t.substring(n.raw.length),r.push(n);continue}let l=t;if((o=this.options.extensions)!=null&&o.startBlock){let h=1/0,c=t.slice(1),u;this.options.extensions.startBlock.forEach(f=>{u=f.call({lexer:this},c),typeof u=="number"&&u>=0&&(h=Math.min(h,u))}),h<1/0&&h>=0&&(l=t.substring(0,h+1))}if(this.state.top&&(n=this.tokenizer.paragraph(l))){let h=r.at(-1);i&&(h==null?void 0:h.type)==="paragraph"?(h.raw+=(h.raw.endsWith(`
193
+ `)?"":`
194
+ `)+n.raw,h.text+=`
195
+ `+n.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=h.text):r.push(n),i=l.length!==t.length,t=t.substring(n.raw.length);continue}if(n=this.tokenizer.text(t)){t=t.substring(n.raw.length);let h=r.at(-1);(h==null?void 0:h.type)==="text"?(h.raw+=(h.raw.endsWith(`
196
+ `)?"":`
197
+ `)+n.raw,h.text+=`
198
+ `+n.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=h.text):r.push(n);continue}if(t){let h="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(h);break}else throw new Error(h)}}return this.state.top=!0,r}inline(t,r=[]){return this.inlineQueue.push({src:t,tokens:r}),r}inlineTokens(t,r=[]){var l,h,c,u,f;let i=t,a=null;if(this.tokens.links){let d=Object.keys(this.tokens.links);if(d.length>0)for(;(a=this.tokenizer.rules.inline.reflinkSearch.exec(i))!=null;)d.includes(a[0].slice(a[0].lastIndexOf("[")+1,-1))&&(i=i.slice(0,a.index)+"["+"a".repeat(a[0].length-2)+"]"+i.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(a=this.tokenizer.rules.inline.anyPunctuation.exec(i))!=null;)i=i.slice(0,a.index)+"++"+i.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);let s;for(;(a=this.tokenizer.rules.inline.blockSkip.exec(i))!=null;)s=a[2]?a[2].length:0,i=i.slice(0,a.index+s)+"["+"a".repeat(a[0].length-s-2)+"]"+i.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);i=((h=(l=this.options.hooks)==null?void 0:l.emStrongMask)==null?void 0:h.call({lexer:this},i))??i;let o=!1,n="";for(;t;){o||(n=""),o=!1;let d;if((u=(c=this.options.extensions)==null?void 0:c.inline)!=null&&u.some(g=>(d=g.call({lexer:this},t,r))?(t=t.substring(d.raw.length),r.push(d),!0):!1))continue;if(d=this.tokenizer.escape(t)){t=t.substring(d.raw.length),r.push(d);continue}if(d=this.tokenizer.tag(t)){t=t.substring(d.raw.length),r.push(d);continue}if(d=this.tokenizer.link(t)){t=t.substring(d.raw.length),r.push(d);continue}if(d=this.tokenizer.reflink(t,this.tokens.links)){t=t.substring(d.raw.length);let g=r.at(-1);d.type==="text"&&(g==null?void 0:g.type)==="text"?(g.raw+=d.raw,g.text+=d.text):r.push(d);continue}if(d=this.tokenizer.emStrong(t,i,n)){t=t.substring(d.raw.length),r.push(d);continue}if(d=this.tokenizer.codespan(t)){t=t.substring(d.raw.length),r.push(d);continue}if(d=this.tokenizer.br(t)){t=t.substring(d.raw.length),r.push(d);continue}if(d=this.tokenizer.del(t)){t=t.substring(d.raw.length),r.push(d);continue}if(d=this.tokenizer.autolink(t)){t=t.substring(d.raw.length),r.push(d);continue}if(!this.state.inLink&&(d=this.tokenizer.url(t))){t=t.substring(d.raw.length),r.push(d);continue}let p=t;if((f=this.options.extensions)!=null&&f.startInline){let g=1/0,m=t.slice(1),C;this.options.extensions.startInline.forEach(x=>{C=x.call({lexer:this},m),typeof C=="number"&&C>=0&&(g=Math.min(g,C))}),g<1/0&&g>=0&&(p=t.substring(0,g+1))}if(d=this.tokenizer.inlineText(p)){t=t.substring(d.raw.length),d.raw.slice(-1)!=="_"&&(n=d.raw.slice(-1)),o=!0;let g=r.at(-1);(g==null?void 0:g.type)==="text"?(g.raw+=d.raw,g.text+=d.text):r.push(d);continue}if(t){let g="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(g);break}else throw new Error(g)}}return r}},Lo=class{constructor(t){St(this,"options");St(this,"parser");this.options=t||ti}space(t){return""}code({text:t,lang:r,escaped:i}){var o;let a=(o=(r||"").match(ae.notSpaceStart))==null?void 0:o[0],s=t.replace(ae.endingNewline,"")+`
199
+ `;return a?'<pre><code class="language-'+Re(a)+'">'+(i?s:Re(s,!0))+`</code></pre>
200
+ `:"<pre><code>"+(i?s:Re(s,!0))+`</code></pre>
201
+ `}blockquote({tokens:t}){return`<blockquote>
202
+ ${this.parser.parse(t)}</blockquote>
203
+ `}html({text:t}){return t}def(t){return""}heading({tokens:t,depth:r}){return`<h${r}>${this.parser.parseInline(t)}</h${r}>
204
+ `}hr(t){return`<hr>
205
+ `}list(t){let r=t.ordered,i=t.start,a="";for(let n=0;n<t.items.length;n++){let l=t.items[n];a+=this.listitem(l)}let s=r?"ol":"ul",o=r&&i!==1?' start="'+i+'"':"";return"<"+s+o+`>
206
+ `+a+"</"+s+`>
207
+ `}listitem(t){var i;let r="";if(t.task){let a=this.checkbox({checked:!!t.checked});t.loose?((i=t.tokens[0])==null?void 0:i.type)==="paragraph"?(t.tokens[0].text=a+" "+t.tokens[0].text,t.tokens[0].tokens&&t.tokens[0].tokens.length>0&&t.tokens[0].tokens[0].type==="text"&&(t.tokens[0].tokens[0].text=a+" "+Re(t.tokens[0].tokens[0].text),t.tokens[0].tokens[0].escaped=!0)):t.tokens.unshift({type:"text",raw:a+" ",text:a+" ",escaped:!0}):r+=a+" "}return r+=this.parser.parse(t.tokens,!!t.loose),`<li>${r}</li>
208
+ `}checkbox({checked:t}){return"<input "+(t?'checked="" ':"")+'disabled="" type="checkbox">'}paragraph({tokens:t}){return`<p>${this.parser.parseInline(t)}</p>
209
+ `}table(t){let r="",i="";for(let s=0;s<t.header.length;s++)i+=this.tablecell(t.header[s]);r+=this.tablerow({text:i});let a="";for(let s=0;s<t.rows.length;s++){let o=t.rows[s];i="";for(let n=0;n<o.length;n++)i+=this.tablecell(o[n]);a+=this.tablerow({text:i})}return a&&(a=`<tbody>${a}</tbody>`),`<table>
210
+ <thead>
211
+ `+r+`</thead>
212
+ `+a+`</table>
213
+ `}tablerow({text:t}){return`<tr>
214
+ ${t}</tr>
215
+ `}tablecell(t){let r=this.parser.parseInline(t.tokens),i=t.header?"th":"td";return(t.align?`<${i} align="${t.align}">`:`<${i}>`)+r+`</${i}>
216
+ `}strong({tokens:t}){return`<strong>${this.parser.parseInline(t)}</strong>`}em({tokens:t}){return`<em>${this.parser.parseInline(t)}</em>`}codespan({text:t}){return`<code>${Re(t,!0)}</code>`}br(t){return"<br>"}del({tokens:t}){return`<del>${this.parser.parseInline(t)}</del>`}link({href:t,title:r,tokens:i}){let a=this.parser.parseInline(i),s=sd(t);if(s===null)return a;t=s;let o='<a href="'+t+'"';return r&&(o+=' title="'+Re(r)+'"'),o+=">"+a+"</a>",o}image({href:t,title:r,text:i,tokens:a}){a&&(i=this.parser.parseInline(a,this.parser.textRenderer));let s=sd(t);if(s===null)return Re(i);t=s;let o=`<img src="${t}" alt="${i}"`;return r&&(o+=` title="${Re(r)}"`),o+=">",o}text(t){return"tokens"in t&&t.tokens?this.parser.parseInline(t.tokens):"escaped"in t&&t.escaped?t.text:Re(t.text)}},rc=class{strong({text:t}){return t}em({text:t}){return t}codespan({text:t}){return t}del({text:t}){return t}html({text:t}){return t}text({text:t}){return t}link({text:t}){return""+t}image({text:t}){return""+t}br(){return""}},Se=class Nl{constructor(t){St(this,"options");St(this,"renderer");St(this,"textRenderer");this.options=t||ti,this.options.renderer=this.options.renderer||new Lo,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new rc}static parse(t,r){return new Nl(r).parse(t)}static parseInline(t,r){return new Nl(r).parseInline(t)}parse(t,r=!0){var a,s;let i="";for(let o=0;o<t.length;o++){let n=t[o];if((s=(a=this.options.extensions)==null?void 0:a.renderers)!=null&&s[n.type]){let h=n,c=this.options.extensions.renderers[h.type].call({parser:this},h);if(c!==!1||!["space","hr","heading","code","table","blockquote","list","html","def","paragraph","text"].includes(h.type)){i+=c||"";continue}}let l=n;switch(l.type){case"space":{i+=this.renderer.space(l);continue}case"hr":{i+=this.renderer.hr(l);continue}case"heading":{i+=this.renderer.heading(l);continue}case"code":{i+=this.renderer.code(l);continue}case"table":{i+=this.renderer.table(l);continue}case"blockquote":{i+=this.renderer.blockquote(l);continue}case"list":{i+=this.renderer.list(l);continue}case"html":{i+=this.renderer.html(l);continue}case"def":{i+=this.renderer.def(l);continue}case"paragraph":{i+=this.renderer.paragraph(l);continue}case"text":{let h=l,c=this.renderer.text(h);for(;o+1<t.length&&t[o+1].type==="text";)h=t[++o],c+=`
217
+ `+this.renderer.text(h);r?i+=this.renderer.paragraph({type:"paragraph",raw:c,text:c,tokens:[{type:"text",raw:c,text:c,escaped:!0}]}):i+=c;continue}default:{let h='Token with "'+l.type+'" type was not found.';if(this.options.silent)return console.error(h),"";throw new Error(h)}}}return i}parseInline(t,r=this.renderer){var a,s;let i="";for(let o=0;o<t.length;o++){let n=t[o];if((s=(a=this.options.extensions)==null?void 0:a.renderers)!=null&&s[n.type]){let h=this.options.extensions.renderers[n.type].call({parser:this},n);if(h!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(n.type)){i+=h||"";continue}}let l=n;switch(l.type){case"escape":{i+=r.text(l);break}case"html":{i+=r.html(l);break}case"link":{i+=r.link(l);break}case"image":{i+=r.image(l);break}case"strong":{i+=r.strong(l);break}case"em":{i+=r.em(l);break}case"codespan":{i+=r.codespan(l);break}case"br":{i+=r.br(l);break}case"del":{i+=r.del(l);break}case"text":{i+=r.text(l);break}default:{let h='Token with "'+l.type+'" type was not found.';if(this.options.silent)return console.error(h),"";throw new Error(h)}}}return i}},_s,ba=(_s=class{constructor(t){St(this,"options");St(this,"block");this.options=t||ti}preprocess(t){return t}postprocess(t){return t}processAllTokens(t){return t}emStrongMask(t){return t}provideLexer(){return this.block?_e.lex:_e.lexInline}provideParser(){return this.block?Se.parse:Se.parseInline}},St(_s,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens","emStrongMask"])),St(_s,"passThroughHooksRespectAsync",new Set(["preprocess","postprocess","processAllTokens"])),_s),CM=class{constructor(...t){St(this,"defaults",Xh());St(this,"options",this.setOptions);St(this,"parse",this.parseMarkdown(!0));St(this,"parseInline",this.parseMarkdown(!1));St(this,"Parser",Se);St(this,"Renderer",Lo);St(this,"TextRenderer",rc);St(this,"Lexer",_e);St(this,"Tokenizer",Bo);St(this,"Hooks",ba);this.use(...t)}walkTokens(t,r){var a,s;let i=[];for(let o of t)switch(i=i.concat(r.call(this,o)),o.type){case"table":{let n=o;for(let l of n.header)i=i.concat(this.walkTokens(l.tokens,r));for(let l of n.rows)for(let h of l)i=i.concat(this.walkTokens(h.tokens,r));break}case"list":{let n=o;i=i.concat(this.walkTokens(n.items,r));break}default:{let n=o;(s=(a=this.defaults.extensions)==null?void 0:a.childTokens)!=null&&s[n.type]?this.defaults.extensions.childTokens[n.type].forEach(l=>{let h=n[l].flat(1/0);i=i.concat(this.walkTokens(h,r))}):n.tokens&&(i=i.concat(this.walkTokens(n.tokens,r)))}}return i}use(...t){let r=this.defaults.extensions||{renderers:{},childTokens:{}};return t.forEach(i=>{let a={...i};if(a.async=this.defaults.async||a.async||!1,i.extensions&&(i.extensions.forEach(s=>{if(!s.name)throw new Error("extension name required");if("renderer"in s){let o=r.renderers[s.name];o?r.renderers[s.name]=function(...n){let l=s.renderer.apply(this,n);return l===!1&&(l=o.apply(this,n)),l}:r.renderers[s.name]=s.renderer}if("tokenizer"in s){if(!s.level||s.level!=="block"&&s.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let o=r[s.level];o?o.unshift(s.tokenizer):r[s.level]=[s.tokenizer],s.start&&(s.level==="block"?r.startBlock?r.startBlock.push(s.start):r.startBlock=[s.start]:s.level==="inline"&&(r.startInline?r.startInline.push(s.start):r.startInline=[s.start]))}"childTokens"in s&&s.childTokens&&(r.childTokens[s.name]=s.childTokens)}),a.extensions=r),i.renderer){let s=this.defaults.renderer||new Lo(this.defaults);for(let o in i.renderer){if(!(o in s))throw new Error(`renderer '${o}' does not exist`);if(["options","parser"].includes(o))continue;let n=o,l=i.renderer[n],h=s[n];s[n]=(...c)=>{let u=l.apply(s,c);return u===!1&&(u=h.apply(s,c)),u||""}}a.renderer=s}if(i.tokenizer){let s=this.defaults.tokenizer||new Bo(this.defaults);for(let o in i.tokenizer){if(!(o in s))throw new Error(`tokenizer '${o}' does not exist`);if(["options","rules","lexer"].includes(o))continue;let n=o,l=i.tokenizer[n],h=s[n];s[n]=(...c)=>{let u=l.apply(s,c);return u===!1&&(u=h.apply(s,c)),u}}a.tokenizer=s}if(i.hooks){let s=this.defaults.hooks||new ba;for(let o in i.hooks){if(!(o in s))throw new Error(`hook '${o}' does not exist`);if(["options","block"].includes(o))continue;let n=o,l=i.hooks[n],h=s[n];ba.passThroughHooks.has(o)?s[n]=c=>{if(this.defaults.async&&ba.passThroughHooksRespectAsync.has(o))return(async()=>{let f=await l.call(s,c);return h.call(s,f)})();let u=l.call(s,c);return h.call(s,u)}:s[n]=(...c)=>{if(this.defaults.async)return(async()=>{let f=await l.apply(s,c);return f===!1&&(f=await h.apply(s,c)),f})();let u=l.apply(s,c);return u===!1&&(u=h.apply(s,c)),u}}a.hooks=s}if(i.walkTokens){let s=this.defaults.walkTokens,o=i.walkTokens;a.walkTokens=function(n){let l=[];return l.push(o.call(this,n)),s&&(l=l.concat(s.call(this,n))),l}}this.defaults={...this.defaults,...a}}),this}setOptions(t){return this.defaults={...this.defaults,...t},this}lexer(t,r){return _e.lex(t,r??this.defaults)}parser(t,r){return Se.parse(t,r??this.defaults)}parseMarkdown(t){return(r,i)=>{let a={...i},s={...this.defaults,...a},o=this.onError(!!s.silent,!!s.async);if(this.defaults.async===!0&&a.async===!1)return o(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof r>"u"||r===null)return o(new Error("marked(): input parameter is undefined or null"));if(typeof r!="string")return o(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(r)+", string expected"));if(s.hooks&&(s.hooks.options=s,s.hooks.block=t),s.async)return(async()=>{let n=s.hooks?await s.hooks.preprocess(r):r,l=await(s.hooks?await s.hooks.provideLexer():t?_e.lex:_e.lexInline)(n,s),h=s.hooks?await s.hooks.processAllTokens(l):l;s.walkTokens&&await Promise.all(this.walkTokens(h,s.walkTokens));let c=await(s.hooks?await s.hooks.provideParser():t?Se.parse:Se.parseInline)(h,s);return s.hooks?await s.hooks.postprocess(c):c})().catch(o);try{s.hooks&&(r=s.hooks.preprocess(r));let n=(s.hooks?s.hooks.provideLexer():t?_e.lex:_e.lexInline)(r,s);s.hooks&&(n=s.hooks.processAllTokens(n)),s.walkTokens&&this.walkTokens(n,s.walkTokens);let l=(s.hooks?s.hooks.provideParser():t?Se.parse:Se.parseInline)(n,s);return s.hooks&&(l=s.hooks.postprocess(l)),l}catch(n){return o(n)}}}onError(t,r){return i=>{if(i.message+=`
218
+ Please report this to https://github.com/markedjs/marked.`,t){let a="<p>An error occurred:</p><pre>"+Re(i.message+"",!0)+"</pre>";return r?Promise.resolve(a):a}if(r)return Promise.reject(i);throw i}}},jr=new CM;function _t(e,t){return jr.parse(e,t)}_t.options=_t.setOptions=function(e){return jr.setOptions(e),_t.defaults=jr.defaults,Rm(_t.defaults),_t};_t.getDefaults=Xh;_t.defaults=ti;_t.use=function(...e){return jr.use(...e),_t.defaults=jr.defaults,Rm(_t.defaults),_t};_t.walkTokens=function(e,t){return jr.walkTokens(e,t)};_t.parseInline=jr.parseInline;_t.Parser=Se;_t.parser=Se.parse;_t.Renderer=Lo;_t.TextRenderer=rc;_t.Lexer=_e;_t.lexer=_e.lex;_t.Tokenizer=Bo;_t.Hooks=ba;_t.parse=_t;_t.options;_t.setOptions;_t.use;_t.walkTokens;_t.parseInline;Se.parse;_e.lex;function Vm(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];var i=Array.from(typeof e=="string"?[e]:e);i[i.length-1]=i[i.length-1].replace(/\r?\n([\t ]*)$/,"");var a=i.reduce(function(n,l){var h=l.match(/\n([\t ]+|(?!\s).)/g);return h?n.concat(h.map(function(c){var u,f;return(f=(u=c.match(/[\t ]/g))===null||u===void 0?void 0:u.length)!==null&&f!==void 0?f:0})):n},[]);if(a.length){var s=new RegExp(`
219
+ [ ]{`+Math.min.apply(Math,a)+"}","g");i=i.map(function(n){return n.replace(s,`
220
+ `)})}i[0]=i[0].replace(/^\r?\n/,"");var o=i[0];return t.forEach(function(n,l){var h=o.match(/(?:^|\n)( *)$/),c=h?h[1]:"",u=n;typeof n=="string"&&n.includes(`
221
+ `)&&(u=String(n).split(`
222
+ `).map(function(f,d){return d===0?f:""+c+f}).join(`
223
+ `)),o+=u+i[l+1]}),o}var xM={body:'<g><rect width="80" height="80" style="fill: #087ebf; stroke-width: 0px;"/><text transform="translate(21.16 64.67)" style="fill: #fff; font-family: ArialMT, Arial; font-size: 67.75px;"><tspan x="0" y="0">?</tspan></text></g>',height:80,width:80},ql=new Map,Zm=new Map,bM=y(e=>{for(const t of e){if(!t.name)throw new Error('Invalid icon loader. Must have a "name" property with non-empty string value.');if(W.debug("Registering icon pack:",t.name),"loader"in t)Zm.set(t.name,t.loader);else if("icons"in t)ql.set(t.name,t.icons);else throw W.error("Invalid icon loader:",t),new Error('Invalid icon loader. Must have either "icons" or "loader" property.')}},"registerIconPacks"),Qm=y(async(e,t)=>{const r=kF(e,!0,t!==void 0);if(!r)throw new Error(`Invalid icon name: ${e}`);const i=r.prefix||t;if(!i)throw new Error(`Icon name must contain a prefix: ${e}`);let a=ql.get(i);if(!a){const o=Zm.get(i);if(!o)throw new Error(`Icon set not found: ${r.prefix}`);try{a={...await o(),prefix:i},ql.set(i,a)}catch(n){throw W.error(n),new Error(`Failed to load icon set: ${r.prefix}`)}}const s=_F(a,r.name);if(!s)throw new Error(`Icon not found: ${e}`);return s},"getRegisteredIconData"),kM=y(async e=>{try{return await Qm(e),!0}catch{return!1}},"isIconAvailable"),Ja=y(async(e,t,r)=>{let i;try{i=await Qm(e,t==null?void 0:t.fallbackPrefix)}catch(o){W.error(o),i=xM}const a=AF(i,t),s=OF(DF(a.body),{...a.attributes,...r});return Ae(s,At())},"getIconSVG");function Km(e,{markdownAutoWrap:t}){const i=e.replace(/<br\/>/g,`
224
+ `).replace(/\n{2,}/g,`
225
+ `);return Vm(i)}y(Km,"preprocessMarkdown");function Jm(e){return e.split(/\\n|\n|<br\s*\/?>/gi).map(t=>{var r;return((r=t.trim().match(/<[^>]+>|[^\s<>]+/g))==null?void 0:r.map(i=>({content:i,type:"normal"})))??[]})}y(Jm,"nonMarkdownToLines");function t0(e,t={}){const r=Km(e,t),i=_t.lexer(r),a=[[]];let s=0;function o(n,l="normal"){n.type==="text"?n.text.split(`
226
+ `).forEach((c,u)=>{u!==0&&(s++,a.push([])),c.split(" ").forEach(f=>{f=f.replace(/&#39;/g,"'"),f&&a[s].push({content:f,type:l})})}):n.type==="strong"||n.type==="em"?n.tokens.forEach(h=>{o(h,n.type)}):n.type==="html"&&a[s].push({content:n.text,type:"normal"})}return y(o,"processNode"),i.forEach(n=>{var l;n.type==="paragraph"?(l=n.tokens)==null||l.forEach(h=>{o(h)}):n.type==="html"?a[s].push({content:n.text,type:"normal"}):a[s].push({content:n.raw,type:"normal"})}),a}y(t0,"markdownToLines");function e0(e){return e?`<p>${e.replace(/\\n|\n/g,"<br />")}</p>`:""}y(e0,"nonMarkdownToHTML");function r0(e,{markdownAutoWrap:t}={}){const r=_t.lexer(e);function i(a){var s,o,n;return a.type==="text"?t===!1?a.text.replace(/\n */g,"<br/>").replace(/ /g,"&nbsp;"):a.text.replace(/\n */g,"<br/>"):a.type==="strong"?`<strong>${(s=a.tokens)==null?void 0:s.map(i).join("")}</strong>`:a.type==="em"?`<em>${(o=a.tokens)==null?void 0:o.map(i).join("")}</em>`:a.type==="paragraph"?`<p>${(n=a.tokens)==null?void 0:n.map(i).join("")}</p>`:a.type==="space"?"":a.type==="html"?`${a.text}`:a.type==="escape"?a.text:(W.warn(`Unsupported markdown: ${a.type}`),a.raw)}return y(i,"output"),r.map(i).join("")}y(r0,"markdownToHTML");function i0(e){return Intl.Segmenter?[...new Intl.Segmenter().segment(e)].map(t=>t.segment):[...e]}y(i0,"splitTextToChars");function a0(e,t){const r=i0(t.content);return ic(e,[],r,t.type)}y(a0,"splitWordToFitWidth");function ic(e,t,r,i){if(r.length===0)return[{content:t.join(""),type:i},{content:"",type:i}];const[a,...s]=r,o=[...t,a];return e([{content:o.join(""),type:i}])?ic(e,o,s,i):(t.length===0&&a&&(t.push(a),r.shift()),[{content:t.join(""),type:i},{content:r.join(""),type:i}])}y(ic,"splitWordToFitWidthRecursion");function s0(e,t){if(e.some(({content:r})=>r.includes(`
227
+ `)))throw new Error("splitLineToFitWidth does not support newlines in the line");return Fo(e,t)}y(s0,"splitLineToFitWidth");function Fo(e,t,r=[],i=[]){if(e.length===0)return i.length>0&&r.push(i),r.length>0?r:[];let a="";e[0].content===" "&&(a=" ",e.shift());const s=e.shift()??{content:" ",type:"normal"},o=[...i];if(a!==""&&o.push({content:a,type:"normal"}),o.push(s),t(o))return Fo(e,t,r,o);if(i.length>0)r.push(i),e.unshift(s);else if(s.content){const[n,l]=a0(t,s);r.push([n]),l.content&&e.unshift(l)}return Fo(e,t,r)}y(Fo,"splitLineToFitWidthRecursion");function zl(e,t){t&&e.attr("style",t)}y(zl,"applyStyle");var ld=16384;async function o0(e,t,r,i,a=!1,s=At()){const o=e.append("foreignObject");o.attr("width",`${Math.min(10*r,ld)}px`),o.attr("height",`${Math.min(10*r,ld)}px`);const n=o.append("xhtml:div"),l=Ma(t.label)?await cf(t.label.replace(Ya.lineBreakRegex,`
228
+ `),s):Ae(t.label,s),h=t.isNode?"nodeLabel":"edgeLabel",c=n.append("span");c.html(l),zl(c,t.labelStyle),c.attr("class",`${h} ${i}`),zl(n,t.labelStyle),n.style("display","table-cell"),n.style("white-space","nowrap"),n.style("line-height","1.5"),r!==Number.POSITIVE_INFINITY&&(n.style("max-width",r+"px"),n.style("text-align","center")),n.attr("xmlns","http://www.w3.org/1999/xhtml"),a&&n.attr("class","labelBkg");let u=n.node().getBoundingClientRect();return u.width===r&&(n.style("display","table"),n.style("white-space","break-spaces"),n.style("width",r+"px"),u=n.node().getBoundingClientRect()),o.node()}y(o0,"addHtmlSpan");function an(e,t,r,i=!1){const a=e.append("tspan").attr("class","text-outer-tspan").attr("x",0).attr("y",t*r-.1+"em").attr("dy",r+"em");return i&&a.attr("text-anchor","middle"),a}y(an,"createTspan");function n0(e,t,r){const i=e.append("text"),a=an(i,1,t);sn(a,r);const s=a.node().getComputedTextLength();return i.remove(),s}y(n0,"computeWidthOfText");function TM(e,t,r){var o;const i=e.append("text"),a=an(i,1,t);sn(a,[{content:r,type:"normal"}]);const s=(o=a.node())==null?void 0:o.getBoundingClientRect();return s&&i.remove(),s}y(TM,"computeDimensionOfText");function l0(e,t,r,i=!1,a=!1){const o=t.append("g"),n=o.insert("rect").attr("class","background").attr("style","stroke: none"),l=o.append("text").attr("y","-10.1");a&&l.attr("text-anchor","middle");let h=0;for(const c of r){const u=y(d=>n0(o,1.1,d)<=e,"checkWidth"),f=u(c)?[c]:s0(c,u);for(const d of f){const p=an(l,h,1.1,a);sn(p,d),h++}}if(i){const c=l.node().getBBox(),u=2;return n.attr("x",c.x-u).attr("y",c.y-u).attr("width",c.width+2*u).attr("height",c.height+2*u),o.node()}else return l.node()}y(l0,"createFormattedText");function Wl(e){const t=/&(amp|lt|gt);/g;return e.replace(t,(r,i)=>{switch(i){case"amp":return"&";case"lt":return"<";case"gt":return">";default:return r}})}y(Wl,"decodeHTMLEntities");function sn(e,t){e.text(""),t.forEach((r,i)=>{const a=e.append("tspan").attr("font-style",r.type==="em"?"italic":"normal").attr("class","text-inner-tspan").attr("font-weight",r.type==="strong"?"bold":"normal");i===0?a.text(Wl(r.content)):a.text(" "+Wl(r.content))})}y(sn,"updateTextContentAndStyles");async function h0(e,t={}){const r=[];e.replace(/(fa[bklrs]?):fa-([\w-]+)/g,(a,s,o)=>(r.push((async()=>{const n=`${s}:${o}`;return await kM(n)?await Ja(n,void 0,{class:"label-icon"}):`<i class='${Ae(a,t).replace(":"," ")}'></i>`})()),a));const i=await Promise.all(r);return e.replace(/(fa[bklrs]?):fa-([\w-]+)/g,()=>i.shift()??"")}y(h0,"replaceIconSubstring");var dr=y(async(e,t="",{style:r="",isTitle:i=!1,classes:a="",useHtmlLabels:s=!0,markdown:o=!0,isNode:n=!0,width:l=200,addSvgBackground:h=!1}={},c)=>{if(W.debug("XYZ createText",t,r,i,a,s,n,"addSvgBackground: ",h),s){const u=o?r0(t,c):e0(t),f=await h0(Yr(u),c),d=t.replace(/\\\\/g,"\\"),p={isNode:n,label:Ma(t)?d:f,labelStyle:r.replace("fill:","color:")};return await o0(e,p,l,a,h,c)}else{const u=Yr(t.replace(/<br\s*\/?>/g,"<br/>")),f=o?t0(u.replace("<br>","<br/>"),c):Jm(u),d=l0(l,e,f,t?h:!1,!n);if(n){/stroke:/.exec(r)&&(r=r.replace("stroke:","lineColor:"));const p=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");pt(d).attr("style",p)}else{const p=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/background:/g,"fill:");pt(d).select("rect").attr("style",p.replace(/background:/g,"fill:"));const g=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");pt(d).select("text").attr("style",g)}return i?pt(d).selectAll("tspan.text-outer-tspan").classed("title-row",!0):pt(d).selectAll("tspan.text-outer-tspan").classed("row",!0),d}},"createText");function Hn(e,t,r){if(e&&e.length){const[i,a]=t,s=Math.PI/180*r,o=Math.cos(s),n=Math.sin(s);for(const l of e){const[h,c]=l;l[0]=(h-i)*o-(c-a)*n+i,l[1]=(h-i)*n+(c-a)*o+a}}}function wM(e,t){return e[0]===t[0]&&e[1]===t[1]}function _M(e,t,r,i=1){const a=r,s=Math.max(t,.1),o=e[0]&&e[0][0]&&typeof e[0][0]=="number"?[e]:e,n=[0,0];if(a)for(const h of o)Hn(h,n,a);const l=(function(h,c,u){const f=[];for(const x of h){const k=[...x];wM(k[0],k[k.length-1])||k.push([k[0][0],k[0][1]]),k.length>2&&f.push(k)}const d=[];c=Math.max(c,.1);const p=[];for(const x of f)for(let k=0;k<x.length-1;k++){const w=x[k],S=x[k+1];if(w[1]!==S[1]){const _=Math.min(w[1],S[1]);p.push({ymin:_,ymax:Math.max(w[1],S[1]),x:_===w[1]?w[0]:S[0],islope:(S[0]-w[0])/(S[1]-w[1])})}}if(p.sort(((x,k)=>x.ymin<k.ymin?-1:x.ymin>k.ymin?1:x.x<k.x?-1:x.x>k.x?1:x.ymax===k.ymax?0:(x.ymax-k.ymax)/Math.abs(x.ymax-k.ymax))),!p.length)return d;let g=[],m=p[0].ymin,C=0;for(;g.length||p.length;){if(p.length){let x=-1;for(let k=0;k<p.length&&!(p[k].ymin>m);k++)x=k;p.splice(0,x+1).forEach((k=>{g.push({s:m,edge:k})}))}if(g=g.filter((x=>!(x.edge.ymax<=m))),g.sort(((x,k)=>x.edge.x===k.edge.x?0:(x.edge.x-k.edge.x)/Math.abs(x.edge.x-k.edge.x))),(u!==1||C%c==0)&&g.length>1)for(let x=0;x<g.length;x+=2){const k=x+1;if(k>=g.length)break;const w=g[x].edge,S=g[k].edge;d.push([[Math.round(w.x),m],[Math.round(S.x),m]])}m+=u,g.forEach((x=>{x.edge.x=x.edge.x+u*x.edge.islope})),C++}return d})(o,s,i);if(a){for(const h of o)Hn(h,n,-a);(function(h,c,u){const f=[];h.forEach((d=>f.push(...d))),Hn(f,c,u)})(l,n,-a)}return l}function ts(e,t){var r;const i=t.hachureAngle+90;let a=t.hachureGap;a<0&&(a=4*t.strokeWidth),a=Math.round(Math.max(a,.1));let s=1;return t.roughness>=1&&(((r=t.randomizer)===null||r===void 0?void 0:r.next())||Math.random())>.7&&(s=a),_M(e,a,i,s||1)}class ac{constructor(t){this.helper=t}fillPolygons(t,r){return this._fillPolygons(t,r)}_fillPolygons(t,r){const i=ts(t,r);return{type:"fillSketch",ops:this.renderLines(i,r)}}renderLines(t,r){const i=[];for(const a of t)i.push(...this.helper.doubleLineOps(a[0][0],a[0][1],a[1][0],a[1][1],r));return i}}function on(e){const t=e[0],r=e[1];return Math.sqrt(Math.pow(t[0]-r[0],2)+Math.pow(t[1]-r[1],2))}class SM extends ac{fillPolygons(t,r){let i=r.hachureGap;i<0&&(i=4*r.strokeWidth),i=Math.max(i,.1);const a=ts(t,Object.assign({},r,{hachureGap:i})),s=Math.PI/180*r.hachureAngle,o=[],n=.5*i*Math.cos(s),l=.5*i*Math.sin(s);for(const[h,c]of a)on([h,c])&&o.push([[h[0]-n,h[1]+l],[...c]],[[h[0]+n,h[1]-l],[...c]]);return{type:"fillSketch",ops:this.renderLines(o,r)}}}class vM extends ac{fillPolygons(t,r){const i=this._fillPolygons(t,r),a=Object.assign({},r,{hachureAngle:r.hachureAngle+90}),s=this._fillPolygons(t,a);return i.ops=i.ops.concat(s.ops),i}}class BM{constructor(t){this.helper=t}fillPolygons(t,r){const i=ts(t,r=Object.assign({},r,{hachureAngle:0}));return this.dotsOnLines(i,r)}dotsOnLines(t,r){const i=[];let a=r.hachureGap;a<0&&(a=4*r.strokeWidth),a=Math.max(a,.1);let s=r.fillWeight;s<0&&(s=r.strokeWidth/2);const o=a/4;for(const n of t){const l=on(n),h=l/a,c=Math.ceil(h)-1,u=l-c*a,f=(n[0][0]+n[1][0])/2-a/4,d=Math.min(n[0][1],n[1][1]);for(let p=0;p<c;p++){const g=d+u+p*a,m=f-o+2*Math.random()*o,C=g-o+2*Math.random()*o,x=this.helper.ellipse(m,C,s,s,r);i.push(...x.ops)}}return{type:"fillSketch",ops:i}}}class LM{constructor(t){this.helper=t}fillPolygons(t,r){const i=ts(t,r);return{type:"fillSketch",ops:this.dashedLine(i,r)}}dashedLine(t,r){const i=r.dashOffset<0?r.hachureGap<0?4*r.strokeWidth:r.hachureGap:r.dashOffset,a=r.dashGap<0?r.hachureGap<0?4*r.strokeWidth:r.hachureGap:r.dashGap,s=[];return t.forEach((o=>{const n=on(o),l=Math.floor(n/(i+a)),h=(n+a-l*(i+a))/2;let c=o[0],u=o[1];c[0]>u[0]&&(c=o[1],u=o[0]);const f=Math.atan((u[1]-c[1])/(u[0]-c[0]));for(let d=0;d<l;d++){const p=d*(i+a),g=p+i,m=[c[0]+p*Math.cos(f)+h*Math.cos(f),c[1]+p*Math.sin(f)+h*Math.sin(f)],C=[c[0]+g*Math.cos(f)+h*Math.cos(f),c[1]+g*Math.sin(f)+h*Math.sin(f)];s.push(...this.helper.doubleLineOps(m[0],m[1],C[0],C[1],r))}})),s}}class FM{constructor(t){this.helper=t}fillPolygons(t,r){const i=r.hachureGap<0?4*r.strokeWidth:r.hachureGap,a=r.zigzagOffset<0?i:r.zigzagOffset,s=ts(t,r=Object.assign({},r,{hachureGap:i+a}));return{type:"fillSketch",ops:this.zigzagLines(s,a,r)}}zigzagLines(t,r,i){const a=[];return t.forEach((s=>{const o=on(s),n=Math.round(o/(2*r));let l=s[0],h=s[1];l[0]>h[0]&&(l=s[1],h=s[0]);const c=Math.atan((h[1]-l[1])/(h[0]-l[0]));for(let u=0;u<n;u++){const f=2*u*r,d=2*(u+1)*r,p=Math.sqrt(2*Math.pow(r,2)),g=[l[0]+f*Math.cos(c),l[1]+f*Math.sin(c)],m=[l[0]+d*Math.cos(c),l[1]+d*Math.sin(c)],C=[g[0]+p*Math.cos(c+Math.PI/4),g[1]+p*Math.sin(c+Math.PI/4)];a.push(...this.helper.doubleLineOps(g[0],g[1],C[0],C[1],i),...this.helper.doubleLineOps(C[0],C[1],m[0],m[1],i))}})),a}}const he={};class MM{constructor(t){this.seed=t}next(){return this.seed?(2**31-1&(this.seed=Math.imul(48271,this.seed)))/2**31:Math.random()}}const AM=0,Un=1,hd=2,xs={A:7,a:7,C:6,c:6,H:1,h:1,L:2,l:2,M:2,m:2,Q:4,q:4,S:4,s:4,T:2,t:2,V:1,v:1,Z:0,z:0};function Yn(e,t){return e.type===t}function sc(e){const t=[],r=(function(o){const n=new Array;for(;o!=="";)if(o.match(/^([ \t\r\n,]+)/))o=o.substr(RegExp.$1.length);else if(o.match(/^([aAcChHlLmMqQsStTvVzZ])/))n[n.length]={type:AM,text:RegExp.$1},o=o.substr(RegExp.$1.length);else{if(!o.match(/^(([-+]?[0-9]+(\.[0-9]*)?|[-+]?\.[0-9]+)([eE][-+]?[0-9]+)?)/))return[];n[n.length]={type:Un,text:`${parseFloat(RegExp.$1)}`},o=o.substr(RegExp.$1.length)}return n[n.length]={type:hd,text:""},n})(e);let i="BOD",a=0,s=r[a];for(;!Yn(s,hd);){let o=0;const n=[];if(i==="BOD"){if(s.text!=="M"&&s.text!=="m")return sc("M0,0"+e);a++,o=xs[s.text],i=s.text}else Yn(s,Un)?o=xs[i]:(a++,o=xs[s.text],i=s.text);if(!(a+o<r.length))throw new Error("Path data ended short");for(let l=a;l<a+o;l++){const h=r[l];if(!Yn(h,Un))throw new Error("Param not a number: "+i+","+h.text);n[n.length]=+h.text}if(typeof xs[i]!="number")throw new Error("Bad segment: "+i);{const l={key:i,data:n};t.push(l),a+=o,s=r[a],i==="M"&&(i="L"),i==="m"&&(i="l")}}return t}function c0(e){let t=0,r=0,i=0,a=0;const s=[];for(const{key:o,data:n}of e)switch(o){case"M":s.push({key:"M",data:[...n]}),[t,r]=n,[i,a]=n;break;case"m":t+=n[0],r+=n[1],s.push({key:"M",data:[t,r]}),i=t,a=r;break;case"L":s.push({key:"L",data:[...n]}),[t,r]=n;break;case"l":t+=n[0],r+=n[1],s.push({key:"L",data:[t,r]});break;case"C":s.push({key:"C",data:[...n]}),t=n[4],r=n[5];break;case"c":{const l=n.map(((h,c)=>c%2?h+r:h+t));s.push({key:"C",data:l}),t=l[4],r=l[5];break}case"Q":s.push({key:"Q",data:[...n]}),t=n[2],r=n[3];break;case"q":{const l=n.map(((h,c)=>c%2?h+r:h+t));s.push({key:"Q",data:l}),t=l[2],r=l[3];break}case"A":s.push({key:"A",data:[...n]}),t=n[5],r=n[6];break;case"a":t+=n[5],r+=n[6],s.push({key:"A",data:[n[0],n[1],n[2],n[3],n[4],t,r]});break;case"H":s.push({key:"H",data:[...n]}),t=n[0];break;case"h":t+=n[0],s.push({key:"H",data:[t]});break;case"V":s.push({key:"V",data:[...n]}),r=n[0];break;case"v":r+=n[0],s.push({key:"V",data:[r]});break;case"S":s.push({key:"S",data:[...n]}),t=n[2],r=n[3];break;case"s":{const l=n.map(((h,c)=>c%2?h+r:h+t));s.push({key:"S",data:l}),t=l[2],r=l[3];break}case"T":s.push({key:"T",data:[...n]}),t=n[0],r=n[1];break;case"t":t+=n[0],r+=n[1],s.push({key:"T",data:[t,r]});break;case"Z":case"z":s.push({key:"Z",data:[]}),t=i,r=a}return s}function u0(e){const t=[];let r="",i=0,a=0,s=0,o=0,n=0,l=0;for(const{key:h,data:c}of e){switch(h){case"M":t.push({key:"M",data:[...c]}),[i,a]=c,[s,o]=c;break;case"C":t.push({key:"C",data:[...c]}),i=c[4],a=c[5],n=c[2],l=c[3];break;case"L":t.push({key:"L",data:[...c]}),[i,a]=c;break;case"H":i=c[0],t.push({key:"L",data:[i,a]});break;case"V":a=c[0],t.push({key:"L",data:[i,a]});break;case"S":{let u=0,f=0;r==="C"||r==="S"?(u=i+(i-n),f=a+(a-l)):(u=i,f=a),t.push({key:"C",data:[u,f,...c]}),n=c[0],l=c[1],i=c[2],a=c[3];break}case"T":{const[u,f]=c;let d=0,p=0;r==="Q"||r==="T"?(d=i+(i-n),p=a+(a-l)):(d=i,p=a);const g=i+2*(d-i)/3,m=a+2*(p-a)/3,C=u+2*(d-u)/3,x=f+2*(p-f)/3;t.push({key:"C",data:[g,m,C,x,u,f]}),n=d,l=p,i=u,a=f;break}case"Q":{const[u,f,d,p]=c,g=i+2*(u-i)/3,m=a+2*(f-a)/3,C=d+2*(u-d)/3,x=p+2*(f-p)/3;t.push({key:"C",data:[g,m,C,x,d,p]}),n=u,l=f,i=d,a=p;break}case"A":{const u=Math.abs(c[0]),f=Math.abs(c[1]),d=c[2],p=c[3],g=c[4],m=c[5],C=c[6];u===0||f===0?(t.push({key:"C",data:[i,a,m,C,m,C]}),i=m,a=C):(i!==m||a!==C)&&(d0(i,a,m,C,u,f,d,p,g).forEach((function(x){t.push({key:"C",data:x})})),i=m,a=C);break}case"Z":t.push({key:"Z",data:[]}),i=s,a=o}r=h}return t}function da(e,t,r){return[e*Math.cos(r)-t*Math.sin(r),e*Math.sin(r)+t*Math.cos(r)]}function d0(e,t,r,i,a,s,o,n,l,h){const c=(u=o,Math.PI*u/180);var u;let f=[],d=0,p=0,g=0,m=0;if(h)[d,p,g,m]=h;else{[e,t]=da(e,t,-c),[r,i]=da(r,i,-c);const D=(e-r)/2,M=(t-i)/2;let $=D*D/(a*a)+M*M/(s*s);$>1&&($=Math.sqrt($),a*=$,s*=$);const A=a*a,O=s*s,F=A*O-A*M*M-O*D*D,H=A*M*M+O*D*D,Y=(n===l?-1:1)*Math.sqrt(Math.abs(F/H));g=Y*a*M/s+(e+r)/2,m=Y*-s*D/a+(t+i)/2,d=Math.asin(parseFloat(((t-m)/s).toFixed(9))),p=Math.asin(parseFloat(((i-m)/s).toFixed(9))),e<g&&(d=Math.PI-d),r<g&&(p=Math.PI-p),d<0&&(d=2*Math.PI+d),p<0&&(p=2*Math.PI+p),l&&d>p&&(d-=2*Math.PI),!l&&p>d&&(p-=2*Math.PI)}let C=p-d;if(Math.abs(C)>120*Math.PI/180){const D=p,M=r,$=i;p=l&&p>d?d+120*Math.PI/180*1:d+120*Math.PI/180*-1,f=d0(r=g+a*Math.cos(p),i=m+s*Math.sin(p),M,$,a,s,o,0,l,[p,D,g,m])}C=p-d;const x=Math.cos(d),k=Math.sin(d),w=Math.cos(p),S=Math.sin(p),_=Math.tan(C/4),T=4/3*a*_,B=4/3*s*_,z=[e,t],I=[e+T*k,t-B*x],E=[r+T*S,i-B*w],N=[r,i];if(I[0]=2*z[0]-I[0],I[1]=2*z[1]-I[1],h)return[I,E,N].concat(f);{f=[I,E,N].concat(f);const D=[];for(let M=0;M<f.length;M+=3){const $=da(f[M][0],f[M][1],c),A=da(f[M+1][0],f[M+1][1],c),O=da(f[M+2][0],f[M+2][1],c);D.push([$[0],$[1],A[0],A[1],O[0],O[1]])}return D}}const EM={randOffset:function(e,t){return lt(e,t)},randOffsetWithRange:function(e,t,r){return Mo(e,t,r)},ellipse:function(e,t,r,i,a){const s=p0(r,i,a);return Hl(e,t,a,s).opset},doubleLineOps:function(e,t,r,i,a){return kr(e,t,r,i,a,!0)}};function f0(e,t,r,i,a){return{type:"path",ops:kr(e,t,r,i,a)}}function Rs(e,t,r){const i=(e||[]).length;if(i>2){const a=[];for(let s=0;s<i-1;s++)a.push(...kr(e[s][0],e[s][1],e[s+1][0],e[s+1][1],r));return t&&a.push(...kr(e[i-1][0],e[i-1][1],e[0][0],e[0][1],r)),{type:"path",ops:a}}return i===2?f0(e[0][0],e[0][1],e[1][0],e[1][1],r):{type:"path",ops:[]}}function $M(e,t,r,i,a){return(function(s,o){return Rs(s,!0,o)})([[e,t],[e+r,t],[e+r,t+i],[e,t+i]],a)}function cd(e,t){if(e.length){const r=typeof e[0][0]=="number"?[e]:e,i=bs(r[0],1*(1+.2*t.roughness),t),a=t.disableMultiStroke?[]:bs(r[0],1.5*(1+.22*t.roughness),fd(t));for(let s=1;s<r.length;s++){const o=r[s];if(o.length){const n=bs(o,1*(1+.2*t.roughness),t),l=t.disableMultiStroke?[]:bs(o,1.5*(1+.22*t.roughness),fd(t));for(const h of n)h.op!=="move"&&i.push(h);for(const h of l)h.op!=="move"&&a.push(h)}}return{type:"path",ops:i.concat(a)}}return{type:"path",ops:[]}}function p0(e,t,r){const i=Math.sqrt(2*Math.PI*Math.sqrt((Math.pow(e/2,2)+Math.pow(t/2,2))/2)),a=Math.ceil(Math.max(r.curveStepCount,r.curveStepCount/Math.sqrt(200)*i)),s=2*Math.PI/a;let o=Math.abs(e/2),n=Math.abs(t/2);const l=1-r.curveFitting;return o+=lt(o*l,r),n+=lt(n*l,r),{increment:s,rx:o,ry:n}}function Hl(e,t,r,i){const[a,s]=pd(i.increment,e,t,i.rx,i.ry,1,i.increment*Mo(.1,Mo(.4,1,r),r),r);let o=Ao(a,null,r);if(!r.disableMultiStroke&&r.roughness!==0){const[n]=pd(i.increment,e,t,i.rx,i.ry,1.5,0,r),l=Ao(n,null,r);o=o.concat(l)}return{estimatedPoints:s,opset:{type:"path",ops:o}}}function ud(e,t,r,i,a,s,o,n,l){const h=e,c=t;let u=Math.abs(r/2),f=Math.abs(i/2);u+=lt(.01*u,l),f+=lt(.01*f,l);let d=a,p=s;for(;d<0;)d+=2*Math.PI,p+=2*Math.PI;p-d>2*Math.PI&&(d=0,p=2*Math.PI);const g=2*Math.PI/l.curveStepCount,m=Math.min(g/2,(p-d)/2),C=gd(m,h,c,u,f,d,p,1,l);if(!l.disableMultiStroke){const x=gd(m,h,c,u,f,d,p,1.5,l);C.push(...x)}return o&&(n?C.push(...kr(h,c,h+u*Math.cos(d),c+f*Math.sin(d),l),...kr(h,c,h+u*Math.cos(p),c+f*Math.sin(p),l)):C.push({op:"lineTo",data:[h,c]},{op:"lineTo",data:[h+u*Math.cos(d),c+f*Math.sin(d)]})),{type:"path",ops:C}}function dd(e,t){const r=u0(c0(sc(e))),i=[];let a=[0,0],s=[0,0];for(const{key:o,data:n}of r)switch(o){case"M":s=[n[0],n[1]],a=[n[0],n[1]];break;case"L":i.push(...kr(s[0],s[1],n[0],n[1],t)),s=[n[0],n[1]];break;case"C":{const[l,h,c,u,f,d]=n;i.push(...DM(l,h,c,u,f,d,s,t)),s=[f,d];break}case"Z":i.push(...kr(s[0],s[1],a[0],a[1],t)),s=[a[0],a[1]]}return{type:"path",ops:i}}function jn(e,t){const r=[];for(const i of e)if(i.length){const a=t.maxRandomnessOffset||0,s=i.length;if(s>2){r.push({op:"move",data:[i[0][0]+lt(a,t),i[0][1]+lt(a,t)]});for(let o=1;o<s;o++)r.push({op:"lineTo",data:[i[o][0]+lt(a,t),i[o][1]+lt(a,t)]})}}return{type:"fillPath",ops:r}}function oi(e,t){return(function(r,i){let a=r.fillStyle||"hachure";if(!he[a])switch(a){case"zigzag":he[a]||(he[a]=new SM(i));break;case"cross-hatch":he[a]||(he[a]=new vM(i));break;case"dots":he[a]||(he[a]=new BM(i));break;case"dashed":he[a]||(he[a]=new LM(i));break;case"zigzag-line":he[a]||(he[a]=new FM(i));break;default:a="hachure",he[a]||(he[a]=new ac(i))}return he[a]})(t,EM).fillPolygons(e,t)}function fd(e){const t=Object.assign({},e);return t.randomizer=void 0,e.seed&&(t.seed=e.seed+1),t}function g0(e){return e.randomizer||(e.randomizer=new MM(e.seed||0)),e.randomizer.next()}function Mo(e,t,r,i=1){return r.roughness*i*(g0(r)*(t-e)+e)}function lt(e,t,r=1){return Mo(-e,e,t,r)}function kr(e,t,r,i,a,s=!1){const o=s?a.disableMultiStrokeFill:a.disableMultiStroke,n=Ul(e,t,r,i,a,!0,!1);if(o)return n;const l=Ul(e,t,r,i,a,!0,!0);return n.concat(l)}function Ul(e,t,r,i,a,s,o){const n=Math.pow(e-r,2)+Math.pow(t-i,2),l=Math.sqrt(n);let h=1;h=l<200?1:l>500?.4:-.0016668*l+1.233334;let c=a.maxRandomnessOffset||0;c*c*100>n&&(c=l/10);const u=c/2,f=.2+.2*g0(a);let d=a.bowing*a.maxRandomnessOffset*(i-t)/200,p=a.bowing*a.maxRandomnessOffset*(e-r)/200;d=lt(d,a,h),p=lt(p,a,h);const g=[],m=()=>lt(u,a,h),C=()=>lt(c,a,h),x=a.preserveVertices;return o?g.push({op:"move",data:[e+(x?0:m()),t+(x?0:m())]}):g.push({op:"move",data:[e+(x?0:lt(c,a,h)),t+(x?0:lt(c,a,h))]}),o?g.push({op:"bcurveTo",data:[d+e+(r-e)*f+m(),p+t+(i-t)*f+m(),d+e+2*(r-e)*f+m(),p+t+2*(i-t)*f+m(),r+(x?0:m()),i+(x?0:m())]}):g.push({op:"bcurveTo",data:[d+e+(r-e)*f+C(),p+t+(i-t)*f+C(),d+e+2*(r-e)*f+C(),p+t+2*(i-t)*f+C(),r+(x?0:C()),i+(x?0:C())]}),g}function bs(e,t,r){if(!e.length)return[];const i=[];i.push([e[0][0]+lt(t,r),e[0][1]+lt(t,r)]),i.push([e[0][0]+lt(t,r),e[0][1]+lt(t,r)]);for(let a=1;a<e.length;a++)i.push([e[a][0]+lt(t,r),e[a][1]+lt(t,r)]),a===e.length-1&&i.push([e[a][0]+lt(t,r),e[a][1]+lt(t,r)]);return Ao(i,null,r)}function Ao(e,t,r){const i=e.length,a=[];if(i>3){const s=[],o=1-r.curveTightness;a.push({op:"move",data:[e[1][0],e[1][1]]});for(let n=1;n+2<i;n++){const l=e[n];s[0]=[l[0],l[1]],s[1]=[l[0]+(o*e[n+1][0]-o*e[n-1][0])/6,l[1]+(o*e[n+1][1]-o*e[n-1][1])/6],s[2]=[e[n+1][0]+(o*e[n][0]-o*e[n+2][0])/6,e[n+1][1]+(o*e[n][1]-o*e[n+2][1])/6],s[3]=[e[n+1][0],e[n+1][1]],a.push({op:"bcurveTo",data:[s[1][0],s[1][1],s[2][0],s[2][1],s[3][0],s[3][1]]})}}else i===3?(a.push({op:"move",data:[e[1][0],e[1][1]]}),a.push({op:"bcurveTo",data:[e[1][0],e[1][1],e[2][0],e[2][1],e[2][0],e[2][1]]})):i===2&&a.push(...Ul(e[0][0],e[0][1],e[1][0],e[1][1],r,!0,!0));return a}function pd(e,t,r,i,a,s,o,n){const l=[],h=[];if(n.roughness===0){e/=4,h.push([t+i*Math.cos(-e),r+a*Math.sin(-e)]);for(let c=0;c<=2*Math.PI;c+=e){const u=[t+i*Math.cos(c),r+a*Math.sin(c)];l.push(u),h.push(u)}h.push([t+i*Math.cos(0),r+a*Math.sin(0)]),h.push([t+i*Math.cos(e),r+a*Math.sin(e)])}else{const c=lt(.5,n)-Math.PI/2;h.push([lt(s,n)+t+.9*i*Math.cos(c-e),lt(s,n)+r+.9*a*Math.sin(c-e)]);const u=2*Math.PI+c-.01;for(let f=c;f<u;f+=e){const d=[lt(s,n)+t+i*Math.cos(f),lt(s,n)+r+a*Math.sin(f)];l.push(d),h.push(d)}h.push([lt(s,n)+t+i*Math.cos(c+2*Math.PI+.5*o),lt(s,n)+r+a*Math.sin(c+2*Math.PI+.5*o)]),h.push([lt(s,n)+t+.98*i*Math.cos(c+o),lt(s,n)+r+.98*a*Math.sin(c+o)]),h.push([lt(s,n)+t+.9*i*Math.cos(c+.5*o),lt(s,n)+r+.9*a*Math.sin(c+.5*o)])}return[h,l]}function gd(e,t,r,i,a,s,o,n,l){const h=s+lt(.1,l),c=[];c.push([lt(n,l)+t+.9*i*Math.cos(h-e),lt(n,l)+r+.9*a*Math.sin(h-e)]);for(let u=h;u<=o;u+=e)c.push([lt(n,l)+t+i*Math.cos(u),lt(n,l)+r+a*Math.sin(u)]);return c.push([t+i*Math.cos(o),r+a*Math.sin(o)]),c.push([t+i*Math.cos(o),r+a*Math.sin(o)]),Ao(c,null,l)}function DM(e,t,r,i,a,s,o,n){const l=[],h=[n.maxRandomnessOffset||1,(n.maxRandomnessOffset||1)+.3];let c=[0,0];const u=n.disableMultiStroke?1:2,f=n.preserveVertices;for(let d=0;d<u;d++)d===0?l.push({op:"move",data:[o[0],o[1]]}):l.push({op:"move",data:[o[0]+(f?0:lt(h[0],n)),o[1]+(f?0:lt(h[0],n))]}),c=f?[a,s]:[a+lt(h[d],n),s+lt(h[d],n)],l.push({op:"bcurveTo",data:[e+lt(h[d],n),t+lt(h[d],n),r+lt(h[d],n),i+lt(h[d],n),c[0],c[1]]});return l}function fa(e){return[...e]}function md(e,t=0){const r=e.length;if(r<3)throw new Error("A curve must have at least three points.");const i=[];if(r===3)i.push(fa(e[0]),fa(e[1]),fa(e[2]),fa(e[2]));else{const a=[];a.push(e[0],e[0]);for(let n=1;n<e.length;n++)a.push(e[n]),n===e.length-1&&a.push(e[n]);const s=[],o=1-t;i.push(fa(a[0]));for(let n=1;n+2<a.length;n++){const l=a[n];s[0]=[l[0],l[1]],s[1]=[l[0]+(o*a[n+1][0]-o*a[n-1][0])/6,l[1]+(o*a[n+1][1]-o*a[n-1][1])/6],s[2]=[a[n+1][0]+(o*a[n][0]-o*a[n+2][0])/6,a[n+1][1]+(o*a[n][1]-o*a[n+2][1])/6],s[3]=[a[n+1][0],a[n+1][1]],i.push(s[1],s[2],s[3])}}return i}function Ns(e,t){return Math.pow(e[0]-t[0],2)+Math.pow(e[1]-t[1],2)}function OM(e,t,r){const i=Ns(t,r);if(i===0)return Ns(e,t);let a=((e[0]-t[0])*(r[0]-t[0])+(e[1]-t[1])*(r[1]-t[1]))/i;return a=Math.max(0,Math.min(1,a)),Ns(e,Mr(t,r,a))}function Mr(e,t,r){return[e[0]+(t[0]-e[0])*r,e[1]+(t[1]-e[1])*r]}function Yl(e,t,r,i){const a=i||[];if((function(n,l){const h=n[l+0],c=n[l+1],u=n[l+2],f=n[l+3];let d=3*c[0]-2*h[0]-f[0];d*=d;let p=3*c[1]-2*h[1]-f[1];p*=p;let g=3*u[0]-2*f[0]-h[0];g*=g;let m=3*u[1]-2*f[1]-h[1];return m*=m,d<g&&(d=g),p<m&&(p=m),d+p})(e,t)<r){const n=e[t+0];a.length?(s=a[a.length-1],o=n,Math.sqrt(Ns(s,o))>1&&a.push(n)):a.push(n),a.push(e[t+3])}else{const l=e[t+0],h=e[t+1],c=e[t+2],u=e[t+3],f=Mr(l,h,.5),d=Mr(h,c,.5),p=Mr(c,u,.5),g=Mr(f,d,.5),m=Mr(d,p,.5),C=Mr(g,m,.5);Yl([l,f,g,C],0,r,a),Yl([C,m,p,u],0,r,a)}var s,o;return a}function IM(e,t){return Eo(e,0,e.length,t)}function Eo(e,t,r,i,a){const s=a||[],o=e[t],n=e[r-1];let l=0,h=1;for(let c=t+1;c<r-1;++c){const u=OM(e[c],o,n);u>l&&(l=u,h=c)}return Math.sqrt(l)>i?(Eo(e,t,h+1,i,s),Eo(e,h,r,i,s)):(s.length||s.push(o),s.push(n)),s}function Gn(e,t=.15,r){const i=[],a=(e.length-1)/3;for(let s=0;s<a;s++)Yl(e,3*s,t,i);return r&&r>0?Eo(i,0,i.length,r):i}const pe="none";class $o{constructor(t){this.defaultOptions={maxRandomnessOffset:2,roughness:1,bowing:1,stroke:"#000",strokeWidth:1,curveTightness:0,curveFitting:.95,curveStepCount:9,fillStyle:"hachure",fillWeight:-1,hachureAngle:-41,hachureGap:-1,dashOffset:-1,dashGap:-1,zigzagOffset:-1,seed:0,disableMultiStroke:!1,disableMultiStrokeFill:!1,preserveVertices:!1,fillShapeRoughnessGain:.8},this.config=t||{},this.config.options&&(this.defaultOptions=this._o(this.config.options))}static newSeed(){return Math.floor(Math.random()*2**31)}_o(t){return t?Object.assign({},this.defaultOptions,t):this.defaultOptions}_d(t,r,i){return{shape:t,sets:r||[],options:i||this.defaultOptions}}line(t,r,i,a,s){const o=this._o(s);return this._d("line",[f0(t,r,i,a,o)],o)}rectangle(t,r,i,a,s){const o=this._o(s),n=[],l=$M(t,r,i,a,o);if(o.fill){const h=[[t,r],[t+i,r],[t+i,r+a],[t,r+a]];o.fillStyle==="solid"?n.push(jn([h],o)):n.push(oi([h],o))}return o.stroke!==pe&&n.push(l),this._d("rectangle",n,o)}ellipse(t,r,i,a,s){const o=this._o(s),n=[],l=p0(i,a,o),h=Hl(t,r,o,l);if(o.fill)if(o.fillStyle==="solid"){const c=Hl(t,r,o,l).opset;c.type="fillPath",n.push(c)}else n.push(oi([h.estimatedPoints],o));return o.stroke!==pe&&n.push(h.opset),this._d("ellipse",n,o)}circle(t,r,i,a){const s=this.ellipse(t,r,i,i,a);return s.shape="circle",s}linearPath(t,r){const i=this._o(r);return this._d("linearPath",[Rs(t,!1,i)],i)}arc(t,r,i,a,s,o,n=!1,l){const h=this._o(l),c=[],u=ud(t,r,i,a,s,o,n,!0,h);if(n&&h.fill)if(h.fillStyle==="solid"){const f=Object.assign({},h);f.disableMultiStroke=!0;const d=ud(t,r,i,a,s,o,!0,!1,f);d.type="fillPath",c.push(d)}else c.push((function(f,d,p,g,m,C,x){const k=f,w=d;let S=Math.abs(p/2),_=Math.abs(g/2);S+=lt(.01*S,x),_+=lt(.01*_,x);let T=m,B=C;for(;T<0;)T+=2*Math.PI,B+=2*Math.PI;B-T>2*Math.PI&&(T=0,B=2*Math.PI);const z=(B-T)/x.curveStepCount,I=[];for(let E=T;E<=B;E+=z)I.push([k+S*Math.cos(E),w+_*Math.sin(E)]);return I.push([k+S*Math.cos(B),w+_*Math.sin(B)]),I.push([k,w]),oi([I],x)})(t,r,i,a,s,o,h));return h.stroke!==pe&&c.push(u),this._d("arc",c,h)}curve(t,r){const i=this._o(r),a=[],s=cd(t,i);if(i.fill&&i.fill!==pe)if(i.fillStyle==="solid"){const o=cd(t,Object.assign(Object.assign({},i),{disableMultiStroke:!0,roughness:i.roughness?i.roughness+i.fillShapeRoughnessGain:0}));a.push({type:"fillPath",ops:this._mergedShape(o.ops)})}else{const o=[],n=t;if(n.length){const l=typeof n[0][0]=="number"?[n]:n;for(const h of l)h.length<3?o.push(...h):h.length===3?o.push(...Gn(md([h[0],h[0],h[1],h[2]]),10,(1+i.roughness)/2)):o.push(...Gn(md(h),10,(1+i.roughness)/2))}o.length&&a.push(oi([o],i))}return i.stroke!==pe&&a.push(s),this._d("curve",a,i)}polygon(t,r){const i=this._o(r),a=[],s=Rs(t,!0,i);return i.fill&&(i.fillStyle==="solid"?a.push(jn([t],i)):a.push(oi([t],i))),i.stroke!==pe&&a.push(s),this._d("polygon",a,i)}path(t,r){const i=this._o(r),a=[];if(!t)return this._d("path",a,i);t=(t||"").replace(/\n/g," ").replace(/(-\s)/g,"-").replace("/(ss)/g"," ");const s=i.fill&&i.fill!=="transparent"&&i.fill!==pe,o=i.stroke!==pe,n=!!(i.simplification&&i.simplification<1),l=(function(c,u,f){const d=u0(c0(sc(c))),p=[];let g=[],m=[0,0],C=[];const x=()=>{C.length>=4&&g.push(...Gn(C,u)),C=[]},k=()=>{x(),g.length&&(p.push(g),g=[])};for(const{key:S,data:_}of d)switch(S){case"M":k(),m=[_[0],_[1]],g.push(m);break;case"L":x(),g.push([_[0],_[1]]);break;case"C":if(!C.length){const T=g.length?g[g.length-1]:m;C.push([T[0],T[1]])}C.push([_[0],_[1]]),C.push([_[2],_[3]]),C.push([_[4],_[5]]);break;case"Z":x(),g.push([m[0],m[1]])}if(k(),!f)return p;const w=[];for(const S of p){const _=IM(S,f);_.length&&w.push(_)}return w})(t,1,n?4-4*(i.simplification||1):(1+i.roughness)/2),h=dd(t,i);if(s)if(i.fillStyle==="solid")if(l.length===1){const c=dd(t,Object.assign(Object.assign({},i),{disableMultiStroke:!0,roughness:i.roughness?i.roughness+i.fillShapeRoughnessGain:0}));a.push({type:"fillPath",ops:this._mergedShape(c.ops)})}else a.push(jn(l,i));else a.push(oi(l,i));return o&&(n?l.forEach((c=>{a.push(Rs(c,!1,i))})):a.push(h)),this._d("path",a,i)}opsToPath(t,r){let i="";for(const a of t.ops){const s=typeof r=="number"&&r>=0?a.data.map((o=>+o.toFixed(r))):a.data;switch(a.op){case"move":i+=`M${s[0]} ${s[1]} `;break;case"bcurveTo":i+=`C${s[0]} ${s[1]}, ${s[2]} ${s[3]}, ${s[4]} ${s[5]} `;break;case"lineTo":i+=`L${s[0]} ${s[1]} `}}return i.trim()}toPaths(t){const r=t.sets||[],i=t.options||this.defaultOptions,a=[];for(const s of r){let o=null;switch(s.type){case"path":o={d:this.opsToPath(s),stroke:i.stroke,strokeWidth:i.strokeWidth,fill:pe};break;case"fillPath":o={d:this.opsToPath(s),stroke:pe,strokeWidth:0,fill:i.fill||pe};break;case"fillSketch":o=this.fillSketch(s,i)}o&&a.push(o)}return a}fillSketch(t,r){let i=r.fillWeight;return i<0&&(i=r.strokeWidth/2),{d:this.opsToPath(t),stroke:r.fill||pe,strokeWidth:i,fill:pe}}_mergedShape(t){return t.filter(((r,i)=>i===0||r.op!=="move"))}}class PM{constructor(t,r){this.canvas=t,this.ctx=this.canvas.getContext("2d"),this.gen=new $o(r)}draw(t){const r=t.sets||[],i=t.options||this.getDefaultOptions(),a=this.ctx,s=t.options.fixedDecimalPlaceDigits;for(const o of r)switch(o.type){case"path":a.save(),a.strokeStyle=i.stroke==="none"?"transparent":i.stroke,a.lineWidth=i.strokeWidth,i.strokeLineDash&&a.setLineDash(i.strokeLineDash),i.strokeLineDashOffset&&(a.lineDashOffset=i.strokeLineDashOffset),this._drawToContext(a,o,s),a.restore();break;case"fillPath":{a.save(),a.fillStyle=i.fill||"";const n=t.shape==="curve"||t.shape==="polygon"||t.shape==="path"?"evenodd":"nonzero";this._drawToContext(a,o,s,n),a.restore();break}case"fillSketch":this.fillSketch(a,o,i)}}fillSketch(t,r,i){let a=i.fillWeight;a<0&&(a=i.strokeWidth/2),t.save(),i.fillLineDash&&t.setLineDash(i.fillLineDash),i.fillLineDashOffset&&(t.lineDashOffset=i.fillLineDashOffset),t.strokeStyle=i.fill||"",t.lineWidth=a,this._drawToContext(t,r,i.fixedDecimalPlaceDigits),t.restore()}_drawToContext(t,r,i,a="nonzero"){t.beginPath();for(const s of r.ops){const o=typeof i=="number"&&i>=0?s.data.map((n=>+n.toFixed(i))):s.data;switch(s.op){case"move":t.moveTo(o[0],o[1]);break;case"bcurveTo":t.bezierCurveTo(o[0],o[1],o[2],o[3],o[4],o[5]);break;case"lineTo":t.lineTo(o[0],o[1])}}r.type==="fillPath"?t.fill(a):t.stroke()}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}line(t,r,i,a,s){const o=this.gen.line(t,r,i,a,s);return this.draw(o),o}rectangle(t,r,i,a,s){const o=this.gen.rectangle(t,r,i,a,s);return this.draw(o),o}ellipse(t,r,i,a,s){const o=this.gen.ellipse(t,r,i,a,s);return this.draw(o),o}circle(t,r,i,a){const s=this.gen.circle(t,r,i,a);return this.draw(s),s}linearPath(t,r){const i=this.gen.linearPath(t,r);return this.draw(i),i}polygon(t,r){const i=this.gen.polygon(t,r);return this.draw(i),i}arc(t,r,i,a,s,o,n=!1,l){const h=this.gen.arc(t,r,i,a,s,o,n,l);return this.draw(h),h}curve(t,r){const i=this.gen.curve(t,r);return this.draw(i),i}path(t,r){const i=this.gen.path(t,r);return this.draw(i),i}}const ks="http://www.w3.org/2000/svg";class RM{constructor(t,r){this.svg=t,this.gen=new $o(r)}draw(t){const r=t.sets||[],i=t.options||this.getDefaultOptions(),a=this.svg.ownerDocument||window.document,s=a.createElementNS(ks,"g"),o=t.options.fixedDecimalPlaceDigits;for(const n of r){let l=null;switch(n.type){case"path":l=a.createElementNS(ks,"path"),l.setAttribute("d",this.opsToPath(n,o)),l.setAttribute("stroke",i.stroke),l.setAttribute("stroke-width",i.strokeWidth+""),l.setAttribute("fill","none"),i.strokeLineDash&&l.setAttribute("stroke-dasharray",i.strokeLineDash.join(" ").trim()),i.strokeLineDashOffset&&l.setAttribute("stroke-dashoffset",`${i.strokeLineDashOffset}`);break;case"fillPath":l=a.createElementNS(ks,"path"),l.setAttribute("d",this.opsToPath(n,o)),l.setAttribute("stroke","none"),l.setAttribute("stroke-width","0"),l.setAttribute("fill",i.fill||""),t.shape!=="curve"&&t.shape!=="polygon"||l.setAttribute("fill-rule","evenodd");break;case"fillSketch":l=this.fillSketch(a,n,i)}l&&s.appendChild(l)}return s}fillSketch(t,r,i){let a=i.fillWeight;a<0&&(a=i.strokeWidth/2);const s=t.createElementNS(ks,"path");return s.setAttribute("d",this.opsToPath(r,i.fixedDecimalPlaceDigits)),s.setAttribute("stroke",i.fill||""),s.setAttribute("stroke-width",a+""),s.setAttribute("fill","none"),i.fillLineDash&&s.setAttribute("stroke-dasharray",i.fillLineDash.join(" ").trim()),i.fillLineDashOffset&&s.setAttribute("stroke-dashoffset",`${i.fillLineDashOffset}`),s}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}opsToPath(t,r){return this.gen.opsToPath(t,r)}line(t,r,i,a,s){const o=this.gen.line(t,r,i,a,s);return this.draw(o)}rectangle(t,r,i,a,s){const o=this.gen.rectangle(t,r,i,a,s);return this.draw(o)}ellipse(t,r,i,a,s){const o=this.gen.ellipse(t,r,i,a,s);return this.draw(o)}circle(t,r,i,a){const s=this.gen.circle(t,r,i,a);return this.draw(s)}linearPath(t,r){const i=this.gen.linearPath(t,r);return this.draw(i)}polygon(t,r){const i=this.gen.polygon(t,r);return this.draw(i)}arc(t,r,i,a,s,o,n=!1,l){const h=this.gen.arc(t,r,i,a,s,o,n,l);return this.draw(h)}curve(t,r){const i=this.gen.curve(t,r);return this.draw(i)}path(t,r){const i=this.gen.path(t,r);return this.draw(i)}}var K={canvas:(e,t)=>new PM(e,t),svg:(e,t)=>new RM(e,t),generator:e=>new $o(e),newSeed:()=>$o.newSeed()},nt=y(async(e,t,r)=>{var d,p;let i;const a=t.useHtmlLabels||cr((d=bt())==null?void 0:d.htmlLabels);r?i=r:i="node default";const s=e.insert("g").attr("class",i).attr("id",t.domId||t.id),o=s.insert("g").attr("class","label").attr("style",Ht(t.labelStyle));let n;t.label===void 0?n="":n=typeof t.label=="string"?t.label:t.label[0];const l=!!t.icon||!!t.img,h=t.labelType==="markdown",c=await dr(o,Ae(Yr(n),bt()),{useHtmlLabels:a,width:t.width||((p=bt().flowchart)==null?void 0:p.wrappingWidth),classes:h?"markdown-node-label":"",style:t.labelStyle,addSvgBackground:l,markdown:h},bt());let u=c.getBBox();const f=((t==null?void 0:t.padding)??0)/2;if(a){const g=c.children[0],m=pt(c);await Om(g,n),u=g.getBoundingClientRect(),m.attr("width",u.width),m.attr("height",u.height)}return a?o.attr("transform","translate("+-u.width/2+", "+-u.height/2+")"):o.attr("transform","translate(0, "+-u.height/2+")"),t.centerLabel&&o.attr("transform","translate("+-u.width/2+", "+-u.height/2+")"),o.insert("rect",":first-child"),{shapeSvg:s,bbox:u,halfPadding:f,label:o}},"labelHelper"),Xn=y(async(e,t,r)=>{var l,h;const i=r.useHtmlLabels??ne(bt()),a=e.insert("g").attr("class","label").attr("style",r.labelStyle||""),s=await dr(a,Ae(Yr(t),bt()),{useHtmlLabels:i,width:r.width||((h=(l=bt())==null?void 0:l.flowchart)==null?void 0:h.wrappingWidth),style:r.labelStyle,addSvgBackground:!!r.icon||!!r.img});let o=s.getBBox();const n=r.padding/2;if(ne(bt())){const c=s.children[0],u=pt(s);o=c.getBoundingClientRect(),u.attr("width",o.width),u.attr("height",o.height)}return i?a.attr("transform","translate("+-o.width/2+", "+-o.height/2+")"):a.attr("transform","translate(0, "+-o.height/2+")"),r.centerLabel&&a.attr("transform","translate("+-o.width/2+", "+-o.height/2+")"),a.insert("rect",":first-child"),{shapeSvg:e,bbox:o,halfPadding:n,label:a}},"insertLabel"),rt=y((e,t)=>{const r=t.node().getBBox();e.width=r.width,e.height=r.height},"updateNodeBounds"),ot=y((e,t)=>(e.look==="handDrawn"?"rough-node":"node")+" "+e.cssClasses+" "+(t||""),"getNodeClasses");function yt(e){const t=e.map((r,i)=>`${i===0?"M":"L"}${r.x},${r.y}`);return t.push("Z"),t.join(" ")}y(yt,"createPathFromPoints");function Tr(e,t,r,i,a,s){const o=[],l=r-e,h=i-t,c=l/s,u=2*Math.PI/c,f=t+h/2;for(let d=0;d<=50;d++){const p=d/50,g=e+p*l,m=f+a*Math.sin(u*(g-e));o.push({x:g,y:m})}return o}y(Tr,"generateFullSineWavePoints");function za(e,t,r,i,a,s){const o=[],n=a*Math.PI/180,c=(s*Math.PI/180-n)/(i-1);for(let u=0;u<i;u++){const f=n+u*c,d=e+r*Math.cos(f),p=t+r*Math.sin(f);o.push({x:-d,y:-p})}return o}y(za,"generateCirclePoints");function jl(e){const t=Array.from(e.childNodes).filter(l=>l.tagName==="path"),r=document.createElementNS("http://www.w3.org/2000/svg","path"),i=t.map(l=>l.getAttribute("d")).filter(l=>l!==null).join(" ");r.setAttribute("d",i);const a=t.find(l=>l.getAttribute("fill")!=="none"),s=t.find(l=>l.getAttribute("stroke")!=="none"),o=y((l,h)=>(l==null?void 0:l.getAttribute(h))??void 0,"getAttr");if(a){const l={fill:o(a,"fill"),"fill-opacity":o(a,"fill-opacity")??"1"};Object.entries(l).forEach(([h,c])=>{c&&r.setAttribute(h,c)})}if(s){const l={stroke:o(s,"stroke"),"stroke-width":o(s,"stroke-width")??"1","stroke-opacity":o(s,"stroke-opacity")??"1"};Object.entries(l).forEach(([h,c])=>{c&&r.setAttribute(h,c)})}const n=document.createElementNS("http://www.w3.org/2000/svg","g");return n.appendChild(r),n}y(jl,"mergePaths");var NM=y((e,t)=>{var r=e.x,i=e.y,a=t.x-r,s=t.y-i,o=e.width/2,n=e.height/2,l,h;return Math.abs(s)*o>Math.abs(a)*n?(s<0&&(n=-n),l=s===0?0:n*a/s,h=n):(a<0&&(o=-o),l=o,h=a===0?0:o*s/a),{x:r+l,y:i+h}},"intersectRect"),Gi=NM,qM=y(async(e,t,r,i=!1,a=!1)=>{let s=t||"";typeof s=="object"&&(s=s[0]);const o=bt(),n=ne(o);return await dr(e,s,{style:r,isTitle:i,useHtmlLabels:n,markdown:!1,isNode:a,width:Number.POSITIVE_INFINITY},o)},"createLabel"),gr=qM,_r=y((e,t,r,i,a)=>["M",e+a,t,"H",e+r-a,"A",a,a,0,0,1,e+r,t+a,"V",t+i-a,"A",a,a,0,0,1,e+r-a,t+i,"H",e+a,"A",a,a,0,0,1,e,t+i-a,"V",t+a,"A",a,a,0,0,1,e+a,t,"Z"].join(" "),"createRoundedRectPathD"),m0=y(async(e,t)=>{W.info("Creating subgraph rect for ",t.id,t);const r=bt(),{themeVariables:i,handDrawnSeed:a}=r,{clusterBkg:s,clusterBorder:o}=i,{labelStyles:n,nodeStyles:l,borderStyles:h,backgroundStyles:c}=tt(t),u=e.insert("g").attr("class","cluster "+t.cssClasses).attr("id",t.domId).attr("data-look",t.look),f=ne(r),d=u.insert("g").attr("class","cluster-label ");let p;t.labelType==="markdown"?p=await dr(d,t.label,{style:t.labelStyle,useHtmlLabels:f,isNode:!0,width:t.width}):p=await gr(d,t.label,t.labelStyle||"",!1,!0);let g=p.getBBox();if(ne(r)){const T=p.children[0],B=pt(p);g=T.getBoundingClientRect(),B.attr("width",g.width),B.attr("height",g.height)}const m=t.width<=g.width+t.padding?g.width+t.padding:t.width;t.width<=g.width+t.padding?t.diff=(m-t.width)/2-t.padding:t.diff=-t.padding;const C=t.height,x=t.x-m/2,k=t.y-C/2;W.trace("Data ",t,JSON.stringify(t));let w;if(t.look==="handDrawn"){const T=K.svg(u),B=J(t,{roughness:.7,fill:s,stroke:o,fillWeight:3,seed:a}),z=T.path(_r(x,k,m,C,0),B);w=u.insert(()=>(W.debug("Rough node insert CXC",z),z),":first-child"),w.select("path:nth-child(2)").attr("style",h.join(";")),w.select("path").attr("style",c.join(";").replace("fill","stroke"))}else w=u.insert("rect",":first-child"),w.attr("style",l).attr("rx",t.rx).attr("ry",t.ry).attr("x",x).attr("y",k).attr("width",m).attr("height",C);const{subGraphTitleTopMargin:S}=Gh(r);if(d.attr("transform",`translate(${t.x-g.width/2}, ${t.y-t.height/2+S})`),n){const T=d.select("span");T&&T.attr("style",n)}const _=w.node().getBBox();return t.offsetX=0,t.width=_.width,t.height=_.height,t.offsetY=g.height-t.padding/2,t.intersect=function(T){return Gi(t,T)},{cluster:u,labelBBox:g}},"rect"),zM=y((e,t)=>{const r=e.insert("g").attr("class","note-cluster").attr("id",t.domId),i=r.insert("rect",":first-child"),a=0*t.padding,s=a/2;i.attr("rx",t.rx).attr("ry",t.ry).attr("x",t.x-t.width/2-s).attr("y",t.y-t.height/2-s).attr("width",t.width+a).attr("height",t.height+a).attr("fill","none");const o=i.node().getBBox();return t.width=o.width,t.height=o.height,t.intersect=function(n){return Gi(t,n)},{cluster:r,labelBBox:{width:0,height:0}}},"noteGroup"),WM=y(async(e,t)=>{const r=bt(),{themeVariables:i,handDrawnSeed:a}=r,{altBackground:s,compositeBackground:o,compositeTitleBackground:n,nodeBorder:l}=i,h=e.insert("g").attr("class",t.cssClasses).attr("id",t.domId).attr("data-id",t.id).attr("data-look",t.look),c=h.insert("g",":first-child"),u=h.insert("g").attr("class","cluster-label");let f=h.append("rect");const d=await gr(u,t.label,t.labelStyle,void 0,!0);let p=d.getBBox();if(ne(r)){const z=d.children[0],I=pt(d);p=z.getBoundingClientRect(),I.attr("width",p.width),I.attr("height",p.height)}const g=0*t.padding,m=g/2,C=(t.width<=p.width+t.padding?p.width+t.padding:t.width)+g;t.width<=p.width+t.padding?t.diff=(C-t.width)/2-t.padding:t.diff=-t.padding;const x=t.height+g,k=t.height+g-p.height-6,w=t.x-C/2,S=t.y-x/2;t.width=C;const _=t.y-t.height/2-m+p.height+2;let T;if(t.look==="handDrawn"){const z=t.cssClasses.includes("statediagram-cluster-alt"),I=K.svg(h),E=t.rx||t.ry?I.path(_r(w,S,C,x,10),{roughness:.7,fill:n,fillStyle:"solid",stroke:l,seed:a}):I.rectangle(w,S,C,x,{seed:a});T=h.insert(()=>E,":first-child");const N=I.rectangle(w,_,C,k,{fill:z?s:o,fillStyle:z?"hachure":"solid",stroke:l,seed:a});T=h.insert(()=>E,":first-child"),f=h.insert(()=>N)}else T=c.insert("rect",":first-child"),T.attr("class","outer").attr("x",w).attr("y",S).attr("width",C).attr("height",x).attr("data-look",t.look),f.attr("class","inner").attr("x",w).attr("y",_).attr("width",C).attr("height",k);u.attr("transform",`translate(${t.x-p.width/2}, ${S+1-(ne(r)?0:3)})`);const B=T.node().getBBox();return t.height=B.height,t.offsetX=0,t.offsetY=p.height-t.padding/2,t.labelBBox=p,t.intersect=function(z){return Gi(t,z)},{cluster:h,labelBBox:p}},"roundedWithTitle"),HM=y(async(e,t)=>{W.info("Creating subgraph rect for ",t.id,t);const r=bt(),{themeVariables:i,handDrawnSeed:a}=r,{clusterBkg:s,clusterBorder:o}=i,{labelStyles:n,nodeStyles:l,borderStyles:h,backgroundStyles:c}=tt(t),u=e.insert("g").attr("class","cluster "+t.cssClasses).attr("id",t.domId).attr("data-look",t.look),f=ne(r),d=u.insert("g").attr("class","cluster-label "),p=await dr(d,t.label,{style:t.labelStyle,useHtmlLabels:f,isNode:!0,width:t.width});let g=p.getBBox();if(ne(r)){const T=p.children[0],B=pt(p);g=T.getBoundingClientRect(),B.attr("width",g.width),B.attr("height",g.height)}const m=t.width<=g.width+t.padding?g.width+t.padding:t.width;t.width<=g.width+t.padding?t.diff=(m-t.width)/2-t.padding:t.diff=-t.padding;const C=t.height,x=t.x-m/2,k=t.y-C/2;W.trace("Data ",t,JSON.stringify(t));let w;if(t.look==="handDrawn"){const T=K.svg(u),B=J(t,{roughness:.7,fill:s,stroke:o,fillWeight:4,seed:a}),z=T.path(_r(x,k,m,C,t.rx),B);w=u.insert(()=>(W.debug("Rough node insert CXC",z),z),":first-child"),w.select("path:nth-child(2)").attr("style",h.join(";")),w.select("path").attr("style",c.join(";").replace("fill","stroke"))}else w=u.insert("rect",":first-child"),w.attr("style",l).attr("rx",t.rx).attr("ry",t.ry).attr("x",x).attr("y",k).attr("width",m).attr("height",C);const{subGraphTitleTopMargin:S}=Gh(r);if(d.attr("transform",`translate(${t.x-g.width/2}, ${t.y-t.height/2+S})`),n){const T=d.select("span");T&&T.attr("style",n)}const _=w.node().getBBox();return t.offsetX=0,t.width=_.width,t.height=_.height,t.offsetY=g.height-t.padding/2,t.intersect=function(T){return Gi(t,T)},{cluster:u,labelBBox:g}},"kanbanSection"),UM=y((e,t)=>{const r=bt(),{themeVariables:i,handDrawnSeed:a}=r,{nodeBorder:s}=i,o=e.insert("g").attr("class",t.cssClasses).attr("id",t.domId).attr("data-look",t.look),n=o.insert("g",":first-child"),l=0*t.padding,h=t.width+l;t.diff=-t.padding;const c=t.height+l,u=t.x-h/2,f=t.y-c/2;t.width=h;let d;if(t.look==="handDrawn"){const m=K.svg(o).rectangle(u,f,h,c,{fill:"lightgrey",roughness:.5,strokeLineDash:[5],stroke:s,seed:a});d=o.insert(()=>m,":first-child")}else{d=n.insert("rect",":first-child");let g="outer";t.look,g="divider",d.attr("class",g).attr("x",u).attr("y",f).attr("width",h).attr("height",c).attr("data-look",t.look)}const p=d.node().getBBox();return t.height=p.height,t.offsetX=0,t.offsetY=0,t.intersect=function(g){return Gi(t,g)},{cluster:o,labelBBox:{}}},"divider"),YM=m0,jM={rect:m0,squareRect:YM,roundedWithTitle:WM,noteGroup:zM,divider:UM,kanbanSection:HM},y0=new Map,GM=y(async(e,t)=>{const r=t.shape||"rect",i=await jM[r](e,t);return y0.set(t.id,i),i},"insertCluster"),X$=y(()=>{y0=new Map},"clear");function C0(e,t){return e.intersect(t)}y(C0,"intersectNode");var XM=C0;function x0(e,t,r,i){var a=e.x,s=e.y,o=a-i.x,n=s-i.y,l=Math.sqrt(t*t*n*n+r*r*o*o),h=Math.abs(t*r*o/l);i.x<a&&(h=-h);var c=Math.abs(t*r*n/l);return i.y<s&&(c=-c),{x:a+h,y:s+c}}y(x0,"intersectEllipse");var b0=x0;function k0(e,t,r){return b0(e,t,t,r)}y(k0,"intersectCircle");var VM=k0;function T0(e,t,r,i){{const a=t.y-e.y,s=e.x-t.x,o=t.x*e.y-e.x*t.y,n=a*r.x+s*r.y+o,l=a*i.x+s*i.y+o,h=1e-6;if(n!==0&&l!==0&&Gl(n,l))return;const c=i.y-r.y,u=r.x-i.x,f=i.x*r.y-r.x*i.y,d=c*e.x+u*e.y+f,p=c*t.x+u*t.y+f;if(Math.abs(d)<h&&Math.abs(p)<h&&Gl(d,p))return;const g=a*u-c*s;if(g===0)return;const m=Math.abs(g/2);let C=s*f-u*o;const x=C<0?(C-m)/g:(C+m)/g;C=c*o-a*f;const k=C<0?(C-m)/g:(C+m)/g;return{x,y:k}}}y(T0,"intersectLine");function Gl(e,t){return e*t>0}y(Gl,"sameSign");var ZM=T0;function w0(e,t,r){let i=e.x,a=e.y,s=[],o=Number.POSITIVE_INFINITY,n=Number.POSITIVE_INFINITY;typeof t.forEach=="function"?t.forEach(function(c){o=Math.min(o,c.x),n=Math.min(n,c.y)}):(o=Math.min(o,t.x),n=Math.min(n,t.y));let l=i-e.width/2-o,h=a-e.height/2-n;for(let c=0;c<t.length;c++){let u=t[c],f=t[c<t.length-1?c+1:0],d=ZM(e,r,{x:l+u.x,y:h+u.y},{x:l+f.x,y:h+f.y});d&&s.push(d)}return s.length?(s.length>1&&s.sort(function(c,u){let f=c.x-r.x,d=c.y-r.y,p=Math.sqrt(f*f+d*d),g=u.x-r.x,m=u.y-r.y,C=Math.sqrt(g*g+m*m);return p<C?-1:p===C?0:1}),s[0]):e}y(w0,"intersectPolygon");var QM=w0,V={node:XM,circle:VM,ellipse:b0,polygon:QM,rect:Gi};function _0(e,t){const{labelStyles:r}=tt(t);t.labelStyle=r;const i=ot(t);let a=i;i||(a="anchor");const s=e.insert("g").attr("class",a).attr("id",t.domId||t.id),o=1,{cssStyles:n}=t,l=K.svg(s),h=J(t,{fill:"black",stroke:"none",fillStyle:"solid"});t.look!=="handDrawn"&&(h.roughness=0);const c=l.circle(0,0,o*2,h),u=s.insert(()=>c,":first-child");return u.attr("class","anchor").attr("style",Ht(n)),rt(t,u),t.intersect=function(f){return W.info("Circle intersect",t,o,f),V.circle(t,o,f)},s}y(_0,"anchor");function Xl(e,t,r,i,a,s,o){const l=(e+r)/2,h=(t+i)/2,c=Math.atan2(i-t,r-e),u=(r-e)/2,f=(i-t)/2,d=u/a,p=f/s,g=Math.sqrt(d**2+p**2);if(g>1)throw new Error("The given radii are too small to create an arc between the points.");const m=Math.sqrt(1-g**2),C=l+m*s*Math.sin(c)*(o?-1:1),x=h-m*a*Math.cos(c)*(o?-1:1),k=Math.atan2((t-x)/s,(e-C)/a);let S=Math.atan2((i-x)/s,(r-C)/a)-k;o&&S<0&&(S+=2*Math.PI),!o&&S>0&&(S-=2*Math.PI);const _=[];for(let T=0;T<20;T++){const B=T/19,z=k+B*S,I=C+a*Math.cos(z),E=x+s*Math.sin(z);_.push({x:I,y:E})}return _}y(Xl,"generateArcPoints");function S0(e,t,r){const[i,a]=[t,r].sort((s,o)=>o-s);return a*(1-Math.sqrt(1-(e/i/2)**2))}y(S0,"calculateArcSagitta");async function v0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?16:a,o=t.look==="neo"?12:a,n=y(z=>z+o,"calcTotalHeight"),l=y(z=>{const I=z/2;return[I/(2.5+z/50),I]},"calcEllipseRadius"),{shapeSvg:h,bbox:c}=await nt(e,t,ot(t)),u=n(t!=null&&t.height?t==null?void 0:t.height:c.height),[f,d]=l(u),p=S0(u,f,d),m=(t!=null&&t.width?t==null?void 0:t.width:c.width)+s*2+p-p,C=u,{cssStyles:x}=t,k=[{x:m/2,y:-C/2},{x:-m/2,y:-C/2},...Xl(-m/2,-C/2,-m/2,C/2,f,d,!1),{x:m/2,y:C/2},...Xl(m/2,C/2,m/2,-C/2,f,d,!0)],w=K.svg(h),S=J(t,{});t.look!=="handDrawn"&&(S.roughness=0,S.fillStyle="solid");const _=yt(k),T=w.path(_,S),B=h.insert(()=>T,":first-child");return B.attr("class","basic label-container outer-path"),x&&t.look!=="handDrawn"&&B.selectAll("path").attr("style",x),i&&t.look!=="handDrawn"&&B.selectAll("path").attr("style",i),B.attr("transform",`translate(${f/2}, 0)`),rt(t,B),t.intersect=function(z){return V.polygon(t,k,z)},h}y(v0,"bowTieRect");function fr(e,t,r,i){return e.insert("polygon",":first-child").attr("points",i.map(function(a){return a.x+","+a.y}).join(" ")).attr("class","label-container").attr("transform","translate("+-t/2+","+r/2+")")}y(fr,"insertPolygonShape");var Ts=12;async function B0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?28:a,o=t.look==="neo"?24:a,{shapeSvg:n,bbox:l}=await nt(e,t,ot(t)),h=((t==null?void 0:t.width)??l.width)+(t.look==="neo"?s*2:s+Ts),c=((t==null?void 0:t.height)??l.height)+(t.look==="neo"?o*2:o),u=0,f=h,d=-c,p=0,g=[{x:u+Ts,y:d},{x:f,y:d},{x:f,y:p},{x:u,y:p},{x:u,y:d+Ts},{x:u+Ts,y:d}];let m;const{cssStyles:C}=t;if(t.look==="handDrawn"){const x=K.svg(n),k=J(t,{}),w=yt(g),S=x.path(w,k);m=n.insert(()=>S,":first-child").attr("transform",`translate(${-h/2}, ${c/2})`),C&&m.attr("style",C)}else m=fr(n,h,c,g);return i&&m.attr("style",i),rt(t,m),t.intersect=function(x){return V.polygon(t,g,x)},n}y(B0,"card");function L0(e,t){const{nodeStyles:r}=tt(t);t.label="";const i=e.insert("g").attr("class",ot(t)).attr("id",t.domId??t.id),{cssStyles:a}=t,s=Math.max(28,t.width??0),o=[{x:0,y:s/2},{x:s/2,y:0},{x:0,y:-s/2},{x:-s/2,y:0}],n=K.svg(i),l=J(t,{});t.look!=="handDrawn"&&(l.roughness=0,l.fillStyle="solid");const h=yt(o),c=n.path(h,l),u=i.insert(()=>c,":first-child");return a&&t.look!=="handDrawn"&&u.selectAll("path").attr("style",a),r&&t.look!=="handDrawn"&&u.selectAll("path").attr("style",r),t.width=28,t.height=28,t.intersect=function(f){return V.polygon(t,o,f)},i}y(L0,"choice");async function oc(e,t,r){const{labelStyles:i,nodeStyles:a}=tt(t);t.labelStyle=i;const{shapeSvg:s,bbox:o,halfPadding:n}=await nt(e,t,ot(t)),l=16,h=(r==null?void 0:r.padding)??n,c=t.look==="neo"?o.width/2+l*2:o.width/2+h;let u;const{cssStyles:f}=t;if(t.look==="handDrawn"){const d=K.svg(s),p=J(t,{}),g=d.circle(0,0,c*2,p);u=s.insert(()=>g,":first-child"),u.attr("class","basic label-container").attr("style",Ht(f))}else u=s.insert("circle",":first-child").attr("class","basic label-container").attr("style",a).attr("r",c).attr("cx",0).attr("cy",0);return rt(t,u),t.calcIntersect=function(d,p){const g=d.width/2;return V.circle(d,g,p)},t.intersect=function(d){return W.info("Circle intersect",t,c,d),V.circle(t,c,d)},s}y(oc,"circle");function F0(e){const t=Math.cos(Math.PI/4),r=Math.sin(Math.PI/4),i=e*2,a={x:i/2*t,y:i/2*r},s={x:-(i/2)*t,y:i/2*r},o={x:-(i/2)*t,y:-(i/2)*r},n={x:i/2*t,y:-(i/2)*r};return`M ${s.x},${s.y} L ${n.x},${n.y}
229
+ M ${a.x},${a.y} L ${o.x},${o.y}`}y(F0,"createLine");function M0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r,t.label="";const a=e.insert("g").attr("class",ot(t)).attr("id",t.domId??t.id),s=Math.max(30,(t==null?void 0:t.width)??0),{cssStyles:o}=t,n=K.svg(a),l=J(t,{});t.look!=="handDrawn"&&(l.roughness=0,l.fillStyle="solid");const h=n.circle(0,0,s*2,l),c=F0(s),u=n.path(c,l),f=a.insert(()=>h,":first-child");return f.insert(()=>u),f.attr("class","outer-path"),o&&t.look!=="handDrawn"&&f.selectAll("path").attr("style",o),i&&t.look!=="handDrawn"&&f.selectAll("path").attr("style",i),rt(t,f),t.intersect=function(d){return W.info("crossedCircle intersect",t,{radius:s,point:d}),V.circle(t,s,d)},a}y(M0,"crossedCircle");function Je(e,t,r,i=100,a=0,s=180){const o=[],n=a*Math.PI/180,c=(s*Math.PI/180-n)/(i-1);for(let u=0;u<i;u++){const f=n+u*c,d=e+r*Math.cos(f),p=t+r*Math.sin(f);o.push({x:-d,y:-p})}return o}y(Je,"generateCirclePoints");async function A0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const{shapeSvg:a,bbox:s,label:o}=await nt(e,t,ot(t)),n=t.look==="neo"?18:t.padding??0,l=t.look==="neo"?12:t.padding??0,h=s.width+n,c=s.height+l,u=Math.max(5,c*.1),{cssStyles:f}=t,d=[...Je(h/2,-c/2,u,30,-90,0),{x:-h/2-u,y:u},...Je(h/2+u*2,-u,u,20,-180,-270),...Je(h/2+u*2,u,u,20,-90,-180),{x:-h/2-u,y:-c/2},...Je(h/2,c/2,u,20,0,90)],p=[{x:h/2,y:-c/2-u},{x:-h/2,y:-c/2-u},...Je(h/2,-c/2,u,20,-90,0),{x:-h/2-u,y:-u},...Je(h/2+h*.1,-u,u,20,-180,-270),...Je(h/2+h*.1,u,u,20,-90,-180),{x:-h/2-u,y:c/2},...Je(h/2,c/2,u,20,0,90),{x:-h/2,y:c/2+u},{x:h/2,y:c/2+u}],g=K.svg(a),m=J(t,{fill:"none"});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const x=yt(d).replace("Z",""),k=g.path(x,m),w=yt(p),S=g.path(w,{...m}),_=a.insert("g",":first-child");return _.insert(()=>S,":first-child").attr("stroke-opacity",0),_.insert(()=>k,":first-child"),_.attr("class","text"),f&&t.look!=="handDrawn"&&_.selectAll("path").attr("style",f),i&&t.look!=="handDrawn"&&_.selectAll("path").attr("style",i),_.attr("transform",`translate(${u}, 0)`),o.attr("transform",`translate(${-h/2+u-(s.x-(s.left??0))},${-c/2+(t.padding??0)/2-(s.y-(s.top??0))})`),rt(t,_),t.intersect=function(T){return V.polygon(t,p,T)},a}y(A0,"curlyBraceLeft");function tr(e,t,r,i=100,a=0,s=180){const o=[],n=a*Math.PI/180,c=(s*Math.PI/180-n)/(i-1);for(let u=0;u<i;u++){const f=n+u*c,d=e+r*Math.cos(f),p=t+r*Math.sin(f);o.push({x:d,y:p})}return o}y(tr,"generateCirclePoints");async function E0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const{shapeSvg:a,bbox:s,label:o}=await nt(e,t,ot(t)),n=t.look==="neo"?18:t.padding??0,l=t.look==="neo"?12:t.padding??0,h=s.width+(t.look==="neo"?n*2:n),c=s.height+(t.look==="neo"?l*2:l),u=Math.max(5,c*.1),{cssStyles:f}=t,d=[...tr(h/2,-c/2,u,20,-90,0),{x:h/2+u,y:-u},...tr(h/2+u*2,-u,u,20,-180,-270),...tr(h/2+u*2,u,u,20,-90,-180),{x:h/2+u,y:c/2},...tr(h/2,c/2,u,20,0,90)],p=[{x:-h/2,y:-c/2-u},{x:h/2,y:-c/2-u},...tr(h/2,-c/2,u,20,-90,0),{x:h/2+u,y:-u},...tr(h/2+u*2,-u,u,20,-180,-270),...tr(h/2+u*2,u,u,20,-90,-180),{x:h/2+u,y:c/2},...tr(h/2,c/2,u,20,0,90),{x:h/2,y:c/2+u},{x:-h/2,y:c/2+u}],g=K.svg(a),m=J(t,{fill:"none"});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const x=yt(d).replace("Z",""),k=g.path(x,m),w=yt(p),S=g.path(w,{...m}),_=a.insert("g",":first-child");return _.insert(()=>S,":first-child").attr("stroke-opacity",0),_.insert(()=>k,":first-child"),_.attr("class","text"),f&&t.look!=="handDrawn"&&_.selectAll("path").attr("style",f),i&&t.look!=="handDrawn"&&_.selectAll("path").attr("style",i),_.attr("transform",`translate(${-u}, 0)`),o.attr("transform",`translate(${-h/2+(t.padding??0)/2-(s.x-(s.left??0))},${-c/2+(t.padding??0)/2-(s.y-(s.top??0))})`),rt(t,_),t.intersect=function(T){return V.polygon(t,p,T)},a}y(E0,"curlyBraceRight");function jt(e,t,r,i=100,a=0,s=180){const o=[],n=a*Math.PI/180,c=(s*Math.PI/180-n)/(i-1);for(let u=0;u<i;u++){const f=n+u*c,d=e+r*Math.cos(f),p=t+r*Math.sin(f);o.push({x:-d,y:-p})}return o}y(jt,"generateCirclePoints");async function $0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const{shapeSvg:a,bbox:s,label:o}=await nt(e,t,ot(t)),n=t.look==="neo"?18:t.padding??0,l=t.look==="neo"?12:t.padding??0,h=s.width+(t.look==="neo"?n*2:n),c=s.height+(t.look==="neo"?l*2:l),u=Math.max(5,c*.1),{cssStyles:f}=t,d=[...jt(h/2,-c/2,u,30,-90,0),{x:-h/2-u,y:u},...jt(h/2+u*2,-u,u,20,-180,-270),...jt(h/2+u*2,u,u,20,-90,-180),{x:-h/2-u,y:-c/2},...jt(h/2,c/2,u,20,0,90)],p=[...jt(-h/2+u+u/2,-c/2,u,20,-90,-180),{x:h/2-u/2,y:u},...jt(-h/2-u/2,-u,u,20,0,90),...jt(-h/2-u/2,u,u,20,-90,0),{x:h/2-u/2,y:-u},...jt(-h/2+u+u/2,c/2,u,30,-180,-270)],g=[{x:h/2,y:-c/2-u},{x:-h/2,y:-c/2-u},...jt(h/2,-c/2,u,20,-90,0),{x:-h/2-u,y:-u},...jt(h/2+u*2,-u,u,20,-180,-270),...jt(h/2+u*2,u,u,20,-90,-180),{x:-h/2-u,y:c/2},...jt(h/2,c/2,u,20,0,90),{x:-h/2,y:c/2+u},{x:h/2-u-u/2,y:c/2+u},...jt(-h/2+u+u/2,-c/2,u,20,-90,-180),{x:h/2-u/2,y:u},...jt(-h/2-u/2,-u,u,20,0,90),...jt(-h/2-u/2,u,u,20,-90,0),{x:h/2-u/2,y:-u},...jt(-h/2+u+u/2,c/2,u,30,-180,-270)],m=K.svg(a),C=J(t,{fill:"none"});t.look!=="handDrawn"&&(C.roughness=0,C.fillStyle="solid");const k=yt(d).replace("Z",""),w=m.path(k,C),_=yt(p).replace("Z",""),T=m.path(_,C),B=yt(g),z=m.path(B,{...C}),I=a.insert("g",":first-child");return I.insert(()=>z,":first-child").attr("stroke-opacity",0),I.insert(()=>w,":first-child"),I.insert(()=>T,":first-child"),I.attr("class","text"),f&&t.look!=="handDrawn"&&I.selectAll("path").attr("style",f),i&&t.look!=="handDrawn"&&I.selectAll("path").attr("style",i),I.attr("transform",`translate(${u-u/4}, 0)`),o.attr("transform",`translate(${-h/2+(t.padding??0)/2-(s.x-(s.left??0))},${-c/2+(t.padding??0)/2-(s.y-(s.top??0))})`),rt(t,I),t.intersect=function(E){return V.polygon(t,g,E)},a}y($0,"curlyBraces");async function D0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?16:a,o=t.look==="neo"?12:a,n=20,l=5,{shapeSvg:h,bbox:c}=await nt(e,t,ot(t)),u=Math.max(n,(c.width+s*2)*1.25,(t==null?void 0:t.width)??0),f=Math.max(l,c.height+o*2,(t==null?void 0:t.height)??0),d=f/2,{cssStyles:p}=t,g=K.svg(h),m=J(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const C=u,x=f,k=C-d,w=x/4,S=[{x:k,y:0},{x:w,y:0},{x:0,y:x/2},{x:w,y:x},{x:k,y:x},...za(-k,-x/2,d,50,270,90)],_=yt(S),T=g.path(_,m),B=h.insert(()=>T,":first-child");return B.attr("class","basic label-container outer-path"),p&&t.look!=="handDrawn"&&B.selectChildren("path").attr("style",p),i&&t.look!=="handDrawn"&&B.selectChildren("path").attr("style",i),B.attr("transform",`translate(${-u/2}, ${-f/2})`),rt(t,B),t.intersect=function(z){return V.polygon(t,S,z)},h}y(D0,"curvedTrapezoid");var KM=y((e,t,r,i,a,s)=>[`M${e},${t+s}`,`a${a},${s} 0,0,0 ${r},0`,`a${a},${s} 0,0,0 ${-r},0`,`l0,${i}`,`a${a},${s} 0,0,0 ${r},0`,`l0,${-i}`].join(" "),"createCylinderPathD"),JM=y((e,t,r,i,a,s)=>[`M${e},${t+s}`,`M${e+r},${t+s}`,`a${a},${s} 0,0,0 ${-r},0`,`l0,${i}`,`a${a},${s} 0,0,0 ${r},0`,`l0,${-i}`].join(" "),"createOuterCylinderPathD"),tA=y((e,t,r,i,a,s)=>[`M${e-r/2},${-i/2}`,`a${a},${s} 0,0,0 ${r},0`].join(" "),"createInnerCylinderPathD"),yd=8,Cd=8;async function O0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?24:a,o=t.look==="neo"?24:a;if(t.width||t.height){const m=t.width??0;t.width=(t.width??0)-o,t.width<Cd&&(t.width=Cd);const x=m/2/(2.5+m/50);t.height=(t.height??0)-s-x*3,t.height<yd&&(t.height=yd)}const{shapeSvg:n,bbox:l,label:h}=await nt(e,t,ot(t)),c=(t.width?t.width:l.width)+o,u=c/2,f=u/(2.5+c/50),d=(t.height?t.height:l.height)+s+f;let p;const{cssStyles:g}=t;if(t.look==="handDrawn"){const m=K.svg(n),C=JM(0,0,c,d,u,f),x=tA(0,f,c,d,u,f),k=J(t,{}),w=m.path(C,k),S=m.path(x,J(t,{fill:"none"}));p=n.insert(()=>S,":first-child"),p=n.insert(()=>w,":first-child"),p.attr("class","basic label-container"),g&&p.attr("style",g)}else{const m=KM(0,0,c,d,u,f);p=n.insert("path",":first-child").attr("d",m).attr("class","basic label-container outer-path").attr("style",Ht(g)).attr("style",i)}return p.attr("label-offset-y",f),p.attr("transform",`translate(${-c/2}, ${-(d/2+f)})`),rt(t,p),h.attr("transform",`translate(${-(l.width/2)-(l.x-(l.left??0))}, ${-(l.height/2)+(t.padding??0)/1.5-(l.y-(l.top??0))})`),t.intersect=function(m){const C=V.rect(t,m),x=C.x-(t.x??0);if(u!=0&&(Math.abs(x)<(t.width??0)/2||Math.abs(x)==(t.width??0)/2&&Math.abs(C.y-(t.y??0))>(t.height??0)/2-f)){let k=f*f*(1-x*x/(u*u));k>0&&(k=Math.sqrt(k)),k=f-k,m.y-(t.y??0)>0&&(k=-k),C.y+=k}return C},n}y(O0,"cylinder");async function I0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.look==="neo"?16:t.padding??0,s=t.look==="neo"?16:t.padding??0,{shapeSvg:o,bbox:n,label:l}=await nt(e,t,ot(t)),h=n.width+a,c=n.height+s,u=c*.2,f=-h/2,d=-c/2-u/2,{cssStyles:p}=t,g=K.svg(o),m=J(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const C=[{x:f,y:d+u},{x:-f,y:d+u},{x:-f,y:-d},{x:f,y:-d},{x:f,y:d},{x:-f,y:d},{x:-f,y:d+u}],x=g.polygon(C.map(w=>[w.x,w.y]),m),k=o.insert(()=>x,":first-child");return k.attr("class","basic label-container outer-path"),p&&t.look!=="handDrawn"&&k.selectAll("path").attr("style",p),i&&t.look!=="handDrawn"&&k.selectAll("path").attr("style",i),l.attr("transform",`translate(${f+(t.padding??0)/2-(n.x-(n.left??0))}, ${d+u+(t.padding??0)/2-(n.y-(n.top??0))})`),rt(t,k),t.intersect=function(w){return V.rect(t,w)},o}y(I0,"dividedRectangle");async function P0(e,t){var d,p;const{labelStyles:r,nodeStyles:i}=tt(t),a=t.look==="neo"?12:5;t.labelStyle=r;const s=t.padding??0,o=t.look==="neo"?16:s,{shapeSvg:n,bbox:l}=await nt(e,t,ot(t)),h=(t!=null&&t.width?(t==null?void 0:t.width)/2:l.width/2)+(o??0),c=h-a;let u;const{cssStyles:f}=t;if(t.look==="handDrawn"){const g=K.svg(n),m=J(t,{roughness:.2,strokeWidth:2.5}),C=J(t,{roughness:.2,strokeWidth:1.5}),x=g.circle(0,0,h*2,m),k=g.circle(0,0,c*2,C);u=n.insert("g",":first-child"),u.attr("class",Ht(t.cssClasses)).attr("style",Ht(f)),(d=u.node())==null||d.appendChild(x),(p=u.node())==null||p.appendChild(k)}else{u=n.insert("g",":first-child");const g=u.insert("circle",":first-child"),m=u.insert("circle");u.attr("class","basic label-container").attr("style",i),g.attr("class","outer-circle").attr("style",i).attr("r",h).attr("cx",0).attr("cy",0),m.attr("class","inner-circle").attr("style",i).attr("r",c).attr("cx",0).attr("cy",0)}return rt(t,u),t.intersect=function(g){return W.info("DoubleCircle intersect",t,h,g),V.circle(t,h,g)},n}y(P0,"doublecircle");function R0(e,t,{config:{themeVariables:r}}){const{labelStyles:i,nodeStyles:a}=tt(t);t.label="",t.labelStyle=i;const s=e.insert("g").attr("class",ot(t)).attr("id",t.domId??t.id),o=7,{cssStyles:n}=t,l=K.svg(s),{nodeBorder:h}=r,c=J(t,{fillStyle:"solid"});t.look!=="handDrawn"&&(c.roughness=0);const u=l.circle(0,0,o*2,c),f=s.insert(()=>u,":first-child");return f.selectAll("path").attr("style",`fill: ${h} !important;`),n&&n.length>0&&t.look!=="handDrawn"&&f.selectAll("path").attr("style",n),a&&t.look!=="handDrawn"&&f.selectAll("path").attr("style",a),rt(t,f),t.intersect=function(d){return W.info("filledCircle intersect",t,{radius:o,point:d}),V.circle(t,o,d)},s}y(R0,"filledCircle");var xd=10,bd=10;async function N0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?a*2:a;(t.width||t.height)&&(t.height=(t==null?void 0:t.height)??0,t.height<xd&&(t.height=xd),t.width=((t==null?void 0:t.width)??0)-s-s/2,t.width<bd&&(t.width=bd));const{shapeSvg:o,bbox:n,label:l}=await nt(e,t,ot(t)),h=(t!=null&&t.width?t==null?void 0:t.width:n.width)+(s??0),c=t!=null&&t.height?t==null?void 0:t.height:h+n.height,u=c,f=[{x:0,y:-c},{x:u,y:-c},{x:u/2,y:0}],{cssStyles:d}=t,p=K.svg(o),g=J(t,{});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const m=yt(f),C=p.path(m,g),x=o.insert(()=>C,":first-child").attr("transform",`translate(${-c/2}, ${c/2})`).attr("class","outer-path");return d&&t.look!=="handDrawn"&&x.selectChildren("path").attr("style",d),i&&t.look!=="handDrawn"&&x.selectChildren("path").attr("style",i),t.width=h,t.height=c,rt(t,x),l.attr("transform",`translate(${-n.width/2-(n.x-(n.left??0))}, ${-c/2+(t.padding??0)/2+(n.y-(n.top??0))})`),t.intersect=function(k){return W.info("Triangle intersect",t,f,k),V.polygon(t,f,k)},o}y(N0,"flippedTriangle");function q0(e,t,{dir:r,config:{state:i,themeVariables:a}}){const{nodeStyles:s}=tt(t);t.label="";const o=e.insert("g").attr("class",ot(t)).attr("id",t.domId??t.id),{cssStyles:n}=t;let l=Math.max(70,(t==null?void 0:t.width)??0),h=Math.max(10,(t==null?void 0:t.height)??0);r==="LR"&&(l=Math.max(10,(t==null?void 0:t.width)??0),h=Math.max(70,(t==null?void 0:t.height)??0));const c=-1*l/2,u=-1*h/2,f=K.svg(o),d=J(t,{stroke:a.lineColor,fill:a.lineColor});t.look!=="handDrawn"&&(d.roughness=0,d.fillStyle="solid");const p=f.rectangle(c,u,l,h,d),g=o.insert(()=>p,":first-child");n&&t.look!=="handDrawn"&&g.selectAll("path").attr("style",n),s&&t.look!=="handDrawn"&&g.selectAll("path").attr("style",s),rt(t,g);const m=(i==null?void 0:i.padding)??0;return t.width&&t.height&&(t.width+=m/2||0,t.height+=m/2||0),t.intersect=function(C){return V.rect(t,C)},o}y(q0,"forkJoin");async function z0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=15,s=10,o=t.look==="neo"?16:t.padding??0,n=t.look==="neo"?12:t.padding??0;(t.width||t.height)&&(t.height=((t==null?void 0:t.height)??0)-n*2,t.height<s&&(t.height=s),t.width=((t==null?void 0:t.width)??0)-o*2,t.width<a&&(t.width=a));const{shapeSvg:l,bbox:h}=await nt(e,t,ot(t)),c=(t!=null&&t.width?t==null?void 0:t.width:Math.max(a,h.width))+o*2,u=(t!=null&&t.height?t==null?void 0:t.height:Math.max(s,h.height))+n*2,f=u/2,{cssStyles:d}=t,p=K.svg(l),g=J(t,{});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const m=[{x:-c/2,y:-u/2},{x:c/2-f,y:-u/2},...za(-c/2+f,0,f,50,90,270),{x:c/2-f,y:u/2},{x:-c/2,y:u/2}],C=yt(m),x=p.path(C,g),k=l.insert(()=>x,":first-child");return k.attr("class","basic label-container outer-path"),d&&t.look!=="handDrawn"&&k.selectChildren("path").attr("style",d),i&&t.look!=="handDrawn"&&k.selectChildren("path").attr("style",i),rt(t,k),t.intersect=function(w){return W.info("Pill intersect",t,{radius:f,point:w}),V.polygon(t,m,w)},l}y(z0,"halfRoundedRectangle");var eA=y((e,t,r,i,a)=>[`M${e+a},${t}`,`L${e+r-a},${t}`,`L${e+r},${t-i/2}`,`L${e+r-a},${t-i}`,`L${e+a},${t-i}`,`L${e},${t-i/2}`,"Z"].join(" "),"createHexagonPathD");async function W0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t),a=t.look==="neo"?3.5:4;t.labelStyle=r;const s=t.padding??0,o=70,n=32,l=t.look==="neo"?o:s,h=t.look==="neo"?n:s;if(t.width||t.height){const k=(t.height??0)/a;t.width=((t==null?void 0:t.width)??0)-2*k-h,t.height=(t.height??0)-l}const{shapeSvg:c,bbox:u}=await nt(e,t,ot(t)),f=(t!=null&&t.height?t==null?void 0:t.height:u.height)+l,d=f/a,p=(t!=null&&t.width?t==null?void 0:t.width:u.width)+2*d+h,g=[{x:d,y:0},{x:p-d,y:0},{x:p,y:-f/2},{x:p-d,y:-f},{x:d,y:-f},{x:0,y:-f/2}];let m;const{cssStyles:C}=t;if(t.look==="handDrawn"){const x=K.svg(c),k=J(t,{}),w=eA(0,0,p,f,d),S=x.path(w,k);m=c.insert(()=>S,":first-child").attr("transform",`translate(${-p/2}, ${f/2})`),C&&m.attr("style",C)}else m=fr(c,p,f,g);return i&&m.attr("style",i),t.width=p,t.height=f,rt(t,m),t.intersect=function(x){return V.polygon(t,g,x)},c}y(W0,"hexagon");async function H0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.label="",t.labelStyle=r;const{shapeSvg:a}=await nt(e,t,ot(t)),s=Math.max(30,(t==null?void 0:t.width)??0),o=Math.max(30,(t==null?void 0:t.height)??0),{cssStyles:n}=t,l=K.svg(a),h=J(t,{});t.look!=="handDrawn"&&(h.roughness=0,h.fillStyle="solid");const c=[{x:0,y:0},{x:s,y:0},{x:0,y:o},{x:s,y:o}],u=yt(c),f=l.path(u,h),d=a.insert(()=>f,":first-child");return d.attr("class","basic label-container outer-path"),n&&t.look!=="handDrawn"&&d.selectChildren("path").attr("style",n),i&&t.look!=="handDrawn"&&d.selectChildren("path").attr("style",i),d.attr("transform",`translate(${-s/2}, ${-o/2})`),rt(t,d),t.intersect=function(p){return W.info("Pill intersect",t,{points:c}),V.polygon(t,c,p)},a}y(H0,"hourglass");async function U0(e,t,{config:{themeVariables:r,flowchart:i}}){const{labelStyles:a}=tt(t);t.labelStyle=a;const s=t.assetHeight??48,o=t.assetWidth??48,n=Math.max(s,o),l=i==null?void 0:i.wrappingWidth;t.width=Math.max(n,l??0);const{shapeSvg:h,bbox:c,label:u}=await nt(e,t,"icon-shape default"),f=t.pos==="t",d=n,p=n,{nodeBorder:g}=r,{stylesMap:m}=ji(t),C=-p/2,x=-d/2,k=t.label?8:0,w=K.svg(h),S=J(t,{stroke:"none",fill:"none"});t.look!=="handDrawn"&&(S.roughness=0,S.fillStyle="solid");const _=w.rectangle(C,x,p,d,S),T=Math.max(p,c.width),B=d+c.height+k,z=w.rectangle(-T/2,-B/2,T,B,{...S,fill:"transparent",stroke:"none"}),I=h.insert(()=>_,":first-child"),E=h.insert(()=>z);if(t.icon){const N=h.append("g");N.html(`<g>${await Ja(t.icon,{height:n,width:n,fallbackPrefix:""})}</g>`);const D=N.node().getBBox(),M=D.width,$=D.height,A=D.x,O=D.y;N.attr("transform",`translate(${-M/2-A},${f?c.height/2+k/2-$/2-O:-c.height/2-k/2-$/2-O})`),N.attr("style",`color: ${m.get("stroke")??g};`)}return u.attr("transform",`translate(${-c.width/2-(c.x-(c.left??0))},${f?-B/2:B/2-c.height})`),I.attr("transform",`translate(0,${f?c.height/2+k/2:-c.height/2-k/2})`),rt(t,E),t.intersect=function(N){if(W.info("iconSquare intersect",t,N),!t.label)return V.rect(t,N);const D=t.x??0,M=t.y??0,$=t.height??0;let A=[];return f?A=[{x:D-c.width/2,y:M-$/2},{x:D+c.width/2,y:M-$/2},{x:D+c.width/2,y:M-$/2+c.height+k},{x:D+p/2,y:M-$/2+c.height+k},{x:D+p/2,y:M+$/2},{x:D-p/2,y:M+$/2},{x:D-p/2,y:M-$/2+c.height+k},{x:D-c.width/2,y:M-$/2+c.height+k}]:A=[{x:D-p/2,y:M-$/2},{x:D+p/2,y:M-$/2},{x:D+p/2,y:M-$/2+d},{x:D+c.width/2,y:M-$/2+d},{x:D+c.width/2/2,y:M+$/2},{x:D-c.width/2,y:M+$/2},{x:D-c.width/2,y:M-$/2+d},{x:D-p/2,y:M-$/2+d}],V.polygon(t,A,N)},h}y(U0,"icon");async function Y0(e,t,{config:{themeVariables:r,flowchart:i}}){const{labelStyles:a}=tt(t);t.labelStyle=a;const s=t.assetHeight??48,o=t.assetWidth??48,n=Math.max(s,o),l=i==null?void 0:i.wrappingWidth;t.width=Math.max(n,l??0);const{shapeSvg:h,bbox:c,label:u}=await nt(e,t,"icon-shape default"),f=20,d=t.label?8:0,p=t.pos==="t",{nodeBorder:g,mainBkg:m}=r,{stylesMap:C}=ji(t),x=K.svg(h),k=J(t,{});t.look!=="handDrawn"&&(k.roughness=0,k.fillStyle="solid");const w=C.get("fill");k.stroke=w??m;const S=h.append("g");t.icon&&S.html(`<g>${await Ja(t.icon,{height:n,width:n,fallbackPrefix:""})}</g>`);const _=S.node().getBBox(),T=_.width,B=_.height,z=_.x,I=_.y,E=Math.max(T,B)*Math.SQRT2+f*2,N=x.circle(0,0,E,k),D=Math.max(E,c.width),M=E+c.height+d,$=x.rectangle(-D/2,-M/2,D,M,{...k,fill:"transparent",stroke:"none"}),A=h.insert(()=>N,":first-child"),O=h.insert(()=>$);return S.attr("transform",`translate(${-T/2-z},${p?c.height/2+d/2-B/2-I:-c.height/2-d/2-B/2-I})`),S.attr("style",`color: ${C.get("stroke")??g};`),u.attr("transform",`translate(${-c.width/2-(c.x-(c.left??0))},${p?-M/2:M/2-c.height})`),A.attr("transform",`translate(0,${p?c.height/2+d/2:-c.height/2-d/2})`),rt(t,O),t.intersect=function(F){return W.info("iconSquare intersect",t,F),V.rect(t,F)},h}y(Y0,"iconCircle");async function j0(e,t,{config:{themeVariables:r,flowchart:i}}){const{labelStyles:a}=tt(t);t.labelStyle=a;const s=t.assetHeight??48,o=t.assetWidth??48,n=Math.max(s,o),l=i==null?void 0:i.wrappingWidth;t.width=Math.max(n,l??0);const{shapeSvg:h,bbox:c,halfPadding:u,label:f}=await nt(e,t,"icon-shape default"),d=t.pos==="t",p=n+u*2,g=n+u*2,{nodeBorder:m,mainBkg:C}=r,{stylesMap:x}=ji(t),k=-g/2,w=-p/2,S=t.label?8:0,_=K.svg(h),T=J(t,{});t.look!=="handDrawn"&&(T.roughness=0,T.fillStyle="solid");const B=x.get("fill");T.stroke=B??C;const z=_.path(_r(k,w,g,p,5),T),I=Math.max(g,c.width),E=p+c.height+S,N=_.rectangle(-I/2,-E/2,I,E,{...T,fill:"transparent",stroke:"none"}),D=h.insert(()=>z,":first-child").attr("class","icon-shape2"),M=h.insert(()=>N);if(t.icon){const $=h.append("g");$.html(`<g>${await Ja(t.icon,{height:n,width:n,fallbackPrefix:""})}</g>`);const A=$.node().getBBox(),O=A.width,F=A.height,H=A.x,Y=A.y;$.attr("transform",`translate(${-O/2-H},${d?c.height/2+S/2-F/2-Y:-c.height/2-S/2-F/2-Y})`),$.attr("style",`color: ${x.get("stroke")??m};`)}return f.attr("transform",`translate(${-c.width/2-(c.x-(c.left??0))},${d?-E/2:E/2-c.height})`),D.attr("transform",`translate(0,${d?c.height/2+S/2:-c.height/2-S/2})`),rt(t,M),t.intersect=function($){if(W.info("iconSquare intersect",t,$),!t.label)return V.rect(t,$);const A=t.x??0,O=t.y??0,F=t.height??0;let H=[];return d?H=[{x:A-c.width/2,y:O-F/2},{x:A+c.width/2,y:O-F/2},{x:A+c.width/2,y:O-F/2+c.height+S},{x:A+g/2,y:O-F/2+c.height+S},{x:A+g/2,y:O+F/2},{x:A-g/2,y:O+F/2},{x:A-g/2,y:O-F/2+c.height+S},{x:A-c.width/2,y:O-F/2+c.height+S}]:H=[{x:A-g/2,y:O-F/2},{x:A+g/2,y:O-F/2},{x:A+g/2,y:O-F/2+p},{x:A+c.width/2,y:O-F/2+p},{x:A+c.width/2/2,y:O+F/2},{x:A-c.width/2,y:O+F/2},{x:A-c.width/2,y:O-F/2+p},{x:A-g/2,y:O-F/2+p}],V.polygon(t,H,$)},h}y(j0,"iconRounded");async function G0(e,t,{config:{themeVariables:r,flowchart:i}}){const{labelStyles:a}=tt(t);t.labelStyle=a;const s=t.assetHeight??48,o=t.assetWidth??48,n=Math.max(s,o),l=i==null?void 0:i.wrappingWidth;t.width=Math.max(n,l??0);const{shapeSvg:h,bbox:c,halfPadding:u,label:f}=await nt(e,t,"icon-shape default"),d=t.pos==="t",p=n+u*2,g=n+u*2,{nodeBorder:m,mainBkg:C}=r,{stylesMap:x}=ji(t),k=-g/2,w=-p/2,S=t.label?8:0,_=K.svg(h),T=J(t,{});t.look!=="handDrawn"&&(T.roughness=0,T.fillStyle="solid");const B=x.get("fill");T.stroke=B??C;const z=_.path(_r(k,w,g,p,.1),T),I=Math.max(g,c.width),E=p+c.height+S,N=_.rectangle(-I/2,-E/2,I,E,{...T,fill:"transparent",stroke:"none"}),D=h.insert(()=>z,":first-child"),M=h.insert(()=>N);if(t.icon){const $=h.append("g");$.html(`<g>${await Ja(t.icon,{height:n,width:n,fallbackPrefix:""})}</g>`);const A=$.node().getBBox(),O=A.width,F=A.height,H=A.x,Y=A.y;$.attr("transform",`translate(${-O/2-H},${d?c.height/2+S/2-F/2-Y:-c.height/2-S/2-F/2-Y})`),$.attr("style",`color: ${x.get("stroke")??m};`)}return f.attr("transform",`translate(${-c.width/2-(c.x-(c.left??0))},${d?-E/2:E/2-c.height})`),D.attr("transform",`translate(0,${d?c.height/2+S/2:-c.height/2-S/2})`),rt(t,M),t.intersect=function($){if(W.info("iconSquare intersect",t,$),!t.label)return V.rect(t,$);const A=t.x??0,O=t.y??0,F=t.height??0;let H=[];return d?H=[{x:A-c.width/2,y:O-F/2},{x:A+c.width/2,y:O-F/2},{x:A+c.width/2,y:O-F/2+c.height+S},{x:A+g/2,y:O-F/2+c.height+S},{x:A+g/2,y:O+F/2},{x:A-g/2,y:O+F/2},{x:A-g/2,y:O-F/2+c.height+S},{x:A-c.width/2,y:O-F/2+c.height+S}]:H=[{x:A-g/2,y:O-F/2},{x:A+g/2,y:O-F/2},{x:A+g/2,y:O-F/2+p},{x:A+c.width/2,y:O-F/2+p},{x:A+c.width/2/2,y:O+F/2},{x:A-c.width/2,y:O+F/2},{x:A-c.width/2,y:O-F/2+p},{x:A-g/2,y:O-F/2+p}],V.polygon(t,H,$)},h}y(G0,"iconSquare");async function X0(e,t,{config:{flowchart:r}}){const i=new Image;i.src=(t==null?void 0:t.img)??"",await i.decode();const a=Number(i.naturalWidth.toString().replace("px","")),s=Number(i.naturalHeight.toString().replace("px",""));t.imageAspectRatio=a/s;const{labelStyles:o}=tt(t);t.labelStyle=o;const n=r==null?void 0:r.wrappingWidth;t.defaultWidth=r==null?void 0:r.wrappingWidth;const l=Math.max(t.label?n??0:0,(t==null?void 0:t.assetWidth)??a),h=t.constraint==="on"&&t!=null&&t.assetHeight?t.assetHeight*t.imageAspectRatio:l,c=t.constraint==="on"?h/t.imageAspectRatio:(t==null?void 0:t.assetHeight)??s;t.width=Math.max(h,n??0);const{shapeSvg:u,bbox:f,label:d}=await nt(e,t,"image-shape default"),p=t.pos==="t",g=-h/2,m=-c/2,C=t.label?8:0,x=K.svg(u),k=J(t,{});t.look!=="handDrawn"&&(k.roughness=0,k.fillStyle="solid");const w=x.rectangle(g,m,h,c,k),S=Math.max(h,f.width),_=c+f.height+C,T=x.rectangle(-S/2,-_/2,S,_,{...k,fill:"none",stroke:"none"}),B=u.insert(()=>w,":first-child"),z=u.insert(()=>T);if(t.img){const I=u.append("image");I.attr("href",t.img),I.attr("width",h),I.attr("height",c),I.attr("preserveAspectRatio","none"),I.attr("transform",`translate(${-h/2},${p?_/2-c:-_/2})`)}return d.attr("transform",`translate(${-f.width/2-(f.x-(f.left??0))},${p?-c/2-f.height/2-C/2:c/2-f.height/2+C/2})`),B.attr("transform",`translate(0,${p?f.height/2+C/2:-f.height/2-C/2})`),rt(t,z),t.intersect=function(I){if(W.info("iconSquare intersect",t,I),!t.label)return V.rect(t,I);const E=t.x??0,N=t.y??0,D=t.height??0;let M=[];return p?M=[{x:E-f.width/2,y:N-D/2},{x:E+f.width/2,y:N-D/2},{x:E+f.width/2,y:N-D/2+f.height+C},{x:E+h/2,y:N-D/2+f.height+C},{x:E+h/2,y:N+D/2},{x:E-h/2,y:N+D/2},{x:E-h/2,y:N-D/2+f.height+C},{x:E-f.width/2,y:N-D/2+f.height+C}]:M=[{x:E-h/2,y:N-D/2},{x:E+h/2,y:N-D/2},{x:E+h/2,y:N-D/2+c},{x:E+f.width/2,y:N-D/2+c},{x:E+f.width/2/2,y:N+D/2},{x:E-f.width/2,y:N+D/2},{x:E-f.width/2,y:N-D/2+c},{x:E-h/2,y:N-D/2+c}],V.polygon(t,M,I)},u}y(X0,"imageSquare");async function V0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=a,o=t.look==="neo"?a*2:a,{shapeSvg:n,bbox:l}=await nt(e,t,ot(t)),h=Math.max(l.width+(o??0)*2,(t==null?void 0:t.width)??0),c=Math.max(l.height+(s??0)*2,(t==null?void 0:t.height)??0),u=[{x:0,y:0},{x:h,y:0},{x:h+3*c/6,y:-c},{x:-3*c/6,y:-c}];let f;const{cssStyles:d}=t;if(t.look==="handDrawn"){const p=K.svg(n),g=J(t,{}),m=yt(u),C=p.path(m,g);f=n.insert(()=>C,":first-child").attr("transform",`translate(${-h/2}, ${c/2})`),d&&f.attr("style",d)}else f=fr(n,h,c,u);return i&&f.attr("style",i),t.width=h,t.height=c,rt(t,f),t.intersect=function(p){return V.polygon(t,u,p)},n}y(V0,"inv_trapezoid");async function es(e,t,r){const{labelStyles:i,nodeStyles:a}=tt(t);t.labelStyle=i;const{shapeSvg:s,bbox:o}=await nt(e,t,ot(t)),n=Math.max(o.width+r.labelPaddingX*2,(t==null?void 0:t.width)||0),l=Math.max(o.height+r.labelPaddingY*2,(t==null?void 0:t.height)||0),h=-n/2,c=-l/2;let u,{rx:f,ry:d}=t;const{cssStyles:p}=t;if(r!=null&&r.rx&&r.ry&&(f=r.rx,d=r.ry),t.look==="handDrawn"){const g=K.svg(s),m=J(t,{}),C=f||d?g.path(_r(h,c,n,l,f||0),m):g.rectangle(h,c,n,l,m);u=s.insert(()=>C,":first-child"),u.attr("class","basic label-container").attr("style",Ht(p))}else u=s.insert("rect",":first-child"),u.attr("class","basic label-container").attr("style",a).attr("rx",Ht(f)).attr("ry",Ht(d)).attr("x",h).attr("y",c).attr("width",n).attr("height",l);return rt(t,u),t.calcIntersect=function(g,m){return V.rect(g,m)},t.intersect=function(g){return V.rect(t,g)},s}y(es,"drawRect");async function Z0(e,t){const{shapeSvg:r,bbox:i,label:a}=await nt(e,t,"label"),s=r.insert("rect",":first-child");return s.attr("width",.1).attr("height",.1),r.attr("class","label edgeLabel"),a.attr("transform",`translate(${-(i.width/2)-(i.x-(i.left??0))}, ${-(i.height/2)-(i.y-(i.top??0))})`),rt(t,s),t.intersect=function(l){return V.rect(t,l)},r}y(Z0,"labelRect");async function Q0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=a,o=t.look==="neo"?a*2:a,{shapeSvg:n,bbox:l}=await nt(e,t,ot(t)),h=((t==null?void 0:t.height)??l.height)+s,c=((t==null?void 0:t.width)??l.width)+o,u=[{x:0,y:0},{x:c+3*h/6,y:0},{x:c,y:-h},{x:-(3*h)/6,y:-h}];let f;const{cssStyles:d}=t;if(t.look==="handDrawn"){const p=K.svg(n),g=J(t,{}),m=yt(u),C=p.path(m,g);f=n.insert(()=>C,":first-child").attr("transform",`translate(${-c/2}, ${h/2})`),d&&f.attr("style",d)}else f=fr(n,c,h,u);return i&&f.attr("style",i),t.width=c,t.height=h,rt(t,f),t.intersect=function(p){return V.polygon(t,u,p)},n}y(Q0,"lean_left");async function K0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=a,o=t.look==="neo"?a*2:a,{shapeSvg:n,bbox:l}=await nt(e,t,ot(t)),h=((t==null?void 0:t.height)??l.height)+s,c=((t==null?void 0:t.width)??l.width)+o,u=[{x:-3*h/6,y:0},{x:c,y:0},{x:c+3*h/6,y:-h},{x:0,y:-h}];let f;const{cssStyles:d}=t;if(t.look==="handDrawn"){const p=K.svg(n),g=J(t,{}),m=yt(u),C=p.path(m,g);f=n.insert(()=>C,":first-child").attr("transform",`translate(${-c/2}, ${h/2})`),d&&f.attr("style",d)}else f=fr(n,c,h,u);return i&&f.attr("style",i),t.width=c,t.height=h,rt(t,f),t.intersect=function(p){return V.polygon(t,u,p)},n}y(K0,"lean_right");function J0(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.label="",t.labelStyle=r;const a=e.insert("g").attr("class",ot(t)).attr("id",t.domId??t.id),{cssStyles:s}=t,o=Math.max(35,(t==null?void 0:t.width)??0),n=Math.max(35,(t==null?void 0:t.height)??0),l=7,h=[{x:o,y:0},{x:0,y:n+l/2},{x:o-2*l,y:n+l/2},{x:0,y:2*n},{x:o,y:n-l/2},{x:2*l,y:n-l/2}],c=K.svg(a),u=J(t,{});t.look!=="handDrawn"&&(u.roughness=0,u.fillStyle="solid");const f=yt(h),d=c.path(f,u),p=a.insert(()=>d,":first-child");return p.attr("class","outer-path"),s&&t.look!=="handDrawn"&&p.selectAll("path").attr("style",s),i&&t.look!=="handDrawn"&&p.selectAll("path").attr("style",i),p.attr("transform",`translate(-${o/2},${-n})`),rt(t,p),t.intersect=function(g){return W.info("lightningBolt intersect",t,g),V.polygon(t,h,g)},a}y(J0,"lightningBolt");var rA=y((e,t,r,i,a,s,o)=>[`M${e},${t+s}`,`a${a},${s} 0,0,0 ${r},0`,`a${a},${s} 0,0,0 ${-r},0`,`l0,${i}`,`a${a},${s} 0,0,0 ${r},0`,`l0,${-i}`,`M${e},${t+s+o}`,`a${a},${s} 0,0,0 ${r},0`].join(" "),"createCylinderPathD"),iA=y((e,t,r,i,a,s,o)=>[`M${e},${t+s}`,`M${e+r},${t+s}`,`a${a},${s} 0,0,0 ${-r},0`,`l0,${i}`,`a${a},${s} 0,0,0 ${r},0`,`l0,${-i}`,`M${e},${t+s+o}`,`a${a},${s} 0,0,0 ${r},0`].join(" "),"createOuterCylinderPathD"),aA=y((e,t,r,i,a,s)=>[`M${e-r/2},${-i/2}`,`a${a},${s} 0,0,0 ${r},0`].join(" "),"createInnerCylinderPathD"),kd=10,Td=10;async function ty(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?16:a,o=t.look==="neo"?24:a;if(t.width||t.height){const C=t.width??0;t.width=(t.width??0)-s,t.width<Td&&(t.width=Td);const k=C/2/(2.5+C/50);t.height=(t.height??0)-o-k*3,t.height<kd&&(t.height=kd)}const{shapeSvg:n,bbox:l,label:h}=await nt(e,t,ot(t)),c=(t!=null&&t.width?t==null?void 0:t.width:l.width)+s*2,u=c/2,f=u/(2.5+c/50),d=(t!=null&&t.height?t==null?void 0:t.height:l.height)+f+o*2,p=d*.1;let g;const{cssStyles:m}=t;if(t.look==="handDrawn"){const C=K.svg(n),x=iA(0,0,c,d,u,f,p),k=aA(0,f,c,d,u,f),w=J(t,{}),S=C.path(x,w),_=C.path(k,w);n.insert(()=>_,":first-child").attr("class","line"),g=n.insert(()=>S,":first-child"),g.attr("class","basic label-container"),m&&g.attr("style",m)}else{const C=rA(0,0,c,d,u,f,p);g=n.insert("path",":first-child").attr("d",C).attr("class","basic label-container outer-path").attr("style",Ht(m)).attr("style",i)}return g.attr("label-offset-y",f),g.attr("transform",`translate(${-c/2}, ${-(d/2+f)})`),rt(t,g),h.attr("transform",`translate(${-(l.width/2)-(l.x-(l.left??0))}, ${-(l.height/2)+f-(l.y-(l.top??0))})`),t.intersect=function(C){const x=V.rect(t,C),k=x.x-(t.x??0);if(u!=0&&(Math.abs(k)<(t.width??0)/2||Math.abs(k)==(t.width??0)/2&&Math.abs(x.y-(t.y??0))>(t.height??0)/2-f)){let w=f*f*(1-k*k/(u*u));w>0&&(w=Math.sqrt(w)),w=f-w,C.y-(t.y??0)>0&&(w=-w),x.y+=w}return x},n}y(ty,"linedCylinder");async function ey(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?16:a,o=t.look==="neo"?12:a;if(t.width||t.height){const w=t.width;t.width=(w??0)*10/11-s*2,t.width<10&&(t.width=10),t.height=((t==null?void 0:t.height)??0)-o*2,t.height<10&&(t.height=10)}const{shapeSvg:n,bbox:l,label:h}=await nt(e,t,ot(t)),c=(t!=null&&t.width?t==null?void 0:t.width:l.width)+(s??0)*2,u=(t!=null&&t.height?t==null?void 0:t.height:l.height)+(o??0)*2,f=t.look==="neo"?u/4:u/8,d=u+f,{cssStyles:p}=t,g=K.svg(n),m=J(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const C=[{x:-c/2-c/2*.1,y:-d/2},{x:-c/2-c/2*.1,y:d/2},...Tr(-c/2-c/2*.1,d/2,c/2+c/2*.1,d/2,f,.8),{x:c/2+c/2*.1,y:-d/2},{x:-c/2-c/2*.1,y:-d/2},{x:-c/2,y:-d/2},{x:-c/2,y:d/2*1.1},{x:-c/2,y:-d/2}],x=g.polygon(C.map(w=>[w.x,w.y]),m),k=n.insert(()=>x,":first-child");return k.attr("class","basic label-container outer-path"),p&&t.look!=="handDrawn"&&k.selectAll("path").attr("style",p),i&&t.look!=="handDrawn"&&k.selectAll("path").attr("style",i),k.attr("transform",`translate(0,${-f/2})`),h.attr("transform",`translate(${-c/2+(t.padding??0)+c/2*.1/2-(l.x-(l.left??0))},${-u/2+(t.padding??0)-f/2-(l.y-(l.top??0))})`),rt(t,k),t.intersect=function(w){return V.polygon(t,C,w)},n}y(ey,"linedWaveEdgedRect");async function ry(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?16:a,o=t.look==="neo"?12:a,n=t.look==="neo"?10:5;(t.width||t.height)&&(t.width=Math.max(((t==null?void 0:t.width)??0)-s*2-2*n,10),t.height=Math.max(((t==null?void 0:t.height)??0)-o*2-2*n,10));const{shapeSvg:l,bbox:h,label:c}=await nt(e,t,ot(t)),u=(t!=null&&t.width?t==null?void 0:t.width:h.width)+s*2+2*n,f=(t!=null&&t.height?t==null?void 0:t.height:h.height)+o*2+2*n,d=u-2*n,p=f-2*n,g=-d/2,m=-p/2,{cssStyles:C}=t,x=K.svg(l),k=J(t,{}),w=[{x:g-n,y:m+n},{x:g-n,y:m+p+n},{x:g+d-n,y:m+p+n},{x:g+d-n,y:m+p},{x:g+d,y:m+p},{x:g+d,y:m+p-n},{x:g+d+n,y:m+p-n},{x:g+d+n,y:m-n},{x:g+n,y:m-n},{x:g+n,y:m},{x:g,y:m},{x:g,y:m+n}],S=[{x:g,y:m+n},{x:g+d-n,y:m+n},{x:g+d-n,y:m+p},{x:g+d,y:m+p},{x:g+d,y:m},{x:g,y:m}];t.look!=="handDrawn"&&(k.roughness=0,k.fillStyle="solid");const _=yt(w);let T=x.path(_,k);const B=yt(S);let z=x.path(B,k);t.look!=="handDrawn"&&(T=jl(T),z=jl(z));const I=l.insert("g",":first-child");return I.insert(()=>T),I.insert(()=>z),I.attr("class","basic label-container outer-path"),C&&t.look!=="handDrawn"&&I.selectAll("path").attr("style",C),i&&t.look!=="handDrawn"&&I.selectAll("path").attr("style",i),c.attr("transform",`translate(${-(h.width/2)-n-(h.x-(h.left??0))}, ${-(h.height/2)+n-(h.y-(h.top??0))})`),rt(t,I),t.intersect=function(E){return V.polygon(t,w,E)},l}y(ry,"multiRect");async function iy(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const{shapeSvg:a,bbox:s,label:o}=await nt(e,t,ot(t)),n=t.padding??0,l=t.look==="neo"?16:n,h=t.look==="neo"?12:n;let c=!0;(t.width||t.height)&&(c=!1,t.width=((t==null?void 0:t.width)??0)-l*2,t.height=((t==null?void 0:t.height)??0)-h*3);const u=Math.max(s.width,(t==null?void 0:t.width)??0)+l*2,f=Math.max(s.height,(t==null?void 0:t.height)??0)+h*3,d=t.look==="neo"?f/4:f/8,p=f+(c?d/2:-d/2),g=-u/2,m=-p/2,C=10,{cssStyles:x}=t,k=Tr(g-C,m+p+C,g+u-C,m+p+C,d,.8),w=k==null?void 0:k[k.length-1],S=[{x:g-C,y:m+C},{x:g-C,y:m+p+C},...k,{x:g+u-C,y:w.y-C},{x:g+u,y:w.y-C},{x:g+u,y:w.y-2*C},{x:g+u+C,y:w.y-2*C},{x:g+u+C,y:m-C},{x:g+C,y:m-C},{x:g+C,y:m},{x:g,y:m},{x:g,y:m+C}],_=[{x:g,y:m+C},{x:g+u-C,y:m+C},{x:g+u-C,y:w.y-C},{x:g+u,y:w.y-C},{x:g+u,y:m},{x:g,y:m}],T=K.svg(a),B=J(t,{});t.look!=="handDrawn"&&(B.roughness=0,B.fillStyle="solid");const z=yt(S),I=T.path(z,B),E=yt(_),N=T.path(E,B),D=a.insert(()=>I,":first-child");return D.insert(()=>N),D.attr("class","basic label-container outer-path"),x&&t.look!=="handDrawn"&&D.selectAll("path").attr("style",x),i&&t.look!=="handDrawn"&&D.selectAll("path").attr("style",i),D.attr("transform",`translate(0,${-d/2})`),o.attr("transform",`translate(${-(s.width/2)-C-(s.x-(s.left??0))}, ${-(s.height/2)+C-d/2-(s.y-(s.top??0))})`),rt(t,D),t.intersect=function(M){return V.polygon(t,S,M)},a}y(iy,"multiWaveEdgedRectangle");async function ay(e,t,{config:{themeVariables:r}}){const{labelStyles:i,nodeStyles:a}=tt(t);t.labelStyle=i,t.useHtmlLabels||ne(At())||(t.centerLabel=!0);const{shapeSvg:o,bbox:n,label:l}=await nt(e,t,ot(t)),h=Math.max(n.width+(t.padding??0)*2,(t==null?void 0:t.width)??0),c=Math.max(n.height+(t.padding??0)*2,(t==null?void 0:t.height)??0),u=-h/2,f=-c/2,{cssStyles:d}=t,p=K.svg(o),g=J(t,{fill:r.noteBkgColor,stroke:r.noteBorderColor});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const m=p.rectangle(u,f,h,c,g),C=o.insert(()=>m,":first-child");return C.attr("class","basic label-container outer-path"),l.attr("class","label noteLabel"),d&&t.look!=="handDrawn"&&C.selectAll("path").attr("style",d),a&&t.look!=="handDrawn"&&C.selectAll("path").attr("style",a),l.attr("transform",`translate(${-n.width/2-(n.x-(n.left??0))}, ${-(n.height/2)-(n.y-(n.top??0))})`),rt(t,C),t.intersect=function(x){return V.rect(t,x)},o}y(ay,"note");var sA=y((e,t,r)=>[`M${e+r/2},${t}`,`L${e+r},${t-r/2}`,`L${e+r/2},${t-r}`,`L${e},${t-r/2}`,"Z"].join(" "),"createDecisionBoxPathD");async function sy(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const{shapeSvg:a,bbox:s}=await nt(e,t,ot(t)),o=s.width+(t.padding??0),n=s.height+(t.padding??0),l=o+n,h=.5,c=[{x:l/2,y:0},{x:l,y:-l/2},{x:l/2,y:-l},{x:0,y:-l/2}];let u;const{cssStyles:f}=t;if(t.look==="handDrawn"){const d=K.svg(a),p=J(t,{}),g=sA(0,0,l),m=d.path(g,p);u=a.insert(()=>m,":first-child").attr("transform",`translate(${-l/2+h}, ${l/2})`),f&&u.attr("style",f)}else u=fr(a,l,l,c),u.attr("transform",`translate(${-l/2+h}, ${l/2})`);return i&&u.attr("style",i),rt(t,u),t.calcIntersect=function(d,p){const g=d.width,m=[{x:g/2,y:0},{x:g,y:-g/2},{x:g/2,y:-g},{x:0,y:-g/2}],C=V.polygon(d,m,p);return{x:C.x-.5,y:C.y-.5}},t.intersect=function(d){return this.calcIntersect(t,d)},a}y(sy,"question");async function oy(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?21:a??0,o=t.look==="neo"?12:a??0,{shapeSvg:n,bbox:l,label:h}=await nt(e,t,ot(t)),c=((t==null?void 0:t.width)??l.width)+(t.look==="neo"?s*2:s),u=((t==null?void 0:t.height)??l.height)+(t.look==="neo"?o*2:o),f=-c/2,d=-u/2,p=d/2,g=[{x:f+p,y:d},{x:f,y:0},{x:f+p,y:-d},{x:-f,y:-d},{x:-f,y:d}],{cssStyles:m}=t,C=K.svg(n),x=J(t,{});t.look!=="handDrawn"&&(x.roughness=0,x.fillStyle="solid");const k=yt(g),w=C.path(k,x),S=n.insert(()=>w,":first-child");return S.attr("class","basic label-container outer-path"),m&&t.look!=="handDrawn"&&S.selectAll("path").attr("style",m),i&&t.look!=="handDrawn"&&S.selectAll("path").attr("style",i),S.attr("transform",`translate(${-p/2},0)`),h.attr("transform",`translate(${-p/2-l.width/2-(l.x-(l.left??0))}, ${-(l.height/2)-(l.y-(l.top??0))})`),rt(t,S),t.intersect=function(_){return V.polygon(t,g,_)},n}y(oy,"rect_left_inv_arrow");async function ny(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;let a;t.cssClasses?a="node "+t.cssClasses:a="node default";const s=e.insert("g").attr("class",a).attr("id",t.domId||t.id),o=s.insert("g"),n=s.insert("g").attr("class","label").attr("style",i),l=t.description,h=t.label,c=await gr(n,h,t.labelStyle,!0,!0);let u={width:0,height:0};if(ne(bt())){const B=c.children[0],z=pt(c);u=B.getBoundingClientRect(),z.attr("width",u.width),z.attr("height",u.height)}W.info("Text 2",l);const f=l||[],d=c.getBBox(),p=await gr(n,Array.isArray(f)?f.join("<br/>"):f,t.labelStyle,!0,!0),g=p.children[0],m=pt(p);u=g.getBoundingClientRect(),m.attr("width",u.width),m.attr("height",u.height);const C=(t.padding||0)/2;pt(p).attr("transform","translate( "+(u.width>d.width?0:(d.width-u.width)/2)+", "+(d.height+C+5)+")"),pt(c).attr("transform","translate( "+(u.width<d.width?0:-(d.width-u.width)/2)+", 0)"),u=n.node().getBBox(),n.attr("transform","translate("+-u.width/2+", "+(-u.height/2-C+3)+")");const x=u.width+(t.padding||0),k=u.height+(t.padding||0),w=-u.width/2-C,S=-u.height/2-C;let _,T;if(t.look==="handDrawn"){const B=K.svg(s),z=J(t,{}),I=B.path(_r(w,S,x,k,t.rx||0),z),E=B.line(-u.width/2-C,-u.height/2-C+d.height+C,u.width/2+C,-u.height/2-C+d.height+C,z);T=s.insert(()=>(W.debug("Rough node insert CXC",I),E),":first-child"),_=s.insert(()=>(W.debug("Rough node insert CXC",I),I),":first-child")}else _=o.insert("rect",":first-child"),T=o.insert("line"),_.attr("class","outer title-state").attr("style",i).attr("x",-u.width/2-C).attr("y",-u.height/2-C).attr("width",u.width+(t.padding||0)).attr("height",u.height+(t.padding||0)),T.attr("class","divider").attr("x1",-u.width/2-C).attr("x2",u.width/2+C).attr("y1",-u.height/2-C+d.height+C).attr("y2",-u.height/2-C+d.height+C);return rt(t,_),t.intersect=function(B){return V.rect(t,B)},s}y(ny,"rectWithTitle");async function ly(e,t,{config:{themeVariables:r}}){const i=(r==null?void 0:r.radius)??5,a={rx:i,ry:i,labelPaddingX:((t==null?void 0:t.padding)??0)*1,labelPaddingY:((t==null?void 0:t.padding)??0)*1};return es(e,t,a)}y(ly,"roundedRect");var Lr=8;async function hy(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.look==="neo"?16:t.padding??0,s=t.look==="neo"?12:t.padding??0,{shapeSvg:o,bbox:n,label:l}=await nt(e,t,ot(t)),h=((t==null?void 0:t.width)??n.width)+a*2+(t.look==="neo"?Lr:Lr*2),c=((t==null?void 0:t.height)??n.height)+s*2,u=h-Lr,f=c,d=Lr-h/2,p=-c/2,{cssStyles:g}=t,m=K.svg(o),C=J(t,{});t.look!=="handDrawn"&&(C.roughness=0,C.fillStyle="solid");const x=[{x:d,y:p},{x:d+u,y:p},{x:d+u,y:p+f},{x:d-Lr,y:p+f},{x:d-Lr,y:p},{x:d,y:p},{x:d,y:p+f}],k=m.polygon(x.map(S=>[S.x,S.y]),C),w=o.insert(()=>k,":first-child");return w.attr("class","basic label-container outer-path").attr("style",Ht(g)),i&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",i),g&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",i),l.attr("transform",`translate(${Lr/2-n.width/2-(n.x-(n.left??0))}, ${-(n.height/2)-(n.y-(n.top??0))})`),rt(t,w),t.intersect=function(S){return V.rect(t,S)},o}y(hy,"shadedProcess");async function cy(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?16:a,o=t.look==="neo"?12:a;(t.width||t.height)&&(t.width=Math.max(((t==null?void 0:t.width)??0)-s*2,10),t.height=Math.max(((t==null?void 0:t.height)??0)/1.5-o*2,10));const{shapeSvg:n,bbox:l,label:h}=await nt(e,t,ot(t)),c=(t!=null&&t.width?t==null?void 0:t.width:l.width)+s*2,u=((t!=null&&t.height?t==null?void 0:t.height:l.height)+o*2)*1.5,f=c,d=u/1.5,p=-f/2,g=-d/2,{cssStyles:m}=t,C=K.svg(n),x=J(t,{});t.look!=="handDrawn"&&(x.roughness=0,x.fillStyle="solid");const k=[{x:p,y:g},{x:p,y:g+d},{x:p+f,y:g+d},{x:p+f,y:g-d/2}],w=yt(k),S=C.path(w,x),_=n.insert(()=>S,":first-child");return _.attr("class","basic label-container outer-path"),m&&t.look!=="handDrawn"&&_.selectChildren("path").attr("style",m),i&&t.look!=="handDrawn"&&_.selectChildren("path").attr("style",i),_.attr("transform",`translate(0, ${d/4})`),h.attr("transform",`translate(${-f/2+(t.padding??0)-(l.x-(l.left??0))}, ${-d/4+(t.padding??0)-(l.y-(l.top??0))})`),rt(t,_),t.intersect=function(T){return V.polygon(t,k,T)},n}y(cy,"slopedRect");async function uy(e,t){const r=t.padding??0,i=t.look==="neo"?16:r*2,a=t.look==="neo"?12:r,s={rx:0,ry:0,labelPaddingX:t.labelPaddingX??i,labelPaddingY:a};return es(e,t,s)}y(uy,"squareRect");async function dy(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?20:a,o=t.look==="neo"?12:a,{shapeSvg:n,bbox:l}=await nt(e,t,ot(t)),h=l.height+(t.look==="neo"?o*2:o),c=l.width+h/4+(t.look==="neo"?s*2:s),u=h/2,{cssStyles:f}=t,d=K.svg(n),p=J(t,{});t.look!=="handDrawn"&&(p.roughness=0,p.fillStyle="solid");const g=[{x:-c/2+u,y:-h/2},{x:c/2-u,y:-h/2},...za(-c/2+u,0,u,50,90,270),{x:c/2-u,y:h/2},...za(c/2-u,0,u,50,270,450)],m=yt(g),C=d.path(m,p),x=n.insert(()=>C,":first-child");return x.attr("class","basic label-container outer-path"),f&&t.look!=="handDrawn"&&x.selectChildren("path").attr("style",f),i&&t.look!=="handDrawn"&&x.selectChildren("path").attr("style",i),rt(t,x),t.intersect=function(k){return V.polygon(t,g,k)},n}y(dy,"stadium");async function fy(e,t){const r={rx:t.look==="neo"?3:5,ry:t.look==="neo"?3:5};return es(e,t,r)}y(fy,"state");function py(e,t,{config:{themeVariables:r}}){var x,k;const{labelStyles:i,nodeStyles:a}=tt(t);t.labelStyle=i;const{cssStyles:s}=t,{lineColor:o,stateBorder:n,nodeBorder:l,nodeShadow:h}=r;(t.width||t.height)&&((t.width??0)<14&&(t.width=14),(t.height??0)<14&&(t.height=14)),t.width||(t.width=14),t.height||(t.height=14);const c=e.insert("g").attr("class","node default").attr("id",t.domId??t.id),u=K.svg(c),f=J(t,{});t.look!=="handDrawn"&&(f.roughness=0,f.fillStyle="solid");const d=u.circle(0,0,t.width,{...f,stroke:o,strokeWidth:2}),p=n??l,g=(t.width??0)*5/14,m=u.circle(0,0,g,{...f,fill:p,stroke:p,strokeWidth:2,fillStyle:"solid"}),C=c.insert(()=>d,":first-child");if(C.insert(()=>m),t.look!=="handDrawn"&&C.attr("class","outer-path"),s&&C.selectAll("path").attr("style",s),a&&C.selectAll("path").attr("style",a),t.width<25&&h&&t.look!=="handDrawn"){const w=((k=(x=e.node())==null?void 0:x.ownerSVGElement)==null?void 0:k.id)??"",S=w?`${w}-drop-shadow-small`:"drop-shadow-small";C.attr("style",`filter:url(#${S})`)}return rt(t,C),t.intersect=function(w){return V.circle(t,(t.width??0)/2,w)},c}y(py,"stateEnd");function gy(e,t,{config:{themeVariables:r}}){var n,l;const{lineColor:i,nodeShadow:a}=r;(t.width||t.height)&&((t.width??0)<14&&(t.width=14),(t.height??0)<14&&(t.height=14)),t.width||(t.width=14),t.height||(t.height=14);const s=e.insert("g").attr("class","node default").attr("id",t.domId||t.id);let o;if(t.look==="handDrawn"){const c=K.svg(s).circle(0,0,t.width,pF(i));o=s.insert(()=>c),o.attr("class","state-start").attr("r",(t.width??7)/2).attr("width",t.width??14).attr("height",t.height??14)}else o=s.insert("circle",":first-child"),o.attr("class","state-start").attr("r",(t.width??7)/2).attr("width",t.width??14).attr("height",t.height??14);if(t.width<25&&a&&t.look!=="handDrawn"){const h=((l=(n=e.node())==null?void 0:n.ownerSVGElement)==null?void 0:l.id)??"",c=h?`${h}-drop-shadow-small`:"drop-shadow-small";o.attr("style",`filter:url(#${c})`)}return rt(t,o),t.intersect=function(h){return V.circle(t,(t.width??7)/2,h)},s}y(gy,"stateStart");var ni=8;async function my(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=(t==null?void 0:t.padding)??8,s=t.look==="neo"?28:a,o=t.look==="neo"?12:a,{shapeSvg:n,bbox:l}=await nt(e,t,ot(t)),h=((t==null?void 0:t.width)??l.width)+2*ni+s,c=((t==null?void 0:t.height)??l.height)+o,u=h-2*ni,f=c,d=-h/2,p=-c/2,g=[{x:0,y:0},{x:u,y:0},{x:u,y:-f},{x:0,y:-f},{x:0,y:0},{x:-8,y:0},{x:u+8,y:0},{x:u+8,y:-f},{x:-8,y:-f},{x:-8,y:0}];if(t.look==="handDrawn"){const m=K.svg(n),C=J(t,{}),x=m.rectangle(d,p,u+16,f,C),k=m.line(d+ni,p,d+ni,p+f,C),w=m.line(d+ni+u,p,d+ni+u,p+f,C);n.insert(()=>k,":first-child"),n.insert(()=>w,":first-child");const S=n.insert(()=>x,":first-child"),{cssStyles:_}=t;S.attr("class","basic label-container").attr("style",Ht(_)),rt(t,S)}else{const m=fr(n,u,f,g);i&&m.attr("style",i),rt(t,m)}return t.intersect=function(m){return V.polygon(t,g,m)},n}y(my,"subroutine");var Vn=.2;async function yy(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?16:a,o=t.look==="neo"?12:a;(t.width||t.height)&&(t.height=Math.max(((t==null?void 0:t.height)??0)-o*2,10),t.width=Math.max(((t==null?void 0:t.width)??0)-s*2-Vn*(t.height+o*2),10));const{shapeSvg:n,bbox:l}=await nt(e,t,ot(t)),h=(t!=null&&t.height?t==null?void 0:t.height:l.height)+o*2,c=Vn*h,u=Vn*h,d=(t!=null&&t.width?t==null?void 0:t.width:l.width)+s*2+c-c,p=h,g=-d/2,m=-p/2,{cssStyles:C}=t,x=K.svg(n),k=J(t,{}),w=[{x:g-c/2,y:m},{x:g+d+c/2,y:m},{x:g+d+c/2,y:m+p},{x:g-c/2,y:m+p}],S=[{x:g+d-c/2,y:m+p},{x:g+d+c/2,y:m+p},{x:g+d+c/2,y:m+p-u}];t.look!=="handDrawn"&&(k.roughness=0,k.fillStyle="solid");const _=yt(w),T=x.path(_,k),B=yt(S),z=x.path(B,{...k,fillStyle:"solid"}),I=n.insert(()=>z,":first-child");return I.insert(()=>T,":first-child"),I.attr("class","basic label-container outer-path"),C&&t.look!=="handDrawn"&&I.selectAll("path").attr("style",C),i&&t.look!=="handDrawn"&&I.selectAll("path").attr("style",i),rt(t,I),t.intersect=function(E){return V.polygon(t,w,E)},n}y(yy,"taggedRect");async function Cy(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const{shapeSvg:a,bbox:s,label:o}=await nt(e,t,ot(t)),n=Math.max(s.width+(t.padding??0)*2,(t==null?void 0:t.width)??0),l=Math.max(s.height+(t.padding??0)*2,(t==null?void 0:t.height)??0),h=l/8,c=.2*n,u=.2*l,f=l+h,{cssStyles:d}=t,p=K.svg(a),g=J(t,{});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const m=[{x:-n/2-n/2*.1,y:f/2},...Tr(-n/2-n/2*.1,f/2,n/2+n/2*.1,f/2,h,.8),{x:n/2+n/2*.1,y:-f/2},{x:-n/2-n/2*.1,y:-f/2}],C=-n/2+n/2*.1,x=-f/2-u*.4,k=[{x:C+n-c,y:(x+l)*1.3},{x:C+n,y:x+l-u},{x:C+n,y:(x+l)*.9},...Tr(C+n,(x+l)*1.25,C+n-c,(x+l)*1.3,-l*.02,.5)],w=yt(m),S=p.path(w,g),_=yt(k),T=p.path(_,{...g,fillStyle:"solid"}),B=a.insert(()=>T,":first-child");return B.insert(()=>S,":first-child"),B.attr("class","basic label-container outer-path"),d&&t.look!=="handDrawn"&&B.selectAll("path").attr("style",d),i&&t.look!=="handDrawn"&&B.selectAll("path").attr("style",i),B.attr("transform",`translate(0,${-h/2})`),o.attr("transform",`translate(${-n/2+(t.padding??0)-(s.x-(s.left??0))},${-l/2+(t.padding??0)-h/2-(s.y-(s.top??0))})`),rt(t,B),t.intersect=function(z){return V.polygon(t,m,z)},a}y(Cy,"taggedWaveEdgedRectangle");async function xy(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const{shapeSvg:a,bbox:s}=await nt(e,t,ot(t)),o=Math.max(s.width+(t.padding??0),(t==null?void 0:t.width)||0),n=Math.max(s.height+(t.padding??0),(t==null?void 0:t.height)||0),l=-o/2,h=-n/2,c=a.insert("rect",":first-child");return c.attr("class","text").attr("style",i).attr("rx",0).attr("ry",0).attr("x",l).attr("y",h).attr("width",o).attr("height",n),rt(t,c),t.intersect=function(u){return V.rect(t,u)},a}y(xy,"text");var oA=y((e,t,r,i,a,s)=>`M${e},${t}
230
+ a${a},${s} 0,0,1 0,${-i}
231
+ l${r},0
232
+ a${a},${s} 0,0,1 0,${i}
233
+ M${r},${-i}
234
+ a${a},${s} 0,0,0 0,${i}
235
+ l${-r},0`,"createCylinderPathD"),nA=y((e,t,r,i,a,s)=>[`M${e},${t}`,`M${e+r},${t}`,`a${a},${s} 0,0,0 0,${-i}`,`l${-r},0`,`a${a},${s} 0,0,0 0,${i}`,`l${r},0`].join(" "),"createOuterCylinderPathD"),lA=y((e,t,r,i,a,s)=>[`M${e+r/2},${-i/2}`,`a${a},${s} 0,0,0 0,${i}`].join(" "),"createInnerCylinderPathD"),wd=5,_d=10;async function by(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?12:a/2;if(t.width||t.height){const g=t.height??0;t.height=(t.height??0)-s,t.height<wd&&(t.height=wd);const C=g/2/(2.5+g/50);t.width=(t.width??0)-s-C*3,t.width<_d&&(t.width=_d)}const{shapeSvg:o,bbox:n,label:l}=await nt(e,t,ot(t)),h=(t.height?t.height:n.height)+s,c=h/2,u=c/(2.5+h/50),f=(t.width?t.width:n.width)+u+s,{cssStyles:d}=t;let p;if(t.look==="handDrawn"){const g=K.svg(o),m=nA(0,0,f,h,u,c),C=lA(0,0,f,h,u,c),x=g.path(m,J(t,{})),k=g.path(C,J(t,{fill:"none"}));p=o.insert(()=>k,":first-child"),p=o.insert(()=>x,":first-child"),p.attr("class","basic label-container"),d&&p.attr("style",d)}else{const g=oA(0,0,f,h,u,c);p=o.insert("path",":first-child").attr("d",g).attr("class","basic label-container").attr("style",Ht(d)).attr("style",i),p.attr("class","basic label-container outer-path"),d&&p.selectAll("path").attr("style",d),i&&p.selectAll("path").attr("style",i)}return p.attr("label-offset-x",u),p.attr("transform",`translate(${-f/2}, ${h/2} )`),l.attr("transform",`translate(${-(n.width/2)-u-(n.x-(n.left??0))}, ${-(n.height/2)-(n.y-(n.top??0))})`),rt(t,p),t.intersect=function(g){const m=V.rect(t,g),C=m.y-(t.y??0);if(c!=0&&(Math.abs(C)<(t.height??0)/2||Math.abs(C)==(t.height??0)/2&&Math.abs(m.x-(t.x??0))>(t.width??0)/2-u)){let x=u*u*(1-C*C/(c*c));x!=0&&(x=Math.sqrt(Math.abs(x))),x=u-x,g.x-(t.x??0)>0&&(x=-x),m.x+=x}return m},o}y(by,"tiltedCylinder");async function ky(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=(t.look==="neo",a),o=t.look==="neo"?a*2:a,{shapeSvg:n,bbox:l}=await nt(e,t,ot(t)),h=((t==null?void 0:t.height)??l.height)+s,c=((t==null?void 0:t.width)??l.width)+o,u=[{x:-3*h/6,y:0},{x:c+3*h/6,y:0},{x:c,y:-h},{x:0,y:-h}];let f;const{cssStyles:d}=t;if(t.look==="handDrawn"){const p=K.svg(n),g=J(t,{}),m=yt(u),C=p.path(m,g);f=n.insert(()=>C,":first-child").attr("transform",`translate(${-c/2}, ${h/2})`),d&&f.attr("style",d)}else f=fr(n,c,h,u);return i&&f.attr("style",i),t.width=c,t.height=h,rt(t,f),t.intersect=function(p){return V.polygon(t,u,p)},n}y(ky,"trapezoid");async function Ty(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?16:a,o=t.look==="neo"?12:a,n=15,l=5;(t.width||t.height)&&(t.height=(t.height??0)-o*2,t.height<l&&(t.height=l),t.width=(t.width??0)-s*2,t.width<n&&(t.width=n));const{shapeSvg:h,bbox:c}=await nt(e,t,ot(t)),u=(t!=null&&t.width?t==null?void 0:t.width:c.width)+s*2,f=(t!=null&&t.height?t==null?void 0:t.height:c.height)+o*2,{cssStyles:d}=t,p=K.svg(h),g=J(t,{});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const m=[{x:-u/2*.8,y:-f/2},{x:u/2*.8,y:-f/2},{x:u/2,y:-f/2*.6},{x:u/2,y:f/2},{x:-u/2,y:f/2},{x:-u/2,y:-f/2*.6}],C=yt(m),x=p.path(C,g),k=h.insert(()=>x,":first-child");return k.attr("class","basic label-container outer-path"),d&&t.look!=="handDrawn"&&k.selectChildren("path").attr("style",d),i&&t.look!=="handDrawn"&&k.selectChildren("path").attr("style",i),rt(t,k),t.intersect=function(w){return V.polygon(t,m,w)},h}y(Ty,"trapezoidalPentagon");var Sd=10,vd=10;async function wy(e,t){var w;const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?a*2:a;(t.width||t.height)&&(t.width=(((t==null?void 0:t.width)??0)-s)/2,t.width<vd&&(t.width=vd),t.height=(t==null?void 0:t.height)??0,t.height<Sd&&(t.height=Sd));const{shapeSvg:o,bbox:n,label:l}=await nt(e,t,ot(t)),h=cr((w=bt().flowchart)==null?void 0:w.htmlLabels),c=(t!=null&&t.width?t==null?void 0:t.width:n.width)+s,u=t!=null&&t.height?t==null?void 0:t.height:c+n.height,f=u,d=[{x:0,y:0},{x:f,y:0},{x:f/2,y:-u}],{cssStyles:p}=t,g=K.svg(o),m=J(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const C=yt(d),x=g.path(C,m),k=o.insert(()=>x,":first-child").attr("transform",`translate(${-u/2}, ${u/2})`).attr("class","outer-path");return p&&t.look!=="handDrawn"&&k.selectChildren("path").attr("style",p),i&&t.look!=="handDrawn"&&k.selectChildren("path").attr("style",i),t.width=c,t.height=u,rt(t,k),l.attr("transform",`translate(${-n.width/2-(n.x-(n.left??0))}, ${u/2-(n.height+(t.padding??0)/(h?2:1)-(n.y-(n.top??0)))})`),t.intersect=function(S){return W.info("Triangle intersect",t,d,S),V.polygon(t,d,S)},o}y(wy,"triangle");async function _y(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?16:a,o=t.look==="neo"?12:a;let n=!0;(t.width||t.height)&&(n=!1,t.width=((t==null?void 0:t.width)??0)-s*2,t.width<10&&(t.width=10),t.height=((t==null?void 0:t.height)??0)-o*2,t.height<10&&(t.height=10));const{shapeSvg:l,bbox:h,label:c}=await nt(e,t,ot(t)),u=(t!=null&&t.width?t==null?void 0:t.width:h.width)+(s??0)*2,f=(t!=null&&t.height?t==null?void 0:t.height:h.height)+(o??0)*2,d=t.look==="neo"?f/4:f/8,p=f+(n?d:-d),{cssStyles:g}=t,C=14-u,x=C>0?C/2:0,k=K.svg(l),w=J(t,{});t.look!=="handDrawn"&&(w.roughness=0,w.fillStyle="solid");const S=[{x:-u/2-x,y:p/2},...Tr(-u/2-x,p/2,u/2+x,p/2,d,.8),{x:u/2+x,y:-p/2},{x:-u/2-x,y:-p/2}],_=yt(S),T=k.path(_,w),B=l.insert(()=>T,":first-child");return B.attr("class","basic label-container outer-path"),g&&t.look!=="handDrawn"&&B.selectAll("path").attr("style",g),i&&t.look!=="handDrawn"&&B.selectAll("path").attr("style",i),B.attr("transform",`translate(0,${-d/2})`),c.attr("transform",`translate(${-u/2+(t.padding??0)-(h.x-(h.left??0))},${-f/2+(t.padding??0)-d-(h.y-(h.top??0))})`),rt(t,B),t.intersect=function(z){return V.polygon(t,S,z)},l}y(_y,"waveEdgedRectangle");async function Sy(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.padding??0,s=t.look==="neo"?16:a,o=t.look==="neo"?20:a;if(t.width||t.height){t.width=(t==null?void 0:t.width)??0,t.width<20&&(t.width=20),t.height=(t==null?void 0:t.height)??0,t.height<10&&(t.height=10);const w=Math.min(t.height*.2,t.height/4);t.height=Math.ceil(t.height-o-w*(20/9)),t.width=t.width-s*2}const{shapeSvg:n,bbox:l}=await nt(e,t,ot(t)),h=(t!=null&&t.width?t==null?void 0:t.width:l.width)+s*2,c=(t!=null&&t.height?t==null?void 0:t.height:l.height)+o,u=c/8,f=c+u*2,{cssStyles:d}=t,p=K.svg(n),g=J(t,{});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const m=[{x:-h/2,y:f/2},...Tr(-h/2,f/2,h/2,f/2,u,1),{x:h/2,y:-f/2},...Tr(h/2,-f/2,-h/2,-f/2,u,-1)],C=yt(m),x=p.path(C,g),k=n.insert(()=>x,":first-child");return k.attr("class","basic label-container"),d&&t.look!=="handDrawn"&&k.selectAll("path").attr("style",d),i&&t.look!=="handDrawn"&&k.selectAll("path").attr("style",i),rt(t,k),t.intersect=function(w){return V.polygon(t,m,w)},n}y(Sy,"waveRectangle");var Et=10;async function vy(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t.look==="neo"?16:t.padding??0,s=t.look==="neo"?12:t.padding??0;(t.width||t.height)&&(t.width=Math.max(((t==null?void 0:t.width)??0)-a*2-Et,10),t.height=Math.max(((t==null?void 0:t.height)??0)-s*2-Et,10));const{shapeSvg:o,bbox:n,label:l}=await nt(e,t,ot(t)),h=(t!=null&&t.width?t==null?void 0:t.width:n.width)+a*2+Et,c=(t!=null&&t.height?t==null?void 0:t.height:n.height)+s*2+Et,u=h-Et,f=c-Et,d=-u/2,p=-f/2,{cssStyles:g}=t,m=K.svg(o),C=J(t,{}),x=[{x:d-Et,y:p-Et},{x:d-Et,y:p+f},{x:d+u,y:p+f},{x:d+u,y:p-Et}],k=`M${d-Et},${p-Et} L${d+u},${p-Et} L${d+u},${p+f} L${d-Et},${p+f} L${d-Et},${p-Et}
236
+ M${d-Et},${p} L${d+u},${p}
237
+ M${d},${p-Et} L${d},${p+f}`;t.look!=="handDrawn"&&(C.roughness=0,C.fillStyle="solid");const w=m.path(k,C),S=o.insert(()=>w,":first-child");return S.attr("transform",`translate(${Et/2}, ${Et/2})`),S.attr("class","basic label-container outer-path"),g&&t.look!=="handDrawn"&&S.selectAll("path").attr("style",g),i&&t.look!=="handDrawn"&&S.selectAll("path").attr("style",i),l.attr("transform",`translate(${-(n.width/2)+Et/2-(n.x-(n.left??0))}, ${-(n.height/2)+Et/2-(n.y-(n.top??0))})`),rt(t,S),t.intersect=function(_){return V.polygon(t,x,_)},o}y(vy,"windowPane");var Bd=new Set(["redux-color","redux-dark-color"]),hA=new Set(["redux","redux-dark","redux-color","redux-dark-color"]);async function nc(e,t){var xt,vt,Bt,X;const r=t;r.alias&&(t.label=r.alias);const{theme:i,themeVariables:a}=At(),{rowEven:s,rowOdd:o,nodeBorder:n,borderColorArray:l}=a;if(t.look==="handDrawn"){const{themeVariables:U}=At(),{background:G}=U,q={...t,id:t.id+"-background",domId:(t.domId||t.id)+"-background",look:"default",cssStyles:["stroke: none",`fill: ${G}`]};await nc(e,q)}const h=At();t.useHtmlLabels=h.htmlLabels;let c=((xt=h.er)==null?void 0:xt.diagramPadding)??10,u=((vt=h.er)==null?void 0:vt.entityPadding)??6;const{cssStyles:f}=t,{labelStyles:d,nodeStyles:p}=tt(t);if(r.attributes.length===0&&t.label){const U={rx:0,ry:0,labelPaddingX:c,labelPaddingY:c*1.5};hr(t.label,h)+U.labelPaddingX*2<h.er.minEntityWidth&&(t.width=h.er.minEntityWidth);const G=await es(e,t,U);if(i!=null&&Bd.has(i)){const q=r.colorIndex??0;G.attr("data-color-id",`color-${q%l.length}`)}if(!cr(h.htmlLabels)){const q=G.select("text"),ft=(Bt=q.node())==null?void 0:Bt.getBBox();q.attr("transform",`translate(${-ft.width/2}, 0)`)}return G}h.htmlLabels||(c*=1.25,u*=1.25);let g=ot(t);g||(g="node default");const m=e.insert("g").attr("class",g).attr("id",t.domId||t.id),C=await hi(m,t.label??"",h,0,0,["name"],d);C.height+=u;let x=0;const k=[],w=[];let S=0,_=0,T=0,B=0,z=!0,I=!0;for(const U of r.attributes){const G=await hi(m,U.type,h,0,x,["attribute-type"],d);S=Math.max(S,G.width+c);const q=await hi(m,U.name,h,0,x,["attribute-name"],d);_=Math.max(_,q.width+c);const ft=await hi(m,U.keys.join(),h,0,x,["attribute-keys"],d);T=Math.max(T,ft.width+c);const gt=await hi(m,U.comment,h,0,x,["attribute-comment"],d);B=Math.max(B,gt.width+c);const wt=Math.max(G.height,q.height,ft.height,gt.height)+u;w.push({yOffset:x,rowHeight:wt}),x+=wt}let E=4;T<=c&&(z=!1,T=0,E--),B<=c&&(I=!1,B=0,E--);const N=m.node().getBBox();if(C.width+c*2-(S+_+T+B)>0){const U=C.width+c*2-(S+_+T+B);S+=U/E,_+=U/E,T>0&&(T+=U/E),B>0&&(B+=U/E)}const D=S+_+T+B,M=K.svg(m),$=J(t,{});t.look!=="handDrawn"&&($.roughness=0,$.fillStyle="solid");let A=0;w.length>0&&(A=w.reduce((U,G)=>U+((G==null?void 0:G.rowHeight)??0),0));const O=Math.max(N.width+c*2,(t==null?void 0:t.width)||0,D),F=Math.max((A??0)+C.height,(t==null?void 0:t.height)||0),H=-O/2,Y=-F/2;if(m.selectAll("g:not(:first-child)").each((U,G,q)=>{const ft=pt(q[G]),gt=ft.attr("transform");let wt=0,Ot=0;if(gt){const de=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(gt);de&&(wt=parseFloat(de[1]),Ot=parseFloat(de[2]),ft.attr("class").includes("attribute-name")?wt+=S:ft.attr("class").includes("attribute-keys")?wt+=S+_:ft.attr("class").includes("attribute-comment")&&(wt+=S+_+T))}ft.attr("transform",`translate(${H+c/2+wt}, ${Ot+Y+C.height+u/2})`)}),m.select(".name").attr("transform","translate("+-C.width/2+", "+(Y+u/2)+")"),i!=null&&Bd.has(i)){const U=r.colorIndex??0;m.attr("data-color-id",`color-${U%l.length}`)}const Z=M.rectangle(H,Y,O,F,$),ut=m.insert(()=>Z,":first-child").attr("class","outer-path").attr("style",f.join(""));k.push(0);for(const[U,G]of w.entries()){const ft=(U+1)%2===0&&G.yOffset!==0,gt=M.rectangle(H,C.height+Y+(G==null?void 0:G.yOffset),O,G==null?void 0:G.rowHeight,{...$,fill:ft?s:o,stroke:n});m.insert(()=>gt,"g.label").attr("style",f.join("")).attr("class",`row-rect-${ft?"even":"odd"}`)}const at=1e-4;let dt=ci(H,C.height+Y,O+H,C.height+Y,at),Q=M.polygon(dt.map(U=>[U.x,U.y]),$);if(m.insert(()=>Q).attr("class","divider"),dt=ci(S+H,C.height+Y,S+H,F+Y,at),Q=M.polygon(dt.map(U=>[U.x,U.y]),$),m.insert(()=>Q).attr("class","divider"),z){const U=S+_+H;dt=ci(U,C.height+Y,U,F+Y,at),Q=M.polygon(dt.map(G=>[G.x,G.y]),$),m.insert(()=>Q).attr("class","divider")}if(I){const U=S+_+T+H;dt=ci(U,C.height+Y,U,F+Y,at),Q=M.polygon(dt.map(G=>[G.x,G.y]),$),m.insert(()=>Q).attr("class","divider")}for(const U of k){const G=C.height+Y+U;dt=ci(H,G,O+H,G,at),Q=M.polygon(dt.map(q=>[q.x,q.y]),$),m.insert(()=>Q).attr("class","divider")}if(rt(t,ut),p&&t.look!=="handDrawn")if(i!=null&&hA.has(i))m.selectAll("path").attr("style",p);else{const U=p.split(";"),G=(X=U==null?void 0:U.filter(q=>q.includes("stroke")))==null?void 0:X.map(q=>`${q}`).join("; ");m.selectAll("path").attr("style",G??""),m.selectAll(".row-rect-even path").attr("style",p)}return t.intersect=function(U){return V.rect(t,U)},m}y(nc,"erBox");async function hi(e,t,r,i=0,a=0,s=[],o=""){const n=e.insert("g").attr("class",`label ${s.join(" ")}`).attr("transform",`translate(${i}, ${a})`).attr("style",o);t!==zc(t)&&(t=zc(t),t=t.replaceAll("<","&lt;").replaceAll(">","&gt;"));const l=n.node().appendChild(await dr(n,t,{width:hr(t,r)+100,style:o,useHtmlLabels:r.htmlLabels},r));if(t.includes("&lt;")||t.includes("&gt;")){let c=l.children[0];for(c.textContent=c.textContent.replaceAll("&lt;","<").replaceAll("&gt;",">");c.childNodes[0];)c=c.childNodes[0],c.textContent=c.textContent.replaceAll("&lt;","<").replaceAll("&gt;",">")}let h=l.getBBox();if(cr(r.htmlLabels)){const c=l.children[0];c.style.textAlign="start";const u=pt(l);h=c.getBoundingClientRect(),u.attr("width",h.width),u.attr("height",h.height)}return h}y(hi,"addText");function ci(e,t,r,i,a){return e===r?[{x:e-a/2,y:t},{x:e+a/2,y:t},{x:r+a/2,y:i},{x:r-a/2,y:i}]:[{x:e,y:t-a/2},{x:e,y:t+a/2},{x:r,y:i+a/2},{x:r,y:i-a/2}]}y(ci,"lineToPolygon");async function By(e,t,r,i,a=r.class.padding??12){const s=i?0:3,o=e.insert("g").attr("class",ot(t)).attr("id",t.domId||t.id);let n=null,l=null,h=null,c=null,u=0,f=0,d=0;if(n=o.insert("g").attr("class","annotation-group text"),t.annotations.length>0){const x=t.annotations[0];await ka(n,{text:`«${x}»`},0),u=n.node().getBBox().height}l=o.insert("g").attr("class","label-group text"),await ka(l,t,0,["font-weight: bolder"]);const p=l.node().getBBox();f=p.height,h=o.insert("g").attr("class","members-group text");let g=0;for(const x of t.members){const k=await ka(h,x,g,[x.parseClassifier()]);g+=k+s}d=h.node().getBBox().height,d<=0&&(d=a/2),c=o.insert("g").attr("class","methods-group text");let m=0;for(const x of t.methods){const k=await ka(c,x,m,[x.parseClassifier()]);m+=k+s}let C=o.node().getBBox();if(n!==null){const x=n.node().getBBox();n.attr("transform",`translate(${-x.width/2})`)}return l.attr("transform",`translate(${-p.width/2}, ${u})`),C=o.node().getBBox(),h.attr("transform",`translate(0, ${u+f+a*2})`),C=o.node().getBBox(),c.attr("transform",`translate(0, ${u+f+(d?d+a*4:a*2)})`),C=o.node().getBBox(),{shapeSvg:o,bbox:C}}y(By,"textHelper");async function ka(e,t,r,i=[]){const a=e.insert("g").attr("class","label").attr("style",i.join("; ")),s=At();let o="useHtmlLabels"in t?t.useHtmlLabels:cr(s.htmlLabels)??!0,n="";"text"in t?n=t.text:n=t.label,!o&&n.startsWith("\\")&&(n=n.substring(1)),Ma(n)&&(o=!0);const l=await dr(a,uh(Yr(n)),{width:hr(n,s)+50,classes:"markdown-node-label",useHtmlLabels:o},s);let h,c=1;if(o){const u=l.children[0],f=pt(l);c=u.innerHTML.split("<br>").length,u.innerHTML.includes("</math>")&&(c+=u.innerHTML.split("<mrow>").length-1);const d=u.getElementsByTagName("img");if(d){const p=n.replace(/<img[^>]*>/g,"").trim()==="";await Promise.all([...d].map(g=>new Promise(m=>{function C(){var x;if(g.style.display="flex",g.style.flexDirection="column",p){const k=((x=s.fontSize)==null?void 0:x.toString())??window.getComputedStyle(document.body).fontSize,S=parseInt(k,10)*5+"px";g.style.minWidth=S,g.style.maxWidth=S}else g.style.width="100%";m(g)}y(C,"setupImage"),setTimeout(()=>{g.complete&&C()}),g.addEventListener("error",C),g.addEventListener("load",C)})))}h=u.getBoundingClientRect(),f.attr("width",h.width),f.attr("height",h.height)}else{i.includes("font-weight: bolder")&&pt(l).selectAll("tspan").attr("font-weight",""),c=l.children.length;const u=l.children[0];(l.textContent===""||l.textContent.includes("&gt"))&&(u.textContent=n[0]+n.substring(1).replaceAll("&gt;",">").replaceAll("&lt;","<").trim(),n[1]===" "&&(u.textContent=u.textContent[0]+" "+u.textContent.substring(1))),u.textContent==="undefined"&&(u.textContent=""),h=l.getBBox()}return a.attr("transform","translate(0,"+(-h.height/(2*c)+r)+")"),h.height}y(ka,"addText");async function Ly(e,t){var M,$;const r=bt(),{themeVariables:i}=r,{useGradient:a}=i,s=r.class.padding??12,o=s,n=t.useHtmlLabels??cr(r.htmlLabels)??!0,l=t;l.annotations=l.annotations??[],l.members=l.members??[],l.methods=l.methods??[];const{shapeSvg:h,bbox:c}=await By(e,t,r,n,o),{labelStyles:u,nodeStyles:f}=tt(t);t.labelStyle=u,t.cssStyles=l.styles||"";const d=((M=l.styles)==null?void 0:M.join(";"))||f||"";t.cssStyles||(t.cssStyles=d.replaceAll("!important","").split(";"));const p=l.members.length===0&&l.methods.length===0&&!(($=r.class)!=null&&$.hideEmptyMembersBox),g=K.svg(h),m=J(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const C=Math.max(t.width??0,c.width);let x=Math.max(t.height??0,c.height);const k=(t.height??0)>c.height;l.members.length===0&&l.methods.length===0?x+=o:l.members.length>0&&l.methods.length===0&&(x+=o*2);const w=-C/2,S=-x/2;let _=p?s*2:l.members.length===0&&l.methods.length===0?-s:0;k&&(_=s*2);const T=g.rectangle(w-s,S-s-(p?s:l.members.length===0&&l.methods.length===0?-s/2:0),C+2*s,x+2*s+_,m),B=h.insert(()=>T,":first-child");B.attr("class","basic label-container outer-path");const z=B.node().getBBox(),I=h.select(".annotation-group").node().getBBox().height-(p?s/2:0)||0,E=h.select(".label-group").node().getBBox().height-(p?s/2:0)||0,N=h.select(".members-group").node().getBBox().height-(p?s/2:0)||0,D=(I+E+S+s-(S-s-(p?s:l.members.length===0&&l.methods.length===0?-s/2:0)))/2;if(h.selectAll(".text").each((A,O,F)=>{var dt,Q;const H=pt(F[O]),Y=H.attr("transform");let Z=0;if(Y){const vt=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(Y);vt&&(Z=parseFloat(vt[2]))}let ut=Z+S+s-(p?s:l.members.length===0&&l.methods.length===0?-s/2:0);if(H.attr("class").includes("methods-group")){const xt=Math.max(N,o/2);k?ut=Math.max(D,I+E+xt+S+o*2+s)+o*2:ut=I+E+xt+S+o*4+s}l.members.length===0&&l.methods.length===0&&((dt=r.class)!=null&&dt.hideEmptyMembersBox)&&(l.annotations.length>0?ut=Z-o:ut=Z),n||(ut-=4);let at=w;(H.attr("class").includes("label-group")||H.attr("class").includes("annotation-group"))&&(at=-((Q=H.node())==null?void 0:Q.getBBox().width)/2||0,h.selectAll("text").each(function(xt,vt,Bt){window.getComputedStyle(Bt[vt]).textAnchor==="middle"&&(at=0)})),H.attr("transform",`translate(${at}, ${ut})`)}),l.members.length>0||l.methods.length>0||p){const A=I+E+S+s,O=g.line(z.x,A,z.x+z.width,A+.001,m);h.insert(()=>O).attr("class",`divider${t.look==="neo"&&!a?" neo-line":""}`).attr("style",d)}if(p||l.members.length>0||l.methods.length>0){const A=I+E+N+S+o*2+s,O=g.line(z.x,k?Math.max(D,A):A,z.x+z.width,(k?Math.max(D,A):A)+.001,m);h.insert(()=>O).attr("class",`divider${t.look==="neo"&&!a?" neo-line":""}`).attr("style",d)}if(l.look!=="handDrawn"&&h.selectAll("path").attr("style",d),B.select(":nth-child(2)").attr("style",d),h.selectAll(".divider").select("path").attr("style",d),t.labelStyle?h.selectAll("span").attr("style",t.labelStyle):h.selectAll("span").attr("style",d),!n){const A=RegExp(/color\s*:\s*([^;]*)/),O=A.exec(d);if(O){const F=O[0].replace("color","fill");h.selectAll("tspan").attr("style",F)}else if(u){const F=A.exec(u);if(F){const H=F[0].replace("color","fill");h.selectAll("tspan").attr("style",H)}}}return rt(t,B),t.intersect=function(A){return V.rect(t,A)},h}y(Ly,"classBox");async function Fy(e,t){var z,I;const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const a=t,s=t,o=20,n=20,l="verifyMethod"in t,h=ot(t),{themeVariables:c}=bt(),{borderColorArray:u,requirementEdgeLabelBackground:f}=c,d=e.insert("g").attr("class",h).attr("id",t.domId??t.id);let p;l?p=await Ne(d,`&lt;&lt;${a.type}&gt;&gt;`,0,t.labelStyle):p=await Ne(d,"&lt;&lt;Element&gt;&gt;",0,t.labelStyle);let g=p;const m=await Ne(d,a.name,g,t.labelStyle+"; font-weight: bold;");if(g+=m+n,l){const E=await Ne(d,`${a.requirementId?`ID: ${a.requirementId}`:""}`,g,t.labelStyle);g+=E;const N=await Ne(d,`${a.text?`Text: ${a.text}`:""}`,g,t.labelStyle);g+=N;const D=await Ne(d,`${a.risk?`Risk: ${a.risk}`:""}`,g,t.labelStyle);g+=D,await Ne(d,`${a.verifyMethod?`Verification: ${a.verifyMethod}`:""}`,g,t.labelStyle)}else{const E=await Ne(d,`${s.type?`Type: ${s.type}`:""}`,g,t.labelStyle);g+=E,await Ne(d,`${s.docRef?`Doc Ref: ${s.docRef}`:""}`,g,t.labelStyle)}const C=(((z=d.node())==null?void 0:z.getBBox().width)??200)+o,x=(((I=d.node())==null?void 0:I.getBBox().height)??200)+o,k=-C/2,w=-x/2,S=K.svg(d),_=J(t,{});t.look!=="handDrawn"&&(_.roughness=0,_.fillStyle="solid");const T=S.rectangle(k,w,C,x,_),B=d.insert(()=>T,":first-child");if(B.attr("class","basic label-container outer-path").attr("style",i),u!=null&&u.length){const E=t.colorIndex??0;d.attr("data-color-id",`color-${E%u.length}`)}if(d.selectAll(".label").each((E,N,D)=>{const M=pt(D[N]),$=M.attr("transform");let A=0,O=0;if($){const Z=RegExp(/translate\(([^,]+),([^)]+)\)/).exec($);Z&&(A=parseFloat(Z[1]),O=parseFloat(Z[2]))}const F=O-x/2;let H=k+o/2;(N===0||N===1)&&(H=A),M.attr("transform",`translate(${H}, ${F+o})`)}),g>p+m+n){const E=w+p+m+n;let N;if(t.look==="neo"){const $=[[k,E],[k+C,E],[k+C,E+.001],[k,E+.001]];N=S.polygon($,_)}else N=S.line(k,E,k+C,E,_);d.insert(()=>N).attr("class","divider")}return rt(t,B),t.intersect=function(E){return V.rect(t,E)},i&&t.look!=="handDrawn"&&(f||u!=null&&u.length)&&d.selectAll("path").attr("style",i),d}y(Fy,"requirementBox");async function Ne(e,t,r,i=""){if(t==="")return 0;const a=e.insert("g").attr("class","label").attr("style",i),s=bt(),o=s.htmlLabels??!0,n=await dr(a,uh(Yr(t)),{width:hr(t,s)+50,classes:"markdown-node-label",useHtmlLabels:o,style:i},s);let l;if(o){const h=n.children[0],c=pt(n);l=h.getBoundingClientRect(),c.attr("width",l.width),c.attr("height",l.height)}else{const h=n.children[0];for(const c of h.children)i&&c.setAttribute("style",i);l=n.getBBox(),l.height+=6}return a.attr("transform",`translate(${-l.width/2},${-l.height/2+r})`),l.height}y(Ne,"addText");var cA=y(e=>{switch(e){case"Very High":return"red";case"High":return"orange";case"Medium":return null;case"Low":return"blue";case"Very Low":return"lightblue"}},"colorFromPriority");async function My(e,t,{config:r}){var N,D;const{labelStyles:i,nodeStyles:a}=tt(t);t.labelStyle=i||"";const s=10,o=t.width;t.width=(t.width??200)-10;const{shapeSvg:n,bbox:l,label:h}=await nt(e,t,ot(t)),c=t.padding||10;let u="",f;"ticket"in t&&t.ticket&&((N=r==null?void 0:r.kanban)!=null&&N.ticketBaseUrl)&&(u=(D=r==null?void 0:r.kanban)==null?void 0:D.ticketBaseUrl.replace("#TICKET#",t.ticket),f=n.insert("svg:a",":first-child").attr("class","kanban-ticket-link").attr("xlink:href",u).attr("target","_blank"));const d={useHtmlLabels:t.useHtmlLabels,labelStyle:t.labelStyle||"",width:t.width,img:t.img,padding:t.padding||8,centerLabel:!1};let p,g;f?{label:p,bbox:g}=await Xn(f,"ticket"in t&&t.ticket||"",d):{label:p,bbox:g}=await Xn(n,"ticket"in t&&t.ticket||"",d);const{label:m,bbox:C}=await Xn(n,"assigned"in t&&t.assigned||"",d);t.width=o;const x=10,k=(t==null?void 0:t.width)||0,w=Math.max(g.height,C.height)/2,S=Math.max(l.height+x*2,(t==null?void 0:t.height)||0)+w,_=-k/2,T=-S/2;h.attr("transform","translate("+(c-k/2)+", "+(-w-l.height/2)+")"),p.attr("transform","translate("+(c-k/2)+", "+(-w+l.height/2)+")"),m.attr("transform","translate("+(c+k/2-C.width-2*s)+", "+(-w+l.height/2)+")");let B;const{rx:z,ry:I}=t,{cssStyles:E}=t;if(t.look==="handDrawn"){const M=K.svg(n),$=J(t,{}),A=z||I?M.path(_r(_,T,k,S,z||0),$):M.rectangle(_,T,k,S,$);B=n.insert(()=>A,":first-child"),B.attr("class","basic label-container").attr("style",E||null)}else{B=n.insert("rect",":first-child"),B.attr("class","basic label-container __APA__").attr("style",a).attr("rx",z??5).attr("ry",I??5).attr("x",_).attr("y",T).attr("width",k).attr("height",S);const M="priority"in t&&t.priority;if(M){const $=n.append("line"),A=_+2,O=T+Math.floor((z??0)/2),F=T+S-Math.floor((z??0)/2);$.attr("x1",A).attr("y1",O).attr("x2",A).attr("y2",F).attr("stroke-width","4").attr("stroke",cA(M))}}return rt(t,B),t.height=S,t.intersect=function(M){return V.rect(t,M)},n}y(My,"kanbanItem");async function Ay(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const{shapeSvg:a,bbox:s,halfPadding:o,label:n}=await nt(e,t,ot(t)),l=s.width+10*o,h=s.height+8*o,c=.15*l,{cssStyles:u}=t,f=s.width+20,d=s.height+20,p=Math.max(l,f),g=Math.max(h,d);n.attr("transform",`translate(${-s.width/2}, ${-s.height/2})`);let m;const C=`M0 0
238
+ a${c},${c} 1 0,0 ${p*.25},${-1*g*.1}
239
+ a${c},${c} 1 0,0 ${p*.25},0
240
+ a${c},${c} 1 0,0 ${p*.25},0
241
+ a${c},${c} 1 0,0 ${p*.25},${g*.1}
242
+
243
+ a${c},${c} 1 0,0 ${p*.15},${g*.33}
244
+ a${c*.8},${c*.8} 1 0,0 0,${g*.34}
245
+ a${c},${c} 1 0,0 ${-1*p*.15},${g*.33}
246
+
247
+ a${c},${c} 1 0,0 ${-1*p*.25},${g*.15}
248
+ a${c},${c} 1 0,0 ${-1*p*.25},0
249
+ a${c},${c} 1 0,0 ${-1*p*.25},0
250
+ a${c},${c} 1 0,0 ${-1*p*.25},${-1*g*.15}
251
+
252
+ a${c},${c} 1 0,0 ${-1*p*.1},${-1*g*.33}
253
+ a${c*.8},${c*.8} 1 0,0 0,${-1*g*.34}
254
+ a${c},${c} 1 0,0 ${p*.1},${-1*g*.33}
255
+ H0 V0 Z`;if(t.look==="handDrawn"){const x=K.svg(a),k=J(t,{}),w=x.path(C,k);m=a.insert(()=>w,":first-child"),m.attr("class","basic label-container").attr("style",Ht(u))}else m=a.insert("path",":first-child").attr("class","basic label-container").attr("style",i).attr("d",C);return m.attr("transform",`translate(${-p/2}, ${-g/2})`),rt(t,m),t.calcIntersect=function(x,k){return V.rect(x,k)},t.intersect=function(x){return W.info("Bang intersect",t,x),V.rect(t,x)},a}y(Ay,"bang");async function Ey(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const{shapeSvg:a,bbox:s,halfPadding:o,label:n}=await nt(e,t,ot(t)),l=s.width+2*o,h=s.height+2*o,c=.15*l,u=.25*l,f=.35*l,d=.2*l,{cssStyles:p}=t;let g;const m=`M0 0
256
+ a${c},${c} 0 0,1 ${l*.25},${-1*l*.1}
257
+ a${f},${f} 1 0,1 ${l*.4},${-1*l*.1}
258
+ a${u},${u} 1 0,1 ${l*.35},${l*.2}
259
+
260
+ a${c},${c} 1 0,1 ${l*.15},${h*.35}
261
+ a${d},${d} 1 0,1 ${-1*l*.15},${h*.65}
262
+
263
+ a${u},${c} 1 0,1 ${-1*l*.25},${l*.15}
264
+ a${f},${f} 1 0,1 ${-1*l*.5},0
265
+ a${c},${c} 1 0,1 ${-1*l*.25},${-1*l*.15}
266
+
267
+ a${c},${c} 1 0,1 ${-1*l*.1},${-1*h*.35}
268
+ a${d},${d} 1 0,1 ${l*.1},${-1*h*.65}
269
+ H0 V0 Z`;if(t.look==="handDrawn"){const C=K.svg(a),x=J(t,{}),k=C.path(m,x);g=a.insert(()=>k,":first-child"),g.attr("class","basic label-container").attr("style",Ht(p))}else g=a.insert("path",":first-child").attr("class","basic label-container").attr("style",i).attr("d",m);return n.attr("transform",`translate(${-s.width/2}, ${-s.height/2})`),g.attr("transform",`translate(${-l/2}, ${-h/2})`),rt(t,g),t.calcIntersect=function(C,x){return V.rect(C,x)},t.intersect=function(C){return W.info("Cloud intersect",t,C),V.rect(t,C)},a}y(Ey,"cloud");async function $y(e,t){const{labelStyles:r,nodeStyles:i}=tt(t);t.labelStyle=r;const{shapeSvg:a,bbox:s,halfPadding:o,label:n}=await nt(e,t,ot(t)),l=s.width+8*o,h=s.height+2*o,c=5,u=t.look==="neo"?`
270
+ M${-l/2} ${h/2-c}
271
+ v${-h+2*c}
272
+ q0,-${c} ${c},-${c}
273
+ h${l-2*c}
274
+ q${c},0 ${c},${c}
275
+ v${h-c}
276
+ H${-l/2}
277
+ Z
278
+ `:`
279
+ M${-l/2} ${h/2-c}
280
+ v${-h+2*c}
281
+ q0,-${c} ${c},-${c}
282
+ h${l-2*c}
283
+ q${c},0 ${c},${c}
284
+ v${h-2*c}
285
+ q0,${c} ${-c},${c}
286
+ h${-(l-2*c)}
287
+ q${-c},0 ${-c},${-c}
288
+ Z
289
+ `;if(!t.domId)throw new Error(`defaultMindmapNode: node "${t.id}" is missing a domId — was render.ts domId prefixing skipped?`);const f=a.append("path").attr("id",t.domId).attr("class","node-bkg node-"+t.type).attr("style",i).attr("d",u);return a.append("line").attr("class","node-line-").attr("x1",-l/2).attr("y1",h/2).attr("x2",l/2).attr("y2",h/2),n.attr("transform",`translate(${-s.width/2}, ${-s.height/2})`),a.append(()=>n.node()),rt(t,f),t.calcIntersect=function(d,p){return V.rect(d,p)},t.intersect=function(d){return V.rect(t,d)},a}y($y,"defaultMindmapNode");async function Dy(e,t){const r={padding:t.padding??0};return oc(e,t,r)}y(Dy,"mindmapCircle");var uA=[{semanticName:"Process",name:"Rectangle",shortName:"rect",description:"Standard process shape",aliases:["proc","process","rectangle"],internalAliases:["squareRect"],handler:uy},{semanticName:"Event",name:"Rounded Rectangle",shortName:"rounded",description:"Represents an event",aliases:["event"],internalAliases:["roundedRect"],handler:ly},{semanticName:"Terminal Point",name:"Stadium",shortName:"stadium",description:"Terminal point",aliases:["terminal","pill"],handler:dy},{semanticName:"Subprocess",name:"Framed Rectangle",shortName:"fr-rect",description:"Subprocess",aliases:["subprocess","subproc","framed-rectangle","subroutine"],handler:my},{semanticName:"Database",name:"Cylinder",shortName:"cyl",description:"Database storage",aliases:["db","database","cylinder"],handler:O0},{semanticName:"Start",name:"Circle",shortName:"circle",description:"Starting point",aliases:["circ"],handler:oc},{semanticName:"Bang",name:"Bang",shortName:"bang",description:"Bang",aliases:["bang"],handler:Ay},{semanticName:"Cloud",name:"Cloud",shortName:"cloud",description:"cloud",aliases:["cloud"],handler:Ey},{semanticName:"Decision",name:"Diamond",shortName:"diam",description:"Decision-making step",aliases:["decision","diamond","question"],handler:sy},{semanticName:"Prepare Conditional",name:"Hexagon",shortName:"hex",description:"Preparation or condition step",aliases:["hexagon","prepare"],handler:W0},{semanticName:"Data Input/Output",name:"Lean Right",shortName:"lean-r",description:"Represents input or output",aliases:["lean-right","in-out"],internalAliases:["lean_right"],handler:K0},{semanticName:"Data Input/Output",name:"Lean Left",shortName:"lean-l",description:"Represents output or input",aliases:["lean-left","out-in"],internalAliases:["lean_left"],handler:Q0},{semanticName:"Priority Action",name:"Trapezoid Base Bottom",shortName:"trap-b",description:"Priority action",aliases:["priority","trapezoid-bottom","trapezoid"],handler:ky},{semanticName:"Manual Operation",name:"Trapezoid Base Top",shortName:"trap-t",description:"Represents a manual task",aliases:["manual","trapezoid-top","inv-trapezoid"],internalAliases:["inv_trapezoid"],handler:V0},{semanticName:"Stop",name:"Double Circle",shortName:"dbl-circ",description:"Represents a stop point",aliases:["double-circle"],internalAliases:["doublecircle"],handler:P0},{semanticName:"Text Block",name:"Text Block",shortName:"text",description:"Text block",handler:xy},{semanticName:"Card",name:"Notched Rectangle",shortName:"notch-rect",description:"Represents a card",aliases:["card","notched-rectangle"],handler:B0},{semanticName:"Lined/Shaded Process",name:"Lined Rectangle",shortName:"lin-rect",description:"Lined process shape",aliases:["lined-rectangle","lined-process","lin-proc","shaded-process"],handler:hy},{semanticName:"Start",name:"Small Circle",shortName:"sm-circ",description:"Small starting point",aliases:["start","small-circle"],internalAliases:["stateStart"],handler:gy},{semanticName:"Stop",name:"Framed Circle",shortName:"fr-circ",description:"Stop point",aliases:["stop","framed-circle"],internalAliases:["stateEnd"],handler:py},{semanticName:"Fork/Join",name:"Filled Rectangle",shortName:"fork",description:"Fork or join in process flow",aliases:["join"],internalAliases:["forkJoin"],handler:q0},{semanticName:"Collate",name:"Hourglass",shortName:"hourglass",description:"Represents a collate operation",aliases:["hourglass","collate"],handler:H0},{semanticName:"Comment",name:"Curly Brace",shortName:"brace",description:"Adds a comment",aliases:["comment","brace-l"],handler:A0},{semanticName:"Comment Right",name:"Curly Brace",shortName:"brace-r",description:"Adds a comment",handler:E0},{semanticName:"Comment with braces on both sides",name:"Curly Braces",shortName:"braces",description:"Adds a comment",handler:$0},{semanticName:"Com Link",name:"Lightning Bolt",shortName:"bolt",description:"Communication link",aliases:["com-link","lightning-bolt"],handler:J0},{semanticName:"Document",name:"Document",shortName:"doc",description:"Represents a document",aliases:["doc","document"],handler:_y},{semanticName:"Delay",name:"Half-Rounded Rectangle",shortName:"delay",description:"Represents a delay",aliases:["half-rounded-rectangle"],handler:z0},{semanticName:"Direct Access Storage",name:"Horizontal Cylinder",shortName:"h-cyl",description:"Direct access storage",aliases:["das","horizontal-cylinder"],handler:by},{semanticName:"Disk Storage",name:"Lined Cylinder",shortName:"lin-cyl",description:"Disk storage",aliases:["disk","lined-cylinder"],handler:ty},{semanticName:"Display",name:"Curved Trapezoid",shortName:"curv-trap",description:"Represents a display",aliases:["curved-trapezoid","display"],handler:D0},{semanticName:"Divided Process",name:"Divided Rectangle",shortName:"div-rect",description:"Divided process shape",aliases:["div-proc","divided-rectangle","divided-process"],handler:I0},{semanticName:"Extract",name:"Triangle",shortName:"tri",description:"Extraction process",aliases:["extract","triangle"],handler:wy},{semanticName:"Internal Storage",name:"Window Pane",shortName:"win-pane",description:"Internal storage",aliases:["internal-storage","window-pane"],handler:vy},{semanticName:"Junction",name:"Filled Circle",shortName:"f-circ",description:"Junction point",aliases:["junction","filled-circle"],handler:R0},{semanticName:"Loop Limit",name:"Trapezoidal Pentagon",shortName:"notch-pent",description:"Loop limit step",aliases:["loop-limit","notched-pentagon"],handler:Ty},{semanticName:"Manual File",name:"Flipped Triangle",shortName:"flip-tri",description:"Manual file operation",aliases:["manual-file","flipped-triangle"],handler:N0},{semanticName:"Manual Input",name:"Sloped Rectangle",shortName:"sl-rect",description:"Manual input step",aliases:["manual-input","sloped-rectangle"],handler:cy},{semanticName:"Multi-Document",name:"Stacked Document",shortName:"docs",description:"Multiple documents",aliases:["documents","st-doc","stacked-document"],handler:iy},{semanticName:"Multi-Process",name:"Stacked Rectangle",shortName:"st-rect",description:"Multiple processes",aliases:["procs","processes","stacked-rectangle"],handler:ry},{semanticName:"Stored Data",name:"Bow Tie Rectangle",shortName:"bow-rect",description:"Stored data",aliases:["stored-data","bow-tie-rectangle"],handler:v0},{semanticName:"Summary",name:"Crossed Circle",shortName:"cross-circ",description:"Summary",aliases:["summary","crossed-circle"],handler:M0},{semanticName:"Tagged Document",name:"Tagged Document",shortName:"tag-doc",description:"Tagged document",aliases:["tag-doc","tagged-document"],handler:Cy},{semanticName:"Tagged Process",name:"Tagged Rectangle",shortName:"tag-rect",description:"Tagged process",aliases:["tagged-rectangle","tag-proc","tagged-process"],handler:yy},{semanticName:"Paper Tape",name:"Flag",shortName:"flag",description:"Paper tape",aliases:["paper-tape"],handler:Sy},{semanticName:"Odd",name:"Odd",shortName:"odd",description:"Odd shape",internalAliases:["rect_left_inv_arrow"],handler:oy},{semanticName:"Lined Document",name:"Lined Document",shortName:"lin-doc",description:"Lined document",aliases:["lined-document"],handler:ey}],dA=y(()=>{const t=[...Object.entries({state:fy,choice:L0,note:ay,rectWithTitle:ny,labelRect:Z0,iconSquare:G0,iconCircle:Y0,icon:U0,iconRounded:j0,imageSquare:X0,anchor:_0,kanbanItem:My,mindmapCircle:Dy,defaultMindmapNode:$y,classBox:Ly,erBox:nc,requirementBox:Fy}),...uA.flatMap(r=>[r.shortName,..."aliases"in r?r.aliases:[],..."internalAliases"in r?r.internalAliases:[]].map(a=>[a,r.handler]))];return Object.fromEntries(t)},"generateShapeMap"),Oy=dA();function fA(e){return e in Oy}y(fA,"isValidShape");var nn=new Map;async function Iy(e,t,r){let i,a;t.shape==="rect"&&(t.rx&&t.ry?t.shape="roundedRect":t.shape="squareRect");const s=t.shape?Oy[t.shape]:void 0;if(!s)throw new Error(`No such shape: ${t.shape}. Please check your syntax.`);if(t.link){let o;r.config.securityLevel==="sandbox"?o="_top":t.linkTarget&&(o=t.linkTarget||"_blank"),i=e.insert("svg:a").attr("xlink:href",t.link).attr("target",o??null),a=await s(i,t,r)}else a=await s(e,t,r),i=a;return i.attr("data-look",Ht(t.look)),t.tooltip&&a.attr("title",t.tooltip),nn.set(t.id,i),t.haveCallback&&i.attr("class",i.attr("class")+" clickable"),i}y(Iy,"insertNode");var V$=y((e,t)=>{nn.set(t.id,e)},"setNodeElem"),Z$=y(()=>{nn.clear()},"clear"),Q$=y(e=>{const t=nn.get(e.id);W.trace("Transforming node",e.diff,e,"translate("+(e.x-e.width/2-5)+", "+e.width/2+")");const r=8,i=e.diff||0;return e.clusterNode?t.attr("transform","translate("+(e.x+i-e.width/2)+", "+(e.y-e.height/2-r)+")"):t.attr("transform","translate("+e.x+", "+e.y+")"),i},"positionNode"),pA=y((e,t,r,i,a,s=!1,o)=>{t.arrowTypeStart&&Ld(e,"start",t.arrowTypeStart,r,i,a,s,o),t.arrowTypeEnd&&Ld(e,"end",t.arrowTypeEnd,r,i,a,s,o)},"addEdgeMarkers"),gA={arrow_cross:{type:"cross",fill:!1},arrow_point:{type:"point",fill:!0},arrow_barb:{type:"barb",fill:!0},arrow_barb_neo:{type:"barb",fill:!0},arrow_circle:{type:"circle",fill:!1},aggregation:{type:"aggregation",fill:!1},extension:{type:"extension",fill:!1},composition:{type:"composition",fill:!0},dependency:{type:"dependency",fill:!0},lollipop:{type:"lollipop",fill:!1},only_one:{type:"onlyOne",fill:!1},zero_or_one:{type:"zeroOrOne",fill:!1},one_or_more:{type:"oneOrMore",fill:!1},zero_or_more:{type:"zeroOrMore",fill:!1},requirement_arrow:{type:"requirement_arrow",fill:!1},requirement_contains:{type:"requirement_contains",fill:!1}},mA=["cross","point","circle","lollipop","aggregation","extension","composition","dependency","barb"],Ld=y((e,t,r,i,a,s,o=!1,n)=>{var p;const l=gA[r],h=l&&mA.includes(l.type);if(!l){W.warn(`Unknown arrow type: ${r}`);return}const c=l.type,d=`${a}_${s}-${c}${t==="start"?"Start":"End"}${o&&h?"-margin":""}`;if(n&&n.trim()!==""){const g=n.replace(/[^\dA-Za-z]/g,"_"),m=`${d}_${g}`;if(!document.getElementById(m)){const C=document.getElementById(d);if(C){const x=C.cloneNode(!0);x.id=m,x.querySelectorAll("path, circle, line").forEach(w=>{w.setAttribute("stroke",n),l.fill&&w.setAttribute("fill",n)}),(p=C.parentNode)==null||p.appendChild(x)}}e.attr(`marker-${t}`,`url(${i}#${m})`)}else e.attr(`marker-${t}`,`url(${i}#${d})`)},"addEdgeMarker"),yA=y(e=>{var t,r;return typeof e=="string"?e:(r=(t=bt())==null?void 0:t.flowchart)==null?void 0:r.curve},"resolveEdgeCurveType"),Do=new Map,Gt=new Map,K$=y(()=>{Do.clear(),Gt.clear()},"clear"),pa=y(e=>e?typeof e=="string"?e:e.reduce((t,r)=>t+";"+r,""):"","getLabelStyles"),CA=y(async(e,t)=>{const r=bt();let i=ne(r);const{labelStyles:a}=tt(t);t.labelStyle=a;const s=e.insert("g").attr("class","edgeLabel"),o=s.insert("g").attr("class","label").attr("data-id",t.id),n=t.labelType==="markdown",h=await dr(e,t.label,{style:pa(t.labelStyle),useHtmlLabels:i,addSvgBackground:!0,isNode:!1,markdown:n,width:n?void 0:void 0},r);o.node().appendChild(h),W.info("abc82",t,t.labelType);let c=h.getBBox(),u=c;if(i){const d=h.children[0],p=pt(h);c=d.getBoundingClientRect(),u=c,p.attr("width",c.width),p.attr("height",c.height)}else{const d=pt(h).select("text").node();d&&typeof d.getBBox=="function"&&(u=d.getBBox())}o.attr("transform",la(u,i)),Do.set(t.id,s),t.width=c.width,t.height=c.height;let f;if(t.startLabelLeft){const d=e.insert("g").attr("class","edgeTerminals"),p=d.insert("g").attr("class","inner"),g=await gr(p,t.startLabelLeft,pa(t.labelStyle)||"",!1,!1);f=g;let m=g.getBBox();if(i){const C=g.children[0],x=pt(g);m=C.getBoundingClientRect(),x.attr("width",m.width),x.attr("height",m.height)}p.attr("transform",la(m,i)),Gt.get(t.id)||Gt.set(t.id,{}),Gt.get(t.id).startLeft=d,Ta(f,t.startLabelLeft)}if(t.startLabelRight){const d=e.insert("g").attr("class","edgeTerminals"),p=d.insert("g").attr("class","inner"),g=await gr(p,t.startLabelRight,pa(t.labelStyle)||"",!1,!1);f=g,p.node().appendChild(g);let m=g.getBBox();if(i){const C=g.children[0],x=pt(g);m=C.getBoundingClientRect(),x.attr("width",m.width),x.attr("height",m.height)}p.attr("transform",la(m,i)),Gt.get(t.id)||Gt.set(t.id,{}),Gt.get(t.id).startRight=d,Ta(f,t.startLabelRight)}if(t.endLabelLeft){const d=e.insert("g").attr("class","edgeTerminals"),p=d.insert("g").attr("class","inner"),g=await gr(p,t.endLabelLeft,pa(t.labelStyle)||"",!1,!1);f=g;let m=g.getBBox();if(i){const C=g.children[0],x=pt(g);m=C.getBoundingClientRect(),x.attr("width",m.width),x.attr("height",m.height)}p.attr("transform",la(m,i)),d.node().appendChild(g),Gt.get(t.id)||Gt.set(t.id,{}),Gt.get(t.id).endLeft=d,Ta(f,t.endLabelLeft)}if(t.endLabelRight){const d=e.insert("g").attr("class","edgeTerminals"),p=d.insert("g").attr("class","inner"),g=await gr(p,t.endLabelRight,pa(t.labelStyle)||"",!1,!1);f=g;let m=g.getBBox();if(i){const C=g.children[0],x=pt(g);m=C.getBoundingClientRect(),x.attr("width",m.width),x.attr("height",m.height)}p.attr("transform",la(m,i)),d.node().appendChild(g),Gt.get(t.id)||Gt.set(t.id,{}),Gt.get(t.id).endRight=d,Ta(f,t.endLabelRight)}return h},"insertEdgeLabel");function Ta(e,t){ne(bt())&&e&&(e.style.width=t.length*9+"px",e.style.height="12px")}y(Ta,"setTerminalWidth");var xA=y((e,t)=>{W.debug("Moving label abc88 ",e.id,e.label,Do.get(e.id),t);let r=t.updatedPath?t.updatedPath:t.originalPath;const i=bt(),{subGraphTitleTotalMargin:a}=Gh(i);if(e.label){const s=Do.get(e.id);let o=e.x,n=e.y;if(r){const l=Be.calcLabelPosition(r);W.debug("Moving label "+e.label+" from (",o,",",n,") to (",l.x,",",l.y,") abc88"),t.updatedPath&&(o=l.x,n=l.y)}s.attr("transform",`translate(${o}, ${n+a/2})`)}if(e.startLabelLeft){const s=Gt.get(e.id).startLeft;let o=e.x,n=e.y;if(r){const l=Be.calcTerminalLabelPosition(e.arrowTypeStart?10:0,"start_left",r);o=l.x,n=l.y}s.attr("transform",`translate(${o}, ${n})`)}if(e.startLabelRight){const s=Gt.get(e.id).startRight;let o=e.x,n=e.y;if(r){const l=Be.calcTerminalLabelPosition(e.arrowTypeStart?10:0,"start_right",r);o=l.x,n=l.y}s.attr("transform",`translate(${o}, ${n})`)}if(e.endLabelLeft){const s=Gt.get(e.id).endLeft;let o=e.x,n=e.y;if(r){const l=Be.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,"end_left",r);o=l.x,n=l.y}s.attr("transform",`translate(${o}, ${n})`)}if(e.endLabelRight){const s=Gt.get(e.id).endRight;let o=e.x,n=e.y;if(r){const l=Be.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,"end_right",r);o=l.x,n=l.y}s.attr("transform",`translate(${o}, ${n})`)}},"positionEdgeLabel"),bA=y((e,t)=>{const r=e.x,i=e.y,a=Math.abs(t.x-r),s=Math.abs(t.y-i),o=e.width/2,n=e.height/2;return a>=o||s>=n},"outsideNode"),kA=y((e,t,r)=>{W.debug(`intersection calc abc89:
290
+ outsidePoint: ${JSON.stringify(t)}
291
+ insidePoint : ${JSON.stringify(r)}
292
+ node : x:${e.x} y:${e.y} w:${e.width} h:${e.height}`);const i=e.x,a=e.y,s=Math.abs(i-r.x),o=e.width/2;let n=r.x<t.x?o-s:o+s;const l=e.height/2,h=Math.abs(t.y-r.y),c=Math.abs(t.x-r.x);if(Math.abs(a-t.y)*o>Math.abs(i-t.x)*l){let u=r.y<t.y?t.y-l-a:a-l-t.y;n=c*u/h;const f={x:r.x<t.x?r.x+n:r.x-c+n,y:r.y<t.y?r.y+h-u:r.y-h+u};return n===0&&(f.x=t.x,f.y=t.y),c===0&&(f.x=t.x),h===0&&(f.y=t.y),W.debug(`abc89 top/bottom calc, Q ${h}, q ${u}, R ${c}, r ${n}`,f),f}else{r.x<t.x?n=t.x-o-i:n=i-o-t.x;let u=h*n/c,f=r.x<t.x?r.x+c-n:r.x-c+n,d=r.y<t.y?r.y+u:r.y-u;return W.debug(`sides calc abc89, Q ${h}, q ${u}, R ${c}, r ${n}`,{_x:f,_y:d}),n===0&&(f=t.x,d=t.y),c===0&&(f=t.x),h===0&&(d=t.y),{x:f,y:d}}},"intersection"),Fd=y((e,t)=>{W.warn("abc88 cutPathAtIntersect",e,t);let r=[],i=e[0],a=!1;return e.forEach(s=>{if(W.info("abc88 checking point",s,t),!bA(t,s)&&!a){const o=kA(t,i,s);W.debug("abc88 inside",s,i,o),W.debug("abc88 intersection",o,t);let n=!1;r.forEach(l=>{n=n||l.x===o.x&&l.y===o.y}),r.some(l=>l.x===o.x&&l.y===o.y)?W.warn("abc88 no intersect",o,r):r.push(o),a=!0}else W.warn("abc88 outside",s,i),i=s,a||r.push(s)}),W.debug("returning points",r),r},"cutPathAtIntersect");function Py(e){const t=[],r=[];for(let i=1;i<e.length-1;i++){const a=e[i-1],s=e[i],o=e[i+1];(a.x===s.x&&s.y===o.y&&Math.abs(s.x-o.x)>5&&Math.abs(s.y-a.y)>5||a.y===s.y&&s.x===o.x&&Math.abs(s.x-a.x)>5&&Math.abs(s.y-o.y)>5)&&(t.push(s),r.push(i))}return{cornerPoints:t,cornerPointPositions:r}}y(Py,"extractCornerPoints");var Md=y(function(e,t,r){const i=t.x-e.x,a=t.y-e.y,s=Math.sqrt(i*i+a*a),o=r/s;return{x:t.x-o*i,y:t.y-o*a}},"findAdjacentPoint"),TA=y(function(e){const{cornerPointPositions:t}=Py(e),r=[];for(let i=0;i<e.length;i++)if(t.includes(i)){const a=e[i-1],s=e[i+1],o=e[i],n=Md(a,o,5),l=Md(s,o,5),h=l.x-n.x,c=l.y-n.y;r.push(n);const u=Math.sqrt(2)*2;let f={x:o.x,y:o.y};if(Math.abs(s.x-a.x)>10&&Math.abs(s.y-a.y)>=10){W.debug("Corner point fixing",Math.abs(s.x-a.x),Math.abs(s.y-a.y));const d=5;o.x===n.x?f={x:h<0?n.x-d+u:n.x+d-u,y:c<0?n.y-u:n.y+u}:f={x:h<0?n.x-u:n.x+u,y:c<0?n.y-d+u:n.y+d-u}}else W.debug("Corner point skipping fixing",Math.abs(s.x-a.x),Math.abs(s.y-a.y));r.push(f,l)}else r.push(e[i]);return r},"fixCorners"),wA=y((e,t,r)=>{const i=e-t-r,a=2,s=2,o=a+s,n=Math.floor(i/o),l=Array(n).fill(`${a} ${s}`).join(" ");return`0 ${t} ${l} ${r}`},"generateDashArray"),_A=y(function(e,t,r,i,a,s,o,n=!1){var O;if(!o)throw new Error(`insertEdge: missing diagramId for edge "${t.id}" — edge IDs require a diagram prefix for uniqueness`);const{handDrawnSeed:l}=bt();let h=t.points,c=!1;const u=a;var f=s;const d=[];for(const F in t.cssCompiledStyles)Im(F)||d.push(t.cssCompiledStyles[F]);W.debug("UIO intersect check",t.points,f.x,u.x),f.intersect&&u.intersect&&!n&&(h=h.slice(1,t.points.length-1),h.unshift(u.intersect(h[0])),W.debug("Last point UIO",t.start,"-->",t.end,h[h.length-1],f,f.intersect(h[h.length-1])),h.push(f.intersect(h[h.length-1])));const p=btoa(JSON.stringify(h));t.toCluster&&(W.info("to cluster abc88",r.get(t.toCluster)),h=Fd(t.points,r.get(t.toCluster).node),c=!0),t.fromCluster&&(W.debug("from cluster abc88",r.get(t.fromCluster),JSON.stringify(h,null,2)),h=Fd(h.reverse(),r.get(t.fromCluster).node).reverse(),c=!0);let g=h.filter(F=>!Number.isNaN(F.y));const m=yA(t.curve);m!=="rounded"&&(g=TA(g));let C=Ba;switch(m){case"linear":C=Ba;break;case"basis":C=xl;break;case"cardinal":C=mp;break;case"bumpX":C=up;break;case"bumpY":C=dp;break;case"catmullRom":C=Cp;break;case"monotoneX":C=_p;break;case"monotoneY":C=Sp;break;case"natural":C=Bp;break;case"step":C=Lp;break;case"stepAfter":C=Mp;break;case"stepBefore":C=Fp;break;case"rounded":C=Ba;break;default:C=xl}const{x,y:k}=Cv(t),w=J_().x(x).y(k).curve(C);let S;switch(t.thickness){case"normal":S="edge-thickness-normal";break;case"thick":S="edge-thickness-thick";break;case"invisible":S="edge-thickness-invisible";break;default:S="edge-thickness-normal"}switch(t.pattern){case"solid":S+=" edge-pattern-solid";break;case"dotted":S+=" edge-pattern-dotted";break;case"dashed":S+=" edge-pattern-dashed";break;default:S+=" edge-pattern-solid"}let _,T=m==="rounded"?Ry(Ny(g,t),5):w(g);const B=Array.isArray(t.style)?t.style:[t.style];let z=B.find(F=>F==null?void 0:F.startsWith("stroke:")),I="";t.animate&&(I="edge-animation-fast"),t.animation&&(I="edge-animation-"+t.animation);let E=!1;if(t.look==="handDrawn"){const F=K.svg(e);Object.assign([],g);const H=F.path(T,{roughness:.3,seed:l});S+=" transition",_=pt(H).select("path").attr("id",`${o}-${t.id}`).attr("class"," "+S+(t.classes?" "+t.classes:"")+(I?" "+I:"")).attr("style",B?B.reduce((Z,ut)=>Z+";"+ut,""):"");let Y=_.attr("d");_.attr("d",Y),e.node().appendChild(_.node())}else{const F=d.join(";"),H=B?B.reduce((Q,xt)=>Q+xt+";",""):"",Y=(F?F+";"+H+";":H)+";"+(B?B.reduce((Q,xt)=>Q+";"+xt,""):"");_=e.append("path").attr("d",T).attr("id",`${o}-${t.id}`).attr("class"," "+S+(t.classes?" "+t.classes:"")+(I?" "+I:"")).attr("style",Y),z=(O=Y.match(/stroke:([^;]+)/))==null?void 0:O[1],E=t.animate===!0||!!t.animation||F.includes("animation");const Z=_.node(),ut=typeof Z.getTotalLength=="function"?Z.getTotalLength():0,at=Du[t.arrowTypeStart]||0,dt=Du[t.arrowTypeEnd]||0;if(t.look==="neo"&&!E){const xt=`stroke-dasharray: ${t.pattern==="dotted"||t.pattern==="dashed"?wA(ut,at,dt):`0 ${at} ${ut-at-dt} ${dt}`}; stroke-dashoffset: 0;`;_.attr("style",xt+_.attr("style"))}}_.attr("data-edge",!0),_.attr("data-et","edge"),_.attr("data-id",t.id),_.attr("data-points",p),_.attr("data-look",Ht(t.look)),t.showPoints&&g.forEach(F=>{e.append("circle").style("stroke","red").style("fill","red").attr("r",1).attr("cx",F.x).attr("cy",F.y)});let N="";(bt().flowchart.arrowMarkerAbsolute||bt().state.arrowMarkerAbsolute)&&(N=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,N=N.replace(/\(/g,"\\(").replace(/\)/g,"\\)")),W.info("arrowTypeStart",t.arrowTypeStart),W.info("arrowTypeEnd",t.arrowTypeEnd);const D=!E&&(t==null?void 0:t.look)==="neo";pA(_,t,N,o,i,D,z);const M=Math.floor(h.length/2),$=h[M];Be.isLabelCoordinateInPath($,_.attr("d"))||(c=!0);let A={};return c&&(A.updatedPath=h),A.originalPath=t.points,A},"insertEdge");function Ry(e,t){if(e.length<2)return"";let r="";const i=e.length,a=1e-5;for(let s=0;s<i;s++){const o=e[s],n=e[s-1],l=e[s+1];if(s===0)r+=`M${o.x},${o.y}`;else if(s===i-1)r+=`L${o.x},${o.y}`;else{const h=o.x-n.x,c=o.y-n.y,u=l.x-o.x,f=l.y-o.y,d=Math.hypot(h,c),p=Math.hypot(u,f);if(d<a||p<a){r+=`L${o.x},${o.y}`;continue}const g=h/d,m=c/d,C=u/p,x=f/p,k=g*C+m*x,w=Math.max(-1,Math.min(1,k)),S=Math.acos(w);if(S<a||Math.abs(Math.PI-S)<a){r+=`L${o.x},${o.y}`;continue}const _=Math.min(t/Math.sin(S/2),d/2,p/2),T=o.x-g*_,B=o.y-m*_,z=o.x+C*_,I=o.y+x*_;r+=`L${T},${B}`,r+=`Q${o.x},${o.y} ${z},${I}`}}return r}y(Ry,"generateRoundedPath");function Vl(e,t){if(!e||!t)return{angle:0,deltaX:0,deltaY:0};const r=t.x-e.x,i=t.y-e.y;return{angle:Math.atan2(i,r),deltaX:r,deltaY:i}}y(Vl,"calculateDeltaAndAngle");function Ny(e,t){const r=e.map(a=>({...a}));if(e.length>=2&&Kt[t.arrowTypeStart]){const a=Kt[t.arrowTypeStart],s=e[0],o=e[1],{angle:n}=Vl(s,o),l=a*Math.cos(n),h=a*Math.sin(n);r[0].x=s.x+l,r[0].y=s.y+h}const i=e.length;if(i>=2&&Kt[t.arrowTypeEnd]){const a=Kt[t.arrowTypeEnd],s=e[i-1],o=e[i-2],{angle:n}=Vl(o,s),l=a*Math.cos(n),h=a*Math.sin(n);r[i-1].x=s.x-l,r[i-1].y=s.y-h}return r}y(Ny,"applyMarkerOffsetsToPoints");var SA=y((e,t,r,i)=>{t.forEach(a=>{XA[a](e,r,i)})},"insertMarkers"),vA=y((e,t,r)=>{W.trace("Making markers for ",r),e.append("defs").append("marker").attr("id",r+"_"+t+"-extensionStart").attr("class","marker extension "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 1,7 L18,13 V 1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-extensionEnd").attr("class","marker extension "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z"),e.append("marker").attr("id",r+"_"+t+"-extensionStart-margin").attr("class","marker extension "+t).attr("refX",18).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").attr("viewBox","0 0 20 14").append("polygon").attr("points","10,7 18,13 18,1").style("stroke-width",2).style("stroke-dasharray","0"),e.append("defs").append("marker").attr("id",r+"_"+t+"-extensionEnd-margin").attr("class","marker extension "+t).attr("refX",9).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").attr("viewBox","0 0 20 14").append("polygon").attr("points","10,1 10,13 18,7").style("stroke-width",2).style("stroke-dasharray","0")},"extension"),BA=y((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-compositionStart").attr("class","marker composition "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-compositionEnd").attr("class","marker composition "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-compositionStart-margin").attr("class","marker composition "+t).attr("refX",15).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("viewBox","0 0 15 15").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-compositionEnd-margin").attr("class","marker composition "+t).attr("refX",3.5).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"composition"),LA=y((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationStart").attr("class","marker aggregation "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationEnd").attr("class","marker aggregation "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationStart-margin").attr("class","marker aggregation "+t).attr("refX",15).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",2).attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationEnd-margin").attr("class","marker aggregation "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",2).attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"aggregation"),FA=y((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyStart").attr("class","marker dependency "+t).attr("refX",6).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyEnd").attr("class","marker dependency "+t).attr("refX",13).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyStart-margin").attr("class","marker dependency "+t).attr("refX",4).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyEnd-margin").attr("class","marker dependency "+t).attr("refX",16).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},"dependency"),MA=y((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopStart").attr("class","marker lollipop "+t).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),e.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopEnd").attr("class","marker lollipop "+t).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),e.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopStart-margin").attr("class","marker lollipop "+t).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6).attr("stroke-width",2),e.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopEnd-margin").attr("class","marker lollipop "+t).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6).attr("stroke-width",2)},"lollipop"),AA=y((e,t,r)=>{e.append("marker").attr("id",r+"_"+t+"-pointEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-pointStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",4.5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-pointEnd-margin").attr("class","marker "+t).attr("viewBox","0 0 11.5 14").attr("refX",11.5).attr("refY",7).attr("markerUnits","userSpaceOnUse").attr("markerWidth",10.5).attr("markerHeight",14).attr("orient","auto").append("path").attr("d","M 0 0 L 11.5 7 L 0 14 z").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-pointStart-margin").attr("class","marker "+t).attr("viewBox","0 0 11.5 14").attr("refX",1).attr("refY",7).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11.5).attr("markerHeight",14).attr("orient","auto").append("polygon").attr("points","0,7 11.5,14 11.5,0").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0")},"point"),EA=y((e,t,r)=>{e.append("marker").attr("id",r+"_"+t+"-circleEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-circleStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-circleEnd-margin").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refY",5).attr("refX",12.25).attr("markerUnits","userSpaceOnUse").attr("markerWidth",14).attr("markerHeight",14).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-circleStart-margin").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",-2).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",14).attr("markerHeight",14).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0")},"circle"),$A=y((e,t,r)=>{e.append("marker").attr("id",r+"_"+t+"-crossEnd").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-crossStart").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-crossEnd-margin").attr("class","marker cross "+t).attr("viewBox","0 0 15 15").attr("refX",17.7).attr("refY",7.5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 1,1 L 14,14 M 1,14 L 14,1").attr("class","arrowMarkerPath").style("stroke-width",2.5),e.append("marker").attr("id",r+"_"+t+"-crossStart-margin").attr("class","marker cross "+t).attr("viewBox","0 0 15 15").attr("refX",-3.5).attr("refY",7.5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 1,1 L 14,14 M 1,14 L 14,1").attr("class","arrowMarkerPath").style("stroke-width",2.5).style("stroke-dasharray","1,0")},"cross"),DA=y((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")},"barb"),OA=y((e,t,r)=>{const i=At(),{themeVariables:a}=i,{transitionColor:s}=a;e.append("defs").append("marker").attr("id",r+"_"+t+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","strokeWidth").attr("orient","auto").append("path").attr("d","M 19,7 L11,14 L13,7 L11,0 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-barbEnd-margin").attr("refX",17).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M 19,7 L11,14 L13,7 L11,0 Z").attr("fill",`${s}`)},"barbNeo"),IA=y((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-onlyOneStart").attr("class","marker onlyOne "+t).attr("refX",0).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M9,0 L9,18 M15,0 L15,18"),e.append("defs").append("marker").attr("id",r+"_"+t+"-onlyOneEnd").attr("class","marker onlyOne "+t).attr("refX",18).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M3,0 L3,18 M9,0 L9,18")},"only_one"),PA=y((e,t,r)=>{const i=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrOneStart").attr("class","marker zeroOrOne "+t).attr("refX",0).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");i.append("circle").attr("fill","white").attr("cx",21).attr("cy",9).attr("r",6),i.append("path").attr("d","M9,0 L9,18");const a=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrOneEnd").attr("class","marker zeroOrOne "+t).attr("refX",30).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");a.append("circle").attr("fill","white").attr("cx",9).attr("cy",9).attr("r",6),a.append("path").attr("d","M21,0 L21,18")},"zero_or_one"),RA=y((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-oneOrMoreStart").attr("class","marker oneOrMore "+t).attr("refX",18).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27"),e.append("defs").append("marker").attr("id",r+"_"+t+"-oneOrMoreEnd").attr("class","marker oneOrMore "+t).attr("refX",27).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18")},"one_or_more"),NA=y((e,t,r)=>{const i=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrMoreStart").attr("class","marker zeroOrMore "+t).attr("refX",18).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");i.append("circle").attr("fill","white").attr("cx",48).attr("cy",18).attr("r",6),i.append("path").attr("d","M0,18 Q18,0 36,18 Q18,36 0,18");const a=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrMoreEnd").attr("class","marker zeroOrMore "+t).attr("refX",39).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");a.append("circle").attr("fill","white").attr("cx",9).attr("cy",18).attr("r",6),a.append("path").attr("d","M21,18 Q39,0 57,18 Q39,36 21,18")},"zero_or_more"),qA=y((e,t,r)=>{const i=At(),{themeVariables:a}=i,{strokeWidth:s}=a;e.append("defs").append("marker").attr("id",r+"_"+t+"-onlyOneStart").attr("class","marker onlyOne "+t).attr("refX",0).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M9,0 L9,18 M15,0 L15,18").attr("stroke-width",`${s}`),e.append("defs").append("marker").attr("id",r+"_"+t+"-onlyOneEnd").attr("class","marker onlyOne "+t).attr("refX",18).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M3,0 L3,18 M9,0 L9,18").attr("stroke-width",`${s}`)},"only_one_neo"),zA=y((e,t,r)=>{const i=At(),{themeVariables:a}=i,{strokeWidth:s,mainBkg:o}=a,n=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrOneStart").attr("class","marker zeroOrOne "+t).attr("refX",0).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto").attr("markerUnits","userSpaceOnUse");n.append("circle").attr("fill",o??"white").attr("cx",21).attr("cy",9).attr("stroke-width",`${s}`).attr("r",6),n.append("path").attr("d","M9,0 L9,18").attr("stroke-width",`${s}`);const l=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrOneEnd").attr("class","marker zeroOrOne "+t).attr("refX",30).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("markerUnits","userSpaceOnUse").attr("orient","auto");l.append("circle").attr("fill",o??"white").attr("cx",9).attr("cy",9).attr("stroke-width",`${s}`).attr("r",6),l.append("path").attr("d","M21,0 L21,18").attr("stroke-width",`${s}`)},"zero_or_one_neo"),WA=y((e,t,r)=>{const i=At(),{themeVariables:a}=i,{strokeWidth:s}=a;e.append("defs").append("marker").attr("id",r+"_"+t+"-oneOrMoreStart").attr("class","marker oneOrMore "+t).attr("refX",18).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27").attr("stroke-width",`${s}`),e.append("defs").append("marker").attr("id",r+"_"+t+"-oneOrMoreEnd").attr("class","marker oneOrMore "+t).attr("refX",27).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18").attr("stroke-width",`${s}`)},"one_or_more_neo"),HA=y((e,t,r)=>{const i=At(),{themeVariables:a}=i,{strokeWidth:s,mainBkg:o}=a,n=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrMoreStart").attr("class","marker zeroOrMore "+t).attr("refX",18).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("markerUnits","userSpaceOnUse").attr("orient","auto");n.append("circle").attr("fill",o??"white").attr("cx",45.5).attr("cy",18).attr("r",6).attr("stroke-width",`${s}`),n.append("path").attr("d","M0,18 Q18,0 36,18 Q18,36 0,18").attr("stroke-width",`${s}`);const l=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrMoreEnd").attr("class","marker zeroOrMore "+t).attr("refX",39).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto").attr("markerUnits","userSpaceOnUse");l.append("circle").attr("fill",o??"white").attr("cx",11).attr("cy",18).attr("r",6).attr("stroke-width",`${s}`),l.append("path").attr("d","M21,18 Q39,0 57,18 Q39,36 21,18").attr("stroke-width",`${s}`)},"zero_or_more_neo"),UA=y((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-requirement_arrowEnd").attr("refX",20).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("path").attr("d",`M0,0
293
+ L20,10
294
+ M20,10
295
+ L0,20`)},"requirement_arrow"),YA=y((e,t,r)=>{const i=At(),{themeVariables:a}=i,{strokeWidth:s}=a;e.append("defs").append("marker").attr("id",r+"_"+t+"-requirement_arrowEnd").attr("refX",20).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").attr("markerUnits","userSpaceOnUse").attr("stroke-width",`${s}`).attr("viewBox","0 0 25 20").append("path").attr("d",`M0,0
296
+ L20,10
297
+ M20,10
298
+ L0,20`).attr("stroke-linejoin","miter")},"requirement_arrow_neo"),jA=y((e,t,r)=>{const i=e.append("defs").append("marker").attr("id",r+"_"+t+"-requirement_containsStart").attr("refX",0).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("g");i.append("circle").attr("cx",10).attr("cy",10).attr("r",9).attr("fill","none"),i.append("line").attr("x1",1).attr("x2",19).attr("y1",10).attr("y2",10),i.append("line").attr("y1",1).attr("y2",19).attr("x1",10).attr("x2",10)},"requirement_contains"),GA=y((e,t,r)=>{const i=At(),{themeVariables:a}=i,{strokeWidth:s}=a,o=e.append("defs").append("marker").attr("id",r+"_"+t+"-requirement_containsStart").attr("refX",0).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("g");o.append("circle").attr("cx",10).attr("cy",10).attr("r",9).attr("fill","none"),o.append("line").attr("x1",1).attr("x2",19).attr("y1",10).attr("y2",10),o.append("line").attr("y1",1).attr("y2",19).attr("x1",10).attr("x2",10),o.selectAll("*").attr("stroke-width",`${s}`)},"requirement_contains_neo"),XA={extension:vA,composition:BA,aggregation:LA,dependency:FA,lollipop:MA,point:AA,circle:EA,cross:$A,barb:DA,barbNeo:OA,only_one:IA,zero_or_one:PA,one_or_more:RA,zero_or_more:NA,only_one_neo:qA,zero_or_one_neo:zA,one_or_more_neo:WA,zero_or_more_neo:HA,requirement_arrow:UA,requirement_contains:jA,requirement_arrow_neo:YA,requirement_contains_neo:GA},VA=SA,ZA={common:Ya,getConfig:At,insertCluster:GM,insertEdge:_A,insertEdgeLabel:CA,insertMarkers:VA,insertNode:Iy,interpolateToCurve:zh,labelHelper:nt,log:W,positionEdgeLabel:xA},Wa={},qy=y(e=>{for(const t of e)Wa[t.name]=t},"registerLayoutLoaders"),QA=y(()=>{qy([{name:"dagre",loader:y(async()=>await Ct(()=>import("./dagre-KV5264BT-Evq-yC-H.js"),__vite__mapDeps([0,1,2,3,4,5])),"loader")},{name:"cose-bilkent",loader:y(async()=>await Ct(()=>import("./cose-bilkent-S5V4N54A-tP2GUtP-.js"),__vite__mapDeps([6,7])),"loader")}])},"registerDefaultLayoutLoaders");QA();var J$=y(async(e,t)=>{if(!(e.layoutAlgorithm in Wa))throw new Error(`Unknown layout algorithm: ${e.layoutAlgorithm}`);if(e.diagramId)for(const c of e.nodes){const u=c.domId||c.id;c.domId=`${e.diagramId}-${u}`}const r=Wa[e.layoutAlgorithm],i=await r.loader(),{theme:a,themeVariables:s}=e.config,{useGradient:o,gradientStart:n,gradientStop:l}=s,h=t.attr("id");if(t.append("defs").append("filter").attr("id",`${h}-drop-shadow`).attr("height","130%").attr("width","130%").append("feDropShadow").attr("dx","4").attr("dy","4").attr("stdDeviation",0).attr("flood-opacity","0.06").attr("flood-color",`${a!=null&&a.includes("dark")?"#FFFFFF":"#000000"}`),t.append("defs").append("filter").attr("id",`${h}-drop-shadow-small`).attr("height","150%").attr("width","150%").append("feDropShadow").attr("dx","2").attr("dy","2").attr("stdDeviation",0).attr("flood-opacity","0.06").attr("flood-color",`${a!=null&&a.includes("dark")?"#FFFFFF":"#000000"}`),o){const c=t.append("linearGradient").attr("id",t.attr("id")+"-gradient").attr("gradientUnits","objectBoundingBox").attr("x1","0%").attr("y1","0%").attr("x2","100%").attr("y2","0%");c.append("svg:stop").attr("offset","0%").attr("stop-color",n).attr("stop-opacity",1),c.append("svg:stop").attr("offset","100%").attr("stop-color",l).attr("stop-opacity",1)}return i.render(e,t,ZA,{algorithm:r.algorithm})},"render"),tD=y((e="",{fallback:t="dagre"}={})=>{if(e in Wa)return e;if(t in Wa)return W.warn(`Layout algorithm ${e} is not registered. Using ${t} as fallback.`),t;throw new Error(`Both layout algorithms ${e} and ${t} are not registered.`)},"getRegisteredLayoutAlgorithm"),zy="comm",Wy="rule",Hy="decl",KA="@import",JA="@namespace",t5="@keyframes",e5="@layer",Uy=Math.abs,lc=String.fromCharCode;function Yy(e){return e.trim()}function qs(e,t,r){return e.replace(t,r)}function r5(e,t,r){return e.indexOf(t,r)}function Ci(e,t){return e.charCodeAt(t)|0}function Wi(e,t,r){return e.slice(t,r)}function qe(e){return e.length}function i5(e){return e.length}function ws(e,t){return t.push(e),e}var ln=1,Hi=1,jy=0,Te=0,Pt=0,Xi="";function hc(e,t,r,i,a,s,o,n){return{value:e,root:t,parent:r,type:i,props:a,children:s,line:ln,column:Hi,length:o,return:"",siblings:n}}function a5(){return Pt}function s5(){return Pt=Te>0?Ci(Xi,--Te):0,Hi--,Pt===10&&(Hi=1,ln--),Pt}function Fe(){return Pt=Te<jy?Ci(Xi,Te++):0,Hi++,Pt===10&&(Hi=1,ln++),Pt}function mr(){return Ci(Xi,Te)}function zs(){return Te}function hn(e,t){return Wi(Xi,e,t)}function Ha(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function o5(e){return ln=Hi=1,jy=qe(Xi=e),Te=0,[]}function n5(e){return Xi="",e}function Zn(e){return Yy(hn(Te-1,Zl(e===91?e+2:e===40?e+1:e)))}function l5(e){for(;(Pt=mr())&&Pt<33;)Fe();return Ha(e)>2||Ha(Pt)>3?"":" "}function h5(e,t){for(;--t&&Fe()&&!(Pt<48||Pt>102||Pt>57&&Pt<65||Pt>70&&Pt<97););return hn(e,zs()+(t<6&&mr()==32&&Fe()==32))}function Zl(e){for(;Fe();)switch(Pt){case e:return Te;case 34:case 39:e!==34&&e!==39&&Zl(Pt);break;case 40:e===41&&Zl(e);break;case 92:Fe();break}return Te}function c5(e,t){for(;Fe()&&e+Pt!==57;)if(e+Pt===84&&mr()===47)break;return"/*"+hn(t,Te-1)+"*"+lc(e===47?e:Fe())}function u5(e){for(;!Ha(mr());)Fe();return hn(e,Te)}function d5(e){return n5(Ws("",null,null,null,[""],e=o5(e),0,[0],e))}function Ws(e,t,r,i,a,s,o,n,l){for(var h=0,c=0,u=o,f=0,d=0,p=0,g=1,m=1,C=1,x=0,k="",w=a,S=s,_=i,T=k;m;)switch(p=x,x=Fe()){case 40:if(p!=108&&Ci(T,u-1)==58){r5(T+=qs(Zn(x),"&","&\f"),"&\f",Uy(h?n[h-1]:0))!=-1&&(C=-1);break}case 34:case 39:case 91:T+=Zn(x);break;case 9:case 10:case 13:case 32:T+=l5(p);break;case 92:T+=h5(zs()-1,7);continue;case 47:switch(mr()){case 42:case 47:ws(f5(c5(Fe(),zs()),t,r,l),l),(Ha(p||1)==5||Ha(mr()||1)==5)&&qe(T)&&Wi(T,-1,void 0)!==" "&&(T+=" ");break;default:T+="/"}break;case 123*g:n[h++]=qe(T)*C;case 125*g:case 59:case 0:switch(x){case 0:case 125:m=0;case 59+c:C==-1&&(T=qs(T,/\f/g,"")),d>0&&(qe(T)-u||g===0&&p===47)&&ws(d>32?Ed(T+";",i,r,u-1,l):Ed(qs(T," ","")+";",i,r,u-2,l),l);break;case 59:T+=";";default:if(ws(_=Ad(T,t,r,h,c,a,n,k,w=[],S=[],u,s),s),x===123)if(c===0)Ws(T,t,_,_,w,s,u,n,S);else{switch(f){case 99:if(Ci(T,3)===110)break;case 108:if(Ci(T,2)===97)break;default:c=0;case 100:case 109:case 115:}c?Ws(e,_,_,i&&ws(Ad(e,_,_,0,0,a,n,k,a,w=[],u,S),S),a,S,u,n,i?w:S):Ws(T,_,_,_,[""],S,0,n,S)}}h=c=d=0,g=C=1,k=T="",u=o;break;case 58:u=1+qe(T),d=p;default:if(g<1){if(x==123)--g;else if(x==125&&g++==0&&s5()==125)continue}switch(T+=lc(x),x*g){case 38:C=c>0?1:(T+="\f",-1);break;case 44:n[h++]=(qe(T)-1)*C,C=1;break;case 64:mr()===45&&(T+=Zn(Fe())),f=mr(),c=u=qe(k=T+=u5(zs())),x++;break;case 45:p===45&&qe(T)==2&&(g=0)}}return s}function Ad(e,t,r,i,a,s,o,n,l,h,c,u){for(var f=a-1,d=a===0?s:[""],p=i5(d),g=0,m=0,C=0;g<i;++g)for(var x=0,k=Wi(e,f+1,f=Uy(m=o[g])),w=e;x<p;++x)(w=Yy(m>0?d[x]+" "+k:qs(k,/&\f/g,d[x])))&&(l[C++]=w);return hc(e,t,r,a===0?Wy:n,l,h,c,u)}function f5(e,t,r,i){return hc(e,t,r,zy,lc(a5()),Wi(e,2,-2),0,i)}function Ed(e,t,r,i,a){return hc(e,t,r,Hy,Wi(e,0,i),Wi(e,i+1,-1),i,a)}function Ql(e,t){for(var r="",i=0;i<e.length;i++)r+=t(e[i],i,e,t)||"";return r}function p5(e,t,r,i){switch(e.type){case e5:if(e.children.length)break;case KA:case JA:case Hy:return e.return=e.return||e.value;case zy:return"";case t5:return e.return=e.value+"{"+Ql(e.children,i)+"}";case Wy:if(!qe(e.value=e.props.join(",")))return""}return qe(r=Ql(e.children,i))?e.return=e.value+"{"+r+"}":""}var g5=gm(Object.keys,Object),m5=Object.prototype,y5=m5.hasOwnProperty;function C5(e){if(!Ko(e))return g5(e);var t=[];for(var r in Object(e))y5.call(e,r)&&r!="constructor"&&t.push(r);return t}var Kl=Jr(Ge,"DataView"),Jl=Jr(Ge,"Promise"),th=Jr(Ge,"Set"),eh=Jr(Ge,"WeakMap"),$d="[object Map]",x5="[object Object]",Dd="[object Promise]",Od="[object Set]",Id="[object WeakMap]",Pd="[object DataView]",b5=Kr(Kl),k5=Kr(qa),T5=Kr(Jl),w5=Kr(th),_5=Kr(eh),Ar=Ui;(Kl&&Ar(new Kl(new ArrayBuffer(1)))!=Pd||qa&&Ar(new qa)!=$d||Jl&&Ar(Jl.resolve())!=Dd||th&&Ar(new th)!=Od||eh&&Ar(new eh)!=Id)&&(Ar=function(e){var t=Ui(e),r=t==x5?e.constructor:void 0,i=r?Kr(r):"";if(i)switch(i){case b5:return Pd;case k5:return $d;case T5:return Dd;case w5:return Od;case _5:return Id}return t});var S5="[object Map]",v5="[object Set]",B5=Object.prototype,L5=B5.hasOwnProperty;function Rd(e){if(e==null)return!0;if(Jo(e)&&(_o(e)||typeof e=="string"||typeof e.splice=="function"||Nh(e)||qh(e)||wo(e)))return!e.length;var t=Ar(e);if(t==S5||t==v5)return!e.size;if(Ko(e))return!C5(e).length;for(var r in e)if(L5.call(e,r))return!1;return!0}var Gy="c4",F5=y(e=>/^\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(e),"detector"),M5=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./c4Diagram-AHTNJAMY-CUE7rn2p.js");return{diagram:t}},__vite__mapDeps([8,9]));return{id:Gy,diagram:e}},"loader"),A5={id:Gy,detector:F5,loader:M5},E5=A5,Xy="flowchart",$5=y((e,t)=>{var r,i;return((r=t==null?void 0:t.flowchart)==null?void 0:r.defaultRenderer)==="dagre-wrapper"||((i=t==null?void 0:t.flowchart)==null?void 0:i.defaultRenderer)==="elk"?!1:/^\s*graph/.test(e)},"detector"),D5=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./flowDiagram-DWJPFMVM-BjEk7JcK.js");return{diagram:t}},__vite__mapDeps([10,11,9,12,13]));return{id:Xy,diagram:e}},"loader"),O5={id:Xy,detector:$5,loader:D5},I5=O5,Vy="flowchart-v2",P5=y((e,t)=>{var r,i,a;return((r=t==null?void 0:t.flowchart)==null?void 0:r.defaultRenderer)==="dagre-d3"?!1:(((i=t==null?void 0:t.flowchart)==null?void 0:i.defaultRenderer)==="elk"&&(t.layout="elk"),/^\s*graph/.test(e)&&((a=t==null?void 0:t.flowchart)==null?void 0:a.defaultRenderer)==="dagre-wrapper"?!0:/^\s*flowchart/.test(e))},"detector"),R5=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./flowDiagram-DWJPFMVM-BjEk7JcK.js");return{diagram:t}},__vite__mapDeps([10,11,9,12,13]));return{id:Vy,diagram:e}},"loader"),N5={id:Vy,detector:P5,loader:R5},q5=N5,Zy="er",z5=y(e=>/^\s*erDiagram/.test(e),"detector"),W5=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./erDiagram-SMLLAGMA-aXA9Q1fI.js");return{diagram:t}},__vite__mapDeps([14,12,13]));return{id:Zy,diagram:e}},"loader"),H5={id:Zy,detector:z5,loader:W5},U5=H5,Qy="gitGraph",Y5=y(e=>/^\s*gitGraph/.test(e),"detector"),j5=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./gitGraphDiagram-UUTBAWPF-oEcGoRSk.js");return{diagram:t}},__vite__mapDeps([15,16,17,18,4,2]));return{id:Qy,diagram:e}},"loader"),G5={id:Qy,detector:Y5,loader:j5},X5=G5,Ky="gantt",V5=y(e=>/^\s*gantt/.test(e),"detector"),Z5=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./ganttDiagram-T4ZO3ILL-D3u7X5y3.js");return{diagram:t}},[]);return{id:Ky,diagram:e}},"loader"),Q5={id:Ky,detector:V5,loader:Z5},K5=Q5,Jy="info",J5=y(e=>/^\s*info/.test(e),"detector"),tE=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./infoDiagram-42DDH7IO-C28F97oa.js");return{diagram:t}},__vite__mapDeps([19,18,4,2]));return{id:Jy,diagram:e}},"loader"),eE={id:Jy,detector:J5,loader:tE},tC="pie",rE=y(e=>/^\s*pie/.test(e),"detector"),iE=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./pieDiagram-DEJITSTG-DDYdBumO.js");return{diagram:t}},__vite__mapDeps([20,16,18,4,2]));return{id:tC,diagram:e}},"loader"),aE={id:tC,detector:rE,loader:iE},eC="quadrantChart",sE=y(e=>/^\s*quadrantChart/.test(e),"detector"),oE=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./quadrantDiagram-34T5L4WZ-1M4jQ4aT.js");return{diagram:t}},[]);return{id:eC,diagram:e}},"loader"),nE={id:eC,detector:sE,loader:oE},lE=nE,rC="xychart",hE=y(e=>/^\s*xychart(-beta)?/.test(e),"detector"),cE=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./xychartDiagram-5P7HB3ND-tZNDsxpi.js");return{diagram:t}},[]);return{id:rC,diagram:e}},"loader"),uE={id:rC,detector:hE,loader:cE},dE=uE,iC="requirement",fE=y(e=>/^\s*requirement(Diagram)?/.test(e),"detector"),pE=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./requirementDiagram-MS252O5E-cbWppHFa.js");return{diagram:t}},__vite__mapDeps([21,12,13]));return{id:iC,diagram:e}},"loader"),gE={id:iC,detector:fE,loader:pE},mE=gE,aC="sequence",yE=y(e=>/^\s*sequenceDiagram/.test(e),"detector"),CE=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./sequenceDiagram-FGHM5R23-ComC2-Sc.js");return{diagram:t}},__vite__mapDeps([22,9,17]));return{id:aC,diagram:e}},"loader"),xE={id:aC,detector:yE,loader:CE},bE=xE,sC="class",kE=y((e,t)=>{var r;return((r=t==null?void 0:t.class)==null?void 0:r.defaultRenderer)==="dagre-wrapper"?!1:/^\s*classDiagram/.test(e)},"detector"),TE=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./classDiagram-6PBFFD2Q-DHxKXnDK.js");return{diagram:t}},__vite__mapDeps([23,24,11,9,12,13]));return{id:sC,diagram:e}},"loader"),wE={id:sC,detector:kE,loader:TE},_E=wE,oC="classDiagram",SE=y((e,t)=>{var r;return/^\s*classDiagram/.test(e)&&((r=t==null?void 0:t.class)==null?void 0:r.defaultRenderer)==="dagre-wrapper"?!0:/^\s*classDiagram-v2/.test(e)},"detector"),vE=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./classDiagram-v2-HSJHXN6E-DHxKXnDK.js");return{diagram:t}},__vite__mapDeps([25,24,11,9,12,13]));return{id:oC,diagram:e}},"loader"),BE={id:oC,detector:SE,loader:vE},LE=BE,nC="state",FE=y((e,t)=>{var r;return((r=t==null?void 0:t.state)==null?void 0:r.defaultRenderer)==="dagre-wrapper"?!1:/^\s*stateDiagram/.test(e)},"detector"),ME=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./stateDiagram-FHFEXIEX-8nR4RqyL.js");return{diagram:t}},__vite__mapDeps([26,27,12,13,1,2,3,4]));return{id:nC,diagram:e}},"loader"),AE={id:nC,detector:FE,loader:ME},EE=AE,lC="stateDiagram",$E=y((e,t)=>{var r;return!!(/^\s*stateDiagram-v2/.test(e)||/^\s*stateDiagram/.test(e)&&((r=t==null?void 0:t.state)==null?void 0:r.defaultRenderer)==="dagre-wrapper")},"detector"),DE=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./stateDiagram-v2-QKLJ7IA2-sni4Ws2p.js");return{diagram:t}},__vite__mapDeps([28,27,12,13]));return{id:lC,diagram:e}},"loader"),OE={id:lC,detector:$E,loader:DE},IE=OE,hC="journey",PE=y(e=>/^\s*journey/.test(e),"detector"),RE=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./journeyDiagram-VCZTEJTY-DshaLFkN.js");return{diagram:t}},__vite__mapDeps([29,11,9]));return{id:hC,diagram:e}},"loader"),NE={id:hC,detector:PE,loader:RE},qE=NE,zE=y((e,t,r)=>{W.debug(`rendering svg for syntax error
299
+ `);const i=cS(t),a=i.append("g");i.attr("viewBox","0 0 2412 512"),uf(i,100,512,!0),a.append("path").attr("class","error-icon").attr("d","m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z"),a.append("path").attr("class","error-icon").attr("d","m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z"),a.append("path").attr("class","error-icon").attr("d","m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z"),a.append("path").attr("class","error-icon").attr("d","m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z"),a.append("path").attr("class","error-icon").attr("d","m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z"),a.append("path").attr("class","error-icon").attr("d","m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z"),a.append("text").attr("class","error-text").attr("x",1440).attr("y",250).attr("font-size","150px").style("text-anchor","middle").text("Syntax error in text"),a.append("text").attr("class","error-text").attr("x",1250).attr("y",400).attr("font-size","100px").style("text-anchor","middle").text(`mermaid version ${r}`)},"draw"),cC={draw:zE},WE=cC,HE={db:{},renderer:cC,parser:{parse:y(()=>{},"parse")}},UE=HE,uC="flowchart-elk",YE=y((e,t={})=>{var r;return/^\s*flowchart-elk/.test(e)||/^\s*(flowchart|graph)/.test(e)&&((r=t==null?void 0:t.flowchart)==null?void 0:r.defaultRenderer)==="elk"?(t.layout="elk",!0):!1},"detector"),jE=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./flowDiagram-DWJPFMVM-BjEk7JcK.js");return{diagram:t}},__vite__mapDeps([10,11,9,12,13]));return{id:uC,diagram:e}},"loader"),GE={id:uC,detector:YE,loader:jE},XE=GE,dC="timeline",VE=y(e=>/^\s*timeline/.test(e),"detector"),ZE=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./timeline-definition-GMOUNBTQ-CWEAkGhb.js");return{diagram:t}},[]);return{id:dC,diagram:e}},"loader"),QE={id:dC,detector:VE,loader:ZE},KE=QE,fC="mindmap",JE=y(e=>/^\s*mindmap/.test(e),"detector"),t3=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./mindmap-definition-QFDTVHPH-Cuart2gs.js");return{diagram:t}},__vite__mapDeps([30,12,13]));return{id:fC,diagram:e}},"loader"),e3={id:fC,detector:JE,loader:t3},r3=e3,pC="kanban",i3=y(e=>/^\s*kanban/.test(e),"detector"),a3=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./kanban-definition-6JOO6SKY-C2g7cjfd.js");return{diagram:t}},__vite__mapDeps([31,11]));return{id:pC,diagram:e}},"loader"),s3={id:pC,detector:i3,loader:a3},o3=s3,gC="sankey",n3=y(e=>/^\s*sankey(-beta)?/.test(e),"detector"),l3=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./sankeyDiagram-XADWPNL6-4D4rvcjw.js");return{diagram:t}},[]);return{id:gC,diagram:e}},"loader"),h3={id:gC,detector:n3,loader:l3},c3=h3,mC="packet",u3=y(e=>/^\s*packet(-beta)?/.test(e),"detector"),d3=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./diagram-TYMM5635-BOJIcEla.js");return{diagram:t}},__vite__mapDeps([32,16,18,4,2]));return{id:mC,diagram:e}},"loader"),f3={id:mC,detector:u3,loader:d3},yC="radar",p3=y(e=>/^\s*radar-beta/.test(e),"detector"),g3=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./diagram-MMDJMWI5-DxJ3dga5.js");return{diagram:t}},__vite__mapDeps([33,16,18,4,2]));return{id:yC,diagram:e}},"loader"),m3={id:yC,detector:p3,loader:g3},CC="block",y3=y(e=>/^\s*block(-beta)?/.test(e),"detector"),C3=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./blockDiagram-DXYQGD6D-CgFuSL-z.js");return{diagram:t}},__vite__mapDeps([34,11,5,1,2]));return{id:CC,diagram:e}},"loader"),x3={id:CC,detector:y3,loader:C3},b3=x3,xC="treeView",k3=y(e=>/^\s*treeView-beta/.test(e),"detector"),T3=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./diagram-5BDNPKRD-C9IEP2hE.js");return{diagram:t}},__vite__mapDeps([35,16,17,18,4,2]));return{id:xC,diagram:e}},"loader"),w3={id:xC,detector:k3,loader:T3},_3=w3,bC="architecture",S3=y(e=>/^\s*architecture/.test(e),"detector"),v3=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./architectureDiagram-Q4EWVU46-DtqSqMGf.js");return{diagram:t}},__vite__mapDeps([36,16,18,4,2,7]));return{id:bC,diagram:e}},"loader"),B3={id:bC,detector:S3,loader:v3},L3=B3,kC="ishikawa",F3=y(e=>/^\s*ishikawa(-beta)?\b/i.test(e),"detector"),M3=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./ishikawaDiagram-UXIWVN3A-D59D4ZGk.js");return{diagram:t}},[]);return{id:kC,diagram:e}},"loader"),A3={id:kC,detector:F3,loader:M3},TC="venn",E3=y(e=>/^\s*venn-beta/.test(e),"detector"),$3=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./vennDiagram-DHZGUBPP-BCUB4Y59.js");return{diagram:t}},[]);return{id:TC,diagram:e}},"loader"),D3={id:TC,detector:E3,loader:$3},O3=D3,wC="treemap",I3=y(e=>/^\s*treemap/.test(e),"detector"),P3=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./diagram-G4DWMVQ6-BCLMvrx-.js");return{diagram:t}},__vite__mapDeps([37,13,16,18,4,2]));return{id:wC,diagram:e}},"loader"),R3={id:wC,detector:I3,loader:P3},_C="wardley-beta",N3=y(e=>/^\s*wardley-beta/i.test(e),"detector"),q3=y(async()=>{const{diagram:e}=await Ct(async()=>{const{diagram:t}=await import("./wardleyDiagram-NUSXRM2D-q0nyo3Bx.js");return{diagram:t}},__vite__mapDeps([38,16,18,4,2]));return{id:_C,diagram:e}},"loader"),z3={id:_C,detector:N3,loader:q3},W3=z3,Nd=!1,cn=y(()=>{Nd||(Nd=!0,Gs("error",UE,e=>e.toLowerCase().trim()==="error"),Gs("---",{db:{clear:y(()=>{},"clear")},styles:{},renderer:{draw:y(()=>{},"draw")},parser:{parse:y(()=>{throw new Error("Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks")},"parse")},init:y(()=>null,"init")},e=>e.toLowerCase().trimStart().startsWith("---")),tl(XE,r3,L3),tl(E5,o3,LE,_E,U5,K5,eE,aE,mE,bE,q5,I5,KE,X5,IE,EE,qE,lE,c3,f3,dE,b3,_3,m3,A3,R3,O3,W3))},"addDiagrams"),H3=y(async()=>{W.debug("Loading registered diagrams");const t=(await Promise.allSettled(Object.entries(Rr).map(async([r,{detector:i,loader:a}])=>{if(a)try{al(r)}catch{try{const{diagram:s,id:o}=await a();Gs(o,s,i)}catch(s){throw W.error(`Failed to load external diagram with key ${r}. Removing from detectors.`),delete Rr[r],s}}}))).filter(r=>r.status==="rejected");if(t.length>0){W.error(`Failed to load ${t.length} external diagrams`);for(const r of t)W.error(r);throw new Error(`Failed to load ${t.length} external diagrams`)}},"loadRegisteredDiagrams"),U3="graphics-document document";function SC(e,t){e.attr("role",U3),t!==""&&e.attr("aria-roledescription",t)}y(SC,"setA11yDiagramInfo");function vC(e,t,r,i){if(e.insert!==void 0){if(r){const a=`chart-desc-${i}`;e.attr("aria-describedby",a),e.insert("desc",":first-child").attr("id",a).text(r)}if(t){const a=`chart-title-${i}`;e.attr("aria-labelledby",a),e.insert("title",":first-child").attr("id",a).text(t)}}}y(vC,"addSVGa11yTitleDescription");var Pr,rh=(Pr=class{constructor(t,r,i,a,s){this.type=t,this.text=r,this.db=i,this.parser=a,this.renderer=s}static async fromText(t,r={}){var h,c;const i=At(),a=oh(t,i);t=fF(t)+`
300
+ `;try{al(a)}catch{const u=Ax(a);if(!u)throw new Zd(`Diagram ${a} not found.`);const{id:f,diagram:d}=await u();Gs(f,d)}const{db:s,parser:o,renderer:n,init:l}=al(a);return o.parser&&(o.parser.yy=s),(h=s.clear)==null||h.call(s),l==null||l(i),r.title&&((c=s.setDiagramTitle)==null||c.call(s,r.title)),await o.parse(t),new Pr(a,t,s,o,n)}async render(t,r){await this.renderer.draw(this.text,t,r,this)}getParser(){return this.parser}getType(){return this.type}},y(Pr,"Diagram"),Pr),qd=[],Y3=y(()=>{qd.forEach(e=>{e()}),qd=[]},"attachFunctions"),j3=y(e=>e.replace(/^\s*%%(?!{)[^\n]+\n?/gm,"").trimStart(),"cleanupComments");function BC(e){const t=e.match(Vd);if(!t)return{text:e,metadata:{}};let r=yv(t[1],{schema:mv})??{};r=typeof r=="object"&&!Array.isArray(r)?r:{};const i={};return r.displayMode&&(i.displayMode=r.displayMode.toString()),r.title&&(i.title=r.title.toString()),r.config&&(i.config=r.config),{text:e.slice(t[0].length),metadata:i}}y(BC,"extractFrontMatter");var G3=y(e=>e.replace(/\r\n?/g,`
301
+ `).replace(/<(\w+)([^>]*)>/g,(t,r,i)=>"<"+r+i.replace(/="([^"]*)"/g,"='$1'")+">"),"cleanupText"),X3=y(e=>{const{text:t,metadata:r}=BC(e),{displayMode:i,title:a,config:s={}}=r;return i&&(s.gantt||(s.gantt={}),s.gantt.displayMode=i),{title:a,config:s,text:t}},"processFrontmatter"),V3=y(e=>{const t=Be.detectInit(e)??{},r=Be.detectDirective(e,"wrap");return Array.isArray(r)?t.wrap=r.some(({type:i})=>i==="wrap"):(r==null?void 0:r.type)==="wrap"&&(t.wrap=!0),{text:tF(e),directive:t}},"processDirectives");function cc(e){const t=G3(e),r=X3(t),i=V3(r.text),a=jh(r.config,i.directive);return e=j3(i.text),{code:e,title:r.title,config:a}}y(cc,"preprocessDiagram");function LC(e){const t=new TextEncoder().encode(e),r=Array.from(t,i=>String.fromCodePoint(i)).join("");return btoa(r)}y(LC,"toBase64");var Z3=5e4,Q3="graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa",K3="sandbox",J3="loose",t$="http://www.w3.org/2000/svg",e$="http://www.w3.org/1999/xlink",r$="http://www.w3.org/1999/xhtml",i$="100%",a$="100%",s$="border:0;margin:0;",o$="margin:0",n$="allow-top-navigation-by-user-activation allow-popups",l$='The "iframe" tag is not supported by your browser.',h$=["foreignobject"],c$=["dominant-baseline"];function uc(e){const t=cc(e);return Ys(),s1(t.config??{}),t}y(uc,"processAndSetConfigs");async function FC(e,t){cn();try{const{code:r,config:i}=uc(e);return{diagramType:(await AC(r)).type,config:i}}catch(r){if(t!=null&&t.suppressErrors)return!1;throw r}}y(FC,"parse");var zd=y((e,t,r=[])=>`
302
+ .${e} ${t} { ${r.join(" !important; ")} !important; }`,"cssImportantStyles"),u$=y((e,t=new Map)=>{let r="";if(e.themeCSS!==void 0&&(r+=`
303
+ ${e.themeCSS}`),e.fontFamily!==void 0&&(r+=`
304
+ :root { --mermaid-font-family: ${e.fontFamily}}`),e.altFontFamily!==void 0&&(r+=`
305
+ :root { --mermaid-alt-font-family: ${e.altFontFamily}}`),t instanceof Map){const o=ne(e)?["> *","span"]:["rect","polygon","ellipse","circle","path"];t.forEach(n=>{Rd(n.styles)||o.forEach(l=>{r+=zd(n.id,l,n.styles)}),Rd(n.textStyles)||(r+=zd(n.id,"tspan",((n==null?void 0:n.textStyles)||[]).map(l=>l.replace("color","fill"))))})}return r},"createCssStyles"),d$=y((e,t,r,i)=>{const a=u$(e,r),s=_1(t,a,{...e.themeVariables,theme:e.theme,look:e.look},i);return Ql(d5(`${i}{${s}}`),p5)},"createUserStyles"),f$=y((e="",t,r)=>{let i=e;return!r&&!t&&(i=i.replace(/marker-end="url\([\d+./:=?A-Za-z-]*?#/g,'marker-end="url(#')),i=Yr(i),i=i.replace(/<br>/g,"<br/>"),i},"cleanUpSvgCode"),p$=y((e="",t)=>{var a,s;const r=(s=(a=t==null?void 0:t.viewBox)==null?void 0:a.baseVal)!=null&&s.height?t.viewBox.baseVal.height+"px":a$,i=LC(`<body style="${o$}">${e}</body>`);return`<iframe style="width:${i$};height:${r};${s$}" src="data:text/html;charset=UTF-8;base64,${i}" sandbox="${n$}">
306
+ ${l$}
307
+ </iframe>`},"putIntoIFrame"),Wd=y((e,t,r,i,a)=>{const s=e.append("div");s.attr("id",r),i&&s.attr("style",i);const o=s.append("svg").attr("id",t).attr("width","100%").attr("xmlns",t$);return a&&o.attr("xmlns:xlink",a),o.append("g"),e},"appendDivSvgG");function ih(e,t){return e.append("iframe").attr("id",t).attr("style","width: 100%; height: 100%;").attr("sandbox","")}y(ih,"sandboxedIframe");var g$=y((e,t,r,i)=>{var a,s,o;(a=e.getElementById(t))==null||a.remove(),(s=e.getElementById(r))==null||s.remove(),(o=e.getElementById(i))==null||o.remove()},"removeExistingElements"),m$=y(async function(e,t,r){var N,D,M,$,A,O;cn();const i=uc(t);t=i.code;const a=At();W.debug(a),t.length>((a==null?void 0:a.maxTextSize)??Z3)&&(t=Q3);const s="#"+e,o="i"+e,n="#"+o,l="d"+e,h="#"+l,c=y(()=>{const H=pt(f?n:h).node();H&&"remove"in H&&H.remove()},"removeTempElements");let u=pt("body");const f=a.securityLevel===K3,d=a.securityLevel===J3,p=a.fontFamily;if(r!==void 0){if(r&&(r.innerHTML=""),f){const F=ih(pt(r),o);u=pt(F.nodes()[0].contentDocument.body),u.node().style.margin=0}else u=pt(r);Wd(u,e,l,`font-family: ${p}`,e$)}else{if(g$(document,e,l,o),f){const F=ih(pt("body"),o);u=pt(F.nodes()[0].contentDocument.body),u.node().style.margin=0}else u=pt("body");Wd(u,e,l)}let g,m;try{g=await rh.fromText(t,{title:i.title})}catch(F){if(a.suppressErrorRendering)throw c(),F;g=await rh.fromText("error"),m=F}const C=u.select(h).node(),x=g.type,k=C.firstChild,w=k.firstChild,S=(D=(N=g.renderer).getClasses)==null?void 0:D.call(N,t,g),_=d$(a,x,S,s),T=document.createElement("style");T.innerHTML=_,k.insertBefore(T,w);try{await g.renderer.draw(t,e,"11.14.0",g)}catch(F){throw a.suppressErrorRendering?c():WE.draw(t,e,"11.14.0"),F}const B=u.select(`${h} svg`),z=($=(M=g.db).getAccTitle)==null?void 0:$.call(M),I=(O=(A=g.db).getAccDescription)==null?void 0:O.call(A);EC(x,B,z,I),u.select(`[id="${e}"]`).selectAll("foreignobject > *").attr("xmlns",r$);let E=u.select(h).node().innerHTML;if(W.debug("config.arrowMarkerAbsolute",a.arrowMarkerAbsolute),E=f$(E,f,cr(a.arrowMarkerAbsolute)),f){const F=u.select(h+" svg").node();E=p$(E,F)}else d||(E=$i.sanitize(E,{ADD_TAGS:h$,ADD_ATTR:c$,HTML_INTEGRATION_POINTS:{foreignobject:!0}}));if(Y3(),m)throw m;return c(),{diagramType:x,svg:E,bindFunctions:g.db.bindFunctions}},"render");function MC(e={}){var i;const t=qt({},e);t!=null&&t.fontFamily&&!((i=t.themeVariables)!=null&&i.fontFamily)&&(t.themeVariables||(t.themeVariables={}),t.themeVariables.fontFamily=t.fontFamily),i1(t),t!=null&&t.theme&&t.theme in ar?t.themeVariables=ar[t.theme].getThemeVariables(t.themeVariables):t&&(t.themeVariables=ar.default.getThemeVariables(t.themeVariables));const r=typeof t=="object"?r1(t):ef();ah(r.logLevel),cn()}y(MC,"initialize");var AC=y((e,t={})=>{const{code:r}=cc(e);return rh.fromText(r,t)},"getDiagramFromText");function EC(e,t,r,i){SC(t,e),vC(t,r,i,t.attr("id"))}y(EC,"addA11yInfo");var Gr=Object.freeze({render:m$,parse:FC,getDiagramFromText:AC,initialize:MC,getConfig:At,setConfig:rf,getSiteConfig:ef,updateSiteConfig:a1,reset:y(()=>{Ys()},"reset"),globalReset:y(()=>{Ys(Di)},"globalReset"),defaultConfig:Di});ah(At().logLevel);Ys(At());var y$=y((e,t,r)=>{W.warn(e),Yh(e)?(r&&r(e.str,e.hash),t.push({...e,message:e.str,error:e})):(r&&r(e),e instanceof Error&&t.push({str:e.message,message:e.message,hash:e.name,error:e}))},"handleError"),$C=y(async function(e={querySelector:".mermaid"}){try{await C$(e)}catch(t){if(Yh(t)&&W.error(t.str),me.parseError&&me.parseError(t),!e.suppressErrors)throw W.error("Use the suppressErrors option to suppress these errors"),t}},"run"),C$=y(async function({postRenderCallback:e,querySelector:t,nodes:r}={querySelector:".mermaid"}){const i=Gr.getConfig();W.debug(`${e?"":"No "}Callback function found`);let a;if(r)a=r;else if(t)a=document.querySelectorAll(t);else throw new Error("Nodes and querySelector are both undefined");W.debug(`Found ${a.length} diagrams`),(i==null?void 0:i.startOnLoad)!==void 0&&(W.debug("Start On Load: "+(i==null?void 0:i.startOnLoad)),Gr.updateSiteConfig({startOnLoad:i==null?void 0:i.startOnLoad}));const s=new Be.InitIDGenerator(i.deterministicIds,i.deterministicIDSeed);let o;const n=[];for(const l of Array.from(a)){if(W.info("Rendering diagram: "+l.id),l.getAttribute("data-processed"))continue;l.setAttribute("data-processed","true");const h=`mermaid-${s.next()}`;o=l.innerHTML,o=Vm(Be.entityDecode(o)).trim().replace(/<br\s*\/?>/gi,"<br/>");const c=Be.detectInit(o);c&&W.debug("Detected early reinit: ",c);try{const{svg:u,bindFunctions:f}=await PC(h,o,l);l.innerHTML=u,e&&await e(h),f&&f(l)}catch(u){y$(u,n,me.parseError)}}if(n.length>0)throw n[0]},"runThrowsErrors"),DC=y(function(e){Gr.initialize(e)},"initialize"),x$=y(async function(e,t,r){W.warn("mermaid.init is deprecated. Please use run instead."),e&&DC(e);const i={postRenderCallback:r,querySelector:".mermaid"};typeof t=="string"?i.querySelector=t:t&&(t instanceof HTMLElement?i.nodes=[t]:i.nodes=t),await $C(i)},"init"),b$=y(async(e,{lazyLoad:t=!0}={})=>{cn(),tl(...e),t===!1&&await H3()},"registerExternalDiagrams"),OC=y(function(){if(me.startOnLoad){const{startOnLoad:e}=Gr.getConfig();e&&me.run().catch(t=>W.error("Mermaid failed to initialize",t))}},"contentLoaded");typeof document<"u"&&window.addEventListener("load",OC,!1);var k$=y(function(e){me.parseError=e},"setParseErrorHandler"),Oo=[],Qn=!1,IC=y(async()=>{if(!Qn){for(Qn=!0;Oo.length>0;){const e=Oo.shift();if(e)try{await e()}catch(t){W.error("Error executing queue",t)}}Qn=!1}},"executeQueue"),T$=y(async(e,t)=>new Promise((r,i)=>{const a=y(()=>new Promise((s,o)=>{Gr.parse(e,t).then(n=>{s(n),r(n)},n=>{var l;W.error("Error parsing",n),(l=me.parseError)==null||l.call(me,n),o(n),i(n)})}),"performCall");Oo.push(a),IC().catch(i)}),"parse"),PC=y((e,t,r)=>new Promise((i,a)=>{const s=y(()=>new Promise((o,n)=>{Gr.render(e,t,r).then(l=>{o(l),i(l)},l=>{var h;W.error("Error parsing",l),(h=me.parseError)==null||h.call(me,l),n(l),a(l)})}),"performCall");Oo.push(s),IC().catch(a)}),"render"),w$=y(()=>Object.keys(Rr).map(e=>({id:e})),"getRegisteredDiagramsMetadata"),me={startOnLoad:!0,mermaidAPI:Gr,parse:T$,render:PC,init:x$,run:$C,registerExternalDiagrams:b$,registerLayoutLoaders:qy,initialize:DC,parseError:void 0,contentLoaded:OC,setParseErrorHandler:k$,detectType:oh,registerIconPacks:bM,getRegisteredDiagramsMetadata:w$},eD=me;/*! Check if previously processed *//*!
308
+ * Wait for document loaded before starting the execution
309
+ */export{cf as $,$i as A,S1 as B,A$ as C,yr as D,v$ as E,ex as F,At as G,$1 as H,jh as I,mv as J,tf as K,sF as L,cS as M,tn as N,q$ as O,Qf as P,z$ as Q,Tw as R,Px as S,fw as T,TM as U,J_ as V,Ma as W,F$ as X,f1 as Y,ZL as Z,y as _,B1 as a,no as a$,zc as a0,xl as a1,aF as a2,Ee as a3,R as a4,P as a5,k1 as a6,df as a7,GM as a8,Iy as a9,L$ as aA,Jo as aB,_o as aC,Sm as aD,XC as aE,Ja as aF,bM as aG,xM as aH,R$ as aI,$$ as aJ,E$ as aK,I$ as aL,tx as aM,O$ as aN,sp as aO,_h as aP,Uo as aQ,Mw as aR,Fw as aS,Ri as aT,Lw as aU,Bw as aV,lo as aW,Xa as aX,Th as aY,kh as aZ,di as a_,Q$ as aa,Cv as ab,ne as ac,dr as ad,la as ae,Gh as af,Am as ag,Yr as ah,Om as ai,K as aj,Xf as ak,Zf as al,P$ as am,tt as an,Im as ao,Ct as ap,B$ as aq,VA as ar,Z$ as as,K$ as at,X$ as au,rt as av,V$ as aw,_A as ax,xA as ay,CA as az,v1 as b,D$ as b0,N$ as b1,_L as b2,wm as b3,mm as b4,LB as b5,ko as b6,FB as b7,Qa as b8,Ar as b9,th as bA,YL as bB,RL as bC,GL as bD,Rh as bE,VL as bF,S$ as bG,xL as ba,Gu as bb,Qr as bc,MB as bd,Nh as be,BB as bf,$B as bg,Yi as bh,wL as bi,jL as bj,RB as bk,NL as bl,Ph as bm,Rd as bn,Ui as bo,ML as bp,C5 as bq,Za as br,wo as bs,wr as bt,Vo as bu,Wu as bv,qh as bw,Cm as bx,Tm as by,SB as bz,bt as c,pt as d,uf as e,qt as f,F1 as g,hr as h,Ae as i,kv as j,Ya as k,W as l,eD as m,$m as n,Ua as o,M$ as p,tD as q,J$ as r,L1 as s,M1 as t,Be as u,A1 as v,lF as w,yv as x,fA as y,W$ as z};