ryugi-artifacts 1.69.0 → 1.70.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (340) hide show
  1. package/dist/cli.cjs +3 -3
  2. package/dist/server.cjs +7 -2
  3. package/dist/viewer/{AgentStatusPill-CxFpJS9T.js → AgentStatusPill-exn8kG-H.js} +1 -1
  4. package/dist/viewer/ArtboardLayout-Dz0spzAj.js +12 -0
  5. package/dist/viewer/ArtifactList-DKmeVnKi.js +2 -0
  6. package/dist/viewer/{AutoPublishPrompt-DkGEIW9t.js → AutoPublishPrompt-BYAg2V0y.js} +1 -1
  7. package/dist/viewer/{Avatar-VUQPY4DD.js → Avatar-Cr9OW8YH.js} +1 -1
  8. package/dist/viewer/{Avatar-BhOg2BXZ.js → Avatar-NMdjRnIS.js} +1 -1
  9. package/dist/viewer/{BottomSheet-AqG81d_M.js → BottomSheet-BQnGJL4p.js} +1 -1
  10. package/dist/viewer/{Canvas-4Utk2C18.js → Canvas-DxaQjjSK.js} +1 -1
  11. package/dist/viewer/{CompositeItem-ClMglprA.js → CompositeItem-tvyaiM7D.js} +1 -1
  12. package/dist/viewer/DocumentLayout-_U2M-QV_.js +2 -0
  13. package/dist/viewer/DocumentPage-ox4EQvxU.js +4 -0
  14. package/dist/viewer/DropdownMenu-DQRhgqL-.js +1 -0
  15. package/dist/viewer/{HtmlLayout-89ZuJNxJ.js → HtmlLayout-DzcNJHBz.js} +1 -1
  16. package/dist/viewer/{MenuSubmenuTrigger-B9c8QfBG.js → MenuSubmenuTrigger-CFAM5XEZ.js} +1 -1
  17. package/dist/viewer/{MenuTrigger-yVEYn1Ao.js → MenuTrigger-COssWqPW.js} +1 -1
  18. package/dist/viewer/{PhoneArtboardBar-Bzffd2nB.js → PhoneArtboardBar-B6JoWeSs.js} +1 -1
  19. package/dist/viewer/{PhoneSheet-CN4Ewszx.js → PhoneSheet-F7YTU--u.js} +1 -1
  20. package/dist/viewer/{Popover-J_7ZaGFR.js → Popover-4xoki5-K.js} +1 -1
  21. package/dist/viewer/PreviewLayout-CTH3onR8.js +2 -0
  22. package/dist/viewer/{Segmented-DhJdw1_a.js → Segmented-CFwxjVOk.js} +1 -1
  23. package/dist/viewer/{Select-Cqb37-IZ.js → Select-CwMZ_V48.js} +1 -1
  24. package/dist/viewer/{SelectScrollUpArrow-DYO27Q2D.js → SelectScrollUpArrow-D1wI2boK.js} +1 -1
  25. package/dist/viewer/{SettingsDialog-BpwMMImH.js → SettingsDialog-ytisgF60.js} +1 -1
  26. package/dist/viewer/{SnapshotDocument-Cca8g4SA.js → SnapshotDocument-IbfxlwGq.js} +1 -1
  27. package/dist/viewer/{SplitShell-lfa8K-76.js → SplitShell-BT_RNQiE.js} +1 -1
  28. package/dist/viewer/{ThreadView-CNiDFkdG.js → ThreadView-CxcjZsZO.js} +1 -1
  29. package/dist/viewer/{TooltipPopup-DsKnBNAK.js → TooltipPopup-D7gvHCZl.js} +1 -1
  30. package/dist/viewer/{VirtualizedEditor-uWe43zaI-lgt127eM.js → VirtualizedEditor-uWe43zaI-BMW7pyKh.js} +1 -1
  31. package/dist/viewer/{VirtualizedRenderer-C_d95FXi-GNEopmGk.js → VirtualizedRenderer-C_d95FXi-D1_QNgkv.js} +1 -1
  32. package/dist/viewer/{WarningsBadge-DT8IiYtX.js → WarningsBadge-yykGlxIS.js} +1 -1
  33. package/dist/viewer/WhiteboardLayout-DdKyBMil.js +3 -0
  34. package/dist/viewer/{WritingCursor-DQcBMO0U.js → WritingCursor-BmvJsfI4.js} +1 -1
  35. package/dist/viewer/{abnfDiagram-VCTEODGH-CTyAnl0Z.js → abnfDiagram-VCTEODGH-BcWo9FwK.js} +1 -1
  36. package/dist/viewer/{agentLook-C2_12glW.js → agentLook-t-qk7xG-.js} +1 -1
  37. package/dist/viewer/{anchor-B2Eea6vf.js → anchor-CMDdppxq.js} +1 -1
  38. package/dist/viewer/{ar-SA-G6X2FPQ2-Co8NUjyx.js → ar-SA-G6X2FPQ2-Cm_ExiPk.js} +1 -1
  39. package/dist/viewer/{architecture-7GRP2DOG-B0zVjmxn.js → architecture-7GRP2DOG-B0ELn-r9.js} +1 -1
  40. package/dist/viewer/{architectureDiagram-5GKGNRK7-CGcFQF9y.js → architectureDiagram-5GKGNRK7-pjk1bmyn.js} +1 -1
  41. package/dist/viewer/{az-AZ-76LH7QW2-De3Qkr8D.js → az-AZ-76LH7QW2-C3xDoCfK.js} +1 -1
  42. package/dist/viewer/{bg-BG-XCXSNQG7-BzK_v3Xv.js → bg-BG-XCXSNQG7-BuqoExRt.js} +1 -1
  43. package/dist/viewer/{blockDiagram-I7D4REHJ-mTBluH4Q.js → blockDiagram-I7D4REHJ-Bt5Fgmbw.js} +1 -1
  44. package/dist/viewer/{bn-BD-2XOGV67Q-BDqCkFBJ.js → bn-BD-2XOGV67Q-Cb6R-JhO.js} +1 -1
  45. package/dist/viewer/{c4Diagram-7LVT6UL2-D-nVvYcu.js → c4Diagram-7LVT6UL2-DVoqgVNh.js} +1 -1
  46. package/dist/viewer/{ca-ES-6MX7JW3Y-Di897XK8.js → ca-ES-6MX7JW3Y-C9x3VZP6.js} +1 -1
  47. package/dist/viewer/{channel-D9zHsUWH.js → channel-DH0VKMTa.js} +8 -8
  48. package/dist/viewer/channel-fe5QTu-s.js +1 -0
  49. package/dist/viewer/{chunk-4HAMMTFA-QTbQqNtn.js → chunk-4HAMMTFA-CTdlWrtX.js} +1 -1
  50. package/dist/viewer/{chunk-75Z2AOVW-BbYnGlO9.js → chunk-75Z2AOVW-C_A1Se9D.js} +1 -1
  51. package/dist/viewer/{chunk-DU6HZSFF-D25kbUvc.js → chunk-DU6HZSFF-Dr7PaN7b.js} +1 -1
  52. package/dist/viewer/{chunk-EIO257PC-BqMFp5wN.js → chunk-EIO257PC-oHJkbpFs.js} +1 -1
  53. package/dist/viewer/{chunk-F27PBJKO-C7JmXEA_.js → chunk-F27PBJKO-BBCDjN53.js} +1 -1
  54. package/dist/viewer/{chunk-GMAD6QVW-C27INOB_.js → chunk-GMAD6QVW-BFHBOVJq.js} +1 -1
  55. package/dist/viewer/{chunk-GVQU2GXP-CEY5vytX.js → chunk-GVQU2GXP-BIpEZyzS.js} +1 -1
  56. package/dist/viewer/{chunk-IMKFNOWR-BQSAfnnl.js → chunk-IMKFNOWR-KEawvx8K.js} +1 -1
  57. package/dist/viewer/{chunk-L3NEJ4N5-DlFoBxMY.js → chunk-L3NEJ4N5-IwBcwkuk.js} +1 -1
  58. package/dist/viewer/{chunk-OSK3NFVY-F3_Phybw.js → chunk-OSK3NFVY-C3k_p7-w.js} +1 -1
  59. package/dist/viewer/{chunk-P2QGCYS3-09egvNok.js → chunk-P2QGCYS3-Dtm_7Lz7.js} +1 -1
  60. package/dist/viewer/{chunk-POPQ4Y6H-CV8YIoqC.js → chunk-POPQ4Y6H-CytCoNkh.js} +1 -1
  61. package/dist/viewer/{chunk-PWAF6VOD-Bz8UB2mc.js → chunk-PWAF6VOD-CyHOdyql.js} +1 -1
  62. package/dist/viewer/{chunk-SHT3W25Y-DDp6zMvV.js → chunk-SHT3W25Y-DD7pl4JI.js} +1 -1
  63. package/dist/viewer/{chunk-SVP7TREG-C8P_HXcE.js → chunk-SVP7TREG-Bu4mLQNH.js} +1 -1
  64. package/dist/viewer/{chunk-TICWLB2K-CqNIbLdD.js → chunk-TICWLB2K-sZ8FCdF0.js} +1 -1
  65. package/dist/viewer/classDiagram-ZZMXUADV-B-zT7lnC.js +1 -0
  66. package/dist/viewer/classDiagram-v2-VYDZK3BY-B-zT7lnC.js +1 -0
  67. package/dist/viewer/{cs-CZ-2BRQDIVT-BqCK2YiO.js → cs-CZ-2BRQDIVT-BYzmp2zB.js} +1 -1
  68. package/dist/viewer/{cynefin-OW5HDTMX-Cj8F5cxd.js → cynefin-OW5HDTMX-BRRxGfUD.js} +1 -1
  69. package/dist/viewer/{cynefinDiagram-5FMLGOSQ-ao8tcFtS.js → cynefinDiagram-5FMLGOSQ-BJJG-W2c.js} +1 -1
  70. package/dist/viewer/{da-DK-5WZEPLOC-D8GWiO3u.js → da-DK-5WZEPLOC-BQMUVHri.js} +1 -1
  71. package/dist/viewer/{dagre-GXQ25YYZ-DsGmxha_.js → dagre-GXQ25YYZ-18YALgQ_.js} +1 -1
  72. package/dist/viewer/{de-DE-XR44H4JA-OJKx5xur.js → de-DE-XR44H4JA-CXVFrfP-.js} +1 -1
  73. package/dist/viewer/{diagram-S7CK7UJ4-BPqNSGqm.js → diagram-S7CK7UJ4-BxB2LRSe.js} +1 -1
  74. package/dist/viewer/{diagram-UQ7AKVKN-Hyylpo16.js → diagram-UQ7AKVKN-BcJ9Tkbs.js} +1 -1
  75. package/dist/viewer/{diagram-VSXAHHWV-CqqVLGLK.js → diagram-VSXAHHWV-_UeBcZmY.js} +1 -1
  76. package/dist/viewer/{diagram-VX7I27RA-QDUSbpnl.js → diagram-VX7I27RA-Bc9iy24S.js} +1 -1
  77. package/dist/viewer/{diagram-Z3DM3KII-BlSnfIUw.js → diagram-Z3DM3KII-gU89rmSx.js} +1 -1
  78. package/dist/viewer/{dist-PC_089aX.js → dist-0mKY9eI7.js} +1 -1
  79. package/dist/viewer/{dist-BFQmsjpz.js → dist-B01tJOMA.js} +1 -1
  80. package/dist/viewer/{dist-8PA9S6LL.js → dist-B2jUGLcW.js} +1 -1
  81. package/dist/viewer/{dist-y47EP8TD.js → dist-BhkEYAHc.js} +1 -1
  82. package/dist/viewer/{dist-dHcM14_b.js → dist-Bo6d3UKT.js} +1 -1
  83. package/dist/viewer/{dist-BLAIDSVI.js → dist-BqnvFgk0.js} +1 -1
  84. package/dist/viewer/{dist-Cwm7m3VK.js → dist-C0qQs54I.js} +1 -1
  85. package/dist/viewer/{dist-BjVw2B6k.js → dist-C3CTurMw.js} +1 -1
  86. package/dist/viewer/{dist-BKcrjsO1.js → dist-C3WYDtp3.js} +1 -1
  87. package/dist/viewer/{dist-CY5pHbTR.js → dist-COTHq9_Y.js} +1 -1
  88. package/dist/viewer/{dist-DS3MMXtI.js → dist-CRyNsNEn.js} +1 -1
  89. package/dist/viewer/{dist-DlY6E9WS.js → dist-CTW5Mm7j.js} +1 -1
  90. package/dist/viewer/{dist-C6PBT5lE.js → dist-D3D--6Bp.js} +1 -1
  91. package/dist/viewer/{dist-Bo8QJSW2.js → dist-DJY0rxct.js} +1 -1
  92. package/dist/viewer/{dist-D8bHZTnA.js → dist-DJY6L8B9.js} +1 -1
  93. package/dist/viewer/{dist-Cc-_5Hcx.js → dist-DVq4uFIZ.js} +1 -1
  94. package/dist/viewer/{dist-DpV8-atf.js → dist-DZdqkKNN.js} +1 -1
  95. package/dist/viewer/{dist-Bot6IVVV.js → dist-DcqWCvRw.js} +1 -1
  96. package/dist/viewer/{dist-CwxBiwOj.js → dist-DhcQ70Kn.js} +1 -1
  97. package/dist/viewer/{dist-BB7KGjDd.js → dist-GsD7M9aH.js} +1 -1
  98. package/dist/viewer/{dist-CnQsaM53.js → dist-Hb3V0HyK.js} +1 -1
  99. package/dist/viewer/{dist-XKj_gvVl.js → dist-QjnQrlMe.js} +4 -4
  100. package/dist/viewer/{dist-BIiCOFkh.js → dist-_PSM37a1.js} +1 -1
  101. package/dist/viewer/{dist-CdS13Sm9.js → dist-hFUF3Lsa.js} +1 -1
  102. package/dist/viewer/{ebnfDiagram-PWID7BFC-Cv8jFIx3.js → ebnfDiagram-PWID7BFC-C8HSoSRy.js} +1 -1
  103. package/dist/viewer/{el-GR-BZB4AONW-Bgcc_mhT.js → el-GR-BZB4AONW-ow3fFVLT.js} +1 -1
  104. package/dist/viewer/{en-B4ZKOASM-xfJgNr4J.js → en-B4ZKOASM-CaY3r9HU.js} +1 -1
  105. package/dist/viewer/{erDiagram-RLTQ6QDP-DlKwxifM.js → erDiagram-RLTQ6QDP-BxJx7rlQ.js} +1 -1
  106. package/dist/viewer/{es-ES-U4NZUMDT-DjVCDf-d.js → es-ES-U4NZUMDT-BMjMaVCY.js} +1 -1
  107. package/dist/viewer/{eu-ES-A7QVB2H4-B9DLpn4i.js → eu-ES-A7QVB2H4-CM4bkpMu.js} +1 -1
  108. package/dist/viewer/{eventmodeling-NTZA5JFV-DBsen_iq.js → eventmodeling-NTZA5JFV-DnbDCfB2.js} +1 -1
  109. package/dist/viewer/{fa-IR-HGAKTJCU-mcJehgzb.js → fa-IR-HGAKTJCU-BLD2tQpT.js} +1 -1
  110. package/dist/viewer/{fi-FI-Z5N7JZ37-DNSkiCdk.js → fi-FI-Z5N7JZ37-Bgn7EPoz.js} +1 -1
  111. package/dist/viewer/flowDiagram-HODETNUW-CXlFZEEj.js +1 -0
  112. package/dist/viewer/{fr-FR-RHASNOE6-Bpxco8-f.js → fr-FR-RHASNOE6-Bkw82-6W.js} +1 -1
  113. package/dist/viewer/{ganttDiagram-EL5Y4UJY-B9_jTP-f.js → ganttDiagram-EL5Y4UJY-DOR_e0je.js} +1 -1
  114. package/dist/viewer/{gitGraph-4MIJSDKK-DQ5l_Czp.js → gitGraph-4MIJSDKK-SVRQ5W4D.js} +1 -1
  115. package/dist/viewer/{gitGraphDiagram-WWUBYQGX-CNheUmFp.js → gitGraphDiagram-WWUBYQGX-CDiQ0mCt.js} +1 -1
  116. package/dist/viewer/{gl-ES-HMX3MZ6V-BDlXQ8Mo.js → gl-ES-HMX3MZ6V-BLzHqZN8.js} +1 -1
  117. package/dist/viewer/{he-IL-6SHJWFNN-D_oWBOT_.js → he-IL-6SHJWFNN-D8wU25du.js} +1 -1
  118. package/dist/viewer/{hi-IN-IWLTKZ5I-B00j5Akq.js → hi-IN-IWLTKZ5I-BL-e61Xu.js} +1 -1
  119. package/dist/viewer/{hu-HU-A5ZG7DT2-Dir0Uxpm.js → hu-HU-A5ZG7DT2-DbYToYgQ.js} +1 -1
  120. package/dist/viewer/{id-ID-SAP4L64H-CIWlaa2K.js → id-ID-SAP4L64H-CCT_QszX.js} +1 -1
  121. package/dist/viewer/{image-GAAHSSAO-eNNIIQuo.js → image-GAAHSSAO-DKoD4XKV.js} +1 -1
  122. package/dist/viewer/index.html +5 -5
  123. package/dist/viewer/index.js +2 -2
  124. package/dist/viewer/index2.css +1 -1
  125. package/dist/viewer/index3.css +88 -0
  126. package/dist/viewer/{info-A6RAGUB7-Cg2ZMBgH.js → info-A6RAGUB7-CX2C9N30.js} +1 -1
  127. package/dist/viewer/{infoDiagram-27XIBGKW-D4PQhgAE.js → infoDiagram-27XIBGKW-CN86my9R.js} +1 -1
  128. package/dist/viewer/{ishikawaDiagram-5VMMS53U-ST2q8zVR.js → ishikawaDiagram-5VMMS53U-5BluWj2f.js} +1 -1
  129. package/dist/viewer/{it-IT-JPQ66NNP-pmEG31XC.js → it-IT-JPQ66NNP-afXtP8Ww.js} +1 -1
  130. package/dist/viewer/{ja-JP-DBVTYXUO-B4zqTUsM.js → ja-JP-DBVTYXUO-DekQisaL.js} +1 -1
  131. package/dist/viewer/{journeyDiagram-3NMN7TZE-jw9cozQW.js → journeyDiagram-3NMN7TZE-CJC3KFyX.js} +1 -1
  132. package/dist/viewer/{kaa-6HZHGXH3-BbZXuqjx.js → kaa-6HZHGXH3-tRph-_T2.js} +1 -1
  133. package/dist/viewer/{kab-KAB-ZGHBKWFO-B6Dpy25G.js → kab-KAB-ZGHBKWFO-BE4QoOsA.js} +1 -1
  134. package/dist/viewer/{kanban-definition-UXKFOSKX-kKtBGERG.js → kanban-definition-UXKFOSKX-B18ysZ84.js} +1 -1
  135. package/dist/viewer/{kk-KZ-P5N5QNE5-BlT2i9fi.js → kk-KZ-P5N5QNE5-CVRotJxc.js} +1 -1
  136. package/dist/viewer/{km-KH-HSX4SM5Z-It93cDWb.js → km-KH-HSX4SM5Z-hAYTx672.js} +1 -1
  137. package/dist/viewer/{ko-KR-MTYHY66A-BE5d6K1R.js → ko-KR-MTYHY66A-QEVtuRm5.js} +1 -1
  138. package/dist/viewer/{ku-TR-6OUDTVRD-CyJeB7Dj.js → ku-TR-6OUDTVRD-CRm854Ze.js} +1 -1
  139. package/dist/viewer/{local-split-host-DwGe1ki5.js → local-split-host-B8nXcoph.js} +1 -1
  140. package/dist/viewer/{lt-LT-XHIRWOB4-B90xeOxU.js → lt-LT-XHIRWOB4-CKPgIz76.js} +1 -1
  141. package/dist/viewer/{lv-LV-5QDEKY6T-CItjDmqr.js → lv-LV-5QDEKY6T-ChfyCJQM.js} +1 -1
  142. package/dist/viewer/{mermaid-parser.core-0b8QyWBB.js → mermaid-parser.core-BVnYCq41.js} +3 -3
  143. package/dist/viewer/{mindmap-definition-YA3MSWOX-aI29Qvpk.js → mindmap-definition-YA3MSWOX-DHv3E1P_.js} +1 -1
  144. package/dist/viewer/{mr-IN-CRQNXWMA-Tce1KbsQ.js → mr-IN-CRQNXWMA-BJLGlD17.js} +1 -1
  145. package/dist/viewer/{my-MM-5M5IBNSE-CpUB2CXI.js → my-MM-5M5IBNSE-9rLlVOlt.js} +1 -1
  146. package/dist/viewer/{nb-NO-T6EIAALU-DsRuGO1k.js → nb-NO-T6EIAALU-B8VMz4zh.js} +1 -1
  147. package/dist/viewer/{nl-NL-IS3SIHDZ-BjF2156S.js → nl-NL-IS3SIHDZ-DqLxBYZV.js} +1 -1
  148. package/dist/viewer/{nn-NO-6E72VCQL-CGeF_3vr.js → nn-NO-6E72VCQL-Bo0PPFBQ.js} +1 -1
  149. package/dist/viewer/{oc-FR-POXYY2M6-DLnQnEGu.js → oc-FR-POXYY2M6-CWWRWFHX.js} +1 -1
  150. package/dist/viewer/{pa-IN-N4M65BXN-BAx2ywdg.js → pa-IN-N4M65BXN-DT0tg3Sk.js} +1 -1
  151. package/dist/viewer/{packet-AYTQ26CC-DK170Gd5.js → packet-AYTQ26CC-KGzO-wcr.js} +1 -1
  152. package/dist/viewer/{parseTrigger-YW1R9ofU.js → parseTrigger-Bu-PV9CL.js} +1 -1
  153. package/dist/viewer/{pegDiagram-XKGWAZYB-DHp6Wg_9.js → pegDiagram-XKGWAZYB-Dic4eBsi.js} +1 -1
  154. package/dist/viewer/percentages-BXMCSKIN-BS0t4tWg.js +1 -0
  155. package/dist/viewer/{pie-WAS4IAKB-BSUWPbAv.js → pie-WAS4IAKB-BYfJrbuD.js} +1 -1
  156. package/dist/viewer/{pieDiagram-E7YTZNPT-wfRRTiyk.js → pieDiagram-E7YTZNPT-CjUaUWV2.js} +1 -1
  157. package/dist/viewer/{pl-PL-T2D74RX3-BiWBdXLi.js → pl-PL-T2D74RX3-Ch27cnOo.js} +1 -1
  158. package/dist/viewer/preview.html +4 -4
  159. package/dist/viewer/preview.js +1 -1
  160. package/dist/viewer/{prod-CLoF9GCs.js → prod-TT-J6Nam.js} +8 -8
  161. package/dist/viewer/{pt-BR-5N22H2LF-CQSzKbCy.js → pt-BR-5N22H2LF-8J6Vfb7V.js} +1 -1
  162. package/dist/viewer/{pt-PT-UZXXM6DQ-CIlCAlTv.js → pt-PT-UZXXM6DQ-BX7qQNlR.js} +1 -1
  163. package/dist/viewer/{quadrantDiagram-AXDQQJYC-BtPMYaDQ.js → quadrantDiagram-AXDQQJYC-r9uBJJoA.js} +1 -1
  164. package/dist/viewer/{radar-RG4KPBEZ-BcVxV4zy.js → radar-RG4KPBEZ-DDBCvrzl.js} +1 -1
  165. package/dist/viewer/{railroad-74A4TZTK-CTa8S3gO.js → railroad-74A4TZTK-DHdJAn7o.js} +1 -1
  166. package/dist/viewer/{railroad-abnf-HS5TGJTU-OAwQkYAd.js → railroad-abnf-HS5TGJTU-D9wWd5uO.js} +1 -1
  167. package/dist/viewer/{railroad-ebnf-LZEXJU2U-C5cc5X65.js → railroad-ebnf-LZEXJU2U-D-NZ6dqJ.js} +1 -1
  168. package/dist/viewer/{railroad-peg-WCYAUIDC-BDnKRxE1.js → railroad-peg-WCYAUIDC-CyPMQZm7.js} +1 -1
  169. package/dist/viewer/{railroadDiagram-O6MQD6OU-jnRSJdUv.js → railroadDiagram-O6MQD6OU-CWrubsQf.js} +1 -1
  170. package/dist/viewer/{ref-cwone_vf.js → ref-BF7Dk-nb.js} +1 -1
  171. package/dist/viewer/{requirementDiagram-BXWQKSXE-BNTKDL1i.js → requirementDiagram-BXWQKSXE-YIdQ9sc_.js} +1 -1
  172. package/dist/viewer/{ro-RO-JPDTUUEW-QX3jx-nb.js → ro-RO-JPDTUUEW-2Pp-dKmW.js} +1 -1
  173. package/dist/viewer/route-CDT5H7Dv.js +64 -0
  174. package/dist/viewer/{route-messages-DNqJY8RF.js → route-messages-Bgmu6wjw.js} +1 -1
  175. package/dist/viewer/{ru-RU-B4JR7IUQ-C9FGD7Cs.js → ru-RU-B4JR7IUQ-DPkLOvY0.js} +1 -1
  176. package/dist/viewer/{sankeyDiagram-P5KCCOFB-Sqlj0O4h.js → sankeyDiagram-P5KCCOFB-BQftNXO2.js} +1 -1
  177. package/dist/viewer/{selection--wknfKoX.js → selection-BTJrtSto.js} +1 -1
  178. package/dist/viewer/{sequenceDiagram-WJ2MYXX4-CPdR8yLJ.js → sequenceDiagram-WJ2MYXX4-C90CSvsu.js} +1 -1
  179. package/dist/viewer/{si-LK-N5RQ5JYF-f_2YLEad.js → si-LK-N5RQ5JYF-DjQ-ynCO.js} +1 -1
  180. package/dist/viewer/{sk-SK-C5VTKIMK-DkKosukU.js → sk-SK-C5VTKIMK-Do9H8uzR.js} +1 -1
  181. package/dist/viewer/{sl-SI-NN7IZMDC-DMIQDLDl.js → sl-SI-NN7IZMDC-bJ5rRome.js} +1 -1
  182. package/dist/viewer/{split-url-EQlIwqCq.js → split-url-D0Eu87y4.js} +3 -3
  183. package/dist/viewer/{stateDiagram-D77RDMKH-Dk8vgDDZ.js → stateDiagram-D77RDMKH-pBFTeHBj.js} +1 -1
  184. package/dist/viewer/stateDiagram-v2-MP3YSRHH-aanK4VsX.js +1 -0
  185. package/dist/viewer/subset-shared.chunk-BiJjRqIa.js +1 -0
  186. package/dist/viewer/{subset-worker.chunk-B_8bLook.js → subset-worker.chunk-3zYap8Q-.js} +1 -1
  187. package/dist/viewer/{sv-SE-XGPEYMSR-B7-5iBmq.js → sv-SE-XGPEYMSR-C0oEs72p.js} +1 -1
  188. package/dist/viewer/{swimlanes-42K2YHIH-C8ikgnYd.js → swimlanes-42K2YHIH-CTsMizz_.js} +1 -1
  189. package/dist/viewer/swimlanesDiagram-VR7AAH4N-Bgny_WIB.js +8 -0
  190. package/dist/viewer/{ta-IN-2NMHFXQM-CCuxmYHa.js → ta-IN-2NMHFXQM-B3AATr70.js} +1 -1
  191. package/dist/viewer/{th-TH-HPSO5L25-555yyoqZ.js → th-TH-HPSO5L25-DQBS-yab.js} +1 -1
  192. package/dist/viewer/{timeline-definition-24CTP7MA-C2dpylBO.js → timeline-definition-24CTP7MA-C-XiBPgr.js} +1 -1
  193. package/dist/viewer/{tr-TR-DEFEU3FU-BzupxUte.js → tr-TR-DEFEU3FU-ag7nD5kA.js} +1 -1
  194. package/dist/viewer/{treeView-Q6P3EWNA-Bo2ovp6d.js → treeView-Q6P3EWNA-SVlfuIv-.js} +1 -1
  195. package/dist/viewer/{treemap-WGGIJYW6-B_JgUt2a.js → treemap-WGGIJYW6-_ZShzHPs.js} +1 -1
  196. package/dist/viewer/{uk-UA-QMV73CPH-DRep9RrQ.js → uk-UA-QMV73CPH-BSQfUSoA.js} +1 -1
  197. package/dist/viewer/{useAriaLabelledBy-qrGtdh85.js → useAriaLabelledBy-BuWax2Z2.js} +1 -1
  198. package/dist/viewer/{useArtifactFeed-C3070Mi8.js → useArtifactFeed-BDiYn0gP.js} +1 -1
  199. package/dist/viewer/useCloudStatus-JY8n58HL.js +1 -0
  200. package/dist/viewer/{useOpenInteractionType-B0XlD3Xc.js → useOpenInteractionType-DH5mUVhj.js} +1 -1
  201. package/dist/viewer/{useTranslation-D3df1rHG.js → useTranslation-BNqJXci1.js} +1 -1
  202. package/dist/viewer/{useTypeFavicon-COeOH_8h.js → useTypeFavicon-B3gDp1sZ.js} +1 -1
  203. package/dist/viewer/{vennDiagram-4TSXK5OY-BmwVNbSU.js → vennDiagram-4TSXK5OY-BV0PYWnH.js} +1 -1
  204. package/dist/viewer/{vi-VN-M7AON7JQ-HxuRLuM7.js → vi-VN-M7AON7JQ-Dl7QA_Y_.js} +1 -1
  205. package/dist/viewer/{view-Q3sf2djn.js → view--v3LsuO9.js} +1 -1
  206. package/dist/viewer/{viewport-CFJHn_Y6-CLCrXOsP.js → viewport-CFJHn_Y6-D8gntZjd.js} +1 -1
  207. package/dist/viewer/{wardley-WFR3VGLG-D6GPmsYf.js → wardley-WFR3VGLG-BNvAuofQ.js} +1 -1
  208. package/dist/viewer/{wardleyDiagram-VM6X3IG4-BL1YKfSh.js → wardleyDiagram-VM6X3IG4-B12XuiXU.js} +1 -1
  209. package/dist/viewer/{xychartDiagram-S5SC5T6Z-9WjSzaRU.js → xychartDiagram-S5SC5T6Z-CNASGt-y.js} +1 -1
  210. package/dist/viewer/{zh-CN-LNUGB5OW-C_gHexkj.js → zh-CN-LNUGB5OW-BN9rjxsZ.js} +1 -1
  211. package/dist/viewer/{zh-HK-E62DVLB3-Dhwq5Laa.js → zh-HK-E62DVLB3-DVH9Q1Iz.js} +1 -1
  212. package/dist/viewer/{zh-TW-RAJ6MFWO-CfId5kew.js → zh-TW-RAJ6MFWO-CZYgWnVr.js} +1 -1
  213. package/dist/viewer-lib/{Canvas-BpIyaqFN.js → Canvas-Cz4jc5_1.js} +3 -3
  214. package/dist/viewer-lib/PageLoader-M5KGHqfg.js +32 -0
  215. package/dist/viewer-lib/{PhoneArtboardBar-DYEcy0Qa.js → PhoneArtboardBar-MV_lMiiq.js} +2 -2
  216. package/dist/viewer-lib/{PreviewView-DX6HLiL0.js → PreviewView-C0pRJ1cs.js} +117 -110
  217. package/dist/viewer-lib/{ReadOnlyWhiteboard-C9v2Zbtp.js → ReadOnlyWhiteboard-B5wXA3u9.js} +90 -89
  218. package/dist/viewer-lib/{i18n-QksLzzWi.js → RyugiLoader-_MZxEs2s.js} +145 -20
  219. package/dist/viewer-lib/{SnapshotDocument-CMVvuBUw.css → SnapshotDocument-BV29XJk4.css} +1 -1
  220. package/dist/viewer-lib/{SnapshotDocument-BbgwNfWB.js → SnapshotDocument-DiIRfl5L.js} +75 -75
  221. package/dist/viewer-lib/{VirtualizedEditor-uWe43zaI-CmgTXS-p.js → VirtualizedEditor-uWe43zaI-DktBg0M1.js} +2 -2
  222. package/dist/viewer-lib/{VirtualizedRenderer-C_d95FXi-BuckUTnS.js → VirtualizedRenderer-C_d95FXi-B39OU9Je.js} +3 -3
  223. package/dist/viewer-lib/{WarningsBadge-1xR7QoZB.js → WarningsBadge-p7-QKPVW.js} +1 -1
  224. package/dist/viewer-lib/{agentLook-xSyYY25N.js → agentLook-Pf_kpgWG.js} +1 -1
  225. package/dist/viewer-lib/{ar-SA-G6X2FPQ2-CEJUrUcf.js → ar-SA-G6X2FPQ2-qbH69ISs.js} +1 -1
  226. package/dist/viewer-lib/{az-AZ-76LH7QW2-D3FZr56u.js → az-AZ-76LH7QW2-CfO7QPHE.js} +1 -1
  227. package/dist/viewer-lib/{bg-BG-XCXSNQG7-DV2gd8SJ.js → bg-BG-XCXSNQG7-JgeW4H2C.js} +1 -1
  228. package/dist/viewer-lib/{bn-BD-2XOGV67Q-fNhYcJwe.js → bn-BD-2XOGV67Q-AoN4Z5CP.js} +1 -1
  229. package/dist/viewer-lib/{ca-ES-6MX7JW3Y-p45OBk_B.js → ca-ES-6MX7JW3Y-BaoeIvfa.js} +1 -1
  230. package/dist/viewer-lib/{chunk-EIO257PC-CXXH8Md3.js → chunk-EIO257PC-Ac80GdCI.js} +1 -1
  231. package/dist/viewer-lib/core.js +5 -4
  232. package/dist/viewer-lib/{cs-CZ-2BRQDIVT-CY75gnzI.js → cs-CZ-2BRQDIVT-DhxT4nbh.js} +1 -1
  233. package/dist/viewer-lib/{da-DK-5WZEPLOC-DmMaYPrm.js → da-DK-5WZEPLOC-E4_32hvX.js} +1 -1
  234. package/dist/viewer-lib/{de-DE-XR44H4JA-DYfV8p9-.js → de-DE-XR44H4JA-CH1m2Hyu.js} +1 -1
  235. package/dist/viewer-lib/{dist-CByhej7K.js → dist-4N9VL_Qo.js} +3 -3
  236. package/dist/viewer-lib/{dist-DXfPN4Ec.js → dist-BGqKudtK.js} +3 -3
  237. package/dist/viewer-lib/{dist-BC4KdWXx.js → dist-BUWnxmmt.js} +2 -2
  238. package/dist/viewer-lib/{dist-Bj7f3YVM.js → dist-Bf3vx8tA.js} +3 -3
  239. package/dist/viewer-lib/{dist-B2Nu28kR.js → dist-C2-8CMJG.js} +3 -3
  240. package/dist/viewer-lib/{dist-BTsSLXre.js → dist-COGc35cY.js} +1 -1
  241. package/dist/viewer-lib/{dist-C1rZNGDI.js → dist-CxLJJRFh.js} +3 -3
  242. package/dist/viewer-lib/{dist-Dk0VPjYJ.js → dist-D-eZ6Mt_.js} +4 -4
  243. package/dist/viewer-lib/{dist-CLtlsvg1.js → dist-D4hVC50-.js} +2 -2
  244. package/dist/viewer-lib/{dist-B4fnnsge.js → dist-DCoCMlKT.js} +2 -2
  245. package/dist/viewer-lib/{dist-DBjTRRIP.js → dist-DNSST2rW.js} +3 -3
  246. package/dist/viewer-lib/{dist-BIGmzfNO.js → dist-DjyhCAJp.js} +3 -3
  247. package/dist/viewer-lib/{dist-ot8vVTH3.js → dist-DpLE-ZgU.js} +2 -2
  248. package/dist/viewer-lib/{dist-DXMlNYXL.js → dist-DpdpsTAT.js} +2 -2
  249. package/dist/viewer-lib/{dist-C4KWXAoU.js → dist-DrhJ9opW.js} +2 -2
  250. package/dist/viewer-lib/{dist-BCKU1e8H.js → dist-Dt0ohtTi.js} +4 -4
  251. package/dist/viewer-lib/{dist-lmMdFW_t.js → dist-GyL4PJ8b.js} +3 -3
  252. package/dist/viewer-lib/{dist-CcDaSD_g.js → dist-JKcrLRtX.js} +2 -2
  253. package/dist/viewer-lib/{dist-3pnICcdO.js → dist-K_XrbIQp.js} +2 -2
  254. package/dist/viewer-lib/{dist-BHOz-HOQ.js → dist-YCAwO-Nd.js} +3 -3
  255. package/dist/viewer-lib/{dist-BqK2glT6.js → dist-e2LB4sJU.js} +4 -4
  256. package/dist/viewer-lib/{dist-DJ5tvY8x.js → dist-elxdtjg5.js} +1 -1
  257. package/dist/viewer-lib/{dist-kESmUvgx.js → dist-xhmSGfbo.js} +3 -3
  258. package/dist/viewer-lib/document.js +676 -674
  259. package/dist/viewer-lib/{el-GR-BZB4AONW-C0-Rg3rY.js → el-GR-BZB4AONW-CxMbipHk.js} +1 -1
  260. package/dist/viewer-lib/{en-B4ZKOASM-CWwARfdU.js → en-B4ZKOASM-Ch0kGhap.js} +1 -1
  261. package/dist/viewer-lib/{es-ES-U4NZUMDT-Di1ZUIVa.js → es-ES-U4NZUMDT-B9x-x6lF.js} +1 -1
  262. package/dist/viewer-lib/{eu-ES-A7QVB2H4-DfxpIbwQ.js → eu-ES-A7QVB2H4-C3VIhLkt.js} +1 -1
  263. package/dist/viewer-lib/{fa-IR-HGAKTJCU-BzJgn5bY.js → fa-IR-HGAKTJCU-Ch3qRpCM.js} +1 -1
  264. package/dist/viewer-lib/{fi-FI-Z5N7JZ37-Dgh9WYA8.js → fi-FI-Z5N7JZ37-DUj1GHLS.js} +1 -1
  265. package/dist/viewer-lib/{fr-FR-RHASNOE6-FxbVo7Yh.js → fr-FR-RHASNOE6-DHTtAWgo.js} +1 -1
  266. package/dist/viewer-lib/{gl-ES-HMX3MZ6V-BwezJSl-.js → gl-ES-HMX3MZ6V-Cze-1U2w.js} +1 -1
  267. package/dist/viewer-lib/{he-IL-6SHJWFNN-CMKZRRs9.js → he-IL-6SHJWFNN-CNXnKism.js} +1 -1
  268. package/dist/viewer-lib/{hi-IN-IWLTKZ5I-4-ZNp-DM.js → hi-IN-IWLTKZ5I-flVZhrNs.js} +1 -1
  269. package/dist/viewer-lib/{hu-HU-A5ZG7DT2-Cao8cecF.js → hu-HU-A5ZG7DT2-C37EVmEa.js} +1 -1
  270. package/dist/viewer-lib/{id-ID-SAP4L64H-CWnVrU2u.js → id-ID-SAP4L64H-ClyjpOWe.js} +1 -1
  271. package/dist/viewer-lib/{image-GAAHSSAO-5jYfRo5K.js → image-GAAHSSAO-uUIN58iQ.js} +1 -1
  272. package/dist/viewer-lib/index.js +1776 -1778
  273. package/dist/viewer-lib/{it-IT-JPQ66NNP-DiPCKoa_.js → it-IT-JPQ66NNP-Blbj9-RE.js} +1 -1
  274. package/dist/viewer-lib/{ja-JP-DBVTYXUO-CXbGOVTd.js → ja-JP-DBVTYXUO-d4IkMycP.js} +1 -1
  275. package/dist/viewer-lib/{kaa-6HZHGXH3-BkMVWloD.js → kaa-6HZHGXH3-BLfJ-cuB.js} +1 -1
  276. package/dist/viewer-lib/{kab-KAB-ZGHBKWFO-FA3Rofsx.js → kab-KAB-ZGHBKWFO-CE_PEjYa.js} +1 -1
  277. package/dist/viewer-lib/{kk-KZ-P5N5QNE5-CsDnxzrG.js → kk-KZ-P5N5QNE5-MSQ0edn8.js} +1 -1
  278. package/dist/viewer-lib/{km-KH-HSX4SM5Z-BxCiwgzA.js → km-KH-HSX4SM5Z-BYOvIsAB.js} +1 -1
  279. package/dist/viewer-lib/{ko-KR-MTYHY66A-C-7uFPlL.js → ko-KR-MTYHY66A-DBp6P6uI.js} +1 -1
  280. package/dist/viewer-lib/{ku-TR-6OUDTVRD-BILRBU5_.js → ku-TR-6OUDTVRD-DXb7ijNZ.js} +1 -1
  281. package/dist/viewer-lib/{lib-DwpunbxQ.js → lib-0D5Lgp7R.js} +1 -1
  282. package/dist/viewer-lib/{lt-LT-XHIRWOB4-B6TKZcXY.js → lt-LT-XHIRWOB4-tWY6xBEJ.js} +1 -1
  283. package/dist/viewer-lib/{lv-LV-5QDEKY6T-C-K90vIy.js → lv-LV-5QDEKY6T-B8Ew_8za.js} +1 -1
  284. package/dist/viewer-lib/{mr-IN-CRQNXWMA-K0hO9NLW.js → mr-IN-CRQNXWMA-C6A0bvr8.js} +1 -1
  285. package/dist/viewer-lib/{my-MM-5M5IBNSE-Da5X6e7B.js → my-MM-5M5IBNSE-B4eEg06F.js} +1 -1
  286. package/dist/viewer-lib/{nb-NO-T6EIAALU-D9WwGGq8.js → nb-NO-T6EIAALU-BST0y_U9.js} +1 -1
  287. package/dist/viewer-lib/{nl-NL-IS3SIHDZ-BOYOn6bl.js → nl-NL-IS3SIHDZ-R2rJHctU.js} +1 -1
  288. package/dist/viewer-lib/{nn-NO-6E72VCQL-Bwi6kGD3.js → nn-NO-6E72VCQL-DFgpBRTv.js} +1 -1
  289. package/dist/viewer-lib/{oc-FR-POXYY2M6-h8Hb5RCQ.js → oc-FR-POXYY2M6-Dfgf8Rar.js} +1 -1
  290. package/dist/viewer-lib/{pa-IN-N4M65BXN-DHJ5ZqCB.js → pa-IN-N4M65BXN-pRdhmMMX.js} +1 -1
  291. package/dist/viewer-lib/percentages-BXMCSKIN-tIRAqLi6.js +1 -0
  292. package/dist/viewer-lib/{pl-PL-T2D74RX3-DSrRpGY_.js → pl-PL-T2D74RX3-CWXo_n8w.js} +1 -1
  293. package/dist/viewer-lib/{plugin-_bGVeqI0-CUWLVkLE.js → plugin-_bGVeqI0-CEaMOsSS.js} +1 -1
  294. package/dist/viewer-lib/{prod-IPTdmVn7.js → prod-C-Yl3reA.js} +59 -59
  295. package/dist/viewer-lib/{pt-BR-5N22H2LF-Cnku-mHw.js → pt-BR-5N22H2LF-QYaR1bwz.js} +1 -1
  296. package/dist/viewer-lib/{pt-PT-UZXXM6DQ-CI4Lw12R.js → pt-PT-UZXXM6DQ-B3Xmhk77.js} +1 -1
  297. package/dist/viewer-lib/{ro-RO-JPDTUUEW-Z0rMTCBA.js → ro-RO-JPDTUUEW-c4iCK_Pl.js} +1 -1
  298. package/dist/viewer-lib/{route-messages-BHovJ4nB.js → route-messages-BOdX3qq4.js} +20 -20
  299. package/dist/viewer-lib/{ru-RU-B4JR7IUQ-DH7fwhiu.js → ru-RU-B4JR7IUQ-D6bje_j4.js} +1 -1
  300. package/dist/viewer-lib/{si-LK-N5RQ5JYF-BFG1Q032.js → si-LK-N5RQ5JYF-CSCCQJ8w.js} +1 -1
  301. package/dist/viewer-lib/{sk-SK-C5VTKIMK-nKDfxLLq.js → sk-SK-C5VTKIMK-Y0-0nXpW.js} +1 -1
  302. package/dist/viewer-lib/{sl-SI-NN7IZMDC-zdGtFnJ4.js → sl-SI-NN7IZMDC-LLRODh8d.js} +1 -1
  303. package/dist/viewer-lib/{stylex-H52XSOyN.css → stylex-CCivaCRo.css} +88 -0
  304. package/dist/viewer-lib/subset-shared.chunk-Bkt4jbTb.js +2 -0
  305. package/dist/viewer-lib/{subset-worker.chunk-DHe1FqQ-.js → subset-worker.chunk-CFZCkpb_.js} +2 -2
  306. package/dist/viewer-lib/{sv-SE-XGPEYMSR-MVhH_h3w.js → sv-SE-XGPEYMSR-r-pwNhnE.js} +1 -1
  307. package/dist/viewer-lib/{ta-IN-2NMHFXQM-C_I2r20T.js → ta-IN-2NMHFXQM-BpeAXDlG.js} +1 -1
  308. package/dist/viewer-lib/{th-TH-HPSO5L25-DQ6MPZ1r.js → th-TH-HPSO5L25-DVXFh9KL.js} +1 -1
  309. package/dist/viewer-lib/{tr-TR-DEFEU3FU-BNz_PazH.js → tr-TR-DEFEU3FU-CywClmkn.js} +1 -1
  310. package/dist/viewer-lib/types/src/shared/brand.d.ts +2 -1
  311. package/dist/viewer-lib/types/src/viewer/components/PageLoader.d.ts +3 -0
  312. package/dist/viewer-lib/types/src/viewer/components/RyugiLoader.d.ts +5 -0
  313. package/dist/viewer-lib/types/src/viewer/lib/pageSettle.d.ts +2 -0
  314. package/dist/viewer-lib/types/src/viewer/library/core.d.ts +3 -0
  315. package/dist/viewer-lib/{uk-UA-QMV73CPH-Dn_Qrdeq.js → uk-UA-QMV73CPH-CBuRoxji.js} +1 -1
  316. package/dist/viewer-lib/{vi-VN-M7AON7JQ-C777_3GC.js → vi-VN-M7AON7JQ-CUq13H3z.js} +1 -1
  317. package/dist/viewer-lib/{viewport-CFJHn_Y6-BrrKKQGr.js → viewport-CFJHn_Y6-NgIgENqw.js} +1 -1
  318. package/dist/viewer-lib/{zh-CN-LNUGB5OW-yPc5aNBV.js → zh-CN-LNUGB5OW-BRivCR5s.js} +1 -1
  319. package/dist/viewer-lib/{zh-HK-E62DVLB3-DL9Y2kPe.js → zh-HK-E62DVLB3-DaZXYMh5.js} +1 -1
  320. package/dist/viewer-lib/{zh-TW-RAJ6MFWO-3VDE8SB2.js → zh-TW-RAJ6MFWO-B7IvI564.js} +1 -1
  321. package/package.json +1 -1
  322. package/dist/viewer/ArtboardLayout-9iOfvOR4.js +0 -12
  323. package/dist/viewer/ArtifactList-Binw79VZ.js +0 -2
  324. package/dist/viewer/DocumentLayout-D7hzy6qw.js +0 -2
  325. package/dist/viewer/DocumentPage-whdrobXS.js +0 -4
  326. package/dist/viewer/DropdownMenu-CZUIT5ss.js +0 -1
  327. package/dist/viewer/PreviewLayout-Dvv4xVya.js +0 -2
  328. package/dist/viewer/WhiteboardLayout-fX2Dx4Ro.js +0 -3
  329. package/dist/viewer/channel-OqtHMQX0.js +0 -1
  330. package/dist/viewer/classDiagram-ZZMXUADV-CVstJoyx.js +0 -1
  331. package/dist/viewer/classDiagram-v2-VYDZK3BY-CVstJoyx.js +0 -1
  332. package/dist/viewer/flowDiagram-HODETNUW-CzgiVLhq.js +0 -1
  333. package/dist/viewer/percentages-BXMCSKIN-DvCjqEYt.js +0 -1
  334. package/dist/viewer/route-BWL5AGYx.js +0 -64
  335. package/dist/viewer/stateDiagram-v2-MP3YSRHH-Ds741M59.js +0 -1
  336. package/dist/viewer/subset-shared.chunk-BwlAfs_X.js +0 -1
  337. package/dist/viewer/swimlanesDiagram-VR7AAH4N-CIbxLGch.js +0 -8
  338. package/dist/viewer/useCloudStatus-BJMLC8Dr.js +0 -1
  339. package/dist/viewer-lib/percentages-BXMCSKIN-CN_vO7hH.js +0 -1
  340. package/dist/viewer-lib/subset-shared.chunk-BI1a3Hz4.js +0 -2
@@ -0,0 +1 @@
1
+ import{at as e,ot as t}from"./chunk-DU6HZSFF-Dr7PaN7b.js";var n=(n,r)=>t.lang.round(e.parse(n)[r]);export{n as t};
@@ -1,4 +1,4 @@
1
- import{a as e,p as t,r as n,u as r}from"./chunk-75Z2AOVW-BbYnGlO9.js";import{n as i,t as a}from"./src-KUZZYZBk.js";import{n as o}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{A as s,B as c,M as l,T as u,b as d,f,g as p,x as m,z as h}from"./chunk-DU6HZSFF-D25kbUvc.js";import{a as g,i as _,r as v,t as y}from"./chunk-P2QGCYS3-09egvNok.js";import{t as b}from"./chunk-PWAF6VOD-Bz8UB2mc.js";import{n as x,r as S}from"./chunk-GMAD6QVW-C27INOB_.js";import{t as C}from"./rough.esm-Dy-Kn_BL.js";var w=1,T=3;async function E(e){let n=e.getElementsByTagName(`img`);if(!n||n.length===0)return;let r=!D(e);await Promise.all([...n].map(e=>new Promise(n=>{function i(){if(e.style.display=`flex`,e.style.flexDirection=`column`,r){let n=m().fontSize?m().fontSize:window.getComputedStyle(document.body).fontSize,[r=f.fontSize]=t(n),i=r*5+`px`;e.style.minWidth=i,e.style.maxWidth=i}else e.style.width=`100%`;n(e)}o(i,`setupImage`),setTimeout(()=>{e.complete&&i()}),e.addEventListener(`error`,i),e.addEventListener(`load`,i)})))}o(E,`configureLabelImages`);function D(e){return e.nodeType===T?e.textContent?.trim()!==``:e.nodeType!==w||e.tagName.toLowerCase()===`img`?!1:[...e.childNodes].some(D)}o(D,`hasTextBesidesImages`);var O=3,k=32,A=o(async(t,n,i)=>{let o=m(),s=t.insert(`g`).attr(`class`,i??`node default`).attr(`id`,n.domId||n.id),c=s.insert(`g`).attr(`class`,`label`).attr(`style`,r(n.labelStyle)),l=[{text:typeof n.label==`string`?n.label:n.label?.[0]??``,cssClass:`c4-name`},{text:n.stereotype,cssClass:`c4-type`},...(n.description??[]).map(e=>({text:e,cssClass:`c4-descr`}))].filter(e=>e.text),u=n.width?Math.max(n.width-2*(n.padding??0),k):m().flowchart?.wrappingWidth??200,d=o.c4?.wrap??!0?u:1/0,f=await Promise.all(l.map(async t=>{let r=c.append(`g`).attr(`class`,t.cssClass),i=await x(r,h(e(t.text??``),o),{useHtmlLabels:!1,markdown:!1,isNode:!0,width:d,style:n.labelStyle},o);return a(i).selectAll(`tspan.text-outer-tspan`).attr(`text-anchor`,`middle`),a(i).selectAll(`tspan.text-inner-tspan`).attr(`font-weight`,null).attr(`font-style`,null),{el:r,box:r.node().getBBox()}})),p=Math.max(...f.map(({box:e})=>e.width),0),g=0;for(let{el:e,box:t}of f)e.attr(`transform`,`translate(${p/2-t.x-t.width/2}, ${g-t.y})`),g+=t.height+O;let _=f.length>0?g-O:0;return c.insert(`rect`,`:first-child`),c.attr(`transform`,`translate(${-p/2}, ${-_/2})`),{shapeSvg:s,bbox:c.node().getBBox(),halfPadding:(n.padding??0)/2,label:c}},`c4LabelHelper`),j=o(async(t,n,i)=>{if(n.stereotype!==void 0)return A(t,n,i);let o,s=n.useHtmlLabels||p(m()?.htmlLabels);o=i||`node default`;let c=t.insert(`g`).attr(`class`,o).attr(`id`,n.domId||n.id),l=c.insert(`g`).attr(`class`,`label`).attr(`style`,r(n.labelStyle)),u;u=n.label===void 0?``:typeof n.label==`string`?n.label:n.label[0];let d=!!n.icon||!!n.img,f=n.labelType===`markdown`,g=await x(l,h(e(u),m()),{useHtmlLabels:s,width:n.width||n.wrappingWidth||m().flowchart?.wrappingWidth,classes:f?`markdown-node-label`:``,style:n.labelStyle,addSvgBackground:d,markdown:f},m()),_=(n?.padding??0)/2,v;if(s){let e=g.children[0],t=a(g);await E(e),v=await S.measure(()=>e.getBoundingClientRect()),t.attr(`width`,v.width),t.attr(`height`,v.height)}else v=await S.measure(()=>g.getBBox());return s?l.attr(`transform`,`translate(`+-v.width/2+`, `+-v.height/2+`)`):l.attr(`transform`,`translate(0, `+-v.height/2+`)`),n.centerLabel&&l.attr(`transform`,`translate(`+-v.width/2+`, `+-v.height/2+`)`),l.insert(`rect`,`:first-child`),{shapeSvg:c,bbox:v,halfPadding:_,label:l}},`labelHelper`),M=o(async(t,n,r)=>{let i=r.useHtmlLabels??u(m()),o=t.insert(`g`).attr(`class`,`label`).attr(`style`,r.labelStyle||``),s=await x(o,h(e(n),m()),{useHtmlLabels:i,width:r.width||m()?.flowchart?.wrappingWidth,style:r.labelStyle,addSvgBackground:!!r.icon||!!r.img}),c=r.padding/2,l;if(u(m())){let e=s.children[0],t=a(s);l=await S.measure(()=>e.getBoundingClientRect()),t.attr(`width`,l.width),t.attr(`height`,l.height)}else l=await S.measure(()=>s.getBBox());return i?o.attr(`transform`,`translate(`+-l.width/2+`, `+-l.height/2+`)`):o.attr(`transform`,`translate(0, `+-l.height/2+`)`),r.centerLabel&&o.attr(`transform`,`translate(`+-l.width/2+`, `+-l.height/2+`)`),o.insert(`rect`,`:first-child`),{shapeSvg:t,bbox:l,halfPadding:c,label:o}},`insertLabel`),N=o((e,t,n)=>{if(n){e.width=n.width,e.height=n.height;return}let r=t.node().getBBox();e.width=r.width,e.height=r.height},`updateNodeBounds`),P=o((e,t)=>(e.look===`handDrawn`?`rough-node`:`node`)+` `+e.cssClasses+` `+(t||``),`getNodeClasses`);function F(e){let t=e.map((e,t)=>`${t===0?`M`:`L`}${e.x},${e.y}`);return t.push(`Z`),t.join(` `)}o(F,`createPathFromPoints`);function I(e,t,n,r,i,a){let o=[],s=n-e,c=r-t,l=s/a,u=2*Math.PI/l,d=t+c/2;for(let t=0;t<=50;t++){let n=e+t/50*s,r=d+i*Math.sin(u*(n-e));o.push({x:n,y:r})}return o}o(I,`generateFullSineWavePoints`);function L(e,t,n,r,i,a){let o=[],s=i*Math.PI/180,c=(a*Math.PI/180-s)/(r-1);for(let i=0;i<r;i++){let r=s+i*c,a=e+n*Math.cos(r),l=t+n*Math.sin(r);o.push({x:-a,y:-l})}return o}o(L,`generateCirclePoints`);function ee(e){let t=Array.from(e.childNodes).filter(e=>e.tagName===`path`),n=document.createElementNS(`http://www.w3.org/2000/svg`,`path`),r=t.map(e=>e.getAttribute(`d`)).filter(e=>e!==null).join(` `);n.setAttribute(`d`,r);let i=t.find(e=>e.getAttribute(`fill`)!==`none`),a=t.find(e=>e.getAttribute(`stroke`)!==`none`),s=o((e,t)=>e?.getAttribute(t)??void 0,`getAttr`);if(i){let e={fill:s(i,`fill`),"fill-opacity":s(i,`fill-opacity`)??`1`};Object.entries(e).forEach(([e,t])=>{t&&n.setAttribute(e,t)})}if(a){let e={stroke:s(a,`stroke`),"stroke-width":s(a,`stroke-width`)??`1`,"stroke-opacity":s(a,`stroke-opacity`)??`1`};Object.entries(e).forEach(([e,t])=>{t&&n.setAttribute(e,t)})}let c=document.createElementNS(`http://www.w3.org/2000/svg`,`g`);return c.appendChild(n),c}o(ee,`mergePaths`);var R=o((e,t)=>{var n=e.x,r=e.y,i=t.x-n,a=t.y-r,o=e.width/2,s=e.height/2,c,l;return Math.abs(a)*o>Math.abs(i)*s?(a<0&&(s=-s),c=a===0?0:s*i/a,l=s):(i<0&&(o=-o),c=o,l=i===0?0:o*a/i),{x:n+c,y:r+l}},`intersectRect`),z=o((e,t,n,r,i)=>[`M`,e+i,t,`H`,e+n-i,`A`,i,i,0,0,1,e+n,t+i,`V`,t+r-i,`A`,i,i,0,0,1,e+n-i,t+r,`H`,e+i,`A`,i,i,0,0,1,e,t+r-i,`V`,t+i,`A`,i,i,0,0,1,e+i,t,`Z`].join(` `),`createRoundedRectPathD`),te=o(async(e,t,n,r=!1,i=!1)=>{let a=t||``;typeof a==`object`&&(a=a[0]);let o=m(),s=u(o);return await x(e,a,{style:n,isTitle:r,useHtmlLabels:s,markdown:!1,isNode:i,width:1/0},o)},`createLabel`);function B(e,t){return e.intersect(t)}o(B,`intersectNode`);var ne=B;function V(e,t,n,r){var i=e.x,a=e.y,o=i-r.x,s=a-r.y,c=Math.sqrt(t*t*s*s+n*n*o*o),l=Math.abs(t*n*o/c);r.x<i&&(l=-l);var u=Math.abs(t*n*s/c);return r.y<a&&(u=-u),{x:i+l,y:a+u}}o(V,`intersectEllipse`);var H=V;function re(e,t,n){return H(e,t,t,n)}o(re,`intersectCircle`);var ie=re;function U(e,t,n,r){{let i=t.y-e.y,a=e.x-t.x,o=t.x*e.y-e.x*t.y,s=i*n.x+a*n.y+o,c=i*r.x+a*r.y+o,l=1e-6;if(s!==0&&c!==0&&W(s,c))return;let u=r.y-n.y,d=n.x-r.x,f=r.x*n.y-n.x*r.y,p=u*e.x+d*e.y+f,m=u*t.x+d*t.y+f;if(Math.abs(p)<l&&Math.abs(m)<l&&W(p,m))return;let h=i*d-u*a;if(h===0)return;let g=Math.abs(h/2),_=a*f-d*o,v=_<0?(_-g)/h:(_+g)/h;return _=u*o-i*f,{x:v,y:_<0?(_-g)/h:(_+g)/h}}}o(U,`intersectLine`);function W(e,t){return e*t>0}o(W,`sameSign`);var G=U;function ae(e,t,n){let r=e.x,i=e.y,a=[],o=1/0,s=1/0;typeof t.forEach==`function`?t.forEach(function(e){o=Math.min(o,e.x),s=Math.min(s,e.y)}):(o=Math.min(o,t.x),s=Math.min(s,t.y));let c=r-e.width/2-o,l=i-e.height/2-s;for(let r=0;r<t.length;r++){let i=t[r],o=t[r<t.length-1?r+1:0],s=G(e,n,{x:c+i.x,y:l+i.y},{x:c+o.x,y:l+o.y});s&&a.push(s)}return a.length?(a.length>1&&a.sort(function(e,t){let r=e.x-n.x,i=e.y-n.y,a=Math.sqrt(r*r+i*i),o=t.x-n.x,s=t.y-n.y,c=Math.sqrt(o*o+s*s);return a<c?-1:a===c?0:1}),a[0]):e}o(ae,`intersectPolygon`);var K={node:ne,circle:ie,ellipse:H,polygon:ae,rect:R};function oe(e,t){let{labelStyles:n}=_(t);t.labelStyle=n;let a=P(t),o=a;a||(o=`anchor`);let s=e.insert(`g`).attr(`class`,o).attr(`id`,t.domId||t.id),{cssStyles:c}=t,l=C.svg(s),u=g(t,{fill:`black`,stroke:`none`,fillStyle:`solid`});t.look!==`handDrawn`&&(u.roughness=0);let d=l.circle(0,0,2,u),f=s.insert(()=>d,`:first-child`);return f.attr(`class`,`anchor`).attr(`style`,r(c)),N(t,f),t.intersect=function(e){return i.info(`Circle intersect`,t,1,e),K.circle(t,1,e)},s}o(oe,`anchor`);function se(e,t,n,r,i,a,o){let s=(e+n)/2,c=(t+r)/2,l=Math.atan2(r-t,n-e),u=(n-e)/2,d=(r-t)/2,f=u/i,p=d/a,m=Math.sqrt(f**2+p**2);if(m>1)throw Error(`The given radii are too small to create an arc between the points.`);let h=Math.sqrt(1-m**2),g=s+h*a*Math.sin(l)*(o?-1:1),_=c-h*i*Math.cos(l)*(o?-1:1),v=Math.atan2((t-_)/a,(e-g)/i),y=Math.atan2((r-_)/a,(n-g)/i)-v;o&&y<0&&(y+=2*Math.PI),!o&&y>0&&(y-=2*Math.PI);let b=[];for(let e=0;e<20;e++){let t=v+e/19*y,n=g+i*Math.cos(t),r=_+a*Math.sin(t);b.push({x:n,y:r})}return b}o(se,`generateArcPoints`);function ce(e,t,n){let[r,i]=[t,n].sort((e,t)=>t-e);return i*(1-Math.sqrt(1-(e/r/2)**2))}o(ce,`calculateArcSagitta`);async function le(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,s=t.look===`neo`?12:i,c=o(e=>e+s,`calcTotalHeight`),l=o(e=>{let t=e/2;return[t/(2.5+e/50),t]},`calcEllipseRadius`),{shapeSvg:u,bbox:d}=await j(e,t,P(t)),f=c(t?.height?t?.height:d.height),[p,m]=l(f),h=ce(f,p,m),v=(t?.width?t?.width:d.width)+a*2+h-h,y=f,{cssStyles:b}=t,x=[{x:v/2,y:-y/2},{x:-v/2,y:-y/2},...se(-v/2,-y/2,-v/2,y/2,p,m,!1),{x:v/2,y:y/2},...se(v/2,y/2,v/2,-y/2,p,m,!0)],S=C.svg(u),w=g(t,{});t.look!==`handDrawn`&&(w.roughness=0,w.fillStyle=`solid`);let T=F(x),E=S.path(T,w),D=u.insert(()=>E,`:first-child`);return D.attr(`class`,`basic label-container outer-path`),b&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,b),r&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,r),D.attr(`transform`,`translate(${p/2}, 0)`),N(t,D),t.intersect=function(e){return K.polygon(t,x,e)},u}o(le,`bowTieRect`);async function ue(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{shapeSvg:a,bbox:s,label:c}=await j(e,t,P(t)),l=n?.nodeBorder??n?.lineColor??`currentColor`,u=t.padding??12,d=Math.max(s.width+u*2,t.width??0,80),f=Math.max(Math.min(d*.08,12),5),p=Math.max(s.height+u*2+f,t.height??0),m=-p/2+f,h=p/2,v=d*.72,y=[`M${-d/2},${m}`,`L${-v/2},${h}`,`A${v/2},${f} 0 0 0 ${v/2},${h}`,`L${d/2},${m}`,`A${d/2},${f} 0 0 0 ${-d/2},${m}`,`Z`].join(` `),{cssStyles:b}=t,x=a.insert(`g`,`:first-child`).attr(`class`,`basic label-container`);if(t.look===`handDrawn`){let e=C.svg(a).path(y,g(t,{}));x.node()?.appendChild(e),b&&x.attr(`style`,b)}else x.append(`path`).attr(`d`,y).attr(`style`,i);x.append(`ellipse`).attr(`cx`,0).attr(`cy`,m).attr(`rx`,d/2).attr(`ry`,f).attr(`style`,`fill:none;stroke:${l};stroke-width:1px`),N(t,x);let S=m+(h-m)/2;c.attr(`transform`,`translate(${-(s.width/2)-(s.x-(s.left??0))}, ${S-s.height/2-(s.y-(s.top??0))})`);let w=o((e,t,n)=>Array.from({length:13},(r,i)=>{let a=Math.PI-i*Math.PI/12;return{x:e*Math.cos(a),y:t+n*f*Math.sin(a)}}),`arc`),T=[...w(d/2,m,-1),...w(v/2,h,1).reverse()];return t.intersect=function(e){return K.polygon(t,T,e)},a}o(ue,`bucket`);var de=20,fe=8,pe=80,me=8;async function he(e,t){let{themeVariables:n}=m(),i=n.clusterBkg,a=n.clusterBorder,{nodeStyles:o}=_(t),{shapeSvg:s,bbox:c}=await j(e,t,P(t)),l=t.padding??8,d=c.height,f=Math.max(c.width+l*2,pe,t?.width??0),p=Math.max(d+fe+de+l*2,t?.height??0),h=-f/2,v=-p/2,y=-(fe+de)/2,b=s.select(`.label`);b&&(t.useHtmlLabels??u(m())?b.attr(`transform`,`translate(${-c.width/2}, ${-c.height/2+y})`):b.attr(`transform`,`translate(0, ${-c.height/2+y})`));let x;if(t.look===`handDrawn`){let e=C.svg(s),n=g(t,{fill:i,stroke:a,fillStyle:`solid`}),o=e.path(z(h,v,f,p,me),n);x=s.insert(()=>o,`:first-child`),x.attr(`class`,`basic label-container collapsed-group`).attr(`style`,r(t.cssStyles))}else x=s.insert(`rect`,`:first-child`),x.attr(`class`,`basic label-container collapsed-group`).attr(`style`,o).attr(`rx`,me).attr(`ry`,me).attr(`x`,h).attr(`y`,v).attr(`width`,f).attr(`height`,p).attr(`fill`,i).attr(`stroke`,a);let S=v+l+d+fe;s.append(`line`).attr(`class`,`collapsed-separator`).attr(`x1`,h+8).attr(`y1`,S).attr(`x2`,h+f-8).attr(`y2`,S).attr(`stroke`,a).attr(`stroke-dasharray`,`3, 3`);let w=S+de/2;for(let e=-1;e<=1;e++)s.append(`circle`).attr(`class`,`collapsed-indicator`).attr(`cx`,e*10).attr(`cy`,w).attr(`r`,2.5).attr(`fill`,a);return N(t,x),t.calcIntersect=function(e,t){return K.rect(e,t)},t.intersect=function(e){return K.rect(t,e)},s}o(he,`collapsedGroup`);function q(e,t,n,r){return e.insert(`polygon`,`:first-child`).attr(`points`,r.map(function(e){return e.x+`,`+e.y}).join(` `)).attr(`class`,`label-container`).attr(`transform`,`translate(`+-t/2+`,`+n/2+`)`)}o(q,`insertPolygonShape`);var ge=[`right`,`left`,`up`,`down`],_e=`point`,ve=o(e=>{let t=new Set;for(let n of e)switch(n){case`x`:t.add(`right`),t.add(`left`);break;case`y`:t.add(`up`),t.add(`down`);break;default:t.add(n)}return t},`expandAndDeduplicateDirections`),ye=o(e=>ge.filter(t=>e.has(t)).join(`|`)||_e,`getDirectionKey`),be={"right|left|up|down":o(({height:e,midpoint:t,padding:n,width:r})=>[{x:0,y:0},{x:t,y:0},{x:r/2,y:2*n},{x:r-t,y:0},{x:r,y:0},{x:r,y:-e/3},{x:r+2*n,y:-e/2},{x:r,y:-2*e/3},{x:r,y:-e},{x:r-t,y:-e},{x:r/2,y:-e-2*n},{x:t,y:-e},{x:0,y:-e},{x:0,y:-2*e/3},{x:-2*n,y:-e/2},{x:0,y:-e/3}],`right|left|up|down`),"right|left|up":o(({height:e,midpoint:t,width:n})=>[{x:t,y:0},{x:n-t,y:0},{x:n,y:-e/2},{x:n-t,y:-e},{x:t,y:-e},{x:0,y:-e/2}],`right|left|up`),"right|left|down":o(({height:e,midpoint:t,width:n})=>[{x:0,y:0},{x:t,y:-e},{x:n-t,y:-e},{x:n,y:0}],`right|left|down`),"right|up|down":o(({height:e,midpoint:t,width:n})=>[{x:0,y:0},{x:n,y:-t},{x:n,y:-e+t},{x:0,y:-e}],`right|up|down`),"left|up|down":o(({height:e,midpoint:t,width:n})=>[{x:n,y:0},{x:0,y:-t},{x:0,y:-e+t},{x:n,y:-e}],`left|up|down`),"right|left":o(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:0},{x:t,y:-n},{x:r-t,y:-n},{x:r-t,y:0},{x:r,y:-e/2},{x:r-t,y:-e},{x:r-t,y:-e+n},{x:t,y:-e+n},{x:t,y:-e},{x:0,y:-e/2}],`right|left`),"up|down":o(({height:e,midpoint:t,padding:n,width:r})=>[{x:r/2,y:0},{x:0,y:-n},{x:t,y:-n},{x:t,y:-e+n},{x:0,y:-e+n},{x:r/2,y:-e},{x:r,y:-e+n},{x:r-t,y:-e+n},{x:r-t,y:-n},{x:r,y:-n}],`up|down`),"right|up":o(({height:e,midpoint:t,width:n})=>[{x:0,y:0},{x:n,y:-t},{x:0,y:-e}],`right|up`),"right|down":o(({height:e,width:t})=>[{x:0,y:0},{x:t,y:0},{x:0,y:-e}],`right|down`),"left|up":o(({height:e,midpoint:t,width:n})=>[{x:n,y:0},{x:0,y:-t},{x:n,y:-e}],`left|up`),"left|down":o(({height:e,width:t})=>[{x:t,y:0},{x:0,y:0},{x:t,y:-e}],`left|down`),right:o(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:-n},{x:t,y:-n},{x:r-t,y:-n},{x:r-t,y:0},{x:r,y:-e/2},{x:r-t,y:-e},{x:r-t,y:-e+n},{x:t,y:-e+n},{x:t,y:-e+n}],`right`),left:o(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:0},{x:t,y:-n},{x:r-t,y:-n},{x:r-t,y:-e+n},{x:t,y:-e+n},{x:t,y:-e},{x:0,y:-e/2}],`left`),up:o(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:-n},{x:t,y:-e+n},{x:0,y:-e+n},{x:r/2,y:-e},{x:r,y:-e+n},{x:r-t,y:-e+n},{x:r-t,y:-n}],`up`),down:o(({height:e,midpoint:t,padding:n,width:r})=>[{x:r/2,y:0},{x:0,y:-n},{x:t,y:-n},{x:t,y:-e+n},{x:r-t,y:-e+n},{x:r-t,y:-n},{x:r,y:-n}],`down`),[_e]:()=>[{x:0,y:0}]},xe=o((e,t,n,r)=>{let i=ve(e),a=(n.padding??0)/2,o=t.height+4*a,s=o/2,c=r??t.width+2*s+2*a;return(be[ye(i)]??be[_e])({height:o,midpoint:s,padding:a,width:c})},`getArrowPoints`);async function Se(e,t){let n=t,{shapeSvg:r,bbox:i}=await j(e,n,P(n)),a=n.padding??0,o=i.height+2*a,s=o/2,c=i.width+2*s+a,l=n.width??0,u=n.positioned&&(n.widthInColumns??1)>1&&l>c?l:c,d=xe(n.directions??[],i,n,u),f=q(r,u,o,d);return f.attr(`style`,n.style??null),N(n,f),n.intersect=function(e){return K.polygon(n,d,e)},r}o(Se,`block_arrow`);async function Ce(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{shapeSvg:a,bbox:o,label:s}=await j(e,t,P(t)),c=n?.nodeBorder??n?.lineColor??`currentColor`,l=t.padding??12,u=Math.max(o.width+l*2,t.width??0,90),d=Math.max(o.height+l*2+18,t.height??0),f=-d/2,{cssStyles:p}=t,m=a.insert(`g`,`:first-child`).attr(`class`,`basic label-container`);if(t.look===`handDrawn`){let e=C.svg(a).path(z(-u/2,f,u,d,12),g(t,{}));m.node()?.appendChild(e),p&&m.attr(`style`,p)}else m.append(`rect`).attr(`x`,-u/2).attr(`y`,f).attr(`width`,u).attr(`height`,d).attr(`rx`,12).attr(`ry`,12).attr(`style`,i);m.append(`line`).attr(`x1`,-u/2).attr(`y1`,f+18).attr(`x2`,u/2).attr(`y2`,f+18).attr(`style`,`stroke:${c};stroke-width:1px`);for(let e=0;e<3;e++)m.append(`circle`).attr(`cx`,-u/2+12+e*9).attr(`cy`,f+9).attr(`r`,2.5).attr(`style`,`fill:${c};stroke:none`);m.append(`rect`).attr(`class`,`browser-address-bar`).attr(`x`,-u/2+44).attr(`y`,f+4).attr(`width`,Math.max(u-56,10)).attr(`height`,10).attr(`rx`,3).attr(`ry`,3).attr(`style`,`fill:none;stroke:${c};stroke-width:1px;opacity:0.6`),N(t,m);let h=f+18+(d-18)/2;return s.attr(`transform`,`translate(${-(o.width/2)-(o.x-(o.left??0))}, ${h-o.height/2-(o.y-(o.top??0))})`),t.intersect=function(e){return K.rect(t,e)},a}o(Ce,`browser`);var we=12;async function Te(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?28:i,o=t.look===`neo`?24:i,{shapeSvg:s,bbox:c}=await j(e,t,P(t)),l=(t?.width??c.width)+(t.look===`neo`?a*2:a+we),u=(t?.height??c.height)+(t.look===`neo`?o*2:o),d=l,f=-u,p=[{x:0+we,y:f},{x:d,y:f},{x:d,y:0},{x:0,y:0},{x:0,y:f+we},{x:0+we,y:f}],m,{cssStyles:h}=t;if(t.look===`handDrawn`){let e=C.svg(s),n=g(t,{}),r=F(p),i=e.path(r,n);m=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-l/2}, ${u/2})`),h&&m.attr(`style`,h)}else m=q(s,l,u,p);return r&&m.attr(`style`,r),N(t,m),t.intersect=function(e){return K.polygon(t,p,e)},s}o(Te,`card`);function Ee(e,t){let{nodeStyles:n}=_(t);t.label=``;let r=e.insert(`g`).attr(`class`,P(t)).attr(`id`,t.domId??t.id),{cssStyles:i}=t,a=Math.max(28,t.width??0),o=[{x:0,y:a/2},{x:a/2,y:0},{x:0,y:-a/2},{x:-a/2,y:0}],s=C.svg(r),c=g(t,{});t.look!==`handDrawn`&&(c.roughness=0,c.fillStyle=`solid`);let l=F(o),u=s.path(l,c),d=r.insert(()=>u,`:first-child`);return i&&t.look!==`handDrawn`&&d.selectAll(`path`).attr(`style`,i),n&&t.look!==`handDrawn`&&d.selectAll(`path`).attr(`style`,n),t.width=28,t.height=28,t.intersect=function(e){return K.polygon(t,o,e)},r}o(Ee,`choice`);async function De(e,t,n){let{labelStyles:a,nodeStyles:o}=_(t);t.labelStyle=a;let{shapeSvg:s,bbox:c,halfPadding:l}=await j(e,t,P(t)),u=n?.padding??l,d=t.look===`neo`?c.width/2+32:c.width/2+u,f,{cssStyles:p}=t;if(t.look===`handDrawn`){let e=C.svg(s),n=g(t,{}),i=e.circle(0,0,d*2,n);f=s.insert(()=>i,`:first-child`),f.attr(`class`,`basic label-container`).attr(`style`,r(p))}else f=s.insert(`circle`,`:first-child`).attr(`class`,`basic label-container`).attr(`style`,o).attr(`r`,d).attr(`cx`,0).attr(`cy`,0);return N(t,f),t.calcIntersect=function(e,t){let n=e.width/2;return K.circle(e,n,t)},t.intersect=function(e){return i.info(`Circle intersect`,t,d,e),K.circle(t,d,e)},s}o(De,`circle`);async function Oe(e,t){let n=t,{shapeSvg:r,bbox:i,halfPadding:a}=await j(e,n,[`node`,n.cssClasses,n.class].filter(Boolean).join(` `)),o=r.insert(`rect`,`:first-child`),s=n.padding??0,c=n.positioned?n.width??0:i.width+s,l=n.positioned?n.height??0:i.height+s,u=n.positioned?-c/2:-i.width/2-a,d=n.positioned?-l/2:-i.height/2-a;return o.attr(`class`,`basic cluster composite label-container`).attr(`style`,n.style??null).attr(`rx`,n.rx??null).attr(`ry`,n.ry??null).attr(`x`,u).attr(`y`,d).attr(`width`,c).attr(`height`,l),N(n,o),n.intersect=function(e){return K.rect(n,e)},r}o(Oe,`composite`);async function ke(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{shapeSvg:a,bbox:o,label:s}=await j(e,t,P(t)),c=n?.nodeBorder??n?.lineColor??`currentColor`,l=t.padding??12,u=Math.max(o.width+l*2,t.width??0,90),d=Math.max(o.height+l*2+20,t.height??0),f=-d/2,{cssStyles:p}=t,m=a.insert(`g`,`:first-child`).attr(`class`,`basic label-container`);if(t.look===`handDrawn`){let e=C.svg(a).path(z(-u/2,f,u,d,12),g(t,{}));m.node()?.appendChild(e),p&&m.attr(`style`,p)}else m.append(`rect`).attr(`x`,-u/2).attr(`y`,f).attr(`width`,u).attr(`height`,d).attr(`rx`,12).attr(`ry`,12).attr(`style`,i);m.append(`text`).attr(`x`,-u/2+12).attr(`y`,f+16).attr(`class`,`console-glyph`).attr(`style`,`font-family:monospace;font-weight:bold;font-size:14px;fill:${c}`).text(`>_`),N(t,m);let h=f+20+(d-20)/2;return s.attr(`transform`,`translate(${-(o.width/2)-(o.x-(o.left??0))}, ${h-o.height/2-(o.y-(o.top??0))})`),t.intersect=function(e){return K.rect(t,e)},a}o(ke,`consoleWindow`);function Ae(e){let t=Math.cos(Math.PI/4),n=Math.sin(Math.PI/4),r=e*2,i={x:r/2*t,y:r/2*n},a={x:-(r/2)*t,y:r/2*n},o={x:-(r/2)*t,y:-(r/2)*n},s={x:r/2*t,y:-(r/2)*n};return`M ${a.x},${a.y} L ${s.x},${s.y}
1
+ import{a as e,p as t,r as n,u as r}from"./chunk-75Z2AOVW-C_A1Se9D.js";import{n as i,t as a}from"./src-KUZZYZBk.js";import{n as o}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{A as s,B as c,M as l,T as u,b as d,f,g as p,x as m,z as h}from"./chunk-DU6HZSFF-Dr7PaN7b.js";import{a as g,i as _,r as v,t as y}from"./chunk-P2QGCYS3-Dtm_7Lz7.js";import{t as b}from"./chunk-PWAF6VOD-CyHOdyql.js";import{n as x,r as S}from"./chunk-GMAD6QVW-BFHBOVJq.js";import{t as C}from"./rough.esm-Dy-Kn_BL.js";var w=1,T=3;async function E(e){let n=e.getElementsByTagName(`img`);if(!n||n.length===0)return;let r=!D(e);await Promise.all([...n].map(e=>new Promise(n=>{function i(){if(e.style.display=`flex`,e.style.flexDirection=`column`,r){let n=m().fontSize?m().fontSize:window.getComputedStyle(document.body).fontSize,[r=f.fontSize]=t(n),i=r*5+`px`;e.style.minWidth=i,e.style.maxWidth=i}else e.style.width=`100%`;n(e)}o(i,`setupImage`),setTimeout(()=>{e.complete&&i()}),e.addEventListener(`error`,i),e.addEventListener(`load`,i)})))}o(E,`configureLabelImages`);function D(e){return e.nodeType===T?e.textContent?.trim()!==``:e.nodeType!==w||e.tagName.toLowerCase()===`img`?!1:[...e.childNodes].some(D)}o(D,`hasTextBesidesImages`);var O=3,k=32,A=o(async(t,n,i)=>{let o=m(),s=t.insert(`g`).attr(`class`,i??`node default`).attr(`id`,n.domId||n.id),c=s.insert(`g`).attr(`class`,`label`).attr(`style`,r(n.labelStyle)),l=[{text:typeof n.label==`string`?n.label:n.label?.[0]??``,cssClass:`c4-name`},{text:n.stereotype,cssClass:`c4-type`},...(n.description??[]).map(e=>({text:e,cssClass:`c4-descr`}))].filter(e=>e.text),u=n.width?Math.max(n.width-2*(n.padding??0),k):m().flowchart?.wrappingWidth??200,d=o.c4?.wrap??!0?u:1/0,f=await Promise.all(l.map(async t=>{let r=c.append(`g`).attr(`class`,t.cssClass),i=await x(r,h(e(t.text??``),o),{useHtmlLabels:!1,markdown:!1,isNode:!0,width:d,style:n.labelStyle},o);return a(i).selectAll(`tspan.text-outer-tspan`).attr(`text-anchor`,`middle`),a(i).selectAll(`tspan.text-inner-tspan`).attr(`font-weight`,null).attr(`font-style`,null),{el:r,box:r.node().getBBox()}})),p=Math.max(...f.map(({box:e})=>e.width),0),g=0;for(let{el:e,box:t}of f)e.attr(`transform`,`translate(${p/2-t.x-t.width/2}, ${g-t.y})`),g+=t.height+O;let _=f.length>0?g-O:0;return c.insert(`rect`,`:first-child`),c.attr(`transform`,`translate(${-p/2}, ${-_/2})`),{shapeSvg:s,bbox:c.node().getBBox(),halfPadding:(n.padding??0)/2,label:c}},`c4LabelHelper`),j=o(async(t,n,i)=>{if(n.stereotype!==void 0)return A(t,n,i);let o,s=n.useHtmlLabels||p(m()?.htmlLabels);o=i||`node default`;let c=t.insert(`g`).attr(`class`,o).attr(`id`,n.domId||n.id),l=c.insert(`g`).attr(`class`,`label`).attr(`style`,r(n.labelStyle)),u;u=n.label===void 0?``:typeof n.label==`string`?n.label:n.label[0];let d=!!n.icon||!!n.img,f=n.labelType===`markdown`,g=await x(l,h(e(u),m()),{useHtmlLabels:s,width:n.width||n.wrappingWidth||m().flowchart?.wrappingWidth,classes:f?`markdown-node-label`:``,style:n.labelStyle,addSvgBackground:d,markdown:f},m()),_=(n?.padding??0)/2,v;if(s){let e=g.children[0],t=a(g);await E(e),v=await S.measure(()=>e.getBoundingClientRect()),t.attr(`width`,v.width),t.attr(`height`,v.height)}else v=await S.measure(()=>g.getBBox());return s?l.attr(`transform`,`translate(`+-v.width/2+`, `+-v.height/2+`)`):l.attr(`transform`,`translate(0, `+-v.height/2+`)`),n.centerLabel&&l.attr(`transform`,`translate(`+-v.width/2+`, `+-v.height/2+`)`),l.insert(`rect`,`:first-child`),{shapeSvg:c,bbox:v,halfPadding:_,label:l}},`labelHelper`),M=o(async(t,n,r)=>{let i=r.useHtmlLabels??u(m()),o=t.insert(`g`).attr(`class`,`label`).attr(`style`,r.labelStyle||``),s=await x(o,h(e(n),m()),{useHtmlLabels:i,width:r.width||m()?.flowchart?.wrappingWidth,style:r.labelStyle,addSvgBackground:!!r.icon||!!r.img}),c=r.padding/2,l;if(u(m())){let e=s.children[0],t=a(s);l=await S.measure(()=>e.getBoundingClientRect()),t.attr(`width`,l.width),t.attr(`height`,l.height)}else l=await S.measure(()=>s.getBBox());return i?o.attr(`transform`,`translate(`+-l.width/2+`, `+-l.height/2+`)`):o.attr(`transform`,`translate(0, `+-l.height/2+`)`),r.centerLabel&&o.attr(`transform`,`translate(`+-l.width/2+`, `+-l.height/2+`)`),o.insert(`rect`,`:first-child`),{shapeSvg:t,bbox:l,halfPadding:c,label:o}},`insertLabel`),N=o((e,t,n)=>{if(n){e.width=n.width,e.height=n.height;return}let r=t.node().getBBox();e.width=r.width,e.height=r.height},`updateNodeBounds`),P=o((e,t)=>(e.look===`handDrawn`?`rough-node`:`node`)+` `+e.cssClasses+` `+(t||``),`getNodeClasses`);function F(e){let t=e.map((e,t)=>`${t===0?`M`:`L`}${e.x},${e.y}`);return t.push(`Z`),t.join(` `)}o(F,`createPathFromPoints`);function I(e,t,n,r,i,a){let o=[],s=n-e,c=r-t,l=s/a,u=2*Math.PI/l,d=t+c/2;for(let t=0;t<=50;t++){let n=e+t/50*s,r=d+i*Math.sin(u*(n-e));o.push({x:n,y:r})}return o}o(I,`generateFullSineWavePoints`);function L(e,t,n,r,i,a){let o=[],s=i*Math.PI/180,c=(a*Math.PI/180-s)/(r-1);for(let i=0;i<r;i++){let r=s+i*c,a=e+n*Math.cos(r),l=t+n*Math.sin(r);o.push({x:-a,y:-l})}return o}o(L,`generateCirclePoints`);function ee(e){let t=Array.from(e.childNodes).filter(e=>e.tagName===`path`),n=document.createElementNS(`http://www.w3.org/2000/svg`,`path`),r=t.map(e=>e.getAttribute(`d`)).filter(e=>e!==null).join(` `);n.setAttribute(`d`,r);let i=t.find(e=>e.getAttribute(`fill`)!==`none`),a=t.find(e=>e.getAttribute(`stroke`)!==`none`),s=o((e,t)=>e?.getAttribute(t)??void 0,`getAttr`);if(i){let e={fill:s(i,`fill`),"fill-opacity":s(i,`fill-opacity`)??`1`};Object.entries(e).forEach(([e,t])=>{t&&n.setAttribute(e,t)})}if(a){let e={stroke:s(a,`stroke`),"stroke-width":s(a,`stroke-width`)??`1`,"stroke-opacity":s(a,`stroke-opacity`)??`1`};Object.entries(e).forEach(([e,t])=>{t&&n.setAttribute(e,t)})}let c=document.createElementNS(`http://www.w3.org/2000/svg`,`g`);return c.appendChild(n),c}o(ee,`mergePaths`);var R=o((e,t)=>{var n=e.x,r=e.y,i=t.x-n,a=t.y-r,o=e.width/2,s=e.height/2,c,l;return Math.abs(a)*o>Math.abs(i)*s?(a<0&&(s=-s),c=a===0?0:s*i/a,l=s):(i<0&&(o=-o),c=o,l=i===0?0:o*a/i),{x:n+c,y:r+l}},`intersectRect`),z=o((e,t,n,r,i)=>[`M`,e+i,t,`H`,e+n-i,`A`,i,i,0,0,1,e+n,t+i,`V`,t+r-i,`A`,i,i,0,0,1,e+n-i,t+r,`H`,e+i,`A`,i,i,0,0,1,e,t+r-i,`V`,t+i,`A`,i,i,0,0,1,e+i,t,`Z`].join(` `),`createRoundedRectPathD`),te=o(async(e,t,n,r=!1,i=!1)=>{let a=t||``;typeof a==`object`&&(a=a[0]);let o=m(),s=u(o);return await x(e,a,{style:n,isTitle:r,useHtmlLabels:s,markdown:!1,isNode:i,width:1/0},o)},`createLabel`);function B(e,t){return e.intersect(t)}o(B,`intersectNode`);var ne=B;function V(e,t,n,r){var i=e.x,a=e.y,o=i-r.x,s=a-r.y,c=Math.sqrt(t*t*s*s+n*n*o*o),l=Math.abs(t*n*o/c);r.x<i&&(l=-l);var u=Math.abs(t*n*s/c);return r.y<a&&(u=-u),{x:i+l,y:a+u}}o(V,`intersectEllipse`);var H=V;function re(e,t,n){return H(e,t,t,n)}o(re,`intersectCircle`);var ie=re;function U(e,t,n,r){{let i=t.y-e.y,a=e.x-t.x,o=t.x*e.y-e.x*t.y,s=i*n.x+a*n.y+o,c=i*r.x+a*r.y+o,l=1e-6;if(s!==0&&c!==0&&W(s,c))return;let u=r.y-n.y,d=n.x-r.x,f=r.x*n.y-n.x*r.y,p=u*e.x+d*e.y+f,m=u*t.x+d*t.y+f;if(Math.abs(p)<l&&Math.abs(m)<l&&W(p,m))return;let h=i*d-u*a;if(h===0)return;let g=Math.abs(h/2),_=a*f-d*o,v=_<0?(_-g)/h:(_+g)/h;return _=u*o-i*f,{x:v,y:_<0?(_-g)/h:(_+g)/h}}}o(U,`intersectLine`);function W(e,t){return e*t>0}o(W,`sameSign`);var G=U;function ae(e,t,n){let r=e.x,i=e.y,a=[],o=1/0,s=1/0;typeof t.forEach==`function`?t.forEach(function(e){o=Math.min(o,e.x),s=Math.min(s,e.y)}):(o=Math.min(o,t.x),s=Math.min(s,t.y));let c=r-e.width/2-o,l=i-e.height/2-s;for(let r=0;r<t.length;r++){let i=t[r],o=t[r<t.length-1?r+1:0],s=G(e,n,{x:c+i.x,y:l+i.y},{x:c+o.x,y:l+o.y});s&&a.push(s)}return a.length?(a.length>1&&a.sort(function(e,t){let r=e.x-n.x,i=e.y-n.y,a=Math.sqrt(r*r+i*i),o=t.x-n.x,s=t.y-n.y,c=Math.sqrt(o*o+s*s);return a<c?-1:a===c?0:1}),a[0]):e}o(ae,`intersectPolygon`);var K={node:ne,circle:ie,ellipse:H,polygon:ae,rect:R};function oe(e,t){let{labelStyles:n}=_(t);t.labelStyle=n;let a=P(t),o=a;a||(o=`anchor`);let s=e.insert(`g`).attr(`class`,o).attr(`id`,t.domId||t.id),{cssStyles:c}=t,l=C.svg(s),u=g(t,{fill:`black`,stroke:`none`,fillStyle:`solid`});t.look!==`handDrawn`&&(u.roughness=0);let d=l.circle(0,0,2,u),f=s.insert(()=>d,`:first-child`);return f.attr(`class`,`anchor`).attr(`style`,r(c)),N(t,f),t.intersect=function(e){return i.info(`Circle intersect`,t,1,e),K.circle(t,1,e)},s}o(oe,`anchor`);function se(e,t,n,r,i,a,o){let s=(e+n)/2,c=(t+r)/2,l=Math.atan2(r-t,n-e),u=(n-e)/2,d=(r-t)/2,f=u/i,p=d/a,m=Math.sqrt(f**2+p**2);if(m>1)throw Error(`The given radii are too small to create an arc between the points.`);let h=Math.sqrt(1-m**2),g=s+h*a*Math.sin(l)*(o?-1:1),_=c-h*i*Math.cos(l)*(o?-1:1),v=Math.atan2((t-_)/a,(e-g)/i),y=Math.atan2((r-_)/a,(n-g)/i)-v;o&&y<0&&(y+=2*Math.PI),!o&&y>0&&(y-=2*Math.PI);let b=[];for(let e=0;e<20;e++){let t=v+e/19*y,n=g+i*Math.cos(t),r=_+a*Math.sin(t);b.push({x:n,y:r})}return b}o(se,`generateArcPoints`);function ce(e,t,n){let[r,i]=[t,n].sort((e,t)=>t-e);return i*(1-Math.sqrt(1-(e/r/2)**2))}o(ce,`calculateArcSagitta`);async function le(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,s=t.look===`neo`?12:i,c=o(e=>e+s,`calcTotalHeight`),l=o(e=>{let t=e/2;return[t/(2.5+e/50),t]},`calcEllipseRadius`),{shapeSvg:u,bbox:d}=await j(e,t,P(t)),f=c(t?.height?t?.height:d.height),[p,m]=l(f),h=ce(f,p,m),v=(t?.width?t?.width:d.width)+a*2+h-h,y=f,{cssStyles:b}=t,x=[{x:v/2,y:-y/2},{x:-v/2,y:-y/2},...se(-v/2,-y/2,-v/2,y/2,p,m,!1),{x:v/2,y:y/2},...se(v/2,y/2,v/2,-y/2,p,m,!0)],S=C.svg(u),w=g(t,{});t.look!==`handDrawn`&&(w.roughness=0,w.fillStyle=`solid`);let T=F(x),E=S.path(T,w),D=u.insert(()=>E,`:first-child`);return D.attr(`class`,`basic label-container outer-path`),b&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,b),r&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,r),D.attr(`transform`,`translate(${p/2}, 0)`),N(t,D),t.intersect=function(e){return K.polygon(t,x,e)},u}o(le,`bowTieRect`);async function ue(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{shapeSvg:a,bbox:s,label:c}=await j(e,t,P(t)),l=n?.nodeBorder??n?.lineColor??`currentColor`,u=t.padding??12,d=Math.max(s.width+u*2,t.width??0,80),f=Math.max(Math.min(d*.08,12),5),p=Math.max(s.height+u*2+f,t.height??0),m=-p/2+f,h=p/2,v=d*.72,y=[`M${-d/2},${m}`,`L${-v/2},${h}`,`A${v/2},${f} 0 0 0 ${v/2},${h}`,`L${d/2},${m}`,`A${d/2},${f} 0 0 0 ${-d/2},${m}`,`Z`].join(` `),{cssStyles:b}=t,x=a.insert(`g`,`:first-child`).attr(`class`,`basic label-container`);if(t.look===`handDrawn`){let e=C.svg(a).path(y,g(t,{}));x.node()?.appendChild(e),b&&x.attr(`style`,b)}else x.append(`path`).attr(`d`,y).attr(`style`,i);x.append(`ellipse`).attr(`cx`,0).attr(`cy`,m).attr(`rx`,d/2).attr(`ry`,f).attr(`style`,`fill:none;stroke:${l};stroke-width:1px`),N(t,x);let S=m+(h-m)/2;c.attr(`transform`,`translate(${-(s.width/2)-(s.x-(s.left??0))}, ${S-s.height/2-(s.y-(s.top??0))})`);let w=o((e,t,n)=>Array.from({length:13},(r,i)=>{let a=Math.PI-i*Math.PI/12;return{x:e*Math.cos(a),y:t+n*f*Math.sin(a)}}),`arc`),T=[...w(d/2,m,-1),...w(v/2,h,1).reverse()];return t.intersect=function(e){return K.polygon(t,T,e)},a}o(ue,`bucket`);var de=20,fe=8,pe=80,me=8;async function he(e,t){let{themeVariables:n}=m(),i=n.clusterBkg,a=n.clusterBorder,{nodeStyles:o}=_(t),{shapeSvg:s,bbox:c}=await j(e,t,P(t)),l=t.padding??8,d=c.height,f=Math.max(c.width+l*2,pe,t?.width??0),p=Math.max(d+fe+de+l*2,t?.height??0),h=-f/2,v=-p/2,y=-(fe+de)/2,b=s.select(`.label`);b&&(t.useHtmlLabels??u(m())?b.attr(`transform`,`translate(${-c.width/2}, ${-c.height/2+y})`):b.attr(`transform`,`translate(0, ${-c.height/2+y})`));let x;if(t.look===`handDrawn`){let e=C.svg(s),n=g(t,{fill:i,stroke:a,fillStyle:`solid`}),o=e.path(z(h,v,f,p,me),n);x=s.insert(()=>o,`:first-child`),x.attr(`class`,`basic label-container collapsed-group`).attr(`style`,r(t.cssStyles))}else x=s.insert(`rect`,`:first-child`),x.attr(`class`,`basic label-container collapsed-group`).attr(`style`,o).attr(`rx`,me).attr(`ry`,me).attr(`x`,h).attr(`y`,v).attr(`width`,f).attr(`height`,p).attr(`fill`,i).attr(`stroke`,a);let S=v+l+d+fe;s.append(`line`).attr(`class`,`collapsed-separator`).attr(`x1`,h+8).attr(`y1`,S).attr(`x2`,h+f-8).attr(`y2`,S).attr(`stroke`,a).attr(`stroke-dasharray`,`3, 3`);let w=S+de/2;for(let e=-1;e<=1;e++)s.append(`circle`).attr(`class`,`collapsed-indicator`).attr(`cx`,e*10).attr(`cy`,w).attr(`r`,2.5).attr(`fill`,a);return N(t,x),t.calcIntersect=function(e,t){return K.rect(e,t)},t.intersect=function(e){return K.rect(t,e)},s}o(he,`collapsedGroup`);function q(e,t,n,r){return e.insert(`polygon`,`:first-child`).attr(`points`,r.map(function(e){return e.x+`,`+e.y}).join(` `)).attr(`class`,`label-container`).attr(`transform`,`translate(`+-t/2+`,`+n/2+`)`)}o(q,`insertPolygonShape`);var ge=[`right`,`left`,`up`,`down`],_e=`point`,ve=o(e=>{let t=new Set;for(let n of e)switch(n){case`x`:t.add(`right`),t.add(`left`);break;case`y`:t.add(`up`),t.add(`down`);break;default:t.add(n)}return t},`expandAndDeduplicateDirections`),ye=o(e=>ge.filter(t=>e.has(t)).join(`|`)||_e,`getDirectionKey`),be={"right|left|up|down":o(({height:e,midpoint:t,padding:n,width:r})=>[{x:0,y:0},{x:t,y:0},{x:r/2,y:2*n},{x:r-t,y:0},{x:r,y:0},{x:r,y:-e/3},{x:r+2*n,y:-e/2},{x:r,y:-2*e/3},{x:r,y:-e},{x:r-t,y:-e},{x:r/2,y:-e-2*n},{x:t,y:-e},{x:0,y:-e},{x:0,y:-2*e/3},{x:-2*n,y:-e/2},{x:0,y:-e/3}],`right|left|up|down`),"right|left|up":o(({height:e,midpoint:t,width:n})=>[{x:t,y:0},{x:n-t,y:0},{x:n,y:-e/2},{x:n-t,y:-e},{x:t,y:-e},{x:0,y:-e/2}],`right|left|up`),"right|left|down":o(({height:e,midpoint:t,width:n})=>[{x:0,y:0},{x:t,y:-e},{x:n-t,y:-e},{x:n,y:0}],`right|left|down`),"right|up|down":o(({height:e,midpoint:t,width:n})=>[{x:0,y:0},{x:n,y:-t},{x:n,y:-e+t},{x:0,y:-e}],`right|up|down`),"left|up|down":o(({height:e,midpoint:t,width:n})=>[{x:n,y:0},{x:0,y:-t},{x:0,y:-e+t},{x:n,y:-e}],`left|up|down`),"right|left":o(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:0},{x:t,y:-n},{x:r-t,y:-n},{x:r-t,y:0},{x:r,y:-e/2},{x:r-t,y:-e},{x:r-t,y:-e+n},{x:t,y:-e+n},{x:t,y:-e},{x:0,y:-e/2}],`right|left`),"up|down":o(({height:e,midpoint:t,padding:n,width:r})=>[{x:r/2,y:0},{x:0,y:-n},{x:t,y:-n},{x:t,y:-e+n},{x:0,y:-e+n},{x:r/2,y:-e},{x:r,y:-e+n},{x:r-t,y:-e+n},{x:r-t,y:-n},{x:r,y:-n}],`up|down`),"right|up":o(({height:e,midpoint:t,width:n})=>[{x:0,y:0},{x:n,y:-t},{x:0,y:-e}],`right|up`),"right|down":o(({height:e,width:t})=>[{x:0,y:0},{x:t,y:0},{x:0,y:-e}],`right|down`),"left|up":o(({height:e,midpoint:t,width:n})=>[{x:n,y:0},{x:0,y:-t},{x:n,y:-e}],`left|up`),"left|down":o(({height:e,width:t})=>[{x:t,y:0},{x:0,y:0},{x:t,y:-e}],`left|down`),right:o(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:-n},{x:t,y:-n},{x:r-t,y:-n},{x:r-t,y:0},{x:r,y:-e/2},{x:r-t,y:-e},{x:r-t,y:-e+n},{x:t,y:-e+n},{x:t,y:-e+n}],`right`),left:o(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:0},{x:t,y:-n},{x:r-t,y:-n},{x:r-t,y:-e+n},{x:t,y:-e+n},{x:t,y:-e},{x:0,y:-e/2}],`left`),up:o(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:-n},{x:t,y:-e+n},{x:0,y:-e+n},{x:r/2,y:-e},{x:r,y:-e+n},{x:r-t,y:-e+n},{x:r-t,y:-n}],`up`),down:o(({height:e,midpoint:t,padding:n,width:r})=>[{x:r/2,y:0},{x:0,y:-n},{x:t,y:-n},{x:t,y:-e+n},{x:r-t,y:-e+n},{x:r-t,y:-n},{x:r,y:-n}],`down`),[_e]:()=>[{x:0,y:0}]},xe=o((e,t,n,r)=>{let i=ve(e),a=(n.padding??0)/2,o=t.height+4*a,s=o/2,c=r??t.width+2*s+2*a;return(be[ye(i)]??be[_e])({height:o,midpoint:s,padding:a,width:c})},`getArrowPoints`);async function Se(e,t){let n=t,{shapeSvg:r,bbox:i}=await j(e,n,P(n)),a=n.padding??0,o=i.height+2*a,s=o/2,c=i.width+2*s+a,l=n.width??0,u=n.positioned&&(n.widthInColumns??1)>1&&l>c?l:c,d=xe(n.directions??[],i,n,u),f=q(r,u,o,d);return f.attr(`style`,n.style??null),N(n,f),n.intersect=function(e){return K.polygon(n,d,e)},r}o(Se,`block_arrow`);async function Ce(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{shapeSvg:a,bbox:o,label:s}=await j(e,t,P(t)),c=n?.nodeBorder??n?.lineColor??`currentColor`,l=t.padding??12,u=Math.max(o.width+l*2,t.width??0,90),d=Math.max(o.height+l*2+18,t.height??0),f=-d/2,{cssStyles:p}=t,m=a.insert(`g`,`:first-child`).attr(`class`,`basic label-container`);if(t.look===`handDrawn`){let e=C.svg(a).path(z(-u/2,f,u,d,12),g(t,{}));m.node()?.appendChild(e),p&&m.attr(`style`,p)}else m.append(`rect`).attr(`x`,-u/2).attr(`y`,f).attr(`width`,u).attr(`height`,d).attr(`rx`,12).attr(`ry`,12).attr(`style`,i);m.append(`line`).attr(`x1`,-u/2).attr(`y1`,f+18).attr(`x2`,u/2).attr(`y2`,f+18).attr(`style`,`stroke:${c};stroke-width:1px`);for(let e=0;e<3;e++)m.append(`circle`).attr(`cx`,-u/2+12+e*9).attr(`cy`,f+9).attr(`r`,2.5).attr(`style`,`fill:${c};stroke:none`);m.append(`rect`).attr(`class`,`browser-address-bar`).attr(`x`,-u/2+44).attr(`y`,f+4).attr(`width`,Math.max(u-56,10)).attr(`height`,10).attr(`rx`,3).attr(`ry`,3).attr(`style`,`fill:none;stroke:${c};stroke-width:1px;opacity:0.6`),N(t,m);let h=f+18+(d-18)/2;return s.attr(`transform`,`translate(${-(o.width/2)-(o.x-(o.left??0))}, ${h-o.height/2-(o.y-(o.top??0))})`),t.intersect=function(e){return K.rect(t,e)},a}o(Ce,`browser`);var we=12;async function Te(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?28:i,o=t.look===`neo`?24:i,{shapeSvg:s,bbox:c}=await j(e,t,P(t)),l=(t?.width??c.width)+(t.look===`neo`?a*2:a+we),u=(t?.height??c.height)+(t.look===`neo`?o*2:o),d=l,f=-u,p=[{x:0+we,y:f},{x:d,y:f},{x:d,y:0},{x:0,y:0},{x:0,y:f+we},{x:0+we,y:f}],m,{cssStyles:h}=t;if(t.look===`handDrawn`){let e=C.svg(s),n=g(t,{}),r=F(p),i=e.path(r,n);m=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-l/2}, ${u/2})`),h&&m.attr(`style`,h)}else m=q(s,l,u,p);return r&&m.attr(`style`,r),N(t,m),t.intersect=function(e){return K.polygon(t,p,e)},s}o(Te,`card`);function Ee(e,t){let{nodeStyles:n}=_(t);t.label=``;let r=e.insert(`g`).attr(`class`,P(t)).attr(`id`,t.domId??t.id),{cssStyles:i}=t,a=Math.max(28,t.width??0),o=[{x:0,y:a/2},{x:a/2,y:0},{x:0,y:-a/2},{x:-a/2,y:0}],s=C.svg(r),c=g(t,{});t.look!==`handDrawn`&&(c.roughness=0,c.fillStyle=`solid`);let l=F(o),u=s.path(l,c),d=r.insert(()=>u,`:first-child`);return i&&t.look!==`handDrawn`&&d.selectAll(`path`).attr(`style`,i),n&&t.look!==`handDrawn`&&d.selectAll(`path`).attr(`style`,n),t.width=28,t.height=28,t.intersect=function(e){return K.polygon(t,o,e)},r}o(Ee,`choice`);async function De(e,t,n){let{labelStyles:a,nodeStyles:o}=_(t);t.labelStyle=a;let{shapeSvg:s,bbox:c,halfPadding:l}=await j(e,t,P(t)),u=n?.padding??l,d=t.look===`neo`?c.width/2+32:c.width/2+u,f,{cssStyles:p}=t;if(t.look===`handDrawn`){let e=C.svg(s),n=g(t,{}),i=e.circle(0,0,d*2,n);f=s.insert(()=>i,`:first-child`),f.attr(`class`,`basic label-container`).attr(`style`,r(p))}else f=s.insert(`circle`,`:first-child`).attr(`class`,`basic label-container`).attr(`style`,o).attr(`r`,d).attr(`cx`,0).attr(`cy`,0);return N(t,f),t.calcIntersect=function(e,t){let n=e.width/2;return K.circle(e,n,t)},t.intersect=function(e){return i.info(`Circle intersect`,t,d,e),K.circle(t,d,e)},s}o(De,`circle`);async function Oe(e,t){let n=t,{shapeSvg:r,bbox:i,halfPadding:a}=await j(e,n,[`node`,n.cssClasses,n.class].filter(Boolean).join(` `)),o=r.insert(`rect`,`:first-child`),s=n.padding??0,c=n.positioned?n.width??0:i.width+s,l=n.positioned?n.height??0:i.height+s,u=n.positioned?-c/2:-i.width/2-a,d=n.positioned?-l/2:-i.height/2-a;return o.attr(`class`,`basic cluster composite label-container`).attr(`style`,n.style??null).attr(`rx`,n.rx??null).attr(`ry`,n.ry??null).attr(`x`,u).attr(`y`,d).attr(`width`,c).attr(`height`,l),N(n,o),n.intersect=function(e){return K.rect(n,e)},r}o(Oe,`composite`);async function ke(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{shapeSvg:a,bbox:o,label:s}=await j(e,t,P(t)),c=n?.nodeBorder??n?.lineColor??`currentColor`,l=t.padding??12,u=Math.max(o.width+l*2,t.width??0,90),d=Math.max(o.height+l*2+20,t.height??0),f=-d/2,{cssStyles:p}=t,m=a.insert(`g`,`:first-child`).attr(`class`,`basic label-container`);if(t.look===`handDrawn`){let e=C.svg(a).path(z(-u/2,f,u,d,12),g(t,{}));m.node()?.appendChild(e),p&&m.attr(`style`,p)}else m.append(`rect`).attr(`x`,-u/2).attr(`y`,f).attr(`width`,u).attr(`height`,d).attr(`rx`,12).attr(`ry`,12).attr(`style`,i);m.append(`text`).attr(`x`,-u/2+12).attr(`y`,f+16).attr(`class`,`console-glyph`).attr(`style`,`font-family:monospace;font-weight:bold;font-size:14px;fill:${c}`).text(`>_`),N(t,m);let h=f+20+(d-20)/2;return s.attr(`transform`,`translate(${-(o.width/2)-(o.x-(o.left??0))}, ${h-o.height/2-(o.y-(o.top??0))})`),t.intersect=function(e){return K.rect(t,e)},a}o(ke,`consoleWindow`);function Ae(e){let t=Math.cos(Math.PI/4),n=Math.sin(Math.PI/4),r=e*2,i={x:r/2*t,y:r/2*n},a={x:-(r/2)*t,y:r/2*n},o={x:-(r/2)*t,y:-(r/2)*n},s={x:r/2*t,y:-(r/2)*n};return`M ${a.x},${a.y} L ${s.x},${s.y}
2
2
  M ${i.x},${i.y} L ${o.x},${o.y}`}o(Ae,`createLine`);function je(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n,t.label=``;let a=e.insert(`g`).attr(`class`,P(t)).attr(`id`,t.domId??t.id),o=Math.max(30,t?.width??0),{cssStyles:s}=t,c=C.svg(a),l=g(t,{});t.look!==`handDrawn`&&(l.roughness=0,l.fillStyle=`solid`);let u=c.circle(0,0,o*2,l),d=Ae(o),f=c.path(d,l),p=a.insert(()=>u,`:first-child`);return p.insert(()=>f),p.attr(`class`,`outer-path`),s&&t.look!==`handDrawn`&&p.selectAll(`path`).attr(`style`,s),r&&t.look!==`handDrawn`&&p.selectAll(`path`).attr(`style`,r),N(t,p),t.intersect=function(e){return i.info(`crossedCircle intersect`,t,{radius:o,point:e}),K.circle(t,o,e)},a}o(je,`crossedCircle`);function J(e,t,n,r=100,i=0,a=180){let o=[],s=i*Math.PI/180,c=(a*Math.PI/180-s)/(r-1);for(let i=0;i<r;i++){let r=s+i*c,a=e+n*Math.cos(r),l=t+n*Math.sin(r);o.push({x:-a,y:-l})}return o}o(J,`generateCirclePoints`);async function Me(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await j(e,t,P(t)),s=t.look===`neo`?18:t.padding??0,c=t.look===`neo`?12:t.padding??0,l=a.width+s,u=a.height+c,d=Math.max(5,u*.1),{cssStyles:f}=t,p=[...J(l/2,-u/2,d,30,-90,0),{x:-l/2-d,y:d},...J(l/2+d*2,-d,d,20,-180,-270),...J(l/2+d*2,d,d,20,-90,-180),{x:-l/2-d,y:-u/2},...J(l/2,u/2,d,20,0,90)],m=[{x:l/2,y:-u/2-d},{x:-l/2,y:-u/2-d},...J(l/2,-u/2,d,20,-90,0),{x:-l/2-d,y:-d},...J(l/2+l*.1,-d,d,20,-180,-270),...J(l/2+l*.1,d,d,20,-90,-180),{x:-l/2-d,y:u/2},...J(l/2,u/2,d,20,0,90),{x:-l/2,y:u/2+d},{x:l/2,y:u/2+d}],h=C.svg(i),v=g(t,{fill:`none`});t.look!==`handDrawn`&&(v.roughness=0,v.fillStyle=`solid`);let y=F(p).replace(`Z`,``),b=h.path(y,v),x=F(m),S=h.path(x,{...v}),w=i.insert(`g`,`:first-child`);return w.insert(()=>S,`:first-child`).attr(`stroke-opacity`,0),w.insert(()=>b,`:first-child`),w.attr(`class`,`text`),f&&t.look!==`handDrawn`&&w.selectAll(`path`).attr(`style`,f),r&&t.look!==`handDrawn`&&w.selectAll(`path`).attr(`style`,r),w.attr(`transform`,`translate(${d}, 0)`),o.attr(`transform`,`translate(${-l/2+d-(a.x-(a.left??0))},${-u/2+(t.padding??0)/2-(a.y-(a.top??0))})`),N(t,w),t.intersect=function(e){return K.polygon(t,m,e)},i}o(Me,`curlyBraceLeft`);function Y(e,t,n,r=100,i=0,a=180){let o=[],s=i*Math.PI/180,c=(a*Math.PI/180-s)/(r-1);for(let i=0;i<r;i++){let r=s+i*c,a=e+n*Math.cos(r),l=t+n*Math.sin(r);o.push({x:a,y:l})}return o}o(Y,`generateCirclePoints`);async function Ne(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await j(e,t,P(t)),s=t.look===`neo`?18:t.padding??0,c=t.look===`neo`?12:t.padding??0,l=a.width+(t.look===`neo`?s*2:s),u=a.height+(t.look===`neo`?c*2:c),d=Math.max(5,u*.1),{cssStyles:f}=t,p=[...Y(l/2,-u/2,d,20,-90,0),{x:l/2+d,y:-d},...Y(l/2+d*2,-d,d,20,-180,-270),...Y(l/2+d*2,d,d,20,-90,-180),{x:l/2+d,y:u/2},...Y(l/2,u/2,d,20,0,90)],m=[{x:-l/2,y:-u/2-d},{x:l/2,y:-u/2-d},...Y(l/2,-u/2,d,20,-90,0),{x:l/2+d,y:-d},...Y(l/2+d*2,-d,d,20,-180,-270),...Y(l/2+d*2,d,d,20,-90,-180),{x:l/2+d,y:u/2},...Y(l/2,u/2,d,20,0,90),{x:l/2,y:u/2+d},{x:-l/2,y:u/2+d}],h=C.svg(i),v=g(t,{fill:`none`});t.look!==`handDrawn`&&(v.roughness=0,v.fillStyle=`solid`);let y=F(p).replace(`Z`,``),b=h.path(y,v),x=F(m),S=h.path(x,{...v}),w=i.insert(`g`,`:first-child`);return w.insert(()=>S,`:first-child`).attr(`stroke-opacity`,0),w.insert(()=>b,`:first-child`),w.attr(`class`,`text`),f&&t.look!==`handDrawn`&&w.selectAll(`path`).attr(`style`,f),r&&t.look!==`handDrawn`&&w.selectAll(`path`).attr(`style`,r),w.attr(`transform`,`translate(${-d}, 0)`),o.attr(`transform`,`translate(${-l/2+(t.padding??0)/2-(a.x-(a.left??0))},${-u/2+(t.padding??0)/2-(a.y-(a.top??0))})`),N(t,w),t.intersect=function(e){return K.polygon(t,m,e)},i}o(Ne,`curlyBraceRight`);function X(e,t,n,r=100,i=0,a=180){let o=[],s=i*Math.PI/180,c=(a*Math.PI/180-s)/(r-1);for(let i=0;i<r;i++){let r=s+i*c,a=e+n*Math.cos(r),l=t+n*Math.sin(r);o.push({x:-a,y:-l})}return o}o(X,`generateCirclePoints`);async function Pe(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await j(e,t,P(t)),s=t.look===`neo`?18:t.padding??0,c=t.look===`neo`?12:t.padding??0,l=a.width+(t.look===`neo`?s*2:s),u=a.height+(t.look===`neo`?c*2:c),d=Math.max(5,u*.1),{cssStyles:f}=t,p=[...X(l/2,-u/2,d,30,-90,0),{x:-l/2-d,y:d},...X(l/2+d*2,-d,d,20,-180,-270),...X(l/2+d*2,d,d,20,-90,-180),{x:-l/2-d,y:-u/2},...X(l/2,u/2,d,20,0,90)],m=[...X(-l/2+d+d/2,-u/2,d,20,-90,-180),{x:l/2-d/2,y:d},...X(-l/2-d/2,-d,d,20,0,90),...X(-l/2-d/2,d,d,20,-90,0),{x:l/2-d/2,y:-d},...X(-l/2+d+d/2,u/2,d,30,-180,-270)],h=[{x:l/2,y:-u/2-d},{x:-l/2,y:-u/2-d},...X(l/2,-u/2,d,20,-90,0),{x:-l/2-d,y:-d},...X(l/2+d*2,-d,d,20,-180,-270),...X(l/2+d*2,d,d,20,-90,-180),{x:-l/2-d,y:u/2},...X(l/2,u/2,d,20,0,90),{x:-l/2,y:u/2+d},{x:l/2-d-d/2,y:u/2+d},...X(-l/2+d+d/2,-u/2,d,20,-90,-180),{x:l/2-d/2,y:d},...X(-l/2-d/2,-d,d,20,0,90),...X(-l/2-d/2,d,d,20,-90,0),{x:l/2-d/2,y:-d},...X(-l/2+d+d/2,u/2,d,30,-180,-270)],v=C.svg(i),y=g(t,{fill:`none`});t.look!==`handDrawn`&&(y.roughness=0,y.fillStyle=`solid`);let b=F(p).replace(`Z`,``),x=v.path(b,y),S=F(m).replace(`Z`,``),w=v.path(S,y),T=F(h),E=v.path(T,{...y}),D=i.insert(`g`,`:first-child`);return D.insert(()=>E,`:first-child`).attr(`stroke-opacity`,0),D.insert(()=>x,`:first-child`),D.insert(()=>w,`:first-child`),D.attr(`class`,`text`),f&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,f),r&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,r),D.attr(`transform`,`translate(${d-d/4}, 0)`),o.attr(`transform`,`translate(${-l/2+(t.padding??0)/2-(a.x-(a.left??0))},${-u/2+(t.padding??0)/2-(a.y-(a.top??0))})`),N(t,D),t.intersect=function(e){return K.polygon(t,h,e)},i}o(Pe,`curlyBraces`);async function Fe(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i,{shapeSvg:s,bbox:c}=await j(e,t,P(t)),l=Math.max(20,(c.width+a*2)*1.25,t?.width??0),u=Math.max(5,c.height+o*2,t?.height??0),d=u/2,{cssStyles:f}=t,p=C.svg(s),m=g(t,{});t.look!==`handDrawn`&&(m.roughness=0,m.fillStyle=`solid`);let h=l,v=u,y=h-d,b=v/4,x=[{x:y,y:0},{x:b,y:0},{x:0,y:v/2},{x:b,y:v},{x:y,y:v},...L(-y,-v/2,d,50,270,90)],S=F(x),w=p.path(S,m),T=s.insert(()=>w,`:first-child`);return T.attr(`class`,`basic label-container outer-path`),f&&t.look!==`handDrawn`&&T.selectChildren(`path`).attr(`style`,f),r&&t.look!==`handDrawn`&&T.selectChildren(`path`).attr(`style`,r),T.attr(`transform`,`translate(${-l/2}, ${-u/2})`),N(t,T),t.intersect=function(e){return K.polygon(t,x,e)},s}o(Fe,`curvedTrapezoid`);async function Ie(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await j(e,t,P(t)),s=t.padding??20,c=Math.max(a.width+s*2,t.width??0,100),l=Math.min(Math.max(c*.23,16),56),u=l*.27,d=Math.max(a.height+s*2,t.height?t.height-(2*l-u):0),f=Math.min(c*.177,d*.45),p=d+2*l-u,m=-p/2,h=m+2*l-u,v=i.insert(`g`,`:first-child`).attr(`class`,`basic label-container`),{cssStyles:y}=t;if(t.look===`handDrawn`){let e=C.svg(i),n=g(t,{}),r=e.path(z(-c/2,h,c,d,f),n),a=e.circle(0,m+l,l*2,n);v.insert(()=>a,`:first-child`),v.insert(()=>r,`:first-child`),y&&v.attr(`style`,y)}else v.append(`rect`).attr(`x`,-c/2).attr(`y`,h).attr(`width`,c).attr(`height`,d).attr(`rx`,f).attr(`ry`,f).attr(`style`,r),v.append(`circle`).attr(`cx`,0).attr(`cy`,m+l).attr(`r`,l).attr(`style`,r);N(t,v);let b=h+d/2;o.attr(`transform`,`translate(${-(a.width/2)-(a.x-(a.left??0))}, ${b-a.height/2-(a.y-(a.top??0))})`);let x=m+l,S=Math.asin(Math.min(1,(h-x)/l))*180/Math.PI,w=[...L(0,-x,l,24,180+S,-S),...L(-(-c/2+f),-(h+f),f,12,90,0),...L(-(-c/2+f),-(p/2-f),f,12,360,270),...L(-(c/2-f),-(p/2-f),f,12,270,180),...L(-(c/2-f),-(h+f),f,12,180,90)];return t.intersect=function(e){return K.polygon(t,w,e)},i}o(Ie,`person`);var Le=o((e,t,n,r,i,a)=>[`M${e},${t+a}`,`a${i},${a} 0,0,0 ${n},0`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,`l0,${-r}`].join(` `),`createCylinderPathD`),Re=o((e,t,n,r,i,a)=>[`M${e},${t+a}`,`M${e+n},${t+a}`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,`l0,${-r}`].join(` `),`createOuterCylinderPathD`),ze=o((e,t,n,r,i,a)=>[`M${e-n/2},${-r/2}`,`a${i},${a} 0,0,0 ${n},0`].join(` `),`createInnerCylinderPathD`),Be=8,Ve=8;async function He(e,t){let{labelStyles:n,nodeStyles:i}=_(t);t.labelStyle=n;let a=t.padding??0,o=t.look===`neo`?24:a,s=t.look===`neo`?24:a,c=t.width??0;if(t.width&&(t.width-=s,t.width<Ve&&(t.width=Ve)),t.height){let e=c/2/(2.5+c/50);t.height=t.height-o-e*3,t.height<Be&&(t.height=Be)}let{shapeSvg:l,bbox:u,label:d}=await j(e,t,P(t)),f=Math.max(t.width??0,u.width)+s,p=f/2,m=p/(2.5+f/50),h=Math.max(t.height??0,u.height)+o+m,v,{cssStyles:y}=t;if(t.look===`handDrawn`){let e=C.svg(l),n=Re(0,0,f,h,p,m),r=ze(0,m,f,h,p,m),i=g(t,{}),a=e.path(n,i),o=e.path(r,g(t,{fill:`none`}));v=l.insert(()=>o,`:first-child`),v=l.insert(()=>a,`:first-child`),v.attr(`class`,`basic label-container`),y&&v.attr(`style`,y)}else{let e=Le(0,0,f,h,p,m);v=l.insert(`path`,`:first-child`).attr(`d`,e).attr(`class`,`basic label-container outer-path`).attr(`style`,r(y)).attr(`style`,i)}return v.attr(`label-offset-y`,m),v.attr(`transform`,`translate(${-f/2}, ${-(h/2+m)})`),N(t,v),d.attr(`transform`,`translate(${-(u.width/2)-(u.x-(u.left??0))}, ${-(u.height/2)+(t.padding??0)/1.5-(u.y-(u.top??0))})`),t.intersect=function(e){let n=K.rect(t,e),r=n.x-(t.x??0);if(p!=0&&(Math.abs(r)<(t.width??0)/2||Math.abs(r)==(t.width??0)/2&&Math.abs(n.y-(t.y??0))>(t.height??0)/2-m)){let i=m*m*(1-r*r/(p*p));i>0&&(i=Math.sqrt(i)),i=m-i,e.y-(t.y??0)>0&&(i=-i),n.y+=i}return n},l}o(He,`cylinder`);async function Ue(e,t,n){let{labelStyles:i,nodeStyles:a}=_(t);t.labelStyle=i;let{shapeSvg:o,bbox:s}=await j(e,t,P(t)),c=Math.max(s.width+n.labelPaddingX*2,t?.width||0),l=Math.max(s.height+n.labelPaddingY*2,t?.height||0),u=-c/2,d=-l/2,f,{rx:p,ry:m}=t,{cssStyles:h}=t;if(n?.rx&&n.ry&&(p=n.rx,m=n.ry),t.look===`handDrawn`){let e=C.svg(o),n=g(t,{}),i=p||m?e.path(z(u,d,c,l,p||0),n):e.rectangle(u,d,c,l,n);f=o.insert(()=>i,`:first-child`),f.attr(`class`,`basic label-container`).attr(`style`,r(h))}else f=o.insert(`rect`,`:first-child`),f.attr(`class`,`basic label-container`).attr(`style`,a).attr(`rx`,r(p)).attr(`ry`,r(m)).attr(`x`,u).attr(`y`,d).attr(`width`,c).attr(`height`,l);return N(t,f,t.look===`handDrawn`?void 0:{width:c,height:l}),t.calcIntersect=function(e,t){return K.rect(e,t)},t.intersect=function(e){return K.rect(t,e)},o}o(Ue,`drawRect`);async function We(e,t){let{cssClasses:n,labelPaddingX:r,labelPaddingY:i,padding:a,width:o,height:s}=t,c=await Ue(e,t,{rx:0,ry:0,classes:n??``,labelPaddingX:r??(a??0)*2,labelPaddingY:i??a??0});if(t.look===`handDrawn`){let e=C.svg(c),n=g(t,{}),r=c.select(`.basic.label-container > path:nth-child(2)`),i=r.node();if(!i)return c;let a=null;if(i instanceof SVGGraphicsElement)a=i.getBBox();else return c;return c.insert(()=>e.line(a.x,a.y,a.x+a.width,a.y,n),`.basic.label-container g.label`),c.insert(()=>e.line(a.x,a.y+a.height,a.x+a.width,a.y+a.height,n),`.basic.label-container g.label`),r.remove(),c}let l=c.select(`.basic.label-container`),u=(Number(l.attr(`width`))||o)??0,d=(Number(l.attr(`height`))||s)??0;return u>0&&d>0&&l.attr(`stroke-dasharray`,`${u} ${d}`),c}o(We,`datastore`);async function Ge(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.look===`neo`?16:t.padding??0,a=t.look===`neo`?16:t.padding??0,{shapeSvg:o,bbox:s,label:c}=await j(e,t,P(t)),l=s.width+i,u=s.height+a,d=u*.2,f=-l/2,p=-u/2-d/2,{cssStyles:m}=t,h=C.svg(o),v=g(t,{});t.look!==`handDrawn`&&(v.roughness=0,v.fillStyle=`solid`);let y=[{x:f,y:p+d},{x:-f,y:p+d},{x:-f,y:-p},{x:f,y:-p},{x:f,y:p},{x:-f,y:p},{x:-f,y:p+d}],b=h.polygon(y.map(e=>[e.x,e.y]),v),x=o.insert(()=>b,`:first-child`);return x.attr(`class`,`basic label-container outer-path`),m&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,m),r&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,r),c.attr(`transform`,`translate(${f+(t.padding??0)/2-(s.x-(s.left??0))}, ${p+d+(t.padding??0)/2-(s.y-(s.top??0))})`),N(t,x),t.intersect=function(e){return K.rect(t,e)},o}o(Ge,`dividedRectangle`);async function Ke(e,t){let{labelStyles:n,nodeStyles:a}=_(t),o=t.look===`neo`?12:5;t.labelStyle=n;let s=t.padding??0,c=t.look===`neo`?16:s,{shapeSvg:l,bbox:u}=await j(e,t,P(t)),d=(t?.width?t?.width/2:u.width/2)+(c??0),f=d-o,p,{cssStyles:m}=t;if(t.look===`handDrawn`){let e=C.svg(l),n=g(t,{roughness:.2,strokeWidth:2.5}),i=g(t,{roughness:.2,strokeWidth:1.5}),a=e.circle(0,0,d*2,n),o=e.circle(0,0,f*2,i);p=l.insert(`g`,`:first-child`),p.attr(`class`,r(t.cssClasses)).attr(`style`,r(m)),p.node()?.appendChild(a),p.node()?.appendChild(o)}else{p=l.insert(`g`,`:first-child`);let e=p.insert(`circle`,`:first-child`),t=p.insert(`circle`);p.attr(`class`,`basic label-container`).attr(`style`,a),e.attr(`class`,`outer-circle`).attr(`style`,a).attr(`r`,d).attr(`cx`,0).attr(`cy`,0),t.attr(`class`,`inner-circle`).attr(`style`,a).attr(`r`,f).attr(`cx`,0).attr(`cy`,0)}return N(t,p),t.intersect=function(e){return i.info(`DoubleCircle intersect`,t,d,e),K.circle(t,d,e)},l}o(Ke,`doublecircle`);function qe(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:a}=_(t);t.label=``,t.labelStyle=r;let o=e.insert(`g`).attr(`class`,P(t)).attr(`id`,t.domId??t.id),{cssStyles:s}=t,c=C.svg(o),{nodeBorder:l}=n,u=g(t,{fillStyle:`solid`});t.look!==`handDrawn`&&(u.roughness=0);let d=c.circle(0,0,14,u),f=o.insert(()=>d,`:first-child`);return f.selectAll(`path`).attr(`style`,`fill: ${l} !important;`),s&&s.length>0&&t.look!==`handDrawn`&&f.selectAll(`path`).attr(`style`,s),a&&t.look!==`handDrawn`&&f.selectAll(`path`).attr(`style`,a),N(t,f),t.intersect=function(e){return i.info(`filledCircle intersect`,t,{radius:7,point:e}),K.circle(t,7,e)},o}o(qe,`filledCircle`);var Je=10,Ye=10;async function Xe(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let a=t.padding??0,o=t.look===`neo`?a*2:a;(t.width||t.height)&&(t.height=t?.height??0,t.height<Je&&(t.height=Je),t.width=(t?.width??0)-o-o/2,t.width<Ye&&(t.width=Ye));let{shapeSvg:s,bbox:c,label:l}=await j(e,t,P(t)),u=(t?.width?t?.width:c.width)+(o??0),d=t?.height?t?.height:u+c.height,f=d,p=[{x:0,y:-d},{x:f,y:-d},{x:f/2,y:0}],{cssStyles:m}=t,h=C.svg(s),v=g(t,{});t.look!==`handDrawn`&&(v.roughness=0,v.fillStyle=`solid`);let y=F(p),b=h.path(y,v),x=s.insert(()=>b,`:first-child`).attr(`transform`,`translate(${-d/2}, ${d/2})`).attr(`class`,`outer-path`);return m&&t.look!==`handDrawn`&&x.selectChildren(`path`).attr(`style`,m),r&&t.look!==`handDrawn`&&x.selectChildren(`path`).attr(`style`,r),t.width=u,t.height=d,N(t,x),l.attr(`transform`,`translate(${-c.width/2-(c.x-(c.left??0))}, ${-d/2+(t.padding??0)/2+(c.y-(c.top??0))})`),t.intersect=function(e){return i.info(`Triangle intersect`,t,p,e),K.polygon(t,p,e)},s}o(Xe,`flippedTriangle`);async function Ze(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await j(e,t,P(t)),s=t.padding??12,c=Math.max(a.width+s*2,t.width??0,90),l=a.height+s*2,u=Math.max(Math.min(l*.16,14),8),d=Math.max(l+u,t.height??0),f=d-u,p=Math.max(c*.38,28),m=-d/2,h=[{x:-c/2,y:m},{x:-c/2+p,y:m},{x:-c/2+p,y:m+u},{x:c/2,y:m+u},{x:c/2,y:d/2},{x:-c/2,y:d/2}],v=[`M${h[0].x},${h[0].y}`,...h.slice(1).map(e=>`L${e.x},${e.y}`),`Z`].join(` `),{cssStyles:y}=t,b;if(t.look===`handDrawn`){let e=C.svg(i).path(v,g(t,{}));b=i.insert(()=>e,`:first-child`).attr(`class`,`basic label-container`),y&&b.attr(`style`,y)}else b=i.insert(`path`,`:first-child`).attr(`d`,v).attr(`class`,`basic label-container`).attr(`style`,r);t.look===`handDrawn`?N(t,b):N(t,b,{width:c,height:d});let x=m+u+f/2;return o.attr(`transform`,`translate(${-(a.width/2)-(a.x-(a.left??0))}, ${x-a.height/2-(a.y-(a.top??0))})`),t.intersect=function(e){return K.polygon(t,h,e)},i}o(Ze,`folder`);function Qe(e,t,{dir:n,config:{state:r,themeVariables:i}}){let{nodeStyles:a}=_(t);t.label=``;let o=e.insert(`g`).attr(`class`,P(t)).attr(`id`,t.domId??t.id),{cssStyles:s}=t,c=Math.max(70,t?.width??0),l=Math.max(10,t?.height??0);n===`LR`&&(c=Math.max(10,t?.width??0),l=Math.max(70,t?.height??0));let u=-1*c/2,d=-1*l/2,f=C.svg(o),p=g(t,{stroke:i.lineColor,fill:i.lineColor});t.look!==`handDrawn`&&(p.roughness=0,p.fillStyle=`solid`);let m=f.rectangle(u,d,c,l,p),h=o.insert(()=>m,`:first-child`);s&&t.look!==`handDrawn`&&h.selectAll(`path`).attr(`style`,s),a&&t.look!==`handDrawn`&&h.selectAll(`path`).attr(`style`,a),N(t,h);let v=r?.padding??0;return t.width&&t.height&&(t.width+=v/2||0,t.height+=v/2||0),t.intersect=function(e){return K.rect(t,e)},o}o(Qe,`forkJoin`);async function $e(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let a=t.look===`neo`?16:t.padding??0,o=t.look===`neo`?12:t.padding??0;(t.width||t.height)&&(t.height=(t?.height??0)-o*2,t.height<10&&(t.height=10),t.width=(t?.width??0)-a*2,t.width<15&&(t.width=15));let{shapeSvg:s,bbox:c}=await j(e,t,P(t)),l=(t?.width?t?.width:Math.max(15,c.width))+a*2,u=(t?.height?t?.height:Math.max(10,c.height))+o*2,d=u/2,{cssStyles:f}=t,p=C.svg(s),m=g(t,{});t.look!==`handDrawn`&&(m.roughness=0,m.fillStyle=`solid`);let h=[{x:-l/2,y:-u/2},{x:l/2-d,y:-u/2},...L(-l/2+d,0,d,50,90,270),{x:l/2-d,y:u/2},{x:-l/2,y:u/2}],v=F(h),y=p.path(v,m),b=s.insert(()=>y,`:first-child`);return b.attr(`class`,`basic label-container outer-path`),f&&t.look!==`handDrawn`&&b.selectChildren(`path`).attr(`style`,f),r&&t.look!==`handDrawn`&&b.selectChildren(`path`).attr(`style`,r),N(t,b),t.intersect=function(e){return i.info(`Pill intersect`,t,{radius:d,point:e}),K.polygon(t,h,e)},s}o($e,`halfRoundedRectangle`);var et=o((e,t,n,r,i)=>[`M${e+i},${t}`,`L${e+n-i},${t}`,`L${e+n},${t-r/2}`,`L${e+n-i},${t-r}`,`L${e+i},${t-r}`,`L${e},${t-r/2}`,`Z`].join(` `),`createHexagonPathD`);async function tt(e,t){let{labelStyles:n,nodeStyles:r}=_(t),i=t.look===`neo`?3.5:4;t.labelStyle=n;let a=t.padding??0,o=t.look===`neo`?70:a,s=t.look===`neo`?32:a;if(t.width||t.height){let e=(t.height??0)/i;t.width=(t?.width??0)-2*e-s,t.height=(t.height??0)-o}let{shapeSvg:c,bbox:l}=await j(e,t,P(t)),u=(t?.height?t?.height:l.height)+o,d=u/i,f=(t?.width?t?.width:l.width)+2*d+s,p=[{x:d,y:0},{x:f-d,y:0},{x:f,y:-u/2},{x:f-d,y:-u},{x:d,y:-u},{x:0,y:-u/2}],m,{cssStyles:h}=t;if(t.look===`handDrawn`){let e=C.svg(c),n=g(t,{}),r=et(0,0,f,u,d),i=e.path(r,n);m=c.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-f/2}, ${u/2})`),h&&m.attr(`style`,h)}else m=q(c,f,u,p);return r&&m.attr(`style`,r),t.width=f,t.height=u,N(t,m),t.intersect=function(e){return K.polygon(t,p,e)},c}o(tt,`hexagon`);async function nt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.label=``,t.labelStyle=n;let{shapeSvg:a}=await j(e,t,P(t)),o=Math.max(30,t?.width??0),s=Math.max(30,t?.height??0),{cssStyles:c}=t,l=C.svg(a),u=g(t,{});t.look!==`handDrawn`&&(u.roughness=0,u.fillStyle=`solid`);let d=[{x:0,y:0},{x:o,y:0},{x:0,y:s},{x:o,y:s}],f=F(d),p=l.path(f,u),m=a.insert(()=>p,`:first-child`);return m.attr(`class`,`basic label-container outer-path`),c&&t.look!==`handDrawn`&&m.selectChildren(`path`).attr(`style`,c),r&&t.look!==`handDrawn`&&m.selectChildren(`path`).attr(`style`,r),m.attr(`transform`,`translate(${-o/2}, ${-s/2})`),N(t,m),t.intersect=function(e){return i.info(`Pill intersect`,t,{points:d}),K.polygon(t,d,e)},a}o(nt,`hourglass`);async function rt(e,t,{config:{themeVariables:n,flowchart:r}}){let{labelStyles:a}=_(t);t.labelStyle=a;let o=t.assetHeight??48,s=t.assetWidth??48,c=Math.max(o,s),l=r?.wrappingWidth;t.width=Math.max(c,l??0);let{shapeSvg:u,bbox:d,label:f}=await j(e,t,`icon-shape default`),p=t.pos===`t`,m=c,h=c,{nodeBorder:v}=n,{stylesMap:x}=y(t),S=-h/2,w=-m/2,T=t.label?8:0,E=C.svg(u),D=g(t,{stroke:`none`,fill:`none`});t.look!==`handDrawn`&&(D.roughness=0,D.fillStyle=`solid`);let O=E.rectangle(S,w,h,m,D),k=Math.max(h,d.width),A=m+d.height+T,M=E.rectangle(-k/2,-A/2,k,A,{...D,fill:`transparent`,stroke:`none`}),P=u.insert(()=>O,`:first-child`),F=u.insert(()=>M);if(t.icon){let e=u.append(`g`);e.html(`<g>${await b(t.icon,{height:c,width:c,fallbackPrefix:``})}</g>`);let n=e.node().getBBox(),r=n.width,i=n.height,a=n.x,o=n.y;e.attr(`transform`,`translate(${-r/2-a},${p?d.height/2+T/2-i/2-o:-d.height/2-T/2-i/2-o})`),e.attr(`style`,`color: ${x.get(`stroke`)??v};`)}return f.attr(`transform`,`translate(${-d.width/2-(d.x-(d.left??0))},${p?-A/2:A/2-d.height})`),P.attr(`transform`,`translate(0,${p?d.height/2+T/2:-d.height/2-T/2})`),N(t,F),t.intersect=function(e){if(i.info(`iconSquare intersect`,t,e),!t.label)return K.rect(t,e);let n=t.x??0,r=t.y??0,a=t.height??0,o=[];return o=p?[{x:n-d.width/2,y:r-a/2},{x:n+d.width/2,y:r-a/2},{x:n+d.width/2,y:r-a/2+d.height+T},{x:n+h/2,y:r-a/2+d.height+T},{x:n+h/2,y:r+a/2},{x:n-h/2,y:r+a/2},{x:n-h/2,y:r-a/2+d.height+T},{x:n-d.width/2,y:r-a/2+d.height+T}]:[{x:n-h/2,y:r-a/2},{x:n+h/2,y:r-a/2},{x:n+h/2,y:r-a/2+m},{x:n+d.width/2,y:r-a/2+m},{x:n+d.width/2/2,y:r+a/2},{x:n-d.width/2,y:r+a/2},{x:n-d.width/2,y:r-a/2+m},{x:n-h/2,y:r-a/2+m}],K.polygon(t,o,e)},u}o(rt,`icon`);async function it(e,t,{config:{themeVariables:n,flowchart:r}}){let{labelStyles:a}=_(t);t.labelStyle=a;let o=t.assetHeight??48,s=t.assetWidth??48,c=Math.max(o,s),l=r?.wrappingWidth;t.width=Math.max(c,l??0);let{shapeSvg:u,bbox:d,label:f}=await j(e,t,`icon-shape default`),p=t.label?8:0,m=t.pos===`t`,{nodeBorder:h,mainBkg:v}=n,{stylesMap:x}=y(t),S=C.svg(u),w=g(t,{});t.look!==`handDrawn`&&(w.roughness=0,w.fillStyle=`solid`),w.stroke=x.get(`fill`)??v;let T=u.append(`g`);t.icon&&T.html(`<g>${await b(t.icon,{height:c,width:c,fallbackPrefix:``})}</g>`);let E=T.node().getBBox(),D=E.width,O=E.height,k=E.x,A=E.y,M=Math.max(D,O)*Math.SQRT2+40,P=S.circle(0,0,M,w),F=Math.max(M,d.width),I=M+d.height+p,L=S.rectangle(-F/2,-I/2,F,I,{...w,fill:`transparent`,stroke:`none`}),ee=u.insert(()=>P,`:first-child`),R=u.insert(()=>L);return T.attr(`transform`,`translate(${-D/2-k},${m?d.height/2+p/2-O/2-A:-d.height/2-p/2-O/2-A})`),T.attr(`style`,`color: ${x.get(`stroke`)??h};`),f.attr(`transform`,`translate(${-d.width/2-(d.x-(d.left??0))},${m?-I/2:I/2-d.height})`),ee.attr(`transform`,`translate(0,${m?d.height/2+p/2:-d.height/2-p/2})`),N(t,R),t.intersect=function(e){return i.info(`iconSquare intersect`,t,e),K.rect(t,e)},u}o(it,`iconCircle`);async function at(e,t,{config:{themeVariables:n,flowchart:r}}){let{labelStyles:a}=_(t);t.labelStyle=a;let o=t.assetHeight??48,s=t.assetWidth??48,c=Math.max(o,s),l=r?.wrappingWidth;t.width=Math.max(c,l??0);let{shapeSvg:u,bbox:d,halfPadding:f,label:p}=await j(e,t,`icon-shape default`),m=t.pos===`t`,h=c+f*2,v=c+f*2,{nodeBorder:x,mainBkg:S}=n,{stylesMap:w}=y(t),T=-v/2,E=-h/2,D=t.label?8:0,O=C.svg(u),k=g(t,{});t.look!==`handDrawn`&&(k.roughness=0,k.fillStyle=`solid`),k.stroke=w.get(`fill`)??S;let A=O.path(z(T,E,v,h,5),k),M=Math.max(v,d.width),P=h+d.height+D,F=O.rectangle(-M/2,-P/2,M,P,{...k,fill:`transparent`,stroke:`none`}),I=u.insert(()=>A,`:first-child`).attr(`class`,`icon-shape2`),L=u.insert(()=>F);if(t.icon){let e=u.append(`g`);e.html(`<g>${await b(t.icon,{height:c,width:c,fallbackPrefix:``})}</g>`);let n=e.node().getBBox(),r=n.width,i=n.height,a=n.x,o=n.y;e.attr(`transform`,`translate(${-r/2-a},${m?d.height/2+D/2-i/2-o:-d.height/2-D/2-i/2-o})`),e.attr(`style`,`color: ${w.get(`stroke`)??x};`)}return p.attr(`transform`,`translate(${-d.width/2-(d.x-(d.left??0))},${m?-P/2:P/2-d.height})`),I.attr(`transform`,`translate(0,${m?d.height/2+D/2:-d.height/2-D/2})`),N(t,L),t.intersect=function(e){if(i.info(`iconSquare intersect`,t,e),!t.label)return K.rect(t,e);let n=t.x??0,r=t.y??0,a=t.height??0,o=[];return o=m?[{x:n-d.width/2,y:r-a/2},{x:n+d.width/2,y:r-a/2},{x:n+d.width/2,y:r-a/2+d.height+D},{x:n+v/2,y:r-a/2+d.height+D},{x:n+v/2,y:r+a/2},{x:n-v/2,y:r+a/2},{x:n-v/2,y:r-a/2+d.height+D},{x:n-d.width/2,y:r-a/2+d.height+D}]:[{x:n-v/2,y:r-a/2},{x:n+v/2,y:r-a/2},{x:n+v/2,y:r-a/2+h},{x:n+d.width/2,y:r-a/2+h},{x:n+d.width/2/2,y:r+a/2},{x:n-d.width/2,y:r+a/2},{x:n-d.width/2,y:r-a/2+h},{x:n-v/2,y:r-a/2+h}],K.polygon(t,o,e)},u}o(at,`iconRounded`);async function ot(e,t,{config:{themeVariables:n,flowchart:r}}){let{labelStyles:a}=_(t);t.labelStyle=a;let o=t.assetHeight??48,s=t.assetWidth??48,c=Math.max(o,s),l=r?.wrappingWidth;t.width=Math.max(c,l??0);let{shapeSvg:u,bbox:d,halfPadding:f,label:p}=await j(e,t,`icon-shape default`),m=t.pos===`t`,h=c+f*2,v=c+f*2,{nodeBorder:x,mainBkg:S}=n,{stylesMap:w}=y(t),T=-v/2,E=-h/2,D=t.label?8:0,O=C.svg(u),k=g(t,{});t.look!==`handDrawn`&&(k.roughness=0,k.fillStyle=`solid`),k.stroke=w.get(`fill`)??S;let A=O.path(z(T,E,v,h,.1),k),M=Math.max(v,d.width),P=h+d.height+D,F=O.rectangle(-M/2,-P/2,M,P,{...k,fill:`transparent`,stroke:`none`}),I=u.insert(()=>A,`:first-child`),L=u.insert(()=>F);if(t.icon){let e=u.append(`g`);e.html(`<g>${await b(t.icon,{height:c,width:c,fallbackPrefix:``})}</g>`);let n=e.node().getBBox(),r=n.width,i=n.height,a=n.x,o=n.y;e.attr(`transform`,`translate(${-r/2-a},${m?d.height/2+D/2-i/2-o:-d.height/2-D/2-i/2-o})`),e.attr(`style`,`color: ${w.get(`stroke`)??x};`)}return p.attr(`transform`,`translate(${-d.width/2-(d.x-(d.left??0))},${m?-P/2:P/2-d.height})`),I.attr(`transform`,`translate(0,${m?d.height/2+D/2:-d.height/2-D/2})`),N(t,L),t.intersect=function(e){if(i.info(`iconSquare intersect`,t,e),!t.label)return K.rect(t,e);let n=t.x??0,r=t.y??0,a=t.height??0,o=[];return o=m?[{x:n-d.width/2,y:r-a/2},{x:n+d.width/2,y:r-a/2},{x:n+d.width/2,y:r-a/2+d.height+D},{x:n+v/2,y:r-a/2+d.height+D},{x:n+v/2,y:r+a/2},{x:n-v/2,y:r+a/2},{x:n-v/2,y:r-a/2+d.height+D},{x:n-d.width/2,y:r-a/2+d.height+D}]:[{x:n-v/2,y:r-a/2},{x:n+v/2,y:r-a/2},{x:n+v/2,y:r-a/2+h},{x:n+d.width/2,y:r-a/2+h},{x:n+d.width/2/2,y:r+a/2},{x:n-d.width/2,y:r+a/2},{x:n-d.width/2,y:r-a/2+h},{x:n-v/2,y:r-a/2+h}],K.polygon(t,o,e)},u}o(ot,`iconSquare`);async function st(e,t,{config:{flowchart:n}}){let r=new Image;r.src=t?.img??``,await r.decode();let a=Number(r.naturalWidth.toString().replace(`px`,``)),o=Number(r.naturalHeight.toString().replace(`px`,``));t.imageAspectRatio=a/o;let{labelStyles:s}=_(t);t.labelStyle=s;let c=n?.wrappingWidth;t.defaultWidth=n?.wrappingWidth;let l=Math.max(t.label?c??0:0,t?.assetWidth??a),u=t.constraint===`on`&&t?.assetHeight?t.assetHeight*t.imageAspectRatio:l,d=t.constraint===`on`?u/t.imageAspectRatio:t?.assetHeight??o;t.width=Math.max(u,c??0);let{shapeSvg:f,bbox:p,label:m}=await j(e,t,`image-shape default`),h=t.pos===`t`,v=-u/2,y=-d/2,b=t.label?8:0,x=C.svg(f),S=g(t,{});t.look!==`handDrawn`&&(S.roughness=0,S.fillStyle=`solid`);let w=x.rectangle(v,y,u,d,S),T=Math.max(u,p.width),E=d+p.height+b,D=x.rectangle(-T/2,-E/2,T,E,{...S,fill:`none`,stroke:`none`}),O=f.insert(()=>w,`:first-child`),k=f.insert(()=>D);if(t.img){let e=f.append(`image`);e.attr(`href`,t.img),e.attr(`width`,u),e.attr(`height`,d),e.attr(`preserveAspectRatio`,`none`),e.attr(`transform`,`translate(${-u/2},${h?E/2-d:-E/2})`)}return m.attr(`transform`,`translate(${-p.width/2-(p.x-(p.left??0))},${h?-d/2-p.height/2-b/2:d/2-p.height/2+b/2})`),O.attr(`transform`,`translate(0,${h?p.height/2+b/2:-p.height/2-b/2})`),N(t,k),t.intersect=function(e){if(i.info(`iconSquare intersect`,t,e),!t.label)return K.rect(t,e);let n=t.x??0,r=t.y??0,a=t.height??0,o=[];return o=h?[{x:n-p.width/2,y:r-a/2},{x:n+p.width/2,y:r-a/2},{x:n+p.width/2,y:r-a/2+p.height+b},{x:n+u/2,y:r-a/2+p.height+b},{x:n+u/2,y:r+a/2},{x:n-u/2,y:r+a/2},{x:n-u/2,y:r-a/2+p.height+b},{x:n-p.width/2,y:r-a/2+p.height+b}]:[{x:n-u/2,y:r-a/2},{x:n+u/2,y:r-a/2},{x:n+u/2,y:r-a/2+d},{x:n+p.width/2,y:r-a/2+d},{x:n+p.width/2/2,y:r+a/2},{x:n-p.width/2,y:r+a/2},{x:n-p.width/2,y:r-a/2+d},{x:n-u/2,y:r-a/2+d}],K.polygon(t,o,e)},f}o(st,`imageSquare`);async function ct(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=i,o=t.look===`neo`?i*2:i,{shapeSvg:s,bbox:c}=await j(e,t,P(t)),l=Math.max(c.height+a*2,t.height??0),u=Math.max(c.width+o*2,(t.width??0)-l),d=[{x:0,y:0},{x:u,y:0},{x:u+3*l/6,y:-l},{x:-3*l/6,y:-l}],f,{cssStyles:p}=t;if(t.look===`handDrawn`){let e=C.svg(s),n=g(t,{}),r=F(d),i=e.path(r,n);f=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-u/2}, ${l/2})`),p&&f.attr(`style`,p)}else f=q(s,u,l,d);return r&&f.attr(`style`,r),t.width=u,t.height=l,N(t,f),t.intersect=function(e){return K.polygon(t,d,e)},s}o(ct,`inv_trapezoid`);async function lt(e,t){let{shapeSvg:n,bbox:r,label:i}=await j(e,t,`label`),a=n.insert(`rect`,`:first-child`);return a.attr(`width`,.1).attr(`height`,.1),n.attr(`class`,`label edgeLabel`),i.attr(`transform`,`translate(${-(r.width/2)-(r.x-(r.left??0))}, ${-(r.height/2)-(r.y-(r.top??0))})`),N(t,a),t.intersect=function(e){return K.rect(t,e)},n}o(lt,`labelRect`);async function ut(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=i,o=t.look===`neo`?i*2:i,{shapeSvg:s,bbox:c}=await j(e,t,P(t)),l=Math.max(c.height+a,t.height??0),u=Math.max(c.width+o,(t.width??0)-l),d=[{x:0,y:0},{x:u+3*l/6,y:0},{x:u,y:-l},{x:-(3*l)/6,y:-l}],f,{cssStyles:p}=t;if(t.look===`handDrawn`){let e=C.svg(s),n=g(t,{}),r=F(d),i=e.path(r,n);f=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-u/2}, ${l/2})`),p&&f.attr(`style`,p)}else f=q(s,u,l,d);return r&&f.attr(`style`,r),t.width=u,t.height=l,N(t,f),t.intersect=function(e){return K.polygon(t,d,e)},s}o(ut,`lean_left`);async function dt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=i,o=t.look===`neo`?i*2:i,{shapeSvg:s,bbox:c}=await j(e,t,P(t)),l=Math.max(c.height+a,t.height??0),u=Math.max(c.width+o,(t.width??0)-l),d=[{x:-3*l/6,y:0},{x:u,y:0},{x:u+3*l/6,y:-l},{x:0,y:-l}],f,{cssStyles:p}=t;if(t.look===`handDrawn`){let e=C.svg(s),n=g(t,{}),r=F(d),i=e.path(r,n);f=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-u/2}, ${l/2})`),p&&f.attr(`style`,p)}else f=q(s,u,l,d);return r&&f.attr(`style`,r),t.width=u,t.height=l,N(t,f),t.intersect=function(e){return K.polygon(t,d,e)},s}o(dt,`lean_right`);function ft(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.label=``,t.labelStyle=n;let a=e.insert(`g`).attr(`class`,P(t)).attr(`id`,t.domId??t.id),{cssStyles:o}=t,s=Math.max(35,t?.width??0),c=Math.max(35,t?.height??0),l=[{x:s,y:0},{x:0,y:c+7/2},{x:s-14,y:c+7/2},{x:0,y:2*c},{x:s,y:c-7/2},{x:14,y:c-7/2}],u=C.svg(a),d=g(t,{});t.look!==`handDrawn`&&(d.roughness=0,d.fillStyle=`solid`);let f=F(l),p=u.path(f,d),m=a.insert(()=>p,`:first-child`);return m.attr(`class`,`outer-path`),o&&t.look!==`handDrawn`&&m.selectAll(`path`).attr(`style`,o),r&&t.look!==`handDrawn`&&m.selectAll(`path`).attr(`style`,r),m.attr(`transform`,`translate(-${s/2},${-c})`),N(t,m),t.intersect=function(e){return i.info(`lightningBolt intersect`,t,e),K.polygon(t,l,e)},a}o(ft,`lightningBolt`);var pt=o((e,t,n,r,i,a,o)=>[`M${e},${t+a}`,`a${i},${a} 0,0,0 ${n},0`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,`l0,${-r}`,`M${e},${t+a+o}`,`a${i},${a} 0,0,0 ${n},0`].join(` `),`createCylinderPathD`),mt=o((e,t,n,r,i,a,o)=>[`M${e},${t+a}`,`M${e+n},${t+a}`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,`l0,${-r}`,`M${e},${t+a+o}`,`a${i},${a} 0,0,0 ${n},0`].join(` `),`createOuterCylinderPathD`),ht=o((e,t,n,r,i,a)=>[`M${e-n/2},${-r/2}`,`a${i},${a} 0,0,0 ${n},0`].join(` `),`createInnerCylinderPathD`),gt=10,_t=10;async function vt(e,t){let{labelStyles:n,nodeStyles:i}=_(t);t.labelStyle=n;let a=t.padding??0,o=t.look===`neo`?16:a,s=t.look===`neo`?24:a;if(t.width||t.height){let e=t.width??0;t.width=(t.width??0)-o,t.width<_t&&(t.width=_t);let n=e/2/(2.5+e/50);t.height=(t.height??0)-s-n*3,t.height<gt&&(t.height=gt)}let{shapeSvg:c,bbox:l,label:u}=await j(e,t,P(t)),d=(t?.width?t?.width:l.width)+o*2,f=d/2,p=f/(2.5+d/50),m=(t?.height?t?.height:l.height)+p+s*2,h=m*.1,v,{cssStyles:y}=t;if(t.look===`handDrawn`){let e=C.svg(c),n=mt(0,0,d,m,f,p,h),r=ht(0,p,d,m,f,p),i=g(t,{}),a=e.path(n,i),o=e.path(r,i);c.insert(()=>o,`:first-child`).attr(`class`,`line`),v=c.insert(()=>a,`:first-child`),v.attr(`class`,`basic label-container`),y&&v.attr(`style`,y)}else{let e=pt(0,0,d,m,f,p,h);v=c.insert(`path`,`:first-child`).attr(`d`,e).attr(`class`,`basic label-container outer-path`).attr(`style`,r(y)).attr(`style`,i)}return v.attr(`label-offset-y`,p),v.attr(`transform`,`translate(${-d/2}, ${-(m/2+p)})`),N(t,v),u.attr(`transform`,`translate(${-(l.width/2)-(l.x-(l.left??0))}, ${-(l.height/2)+p-(l.y-(l.top??0))})`),t.intersect=function(e){let n=K.rect(t,e),r=n.x-(t.x??0);if(f!=0&&(Math.abs(r)<(t.width??0)/2||Math.abs(r)==(t.width??0)/2&&Math.abs(n.y-(t.y??0))>(t.height??0)/2-p)){let i=p*p*(1-r*r/(f*f));i>0&&(i=Math.sqrt(i)),i=p-i,e.y-(t.y??0)>0&&(i=-i),n.y+=i}return n},c}o(vt,`linedCylinder`);async function yt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i;(t.width||t.height)&&(t.width=(t.width??0)*10/11-a*2,t.width<10&&(t.width=10),t.height=(t?.height??0)-o*2,t.height<10&&(t.height=10));let{shapeSvg:s,bbox:c,label:l}=await j(e,t,P(t)),u=(t?.width?t?.width:c.width)+(a??0)*2,d=(t?.height?t?.height:c.height)+(o??0)*2,f=t.look===`neo`?d/4:d/8,p=d+f,{cssStyles:m}=t,h=C.svg(s),v=g(t,{});t.look!==`handDrawn`&&(v.roughness=0,v.fillStyle=`solid`);let y=[{x:-u/2-u/2*.1,y:-p/2},{x:-u/2-u/2*.1,y:p/2},...I(-u/2-u/2*.1,p/2,u/2+u/2*.1,p/2,f,.8),{x:u/2+u/2*.1,y:-p/2},{x:-u/2-u/2*.1,y:-p/2},{x:-u/2,y:-p/2},{x:-u/2,y:p/2*1.1},{x:-u/2,y:-p/2}],b=h.polygon(y.map(e=>[e.x,e.y]),v),x=s.insert(()=>b,`:first-child`);return x.attr(`class`,`basic label-container outer-path`),m&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,m),r&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,r),x.attr(`transform`,`translate(0,${-f/2})`),l.attr(`transform`,`translate(${-u/2+(t.padding??0)+u/2*.1/2-(c.x-(c.left??0))},${-d/2+(t.padding??0)-f/2-(c.y-(c.top??0))})`),N(t,x),t.intersect=function(e){return K.polygon(t,y,e)},s}o(yt,`linedWaveEdgedRect`);async function bt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i,s=t.look===`neo`?10:5;(t.width||t.height)&&(t.width=Math.max((t?.width??0)-a*2-2*s,10),t.height=Math.max((t?.height??0)-o*2-2*s,10));let{shapeSvg:c,bbox:l,label:u}=await j(e,t,P(t)),d=(t?.width?t?.width:l.width)+a*2+2*s,f=(t?.height?t?.height:l.height)+o*2+2*s,p=d-2*s,m=f-2*s,h=-p/2,v=-m/2,{cssStyles:y}=t,b=C.svg(c),x=g(t,{}),S=[{x:h-s,y:v+s},{x:h-s,y:v+m+s},{x:h+p-s,y:v+m+s},{x:h+p-s,y:v+m},{x:h+p,y:v+m},{x:h+p,y:v+m-s},{x:h+p+s,y:v+m-s},{x:h+p+s,y:v-s},{x:h+s,y:v-s},{x:h+s,y:v},{x:h,y:v},{x:h,y:v+s}],w=[{x:h,y:v+s},{x:h+p-s,y:v+s},{x:h+p-s,y:v+m},{x:h+p,y:v+m},{x:h+p,y:v},{x:h,y:v}];t.look!==`handDrawn`&&(x.roughness=0,x.fillStyle=`solid`);let T=F(S),E=b.path(T,x),D=F(w),O=b.path(D,x);t.look!==`handDrawn`&&(E=ee(E),O=ee(O));let k=c.insert(`g`,`:first-child`);return k.insert(()=>E),k.insert(()=>O),k.attr(`class`,`basic label-container outer-path`),y&&t.look!==`handDrawn`&&k.selectAll(`path`).attr(`style`,y),r&&t.look!==`handDrawn`&&k.selectAll(`path`).attr(`style`,r),u.attr(`transform`,`translate(${-(l.width/2)-s-(l.x-(l.left??0))}, ${-(l.height/2)+s-(l.y-(l.top??0))})`),N(t,k),t.intersect=function(e){return K.polygon(t,S,e)},c}o(bt,`multiRect`);async function xt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await j(e,t,P(t)),s=t.padding??0,c=t.look===`neo`?16:s,l=t.look===`neo`?12:s,u=!0;(t.width||t.height)&&(u=!1,t.width=(t?.width??0)-c*2,t.height=(t?.height??0)-l*3);let d=Math.max(a.width,t?.width??0)+c*2,f=Math.max(a.height,t?.height??0)+l*3,p=t.look===`neo`?f/4:f/8,m=f+(u?p/2:-p/2),h=-d/2,v=-m/2,{cssStyles:y}=t,b=I(h-10,v+m+10,h+d-10,v+m+10,p,.8),x=b?.[b.length-1],S=[{x:h-10,y:v+10},{x:h-10,y:v+m+10},...b,{x:h+d-10,y:x.y-10},{x:h+d,y:x.y-10},{x:h+d,y:x.y-20},{x:h+d+10,y:x.y-20},{x:h+d+10,y:v-10},{x:h+10,y:v-10},{x:h+10,y:v},{x:h,y:v},{x:h,y:v+10}],w=[{x:h,y:v+10},{x:h+d-10,y:v+10},{x:h+d-10,y:x.y-10},{x:h+d,y:x.y-10},{x:h+d,y:v},{x:h,y:v}],T=C.svg(i),E=g(t,{});t.look!==`handDrawn`&&(E.roughness=0,E.fillStyle=`solid`);let D=F(S),O=T.path(D,E),k=F(w),A=T.path(k,E),M=i.insert(()=>O,`:first-child`);return M.insert(()=>A),M.attr(`class`,`basic label-container outer-path`),y&&t.look!==`handDrawn`&&M.selectAll(`path`).attr(`style`,y),r&&t.look!==`handDrawn`&&M.selectAll(`path`).attr(`style`,r),M.attr(`transform`,`translate(0,${-p/2})`),o.attr(`transform`,`translate(${-(a.width/2)-10-(a.x-(a.left??0))}, ${-(a.height/2)+10-p/2-(a.y-(a.top??0))})`),N(t,M),t.intersect=function(e){return K.polygon(t,S,e)},i}o(xt,`multiWaveEdgedRectangle`);async function St(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r,t.useHtmlLabels||u(d())||(t.centerLabel=!0);let{shapeSvg:a,bbox:o,label:s}=await j(e,t,P(t)),c=Math.max(o.width+(t.padding??0)*2,t?.width??0),l=Math.max(o.height+(t.padding??0)*2,t?.height??0),f=-c/2,p=-l/2,{cssStyles:m}=t,h=C.svg(a),v=g(t,{fill:n.noteBkgColor,stroke:n.noteBorderColor});t.look!==`handDrawn`&&(v.roughness=0,v.fillStyle=`solid`);let y=h.rectangle(f,p,c,l,v),b=a.insert(()=>y,`:first-child`);return b.attr(`class`,`basic label-container outer-path`),s.attr(`class`,`label noteLabel`),m&&t.look!==`handDrawn`&&b.selectAll(`path`).attr(`style`,m),i&&t.look!==`handDrawn`&&b.selectAll(`path`).attr(`style`,i),s.attr(`transform`,`translate(${-o.width/2-(o.x-(o.left??0))}, ${-(o.height/2)-(o.y-(o.top??0))})`),N(t,b),t.intersect=function(e){return K.rect(t,e)},a}o(St,`note`);var Ct=o((e,t,n)=>[`M${e+n/2},${t}`,`L${e+n},${t-n/2}`,`L${e+n/2},${t-n}`,`L${e},${t-n/2}`,`Z`].join(` `),`createDecisionBoxPathD`);async function wt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a}=await j(e,t,P(t)),o=a.width+(t.padding??0)+(a.height+(t.padding??0)),s=.5,c=[{x:o/2,y:0},{x:o,y:-o/2},{x:o/2,y:-o},{x:0,y:-o/2}],l,{cssStyles:u}=t;if(t.look===`handDrawn`){let e=C.svg(i),n=g(t,{}),r=Ct(0,0,o),a=e.path(r,n);l=i.insert(()=>a,`:first-child`).attr(`transform`,`translate(${-o/2+s}, ${o/2})`),u&&l.attr(`style`,u)}else l=q(i,o,o,c),l.attr(`transform`,`translate(${-o/2+s}, ${o/2})`);return r&&l.attr(`style`,r),N(t,l),t.calcIntersect=function(e,t){let n=e.width,r=[{x:n/2,y:0},{x:n,y:-n/2},{x:n/2,y:-n},{x:0,y:-n/2}],i=K.polygon(e,r,t);return{x:i.x-.5,y:i.y-.5}},t.intersect=function(e){return this.calcIntersect(t,e)},i}o(wt,`question`);async function Tt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?21:i??0,o=t.look===`neo`?12:i??0,{shapeSvg:s,bbox:c,label:l}=await j(e,t,P(t)),u=c.width+(t.look===`neo`?a*2:a),d=Math.max(c.height+(t.look===`neo`?o*2:o),t.height??0),f=d/4,p=-Math.max(u,(t.width??0)-f)/2,m=-d/2,h=m/2,v=[{x:p+h,y:m},{x:p,y:0},{x:p+h,y:-m},{x:-p,y:-m},{x:-p,y:m}],{cssStyles:y}=t,b=C.svg(s),x=g(t,{});t.look!==`handDrawn`&&(x.roughness=0,x.fillStyle=`solid`);let S=F(v),w=b.path(S,x),T=s.insert(()=>w,`:first-child`);return T.attr(`class`,`basic label-container outer-path`),y&&t.look!==`handDrawn`&&T.selectAll(`path`).attr(`style`,y),r&&t.look!==`handDrawn`&&T.selectAll(`path`).attr(`style`,r),T.attr(`transform`,`translate(${-h/2},0)`),l.attr(`transform`,`translate(${-h/2-c.width/2-(c.x-(c.left??0))}, ${-(c.height/2)-(c.y-(c.top??0))})`),N(t,T),t.intersect=function(e){return K.polygon(t,v,e)},s}o(Tt,`rect_left_inv_arrow`);async function Et(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let o;o=t.cssClasses?`node `+t.cssClasses:`node default`;let s=e.insert(`g`).attr(`class`,o).attr(`id`,t.domId||t.id),c=s.insert(`g`),l=s.insert(`g`).attr(`class`,`label`).attr(`style`,r),d=t.description,f=t.label,p=await te(l,f,t.labelStyle,!0,!0),h={width:0,height:0};if(u(m())){let e=p.children[0],t=a(p);h=e.getBoundingClientRect(),t.attr(`width`,h.width),t.attr(`height`,h.height)}i.info(`Text 2`,d);let v=d||[],y=p.getBBox(),b=await te(l,Array.isArray(v)?v.join(`<br/>`):v,t.labelStyle,!0,!0),x=b.children[0],S=a(b);h=x.getBoundingClientRect(),S.attr(`width`,h.width),S.attr(`height`,h.height);let w=(t.padding||0)/2;a(b).attr(`transform`,`translate( `+(h.width>y.width?0:(y.width-h.width)/2)+`, `+(y.height+w+5)+`)`),a(p).attr(`transform`,`translate( `+(h.width<y.width?0:-(y.width-h.width)/2)+`, 0)`),h=l.node().getBBox(),l.attr(`transform`,`translate(`+-h.width/2+`, `+(-h.height/2-w+3)+`)`);let T=h.width+(t.padding||0),E=h.height+(t.padding||0),D=-h.width/2-w,O=-h.height/2-w,k,A;if(t.look===`handDrawn`){let e=C.svg(s),n=g(t,{}),r=e.path(z(D,O,T,E,t.rx||0),n),a=e.line(-h.width/2-w,-h.height/2-w+y.height+w,h.width/2+w,-h.height/2-w+y.height+w,n);A=s.insert(()=>(i.debug(`Rough node insert CXC`,r),a),`:first-child`),k=s.insert(()=>(i.debug(`Rough node insert CXC`,r),r),`:first-child`)}else k=c.insert(`rect`,`:first-child`),A=c.insert(`line`),k.attr(`class`,`outer title-state`).attr(`style`,r).attr(`x`,-h.width/2-w).attr(`y`,-h.height/2-w).attr(`width`,h.width+(t.padding||0)).attr(`height`,h.height+(t.padding||0)),A.attr(`class`,`divider`).attr(`x1`,-h.width/2-w).attr(`x2`,h.width/2+w).attr(`y1`,-h.height/2-w+y.height+w).attr(`y2`,-h.height/2-w+y.height+w);return N(t,k),t.intersect=function(e){return K.rect(t,e)},s}o(Et,`rectWithTitle`);async function Dt(e,t,{config:{themeVariables:n}}){let r=n?.radius??5;return Ue(e,t,{rx:r,ry:r,classes:``,labelPaddingX:(t?.padding??0)*1,labelPaddingY:(t?.padding??0)*1})}o(Dt,`roundedRect`);var Z=8;async function Ot(e,t){let{labelStyles:n,nodeStyles:i}=_(t);t.labelStyle=n;let a=t.look===`neo`?16:t.padding??0,o=t.look===`neo`?12:t.padding??0,{shapeSvg:s,bbox:c,label:l}=await j(e,t,P(t)),u=(t?.width??c.width)+a*2+(t.look===`neo`?Z:Z*2),d=(t?.height??c.height)+o*2,f=u-Z,p=d,m=Z-u/2,h=-d/2,{cssStyles:v}=t,y=C.svg(s),b=g(t,{});t.look!==`handDrawn`&&(b.roughness=0,b.fillStyle=`solid`);let x=[{x:m,y:h},{x:m+f,y:h},{x:m+f,y:h+p},{x:m-Z,y:h+p},{x:m-Z,y:h},{x:m,y:h},{x:m,y:h+p}],S=y.polygon(x.map(e=>[e.x,e.y]),b),w=s.insert(()=>S,`:first-child`);return w.attr(`class`,`basic label-container outer-path`).attr(`style`,r(v)),i&&t.look!==`handDrawn`&&w.selectAll(`path`).attr(`style`,i),v&&t.look!==`handDrawn`&&w.selectAll(`path`).attr(`style`,i),l.attr(`transform`,`translate(${Z/2-c.width/2-(c.x-(c.left??0))}, ${-(c.height/2)-(c.y-(c.top??0))})`),N(t,w),t.intersect=function(e){return K.rect(t,e)},s}o(Ot,`shadedProcess`);async function kt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i;(t.width||t.height)&&(t.width=Math.max((t?.width??0)-a*2,10),t.height=Math.max((t?.height??0)/1.5-o*2,10));let{shapeSvg:s,bbox:c,label:l}=await j(e,t,P(t)),u=(t?.width?t?.width:c.width)+a*2,d=((t?.height?t?.height:c.height)+o*2)*1.5,f=u,p=d/1.5,m=-f/2,h=-p/2,{cssStyles:v}=t,y=C.svg(s),b=g(t,{});t.look!==`handDrawn`&&(b.roughness=0,b.fillStyle=`solid`);let x=[{x:m,y:h},{x:m,y:h+p},{x:m+f,y:h+p},{x:m+f,y:h-p/2}],S=F(x),w=y.path(S,b),T=s.insert(()=>w,`:first-child`);return T.attr(`class`,`basic label-container outer-path`),v&&t.look!==`handDrawn`&&T.selectChildren(`path`).attr(`style`,v),r&&t.look!==`handDrawn`&&T.selectChildren(`path`).attr(`style`,r),T.attr(`transform`,`translate(0, ${p/4})`),l.attr(`transform`,`translate(${-f/2+(t.padding??0)-(c.x-(c.left??0))}, ${-p/4+(t.padding??0)-(c.y-(c.top??0))})`),N(t,T),t.intersect=function(e){return K.polygon(t,x,e)},s}o(kt,`slopedRect`);async function At(e,t){let n=t.padding??0,r=t.look===`neo`?16:n*2,i=t.look===`neo`?12:n;return Ue(e,t,{rx:0,ry:0,classes:``,labelPaddingX:t.labelPaddingX??r,labelPaddingY:i})}o(At,`squareRect`);async function jt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?20:i,o=t.look===`neo`?12:i,{shapeSvg:s,bbox:c}=await j(e,t,P(t)),l=c.height+(t.look===`neo`?o*2:o),u=c.width+l/4+(t.look===`neo`?a*2:a),d=l/2,{cssStyles:f}=t,p=C.svg(s),m=g(t,{});t.look!==`handDrawn`&&(m.roughness=0,m.fillStyle=`solid`);let h=[{x:-u/2+d,y:-l/2},{x:u/2-d,y:-l/2},...L(-u/2+d,0,d,50,90,270),{x:u/2-d,y:l/2},...L(u/2-d,0,d,50,270,450)],v=F(h),y=p.path(v,m),b=s.insert(()=>y,`:first-child`);return b.attr(`class`,`basic label-container outer-path`),f&&t.look!==`handDrawn`&&b.selectChildren(`path`).attr(`style`,f),r&&t.look!==`handDrawn`&&b.selectChildren(`path`).attr(`style`,r),N(t,b),t.intersect=function(e){return K.polygon(t,h,e)},s}o(jt,`stadium`);async function Mt(e,t){return Ue(e,t,{rx:t.look===`neo`?3:5,ry:t.look===`neo`?3:5,classes:`flowchart-node`})}o(Mt,`state`);function Nt(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{cssStyles:a}=t,{lineColor:o,stateBorder:s,nodeBorder:c,nodeShadow:l}=n;(t.width||t.height)&&((t.width??0)<14&&(t.width=14),(t.height??0)<14&&(t.height=14)),t.width||=14,t.height||=14;let u=e.insert(`g`).attr(`class`,`node default`).attr(`id`,t.domId??t.id),d=C.svg(u),f=g(t,{});t.look!==`handDrawn`&&(f.roughness=0,f.fillStyle=`solid`);let p=d.circle(0,0,t.width,{...f,stroke:o,strokeWidth:2}),m=s??c,h=(t.width??0)*5/14,v=d.circle(0,0,h,{...f,fill:m,stroke:m,strokeWidth:2,fillStyle:`solid`}),y=u.insert(()=>p,`:first-child`);if(y.insert(()=>v),t.look!==`handDrawn`&&y.attr(`class`,`outer-path`),a&&y.selectAll(`path`).attr(`style`,a),i&&y.selectAll(`path`).attr(`style`,i),t.width<25&&l&&t.look!==`handDrawn`){let t=e.node()?.ownerSVGElement?.id??``,n=t?`${t}-drop-shadow-small`:`drop-shadow-small`;y.attr(`style`,`filter:url(#${n})`)}return N(t,y),t.intersect=function(e){return K.circle(t,(t.width??0)/2,e)},u}o(Nt,`stateEnd`);function Pt(e,t,{config:{themeVariables:n}}){let{lineColor:r,nodeShadow:i}=n;(t.width||t.height)&&((t.width??0)<14&&(t.width=14),(t.height??0)<14&&(t.height=14)),t.width||=14,t.height||=14;let a=e.insert(`g`).attr(`class`,`node default`).attr(`id`,t.domId||t.id),o;if(t.look===`handDrawn`){let e=C.svg(a).circle(0,0,t.width,v(r));o=a.insert(()=>e),o.attr(`class`,`state-start`).attr(`r`,(t.width??7)/2).attr(`width`,t.width??14).attr(`height`,t.height??14)}else o=a.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&&i&&t.look!==`handDrawn`){let t=e.node()?.ownerSVGElement?.id??``,n=t?`${t}-drop-shadow-small`:`drop-shadow-small`;o.attr(`style`,`filter:url(#${n})`)}return N(t,o),t.intersect=function(e){return K.circle(t,(t.width??7)/2,e)},a}o(Pt,`stateStart`);var Ft=8;async function It(e,t){let{labelStyles:n,nodeStyles:i}=_(t);t.labelStyle=n;let a=t?.padding??8,o=t.look===`neo`?28:a,s=t.look===`neo`?12:a,{shapeSvg:c,bbox:l}=await j(e,t,P(t)),u=Math.max(l.width+2*Ft+o,t.width??0),d=Math.max(l.height+s,t.height??0),f=u-2*Ft,p=d,m=-u/2,h=-d/2,v=[{x:0,y:0},{x:f,y:0},{x:f,y:-p},{x:0,y:-p},{x:0,y:0},{x:-8,y:0},{x:f+8,y:0},{x:f+8,y:-p},{x:-8,y:-p},{x:-8,y:0}];if(t.look===`handDrawn`){let e=C.svg(c),n=g(t,{}),i=e.rectangle(m,h,f+16,p,n),a=e.line(m+Ft,h,m+Ft,h+p,n),o=e.line(m+Ft+f,h,m+Ft+f,h+p,n);c.insert(()=>a,`:first-child`),c.insert(()=>o,`:first-child`);let s=c.insert(()=>i,`:first-child`),{cssStyles:l}=t;s.attr(`class`,`basic label-container`).attr(`style`,r(l)),N(t,s)}else{let e=q(c,f,p,v);i&&e.attr(`style`,i),N(t,e)}return t.intersect=function(e){return K.polygon(t,v,e)},c}o(It,`subroutine`);var Lt=.2;async function Rt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i;(t.width||t.height)&&(t.height=Math.max((t?.height??0)-o*2,10),t.width=Math.max((t?.width??0)-a*2-Lt*(t.height+o*2),10));let{shapeSvg:s,bbox:c}=await j(e,t,P(t)),l=(t?.height?t?.height:c.height)+o*2,u=Lt*l,d=Lt*l,f=(t?.width?t?.width:c.width)+a*2+u-u,p=l,m=-f/2,h=-p/2,{cssStyles:v}=t,y=C.svg(s),b=g(t,{}),x=[{x:m-u/2,y:h},{x:m+f+u/2,y:h},{x:m+f+u/2,y:h+p},{x:m-u/2,y:h+p}],S=[{x:m+f-u/2,y:h+p},{x:m+f+u/2,y:h+p},{x:m+f+u/2,y:h+p-d}];t.look!==`handDrawn`&&(b.roughness=0,b.fillStyle=`solid`);let w=F(x),T=y.path(w,b),E=F(S),D=y.path(E,{...b,fillStyle:`solid`}),O=s.insert(()=>D,`:first-child`);return O.insert(()=>T,`:first-child`),O.attr(`class`,`basic label-container outer-path`),v&&t.look!==`handDrawn`&&O.selectAll(`path`).attr(`style`,v),r&&t.look!==`handDrawn`&&O.selectAll(`path`).attr(`style`,r),N(t,O),t.intersect=function(e){return K.polygon(t,x,e)},s}o(Rt,`taggedRect`);async function zt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await j(e,t,P(t)),s=Math.max(a.width+(t.padding??0)*2,t?.width??0),c=Math.max(a.height+(t.padding??0)*2,t?.height??0),l=c/8,u=.2*s,d=.2*c,f=c+l,{cssStyles:p}=t,m=C.svg(i),h=g(t,{});t.look!==`handDrawn`&&(h.roughness=0,h.fillStyle=`solid`);let v=[{x:-s/2-s/2*.1,y:f/2},...I(-s/2-s/2*.1,f/2,s/2+s/2*.1,f/2,l,.8),{x:s/2+s/2*.1,y:-f/2},{x:-s/2-s/2*.1,y:-f/2}],y=-s/2+s/2*.1,b=-f/2-d*.4,x=[{x:y+s-u,y:(b+c)*1.3},{x:y+s,y:b+c-d},{x:y+s,y:(b+c)*.9},...I(y+s,(b+c)*1.25,y+s-u,(b+c)*1.3,-c*.02,.5)],S=F(v),w=m.path(S,h),T=F(x),E=m.path(T,{...h,fillStyle:`solid`}),D=i.insert(()=>E,`:first-child`);return D.insert(()=>w,`:first-child`),D.attr(`class`,`basic label-container outer-path`),p&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,p),r&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,r),D.attr(`transform`,`translate(0,${-l/2})`),o.attr(`transform`,`translate(${-s/2+(t.padding??0)-(a.x-(a.left??0))},${-c/2+(t.padding??0)-l/2-(a.y-(a.top??0))})`),N(t,D),t.intersect=function(e){return K.polygon(t,v,e)},i}o(zt,`taggedWaveEdgedRectangle`);async function Bt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a}=await j(e,t,P(t)),o=Math.max(a.width+(t.padding??0),t?.width||0),s=Math.max(a.height+(t.padding??0),t?.height||0),c=-o/2,l=-s/2,u=i.insert(`rect`,`:first-child`);return u.attr(`class`,`text`).attr(`style`,r).attr(`rx`,0).attr(`ry`,0).attr(`x`,c).attr(`y`,l).attr(`width`,o).attr(`height`,s),N(t,u),t.intersect=function(e){return K.rect(t,e)},i}o(Bt,`text`);var Vt=o((e,t,n,r,i,a)=>`M${e},${t}
3
3
  a${i},${a} 0,0,1 0,${-r}
4
4
  l${n},0
@@ -1,2 +1,2 @@
1
- import{Hr as e,Vr as t}from"./split-url-EQlIwqCq.js";import{n,t as r}from"./src-KUZZYZBk.js";import{n as i}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{R as a,h as o,p as s,r as c,s as l}from"./chunk-DU6HZSFF-D25kbUvc.js";import{s as u}from"./html-BYfTdFQ4.js";import{t as d}from"./dist-CN30VTUJ.js";function f(e){if(typeof e!=`object`||!e)return!1;if(Object.getPrototypeOf(e)===null)return!0;if(Object.prototype.toString.call(e)!==`[object Object]`){let t=e[Symbol.toStringTag];return t==null||!Object.getOwnPropertyDescriptor(e,Symbol.toStringTag)?.writable?!1:e.toString()===`[object ${t}]`}let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function ee(){}function te(e){return Object.getOwnPropertySymbols(e).filter(t=>Object.prototype.propertyIsEnumerable.call(e,t))}var ne=`[object RegExp]`,p=`[object String]`,m=`[object Number]`,h=`[object Boolean]`,g=`[object Arguments]`,re=`[object Symbol]`,ie=`[object Date]`,_=`[object Map]`,v=`[object Set]`,y=`[object Array]`,b=`[object ArrayBuffer]`,ae=`[object Object]`,oe=`[object DataView]`,se=`[object Uint8Array]`,ce=`[object Uint8ClampedArray]`,le=`[object Uint16Array]`,ue=`[object Uint32Array]`,de=`[object Int8Array]`,fe=`[object Int16Array]`,pe=`[object Int32Array]`,me=`[object Float32Array]`,he=`[object Float64Array]`,ge=typeof globalThis==`object`&&globalThis||typeof window==`object`&&window||typeof self==`object`&&self||typeof global==`object`&&global||(function(){return this})();function x(e){return ge.Buffer!==void 0&&ge.Buffer.isBuffer(e)}function _e(e){return Number.isSafeInteger(e)&&e>=0}function ve(e){return e!=null&&typeof e!=`function`&&_e(e.length)}function ye(e){return e===`__proto__`}function S(e){return e==null||typeof e!=`object`&&typeof e!=`function`}function C(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function be(e,t){return w(e,void 0,e,new Map,t)}function w(e,t,n,r=new Map,i=void 0){let a=i?.(e,t,n,r);if(a!==void 0)return a;if(S(e))return e;if(r.has(e))return r.get(e);if(Array.isArray(e)){let t=Array(e.length);r.set(e,t);for(let a=0;a<e.length;a++)t[a]=w(e[a],a,n,r,i);return Object.hasOwn(e,`index`)&&(t.index=e.index),Object.hasOwn(e,`input`)&&(t.input=e.input),t}if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp){let t=new RegExp(e.source,e.flags);return t.lastIndex=e.lastIndex,t}if(e instanceof Map){let t=new Map;r.set(e,t);for(let[a,o]of e)t.set(a,w(o,a,n,r,i));return t}if(e instanceof Set){let t=new Set;r.set(e,t);for(let a of e)t.add(w(a,void 0,n,r,i));return t}if(x(e))return e.subarray();if(C(e)){let t=new(Object.getPrototypeOf(e)).constructor(e.length);r.set(e,t);for(let a=0;a<e.length;a++)t[a]=w(e[a],a,n,r,i);return t}if(e instanceof ArrayBuffer||typeof SharedArrayBuffer<`u`&&e instanceof SharedArrayBuffer)return e.slice(0);if(e instanceof DataView){let t=new DataView(e.buffer.slice(0),e.byteOffset,e.byteLength);return r.set(e,t),T(t,e,n,r,i),t}if(typeof File<`u`&&e instanceof File){let t=new File([e],e.name,{type:e.type});return r.set(e,t),T(t,e,n,r,i),t}if(typeof Blob<`u`&&e instanceof Blob){let t=new Blob([e],{type:e.type});return r.set(e,t),T(t,e,n,r,i),t}if(e instanceof Error){let t=structuredClone(e);return r.set(e,t),t.message=e.message,t.name=e.name,t.stack=e.stack,t.cause=e.cause,t.constructor=e.constructor,T(t,e,n,r,i),t}if(e instanceof Boolean){let t=new Boolean(e.valueOf());return r.set(e,t),T(t,e,n,r,i),t}if(e instanceof Number){let t=new Number(e.valueOf());return r.set(e,t),T(t,e,n,r,i),t}if(e instanceof String){let t=new String(e.valueOf());return r.set(e,t),T(t,e,n,r,i),t}if(typeof e==`object`&&xe(e)){let t=Object.create(Object.getPrototypeOf(e));return r.set(e,t),T(t,e,n,r,i),t}return e}function T(e,t,n=e,r,i){let a=[...Object.keys(t),...te(t)];for(let o=0;o<a.length;o++){let s=a[o],c=Object.getOwnPropertyDescriptor(e,s);(c==null||c.writable)&&(e[s]=w(t[s],s,n,r,i))}}function xe(t){switch(e(t)){case g:case y:case b:case oe:case h:case ie:case me:case he:case de:case fe:case pe:case _:case m:case ae:case ne:case v:case p:case re:case se:case ce:case le:case ue:return!0;default:return!1}}function Se(t,n){return be(t,(r,i,a,o)=>{let s=n?.(r,i,a,o);if(s!==void 0)return s;if(typeof t==`object`){if(e(t)===`[object Object]`&&typeof t.constructor!=`function`){let e={};return o.set(t,e),T(e,t,a,o),e}switch(Object.prototype.toString.call(t)){case m:case p:case h:{let e=new t.constructor(t?.valueOf());return T(e,t),e}case g:{let e={};return T(e,t),e.length=t.length,e[Symbol.iterator]=t[Symbol.iterator],e}default:return}}})}function Ce(e){return Se(e)}function E(t){return typeof t==`object`&&!!t&&e(t)===`[object Arguments]`}function we(e){return t(e)&&ve(e)}function D(e){return C(e)}function O(e,t){if(typeof e!=`function`||t!=null&&typeof t!=`function`)throw TypeError(`Expected a function`);let n=function(...r){let i=t?t.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);let o=e.apply(this,r);return n.cache=a.set(i,o)||a,o};return n.cache=new(O.Cache||Map),n}O.Cache=Map;function Te(e){if(S(e))return e;if(Array.isArray(e)||C(e)||e instanceof ArrayBuffer||typeof SharedArrayBuffer<`u`&&e instanceof SharedArrayBuffer)return e.slice(0);let t=Object.getPrototypeOf(e);if(t==null)return Object.assign(Object.create(t),e);let n=t.constructor;if(e instanceof Date||e instanceof Map||e instanceof Set)return new n(e);if(e instanceof RegExp){let t=new n(e);return t.lastIndex=e.lastIndex,t}if(e instanceof DataView)return new n(e.buffer.slice(0));if(e instanceof Error){let t;return t=e instanceof AggregateError?new n(e.errors,e.message,{cause:e.cause}):new n(e.message,{cause:e.cause}),t.stack=e.stack,Object.assign(t,e),t}return typeof File<`u`&&e instanceof File?new n([e],e.name,{type:e.type,lastModified:e.lastModified}):typeof e==`object`?Object.assign(Object.create(t),e):e}function Ee(e,...t){let n=t.slice(0,-1),r=t[t.length-1],i=e;for(let e=0;e<n.length;e++){let t=n[e];i=k(i,t,r,new Map)}return i}function k(e,n,r,i){if(S(e)&&(e=Object(e)),typeof n!=`object`||!n)return e;if(i.has(n))return Te(i.get(n));if(i.set(n,e),Array.isArray(n)){n=n.slice();for(let e=0;e<n.length;e++)e in n||(n[e]=void 0)}let a=[...Object.keys(n),...te(n)];for(let o=0;o<a.length;o++){let s=a[o];if(ye(s))continue;let c=n[s],l=e[s];if(E(c)&&(c={...c}),E(l)&&(l={...l}),x(c)&&(c=Ce(c)),Array.isArray(c)){if(Array.isArray(l)){let e=[],t=Reflect.ownKeys(l);for(let n=0;n<t.length;n++){let r=t[n];e[r]=l[r]}l=e}else if(we(l)){let e=[];for(let t=0;t<l.length;t++)e[t]=l[t];l=e}else l=[]}let u=r(l,c,s,e,n,i);u===void 0?Array.isArray(c)||t(l)&&t(c)&&(f(l)||f(c)||D(l)||D(c))?e[s]=k(l,c,r,i):l==null&&f(c)?e[s]=k({},c,r,i):l==null&&D(c)?e[s]=Ce(c):(l===void 0||c!==void 0)&&(e[s]=c):e[s]=u}return e}function De(e,...t){return Ee(e,...t,ee)}var A=class{constructor(e,t){this._context=e,this._x=t}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(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._x?this._context.bezierCurveTo(this._x0=(this._x0+e)/2,this._y0,this._x0,t,e,t):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+t)/2,e,this._y0,e,t)}this._x0=e,this._y0=t}};function j(e){return new A(e,!0)}function Oe(e){return new A(e,!1)}function M(){}function N(e,t,n){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+n)/6)}function P(e){this._context=e}P.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:N(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(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:N(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function ke(e){return new P(e)}function Ae(e){this._context=e}Ae.prototype={areaStart:M,areaEnd:M,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)}},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:N(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function je(e){return new Ae(e)}function Me(e){this._context=e}Me.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 n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:N(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function Ne(e){return new Me(e)}function Pe(e,t){this._basis=new P(e),this._beta=t}Pe.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,n=e.length-1;if(n>0)for(var r=e[0],i=t[0],a=e[n]-r,o=t[n]-i,s=-1,c;++s<=n;)c=s/n,this._basis.point(this._beta*e[s]+(1-this._beta)*(r+c*a),this._beta*t[s]+(1-this._beta)*(i+c*o));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};var Fe=(function e(t){function n(e){return t===1?new P(e):new Pe(e,t)}return n.beta=function(t){return e(+t)},n})(.85);function F(e,t,n){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-n),e._x2,e._y2)}function I(e,t){this._context=e,this._k=(1-t)/6}I.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:F(this,this._x1,this._y1)}(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:F(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var Ie=(function e(t){function n(e){return new I(e,t)}return n.tension=function(t){return e(+t)},n})(0);function L(e,t){this._context=e,this._k=(1-t)/6}L.prototype={areaStart:M,areaEnd:M,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)}},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:F(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var Le=(function e(t){function n(e){return new L(e,t)}return n.tension=function(t){return e(+t)},n})(0);function R(e,t){this._context=e,this._k=(1-t)/6}R.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:F(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var Re=(function e(t){function n(e){return new R(e,t)}return n.tension=function(t){return e(+t)},n})(0);function z(e,t,n){var r=e._x1,i=e._y1,a=e._x2,o=e._y2;if(e._l01_a>1e-12){var s=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,c=3*e._l01_a*(e._l01_a+e._l12_a);r=(r*s-e._x0*e._l12_2a+e._x2*e._l01_2a)/c,i=(i*s-e._y0*e._l12_2a+e._y2*e._l01_2a)/c}if(e._l23_a>1e-12){var l=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,u=3*e._l23_a*(e._l23_a+e._l12_a);a=(a*l+e._x1*e._l23_2a-t*e._l12_2a)/u,o=(o*l+e._y1*e._l23_2a-n*e._l12_2a)/u}e._context.bezierCurveTo(r,i,a,o,e._x2,e._y2)}function ze(e,t){this._context=e,this._alpha=t}ze.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)}(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 n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=(n*n+r*r)**+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:z(this,e,t)}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}};var B=(function e(t){function n(e){return t?new ze(e,t):new I(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function Be(e,t){this._context=e,this._alpha=t}Be.prototype={areaStart:M,areaEnd:M,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)}},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=(n*n+r*r)**+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:z(this,e,t)}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}};var Ve=(function e(t){function n(e){return t?new Be(e,t):new L(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function He(e,t){this._context=e,this._alpha=t}He.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 n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=(n*n+r*r)**+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:z(this,e,t)}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}};var Ue=(function e(t){function n(e){return t?new He(e,t):new R(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function We(e){this._context=e}We.prototype={areaStart:M,areaEnd:M,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 Ge(e){return new We(e)}function Ke(e){return e<0?-1:1}function qe(e,t,n){var r=e._x1-e._x0,i=t-e._x1,a=(e._y1-e._y0)/(r||i<0&&-0),o=(n-e._y1)/(i||r<0&&-0),s=(a*i+o*r)/(r+i);return(Ke(a)+Ke(o))*Math.min(Math.abs(a),Math.abs(o),.5*Math.abs(s))||0}function Je(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function V(e,t,n){var r=e._x0,i=e._y0,a=e._x1,o=e._y1,s=(a-r)/3;e._context.bezierCurveTo(r+s,i+s*t,a-s,o-s*n,a,o)}function H(e){this._context=e}H.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:V(this,this._t0,Je(this,this._t0))}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var n=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,V(this,Je(this,n=qe(this,e,t)),n);break;default:V(this,this._t0,n=qe(this,e,t))}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function Ye(e){this._context=new Xe(e)}(Ye.prototype=Object.create(H.prototype)).point=function(e,t){H.prototype.point.call(this,t,e)};function Xe(e){this._context=e}Xe.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,n,r,i,a){this._context.bezierCurveTo(t,e,r,n,a,i)}};function Ze(e){return new H(e)}function Qe(e){return new Ye(e)}function $e(e){this._context=e}$e.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,n=e.length;if(n){if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),n===2)this._context.lineTo(e[1],t[1]);else for(var r=et(e),i=et(t),a=0,o=1;o<n;++a,++o)this._context.bezierCurveTo(r[0][a],i[0][a],r[1][a],i[1][a],e[o],t[o])}(this._line||this._line!==0&&n===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 et(e){var t,n=e.length-1,r,i=Array(n),a=Array(n),o=Array(n);for(i[0]=0,a[0]=2,o[0]=e[0]+2*e[1],t=1;t<n-1;++t)i[t]=1,a[t]=4,o[t]=4*e[t]+2*e[t+1];for(i[n-1]=2,a[n-1]=7,o[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=i[t]/a[t-1],a[t]-=r,o[t]-=r*o[t-1];for(i[n-1]=o[n-1]/a[n-1],t=n-2;t>=0;--t)i[t]=(o[t]-i[t+1])/a[t];for(a[n-1]=(e[n]+i[n-1])/2,t=0;t<n-1;++t)a[t]=2*e[t+1]-i[t+1];return[i,a]}function tt(e){return new $e(e)}function U(e,t){this._context=e,this._t=t}U.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 n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}}this._x=e,this._y=t}};function nt(e){return new U(e,.5)}function rt(e){return new U(e,0)}function it(e){return new U(e,1)}var at=d(),ot={curveBasis:ke,curveBasisClosed:je,curveBasisOpen:Ne,curveBumpX:j,curveBumpY:Oe,curveBundle:Fe,curveCardinalClosed:Le,curveCardinalOpen:Re,curveCardinal:Ie,curveCatmullRomClosed:Ve,curveCatmullRomOpen:Ue,curveCatmullRom:B,curveLinear:u,curveLinearClosed:Ge,curveMonotoneX:Ze,curveMonotoneY:Qe,curveNatural:tt,curveStep:nt,curveStepAfter:it,curveStepBefore:rt},st=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,ct=i(function(e,t){let n=lt(e,/(?:init\b)|(?:initialize\b)/),r={};if(Array.isArray(n)){let e=n.map(e=>e.args);a(e),r=c(r,[...e])}else r=n.args;if(!r)return;let i=s(e,t),o=`config`;return r[o]!==void 0&&(i===`flowchart-v2`&&(i=`flowchart`),r[i]=r[o],delete r[o]),r},`detectInit`),lt=i(function(e,t=null){try{let r=RegExp(`[%]{2}(?![{]${st.source})(?=[}][%]{2}).*
1
+ import{Hr as e,Vr as t}from"./split-url-D0Eu87y4.js";import{n,t as r}from"./src-KUZZYZBk.js";import{n as i}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{R as a,h as o,p as s,r as c,s as l}from"./chunk-DU6HZSFF-Dr7PaN7b.js";import{s as u}from"./html-BYfTdFQ4.js";import{t as d}from"./dist-CN30VTUJ.js";function f(e){if(typeof e!=`object`||!e)return!1;if(Object.getPrototypeOf(e)===null)return!0;if(Object.prototype.toString.call(e)!==`[object Object]`){let t=e[Symbol.toStringTag];return t==null||!Object.getOwnPropertyDescriptor(e,Symbol.toStringTag)?.writable?!1:e.toString()===`[object ${t}]`}let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function ee(){}function te(e){return Object.getOwnPropertySymbols(e).filter(t=>Object.prototype.propertyIsEnumerable.call(e,t))}var ne=`[object RegExp]`,p=`[object String]`,m=`[object Number]`,h=`[object Boolean]`,g=`[object Arguments]`,re=`[object Symbol]`,ie=`[object Date]`,_=`[object Map]`,v=`[object Set]`,y=`[object Array]`,b=`[object ArrayBuffer]`,ae=`[object Object]`,oe=`[object DataView]`,se=`[object Uint8Array]`,ce=`[object Uint8ClampedArray]`,le=`[object Uint16Array]`,ue=`[object Uint32Array]`,de=`[object Int8Array]`,fe=`[object Int16Array]`,pe=`[object Int32Array]`,me=`[object Float32Array]`,he=`[object Float64Array]`,ge=typeof globalThis==`object`&&globalThis||typeof window==`object`&&window||typeof self==`object`&&self||typeof global==`object`&&global||(function(){return this})();function x(e){return ge.Buffer!==void 0&&ge.Buffer.isBuffer(e)}function _e(e){return Number.isSafeInteger(e)&&e>=0}function ve(e){return e!=null&&typeof e!=`function`&&_e(e.length)}function ye(e){return e===`__proto__`}function S(e){return e==null||typeof e!=`object`&&typeof e!=`function`}function C(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function be(e,t){return w(e,void 0,e,new Map,t)}function w(e,t,n,r=new Map,i=void 0){let a=i?.(e,t,n,r);if(a!==void 0)return a;if(S(e))return e;if(r.has(e))return r.get(e);if(Array.isArray(e)){let t=Array(e.length);r.set(e,t);for(let a=0;a<e.length;a++)t[a]=w(e[a],a,n,r,i);return Object.hasOwn(e,`index`)&&(t.index=e.index),Object.hasOwn(e,`input`)&&(t.input=e.input),t}if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp){let t=new RegExp(e.source,e.flags);return t.lastIndex=e.lastIndex,t}if(e instanceof Map){let t=new Map;r.set(e,t);for(let[a,o]of e)t.set(a,w(o,a,n,r,i));return t}if(e instanceof Set){let t=new Set;r.set(e,t);for(let a of e)t.add(w(a,void 0,n,r,i));return t}if(x(e))return e.subarray();if(C(e)){let t=new(Object.getPrototypeOf(e)).constructor(e.length);r.set(e,t);for(let a=0;a<e.length;a++)t[a]=w(e[a],a,n,r,i);return t}if(e instanceof ArrayBuffer||typeof SharedArrayBuffer<`u`&&e instanceof SharedArrayBuffer)return e.slice(0);if(e instanceof DataView){let t=new DataView(e.buffer.slice(0),e.byteOffset,e.byteLength);return r.set(e,t),T(t,e,n,r,i),t}if(typeof File<`u`&&e instanceof File){let t=new File([e],e.name,{type:e.type});return r.set(e,t),T(t,e,n,r,i),t}if(typeof Blob<`u`&&e instanceof Blob){let t=new Blob([e],{type:e.type});return r.set(e,t),T(t,e,n,r,i),t}if(e instanceof Error){let t=structuredClone(e);return r.set(e,t),t.message=e.message,t.name=e.name,t.stack=e.stack,t.cause=e.cause,t.constructor=e.constructor,T(t,e,n,r,i),t}if(e instanceof Boolean){let t=new Boolean(e.valueOf());return r.set(e,t),T(t,e,n,r,i),t}if(e instanceof Number){let t=new Number(e.valueOf());return r.set(e,t),T(t,e,n,r,i),t}if(e instanceof String){let t=new String(e.valueOf());return r.set(e,t),T(t,e,n,r,i),t}if(typeof e==`object`&&xe(e)){let t=Object.create(Object.getPrototypeOf(e));return r.set(e,t),T(t,e,n,r,i),t}return e}function T(e,t,n=e,r,i){let a=[...Object.keys(t),...te(t)];for(let o=0;o<a.length;o++){let s=a[o],c=Object.getOwnPropertyDescriptor(e,s);(c==null||c.writable)&&(e[s]=w(t[s],s,n,r,i))}}function xe(t){switch(e(t)){case g:case y:case b:case oe:case h:case ie:case me:case he:case de:case fe:case pe:case _:case m:case ae:case ne:case v:case p:case re:case se:case ce:case le:case ue:return!0;default:return!1}}function Se(t,n){return be(t,(r,i,a,o)=>{let s=n?.(r,i,a,o);if(s!==void 0)return s;if(typeof t==`object`){if(e(t)===`[object Object]`&&typeof t.constructor!=`function`){let e={};return o.set(t,e),T(e,t,a,o),e}switch(Object.prototype.toString.call(t)){case m:case p:case h:{let e=new t.constructor(t?.valueOf());return T(e,t),e}case g:{let e={};return T(e,t),e.length=t.length,e[Symbol.iterator]=t[Symbol.iterator],e}default:return}}})}function Ce(e){return Se(e)}function E(t){return typeof t==`object`&&!!t&&e(t)===`[object Arguments]`}function we(e){return t(e)&&ve(e)}function D(e){return C(e)}function O(e,t){if(typeof e!=`function`||t!=null&&typeof t!=`function`)throw TypeError(`Expected a function`);let n=function(...r){let i=t?t.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);let o=e.apply(this,r);return n.cache=a.set(i,o)||a,o};return n.cache=new(O.Cache||Map),n}O.Cache=Map;function Te(e){if(S(e))return e;if(Array.isArray(e)||C(e)||e instanceof ArrayBuffer||typeof SharedArrayBuffer<`u`&&e instanceof SharedArrayBuffer)return e.slice(0);let t=Object.getPrototypeOf(e);if(t==null)return Object.assign(Object.create(t),e);let n=t.constructor;if(e instanceof Date||e instanceof Map||e instanceof Set)return new n(e);if(e instanceof RegExp){let t=new n(e);return t.lastIndex=e.lastIndex,t}if(e instanceof DataView)return new n(e.buffer.slice(0));if(e instanceof Error){let t;return t=e instanceof AggregateError?new n(e.errors,e.message,{cause:e.cause}):new n(e.message,{cause:e.cause}),t.stack=e.stack,Object.assign(t,e),t}return typeof File<`u`&&e instanceof File?new n([e],e.name,{type:e.type,lastModified:e.lastModified}):typeof e==`object`?Object.assign(Object.create(t),e):e}function Ee(e,...t){let n=t.slice(0,-1),r=t[t.length-1],i=e;for(let e=0;e<n.length;e++){let t=n[e];i=k(i,t,r,new Map)}return i}function k(e,n,r,i){if(S(e)&&(e=Object(e)),typeof n!=`object`||!n)return e;if(i.has(n))return Te(i.get(n));if(i.set(n,e),Array.isArray(n)){n=n.slice();for(let e=0;e<n.length;e++)e in n||(n[e]=void 0)}let a=[...Object.keys(n),...te(n)];for(let o=0;o<a.length;o++){let s=a[o];if(ye(s))continue;let c=n[s],l=e[s];if(E(c)&&(c={...c}),E(l)&&(l={...l}),x(c)&&(c=Ce(c)),Array.isArray(c)){if(Array.isArray(l)){let e=[],t=Reflect.ownKeys(l);for(let n=0;n<t.length;n++){let r=t[n];e[r]=l[r]}l=e}else if(we(l)){let e=[];for(let t=0;t<l.length;t++)e[t]=l[t];l=e}else l=[]}let u=r(l,c,s,e,n,i);u===void 0?Array.isArray(c)||t(l)&&t(c)&&(f(l)||f(c)||D(l)||D(c))?e[s]=k(l,c,r,i):l==null&&f(c)?e[s]=k({},c,r,i):l==null&&D(c)?e[s]=Ce(c):(l===void 0||c!==void 0)&&(e[s]=c):e[s]=u}return e}function De(e,...t){return Ee(e,...t,ee)}var A=class{constructor(e,t){this._context=e,this._x=t}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(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._x?this._context.bezierCurveTo(this._x0=(this._x0+e)/2,this._y0,this._x0,t,e,t):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+t)/2,e,this._y0,e,t)}this._x0=e,this._y0=t}};function j(e){return new A(e,!0)}function Oe(e){return new A(e,!1)}function M(){}function N(e,t,n){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+n)/6)}function P(e){this._context=e}P.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:N(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(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:N(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function ke(e){return new P(e)}function Ae(e){this._context=e}Ae.prototype={areaStart:M,areaEnd:M,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)}},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:N(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function je(e){return new Ae(e)}function Me(e){this._context=e}Me.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 n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:N(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function Ne(e){return new Me(e)}function Pe(e,t){this._basis=new P(e),this._beta=t}Pe.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,n=e.length-1;if(n>0)for(var r=e[0],i=t[0],a=e[n]-r,o=t[n]-i,s=-1,c;++s<=n;)c=s/n,this._basis.point(this._beta*e[s]+(1-this._beta)*(r+c*a),this._beta*t[s]+(1-this._beta)*(i+c*o));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};var Fe=(function e(t){function n(e){return t===1?new P(e):new Pe(e,t)}return n.beta=function(t){return e(+t)},n})(.85);function F(e,t,n){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-n),e._x2,e._y2)}function I(e,t){this._context=e,this._k=(1-t)/6}I.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:F(this,this._x1,this._y1)}(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:F(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var Ie=(function e(t){function n(e){return new I(e,t)}return n.tension=function(t){return e(+t)},n})(0);function L(e,t){this._context=e,this._k=(1-t)/6}L.prototype={areaStart:M,areaEnd:M,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)}},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:F(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var Le=(function e(t){function n(e){return new L(e,t)}return n.tension=function(t){return e(+t)},n})(0);function R(e,t){this._context=e,this._k=(1-t)/6}R.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:F(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var Re=(function e(t){function n(e){return new R(e,t)}return n.tension=function(t){return e(+t)},n})(0);function z(e,t,n){var r=e._x1,i=e._y1,a=e._x2,o=e._y2;if(e._l01_a>1e-12){var s=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,c=3*e._l01_a*(e._l01_a+e._l12_a);r=(r*s-e._x0*e._l12_2a+e._x2*e._l01_2a)/c,i=(i*s-e._y0*e._l12_2a+e._y2*e._l01_2a)/c}if(e._l23_a>1e-12){var l=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,u=3*e._l23_a*(e._l23_a+e._l12_a);a=(a*l+e._x1*e._l23_2a-t*e._l12_2a)/u,o=(o*l+e._y1*e._l23_2a-n*e._l12_2a)/u}e._context.bezierCurveTo(r,i,a,o,e._x2,e._y2)}function ze(e,t){this._context=e,this._alpha=t}ze.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)}(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 n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=(n*n+r*r)**+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:z(this,e,t)}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}};var B=(function e(t){function n(e){return t?new ze(e,t):new I(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function Be(e,t){this._context=e,this._alpha=t}Be.prototype={areaStart:M,areaEnd:M,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)}},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=(n*n+r*r)**+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:z(this,e,t)}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}};var Ve=(function e(t){function n(e){return t?new Be(e,t):new L(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function He(e,t){this._context=e,this._alpha=t}He.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 n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=(n*n+r*r)**+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:z(this,e,t)}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}};var Ue=(function e(t){function n(e){return t?new He(e,t):new R(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function We(e){this._context=e}We.prototype={areaStart:M,areaEnd:M,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 Ge(e){return new We(e)}function Ke(e){return e<0?-1:1}function qe(e,t,n){var r=e._x1-e._x0,i=t-e._x1,a=(e._y1-e._y0)/(r||i<0&&-0),o=(n-e._y1)/(i||r<0&&-0),s=(a*i+o*r)/(r+i);return(Ke(a)+Ke(o))*Math.min(Math.abs(a),Math.abs(o),.5*Math.abs(s))||0}function Je(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function V(e,t,n){var r=e._x0,i=e._y0,a=e._x1,o=e._y1,s=(a-r)/3;e._context.bezierCurveTo(r+s,i+s*t,a-s,o-s*n,a,o)}function H(e){this._context=e}H.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:V(this,this._t0,Je(this,this._t0))}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var n=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,V(this,Je(this,n=qe(this,e,t)),n);break;default:V(this,this._t0,n=qe(this,e,t))}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function Ye(e){this._context=new Xe(e)}(Ye.prototype=Object.create(H.prototype)).point=function(e,t){H.prototype.point.call(this,t,e)};function Xe(e){this._context=e}Xe.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,n,r,i,a){this._context.bezierCurveTo(t,e,r,n,a,i)}};function Ze(e){return new H(e)}function Qe(e){return new Ye(e)}function $e(e){this._context=e}$e.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,n=e.length;if(n){if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),n===2)this._context.lineTo(e[1],t[1]);else for(var r=et(e),i=et(t),a=0,o=1;o<n;++a,++o)this._context.bezierCurveTo(r[0][a],i[0][a],r[1][a],i[1][a],e[o],t[o])}(this._line||this._line!==0&&n===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 et(e){var t,n=e.length-1,r,i=Array(n),a=Array(n),o=Array(n);for(i[0]=0,a[0]=2,o[0]=e[0]+2*e[1],t=1;t<n-1;++t)i[t]=1,a[t]=4,o[t]=4*e[t]+2*e[t+1];for(i[n-1]=2,a[n-1]=7,o[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=i[t]/a[t-1],a[t]-=r,o[t]-=r*o[t-1];for(i[n-1]=o[n-1]/a[n-1],t=n-2;t>=0;--t)i[t]=(o[t]-i[t+1])/a[t];for(a[n-1]=(e[n]+i[n-1])/2,t=0;t<n-1;++t)a[t]=2*e[t+1]-i[t+1];return[i,a]}function tt(e){return new $e(e)}function U(e,t){this._context=e,this._t=t}U.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 n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}}this._x=e,this._y=t}};function nt(e){return new U(e,.5)}function rt(e){return new U(e,0)}function it(e){return new U(e,1)}var at=d(),ot={curveBasis:ke,curveBasisClosed:je,curveBasisOpen:Ne,curveBumpX:j,curveBumpY:Oe,curveBundle:Fe,curveCardinalClosed:Le,curveCardinalOpen:Re,curveCardinal:Ie,curveCatmullRomClosed:Ve,curveCatmullRomOpen:Ue,curveCatmullRom:B,curveLinear:u,curveLinearClosed:Ge,curveMonotoneX:Ze,curveMonotoneY:Qe,curveNatural:tt,curveStep:nt,curveStepAfter:it,curveStepBefore:rt},st=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,ct=i(function(e,t){let n=lt(e,/(?:init\b)|(?:initialize\b)/),r={};if(Array.isArray(n)){let e=n.map(e=>e.args);a(e),r=c(r,[...e])}else r=n.args;if(!r)return;let i=s(e,t),o=`config`;return r[o]!==void 0&&(i===`flowchart-v2`&&(i=`flowchart`),r[i]=r[o],delete r[o]),r},`detectInit`),lt=i(function(e,t=null){try{let r=RegExp(`[%]{2}(?![{]${st.source})(?=[}][%]{2}).*
2
2
  `,`ig`);e=e.trim().replace(r,``).replace(/'/gm,`"`),n.debug(`Detecting diagram directive${t===null?``:` type:`+t} based on the text:${e}`);let i,a=[];for(;(i=o.exec(e))!==null;)if(i.index===o.lastIndex&&o.lastIndex++,i&&!t||t&&i[1]?.match(t)||t&&i[2]?.match(t)){let e=i[1]?i[1]:i[2],t=i[3]?i[3].trim():i[4]?JSON.parse(i[4].trim()):null;a.push({type:e,args:t})}return a.length===0?{type:e,args:null}:a.length===1?a[0]:a}catch(r){return n.error(`ERROR: ${r.message} - Unable to parse directive type: '${t}' based on the text: '${e}'`),{type:void 0,args:null}}},`detectDirective`),ut=i(function(e){return e.replace(o,``)},`removeDirectives`),dt=i(function(e,t){for(let[n,r]of t.entries())if(r.match(e))return n;return-1},`isSubstringInArray`);function W(e,t){return e?ot[`curve${e.charAt(0).toUpperCase()+e.slice(1)}`]??t:t}i(W,`interpolateToCurve`);function ft(e,t){let n=e.trim();if(n)return t.securityLevel===`loose`?n:(0,at.sanitizeUrl)(n)}i(ft,`formatUrl`);var pt=i((e,...t)=>{let r=e.split(`.`),i=r.length-1,a=r[i],o=window;for(let t=0;t<i;t++)if(o=o[r[t]],!o){n.error(`Function name: ${e} not found in window`);return}o[a](...t)},`runFunc`);function G(e,t){return!e||!t?0:Math.sqrt((t.x-e.x)**2+(t.y-e.y)**2)}i(G,`distance`);function mt(e){let t,n=0;return e.forEach(e=>{n+=G(e,t),t=e}),K(e,n/2)}i(mt,`traverseEdge`);function ht(e){return e.length===1?e[0]:mt(e)}i(ht,`calcLabelPosition`);var gt=i((e,t=2)=>{let n=10**t;return Math.round(e*n)/n},`roundNumber`),K=i((e,t)=>{let n,r=t;for(let t of e){if(n){let e=G(t,n);if(e===0)return n;if(e<r)r-=e;else{let i=r/e;if(i<=0)return n;if(i>=1)return{x:t.x,y:t.y};if(i>0&&i<1)return{x:gt((1-i)*n.x+i*t.x,5),y:gt((1-i)*n.y+i*t.y,5)}}}n=t}throw Error(`Could not find a suitable point for the given distance`)},`calculatePoint`),_t=i((e,t,r)=>{n.info(`our points ${JSON.stringify(t)}`),t[0]!==r&&(t=t.reverse());let i=K(t,25),a=e?10:5,o=Math.atan2(t[0].y-i.y,t[0].x-i.x),s={x:0,y:0};return s.x=Math.sin(o)*a+(t[0].x+i.x)/2,s.y=-Math.cos(o)*a+(t[0].y+i.y)/2,s},`calcCardinalityPosition`);function vt(e,t,r){let i=structuredClone(r);n.info(`our points`,i),t!==`start_left`&&t!==`start_right`&&i.reverse();let a=K(i,25+e),o=10+e*.5,s=Math.atan2(i[0].y-a.y,i[0].x-a.x),c={x:0,y:0};return t===`start_left`?(c.x=Math.sin(s+Math.PI)*o+(i[0].x+a.x)/2,c.y=-Math.cos(s+Math.PI)*o+(i[0].y+a.y)/2):t===`end_right`?(c.x=Math.sin(s-Math.PI)*o+(i[0].x+a.x)/2-5,c.y=-Math.cos(s-Math.PI)*o+(i[0].y+a.y)/2-5):t===`end_left`?(c.x=Math.sin(s)*o+(i[0].x+a.x)/2-5,c.y=-Math.cos(s)*o+(i[0].y+a.y)/2-5):(c.x=Math.sin(s)*o+(i[0].x+a.x)/2,c.y=-Math.cos(s)*o+(i[0].y+a.y)/2),c}i(vt,`calcTerminalLabelPosition`);function q(e){let t=``,n=``;for(let r of e)r!==void 0&&(r.startsWith(`color:`)||r.startsWith(`text-align:`)?n=n+r+`;`:t=t+r+`;`);return{style:t,labelStyle:n}}i(q,`getStylesFromArray`);var yt=0,bt=i(()=>(yt++,`id-`+Math.random().toString(36).substr(2,12)+`-`+yt),`generateId`);function xt(e){let t=``;for(let n=0;n<e;n++)t+=`0123456789abcdef`.charAt(Math.floor(Math.random()*16));return t}i(xt,`makeRandomHex`);var St=i(e=>xt(e.length),`random`),Ct=i(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`),wt=i(function(e,t){let n=t.text.replace(l.lineBreakRegex,` `),[,r]=Q(t.fontSize),i=e.append(`text`);i.attr(`x`,t.x),i.attr(`y`,t.y),i.style(`text-anchor`,t.anchor),i.style(`font-family`,t.fontFamily),i.style(`font-size`,r),i.style(`font-weight`,t.fontWeight),i.attr(`fill`,t.fill),t.class!==void 0&&i.attr(`class`,t.class);let a=i.append(`tspan`);return a.attr(`x`,t.x+t.textMargin*2),a.attr(`fill`,t.fill),a.text(n),i},`drawSimpleText`),Tt=O((e,t,n)=>{if(!e||(n=Object.assign({fontSize:12,fontWeight:400,fontFamily:`Arial`,joinWith:`<br/>`},n),l.lineBreakRegex.test(e)))return e;let r=e.split(` `).filter(Boolean),i=[],a=``;return r.forEach((e,o)=>{let s=Y(`${e} `,n),c=Y(a,n);if(s>t){let{hyphenatedStrings:r,remainingWord:o}=Et(e,t,`-`,n);i.push(a,...r),a=o}else c+s>=t?(i.push(a),a=e):a=[a,e].filter(Boolean).join(` `);o+1===r.length&&i.push(a)}),i.filter(e=>e!==``).join(n.joinWith)},(e,t,n)=>`${e}${t}${n.fontSize}${n.fontWeight}${n.fontFamily}${n.joinWith}`),Et=O((e,t,n=`-`,r)=>{r=Object.assign({fontSize:12,fontWeight:400,fontFamily:`Arial`,margin:0},r);let i=[...e],a=[],o=``;return i.forEach((e,s)=>{let c=`${o}${e}`;if(Y(c,r)>=t){let e=s+1,t=i.length===e,r=`${c}${n}`;a.push(t?c:r),o=``}else o=c}),{hyphenatedStrings:a,remainingWord:o}},(e,t,n=`-`,r)=>`${e}${t}${n}${r.fontSize}${r.fontWeight}${r.fontFamily}`);function J(e,t){return X(e,t).height}i(J,`calculateTextHeight`);function Y(e,t){return X(e,t).width}i(Y,`calculateTextWidth`);var X=O((e,t)=>{let{fontSize:n=12,fontFamily:i=`Arial`,fontWeight:a=400}=t;if(!e)return{width:0,height:0};let[,o]=Q(n),s=[`sans-serif`,i],c=e.split(l.lineBreakRegex),u=[],d=r(`body`);if(!d.remove)return{width:0,height:0,lineHeight:0};let f=d.append(`svg`);for(let e of s){let t=0,n={width:0,height:0,lineHeight:0};for(let r of c){let i=Ct();i.text=r||`​`;let s=wt(f,i).style(`font-size`,o).style(`font-weight`,a).style(`font-family`,e),c=(s._groups||s)[0][0].getBBox();if(c.width===0&&c.height===0)throw Error(`svg element not in render tree`);n.width=Math.round(Math.max(n.width,c.width)),t=Math.round(c.height),n.height+=t,n.lineHeight=Math.round(Math.max(n.lineHeight,t))}u.push(n)}return f.remove(),u[isNaN(u[1].height)||isNaN(u[1].width)||isNaN(u[1].lineHeight)||u[0].height>u[1].height&&u[0].width>u[1].width&&u[0].lineHeight>u[1].lineHeight?0:1]},(e,t)=>`${e}${t.fontSize}${t.fontWeight}${t.fontFamily}`),Dt=class{constructor(e=!1,t){this.count=0,this.count=t?t.length:0,this.next=e?()=>this.count++:()=>Date.now()}static{i(this,`InitIDGenerator`)}},Z,Ot=i(function(e){return Z||=document.createElement(`div`),e=escape(e).replace(/%26/g,`&`).replace(/%23/g,`#`).replace(/%3B/g,`;`),Z.innerHTML=e,unescape(Z.textContent)},`entityDecode`);function kt(e){return`str`in e}i(kt,`isDetailedError`);var At=i((e,t,n,r)=>{if(!r)return;let i=e.node()?.getBBox();i&&e.append(`text`).text(r).attr(`text-anchor`,`middle`).attr(`x`,i.x+i.width/2).attr(`y`,-n).attr(`class`,t)},`insertTitle`),Q=i(e=>{if(typeof e==`number`)return[e,e+`px`];let t=parseInt(e??``,10);return Number.isNaN(t)?[void 0,void 0]:e===String(t)?[t,e+`px`]:[t,e]},`parseFontSize`);function $(e,t){return De({},e,t)}i($,`cleanAndMerge`);var jt={assignWithDepth:c,wrapLabel:Tt,calculateTextHeight:J,calculateTextWidth:Y,calculateTextDimensions:X,cleanAndMerge:$,detectInit:ct,detectDirective:lt,isSubstringInArray:dt,interpolateToCurve:W,calcLabelPosition:ht,calcCardinalityPosition:_t,calcTerminalLabelPosition:vt,formatUrl:ft,getStylesFromArray:q,generateId:bt,random:St,runFunc:pt,entityDecode:Ot,insertTitle:At,isLabelCoordinateInPath:It,parseFontSize:Q,InitIDGenerator:Dt},Mt=i(function(e){let t=e;return t=t.replace(/style.*:\S*#.*;/g,function(e){return e.substring(0,e.length-1)}),t=t.replace(/classDef.*:\S*#.*;/g,function(e){return e.substring(0,e.length-1)}),t=t.replace(/#\w+;/g,function(e){let t=e.substring(1,e.length-1);return/^\+?\d+$/.test(t)?`fl°°`+t+`¶ß`:`fl°`+t+`¶ß`}),t},`encodeEntities`),Nt=i(function(e){return e.replace(/fl°°/g,`&#`).replace(/fl°/g,`&`).replace(/¶ß/g,`;`)},`decodeEntities`),Pt=i((e,t,{counter:n=0,prefix:r,suffix:i},a)=>a||`${r?`${r}_`:``}${e}_${t}_${n}${i?`_${i}`:``}`,`getEdgeId`);function Ft(e){return e??null}i(Ft,`handleUndefinedAttr`);function It(e,t){let n=Math.round(e.x),r=Math.round(e.y),i=t.replace(/(\d+\.\d+)/g,e=>Math.round(parseFloat(e)).toString());return i.includes(n.toString())||i.includes(r.toString())}i(It,`isLabelCoordinateInPath`);export{ue as $,E as A,me as B,Qe as C,j as D,ke as E,b as F,_ as G,fe as H,y as I,ne as J,m as K,h as L,ve as M,x as N,Oe as O,g as P,le as Q,oe as R,Ze as S,Ie as T,pe as U,he as V,de as W,p as X,v as Y,re as Z,Tt as _,Nt as a,nt as b,Pt as c,W as d,se as et,kt as f,jt as g,ut as h,$ as i,S as j,D as k,q as l,St as m,J as n,Mt as o,Q as p,ae as q,Y as r,bt as s,X as t,ce as tt,Ft as u,it as v,B as w,tt as x,rt as y,ie as z};