Skip to content

feat(v6.51.1): canvases zoom out to 5% (ADR-253) - #306

Merged
cgbarlow merged 1 commit into
mainfrom
feature/canvas-zoom-out
Sep 24, 2026
Merged

cgbarlow merged 1 commit into
mainfrom
feature/canvas-zoom-out

Conversation

@cgbarlow

Copy link
Copy Markdown
Owner

Summary

The canvases didn't set a zoom limit, so they all used Svelte Flow's default minZoom of 0.5. That limit also caps fitView, so large diagrams such as the 274-node Barlow family tree opened at 50% with most of the diagram off screen, and the zoom-out control stopped there.

  • New shared constant CANVAS_MIN_ZOOM = 0.05 in frontend/src/lib/canvas/zoom.ts
  • Passed as minZoom to every <SvelteFlow>: UnifiedCanvas (browse and edit), FullViewCanvas, ModelCanvas, BrowseCanvas
  • Fit-to-view (on load, the Controls button, the keyboard shortcut) inherits the new limit, so no fitView call sites change
  • maxZoom is unchanged; the sequence canvas has its own viewport and isn't affected
  • ADR-253, SPEC-253-A, CHANGELOG entry, version bump to 6.51.1

Frontend-only; no API, MCP or CLI change, so surface parity is unaffected.

Test plan

  • frontend/tests/unit/canvasZoomRange.test.ts: red before the change (4 of 5 failed), green after
  • Full vitest suite: only the 7 failures that also fail on main
  • svelte-check: no new errors (two in UnifiedCanvas.svelte were already on main, on lines this change doesn't touch)
  • Playwright on local dev: zoom-out goes from the fitted 0.78 down to 0.05 before the control disables (it stopped at 0.5 before)
  • On UAT, open the Barlow line diagram and check that fit-to-view shows the whole tree

🤖 Generated with Claude Code

https://claude.ai/code/session_01EbTwcTX1wKVooS7oWd7cP9

Svelte Flow's default minZoom of 0.5 also capped fitView, so large
diagrams (the 274-node family tree) opened at 50% with most of the
diagram off screen. A shared CANVAS_MIN_ZOOM = 0.05 is now passed to
every <SvelteFlow>.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01EbTwcTX1wKVooS7oWd7cP9
@cgbarlow
cgbarlow merged commit dccac87 into main Sep 24, 2026
1 check passed
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