#601·archify

[Bug]: Hiding the sequence legend clips activations on an automatic canvas

Author: To3akaRinCreated Sep 28, 2026Updated Sep 28, 2026

Version and environment

Git clone of dev at e825eb20faab530f911368b2a41a4c10fc915b41, Node 22.23.1, macOS, Sequence.

Minimal input

Save as activation.sequence.json:

json
{
  "schema_version": 1,
  "diagram_type": "sequence",
  "meta": {
    "title": "Activation capacity",
    "output": "activation.html",
    "quality_profile": "showcase",
    "column_fit": "spread",
    "legend": { "mode": "hidden" }
  },
  "participants": [
    { "id": "client", "type": "external", "label": "Client" },
    { "id": "api", "type": "backend", "label": "API" }
  ],
  "messages": [
    { "id": "request", "from": "client", "to": "api", "y": 200, "label": "request" }
  ],
  "activations": [{ "participant": "api", "from": 180, "to": 1200 }]
}
bash
node archify/bin/archify.mjs validate sequence activation.sequence.json --json
node archify/bin/archify.mjs render sequence activation.sequence.json activation.html
node archify/bin/archify.mjs deliver sequence activation.sequence.json activation.html --json

Actual behavior

All three commands exit 0. The delivered SVG has viewBox="0 0 920 760", but the activation rectangle has y="180" and height="1020": its bottom is at 1200, 440 SVG units outside the canvas.

Remove only meta.legend and repeat: all three commands still succeed, and the automatic height becomes 1298, containing the same activation. The reproduction specifies no meta.viewBox.

The Sequence README defines activation from/to as y pixel coordinates. This observation follows directly from the generated SVG bounds; no browser screenshot/perceptual pass is claimed.

Expected behavior and scope

Hiding the legend should not discard the space required by authored timeline content. An automatically sized canvas should still contain its messages, notes, activations and segments. An explicitly authored meta.viewBox should remain authoritative.

contentBottom already measures those elements, but automatic height depends only on legendRequiredHeight(). When no legend entries remain, that function returns 0 and loses the content budget with it.

I plan to separate automatic content capacity from optional legend capacity, reuse existing timeline margins, and add public CLI regressions. The bounded fix preserves short/default examples, visible-legend behavior and authored coordinates. It does not introduce new hard validation rules for all explicit activation ranges or change Viewer layout.

Checks

  • Searched related issue/PR work; #592 addresses visible legend/lifeline placement, and #564/#568 concern segment headings, not hidden-legend content capacity.
  • Reproduction contains no private data or credentials.