feat(library): add waypoint editing to straight edges - #834
Merged
Conversation
8 tasks
Claudia-Anthropica
requested changes
Jul 28, 2026
Claudia-Anthropica
left a comment
Collaborator
There was a problem hiding this comment.
@FelixTJDietrich The waypoint workflow and migration coverage look solid overall. One pointer-event edge case can still make a valid new-waypoint drag disappear on release; see the inline comment.
Claudia-Anthropica
approved these changes
Jul 28, 2026
Claudia-Anthropica
left a comment
Collaborator
There was a problem hiding this comment.
@FelixTJDietrich The quick-drag handoff now preserves the threshold-crossing move, and the focused regression covers the original failure mode. Looks good.
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Straight connections in use-case, syntax-tree, and Petri-net diagrams currently offer no way to correct a route without moving its nodes. This PR gives those edges a direct, discoverable waypoint-editing workflow:
The handles intentionally share the opaque blue visual state of step-edge bend handles. They remain circular because a straight-edge waypoint moves in two dimensions, while a step-edge capsule represents a segment constrained to one axis.
This PR is deliberately limited to manual editing. Automatic routing and syntax-tree layout are separated into the follow-up PR #835 so each change can be reviewed and released independently.
Release note
Shape diagonal connections by hand just like orthogonal ones. Use-case, syntax-tree,
and petri-net connections now have filled circular waypoints: drag the handle on a
segment to add one, drag an existing point to reshape the route, and double-click,
press Delete, or drag it magnetically back onto the line to remove it. Shift-drag locks
to familiar 15-degree angles, endpoint reconnection preserves the custom route, and a
single reset clears all hand-authored routing.
Implementation notes
maincontains only the new optionalmoveEdgeWaypointlabel; complete translation dictionaries written for earlier releases still compile and receive the English fallback internally.Steps for testing
data.points; confirm it remains visually straight, while an orthogonal edge retains its existing manual bends.pnpm lint && pnpm format:check && pnpm build && pnpm test.pnpm exec playwright test tests/e2e/straight-edge-waypoint-ux.spec.ts --project chromium --project firefoxfromstandalone/webapp.pnpm --filter @tumaet/apollon run size; the main entry should remain below 121 kB brotli.Local verification on this branch after rebasing onto current
main: 88 unit-test files passed (1,781 tests; 1 skipped), and the main published entry is 119.71 kB brotli against its 121 kB budget. The focused production interaction and legacy-import suite passed all 7 tests in both Chromium and Firefox (14 browser runs total), including real pointer drags where waypoint and endpoint targets are close together and a one-move quick-drag regression.Screenshots / screencasts
Captured from this branch's production build after adding a waypoint. The focused Playwright suite covers what the still cannot show: drag, magnetic collapse, overlapping-target ownership, hover, keyboard removal, and a computed-style comparison against step-edge handles.
Checklist
pnpm changeset, how)feat) matches the user-visible feature and release-note grouppnpm lint && pnpm format:check && pnpm build && pnpm testlocally — green