Skip to content

feat: align select and pen gestures with standard outline editing - #466

Merged
kostyafarber merged 6 commits into
mainfrom
fix/select-drag-hover-marquee
Sep 29, 2026
Merged

kostyafarber merged 6 commits into
mainfrom
fix/select-drag-hover-marquee

Conversation

@kostyafarber

@kostyafarber kostyafarber commented Sep 29, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • Select: dragging any unselected object inside the selection's bounding box now moves the whole selection instead of selecting the object under the pointer. Alt-drag keeps its own point-slide and duplicate behavior.
  • Select: Shift-hover shows the add cursor over unselected points, anchors, segments, and components, matching what Shift-click adds.
  • Select: the marquee selects a segment it touches unless exactly one of its end points is inside, so boxing a single point still selects only that point. Adds Curve.intersectsRect to @shift/geo.
  • Pen: dragging from the active endpoint, or from an open end when no stroke is active, pulls the next segment's first handle. From a line the handle is free and the point stays a corner; Option keeps it on the line's direction and makes the point smooth. From a curve the incoming handle mirrors it. The pending handle stays drawn and shapes the next dragged curve; a click still draws a line.
  • Pen: Escape during a closing drag now cancels the closing curve instead of leaving the contour closed with its preview handles.

Issue

Closes #465
Refs #369

Testing

  • pnpm check passed.
  • pnpm typecheck and pnpm lint:check passed.
  • npx vitest run in apps/desktop: 1166 tests passed, including new regression tests in SelectMove.test.ts, Select.test.ts, and Pen.test.ts.
  • npx vitest run in packages/geo: passed, including new Curve.intersectsRect tests.
  • Manual: gestures checked in the running app during development.
  • Desktop E2E runs on this pull request, not locally. The first run failed three canvas goldens in glyph-rendering.spec.ts (pen-cubic-curve, pen-s-curve-handles, pen-smooth-junction-drag-preview). Each diff is only the newly drawn pending handle: from the last point between gestures, and from the start of the curve being dragged. The baselines were replaced with the CI-rendered images after inspecting every diff.
  • No screenshots attached: the changes are gesture behavior and a transient handle overlay.

🤖 Generated with Claude Code

A segment is selected when the marquee touches its curve, except when
exactly one of its end points is inside: boxing a point keeps selecting
that point alone rather than the segments leaving it.
Dragging from an open end pulls the next segment's first handle. From a
line the handle is free and the point stays a corner; Option keeps it on
the line's direction and makes the point smooth. From a curve the
incoming handle mirrors it. The pulled handle stays drawn and shapes the
next dragged curve; a click still draws a line and drops it.
@kostyafarber kostyafarber added the release: nightly Run a Nightly build after this pull request merges label Sep 29, 2026
@kostyafarber
kostyafarber added this pull request to the merge queue Sep 29, 2026
Merged via the queue into main with commit d9f2a8c Sep 29, 2026
29 of 30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release: nightly Run a Nightly build after this pull request merges

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Align select and pen gestures with standard outline editing

1 participant