@kabmo-labs/kabmo 0.58.1 → 0.59.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (391) hide show
  1. package/dist/client/index.html +1 -1
  2. package/dist/client/index.js +513 -495
  3. package/dist/client/static/js/{Body-ysmhxbvk.js → Body-jqq4654r.js} +3 -3
  4. package/dist/client/static/js/{CsvGrid-w90pxyn2.js → CsvGrid-avw0taqb.js} +2 -2
  5. package/dist/client/static/js/{DocxView-evxn6kaq.js → DocxView-d221vr6g.js} +3 -3
  6. package/dist/client/static/js/{DrawioView-tmdevwf4.js → DrawioView-gjsy7p01.js} +2 -2
  7. package/dist/client/static/js/{HtmlPreview-bpsn2z9p.js → HtmlPreview-949393v1.js} +1 -1
  8. package/dist/client/static/js/ImageView-pan9pqtm.js +1 -0
  9. package/dist/client/static/js/LayoutWrapper-p0qmghgt.js +2 -0
  10. package/dist/client/static/js/MergeDiffView-swt467g7.js +1 -0
  11. package/dist/client/static/js/Modal-4spmcn44.js +60 -0
  12. package/dist/client/static/js/{PdfView-txxn6qff.js → PdfView-dzj2s6rj.js} +1 -1
  13. package/dist/client/static/js/SessionsView-b6szjdg5.js +1 -0
  14. package/dist/client/static/js/{SheetView-52b33e6f.js → SheetView-jpc178g5.js} +11 -11
  15. package/dist/client/static/js/{SvgPreview-hrk4pfm1.js → SvgPreview-94fap32p.js} +1 -1
  16. package/dist/client/static/js/{abnfDiagram-O67JEVCF-at77sybc.js → abnfDiagram-O67JEVCF-a6eyfzrj.js} +1 -1
  17. package/dist/client/static/js/architecture-7GRP2DOG-bwn1drdz.js +1 -0
  18. package/dist/client/static/js/{architectureDiagram-NJMV4G6O-raw33jgg.js → architectureDiagram-NJMV4G6O-pgmyfncy.js} +3 -3
  19. package/dist/client/static/js/{astro-qha7sceh.js → astro-ryr2ajmg.js} +1 -1
  20. package/dist/client/static/js/bash-zknkkwkw.js +1 -0
  21. package/dist/client/static/js/{blockDiagram-BEXU5L5S-b6e90fbk.js → blockDiagram-BEXU5L5S-rf51jyb2.js} +4 -4
  22. package/dist/client/static/js/c-0w02jkxb.js +1 -0
  23. package/dist/client/static/js/{c4Diagram-YGBWAQC7-msg9y1c6.js → c4Diagram-YGBWAQC7-0faj48jp.js} +2 -2
  24. package/dist/client/static/js/{classDiagram-v2-NBCMYWYE-jmrd1h8r.js → classDiagram-v2-NBCMYWYE-bvzsws8x.js} +4 -4
  25. package/dist/client/static/js/{cose-bilkent-JH36ORCC-na65ebq3.js → cose-bilkent-JH36ORCC-j1amnd3m.js} +1 -1
  26. package/dist/client/static/js/cpp-p5b4vean.js +1 -0
  27. package/dist/client/static/js/css-9jzbvdyz.js +1 -0
  28. package/dist/client/static/js/css-sn00sq6v.js +1 -0
  29. package/dist/client/static/js/cynefin-OW5HDTMX-jbc50ks8.js +1 -0
  30. package/dist/client/static/js/{cynefinDiagram-VND7K2PF-9xkkw71m.js → cynefinDiagram-VND7K2PF-f73w6zzz.js} +2 -2
  31. package/dist/client/static/js/{dagre-6A5THRUB-p59f19tv.js → dagre-6A5THRUB-a5vgvjsg.js} +2 -2
  32. package/dist/client/static/js/{diagram-22UHCM2B-2e2rcvn7.js → diagram-22UHCM2B-6y9efamp.js} +9 -9
  33. package/dist/client/static/js/{diagram-3UASUU5V-r9ds8vgr.js → diagram-3UASUU5V-2mycy7xm.js} +1 -1
  34. package/dist/client/static/js/{diagram-ATOU4E4O-jgwxv7v8.js → diagram-ATOU4E4O-10zgjb66.js} +3 -3
  35. package/dist/client/static/js/{diagram-CDSNMT55-20m35eqq.js → diagram-CDSNMT55-bewa52yf.js} +4 -4
  36. package/dist/client/static/js/{diagram-MLGK6HIB-vt3kxt2m.js → diagram-MLGK6HIB-mh3b7gd3.js} +1 -1
  37. package/dist/client/static/js/{diagram-MPIPVDR6-c47rgxf1.js → diagram-MPIPVDR6-gvdrbdm5.js} +2 -2
  38. package/dist/client/static/js/{dockerfile-gtcyey0q.js → dockerfile-6bn19kg0.js} +1 -1
  39. package/dist/client/static/js/{ebnfDiagram-ZINNZB2B-aszw3xy3.js → ebnfDiagram-ZINNZB2B-2prre93c.js} +1 -1
  40. package/dist/client/static/js/{elixir-w92v180e.js → elixir-fyxw6d70.js} +1 -1
  41. package/dist/client/static/js/{elk-276RUBZZ-gbvr3gry.js → elk-276RUBZZ-9t6t9kc6.js} +2 -2
  42. package/dist/client/static/js/{erDiagram-OPXOYQCR-1hqca8qe.js → erDiagram-OPXOYQCR-etcggr5n.js} +6 -6
  43. package/dist/client/static/js/{erlang-v7344938.js → erlang-97ayje6m.js} +1 -1
  44. package/dist/client/static/js/eventmodeling-NTZA5JFV-b37ey01t.js +1 -0
  45. package/dist/client/static/js/flowDiagram-KWPJA3E3-7c2ncsw7.js +1 -0
  46. package/dist/client/static/js/{ganttDiagram-FUAMR5RP-07v22te5.js → ganttDiagram-FUAMR5RP-cdc4mwhs.js} +3 -3
  47. package/dist/client/static/js/gitGraph-4MIJSDKK-mvqq7tcs.js +1 -0
  48. package/dist/client/static/js/{gitGraphDiagram-X574FWY7-y068jtz9.js → gitGraphDiagram-X574FWY7-55d0fa7x.js} +8 -8
  49. package/dist/client/static/js/graphql-xzykn0ba.js +1 -0
  50. package/dist/client/static/js/html-2zc3shky.js +1 -0
  51. package/dist/client/static/js/{index-r8d4bk86.js → index-10vzyga1.js} +2 -2
  52. package/dist/client/static/js/{index-8d8ce00v.js → index-27gwghmp.js} +2 -2
  53. package/dist/client/static/js/{index-zhgh7a31.js → index-2f6afhze.js} +2 -2
  54. package/dist/client/static/js/{index-nptbz7sv.js → index-3akjcs82.js} +1 -1
  55. package/dist/client/static/js/{index-fhtnvqgf.js → index-3j2he86h.js} +2 -2
  56. package/dist/client/static/js/index-461ga40v.js +2 -0
  57. package/dist/client/static/js/{index-9qf2h9jb.js → index-51rbgeh9.js} +12 -12
  58. package/dist/client/static/js/{index-s4dpkds5.js → index-537m8a3x.js} +2 -2
  59. package/dist/client/static/js/{index-tdg7hz80.js → index-58z2hatp.js} +2 -2
  60. package/dist/client/static/js/{index-4tbdws4r.js → index-5e4e18tg.js} +2 -2
  61. package/dist/client/static/js/{index-gqrt766t.js → index-60cxxnpk.js} +61 -61
  62. package/dist/client/static/js/{index-th61y26d.js → index-69mnn71v.js} +2 -2
  63. package/dist/client/static/js/{index-e0kahttb.js → index-6bsez5n6.js} +1 -1
  64. package/dist/client/static/js/{index-gaa39w5q.js → index-8tzt0dek.js} +2 -2
  65. package/dist/client/static/js/{index-zs7kw0be.js → index-8z9aqgf3.js} +4 -4
  66. package/dist/client/static/js/{index-ewryzs4g.js → index-92h38pwg.js} +2 -2
  67. package/dist/client/static/js/{index-f61c25vn.js → index-9rvjegmy.js} +3 -3
  68. package/dist/client/static/js/{index-80kx6dm6.js → index-a3bpmw2r.js} +2 -2
  69. package/dist/client/static/js/{index-xmg1x6zv.js → index-a5ecn5yx.js} +5 -5
  70. package/dist/client/static/js/{index-azz46nwc.js → index-ax8gaayq.js} +2 -2
  71. package/dist/client/static/js/{index-wn28m9h7.js → index-c253x7vt.js} +8 -8
  72. package/dist/client/static/js/{index-y0f3wbc3.js → index-d9sfavx1.js} +2 -2
  73. package/dist/client/static/js/{index-5hvt233n.js → index-db6s66jr.js} +2 -2
  74. package/dist/client/static/js/index-eggbcdwx.js +481 -0
  75. package/dist/client/static/js/{index-e4nge3f4.js → index-f13ern5e.js} +1 -1
  76. package/dist/client/static/js/index-f6t91mpp.js +2 -0
  77. package/dist/client/static/js/{index-wxqcnsrq.js → index-fr91ghwb.js} +2 -2
  78. package/dist/client/static/js/{index-tq3t3qm4.js → index-fsa18ns9.js} +2 -2
  79. package/dist/client/static/js/{index-fv7nybnf.js → index-fyt8m8ah.js} +2 -2
  80. package/dist/client/static/js/{index-007sewcn.js → index-gcad7b6g.js} +2 -2
  81. package/dist/client/static/js/{index-rxt8sf9a.js → index-h1xbx74w.js} +2 -2
  82. package/dist/client/static/js/{index-medk4f18.js → index-j1ksa4x2.js} +2 -2
  83. package/dist/client/static/js/{index-sxag9ptg.js → index-jct0jryd.js} +2 -2
  84. package/dist/client/static/js/{index-qefssj0m.js → index-jpvng27a.js} +1 -1
  85. package/dist/client/static/js/{index-vw8b29ek.js → index-me0b6wkw.js} +1 -1
  86. package/dist/client/static/js/{index-6x0kn8pb.js → index-mhrkjbjq.js} +2 -2
  87. package/dist/client/static/js/{index-fe92hqmb.js → index-mngpcca7.js} +4 -4
  88. package/dist/client/static/js/index-mttx9327.css +1 -0
  89. package/dist/client/static/js/{index-5xxbbzqa.js → index-mx5y9vt9.js} +7 -7
  90. package/dist/client/static/js/{index-3ymw778n.js → index-ndqtff48.js} +2 -2
  91. package/dist/client/static/js/{index-cmjyet7w.js → index-nf4hq5tg.js} +27 -27
  92. package/dist/client/static/js/{index-cpp43af3.js → index-njhrm5qa.js} +9 -9
  93. package/dist/client/static/js/index-nnwcbp2d.js +2 -0
  94. package/dist/client/static/js/{index-3p732mvs.js → index-np2rfq06.js} +2 -2
  95. package/dist/client/static/js/{index-2s17netq.js → index-nwbr15b3.js} +2 -2
  96. package/dist/client/static/js/{index-an7fq7f6.js → index-pa70qj4p.js} +1 -1
  97. package/dist/client/static/js/index-pe5f2gmn.js +1 -0
  98. package/dist/client/static/js/{index-1e0rt7c6.js → index-pgy7ree5.js} +5 -5
  99. package/dist/client/static/js/index-pzwf6hwe.js +4 -0
  100. package/dist/client/static/js/{index-7sq6cjt1.js → index-q3k8r0ms.js} +11 -11
  101. package/dist/client/static/js/{index-j830qk07.js → index-rw84kefb.js} +2 -2
  102. package/dist/client/static/js/{index-94d416ee.js → index-s9ts6qbj.js} +2 -2
  103. package/dist/client/static/js/{index-vny4ymjf.js → index-sg65xdey.js} +1 -1
  104. package/dist/client/static/js/{index-hb7a7m9m.js → index-skvfxcd8.js} +1 -1
  105. package/dist/client/static/js/{index-1e710snk.js → index-sx2yz2wx.js} +1 -1
  106. package/dist/client/static/js/{index-kzzvrqnv.js → index-trq7bdvk.js} +2 -2
  107. package/dist/client/static/js/{index-v8xhgfeq.js → index-vs2y8gxr.js} +2 -2
  108. package/dist/client/static/js/index-wwyjzhgs.js +2 -0
  109. package/dist/client/static/js/{index-374xq5a4.js → index-xe447cw3.js} +1 -1
  110. package/dist/client/static/js/index-y09de44h.js +2 -0
  111. package/dist/client/static/js/{index-jxsha63v.js → index-y4cx8cqf.js} +2 -2
  112. package/dist/client/static/js/{index-c9aqx3ht.js → index-yg38s8t3.js} +1 -1
  113. package/dist/client/static/js/{index-dxq1tbwm.js → index-yh7gngsh.js} +2 -2
  114. package/dist/client/static/js/{index-3m1dksmy.js → index-yrwm437g.js} +2 -2
  115. package/dist/client/static/js/{index-7ynf3s2w.js → index-z82nd2bd.js} +2 -2
  116. package/dist/client/static/js/info-A6RAGUB7-zkv4crz7.js +1 -0
  117. package/dist/client/static/js/{infoDiagram-VRGFBTTK-1x83h4k4.js → infoDiagram-VRGFBTTK-9xph6cr5.js} +2 -2
  118. package/dist/client/static/js/ini-62r3vxaf.js +1 -0
  119. package/dist/client/static/js/{ishikawaDiagram-OU5B5YK6-et6z3c28.js → ishikawaDiagram-OU5B5YK6-3gshs3v8.js} +2 -2
  120. package/dist/client/static/js/java-kacycary.js +1 -0
  121. package/dist/client/static/js/javascript-zc1qnyyp.js +1 -0
  122. package/dist/client/static/js/{journeyDiagram-ZHPQQLJL-sw669e7a.js → journeyDiagram-ZHPQQLJL-fa8x56mf.js} +2 -2
  123. package/dist/client/static/js/json-yrwpn6bd.js +1 -0
  124. package/dist/client/static/js/jsx-b40ag8q1.js +1 -0
  125. package/dist/client/static/js/{julia-z14p8jsx.js → julia-agc5kfvg.js} +1 -1
  126. package/dist/client/static/js/{kanban-definition-PNTS6WVX-aqxg95kx.js → kanban-definition-PNTS6WVX-fybp2hh4.js} +6 -6
  127. package/dist/client/static/js/lua-bk961f37.js +1 -0
  128. package/dist/client/static/js/markdown-b7rgzgd6.js +1 -0
  129. package/dist/client/static/js/mermaid.core-jjh5ggp0.js +12 -0
  130. package/dist/client/static/js/{mindmap-definition-NLK3R4M7-530anpc4.js → mindmap-definition-NLK3R4M7-gtfbg619.js} +4 -4
  131. package/dist/client/static/js/one-dark-pro-vht9rv39.js +1 -0
  132. package/dist/client/static/js/one-light-arxc5whh.js +1 -0
  133. package/dist/client/static/js/packet-AYTQ26CC-dgpge627.js +1 -0
  134. package/dist/client/static/js/{pegDiagram-GJSIUBJH-5zar6hvy.js → pegDiagram-GJSIUBJH-1a51sbqv.js} +1 -1
  135. package/dist/client/static/js/{perl-1na2x6yd.js → perl-v5vbtzgf.js} +1 -1
  136. package/dist/client/static/js/{php-x75tt7w3.js → php-83qwy98t.js} +1 -1
  137. package/dist/client/static/js/pie-WAS4IAKB-b8pgsqrd.js +1 -0
  138. package/dist/client/static/js/{pieDiagram-5QR66LMP-3bx8syvw.js → pieDiagram-5QR66LMP-zd9svyyn.js} +3 -3
  139. package/dist/client/static/js/properties-k8gbzggp.js +1 -0
  140. package/dist/client/static/js/python-343tspad.js +1 -0
  141. package/dist/client/static/js/{quadrantDiagram-O4NWA36T-yaarpr2e.js → quadrantDiagram-O4NWA36T-5gtw2m6s.js} +2 -2
  142. package/dist/client/static/js/r-ycdwmv8g.js +1 -0
  143. package/dist/client/static/js/radar-RG4KPBEZ-fmfe5y27.js +1 -0
  144. package/dist/client/static/js/railroad-74A4TZTK-b5tks4ce.js +1 -0
  145. package/dist/client/static/js/railroad-abnf-HS5TGJTU-0sf4m0ze.js +1 -0
  146. package/dist/client/static/js/railroad-ebnf-LZEXJU2U-pjfy3pt7.js +1 -0
  147. package/dist/client/static/js/railroad-peg-WCYAUIDC-nr8ngt42.js +1 -0
  148. package/dist/client/static/js/{railroadDiagram-XR7U4H2S-ag41q4nt.js → railroadDiagram-XR7U4H2S-3ccwpfzz.js} +1 -1
  149. package/dist/client/static/js/{requirementDiagram-PLB6GJNP-g8sr48h4.js → requirementDiagram-PLB6GJNP-sasndrrp.js} +3 -3
  150. package/dist/client/static/js/{ruby-3h22qahv.js → ruby-994n5j6e.js} +1 -1
  151. package/dist/client/static/js/{rust-r27demr5.js → rust-n9z2c9m3.js} +1 -1
  152. package/dist/client/static/js/{sankeyDiagram-IPEJSGJF-t1wbd1hh.js → sankeyDiagram-IPEJSGJF-2ahb4sda.js} +3 -3
  153. package/dist/client/static/js/{sass-8bq5r2tz.js → sass-p6g7qdv2.js} +1 -1
  154. package/dist/client/static/js/{scss-c04ezwnn.js → scss-4j4t3r6y.js} +1 -1
  155. package/dist/client/static/js/{sequenceDiagram-PO4LG4MO-407mjqty.js → sequenceDiagram-PO4LG4MO-bfj90kz1.js} +7 -7
  156. package/dist/client/static/js/{sizeCapture-INFHLROL-w38zb9ky.js → sizeCapture-INFHLROL-5tygxmtc.js} +1 -1
  157. package/dist/client/static/js/sql-kwpd5w07.js +1 -0
  158. package/dist/client/static/js/{stateDiagram-v2-GCMORJYK-4cvgymkc.js → stateDiagram-v2-GCMORJYK-533xw76e.js} +3 -3
  159. package/dist/client/static/js/{svelte-egg3x4tw.js → svelte-bek3h1sz.js} +1 -1
  160. package/dist/client/static/js/{swimlanes-2SLR337P-w7ts2rzw.js → swimlanes-2SLR337P-gd3d04pk.js} +1 -1
  161. package/dist/client/static/js/swimlanesDiagram-TC7HE7FX-xxmvdyg4.js +8 -0
  162. package/dist/client/static/js/{timeline-definition-EJHVYXUP-nq46nzy9.js → timeline-definition-EJHVYXUP-fvqvgqvg.js} +3 -3
  163. package/dist/client/static/js/treeView-Q6P3EWNA-23r9fa68.js +1 -0
  164. package/dist/client/static/js/treemap-WGGIJYW6-mxxzdrj6.js +1 -0
  165. package/dist/client/static/js/tsx-gjxfjnbk.js +1 -0
  166. package/dist/client/static/js/typescript-4dchbnya.js +1 -0
  167. package/dist/client/static/js/{usecaseDiagram-POWQR4AR-q144snzb.js → usecaseDiagram-POWQR4AR-tm1f0m4x.js} +15 -15
  168. package/dist/client/static/js/{vennDiagram-UO4OBE2U-2wemak2p.js → vennDiagram-UO4OBE2U-2vdvv1hd.js} +4 -4
  169. package/dist/client/static/js/{vue-d7p4wv35.js → vue-y44m889c.js} +1 -1
  170. package/dist/client/static/js/wardley-WFR3VGLG-cbqtax1x.js +1 -0
  171. package/dist/client/static/js/{wardleyDiagram-VNRHLVJA-bb2qvvgr.js → wardleyDiagram-VNRHLVJA-7avcjznx.js} +4 -4
  172. package/dist/client/static/js/xml-xs6qz3ya.js +1 -0
  173. package/dist/client/static/js/{xychartDiagram-PMCCYNJV-9dr05fdq.js → xychartDiagram-PMCCYNJV-g39y526n.js} +4 -4
  174. package/dist/client/static/js/yaml-174nk5bn.js +1 -0
  175. package/package.json +7 -7
  176. package/src/client/borders.css +15 -3
  177. package/src/client/components/common/ComposerTextarea.test.tsx +13 -1
  178. package/src/client/components/common/ComposerTextarea.tsx +8 -2
  179. package/src/client/components/common/MarkdownRenderer.tsx +11 -2
  180. package/src/client/components/common/harness-glyph/harness-glyph.test.ts +0 -4
  181. package/src/client/components/common/harness-glyph/index.tsx +4 -5
  182. package/src/client/components/common/markdown-inline-file.test.tsx +90 -15
  183. package/src/client/components/common/session-actions-menu/index.test.tsx +45 -0
  184. package/src/client/components/common/session-actions-menu/index.tsx +6 -1
  185. package/src/client/components/layout/desktop-layout/RightColumn.tsx +4 -1
  186. package/src/client/components/layout/desktop-layout/WorkspacePanels.tsx +28 -35
  187. package/src/client/components/layout/desktop-layout/index.tsx +5 -3
  188. package/src/client/components/layout/desktop-layout/resizer/index.tsx +13 -3
  189. package/src/client/components/layout/desktop-layout/resizer/panel.test.ts +41 -0
  190. package/src/client/components/layout/session-sidebar/CategoryHeader.tsx +21 -1
  191. package/src/client/components/layout/session-sidebar/CategoryHeader.worktree.test.tsx +1 -0
  192. package/src/client/components/layout/session-sidebar/CategoryItem.tsx +8 -2
  193. package/src/client/components/layout/session-sidebar/ClassicView.tsx +2 -0
  194. package/src/client/components/layout/session-sidebar/SessionList.tsx +4 -0
  195. package/src/client/components/layout/session-sidebar/SessionsView.tsx +22 -1
  196. package/src/client/components/layout/session-sidebar/modern/WorkspaceHeader.tsx +45 -28
  197. package/src/client/components/layout/session-sidebar/modern/WorkspaceSection.tsx +9 -3
  198. package/src/client/components/layout/session-sidebar/modern/index.tsx +2 -0
  199. package/src/client/components/layout/session-sidebar/modern/workspace-header.test.tsx +27 -11
  200. package/src/client/components/layout/session-sidebar/search-results.test.tsx +29 -16
  201. package/src/client/components/layout/session-sidebar/session-list-states.test.tsx +1 -0
  202. package/src/client/components/layout/session-sidebar/variant-props.ts +2 -0
  203. package/src/client/components/mobile/LayoutWrapper.tsx +9 -0
  204. package/src/client/components/mobile/SessionSidebar.tsx +4 -0
  205. package/src/client/components/mobile/left-drawer-nav.test.tsx +1 -1
  206. package/src/client/components/mobile/mobile-session-sidebar/Body.tsx +4 -0
  207. package/src/client/components/mobile/mobile-session-sidebar/ClassicDrawer.tsx +3 -0
  208. package/src/client/components/mobile/mobile-session-sidebar/Item.test.tsx +85 -0
  209. package/src/client/components/mobile/mobile-session-sidebar/Item.tsx +30 -14
  210. package/src/client/components/mobile/mobile-session-sidebar/List.tsx +4 -0
  211. package/src/client/components/settings/apply-side-effects.test.ts +31 -0
  212. package/src/client/components/settings/apply-side-effects.ts +7 -0
  213. package/src/client/components/settings/categories/appearance-settings/BorderStyleSection.tsx +3 -2
  214. package/src/client/components/settings/categories/appearance-settings/SidebarStyleSection.test.tsx +95 -0
  215. package/src/client/components/settings/categories/appearance-settings/SidebarStyleSection.tsx +35 -0
  216. package/src/client/components/workspace/chat-timeline/EmptyWorkspacePrompt.tsx +1 -0
  217. package/src/client/components/workspace/chat-timeline/MessageItem.gutter.test.ts +26 -0
  218. package/src/client/components/workspace/chat-timeline/MessageItem.tsx +6 -3
  219. package/src/client/components/workspace/chat-timeline/ThinkingSection.test.tsx +17 -0
  220. package/src/client/components/workspace/chat-timeline/ThinkingSection.tsx +9 -3
  221. package/src/client/components/workspace/chat-timeline/chat-input/AccessDropdown.test.ts +39 -2
  222. package/src/client/components/workspace/chat-timeline/chat-input/AccessDropdown.tsx +19 -4
  223. package/src/client/components/workspace/chat-timeline/chat-input/AttachmentToolbar.tsx +28 -21
  224. package/src/client/components/workspace/chat-timeline/chat-input/AttachmentToolbar.wait.test.tsx +48 -0
  225. package/src/client/components/workspace/chat-timeline/chat-input/ComposerRows.tsx +44 -21
  226. package/src/client/components/workspace/chat-timeline/chat-input/GoalBanner.test.ts +24 -0
  227. package/src/client/components/workspace/chat-timeline/chat-input/GoalBanner.tsx +44 -18
  228. package/src/client/components/workspace/chat-timeline/chat-input/GoalSurfaces.tsx +2 -1
  229. package/src/client/components/workspace/chat-timeline/chat-input/ModeToggles.test.ts +35 -0
  230. package/src/client/components/workspace/chat-timeline/chat-input/ModeToggles.tsx +33 -12
  231. package/src/client/components/workspace/chat-timeline/chat-input/SessionModeDropdown.test.tsx +24 -0
  232. package/src/client/components/workspace/chat-timeline/chat-input/SessionModeDropdown.tsx +14 -3
  233. package/src/client/components/workspace/chat-timeline/chat-input/Toolbar.test.ts +24 -1
  234. package/src/client/components/workspace/chat-timeline/chat-input/Toolbar.tsx +78 -135
  235. package/src/client/components/workspace/chat-timeline/chat-input/VoiceButton.tsx +58 -0
  236. package/src/client/components/workspace/chat-timeline/chat-input/action-base.ts +42 -0
  237. package/src/client/components/workspace/chat-timeline/chat-input/index.tsx +1 -0
  238. package/src/client/components/workspace/chat-timeline/chat-input/mode-icons.test.ts +108 -0
  239. package/src/client/components/workspace/chat-timeline/chat-input/mode-icons.tsx +122 -0
  240. package/src/client/components/workspace/chat-timeline/chat-input/narrow.test.tsx +78 -20
  241. package/src/client/components/workspace/chat-timeline/chat-input/styles/index.tsx +11 -5
  242. package/src/client/components/workspace/chat-timeline/chat-input/styles.test.tsx +19 -0
  243. package/src/client/components/workspace/chat-timeline/composer-dock-frame.test.tsx +9 -0
  244. package/src/client/components/workspace/chat-timeline/index.tsx +1 -1
  245. package/src/client/components/workspace/chat-timeline/tool-renderers/ask-panel/OptionRow.test.tsx +125 -0
  246. package/src/client/components/workspace/chat-timeline/tool-renderers/ask-panel/OptionRow.tsx +84 -27
  247. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Mcp.test.tsx +18 -0
  248. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Mcp.tsx +14 -5
  249. package/src/client/components/workspace/model-dropdown/HarnessTabs.tsx +31 -10
  250. package/src/client/components/workspace/model-dropdown/Header.tsx +13 -5
  251. package/src/client/components/workspace/model-dropdown/Panel.tsx +18 -0
  252. package/src/client/components/workspace/model-dropdown/ThinkingLevels.tsx +51 -0
  253. package/src/client/components/workspace/model-dropdown/Trigger.tsx +99 -0
  254. package/src/client/components/workspace/model-dropdown/bands.ts +51 -0
  255. package/src/client/components/workspace/model-dropdown/harness-tabs.test.tsx +21 -5
  256. package/src/client/components/workspace/model-dropdown/index.tsx +20 -47
  257. package/src/client/components/workspace/model-dropdown/thinking-levels.test.tsx +108 -0
  258. package/src/client/components/workspace/model-dropdown/trigger.test.ts +54 -8
  259. package/src/client/hooks/chat/composer/attachments.test.ts +12 -0
  260. package/src/client/hooks/chat/composer/attachments.ts +16 -4
  261. package/src/client/hooks/chat/composer/pipeline.test.ts +14 -0
  262. package/src/client/hooks/chat/composer/pipeline.ts +15 -6
  263. package/src/client/hooks/chat/omp/session-list.activity.test.ts +20 -0
  264. package/src/client/hooks/chat/omp/session-merges.ts +18 -6
  265. package/src/client/hooks/chat/omp/session-sidebar-controller.ts +4 -0
  266. package/src/client/hooks/chat/timeline/scope.test.ts +17 -0
  267. package/src/client/hooks/chat/timeline/scope.ts +6 -1
  268. package/src/client/hooks/chat/timeline/send-refusal.test.ts +19 -0
  269. package/src/client/hooks/chat/timeline/send-steer.test.ts +17 -0
  270. package/src/client/hooks/chat/timeline/send.ts +17 -0
  271. package/src/client/hooks/editor/quick-open.ts +41 -0
  272. package/src/client/hooks/ui/border-style.test.ts +13 -0
  273. package/src/client/hooks/ui/markdown-render.ts +11 -6
  274. package/src/client/hooks/ui/open-inline-file.test.ts +16 -0
  275. package/src/client/hooks/ui/open-inline-file.ts +4 -2
  276. package/src/client/hooks/ui/show-more.ts +11 -1
  277. package/src/client/hooks/ui/ui-feedback.test.ts +11 -0
  278. package/src/client/hooks/ui/verified-inline-files.test.tsx +143 -0
  279. package/src/client/hooks/ui/verified-inline-files.ts +165 -0
  280. package/src/client/hooks/workspace/mobile-workspace-panels.test.tsx +116 -0
  281. package/src/client/hooks/workspace/mobile-workspace-panels.ts +73 -0
  282. package/src/client/hooks/workspace/panel-resize.test.ts +127 -0
  283. package/src/client/hooks/workspace/panel-resize.ts +81 -0
  284. package/src/client/hooks/workspace/session-list-limit.test.ts +80 -0
  285. package/src/client/hooks/workspace/session-list-limit.ts +69 -0
  286. package/src/client/hooks/workspace/session-pin.ts +58 -0
  287. package/src/client/hooks/workspace/workspace-panels-mode.test.tsx +87 -0
  288. package/src/client/hooks/workspace/workspace-panels-mode.ts +76 -0
  289. package/src/client/lib/router/branch-params.test.ts +17 -1
  290. package/src/client/lib/router/branch-params.ts +18 -0
  291. package/src/client/lib/ui/pressed.ts +15 -0
  292. package/src/client/tailwind.css +30 -10
  293. package/src/server/lib/connect/cloudflared.lifecycle.test.ts +25 -9
  294. package/src/server/lib/db/schema.test.ts +1 -1
  295. package/src/server/lib/db/schema.ts +17 -0
  296. package/src/server/lib/harness/activity.server.test.ts +81 -0
  297. package/src/server/lib/harness/activity.server.ts +55 -0
  298. package/src/server/lib/harness/spawn.server.ts +9 -0
  299. package/src/server/lib/omp/session/delete.server.ts +4 -2
  300. package/src/server/lib/omp/session/sidebar-activity.server.test.ts +24 -2
  301. package/src/server/lib/omp/session/sidebar-data.canonical.test.ts +14 -0
  302. package/src/server/lib/sessions/last-opened.server.test.ts +17 -0
  303. package/src/server/lib/sessions/last-opened.server.ts +18 -1
  304. package/src/server/routes/sessions/index.ts +3 -2
  305. package/src/server/routes/sessions/routes.test.ts +29 -46
  306. package/src/server/routes/sessions/session.ts +40 -62
  307. package/src/server/routes/sessions/state.test.ts +89 -0
  308. package/src/server/routes/sessions/state.ts +86 -0
  309. package/src/shared/lib/chat/attachment-budget.test.ts +74 -0
  310. package/src/shared/lib/chat/attachment-budget.ts +111 -0
  311. package/src/shared/lib/chat/attachments.test.ts +0 -17
  312. package/src/shared/lib/chat/attachments.ts +0 -53
  313. package/src/shared/lib/chat/timeline/block-chrome.test.ts +35 -0
  314. package/src/shared/lib/chat/timeline/block-chrome.ts +21 -0
  315. package/src/shared/lib/markdown/degenerate-emphasis.test.ts +64 -0
  316. package/src/shared/lib/markdown/degenerate-emphasis.ts +90 -0
  317. package/src/shared/lib/markdown/inline-file.test.ts +79 -22
  318. package/src/shared/lib/markdown/inline-file.ts +57 -25
  319. package/src/shared/lib/markdown/marked.ts +5 -1
  320. package/src/shared/lib/settings/defaults.ts +2 -0
  321. package/src/shared/lib/theme/border-style.ts +1 -1
  322. package/src/shared/lib/workspace/active-project.test.ts +17 -1
  323. package/src/shared/lib/workspace/active-project.ts +9 -0
  324. package/src/shared/lib/workspace/project-settings-delete.test.ts +97 -0
  325. package/src/shared/lib/workspace/project-settings.test.ts +2 -34
  326. package/src/shared/lib/workspace/project-settings.ts +6 -0
  327. package/src/shared/lib/workspace/session-list-limit.test.ts +31 -0
  328. package/src/shared/lib/workspace/session-list-limit.ts +32 -0
  329. package/src/shared/lib/workspace/sidebar-sort.test.ts +21 -0
  330. package/src/shared/lib/workspace/workspace-panel-widths.ts +1 -1
  331. package/src/shared/lib/workspace/workspace-session.test.ts +34 -0
  332. package/src/shared/lib/workspace/workspace-session.ts +40 -0
  333. package/src/shared/types/settings/state.ts +10 -0
  334. package/dist/client/static/js/ImageView-ssazqckj.js +0 -1
  335. package/dist/client/static/js/LayoutWrapper-qwpfq4dq.js +0 -2
  336. package/dist/client/static/js/MergeDiffView-en6aazw8.js +0 -1
  337. package/dist/client/static/js/Modal-zjnhj9nb.js +0 -60
  338. package/dist/client/static/js/SessionsView-eryjtmb2.js +0 -1
  339. package/dist/client/static/js/architecture-7GRP2DOG-v05ap4e3.js +0 -1
  340. package/dist/client/static/js/bash-n5d0esqg.js +0 -1
  341. package/dist/client/static/js/c-pk766wx0.js +0 -1
  342. package/dist/client/static/js/cpp-3pt91jvm.js +0 -1
  343. package/dist/client/static/js/css-q2k6afe3.js +0 -1
  344. package/dist/client/static/js/css-sp1cgdbr.js +0 -1
  345. package/dist/client/static/js/cynefin-OW5HDTMX-sqv0ze38.js +0 -1
  346. package/dist/client/static/js/eventmodeling-NTZA5JFV-t4dzf5s7.js +0 -1
  347. package/dist/client/static/js/flowDiagram-KWPJA3E3-c16xmjyv.js +0 -1
  348. package/dist/client/static/js/gitGraph-4MIJSDKK-0jq8y0qd.js +0 -1
  349. package/dist/client/static/js/graphql-qx4tt6ze.js +0 -1
  350. package/dist/client/static/js/html-5e0g8664.js +0 -1
  351. package/dist/client/static/js/index-4ddgpqm0.css +0 -1
  352. package/dist/client/static/js/index-5g2j626a.js +0 -1
  353. package/dist/client/static/js/index-cc7qbfvn.js +0 -477
  354. package/dist/client/static/js/index-f27wvdky.js +0 -4
  355. package/dist/client/static/js/index-m5n0zsft.js +0 -2
  356. package/dist/client/static/js/index-rqt8mem9.js +0 -2
  357. package/dist/client/static/js/index-s9k82stc.js +0 -2
  358. package/dist/client/static/js/index-skwem10a.js +0 -2
  359. package/dist/client/static/js/index-tv9rn2nd.js +0 -2
  360. package/dist/client/static/js/info-A6RAGUB7-szttx3v5.js +0 -1
  361. package/dist/client/static/js/ini-bdk46a3d.js +0 -1
  362. package/dist/client/static/js/java-3g3925cf.js +0 -1
  363. package/dist/client/static/js/javascript-av46zx4c.js +0 -1
  364. package/dist/client/static/js/json-hdyzmffz.js +0 -1
  365. package/dist/client/static/js/jsx-y8r9mrdq.js +0 -1
  366. package/dist/client/static/js/lua-wf5k6p3r.js +0 -1
  367. package/dist/client/static/js/markdown-9bf16dx7.js +0 -1
  368. package/dist/client/static/js/mermaid.core-6cgqsgcf.js +0 -12
  369. package/dist/client/static/js/one-dark-pro-9hnhtkpr.js +0 -1
  370. package/dist/client/static/js/one-light-2n5y8592.js +0 -1
  371. package/dist/client/static/js/packet-AYTQ26CC-401149bv.js +0 -1
  372. package/dist/client/static/js/pie-WAS4IAKB-bgfv8tfz.js +0 -1
  373. package/dist/client/static/js/properties-xk4dn00p.js +0 -1
  374. package/dist/client/static/js/python-7sgz05n4.js +0 -1
  375. package/dist/client/static/js/r-w4qxm0pv.js +0 -1
  376. package/dist/client/static/js/radar-RG4KPBEZ-pw720590.js +0 -1
  377. package/dist/client/static/js/railroad-74A4TZTK-n2a30ngs.js +0 -1
  378. package/dist/client/static/js/railroad-abnf-HS5TGJTU-rn5rx9qt.js +0 -1
  379. package/dist/client/static/js/railroad-ebnf-LZEXJU2U-t4yryhtd.js +0 -1
  380. package/dist/client/static/js/railroad-peg-WCYAUIDC-c4ebgvrr.js +0 -1
  381. package/dist/client/static/js/sql-sd00wgem.js +0 -1
  382. package/dist/client/static/js/swimlanesDiagram-TC7HE7FX-v82nym6b.js +0 -8
  383. package/dist/client/static/js/treeView-Q6P3EWNA-bxgt5yhm.js +0 -1
  384. package/dist/client/static/js/treemap-WGGIJYW6-hh3595m0.js +0 -1
  385. package/dist/client/static/js/tsx-h5yzg80q.js +0 -1
  386. package/dist/client/static/js/typescript-qy1sbhea.js +0 -1
  387. package/dist/client/static/js/wardley-WFR3VGLG-6bza7h1b.js +0 -1
  388. package/dist/client/static/js/xml-mrk4xakv.js +0 -1
  389. package/dist/client/static/js/yaml-xaza6dra.js +0 -1
  390. package/src/client/components/workspace/chat-timeline/chat-input/ThinkingLevelDropdown.test.tsx +0 -110
  391. package/src/client/components/workspace/chat-timeline/chat-input/ThinkingLevelDropdown.tsx +0 -86
@@ -1 +1 @@
1
- import{t}from"./index-gqrt766t.js";var c=1;function i(){if(typeof globalThis>"u")return;return globalThis}t(i,"getCaptureGlobal");function p(){return Boolean(i()?.mermaidCaptureSizes)}t(p,"shouldCaptureSizes");function u(){if(typeof location>"u")return"browser-dev";return`${location.pathname}${location.search}`}t(u,"capturedFromLocation");function d(n,r){let o=i();if(!o)return;let e=r.node(),s=((e&&"ownerSVGElement"in e?e.ownerSVGElement:null)??e)?.id??"(unknown)";o.mermaidCapturedSizes??=[];let a={svgId:s,sizes:n};o.mermaidCapturedSizes.push(a),o.mermaidLastCapturedSizes=a}t(d,"emitCapturedSizes");function m(n,r){let o=[];for(let e of r.nodes){if(e.isGroup)continue;o.push({id:e.id,width:e.width??0,height:e.height??0})}if(o.length===0)return;d({metadata:{captureVersion:c,capturedAt:new Date().toISOString(),capturedFrom:u()},nodes:o},n)}t(m,"captureNodeSizes");export{m as captureNodeSizes};
1
+ import{t}from"./index-60cxxnpk.js";var c=1;function i(){if(typeof globalThis>"u")return;return globalThis}t(i,"getCaptureGlobal");function p(){return Boolean(i()?.mermaidCaptureSizes)}t(p,"shouldCaptureSizes");function u(){if(typeof location>"u")return"browser-dev";return`${location.pathname}${location.search}`}t(u,"capturedFromLocation");function d(n,r){let o=i();if(!o)return;let e=r.node(),s=((e&&"ownerSVGElement"in e?e.ownerSVGElement:null)??e)?.id??"(unknown)";o.mermaidCapturedSizes??=[];let a={svgId:s,sizes:n};o.mermaidCapturedSizes.push(a),o.mermaidLastCapturedSizes=a}t(d,"emitCapturedSizes");function m(n,r){let o=[];for(let e of r.nodes){if(e.isGroup)continue;o.push({id:e.id,width:e.width??0,height:e.height??0})}if(o.length===0)return;d({metadata:{captureVersion:c,capturedAt:new Date().toISOString(),capturedFrom:u()},nodes:o},n)}t(m,"captureNodeSizes");export{m as captureNodeSizes};
@@ -0,0 +1 @@
1
+ import{_a}from"./index-5e4e18tg.js";export{_a as default};
@@ -1,9 +1,9 @@
1
- import{t,l,w,F,O,G,z,j,q,H,m,b,Wg,V,kt,dt,pt,ta,Pt,Ot,$t,xt}from"./index-gqrt766t.js";import{Ht}from"./index-cc7qbfvn.js";import{Za}from"./index-j830qk07.js";var Wt=function(){var e=t(function(Q,c,f,a){for(f=f||{},a=Q.length;a--;f[Q[a]]=c);return f},"o"),s=[1,2],o=[1,3],r=[1,4],d=[2,4],u=[1,9],S=[1,11],g=[1,16],n=[1,17],T=[1,18],E=[1,19],I=[1,33],N=[1,20],B=[1,21],C=[1,22],p=[1,23],R=[1,24],A=[1,26],W=[1,27],P=[1,28],U=[1,29],D=[1,30],st=[1,31],gt=[1,32],yt=[1,35],mt=[1,36],bt=[1,37],Tt=[1,38],rt=[1,34],y=[1,4,5,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],Et=[1,4,5,14,15,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,39,40,41,45,48,51,52,53,54,57],Kt=[4,5,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],Nt={trace:t(function(){},"trace"),yy:{},symbols_:{error:2,start:3,SPACE:4,NL:5,SD:6,document:7,line:8,statement:9,classDefStatement:10,styleStatement:11,cssClassStatement:12,idStatement:13,DESCR:14,"-->":15,HIDE_EMPTY:16,scale:17,WIDTH:18,COMPOSIT_STATE:19,STRUCT_START:20,STRUCT_STOP:21,STATE_DESCR:22,AS:23,ID:24,FORK:25,JOIN:26,CHOICE:27,CONCURRENT:28,note:29,notePosition:30,NOTE_TEXT:31,direction:32,acc_title:33,acc_title_value:34,acc_descr:35,acc_descr_value:36,acc_descr_multiline_value:37,CLICK:38,STRING:39,HREF:40,classDef:41,CLASSDEF_ID:42,CLASSDEF_STYLEOPTS:43,DEFAULT:44,style:45,STYLE_IDS:46,STYLEDEF_STYLEOPTS:47,class:48,CLASSENTITY_IDS:49,STYLECLASS:50,direction_tb:51,direction_bt:52,direction_rl:53,direction_lr:54,eol:55,";":56,EDGE_STATE:57,STYLE_SEPARATOR:58,left_of:59,right_of:60,$accept:0,$end:1},terminals_:{2:"error",4:"SPACE",5:"NL",6:"SD",14:"DESCR",15:"-->",16:"HIDE_EMPTY",17:"scale",18:"WIDTH",19:"COMPOSIT_STATE",20:"STRUCT_START",21:"STRUCT_STOP",22:"STATE_DESCR",23:"AS",24:"ID",25:"FORK",26:"JOIN",27:"CHOICE",28:"CONCURRENT",29:"note",31:"NOTE_TEXT",33:"acc_title",34:"acc_title_value",35:"acc_descr",36:"acc_descr_value",37:"acc_descr_multiline_value",38:"CLICK",39:"STRING",40:"HREF",41:"classDef",42:"CLASSDEF_ID",43:"CLASSDEF_STYLEOPTS",44:"DEFAULT",45:"style",46:"STYLE_IDS",47:"STYLEDEF_STYLEOPTS",48:"class",49:"CLASSENTITY_IDS",50:"STYLECLASS",51:"direction_tb",52:"direction_bt",53:"direction_rl",54:"direction_lr",56:";",57:"EDGE_STATE",58:"STYLE_SEPARATOR",59:"left_of",60:"right_of"},productions_:[0,[3,2],[3,2],[3,2],[7,0],[7,2],[8,2],[8,1],[8,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,3],[9,4],[9,1],[9,2],[9,1],[9,4],[9,3],[9,6],[9,1],[9,1],[9,1],[9,1],[9,4],[9,4],[9,1],[9,2],[9,2],[9,1],[9,5],[9,5],[10,3],[10,3],[11,3],[12,3],[32,1],[32,1],[32,1],[32,1],[55,1],[55,1],[13,1],[13,1],[13,3],[13,3],[30,1],[30,1]],performAction:t(function(c,f,a,k,_,i,it){var h=i.length-1;switch(_){case 3:return k.setRootDoc(i[h]),i[h];break;case 4:this.$=[];break;case 5:if(i[h]!="nl")i[h-1].push(i[h]),this.$=i[h-1];break;case 6:case 7:this.$=i[h];break;case 8:this.$="nl";break;case 12:this.$=i[h];break;case 13:let vt=i[h-1];vt.description=k.trimColon(i[h]),this.$=vt;break;case 14:this.$={stmt:"relation",state1:i[h-2],state2:i[h]};break;case 15:let Dt=k.trimColon(i[h]);this.$={stmt:"relation",state1:i[h-3],state2:i[h-1],description:Dt};break;case 19:this.$={stmt:"state",id:i[h-3],type:"default",description:"",doc:i[h-1]};break;case 20:var K=i[h],X=i[h-2].trim();if(i[h].match(":")){var lt=i[h].split(":");K=lt[0],X=[X,lt[1]]}this.$={stmt:"state",id:K,type:"default",description:X};break;case 21:this.$={stmt:"state",id:i[h-3],type:"default",description:i[h-5],doc:i[h-1]};break;case 22:this.$={stmt:"state",id:i[h],type:"fork"};break;case 23:this.$={stmt:"state",id:i[h],type:"join"};break;case 24:this.$={stmt:"state",id:i[h],type:"choice"};break;case 25:this.$={stmt:"state",id:k.getDividerId(),type:"divider"};break;case 26:this.$={stmt:"state",id:i[h-1].trim(),note:{position:i[h-2].trim(),text:i[h].trim()}};break;case 29:this.$=i[h].trim(),k.setAccTitle(this.$);break;case 30:case 31:this.$=i[h].trim(),k.setAccDescription(this.$);break;case 32:this.$={stmt:"click",id:i[h-3],url:i[h-2],tooltip:i[h-1]};break;case 33:this.$={stmt:"click",id:i[h-3],url:i[h-1],tooltip:""};break;case 34:case 35:this.$={stmt:"classDef",id:i[h-1].trim(),classes:i[h].trim()};break;case 36:this.$={stmt:"style",id:i[h-1].trim(),styleClass:i[h].trim()};break;case 37:this.$={stmt:"applyClass",id:i[h-1].trim(),styleClass:i[h].trim()};break;case 38:k.setDirection("TB"),this.$={stmt:"dir",value:"TB"};break;case 39:k.setDirection("BT"),this.$={stmt:"dir",value:"BT"};break;case 40:k.setDirection("RL"),this.$={stmt:"dir",value:"RL"};break;case 41:k.setDirection("LR"),this.$={stmt:"dir",value:"LR"};break;case 44:case 45:this.$={stmt:"state",id:i[h].trim(),type:"default",description:""};break;case 46:this.$={stmt:"state",id:i[h-2].trim(),classes:[i[h].trim()],type:"default",description:""};break;case 47:this.$={stmt:"state",id:i[h-2].trim(),classes:[i[h].trim()],type:"default",description:""};break}},"anonymous"),table:[{3:1,4:s,5:o,6:r},{1:[3]},{3:5,4:s,5:o,6:r},{3:6,4:s,5:o,6:r},e([1,4,5,16,17,19,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],d,{7:7}),{1:[2,1]},{1:[2,2]},{1:[2,3],4:u,5:S,8:8,9:10,10:12,11:13,12:14,13:15,16:g,17:n,19:T,22:E,24:I,25:N,26:B,27:C,28:p,29:R,32:25,33:A,35:W,37:P,38:U,41:D,45:st,48:gt,51:yt,52:mt,53:bt,54:Tt,57:rt},e(y,[2,5]),{9:39,10:12,11:13,12:14,13:15,16:g,17:n,19:T,22:E,24:I,25:N,26:B,27:C,28:p,29:R,32:25,33:A,35:W,37:P,38:U,41:D,45:st,48:gt,51:yt,52:mt,53:bt,54:Tt,57:rt},e(y,[2,7]),e(y,[2,8]),e(y,[2,9]),e(y,[2,10]),e(y,[2,11]),e(y,[2,12],{14:[1,40],15:[1,41]}),e(y,[2,16]),{18:[1,42]},e(y,[2,18],{20:[1,43]}),{23:[1,44]},e(y,[2,22]),e(y,[2,23]),e(y,[2,24]),e(y,[2,25]),{30:45,31:[1,46],59:[1,47],60:[1,48]},e(y,[2,28]),{34:[1,49]},{36:[1,50]},e(y,[2,31]),{13:51,24:I,57:rt},{42:[1,52],44:[1,53]},{46:[1,54]},{49:[1,55]},e(Et,[2,44],{58:[1,56]}),e(Et,[2,45],{58:[1,57]}),e(y,[2,38]),e(y,[2,39]),e(y,[2,40]),e(y,[2,41]),e(y,[2,6]),e(y,[2,13]),{13:58,24:I,57:rt},e(y,[2,17]),e(Kt,d,{7:59}),{24:[1,60]},{24:[1,61]},{23:[1,62]},{24:[2,48]},{24:[2,49]},e(y,[2,29]),e(y,[2,30]),{39:[1,63],40:[1,64]},{43:[1,65]},{43:[1,66]},{47:[1,67]},{50:[1,68]},{24:[1,69]},{24:[1,70]},e(y,[2,14],{14:[1,71]}),{4:u,5:S,8:8,9:10,10:12,11:13,12:14,13:15,16:g,17:n,19:T,21:[1,72],22:E,24:I,25:N,26:B,27:C,28:p,29:R,32:25,33:A,35:W,37:P,38:U,41:D,45:st,48:gt,51:yt,52:mt,53:bt,54:Tt,57:rt},e(y,[2,20],{20:[1,73]}),{31:[1,74]},{24:[1,75]},{39:[1,76]},{39:[1,77]},e(y,[2,34]),e(y,[2,35]),e(y,[2,36]),e(y,[2,37]),e(Et,[2,46]),e(Et,[2,47]),e(y,[2,15]),e(y,[2,19]),e(Kt,d,{7:78}),e(y,[2,26]),e(y,[2,27]),{5:[1,79]},{5:[1,80]},{4:u,5:S,8:8,9:10,10:12,11:13,12:14,13:15,16:g,17:n,19:T,21:[1,81],22:E,24:I,25:N,26:B,27:C,28:p,29:R,32:25,33:A,35:W,37:P,38:U,41:D,45:st,48:gt,51:yt,52:mt,53:bt,54:Tt,57:rt},e(y,[2,32]),e(y,[2,33]),e(y,[2,21])],defaultActions:{5:[2,1],6:[2,2],47:[2,48],48:[2,49]},parseError:t(function(c,f){if(f.recoverable)this.trace(c);else{var a=Error(c);throw a.hash=f,a}},"parseError"),parse:t(function(c){var f=this,a=[0],k=[],_=[null],i=[],it=this.table,h="",K=0,X=0,lt=0,vt=2,Dt=1,me=i.slice.call(arguments,1),v=Object.create(this.lexer),tt={yy:{}};for(var Rt in this.yy)if(Object.prototype.hasOwnProperty.call(this.yy,Rt))tt.yy[Rt]=this.yy[Rt];if(v.setInput(c,tt.yy),tt.yy.lexer=v,tt.yy.parser=this,typeof v.yylloc>"u")v.yylloc={};var Ft=v.yylloc;i.push(Ft);var be=v.options&&v.options.ranges;if(typeof tt.yy.parseError==="function")this.parseError=tt.yy.parseError;else this.parseError=Object.getPrototypeOf(this).parseError;function ke(M){a.length=a.length-2*M,_.length=_.length-M,i.length=i.length-M}t(ke,"popStack");function Xt(){var M=k.pop()||v.lex()||Dt;if(typeof M!=="number"){if(M instanceof Array)k=M,M=k.pop();M=f.symbols_[M]||M}return M}t(Xt,"lex");var x,Bt,et,Y,Qe,Gt,at={},Ct,J,Jt,At;while(!0){if(et=a[a.length-1],this.defaultActions[et])Y=this.defaultActions[et];else{if(x===null||typeof x>"u")x=Xt();Y=it[et]&&it[et][x]}if(typeof Y>"u"||!Y.length||!Y[0]){var Yt="";At=[];for(Ct in it[et])if(this.terminals_[Ct]&&Ct>vt)At.push("'"+this.terminals_[Ct]+"'");if(v.showPosition)Yt="Parse error on line "+(K+1)+`:
1
+ import{t,l,w,F,O,G,z,j,q,H,m,b,tA,V,wt,pt,mt,aa,$t,zt,Ut,Ct}from"./index-60cxxnpk.js";import{Wt}from"./index-eggbcdwx.js";import{to}from"./index-rw84kefb.js";var Vt=function(){var e=t(function(Q,c,f,a){for(f=f||{},a=Q.length;a--;f[Q[a]]=c);return f},"o"),s=[1,2],o=[1,3],r=[1,4],d=[2,4],u=[1,9],S=[1,11],g=[1,16],n=[1,17],T=[1,18],E=[1,19],I=[1,33],N=[1,20],B=[1,21],C=[1,22],p=[1,23],R=[1,24],A=[1,26],W=[1,27],P=[1,28],U=[1,29],D=[1,30],st=[1,31],St=[1,32],gt=[1,35],yt=[1,36],bt=[1,37],kt=[1,38],rt=[1,34],y=[1,4,5,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],Tt=[1,4,5,14,15,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,39,40,41,45,48,51,52,53,54,57],Kt=[4,5,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],Nt={trace:t(function(){},"trace"),yy:{},symbols_:{error:2,start:3,SPACE:4,NL:5,SD:6,document:7,line:8,statement:9,classDefStatement:10,styleStatement:11,cssClassStatement:12,idStatement:13,DESCR:14,"-->":15,HIDE_EMPTY:16,scale:17,WIDTH:18,COMPOSIT_STATE:19,STRUCT_START:20,STRUCT_STOP:21,STATE_DESCR:22,AS:23,ID:24,FORK:25,JOIN:26,CHOICE:27,CONCURRENT:28,note:29,notePosition:30,NOTE_TEXT:31,direction:32,acc_title:33,acc_title_value:34,acc_descr:35,acc_descr_value:36,acc_descr_multiline_value:37,CLICK:38,STRING:39,HREF:40,classDef:41,CLASSDEF_ID:42,CLASSDEF_STYLEOPTS:43,DEFAULT:44,style:45,STYLE_IDS:46,STYLEDEF_STYLEOPTS:47,class:48,CLASSENTITY_IDS:49,STYLECLASS:50,direction_tb:51,direction_bt:52,direction_rl:53,direction_lr:54,eol:55,";":56,EDGE_STATE:57,STYLE_SEPARATOR:58,left_of:59,right_of:60,$accept:0,$end:1},terminals_:{2:"error",4:"SPACE",5:"NL",6:"SD",14:"DESCR",15:"-->",16:"HIDE_EMPTY",17:"scale",18:"WIDTH",19:"COMPOSIT_STATE",20:"STRUCT_START",21:"STRUCT_STOP",22:"STATE_DESCR",23:"AS",24:"ID",25:"FORK",26:"JOIN",27:"CHOICE",28:"CONCURRENT",29:"note",31:"NOTE_TEXT",33:"acc_title",34:"acc_title_value",35:"acc_descr",36:"acc_descr_value",37:"acc_descr_multiline_value",38:"CLICK",39:"STRING",40:"HREF",41:"classDef",42:"CLASSDEF_ID",43:"CLASSDEF_STYLEOPTS",44:"DEFAULT",45:"style",46:"STYLE_IDS",47:"STYLEDEF_STYLEOPTS",48:"class",49:"CLASSENTITY_IDS",50:"STYLECLASS",51:"direction_tb",52:"direction_bt",53:"direction_rl",54:"direction_lr",56:";",57:"EDGE_STATE",58:"STYLE_SEPARATOR",59:"left_of",60:"right_of"},productions_:[0,[3,2],[3,2],[3,2],[7,0],[7,2],[8,2],[8,1],[8,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,3],[9,4],[9,1],[9,2],[9,1],[9,4],[9,3],[9,6],[9,1],[9,1],[9,1],[9,1],[9,4],[9,4],[9,1],[9,2],[9,2],[9,1],[9,5],[9,5],[10,3],[10,3],[11,3],[12,3],[32,1],[32,1],[32,1],[32,1],[55,1],[55,1],[13,1],[13,1],[13,3],[13,3],[30,1],[30,1]],performAction:t(function(c,f,a,k,_,i,it){var h=i.length-1;switch(_){case 3:return k.setRootDoc(i[h]),i[h];break;case 4:this.$=[];break;case 5:if(i[h]!="nl")i[h-1].push(i[h]),this.$=i[h-1];break;case 6:case 7:this.$=i[h];break;case 8:this.$="nl";break;case 12:this.$=i[h];break;case 13:let _t=i[h-1];_t.description=k.trimColon(i[h]),this.$=_t;break;case 14:this.$={stmt:"relation",state1:i[h-2],state2:i[h]};break;case 15:let vt=k.trimColon(i[h]);this.$={stmt:"relation",state1:i[h-3],state2:i[h-1],description:vt};break;case 19:this.$={stmt:"state",id:i[h-3],type:"default",description:"",doc:i[h-1]};break;case 20:var K=i[h],X=i[h-2].trim();if(i[h].match(":")){var lt=i[h].split(":");K=lt[0],X=[X,lt[1]]}this.$={stmt:"state",id:K,type:"default",description:X};break;case 21:this.$={stmt:"state",id:i[h-3],type:"default",description:i[h-5],doc:i[h-1]};break;case 22:this.$={stmt:"state",id:i[h],type:"fork"};break;case 23:this.$={stmt:"state",id:i[h],type:"join"};break;case 24:this.$={stmt:"state",id:i[h],type:"choice"};break;case 25:this.$={stmt:"state",id:k.getDividerId(),type:"divider"};break;case 26:this.$={stmt:"state",id:i[h-1].trim(),note:{position:i[h-2].trim(),text:i[h].trim()}};break;case 29:this.$=i[h].trim(),k.setAccTitle(this.$);break;case 30:case 31:this.$=i[h].trim(),k.setAccDescription(this.$);break;case 32:this.$={stmt:"click",id:i[h-3],url:i[h-2],tooltip:i[h-1]};break;case 33:this.$={stmt:"click",id:i[h-3],url:i[h-1],tooltip:""};break;case 34:case 35:this.$={stmt:"classDef",id:i[h-1].trim(),classes:i[h].trim()};break;case 36:this.$={stmt:"style",id:i[h-1].trim(),styleClass:i[h].trim()};break;case 37:this.$={stmt:"applyClass",id:i[h-1].trim(),styleClass:i[h].trim()};break;case 38:k.setDirection("TB"),this.$={stmt:"dir",value:"TB"};break;case 39:k.setDirection("BT"),this.$={stmt:"dir",value:"BT"};break;case 40:k.setDirection("RL"),this.$={stmt:"dir",value:"RL"};break;case 41:k.setDirection("LR"),this.$={stmt:"dir",value:"LR"};break;case 44:case 45:this.$={stmt:"state",id:i[h].trim(),type:"default",description:""};break;case 46:this.$={stmt:"state",id:i[h-2].trim(),classes:[i[h].trim()],type:"default",description:""};break;case 47:this.$={stmt:"state",id:i[h-2].trim(),classes:[i[h].trim()],type:"default",description:""};break}},"anonymous"),table:[{3:1,4:s,5:o,6:r},{1:[3]},{3:5,4:s,5:o,6:r},{3:6,4:s,5:o,6:r},e([1,4,5,16,17,19,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],d,{7:7}),{1:[2,1]},{1:[2,2]},{1:[2,3],4:u,5:S,8:8,9:10,10:12,11:13,12:14,13:15,16:g,17:n,19:T,22:E,24:I,25:N,26:B,27:C,28:p,29:R,32:25,33:A,35:W,37:P,38:U,41:D,45:st,48:St,51:gt,52:yt,53:bt,54:kt,57:rt},e(y,[2,5]),{9:39,10:12,11:13,12:14,13:15,16:g,17:n,19:T,22:E,24:I,25:N,26:B,27:C,28:p,29:R,32:25,33:A,35:W,37:P,38:U,41:D,45:st,48:St,51:gt,52:yt,53:bt,54:kt,57:rt},e(y,[2,7]),e(y,[2,8]),e(y,[2,9]),e(y,[2,10]),e(y,[2,11]),e(y,[2,12],{14:[1,40],15:[1,41]}),e(y,[2,16]),{18:[1,42]},e(y,[2,18],{20:[1,43]}),{23:[1,44]},e(y,[2,22]),e(y,[2,23]),e(y,[2,24]),e(y,[2,25]),{30:45,31:[1,46],59:[1,47],60:[1,48]},e(y,[2,28]),{34:[1,49]},{36:[1,50]},e(y,[2,31]),{13:51,24:I,57:rt},{42:[1,52],44:[1,53]},{46:[1,54]},{49:[1,55]},e(Tt,[2,44],{58:[1,56]}),e(Tt,[2,45],{58:[1,57]}),e(y,[2,38]),e(y,[2,39]),e(y,[2,40]),e(y,[2,41]),e(y,[2,6]),e(y,[2,13]),{13:58,24:I,57:rt},e(y,[2,17]),e(Kt,d,{7:59}),{24:[1,60]},{24:[1,61]},{23:[1,62]},{24:[2,48]},{24:[2,49]},e(y,[2,29]),e(y,[2,30]),{39:[1,63],40:[1,64]},{43:[1,65]},{43:[1,66]},{47:[1,67]},{50:[1,68]},{24:[1,69]},{24:[1,70]},e(y,[2,14],{14:[1,71]}),{4:u,5:S,8:8,9:10,10:12,11:13,12:14,13:15,16:g,17:n,19:T,21:[1,72],22:E,24:I,25:N,26:B,27:C,28:p,29:R,32:25,33:A,35:W,37:P,38:U,41:D,45:st,48:St,51:gt,52:yt,53:bt,54:kt,57:rt},e(y,[2,20],{20:[1,73]}),{31:[1,74]},{24:[1,75]},{39:[1,76]},{39:[1,77]},e(y,[2,34]),e(y,[2,35]),e(y,[2,36]),e(y,[2,37]),e(Tt,[2,46]),e(Tt,[2,47]),e(y,[2,15]),e(y,[2,19]),e(Kt,d,{7:78}),e(y,[2,26]),e(y,[2,27]),{5:[1,79]},{5:[1,80]},{4:u,5:S,8:8,9:10,10:12,11:13,12:14,13:15,16:g,17:n,19:T,21:[1,81],22:E,24:I,25:N,26:B,27:C,28:p,29:R,32:25,33:A,35:W,37:P,38:U,41:D,45:st,48:St,51:gt,52:yt,53:bt,54:kt,57:rt},e(y,[2,32]),e(y,[2,33]),e(y,[2,21])],defaultActions:{5:[2,1],6:[2,2],47:[2,48],48:[2,49]},parseError:t(function(c,f){if(f.recoverable)this.trace(c);else{var a=Error(c);throw a.hash=f,a}},"parseError"),parse:t(function(c){var f=this,a=[0],k=[],_=[null],i=[],it=this.table,h="",K=0,X=0,lt=0,_t=2,vt=1,me=i.slice.call(arguments,1),v=Object.create(this.lexer),tt={yy:{}};for(var Ot in this.yy)if(Object.prototype.hasOwnProperty.call(this.yy,Ot))tt.yy[Ot]=this.yy[Ot];if(v.setInput(c,tt.yy),tt.yy.lexer=v,tt.yy.parser=this,typeof v.yylloc>"u")v.yylloc={};var Rt=v.yylloc;i.push(Rt);var be=v.options&&v.options.ranges;if(typeof tt.yy.parseError==="function")this.parseError=tt.yy.parseError;else this.parseError=Object.getPrototypeOf(this).parseError;function ke(M){a.length=a.length-2*M,_.length=_.length-M,i.length=i.length-M}t(ke,"popStack");function Xt(){var M=k.pop()||v.lex()||vt;if(typeof M!=="number"){if(M instanceof Array)k=M,M=k.pop();M=f.symbols_[M]||M}return M}t(Xt,"lex");var x,Ft,et,Y,Qe,Pt,at={},Dt,J,Jt,At;while(!0){if(et=a[a.length-1],this.defaultActions[et])Y=this.defaultActions[et];else{if(x===null||typeof x>"u")x=Xt();Y=it[et]&&it[et][x]}if(typeof Y>"u"||!Y.length||!Y[0]){var Bt="";At=[];for(Dt in it[et])if(this.terminals_[Dt]&&Dt>_t)At.push("'"+this.terminals_[Dt]+"'");if(v.showPosition)Bt="Parse error on line "+(K+1)+`:
2
2
  `+v.showPosition()+`
3
- Expecting `+At.join(", ")+", got '"+(this.terminals_[x]||x)+"'";else Yt="Parse error on line "+(K+1)+": Unexpected "+(x==Dt?"end of input":"'"+(this.terminals_[x]||x)+"'");this.parseError(Yt,{text:v.match,token:this.terminals_[x]||x,line:v.yylineno,loc:Ft,expected:At})}if(Y[0]instanceof Array&&Y.length>1)throw Error("Parse Error: multiple actions possible at state: "+et+", token: "+x);switch(Y[0]){case 1:if(a.push(x),_.push(v.yytext),i.push(v.yylloc),a.push(Y[1]),x=null,!Bt){if(X=v.yyleng,h=v.yytext,K=v.yylineno,Ft=v.yylloc,lt>0)lt--}else x=Bt,Bt=null;break;case 2:if(J=this.productions_[Y[1]][1],at.$=_[_.length-J],at._$={first_line:i[i.length-(J||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(J||1)].first_column,last_column:i[i.length-1].last_column},be)at._$.range=[i[i.length-(J||1)].range[0],i[i.length-1].range[1]];if(Gt=this.performAction.apply(at,[h,X,K,tt.yy,Y[1],_,i].concat(me)),typeof Gt<"u")return Gt;if(J)a=a.slice(0,-1*J*2),_=_.slice(0,-1*J),i=i.slice(0,-1*J);a.push(this.productions_[Y[1]][0]),_.push(at.$),i.push(at._$),Jt=it[a[a.length-2]][a[a.length-1]],a.push(Jt);break;case 3:return!0}}return!0},"parse")},ye=function(){var Q={EOF:1,parseError:t(function(f,a){if(this.yy.parser)this.yy.parser.parseError(f,a);else throw Error(f)},"parseError"),setInput:t(function(c,f){if(this.yy=f||this.yy||{},this._input=c,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges)this.yylloc.range=[0,0];return this.offset=0,this},"setInput"),input:t(function(){var c=this._input[0];this.yytext+=c,this.yyleng++,this.offset++,this.match+=c,this.matched+=c;var f=c.match(/(?:\r\n?|\n).*/g);if(f)this.yylineno++,this.yylloc.last_line++;else this.yylloc.last_column++;if(this.options.ranges)this.yylloc.range[1]++;return this._input=this._input.slice(1),c},"input"),unput:t(function(c){var f=c.length,a=c.split(/(?:\r\n?|\n)/g);this._input=c+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-f),this.offset-=f;var k=this.match.split(/(?:\r\n?|\n)/g);if(this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),a.length-1)this.yylineno-=a.length-1;var _=this.yylloc.range;if(this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:a?(a.length===k.length?this.yylloc.first_column:0)+k[k.length-a.length].length-a[0].length:this.yylloc.first_column-f},this.options.ranges)this.yylloc.range=[_[0],_[0]+this.yyleng-f];return this.yyleng=this.yytext.length,this},"unput"),more:t(function(){return this._more=!0,this},"more"),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
3
+ Expecting `+At.join(", ")+", got '"+(this.terminals_[x]||x)+"'";else Bt="Parse error on line "+(K+1)+": Unexpected "+(x==vt?"end of input":"'"+(this.terminals_[x]||x)+"'");this.parseError(Bt,{text:v.match,token:this.terminals_[x]||x,line:v.yylineno,loc:Rt,expected:At})}if(Y[0]instanceof Array&&Y.length>1)throw Error("Parse Error: multiple actions possible at state: "+et+", token: "+x);switch(Y[0]){case 1:if(a.push(x),_.push(v.yytext),i.push(v.yylloc),a.push(Y[1]),x=null,!Ft){if(X=v.yyleng,h=v.yytext,K=v.yylineno,Rt=v.yylloc,lt>0)lt--}else x=Ft,Ft=null;break;case 2:if(J=this.productions_[Y[1]][1],at.$=_[_.length-J],at._$={first_line:i[i.length-(J||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(J||1)].first_column,last_column:i[i.length-1].last_column},be)at._$.range=[i[i.length-(J||1)].range[0],i[i.length-1].range[1]];if(Pt=this.performAction.apply(at,[h,X,K,tt.yy,Y[1],_,i].concat(me)),typeof Pt<"u")return Pt;if(J)a=a.slice(0,-1*J*2),_=_.slice(0,-1*J),i=i.slice(0,-1*J);a.push(this.productions_[Y[1]][0]),_.push(at.$),i.push(at._$),Jt=it[a[a.length-2]][a[a.length-1]],a.push(Jt);break;case 3:return!0}}return!0},"parse")},ye=function(){var Q={EOF:1,parseError:t(function(f,a){if(this.yy.parser)this.yy.parser.parseError(f,a);else throw Error(f)},"parseError"),setInput:t(function(c,f){if(this.yy=f||this.yy||{},this._input=c,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges)this.yylloc.range=[0,0];return this.offset=0,this},"setInput"),input:t(function(){var c=this._input[0];this.yytext+=c,this.yyleng++,this.offset++,this.match+=c,this.matched+=c;var f=c.match(/(?:\r\n?|\n).*/g);if(f)this.yylineno++,this.yylloc.last_line++;else this.yylloc.last_column++;if(this.options.ranges)this.yylloc.range[1]++;return this._input=this._input.slice(1),c},"input"),unput:t(function(c){var f=c.length,a=c.split(/(?:\r\n?|\n)/g);this._input=c+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-f),this.offset-=f;var k=this.match.split(/(?:\r\n?|\n)/g);if(this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),a.length-1)this.yylineno-=a.length-1;var _=this.yylloc.range;if(this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:a?(a.length===k.length?this.yylloc.first_column:0)+k[k.length-a.length].length-a[0].length:this.yylloc.first_column-f},this.options.ranges)this.yylloc.range=[_[0],_[0]+this.yyleng-f];return this.yyleng=this.yytext.length,this},"unput"),more:t(function(){return this._more=!0,this},"more"),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
4
4
  `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:t(function(c){this.unput(this.match.slice(c))},"less"),pastInput:t(function(){var c=this.matched.substr(0,this.matched.length-this.match.length);return(c.length>20?"...":"")+c.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:t(function(){var c=this.match;if(c.length<20)c+=this._input.substr(0,20-c.length);return(c.substr(0,20)+(c.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:t(function(){var c=this.pastInput(),f=Array(c.length+1).join("-");return c+this.upcomingInput()+`
5
5
  `+f+"^"},"showPosition"),test_match:t(function(c,f){var a,k,_;if(this.options.backtrack_lexer){if(_={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges)_.yylloc.range=this.yylloc.range.slice(0)}if(k=c[0].match(/(?:\r\n?|\n).*/g),k)this.yylineno+=k.length;if(this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:k?k[k.length-1].length-k[k.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+c[0].length},this.yytext+=c[0],this.match+=c[0],this.matches=c,this.yyleng=this.yytext.length,this.options.ranges)this.yylloc.range=[this.offset,this.offset+=this.yyleng];if(this._more=!1,this._backtrack=!1,this._input=this._input.slice(c[0].length),this.matched+=c[0],a=this.performAction.call(this,this.yy,this,f,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input)this.done=!1;if(a)return a;else if(this._backtrack){for(var i in _)this[i]=_[i];return!1}return!1},"test_match"),next:t(function(){if(this.done)return this.EOF;if(!this._input)this.done=!0;var c,f,a,k;if(!this._more)this.yytext="",this.match="";var _=this._currentRules();for(var i=0;i<_.length;i++)if(a=this._input.match(this.rules[_[i]]),a&&(!f||a[0].length>f[0].length)){if(f=a,k=i,this.options.backtrack_lexer)if(c=this.test_match(a,_[i]),c!==!1)return c;else if(this._backtrack){f=!1;continue}else return!1;else if(!this.options.flex)break}if(f){if(c=this.test_match(f,_[k]),c!==!1)return c;return!1}if(this._input==="")return this.EOF;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
6
- `+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:t(function(){var f=this.next();if(f)return f;else return this.lex()},"lex"),begin:t(function(f){this.conditionStack.push(f)},"begin"),popState:t(function(){var f=this.conditionStack.length-1;if(f>0)return this.conditionStack.pop();else return this.conditionStack[0]},"popState"),_currentRules:t(function(){if(this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1])return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules;else return this.conditions.INITIAL.rules},"_currentRules"),topState:t(function(f){if(f=this.conditionStack.length-1-Math.abs(f||0),f>=0)return this.conditionStack[f];else return"INITIAL"},"topState"),pushState:t(function(f){this.begin(f)},"pushState"),stateStackSize:t(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:t(function(f,a,k,_){function i(){let h=a.yytext.indexOf("%%");if(h===0)return!1;if(h>0){let K=a.yytext.slice(0,h),X=a.yytext.slice(h);if(X)f.lexer.unput(X);a.yytext=K}return!0}t(i,"processId");var it=_;switch(k){case 0:return 38;case 1:return 40;case 2:return 39;case 3:return 44;case 4:return 51;case 5:return 52;case 6:return 53;case 7:return 54;case 8:return 5;case 9:break;case 10:break;case 11:break;case 12:break;case 13:return this.pushState("SCALE"),17;break;case 14:return 18;case 15:this.popState();break;case 16:return this.begin("acc_title"),33;break;case 17:return this.popState(),"acc_title_value";break;case 18:return this.begin("acc_descr"),35;break;case 19:return this.popState(),"acc_descr_value";break;case 20:this.begin("acc_descr_multiline");break;case 21:this.popState();break;case 22:return"acc_descr_multiline_value";case 23:return this.pushState("CLASSDEF"),41;break;case 24:return this.popState(),this.pushState("CLASSDEFID"),"DEFAULT_CLASSDEF_ID";break;case 25:return this.popState(),this.pushState("CLASSDEFID"),42;break;case 26:return this.popState(),43;break;case 27:return this.pushState("CLASS"),48;break;case 28:return this.popState(),this.pushState("CLASS_STYLE"),49;break;case 29:return this.popState(),50;break;case 30:return this.pushState("STYLE"),45;break;case 31:return this.popState(),this.pushState("STYLEDEF_STYLES"),46;break;case 32:return this.popState(),47;break;case 33:return this.pushState("SCALE"),17;break;case 34:return 18;case 35:this.popState();break;case 36:this.pushState("STATE");break;case 37:return this.popState(),a.yytext=a.yytext.slice(0,-8).trim(),25;break;case 38:return this.popState(),a.yytext=a.yytext.slice(0,-8).trim(),26;break;case 39:return this.popState(),a.yytext=a.yytext.slice(0,-10).trim(),27;break;case 40:return this.popState(),a.yytext=a.yytext.slice(0,-8).trim(),25;break;case 41:return this.popState(),a.yytext=a.yytext.slice(0,-8).trim(),26;break;case 42:return this.popState(),a.yytext=a.yytext.slice(0,-10).trim(),27;break;case 43:return 51;case 44:return 52;case 45:return 53;case 46:return 54;case 47:this.pushState("STATE_STRING");break;case 48:return this.pushState("STATE_ID"),"AS";break;case 49:if(!i())return;return this.popState(),"ID";break;case 50:this.popState();break;case 51:return"STATE_DESCR";case 52:throw Error('Error: State name must be a single word. Found: "'+a.yytext.trim()+'"');case 53:return 19;case 54:this.popState();break;case 55:return this.popState(),this.pushState("struct"),20;break;case 56:return this.popState(),21;break;case 57:break;case 58:return this.begin("NOTE"),29;break;case 59:return this.popState(),this.pushState("NOTE_ID"),59;break;case 60:return this.popState(),this.pushState("NOTE_ID"),60;break;case 61:this.popState(),this.pushState("FLOATING_NOTE");break;case 62:return this.popState(),this.pushState("FLOATING_NOTE_ID"),"AS";break;case 63:break;case 64:return"NOTE_TEXT";case 65:if(!i())return;return this.popState(),"ID";break;case 66:if(!i())return;return this.popState(),this.pushState("NOTE_TEXT"),24;break;case 67:return this.popState(),a.yytext=a.yytext.substr(2).trim(),31;break;case 68:return this.popState(),a.yytext=a.yytext.slice(0,-8).trim(),31;break;case 69:return 6;case 70:return 6;case 71:return 16;case 72:return 57;case 73:if(!i())return;return 24;case 74:return a.yytext=a.yytext.trim(),14;break;case 75:return 15;case 76:return 28;case 77:return 58;case 78:return 5;case 79:return"INVALID"}},"anonymous"),rules:[/^(?:click\b)/i,/^(?:href\b)/i,/^(?:"[^"]*")/i,/^(?:default\b)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:[\n]+)/i,/^(?:[\s]+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%%(?!\{)[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:classDef\s+)/i,/^(?:DEFAULT\s+)/i,/^(?:\w+\s+)/i,/^(?:[^\n]*)/i,/^(?:class\s+)/i,/^(?:(\w+)+((,\s*\w+)*))/i,/^(?:[^\n]*)/i,/^(?:style\s+)/i,/^(?:[\w,]+\s+)/i,/^(?:[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:state\s+)/i,/^(?:.*<<fork>>)/i,/^(?:.*<<join>>)/i,/^(?:.*<<choice>>)/i,/^(?:.*\[\[fork\]\])/i,/^(?:.*\[\[join\]\])/i,/^(?:.*\[\[choice\]\])/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:["])/i,/^(?:\s*as\s+)/i,/^(?:[^\n\{]*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:\w+\s+\w+.*?\{)/i,/^(?:[^\n\s\{]+)/i,/^(?:\n)/i,/^(?:\{)/i,/^(?:\})/i,/^(?:[\n])/i,/^(?:note\s+)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:")/i,/^(?:\s*as\s*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[^\n]*)/i,/^(?:\s*[^:\n\s\-]+)/i,/^(?:\s*:[^:\n;]+)/i,/^(?:[\s\S]*?\n\s*end note\b)/i,/^(?:stateDiagram\s+)/i,/^(?:stateDiagram-v2\s+)/i,/^(?:hide empty description\b)/i,/^(?:\[\*\])/i,/^(?:[^:\n\s\-\{]+)/i,/^(?:\s*:(?:[^:\n;]|:[^:\n;])+)/i,/^(?:-->)/i,/^(?:--)/i,/^(?::::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[10,11,12],inclusive:!1},struct:{rules:[10,11,12,23,27,30,36,43,44,45,46,56,57,58,72,73,74,75,76,77],inclusive:!1},FLOATING_NOTE_ID:{rules:[65],inclusive:!1},FLOATING_NOTE:{rules:[62,63,64],inclusive:!1},NOTE_TEXT:{rules:[67,68],inclusive:!1},NOTE_ID:{rules:[66],inclusive:!1},NOTE:{rules:[59,60,61],inclusive:!1},STYLEDEF_STYLEOPTS:{rules:[],inclusive:!1},STYLEDEF_STYLES:{rules:[32],inclusive:!1},STYLE_IDS:{rules:[],inclusive:!1},STYLE:{rules:[31],inclusive:!1},CLASS_STYLE:{rules:[29],inclusive:!1},CLASS:{rules:[28],inclusive:!1},CLASSDEFID:{rules:[26],inclusive:!1},CLASSDEF:{rules:[24,25],inclusive:!1},acc_descr_multiline:{rules:[21,22],inclusive:!1},acc_descr:{rules:[19],inclusive:!1},acc_title:{rules:[17],inclusive:!1},SCALE:{rules:[14,15,34,35],inclusive:!1},ALIAS:{rules:[],inclusive:!1},STATE_ID:{rules:[49],inclusive:!1},STATE_STRING:{rules:[50,51],inclusive:!1},FORK_STATE:{rules:[],inclusive:!1},STATE:{rules:[10,11,12,37,38,39,40,41,42,47,48,52,53,54,55],inclusive:!1},ID:{rules:[10,11,12],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,11,12,13,16,18,20,23,27,30,33,36,55,58,69,70,71,72,73,74,75,77,78,79],inclusive:!0}}};return Q}();Nt.lexer=ye;function _t(){this.yy={}}return t(_t,"Parser"),_t.prototype=Nt,Nt.Parser=_t,new _t}();Wt.parser=Wt;var Te=Wt,Ee="TB",re="TB",qt="dir",ot="state",nt="root",jt="relation",_e="classDef",ve="style",De="applyClass",ft="default",ie="divider",ae="fill:none",ne="fill: #333",oe="c",le="markdown",ce="normal",Vt="rect",Mt="rectWithTitle",Ce="stateStart",Ae="stateEnd",Ut="divider",Qt="roundedWithTitle",xe="note",Le="noteGroup",St="statediagram",we="state",Ie=`${St}-${we}`,he="transition",Ne="note",Oe="note-edge",Re=`${he} ${Oe}`,$e=`${St}-${Ne}`,Fe="cluster",Pe=`${St}-${Fe}`,Be="cluster-alt",Ge=`${St}-${Be}`,de="parent",ue="note",Ye="state",zt="----",Ve=`${zt}${ue}`,Zt=`${zt}${de}`,wt=new Map,Z=0,fe=0,ct=new Map,Me=t((e,s,o,r)=>{if(e===Ut&&o?.id!==void 0&&ct.has(o.id)){let S=ct.get(o.id);return ct.set(s,S),S}let d=fe++,u=r?void 0:d;return ct.set(s,u),u},"colorSlotFor");function It(e="",s=0,o="",r=zt){let d=o!==null&&o.length>0?`${r}${o}`:"";return`${Ye}-${e}${d}-${s}`}t(It,"stateDomId");var We=t((e,s,o,r,d,u,S,g)=>{l.trace("items",s),s.forEach((n)=>{switch(n.stmt){case ot:ut(e,n,o,r,d,u,S,g);break;case ft:ut(e,n,o,r,d,u,S,g);break;case jt:{ut(e,n.state1,o,r,d,u,S,g),ut(e,n.state2,o,r,d,u,S,g);let T=S==="neo",E={id:"edge"+Z,start:n.state1.id,end:n.state2.id,arrowhead:"normal",arrowTypeEnd:T?"arrow_barb_neo":"arrow_barb",style:ae,labelStyle:"",label:w.sanitizeText(n.description??"",m()),arrowheadStyle:ne,labelpos:oe,labelType:le,thickness:ce,classes:he,look:S};d.push(E),Z++}break}})},"setupDoc"),te=t((e,s=re)=>{let o=s;if(e.doc){for(let r of e.doc)if(r.stmt==="dir")o=r.value}return o},"getDir");function ht(e,s,o){if(!s.id||s.id==="</join></fork>"||s.id==="</choice>")return;if(s.cssClasses){if(!Array.isArray(s.cssCompiledStyles))s.cssCompiledStyles=[];s.cssClasses.split(" ").forEach((d)=>{let u=o.get(d);if(u)s.cssCompiledStyles=[...s.cssCompiledStyles??[],...u.styles]})}let r=e.find((d)=>d.id===s.id);if(r)Object.assign(r,s);else e.push(s)}t(ht,"insertOrUpdateNode");function pe(e){return e?.classes?.join(" ")??""}t(pe,"getClassesFromDbInfo");function Se(e){return e?.styles??[]}t(Se,"getStylesFromDbInfo");var ut=t((e,s,o,r,d,u,S,g)=>{let n=s.id,T=o.get(n),E=pe(T),I=Se(T),N=m(),B=E.trim()!==""||I.length>0;if(l.info("dataFetcher parsedItem",s,T,I),n!=="root"){let C=Vt;if(s.start===!0)C=Ce;else if(s.start===!1)C=Ae;if(s.type!==ft)C=s.type;if(!wt.get(n))wt.set(n,{id:n,shape:C,description:w.sanitizeText(n,N),cssClasses:`${E} ${Ie}`,cssStyles:I});let p=wt.get(n);if(s.description){if(Array.isArray(p.description))p.shape=Mt,p.description.push(s.description);else if(p.description?.length&&p.description.length>0)if(p.shape=Mt,p.description===n)p.description=[s.description];else p.description=[p.description,s.description];else p.shape=Vt,p.description=s.description;p.description=w.sanitizeTextOrArray(p.description,N)}if(p.description?.length===1&&p.shape===Mt)if(p.type==="group")p.shape=Qt;else p.shape=Vt;if(!p.type&&s.doc)l.info("Setting cluster for XCX",n,te(s)),p.type="group",p.isGroup=!0,p.dir=te(s),p.shape=s.type===ie?Ut:Qt,p.colorIndex=Me(p.shape,n,e,B),p.cssClasses=`${p.cssClasses} ${Pe} ${u?Ge:""}`;let R={labelStyle:"",shape:p.shape,label:p.description,cssClasses:p.cssClasses,cssCompiledStyles:[],cssStyles:p.cssStyles,id:n,dir:p.dir,domId:It(n,Z),type:p.type,isGroup:p.type==="group",colorIndex:p.colorIndex,padding:8,rx:10,ry:10,look:S,labelType:"markdown"};if(R.shape===Ut)R.label="";if(e&&e.id!=="root")l.trace("Setting node ",n," to be child of its parent ",e.id),R.parentId=e.id;if(R.centerLabel=!0,s.note){let A={labelStyle:"",shape:xe,label:s.note.text,labelType:"markdown",cssClasses:$e,cssStyles:[],cssCompiledStyles:[],id:n+Ve+"-"+Z,domId:It(n,Z,ue),type:"node",isGroup:!1,padding:N.flowchart?.padding,look:S,position:s.note.position},W=n+Zt,P={labelStyle:"",shape:Le,label:s.note.text,cssClasses:p.cssClasses,cssStyles:[],id:n+Zt,domId:It(n,Z,de),type:"group",isGroup:!0,padding:16,look:S,position:s.note.position};Z++,P.id=W,A.parentId=W,ht(r,P,g),ht(r,A,g),ht(r,R,g);let U=n,D=A.id;if(s.note.position==="left of")U=A.id,D=n;d.push({id:U+"-"+D,start:U,end:D,arrowhead:"none",arrowTypeEnd:"",style:ae,labelStyle:"",classes:Re,pattern:"dashed",arrowheadStyle:ne,labelpos:oe,labelType:le,thickness:ce,look:S})}else ht(r,R,g)}if(s.doc)l.trace("Adding nodes children "),We(s,s.doc,o,r,d,!u,S,g)},"dataFetcher"),je=t(()=>{wt.clear(),Z=0,fe=0,ct.clear()},"reset"),ge=t((e,s=re)=>{if(!e.doc)return s;let o=s;for(let r of e.doc)if(r.stmt==="dir")o=r.value;return o},"getDir"),Ue=t(function(e,s){return s.db.getClasses()},"getClasses"),He=t(async function(e,s,o,r){l.info("REF0:"),l.info("Drawing state diagram (v2)",s);let{securityLevel:d,state:u,layout:S}=m();r.db.extract(r.db.getRootDocV2());let g=r.db.getData(),n=$t(s,d);if(g.type=r.type,g.layoutAlgorithm=Ot(S),g.nodeSpacing=u?.nodeSpacing||50,g.rankSpacing=u?.rankSpacing||50,m().look==="neo")g.markers=["barbNeo"];else g.markers=["barb"];g.diagramId=s,await Pt(g,n);let E=8;try{(typeof r.db.getLinks==="function"?r.db.getLinks():new Map).forEach((N,B)=>{let C=typeof B==="string"?B:typeof B?.id==="string"?B.id:"",p=g.nodes.find((D)=>D.id===C);if(!C){l.warn("⚠️ Invalid or missing stateId from key:",JSON.stringify(B));return}let R=n.node()?.querySelectorAll("g.node, g.rough-node"),A;if(R?.forEach((D)=>{let st=D.textContent?.trim();if(D.id===p?.domId||st===C)A=D}),!A){l.warn("⚠️ Could not find node matching text:",C);return}let W=A.parentNode;if(!W){l.warn("⚠️ Node has no parent, cannot wrap:",C);return}let P=document.createElementNS("http://www.w3.org/2000/svg","a"),U=N.url.replace(/^"+|"+$/g,"");if(P.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",U),P.setAttribute("target","_blank"),N.tooltip){let D=N.tooltip.replace(/^"+|"+$/g,"");P.setAttribute("title",D),A.setAttribute("title",D)}W.replaceChild(P,A),P.appendChild(A),l.info("\uD83D\uDD17 Wrapped node in <a> tag for:",C,N.url)})}catch(I){l.error("❌ Error injecting clickable links:",I)}V.insertTitle(n,"statediagramTitleText",u?.titleTopMargin??25,r.db.getDiagramTitle()),xt(n,E,St,u?.useMaxWidth??!0)},"draw"),ze={getClasses:Ue,draw:He,getDir:ge},L={START_NODE:"[*]",START_TYPE:"start",END_NODE:"[*]",END_TYPE:"end",COLOR_KEYWORD:"color",FILL_KEYWORD:"fill",BG_FILL:"bgFill",STYLECLASS_SEP:","},ee=t(()=>new Map,"newClassesList"),se=t(()=>({relations:[],states:new Map,documents:{}}),"newDoc"),Lt=t((e)=>JSON.parse(JSON.stringify(e)),"clone"),Ke=class{constructor(e){this.version=e,this.nodes=[],this.edges=[],this.rootDoc=[],this.classes=ee(),this.documents={root:se()},this.currentDocument=this.documents.root,this.startEndCount=0,this.dividerCnt=0,this.links=new Map,this.funs=[],this.getAccTitle=G,this.setAccTitle=O,this.getAccDescription=j,this.setAccDescription=z,this.setDiagramTitle=q,this.getDiagramTitle=H,this.clear(),this.setRootDoc=this.setRootDoc.bind(this),this.getDividerId=this.getDividerId.bind(this),this.setDirection=this.setDirection.bind(this),this.trimColon=this.trimColon.bind(this),this.bindFunctions=this.bindFunctions.bind(this)}static{t(this,"StateDB")}static{this.relationType={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3}}extract(e){this.clear(!0);for(let r of Array.isArray(e)?e:e.doc)switch(r.stmt){case ot:this.addState(r.id.trim(),r.type,r.doc,r.description,r.note);break;case jt:this.addRelation(r.state1,r.state2,r.description);break;case _e:this.addStyleClass(r.id.trim(),r.classes);break;case ve:this.handleStyleDef(r);break;case De:this.setCssClass(r.id.trim(),r.styleClass);break;case"click":this.addLink(r.id,r.url,r.tooltip);break}let s=this.getStates(),o=m();je(),ut(void 0,this.getRootDocV2(),s,this.nodes,this.edges,!0,o.look,this.classes);for(let r of this.nodes){if(!Array.isArray(r.label))continue;if(r.description=r.label.slice(1),r.isGroup&&r.description.length>0)throw Error(`Group nodes can only have label. Remove the additional description for node [${r.id}]`);r.label=r.label[0]}}handleStyleDef(e){let s=e.id.trim().split(","),o=e.styleClass.split(",");for(let r of s){let d=this.getState(r);if(!d){let u=r.trim();this.addState(u),d=this.getState(u)}if(d)d.styles=o.map((u)=>u.replace(/;/g,"")?.trim())}}setRootDoc(e){if(l.info("Setting root doc",e),this.rootDoc=e,this.version===1)this.extract(e);else this.extract(this.getRootDocV2())}docTranslator(e,s,o){if(s.stmt===jt){this.docTranslator(e,s.state1,!0),this.docTranslator(e,s.state2,!1);return}if(s.stmt===ot)if(s.id===L.START_NODE)s.id=e.id+(o?"_start":"_end"),s.start=o;else s.id=s.id.trim();if(s.stmt!==nt&&s.stmt!==ot||!s.doc)return;let r=[],d=[];for(let u of s.doc)if(u.type===ie){let S=Lt(u);S.doc=Lt(d),r.push(S),d=[]}else d.push(u);if(r.length>0&&d.length>0){let u={stmt:ot,id:Wg(),type:"divider",doc:Lt(d)};r.push(Lt(u)),s.doc=r}s.doc.forEach((u)=>this.docTranslator(s,u,!0))}getRootDocV2(){return this.docTranslator({id:nt,stmt:nt},{id:nt,stmt:nt,doc:this.rootDoc},!0),{id:nt,doc:this.rootDoc}}addState(e,s=ft,o=void 0,r=void 0,d=void 0,u=void 0,S=void 0,g=void 0){let n=e?.trim();if(!this.currentDocument.states.has(n))l.info("Adding state ",n,r),this.currentDocument.states.set(n,{stmt:ot,id:n,descriptions:[],type:s,doc:o,note:d,classes:[],styles:[],textStyles:[]});else{let T=this.currentDocument.states.get(n);if(!T)throw Error(`State not found: ${n}`);if(!T.doc)T.doc=o;if(!T.type)T.type=s}if(r)l.info("Setting state description",n,r),(Array.isArray(r)?r:[r]).forEach((E)=>this.addDescription(n,E.trim()));if(d){let T=this.currentDocument.states.get(n);if(!T)throw Error(`State not found: ${n}`);T.note=d,T.note.text=w.sanitizeText(T.note.text,m())}if(u)l.info("Setting state classes",n,u),(Array.isArray(u)?u:[u]).forEach((E)=>this.setCssClass(n,E.trim()));if(S)l.info("Setting state styles",n,S),(Array.isArray(S)?S:[S]).forEach((E)=>this.setStyle(n,E.trim()));if(g)l.info("Setting state styles",n,S),(Array.isArray(g)?g:[g]).forEach((E)=>this.setTextStyle(n,E.trim()))}clear(e){if(this.nodes=[],this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.documents={root:se()},this.currentDocument=this.documents.root,this.startEndCount=0,this.classes=ee(),!e)this.links=new Map,F()}getState(e){return this.currentDocument.states.get(e)}getStates(){return this.currentDocument.states}logDocuments(){l.info("Documents = ",this.documents)}getRelations(){return this.currentDocument.relations}addLink(e,s,o){this.links.set(e,{url:s,tooltip:o}),l.warn("Adding link",e,s,o)}getLinks(){return this.links}startIdIfNeeded(e=""){if(e===L.START_NODE)return this.startEndCount++,`${L.START_TYPE}${this.startEndCount}`;return e}startTypeIfNeeded(e="",s=ft){return e===L.START_NODE?L.START_TYPE:s}endIdIfNeeded(e=""){if(e===L.END_NODE)return this.startEndCount++,`${L.END_TYPE}${this.startEndCount}`;return e}endTypeIfNeeded(e="",s=ft){return e===L.END_NODE?L.END_TYPE:s}addRelationObjs(e,s,o=""){let r=this.startIdIfNeeded(e.id.trim()),d=this.startTypeIfNeeded(e.id.trim(),e.type),u=this.startIdIfNeeded(s.id.trim()),S=this.startTypeIfNeeded(s.id.trim(),s.type);this.addState(r,d,e.doc,e.description,e.note,e.classes,e.styles,e.textStyles),this.addState(u,S,s.doc,s.description,s.note,s.classes,s.styles,s.textStyles),this.currentDocument.relations.push({id1:r,id2:u,relationTitle:w.sanitizeText(o,m())})}addRelation(e,s,o){if(typeof e==="object"&&typeof s==="object")this.addRelationObjs(e,s,o);else if(typeof e==="string"&&typeof s==="string"){let r=this.startIdIfNeeded(e.trim()),d=this.startTypeIfNeeded(e),u=this.endIdIfNeeded(s.trim()),S=this.endTypeIfNeeded(s);this.addState(r,d),this.addState(u,S),this.currentDocument.relations.push({id1:r,id2:u,relationTitle:o?w.sanitizeText(o,m()):void 0})}}addDescription(e,s){let o=this.currentDocument.states.get(e),r=s.startsWith(":")?s.replace(":","").trim():s;o?.descriptions?.push(w.sanitizeText(r,m()))}cleanupLabel(e){return e.startsWith(":")?e.slice(2).trim():e.trim()}getDividerId(){return this.dividerCnt++,`divider-id-${this.dividerCnt}`}addStyleClass(e,s=""){if(!this.classes.has(e))this.classes.set(e,{id:e,styles:[],textStyles:[]});let o=this.classes.get(e);if(s&&o)s.split(L.STYLECLASS_SEP).forEach((r)=>{let d=r.replace(/([^;]*);/,"$1").trim();if(RegExp(L.COLOR_KEYWORD).exec(r)){let S=d.replace(L.FILL_KEYWORD,L.BG_FILL).replace(L.COLOR_KEYWORD,L.FILL_KEYWORD);o.textStyles.push(S)}o.styles.push(d)})}getClasses(){return this.classes}setupToolTips(e){let s=Za();b(e).select("svg").selectAll("g.node, g.rough-node").on("mouseover",(d)=>{let u=b(d.currentTarget),S=u.attr("title");if(S===null)return;let g=d.currentTarget?.getBoundingClientRect();s.transition().duration(200).style("opacity",".9"),s.style("left",window.scrollX+g.left+(g.right-g.left)/2+"px").style("top",window.scrollY+g.bottom+"px"),s.html(Ht.sanitize(S)),u.classed("hover",!0)}).on("mouseout",(d)=>{s.transition().duration(500).style("opacity",0),b(d.currentTarget).classed("hover",!1)})}setCssClass(e,s){e.split(",").forEach((o)=>{let r=this.getState(o);if(!r){let d=o.trim();this.addState(d),r=this.getState(d)}r?.classes?.push(s)})}setStyle(e,s){this.getState(e)?.styles?.push(s)}setTextStyle(e,s){this.getState(e)?.textStyles?.push(s)}bindFunctions(e){this.funs.forEach((s)=>{s(e)})}getDirectionStatement(){return this.rootDoc.find((e)=>e.stmt===qt)}getDirection(){return this.getDirectionStatement()?.value??Ee}setDirection(e){let s=this.getDirectionStatement();if(s)s.value=e;else this.rootDoc.unshift({stmt:qt,value:e})}trimColon(e){return e.startsWith(":")?e.slice(1).trim():e.trim()}getData(){let e=m();for(let s of this.nodes)if(s.wrappingWidth??=e.state?.wrappingWidth,!s.isGroup)s.minWidth??=e.state?.minNodeWidth;return{nodes:this.nodes,edges:this.edges,other:{},config:e,direction:ge(this.getRootDocV2())}}getConfig(){return m().state}},Xe=t((e)=>{let{theme:s,bkgColorArray:o,borderColorArray:r}=e;if(!dt(s,r))return"";let d=pt(e.look),u=kt(o),S="";for(let g=0;g<ta(r);g++){let n=r[g],T=u?`fill: ${o[g%o.length]};`:"",E=`[data-look="${d}"][data-color-id="color-${g}"]`;S+=`
6
+ `+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:t(function(){var f=this.next();if(f)return f;else return this.lex()},"lex"),begin:t(function(f){this.conditionStack.push(f)},"begin"),popState:t(function(){var f=this.conditionStack.length-1;if(f>0)return this.conditionStack.pop();else return this.conditionStack[0]},"popState"),_currentRules:t(function(){if(this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1])return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules;else return this.conditions.INITIAL.rules},"_currentRules"),topState:t(function(f){if(f=this.conditionStack.length-1-Math.abs(f||0),f>=0)return this.conditionStack[f];else return"INITIAL"},"topState"),pushState:t(function(f){this.begin(f)},"pushState"),stateStackSize:t(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:t(function(f,a,k,_){function i(){let h=a.yytext.indexOf("%%");if(h===0)return!1;if(h>0){let K=a.yytext.slice(0,h),X=a.yytext.slice(h);if(X)f.lexer.unput(X);a.yytext=K}return!0}t(i,"processId");var it=_;switch(k){case 0:return 38;case 1:return 40;case 2:return 39;case 3:return 44;case 4:return 51;case 5:return 52;case 6:return 53;case 7:return 54;case 8:return 5;case 9:break;case 10:break;case 11:break;case 12:break;case 13:return this.pushState("SCALE"),17;break;case 14:return 18;case 15:this.popState();break;case 16:return this.begin("acc_title"),33;break;case 17:return this.popState(),"acc_title_value";break;case 18:return this.begin("acc_descr"),35;break;case 19:return this.popState(),"acc_descr_value";break;case 20:this.begin("acc_descr_multiline");break;case 21:this.popState();break;case 22:return"acc_descr_multiline_value";case 23:return this.pushState("CLASSDEF"),41;break;case 24:return this.popState(),this.pushState("CLASSDEFID"),"DEFAULT_CLASSDEF_ID";break;case 25:return this.popState(),this.pushState("CLASSDEFID"),42;break;case 26:return this.popState(),43;break;case 27:return this.pushState("CLASS"),48;break;case 28:return this.popState(),this.pushState("CLASS_STYLE"),49;break;case 29:return this.popState(),50;break;case 30:return this.pushState("STYLE"),45;break;case 31:return this.popState(),this.pushState("STYLEDEF_STYLES"),46;break;case 32:return this.popState(),47;break;case 33:return this.pushState("SCALE"),17;break;case 34:return 18;case 35:this.popState();break;case 36:this.pushState("STATE");break;case 37:return this.popState(),a.yytext=a.yytext.slice(0,-8).trim(),25;break;case 38:return this.popState(),a.yytext=a.yytext.slice(0,-8).trim(),26;break;case 39:return this.popState(),a.yytext=a.yytext.slice(0,-10).trim(),27;break;case 40:return this.popState(),a.yytext=a.yytext.slice(0,-8).trim(),25;break;case 41:return this.popState(),a.yytext=a.yytext.slice(0,-8).trim(),26;break;case 42:return this.popState(),a.yytext=a.yytext.slice(0,-10).trim(),27;break;case 43:return 51;case 44:return 52;case 45:return 53;case 46:return 54;case 47:this.pushState("STATE_STRING");break;case 48:return this.pushState("STATE_ID"),"AS";break;case 49:if(!i())return;return this.popState(),"ID";break;case 50:this.popState();break;case 51:return"STATE_DESCR";case 52:throw Error('Error: State name must be a single word. Found: "'+a.yytext.trim()+'"');case 53:return 19;case 54:this.popState();break;case 55:return this.popState(),this.pushState("struct"),20;break;case 56:return this.popState(),21;break;case 57:break;case 58:return this.begin("NOTE"),29;break;case 59:return this.popState(),this.pushState("NOTE_ID"),59;break;case 60:return this.popState(),this.pushState("NOTE_ID"),60;break;case 61:this.popState(),this.pushState("FLOATING_NOTE");break;case 62:return this.popState(),this.pushState("FLOATING_NOTE_ID"),"AS";break;case 63:break;case 64:return"NOTE_TEXT";case 65:if(!i())return;return this.popState(),"ID";break;case 66:if(!i())return;return this.popState(),this.pushState("NOTE_TEXT"),24;break;case 67:return this.popState(),a.yytext=a.yytext.substr(2).trim(),31;break;case 68:return this.popState(),a.yytext=a.yytext.slice(0,-8).trim(),31;break;case 69:return 6;case 70:return 6;case 71:return 16;case 72:return 57;case 73:if(!i())return;return 24;case 74:return a.yytext=a.yytext.trim(),14;break;case 75:return 15;case 76:return 28;case 77:return 58;case 78:return 5;case 79:return"INVALID"}},"anonymous"),rules:[/^(?:click\b)/i,/^(?:href\b)/i,/^(?:"[^"]*")/i,/^(?:default\b)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:[\n]+)/i,/^(?:[\s]+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%%(?!\{)[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:classDef\s+)/i,/^(?:DEFAULT\s+)/i,/^(?:\w+\s+)/i,/^(?:[^\n]*)/i,/^(?:class\s+)/i,/^(?:(\w+)+((,\s*\w+)*))/i,/^(?:[^\n]*)/i,/^(?:style\s+)/i,/^(?:[\w,]+\s+)/i,/^(?:[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:state\s+)/i,/^(?:.*<<fork>>)/i,/^(?:.*<<join>>)/i,/^(?:.*<<choice>>)/i,/^(?:.*\[\[fork\]\])/i,/^(?:.*\[\[join\]\])/i,/^(?:.*\[\[choice\]\])/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:["])/i,/^(?:\s*as\s+)/i,/^(?:[^\n\{]*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:\w+\s+\w+.*?\{)/i,/^(?:[^\n\s\{]+)/i,/^(?:\n)/i,/^(?:\{)/i,/^(?:\})/i,/^(?:[\n])/i,/^(?:note\s+)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:")/i,/^(?:\s*as\s*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[^\n]*)/i,/^(?:\s*[^:\n\s\-]+)/i,/^(?:\s*:[^:\n;]+)/i,/^(?:[\s\S]*?\n\s*end note\b)/i,/^(?:stateDiagram\s+)/i,/^(?:stateDiagram-v2\s+)/i,/^(?:hide empty description\b)/i,/^(?:\[\*\])/i,/^(?:[^:\n\s\-\{]+)/i,/^(?:\s*:(?:[^:\n;]|:[^:\n;])+)/i,/^(?:-->)/i,/^(?:--)/i,/^(?::::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[10,11,12],inclusive:!1},struct:{rules:[10,11,12,23,27,30,36,43,44,45,46,56,57,58,72,73,74,75,76,77],inclusive:!1},FLOATING_NOTE_ID:{rules:[65],inclusive:!1},FLOATING_NOTE:{rules:[62,63,64],inclusive:!1},NOTE_TEXT:{rules:[67,68],inclusive:!1},NOTE_ID:{rules:[66],inclusive:!1},NOTE:{rules:[59,60,61],inclusive:!1},STYLEDEF_STYLEOPTS:{rules:[],inclusive:!1},STYLEDEF_STYLES:{rules:[32],inclusive:!1},STYLE_IDS:{rules:[],inclusive:!1},STYLE:{rules:[31],inclusive:!1},CLASS_STYLE:{rules:[29],inclusive:!1},CLASS:{rules:[28],inclusive:!1},CLASSDEFID:{rules:[26],inclusive:!1},CLASSDEF:{rules:[24,25],inclusive:!1},acc_descr_multiline:{rules:[21,22],inclusive:!1},acc_descr:{rules:[19],inclusive:!1},acc_title:{rules:[17],inclusive:!1},SCALE:{rules:[14,15,34,35],inclusive:!1},ALIAS:{rules:[],inclusive:!1},STATE_ID:{rules:[49],inclusive:!1},STATE_STRING:{rules:[50,51],inclusive:!1},FORK_STATE:{rules:[],inclusive:!1},STATE:{rules:[10,11,12,37,38,39,40,41,42,47,48,52,53,54,55],inclusive:!1},ID:{rules:[10,11,12],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,11,12,13,16,18,20,23,27,30,33,36,55,58,69,70,71,72,73,74,75,77,78,79],inclusive:!0}}};return Q}();Nt.lexer=ye;function Et(){this.yy={}}return t(Et,"Parser"),Et.prototype=Nt,Nt.Parser=Et,new Et}();Vt.parser=Vt;var Te=Vt,Ee="TB",re="TB",qt="dir",ot="state",nt="root",Mt="relation",_e="classDef",ve="style",De="applyClass",ut="default",ie="divider",ae="fill:none",ne="fill: #333",oe="c",le="markdown",ce="normal",Gt="rect",Yt="rectWithTitle",Ce="stateStart",Ae="stateEnd",jt="divider",Qt="roundedWithTitle",xe="note",Le="noteGroup",ft="statediagram",we="state",Ie=`${ft}-${we}`,he="transition",Ne="note",Oe="note-edge",Re=`${he} ${Oe}`,$e=`${ft}-${Ne}`,Fe="cluster",Pe=`${ft}-${Fe}`,Be="cluster-alt",Ge=`${ft}-${Be}`,de="parent",ue="note",Ye="state",Ht="----",Ve=`${Ht}${ue}`,Zt=`${Ht}${de}`,Lt=new Map,Z=0,fe=0,ct=new Map,Me=t((e,s,o,r)=>{if(e===jt&&o?.id!==void 0&&ct.has(o.id)){let S=ct.get(o.id);return ct.set(s,S),S}let d=fe++,u=r?void 0:d;return ct.set(s,u),u},"colorSlotFor");function It(e="",s=0,o="",r=Ht){let d=o!==null&&o.length>0?`${r}${o}`:"";return`${Ye}-${e}${d}-${s}`}t(It,"stateDomId");var We=t((e,s,o,r,d,u,S,g)=>{l.trace("items",s),s.forEach((n)=>{switch(n.stmt){case ot:dt(e,n,o,r,d,u,S,g);break;case ut:dt(e,n,o,r,d,u,S,g);break;case Mt:{dt(e,n.state1,o,r,d,u,S,g),dt(e,n.state2,o,r,d,u,S,g);let T=S==="neo",E={id:"edge"+Z,start:n.state1.id,end:n.state2.id,arrowhead:"normal",arrowTypeEnd:T?"arrow_barb_neo":"arrow_barb",style:ae,labelStyle:"",label:w.sanitizeText(n.description??"",m()),arrowheadStyle:ne,labelpos:oe,labelType:le,thickness:ce,classes:he,look:S};d.push(E),Z++}break}})},"setupDoc"),te=t((e,s=re)=>{let o=s;if(e.doc){for(let r of e.doc)if(r.stmt==="dir")o=r.value}return o},"getDir");function ht(e,s,o){if(!s.id||s.id==="</join></fork>"||s.id==="</choice>")return;if(s.cssClasses){if(!Array.isArray(s.cssCompiledStyles))s.cssCompiledStyles=[];s.cssClasses.split(" ").forEach((d)=>{let u=o.get(d);if(u)s.cssCompiledStyles=[...s.cssCompiledStyles??[],...u.styles]})}let r=e.find((d)=>d.id===s.id);if(r)Object.assign(r,s);else e.push(s)}t(ht,"insertOrUpdateNode");function pe(e){return e?.classes?.join(" ")??""}t(pe,"getClassesFromDbInfo");function Se(e){return e?.styles??[]}t(Se,"getStylesFromDbInfo");var dt=t((e,s,o,r,d,u,S,g)=>{let n=s.id,T=o.get(n),E=pe(T),I=Se(T),N=m(),B=E.trim()!==""||I.length>0;if(l.info("dataFetcher parsedItem",s,T,I),n!=="root"){let C=Gt;if(s.start===!0)C=Ce;else if(s.start===!1)C=Ae;if(s.type!==ut)C=s.type;if(!Lt.get(n))Lt.set(n,{id:n,shape:C,description:w.sanitizeText(n,N),cssClasses:`${E} ${Ie}`,cssStyles:I});let p=Lt.get(n);if(s.description){if(Array.isArray(p.description))p.shape=Yt,p.description.push(s.description);else if(p.description?.length&&p.description.length>0)if(p.shape=Yt,p.description===n)p.description=[s.description];else p.description=[p.description,s.description];else p.shape=Gt,p.description=s.description;p.description=w.sanitizeTextOrArray(p.description,N)}if(p.description?.length===1&&p.shape===Yt)if(p.type==="group")p.shape=Qt;else p.shape=Gt;if(!p.type&&s.doc)l.info("Setting cluster for XCX",n,te(s)),p.type="group",p.isGroup=!0,p.dir=te(s),p.shape=s.type===ie?jt:Qt,p.colorIndex=Me(p.shape,n,e,B),p.cssClasses=`${p.cssClasses} ${Pe} ${u?Ge:""}`;let R={labelStyle:"",shape:p.shape,label:p.description,cssClasses:p.cssClasses,cssCompiledStyles:[],cssStyles:p.cssStyles,id:n,dir:p.dir,domId:It(n,Z),type:p.type,isGroup:p.type==="group",colorIndex:p.colorIndex,padding:8,rx:10,ry:10,look:S,labelType:"markdown"};if(R.shape===jt)R.label="";if(e&&e.id!=="root")l.trace("Setting node ",n," to be child of its parent ",e.id),R.parentId=e.id;if(R.centerLabel=!0,s.note){let A={labelStyle:"",shape:xe,label:s.note.text,labelType:"markdown",cssClasses:$e,cssStyles:[],cssCompiledStyles:[],id:n+Ve+"-"+Z,domId:It(n,Z,ue),type:"node",isGroup:!1,padding:N.flowchart?.padding,look:S,position:s.note.position},W=n+Zt,P={labelStyle:"",shape:Le,label:s.note.text,cssClasses:p.cssClasses,cssStyles:[],id:n+Zt,domId:It(n,Z,de),type:"group",isGroup:!0,padding:16,look:S,position:s.note.position};Z++,P.id=W,A.parentId=W,ht(r,P,g),ht(r,A,g),ht(r,R,g);let U=n,D=A.id;if(s.note.position==="left of")U=A.id,D=n;d.push({id:U+"-"+D,start:U,end:D,arrowhead:"none",arrowTypeEnd:"",style:ae,labelStyle:"",classes:Re,pattern:"dashed",arrowheadStyle:ne,labelpos:oe,labelType:le,thickness:ce,look:S})}else ht(r,R,g)}if(s.doc)l.trace("Adding nodes children "),We(s,s.doc,o,r,d,!u,S,g)},"dataFetcher"),je=t(()=>{Lt.clear(),Z=0,fe=0,ct.clear()},"reset"),ge=t((e,s=re)=>{if(!e.doc)return s;let o=s;for(let r of e.doc)if(r.stmt==="dir")o=r.value;return o},"getDir"),Ue=t(function(e,s){return s.db.getClasses()},"getClasses"),He=t(async function(e,s,o,r){l.info("REF0:"),l.info("Drawing state diagram (v2)",s);let{securityLevel:d,state:u,layout:S}=m();r.db.extract(r.db.getRootDocV2());let g=r.db.getData(),n=Ut(s,d);if(g.type=r.type,g.layoutAlgorithm=zt(S),g.nodeSpacing=u?.nodeSpacing||50,g.rankSpacing=u?.rankSpacing||50,m().look==="neo")g.markers=["barbNeo"];else g.markers=["barb"];g.diagramId=s,await $t(g,n);let E=8;try{(typeof r.db.getLinks==="function"?r.db.getLinks():new Map).forEach((N,B)=>{let C=typeof B==="string"?B:typeof B?.id==="string"?B.id:"",p=g.nodes.find((D)=>D.id===C);if(!C){l.warn("⚠️ Invalid or missing stateId from key:",JSON.stringify(B));return}let R=n.node()?.querySelectorAll("g.node, g.rough-node"),A;if(R?.forEach((D)=>{let st=D.textContent?.trim();if(D.id===p?.domId||st===C)A=D}),!A){l.warn("⚠️ Could not find node matching text:",C);return}let W=A.parentNode;if(!W){l.warn("⚠️ Node has no parent, cannot wrap:",C);return}let P=document.createElementNS("http://www.w3.org/2000/svg","a"),U=N.url.replace(/^"+|"+$/g,"");if(P.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",U),P.setAttribute("target","_blank"),N.tooltip){let D=N.tooltip.replace(/^"+|"+$/g,"");P.setAttribute("title",D),A.setAttribute("title",D)}W.replaceChild(P,A),P.appendChild(A),l.info("\uD83D\uDD17 Wrapped node in <a> tag for:",C,N.url)})}catch(I){l.error("❌ Error injecting clickable links:",I)}V.insertTitle(n,"statediagramTitleText",u?.titleTopMargin??25,r.db.getDiagramTitle()),Ct(n,E,ft,u?.useMaxWidth??!0)},"draw"),ze={getClasses:Ue,draw:He,getDir:ge},L={START_NODE:"[*]",START_TYPE:"start",END_NODE:"[*]",END_TYPE:"end",COLOR_KEYWORD:"color",FILL_KEYWORD:"fill",BG_FILL:"bgFill",STYLECLASS_SEP:","},ee=t(()=>new Map,"newClassesList"),se=t(()=>({relations:[],states:new Map,documents:{}}),"newDoc"),xt=t((e)=>JSON.parse(JSON.stringify(e)),"clone"),Ke=class{constructor(e){this.version=e,this.nodes=[],this.edges=[],this.rootDoc=[],this.classes=ee(),this.documents={root:se()},this.currentDocument=this.documents.root,this.startEndCount=0,this.dividerCnt=0,this.links=new Map,this.funs=[],this.getAccTitle=G,this.setAccTitle=O,this.getAccDescription=j,this.setAccDescription=z,this.setDiagramTitle=q,this.getDiagramTitle=H,this.clear(),this.setRootDoc=this.setRootDoc.bind(this),this.getDividerId=this.getDividerId.bind(this),this.setDirection=this.setDirection.bind(this),this.trimColon=this.trimColon.bind(this),this.bindFunctions=this.bindFunctions.bind(this)}static{t(this,"StateDB")}static{this.relationType={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3}}extract(e){this.clear(!0);for(let r of Array.isArray(e)?e:e.doc)switch(r.stmt){case ot:this.addState(r.id.trim(),r.type,r.doc,r.description,r.note);break;case Mt:this.addRelation(r.state1,r.state2,r.description);break;case _e:this.addStyleClass(r.id.trim(),r.classes);break;case ve:this.handleStyleDef(r);break;case De:this.setCssClass(r.id.trim(),r.styleClass);break;case"click":this.addLink(r.id,r.url,r.tooltip);break}let s=this.getStates(),o=m();je(),dt(void 0,this.getRootDocV2(),s,this.nodes,this.edges,!0,o.look,this.classes);for(let r of this.nodes){if(!Array.isArray(r.label))continue;if(r.description=r.label.slice(1),r.isGroup&&r.description.length>0)throw Error(`Group nodes can only have label. Remove the additional description for node [${r.id}]`);r.label=r.label[0]}}handleStyleDef(e){let s=e.id.trim().split(","),o=e.styleClass.split(",");for(let r of s){let d=this.getState(r);if(!d){let u=r.trim();this.addState(u),d=this.getState(u)}if(d)d.styles=o.map((u)=>u.replace(/;/g,"")?.trim())}}setRootDoc(e){if(l.info("Setting root doc",e),this.rootDoc=e,this.version===1)this.extract(e);else this.extract(this.getRootDocV2())}docTranslator(e,s,o){if(s.stmt===Mt){this.docTranslator(e,s.state1,!0),this.docTranslator(e,s.state2,!1);return}if(s.stmt===ot)if(s.id===L.START_NODE)s.id=e.id+(o?"_start":"_end"),s.start=o;else s.id=s.id.trim();if(s.stmt!==nt&&s.stmt!==ot||!s.doc)return;let r=[],d=[];for(let u of s.doc)if(u.type===ie){let S=xt(u);S.doc=xt(d),r.push(S),d=[]}else d.push(u);if(r.length>0&&d.length>0){let u={stmt:ot,id:tA(),type:"divider",doc:xt(d)};r.push(xt(u)),s.doc=r}s.doc.forEach((u)=>this.docTranslator(s,u,!0))}getRootDocV2(){return this.docTranslator({id:nt,stmt:nt},{id:nt,stmt:nt,doc:this.rootDoc},!0),{id:nt,doc:this.rootDoc}}addState(e,s=ut,o=void 0,r=void 0,d=void 0,u=void 0,S=void 0,g=void 0){let n=e?.trim();if(!this.currentDocument.states.has(n))l.info("Adding state ",n,r),this.currentDocument.states.set(n,{stmt:ot,id:n,descriptions:[],type:s,doc:o,note:d,classes:[],styles:[],textStyles:[]});else{let T=this.currentDocument.states.get(n);if(!T)throw Error(`State not found: ${n}`);if(!T.doc)T.doc=o;if(!T.type)T.type=s}if(r)l.info("Setting state description",n,r),(Array.isArray(r)?r:[r]).forEach((E)=>this.addDescription(n,E.trim()));if(d){let T=this.currentDocument.states.get(n);if(!T)throw Error(`State not found: ${n}`);T.note=d,T.note.text=w.sanitizeText(T.note.text,m())}if(u)l.info("Setting state classes",n,u),(Array.isArray(u)?u:[u]).forEach((E)=>this.setCssClass(n,E.trim()));if(S)l.info("Setting state styles",n,S),(Array.isArray(S)?S:[S]).forEach((E)=>this.setStyle(n,E.trim()));if(g)l.info("Setting state styles",n,S),(Array.isArray(g)?g:[g]).forEach((E)=>this.setTextStyle(n,E.trim()))}clear(e){if(this.nodes=[],this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.documents={root:se()},this.currentDocument=this.documents.root,this.startEndCount=0,this.classes=ee(),!e)this.links=new Map,F()}getState(e){return this.currentDocument.states.get(e)}getStates(){return this.currentDocument.states}logDocuments(){l.info("Documents = ",this.documents)}getRelations(){return this.currentDocument.relations}addLink(e,s,o){this.links.set(e,{url:s,tooltip:o}),l.warn("Adding link",e,s,o)}getLinks(){return this.links}startIdIfNeeded(e=""){if(e===L.START_NODE)return this.startEndCount++,`${L.START_TYPE}${this.startEndCount}`;return e}startTypeIfNeeded(e="",s=ut){return e===L.START_NODE?L.START_TYPE:s}endIdIfNeeded(e=""){if(e===L.END_NODE)return this.startEndCount++,`${L.END_TYPE}${this.startEndCount}`;return e}endTypeIfNeeded(e="",s=ut){return e===L.END_NODE?L.END_TYPE:s}addRelationObjs(e,s,o=""){let r=this.startIdIfNeeded(e.id.trim()),d=this.startTypeIfNeeded(e.id.trim(),e.type),u=this.startIdIfNeeded(s.id.trim()),S=this.startTypeIfNeeded(s.id.trim(),s.type);this.addState(r,d,e.doc,e.description,e.note,e.classes,e.styles,e.textStyles),this.addState(u,S,s.doc,s.description,s.note,s.classes,s.styles,s.textStyles),this.currentDocument.relations.push({id1:r,id2:u,relationTitle:w.sanitizeText(o,m())})}addRelation(e,s,o){if(typeof e==="object"&&typeof s==="object")this.addRelationObjs(e,s,o);else if(typeof e==="string"&&typeof s==="string"){let r=this.startIdIfNeeded(e.trim()),d=this.startTypeIfNeeded(e),u=this.endIdIfNeeded(s.trim()),S=this.endTypeIfNeeded(s);this.addState(r,d),this.addState(u,S),this.currentDocument.relations.push({id1:r,id2:u,relationTitle:o?w.sanitizeText(o,m()):void 0})}}addDescription(e,s){let o=this.currentDocument.states.get(e),r=s.startsWith(":")?s.replace(":","").trim():s;o?.descriptions?.push(w.sanitizeText(r,m()))}cleanupLabel(e){return e.startsWith(":")?e.slice(2).trim():e.trim()}getDividerId(){return this.dividerCnt++,`divider-id-${this.dividerCnt}`}addStyleClass(e,s=""){if(!this.classes.has(e))this.classes.set(e,{id:e,styles:[],textStyles:[]});let o=this.classes.get(e);if(s&&o)s.split(L.STYLECLASS_SEP).forEach((r)=>{let d=r.replace(/([^;]*);/,"$1").trim();if(RegExp(L.COLOR_KEYWORD).exec(r)){let S=d.replace(L.FILL_KEYWORD,L.BG_FILL).replace(L.COLOR_KEYWORD,L.FILL_KEYWORD);o.textStyles.push(S)}o.styles.push(d)})}getClasses(){return this.classes}setupToolTips(e){let s=to();b(e).select("svg").selectAll("g.node, g.rough-node").on("mouseover",(d)=>{let u=b(d.currentTarget),S=u.attr("title");if(S===null)return;let g=d.currentTarget?.getBoundingClientRect();s.transition().duration(200).style("opacity",".9"),s.style("left",window.scrollX+g.left+(g.right-g.left)/2+"px").style("top",window.scrollY+g.bottom+"px"),s.html(Wt.sanitize(S)),u.classed("hover",!0)}).on("mouseout",(d)=>{s.transition().duration(500).style("opacity",0),b(d.currentTarget).classed("hover",!1)})}setCssClass(e,s){e.split(",").forEach((o)=>{let r=this.getState(o);if(!r){let d=o.trim();this.addState(d),r=this.getState(d)}r?.classes?.push(s)})}setStyle(e,s){this.getState(e)?.styles?.push(s)}setTextStyle(e,s){this.getState(e)?.textStyles?.push(s)}bindFunctions(e){this.funs.forEach((s)=>{s(e)})}getDirectionStatement(){return this.rootDoc.find((e)=>e.stmt===qt)}getDirection(){return this.getDirectionStatement()?.value??Ee}setDirection(e){let s=this.getDirectionStatement();if(s)s.value=e;else this.rootDoc.unshift({stmt:qt,value:e})}trimColon(e){return e.startsWith(":")?e.slice(1).trim():e.trim()}getData(){let e=m();for(let s of this.nodes)if(s.wrappingWidth??=e.state?.wrappingWidth,!s.isGroup)s.minWidth??=e.state?.minNodeWidth;return{nodes:this.nodes,edges:this.edges,other:{},config:e,direction:ge(this.getRootDocV2())}}getConfig(){return m().state}},Xe=t((e)=>{let{theme:s,bkgColorArray:o,borderColorArray:r}=e;if(!pt(s,r))return"";let d=mt(e.look),u=wt(o),S="";for(let g=0;g<aa(r);g++){let n=r[g],T=u?`fill: ${o[g%o.length]};`:"",E=`[data-look="${d}"][data-color-id="color-${g}"]`;S+=`
7
7
 
8
8
  /* The title strip: \`rect.outer\` spans the whole composite and \`rect.inner\` covers
9
9
  the body, so what stays visible of \`outer\` is the band behind the label. */
@@ -1 +1 @@
1
- import{Ze}from"./index-80kx6dm6.js";import{Ga,rp}from"./index-3m1dksmy.js";import{Et}from"./index-r8d4bk86.js";var e=Object.freeze(JSON.parse('{"displayName":"Svelte","fileTypes":["svelte"],"injections":{"L:(meta.script.svelte | meta.style.svelte) (meta.lang.js | meta.lang.javascript) - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.js","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.js"}]}]},"L:(meta.script.svelte | meta.style.svelte) (meta.lang.ts | meta.lang.typescript) - (meta source)":{"patterns":[{"begin":"(?<=>)(?=[^\\\\n]+</(s(?:cript|tyle))[>\\\\s])","contentName":"source.ts","end":"(?=</(s(?:cript|tyle))[>\\\\s])","name":"meta.embedded.block.svelte","patterns":[{"include":"source.ts"}]},{"begin":"(?<=>)(?!</)","contentName":"source.ts","name":"meta.embedded.block.svelte","patterns":[{"include":"source.ts"}],"while":"^(?!\\\\s*</(s(?:cript|tyle))[>\\\\s])"}]},"L:(meta.script.svelte | meta.style.svelte) meta.lang.coffee - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.coffee","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.coffee"}]}]},"L:(source.ts, source.js, source.coffee)":{"patterns":[{"match":"(?<![\\"$\'./_[:alnum:]])\\\\$(?=[_[:alpha:]][$_[:alnum:]]*)","name":"punctuation.definition.variable.svelte"},{"match":"(?<![\\"$\'./_[:alnum:]])(\\\\$\\\\$)(?=props|restProps|slots)","name":"punctuation.definition.variable.svelte"}]},"L:meta.script.svelte - meta.lang - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.js","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.js"}]}]},"L:meta.style.svelte - meta.lang - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.css","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.css"}]}]},"L:meta.style.svelte meta.lang.css - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.css","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.css"}]}]},"L:meta.style.svelte meta.lang.less - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.css.less","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.css.less"}]}]},"L:meta.style.svelte meta.lang.postcss - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.css.postcss","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.css.postcss"}]}]},"L:meta.style.svelte meta.lang.sass - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.sass","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.sass"}]}]},"L:meta.style.svelte meta.lang.scss - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.css.scss","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.css.scss"}]}]},"L:meta.style.svelte meta.lang.stylus - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.stylus","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.stylus"}]}]},"L:meta.template.svelte - meta.lang - (meta source)":{"patterns":[{"begin":"(?<=>)\\\\s","end":"(?=</template)","patterns":[{"include":"#scope"}]}]},"L:meta.template.svelte meta.lang.pug - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"text.pug","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"text.pug"}]}]}},"name":"svelte","patterns":[{"include":"#scope"}],"repository":{"attributes":{"patterns":[{"include":"#attributes-comments"},{"include":"#attributes-directives"},{"include":"#attributes-keyvalue"},{"include":"#attributes-attach"},{"include":"#attributes-interpolated"}]},"attributes-attach":{"begin":"(?<![:=])\\\\s*(\\\\{@attach\\\\s)","captures":{"1":{"name":"entity.other.attribute-name.svelte"}},"contentName":"meta.embedded.expression.svelte source.ts","end":"(})","patterns":[{"include":"source.ts"}]},"attributes-comments":{"patterns":[{"match":"//.*$","name":"comment.line.double-slash.svelte"},{"begin":"/\\\\*","end":"\\\\*/","name":"comment.block.svelte"}]},"attributes-directives":{"begin":"(?<!<)(on|use|bind|transition|in|out|animate|let|class|style)(:)(?:((?:--)?[$_[:alpha:]][-$_[:alnum:]]*(?=\\\\s*=))|((?:--)?[$_[:alpha:]][-$_[:alnum:]]*))((\\\\|\\\\w+)*)","beginCaptures":{"1":{"patterns":[{"include":"#attributes-directives-keywords"}]},"2":{"name":"punctuation.definition.keyword.svelte"},"3":{"patterns":[{"include":"#attributes-directives-types-assigned"}]},"4":{"patterns":[{"include":"#attributes-directives-types"}]},"5":{"patterns":[{"match":"\\\\w+","name":"support.function.svelte"},{"match":"\\\\|","name":"punctuation.separator.svelte"}]}},"end":"(?=\\\\s*+[^=\\\\s])","name":"meta.directive.$1.svelte","patterns":[{"begin":"=","beginCaptures":{"0":{"name":"punctuation.separator.key-value.svelte"}},"end":"(?<=[^=\\\\s])(?!\\\\s*=)|(?=/?>)","patterns":[{"include":"#attributes-value"}]}]},"attributes-directives-keywords":{"patterns":[{"match":"on|use|bind","name":"keyword.control.svelte"},{"match":"transition|in|out|animate","name":"keyword.other.animation.svelte"},{"match":"let","name":"storage.type.svelte"},{"match":"class|style","name":"entity.other.attribute-name.svelte"}]},"attributes-directives-types":{"patterns":[{"match":"(?<=(on):).*$","name":"entity.name.type.svelte"},{"match":"(?<=(bind):).*$","name":"variable.parameter.svelte"},{"match":"(?<=(use|transition|in|out|animate):).*$","name":"variable.function.svelte"},{"match":"(?<=(let|class|style):).*$","name":"variable.parameter.svelte"}]},"attributes-directives-types-assigned":{"patterns":[{"match":"(?<=(bind):)this$","name":"variable.language.svelte"},{"match":"(?<=(bind):).*$","name":"entity.name.type.svelte"},{"match":"(?<=(class):).*$","name":"entity.other.attribute-name.class.svelte"},{"match":"(?<=(style):).*$","name":"support.type.property-name.svelte"},{"include":"#attributes-directives-types"}]},"attributes-generics":{"begin":"(generics)(=)([\\"\'])","beginCaptures":{"1":{"name":"entity.other.attribute-name.svelte"},"2":{"name":"punctuation.separator.key-value.svelte"},"3":{"name":"punctuation.definition.string.begin.svelte"}},"contentName":"meta.embedded.expression.svelte source.ts","end":"(\\\\3)","endCaptures":{"1":{"name":"punctuation.definition.string.end.svelte"}},"patterns":[{"include":"#type-parameters"}]},"attributes-interpolated":{"begin":"(?<![:=])\\\\s*(\\\\{)","captures":{"1":{"name":"entity.other.attribute-name.svelte"}},"contentName":"meta.embedded.expression.svelte source.ts","end":"(})","patterns":[{"include":"source.ts"}]},"attributes-keyvalue":{"begin":"((?:--)?[$_[:alpha:]][-$_[:alnum:]]*)","beginCaptures":{"0":{"patterns":[{"match":"--.*","name":"support.type.property-name.svelte"},{"match":".*","name":"entity.other.attribute-name.svelte"}]}},"end":"(?=\\\\s*+[^=\\\\s])","name":"meta.attribute.$1.svelte","patterns":[{"begin":"=","beginCaptures":{"0":{"name":"punctuation.separator.key-value.svelte"}},"end":"(?<=[^=\\\\s])(?!\\\\s*=)|(?=/?>)","patterns":[{"include":"#attributes-value"}]}]},"attributes-value":{"patterns":[{"include":"#interpolation"},{"captures":{"1":{"name":"punctuation.definition.string.begin.svelte"},"2":{"name":"constant.numeric.decimal.svelte"},"3":{"name":"punctuation.definition.string.end.svelte"},"4":{"name":"constant.numeric.decimal.svelte"}},"match":"([\\"\'])([.0-9_]+[%\\\\w]{0,4})(\\\\1)|([.0-9_]+[%\\\\w]{0,4})(?=\\\\s|/?>)"},{"match":"([^\\"\'/<=>`\\\\s]|/(?!>))+","name":"string.unquoted.svelte","patterns":[{"include":"#interpolation"}]},{"begin":"([\\"\'])","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.svelte"}},"end":"\\\\1","endCaptures":{"0":{"name":"punctuation.definition.string.end.svelte"}},"name":"string.quoted.svelte","patterns":[{"include":"#interpolation"}]}]},"comments":{"begin":"<!--","captures":{"0":{"name":"punctuation.definition.comment.svelte"}},"end":"-->","name":"comment.block.svelte","patterns":[{"begin":"(@)(component)","beginCaptures":{"1":{"name":"punctuation.definition.keyword.svelte"},"2":{"name":"storage.type.class.component.svelte keyword.declaration.class.component.svelte"}},"contentName":"comment.block.documentation.svelte","end":"(?=-->)","patterns":[{"captures":{"0":{"patterns":[{"include":"text.html.markdown"}]}},"match":".*?(?=-->)"},{"include":"text.html.markdown"}]},{"match":"\\\\G-?>|<!--(?!>)|<!-(?=-->)|--!>","name":"invalid.illegal.characters-not-allowed-here.svelte"}]},"destructuring":{"patterns":[{"begin":"(?=\\\\{)","end":"(?<=})","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts#object-binding-pattern"}]},{"begin":"(?=\\\\[)","end":"(?<=])","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts#array-binding-pattern"}]}]},"destructuring-const":{"patterns":[{"begin":"(?=\\\\{)","end":"(?<=})","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts#object-binding-pattern-const"}]},{"begin":"(?=\\\\[)","end":"(?<=])","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts#array-binding-pattern-const"}]}]},"interpolation":{"patterns":[{"begin":"\\\\{","beginCaptures":{"0":{"name":"punctuation.section.embedded.begin.svelte"}},"contentName":"meta.embedded.expression.svelte source.ts","end":"}","endCaptures":{"0":{"name":"punctuation.section.embedded.end.svelte"}},"patterns":[{"begin":"\\\\G\\\\s*(?=\\\\{)","end":"(?<=})","patterns":[{"include":"source.ts#object-literal"}]},{"include":"source.ts"}]}]},"scope":{"patterns":[{"include":"#comments"},{"include":"#special-tags"},{"include":"#tags"},{"include":"#interpolation"},{"begin":"(?<=[>}])","end":"(?=[<{])","name":"text.svelte"}]},"special-tags":{"patterns":[{"include":"#special-tags-void"},{"include":"#special-tags-block-begin"},{"include":"#special-tags-block-end"}]},"special-tags-block-begin":{"begin":"(\\\\{)\\\\s*(#([a-z]*))","beginCaptures":{"1":{"name":"punctuation.definition.block.begin.svelte"},"2":{"patterns":[{"include":"#special-tags-keywords"}]}},"end":"(})","endCaptures":{"0":{"name":"punctuation.definition.block.end.svelte"}},"name":"meta.special.$3.svelte meta.special.start.svelte","patterns":[{"include":"#special-tags-modes"}]},"special-tags-block-end":{"begin":"(\\\\{)\\\\s*(/([a-z]*))","beginCaptures":{"1":{"name":"punctuation.definition.block.begin.svelte"},"2":{"patterns":[{"include":"#special-tags-keywords"}]}},"end":"(})","endCaptures":{"1":{"name":"punctuation.definition.block.end.svelte"}},"name":"meta.special.$3.svelte meta.special.end.svelte"},"special-tags-keywords":{"captures":{"1":{"name":"punctuation.definition.keyword.svelte"},"2":{"patterns":[{"match":"if|else\\\\s+if|else","name":"keyword.control.conditional.svelte"},{"match":"each|key","name":"keyword.control.svelte"},{"match":"await|then|catch","name":"keyword.control.flow.svelte"},{"match":"snippet","name":"keyword.control.svelte"},{"match":"html","name":"keyword.other.svelte"},{"match":"render","name":"keyword.other.svelte"},{"match":"debug","name":"keyword.other.debugger.svelte"},{"match":"const","name":"storage.type.svelte"}]}},"match":"([#/:@])(else\\\\s+if|[a-z]*)"},"special-tags-modes":{"patterns":[{"begin":"(?<=(if|key|then|catch|html|render).*?)\\\\G","end":"(?=})","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts"}]},{"begin":"(?<=snippet.*?)\\\\G","end":"(?=})","name":"meta.embedded.expression.svelte source.ts","patterns":[{"captures":{"1":{"name":"entity.name.function.ts"}},"match":"\\\\G\\\\s*([$_[:alpha:]][$_[:alnum:]]*)\\\\s*(?=<)"},{"begin":"(?<=<)","contentName":"meta.type.parameters.ts","end":"(?=>)","patterns":[{"include":"source.ts"}]},{"begin":"(?<=>\\\\s*\\\\()","end":"(?=})","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts"}]},{"begin":"\\\\G","end":"(?=})","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts"}]}]},{"begin":"(?<=const.*?)\\\\G","end":"(?=})","patterns":[{"include":"#destructuring-const"},{"begin":"\\\\G\\\\s*([$_[:alpha:]][$_[:alnum:]]+)\\\\s*","beginCaptures":{"1":{"name":"variable.other.constant.svelte"}},"end":"(?=[:=])"},{"begin":"(?=:)","end":"(?==)","name":"meta.type.annotation.svelte","patterns":[{"include":"source.ts"}]},{"begin":"(?==)","end":"(?=})","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts"}]}]},{"begin":"(?<=each.*?)\\\\G","end":"(?=})","patterns":[{"begin":"\\\\G\\\\s*?(?=\\\\S)","contentName":"meta.embedded.expression.svelte source.ts","end":"(?=(?:^\\\\s*|\\\\s+)(as)|\\\\s*([,}]))","patterns":[{"include":"source.ts"}]},{"begin":"(as)|(?=[,}])","beginCaptures":{"1":{"name":"keyword.control.as.svelte"}},"end":"(?=})","patterns":[{"include":"#destructuring"},{"begin":"\\\\(","captures":{"0":{"name":"meta.brace.round.svelte"}},"contentName":"meta.embedded.expression.svelte source.ts","end":"\\\\)|(?=})","patterns":[{"include":"source.ts"}]},{"captures":{"1":{"name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts"}]}},"match":"(\\\\s*([$_[:alpha:]][$_[:alnum:]]*)\\\\s*)"},{"match":",","name":"punctuation.separator.svelte"}]}]},{"begin":"(?<=await.*?)\\\\G","end":"(?=})","patterns":[{"begin":"\\\\G\\\\s*?(?=\\\\S)","contentName":"meta.embedded.expression.svelte source.ts","end":"\\\\s+(then)|(?=})","endCaptures":{"1":{"name":"keyword.control.flow.svelte"}},"patterns":[{"include":"source.ts"}]},{"begin":"(?<=then\\\\b)","contentName":"meta.embedded.expression.svelte source.ts","end":"(?=})","patterns":[{"include":"source.ts"}]}]},{"begin":"(?<=debug.*?)\\\\G","end":"(?=})","patterns":[{"captures":{"0":{"name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts"}]}},"match":"[$_[:alpha:]][$_[:alnum:]]*"},{"match":",","name":"punctuation.separator.svelte"}]}]},"special-tags-void":{"begin":"(\\\\{)\\\\s*([:@](else\\\\s+if|[a-z]*))","beginCaptures":{"1":{"name":"punctuation.definition.block.begin.svelte"},"2":{"patterns":[{"include":"#special-tags-keywords"}]}},"end":"}","endCaptures":{"0":{"name":"punctuation.definition.block.end.svelte"}},"name":"meta.special.$3.svelte","patterns":[{"include":"#special-tags-modes"}]},"tags":{"patterns":[{"include":"#tags-lang"},{"include":"#tags-void"},{"include":"#tags-general-end"},{"include":"#tags-general-start"}]},"tags-end-node":{"captures":{"1":{"name":"meta.tag.end.svelte punctuation.definition.tag.begin.svelte"},"2":{"name":"meta.tag.end.svelte","patterns":[{"include":"#tags-name"}]},"3":{"name":"meta.tag.end.svelte punctuation.definition.tag.end.svelte"},"4":{"name":"meta.tag.start.svelte punctuation.definition.tag.end.svelte"}},"match":"(</)(.*?)\\\\s*(>)|(/>)"},"tags-general-end":{"begin":"(</)([^/>\\\\s]*)","beginCaptures":{"1":{"name":"meta.tag.end.svelte punctuation.definition.tag.begin.svelte"},"2":{"name":"meta.tag.end.svelte","patterns":[{"include":"#tags-name"}]}},"end":"(>)","endCaptures":{"1":{"name":"meta.tag.end.svelte punctuation.definition.tag.end.svelte"}},"name":"meta.scope.tag.$2.svelte"},"tags-general-start":{"begin":"(<)([^/>\\\\s]*)","beginCaptures":{"0":{"patterns":[{"include":"#tags-start-node"}]}},"end":"(/?>)","endCaptures":{"1":{"name":"meta.tag.start.svelte punctuation.definition.tag.end.svelte"}},"name":"meta.scope.tag.$2.svelte","patterns":[{"include":"#tags-start-attributes"}]},"tags-lang":{"begin":"<(script|style|template)","beginCaptures":{"0":{"patterns":[{"include":"#tags-start-node"}]}},"end":"</\\\\1\\\\s*>|/>","endCaptures":{"0":{"patterns":[{"include":"#tags-end-node"}]}},"name":"meta.$1.svelte","patterns":[{"begin":"\\\\G(?=\\\\s*[^>]*?(type|lang)\\\\s*=\\\\s*([\\"\']?)(?:text/)?(\\\\w+)\\\\2)","end":"(?=</|/>)","name":"meta.lang.$3.svelte","patterns":[{"include":"#tags-lang-start-attributes"}]},{"include":"#tags-lang-start-attributes"}]},"tags-lang-start-attributes":{"begin":"\\\\G","end":"(?=/>)|>","endCaptures":{"0":{"name":"punctuation.definition.tag.end.svelte"}},"name":"meta.tag.start.svelte","patterns":[{"include":"#attributes-generics"},{"include":"#attributes"}]},"tags-name":{"patterns":[{"captures":{"1":{"name":"keyword.control.svelte"},"2":{"name":"punctuation.definition.keyword.svelte"},"3":{"name":"entity.name.tag.svelte"}},"match":"(svelte)(:)([a-z][-:\\\\w]*)"},{"match":"slot","name":"keyword.control.svelte"},{"captures":{"1":{"patterns":[{"match":"\\\\w+","name":"support.class.component.svelte"},{"match":"\\\\.","name":"punctuation.definition.keyword.svelte"}]},"2":{"name":"support.class.component.svelte"}},"match":"(\\\\w+(?:\\\\.\\\\w+)+)|([A-Z]\\\\w*)"},{"match":"[a-z][0-:\\\\w]*-[-0-:\\\\w]*","name":"meta.tag.custom.svelte entity.name.tag.svelte"},{"match":"[a-z][-0-:\\\\w]*","name":"entity.name.tag.svelte"}]},"tags-start-attributes":{"begin":"\\\\G","end":"(?=/?>)","name":"meta.tag.start.svelte","patterns":[{"include":"#attributes"}]},"tags-start-node":{"captures":{"1":{"name":"punctuation.definition.tag.begin.svelte"},"2":{"patterns":[{"include":"#tags-name"}]}},"match":"(<)([^/>\\\\s]*)","name":"meta.tag.start.svelte"},"tags-void":{"begin":"(<)(area|base|br|col|embed|hr|img|input|link|meta|param|source|track|wbr)(?=\\\\s|/?>)","beginCaptures":{"1":{"name":"punctuation.definition.tag.begin.svelte"},"2":{"name":"entity.name.tag.svelte"}},"end":"/?>","endCaptures":{"0":{"name":"punctuation.definition.tag.begin.svelte"}},"name":"meta.tag.void.svelte","patterns":[{"include":"#attributes"}]},"type-parameters":{"name":"meta.type.parameters.ts","patterns":[{"include":"source.ts#comment"},{"match":"(?<![$_[:alnum:]])(?:(?<=\\\\.\\\\.\\\\.)|(?<!\\\\.))(extends|in|out|const)(?![$_[:alnum:]])(?:(?=\\\\.\\\\.\\\\.)|(?!\\\\.))","name":"storage.modifier.ts"},{"include":"source.ts#type"},{"include":"source.ts#punctuation-comma"},{"match":"(=)(?!>)","name":"keyword.operator.assignment.ts"}]}},"scopeName":"source.svelte","embeddedLangs":["javascript","typescript","css","postcss"],"embeddedLangsLazy":["coffee","stylus","sass","scss","less","pug","markdown"]}')),i=[...Ze,...Ga,...Et,...rp,e];export{i as default};
1
+ import{Xe}from"./index-a3bpmw2r.js";import{qa,up}from"./index-yrwm437g.js";import{It}from"./index-10vzyga1.js";var e=Object.freeze(JSON.parse('{"displayName":"Svelte","fileTypes":["svelte"],"injections":{"L:(meta.script.svelte | meta.style.svelte) (meta.lang.js | meta.lang.javascript) - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.js","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.js"}]}]},"L:(meta.script.svelte | meta.style.svelte) (meta.lang.ts | meta.lang.typescript) - (meta source)":{"patterns":[{"begin":"(?<=>)(?=[^\\\\n]+</(s(?:cript|tyle))[>\\\\s])","contentName":"source.ts","end":"(?=</(s(?:cript|tyle))[>\\\\s])","name":"meta.embedded.block.svelte","patterns":[{"include":"source.ts"}]},{"begin":"(?<=>)(?!</)","contentName":"source.ts","name":"meta.embedded.block.svelte","patterns":[{"include":"source.ts"}],"while":"^(?!\\\\s*</(s(?:cript|tyle))[>\\\\s])"}]},"L:(meta.script.svelte | meta.style.svelte) meta.lang.coffee - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.coffee","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.coffee"}]}]},"L:(source.ts, source.js, source.coffee)":{"patterns":[{"match":"(?<![\\"$\'./_[:alnum:]])\\\\$(?=[_[:alpha:]][$_[:alnum:]]*)","name":"punctuation.definition.variable.svelte"},{"match":"(?<![\\"$\'./_[:alnum:]])(\\\\$\\\\$)(?=props|restProps|slots)","name":"punctuation.definition.variable.svelte"}]},"L:meta.script.svelte - meta.lang - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.js","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.js"}]}]},"L:meta.style.svelte - meta.lang - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.css","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.css"}]}]},"L:meta.style.svelte meta.lang.css - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.css","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.css"}]}]},"L:meta.style.svelte meta.lang.less - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.css.less","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.css.less"}]}]},"L:meta.style.svelte meta.lang.postcss - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.css.postcss","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.css.postcss"}]}]},"L:meta.style.svelte meta.lang.sass - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.sass","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.sass"}]}]},"L:meta.style.svelte meta.lang.scss - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.css.scss","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.css.scss"}]}]},"L:meta.style.svelte meta.lang.stylus - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"source.stylus","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"source.stylus"}]}]},"L:meta.template.svelte - meta.lang - (meta source)":{"patterns":[{"begin":"(?<=>)\\\\s","end":"(?=</template)","patterns":[{"include":"#scope"}]}]},"L:meta.template.svelte meta.lang.pug - (meta source)":{"patterns":[{"begin":"(?<=>)(?!</)","contentName":"text.pug","end":"(?=</)","name":"meta.embedded.block.svelte","patterns":[{"include":"text.pug"}]}]}},"name":"svelte","patterns":[{"include":"#scope"}],"repository":{"attributes":{"patterns":[{"include":"#attributes-comments"},{"include":"#attributes-directives"},{"include":"#attributes-keyvalue"},{"include":"#attributes-attach"},{"include":"#attributes-interpolated"}]},"attributes-attach":{"begin":"(?<![:=])\\\\s*(\\\\{@attach\\\\s)","captures":{"1":{"name":"entity.other.attribute-name.svelte"}},"contentName":"meta.embedded.expression.svelte source.ts","end":"(})","patterns":[{"include":"source.ts"}]},"attributes-comments":{"patterns":[{"match":"//.*$","name":"comment.line.double-slash.svelte"},{"begin":"/\\\\*","end":"\\\\*/","name":"comment.block.svelte"}]},"attributes-directives":{"begin":"(?<!<)(on|use|bind|transition|in|out|animate|let|class|style)(:)(?:((?:--)?[$_[:alpha:]][-$_[:alnum:]]*(?=\\\\s*=))|((?:--)?[$_[:alpha:]][-$_[:alnum:]]*))((\\\\|\\\\w+)*)","beginCaptures":{"1":{"patterns":[{"include":"#attributes-directives-keywords"}]},"2":{"name":"punctuation.definition.keyword.svelte"},"3":{"patterns":[{"include":"#attributes-directives-types-assigned"}]},"4":{"patterns":[{"include":"#attributes-directives-types"}]},"5":{"patterns":[{"match":"\\\\w+","name":"support.function.svelte"},{"match":"\\\\|","name":"punctuation.separator.svelte"}]}},"end":"(?=\\\\s*+[^=\\\\s])","name":"meta.directive.$1.svelte","patterns":[{"begin":"=","beginCaptures":{"0":{"name":"punctuation.separator.key-value.svelte"}},"end":"(?<=[^=\\\\s])(?!\\\\s*=)|(?=/?>)","patterns":[{"include":"#attributes-value"}]}]},"attributes-directives-keywords":{"patterns":[{"match":"on|use|bind","name":"keyword.control.svelte"},{"match":"transition|in|out|animate","name":"keyword.other.animation.svelte"},{"match":"let","name":"storage.type.svelte"},{"match":"class|style","name":"entity.other.attribute-name.svelte"}]},"attributes-directives-types":{"patterns":[{"match":"(?<=(on):).*$","name":"entity.name.type.svelte"},{"match":"(?<=(bind):).*$","name":"variable.parameter.svelte"},{"match":"(?<=(use|transition|in|out|animate):).*$","name":"variable.function.svelte"},{"match":"(?<=(let|class|style):).*$","name":"variable.parameter.svelte"}]},"attributes-directives-types-assigned":{"patterns":[{"match":"(?<=(bind):)this$","name":"variable.language.svelte"},{"match":"(?<=(bind):).*$","name":"entity.name.type.svelte"},{"match":"(?<=(class):).*$","name":"entity.other.attribute-name.class.svelte"},{"match":"(?<=(style):).*$","name":"support.type.property-name.svelte"},{"include":"#attributes-directives-types"}]},"attributes-generics":{"begin":"(generics)(=)([\\"\'])","beginCaptures":{"1":{"name":"entity.other.attribute-name.svelte"},"2":{"name":"punctuation.separator.key-value.svelte"},"3":{"name":"punctuation.definition.string.begin.svelte"}},"contentName":"meta.embedded.expression.svelte source.ts","end":"(\\\\3)","endCaptures":{"1":{"name":"punctuation.definition.string.end.svelte"}},"patterns":[{"include":"#type-parameters"}]},"attributes-interpolated":{"begin":"(?<![:=])\\\\s*(\\\\{)","captures":{"1":{"name":"entity.other.attribute-name.svelte"}},"contentName":"meta.embedded.expression.svelte source.ts","end":"(})","patterns":[{"include":"source.ts"}]},"attributes-keyvalue":{"begin":"((?:--)?[$_[:alpha:]][-$_[:alnum:]]*)","beginCaptures":{"0":{"patterns":[{"match":"--.*","name":"support.type.property-name.svelte"},{"match":".*","name":"entity.other.attribute-name.svelte"}]}},"end":"(?=\\\\s*+[^=\\\\s])","name":"meta.attribute.$1.svelte","patterns":[{"begin":"=","beginCaptures":{"0":{"name":"punctuation.separator.key-value.svelte"}},"end":"(?<=[^=\\\\s])(?!\\\\s*=)|(?=/?>)","patterns":[{"include":"#attributes-value"}]}]},"attributes-value":{"patterns":[{"include":"#interpolation"},{"captures":{"1":{"name":"punctuation.definition.string.begin.svelte"},"2":{"name":"constant.numeric.decimal.svelte"},"3":{"name":"punctuation.definition.string.end.svelte"},"4":{"name":"constant.numeric.decimal.svelte"}},"match":"([\\"\'])([.0-9_]+[%\\\\w]{0,4})(\\\\1)|([.0-9_]+[%\\\\w]{0,4})(?=\\\\s|/?>)"},{"match":"([^\\"\'/<=>`\\\\s]|/(?!>))+","name":"string.unquoted.svelte","patterns":[{"include":"#interpolation"}]},{"begin":"([\\"\'])","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.svelte"}},"end":"\\\\1","endCaptures":{"0":{"name":"punctuation.definition.string.end.svelte"}},"name":"string.quoted.svelte","patterns":[{"include":"#interpolation"}]}]},"comments":{"begin":"<!--","captures":{"0":{"name":"punctuation.definition.comment.svelte"}},"end":"-->","name":"comment.block.svelte","patterns":[{"begin":"(@)(component)","beginCaptures":{"1":{"name":"punctuation.definition.keyword.svelte"},"2":{"name":"storage.type.class.component.svelte keyword.declaration.class.component.svelte"}},"contentName":"comment.block.documentation.svelte","end":"(?=-->)","patterns":[{"captures":{"0":{"patterns":[{"include":"text.html.markdown"}]}},"match":".*?(?=-->)"},{"include":"text.html.markdown"}]},{"match":"\\\\G-?>|<!--(?!>)|<!-(?=-->)|--!>","name":"invalid.illegal.characters-not-allowed-here.svelte"}]},"destructuring":{"patterns":[{"begin":"(?=\\\\{)","end":"(?<=})","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts#object-binding-pattern"}]},{"begin":"(?=\\\\[)","end":"(?<=])","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts#array-binding-pattern"}]}]},"destructuring-const":{"patterns":[{"begin":"(?=\\\\{)","end":"(?<=})","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts#object-binding-pattern-const"}]},{"begin":"(?=\\\\[)","end":"(?<=])","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts#array-binding-pattern-const"}]}]},"interpolation":{"patterns":[{"begin":"\\\\{","beginCaptures":{"0":{"name":"punctuation.section.embedded.begin.svelte"}},"contentName":"meta.embedded.expression.svelte source.ts","end":"}","endCaptures":{"0":{"name":"punctuation.section.embedded.end.svelte"}},"patterns":[{"begin":"\\\\G\\\\s*(?=\\\\{)","end":"(?<=})","patterns":[{"include":"source.ts#object-literal"}]},{"include":"source.ts"}]}]},"scope":{"patterns":[{"include":"#comments"},{"include":"#special-tags"},{"include":"#tags"},{"include":"#interpolation"},{"begin":"(?<=[>}])","end":"(?=[<{])","name":"text.svelte"}]},"special-tags":{"patterns":[{"include":"#special-tags-void"},{"include":"#special-tags-block-begin"},{"include":"#special-tags-block-end"}]},"special-tags-block-begin":{"begin":"(\\\\{)\\\\s*(#([a-z]*))","beginCaptures":{"1":{"name":"punctuation.definition.block.begin.svelte"},"2":{"patterns":[{"include":"#special-tags-keywords"}]}},"end":"(})","endCaptures":{"0":{"name":"punctuation.definition.block.end.svelte"}},"name":"meta.special.$3.svelte meta.special.start.svelte","patterns":[{"include":"#special-tags-modes"}]},"special-tags-block-end":{"begin":"(\\\\{)\\\\s*(/([a-z]*))","beginCaptures":{"1":{"name":"punctuation.definition.block.begin.svelte"},"2":{"patterns":[{"include":"#special-tags-keywords"}]}},"end":"(})","endCaptures":{"1":{"name":"punctuation.definition.block.end.svelte"}},"name":"meta.special.$3.svelte meta.special.end.svelte"},"special-tags-keywords":{"captures":{"1":{"name":"punctuation.definition.keyword.svelte"},"2":{"patterns":[{"match":"if|else\\\\s+if|else","name":"keyword.control.conditional.svelte"},{"match":"each|key","name":"keyword.control.svelte"},{"match":"await|then|catch","name":"keyword.control.flow.svelte"},{"match":"snippet","name":"keyword.control.svelte"},{"match":"html","name":"keyword.other.svelte"},{"match":"render","name":"keyword.other.svelte"},{"match":"debug","name":"keyword.other.debugger.svelte"},{"match":"const","name":"storage.type.svelte"}]}},"match":"([#/:@])(else\\\\s+if|[a-z]*)"},"special-tags-modes":{"patterns":[{"begin":"(?<=(if|key|then|catch|html|render).*?)\\\\G","end":"(?=})","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts"}]},{"begin":"(?<=snippet.*?)\\\\G","end":"(?=})","name":"meta.embedded.expression.svelte source.ts","patterns":[{"captures":{"1":{"name":"entity.name.function.ts"}},"match":"\\\\G\\\\s*([$_[:alpha:]][$_[:alnum:]]*)\\\\s*(?=<)"},{"begin":"(?<=<)","contentName":"meta.type.parameters.ts","end":"(?=>)","patterns":[{"include":"source.ts"}]},{"begin":"(?<=>\\\\s*\\\\()","end":"(?=})","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts"}]},{"begin":"\\\\G","end":"(?=})","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts"}]}]},{"begin":"(?<=const.*?)\\\\G","end":"(?=})","patterns":[{"include":"#destructuring-const"},{"begin":"\\\\G\\\\s*([$_[:alpha:]][$_[:alnum:]]+)\\\\s*","beginCaptures":{"1":{"name":"variable.other.constant.svelte"}},"end":"(?=[:=])"},{"begin":"(?=:)","end":"(?==)","name":"meta.type.annotation.svelte","patterns":[{"include":"source.ts"}]},{"begin":"(?==)","end":"(?=})","name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts"}]}]},{"begin":"(?<=each.*?)\\\\G","end":"(?=})","patterns":[{"begin":"\\\\G\\\\s*?(?=\\\\S)","contentName":"meta.embedded.expression.svelte source.ts","end":"(?=(?:^\\\\s*|\\\\s+)(as)|\\\\s*([,}]))","patterns":[{"include":"source.ts"}]},{"begin":"(as)|(?=[,}])","beginCaptures":{"1":{"name":"keyword.control.as.svelte"}},"end":"(?=})","patterns":[{"include":"#destructuring"},{"begin":"\\\\(","captures":{"0":{"name":"meta.brace.round.svelte"}},"contentName":"meta.embedded.expression.svelte source.ts","end":"\\\\)|(?=})","patterns":[{"include":"source.ts"}]},{"captures":{"1":{"name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts"}]}},"match":"(\\\\s*([$_[:alpha:]][$_[:alnum:]]*)\\\\s*)"},{"match":",","name":"punctuation.separator.svelte"}]}]},{"begin":"(?<=await.*?)\\\\G","end":"(?=})","patterns":[{"begin":"\\\\G\\\\s*?(?=\\\\S)","contentName":"meta.embedded.expression.svelte source.ts","end":"\\\\s+(then)|(?=})","endCaptures":{"1":{"name":"keyword.control.flow.svelte"}},"patterns":[{"include":"source.ts"}]},{"begin":"(?<=then\\\\b)","contentName":"meta.embedded.expression.svelte source.ts","end":"(?=})","patterns":[{"include":"source.ts"}]}]},{"begin":"(?<=debug.*?)\\\\G","end":"(?=})","patterns":[{"captures":{"0":{"name":"meta.embedded.expression.svelte source.ts","patterns":[{"include":"source.ts"}]}},"match":"[$_[:alpha:]][$_[:alnum:]]*"},{"match":",","name":"punctuation.separator.svelte"}]}]},"special-tags-void":{"begin":"(\\\\{)\\\\s*([:@](else\\\\s+if|[a-z]*))","beginCaptures":{"1":{"name":"punctuation.definition.block.begin.svelte"},"2":{"patterns":[{"include":"#special-tags-keywords"}]}},"end":"}","endCaptures":{"0":{"name":"punctuation.definition.block.end.svelte"}},"name":"meta.special.$3.svelte","patterns":[{"include":"#special-tags-modes"}]},"tags":{"patterns":[{"include":"#tags-lang"},{"include":"#tags-void"},{"include":"#tags-general-end"},{"include":"#tags-general-start"}]},"tags-end-node":{"captures":{"1":{"name":"meta.tag.end.svelte punctuation.definition.tag.begin.svelte"},"2":{"name":"meta.tag.end.svelte","patterns":[{"include":"#tags-name"}]},"3":{"name":"meta.tag.end.svelte punctuation.definition.tag.end.svelte"},"4":{"name":"meta.tag.start.svelte punctuation.definition.tag.end.svelte"}},"match":"(</)(.*?)\\\\s*(>)|(/>)"},"tags-general-end":{"begin":"(</)([^/>\\\\s]*)","beginCaptures":{"1":{"name":"meta.tag.end.svelte punctuation.definition.tag.begin.svelte"},"2":{"name":"meta.tag.end.svelte","patterns":[{"include":"#tags-name"}]}},"end":"(>)","endCaptures":{"1":{"name":"meta.tag.end.svelte punctuation.definition.tag.end.svelte"}},"name":"meta.scope.tag.$2.svelte"},"tags-general-start":{"begin":"(<)([^/>\\\\s]*)","beginCaptures":{"0":{"patterns":[{"include":"#tags-start-node"}]}},"end":"(/?>)","endCaptures":{"1":{"name":"meta.tag.start.svelte punctuation.definition.tag.end.svelte"}},"name":"meta.scope.tag.$2.svelte","patterns":[{"include":"#tags-start-attributes"}]},"tags-lang":{"begin":"<(script|style|template)","beginCaptures":{"0":{"patterns":[{"include":"#tags-start-node"}]}},"end":"</\\\\1\\\\s*>|/>","endCaptures":{"0":{"patterns":[{"include":"#tags-end-node"}]}},"name":"meta.$1.svelte","patterns":[{"begin":"\\\\G(?=\\\\s*[^>]*?(type|lang)\\\\s*=\\\\s*([\\"\']?)(?:text/)?(\\\\w+)\\\\2)","end":"(?=</|/>)","name":"meta.lang.$3.svelte","patterns":[{"include":"#tags-lang-start-attributes"}]},{"include":"#tags-lang-start-attributes"}]},"tags-lang-start-attributes":{"begin":"\\\\G","end":"(?=/>)|>","endCaptures":{"0":{"name":"punctuation.definition.tag.end.svelte"}},"name":"meta.tag.start.svelte","patterns":[{"include":"#attributes-generics"},{"include":"#attributes"}]},"tags-name":{"patterns":[{"captures":{"1":{"name":"keyword.control.svelte"},"2":{"name":"punctuation.definition.keyword.svelte"},"3":{"name":"entity.name.tag.svelte"}},"match":"(svelte)(:)([a-z][-:\\\\w]*)"},{"match":"slot","name":"keyword.control.svelte"},{"captures":{"1":{"patterns":[{"match":"\\\\w+","name":"support.class.component.svelte"},{"match":"\\\\.","name":"punctuation.definition.keyword.svelte"}]},"2":{"name":"support.class.component.svelte"}},"match":"(\\\\w+(?:\\\\.\\\\w+)+)|([A-Z]\\\\w*)"},{"match":"[a-z][0-:\\\\w]*-[-0-:\\\\w]*","name":"meta.tag.custom.svelte entity.name.tag.svelte"},{"match":"[a-z][-0-:\\\\w]*","name":"entity.name.tag.svelte"}]},"tags-start-attributes":{"begin":"\\\\G","end":"(?=/?>)","name":"meta.tag.start.svelte","patterns":[{"include":"#attributes"}]},"tags-start-node":{"captures":{"1":{"name":"punctuation.definition.tag.begin.svelte"},"2":{"patterns":[{"include":"#tags-name"}]}},"match":"(<)([^/>\\\\s]*)","name":"meta.tag.start.svelte"},"tags-void":{"begin":"(<)(area|base|br|col|embed|hr|img|input|link|meta|param|source|track|wbr)(?=\\\\s|/?>)","beginCaptures":{"1":{"name":"punctuation.definition.tag.begin.svelte"},"2":{"name":"entity.name.tag.svelte"}},"end":"/?>","endCaptures":{"0":{"name":"punctuation.definition.tag.begin.svelte"}},"name":"meta.tag.void.svelte","patterns":[{"include":"#attributes"}]},"type-parameters":{"name":"meta.type.parameters.ts","patterns":[{"include":"source.ts#comment"},{"match":"(?<![$_[:alnum:]])(?:(?<=\\\\.\\\\.\\\\.)|(?<!\\\\.))(extends|in|out|const)(?![$_[:alnum:]])(?:(?=\\\\.\\\\.\\\\.)|(?!\\\\.))","name":"storage.modifier.ts"},{"include":"source.ts#type"},{"include":"source.ts#punctuation-comma"},{"match":"(=)(?!>)","name":"keyword.operator.assignment.ts"}]}},"scopeName":"source.svelte","embeddedLangs":["javascript","typescript","css","postcss"],"embeddedLangsLazy":["coffee","stylus","sass","scss","less","pug","markdown"]}')),i=[...Xe,...qa,...It,...up,e];export{i as default};