@diagrammo/dgmo 0.64.0 → 0.65.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 (138) hide show
  1. package/LICENSE +1 -1
  2. package/dist/advanced.js +71 -71
  3. package/dist/block.js +15 -15
  4. package/dist/chart-meta.js +3 -3
  5. package/dist/{charts-d3-ZTXJWEHI.js → charts-d3-I6OE5K3B.js} +9 -9
  6. package/dist/{chunk-C6DMG2V6.js → chunk-27YPE7NO.js} +28 -12
  7. package/dist/{chunk-RBAW7VUG.js → chunk-2EPV7CLY.js} +5 -7
  8. package/dist/{chunk-SCJ7CAJF.js → chunk-3HOCNSPD.js} +2 -2
  9. package/dist/{chunk-Z2ADWRSW.js → chunk-3PSPUYT5.js} +3 -3
  10. package/dist/{chunk-RBBJIHNL.js → chunk-4IE42ODL.js} +11 -11
  11. package/dist/{chunk-SMCUX42K.js → chunk-4TM7MWU4.js} +7 -6
  12. package/dist/{chunk-H3HFC3SQ.js → chunk-5GM6BZO7.js} +3 -3
  13. package/dist/{chunk-7T3A2UK3.js → chunk-5T7K6QND.js} +15 -16
  14. package/dist/{chunk-NKRCPBTJ.js → chunk-6BOPYGJC.js} +6 -6
  15. package/dist/{chunk-37EHGTQ2.js → chunk-6E5YZR4S.js} +18 -16
  16. package/dist/{chunk-MHI6W6XS.js → chunk-6IUL6LER.js} +10 -7
  17. package/dist/{chunk-S5RWWISJ.js → chunk-7L53J53J.js} +4 -4
  18. package/dist/{chunk-WDJ4HAGO.js → chunk-A6CTYC7O.js} +2 -2
  19. package/dist/{chunk-CDMF7P5A.js → chunk-BBCKUAUR.js} +2 -2
  20. package/dist/{chunk-AA4M6F2P.js → chunk-BBY57XAA.js} +3 -3
  21. package/dist/{chunk-NKRVFQGO.js → chunk-BDI25HWH.js} +18 -6
  22. package/dist/{chunk-SVR3YFM3.js → chunk-C666LP3O.js} +20 -15
  23. package/dist/{chunk-KRTO7NRK.js → chunk-D2WHS23S.js} +2 -2
  24. package/dist/{chunk-LYTEVE2N.js → chunk-DBF4IM4U.js} +20 -15
  25. package/dist/{chunk-PCWPYOT4.js → chunk-ET4R3AU5.js} +4 -4
  26. package/dist/{chunk-2KOBOIB2.js → chunk-FBD5ASMB.js} +2 -2
  27. package/dist/{chunk-ES66QH6J.js → chunk-FG24NXKN.js} +2 -2
  28. package/dist/{chunk-3CIOJ5YJ.js → chunk-FJ57274M.js} +3 -1
  29. package/dist/{chunk-6BVIZW5N.js → chunk-FLFBY5GN.js} +14 -12
  30. package/dist/{chunk-XUN3MIO3.js → chunk-G64OVYUT.js} +2 -2
  31. package/dist/{chunk-RQL25P3U.js → chunk-G7QZF6T3.js} +9 -9
  32. package/dist/{chunk-IGIJZHB6.js → chunk-GC7CBX6C.js} +6 -6
  33. package/dist/{chunk-B6AONGTI.js → chunk-GDQN2TPX.js} +21 -14
  34. package/dist/{chunk-CZUSH6NI.js → chunk-GMLSYNFP.js} +10 -9
  35. package/dist/{chunk-R6HCNSP6.js → chunk-GOW5VO6M.js} +2 -2
  36. package/dist/{chunk-SPHC4RYF.js → chunk-GXOMKWQ5.js} +10 -9
  37. package/dist/{chunk-MQHOKBJ6.js → chunk-IJ4FUFTR.js} +5 -5
  38. package/dist/{chunk-V3UQSKWJ.js → chunk-IJSFEU4J.js} +9 -9
  39. package/dist/{chunk-LSFZDBAP.js → chunk-IKHV5IJB.js} +2 -2
  40. package/dist/{chunk-LMXAB4YM.js → chunk-IZ6RWMBM.js} +9 -9
  41. package/dist/{chunk-6VJCURWU.js → chunk-J2EXBAPZ.js} +4 -5
  42. package/dist/{chunk-IX6N5MCY.js → chunk-JCL4K7AK.js} +12 -11
  43. package/dist/{chunk-OBKM6GIJ.js → chunk-JTUDM7S4.js} +10 -10
  44. package/dist/{chunk-CVVICCSB.js → chunk-L65WI4HO.js} +4 -4
  45. package/dist/{chunk-67D4MN2H.js → chunk-LK6LTSLH.js} +2 -2
  46. package/dist/{chunk-KOHIF4LD.js → chunk-MBODBL7C.js} +6 -5
  47. package/dist/chunk-MTGGOCND.js +638 -0
  48. package/dist/{chunk-VJARCVMH.js → chunk-MU3CJPJF.js} +2 -2
  49. package/dist/{chunk-RKTIIU7Z.js → chunk-N6XI5VTA.js} +4 -4
  50. package/dist/{chunk-ODUT5WMC.js → chunk-NVOU7N6C.js} +2 -2
  51. package/dist/{chunk-T4QXHE34.js → chunk-OWUWLZJT.js} +13 -11
  52. package/dist/{chunk-LDVUPGWC.js → chunk-OWVDD5EC.js} +2 -2
  53. package/dist/{chunk-M4HYPDER.js → chunk-P5OCINCI.js} +8 -8
  54. package/dist/{chunk-JU2VMFYC.js → chunk-PZOFMBF3.js} +2 -2
  55. package/dist/{chunk-YLK3JNWP.js → chunk-QNCXONBR.js} +2 -2
  56. package/dist/{chunk-DB2KQ5DN.js → chunk-QRWY5QTA.js} +5 -5
  57. package/dist/{chunk-I2ATN25N.js → chunk-R4XM44BW.js} +25 -16
  58. package/dist/{chunk-DJCZWQ2A.js → chunk-RTTZIX34.js} +4 -4
  59. package/dist/{chunk-OMTBYLKN.js → chunk-TPKNA2U5.js} +9 -7
  60. package/dist/{chunk-DN5HEDE4.js → chunk-TT5B36WO.js} +16 -20
  61. package/dist/{chunk-SF3JAWMY.js → chunk-TWILCDUE.js} +3 -3
  62. package/dist/{chunk-NIZM3LAG.js → chunk-UINRIO77.js} +10 -10
  63. package/dist/{chunk-5H2LIQIH.js → chunk-UJXCDF4E.js} +4 -4
  64. package/dist/{chunk-Z5ID35YP.js → chunk-UTCPNJND.js} +2 -4
  65. package/dist/{chunk-U42ZEK7L.js → chunk-V4BYBIBU.js} +24 -15
  66. package/dist/{chunk-L4IN4OBB.js → chunk-VLI5SYXW.js} +7 -7
  67. package/dist/{chunk-43E26CDA.js → chunk-VS2M72PF.js} +4 -4
  68. package/dist/{chunk-KZ3PCDUJ.js → chunk-VV6HZQ5K.js} +2 -2
  69. package/dist/{chunk-Z5BTSBWW.js → chunk-WF2HDQPG.js} +4 -4
  70. package/dist/{chunk-TAJ2XFTT.js → chunk-XKMCL2YJ.js} +19 -16
  71. package/dist/{chunk-7GUYGQR4.js → chunk-XVEPB2UU.js} +4 -4
  72. package/dist/{chunk-YHTKDIF2.js → chunk-YGFNITPC.js} +11 -11
  73. package/dist/{chunk-I24O2RWT.js → chunk-YJOOIOSR.js} +84 -14
  74. package/dist/{chunk-KPX2OWZR.js → chunk-YKWHUPBP.js} +13 -14
  75. package/dist/{chunk-FRC4LDTQ.js → chunk-YMYPFX4O.js} +36 -30
  76. package/dist/{chunk-VOJOARA6.js → chunk-ZZXPYVS4.js} +82 -77
  77. package/dist/{dgmo-router-QWRF7ZKM.js → dgmo-router-464FE256.js} +4 -4
  78. package/dist/{dimensions-ES6O2T4H.js → dimensions-ILAVBRQ3.js} +7 -7
  79. package/dist/{flowchart-renderer-EXMRHFTQ.js → flowchart-renderer-6JKM2FA4.js} +7 -7
  80. package/dist/index.js +15 -15
  81. package/dist/{layout-HBWT2G23.js → layout-4LNMXLVK.js} +3 -3
  82. package/dist/{layout-UU4VJTOP.js → layout-62ERBWCM.js} +3 -3
  83. package/dist/{layout-N6X46MWG.js → layout-6SKHNQYO.js} +4 -4
  84. package/dist/{layout-OH4VQ3OI.js → layout-7JULRP4Y.js} +4 -4
  85. package/dist/{layout-QTZO6CW5.js → layout-FA37VP7V.js} +4 -4
  86. package/dist/layout-IN53LAE6.js +9 -0
  87. package/dist/{layout-H4H4OFE4.js → layout-IO6ORC5T.js} +3 -3
  88. package/dist/{layout-54P3DAXY.js → layout-LVMWK4QY.js} +5 -5
  89. package/dist/{layout-WCOEZPOI.js → layout-MNOTDWXW.js} +4 -4
  90. package/dist/{layout-2T2VCCTM.js → layout-RD7GDM4I.js} +5 -5
  91. package/dist/{layout-SKQMIXTG.js → layout-SBQTN2YM.js} +4 -4
  92. package/dist/{layout-5E2NQZNM.js → layout-SGYR6HBX.js} +3 -3
  93. package/dist/{layout-W3ZBJOIK.js → layout-WIMQIHBU.js} +5 -5
  94. package/dist/{layout-search-AJ6VUVUI.js → layout-search-C44CJQOB.js} +5 -5
  95. package/dist/{legend-constants-QQU3QYBF.js → legend-constants-RGINV5SF.js} +3 -3
  96. package/dist/{parser-KSIYWKYF.js → parser-CSKF2KNO.js} +8 -4
  97. package/dist/{parser-2BGDJJ2L.js → parser-WLL63XH7.js} +2 -2
  98. package/dist/{renderer-XLEYPLVL.js → renderer-2UIQVKXK.js} +8 -8
  99. package/dist/{renderer-KOWVTTYR.js → renderer-3GG2DEFQ.js} +7 -7
  100. package/dist/{renderer-XLPNUOYA.js → renderer-6NDYVZXQ.js} +10 -10
  101. package/dist/{renderer-2ARNFXSC.js → renderer-6ST44AVP.js} +10 -10
  102. package/dist/{renderer-YLM4CGBG.js → renderer-ALP46W2X.js} +8 -8
  103. package/dist/{renderer-NHFRVCDC.js → renderer-AOFIEF2T.js} +9 -9
  104. package/dist/{renderer-HLWEJQJW.js → renderer-BEVY3UP5.js} +5 -5
  105. package/dist/{renderer-H6AQ4UIR.js → renderer-BXPWSNTJ.js} +13 -13
  106. package/dist/{renderer-BYWLJDT4.js → renderer-EWTETTII.js} +8 -8
  107. package/dist/{renderer-KK2534AF.js → renderer-FHXAWDNI.js} +4 -4
  108. package/dist/{renderer-OB77AT7V.js → renderer-FI4IKF4I.js} +7 -7
  109. package/dist/{renderer-DMVUBKP7.js → renderer-GHYH6DLG.js} +4 -4
  110. package/dist/{renderer-LSBXYOID.js → renderer-GYYJ4APT.js} +10 -10
  111. package/dist/{renderer-M43ROWET.js → renderer-JFOHE3YB.js} +9 -9
  112. package/dist/{renderer-OA7FSZ4A.js → renderer-L5QGQTLV.js} +3 -3
  113. package/dist/{renderer-7OOC2ZO2.js → renderer-L7S6YVM6.js} +4 -4
  114. package/dist/{renderer-YELZR4QT.js → renderer-LCHVBTV4.js} +12 -12
  115. package/dist/{renderer-IN3UPTZS.js → renderer-M4DAYNWC.js} +3 -3
  116. package/dist/{renderer-WN47AMUM.js → renderer-NXIK3LOA.js} +8 -8
  117. package/dist/{renderer-QR5343AR.js → renderer-OWUXQDHM.js} +3 -3
  118. package/dist/{renderer-FCO42JLK.js → renderer-PJNJOCLB.js} +8 -8
  119. package/dist/{renderer-OYTERGAO.js → renderer-QQBUBD66.js} +9 -9
  120. package/dist/{renderer-PM7JPC3J.js → renderer-REFE3YFH.js} +11 -11
  121. package/dist/{renderer-C6KOE774.js → renderer-RL2JGVPC.js} +10 -10
  122. package/dist/{renderer-ZNTLBQ45.js → renderer-RVFPPKWN.js} +9 -9
  123. package/dist/{renderer-QEHUJHRK.js → renderer-SFQHFPC5.js} +10 -10
  124. package/dist/{renderer-LO4FXQHP.js → renderer-T4CMBGA5.js} +8 -8
  125. package/dist/{renderer-M3PQKXK2.js → renderer-TJD6A3AK.js} +13 -13
  126. package/dist/{renderer-2E7LQC32.js → renderer-URPIVAPI.js} +3 -3
  127. package/dist/{renderer-T5CUGSXP.js → renderer-WENGQEX6.js} +7 -7
  128. package/dist/{renderer-WR3FA3FF.js → renderer-WR6J7NKH.js} +8 -8
  129. package/dist/{renderer-YBEZ5V2H.js → renderer-X3V2G4UL.js} +3 -3
  130. package/dist/{renderer-KPEQ72FY.js → renderer-YAW4VHAI.js} +11 -11
  131. package/dist/{renderer-radial-XWAKJACV.js → renderer-radial-HOUGPUPW.js} +7 -7
  132. package/dist/{state-renderer-LIESKSBO.js → state-renderer-JJSQJZEL.js} +11 -11
  133. package/docs/ai-integration.md +1 -1
  134. package/docs/language-reference.md +5 -0
  135. package/gallery/fixtures/er.dgmo +1 -1
  136. package/package.json +5 -3
  137. package/dist/chunk-4ASYQ347.js +0 -185
  138. package/dist/layout-5XGYNYVT.js +0 -9
@@ -1,10 +1,9 @@
1
1
  import {
2
2
  computeLegendLayout
3
- } from "./chunk-ES66QH6J.js";
3
+ } from "./chunk-FG24NXKN.js";
4
4
  import {
5
- FONT_CENTRAL_DY,
6
5
  FONT_FAMILY
7
- } from "./chunk-Z5ID35YP.js";
6
+ } from "./chunk-UTCPNJND.js";
8
7
  import {
9
8
  CONTROLS_ICON_PATH,
10
9
  LEGEND_DOT_R,
@@ -16,7 +15,7 @@ import {
16
15
  LEGEND_TOGGLE_OFF_OPACITY,
17
16
  legendChromeColors,
18
17
  measureLegendText
19
- } from "./chunk-SCJ7CAJF.js";
18
+ } from "./chunk-3HOCNSPD.js";
20
19
  import {
21
20
  tagAttrKey
22
21
  } from "./chunk-MDI5FMWO.js";
@@ -25,9 +24,8 @@ import {
25
24
  } from "./chunk-42IT4BG2.js";
26
25
 
27
26
  // src/utils/legend-d3.ts
28
- var LEGEND_TEXT_DY = `${FONT_CENTRAL_DY}em`;
29
27
  function centerText(sel) {
30
- return sel.attr("dy", LEGEND_TEXT_DY);
28
+ return sel.attr("dominant-baseline", "central");
31
29
  }
32
30
  function renderLegendD3(container, config, state, palette, isDark, callbacks, containerWidth) {
33
31
  const width = containerWidth ?? parseFloat(container.attr("width") || "800");
@@ -293,4 +291,4 @@ export {
293
291
  renderLegendD3,
294
292
  renderIntegratedLegend
295
293
  };
296
- //# sourceMappingURL=chunk-RBAW7VUG.js.map
294
+ //# sourceMappingURL=chunk-2EPV7CLY.js.map
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  measureText,
3
3
  truncateText
4
- } from "./chunk-4ASYQ347.js";
4
+ } from "./chunk-MTGGOCND.js";
5
5
  import {
6
6
  mix
7
7
  } from "./chunk-42IT4BG2.js";
@@ -59,4 +59,4 @@ export {
59
59
  LEGEND_TOGGLE_OFF_OPACITY,
60
60
  LEGEND_GEAR_PILL_W
61
61
  };
62
- //# sourceMappingURL=chunk-SCJ7CAJF.js.map
62
+ //# sourceMappingURL=chunk-3HOCNSPD.js.map
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  renderIntegratedLegend
3
- } from "./chunk-RBAW7VUG.js";
3
+ } from "./chunk-2EPV7CLY.js";
4
4
  import {
5
5
  FONT_FAMILY
6
- } from "./chunk-Z5ID35YP.js";
6
+ } from "./chunk-UTCPNJND.js";
7
7
  import {
8
8
  getFigure,
9
9
  getPartGeom,
@@ -346,4 +346,4 @@ export {
346
346
  renderBody,
347
347
  renderBodyForExport
348
348
  };
349
- //# sourceMappingURL=chunk-Z2ADWRSW.js.map
349
+ //# sourceMappingURL=chunk-3PSPUYT5.js.map
@@ -1,14 +1,14 @@
1
1
  import {
2
2
  extractExportSvg,
3
3
  runInExportContainer
4
- } from "./chunk-KZ3PCDUJ.js";
4
+ } from "./chunk-VV6HZQ5K.js";
5
5
  import {
6
6
  layoutOrg
7
- } from "./chunk-RKTIIU7Z.js";
7
+ } from "./chunk-N6XI5VTA.js";
8
8
  import {
9
9
  renderCollapseBar,
10
10
  renderNodeCard
11
- } from "./chunk-H3HFC3SQ.js";
11
+ } from "./chunk-5GM6BZO7.js";
12
12
  import {
13
13
  CARD_RADIUS,
14
14
  COLLAPSE_BAR_HEIGHT,
@@ -25,7 +25,7 @@ import {
25
25
  META_LINE_HEIGHT,
26
26
  NODE_STROKE_WIDTH,
27
27
  SEPARATOR_GAP
28
- } from "./chunk-3CIOJ5YJ.js";
28
+ } from "./chunk-FJ57274M.js";
29
29
  import {
30
30
  ScaleContext
31
31
  } from "./chunk-YYVTBZZC.js";
@@ -35,13 +35,13 @@ import {
35
35
  } from "./chunk-A4GOY3PE.js";
36
36
  import {
37
37
  renderIntegratedLegend
38
- } from "./chunk-RBAW7VUG.js";
38
+ } from "./chunk-2EPV7CLY.js";
39
39
  import {
40
40
  getMaxLegendReservedHeight
41
- } from "./chunk-ES66QH6J.js";
41
+ } from "./chunk-FG24NXKN.js";
42
42
  import {
43
43
  FONT_FAMILY
44
- } from "./chunk-Z5ID35YP.js";
44
+ } from "./chunk-UTCPNJND.js";
45
45
  import {
46
46
  EYE_CLOSED_PATH,
47
47
  EYE_OPEN_PATH,
@@ -49,10 +49,10 @@ import {
49
49
  LEGEND_EYE_SIZE,
50
50
  LEGEND_GROUP_GAP,
51
51
  LEGEND_HEIGHT
52
- } from "./chunk-SCJ7CAJF.js";
52
+ } from "./chunk-3HOCNSPD.js";
53
53
  import {
54
54
  measureText
55
- } from "./chunk-4ASYQ347.js";
55
+ } from "./chunk-MTGGOCND.js";
56
56
  import {
57
57
  parseOrg
58
58
  } from "./chunk-CUYDE77F.js";
@@ -207,7 +207,7 @@ function renderOrg(container, parsed, layout, palette, isDark, onClickItem, expo
207
207
  const fill = containerFill(palette, isDark, colorOff ? void 0 : c.color);
208
208
  const stroke = containerStroke(palette, colorOff ? void 0 : c.color);
209
209
  cG.append("rect").attr("x", 0).attr("y", 0).attr("width", c.width).attr("height", c.height).attr("rx", sContainerRadius).attr("fill", fill).attr("stroke", stroke).attr("stroke-opacity", 0.35).attr("stroke-width", sNodeStrokeWidth);
210
- cG.append("text").attr("x", c.width / 2).attr("y", sContainerHeaderHeight / 2 + sContainerLabelFontSize / 2 - 2).attr("text-anchor", "middle").attr("fill", palette.text).attr("font-size", sContainerLabelFontSize).attr("font-weight", "bold").text(c.label);
210
+ cG.append("text").attr("x", c.width / 2).attr("y", sContainerHeaderHeight / 2).attr("dominant-baseline", "central").attr("text-anchor", "middle").attr("fill", palette.text).attr("font-size", sContainerLabelFontSize).attr("font-weight", "bold").text(c.label);
211
211
  const metaEntries = Object.entries(c.metadata);
212
212
  if (metaEntries.length > 0) {
213
213
  const metaDisplayKeys = metaEntries.map(
@@ -485,4 +485,4 @@ export {
485
485
  renderOrg,
486
486
  renderOrgForExport
487
487
  };
488
- //# sourceMappingURL=chunk-RBBJIHNL.js.map
488
+ //# sourceMappingURL=chunk-4IE42ODL.js.map
@@ -4,7 +4,7 @@ import {
4
4
  } from "./chunk-PDKUANDZ.js";
5
5
  import {
6
6
  layoutGraph
7
- } from "./chunk-LSFZDBAP.js";
7
+ } from "./chunk-IKHV5IJB.js";
8
8
  import {
9
9
  appendArrowheadMarkers
10
10
  } from "./chunk-LP7EC4MI.js";
@@ -16,9 +16,10 @@ import {
16
16
  renderNoteConnector
17
17
  } from "./chunk-H52HJ26L.js";
18
18
  import {
19
+ EDGE_LABEL_KNOCKOUT_OPACITY,
19
20
  EDGE_STROKE_WIDTH,
20
21
  NODE_STROKE_WIDTH
21
- } from "./chunk-3CIOJ5YJ.js";
22
+ } from "./chunk-FJ57274M.js";
22
23
  import {
23
24
  ScaleContext
24
25
  } from "./chunk-YYVTBZZC.js";
@@ -32,10 +33,10 @@ import {
32
33
  } from "./chunk-A4GOY3PE.js";
33
34
  import {
34
35
  FONT_FAMILY
35
- } from "./chunk-Z5ID35YP.js";
36
+ } from "./chunk-UTCPNJND.js";
36
37
  import {
37
38
  measureText
38
- } from "./chunk-4ASYQ347.js";
39
+ } from "./chunk-MTGGOCND.js";
39
40
  import {
40
41
  parseFlowchart
41
42
  } from "./chunk-CHOKOYSC.js";
@@ -453,7 +454,7 @@ function renderFlowchart(container, graph, layout, palette, isDark, onClickItem,
453
454
  }
454
455
  const lp = labelPosMap.get(ei);
455
456
  if (edge.label && lp) {
456
- edgeG.append("rect").attr("x", lp.x - lp.w / 2).attr("y", lp.y - lp.h / 2 - 1).attr("width", lp.w).attr("height", lp.h).attr("rx", 3).attr("fill", palette.bg).attr("opacity", 0.85).attr("class", "fc-edge-label-bg");
457
+ edgeG.append("rect").attr("x", lp.x - lp.w / 2).attr("y", lp.y - lp.h / 2 - 1).attr("width", lp.w).attr("height", lp.h).attr("rx", 3).attr("fill", palette.bg).attr("opacity", EDGE_LABEL_KNOCKOUT_OPACITY).attr("class", "fc-edge-label-bg");
457
458
  edgeG.append("text").attr("x", lp.x).attr("y", lp.y + 4).attr("text-anchor", "middle").attr("fill", edgeColor).attr("font-size", sEdgeLabelFontSize).attr("class", "fc-edge-label").text(edge.label);
458
459
  }
459
460
  }
@@ -585,4 +586,4 @@ export {
585
586
  renderFlowchart,
586
587
  renderFlowchartForExport
587
588
  };
588
- //# sourceMappingURL=chunk-SMCUX42K.js.map
589
+ //# sourceMappingURL=chunk-4TM7MWU4.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  measureText
3
- } from "./chunk-4ASYQ347.js";
3
+ } from "./chunk-MTGGOCND.js";
4
4
 
5
5
  // src/utils/card.ts
6
6
  function renderNodeCard(container, opts) {
@@ -17,7 +17,7 @@ function renderNodeCard(container, opts) {
17
17
  container.append("text").attr("x", opts.width / 2).attr("y", startY + li * lineH).attr("text-anchor", "middle").attr("dominant-baseline", "central").attr("fill", opts.labelColor).attr("font-size", opts.labelFontSize).attr("font-weight", "bold").text(labelLines[li]);
18
18
  }
19
19
  } else {
20
- container.append("text").attr("x", opts.width / 2).attr("y", opts.headerHeight / 2 + opts.labelFontSize / 2 - 2).attr("text-anchor", "middle").attr("fill", opts.labelColor).attr("font-size", opts.labelFontSize).attr("font-weight", "bold").text(labelLines?.[0] ?? opts.label);
20
+ container.append("text").attr("x", opts.width / 2).attr("y", opts.headerHeight / 2).attr("dominant-baseline", "central").attr("text-anchor", "middle").attr("fill", opts.labelColor).attr("font-size", opts.labelFontSize).attr("font-weight", "bold").text(labelLines?.[0] ?? opts.label);
21
21
  }
22
22
  const meta = opts.meta;
23
23
  if (!meta || meta.rows.length === 0) return;
@@ -44,4 +44,4 @@ export {
44
44
  renderNodeCard,
45
45
  renderCollapseBar
46
46
  };
47
- //# sourceMappingURL=chunk-H3HFC3SQ.js.map
47
+ //# sourceMappingURL=chunk-5GM6BZO7.js.map
@@ -2,7 +2,7 @@ import {
2
2
  computeQuadrantPointLabels,
3
3
  rectCircleOverlap,
4
4
  rectsOverlap
5
- } from "./chunk-CVVICCSB.js";
5
+ } from "./chunk-L65WI4HO.js";
6
6
  import {
7
7
  EXPORT_HEIGHT,
8
8
  EXPORT_WIDTH,
@@ -11,10 +11,10 @@ import {
11
11
  initD3Chart,
12
12
  renderChartTitle,
13
13
  resolveExportPalette
14
- } from "./chunk-67D4MN2H.js";
14
+ } from "./chunk-LK6LTSLH.js";
15
15
  import {
16
16
  layoutInlineHeader
17
- } from "./chunk-6VJCURWU.js";
17
+ } from "./chunk-J2EXBAPZ.js";
18
18
  import {
19
19
  TITLE_FONT_SIZE,
20
20
  TITLE_FONT_WEIGHT,
@@ -23,21 +23,20 @@ import {
23
23
  } from "./chunk-A4GOY3PE.js";
24
24
  import {
25
25
  computeLegendLayout
26
- } from "./chunk-ES66QH6J.js";
26
+ } from "./chunk-FG24NXKN.js";
27
27
  import {
28
- FONT_CENTRAL_DY,
29
28
  FONT_FAMILY
30
- } from "./chunk-Z5ID35YP.js";
29
+ } from "./chunk-UTCPNJND.js";
31
30
  import {
32
31
  LEGEND_DOT_R,
33
32
  LEGEND_ENTRY_FONT_SIZE,
34
33
  LEGEND_HEIGHT,
35
34
  LEGEND_PILL_FONT_SIZE,
36
35
  legendChromeColors
37
- } from "./chunk-SCJ7CAJF.js";
36
+ } from "./chunk-3HOCNSPD.js";
38
37
  import {
39
38
  measureText
40
- } from "./chunk-4ASYQ347.js";
39
+ } from "./chunk-MTGGOCND.js";
41
40
  import {
42
41
  getExtendedChartLegendGroups,
43
42
  getSimpleChartLegendGroups,
@@ -64,9 +63,7 @@ import {
64
63
  } from "./chunk-42IT4BG2.js";
65
64
 
66
65
  // src/utils/legend-svg.ts
67
- function baselineY(centerY, fontSize) {
68
- return centerY + fontSize * FONT_CENTRAL_DY;
69
- }
66
+ var CENTER = 'dominant-baseline="central"';
70
67
  function esc(s) {
71
68
  return s.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;");
72
69
  }
@@ -81,19 +78,19 @@ function emitCapsule(capsule, palette, groupBg, pillBorder) {
81
78
  `<rect x="${pill.x}" y="${pill.y}" width="${pill.width}" height="${pill.height}" rx="${pill.height / 2}" fill="none" stroke="${esc(pillBorder)}" stroke-width="0.75"/>`
82
79
  );
83
80
  inner.push(
84
- `<text x="${pill.x + pill.width / 2}" y="${baselineY(LEGEND_HEIGHT / 2, LEGEND_PILL_FONT_SIZE)}" font-size="${LEGEND_PILL_FONT_SIZE}" font-weight="500" fill="${esc(palette.text)}" text-anchor="middle" font-family="${esc(FONT_FAMILY)}">${esc(capsule.groupName)}</text>`
81
+ `<text x="${pill.x + pill.width / 2}" y="${LEGEND_HEIGHT / 2}" ${CENTER} font-size="${LEGEND_PILL_FONT_SIZE}" font-weight="500" fill="${esc(palette.text)}" text-anchor="middle" font-family="${esc(FONT_FAMILY)}">${esc(capsule.groupName)}</text>`
85
82
  );
86
83
  for (const entry of capsule.entries) {
87
84
  const label = entry.displayValue ?? entry.value;
88
85
  const hit = entry.width != null ? `<rect x="${entry.x}" y="${entry.y}" width="${entry.width}" height="${LEGEND_HEIGHT}" fill="transparent"/>` : "";
89
86
  inner.push(
90
- `<g data-legend-entry="${esc(entry.value.toLowerCase())}" data-series-name="${esc(entry.value)}" style="cursor:pointer">` + hit + `<circle cx="${entry.dotCx}" cy="${entry.dotCy}" r="${LEGEND_DOT_R}" fill="${esc(entry.color)}"/><text x="${entry.textX}" y="${baselineY(entry.dotCy, LEGEND_ENTRY_FONT_SIZE)}" font-size="${LEGEND_ENTRY_FONT_SIZE}" fill="${esc(palette.textMuted)}" font-family="${esc(FONT_FAMILY)}">${esc(label)}</text></g>`
87
+ `<g data-legend-entry="${esc(entry.value.toLowerCase())}" data-series-name="${esc(entry.value)}" style="cursor:pointer">` + hit + `<circle cx="${entry.dotCx}" cy="${entry.dotCy}" r="${LEGEND_DOT_R}" fill="${esc(entry.color)}"/><text x="${entry.textX}" y="${entry.dotCy}" ${CENTER} font-size="${LEGEND_ENTRY_FONT_SIZE}" fill="${esc(palette.textMuted)}" font-family="${esc(FONT_FAMILY)}">${esc(label)}</text></g>`
91
88
  );
92
89
  }
93
90
  return `<g transform="translate(${capsule.x},${capsule.y})" data-legend-group="${esc(tagAttrKey(capsule.groupName))}" style="cursor:pointer">${inner.join("")}</g>`;
94
91
  }
95
92
  function emitPill(pill, palette, groupBg) {
96
- return `<g transform="translate(${pill.x},${pill.y})" data-legend-group="${esc(tagAttrKey(pill.groupName))}" style="cursor:pointer"><rect width="${pill.width}" height="${pill.height}" rx="${pill.height / 2}" fill="${esc(groupBg)}"/><text x="${pill.width / 2}" y="${baselineY(pill.height / 2, LEGEND_PILL_FONT_SIZE)}" font-size="${LEGEND_PILL_FONT_SIZE}" font-weight="500" fill="${esc(palette.textMuted)}" text-anchor="middle" font-family="${esc(FONT_FAMILY)}">${esc(pill.groupName)}</text></g>`;
93
+ return `<g transform="translate(${pill.x},${pill.y})" data-legend-group="${esc(tagAttrKey(pill.groupName))}" style="cursor:pointer"><rect width="${pill.width}" height="${pill.height}" rx="${pill.height / 2}" fill="${esc(groupBg)}"/><text x="${pill.width / 2}" y="${pill.height / 2}" ${CENTER} font-size="${LEGEND_PILL_FONT_SIZE}" font-weight="500" fill="${esc(palette.textMuted)}" text-anchor="middle" font-family="${esc(FONT_FAMILY)}">${esc(pill.groupName)}</text></g>`;
97
94
  }
98
95
  function renderLegendSvg(groups, options) {
99
96
  if (groups.length === 0) return { svg: "", height: 0, width: 0 };
@@ -1061,7 +1058,9 @@ function renderHeatmap(svg, chart, width, height, palette, isDark, textColor, bg
1061
1058
  const REF = 100;
1062
1059
  const maxValueW = Math.max(
1063
1060
  1,
1064
- ...rows.flatMap((r) => r.values.map((v) => measureText(fmtNum(v), REF)))
1061
+ ...rows.flatMap(
1062
+ (r) => r.values.map((v) => measureText(fmtNum(v), REF, { bold: true }))
1063
+ )
1065
1064
  );
1066
1065
  const cellFont = Math.max(
1067
1066
  11,
@@ -2065,4 +2064,4 @@ export {
2065
2064
  supportsD3DataChart,
2066
2065
  renderDataChartD3
2067
2066
  };
2068
- //# sourceMappingURL=chunk-7T3A2UK3.js.map
2067
+ //# sourceMappingURL=chunk-5T7K6QND.js.map
@@ -14,11 +14,11 @@ import {
14
14
  } from "./chunk-A4GOY3PE.js";
15
15
  import {
16
16
  FONT_FAMILY
17
- } from "./chunk-Z5ID35YP.js";
17
+ } from "./chunk-UTCPNJND.js";
18
18
  import {
19
19
  CHAR_WIDTH_RATIO,
20
20
  measureText
21
- } from "./chunk-4ASYQ347.js";
21
+ } from "./chunk-MTGGOCND.js";
22
22
  import {
23
23
  fillModeFromOptions
24
24
  } from "./chunk-P2PUWV3Y.js";
@@ -181,16 +181,16 @@ function renderRing(container, parsed, palette, isDark, onClickItem, exportDims)
181
181
  }
182
182
  var MAX_LABEL_ARC = 1.6 * Math.PI;
183
183
  function drawRingCurvedLabel(labelG, defs, pathId, text, cx, cy, rMid, labelFont, textColor, palette) {
184
- const PAD = 1.18;
184
+ const PAD = 1.14;
185
185
  let fs = labelFont;
186
186
  let rPath = rMid - fs * 0.32;
187
187
  const maxLen = MAX_LABEL_ARC * rPath;
188
- const wPadded = measureText(text, labelFont) * PAD;
188
+ const wPadded = measureText(text, labelFont, { bold: true }) * PAD;
189
189
  if (wPadded > maxLen) {
190
190
  fs = Math.max(LABEL_FONT_MIN, Math.floor(labelFont * maxLen / wPadded));
191
191
  rPath = rMid - fs * 0.32;
192
192
  }
193
- const arcLen = measureText(text, fs) * PAD;
193
+ const arcLen = measureText(text, fs, { bold: true }) * PAD;
194
194
  const halfAngle = Math.min(arcLen / (2 * rPath), MAX_LABEL_ARC / 2);
195
195
  const largeArc = halfAngle * 2 > Math.PI ? 1 : 0;
196
196
  const p0x = cx - Math.sin(halfAngle) * rPath;
@@ -296,4 +296,4 @@ export {
296
296
  renderRing,
297
297
  renderRingForExport
298
298
  };
299
- //# sourceMappingURL=chunk-NKRCPBTJ.js.map
299
+ //# sourceMappingURL=chunk-6BOPYGJC.js.map
@@ -8,7 +8,7 @@ import {
8
8
  rectCircleOverlap,
9
9
  rectsOverlap,
10
10
  segmentRectOverlap
11
- } from "./chunk-CVVICCSB.js";
11
+ } from "./chunk-L65WI4HO.js";
12
12
  import {
13
13
  TITLE_FONT_SIZE,
14
14
  TITLE_Y
@@ -16,10 +16,10 @@ import {
16
16
  import {
17
17
  compactNumber,
18
18
  computeLegendLayout
19
- } from "./chunk-ES66QH6J.js";
19
+ } from "./chunk-FG24NXKN.js";
20
20
  import {
21
21
  measureLegendText
22
- } from "./chunk-SCJ7CAJF.js";
22
+ } from "./chunk-3HOCNSPD.js";
23
23
  import {
24
24
  tagAttrKey
25
25
  } from "./chunk-MDI5FMWO.js";
@@ -1036,6 +1036,20 @@ function createLabelMetrics(size) {
1036
1036
  };
1037
1037
  }
1038
1038
 
1039
+ // src/map/layout-constants.ts
1040
+ var FIT_PAD = 24;
1041
+ var WORLD_LABEL_ANCHORS = {
1042
+ US: [-98.5, 39.5],
1043
+ // CONUS geographic centre (near Lebanon, Kansas)
1044
+ // Russia crosses the antimeridian (Chukotka at ~170°W), so on a non-global
1045
+ // (e.g. Europe) projection its geometry smears across the whole frame and the
1046
+ // area-weighted centroid lands mid-map (over Europe) — useless as a label
1047
+ // anchor. Pin it to European Russia (~Volga) so a Europe view labels visible
1048
+ // western Russia on its eastern margin; on a world view this still sits over
1049
+ // Russian land. (See the curated-anchor smear-gate bypass in context-labels.)
1050
+ RU: [45, 58]
1051
+ };
1052
+
1039
1053
  // src/map/region-labels.ts
1040
1054
  function placeRegionLabels(args) {
1041
1055
  const {
@@ -1438,7 +1452,6 @@ function placeRegionLabels(args) {
1438
1452
  }
1439
1453
 
1440
1454
  // src/map/layout.ts
1441
- var FIT_PAD = 24;
1442
1455
  var PATH_DIGITS = 1;
1443
1456
  var THIN_TOL = 0.6;
1444
1457
  var ALBERS_SKEW_MAX = 1.25;
@@ -1483,17 +1496,6 @@ var R_MIN = 4;
1483
1496
  var R_MAX = 22;
1484
1497
  var POI_FILL_OPACITY_MAX = 0.92;
1485
1498
  var POI_FILL_OPACITY_MIN = 0.55;
1486
- var WORLD_LABEL_ANCHORS = {
1487
- US: [-98.5, 39.5],
1488
- // CONUS geographic centre (near Lebanon, Kansas)
1489
- // Russia crosses the antimeridian (Chukotka at ~170°W), so on a non-global
1490
- // (e.g. Europe) projection its geometry smears across the whole frame and the
1491
- // area-weighted centroid lands mid-map (over Europe) — useless as a label
1492
- // anchor. Pin it to European Russia (~Volga) so a Europe view labels visible
1493
- // western Russia on its eastern margin; on a world view this still sits over
1494
- // Russian land. (See the curated-anchor smear-gate bypass in context-labels.)
1495
- RU: [45, 58]
1496
- };
1497
1499
  var MAX_CLUSTER_EXTENT_FACTOR = 0.18;
1498
1500
  var MAX_COLUMN_ROWS = 7;
1499
1501
  var REGION_LABEL_HALO_RATIO = 4.5;
@@ -3363,4 +3365,4 @@ export {
3363
3365
  albersSkewFallback,
3364
3366
  layoutMap
3365
3367
  };
3366
- //# sourceMappingURL=chunk-37EHGTQ2.js.map
3368
+ //# sourceMappingURL=chunk-6E5YZR4S.js.map
@@ -9,7 +9,7 @@ import {
9
9
  } from "./chunk-YYVTBZZC.js";
10
10
  import {
11
11
  layoutInlineHeader
12
- } from "./chunk-6VJCURWU.js";
12
+ } from "./chunk-J2EXBAPZ.js";
13
13
  import {
14
14
  TITLE_FONT_SIZE,
15
15
  TITLE_FONT_WEIGHT,
@@ -17,18 +17,18 @@ import {
17
17
  } from "./chunk-A4GOY3PE.js";
18
18
  import {
19
19
  renderIntegratedLegend
20
- } from "./chunk-RBAW7VUG.js";
20
+ } from "./chunk-2EPV7CLY.js";
21
21
  import {
22
22
  getLegendExtent,
23
23
  getMaxLegendReservedHeight
24
- } from "./chunk-ES66QH6J.js";
24
+ } from "./chunk-FG24NXKN.js";
25
25
  import {
26
26
  FONT_FAMILY
27
- } from "./chunk-Z5ID35YP.js";
27
+ } from "./chunk-UTCPNJND.js";
28
28
  import {
29
29
  measureText,
30
30
  truncateText
31
- } from "./chunk-4ASYQ347.js";
31
+ } from "./chunk-MTGGOCND.js";
32
32
  import {
33
33
  isSequenceBlock,
34
34
  isSequenceNote,
@@ -1645,7 +1645,10 @@ function renderSequenceDiagram(container, parsed, palette, isDark, _onNavigateTo
1645
1645
  const msgCount = sectionMsgCounts.get(sec.lineNumber) ?? 0;
1646
1646
  const labelText = isCollapsed ? `${sec.label} (${msgCount} ${msgCount === 1 ? "message" : "messages"})` : sec.label;
1647
1647
  const labelX = (sectionLineX1 + sectionLineX2) / 2;
1648
- const labelHitW = Math.max(80, measureText(labelText, 11) + 24);
1648
+ const labelHitW = Math.max(
1649
+ 80,
1650
+ measureText(labelText, 11, { bold: true }) + 24
1651
+ );
1649
1652
  sectionG.append("rect").attr("x", labelX - labelHitW / 2).attr("y", secY - BAND_HEIGHT / 2).attr("width", labelHitW).attr("height", BAND_HEIGHT).attr("fill", "transparent").attr("class", "section-label-hit");
1650
1653
  sectionG.append("text").attr("x", labelX).attr("y", secY + 4).attr("text-anchor", "middle").attr("fill", lineColor).attr("font-size", 11).attr("font-weight", "bold").attr("class", "section-label").text(labelText);
1651
1654
  }
@@ -1907,4 +1910,4 @@ export {
1907
1910
  renderSequenceDiagram,
1908
1911
  buildNoteMessageMap
1909
1912
  };
1910
- //# sourceMappingURL=chunk-MHI6W6XS.js.map
1913
+ //# sourceMappingURL=chunk-6IUL6LER.js.map
@@ -1,16 +1,16 @@
1
1
  import {
2
2
  FONT_FAMILY
3
- } from "./chunk-Z5ID35YP.js";
3
+ } from "./chunk-UTCPNJND.js";
4
4
  import {
5
5
  measureText,
6
6
  truncateText
7
- } from "./chunk-4ASYQ347.js";
7
+ } from "./chunk-MTGGOCND.js";
8
8
  import {
9
9
  encodeDiagramUrl
10
10
  } from "./chunk-U7VO6JAA.js";
11
11
  import {
12
12
  parseDgmoChartType
13
- } from "./chunk-AA4M6F2P.js";
13
+ } from "./chunk-BBY57XAA.js";
14
14
  import {
15
15
  chartTypes
16
16
  } from "./chunk-P2PUWV3Y.js";
@@ -204,4 +204,4 @@ export {
204
204
  MONO_FAMILY,
205
205
  renderErrorCard
206
206
  };
207
- //# sourceMappingURL=chunk-S5RWWISJ.js.map
207
+ //# sourceMappingURL=chunk-7L53J53J.js.map
@@ -9,7 +9,7 @@ import {
9
9
  } from "./chunk-A4GOY3PE.js";
10
10
  import {
11
11
  FONT_FAMILY
12
- } from "./chunk-Z5ID35YP.js";
12
+ } from "./chunk-UTCPNJND.js";
13
13
  import {
14
14
  getSeriesColors,
15
15
  mix,
@@ -361,4 +361,4 @@ export {
361
361
  renderGoal,
362
362
  renderGoalForExport
363
363
  };
364
- //# sourceMappingURL=chunk-WDJ4HAGO.js.map
364
+ //# sourceMappingURL=chunk-A6CTYC7O.js.map
@@ -3,7 +3,7 @@ import {
3
3
  } from "./chunk-FWVKPEG3.js";
4
4
  import {
5
5
  FONT_FAMILY
6
- } from "./chunk-Z5ID35YP.js";
6
+ } from "./chunk-UTCPNJND.js";
7
7
  import {
8
8
  fixedParts,
9
9
  fixedTimeCells,
@@ -558,4 +558,4 @@ export {
558
558
  renderClock,
559
559
  renderClockForExport
560
560
  };
561
- //# sourceMappingURL=chunk-CDMF7P5A.js.map
561
+ //# sourceMappingURL=chunk-BBCKUAUR.js.map
@@ -72,7 +72,7 @@ import {
72
72
  import {
73
73
  isLiveLinkLine,
74
74
  parseLiveLink
75
- } from "./chunk-6BVIZW5N.js";
75
+ } from "./chunk-FLFBY5GN.js";
76
76
  import {
77
77
  parseEventLine
78
78
  } from "./chunk-QMYJO4EL.js";
@@ -119,7 +119,7 @@ import {
119
119
  import {
120
120
  looksLikeERDiagram,
121
121
  parseERDiagram
122
- } from "./chunk-NKRVFQGO.js";
122
+ } from "./chunk-BDI25HWH.js";
123
123
  import {
124
124
  looksLikeOrg,
125
125
  parseOrg
@@ -2031,4 +2031,4 @@ export {
2031
2031
  knownChartTypeIds,
2032
2032
  parseDgmo
2033
2033
  };
2034
- //# sourceMappingURL=chunk-AA4M6F2P.js.map
2034
+ //# sourceMappingURL=chunk-BBY57XAA.js.map
@@ -109,11 +109,13 @@ function parseRelationship(trimmed, lineNumber, pushError) {
109
109
  }
110
110
  function parseColumn(trimmed) {
111
111
  const rawTokens = tokenizeQuoteAware(trimmed);
112
- if (rawTokens.length === 0) return null;
112
+ if (rawTokens.length === 0) return { ok: false, reason: "not-a-column" };
113
113
  const firstRaw = rawTokens[0];
114
114
  const wasQuoted = firstRaw.startsWith('"') || firstRaw.startsWith("'");
115
115
  const name = stripQuotes(firstRaw);
116
- if (!wasQuoted && !/^\w+$/.test(name)) return null;
116
+ if (!wasQuoted && !/^\w+$/.test(name)) {
117
+ return { ok: false, reason: "not-a-column" };
118
+ }
117
119
  const constraints = [];
118
120
  let type;
119
121
  for (let i = 1; i < rawTokens.length; i++) {
@@ -125,10 +127,10 @@ function parseColumn(trimmed) {
125
127
  } else if (type === void 0) {
126
128
  type = tok;
127
129
  } else {
128
- return null;
130
+ return { ok: false, reason: "unknown-token", name, token: tok };
129
131
  }
130
132
  }
131
- return { name, ...type !== void 0 && { type }, constraints };
133
+ return { ok: true, name, ...type !== void 0 && { type }, constraints };
132
134
  }
133
135
  function parseERDiagram(content, palette) {
134
136
  const lines = content.split("\n");
@@ -315,13 +317,23 @@ function parseERDiagram(content, palette) {
315
317
  continue;
316
318
  }
317
319
  const colResult = parseColumn(trimmed);
318
- if (colResult) {
320
+ if (colResult.ok) {
319
321
  currentTable.columns.push({
320
322
  name: colResult.name,
321
323
  ...colResult.type && { type: colResult.type },
322
324
  constraints: colResult.constraints,
323
325
  lineNumber
324
326
  });
327
+ } else if (colResult.reason === "unknown-token") {
328
+ pushError(
329
+ lineNumber,
330
+ colResult.token.includes(",") ? `Column constraints are space-separated, not comma-separated. Write "${colResult.name} ${colResult.token.replace(/,+$/, "")} \u2026" without the comma.` : `Unexpected "${colResult.token}" in column "${colResult.name}". A column is: name [type] [pk|fk|unique|nullable]`
331
+ );
332
+ } else {
333
+ pushError(
334
+ lineNumber,
335
+ `"${trimmed}" is neither a column nor a relationship. A column is: name [type] [pk|fk|unique|nullable]. A relationship is: 1-label-* target`
336
+ );
325
337
  }
326
338
  continue;
327
339
  }
@@ -521,4 +533,4 @@ export {
521
533
  looksLikeERDiagram,
522
534
  extractSymbols
523
535
  };
524
- //# sourceMappingURL=chunk-NKRVFQGO.js.map
536
+ //# sourceMappingURL=chunk-BDI25HWH.js.map