@marimo-team/islands 0.23.17-dev8 → 0.24.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 (643) hide show
  1. package/dist/{ConnectedDataExplorerComponent-f9vLjQiF.js → ConnectedDataExplorerComponent-BUC1MrsF.js} +24 -24
  2. package/dist/{ErrorBoundary-DhLqwSWA.js → ErrorBoundary-BniTEhHn.js} +7 -7
  3. package/dist/{ImageComparisonComponent-C3y7L3eJ.js → ImageComparisonComponent-B7b8DcJI.js} +42 -31
  4. package/dist/{Plot-YQOuVIei.js → Plot-eTseCFf_.js} +4 -4
  5. package/dist/_initCloneObject-DNUst5Cg.js +91 -0
  6. package/dist/abnfDiagram-N423BO3Z-DA4j92-C.js +112 -0
  7. package/dist/{any-language-editor-DifE-fl7.js → any-language-editor-LHl8ZmVN.js} +26 -26
  8. package/dist/apl-Cwo7GIH7.js +4 -0
  9. package/dist/{arc-CTIpFoOn.js → arc-9nABupDE.js} +2 -2
  10. package/dist/architecture-TIHT7OUA-DxLlkuAK.js +5 -0
  11. package/dist/{architectureDiagram-VXUJARFQ-DXwkyAaM.js → architectureDiagram-T3A2C74G-BBlBK1Oh.js} +327 -214
  12. package/dist/{arrays-sEtDRoG4.js → arrays-C56grfjL.js} +1 -1
  13. package/dist/asciiarmor-jrfEZ3j_.js +4 -0
  14. package/dist/asn1-BNEiJ4nQ.js +4 -0
  15. package/dist/assets/__vite-browser-external-DUz7vvG0.js +1 -0
  16. package/dist/assets/{worker-CDEKsBgX.js → worker-Cl1KJG2_.js} +2 -2
  17. package/dist/blockDiagram-VBNYF7ZC-Datz1WNn.js +3284 -0
  18. package/dist/brainfuck-BCunvTbd.js +4 -0
  19. package/dist/{button-BSm8IXRU.js → button-Dr2uAwhT.js} +9 -7
  20. package/dist/{c4Diagram-YG6GDRKO-B6dZC_oU.js → c4Diagram-5PPSVZJV-DTIsibpE.js} +165 -162
  21. package/dist/{capabilities-C6OQ5YBO.js → capabilities-BilXeZ7p.js} +2 -2
  22. package/dist/{channel-BN070S0F.js → channel-CuV_jmG4.js} +1 -1
  23. package/dist/chat-ui-o-tATfmW.js +8619 -0
  24. package/dist/{check-DP7U0H0G.js → check-58HHfHKy.js} +1 -1
  25. package/dist/chunk-2GRJ4B5K-DRayWnnu.js +68 -0
  26. package/dist/{chunk-QZHKN3VN-Dym5BS7y.js → chunk-2Q5K7J3B-BSLyFOHa.js} +1 -1
  27. package/dist/chunk-3NCLNEKW-BPlp8K7N.js +11 -0
  28. package/dist/chunk-4I5QYGJK-CYJC3pkC.js +260 -0
  29. package/dist/chunk-5FCAYU7R-C3cMIeyz.js +24 -0
  30. package/dist/{chunk-5FQGJX7Z-B9WoXK1R.js → chunk-5FQGJX7Z-BRZ_XYUw.js} +6 -6
  31. package/dist/chunk-5HE753X5-D2jFCVXb.js +34 -0
  32. package/dist/chunk-5JV3BV7I-B7tzprBU.js +50 -0
  33. package/dist/{chunk-DI55MBZ5-D4Y8yV8B.js → chunk-5RXB4S5H-DcCPfb0q.js} +373 -327
  34. package/dist/chunk-5TONJI2A-LRqbgPte.js +59 -0
  35. package/dist/{chunk-FMBD7UC4-quJmebXa.js → chunk-5VM5RSS4-ChXEBudA.js} +1 -1
  36. package/dist/chunk-6Q2QTUOP-zcnb3OaV.js +503 -0
  37. package/dist/{chunk-HN2XXSSU-Bv0QkeMr.js → chunk-7BUUIJ7U-CkIbJNZo.js} +32 -25
  38. package/dist/chunk-7Z6QIM7H-1j-x7ddW.js +606 -0
  39. package/dist/{chunk-FRFDVMJY-BHBqN-vD.js → chunk-BIQX33UG-B-BYk6sM.js} +3 -3
  40. package/dist/chunk-Bfp04NdC.js +25 -0
  41. package/dist/chunk-CQNSW5MT-DBXDKSOU.js +34 -0
  42. package/dist/{chunk-4F5CHEZ2-VlodlEGo.js → chunk-CYSBUYHQ-Cv-vKQV-.js} +1 -1
  43. package/dist/{chunk-SJTYNZTY-DnXoKWpW.js → chunk-EMLP6XTP-DCtMkXLF.js} +1 -1
  44. package/dist/{chunk-B4BG7PRW-B_z2FEHm.js → chunk-GF5L2VYU-esTxzELH.js} +878 -636
  45. package/dist/chunk-I66GZJ75-9xAsFrdW.js +3744 -0
  46. package/dist/chunk-J7OUQ5F2-CbNBTlFM.js +81 -0
  47. package/dist/chunk-JG7HCLWE-CZIm6axg.js +59 -0
  48. package/dist/{flowDiagram-NV44I4VS-BRhSg-ro.js → chunk-JQJVKLGR-ZALkKVji.js} +1019 -1001
  49. package/dist/{chunk-4BX2VUAB-iU5lQTDI.js → chunk-JWPE2WC7-C_Daz-Oc.js} +1 -1
  50. package/dist/{chunk-QN33PNHL-DPBNNzpR.js → chunk-KBJHAD2P-B7m9DztL.js} +3 -2
  51. package/dist/chunk-KEIR6QF5-aP6TmWQ-.js +21095 -0
  52. package/dist/{chunk-UMXZTB3W-D1uHz8MN.js → chunk-MOZMSUNE-BQi-ggQx.js} +7 -4
  53. package/dist/{chunk-S3R3BYOJ-BdgLc8AM.js → chunk-NSK5VX7P-BmmoJBbx.js} +320 -29
  54. package/dist/chunk-OSBZ3O6U-BcrmpSY_.js +22 -0
  55. package/dist/{chunk-TQ3KTPDO-CsDx6v37.js → chunk-QBLGF6JB-BACuPUWb.js} +3 -3
  56. package/dist/chunk-QR6OTTB3-C4L1dLRd.js +3762 -0
  57. package/dist/{chunk-B2363JML-zL3VngtH.js → chunk-R7FJI6CG-BYAXJpIb.js} +3 -3
  58. package/dist/chunk-RYQCIY6F-poA0Ugpr.js +243 -0
  59. package/dist/chunk-U6XO7XAA-I8tCjTeT.js +60 -0
  60. package/dist/chunk-UBXNYLIW-C8LueN5Q.js +34 -0
  61. package/dist/{chunk-ATLVNIR6-qFiszptQ.js → chunk-W5SLKNZC-DK-_KuKT.js} +2 -2
  62. package/dist/{chunk-JA3XYJ7Z-CY4CRbV5.js → chunk-WRU74C26-DLgw-V0j.js} +262 -451
  63. package/dist/chunk-XXDRQBXY-Dzcp3rUR.js +9 -0
  64. package/dist/chunk-Y2CYZVJY-DX3DSigL.js +13 -0
  65. package/dist/{chunk-PL6DKKU2-CAHKc95s.js → chunk-YOTPTUD7-C8qfgaz5.js} +5 -5
  66. package/dist/{chunk-MI3HLSF2-HGWI-8Pg.js → chunk-ZIRB5QZD-_JX1DzEJ.js} +12 -8
  67. package/dist/classDiagram-JCYQIIEL-D8A6ZyXv.js +32 -0
  68. package/dist/classDiagram-v2-OCEON4UE-DIdYl-t3.js +32 -0
  69. package/dist/{click-outside-container-BSIeYt4y.js → click-outside-container-BZNsAj09.js} +2 -2
  70. package/dist/{clike-7lgyEYRk.js → clike-CWndBX_M.js} +1 -1
  71. package/dist/clojure-2X0Rfij9.js +4 -0
  72. package/dist/cmake-DEwzCy9U.js +4 -0
  73. package/dist/cobol-Ck4eCoAB.js +4 -0
  74. package/dist/{code-block-37QAKDTI-MSxEjskJ.js → code-block-37QAKDTI-B4pWe5MI.js} +4 -4
  75. package/dist/coffeescript-bB1IDwhg.js +4 -0
  76. package/dist/{common-BLoQG6ym.js → common-DV4qU2ew.js} +797 -804
  77. package/dist/commonlisp-BDYrVBNC.js +4 -0
  78. package/dist/{compiler-runtime-CEbnTgxf.js → compiler-runtime-DsR6imPN.js} +2 -2
  79. package/dist/{copy-DNq8q3zw.js → copy-C7ZKMKox.js} +5 -5
  80. package/dist/{cose-bilkent-S5V4N54A-BYj0aL7z.js → cose-bilkent-JH36ORCC-D6iQzSi6.js} +6 -5
  81. package/dist/crystal-BSoiVUiH.js +4 -0
  82. package/dist/css-w1h9i21f.js +4 -0
  83. package/dist/cynefin-VYW2F7L2-DnZOHyNF.js +5 -0
  84. package/dist/cynefinDiagram-MW4NZA55-B1GNPS2u.js +367 -0
  85. package/dist/cypher-B4xzuKGP.js +4 -0
  86. package/dist/{cytoscape.esm-Dr8XzXWK.js → cytoscape.esm-BPa26Dup.js} +393 -334
  87. package/dist/d-D50Bz34p.js +4 -0
  88. package/dist/{dagre-By_QsQgc.js → dagre-ThTNj8pe.js} +60 -45
  89. package/dist/dagre-VZM6K2ZE-DEs5dfXA.js +343 -0
  90. package/dist/{data-grid-overlay-editor-BWRG2b_o.js → data-grid-overlay-editor-Ci7TXVf5.js} +5 -5
  91. package/dist/{debounce-BOD3DbfP.js → debounce-D784bpms.js} +2 -2
  92. package/dist/{defaultLocale-BpsHxBd7.js → defaultLocale-CMezyvMc.js} +26 -26
  93. package/dist/diagram-7IWD3JNH-Bdk1_wJO.js +321 -0
  94. package/dist/diagram-B4RE2ZJO-Be9eYLJ0.js +464 -0
  95. package/dist/{diagram-S2PKOQOG-CGh4OMEV.js → diagram-LBJQPF4R-BNSnzxFw.js} +26 -18
  96. package/dist/{diagram-PSM6KHXK-D4ftnaua.js → diagram-Q27KOJAE-NPRzyGtd.js} +68 -63
  97. package/dist/diagram-UB23O5K3-Dogz4itg.js +236 -0
  98. package/dist/diff-BMdzfXq-.js +4 -0
  99. package/dist/{dist-BTdrwBWP.js → dist-72nb8Uag.js} +3 -3
  100. package/dist/{dist-CV79CsQ0.js → dist-9PC5KxMl.js} +2 -2
  101. package/dist/{dist-BOMbzyb3.js → dist-Awj73yUw.js} +3 -3
  102. package/dist/{dist-w_gWE5Wf.js → dist-B0Ctcrt9.js} +1 -1
  103. package/dist/{dist-BO5HRiTf.js → dist-B1Donbpk.js} +2 -2
  104. package/dist/dist-BC6wzWNb.js +5 -0
  105. package/dist/{dist-De-GlSAs.js → dist-BJ2IUa0l.js} +15 -9
  106. package/dist/dist-BMd_RcOy.js +5 -0
  107. package/dist/dist-BZEWjN6r.js +5 -0
  108. package/dist/{dist-BP39XM8u.js → dist-B_K4AAkc.js} +1 -1
  109. package/dist/dist-BeuGjR3n.js +6 -0
  110. package/dist/dist-BfDQCUe6.js +5 -0
  111. package/dist/dist-BhNblTOV.js +8 -0
  112. package/dist/{dist-BPF0gTRZ.js → dist-C0ifRfXi.js} +1 -1
  113. package/dist/{dist-pqIwD8VD.js → dist-C3mEki35.js} +2 -2
  114. package/dist/{dist-LpLXa9Lb.js → dist-CNfV2vDI.js} +2 -2
  115. package/dist/{dist-DviUBLUp.js → dist-COcQ5Vyc.js} +4 -4
  116. package/dist/dist-CRCm4Fuo.js +5 -0
  117. package/dist/{dist-4lVIWUT3.js → dist-CSZpLb9d.js} +1 -1
  118. package/dist/{dist-BIEt-mlF.js → dist-CWswQBvu.js} +1 -1
  119. package/dist/{dist-D3bdsa1d.js → dist-CXYro_Nw.js} +4 -4
  120. package/dist/{dist-CRmSjkLP.js → dist-Ckfsc8C3.js} +2 -2
  121. package/dist/{dist-CSlJrrAw.js → dist-Cyq6Pxtv.js} +1 -1
  122. package/dist/{dist-JGehap7K.js → dist-D-BWPyoX.js} +5 -5
  123. package/dist/{dist-BCX980mU.js → dist-D-YB6j-O.js} +2 -2
  124. package/dist/{dist-DgjbnqTg.js → dist-D1vYHETp.js} +2 -2
  125. package/dist/{dist-BpeiYpG2.js → dist-D9-ePb6D.js} +2 -2
  126. package/dist/dist-DBPEbGkd.js +8 -0
  127. package/dist/{dist-C2_4pjuS.js → dist-DC409ROm.js} +1 -1
  128. package/dist/{dist-BdqCKQ1O.js → dist-DJRUd9aM.js} +2 -2
  129. package/dist/{dist-DaXJPX8F.js → dist-DLvxZEAK.js} +2 -2
  130. package/dist/dist-DSsl8IAI.js +5 -0
  131. package/dist/{dist-3NCqaWjt.js → dist-D_ulymry.js} +2 -2
  132. package/dist/{dist-DZwp8lro.js → dist-DgY27bJ4.js} +3 -3
  133. package/dist/{dist-BwhXBwMd.js → dist-DiwVZiK7.js} +1 -1
  134. package/dist/{dist-DwqBJ014.js → dist-DnYHhW6c.js} +2 -2
  135. package/dist/dist-Dx0kkrek.js +5 -0
  136. package/dist/{dist-DsoKosxi.js → dist-HaLHv0k5.js} +2 -3
  137. package/dist/dist-NKA1TU8a.js +6 -0
  138. package/dist/dist-ZFcsIdHj.js +8 -0
  139. package/dist/{dist-C18MUWTj.js → dist-iZ8-rtUy.js} +2 -2
  140. package/dist/{dist-DIlxLFXG.js → dist-j30bBjjN.js} +15 -15
  141. package/dist/{dist-SXNmlE8A.js → dist-kOCFEa1U.js} +3 -3
  142. package/dist/{dist-CFSb_Frm.js → dist-sxRUVPmt.js} +1 -1
  143. package/dist/dist-uA2RbGmY.js +5 -0
  144. package/dist/{dist-B2jmQKKx.js → dist-xVU82Nq7.js} +2 -2
  145. package/dist/dist-zSCo-xCB.js +8 -0
  146. package/dist/{dockerfile-B82Pkz_V.js → dockerfile-DImRFUlA.js} +1 -1
  147. package/dist/dtd-B9dCT0pu.js +4 -0
  148. package/dist/dylan-DLghDyuR.js +4 -0
  149. package/dist/ebnfDiagram-BXEA7PRR-CqRWkG7L.js +129 -0
  150. package/dist/ecl-w0qdPHDB.js +4 -0
  151. package/dist/eiffel-C5AWRCNP.js +4 -0
  152. package/dist/elm-CT8FZrOm.js +4 -0
  153. package/dist/{erDiagram-Q2GNP2WA-BcKAHFqF.js → erDiagram-JOGREHBK-BZMJX-Au.js} +568 -436
  154. package/dist/erlang-DPD-9M5g.js +4 -0
  155. package/dist/{error-banner-B_GQfxxD.js → error-banner-BwCLtmkH.js} +6 -6
  156. package/dist/{esm-CuQHjs36.js → esm-BJ4n0NUT.js} +1 -1
  157. package/dist/{esm-DKOv6P2M.js → esm-Dusmf6uu.js} +105 -105
  158. package/dist/{esm-DzZVaNH4.js → esm-QLUgkqzZ.js} +6 -6
  159. package/dist/eventmodeling-45OFAUF4-D8Kbnsr6.js +5 -0
  160. package/dist/{extends-w2_S44bV.js → extends-iFBneQO_.js} +9 -9
  161. package/dist/{factor-Bq2mGIHt.js → factor-BonZgUGg.js} +1 -1
  162. package/dist/factor-rFfeJu3r.js +4 -0
  163. package/dist/flowDiagram-UKHOOZJN-DqIE8_b3.js +21 -0
  164. package/dist/{formats-Dwq1THhr.js → formats-HSfYlcA8.js} +7 -7
  165. package/dist/forth-C-3AyQx4.js +4 -0
  166. package/dist/fortran-BSN9TeT7.js +4 -0
  167. package/dist/ganttDiagram-PKOTCBZU-Bc9puoXb.js +2207 -0
  168. package/dist/gas-DwmuvQpB.js +4 -0
  169. package/dist/gherkin-gmCjL-Sn.js +4 -0
  170. package/dist/{gitGraph-G5XIXVHT-BjTx0kww.js → gitGraph-TEB2WS4Q-DVzLmQHc.js} +2 -3
  171. package/dist/gitGraphDiagram-DS77QQ5N-CqKr-Dfg.js +766 -0
  172. package/dist/{glide-data-editor-B9K6-MJe.js → glide-data-editor-BI2i_IEE.js} +18 -18
  173. package/dist/graphlib-DMVIRZap.js +614 -0
  174. package/dist/groovy-DCjvesOy.js +4 -0
  175. package/dist/hasIn-synBnXn4.js +119 -0
  176. package/dist/haskell-C1p0D9L8.js +4 -0
  177. package/dist/haxe-q-fgv0zr.js +5 -0
  178. package/dist/{html-to-image-CZ1kLKkq.js → html-to-image-BOiFHx3u.js} +7535 -3056
  179. package/dist/idl-Bmg4bsnK.js +4 -0
  180. package/dist/{info-VBDWY6EO-CA67FznA.js → info-DKCQHKI2-BxOTqQHM.js} +2 -3
  181. package/dist/infoDiagram-6WML65LV-B869X2KY.js +37 -0
  182. package/dist/{input-C5K4VBvB.js → input-BRE2a7Ay.js} +13 -13
  183. package/dist/{_baseFor-4jw-lnCC.js → isArrayLikeObject-CBUaLibE.js} +96 -29
  184. package/dist/{isEmpty-CJJMn-QP.js → isEmpty-CgME6WRV.js} +15 -15
  185. package/dist/{isSymbol-CoUCgMCM.js → isSymbol-Ch3GYg4S.js} +1 -1
  186. package/dist/ishikawaDiagram-WSZJBQD7-BrOMFBYy.js +731 -0
  187. package/dist/javascript-BY5QZ-eN.js +4 -0
  188. package/dist/{journeyDiagram-XKPGCS4Q-DEal0aT1.js → journeyDiagram-NVQOT4AX-CTwHlsTm.js} +124 -123
  189. package/dist/{jsx-runtime-DebpN0FN.js → jsx-runtime-Dp_oQwaf.js} +1 -1
  190. package/dist/julia-DbR1YalK.js +4 -0
  191. package/dist/{kanban-definition-3W4ZIXB7-Dl90wENN.js → kanban-definition-27J2QSJJ-CKowzO9_.js} +51 -45
  192. package/dist/{katex-C4t-BmrK.js → katex-Ci33kJVq.js} +1 -1
  193. package/dist/{katex-Bld7b-fk.js → katex-Dp22h6yO.js} +2871 -3002
  194. package/dist/{label-DjoYwqmj.js → label-CMh2d8pJ.js} +6 -6
  195. package/dist/{line-C43FIPBd.js → line-Bc27KE1D.js} +3 -3
  196. package/dist/{linear-H_vsH9ao.js → linear-6pDlrp1I.js} +4 -4
  197. package/dist/livescript-BDUooIeL.js +4 -0
  198. package/dist/{loader-DX-IDS7n.js → loader-DTnbNSVZ.js} +11 -11
  199. package/dist/lua-CswAWSkH.js +4 -0
  200. package/dist/main.js +747 -752
  201. package/dist/map-BQ_Xp80D.js +137 -0
  202. package/dist/mathematica-Bw7v11B5.js +4 -0
  203. package/dist/mbox-j35IMz1j.js +4 -0
  204. package/dist/merge-CDbSrd9f.js +69 -0
  205. package/dist/mermaid-4DMBBIKO-BZSpTmcx.js +6 -0
  206. package/dist/mermaid-DpAz2sTy.js +1265 -0
  207. package/dist/mermaid-parser.core-BQzz3_BI.js +87 -0
  208. package/dist/{mhchem-EGhUZR1V.js → mhchem-BDHjke3h.js} +1 -1
  209. package/dist/{micromark-factory-space-CwHmg6iz.js → micromark-factory-space-Cr4NxAt3.js} +1 -1
  210. package/dist/{mindmap-definition-VGOIOE7T-CCDupjWW.js → mindmap-definition-FAOFIHXS-CTsi-HFj.js} +126 -80
  211. package/dist/mirc-Ba_RHVXO.js +4 -0
  212. package/dist/mllike-DbTP2dPp.js +6 -0
  213. package/dist/modelica-lpT3V1X6.js +4 -0
  214. package/dist/mscgen-BN4ZSJMx.js +6 -0
  215. package/dist/mumps-uI5g1A0g.js +4 -0
  216. package/dist/{node-sql-parser-v1Vi-Fft.js → node-sql-parser-BaLGWQe1.js} +1 -1
  217. package/dist/{now-Ch98bJO_.js → now-sFWt-GLC.js} +2 -2
  218. package/dist/{nsis-i9_sgigf.js → nsis-C68fFq_o.js} +1 -1
  219. package/dist/nsis-Df56GiRg.js +4 -0
  220. package/dist/ntriples-B3LWuG7W.js +4 -0
  221. package/dist/{number-overlay-editor-Ck_mc_gT.js → number-overlay-editor-CeBHRJvI.js} +3 -3
  222. package/dist/octave-CovfQgOx.js +4 -0
  223. package/dist/{once-B60G2fuJ.js → once-Boutk_9X.js} +1 -1
  224. package/dist/{ordinal-Bkv2-veX.js → ordinal-Bdajf2BE.js} +1 -1
  225. package/dist/oz-DQQAvVFb.js +4 -0
  226. package/dist/{packet-DYOGHKS2-Bkgofxf3.js → packet-7NZHBO7P-BG8whXXH.js} +2 -3
  227. package/dist/pascal-xz94P9sf.js +4 -0
  228. package/dist/pegDiagram-VL7TDLO6-CNpT8Sqz.js +124 -0
  229. package/dist/perl-aEWKE-1n.js +4 -0
  230. package/dist/pick-CaEWivSF.js +47 -0
  231. package/dist/{pie-VRWISCQL-B1AMhN_7.js → pie-RZYD4A2V-Cc_QhFbT.js} +2 -3
  232. package/dist/pieDiagram-7S7Q4E2Y-Ct8jRpe_.js +219 -0
  233. package/dist/pig-DB6DOZl7.js +4 -0
  234. package/dist/powershell-DM5saUx1.js +4 -0
  235. package/dist/{precisionRound-CnHPY_5v.js → precisionRound-BOoJTbDj.js} +1 -1
  236. package/dist/{process-output-bVfbcx5_.js → process-output-HrsM52f8.js} +7 -7
  237. package/dist/properties-BGjYQuGo.js +4 -0
  238. package/dist/protobuf-BPpEyPud.js +4 -0
  239. package/dist/{pug-BhE2JRSg.js → pug-DFPPZ3LA.js} +1 -1
  240. package/dist/pug-uJzB88ft.js +4 -0
  241. package/dist/puppet-oIm2d_Lg.js +4 -0
  242. package/dist/{purify.es-EnR5yhgI.js → purify.es-DR5PNXwx.js} +160 -155
  243. package/dist/python-WE57eUzD.js +4 -0
  244. package/dist/q-CR8xPodo.js +4 -0
  245. package/dist/{quadrantDiagram-AYHSOK5B-BqDB9tUC.js → quadrantDiagram-CIZ2JOQS-B5n_xFcF.js} +429 -401
  246. package/dist/r-CJdmQZNj.js +4 -0
  247. package/dist/{radar-ZZBFDIW7-C2b7A32s.js → radar-I7S5WNFK-OhUkecXA.js} +2 -3
  248. package/dist/railroad-3IZDKUUU-1CmOpo1B.js +5 -0
  249. package/dist/railroad-abnf-AHOZXSZD-DmH4lsDS.js +5 -0
  250. package/dist/railroad-ebnf-EBAXGLYW-CzK0md4e.js +5 -0
  251. package/dist/railroad-peg-LSFZ7HO6-DOklooKz.js +5 -0
  252. package/dist/railroadDiagram-AXF67PYL-BbUWbtf8.js +100 -0
  253. package/dist/{react-DA-nE2FX.js → react-DhGsCS90.js} +1 -1
  254. package/dist/{react-dom-BTJzcVJ9.js → react-dom-CmENFV8Q.js} +2 -2
  255. package/dist/{react-vega-BazDALhI.js → react-vega-zyfTF9SY.js} +8036 -4796
  256. package/dist/{requirementDiagram-UZGBJVZJ-KbVt8SPH.js → requirementDiagram-LRYGKXZP-CpoDmKSf.js} +137 -105
  257. package/dist/{reveal-component-BejXPHja.js → reveal-component-CYZAzXrV.js} +27 -28
  258. package/dist/rough.esm-lGyFQ0B-.js +1363 -0
  259. package/dist/rpm-Cm5K4RH9.js +5 -0
  260. package/dist/ruby-ArsuTozQ.js +4 -0
  261. package/dist/sankeyDiagram-W5VNT64P-D82rYiAG.js +942 -0
  262. package/dist/sas-DShligrE.js +4 -0
  263. package/dist/scheme-kDLirQL7.js +4 -0
  264. package/dist/sequenceDiagram-SI44F4Z6-DgVKU1s5.js +4281 -0
  265. package/dist/shell-CVQuWP_N.js +4 -0
  266. package/dist/sieve-BW-ePwnq.js +4 -0
  267. package/dist/sizeCapture-X5ZJPWSS-BQgxHTji.js +48 -0
  268. package/dist/smalltalk-DI4aAXxY.js +4 -0
  269. package/dist/sparql-B2sp0oiz.js +4 -0
  270. package/dist/{spec-CQKL_D3i.js → spec-BL1GSUUF.js} +4 -4
  271. package/dist/{src-DV3ha_nA.js → src-BwVZVGyf.js} +13 -22
  272. package/dist/{stateDiagram-FKZM4ZOC-ByOvQf2n.js → stateDiagram-OKZ733FA-Cc9BchXz.js} +61 -58
  273. package/dist/stateDiagram-v2-UEYNNEHI-Dd4Tuw6F.js +32 -0
  274. package/dist/{step-BqHnkgWE.js → step-BqVgkWtk.js} +1 -1
  275. package/dist/stex-D2rme5UG.js +4 -0
  276. package/dist/{strings-DIy9NAmg.js → strings-DMLVGXRo.js} +305 -305
  277. package/dist/style.css +1 -1
  278. package/dist/stylus-xxO-85eO.js +4 -0
  279. package/dist/swift-Ctg533nZ.js +4 -0
  280. package/dist/swimlanes-SLNWSIFB-BHvhO5uv.js +5564 -0
  281. package/dist/swimlanesDiagram-ULZ7WXOC-aI_zgQ8O.js +33 -0
  282. package/dist/{swiper-component-CEdAYjb7.js → swiper-component-Cx0cRWLk.js} +6 -6
  283. package/dist/tcl-phm9c5Nd.js +4 -0
  284. package/dist/textile-CphjAg90.js +4 -0
  285. package/dist/{time-Bb4A7I6a.js → time-DAJu9fnj.js} +4 -4
  286. package/dist/timeline-definition-Z64GVDOM-BAHuDYyA.js +1107 -0
  287. package/dist/{timer-BpI_FKSA.js → timer-aIIabkbI.js} +1 -1
  288. package/dist/{toDate-CqhBWjvO.js → toDate-BGM7kFtQ.js} +6 -6
  289. package/dist/toml-BUuMK772.js +4 -0
  290. package/dist/{tooltip-f-qR0iUx.js → tooltip-BtUxZT5h.js} +7 -7
  291. package/dist/treeView-QDETBFTQ-DsLN_c8p.js +5 -0
  292. package/dist/{treemap-GDKQZRPO-SDux0AV8.js → treemap-6X3UGDF4-K1bi3LJm.js} +2 -3
  293. package/dist/troff-lCtc05A3.js +4 -0
  294. package/dist/ttcn-CcykzBcW.js +4 -0
  295. package/dist/ttcn-cfg-C-XYdqpE.js +4 -0
  296. package/dist/turtle-CpfVZs8G.js +4 -0
  297. package/dist/{types-DicH9Oi0.js → types-DT8UHI5w.js} +1 -1
  298. package/dist/{use-vega-container-remeasure-DGNrIQSk.js → use-vega-container-remeasure-B7OD7yUY.js} +3 -3
  299. package/dist/{useAsyncData-CYOQb1EW.js → useAsyncData-CDcbh-Qv.js} +5 -5
  300. package/dist/{useDateFormatter-Bt2qr_XS.js → useDateFormatter-B_vTzxpm.js} +4 -4
  301. package/dist/{useDeepCompareMemoize-CSHQeQEI.js → useDeepCompareMemoize-Bj6QvwiG.js} +3 -3
  302. package/dist/{useIframeCapabilities-kA09ykNq.js → useIframeCapabilities-CxuXXwjj.js} +4 -4
  303. package/dist/{useLifecycle-CMJGqBaY.js → useLifecycle-Bw4wRj_O.js} +7 -7
  304. package/dist/{useTheme-DYfby65G.js → useTheme-BzEXeAR5.js} +8 -7
  305. package/dist/vb-VOIzXwm9.js +4 -0
  306. package/dist/vbscript-D0WfcnVk.js +4 -0
  307. package/dist/{vega-component-C7nO5zcf.js → vega-component-CJug-VdR.js} +24 -24
  308. package/dist/{vega-embed-container-DAQAMjiO.js → vega-embed-container-BRjjqRGz.js} +9 -9
  309. package/dist/{vega-loader.browser-DmpxCJqx.js → vega-loader.browser-CGb-2Kwi.js} +106 -113
  310. package/dist/velocity-CCrc5n-0.js +4 -0
  311. package/dist/vennDiagram-T6HMQDX7-CTyzMewS.js +1913 -0
  312. package/dist/verilog-BLFhaDBH.js +4 -0
  313. package/dist/vhdl-DjuqPE9b.js +4 -0
  314. package/dist/wardley-OPB4EBWU-CP99MvU1.js +5 -0
  315. package/dist/wardleyDiagram-T6FBY63Y-vcno_rbk.js +669 -0
  316. package/dist/webidl-Cc7RrfeK.js +4 -0
  317. package/dist/xquery-BiCRLnNG.js +4 -0
  318. package/dist/{xychartDiagram-PRI3JC2R-BSkNxYNw.js → xychartDiagram-ELKLHX3M-DyFDERhM.js} +417 -353
  319. package/dist/yacas-CWcjav-O.js +4 -0
  320. package/dist/z80-DpYS2lE7.js +4 -0
  321. package/dist/{zod-BUcyXSdR.js → zod-BFY2SnzC.js} +42 -43
  322. package/package.json +7 -7
  323. package/src/__mocks__/requests.ts +5 -0
  324. package/src/components/ai/ai-model-dropdown.tsx +2 -2
  325. package/src/components/app-config/user-config-form.tsx +26 -0
  326. package/src/components/chat/__tests__/capabilities-popover.test.tsx +38 -0
  327. package/src/components/chat/__tests__/chat-abort.test.ts +51 -0
  328. package/src/components/chat/__tests__/use-chat-controller-id.test.tsx +39 -0
  329. package/src/components/chat/capabilities-popover.tsx +68 -0
  330. package/src/components/chat/chat-abort.ts +44 -0
  331. package/src/components/chat/chat-display.tsx +17 -0
  332. package/src/components/chat/chat-panel.tsx +107 -50
  333. package/src/components/chat/chat-utils.ts +1 -1
  334. package/src/components/chat/use-chat-controller-id.ts +24 -0
  335. package/src/components/data-table/charts/__tests__/schemas.test.ts +35 -0
  336. package/src/components/data-table/charts/schemas.ts +5 -2
  337. package/src/components/databases/icons/huggingface.svg +8 -0
  338. package/src/components/datasets/__tests__/icons.test.ts +21 -0
  339. package/src/components/datasets/icons.tsx +10 -0
  340. package/src/components/datasources/__tests__/components.test.tsx +29 -0
  341. package/src/components/datasources/components.tsx +8 -3
  342. package/src/components/editor/actions/export-dialog/__tests__/export-dialog.test.tsx +35 -0
  343. package/src/components/editor/actions/export-dialog/__tests__/state.test.ts +61 -0
  344. package/src/components/editor/actions/export-dialog/export-command.ts +4 -9
  345. package/src/components/editor/actions/export-dialog/format-notice.tsx +28 -0
  346. package/src/components/editor/actions/export-dialog/state.ts +23 -5
  347. package/src/components/editor/actions/export-dialog/use-export-dialog.ts +3 -13
  348. package/src/components/editor/actions/useConfigActions.tsx +24 -0
  349. package/src/components/editor/ai/add-cell-with-ai.tsx +2 -2
  350. package/src/components/editor/ai/ai-completion-editor.tsx +2 -2
  351. package/src/components/editor/chrome/panels/outline/__tests__/useActiveOutline.test.ts +26 -0
  352. package/src/components/editor/chrome/wrapper/useOpenAiAssistant.ts +2 -2
  353. package/src/components/editor/code/__tests__/readonly-python-code.test.tsx +114 -2
  354. package/src/components/editor/connections/storage/__tests__/__snapshots__/as-code.test.ts.snap +14 -0
  355. package/src/components/editor/connections/storage/__tests__/as-code.test.ts +20 -0
  356. package/src/components/editor/connections/storage/add-storage-form.tsx +10 -0
  357. package/src/components/editor/connections/storage/as-code.ts +19 -1
  358. package/src/components/editor/connections/storage/schemas.ts +19 -0
  359. package/src/components/storage/__tests__/storage-snippets.test.ts +88 -0
  360. package/src/components/storage/components.tsx +2 -0
  361. package/src/components/storage/storage-snippets.ts +58 -0
  362. package/src/core/__tests__/mode.test.ts +85 -0
  363. package/src/core/ai/__tests__/config.test.tsx +96 -0
  364. package/src/core/ai/config.ts +16 -22
  365. package/src/core/ai/constants.ts +7 -0
  366. package/src/core/ai/staged-cells.ts +3 -0
  367. package/src/core/ai/state.ts +10 -0
  368. package/src/core/codemirror/__tests__/setup.test.ts +1 -1
  369. package/src/core/codemirror/cm.ts +2 -2
  370. package/src/core/codemirror/code-lens/__tests__/extension.test.ts +85 -6
  371. package/src/core/codemirror/code-lens/extension.ts +144 -47
  372. package/src/core/codemirror/find-replace/search-highlight.ts +8 -3
  373. package/src/core/codemirror/language/languages/sql/__tests__/renderers.test.tsx +44 -0
  374. package/src/core/codemirror/language/languages/sql/renderers.tsx +3 -3
  375. package/src/core/codemirror/theme/__tests__/light.test.ts +59 -123
  376. package/src/core/codemirror/theme/dark.ts +6 -5
  377. package/src/core/codemirror/theme/light.ts +6 -4
  378. package/src/core/config/__tests__/config-schema.test.ts +2 -0
  379. package/src/core/config/config-schema.ts +1 -0
  380. package/src/core/config/feature-flag.tsx +0 -2
  381. package/src/core/dom/outline.ts +25 -2
  382. package/src/core/hotkeys/hotkeys.ts +2 -0
  383. package/src/core/mode.ts +11 -9
  384. package/src/core/network/__tests__/api.test.ts +132 -17
  385. package/src/core/network/__tests__/export-filename.test.ts +43 -0
  386. package/src/core/network/__tests__/requests-lazy.test.ts +1 -0
  387. package/src/core/network/api.ts +47 -12
  388. package/src/core/network/export-filename.ts +37 -0
  389. package/src/core/network/markdown-export.ts +19 -0
  390. package/src/core/network/requests-network.ts +29 -5
  391. package/src/core/network/types.ts +4 -0
  392. package/src/core/storage/types.ts +1 -0
  393. package/src/css/app/codemirror.css +11 -7
  394. package/src/css/globals.css +8 -0
  395. package/src/plugins/impl/DataEditorPlugin.tsx +2 -9
  396. package/src/plugins/impl/__tests__/DataEditorPlugin.test.ts +18 -0
  397. package/src/plugins/impl/chat/chat-ui.tsx +51 -3
  398. package/src/plugins/impl/data-frames/__tests__/schema.test.ts +30 -0
  399. package/src/plugins/impl/data-frames/schema.ts +4 -1
  400. package/src/plugins/impl/image-comparison/ImageComparisonComponent.tsx +20 -1
  401. package/src/plugins/impl/image-comparison/__tests__/ImageComparisonComponent.test.tsx +58 -0
  402. package/src/stories/theme.stories.tsx +71 -1
  403. package/dist/_baseUniq-B_2Hw7zG.js +0 -380
  404. package/dist/apl-e1B5LPEL.js +0 -4
  405. package/dist/architecture-7HQA4BMR-DHUrQjL4.js +0 -6
  406. package/dist/asciiarmor-B-gwgesP.js +0 -4
  407. package/dist/asn1-DF2ckRB4.js +0 -4
  408. package/dist/assets/__vite-browser-external-DltVXDv7.js +0 -1
  409. package/dist/blockDiagram-VD42YOAC-CIOjvxeD.js +0 -3131
  410. package/dist/brainfuck-4G-7_gq_.js +0 -4
  411. package/dist/chat-ui-DsZJj75A.js +0 -8369
  412. package/dist/chunk-55IACEB6-7h71GwyW.js +0 -8
  413. package/dist/chunk-ABZYJK2D-BxBDji1u.js +0 -2438
  414. package/dist/chunk-BNovOVIE.js +0 -28
  415. package/dist/chunk-CVBHYZKI-CwazXVlJ.js +0 -13
  416. package/dist/chunk-DR5Q36YT-5Yp2GWwR.js +0 -137
  417. package/dist/chunk-EXTU4WIE-BQPBhApE.js +0 -10
  418. package/dist/chunk-JZLCHNYA-DWIR9m5O.js +0 -4901
  419. package/dist/chunk-N4CR4FBY-Bw2HcMNc.js +0 -65
  420. package/dist/chunk-QXUST7PY-DtC2t9Mk.js +0 -498
  421. package/dist/chunk-TCCFYFTB-DPWJa9zL.js +0 -13948
  422. package/dist/chunk-TZMSLE5B-BzSHcq-K.js +0 -63
  423. package/dist/classDiagram-2ON5EDUG-BiQPjMNY.js +0 -30
  424. package/dist/classDiagram-v2-WZHVMYZB-YHdR8fqM.js +0 -30
  425. package/dist/clojure-CUybM11R.js +0 -4
  426. package/dist/clone-Q4Fqwn6q.js +0 -9
  427. package/dist/cmake-BPjGcuDL.js +0 -4
  428. package/dist/cobol-BETk_nb6.js +0 -4
  429. package/dist/coffeescript-CManZxXL.js +0 -4
  430. package/dist/commonlisp-DWkn7GW8.js +0 -4
  431. package/dist/crystal-CCbg5EUH.js +0 -4
  432. package/dist/css-By8eo-XS.js +0 -4
  433. package/dist/cypher-DwfHg3nP.js +0 -4
  434. package/dist/d-Brs1wNbw.js +0 -4
  435. package/dist/dagre-6UL2VRFP-DpYjBqQs.js +0 -296
  436. package/dist/diagram-QEK2KX5R-DVlUOgs1.js +0 -228
  437. package/dist/diff-DJIRmJ1g.js +0 -4
  438. package/dist/dist-5o9uz19x.js +0 -5
  439. package/dist/dist-BpDH0DEP.js +0 -5
  440. package/dist/dist-BpXhbQXO.js +0 -8
  441. package/dist/dist-ByadAk_L.js +0 -5
  442. package/dist/dist-CK0g7JvP.js +0 -8
  443. package/dist/dist-CfzCtiq2.js +0 -5
  444. package/dist/dist-D8JtVFrW.js +0 -8
  445. package/dist/dist-DK2Oocpu.js +0 -6
  446. package/dist/dist-DnSu977r.js +0 -5
  447. package/dist/dist-UmxJm6sW.js +0 -8
  448. package/dist/dist-aYSBQSyM.js +0 -5
  449. package/dist/dist-kkZ1Ztlh.js +0 -6
  450. package/dist/dist-ngPczwNi.js +0 -5
  451. package/dist/dist-wQRyxyTV.js +0 -5
  452. package/dist/dtd-Dyiazv4N.js +0 -4
  453. package/dist/dylan-D8Fcw7NA.js +0 -4
  454. package/dist/ecl-CjKp8Vii.js +0 -4
  455. package/dist/eiffel-K9ViOX5r.js +0 -4
  456. package/dist/elm-B5NVtRco.js +0 -4
  457. package/dist/erlang-BnLzgk7R.js +0 -4
  458. package/dist/factor-C7f9Jz5R.js +0 -4
  459. package/dist/flatten-Bbw7g6-K.js +0 -8
  460. package/dist/forth-rGM8jLao.js +0 -4
  461. package/dist/fortran-B3acSe0i.js +0 -4
  462. package/dist/ganttDiagram-JELNMOA3-CXXCN7LN.js +0 -2170
  463. package/dist/gas-Bb1Vmv_N.js +0 -4
  464. package/dist/gherkin-C9Lyidgd.js +0 -4
  465. package/dist/gitGraphDiagram-V2S2FVAM-BOlkMSqK.js +0 -652
  466. package/dist/graphlib-Ns7y5crs.js +0 -359
  467. package/dist/groovy-DQk6XcGH.js +0 -4
  468. package/dist/hasIn-Deg7jl_j.js +0 -108
  469. package/dist/haskell-mV0Vw9gv.js +0 -4
  470. package/dist/haxe-DqxN89zH.js +0 -5
  471. package/dist/idl-ya8W561J.js +0 -4
  472. package/dist/infoDiagram-HS3SLOUP-D3TyKnL_.js +0 -30
  473. package/dist/javascript-CgqgptVu.js +0 -4
  474. package/dist/julia-CFQ-HusI.js +0 -4
  475. package/dist/livescript-D__3TmDo.js +0 -4
  476. package/dist/lua-Bytcgj_W.js +0 -4
  477. package/dist/main-B1Jo_8pC.js +0 -4321
  478. package/dist/mathematica-DJhvVKvl.js +0 -4
  479. package/dist/mbox-IGHPCjfR.js +0 -4
  480. package/dist/memoize-BOtf2yFf.js +0 -17
  481. package/dist/merge-Be1CqGnU.js +0 -222
  482. package/dist/mermaid-4DMBBIKO-FXbOziy9.js +0 -6
  483. package/dist/mermaid-hv6IckVw.js +0 -1100
  484. package/dist/mermaid-parser.core-DoivvxPd.js +0 -54
  485. package/dist/min-Dtgc8txR.js +0 -38
  486. package/dist/mirc-tcwvVugm.js +0 -4
  487. package/dist/mllike-Dx91i62r.js +0 -6
  488. package/dist/modelica-_SRt-yU5.js +0 -4
  489. package/dist/mscgen-GZrGS9gt.js +0 -6
  490. package/dist/mumps-Cv3ygyod.js +0 -4
  491. package/dist/nsis-BU7GeGbI.js +0 -4
  492. package/dist/ntriples-CL-FCYXb.js +0 -4
  493. package/dist/octave-Dc6_3DIu.js +0 -4
  494. package/dist/oz-DpUAJCXf.js +0 -4
  495. package/dist/pascal-B17mncXs.js +0 -4
  496. package/dist/perl-BTpK97q9.js +0 -4
  497. package/dist/pick-D1Qo8s2C.js +0 -43
  498. package/dist/pieDiagram-ADFJNKIX-JvXG_6hk.js +0 -170
  499. package/dist/pig-CFb638Ap.js +0 -4
  500. package/dist/powershell-Cxo-_2A5.js +0 -4
  501. package/dist/properties-BPgT1xTB.js +0 -4
  502. package/dist/protobuf-BgHBaIIK.js +0 -4
  503. package/dist/pug-25-oS0SG.js +0 -4
  504. package/dist/puppet-DarIr20S.js +0 -4
  505. package/dist/python-BqmOsBsi.js +0 -4
  506. package/dist/q-D3QJCTup.js +0 -4
  507. package/dist/r-Cz_yBX4z.js +0 -4
  508. package/dist/rpm-DGOtYwAI.js +0 -5
  509. package/dist/ruby-DBZu4rPc.js +0 -4
  510. package/dist/sankeyDiagram-TZEHDZUN-DgkF38jx.js +0 -892
  511. package/dist/sas-Dd1D9qTq.js +0 -4
  512. package/dist/scheme-BmDjvTHX.js +0 -4
  513. package/dist/sequenceDiagram-WL72ISMW-BDmx9n95.js +0 -3652
  514. package/dist/shell-BL8zFSaj.js +0 -4
  515. package/dist/sieve-BAx2WqUP.js +0 -4
  516. package/dist/smalltalk-CYRzF7VV.js +0 -4
  517. package/dist/sparql-YWaDRO4A.js +0 -4
  518. package/dist/stateDiagram-v2-4FDKWEC3-C3xqeavR.js +0 -29
  519. package/dist/stex-B5O-env2.js +0 -4
  520. package/dist/stylus-lYsyLFc1.js +0 -4
  521. package/dist/swift-ClQz9z1n.js +0 -4
  522. package/dist/tcl-B3jhsfqY.js +0 -4
  523. package/dist/textile-Cb1Dw7Aq.js +0 -4
  524. package/dist/timeline-definition-IT6M3QCI-CkD_trIn.js +0 -856
  525. package/dist/toml-nHZhetdO.js +0 -4
  526. package/dist/troff-DuJAGWKH.js +0 -4
  527. package/dist/ttcn-BxrcwP21.js +0 -4
  528. package/dist/ttcn-cfg-BAg_9dcc.js +0 -4
  529. package/dist/turtle-zCq949as.js +0 -4
  530. package/dist/vb-De5hElus.js +0 -4
  531. package/dist/vbscript-Cypcpv4F.js +0 -4
  532. package/dist/velocity-Di7l-yhe.js +0 -4
  533. package/dist/verilog-Bzi-S3g2.js +0 -4
  534. package/dist/vhdl-B0ZZITaW.js +0 -4
  535. package/dist/webidl-0sviiRcN.js +0 -4
  536. package/dist/xquery-B4qMVWaB.js +0 -4
  537. package/dist/yacas-Jt25Fuv8.js +0 -4
  538. package/dist/z80-CrcbYzmp.js +0 -4
  539. /package/dist/{apl-99A7dLQe.js → apl-CMUKiT2b.js} +0 -0
  540. /package/dist/{array-O78LT16Y.js → array-CEIRxyh3.js} +0 -0
  541. /package/dist/{asciiarmor-DLEhpFDx.js → asciiarmor-C_r6K6db.js} +0 -0
  542. /package/dist/{asn1-CMrcTsT4.js → asn1-DnlnCQTu.js} +0 -0
  543. /package/dist/{asterisk-CqykImq7.js → asterisk-DaVJJDnV.js} +0 -0
  544. /package/dist/{brainfuck-ChPt5yBe.js → brainfuck-CtQoQVkV.js} +0 -0
  545. /package/dist/{clike-CE0fXfM_.js → clike-CIAs0ABt.js} +0 -0
  546. /package/dist/{clojure-QkBEMU-g.js → clojure-C6tKQYjD.js} +0 -0
  547. /package/dist/{cmake-CU1jX7Mo.js → cmake-D-nfcg14.js} +0 -0
  548. /package/dist/{cobol-DMOKzzky.js → cobol-DYTC58p9.js} +0 -0
  549. /package/dist/{coffeescript-DjnjLyfk.js → coffeescript-DctDWA58.js} +0 -0
  550. /package/dist/{colors-DmiH1bIH.js → colors-DR_aHfmQ.js} +0 -0
  551. /package/dist/{common-keywords-D3nPJNQP.js → common-keywords-FBrXPTcz.js} +0 -0
  552. /package/dist/{commonlisp-CYd9iOSe.js → commonlisp-BmvTqU5y.js} +0 -0
  553. /package/dist/{crystal-Dy55yoYG.js → crystal-BPIK2UMa.js} +0 -0
  554. /package/dist/{css-CNU8w3HJ.js → css-CDo_Lwzn.js} +0 -0
  555. /package/dist/{cypher-q47DGzK7.js → cypher-KztbD63v.js} +0 -0
  556. /package/dist/{d-jEkaLvxX.js → d-HXBWOoe9.js} +0 -0
  557. /package/dist/{defaultLocale-DoeErsX2.js → defaultLocale-DMZFeDB8.js} +0 -0
  558. /package/dist/{diff-vb2-unFN.js → diff-B9rWZH0m.js} +0 -0
  559. /package/dist/{dtd-C9kR-bXa.js → dtd-LtAMP5y8.js} +0 -0
  560. /package/dist/{duckdb-keywords-B6HYCMOT.js → duckdb-keywords-CvJhR_Yd.js} +0 -0
  561. /package/dist/{dylan-BLckrK-V.js → dylan-DXMK92pf.js} +0 -0
  562. /package/dist/{ebnf-Cnp3L9jg.js → ebnf-2D4Ctp3y.js} +0 -0
  563. /package/dist/{ecl-CEsf6XVg.js → ecl-Dqq8ser2.js} +0 -0
  564. /package/dist/{eiffel-2KGZNzx6.js → eiffel-ChExWBDx.js} +0 -0
  565. /package/dist/{elm-D2s3K5wF.js → elm-BMBz2xbZ.js} +0 -0
  566. /package/dist/{emotion-is-prop-valid.esm-DdVSF4FD.js → emotion-is-prop-valid.esm-_z-EwK5u.js} +0 -0
  567. /package/dist/{erlang-0PMFOndk.js → erlang-CGSDzg9P.js} +0 -0
  568. /package/dist/{fcl-D9nccAWI.js → fcl-Ccj8Z5Xd.js} +0 -0
  569. /package/dist/{forth-DG89iUsu.js → forth-vTkfR0aY.js} +0 -0
  570. /package/dist/{fortran-ytKsAVvu.js → fortran-CF4LAVFn.js} +0 -0
  571. /package/dist/{gas-Cg2Fm0N2.js → gas-mMFbQ2x4.js} +0 -0
  572. /package/dist/{gherkin-B87FEnZ-.js → gherkin-DLS1q0XM.js} +0 -0
  573. /package/dist/{groovy-Dcs08AWD.js → groovy-Zt6CNPxV.js} +0 -0
  574. /package/dist/{haskell-cwkOuhx6.js → haskell-kVOgzpVy.js} +0 -0
  575. /package/dist/{haxe-DWEo4q10.js → haxe-Bo21F6gc.js} +0 -0
  576. /package/dist/{http-B8jdG64J.js → http-_DVAYWoR.js} +0 -0
  577. /package/dist/{idl-WWQwDcRV.js → idl-B865GSM-.js} +0 -0
  578. /package/dist/{init-DNBbYZd_.js → init-TaqZJsBY.js} +0 -0
  579. /package/dist/{invariant-wRzNXIsJ.js → invariant-hOqqBz8A.js} +0 -0
  580. /package/dist/{javascript-BeR74dxD.js → javascript-CSLuHpxZ.js} +0 -0
  581. /package/dist/{julia-UlvCUYGL.js → julia-BCOLeQif.js} +0 -0
  582. /package/dist/{livescript-GPmFcmYV.js → livescript-DqUzLZFs.js} +0 -0
  583. /package/dist/{lua-DYoT_0zM.js → lua-D0ciLwkO.js} +0 -0
  584. /package/dist/{math-CBNc2Ib0.js → math-CTnb-N1W.js} +0 -0
  585. /package/dist/{mathematica-DSFIQlbG.js → mathematica-DujD1RDf.js} +0 -0
  586. /package/dist/{mbox-ej8lFMdL.js → mbox-8OkSQMDn.js} +0 -0
  587. /package/dist/{mirc-CAdIdvHQ.js → mirc-D47x8yRQ.js} +0 -0
  588. /package/dist/{mllike-CjTB1lHF.js → mllike-Dcfw-g6D.js} +0 -0
  589. /package/dist/{modelica-BB68FYMa.js → modelica-BHtr9gKR.js} +0 -0
  590. /package/dist/{mscgen-BkbzgGGI.js → mscgen-uZedQc_A.js} +0 -0
  591. /package/dist/{mumps-Cu-28E9F.js → mumps-Bc9QS1-K.js} +0 -0
  592. /package/dist/{nginx-C1ofKPst.js → nginx-DasThI7R.js} +0 -0
  593. /package/dist/{ntriples-D9cQiZxZ.js → ntriples-Clpn9Mrg.js} +0 -0
  594. /package/dist/{objects-De59twF-.js → objects-UzwQd5gx.js} +0 -0
  595. /package/dist/{octave-BvtAnPX0.js → octave-DA2esRWi.js} +0 -0
  596. /package/dist/{oz-COaVHk2E.js → oz-D8i-brWx.js} +0 -0
  597. /package/dist/{pascal-BFpqVD2x.js → pascal-Dt1a0CeN.js} +0 -0
  598. /package/dist/{path-DwWbhZFI.js → path-7gr7eZmp.js} +0 -0
  599. /package/dist/{perl-DaiORxHP.js → perl-CXy9EfRp.js} +0 -0
  600. /package/dist/{pig-DFzRhmsF.js → pig-DnXnrjQg.js} +0 -0
  601. /package/dist/{powershell-BG2LQNKN.js → powershell-BYE6u-Qk.js} +0 -0
  602. /package/dist/{properties-CqJJR5QY.js → properties-DlhyusaK.js} +0 -0
  603. /package/dist/{protobuf-WwDYV1yY.js → protobuf-DoMSrsPi.js} +0 -0
  604. /package/dist/{puppet-QNY3w_uN.js → puppet-DGi4idFA.js} +0 -0
  605. /package/dist/{python-4QrQ3Ugi.js → python-CYhALYh0.js} +0 -0
  606. /package/dist/{q-DhwXuxE2.js → q-Cs_qWJkU.js} +0 -0
  607. /package/dist/{r-Df-nkR25.js → r-DWJSQl1c.js} +0 -0
  608. /package/dist/{range-BOiA8qqU.js → range-Bieq5MNc.js} +0 -0
  609. /package/dist/{rpm-Cokue07s.js → rpm-DIip1m0n.js} +0 -0
  610. /package/dist/{ruby-DrYcL3qF.js → ruby-NgZGoa7Q.js} +0 -0
  611. /package/dist/{sas-CoiPirA5.js → sas-DEKzCzM2.js} +0 -0
  612. /package/dist/{scheme-CwFLjzHv.js → scheme-CBrGar2n.js} +0 -0
  613. /package/dist/{semaphore-C8rmHdhj.js → semaphore-P832H4YT.js} +0 -0
  614. /package/dist/{shell-BFV-R24I.js → shell-D7XFPOM_.js} +0 -0
  615. /package/dist/{sieve-CxwXF5T9.js → sieve-BOxOVQ18.js} +0 -0
  616. /package/dist/{simple-mode-DTaJtKPt.js → simple-mode-D-FXBgPn.js} +0 -0
  617. /package/dist/{smalltalk-QivVOCtX.js → smalltalk-DYK-HkUK.js} +0 -0
  618. /package/dist/{solr-BLvysN-c.js → solr-RZ9uTl59.js} +0 -0
  619. /package/dist/{sparql-nKsFk8j7.js → sparql-CU1uk9Py.js} +0 -0
  620. /package/dist/{spreadsheet-BWc8C2FT.js → spreadsheet-BNNUNXA2.js} +0 -0
  621. /package/dist/{sql-CWfUjlV1.js → sql-B4x8IkwU.js} +0 -0
  622. /package/dist/{stex-DtMAhV4-.js → stex-DIvyJfNO.js} +0 -0
  623. /package/dist/{stylus-BLKQAycn.js → stylus-BokZhKWB.js} +0 -0
  624. /package/dist/{swift-CJoKqiKj.js → swift-TlA42tbT.js} +0 -0
  625. /package/dist/{tcl-YTeYFNUc.js → tcl-C-m7N_9k.js} +0 -0
  626. /package/dist/{textile-C6rKQqMQ.js → textile-BWOWG894.js} +0 -0
  627. /package/dist/{tiddlywiki-ZXwTHGNT.js → tiddlywiki-DI0mF2WJ.js} +0 -0
  628. /package/dist/{tiki-C628O_u4.js → tiki-2HU6XLLn.js} +0 -0
  629. /package/dist/{toml-DxlPGbRy.js → toml-GapOS-6U.js} +0 -0
  630. /package/dist/{treemap-DY3NBr79.js → treemap-CQJ0bIDy.js} +0 -0
  631. /package/dist/{troff-DFCfH7Ku.js → troff-ChPXSGgg.js} +0 -0
  632. /package/dist/{ttcn-DAW-ERVP.js → ttcn-CGf_ktUb.js} +0 -0
  633. /package/dist/{ttcn-cfg-CpJ8b7EN.js → ttcn-cfg-E0kw_vEm.js} +0 -0
  634. /package/dist/{turtle-BneV2f8L.js → turtle-DDIYttZr.js} +0 -0
  635. /package/dist/{vb-D973Vxxh.js → vb-DsGz8YA-.js} +0 -0
  636. /package/dist/{vbscript-Dckaq3YO.js → vbscript-BfQcpKZn.js} +0 -0
  637. /package/dist/{velocity-DKty-GUC.js → velocity-BMi53hPb.js} +0 -0
  638. /package/dist/{verilog-aNaK_biA.js → verilog-B_WDxmCB.js} +0 -0
  639. /package/dist/{vhdl-CQuehnQy.js → vhdl-C52-TT0z.js} +0 -0
  640. /package/dist/{webidl-Bhg8vaMr.js → webidl-Cnphjlul.js} +0 -0
  641. /package/dist/{xquery-D2q16GaM.js → xquery-X_kWyOft.js} +0 -0
  642. /package/dist/{yacas-DHGOHnNa.js → yacas-Dpp9zAZ5.js} +0 -0
  643. /package/dist/{z80-BPhTmO22.js → z80-BZLZAthF.js} +0 -0
@@ -1,3652 +0,0 @@
1
- var _a;
2
- import "./purify.es-EnR5yhgI.js";
3
- import { g as utils_default, p as parseFontSize, t as ZERO_WIDTH_SPACE } from "./chunk-S3R3BYOJ-BdgLc8AM.js";
4
- import { i as log, r as __name, t as select_default } from "./src-DV3ha_nA.js";
5
- import { B as setAccTitle, C as getDiagramTitle, E as getUrl, H as setConfig2, I as sanitizeText, N as renderKatexSanitized, O as hasKatex, U as setDiagramTitle, _ as getAccDescription, a as clear, b as getConfig2, c as configureSvgSize, i as calculateMathMLDimensions, r as assignWithDepth_default, s as common_default, v as getAccTitle, y as getConfig, z as setAccDescription } from "./chunk-ABZYJK2D-BxBDji1u.js";
6
- import { n as load, t as JSON_SCHEMA } from "./chunk-MI3HLSF2-HGWI-8Pg.js";
7
- import { t as require_dist } from "./dist-DsoKosxi.js";
8
- import { i as drawRect, n as drawEmbeddedImage, o as getNoteRect, r as drawImage, s as getTextObj, t as drawBackgroundRect } from "./chunk-TZMSLE5B-BzSHcq-K.js";
9
- import { t as ImperativeState } from "./chunk-QZHKN3VN-Dym5BS7y.js";
10
- var import_dist = require_dist(), parser = (function() {
11
- var t = /* @__PURE__ */ __name(function(t2, l2, u2, d2) {
12
- for (u2 || (u2 = {}), d2 = t2.length; d2--; u2[t2[d2]] = l2) ;
13
- return u2;
14
- }, "o"), l = [1, 2], u = [1, 3], d = [1, 4], p = [2, 4], m = [1, 9], h = [1, 11], g = [1, 13], _ = [1, 14], v = [1, 16], y = [1, 17], b = [1, 18], x = [1, 24], S = [1, 25], C = [1, 26], w = [1, 27], T = [1, 28], E = [1, 29], D = [1, 30], O = [1, 31], k = [1, 32], A = [1, 33], j = [1, 34], M = [1, 35], N = [1, 36], P = [1, 37], F = [1, 38], I = [1, 39], L = [1, 41], R = [1, 42], z = [1, 43], B = [1, 44], V = [1, 45], H = [1, 46], U = [
15
- 1,
16
- 4,
17
- 5,
18
- 13,
19
- 14,
20
- 16,
21
- 18,
22
- 21,
23
- 23,
24
- 29,
25
- 30,
26
- 31,
27
- 33,
28
- 35,
29
- 36,
30
- 37,
31
- 38,
32
- 39,
33
- 41,
34
- 43,
35
- 44,
36
- 46,
37
- 47,
38
- 48,
39
- 49,
40
- 50,
41
- 52,
42
- 53,
43
- 55,
44
- 60,
45
- 61,
46
- 62,
47
- 63,
48
- 71
49
- ], W = [2, 71], G = [
50
- 4,
51
- 5,
52
- 16,
53
- 50,
54
- 52,
55
- 53
56
- ], K = [
57
- 4,
58
- 5,
59
- 13,
60
- 14,
61
- 16,
62
- 18,
63
- 21,
64
- 23,
65
- 29,
66
- 30,
67
- 31,
68
- 33,
69
- 35,
70
- 36,
71
- 37,
72
- 38,
73
- 39,
74
- 41,
75
- 43,
76
- 44,
77
- 46,
78
- 50,
79
- 52,
80
- 53,
81
- 55,
82
- 60,
83
- 61,
84
- 62,
85
- 63,
86
- 71
87
- ], q = [
88
- 4,
89
- 5,
90
- 13,
91
- 14,
92
- 16,
93
- 18,
94
- 21,
95
- 23,
96
- 29,
97
- 30,
98
- 31,
99
- 33,
100
- 35,
101
- 36,
102
- 37,
103
- 38,
104
- 39,
105
- 41,
106
- 43,
107
- 44,
108
- 46,
109
- 49,
110
- 50,
111
- 52,
112
- 53,
113
- 55,
114
- 60,
115
- 61,
116
- 62,
117
- 63,
118
- 71
119
- ], J = [
120
- 4,
121
- 5,
122
- 13,
123
- 14,
124
- 16,
125
- 18,
126
- 21,
127
- 23,
128
- 29,
129
- 30,
130
- 31,
131
- 33,
132
- 35,
133
- 36,
134
- 37,
135
- 38,
136
- 39,
137
- 41,
138
- 43,
139
- 44,
140
- 46,
141
- 48,
142
- 50,
143
- 52,
144
- 53,
145
- 55,
146
- 60,
147
- 61,
148
- 62,
149
- 63,
150
- 71
151
- ], Y = [
152
- 4,
153
- 5,
154
- 13,
155
- 14,
156
- 16,
157
- 18,
158
- 21,
159
- 23,
160
- 29,
161
- 30,
162
- 31,
163
- 33,
164
- 35,
165
- 36,
166
- 37,
167
- 38,
168
- 39,
169
- 41,
170
- 43,
171
- 44,
172
- 46,
173
- 47,
174
- 50,
175
- 52,
176
- 53,
177
- 55,
178
- 60,
179
- 61,
180
- 62,
181
- 63,
182
- 71
183
- ], X = [
184
- 69,
185
- 70,
186
- 71
187
- ], Z = [1, 127], Q = {
188
- trace: /* @__PURE__ */ __name(function() {
189
- }, "trace"),
190
- yy: {},
191
- symbols_: {
192
- error: 2,
193
- start: 3,
194
- SPACE: 4,
195
- NEWLINE: 5,
196
- SD: 6,
197
- document: 7,
198
- line: 8,
199
- statement: 9,
200
- box_section: 10,
201
- box_line: 11,
202
- participant_statement: 12,
203
- create: 13,
204
- box: 14,
205
- restOfLine: 15,
206
- end: 16,
207
- signal: 17,
208
- autonumber: 18,
209
- NUM: 19,
210
- off: 20,
211
- activate: 21,
212
- actor: 22,
213
- deactivate: 23,
214
- note_statement: 24,
215
- links_statement: 25,
216
- link_statement: 26,
217
- properties_statement: 27,
218
- details_statement: 28,
219
- title: 29,
220
- legacy_title: 30,
221
- acc_title: 31,
222
- acc_title_value: 32,
223
- acc_descr: 33,
224
- acc_descr_value: 34,
225
- acc_descr_multiline_value: 35,
226
- loop: 36,
227
- rect: 37,
228
- opt: 38,
229
- alt: 39,
230
- else_sections: 40,
231
- par: 41,
232
- par_sections: 42,
233
- par_over: 43,
234
- critical: 44,
235
- option_sections: 45,
236
- break: 46,
237
- option: 47,
238
- and: 48,
239
- else: 49,
240
- participant: 50,
241
- AS: 51,
242
- participant_actor: 52,
243
- destroy: 53,
244
- actor_with_config: 54,
245
- note: 55,
246
- placement: 56,
247
- text2: 57,
248
- over: 58,
249
- actor_pair: 59,
250
- links: 60,
251
- link: 61,
252
- properties: 62,
253
- details: 63,
254
- spaceList: 64,
255
- ",": 65,
256
- left_of: 66,
257
- right_of: 67,
258
- signaltype: 68,
259
- "+": 69,
260
- "-": 70,
261
- ACTOR: 71,
262
- config_object: 72,
263
- CONFIG_START: 73,
264
- CONFIG_CONTENT: 74,
265
- CONFIG_END: 75,
266
- SOLID_OPEN_ARROW: 76,
267
- DOTTED_OPEN_ARROW: 77,
268
- SOLID_ARROW: 78,
269
- BIDIRECTIONAL_SOLID_ARROW: 79,
270
- DOTTED_ARROW: 80,
271
- BIDIRECTIONAL_DOTTED_ARROW: 81,
272
- SOLID_CROSS: 82,
273
- DOTTED_CROSS: 83,
274
- SOLID_POINT: 84,
275
- DOTTED_POINT: 85,
276
- TXT: 86,
277
- $accept: 0,
278
- $end: 1
279
- },
280
- terminals_: {
281
- 2: "error",
282
- 4: "SPACE",
283
- 5: "NEWLINE",
284
- 6: "SD",
285
- 13: "create",
286
- 14: "box",
287
- 15: "restOfLine",
288
- 16: "end",
289
- 18: "autonumber",
290
- 19: "NUM",
291
- 20: "off",
292
- 21: "activate",
293
- 23: "deactivate",
294
- 29: "title",
295
- 30: "legacy_title",
296
- 31: "acc_title",
297
- 32: "acc_title_value",
298
- 33: "acc_descr",
299
- 34: "acc_descr_value",
300
- 35: "acc_descr_multiline_value",
301
- 36: "loop",
302
- 37: "rect",
303
- 38: "opt",
304
- 39: "alt",
305
- 41: "par",
306
- 43: "par_over",
307
- 44: "critical",
308
- 46: "break",
309
- 47: "option",
310
- 48: "and",
311
- 49: "else",
312
- 50: "participant",
313
- 51: "AS",
314
- 52: "participant_actor",
315
- 53: "destroy",
316
- 55: "note",
317
- 58: "over",
318
- 60: "links",
319
- 61: "link",
320
- 62: "properties",
321
- 63: "details",
322
- 65: ",",
323
- 66: "left_of",
324
- 67: "right_of",
325
- 69: "+",
326
- 70: "-",
327
- 71: "ACTOR",
328
- 73: "CONFIG_START",
329
- 74: "CONFIG_CONTENT",
330
- 75: "CONFIG_END",
331
- 76: "SOLID_OPEN_ARROW",
332
- 77: "DOTTED_OPEN_ARROW",
333
- 78: "SOLID_ARROW",
334
- 79: "BIDIRECTIONAL_SOLID_ARROW",
335
- 80: "DOTTED_ARROW",
336
- 81: "BIDIRECTIONAL_DOTTED_ARROW",
337
- 82: "SOLID_CROSS",
338
- 83: "DOTTED_CROSS",
339
- 84: "SOLID_POINT",
340
- 85: "DOTTED_POINT",
341
- 86: "TXT"
342
- },
343
- productions_: [
344
- 0,
345
- [3, 2],
346
- [3, 2],
347
- [3, 2],
348
- [7, 0],
349
- [7, 2],
350
- [8, 2],
351
- [8, 1],
352
- [8, 1],
353
- [10, 0],
354
- [10, 2],
355
- [11, 2],
356
- [11, 1],
357
- [11, 1],
358
- [9, 1],
359
- [9, 2],
360
- [9, 4],
361
- [9, 2],
362
- [9, 4],
363
- [9, 3],
364
- [9, 3],
365
- [9, 2],
366
- [9, 3],
367
- [9, 3],
368
- [9, 2],
369
- [9, 2],
370
- [9, 2],
371
- [9, 2],
372
- [9, 2],
373
- [9, 1],
374
- [9, 1],
375
- [9, 2],
376
- [9, 2],
377
- [9, 1],
378
- [9, 4],
379
- [9, 4],
380
- [9, 4],
381
- [9, 4],
382
- [9, 4],
383
- [9, 4],
384
- [9, 4],
385
- [9, 4],
386
- [45, 1],
387
- [45, 4],
388
- [42, 1],
389
- [42, 4],
390
- [40, 1],
391
- [40, 4],
392
- [12, 5],
393
- [12, 3],
394
- [12, 5],
395
- [12, 3],
396
- [12, 3],
397
- [12, 3],
398
- [24, 4],
399
- [24, 4],
400
- [25, 3],
401
- [26, 3],
402
- [27, 3],
403
- [28, 3],
404
- [64, 2],
405
- [64, 1],
406
- [59, 3],
407
- [59, 1],
408
- [56, 1],
409
- [56, 1],
410
- [17, 5],
411
- [17, 5],
412
- [17, 4],
413
- [54, 2],
414
- [72, 3],
415
- [22, 1],
416
- [68, 1],
417
- [68, 1],
418
- [68, 1],
419
- [68, 1],
420
- [68, 1],
421
- [68, 1],
422
- [68, 1],
423
- [68, 1],
424
- [68, 1],
425
- [68, 1],
426
- [57, 1]
427
- ],
428
- performAction: /* @__PURE__ */ __name(function(t2, l2, u2, d2, f, p2, m2) {
429
- var h2 = p2.length - 1;
430
- switch (f) {
431
- case 3:
432
- return d2.apply(p2[h2]), p2[h2];
433
- case 4:
434
- case 9:
435
- this.$ = [];
436
- break;
437
- case 5:
438
- case 10:
439
- p2[h2 - 1].push(p2[h2]), this.$ = p2[h2 - 1];
440
- break;
441
- case 6:
442
- case 7:
443
- case 11:
444
- case 12:
445
- this.$ = p2[h2];
446
- break;
447
- case 8:
448
- case 13:
449
- this.$ = [];
450
- break;
451
- case 15:
452
- p2[h2].type = "createParticipant", this.$ = p2[h2];
453
- break;
454
- case 16:
455
- p2[h2 - 1].unshift({
456
- type: "boxStart",
457
- boxData: d2.parseBoxData(p2[h2 - 2])
458
- }), p2[h2 - 1].push({
459
- type: "boxEnd",
460
- boxText: p2[h2 - 2]
461
- }), this.$ = p2[h2 - 1];
462
- break;
463
- case 18:
464
- this.$ = {
465
- type: "sequenceIndex",
466
- sequenceIndex: Number(p2[h2 - 2]),
467
- sequenceIndexStep: Number(p2[h2 - 1]),
468
- sequenceVisible: true,
469
- signalType: d2.LINETYPE.AUTONUMBER
470
- };
471
- break;
472
- case 19:
473
- this.$ = {
474
- type: "sequenceIndex",
475
- sequenceIndex: Number(p2[h2 - 1]),
476
- sequenceIndexStep: 1,
477
- sequenceVisible: true,
478
- signalType: d2.LINETYPE.AUTONUMBER
479
- };
480
- break;
481
- case 20:
482
- this.$ = {
483
- type: "sequenceIndex",
484
- sequenceVisible: false,
485
- signalType: d2.LINETYPE.AUTONUMBER
486
- };
487
- break;
488
- case 21:
489
- this.$ = {
490
- type: "sequenceIndex",
491
- sequenceVisible: true,
492
- signalType: d2.LINETYPE.AUTONUMBER
493
- };
494
- break;
495
- case 22:
496
- this.$ = {
497
- type: "activeStart",
498
- signalType: d2.LINETYPE.ACTIVE_START,
499
- actor: p2[h2 - 1].actor
500
- };
501
- break;
502
- case 23:
503
- this.$ = {
504
- type: "activeEnd",
505
- signalType: d2.LINETYPE.ACTIVE_END,
506
- actor: p2[h2 - 1].actor
507
- };
508
- break;
509
- case 29:
510
- d2.setDiagramTitle(p2[h2].substring(6)), this.$ = p2[h2].substring(6);
511
- break;
512
- case 30:
513
- d2.setDiagramTitle(p2[h2].substring(7)), this.$ = p2[h2].substring(7);
514
- break;
515
- case 31:
516
- this.$ = p2[h2].trim(), d2.setAccTitle(this.$);
517
- break;
518
- case 32:
519
- case 33:
520
- this.$ = p2[h2].trim(), d2.setAccDescription(this.$);
521
- break;
522
- case 34:
523
- p2[h2 - 1].unshift({
524
- type: "loopStart",
525
- loopText: d2.parseMessage(p2[h2 - 2]),
526
- signalType: d2.LINETYPE.LOOP_START
527
- }), p2[h2 - 1].push({
528
- type: "loopEnd",
529
- loopText: p2[h2 - 2],
530
- signalType: d2.LINETYPE.LOOP_END
531
- }), this.$ = p2[h2 - 1];
532
- break;
533
- case 35:
534
- p2[h2 - 1].unshift({
535
- type: "rectStart",
536
- color: d2.parseMessage(p2[h2 - 2]),
537
- signalType: d2.LINETYPE.RECT_START
538
- }), p2[h2 - 1].push({
539
- type: "rectEnd",
540
- color: d2.parseMessage(p2[h2 - 2]),
541
- signalType: d2.LINETYPE.RECT_END
542
- }), this.$ = p2[h2 - 1];
543
- break;
544
- case 36:
545
- p2[h2 - 1].unshift({
546
- type: "optStart",
547
- optText: d2.parseMessage(p2[h2 - 2]),
548
- signalType: d2.LINETYPE.OPT_START
549
- }), p2[h2 - 1].push({
550
- type: "optEnd",
551
- optText: d2.parseMessage(p2[h2 - 2]),
552
- signalType: d2.LINETYPE.OPT_END
553
- }), this.$ = p2[h2 - 1];
554
- break;
555
- case 37:
556
- p2[h2 - 1].unshift({
557
- type: "altStart",
558
- altText: d2.parseMessage(p2[h2 - 2]),
559
- signalType: d2.LINETYPE.ALT_START
560
- }), p2[h2 - 1].push({
561
- type: "altEnd",
562
- signalType: d2.LINETYPE.ALT_END
563
- }), this.$ = p2[h2 - 1];
564
- break;
565
- case 38:
566
- p2[h2 - 1].unshift({
567
- type: "parStart",
568
- parText: d2.parseMessage(p2[h2 - 2]),
569
- signalType: d2.LINETYPE.PAR_START
570
- }), p2[h2 - 1].push({
571
- type: "parEnd",
572
- signalType: d2.LINETYPE.PAR_END
573
- }), this.$ = p2[h2 - 1];
574
- break;
575
- case 39:
576
- p2[h2 - 1].unshift({
577
- type: "parStart",
578
- parText: d2.parseMessage(p2[h2 - 2]),
579
- signalType: d2.LINETYPE.PAR_OVER_START
580
- }), p2[h2 - 1].push({
581
- type: "parEnd",
582
- signalType: d2.LINETYPE.PAR_END
583
- }), this.$ = p2[h2 - 1];
584
- break;
585
- case 40:
586
- p2[h2 - 1].unshift({
587
- type: "criticalStart",
588
- criticalText: d2.parseMessage(p2[h2 - 2]),
589
- signalType: d2.LINETYPE.CRITICAL_START
590
- }), p2[h2 - 1].push({
591
- type: "criticalEnd",
592
- signalType: d2.LINETYPE.CRITICAL_END
593
- }), this.$ = p2[h2 - 1];
594
- break;
595
- case 41:
596
- p2[h2 - 1].unshift({
597
- type: "breakStart",
598
- breakText: d2.parseMessage(p2[h2 - 2]),
599
- signalType: d2.LINETYPE.BREAK_START
600
- }), p2[h2 - 1].push({
601
- type: "breakEnd",
602
- optText: d2.parseMessage(p2[h2 - 2]),
603
- signalType: d2.LINETYPE.BREAK_END
604
- }), this.$ = p2[h2 - 1];
605
- break;
606
- case 43:
607
- this.$ = p2[h2 - 3].concat([{
608
- type: "option",
609
- optionText: d2.parseMessage(p2[h2 - 1]),
610
- signalType: d2.LINETYPE.CRITICAL_OPTION
611
- }, p2[h2]]);
612
- break;
613
- case 45:
614
- this.$ = p2[h2 - 3].concat([{
615
- type: "and",
616
- parText: d2.parseMessage(p2[h2 - 1]),
617
- signalType: d2.LINETYPE.PAR_AND
618
- }, p2[h2]]);
619
- break;
620
- case 47:
621
- this.$ = p2[h2 - 3].concat([{
622
- type: "else",
623
- altText: d2.parseMessage(p2[h2 - 1]),
624
- signalType: d2.LINETYPE.ALT_ELSE
625
- }, p2[h2]]);
626
- break;
627
- case 48:
628
- p2[h2 - 3].draw = "participant", p2[h2 - 3].type = "addParticipant", p2[h2 - 3].description = d2.parseMessage(p2[h2 - 1]), this.$ = p2[h2 - 3];
629
- break;
630
- case 49:
631
- p2[h2 - 1].draw = "participant", p2[h2 - 1].type = "addParticipant", this.$ = p2[h2 - 1];
632
- break;
633
- case 50:
634
- p2[h2 - 3].draw = "actor", p2[h2 - 3].type = "addParticipant", p2[h2 - 3].description = d2.parseMessage(p2[h2 - 1]), this.$ = p2[h2 - 3];
635
- break;
636
- case 51:
637
- p2[h2 - 1].draw = "actor", p2[h2 - 1].type = "addParticipant", this.$ = p2[h2 - 1];
638
- break;
639
- case 52:
640
- p2[h2 - 1].type = "destroyParticipant", this.$ = p2[h2 - 1];
641
- break;
642
- case 53:
643
- p2[h2 - 1].draw = "participant", p2[h2 - 1].type = "addParticipant", this.$ = p2[h2 - 1];
644
- break;
645
- case 54:
646
- this.$ = [p2[h2 - 1], {
647
- type: "addNote",
648
- placement: p2[h2 - 2],
649
- actor: p2[h2 - 1].actor,
650
- text: p2[h2]
651
- }];
652
- break;
653
- case 55:
654
- p2[h2 - 2] = [].concat(p2[h2 - 1], p2[h2 - 1]).slice(0, 2), p2[h2 - 2][0] = p2[h2 - 2][0].actor, p2[h2 - 2][1] = p2[h2 - 2][1].actor, this.$ = [p2[h2 - 1], {
655
- type: "addNote",
656
- placement: d2.PLACEMENT.OVER,
657
- actor: p2[h2 - 2].slice(0, 2),
658
- text: p2[h2]
659
- }];
660
- break;
661
- case 56:
662
- this.$ = [p2[h2 - 1], {
663
- type: "addLinks",
664
- actor: p2[h2 - 1].actor,
665
- text: p2[h2]
666
- }];
667
- break;
668
- case 57:
669
- this.$ = [p2[h2 - 1], {
670
- type: "addALink",
671
- actor: p2[h2 - 1].actor,
672
- text: p2[h2]
673
- }];
674
- break;
675
- case 58:
676
- this.$ = [p2[h2 - 1], {
677
- type: "addProperties",
678
- actor: p2[h2 - 1].actor,
679
- text: p2[h2]
680
- }];
681
- break;
682
- case 59:
683
- this.$ = [p2[h2 - 1], {
684
- type: "addDetails",
685
- actor: p2[h2 - 1].actor,
686
- text: p2[h2]
687
- }];
688
- break;
689
- case 62:
690
- this.$ = [p2[h2 - 2], p2[h2]];
691
- break;
692
- case 63:
693
- this.$ = p2[h2];
694
- break;
695
- case 64:
696
- this.$ = d2.PLACEMENT.LEFTOF;
697
- break;
698
- case 65:
699
- this.$ = d2.PLACEMENT.RIGHTOF;
700
- break;
701
- case 66:
702
- this.$ = [
703
- p2[h2 - 4],
704
- p2[h2 - 1],
705
- {
706
- type: "addMessage",
707
- from: p2[h2 - 4].actor,
708
- to: p2[h2 - 1].actor,
709
- signalType: p2[h2 - 3],
710
- msg: p2[h2],
711
- activate: true
712
- },
713
- {
714
- type: "activeStart",
715
- signalType: d2.LINETYPE.ACTIVE_START,
716
- actor: p2[h2 - 1].actor
717
- }
718
- ];
719
- break;
720
- case 67:
721
- this.$ = [
722
- p2[h2 - 4],
723
- p2[h2 - 1],
724
- {
725
- type: "addMessage",
726
- from: p2[h2 - 4].actor,
727
- to: p2[h2 - 1].actor,
728
- signalType: p2[h2 - 3],
729
- msg: p2[h2]
730
- },
731
- {
732
- type: "activeEnd",
733
- signalType: d2.LINETYPE.ACTIVE_END,
734
- actor: p2[h2 - 4].actor
735
- }
736
- ];
737
- break;
738
- case 68:
739
- this.$ = [
740
- p2[h2 - 3],
741
- p2[h2 - 1],
742
- {
743
- type: "addMessage",
744
- from: p2[h2 - 3].actor,
745
- to: p2[h2 - 1].actor,
746
- signalType: p2[h2 - 2],
747
- msg: p2[h2]
748
- }
749
- ];
750
- break;
751
- case 69:
752
- this.$ = {
753
- type: "addParticipant",
754
- actor: p2[h2 - 1],
755
- config: p2[h2]
756
- };
757
- break;
758
- case 70:
759
- this.$ = p2[h2 - 1].trim();
760
- break;
761
- case 71:
762
- this.$ = {
763
- type: "addParticipant",
764
- actor: p2[h2]
765
- };
766
- break;
767
- case 72:
768
- this.$ = d2.LINETYPE.SOLID_OPEN;
769
- break;
770
- case 73:
771
- this.$ = d2.LINETYPE.DOTTED_OPEN;
772
- break;
773
- case 74:
774
- this.$ = d2.LINETYPE.SOLID;
775
- break;
776
- case 75:
777
- this.$ = d2.LINETYPE.BIDIRECTIONAL_SOLID;
778
- break;
779
- case 76:
780
- this.$ = d2.LINETYPE.DOTTED;
781
- break;
782
- case 77:
783
- this.$ = d2.LINETYPE.BIDIRECTIONAL_DOTTED;
784
- break;
785
- case 78:
786
- this.$ = d2.LINETYPE.SOLID_CROSS;
787
- break;
788
- case 79:
789
- this.$ = d2.LINETYPE.DOTTED_CROSS;
790
- break;
791
- case 80:
792
- this.$ = d2.LINETYPE.SOLID_POINT;
793
- break;
794
- case 81:
795
- this.$ = d2.LINETYPE.DOTTED_POINT;
796
- break;
797
- case 82:
798
- this.$ = d2.parseMessage(p2[h2].trim().substring(1));
799
- break;
800
- }
801
- }, "anonymous"),
802
- table: [
803
- {
804
- 3: 1,
805
- 4: l,
806
- 5: u,
807
- 6: d
808
- },
809
- { 1: [3] },
810
- {
811
- 3: 5,
812
- 4: l,
813
- 5: u,
814
- 6: d
815
- },
816
- {
817
- 3: 6,
818
- 4: l,
819
- 5: u,
820
- 6: d
821
- },
822
- t([
823
- 1,
824
- 4,
825
- 5,
826
- 13,
827
- 14,
828
- 18,
829
- 21,
830
- 23,
831
- 29,
832
- 30,
833
- 31,
834
- 33,
835
- 35,
836
- 36,
837
- 37,
838
- 38,
839
- 39,
840
- 41,
841
- 43,
842
- 44,
843
- 46,
844
- 50,
845
- 52,
846
- 53,
847
- 55,
848
- 60,
849
- 61,
850
- 62,
851
- 63,
852
- 71
853
- ], p, { 7: 7 }),
854
- { 1: [2, 1] },
855
- { 1: [2, 2] },
856
- {
857
- 1: [2, 3],
858
- 4: m,
859
- 5: h,
860
- 8: 8,
861
- 9: 10,
862
- 12: 12,
863
- 13: g,
864
- 14: _,
865
- 17: 15,
866
- 18: v,
867
- 21: y,
868
- 22: 40,
869
- 23: b,
870
- 24: 19,
871
- 25: 20,
872
- 26: 21,
873
- 27: 22,
874
- 28: 23,
875
- 29: x,
876
- 30: S,
877
- 31: C,
878
- 33: w,
879
- 35: T,
880
- 36: E,
881
- 37: D,
882
- 38: O,
883
- 39: k,
884
- 41: A,
885
- 43: j,
886
- 44: M,
887
- 46: N,
888
- 50: P,
889
- 52: F,
890
- 53: I,
891
- 55: L,
892
- 60: R,
893
- 61: z,
894
- 62: B,
895
- 63: V,
896
- 71: H
897
- },
898
- t(U, [2, 5]),
899
- {
900
- 9: 47,
901
- 12: 12,
902
- 13: g,
903
- 14: _,
904
- 17: 15,
905
- 18: v,
906
- 21: y,
907
- 22: 40,
908
- 23: b,
909
- 24: 19,
910
- 25: 20,
911
- 26: 21,
912
- 27: 22,
913
- 28: 23,
914
- 29: x,
915
- 30: S,
916
- 31: C,
917
- 33: w,
918
- 35: T,
919
- 36: E,
920
- 37: D,
921
- 38: O,
922
- 39: k,
923
- 41: A,
924
- 43: j,
925
- 44: M,
926
- 46: N,
927
- 50: P,
928
- 52: F,
929
- 53: I,
930
- 55: L,
931
- 60: R,
932
- 61: z,
933
- 62: B,
934
- 63: V,
935
- 71: H
936
- },
937
- t(U, [2, 7]),
938
- t(U, [2, 8]),
939
- t(U, [2, 14]),
940
- {
941
- 12: 48,
942
- 50: P,
943
- 52: F,
944
- 53: I
945
- },
946
- { 15: [1, 49] },
947
- { 5: [1, 50] },
948
- {
949
- 5: [1, 53],
950
- 19: [1, 51],
951
- 20: [1, 52]
952
- },
953
- {
954
- 22: 54,
955
- 71: H
956
- },
957
- {
958
- 22: 55,
959
- 71: H
960
- },
961
- { 5: [1, 56] },
962
- { 5: [1, 57] },
963
- { 5: [1, 58] },
964
- { 5: [1, 59] },
965
- { 5: [1, 60] },
966
- t(U, [2, 29]),
967
- t(U, [2, 30]),
968
- { 32: [1, 61] },
969
- { 34: [1, 62] },
970
- t(U, [2, 33]),
971
- { 15: [1, 63] },
972
- { 15: [1, 64] },
973
- { 15: [1, 65] },
974
- { 15: [1, 66] },
975
- { 15: [1, 67] },
976
- { 15: [1, 68] },
977
- { 15: [1, 69] },
978
- { 15: [1, 70] },
979
- {
980
- 22: 71,
981
- 54: 72,
982
- 71: [1, 73]
983
- },
984
- {
985
- 22: 74,
986
- 71: H
987
- },
988
- {
989
- 22: 75,
990
- 71: H
991
- },
992
- {
993
- 68: 76,
994
- 76: [1, 77],
995
- 77: [1, 78],
996
- 78: [1, 79],
997
- 79: [1, 80],
998
- 80: [1, 81],
999
- 81: [1, 82],
1000
- 82: [1, 83],
1001
- 83: [1, 84],
1002
- 84: [1, 85],
1003
- 85: [1, 86]
1004
- },
1005
- {
1006
- 56: 87,
1007
- 58: [1, 88],
1008
- 66: [1, 89],
1009
- 67: [1, 90]
1010
- },
1011
- {
1012
- 22: 91,
1013
- 71: H
1014
- },
1015
- {
1016
- 22: 92,
1017
- 71: H
1018
- },
1019
- {
1020
- 22: 93,
1021
- 71: H
1022
- },
1023
- {
1024
- 22: 94,
1025
- 71: H
1026
- },
1027
- t([
1028
- 5,
1029
- 51,
1030
- 65,
1031
- 76,
1032
- 77,
1033
- 78,
1034
- 79,
1035
- 80,
1036
- 81,
1037
- 82,
1038
- 83,
1039
- 84,
1040
- 85,
1041
- 86
1042
- ], W),
1043
- t(U, [2, 6]),
1044
- t(U, [2, 15]),
1045
- t(G, [2, 9], { 10: 95 }),
1046
- t(U, [2, 17]),
1047
- {
1048
- 5: [1, 97],
1049
- 19: [1, 96]
1050
- },
1051
- { 5: [1, 98] },
1052
- t(U, [2, 21]),
1053
- { 5: [1, 99] },
1054
- { 5: [1, 100] },
1055
- t(U, [2, 24]),
1056
- t(U, [2, 25]),
1057
- t(U, [2, 26]),
1058
- t(U, [2, 27]),
1059
- t(U, [2, 28]),
1060
- t(U, [2, 31]),
1061
- t(U, [2, 32]),
1062
- t(K, p, { 7: 101 }),
1063
- t(K, p, { 7: 102 }),
1064
- t(K, p, { 7: 103 }),
1065
- t(q, p, {
1066
- 40: 104,
1067
- 7: 105
1068
- }),
1069
- t(J, p, {
1070
- 42: 106,
1071
- 7: 107
1072
- }),
1073
- t(J, p, {
1074
- 7: 107,
1075
- 42: 108
1076
- }),
1077
- t(Y, p, {
1078
- 45: 109,
1079
- 7: 110
1080
- }),
1081
- t(K, p, { 7: 111 }),
1082
- {
1083
- 5: [1, 113],
1084
- 51: [1, 112]
1085
- },
1086
- { 5: [1, 114] },
1087
- t([5, 51], W, {
1088
- 72: 115,
1089
- 73: [1, 116]
1090
- }),
1091
- {
1092
- 5: [1, 118],
1093
- 51: [1, 117]
1094
- },
1095
- { 5: [1, 119] },
1096
- {
1097
- 22: 122,
1098
- 69: [1, 120],
1099
- 70: [1, 121],
1100
- 71: H
1101
- },
1102
- t(X, [2, 72]),
1103
- t(X, [2, 73]),
1104
- t(X, [2, 74]),
1105
- t(X, [2, 75]),
1106
- t(X, [2, 76]),
1107
- t(X, [2, 77]),
1108
- t(X, [2, 78]),
1109
- t(X, [2, 79]),
1110
- t(X, [2, 80]),
1111
- t(X, [2, 81]),
1112
- {
1113
- 22: 123,
1114
- 71: H
1115
- },
1116
- {
1117
- 22: 125,
1118
- 59: 124,
1119
- 71: H
1120
- },
1121
- { 71: [2, 64] },
1122
- { 71: [2, 65] },
1123
- {
1124
- 57: 126,
1125
- 86: Z
1126
- },
1127
- {
1128
- 57: 128,
1129
- 86: Z
1130
- },
1131
- {
1132
- 57: 129,
1133
- 86: Z
1134
- },
1135
- {
1136
- 57: 130,
1137
- 86: Z
1138
- },
1139
- {
1140
- 4: [1, 133],
1141
- 5: [1, 135],
1142
- 11: 132,
1143
- 12: 134,
1144
- 16: [1, 131],
1145
- 50: P,
1146
- 52: F,
1147
- 53: I
1148
- },
1149
- { 5: [1, 136] },
1150
- t(U, [2, 19]),
1151
- t(U, [2, 20]),
1152
- t(U, [2, 22]),
1153
- t(U, [2, 23]),
1154
- {
1155
- 4: m,
1156
- 5: h,
1157
- 8: 8,
1158
- 9: 10,
1159
- 12: 12,
1160
- 13: g,
1161
- 14: _,
1162
- 16: [1, 137],
1163
- 17: 15,
1164
- 18: v,
1165
- 21: y,
1166
- 22: 40,
1167
- 23: b,
1168
- 24: 19,
1169
- 25: 20,
1170
- 26: 21,
1171
- 27: 22,
1172
- 28: 23,
1173
- 29: x,
1174
- 30: S,
1175
- 31: C,
1176
- 33: w,
1177
- 35: T,
1178
- 36: E,
1179
- 37: D,
1180
- 38: O,
1181
- 39: k,
1182
- 41: A,
1183
- 43: j,
1184
- 44: M,
1185
- 46: N,
1186
- 50: P,
1187
- 52: F,
1188
- 53: I,
1189
- 55: L,
1190
- 60: R,
1191
- 61: z,
1192
- 62: B,
1193
- 63: V,
1194
- 71: H
1195
- },
1196
- {
1197
- 4: m,
1198
- 5: h,
1199
- 8: 8,
1200
- 9: 10,
1201
- 12: 12,
1202
- 13: g,
1203
- 14: _,
1204
- 16: [1, 138],
1205
- 17: 15,
1206
- 18: v,
1207
- 21: y,
1208
- 22: 40,
1209
- 23: b,
1210
- 24: 19,
1211
- 25: 20,
1212
- 26: 21,
1213
- 27: 22,
1214
- 28: 23,
1215
- 29: x,
1216
- 30: S,
1217
- 31: C,
1218
- 33: w,
1219
- 35: T,
1220
- 36: E,
1221
- 37: D,
1222
- 38: O,
1223
- 39: k,
1224
- 41: A,
1225
- 43: j,
1226
- 44: M,
1227
- 46: N,
1228
- 50: P,
1229
- 52: F,
1230
- 53: I,
1231
- 55: L,
1232
- 60: R,
1233
- 61: z,
1234
- 62: B,
1235
- 63: V,
1236
- 71: H
1237
- },
1238
- {
1239
- 4: m,
1240
- 5: h,
1241
- 8: 8,
1242
- 9: 10,
1243
- 12: 12,
1244
- 13: g,
1245
- 14: _,
1246
- 16: [1, 139],
1247
- 17: 15,
1248
- 18: v,
1249
- 21: y,
1250
- 22: 40,
1251
- 23: b,
1252
- 24: 19,
1253
- 25: 20,
1254
- 26: 21,
1255
- 27: 22,
1256
- 28: 23,
1257
- 29: x,
1258
- 30: S,
1259
- 31: C,
1260
- 33: w,
1261
- 35: T,
1262
- 36: E,
1263
- 37: D,
1264
- 38: O,
1265
- 39: k,
1266
- 41: A,
1267
- 43: j,
1268
- 44: M,
1269
- 46: N,
1270
- 50: P,
1271
- 52: F,
1272
- 53: I,
1273
- 55: L,
1274
- 60: R,
1275
- 61: z,
1276
- 62: B,
1277
- 63: V,
1278
- 71: H
1279
- },
1280
- { 16: [1, 140] },
1281
- {
1282
- 4: m,
1283
- 5: h,
1284
- 8: 8,
1285
- 9: 10,
1286
- 12: 12,
1287
- 13: g,
1288
- 14: _,
1289
- 16: [2, 46],
1290
- 17: 15,
1291
- 18: v,
1292
- 21: y,
1293
- 22: 40,
1294
- 23: b,
1295
- 24: 19,
1296
- 25: 20,
1297
- 26: 21,
1298
- 27: 22,
1299
- 28: 23,
1300
- 29: x,
1301
- 30: S,
1302
- 31: C,
1303
- 33: w,
1304
- 35: T,
1305
- 36: E,
1306
- 37: D,
1307
- 38: O,
1308
- 39: k,
1309
- 41: A,
1310
- 43: j,
1311
- 44: M,
1312
- 46: N,
1313
- 49: [1, 141],
1314
- 50: P,
1315
- 52: F,
1316
- 53: I,
1317
- 55: L,
1318
- 60: R,
1319
- 61: z,
1320
- 62: B,
1321
- 63: V,
1322
- 71: H
1323
- },
1324
- { 16: [1, 142] },
1325
- {
1326
- 4: m,
1327
- 5: h,
1328
- 8: 8,
1329
- 9: 10,
1330
- 12: 12,
1331
- 13: g,
1332
- 14: _,
1333
- 16: [2, 44],
1334
- 17: 15,
1335
- 18: v,
1336
- 21: y,
1337
- 22: 40,
1338
- 23: b,
1339
- 24: 19,
1340
- 25: 20,
1341
- 26: 21,
1342
- 27: 22,
1343
- 28: 23,
1344
- 29: x,
1345
- 30: S,
1346
- 31: C,
1347
- 33: w,
1348
- 35: T,
1349
- 36: E,
1350
- 37: D,
1351
- 38: O,
1352
- 39: k,
1353
- 41: A,
1354
- 43: j,
1355
- 44: M,
1356
- 46: N,
1357
- 48: [1, 143],
1358
- 50: P,
1359
- 52: F,
1360
- 53: I,
1361
- 55: L,
1362
- 60: R,
1363
- 61: z,
1364
- 62: B,
1365
- 63: V,
1366
- 71: H
1367
- },
1368
- { 16: [1, 144] },
1369
- { 16: [1, 145] },
1370
- {
1371
- 4: m,
1372
- 5: h,
1373
- 8: 8,
1374
- 9: 10,
1375
- 12: 12,
1376
- 13: g,
1377
- 14: _,
1378
- 16: [2, 42],
1379
- 17: 15,
1380
- 18: v,
1381
- 21: y,
1382
- 22: 40,
1383
- 23: b,
1384
- 24: 19,
1385
- 25: 20,
1386
- 26: 21,
1387
- 27: 22,
1388
- 28: 23,
1389
- 29: x,
1390
- 30: S,
1391
- 31: C,
1392
- 33: w,
1393
- 35: T,
1394
- 36: E,
1395
- 37: D,
1396
- 38: O,
1397
- 39: k,
1398
- 41: A,
1399
- 43: j,
1400
- 44: M,
1401
- 46: N,
1402
- 47: [1, 146],
1403
- 50: P,
1404
- 52: F,
1405
- 53: I,
1406
- 55: L,
1407
- 60: R,
1408
- 61: z,
1409
- 62: B,
1410
- 63: V,
1411
- 71: H
1412
- },
1413
- {
1414
- 4: m,
1415
- 5: h,
1416
- 8: 8,
1417
- 9: 10,
1418
- 12: 12,
1419
- 13: g,
1420
- 14: _,
1421
- 16: [1, 147],
1422
- 17: 15,
1423
- 18: v,
1424
- 21: y,
1425
- 22: 40,
1426
- 23: b,
1427
- 24: 19,
1428
- 25: 20,
1429
- 26: 21,
1430
- 27: 22,
1431
- 28: 23,
1432
- 29: x,
1433
- 30: S,
1434
- 31: C,
1435
- 33: w,
1436
- 35: T,
1437
- 36: E,
1438
- 37: D,
1439
- 38: O,
1440
- 39: k,
1441
- 41: A,
1442
- 43: j,
1443
- 44: M,
1444
- 46: N,
1445
- 50: P,
1446
- 52: F,
1447
- 53: I,
1448
- 55: L,
1449
- 60: R,
1450
- 61: z,
1451
- 62: B,
1452
- 63: V,
1453
- 71: H
1454
- },
1455
- { 15: [1, 148] },
1456
- t(U, [2, 49]),
1457
- t(U, [2, 53]),
1458
- { 5: [2, 69] },
1459
- { 74: [1, 149] },
1460
- { 15: [1, 150] },
1461
- t(U, [2, 51]),
1462
- t(U, [2, 52]),
1463
- {
1464
- 22: 151,
1465
- 71: H
1466
- },
1467
- {
1468
- 22: 152,
1469
- 71: H
1470
- },
1471
- {
1472
- 57: 153,
1473
- 86: Z
1474
- },
1475
- {
1476
- 57: 154,
1477
- 86: Z
1478
- },
1479
- {
1480
- 57: 155,
1481
- 86: Z
1482
- },
1483
- {
1484
- 65: [1, 156],
1485
- 86: [2, 63]
1486
- },
1487
- { 5: [2, 56] },
1488
- { 5: [2, 82] },
1489
- { 5: [2, 57] },
1490
- { 5: [2, 58] },
1491
- { 5: [2, 59] },
1492
- t(U, [2, 16]),
1493
- t(G, [2, 10]),
1494
- {
1495
- 12: 157,
1496
- 50: P,
1497
- 52: F,
1498
- 53: I
1499
- },
1500
- t(G, [2, 12]),
1501
- t(G, [2, 13]),
1502
- t(U, [2, 18]),
1503
- t(U, [2, 34]),
1504
- t(U, [2, 35]),
1505
- t(U, [2, 36]),
1506
- t(U, [2, 37]),
1507
- { 15: [1, 158] },
1508
- t(U, [2, 38]),
1509
- { 15: [1, 159] },
1510
- t(U, [2, 39]),
1511
- t(U, [2, 40]),
1512
- { 15: [1, 160] },
1513
- t(U, [2, 41]),
1514
- { 5: [1, 161] },
1515
- { 75: [1, 162] },
1516
- { 5: [1, 163] },
1517
- {
1518
- 57: 164,
1519
- 86: Z
1520
- },
1521
- {
1522
- 57: 165,
1523
- 86: Z
1524
- },
1525
- { 5: [2, 68] },
1526
- { 5: [2, 54] },
1527
- { 5: [2, 55] },
1528
- {
1529
- 22: 166,
1530
- 71: H
1531
- },
1532
- t(G, [2, 11]),
1533
- t(q, p, {
1534
- 7: 105,
1535
- 40: 167
1536
- }),
1537
- t(J, p, {
1538
- 7: 107,
1539
- 42: 168
1540
- }),
1541
- t(Y, p, {
1542
- 7: 110,
1543
- 45: 169
1544
- }),
1545
- t(U, [2, 48]),
1546
- { 5: [2, 70] },
1547
- t(U, [2, 50]),
1548
- { 5: [2, 66] },
1549
- { 5: [2, 67] },
1550
- { 86: [2, 62] },
1551
- { 16: [2, 47] },
1552
- { 16: [2, 45] },
1553
- { 16: [2, 43] }
1554
- ],
1555
- defaultActions: {
1556
- 5: [2, 1],
1557
- 6: [2, 2],
1558
- 89: [2, 64],
1559
- 90: [2, 65],
1560
- 115: [2, 69],
1561
- 126: [2, 56],
1562
- 127: [2, 82],
1563
- 128: [2, 57],
1564
- 129: [2, 58],
1565
- 130: [2, 59],
1566
- 153: [2, 68],
1567
- 154: [2, 54],
1568
- 155: [2, 55],
1569
- 162: [2, 70],
1570
- 164: [2, 66],
1571
- 165: [2, 67],
1572
- 166: [2, 62],
1573
- 167: [2, 47],
1574
- 168: [2, 45],
1575
- 169: [2, 43]
1576
- },
1577
- parseError: /* @__PURE__ */ __name(function(t2, l2) {
1578
- if (l2.recoverable) this.trace(t2);
1579
- else {
1580
- var u2 = Error(t2);
1581
- throw u2.hash = l2, u2;
1582
- }
1583
- }, "parseError"),
1584
- parse: /* @__PURE__ */ __name(function(t2) {
1585
- var l2 = this, u2 = [0], d2 = [], p2 = [null], m2 = [], h2 = this.table, g2 = "", _2 = 0, v2 = 0, y2 = 0, b2 = 2, x2 = 1, S2 = m2.slice.call(arguments, 1), C2 = Object.create(this.lexer), w2 = { yy: {} };
1586
- for (var T2 in this.yy) Object.prototype.hasOwnProperty.call(this.yy, T2) && (w2.yy[T2] = this.yy[T2]);
1587
- C2.setInput(t2, w2.yy), w2.yy.lexer = C2, w2.yy.parser = this, C2.yylloc === void 0 && (C2.yylloc = {});
1588
- var E2 = C2.yylloc;
1589
- m2.push(E2);
1590
- var D2 = C2.options && C2.options.ranges;
1591
- typeof w2.yy.parseError == "function" ? this.parseError = w2.yy.parseError : this.parseError = Object.getPrototypeOf(this).parseError;
1592
- function O2(t3) {
1593
- u2.length -= 2 * t3, p2.length -= t3, m2.length -= t3;
1594
- }
1595
- __name(O2, "popStack");
1596
- function k2() {
1597
- var t3 = d2.pop() || C2.lex() || x2;
1598
- return typeof t3 != "number" && (t3 instanceof Array && (d2 = t3, t3 = d2.pop()), t3 = l2.symbols_[t3] || t3), t3;
1599
- }
1600
- __name(k2, "lex");
1601
- for (var A2, j2, M2, N2, P2, F2 = {}, I2, L2, R2, z2; ; ) {
1602
- if (M2 = u2[u2.length - 1], this.defaultActions[M2] ? N2 = this.defaultActions[M2] : (A2 ?? (A2 = k2()), N2 = h2[M2] && h2[M2][A2]), N2 === void 0 || !N2.length || !N2[0]) {
1603
- var B2 = "";
1604
- for (I2 in z2 = [], h2[M2]) this.terminals_[I2] && I2 > b2 && z2.push("'" + this.terminals_[I2] + "'");
1605
- B2 = C2.showPosition ? "Parse error on line " + (_2 + 1) + ":\n" + C2.showPosition() + "\nExpecting " + z2.join(", ") + ", got '" + (this.terminals_[A2] || A2) + "'" : "Parse error on line " + (_2 + 1) + ": Unexpected " + (A2 == x2 ? "end of input" : "'" + (this.terminals_[A2] || A2) + "'"), this.parseError(B2, {
1606
- text: C2.match,
1607
- token: this.terminals_[A2] || A2,
1608
- line: C2.yylineno,
1609
- loc: E2,
1610
- expected: z2
1611
- });
1612
- }
1613
- if (N2[0] instanceof Array && N2.length > 1) throw Error("Parse Error: multiple actions possible at state: " + M2 + ", token: " + A2);
1614
- switch (N2[0]) {
1615
- case 1:
1616
- u2.push(A2), p2.push(C2.yytext), m2.push(C2.yylloc), u2.push(N2[1]), A2 = null, j2 ? (A2 = j2, j2 = null) : (v2 = C2.yyleng, g2 = C2.yytext, _2 = C2.yylineno, E2 = C2.yylloc, y2 > 0 && y2--);
1617
- break;
1618
- case 2:
1619
- if (L2 = this.productions_[N2[1]][1], F2.$ = p2[p2.length - L2], F2._$ = {
1620
- first_line: m2[m2.length - (L2 || 1)].first_line,
1621
- last_line: m2[m2.length - 1].last_line,
1622
- first_column: m2[m2.length - (L2 || 1)].first_column,
1623
- last_column: m2[m2.length - 1].last_column
1624
- }, D2 && (F2._$.range = [m2[m2.length - (L2 || 1)].range[0], m2[m2.length - 1].range[1]]), P2 = this.performAction.apply(F2, [
1625
- g2,
1626
- v2,
1627
- _2,
1628
- w2.yy,
1629
- N2[1],
1630
- p2,
1631
- m2
1632
- ].concat(S2)), P2 !== void 0) return P2;
1633
- L2 && (u2 = u2.slice(0, -1 * L2 * 2), p2 = p2.slice(0, -1 * L2), m2 = m2.slice(0, -1 * L2)), u2.push(this.productions_[N2[1]][0]), p2.push(F2.$), m2.push(F2._$), R2 = h2[u2[u2.length - 2]][u2[u2.length - 1]], u2.push(R2);
1634
- break;
1635
- case 3:
1636
- return true;
1637
- }
1638
- }
1639
- return true;
1640
- }, "parse")
1641
- };
1642
- Q.lexer = /* @__PURE__ */ (function() {
1643
- return {
1644
- EOF: 1,
1645
- parseError: /* @__PURE__ */ __name(function(t2, l2) {
1646
- if (this.yy.parser) this.yy.parser.parseError(t2, l2);
1647
- else throw Error(t2);
1648
- }, "parseError"),
1649
- setInput: /* @__PURE__ */ __name(function(t2, l2) {
1650
- return this.yy = l2 || this.yy || {}, this._input = t2, this._more = this._backtrack = this.done = false, this.yylineno = this.yyleng = 0, this.yytext = this.matched = this.match = "", this.conditionStack = ["INITIAL"], this.yylloc = {
1651
- first_line: 1,
1652
- first_column: 0,
1653
- last_line: 1,
1654
- last_column: 0
1655
- }, this.options.ranges && (this.yylloc.range = [0, 0]), this.offset = 0, this;
1656
- }, "setInput"),
1657
- input: /* @__PURE__ */ __name(function() {
1658
- var t2 = this._input[0];
1659
- return this.yytext += t2, this.yyleng++, this.offset++, this.match += t2, this.matched += t2, t2.match(/(?:\r\n?|\n).*/g) ? (this.yylineno++, this.yylloc.last_line++) : this.yylloc.last_column++, this.options.ranges && this.yylloc.range[1]++, this._input = this._input.slice(1), t2;
1660
- }, "input"),
1661
- unput: /* @__PURE__ */ __name(function(t2) {
1662
- var l2 = t2.length, u2 = t2.split(/(?:\r\n?|\n)/g);
1663
- this._input = t2 + this._input, this.yytext = this.yytext.substr(0, this.yytext.length - l2), this.offset -= l2;
1664
- var d2 = this.match.split(/(?:\r\n?|\n)/g);
1665
- this.match = this.match.substr(0, this.match.length - 1), this.matched = this.matched.substr(0, this.matched.length - 1), u2.length - 1 && (this.yylineno -= u2.length - 1);
1666
- var f = this.yylloc.range;
1667
- return this.yylloc = {
1668
- first_line: this.yylloc.first_line,
1669
- last_line: this.yylineno + 1,
1670
- first_column: this.yylloc.first_column,
1671
- last_column: u2 ? (u2.length === d2.length ? this.yylloc.first_column : 0) + d2[d2.length - u2.length].length - u2[0].length : this.yylloc.first_column - l2
1672
- }, this.options.ranges && (this.yylloc.range = [f[0], f[0] + this.yyleng - l2]), this.yyleng = this.yytext.length, this;
1673
- }, "unput"),
1674
- more: /* @__PURE__ */ __name(function() {
1675
- return this._more = true, this;
1676
- }, "more"),
1677
- reject: /* @__PURE__ */ __name(function() {
1678
- if (this.options.backtrack_lexer) this._backtrack = true;
1679
- else return this.parseError("Lexical error on line " + (this.yylineno + 1) + ". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n" + this.showPosition(), {
1680
- text: "",
1681
- token: null,
1682
- line: this.yylineno
1683
- });
1684
- return this;
1685
- }, "reject"),
1686
- less: /* @__PURE__ */ __name(function(t2) {
1687
- this.unput(this.match.slice(t2));
1688
- }, "less"),
1689
- pastInput: /* @__PURE__ */ __name(function() {
1690
- var t2 = this.matched.substr(0, this.matched.length - this.match.length);
1691
- return (t2.length > 20 ? "..." : "") + t2.substr(-20).replace(/\n/g, "");
1692
- }, "pastInput"),
1693
- upcomingInput: /* @__PURE__ */ __name(function() {
1694
- var t2 = this.match;
1695
- return t2.length < 20 && (t2 += this._input.substr(0, 20 - t2.length)), (t2.substr(0, 20) + (t2.length > 20 ? "..." : "")).replace(/\n/g, "");
1696
- }, "upcomingInput"),
1697
- showPosition: /* @__PURE__ */ __name(function() {
1698
- var t2 = this.pastInput(), l2 = Array(t2.length + 1).join("-");
1699
- return t2 + this.upcomingInput() + "\n" + l2 + "^";
1700
- }, "showPosition"),
1701
- test_match: /* @__PURE__ */ __name(function(t2, l2) {
1702
- var u2, d2, f;
1703
- if (this.options.backtrack_lexer && (f = {
1704
- yylineno: this.yylineno,
1705
- yylloc: {
1706
- first_line: this.yylloc.first_line,
1707
- last_line: this.last_line,
1708
- first_column: this.yylloc.first_column,
1709
- last_column: this.yylloc.last_column
1710
- },
1711
- yytext: this.yytext,
1712
- match: this.match,
1713
- matches: this.matches,
1714
- matched: this.matched,
1715
- yyleng: this.yyleng,
1716
- offset: this.offset,
1717
- _more: this._more,
1718
- _input: this._input,
1719
- yy: this.yy,
1720
- conditionStack: this.conditionStack.slice(0),
1721
- done: this.done
1722
- }, this.options.ranges && (f.yylloc.range = this.yylloc.range.slice(0))), d2 = t2[0].match(/(?:\r\n?|\n).*/g), d2 && (this.yylineno += d2.length), this.yylloc = {
1723
- first_line: this.yylloc.last_line,
1724
- last_line: this.yylineno + 1,
1725
- first_column: this.yylloc.last_column,
1726
- last_column: d2 ? d2[d2.length - 1].length - d2[d2.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + t2[0].length
1727
- }, this.yytext += t2[0], this.match += t2[0], this.matches = t2, this.yyleng = this.yytext.length, this.options.ranges && (this.yylloc.range = [this.offset, this.offset += this.yyleng]), this._more = false, this._backtrack = false, this._input = this._input.slice(t2[0].length), this.matched += t2[0], u2 = this.performAction.call(this, this.yy, this, l2, this.conditionStack[this.conditionStack.length - 1]), this.done && this._input && (this.done = false), u2) return u2;
1728
- if (this._backtrack) {
1729
- for (var p2 in f) this[p2] = f[p2];
1730
- return false;
1731
- }
1732
- return false;
1733
- }, "test_match"),
1734
- next: /* @__PURE__ */ __name(function() {
1735
- if (this.done) return this.EOF;
1736
- this._input || (this.done = true);
1737
- var t2, l2, u2, d2;
1738
- this._more || (this.yytext = "", this.match = "");
1739
- for (var f = this._currentRules(), p2 = 0; p2 < f.length; p2++) if (u2 = this._input.match(this.rules[f[p2]]), u2 && (!l2 || u2[0].length > l2[0].length)) {
1740
- if (l2 = u2, d2 = p2, this.options.backtrack_lexer) {
1741
- if (t2 = this.test_match(u2, f[p2]), t2 !== false) return t2;
1742
- if (this._backtrack) {
1743
- l2 = false;
1744
- continue;
1745
- } else return false;
1746
- } else if (!this.options.flex) break;
1747
- }
1748
- return l2 ? (t2 = this.test_match(l2, f[d2]), t2 === false ? false : t2) : this._input === "" ? this.EOF : this.parseError("Lexical error on line " + (this.yylineno + 1) + ". Unrecognized text.\n" + this.showPosition(), {
1749
- text: "",
1750
- token: null,
1751
- line: this.yylineno
1752
- });
1753
- }, "next"),
1754
- lex: /* @__PURE__ */ __name(function() {
1755
- return this.next() || this.lex();
1756
- }, "lex"),
1757
- begin: /* @__PURE__ */ __name(function(t2) {
1758
- this.conditionStack.push(t2);
1759
- }, "begin"),
1760
- popState: /* @__PURE__ */ __name(function() {
1761
- return this.conditionStack.length - 1 > 0 ? this.conditionStack.pop() : this.conditionStack[0];
1762
- }, "popState"),
1763
- _currentRules: /* @__PURE__ */ __name(function() {
1764
- return this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1] ? this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules : this.conditions.INITIAL.rules;
1765
- }, "_currentRules"),
1766
- topState: /* @__PURE__ */ __name(function(t2) {
1767
- return t2 = this.conditionStack.length - 1 - Math.abs(t2 || 0), t2 >= 0 ? this.conditionStack[t2] : "INITIAL";
1768
- }, "topState"),
1769
- pushState: /* @__PURE__ */ __name(function(t2) {
1770
- this.begin(t2);
1771
- }, "pushState"),
1772
- stateStackSize: /* @__PURE__ */ __name(function() {
1773
- return this.conditionStack.length;
1774
- }, "stateStackSize"),
1775
- options: { "case-insensitive": true },
1776
- performAction: /* @__PURE__ */ __name(function(t2, l2, u2, d2) {
1777
- switch (u2) {
1778
- case 0:
1779
- return 5;
1780
- case 1:
1781
- break;
1782
- case 2:
1783
- break;
1784
- case 3:
1785
- break;
1786
- case 4:
1787
- break;
1788
- case 5:
1789
- break;
1790
- case 6:
1791
- return 19;
1792
- case 7:
1793
- return this.begin("CONFIG"), 73;
1794
- case 8:
1795
- return 74;
1796
- case 9:
1797
- return this.popState(), this.popState(), 75;
1798
- case 10:
1799
- return l2.yytext = l2.yytext.trim(), 71;
1800
- case 11:
1801
- return l2.yytext = l2.yytext.trim(), this.begin("ALIAS"), 71;
1802
- case 12:
1803
- return this.begin("LINE"), 14;
1804
- case 13:
1805
- return this.begin("ID"), 50;
1806
- case 14:
1807
- return this.begin("ID"), 52;
1808
- case 15:
1809
- return 13;
1810
- case 16:
1811
- return this.begin("ID"), 53;
1812
- case 17:
1813
- return l2.yytext = l2.yytext.trim(), this.begin("ALIAS"), 71;
1814
- case 18:
1815
- return this.popState(), this.popState(), this.begin("LINE"), 51;
1816
- case 19:
1817
- return this.popState(), this.popState(), 5;
1818
- case 20:
1819
- return this.begin("LINE"), 36;
1820
- case 21:
1821
- return this.begin("LINE"), 37;
1822
- case 22:
1823
- return this.begin("LINE"), 38;
1824
- case 23:
1825
- return this.begin("LINE"), 39;
1826
- case 24:
1827
- return this.begin("LINE"), 49;
1828
- case 25:
1829
- return this.begin("LINE"), 41;
1830
- case 26:
1831
- return this.begin("LINE"), 43;
1832
- case 27:
1833
- return this.begin("LINE"), 48;
1834
- case 28:
1835
- return this.begin("LINE"), 44;
1836
- case 29:
1837
- return this.begin("LINE"), 47;
1838
- case 30:
1839
- return this.begin("LINE"), 46;
1840
- case 31:
1841
- return this.popState(), 15;
1842
- case 32:
1843
- return 16;
1844
- case 33:
1845
- return 66;
1846
- case 34:
1847
- return 67;
1848
- case 35:
1849
- return 60;
1850
- case 36:
1851
- return 61;
1852
- case 37:
1853
- return 62;
1854
- case 38:
1855
- return 63;
1856
- case 39:
1857
- return 58;
1858
- case 40:
1859
- return 55;
1860
- case 41:
1861
- return this.begin("ID"), 21;
1862
- case 42:
1863
- return this.begin("ID"), 23;
1864
- case 43:
1865
- return 29;
1866
- case 44:
1867
- return 30;
1868
- case 45:
1869
- return this.begin("acc_title"), 31;
1870
- case 46:
1871
- return this.popState(), "acc_title_value";
1872
- case 47:
1873
- return this.begin("acc_descr"), 33;
1874
- case 48:
1875
- return this.popState(), "acc_descr_value";
1876
- case 49:
1877
- this.begin("acc_descr_multiline");
1878
- break;
1879
- case 50:
1880
- this.popState();
1881
- break;
1882
- case 51:
1883
- return "acc_descr_multiline_value";
1884
- case 52:
1885
- return 6;
1886
- case 53:
1887
- return 18;
1888
- case 54:
1889
- return 20;
1890
- case 55:
1891
- return 65;
1892
- case 56:
1893
- return 5;
1894
- case 57:
1895
- return l2.yytext = l2.yytext.trim(), 71;
1896
- case 58:
1897
- return 78;
1898
- case 59:
1899
- return 79;
1900
- case 60:
1901
- return 80;
1902
- case 61:
1903
- return 81;
1904
- case 62:
1905
- return 76;
1906
- case 63:
1907
- return 77;
1908
- case 64:
1909
- return 82;
1910
- case 65:
1911
- return 83;
1912
- case 66:
1913
- return 84;
1914
- case 67:
1915
- return 85;
1916
- case 68:
1917
- return 86;
1918
- case 69:
1919
- return 86;
1920
- case 70:
1921
- return 69;
1922
- case 71:
1923
- return 70;
1924
- case 72:
1925
- return 5;
1926
- case 73:
1927
- return "INVALID";
1928
- }
1929
- }, "anonymous"),
1930
- rules: [
1931
- /^(?:[\n]+)/i,
1932
- /^(?:\s+)/i,
1933
- /^(?:((?!\n)\s)+)/i,
1934
- /^(?:#[^\n]*)/i,
1935
- /^(?:%(?!\{)[^\n]*)/i,
1936
- /^(?:[^\}]%%[^\n]*)/i,
1937
- /^(?:[0-9]+(?=[ \n]+))/i,
1938
- /^(?:@\{)/i,
1939
- /^(?:[^\}]+)/i,
1940
- /^(?:\})/i,
1941
- /^(?:[^\<->\->:\n,;@\s]+(?=@\{))/i,
1942
- /^(?:[^\<->\->:\n,;@]+?([\-]*[^\<->\->:\n,;@]+?)*?(?=((?!\n)\s)+as(?!\n)\s|[#\n;]|$))/i,
1943
- /^(?:box\b)/i,
1944
- /^(?:participant\b)/i,
1945
- /^(?:actor\b)/i,
1946
- /^(?:create\b)/i,
1947
- /^(?:destroy\b)/i,
1948
- /^(?:[^<\->\->:\n,;]+?([\-]*[^<\->\->:\n,;]+?)*?(?=((?!\n)\s)+as(?!\n)\s|[#\n;]|$))/i,
1949
- /^(?:as\b)/i,
1950
- /^(?:(?:))/i,
1951
- /^(?:loop\b)/i,
1952
- /^(?:rect\b)/i,
1953
- /^(?:opt\b)/i,
1954
- /^(?:alt\b)/i,
1955
- /^(?:else\b)/i,
1956
- /^(?:par\b)/i,
1957
- /^(?:par_over\b)/i,
1958
- /^(?:and\b)/i,
1959
- /^(?:critical\b)/i,
1960
- /^(?:option\b)/i,
1961
- /^(?:break\b)/i,
1962
- /^(?:(?:[:]?(?:no)?wrap)?[^#\n;]*)/i,
1963
- /^(?:end\b)/i,
1964
- /^(?:left of\b)/i,
1965
- /^(?:right of\b)/i,
1966
- /^(?:links\b)/i,
1967
- /^(?:link\b)/i,
1968
- /^(?:properties\b)/i,
1969
- /^(?:details\b)/i,
1970
- /^(?:over\b)/i,
1971
- /^(?:note\b)/i,
1972
- /^(?:activate\b)/i,
1973
- /^(?:deactivate\b)/i,
1974
- /^(?:title\s[^#\n;]+)/i,
1975
- /^(?:title:\s[^#\n;]+)/i,
1976
- /^(?:accTitle\s*:\s*)/i,
1977
- /^(?:(?!\n||)*[^\n]*)/i,
1978
- /^(?:accDescr\s*:\s*)/i,
1979
- /^(?:(?!\n||)*[^\n]*)/i,
1980
- /^(?:accDescr\s*\{\s*)/i,
1981
- /^(?:[\}])/i,
1982
- /^(?:[^\}]*)/i,
1983
- /^(?:sequenceDiagram\b)/i,
1984
- /^(?:autonumber\b)/i,
1985
- /^(?:off\b)/i,
1986
- /^(?:,)/i,
1987
- /^(?:;)/i,
1988
- /^(?:[^+<\->\->:\n,;]+((?!(-x|--x|-\)|--\)))[\-]*[^\+<\->\->:\n,;]+)*)/i,
1989
- /^(?:->>)/i,
1990
- /^(?:<<->>)/i,
1991
- /^(?:-->>)/i,
1992
- /^(?:<<-->>)/i,
1993
- /^(?:->)/i,
1994
- /^(?:-->)/i,
1995
- /^(?:-[x])/i,
1996
- /^(?:--[x])/i,
1997
- /^(?:-[\)])/i,
1998
- /^(?:--[\)])/i,
1999
- /^(?::(?:(?:no)?wrap)?[^#\n;]*)/i,
2000
- /^(?::)/i,
2001
- /^(?:\+)/i,
2002
- /^(?:-)/i,
2003
- /^(?:$)/i,
2004
- /^(?:.)/i
2005
- ],
2006
- conditions: {
2007
- acc_descr_multiline: {
2008
- rules: [50, 51],
2009
- inclusive: false
2010
- },
2011
- acc_descr: {
2012
- rules: [48],
2013
- inclusive: false
2014
- },
2015
- acc_title: {
2016
- rules: [46],
2017
- inclusive: false
2018
- },
2019
- ID: {
2020
- rules: [
2021
- 2,
2022
- 3,
2023
- 7,
2024
- 10,
2025
- 11,
2026
- 17
2027
- ],
2028
- inclusive: false
2029
- },
2030
- ALIAS: {
2031
- rules: [
2032
- 2,
2033
- 3,
2034
- 18,
2035
- 19
2036
- ],
2037
- inclusive: false
2038
- },
2039
- LINE: {
2040
- rules: [
2041
- 2,
2042
- 3,
2043
- 31
2044
- ],
2045
- inclusive: false
2046
- },
2047
- CONFIG: {
2048
- rules: [8, 9],
2049
- inclusive: false
2050
- },
2051
- CONFIG_DATA: {
2052
- rules: [],
2053
- inclusive: false
2054
- },
2055
- INITIAL: {
2056
- rules: [
2057
- 0,
2058
- 1,
2059
- 3,
2060
- 4,
2061
- 5,
2062
- 6,
2063
- 12,
2064
- 13,
2065
- 14,
2066
- 15,
2067
- 16,
2068
- 20,
2069
- 21,
2070
- 22,
2071
- 23,
2072
- 24,
2073
- 25,
2074
- 26,
2075
- 27,
2076
- 28,
2077
- 29,
2078
- 30,
2079
- 32,
2080
- 33,
2081
- 34,
2082
- 35,
2083
- 36,
2084
- 37,
2085
- 38,
2086
- 39,
2087
- 40,
2088
- 41,
2089
- 42,
2090
- 43,
2091
- 44,
2092
- 45,
2093
- 47,
2094
- 49,
2095
- 52,
2096
- 53,
2097
- 54,
2098
- 55,
2099
- 56,
2100
- 57,
2101
- 58,
2102
- 59,
2103
- 60,
2104
- 61,
2105
- 62,
2106
- 63,
2107
- 64,
2108
- 65,
2109
- 66,
2110
- 67,
2111
- 68,
2112
- 69,
2113
- 70,
2114
- 71,
2115
- 72,
2116
- 73
2117
- ],
2118
- inclusive: true
2119
- }
2120
- }
2121
- };
2122
- })();
2123
- function $() {
2124
- this.yy = {};
2125
- }
2126
- return __name($, "Parser"), $.prototype = Q, Q.Parser = $, new $();
2127
- })();
2128
- parser.parser = parser;
2129
- var sequenceDiagram_default = parser, LINETYPE = {
2130
- SOLID: 0,
2131
- DOTTED: 1,
2132
- NOTE: 2,
2133
- SOLID_CROSS: 3,
2134
- DOTTED_CROSS: 4,
2135
- SOLID_OPEN: 5,
2136
- DOTTED_OPEN: 6,
2137
- LOOP_START: 10,
2138
- LOOP_END: 11,
2139
- ALT_START: 12,
2140
- ALT_ELSE: 13,
2141
- ALT_END: 14,
2142
- OPT_START: 15,
2143
- OPT_END: 16,
2144
- ACTIVE_START: 17,
2145
- ACTIVE_END: 18,
2146
- PAR_START: 19,
2147
- PAR_AND: 20,
2148
- PAR_END: 21,
2149
- RECT_START: 22,
2150
- RECT_END: 23,
2151
- SOLID_POINT: 24,
2152
- DOTTED_POINT: 25,
2153
- AUTONUMBER: 26,
2154
- CRITICAL_START: 27,
2155
- CRITICAL_OPTION: 28,
2156
- CRITICAL_END: 29,
2157
- BREAK_START: 30,
2158
- BREAK_END: 31,
2159
- PAR_OVER_START: 32,
2160
- BIDIRECTIONAL_SOLID: 33,
2161
- BIDIRECTIONAL_DOTTED: 34
2162
- }, ARROWTYPE = {
2163
- FILLED: 0,
2164
- OPEN: 1
2165
- }, PLACEMENT = {
2166
- LEFTOF: 0,
2167
- RIGHTOF: 1,
2168
- OVER: 2
2169
- }, PARTICIPANT_TYPE = {
2170
- ACTOR: "actor",
2171
- BOUNDARY: "boundary",
2172
- COLLECTIONS: "collections",
2173
- CONTROL: "control",
2174
- DATABASE: "database",
2175
- ENTITY: "entity",
2176
- PARTICIPANT: "participant",
2177
- QUEUE: "queue"
2178
- }, SequenceDB = (_a = class {
2179
- constructor() {
2180
- this.state = new ImperativeState(() => ({
2181
- prevActor: void 0,
2182
- actors: /* @__PURE__ */ new Map(),
2183
- createdActors: /* @__PURE__ */ new Map(),
2184
- destroyedActors: /* @__PURE__ */ new Map(),
2185
- boxes: [],
2186
- messages: [],
2187
- notes: [],
2188
- sequenceNumbersEnabled: false,
2189
- wrapEnabled: void 0,
2190
- currentBox: void 0,
2191
- lastCreated: void 0,
2192
- lastDestroyed: void 0
2193
- })), this.setAccTitle = setAccTitle, this.setAccDescription = setAccDescription, this.setDiagramTitle = setDiagramTitle, this.getAccTitle = getAccTitle, this.getAccDescription = getAccDescription, this.getDiagramTitle = getDiagramTitle, this.apply = this.apply.bind(this), this.parseBoxData = this.parseBoxData.bind(this), this.parseMessage = this.parseMessage.bind(this), this.clear(), this.setWrap(getConfig2().wrap), this.LINETYPE = LINETYPE, this.ARROWTYPE = ARROWTYPE, this.PLACEMENT = PLACEMENT;
2194
- }
2195
- addBox(t) {
2196
- this.state.records.boxes.push({
2197
- name: t.text,
2198
- wrap: t.wrap ?? this.autoWrap(),
2199
- fill: t.color,
2200
- actorKeys: []
2201
- }), this.state.records.currentBox = this.state.records.boxes.slice(-1)[0];
2202
- }
2203
- addActor(t, l, u, d, f) {
2204
- let p = this.state.records.currentBox, m;
2205
- if (f !== void 0) {
2206
- let t2;
2207
- t2 = f.includes("\n") ? f + "\n" : "{\n" + f + "\n}", m = load(t2, { schema: JSON_SCHEMA });
2208
- }
2209
- d = (m == null ? void 0 : m.type) ?? d;
2210
- let h = this.state.records.actors.get(t);
2211
- if (h) {
2212
- if (this.state.records.currentBox && h.box && this.state.records.currentBox !== h.box) throw Error(`A same participant should only be defined in one Box: ${h.name} can't be in '${h.box.name}' and in '${this.state.records.currentBox.name}' at the same time.`);
2213
- if (p = h.box ? h.box : this.state.records.currentBox, h.box = p, h && l === h.name && u == null) return;
2214
- }
2215
- if ((u == null ? void 0 : u.text) ?? (u = {
2216
- text: l,
2217
- type: d
2218
- }), (d == null || u.text == null) && (u = {
2219
- text: l,
2220
- type: d
2221
- }), this.state.records.actors.set(t, {
2222
- box: p,
2223
- name: l,
2224
- description: u.text,
2225
- wrap: u.wrap ?? this.autoWrap(),
2226
- prevActor: this.state.records.prevActor,
2227
- links: {},
2228
- properties: {},
2229
- actorCnt: null,
2230
- rectData: null,
2231
- type: d ?? "participant"
2232
- }), this.state.records.prevActor) {
2233
- let l2 = this.state.records.actors.get(this.state.records.prevActor);
2234
- l2 && (l2.nextActor = t);
2235
- }
2236
- this.state.records.currentBox && this.state.records.currentBox.actorKeys.push(t), this.state.records.prevActor = t;
2237
- }
2238
- activationCount(t) {
2239
- let l, u = 0;
2240
- if (!t) return 0;
2241
- for (l = 0; l < this.state.records.messages.length; l++) this.state.records.messages[l].type === this.LINETYPE.ACTIVE_START && this.state.records.messages[l].from === t && u++, this.state.records.messages[l].type === this.LINETYPE.ACTIVE_END && this.state.records.messages[l].from === t && u--;
2242
- return u;
2243
- }
2244
- addMessage(t, l, u, d) {
2245
- this.state.records.messages.push({
2246
- id: this.state.records.messages.length.toString(),
2247
- from: t,
2248
- to: l,
2249
- message: u.text,
2250
- wrap: u.wrap ?? this.autoWrap(),
2251
- answer: d
2252
- });
2253
- }
2254
- addSignal(t, l, u, d, f = false) {
2255
- if (d === this.LINETYPE.ACTIVE_END && this.activationCount(t ?? "") < 1) {
2256
- let l2 = /* @__PURE__ */ Error("Trying to inactivate an inactive participant (" + t + ")");
2257
- throw l2.hash = {
2258
- text: "->>-",
2259
- token: "->>-",
2260
- line: "1",
2261
- loc: {
2262
- first_line: 1,
2263
- last_line: 1,
2264
- first_column: 1,
2265
- last_column: 1
2266
- },
2267
- expected: ["'ACTIVE_PARTICIPANT'"]
2268
- }, l2;
2269
- }
2270
- return this.state.records.messages.push({
2271
- id: this.state.records.messages.length.toString(),
2272
- from: t,
2273
- to: l,
2274
- message: (u == null ? void 0 : u.text) ?? "",
2275
- wrap: (u == null ? void 0 : u.wrap) ?? this.autoWrap(),
2276
- type: d,
2277
- activate: f
2278
- }), true;
2279
- }
2280
- hasAtLeastOneBox() {
2281
- return this.state.records.boxes.length > 0;
2282
- }
2283
- hasAtLeastOneBoxWithTitle() {
2284
- return this.state.records.boxes.some((t) => t.name);
2285
- }
2286
- getMessages() {
2287
- return this.state.records.messages;
2288
- }
2289
- getBoxes() {
2290
- return this.state.records.boxes;
2291
- }
2292
- getActors() {
2293
- return this.state.records.actors;
2294
- }
2295
- getCreatedActors() {
2296
- return this.state.records.createdActors;
2297
- }
2298
- getDestroyedActors() {
2299
- return this.state.records.destroyedActors;
2300
- }
2301
- getActor(t) {
2302
- return this.state.records.actors.get(t);
2303
- }
2304
- getActorKeys() {
2305
- return [...this.state.records.actors.keys()];
2306
- }
2307
- enableSequenceNumbers() {
2308
- this.state.records.sequenceNumbersEnabled = true;
2309
- }
2310
- disableSequenceNumbers() {
2311
- this.state.records.sequenceNumbersEnabled = false;
2312
- }
2313
- showSequenceNumbers() {
2314
- return this.state.records.sequenceNumbersEnabled;
2315
- }
2316
- setWrap(t) {
2317
- this.state.records.wrapEnabled = t;
2318
- }
2319
- extractWrap(t) {
2320
- if (t === void 0) return {};
2321
- t = t.trim();
2322
- let l = /^:?wrap:/.exec(t) === null ? /^:?nowrap:/.exec(t) === null ? void 0 : false : true;
2323
- return {
2324
- cleanedText: (l === void 0 ? t : t.replace(/^:?(?:no)?wrap:/, "")).trim(),
2325
- wrap: l
2326
- };
2327
- }
2328
- autoWrap() {
2329
- var _a2;
2330
- return this.state.records.wrapEnabled === void 0 ? ((_a2 = getConfig2().sequence) == null ? void 0 : _a2.wrap) ?? false : this.state.records.wrapEnabled;
2331
- }
2332
- clear() {
2333
- this.state.reset(), clear();
2334
- }
2335
- parseMessage(t) {
2336
- let l = t.trim(), { wrap: u, cleanedText: f } = this.extractWrap(l), p = {
2337
- text: f,
2338
- wrap: u
2339
- };
2340
- return log.debug(`parseMessage: ${JSON.stringify(p)}`), p;
2341
- }
2342
- parseBoxData(t) {
2343
- let l = /^((?:rgba?|hsla?)\s*\(.*\)|\w*)(.*)$/.exec(t), u = (l == null ? void 0 : l[1]) ? l[1].trim() : "transparent", d = (l == null ? void 0 : l[2]) ? l[2].trim() : void 0;
2344
- if (window == null ? void 0 : window.CSS) window.CSS.supports("color", u) || (u = "transparent", d = t.trim());
2345
- else {
2346
- let l2 = new Option().style;
2347
- l2.color = u, l2.color !== u && (u = "transparent", d = t.trim());
2348
- }
2349
- let { wrap: f, cleanedText: p } = this.extractWrap(d);
2350
- return {
2351
- text: p ? sanitizeText(p, getConfig2()) : void 0,
2352
- color: u,
2353
- wrap: f
2354
- };
2355
- }
2356
- addNote(t, l, u) {
2357
- let d = {
2358
- actor: t,
2359
- placement: l,
2360
- message: u.text,
2361
- wrap: u.wrap ?? this.autoWrap()
2362
- }, f = [].concat(t, t);
2363
- this.state.records.notes.push(d), this.state.records.messages.push({
2364
- id: this.state.records.messages.length.toString(),
2365
- from: f[0],
2366
- to: f[1],
2367
- message: u.text,
2368
- wrap: u.wrap ?? this.autoWrap(),
2369
- type: this.LINETYPE.NOTE,
2370
- placement: l
2371
- });
2372
- }
2373
- addLinks(t, l) {
2374
- let u = this.getActor(t);
2375
- try {
2376
- let t2 = sanitizeText(l.text, getConfig2());
2377
- t2 = t2.replace(/&equals;/g, "="), t2 = t2.replace(/&amp;/g, "&");
2378
- let d = JSON.parse(t2);
2379
- this.insertLinks(u, d);
2380
- } catch (t2) {
2381
- log.error("error while parsing actor link text", t2);
2382
- }
2383
- }
2384
- addALink(t, l) {
2385
- let u = this.getActor(t);
2386
- try {
2387
- let t2 = {}, d = sanitizeText(l.text, getConfig2()), f = d.indexOf("@");
2388
- d = d.replace(/&equals;/g, "="), d = d.replace(/&amp;/g, "&");
2389
- let p = d.slice(0, f - 1).trim();
2390
- t2[p] = d.slice(f + 1).trim(), this.insertLinks(u, t2);
2391
- } catch (t2) {
2392
- log.error("error while parsing actor link text", t2);
2393
- }
2394
- }
2395
- insertLinks(t, l) {
2396
- if (t.links == null) t.links = l;
2397
- else for (let u in l) t.links[u] = l[u];
2398
- }
2399
- addProperties(t, l) {
2400
- let u = this.getActor(t);
2401
- try {
2402
- let t2 = sanitizeText(l.text, getConfig2()), d = JSON.parse(t2);
2403
- this.insertProperties(u, d);
2404
- } catch (t2) {
2405
- log.error("error while parsing actor properties text", t2);
2406
- }
2407
- }
2408
- insertProperties(t, l) {
2409
- if (t.properties == null) t.properties = l;
2410
- else for (let u in l) t.properties[u] = l[u];
2411
- }
2412
- boxEnd() {
2413
- this.state.records.currentBox = void 0;
2414
- }
2415
- addDetails(t, l) {
2416
- let u = this.getActor(t), f = document.getElementById(l.text);
2417
- try {
2418
- let t2 = f.innerHTML, l2 = JSON.parse(t2);
2419
- l2.properties && this.insertProperties(u, l2.properties), l2.links && this.insertLinks(u, l2.links);
2420
- } catch (t2) {
2421
- log.error("error while parsing actor details text", t2);
2422
- }
2423
- }
2424
- getActorProperty(t, l) {
2425
- if ((t == null ? void 0 : t.properties) !== void 0) return t.properties[l];
2426
- }
2427
- apply(t) {
2428
- if (Array.isArray(t)) t.forEach((t2) => {
2429
- this.apply(t2);
2430
- });
2431
- else switch (t.type) {
2432
- case "sequenceIndex":
2433
- this.state.records.messages.push({
2434
- id: this.state.records.messages.length.toString(),
2435
- from: void 0,
2436
- to: void 0,
2437
- message: {
2438
- start: t.sequenceIndex,
2439
- step: t.sequenceIndexStep,
2440
- visible: t.sequenceVisible
2441
- },
2442
- wrap: false,
2443
- type: t.signalType
2444
- });
2445
- break;
2446
- case "addParticipant":
2447
- this.addActor(t.actor, t.actor, t.description, t.draw, t.config);
2448
- break;
2449
- case "createParticipant":
2450
- if (this.state.records.actors.has(t.actor)) throw Error("It is not possible to have actors with the same id, even if one is destroyed before the next is created. Use 'AS' aliases to simulate the behavior");
2451
- this.state.records.lastCreated = t.actor, this.addActor(t.actor, t.actor, t.description, t.draw, t.config), this.state.records.createdActors.set(t.actor, this.state.records.messages.length);
2452
- break;
2453
- case "destroyParticipant":
2454
- this.state.records.lastDestroyed = t.actor, this.state.records.destroyedActors.set(t.actor, this.state.records.messages.length);
2455
- break;
2456
- case "activeStart":
2457
- this.addSignal(t.actor, void 0, void 0, t.signalType);
2458
- break;
2459
- case "activeEnd":
2460
- this.addSignal(t.actor, void 0, void 0, t.signalType);
2461
- break;
2462
- case "addNote":
2463
- this.addNote(t.actor, t.placement, t.text);
2464
- break;
2465
- case "addLinks":
2466
- this.addLinks(t.actor, t.text);
2467
- break;
2468
- case "addALink":
2469
- this.addALink(t.actor, t.text);
2470
- break;
2471
- case "addProperties":
2472
- this.addProperties(t.actor, t.text);
2473
- break;
2474
- case "addDetails":
2475
- this.addDetails(t.actor, t.text);
2476
- break;
2477
- case "addMessage":
2478
- if (this.state.records.lastCreated) {
2479
- if (t.to !== this.state.records.lastCreated) throw Error("The created participant " + this.state.records.lastCreated.name + " does not have an associated creating message after its declaration. Please check the sequence diagram.");
2480
- this.state.records.lastCreated = void 0;
2481
- } else if (this.state.records.lastDestroyed) {
2482
- if (t.to !== this.state.records.lastDestroyed && t.from !== this.state.records.lastDestroyed) throw Error("The destroyed participant " + this.state.records.lastDestroyed.name + " does not have an associated destroying message after its declaration. Please check the sequence diagram.");
2483
- this.state.records.lastDestroyed = void 0;
2484
- }
2485
- this.addSignal(t.from, t.to, t.msg, t.signalType, t.activate);
2486
- break;
2487
- case "boxStart":
2488
- this.addBox(t.boxData);
2489
- break;
2490
- case "boxEnd":
2491
- this.boxEnd();
2492
- break;
2493
- case "loopStart":
2494
- this.addSignal(void 0, void 0, t.loopText, t.signalType);
2495
- break;
2496
- case "loopEnd":
2497
- this.addSignal(void 0, void 0, void 0, t.signalType);
2498
- break;
2499
- case "rectStart":
2500
- this.addSignal(void 0, void 0, t.color, t.signalType);
2501
- break;
2502
- case "rectEnd":
2503
- this.addSignal(void 0, void 0, void 0, t.signalType);
2504
- break;
2505
- case "optStart":
2506
- this.addSignal(void 0, void 0, t.optText, t.signalType);
2507
- break;
2508
- case "optEnd":
2509
- this.addSignal(void 0, void 0, void 0, t.signalType);
2510
- break;
2511
- case "altStart":
2512
- this.addSignal(void 0, void 0, t.altText, t.signalType);
2513
- break;
2514
- case "else":
2515
- this.addSignal(void 0, void 0, t.altText, t.signalType);
2516
- break;
2517
- case "altEnd":
2518
- this.addSignal(void 0, void 0, void 0, t.signalType);
2519
- break;
2520
- case "setAccTitle":
2521
- setAccTitle(t.text);
2522
- break;
2523
- case "parStart":
2524
- this.addSignal(void 0, void 0, t.parText, t.signalType);
2525
- break;
2526
- case "and":
2527
- this.addSignal(void 0, void 0, t.parText, t.signalType);
2528
- break;
2529
- case "parEnd":
2530
- this.addSignal(void 0, void 0, void 0, t.signalType);
2531
- break;
2532
- case "criticalStart":
2533
- this.addSignal(void 0, void 0, t.criticalText, t.signalType);
2534
- break;
2535
- case "option":
2536
- this.addSignal(void 0, void 0, t.optionText, t.signalType);
2537
- break;
2538
- case "criticalEnd":
2539
- this.addSignal(void 0, void 0, void 0, t.signalType);
2540
- break;
2541
- case "breakStart":
2542
- this.addSignal(void 0, void 0, t.breakText, t.signalType);
2543
- break;
2544
- case "breakEnd":
2545
- this.addSignal(void 0, void 0, void 0, t.signalType);
2546
- break;
2547
- }
2548
- }
2549
- getConfig() {
2550
- return getConfig2().sequence;
2551
- }
2552
- }, __name(_a, "SequenceDB"), _a), styles_default = /* @__PURE__ */ __name((t) => `.actor {
2553
- stroke: ${t.actorBorder};
2554
- fill: ${t.actorBkg};
2555
- }
2556
-
2557
- text.actor > tspan {
2558
- fill: ${t.actorTextColor};
2559
- stroke: none;
2560
- }
2561
-
2562
- .actor-line {
2563
- stroke: ${t.actorLineColor};
2564
- }
2565
-
2566
- .innerArc {
2567
- stroke-width: 1.5;
2568
- stroke-dasharray: none;
2569
- }
2570
-
2571
- .messageLine0 {
2572
- stroke-width: 1.5;
2573
- stroke-dasharray: none;
2574
- stroke: ${t.signalColor};
2575
- }
2576
-
2577
- .messageLine1 {
2578
- stroke-width: 1.5;
2579
- stroke-dasharray: 2, 2;
2580
- stroke: ${t.signalColor};
2581
- }
2582
-
2583
- #arrowhead path {
2584
- fill: ${t.signalColor};
2585
- stroke: ${t.signalColor};
2586
- }
2587
-
2588
- .sequenceNumber {
2589
- fill: ${t.sequenceNumberColor};
2590
- }
2591
-
2592
- #sequencenumber {
2593
- fill: ${t.signalColor};
2594
- }
2595
-
2596
- #crosshead path {
2597
- fill: ${t.signalColor};
2598
- stroke: ${t.signalColor};
2599
- }
2600
-
2601
- .messageText {
2602
- fill: ${t.signalTextColor};
2603
- stroke: none;
2604
- }
2605
-
2606
- .labelBox {
2607
- stroke: ${t.labelBoxBorderColor};
2608
- fill: ${t.labelBoxBkgColor};
2609
- }
2610
-
2611
- .labelText, .labelText > tspan {
2612
- fill: ${t.labelTextColor};
2613
- stroke: none;
2614
- }
2615
-
2616
- .loopText, .loopText > tspan {
2617
- fill: ${t.loopTextColor};
2618
- stroke: none;
2619
- }
2620
-
2621
- .loopLine {
2622
- stroke-width: 2px;
2623
- stroke-dasharray: 2, 2;
2624
- stroke: ${t.labelBoxBorderColor};
2625
- fill: ${t.labelBoxBorderColor};
2626
- }
2627
-
2628
- .note {
2629
- //stroke: #decc93;
2630
- stroke: ${t.noteBorderColor};
2631
- fill: ${t.noteBkgColor};
2632
- }
2633
-
2634
- .noteText, .noteText > tspan {
2635
- fill: ${t.noteTextColor};
2636
- stroke: none;
2637
- }
2638
-
2639
- .activation0 {
2640
- fill: ${t.activationBkgColor};
2641
- stroke: ${t.activationBorderColor};
2642
- }
2643
-
2644
- .activation1 {
2645
- fill: ${t.activationBkgColor};
2646
- stroke: ${t.activationBorderColor};
2647
- }
2648
-
2649
- .activation2 {
2650
- fill: ${t.activationBkgColor};
2651
- stroke: ${t.activationBorderColor};
2652
- }
2653
-
2654
- .actorPopupMenu {
2655
- position: absolute;
2656
- }
2657
-
2658
- .actorPopupMenuPanel {
2659
- position: absolute;
2660
- fill: ${t.actorBkg};
2661
- box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
2662
- filter: drop-shadow(3px 5px 2px rgb(0 0 0 / 0.4));
2663
- }
2664
- .actor-man line {
2665
- stroke: ${t.actorBorder};
2666
- fill: ${t.actorBkg};
2667
- }
2668
- .actor-man circle, line {
2669
- stroke: ${t.actorBorder};
2670
- fill: ${t.actorBkg};
2671
- stroke-width: 2px;
2672
- }
2673
-
2674
- `, "getStyles"), ACTOR_TYPE_WIDTH = 36, TOP_ACTOR_CLASS = "actor-top", BOTTOM_ACTOR_CLASS = "actor-bottom", ACTOR_BOX_CLASS = "actor-box", ACTOR_MAN_FIGURE_CLASS = "actor-man", drawRect2 = /* @__PURE__ */ __name(function(t, l) {
2675
- return drawRect(t, l);
2676
- }, "drawRect"), drawPopup = /* @__PURE__ */ __name(function(t, l, u, d, f) {
2677
- if (l.links === void 0 || l.links === null || Object.keys(l.links).length === 0) return {
2678
- height: 0,
2679
- width: 0
2680
- };
2681
- let p = l.links, m = l.actorCnt, h = l.rectData;
2682
- var g = "none";
2683
- f && (g = "block !important");
2684
- let _ = t.append("g");
2685
- _.attr("id", "actor" + m + "_popup"), _.attr("class", "actorPopupMenu"), _.attr("display", g);
2686
- var v = "";
2687
- h.class !== void 0 && (v = " " + h.class);
2688
- let y = h.width > u ? h.width : u, b = _.append("rect");
2689
- if (b.attr("class", "actorPopupMenuPanel" + v), b.attr("x", h.x), b.attr("y", h.height), b.attr("fill", h.fill), b.attr("stroke", h.stroke), b.attr("width", y), b.attr("height", h.height), b.attr("rx", h.rx), b.attr("ry", h.ry), p != null) {
2690
- var x = 20;
2691
- for (let t2 in p) {
2692
- var S = _.append("a"), C = (0, import_dist.sanitizeUrl)(p[t2]);
2693
- S.attr("xlink:href", C), S.attr("target", "_blank"), _drawMenuItemTextCandidateFunc(d)(t2, S, h.x + 10, h.height + x, y, 20, { class: "actor" }, d), x += 30;
2694
- }
2695
- }
2696
- return b.attr("height", x), {
2697
- height: h.height + x,
2698
- width: y
2699
- };
2700
- }, "drawPopup"), popupMenuToggle = /* @__PURE__ */ __name(function(t) {
2701
- return "var pu = document.getElementById('" + t + "'); if (pu != null) { pu.style.display = pu.style.display == 'block' ? 'none' : 'block'; }";
2702
- }, "popupMenuToggle"), drawKatex = /* @__PURE__ */ __name(async function(t, l, u = null) {
2703
- let d = t.append("foreignObject"), f = await renderKatexSanitized(l.text, getConfig()), p = d.append("xhtml:div").attr("style", "width: fit-content;").attr("xmlns", "http://www.w3.org/1999/xhtml").html(f).node().getBoundingClientRect();
2704
- if (d.attr("height", Math.round(p.height)).attr("width", Math.round(p.width)), l.class === "noteText") {
2705
- let u2 = t.node().firstChild;
2706
- u2.setAttribute("height", p.height + 2 * l.textMargin);
2707
- let f2 = u2.getBBox();
2708
- d.attr("x", Math.round(f2.x + f2.width / 2 - p.width / 2)).attr("y", Math.round(f2.y + f2.height / 2 - p.height / 2));
2709
- } else if (u) {
2710
- let { startx: t2, stopx: f2, starty: m } = u;
2711
- if (t2 > f2) {
2712
- let l2 = t2;
2713
- t2 = f2, f2 = l2;
2714
- }
2715
- d.attr("x", Math.round(t2 + Math.abs(t2 - f2) / 2 - p.width / 2)), l.class === "loopText" ? d.attr("y", Math.round(m)) : d.attr("y", Math.round(m - p.height));
2716
- }
2717
- return [d];
2718
- }, "drawKatex"), drawText = /* @__PURE__ */ __name(function(t, u) {
2719
- let d = 0, p = 0, m = u.text.split(common_default.lineBreakRegex), [h, g] = parseFontSize(u.fontSize), _ = [], v = 0, y = /* @__PURE__ */ __name(() => u.y, "yfunc");
2720
- if (u.valign !== void 0 && u.textMargin !== void 0 && u.textMargin > 0) switch (u.valign) {
2721
- case "top":
2722
- case "start":
2723
- y = /* @__PURE__ */ __name(() => Math.round(u.y + u.textMargin), "yfunc");
2724
- break;
2725
- case "middle":
2726
- case "center":
2727
- y = /* @__PURE__ */ __name(() => Math.round(u.y + (d + p + u.textMargin) / 2), "yfunc");
2728
- break;
2729
- case "bottom":
2730
- case "end":
2731
- y = /* @__PURE__ */ __name(() => Math.round(u.y + (d + p + 2 * u.textMargin) - u.textMargin), "yfunc");
2732
- break;
2733
- }
2734
- if (u.anchor !== void 0 && u.textMargin !== void 0 && u.width !== void 0) switch (u.anchor) {
2735
- case "left":
2736
- case "start":
2737
- u.x = Math.round(u.x + u.textMargin), u.anchor = "start", u.dominantBaseline = "middle", u.alignmentBaseline = "middle";
2738
- break;
2739
- case "middle":
2740
- case "center":
2741
- u.x = Math.round(u.x + u.width / 2), u.anchor = "middle", u.dominantBaseline = "middle", u.alignmentBaseline = "middle";
2742
- break;
2743
- case "right":
2744
- case "end":
2745
- u.x = Math.round(u.x + u.width - u.textMargin), u.anchor = "end", u.dominantBaseline = "middle", u.alignmentBaseline = "middle";
2746
- break;
2747
- }
2748
- for (let [l, f] of m.entries()) {
2749
- u.textMargin !== void 0 && u.textMargin === 0 && h !== void 0 && (v = l * h);
2750
- let m2 = t.append("text");
2751
- m2.attr("x", u.x), m2.attr("y", y()), u.anchor !== void 0 && m2.attr("text-anchor", u.anchor).attr("dominant-baseline", u.dominantBaseline).attr("alignment-baseline", u.alignmentBaseline), u.fontFamily !== void 0 && m2.style("font-family", u.fontFamily), g !== void 0 && m2.style("font-size", g), u.fontWeight !== void 0 && m2.style("font-weight", u.fontWeight), u.fill !== void 0 && m2.attr("fill", u.fill), u.class !== void 0 && m2.attr("class", u.class), u.dy === void 0 ? v !== 0 && m2.attr("dy", v) : m2.attr("dy", u.dy);
2752
- let b = f || "\u200B";
2753
- if (u.tspan) {
2754
- let t2 = m2.append("tspan");
2755
- t2.attr("x", u.x), u.fill !== void 0 && t2.attr("fill", u.fill), t2.text(b);
2756
- } else m2.text(b);
2757
- u.valign !== void 0 && u.textMargin !== void 0 && u.textMargin > 0 && (p += (m2._groups || m2)[0][0].getBBox().height, d = p), _.push(m2);
2758
- }
2759
- return _;
2760
- }, "drawText"), drawLabel = /* @__PURE__ */ __name(function(t, l) {
2761
- function u(t2, l2, u2, d2, f) {
2762
- return t2 + "," + l2 + " " + (t2 + u2) + "," + l2 + " " + (t2 + u2) + "," + (l2 + d2 - f) + " " + (t2 + u2 - f * 1.2) + "," + (l2 + d2) + " " + t2 + "," + (l2 + d2);
2763
- }
2764
- __name(u, "genPoints");
2765
- let d = t.append("polygon");
2766
- return d.attr("points", u(l.x, l.y, l.width, l.height, 7)), d.attr("class", "labelBox"), l.y += l.height / 2, drawText(t, l), d;
2767
- }, "drawLabel"), actorCnt = -1, fixLifeLineHeights = /* @__PURE__ */ __name((t, l, u, d) => {
2768
- t.select && u.forEach((u2) => {
2769
- let f = l.get(u2), p = t.select("#actor" + f.actorCnt);
2770
- !d.mirrorActors && f.stopy ? p.attr("y2", f.stopy + f.height / 2) : d.mirrorActors && p.attr("y2", f.stopy);
2771
- });
2772
- }, "fixLifeLineHeights"), drawActorTypeParticipant = /* @__PURE__ */ __name(function(t, l, u, d) {
2773
- var _a2, _b;
2774
- let f = d ? l.stopy : l.starty, p = l.x + l.width / 2, m = f + l.height, h = t.append("g").lower();
2775
- var g = h;
2776
- d || (actorCnt++, Object.keys(l.links || {}).length && !u.forceMenus && g.attr("onclick", popupMenuToggle(`actor${actorCnt}_popup`)).attr("cursor", "pointer"), g.append("line").attr("id", "actor" + actorCnt).attr("x1", p).attr("y1", m).attr("x2", p).attr("y2", 2e3).attr("class", "actor-line 200").attr("stroke-width", "0.5px").attr("stroke", "#999").attr("name", l.name), g = h.append("g"), l.actorCnt = actorCnt, l.links != null && g.attr("id", "root-" + actorCnt));
2777
- let _ = getNoteRect();
2778
- var v = "actor";
2779
- ((_a2 = l.properties) == null ? void 0 : _a2.class) ? v = l.properties.class : _.fill = "#eaeaea", d ? v += ` ${BOTTOM_ACTOR_CLASS}` : v += ` ${TOP_ACTOR_CLASS}`, _.x = l.x, _.y = f, _.width = l.width, _.height = l.height, _.class = v, _.rx = 3, _.ry = 3, _.name = l.name;
2780
- let y = drawRect2(g, _);
2781
- if (l.rectData = _, (_b = l.properties) == null ? void 0 : _b.icon) {
2782
- let t2 = l.properties.icon.trim();
2783
- t2.charAt(0) === "@" ? drawEmbeddedImage(g, _.x + _.width - 20, _.y + 10, t2.substr(1)) : drawImage(g, _.x + _.width - 20, _.y + 10, t2);
2784
- }
2785
- _drawTextCandidateFunc(u, hasKatex(l.description))(l.description, g, _.x, _.y, _.width, _.height, { class: `actor ${ACTOR_BOX_CLASS}` }, u);
2786
- let x = l.height;
2787
- if (y.node) {
2788
- let t2 = y.node().getBBox();
2789
- l.height = t2.height, x = t2.height;
2790
- }
2791
- return x;
2792
- }, "drawActorTypeParticipant"), drawActorTypeCollections = /* @__PURE__ */ __name(function(t, l, u, d) {
2793
- var _a2, _b;
2794
- let f = d ? l.stopy : l.starty, p = l.x + l.width / 2, m = f + l.height, h = t.append("g").lower();
2795
- var g = h;
2796
- d || (actorCnt++, Object.keys(l.links || {}).length && !u.forceMenus && g.attr("onclick", popupMenuToggle(`actor${actorCnt}_popup`)).attr("cursor", "pointer"), g.append("line").attr("id", "actor" + actorCnt).attr("x1", p).attr("y1", m).attr("x2", p).attr("y2", 2e3).attr("class", "actor-line 200").attr("stroke-width", "0.5px").attr("stroke", "#999").attr("name", l.name), g = h.append("g"), l.actorCnt = actorCnt, l.links != null && g.attr("id", "root-" + actorCnt));
2797
- let _ = getNoteRect();
2798
- var v = "actor";
2799
- ((_a2 = l.properties) == null ? void 0 : _a2.class) ? v = l.properties.class : _.fill = "#eaeaea", d ? v += ` ${BOTTOM_ACTOR_CLASS}` : v += ` ${TOP_ACTOR_CLASS}`, _.x = l.x, _.y = f, _.width = l.width, _.height = l.height, _.class = v, _.name = l.name;
2800
- let y = {
2801
- ..._,
2802
- x: _.x + -6,
2803
- y: _.y + 6,
2804
- class: "actor"
2805
- }, x = drawRect2(g, _);
2806
- if (drawRect2(g, y), l.rectData = _, (_b = l.properties) == null ? void 0 : _b.icon) {
2807
- let t2 = l.properties.icon.trim();
2808
- t2.charAt(0) === "@" ? drawEmbeddedImage(g, _.x + _.width - 20, _.y + 10, t2.substr(1)) : drawImage(g, _.x + _.width - 20, _.y + 10, t2);
2809
- }
2810
- _drawTextCandidateFunc(u, hasKatex(l.description))(l.description, g, _.x - 6, _.y + 6, _.width, _.height, { class: `actor ${ACTOR_BOX_CLASS}` }, u);
2811
- let S = l.height;
2812
- if (x.node) {
2813
- let t2 = x.node().getBBox();
2814
- l.height = t2.height, S = t2.height;
2815
- }
2816
- return S;
2817
- }, "drawActorTypeCollections"), drawActorTypeQueue = /* @__PURE__ */ __name(function(t, l, u, d) {
2818
- var _a2, _b;
2819
- let f = d ? l.stopy : l.starty, p = l.x + l.width / 2, m = f + l.height, h = t.append("g").lower(), g = h;
2820
- d || (actorCnt++, Object.keys(l.links || {}).length && !u.forceMenus && g.attr("onclick", popupMenuToggle(`actor${actorCnt}_popup`)).attr("cursor", "pointer"), g.append("line").attr("id", "actor" + actorCnt).attr("x1", p).attr("y1", m).attr("x2", p).attr("y2", 2e3).attr("class", "actor-line 200").attr("stroke-width", "0.5px").attr("stroke", "#999").attr("name", l.name), g = h.append("g"), l.actorCnt = actorCnt, l.links != null && g.attr("id", "root-" + actorCnt));
2821
- let _ = getNoteRect(), v = "actor";
2822
- ((_a2 = l.properties) == null ? void 0 : _a2.class) ? v = l.properties.class : _.fill = "#eaeaea", d ? v += ` ${BOTTOM_ACTOR_CLASS}` : v += ` ${TOP_ACTOR_CLASS}`, _.x = l.x, _.y = f, _.width = l.width, _.height = l.height, _.class = v, _.name = l.name;
2823
- let y = _.height / 2, x = y / (2.5 + _.height / 50), S = g.append("g"), C = g.append("g");
2824
- if (S.append("path").attr("d", `M ${_.x},${_.y + y}
2825
- a ${x},${y} 0 0 0 0,${_.height}
2826
- h ${_.width - 2 * x}
2827
- a ${x},${y} 0 0 0 0,-${_.height}
2828
- Z
2829
- `).attr("class", v), C.append("path").attr("d", `M ${_.x},${_.y + y}
2830
- a ${x},${y} 0 0 0 0,${_.height}`).attr("stroke", "#666").attr("stroke-width", "1px").attr("class", v), S.attr("transform", `translate(${x}, ${-(_.height / 2)})`), C.attr("transform", `translate(${_.width - x}, ${-_.height / 2})`), l.rectData = _, (_b = l.properties) == null ? void 0 : _b.icon) {
2831
- let t2 = l.properties.icon.trim(), u2 = _.x + _.width - 20, d2 = _.y + 10;
2832
- t2.charAt(0) === "@" ? drawEmbeddedImage(g, u2, d2, t2.substr(1)) : drawImage(g, u2, d2, t2);
2833
- }
2834
- _drawTextCandidateFunc(u, hasKatex(l.description))(l.description, g, _.x, _.y, _.width, _.height, { class: `actor ${ACTOR_BOX_CLASS}` }, u);
2835
- let w = l.height, T = S.select("path:last-child");
2836
- if (T.node()) {
2837
- let t2 = T.node().getBBox();
2838
- l.height = t2.height, w = t2.height;
2839
- }
2840
- return w;
2841
- }, "drawActorTypeQueue"), drawActorTypeControl = /* @__PURE__ */ __name(function(t, l, u, d) {
2842
- var _a2;
2843
- let f = d ? l.stopy : l.starty, p = l.x + l.width / 2, m = f + 75, h = t.append("g").lower();
2844
- d || (actorCnt++, h.append("line").attr("id", "actor" + actorCnt).attr("x1", p).attr("y1", m).attr("x2", p).attr("y2", 2e3).attr("class", "actor-line 200").attr("stroke-width", "0.5px").attr("stroke", "#999").attr("name", l.name), l.actorCnt = actorCnt);
2845
- let g = t.append("g"), _ = ACTOR_MAN_FIGURE_CLASS;
2846
- d ? _ += ` ${BOTTOM_ACTOR_CLASS}` : _ += ` ${TOP_ACTOR_CLASS}`, g.attr("class", _), g.attr("name", l.name);
2847
- let v = getNoteRect();
2848
- v.x = l.x, v.y = f, v.fill = "#eaeaea", v.width = l.width, v.height = l.height, v.class = "actor";
2849
- let y = l.x + l.width / 2, x = f + 30;
2850
- return g.append("defs").append("marker").attr("id", "filled-head-control").attr("refX", 11).attr("refY", 5.8).attr("markerWidth", 20).attr("markerHeight", 28).attr("orient", "172.5").append("path").attr("d", "M 14.4 5.6 L 7.2 10.4 L 8.8 5.6 L 7.2 0.8 Z"), g.append("circle").attr("cx", y).attr("cy", x).attr("r", 18).attr("fill", "#eaeaf7").attr("stroke", "#666").attr("stroke-width", 1.2), g.append("line").attr("marker-end", "url(#filled-head-control)").attr("transform", `translate(${y}, ${x - 18})`), l.height = g.node().getBBox().height + 2 * (((_a2 = u == null ? void 0 : u.sequence) == null ? void 0 : _a2.labelBoxHeight) ?? 0), _drawTextCandidateFunc(u, hasKatex(l.description))(l.description, g, v.x, v.y + 18 + (d ? 5 : 10), v.width, v.height, { class: `actor ${ACTOR_MAN_FIGURE_CLASS}` }, u), l.height;
2851
- }, "drawActorTypeControl"), drawActorTypeEntity = /* @__PURE__ */ __name(function(t, l, u, d) {
2852
- var _a2;
2853
- let f = d ? l.stopy : l.starty, p = l.x + l.width / 2, m = f + 75, h = t.append("g").lower(), g = t.append("g"), _ = ACTOR_MAN_FIGURE_CLASS;
2854
- d ? _ += ` ${BOTTOM_ACTOR_CLASS}` : _ += ` ${TOP_ACTOR_CLASS}`, g.attr("class", _), g.attr("name", l.name);
2855
- let v = getNoteRect();
2856
- v.x = l.x, v.y = f, v.fill = "#eaeaea", v.width = l.width, v.height = l.height, v.class = "actor";
2857
- let y = l.x + l.width / 2, x = f + (d ? 10 : 25);
2858
- return g.append("circle").attr("cx", y).attr("cy", x).attr("r", 18).attr("width", l.width).attr("height", l.height), g.append("line").attr("x1", y - 18).attr("x2", y + 18).attr("y1", x + 18).attr("y2", x + 18).attr("stroke", "#333").attr("stroke-width", 2), l.height = g.node().getBBox().height + (((_a2 = u == null ? void 0 : u.sequence) == null ? void 0 : _a2.labelBoxHeight) ?? 0), d || (actorCnt++, h.append("line").attr("id", "actor" + actorCnt).attr("x1", p).attr("y1", m).attr("x2", p).attr("y2", 2e3).attr("class", "actor-line 200").attr("stroke-width", "0.5px").attr("stroke", "#999").attr("name", l.name), l.actorCnt = actorCnt), _drawTextCandidateFunc(u, hasKatex(l.description))(l.description, g, v.x, v.y + (d ? (x - f + 18 - 5) / 2 : (x + 18 - f) / 2), v.width, v.height, { class: `actor ${ACTOR_MAN_FIGURE_CLASS}` }, u), g.attr("transform", `translate(0, ${18 / 2})`), l.height;
2859
- }, "drawActorTypeEntity"), drawActorTypeDatabase = /* @__PURE__ */ __name(function(t, l, u, d) {
2860
- var _a2;
2861
- let f = d ? l.stopy : l.starty, p = l.x + l.width / 2, m = f + l.height + 2 * u.boxTextMargin, h = t.append("g").lower(), g = h;
2862
- d || (actorCnt++, Object.keys(l.links || {}).length && !u.forceMenus && g.attr("onclick", popupMenuToggle(`actor${actorCnt}_popup`)).attr("cursor", "pointer"), g.append("line").attr("id", "actor" + actorCnt).attr("x1", p).attr("y1", m).attr("x2", p).attr("y2", 2e3).attr("class", "actor-line 200").attr("stroke-width", "0.5px").attr("stroke", "#999").attr("name", l.name), g = h.append("g"), l.actorCnt = actorCnt, l.links != null && g.attr("id", "root-" + actorCnt));
2863
- let _ = getNoteRect(), v = "actor";
2864
- ((_a2 = l.properties) == null ? void 0 : _a2.class) ? v = l.properties.class : _.fill = "#eaeaea", d ? v += ` ${BOTTOM_ACTOR_CLASS}` : v += ` ${TOP_ACTOR_CLASS}`, _.x = l.x, _.y = f, _.width = l.width, _.height = l.height, _.class = v, _.name = l.name, _.x = l.x, _.y = f;
2865
- let y = _.width / 4, x = _.width / 4, S = y / 2, C = S / (2.5 + y / 50), w = g.append("g"), T = `
2866
- M ${_.x},${_.y + C}
2867
- a ${S},${C} 0 0 0 ${y},0
2868
- a ${S},${C} 0 0 0 -${y},0
2869
- l 0,${x - 2 * C}
2870
- a ${S},${C} 0 0 0 ${y},0
2871
- l 0,-${x - 2 * C}
2872
- `;
2873
- w.append("path").attr("d", T).attr("fill", "#eaeaea").attr("stroke", "#000").attr("stroke-width", 1).attr("class", v), d ? w.attr("transform", `translate(${y * 1.5}, ${_.height / 4 - 2 * C})`) : w.attr("transform", `translate(${y * 1.5}, ${(_.height + C) / 4})`), l.rectData = _, _drawTextCandidateFunc(u, hasKatex(l.description))(l.description, g, _.x, _.y + (d ? (_.height + x) / 4 : (_.height + C) / 2), _.width, _.height, { class: `actor ${ACTOR_BOX_CLASS}` }, u);
2874
- let E = w.select("path:last-child");
2875
- return E.node() && (l.height = E.node().getBBox().height + (u.sequence.labelBoxHeight ?? 0)), l.height;
2876
- }, "drawActorTypeDatabase"), drawActorTypeBoundary = /* @__PURE__ */ __name(function(t, l, u, d) {
2877
- let f = d ? l.stopy : l.starty, p = l.x + l.width / 2, m = f + 80, h = t.append("g").lower();
2878
- d || (actorCnt++, h.append("line").attr("id", "actor" + actorCnt).attr("x1", p).attr("y1", m).attr("x2", p).attr("y2", 2e3).attr("class", "actor-line 200").attr("stroke-width", "0.5px").attr("stroke", "#999").attr("name", l.name), l.actorCnt = actorCnt);
2879
- let g = t.append("g"), _ = ACTOR_MAN_FIGURE_CLASS;
2880
- d ? _ += ` ${BOTTOM_ACTOR_CLASS}` : _ += ` ${TOP_ACTOR_CLASS}`, g.attr("class", _), g.attr("name", l.name);
2881
- let v = getNoteRect();
2882
- return v.x = l.x, v.y = f, v.fill = "#eaeaea", v.width = l.width, v.height = l.height, v.class = "actor", g.append("line").attr("id", "actor-man-torso" + actorCnt).attr("x1", l.x + l.width / 2 - 30 * 2.5).attr("y1", f + 10).attr("x2", l.x + l.width / 2 - 15).attr("y2", f + 10), g.append("line").attr("id", "actor-man-arms" + actorCnt).attr("x1", l.x + l.width / 2 - 30 * 2.5).attr("y1", f + 0).attr("x2", l.x + l.width / 2 - 30 * 2.5).attr("y2", f + 20), g.append("circle").attr("cx", l.x + l.width / 2).attr("cy", f + 10).attr("r", 30), l.height = g.node().getBBox().height + (u.sequence.labelBoxHeight ?? 0), _drawTextCandidateFunc(u, hasKatex(l.description))(l.description, g, v.x, v.y + (d ? 30 / 2 - 4 : 18), v.width, v.height, { class: `actor ${ACTOR_MAN_FIGURE_CLASS}` }, u), g.attr("transform", "translate(0,22)"), l.height;
2883
- }, "drawActorTypeBoundary"), drawActorTypeActor = /* @__PURE__ */ __name(function(t, l, u, d) {
2884
- let f = d ? l.stopy : l.starty, p = l.x + l.width / 2, m = f + 80, h = t.append("g").lower();
2885
- d || (actorCnt++, h.append("line").attr("id", "actor" + actorCnt).attr("x1", p).attr("y1", m).attr("x2", p).attr("y2", 2e3).attr("class", "actor-line 200").attr("stroke-width", "0.5px").attr("stroke", "#999").attr("name", l.name), l.actorCnt = actorCnt);
2886
- let g = t.append("g"), _ = ACTOR_MAN_FIGURE_CLASS;
2887
- d ? _ += ` ${BOTTOM_ACTOR_CLASS}` : _ += ` ${TOP_ACTOR_CLASS}`, g.attr("class", _), g.attr("name", l.name);
2888
- let v = getNoteRect();
2889
- v.x = l.x, v.y = f, v.fill = "#eaeaea", v.width = l.width, v.height = l.height, v.class = "actor", v.rx = 3, v.ry = 3, g.append("line").attr("id", "actor-man-torso" + actorCnt).attr("x1", p).attr("y1", f + 25).attr("x2", p).attr("y2", f + 45), g.append("line").attr("id", "actor-man-arms" + actorCnt).attr("x1", p - ACTOR_TYPE_WIDTH / 2).attr("y1", f + 33).attr("x2", p + ACTOR_TYPE_WIDTH / 2).attr("y2", f + 33), g.append("line").attr("x1", p - ACTOR_TYPE_WIDTH / 2).attr("y1", f + 60).attr("x2", p).attr("y2", f + 45), g.append("line").attr("x1", p).attr("y1", f + 45).attr("x2", p + ACTOR_TYPE_WIDTH / 2 - 2).attr("y2", f + 60);
2890
- let y = g.append("circle");
2891
- return y.attr("cx", l.x + l.width / 2), y.attr("cy", f + 10), y.attr("r", 15), y.attr("width", l.width), y.attr("height", l.height), l.height = g.node().getBBox().height, _drawTextCandidateFunc(u, hasKatex(l.description))(l.description, g, v.x, v.y + 35, v.width, v.height, { class: `actor ${ACTOR_MAN_FIGURE_CLASS}` }, u), l.height;
2892
- }, "drawActorTypeActor"), drawActor = /* @__PURE__ */ __name(async function(t, l, u, d) {
2893
- switch (l.type) {
2894
- case "actor":
2895
- return await drawActorTypeActor(t, l, u, d);
2896
- case "participant":
2897
- return await drawActorTypeParticipant(t, l, u, d);
2898
- case "boundary":
2899
- return await drawActorTypeBoundary(t, l, u, d);
2900
- case "control":
2901
- return await drawActorTypeControl(t, l, u, d);
2902
- case "entity":
2903
- return await drawActorTypeEntity(t, l, u, d);
2904
- case "database":
2905
- return await drawActorTypeDatabase(t, l, u, d);
2906
- case "collections":
2907
- return await drawActorTypeCollections(t, l, u, d);
2908
- case "queue":
2909
- return await drawActorTypeQueue(t, l, u, d);
2910
- }
2911
- }, "drawActor"), drawBox = /* @__PURE__ */ __name(function(t, l, u) {
2912
- let d = t.append("g");
2913
- drawBackgroundRect2(d, l), l.name && _drawTextCandidateFunc(u)(l.name, d, l.x, l.y + u.boxTextMargin + (l.textMaxHeight || 0) / 2, l.width, 0, { class: "text" }, u), d.lower();
2914
- }, "drawBox"), anchorElement = /* @__PURE__ */ __name(function(t) {
2915
- return t.append("g");
2916
- }, "anchorElement"), drawActivation = /* @__PURE__ */ __name(function(t, l, u, d, f) {
2917
- let p = getNoteRect(), m = l.anchored;
2918
- p.x = l.startx, p.y = l.starty, p.class = "activation" + f % 3, p.width = l.stopx - l.startx, p.height = u - l.starty, drawRect2(m, p);
2919
- }, "drawActivation"), drawLoop = /* @__PURE__ */ __name(async function(t, l, u, d) {
2920
- let { boxMargin: p, boxTextMargin: m, labelBoxHeight: h, labelBoxWidth: g, messageFontFamily: _, messageFontSize: v, messageFontWeight: y } = d, x = t.append("g"), S = /* @__PURE__ */ __name(function(t2, l2, u2, d2) {
2921
- return x.append("line").attr("x1", t2).attr("y1", l2).attr("x2", u2).attr("y2", d2).attr("class", "loopLine");
2922
- }, "drawLoopLine");
2923
- S(l.startx, l.starty, l.stopx, l.starty), S(l.stopx, l.starty, l.stopx, l.stopy), S(l.startx, l.stopy, l.stopx, l.stopy), S(l.startx, l.starty, l.startx, l.stopy), l.sections !== void 0 && l.sections.forEach(function(t2) {
2924
- S(l.startx, t2.y, l.stopx, t2.y).style("stroke-dasharray", "3, 3");
2925
- });
2926
- let C = getTextObj();
2927
- C.text = u, C.x = l.startx, C.y = l.starty, C.fontFamily = _, C.fontSize = v, C.fontWeight = y, C.anchor = "middle", C.valign = "middle", C.tspan = false, C.width = g || 50, C.height = h || 20, C.textMargin = m, C.class = "labelText", drawLabel(x, C), C = getTextObj2(), C.text = l.title, C.x = l.startx + g / 2 + (l.stopx - l.startx) / 2, C.y = l.starty + p + m, C.anchor = "middle", C.valign = "middle", C.textMargin = m, C.class = "loopText", C.fontFamily = _, C.fontSize = v, C.fontWeight = y, C.wrap = true;
2928
- let w = hasKatex(C.text) ? await drawKatex(x, C, l) : drawText(x, C);
2929
- if (l.sectionTitles !== void 0) {
2930
- for (let [t2, u2] of Object.entries(l.sectionTitles)) if (u2.message) {
2931
- C.text = u2.message, C.x = l.startx + (l.stopx - l.startx) / 2, C.y = l.sections[t2].y + p + m, C.class = "loopText", C.anchor = "middle", C.valign = "middle", C.tspan = false, C.fontFamily = _, C.fontSize = v, C.fontWeight = y, C.wrap = l.wrap, hasKatex(C.text) ? (l.starty = l.sections[t2].y, await drawKatex(x, C, l)) : drawText(x, C);
2932
- let d2 = Math.round(w.map((t3) => (t3._groups || t3)[0][0].getBBox().height).reduce((t3, l2) => t3 + l2));
2933
- l.sections[t2].height += d2 - (p + m);
2934
- }
2935
- }
2936
- return l.height = Math.round(l.stopy - l.starty), x;
2937
- }, "drawLoop"), drawBackgroundRect2 = /* @__PURE__ */ __name(function(t, l) {
2938
- drawBackgroundRect(t, l);
2939
- }, "drawBackgroundRect"), insertDatabaseIcon = /* @__PURE__ */ __name(function(t) {
2940
- t.append("defs").append("symbol").attr("id", "database").attr("fill-rule", "evenodd").attr("clip-rule", "evenodd").append("path").attr("transform", "scale(.5)").attr("d", "M12.258.001l.256.004.255.005.253.008.251.01.249.012.247.015.246.016.242.019.241.02.239.023.236.024.233.027.231.028.229.031.225.032.223.034.22.036.217.038.214.04.211.041.208.043.205.045.201.046.198.048.194.05.191.051.187.053.183.054.18.056.175.057.172.059.168.06.163.061.16.063.155.064.15.066.074.033.073.033.071.034.07.034.069.035.068.035.067.035.066.035.064.036.064.036.062.036.06.036.06.037.058.037.058.037.055.038.055.038.053.038.052.038.051.039.05.039.048.039.047.039.045.04.044.04.043.04.041.04.04.041.039.041.037.041.036.041.034.041.033.042.032.042.03.042.029.042.027.042.026.043.024.043.023.043.021.043.02.043.018.044.017.043.015.044.013.044.012.044.011.045.009.044.007.045.006.045.004.045.002.045.001.045v17l-.001.045-.002.045-.004.045-.006.045-.007.045-.009.044-.011.045-.012.044-.013.044-.015.044-.017.043-.018.044-.02.043-.021.043-.023.043-.024.043-.026.043-.027.042-.029.042-.03.042-.032.042-.033.042-.034.041-.036.041-.037.041-.039.041-.04.041-.041.04-.043.04-.044.04-.045.04-.047.039-.048.039-.05.039-.051.039-.052.038-.053.038-.055.038-.055.038-.058.037-.058.037-.06.037-.06.036-.062.036-.064.036-.064.036-.066.035-.067.035-.068.035-.069.035-.07.034-.071.034-.073.033-.074.033-.15.066-.155.064-.16.063-.163.061-.168.06-.172.059-.175.057-.18.056-.183.054-.187.053-.191.051-.194.05-.198.048-.201.046-.205.045-.208.043-.211.041-.214.04-.217.038-.22.036-.223.034-.225.032-.229.031-.231.028-.233.027-.236.024-.239.023-.241.02-.242.019-.246.016-.247.015-.249.012-.251.01-.253.008-.255.005-.256.004-.258.001-.258-.001-.256-.004-.255-.005-.253-.008-.251-.01-.249-.012-.247-.015-.245-.016-.243-.019-.241-.02-.238-.023-.236-.024-.234-.027-.231-.028-.228-.031-.226-.032-.223-.034-.22-.036-.217-.038-.214-.04-.211-.041-.208-.043-.204-.045-.201-.046-.198-.048-.195-.05-.19-.051-.187-.053-.184-.054-.179-.056-.176-.057-.172-.059-.167-.06-.164-.061-.159-.063-.155-.064-.151-.066-.074-.033-.072-.033-.072-.034-.07-.034-.069-.035-.068-.035-.067-.035-.066-.035-.064-.036-.063-.036-.062-.036-.061-.036-.06-.037-.058-.037-.057-.037-.056-.038-.055-.038-.053-.038-.052-.038-.051-.039-.049-.039-.049-.039-.046-.039-.046-.04-.044-.04-.043-.04-.041-.04-.04-.041-.039-.041-.037-.041-.036-.041-.034-.041-.033-.042-.032-.042-.03-.042-.029-.042-.027-.042-.026-.043-.024-.043-.023-.043-.021-.043-.02-.043-.018-.044-.017-.043-.015-.044-.013-.044-.012-.044-.011-.045-.009-.044-.007-.045-.006-.045-.004-.045-.002-.045-.001-.045v-17l.001-.045.002-.045.004-.045.006-.045.007-.045.009-.044.011-.045.012-.044.013-.044.015-.044.017-.043.018-.044.02-.043.021-.043.023-.043.024-.043.026-.043.027-.042.029-.042.03-.042.032-.042.033-.042.034-.041.036-.041.037-.041.039-.041.04-.041.041-.04.043-.04.044-.04.046-.04.046-.039.049-.039.049-.039.051-.039.052-.038.053-.038.055-.038.056-.038.057-.037.058-.037.06-.037.061-.036.062-.036.063-.036.064-.036.066-.035.067-.035.068-.035.069-.035.07-.034.072-.034.072-.033.074-.033.151-.066.155-.064.159-.063.164-.061.167-.06.172-.059.176-.057.179-.056.184-.054.187-.053.19-.051.195-.05.198-.048.201-.046.204-.045.208-.043.211-.041.214-.04.217-.038.22-.036.223-.034.226-.032.228-.031.231-.028.234-.027.236-.024.238-.023.241-.02.243-.019.245-.016.247-.015.249-.012.251-.01.253-.008.255-.005.256-.004.258-.001.258.001zm-9.258 20.499v.01l.001.021.003.021.004.022.005.021.006.022.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.023.018.024.019.024.021.024.022.025.023.024.024.025.052.049.056.05.061.051.066.051.07.051.075.051.079.052.084.052.088.052.092.052.097.052.102.051.105.052.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.048.144.049.147.047.152.047.155.047.16.045.163.045.167.043.171.043.176.041.178.041.183.039.187.039.19.037.194.035.197.035.202.033.204.031.209.03.212.029.216.027.219.025.222.024.226.021.23.02.233.018.236.016.24.015.243.012.246.01.249.008.253.005.256.004.259.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.021.224-.024.22-.026.216-.027.212-.028.21-.031.205-.031.202-.034.198-.034.194-.036.191-.037.187-.039.183-.04.179-.04.175-.042.172-.043.168-.044.163-.045.16-.046.155-.046.152-.047.148-.048.143-.049.139-.049.136-.05.131-.05.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.053.083-.051.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.05.023-.024.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.023.01-.022.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.127l-.077.055-.08.053-.083.054-.085.053-.087.052-.09.052-.093.051-.095.05-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.045-.118.044-.12.043-.122.042-.124.042-.126.041-.128.04-.13.04-.132.038-.134.038-.135.037-.138.037-.139.035-.142.035-.143.034-.144.033-.147.032-.148.031-.15.03-.151.03-.153.029-.154.027-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.01-.179.008-.179.008-.181.006-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.006-.179-.008-.179-.008-.178-.01-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.027-.153-.029-.151-.03-.15-.03-.148-.031-.146-.032-.145-.033-.143-.034-.141-.035-.14-.035-.137-.037-.136-.037-.134-.038-.132-.038-.13-.04-.128-.04-.126-.041-.124-.042-.122-.042-.12-.044-.117-.043-.116-.045-.113-.045-.112-.046-.109-.047-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.05-.093-.052-.09-.051-.087-.052-.085-.053-.083-.054-.08-.054-.077-.054v4.127zm0-5.654v.011l.001.021.003.021.004.021.005.022.006.022.007.022.009.022.01.022.011.023.012.023.013.023.015.024.016.023.017.024.018.024.019.024.021.024.022.024.023.025.024.024.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.052.11.051.114.051.119.052.123.05.127.051.131.05.135.049.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.044.171.042.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.022.23.02.233.018.236.016.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.012.241-.015.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.048.139-.05.136-.049.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.051.051-.049.023-.025.023-.024.021-.025.02-.024.019-.024.018-.024.017-.024.015-.023.014-.023.013-.024.012-.022.01-.023.01-.023.008-.022.006-.022.006-.022.004-.021.004-.022.001-.021.001-.021v-4.139l-.077.054-.08.054-.083.054-.085.052-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.044-.118.044-.12.044-.122.042-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.035-.143.033-.144.033-.147.033-.148.031-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.009-.179.009-.179.007-.181.007-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.007-.179-.007-.179-.009-.178-.009-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.031-.146-.033-.145-.033-.143-.033-.141-.035-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.04-.126-.041-.124-.042-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.051-.093-.051-.09-.051-.087-.053-.085-.052-.083-.054-.08-.054-.077-.054v4.139zm0-5.666v.011l.001.02.003.022.004.021.005.022.006.021.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.024.018.023.019.024.021.025.022.024.023.024.024.025.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.051.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.043.171.043.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.021.23.02.233.018.236.017.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.013.241-.014.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.049.139-.049.136-.049.131-.051.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.049.023-.025.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.022.01-.023.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.153l-.077.054-.08.054-.083.053-.085.053-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.048-.105.048-.106.048-.109.046-.111.046-.114.046-.115.044-.118.044-.12.043-.122.043-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.034-.143.034-.144.033-.147.032-.148.032-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.024-.161.024-.162.023-.163.023-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.01-.178.01-.179.009-.179.007-.181.006-.182.006-.182.004-.184.003-.184.001-.185.001-.185-.001-.184-.001-.184-.003-.182-.004-.182-.006-.181-.006-.179-.007-.179-.009-.178-.01-.176-.01-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.023-.162-.023-.161-.024-.159-.024-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.032-.146-.032-.145-.033-.143-.034-.141-.034-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.041-.126-.041-.124-.041-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.048-.105-.048-.102-.048-.1-.05-.097-.049-.095-.051-.093-.051-.09-.052-.087-.052-.085-.053-.083-.053-.08-.054-.077-.054v4.153zm8.74-8.179l-.257.004-.254.005-.25.008-.247.011-.244.012-.241.014-.237.016-.233.018-.231.021-.226.022-.224.023-.22.026-.216.027-.212.028-.21.031-.205.032-.202.033-.198.034-.194.036-.191.038-.187.038-.183.04-.179.041-.175.042-.172.043-.168.043-.163.045-.16.046-.155.046-.152.048-.148.048-.143.048-.139.049-.136.05-.131.05-.126.051-.123.051-.118.051-.114.052-.11.052-.106.052-.101.052-.096.052-.092.052-.088.052-.083.052-.079.052-.074.051-.07.052-.065.051-.06.05-.056.05-.051.05-.023.025-.023.024-.021.024-.02.025-.019.024-.018.024-.017.023-.015.024-.014.023-.013.023-.012.023-.01.023-.01.022-.008.022-.006.023-.006.021-.004.022-.004.021-.001.021-.001.021.001.021.001.021.004.021.004.022.006.021.006.023.008.022.01.022.01.023.012.023.013.023.014.023.015.024.017.023.018.024.019.024.02.025.021.024.023.024.023.025.051.05.056.05.06.05.065.051.07.052.074.051.079.052.083.052.088.052.092.052.096.052.101.052.106.052.11.052.114.052.118.051.123.051.126.051.131.05.136.05.139.049.143.048.148.048.152.048.155.046.16.046.163.045.168.043.172.043.175.042.179.041.183.04.187.038.191.038.194.036.198.034.202.033.205.032.21.031.212.028.216.027.22.026.224.023.226.022.231.021.233.018.237.016.241.014.244.012.247.011.25.008.254.005.257.004.26.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.022.224-.023.22-.026.216-.027.212-.028.21-.031.205-.032.202-.033.198-.034.194-.036.191-.038.187-.038.183-.04.179-.041.175-.042.172-.043.168-.043.163-.045.16-.046.155-.046.152-.048.148-.048.143-.048.139-.049.136-.05.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.05.051-.05.023-.025.023-.024.021-.024.02-.025.019-.024.018-.024.017-.023.015-.024.014-.023.013-.023.012-.023.01-.023.01-.022.008-.022.006-.023.006-.021.004-.022.004-.021.001-.021.001-.021-.001-.021-.001-.021-.004-.021-.004-.022-.006-.021-.006-.023-.008-.022-.01-.022-.01-.023-.012-.023-.013-.023-.014-.023-.015-.024-.017-.023-.018-.024-.019-.024-.02-.025-.021-.024-.023-.024-.023-.025-.051-.05-.056-.05-.06-.05-.065-.051-.07-.052-.074-.051-.079-.052-.083-.052-.088-.052-.092-.052-.096-.052-.101-.052-.106-.052-.11-.052-.114-.052-.118-.051-.123-.051-.126-.051-.131-.05-.136-.05-.139-.049-.143-.048-.148-.048-.152-.048-.155-.046-.16-.046-.163-.045-.168-.043-.172-.043-.175-.042-.179-.041-.183-.04-.187-.038-.191-.038-.194-.036-.198-.034-.202-.033-.205-.032-.21-.031-.212-.028-.216-.027-.22-.026-.224-.023-.226-.022-.231-.021-.233-.018-.237-.016-.241-.014-.244-.012-.247-.011-.25-.008-.254-.005-.257-.004-.26-.001-.26.001z");
2941
- }, "insertDatabaseIcon"), insertComputerIcon = /* @__PURE__ */ __name(function(t) {
2942
- t.append("defs").append("symbol").attr("id", "computer").attr("width", "24").attr("height", "24").append("path").attr("transform", "scale(.5)").attr("d", "M2 2v13h20v-13h-20zm18 11h-16v-9h16v9zm-10.228 6l.466-1h3.524l.467 1h-4.457zm14.228 3h-24l2-6h2.104l-1.33 4h18.45l-1.297-4h2.073l2 6zm-5-10h-14v-7h14v7z");
2943
- }, "insertComputerIcon"), insertClockIcon = /* @__PURE__ */ __name(function(t) {
2944
- t.append("defs").append("symbol").attr("id", "clock").attr("width", "24").attr("height", "24").append("path").attr("transform", "scale(.5)").attr("d", "M12 2c5.514 0 10 4.486 10 10s-4.486 10-10 10-10-4.486-10-10 4.486-10 10-10zm0-2c-6.627 0-12 5.373-12 12s5.373 12 12 12 12-5.373 12-12-5.373-12-12-12zm5.848 12.459c.202.038.202.333.001.372-1.907.361-6.045 1.111-6.547 1.111-.719 0-1.301-.582-1.301-1.301 0-.512.77-5.447 1.125-7.445.034-.192.312-.181.343.014l.985 6.238 5.394 1.011z");
2945
- }, "insertClockIcon"), insertArrowHead = /* @__PURE__ */ __name(function(t) {
2946
- t.append("defs").append("marker").attr("id", "arrowhead").attr("refX", 7.9).attr("refY", 5).attr("markerUnits", "userSpaceOnUse").attr("markerWidth", 12).attr("markerHeight", 12).attr("orient", "auto-start-reverse").append("path").attr("d", "M -1 0 L 10 5 L 0 10 z");
2947
- }, "insertArrowHead"), insertArrowFilledHead = /* @__PURE__ */ __name(function(t) {
2948
- t.append("defs").append("marker").attr("id", "filled-head").attr("refX", 15.5).attr("refY", 7).attr("markerWidth", 20).attr("markerHeight", 28).attr("orient", "auto").append("path").attr("d", "M 18,7 L9,13 L14,7 L9,1 Z");
2949
- }, "insertArrowFilledHead"), insertSequenceNumber = /* @__PURE__ */ __name(function(t) {
2950
- t.append("defs").append("marker").attr("id", "sequencenumber").attr("refX", 15).attr("refY", 15).attr("markerWidth", 60).attr("markerHeight", 40).attr("orient", "auto").append("circle").attr("cx", 15).attr("cy", 15).attr("r", 6);
2951
- }, "insertSequenceNumber"), insertArrowCrossHead = /* @__PURE__ */ __name(function(t) {
2952
- t.append("defs").append("marker").attr("id", "crosshead").attr("markerWidth", 15).attr("markerHeight", 8).attr("orient", "auto").attr("refX", 4).attr("refY", 4.5).append("path").attr("fill", "none").attr("stroke", "#000000").style("stroke-dasharray", "0, 0").attr("stroke-width", "1pt").attr("d", "M 1,2 L 6,7 M 6,2 L 1,7");
2953
- }, "insertArrowCrossHead"), getTextObj2 = /* @__PURE__ */ __name(function() {
2954
- return {
2955
- x: 0,
2956
- y: 0,
2957
- fill: void 0,
2958
- anchor: void 0,
2959
- style: "#666",
2960
- width: void 0,
2961
- height: void 0,
2962
- textMargin: 0,
2963
- rx: 0,
2964
- ry: 0,
2965
- tspan: true,
2966
- valign: void 0
2967
- };
2968
- }, "getTextObj"), getNoteRect2 = /* @__PURE__ */ __name(function() {
2969
- return {
2970
- x: 0,
2971
- y: 0,
2972
- fill: "#EDF2AE",
2973
- stroke: "#666",
2974
- width: 100,
2975
- anchor: "start",
2976
- height: 100,
2977
- rx: 0,
2978
- ry: 0
2979
- };
2980
- }, "getNoteRect"), _drawTextCandidateFunc = /* @__PURE__ */ (function() {
2981
- function t(t2, l, u2, d2, f, p2, h) {
2982
- m(l.append("text").attr("x", u2 + f / 2).attr("y", d2 + p2 / 2 + 5).style("text-anchor", "middle").text(t2), h);
2983
- }
2984
- __name(t, "byText");
2985
- function u(t2, u2, d2, f, p2, h, g, _) {
2986
- let { actorFontSize: v, actorFontFamily: y, actorFontWeight: b } = _, [x, S] = parseFontSize(v), C = t2.split(common_default.lineBreakRegex);
2987
- for (let t3 = 0; t3 < C.length; t3++) {
2988
- let l = t3 * x - x * (C.length - 1) / 2, _2 = u2.append("text").attr("x", d2 + p2 / 2).attr("y", f).style("text-anchor", "middle").style("font-size", S).style("font-weight", b).style("font-family", y);
2989
- _2.append("tspan").attr("x", d2 + p2 / 2).attr("dy", l).text(C[t3]), _2.attr("y", f + h / 2).attr("dominant-baseline", "central").attr("alignment-baseline", "central"), m(_2, g);
2990
- }
2991
- }
2992
- __name(u, "byTspan");
2993
- function d(t2, l, d2, f, p2, h, g, _) {
2994
- let v = l.append("switch"), y = v.append("foreignObject").attr("x", d2).attr("y", f).attr("width", p2).attr("height", h).append("xhtml:div").style("display", "table").style("height", "100%").style("width", "100%");
2995
- y.append("div").style("display", "table-cell").style("text-align", "center").style("vertical-align", "middle").text(t2), u(t2, v, d2, f, p2, h, g, _), m(y, g);
2996
- }
2997
- __name(d, "byFo");
2998
- async function p(t2, l, d2, f, p2, h, g, _) {
2999
- let v = await calculateMathMLDimensions(t2, getConfig()), b = l.append("switch"), x = b.append("foreignObject").attr("x", d2 + p2 / 2 - v.width / 2).attr("y", f + h / 2 - v.height / 2).attr("width", v.width).attr("height", v.height).append("xhtml:div").style("height", "100%").style("width", "100%");
3000
- x.append("div").style("text-align", "center").style("vertical-align", "middle").html(await renderKatexSanitized(t2, getConfig())), u(t2, b, d2, f, p2, h, g, _), m(x, g);
3001
- }
3002
- __name(p, "byKatex");
3003
- function m(t2, l) {
3004
- for (let u2 in l) l.hasOwnProperty(u2) && t2.attr(u2, l[u2]);
3005
- }
3006
- return __name(m, "_setTextAttrs"), function(l, f = false) {
3007
- return f ? p : l.textPlacement === "fo" ? d : l.textPlacement === "old" ? t : u;
3008
- };
3009
- })(), _drawMenuItemTextCandidateFunc = /* @__PURE__ */ (function() {
3010
- function t(t2, l2, u2, f, p, m, h) {
3011
- d(l2.append("text").attr("x", u2).attr("y", f).style("text-anchor", "start").text(t2), h);
3012
- }
3013
- __name(t, "byText");
3014
- function l(t2, l2, u2, f, p, m, h, g) {
3015
- let { actorFontSize: _, actorFontFamily: v, actorFontWeight: y } = g, b = t2.split(common_default.lineBreakRegex);
3016
- for (let t3 = 0; t3 < b.length; t3++) {
3017
- let p2 = t3 * _ - _ * (b.length - 1) / 2, g2 = l2.append("text").attr("x", u2).attr("y", f).style("text-anchor", "start").style("font-size", _).style("font-weight", y).style("font-family", v);
3018
- g2.append("tspan").attr("x", u2).attr("dy", p2).text(b[t3]), g2.attr("y", f + m / 2).attr("dominant-baseline", "central").attr("alignment-baseline", "central"), d(g2, h);
3019
- }
3020
- }
3021
- __name(l, "byTspan");
3022
- function u(t2, u2, f, p, m, h, g, _) {
3023
- let v = u2.append("switch"), y = v.append("foreignObject").attr("x", f).attr("y", p).attr("width", m).attr("height", h).append("xhtml:div").style("display", "table").style("height", "100%").style("width", "100%");
3024
- y.append("div").style("display", "table-cell").style("text-align", "center").style("vertical-align", "middle").text(t2), l(t2, v, f, p, m, h, g, _), d(y, g);
3025
- }
3026
- __name(u, "byFo");
3027
- function d(t2, l2) {
3028
- for (let u2 in l2) l2.hasOwnProperty(u2) && t2.attr(u2, l2[u2]);
3029
- }
3030
- return __name(d, "_setTextAttrs"), function(d2) {
3031
- return d2.textPlacement === "fo" ? u : d2.textPlacement === "old" ? t : l;
3032
- };
3033
- })(), svgDraw_default = {
3034
- drawRect: drawRect2,
3035
- drawText,
3036
- drawLabel,
3037
- drawActor,
3038
- drawBox,
3039
- drawPopup,
3040
- anchorElement,
3041
- drawActivation,
3042
- drawLoop,
3043
- drawBackgroundRect: drawBackgroundRect2,
3044
- insertArrowHead,
3045
- insertArrowFilledHead,
3046
- insertSequenceNumber,
3047
- insertArrowCrossHead,
3048
- insertDatabaseIcon,
3049
- insertComputerIcon,
3050
- insertClockIcon,
3051
- getTextObj: getTextObj2,
3052
- getNoteRect: getNoteRect2,
3053
- fixLifeLineHeights,
3054
- sanitizeUrl: import_dist.sanitizeUrl
3055
- }, conf = {}, bounds = {
3056
- data: {
3057
- startx: void 0,
3058
- stopx: void 0,
3059
- starty: void 0,
3060
- stopy: void 0
3061
- },
3062
- verticalPos: 0,
3063
- sequenceItems: [],
3064
- activations: [],
3065
- models: {
3066
- getHeight: /* @__PURE__ */ __name(function() {
3067
- return Math.max.apply(null, this.actors.length === 0 ? [0] : this.actors.map((t) => t.height || 0)) + (this.loops.length === 0 ? 0 : this.loops.map((t) => t.height || 0).reduce((t, l) => t + l)) + (this.messages.length === 0 ? 0 : this.messages.map((t) => t.height || 0).reduce((t, l) => t + l)) + (this.notes.length === 0 ? 0 : this.notes.map((t) => t.height || 0).reduce((t, l) => t + l));
3068
- }, "getHeight"),
3069
- clear: /* @__PURE__ */ __name(function() {
3070
- this.actors = [], this.boxes = [], this.loops = [], this.messages = [], this.notes = [];
3071
- }, "clear"),
3072
- addBox: /* @__PURE__ */ __name(function(t) {
3073
- this.boxes.push(t);
3074
- }, "addBox"),
3075
- addActor: /* @__PURE__ */ __name(function(t) {
3076
- this.actors.push(t);
3077
- }, "addActor"),
3078
- addLoop: /* @__PURE__ */ __name(function(t) {
3079
- this.loops.push(t);
3080
- }, "addLoop"),
3081
- addMessage: /* @__PURE__ */ __name(function(t) {
3082
- this.messages.push(t);
3083
- }, "addMessage"),
3084
- addNote: /* @__PURE__ */ __name(function(t) {
3085
- this.notes.push(t);
3086
- }, "addNote"),
3087
- lastActor: /* @__PURE__ */ __name(function() {
3088
- return this.actors[this.actors.length - 1];
3089
- }, "lastActor"),
3090
- lastLoop: /* @__PURE__ */ __name(function() {
3091
- return this.loops[this.loops.length - 1];
3092
- }, "lastLoop"),
3093
- lastMessage: /* @__PURE__ */ __name(function() {
3094
- return this.messages[this.messages.length - 1];
3095
- }, "lastMessage"),
3096
- lastNote: /* @__PURE__ */ __name(function() {
3097
- return this.notes[this.notes.length - 1];
3098
- }, "lastNote"),
3099
- actors: [],
3100
- boxes: [],
3101
- loops: [],
3102
- messages: [],
3103
- notes: []
3104
- },
3105
- init: /* @__PURE__ */ __name(function() {
3106
- this.sequenceItems = [], this.activations = [], this.models.clear(), this.data = {
3107
- startx: void 0,
3108
- stopx: void 0,
3109
- starty: void 0,
3110
- stopy: void 0
3111
- }, this.verticalPos = 0, setConf(getConfig2());
3112
- }, "init"),
3113
- updateVal: /* @__PURE__ */ __name(function(t, l, u, d) {
3114
- t[l] === void 0 ? t[l] = u : t[l] = d(u, t[l]);
3115
- }, "updateVal"),
3116
- updateBounds: /* @__PURE__ */ __name(function(t, l, u, d) {
3117
- let p = this, m = 0;
3118
- function h(h2) {
3119
- return /* @__PURE__ */ __name(function(f) {
3120
- m++;
3121
- let g = p.sequenceItems.length - m + 1;
3122
- p.updateVal(f, "starty", l - g * conf.boxMargin, Math.min), p.updateVal(f, "stopy", d + g * conf.boxMargin, Math.max), p.updateVal(bounds.data, "startx", t - g * conf.boxMargin, Math.min), p.updateVal(bounds.data, "stopx", u + g * conf.boxMargin, Math.max), h2 !== "activation" && (p.updateVal(f, "startx", t - g * conf.boxMargin, Math.min), p.updateVal(f, "stopx", u + g * conf.boxMargin, Math.max), p.updateVal(bounds.data, "starty", l - g * conf.boxMargin, Math.min), p.updateVal(bounds.data, "stopy", d + g * conf.boxMargin, Math.max));
3123
- }, "updateItemBounds");
3124
- }
3125
- __name(h, "updateFn"), this.sequenceItems.forEach(h()), this.activations.forEach(h("activation"));
3126
- }, "updateBounds"),
3127
- insert: /* @__PURE__ */ __name(function(t, l, u, d) {
3128
- let f = common_default.getMin(t, u), p = common_default.getMax(t, u), m = common_default.getMin(l, d), h = common_default.getMax(l, d);
3129
- this.updateVal(bounds.data, "startx", f, Math.min), this.updateVal(bounds.data, "starty", m, Math.min), this.updateVal(bounds.data, "stopx", p, Math.max), this.updateVal(bounds.data, "stopy", h, Math.max), this.updateBounds(f, m, p, h);
3130
- }, "insert"),
3131
- newActivation: /* @__PURE__ */ __name(function(t, l, u) {
3132
- let d = u.get(t.from), f = actorActivations(t.from).length || 0, p = d.x + d.width / 2 + (f - 1) * conf.activationWidth / 2;
3133
- this.activations.push({
3134
- startx: p,
3135
- starty: this.verticalPos + 2,
3136
- stopx: p + conf.activationWidth,
3137
- stopy: void 0,
3138
- actor: t.from,
3139
- anchored: svgDraw_default.anchorElement(l)
3140
- });
3141
- }, "newActivation"),
3142
- endActivation: /* @__PURE__ */ __name(function(t) {
3143
- let l = this.activations.map(function(t2) {
3144
- return t2.actor;
3145
- }).lastIndexOf(t.from);
3146
- return this.activations.splice(l, 1)[0];
3147
- }, "endActivation"),
3148
- createLoop: /* @__PURE__ */ __name(function(t = {
3149
- message: void 0,
3150
- wrap: false,
3151
- width: void 0
3152
- }, l) {
3153
- return {
3154
- startx: void 0,
3155
- starty: this.verticalPos,
3156
- stopx: void 0,
3157
- stopy: void 0,
3158
- title: t.message,
3159
- wrap: t.wrap,
3160
- width: t.width,
3161
- height: 0,
3162
- fill: l
3163
- };
3164
- }, "createLoop"),
3165
- newLoop: /* @__PURE__ */ __name(function(t = {
3166
- message: void 0,
3167
- wrap: false,
3168
- width: void 0
3169
- }, l) {
3170
- this.sequenceItems.push(this.createLoop(t, l));
3171
- }, "newLoop"),
3172
- endLoop: /* @__PURE__ */ __name(function() {
3173
- return this.sequenceItems.pop();
3174
- }, "endLoop"),
3175
- isLoopOverlap: /* @__PURE__ */ __name(function() {
3176
- return this.sequenceItems.length ? this.sequenceItems[this.sequenceItems.length - 1].overlap : false;
3177
- }, "isLoopOverlap"),
3178
- addSectionToLoop: /* @__PURE__ */ __name(function(t) {
3179
- let l = this.sequenceItems.pop();
3180
- l.sections = l.sections || [], l.sectionTitles = l.sectionTitles || [], l.sections.push({
3181
- y: bounds.getVerticalPos(),
3182
- height: 0
3183
- }), l.sectionTitles.push(t), this.sequenceItems.push(l);
3184
- }, "addSectionToLoop"),
3185
- saveVerticalPos: /* @__PURE__ */ __name(function() {
3186
- this.isLoopOverlap() && (this.savedVerticalPos = this.verticalPos);
3187
- }, "saveVerticalPos"),
3188
- resetVerticalPos: /* @__PURE__ */ __name(function() {
3189
- this.isLoopOverlap() && (this.verticalPos = this.savedVerticalPos);
3190
- }, "resetVerticalPos"),
3191
- bumpVerticalPos: /* @__PURE__ */ __name(function(t) {
3192
- this.verticalPos += t, this.data.stopy = common_default.getMax(this.data.stopy, this.verticalPos);
3193
- }, "bumpVerticalPos"),
3194
- getVerticalPos: /* @__PURE__ */ __name(function() {
3195
- return this.verticalPos;
3196
- }, "getVerticalPos"),
3197
- getBounds: /* @__PURE__ */ __name(function() {
3198
- return {
3199
- bounds: this.data,
3200
- models: this.models
3201
- };
3202
- }, "getBounds")
3203
- }, drawNote = /* @__PURE__ */ __name(async function(t, l) {
3204
- bounds.bumpVerticalPos(conf.boxMargin), l.height = conf.boxMargin, l.starty = bounds.getVerticalPos();
3205
- let u = getNoteRect();
3206
- u.x = l.startx, u.y = l.starty, u.width = l.width || conf.width, u.class = "note";
3207
- let d = t.append("g"), f = svgDraw_default.drawRect(d, u), p = getTextObj();
3208
- p.x = l.startx, p.y = l.starty, p.width = u.width, p.dy = "1em", p.text = l.message, p.class = "noteText", p.fontFamily = conf.noteFontFamily, p.fontSize = conf.noteFontSize, p.fontWeight = conf.noteFontWeight, p.anchor = conf.noteAlign, p.textMargin = conf.noteMargin, p.valign = "center";
3209
- let m = hasKatex(p.text) ? await drawKatex(d, p) : drawText(d, p), h = Math.round(m.map((t2) => (t2._groups || t2)[0][0].getBBox().height).reduce((t2, l2) => t2 + l2));
3210
- f.attr("height", h + 2 * conf.noteMargin), l.height += h + 2 * conf.noteMargin, bounds.bumpVerticalPos(h + 2 * conf.noteMargin), l.stopy = l.starty + h + 2 * conf.noteMargin, l.stopx = l.startx + u.width, bounds.insert(l.startx, l.starty, l.stopx, l.stopy), bounds.models.addNote(l);
3211
- }, "drawNote"), messageFont = /* @__PURE__ */ __name((t) => ({
3212
- fontFamily: t.messageFontFamily,
3213
- fontSize: t.messageFontSize,
3214
- fontWeight: t.messageFontWeight
3215
- }), "messageFont"), noteFont = /* @__PURE__ */ __name((t) => ({
3216
- fontFamily: t.noteFontFamily,
3217
- fontSize: t.noteFontSize,
3218
- fontWeight: t.noteFontWeight
3219
- }), "noteFont"), actorFont = /* @__PURE__ */ __name((t) => ({
3220
- fontFamily: t.actorFontFamily,
3221
- fontSize: t.actorFontSize,
3222
- fontWeight: t.actorFontWeight
3223
- }), "actorFont");
3224
- async function boundMessage(l, u) {
3225
- bounds.bumpVerticalPos(10);
3226
- let { startx: d, stopx: f, message: p } = u, m = common_default.splitBreaks(p).length, h = hasKatex(p), g = h ? await calculateMathMLDimensions(p, getConfig2()) : utils_default.calculateTextDimensions(p, messageFont(conf));
3227
- if (!h) {
3228
- let t = g.height / m;
3229
- u.height += t, bounds.bumpVerticalPos(t);
3230
- }
3231
- let _, v = g.height - 10, y = g.width;
3232
- if (d === f) {
3233
- _ = bounds.getVerticalPos() + v, conf.rightAngles || (v += conf.boxMargin, _ = bounds.getVerticalPos() + v), v += 30;
3234
- let t = common_default.getMax(y / 2, conf.width / 2);
3235
- bounds.insert(d - t, bounds.getVerticalPos() - 10 + v, f + t, bounds.getVerticalPos() + 30 + v);
3236
- } else v += conf.boxMargin, _ = bounds.getVerticalPos() + v, bounds.insert(d, _ - 10, f, _);
3237
- return bounds.bumpVerticalPos(v), u.height += v, u.stopy = u.starty + u.height, bounds.insert(u.fromBounds, u.starty, u.toBounds, u.stopy), _;
3238
- }
3239
- __name(boundMessage, "boundMessage");
3240
- var drawMessage = /* @__PURE__ */ __name(async function(l, u, d, f) {
3241
- let { startx: p, stopx: m, starty: h, message: _, type: v, sequenceIndex: y, sequenceVisible: x } = u, S = utils_default.calculateTextDimensions(_, messageFont(conf)), C = getTextObj();
3242
- C.x = p, C.y = h + 10, C.width = m - p, C.class = "messageText", C.dy = "1em", C.text = _, C.fontFamily = conf.messageFontFamily, C.fontSize = conf.messageFontSize, C.fontWeight = conf.messageFontWeight, C.anchor = conf.messageAlign, C.valign = "center", C.textMargin = conf.wrapPadding, C.tspan = false, hasKatex(C.text) ? await drawKatex(l, C, {
3243
- startx: p,
3244
- stopx: m,
3245
- starty: d
3246
- }) : drawText(l, C);
3247
- let w = S.width, T;
3248
- p === m ? T = conf.rightAngles ? l.append("path").attr("d", `M ${p},${d} H ${p + common_default.getMax(conf.width / 2, w / 2)} V ${d + 25} H ${p}`) : l.append("path").attr("d", "M " + p + "," + d + " C " + (p + 60) + "," + (d - 10) + " " + (p + 60) + "," + (d + 30) + " " + p + "," + (d + 20)) : (T = l.append("line"), T.attr("x1", p), T.attr("y1", d), T.attr("x2", m), T.attr("y2", d)), v === f.db.LINETYPE.DOTTED || v === f.db.LINETYPE.DOTTED_CROSS || v === f.db.LINETYPE.DOTTED_POINT || v === f.db.LINETYPE.DOTTED_OPEN || v === f.db.LINETYPE.BIDIRECTIONAL_DOTTED ? (T.style("stroke-dasharray", "3, 3"), T.attr("class", "messageLine1")) : T.attr("class", "messageLine0");
3249
- let E = "";
3250
- conf.arrowMarkerAbsolute && (E = getUrl(true)), T.attr("stroke-width", 2), T.attr("stroke", "none"), T.style("fill", "none"), (v === f.db.LINETYPE.SOLID || v === f.db.LINETYPE.DOTTED) && T.attr("marker-end", "url(" + E + "#arrowhead)"), (v === f.db.LINETYPE.BIDIRECTIONAL_SOLID || v === f.db.LINETYPE.BIDIRECTIONAL_DOTTED) && (T.attr("marker-start", "url(" + E + "#arrowhead)"), T.attr("marker-end", "url(" + E + "#arrowhead)")), (v === f.db.LINETYPE.SOLID_POINT || v === f.db.LINETYPE.DOTTED_POINT) && T.attr("marker-end", "url(" + E + "#filled-head)"), (v === f.db.LINETYPE.SOLID_CROSS || v === f.db.LINETYPE.DOTTED_CROSS) && T.attr("marker-end", "url(" + E + "#crosshead)"), (x || conf.showSequenceNumbers) && ((v === f.db.LINETYPE.BIDIRECTIONAL_SOLID || v === f.db.LINETYPE.BIDIRECTIONAL_DOTTED) && (p < m ? T.attr("x1", p + 12) : T.attr("x1", p + 6)), l.append("line").attr("x1", p).attr("y1", d).attr("x2", p).attr("y2", d).attr("stroke-width", 0).attr("marker-start", "url(" + E + "#sequencenumber)"), l.append("text").attr("x", p).attr("y", d + 4).attr("font-family", "sans-serif").attr("font-size", "12px").attr("text-anchor", "middle").attr("class", "sequenceNumber").text(y));
3251
- }, "drawMessage"), addActorRenderingData = /* @__PURE__ */ __name(function(t, l, u, d, f, p, m) {
3252
- let h = 0, g = 0, _, v = 0;
3253
- for (let t2 of d) {
3254
- let d2 = l.get(t2), p2 = d2.box;
3255
- _ && _ != p2 && (m || bounds.models.addBox(_), g += conf.boxMargin + _.margin), p2 && p2 != _ && (m || (p2.x = h + g, p2.y = f), g += p2.margin), d2.width = d2.width || conf.width, d2.height = common_default.getMax(d2.height || conf.height, conf.height), d2.margin = d2.margin || conf.actorMargin, v = common_default.getMax(v, d2.height), u.get(d2.name) && (g += d2.width / 2), d2.x = h + g, d2.starty = bounds.getVerticalPos(), bounds.insert(d2.x, f, d2.x + d2.width, d2.height), h += d2.width + g, d2.box && (d2.box.width = h + p2.margin - d2.box.x), g = d2.margin, _ = d2.box, bounds.models.addActor(d2);
3256
- }
3257
- _ && !m && bounds.models.addBox(_), bounds.bumpVerticalPos(v);
3258
- }, "addActorRenderingData"), drawActors = /* @__PURE__ */ __name(async function(t, l, u, d) {
3259
- if (d) {
3260
- let d2 = 0;
3261
- bounds.bumpVerticalPos(conf.boxMargin * 2);
3262
- for (let f of u) {
3263
- let u2 = l.get(f);
3264
- u2.stopy || (u2.stopy = bounds.getVerticalPos());
3265
- let p = await svgDraw_default.drawActor(t, u2, conf, true);
3266
- d2 = common_default.getMax(d2, p);
3267
- }
3268
- bounds.bumpVerticalPos(d2 + conf.boxMargin);
3269
- } else for (let d2 of u) {
3270
- let u2 = l.get(d2);
3271
- await svgDraw_default.drawActor(t, u2, conf, false);
3272
- }
3273
- }, "drawActors"), drawActorsPopup = /* @__PURE__ */ __name(function(t, l, u, d) {
3274
- let f = 0, p = 0;
3275
- for (let m of u) {
3276
- let u2 = l.get(m), h = getRequiredPopupWidth(u2), g = svgDraw_default.drawPopup(t, u2, h, conf, conf.forceMenus, d);
3277
- g.height > f && (f = g.height), g.width + u2.x > p && (p = g.width + u2.x);
3278
- }
3279
- return {
3280
- maxHeight: f,
3281
- maxWidth: p
3282
- };
3283
- }, "drawActorsPopup"), setConf = /* @__PURE__ */ __name(function(t) {
3284
- assignWithDepth_default(conf, t), t.fontFamily && (conf.actorFontFamily = conf.noteFontFamily = conf.messageFontFamily = t.fontFamily), t.fontSize && (conf.actorFontSize = conf.noteFontSize = conf.messageFontSize = t.fontSize), t.fontWeight && (conf.actorFontWeight = conf.noteFontWeight = conf.messageFontWeight = t.fontWeight);
3285
- }, "setConf"), actorActivations = /* @__PURE__ */ __name(function(t) {
3286
- return bounds.activations.filter(function(l) {
3287
- return l.actor === t;
3288
- });
3289
- }, "actorActivations"), activationBounds = /* @__PURE__ */ __name(function(t, l) {
3290
- let u = l.get(t), d = actorActivations(t);
3291
- return [d.reduce(function(t2, l2) {
3292
- return common_default.getMin(t2, l2.startx);
3293
- }, u.x + u.width / 2 - 1), d.reduce(function(t2, l2) {
3294
- return common_default.getMax(t2, l2.stopx);
3295
- }, u.x + u.width / 2 + 1)];
3296
- }, "activationBounds");
3297
- function adjustLoopHeightForWrap(l, u, f, p, m) {
3298
- bounds.bumpVerticalPos(f);
3299
- let h = p;
3300
- if (u.id && u.message && l[u.id]) {
3301
- let f2 = l[u.id].width, m2 = messageFont(conf);
3302
- u.message = utils_default.wrapLabel(`[${u.message}]`, f2 - 2 * conf.wrapPadding, m2), u.width = f2, u.wrap = true;
3303
- let g = utils_default.calculateTextDimensions(u.message, m2), _ = common_default.getMax(g.height, conf.labelBoxHeight);
3304
- h = p + _, log.debug(`${_} - ${u.message}`);
3305
- }
3306
- m(u), bounds.bumpVerticalPos(h);
3307
- }
3308
- __name(adjustLoopHeightForWrap, "adjustLoopHeightForWrap");
3309
- function adjustCreatedDestroyedData(t, l, u, d, p, m, h) {
3310
- function g(u2, d2) {
3311
- u2.x < p.get(t.from).x ? (bounds.insert(l.stopx - d2, l.starty, l.startx, l.stopy + u2.height / 2 + conf.noteMargin), l.stopx += d2) : (bounds.insert(l.startx, l.starty, l.stopx + d2, l.stopy + u2.height / 2 + conf.noteMargin), l.stopx -= d2);
3312
- }
3313
- __name(g, "receiverAdjustment");
3314
- function _(u2, d2) {
3315
- u2.x < p.get(t.to).x ? (bounds.insert(l.startx - d2, l.starty, l.stopx, l.stopy + u2.height / 2 + conf.noteMargin), l.startx += d2) : (bounds.insert(l.stopx, l.starty, l.startx + d2, l.stopy + u2.height / 2 + conf.noteMargin), l.startx -= d2);
3316
- }
3317
- __name(_, "senderAdjustment");
3318
- let v = [
3319
- PARTICIPANT_TYPE.ACTOR,
3320
- PARTICIPANT_TYPE.CONTROL,
3321
- PARTICIPANT_TYPE.ENTITY,
3322
- PARTICIPANT_TYPE.DATABASE
3323
- ];
3324
- if (m.get(t.to) == d) {
3325
- let l2 = p.get(t.to);
3326
- g(l2, v.includes(l2.type) ? ACTOR_TYPE_WIDTH / 2 + 3 : l2.width / 2 + 3), l2.starty = u - l2.height / 2, bounds.bumpVerticalPos(l2.height / 2);
3327
- } else if (h.get(t.from) == d) {
3328
- let l2 = p.get(t.from);
3329
- conf.mirrorActors && _(l2, v.includes(l2.type) ? ACTOR_TYPE_WIDTH / 2 : l2.width / 2), l2.stopy = u - l2.height / 2, bounds.bumpVerticalPos(l2.height / 2);
3330
- } else if (h.get(t.to) == d) {
3331
- let l2 = p.get(t.to);
3332
- conf.mirrorActors && g(l2, v.includes(l2.type) ? ACTOR_TYPE_WIDTH / 2 + 3 : l2.width / 2 + 3), l2.stopy = u - l2.height / 2, bounds.bumpVerticalPos(l2.height / 2);
3333
- }
3334
- }
3335
- __name(adjustCreatedDestroyedData, "adjustCreatedDestroyedData");
3336
- var draw = /* @__PURE__ */ __name(async function(t, l, u, m) {
3337
- let { securityLevel: h, sequence: g } = getConfig2();
3338
- conf = g;
3339
- let _;
3340
- h === "sandbox" && (_ = select_default("#i" + l));
3341
- let v = select_default(h === "sandbox" ? _.nodes()[0].contentDocument.body : "body"), y = h === "sandbox" ? _.nodes()[0].contentDocument : document;
3342
- bounds.init(), log.debug(m.db);
3343
- let b = h === "sandbox" ? v.select(`[id="${l}"]`) : select_default(`[id="${l}"]`), x = m.db.getActors(), S = m.db.getCreatedActors(), C = m.db.getDestroyedActors(), E = m.db.getBoxes(), D = m.db.getActorKeys(), O = m.db.getMessages(), k = m.db.getDiagramTitle(), A = m.db.hasAtLeastOneBox(), j = m.db.hasAtLeastOneBoxWithTitle(), M = await getMaxMessageWidthPerActor(x, O, m);
3344
- if (conf.height = await calculateActorMargins(x, M, E), svgDraw_default.insertComputerIcon(b), svgDraw_default.insertDatabaseIcon(b), svgDraw_default.insertClockIcon(b), A && (bounds.bumpVerticalPos(conf.boxMargin), j && bounds.bumpVerticalPos(E[0].textMaxHeight)), conf.hideUnusedParticipants === true) {
3345
- let t2 = /* @__PURE__ */ new Set();
3346
- O.forEach((l2) => {
3347
- t2.add(l2.from), t2.add(l2.to);
3348
- }), D = D.filter((l2) => t2.has(l2));
3349
- }
3350
- addActorRenderingData(b, x, S, D, 0, O, false);
3351
- let N = await calculateLoopBounds(O, x, M, m);
3352
- svgDraw_default.insertArrowHead(b), svgDraw_default.insertArrowCrossHead(b), svgDraw_default.insertArrowFilledHead(b), svgDraw_default.insertSequenceNumber(b);
3353
- function P(t2, l2) {
3354
- let u2 = bounds.endActivation(t2);
3355
- u2.starty + 18 > l2 && (u2.starty = l2 - 6, l2 += 12), svgDraw_default.drawActivation(b, u2, l2, conf, actorActivations(t2.from).length), bounds.insert(u2.startx, l2 - 10, u2.stopx, l2);
3356
- }
3357
- __name(P, "activeEnd");
3358
- let F = 1, I = 1, L = [], R = [], z = 0;
3359
- for (let t2 of O) {
3360
- let l2, u2, f;
3361
- switch (t2.type) {
3362
- case m.db.LINETYPE.NOTE:
3363
- bounds.resetVerticalPos(), u2 = t2.noteModel, await drawNote(b, u2);
3364
- break;
3365
- case m.db.LINETYPE.ACTIVE_START:
3366
- bounds.newActivation(t2, b, x);
3367
- break;
3368
- case m.db.LINETYPE.ACTIVE_END:
3369
- P(t2, bounds.getVerticalPos());
3370
- break;
3371
- case m.db.LINETYPE.LOOP_START:
3372
- adjustLoopHeightForWrap(N, t2, conf.boxMargin, conf.boxMargin + conf.boxTextMargin, (t3) => bounds.newLoop(t3));
3373
- break;
3374
- case m.db.LINETYPE.LOOP_END:
3375
- l2 = bounds.endLoop(), await svgDraw_default.drawLoop(b, l2, "loop", conf), bounds.bumpVerticalPos(l2.stopy - bounds.getVerticalPos()), bounds.models.addLoop(l2);
3376
- break;
3377
- case m.db.LINETYPE.RECT_START:
3378
- adjustLoopHeightForWrap(N, t2, conf.boxMargin, conf.boxMargin, (t3) => bounds.newLoop(void 0, t3.message));
3379
- break;
3380
- case m.db.LINETYPE.RECT_END:
3381
- l2 = bounds.endLoop(), R.push(l2), bounds.models.addLoop(l2), bounds.bumpVerticalPos(l2.stopy - bounds.getVerticalPos());
3382
- break;
3383
- case m.db.LINETYPE.OPT_START:
3384
- adjustLoopHeightForWrap(N, t2, conf.boxMargin, conf.boxMargin + conf.boxTextMargin, (t3) => bounds.newLoop(t3));
3385
- break;
3386
- case m.db.LINETYPE.OPT_END:
3387
- l2 = bounds.endLoop(), await svgDraw_default.drawLoop(b, l2, "opt", conf), bounds.bumpVerticalPos(l2.stopy - bounds.getVerticalPos()), bounds.models.addLoop(l2);
3388
- break;
3389
- case m.db.LINETYPE.ALT_START:
3390
- adjustLoopHeightForWrap(N, t2, conf.boxMargin, conf.boxMargin + conf.boxTextMargin, (t3) => bounds.newLoop(t3));
3391
- break;
3392
- case m.db.LINETYPE.ALT_ELSE:
3393
- adjustLoopHeightForWrap(N, t2, conf.boxMargin + conf.boxTextMargin, conf.boxMargin, (t3) => bounds.addSectionToLoop(t3));
3394
- break;
3395
- case m.db.LINETYPE.ALT_END:
3396
- l2 = bounds.endLoop(), await svgDraw_default.drawLoop(b, l2, "alt", conf), bounds.bumpVerticalPos(l2.stopy - bounds.getVerticalPos()), bounds.models.addLoop(l2);
3397
- break;
3398
- case m.db.LINETYPE.PAR_START:
3399
- case m.db.LINETYPE.PAR_OVER_START:
3400
- adjustLoopHeightForWrap(N, t2, conf.boxMargin, conf.boxMargin + conf.boxTextMargin, (t3) => bounds.newLoop(t3)), bounds.saveVerticalPos();
3401
- break;
3402
- case m.db.LINETYPE.PAR_AND:
3403
- adjustLoopHeightForWrap(N, t2, conf.boxMargin + conf.boxTextMargin, conf.boxMargin, (t3) => bounds.addSectionToLoop(t3));
3404
- break;
3405
- case m.db.LINETYPE.PAR_END:
3406
- l2 = bounds.endLoop(), await svgDraw_default.drawLoop(b, l2, "par", conf), bounds.bumpVerticalPos(l2.stopy - bounds.getVerticalPos()), bounds.models.addLoop(l2);
3407
- break;
3408
- case m.db.LINETYPE.AUTONUMBER:
3409
- F = t2.message.start || F, I = t2.message.step || I, t2.message.visible ? m.db.enableSequenceNumbers() : m.db.disableSequenceNumbers();
3410
- break;
3411
- case m.db.LINETYPE.CRITICAL_START:
3412
- adjustLoopHeightForWrap(N, t2, conf.boxMargin, conf.boxMargin + conf.boxTextMargin, (t3) => bounds.newLoop(t3));
3413
- break;
3414
- case m.db.LINETYPE.CRITICAL_OPTION:
3415
- adjustLoopHeightForWrap(N, t2, conf.boxMargin + conf.boxTextMargin, conf.boxMargin, (t3) => bounds.addSectionToLoop(t3));
3416
- break;
3417
- case m.db.LINETYPE.CRITICAL_END:
3418
- l2 = bounds.endLoop(), await svgDraw_default.drawLoop(b, l2, "critical", conf), bounds.bumpVerticalPos(l2.stopy - bounds.getVerticalPos()), bounds.models.addLoop(l2);
3419
- break;
3420
- case m.db.LINETYPE.BREAK_START:
3421
- adjustLoopHeightForWrap(N, t2, conf.boxMargin, conf.boxMargin + conf.boxTextMargin, (t3) => bounds.newLoop(t3));
3422
- break;
3423
- case m.db.LINETYPE.BREAK_END:
3424
- l2 = bounds.endLoop(), await svgDraw_default.drawLoop(b, l2, "break", conf), bounds.bumpVerticalPos(l2.stopy - bounds.getVerticalPos()), bounds.models.addLoop(l2);
3425
- break;
3426
- default:
3427
- try {
3428
- f = t2.msgModel, f.starty = bounds.getVerticalPos(), f.sequenceIndex = F, f.sequenceVisible = m.db.showSequenceNumbers();
3429
- let l3 = await boundMessage(b, f);
3430
- adjustCreatedDestroyedData(t2, f, l3, z, x, S, C), L.push({
3431
- messageModel: f,
3432
- lineStartY: l3
3433
- }), bounds.models.addMessage(f);
3434
- } catch (t3) {
3435
- log.error("error while drawing message", t3);
3436
- }
3437
- }
3438
- [
3439
- m.db.LINETYPE.SOLID_OPEN,
3440
- m.db.LINETYPE.DOTTED_OPEN,
3441
- m.db.LINETYPE.SOLID,
3442
- m.db.LINETYPE.DOTTED,
3443
- m.db.LINETYPE.SOLID_CROSS,
3444
- m.db.LINETYPE.DOTTED_CROSS,
3445
- m.db.LINETYPE.SOLID_POINT,
3446
- m.db.LINETYPE.DOTTED_POINT,
3447
- m.db.LINETYPE.BIDIRECTIONAL_SOLID,
3448
- m.db.LINETYPE.BIDIRECTIONAL_DOTTED
3449
- ].includes(t2.type) && (F += I), z++;
3450
- }
3451
- log.debug("createdActors", S), log.debug("destroyedActors", C), await drawActors(b, x, D, false);
3452
- for (let t2 of L) await drawMessage(b, t2.messageModel, t2.lineStartY, m);
3453
- conf.mirrorActors && await drawActors(b, x, D, true), R.forEach((t2) => svgDraw_default.drawBackgroundRect(b, t2)), fixLifeLineHeights(b, x, D, conf);
3454
- for (let t2 of bounds.models.boxes) {
3455
- t2.height = bounds.getVerticalPos() - t2.y, bounds.insert(t2.x, t2.y, t2.x + t2.width, t2.height);
3456
- let l2 = conf.boxMargin * 2;
3457
- t2.startx = t2.x - l2, t2.starty = t2.y - l2 * 0.25, t2.stopx = t2.startx + t2.width + 2 * l2, t2.stopy = t2.starty + t2.height + l2 * 0.75, t2.stroke = "rgb(0,0,0, 0.5)", svgDraw_default.drawBox(b, t2, conf);
3458
- }
3459
- A && bounds.bumpVerticalPos(conf.boxMargin);
3460
- let B = drawActorsPopup(b, x, D, y), { bounds: V } = bounds.getBounds();
3461
- V.startx === void 0 && (V.startx = 0), V.starty === void 0 && (V.starty = 0), V.stopx === void 0 && (V.stopx = 0), V.stopy === void 0 && (V.stopy = 0);
3462
- let H = V.stopy - V.starty;
3463
- H < B.maxHeight && (H = B.maxHeight);
3464
- let U = H + 2 * conf.diagramMarginY;
3465
- conf.mirrorActors && (U = U - conf.boxMargin + conf.bottomMarginAdj);
3466
- let W = V.stopx - V.startx;
3467
- W < B.maxWidth && (W = B.maxWidth);
3468
- let G = W + 2 * conf.diagramMarginX;
3469
- k && b.append("text").text(k).attr("x", (V.stopx - V.startx) / 2 - 2 * conf.diagramMarginX).attr("y", -25), configureSvgSize(b, U, G, conf.useMaxWidth);
3470
- let K = k ? 40 : 0;
3471
- b.attr("viewBox", V.startx - conf.diagramMarginX + " -" + (conf.diagramMarginY + K) + " " + G + " " + (U + K)), log.debug("models:", bounds.models);
3472
- }, "draw");
3473
- async function getMaxMessageWidthPerActor(l, u, f) {
3474
- let p = {};
3475
- for (let d of u) if (l.get(d.to) && l.get(d.from)) {
3476
- let u2 = l.get(d.to);
3477
- if (d.placement === f.db.PLACEMENT.LEFTOF && !u2.prevActor || d.placement === f.db.PLACEMENT.RIGHTOF && !u2.nextActor) continue;
3478
- let m = d.placement !== void 0, h = !m, g = m ? noteFont(conf) : messageFont(conf), _ = d.wrap ? utils_default.wrapLabel(d.message, conf.width - 2 * conf.wrapPadding, g) : d.message, v = (hasKatex(_) ? await calculateMathMLDimensions(d.message, getConfig2()) : utils_default.calculateTextDimensions(_, g)).width + 2 * conf.wrapPadding;
3479
- h && d.from === u2.nextActor ? p[d.to] = common_default.getMax(p[d.to] || 0, v) : h && d.from === u2.prevActor ? p[d.from] = common_default.getMax(p[d.from] || 0, v) : h && d.from === d.to ? (p[d.from] = common_default.getMax(p[d.from] || 0, v / 2), p[d.to] = common_default.getMax(p[d.to] || 0, v / 2)) : d.placement === f.db.PLACEMENT.RIGHTOF ? p[d.from] = common_default.getMax(p[d.from] || 0, v) : d.placement === f.db.PLACEMENT.LEFTOF ? p[u2.prevActor] = common_default.getMax(p[u2.prevActor] || 0, v) : d.placement === f.db.PLACEMENT.OVER && (u2.prevActor && (p[u2.prevActor] = common_default.getMax(p[u2.prevActor] || 0, v / 2)), u2.nextActor && (p[d.from] = common_default.getMax(p[d.from] || 0, v / 2)));
3480
- }
3481
- return log.debug("maxMessageWidthPerActor:", p), p;
3482
- }
3483
- __name(getMaxMessageWidthPerActor, "getMaxMessageWidthPerActor");
3484
- var getRequiredPopupWidth = /* @__PURE__ */ __name(function(l) {
3485
- let u = 0, d = actorFont(conf);
3486
- for (let f in l.links) {
3487
- let l2 = utils_default.calculateTextDimensions(f, d).width + 2 * conf.wrapPadding + 2 * conf.boxMargin;
3488
- u < l2 && (u = l2);
3489
- }
3490
- return u;
3491
- }, "getRequiredPopupWidth");
3492
- async function calculateActorMargins(l, u, d) {
3493
- let f = 0;
3494
- for (let u2 of l.keys()) {
3495
- let d2 = l.get(u2);
3496
- d2.wrap && (d2.description = utils_default.wrapLabel(d2.description, conf.width - 2 * conf.wrapPadding, actorFont(conf)));
3497
- let p2 = hasKatex(d2.description) ? await calculateMathMLDimensions(d2.description, getConfig2()) : utils_default.calculateTextDimensions(d2.description, actorFont(conf));
3498
- d2.width = d2.wrap ? conf.width : common_default.getMax(conf.width, p2.width + 2 * conf.wrapPadding), d2.height = d2.wrap ? common_default.getMax(p2.height, conf.height) : conf.height, f = common_default.getMax(f, d2.height);
3499
- }
3500
- for (let t in u) {
3501
- let d2 = l.get(t);
3502
- if (!d2) continue;
3503
- let f2 = l.get(d2.nextActor);
3504
- if (!f2) {
3505
- let l2 = u[t] + conf.actorMargin - d2.width / 2;
3506
- d2.margin = common_default.getMax(l2, conf.actorMargin);
3507
- continue;
3508
- }
3509
- let p2 = u[t] + conf.actorMargin - d2.width / 2 - f2.width / 2;
3510
- d2.margin = common_default.getMax(p2, conf.actorMargin);
3511
- }
3512
- let p = 0;
3513
- return d.forEach((u2) => {
3514
- let d2 = messageFont(conf), f2 = u2.actorKeys.reduce((t, u3) => t += l.get(u3).width + (l.get(u3).margin || 0), 0), m = conf.boxMargin * 8;
3515
- f2 += m, f2 -= 2 * conf.boxTextMargin, u2.wrap && (u2.name = utils_default.wrapLabel(u2.name, f2 - 2 * conf.wrapPadding, d2));
3516
- let h = utils_default.calculateTextDimensions(u2.name, d2);
3517
- p = common_default.getMax(h.height, p);
3518
- let g = common_default.getMax(f2, h.width + 2 * conf.wrapPadding);
3519
- if (u2.margin = conf.boxTextMargin, f2 < g) {
3520
- let t = (g - f2) / 2;
3521
- u2.margin += t;
3522
- }
3523
- }), d.forEach((t) => t.textMaxHeight = p), common_default.getMax(f, conf.height);
3524
- }
3525
- __name(calculateActorMargins, "calculateActorMargins");
3526
- var buildNoteModel = /* @__PURE__ */ __name(async function(l, u, f) {
3527
- let p = u.get(l.from), m = u.get(l.to), h = p.x, g = m.x, _ = l.wrap && l.message, v = hasKatex(l.message) ? await calculateMathMLDimensions(l.message, getConfig2()) : utils_default.calculateTextDimensions(_ ? utils_default.wrapLabel(l.message, conf.width, noteFont(conf)) : l.message, noteFont(conf)), y = {
3528
- width: _ ? conf.width : common_default.getMax(conf.width, v.width + 2 * conf.noteMargin),
3529
- height: 0,
3530
- startx: p.x,
3531
- stopx: 0,
3532
- starty: 0,
3533
- stopy: 0,
3534
- message: l.message
3535
- };
3536
- return l.placement === f.db.PLACEMENT.RIGHTOF ? (y.width = _ ? common_default.getMax(conf.width, v.width) : common_default.getMax(p.width / 2 + m.width / 2, v.width + 2 * conf.noteMargin), y.startx = h + (p.width + conf.actorMargin) / 2) : l.placement === f.db.PLACEMENT.LEFTOF ? (y.width = _ ? common_default.getMax(conf.width, v.width + 2 * conf.noteMargin) : common_default.getMax(p.width / 2 + m.width / 2, v.width + 2 * conf.noteMargin), y.startx = h - y.width + (p.width - conf.actorMargin) / 2) : l.to === l.from ? (v = utils_default.calculateTextDimensions(_ ? utils_default.wrapLabel(l.message, common_default.getMax(conf.width, p.width), noteFont(conf)) : l.message, noteFont(conf)), y.width = _ ? common_default.getMax(conf.width, p.width) : common_default.getMax(p.width, conf.width, v.width + 2 * conf.noteMargin), y.startx = h + (p.width - y.width) / 2) : (y.width = Math.abs(h + p.width / 2 - (g + m.width / 2)) + conf.actorMargin, y.startx = h < g ? h + p.width / 2 - conf.actorMargin / 2 : g + m.width / 2 - conf.actorMargin / 2), _ && (y.message = utils_default.wrapLabel(l.message, y.width - 2 * conf.wrapPadding, noteFont(conf))), log.debug(`NM:[${y.startx},${y.stopx},${y.starty},${y.stopy}:${y.width},${y.height}=${l.message}]`), y;
3537
- }, "buildNoteModel"), buildMessageModel = /* @__PURE__ */ __name(function(l, u, d) {
3538
- if (![
3539
- d.db.LINETYPE.SOLID_OPEN,
3540
- d.db.LINETYPE.DOTTED_OPEN,
3541
- d.db.LINETYPE.SOLID,
3542
- d.db.LINETYPE.DOTTED,
3543
- d.db.LINETYPE.SOLID_CROSS,
3544
- d.db.LINETYPE.DOTTED_CROSS,
3545
- d.db.LINETYPE.SOLID_POINT,
3546
- d.db.LINETYPE.DOTTED_POINT,
3547
- d.db.LINETYPE.BIDIRECTIONAL_SOLID,
3548
- d.db.LINETYPE.BIDIRECTIONAL_DOTTED
3549
- ].includes(l.type)) return {};
3550
- let [p, m] = activationBounds(l.from, u), [h, g] = activationBounds(l.to, u), _ = p <= h, v = _ ? m : p, y = _ ? h : g, b = Math.abs(h - g) > 2, x = /* @__PURE__ */ __name((t) => _ ? -t : t, "adjustValue");
3551
- l.from === l.to ? y = v : (l.activate && !b && (y += x(conf.activationWidth / 2 - 1)), [d.db.LINETYPE.SOLID_OPEN, d.db.LINETYPE.DOTTED_OPEN].includes(l.type) || (y += x(3)), [d.db.LINETYPE.BIDIRECTIONAL_SOLID, d.db.LINETYPE.BIDIRECTIONAL_DOTTED].includes(l.type) && (v -= x(3)));
3552
- let S = [
3553
- p,
3554
- m,
3555
- h,
3556
- g
3557
- ], C = Math.abs(v - y);
3558
- l.wrap && l.message && (l.message = utils_default.wrapLabel(l.message, common_default.getMax(C + 2 * conf.wrapPadding, conf.width), messageFont(conf)));
3559
- let w = utils_default.calculateTextDimensions(l.message, messageFont(conf));
3560
- return {
3561
- width: common_default.getMax(l.wrap ? 0 : w.width + 2 * conf.wrapPadding, C + 2 * conf.wrapPadding, conf.width),
3562
- height: 0,
3563
- startx: v,
3564
- stopx: y,
3565
- starty: 0,
3566
- stopy: 0,
3567
- message: l.message,
3568
- type: l.type,
3569
- wrap: l.wrap,
3570
- fromBounds: Math.min.apply(null, S),
3571
- toBounds: Math.max.apply(null, S)
3572
- };
3573
- }, "buildMessageModel"), calculateLoopBounds = /* @__PURE__ */ __name(async function(t, l, u, f) {
3574
- let p = {}, m = [], h, g, _;
3575
- for (let u2 of t) {
3576
- switch (u2.type) {
3577
- case f.db.LINETYPE.LOOP_START:
3578
- case f.db.LINETYPE.ALT_START:
3579
- case f.db.LINETYPE.OPT_START:
3580
- case f.db.LINETYPE.PAR_START:
3581
- case f.db.LINETYPE.PAR_OVER_START:
3582
- case f.db.LINETYPE.CRITICAL_START:
3583
- case f.db.LINETYPE.BREAK_START:
3584
- m.push({
3585
- id: u2.id,
3586
- msg: u2.message,
3587
- from: 2 ** 53 - 1,
3588
- to: -(2 ** 53 - 1),
3589
- width: 0
3590
- });
3591
- break;
3592
- case f.db.LINETYPE.ALT_ELSE:
3593
- case f.db.LINETYPE.PAR_AND:
3594
- case f.db.LINETYPE.CRITICAL_OPTION:
3595
- u2.message && (h = m.pop(), p[h.id] = h, p[u2.id] = h, m.push(h));
3596
- break;
3597
- case f.db.LINETYPE.LOOP_END:
3598
- case f.db.LINETYPE.ALT_END:
3599
- case f.db.LINETYPE.OPT_END:
3600
- case f.db.LINETYPE.PAR_END:
3601
- case f.db.LINETYPE.CRITICAL_END:
3602
- case f.db.LINETYPE.BREAK_END:
3603
- h = m.pop(), p[h.id] = h;
3604
- break;
3605
- case f.db.LINETYPE.ACTIVE_START:
3606
- {
3607
- let t2 = l.get(u2.from ? u2.from : u2.to.actor), d = actorActivations(u2.from ? u2.from : u2.to.actor).length, f2 = t2.x + t2.width / 2 + (d - 1) * conf.activationWidth / 2, p2 = {
3608
- startx: f2,
3609
- stopx: f2 + conf.activationWidth,
3610
- actor: u2.from,
3611
- enabled: true
3612
- };
3613
- bounds.activations.push(p2);
3614
- }
3615
- break;
3616
- case f.db.LINETYPE.ACTIVE_END:
3617
- {
3618
- let t2 = bounds.activations.map((t3) => t3.actor).lastIndexOf(u2.from);
3619
- bounds.activations.splice(t2, 1).splice(0, 1);
3620
- }
3621
- break;
3622
- }
3623
- u2.placement === void 0 ? (_ = buildMessageModel(u2, l, f), u2.msgModel = _, _.startx && _.stopx && m.length > 0 && m.forEach((t2) => {
3624
- if (h = t2, _.startx === _.stopx) {
3625
- let t3 = l.get(u2.from), d = l.get(u2.to);
3626
- h.from = common_default.getMin(t3.x - _.width / 2, t3.x - t3.width / 2, h.from), h.to = common_default.getMax(d.x + _.width / 2, d.x + t3.width / 2, h.to), h.width = common_default.getMax(h.width, Math.abs(h.to - h.from)) - conf.labelBoxWidth;
3627
- } else h.from = common_default.getMin(_.startx, h.from), h.to = common_default.getMax(_.stopx, h.to), h.width = common_default.getMax(h.width, _.width) - conf.labelBoxWidth;
3628
- })) : (g = await buildNoteModel(u2, l, f), u2.noteModel = g, m.forEach((t2) => {
3629
- h = t2, h.from = common_default.getMin(h.from, g.startx), h.to = common_default.getMax(h.to, g.startx + g.width), h.width = common_default.getMax(h.width, Math.abs(h.from - h.to)) - conf.labelBoxWidth;
3630
- }));
3631
- }
3632
- return bounds.activations = [], log.debug("Loop type widths:", p), p;
3633
- }, "calculateLoopBounds"), diagram = {
3634
- parser: sequenceDiagram_default,
3635
- get db() {
3636
- return new SequenceDB();
3637
- },
3638
- renderer: {
3639
- bounds,
3640
- drawActors,
3641
- drawActorsPopup,
3642
- setConf,
3643
- draw
3644
- },
3645
- styles: styles_default,
3646
- init: /* @__PURE__ */ __name((t) => {
3647
- t.sequence || (t.sequence = {}), t.wrap && (t.sequence.wrap = t.wrap, setConfig2({ sequence: { wrap: t.wrap } }));
3648
- }, "init")
3649
- };
3650
- export {
3651
- diagram
3652
- };