@diagrammo/dgmo 0.24.0 → 0.25.1

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.
package/dist/auto.cjs CHANGED
@@ -743,7 +743,7 @@ function withTagAliases(base, aliases) {
743
743
  function isReservedKey(registry, key) {
744
744
  return registry.keys.has(key) || registry.tagAliases.has(key);
745
745
  }
746
- var SEQUENCE_REGISTRY, INFRA_REGISTRY, MAP_REGISTRY, ORG_REGISTRY, C4_REGISTRY, ER_REGISTRY, CLASS_REGISTRY, KANBAN_REGISTRY, SITEMAP_REGISTRY, GANTT_REGISTRY, PERT_REGISTRY, BOXES_AND_LINES_REGISTRY, TIMELINE_REGISTRY, MINDMAP_REGISTRY, TECH_RADAR_REGISTRY, CYCLE_REGISTRY, JOURNEY_MAP_REGISTRY, PYRAMID_REGISTRY, RING_REGISTRY, RACI_REGISTRY, WIREFRAME_REGISTRY;
746
+ var SEQUENCE_REGISTRY, INFRA_REGISTRY, MAP_REGISTRY, ORG_REGISTRY, C4_REGISTRY, ER_REGISTRY, KANBAN_REGISTRY, SITEMAP_REGISTRY, GANTT_REGISTRY, PERT_REGISTRY, BOXES_AND_LINES_REGISTRY, TIMELINE_REGISTRY, MINDMAP_REGISTRY, TECH_RADAR_REGISTRY, CYCLE_REGISTRY, JOURNEY_MAP_REGISTRY, PYRAMID_REGISTRY, RING_REGISTRY, RACI_REGISTRY;
747
747
  var init_reserved_key_registry = __esm({
748
748
  "src/utils/reserved-key-registry.ts"() {
749
749
  "use strict";
@@ -787,10 +787,6 @@ var init_reserved_key_registry = __esm({
787
787
  "description",
788
788
  "domain"
789
789
  ]);
790
- CLASS_REGISTRY = staticRegistry([
791
- "color",
792
- "description"
793
- ]);
794
790
  KANBAN_REGISTRY = staticRegistry([
795
791
  "color",
796
792
  "description",
@@ -866,7 +862,6 @@ var init_reserved_key_registry = __esm({
866
862
  "color",
867
863
  "description"
868
864
  ]);
869
- WIREFRAME_REGISTRY = staticRegistry([]);
870
865
  }
871
866
  });
872
867
 
@@ -4135,6 +4130,9 @@ var init_legend_layout = __esm({
4135
4130
  });
4136
4131
 
4137
4132
  // src/utils/legend-d3.ts
4133
+ function centerText(sel) {
4134
+ return sel.attr("dy", LEGEND_TEXT_DY);
4135
+ }
4138
4136
  function renderLegendD3(container, config, state, palette, isDark, callbacks, containerWidth) {
4139
4137
  const width = containerWidth ?? parseFloat(container.attr("width") || "800");
4140
4138
  let currentState = { ...state };
@@ -4217,21 +4215,21 @@ function renderCapsule(parent, capsule, palette, groupBg, pillBorder, _isDark, c
4217
4215
  const pill = capsule.pill;
4218
4216
  g.append("rect").attr("x", pill.x).attr("y", pill.y).attr("width", pill.width).attr("height", pill.height).attr("rx", pill.height / 2).attr("fill", palette.bg);
4219
4217
  g.append("rect").attr("x", pill.x).attr("y", pill.y).attr("width", pill.width).attr("height", pill.height).attr("rx", pill.height / 2).attr("fill", "none").attr("stroke", pillBorder).attr("stroke-width", 0.75);
4220
- g.append("text").attr("x", pill.x + pill.width / 2).attr("y", LEGEND_HEIGHT / 2).attr("text-anchor", "middle").attr("dominant-baseline", "central").attr("font-size", LEGEND_PILL_FONT_SIZE).attr("font-weight", 500).attr("fill", palette.text).attr("pointer-events", "none").attr("font-family", FONT_FAMILY).text(capsule.groupName);
4218
+ g.append("text").attr("x", pill.x + pill.width / 2).attr("y", LEGEND_HEIGHT / 2).attr("text-anchor", "middle").call(centerText).attr("font-size", LEGEND_PILL_FONT_SIZE).attr("font-weight", 500).attr("fill", palette.text).attr("pointer-events", "none").attr("font-family", FONT_FAMILY).text(capsule.groupName);
4221
4219
  if (capsule.gradient) {
4222
4220
  const gr = capsule.gradient;
4223
4221
  const gradId = `dgmo-legend-ramp-${capsule.groupName.toLowerCase().replace(/[^a-z0-9]+/g, "-")}`;
4224
4222
  const def = g.append("defs").append("linearGradient").attr("id", gradId);
4225
4223
  def.append("stop").attr("offset", "0%").attr("stop-color", mix(gr.hue, gr.base, 15));
4226
4224
  def.append("stop").attr("offset", "100%").attr("stop-color", gr.hue);
4227
- g.append("text").attr("x", gr.minX).attr("y", gr.textY).attr("dominant-baseline", "central").attr("font-size", LEGEND_ENTRY_FONT_SIZE).attr("fill", palette.textMuted).attr("pointer-events", "none").attr("font-family", FONT_FAMILY).text(gr.minText);
4225
+ g.append("text").attr("x", gr.minX).attr("y", gr.textY).call(centerText).attr("font-size", LEGEND_ENTRY_FONT_SIZE).attr("fill", palette.textMuted).attr("pointer-events", "none").attr("font-family", FONT_FAMILY).text(gr.minText);
4228
4226
  g.append("rect").attr("class", "dgmo-legend-gradient-ramp").attr("data-ramp-min", gr.min).attr("data-ramp-max", gr.max).attr("x", gr.rampX).attr("y", gr.rampY).attr("width", gr.rampW).attr("height", gr.rampH).attr("rx", 2).attr("fill", `url(#${gradId})`);
4229
- g.append("text").attr("x", gr.maxX).attr("y", gr.textY).attr("dominant-baseline", "central").attr("font-size", LEGEND_ENTRY_FONT_SIZE).attr("fill", palette.textMuted).attr("pointer-events", "none").attr("font-family", FONT_FAMILY).text(gr.maxText);
4227
+ g.append("text").attr("x", gr.maxX).attr("y", gr.textY).call(centerText).attr("font-size", LEGEND_ENTRY_FONT_SIZE).attr("fill", palette.textMuted).attr("pointer-events", "none").attr("font-family", FONT_FAMILY).text(gr.maxText);
4230
4228
  }
4231
4229
  for (const entry of capsule.entries) {
4232
4230
  const entryG = g.append("g").attr("data-legend-entry", entry.value.toLowerCase()).attr("data-series-name", entry.value).style("cursor", "pointer");
4233
4231
  entryG.append("circle").attr("cx", entry.dotCx).attr("cy", entry.dotCy).attr("r", LEGEND_DOT_R).attr("fill", entry.color);
4234
- entryG.append("text").attr("x", entry.textX).attr("y", entry.textY).attr("dominant-baseline", "central").attr("font-size", LEGEND_ENTRY_FONT_SIZE).attr("fill", palette.textMuted).attr("font-family", FONT_FAMILY).text(entry.displayValue ?? entry.value);
4232
+ entryG.append("text").attr("x", entry.textX).attr("y", entry.textY).call(centerText).attr("font-size", LEGEND_ENTRY_FONT_SIZE).attr("fill", palette.textMuted).attr("font-family", FONT_FAMILY).text(entry.displayValue ?? entry.value);
4235
4233
  if (callbacks?.onEntryHover) {
4236
4234
  const groupName = capsule.groupName;
4237
4235
  const entryValue = entry.value;
@@ -4251,7 +4249,7 @@ function renderCapsule(parent, capsule, palette, groupBg, pillBorder, _isDark, c
4251
4249
  function renderPill(parent, pill, palette, groupBg, callbacks) {
4252
4250
  const g = parent.append("g").attr("transform", `translate(${pill.x},${pill.y})`).attr("data-legend-group", pill.groupName.toLowerCase()).style("cursor", "pointer");
4253
4251
  g.append("rect").attr("width", pill.width).attr("height", pill.height).attr("rx", pill.height / 2).attr("fill", groupBg);
4254
- g.append("text").attr("x", pill.width / 2).attr("y", pill.height / 2).attr("text-anchor", "middle").attr("dominant-baseline", "central").attr("font-size", LEGEND_PILL_FONT_SIZE).attr("font-weight", 500).attr("fill", palette.textMuted).attr("pointer-events", "none").attr("font-family", FONT_FAMILY).text(pill.groupName);
4252
+ g.append("text").attr("x", pill.width / 2).attr("y", pill.height / 2).attr("text-anchor", "middle").call(centerText).attr("font-size", LEGEND_PILL_FONT_SIZE).attr("font-weight", 500).attr("fill", palette.textMuted).attr("pointer-events", "none").attr("font-family", FONT_FAMILY).text(pill.groupName);
4255
4253
  if (callbacks?.onGroupToggle) {
4256
4254
  const cb = callbacks.onGroupToggle;
4257
4255
  const name = pill.groupName;
@@ -4274,7 +4272,7 @@ function renderControl(parent, ctrl, palette, _groupBg, pillBorder, _isDark, con
4274
4272
  textX = 8 + 14 + LEGEND_ENTRY_DOT_GAP + measureLegendText(ctrl.label, LEGEND_PILL_FONT_SIZE) / 2;
4275
4273
  }
4276
4274
  if (ctrl.label) {
4277
- g.append("text").attr("x", textX).attr("y", ctrl.height / 2).attr("text-anchor", "middle").attr("dominant-baseline", "central").attr("font-size", LEGEND_PILL_FONT_SIZE).attr("font-weight", 500).attr("fill", palette.textMuted).attr("pointer-events", "none").attr("font-family", FONT_FAMILY).text(ctrl.label);
4275
+ g.append("text").attr("x", textX).attr("y", ctrl.height / 2).attr("text-anchor", "middle").call(centerText).attr("font-size", LEGEND_PILL_FONT_SIZE).attr("font-weight", 500).attr("fill", palette.textMuted).attr("pointer-events", "none").attr("font-family", FONT_FAMILY).text(ctrl.label);
4278
4276
  }
4279
4277
  if (ctrl.children) {
4280
4278
  let cx = ctrl.width + 4;
@@ -4284,7 +4282,7 @@ function renderControl(parent, ctrl, palette, _groupBg, pillBorder, _isDark, con
4284
4282
  "fill",
4285
4283
  child.isActive ? palette.primary ?? palette.text : "none"
4286
4284
  ).attr("stroke", pillBorder).attr("stroke-width", 0.75);
4287
- childG.append("text").attr("x", child.width / 2).attr("y", ctrl.height / 2).attr("text-anchor", "middle").attr("dominant-baseline", "central").attr("font-size", LEGEND_ENTRY_FONT_SIZE).attr("fill", child.isActive ? palette.bg : palette.textMuted).attr("font-family", FONT_FAMILY).text(child.label);
4285
+ childG.append("text").attr("x", child.width / 2).attr("y", ctrl.height / 2).attr("text-anchor", "middle").call(centerText).attr("font-size", LEGEND_ENTRY_FONT_SIZE).attr("fill", child.isActive ? palette.bg : palette.textMuted).attr("font-family", FONT_FAMILY).text(child.label);
4288
4286
  const configCtrl2 = configControls?.find((c) => c.id === ctrl.id);
4289
4287
  const configChild = configCtrl2?.children?.find((c) => c.id === child.id);
4290
4288
  if (configChild?.onClick) {
@@ -4338,7 +4336,7 @@ function renderControlsGroup(parent, layout, palette, groupBg, pillBorder, callb
4338
4336
  } else {
4339
4337
  entryG.append("circle").attr("cx", tl.dotCx).attr("cy", tl.dotCy).attr("r", LEGEND_TOGGLE_DOT_R).attr("fill", "none").attr("stroke", palette.textMuted).attr("stroke-width", 1);
4340
4338
  }
4341
- entryG.append("text").attr("x", tl.textX).attr("y", tl.textY).attr("dominant-baseline", "central").attr("font-size", LEGEND_ENTRY_FONT_SIZE).attr("fill", palette.textMuted).attr("opacity", tl.active ? 1 : LEGEND_TOGGLE_OFF_OPACITY).attr("font-family", FONT_FAMILY).text(tl.label);
4339
+ entryG.append("text").attr("x", tl.textX).attr("y", tl.textY).call(centerText).attr("font-size", LEGEND_ENTRY_FONT_SIZE).attr("fill", palette.textMuted).attr("opacity", tl.active ? 1 : LEGEND_TOGGLE_OFF_OPACITY).attr("font-family", FONT_FAMILY).text(tl.label);
4342
4340
  if (callbacks?.onControlsToggle && toggle) {
4343
4341
  const cb = callbacks.onControlsToggle;
4344
4342
  const id = tl.id;
@@ -4351,6 +4349,7 @@ function renderControlsGroup(parent, layout, palette, groupBg, pillBorder, callb
4351
4349
  }
4352
4350
  }
4353
4351
  }
4352
+ var LEGEND_TEXT_DY;
4354
4353
  var init_legend_d3 = __esm({
4355
4354
  "src/utils/legend-d3.ts"() {
4356
4355
  "use strict";
@@ -4358,6 +4357,7 @@ var init_legend_d3 = __esm({
4358
4357
  init_legend_layout();
4359
4358
  init_color_utils();
4360
4359
  init_fonts();
4360
+ LEGEND_TEXT_DY = "0.32em";
4361
4361
  }
4362
4362
  });
4363
4363
 
@@ -4608,7 +4608,6 @@ var init_arrows = __esm({
4608
4608
  var parser_exports = {};
4609
4609
  __export(parser_exports, {
4610
4610
  isSequenceBlock: () => isSequenceBlock,
4611
- isSequenceMessage: () => isSequenceMessage,
4612
4611
  isSequenceNote: () => isSequenceNote,
4613
4612
  isSequenceSection: () => isSequenceSection,
4614
4613
  looksLikeSequence: () => looksLikeSequence,
@@ -4624,9 +4623,6 @@ function isHardRemovedToken(remainder) {
4624
4623
  }
4625
4624
  return { removed: false };
4626
4625
  }
4627
- function isSequenceMessage(el) {
4628
- return el.kind === "message";
4629
- }
4630
4626
  function isSequenceBlock(el) {
4631
4627
  return el.kind === "block";
4632
4628
  }
@@ -16316,6 +16312,9 @@ function parseMap(content) {
16316
16312
  break;
16317
16313
  // ── Cosmetic `no-*` opt-outs: bare flags, idempotent (mirror `no-legend`,
16318
16314
  // no dup warning); each defaults the feature ON when absent. ──
16315
+ case "no-title":
16316
+ d.noTitle = true;
16317
+ break;
16319
16318
  case "no-legend":
16320
16319
  d.noLegend = true;
16321
16320
  break;
@@ -16337,6 +16336,9 @@ function parseMap(content) {
16337
16336
  case "no-colorize":
16338
16337
  d.noColorize = true;
16339
16338
  break;
16339
+ case "no-cluster-pois":
16340
+ d.noClusterPois = true;
16341
+ break;
16340
16342
  }
16341
16343
  }
16342
16344
  function handleTag(trimmed, line12) {
@@ -16638,13 +16640,15 @@ var init_parser12 = __esm({
16638
16640
  "locale",
16639
16641
  "active-tag",
16640
16642
  "caption",
16643
+ "no-title",
16641
16644
  "no-legend",
16642
16645
  "no-coastline",
16643
16646
  "no-relief",
16644
16647
  "no-context-labels",
16645
16648
  "no-region-labels",
16646
16649
  "no-poi-labels",
16647
- "no-colorize"
16650
+ "no-colorize",
16651
+ "no-cluster-pois"
16648
16652
  ]);
16649
16653
  }
16650
16654
  });
@@ -37354,18 +37358,10 @@ var init_layout11 = __esm({
37354
37358
  // src/pert/renderer.ts
37355
37359
  var renderer_exports11 = {};
37356
37360
  __export(renderer_exports11, {
37357
- PERT_LEGEND_PILL_HEIGHT: () => PERT_LEGEND_PILL_HEIGHT,
37358
- highlightPertCriticalPath: () => highlightPertCriticalPath,
37359
- highlightPertSet: () => highlightPertSet,
37360
37361
  measurePertAnalysisBlock: () => measurePertAnalysisBlock,
37361
- pertLegendBlockWidth: () => pertLegendBlockWidth,
37362
- pertLegendEntries: () => pertLegendEntries,
37363
- renderLegendBlock: () => renderLegendBlock,
37364
37362
  renderPert: () => renderPert,
37365
37363
  renderPertAnalysisBlock: () => renderPertAnalysisBlock,
37366
- renderPertForExport: () => renderPertForExport,
37367
- resetPertCriticalPath: () => resetPertCriticalPath,
37368
- resetPertHighlight: () => resetPertHighlight
37364
+ renderPertForExport: () => renderPertForExport
37369
37365
  });
37370
37366
  function analysisBlockChrome(palette, isDark) {
37371
37367
  const surfaceBg = isDark ? palette.surface : palette.bg;
@@ -37448,16 +37444,14 @@ function renderPert(container, resolved, layout, palette, isDark, options = {})
37448
37444
  const standaloneFieldLegendWidthForExport = layout.width;
37449
37445
  const analysisBlockHeight = analysisLayer.analysisHasContent ? CAPTION_TOP_GAP + analysisLayer.analysisRowHeight : 0;
37450
37446
  const fieldLegendBlockHeight = analysisLayer.fieldLegendStandalone ? CAPTION_TOP_GAP + fieldLegendHeightFor(standaloneFieldLegendWidthForExport) : 0;
37451
- const showTopLegend = options.showTopLegend ?? true;
37452
- const legendEntries = showTopLegend ? pertLegendEntries(resolved) : [];
37447
+ const showLegend = options.showLegend ?? true;
37453
37448
  const tagLegendActive = resolveActiveTagGroup(
37454
37449
  resolved.tagGroups,
37455
37450
  resolved.options.activeTag,
37456
37451
  options.activeTagOverride
37457
37452
  );
37458
- const showTagLegend = showTopLegend && resolved.tagGroups.length > 0;
37459
- const tagLegendBlockHeight = showTagLegend ? LEGEND_PILL_HEIGHT + LEGEND_BOTTOM_GAP : 0;
37460
- const legendBlockHeight = (legendEntries.length > 0 ? LEGEND_TOP_GAP + LEGEND_PILL_HEIGHT + LEGEND_BOTTOM_GAP : 0) + tagLegendBlockHeight;
37453
+ const showTagLegend = showLegend && resolved.tagGroups.length > 0;
37454
+ const legendBlockHeight = showTagLegend ? LEGEND_TOP_GAP + LEGEND_PILL_HEIGHT + LEGEND_BOTTOM_GAP : 0;
37461
37455
  const naturalChartWidth = layout.width + DIAGRAM_PADDING11 * 2;
37462
37456
  const minAnalysisRowW = analysisLayer.analysisHasContent ? analysisLayer.minContentWidth + 2 * DIAGRAM_PADDING11 : 0;
37463
37457
  const naturalWidth = Math.max(naturalChartWidth, minAnalysisRowW);
@@ -37480,8 +37474,7 @@ function renderPert(container, resolved, layout, palette, isDark, options = {})
37480
37474
  const sLegendTopGap = ctx.aesthetic(LEGEND_TOP_GAP);
37481
37475
  const sLegendBottomGap = ctx.aesthetic(LEGEND_BOTTOM_GAP);
37482
37476
  const sLegendPillHeight = ctx.structural(LEGEND_PILL_HEIGHT);
37483
- const sTagLegendBlockHeight = showTagLegend ? sLegendPillHeight + sLegendBottomGap : 0;
37484
- const sLegendBlockHeight = (legendEntries.length > 0 ? sLegendTopGap + sLegendPillHeight + sLegendBottomGap : 0) + sTagLegendBlockHeight;
37477
+ const sLegendBlockHeight = showTagLegend ? sLegendTopGap + sLegendPillHeight + sLegendBottomGap : 0;
37485
37478
  const sNodeRadius = ctx.structural(NODE_RADIUS2);
37486
37479
  const sNodeStrokeWidth = ctx.structural(NODE_STROKE_WIDTH10);
37487
37480
  const sNodeFontSize = ctx.text(NODE_FONT_SIZE4);
@@ -37513,17 +37506,8 @@ function renderPert(container, resolved, layout, palette, isDark, options = {})
37513
37506
  }
37514
37507
  const offsetX = Math.max(sDiagramPad, (svgW - layout.width) / 2);
37515
37508
  const offsetY = sDiagramPad + sTitleHeight + sLegendBlockHeight;
37516
- if (legendEntries.length > 0) {
37517
- renderLegendBlock(svg, legendEntries, {
37518
- x: 0,
37519
- y: sDiagramPad + sTitleHeight + sLegendTopGap,
37520
- width: svgW,
37521
- palette,
37522
- isDark
37523
- });
37524
- }
37525
37509
  if (showTagLegend) {
37526
- const tagLegendY = sDiagramPad + sTitleHeight + (legendEntries.length > 0 ? sLegendTopGap + sLegendPillHeight : sLegendTopGap);
37510
+ const tagLegendY = sDiagramPad + sTitleHeight + sLegendTopGap;
37527
37511
  renderTagLegendRow(svg, resolved, palette, isDark, {
37528
37512
  x: 0,
37529
37513
  y: tagLegendY,
@@ -37607,8 +37591,7 @@ function renderPertForExport(content, theme, palette, now) {
37607
37591
  }
37608
37592
  const captionBoxHeight = captionBullets.length > 0 ? captionBullets.length * CAPTION_LINE_HEIGHT + 2 * CAPTION_BOX_PADDING_Y + CAPTION_HEADER_BAND_HEIGHT : 0;
37609
37593
  const captionBlockHeight = captionBullets.length > 0 ? CAPTION_TOP_GAP + captionBoxHeight : 0;
37610
- const legendEntries = pertLegendEntries(resolved);
37611
- const legendBlockHeight = legendEntries.length > 0 ? LEGEND_TOP_GAP + LEGEND_PILL_HEIGHT + LEGEND_BOTTOM_GAP : 0;
37594
+ const legendBlockHeight = resolved.tagGroups.length > 0 ? LEGEND_TOP_GAP + LEGEND_PILL_HEIGHT + LEGEND_BOTTOM_GAP : 0;
37612
37595
  const exportWidth = layout.width + DIAGRAM_PADDING11 * 2;
37613
37596
  const exportHeight = layout.height + DIAGRAM_PADDING11 * 2 + titleHeight + legendBlockHeight + captionBlockHeight;
37614
37597
  const container = document.createElement("div");
@@ -38148,22 +38131,22 @@ function renderEdges2(root, resolved, layout, palette, collapsedSet, sc = {}) {
38148
38131
  if (srcGroup && tgtGroup && srcGroup === tgtGroup && collapsedSet.has(srcGroup)) {
38149
38132
  continue;
38150
38133
  }
38151
- const isCritical2 = criticalSet.has(e.source) && criticalSet.has(e.target);
38134
+ const isCritical = criticalSet.has(e.source) && criticalSet.has(e.target);
38152
38135
  let band;
38153
38136
  if (mcOn) {
38154
38137
  const sc2 = critById.get(e.source);
38155
38138
  const tc = critById.get(e.target);
38156
38139
  const minC = sc2 === null || tc === null || sc2 === void 0 || tc === void 0 ? null : Math.min(sc2, tc);
38157
38140
  band = criticalityBand(minC);
38158
- if (band === null && isCritical2) band = "red";
38141
+ if (band === null && isCritical) band = "red";
38159
38142
  } else {
38160
- band = isCritical2 ? "red" : null;
38143
+ band = isCritical ? "red" : null;
38161
38144
  }
38162
38145
  const path = lineGenerator6(e.points);
38163
38146
  if (!path) continue;
38164
38147
  const sESW = sc.edgeStrokeWidth ?? EDGE_STROKE_WIDTH10;
38165
38148
  const sELFS = sc.edgeLabelFontSize ?? 10;
38166
- layer.append("path").attr("class", "pert-edge").attr("d", path).attr("fill", "none").attr("stroke", bandColor(band, palette, palette.textMuted)).attr("stroke-width", sESW).attr("marker-end", `url(#${bandArrow(band)})`).attr("data-source", e.source).attr("data-target", e.target).attr("data-critical", String(isCritical2)).attr("data-critical-path", String(isCritical2)).attr("data-criticality-band", band ?? "");
38149
+ layer.append("path").attr("class", "pert-edge").attr("d", path).attr("fill", "none").attr("stroke", bandColor(band, palette, palette.textMuted)).attr("stroke-width", sESW).attr("marker-end", `url(#${bandArrow(band)})`).attr("data-source", e.source).attr("data-target", e.target).attr("data-critical", String(isCritical)).attr("data-critical-path", String(isCritical)).attr("data-criticality-band", band ?? "");
38167
38150
  const parsedEdge = edgeByKey.get(`${e.source}->${e.target}`);
38168
38151
  const labelText = parsedEdge ? formatEdgeLabel(parsedEdge) : null;
38169
38152
  if (labelText) {
@@ -38215,7 +38198,7 @@ function renderNodes2(root, _defs, resolved, layout, palette, isDark, sizing, on
38215
38198
  const r = byId.get(node.id);
38216
38199
  if (!r) continue;
38217
38200
  if (r.activity.groupId && collapsedSet.has(r.activity.groupId)) continue;
38218
- const isCritical2 = r.isCriticalPath;
38201
+ const isCritical = r.isCriticalPath;
38219
38202
  const isTbd = tbdSet.has(node.id);
38220
38203
  const dashArray = isTbd ? "4,3" : "none";
38221
38204
  const isTopMu = topMuIds.has(node.id);
@@ -38223,14 +38206,14 @@ function renderNodes2(root, _defs, resolved, layout, palette, isDark, sizing, on
38223
38206
  let band;
38224
38207
  if (mcOn) {
38225
38208
  band = criticalityBand(r.criticality);
38226
- if (band === null && isCritical2) band = "red";
38209
+ if (band === null && isCritical) band = "red";
38227
38210
  } else {
38228
- band = isCritical2 ? "red" : null;
38211
+ band = isCritical ? "red" : null;
38229
38212
  }
38230
38213
  const g = layer.append("g").attr("class", "pert-node").attr("transform", `translate(${node.x}, ${node.y})`).attr("data-activity-id", node.id).attr("data-line-number", String(r.activity.lineNumber)).attr(
38231
38214
  "data-group-id",
38232
38215
  r.activity.groupId !== void 0 ? r.activity.groupId : ""
38233
- ).attr("data-critical-path", String(isCritical2)).attr("data-criticality-band", band ?? "").attr("data-duration-rank", isTopMu ? "top" : isBottomMu ? "bottom" : "");
38216
+ ).attr("data-critical-path", String(isCritical)).attr("data-criticality-band", band ?? "").attr("data-duration-rank", isTopMu ? "top" : isBottomMu ? "bottom" : "");
38234
38217
  if (r.activity.tags) {
38235
38218
  for (const [tagKey, tagValue] of Object.entries(r.activity.tags)) {
38236
38219
  g.attr(`data-tag-${tagKey}`, String(tagValue).toLowerCase());
@@ -38540,69 +38523,6 @@ function computeAnchorPinSet(resolved) {
38540
38523
  }
38541
38524
  return pinned;
38542
38525
  }
38543
- function isCritical(el, mcOn) {
38544
- if (mcOn) {
38545
- return HIGHLIGHT_BANDS.has(el.getAttribute("data-criticality-band") ?? "");
38546
- }
38547
- return el.getAttribute("data-critical-path") === "true";
38548
- }
38549
- function isInHighlightSet(el, kind, mcOn) {
38550
- if (kind === "critical") return isCritical(el, mcOn);
38551
- if (kind === "milestone") {
38552
- return el.getAttribute("data-milestone") === "true";
38553
- }
38554
- return el.hasAttribute("data-anchor");
38555
- }
38556
- function highlightPertSet(container, kind) {
38557
- const svg = container.querySelector("svg");
38558
- if (!svg) return;
38559
- const mcOn = Array.from(svg.querySelectorAll(".pert-edge")).some((e) => {
38560
- const b = e.getAttribute("data-criticality-band");
38561
- return b !== null && b !== "" && b !== "red";
38562
- });
38563
- const candidates = svg.querySelectorAll(
38564
- ".pert-node, .pert-edge, .pert-group-collapsed"
38565
- );
38566
- let anyMatch = false;
38567
- for (const el of candidates) {
38568
- if (isInHighlightSet(el, kind, mcOn)) {
38569
- anyMatch = true;
38570
- break;
38571
- }
38572
- }
38573
- if (!anyMatch) return;
38574
- svg.setAttribute("data-pert-highlight-active", kind);
38575
- for (const el of svg.querySelectorAll(".pert-node, .pert-edge")) {
38576
- el.setAttribute(
38577
- "opacity",
38578
- isInHighlightSet(el, kind, mcOn) ? "1" : String(FADE_OPACITY)
38579
- );
38580
- }
38581
- for (const el of svg.querySelectorAll(".pert-group")) {
38582
- const inSet = el.classList.contains("pert-group-collapsed") && isInHighlightSet(el, kind, mcOn);
38583
- el.setAttribute(
38584
- "opacity",
38585
- inSet ? "1" : String(FADE_OPACITY)
38586
- );
38587
- }
38588
- }
38589
- function highlightPertCriticalPath(container) {
38590
- highlightPertSet(container, "critical");
38591
- }
38592
- function resetPertHighlight(container) {
38593
- const svg = container.querySelector("svg");
38594
- if (!svg) return;
38595
- svg.removeAttribute("data-pert-highlight-active");
38596
- svg.removeAttribute("data-critical-path-active");
38597
- for (const el of svg.querySelectorAll(
38598
- ".pert-node, .pert-edge, .pert-group"
38599
- )) {
38600
- el.removeAttribute("opacity");
38601
- }
38602
- }
38603
- function resetPertCriticalPath(container) {
38604
- resetPertHighlight(container);
38605
- }
38606
38526
  function anchorAnnotationText(resolved) {
38607
38527
  const anchor = resolved.options.anchor;
38608
38528
  if (anchor === null) return null;
@@ -38655,70 +38575,6 @@ function renderCaptionBlock(svg, bullets, args) {
38655
38575
  if (i > 0) tspan.attr("dy", CAPTION_LINE_HEIGHT);
38656
38576
  });
38657
38577
  }
38658
- function pertLegendEntries(resolved) {
38659
- const entries = [];
38660
- if (resolved.activities.length > 0) {
38661
- entries.push({ kind: "critical", label: "Critical Path" });
38662
- }
38663
- if (resolved.options.anchor !== null) {
38664
- entries.push({ kind: "anchor", label: "Anchor" });
38665
- }
38666
- if (resolved.activities.some((a) => a.activity.isMilestone)) {
38667
- entries.push({ kind: "milestone", label: "Milestone" });
38668
- }
38669
- return entries;
38670
- }
38671
- function legendSwatchWidth(kind) {
38672
- if (kind === "critical") return LEGEND_DOT_R * 2;
38673
- if (kind === "anchor") return PIN_ICON_W;
38674
- return LEGEND_FONT_SIZE;
38675
- }
38676
- function legendPillWidth(entry) {
38677
- const labelW = measureLegendText(entry.label, LEGEND_FONT_SIZE);
38678
- return Math.ceil(
38679
- LEGEND_PILL_PADDING_X + legendSwatchWidth(entry.kind) + LEGEND_SWATCH_GAP + labelW + LEGEND_PILL_PADDING_X
38680
- );
38681
- }
38682
- function legendNaturalWidth(entries) {
38683
- if (entries.length === 0) return 0;
38684
- let total = 0;
38685
- for (const e of entries) total += legendPillWidth(e);
38686
- total += (entries.length - 1) * LEGEND_PILL_GAP;
38687
- return total;
38688
- }
38689
- function pertLegendBlockWidth(entries) {
38690
- return legendNaturalWidth(entries);
38691
- }
38692
- function renderLegendBlock(svg, entries, args) {
38693
- if (entries.length === 0) return;
38694
- const { x, y, width, palette, isDark } = args;
38695
- const groupBg = isDark ? mix(palette.surface, palette.bg, 50) : mix(palette.surface, palette.bg, 30);
38696
- const block = svg.append("g").attr("class", "pert-legend").attr("data-pert-legend", "");
38697
- const totalW = legendNaturalWidth(entries);
38698
- let pillX = x + (width - totalW) / 2;
38699
- for (const entry of entries) {
38700
- const pillW = legendPillWidth(entry);
38701
- const pill = block.append("g").attr("class", "pert-legend-entry").attr("data-legend-entry", entry.kind).attr("transform", `translate(${pillX}, ${y})`).style("cursor", "pointer");
38702
- pill.append("rect").attr("class", "pert-legend-pill").attr("width", pillW).attr("height", LEGEND_PILL_HEIGHT).attr("rx", LEGEND_PILL_HEIGHT / 2).attr("ry", LEGEND_PILL_HEIGHT / 2).attr("fill", groupBg);
38703
- const swatchW = legendSwatchWidth(entry.kind);
38704
- const swatchCx = LEGEND_PILL_PADDING_X + swatchW / 2;
38705
- const swatchCy = LEGEND_PILL_HEIGHT / 2;
38706
- if (entry.kind === "critical") {
38707
- pill.append("circle").attr("class", "pert-legend-swatch").attr("cx", swatchCx).attr("cy", swatchCy).attr("r", LEGEND_DOT_R).attr("fill", palette.colors.red);
38708
- } else if (entry.kind === "anchor") {
38709
- drawAnchorPin(
38710
- pill,
38711
- swatchCx - PIN_ICON_W / 2,
38712
- swatchCy,
38713
- palette.textMuted
38714
- );
38715
- } else {
38716
- pill.append("text").attr("class", "pert-legend-swatch").attr("x", swatchCx).attr("y", swatchCy).attr("text-anchor", "middle").attr("dominant-baseline", "central").attr("font-family", FONT_FAMILY).attr("font-size", LEGEND_FONT_SIZE + 1).attr("fill", palette.textMuted).text("\u25C6");
38717
- }
38718
- pill.append("text").attr("class", "pert-legend-label").attr("x", LEGEND_PILL_PADDING_X + swatchW + LEGEND_SWATCH_GAP).attr("y", swatchCy).attr("dominant-baseline", "central").attr("font-family", FONT_FAMILY).attr("font-size", LEGEND_FONT_SIZE).attr("font-weight", 500).attr("fill", palette.textMuted).text(entry.label);
38719
- pillX += pillW + LEGEND_PILL_GAP;
38720
- }
38721
- }
38722
38578
  function renderTagLegendRow(svg, resolved, palette, isDark, args) {
38723
38579
  if (resolved.tagGroups.length === 0) return;
38724
38580
  const { x, y, width, activeGroup, exportMode } = args;
@@ -39165,7 +39021,7 @@ function formatScurveDate(iso) {
39165
39021
  if (month < 0 || month > 11 || isNaN(day)) return iso;
39166
39022
  return `${SCURVE_MONTH_NAMES[month]} ${day}`;
39167
39023
  }
39168
- var d3Selection12, d3Shape8, DIAGRAM_PADDING11, NODE_FONT_SIZE4, NODE_CELL_FONT_SIZE2, NODE_RADIUS2, NODE_STROKE_WIDTH10, NODE_TOP_ROW_HEIGHT, NODE_BOTTOM_ROW_HEIGHT, EDGE_STROKE_WIDTH10, ARROWHEAD_W4, ARROWHEAD_H4, CONTAINER_RADIUS3, CONTAINER_LABEL_FONT_SIZE3, CONTAINER_HEADER_HEIGHT3, COLLAPSE_BAR_HEIGHT7, FADE_OPACITY, DURATION_FADE_OPACITY, PIN_ICON_W, PIN_ICON_H, LEGEND_PILL_HEIGHT, LEGEND_PILL_PADDING_X, LEGEND_PILL_GAP, LEGEND_SWATCH_GAP, LEGEND_FONT_SIZE, LEGEND_TOP_GAP, LEGEND_BOTTOM_GAP, FIELD_LEGEND_HEADER_BAND_HEIGHT, FIELD_LEGEND_CELL_VPAD, FIELD_LEGEND_LABEL_FONT_SIZE, FIELD_LEGEND_DESC_FONT_SIZE, FIELD_LEGEND_DESC_LINE_HEIGHT, FIELD_LEGEND_LABEL_DESC_GAP, FIELD_LEGEND_CELLS, lineGenerator6, FIELD_LEGEND_MIN_W, HIGHLIGHT_BANDS, SUB_BULLET_INDENT, CAPTION_HEADER_BAND_HEIGHT, TORNADO_TOP_N, TORNADO_ROW_HEIGHT, TORNADO_NAME_COL_W, TORNADO_BAR_FONT_SIZE, TORNADO_BAR_HEIGHT, SUMMARY_MIN_W, SUMMARY_MAX_W, ANALYSIS_GAP, COL1_VSTACK_GAP, TORNADO_MIN_W, SCURVE_MIN_W, SCURVE_BOX_HEIGHT, SCURVE_PLOT_PADDING_X, SCURVE_PLOT_PADDING_RIGHT, SCURVE_PLOT_PADDING_BOTTOM, SCURVE_TICK_FONT_SIZE, SCURVE_PERCENTILE_RADIUS, PERT_LEGEND_PILL_HEIGHT, DAYS_PER_UNIT, SCURVE_MONTH_NAMES, UNIT_TO_DAYS_LOCAL2;
39024
+ var d3Selection12, d3Shape8, DIAGRAM_PADDING11, NODE_FONT_SIZE4, NODE_CELL_FONT_SIZE2, NODE_RADIUS2, NODE_STROKE_WIDTH10, NODE_TOP_ROW_HEIGHT, NODE_BOTTOM_ROW_HEIGHT, EDGE_STROKE_WIDTH10, ARROWHEAD_W4, ARROWHEAD_H4, CONTAINER_RADIUS3, CONTAINER_LABEL_FONT_SIZE3, CONTAINER_HEADER_HEIGHT3, COLLAPSE_BAR_HEIGHT7, DURATION_FADE_OPACITY, PIN_ICON_W, PIN_ICON_H, LEGEND_PILL_HEIGHT, LEGEND_TOP_GAP, LEGEND_BOTTOM_GAP, FIELD_LEGEND_HEADER_BAND_HEIGHT, FIELD_LEGEND_CELL_VPAD, FIELD_LEGEND_LABEL_FONT_SIZE, FIELD_LEGEND_DESC_FONT_SIZE, FIELD_LEGEND_DESC_LINE_HEIGHT, FIELD_LEGEND_LABEL_DESC_GAP, FIELD_LEGEND_CELLS, lineGenerator6, FIELD_LEGEND_MIN_W, SUB_BULLET_INDENT, CAPTION_HEADER_BAND_HEIGHT, TORNADO_TOP_N, TORNADO_ROW_HEIGHT, TORNADO_NAME_COL_W, TORNADO_BAR_FONT_SIZE, TORNADO_BAR_HEIGHT, SUMMARY_MIN_W, SUMMARY_MAX_W, ANALYSIS_GAP, COL1_VSTACK_GAP, TORNADO_MIN_W, SCURVE_MIN_W, SCURVE_BOX_HEIGHT, SCURVE_PLOT_PADDING_X, SCURVE_PLOT_PADDING_RIGHT, SCURVE_PLOT_PADDING_BOTTOM, SCURVE_TICK_FONT_SIZE, SCURVE_PERCENTILE_RADIUS, DAYS_PER_UNIT, SCURVE_MONTH_NAMES, UNIT_TO_DAYS_LOCAL2;
39169
39025
  var init_renderer11 = __esm({
39170
39026
  "src/pert/renderer.ts"() {
39171
39027
  "use strict";
@@ -39196,15 +39052,10 @@ var init_renderer11 = __esm({
39196
39052
  CONTAINER_LABEL_FONT_SIZE3 = 13;
39197
39053
  CONTAINER_HEADER_HEIGHT3 = 28;
39198
39054
  COLLAPSE_BAR_HEIGHT7 = 6;
39199
- FADE_OPACITY = 0.15;
39200
39055
  DURATION_FADE_OPACITY = 0.55;
39201
39056
  PIN_ICON_W = 13;
39202
39057
  PIN_ICON_H = 13;
39203
39058
  LEGEND_PILL_HEIGHT = LEGEND_HEIGHT;
39204
- LEGEND_PILL_PADDING_X = 8;
39205
- LEGEND_PILL_GAP = 8;
39206
- LEGEND_SWATCH_GAP = LEGEND_ENTRY_DOT_GAP;
39207
- LEGEND_FONT_SIZE = LEGEND_PILL_FONT_SIZE;
39208
39059
  LEGEND_TOP_GAP = 12;
39209
39060
  LEGEND_BOTTOM_GAP = 12;
39210
39061
  FIELD_LEGEND_HEADER_BAND_HEIGHT = 26;
@@ -39241,7 +39092,6 @@ var init_renderer11 = __esm({
39241
39092
  ];
39242
39093
  lineGenerator6 = d3Shape8.line().x((d) => d.x).y((d) => d.y).curve(d3Shape8.curveBasis);
39243
39094
  FIELD_LEGEND_MIN_W = 220;
39244
- HIGHLIGHT_BANDS = /* @__PURE__ */ new Set(["red", "orange", "yellow"]);
39245
39095
  SUB_BULLET_INDENT = 20;
39246
39096
  CAPTION_HEADER_BAND_HEIGHT = CAPTION_LINE_HEIGHT + 8;
39247
39097
  TORNADO_TOP_N = 10;
@@ -39261,7 +39111,6 @@ var init_renderer11 = __esm({
39261
39111
  SCURVE_PLOT_PADDING_BOTTOM = 44;
39262
39112
  SCURVE_TICK_FONT_SIZE = 13;
39263
39113
  SCURVE_PERCENTILE_RADIUS = 4;
39264
- PERT_LEGEND_PILL_HEIGHT = LEGEND_PILL_HEIGHT;
39265
39114
  DAYS_PER_UNIT = {
39266
39115
  min: 1 / (60 * 24),
39267
39116
  h: 1 / 24,
@@ -40786,31 +40635,31 @@ function renderGantt(container, resolved, palette, isDark, options, exportDims)
40786
40635
  todayHoverG.on("mouseenter", () => {
40787
40636
  g.selectAll(".gantt-task").attr(
40788
40637
  "opacity",
40789
- FADE_OPACITY2
40638
+ FADE_OPACITY
40790
40639
  );
40791
40640
  g.selectAll(".gantt-milestone").attr(
40792
40641
  "opacity",
40793
- FADE_OPACITY2
40642
+ FADE_OPACITY
40794
40643
  );
40795
40644
  g.selectAll(
40796
40645
  ".gantt-group-bar, .gantt-group-summary"
40797
- ).attr("opacity", FADE_OPACITY2);
40798
- svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY2);
40799
- svg.selectAll(".gantt-task-label").attr("opacity", FADE_OPACITY2);
40800
- svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY2);
40646
+ ).attr("opacity", FADE_OPACITY);
40647
+ svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY);
40648
+ svg.selectAll(".gantt-task-label").attr("opacity", FADE_OPACITY);
40649
+ svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY);
40801
40650
  g.selectAll(
40802
40651
  ".gantt-lane-band, .gantt-lane-accent, .gantt-lane-band-group"
40803
- ).attr("opacity", FADE_OPACITY2);
40652
+ ).attr("opacity", FADE_OPACITY);
40804
40653
  g.selectAll(
40805
40654
  ".gantt-dep-arrow, .gantt-dep-arrowhead"
40806
- ).attr("opacity", FADE_OPACITY2);
40655
+ ).attr("opacity", FADE_OPACITY);
40807
40656
  g.selectAll(".gantt-era-group").attr(
40808
40657
  "opacity",
40809
- FADE_OPACITY2
40658
+ FADE_OPACITY
40810
40659
  );
40811
40660
  g.selectAll(".gantt-marker-group").attr(
40812
40661
  "opacity",
40813
- FADE_OPACITY2
40662
+ FADE_OPACITY
40814
40663
  );
40815
40664
  showGanttDateIndicators(
40816
40665
  g,
@@ -41042,28 +40891,28 @@ function applyCriticalPathHighlight(svg, chartG) {
41042
40891
  const el = d3Selection13.select(this);
41043
40892
  el.attr(
41044
40893
  "opacity",
41045
- el.attr("data-critical-path") === "true" ? 1 : FADE_OPACITY2
40894
+ el.attr("data-critical-path") === "true" ? 1 : FADE_OPACITY
41046
40895
  );
41047
40896
  });
41048
- chartG.selectAll(".gantt-milestone").attr("opacity", FADE_OPACITY2);
41049
- chartG.selectAll(".gantt-group-bar, .gantt-group-summary").attr("opacity", FADE_OPACITY2);
40897
+ chartG.selectAll(".gantt-milestone").attr("opacity", FADE_OPACITY);
40898
+ chartG.selectAll(".gantt-group-bar, .gantt-group-summary").attr("opacity", FADE_OPACITY);
41050
40899
  svg.selectAll(".gantt-task-label").each(function() {
41051
40900
  const el = d3Selection13.select(this);
41052
40901
  el.attr(
41053
40902
  "opacity",
41054
- el.attr("data-critical-path") === "true" ? 1 : FADE_OPACITY2
40903
+ el.attr("data-critical-path") === "true" ? 1 : FADE_OPACITY
41055
40904
  );
41056
40905
  });
41057
- svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY2);
41058
- svg.selectAll(".gantt-group-band-bg, .gantt-group-band-accent").attr("opacity", FADE_OPACITY2);
41059
- svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY2);
41060
- svg.selectAll(".gantt-lane-band-bg, .gantt-lane-band-accent").attr("opacity", FADE_OPACITY2);
41061
- chartG.selectAll(".gantt-lane-band, .gantt-lane-accent").attr("opacity", FADE_OPACITY2);
40906
+ svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY);
40907
+ svg.selectAll(".gantt-group-band-bg, .gantt-group-band-accent").attr("opacity", FADE_OPACITY);
40908
+ svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY);
40909
+ svg.selectAll(".gantt-lane-band-bg, .gantt-lane-band-accent").attr("opacity", FADE_OPACITY);
40910
+ chartG.selectAll(".gantt-lane-band, .gantt-lane-accent").attr("opacity", FADE_OPACITY);
41062
40911
  chartG.selectAll(".gantt-dep-arrow, .gantt-dep-arrowhead").each(function() {
41063
40912
  const el = d3Selection13.select(this);
41064
40913
  el.attr(
41065
40914
  "opacity",
41066
- el.attr("data-critical-path") === "true" ? 0.7 : FADE_OPACITY2
40915
+ el.attr("data-critical-path") === "true" ? 0.7 : FADE_OPACITY
41067
40916
  );
41068
40917
  });
41069
40918
  }
@@ -41242,27 +41091,27 @@ function renderTagLegend(svg, chartG, tagGroups, activeGroupName, chartLeftMargi
41242
41091
  const el = d3Selection13.select(this);
41243
41092
  el.attr(
41244
41093
  "opacity",
41245
- el.attr(`data-tag-${tagKey}`) === ev ? 1 : FADE_OPACITY2
41094
+ el.attr(`data-tag-${tagKey}`) === ev ? 1 : FADE_OPACITY
41246
41095
  );
41247
41096
  });
41248
- chartG.selectAll(".gantt-milestone").attr("opacity", FADE_OPACITY2);
41249
- chartG.selectAll(".gantt-group-bar, .gantt-group-summary").attr("opacity", FADE_OPACITY2);
41097
+ chartG.selectAll(".gantt-milestone").attr("opacity", FADE_OPACITY);
41098
+ chartG.selectAll(".gantt-group-bar, .gantt-group-summary").attr("opacity", FADE_OPACITY);
41250
41099
  svg.selectAll(".gantt-task-label").each(function() {
41251
41100
  const el = d3Selection13.select(this);
41252
41101
  el.attr(
41253
41102
  "opacity",
41254
- el.attr(`data-tag-${tagKey}`) === ev ? 1 : FADE_OPACITY2
41103
+ el.attr(`data-tag-${tagKey}`) === ev ? 1 : FADE_OPACITY
41255
41104
  );
41256
41105
  });
41257
- svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY2);
41106
+ svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY);
41258
41107
  svg.selectAll(".gantt-lane-header").each(function() {
41259
41108
  const el = d3Selection13.select(this);
41260
41109
  el.attr(
41261
41110
  "opacity",
41262
- el.attr(`data-tag-${tagKey}`) === ev ? 1 : FADE_OPACITY2
41111
+ el.attr(`data-tag-${tagKey}`) === ev ? 1 : FADE_OPACITY
41263
41112
  );
41264
41113
  });
41265
- chartG.selectAll(".gantt-lane-band, .gantt-lane-accent").attr("opacity", FADE_OPACITY2);
41114
+ chartG.selectAll(".gantt-lane-band, .gantt-lane-accent").attr("opacity", FADE_OPACITY);
41266
41115
  } else {
41267
41116
  if (criticalPathActive) {
41268
41117
  applyCriticalPathHighlight(svg, chartG);
@@ -41367,27 +41216,27 @@ function renderErasAndMarkers(g, svg, resolved, xScale, innerHeight, palette, er
41367
41216
  eraG.on("mouseenter", () => {
41368
41217
  g.selectAll(".gantt-task").attr(
41369
41218
  "opacity",
41370
- FADE_OPACITY2
41219
+ FADE_OPACITY
41371
41220
  );
41372
41221
  g.selectAll(".gantt-milestone").attr(
41373
41222
  "opacity",
41374
- FADE_OPACITY2
41223
+ FADE_OPACITY
41375
41224
  );
41376
41225
  g.selectAll(
41377
41226
  ".gantt-group-bar, .gantt-group-summary"
41378
- ).attr("opacity", FADE_OPACITY2);
41379
- svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY2);
41380
- svg.selectAll(".gantt-task-label").attr("opacity", FADE_OPACITY2);
41381
- svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY2);
41227
+ ).attr("opacity", FADE_OPACITY);
41228
+ svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY);
41229
+ svg.selectAll(".gantt-task-label").attr("opacity", FADE_OPACITY);
41230
+ svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY);
41382
41231
  g.selectAll(
41383
41232
  ".gantt-lane-band, .gantt-lane-accent, .gantt-lane-band-group"
41384
- ).attr("opacity", FADE_OPACITY2);
41233
+ ).attr("opacity", FADE_OPACITY);
41385
41234
  g.selectAll(
41386
41235
  ".gantt-dep-arrow, .gantt-dep-arrowhead"
41387
- ).attr("opacity", FADE_OPACITY2);
41236
+ ).attr("opacity", FADE_OPACITY);
41388
41237
  g.selectAll(".gantt-marker-group").attr(
41389
41238
  "opacity",
41390
- FADE_OPACITY2
41239
+ FADE_OPACITY
41391
41240
  );
41392
41241
  eraRect.attr("opacity", hoverEraOpacity);
41393
41242
  if (eraTruncated) eraLabel.text(era.label);
@@ -41445,31 +41294,31 @@ function renderErasAndMarkers(g, svg, resolved, xScale, innerHeight, palette, er
41445
41294
  markerG.on("mouseenter", () => {
41446
41295
  g.selectAll(".gantt-task").attr(
41447
41296
  "opacity",
41448
- FADE_OPACITY2
41297
+ FADE_OPACITY
41449
41298
  );
41450
41299
  g.selectAll(".gantt-milestone").attr(
41451
41300
  "opacity",
41452
- FADE_OPACITY2
41301
+ FADE_OPACITY
41453
41302
  );
41454
41303
  g.selectAll(
41455
41304
  ".gantt-group-bar, .gantt-group-summary"
41456
- ).attr("opacity", FADE_OPACITY2);
41457
- svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY2);
41458
- svg.selectAll(".gantt-task-label").attr("opacity", FADE_OPACITY2);
41459
- svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY2);
41305
+ ).attr("opacity", FADE_OPACITY);
41306
+ svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY);
41307
+ svg.selectAll(".gantt-task-label").attr("opacity", FADE_OPACITY);
41308
+ svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY);
41460
41309
  g.selectAll(
41461
41310
  ".gantt-lane-band, .gantt-lane-accent, .gantt-lane-band-group"
41462
- ).attr("opacity", FADE_OPACITY2);
41311
+ ).attr("opacity", FADE_OPACITY);
41463
41312
  g.selectAll(
41464
41313
  ".gantt-dep-arrow, .gantt-dep-arrowhead"
41465
- ).attr("opacity", FADE_OPACITY2);
41314
+ ).attr("opacity", FADE_OPACITY);
41466
41315
  g.selectAll(".gantt-era-group").attr(
41467
41316
  "opacity",
41468
- FADE_OPACITY2
41317
+ FADE_OPACITY
41469
41318
  );
41470
41319
  g.selectAll(".gantt-marker-group").attr(
41471
41320
  "opacity",
41472
- FADE_OPACITY2
41321
+ FADE_OPACITY
41473
41322
  );
41474
41323
  markerG.attr("opacity", 1);
41475
41324
  markerLine.attr("opacity", 0.8);
@@ -41545,7 +41394,7 @@ function renderSprintBands(g, svg, resolved, xScale, innerHeight, palette) {
41545
41394
  const id = el.attr("data-task-id");
41546
41395
  el.attr(
41547
41396
  "opacity",
41548
- id && overlappingTaskIds.has(id) ? 1 : FADE_OPACITY2
41397
+ id && overlappingTaskIds.has(id) ? 1 : FADE_OPACITY
41549
41398
  );
41550
41399
  });
41551
41400
  g.selectAll(".gantt-milestone").each(function() {
@@ -41553,7 +41402,7 @@ function renderSprintBands(g, svg, resolved, xScale, innerHeight, palette) {
41553
41402
  const id = el.attr("data-task-id");
41554
41403
  el.attr(
41555
41404
  "opacity",
41556
- id && overlappingTaskIds.has(id) ? 1 : FADE_OPACITY2
41405
+ id && overlappingTaskIds.has(id) ? 1 : FADE_OPACITY
41557
41406
  );
41558
41407
  });
41559
41408
  svg.selectAll(".gantt-task-label").each(function() {
@@ -41561,7 +41410,7 @@ function renderSprintBands(g, svg, resolved, xScale, innerHeight, palette) {
41561
41410
  const id = el.attr("data-task-id");
41562
41411
  el.attr(
41563
41412
  "opacity",
41564
- id && overlappingTaskIds.has(id) ? 1 : FADE_OPACITY2
41413
+ id && overlappingTaskIds.has(id) ? 1 : FADE_OPACITY
41565
41414
  );
41566
41415
  });
41567
41416
  g.selectAll(
@@ -41571,7 +41420,7 @@ function renderSprintBands(g, svg, resolved, xScale, innerHeight, palette) {
41571
41420
  const name = el.attr("data-group");
41572
41421
  el.attr(
41573
41422
  "opacity",
41574
- name && overlappingGroupNames.has(name) ? 1 : FADE_OPACITY2
41423
+ name && overlappingGroupNames.has(name) ? 1 : FADE_OPACITY
41575
41424
  );
41576
41425
  });
41577
41426
  svg.selectAll(".gantt-group-label").each(function() {
@@ -41579,19 +41428,19 @@ function renderSprintBands(g, svg, resolved, xScale, innerHeight, palette) {
41579
41428
  const name = el.attr("data-group");
41580
41429
  el.attr(
41581
41430
  "opacity",
41582
- name && overlappingGroupNames.has(name) ? 1 : FADE_OPACITY2
41431
+ name && overlappingGroupNames.has(name) ? 1 : FADE_OPACITY
41583
41432
  );
41584
41433
  });
41585
- svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY2);
41434
+ svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY);
41586
41435
  g.selectAll(
41587
41436
  ".gantt-lane-band, .gantt-lane-accent, .gantt-lane-band-group"
41588
- ).attr("opacity", FADE_OPACITY2);
41437
+ ).attr("opacity", FADE_OPACITY);
41589
41438
  g.selectAll(
41590
41439
  ".gantt-dep-arrow, .gantt-dep-arrowhead"
41591
- ).attr("opacity", FADE_OPACITY2);
41440
+ ).attr("opacity", FADE_OPACITY);
41592
41441
  g.selectAll(".gantt-marker-group").attr(
41593
41442
  "opacity",
41594
- FADE_OPACITY2
41443
+ FADE_OPACITY
41595
41444
  );
41596
41445
  sprintRect.attr("opacity", SPRINT_HOVER_OPACITY);
41597
41446
  const startVisible = rawSx >= chartMinX;
@@ -41660,20 +41509,20 @@ function highlightDeps(g, svg, taskId, resolved) {
41660
41509
  g.selectAll(".gantt-task").each(function() {
41661
41510
  const el = d3Selection13.select(this);
41662
41511
  const id = el.attr("data-task-id");
41663
- el.attr("opacity", id && related.has(id) ? 1 : FADE_OPACITY2);
41512
+ el.attr("opacity", id && related.has(id) ? 1 : FADE_OPACITY);
41664
41513
  });
41665
41514
  g.selectAll(".gantt-milestone").attr(
41666
41515
  "opacity",
41667
- FADE_OPACITY2
41516
+ FADE_OPACITY
41668
41517
  );
41669
41518
  g.selectAll(
41670
41519
  ".gantt-group-bar, .gantt-group-summary"
41671
- ).attr("opacity", FADE_OPACITY2);
41672
- svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY2);
41673
- svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY2);
41520
+ ).attr("opacity", FADE_OPACITY);
41521
+ svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY);
41522
+ svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY);
41674
41523
  g.selectAll(".gantt-lane-band, .gantt-lane-accent").attr(
41675
41524
  "opacity",
41676
- FADE_OPACITY2
41525
+ FADE_OPACITY
41677
41526
  );
41678
41527
  g.selectAll(
41679
41528
  ".gantt-dep-arrow, .gantt-dep-arrowhead"
@@ -41682,52 +41531,52 @@ function highlightDeps(g, svg, taskId, resolved) {
41682
41531
  const from = el.attr("data-dep-from");
41683
41532
  const to = el.attr("data-dep-to");
41684
41533
  const isRelated = from && related.has(from) || to && related.has(to);
41685
- el.attr("opacity", isRelated ? 0.5 : FADE_OPACITY2);
41534
+ el.attr("opacity", isRelated ? 0.5 : FADE_OPACITY);
41686
41535
  });
41687
41536
  g.selectAll(".gantt-marker-group").attr(
41688
41537
  "opacity",
41689
- FADE_OPACITY2
41538
+ FADE_OPACITY
41690
41539
  );
41691
41540
  }
41692
41541
  function highlightGroup(g, svg, groupName) {
41693
41542
  g.selectAll(".gantt-task").each(function() {
41694
41543
  const el = d3Selection13.select(this);
41695
- el.attr("opacity", el.attr("data-group") === groupName ? 1 : FADE_OPACITY2);
41544
+ el.attr("opacity", el.attr("data-group") === groupName ? 1 : FADE_OPACITY);
41696
41545
  });
41697
41546
  g.selectAll(".gantt-milestone").each(function() {
41698
41547
  const el = d3Selection13.select(this);
41699
- el.attr("opacity", el.attr("data-group") === groupName ? 1 : FADE_OPACITY2);
41548
+ el.attr("opacity", el.attr("data-group") === groupName ? 1 : FADE_OPACITY);
41700
41549
  });
41701
41550
  g.selectAll(
41702
41551
  ".gantt-group-bar, .gantt-group-summary"
41703
41552
  ).each(function() {
41704
41553
  const el = d3Selection13.select(this);
41705
- el.attr("opacity", el.attr("data-group") === groupName ? 1 : FADE_OPACITY2);
41554
+ el.attr("opacity", el.attr("data-group") === groupName ? 1 : FADE_OPACITY);
41706
41555
  });
41707
41556
  svg.selectAll(".gantt-group-label").each(function() {
41708
41557
  const el = d3Selection13.select(this);
41709
- el.attr("opacity", el.attr("data-group") === groupName ? 1 : FADE_OPACITY2);
41558
+ el.attr("opacity", el.attr("data-group") === groupName ? 1 : FADE_OPACITY);
41710
41559
  });
41711
41560
  svg.selectAll(".gantt-task-label").each(function() {
41712
41561
  const el = d3Selection13.select(this);
41713
- el.attr("opacity", el.attr("data-group") === groupName ? 1 : FADE_OPACITY2);
41562
+ el.attr("opacity", el.attr("data-group") === groupName ? 1 : FADE_OPACITY);
41714
41563
  });
41715
41564
  svg.selectAll(".gantt-group-band-bg, .gantt-group-band-accent").each(function() {
41716
41565
  const el = d3Selection13.select(this);
41717
41566
  el.attr(
41718
41567
  "opacity",
41719
- el.attr("data-group") === groupName ? 1 : FADE_OPACITY2
41568
+ el.attr("data-group") === groupName ? 1 : FADE_OPACITY
41720
41569
  );
41721
41570
  });
41722
- svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY2);
41723
- svg.selectAll(".gantt-lane-band-bg, .gantt-lane-band-accent").attr("opacity", FADE_OPACITY2);
41571
+ svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY);
41572
+ svg.selectAll(".gantt-lane-band-bg, .gantt-lane-band-accent").attr("opacity", FADE_OPACITY);
41724
41573
  g.selectAll(".gantt-lane-band, .gantt-lane-accent").attr(
41725
41574
  "opacity",
41726
- FADE_OPACITY2
41575
+ FADE_OPACITY
41727
41576
  );
41728
41577
  g.selectAll(".gantt-marker-group").attr(
41729
41578
  "opacity",
41730
- FADE_OPACITY2
41579
+ FADE_OPACITY
41731
41580
  );
41732
41581
  }
41733
41582
  function highlightLane(g, svg, tagKey, laneName) {
@@ -41735,105 +41584,105 @@ function highlightLane(g, svg, tagKey, laneName) {
41735
41584
  const laneValue = laneName.toLowerCase();
41736
41585
  g.selectAll(".gantt-task").each(function() {
41737
41586
  const el = d3Selection13.select(this);
41738
- el.attr("opacity", el.attr(tagAttr) === laneValue ? 1 : FADE_OPACITY2);
41587
+ el.attr("opacity", el.attr(tagAttr) === laneValue ? 1 : FADE_OPACITY);
41739
41588
  });
41740
41589
  g.selectAll(".gantt-milestone").each(function() {
41741
41590
  const el = d3Selection13.select(this);
41742
- el.attr("opacity", el.attr(tagAttr) === laneValue ? 1 : FADE_OPACITY2);
41591
+ el.attr("opacity", el.attr(tagAttr) === laneValue ? 1 : FADE_OPACITY);
41743
41592
  });
41744
41593
  svg.selectAll(".gantt-task-label").each(function() {
41745
41594
  const el = d3Selection13.select(this);
41746
- el.attr("opacity", el.attr(tagAttr) === laneValue ? 1 : FADE_OPACITY2);
41595
+ el.attr("opacity", el.attr(tagAttr) === laneValue ? 1 : FADE_OPACITY);
41747
41596
  });
41748
41597
  svg.selectAll(".gantt-lane-header").each(function() {
41749
41598
  const el = d3Selection13.select(this);
41750
- el.attr("opacity", el.attr("data-lane") === laneName ? 1 : FADE_OPACITY2);
41599
+ el.attr("opacity", el.attr("data-lane") === laneName ? 1 : FADE_OPACITY);
41751
41600
  });
41752
41601
  g.selectAll(".gantt-lane-band-group").each(function() {
41753
41602
  const el = d3Selection13.select(this);
41754
- el.attr("opacity", el.attr("data-lane") === laneName ? 1 : FADE_OPACITY2);
41603
+ el.attr("opacity", el.attr("data-lane") === laneName ? 1 : FADE_OPACITY);
41755
41604
  });
41756
41605
  svg.selectAll(".gantt-lane-band-bg, .gantt-lane-band-accent").each(function() {
41757
41606
  const el = d3Selection13.select(this);
41758
- el.attr("opacity", el.attr("data-lane") === laneName ? 1 : FADE_OPACITY2);
41607
+ el.attr("opacity", el.attr("data-lane") === laneName ? 1 : FADE_OPACITY);
41759
41608
  });
41760
41609
  g.selectAll(
41761
41610
  ".gantt-group-bar, .gantt-group-summary"
41762
- ).attr("opacity", FADE_OPACITY2);
41763
- svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY2);
41764
- svg.selectAll(".gantt-group-band-bg, .gantt-group-band-accent").attr("opacity", FADE_OPACITY2);
41611
+ ).attr("opacity", FADE_OPACITY);
41612
+ svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY);
41613
+ svg.selectAll(".gantt-group-band-bg, .gantt-group-band-accent").attr("opacity", FADE_OPACITY);
41765
41614
  g.selectAll(".gantt-marker-group").attr(
41766
41615
  "opacity",
41767
- FADE_OPACITY2
41616
+ FADE_OPACITY
41768
41617
  );
41769
41618
  }
41770
41619
  function highlightTask(g, svg, taskId) {
41771
41620
  g.selectAll(".gantt-task").each(function() {
41772
41621
  const el = d3Selection13.select(this);
41773
- el.attr("opacity", el.attr("data-task-id") === taskId ? 1 : FADE_OPACITY2);
41622
+ el.attr("opacity", el.attr("data-task-id") === taskId ? 1 : FADE_OPACITY);
41774
41623
  });
41775
41624
  g.selectAll(".gantt-milestone").attr(
41776
41625
  "opacity",
41777
- FADE_OPACITY2
41626
+ FADE_OPACITY
41778
41627
  );
41779
41628
  svg.selectAll(".gantt-task-label").each(function() {
41780
41629
  const el = d3Selection13.select(this);
41781
- el.attr("opacity", el.attr("data-task-id") === taskId ? 1 : FADE_OPACITY2);
41630
+ el.attr("opacity", el.attr("data-task-id") === taskId ? 1 : FADE_OPACITY);
41782
41631
  });
41783
41632
  g.selectAll(
41784
41633
  ".gantt-group-bar, .gantt-group-summary"
41785
- ).attr("opacity", FADE_OPACITY2);
41786
- svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY2);
41787
- svg.selectAll(".gantt-group-band-bg, .gantt-group-band-accent").attr("opacity", FADE_OPACITY2);
41788
- svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY2);
41789
- svg.selectAll(".gantt-lane-band-bg, .gantt-lane-band-accent").attr("opacity", FADE_OPACITY2);
41634
+ ).attr("opacity", FADE_OPACITY);
41635
+ svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY);
41636
+ svg.selectAll(".gantt-group-band-bg, .gantt-group-band-accent").attr("opacity", FADE_OPACITY);
41637
+ svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY);
41638
+ svg.selectAll(".gantt-lane-band-bg, .gantt-lane-band-accent").attr("opacity", FADE_OPACITY);
41790
41639
  g.selectAll(
41791
41640
  ".gantt-lane-band, .gantt-lane-accent, .gantt-lane-band-group"
41792
- ).attr("opacity", FADE_OPACITY2);
41641
+ ).attr("opacity", FADE_OPACITY);
41793
41642
  g.selectAll(
41794
41643
  ".gantt-dep-arrow, .gantt-dep-arrowhead"
41795
- ).attr("opacity", FADE_OPACITY2);
41644
+ ).attr("opacity", FADE_OPACITY);
41796
41645
  g.selectAll(".gantt-marker-group").attr(
41797
41646
  "opacity",
41798
- FADE_OPACITY2
41647
+ FADE_OPACITY
41799
41648
  );
41800
41649
  }
41801
41650
  function highlightMilestone(g, svg, taskId) {
41802
41651
  g.selectAll(".gantt-task").attr(
41803
41652
  "opacity",
41804
- FADE_OPACITY2
41653
+ FADE_OPACITY
41805
41654
  );
41806
41655
  g.selectAll(".gantt-milestone").each(function() {
41807
41656
  const el = d3Selection13.select(this);
41808
- el.attr("opacity", el.attr("data-task-id") === taskId ? 1 : FADE_OPACITY2);
41657
+ el.attr("opacity", el.attr("data-task-id") === taskId ? 1 : FADE_OPACITY);
41809
41658
  });
41810
41659
  svg.selectAll(".gantt-task-label").each(function() {
41811
41660
  const el = d3Selection13.select(this);
41812
- el.attr("opacity", el.attr("data-task-id") === taskId ? 1 : FADE_OPACITY2);
41661
+ el.attr("opacity", el.attr("data-task-id") === taskId ? 1 : FADE_OPACITY);
41813
41662
  });
41814
41663
  g.selectAll(
41815
41664
  ".gantt-group-bar, .gantt-group-summary"
41816
- ).attr("opacity", FADE_OPACITY2);
41817
- svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY2);
41818
- svg.selectAll(".gantt-group-band-bg, .gantt-group-band-accent").attr("opacity", FADE_OPACITY2);
41819
- svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY2);
41820
- svg.selectAll(".gantt-lane-band-bg, .gantt-lane-band-accent").attr("opacity", FADE_OPACITY2);
41665
+ ).attr("opacity", FADE_OPACITY);
41666
+ svg.selectAll(".gantt-group-label").attr("opacity", FADE_OPACITY);
41667
+ svg.selectAll(".gantt-group-band-bg, .gantt-group-band-accent").attr("opacity", FADE_OPACITY);
41668
+ svg.selectAll(".gantt-lane-header").attr("opacity", FADE_OPACITY);
41669
+ svg.selectAll(".gantt-lane-band-bg, .gantt-lane-band-accent").attr("opacity", FADE_OPACITY);
41821
41670
  g.selectAll(
41822
41671
  ".gantt-lane-band, .gantt-lane-accent, .gantt-lane-band-group"
41823
- ).attr("opacity", FADE_OPACITY2);
41672
+ ).attr("opacity", FADE_OPACITY);
41824
41673
  g.selectAll(
41825
41674
  ".gantt-dep-arrow, .gantt-dep-arrowhead"
41826
- ).attr("opacity", FADE_OPACITY2);
41675
+ ).attr("opacity", FADE_OPACITY);
41827
41676
  g.selectAll(".gantt-marker-group").attr(
41828
41677
  "opacity",
41829
- FADE_OPACITY2
41678
+ FADE_OPACITY
41830
41679
  );
41831
41680
  }
41832
41681
  function highlightTaskLabel(svg, lineNumber) {
41833
41682
  const ln = String(lineNumber);
41834
41683
  svg.selectAll(".gantt-task-label").each(function() {
41835
41684
  const el = d3Selection13.select(this);
41836
- el.attr("opacity", el.attr("data-line-number") === ln ? 1 : FADE_OPACITY2);
41685
+ el.attr("opacity", el.attr("data-line-number") === ln ? 1 : FADE_OPACITY);
41837
41686
  });
41838
41687
  }
41839
41688
  function resetTaskLabels(svg) {
@@ -42107,7 +41956,7 @@ function renderTimeScaleHorizontal(g, scale, _innerWidth, innerHeight, textColor
42107
41956
  g.append("text").attr("class", "gantt-scale-tick").attr("x", tick.pos).attr("y", innerHeight + tickLen + 12).attr("text-anchor", "middle").attr("font-size", "10px").attr("fill", textColor).attr("opacity", opacity).text(tick.label);
42108
41957
  }
42109
41958
  }
42110
- var d3Scale, d3Selection13, BAR_H, ROW_GAP, GROUP_GAP2, MILESTONE_SIZE, MIN_LEFT_MARGIN, BOTTOM_MARGIN, RIGHT_MARGIN, CHAR_W2, LABEL_PAD2, LABEL_GAP, BAND_ACCENT_W, BAND_RADIUS, bandClipCounter, JS_DAY_TO_WEEKDAY2, ERA_COLORS, SPRINT_BAND_OPACITY, SPRINT_HOVER_OPACITY, SPRINT_BOUNDARY_OPACITY, FADE_OPACITY2, MONTH_ABBR2;
41959
+ var d3Scale, d3Selection13, BAR_H, ROW_GAP, GROUP_GAP2, MILESTONE_SIZE, MIN_LEFT_MARGIN, BOTTOM_MARGIN, RIGHT_MARGIN, CHAR_W2, LABEL_PAD2, LABEL_GAP, BAND_ACCENT_W, BAND_RADIUS, bandClipCounter, JS_DAY_TO_WEEKDAY2, ERA_COLORS, SPRINT_BAND_OPACITY, SPRINT_HOVER_OPACITY, SPRINT_BOUNDARY_OPACITY, FADE_OPACITY, MONTH_ABBR2;
42111
41960
  var init_renderer12 = __esm({
42112
41961
  "src/gantt/renderer.ts"() {
42113
41962
  "use strict";
@@ -42150,7 +41999,7 @@ var init_renderer12 = __esm({
42150
41999
  SPRINT_BAND_OPACITY = 0.05;
42151
42000
  SPRINT_HOVER_OPACITY = 0.12;
42152
42001
  SPRINT_BOUNDARY_OPACITY = 0.3;
42153
- FADE_OPACITY2 = 0.1;
42002
+ FADE_OPACITY = 0.1;
42154
42003
  MONTH_ABBR2 = [
42155
42004
  "Jan",
42156
42005
  "Feb",
@@ -47465,7 +47314,8 @@ function layoutMap(resolved, data, size, opts) {
47465
47314
  palette.bg,
47466
47315
  mutedBasemap ? isDark ? MUTED_FOREIGN_DARK : MUTED_FOREIGN_LIGHT : isDark ? FOREIGN_TINT_DARK : FOREIGN_TINT_LIGHT
47467
47316
  );
47468
- const colorizeActive = resolved.directives.noColorize !== true && !hasRamp && resolved.tagGroups.length === 0;
47317
+ const hasDirectColor = resolved.regions.some((r) => r.color !== void 0);
47318
+ const colorizeActive = resolved.directives.noColorize !== true && !hasRamp && !hasDirectColor && resolved.tagGroups.length === 0;
47469
47319
  const colorByIso = /* @__PURE__ */ new Map();
47470
47320
  if (colorizeActive) {
47471
47321
  const adjacency = /* @__PURE__ */ new Map();
@@ -47561,16 +47411,17 @@ function layoutMap(resolved, data, size, opts) {
47561
47411
  };
47562
47412
  }
47563
47413
  }
47414
+ const shownTitle = resolved.directives.noTitle ? null : resolved.title;
47564
47415
  const TITLE_GAP2 = 16;
47565
47416
  let topPad = FIT_PAD;
47566
- if (resolved.title && resolved.pois.length > 0) {
47417
+ if (shownTitle && resolved.pois.length > 0) {
47567
47418
  const bannerBottom = (resolved.subtitle ? TITLE_Y + TITLE_FONT_SIZE : TITLE_Y) + TITLE_FONT_SIZE / 2;
47568
47419
  topPad = Math.max(FIT_PAD, bannerBottom + TITLE_GAP2);
47569
47420
  }
47570
47421
  const legendBand = mapLegendBand(legend, {
47571
47422
  width,
47572
47423
  mode: opts.legendMode ?? "preview",
47573
- hasTitle: Boolean(resolved.title),
47424
+ hasTitle: Boolean(shownTitle),
47574
47425
  hasSubtitle: Boolean(resolved.subtitle)
47575
47426
  });
47576
47427
  if (legendBand > topPad) topPad = legendBand;
@@ -48659,7 +48510,7 @@ function layoutMap(resolved, data, size, opts) {
48659
48510
  width,
48660
48511
  height,
48661
48512
  background: water,
48662
- title: resolved.title,
48513
+ title: shownTitle,
48663
48514
  ...resolved.subtitle !== void 0 && { subtitle: resolved.subtitle },
48664
48515
  ...resolved.caption !== void 0 && { caption: resolved.caption },
48665
48516
  regions,
@@ -49069,9 +48920,10 @@ function renderMap(container, resolved, data, palette, isDark, onClickItem, expo
49069
48920
  wireSync(lt, leg.lineNumber);
49070
48921
  }
49071
48922
  });
48923
+ const clusterUi = !exportDims && !resolved.directives.noClusterPois;
49072
48924
  const gSpider = svg.append("g").attr("class", "dgmo-map-spider");
49073
48925
  for (const cl of layout.clusters) {
49074
- if (!exportDims) {
48926
+ if (clusterUi) {
49075
48927
  gSpider.append("circle").attr("cx", cl.cx).attr("cy", cl.cy).attr("r", cl.hitR).attr("fill", "transparent").attr("data-cluster-hit", cl.id).style("cursor", "pointer");
49076
48928
  }
49077
48929
  for (const leg of cl.legs) {
@@ -49163,13 +49015,18 @@ function renderMap(container, resolved, data, palette, isDark, onClickItem, expo
49163
49015
  }
49164
49016
  wireSync(t, lab.lineNumber);
49165
49017
  }
49166
- if (!exportDims && layout.clusters.length) {
49018
+ if (clusterUi && layout.clusters.length) {
49167
49019
  const gBadge = svg.append("g").attr("class", "dgmo-map-cluster-badges");
49168
49020
  for (const cl of layout.clusters) {
49169
49021
  const g = gBadge.append("g").attr("data-cluster", cl.id).style("opacity", 0).style("pointer-events", "none");
49170
49022
  const R = 9;
49171
49023
  g.append("circle").attr("cx", cl.cx).attr("cy", cl.cy).attr("r", R).attr("fill", mix(palette.textMuted, palette.bg, 35)).attr("stroke", palette.textMuted).attr("stroke-width", 1);
49172
49024
  g.append("circle").attr("cx", cl.cx).attr("cy", cl.cy).attr("r", R + 2.5).attr("fill", "none").attr("stroke", palette.textMuted).attr("stroke-width", 1);
49025
+ const beadR = R + 2.5;
49026
+ for (const leg of cl.legs) {
49027
+ const a = Math.atan2(leg.y2 - cl.cy, leg.x2 - cl.cx);
49028
+ g.append("circle").attr("class", "dgmo-map-cluster-bead").attr("cx", cl.cx + beadR * Math.cos(a)).attr("cy", cl.cy + beadR * Math.sin(a)).attr("r", 1.8).attr("fill", leg.color).attr("stroke", palette.bg).attr("stroke-width", 0.5);
49029
+ }
49173
49030
  emitText(
49174
49031
  g,
49175
49032
  cl.cx,
@@ -52095,10 +51952,12 @@ function renderSequenceDiagram(container, parsed, palette, isDark, _onNavigateTo
52095
51952
  isDark ? 15 : 20
52096
51953
  ) : isDark ? palette.surface : palette.bg;
52097
51954
  const strokeColor = groupTagColor || palette.textMuted;
52098
- const groupG = svg.append("g").attr("class", "group-box-wrapper").attr("data-group-toggle", "").attr("data-group-line", String(group.lineNumber)).attr("cursor", "pointer");
51955
+ const groupG = svg.append("g").attr("class", "group-box-wrapper").attr("data-group-toggle", "").attr("data-group-line", String(group.lineNumber)).attr("tabindex", "0").attr("role", "button").attr("aria-expanded", "true").attr("cursor", "pointer");
52099
51956
  groupG.append("title").text("Click to collapse");
52100
- groupG.append("rect").attr("x", minX).attr("y", boxY).attr("width", maxX - minX).attr("height", boxH).attr("rx", 6).attr("fill", fillColor).attr("stroke", strokeColor).attr("stroke-width", 1).attr("stroke-opacity", 0.5).attr("class", "group-box");
52101
- groupG.append("text").attr("x", minX + 8).attr("y", boxY + GROUP_LABEL_SIZE + 4).attr("fill", strokeColor).attr("font-size", GROUP_LABEL_SIZE).attr("font-weight", "bold").attr("opacity", 0.7).attr("class", "group-label").text(group.name);
51957
+ groupG.append("rect").attr("x", minX).attr("y", boxY).attr("width", maxX - minX).attr("height", boxH).attr("rx", 6).attr("fill", fillColor).attr("stroke", strokeColor).attr("stroke-width", 1).attr("stroke-opacity", 0.5).attr("pointer-events", "none").attr("class", "group-box");
51958
+ groupG.append("rect").attr("x", minX).attr("y", boxY).attr("width", maxX - minX).attr("height", participantStartY - boxY).attr("fill", "transparent").attr("class", "group-label-hit");
51959
+ groupG.append("text").attr("x", minX + 8).attr("y", boxY + GROUP_LABEL_SIZE + 4).attr("fill", strokeColor).attr("font-size", GROUP_LABEL_SIZE).attr("opacity", 0.7).attr("pointer-events", "none").attr("class", "group-chevron").text("\u25BE");
51960
+ groupG.append("text").attr("x", minX + 8 + GROUP_LABEL_SIZE + 2).attr("y", boxY + GROUP_LABEL_SIZE + 4).attr("fill", strokeColor).attr("font-size", GROUP_LABEL_SIZE).attr("font-weight", "bold").attr("opacity", 0.7).attr("pointer-events", "none").attr("class", "group-label").text(group.name);
52102
51961
  }
52103
51962
  const lifelineStartY = lifelineStartY0;
52104
51963
  participants.forEach((participant) => {
@@ -52140,7 +51999,7 @@ function renderSequenceDiagram(container, parsed, palette, isDark, _onNavigateTo
52140
51999
  const participantG = svg.select(
52141
52000
  `.participant[data-participant-id="${participant.id}"]`
52142
52001
  );
52143
- participantG.attr("data-group-toggle", "").attr("data-group-line", String(meta.lineNumber)).attr("cursor", "pointer");
52002
+ participantG.attr("data-group-toggle", "").attr("data-group-line", String(meta.lineNumber)).attr("tabindex", "0").attr("role", "button").attr("aria-expanded", "false").attr("cursor", "pointer");
52144
52003
  participantG.append("title").text("Click to expand");
52145
52004
  const pFill = effectiveTagColor ? mix(
52146
52005
  effectiveTagColor,
@@ -54119,7 +53978,7 @@ function renderArcDiagram(container, parsed, palette, _isDark, onClickItem, expo
54119
53978
  neighbors2.get(link.source).add(link.target);
54120
53979
  neighbors2.get(link.target).add(link.source);
54121
53980
  }
54122
- const FADE_OPACITY3 = 0.1;
53981
+ const FADE_OPACITY2 = 0.1;
54123
53982
  function handleMouseEnter(hovered) {
54124
53983
  const connected = neighbors2.get(hovered);
54125
53984
  g.selectAll(".arc-link").each(function() {
@@ -54127,13 +53986,13 @@ function renderArcDiagram(container, parsed, palette, _isDark, onClickItem, expo
54127
53986
  const src = el.attr("data-source");
54128
53987
  const tgt = el.attr("data-target");
54129
53988
  const isRelated = src === hovered || tgt === hovered;
54130
- el.attr("stroke-opacity", isRelated ? 0.85 : FADE_OPACITY3);
53989
+ el.attr("stroke-opacity", isRelated ? 0.85 : FADE_OPACITY2);
54131
53990
  });
54132
53991
  g.selectAll(".arc-node").each(function() {
54133
53992
  const el = d3Selection23.select(this);
54134
53993
  const name = el.attr("data-node");
54135
53994
  const isRelated = name === hovered || connected.has(name);
54136
- el.attr("opacity", isRelated ? 1 : FADE_OPACITY3);
53995
+ el.attr("opacity", isRelated ? 1 : FADE_OPACITY2);
54137
53996
  });
54138
53997
  }
54139
53998
  function handleMouseLeave() {
@@ -54157,11 +54016,11 @@ function renderArcDiagram(container, parsed, palette, _isDark, onClickItem, expo
54157
54016
  g.selectAll(".arc-link").each(function() {
54158
54017
  const el = d3Selection23.select(this);
54159
54018
  const isRelated = members.has(el.attr("data-source")) || members.has(el.attr("data-target"));
54160
- el.attr("stroke-opacity", isRelated ? 0.85 : FADE_OPACITY3);
54019
+ el.attr("stroke-opacity", isRelated ? 0.85 : FADE_OPACITY2);
54161
54020
  });
54162
54021
  g.selectAll(".arc-node").each(function() {
54163
54022
  const el = d3Selection23.select(this);
54164
- el.attr("opacity", members.has(el.attr("data-node")) ? 1 : FADE_OPACITY3);
54023
+ el.attr("opacity", members.has(el.attr("data-node")) ? 1 : FADE_OPACITY2);
54165
54024
  });
54166
54025
  g.selectAll(".arc-group-band").each(function() {
54167
54026
  const el = d3Selection23.select(this);
@@ -54683,23 +54542,23 @@ function setupTimeline(container, parsed, palette, isDark, exportDims, activeTag
54683
54542
  };
54684
54543
  }
54685
54544
  function makeTimelineHoverHelpers() {
54686
- const FADE_OPACITY3 = 0.1;
54545
+ const FADE_OPACITY2 = 0.1;
54687
54546
  function fadeToGroup(g, groupName) {
54688
54547
  g.selectAll(".tl-event").each(function() {
54689
54548
  const el = d3Selection23.select(this);
54690
54549
  const evGroup = el.attr("data-group");
54691
- el.attr("opacity", evGroup === groupName ? 1 : FADE_OPACITY3);
54550
+ el.attr("opacity", evGroup === groupName ? 1 : FADE_OPACITY2);
54692
54551
  });
54693
54552
  g.selectAll(".tl-legend-item, .tl-lane-header").each(
54694
54553
  function() {
54695
54554
  const el = d3Selection23.select(this);
54696
54555
  const name = el.attr("data-group");
54697
- el.attr("opacity", name === groupName ? 1 : FADE_OPACITY3);
54556
+ el.attr("opacity", name === groupName ? 1 : FADE_OPACITY2);
54698
54557
  }
54699
54558
  );
54700
54559
  g.selectAll(".tl-marker").attr(
54701
54560
  "opacity",
54702
- FADE_OPACITY3
54561
+ FADE_OPACITY2
54703
54562
  );
54704
54563
  }
54705
54564
  function fadeToEra(g, eraStart, eraEnd) {
@@ -54709,40 +54568,40 @@ function makeTimelineHoverHelpers() {
54709
54568
  const endDate = el.attr("data-end-date");
54710
54569
  const evEnd = endDate ? parseFloat(endDate) : date;
54711
54570
  const inside = evEnd >= eraStart && date <= eraEnd;
54712
- el.attr("opacity", inside ? 1 : FADE_OPACITY3);
54571
+ el.attr("opacity", inside ? 1 : FADE_OPACITY2);
54713
54572
  });
54714
54573
  g.selectAll(".tl-legend-item, .tl-lane-header").attr(
54715
54574
  "opacity",
54716
- FADE_OPACITY3
54575
+ FADE_OPACITY2
54717
54576
  );
54718
54577
  g.selectAll(".tl-era").each(function() {
54719
54578
  const el = d3Selection23.select(this);
54720
54579
  const s = parseFloat(el.attr("data-era-start"));
54721
54580
  const e = parseFloat(el.attr("data-era-end"));
54722
54581
  const isSelf = s === eraStart && e === eraEnd;
54723
- el.attr("opacity", isSelf ? 1 : FADE_OPACITY3);
54582
+ el.attr("opacity", isSelf ? 1 : FADE_OPACITY2);
54724
54583
  });
54725
54584
  g.selectAll(".tl-marker").each(function() {
54726
54585
  const el = d3Selection23.select(this);
54727
54586
  const date = parseFloat(el.attr("data-marker-date"));
54728
54587
  const inside = date >= eraStart && date <= eraEnd;
54729
- el.attr("opacity", inside ? 1 : FADE_OPACITY3);
54588
+ el.attr("opacity", inside ? 1 : FADE_OPACITY2);
54730
54589
  });
54731
54590
  }
54732
54591
  function fadeToMarker(g, markerDate) {
54733
54592
  g.selectAll(".tl-event").attr(
54734
54593
  "opacity",
54735
- FADE_OPACITY3
54594
+ FADE_OPACITY2
54736
54595
  );
54737
- g.selectAll(".tl-era").attr("opacity", FADE_OPACITY3);
54596
+ g.selectAll(".tl-era").attr("opacity", FADE_OPACITY2);
54738
54597
  g.selectAll(".tl-legend-item, .tl-lane-header").attr(
54739
54598
  "opacity",
54740
- FADE_OPACITY3
54599
+ FADE_OPACITY2
54741
54600
  );
54742
54601
  g.selectAll(".tl-marker").each(function() {
54743
54602
  const el = d3Selection23.select(this);
54744
54603
  const date = parseFloat(el.attr("data-marker-date"));
54745
- el.attr("opacity", date === markerDate ? 1 : FADE_OPACITY3);
54604
+ el.attr("opacity", date === markerDate ? 1 : FADE_OPACITY2);
54746
54605
  });
54747
54606
  }
54748
54607
  function fadeReset(g) {
@@ -54756,15 +54615,15 @@ function makeTimelineHoverHelpers() {
54756
54615
  g.selectAll(".tl-event").each(function() {
54757
54616
  const el = d3Selection23.select(this);
54758
54617
  const val = el.attr(attrName);
54759
- el.attr("opacity", val === tagValue ? 1 : FADE_OPACITY3);
54618
+ el.attr("opacity", val === tagValue ? 1 : FADE_OPACITY2);
54760
54619
  });
54761
54620
  g.selectAll(".tl-legend-item, .tl-lane-header").attr(
54762
54621
  "opacity",
54763
- FADE_OPACITY3
54622
+ FADE_OPACITY2
54764
54623
  );
54765
54624
  g.selectAll(".tl-marker").attr(
54766
54625
  "opacity",
54767
- FADE_OPACITY3
54626
+ FADE_OPACITY2
54768
54627
  );
54769
54628
  g.selectAll(".tl-tag-legend-entry").each(function() {
54770
54629
  const el = d3Selection23.select(this);
@@ -54773,7 +54632,7 @@ function makeTimelineHoverHelpers() {
54773
54632
  const entryGroup = el.attr("data-tag-group");
54774
54633
  el.attr(
54775
54634
  "opacity",
54776
- entryGroup === tagKey && entryValue === tagValue ? 1 : FADE_OPACITY3
54635
+ entryGroup === tagKey && entryValue === tagValue ? 1 : FADE_OPACITY2
54777
54636
  );
54778
54637
  });
54779
54638
  }
@@ -54783,7 +54642,7 @@ function makeTimelineHoverHelpers() {
54783
54642
  }
54784
54643
  }
54785
54644
  return {
54786
- FADE_OPACITY: FADE_OPACITY3,
54645
+ FADE_OPACITY: FADE_OPACITY2,
54787
54646
  fadeToGroup,
54788
54647
  fadeToEra,
54789
54648
  fadeToMarker,
@@ -54795,7 +54654,7 @@ function makeTimelineHoverHelpers() {
54795
54654
  function renderTimelineTagLegendOverlay(container, parsed, palette, isDark, setup, hovers, onClickItem, exportDims, swimlaneTagGroup, activeTagGroup, onTagStateChange, viewMode, exportMode) {
54796
54655
  if (parsed.timelineTagGroups.length === 0) return;
54797
54656
  const { width, textColor, groupColorMap, solid } = setup;
54798
- const { FADE_OPACITY: FADE_OPACITY3, fadeReset, fadeToTagValue } = hovers;
54657
+ const { FADE_OPACITY: FADE_OPACITY2, fadeReset, fadeToTagValue } = hovers;
54799
54658
  const title = parsed.noTitle ? null : parsed.title;
54800
54659
  const { timelineEvents } = parsed;
54801
54660
  const LG_HEIGHT = LEGEND_HEIGHT;
@@ -54885,7 +54744,7 @@ function renderTimelineTagLegendOverlay(container, parsed, palette, isDark, setu
54885
54744
  const eg = el.attr("data-tag-group") ?? el.node()?.closest?.("[data-tag-group]")?.getAttribute("data-tag-group");
54886
54745
  el.attr(
54887
54746
  "opacity",
54888
- eg === tagKey && ev === tagVal ? 1 : FADE_OPACITY3
54747
+ eg === tagKey && ev === tagVal ? 1 : FADE_OPACITY2
54889
54748
  );
54890
54749
  });
54891
54750
  } else {
@@ -57644,6 +57503,9 @@ async function renderForExport(content, theme, palette, viewState, options) {
57644
57503
  const { renderSequenceDiagram: renderSequenceDiagram2 } = await Promise.resolve().then(() => (init_renderer20(), renderer_exports20));
57645
57504
  const seqParsed = parseSequenceDgmo2(content);
57646
57505
  if (seqParsed.error || seqParsed.participants.length === 0) return "";
57506
+ const collapsedSections = viewState?.cs ? new Set(viewState.cs) : void 0;
57507
+ const collapsedGroups = viewState?.cg ? new Set(viewState.cg.map(Number).filter((n) => Number.isFinite(n))) : void 0;
57508
+ const seqActiveTagGroup = viewState?.tag ?? options?.tagGroup;
57647
57509
  renderSequenceDiagram2(
57648
57510
  container,
57649
57511
  seqParsed,
@@ -57652,9 +57514,11 @@ async function renderForExport(content, theme, palette, viewState, options) {
57652
57514
  void 0,
57653
57515
  {
57654
57516
  exportWidth: EXPORT_WIDTH,
57655
- ...options?.tagGroup !== void 0 && {
57656
- activeTagGroup: options.tagGroup
57657
- }
57517
+ ...seqActiveTagGroup !== void 0 && {
57518
+ activeTagGroup: seqActiveTagGroup
57519
+ },
57520
+ ...collapsedSections !== void 0 && { collapsedSections },
57521
+ ...collapsedGroups !== void 0 && { collapsedGroups }
57658
57522
  }
57659
57523
  );
57660
57524
  } else if (parsed.type === "wordcloud") {
@@ -58624,6 +58488,7 @@ var DIRECTIVE_KEYWORDS = /* @__PURE__ */ new Set([
58624
58488
  "no-region-labels",
58625
58489
  "no-poi-labels",
58626
58490
  "no-colorize",
58491
+ "no-cluster-pois",
58627
58492
  "poi",
58628
58493
  "route",
58629
58494
  // Data charts
@@ -59293,7 +59158,7 @@ pre.dgmo, code.language-dgmo, pre > code.language-dgmo,
59293
59158
 
59294
59159
  // src/auto/index.ts
59295
59160
  init_safe_href();
59296
- var VERSION = "0.24.0";
59161
+ var VERSION = "0.25.1";
59297
59162
  var DEFAULTS = {
59298
59163
  theme: "auto",
59299
59164
  palette: "nord",