@diagrammo/dgmo 0.88.0 → 0.90.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 (230) hide show
  1. package/README.md +5 -3
  2. package/dist/advanced.d.ts +472 -22
  3. package/dist/advanced.js +401 -240
  4. package/dist/{analyzer-R5UBTRO2.js → analyzer-7ZGAZIE6.js} +2 -2
  5. package/dist/block.d.ts +1 -1
  6. package/dist/block.js +95 -72
  7. package/dist/{calculator-35YVW4QO.js → calculator-PX3JHKAS.js} +2 -2
  8. package/dist/{chart-meta-PbgpGwYo.d.ts → chart-meta-B_WTMP0y.d.ts} +1 -1
  9. package/dist/chart-meta.d.ts +2 -2
  10. package/dist/chart-meta.js +22 -21
  11. package/dist/{chart-types-Db_EGf1o.d.ts → chart-types-V2NcgN5O.d.ts} +5 -1
  12. package/dist/{charts-d3-3BZRSZV6.js → charts-d3-QW4ERNUE.js} +13 -12
  13. package/dist/{chunk-O6MMQQLF.js → chunk-2EDJPHXQ.js} +17 -17
  14. package/dist/{chunk-7WGCQE2E.js → chunk-2ZVLI6GQ.js} +1 -1
  15. package/dist/{chunk-JLETTWUJ.js → chunk-3BQCSQQJ.js} +57 -28
  16. package/dist/{chunk-MVCPO6LI.js → chunk-3HBR3YAN.js} +37 -27
  17. package/dist/chunk-3UR4F7FE.js +14 -0
  18. package/dist/{chunk-IDJGV6VM.js → chunk-4HG4PYHM.js} +209 -1
  19. package/dist/{chunk-YMG7JDEY.js → chunk-4IYJOXGS.js} +78 -31
  20. package/dist/{chunk-BOO24UMJ.js → chunk-4YO7VJTP.js} +1 -1
  21. package/dist/{chunk-AAMCXQPP.js → chunk-54YUDXGP.js} +6 -6
  22. package/dist/{chunk-UG2XG57E.js → chunk-5M52RPAS.js} +2 -2
  23. package/dist/{chunk-UNAP6O26.js → chunk-5M6PMV5Z.js} +14 -14
  24. package/dist/{chunk-BMUWF77V.js → chunk-5MDQMB6A.js} +4 -4
  25. package/dist/{chunk-WPL5PFXE.js → chunk-5TZPIKNV.js} +5 -5
  26. package/dist/{chunk-VPASQOR3.js → chunk-62VWZ3SE.js} +6 -5
  27. package/dist/{chunk-N4XHXBDQ.js → chunk-64KSPLU2.js} +6 -5
  28. package/dist/{chunk-VEPIAUSK.js → chunk-6BQSDF77.js} +1 -5
  29. package/dist/{chunk-LNO3ASX5.js → chunk-A5EE66RQ.js} +2 -2
  30. package/dist/{chunk-5KGM44TG.js → chunk-A5PUOHIS.js} +4 -4
  31. package/dist/{chunk-UNNJCSSQ.js → chunk-AAC3XQWV.js} +3 -3
  32. package/dist/{chunk-VJ2KROJ5.js → chunk-AHWA36O7.js} +1 -1
  33. package/dist/{chunk-FKZ2Y3Q5.js → chunk-C4W62JZO.js} +2 -2
  34. package/dist/{chunk-6I5UN4FD.js → chunk-CDT33RHG.js} +4 -4
  35. package/dist/{chunk-3DOQOXXI.js → chunk-CNUN5GO6.js} +1 -1
  36. package/dist/{chunk-NF5YKFRH.js → chunk-COPSI54O.js} +3 -3
  37. package/dist/{chunk-GUTZCRBT.js → chunk-CUY56BK4.js} +2 -2
  38. package/dist/{chunk-HSRQDWV7.js → chunk-CYF2X3CG.js} +2 -11
  39. package/dist/{chunk-NGC3IZRY.js → chunk-DNMICILX.js} +2 -2
  40. package/dist/{chunk-CFBY77QJ.js → chunk-DXPT2HPH.js} +145 -156
  41. package/dist/{chunk-J7Q4VPBJ.js → chunk-EB7AEM2H.js} +28 -22
  42. package/dist/{chunk-MGBV4JEI.js → chunk-EDXGEQW3.js} +1 -1
  43. package/dist/{chunk-H2GEIFUF.js → chunk-EEYQFJVK.js} +154 -48
  44. package/dist/{chunk-FPXMCGS5.js → chunk-EK7JYFCL.js} +2 -2
  45. package/dist/{chunk-3C2FWS2J.js → chunk-EWERNTOX.js} +1 -1
  46. package/dist/{chunk-WZ23JJ7U.js → chunk-FDRHBQUG.js} +26 -24
  47. package/dist/{chunk-FJNXXGTR.js → chunk-FS2LZBHG.js} +2 -2
  48. package/dist/{chunk-ERNCPKD4.js → chunk-G2KHLANR.js} +1 -1
  49. package/dist/{chunk-XVSJYAK7.js → chunk-G5BGW4BX.js} +2 -2
  50. package/dist/{chunk-33FQ6HNV.js → chunk-GQVXYRPC.js} +9 -9
  51. package/dist/{chunk-MHAYUS65.js → chunk-GXP344YZ.js} +3 -3
  52. package/dist/{chunk-NJIGYGZS.js → chunk-GYBKG4Z6.js} +15 -10
  53. package/dist/{chunk-MSXRNVHB.js → chunk-HIVJBESO.js} +311 -72
  54. package/dist/{chunk-UY6TEJJH.js → chunk-HJRP6PXL.js} +1 -1
  55. package/dist/{chunk-DOXBS7F5.js → chunk-HLE5QGZJ.js} +4 -4
  56. package/dist/{chunk-L5AFONQU.js → chunk-HX2KJEPD.js} +1 -1
  57. package/dist/{chunk-LL6D3MES.js → chunk-I6FWHICD.js} +19 -19
  58. package/dist/{chunk-RH2PROYG.js → chunk-I6GGMCTV.js} +4 -2
  59. package/dist/{chunk-3RYBTEF5.js → chunk-I74AQRVD.js} +6 -12
  60. package/dist/{chunk-PLE2432T.js → chunk-ICYPGWOV.js} +3 -3
  61. package/dist/chunk-IHK3Y2HG.js +781 -0
  62. package/dist/{chunk-JD4RHBNX.js → chunk-IMHNZITR.js} +9 -9
  63. package/dist/{chunk-GUYVKGFN.js → chunk-IRVQT4GR.js} +3 -3
  64. package/dist/{chunk-XUDGZJTJ.js → chunk-J3ODKAWN.js} +8 -8
  65. package/dist/{chunk-UMRZPRAN.js → chunk-JRQ4LBQI.js} +20 -20
  66. package/dist/{chunk-MY6GUH26.js → chunk-JX4RCC6B.js} +2 -2
  67. package/dist/{chunk-DSG6GBUQ.js → chunk-K4GUO7FV.js} +8 -8
  68. package/dist/{chunk-HAH5X345.js → chunk-KATED53P.js} +1 -1
  69. package/dist/{chunk-J64NZ6NF.js → chunk-KSZHIAI2.js} +1 -1
  70. package/dist/{chunk-7HWY4QAJ.js → chunk-L24LESXF.js} +1 -0
  71. package/dist/{chunk-UIUXIDBX.js → chunk-LBRHDWEA.js} +5 -5
  72. package/dist/{chunk-GSYZZFI5.js → chunk-LC5LY5V2.js} +2 -2
  73. package/dist/{chunk-P5V63L35.js → chunk-LNQDICFJ.js} +22 -22
  74. package/dist/{chunk-PIXJL77H.js → chunk-M6J25PAZ.js} +1 -1
  75. package/dist/{chunk-RGI64U3A.js → chunk-MIVSVEK4.js} +14 -14
  76. package/dist/{chunk-6K7RODXG.js → chunk-MKFQ5E7J.js} +1 -1
  77. package/dist/{chunk-44GP7PD5.js → chunk-MPJQMMBZ.js} +12 -0
  78. package/dist/{chunk-WQ6G6FFM.js → chunk-NFWRIC2V.js} +1 -1
  79. package/dist/{chunk-LHL6HDUL.js → chunk-NJYA4QSN.js} +84 -12
  80. package/dist/{chunk-RU725VCJ.js → chunk-NMKLX57Y.js} +10 -35
  81. package/dist/{chunk-PPH6ILHL.js → chunk-NP2SE6MQ.js} +4 -4
  82. package/dist/{chunk-FM3WAVB6.js → chunk-NS7L7YKH.js} +1 -1
  83. package/dist/{chunk-HEYGGSNQ.js → chunk-NTJ5HVV6.js} +5 -5
  84. package/dist/{chunk-BAZT6CIF.js → chunk-NUYWNKHH.js} +9 -9
  85. package/dist/{chunk-DV2VEJCC.js → chunk-NWSPPGIE.js} +6 -6
  86. package/dist/{chunk-AYOVY75O.js → chunk-NY56FM55.js} +3 -3
  87. package/dist/{chunk-LD2JSKU3.js → chunk-OOCVGX4W.js} +15 -0
  88. package/dist/{chunk-A4XPI4YN.js → chunk-OSIUWQ3N.js} +29 -2
  89. package/dist/{chunk-LJFXC3IP.js → chunk-OWJVSJLA.js} +17 -17
  90. package/dist/{chunk-GDJW64XE.js → chunk-OYKNMFUY.js} +1 -1
  91. package/dist/{chunk-YK4N6TBN.js → chunk-PIHAUVA4.js} +10 -10
  92. package/dist/{chunk-C7QRRTAW.js → chunk-PNCKZFPE.js} +2 -2
  93. package/dist/{chunk-D4M25W6R.js → chunk-POBNN5DP.js} +6 -6
  94. package/dist/{chunk-N7XRBWXA.js → chunk-PQ5NW3QZ.js} +15 -15
  95. package/dist/{chunk-HTPZDZKQ.js → chunk-PXEUQ7EG.js} +22 -22
  96. package/dist/{chunk-XWYR5T52.js → chunk-QOZ4RVQY.js} +19 -19
  97. package/dist/{chunk-BV6PKJUS.js → chunk-QRIW46LR.js} +8 -8
  98. package/dist/{chunk-LSQGJN5H.js → chunk-R2PTZ6QM.js} +21 -21
  99. package/dist/{chunk-VW52W5F6.js → chunk-RCBHL2B5.js} +229 -159
  100. package/dist/{chunk-66YFDTT6.js → chunk-RJYFHEP4.js} +3 -3
  101. package/dist/{chunk-P3SKSKJI.js → chunk-RNXX2GOQ.js} +2 -2
  102. package/dist/{chunk-BT2WH2XT.js → chunk-RRBV4HIM.js} +3 -3
  103. package/dist/{chunk-WXPBP4IT.js → chunk-RY5RRKYN.js} +14 -14
  104. package/dist/{chunk-NZCSVD4M.js → chunk-S4LLHDGK.js} +8 -8
  105. package/dist/chunk-S7C32S2T.js +825 -0
  106. package/dist/{chunk-QFIXL3OK.js → chunk-SEKNYIMO.js} +1 -1
  107. package/dist/{chunk-JRUEIRJB.js → chunk-SLO22FPS.js} +2 -2
  108. package/dist/{chunk-47E5UTXE.js → chunk-SMEVBJJJ.js} +2 -2
  109. package/dist/{chunk-QFHWYWQL.js → chunk-SVQDLYX7.js} +1 -1
  110. package/dist/{chunk-WP2RLGDI.js → chunk-TCX5PMEY.js} +1 -1
  111. package/dist/{chunk-5LD7SHXO.js → chunk-TQ644YGV.js} +18 -18
  112. package/dist/{chunk-PUVTFUNH.js → chunk-U762HK4D.js} +28 -28
  113. package/dist/{chunk-DAX42XVH.js → chunk-VCHYS3RD.js} +14 -9
  114. package/dist/{chunk-XIFK423U.js → chunk-W7QN5BC5.js} +4 -4
  115. package/dist/{chunk-7UDAIP6W.js → chunk-WHRIN7N3.js} +1 -1
  116. package/dist/{chunk-ZUCXFXLD.js → chunk-X3WYJ5T7.js} +2 -2
  117. package/dist/{chunk-RE6TVIAV.js → chunk-X6IZP2BD.js} +4 -4
  118. package/dist/{chunk-LCJURK7L.js → chunk-Y6GQQ4Y2.js} +1 -1
  119. package/dist/{chunk-HTWH2XQL.js → chunk-YE7D2S75.js} +2 -2
  120. package/dist/{chunk-B7CU2HW5.js → chunk-YKGUSW6D.js} +17 -17
  121. package/dist/{chunk-AQIBKTPG.js → chunk-YWRZG6GN.js} +10 -10
  122. package/dist/{chunk-JQ57AWDL.js → chunk-ZJ4PYTCK.js} +1 -1
  123. package/dist/completion-registry.d.ts +7 -1
  124. package/dist/completion-registry.js +64 -20
  125. package/dist/countdown.js +1 -1
  126. package/dist/{d3-B6524aaP.d.ts → d3-2S3PrXik.d.ts} +11 -0
  127. package/dist/dgmo-router-BJBXSZMV.js +94 -0
  128. package/dist/{dimensions-6QAWEGIR.js → dimensions-AMA2S7RO.js} +7 -7
  129. package/dist/editor.js +12 -0
  130. package/dist/{flowchart-parser-GG7XBLQH.js → flowchart-parser-ADZIFVCH.js} +3 -3
  131. package/dist/{flowchart-renderer-THC6Y7EH.js → flowchart-renderer-CAG6ZNJ6.js} +10 -9
  132. package/dist/highlight.js +12 -0
  133. package/dist/index.d.ts +26 -5
  134. package/dist/index.js +94 -67
  135. package/dist/{layout-P6DTD4RT.js → layout-4RRC7XU7.js} +2 -2
  136. package/dist/{layout-LUQKAGGT.js → layout-6OSF2UGP.js} +5 -5
  137. package/dist/{layout-AM57TGN5.js → layout-C6MKMOBI.js} +3 -3
  138. package/dist/{layout-EHTYSMV4.js → layout-H4K54IW3.js} +2 -2
  139. package/dist/{layout-XUW444O5.js → layout-QS2SESBU.js} +3 -3
  140. package/dist/{layout-5NPBHV5F.js → layout-T2PGKQUQ.js} +4 -4
  141. package/dist/{layout-CUFA7XJD.js → layout-UFB2O4AO.js} +5 -5
  142. package/dist/{layout-MSSHF45T.js → layout-UPQGIT3N.js} +2 -2
  143. package/dist/{layout-QX5T6ZNE.js → layout-VQ2USZJ3.js} +5 -5
  144. package/dist/{layout-SOPAVXIH.js → layout-VRJ5YFUE.js} +3 -3
  145. package/dist/{layout-BOVTLAOT.js → layout-ZP7XYVXF.js} +2 -2
  146. package/dist/{layout-search-VKSBUCDM.js → layout-search-YKUL4VBV.js} +105 -6
  147. package/dist/{legend-constants-ZVO4FLAK.js → legend-constants-HE7FVDJP.js} +4 -2
  148. package/dist/{palettes-BIV54XLS.js → palettes-WQHELGVQ.js} +7 -4
  149. package/dist/{parser-KYPP2DX6.js → parser-223VOHSB.js} +4 -4
  150. package/dist/{parser-JOOAVBJI.js → parser-2PNV7UI3.js} +3 -3
  151. package/dist/{parser-GZ3LVF72.js → parser-3MGA2MTM.js} +2 -2
  152. package/dist/{parser-NOANDFJ4.js → parser-4AR25MAS.js} +2 -2
  153. package/dist/{parser-ACW6C6OY.js → parser-4B2PIXHI.js} +3 -3
  154. package/dist/{parser-KZMJNKDW.js → parser-57YQEEMC.js} +2 -2
  155. package/dist/{parser-J4DVNL4W.js → parser-5ZD2NKGU.js} +4 -4
  156. package/dist/{parser-LANGKWRG.js → parser-6LMB7BQQ.js} +2 -2
  157. package/dist/parser-AL6YL7KM.js +12 -0
  158. package/dist/{parser-5655XSOR.js → parser-B2FWP7ZO.js} +3 -3
  159. package/dist/{parser-GEKPWSSK.js → parser-BJDQX4KV.js} +3 -3
  160. package/dist/{parser-C327BBE3.js → parser-CA5WC5HF.js} +3 -3
  161. package/dist/{parser-KZMALSB2.js → parser-E5HFYL7B.js} +4 -4
  162. package/dist/{parser-WUK6CP5X.js → parser-ESZ5J5IJ.js} +6 -5
  163. package/dist/{parser-256EIWB2.js → parser-FDXUQ5TI.js} +2 -2
  164. package/dist/{parser-AN3MGHRL.js → parser-FV6RGALQ.js} +3 -3
  165. package/dist/{parser-DGF3ZEO6.js → parser-HPR7G7F6.js} +3 -3
  166. package/dist/{parser-OKB64MMN.js → parser-I4HZVIHX.js} +3 -3
  167. package/dist/{parser-JXS4426S.js → parser-J3BM2AP2.js} +4 -4
  168. package/dist/{parser-NPXPJHWN.js → parser-JFNDS5E5.js} +3 -3
  169. package/dist/{parser-PVIWHVGY.js → parser-KFIK3EOO.js} +3 -3
  170. package/dist/{parser-GPW4ZHPQ.js → parser-LGUT7KKH.js} +4 -3
  171. package/dist/{parser-KFYRTGTC.js → parser-MYRGCK7Q.js} +4 -4
  172. package/dist/{parser-ZLKYDFI5.js → parser-NAUUUCI3.js} +3 -3
  173. package/dist/{parser-DHSFIUPU.js → parser-NJ5VEZA3.js} +3 -3
  174. package/dist/{parser-OVQTTTUJ.js → parser-OFTMA36M.js} +2 -2
  175. package/dist/{parser-AKBVJHMK.js → parser-OV2WDSEV.js} +3 -3
  176. package/dist/{parser-LGS65QPN.js → parser-Q3UAOLEZ.js} +2 -2
  177. package/dist/{parser-XYY5NHP4.js → parser-R6OETHWM.js} +2 -2
  178. package/dist/{parser-7OEE7QT6.js → parser-RARXAHC7.js} +2 -2
  179. package/dist/{parser-NGHQQGD2.js → parser-T2RVIRDG.js} +3 -3
  180. package/dist/{parser-WEVTMBJ5.js → parser-W2DWCCLO.js} +3 -3
  181. package/dist/{parser-HCGXNHHL.js → parser-WFY4ZJUW.js} +3 -3
  182. package/dist/{parser-SA3RAJFS.js → parser-WSONWDFN.js} +2 -2
  183. package/dist/{renderer-2OOPQ4CH.js → renderer-3N64GVNM.js} +3 -3
  184. package/dist/{renderer-4BIMRO4X.js → renderer-3QM2DK7I.js} +7 -7
  185. package/dist/{renderer-4NZZ5J2F.js → renderer-3W5T3IU6.js} +8 -8
  186. package/dist/{renderer-RWJ45DWH.js → renderer-4Z7FRQ2A.js} +3 -3
  187. package/dist/{renderer-LODEVN3V.js → renderer-52CHSV6S.js} +13 -13
  188. package/dist/{renderer-X5A5VIRD.js → renderer-6OOJNEQE.js} +10 -10
  189. package/dist/{renderer-YDAVCRTP.js → renderer-A3PMPUO6.js} +15 -11
  190. package/dist/{renderer-NHPKNNBD.js → renderer-AM4VZSBQ.js} +11 -11
  191. package/dist/{renderer-SDUSBCJI.js → renderer-B3CPMS5R.js} +10 -10
  192. package/dist/{renderer-TPOZOAXR.js → renderer-B4KE3NM4.js} +17 -16
  193. package/dist/renderer-COSJM7UG.js +80 -0
  194. package/dist/{renderer-R34GJL7U.js → renderer-FXCVH2M5.js} +16 -15
  195. package/dist/{renderer-QM23SWAM.js → renderer-GWH5ACJ5.js} +4 -4
  196. package/dist/{renderer-222OTVQV.js → renderer-IG72UJHW.js} +5 -5
  197. package/dist/{renderer-A6ACVK4X.js → renderer-IO3D5E4E.js} +7 -7
  198. package/dist/{renderer-RMGN3Q7D.js → renderer-IPDCAACY.js} +5 -5
  199. package/dist/{renderer-XUPLAO4B.js → renderer-KK5BU5K2.js} +8 -8
  200. package/dist/{renderer-DCFQDBGJ.js → renderer-LD2H7WGP.js} +3 -3
  201. package/dist/{renderer-KVAQE7PQ.js → renderer-MK47ESCB.js} +8 -8
  202. package/dist/{renderer-4BHOELCE.js → renderer-MRMFYYZT.js} +3 -3
  203. package/dist/{renderer-6BUUTWVS.js → renderer-O5RQHGK2.js} +9 -9
  204. package/dist/{renderer-2KVQGGTT.js → renderer-OA5D3ZKB.js} +10 -10
  205. package/dist/{renderer-RENDISO5.js → renderer-ON4PTUHJ.js} +14 -14
  206. package/dist/{renderer-JKV2DBYP.js → renderer-OPDSKCQS.js} +7 -7
  207. package/dist/{renderer-XRALFCIN.js → renderer-PLRMST57.js} +10 -10
  208. package/dist/{renderer-WH2HWE5Z.js → renderer-PSMRAL72.js} +11 -11
  209. package/dist/{renderer-RNCYODNF.js → renderer-PXGCR7N4.js} +11 -10
  210. package/dist/{renderer-PQYO2HCE.js → renderer-R7OYCJEA.js} +4 -4
  211. package/dist/{renderer-36JH4OMC.js → renderer-SBXCPA3S.js} +12 -12
  212. package/dist/{renderer-A4LMOBZL.js → renderer-TMQNTUQS.js} +15 -15
  213. package/dist/renderer-TTKTBB4C.js +46 -0
  214. package/dist/{renderer-RAATRF6W.js → renderer-UVFGW2O6.js} +12 -10
  215. package/dist/{renderer-3FF4QVGW.js → renderer-W22GX72R.js} +10 -10
  216. package/dist/{renderer-BICLPGAH.js → renderer-WQ654YT5.js} +2 -2
  217. package/dist/{renderer-radial-XZ5TKUT4.js → renderer-radial-42LVSG74.js} +8 -8
  218. package/dist/{state-parser-FE3RF6XY.js → state-parser-ROKY5KSI.js} +4 -4
  219. package/dist/{state-renderer-5IQ4OJUI.js → state-renderer-MMG23G4W.js} +14 -14
  220. package/dist/{themes-CzuBdx1T.d.ts → themes-Cm2YBcT8.d.ts} +38 -2
  221. package/docs/ai-integration.md +8 -5
  222. package/docs/language-reference.md +163 -13
  223. package/gallery/fixtures/sketch.dgmo +2 -2
  224. package/gallery/fixtures/whiteboard.dgmo +18 -0
  225. package/package.json +2 -1
  226. package/dist/dgmo-router-F2DSURTR.js +0 -92
  227. package/dist/renderer-YIZ7G4HU.js +0 -78
  228. package/dist/{chunk-3TYUXC7D.js → chunk-2SKMEL7V.js} +0 -0
  229. package/dist/{chunk-CLQIXD2C.js → chunk-7Z2VFRP5.js} +3 -3
  230. package/dist/{chunk-2A4DQAXG.js → chunk-IIOLFAGJ.js} +3 -3
@@ -9,6 +9,9 @@ import {
9
9
  import {
10
10
  ScaleContext
11
11
  } from "./chunk-24YPR5EH.js";
12
+ import {
13
+ renderIntegratedLegend
14
+ } from "./chunk-NJYA4QSN.js";
12
15
  import {
13
16
  ARROWHEAD_HEIGHT,
14
17
  ARROWHEAD_WIDTH,
@@ -26,34 +29,30 @@ import {
26
29
  } from "./chunk-XCKNFFKM.js";
27
30
  import {
28
31
  layoutInlineHeader
29
- } from "./chunk-3DOQOXXI.js";
32
+ } from "./chunk-CNUN5GO6.js";
33
+ import {
34
+ getLegendExtent,
35
+ getMaxLegendReservedHeight
36
+ } from "./chunk-NS7L7YKH.js";
30
37
  import {
31
38
  TITLE_FONT_SIZE,
32
39
  TITLE_FONT_WEIGHT,
33
40
  TITLE_Y
34
41
  } from "./chunk-VLC6WNRD.js";
35
- import {
36
- renderIntegratedLegend
37
- } from "./chunk-LHL6HDUL.js";
38
- import {
39
- getLegendExtent,
40
- getMaxLegendReservedHeight
41
- } from "./chunk-FM3WAVB6.js";
42
42
  import {
43
43
  FONT_FAMILY
44
44
  } from "./chunk-ICLB27PZ.js";
45
- import {
46
- fitWrapped,
47
- measureText,
48
- wrapTextToWidth
49
- } from "./chunk-KAO7JL4I.js";
50
45
  import {
51
46
  UNTAGGED_TAG_COLOR,
52
47
  resolveActiveTagGroup,
53
48
  resolveGroupTagColor,
54
49
  resolveTagColor,
55
50
  tagAttrKey
56
- } from "./chunk-L5AFONQU.js";
51
+ } from "./chunk-HX2KJEPD.js";
52
+ import {
53
+ fitWrapped,
54
+ measureText
55
+ } from "./chunk-KAO7JL4I.js";
57
56
  import {
58
57
  contrastText,
59
58
  groupFill,
@@ -61,7 +60,7 @@ import {
61
60
  mix,
62
61
  shapeFill,
63
62
  themeBaseBg
64
- } from "./chunk-7HWY4QAJ.js";
63
+ } from "./chunk-L24LESXF.js";
65
64
 
66
65
  // src/sketch/renderer.ts
67
66
  import * as d3 from "d3-selection";
@@ -424,41 +423,10 @@ var DASH = SKETCH_VISUALS.dash;
424
423
  var BAND_LABEL_FONT_SIZE = SKETCH_VISUALS.bandLabelFontSize;
425
424
  var BAND_LABEL_OPACITY = SKETCH_VISUALS.bandLabelOpacity;
426
425
  var BAND_LABEL_WEIGHT = SKETCH_VISUALS.bandLabelFontWeight;
427
- var NOTE_FONT_SIZE = 11;
428
426
  var COLLAPSE_BAR_HEIGHT2 = COLLAPSE_BAR_HEIGHT;
429
427
  var EDGE_LABEL_FONT_SIZE = SKETCH_VISUALS.edgeLabelFontSize;
430
428
  var CURVE_HANDLE_MIN = 24;
431
429
  var CURVE_HANDLE_MAX = 90;
432
- function drawNoteBody(g, w, h, colors, strokeWidth) {
433
- const f = 14;
434
- g.append("path").attr(
435
- "d",
436
- `M0 2 a2 2 0 0 1 2 -2 h${w - f - 2} l${f} ${f} v${h - f - 2} a2 2 0 0 1 -2 2 h-${w - 4} a2 2 0 0 1 -2 -2 Z`
437
- ).attr("fill", colors.fill).attr("stroke", colors.stroke).attr("stroke-width", strokeWidth);
438
- g.append("path").attr("d", `M${w - f} 0 v${f} h${f}`).attr("fill", "none").attr("stroke", colors.stroke).attr("stroke-width", 1.2);
439
- }
440
- function drawTypeBadge(g, kind, color, bx, by) {
441
- const b = g.append("g").attr("transform", `translate(${bx},${by})`).attr("fill", "none").attr("stroke", color).attr("stroke-width", 1.3).attr("stroke-linejoin", "round").attr("stroke-linecap", "round");
442
- switch (kind) {
443
- case "database":
444
- b.append("ellipse").attr("cx", 8).attr("cy", 3).attr("rx", 6).attr("ry", 2.4);
445
- b.append("path").attr("d", "M2 3 v10 a6 2.4 0 0 0 12 0 v-10");
446
- return;
447
- case "queue":
448
- b.append("path").attr("d", "M3 1 h8 a3 6.5 0 0 1 0 13 h-8 Z");
449
- b.append("ellipse").attr("cx", 3).attr("cy", 7.5).attr("rx", 3).attr("ry", 6.5);
450
- return;
451
- case "document":
452
- b.append("path").attr("d", "M2 1 h9 v11 q-4.5 2 -9 0 q0 0 0 0 Z");
453
- return;
454
- case "person":
455
- b.append("circle").attr("cx", 8).attr("cy", 5).attr("r", 3);
456
- b.append("path").attr("d", "M2 15 a6 5 0 0 1 12 0");
457
- return;
458
- default:
459
- return;
460
- }
461
- }
462
430
  var CARD_HEADER_H = SKETCH_VISUALS.cardHeaderHeight;
463
431
  var CARD_LABEL_MAX = SKETCH_VISUALS.nodeLabelFontSize;
464
432
  var CARD_LABEL_MIN = SKETCH_VISUALS.nodeLabelFontSizeMin;
@@ -476,7 +444,6 @@ function renderSketch(container, parsed, layout, palette, isDark, options = {})
476
444
  const sTitleFontSize = sctx.text(TITLE_FONT_SIZE2);
477
445
  const sEdgeLabelFontSize = sctx.text(EDGE_LABEL_FONT_SIZE);
478
446
  const sBandLabelFontSize = sctx.text(BAND_LABEL_FONT_SIZE);
479
- const sNoteFontSize = sctx.text(NOTE_FONT_SIZE);
480
447
  const sCardLabelMax = sctx.text(CARD_LABEL_MAX);
481
448
  const sCardLabelMin = sctx.text(CARD_LABEL_MIN);
482
449
  const sCardMetaFont = sctx.text(CARD_META_FONT);
@@ -497,8 +464,7 @@ function renderSketch(container, parsed, layout, palette, isDark, options = {})
497
464
  cardLabelMin: sCardLabelMin,
498
465
  cardMetaFont: sCardMetaFont,
499
466
  cardTitleMax: sCardTitleMax,
500
- bandLabelFontSize: sBandLabelFontSize,
501
- noteFontSize: sNoteFontSize
467
+ bandLabelFontSize: sBandLabelFontSize
502
468
  };
503
469
  const tagGroups = [...parsed.tagGroups];
504
470
  const activeName = resolveActiveTagGroup(
@@ -817,75 +783,20 @@ function drawNode(layer, node, colors, palette, isDark, splitCard, s) {
817
783
  void isDark;
818
784
  const g = layer.append("g").attr("class", node.isCollapsedBox ? "sk-node sk-box-collapsed" : "sk-node").attr("transform", `translate(${node.x},${node.y})`).attr("data-node-id", node.id).attr("data-line-number", node.lineNumber);
819
785
  for (const [k, v] of Object.entries(node.metadata)) {
820
- g.attr(`data-tag-${k}`, v);
786
+ g.attr(`data-tag-${tagAttrKey(k)}`, v);
821
787
  }
822
788
  if (node.isCollapsedBox) {
823
789
  g.attr("data-group-toggle", node.label);
824
790
  }
825
- if (node.shape === "note") {
826
- drawNoteBody(g, node.w, node.h, colors, s.nodeStrokeWidth);
827
- const lines = wrapTextToWidth(node.label, s.noteFontSize, node.w - 34);
828
- const lineHeight = s.noteFontSize + 4;
829
- lines.slice(0, 5).forEach((line, i) => {
830
- g.append("text").attr("x", 10).attr("y", 20 + i * lineHeight).attr("font-size", s.noteFontSize).attr("fill", colors.text).text(line);
831
- });
832
- } else {
833
- const badge = node.shape !== "rectangle";
834
- const labelInset = badge ? 22 : 0;
835
- const solidLike = colors.stroke === colors.fill;
836
- const ruleColor = solidLike ? colors.text : colors.stroke;
837
- if (!node.isCollapsedBox && (node.description || splitCard)) {
838
- const fitH = fitWrapped(
839
- node.label,
840
- node.w - 24 - labelInset,
841
- s.cardLabelMax,
842
- s.cardLabelMin,
843
- 1
844
- );
845
- renderNodeCard(g, {
846
- width: node.w,
847
- height: node.h,
848
- rx: s.cardRadius,
849
- fill: colors.fill,
850
- stroke: colors.stroke,
851
- strokeWidth: s.nodeStrokeWidth,
852
- label: fitH.lines[0] ?? node.label,
853
- labelColor: colors.text,
854
- labelFontSize: fitH.fontSize,
855
- headerHeight: s.cardHeaderH
856
- });
857
- g.append("line").attr("x1", 0).attr("y1", s.cardHeaderH).attr("x2", node.w).attr("y2", s.cardHeaderH).attr("stroke", ruleColor).attr("stroke-opacity", 0.3).attr("stroke-width", 1);
858
- if (node.description) {
859
- const inset = 12;
860
- const bodyGap = 8;
861
- const lh = s.cardMetaFont + 4;
862
- const avail = node.h - s.cardHeaderH - bodyGap - 8;
863
- const body = g.append("g").attr("class", "sk-desc").attr("transform", `translate(${inset} ${s.cardHeaderH + bodyGap})`);
864
- const block = drawMarkdownBlock(body, node.description, {
865
- width: node.w - inset * 2,
866
- fontSize: s.cardMetaFont,
867
- lineHeight: lh,
868
- color: colors.text,
869
- // match the header label (contrast-aware in solid)
870
- linkColor: colors.text,
871
- maxLines: Math.max(1, Math.floor(avail / lh)),
872
- noEllipsis: true
873
- });
874
- if (block.total > block.shown) {
875
- g.append("text").attr("class", "sk-desc-more").attr("x", node.w - 8).attr("y", node.h - 5).attr("text-anchor", "end").attr("font-size", 9).attr("fill", palette.textMuted).attr("data-line-number", node.lineNumber).style("cursor", "pointer").text(`+${block.total - block.shown} more in source`);
876
- }
877
- }
878
- if (badge) {
879
- drawTypeBadge(g, node.shape, colors.text, 10, (s.cardHeaderH - 16) / 2);
880
- }
881
- return;
882
- }
883
- const fit = fitWrapped(
791
+ const solidLike = colors.stroke === colors.fill;
792
+ const ruleColor = solidLike ? colors.text : colors.stroke;
793
+ if (!node.isCollapsedBox && (node.description || splitCard)) {
794
+ const fitH = fitWrapped(
884
795
  node.label,
885
- node.w - 24 - labelInset,
886
- s.cardTitleMax,
796
+ node.w - 24,
797
+ s.cardLabelMax,
887
798
  s.cardLabelMin,
888
- 3
799
+ 1
889
800
  );
890
801
  renderNodeCard(g, {
891
802
  width: node.w,
@@ -894,16 +805,54 @@ function drawNode(layer, node, colors, palette, isDark, splitCard, s) {
894
805
  fill: colors.fill,
895
806
  stroke: colors.stroke,
896
807
  strokeWidth: s.nodeStrokeWidth,
897
- label: fit.lines.join(" "),
898
- labelLines: fit.lines,
808
+ label: fitH.lines[0] ?? node.label,
899
809
  labelColor: colors.text,
900
- labelFontSize: fit.fontSize,
901
- headerHeight: node.h
810
+ labelFontSize: fitH.fontSize,
811
+ headerHeight: s.cardHeaderH
902
812
  });
903
- if (badge) {
904
- drawTypeBadge(g, node.shape, colors.text, 10, (s.cardHeaderH - 16) / 2);
813
+ g.append("line").attr("x1", 0).attr("y1", s.cardHeaderH).attr("x2", node.w).attr("y2", s.cardHeaderH).attr("stroke", ruleColor).attr("stroke-opacity", 0.3).attr("stroke-width", 1);
814
+ if (node.description) {
815
+ const inset = 12;
816
+ const bodyGap = 8;
817
+ const lh = s.cardMetaFont + 4;
818
+ const avail = node.h - s.cardHeaderH - bodyGap - 8;
819
+ const body = g.append("g").attr("class", "sk-desc").attr("transform", `translate(${inset} ${s.cardHeaderH + bodyGap})`);
820
+ const block = drawMarkdownBlock(body, node.description, {
821
+ width: node.w - inset * 2,
822
+ fontSize: s.cardMetaFont,
823
+ lineHeight: lh,
824
+ color: colors.text,
825
+ // match the header label (contrast-aware in solid)
826
+ linkColor: colors.text,
827
+ maxLines: Math.max(1, Math.floor(avail / lh)),
828
+ noEllipsis: true
829
+ });
830
+ if (block.total > block.shown) {
831
+ g.append("text").attr("class", "sk-desc-more").attr("x", node.w - 8).attr("y", node.h - 5).attr("text-anchor", "end").attr("font-size", 9).attr("fill", palette.textMuted).attr("data-line-number", node.lineNumber).style("cursor", "pointer").text(`+${block.total - block.shown} more in source`);
832
+ }
905
833
  }
834
+ return;
906
835
  }
836
+ const fit = fitWrapped(
837
+ node.label,
838
+ node.w - 24,
839
+ s.cardTitleMax,
840
+ s.cardLabelMin,
841
+ 3
842
+ );
843
+ renderNodeCard(g, {
844
+ width: node.w,
845
+ height: node.h,
846
+ rx: s.cardRadius,
847
+ fill: colors.fill,
848
+ stroke: colors.stroke,
849
+ strokeWidth: s.nodeStrokeWidth,
850
+ label: fit.lines.join(" "),
851
+ labelLines: fit.lines,
852
+ labelColor: colors.text,
853
+ labelFontSize: fit.fontSize,
854
+ headerHeight: node.h
855
+ });
907
856
  if (node.isCollapsedBox) {
908
857
  renderCollapseBar(g, {
909
858
  width: node.w,
@@ -1048,57 +997,70 @@ function hoppedPath(g, hops) {
1048
997
  const N = 49;
1049
998
  const pts = [];
1050
999
  for (let s = 0; s <= N; s++) pts.push(cubicAt(g, s / N));
1051
- const onSeg = /* @__PURE__ */ new Map();
1000
+ const cum = [0];
1001
+ for (let k2 = 1; k2 <= N; k2++) {
1002
+ const a = pts[k2 - 1];
1003
+ const b = pts[k2];
1004
+ cum.push(cum[k2 - 1] + Math.hypot(b.x - a.x, b.y - a.y));
1005
+ }
1006
+ const total = cum[N];
1007
+ const at = (len) => {
1008
+ let k2 = 1;
1009
+ while (k2 < N && cum[k2] < len) k2++;
1010
+ const a = pts[k2 - 1];
1011
+ const b = pts[k2];
1012
+ const span = cum[k2] - cum[k2 - 1] || 1;
1013
+ const f = Math.max(0, Math.min(1, (len - cum[k2 - 1]) / span));
1014
+ return { x: a.x + f * (b.x - a.x), y: a.y + f * (b.y - a.y) };
1015
+ };
1016
+ const centres = [];
1052
1017
  for (const hp of hops) {
1053
- let bestSeg = -1;
1054
1018
  let bestD = Infinity;
1055
- let bestPt = null;
1056
- for (let k = 1; k <= N; k++) {
1057
- const a = pts[k - 1];
1058
- const b = pts[k];
1019
+ let bestLen = 0;
1020
+ for (let k2 = 1; k2 <= N; k2++) {
1021
+ const a = pts[k2 - 1];
1022
+ const b = pts[k2];
1059
1023
  const dx = b.x - a.x;
1060
1024
  const dy = b.y - a.y;
1061
1025
  const len2 = dx * dx + dy * dy || 1;
1062
1026
  let f = ((hp.x - a.x) * dx + (hp.y - a.y) * dy) / len2;
1063
1027
  f = Math.max(0, Math.min(1, f));
1064
- const px = a.x + f * dx;
1065
- const py = a.y + f * dy;
1066
- const d2 = Math.hypot(hp.x - px, hp.y - py);
1028
+ const d2 = Math.hypot(hp.x - (a.x + f * dx), hp.y - (a.y + f * dy));
1067
1029
  if (d2 < bestD) {
1068
1030
  bestD = d2;
1069
- bestSeg = k;
1070
- bestPt = { x: px, y: py };
1031
+ bestLen = cum[k2 - 1] + f * (cum[k2] - cum[k2 - 1]);
1071
1032
  }
1072
1033
  }
1073
- if (bestSeg >= 3 && bestSeg <= N - 3 && bestPt && !onSeg.has(bestSeg))
1074
- onSeg.set(bestSeg, bestPt);
1034
+ centres.push(bestLen);
1075
1035
  }
1076
- if (onSeg.size === 0) return null;
1036
+ const clear = Math.max(2 * HOP_R, 3 * total / N);
1037
+ const kept = [];
1038
+ for (const c of centres.sort((x, y) => x - y)) {
1039
+ if (c < clear || c > total - clear) continue;
1040
+ if (kept.length > 0 && c - kept[kept.length - 1] < 2 * HOP_R) continue;
1041
+ kept.push(c);
1042
+ }
1043
+ if (kept.length === 0) return null;
1077
1044
  let d = `M ${pts[0].x} ${pts[0].y}`;
1078
- for (let k = 1; k <= N; k++) {
1079
- const a = pts[k - 1];
1080
- const b = pts[k];
1081
- const hp = onSeg.get(k);
1082
- if (hp) {
1083
- const segLen = Math.hypot(b.x - a.x, b.y - a.y) || 1;
1084
- const dir = { x: (b.x - a.x) / segLen, y: (b.y - a.y) / segLen };
1085
- let perp = { x: dir.y, y: -dir.x };
1086
- if (perp.y > 0) perp = { x: -perp.x, y: -perp.y };
1087
- const A = { x: hp.x - dir.x * HOP_R, y: hp.y - dir.y * HOP_R };
1088
- const B = { x: hp.x + dir.x * HOP_R, y: hp.y + dir.y * HOP_R };
1089
- const k1 = {
1090
- x: A.x + perp.x * HOP_R * 1.33,
1091
- y: A.y + perp.y * HOP_R * 1.33
1092
- };
1093
- const k2 = {
1094
- x: B.x + perp.x * HOP_R * 1.33,
1095
- y: B.y + perp.y * HOP_R * 1.33
1096
- };
1097
- d += ` L ${A.x} ${A.y} C ${k1.x} ${k1.y}, ${k2.x} ${k2.y}, ${B.x} ${B.y} L ${b.x} ${b.y}`;
1098
- } else {
1099
- d += ` L ${b.x} ${b.y}`;
1045
+ let k = 1;
1046
+ for (const c of kept) {
1047
+ const s0 = c - HOP_R;
1048
+ const s1 = c + HOP_R;
1049
+ while (k <= N && cum[k] < s0) {
1050
+ d += ` L ${pts[k].x} ${pts[k].y}`;
1051
+ k++;
1100
1052
  }
1053
+ const A = at(s0);
1054
+ const B = at(s1);
1055
+ const chord = Math.hypot(B.x - A.x, B.y - A.y) || 1;
1056
+ const dir = { x: (B.x - A.x) / chord, y: (B.y - A.y) / chord };
1057
+ let perp = { x: dir.y, y: -dir.x };
1058
+ if (perp.y > 0) perp = { x: -perp.x, y: -perp.y };
1059
+ const lift = chord / 2 * 1.33;
1060
+ d += ` L ${A.x} ${A.y} C ${A.x + perp.x * lift} ${A.y + perp.y * lift}, ${B.x + perp.x * lift} ${B.y + perp.y * lift}, ${B.x} ${B.y}`;
1061
+ while (k <= N && cum[k] <= s1) k++;
1101
1062
  }
1063
+ for (; k <= N; k++) d += ` L ${pts[k].x} ${pts[k].y}`;
1102
1064
  return d;
1103
1065
  }
1104
1066
  function pathCrossings(g, obstacles) {
@@ -1411,6 +1373,7 @@ function sketchEdgeGeometry(layout, offsets) {
1411
1373
  return out;
1412
1374
  };
1413
1375
  const hopsFor = layout.edges.map(() => []);
1376
+ const hopsOn = layout.edges.map(() => []);
1414
1377
  for (let i = 0; i < polys.length; i++) {
1415
1378
  for (let j = i + 1; j < polys.length; j++) {
1416
1379
  const a = polys[i];
@@ -1418,7 +1381,11 @@ function sketchEdgeGeometry(layout, offsets) {
1418
1381
  if (!a || !b) continue;
1419
1382
  if (!ctx[i]?.adjacent.has(j)) {
1420
1383
  const pt2 = polyIntersections(a, b)[0];
1421
- if (pt2) hopsFor[j].push(pt2);
1384
+ if (pt2) {
1385
+ hopsFor[j].push(pt2);
1386
+ hopsOn[i].push(pt2);
1387
+ hopsOn[j].push(pt2);
1388
+ }
1422
1389
  continue;
1423
1390
  }
1424
1391
  const ei = layout.edges[i];
@@ -1435,7 +1402,11 @@ function sketchEdgeGeometry(layout, offsets) {
1435
1402
  (q) => Math.hypot(p.x - q.x, p.y - q.y) > SHARED_END_CLEAR
1436
1403
  )
1437
1404
  );
1438
- if (pt) hopsFor[j].push(pt);
1405
+ if (pt) {
1406
+ hopsFor[j].push(pt);
1407
+ hopsOn[i].push(pt);
1408
+ hopsOn[j].push(pt);
1409
+ }
1439
1410
  }
1440
1411
  }
1441
1412
  return layout.edges.map((edge, i) => {
@@ -1448,6 +1419,7 @@ function sketchEdgeGeometry(layout, offsets) {
1448
1419
  d: g.d,
1449
1420
  mid: g.mid,
1450
1421
  ...dRender && { dRender },
1422
+ ...hopsOn[i].length > 0 && { hops: hopsOn[i] },
1451
1423
  p0: g.p0,
1452
1424
  h0: g.h0,
1453
1425
  h1: g.h1,
@@ -1455,6 +1427,22 @@ function sketchEdgeGeometry(layout, offsets) {
1455
1427
  };
1456
1428
  });
1457
1429
  }
1430
+ var HOP_LABEL_CLEAR = HOP_R + 2;
1431
+ function sketchLabelSpot(g, halfW, halfH) {
1432
+ const hops = g.hops ?? [];
1433
+ if (hops.length === 0) return g.mid;
1434
+ const clear = (p) => hops.every(
1435
+ (h) => Math.abs(p.x - h.x) >= halfW + HOP_LABEL_CLEAR || Math.abs(p.y - h.y) >= halfH + HOP_LABEL_CLEAR
1436
+ );
1437
+ if (clear(g.mid)) return g.mid;
1438
+ for (let step = 1; step <= 18; step++) {
1439
+ for (const t of [0.5 - step * 0.02, 0.5 + step * 0.02]) {
1440
+ const p = cubicAt(g, t);
1441
+ if (clear(p)) return p;
1442
+ }
1443
+ }
1444
+ return g.mid;
1445
+ }
1458
1446
  function renderSketchForExport(container, parsed, layout, palette, isDark, options = {}) {
1459
1447
  renderSketch(container, parsed, layout, palette, isDark, {
1460
1448
  ...options,
@@ -1472,5 +1460,6 @@ export {
1472
1460
  SKETCH_VISUALS,
1473
1461
  renderSketch,
1474
1462
  sketchEdgeGeometry,
1463
+ sketchLabelSpot,
1475
1464
  renderSketchForExport
1476
1465
  };
@@ -4,48 +4,50 @@ import {
4
4
  import {
5
5
  ScaleContext
6
6
  } from "./chunk-24YPR5EH.js";
7
+ import {
8
+ keepSwimlaneToggleFocus,
9
+ renderIntegratedLegend,
10
+ wireSwimlaneToggle
11
+ } from "./chunk-NJYA4QSN.js";
7
12
  import {
8
13
  CARD_RADIUS
9
14
  } from "./chunk-XCKNFFKM.js";
10
15
  import {
11
16
  serializeSvg
12
- } from "./chunk-LD2JSKU3.js";
17
+ } from "./chunk-OOCVGX4W.js";
18
+ import {
19
+ getMaxLegendReservedHeight
20
+ } from "./chunk-NS7L7YKH.js";
13
21
  import {
14
22
  TITLE_FONT_SIZE,
15
23
  TITLE_FONT_WEIGHT
16
24
  } from "./chunk-VLC6WNRD.js";
17
- import {
18
- renderIntegratedLegend
19
- } from "./chunk-LHL6HDUL.js";
20
- import {
21
- getMaxLegendReservedHeight
22
- } from "./chunk-FM3WAVB6.js";
23
25
  import {
24
26
  FONT_FAMILY
25
27
  } from "./chunk-ICLB27PZ.js";
26
28
  import {
27
29
  parseKanban
28
- } from "./chunk-GUYVKGFN.js";
30
+ } from "./chunk-IRVQT4GR.js";
31
+ import {
32
+ tagAttrKey
33
+ } from "./chunk-HX2KJEPD.js";
34
+ import {
35
+ fillModeFromOptions,
36
+ legendSuppressed
37
+ } from "./chunk-MPJQMMBZ.js";
29
38
  import {
30
39
  LEGEND_HEIGHT,
31
40
  measureLegendText
32
- } from "./chunk-RH2PROYG.js";
41
+ } from "./chunk-I6GGMCTV.js";
33
42
  import {
34
43
  measureText
35
44
  } from "./chunk-KAO7JL4I.js";
36
- import {
37
- tagAttrKey
38
- } from "./chunk-L5AFONQU.js";
39
- import {
40
- fillModeFromOptions,
41
- legendSuppressed
42
- } from "./chunk-44GP7PD5.js";
43
45
  import {
44
46
  contrastText,
45
47
  mix,
46
48
  shapeFill,
47
49
  themeBaseBg
48
- } from "./chunk-7HWY4QAJ.js";
50
+ } from "./chunk-L24LESXF.js";
49
51
 
50
52
  // src/kanban/renderer.ts
51
53
  import * as d3Selection from "d3-selection";
@@ -357,6 +359,12 @@ function computeLayout(parsed, _palette, collapsedColumns, hiddenMetaGroups, sDi
357
359
  return { columns: columnLayouts, totalWidth, totalHeight };
358
360
  }
359
361
  function renderKanban(container, parsed, palette, isDark, options) {
362
+ keepSwimlaneToggleFocus(
363
+ container,
364
+ () => drawKanban(container, parsed, palette, isDark, options)
365
+ );
366
+ }
367
+ function drawKanban(container, parsed, palette, isDark, options) {
360
368
  const exportDims = options?.exportDims;
361
369
  const activeTagGroup = options?.activeTagGroup ?? null;
362
370
  const onSwimlaneChange = options?.onSwimlaneChange;
@@ -476,9 +484,7 @@ function renderKanban(container, parsed, palette, isDark, options) {
476
484
  isCurrent,
477
485
  palette
478
486
  );
479
- iconEl.append("title").text(`Group by ${groupName}`);
480
- iconEl.style("cursor", "pointer").on("click", (event) => {
481
- event.stopPropagation();
487
+ wireSwimlaneToggle(iconEl, groupName, isCurrent, true, () => {
482
488
  onSwimlaneChange?.(isCurrent ? null : groupName);
483
489
  });
484
490
  }
@@ -664,7 +670,7 @@ function renderKanban(container, parsed, palette, isDark, options) {
664
670
  const tagKey = tagAttrKey(activeTagGroup);
665
671
  const tagValue = card.tags[tagKey];
666
672
  const group = parsed.tagGroups.find(
667
- (tg) => tg.name.toLowerCase() === tagKey
673
+ (tg) => tagAttrKey(tg.name) === tagKey
668
674
  );
669
675
  const value = tagValue ?? group?.defaultValue;
670
676
  if (value) {
@@ -1131,7 +1137,7 @@ function renderSwimlaneCard(parent, cardLayout, tagGroups, activeTagGroup, palet
1131
1137
  const cg = parent.append("g").attr("class", "kanban-card").attr("data-card-id", card.id).attr("data-line-number", card.lineNumber);
1132
1138
  if (activeTagGroup) {
1133
1139
  const tagKey = tagAttrKey(activeTagGroup);
1134
- const group = tagGroups.find((tg) => tg.name.toLowerCase() === tagKey);
1140
+ const group = tagGroups.find((tg) => tagAttrKey(tg.name) === tagKey);
1135
1141
  const value = card.tags[tagKey] ?? group?.defaultValue;
1136
1142
  if (value) {
1137
1143
  cg.attr(`data-tag-${tagKey}`, value.toLowerCase());
@@ -3,7 +3,7 @@ import {
3
3
  addCalendarDays,
4
4
  resolveConfidence,
5
5
  unitToDays
6
- } from "./chunk-3TYUXC7D.js";
6
+ } from "./chunk-2SKMEL7V.js";
7
7
  import {
8
8
  makeDgmoError
9
9
  } from "./chunk-BYU54C3S.js";