Skip to content

fix(erd): PNG capture state, Fit with notes, note outline in exports - #1299

Merged
ZhuchkaTriplesix merged 2 commits into
devfrom
fix/erd-ui-review-1
Oct 10, 2026
Merged

ZhuchkaTriplesix merged 2 commits into
devfrom
fix/erd-ui-review-1

Conversation

@ZhuchkaTriplesix

Copy link
Copy Markdown
Member

Fixes from the ER diagram interface review.

  1. PNG in the current theme is a screenshot of the canvas. It cleared the picked table, hover and edge label, but not a picked relation (highlighted edge, faded cards) or the tables marked for a group (thick borders). Both are cleared for the capture and come back after it, unless the user changed them meanwhile.
  2. Fit used the cards' bounds only, so a note away from the cards stayed off screen after Fit, on first open and when the minimum zoom was computed. Fit, the zoom floor and the PNG pixel-ratio cap now use the canvas size with notes.
  3. Note outline in SVG / PDF: a note without a colour had a fixed #cbd5e1 outline. It now uses the export palette's border (the current theme's border when exports use the current theme).

Tests: test/features/erd/erd_ui_review_fixes_test.dart — a note at (2600, 1800) is inside the viewport after the first fit; the saved PNG is written while no focus column or Group button is on screen, and both are back afterwards; the neutral outline is #cbd5e1 in the light palette and the theme's border otherwise.

Not in this PR: grouping scattered tables (the frame covers unrelated cards) — a behaviour decision, asked separately.

…note outline

- The current-theme PNG is a screenshot: a picked relation and the tables
  marked for a group are cleared for the capture and restored after it.
- Fit, the first fit and the PNG size cap use the canvas with its notes,
  so a note placed away from the cards is in view.
- A note without a colour takes its outline from the export palette
  (the current theme's border), not a fixed light grey.
@ZhuchkaTriplesix
ZhuchkaTriplesix merged commit ecb4233 into dev Oct 10, 2026
15 checks passed
@ZhuchkaTriplesix
ZhuchkaTriplesix deleted the fix/erd-ui-review-1 branch October 11, 2026 15:02
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