Skip to content

Diagram batch B: new parts, automatic layout and the viewer (DECISIONS 306–328) - #130

Merged
bmjcoding merged 64 commits into
mainfrom
claude/diagrams-b
Nov 24, 2026
Merged

bmjcoding merged 64 commits into
mainfrom
claude/diagrams-b

Conversation

@bmjcoding

@bmjcoding bmjcoding commented Nov 24, 2026 •

Copy link
Copy Markdown
Owner

Diagram batch B: new parts for the five diagram types, automatic layout with elkjs, and a viewer with zoom (DECISIONS 301, 306, 310, 313, 317, 318, 322, 326, 328). A handoff, so the council's decision is the approval to build; the owner sees this PR before it merges.

What it adds

  • Schema: crow's-foot cardinality (the 14px zone, ring and foot), keys to tables two or more columns away routed through corridors, and the marked-gutter lane rule.
  • Sequence: activation bars, opt / alt / loop / par frames, a quiet run, and a text-art form drawn by ink (no reveal, no caret). On a phone it reads as a transcript, and a long route wraps before its arrow.
  • Groups and end lanes: nested groups. A stacked group entered by a turn gets space-12 above it, and its label sits beside its turn.
  • Cards, keys, touch, first visit, dashed flow, marks on steps and participants, and print, right to left and export.
  • Automatic layout (layout="auto"): elkjs assigns each card a column and a row, and Basalt's own router draws the lines. Two layouts per direction; a figure that can't draw in either direction says why in development. elkjs is a dev dependency at exactly 0.12.1 and ships once, as dist/diagram-elk.js with its licence (EPL-2.0 OR GPL-3.0-or-later). It loads only for an automatic figure, never on a phone and never for a fixed layout. The HTML skill places figures at build time and never ships elkjs.
  • The viewer (the owner's addition, DECISIONS 310): Expand opens the figure in a native <dialog> with its rim. Zoom −/+, Fit, pan and keys; SVG, so nothing loses quality. It loads elkjs on Expand.
  • Foundations, motion.md and AGENTS.md: section 6's text, including the lifeline's activation bar and a frame's sides added to the named vertical lines.

For the owner's eye

In review round 66 (npm run review -- 66), dark and light:

  1. Automatic layout: 05-auto-1440, 05-auto-390, and the architecture laid right in the viewer, 05-auto-viewer-1440.
  2. The activation bar, a vertical bar by shape: 03-sequence-1440 and the close crop round66-bars/activation-bars.
  3. Text art, built by ink: 06-text-1440. On a phone, the transcript: 06-text-390.
  4. The viewer: 01-viewer-viewer-1440/390, 01-viewer-viewer-200-1440/390, 02-architecture-viewer-1440/390, the text art in the viewer 06-text-viewer-1440/390. Viewer shots open by script, so the focus ring shows.
  5. Schema with crow's foot and a far key: 04-schema-1440, 04-schema-390.
  6. A nested group's label at 390: 02-architecture-390.
  7. Frames on a phone: 03-sequence-390.
  8. Right to left: 07-rtl-1440, 07-rtl-390.
  9. Clear highlight and the tap hint: 10-data-flow-390. Print from dark: 09-print-print-1440.
  10. Parts never pictured before: 10-data-flow-1440/390, 11-calls-1440/390.

Known gap, named in foundations 6.9: right to left, the stacked drawing does not mirror yet ("drawn, the figure mirrors; stacked, not yet"). It is on the backlog.

Council

Heavy round. Grok scouted. Neon (Draft B) and Muse (Draft A) drafted. Opus checked: the owner took the GPT seat off diagrams (DECISIONS 284). Fable decided (306) and answered four objections by revising all four (313). The final positions, word for word:

Muse (Draft A): agree

agree

I was Draft A. The decision takes Draft B's engine for what is drawn and my notes for the contract, as the check recommended, and I would not defend my prototype where it replaces it: my text art corrupted its own words and scrolled 2.3 times its width at 390 (A-1), my frame headers were struck through by lifelines (A-2), my automatic layout never drew the reference figure on the 1,104 row (A-3), and my link card could not be reached by keyboard (A-4). Draft B's art and transcript, plated frame words, and the link as the roving stop with foundations' arrow as its cue (1.2, 1.4) are the right answers to each.

The decider's three new parts are each better than what either draft had. Automatic layout as a column and a row from elkjs, with Basalt's own router, extents and fit rule on top (1.8), is the design my draft already used for the HTML skill; making it the whole design removes Draft B's elk group boxes (B-2) and my free-rectangle router at once, and grid-place.txt shows no shared cell, no non-member in a group and a clean shape for every line on the CIMIP figures. Spatial keys on tracks (1.5) fix the wrong moves both drafts made on the schema (A-5, B-3): spatial-cells.txt shows every card reachable from every card in all five figures, and the three moves the check found now do nothing, as they should. Nesting several end lines outermost-lowest, space-5 apart (1.3), answers the crossing and touching labels the check measured in Draft B.

The text art at rest with a build by ink and no caret (1.2) is the call I argued for: Draft B's reveal hid every word for five seconds (B-1) against rules the owner approved after the research that asked for it, and putting it first in the list for his eye on the PR is the honest way to surface it. Cardinality on every key or none (1.1) is also right where my draft was wrong: filling an unstated end with "zero or many" invents a fact about the reader's data.

One risk stands, and the decision names it rather than hiding it: the layout proof routes on cells, not pixels, so label seats, lanes and cuts on an automatic placement are unproven until the build. That is a reason to hold the build to section 8's tests — the merged geometry suite on the placed figures at 1,104, in both themes — not a reason to object to the design. If a placement fails those tests the figure stacks, which is the safe failure.

Neon (Draft B): object (all three revised by Fable)

object

The decision's overall shape holds together well: Draft B's engine base with Draft A's contracts, grid placement for automatic layout, track-based spatial arrow keys, cutting the text-art reveal/caret in favour of building by ink, and all three PR #126 calls in section 4 are solid improvements over my draft. I object on three specific technical defects in sections 1.8, 1.1, and 1.3 where the written rules conflict with elkjs@0.12.1 or diagram-core.ts's geometry.

  1. Section 1.8 (8.2 and 8.7) — Partition hints do not hold under 8.2's fixed ELK options.

    • Evidence: Measured directly on the vendored elk.bundled.js 0.12.1 (b1032b7c…a0d7), which proof/grid-place.mjs did not run with partitions (Draft A tested partitions only on a flat graph without INCLUDE_CHILDREN or MODEL_ORDER):
      • With groups (INCLUDE_CHILDREN), ELK silently ignores elk.partitioning.partition on grouped nodes under every cycle-breaking strategy (MODEL_ORDER, GREEDY_MODEL_ORDER, GREEDY). On CIMIP's architecture with group:aws, hinting just ecs (col: 2, partition 1) and svc (col: 3, partition 2) still places ecs at x = 747 after svc at x = 517; partitioning all columns produces 5 partition-order violations (ecs > svc, agent > aurora/s3, sys > aurora/s3).
      • Even without groups, 8.2's elk.layered.cycleBreaking.strategy: "MODEL_ORDER" breaks partitioning: with INCLUDE_CHILDREN on ungrouped CIMIP architecture (all columns partitioned), ecs (x = 804) still lands after svc (x = 540); without INCLUDE_CHILDREN, MODEL_ORDER + elk.partitioning.activate throws an uncaught TypeError: Cannot read properties of null (reading 'a') inside elk.bundled.js (both all-partitioned and 2-node reverse-partitioned).
    • Instead: Drop col/row partition hints under layout: "auto" (ignore or warn on kept col/row in "auto", and keep 8.7's guidance to start from placeDiagram's returned cells in layout: "authored" when moving cards). If partition hints are kept for ungrouped figures only, switch 8.2 from MODEL_ORDER to GREEDY_MODEL_ORDER (0 violations on flat graphs; identical grid-place.json cells for architecture and flowchart) and make a hint on a grouped node a development warning/error instead of promising an invariant ELK does not enforce.
  2. Section 1.1 — The 56px marked schema gap and 11px ring centre collide on three-lane gutters.

    • Evidence: A size-dot (6px, r = 3) ring with a 1px stroke centred at 11px extends to 14.5px, overhanging size-diagram-foot (14px). In a 56px column gap, three overlapping lanes — which occur in CIMIP's extended gutter c2 (two distinct users.id cardinalities alongside the incidents.id bus, visible in drafts/b/shots/schema-1440-dark.png) and in proof/grid-place.json's schema, DOWN gutter c2 (three overlapping buses: incidents.id, sandboxes.id, agent_runs.id) — space evenly at 56 / 4 = 14px (14, 28, 42px). Outer lanes sit 14px from the table edge: 0px outside size-diagram-foot, snapping to 13.5px (dropping the line under 1.1's zone check) or 14.5px (a sharp 90° bend grazing the ring stroke, visible on incidents.commander_id, agent_runs.incident_id, and sandboxes.incident_id in drafts/b/shots/schema-1440-dark.png). Spacing 2–3 lanes strictly inside the remaining 28px channel yields 9.3px or 7px pitch, violating diagram-core.ts's space-3 (12px) minimum lane separation.
    • Instead: Set the marked schema column gap to space-16 (64px, an existing single token; 4 × 224 + 3 × 64 = 1,088px, still fitting the 1,104px row; three lanes sit at 16, 32, 48px, 16px apart and ≥ 15.5px after half-pixel snapping) and centre the optional ring at 10.5px (with the crow's-foot vertex at 7.5px, as in drafts/b/engine.js:572,576) so the ring and its 1px stroke finish at 14.0px, wholly inside size-diagram-foot.
  3. Section 1.3 (and 6.3) — Multi-entry stacked label seating is unspecified and fails the merged seat check.

    • Evidence: Reversing the entry nesting (outermost lane turns lowest at space-4 and enters space-6 in; each inner lane turns space-5 higher and enters space-3 further in) removes the crossing between entries, but leaves the inner line's vertical drop (x = r - 36, y = t - 36..t) cutting across the outer line's turn height (y = t - 16). Under diagram-core.ts:1806,1828, an end-down label seats space-2-5 (10px) clear of its own entry (r - 24 - 10 = r - 34) and fails if its box grown space-1 intersects another line. Growing the gap lengthens the inner drop without clearing it, so measureFigure marks the outer label unseated and bares the stacked figure.
    • Instead: Specify in 1.3 (and 6.3) that when several end lines enter one card, every entry's label anchors space-2-5 clear of the innermost entry's drop (innermost_ex − space-2-5 in LTR, mirrored in RTL, as in drafts/b/engine.js:2326), keeping space-1 clearance from every vertical drop (r - 36 - 10 + 4 = r - 42 < r - 36) alongside the space-5 vertical pitch.
Opus (checker): object (revised by Fable)

object

Opus (checker). I agree with the decision except for one rule, in section 4.3. Every blocking finding from my check (A-1 to A-5,
B-1 to B-3) is answered, and answered better than I asked for in the two places where the decision went past my fix:

  • Automatic layout (1.8). Reading only a column and a row from elk makes B-2 impossible to hit, rather than fixing it after the
    fact. The proof reproduces on three runs.
  • Spatial keys (1.5). Running them on tracks fixes all three wrong moves I measured on the schema
    (proof/spatial-cells.txt).

I also checked the entry rule in 1.3 (outermost lane turns lowest) on paper. It holds: none of the outer line's runs meet the inner
line's runs.

Objection, 4.3: the new "does not fit" test can break the merged rule that a figure drawn at one width is drawn at every wider one.

  • The rule as written. "A side that cannot hold its lines that way at the card's measured height does not fit: the figure is
    stacked at that width."
  • Why it breaks the merged rule. A card's measured height goes down as the figure gets wider, because a track gets wider and its
    words wrap less. So a side can pass at 976, where the card is 56 tall with a wrapped detail, and fail at 1,104, where the same card
    is 40 tall. The figure would then be drawn at the narrow width and stacked at the wide one. That breaks foundations' Lines bullet:
    "from the first width a diagram draws at, it draws at every wider one" (review round 64). Section 4.1 fixes this same kind of break
    for the diamond.
  • The trigger is common, not rare. On a 40px card, the builder's sharing for a straight line plus two others puts them at 20,
    26.7 and 33.3. That is 6.7 apart, under size-diagram-head, and 33.3 is inside the bottom corner's 8px curve. So the case is a
    straight line with two others, not only Neon's 0.875.
  • What I'd have instead. A card grows to the least height at which the shared slots land on the flat part, with each pair
    size-diagram-head apart. For a straight line with two others that is 48. The row takes that height as it takes any taller card. A development build still says "use another side".
  • Result. The figure never stacks over this. The test can't flip with width, and only a card that would fail today changes
    height.
  • If the council won't grow a card. Then judge the side at the card's least height (its height at its widest track), so the
    answer is the same at every width.
  • The test. In diagram-fixes.test.mjs, the "40px card … is stacked" case becomes "is drawn, its ports on the flat part and 8
    apart, at every width from its first drawn one".

Notes for the build, not objections:

  • The diamond sweep (4.1). Sweep it to 1,440 as well, not only to 1,104. A figure inside an app is not held to the page row, and
    the 962 to 970 flip shows the diamond's fit is not monotonic on its own.
  • "Clear highlight" (1.5). On a hybrid laptop, a figure that only becomes "on touch" after its first touch tap mounts the button
    at that moment, so the foot moves once. The test's "nothing in the foot moves when it enables" should cover that tap too.
  • Link card names (1.4). A link card's name is the node's sentence. It must begin with the card's visible name (WCAG 2.5.3,
    Label in Name), and the link-card tests should assert that.
  • Automatic figures were not drawn for this decision. The decider's proof routes on cells, not pixels, and says so. The PR's
    pictures of the automatic architecture (3 by 6 on the 1,104 row) and of the automatic schema are the first time anyone sees one
    drawn through Basalt's router. They should be in front of the owner as item 3 says, not as a test result alone.
Seat Review of 65fa32bd Re-check of 19d23b20 Last look at 40608be1
Neon (code); Opus re-checked in Neon's place (out on usage limits) 5.5/10, 12 blocking Opus 7/10, 2 blocking, fixed not re-reviewed
Fable (pixels) 6/10, 7 blocking 8/10, 1 blocking, fixed the gap at 48 confirmed; text art, wrap and label measured as ruled

The spacing sweep's 66-1 to 66-3 (DECISIONS 328) are built. Fable's re-check also ruled four calls:

  • development checks report with console.error once per figure and draw what production draws;
  • elkjs ships as one copy;
  • a wrapped transcript route breaks before its arrow;
  • a stacked label stays beside its turn.

Bug fix with no panel: on touch, the dead "Clear highlight" button is removed from text figures. The code documents that it appears only when a figure can be traced, and the skill already omitted it. The last fixes (dbbce9fe, ca76f333) and the merge with main (0f74f0eb) were not reviewed by a seat.

Checks

Lint, both typechecks, npm run build and npm run sizes pass. On the merged tree, 371 node-only tests pass.

Browser tests did not run. The owner paused them on 24 Nov (DECISIONS 330). Every new or changed browser test in this batch is written but has never run, so expect some to need fixes when the pause lifts. These are:

  • the viewer, keys, output, sequence, parts, fixes and layout tests;
  • touch tracing, network requests for the lazy elk chunk, skill/React parity for the nine figures, and a pinch;
  • diagram-review.test.mjs.

npm run ci:local has not run on this head.

Merged with main after #129

2ae5f41b merges main cbab8c4e (#129: oxlint, repo review fixes, the safe-sinks rule).

  • diagram-figure.tsx: both sides are kept. Repo review: oxlint, review fixes, and the safe-sinks rule #129's fix keys the figure's options on whether there is a source, so it isn't measured again on every render. Its intent is applied to the viewer too.
  • What Repo review: oxlint, review fixes, and the safe-sinks rule #129's rules flagged in batch B, now fixed:
    • one new Array().join became repeat;
    • each of the viewer's two dangerouslySetInnerHTML (markup the engine builds and escapes) has a sink: note and an exception, with a new node test that passes hostile words through the list, the key, the transcript and the text art;
    • the export button's words use textContent;
    • the skill's diagram sinks are listed in sinks.allowed.json;
    • a text sequence with export is added to the hostile-input page.
  • What passes on the merged tree: lint (all five steps), both typechecks, the build, sizes, and the node-only tests (373). sinks.test.mjs launches Chromium, so it did not run; its node check was run inline.
  • Sizes: each diagram is about 101.2–101.3 KB (+347 bytes from Repo review: oxlint, review fixes, and the safe-sinks rule #129's shared mark check). The skill's diagram cap is 145,450. SKILL.md is at main's 13,050 cap, with one diagram line shortened.

Sizes

  • Each diagram component: about 100.9 KB, past the 5% gate. The owner approved the raise (DECISIONS 317, 318), and everything not drawn on first paint is in lazy chunks.
  • The skill's diagram modules are capped at what they measure, each with its reason in modules.json.
  • SKILL.md stays within 12,800 bytes (12,799): the merge's wording was tightened and no rule was dropped. Batch B's approved raise to 12,950 was not needed.

Merged with main (e396decf, after #127 and #128) as 0f74f0eb. Both sides are kept in every file, and #127's pause glyph is on the diagram's "Pause animations".

🤖 Generated with Claude Code

bmjcoding and others added 30 commits November 23, 2026 13:57
… in React

"Expand" in every figure's foot opens the figure's drawn layout in a dialog. The figure is drawn again
from the same data, laid out once at 100% at the stage's width (never under its least drawn width, never
over the page row), and zoomed with one transform. Fit opens it; the buttons, the keys, Ctrl and the
wheel, a pinch and a drag zoom and pan it. The zoom and pan are plain DOM (diagram-zoom-core.ts), for the
skill to share. The viewer is a chunk of its own, loaded at Expand's first hover, focus or touch.

Also call 1 of DECISIONS 306, section 4: a decision taller than wide is a fit failure, so the CIMIP
flowchart is stacked through 975 and drawn from 976.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…m module

compose.mjs adds diagram-zoom (with dialog, dialog-form and sheet) to a page with a figure, unless every
figure says "zoom": false. It shares React's zoom and pan (diagram-zoom-core.ts) and draws with the diagram
module's engine (Basalt._.diagramKit), so it holds no second copy of it. Its stylesheet is React's
"Diagram viewer" section, renamed. The viewer's layout moves into the engine (measureViewerFigure), for
both: it measures at 100% whatever the zoom and whatever an opening dialog's scale.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… lazy chunk

Base UI's dialog in the viewer's chunk widened the Base UI chunk every component's bundle shares under
esbuild's splitting (Button alone 19,482 bytes against a limit of 17,650; 33 limits failed). The viewer is
now the form dialog's box on a native modal <dialog>, as the skill's is: the same classes, motion, scrim,
Esc, Tab wrap, scroll lock and focus return. A deviation from 9.2, accepted by the lead as engineering.

"Expand" is words only (a deviation from 9.1, the lead's call): Phosphor's ArrowsOutSimple carried six
weights, 2.2 KB in every still figure, and the core set draws no expand glyph.

The viewer's layout (measureViewerFigure), its hint and its keys words move from the engine into
diagram-zoom-core, which only the viewer's chunk and the skill's diagram-zoom module hold. A still
diagram is now 70,415 bytes against 67,580 recorded (+2,835; the 5% limit is 70,959).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The figure snaps its lines from its drawing's origin on whole pixels, and is laid out again once the
dialog's entrance ends, so the viewer's ink is the page's. The list keeps the drawing's place: it is
saved before the drawing is hidden. A hidden figure's empty measure no longer resets the zoom. In print
the viewer has no transition, so its display change is not held by the dialog's own.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Drawn, the arrows go to the nearest card in that direction by the cards' columns and rows: first a card
sharing a track across the arrow, then the lowest of tracks along plus twice the tracks across; ties to
fewer across, the nearer first row, then the author's order. Arrows are physical (a right-to-left figure
swaps them). A figure where some card cannot be reached keeps the author's order and a development
build says so; stacked, the author's order as before. The hint shows four arrows where the drawn figure
has rows and columns, and the keys sentence says "the nearest part in that direction".

diagram-keys.test.mjs: the five CIMIP tables equal the decision's proof, drawn. The right-to-left half
fails until right to left (1.7) draws these figures; they stack under dir=rtl today.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
size-diagram-activation (8px) and size-diagram-foot (14px), and Tokens.swift regenerated. The token CSS
ends with an @media print block that sets every colour token to its light value on the root and on
every theme selector, with color-scheme light and the diagram marks' switch on its light form,
generated from the light tokens. The HTML skill keeps its own beforeprint switch and leaves the block
out of a page (unifying the two is backlog). The contrast test checks the block.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
In print every line, head, dot and label takes its resting ink with !important, over a trace.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A label may hold one break of its author's: both lines in one ink on one plate, each on a 16px line;
every seat rule takes the taller box, and a stacked gap grows 16. The engine never breaks a label. The
list and the sentences join the lines with a space. A development build warns on a second break, a line
past 28 characters, and a break in a sequence's message. test/fixtures/cimip-diagrams-b.json begins
the extended CIMIP examples, with two two-line labels.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A group may name a parent: two levels. Extents stay derived, innermost first: a group's box is its own
members' and its child groups' boxes grown by the merged measures, so an inner boundary is space-4 inside
the outer at the sides and below and space-8 below its top, radius 8 against the outer's 12. Each level
that reaches an edge adds its room to the drawn padding and to the least width (and the static rules
gain rows for three and four levels). Stacked, a nested group is a wrapper inside its parent's, and a
stacked group's label sits on a ground plate over the lines. The list nests, and a node's sentence names
the chain. A development build warns on a third level, an unknown parent, a cycle, and a non-member
inside any group's box. The extended CIMIP architecture nests "Data & logs" in AWS.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
href on an architecture, flowchart or data flow card or a schema table makes the card itself an <a>
(target _blank adds rel noopener noreferrer). It keeps the figure's roving stop, so Enter follows it, and
its name is its sentence, which begins with the visible name. The cue is the core arrow-right (or
external), 16px after the name's last word, which holds it: secondary at rest, primary and travelling
space-0-5 on hover and focus, turned right to left; the name underlines. A press is a colour step (the
fill under state-hover's wash, from color-mix). 44px tall on touch; LinkText in forced colours. The hint
gains Enter "open" and the keys sentence says so. In the list the name is the same link. A participant
cannot be a link. React's build now draws %glyph-mask:name% from the glyph source, as the skill's does.
The extended CIMIP architecture and schema each carry one link.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A message may carry activate (its receiver starts working) and deactivate (its sender stops after it);
they pair by a stack on each participant, a bar left open closes at that participant's last message, and
three deep at most. A bar is size-diagram-activation wide, the head's fill in a 1px structure edge, a
nested one space-1 toward the end side; a message's line ends on the bar's edge, and a self-call's loop
starts from it. A frame (opt, loop, alt) is structure: 1px solid, radius 12, spanning its participants'
columns, all four sides inside the drawing; its 36px header holds the tab (the operator) and the label,
an alt's later branch starts under an exact 4-on-4 dashed rule and "else", and every word sits on a
ground plate. A frame inside a frame is space-2 inside it where they share a side. A header wider than
its frame refuses the drawn layout. Stacked, a frame is the same box round its rows. The key shows a bar
("Working") and each operator drawn with its words (frameLabels changes them); the list's sub-headings
read "Only if: ...", "Otherwise: ...", and messages keep their numbers; a participant's sentence says
when it is working. Forced colours as 1.10. The extended CIMIP sequence carries an opt holding a loop,
an alt, and two bars.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
diagram-sequence.test.mjs (bars, frames, the stack, a header too wide), diagram-parts.test.mjs (nested
groups, link cards, two-line labels). diagrams.test.mjs follows the spatial keys (the decision's table),
and diagram-motion.test.mjs counts the foot without Expand, which every figure now has. Round 66 shows the
viewer, the extended architecture, sequence and schema, and print.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…6's 200% shot

glyph-mask.mjs writes %glyph-mask:name% for the package's build and for the walkthrough, which reads the
source stylesheet. Round 66's viewer demo waits a frame between steps.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
flow: true is allowed on a dashed edge: its own 6-on-4 dashes march toward the head, one period at
speed-diagram-flow on ease-linear, where 48px of line shows; still, held, traced, under reduced motion,
in forced colours and in print they sit where the key draws them (the loops' own rules).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… 306, 1.6)

mark joins a step and a participant, with 292's section 2 whole. A step takes the architecture card's
seat; a participant's head keeps space-6 clear on both sides of its first line, and the column's minimum
counts both; a stacked chip draws the mark inline before the name, space-1-5 apart. The says warning
reads a step's lane label. compose.mjs writes the marks a page names on steps and participants too.
Round 66 marks the service and the sandbox, never Marcus.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
entrance="first-visit" (with an id): the mark basalt-diagram-entrance:<path>#<id> is written in
localStorage when an entrance that played finishes or gives way to the reader, never on a visit at
rest by mode; a later visit is at rest from its first frame (a few bytes in the still engine, the rest
in the lazy motion module). Storage that throws plays again. A development build warns without an id.
SequenceDiagram also takes frameLabels, and the new types are exported.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Where lines are drawn, a tap (a click from a touch or a pen pointer) on a card traces it; the same card,
the drawing's ground or "Clear highlight" clears it, and Esc. A linked card follows its link. "Clear
highlight" is last in the foot, mounted whenever the figure is on touch (the media's, or after its
first touch tap) and aria-disabled until a trace is up. The hint's seat says "Tap a part to highlight
its lines. Tap it again to clear." on touch. No live region. A card that answers a tap is 44px tall on
touch. None of it prints or shows in the viewer. React and the skill share tapTrace. The affordance is a
few hundred bytes inline: a lazy chunk for one button and one line would cost more than it saves.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
No prop: a figure follows its computed direction, read as it is measured. The model is mirrored (column 1
at the right, a frame's span with it, a named left or right side swapped), and the engine lays it out on
a left-to-right drawing, so every route, seat and lane is the one a left-to-right figure gets; what the
drawing holds is set right to left again. A self-call and a nested bar take their logical sides. The
foreign-key row's arrow and the stacked sequence's inline arrows turn; identifiers are isolated left to
right as runs. Arrow keys stay physical (the table is the mirrored model's). The keys test's right-to-left
half now passes (6/6). Not as written: the stack is not mirrored, because its rail and trunk are laid out
on the left; it is drawn, with every line, where it had none before.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…right to left

@srasyndicate/basalt/diagram-export: diagramToSvg and diagramToPng(figure, options), each a Blob, loaded on
demand by the app and never by the index or a figure. The file holds the title and source, the drawing as
laid out now and the key, on surface-page with space-4 round it, at rest (no trace, mover or pending
entrance): native SVG only, never foreignObject, boxes as rects, the drawing's own SVG with its paint
inlined, marks as images, and every word as SVG text at its measured box; the title is the SVG's title
and the summary its desc. Options: theme (page, light, dark), fonts (embed, by default, or name), scale
(PNG, 2). The skill's diagram-export module ("export": true) adds "Download SVG" and "Download PNG"
to the foot and the viewer's foot. A sequence's heads take their mirrored columns. diagram-output.test.mjs
covers print, right to left and export.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@srasyndicate/basalt/diagram-layout's placeDiagram(figure, direction) is the one module that imports
elkjs (0.12.1, exact; EPL-2.0 OR GPL-3.0-or-later, used under EPL-2.0, unmodified; on the allowlist with
its reason). It hands elk every card at one size, groups as hierarchy and the decision's fixed options,
and reads back each card's column and row by bands, nothing else: CIMIP's architecture places as the
proof's 6 by 3 (right) and 3 by 6 (down). layout="auto" on an architecture, flowchart or schema takes
the cards' tracks from placement (one direction or both); a card's own col and row are not read (no
hints; a development build says so). Each line's sides are chosen from the router's shapes, the line
with the fewest clean ones first. The figure tries the type's direction, then the other, and stacks
when neither fits. Without placement the module loads on demand at 640 or wider, never on a phone;
until it answers the figure is stacked. The HTML skill places at build time: compose.mjs runs
parts/diagram-place.mjs (React's placeDiagram, elkjs from the repository) and writes placement into the
page, which never holds elkjs; Basalt.diagram with auto and no placement warns with the build path.

Measured: CIMIP's automatic schema draws (3 by 5, laid down) at 1104. The automatic architecture and
flowchart stack at 1104: a turn-back's label ("HTTP + SSE") finds no seat, and two lines from one
decision lie on one another. The decision's proof routed on cells only and did not run seats.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
variant="text" draws the sequence's data as box-drawing characters in a code block (surface-sunken, the
rim, radius 8, Mono text-xs), generated by a module of its own (diagram-text, loaded on demand; the
skill's diagram-text module). The focal participant in a double-line box, lifelines and working
stretches, ━━▶ ──▶ ┄┄▷ arrows, frames closed on four sides with the operator in primary, bands as ruled
lines; no character over a word, and a copy is the art. Where its widest line does not fit, the block is
the transcript, which the page holds before script: one line a message, frames as indented brackets,
names never broken; nothing scrolls sideways. The pre is aria-hidden. The key's swatches are the art's
glyphs. Under motion="animated" it builds by ink: labels and arrows lift in message order over
duration-slower, no line hidden and no caret (on its first showing, not yet on coming into view).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…er approved the raise)

Each still diagram is about 87.1 KB against 67.5 KB recorded (+28.9%), the whole package up front
+2.3% and styles.css +6.3%. The PR gives the growth part by part.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… raise)

diagram 92,650 -> 123,200 bytes (the engine's new parts, in the skill's development build, and their
stylesheet), diagram-motion 26,850 -> 27,500, SKILL.md's index 12,650 -> 12,950 (three new module lines);
caps recorded for the new modules at their measured sizes: diagram-zoom 16,900, diagram-export 7,450,
diagram-text 5,450.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…loop, the skill's placer

elkjs's file, verbatim and unmodified, is wrapped as an ES module of its own (dist/diagram-elk.js, with its
notice): bundled as CommonJS by an app, it had put the bundler's CommonJS helpers in the chunk every
component's bundle shares (Button 17,991 against 17,650). An automatic figure's placements are memoised,
so the viewer's figure no longer re-measures without end. The else rule's dashes are an SVG mask, not a
gradient. compose.mjs places an automatic diagram in a worker it waits for (node:worker_threads), not a
child process. Tests follow what the decision changed: the dashed-flow check is gone, the motion test's
"no mark" reads a mark's rule, and compose's imports name the worker. The diagram module's cap is
123,300 (measured 123,248).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…s in the theme shown

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…shed line may flow

diagrams.test.mjs: on touch a tap traces, the same tap clears, Clear highlight enables, and nothing is a
live region (1.5 brings the touch trace back). diagram-motion.test.mjs: flow on a dashed line is no
longer an error; its own dashes march. The diagram-export module's cap is 7,850 (measured 7,832).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
bmjcoding and others added 22 commits November 23, 2026 19:23
…B6, P4, P7; Neon B1, B2, B3, B6, P5, P6)

The viewer: a control at a limit, or with the list open, is disabled as Basalt's are (disabled with focusableWhenDisabled: it stays
mounted and focusable, loses its ink, and takes no hover, press or scale), and "Clear highlight" with no trace is the same
(data-disabled). The dialog keeps the form dialog's rim (no border reset), and its inline and block end insets are reset so right
to left it is placed by its top and left and stays inside the window. A linked card that stays in this tab closes the viewer as its
click (or Enter, or tap) is handled, and the browser follows it; a new tab's link leaves the viewer open, in React and the skill.
A text sequence in the viewer holds the art at its own width, never the transcript: the figure reports the width its widest line
needs (textWidth) and the layer takes it; React reads the figure's size once the art is written, and the skill writes the art
before the viewer reads it. The viewer's figure takes the placements the page loaded and, on a phone, loads its own. Its key hint
is read from a placed model (it said two arrows for a figure with rows and columns). Fit for the direction choice is the viewer's
own (whole per cents, 200% at most), so a tie keeps the type's direction. One placement is in flight a figure at a time.

The text sequence: its build by ink is the motion module's, as a drawn figure's entrance: it waits until the art is in view, plays on
the entrance's clock, settles as any entrance settles, and keeps the first visit's mark. "Play the run" shows on a text figure with
run: true, and the run is the colour-only run with the quiet: each message in turn is current (its number primary), every later
one quiet (label secondary, arrow tertiary). textArt widens a frame too narrow for its header or else row, pushing the columns after
it (an inner frame on the same last column passes its width to the outer), and holds the neighbour of a last participant's
self-call far enough off for its words and note. The transcript and the key's focal glyph are in the engine's commit.
Rule 5's warning gathers its reasons only in a development build.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…p (Fable B5, B6, B7, P2, P3; Neon B4, B5, B7 to B10, P1, P3, P4, P7, P8, P9; 66-1 to 66-3)

Right to left, drawn: a frame's tab, its else row and its rule are placed from the frame's end edge in the grid's own coordinates, so
the tab is in the frame's top start corner (the right) and the rule spans the frame; a self-call's words sit beside its loop by the
loop's physical side; a self-call's room is measured to its neighbour by column; a Mono detail is one left-to-right run, so its
words keep their order; stacked, a group's label is on its start side (66-3). The stacked drawing itself is still not mirrored: a
named gap (foundations 6.9 says so).

Stacked: the else rule runs edge to edge of its frame (P2); a row that follows a frame draws no divider (P3); a group whose first
card is entered by a turn has space-12 above, its label in the first space-8 (the decider's answer 1, B7); a node held taller than
its words (the 44px touch floor) centres them (66-1); a route's arrow and the name it points at are one unbreakable item, and its
lines keep the 16px pitch (66-2). The transcript is Draft B's reference (B6): number, sender, arrow and receiver; then the label and
the note on lines of their own, every line hanging under the sender inside its frame's indent. The text art's key draws the focal
participant as the art does, a double box (P4).

The sequence: a text box grown space-1 that would lie on a frame's side fails the fit rule (Neon B7); its lifelines are a layer
under its frames, and its bars, lines and plates over them (P8); a quiet run's head goes with its line in forced colours, and its
label does not transition under reduced motion.

Automatic layout and the schema: a placement with two cards in one cell, a card left out or a card inside a group's box it is not
in is not used (the figure tries its other direction, then stacks, and a development build names the cards); the skill writes an
automatic figure's words on its placement, so before script its cards are in their cells; the figure's grid attributes are synced
with the model (data-cols and its kin), and an automatic figure with no placement is stacked before script (B8). A one-column
schema's turn-backs to one key share a lane only when they state the same thing (B9). A card grows to 48, not 49 (P1). Right to
left keeps a way-only column (P3). A dropped tight far line gives up its corridor (P8). The skill's says-check reads a data flow
step's lane label (B10).

Development checks: a whitespace href is empty; more than 100 cards warns; an automatic figure with no cells has no spatial keys to
check; the skill warns on "first-visit" with no id and gives rule 5's warning, as React does (P4). The 5.1 list's "throws" stays a
warning, as batch A's checks are: changing it is a decision, reported. A ground tap with no trace up does nothing (P7). The skill's
downloads do not print, and "Clear highlight" stays last in its foot (P7).

Export: every drawing SVG is sized and placed, a stretched one keeps its strokes (vector-effect), an entrance's reveal masks are
left out; the drawing's lines are written under the cards; the structural rules drawn by pseudo-elements (a lane's, a band's, a
frame's else) are lines in the file, and a linked card's arrow is not; a running entrance's or a run's colours are read at their
end and every state (trace, quiet run, arrival) is taken off for the read and put back at once, before the faces are fetched; a
figure inside a zoomed layer is read at 100% with its head and key (the skill's viewer, 9.11); a face that is not there is not
embedded; a panel's lit top edge is its own line (B5, P8). Types: DiagramCardinality and DiagramCardinalityPair are exported (P9).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ll's usage texts (Neon P9)

Foundations: a lane is shared by runs never beside each other, and a bar's ink is the pixel that ends at its distance (1.1); a
stacked group entered by a turn has space-12 above, its label in the first space-8 (1.3); the viewer is the form dialog's box on a
native modal <dialog> in its own chunk, drawing and behaving as Dialog does, the rim included, and "Expand" is words only (9.1, 9.2,
and the Phosphor glyph struck from Icons); the least drawn width is the first width the engine draws the figure at, found once for
its data, a text sequence holds its art, and a same-tab link closes the viewer first (9.3, 9.7); right to left, drawn the figure
mirrors and stacked not yet, a named gap (6.9); a linked card's arrow is not drawn in a file (1.7). The ruling's sentence on ways,
a decision's points and turn-backs went in with section 6. The decision's own 1.8 and 5.1 edits are the decider's document's.

The skill's usage texts say what batch B added: flow on any edge, a mark on a step or a participant, a group's parent, href, a
label's break, bars and frames, the text variant, automatic layout and the first visit. Their caps are their measured sizes and a
little more (diagram 4,554 → 4,600; diagram-motion 1,428 → 1,450).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…he viewer shots' focus ring said (Fable P1, P5, P6)

The summary says batch B is whole and fixed after both reviews and the sweep (P1). Two steps for the parts nobody had seen drawn (P5):
the data flow with a mark on a step (S3's, on the sealed segment in the S3 lane), its batch line as a dashed flow, and two more lines
so two cards are each entered by two end lines when stacked; and section 4's calls 2 and 3 (a one-column schema's two turn-back
lanes, and a card grown to 48 for a straight line and two others). The viewer step says its shots open the viewer by script, so the
stage shows its keyboard ring, which a click or a tap does not (P6).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…it answers; elkjs's class is described without its name

Found by a node-only check of Neon's P2: with the chain fixed, elk itself threw on a hierarchy that held itself. The skill's built
viewer part follows its source (the placed model for the key hint).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Recorded sizes: each still diagram 99,589 to 99,677 bytes, +1.7% on batch B's last record (the reviews' fixes in the shared engine,
the figure and the stylesheet); the whole package up front 902,562 bytes (+0.2%); styles.css 413,315 (+0.9%). The skill's caps at
their measured sizes, the reason in modules.json's $comment: diagram 137,700 to 144,100 (measured 144,056), diagram-motion 28,450 to
30,450 (30,418), diagram-zoom 17,000 to 17,600 (17,575), diagram-export 7,850 to 10,450 (10,402); diagram-text stays (5,177 of 5,450).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ng coverage (Fable's section 8 additions; Neon B12)

Written; the browser tests are not run (the owner paused them, DECISIONS 330). Node-only: the contrast pairs pass (200 of 200).
- diagram-review.test.mjs (new): the viewer's disabled controls and "Clear highlight" (no hover, press or scale, another ink), a
  linked card closing the viewer by a click and Enter, a text sequence's art in the viewer at 1440 by 900 and 390 by 844, the rim and
  the dialog inside the window right to left (Fable B1 to B4); right to left frames, else rules, a self-call's words and a Mono detail
  (B5); stacked else rule, no divider after a frame, the group entered by a turn (P2, P3, answer 1); 66-1 to 66-3; the transcript's
  lines and the key's focal glyph (B6, P4); textArt's widened frame and a last participant's self-call; the text build in view and its
  run; export of a flowchart, mid-entrance and mid-run (Neon B5); an unusable placement, a one-column schema's two statements, empty
  and cyclic placements, a way-only column right to left, 48 not 49; the frame-side fit and the sequence's layers; forced colours on a
  quiet run's head; the lazy parts reached only dynamically; the quiet run; the first visit; the five figures right to left.
- Tautological tests replaced, each now failing when its feature breaks: the stranded card (an X of five strands one, and the arrows
  keep the author's order), the viewer's bare stack (a figure that is never drawn and whose stack is bare opens the list), and print's
  traced line (read whatever kind the first lit line is).
- diagram-sequence: the text variant (stable art, closed frames, no scroll at 1440, 390 and 360, aria-hidden, glyph swatches), bars
  and frame errors. diagram-parts: three and four end lanes, the fifth, two entries into one card, marks read the lane label.
  diagram-fixes: call 1 at every whole width from 930 to 1,440, call 2's lanes and padding, call 3 at every fourth width to 1,440.
  diagram-layout: no declaration names elkjs or the graph's helpers, and elkjs's licence ships. contrast: batch B's seats on levels 0
  to 3 and under more contrast, the text art's inks on surface-sunken, a linked card's words on its press step. The skill: an automatic
  figure's static markup on its placement, and the lane label in the says-check.

Their node-level logic was checked by a script outside the suite (the cells against the ruling's, the text art, the placements, the
development checks, the declarations, the import graph, compose): it passes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Animated, its lines waited for the figure to come into view, and the shot caught them pending. The step says the batch line's dashes
march where motion is asked for.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…not banded

The art's character width was read with getBoundingClientRect after the viewer had put its zoom back on the layer, so at Fit the art was laid
out for a width scaled by the zoom and cut off (both re-checks' B3/B2/R1). The probe is now one unbreakable inline-block run read with
offsetWidth, which no transform scales, in React and the skill alike: the width is the same at every zoom.

The skill's viewer banded every text row: the core's inline code rule (code:not(.code code)) gave the art's code element a chip fill and
0.92em. The art's code element is reset to the block's own text (P-R2 of the code re-check).

The implementation hasn't been reviewed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…its list open

The viewer's "bare stack" test failed as written at the re-check (Opus R2, P-R3), and the fault was the engine's. measureFigure's tries
wrote each layout they tried; the bare stack was returned without being written, so the figure kept the last try's attributes (stacked,
not bare, its list closed) and a host seeing a state equal to the one before rendered nothing. The bare state is now applied before it
is returned. The fixture was right.

The implementation hasn't been reviewed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ws as production draws it

The decider's ruling on the batch B re-check: the 5.1 checks an author must fix (a group's unknown parent, a cycle or a third level; a band
in a frame; a third frame level; an alt with one branch; a frame label over 40; an empty frame or branch; a break in a message's label;
layout auto on a type without it; an href on a participant or an empty one; cardinality that is not a form, a referenced end of many,
cardinality without references or on some keys and not all; a label with two breaks or a line over 28; a fourth bar; a deactivate with no
bar; a stack that would need a fifth end lane; entrance first-visit without an id) go to Model.errors and are reported with console.error,
once for a figure and message, in React and the skill (compose.mjs marks them "error: "). The second list stays console.warn. Motion's
errors still throw. The markup is the same with the checks on or off.

Tests: diagram-checks.test.mjs (node, run: 22 pass) proves each first-list item lands in errors and not warnings and the markup equals
production's; the sequence and schema tests read errors now (browser files, written, not run).

The implementation hasn't been reviewed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The decider's ruling on the batch B re-check: elkjs moves from dependencies to devDependencies, pinned exactly at 0.12.1, and ships only as
dist/diagram-elk.js with its licence (dist/elkjs/LICENSE.md); an app no longer installs a second copy. The owner's approval stays where
the lint sees it: dependencies.allowed.json keeps the entry, with its reason updated, and a new $copied block names the packages whose
file is copied into dist. check-deps.mjs (engineering, no pixel changes) counts a copied package as used when its devDependency is that exact
version, and fails when the two drift, so the entry is never called stale. The notice drops "also listed among the package's
dependencies". verify-packages.mjs places an automatic figure from the packed package with elkjs removed from the consumer's node_modules
(part of npm run check: written, not run).

Ran: npm run lint (the allowlist step passes), audit-fix-c8.test.mjs (check-deps, node: pass).

The implementation hasn't been reviewed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The decider's ruling on the batch B re-check: in the transcript, the arrow and the receiver are one unbreakable run (tx-to, nowrap), so a
route that does not fit breaks before its arrow and its second line starts with the arrow under the sender, as the stacked list's route
does (66-2). No deeper indent and no second ink: the receiver keeps the names' primary ink.

Tests: diagram-recheck.test.mjs (node, run) checks every route's markup ends in the one run and the run's nowrap; diagram-review.test.mjs
measures it at 390 in both themes (browser, written, not run).

The implementation hasn't been reviewed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The decider's ruling on the batch B re-check: a stacked group whose first card is entered by a turn (a trunk or end-down line) has
space-12 above that card plus space-4 for each line of the turn's label (--_tl, from the longest label: 64 for one line, 80 for two); an
unlabelled turn keeps space-12. The label's first seats are beside its turn, space-2-5 past the entry, then a line (space-4) at a time up
into that room, never above the group's edge, so nothing grows above the group for it; the line's own seats follow. --_tl is a managed
style, so a redraw clears it.

Tests: diagram-recheck.test.mjs (node, run) checks the marking, --_tl and the rule; diagram-review.test.mjs measures the label inside the
group, at least space-1 under the group's label, its lower edge within space-4 of its turn, nothing grown above, and 48 for an unlabelled
turn (browser, both themes at 390, written, not run).

The implementation hasn't been reviewed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…t again

The figure asked for a placement once per spec object and kept the first answer, so cards added or lines changed while elk ran could be
left without a cell (P-R1 of the code re-check). What placement reads (the type, the cards and their groups or the tables and their
references, the lines, the groups) is now a signature; when it changes, the answer for the old one, loaded or in flight, is dropped and
the figure is laid out again. A change of words or legend does not count.

Tests: diagram-layout.test.mjs (browser, written, not run): two figures under one key in one task draw as a fresh figure of the second's
data draws, with none of the first's cards; a change of lines alone lays out again, and the cells move. Also in that file, the layout
module fetched only when needed (an ES-module app with code splitting on a routed origin: a fixed layout and a phone's automatic figure
fetch no elk chunk, two automatic figures at 1104 fetch it once).

The implementation hasn't been reviewed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…wer; step 10's data flow drawn

The text step and the automatic layout step each gain a viewer shot (the art whole at 1440 and 390; the automatic architecture drawn in
the viewer, both themes), and the viewer's wait is for a drawn figure or the art, not a fixed time. Step 10 shows the extended data flow
drawn at 1440 (a step's mark and a dashed line, Fable's P5), still, then its parts as before.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ouch, pinch, parity for batch B

- diagram-recheck.test.mjs (node, run: 6 pass): the art's glyph probe in both engines; viewerTextWidth leaves the zoom alone; rulings 3
  and 4 in markup and CSS; elkjs one copy; compose.mjs's batch B figures equal the engine's, prefix for prefix (an automatic one on its
  placeDiagram answer). It caught the skill's stale build before the rebuild.
- diagram-review.test.mjs: the frame-side test now has a fixture that crosses (Opus's: a long note over the start side of the frame
  below), with two controls that fail it if anything but B7a's rule stacks it; the text art in the viewer stays whole and the same width
  through zoom in, Fit and zoom out; ruling 3 at 390, both themes; ruling 4's measurements.
- diagram-viewer.test.mjs: the bare-stack fixture was right (the fault was the engine's, fixed in its own commit); the status test now
  pinches with twenty CDP moves and is spoken once.
- diagram-keys.test.mjs: the trace on touch: a ground tap, a scroll from a card, a linked card, the foot's stillness and Clear last, a
  touchscreen laptop's first tap, the stacked schema and sequence with no hint or Clear.
- tools/html-skill/test/diagrams.test.mjs: React and skill parity for batch B's nine figures, both themes at 1440 and 390.

Browser files: written, not run (DECISIONS 330).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ure, the export sizes

The skill's diagram, diagram-text parts rebuilt from this round's sources. The diagram module's cap rises 144100 to 145100 (measured
145072), with the reason in modules.json's $comment (budgets are soft). export-sizes.json re-recorded: each diagram component +1.3%
(about 1.26 KB: the first list's errors and the turn's label seats), the whole package +0.1%.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…d and as the skill does

1.5 mounts "Clear highlight" on touch for a figure that can be traced. React mounted it for a text sequence too: its ink is the art or the
transcript, which no tap traces, so the button stayed disabled. It is now mounted only for a figure that is not text, as the skill already
does (it mounts the button only where the figure has an ink layer with lines). A bug fix restoring documented behaviour: the one pixel
change is the dead button gone from the text figure's foot on touch.

Tests: diagram-recheck.test.mjs (node, run: 7 pass) checks the condition in both engines and that a text figure has no ink layer;
diagram-keys.test.mjs taps the text figure at 1440 (art) and 390 (transcript) on touch and finds no Clear highlight (browser, written,
not run). export-sizes.json re-recorded (+11 to +13 bytes a diagram component).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…port height; round 66's text viewer at 390 by 844

build.mjs takes --only <step ids>, shooting those steps alone into --out and keeping each step's number, so a re-shot picture has its
round's name. A step may set heights, keyed "state@width", to give one state at one width its own viewport height. Round 66's text
viewer is shot at 390 by 844, a phone's own screen, not 2,000.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…to diagram batch B

Both sides kept:
- AGENTS.md and foundations: the structural vertical lines list both rounds' items (a sequence diagram's lifeline with its activation bar,
  a frame's sides, and a stage list's or run timeline's connector with #127's full rule).
- packages/react/build.mjs: the separate-entry and lazy lists hold batch B's (diagram-viewer, diagram-zoom-core, diagram-layout,
  diagram-text, diagram-elk, with the elkjs copy) and #128's (release-sources, rail-tooltip).
- contrast.test.mjs: batch B's print and diagram pairs and #128's release-page pairs.
- rounds.tsx: rounds 66, 67 and 68.
- modules.json: both sides' caps and $comment notes. skillMd stays 12800, not batch B's 12950: SKILL.md was tightened in its wording
  (no rule dropped, every phrase a test pins kept) from 13105 to 12799 bytes; core takes main's 35550.
- #127's pause glyph (328) on the diagram's "Pause animations": React through LoopsToggleButton's icon, the skill's diagram-motion source
  merged with it.

Generated files regenerated, not hand-merged: the skill's parts and manifest (npm run build), export-sizes.json (npm run sizes).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…nks rule) into diagram batch B

diagram-figure.tsx keeps both: batch B's touch trace and viewer keys, and #129's fix that keys the figure's options on whether there is a
source, not the node (a new node each render measured the figure again). The same fix's intent is applied to the viewer's keys: the options
key on the string, not the viewer object. #129's sink: comment on the ink is kept.

What #129's rules flagged in batch B, and the fix:
- oxlint unicorn/no-new-array: diagram-text.js's glyph probe built its run with new Array(41).join; it is '─'.repeat(40).
- oxlint react/no-danger and the sink check: the viewer's list and key (diagram-viewer.tsx) are dangerouslySetInnerHTML with no reason.
  Each now has its sink: comment (the engine's figureList and figureKey through toHtml, which escapes every text and attribute) and the
  oxlint exception beside it, as brand-svg.tsx does; diagram-recheck.test.mjs (node, run) passes hostile words through the list, the key,
  the transcript and the text art and finds them only as text.
- The sink check in the skill: diagram-export.js's button words are set with textContent, so it has no sink; diagram-text.js (1) and
  diagram-zoom.js (2) are in sinks.allowed.json with what they take and why it is safe; diagram.js's count is 4 (batch B's key hint,
  its keys and words through escapeHtml). A text sequence with export on joins the hostile-input page (support-hostile.mjs), so
  diagram-text, diagram-export and diagram-zoom are in the probe.

modules.json keeps both sides' caps and notes: diagram 145450 (batch B's 145100 plus #129's mark check; measured 145427), usage 4600.
SKILL.md fits main's 13050 with one index line tightened. Generated files regenerated: the skill's parts and manifest (npm run build),
export-sizes.json (npm run sizes).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@bmjcoding
bmjcoding marked this pull request as ready for review November 24, 2026 10:14
@bmjcoding
bmjcoding merged commit 86d7c9b into main Nov 24, 2026
1 of 2 checks passed
@bmjcoding
bmjcoding deleted the claude/diagrams-b branch November 24, 2026 10:14
bmjcoding added a commit that referenced this pull request Nov 24, 2026
…rated

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
bmjcoding added a commit that referenced this pull request Nov 24, 2026
Both sides kept. Round 69 and round 70 are both registered. The skill's
notifications keep main's checked href and placement and take data-edge.
SKILL.md takes main's wording and the edge line, trimmed to 13,040 (main's
cap 13,050, no rule dropped); AGENTS.md takes main's diagram card and the
toast and selection column lines. Generated files are rebuilt, the export
table re-measured, and the bundle test's limits and the skill's caps set to
the measured sizes from main's, with the reasons.

Lint's new steps: oxlint and the sink check flagged round 69's skill frame
(a sink comment and the reasoned oxlint exception, as round 47's) and two
new sinks in the skill (copy.js now writes the button once with its glyph
swapped; terminal.js draws its three glyphs once and shows one), so the
ledger is unchanged. The edge rule now reaches #130's diagram viewer: its
Close hangs at the head's end and Zoom out at the foot's start, the foot
declaring its room (the skill's copy maps the insets). #131's timeline has
no ghost control at an edge (its toggle is a TextButton).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
bmjcoding added a commit that referenced this pull request Nov 24, 2026
…diagram-interop

Resolve conflicts in build.mjs, package.json, verify-packages.mjs and SKILL.md (rewording steps 1-3 to keep SKILL.md within its 13050 B budget while keeping the export rule and all main rules; raising diagram usage cap 4600 -> 4850 in modules.json for the merged export line). Fix oxlint no-new-array and narrow MStep on sequence frames in scene.ts so the merge commit builds cleanly.

Co-Authored-By: Gemini 4 Neon <noreply@google.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant