@diagrammo/dgmo 0.51.0 → 0.53.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 (336) hide show
  1. package/.cursorrules +74 -77
  2. package/.github/copilot-instructions.md +74 -77
  3. package/.windsurfrules +74 -77
  4. package/SKILL.md +74 -77
  5. package/dist/advanced.d.ts +109 -246
  6. package/dist/advanced.js +296 -633
  7. package/dist/analyzer-TDN5KJFP.js +15 -0
  8. package/dist/auto.css +14 -6
  9. package/dist/auto.js +141 -129
  10. package/dist/auto.mjs +2062 -937
  11. package/dist/block.css +14 -6
  12. package/dist/block.js +123 -73
  13. package/dist/calculator-VBIT6GQF.js +11 -0
  14. package/dist/chart-meta-CPNVUZ5J.d.ts +232 -0
  15. package/dist/chart-meta.d.ts +2 -0
  16. package/dist/chart-meta.js +105 -0
  17. package/dist/charts-d3-DH2XA45I.js +26 -0
  18. package/dist/{chunk-RLFVAKEO.js → chunk-22OQWBWD.js} +25 -8
  19. package/dist/{chunk-I2QZFCS2.js → chunk-27STWBOK.js} +10 -8
  20. package/dist/{chunk-5PZT4DQG.js → chunk-2QC4HXCY.js} +41 -21
  21. package/dist/{chunk-HFMYN6N2.js → chunk-3B2GXZCX.js} +4 -3
  22. package/dist/{chunk-F3FYUFUH.js → chunk-3BEKKRH5.js} +18 -17
  23. package/dist/{chunk-2UJSV2VT.js → chunk-3CZLWOCI.js} +17 -7
  24. package/dist/{chunk-JEUJOX5X.js → chunk-3IUHKMJI.js} +2 -2
  25. package/dist/{chunk-7L4UJOY6.js → chunk-3TYUXC7D.js} +2 -2
  26. package/dist/{chunk-Y2ZE3MSG.js → chunk-43E26CDA.js} +2 -2
  27. package/dist/{chunk-ZO27FGJS.js → chunk-4ASVFYB2.js} +10 -7
  28. package/dist/{chunk-WCT3NYCV.js → chunk-4ASYQ347.js} +33 -8
  29. package/dist/{chunk-2ILHQOL3.js → chunk-4K42RUGC.js} +41 -13
  30. package/dist/{chunk-I5IGB56C.js → chunk-4QV26TEG.js} +41 -1
  31. package/dist/{chunk-QOOUC2J5.js → chunk-4RGZFA7H.js} +2 -2
  32. package/dist/{chunk-CXK4DZH3.js → chunk-4W2PE66Q.js} +12 -2
  33. package/dist/{chunk-EXOQP75F.js → chunk-4WGMGKCZ.js} +53 -33
  34. package/dist/{chunk-JED6ZDEE.js → chunk-5HWPEYWB.js} +2 -2
  35. package/dist/{chunk-3YSQZ75W.js → chunk-65V6IRFN.js} +46 -33
  36. package/dist/{chunk-TMACGPW5.js → chunk-6AUZPPAV.js} +4 -4
  37. package/dist/{chunk-6H7O2OPM.js → chunk-6DCOIN4W.js} +36 -6
  38. package/dist/{chunk-GTWKD3QT.js → chunk-6HTRCTAS.js} +7 -6
  39. package/dist/{chunk-VB4UJ3H2.js → chunk-6KY7OCZC.js} +21 -11
  40. package/dist/{chunk-YAA6IID3.js → chunk-774C2FF3.js} +2 -2
  41. package/dist/{chunk-WJ7RW65H.js → chunk-7GUF6SDR.js} +22 -20
  42. package/dist/{chunk-QYTPPDAO.js → chunk-7JDTNFAK.js} +3 -3
  43. package/dist/{chunk-U6EQI3U6.js → chunk-ADYKAKE3.js} +3 -3
  44. package/dist/{chunk-VNSXLA6G.js → chunk-AHXIMHDQ.js} +84 -20
  45. package/dist/chunk-AIMLCDAO.js +404 -0
  46. package/dist/{chunk-6MNGECP2.js → chunk-ALYZ3MAA.js} +4 -4
  47. package/dist/{chunk-5F5ELR3V.js → chunk-AN2DQB3G.js} +151 -20
  48. package/dist/{chunk-IEWG6J7C.js → chunk-AZNXGWDC.js} +91 -36
  49. package/dist/{chunk-4XFBQT5O.js → chunk-B4XS2AF2.js} +3 -3
  50. package/dist/{chunk-CC4YRBWV.js → chunk-BD3WGY4T.js} +18 -8
  51. package/dist/{chunk-RAHVMKBG.js → chunk-BFDVEO5R.js} +2 -2
  52. package/dist/{chunk-332ZR4QU.js → chunk-BR7AYN76.js} +8 -8
  53. package/dist/{chunk-P3NRSSUU.js → chunk-BULHGPHK.js} +3 -3
  54. package/dist/{chunk-PZDBOK2Q.js → chunk-CK2GMDXD.js} +11 -5
  55. package/dist/{chunk-467TVMQL.js → chunk-CMVZWP32.js} +3 -3
  56. package/dist/{chunk-GNSFLJAA.js → chunk-CQFNIIQN.js} +7 -7
  57. package/dist/{chunk-RBDIYLA5.js → chunk-DAOFNU6J.js} +17 -1
  58. package/dist/{chunk-AFIEPDLX.js → chunk-DWUMPMV2.js} +23 -11
  59. package/dist/{chunk-USZW2HHU.js → chunk-EQW6HOP4.js} +4 -3
  60. package/dist/{chunk-6BQFET7X.js → chunk-FFXCKZOU.js} +12 -4
  61. package/dist/{chunk-WRNFDFPU.js → chunk-FGDSTT3F.js} +2 -2
  62. package/dist/{chunk-6NFYEQDX.js → chunk-FLDC7ZAK.js} +34 -7
  63. package/dist/{chunk-IUJODQKX.js → chunk-FT7TPPZ5.js} +25 -23
  64. package/dist/{chunk-IEDMFNU7.js → chunk-FUKNRLIJ.js} +19 -7
  65. package/dist/{chunk-JJXGQIRV.js → chunk-FXCB7H5O.js} +4 -4
  66. package/dist/{chunk-GGHRAITI.js → chunk-GABSL6TH.js} +4 -4
  67. package/dist/{chunk-RXKTSFDL.js → chunk-GAWKIIPO.js} +35 -43
  68. package/dist/{chunk-ZJ3LS7DW.js → chunk-GMAH572Z.js} +6 -6
  69. package/dist/{chunk-TRM2J7ZN.js → chunk-GMIJ35PW.js} +28 -29
  70. package/dist/{chunk-AB7INMR5.js → chunk-GQ644SPD.js} +26 -25
  71. package/dist/{chunk-5QKQSSPO.js → chunk-GRM2A4BG.js} +4 -4
  72. package/dist/{chunk-3ODS2VGL.js → chunk-GWQJKTFS.js} +161 -704
  73. package/dist/{chunk-OTOHI4JO.js → chunk-H3HFC3SQ.js} +2 -2
  74. package/dist/{chunk-JSSX2SX4.js → chunk-HE5J53SZ.js} +4 -4
  75. package/dist/{chunk-2EQMXBBQ.js → chunk-HNBY6CNV.js} +3 -3
  76. package/dist/{chunk-J76PIKAT.js → chunk-HO3RCNF6.js} +3 -3
  77. package/dist/{chunk-OJTXTQA2.js → chunk-HORZ5H2L.js} +38 -31
  78. package/dist/{chunk-MX2EY5Y7.js → chunk-HOXKNRON.js} +2 -2
  79. package/dist/{chunk-E7Y3SYKW.js → chunk-I64ECJX3.js} +18 -8
  80. package/dist/{chunk-JM4LEPY3.js → chunk-IQJCVREL.js} +11 -8
  81. package/dist/{chunk-3JLKYGBQ.js → chunk-J7HI6G3G.js} +9 -6
  82. package/dist/{chunk-Q62FEYK3.js → chunk-JHOAH4TI.js} +3 -3
  83. package/dist/{chunk-OZPBJM5Q.js → chunk-JTMSWEIW.js} +11 -8
  84. package/dist/{chunk-P6T66CCZ.js → chunk-JYDMBWRP.js} +37 -19
  85. package/dist/{chunk-7DF4J4RL.js → chunk-KKHCNSKK.js} +17 -11
  86. package/dist/{chunk-ENRS56GC.js → chunk-KUSAVOWZ.js} +11 -8
  87. package/dist/{chunk-BYJBIALT.js → chunk-LC3FFD43.js} +23 -18
  88. package/dist/{chunk-65WJYYKJ.js → chunk-LHILKFDP.js} +16 -11
  89. package/dist/{chunk-NEQ6GJXB.js → chunk-LQHVDZYC.js} +52 -16
  90. package/dist/{chunk-5WPNFSXP.js → chunk-MA3HJZHB.js} +5 -5
  91. package/dist/{chunk-Z6XJQ6KO.js → chunk-MEQYZZFR.js} +3 -3
  92. package/dist/{chunk-MVN25IF6.js → chunk-NNUMX6WX.js} +42 -12
  93. package/dist/{chunk-7DYOELRK.js → chunk-NNYFQOTK.js} +78 -38
  94. package/dist/{chunk-NNAAJVBU.js → chunk-NR5HCAUD.js} +1 -1
  95. package/dist/{chunk-H6PI3KJT.js → chunk-ODUT5WMC.js} +2 -2
  96. package/dist/{chunk-5PDTIBLV.js → chunk-P3H7QVDH.js} +56 -19
  97. package/dist/{chunk-ND76YJCN.js → chunk-PIXZTCKH.js} +84 -117
  98. package/dist/{chunk-3LV2NCB6.js → chunk-PKNNHU7H.js} +22 -9
  99. package/dist/{chunk-TK2VQQX2.js → chunk-PT4SW76W.js} +20 -18
  100. package/dist/{chunk-AE7II3E3.js → chunk-PV2QO7QL.js} +4 -4
  101. package/dist/{chunk-FTBZV6NE.js → chunk-PYO4TJJ3.js} +34 -26
  102. package/dist/{chunk-QZPEGJOM.js → chunk-Q7AH665U.js} +28 -14
  103. package/dist/{chunk-QHI5XVUJ.js → chunk-QAALSCKI.js} +27 -26
  104. package/dist/{chunk-GD6L76WD.js → chunk-QI3BOLQB.js} +23 -11
  105. package/dist/{chunk-Y6GBQTBK.js → chunk-QWIBT6DS.js} +50 -28
  106. package/dist/{chunk-GU46PPT3.js → chunk-QXGACPS2.js} +5 -5
  107. package/dist/{chunk-FMDSF3OV.js → chunk-QZAW5SFH.js} +2 -2
  108. package/dist/{chunk-YGJZWZTY.js → chunk-R5NH5BZG.js} +12 -9
  109. package/dist/{chunk-U5SI5NIM.js → chunk-RJ5LBZ5U.js} +43 -26
  110. package/dist/{chunk-XHVV4NVW.js → chunk-RT7ACF77.js} +12 -2
  111. package/dist/{chunk-XEQXCIBC.js → chunk-RW5PEJ7D.js} +18 -6
  112. package/dist/{chunk-4VWJ4LW2.js → chunk-SG4PRYO3.js} +61 -49
  113. package/dist/{chunk-RBHWPDBB.js → chunk-SGPFVDUL.js} +18 -7
  114. package/dist/{chunk-KJGG2JKQ.js → chunk-SQCBSFT5.js} +84 -79
  115. package/dist/{chunk-5X6YQA2J.js → chunk-U7NKYLX2.js} +18 -16
  116. package/dist/chunk-U7VO6JAA.js +566 -0
  117. package/dist/{chunk-32XPAAET.js → chunk-UFQJMOVZ.js} +10 -10
  118. package/dist/{chunk-Z72XRXD4.js → chunk-UJRTPOHH.js} +3 -3
  119. package/dist/{chunk-EDA6C7MV.js → chunk-UK6DKJLD.js} +34 -14
  120. package/dist/{chunk-GROLTAWZ.js → chunk-UKP5HWB5.js} +149 -89
  121. package/dist/{chunk-DY7XLRHK.js → chunk-UQRIKAMH.js} +28 -27
  122. package/dist/{chunk-TYS6CSS5.js → chunk-UU6LUYUH.js} +2 -2
  123. package/dist/{chunk-NI3XQBPB.js → chunk-UVDCHR4E.js} +18 -6
  124. package/dist/{chunk-6K2M4VSR.js → chunk-VAO6ANGC.js} +23 -10
  125. package/dist/{chunk-6NYWYNBI.js → chunk-VGNIDAPQ.js} +4 -4
  126. package/dist/{chunk-VL2O2F3W.js → chunk-VHO3YBTB.js} +2 -2
  127. package/dist/{chunk-IUO34HKW.js → chunk-VIRANCNY.js} +36 -32
  128. package/dist/{chunk-4QZ43D7I.js → chunk-VJHBSPGF.js} +12 -14
  129. package/dist/{chunk-BGP54HVR.js → chunk-VKNCC2GX.js} +12 -8
  130. package/dist/{chunk-FC5I2KXV.js → chunk-VRRDUYOK.js} +7 -7
  131. package/dist/{chunk-G3PF3S7P.js → chunk-W2DINCHL.js} +15 -15
  132. package/dist/{chunk-OU7HLO7I.js → chunk-W5KMNC5U.js} +8 -8
  133. package/dist/{chunk-FFUN5D66.js → chunk-WF64MW5G.js} +2 -2
  134. package/dist/{chunk-X7EC3L2H.js → chunk-X3RXGSCZ.js} +48 -30
  135. package/dist/{chunk-KFNWFNAA.js → chunk-XEAQDIMF.js} +7 -6
  136. package/dist/{chunk-AXW3M6OQ.js → chunk-XG4NWFPY.js} +38 -27
  137. package/dist/{chunk-B63YB7X3.js → chunk-XQ4KN6JQ.js} +127 -65
  138. package/dist/{chunk-WBRZJOEC.js → chunk-XY3UDKKH.js} +4 -4
  139. package/dist/{chunk-IE477RQZ.js → chunk-YG2BEIQU.js} +14 -13
  140. package/dist/{chunk-LV4BETUU.js → chunk-YJVA3QUU.js} +55 -5
  141. package/dist/{chunk-5SVOCD5W.js → chunk-YR43LJT5.js} +20 -16
  142. package/dist/{chunk-TLVIHFRO.js → chunk-ZKPPI6BF.js} +2 -2
  143. package/dist/{chunk-WQLMU7VG.js → chunk-ZXUAPTCK.js} +3 -3
  144. package/dist/cli.cjs +158 -155
  145. package/dist/clock.js +25 -23
  146. package/dist/countdown.js +4 -3
  147. package/dist/dgmo-router-B4S23EBH.js +86 -0
  148. package/dist/dimensions-K6PGYYGT.js +22 -0
  149. package/dist/editor.js +36 -6
  150. package/dist/element.js +143 -131
  151. package/dist/element.mjs +2062 -937
  152. package/dist/flowchart-parser-LALR6J6F.js +21 -0
  153. package/dist/{flowchart-renderer-AQSMEMYF.js → flowchart-renderer-DXYB5YRF.js} +14 -14
  154. package/dist/highlight.d.ts +21 -1
  155. package/dist/highlight.js +129 -8
  156. package/dist/index.d.ts +4 -2
  157. package/dist/index.js +80 -75
  158. package/dist/layout-3BVDMKXI.js +15 -0
  159. package/dist/layout-3M5UYJHY.js +14 -0
  160. package/dist/{layout-JDJAEQ3P.js → layout-3V2A4MUE.js} +8 -8
  161. package/dist/layout-4IHCMWZN.js +19 -0
  162. package/dist/layout-5XGYNYVT.js +9 -0
  163. package/dist/layout-AZUPXWSK.js +15 -0
  164. package/dist/{layout-F4WO357A.js → layout-CAAKQX4W.js} +3 -3
  165. package/dist/layout-CB3XWCOI.js +10 -0
  166. package/dist/{layout-OAC4PEAC.js → layout-E6HR6PXH.js} +7 -7
  167. package/dist/{layout-7QXCNOVS.js → layout-HBWT2G23.js} +3 -3
  168. package/dist/layout-KPQWJNAG.js +14 -0
  169. package/dist/layout-OL2XFJXA.js +17 -0
  170. package/dist/layout-WCAIKGZG.js +19 -0
  171. package/dist/layout-WSMPBQ4Q.js +17 -0
  172. package/dist/layout-ZE5DRJWX.js +20 -0
  173. package/dist/{layout-search-55FU6HD3.js → layout-search-34DPZD43.js} +51 -35
  174. package/dist/legend-constants-P5EQWRQQ.js +49 -0
  175. package/dist/{palettes-PRJ2RI6D.js → palettes-FGTNFARW.js} +4 -4
  176. package/dist/{parser-KKTJ6M3Y.js → parser-275KP7JO.js} +8 -8
  177. package/dist/parser-27Z76SN3.js +22 -0
  178. package/dist/parser-3CODK6RG.js +15 -0
  179. package/dist/{parser-EH5VE7ZN.js → parser-3KIGEEJM.js} +6 -6
  180. package/dist/parser-3VSWEKBF.js +15 -0
  181. package/dist/parser-4E4I3GNT.js +13 -0
  182. package/dist/parser-5FGJSQNS.js +12 -0
  183. package/dist/parser-5HQXCNOS.js +12 -0
  184. package/dist/parser-5QPFOB5F.js +12 -0
  185. package/dist/parser-6B6SSZT7.js +11 -0
  186. package/dist/parser-6PPHAXXH.js +14 -0
  187. package/dist/parser-7JHWEWXM.js +13 -0
  188. package/dist/{parser-5PDYJGWA.js → parser-7JVIDLLR.js} +7 -7
  189. package/dist/parser-CKA3QMAG.js +18 -0
  190. package/dist/parser-CRKLXGW7.js +13 -0
  191. package/dist/parser-EXNBDNGY.js +11 -0
  192. package/dist/parser-FF4BMRSB.js +16 -0
  193. package/dist/parser-FOOFEJQU.js +13 -0
  194. package/dist/parser-G26MTBFS.js +11 -0
  195. package/dist/parser-GKP2MHHL.js +11 -0
  196. package/dist/parser-GN2MM5CC.js +11 -0
  197. package/dist/parser-IKWK2ZU3.js +18 -0
  198. package/dist/parser-IVGHXLZP.js +14 -0
  199. package/dist/parser-NNIL3HXU.js +11 -0
  200. package/dist/parser-RNLTBIJ6.js +19 -0
  201. package/dist/parser-UWRX52PC.js +16 -0
  202. package/dist/parser-VOERD6XR.js +14 -0
  203. package/dist/parser-XNKJCMMA.js +13 -0
  204. package/dist/parser-XVPTRWZ4.js +15 -0
  205. package/dist/parser-YSLNDFLV.js +22 -0
  206. package/dist/parser-ZGNXYFPS.js +15 -0
  207. package/dist/parser-ZQDQTB4X.js +20 -0
  208. package/dist/pert.d.ts +4 -2
  209. package/dist/registry-CaSw0PSH.d.ts +350 -0
  210. package/dist/renderer-2C6DJRYN.js +24 -0
  211. package/dist/renderer-5MPN7CXZ.js +19 -0
  212. package/dist/renderer-6EN5XXJZ.js +27 -0
  213. package/dist/renderer-6WRYVM5R.js +24 -0
  214. package/dist/renderer-7NQSTQMQ.js +16 -0
  215. package/dist/renderer-7ZNVOVFG.js +16 -0
  216. package/dist/{renderer-KQB7UGDS.js → renderer-AK2WO4EI.js} +7 -6
  217. package/dist/renderer-COLQFSFV.js +26 -0
  218. package/dist/renderer-CWEFGEIC.js +36 -0
  219. package/dist/renderer-D3BRNOMV.js +29 -0
  220. package/dist/renderer-HIFQVEJA.js +22 -0
  221. package/dist/renderer-JCZG6AYU.js +28 -0
  222. package/dist/{renderer-6RKQPNJI.js → renderer-JTCX6PCG.js} +13 -13
  223. package/dist/renderer-JWGQSTMR.js +37 -0
  224. package/dist/{renderer-3YPZHMOU.js → renderer-K7XLVPH5.js} +6 -6
  225. package/dist/renderer-KARQF3F3.js +22 -0
  226. package/dist/renderer-LVZAHRP6.js +34 -0
  227. package/dist/{renderer-QXGN5H3A.js → renderer-NE5W7CQP.js} +8 -8
  228. package/dist/renderer-QD2SJF2I.js +34 -0
  229. package/dist/renderer-RLMOTXZ6.js +37 -0
  230. package/dist/renderer-SQ54MDSA.js +26 -0
  231. package/dist/{renderer-UV6MI64M.js → renderer-TYHGXAVT.js} +7 -6
  232. package/dist/renderer-UKXW2QPE.js +23 -0
  233. package/dist/renderer-UPF7NRTI.js +28 -0
  234. package/dist/renderer-VMH6L6CP.js +24 -0
  235. package/dist/{renderer-GHPZMFU2.js → renderer-WCWI4I6A.js} +5 -5
  236. package/dist/renderer-WFSUBKUL.js +25 -0
  237. package/dist/renderer-WNFXYYGL.js +21 -0
  238. package/dist/{renderer-RGIYOTKJ.js → renderer-XTXSOK3L.js} +14 -14
  239. package/dist/renderer-YUKPS27O.js +24 -0
  240. package/dist/renderer-YUXGXGSW.js +27 -0
  241. package/dist/renderer-ZBTEX2JK.js +16 -0
  242. package/dist/renderer-radial-WF6VOUOD.js +21 -0
  243. package/dist/{resolver-EMTGNR3D.js → resolver-WFKZYBJ2.js} +4 -4
  244. package/dist/state-parser-L7DHZIQO.js +19 -0
  245. package/dist/state-renderer-TFEUOP4H.js +38 -0
  246. package/dist/{themes-32xj5ZTW.d.ts → themes-tbBkIVsn.d.ts} +2 -349
  247. package/docs/ai-integration.md +74 -77
  248. package/docs/language-reference.md +329 -290
  249. package/fonts/Inter-Bold.woff2 +0 -0
  250. package/fonts/Inter-Regular.woff2 +0 -0
  251. package/gallery/fixtures/boxes-and-lines-diverging.dgmo +1 -2
  252. package/gallery/fixtures/boxes-and-lines.dgmo +1 -1
  253. package/gallery/fixtures/clock.dgmo +1 -1
  254. package/gallery/fixtures/event-line.dgmo +1 -1
  255. package/gallery/fixtures/gantt-full.dgmo +1 -1
  256. package/gallery/fixtures/gantt-sprints.dgmo +9 -9
  257. package/gallery/fixtures/gantt.dgmo +1 -1
  258. package/gallery/fixtures/legacy-syntax-backcompat.dgmo +16 -0
  259. package/gallery/fixtures/state-tags.dgmo +40 -0
  260. package/gallery/fixtures/swimlane.dgmo +1 -1
  261. package/gallery/fixtures/timeline-intraday.dgmo +1 -1
  262. package/package.json +5 -1
  263. package/dist/analyzer-BJ54GIFB.js +0 -15
  264. package/dist/calculator-LDYQCDDY.js +0 -11
  265. package/dist/charts-d3-7E4B4IMW.js +0 -26
  266. package/dist/dgmo-router-Y2VEX46B.js +0 -86
  267. package/dist/dimensions-F7B5C4BJ.js +0 -22
  268. package/dist/flowchart-parser-MY53QWTZ.js +0 -21
  269. package/dist/layout-46366KBT.js +0 -10
  270. package/dist/layout-46N4JJYK.js +0 -17
  271. package/dist/layout-4DIUOX2T.js +0 -14
  272. package/dist/layout-AM2JWW3X.js +0 -15
  273. package/dist/layout-CBCLPMSG.js +0 -15
  274. package/dist/layout-EE6GE46Y.js +0 -17
  275. package/dist/layout-G23F7LDH.js +0 -9
  276. package/dist/layout-HYZPWAK5.js +0 -18
  277. package/dist/layout-MUPRALE5.js +0 -14
  278. package/dist/layout-YVTNOTN4.js +0 -20
  279. package/dist/layout-ZDOSXL5G.js +0 -19
  280. package/dist/parser-2Q2T4C3B.js +0 -22
  281. package/dist/parser-3A42DZ72.js +0 -11
  282. package/dist/parser-4RFTKAQX.js +0 -15
  283. package/dist/parser-57ILIFZ2.js +0 -20
  284. package/dist/parser-5A2UWU6B.js +0 -11
  285. package/dist/parser-6BJEXUFX.js +0 -13
  286. package/dist/parser-6ZKABF5S.js +0 -22
  287. package/dist/parser-AIMHGJRR.js +0 -19
  288. package/dist/parser-AZJ25OKK.js +0 -13
  289. package/dist/parser-B77S5SZM.js +0 -11
  290. package/dist/parser-BEPSWJAD.js +0 -11
  291. package/dist/parser-BKI42XBQ.js +0 -16
  292. package/dist/parser-C3D7MVXY.js +0 -11
  293. package/dist/parser-CDG7CHV5.js +0 -14
  294. package/dist/parser-CZOJ7XQ6.js +0 -15
  295. package/dist/parser-E2RL6JYF.js +0 -18
  296. package/dist/parser-FQ6GZFMR.js +0 -13
  297. package/dist/parser-GKLZKEIK.js +0 -13
  298. package/dist/parser-H6ABKHZZ.js +0 -12
  299. package/dist/parser-I6GGFKOQ.js +0 -12
  300. package/dist/parser-JA7JQ7NF.js +0 -15
  301. package/dist/parser-OK22AC6Y.js +0 -14
  302. package/dist/parser-OK2ILHRT.js +0 -16
  303. package/dist/parser-OUTPNJWC.js +0 -11
  304. package/dist/parser-PORDUX5E.js +0 -15
  305. package/dist/parser-SRVFR7PM.js +0 -13
  306. package/dist/parser-UKFFZCFJ.js +0 -14
  307. package/dist/parser-UMWPLORP.js +0 -18
  308. package/dist/parser-Z4TZV2CB.js +0 -12
  309. package/dist/renderer-2AUFT3E2.js +0 -24
  310. package/dist/renderer-2HTNBIF2.js +0 -34
  311. package/dist/renderer-3K3IB7D5.js +0 -22
  312. package/dist/renderer-3YNIWF5I.js +0 -16
  313. package/dist/renderer-4WR6WMVF.js +0 -26
  314. package/dist/renderer-66MERVQ2.js +0 -24
  315. package/dist/renderer-ARMJBP6C.js +0 -28
  316. package/dist/renderer-CO2DW7S7.js +0 -37
  317. package/dist/renderer-EDJ2O4S5.js +0 -34
  318. package/dist/renderer-F7U3MFCV.js +0 -22
  319. package/dist/renderer-GD2COXVL.js +0 -16
  320. package/dist/renderer-GQIESYEM.js +0 -25
  321. package/dist/renderer-HCKJDFXD.js +0 -37
  322. package/dist/renderer-HYGHO4SJ.js +0 -28
  323. package/dist/renderer-JC3RDUT7.js +0 -23
  324. package/dist/renderer-NKJ24TEA.js +0 -19
  325. package/dist/renderer-OYO67VZK.js +0 -26
  326. package/dist/renderer-QIWVHWZO.js +0 -15
  327. package/dist/renderer-QRWACQRI.js +0 -21
  328. package/dist/renderer-QXPP4TA2.js +0 -27
  329. package/dist/renderer-RHT4MHFU.js +0 -24
  330. package/dist/renderer-RYR3TJ46.js +0 -36
  331. package/dist/renderer-SRKDNDFB.js +0 -27
  332. package/dist/renderer-TGTUABCI.js +0 -24
  333. package/dist/renderer-TXJFKPOG.js +0 -29
  334. package/dist/renderer-radial-FWABAZHB.js +0 -21
  335. package/dist/state-parser-6T6CNMPX.js +0 -18
  336. package/dist/state-renderer-AWZ3ECAX.js +0 -34
@@ -5,6 +5,9 @@ import {
5
5
  import {
6
6
  wrapDescriptionLines
7
7
  } from "./chunk-BMR4CIEO.js";
8
+ import {
9
+ FONT_FAMILY
10
+ } from "./chunk-6KFWC4CO.js";
8
11
  import {
9
12
  DAY_MS,
10
13
  applyOrdinalTemplate,
@@ -20,16 +23,14 @@ import {
20
23
  splitClockSeconds
21
24
  } from "./chunk-OQKP2X3D.js";
22
25
  import {
23
- FONT_FAMILY
24
- } from "./chunk-6KFWC4CO.js";
25
- import {
26
+ contrastText,
26
27
  getSeriesColors,
27
28
  mix,
28
29
  themeBaseBg
29
- } from "./chunk-P6T66CCZ.js";
30
+ } from "./chunk-JYDMBWRP.js";
30
31
  import {
31
32
  resolveColor
32
- } from "./chunk-TLVIHFRO.js";
33
+ } from "./chunk-ZKPPI6BF.js";
33
34
 
34
35
  // src/countdown/renderer.ts
35
36
  import * as d3Selection from "d3-selection";
@@ -42,8 +43,10 @@ function bakedHero(parsed, now) {
42
43
  if (parsed.expired !== null) return parsed.expired;
43
44
  const elapsed = -remaining;
44
45
  if (elapsed <= 0) return "Now!";
45
- if (parsed.units === "compound" || parsed.units === "human")
46
- return `${formatCompound(resolved, now, 2, tz)} ago`;
46
+ if (parsed.units === "compound" || parsed.units === "human") {
47
+ const [a, b] = parsed.hasTime ? [resolved, now] : [dayStart(resolved, tz), dayStart(now, tz)];
48
+ return `${formatCompound(a, b, 2, tz)} ago`;
49
+ }
47
50
  const bu = parsed.units === "full" || parsed.units === "clock" ? "days" : parsed.units;
48
51
  return `${formatCount(elapsed, { units: bu, round: parsed.round, fields: parsed.fields })} ago`;
49
52
  }
@@ -103,7 +106,7 @@ var keyOf = (ms) => {
103
106
  const d = new Date(ms);
104
107
  return d.getFullYear() * 1e4 + d.getMonth() * 100 + d.getDate();
105
108
  };
106
- function bandColors(palette, accent, muted, faint) {
109
+ function bandColors(palette, accent, muted, faint, isDark, fillMode) {
107
110
  const blue = resolveColor("blue", palette) ?? mix(palette.text, palette.bg, 45);
108
111
  const collides = accent.toLowerCase() === blue.toLowerCase();
109
112
  const now = collides ? resolveColor("teal", palette) ?? resolveColor("cyan", palette) ?? mix(palette.text, palette.bg, 55) : blue;
@@ -118,7 +121,11 @@ function bandColors(palette, accent, muted, faint) {
118
121
  event: accent,
119
122
  midSoft: mix(mid, palette.bg, 24),
120
123
  inert: mix(palette.text, palette.bg, 7),
121
- inertBorder: mix(palette.text, palette.bg, 22)
124
+ inertBorder: mix(palette.text, palette.bg, 22),
125
+ fillMode,
126
+ baseBg: themeBaseBg(palette, isDark),
127
+ onLight: palette.textOnFillLight,
128
+ onDark: palette.textOnFillDark
122
129
  };
123
130
  }
124
131
  function roleStyle(C, role) {
@@ -128,15 +135,26 @@ function roleStyle(C, role) {
128
135
  case "future":
129
136
  return { fill: C.inert, stroke: C.inertBorder, text: C.muted };
130
137
  case "today":
131
- return { fill: C.now, stroke: C.now, text: C.bg };
138
+ return chipStyle(C, C.now);
132
139
  case "event":
133
- return { fill: C.event, stroke: C.event, text: C.bg };
140
+ return chipStyle(C, C.event);
134
141
  }
135
142
  }
143
+ function chipStyle(C, color) {
144
+ if (C.fillMode === "outline")
145
+ return { fill: C.baseBg, stroke: color, text: color };
146
+ if (C.fillMode === "solid")
147
+ return {
148
+ fill: color,
149
+ stroke: color,
150
+ text: contrastText(color, C.onLight, C.onDark)
151
+ };
152
+ return { fill: color, stroke: color, text: C.bg };
153
+ }
136
154
  function gradStyle(C, frac) {
137
155
  const t = Math.max(0, Math.min(1, frac));
138
156
  const f = mix(C.event, C.now, Math.round(t * 100));
139
- return { fill: f, stroke: f, text: C.bg };
157
+ return chipStyle(C, f);
140
158
  }
141
159
  function aText(svg, x, y, size, fill, weight, anchor, txt, extra) {
142
160
  const t = svg.append("text").attr("x", x).attr("y", y).attr("text-anchor", anchor).attr("font-size", size).attr("font-weight", weight).attr("fill", fill).attr("font-family", FONT_FAMILY).attr("font-variant-numeric", "tabular-nums").text(txt);
@@ -167,18 +185,20 @@ function haloRect(svg, x, y, w, h, rx, C) {
167
185
  function pickBand(nowMs, resolvedMs, hasTime) {
168
186
  const days = dayDelta(nowMs, resolvedMs);
169
187
  if (hasTime && days <= 0) return "clock";
170
- if (days > 3 * 365) return "years";
171
- if (days > 365) return "year";
172
- if (days > 92) return "months";
173
- if (days > 18) return "monthgrid";
174
- if (days >= 1) return "weekstrip";
175
188
  if (days === 0) return "today";
176
- return "after";
189
+ const mag = Math.abs(days);
190
+ if (mag > 3 * 365) return "years";
191
+ if (mag > 365) return "year";
192
+ if (mag > 92) return "months";
193
+ if (mag > 7) return "monthgrid";
194
+ return "weekstrip";
177
195
  }
178
196
  function monthSpan(nowMs, resolvedMs) {
179
197
  const n = new Date(nowMs);
180
198
  const t = new Date(resolvedMs);
181
- return (t.getFullYear() - n.getFullYear()) * 12 + (t.getMonth() - n.getMonth()) + 1;
199
+ return Math.abs(
200
+ (t.getFullYear() - n.getFullYear()) * 12 + (t.getMonth() - n.getMonth())
201
+ ) + 1;
182
202
  }
183
203
  var MONTH_TARGET_PX = 200;
184
204
  function monthGridLayout(nowMs, resolvedMs, contentW) {
@@ -189,21 +209,24 @@ function monthGridLayout(nowMs, resolvedMs, contentW) {
189
209
  const padBefore = Math.floor((shown - realSpan) / 2);
190
210
  const nowMk = now.getFullYear() * 12 + now.getMonth();
191
211
  const evMk = ev.getFullYear() * 12 + ev.getMonth();
212
+ const loMk = Math.min(nowMk, evMk);
213
+ const hiMk = Math.max(nowMk, evMk);
214
+ const startMk = loMk - padBefore;
192
215
  const months = [];
193
216
  const dim = [];
194
217
  for (let i = 0; i < shown; i++) {
195
- const d = new Date(now.getFullYear(), now.getMonth() - padBefore + i, 1);
218
+ const d = new Date(Math.floor(startMk / 12), startMk % 12 + i, 1);
196
219
  const mk = d.getFullYear() * 12 + d.getMonth();
197
220
  months.push(d);
198
- dim.push(mk < nowMk || mk > evMk);
221
+ dim.push(mk < loMk || mk > hiMk);
199
222
  }
200
223
  return { months, dim };
201
224
  }
202
225
  function yearsLayout(nowMs, resolvedMs) {
203
226
  const y0 = new Date(nowMs).getFullYear();
204
227
  const y1 = new Date(resolvedMs).getFullYear();
205
- const d0 = Math.floor(y0 / 10) * 10;
206
- const d1 = Math.floor(y1 / 10) * 10;
228
+ const d0 = Math.floor(Math.min(y0, y1) / 10) * 10;
229
+ const d1 = Math.floor(Math.max(y0, y1) / 10) * 10;
207
230
  return { d0, d1, rows: (d1 - d0) / 10 + 1 };
208
231
  }
209
232
  function bandHeightFor(kind, nowMs, resolvedMs, contentW) {
@@ -225,7 +248,9 @@ function bandHeightFor(kind, nowMs, resolvedMs, contentW) {
225
248
  return total;
226
249
  }
227
250
  case "year": {
228
- const R = new Date(resolvedMs).getFullYear() - new Date(nowMs).getFullYear() + 1;
251
+ const R = Math.abs(
252
+ new Date(resolvedMs).getFullYear() - new Date(nowMs).getFullYear()
253
+ ) + 1;
229
254
  const yearW = 66;
230
255
  const gap = 8;
231
256
  const cellW = (contentW - yearW - 11 * gap) / 12;
@@ -251,14 +276,13 @@ function bandHeightFor(kind, nowMs, resolvedMs, contentW) {
251
276
  return 26 + 6 * cellH + 8;
252
277
  }
253
278
  case "weekstrip": {
254
- const n = Math.max(7, dayDelta(nowMs, resolvedMs) + 1);
279
+ const n = Math.max(7, Math.abs(dayDelta(nowMs, resolvedMs)) + 1);
255
280
  const cw = (contentW - 10 * (n - 1)) / n;
256
281
  return clamp(cw * 1.5, 116, 170);
257
282
  }
258
283
  case "clock":
259
284
  return clamp(contentW * 0.26, 150, 205);
260
285
  case "today":
261
- case "after":
262
286
  return clamp(contentW * 0.22, 125, 170);
263
287
  }
264
288
  }
@@ -296,7 +320,7 @@ function vizYears(svg, g, nowMs, resolvedMs, C) {
296
320
  const before = yr < nowY;
297
321
  const isNow = yr === nowY;
298
322
  const isEv = yr === evY;
299
- const between = yr > nowY && yr < evY;
323
+ const between = (yr - nowY) * (yr - evY) < 0;
300
324
  const st = isEv ? roleStyle(C, "event") : isNow ? roleStyle(C, "today") : between ? gradStyle(C, (yr - nowY) / (evY - nowY)) : roleStyle(C, before ? "past" : "future");
301
325
  const x = g.left + labW + i * (cellW + gap);
302
326
  aRect(svg, x, ry, cellW, cellH, rx, st.fill, st.stroke, 1);
@@ -320,8 +344,8 @@ function vizYears(svg, g, nowMs, resolvedMs, C) {
320
344
  function vizYear(svg, g, nowMs, resolvedMs, C) {
321
345
  const now = new Date(nowMs);
322
346
  const ev = new Date(resolvedMs);
323
- const y0 = now.getFullYear();
324
- const y1 = ev.getFullYear();
347
+ const y0 = Math.min(now.getFullYear(), ev.getFullYear());
348
+ const y1 = Math.max(now.getFullYear(), ev.getFullYear());
325
349
  const years = [];
326
350
  for (let y = y0; y <= y1; y++) years.push(y);
327
351
  const R = years.length;
@@ -351,10 +375,11 @@ function vizYear(svg, g, nowMs, resolvedMs, C) {
351
375
  { "dominant-baseline": "central" }
352
376
  );
353
377
  for (let m = 0; m < 12; m++) {
354
- const before = yr < nowY || yr === nowY && m < nowM;
378
+ const mOrd = yr * 12 + m;
379
+ const before = mOrd < nowOrd;
355
380
  const isNow = yr === nowY && m === nowM;
356
381
  const isEv = yr === evY && m === evM;
357
- const between = (yr > nowY || yr === nowY && m > nowM) && (yr < evY || yr === evY && m < evM);
382
+ const between = (mOrd - nowOrd) * (mOrd - evOrd) < 0;
358
383
  const anchor = isEv || isNow;
359
384
  const st = isEv ? roleStyle(C, "event") : isNow ? roleStyle(C, "today") : between ? gradStyle(C, (yr * 12 + m - nowOrd) / (evOrd - nowOrd)) : roleStyle(C, before ? "past" : "future");
360
385
  const x = g.left + yearW + m * (cellW + gap);
@@ -418,19 +443,22 @@ function vizMonths(svg, g, nowMs, resolvedMs, C) {
418
443
  const cellH = (g.height - rowGap * (rows - 1)) / rows;
419
444
  const nowMk = now.getFullYear() * 12 + now.getMonth();
420
445
  const evMk = ev.getFullYear() * 12 + ev.getMonth();
446
+ const loMk = Math.min(nowMk, evMk);
447
+ const hiMk = Math.max(nowMk, evMk);
448
+ const startMk = loMk - padBefore;
421
449
  for (let i = 0; i < shown; i++) {
422
- const d = new Date(now.getFullYear(), now.getMonth() - padBefore + i, 1);
450
+ const d = new Date(Math.floor(startMk / 12), startMk % 12 + i, 1);
423
451
  const mk = d.getFullYear() * 12 + d.getMonth();
424
452
  const isNow = mk === nowMk;
425
453
  const isEv = mk === evMk;
426
- const isContext = mk < nowMk || mk > evMk;
454
+ const isContext = mk < loMk || mk > hiMk;
427
455
  const anchor = isNow || isEv;
428
456
  const col = i % perRow;
429
457
  const row = Math.floor(i / perRow);
430
458
  const x = g.left + col * (cellW + gap);
431
459
  const y = g.top + row * (cellH + rowGap);
432
460
  const mt = isContext ? svg.append("g").attr("opacity", 0.42) : svg;
433
- const st = isEv ? roleStyle(C, "event") : isNow ? roleStyle(C, "today") : mk > nowMk && mk < evMk ? gradStyle(C, (mk - nowMk) / (evMk - nowMk)) : roleStyle(C, mk < nowMk ? "past" : "future");
461
+ const st = isEv ? roleStyle(C, "event") : isNow ? roleStyle(C, "today") : (mk - nowMk) * (mk - evMk) < 0 ? gradStyle(C, (mk - nowMk) / (evMk - nowMk)) : roleStyle(C, mk < nowMk ? "past" : "future");
434
462
  const rxM = Math.min(12, cellH * 0.14);
435
463
  aRect(mt, x, y, cellW, cellH, rxM, st.fill, st.stroke, 1.25);
436
464
  if (isEv) haloRect(mt, x, y, cellW, cellH, rxM, C);
@@ -529,7 +557,7 @@ function vizMonthGrid(svg, g, nowMs, resolvedMs, C) {
529
557
  const cy = gy + wk * cellH;
530
558
  const isEvent = dk === evKey;
531
559
  const isToday = dk === todayKey;
532
- const between = dk > todayKey && dk < evKey;
560
+ const between = (dk - todayKey) * (dk - evKey) < 0;
533
561
  const anchor = isEvent || isToday;
534
562
  const dtMs = new Date(m.getFullYear(), m.getMonth(), day).getTime();
535
563
  const st = isEvent ? roleStyle(C, "event") : isToday ? roleStyle(C, "today") : between ? gradStyle(C, dayDelta(nowMs, dtMs) / dayDelta(nowMs, resolvedMs)) : roleStyle(C, dk < todayKey ? "past" : "future");
@@ -568,8 +596,7 @@ function vizMonthGrid(svg, g, nowMs, resolvedMs, C) {
568
596
  });
569
597
  }
570
598
  function vizWeekStrip(svg, g, nowMs, resolvedMs, C) {
571
- const now = new Date(nowMs);
572
- const nReal = dayDelta(nowMs, resolvedMs) + 1;
599
+ const nReal = Math.abs(dayDelta(nowMs, resolvedMs)) + 1;
573
600
  const n = Math.max(7, nReal);
574
601
  const padBefore = Math.floor((n - nReal) / 2);
575
602
  const gap = n <= 7 ? 14 : n <= 12 ? 10 : 7;
@@ -580,17 +607,20 @@ function vizWeekStrip(svg, g, nowMs, resolvedMs, C) {
580
607
  const showTag = cw >= 44;
581
608
  const nowOrd = DAY_START(nowMs);
582
609
  const evOrd = DAY_START(resolvedMs);
610
+ const loOrd = Math.min(nowOrd, evOrd);
611
+ const hiOrd = Math.max(nowOrd, evOrd);
612
+ const first = new Date(Math.min(nowMs, resolvedMs));
583
613
  for (let i = 0; i < n; i++) {
584
614
  const dt = new Date(
585
- now.getFullYear(),
586
- now.getMonth(),
587
- now.getDate() + i - padBefore
615
+ first.getFullYear(),
616
+ first.getMonth(),
617
+ first.getDate() + i - padBefore
588
618
  );
589
619
  const dtOrd = DAY_START(dt.getTime());
590
620
  const x = g.left + i * (cw + gap);
591
621
  const isToday = dtOrd === nowOrd;
592
622
  const isEvent = dtOrd === evOrd;
593
- const isContext = dtOrd < nowOrd || dtOrd > evOrd;
623
+ const isContext = dtOrd < loOrd || dtOrd > hiOrd;
594
624
  const st = isEvent ? roleStyle(C, "event") : isToday ? roleStyle(C, "today") : isContext ? roleStyle(C, dtOrd < nowOrd ? "past" : "future") : gradStyle(C, (dtOrd - nowOrd) / (evOrd - nowOrd));
595
625
  const ct = isContext ? svg.append("g").attr("opacity", 0.5) : svg;
596
626
  const sw = isToday || isEvent ? 2 : 1.25;
@@ -658,13 +688,14 @@ function vizToday(svg, g, resolvedMs, C) {
658
688
  }
659
689
  const w = Math.min(120, g.contentW * 0.16);
660
690
  const h = g.height * 0.52;
661
- aRect(svg, cx - w / 2, cy - h / 2, w, h, 18, C.event, C.event, 2);
691
+ const st = roleStyle(C, "event");
692
+ aRect(svg, cx - w / 2, cy - h / 2, w, h, 18, st.fill, st.stroke, 2);
662
693
  aText(
663
694
  svg,
664
695
  cx,
665
696
  cy - h * 0.14,
666
697
  14,
667
- C.bg,
698
+ st.text,
668
699
  700,
669
700
  "middle",
670
701
  MON_ABBR[ev.getMonth()].toUpperCase(),
@@ -675,7 +706,7 @@ function vizToday(svg, g, resolvedMs, C) {
675
706
  cx,
676
707
  cy + h * 0.22,
677
708
  Math.min(48, h * 0.4),
678
- C.bg,
709
+ st.text,
679
710
  800,
680
711
  "middle",
681
712
  String(ev.getDate())
@@ -692,75 +723,6 @@ function vizToday(svg, g, resolvedMs, C) {
692
723
  { "letter-spacing": "0.12em" }
693
724
  );
694
725
  }
695
- function vizAfter(svg, g, nowMs, resolvedMs, C) {
696
- const ev = new Date(resolvedMs);
697
- const elapsed = dayDelta(resolvedMs, nowMs);
698
- const n = elapsed + 1;
699
- const gap = 10;
700
- const cw = (g.contentW - gap * (n - 1)) / n;
701
- const ch = Math.min(cw * 1.1, g.height * 0.62);
702
- const top = g.top + (g.height - ch) / 2 - 8;
703
- for (let i = 0; i < n; i++) {
704
- const dt = new Date(ev);
705
- dt.setDate(ev.getDate() + i);
706
- const x = g.left + i * (cw + gap);
707
- const isEvent = i === 0;
708
- const isToday = i === n - 1;
709
- const st = roleStyle(C, isEvent ? "event" : "past");
710
- const fill = st.fill;
711
- const stroke = st.stroke;
712
- const tcol = st.text;
713
- const sw = isEvent ? 2.5 : 1;
714
- aRect(svg, x, top, cw, ch, 12, fill, stroke, sw);
715
- if (isEvent) haloRect(svg, x, top, cw, ch, 12, C);
716
- aText(
717
- svg,
718
- x + cw / 2,
719
- top + ch * 0.46,
720
- Math.min(34, cw * 0.34),
721
- tcol,
722
- isEvent ? 750 : 500,
723
- "middle",
724
- String(dt.getDate())
725
- );
726
- aText(
727
- svg,
728
- x + cw / 2,
729
- top + ch * 0.72,
730
- 11,
731
- tcol,
732
- 600,
733
- "middle",
734
- MON_ABBR[dt.getMonth()]
735
- );
736
- if (isEvent)
737
- aText(
738
- svg,
739
- x + cw / 2,
740
- top - 8,
741
- 11,
742
- C.event,
743
- 700,
744
- "middle",
745
- "IT HAPPENED",
746
- { "letter-spacing": "0.05em" }
747
- );
748
- if (isToday)
749
- aText(svg, x + cw / 2, top - 8, 11, C.now, 700, "middle", "TODAY", {
750
- "letter-spacing": "0.05em"
751
- });
752
- }
753
- aText(
754
- svg,
755
- g.left,
756
- top + ch + 28,
757
- 14,
758
- C.muted,
759
- 400,
760
- "start",
761
- `${elapsed} day${elapsed === 1 ? "" : "s"} ago \u2014 the day has passed`
762
- );
763
- }
764
726
  function polar(cx, cy, r, deg) {
765
727
  const a = (deg - 90) * Math.PI / 180;
766
728
  return [cx + r * Math.cos(a), cy + r * Math.sin(a)];
@@ -847,8 +809,6 @@ function drawBand(svg, kind, g, nowMs, resolvedMs, C) {
847
809
  return vizWeekStrip(svg, g, nowMs, resolvedMs, C);
848
810
  case "today":
849
811
  return vizToday(svg, g, resolvedMs, C);
850
- case "after":
851
- return vizAfter(svg, g, nowMs, resolvedMs, C);
852
812
  case "clock":
853
813
  return vizClock(svg, g, nowMs, resolvedMs, C);
854
814
  }
@@ -1015,7 +975,14 @@ function renderCountdown(container, parsed, palette, isDark, exportDims) {
1015
975
  );
1016
976
  svg.attr("height", bannerH).attr("viewBox", `0 0 ${width} ${bannerH}`);
1017
977
  bgRect.attr("height", bannerH);
1018
- const bandC = bandColors(palette, accent, muted, faint);
978
+ const bandC = bandColors(
979
+ palette,
980
+ accent,
981
+ muted,
982
+ faint,
983
+ isDark,
984
+ parsed.fillMode
985
+ );
1019
986
  if (hasBand && resolved !== null) {
1020
987
  drawBand(
1021
988
  svg,
@@ -1063,4 +1030,4 @@ export {
1063
1030
  renderCountdown,
1064
1031
  renderCountdownForExport
1065
1032
  };
1066
- //# sourceMappingURL=chunk-ND76YJCN.js.map
1033
+ //# sourceMappingURL=chunk-PIXZTCKH.js.map
@@ -11,10 +11,10 @@ import {
11
11
  stripDefaultModifier,
12
12
  tagAttrKey,
13
13
  validateTagGroupNames
14
- } from "./chunk-467TVMQL.js";
14
+ } from "./chunk-CMVZWP32.js";
15
15
  import {
16
16
  parseInArrowLabel
17
- } from "./chunk-FFUN5D66.js";
17
+ } from "./chunk-WF64MW5G.js";
18
18
  import {
19
19
  normalizeName
20
20
  } from "./chunk-NOTA6TEI.js";
@@ -27,16 +27,16 @@ import {
27
27
  splitNameAndMeta,
28
28
  warnUnknownMetaKeys,
29
29
  withTagAliases
30
- } from "./chunk-LV4BETUU.js";
30
+ } from "./chunk-YJVA3QUU.js";
31
31
  import {
32
32
  formatDgmoError,
33
33
  makeDgmoError,
34
34
  makeFail,
35
35
  suggest
36
- } from "./chunk-CXK4DZH3.js";
36
+ } from "./chunk-4W2PE66Q.js";
37
37
 
38
38
  // src/c4/parser.ts
39
- var CONTAINER_RE = /^\[([^\]]+)\]$/;
39
+ var CONTAINER_RE = /^\[([^\]]+)\](?:\s+(collapsed)|\s+collapsed:\s*(\S+))?$/;
40
40
  var ELEMENT_RE = /^(person|system|container|component)\s+(.+)$/i;
41
41
  var IS_A_RE = /\s+is\s+a(?:n)?\s+(\w+)\s*$/i;
42
42
  var C4_IS_A_RE = /^([^:]+?)\s+is\s+an?\s+(person|system|container|component|external|database)\b(.*)$/i;
@@ -65,8 +65,12 @@ var VALID_SHAPES = /* @__PURE__ */ new Set([
65
65
  var KNOWN_C4_OPTIONS = /* @__PURE__ */ new Set(["layout", "active-tag"]);
66
66
  var KNOWN_C4_BOOLEANS = /* @__PURE__ */ new Set([
67
67
  "direction-tb",
68
- "solid-fill",
69
- "no-title"
68
+ "direction-lr",
69
+ "fill-tint",
70
+ "fill-solid",
71
+ "fill-outline",
72
+ "no-title",
73
+ "no-legend"
70
74
  ]);
71
75
  var ALL_CHART_TYPES = [
72
76
  "c4",
@@ -150,6 +154,7 @@ function parseC4(content, palette) {
150
154
  title: null,
151
155
  titleLineNumber: null,
152
156
  options,
157
+ direction: "TB",
153
158
  tagGroups: [],
154
159
  elements: [],
155
160
  relationships: [],
@@ -237,7 +242,12 @@ function parseC4(content, palette) {
237
242
  }
238
243
  if (!contentStarted && !currentTagGroup && measureIndent(line) === 0) {
239
244
  if (KNOWN_C4_BOOLEANS.has(trimmed.toLowerCase())) {
240
- options[trimmed.toLowerCase()] = "on";
245
+ const boolKey = trimmed.toLowerCase();
246
+ if (boolKey === "direction-lr" || boolKey === "direction-tb") {
247
+ delete options["direction-lr"];
248
+ delete options["direction-tb"];
249
+ }
250
+ options[boolKey] = "on";
241
251
  continue;
242
252
  }
243
253
  const optMatch = trimmed.match(OPTION_NOCOLON_RE);
@@ -367,11 +377,13 @@ function parseC4(content, palette) {
367
377
  const containerMatch = trimmed.match(CONTAINER_RE);
368
378
  if (containerMatch) {
369
379
  const groupName = containerMatch[1].trim();
380
+ const groupCollapsed = containerMatch[2] !== void 0 || containerMatch[3]?.toLowerCase() === "true";
370
381
  const parentEntry = findParentElement(indent, stack);
371
382
  if (parentEntry) {
372
383
  const group = {
373
384
  name: groupName,
374
385
  children: [],
386
+ ...groupCollapsed && { collapsed: true },
375
387
  lineNumber
376
388
  };
377
389
  parentEntry.element.groups.push(group);
@@ -709,6 +721,7 @@ function parseC4(content, palette) {
709
721
  result.tagGroups,
710
722
  (line, msg) => pushError(line, msg, "warning")
711
723
  );
724
+ result.direction = options["direction-lr"] ? "LR" : "TB";
712
725
  return result;
713
726
  }
714
727
  function findParentElement(indent, stack) {
@@ -804,4 +817,4 @@ function validateDeploymentRefs(result, knownNames, pushWarning) {
804
817
  export {
805
818
  parseC4
806
819
  };
807
- //# sourceMappingURL=chunk-3LV2NCB6.js.map
820
+ //# sourceMappingURL=chunk-PKNNHU7H.js.map
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  renderIntegratedLegend
3
- } from "./chunk-OU7HLO7I.js";
3
+ } from "./chunk-W5KMNC5U.js";
4
4
  import {
5
5
  getMaxLegendReservedHeight
6
- } from "./chunk-YAA6IID3.js";
6
+ } from "./chunk-774C2FF3.js";
7
7
  import {
8
8
  TITLE_FONT_SIZE,
9
9
  TITLE_FONT_WEIGHT,
@@ -13,21 +13,22 @@ import {
13
13
  FONT_FAMILY
14
14
  } from "./chunk-6KFWC4CO.js";
15
15
  import {
16
- LEGEND_GROUP_GAP
17
- } from "./chunk-QOOUC2J5.js";
16
+ isBlockNode
17
+ } from "./chunk-NR5HCAUD.js";
18
18
  import {
19
- measureText
20
- } from "./chunk-WCT3NYCV.js";
19
+ mix,
20
+ themeBaseBg
21
+ } from "./chunk-JYDMBWRP.js";
21
22
  import {
22
- isBlockNode
23
- } from "./chunk-NNAAJVBU.js";
23
+ LEGEND_GROUP_GAP
24
+ } from "./chunk-4RGZFA7H.js";
24
25
  import {
25
- mix
26
- } from "./chunk-P6T66CCZ.js";
26
+ measureText
27
+ } from "./chunk-4ASYQ347.js";
27
28
  import {
28
29
  resolveTagColor,
29
30
  tagAttrKey
30
- } from "./chunk-467TVMQL.js";
31
+ } from "./chunk-CMVZWP32.js";
31
32
 
32
33
  // src/block/renderer.ts
33
34
  import * as d3Selection from "d3-selection";
@@ -223,7 +224,8 @@ function renderBlock(container, parsed, palette, isDark, exportDims, options = {
223
224
  activeGroup,
224
225
  activeKey: activeGroup ? tagAttrKey(activeGroup) : null,
225
226
  neutral,
226
- solidFill: opts.solidFill,
227
+ fillMode: opts.fillMode,
228
+ isDark,
227
229
  onToggle: options.onToggle
228
230
  });
229
231
  if (legend) {
@@ -262,7 +264,7 @@ function clipLabel(s, maxWidth, fs) {
262
264
  }
263
265
  var clipCounter = 0;
264
266
  function drawItems(g, items, ctx, path = []) {
265
- const { palette, solidFill: solid } = ctx;
267
+ const { palette, fillMode } = ctx;
266
268
  for (const it of items) {
267
269
  if (it.type === "empty") {
268
270
  g.append("rect").attr("x", it.x).attr("y", it.y).attr("width", it.w).attr("height", it.h).attr("rx", 7).attr("fill", "none").attr("stroke", ctx.neutral).attr("stroke-width", 1).attr("stroke-dasharray", "3 4").attr("opacity", 0.7);
@@ -280,17 +282,17 @@ function drawItems(g, items, ctx, path = []) {
280
282
  if (v) cell.attr(`data-tag-${ctx.activeKey}`, v);
281
283
  }
282
284
  if (it.type === "collapsed") {
283
- const fill2 = color ? solid ? color : mix(color, palette.bg, 12) : palette.surface;
285
+ const fill2 = color ? fillMode === "solid" ? color : fillMode === "outline" ? themeBaseBg(palette, ctx.isDark) : mix(color, palette.bg, 12) : palette.surface;
284
286
  const cid = `dgmo-block-clip-${clipCounter++}`;
285
287
  cell.append("clipPath").attr("id", cid).append("rect").attr("x", it.x).attr("y", it.y).attr("width", it.w).attr("height", it.h).attr("rx", 10);
286
288
  cell.append("rect").attr("x", it.x).attr("y", it.y).attr("width", it.w).attr("height", it.h).attr("rx", 10).attr("fill", fill2).attr("stroke", stroke).attr("stroke-width", 1.5);
287
289
  cell.append("text").attr("x", it.x + it.w / 2).attr("y", it.y + it.h / 2 + 4).attr("text-anchor", "middle").attr("font-size", 12.5).attr("font-weight", 700).attr("fill", palette.text).text(clipLabel(it.label ?? "", it.w - 24, 12.5));
288
- cell.append("rect").attr("x", it.x).attr("y", it.y + it.h - BLOCK_BAR_H).attr("width", it.w).attr("height", BLOCK_BAR_H).attr("fill", solid && color ? palette.text : stroke).attr("clip-path", `url(#${cid})`);
290
+ cell.append("rect").attr("x", it.x).attr("y", it.y + it.h - BLOCK_BAR_H).attr("width", it.w).attr("height", BLOCK_BAR_H).attr("fill", fillMode === "solid" && color ? palette.text : stroke).attr("clip-path", `url(#${cid})`);
289
291
  bindToggle(cell, it, ctx, it.h);
290
292
  continue;
291
293
  }
292
294
  if (it.type === "container") {
293
- const fill2 = color ? solid ? color : mix(color, palette.bg, 7) : palette.surface;
295
+ const fill2 = color ? fillMode === "solid" ? color : fillMode === "outline" ? themeBaseBg(palette, ctx.isDark) : mix(color, palette.bg, 7) : palette.surface;
294
296
  cell.append("rect").attr("x", it.x).attr("y", it.y).attr("width", it.w).attr("height", it.h).attr("rx", 10).attr("fill", fill2).attr("stroke", stroke).attr("stroke-width", 1.5);
295
297
  const sizeMetric = Math.min(it.w, it.h * 2.5);
296
298
  const headerFs = Math.max(
@@ -305,7 +307,7 @@ function drawItems(g, items, ctx, path = []) {
305
307
  if (it.inner) drawItems(g, it.inner, ctx, itemPath);
306
308
  continue;
307
309
  }
308
- const fill = color ? solid ? mix(color, palette.bg, 80) : mix(color, palette.bg, 14) : palette.bg;
310
+ const fill = color ? fillMode === "solid" ? mix(color, palette.bg, 80) : fillMode === "outline" ? themeBaseBg(palette, ctx.isDark) : mix(color, palette.bg, 14) : palette.bg;
309
311
  cell.attr("data-leaf", "true");
310
312
  cell.append("rect").attr("x", it.x).attr("y", it.y).attr("width", it.w).attr("height", it.h).attr("rx", 8).attr("fill", fill).attr("stroke", stroke).attr("stroke-width", 1.25);
311
313
  cell.append("text").attr("x", it.x + it.w / 2).attr("y", it.y + it.h / 2 + 5).attr("text-anchor", "middle").attr("font-size", 13).attr("font-weight", 600).attr("fill", palette.text).text(clipLabel(it.label ?? "", it.w - 16, 13));
@@ -359,4 +361,4 @@ export {
359
361
  renderBlock,
360
362
  authoredCollapsedIds
361
363
  };
362
- //# sourceMappingURL=chunk-TK2VQQX2.js.map
364
+ //# sourceMappingURL=chunk-PT4SW76W.js.map
@@ -5,16 +5,16 @@ import {
5
5
  splitNameAndMeta,
6
6
  tryParseSharedOption,
7
7
  warnUnknownMetaKeys
8
- } from "./chunk-LV4BETUU.js";
8
+ } from "./chunk-YJVA3QUU.js";
9
9
  import {
10
10
  RECOGNIZED_COLOR_NAMES,
11
11
  resolveColor
12
- } from "./chunk-TLVIHFRO.js";
12
+ } from "./chunk-ZKPPI6BF.js";
13
13
  import {
14
14
  makeDgmoError,
15
15
  makeFail,
16
16
  suggest
17
- } from "./chunk-CXK4DZH3.js";
17
+ } from "./chunk-4W2PE66Q.js";
18
18
 
19
19
  // src/ring/parser.ts
20
20
  var MAX_LAYERS = 15;
@@ -165,4 +165,4 @@ function parseRing(content) {
165
165
  export {
166
166
  parseRing
167
167
  };
168
- //# sourceMappingURL=chunk-AE7II3E3.js.map
168
+ //# sourceMappingURL=chunk-PV2QO7QL.js.map