@marimo-team/frontend 0.19.7 → 0.19.8-dev1

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 (600) hide show
  1. package/dist/assets/{CellStatus-C5UGkPn6.js → CellStatus-CTtb89yx.js} +1 -1
  2. package/dist/assets/{ConnectedDataExplorerComponent-CCkOUPJb.js → ConnectedDataExplorerComponent-CX7YQX42.js} +1 -1
  3. package/dist/assets/{ImperativeModal-CUbWEBci.js → ImperativeModal-CKeCkc1k.js} +1 -1
  4. package/dist/assets/{JsonOutput-CknFTI_u.js → JsonOutput-BTBD86gT.js} +8 -8
  5. package/dist/assets/LazyAnyLanguageCodeMirror-Be7SB10I.js +2 -0
  6. package/dist/assets/{MarimoErrorOutput-5rudBbo3.js → MarimoErrorOutput-DuaUr0W-.js} +5 -5
  7. package/dist/assets/{RenderHTML-CQZqVk1Z.js → RenderHTML-IBhB_MjX.js} +1 -1
  8. package/dist/assets/{add-cell-with-ai-pVFp5LZG.js → add-cell-with-ai-DsiiVErB.js} +8 -8
  9. package/dist/assets/{add-database-form-3g4nuZN1.js → add-database-form-B1frIn24.js} +2 -2
  10. package/dist/assets/{agent-panel-DboxNcTk.js → agent-panel-B_Ur2utx.js} +6 -6
  11. package/dist/assets/ai-model-dropdown-Dix8JIRc.js +5 -0
  12. package/dist/assets/{alert-dialog-DwQffb13.js → alert-dialog-CordKci7.js} +1 -1
  13. package/dist/assets/{any-language-editor-BMlwpEZ4.js → any-language-editor-Z9d2XKUM.js} +1 -1
  14. package/dist/assets/apl-DpOiWl6J.js +1 -0
  15. package/dist/assets/app-config-button-CYFJH9oz.js +1 -0
  16. package/dist/assets/{arc-3DY1fURi.js → arc-xh3ZebK_.js} +1 -1
  17. package/dist/assets/{architecture-U656AL7Q-h8chitwC.js → architecture-U656AL7Q-DQB1ihe9.js} +1 -1
  18. package/dist/assets/{architectureDiagram-VXUJARFQ-CbY--qni.js → architectureDiagram-VXUJARFQ-B-zQV2Ro.js} +1 -1
  19. package/dist/assets/asciiarmor-DVIuYySe.js +1 -0
  20. package/dist/assets/asn1-CWHjZJq6.js +1 -0
  21. package/dist/assets/{blockDiagram-VD42YOAC-BqCwBNes.js → blockDiagram-VD42YOAC-B7BRAty8.js} +1 -1
  22. package/dist/assets/brainfuck-CIKJewgG.js +1 -0
  23. package/dist/assets/{c4Diagram-YG6GDRKO-Dl34pnAp.js → c4Diagram-YG6GDRKO-C5JyC9v_.js} +1 -1
  24. package/dist/assets/{cache-panel-BHX9f5Bx.js → cache-panel-BfCxvTOh.js} +1 -1
  25. package/dist/assets/card-BAxUmnnT.js +1 -0
  26. package/dist/assets/{cell-editor-CeBmoryT.js → cell-editor-BQ5bBOiS.js} +9 -9
  27. package/dist/assets/cell-link-DW0zobk9.js +1 -0
  28. package/dist/assets/{cells-BpZ7g6ok.js → cells-BcMpgRWV.js} +52 -52
  29. package/dist/assets/channel-ownMsSXG.js +1 -0
  30. package/dist/assets/chat-components-BpIX7pUp.js +1 -0
  31. package/dist/assets/{chat-display-B4mGvJ0X.js → chat-display-CVXM0cmr.js} +1 -1
  32. package/dist/assets/chat-panel-FiDMP_Qr.js +3 -0
  33. package/dist/assets/{chunk-4BX2VUAB-BpI4ekYZ.js → chunk-4BX2VUAB-BP-RGZn9.js} +1 -1
  34. package/dist/assets/chunk-55IACEB6-NZRDKuqH.js +1 -0
  35. package/dist/assets/{chunk-5FQGJX7Z-CVUXBqX6.js → chunk-5FQGJX7Z-Bmb7yu_c.js} +2 -2
  36. package/dist/assets/{chunk-ABZYJK2D-t8l6Viza.js → chunk-ABZYJK2D-Coo5qi7b.js} +3 -3
  37. package/dist/assets/{chunk-ATLVNIR6-VxibvAOV.js → chunk-ATLVNIR6-C0ULYreM.js} +1 -1
  38. package/dist/assets/{chunk-B4BG7PRW-Dm0tRCOk.js → chunk-B4BG7PRW-D6Q5lT5Z.js} +1 -1
  39. package/dist/assets/{chunk-CVBHYZKI-CsebuiSO.js → chunk-CVBHYZKI-Brsoob-W.js} +1 -1
  40. package/dist/assets/{chunk-DI55MBZ5-BNViV6Iv.js → chunk-DI55MBZ5-BUUtkB-8.js} +1 -1
  41. package/dist/assets/{chunk-EXTU4WIE-CyW9PraH.js → chunk-EXTU4WIE-DQy5cN5X.js} +1 -1
  42. package/dist/assets/{chunk-FMBD7UC4-Cn7KHL11.js → chunk-FMBD7UC4-kejklSRQ.js} +1 -1
  43. package/dist/assets/{chunk-HN2XXSSU-Bw_9WyjM.js → chunk-HN2XXSSU-BBxJMYrA.js} +1 -1
  44. package/dist/assets/{chunk-JA3XYJ7Z-CaauVIYw.js → chunk-JA3XYJ7Z-99Y1UR46.js} +1 -1
  45. package/dist/assets/{chunk-JZLCHNYA-cYgsW1_e.js → chunk-JZLCHNYA-DRGkEV50.js} +1 -1
  46. package/dist/assets/{chunk-MI3HLSF2-Csy17Fj5.js → chunk-MI3HLSF2-D6we5Ftb.js} +1 -1
  47. package/dist/assets/{chunk-N4CR4FBY-eo9CRI73.js → chunk-N4CR4FBY-DHFG9ldR.js} +2 -2
  48. package/dist/assets/{chunk-QN33PNHL-C_hHv997.js → chunk-QN33PNHL-DB8FgLRd.js} +1 -1
  49. package/dist/assets/{chunk-QXUST7PY-CUUVFKsm.js → chunk-QXUST7PY-_zxuSm7L.js} +1 -1
  50. package/dist/assets/{chunk-QZHKN3VN-bGLTeFnj.js → chunk-QZHKN3VN-DCq7JxLD.js} +1 -1
  51. package/dist/assets/{chunk-S3R3BYOJ-DgPGJLrA.js → chunk-S3R3BYOJ-PVCoxQeQ.js} +1 -1
  52. package/dist/assets/{chunk-TZMSLE5B-DFEUz811.js → chunk-TZMSLE5B-KYGSDxPK.js} +1 -1
  53. package/dist/assets/classDiagram-2ON5EDUG-CSgD2v8F.js +1 -0
  54. package/dist/assets/classDiagram-v2-WZHVMYZB-YTETTIT0.js +1 -0
  55. package/dist/assets/{clike-Db5sDcCN.js → clike-wo4CVrJj.js} +1 -1
  56. package/dist/assets/clojure-CTxjMkBI.js +1 -0
  57. package/dist/assets/cmake-aJ0aGjat.js +1 -0
  58. package/dist/assets/cobol-Dw9T4cw-.js +1 -0
  59. package/dist/assets/{code-block-37QAKDTI-Bq6pD3J6.js → code-block-37QAKDTI-D5PRUB7R.js} +1 -1
  60. package/dist/assets/coffeescript-B5HCKl_0.js +1 -0
  61. package/dist/assets/column-preview-v3J210SK.js +1 -0
  62. package/dist/assets/{command-DhzFN2CJ.js → command-DOzj5zu3.js} +1 -1
  63. package/dist/assets/command-palette-B94wuFEk.js +1 -0
  64. package/dist/assets/{common-dAEMv5ry.js → common-DHF6uQdA.js} +1 -1
  65. package/dist/assets/commonlisp-C578hhl1.js +1 -0
  66. package/dist/assets/config-C3-Nti03.js +1 -0
  67. package/dist/assets/{context-JwD-oSsl.js → context-CJp-B2dx.js} +1 -1
  68. package/dist/assets/{copy-icon-BhONVREY.js → copy-icon-C1fNHY3M.js} +1 -1
  69. package/dist/assets/{cose-bilkent-S5V4N54A-BJlSv6jX.js → cose-bilkent-S5V4N54A-vYRNxW8r.js} +1 -1
  70. package/dist/assets/crystal-D84c1nzD.js +1 -0
  71. package/dist/assets/{css-DPSOOi60.js → css-BJsW3aHa.js} +1 -1
  72. package/dist/assets/cypher-DBO3MHmN.js +1 -0
  73. package/dist/assets/d-KvHiAR3H.js +1 -0
  74. package/dist/assets/{dagre-6UL2VRFP-gcBtYL2X.js → dagre-6UL2VRFP-khPiqbzB.js} +1 -1
  75. package/dist/assets/{data-grid-overlay-editor-Cty9HaeD.js → data-grid-overlay-editor-Ca1ELXWD.js} +1 -1
  76. package/dist/assets/{datasource-B0OJBphG.js → datasource-BZ3O2HG1.js} +2 -2
  77. package/dist/assets/{dates-Dhn1r-h6.js → dates-Cx863TsG.js} +1 -1
  78. package/dist/assets/dependency-graph-panel-s45LIDec.js +4 -0
  79. package/dist/assets/{diagram-PSM6KHXK-CoEONPpr.js → diagram-PSM6KHXK-C7-DZLOE.js} +1 -1
  80. package/dist/assets/{diagram-QEK2KX5R-B1m8kE9K.js → diagram-QEK2KX5R-Ct2_XsRV.js} +1 -1
  81. package/dist/assets/{diagram-S2PKOQOG-BBYN_e8t.js → diagram-S2PKOQOG-C82IZoPA.js} +1 -1
  82. package/dist/assets/dialog-Dstm3Ubn.js +1 -0
  83. package/dist/assets/diff-BmUpKGx-.js +1 -0
  84. package/dist/assets/{dist-Ad37Z4TC.js → dist-1nstYXhq.js} +1 -1
  85. package/dist/assets/{dist-fX0SBNCK.js → dist-2qScxWoK.js} +1 -1
  86. package/dist/assets/dist-8LCoAaYJ.js +1 -0
  87. package/dist/assets/{dist-BYEzs7zM.js → dist-B6bNYRJb.js} +1 -1
  88. package/dist/assets/dist-BKMynip3.js +1 -0
  89. package/dist/assets/{dist-CYdfU9am.js → dist-BP1tfplb.js} +1 -1
  90. package/dist/assets/{dist-CdBsAJTp.js → dist-BhLw_JdQ.js} +1 -1
  91. package/dist/assets/dist-BuwU3nUf.js +1 -0
  92. package/dist/assets/{dist-B_YgElQP.js → dist-BwcKpTZt.js} +1 -1
  93. package/dist/assets/{dist-Chrniyxe.js → dist-DXT0W0hS.js} +1 -1
  94. package/dist/assets/dist-DrFRlZJz.js +1 -0
  95. package/dist/assets/{dist-Dnr44J-w.js → dist-DzjeKTWA.js} +1 -1
  96. package/dist/assets/{dist-uzvC4uAK.js → dist-PT7WsOdN.js} +1 -1
  97. package/dist/assets/{dist-rTuWF9u4.js → dist-QPLTo43F.js} +1 -1
  98. package/dist/assets/{dist-0C6YCYyu.js → dist-YQMqR1ri.js} +1 -1
  99. package/dist/assets/{dist-CIhvkX-u.js → dist-h7FGpi6W.js} +1 -1
  100. package/dist/assets/{dockerfile-pmRcusjN.js → dockerfile-BPCA7-hu.js} +1 -1
  101. package/dist/assets/documentation-panel-DRqbOPwM.js +1 -0
  102. package/dist/assets/download-zuPzhwvm.js +9 -0
  103. package/dist/assets/{dropdown-menu-B-6unW-7.js → dropdown-menu-D8v7RjW8.js} +1 -1
  104. package/dist/assets/dtd-Dwf-AbUl.js +1 -0
  105. package/dist/assets/dylan-VHUB-7ez.js +1 -0
  106. package/dist/assets/ecl-DvGrObaA.js +1 -0
  107. package/dist/assets/{edit-page-D3Eg7nUs.js → edit-page-Dlr4v1eI.js} +7 -7
  108. package/dist/assets/eiffel-CUYga93e.js +1 -0
  109. package/dist/assets/elm-BhMhmEP6.js +1 -0
  110. package/dist/assets/{erDiagram-Q2GNP2WA-C1xdmPJj.js → erDiagram-Q2GNP2WA-Ftt2qDiM.js} +1 -1
  111. package/dist/assets/erlang-D4xbdJFD.js +1 -0
  112. package/dist/assets/{error-banner-DUzsIXtq.js → error-banner-JIexM8h5.js} +1 -1
  113. package/dist/assets/error-panel-TqjIx6nC.js +1 -0
  114. package/dist/assets/{es-D8BOePqo.js → es-CPSXxuS6.js} +1 -1
  115. package/dist/assets/{esm-DpMp6qko.js → esm-BbNm2fB0.js} +1 -1
  116. package/dist/assets/{esm-l4kcybiY.js → esm-BmQh-C2G.js} +1 -1
  117. package/dist/assets/factor-C0grrWrC.js +1 -0
  118. package/dist/assets/{factor-Di_n0Vcb.js → factor-Ccw_GUUV.js} +1 -1
  119. package/dist/assets/field-1uCBX4j4.js +1 -0
  120. package/dist/assets/file-explorer-panel-jku_uMQn.js +1 -0
  121. package/dist/assets/{floating-outline-DcxjrFFt.js → floating-outline-CZbF47gm.js} +1 -1
  122. package/dist/assets/{flowDiagram-NV44I4VS-Cl0HZ_gT.js → flowDiagram-NV44I4VS-Ca9aZp-3.js} +1 -1
  123. package/dist/assets/{focus-D51fcwZX.js → focus-BxGelf2n.js} +1 -1
  124. package/dist/assets/form-DQt-Ldr4.js +2 -0
  125. package/dist/assets/{formats-W1SWxSE3.js → formats-CobRswjh.js} +1 -1
  126. package/dist/assets/forth-CSTdXn4A.js +1 -0
  127. package/dist/assets/fortran-fENQO2l9.js +1 -0
  128. package/dist/assets/gallery-page-D_5X4kKx.js +1 -0
  129. package/dist/assets/{ganttDiagram-JELNMOA3-BpE9RPjJ.js → ganttDiagram-JELNMOA3-PYFPdyuJ.js} +1 -1
  130. package/dist/assets/gas-CPJMP4zj.js +1 -0
  131. package/dist/assets/gherkin-CiUmN4EE.js +1 -0
  132. package/dist/assets/{gitGraph-F6HP7TQM-BeFUiPbI.js → gitGraph-F6HP7TQM-ULnyMCh9.js} +1 -1
  133. package/dist/assets/{gitGraphDiagram-NY62KEGX-D649tm7F.js → gitGraphDiagram-NY62KEGX-CfGWoYOo.js} +1 -1
  134. package/dist/assets/{glide-data-editor-HGkaxqOo.js → glide-data-editor-8ek3zzAO.js} +18 -18
  135. package/dist/assets/{globals-DKH14XH0.js → globals-D4t_HyAp.js} +1 -1
  136. package/dist/assets/groovy-DMooZA1X.js +1 -0
  137. package/dist/assets/haskell-sDlThg6u.js +1 -0
  138. package/dist/assets/haxe-Do80ITri.js +1 -0
  139. package/dist/assets/home-page-xDhfcHL1.js +4 -0
  140. package/dist/assets/{hooks-CotXIFzV.js → hooks-MQa8CSUr.js} +1 -1
  141. package/dist/assets/{html-to-image-DjukyIj4.js → html-to-image-DKqpcM7V.js} +1 -1
  142. package/dist/assets/idl-DFPg6k4F.js +1 -0
  143. package/dist/assets/index-DuqUGjtK.js +38 -0
  144. package/dist/assets/{info-NVLQJR56-DbEISpBO.js → info-NVLQJR56-gsco60Pt.js} +1 -1
  145. package/dist/assets/infoDiagram-WHAUD3N6-Csbwq6Ks.js +2 -0
  146. package/dist/assets/input-DcAGg_4_.js +1 -0
  147. package/dist/assets/javascript-BGc4iHiT.js +1 -0
  148. package/dist/assets/{journeyDiagram-XKPGCS4Q-BOKoLZRY.js → journeyDiagram-XKPGCS4Q-DArwMxlY.js} +1 -1
  149. package/dist/assets/julia-BHNHVraD.js +1 -0
  150. package/dist/assets/{kanban-definition-3W4ZIXB7-PPWsqDVb.js → kanban-definition-3W4ZIXB7-CPjBJiO_.js} +1 -1
  151. package/dist/assets/katex-BZrXWsTs.js +1 -0
  152. package/dist/assets/{kiosk-mode-B5u1Ptdj.js → kiosk-mode-C9XznhoS.js} +1 -1
  153. package/dist/assets/{label-Be1daUcS.js → label-CL9Xfexh.js} +1 -1
  154. package/dist/assets/{layout-B1RE_FQ4.js → layout-D-YPCWvX.js} +4 -4
  155. package/dist/assets/{line-BCZzhM6G.js → line-VKarCWVL.js} +1 -1
  156. package/dist/assets/{linear-DjglEiG4.js → linear-BxhToEEF.js} +1 -1
  157. package/dist/assets/links-DgZx-VxW.js +1 -0
  158. package/dist/assets/livescript-Bv2FpOTI.js +1 -0
  159. package/dist/assets/logs-panel-DKSJRyF4.js +1 -0
  160. package/dist/assets/{loro_wasm_bg-C4rb9m-K.js → loro_wasm_bg-CKQGJrH5.js} +1 -1
  161. package/dist/assets/lua-BysKHKPZ.js +1 -0
  162. package/dist/assets/{markdown-renderer-DhMlG2dP.js → markdown-renderer-Bu12gPyJ.js} +1 -1
  163. package/dist/assets/mathematica-BBTHoTvM.js +1 -0
  164. package/dist/assets/mbox-DeT9_lvk.js +1 -0
  165. package/dist/assets/{menu-items-CJhvWPOk.js → menu-items-NblnuU_B.js} +1 -1
  166. package/dist/assets/mermaid-4DMBBIKO-RE7Z6-fl.js +1 -0
  167. package/dist/assets/{mermaid-BG5ill_a.js → mermaid-Bzaf_nA9.js} +3 -3
  168. package/dist/assets/{mermaid-parser.core-BQwQ8Y_u.js → mermaid-parser.core-D237JwYN.js} +2 -2
  169. package/dist/assets/{mhchem-4Yr1r21Y.js → mhchem-DLDYYsJK.js} +1 -1
  170. package/dist/assets/{mindmap-definition-VGOIOE7T-CfwhT5_2.js → mindmap-definition-VGOIOE7T-DVB4z5Yy.js} +1 -1
  171. package/dist/assets/mirc-D5fMSrXQ.js +1 -0
  172. package/dist/assets/mllike-BtxCpmpf.js +1 -0
  173. package/dist/assets/mode-CevBiFCd.js +1 -0
  174. package/dist/assets/modelica-CRQcZpK6.js +1 -0
  175. package/dist/assets/mscgen-BfscU11q.js +1 -0
  176. package/dist/assets/multi-map-W4zci54U.js +1 -0
  177. package/dist/assets/mumps-g7ooySbl.js +1 -0
  178. package/dist/assets/{name-cell-input-FC1vzor8.js → name-cell-input-DwvdP1Ck.js} +1 -1
  179. package/dist/assets/nsis-BtyCmCHZ.js +1 -0
  180. package/dist/assets/{nsis-Bh7CNuij.js → nsis-CzZqoCdu.js} +1 -1
  181. package/dist/assets/ntriples-DLyxF-NO.js +1 -0
  182. package/dist/assets/{number-overlay-editor-Ausf18nY.js → number-overlay-editor-CvIcqV0W.js} +1 -1
  183. package/dist/assets/octave-CFXP_zzr.js +1 -0
  184. package/dist/assets/{ordinal-DTOdb5Da.js → ordinal-C93T4L8H.js} +1 -1
  185. package/dist/assets/outline-panel-Bg_CP1WV.js +1 -0
  186. package/dist/assets/oz-CrQbC0N_.js +1 -0
  187. package/dist/assets/packages-panel-DBgrbk-q.js +1 -0
  188. package/dist/assets/{packet-BFZMPI3H-BR6bDXQk.js → packet-BFZMPI3H-CnHEXEVi.js} +1 -1
  189. package/dist/assets/panels-CaoDGKmF.js +1 -0
  190. package/dist/assets/pascal-CCSZgYZH.js +1 -0
  191. package/dist/assets/paths-Dfii2bN8.js +1 -0
  192. package/dist/assets/perl-Bc1MycMl.js +1 -0
  193. package/dist/assets/{pie-7BOR55EZ-Dya4O8xg.js → pie-7BOR55EZ-C5Sp4r8f.js} +1 -1
  194. package/dist/assets/{pieDiagram-ADFJNKIX-DnzHEEdh.js → pieDiagram-ADFJNKIX-vwwb5uL8.js} +1 -1
  195. package/dist/assets/pig-CDr04RdE.js +1 -0
  196. package/dist/assets/{popover-Gz-GJzym.js → popover-BZZFx3Q8.js} +1 -1
  197. package/dist/assets/powershell-DcvrUwmh.js +1 -0
  198. package/dist/assets/{precisionRound-BMPhtTJQ.js → precisionRound-CU2C3Vxx.js} +1 -1
  199. package/dist/assets/{process-output-CagdHMzs.js → process-output-Cl2N-HlT.js} +1 -1
  200. package/dist/assets/properties-Y8OgFJMt.js +1 -0
  201. package/dist/assets/protobuf-Dyx-ENis.js +1 -0
  202. package/dist/assets/{pug-DEhrk7ZA.js → pug-BqLMXh-D.js} +1 -1
  203. package/dist/assets/pug-T7qjkmFh.js +1 -0
  204. package/dist/assets/puppet-BzYSg90u.js +1 -0
  205. package/dist/assets/python-D4S7tVrv.js +1 -0
  206. package/dist/assets/q-YpqabiSl.js +1 -0
  207. package/dist/assets/{quadrantDiagram-AYHSOK5B-B6T0wyQJ.js → quadrantDiagram-AYHSOK5B-Y8bEZ32G.js} +1 -1
  208. package/dist/assets/r-DzpuVbmQ.js +1 -0
  209. package/dist/assets/{radar-NHE76QYJ-CwXZHOPM.js → radar-NHE76QYJ-DAElyE_r.js} +1 -1
  210. package/dist/assets/{react-plotly-V8H4ohaU.js → react-plotly-CZMBCa5P.js} +1 -1
  211. package/dist/assets/{react-vega-CoHwoAp_.js → react-vega-BCDifxTe.js} +1 -1
  212. package/dist/assets/react-vega-DkHO4e2L.js +1 -0
  213. package/dist/assets/{readonly-python-code-DyP9LVLc.js → readonly-python-code-H1kzT-lB.js} +1 -1
  214. package/dist/assets/{renderShortcut-DEwfrKeS.js → renderShortcut-zxgoVTeP.js} +1 -1
  215. package/dist/assets/{requirementDiagram-UZGBJVZJ-BL1cpcB7.js → requirementDiagram-UZGBJVZJ-ChckaTrX.js} +1 -1
  216. package/dist/assets/rpm-DlmAEsH3.js +1 -0
  217. package/dist/assets/ruby-BHSBK3B4.js +1 -0
  218. package/dist/assets/run-page-BmTC7uxn.js +1 -0
  219. package/dist/assets/{sankeyDiagram-TZEHDZUN-DqWtGnca.js → sankeyDiagram-TZEHDZUN-DtU4O0-i.js} +1 -1
  220. package/dist/assets/sas-DmQmrPAn.js +1 -0
  221. package/dist/assets/scheme-CZHvt0eC.js +1 -0
  222. package/dist/assets/scratchpad-panel-CIxZIJ-1.js +1 -0
  223. package/dist/assets/{secrets-panel-BaEqnh6m.js → secrets-panel-TwfjwIVv.js} +1 -1
  224. package/dist/assets/select-CX1Yi8J8.js +1 -0
  225. package/dist/assets/{sequenceDiagram-WL72ISMW-DX-71FKf.js → sequenceDiagram-WL72ISMW-BGXrTemh.js} +1 -1
  226. package/dist/assets/session-fBtIbMpB.js +1 -0
  227. package/dist/assets/session-panel-CNeWVmTR.js +1 -0
  228. package/dist/assets/shell-BJzvpTMz.js +1 -0
  229. package/dist/assets/sieve-DGjPhm-6.js +1 -0
  230. package/dist/assets/{slides-component-DP2pxhDh.js → slides-component-CGMJm_kL.js} +1 -1
  231. package/dist/assets/smalltalk-DaG60CSr.js +1 -0
  232. package/dist/assets/snippets-panel-DMN_ZSXA.js +1 -0
  233. package/dist/assets/sparql-CN49rXKB.js +1 -0
  234. package/dist/assets/{src-Cf4NnJCp.js → src-DJ8ZKoFs.js} +1 -1
  235. package/dist/assets/{state-BfXVTTtD.js → state-BLsnFVwy.js} +1 -1
  236. package/dist/assets/{stateDiagram-FKZM4ZOC-DiTrx4-Q.js → stateDiagram-FKZM4ZOC-BwSf7RIr.js} +1 -1
  237. package/dist/assets/stateDiagram-v2-4FDKWEC3-SWMI9LKY.js +1 -0
  238. package/dist/assets/{step-COhf-b0R.js → step-DGkZosD0.js} +1 -1
  239. package/dist/assets/stylus-CzHZ_0CL.js +1 -0
  240. package/dist/assets/swift-5fr5bTbW.js +1 -0
  241. package/dist/assets/{switch-8sn_4qbh.js → switch-CfRu5JBF.js} +1 -1
  242. package/dist/assets/tcl-D5oaR_GS.js +1 -0
  243. package/dist/assets/{terminal-C7HXI-7B.js → terminal-C0fH4d_0.js} +2 -2
  244. package/dist/assets/{textarea-DBO30D7K.js → textarea-3ZXdUni1.js} +1 -1
  245. package/dist/assets/textile-CJ5e8-7o.js +1 -0
  246. package/dist/assets/{time-lLuPpFd-.js → time-EL4bnqqQ.js} +1 -1
  247. package/dist/assets/{timeline-definition-IT6M3QCI-BuvaeqF7.js → timeline-definition-IT6M3QCI-BZakpQwy.js} +1 -1
  248. package/dist/assets/{toggle-jWKnIArU.js → toggle-CWS-iCmF.js} +1 -1
  249. package/dist/assets/toml-D9QwsDZO.js +1 -0
  250. package/dist/assets/{tooltip-CEc2ajau.js → tooltip-DH6k_bBY.js} +1 -1
  251. package/dist/assets/{tooltip-BGrCWNss.js → tooltip-DxKBXCGp.js} +1 -1
  252. package/dist/assets/tracing-panel-DogOVTzf.js +2 -0
  253. package/dist/assets/tracing-zzjDz6Hy.js +1 -0
  254. package/dist/assets/{tree-B1vM35Zj.js → tree-DHpFOpHo.js} +1 -1
  255. package/dist/assets/{treemap-KMMF4GRG-CG4hZ-Cn.js → treemap-KMMF4GRG-Bf9yeA5X.js} +1 -1
  256. package/dist/assets/troff-DlwQJbfr.js +1 -0
  257. package/dist/assets/ttcn-DUvoO9Vo.js +1 -0
  258. package/dist/assets/ttcn-cfg-Cj-t-B3M.js +1 -0
  259. package/dist/assets/turtle-DzvxCIjc.js +1 -0
  260. package/dist/assets/{types-DuQOSW7G.js → types-CW-zyy80.js} +1 -1
  261. package/dist/assets/{useAddCell-BmeZUK02.js → useAddCell-mkD8zurm.js} +1 -1
  262. package/dist/assets/{useBoolean-B1Xeh6vA.js → useBoolean-BjVFTMam.js} +1 -1
  263. package/dist/assets/useCellActionButton-BZ46_Pdt.js +1 -0
  264. package/dist/assets/{useDateFormatter-CS4kbWl2.js → useDateFormatter-D89e9xZY.js} +1 -1
  265. package/dist/assets/{useDeleteCell-5uYlTcQZ.js → useDeleteCell-B8CxYiji.js} +1 -1
  266. package/dist/assets/{useDependencyPanelTab-P4LD32r5.js → useDependencyPanelTab-YtWR0xDK.js} +1 -1
  267. package/dist/assets/{useInstallPackage-Bdnnp5fe.js → useInstallPackage-C-gjrVjb.js} +1 -1
  268. package/dist/assets/useNotebookActions-Dfh_7NPm.js +1 -0
  269. package/dist/assets/{useNumberFormatter-c6GXymzg.js → useNumberFormatter-CTkflual.js} +1 -1
  270. package/dist/assets/{usePress-Bup4EGrp.js → usePress-CoEeT5jq.js} +1 -1
  271. package/dist/assets/{useRunCells-24p6hn99.js → useRunCells-rjrIgU8v.js} +1 -1
  272. package/dist/assets/{useSplitCell-C8MYZz7z.js → useSplitCell-fcjSuBNO.js} +1 -1
  273. package/dist/assets/{utilities.esm-CIPARd6-.js → utilities.esm-CkqwfzLw.js} +3 -3
  274. package/dist/assets/vb-Caf126uo.js +1 -0
  275. package/dist/assets/vbscript-BgRl-LR8.js +1 -0
  276. package/dist/assets/vega-component-DAJbxD47.js +1 -0
  277. package/dist/assets/{vega-loader.browser-CRZ52CKf.js → vega-loader.browser-DXARUlxo.js} +1 -1
  278. package/dist/assets/velocity-CpvfwasF.js +1 -0
  279. package/dist/assets/verilog-hsHogyKv.js +1 -0
  280. package/dist/assets/vhdl-FciHazR1.js +1 -0
  281. package/dist/assets/webidl-CqjZNx5V.js +1 -0
  282. package/dist/assets/{write-secret-modal-CpmU5gbF.js → write-secret-modal-CgAvgY9w.js} +1 -1
  283. package/dist/assets/x-CoXDX2vQ.js +1 -0
  284. package/dist/assets/xquery-DpTaL2IT.js +1 -0
  285. package/dist/assets/{xychartDiagram-PRI3JC2R-HVlMJ22G.js → xychartDiagram-PRI3JC2R-CAHFvN1H.js} +1 -1
  286. package/dist/assets/yacas-D6bbkHsk.js +1 -0
  287. package/dist/assets/z80-MlujNizn.js +1 -0
  288. package/dist/index.html +99 -95
  289. package/package.json +1 -1
  290. package/src/components/pages/gallery-page.tsx +158 -0
  291. package/src/core/MarimoApp.tsx +8 -0
  292. package/src/core/mode.ts +4 -3
  293. package/src/core/run-app.tsx +26 -1
  294. package/src/mount.tsx +9 -7
  295. package/dist/assets/LazyAnyLanguageCodeMirror-yzHjsVJt.js +0 -2
  296. package/dist/assets/ai-model-dropdown-71lgLrLy.js +0 -5
  297. package/dist/assets/apl-Dkj9Qe7k.js +0 -1
  298. package/dist/assets/app-config-button-d7RvqO40.js +0 -1
  299. package/dist/assets/asciiarmor-BtQZNUPe.js +0 -1
  300. package/dist/assets/asn1-Df2Lrqg5.js +0 -1
  301. package/dist/assets/brainfuck-BKWhJvy5.js +0 -1
  302. package/dist/assets/cell-link-Bw5bzt4a.js +0 -1
  303. package/dist/assets/channel-Ca5LuXyQ.js +0 -1
  304. package/dist/assets/chat-components-CGlO4yUw.js +0 -1
  305. package/dist/assets/chat-panel-CrWYAGFe.js +0 -3
  306. package/dist/assets/chunk-55IACEB6-SrR0J56d.js +0 -1
  307. package/dist/assets/classDiagram-2ON5EDUG-Dw6g8LWZ.js +0 -1
  308. package/dist/assets/classDiagram-v2-WZHVMYZB-BOkOSYqg.js +0 -1
  309. package/dist/assets/clojure-CktH9n5q.js +0 -1
  310. package/dist/assets/cmake-BwTN0lwz.js +0 -1
  311. package/dist/assets/cobol-D0Y9QJHH.js +0 -1
  312. package/dist/assets/coffeescript-CL84ZPXU.js +0 -1
  313. package/dist/assets/column-preview-CxMrs0B_.js +0 -1
  314. package/dist/assets/command-palette-CK_YtcI5.js +0 -1
  315. package/dist/assets/commonlisp-CukhuKqj.js +0 -1
  316. package/dist/assets/config-CIrPQIbt.js +0 -1
  317. package/dist/assets/crystal-DjLRzuWS.js +0 -1
  318. package/dist/assets/cypher-DTLWn8Gw.js +0 -1
  319. package/dist/assets/d-DWjY1SxT.js +0 -1
  320. package/dist/assets/dependency-graph-panel-BxuHF8Tr.js +0 -4
  321. package/dist/assets/dialog-CxGKN4C_.js +0 -1
  322. package/dist/assets/diff-CBkFqCNH.js +0 -1
  323. package/dist/assets/dist-BhtRbLYO.js +0 -1
  324. package/dist/assets/dist-CyLRJKkZ.js +0 -1
  325. package/dist/assets/dist-DiFit-1W.js +0 -1
  326. package/dist/assets/dist-w6kOVH_r.js +0 -1
  327. package/dist/assets/documentation-panel-DLCX-Vvr.js +0 -1
  328. package/dist/assets/download-BhCZMKuQ.js +0 -9
  329. package/dist/assets/dtd-BuqGL9hz.js +0 -1
  330. package/dist/assets/dylan-WTW5QtBM.js +0 -1
  331. package/dist/assets/ecl-DBVSQs77.js +0 -1
  332. package/dist/assets/eiffel-C3Tl80Mr.js +0 -1
  333. package/dist/assets/elm-BzK6589w.js +0 -1
  334. package/dist/assets/erlang-DMCyf1S1.js +0 -1
  335. package/dist/assets/error-panel-CZ-XjEWh.js +0 -1
  336. package/dist/assets/factor-Y7W4xwTs.js +0 -1
  337. package/dist/assets/field-BEg1eC0P.js +0 -1
  338. package/dist/assets/file-explorer-panel-DUA58FLp.js +0 -1
  339. package/dist/assets/form-DUA_Rz_a.js +0 -2
  340. package/dist/assets/forth-a7Ame17q.js +0 -1
  341. package/dist/assets/fortran-D8W1t7ql.js +0 -1
  342. package/dist/assets/gas-CPCP4r6U.js +0 -1
  343. package/dist/assets/gherkin-dyINaGjD.js +0 -1
  344. package/dist/assets/groovy-yBYyWQAY.js +0 -1
  345. package/dist/assets/haskell-DOSr8Xuo.js +0 -1
  346. package/dist/assets/haxe-JqSUWIxe.js +0 -1
  347. package/dist/assets/home-page-B7vvwjUd.js +0 -4
  348. package/dist/assets/idl-D2Ag6F2o.js +0 -1
  349. package/dist/assets/index-DGasP9Lh.js +0 -38
  350. package/dist/assets/infoDiagram-WHAUD3N6-CEIds0YG.js +0 -2
  351. package/dist/assets/input-pAun1m1X.js +0 -1
  352. package/dist/assets/javascript-3AO8kHoR.js +0 -1
  353. package/dist/assets/julia-DB4UbzHR.js +0 -1
  354. package/dist/assets/katex-D_uHS_Lg.js +0 -1
  355. package/dist/assets/links-C-GGaW8R.js +0 -1
  356. package/dist/assets/livescript-DReeORQ9.js +0 -1
  357. package/dist/assets/logs-panel-1gpGfzHV.js +0 -1
  358. package/dist/assets/lua-ybhkw42a.js +0 -1
  359. package/dist/assets/mathematica-DknPFJHQ.js +0 -1
  360. package/dist/assets/mbox-CvGrdGLO.js +0 -1
  361. package/dist/assets/mermaid-4DMBBIKO-BRvRPAcU.js +0 -1
  362. package/dist/assets/mirc-BeRjyZ00.js +0 -1
  363. package/dist/assets/mllike-Dy0V9wt1.js +0 -1
  364. package/dist/assets/mode-DX8pdI-l.js +0 -1
  365. package/dist/assets/modelica--iMtH0NO.js +0 -1
  366. package/dist/assets/mscgen-CqR_OhJF.js +0 -1
  367. package/dist/assets/multi-map-C8GlnP-4.js +0 -1
  368. package/dist/assets/mumps-DXhR5sNO.js +0 -1
  369. package/dist/assets/nsis-FfqfUShs.js +0 -1
  370. package/dist/assets/ntriples-C3Y5YwlO.js +0 -1
  371. package/dist/assets/octave-Dn-U4f-O.js +0 -1
  372. package/dist/assets/outline-panel-e_rdB4-A.js +0 -1
  373. package/dist/assets/oz-Dx3Usekg.js +0 -1
  374. package/dist/assets/packages-panel-CWeSsfWc.js +0 -1
  375. package/dist/assets/panels-DdW0Mr43.js +0 -1
  376. package/dist/assets/pascal-Bhoas9O4.js +0 -1
  377. package/dist/assets/perl-uQVtdMdg.js +0 -1
  378. package/dist/assets/pig-DDagqkh7.js +0 -1
  379. package/dist/assets/powershell-WeyQqZtK.js +0 -1
  380. package/dist/assets/properties-MEyUmkzm.js +0 -1
  381. package/dist/assets/protobuf-DrUQLGvH.js +0 -1
  382. package/dist/assets/pug-YYu0lKKy.js +0 -1
  383. package/dist/assets/puppet-C9UhEtzi.js +0 -1
  384. package/dist/assets/python-BAh1L3Ue.js +0 -1
  385. package/dist/assets/q-CoA1I94V.js +0 -1
  386. package/dist/assets/r-CnPeMCLv.js +0 -1
  387. package/dist/assets/react-vega-D8yR_dNz.js +0 -1
  388. package/dist/assets/rpm-DOBsrwns.js +0 -1
  389. package/dist/assets/ruby-DphmqCS4.js +0 -1
  390. package/dist/assets/run-page-4ks5Ng3f.js +0 -1
  391. package/dist/assets/sas-DqX-D0mu.js +0 -1
  392. package/dist/assets/scheme-BDPqQOec.js +0 -1
  393. package/dist/assets/scratchpad-panel-BKlpCchw.js +0 -1
  394. package/dist/assets/select-V5IdpNiR.js +0 -1
  395. package/dist/assets/session-panel-Bsntt1Wf.js +0 -1
  396. package/dist/assets/shell-BbHQ-2DS.js +0 -1
  397. package/dist/assets/sieve-AQvCITfE.js +0 -1
  398. package/dist/assets/smalltalk-C_EFh1kg.js +0 -1
  399. package/dist/assets/snippets-panel-BgCAYJln.js +0 -1
  400. package/dist/assets/sparql-BlXg3dFR.js +0 -1
  401. package/dist/assets/stateDiagram-v2-4FDKWEC3-CfbYvNgS.js +0 -1
  402. package/dist/assets/stylus-Dvm1D-Up.js +0 -1
  403. package/dist/assets/swift-BYNffoE5.js +0 -1
  404. package/dist/assets/tcl-BXf8cJq0.js +0 -1
  405. package/dist/assets/textile-BYQcpBSz.js +0 -1
  406. package/dist/assets/toml-DRBRsKy_.js +0 -1
  407. package/dist/assets/tracing-DcLhmYc2.js +0 -1
  408. package/dist/assets/tracing-panel-CLF67O54.js +0 -2
  409. package/dist/assets/troff-DrvwLjLq.js +0 -1
  410. package/dist/assets/ttcn-DP5EbkJT.js +0 -1
  411. package/dist/assets/ttcn-cfg-BRAAKR13.js +0 -1
  412. package/dist/assets/turtle-Dfy5N6iI.js +0 -1
  413. package/dist/assets/useCellActionButton-DNI-LzxR.js +0 -1
  414. package/dist/assets/useNotebookActions-BkFpDvzl.js +0 -1
  415. package/dist/assets/vb-DzPnQ7Kn.js +0 -1
  416. package/dist/assets/vbscript-Dsr7xm0B.js +0 -1
  417. package/dist/assets/vega-component-Dd3MCYZO.js +0 -1
  418. package/dist/assets/velocity-BP08r0ZT.js +0 -1
  419. package/dist/assets/verilog-CtASbUB4.js +0 -1
  420. package/dist/assets/vhdl-BNXpaYPc.js +0 -1
  421. package/dist/assets/webidl-CHQTLbOi.js +0 -1
  422. package/dist/assets/xquery-BysgHIf7.js +0 -1
  423. package/dist/assets/yacas-jKltHvRl.js +0 -1
  424. package/dist/assets/z80-DVuK3CCU.js +0 -1
  425. /package/dist/assets/{Combination-CMPwuAmi.js → Combination-C_mRvd_Z.js} +0 -0
  426. /package/dist/assets/{ImageComparisonComponent-dmuxayWy.js → ImageComparisonComponent-BVBGmVcA.js} +0 -0
  427. /package/dist/assets/{Inputs-D2Xn4HON.js → Inputs-CBxLLWdV.js} +0 -0
  428. /package/dist/assets/{SSRProvider-CEHRCdjA.js → SSRProvider-DBS9qs3r.js} +0 -0
  429. /package/dist/assets/{alert-BrGyZf9c.js → alert-adkp2Qj8.js} +0 -0
  430. /package/dist/assets/{apl-DVWF09P_.js → apl-CpVTW0fY.js} +0 -0
  431. /package/dist/assets/{array-BF0shS9G.js → array-BKCdRGCR.js} +0 -0
  432. /package/dist/assets/{asciiarmor-l0ikukqg.js → asciiarmor-qDK46YPd.js} +0 -0
  433. /package/dist/assets/{asn1-CsdiW8T7.js → asn1-s2ZJql-T.js} +0 -0
  434. /package/dist/assets/{asterisk-DQege133.js → asterisk-Cy-53Fu-.js} +0 -0
  435. /package/dist/assets/{blob-CuXvdYPX.js → blob-t6qcPM7K.js} +0 -0
  436. /package/dist/assets/{brainfuck-C66TQVgP.js → brainfuck-5fD7ZBSv.js} +0 -0
  437. /package/dist/assets/{bundle.esm-2AjO7UK5.js → bundle.esm-B-jCcPJK.js} +0 -0
  438. /package/dist/assets/{chunk-76Q3JFCE-CC_RB1qp.js → chunk-76Q3JFCE-B261Xkae.js} +0 -0
  439. /package/dist/assets/{chunk-FWNWRKHM-D3c3qJTG.js → chunk-FWNWRKHM-C0b0DIG0.js} +0 -0
  440. /package/dist/assets/{chunk-LBM3YZW2-DNY-0NiJ.js → chunk-LBM3YZW2-D3uTpSOd.js} +0 -0
  441. /package/dist/assets/{chunk-LHMN2FUI-xvIevmTh.js → chunk-LHMN2FUI-2FK1AIwU.js} +0 -0
  442. /package/dist/assets/{chunk-O7ZBX7Z2-CsMGWxKA.js → chunk-O7ZBX7Z2-DoE29Zoe.js} +0 -0
  443. /package/dist/assets/{chunk-S6J4BHB3-B5AsdTT7.js → chunk-S6J4BHB3-Cvr0itXK.js} +0 -0
  444. /package/dist/assets/{chunk-T53DSG4Q-td6bRJ2x.js → chunk-T53DSG4Q-C7bPrBIt.js} +0 -0
  445. /package/dist/assets/{chunk-XAJISQIX-Bus-Z8i1.js → chunk-XAJISQIX-TwS9jXHm.js} +0 -0
  446. /package/dist/assets/{clear-button-BZQ4dSdG.js → clear-button-CF0iBcV9.js} +0 -0
  447. /package/dist/assets/{click-outside-container-BVQDdpbt.js → click-outside-container-B12FHFHm.js} +0 -0
  448. /package/dist/assets/{clike-Cc3gZvM_.js → clike-D58k-9vu.js} +0 -0
  449. /package/dist/assets/{clojure-kT8c8jnq.js → clojure-Dkfjc-Fr.js} +0 -0
  450. /package/dist/assets/{cmake-B3S-FpMv.js → cmake-ffkxaUPf.js} +0 -0
  451. /package/dist/assets/{cobol-BrIP6mPV.js → cobol-CKARYRbQ.js} +0 -0
  452. /package/dist/assets/{coffeescript-ByxLkrBT.js → coffeescript-Dz_r13Pd.js} +0 -0
  453. /package/dist/assets/{colors-C3_wIR8c.js → colors-CUF0x3zZ.js} +0 -0
  454. /package/dist/assets/{common-keywords-DHn1q5re.js → common-keywords-CU-S2Vqm.js} +0 -0
  455. /package/dist/assets/{commonlisp-BjIOT_KK.js → commonlisp-EavL1_-N.js} +0 -0
  456. /package/dist/assets/{copy-Bv2DBpIS.js → copy-DHrHayPa.js} +0 -0
  457. /package/dist/assets/{crystal-CQtLRTna.js → crystal-BQ8grXRY.js} +0 -0
  458. /package/dist/assets/{css-CU1K_XUx.js → css-Bmqfl4iE.js} +0 -0
  459. /package/dist/assets/{cypher-An7BGqKu.js → cypher-BKXIqXpT.js} +0 -0
  460. /package/dist/assets/{cytoscape.esm-DRpjbKu_.js → cytoscape.esm-BihqZ2_-.js} +0 -0
  461. /package/dist/assets/{d-fbf-n02o.js → d-DRfFJaS4.js} +0 -0
  462. /package/dist/assets/{defaultLocale-C92Rrpmf.js → defaultLocale-BLne0bXb.js} +0 -0
  463. /package/dist/assets/{defaultLocale-D_rSvXvJ.js → defaultLocale-JieDVWC_.js} +0 -0
  464. /package/dist/assets/{diff-DbzsqZEz.js → diff-BWk1g4qN.js} +0 -0
  465. /package/dist/assets/{dist-BtWo0SNF.js → dist-B1CD4nG7.js} +0 -0
  466. /package/dist/assets/{dist-C9XNJlLJ.js → dist-BZe-2kC9.js} +0 -0
  467. /package/dist/assets/{dist-kdxmhWbv.js → dist-BcotcL0h.js} +0 -0
  468. /package/dist/assets/{dist-fsvXrTzp.js → dist-Bpsss9Eu.js} +0 -0
  469. /package/dist/assets/{dist-BVyBw1BD.js → dist-BtUqLXS9.js} +0 -0
  470. /package/dist/assets/{dist-CS67iP1P.js → dist-Bx6F_B1m.js} +0 -0
  471. /package/dist/assets/{dist-DeazQ1Kh.js → dist-C0QU3Oay.js} +0 -0
  472. /package/dist/assets/{dist-DDGPBuw4.js → dist-CNknMFYG.js} +0 -0
  473. /package/dist/assets/{dist-OM63llNV.js → dist-DGPkGdD2.js} +0 -0
  474. /package/dist/assets/{dist-BmvOPdv_.js → dist-DLCy1STk.js} +0 -0
  475. /package/dist/assets/{dist-CzfJUeh-.js → dist-Dj9zNHXU.js} +0 -0
  476. /package/dist/assets/{dist-C4h-1T2Q.js → dist-DsxhNXOv.js} +0 -0
  477. /package/dist/assets/{dist-C04_12Dz.js → dist-DxxvVPQH.js} +0 -0
  478. /package/dist/assets/{dist-BZY_uvFb.js → dist-GCDTTvNx.js} +0 -0
  479. /package/dist/assets/{dist-CldbmzwA.js → dist-OZngTf6n.js} +0 -0
  480. /package/dist/assets/{dist-CdxIjAOP.js → dist-oarhZoo6.js} +0 -0
  481. /package/dist/assets/{dist-6cIjG-FS.js → dist-qIIHXwC_.js} +0 -0
  482. /package/dist/assets/{dist-D_XLVesh.js → dist-rT8uZk_k.js} +0 -0
  483. /package/dist/assets/{dtd-DnQAYfYi.js → dtd-C1gvGnbI.js} +0 -0
  484. /package/dist/assets/{duckdb-keywords-usZbJ-Dr.js → duckdb-keywords-CR9f4wu5.js} +0 -0
  485. /package/dist/assets/{dylan-DeXj1TAN.js → dylan-D26gjyBo.js} +0 -0
  486. /package/dist/assets/{ebnf-BAIwm2E9.js → ebnf-BdwTqLUx.js} +0 -0
  487. /package/dist/assets/{ecl-B8-j0xrP.js → ecl-D_pghsRW.js} +0 -0
  488. /package/dist/assets/{eiffel-DdiJ6Uyn.js → eiffel-CQeRT5l7.js} +0 -0
  489. /package/dist/assets/{elm-CAmK9rmL.js → elm-BMJejWwJ.js} +0 -0
  490. /package/dist/assets/{emotion-is-prop-valid.esm-DD4AwVTU.js → emotion-is-prop-valid.esm-C59xfSYt.js} +0 -0
  491. /package/dist/assets/{empty-state-h8C2C6hZ.js → empty-state-BAGXXrn8.js} +0 -0
  492. /package/dist/assets/{en-US-pRRbZZHE.js → en-US-XLBup7bs.js} +0 -0
  493. /package/dist/assets/{erlang-hqy6gURy.js → erlang-DTDt7sE1.js} +0 -0
  494. /package/dist/assets/{errors-2SszdW9t.js → errors-B5AI4nf5.js} +0 -0
  495. /package/dist/assets/{esm-BHwEmOw7.js → esm-DvGqZhsW.js} +0 -0
  496. /package/dist/assets/{extends-B2LJnKU3.js → extends-BiFDv3jB.js} +0 -0
  497. /package/dist/assets/{fcl-BRXWXeJY.js → fcl-BFWIADMy.js} +0 -0
  498. /package/dist/assets/{forth-CsaVBHm8.js → forth-DLug1Uos.js} +0 -0
  499. /package/dist/assets/{fortran-DGNsp41i.js → fortran-CfPd9x83.js} +0 -0
  500. /package/dist/assets/{gas-BX8xjNNw.js → gas-C1vwqe1-.js} +0 -0
  501. /package/dist/assets/{gherkin--u9ojH5d.js → gherkin-DxFhlJYL.js} +0 -0
  502. /package/dist/assets/{groovy-Drg0Cp0-.js → groovy-AqjvKzmp.js} +0 -0
  503. /package/dist/assets/{haskell-D96A8Bg_.js → haskell-B9BMJXS_.js} +0 -0
  504. /package/dist/assets/{haxe-B_4sGLdj.js → haxe-CFd4aFZH.js} +0 -0
  505. /package/dist/assets/{http-DxX5IMY1.js → http-CgzOAOXj.js} +0 -0
  506. /package/dist/assets/{icon-32x32-ClOCJ7rj.js → icon-32x32-XIbzzdoo.js} +0 -0
  507. /package/dist/assets/{icons-BhEXrzsb.js → icons-Dw4USSvE.js} +0 -0
  508. /package/dist/assets/{idl-CA47OCO3.js → idl-DKlFwAHI.js} +0 -0
  509. /package/dist/assets/{init-AtRnKt23.js → init-DZpk0tdu.js} +0 -0
  510. /package/dist/assets/{isValid-DcYggVWP.js → isValid-BLB2jskA.js} +0 -0
  511. /package/dist/assets/{javascript-i8I6A_gg.js → javascript-BMuus-3E.js} +0 -0
  512. /package/dist/assets/{julia-DYuDt1xN.js → julia-DGv2rboF.js} +0 -0
  513. /package/dist/assets/{katex-Dc8yG8NU.js → katex-DYp6oq7P.js} +0 -0
  514. /package/dist/assets/{kbd-C3JY7O_u.js → kbd-uRyPZ9w_.js} +0 -0
  515. /package/dist/assets/{links-DHZUhGz-.js → links-BhgWpHdU.js} +0 -0
  516. /package/dist/assets/{livescript-C72Fe_WX.js → livescript-51GCvdcX.js} +0 -0
  517. /package/dist/assets/{loro_wasm_bg-CDxXoyfI.js → loro_wasm_bg-BnAHSQ7o.js} +0 -0
  518. /package/dist/assets/{lua-CrUucAvm.js → lua-BwsAaftY.js} +0 -0
  519. /package/dist/assets/{math-BIeW4iGV.js → math-PgJy15ir.js} +0 -0
  520. /package/dist/assets/{mathematica-GLtAlQgr.js → mathematica-Du4amQ2X.js} +0 -0
  521. /package/dist/assets/{mbox-DsldZPOv.js → mbox-DKL-l6mb.js} +0 -0
  522. /package/dist/assets/{mirc-Dpq184o1.js → mirc-CvS1f8zr.js} +0 -0
  523. /package/dist/assets/{mllike-eEM7KiC0.js → mllike-VhUq11ot.js} +0 -0
  524. /package/dist/assets/{modelica-BKRVU7Ex.js → modelica-CjlHUZat.js} +0 -0
  525. /package/dist/assets/{mscgen-LPWHVNeM.js → mscgen-26STiUsc.js} +0 -0
  526. /package/dist/assets/{multi-icon-DZsiUPo5.js → multi-icon-CLzAg610.js} +0 -0
  527. /package/dist/assets/{mumps-46YgImgy.js → mumps-4o8IRFVU.js} +0 -0
  528. /package/dist/assets/{nginx-C7sPMZD3.js → nginx-CFpObAqg.js} +0 -0
  529. /package/dist/assets/{node-sql-parser-DYAIp20j.js → node-sql-parser-UQ9Ur_LP.js} +0 -0
  530. /package/dist/assets/{ntriples-CABx3n6p.js → ntriples-D0zMsGJ-.js} +0 -0
  531. /package/dist/assets/{numbers-iQunIAXf.js → numbers-UHLm3mA-.js} +0 -0
  532. /package/dist/assets/{objectWithoutPropertiesLoose-DaPAPabU.js → objectWithoutPropertiesLoose-DfWeGRFv.js} +0 -0
  533. /package/dist/assets/{octave-ChjrzDtA.js → octave-CpJ40RVG.js} +0 -0
  534. /package/dist/assets/{oz-BZ0G7oQI.js → oz-W9l5CbXg.js} +0 -0
  535. /package/dist/assets/{panel-context-B7WTvLhE.js → panel-context-C-UJlFyL.js} +0 -0
  536. /package/dist/assets/{pascal-BDWWzmkf.js → pascal-BZtdYBm4.js} +0 -0
  537. /package/dist/assets/{path-BMloFSsK.js → path-dqkZlAhR.js} +0 -0
  538. /package/dist/assets/{perl-C1twkBDg.js → perl-Q79ziUtd.js} +0 -0
  539. /package/dist/assets/{pig-CKZ-JUXx.js → pig-Dn9ueYxG.js} +0 -0
  540. /package/dist/assets/{powershell-BmnkAUC8.js → powershell-DfXPJ56g.js} +0 -0
  541. /package/dist/assets/{prop-types-BiQYf0aU.js → prop-types-DaaA-ptl.js} +0 -0
  542. /package/dist/assets/{properties-B3qF4Ofl.js → properties-DRrw--9g.js} +0 -0
  543. /package/dist/assets/{protobuf-CdWFIAi_.js → protobuf-5jBh6Y7Q.js} +0 -0
  544. /package/dist/assets/{puppet-oVG7sgNi.js → puppet-Bql5dDjm.js} +0 -0
  545. /package/dist/assets/{purify.es-DNVQZNFu.js → purify.es-DZrAQFIu.js} +0 -0
  546. /package/dist/assets/{python-GCb3koKb.js → python-C7HNB5A8.js} +0 -0
  547. /package/dist/assets/{q-CylRV6ad.js → q-CW9lnZXb.js} +0 -0
  548. /package/dist/assets/{r-BV8FQxo8.js → r-DmuxMz9j.js} +0 -0
  549. /package/dist/assets/{range-Bc7-zhbC.js → range-1DwpgXvM.js} +0 -0
  550. /package/dist/assets/{react-resizable-panels.browser.esm-Ctj_10o2.js → react-resizable-panels.browser.esm-BFvP7Upm.js} +0 -0
  551. /package/dist/assets/{request-registry-CB8fU98Q.js → request-registry-CjZcQuTP.js} +0 -0
  552. /package/dist/assets/{requests-BEWfBENt.js → requests-BSPGoGJL.js} +0 -0
  553. /package/dist/assets/{rpm-0QmIraaR.js → rpm-2BQZRXYJ.js} +0 -0
  554. /package/dist/assets/{ruby-h-bI2J_W.js → ruby-B-FyRKB2.js} +0 -0
  555. /package/dist/assets/{runs-bjsj1D88.js → runs-X54OGDTq.js} +0 -0
  556. /package/dist/assets/{sas-BvwZbLPG.js → sas-Q-94el51.js} +0 -0
  557. /package/dist/assets/{scheme-BPuaxh6y.js → scheme-By445Ne_.js} +0 -0
  558. /package/dist/assets/{share-CbPtIlnM.js → share-Ba-pHZtq.js} +0 -0
  559. /package/dist/assets/{shell-DmziZNbR.js → shell-CezKrT5T.js} +0 -0
  560. /package/dist/assets/{sieve-DT4D9aeW.js → sieve-MRWdUbX3.js} +0 -0
  561. /package/dist/assets/{simple-mode-BVXe8Gj5.js → simple-mode-BtxX-F6Z.js} +0 -0
  562. /package/dist/assets/{smalltalk-lAY6r45k.js → smalltalk-C0KZrhPl.js} +0 -0
  563. /package/dist/assets/{solr-B2csZ4mu.js → solr-BkyoAXqg.js} +0 -0
  564. /package/dist/assets/{sparql-nFvL3z3l.js → sparql-CIMoBhOL.js} +0 -0
  565. /package/dist/assets/{spreadsheet-C9drr7Wf.js → spreadsheet-7FZkhkVo.js} +0 -0
  566. /package/dist/assets/{sql-Ba7Mq1qs.js → sql-BNnXxKXA.js} +0 -0
  567. /package/dist/assets/{src-BKLwm2RN.js → src-CmKhyEBC.js} +0 -0
  568. /package/dist/assets/{state-D7LZMIOW.js → state-n1Xz9vt7.js} +0 -0
  569. /package/dist/assets/{stylus-BawZsgUJ.js → stylus-BxV1gbJN.js} +0 -0
  570. /package/dist/assets/{swift-CdaDqiGL.js → swift-C7ozIpB2.js} +0 -0
  571. /package/dist/assets/{table-C8uQmBAN.js → table-qbh6Daed.js} +0 -0
  572. /package/dist/assets/{tcl-D5FopUjH.js → tcl-D9BrnXdg.js} +0 -0
  573. /package/dist/assets/{textile-Cum4VLew.js → textile-8cDJUs1C.js} +0 -0
  574. /package/dist/assets/{tiddlywiki-CEYqr2EK.js → tiddlywiki-DE5lnTl3.js} +0 -0
  575. /package/dist/assets/{tiki-Drx00sPe.js → tiki-Dt9oCY2i.js} +0 -0
  576. /package/dist/assets/{timer-ffBO1paY.js → timer-DXL2Iyk5.js} +0 -0
  577. /package/dist/assets/{toml-5si8PWt8.js → toml-Dtc3-sql.js} +0 -0
  578. /package/dist/assets/{treemap-DqSsE4KM.js → treemap-8bMgVaTX.js} +0 -0
  579. /package/dist/assets/{troff-qCd7sECP.js → troff-CxUT34rC.js} +0 -0
  580. /package/dist/assets/{ttcn-BZC1oJG1.js → ttcn-BiVwbsr5.js} +0 -0
  581. /package/dist/assets/{ttcn-cfg-BlUyan1P.js → ttcn-cfg-BLBfLtVM.js} +0 -0
  582. /package/dist/assets/{turtle-BGa4pyfx.js → turtle-DqTQI7WU.js} +0 -0
  583. /package/dist/assets/{types-z6Sk3JCV.js → types-DZmRsGZN.js} +0 -0
  584. /package/dist/assets/{useAsyncData-C4XRy1BE.js → useAsyncData-BAVCkkQP.js} +0 -0
  585. /package/dist/assets/{useDebounce-D5NcotGm.js → useDebounce-CU_caGaU.js} +0 -0
  586. /package/dist/assets/{useDeepCompareMemoize-ZPd9PxYl.js → useDeepCompareMemoize-DiyglPgJ.js} +0 -0
  587. /package/dist/assets/{useIframeCapabilities-DuIDx9mD.js → useIframeCapabilities-DzIlROXe.js} +0 -0
  588. /package/dist/assets/{useInterval-Cu9ChZf-.js → useInterval-y9MtYlSD.js} +0 -0
  589. /package/dist/assets/{useTheme-DUdVAZI8.js → useTheme-EGf2UOFo.js} +0 -0
  590. /package/dist/assets/{vb-G28CZ46r.js → vb-D-mN5USJ.js} +0 -0
  591. /package/dist/assets/{vbscript-DOr4ZYtx.js → vbscript-BHlqX42l.js} +0 -0
  592. /package/dist/assets/{velocity-DRewaasJ.js → velocity-BX6395is.js} +0 -0
  593. /package/dist/assets/{verilog-DmcGbw8B.js → verilog-CixbCKyb.js} +0 -0
  594. /package/dist/assets/{vhdl-C6ktucee.js → vhdl-CofOR-02.js} +0 -0
  595. /package/dist/assets/{web-vitals-D9j8DwGO.js → web-vitals-Br9feh_D.js} +0 -0
  596. /package/dist/assets/{webidl-DHu7cr9_.js → webidl-DAqkXtNt.js} +0 -0
  597. /package/dist/assets/{ws-BApgRfsy.js → ws-DQY2KwIl.js} +0 -0
  598. /package/dist/assets/{xquery-BuvyHzVJ.js → xquery-wPbfv0-o.js} +0 -0
  599. /package/dist/assets/{yacas-C_HpkPlV.js → yacas-B5Zk1avC.js} +0 -0
  600. /package/dist/assets/{z80-BDlRltlF.js → z80-C0HuDTqd.js} +0 -0
@@ -1 +1 @@
1
- import{s as nt,t as V}from"./chunk-LvLJmgfZ.js";import{u as st}from"./src-Cf4NnJCp.js";import{n as k,r as j}from"./src-BKLwm2RN.js";import{t as z}from"./cytoscape.esm-DRpjbKu_.js";var Z=V(((C,P)=>{(function(m,L){typeof C=="object"&&typeof P=="object"?P.exports=L():typeof define=="function"&&define.amd?define([],L):typeof C=="object"?C.layoutBase=L():m.layoutBase=L()})(C,function(){return(function(m){var L={};function A(n){if(L[n])return L[n].exports;var i=L[n]={i:n,l:!1,exports:{}};return m[n].call(i.exports,i,i.exports,A),i.l=!0,i.exports}return A.m=m,A.c=L,A.i=function(n){return n},A.d=function(n,i,t){A.o(n,i)||Object.defineProperty(n,i,{configurable:!1,enumerable:!0,get:t})},A.n=function(n){var i=n&&n.__esModule?function(){return n.default}:function(){return n};return A.d(i,"a",i),i},A.o=function(n,i){return Object.prototype.hasOwnProperty.call(n,i)},A.p="",A(A.s=26)})([(function(m,L,A){function n(){}n.QUALITY=1,n.DEFAULT_CREATE_BENDS_AS_NEEDED=!1,n.DEFAULT_INCREMENTAL=!1,n.DEFAULT_ANIMATION_ON_LAYOUT=!0,n.DEFAULT_ANIMATION_DURING_LAYOUT=!1,n.DEFAULT_ANIMATION_PERIOD=50,n.DEFAULT_UNIFORM_LEAF_NODE_SIZES=!1,n.DEFAULT_GRAPH_MARGIN=15,n.NODE_DIMENSIONS_INCLUDE_LABELS=!1,n.SIMPLE_NODE_SIZE=40,n.SIMPLE_NODE_HALF_SIZE=n.SIMPLE_NODE_SIZE/2,n.EMPTY_COMPOUND_NODE_SIZE=40,n.MIN_EDGE_LENGTH=1,n.WORLD_BOUNDARY=1e6,n.INITIAL_WORLD_BOUNDARY=n.WORLD_BOUNDARY/1e3,n.WORLD_CENTER_X=1200,n.WORLD_CENTER_Y=900,m.exports=n}),(function(m,L,A){var n=A(2),i=A(8),t=A(9);function e(h,o,N){n.call(this,N),this.isOverlapingSourceAndTarget=!1,this.vGraphObject=N,this.bendpoints=[],this.source=h,this.target=o}for(var r in e.prototype=Object.create(n.prototype),n)e[r]=n[r];e.prototype.getSource=function(){return this.source},e.prototype.getTarget=function(){return this.target},e.prototype.isInterGraph=function(){return this.isInterGraph},e.prototype.getLength=function(){return this.length},e.prototype.isOverlapingSourceAndTarget=function(){return this.isOverlapingSourceAndTarget},e.prototype.getBendpoints=function(){return this.bendpoints},e.prototype.getLca=function(){return this.lca},e.prototype.getSourceInLca=function(){return this.sourceInLca},e.prototype.getTargetInLca=function(){return this.targetInLca},e.prototype.getOtherEnd=function(h){if(this.source===h)return this.target;if(this.target===h)return this.source;throw"Node is not incident with this edge"},e.prototype.getOtherEndInGraph=function(h,o){for(var N=this.getOtherEnd(h),s=o.getGraphManager().getRoot();;){if(N.getOwner()==o)return N;if(N.getOwner()==s)break;N=N.getOwner().getParent()}return null},e.prototype.updateLength=function(){var h=[,,,,];this.isOverlapingSourceAndTarget=i.getIntersection(this.target.getRect(),this.source.getRect(),h),this.isOverlapingSourceAndTarget||(this.lengthX=h[0]-h[2],this.lengthY=h[1]-h[3],Math.abs(this.lengthX)<1&&(this.lengthX=t.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=t.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY))},e.prototype.updateLengthSimple=function(){this.lengthX=this.target.getCenterX()-this.source.getCenterX(),this.lengthY=this.target.getCenterY()-this.source.getCenterY(),Math.abs(this.lengthX)<1&&(this.lengthX=t.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=t.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)},m.exports=e}),(function(m,L,A){function n(i){this.vGraphObject=i}m.exports=n}),(function(m,L,A){var n=A(2),i=A(10),t=A(13),e=A(0),r=A(16),h=A(4);function o(s,g,u,p){u==null&&p==null&&(p=g),n.call(this,p),s.graphManager!=null&&(s=s.graphManager),this.estimatedSize=i.MIN_VALUE,this.inclusionTreeDepth=i.MAX_VALUE,this.vGraphObject=p,this.edges=[],this.graphManager=s,u!=null&&g!=null?this.rect=new t(g.x,g.y,u.width,u.height):this.rect=new t}for(var N in o.prototype=Object.create(n.prototype),n)o[N]=n[N];o.prototype.getEdges=function(){return this.edges},o.prototype.getChild=function(){return this.child},o.prototype.getOwner=function(){return this.owner},o.prototype.getWidth=function(){return this.rect.width},o.prototype.setWidth=function(s){this.rect.width=s},o.prototype.getHeight=function(){return this.rect.height},o.prototype.setHeight=function(s){this.rect.height=s},o.prototype.getCenterX=function(){return this.rect.x+this.rect.width/2},o.prototype.getCenterY=function(){return this.rect.y+this.rect.height/2},o.prototype.getCenter=function(){return new h(this.rect.x+this.rect.width/2,this.rect.y+this.rect.height/2)},o.prototype.getLocation=function(){return new h(this.rect.x,this.rect.y)},o.prototype.getRect=function(){return this.rect},o.prototype.getDiagonal=function(){return Math.sqrt(this.rect.width*this.rect.width+this.rect.height*this.rect.height)},o.prototype.getHalfTheDiagonal=function(){return Math.sqrt(this.rect.height*this.rect.height+this.rect.width*this.rect.width)/2},o.prototype.setRect=function(s,g){this.rect.x=s.x,this.rect.y=s.y,this.rect.width=g.width,this.rect.height=g.height},o.prototype.setCenter=function(s,g){this.rect.x=s-this.rect.width/2,this.rect.y=g-this.rect.height/2},o.prototype.setLocation=function(s,g){this.rect.x=s,this.rect.y=g},o.prototype.moveBy=function(s,g){this.rect.x+=s,this.rect.y+=g},o.prototype.getEdgeListToNode=function(s){var g=[],u=this;return u.edges.forEach(function(p){if(p.target==s){if(p.source!=u)throw"Incorrect edge source!";g.push(p)}}),g},o.prototype.getEdgesBetween=function(s){var g=[],u=this;return u.edges.forEach(function(p){if(!(p.source==u||p.target==u))throw"Incorrect edge source and/or target";(p.target==s||p.source==s)&&g.push(p)}),g},o.prototype.getNeighborsList=function(){var s=new Set,g=this;return g.edges.forEach(function(u){if(u.source==g)s.add(u.target);else{if(u.target!=g)throw"Incorrect incidency!";s.add(u.source)}}),s},o.prototype.withChildren=function(){var s=new Set,g,u;if(s.add(this),this.child!=null)for(var p=this.child.getNodes(),y=0;y<p.length;y++)g=p[y],u=g.withChildren(),u.forEach(function(c){s.add(c)});return s},o.prototype.getNoOfChildren=function(){var s=0,g;if(this.child==null)s=1;else for(var u=this.child.getNodes(),p=0;p<u.length;p++)g=u[p],s+=g.getNoOfChildren();return s==0&&(s=1),s},o.prototype.getEstimatedSize=function(){if(this.estimatedSize==i.MIN_VALUE)throw"assert failed";return this.estimatedSize},o.prototype.calcEstimatedSize=function(){return this.child==null?this.estimatedSize=(this.rect.width+this.rect.height)/2:(this.estimatedSize=this.child.calcEstimatedSize(),this.rect.width=this.estimatedSize,this.rect.height=this.estimatedSize,this.estimatedSize)},o.prototype.scatter=function(){var s,g,u=-e.INITIAL_WORLD_BOUNDARY,p=e.INITIAL_WORLD_BOUNDARY;s=e.WORLD_CENTER_X+r.nextDouble()*(p-u)+u;var y=-e.INITIAL_WORLD_BOUNDARY,c=e.INITIAL_WORLD_BOUNDARY;g=e.WORLD_CENTER_Y+r.nextDouble()*(c-y)+y,this.rect.x=s,this.rect.y=g},o.prototype.updateBounds=function(){if(this.getChild()==null)throw"assert failed";if(this.getChild().getNodes().length!=0){var s=this.getChild();if(s.updateBounds(!0),this.rect.x=s.getLeft(),this.rect.y=s.getTop(),this.setWidth(s.getRight()-s.getLeft()),this.setHeight(s.getBottom()-s.getTop()),e.NODE_DIMENSIONS_INCLUDE_LABELS){var g=s.getRight()-s.getLeft(),u=s.getBottom()-s.getTop();this.labelWidth>g&&(this.rect.x-=(this.labelWidth-g)/2,this.setWidth(this.labelWidth)),this.labelHeight>u&&(this.labelPos=="center"?this.rect.y-=(this.labelHeight-u)/2:this.labelPos=="top"&&(this.rect.y-=this.labelHeight-u),this.setHeight(this.labelHeight))}}},o.prototype.getInclusionTreeDepth=function(){if(this.inclusionTreeDepth==i.MAX_VALUE)throw"assert failed";return this.inclusionTreeDepth},o.prototype.transform=function(s){var g=this.rect.x;g>e.WORLD_BOUNDARY?g=e.WORLD_BOUNDARY:g<-e.WORLD_BOUNDARY&&(g=-e.WORLD_BOUNDARY);var u=this.rect.y;u>e.WORLD_BOUNDARY?u=e.WORLD_BOUNDARY:u<-e.WORLD_BOUNDARY&&(u=-e.WORLD_BOUNDARY);var p=new h(g,u),y=s.inverseTransformPoint(p);this.setLocation(y.x,y.y)},o.prototype.getLeft=function(){return this.rect.x},o.prototype.getRight=function(){return this.rect.x+this.rect.width},o.prototype.getTop=function(){return this.rect.y},o.prototype.getBottom=function(){return this.rect.y+this.rect.height},o.prototype.getParent=function(){return this.owner==null?null:this.owner.getParent()},m.exports=o}),(function(m,L,A){function n(i,t){i==null&&t==null?(this.x=0,this.y=0):(this.x=i,this.y=t)}n.prototype.getX=function(){return this.x},n.prototype.getY=function(){return this.y},n.prototype.setX=function(i){this.x=i},n.prototype.setY=function(i){this.y=i},n.prototype.getDifference=function(i){return new DimensionD(this.x-i.x,this.y-i.y)},n.prototype.getCopy=function(){return new n(this.x,this.y)},n.prototype.translate=function(i){return this.x+=i.width,this.y+=i.height,this},m.exports=n}),(function(m,L,A){var n=A(2),i=A(10),t=A(0),e=A(6),r=A(3),h=A(1),o=A(13),N=A(12),s=A(11);function g(p,y,c){n.call(this,c),this.estimatedSize=i.MIN_VALUE,this.margin=t.DEFAULT_GRAPH_MARGIN,this.edges=[],this.nodes=[],this.isConnected=!1,this.parent=p,y!=null&&y instanceof e?this.graphManager=y:y!=null&&y instanceof Layout&&(this.graphManager=y.graphManager)}for(var u in g.prototype=Object.create(n.prototype),n)g[u]=n[u];g.prototype.getNodes=function(){return this.nodes},g.prototype.getEdges=function(){return this.edges},g.prototype.getGraphManager=function(){return this.graphManager},g.prototype.getParent=function(){return this.parent},g.prototype.getLeft=function(){return this.left},g.prototype.getRight=function(){return this.right},g.prototype.getTop=function(){return this.top},g.prototype.getBottom=function(){return this.bottom},g.prototype.isConnected=function(){return this.isConnected},g.prototype.add=function(p,y,c){if(y==null&&c==null){var f=p;if(this.graphManager==null)throw"Graph has no graph mgr!";if(this.getNodes().indexOf(f)>-1)throw"Node already in graph!";return f.owner=this,this.getNodes().push(f),f}else{var T=p;if(!(this.getNodes().indexOf(y)>-1&&this.getNodes().indexOf(c)>-1))throw"Source or target not in graph!";if(!(y.owner==c.owner&&y.owner==this))throw"Both owners must be this graph!";return y.owner==c.owner?(T.source=y,T.target=c,T.isInterGraph=!1,this.getEdges().push(T),y.edges.push(T),c!=y&&c.edges.push(T),T):null}},g.prototype.remove=function(p){var y=p;if(p instanceof r){if(y==null)throw"Node is null!";if(!(y.owner!=null&&y.owner==this))throw"Owner graph is invalid!";if(this.graphManager==null)throw"Owner graph manager is invalid!";for(var c=y.edges.slice(),f,T=c.length,E=0;E<T;E++)f=c[E],f.isInterGraph?this.graphManager.remove(f):f.source.owner.remove(f);var O=this.nodes.indexOf(y);if(O==-1)throw"Node not in owner node list!";this.nodes.splice(O,1)}else if(p instanceof h){var f=p;if(f==null)throw"Edge is null!";if(!(f.source!=null&&f.target!=null))throw"Source and/or target is null!";if(!(f.source.owner!=null&&f.target.owner!=null&&f.source.owner==this&&f.target.owner==this))throw"Source and/or target owner is invalid!";var a=f.source.edges.indexOf(f),d=f.target.edges.indexOf(f);if(!(a>-1&&d>-1))throw"Source and/or target doesn't know this edge!";f.source.edges.splice(a,1),f.target!=f.source&&f.target.edges.splice(d,1);var O=f.source.owner.getEdges().indexOf(f);if(O==-1)throw"Not in owner's edge list!";f.source.owner.getEdges().splice(O,1)}},g.prototype.updateLeftTop=function(){for(var p=i.MAX_VALUE,y=i.MAX_VALUE,c,f,T,E=this.getNodes(),O=E.length,a=0;a<O;a++){var d=E[a];c=d.getTop(),f=d.getLeft(),p>c&&(p=c),y>f&&(y=f)}return p==i.MAX_VALUE?null:(T=E[0].getParent().paddingLeft==null?this.margin:E[0].getParent().paddingLeft,this.left=y-T,this.top=p-T,new N(this.left,this.top))},g.prototype.updateBounds=function(p){for(var y=i.MAX_VALUE,c=-i.MAX_VALUE,f=i.MAX_VALUE,T=-i.MAX_VALUE,E,O,a,d,l,v=this.nodes,_=v.length,D=0;D<_;D++){var I=v[D];p&&I.child!=null&&I.updateBounds(),E=I.getLeft(),O=I.getRight(),a=I.getTop(),d=I.getBottom(),y>E&&(y=E),c<O&&(c=O),f>a&&(f=a),T<d&&(T=d)}var w=new o(y,f,c-y,T-f);y==i.MAX_VALUE&&(this.left=this.parent.getLeft(),this.right=this.parent.getRight(),this.top=this.parent.getTop(),this.bottom=this.parent.getBottom()),l=v[0].getParent().paddingLeft==null?this.margin:v[0].getParent().paddingLeft,this.left=w.x-l,this.right=w.x+w.width+l,this.top=w.y-l,this.bottom=w.y+w.height+l},g.calculateBounds=function(p){for(var y=i.MAX_VALUE,c=-i.MAX_VALUE,f=i.MAX_VALUE,T=-i.MAX_VALUE,E,O,a,d,l=p.length,v=0;v<l;v++){var _=p[v];E=_.getLeft(),O=_.getRight(),a=_.getTop(),d=_.getBottom(),y>E&&(y=E),c<O&&(c=O),f>a&&(f=a),T<d&&(T=d)}return new o(y,f,c-y,T-f)},g.prototype.getInclusionTreeDepth=function(){return this==this.graphManager.getRoot()?1:this.parent.getInclusionTreeDepth()},g.prototype.getEstimatedSize=function(){if(this.estimatedSize==i.MIN_VALUE)throw"assert failed";return this.estimatedSize},g.prototype.calcEstimatedSize=function(){for(var p=0,y=this.nodes,c=y.length,f=0;f<c;f++){var T=y[f];p+=T.calcEstimatedSize()}return p==0?this.estimatedSize=t.EMPTY_COMPOUND_NODE_SIZE:this.estimatedSize=p/Math.sqrt(this.nodes.length),this.estimatedSize},g.prototype.updateConnected=function(){var p=this;if(this.nodes.length==0){this.isConnected=!0;return}var y=new s,c=new Set,f=this.nodes[0],T,E;for(f.withChildren().forEach(function(l){y.push(l),c.add(l)});y.length!==0;){f=y.shift(),T=f.getEdges();for(var O=T.length,a=0;a<O;a++)E=T[a].getOtherEndInGraph(f,this),E!=null&&!c.has(E)&&E.withChildren().forEach(function(l){y.push(l),c.add(l)})}if(this.isConnected=!1,c.size>=this.nodes.length){var d=0;c.forEach(function(l){l.owner==p&&d++}),d==this.nodes.length&&(this.isConnected=!0)}},m.exports=g}),(function(m,L,A){var n,i=A(1);function t(e){n=A(5),this.layout=e,this.graphs=[],this.edges=[]}t.prototype.addRoot=function(){var e=this.layout.newGraph(),r=this.layout.newNode(null),h=this.add(e,r);return this.setRootGraph(h),this.rootGraph},t.prototype.add=function(e,r,h,o,N){if(h==null&&o==null&&N==null){if(e==null)throw"Graph is null!";if(r==null)throw"Parent node is null!";if(this.graphs.indexOf(e)>-1)throw"Graph already in this graph mgr!";if(this.graphs.push(e),e.parent!=null)throw"Already has a parent!";if(r.child!=null)throw"Already has a child!";return e.parent=r,r.child=e,e}else{N=h,o=r,h=e;var s=o.getOwner(),g=N.getOwner();if(!(s!=null&&s.getGraphManager()==this))throw"Source not in this graph mgr!";if(!(g!=null&&g.getGraphManager()==this))throw"Target not in this graph mgr!";if(s==g)return h.isInterGraph=!1,s.add(h,o,N);if(h.isInterGraph=!0,h.source=o,h.target=N,this.edges.indexOf(h)>-1)throw"Edge already in inter-graph edge list!";if(this.edges.push(h),!(h.source!=null&&h.target!=null))throw"Edge source and/or target is null!";if(!(h.source.edges.indexOf(h)==-1&&h.target.edges.indexOf(h)==-1))throw"Edge already in source and/or target incidency list!";return h.source.edges.push(h),h.target.edges.push(h),h}},t.prototype.remove=function(e){if(e instanceof n){var r=e;if(r.getGraphManager()!=this)throw"Graph not in this graph mgr";if(!(r==this.rootGraph||r.parent!=null&&r.parent.graphManager==this))throw"Invalid parent node!";var h=[];h=h.concat(r.getEdges());for(var o,N=h.length,s=0;s<N;s++)o=h[s],r.remove(o);var g=[];g=g.concat(r.getNodes());var u;N=g.length;for(var s=0;s<N;s++)u=g[s],r.remove(u);r==this.rootGraph&&this.setRootGraph(null);var p=this.graphs.indexOf(r);this.graphs.splice(p,1),r.parent=null}else if(e instanceof i){if(o=e,o==null)throw"Edge is null!";if(!o.isInterGraph)throw"Not an inter-graph edge!";if(!(o.source!=null&&o.target!=null))throw"Source and/or target is null!";if(!(o.source.edges.indexOf(o)!=-1&&o.target.edges.indexOf(o)!=-1))throw"Source and/or target doesn't know this edge!";var p=o.source.edges.indexOf(o);if(o.source.edges.splice(p,1),p=o.target.edges.indexOf(o),o.target.edges.splice(p,1),!(o.source.owner!=null&&o.source.owner.getGraphManager()!=null))throw"Edge owner graph or owner graph manager is null!";if(o.source.owner.getGraphManager().edges.indexOf(o)==-1)throw"Not in owner graph manager's edge list!";var p=o.source.owner.getGraphManager().edges.indexOf(o);o.source.owner.getGraphManager().edges.splice(p,1)}},t.prototype.updateBounds=function(){this.rootGraph.updateBounds(!0)},t.prototype.getGraphs=function(){return this.graphs},t.prototype.getAllNodes=function(){if(this.allNodes==null){for(var e=[],r=this.getGraphs(),h=r.length,o=0;o<h;o++)e=e.concat(r[o].getNodes());this.allNodes=e}return this.allNodes},t.prototype.resetAllNodes=function(){this.allNodes=null},t.prototype.resetAllEdges=function(){this.allEdges=null},t.prototype.resetAllNodesToApplyGravitation=function(){this.allNodesToApplyGravitation=null},t.prototype.getAllEdges=function(){if(this.allEdges==null){var e=[],r=this.getGraphs();r.length;for(var h=0;h<r.length;h++)e=e.concat(r[h].getEdges());e=e.concat(this.edges),this.allEdges=e}return this.allEdges},t.prototype.getAllNodesToApplyGravitation=function(){return this.allNodesToApplyGravitation},t.prototype.setAllNodesToApplyGravitation=function(e){if(this.allNodesToApplyGravitation!=null)throw"assert failed";this.allNodesToApplyGravitation=e},t.prototype.getRoot=function(){return this.rootGraph},t.prototype.setRootGraph=function(e){if(e.getGraphManager()!=this)throw"Root not in this graph mgr!";this.rootGraph=e,e.parent??(e.parent=this.layout.newNode("Root node"))},t.prototype.getLayout=function(){return this.layout},t.prototype.isOneAncestorOfOther=function(e,r){if(!(e!=null&&r!=null))throw"assert failed";if(e==r)return!0;var h=e.getOwner(),o;do{if(o=h.getParent(),o==null)break;if(o==r)return!0;if(h=o.getOwner(),h==null)break}while(!0);h=r.getOwner();do{if(o=h.getParent(),o==null)break;if(o==e)return!0;if(h=o.getOwner(),h==null)break}while(!0);return!1},t.prototype.calcLowestCommonAncestors=function(){for(var e,r,h,o,N,s=this.getAllEdges(),g=s.length,u=0;u<g;u++){if(e=s[u],r=e.source,h=e.target,e.lca=null,e.sourceInLca=r,e.targetInLca=h,r==h){e.lca=r.getOwner();continue}for(o=r.getOwner();e.lca==null;){for(e.targetInLca=h,N=h.getOwner();e.lca==null;){if(N==o){e.lca=N;break}if(N==this.rootGraph)break;if(e.lca!=null)throw"assert failed";e.targetInLca=N.getParent(),N=e.targetInLca.getOwner()}if(o==this.rootGraph)break;e.lca??(e.sourceInLca=o.getParent(),o=e.sourceInLca.getOwner())}if(e.lca==null)throw"assert failed"}},t.prototype.calcLowestCommonAncestor=function(e,r){if(e==r)return e.getOwner();var h=e.getOwner();do{if(h==null)break;var o=r.getOwner();do{if(o==null)break;if(o==h)return o;o=o.getParent().getOwner()}while(!0);h=h.getParent().getOwner()}while(!0);return h},t.prototype.calcInclusionTreeDepths=function(e,r){e==null&&r==null&&(e=this.rootGraph,r=1);for(var h,o=e.getNodes(),N=o.length,s=0;s<N;s++)h=o[s],h.inclusionTreeDepth=r,h.child!=null&&this.calcInclusionTreeDepths(h.child,r+1)},t.prototype.includesInvalidEdge=function(){for(var e,r=this.edges.length,h=0;h<r;h++)if(e=this.edges[h],this.isOneAncestorOfOther(e.source,e.target))return!0;return!1},m.exports=t}),(function(m,L,A){var n=A(0);function i(){}for(var t in n)i[t]=n[t];i.MAX_ITERATIONS=2500,i.DEFAULT_EDGE_LENGTH=50,i.DEFAULT_SPRING_STRENGTH=.45,i.DEFAULT_REPULSION_STRENGTH=4500,i.DEFAULT_GRAVITY_STRENGTH=.4,i.DEFAULT_COMPOUND_GRAVITY_STRENGTH=1,i.DEFAULT_GRAVITY_RANGE_FACTOR=3.8,i.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=1.5,i.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION=!0,i.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION=!0,i.DEFAULT_COOLING_FACTOR_INCREMENTAL=.3,i.COOLING_ADAPTATION_FACTOR=.33,i.ADAPTATION_LOWER_NODE_LIMIT=1e3,i.ADAPTATION_UPPER_NODE_LIMIT=5e3,i.MAX_NODE_DISPLACEMENT_INCREMENTAL=100,i.MAX_NODE_DISPLACEMENT=i.MAX_NODE_DISPLACEMENT_INCREMENTAL*3,i.MIN_REPULSION_DIST=i.DEFAULT_EDGE_LENGTH/10,i.CONVERGENCE_CHECK_PERIOD=100,i.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=.1,i.MIN_EDGE_LENGTH=1,i.GRID_CALCULATION_CHECK_PERIOD=10,m.exports=i}),(function(m,L,A){var n=A(12);function i(){}i.calcSeparationAmount=function(t,e,r,h){if(!t.intersects(e))throw"assert failed";var o=[,,];this.decideDirectionsForOverlappingNodes(t,e,o),r[0]=Math.min(t.getRight(),e.getRight())-Math.max(t.x,e.x),r[1]=Math.min(t.getBottom(),e.getBottom())-Math.max(t.y,e.y),t.getX()<=e.getX()&&t.getRight()>=e.getRight()?r[0]+=Math.min(e.getX()-t.getX(),t.getRight()-e.getRight()):e.getX()<=t.getX()&&e.getRight()>=t.getRight()&&(r[0]+=Math.min(t.getX()-e.getX(),e.getRight()-t.getRight())),t.getY()<=e.getY()&&t.getBottom()>=e.getBottom()?r[1]+=Math.min(e.getY()-t.getY(),t.getBottom()-e.getBottom()):e.getY()<=t.getY()&&e.getBottom()>=t.getBottom()&&(r[1]+=Math.min(t.getY()-e.getY(),e.getBottom()-t.getBottom()));var N=Math.abs((e.getCenterY()-t.getCenterY())/(e.getCenterX()-t.getCenterX()));e.getCenterY()===t.getCenterY()&&e.getCenterX()===t.getCenterX()&&(N=1);var s=N*r[0],g=r[1]/N;r[0]<g?g=r[0]:s=r[1],r[0]=-1*o[0]*(g/2+h),r[1]=-1*o[1]*(s/2+h)},i.decideDirectionsForOverlappingNodes=function(t,e,r){t.getCenterX()<e.getCenterX()?r[0]=-1:r[0]=1,t.getCenterY()<e.getCenterY()?r[1]=-1:r[1]=1},i.getIntersection2=function(t,e,r){var h=t.getCenterX(),o=t.getCenterY(),N=e.getCenterX(),s=e.getCenterY();if(t.intersects(e))return r[0]=h,r[1]=o,r[2]=N,r[3]=s,!0;var g=t.getX(),u=t.getY(),p=t.getRight(),y=t.getX(),c=t.getBottom(),f=t.getRight(),T=t.getWidthHalf(),E=t.getHeightHalf(),O=e.getX(),a=e.getY(),d=e.getRight(),l=e.getX(),v=e.getBottom(),_=e.getRight(),D=e.getWidthHalf(),I=e.getHeightHalf(),w=!1,R=!1;if(h===N){if(o>s)return r[0]=h,r[1]=u,r[2]=N,r[3]=v,!1;if(o<s)return r[0]=h,r[1]=c,r[2]=N,r[3]=a,!1}else if(o===s){if(h>N)return r[0]=g,r[1]=o,r[2]=d,r[3]=s,!1;if(h<N)return r[0]=p,r[1]=o,r[2]=O,r[3]=s,!1}else{var G=t.height/t.width,x=e.height/e.width,M=(s-o)/(N-h),U=void 0,b=void 0,F=void 0,S=void 0,Y=void 0,X=void 0;if(-G===M?h>N?(r[0]=y,r[1]=c,w=!0):(r[0]=p,r[1]=u,w=!0):G===M&&(h>N?(r[0]=g,r[1]=u,w=!0):(r[0]=f,r[1]=c,w=!0)),-x===M?N>h?(r[2]=l,r[3]=v,R=!0):(r[2]=d,r[3]=a,R=!0):x===M&&(N>h?(r[2]=O,r[3]=a,R=!0):(r[2]=_,r[3]=v,R=!0)),w&&R)return!1;if(h>N?o>s?(U=this.getCardinalDirection(G,M,4),b=this.getCardinalDirection(x,M,2)):(U=this.getCardinalDirection(-G,M,3),b=this.getCardinalDirection(-x,M,1)):o>s?(U=this.getCardinalDirection(-G,M,1),b=this.getCardinalDirection(-x,M,3)):(U=this.getCardinalDirection(G,M,2),b=this.getCardinalDirection(x,M,4)),!w)switch(U){case 1:S=u,F=h+-E/M,r[0]=F,r[1]=S;break;case 2:F=f,S=o+T*M,r[0]=F,r[1]=S;break;case 3:S=c,F=h+E/M,r[0]=F,r[1]=S;break;case 4:F=y,S=o+-T*M,r[0]=F,r[1]=S;break}if(!R)switch(b){case 1:X=a,Y=N+-I/M,r[2]=Y,r[3]=X;break;case 2:Y=_,X=s+D*M,r[2]=Y,r[3]=X;break;case 3:X=v,Y=N+I/M,r[2]=Y,r[3]=X;break;case 4:Y=l,X=s+-D*M,r[2]=Y,r[3]=X;break}}return!1},i.getCardinalDirection=function(t,e,r){return t>e?r:1+r%4},i.getIntersection=function(t,e,r,h){if(h==null)return this.getIntersection2(t,e,r);var o=t.x,N=t.y,s=e.x,g=e.y,u=r.x,p=r.y,y=h.x,c=h.y,f=void 0,T=void 0,E=void 0,O=void 0,a=void 0,d=void 0,l=void 0,v=void 0,_=void 0;return E=g-N,a=o-s,l=s*N-o*g,O=c-p,d=u-y,v=y*p-u*c,_=E*d-O*a,_===0?null:(f=(a*v-d*l)/_,T=(O*l-E*v)/_,new n(f,T))},i.angleOfVector=function(t,e,r,h){var o=void 0;return t===r?o=h<e?this.ONE_AND_HALF_PI:this.HALF_PI:(o=Math.atan((h-e)/(r-t)),r<t?o+=Math.PI:h<e&&(o+=this.TWO_PI)),o},i.doIntersect=function(t,e,r,h){var o=t.x,N=t.y,s=e.x,g=e.y,u=r.x,p=r.y,y=h.x,c=h.y,f=(s-o)*(c-p)-(y-u)*(g-N);if(f===0)return!1;var T=((c-p)*(y-o)+(u-y)*(c-N))/f,E=((N-g)*(y-o)+(s-o)*(c-N))/f;return 0<T&&T<1&&0<E&&E<1},i.HALF_PI=.5*Math.PI,i.ONE_AND_HALF_PI=1.5*Math.PI,i.TWO_PI=2*Math.PI,i.THREE_PI=3*Math.PI,m.exports=i}),(function(m,L,A){function n(){}n.sign=function(i){return i>0?1:i<0?-1:0},n.floor=function(i){return i<0?Math.ceil(i):Math.floor(i)},n.ceil=function(i){return i<0?Math.floor(i):Math.ceil(i)},m.exports=n}),(function(m,L,A){function n(){}n.MAX_VALUE=2147483647,n.MIN_VALUE=-2147483648,m.exports=n}),(function(m,L,A){var n=(function(){function h(o,N){for(var s=0;s<N.length;s++){var g=N[s];g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g&&(g.writable=!0),Object.defineProperty(o,g.key,g)}}return function(o,N,s){return N&&h(o.prototype,N),s&&h(o,s),o}})();function i(h,o){if(!(h instanceof o))throw TypeError("Cannot call a class as a function")}var t=function(h){return{value:h,next:null,prev:null}},e=function(h,o,N,s){return h===null?s.head=o:h.next=o,N===null?s.tail=o:N.prev=o,o.prev=h,o.next=N,s.length++,o},r=function(h,o){var N=h.prev,s=h.next;return N===null?o.head=s:N.next=s,s===null?o.tail=N:s.prev=N,h.prev=h.next=null,o.length--,h};m.exports=(function(){function h(o){var N=this;i(this,h),this.length=0,this.head=null,this.tail=null,o==null||o.forEach(function(s){return N.push(s)})}return n(h,[{key:"size",value:function(){return this.length}},{key:"insertBefore",value:function(o,N){return e(N.prev,t(o),N,this)}},{key:"insertAfter",value:function(o,N){return e(N,t(o),N.next,this)}},{key:"insertNodeBefore",value:function(o,N){return e(N.prev,o,N,this)}},{key:"insertNodeAfter",value:function(o,N){return e(N,o,N.next,this)}},{key:"push",value:function(o){return e(this.tail,t(o),null,this)}},{key:"unshift",value:function(o){return e(null,t(o),this.head,this)}},{key:"remove",value:function(o){return r(o,this)}},{key:"pop",value:function(){return r(this.tail,this).value}},{key:"popNode",value:function(){return r(this.tail,this)}},{key:"shift",value:function(){return r(this.head,this).value}},{key:"shiftNode",value:function(){return r(this.head,this)}},{key:"get_object_at",value:function(o){if(o<=this.length()){for(var N=1,s=this.head;N<o;)s=s.next,N++;return s.value}}},{key:"set_object_at",value:function(o,N){if(o<=this.length()){for(var s=1,g=this.head;s<o;)g=g.next,s++;g.value=N}}}]),h})()}),(function(m,L,A){function n(i,t,e){this.x=null,this.y=null,i==null&&t==null&&e==null?(this.x=0,this.y=0):typeof i=="number"&&typeof t=="number"&&e==null?(this.x=i,this.y=t):i.constructor.name=="Point"&&t==null&&e==null&&(e=i,this.x=e.x,this.y=e.y)}n.prototype.getX=function(){return this.x},n.prototype.getY=function(){return this.y},n.prototype.getLocation=function(){return new n(this.x,this.y)},n.prototype.setLocation=function(i,t,e){i.constructor.name=="Point"&&t==null&&e==null?(e=i,this.setLocation(e.x,e.y)):typeof i=="number"&&typeof t=="number"&&e==null&&(parseInt(i)==i&&parseInt(t)==t?this.move(i,t):(this.x=Math.floor(i+.5),this.y=Math.floor(t+.5)))},n.prototype.move=function(i,t){this.x=i,this.y=t},n.prototype.translate=function(i,t){this.x+=i,this.y+=t},n.prototype.equals=function(i){if(i.constructor.name=="Point"){var t=i;return this.x==t.x&&this.y==t.y}return this==i},n.prototype.toString=function(){return new n().constructor.name+"[x="+this.x+",y="+this.y+"]"},m.exports=n}),(function(m,L,A){function n(i,t,e,r){this.x=0,this.y=0,this.width=0,this.height=0,i!=null&&t!=null&&e!=null&&r!=null&&(this.x=i,this.y=t,this.width=e,this.height=r)}n.prototype.getX=function(){return this.x},n.prototype.setX=function(i){this.x=i},n.prototype.getY=function(){return this.y},n.prototype.setY=function(i){this.y=i},n.prototype.getWidth=function(){return this.width},n.prototype.setWidth=function(i){this.width=i},n.prototype.getHeight=function(){return this.height},n.prototype.setHeight=function(i){this.height=i},n.prototype.getRight=function(){return this.x+this.width},n.prototype.getBottom=function(){return this.y+this.height},n.prototype.intersects=function(i){return!(this.getRight()<i.x||this.getBottom()<i.y||i.getRight()<this.x||i.getBottom()<this.y)},n.prototype.getCenterX=function(){return this.x+this.width/2},n.prototype.getMinX=function(){return this.getX()},n.prototype.getMaxX=function(){return this.getX()+this.width},n.prototype.getCenterY=function(){return this.y+this.height/2},n.prototype.getMinY=function(){return this.getY()},n.prototype.getMaxY=function(){return this.getY()+this.height},n.prototype.getWidthHalf=function(){return this.width/2},n.prototype.getHeightHalf=function(){return this.height/2},m.exports=n}),(function(m,L,A){var n=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};function i(){}i.lastID=0,i.createID=function(t){return i.isPrimitive(t)?t:(t.uniqueID==null&&(t.uniqueID=i.getString(),i.lastID++),t.uniqueID)},i.getString=function(t){return t??(t=i.lastID),"Object#"+t},i.isPrimitive=function(t){var e=t===void 0?"undefined":n(t);return t==null||e!="object"&&e!="function"},m.exports=i}),(function(m,L,A){function n(u){if(Array.isArray(u)){for(var p=0,y=Array(u.length);p<u.length;p++)y[p]=u[p];return y}else return Array.from(u)}var i=A(0),t=A(6),e=A(3),r=A(1),h=A(5),o=A(4),N=A(17),s=A(27);function g(u){s.call(this),this.layoutQuality=i.QUALITY,this.createBendsAsNeeded=i.DEFAULT_CREATE_BENDS_AS_NEEDED,this.incremental=i.DEFAULT_INCREMENTAL,this.animationOnLayout=i.DEFAULT_ANIMATION_ON_LAYOUT,this.animationDuringLayout=i.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=i.DEFAULT_ANIMATION_PERIOD,this.uniformLeafNodeSizes=i.DEFAULT_UNIFORM_LEAF_NODE_SIZES,this.edgeToDummyNodes=new Map,this.graphManager=new t(this),this.isLayoutFinished=!1,this.isSubLayout=!1,this.isRemoteUse=!1,u!=null&&(this.isRemoteUse=u)}g.RANDOM_SEED=1,g.prototype=Object.create(s.prototype),g.prototype.getGraphManager=function(){return this.graphManager},g.prototype.getAllNodes=function(){return this.graphManager.getAllNodes()},g.prototype.getAllEdges=function(){return this.graphManager.getAllEdges()},g.prototype.getAllNodesToApplyGravitation=function(){return this.graphManager.getAllNodesToApplyGravitation()},g.prototype.newGraphManager=function(){var u=new t(this);return this.graphManager=u,u},g.prototype.newGraph=function(u){return new h(null,this.graphManager,u)},g.prototype.newNode=function(u){return new e(this.graphManager,u)},g.prototype.newEdge=function(u){return new r(null,null,u)},g.prototype.checkLayoutSuccess=function(){return this.graphManager.getRoot()==null||this.graphManager.getRoot().getNodes().length==0||this.graphManager.includesInvalidEdge()},g.prototype.runLayout=function(){this.isLayoutFinished=!1,this.tilingPreLayout&&this.tilingPreLayout(),this.initParameters();var u=this.checkLayoutSuccess()?!1:this.layout();return i.ANIMATE==="during"?!1:(u&&(this.isSubLayout||this.doPostLayout()),this.tilingPostLayout&&this.tilingPostLayout(),this.isLayoutFinished=!0,u)},g.prototype.doPostLayout=function(){this.incremental||this.transform(),this.update()},g.prototype.update2=function(){if(this.createBendsAsNeeded&&(this.createBendpointsFromDummyNodes(),this.graphManager.resetAllEdges()),!this.isRemoteUse){for(var u=this.graphManager.getAllEdges(),p=0;p<u.length;p++)u[p];for(var y=this.graphManager.getRoot().getNodes(),p=0;p<y.length;p++)y[p];this.update(this.graphManager.getRoot())}},g.prototype.update=function(u){if(u==null)this.update2();else if(u instanceof e){var p=u;if(p.getChild()!=null)for(var y=p.getChild().getNodes(),c=0;c<y.length;c++)update(y[c]);p.vGraphObject!=null&&p.vGraphObject.update(p)}else if(u instanceof r){var f=u;f.vGraphObject!=null&&f.vGraphObject.update(f)}else if(u instanceof h){var T=u;T.vGraphObject!=null&&T.vGraphObject.update(T)}},g.prototype.initParameters=function(){this.isSubLayout||(this.layoutQuality=i.QUALITY,this.animationDuringLayout=i.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=i.DEFAULT_ANIMATION_PERIOD,this.animationOnLayout=i.DEFAULT_ANIMATION_ON_LAYOUT,this.incremental=i.DEFAULT_INCREMENTAL,this.createBendsAsNeeded=i.DEFAULT_CREATE_BENDS_AS_NEEDED,this.uniformLeafNodeSizes=i.DEFAULT_UNIFORM_LEAF_NODE_SIZES),this.animationDuringLayout&&(this.animationOnLayout=!1)},g.prototype.transform=function(u){if(u==null)this.transform(new o(0,0));else{var p=new N,y=this.graphManager.getRoot().updateLeftTop();if(y!=null){p.setWorldOrgX(u.x),p.setWorldOrgY(u.y),p.setDeviceOrgX(y.x),p.setDeviceOrgY(y.y);for(var c=this.getAllNodes(),f,T=0;T<c.length;T++)f=c[T],f.transform(p)}}},g.prototype.positionNodesRandomly=function(u){if(u==null)this.positionNodesRandomly(this.getGraphManager().getRoot()),this.getGraphManager().getRoot().updateBounds(!0);else for(var p,y,c=u.getNodes(),f=0;f<c.length;f++)p=c[f],y=p.getChild(),y==null||y.getNodes().length==0?p.scatter():(this.positionNodesRandomly(y),p.updateBounds())},g.prototype.getFlatForest=function(){for(var u=[],p=!0,y=this.graphManager.getRoot().getNodes(),c=!0,f=0;f<y.length;f++)y[f].getChild()!=null&&(c=!1);if(!c)return u;var T=new Set,E=[],O=new Map,a=[];for(a=a.concat(y);a.length>0&&p;){for(E.push(a[0]);E.length>0&&p;){var d=E[0];E.splice(0,1),T.add(d);for(var l=d.getEdges(),f=0;f<l.length;f++){var v=l[f].getOtherEnd(d);if(O.get(d)!=v)if(!T.has(v))E.push(v),O.set(v,d);else{p=!1;break}}}if(!p)u=[];else{var _=[].concat(n(T));u.push(_);for(var f=0;f<_.length;f++){var D=_[f],I=a.indexOf(D);I>-1&&a.splice(I,1)}T=new Set,O=new Map}}return u},g.prototype.createDummyNodesForBendpoints=function(u){for(var p=[],y=u.source,c=this.graphManager.calcLowestCommonAncestor(u.source,u.target),f=0;f<u.bendpoints.length;f++){var T=this.newNode(null);T.setRect(new Point(0,0),new Dimension(1,1)),c.add(T);var E=this.newEdge(null);this.graphManager.add(E,y,T),p.add(T),y=T}var E=this.newEdge(null);return this.graphManager.add(E,y,u.target),this.edgeToDummyNodes.set(u,p),u.isInterGraph()?this.graphManager.remove(u):c.remove(u),p},g.prototype.createBendpointsFromDummyNodes=function(){var u=[];u=u.concat(this.graphManager.getAllEdges()),u=[].concat(n(this.edgeToDummyNodes.keys()),u);for(var p=0;p<u.length;p++){var y=u[p];if(y.bendpoints.length>0){for(var c=this.edgeToDummyNodes.get(y),f=0;f<c.length;f++){var T=c[f],E=new o(T.getCenterX(),T.getCenterY()),O=y.bendpoints.get(f);O.x=E.x,O.y=E.y,T.getOwner().remove(T)}this.graphManager.add(y,y.source,y.target)}}},g.transform=function(u,p,y,c){if(y!=null&&c!=null){var f=p;if(u<=50){var T=p/y;f-=(p-T)/50*(50-u)}else{var E=p*c;f+=(E-p)/50*(u-50)}return f}else{var O,a;return u<=50?(O=9*p/500,a=p/10):(O=9*p/50,a=-8*p),O*u+a}},g.findCenterOfTree=function(u){var p=[];p=p.concat(u);var y=[],c=new Map,f=!1,T=null;(p.length==1||p.length==2)&&(f=!0,T=p[0]);for(var E=0;E<p.length;E++){var O=p[E],a=O.getNeighborsList().size;c.set(O,O.getNeighborsList().size),a==1&&y.push(O)}var d=[];for(d=d.concat(y);!f;){var l=[];l=l.concat(d),d=[];for(var E=0;E<p.length;E++){var O=p[E],v=p.indexOf(O);v>=0&&p.splice(v,1),O.getNeighborsList().forEach(function(I){if(y.indexOf(I)<0){var w=c.get(I)-1;w==1&&d.push(I),c.set(I,w)}})}y=y.concat(d),(p.length==1||p.length==2)&&(f=!0,T=p[0])}return T},g.prototype.setGraphManager=function(u){this.graphManager=u},m.exports=g}),(function(m,L,A){function n(){}n.seed=1,n.x=0,n.nextDouble=function(){return n.x=Math.sin(n.seed++)*1e4,n.x-Math.floor(n.x)},m.exports=n}),(function(m,L,A){var n=A(4);function i(t,e){this.lworldOrgX=0,this.lworldOrgY=0,this.ldeviceOrgX=0,this.ldeviceOrgY=0,this.lworldExtX=1,this.lworldExtY=1,this.ldeviceExtX=1,this.ldeviceExtY=1}i.prototype.getWorldOrgX=function(){return this.lworldOrgX},i.prototype.setWorldOrgX=function(t){this.lworldOrgX=t},i.prototype.getWorldOrgY=function(){return this.lworldOrgY},i.prototype.setWorldOrgY=function(t){this.lworldOrgY=t},i.prototype.getWorldExtX=function(){return this.lworldExtX},i.prototype.setWorldExtX=function(t){this.lworldExtX=t},i.prototype.getWorldExtY=function(){return this.lworldExtY},i.prototype.setWorldExtY=function(t){this.lworldExtY=t},i.prototype.getDeviceOrgX=function(){return this.ldeviceOrgX},i.prototype.setDeviceOrgX=function(t){this.ldeviceOrgX=t},i.prototype.getDeviceOrgY=function(){return this.ldeviceOrgY},i.prototype.setDeviceOrgY=function(t){this.ldeviceOrgY=t},i.prototype.getDeviceExtX=function(){return this.ldeviceExtX},i.prototype.setDeviceExtX=function(t){this.ldeviceExtX=t},i.prototype.getDeviceExtY=function(){return this.ldeviceExtY},i.prototype.setDeviceExtY=function(t){this.ldeviceExtY=t},i.prototype.transformX=function(t){var e=0,r=this.lworldExtX;return r!=0&&(e=this.ldeviceOrgX+(t-this.lworldOrgX)*this.ldeviceExtX/r),e},i.prototype.transformY=function(t){var e=0,r=this.lworldExtY;return r!=0&&(e=this.ldeviceOrgY+(t-this.lworldOrgY)*this.ldeviceExtY/r),e},i.prototype.inverseTransformX=function(t){var e=0,r=this.ldeviceExtX;return r!=0&&(e=this.lworldOrgX+(t-this.ldeviceOrgX)*this.lworldExtX/r),e},i.prototype.inverseTransformY=function(t){var e=0,r=this.ldeviceExtY;return r!=0&&(e=this.lworldOrgY+(t-this.ldeviceOrgY)*this.lworldExtY/r),e},i.prototype.inverseTransformPoint=function(t){return new n(this.inverseTransformX(t.x),this.inverseTransformY(t.y))},m.exports=i}),(function(m,L,A){function n(s){if(Array.isArray(s)){for(var g=0,u=Array(s.length);g<s.length;g++)u[g]=s[g];return u}else return Array.from(s)}var i=A(15),t=A(7),e=A(0),r=A(8),h=A(9);function o(){i.call(this),this.useSmartIdealEdgeLengthCalculation=t.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.idealEdgeLength=t.DEFAULT_EDGE_LENGTH,this.springConstant=t.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=t.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=t.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=t.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=t.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=t.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.displacementThresholdPerNode=3*t.DEFAULT_EDGE_LENGTH/100,this.coolingFactor=t.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.initialCoolingFactor=t.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.totalDisplacement=0,this.oldTotalDisplacement=0,this.maxIterations=t.MAX_ITERATIONS}for(var N in o.prototype=Object.create(i.prototype),i)o[N]=i[N];o.prototype.initParameters=function(){i.prototype.initParameters.call(this,arguments),this.totalIterations=0,this.notAnimatedIterations=0,this.useFRGridVariant=t.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION,this.grid=[]},o.prototype.calcIdealEdgeLengths=function(){for(var s,g,u,p,y,c,f=this.getGraphManager().getAllEdges(),T=0;T<f.length;T++)s=f[T],s.idealLength=this.idealEdgeLength,s.isInterGraph&&(u=s.getSource(),p=s.getTarget(),y=s.getSourceInLca().getEstimatedSize(),c=s.getTargetInLca().getEstimatedSize(),this.useSmartIdealEdgeLengthCalculation&&(s.idealLength+=y+c-2*e.SIMPLE_NODE_SIZE),g=s.getLca().getInclusionTreeDepth(),s.idealLength+=t.DEFAULT_EDGE_LENGTH*t.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR*(u.getInclusionTreeDepth()+p.getInclusionTreeDepth()-2*g))},o.prototype.initSpringEmbedder=function(){var s=this.getAllNodes().length;this.incremental?(s>t.ADAPTATION_LOWER_NODE_LIMIT&&(this.coolingFactor=Math.max(this.coolingFactor*t.COOLING_ADAPTATION_FACTOR,this.coolingFactor-(s-t.ADAPTATION_LOWER_NODE_LIMIT)/(t.ADAPTATION_UPPER_NODE_LIMIT-t.ADAPTATION_LOWER_NODE_LIMIT)*this.coolingFactor*(1-t.COOLING_ADAPTATION_FACTOR))),this.maxNodeDisplacement=t.MAX_NODE_DISPLACEMENT_INCREMENTAL):(s>t.ADAPTATION_LOWER_NODE_LIMIT?this.coolingFactor=Math.max(t.COOLING_ADAPTATION_FACTOR,1-(s-t.ADAPTATION_LOWER_NODE_LIMIT)/(t.ADAPTATION_UPPER_NODE_LIMIT-t.ADAPTATION_LOWER_NODE_LIMIT)*(1-t.COOLING_ADAPTATION_FACTOR)):this.coolingFactor=1,this.initialCoolingFactor=this.coolingFactor,this.maxNodeDisplacement=t.MAX_NODE_DISPLACEMENT),this.maxIterations=Math.max(this.getAllNodes().length*5,this.maxIterations),this.totalDisplacementThreshold=this.displacementThresholdPerNode*this.getAllNodes().length,this.repulsionRange=this.calcRepulsionRange()},o.prototype.calcSpringForces=function(){for(var s=this.getAllEdges(),g,u=0;u<s.length;u++)g=s[u],this.calcSpringForce(g,g.idealLength)},o.prototype.calcRepulsionForces=function(){var s=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,u,p,y,c,f=this.getAllNodes(),T;if(this.useFRGridVariant)for(this.totalIterations%t.GRID_CALCULATION_CHECK_PERIOD==1&&s&&this.updateGrid(),T=new Set,u=0;u<f.length;u++)y=f[u],this.calculateRepulsionForceOfANode(y,T,s,g),T.add(y);else for(u=0;u<f.length;u++)for(y=f[u],p=u+1;p<f.length;p++)c=f[p],y.getOwner()==c.getOwner()&&this.calcRepulsionForce(y,c)},o.prototype.calcGravitationalForces=function(){for(var s,g=this.getAllNodesToApplyGravitation(),u=0;u<g.length;u++)s=g[u],this.calcGravitationalForce(s)},o.prototype.moveNodes=function(){for(var s=this.getAllNodes(),g,u=0;u<s.length;u++)g=s[u],g.move()},o.prototype.calcSpringForce=function(s,g){var u=s.getSource(),p=s.getTarget(),y,c,f,T;if(this.uniformLeafNodeSizes&&u.getChild()==null&&p.getChild()==null)s.updateLengthSimple();else if(s.updateLength(),s.isOverlapingSourceAndTarget)return;y=s.getLength(),y!=0&&(c=this.springConstant*(y-g),f=c*(s.lengthX/y),T=c*(s.lengthY/y),u.springForceX+=f,u.springForceY+=T,p.springForceX-=f,p.springForceY-=T)},o.prototype.calcRepulsionForce=function(s,g){var u=s.getRect(),p=g.getRect(),y=[,,],c=[,,,,],f,T,E,O,a,d,l;if(u.intersects(p)){r.calcSeparationAmount(u,p,y,t.DEFAULT_EDGE_LENGTH/2),d=2*y[0],l=2*y[1];var v=s.noOfChildren*g.noOfChildren/(s.noOfChildren+g.noOfChildren);s.repulsionForceX-=v*d,s.repulsionForceY-=v*l,g.repulsionForceX+=v*d,g.repulsionForceY+=v*l}else this.uniformLeafNodeSizes&&s.getChild()==null&&g.getChild()==null?(f=p.getCenterX()-u.getCenterX(),T=p.getCenterY()-u.getCenterY()):(r.getIntersection(u,p,c),f=c[2]-c[0],T=c[3]-c[1]),Math.abs(f)<t.MIN_REPULSION_DIST&&(f=h.sign(f)*t.MIN_REPULSION_DIST),Math.abs(T)<t.MIN_REPULSION_DIST&&(T=h.sign(T)*t.MIN_REPULSION_DIST),E=f*f+T*T,O=Math.sqrt(E),a=this.repulsionConstant*s.noOfChildren*g.noOfChildren/E,d=a*f/O,l=a*T/O,s.repulsionForceX-=d,s.repulsionForceY-=l,g.repulsionForceX+=d,g.repulsionForceY+=l},o.prototype.calcGravitationalForce=function(s){var g=s.getOwner(),u=(g.getRight()+g.getLeft())/2,p=(g.getTop()+g.getBottom())/2,y=s.getCenterX()-u,c=s.getCenterY()-p,f=Math.abs(y)+s.getWidth()/2,T=Math.abs(c)+s.getHeight()/2,E;s.getOwner()==this.graphManager.getRoot()?(E=g.getEstimatedSize()*this.gravityRangeFactor,(f>E||T>E)&&(s.gravitationForceX=-this.gravityConstant*y,s.gravitationForceY=-this.gravityConstant*c)):(E=g.getEstimatedSize()*this.compoundGravityRangeFactor,(f>E||T>E)&&(s.gravitationForceX=-this.gravityConstant*y*this.compoundGravityConstant,s.gravitationForceY=-this.gravityConstant*c*this.compoundGravityConstant))},o.prototype.isConverged=function(){var s,g=!1;return this.totalIterations>this.maxIterations/3&&(g=Math.abs(this.totalDisplacement-this.oldTotalDisplacement)<2),s=this.totalDisplacement<this.totalDisplacementThreshold,this.oldTotalDisplacement=this.totalDisplacement,s||g},o.prototype.animate=function(){this.animationDuringLayout&&!this.isSubLayout&&(this.notAnimatedIterations==this.animationPeriod?(this.update(),this.notAnimatedIterations=0):this.notAnimatedIterations++)},o.prototype.calcNoOfChildrenForAllNodes=function(){for(var s,g=this.graphManager.getAllNodes(),u=0;u<g.length;u++)s=g[u],s.noOfChildren=s.getNoOfChildren()},o.prototype.calcGrid=function(s){var g=0,u=0;g=parseInt(Math.ceil((s.getRight()-s.getLeft())/this.repulsionRange)),u=parseInt(Math.ceil((s.getBottom()-s.getTop())/this.repulsionRange));for(var p=Array(g),y=0;y<g;y++)p[y]=Array(u);for(var y=0;y<g;y++)for(var c=0;c<u;c++)p[y][c]=[];return p},o.prototype.addNodeToGrid=function(s,g,u){var p=0,y=0,c=0,f=0;p=parseInt(Math.floor((s.getRect().x-g)/this.repulsionRange)),y=parseInt(Math.floor((s.getRect().width+s.getRect().x-g)/this.repulsionRange)),c=parseInt(Math.floor((s.getRect().y-u)/this.repulsionRange)),f=parseInt(Math.floor((s.getRect().height+s.getRect().y-u)/this.repulsionRange));for(var T=p;T<=y;T++)for(var E=c;E<=f;E++)this.grid[T][E].push(s),s.setGridCoordinates(p,y,c,f)},o.prototype.updateGrid=function(){var s,g,u=this.getAllNodes();for(this.grid=this.calcGrid(this.graphManager.getRoot()),s=0;s<u.length;s++)g=u[s],this.addNodeToGrid(g,this.graphManager.getRoot().getLeft(),this.graphManager.getRoot().getTop())},o.prototype.calculateRepulsionForceOfANode=function(s,g,u,p){if(this.totalIterations%t.GRID_CALCULATION_CHECK_PERIOD==1&&u||p){var y=new Set;s.surrounding=[];for(var c,f=this.grid,T=s.startX-1;T<s.finishX+2;T++)for(var E=s.startY-1;E<s.finishY+2;E++)if(!(T<0||E<0||T>=f.length||E>=f[0].length)){for(var O=0;O<f[T][E].length;O++)if(c=f[T][E][O],!(s.getOwner()!=c.getOwner()||s==c)&&!g.has(c)&&!y.has(c)){var a=Math.abs(s.getCenterX()-c.getCenterX())-(s.getWidth()/2+c.getWidth()/2),d=Math.abs(s.getCenterY()-c.getCenterY())-(s.getHeight()/2+c.getHeight()/2);a<=this.repulsionRange&&d<=this.repulsionRange&&y.add(c)}}s.surrounding=[].concat(n(y))}for(T=0;T<s.surrounding.length;T++)this.calcRepulsionForce(s,s.surrounding[T])},o.prototype.calcRepulsionRange=function(){return 0},m.exports=o}),(function(m,L,A){var n=A(1),i=A(7);function t(r,h,o){n.call(this,r,h,o),this.idealLength=i.DEFAULT_EDGE_LENGTH}for(var e in t.prototype=Object.create(n.prototype),n)t[e]=n[e];m.exports=t}),(function(m,L,A){var n=A(3);function i(e,r,h,o){n.call(this,e,r,h,o),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0,this.startX=0,this.finishX=0,this.startY=0,this.finishY=0,this.surrounding=[]}for(var t in i.prototype=Object.create(n.prototype),n)i[t]=n[t];i.prototype.setGridCoordinates=function(e,r,h,o){this.startX=e,this.finishX=r,this.startY=h,this.finishY=o},m.exports=i}),(function(m,L,A){function n(i,t){this.width=0,this.height=0,i!==null&&t!==null&&(this.height=t,this.width=i)}n.prototype.getWidth=function(){return this.width},n.prototype.setWidth=function(i){this.width=i},n.prototype.getHeight=function(){return this.height},n.prototype.setHeight=function(i){this.height=i},m.exports=n}),(function(m,L,A){var n=A(14);function i(){this.map={},this.keys=[]}i.prototype.put=function(t,e){var r=n.createID(t);this.contains(r)||(this.map[r]=e,this.keys.push(t))},i.prototype.contains=function(t){return n.createID(t),this.map[t]!=null},i.prototype.get=function(t){var e=n.createID(t);return this.map[e]},i.prototype.keySet=function(){return this.keys},m.exports=i}),(function(m,L,A){var n=A(14);function i(){this.set={}}i.prototype.add=function(t){var e=n.createID(t);this.contains(e)||(this.set[e]=t)},i.prototype.remove=function(t){delete this.set[n.createID(t)]},i.prototype.clear=function(){this.set={}},i.prototype.contains=function(t){return this.set[n.createID(t)]==t},i.prototype.isEmpty=function(){return this.size()===0},i.prototype.size=function(){return Object.keys(this.set).length},i.prototype.addAllTo=function(t){for(var e=Object.keys(this.set),r=e.length,h=0;h<r;h++)t.push(this.set[e[h]])},i.prototype.size=function(){return Object.keys(this.set).length},i.prototype.addAll=function(t){for(var e=t.length,r=0;r<e;r++){var h=t[r];this.add(h)}},m.exports=i}),(function(m,L,A){var n=(function(){function e(r,h){for(var o=0;o<h.length;o++){var N=h[o];N.enumerable=N.enumerable||!1,N.configurable=!0,"value"in N&&(N.writable=!0),Object.defineProperty(r,N.key,N)}}return function(r,h,o){return h&&e(r.prototype,h),o&&e(r,o),r}})();function i(e,r){if(!(e instanceof r))throw TypeError("Cannot call a class as a function")}var t=A(11);m.exports=(function(){function e(r,h){i(this,e),(h!==null||h!==void 0)&&(this.compareFunction=this._defaultCompareFunction);var o=void 0;o=r instanceof t?r.size():r.length,this._quicksort(r,0,o-1)}return n(e,[{key:"_quicksort",value:function(r,h,o){if(h<o){var N=this._partition(r,h,o);this._quicksort(r,h,N),this._quicksort(r,N+1,o)}}},{key:"_partition",value:function(r,h,o){for(var N=this._get(r,h),s=h,g=o;;){for(;this.compareFunction(N,this._get(r,g));)g--;for(;this.compareFunction(this._get(r,s),N);)s++;if(s<g)this._swap(r,s,g),s++,g--;else return g}}},{key:"_get",value:function(r,h){return r instanceof t?r.get_object_at(h):r[h]}},{key:"_set",value:function(r,h,o){r instanceof t?r.set_object_at(h,o):r[h]=o}},{key:"_swap",value:function(r,h,o){var N=this._get(r,h);this._set(r,h,this._get(r,o)),this._set(r,o,N)}},{key:"_defaultCompareFunction",value:function(r,h){return h>r}}]),e})()}),(function(m,L,A){var n=(function(){function t(e,r){for(var h=0;h<r.length;h++){var o=r[h];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(e,r,h){return r&&t(e.prototype,r),h&&t(e,h),e}})();function i(t,e){if(!(t instanceof e))throw TypeError("Cannot call a class as a function")}m.exports=(function(){function t(e,r){var h=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:-1,N=arguments.length>4&&arguments[4]!==void 0?arguments[4]:-1;i(this,t),this.sequence1=e,this.sequence2=r,this.match_score=h,this.mismatch_penalty=o,this.gap_penalty=N,this.iMax=e.length+1,this.jMax=r.length+1,this.grid=Array(this.iMax);for(var s=0;s<this.iMax;s++){this.grid[s]=Array(this.jMax);for(var g=0;g<this.jMax;g++)this.grid[s][g]=0}this.tracebackGrid=Array(this.iMax);for(var u=0;u<this.iMax;u++){this.tracebackGrid[u]=Array(this.jMax);for(var p=0;p<this.jMax;p++)this.tracebackGrid[u][p]=[null,null,null]}this.alignments=[],this.score=-1,this.computeGrids()}return n(t,[{key:"getScore",value:function(){return this.score}},{key:"getAlignments",value:function(){return this.alignments}},{key:"computeGrids",value:function(){for(var e=1;e<this.jMax;e++)this.grid[0][e]=this.grid[0][e-1]+this.gap_penalty,this.tracebackGrid[0][e]=[!1,!1,!0];for(var r=1;r<this.iMax;r++)this.grid[r][0]=this.grid[r-1][0]+this.gap_penalty,this.tracebackGrid[r][0]=[!1,!0,!1];for(var h=1;h<this.iMax;h++)for(var o=1;o<this.jMax;o++){var N=void 0;N=this.sequence1[h-1]===this.sequence2[o-1]?this.grid[h-1][o-1]+this.match_score:this.grid[h-1][o-1]+this.mismatch_penalty;var s=this.grid[h-1][o]+this.gap_penalty,g=this.grid[h][o-1]+this.gap_penalty,u=[N,s,g],p=this.arrayAllMaxIndexes(u);this.grid[h][o]=u[p[0]],this.tracebackGrid[h][o]=[p.includes(0),p.includes(1),p.includes(2)]}this.score=this.grid[this.iMax-1][this.jMax-1]}},{key:"alignmentTraceback",value:function(){var e=[];for(e.push({pos:[this.sequence1.length,this.sequence2.length],seq1:"",seq2:""});e[0];){var r=e[0],h=this.tracebackGrid[r.pos[0]][r.pos[1]];h[0]&&e.push({pos:[r.pos[0]-1,r.pos[1]-1],seq1:this.sequence1[r.pos[0]-1]+r.seq1,seq2:this.sequence2[r.pos[1]-1]+r.seq2}),h[1]&&e.push({pos:[r.pos[0]-1,r.pos[1]],seq1:this.sequence1[r.pos[0]-1]+r.seq1,seq2:"-"+r.seq2}),h[2]&&e.push({pos:[r.pos[0],r.pos[1]-1],seq1:"-"+r.seq1,seq2:this.sequence2[r.pos[1]-1]+r.seq2}),r.pos[0]===0&&r.pos[1]===0&&this.alignments.push({sequence1:r.seq1,sequence2:r.seq2}),e.shift()}return this.alignments}},{key:"getAllIndexes",value:function(e,r){for(var h=[],o=-1;(o=e.indexOf(r,o+1))!==-1;)h.push(o);return h}},{key:"arrayAllMaxIndexes",value:function(e){return this.getAllIndexes(e,Math.max.apply(null,e))}}]),t})()}),(function(m,L,A){var n=function(){};n.FDLayout=A(18),n.FDLayoutConstants=A(7),n.FDLayoutEdge=A(19),n.FDLayoutNode=A(20),n.DimensionD=A(21),n.HashMap=A(22),n.HashSet=A(23),n.IGeometry=A(8),n.IMath=A(9),n.Integer=A(10),n.Point=A(12),n.PointD=A(4),n.RandomSeed=A(16),n.RectangleD=A(13),n.Transform=A(17),n.UniqueIDGeneretor=A(14),n.Quicksort=A(24),n.LinkedList=A(11),n.LGraphObject=A(2),n.LGraph=A(5),n.LEdge=A(1),n.LGraphManager=A(6),n.LNode=A(3),n.Layout=A(15),n.LayoutConstants=A(0),n.NeedlemanWunsch=A(25),m.exports=n}),(function(m,L,A){function n(){this.listeners=[]}var i=n.prototype;i.addListener=function(t,e){this.listeners.push({event:t,callback:e})},i.removeListener=function(t,e){for(var r=this.listeners.length;r>=0;r--){var h=this.listeners[r];h.event===t&&h.callback===e&&this.listeners.splice(r,1)}},i.emit=function(t,e){for(var r=0;r<this.listeners.length;r++){var h=this.listeners[r];t===h.event&&h.callback(e)}},m.exports=n})])})})),Q=V(((C,P)=>{(function(m,L){typeof C=="object"&&typeof P=="object"?P.exports=L(Z()):typeof define=="function"&&define.amd?define(["layout-base"],L):typeof C=="object"?C.coseBase=L(Z()):m.coseBase=L(m.layoutBase)})(C,function(m){return(function(L){var A={};function n(i){if(A[i])return A[i].exports;var t=A[i]={i,l:!1,exports:{}};return L[i].call(t.exports,t,t.exports,n),t.l=!0,t.exports}return n.m=L,n.c=A,n.i=function(i){return i},n.d=function(i,t,e){n.o(i,t)||Object.defineProperty(i,t,{configurable:!1,enumerable:!0,get:e})},n.n=function(i){var t=i&&i.__esModule?function(){return i.default}:function(){return i};return n.d(t,"a",t),t},n.o=function(i,t){return Object.prototype.hasOwnProperty.call(i,t)},n.p="",n(n.s=7)})([(function(L,A){L.exports=m}),(function(L,A,n){var i=n(0).FDLayoutConstants;function t(){}for(var e in i)t[e]=i[e];t.DEFAULT_USE_MULTI_LEVEL_SCALING=!1,t.DEFAULT_RADIAL_SEPARATION=i.DEFAULT_EDGE_LENGTH,t.DEFAULT_COMPONENT_SEPERATION=60,t.TILE=!0,t.TILING_PADDING_VERTICAL=10,t.TILING_PADDING_HORIZONTAL=10,t.TREE_REDUCTION_ON_INCREMENTAL=!1,L.exports=t}),(function(L,A,n){var i=n(0).FDLayoutEdge;function t(r,h,o){i.call(this,r,h,o)}for(var e in t.prototype=Object.create(i.prototype),i)t[e]=i[e];L.exports=t}),(function(L,A,n){var i=n(0).LGraph;function t(r,h,o){i.call(this,r,h,o)}for(var e in t.prototype=Object.create(i.prototype),i)t[e]=i[e];L.exports=t}),(function(L,A,n){var i=n(0).LGraphManager;function t(r){i.call(this,r)}for(var e in t.prototype=Object.create(i.prototype),i)t[e]=i[e];L.exports=t}),(function(L,A,n){var i=n(0).FDLayoutNode,t=n(0).IMath;function e(h,o,N,s){i.call(this,h,o,N,s)}for(var r in e.prototype=Object.create(i.prototype),i)e[r]=i[r];e.prototype.move=function(){var h=this.graphManager.getLayout();this.displacementX=h.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.noOfChildren,this.displacementY=h.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.noOfChildren,Math.abs(this.displacementX)>h.coolingFactor*h.maxNodeDisplacement&&(this.displacementX=h.coolingFactor*h.maxNodeDisplacement*t.sign(this.displacementX)),Math.abs(this.displacementY)>h.coolingFactor*h.maxNodeDisplacement&&(this.displacementY=h.coolingFactor*h.maxNodeDisplacement*t.sign(this.displacementY)),this.child==null||this.child.getNodes().length==0?this.moveBy(this.displacementX,this.displacementY):this.propogateDisplacementToChildren(this.displacementX,this.displacementY),h.totalDisplacement+=Math.abs(this.displacementX)+Math.abs(this.displacementY),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0},e.prototype.propogateDisplacementToChildren=function(h,o){for(var N=this.getChild().getNodes(),s,g=0;g<N.length;g++)s=N[g],s.getChild()==null?(s.moveBy(h,o),s.displacementX+=h,s.displacementY+=o):s.propogateDisplacementToChildren(h,o)},e.prototype.setPred1=function(h){this.pred1=h},e.prototype.getPred1=function(){return pred1},e.prototype.getPred2=function(){return pred2},e.prototype.setNext=function(h){this.next=h},e.prototype.getNext=function(){return next},e.prototype.setProcessed=function(h){this.processed=h},e.prototype.isProcessed=function(){return processed},L.exports=e}),(function(L,A,n){var i=n(0).FDLayout,t=n(4),e=n(3),r=n(5),h=n(2),o=n(1),N=n(0).FDLayoutConstants,s=n(0).LayoutConstants,g=n(0).Point,u=n(0).PointD,p=n(0).Layout,y=n(0).Integer,c=n(0).IGeometry,f=n(0).LGraph,T=n(0).Transform;function E(){i.call(this),this.toBeTiled={}}for(var O in E.prototype=Object.create(i.prototype),i)E[O]=i[O];E.prototype.newGraphManager=function(){var a=new t(this);return this.graphManager=a,a},E.prototype.newGraph=function(a){return new e(null,this.graphManager,a)},E.prototype.newNode=function(a){return new r(this.graphManager,a)},E.prototype.newEdge=function(a){return new h(null,null,a)},E.prototype.initParameters=function(){i.prototype.initParameters.call(this,arguments),this.isSubLayout||(o.DEFAULT_EDGE_LENGTH<10?this.idealEdgeLength=10:this.idealEdgeLength=o.DEFAULT_EDGE_LENGTH,this.useSmartIdealEdgeLengthCalculation=o.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.springConstant=N.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=N.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=N.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=N.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=N.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=N.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.prunedNodesAll=[],this.growTreeIterations=0,this.afterGrowthIterations=0,this.isTreeGrowing=!1,this.isGrowthFinished=!1,this.coolingCycle=0,this.maxCoolingCycle=this.maxIterations/N.CONVERGENCE_CHECK_PERIOD,this.finalTemperature=N.CONVERGENCE_CHECK_PERIOD/this.maxIterations,this.coolingAdjuster=1)},E.prototype.layout=function(){return s.DEFAULT_CREATE_BENDS_AS_NEEDED&&(this.createBendpoints(),this.graphManager.resetAllEdges()),this.level=0,this.classicLayout()},E.prototype.classicLayout=function(){if(this.nodesWithGravity=this.calculateNodesToApplyGravitationTo(),this.graphManager.setAllNodesToApplyGravitation(this.nodesWithGravity),this.calcNoOfChildrenForAllNodes(),this.graphManager.calcLowestCommonAncestors(),this.graphManager.calcInclusionTreeDepths(),this.graphManager.getRoot().calcEstimatedSize(),this.calcIdealEdgeLengths(),this.incremental){if(o.TREE_REDUCTION_ON_INCREMENTAL){this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var a=new Set(this.getAllNodes()),d=this.nodesWithGravity.filter(function(v){return a.has(v)});this.graphManager.setAllNodesToApplyGravitation(d)}}else{var l=this.getFlatForest();if(l.length>0)this.positionNodesRadially(l);else{this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var a=new Set(this.getAllNodes()),d=this.nodesWithGravity.filter(function(D){return a.has(D)});this.graphManager.setAllNodesToApplyGravitation(d),this.positionNodesRandomly()}}return this.initSpringEmbedder(),this.runSpringEmbedder(),!0},E.prototype.tick=function(){if(this.totalIterations++,this.totalIterations===this.maxIterations&&!this.isTreeGrowing&&!this.isGrowthFinished)if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0;if(this.totalIterations%N.CONVERGENCE_CHECK_PERIOD==0&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.isConverged())if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0;this.coolingCycle++,this.layoutQuality==0?this.coolingAdjuster=this.coolingCycle:this.layoutQuality==1&&(this.coolingAdjuster=this.coolingCycle/3),this.coolingFactor=Math.max(this.initialCoolingFactor-this.coolingCycle**+(Math.log(100*(this.initialCoolingFactor-this.finalTemperature))/Math.log(this.maxCoolingCycle))/100*this.coolingAdjuster,this.finalTemperature),this.animationPeriod=Math.ceil(this.initialAnimationPeriod*Math.sqrt(this.coolingFactor))}if(this.isTreeGrowing){if(this.growTreeIterations%10==0)if(this.prunedNodesAll.length>0){this.graphManager.updateBounds(),this.updateGrid(),this.growTree(this.prunedNodesAll),this.graphManager.resetAllNodesToApplyGravitation();var a=new Set(this.getAllNodes()),d=this.nodesWithGravity.filter(function(_){return a.has(_)});this.graphManager.setAllNodesToApplyGravitation(d),this.graphManager.updateBounds(),this.updateGrid(),this.coolingFactor=N.DEFAULT_COOLING_FACTOR_INCREMENTAL}else this.isTreeGrowing=!1,this.isGrowthFinished=!0;this.growTreeIterations++}if(this.isGrowthFinished){if(this.isConverged())return!0;this.afterGrowthIterations%10==0&&(this.graphManager.updateBounds(),this.updateGrid()),this.coolingFactor=N.DEFAULT_COOLING_FACTOR_INCREMENTAL*((100-this.afterGrowthIterations)/100),this.afterGrowthIterations++}var l=!this.isTreeGrowing&&!this.isGrowthFinished,v=this.growTreeIterations%10==1&&this.isTreeGrowing||this.afterGrowthIterations%10==1&&this.isGrowthFinished;return this.totalDisplacement=0,this.graphManager.updateBounds(),this.calcSpringForces(),this.calcRepulsionForces(l,v),this.calcGravitationalForces(),this.moveNodes(),this.animate(),!1},E.prototype.getPositionsData=function(){for(var a=this.graphManager.getAllNodes(),d={},l=0;l<a.length;l++){var v=a[l].rect,_=a[l].id;d[_]={id:_,x:v.getCenterX(),y:v.getCenterY(),w:v.width,h:v.height}}return d},E.prototype.runSpringEmbedder=function(){this.initialAnimationPeriod=25,this.animationPeriod=this.initialAnimationPeriod;var a=!1;if(N.ANIMATE==="during")this.emit("layoutstarted");else{for(;!a;)a=this.tick();this.graphManager.updateBounds()}},E.prototype.calculateNodesToApplyGravitationTo=function(){var a=[],d,l=this.graphManager.getGraphs(),v=l.length,_;for(_=0;_<v;_++)d=l[_],d.updateConnected(),d.isConnected||(a=a.concat(d.getNodes()));return a},E.prototype.createBendpoints=function(){var a=[];a=a.concat(this.graphManager.getAllEdges());var d=new Set,l;for(l=0;l<a.length;l++){var v=a[l];if(!d.has(v)){var _=v.getSource(),D=v.getTarget();if(_==D)v.getBendpoints().push(new u),v.getBendpoints().push(new u),this.createDummyNodesForBendpoints(v),d.add(v);else{var I=[];if(I=I.concat(_.getEdgeListToNode(D)),I=I.concat(D.getEdgeListToNode(_)),!d.has(I[0])){if(I.length>1){var w;for(w=0;w<I.length;w++){var R=I[w];R.getBendpoints().push(new u),this.createDummyNodesForBendpoints(R)}}I.forEach(function(G){d.add(G)})}}}if(d.size==a.length)break}},E.prototype.positionNodesRadially=function(a){for(var d=new g(0,0),l=Math.ceil(Math.sqrt(a.length)),v=0,_=0,D=0,I=new u(0,0),w=0;w<a.length;w++){w%l==0&&(D=0,_=v,w!=0&&(_+=o.DEFAULT_COMPONENT_SEPERATION),v=0);var R=a[w],G=p.findCenterOfTree(R);d.x=D,d.y=_,I=E.radialLayout(R,G,d),I.y>v&&(v=Math.floor(I.y)),D=Math.floor(I.x+o.DEFAULT_COMPONENT_SEPERATION)}this.transform(new u(s.WORLD_CENTER_X-I.x/2,s.WORLD_CENTER_Y-I.y/2))},E.radialLayout=function(a,d,l){var v=Math.max(this.maxDiagonalInTree(a),o.DEFAULT_RADIAL_SEPARATION);E.branchRadialLayout(d,null,0,359,0,v);var _=f.calculateBounds(a),D=new T;D.setDeviceOrgX(_.getMinX()),D.setDeviceOrgY(_.getMinY()),D.setWorldOrgX(l.x),D.setWorldOrgY(l.y);for(var I=0;I<a.length;I++)a[I].transform(D);var w=new u(_.getMaxX(),_.getMaxY());return D.inverseTransformPoint(w)},E.branchRadialLayout=function(a,d,l,v,_,D){var I=(v-l+1)/2;I<0&&(I+=180);var w=(I+l)%360*c.TWO_PI/360,R=_*Math.cos(w),G=_*Math.sin(w);a.setCenter(R,G);var x=[];x=x.concat(a.getEdges());var M=x.length;d!=null&&M--;for(var U=0,b=x.length,F,S=a.getEdgesBetween(d);S.length>1;){var Y=S[0];S.splice(0,1);var X=x.indexOf(Y);X>=0&&x.splice(X,1),b--,M--}F=d==null?0:(x.indexOf(S[0])+1)%b;for(var W=Math.abs(v-l)/M,B=F;U!=M;B=++B%b){var H=x[B].getOtherEnd(a);if(H!=d){var q=(l+U*W)%360,ot=(q+W)%360;E.branchRadialLayout(H,a,q,ot,_+D,D),U++}}},E.maxDiagonalInTree=function(a){for(var d=y.MIN_VALUE,l=0;l<a.length;l++){var v=a[l].getDiagonal();v>d&&(d=v)}return d},E.prototype.calcRepulsionRange=function(){return 2*(this.level+1)*this.idealEdgeLength},E.prototype.groupZeroDegreeMembers=function(){var a=this,d={};this.memberGroups={},this.idToDummyNode={};for(var l=[],v=this.graphManager.getAllNodes(),_=0;_<v.length;_++){var D=v[_],I=D.getParent();this.getNodeDegreeWithChildren(D)===0&&(I.id==null||!this.getToBeTiled(I))&&l.push(D)}for(var _=0;_<l.length;_++){var D=l[_],w=D.getParent().id;d[w]===void 0&&(d[w]=[]),d[w]=d[w].concat(D)}Object.keys(d).forEach(function(R){if(d[R].length>1){var G="DummyCompound_"+R;a.memberGroups[G]=d[R];var x=d[R][0].getParent(),M=new r(a.graphManager);M.id=G,M.paddingLeft=x.paddingLeft||0,M.paddingRight=x.paddingRight||0,M.paddingBottom=x.paddingBottom||0,M.paddingTop=x.paddingTop||0,a.idToDummyNode[G]=M;var U=a.getGraphManager().add(a.newGraph(),M),b=x.getChild();b.add(M);for(var F=0;F<d[R].length;F++){var S=d[R][F];b.remove(S),U.add(S)}}})},E.prototype.clearCompounds=function(){var a={},d={};this.performDFSOnCompounds();for(var l=0;l<this.compoundOrder.length;l++)d[this.compoundOrder[l].id]=this.compoundOrder[l],a[this.compoundOrder[l].id]=[].concat(this.compoundOrder[l].getChild().getNodes()),this.graphManager.remove(this.compoundOrder[l].getChild()),this.compoundOrder[l].child=null;this.graphManager.resetAllNodes(),this.tileCompoundMembers(a,d)},E.prototype.clearZeroDegreeMembers=function(){var a=this,d=this.tiledZeroDegreePack=[];Object.keys(this.memberGroups).forEach(function(l){var v=a.idToDummyNode[l];d[l]=a.tileNodes(a.memberGroups[l],v.paddingLeft+v.paddingRight),v.rect.width=d[l].width,v.rect.height=d[l].height})},E.prototype.repopulateCompounds=function(){for(var a=this.compoundOrder.length-1;a>=0;a--){var d=this.compoundOrder[a],l=d.id,v=d.paddingLeft,_=d.paddingTop;this.adjustLocations(this.tiledMemberPack[l],d.rect.x,d.rect.y,v,_)}},E.prototype.repopulateZeroDegreeMembers=function(){var a=this,d=this.tiledZeroDegreePack;Object.keys(d).forEach(function(l){var v=a.idToDummyNode[l],_=v.paddingLeft,D=v.paddingTop;a.adjustLocations(d[l],v.rect.x,v.rect.y,_,D)})},E.prototype.getToBeTiled=function(a){var d=a.id;if(this.toBeTiled[d]!=null)return this.toBeTiled[d];var l=a.getChild();if(l==null)return this.toBeTiled[d]=!1,!1;for(var v=l.getNodes(),_=0;_<v.length;_++){var D=v[_];if(this.getNodeDegree(D)>0)return this.toBeTiled[d]=!1,!1;if(D.getChild()==null){this.toBeTiled[D.id]=!1;continue}if(!this.getToBeTiled(D))return this.toBeTiled[d]=!1,!1}return this.toBeTiled[d]=!0,!0},E.prototype.getNodeDegree=function(a){a.id;for(var d=a.getEdges(),l=0,v=0;v<d.length;v++){var _=d[v];_.getSource().id!==_.getTarget().id&&(l+=1)}return l},E.prototype.getNodeDegreeWithChildren=function(a){var d=this.getNodeDegree(a);if(a.getChild()==null)return d;for(var l=a.getChild().getNodes(),v=0;v<l.length;v++){var _=l[v];d+=this.getNodeDegreeWithChildren(_)}return d},E.prototype.performDFSOnCompounds=function(){this.compoundOrder=[],this.fillCompexOrderByDFS(this.graphManager.getRoot().getNodes())},E.prototype.fillCompexOrderByDFS=function(a){for(var d=0;d<a.length;d++){var l=a[d];l.getChild()!=null&&this.fillCompexOrderByDFS(l.getChild().getNodes()),this.getToBeTiled(l)&&this.compoundOrder.push(l)}},E.prototype.adjustLocations=function(a,d,l,v,_){d+=v,l+=_;for(var D=d,I=0;I<a.rows.length;I++){var w=a.rows[I];d=D;for(var R=0,G=0;G<w.length;G++){var x=w[G];x.rect.x=d,x.rect.y=l,d+=x.rect.width+a.horizontalPadding,x.rect.height>R&&(R=x.rect.height)}l+=R+a.verticalPadding}},E.prototype.tileCompoundMembers=function(a,d){var l=this;this.tiledMemberPack=[],Object.keys(a).forEach(function(v){var _=d[v];l.tiledMemberPack[v]=l.tileNodes(a[v],_.paddingLeft+_.paddingRight),_.rect.width=l.tiledMemberPack[v].width,_.rect.height=l.tiledMemberPack[v].height})},E.prototype.tileNodes=function(a,d){var l={rows:[],rowWidth:[],rowHeight:[],width:0,height:d,verticalPadding:o.TILING_PADDING_VERTICAL,horizontalPadding:o.TILING_PADDING_HORIZONTAL};a.sort(function(D,I){return D.rect.width*D.rect.height>I.rect.width*I.rect.height?-1:D.rect.width*D.rect.height<I.rect.width*I.rect.height?1:0});for(var v=0;v<a.length;v++){var _=a[v];l.rows.length==0?this.insertNodeToRow(l,_,0,d):this.canAddHorizontal(l,_.rect.width,_.rect.height)?this.insertNodeToRow(l,_,this.getShortestRowIndex(l),d):this.insertNodeToRow(l,_,l.rows.length,d),this.shiftToLastRow(l)}return l},E.prototype.insertNodeToRow=function(a,d,l,v){var _=v;l==a.rows.length&&(a.rows.push([]),a.rowWidth.push(_),a.rowHeight.push(0));var D=a.rowWidth[l]+d.rect.width;a.rows[l].length>0&&(D+=a.horizontalPadding),a.rowWidth[l]=D,a.width<D&&(a.width=D);var I=d.rect.height;l>0&&(I+=a.verticalPadding);var w=0;I>a.rowHeight[l]&&(w=a.rowHeight[l],a.rowHeight[l]=I,w=a.rowHeight[l]-w),a.height+=w,a.rows[l].push(d)},E.prototype.getShortestRowIndex=function(a){for(var d=-1,l=Number.MAX_VALUE,v=0;v<a.rows.length;v++)a.rowWidth[v]<l&&(d=v,l=a.rowWidth[v]);return d},E.prototype.getLongestRowIndex=function(a){for(var d=-1,l=Number.MIN_VALUE,v=0;v<a.rows.length;v++)a.rowWidth[v]>l&&(d=v,l=a.rowWidth[v]);return d},E.prototype.canAddHorizontal=function(a,d,l){var v=this.getShortestRowIndex(a);if(v<0)return!0;var _=a.rowWidth[v];if(_+a.horizontalPadding+d<=a.width)return!0;var D=0;a.rowHeight[v]<l&&v>0&&(D=l+a.verticalPadding-a.rowHeight[v]);var I=a.width-_>=d+a.horizontalPadding?(a.height+D)/(_+d+a.horizontalPadding):(a.height+D)/a.width;D=l+a.verticalPadding;var w=a.width<d?(a.height+D)/d:(a.height+D)/a.width;return w<1&&(w=1/w),I<1&&(I=1/I),I<w},E.prototype.shiftToLastRow=function(a){var d=this.getLongestRowIndex(a),l=a.rowWidth.length-1,v=a.rows[d],_=v[v.length-1],D=_.width+a.horizontalPadding;if(a.width-a.rowWidth[l]>D&&d!=l){v.splice(-1,1),a.rows[l].push(_),a.rowWidth[d]=a.rowWidth[d]-D,a.rowWidth[l]=a.rowWidth[l]+D,a.width=a.rowWidth[instance.getLongestRowIndex(a)];for(var I=Number.MIN_VALUE,w=0;w<v.length;w++)v[w].height>I&&(I=v[w].height);d>0&&(I+=a.verticalPadding);var R=a.rowHeight[d]+a.rowHeight[l];a.rowHeight[d]=I,a.rowHeight[l]<_.height+a.verticalPadding&&(a.rowHeight[l]=_.height+a.verticalPadding);var G=a.rowHeight[d]+a.rowHeight[l];a.height+=G-R,this.shiftToLastRow(a)}},E.prototype.tilingPreLayout=function(){o.TILE&&(this.groupZeroDegreeMembers(),this.clearCompounds(),this.clearZeroDegreeMembers())},E.prototype.tilingPostLayout=function(){o.TILE&&(this.repopulateZeroDegreeMembers(),this.repopulateCompounds())},E.prototype.reduceTrees=function(){for(var a=[],d=!0,l;d;){var v=this.graphManager.getAllNodes(),_=[];d=!1;for(var D=0;D<v.length;D++)l=v[D],l.getEdges().length==1&&!l.getEdges()[0].isInterGraph&&l.getChild()==null&&(_.push([l,l.getEdges()[0],l.getOwner()]),d=!0);if(d==1){for(var I=[],w=0;w<_.length;w++)_[w][0].getEdges().length==1&&(I.push(_[w]),_[w][0].getOwner().remove(_[w][0]));a.push(I),this.graphManager.resetAllNodes(),this.graphManager.resetAllEdges()}}this.prunedNodesAll=a},E.prototype.growTree=function(a){for(var d=a[a.length-1],l,v=0;v<d.length;v++)l=d[v],this.findPlaceforPrunedNode(l),l[2].add(l[0]),l[2].add(l[1],l[1].source,l[1].target);a.splice(a.length-1,1),this.graphManager.resetAllNodes(),this.graphManager.resetAllEdges()},E.prototype.findPlaceforPrunedNode=function(a){var d,l,v=a[0];l=v==a[1].source?a[1].target:a[1].source;var _=l.startX,D=l.finishX,I=l.startY,w=l.finishY,R=[0,0,0,0];if(I>0)for(var G=_;G<=D;G++)R[0]+=this.grid[G][I-1].length+this.grid[G][I].length-1;if(D<this.grid.length-1)for(var G=I;G<=w;G++)R[1]+=this.grid[D+1][G].length+this.grid[D][G].length-1;if(w<this.grid[0].length-1)for(var G=_;G<=D;G++)R[2]+=this.grid[G][w+1].length+this.grid[G][w].length-1;if(_>0)for(var G=I;G<=w;G++)R[3]+=this.grid[_-1][G].length+this.grid[_][G].length-1;for(var x=y.MAX_VALUE,M,U,b=0;b<R.length;b++)R[b]<x?(x=R[b],M=1,U=b):R[b]==x&&M++;if(M==3&&x==0)R[0]==0&&R[1]==0&&R[2]==0?d=1:R[0]==0&&R[1]==0&&R[3]==0?d=0:R[0]==0&&R[2]==0&&R[3]==0?d=3:R[1]==0&&R[2]==0&&R[3]==0&&(d=2);else if(M==2&&x==0){var F=Math.floor(Math.random()*2);d=R[0]==0&&R[1]==0?F==0?0:1:R[0]==0&&R[2]==0?F==0?0:2:R[0]==0&&R[3]==0?F==0?0:3:R[1]==0&&R[2]==0?F==0?1:2:R[1]==0&&R[3]==0?F==0?1:3:F==0?2:3}else if(M==4&&x==0){var F=Math.floor(Math.random()*4);d=F}else d=U;d==0?v.setCenter(l.getCenterX(),l.getCenterY()-l.getHeight()/2-N.DEFAULT_EDGE_LENGTH-v.getHeight()/2):d==1?v.setCenter(l.getCenterX()+l.getWidth()/2+N.DEFAULT_EDGE_LENGTH+v.getWidth()/2,l.getCenterY()):d==2?v.setCenter(l.getCenterX(),l.getCenterY()+l.getHeight()/2+N.DEFAULT_EDGE_LENGTH+v.getHeight()/2):v.setCenter(l.getCenterX()-l.getWidth()/2-N.DEFAULT_EDGE_LENGTH-v.getWidth()/2,l.getCenterY())},L.exports=E}),(function(L,A,n){var i={};i.layoutBase=n(0),i.CoSEConstants=n(1),i.CoSEEdge=n(2),i.CoSEGraph=n(3),i.CoSEGraphManager=n(4),i.CoSELayout=n(6),i.CoSENode=n(5),L.exports=i})])})})),at=nt(V(((C,P)=>{(function(m,L){typeof C=="object"&&typeof P=="object"?P.exports=L(Q()):typeof define=="function"&&define.amd?define(["cose-base"],L):typeof C=="object"?C.cytoscapeCoseBilkent=L(Q()):m.cytoscapeCoseBilkent=L(m.coseBase)})(C,function(m){return(function(L){var A={};function n(i){if(A[i])return A[i].exports;var t=A[i]={i,l:!1,exports:{}};return L[i].call(t.exports,t,t.exports,n),t.l=!0,t.exports}return n.m=L,n.c=A,n.i=function(i){return i},n.d=function(i,t,e){n.o(i,t)||Object.defineProperty(i,t,{configurable:!1,enumerable:!0,get:e})},n.n=function(i){var t=i&&i.__esModule?function(){return i.default}:function(){return i};return n.d(t,"a",t),t},n.o=function(i,t){return Object.prototype.hasOwnProperty.call(i,t)},n.p="",n(n.s=1)})([(function(L,A){L.exports=m}),(function(L,A,n){var i=n(0).layoutBase.LayoutConstants,t=n(0).layoutBase.FDLayoutConstants,e=n(0).CoSEConstants,r=n(0).CoSELayout,h=n(0).CoSENode,o=n(0).layoutBase.PointD,N=n(0).layoutBase.DimensionD,s={ready:function(){},stop:function(){},quality:"default",nodeDimensionsIncludeLabels:!1,refresh:30,fit:!0,padding:10,randomize:!0,nodeRepulsion:4500,idealEdgeLength:50,edgeElasticity:.45,nestingFactor:.1,gravity:.25,numIter:2500,tile:!0,animate:"end",animationDuration:500,tilingPaddingVertical:10,tilingPaddingHorizontal:10,gravityRangeCompound:1.5,gravityCompound:1,gravityRange:3.8,initialEnergyOnIncremental:.5};function g(c,f){var T={};for(var E in c)T[E]=c[E];for(var E in f)T[E]=f[E];return T}function u(c){this.options=g(s,c),p(this.options)}var p=function(c){c.nodeRepulsion!=null&&(e.DEFAULT_REPULSION_STRENGTH=t.DEFAULT_REPULSION_STRENGTH=c.nodeRepulsion),c.idealEdgeLength!=null&&(e.DEFAULT_EDGE_LENGTH=t.DEFAULT_EDGE_LENGTH=c.idealEdgeLength),c.edgeElasticity!=null&&(e.DEFAULT_SPRING_STRENGTH=t.DEFAULT_SPRING_STRENGTH=c.edgeElasticity),c.nestingFactor!=null&&(e.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=t.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=c.nestingFactor),c.gravity!=null&&(e.DEFAULT_GRAVITY_STRENGTH=t.DEFAULT_GRAVITY_STRENGTH=c.gravity),c.numIter!=null&&(e.MAX_ITERATIONS=t.MAX_ITERATIONS=c.numIter),c.gravityRange!=null&&(e.DEFAULT_GRAVITY_RANGE_FACTOR=t.DEFAULT_GRAVITY_RANGE_FACTOR=c.gravityRange),c.gravityCompound!=null&&(e.DEFAULT_COMPOUND_GRAVITY_STRENGTH=t.DEFAULT_COMPOUND_GRAVITY_STRENGTH=c.gravityCompound),c.gravityRangeCompound!=null&&(e.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=t.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=c.gravityRangeCompound),c.initialEnergyOnIncremental!=null&&(e.DEFAULT_COOLING_FACTOR_INCREMENTAL=t.DEFAULT_COOLING_FACTOR_INCREMENTAL=c.initialEnergyOnIncremental),c.quality=="draft"?i.QUALITY=0:c.quality=="proof"?i.QUALITY=2:i.QUALITY=1,e.NODE_DIMENSIONS_INCLUDE_LABELS=t.NODE_DIMENSIONS_INCLUDE_LABELS=i.NODE_DIMENSIONS_INCLUDE_LABELS=c.nodeDimensionsIncludeLabels,e.DEFAULT_INCREMENTAL=t.DEFAULT_INCREMENTAL=i.DEFAULT_INCREMENTAL=!c.randomize,e.ANIMATE=t.ANIMATE=i.ANIMATE=c.animate,e.TILE=c.tile,e.TILING_PADDING_VERTICAL=typeof c.tilingPaddingVertical=="function"?c.tilingPaddingVertical.call():c.tilingPaddingVertical,e.TILING_PADDING_HORIZONTAL=typeof c.tilingPaddingHorizontal=="function"?c.tilingPaddingHorizontal.call():c.tilingPaddingHorizontal};u.prototype.run=function(){var c,f,T=this.options;this.idToLNode={};var E=this.layout=new r,O=this;O.stopped=!1,this.cy=this.options.cy,this.cy.trigger({type:"layoutstart",layout:this});var a=E.newGraphManager();this.gm=a;var d=this.options.eles.nodes(),l=this.options.eles.edges();this.root=a.addRoot(),this.processChildrenList(this.root,this.getTopMostNodes(d),E);for(var v=0;v<l.length;v++){var _=l[v],D=this.idToLNode[_.data("source")],I=this.idToLNode[_.data("target")];if(D!==I&&D.getEdgesBetween(I).length==0){var w=a.add(E.newEdge(),D,I);w.id=_.id()}}var R=function(x,M){typeof x=="number"&&(x=M);var U=x.data("id"),b=O.idToLNode[U];return{x:b.getRect().getCenterX(),y:b.getRect().getCenterY()}},G=function x(){for(var M=function(){T.fit&&T.cy.fit(T.eles,T.padding),c||(c=!0,O.cy.one("layoutready",T.ready),O.cy.trigger({type:"layoutready",layout:O}))},U=O.options.refresh,b,F=0;F<U&&!b;F++)b=O.stopped||O.layout.tick();if(b){E.checkLayoutSuccess()&&!E.isSubLayout&&E.doPostLayout(),E.tilingPostLayout&&E.tilingPostLayout(),E.isLayoutFinished=!0,O.options.eles.nodes().positions(R),M(),O.cy.one("layoutstop",O.options.stop),O.cy.trigger({type:"layoutstop",layout:O}),f&&cancelAnimationFrame(f),c=!1;return}var S=O.layout.getPositionsData();T.eles.nodes().positions(function(Y,X){if(typeof Y=="number"&&(Y=X),!Y.isParent()){for(var W=Y.id(),B=S[W],H=Y;B==null&&(B=S[H.data("parent")]||S["DummyCompound_"+H.data("parent")],S[W]=B,H=H.parent()[0],H!=null););return B==null?{x:Y.position("x"),y:Y.position("y")}:{x:B.x,y:B.y}}}),M(),f=requestAnimationFrame(x)};return E.addListener("layoutstarted",function(){O.options.animate==="during"&&(f=requestAnimationFrame(G))}),E.runLayout(),this.options.animate!=="during"&&(O.options.eles.nodes().not(":parent").layoutPositions(O,O.options,R),c=!1),this},u.prototype.getTopMostNodes=function(c){for(var f={},T=0;T<c.length;T++)f[c[T].id()]=!0;return c.filter(function(E,O){typeof E=="number"&&(E=O);for(var a=E.parent()[0];a!=null;){if(f[a.id()])return!1;a=a.parent()[0]}return!0})},u.prototype.processChildrenList=function(c,f,T){for(var E=f.length,O=0;O<E;O++){var a=f[O],d=a.children(),l,v=a.layoutDimensions({nodeDimensionsIncludeLabels:this.options.nodeDimensionsIncludeLabels});if(l=a.outerWidth()!=null&&a.outerHeight()!=null?c.add(new h(T.graphManager,new o(a.position("x")-v.w/2,a.position("y")-v.h/2),new N(parseFloat(v.w),parseFloat(v.h)))):c.add(new h(this.graphManager)),l.id=a.data("id"),l.paddingLeft=parseInt(a.css("padding")),l.paddingTop=parseInt(a.css("padding")),l.paddingRight=parseInt(a.css("padding")),l.paddingBottom=parseInt(a.css("padding")),this.options.nodeDimensionsIncludeLabels&&a.isParent()){var _=a.boundingBox({includeLabels:!0,includeNodes:!1}).w,D=a.boundingBox({includeLabels:!0,includeNodes:!1}).h,I=a.css("text-halign");l.labelWidth=_,l.labelHeight=D,l.labelPos=I}if(this.idToLNode[a.data("id")]=l,isNaN(l.rect.x)&&(l.rect.x=0),isNaN(l.rect.y)&&(l.rect.y=0),d!=null&&d.length>0){var w=T.getGraphManager().add(T.newGraph(),l);this.processChildrenList(w,d,T)}}},u.prototype.stop=function(){return this.stopped=!0,this};var y=function(c){c("layout","cose-bilkent",u)};typeof cytoscape<"u"&&y(cytoscape),L.exports=y})])})}))(),1);z.use(at.default);function $(C,P){C.forEach(m=>{let L={id:m.id,labelText:m.label,height:m.height,width:m.width,padding:m.padding??0};Object.keys(m).forEach(A=>{["id","label","height","width","padding","x","y"].includes(A)||(L[A]=m[A])}),P.add({group:"nodes",data:L,position:{x:m.x??0,y:m.y??0}})})}k($,"addNodes");function K(C,P){C.forEach(m=>{let L={id:m.id,source:m.start,target:m.end};Object.keys(m).forEach(A=>{["id","start","end"].includes(A)||(L[A]=m[A])}),P.add({group:"edges",data:L})})}k(K,"addEdges");function J(C){return new Promise(P=>{let m=st("body").append("div").attr("id","cy").attr("style","display:none"),L=z({container:document.getElementById("cy"),style:[{selector:"edge",style:{"curve-style":"bezier"}}]});m.remove(),$(C.nodes,L),K(C.edges,L),L.nodes().forEach(function(A){A.layoutDimensions=()=>{let n=A.data();return{w:n.width,h:n.height}}}),L.layout({name:"cose-bilkent",quality:"proof",styleEnabled:!1,animate:!1}).run(),L.ready(A=>{j.info("Cytoscape ready",A),P(L)})})}k(J,"createCytoscapeInstance");function tt(C){return C.nodes().map(P=>{let m=P.data(),L=P.position(),A={id:m.id,x:L.x,y:L.y};return Object.keys(m).forEach(n=>{n!=="id"&&(A[n]=m[n])}),A})}k(tt,"extractPositionedNodes");function et(C){return C.edges().map(P=>{let m=P.data(),L=P._private.rscratch,A={id:m.id,source:m.source,target:m.target,startX:L.startX,startY:L.startY,midX:L.midX,midY:L.midY,endX:L.endX,endY:L.endY};return Object.keys(m).forEach(n=>{["id","source","target"].includes(n)||(A[n]=m[n])}),A})}k(et,"extractPositionedEdges");async function it(C,P){j.debug("Starting cose-bilkent layout algorithm");try{rt(C);let m=await J(C),L=tt(m),A=et(m);return j.debug(`Layout completed: ${L.length} nodes, ${A.length} edges`),{nodes:L,edges:A}}catch(m){throw j.error("Error in cose-bilkent layout algorithm:",m),m}}k(it,"executeCoseBilkentLayout");function rt(C){if(!C)throw Error("Layout data is required");if(!C.config)throw Error("Configuration is required in layout data");if(!C.rootNode)throw Error("Root node is required");if(!C.nodes||!Array.isArray(C.nodes))throw Error("No nodes found in layout data");if(!Array.isArray(C.edges))throw Error("Edges array is required in layout data");return!0}k(rt,"validateLayoutData");var ht=k(async(C,P,{insertCluster:m,insertEdge:L,insertEdgeLabel:A,insertMarkers:n,insertNode:i,log:t,positionEdgeLabel:e},{algorithm:r})=>{let h={},o={},N=P.select("g");n(N,C.markers,C.type,C.diagramId);let s=N.insert("g").attr("class","subgraphs"),g=N.insert("g").attr("class","edgePaths"),u=N.insert("g").attr("class","edgeLabels"),p=N.insert("g").attr("class","nodes");t.debug("Inserting nodes into DOM for dimension calculation"),await Promise.all(C.nodes.map(async c=>{if(c.isGroup){let f={...c};o[c.id]=f,h[c.id]=f,await m(s,c)}else{let f={...c};h[c.id]=f;let T=await i(p,c,{config:C.config,dir:C.direction||"TB"}),E=T.node().getBBox();f.width=E.width,f.height=E.height,f.domId=T,t.debug(`Node ${c.id} dimensions: ${E.width}x${E.height}`)}})),t.debug("Running cose-bilkent layout algorithm");let y=await it({...C,nodes:C.nodes.map(c=>{let f=h[c.id];return{...c,width:f.width,height:f.height}})},C.config);t.debug("Positioning nodes based on layout results"),y.nodes.forEach(c=>{let f=h[c.id];f!=null&&f.domId&&(f.domId.attr("transform",`translate(${c.x}, ${c.y})`),f.x=c.x,f.y=c.y,t.debug(`Positioned node ${f.id} at center (${c.x}, ${c.y})`))}),y.edges.forEach(c=>{let f=C.edges.find(T=>T.id===c.id);f&&(f.points=[{x:c.startX,y:c.startY},{x:c.midX,y:c.midY},{x:c.endX,y:c.endY}])}),t.debug("Inserting and positioning edges"),await Promise.all(C.edges.map(async c=>{await A(u,c);let f=h[c.start??""],T=h[c.end??""];if(f&&T){let E=y.edges.find(O=>O.id===c.id);if(E){t.debug("APA01 positionedEdge",E);let O={...c};e(O,L(g,O,o,C.type,f,T,C.diagramId))}else{let O={...c,points:[{x:f.x||0,y:f.y||0},{x:T.x||0,y:T.y||0}]};e(O,L(g,O,o,C.type,f,T,C.diagramId))}}})),t.debug("Cose-bilkent rendering completed")},"render");export{ht as render};
1
+ import{s as nt,t as V}from"./chunk-LvLJmgfZ.js";import{u as st}from"./src-DJ8ZKoFs.js";import{n as k,r as j}from"./src-CmKhyEBC.js";import{t as z}from"./cytoscape.esm-BihqZ2_-.js";var Z=V(((C,P)=>{(function(m,L){typeof C=="object"&&typeof P=="object"?P.exports=L():typeof define=="function"&&define.amd?define([],L):typeof C=="object"?C.layoutBase=L():m.layoutBase=L()})(C,function(){return(function(m){var L={};function A(n){if(L[n])return L[n].exports;var i=L[n]={i:n,l:!1,exports:{}};return m[n].call(i.exports,i,i.exports,A),i.l=!0,i.exports}return A.m=m,A.c=L,A.i=function(n){return n},A.d=function(n,i,t){A.o(n,i)||Object.defineProperty(n,i,{configurable:!1,enumerable:!0,get:t})},A.n=function(n){var i=n&&n.__esModule?function(){return n.default}:function(){return n};return A.d(i,"a",i),i},A.o=function(n,i){return Object.prototype.hasOwnProperty.call(n,i)},A.p="",A(A.s=26)})([(function(m,L,A){function n(){}n.QUALITY=1,n.DEFAULT_CREATE_BENDS_AS_NEEDED=!1,n.DEFAULT_INCREMENTAL=!1,n.DEFAULT_ANIMATION_ON_LAYOUT=!0,n.DEFAULT_ANIMATION_DURING_LAYOUT=!1,n.DEFAULT_ANIMATION_PERIOD=50,n.DEFAULT_UNIFORM_LEAF_NODE_SIZES=!1,n.DEFAULT_GRAPH_MARGIN=15,n.NODE_DIMENSIONS_INCLUDE_LABELS=!1,n.SIMPLE_NODE_SIZE=40,n.SIMPLE_NODE_HALF_SIZE=n.SIMPLE_NODE_SIZE/2,n.EMPTY_COMPOUND_NODE_SIZE=40,n.MIN_EDGE_LENGTH=1,n.WORLD_BOUNDARY=1e6,n.INITIAL_WORLD_BOUNDARY=n.WORLD_BOUNDARY/1e3,n.WORLD_CENTER_X=1200,n.WORLD_CENTER_Y=900,m.exports=n}),(function(m,L,A){var n=A(2),i=A(8),t=A(9);function e(h,o,N){n.call(this,N),this.isOverlapingSourceAndTarget=!1,this.vGraphObject=N,this.bendpoints=[],this.source=h,this.target=o}for(var r in e.prototype=Object.create(n.prototype),n)e[r]=n[r];e.prototype.getSource=function(){return this.source},e.prototype.getTarget=function(){return this.target},e.prototype.isInterGraph=function(){return this.isInterGraph},e.prototype.getLength=function(){return this.length},e.prototype.isOverlapingSourceAndTarget=function(){return this.isOverlapingSourceAndTarget},e.prototype.getBendpoints=function(){return this.bendpoints},e.prototype.getLca=function(){return this.lca},e.prototype.getSourceInLca=function(){return this.sourceInLca},e.prototype.getTargetInLca=function(){return this.targetInLca},e.prototype.getOtherEnd=function(h){if(this.source===h)return this.target;if(this.target===h)return this.source;throw"Node is not incident with this edge"},e.prototype.getOtherEndInGraph=function(h,o){for(var N=this.getOtherEnd(h),s=o.getGraphManager().getRoot();;){if(N.getOwner()==o)return N;if(N.getOwner()==s)break;N=N.getOwner().getParent()}return null},e.prototype.updateLength=function(){var h=[,,,,];this.isOverlapingSourceAndTarget=i.getIntersection(this.target.getRect(),this.source.getRect(),h),this.isOverlapingSourceAndTarget||(this.lengthX=h[0]-h[2],this.lengthY=h[1]-h[3],Math.abs(this.lengthX)<1&&(this.lengthX=t.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=t.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY))},e.prototype.updateLengthSimple=function(){this.lengthX=this.target.getCenterX()-this.source.getCenterX(),this.lengthY=this.target.getCenterY()-this.source.getCenterY(),Math.abs(this.lengthX)<1&&(this.lengthX=t.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=t.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)},m.exports=e}),(function(m,L,A){function n(i){this.vGraphObject=i}m.exports=n}),(function(m,L,A){var n=A(2),i=A(10),t=A(13),e=A(0),r=A(16),h=A(4);function o(s,g,u,p){u==null&&p==null&&(p=g),n.call(this,p),s.graphManager!=null&&(s=s.graphManager),this.estimatedSize=i.MIN_VALUE,this.inclusionTreeDepth=i.MAX_VALUE,this.vGraphObject=p,this.edges=[],this.graphManager=s,u!=null&&g!=null?this.rect=new t(g.x,g.y,u.width,u.height):this.rect=new t}for(var N in o.prototype=Object.create(n.prototype),n)o[N]=n[N];o.prototype.getEdges=function(){return this.edges},o.prototype.getChild=function(){return this.child},o.prototype.getOwner=function(){return this.owner},o.prototype.getWidth=function(){return this.rect.width},o.prototype.setWidth=function(s){this.rect.width=s},o.prototype.getHeight=function(){return this.rect.height},o.prototype.setHeight=function(s){this.rect.height=s},o.prototype.getCenterX=function(){return this.rect.x+this.rect.width/2},o.prototype.getCenterY=function(){return this.rect.y+this.rect.height/2},o.prototype.getCenter=function(){return new h(this.rect.x+this.rect.width/2,this.rect.y+this.rect.height/2)},o.prototype.getLocation=function(){return new h(this.rect.x,this.rect.y)},o.prototype.getRect=function(){return this.rect},o.prototype.getDiagonal=function(){return Math.sqrt(this.rect.width*this.rect.width+this.rect.height*this.rect.height)},o.prototype.getHalfTheDiagonal=function(){return Math.sqrt(this.rect.height*this.rect.height+this.rect.width*this.rect.width)/2},o.prototype.setRect=function(s,g){this.rect.x=s.x,this.rect.y=s.y,this.rect.width=g.width,this.rect.height=g.height},o.prototype.setCenter=function(s,g){this.rect.x=s-this.rect.width/2,this.rect.y=g-this.rect.height/2},o.prototype.setLocation=function(s,g){this.rect.x=s,this.rect.y=g},o.prototype.moveBy=function(s,g){this.rect.x+=s,this.rect.y+=g},o.prototype.getEdgeListToNode=function(s){var g=[],u=this;return u.edges.forEach(function(p){if(p.target==s){if(p.source!=u)throw"Incorrect edge source!";g.push(p)}}),g},o.prototype.getEdgesBetween=function(s){var g=[],u=this;return u.edges.forEach(function(p){if(!(p.source==u||p.target==u))throw"Incorrect edge source and/or target";(p.target==s||p.source==s)&&g.push(p)}),g},o.prototype.getNeighborsList=function(){var s=new Set,g=this;return g.edges.forEach(function(u){if(u.source==g)s.add(u.target);else{if(u.target!=g)throw"Incorrect incidency!";s.add(u.source)}}),s},o.prototype.withChildren=function(){var s=new Set,g,u;if(s.add(this),this.child!=null)for(var p=this.child.getNodes(),y=0;y<p.length;y++)g=p[y],u=g.withChildren(),u.forEach(function(c){s.add(c)});return s},o.prototype.getNoOfChildren=function(){var s=0,g;if(this.child==null)s=1;else for(var u=this.child.getNodes(),p=0;p<u.length;p++)g=u[p],s+=g.getNoOfChildren();return s==0&&(s=1),s},o.prototype.getEstimatedSize=function(){if(this.estimatedSize==i.MIN_VALUE)throw"assert failed";return this.estimatedSize},o.prototype.calcEstimatedSize=function(){return this.child==null?this.estimatedSize=(this.rect.width+this.rect.height)/2:(this.estimatedSize=this.child.calcEstimatedSize(),this.rect.width=this.estimatedSize,this.rect.height=this.estimatedSize,this.estimatedSize)},o.prototype.scatter=function(){var s,g,u=-e.INITIAL_WORLD_BOUNDARY,p=e.INITIAL_WORLD_BOUNDARY;s=e.WORLD_CENTER_X+r.nextDouble()*(p-u)+u;var y=-e.INITIAL_WORLD_BOUNDARY,c=e.INITIAL_WORLD_BOUNDARY;g=e.WORLD_CENTER_Y+r.nextDouble()*(c-y)+y,this.rect.x=s,this.rect.y=g},o.prototype.updateBounds=function(){if(this.getChild()==null)throw"assert failed";if(this.getChild().getNodes().length!=0){var s=this.getChild();if(s.updateBounds(!0),this.rect.x=s.getLeft(),this.rect.y=s.getTop(),this.setWidth(s.getRight()-s.getLeft()),this.setHeight(s.getBottom()-s.getTop()),e.NODE_DIMENSIONS_INCLUDE_LABELS){var g=s.getRight()-s.getLeft(),u=s.getBottom()-s.getTop();this.labelWidth>g&&(this.rect.x-=(this.labelWidth-g)/2,this.setWidth(this.labelWidth)),this.labelHeight>u&&(this.labelPos=="center"?this.rect.y-=(this.labelHeight-u)/2:this.labelPos=="top"&&(this.rect.y-=this.labelHeight-u),this.setHeight(this.labelHeight))}}},o.prototype.getInclusionTreeDepth=function(){if(this.inclusionTreeDepth==i.MAX_VALUE)throw"assert failed";return this.inclusionTreeDepth},o.prototype.transform=function(s){var g=this.rect.x;g>e.WORLD_BOUNDARY?g=e.WORLD_BOUNDARY:g<-e.WORLD_BOUNDARY&&(g=-e.WORLD_BOUNDARY);var u=this.rect.y;u>e.WORLD_BOUNDARY?u=e.WORLD_BOUNDARY:u<-e.WORLD_BOUNDARY&&(u=-e.WORLD_BOUNDARY);var p=new h(g,u),y=s.inverseTransformPoint(p);this.setLocation(y.x,y.y)},o.prototype.getLeft=function(){return this.rect.x},o.prototype.getRight=function(){return this.rect.x+this.rect.width},o.prototype.getTop=function(){return this.rect.y},o.prototype.getBottom=function(){return this.rect.y+this.rect.height},o.prototype.getParent=function(){return this.owner==null?null:this.owner.getParent()},m.exports=o}),(function(m,L,A){function n(i,t){i==null&&t==null?(this.x=0,this.y=0):(this.x=i,this.y=t)}n.prototype.getX=function(){return this.x},n.prototype.getY=function(){return this.y},n.prototype.setX=function(i){this.x=i},n.prototype.setY=function(i){this.y=i},n.prototype.getDifference=function(i){return new DimensionD(this.x-i.x,this.y-i.y)},n.prototype.getCopy=function(){return new n(this.x,this.y)},n.prototype.translate=function(i){return this.x+=i.width,this.y+=i.height,this},m.exports=n}),(function(m,L,A){var n=A(2),i=A(10),t=A(0),e=A(6),r=A(3),h=A(1),o=A(13),N=A(12),s=A(11);function g(p,y,c){n.call(this,c),this.estimatedSize=i.MIN_VALUE,this.margin=t.DEFAULT_GRAPH_MARGIN,this.edges=[],this.nodes=[],this.isConnected=!1,this.parent=p,y!=null&&y instanceof e?this.graphManager=y:y!=null&&y instanceof Layout&&(this.graphManager=y.graphManager)}for(var u in g.prototype=Object.create(n.prototype),n)g[u]=n[u];g.prototype.getNodes=function(){return this.nodes},g.prototype.getEdges=function(){return this.edges},g.prototype.getGraphManager=function(){return this.graphManager},g.prototype.getParent=function(){return this.parent},g.prototype.getLeft=function(){return this.left},g.prototype.getRight=function(){return this.right},g.prototype.getTop=function(){return this.top},g.prototype.getBottom=function(){return this.bottom},g.prototype.isConnected=function(){return this.isConnected},g.prototype.add=function(p,y,c){if(y==null&&c==null){var f=p;if(this.graphManager==null)throw"Graph has no graph mgr!";if(this.getNodes().indexOf(f)>-1)throw"Node already in graph!";return f.owner=this,this.getNodes().push(f),f}else{var T=p;if(!(this.getNodes().indexOf(y)>-1&&this.getNodes().indexOf(c)>-1))throw"Source or target not in graph!";if(!(y.owner==c.owner&&y.owner==this))throw"Both owners must be this graph!";return y.owner==c.owner?(T.source=y,T.target=c,T.isInterGraph=!1,this.getEdges().push(T),y.edges.push(T),c!=y&&c.edges.push(T),T):null}},g.prototype.remove=function(p){var y=p;if(p instanceof r){if(y==null)throw"Node is null!";if(!(y.owner!=null&&y.owner==this))throw"Owner graph is invalid!";if(this.graphManager==null)throw"Owner graph manager is invalid!";for(var c=y.edges.slice(),f,T=c.length,E=0;E<T;E++)f=c[E],f.isInterGraph?this.graphManager.remove(f):f.source.owner.remove(f);var O=this.nodes.indexOf(y);if(O==-1)throw"Node not in owner node list!";this.nodes.splice(O,1)}else if(p instanceof h){var f=p;if(f==null)throw"Edge is null!";if(!(f.source!=null&&f.target!=null))throw"Source and/or target is null!";if(!(f.source.owner!=null&&f.target.owner!=null&&f.source.owner==this&&f.target.owner==this))throw"Source and/or target owner is invalid!";var a=f.source.edges.indexOf(f),d=f.target.edges.indexOf(f);if(!(a>-1&&d>-1))throw"Source and/or target doesn't know this edge!";f.source.edges.splice(a,1),f.target!=f.source&&f.target.edges.splice(d,1);var O=f.source.owner.getEdges().indexOf(f);if(O==-1)throw"Not in owner's edge list!";f.source.owner.getEdges().splice(O,1)}},g.prototype.updateLeftTop=function(){for(var p=i.MAX_VALUE,y=i.MAX_VALUE,c,f,T,E=this.getNodes(),O=E.length,a=0;a<O;a++){var d=E[a];c=d.getTop(),f=d.getLeft(),p>c&&(p=c),y>f&&(y=f)}return p==i.MAX_VALUE?null:(T=E[0].getParent().paddingLeft==null?this.margin:E[0].getParent().paddingLeft,this.left=y-T,this.top=p-T,new N(this.left,this.top))},g.prototype.updateBounds=function(p){for(var y=i.MAX_VALUE,c=-i.MAX_VALUE,f=i.MAX_VALUE,T=-i.MAX_VALUE,E,O,a,d,l,v=this.nodes,_=v.length,D=0;D<_;D++){var I=v[D];p&&I.child!=null&&I.updateBounds(),E=I.getLeft(),O=I.getRight(),a=I.getTop(),d=I.getBottom(),y>E&&(y=E),c<O&&(c=O),f>a&&(f=a),T<d&&(T=d)}var w=new o(y,f,c-y,T-f);y==i.MAX_VALUE&&(this.left=this.parent.getLeft(),this.right=this.parent.getRight(),this.top=this.parent.getTop(),this.bottom=this.parent.getBottom()),l=v[0].getParent().paddingLeft==null?this.margin:v[0].getParent().paddingLeft,this.left=w.x-l,this.right=w.x+w.width+l,this.top=w.y-l,this.bottom=w.y+w.height+l},g.calculateBounds=function(p){for(var y=i.MAX_VALUE,c=-i.MAX_VALUE,f=i.MAX_VALUE,T=-i.MAX_VALUE,E,O,a,d,l=p.length,v=0;v<l;v++){var _=p[v];E=_.getLeft(),O=_.getRight(),a=_.getTop(),d=_.getBottom(),y>E&&(y=E),c<O&&(c=O),f>a&&(f=a),T<d&&(T=d)}return new o(y,f,c-y,T-f)},g.prototype.getInclusionTreeDepth=function(){return this==this.graphManager.getRoot()?1:this.parent.getInclusionTreeDepth()},g.prototype.getEstimatedSize=function(){if(this.estimatedSize==i.MIN_VALUE)throw"assert failed";return this.estimatedSize},g.prototype.calcEstimatedSize=function(){for(var p=0,y=this.nodes,c=y.length,f=0;f<c;f++){var T=y[f];p+=T.calcEstimatedSize()}return p==0?this.estimatedSize=t.EMPTY_COMPOUND_NODE_SIZE:this.estimatedSize=p/Math.sqrt(this.nodes.length),this.estimatedSize},g.prototype.updateConnected=function(){var p=this;if(this.nodes.length==0){this.isConnected=!0;return}var y=new s,c=new Set,f=this.nodes[0],T,E;for(f.withChildren().forEach(function(l){y.push(l),c.add(l)});y.length!==0;){f=y.shift(),T=f.getEdges();for(var O=T.length,a=0;a<O;a++)E=T[a].getOtherEndInGraph(f,this),E!=null&&!c.has(E)&&E.withChildren().forEach(function(l){y.push(l),c.add(l)})}if(this.isConnected=!1,c.size>=this.nodes.length){var d=0;c.forEach(function(l){l.owner==p&&d++}),d==this.nodes.length&&(this.isConnected=!0)}},m.exports=g}),(function(m,L,A){var n,i=A(1);function t(e){n=A(5),this.layout=e,this.graphs=[],this.edges=[]}t.prototype.addRoot=function(){var e=this.layout.newGraph(),r=this.layout.newNode(null),h=this.add(e,r);return this.setRootGraph(h),this.rootGraph},t.prototype.add=function(e,r,h,o,N){if(h==null&&o==null&&N==null){if(e==null)throw"Graph is null!";if(r==null)throw"Parent node is null!";if(this.graphs.indexOf(e)>-1)throw"Graph already in this graph mgr!";if(this.graphs.push(e),e.parent!=null)throw"Already has a parent!";if(r.child!=null)throw"Already has a child!";return e.parent=r,r.child=e,e}else{N=h,o=r,h=e;var s=o.getOwner(),g=N.getOwner();if(!(s!=null&&s.getGraphManager()==this))throw"Source not in this graph mgr!";if(!(g!=null&&g.getGraphManager()==this))throw"Target not in this graph mgr!";if(s==g)return h.isInterGraph=!1,s.add(h,o,N);if(h.isInterGraph=!0,h.source=o,h.target=N,this.edges.indexOf(h)>-1)throw"Edge already in inter-graph edge list!";if(this.edges.push(h),!(h.source!=null&&h.target!=null))throw"Edge source and/or target is null!";if(!(h.source.edges.indexOf(h)==-1&&h.target.edges.indexOf(h)==-1))throw"Edge already in source and/or target incidency list!";return h.source.edges.push(h),h.target.edges.push(h),h}},t.prototype.remove=function(e){if(e instanceof n){var r=e;if(r.getGraphManager()!=this)throw"Graph not in this graph mgr";if(!(r==this.rootGraph||r.parent!=null&&r.parent.graphManager==this))throw"Invalid parent node!";var h=[];h=h.concat(r.getEdges());for(var o,N=h.length,s=0;s<N;s++)o=h[s],r.remove(o);var g=[];g=g.concat(r.getNodes());var u;N=g.length;for(var s=0;s<N;s++)u=g[s],r.remove(u);r==this.rootGraph&&this.setRootGraph(null);var p=this.graphs.indexOf(r);this.graphs.splice(p,1),r.parent=null}else if(e instanceof i){if(o=e,o==null)throw"Edge is null!";if(!o.isInterGraph)throw"Not an inter-graph edge!";if(!(o.source!=null&&o.target!=null))throw"Source and/or target is null!";if(!(o.source.edges.indexOf(o)!=-1&&o.target.edges.indexOf(o)!=-1))throw"Source and/or target doesn't know this edge!";var p=o.source.edges.indexOf(o);if(o.source.edges.splice(p,1),p=o.target.edges.indexOf(o),o.target.edges.splice(p,1),!(o.source.owner!=null&&o.source.owner.getGraphManager()!=null))throw"Edge owner graph or owner graph manager is null!";if(o.source.owner.getGraphManager().edges.indexOf(o)==-1)throw"Not in owner graph manager's edge list!";var p=o.source.owner.getGraphManager().edges.indexOf(o);o.source.owner.getGraphManager().edges.splice(p,1)}},t.prototype.updateBounds=function(){this.rootGraph.updateBounds(!0)},t.prototype.getGraphs=function(){return this.graphs},t.prototype.getAllNodes=function(){if(this.allNodes==null){for(var e=[],r=this.getGraphs(),h=r.length,o=0;o<h;o++)e=e.concat(r[o].getNodes());this.allNodes=e}return this.allNodes},t.prototype.resetAllNodes=function(){this.allNodes=null},t.prototype.resetAllEdges=function(){this.allEdges=null},t.prototype.resetAllNodesToApplyGravitation=function(){this.allNodesToApplyGravitation=null},t.prototype.getAllEdges=function(){if(this.allEdges==null){var e=[],r=this.getGraphs();r.length;for(var h=0;h<r.length;h++)e=e.concat(r[h].getEdges());e=e.concat(this.edges),this.allEdges=e}return this.allEdges},t.prototype.getAllNodesToApplyGravitation=function(){return this.allNodesToApplyGravitation},t.prototype.setAllNodesToApplyGravitation=function(e){if(this.allNodesToApplyGravitation!=null)throw"assert failed";this.allNodesToApplyGravitation=e},t.prototype.getRoot=function(){return this.rootGraph},t.prototype.setRootGraph=function(e){if(e.getGraphManager()!=this)throw"Root not in this graph mgr!";this.rootGraph=e,e.parent??(e.parent=this.layout.newNode("Root node"))},t.prototype.getLayout=function(){return this.layout},t.prototype.isOneAncestorOfOther=function(e,r){if(!(e!=null&&r!=null))throw"assert failed";if(e==r)return!0;var h=e.getOwner(),o;do{if(o=h.getParent(),o==null)break;if(o==r)return!0;if(h=o.getOwner(),h==null)break}while(!0);h=r.getOwner();do{if(o=h.getParent(),o==null)break;if(o==e)return!0;if(h=o.getOwner(),h==null)break}while(!0);return!1},t.prototype.calcLowestCommonAncestors=function(){for(var e,r,h,o,N,s=this.getAllEdges(),g=s.length,u=0;u<g;u++){if(e=s[u],r=e.source,h=e.target,e.lca=null,e.sourceInLca=r,e.targetInLca=h,r==h){e.lca=r.getOwner();continue}for(o=r.getOwner();e.lca==null;){for(e.targetInLca=h,N=h.getOwner();e.lca==null;){if(N==o){e.lca=N;break}if(N==this.rootGraph)break;if(e.lca!=null)throw"assert failed";e.targetInLca=N.getParent(),N=e.targetInLca.getOwner()}if(o==this.rootGraph)break;e.lca??(e.sourceInLca=o.getParent(),o=e.sourceInLca.getOwner())}if(e.lca==null)throw"assert failed"}},t.prototype.calcLowestCommonAncestor=function(e,r){if(e==r)return e.getOwner();var h=e.getOwner();do{if(h==null)break;var o=r.getOwner();do{if(o==null)break;if(o==h)return o;o=o.getParent().getOwner()}while(!0);h=h.getParent().getOwner()}while(!0);return h},t.prototype.calcInclusionTreeDepths=function(e,r){e==null&&r==null&&(e=this.rootGraph,r=1);for(var h,o=e.getNodes(),N=o.length,s=0;s<N;s++)h=o[s],h.inclusionTreeDepth=r,h.child!=null&&this.calcInclusionTreeDepths(h.child,r+1)},t.prototype.includesInvalidEdge=function(){for(var e,r=this.edges.length,h=0;h<r;h++)if(e=this.edges[h],this.isOneAncestorOfOther(e.source,e.target))return!0;return!1},m.exports=t}),(function(m,L,A){var n=A(0);function i(){}for(var t in n)i[t]=n[t];i.MAX_ITERATIONS=2500,i.DEFAULT_EDGE_LENGTH=50,i.DEFAULT_SPRING_STRENGTH=.45,i.DEFAULT_REPULSION_STRENGTH=4500,i.DEFAULT_GRAVITY_STRENGTH=.4,i.DEFAULT_COMPOUND_GRAVITY_STRENGTH=1,i.DEFAULT_GRAVITY_RANGE_FACTOR=3.8,i.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=1.5,i.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION=!0,i.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION=!0,i.DEFAULT_COOLING_FACTOR_INCREMENTAL=.3,i.COOLING_ADAPTATION_FACTOR=.33,i.ADAPTATION_LOWER_NODE_LIMIT=1e3,i.ADAPTATION_UPPER_NODE_LIMIT=5e3,i.MAX_NODE_DISPLACEMENT_INCREMENTAL=100,i.MAX_NODE_DISPLACEMENT=i.MAX_NODE_DISPLACEMENT_INCREMENTAL*3,i.MIN_REPULSION_DIST=i.DEFAULT_EDGE_LENGTH/10,i.CONVERGENCE_CHECK_PERIOD=100,i.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=.1,i.MIN_EDGE_LENGTH=1,i.GRID_CALCULATION_CHECK_PERIOD=10,m.exports=i}),(function(m,L,A){var n=A(12);function i(){}i.calcSeparationAmount=function(t,e,r,h){if(!t.intersects(e))throw"assert failed";var o=[,,];this.decideDirectionsForOverlappingNodes(t,e,o),r[0]=Math.min(t.getRight(),e.getRight())-Math.max(t.x,e.x),r[1]=Math.min(t.getBottom(),e.getBottom())-Math.max(t.y,e.y),t.getX()<=e.getX()&&t.getRight()>=e.getRight()?r[0]+=Math.min(e.getX()-t.getX(),t.getRight()-e.getRight()):e.getX()<=t.getX()&&e.getRight()>=t.getRight()&&(r[0]+=Math.min(t.getX()-e.getX(),e.getRight()-t.getRight())),t.getY()<=e.getY()&&t.getBottom()>=e.getBottom()?r[1]+=Math.min(e.getY()-t.getY(),t.getBottom()-e.getBottom()):e.getY()<=t.getY()&&e.getBottom()>=t.getBottom()&&(r[1]+=Math.min(t.getY()-e.getY(),e.getBottom()-t.getBottom()));var N=Math.abs((e.getCenterY()-t.getCenterY())/(e.getCenterX()-t.getCenterX()));e.getCenterY()===t.getCenterY()&&e.getCenterX()===t.getCenterX()&&(N=1);var s=N*r[0],g=r[1]/N;r[0]<g?g=r[0]:s=r[1],r[0]=-1*o[0]*(g/2+h),r[1]=-1*o[1]*(s/2+h)},i.decideDirectionsForOverlappingNodes=function(t,e,r){t.getCenterX()<e.getCenterX()?r[0]=-1:r[0]=1,t.getCenterY()<e.getCenterY()?r[1]=-1:r[1]=1},i.getIntersection2=function(t,e,r){var h=t.getCenterX(),o=t.getCenterY(),N=e.getCenterX(),s=e.getCenterY();if(t.intersects(e))return r[0]=h,r[1]=o,r[2]=N,r[3]=s,!0;var g=t.getX(),u=t.getY(),p=t.getRight(),y=t.getX(),c=t.getBottom(),f=t.getRight(),T=t.getWidthHalf(),E=t.getHeightHalf(),O=e.getX(),a=e.getY(),d=e.getRight(),l=e.getX(),v=e.getBottom(),_=e.getRight(),D=e.getWidthHalf(),I=e.getHeightHalf(),w=!1,R=!1;if(h===N){if(o>s)return r[0]=h,r[1]=u,r[2]=N,r[3]=v,!1;if(o<s)return r[0]=h,r[1]=c,r[2]=N,r[3]=a,!1}else if(o===s){if(h>N)return r[0]=g,r[1]=o,r[2]=d,r[3]=s,!1;if(h<N)return r[0]=p,r[1]=o,r[2]=O,r[3]=s,!1}else{var G=t.height/t.width,x=e.height/e.width,M=(s-o)/(N-h),U=void 0,b=void 0,F=void 0,S=void 0,Y=void 0,X=void 0;if(-G===M?h>N?(r[0]=y,r[1]=c,w=!0):(r[0]=p,r[1]=u,w=!0):G===M&&(h>N?(r[0]=g,r[1]=u,w=!0):(r[0]=f,r[1]=c,w=!0)),-x===M?N>h?(r[2]=l,r[3]=v,R=!0):(r[2]=d,r[3]=a,R=!0):x===M&&(N>h?(r[2]=O,r[3]=a,R=!0):(r[2]=_,r[3]=v,R=!0)),w&&R)return!1;if(h>N?o>s?(U=this.getCardinalDirection(G,M,4),b=this.getCardinalDirection(x,M,2)):(U=this.getCardinalDirection(-G,M,3),b=this.getCardinalDirection(-x,M,1)):o>s?(U=this.getCardinalDirection(-G,M,1),b=this.getCardinalDirection(-x,M,3)):(U=this.getCardinalDirection(G,M,2),b=this.getCardinalDirection(x,M,4)),!w)switch(U){case 1:S=u,F=h+-E/M,r[0]=F,r[1]=S;break;case 2:F=f,S=o+T*M,r[0]=F,r[1]=S;break;case 3:S=c,F=h+E/M,r[0]=F,r[1]=S;break;case 4:F=y,S=o+-T*M,r[0]=F,r[1]=S;break}if(!R)switch(b){case 1:X=a,Y=N+-I/M,r[2]=Y,r[3]=X;break;case 2:Y=_,X=s+D*M,r[2]=Y,r[3]=X;break;case 3:X=v,Y=N+I/M,r[2]=Y,r[3]=X;break;case 4:Y=l,X=s+-D*M,r[2]=Y,r[3]=X;break}}return!1},i.getCardinalDirection=function(t,e,r){return t>e?r:1+r%4},i.getIntersection=function(t,e,r,h){if(h==null)return this.getIntersection2(t,e,r);var o=t.x,N=t.y,s=e.x,g=e.y,u=r.x,p=r.y,y=h.x,c=h.y,f=void 0,T=void 0,E=void 0,O=void 0,a=void 0,d=void 0,l=void 0,v=void 0,_=void 0;return E=g-N,a=o-s,l=s*N-o*g,O=c-p,d=u-y,v=y*p-u*c,_=E*d-O*a,_===0?null:(f=(a*v-d*l)/_,T=(O*l-E*v)/_,new n(f,T))},i.angleOfVector=function(t,e,r,h){var o=void 0;return t===r?o=h<e?this.ONE_AND_HALF_PI:this.HALF_PI:(o=Math.atan((h-e)/(r-t)),r<t?o+=Math.PI:h<e&&(o+=this.TWO_PI)),o},i.doIntersect=function(t,e,r,h){var o=t.x,N=t.y,s=e.x,g=e.y,u=r.x,p=r.y,y=h.x,c=h.y,f=(s-o)*(c-p)-(y-u)*(g-N);if(f===0)return!1;var T=((c-p)*(y-o)+(u-y)*(c-N))/f,E=((N-g)*(y-o)+(s-o)*(c-N))/f;return 0<T&&T<1&&0<E&&E<1},i.HALF_PI=.5*Math.PI,i.ONE_AND_HALF_PI=1.5*Math.PI,i.TWO_PI=2*Math.PI,i.THREE_PI=3*Math.PI,m.exports=i}),(function(m,L,A){function n(){}n.sign=function(i){return i>0?1:i<0?-1:0},n.floor=function(i){return i<0?Math.ceil(i):Math.floor(i)},n.ceil=function(i){return i<0?Math.floor(i):Math.ceil(i)},m.exports=n}),(function(m,L,A){function n(){}n.MAX_VALUE=2147483647,n.MIN_VALUE=-2147483648,m.exports=n}),(function(m,L,A){var n=(function(){function h(o,N){for(var s=0;s<N.length;s++){var g=N[s];g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g&&(g.writable=!0),Object.defineProperty(o,g.key,g)}}return function(o,N,s){return N&&h(o.prototype,N),s&&h(o,s),o}})();function i(h,o){if(!(h instanceof o))throw TypeError("Cannot call a class as a function")}var t=function(h){return{value:h,next:null,prev:null}},e=function(h,o,N,s){return h===null?s.head=o:h.next=o,N===null?s.tail=o:N.prev=o,o.prev=h,o.next=N,s.length++,o},r=function(h,o){var N=h.prev,s=h.next;return N===null?o.head=s:N.next=s,s===null?o.tail=N:s.prev=N,h.prev=h.next=null,o.length--,h};m.exports=(function(){function h(o){var N=this;i(this,h),this.length=0,this.head=null,this.tail=null,o==null||o.forEach(function(s){return N.push(s)})}return n(h,[{key:"size",value:function(){return this.length}},{key:"insertBefore",value:function(o,N){return e(N.prev,t(o),N,this)}},{key:"insertAfter",value:function(o,N){return e(N,t(o),N.next,this)}},{key:"insertNodeBefore",value:function(o,N){return e(N.prev,o,N,this)}},{key:"insertNodeAfter",value:function(o,N){return e(N,o,N.next,this)}},{key:"push",value:function(o){return e(this.tail,t(o),null,this)}},{key:"unshift",value:function(o){return e(null,t(o),this.head,this)}},{key:"remove",value:function(o){return r(o,this)}},{key:"pop",value:function(){return r(this.tail,this).value}},{key:"popNode",value:function(){return r(this.tail,this)}},{key:"shift",value:function(){return r(this.head,this).value}},{key:"shiftNode",value:function(){return r(this.head,this)}},{key:"get_object_at",value:function(o){if(o<=this.length()){for(var N=1,s=this.head;N<o;)s=s.next,N++;return s.value}}},{key:"set_object_at",value:function(o,N){if(o<=this.length()){for(var s=1,g=this.head;s<o;)g=g.next,s++;g.value=N}}}]),h})()}),(function(m,L,A){function n(i,t,e){this.x=null,this.y=null,i==null&&t==null&&e==null?(this.x=0,this.y=0):typeof i=="number"&&typeof t=="number"&&e==null?(this.x=i,this.y=t):i.constructor.name=="Point"&&t==null&&e==null&&(e=i,this.x=e.x,this.y=e.y)}n.prototype.getX=function(){return this.x},n.prototype.getY=function(){return this.y},n.prototype.getLocation=function(){return new n(this.x,this.y)},n.prototype.setLocation=function(i,t,e){i.constructor.name=="Point"&&t==null&&e==null?(e=i,this.setLocation(e.x,e.y)):typeof i=="number"&&typeof t=="number"&&e==null&&(parseInt(i)==i&&parseInt(t)==t?this.move(i,t):(this.x=Math.floor(i+.5),this.y=Math.floor(t+.5)))},n.prototype.move=function(i,t){this.x=i,this.y=t},n.prototype.translate=function(i,t){this.x+=i,this.y+=t},n.prototype.equals=function(i){if(i.constructor.name=="Point"){var t=i;return this.x==t.x&&this.y==t.y}return this==i},n.prototype.toString=function(){return new n().constructor.name+"[x="+this.x+",y="+this.y+"]"},m.exports=n}),(function(m,L,A){function n(i,t,e,r){this.x=0,this.y=0,this.width=0,this.height=0,i!=null&&t!=null&&e!=null&&r!=null&&(this.x=i,this.y=t,this.width=e,this.height=r)}n.prototype.getX=function(){return this.x},n.prototype.setX=function(i){this.x=i},n.prototype.getY=function(){return this.y},n.prototype.setY=function(i){this.y=i},n.prototype.getWidth=function(){return this.width},n.prototype.setWidth=function(i){this.width=i},n.prototype.getHeight=function(){return this.height},n.prototype.setHeight=function(i){this.height=i},n.prototype.getRight=function(){return this.x+this.width},n.prototype.getBottom=function(){return this.y+this.height},n.prototype.intersects=function(i){return!(this.getRight()<i.x||this.getBottom()<i.y||i.getRight()<this.x||i.getBottom()<this.y)},n.prototype.getCenterX=function(){return this.x+this.width/2},n.prototype.getMinX=function(){return this.getX()},n.prototype.getMaxX=function(){return this.getX()+this.width},n.prototype.getCenterY=function(){return this.y+this.height/2},n.prototype.getMinY=function(){return this.getY()},n.prototype.getMaxY=function(){return this.getY()+this.height},n.prototype.getWidthHalf=function(){return this.width/2},n.prototype.getHeightHalf=function(){return this.height/2},m.exports=n}),(function(m,L,A){var n=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};function i(){}i.lastID=0,i.createID=function(t){return i.isPrimitive(t)?t:(t.uniqueID==null&&(t.uniqueID=i.getString(),i.lastID++),t.uniqueID)},i.getString=function(t){return t??(t=i.lastID),"Object#"+t},i.isPrimitive=function(t){var e=t===void 0?"undefined":n(t);return t==null||e!="object"&&e!="function"},m.exports=i}),(function(m,L,A){function n(u){if(Array.isArray(u)){for(var p=0,y=Array(u.length);p<u.length;p++)y[p]=u[p];return y}else return Array.from(u)}var i=A(0),t=A(6),e=A(3),r=A(1),h=A(5),o=A(4),N=A(17),s=A(27);function g(u){s.call(this),this.layoutQuality=i.QUALITY,this.createBendsAsNeeded=i.DEFAULT_CREATE_BENDS_AS_NEEDED,this.incremental=i.DEFAULT_INCREMENTAL,this.animationOnLayout=i.DEFAULT_ANIMATION_ON_LAYOUT,this.animationDuringLayout=i.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=i.DEFAULT_ANIMATION_PERIOD,this.uniformLeafNodeSizes=i.DEFAULT_UNIFORM_LEAF_NODE_SIZES,this.edgeToDummyNodes=new Map,this.graphManager=new t(this),this.isLayoutFinished=!1,this.isSubLayout=!1,this.isRemoteUse=!1,u!=null&&(this.isRemoteUse=u)}g.RANDOM_SEED=1,g.prototype=Object.create(s.prototype),g.prototype.getGraphManager=function(){return this.graphManager},g.prototype.getAllNodes=function(){return this.graphManager.getAllNodes()},g.prototype.getAllEdges=function(){return this.graphManager.getAllEdges()},g.prototype.getAllNodesToApplyGravitation=function(){return this.graphManager.getAllNodesToApplyGravitation()},g.prototype.newGraphManager=function(){var u=new t(this);return this.graphManager=u,u},g.prototype.newGraph=function(u){return new h(null,this.graphManager,u)},g.prototype.newNode=function(u){return new e(this.graphManager,u)},g.prototype.newEdge=function(u){return new r(null,null,u)},g.prototype.checkLayoutSuccess=function(){return this.graphManager.getRoot()==null||this.graphManager.getRoot().getNodes().length==0||this.graphManager.includesInvalidEdge()},g.prototype.runLayout=function(){this.isLayoutFinished=!1,this.tilingPreLayout&&this.tilingPreLayout(),this.initParameters();var u=this.checkLayoutSuccess()?!1:this.layout();return i.ANIMATE==="during"?!1:(u&&(this.isSubLayout||this.doPostLayout()),this.tilingPostLayout&&this.tilingPostLayout(),this.isLayoutFinished=!0,u)},g.prototype.doPostLayout=function(){this.incremental||this.transform(),this.update()},g.prototype.update2=function(){if(this.createBendsAsNeeded&&(this.createBendpointsFromDummyNodes(),this.graphManager.resetAllEdges()),!this.isRemoteUse){for(var u=this.graphManager.getAllEdges(),p=0;p<u.length;p++)u[p];for(var y=this.graphManager.getRoot().getNodes(),p=0;p<y.length;p++)y[p];this.update(this.graphManager.getRoot())}},g.prototype.update=function(u){if(u==null)this.update2();else if(u instanceof e){var p=u;if(p.getChild()!=null)for(var y=p.getChild().getNodes(),c=0;c<y.length;c++)update(y[c]);p.vGraphObject!=null&&p.vGraphObject.update(p)}else if(u instanceof r){var f=u;f.vGraphObject!=null&&f.vGraphObject.update(f)}else if(u instanceof h){var T=u;T.vGraphObject!=null&&T.vGraphObject.update(T)}},g.prototype.initParameters=function(){this.isSubLayout||(this.layoutQuality=i.QUALITY,this.animationDuringLayout=i.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=i.DEFAULT_ANIMATION_PERIOD,this.animationOnLayout=i.DEFAULT_ANIMATION_ON_LAYOUT,this.incremental=i.DEFAULT_INCREMENTAL,this.createBendsAsNeeded=i.DEFAULT_CREATE_BENDS_AS_NEEDED,this.uniformLeafNodeSizes=i.DEFAULT_UNIFORM_LEAF_NODE_SIZES),this.animationDuringLayout&&(this.animationOnLayout=!1)},g.prototype.transform=function(u){if(u==null)this.transform(new o(0,0));else{var p=new N,y=this.graphManager.getRoot().updateLeftTop();if(y!=null){p.setWorldOrgX(u.x),p.setWorldOrgY(u.y),p.setDeviceOrgX(y.x),p.setDeviceOrgY(y.y);for(var c=this.getAllNodes(),f,T=0;T<c.length;T++)f=c[T],f.transform(p)}}},g.prototype.positionNodesRandomly=function(u){if(u==null)this.positionNodesRandomly(this.getGraphManager().getRoot()),this.getGraphManager().getRoot().updateBounds(!0);else for(var p,y,c=u.getNodes(),f=0;f<c.length;f++)p=c[f],y=p.getChild(),y==null||y.getNodes().length==0?p.scatter():(this.positionNodesRandomly(y),p.updateBounds())},g.prototype.getFlatForest=function(){for(var u=[],p=!0,y=this.graphManager.getRoot().getNodes(),c=!0,f=0;f<y.length;f++)y[f].getChild()!=null&&(c=!1);if(!c)return u;var T=new Set,E=[],O=new Map,a=[];for(a=a.concat(y);a.length>0&&p;){for(E.push(a[0]);E.length>0&&p;){var d=E[0];E.splice(0,1),T.add(d);for(var l=d.getEdges(),f=0;f<l.length;f++){var v=l[f].getOtherEnd(d);if(O.get(d)!=v)if(!T.has(v))E.push(v),O.set(v,d);else{p=!1;break}}}if(!p)u=[];else{var _=[].concat(n(T));u.push(_);for(var f=0;f<_.length;f++){var D=_[f],I=a.indexOf(D);I>-1&&a.splice(I,1)}T=new Set,O=new Map}}return u},g.prototype.createDummyNodesForBendpoints=function(u){for(var p=[],y=u.source,c=this.graphManager.calcLowestCommonAncestor(u.source,u.target),f=0;f<u.bendpoints.length;f++){var T=this.newNode(null);T.setRect(new Point(0,0),new Dimension(1,1)),c.add(T);var E=this.newEdge(null);this.graphManager.add(E,y,T),p.add(T),y=T}var E=this.newEdge(null);return this.graphManager.add(E,y,u.target),this.edgeToDummyNodes.set(u,p),u.isInterGraph()?this.graphManager.remove(u):c.remove(u),p},g.prototype.createBendpointsFromDummyNodes=function(){var u=[];u=u.concat(this.graphManager.getAllEdges()),u=[].concat(n(this.edgeToDummyNodes.keys()),u);for(var p=0;p<u.length;p++){var y=u[p];if(y.bendpoints.length>0){for(var c=this.edgeToDummyNodes.get(y),f=0;f<c.length;f++){var T=c[f],E=new o(T.getCenterX(),T.getCenterY()),O=y.bendpoints.get(f);O.x=E.x,O.y=E.y,T.getOwner().remove(T)}this.graphManager.add(y,y.source,y.target)}}},g.transform=function(u,p,y,c){if(y!=null&&c!=null){var f=p;if(u<=50){var T=p/y;f-=(p-T)/50*(50-u)}else{var E=p*c;f+=(E-p)/50*(u-50)}return f}else{var O,a;return u<=50?(O=9*p/500,a=p/10):(O=9*p/50,a=-8*p),O*u+a}},g.findCenterOfTree=function(u){var p=[];p=p.concat(u);var y=[],c=new Map,f=!1,T=null;(p.length==1||p.length==2)&&(f=!0,T=p[0]);for(var E=0;E<p.length;E++){var O=p[E],a=O.getNeighborsList().size;c.set(O,O.getNeighborsList().size),a==1&&y.push(O)}var d=[];for(d=d.concat(y);!f;){var l=[];l=l.concat(d),d=[];for(var E=0;E<p.length;E++){var O=p[E],v=p.indexOf(O);v>=0&&p.splice(v,1),O.getNeighborsList().forEach(function(I){if(y.indexOf(I)<0){var w=c.get(I)-1;w==1&&d.push(I),c.set(I,w)}})}y=y.concat(d),(p.length==1||p.length==2)&&(f=!0,T=p[0])}return T},g.prototype.setGraphManager=function(u){this.graphManager=u},m.exports=g}),(function(m,L,A){function n(){}n.seed=1,n.x=0,n.nextDouble=function(){return n.x=Math.sin(n.seed++)*1e4,n.x-Math.floor(n.x)},m.exports=n}),(function(m,L,A){var n=A(4);function i(t,e){this.lworldOrgX=0,this.lworldOrgY=0,this.ldeviceOrgX=0,this.ldeviceOrgY=0,this.lworldExtX=1,this.lworldExtY=1,this.ldeviceExtX=1,this.ldeviceExtY=1}i.prototype.getWorldOrgX=function(){return this.lworldOrgX},i.prototype.setWorldOrgX=function(t){this.lworldOrgX=t},i.prototype.getWorldOrgY=function(){return this.lworldOrgY},i.prototype.setWorldOrgY=function(t){this.lworldOrgY=t},i.prototype.getWorldExtX=function(){return this.lworldExtX},i.prototype.setWorldExtX=function(t){this.lworldExtX=t},i.prototype.getWorldExtY=function(){return this.lworldExtY},i.prototype.setWorldExtY=function(t){this.lworldExtY=t},i.prototype.getDeviceOrgX=function(){return this.ldeviceOrgX},i.prototype.setDeviceOrgX=function(t){this.ldeviceOrgX=t},i.prototype.getDeviceOrgY=function(){return this.ldeviceOrgY},i.prototype.setDeviceOrgY=function(t){this.ldeviceOrgY=t},i.prototype.getDeviceExtX=function(){return this.ldeviceExtX},i.prototype.setDeviceExtX=function(t){this.ldeviceExtX=t},i.prototype.getDeviceExtY=function(){return this.ldeviceExtY},i.prototype.setDeviceExtY=function(t){this.ldeviceExtY=t},i.prototype.transformX=function(t){var e=0,r=this.lworldExtX;return r!=0&&(e=this.ldeviceOrgX+(t-this.lworldOrgX)*this.ldeviceExtX/r),e},i.prototype.transformY=function(t){var e=0,r=this.lworldExtY;return r!=0&&(e=this.ldeviceOrgY+(t-this.lworldOrgY)*this.ldeviceExtY/r),e},i.prototype.inverseTransformX=function(t){var e=0,r=this.ldeviceExtX;return r!=0&&(e=this.lworldOrgX+(t-this.ldeviceOrgX)*this.lworldExtX/r),e},i.prototype.inverseTransformY=function(t){var e=0,r=this.ldeviceExtY;return r!=0&&(e=this.lworldOrgY+(t-this.ldeviceOrgY)*this.lworldExtY/r),e},i.prototype.inverseTransformPoint=function(t){return new n(this.inverseTransformX(t.x),this.inverseTransformY(t.y))},m.exports=i}),(function(m,L,A){function n(s){if(Array.isArray(s)){for(var g=0,u=Array(s.length);g<s.length;g++)u[g]=s[g];return u}else return Array.from(s)}var i=A(15),t=A(7),e=A(0),r=A(8),h=A(9);function o(){i.call(this),this.useSmartIdealEdgeLengthCalculation=t.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.idealEdgeLength=t.DEFAULT_EDGE_LENGTH,this.springConstant=t.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=t.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=t.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=t.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=t.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=t.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.displacementThresholdPerNode=3*t.DEFAULT_EDGE_LENGTH/100,this.coolingFactor=t.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.initialCoolingFactor=t.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.totalDisplacement=0,this.oldTotalDisplacement=0,this.maxIterations=t.MAX_ITERATIONS}for(var N in o.prototype=Object.create(i.prototype),i)o[N]=i[N];o.prototype.initParameters=function(){i.prototype.initParameters.call(this,arguments),this.totalIterations=0,this.notAnimatedIterations=0,this.useFRGridVariant=t.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION,this.grid=[]},o.prototype.calcIdealEdgeLengths=function(){for(var s,g,u,p,y,c,f=this.getGraphManager().getAllEdges(),T=0;T<f.length;T++)s=f[T],s.idealLength=this.idealEdgeLength,s.isInterGraph&&(u=s.getSource(),p=s.getTarget(),y=s.getSourceInLca().getEstimatedSize(),c=s.getTargetInLca().getEstimatedSize(),this.useSmartIdealEdgeLengthCalculation&&(s.idealLength+=y+c-2*e.SIMPLE_NODE_SIZE),g=s.getLca().getInclusionTreeDepth(),s.idealLength+=t.DEFAULT_EDGE_LENGTH*t.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR*(u.getInclusionTreeDepth()+p.getInclusionTreeDepth()-2*g))},o.prototype.initSpringEmbedder=function(){var s=this.getAllNodes().length;this.incremental?(s>t.ADAPTATION_LOWER_NODE_LIMIT&&(this.coolingFactor=Math.max(this.coolingFactor*t.COOLING_ADAPTATION_FACTOR,this.coolingFactor-(s-t.ADAPTATION_LOWER_NODE_LIMIT)/(t.ADAPTATION_UPPER_NODE_LIMIT-t.ADAPTATION_LOWER_NODE_LIMIT)*this.coolingFactor*(1-t.COOLING_ADAPTATION_FACTOR))),this.maxNodeDisplacement=t.MAX_NODE_DISPLACEMENT_INCREMENTAL):(s>t.ADAPTATION_LOWER_NODE_LIMIT?this.coolingFactor=Math.max(t.COOLING_ADAPTATION_FACTOR,1-(s-t.ADAPTATION_LOWER_NODE_LIMIT)/(t.ADAPTATION_UPPER_NODE_LIMIT-t.ADAPTATION_LOWER_NODE_LIMIT)*(1-t.COOLING_ADAPTATION_FACTOR)):this.coolingFactor=1,this.initialCoolingFactor=this.coolingFactor,this.maxNodeDisplacement=t.MAX_NODE_DISPLACEMENT),this.maxIterations=Math.max(this.getAllNodes().length*5,this.maxIterations),this.totalDisplacementThreshold=this.displacementThresholdPerNode*this.getAllNodes().length,this.repulsionRange=this.calcRepulsionRange()},o.prototype.calcSpringForces=function(){for(var s=this.getAllEdges(),g,u=0;u<s.length;u++)g=s[u],this.calcSpringForce(g,g.idealLength)},o.prototype.calcRepulsionForces=function(){var s=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,u,p,y,c,f=this.getAllNodes(),T;if(this.useFRGridVariant)for(this.totalIterations%t.GRID_CALCULATION_CHECK_PERIOD==1&&s&&this.updateGrid(),T=new Set,u=0;u<f.length;u++)y=f[u],this.calculateRepulsionForceOfANode(y,T,s,g),T.add(y);else for(u=0;u<f.length;u++)for(y=f[u],p=u+1;p<f.length;p++)c=f[p],y.getOwner()==c.getOwner()&&this.calcRepulsionForce(y,c)},o.prototype.calcGravitationalForces=function(){for(var s,g=this.getAllNodesToApplyGravitation(),u=0;u<g.length;u++)s=g[u],this.calcGravitationalForce(s)},o.prototype.moveNodes=function(){for(var s=this.getAllNodes(),g,u=0;u<s.length;u++)g=s[u],g.move()},o.prototype.calcSpringForce=function(s,g){var u=s.getSource(),p=s.getTarget(),y,c,f,T;if(this.uniformLeafNodeSizes&&u.getChild()==null&&p.getChild()==null)s.updateLengthSimple();else if(s.updateLength(),s.isOverlapingSourceAndTarget)return;y=s.getLength(),y!=0&&(c=this.springConstant*(y-g),f=c*(s.lengthX/y),T=c*(s.lengthY/y),u.springForceX+=f,u.springForceY+=T,p.springForceX-=f,p.springForceY-=T)},o.prototype.calcRepulsionForce=function(s,g){var u=s.getRect(),p=g.getRect(),y=[,,],c=[,,,,],f,T,E,O,a,d,l;if(u.intersects(p)){r.calcSeparationAmount(u,p,y,t.DEFAULT_EDGE_LENGTH/2),d=2*y[0],l=2*y[1];var v=s.noOfChildren*g.noOfChildren/(s.noOfChildren+g.noOfChildren);s.repulsionForceX-=v*d,s.repulsionForceY-=v*l,g.repulsionForceX+=v*d,g.repulsionForceY+=v*l}else this.uniformLeafNodeSizes&&s.getChild()==null&&g.getChild()==null?(f=p.getCenterX()-u.getCenterX(),T=p.getCenterY()-u.getCenterY()):(r.getIntersection(u,p,c),f=c[2]-c[0],T=c[3]-c[1]),Math.abs(f)<t.MIN_REPULSION_DIST&&(f=h.sign(f)*t.MIN_REPULSION_DIST),Math.abs(T)<t.MIN_REPULSION_DIST&&(T=h.sign(T)*t.MIN_REPULSION_DIST),E=f*f+T*T,O=Math.sqrt(E),a=this.repulsionConstant*s.noOfChildren*g.noOfChildren/E,d=a*f/O,l=a*T/O,s.repulsionForceX-=d,s.repulsionForceY-=l,g.repulsionForceX+=d,g.repulsionForceY+=l},o.prototype.calcGravitationalForce=function(s){var g=s.getOwner(),u=(g.getRight()+g.getLeft())/2,p=(g.getTop()+g.getBottom())/2,y=s.getCenterX()-u,c=s.getCenterY()-p,f=Math.abs(y)+s.getWidth()/2,T=Math.abs(c)+s.getHeight()/2,E;s.getOwner()==this.graphManager.getRoot()?(E=g.getEstimatedSize()*this.gravityRangeFactor,(f>E||T>E)&&(s.gravitationForceX=-this.gravityConstant*y,s.gravitationForceY=-this.gravityConstant*c)):(E=g.getEstimatedSize()*this.compoundGravityRangeFactor,(f>E||T>E)&&(s.gravitationForceX=-this.gravityConstant*y*this.compoundGravityConstant,s.gravitationForceY=-this.gravityConstant*c*this.compoundGravityConstant))},o.prototype.isConverged=function(){var s,g=!1;return this.totalIterations>this.maxIterations/3&&(g=Math.abs(this.totalDisplacement-this.oldTotalDisplacement)<2),s=this.totalDisplacement<this.totalDisplacementThreshold,this.oldTotalDisplacement=this.totalDisplacement,s||g},o.prototype.animate=function(){this.animationDuringLayout&&!this.isSubLayout&&(this.notAnimatedIterations==this.animationPeriod?(this.update(),this.notAnimatedIterations=0):this.notAnimatedIterations++)},o.prototype.calcNoOfChildrenForAllNodes=function(){for(var s,g=this.graphManager.getAllNodes(),u=0;u<g.length;u++)s=g[u],s.noOfChildren=s.getNoOfChildren()},o.prototype.calcGrid=function(s){var g=0,u=0;g=parseInt(Math.ceil((s.getRight()-s.getLeft())/this.repulsionRange)),u=parseInt(Math.ceil((s.getBottom()-s.getTop())/this.repulsionRange));for(var p=Array(g),y=0;y<g;y++)p[y]=Array(u);for(var y=0;y<g;y++)for(var c=0;c<u;c++)p[y][c]=[];return p},o.prototype.addNodeToGrid=function(s,g,u){var p=0,y=0,c=0,f=0;p=parseInt(Math.floor((s.getRect().x-g)/this.repulsionRange)),y=parseInt(Math.floor((s.getRect().width+s.getRect().x-g)/this.repulsionRange)),c=parseInt(Math.floor((s.getRect().y-u)/this.repulsionRange)),f=parseInt(Math.floor((s.getRect().height+s.getRect().y-u)/this.repulsionRange));for(var T=p;T<=y;T++)for(var E=c;E<=f;E++)this.grid[T][E].push(s),s.setGridCoordinates(p,y,c,f)},o.prototype.updateGrid=function(){var s,g,u=this.getAllNodes();for(this.grid=this.calcGrid(this.graphManager.getRoot()),s=0;s<u.length;s++)g=u[s],this.addNodeToGrid(g,this.graphManager.getRoot().getLeft(),this.graphManager.getRoot().getTop())},o.prototype.calculateRepulsionForceOfANode=function(s,g,u,p){if(this.totalIterations%t.GRID_CALCULATION_CHECK_PERIOD==1&&u||p){var y=new Set;s.surrounding=[];for(var c,f=this.grid,T=s.startX-1;T<s.finishX+2;T++)for(var E=s.startY-1;E<s.finishY+2;E++)if(!(T<0||E<0||T>=f.length||E>=f[0].length)){for(var O=0;O<f[T][E].length;O++)if(c=f[T][E][O],!(s.getOwner()!=c.getOwner()||s==c)&&!g.has(c)&&!y.has(c)){var a=Math.abs(s.getCenterX()-c.getCenterX())-(s.getWidth()/2+c.getWidth()/2),d=Math.abs(s.getCenterY()-c.getCenterY())-(s.getHeight()/2+c.getHeight()/2);a<=this.repulsionRange&&d<=this.repulsionRange&&y.add(c)}}s.surrounding=[].concat(n(y))}for(T=0;T<s.surrounding.length;T++)this.calcRepulsionForce(s,s.surrounding[T])},o.prototype.calcRepulsionRange=function(){return 0},m.exports=o}),(function(m,L,A){var n=A(1),i=A(7);function t(r,h,o){n.call(this,r,h,o),this.idealLength=i.DEFAULT_EDGE_LENGTH}for(var e in t.prototype=Object.create(n.prototype),n)t[e]=n[e];m.exports=t}),(function(m,L,A){var n=A(3);function i(e,r,h,o){n.call(this,e,r,h,o),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0,this.startX=0,this.finishX=0,this.startY=0,this.finishY=0,this.surrounding=[]}for(var t in i.prototype=Object.create(n.prototype),n)i[t]=n[t];i.prototype.setGridCoordinates=function(e,r,h,o){this.startX=e,this.finishX=r,this.startY=h,this.finishY=o},m.exports=i}),(function(m,L,A){function n(i,t){this.width=0,this.height=0,i!==null&&t!==null&&(this.height=t,this.width=i)}n.prototype.getWidth=function(){return this.width},n.prototype.setWidth=function(i){this.width=i},n.prototype.getHeight=function(){return this.height},n.prototype.setHeight=function(i){this.height=i},m.exports=n}),(function(m,L,A){var n=A(14);function i(){this.map={},this.keys=[]}i.prototype.put=function(t,e){var r=n.createID(t);this.contains(r)||(this.map[r]=e,this.keys.push(t))},i.prototype.contains=function(t){return n.createID(t),this.map[t]!=null},i.prototype.get=function(t){var e=n.createID(t);return this.map[e]},i.prototype.keySet=function(){return this.keys},m.exports=i}),(function(m,L,A){var n=A(14);function i(){this.set={}}i.prototype.add=function(t){var e=n.createID(t);this.contains(e)||(this.set[e]=t)},i.prototype.remove=function(t){delete this.set[n.createID(t)]},i.prototype.clear=function(){this.set={}},i.prototype.contains=function(t){return this.set[n.createID(t)]==t},i.prototype.isEmpty=function(){return this.size()===0},i.prototype.size=function(){return Object.keys(this.set).length},i.prototype.addAllTo=function(t){for(var e=Object.keys(this.set),r=e.length,h=0;h<r;h++)t.push(this.set[e[h]])},i.prototype.size=function(){return Object.keys(this.set).length},i.prototype.addAll=function(t){for(var e=t.length,r=0;r<e;r++){var h=t[r];this.add(h)}},m.exports=i}),(function(m,L,A){var n=(function(){function e(r,h){for(var o=0;o<h.length;o++){var N=h[o];N.enumerable=N.enumerable||!1,N.configurable=!0,"value"in N&&(N.writable=!0),Object.defineProperty(r,N.key,N)}}return function(r,h,o){return h&&e(r.prototype,h),o&&e(r,o),r}})();function i(e,r){if(!(e instanceof r))throw TypeError("Cannot call a class as a function")}var t=A(11);m.exports=(function(){function e(r,h){i(this,e),(h!==null||h!==void 0)&&(this.compareFunction=this._defaultCompareFunction);var o=void 0;o=r instanceof t?r.size():r.length,this._quicksort(r,0,o-1)}return n(e,[{key:"_quicksort",value:function(r,h,o){if(h<o){var N=this._partition(r,h,o);this._quicksort(r,h,N),this._quicksort(r,N+1,o)}}},{key:"_partition",value:function(r,h,o){for(var N=this._get(r,h),s=h,g=o;;){for(;this.compareFunction(N,this._get(r,g));)g--;for(;this.compareFunction(this._get(r,s),N);)s++;if(s<g)this._swap(r,s,g),s++,g--;else return g}}},{key:"_get",value:function(r,h){return r instanceof t?r.get_object_at(h):r[h]}},{key:"_set",value:function(r,h,o){r instanceof t?r.set_object_at(h,o):r[h]=o}},{key:"_swap",value:function(r,h,o){var N=this._get(r,h);this._set(r,h,this._get(r,o)),this._set(r,o,N)}},{key:"_defaultCompareFunction",value:function(r,h){return h>r}}]),e})()}),(function(m,L,A){var n=(function(){function t(e,r){for(var h=0;h<r.length;h++){var o=r[h];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(e,r,h){return r&&t(e.prototype,r),h&&t(e,h),e}})();function i(t,e){if(!(t instanceof e))throw TypeError("Cannot call a class as a function")}m.exports=(function(){function t(e,r){var h=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:-1,N=arguments.length>4&&arguments[4]!==void 0?arguments[4]:-1;i(this,t),this.sequence1=e,this.sequence2=r,this.match_score=h,this.mismatch_penalty=o,this.gap_penalty=N,this.iMax=e.length+1,this.jMax=r.length+1,this.grid=Array(this.iMax);for(var s=0;s<this.iMax;s++){this.grid[s]=Array(this.jMax);for(var g=0;g<this.jMax;g++)this.grid[s][g]=0}this.tracebackGrid=Array(this.iMax);for(var u=0;u<this.iMax;u++){this.tracebackGrid[u]=Array(this.jMax);for(var p=0;p<this.jMax;p++)this.tracebackGrid[u][p]=[null,null,null]}this.alignments=[],this.score=-1,this.computeGrids()}return n(t,[{key:"getScore",value:function(){return this.score}},{key:"getAlignments",value:function(){return this.alignments}},{key:"computeGrids",value:function(){for(var e=1;e<this.jMax;e++)this.grid[0][e]=this.grid[0][e-1]+this.gap_penalty,this.tracebackGrid[0][e]=[!1,!1,!0];for(var r=1;r<this.iMax;r++)this.grid[r][0]=this.grid[r-1][0]+this.gap_penalty,this.tracebackGrid[r][0]=[!1,!0,!1];for(var h=1;h<this.iMax;h++)for(var o=1;o<this.jMax;o++){var N=void 0;N=this.sequence1[h-1]===this.sequence2[o-1]?this.grid[h-1][o-1]+this.match_score:this.grid[h-1][o-1]+this.mismatch_penalty;var s=this.grid[h-1][o]+this.gap_penalty,g=this.grid[h][o-1]+this.gap_penalty,u=[N,s,g],p=this.arrayAllMaxIndexes(u);this.grid[h][o]=u[p[0]],this.tracebackGrid[h][o]=[p.includes(0),p.includes(1),p.includes(2)]}this.score=this.grid[this.iMax-1][this.jMax-1]}},{key:"alignmentTraceback",value:function(){var e=[];for(e.push({pos:[this.sequence1.length,this.sequence2.length],seq1:"",seq2:""});e[0];){var r=e[0],h=this.tracebackGrid[r.pos[0]][r.pos[1]];h[0]&&e.push({pos:[r.pos[0]-1,r.pos[1]-1],seq1:this.sequence1[r.pos[0]-1]+r.seq1,seq2:this.sequence2[r.pos[1]-1]+r.seq2}),h[1]&&e.push({pos:[r.pos[0]-1,r.pos[1]],seq1:this.sequence1[r.pos[0]-1]+r.seq1,seq2:"-"+r.seq2}),h[2]&&e.push({pos:[r.pos[0],r.pos[1]-1],seq1:"-"+r.seq1,seq2:this.sequence2[r.pos[1]-1]+r.seq2}),r.pos[0]===0&&r.pos[1]===0&&this.alignments.push({sequence1:r.seq1,sequence2:r.seq2}),e.shift()}return this.alignments}},{key:"getAllIndexes",value:function(e,r){for(var h=[],o=-1;(o=e.indexOf(r,o+1))!==-1;)h.push(o);return h}},{key:"arrayAllMaxIndexes",value:function(e){return this.getAllIndexes(e,Math.max.apply(null,e))}}]),t})()}),(function(m,L,A){var n=function(){};n.FDLayout=A(18),n.FDLayoutConstants=A(7),n.FDLayoutEdge=A(19),n.FDLayoutNode=A(20),n.DimensionD=A(21),n.HashMap=A(22),n.HashSet=A(23),n.IGeometry=A(8),n.IMath=A(9),n.Integer=A(10),n.Point=A(12),n.PointD=A(4),n.RandomSeed=A(16),n.RectangleD=A(13),n.Transform=A(17),n.UniqueIDGeneretor=A(14),n.Quicksort=A(24),n.LinkedList=A(11),n.LGraphObject=A(2),n.LGraph=A(5),n.LEdge=A(1),n.LGraphManager=A(6),n.LNode=A(3),n.Layout=A(15),n.LayoutConstants=A(0),n.NeedlemanWunsch=A(25),m.exports=n}),(function(m,L,A){function n(){this.listeners=[]}var i=n.prototype;i.addListener=function(t,e){this.listeners.push({event:t,callback:e})},i.removeListener=function(t,e){for(var r=this.listeners.length;r>=0;r--){var h=this.listeners[r];h.event===t&&h.callback===e&&this.listeners.splice(r,1)}},i.emit=function(t,e){for(var r=0;r<this.listeners.length;r++){var h=this.listeners[r];t===h.event&&h.callback(e)}},m.exports=n})])})})),Q=V(((C,P)=>{(function(m,L){typeof C=="object"&&typeof P=="object"?P.exports=L(Z()):typeof define=="function"&&define.amd?define(["layout-base"],L):typeof C=="object"?C.coseBase=L(Z()):m.coseBase=L(m.layoutBase)})(C,function(m){return(function(L){var A={};function n(i){if(A[i])return A[i].exports;var t=A[i]={i,l:!1,exports:{}};return L[i].call(t.exports,t,t.exports,n),t.l=!0,t.exports}return n.m=L,n.c=A,n.i=function(i){return i},n.d=function(i,t,e){n.o(i,t)||Object.defineProperty(i,t,{configurable:!1,enumerable:!0,get:e})},n.n=function(i){var t=i&&i.__esModule?function(){return i.default}:function(){return i};return n.d(t,"a",t),t},n.o=function(i,t){return Object.prototype.hasOwnProperty.call(i,t)},n.p="",n(n.s=7)})([(function(L,A){L.exports=m}),(function(L,A,n){var i=n(0).FDLayoutConstants;function t(){}for(var e in i)t[e]=i[e];t.DEFAULT_USE_MULTI_LEVEL_SCALING=!1,t.DEFAULT_RADIAL_SEPARATION=i.DEFAULT_EDGE_LENGTH,t.DEFAULT_COMPONENT_SEPERATION=60,t.TILE=!0,t.TILING_PADDING_VERTICAL=10,t.TILING_PADDING_HORIZONTAL=10,t.TREE_REDUCTION_ON_INCREMENTAL=!1,L.exports=t}),(function(L,A,n){var i=n(0).FDLayoutEdge;function t(r,h,o){i.call(this,r,h,o)}for(var e in t.prototype=Object.create(i.prototype),i)t[e]=i[e];L.exports=t}),(function(L,A,n){var i=n(0).LGraph;function t(r,h,o){i.call(this,r,h,o)}for(var e in t.prototype=Object.create(i.prototype),i)t[e]=i[e];L.exports=t}),(function(L,A,n){var i=n(0).LGraphManager;function t(r){i.call(this,r)}for(var e in t.prototype=Object.create(i.prototype),i)t[e]=i[e];L.exports=t}),(function(L,A,n){var i=n(0).FDLayoutNode,t=n(0).IMath;function e(h,o,N,s){i.call(this,h,o,N,s)}for(var r in e.prototype=Object.create(i.prototype),i)e[r]=i[r];e.prototype.move=function(){var h=this.graphManager.getLayout();this.displacementX=h.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.noOfChildren,this.displacementY=h.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.noOfChildren,Math.abs(this.displacementX)>h.coolingFactor*h.maxNodeDisplacement&&(this.displacementX=h.coolingFactor*h.maxNodeDisplacement*t.sign(this.displacementX)),Math.abs(this.displacementY)>h.coolingFactor*h.maxNodeDisplacement&&(this.displacementY=h.coolingFactor*h.maxNodeDisplacement*t.sign(this.displacementY)),this.child==null||this.child.getNodes().length==0?this.moveBy(this.displacementX,this.displacementY):this.propogateDisplacementToChildren(this.displacementX,this.displacementY),h.totalDisplacement+=Math.abs(this.displacementX)+Math.abs(this.displacementY),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0},e.prototype.propogateDisplacementToChildren=function(h,o){for(var N=this.getChild().getNodes(),s,g=0;g<N.length;g++)s=N[g],s.getChild()==null?(s.moveBy(h,o),s.displacementX+=h,s.displacementY+=o):s.propogateDisplacementToChildren(h,o)},e.prototype.setPred1=function(h){this.pred1=h},e.prototype.getPred1=function(){return pred1},e.prototype.getPred2=function(){return pred2},e.prototype.setNext=function(h){this.next=h},e.prototype.getNext=function(){return next},e.prototype.setProcessed=function(h){this.processed=h},e.prototype.isProcessed=function(){return processed},L.exports=e}),(function(L,A,n){var i=n(0).FDLayout,t=n(4),e=n(3),r=n(5),h=n(2),o=n(1),N=n(0).FDLayoutConstants,s=n(0).LayoutConstants,g=n(0).Point,u=n(0).PointD,p=n(0).Layout,y=n(0).Integer,c=n(0).IGeometry,f=n(0).LGraph,T=n(0).Transform;function E(){i.call(this),this.toBeTiled={}}for(var O in E.prototype=Object.create(i.prototype),i)E[O]=i[O];E.prototype.newGraphManager=function(){var a=new t(this);return this.graphManager=a,a},E.prototype.newGraph=function(a){return new e(null,this.graphManager,a)},E.prototype.newNode=function(a){return new r(this.graphManager,a)},E.prototype.newEdge=function(a){return new h(null,null,a)},E.prototype.initParameters=function(){i.prototype.initParameters.call(this,arguments),this.isSubLayout||(o.DEFAULT_EDGE_LENGTH<10?this.idealEdgeLength=10:this.idealEdgeLength=o.DEFAULT_EDGE_LENGTH,this.useSmartIdealEdgeLengthCalculation=o.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.springConstant=N.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=N.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=N.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=N.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=N.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=N.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.prunedNodesAll=[],this.growTreeIterations=0,this.afterGrowthIterations=0,this.isTreeGrowing=!1,this.isGrowthFinished=!1,this.coolingCycle=0,this.maxCoolingCycle=this.maxIterations/N.CONVERGENCE_CHECK_PERIOD,this.finalTemperature=N.CONVERGENCE_CHECK_PERIOD/this.maxIterations,this.coolingAdjuster=1)},E.prototype.layout=function(){return s.DEFAULT_CREATE_BENDS_AS_NEEDED&&(this.createBendpoints(),this.graphManager.resetAllEdges()),this.level=0,this.classicLayout()},E.prototype.classicLayout=function(){if(this.nodesWithGravity=this.calculateNodesToApplyGravitationTo(),this.graphManager.setAllNodesToApplyGravitation(this.nodesWithGravity),this.calcNoOfChildrenForAllNodes(),this.graphManager.calcLowestCommonAncestors(),this.graphManager.calcInclusionTreeDepths(),this.graphManager.getRoot().calcEstimatedSize(),this.calcIdealEdgeLengths(),this.incremental){if(o.TREE_REDUCTION_ON_INCREMENTAL){this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var a=new Set(this.getAllNodes()),d=this.nodesWithGravity.filter(function(v){return a.has(v)});this.graphManager.setAllNodesToApplyGravitation(d)}}else{var l=this.getFlatForest();if(l.length>0)this.positionNodesRadially(l);else{this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var a=new Set(this.getAllNodes()),d=this.nodesWithGravity.filter(function(D){return a.has(D)});this.graphManager.setAllNodesToApplyGravitation(d),this.positionNodesRandomly()}}return this.initSpringEmbedder(),this.runSpringEmbedder(),!0},E.prototype.tick=function(){if(this.totalIterations++,this.totalIterations===this.maxIterations&&!this.isTreeGrowing&&!this.isGrowthFinished)if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0;if(this.totalIterations%N.CONVERGENCE_CHECK_PERIOD==0&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.isConverged())if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0;this.coolingCycle++,this.layoutQuality==0?this.coolingAdjuster=this.coolingCycle:this.layoutQuality==1&&(this.coolingAdjuster=this.coolingCycle/3),this.coolingFactor=Math.max(this.initialCoolingFactor-this.coolingCycle**+(Math.log(100*(this.initialCoolingFactor-this.finalTemperature))/Math.log(this.maxCoolingCycle))/100*this.coolingAdjuster,this.finalTemperature),this.animationPeriod=Math.ceil(this.initialAnimationPeriod*Math.sqrt(this.coolingFactor))}if(this.isTreeGrowing){if(this.growTreeIterations%10==0)if(this.prunedNodesAll.length>0){this.graphManager.updateBounds(),this.updateGrid(),this.growTree(this.prunedNodesAll),this.graphManager.resetAllNodesToApplyGravitation();var a=new Set(this.getAllNodes()),d=this.nodesWithGravity.filter(function(_){return a.has(_)});this.graphManager.setAllNodesToApplyGravitation(d),this.graphManager.updateBounds(),this.updateGrid(),this.coolingFactor=N.DEFAULT_COOLING_FACTOR_INCREMENTAL}else this.isTreeGrowing=!1,this.isGrowthFinished=!0;this.growTreeIterations++}if(this.isGrowthFinished){if(this.isConverged())return!0;this.afterGrowthIterations%10==0&&(this.graphManager.updateBounds(),this.updateGrid()),this.coolingFactor=N.DEFAULT_COOLING_FACTOR_INCREMENTAL*((100-this.afterGrowthIterations)/100),this.afterGrowthIterations++}var l=!this.isTreeGrowing&&!this.isGrowthFinished,v=this.growTreeIterations%10==1&&this.isTreeGrowing||this.afterGrowthIterations%10==1&&this.isGrowthFinished;return this.totalDisplacement=0,this.graphManager.updateBounds(),this.calcSpringForces(),this.calcRepulsionForces(l,v),this.calcGravitationalForces(),this.moveNodes(),this.animate(),!1},E.prototype.getPositionsData=function(){for(var a=this.graphManager.getAllNodes(),d={},l=0;l<a.length;l++){var v=a[l].rect,_=a[l].id;d[_]={id:_,x:v.getCenterX(),y:v.getCenterY(),w:v.width,h:v.height}}return d},E.prototype.runSpringEmbedder=function(){this.initialAnimationPeriod=25,this.animationPeriod=this.initialAnimationPeriod;var a=!1;if(N.ANIMATE==="during")this.emit("layoutstarted");else{for(;!a;)a=this.tick();this.graphManager.updateBounds()}},E.prototype.calculateNodesToApplyGravitationTo=function(){var a=[],d,l=this.graphManager.getGraphs(),v=l.length,_;for(_=0;_<v;_++)d=l[_],d.updateConnected(),d.isConnected||(a=a.concat(d.getNodes()));return a},E.prototype.createBendpoints=function(){var a=[];a=a.concat(this.graphManager.getAllEdges());var d=new Set,l;for(l=0;l<a.length;l++){var v=a[l];if(!d.has(v)){var _=v.getSource(),D=v.getTarget();if(_==D)v.getBendpoints().push(new u),v.getBendpoints().push(new u),this.createDummyNodesForBendpoints(v),d.add(v);else{var I=[];if(I=I.concat(_.getEdgeListToNode(D)),I=I.concat(D.getEdgeListToNode(_)),!d.has(I[0])){if(I.length>1){var w;for(w=0;w<I.length;w++){var R=I[w];R.getBendpoints().push(new u),this.createDummyNodesForBendpoints(R)}}I.forEach(function(G){d.add(G)})}}}if(d.size==a.length)break}},E.prototype.positionNodesRadially=function(a){for(var d=new g(0,0),l=Math.ceil(Math.sqrt(a.length)),v=0,_=0,D=0,I=new u(0,0),w=0;w<a.length;w++){w%l==0&&(D=0,_=v,w!=0&&(_+=o.DEFAULT_COMPONENT_SEPERATION),v=0);var R=a[w],G=p.findCenterOfTree(R);d.x=D,d.y=_,I=E.radialLayout(R,G,d),I.y>v&&(v=Math.floor(I.y)),D=Math.floor(I.x+o.DEFAULT_COMPONENT_SEPERATION)}this.transform(new u(s.WORLD_CENTER_X-I.x/2,s.WORLD_CENTER_Y-I.y/2))},E.radialLayout=function(a,d,l){var v=Math.max(this.maxDiagonalInTree(a),o.DEFAULT_RADIAL_SEPARATION);E.branchRadialLayout(d,null,0,359,0,v);var _=f.calculateBounds(a),D=new T;D.setDeviceOrgX(_.getMinX()),D.setDeviceOrgY(_.getMinY()),D.setWorldOrgX(l.x),D.setWorldOrgY(l.y);for(var I=0;I<a.length;I++)a[I].transform(D);var w=new u(_.getMaxX(),_.getMaxY());return D.inverseTransformPoint(w)},E.branchRadialLayout=function(a,d,l,v,_,D){var I=(v-l+1)/2;I<0&&(I+=180);var w=(I+l)%360*c.TWO_PI/360,R=_*Math.cos(w),G=_*Math.sin(w);a.setCenter(R,G);var x=[];x=x.concat(a.getEdges());var M=x.length;d!=null&&M--;for(var U=0,b=x.length,F,S=a.getEdgesBetween(d);S.length>1;){var Y=S[0];S.splice(0,1);var X=x.indexOf(Y);X>=0&&x.splice(X,1),b--,M--}F=d==null?0:(x.indexOf(S[0])+1)%b;for(var W=Math.abs(v-l)/M,B=F;U!=M;B=++B%b){var H=x[B].getOtherEnd(a);if(H!=d){var q=(l+U*W)%360,ot=(q+W)%360;E.branchRadialLayout(H,a,q,ot,_+D,D),U++}}},E.maxDiagonalInTree=function(a){for(var d=y.MIN_VALUE,l=0;l<a.length;l++){var v=a[l].getDiagonal();v>d&&(d=v)}return d},E.prototype.calcRepulsionRange=function(){return 2*(this.level+1)*this.idealEdgeLength},E.prototype.groupZeroDegreeMembers=function(){var a=this,d={};this.memberGroups={},this.idToDummyNode={};for(var l=[],v=this.graphManager.getAllNodes(),_=0;_<v.length;_++){var D=v[_],I=D.getParent();this.getNodeDegreeWithChildren(D)===0&&(I.id==null||!this.getToBeTiled(I))&&l.push(D)}for(var _=0;_<l.length;_++){var D=l[_],w=D.getParent().id;d[w]===void 0&&(d[w]=[]),d[w]=d[w].concat(D)}Object.keys(d).forEach(function(R){if(d[R].length>1){var G="DummyCompound_"+R;a.memberGroups[G]=d[R];var x=d[R][0].getParent(),M=new r(a.graphManager);M.id=G,M.paddingLeft=x.paddingLeft||0,M.paddingRight=x.paddingRight||0,M.paddingBottom=x.paddingBottom||0,M.paddingTop=x.paddingTop||0,a.idToDummyNode[G]=M;var U=a.getGraphManager().add(a.newGraph(),M),b=x.getChild();b.add(M);for(var F=0;F<d[R].length;F++){var S=d[R][F];b.remove(S),U.add(S)}}})},E.prototype.clearCompounds=function(){var a={},d={};this.performDFSOnCompounds();for(var l=0;l<this.compoundOrder.length;l++)d[this.compoundOrder[l].id]=this.compoundOrder[l],a[this.compoundOrder[l].id]=[].concat(this.compoundOrder[l].getChild().getNodes()),this.graphManager.remove(this.compoundOrder[l].getChild()),this.compoundOrder[l].child=null;this.graphManager.resetAllNodes(),this.tileCompoundMembers(a,d)},E.prototype.clearZeroDegreeMembers=function(){var a=this,d=this.tiledZeroDegreePack=[];Object.keys(this.memberGroups).forEach(function(l){var v=a.idToDummyNode[l];d[l]=a.tileNodes(a.memberGroups[l],v.paddingLeft+v.paddingRight),v.rect.width=d[l].width,v.rect.height=d[l].height})},E.prototype.repopulateCompounds=function(){for(var a=this.compoundOrder.length-1;a>=0;a--){var d=this.compoundOrder[a],l=d.id,v=d.paddingLeft,_=d.paddingTop;this.adjustLocations(this.tiledMemberPack[l],d.rect.x,d.rect.y,v,_)}},E.prototype.repopulateZeroDegreeMembers=function(){var a=this,d=this.tiledZeroDegreePack;Object.keys(d).forEach(function(l){var v=a.idToDummyNode[l],_=v.paddingLeft,D=v.paddingTop;a.adjustLocations(d[l],v.rect.x,v.rect.y,_,D)})},E.prototype.getToBeTiled=function(a){var d=a.id;if(this.toBeTiled[d]!=null)return this.toBeTiled[d];var l=a.getChild();if(l==null)return this.toBeTiled[d]=!1,!1;for(var v=l.getNodes(),_=0;_<v.length;_++){var D=v[_];if(this.getNodeDegree(D)>0)return this.toBeTiled[d]=!1,!1;if(D.getChild()==null){this.toBeTiled[D.id]=!1;continue}if(!this.getToBeTiled(D))return this.toBeTiled[d]=!1,!1}return this.toBeTiled[d]=!0,!0},E.prototype.getNodeDegree=function(a){a.id;for(var d=a.getEdges(),l=0,v=0;v<d.length;v++){var _=d[v];_.getSource().id!==_.getTarget().id&&(l+=1)}return l},E.prototype.getNodeDegreeWithChildren=function(a){var d=this.getNodeDegree(a);if(a.getChild()==null)return d;for(var l=a.getChild().getNodes(),v=0;v<l.length;v++){var _=l[v];d+=this.getNodeDegreeWithChildren(_)}return d},E.prototype.performDFSOnCompounds=function(){this.compoundOrder=[],this.fillCompexOrderByDFS(this.graphManager.getRoot().getNodes())},E.prototype.fillCompexOrderByDFS=function(a){for(var d=0;d<a.length;d++){var l=a[d];l.getChild()!=null&&this.fillCompexOrderByDFS(l.getChild().getNodes()),this.getToBeTiled(l)&&this.compoundOrder.push(l)}},E.prototype.adjustLocations=function(a,d,l,v,_){d+=v,l+=_;for(var D=d,I=0;I<a.rows.length;I++){var w=a.rows[I];d=D;for(var R=0,G=0;G<w.length;G++){var x=w[G];x.rect.x=d,x.rect.y=l,d+=x.rect.width+a.horizontalPadding,x.rect.height>R&&(R=x.rect.height)}l+=R+a.verticalPadding}},E.prototype.tileCompoundMembers=function(a,d){var l=this;this.tiledMemberPack=[],Object.keys(a).forEach(function(v){var _=d[v];l.tiledMemberPack[v]=l.tileNodes(a[v],_.paddingLeft+_.paddingRight),_.rect.width=l.tiledMemberPack[v].width,_.rect.height=l.tiledMemberPack[v].height})},E.prototype.tileNodes=function(a,d){var l={rows:[],rowWidth:[],rowHeight:[],width:0,height:d,verticalPadding:o.TILING_PADDING_VERTICAL,horizontalPadding:o.TILING_PADDING_HORIZONTAL};a.sort(function(D,I){return D.rect.width*D.rect.height>I.rect.width*I.rect.height?-1:D.rect.width*D.rect.height<I.rect.width*I.rect.height?1:0});for(var v=0;v<a.length;v++){var _=a[v];l.rows.length==0?this.insertNodeToRow(l,_,0,d):this.canAddHorizontal(l,_.rect.width,_.rect.height)?this.insertNodeToRow(l,_,this.getShortestRowIndex(l),d):this.insertNodeToRow(l,_,l.rows.length,d),this.shiftToLastRow(l)}return l},E.prototype.insertNodeToRow=function(a,d,l,v){var _=v;l==a.rows.length&&(a.rows.push([]),a.rowWidth.push(_),a.rowHeight.push(0));var D=a.rowWidth[l]+d.rect.width;a.rows[l].length>0&&(D+=a.horizontalPadding),a.rowWidth[l]=D,a.width<D&&(a.width=D);var I=d.rect.height;l>0&&(I+=a.verticalPadding);var w=0;I>a.rowHeight[l]&&(w=a.rowHeight[l],a.rowHeight[l]=I,w=a.rowHeight[l]-w),a.height+=w,a.rows[l].push(d)},E.prototype.getShortestRowIndex=function(a){for(var d=-1,l=Number.MAX_VALUE,v=0;v<a.rows.length;v++)a.rowWidth[v]<l&&(d=v,l=a.rowWidth[v]);return d},E.prototype.getLongestRowIndex=function(a){for(var d=-1,l=Number.MIN_VALUE,v=0;v<a.rows.length;v++)a.rowWidth[v]>l&&(d=v,l=a.rowWidth[v]);return d},E.prototype.canAddHorizontal=function(a,d,l){var v=this.getShortestRowIndex(a);if(v<0)return!0;var _=a.rowWidth[v];if(_+a.horizontalPadding+d<=a.width)return!0;var D=0;a.rowHeight[v]<l&&v>0&&(D=l+a.verticalPadding-a.rowHeight[v]);var I=a.width-_>=d+a.horizontalPadding?(a.height+D)/(_+d+a.horizontalPadding):(a.height+D)/a.width;D=l+a.verticalPadding;var w=a.width<d?(a.height+D)/d:(a.height+D)/a.width;return w<1&&(w=1/w),I<1&&(I=1/I),I<w},E.prototype.shiftToLastRow=function(a){var d=this.getLongestRowIndex(a),l=a.rowWidth.length-1,v=a.rows[d],_=v[v.length-1],D=_.width+a.horizontalPadding;if(a.width-a.rowWidth[l]>D&&d!=l){v.splice(-1,1),a.rows[l].push(_),a.rowWidth[d]=a.rowWidth[d]-D,a.rowWidth[l]=a.rowWidth[l]+D,a.width=a.rowWidth[instance.getLongestRowIndex(a)];for(var I=Number.MIN_VALUE,w=0;w<v.length;w++)v[w].height>I&&(I=v[w].height);d>0&&(I+=a.verticalPadding);var R=a.rowHeight[d]+a.rowHeight[l];a.rowHeight[d]=I,a.rowHeight[l]<_.height+a.verticalPadding&&(a.rowHeight[l]=_.height+a.verticalPadding);var G=a.rowHeight[d]+a.rowHeight[l];a.height+=G-R,this.shiftToLastRow(a)}},E.prototype.tilingPreLayout=function(){o.TILE&&(this.groupZeroDegreeMembers(),this.clearCompounds(),this.clearZeroDegreeMembers())},E.prototype.tilingPostLayout=function(){o.TILE&&(this.repopulateZeroDegreeMembers(),this.repopulateCompounds())},E.prototype.reduceTrees=function(){for(var a=[],d=!0,l;d;){var v=this.graphManager.getAllNodes(),_=[];d=!1;for(var D=0;D<v.length;D++)l=v[D],l.getEdges().length==1&&!l.getEdges()[0].isInterGraph&&l.getChild()==null&&(_.push([l,l.getEdges()[0],l.getOwner()]),d=!0);if(d==1){for(var I=[],w=0;w<_.length;w++)_[w][0].getEdges().length==1&&(I.push(_[w]),_[w][0].getOwner().remove(_[w][0]));a.push(I),this.graphManager.resetAllNodes(),this.graphManager.resetAllEdges()}}this.prunedNodesAll=a},E.prototype.growTree=function(a){for(var d=a[a.length-1],l,v=0;v<d.length;v++)l=d[v],this.findPlaceforPrunedNode(l),l[2].add(l[0]),l[2].add(l[1],l[1].source,l[1].target);a.splice(a.length-1,1),this.graphManager.resetAllNodes(),this.graphManager.resetAllEdges()},E.prototype.findPlaceforPrunedNode=function(a){var d,l,v=a[0];l=v==a[1].source?a[1].target:a[1].source;var _=l.startX,D=l.finishX,I=l.startY,w=l.finishY,R=[0,0,0,0];if(I>0)for(var G=_;G<=D;G++)R[0]+=this.grid[G][I-1].length+this.grid[G][I].length-1;if(D<this.grid.length-1)for(var G=I;G<=w;G++)R[1]+=this.grid[D+1][G].length+this.grid[D][G].length-1;if(w<this.grid[0].length-1)for(var G=_;G<=D;G++)R[2]+=this.grid[G][w+1].length+this.grid[G][w].length-1;if(_>0)for(var G=I;G<=w;G++)R[3]+=this.grid[_-1][G].length+this.grid[_][G].length-1;for(var x=y.MAX_VALUE,M,U,b=0;b<R.length;b++)R[b]<x?(x=R[b],M=1,U=b):R[b]==x&&M++;if(M==3&&x==0)R[0]==0&&R[1]==0&&R[2]==0?d=1:R[0]==0&&R[1]==0&&R[3]==0?d=0:R[0]==0&&R[2]==0&&R[3]==0?d=3:R[1]==0&&R[2]==0&&R[3]==0&&(d=2);else if(M==2&&x==0){var F=Math.floor(Math.random()*2);d=R[0]==0&&R[1]==0?F==0?0:1:R[0]==0&&R[2]==0?F==0?0:2:R[0]==0&&R[3]==0?F==0?0:3:R[1]==0&&R[2]==0?F==0?1:2:R[1]==0&&R[3]==0?F==0?1:3:F==0?2:3}else if(M==4&&x==0){var F=Math.floor(Math.random()*4);d=F}else d=U;d==0?v.setCenter(l.getCenterX(),l.getCenterY()-l.getHeight()/2-N.DEFAULT_EDGE_LENGTH-v.getHeight()/2):d==1?v.setCenter(l.getCenterX()+l.getWidth()/2+N.DEFAULT_EDGE_LENGTH+v.getWidth()/2,l.getCenterY()):d==2?v.setCenter(l.getCenterX(),l.getCenterY()+l.getHeight()/2+N.DEFAULT_EDGE_LENGTH+v.getHeight()/2):v.setCenter(l.getCenterX()-l.getWidth()/2-N.DEFAULT_EDGE_LENGTH-v.getWidth()/2,l.getCenterY())},L.exports=E}),(function(L,A,n){var i={};i.layoutBase=n(0),i.CoSEConstants=n(1),i.CoSEEdge=n(2),i.CoSEGraph=n(3),i.CoSEGraphManager=n(4),i.CoSELayout=n(6),i.CoSENode=n(5),L.exports=i})])})})),at=nt(V(((C,P)=>{(function(m,L){typeof C=="object"&&typeof P=="object"?P.exports=L(Q()):typeof define=="function"&&define.amd?define(["cose-base"],L):typeof C=="object"?C.cytoscapeCoseBilkent=L(Q()):m.cytoscapeCoseBilkent=L(m.coseBase)})(C,function(m){return(function(L){var A={};function n(i){if(A[i])return A[i].exports;var t=A[i]={i,l:!1,exports:{}};return L[i].call(t.exports,t,t.exports,n),t.l=!0,t.exports}return n.m=L,n.c=A,n.i=function(i){return i},n.d=function(i,t,e){n.o(i,t)||Object.defineProperty(i,t,{configurable:!1,enumerable:!0,get:e})},n.n=function(i){var t=i&&i.__esModule?function(){return i.default}:function(){return i};return n.d(t,"a",t),t},n.o=function(i,t){return Object.prototype.hasOwnProperty.call(i,t)},n.p="",n(n.s=1)})([(function(L,A){L.exports=m}),(function(L,A,n){var i=n(0).layoutBase.LayoutConstants,t=n(0).layoutBase.FDLayoutConstants,e=n(0).CoSEConstants,r=n(0).CoSELayout,h=n(0).CoSENode,o=n(0).layoutBase.PointD,N=n(0).layoutBase.DimensionD,s={ready:function(){},stop:function(){},quality:"default",nodeDimensionsIncludeLabels:!1,refresh:30,fit:!0,padding:10,randomize:!0,nodeRepulsion:4500,idealEdgeLength:50,edgeElasticity:.45,nestingFactor:.1,gravity:.25,numIter:2500,tile:!0,animate:"end",animationDuration:500,tilingPaddingVertical:10,tilingPaddingHorizontal:10,gravityRangeCompound:1.5,gravityCompound:1,gravityRange:3.8,initialEnergyOnIncremental:.5};function g(c,f){var T={};for(var E in c)T[E]=c[E];for(var E in f)T[E]=f[E];return T}function u(c){this.options=g(s,c),p(this.options)}var p=function(c){c.nodeRepulsion!=null&&(e.DEFAULT_REPULSION_STRENGTH=t.DEFAULT_REPULSION_STRENGTH=c.nodeRepulsion),c.idealEdgeLength!=null&&(e.DEFAULT_EDGE_LENGTH=t.DEFAULT_EDGE_LENGTH=c.idealEdgeLength),c.edgeElasticity!=null&&(e.DEFAULT_SPRING_STRENGTH=t.DEFAULT_SPRING_STRENGTH=c.edgeElasticity),c.nestingFactor!=null&&(e.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=t.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=c.nestingFactor),c.gravity!=null&&(e.DEFAULT_GRAVITY_STRENGTH=t.DEFAULT_GRAVITY_STRENGTH=c.gravity),c.numIter!=null&&(e.MAX_ITERATIONS=t.MAX_ITERATIONS=c.numIter),c.gravityRange!=null&&(e.DEFAULT_GRAVITY_RANGE_FACTOR=t.DEFAULT_GRAVITY_RANGE_FACTOR=c.gravityRange),c.gravityCompound!=null&&(e.DEFAULT_COMPOUND_GRAVITY_STRENGTH=t.DEFAULT_COMPOUND_GRAVITY_STRENGTH=c.gravityCompound),c.gravityRangeCompound!=null&&(e.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=t.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=c.gravityRangeCompound),c.initialEnergyOnIncremental!=null&&(e.DEFAULT_COOLING_FACTOR_INCREMENTAL=t.DEFAULT_COOLING_FACTOR_INCREMENTAL=c.initialEnergyOnIncremental),c.quality=="draft"?i.QUALITY=0:c.quality=="proof"?i.QUALITY=2:i.QUALITY=1,e.NODE_DIMENSIONS_INCLUDE_LABELS=t.NODE_DIMENSIONS_INCLUDE_LABELS=i.NODE_DIMENSIONS_INCLUDE_LABELS=c.nodeDimensionsIncludeLabels,e.DEFAULT_INCREMENTAL=t.DEFAULT_INCREMENTAL=i.DEFAULT_INCREMENTAL=!c.randomize,e.ANIMATE=t.ANIMATE=i.ANIMATE=c.animate,e.TILE=c.tile,e.TILING_PADDING_VERTICAL=typeof c.tilingPaddingVertical=="function"?c.tilingPaddingVertical.call():c.tilingPaddingVertical,e.TILING_PADDING_HORIZONTAL=typeof c.tilingPaddingHorizontal=="function"?c.tilingPaddingHorizontal.call():c.tilingPaddingHorizontal};u.prototype.run=function(){var c,f,T=this.options;this.idToLNode={};var E=this.layout=new r,O=this;O.stopped=!1,this.cy=this.options.cy,this.cy.trigger({type:"layoutstart",layout:this});var a=E.newGraphManager();this.gm=a;var d=this.options.eles.nodes(),l=this.options.eles.edges();this.root=a.addRoot(),this.processChildrenList(this.root,this.getTopMostNodes(d),E);for(var v=0;v<l.length;v++){var _=l[v],D=this.idToLNode[_.data("source")],I=this.idToLNode[_.data("target")];if(D!==I&&D.getEdgesBetween(I).length==0){var w=a.add(E.newEdge(),D,I);w.id=_.id()}}var R=function(x,M){typeof x=="number"&&(x=M);var U=x.data("id"),b=O.idToLNode[U];return{x:b.getRect().getCenterX(),y:b.getRect().getCenterY()}},G=function x(){for(var M=function(){T.fit&&T.cy.fit(T.eles,T.padding),c||(c=!0,O.cy.one("layoutready",T.ready),O.cy.trigger({type:"layoutready",layout:O}))},U=O.options.refresh,b,F=0;F<U&&!b;F++)b=O.stopped||O.layout.tick();if(b){E.checkLayoutSuccess()&&!E.isSubLayout&&E.doPostLayout(),E.tilingPostLayout&&E.tilingPostLayout(),E.isLayoutFinished=!0,O.options.eles.nodes().positions(R),M(),O.cy.one("layoutstop",O.options.stop),O.cy.trigger({type:"layoutstop",layout:O}),f&&cancelAnimationFrame(f),c=!1;return}var S=O.layout.getPositionsData();T.eles.nodes().positions(function(Y,X){if(typeof Y=="number"&&(Y=X),!Y.isParent()){for(var W=Y.id(),B=S[W],H=Y;B==null&&(B=S[H.data("parent")]||S["DummyCompound_"+H.data("parent")],S[W]=B,H=H.parent()[0],H!=null););return B==null?{x:Y.position("x"),y:Y.position("y")}:{x:B.x,y:B.y}}}),M(),f=requestAnimationFrame(x)};return E.addListener("layoutstarted",function(){O.options.animate==="during"&&(f=requestAnimationFrame(G))}),E.runLayout(),this.options.animate!=="during"&&(O.options.eles.nodes().not(":parent").layoutPositions(O,O.options,R),c=!1),this},u.prototype.getTopMostNodes=function(c){for(var f={},T=0;T<c.length;T++)f[c[T].id()]=!0;return c.filter(function(E,O){typeof E=="number"&&(E=O);for(var a=E.parent()[0];a!=null;){if(f[a.id()])return!1;a=a.parent()[0]}return!0})},u.prototype.processChildrenList=function(c,f,T){for(var E=f.length,O=0;O<E;O++){var a=f[O],d=a.children(),l,v=a.layoutDimensions({nodeDimensionsIncludeLabels:this.options.nodeDimensionsIncludeLabels});if(l=a.outerWidth()!=null&&a.outerHeight()!=null?c.add(new h(T.graphManager,new o(a.position("x")-v.w/2,a.position("y")-v.h/2),new N(parseFloat(v.w),parseFloat(v.h)))):c.add(new h(this.graphManager)),l.id=a.data("id"),l.paddingLeft=parseInt(a.css("padding")),l.paddingTop=parseInt(a.css("padding")),l.paddingRight=parseInt(a.css("padding")),l.paddingBottom=parseInt(a.css("padding")),this.options.nodeDimensionsIncludeLabels&&a.isParent()){var _=a.boundingBox({includeLabels:!0,includeNodes:!1}).w,D=a.boundingBox({includeLabels:!0,includeNodes:!1}).h,I=a.css("text-halign");l.labelWidth=_,l.labelHeight=D,l.labelPos=I}if(this.idToLNode[a.data("id")]=l,isNaN(l.rect.x)&&(l.rect.x=0),isNaN(l.rect.y)&&(l.rect.y=0),d!=null&&d.length>0){var w=T.getGraphManager().add(T.newGraph(),l);this.processChildrenList(w,d,T)}}},u.prototype.stop=function(){return this.stopped=!0,this};var y=function(c){c("layout","cose-bilkent",u)};typeof cytoscape<"u"&&y(cytoscape),L.exports=y})])})}))(),1);z.use(at.default);function $(C,P){C.forEach(m=>{let L={id:m.id,labelText:m.label,height:m.height,width:m.width,padding:m.padding??0};Object.keys(m).forEach(A=>{["id","label","height","width","padding","x","y"].includes(A)||(L[A]=m[A])}),P.add({group:"nodes",data:L,position:{x:m.x??0,y:m.y??0}})})}k($,"addNodes");function K(C,P){C.forEach(m=>{let L={id:m.id,source:m.start,target:m.end};Object.keys(m).forEach(A=>{["id","start","end"].includes(A)||(L[A]=m[A])}),P.add({group:"edges",data:L})})}k(K,"addEdges");function J(C){return new Promise(P=>{let m=st("body").append("div").attr("id","cy").attr("style","display:none"),L=z({container:document.getElementById("cy"),style:[{selector:"edge",style:{"curve-style":"bezier"}}]});m.remove(),$(C.nodes,L),K(C.edges,L),L.nodes().forEach(function(A){A.layoutDimensions=()=>{let n=A.data();return{w:n.width,h:n.height}}}),L.layout({name:"cose-bilkent",quality:"proof",styleEnabled:!1,animate:!1}).run(),L.ready(A=>{j.info("Cytoscape ready",A),P(L)})})}k(J,"createCytoscapeInstance");function tt(C){return C.nodes().map(P=>{let m=P.data(),L=P.position(),A={id:m.id,x:L.x,y:L.y};return Object.keys(m).forEach(n=>{n!=="id"&&(A[n]=m[n])}),A})}k(tt,"extractPositionedNodes");function et(C){return C.edges().map(P=>{let m=P.data(),L=P._private.rscratch,A={id:m.id,source:m.source,target:m.target,startX:L.startX,startY:L.startY,midX:L.midX,midY:L.midY,endX:L.endX,endY:L.endY};return Object.keys(m).forEach(n=>{["id","source","target"].includes(n)||(A[n]=m[n])}),A})}k(et,"extractPositionedEdges");async function it(C,P){j.debug("Starting cose-bilkent layout algorithm");try{rt(C);let m=await J(C),L=tt(m),A=et(m);return j.debug(`Layout completed: ${L.length} nodes, ${A.length} edges`),{nodes:L,edges:A}}catch(m){throw j.error("Error in cose-bilkent layout algorithm:",m),m}}k(it,"executeCoseBilkentLayout");function rt(C){if(!C)throw Error("Layout data is required");if(!C.config)throw Error("Configuration is required in layout data");if(!C.rootNode)throw Error("Root node is required");if(!C.nodes||!Array.isArray(C.nodes))throw Error("No nodes found in layout data");if(!Array.isArray(C.edges))throw Error("Edges array is required in layout data");return!0}k(rt,"validateLayoutData");var ht=k(async(C,P,{insertCluster:m,insertEdge:L,insertEdgeLabel:A,insertMarkers:n,insertNode:i,log:t,positionEdgeLabel:e},{algorithm:r})=>{let h={},o={},N=P.select("g");n(N,C.markers,C.type,C.diagramId);let s=N.insert("g").attr("class","subgraphs"),g=N.insert("g").attr("class","edgePaths"),u=N.insert("g").attr("class","edgeLabels"),p=N.insert("g").attr("class","nodes");t.debug("Inserting nodes into DOM for dimension calculation"),await Promise.all(C.nodes.map(async c=>{if(c.isGroup){let f={...c};o[c.id]=f,h[c.id]=f,await m(s,c)}else{let f={...c};h[c.id]=f;let T=await i(p,c,{config:C.config,dir:C.direction||"TB"}),E=T.node().getBBox();f.width=E.width,f.height=E.height,f.domId=T,t.debug(`Node ${c.id} dimensions: ${E.width}x${E.height}`)}})),t.debug("Running cose-bilkent layout algorithm");let y=await it({...C,nodes:C.nodes.map(c=>{let f=h[c.id];return{...c,width:f.width,height:f.height}})},C.config);t.debug("Positioning nodes based on layout results"),y.nodes.forEach(c=>{let f=h[c.id];f!=null&&f.domId&&(f.domId.attr("transform",`translate(${c.x}, ${c.y})`),f.x=c.x,f.y=c.y,t.debug(`Positioned node ${f.id} at center (${c.x}, ${c.y})`))}),y.edges.forEach(c=>{let f=C.edges.find(T=>T.id===c.id);f&&(f.points=[{x:c.startX,y:c.startY},{x:c.midX,y:c.midY},{x:c.endX,y:c.endY}])}),t.debug("Inserting and positioning edges"),await Promise.all(C.edges.map(async c=>{await A(u,c);let f=h[c.start??""],T=h[c.end??""];if(f&&T){let E=y.edges.find(O=>O.id===c.id);if(E){t.debug("APA01 positionedEdge",E);let O={...c};e(O,L(g,O,o,C.type,f,T,C.diagramId))}else{let O={...c,points:[{x:f.x||0,y:f.y||0},{x:T.x||0,y:T.y||0}]};e(O,L(g,O,o,C.type,f,T,C.diagramId))}}})),t.debug("Cose-bilkent rendering completed")},"render");export{ht as render};
@@ -0,0 +1 @@
1
+ import{t as r}from"./crystal-BQ8grXRY.js";export{r as crystal};
@@ -1 +1 @@
1
- import{a as s,i as a,n as r,o,r as e,t}from"./css-CU1K_XUx.js";export{t as css,r as gss,e as keywords,a as less,s as mkCSS,o as sCSS};
1
+ import{a as s,i as a,n as r,o,r as e,t}from"./css-Bmqfl4iE.js";export{t as css,r as gss,e as keywords,a as less,s as mkCSS,o as sCSS};
@@ -0,0 +1 @@
1
+ import{t as r}from"./cypher-BKXIqXpT.js";export{r as cypher};
@@ -0,0 +1 @@
1
+ import{t as o}from"./d-DRfFJaS4.js";export{o as d};
@@ -1,4 +1,4 @@
1
- import{n as C,t as D}from"./graphlib-B4SLw_H3.js";import{t as F}from"./clone-bEECh4rs.js";import{t as L}from"./dagre-DFula7I5.js";import{i as O}from"./min-Ci3LzCQg.js";import"./purify.es-DNVQZNFu.js";import"./src-Cf4NnJCp.js";import"./chunk-S3R3BYOJ-DgPGJLrA.js";import{n as w,r as t}from"./src-BKLwm2RN.js";import{b as M}from"./chunk-ABZYJK2D-t8l6Viza.js";import"./chunk-HN2XXSSU-Bw_9WyjM.js";import{t as j}from"./chunk-CVBHYZKI-CsebuiSO.js";import"./chunk-ATLVNIR6-VxibvAOV.js";import"./dist-C04_12Dz.js";import"./chunk-JA3XYJ7Z-CaauVIYw.js";import{a as Y,c as k,i as H,l as _,n as z,t as q,u as K}from"./chunk-JZLCHNYA-cYgsW1_e.js";import{a as Q,i as U,n as V,r as W,t as Z}from"./chunk-QXUST7PY-CUUVFKsm.js";function X(e){var r={options:{directed:e.isDirected(),multigraph:e.isMultigraph(),compound:e.isCompound()},nodes:$(e),edges:ee(e)};return C(e.graph())||(r.value=F(e.graph())),r}function $(e){return O(e.nodes(),function(r){var n=e.node(r),d=e.parent(r),o={v:r};return C(n)||(o.value=n),C(d)||(o.parent=d),o})}function ee(e){return O(e.edges(),function(r){var n=e.edge(r),d={v:r.v,w:r.w};return C(r.name)||(d.name=r.name),C(n)||(d.value=n),d})}var c=new Map,b=new Map,G=new Map,ne=w(()=>{b.clear(),G.clear(),c.clear()},"clear"),I=w((e,r)=>{let n=b.get(r)||[];return t.trace("In isDescendant",r," ",e," = ",n.includes(e)),n.includes(e)},"isDescendant"),re=w((e,r)=>{let n=b.get(r)||[];return t.info("Descendants of ",r," is ",n),t.info("Edge is ",e),e.v===r||e.w===r?!1:n?n.includes(e.v)||I(e.v,r)||I(e.w,r)||n.includes(e.w):(t.debug("Tilt, ",r,",not in descendants"),!1)},"edgeInCluster"),P=w((e,r,n,d)=>{t.warn("Copying children of ",e,"root",d,"data",r.node(e),d);let o=r.children(e)||[];e!==d&&o.push(e),t.warn("Copying (nodes) clusterId",e,"nodes",o),o.forEach(l=>{if(r.children(l).length>0)P(l,r,n,d);else{let i=r.node(l);t.info("cp ",l," to ",d," with parent ",e),n.setNode(l,i),d!==r.parent(l)&&(t.warn("Setting parent",l,r.parent(l)),n.setParent(l,r.parent(l))),e!==d&&l!==e?(t.debug("Setting parent",l,e),n.setParent(l,e)):(t.info("In copy ",e,"root",d,"data",r.node(e),d),t.debug("Not Setting parent for node=",l,"cluster!==rootId",e!==d,"node!==clusterId",l!==e));let s=r.edges(l);t.debug("Copying Edges",s),s.forEach(f=>{t.info("Edge",f);let E=r.edge(f.v,f.w,f.name);t.info("Edge data",E,d);try{re(f,d)?(t.info("Copying as ",f.v,f.w,E,f.name),n.setEdge(f.v,f.w,E,f.name),t.info("newGraph edges ",n.edges(),n.edge(n.edges()[0]))):t.info("Skipping copy of edge ",f.v,"-->",f.w," rootId: ",d," clusterId:",e)}catch(N){t.error(N)}})}t.debug("Removing node",l),r.removeNode(l)})},"copy"),B=w((e,r)=>{let n=r.children(e),d=[...n];for(let o of n)G.set(o,e),d=[...d,...B(o,r)];return d},"extractDescendants"),ae=w((e,r,n)=>{let d=e.edges().filter(s=>s.v===r||s.w===r),o=e.edges().filter(s=>s.v===n||s.w===n),l=d.map(s=>({v:s.v===r?n:s.v,w:s.w===r?r:s.w})),i=o.map(s=>({v:s.v,w:s.w}));return l.filter(s=>i.some(f=>s.v===f.v&&s.w===f.w))},"findCommonEdges"),S=w((e,r,n)=>{let d=r.children(e);if(t.trace("Searching children of id ",e,d),d.length<1)return e;let o;for(let l of d){let i=S(l,r,n),s=ae(r,n,i);if(i)if(s.length>0)o=i;else return i}return o},"findNonClusterChild"),T=w(e=>!c.has(e)||!c.get(e).externalConnections?e:c.has(e)?c.get(e).id:e,"getAnchorId"),te=w((e,r)=>{if(!e||r>10){t.debug("Opting out, no graph ");return}else t.debug("Opting in, graph ");e.nodes().forEach(function(n){e.children(n).length>0&&(t.warn("Cluster identified",n," Replacement id in edges: ",S(n,e,n)),b.set(n,B(n,e)),c.set(n,{id:S(n,e,n),clusterData:e.node(n)}))}),e.nodes().forEach(function(n){let d=e.children(n),o=e.edges();d.length>0?(t.debug("Cluster identified",n,b),o.forEach(l=>{I(l.v,n)^I(l.w,n)&&(t.warn("Edge: ",l," leaves cluster ",n),t.warn("Descendants of XXX ",n,": ",b.get(n)),c.get(n).externalConnections=!0)})):t.debug("Not a cluster ",n,b)});for(let n of c.keys()){let d=c.get(n).id,o=e.parent(d);o!==n&&c.has(o)&&!c.get(o).externalConnections&&(c.get(n).id=o)}e.edges().forEach(function(n){let d=e.edge(n);t.warn("Edge "+n.v+" -> "+n.w+": "+JSON.stringify(n)),t.warn("Edge "+n.v+" -> "+n.w+": "+JSON.stringify(e.edge(n)));let o=n.v,l=n.w;if(t.warn("Fix XXX",c,"ids:",n.v,n.w,"Translating: ",c.get(n.v)," --- ",c.get(n.w)),c.get(n.v)||c.get(n.w)){if(t.warn("Fixing and trying - removing XXX",n.v,n.w,n.name),o=T(n.v),l=T(n.w),e.removeEdge(n.v,n.w,n.name),o!==n.v){let i=e.parent(o);c.get(i).externalConnections=!0,d.fromCluster=n.v}if(l!==n.w){let i=e.parent(l);c.get(i).externalConnections=!0,d.toCluster=n.w}t.warn("Fix Replacing with XXX",o,l,n.name),e.setEdge(o,l,d,n.name)}}),t.warn("Adjusted Graph",X(e)),A(e,0),t.trace(c)},"adjustClustersAndEdges"),A=w((e,r)=>{var o,l;if(t.warn("extractor - ",r,X(e),e.children("D")),r>10){t.error("Bailing out");return}let n=e.nodes(),d=!1;for(let i of n){let s=e.children(i);d||(d=s.length>0)}if(!d){t.debug("Done, no node has children",e.nodes());return}t.debug("Nodes = ",n,r);for(let i of n)if(t.debug("Extracting node",i,c,c.has(i)&&!c.get(i).externalConnections,!e.parent(i),e.node(i),e.children("D")," Depth ",r),!c.has(i))t.debug("Not a cluster",i,r);else if(!c.get(i).externalConnections&&e.children(i)&&e.children(i).length>0){t.warn("Cluster without external connections, without a parent and with children",i,r);let s=e.graph().rankdir==="TB"?"LR":"TB";(l=(o=c.get(i))==null?void 0:o.clusterData)!=null&&l.dir&&(s=c.get(i).clusterData.dir,t.warn("Fixing dir",c.get(i).clusterData.dir,s));let f=new D({multigraph:!0,compound:!0}).setGraph({rankdir:s,nodesep:50,ranksep:50,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}});t.warn("Old graph before copy",X(e)),P(i,e,f,i),e.setNode(i,{clusterNode:!0,id:i,clusterData:c.get(i).clusterData,label:c.get(i).label,graph:f}),t.warn("New graph after copy node: (",i,")",X(f)),t.debug("Old graph after copy",X(e))}else t.warn("Cluster ** ",i," **not meeting the criteria !externalConnections:",!c.get(i).externalConnections," no parent: ",!e.parent(i)," children ",e.children(i)&&e.children(i).length>0,e.children("D"),r),t.debug(c);n=e.nodes(),t.warn("New list of nodes",n);for(let i of n){let s=e.node(i);t.warn(" Now next level",i,s),s!=null&&s.clusterNode&&A(s.graph,r+1)}},"extractor"),J=w((e,r)=>{if(r.length===0)return[];let n=Object.assign([],r);return r.forEach(d=>{let o=J(e,e.children(d));n=[...n,...o]}),n},"sorter"),ie=w(e=>J(e,e.children()),"sortNodesByHierarchy"),R=w(async(e,r,n,d,o,l)=>{t.warn("Graph in recursive render:XAX",X(r),o);let i=r.graph().rankdir;t.trace("Dir in recursive render - dir:",i);let s=e.insert("g").attr("class","root");r.nodes()?t.info("Recursive render XXX",r.nodes()):t.info("No nodes found for",r),r.edges().length>0&&t.info("Recursive edges",r.edge(r.edges()[0]));let f=s.insert("g").attr("class","clusters"),E=s.insert("g").attr("class","edgePaths"),N=s.insert("g").attr("class","edgeLabels"),p=s.insert("g").attr("class","nodes");await Promise.all(r.nodes().map(async function(g){let a=r.node(g);if(o!==void 0){let u=JSON.parse(JSON.stringify(o.clusterData));t.trace(`Setting data for parent cluster XXX
1
+ import{n as C,t as D}from"./graphlib-B4SLw_H3.js";import{t as F}from"./clone-bEECh4rs.js";import{t as L}from"./dagre-DFula7I5.js";import{i as O}from"./min-Ci3LzCQg.js";import"./purify.es-DZrAQFIu.js";import"./src-DJ8ZKoFs.js";import"./chunk-S3R3BYOJ-PVCoxQeQ.js";import{n as w,r as t}from"./src-CmKhyEBC.js";import{b as M}from"./chunk-ABZYJK2D-Coo5qi7b.js";import"./chunk-HN2XXSSU-BBxJMYrA.js";import{t as j}from"./chunk-CVBHYZKI-Brsoob-W.js";import"./chunk-ATLVNIR6-C0ULYreM.js";import"./dist-DxxvVPQH.js";import"./chunk-JA3XYJ7Z-99Y1UR46.js";import{a as Y,c as k,i as H,l as _,n as z,t as q,u as K}from"./chunk-JZLCHNYA-DRGkEV50.js";import{a as Q,i as U,n as V,r as W,t as Z}from"./chunk-QXUST7PY-_zxuSm7L.js";function X(e){var r={options:{directed:e.isDirected(),multigraph:e.isMultigraph(),compound:e.isCompound()},nodes:$(e),edges:ee(e)};return C(e.graph())||(r.value=F(e.graph())),r}function $(e){return O(e.nodes(),function(r){var n=e.node(r),d=e.parent(r),o={v:r};return C(n)||(o.value=n),C(d)||(o.parent=d),o})}function ee(e){return O(e.edges(),function(r){var n=e.edge(r),d={v:r.v,w:r.w};return C(r.name)||(d.name=r.name),C(n)||(d.value=n),d})}var c=new Map,b=new Map,G=new Map,ne=w(()=>{b.clear(),G.clear(),c.clear()},"clear"),I=w((e,r)=>{let n=b.get(r)||[];return t.trace("In isDescendant",r," ",e," = ",n.includes(e)),n.includes(e)},"isDescendant"),re=w((e,r)=>{let n=b.get(r)||[];return t.info("Descendants of ",r," is ",n),t.info("Edge is ",e),e.v===r||e.w===r?!1:n?n.includes(e.v)||I(e.v,r)||I(e.w,r)||n.includes(e.w):(t.debug("Tilt, ",r,",not in descendants"),!1)},"edgeInCluster"),P=w((e,r,n,d)=>{t.warn("Copying children of ",e,"root",d,"data",r.node(e),d);let o=r.children(e)||[];e!==d&&o.push(e),t.warn("Copying (nodes) clusterId",e,"nodes",o),o.forEach(l=>{if(r.children(l).length>0)P(l,r,n,d);else{let i=r.node(l);t.info("cp ",l," to ",d," with parent ",e),n.setNode(l,i),d!==r.parent(l)&&(t.warn("Setting parent",l,r.parent(l)),n.setParent(l,r.parent(l))),e!==d&&l!==e?(t.debug("Setting parent",l,e),n.setParent(l,e)):(t.info("In copy ",e,"root",d,"data",r.node(e),d),t.debug("Not Setting parent for node=",l,"cluster!==rootId",e!==d,"node!==clusterId",l!==e));let s=r.edges(l);t.debug("Copying Edges",s),s.forEach(f=>{t.info("Edge",f);let E=r.edge(f.v,f.w,f.name);t.info("Edge data",E,d);try{re(f,d)?(t.info("Copying as ",f.v,f.w,E,f.name),n.setEdge(f.v,f.w,E,f.name),t.info("newGraph edges ",n.edges(),n.edge(n.edges()[0]))):t.info("Skipping copy of edge ",f.v,"-->",f.w," rootId: ",d," clusterId:",e)}catch(N){t.error(N)}})}t.debug("Removing node",l),r.removeNode(l)})},"copy"),B=w((e,r)=>{let n=r.children(e),d=[...n];for(let o of n)G.set(o,e),d=[...d,...B(o,r)];return d},"extractDescendants"),ae=w((e,r,n)=>{let d=e.edges().filter(s=>s.v===r||s.w===r),o=e.edges().filter(s=>s.v===n||s.w===n),l=d.map(s=>({v:s.v===r?n:s.v,w:s.w===r?r:s.w})),i=o.map(s=>({v:s.v,w:s.w}));return l.filter(s=>i.some(f=>s.v===f.v&&s.w===f.w))},"findCommonEdges"),S=w((e,r,n)=>{let d=r.children(e);if(t.trace("Searching children of id ",e,d),d.length<1)return e;let o;for(let l of d){let i=S(l,r,n),s=ae(r,n,i);if(i)if(s.length>0)o=i;else return i}return o},"findNonClusterChild"),T=w(e=>!c.has(e)||!c.get(e).externalConnections?e:c.has(e)?c.get(e).id:e,"getAnchorId"),te=w((e,r)=>{if(!e||r>10){t.debug("Opting out, no graph ");return}else t.debug("Opting in, graph ");e.nodes().forEach(function(n){e.children(n).length>0&&(t.warn("Cluster identified",n," Replacement id in edges: ",S(n,e,n)),b.set(n,B(n,e)),c.set(n,{id:S(n,e,n),clusterData:e.node(n)}))}),e.nodes().forEach(function(n){let d=e.children(n),o=e.edges();d.length>0?(t.debug("Cluster identified",n,b),o.forEach(l=>{I(l.v,n)^I(l.w,n)&&(t.warn("Edge: ",l," leaves cluster ",n),t.warn("Descendants of XXX ",n,": ",b.get(n)),c.get(n).externalConnections=!0)})):t.debug("Not a cluster ",n,b)});for(let n of c.keys()){let d=c.get(n).id,o=e.parent(d);o!==n&&c.has(o)&&!c.get(o).externalConnections&&(c.get(n).id=o)}e.edges().forEach(function(n){let d=e.edge(n);t.warn("Edge "+n.v+" -> "+n.w+": "+JSON.stringify(n)),t.warn("Edge "+n.v+" -> "+n.w+": "+JSON.stringify(e.edge(n)));let o=n.v,l=n.w;if(t.warn("Fix XXX",c,"ids:",n.v,n.w,"Translating: ",c.get(n.v)," --- ",c.get(n.w)),c.get(n.v)||c.get(n.w)){if(t.warn("Fixing and trying - removing XXX",n.v,n.w,n.name),o=T(n.v),l=T(n.w),e.removeEdge(n.v,n.w,n.name),o!==n.v){let i=e.parent(o);c.get(i).externalConnections=!0,d.fromCluster=n.v}if(l!==n.w){let i=e.parent(l);c.get(i).externalConnections=!0,d.toCluster=n.w}t.warn("Fix Replacing with XXX",o,l,n.name),e.setEdge(o,l,d,n.name)}}),t.warn("Adjusted Graph",X(e)),A(e,0),t.trace(c)},"adjustClustersAndEdges"),A=w((e,r)=>{var o,l;if(t.warn("extractor - ",r,X(e),e.children("D")),r>10){t.error("Bailing out");return}let n=e.nodes(),d=!1;for(let i of n){let s=e.children(i);d||(d=s.length>0)}if(!d){t.debug("Done, no node has children",e.nodes());return}t.debug("Nodes = ",n,r);for(let i of n)if(t.debug("Extracting node",i,c,c.has(i)&&!c.get(i).externalConnections,!e.parent(i),e.node(i),e.children("D")," Depth ",r),!c.has(i))t.debug("Not a cluster",i,r);else if(!c.get(i).externalConnections&&e.children(i)&&e.children(i).length>0){t.warn("Cluster without external connections, without a parent and with children",i,r);let s=e.graph().rankdir==="TB"?"LR":"TB";(l=(o=c.get(i))==null?void 0:o.clusterData)!=null&&l.dir&&(s=c.get(i).clusterData.dir,t.warn("Fixing dir",c.get(i).clusterData.dir,s));let f=new D({multigraph:!0,compound:!0}).setGraph({rankdir:s,nodesep:50,ranksep:50,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}});t.warn("Old graph before copy",X(e)),P(i,e,f,i),e.setNode(i,{clusterNode:!0,id:i,clusterData:c.get(i).clusterData,label:c.get(i).label,graph:f}),t.warn("New graph after copy node: (",i,")",X(f)),t.debug("Old graph after copy",X(e))}else t.warn("Cluster ** ",i," **not meeting the criteria !externalConnections:",!c.get(i).externalConnections," no parent: ",!e.parent(i)," children ",e.children(i)&&e.children(i).length>0,e.children("D"),r),t.debug(c);n=e.nodes(),t.warn("New list of nodes",n);for(let i of n){let s=e.node(i);t.warn(" Now next level",i,s),s!=null&&s.clusterNode&&A(s.graph,r+1)}},"extractor"),J=w((e,r)=>{if(r.length===0)return[];let n=Object.assign([],r);return r.forEach(d=>{let o=J(e,e.children(d));n=[...n,...o]}),n},"sorter"),ie=w(e=>J(e,e.children()),"sortNodesByHierarchy"),R=w(async(e,r,n,d,o,l)=>{t.warn("Graph in recursive render:XAX",X(r),o);let i=r.graph().rankdir;t.trace("Dir in recursive render - dir:",i);let s=e.insert("g").attr("class","root");r.nodes()?t.info("Recursive render XXX",r.nodes()):t.info("No nodes found for",r),r.edges().length>0&&t.info("Recursive edges",r.edge(r.edges()[0]));let f=s.insert("g").attr("class","clusters"),E=s.insert("g").attr("class","edgePaths"),N=s.insert("g").attr("class","edgeLabels"),p=s.insert("g").attr("class","nodes");await Promise.all(r.nodes().map(async function(g){let a=r.node(g);if(o!==void 0){let u=JSON.parse(JSON.stringify(o.clusterData));t.trace(`Setting data for parent cluster XXX
2
2
  Node.id = `,g,`
3
3
  data=`,u.height,`
4
4
  Parent cluster`,o.height),r.setNode(o.id,u),r.parent(g)||(t.trace("Setting parent",g,o.id),r.setParent(g,o.id,u))}if(t.info("(Insert) Node XXX"+g+": "+JSON.stringify(r.node(g))),a==null?void 0:a.clusterNode){t.info("Cluster identified XBX",g,a.width,r.node(g));let{ranksep:u,nodesep:m}=r.graph();a.graph.setGraph({...a.graph.graph(),ranksep:u+25,nodesep:m});let y=await R(p,a.graph,n,d,r.node(g),l),x=y.elem;K(a,x),a.diff=y.diff||0,t.info("New compound node after recursive render XAX",g,"width",a.width,"height",a.height),_(x,a)}else r.children(g).length>0?(t.trace("Cluster - the non recursive path XBX",g,a.id,a,a.width,"Graph:",r),t.trace(S(a.id,r)),c.set(a.id,{id:S(a.id,r),node:a})):(t.trace("Node - the non recursive path XAX",g,p,r.node(g),i),await Y(p,r.node(g),{config:l,dir:i}))})),await w(async()=>{let g=r.edges().map(async function(a){let u=r.edge(a.v,a.w,a.name);t.info("Edge "+a.v+" -> "+a.w+": "+JSON.stringify(a)),t.info("Edge "+a.v+" -> "+a.w+": ",a," ",JSON.stringify(r.edge(a))),t.info("Fix",c,"ids:",a.v,a.w,"Translating: ",c.get(a.v),c.get(a.w)),await W(N,u)});await Promise.all(g)},"processEdges")(),t.info("Graph before layout:",JSON.stringify(X(r))),t.info("############################################# XXX"),t.info("### Layout ### XXX"),t.info("############################################# XXX"),L(r),t.info("Graph after layout:",JSON.stringify(X(r)));let h=0,{subGraphTitleTotalMargin:v}=j(l);return await Promise.all(ie(r).map(async function(g){var u;let a=r.node(g);if(t.info("Position XBX => "+g+": ("+a.x,","+a.y,") width: ",a.width," height: ",a.height),a==null?void 0:a.clusterNode)a.y+=v,t.info("A tainted cluster node XBX1",g,a.id,a.width,a.height,a.x,a.y,r.parent(g)),c.get(a.id).node=a,k(a);else if(r.children(g).length>0){t.info("A pure cluster node XBX1",g,a.id,a.x,a.y,a.width,a.height,r.parent(g)),a.height+=v,r.node(a.parentId);let m=(a==null?void 0:a.padding)/2||0,y=((u=a==null?void 0:a.labelBBox)==null?void 0:u.height)||0,x=y-m||0;t.debug("OffsetY",x,"labelHeight",y,"halfPadding",m),await H(f,a),c.get(a.id).node=a}else{let m=r.node(a.parentId);a.y+=v/2,t.info("A regular node XBX1 - using the padding",a.id,"parent",a.parentId,a.width,a.height,a.x,a.y,"offsetY",a.offsetY,"parent",m,m==null?void 0:m.offsetY,a),k(a)}})),r.edges().forEach(function(g){let a=r.edge(g);t.info("Edge "+g.v+" -> "+g.w+": "+JSON.stringify(a),a),a.points.forEach(u=>u.y+=v/2),Q(a,V(E,a,c,n,r.node(g.v),r.node(g.w),d))}),r.nodes().forEach(function(g){let a=r.node(g);t.info(g,a.type,a.diff),a.isGroup&&(h=a.diff)}),t.warn("Returning from recursive render XAX",s,h),{elem:s,diff:h}},"recursiveRender"),de=w(async(e,r)=>{var l,i,s,f,E,N;let n=new D({multigraph:!0,compound:!0}).setGraph({rankdir:e.direction,nodesep:((l=e.config)==null?void 0:l.nodeSpacing)||((s=(i=e.config)==null?void 0:i.flowchart)==null?void 0:s.nodeSpacing)||e.nodeSpacing,ranksep:((f=e.config)==null?void 0:f.rankSpacing)||((N=(E=e.config)==null?void 0:E.flowchart)==null?void 0:N.rankSpacing)||e.rankSpacing,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}}),d=r.select("g");U(d,e.markers,e.type,e.diagramId),z(),Z(),q(),ne(),e.nodes.forEach(p=>{n.setNode(p.id,{...p}),p.parentId&&n.setParent(p.id,p.parentId)}),t.debug("Edges:",e.edges),e.edges.forEach(p=>{if(p.start===p.end){let h=p.start,v=h+"---"+h+"---1",g=h+"---"+h+"---2",a=n.node(h);n.setNode(v,{domId:v,id:v,parentId:a.parentId,labelStyle:"",label:"",padding:0,shape:"labelRect",style:"",width:10,height:10}),n.setParent(v,a.parentId),n.setNode(g,{domId:g,id:g,parentId:a.parentId,labelStyle:"",padding:0,shape:"labelRect",label:"",style:"",width:10,height:10}),n.setParent(g,a.parentId);let u=structuredClone(p),m=structuredClone(p),y=structuredClone(p);u.label="",u.arrowTypeEnd="none",u.id=h+"-cyclic-special-1",m.arrowTypeStart="none",m.arrowTypeEnd="none",m.id=h+"-cyclic-special-mid",y.label="",a.isGroup&&(u.fromCluster=h,y.toCluster=h),y.id=h+"-cyclic-special-2",y.arrowTypeStart="none",n.setEdge(h,v,u,h+"-cyclic-special-0"),n.setEdge(v,g,m,h+"-cyclic-special-1"),n.setEdge(g,h,y,h+"-cyc<lic-special-2")}else n.setEdge(p.start,p.end,{...p},p.id)}),t.warn("Graph at first:",JSON.stringify(X(n))),te(n),t.warn("Graph after XAX:",JSON.stringify(X(n)));let o=M();await R(d,n,e.type,e.diagramId,void 0,o)},"render");export{de as render};
@@ -1 +1 @@
1
- import{s as z}from"./chunk-LvLJmgfZ.js";import{t as J}from"./react-BGmjiNul.js";import{t as Q}from"./react-dom-C9fstfnp.js";import{_ as P,i as U,n as Z,t as ee,v as te,y as re}from"./click-outside-container-BVQDdpbt.js";import{t as ie}from"./dist-CdBsAJTp.js";var ae=Q(),r=z(J(),1),ne=()=>t=>t.targetX,oe=()=>t=>t.targetY,le=()=>t=>t.targetWidth,de=()=>t=>t.targetHeight,se=()=>t=>t.targetY+10,ue=()=>t=>Math.max(0,(t.targetHeight-28)/2);const ce=ie("div")({name:"DataGridOverlayEditorStyle",class:"gdg-d19meir1",propsAsIs:!1,vars:{"d19meir1-0":[oe(),"px"],"d19meir1-1":[ne(),"px"],"d19meir1-2":[le(),"px"],"d19meir1-3":[de(),"px"],"d19meir1-4":[se(),"px"],"d19meir1-5":[ue(),"px"]}});function ge(){let[t,n]=r.useState();return[t??void 0,n]}function me(){let[t,n]=ge(),[a,f]=r.useState(0),[v,b]=r.useState(!0);return r.useLayoutEffect(()=>{if(t===void 0||!("IntersectionObserver"in window))return;let o=new IntersectionObserver(l=>{l.length!==0&&b(l[0].isIntersecting)},{threshold:1});return o.observe(t),()=>o.disconnect()},[t]),r.useEffect(()=>{if(v||t===void 0)return;let o,l=()=>{let{right:k}=t.getBoundingClientRect();f(x=>Math.min(x+window.innerWidth-k-10,0)),o=requestAnimationFrame(l)};return o=requestAnimationFrame(l),()=>{o!==void 0&&cancelAnimationFrame(o)}},[t,v]),{ref:n,style:r.useMemo(()=>({transform:`translateX(${a}px)`}),[a])}}var ve=t=>{let{target:n,content:a,onFinishEditing:f,forceEditMode:v,initialValue:b,imageEditorOverride:o,markdownDivCreateNode:l,highlight:k,className:x,theme:C,id:V,cell:w,bloom:c,validateCell:d,getCellRenderer:M,provideEditor:p,isOutsideClick:W,customEventTarget:X}=t,[s,Y]=r.useState(v?a:void 0),O=r.useRef(s??a);O.current=s??a;let[h,N]=r.useState(()=>d===void 0?!0:!(P(a)&&(d==null?void 0:d(w,a,O.current))===!1)),g=r.useCallback((e,i)=>{f(h?e:void 0,i)},[h,f]),q=r.useCallback(e=>{if(d!==void 0&&e!==void 0&&P(e)){let i=d(w,e,O.current);i===!1?N(!1):(typeof i=="object"&&(e=i),N(!0))}Y(e)},[w,d]),y=r.useRef(!1),m=r.useRef(void 0),B=r.useCallback(()=>{g(s,[0,0]),y.current=!0},[s,g]),G=r.useCallback((e,i)=>{g(e,i??m.current??[0,0]),y.current=!0},[g]),_=r.useCallback(async e=>{let i=!1;e.key==="Escape"?(e.stopPropagation(),e.preventDefault(),m.current=[0,0]):e.key==="Enter"&&!e.shiftKey?(e.stopPropagation(),e.preventDefault(),m.current=[0,1],i=!0):e.key==="Tab"&&(e.stopPropagation(),e.preventDefault(),m.current=[e.shiftKey?-1:1,0],i=!0),window.setTimeout(()=>{!y.current&&m.current!==void 0&&(g(i?s:void 0,m.current),y.current=!0)},0)},[g,s]),D=s??a,[u,j]=r.useMemo(()=>{var i,K;if(te(a))return[];let e=p==null?void 0:p(a);return e===void 0?[(K=(i=M(a))==null?void 0:i.provideEditor)==null?void 0:K.call(i,a),!1]:[e,!1]},[a,M,p]),{ref:L,style:$}=me(),R=!0,F,I=!0,E;if(u!==void 0){R=u.disablePadding!==!0,I=u.disableStyling!==!0;let e=re(u);e&&(E=u.styleOverride);let i=e?u.editor:u;F=r.createElement(i,{isHighlighted:k,onChange:q,value:D,initialValue:b,onFinishedEditing:G,validatedSelection:P(D)?D.selectionRange:void 0,forceEditMode:v,target:n,imageEditorOverride:o,markdownDivCreateNode:l,isValid:h,theme:C})}E={...E,...$};let A=document.getElementById("portal");if(A===null)return console.error('Cannot open Data Grid overlay editor, because portal not found. Please add `<div id="portal" />` as the last child of your `<body>`.'),null;let S=I?"gdg-style":"gdg-unstyle";h||(S+=" gdg-invalid"),R&&(S+=" gdg-pad");let H=(c==null?void 0:c[0])??1,T=(c==null?void 0:c[1])??1;return(0,ae.createPortal)(r.createElement(Z.Provider,{value:C},r.createElement(ee,{style:U(C),className:x,onClickOutside:B,isOutsideClick:W,customEventTarget:X},r.createElement(ce,{ref:L,id:V,className:S,style:E,as:j===!0?"label":void 0,targetX:n.x-H,targetY:n.y-T,targetWidth:n.width+H*2,targetHeight:n.height+T*2},r.createElement("div",{className:"gdg-clip-region",onKeyDown:_},F)))),A)};export{ve as default};
1
+ import{s as z}from"./chunk-LvLJmgfZ.js";import{t as J}from"./react-BGmjiNul.js";import{t as Q}from"./react-dom-C9fstfnp.js";import{_ as P,i as U,n as Z,t as ee,v as te,y as re}from"./click-outside-container-B12FHFHm.js";import{t as ie}from"./dist-BhLw_JdQ.js";var ae=Q(),r=z(J(),1),ne=()=>t=>t.targetX,oe=()=>t=>t.targetY,le=()=>t=>t.targetWidth,de=()=>t=>t.targetHeight,se=()=>t=>t.targetY+10,ue=()=>t=>Math.max(0,(t.targetHeight-28)/2);const ce=ie("div")({name:"DataGridOverlayEditorStyle",class:"gdg-d19meir1",propsAsIs:!1,vars:{"d19meir1-0":[oe(),"px"],"d19meir1-1":[ne(),"px"],"d19meir1-2":[le(),"px"],"d19meir1-3":[de(),"px"],"d19meir1-4":[se(),"px"],"d19meir1-5":[ue(),"px"]}});function ge(){let[t,n]=r.useState();return[t??void 0,n]}function me(){let[t,n]=ge(),[a,f]=r.useState(0),[v,b]=r.useState(!0);return r.useLayoutEffect(()=>{if(t===void 0||!("IntersectionObserver"in window))return;let o=new IntersectionObserver(l=>{l.length!==0&&b(l[0].isIntersecting)},{threshold:1});return o.observe(t),()=>o.disconnect()},[t]),r.useEffect(()=>{if(v||t===void 0)return;let o,l=()=>{let{right:k}=t.getBoundingClientRect();f(x=>Math.min(x+window.innerWidth-k-10,0)),o=requestAnimationFrame(l)};return o=requestAnimationFrame(l),()=>{o!==void 0&&cancelAnimationFrame(o)}},[t,v]),{ref:n,style:r.useMemo(()=>({transform:`translateX(${a}px)`}),[a])}}var ve=t=>{let{target:n,content:a,onFinishEditing:f,forceEditMode:v,initialValue:b,imageEditorOverride:o,markdownDivCreateNode:l,highlight:k,className:x,theme:C,id:V,cell:w,bloom:c,validateCell:d,getCellRenderer:M,provideEditor:p,isOutsideClick:W,customEventTarget:X}=t,[s,Y]=r.useState(v?a:void 0),O=r.useRef(s??a);O.current=s??a;let[h,N]=r.useState(()=>d===void 0?!0:!(P(a)&&(d==null?void 0:d(w,a,O.current))===!1)),g=r.useCallback((e,i)=>{f(h?e:void 0,i)},[h,f]),q=r.useCallback(e=>{if(d!==void 0&&e!==void 0&&P(e)){let i=d(w,e,O.current);i===!1?N(!1):(typeof i=="object"&&(e=i),N(!0))}Y(e)},[w,d]),y=r.useRef(!1),m=r.useRef(void 0),B=r.useCallback(()=>{g(s,[0,0]),y.current=!0},[s,g]),G=r.useCallback((e,i)=>{g(e,i??m.current??[0,0]),y.current=!0},[g]),_=r.useCallback(async e=>{let i=!1;e.key==="Escape"?(e.stopPropagation(),e.preventDefault(),m.current=[0,0]):e.key==="Enter"&&!e.shiftKey?(e.stopPropagation(),e.preventDefault(),m.current=[0,1],i=!0):e.key==="Tab"&&(e.stopPropagation(),e.preventDefault(),m.current=[e.shiftKey?-1:1,0],i=!0),window.setTimeout(()=>{!y.current&&m.current!==void 0&&(g(i?s:void 0,m.current),y.current=!0)},0)},[g,s]),D=s??a,[u,j]=r.useMemo(()=>{var i,K;if(te(a))return[];let e=p==null?void 0:p(a);return e===void 0?[(K=(i=M(a))==null?void 0:i.provideEditor)==null?void 0:K.call(i,a),!1]:[e,!1]},[a,M,p]),{ref:L,style:$}=me(),R=!0,F,I=!0,E;if(u!==void 0){R=u.disablePadding!==!0,I=u.disableStyling!==!0;let e=re(u);e&&(E=u.styleOverride);let i=e?u.editor:u;F=r.createElement(i,{isHighlighted:k,onChange:q,value:D,initialValue:b,onFinishedEditing:G,validatedSelection:P(D)?D.selectionRange:void 0,forceEditMode:v,target:n,imageEditorOverride:o,markdownDivCreateNode:l,isValid:h,theme:C})}E={...E,...$};let A=document.getElementById("portal");if(A===null)return console.error('Cannot open Data Grid overlay editor, because portal not found. Please add `<div id="portal" />` as the last child of your `<body>`.'),null;let S=I?"gdg-style":"gdg-unstyle";h||(S+=" gdg-invalid"),R&&(S+=" gdg-pad");let H=(c==null?void 0:c[0])??1,T=(c==null?void 0:c[1])??1;return(0,ae.createPortal)(r.createElement(Z.Provider,{value:C},r.createElement(ee,{style:U(C),className:x,onClickOutside:B,isOutsideClick:W,customEventTarget:X},r.createElement(ce,{ref:L,id:V,className:S,style:E,as:j===!0?"label":void 0,targetX:n.x-H,targetY:n.y-T,targetWidth:n.width+H*2,targetHeight:n.height+T*2},r.createElement("div",{className:"gdg-clip-region",onKeyDown:_},F)))),A)};export{ve as default};
@@ -1,3 +1,3 @@
1
- var x=Object.defineProperty;var A=(r,e,n)=>e in r?x(r,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):r[e]=n;var l=(r,e,n)=>A(r,typeof e!="symbol"?e+"":e,n);import{i as m}from"./useEvent-DO6uJBas.js";import{Ct as I,Dn as E,Mn as T,Yr as C,gr as p,hi as M,ir as w,n as L,rr as O}from"./cells-BpZ7g6ok.js";import{d as $}from"./hotkeys-BHHWjLlp.js";import{t as P}from"./createLucideIcon-CnW3RofX.js";import{t as R}from"./multi-map-C8GlnP-4.js";var D=P("wrench",[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z",key:"1ngwbx"}]]),u,c;function S(r,e,n,a,i){var t={};return Object.keys(a).forEach(function(s){t[s]=a[s]}),t.enumerable=!!t.enumerable,t.configurable=!!t.configurable,("value"in t||t.initializer)&&(t.writable=!0),t=n.slice().reverse().reduce(function(s,o){return o(r,e,s)||s},t),i&&t.initializer!==void 0&&(t.value=t.initializer?t.initializer.call(i):void 0,t.initializer=void 0),t.initializer===void 0?(Object.defineProperty(r,e,t),null):t}var d=class{async getAttachments(r){return[]}asURI(r){return`${this.contextType}://${r}`}parseContextIds(r){let e=RegExp(`${this.mentionPrefix}([\\w-]+):\\/\\/([\\w./-]+)`,"g"),n=[...r.matchAll(e)],a=t=>t.slice(1),i=n.filter(([,t])=>t===this.contextType).map(([t])=>a(t));return[...new Set(i)]}createBasicCompletion(r,e){return{label:`${this.mentionPrefix}${r.uri.split("://")[1]}`,displayLabel:r.name,detail:(e==null?void 0:e.detail)||r.description,boost:(e==null?void 0:e.boost)||1,type:(e==null?void 0:e.type)||this.contextType,apply:`${this.mentionPrefix}${r.uri}`,section:(e==null?void 0:e.section)||this.title}}};let U=(u=C(),c=class{constructor(){l(this,"providers",new Set)}register(r){return this.providers.add(r),this}getProviders(){return this.providers}getProvider(r){return[...this.providers].find(e=>e.contextType===r)}getAllItems(){return[...this.providers].flatMap(r=>r.getItems())}parseAllContextIds(r){return[...this.providers].flatMap(e=>e.parseContextIds(r))}getContextInfo(r){let e=[],n=new Map(this.getAllItems().map(a=>[a.uri,a]));for(let a of r){let i=n.get(a);i&&e.push(i)}return e}formatContextForAI(r){let e=new Map(this.getAllItems().map(a=>[a.uri,a])),n=[];for(let a of r){let i=e.get(a);i&&n.push(i)}return n.length===0?"":n.map(a=>{var i;return((i=this.getProvider(a.type))==null?void 0:i.formatContext(a))||""}).join(`
1
+ var x=Object.defineProperty;var A=(r,e,n)=>e in r?x(r,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):r[e]=n;var l=(r,e,n)=>A(r,typeof e!="symbol"?e+"":e,n);import{i as m}from"./useEvent-DO6uJBas.js";import{An as I,Ct as T,Tn as E,mr as p,n as C,nr as w,pi as L,qr as M,tr as O}from"./cells-BcMpgRWV.js";import{d as $}from"./hotkeys-BHHWjLlp.js";import{t as P}from"./createLucideIcon-CnW3RofX.js";import{t as R}from"./multi-map-W4zci54U.js";var S=P("wrench",[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z",key:"1ngwbx"}]]),u,c;function U(r,e,n,a,i){var t={};return Object.keys(a).forEach(function(s){t[s]=a[s]}),t.enumerable=!!t.enumerable,t.configurable=!!t.configurable,("value"in t||t.initializer)&&(t.writable=!0),t=n.slice().reverse().reduce(function(s,o){return o(r,e,s)||s},t),i&&t.initializer!==void 0&&(t.value=t.initializer?t.initializer.call(i):void 0,t.initializer=void 0),t.initializer===void 0?(Object.defineProperty(r,e,t),null):t}var d=class{async getAttachments(r){return[]}asURI(r){return`${this.contextType}://${r}`}parseContextIds(r){let e=RegExp(`${this.mentionPrefix}([\\w-]+):\\/\\/([\\w./-]+)`,"g"),n=[...r.matchAll(e)],a=t=>t.slice(1),i=n.filter(([,t])=>t===this.contextType).map(([t])=>a(t));return[...new Set(i)]}createBasicCompletion(r,e){return{label:`${this.mentionPrefix}${r.uri.split("://")[1]}`,displayLabel:r.name,detail:(e==null?void 0:e.detail)||r.description,boost:(e==null?void 0:e.boost)||1,type:(e==null?void 0:e.type)||this.contextType,apply:`${this.mentionPrefix}${r.uri}`,section:(e==null?void 0:e.section)||this.title}}};let D=(u=M(),c=class{constructor(){l(this,"providers",new Set)}register(r){return this.providers.add(r),this}getProviders(){return this.providers}getProvider(r){return[...this.providers].find(e=>e.contextType===r)}getAllItems(){return[...this.providers].flatMap(r=>r.getItems())}parseAllContextIds(r){return[...this.providers].flatMap(e=>e.parseContextIds(r))}getContextInfo(r){let e=[],n=new Map(this.getAllItems().map(a=>[a.uri,a]));for(let a of r){let i=n.get(a);i&&e.push(i)}return e}formatContextForAI(r){let e=new Map(this.getAllItems().map(a=>[a.uri,a])),n=[];for(let a of r){let i=e.get(a);i&&n.push(i)}return n.length===0?"":n.map(a=>{var i;return((i=this.getProvider(a.type))==null?void 0:i.formatContext(a))||""}).join(`
2
2
 
3
- `)}async getAttachmentsForContext(r){let e=new Map(this.getAllItems().map(t=>[t.uri,t])),n=[];for(let t of r){let s=e.get(t);s&&n.push(s)}if(n.length===0)return[];let a=new R;for(let t of n){let s=t.type;a.add(s,t)}let i=[...a.entries()].map(async([t,s])=>{let o=this.getProvider(t);if(!o)return[];try{return await o.getAttachments(s)}catch(v){return $.error("Error getting attachments from provider",v),[]}});return(await Promise.all(i)).flat()}},S(c.prototype,"getAllItems",[u],Object.getOwnPropertyDescriptor(c.prototype,"getAllItems"),c.prototype),c);function f(r){return r.replaceAll("<","&lt;").replaceAll(">","&gt;")}function h(r){let{type:e,data:n,details:a}=r,i=`<${e}`;for(let[t,s]of Object.entries(n))if(s!==void 0){let o=f(typeof s=="object"&&s?JSON.stringify(s):String(s));i+=` ${t}="${o}"`}return i+=">",a&&(i+=f(a)),i+=`</${e}>`,i}const g={LOCAL_TABLE:7,REMOTE_TABLE:5,HIGH:4,MEDIUM:3,CELL_OUTPUT:2,LOW:2},y={ERROR:{name:"Error",rank:1},TABLE:{name:"Table",rank:2},DATA_SOURCES:{name:"Data Sources",rank:3},VARIABLE:{name:"Variable",rank:4},CELL_OUTPUT:{name:"Cell Output",rank:5},FILE:{name:"File",rank:6}};var _=M(),b="datasource",k=class extends d{constructor(e,n){super();l(this,"title","Datasource");l(this,"mentionPrefix","@");l(this,"contextType",b);this.connectionsMap=e,this.dataframes=[...n.values()].filter(a=>w(a)==="dataframe")}getItems(){return[...this.connectionsMap.values()].map(e=>{var i;let n="Database schema.",a={connection:e};return p.has(e.name)&&(a.tables=this.dataframes,n="Database schema and the dataframes that can be queried"),e.databases.length===0&&(((i=a.tables)==null?void 0:i.length)??0)===0?null:{uri:this.asURI(e.name),name:e.name,description:n,type:this.contextType,data:a}}).filter(Boolean)}formatContext(e){let n=e.data,{name:a,display_name:i,source:t,...s}=n.connection,o=s;return p.has(a)||(o={...s,engine_name:a}),h({type:this.contextType,data:{connection:o,tables:n.tables}})}formatCompletion(e){let n=e.data,a=n.connection,i=n.tables,t=a.name;return p.has(a.name)&&(t="In-Memory"),{label:`@${t}`,displayLabel:t,detail:T(a.dialect),boost:g.MEDIUM,type:this.contextType,section:y.DATA_SOURCES,info:()=>{let s=document.createElement("div");return s.classList.add("mo-cm-tooltip","docs-documentation"),(0,_.createRoot)(s).render(E(a,i)),s}}}};function z(r){var s;let e=(s=m.get(L(r)))==null?void 0:s.code;if(!e||e.trim()==="")return null;let[n,a,i]=I.sql.transformIn(e),t=m.get(O).connectionsMap.get(i.engine);return t?`@${b}://${t.name}`:null}export{h as a,D as c,y as i,z as n,d as o,g as r,U as s,k as t};
3
+ `)}async getAttachmentsForContext(r){let e=new Map(this.getAllItems().map(t=>[t.uri,t])),n=[];for(let t of r){let s=e.get(t);s&&n.push(s)}if(n.length===0)return[];let a=new R;for(let t of n){let s=t.type;a.add(s,t)}let i=[...a.entries()].map(async([t,s])=>{let o=this.getProvider(t);if(!o)return[];try{return await o.getAttachments(s)}catch(v){return $.error("Error getting attachments from provider",v),[]}});return(await Promise.all(i)).flat()}},U(c.prototype,"getAllItems",[u],Object.getOwnPropertyDescriptor(c.prototype,"getAllItems"),c.prototype),c);function f(r){return r.replaceAll("<","&lt;").replaceAll(">","&gt;")}function h(r){let{type:e,data:n,details:a}=r,i=`<${e}`;for(let[t,s]of Object.entries(n))if(s!==void 0){let o=f(typeof s=="object"&&s?JSON.stringify(s):String(s));i+=` ${t}="${o}"`}return i+=">",a&&(i+=f(a)),i+=`</${e}>`,i}const g={LOCAL_TABLE:7,REMOTE_TABLE:5,HIGH:4,MEDIUM:3,CELL_OUTPUT:2,LOW:2},y={ERROR:{name:"Error",rank:1},TABLE:{name:"Table",rank:2},DATA_SOURCES:{name:"Data Sources",rank:3},VARIABLE:{name:"Variable",rank:4},CELL_OUTPUT:{name:"Cell Output",rank:5},FILE:{name:"File",rank:6}};var _=L(),b="datasource",k=class extends d{constructor(e,n){super();l(this,"title","Datasource");l(this,"mentionPrefix","@");l(this,"contextType",b);this.connectionsMap=e,this.dataframes=[...n.values()].filter(a=>w(a)==="dataframe")}getItems(){return[...this.connectionsMap.values()].map(e=>{var i;let n="Database schema.",a={connection:e};return p.has(e.name)&&(a.tables=this.dataframes,n="Database schema and the dataframes that can be queried"),e.databases.length===0&&(((i=a.tables)==null?void 0:i.length)??0)===0?null:{uri:this.asURI(e.name),name:e.name,description:n,type:this.contextType,data:a}}).filter(Boolean)}formatContext(e){let n=e.data,{name:a,display_name:i,source:t,...s}=n.connection,o=s;return p.has(a)||(o={...s,engine_name:a}),h({type:this.contextType,data:{connection:o,tables:n.tables}})}formatCompletion(e){let n=e.data,a=n.connection,i=n.tables,t=a.name;return p.has(a.name)&&(t="In-Memory"),{label:`@${t}`,displayLabel:t,detail:I(a.dialect),boost:g.MEDIUM,type:this.contextType,section:y.DATA_SOURCES,info:()=>{let s=document.createElement("div");return s.classList.add("mo-cm-tooltip","docs-documentation"),(0,_.createRoot)(s).render(E(a,i)),s}}}};function z(r){var s;let e=(s=m.get(C(r)))==null?void 0:s.code;if(!e||e.trim()==="")return null;let[n,a,i]=T.sql.transformIn(e),t=m.get(O).connectionsMap.get(i.engine);return t?`@${b}://${t.name}`:null}export{h as a,S as c,y as i,z as n,d as o,g as r,D as s,k as t};