@diagrammo/dgmo 0.50.2 → 0.51.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 (233) hide show
  1. package/dist/advanced.d.ts +85 -23
  2. package/dist/advanced.js +207 -161
  3. package/dist/{analyzer-UYKBXAKR.js → analyzer-BJ54GIFB.js} +3 -3
  4. package/dist/auto.css +31 -8
  5. package/dist/auto.d.ts +6 -0
  6. package/dist/auto.js +169 -133
  7. package/dist/auto.mjs +2148 -1024
  8. package/dist/block.css +28 -8
  9. package/dist/block.js +97 -68
  10. package/dist/{charts-d3-MUW3LTML.js → charts-d3-7E4B4IMW.js} +9 -9
  11. package/dist/{chunk-6IAA2QQ2.js → chunk-2EQMXBBQ.js} +2 -2
  12. package/dist/{chunk-XJLKLU4D.js → chunk-2ILHQOL3.js} +3 -3
  13. package/dist/{chunk-SXRTRMEE.js → chunk-2UJSV2VT.js} +3 -3
  14. package/dist/{chunk-LE4MYMLI.js → chunk-32XPAAET.js} +5 -5
  15. package/dist/{chunk-NU3XLTGP.js → chunk-332ZR4QU.js} +4 -4
  16. package/dist/{chunk-F7BFXWNQ.js → chunk-3JLKYGBQ.js} +2 -2
  17. package/dist/{chunk-QROYX7TT.js → chunk-3LV2NCB6.js} +3 -3
  18. package/dist/{chunk-SVTI362O.js → chunk-3ODS2VGL.js} +97 -97
  19. package/dist/{chunk-3XGZF2QJ.js → chunk-3YSQZ75W.js} +6 -6
  20. package/dist/{chunk-FJUNPCYI.js → chunk-467TVMQL.js} +2 -2
  21. package/dist/{chunk-HHXOONLX.js → chunk-4B5YISOR.js} +38 -1
  22. package/dist/{chunk-6HJBFVLO.js → chunk-4QZ43D7I.js} +3 -3
  23. package/dist/{chunk-QJJZSROI.js → chunk-4VWJ4LW2.js} +7 -7
  24. package/dist/chunk-4XFBQT5O.js +35 -0
  25. package/dist/{chunk-2C56LEML.js → chunk-5F5ELR3V.js} +3 -3
  26. package/dist/{chunk-EAMEADTV.js → chunk-5PDTIBLV.js} +83 -21
  27. package/dist/{chunk-C2CVAM3U.js → chunk-5PZT4DQG.js} +160 -87
  28. package/dist/{chunk-IAEC4KLA.js → chunk-5QKQSSPO.js} +2 -2
  29. package/dist/{chunk-5OWVC2A6.js → chunk-5SVOCD5W.js} +6 -6
  30. package/dist/{chunk-VBYSIOOY.js → chunk-5WPNFSXP.js} +3 -3
  31. package/dist/{chunk-4MJ7M6YL.js → chunk-5X6YQA2J.js} +7 -7
  32. package/dist/{chunk-JJUOHGX2.js → chunk-65WJYYKJ.js} +4 -4
  33. package/dist/{chunk-3UIKSPFB.js → chunk-6BQFET7X.js} +3 -3
  34. package/dist/{chunk-U2HGPLZS.js → chunk-6H7O2OPM.js} +14 -1
  35. package/dist/{chunk-DZXYF2F5.js → chunk-6K2M4VSR.js} +3 -3
  36. package/dist/{chunk-PGEGPSCZ.js → chunk-6MNGECP2.js} +2 -2
  37. package/dist/{chunk-3XPUDB7B.js → chunk-6NFYEQDX.js} +266 -38
  38. package/dist/{chunk-4XK3FLFB.js → chunk-6NYWYNBI.js} +3 -3
  39. package/dist/{chunk-TWQUYVP3.js → chunk-7DF4J4RL.js} +4 -4
  40. package/dist/{chunk-H73FP42Q.js → chunk-7DYOELRK.js} +3 -3
  41. package/dist/{chunk-L3UHP6TD.js → chunk-7L4UJOY6.js} +1 -2
  42. package/dist/{chunk-QJP6PG7F.js → chunk-AB7INMR5.js} +9 -9
  43. package/dist/{chunk-3LKM6FMW.js → chunk-AE7II3E3.js} +2 -2
  44. package/dist/{chunk-BTUTZMPT.js → chunk-AFIEPDLX.js} +97 -42
  45. package/dist/chunk-APKUAJ2L.js +220 -0
  46. package/dist/{chunk-X6EZPSW6.js → chunk-AXW3M6OQ.js} +7 -7
  47. package/dist/{chunk-66RUL3XF.js → chunk-B63YB7X3.js} +5 -5
  48. package/dist/{chunk-DSWVNQVS.js → chunk-BGP54HVR.js} +4 -59
  49. package/dist/{chunk-3NODSS6A.js → chunk-BYJBIALT.js} +7 -7
  50. package/dist/{chunk-3YPY3OXD.js → chunk-CC4YRBWV.js} +2 -2
  51. package/dist/{chunk-HLJVEAOF.js → chunk-DY7XLRHK.js} +8 -33
  52. package/dist/{chunk-OMNGQPEZ.js → chunk-E7Y3SYKW.js} +3 -3
  53. package/dist/{chunk-HTMN2Z6U.js → chunk-EDA6C7MV.js} +50 -7
  54. package/dist/{chunk-7L3R6I3U.js → chunk-ENRS56GC.js} +3 -3
  55. package/dist/{chunk-2KGXHFYK.js → chunk-EXOQP75F.js} +7 -7
  56. package/dist/{chunk-BBGDM4NQ.js → chunk-F3FYUFUH.js} +26 -8
  57. package/dist/{chunk-GL5UZ6NY.js → chunk-FC5I2KXV.js} +3 -3
  58. package/dist/{chunk-VVW3F3MD.js → chunk-FTBZV6NE.js} +9 -9
  59. package/dist/{chunk-7QKLIMRZ.js → chunk-G3PF3S7P.js} +41 -46
  60. package/dist/{chunk-J6K7RP6P.js → chunk-GD6L76WD.js} +3 -3
  61. package/dist/{chunk-I2WKW7C7.js → chunk-GGHRAITI.js} +3 -3
  62. package/dist/{chunk-DN66GPY5.js → chunk-GNSFLJAA.js} +24 -3
  63. package/dist/{chunk-IUMPEA64.js → chunk-GROLTAWZ.js} +4 -4
  64. package/dist/{chunk-Q4V4XQWV.js → chunk-GTWKD3QT.js} +2 -2
  65. package/dist/{chunk-F2L5GCQ4.js → chunk-GU46PPT3.js} +3 -3
  66. package/dist/{chunk-6IUAK7RZ.js → chunk-H6PI3KJT.js} +2 -2
  67. package/dist/{chunk-SCQ5VPUF.js → chunk-HFMYN6N2.js} +2 -2
  68. package/dist/{chunk-GKC3HILQ.js → chunk-I2QZFCS2.js} +27 -4
  69. package/dist/{chunk-MCZ5LBZD.js → chunk-IE477RQZ.js} +7 -7
  70. package/dist/{chunk-3Y2DRD7S.js → chunk-IEDMFNU7.js} +3 -3
  71. package/dist/{chunk-M5RXSRO2.js → chunk-IEWG6J7C.js} +4 -4
  72. package/dist/{chunk-P7CE7LXL.js → chunk-IUJODQKX.js} +6 -6
  73. package/dist/{chunk-NWED7CYO.js → chunk-IUO34HKW.js} +6 -6
  74. package/dist/{chunk-NX4EQS3U.js → chunk-J76PIKAT.js} +2 -2
  75. package/dist/{chunk-O7WP4ZD4.js → chunk-JED6ZDEE.js} +2 -2
  76. package/dist/{chunk-6BFZKBGD.js → chunk-JJXGQIRV.js} +2 -2
  77. package/dist/{chunk-O7NUCTFU.js → chunk-JM4LEPY3.js} +2 -2
  78. package/dist/{chunk-VDOOQZUD.js → chunk-JSSX2SX4.js} +4 -4
  79. package/dist/{chunk-SQLNBA64.js → chunk-KFNWFNAA.js} +3 -3
  80. package/dist/{chunk-KQ57MHRO.js → chunk-KJGG2JKQ.js} +143 -82
  81. package/dist/{chunk-OTAL43EH.js → chunk-LV4BETUU.js} +8 -2
  82. package/dist/{chunk-VUJGMJE6.js → chunk-MVN25IF6.js} +4 -4
  83. package/dist/{chunk-CLD2OKV7.js → chunk-MX2EY5Y7.js} +2 -2
  84. package/dist/{chunk-T5SHNNGP.js → chunk-ND76YJCN.js} +59 -25
  85. package/dist/{chunk-KFZYNWWO.js → chunk-NEQ6GJXB.js} +4 -4
  86. package/dist/{chunk-PFHVU7UA.js → chunk-NI3XQBPB.js} +2 -2
  87. package/dist/{chunk-WW32K72E.js → chunk-OJTXTQA2.js} +9 -9
  88. package/dist/{chunk-YNRDWYZP.js → chunk-OQKP2X3D.js} +170 -51
  89. package/dist/{chunk-AHGF2YYA.js → chunk-OTOHI4JO.js} +2 -2
  90. package/dist/{chunk-HEVYAHLW.js → chunk-OU7HLO7I.js} +4 -4
  91. package/dist/{chunk-GBE54KY6.js → chunk-OZPBJM5Q.js} +3 -3
  92. package/dist/{chunk-EOFPYPAU.js → chunk-P3NRSSUU.js} +51 -11
  93. package/dist/{chunk-TSA237IM.js → chunk-PZDBOK2Q.js} +2 -2
  94. package/dist/{chunk-3P2DKJCG.js → chunk-Q62FEYK3.js} +2 -2
  95. package/dist/{chunk-DFTFPYUD.js → chunk-QHI5XVUJ.js} +7 -7
  96. package/dist/{chunk-HQCHYB5F.js → chunk-QOOUC2J5.js} +2 -2
  97. package/dist/{chunk-XEGTMVYY.js → chunk-QZPEGJOM.js} +2 -2
  98. package/dist/{chunk-TN35C5KM.js → chunk-RAHVMKBG.js} +2 -2
  99. package/dist/chunk-RBDIYLA5.js +267 -0
  100. package/dist/{chunk-OTQKUHRS.js → chunk-RBHWPDBB.js} +3 -3
  101. package/dist/{chunk-BH3UYK36.js → chunk-RLFVAKEO.js} +3 -3
  102. package/dist/{chunk-3LH5CLP4.js → chunk-RXKTSFDL.js} +150 -5
  103. package/dist/{chunk-RZ6YKEUJ.js → chunk-TK2VQQX2.js} +6 -6
  104. package/dist/{chunk-I7F2A35O.js → chunk-TMACGPW5.js} +25 -47
  105. package/dist/{chunk-5GJYGP5Z.js → chunk-TRM2J7ZN.js} +8 -8
  106. package/dist/{chunk-BCYVE3N5.js → chunk-TYS6CSS5.js} +2 -2
  107. package/dist/{chunk-5WFIYXQ6.js → chunk-U5SI5NIM.js} +91 -228
  108. package/dist/{chunk-KHEYDLMT.js → chunk-VB4UJ3H2.js} +2 -2
  109. package/dist/{chunk-HGN652MU.js → chunk-VL2O2F3W.js} +2 -2
  110. package/dist/{chunk-ONA5KPV3.js → chunk-VNSXLA6G.js} +4 -4
  111. package/dist/{chunk-CMCR5WBW.js → chunk-WBRZJOEC.js} +3 -3
  112. package/dist/{chunk-5LWQH6QV.js → chunk-WCT3NYCV.js} +1 -1
  113. package/dist/{chunk-T4VOVZT5.js → chunk-WJ7RW65H.js} +4 -4
  114. package/dist/{chunk-SCHXJTZL.js → chunk-WQLMU7VG.js} +2 -2
  115. package/dist/{chunk-C4GQDB5L.js → chunk-WRNFDFPU.js} +2 -2
  116. package/dist/{chunk-66NVRO4K.js → chunk-X7EC3L2H.js} +7 -7
  117. package/dist/{chunk-QXKWYZNR.js → chunk-XEQXCIBC.js} +3 -3
  118. package/dist/{chunk-C63UWAKM.js → chunk-Y2ZE3MSG.js} +2 -2
  119. package/dist/{chunk-FA6K3FWM.js → chunk-Y6GBQTBK.js} +6 -6
  120. package/dist/{chunk-7UEMZREK.js → chunk-YAA6IID3.js} +2 -2
  121. package/dist/{chunk-PZFVK3IH.js → chunk-YGJZWZTY.js} +2 -2
  122. package/dist/{chunk-7TV5Y53Y.js → chunk-ZJ3LS7DW.js} +3 -3
  123. package/dist/{chunk-PH5X4GIP.js → chunk-ZO27FGJS.js} +2 -2
  124. package/dist/cli.cjs +163 -147
  125. package/dist/clock.js +91 -5
  126. package/dist/countdown.js +208 -82
  127. package/dist/dgmo-router-Y2VEX46B.js +86 -0
  128. package/dist/dimensions-F7B5C4BJ.js +22 -0
  129. package/dist/editor.js +14 -1
  130. package/dist/element.d.ts +6 -0
  131. package/dist/element.js +170 -134
  132. package/dist/element.mjs +2112 -1009
  133. package/dist/{flowchart-parser-OE4WHLTF.js → flowchart-parser-MY53QWTZ.js} +4 -4
  134. package/dist/{flowchart-renderer-GPCSMTOR.js → flowchart-renderer-AQSMEMYF.js} +8 -8
  135. package/dist/highlight.js +14 -1
  136. package/dist/index.d.ts +2 -2
  137. package/dist/index.js +55 -53
  138. package/dist/{layout-7SKMFYHL.js → layout-46N4JJYK.js} +5 -5
  139. package/dist/layout-4DIUOX2T.js +14 -0
  140. package/dist/{layout-7H4H46CS.js → layout-7QXCNOVS.js} +3 -3
  141. package/dist/{layout-NXG63LWH.js → layout-AM2JWW3X.js} +4 -4
  142. package/dist/{layout-7MZ5NF2N.js → layout-CBCLPMSG.js} +5 -5
  143. package/dist/{layout-DC4TVXER.js → layout-EE6GE46Y.js} +5 -5
  144. package/dist/{layout-FGQWRYYW.js → layout-F4WO357A.js} +3 -3
  145. package/dist/layout-G23F7LDH.js +9 -0
  146. package/dist/{layout-QNUQLEHU.js → layout-HYZPWAK5.js} +3 -3
  147. package/dist/{layout-FWODLIMP.js → layout-JDJAEQ3P.js} +6 -6
  148. package/dist/layout-MUPRALE5.js +14 -0
  149. package/dist/{layout-34CLNICW.js → layout-OAC4PEAC.js} +5 -5
  150. package/dist/{layout-5BG6DFCU.js → layout-YVTNOTN4.js} +6 -6
  151. package/dist/{layout-PUQCB6AN.js → layout-ZDOSXL5G.js} +7 -7
  152. package/dist/{layout-search-QS44PI5R.js → layout-search-55FU6HD3.js} +6 -157
  153. package/dist/map-data/gazetteer.json +1 -1
  154. package/dist/{parser-36HVKU5U.js → parser-2Q2T4C3B.js} +6 -5
  155. package/dist/{parser-B5FVS7O6.js → parser-3A42DZ72.js} +3 -3
  156. package/dist/{parser-CSFUN3CT.js → parser-4RFTKAQX.js} +5 -4
  157. package/dist/{parser-IJBMRXMC.js → parser-57ILIFZ2.js} +5 -5
  158. package/dist/{parser-DFFEDKHH.js → parser-5A2UWU6B.js} +3 -3
  159. package/dist/{parser-H3XEPFPV.js → parser-5PDYJGWA.js} +4 -4
  160. package/dist/{parser-O4HIUN6G.js → parser-6BJEXUFX.js} +4 -4
  161. package/dist/{parser-MTOMTWTD.js → parser-6ZKABF5S.js} +6 -5
  162. package/dist/{parser-WAV5JRPT.js → parser-AIMHGJRR.js} +4 -4
  163. package/dist/{parser-TXND652E.js → parser-AZJ25OKK.js} +4 -4
  164. package/dist/{parser-4AI5ZN5F.js → parser-B77S5SZM.js} +3 -3
  165. package/dist/{parser-IBWNAPY4.js → parser-BEPSWJAD.js} +3 -3
  166. package/dist/{parser-D5VILGN2.js → parser-BKI42XBQ.js} +4 -4
  167. package/dist/{parser-LWKKBNSA.js → parser-C3D7MVXY.js} +3 -3
  168. package/dist/{parser-HYRTF3DO.js → parser-CDG7CHV5.js} +3 -3
  169. package/dist/{parser-CVMEDULU.js → parser-CZOJ7XQ6.js} +4 -4
  170. package/dist/{parser-AXKBDGNO.js → parser-E2RL6JYF.js} +5 -5
  171. package/dist/{parser-PSA4UBSP.js → parser-EH5VE7ZN.js} +4 -4
  172. package/dist/{parser-K3XXLMUW.js → parser-FQ6GZFMR.js} +4 -4
  173. package/dist/{parser-RV4M6AS2.js → parser-GKLZKEIK.js} +4 -4
  174. package/dist/{parser-MPCE5JBG.js → parser-H6ABKHZZ.js} +4 -4
  175. package/dist/{parser-RZPVAQVX.js → parser-I6GGFKOQ.js} +4 -3
  176. package/dist/{parser-W4PQUGX3.js → parser-JA7JQ7NF.js} +4 -4
  177. package/dist/{parser-5OXGPNBF.js → parser-KKTJ6M3Y.js} +5 -5
  178. package/dist/parser-OK22AC6Y.js +14 -0
  179. package/dist/{parser-4NO6VZ6S.js → parser-OK2ILHRT.js} +4 -4
  180. package/dist/{parser-YS7TOS2K.js → parser-OUTPNJWC.js} +3 -3
  181. package/dist/{parser-KCR2WS3V.js → parser-PORDUX5E.js} +4 -4
  182. package/dist/{parser-VKOJM7KS.js → parser-SRVFR7PM.js} +4 -4
  183. package/dist/{parser-TGQZJ5OT.js → parser-UKFFZCFJ.js} +4 -4
  184. package/dist/{parser-JJR52VAT.js → parser-UMWPLORP.js} +5 -5
  185. package/dist/{parser-AGVYTQXV.js → parser-Z4TZV2CB.js} +4 -4
  186. package/dist/{renderer-A5VE5BCI.js → renderer-2AUFT3E2.js} +8 -8
  187. package/dist/{renderer-FPE3J5VZ.js → renderer-2HTNBIF2.js} +11 -11
  188. package/dist/{renderer-R2WNIC2C.js → renderer-3K3IB7D5.js} +8 -8
  189. package/dist/{renderer-2AZ5HJFK.js → renderer-3YNIWF5I.js} +4 -4
  190. package/dist/{renderer-P5ROYQGU.js → renderer-3YPZHMOU.js} +3 -3
  191. package/dist/{renderer-JCCHNECZ.js → renderer-4WR6WMVF.js} +9 -9
  192. package/dist/{renderer-HDCCZURL.js → renderer-66MERVQ2.js} +9 -9
  193. package/dist/{renderer-2QPMJ2DA.js → renderer-6RKQPNJI.js} +9 -9
  194. package/dist/{renderer-FYSVXL7M.js → renderer-ARMJBP6C.js} +11 -11
  195. package/dist/{renderer-6OKF44KS.js → renderer-CO2DW7S7.js} +13 -13
  196. package/dist/{renderer-BSR2O2H6.js → renderer-EDJ2O4S5.js} +13 -12
  197. package/dist/{renderer-CYB4LK3G.js → renderer-F7U3MFCV.js} +9 -9
  198. package/dist/{renderer-5KVCNMOJ.js → renderer-GD2COXVL.js} +4 -2
  199. package/dist/{renderer-B5TBNZJE.js → renderer-GQIESYEM.js} +8 -8
  200. package/dist/{renderer-ODUUOPVT.js → renderer-HCKJDFXD.js} +13 -13
  201. package/dist/{renderer-QAOBLRXV.js → renderer-HYGHO4SJ.js} +10 -10
  202. package/dist/{renderer-5DSEWF74.js → renderer-JC3RDUT7.js} +8 -8
  203. package/dist/{renderer-7RH2SI3B.js → renderer-KQB7UGDS.js} +3 -3
  204. package/dist/{renderer-45PSOL3E.js → renderer-NKJ24TEA.js} +5 -5
  205. package/dist/{renderer-AUW2BE6G.js → renderer-OYO67VZK.js} +9 -9
  206. package/dist/{renderer-DAXMXIKD.js → renderer-QIWVHWZO.js} +3 -3
  207. package/dist/{renderer-PSMMZCKH.js → renderer-QRWACQRI.js} +8 -8
  208. package/dist/{renderer-4ITCHBT7.js → renderer-QXGN5H3A.js} +5 -5
  209. package/dist/renderer-QXPP4TA2.js +27 -0
  210. package/dist/{renderer-KS7YZJE2.js → renderer-RGIYOTKJ.js} +10 -10
  211. package/dist/{renderer-FF24KZCI.js → renderer-RHT4MHFU.js} +8 -8
  212. package/dist/{renderer-PPIHO5FI.js → renderer-RYR3TJ46.js} +12 -11
  213. package/dist/{renderer-NGXZTRK6.js → renderer-SRKDNDFB.js} +8 -8
  214. package/dist/{renderer-SBS3YWU5.js → renderer-TGTUABCI.js} +8 -8
  215. package/dist/{renderer-7SD6MSBS.js → renderer-TXJFKPOG.js} +11 -11
  216. package/dist/{renderer-HVCU2C3Z.js → renderer-UV6MI64M.js} +3 -3
  217. package/dist/renderer-radial-FWABAZHB.js +21 -0
  218. package/dist/{resolver-FHBCO3PL.js → resolver-EMTGNR3D.js} +4 -3
  219. package/dist/{state-parser-3REXRK3R.js → state-parser-6T6CNMPX.js} +4 -4
  220. package/dist/{state-renderer-XYLNRWXR.js → state-renderer-AWZ3ECAX.js} +8 -8
  221. package/dist/{themes-PdPR1-hC.d.ts → themes-32xj5ZTW.d.ts} +27 -0
  222. package/docs/language-reference.md +93 -10
  223. package/gallery/fixtures/clock.dgmo +3 -3
  224. package/gallery/fixtures/countdown-tz.dgmo +5 -0
  225. package/package.json +1 -1
  226. package/dist/dgmo-router-CE2G67FV.js +0 -84
  227. package/dist/dimensions-OTBKC5M6.js +0 -22
  228. package/dist/layout-6RDJHS6E.js +0 -9
  229. package/dist/layout-J36454XU.js +0 -14
  230. package/dist/layout-LD6XTLD6.js +0 -14
  231. package/dist/parser-4WQQQXCG.js +0 -13
  232. package/dist/renderer-UYMQQCJK.js +0 -24
  233. package/dist/renderer-radial-F7X5F2VU.js +0 -21
package/dist/block.css CHANGED
@@ -26,21 +26,25 @@
26
26
  }
27
27
 
28
28
  /* === Toolbar ===
29
- * The diagram is the star: the toolbar is a slim reserved row below the SVG
30
- * (height always in flow — no layout shift) that stays fully transparent
31
- * until the block is hovered or focused, or the source panel is open. It is
32
- * the <summary> of the source <details>, so toggling works without any JS.
29
+ * The diagram is the star: the toolbar is an overlay pinned to the diagram's
30
+ * top-right corner (position:absolute — it reserves no layout space, so the
31
+ * block is exactly as tall as the chart). It stays fully transparent until
32
+ * the block is hovered or focused, or the source panel is open. It is the
33
+ * <summary> of the source <details>, so toggling works without any JS.
33
34
  * No text labels, no disclosure triangle — three wordless icon buttons. */
34
35
  .dgmo-source-wrap {
35
36
  margin: 0;
36
37
  }
37
38
  .dgmo-toolbar {
39
+ position: absolute;
40
+ top: 0.4em;
41
+ right: 0.4em;
42
+ z-index: 2;
38
43
  display: flex;
39
44
  align-items: center;
40
45
  justify-content: flex-end;
41
46
  gap: 0.25em;
42
- min-height: 1.9em;
43
- padding: 0.15em 0;
47
+ padding: 0.15em;
44
48
  opacity: 0;
45
49
  transition: opacity 0.15s ease;
46
50
  cursor: pointer;
@@ -143,6 +147,14 @@
143
147
  overflow: auto;
144
148
  border-radius: 0.5em;
145
149
  box-shadow: 0 12px 48px rgba(0, 0, 0, 0.45);
150
+ /* Opaque surface behind the enlarged diagram so a transparent embed doesn't
151
+ * show the page through it. The client overrides this inline with the block's
152
+ * own palette bg (data-dgmo-bg); this is the fallback for blocks that predate
153
+ * that attribute. */
154
+ background: #fff;
155
+ }
156
+ [data-theme="dark"] .dgmo-lightbox-svg {
157
+ background: #1e1e1e;
146
158
  }
147
159
  .dgmo-lightbox-svg > svg {
148
160
  display: block;
@@ -177,9 +189,10 @@
177
189
  * border so the code visibly belongs to the chart above it. The frame box
178
190
  * (border + padding) is RESERVED at all times — with the border transparent
179
191
  * while closed — so opening the panel only paints the border in. It never
180
- * reflows the diagram or shifts the toolbar: the SVG box and toolbar position
181
- * are identical open vs closed. */
192
+ * reflows the diagram. position:relative anchors the overlay toolbar to
193
+ * this box. */
182
194
  .dgmo:has(> .dgmo-source-wrap) {
195
+ position: relative;
183
196
  border: 1px solid transparent;
184
197
  border-radius: 0.6em;
185
198
  padding: 0.75em 0.75em 0.5em;
@@ -222,6 +235,13 @@
222
235
  font-size: 0.85em;
223
236
  margin: 0.5em 0 0;
224
237
  }
238
+ .dgmo-error-docs {
239
+ display: inline-block;
240
+ margin-top: 0.6em;
241
+ font-size: 0.9em;
242
+ font-weight: 600;
243
+ color: inherit;
244
+ }
225
245
 
226
246
  /* === Source highlight roles ===
227
247
  * Light values mirror LIGHT_ROLE_STYLES; dark overrides mirror
package/dist/block.js CHANGED
@@ -1,92 +1,95 @@
1
1
  import {
2
2
  defaultEmbedBackground,
3
+ docsLink,
3
4
  normalizeSvgForEmbed,
4
5
  renderErrorCard
5
- } from "./chunk-DN66GPY5.js";
6
+ } from "./chunk-GNSFLJAA.js";
6
7
  import {
7
8
  encodeDiagramUrl,
8
9
  render
9
- } from "./chunk-SVTI362O.js";
10
- import "./chunk-66RUL3XF.js";
10
+ } from "./chunk-3ODS2VGL.js";
11
+ import "./chunk-B63YB7X3.js";
11
12
  import "./chunk-YRYKTYMQ.js";
12
13
  import "./chunk-YYVTBZZC.js";
13
- import "./chunk-HEVYAHLW.js";
14
- import "./chunk-KQ57MHRO.js";
15
- import "./chunk-Q4V4XQWV.js";
16
- import "./chunk-BTUTZMPT.js";
14
+ import "./chunk-OU7HLO7I.js";
15
+ import "./chunk-KJGG2JKQ.js";
16
+ import "./chunk-GTWKD3QT.js";
17
+ import "./chunk-AFIEPDLX.js";
17
18
  import {
18
19
  monthIndex,
19
20
  weekdayIndex
20
- } from "./chunk-YNRDWYZP.js";
21
- import "./chunk-3XPUDB7B.js";
22
- import "./chunk-QXKWYZNR.js";
23
- import "./chunk-PGEGPSCZ.js";
24
- import "./chunk-3UIKSPFB.js";
21
+ } from "./chunk-OQKP2X3D.js";
22
+ import "./chunk-6NFYEQDX.js";
23
+ import "./chunk-APKUAJ2L.js";
24
+ import "./chunk-XEQXCIBC.js";
25
+ import "./chunk-6MNGECP2.js";
26
+ import "./chunk-6BQFET7X.js";
25
27
  import "./chunk-BDXC7MDK.js";
26
- import "./chunk-QJJZSROI.js";
27
- import "./chunk-HGN652MU.js";
28
+ import "./chunk-4VWJ4LW2.js";
29
+ import "./chunk-VL2O2F3W.js";
28
30
  import "./chunk-U6EQI3U6.js";
29
- import "./chunk-7UEMZREK.js";
31
+ import "./chunk-YAA6IID3.js";
30
32
  import "./chunk-A4GOY3PE.js";
31
33
  import "./chunk-6KFWC4CO.js";
32
- import "./chunk-HQCHYB5F.js";
33
- import "./chunk-5LWQH6QV.js";
34
- import "./chunk-XEGTMVYY.js";
35
- import "./chunk-I2WKW7C7.js";
36
- import "./chunk-TSA237IM.js";
37
- import "./chunk-6IAA2QQ2.js";
38
- import "./chunk-6HJBFVLO.js";
39
- import "./chunk-3P2DKJCG.js";
40
- import "./chunk-3LKM6FMW.js";
41
- import "./chunk-XJLKLU4D.js";
42
- import "./chunk-7L3R6I3U.js";
34
+ import "./chunk-QOOUC2J5.js";
35
+ import "./chunk-WCT3NYCV.js";
36
+ import "./chunk-QZPEGJOM.js";
37
+ import "./chunk-GGHRAITI.js";
38
+ import "./chunk-PZDBOK2Q.js";
39
+ import "./chunk-2EQMXBBQ.js";
40
+ import "./chunk-4QZ43D7I.js";
41
+ import "./chunk-Q62FEYK3.js";
42
+ import "./chunk-AE7II3E3.js";
43
+ import "./chunk-2ILHQOL3.js";
44
+ import "./chunk-ENRS56GC.js";
43
45
  import "./chunk-NNAAJVBU.js";
44
- import "./chunk-VUJGMJE6.js";
45
- import "./chunk-C2CVAM3U.js";
46
- import "./chunk-GKC3HILQ.js";
46
+ import "./chunk-MVN25IF6.js";
47
+ import "./chunk-5PZT4DQG.js";
48
+ import "./chunk-I2QZFCS2.js";
47
49
  import {
48
50
  REGISTRY_COLON_KEY_TOKENS,
49
51
  REGISTRY_CONTROL_TOKENS,
50
52
  REGISTRY_DIRECTIVE_TOKENS,
51
53
  REGISTRY_MODIFIER_TOKENS,
52
54
  REGISTRY_STATUS_TOKENS
53
- } from "./chunk-U2HGPLZS.js";
54
- import "./chunk-DSWVNQVS.js";
55
- import "./chunk-DZXYF2F5.js";
55
+ } from "./chunk-6H7O2OPM.js";
56
+ import "./chunk-BGP54HVR.js";
57
+ import "./chunk-6K2M4VSR.js";
56
58
  import "./chunk-XHVV4NVW.js";
57
- import "./chunk-OMNGQPEZ.js";
58
- import "./chunk-VBYSIOOY.js";
59
+ import "./chunk-E7Y3SYKW.js";
60
+ import "./chunk-5WPNFSXP.js";
59
61
  import "./chunk-QQJUTGQH.js";
60
- import "./chunk-SXRTRMEE.js";
61
- import "./chunk-NU3XLTGP.js";
62
- import "./chunk-OTQKUHRS.js";
63
- import "./chunk-SQLNBA64.js";
64
- import "./chunk-EAMEADTV.js";
65
- import "./chunk-L3UHP6TD.js";
62
+ import "./chunk-2UJSV2VT.js";
63
+ import "./chunk-332ZR4QU.js";
64
+ import "./chunk-RBHWPDBB.js";
65
+ import "./chunk-KFNWFNAA.js";
66
+ import "./chunk-5PDTIBLV.js";
67
+ import "./chunk-7L4UJOY6.js";
66
68
  import "./chunk-USZW2HHU.js";
67
- import "./chunk-HTMN2Z6U.js";
68
- import "./chunk-I7F2A35O.js";
69
- import "./chunk-6BFZKBGD.js";
70
- import "./chunk-3Y2DRD7S.js";
71
- import "./chunk-QROYX7TT.js";
69
+ import "./chunk-EDA6C7MV.js";
70
+ import "./chunk-TMACGPW5.js";
71
+ import "./chunk-RBDIYLA5.js";
72
+ import "./chunk-JJXGQIRV.js";
73
+ import "./chunk-IEDMFNU7.js";
74
+ import "./chunk-3LV2NCB6.js";
72
75
  import "./chunk-IYULMRBE.js";
73
76
  import {
74
77
  resolvePaletteOrFallback
75
78
  } from "./chunk-R3XI2VC7.js";
76
79
  import "./chunk-P6T66CCZ.js";
77
- import "./chunk-BH3UYK36.js";
80
+ import "./chunk-RLFVAKEO.js";
78
81
  import "./chunk-C3Z4DX3V.js";
79
- import "./chunk-FJUNPCYI.js";
80
- import "./chunk-GBE54KY6.js";
82
+ import "./chunk-467TVMQL.js";
83
+ import "./chunk-OZPBJM5Q.js";
81
84
  import "./chunk-I46X5VUA.js";
82
- import "./chunk-2C56LEML.js";
85
+ import "./chunk-5F5ELR3V.js";
83
86
  import "./chunk-NXMESY4J.js";
84
- import "./chunk-GL5UZ6NY.js";
85
- import "./chunk-SCHXJTZL.js";
87
+ import "./chunk-FC5I2KXV.js";
88
+ import "./chunk-WQLMU7VG.js";
86
89
  import "./chunk-FMDSF3OV.js";
87
90
  import "./chunk-FFUN5D66.js";
88
91
  import "./chunk-NOTA6TEI.js";
89
- import "./chunk-OTAL43EH.js";
92
+ import "./chunk-LV4BETUU.js";
90
93
  import "./chunk-TLVIHFRO.js";
91
94
  import "./chunk-CXK4DZH3.js";
92
95
  import "./chunk-5WRI5ZAA.js";
@@ -184,7 +187,7 @@ var parser = LRParser.deserialize({
184
187
  maxTerm: 40,
185
188
  skippedNodes: [0],
186
189
  repeatNodeCount: 2,
187
- tokenData: "<v~RzOX#uXY#zYZ$VZp#upq#zqr#ur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!]:^!_!`3R!a!b3R!b!c3R!c!}3R#R#S3R#T#g3R#g#h<W#h#o3R~:aP!P!Q:d~:gP!P!Q:j~:mYOX;]Zp;]qy;]z|;]}!`;]!a#P;]#Q#p;]#q;'S;];'S;=`<Q<%lO;]~;bY`~OX;]Zp;]qy;]z|;]}!`;]!a#P;]#Q#p;]#q;'S;];'S;=`<Q<%lO;]~<TP;=`<%l;]~<]`p~qr3Rst3Rvw3Rwx3R{|3R}!O4V!O!P3R!P!Q3R!Q![3R![!]:^!_!`3R!a!b3R!b!c3R!c!}3R#R#S3R#T#o3R~=fOg~q~~=mPl~q~!`!a=p~=uOY~~=xP;=`<%l#u",
188
191
  tokenizers: [0],
189
192
  topRules: { "Document": [0, 6] },
190
193
  specialized: [{ term: 32, get: (value, stack) => specializeKeyword(value, stack) << 1, external: specializeKeyword }],
@@ -611,21 +614,25 @@ var BLOCK_CSS = `
611
614
  }
612
615
 
613
616
  /* === Toolbar ===
614
- * The diagram is the star: the toolbar is a slim reserved row below the SVG
615
- * (height always in flow \u2014 no layout shift) that stays fully transparent
616
- * until the block is hovered or focused, or the source panel is open. It is
617
- * the <summary> of the source <details>, so toggling works without any JS.
617
+ * The diagram is the star: the toolbar is an overlay pinned to the diagram's
618
+ * top-right corner (position:absolute \u2014 it reserves no layout space, so the
619
+ * block is exactly as tall as the chart). It stays fully transparent until
620
+ * the block is hovered or focused, or the source panel is open. It is the
621
+ * <summary> of the source <details>, so toggling works without any JS.
618
622
  * No text labels, no disclosure triangle \u2014 three wordless icon buttons. */
619
623
  .dgmo-source-wrap {
620
624
  margin: 0;
621
625
  }
622
626
  .dgmo-toolbar {
627
+ position: absolute;
628
+ top: 0.4em;
629
+ right: 0.4em;
630
+ z-index: 2;
623
631
  display: flex;
624
632
  align-items: center;
625
633
  justify-content: flex-end;
626
634
  gap: 0.25em;
627
- min-height: 1.9em;
628
- padding: 0.15em 0;
635
+ padding: 0.15em;
629
636
  opacity: 0;
630
637
  transition: opacity 0.15s ease;
631
638
  cursor: pointer;
@@ -728,6 +735,14 @@ var BLOCK_CSS = `
728
735
  overflow: auto;
729
736
  border-radius: 0.5em;
730
737
  box-shadow: 0 12px 48px rgba(0, 0, 0, 0.45);
738
+ /* Opaque surface behind the enlarged diagram so a transparent embed doesn't
739
+ * show the page through it. The client overrides this inline with the block's
740
+ * own palette bg (data-dgmo-bg); this is the fallback for blocks that predate
741
+ * that attribute. */
742
+ background: #fff;
743
+ }
744
+ [data-theme="dark"] .dgmo-lightbox-svg {
745
+ background: #1e1e1e;
731
746
  }
732
747
  .dgmo-lightbox-svg > svg {
733
748
  display: block;
@@ -762,9 +777,10 @@ var BLOCK_CSS = `
762
777
  * border so the code visibly belongs to the chart above it. The frame box
763
778
  * (border + padding) is RESERVED at all times \u2014 with the border transparent
764
779
  * while closed \u2014 so opening the panel only paints the border in. It never
765
- * reflows the diagram or shifts the toolbar: the SVG box and toolbar position
766
- * are identical open vs closed. */
780
+ * reflows the diagram. position:relative anchors the overlay toolbar to
781
+ * this box. */
767
782
  .dgmo:has(> .dgmo-source-wrap) {
783
+ position: relative;
768
784
  border: 1px solid transparent;
769
785
  border-radius: 0.6em;
770
786
  padding: 0.75em 0.75em 0.5em;
@@ -807,6 +823,13 @@ var BLOCK_CSS = `
807
823
  font-size: 0.85em;
808
824
  margin: 0.5em 0 0;
809
825
  }
826
+ .dgmo-error-docs {
827
+ display: inline-block;
828
+ margin-top: 0.6em;
829
+ font-size: 0.9em;
830
+ font-weight: 600;
831
+ color: inherit;
832
+ }
810
833
 
811
834
  /* === Source highlight roles ===
812
835
  * Light values mirror LIGHT_ROLE_STYLES; dark overrides mirror
@@ -986,11 +1009,12 @@ async function renderDgmoBlock(source, options = {}) {
986
1009
  renderTheme("dark")
987
1010
  ]);
988
1011
  const background = opts.background === "auto" ? defaultEmbedBackground(chartType) : opts.background;
989
- svgsHtml = `<div class="${escapeAttr(innerClasses(opts, "dgmo-light"))}">${normalizeSvgForEmbed(light, { background })}</div><div class="${escapeAttr(innerClasses(opts, "dgmo-dark"))}">${normalizeSvgForEmbed(dark, { background })}</div>`;
1012
+ svgsHtml = `<div class="${escapeAttr(innerClasses(opts, "dgmo-light"))}" data-dgmo-bg="${escapeAttr(palette.light.bg)}">${normalizeSvgForEmbed(light, { background })}</div><div class="${escapeAttr(innerClasses(opts, "dgmo-dark"))}" data-dgmo-bg="${escapeAttr(palette.dark.bg)}">${normalizeSvgForEmbed(dark, { background })}</div>`;
990
1013
  } else {
991
1014
  const svg = await renderTheme(opts.colorMode);
992
1015
  const background = opts.background === "auto" ? defaultEmbedBackground(chartType) : opts.background;
993
- svgsHtml = `<div class="${escapeAttr(innerClasses(opts, "dgmo-svg"))}">${normalizeSvgForEmbed(svg, { background })}</div>`;
1016
+ const paletteBg = palette[opts.colorMode === "dark" ? "dark" : "light"].bg;
1017
+ svgsHtml = `<div class="${escapeAttr(innerClasses(opts, "dgmo-svg"))}" data-dgmo-bg="${escapeAttr(paletteBg)}">${normalizeSvgForEmbed(svg, { background })}</div>`;
994
1018
  }
995
1019
  return { html: assembleBlock(trimmed, svgsHtml, opts), diagnostics };
996
1020
  }
@@ -1002,7 +1026,8 @@ function errorBlockHtml(err, source, options = {}) {
1002
1026
  const base = options.className ?? "dgmo";
1003
1027
  const legacy = (options.legacyClassNames ?? []).join(" ");
1004
1028
  const cls = legacy ? `${base} ${legacy} ${base}--error` : `${base} ${base}--error`;
1005
- return `<div class="${escapeAttr(cls)}" role="alert"><strong>dgmo render error:</strong> ${escapeHtml(msg)}<pre>${escapeHtml(source)}</pre></div>`;
1029
+ const docs = docsLink(source);
1030
+ return `<div class="${escapeAttr(cls)}" role="alert"><strong>dgmo render error:</strong> ${escapeHtml(msg)}<pre>${escapeHtml(source)}</pre><a class="${escapeAttr(base)}-error-docs" href="${escapeAttr(docs.url)}" target="_blank" rel="noopener noreferrer">${escapeHtml(docs.label)}</a></div>`;
1006
1031
  }
1007
1032
  function wrapperClasses(opts, variant) {
1008
1033
  const base = `${opts.className} ${opts.className}--${variant}`;
@@ -1018,7 +1043,7 @@ function assembleBlock(source, svgsHtml, opts) {
1018
1043
  const showcase = opts.mode === "showcase";
1019
1044
  const variant = showcase ? "showcase" : "diagram";
1020
1045
  const ariaAttr = opts.title ? ` aria-label="${escapeAttr(opts.title)}"` : "";
1021
- const sourceHtml = showcase ? sourceDisclosure(source, opts) : "";
1046
+ const sourceHtml = sourceDisclosure(source, opts);
1022
1047
  return `<${Wrapper} class="${escapeAttr(wrapperClasses(opts, variant))}"${ariaAttr}>` + svgsHtml + sourceHtml + `</${Wrapper}>`;
1023
1048
  }
1024
1049
  var CODE_ICON = `<svg width="16" height="16" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="m10 4.5 4 3.5-4 3.5"/><path d="m6 4.5-4 3.5 4 3.5"/></svg>`;
@@ -1026,8 +1051,7 @@ var COPY_ICON = `<svg width="16" height="16" viewBox="0 0 16 16" fill="none" str
1026
1051
  var EXTERNAL_ICON = `<svg width="16" height="16" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M9.5 2.5h4v4"/><path d="M13.5 2.5 7 9"/><path d="M12.5 9.5v3a1 1 0 0 1-1 1h-8a1 1 0 0 1-1-1v-8a1 1 0 0 1 1-1h3"/></svg>`;
1027
1052
  var EXPAND_ICON = `<svg width="16" height="16" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M9.5 2.5h4v4"/><path d="M6.5 13.5h-4v-4"/><path d="M13.5 2.5 9 7"/><path d="M2.5 13.5 7 9"/></svg>`;
1028
1053
  function sourceDisclosure(source, opts) {
1029
- if (!opts.showSource) return "";
1030
- const toggle = `<span class="dgmo-toggle" title="View DGMO source">${CODE_ICON}</span>`;
1054
+ const toggle = opts.showSource ? `<span class="dgmo-toggle" title="View DGMO source">${CODE_ICON}</span>` : "";
1031
1055
  const expandButton = opts.showExpand ? `<button type="button" class="dgmo-toolbar-btn dgmo-expand" aria-label="View full screen" title="Expand">${EXPAND_ICON}</button>` : "";
1032
1056
  const copyButton = opts.showCopy ? `<button type="button" class="dgmo-toolbar-btn dgmo-copy" aria-label="Copy DGMO source" title="Copy source" data-dgmo-source="${escapeAttr(source)}">${COPY_ICON}</button>` : "";
1033
1057
  let openButton = "";
@@ -1037,8 +1061,13 @@ function sourceDisclosure(source, opts) {
1037
1061
  openButton = `<a href="${escapeAttr(encoded.url)}" target="_blank" rel="noopener noreferrer" class="dgmo-toolbar-btn dgmo-open" aria-label="Open in online editor" title="Open in online editor">${EXTERNAL_ICON}</a>`;
1038
1062
  }
1039
1063
  }
1064
+ const buttons = `${toggle}${expandButton}${copyButton}${openButton}`;
1065
+ if (!buttons) return "";
1066
+ if (!opts.showSource) {
1067
+ return `<div class="dgmo-source-wrap"><div class="dgmo-toolbar">${buttons}</div></div>`;
1068
+ }
1040
1069
  const sourceHtml = highlightedSource(source);
1041
- return `<details class="dgmo-source-wrap"><summary class="dgmo-toolbar" aria-label="View DGMO source">${toggle}${expandButton}${copyButton}${openButton}</summary><div class="dgmo-source-inner">${sourceHtml}</div></details>`;
1070
+ return `<details class="dgmo-source-wrap"><summary class="dgmo-toolbar" aria-label="View DGMO source">${buttons}</summary><div class="dgmo-source-inner">${sourceHtml}</div></details>`;
1042
1071
  }
1043
1072
  function highlightedSource(source) {
1044
1073
  const tokens = highlightDgmo(source);
@@ -2,19 +2,19 @@ import {
2
2
  D3_DATA_CHART_TYPES,
3
3
  renderDataChartD3,
4
4
  supportsD3DataChart
5
- } from "./chunk-QJJZSROI.js";
6
- import "./chunk-HGN652MU.js";
5
+ } from "./chunk-4VWJ4LW2.js";
6
+ import "./chunk-VL2O2F3W.js";
7
7
  import "./chunk-U6EQI3U6.js";
8
- import "./chunk-7UEMZREK.js";
8
+ import "./chunk-YAA6IID3.js";
9
9
  import "./chunk-A4GOY3PE.js";
10
10
  import "./chunk-6KFWC4CO.js";
11
- import "./chunk-HQCHYB5F.js";
12
- import "./chunk-5LWQH6QV.js";
13
- import "./chunk-XEGTMVYY.js";
11
+ import "./chunk-QOOUC2J5.js";
12
+ import "./chunk-WCT3NYCV.js";
13
+ import "./chunk-QZPEGJOM.js";
14
14
  import "./chunk-R3XI2VC7.js";
15
15
  import "./chunk-P6T66CCZ.js";
16
- import "./chunk-FJUNPCYI.js";
17
- import "./chunk-OTAL43EH.js";
16
+ import "./chunk-467TVMQL.js";
17
+ import "./chunk-LV4BETUU.js";
18
18
  import "./chunk-TLVIHFRO.js";
19
19
  import "./chunk-CXK4DZH3.js";
20
20
  import "./chunk-5WRI5ZAA.js";
@@ -23,4 +23,4 @@ export {
23
23
  renderDataChartD3,
24
24
  supportsD3DataChart
25
25
  };
26
- //# sourceMappingURL=charts-d3-MUW3LTML.js.map
26
+ //# sourceMappingURL=charts-d3-7E4B4IMW.js.map
@@ -5,7 +5,7 @@ import {
5
5
  splitNameAndMeta,
6
6
  tryParseSharedOption,
7
7
  warnUnknownMetaKeys
8
- } from "./chunk-OTAL43EH.js";
8
+ } from "./chunk-LV4BETUU.js";
9
9
  import {
10
10
  makeDgmoError,
11
11
  makeFail
@@ -274,4 +274,4 @@ function parseCycle(content) {
274
274
  export {
275
275
  parseCycle
276
276
  };
277
- //# sourceMappingURL=chunk-6IAA2QQ2.js.map
277
+ //# sourceMappingURL=chunk-2EQMXBBQ.js.map
@@ -7,7 +7,7 @@ import {
7
7
  tagAttrKey,
8
8
  validateTagGroupNames,
9
9
  validateTagValues
10
- } from "./chunk-FJUNPCYI.js";
10
+ } from "./chunk-467TVMQL.js";
11
11
  import {
12
12
  TREEMAP_REGISTRY,
13
13
  extractColor,
@@ -18,7 +18,7 @@ import {
18
18
  stripQuotes,
19
19
  warnUnknownMetaKeys,
20
20
  withTagAliases
21
- } from "./chunk-OTAL43EH.js";
21
+ } from "./chunk-LV4BETUU.js";
22
22
  import {
23
23
  emit,
24
24
  formatDgmoError,
@@ -377,4 +377,4 @@ export {
377
377
  TREEMAP_DIAGNOSTICS,
378
378
  parseTreemap
379
379
  };
380
- //# sourceMappingURL=chunk-XJLKLU4D.js.map
380
+ //# sourceMappingURL=chunk-2ILHQOL3.js.map
@@ -10,7 +10,7 @@ import {
10
10
  tagAttrKey,
11
11
  validateTagGroupNames,
12
12
  validateTagValues
13
- } from "./chunk-FJUNPCYI.js";
13
+ } from "./chunk-467TVMQL.js";
14
14
  import {
15
15
  MINDMAP_REGISTRY,
16
16
  OPTION_NOCOLON_RE,
@@ -21,7 +21,7 @@ import {
21
21
  tryParseSharedOption,
22
22
  warnUnknownMetaKeys,
23
23
  withTagAliases
24
- } from "./chunk-OTAL43EH.js";
24
+ } from "./chunk-LV4BETUU.js";
25
25
  import {
26
26
  formatDgmoError,
27
27
  makeDgmoError,
@@ -313,4 +313,4 @@ function findMetadataParent(indent, indentStack) {
313
313
  export {
314
314
  parseMindmap
315
315
  };
316
- //# sourceMappingURL=chunk-SXRTRMEE.js.map
316
+ //# sourceMappingURL=chunk-2UJSV2VT.js.map
@@ -8,18 +8,18 @@ import {
8
8
  rectsOverlap,
9
9
  segmentRectOverlap,
10
10
  segmentsCross
11
- } from "./chunk-HGN652MU.js";
11
+ } from "./chunk-VL2O2F3W.js";
12
12
  import {
13
13
  compactNumber,
14
14
  computeLegendLayout
15
- } from "./chunk-7UEMZREK.js";
15
+ } from "./chunk-YAA6IID3.js";
16
16
  import {
17
17
  TITLE_FONT_SIZE,
18
18
  TITLE_Y
19
19
  } from "./chunk-A4GOY3PE.js";
20
20
  import {
21
21
  measureLegendText
22
- } from "./chunk-HQCHYB5F.js";
22
+ } from "./chunk-QOOUC2J5.js";
23
23
  import {
24
24
  contrastRatio,
25
25
  mix,
@@ -29,7 +29,7 @@ import {
29
29
  } from "./chunk-P6T66CCZ.js";
30
30
  import {
31
31
  tagAttrKey
32
- } from "./chunk-FJUNPCYI.js";
32
+ } from "./chunk-467TVMQL.js";
33
33
  import {
34
34
  resolveColor
35
35
  } from "./chunk-TLVIHFRO.js";
@@ -3177,4 +3177,4 @@ export {
3177
3177
  albersSkewFallback,
3178
3178
  layoutMap
3179
3179
  };
3180
- //# sourceMappingURL=chunk-LE4MYMLI.js.map
3180
+ //# sourceMappingURL=chunk-32XPAAET.js.map
@@ -6,10 +6,10 @@ import {
6
6
  tagAttrKey,
7
7
  validateTagGroupNames,
8
8
  validateTagValues
9
- } from "./chunk-FJUNPCYI.js";
9
+ } from "./chunk-467TVMQL.js";
10
10
  import {
11
11
  tryCollectNote
12
- } from "./chunk-SCHXJTZL.js";
12
+ } from "./chunk-WQLMU7VG.js";
13
13
  import {
14
14
  resolveNotes
15
15
  } from "./chunk-FMDSF3OV.js";
@@ -32,7 +32,7 @@ import {
32
32
  tryParseSharedOption,
33
33
  warnUnknownMetaKeys,
34
34
  withTagAliases
35
- } from "./chunk-OTAL43EH.js";
35
+ } from "./chunk-LV4BETUU.js";
36
36
  import {
37
37
  resolveColorWithDiagnostic
38
38
  } from "./chunk-TLVIHFRO.js";
@@ -521,4 +521,4 @@ export {
521
521
  looksLikeERDiagram,
522
522
  extractSymbols
523
523
  };
524
- //# sourceMappingURL=chunk-NU3XLTGP.js.map
524
+ //# sourceMappingURL=chunk-332ZR4QU.js.map
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  measureText,
3
3
  wrapTextToWidth
4
- } from "./chunk-5LWQH6QV.js";
4
+ } from "./chunk-WCT3NYCV.js";
5
5
  import {
6
6
  mix,
7
7
  shapeFill
@@ -287,4 +287,4 @@ export {
287
287
  scoreToCurveY,
288
288
  layoutJourneyMap
289
289
  };
290
- //# sourceMappingURL=chunk-F7BFXWNQ.js.map
290
+ //# sourceMappingURL=chunk-3JLKYGBQ.js.map
@@ -11,7 +11,7 @@ import {
11
11
  stripDefaultModifier,
12
12
  tagAttrKey,
13
13
  validateTagGroupNames
14
- } from "./chunk-FJUNPCYI.js";
14
+ } from "./chunk-467TVMQL.js";
15
15
  import {
16
16
  parseInArrowLabel
17
17
  } from "./chunk-FFUN5D66.js";
@@ -27,7 +27,7 @@ import {
27
27
  splitNameAndMeta,
28
28
  warnUnknownMetaKeys,
29
29
  withTagAliases
30
- } from "./chunk-OTAL43EH.js";
30
+ } from "./chunk-LV4BETUU.js";
31
31
  import {
32
32
  formatDgmoError,
33
33
  makeDgmoError,
@@ -804,4 +804,4 @@ function validateDeploymentRefs(result, knownNames, pushWarning) {
804
804
  export {
805
805
  parseC4
806
806
  };
807
- //# sourceMappingURL=chunk-QROYX7TT.js.map
807
+ //# sourceMappingURL=chunk-3LV2NCB6.js.map