Skip to content

feat: polish the package: phone layout, smaller files, card-fit and validator fixes - #32

Merged
hyamero merged 7 commits into
mainfrom
fix/package-polish
Sep 30, 2026
Merged

hyamero merged 7 commits into
mainfrom
fix/package-polish

Conversation

@hyamero

@hyamero hyamero commented Sep 30, 2026

Copy link
Copy Markdown
Member

Stress-tested the package on 28 diagrams (every gallery sample plus edge cases: single node, self-loops, parallel edges, 8-level nesting, unicode/RTL/emoji, markup in every text field, up to 500 nodes and 250 messages) in Chromium, WebKit and Firefox, in light, dark and at phone width. No console errors, text overflow or page scroll anywhere; 500 nodes render in ~200 ms with no long tasks during flow or zoom. Fixes for what the run turned up:

  • Phones: the inspector took a 300px column and left the canvas 58px wide. Below 672px it now opens as a sheet over the stage, its collapsed toggle sits in the stage corner, and Export shows its icon only so the toolbar fits on one row from ~390px up (at 360px it wraps to two rows).
  • Toolbar clipping: between 460–840px, and at 1100px with the inspector open, the identity card pushed Export off the stage. The top panel is now capped to the stage width; the identity card truncates, then hides below a 640px stage.
  • Identity card: its ⋯ button had no handler. It now opens the inspector on the diagram overview.
  • Card-fit measure: zero-width joiners, variation selectors and combining marks counted as 1.1em glyphs, so emoji like 👩‍👩‍👧‍👦 or ❤️ were measured ~3× too wide and valid text failed validation. The browser ground-truth e2e now covers them.
  • File size: every delivered file carried all 146 brand marks (~170 KB). The built template now holds them as a JSON block that deliver trims to the brands the diagram uses: ~669 KB → ~495 KB (−26%). Dev server, tests and site keep importing brands.gen directly.
  • Oversized diagrams: when content doesn't fit even at the 20% zoom floor, the fit starts at the top-left instead of mid-diagram.
  • deliver -o: creates missing parent folders instead of failing with ENOENT.
  • New validator warnings:
    • semantics/parallel-edge: architecture and dataflow give each card one in and one out port, so two edges running the same way between the same nodes draw as one line with stacked labels. Swimlanes and sequences are exempt.
    • semantics/large-diagram: over 60 nodes. The authoring contract now mentions both.

Not changed: grouped layouts of a few hundred nodes are slow in ELK (300 nodes in 20 groups ≈ 66 s; ≤100 nodes stays under 1.5 s). The wrap pass is needed for grouped graphs too, so the size warning is the mitigation.

Desktop positions at 1440px are unchanged, so the Linux visual baselines should hold; they couldn't be regenerated locally (no Docker), so CI's run is the check.

Tests: all unit suites (viewer 132), typecheck, viewer e2e, CLI e2e and smoke, and site unit/e2e all pass.

@vercel

vercel Bot commented Sep 30, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
stackmap-site Ready Ready Preview Sep 30, 2026 4:58pm UTC

@hyamero hyamero changed the title Package polish: phone layout, smaller files, card-fit and validator fixes feat: polish the package: phone layout, smaller files, card-fit and validator fixes Sep 30, 2026
@hyamero hyamero closed this Sep 30, 2026
@hyamero hyamero reopened this Sep 30, 2026
@hyamero
hyamero merged commit 4ea74d9 into main Sep 30, 2026
15 of 17 checks passed
@hyamero
hyamero deleted the fix/package-polish branch September 30, 2026 17:50
@github-actions

github-actions Bot commented Oct 2, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 0.1.0-rc.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

@github-actions

github-actions Bot commented Oct 2, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 0.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

This branch was successfully deployed

1 active deployment
Preview — e55e47b6 Deployed Sep 30, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant