fix(app): preserve timeline selection autoscroll#35383
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Fixes timeline auto-follow/selection interactions by marking pointer drag selection as a scroll gesture and extending the timeline stability E2E suite to cover upward drag-selection autoscroll behavior.
Changes:
- Mark scroll gestures on pointer down and during primary-button pointer moves within the timeline viewport.
- Add an E2E test that validates upward drag-selection continues moving the scroller (and that selection actually grows).
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| packages/app/src/pages/session/timeline/message-timeline.tsx | Marks scroll gestures for pointer drag interactions to prevent unwanted bottom-follow behavior during native selection autoscroll. |
| packages/app/e2e/performance/timeline-stability/scroll-interaction.spec.ts | Adds a new drag-selection stability test covering upward autoscroll and selection growth. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
599
to
607
| const handleListPointerDown = (event: PointerEvent & { currentTarget: HTMLDivElement }) => { | ||
| if (!prependLoading) clearPrependAnchor() | ||
| if (event.target !== event.currentTarget) return | ||
| props.onMarkScrollGesture(event.currentTarget) | ||
| props.onMarkScrollGesture(event.target) | ||
| } | ||
|
|
||
| const handleListPointerMove = (event: PointerEvent) => { | ||
| if (event.buttons !== 1) return | ||
| props.onMarkScrollGesture(event.target) | ||
| } |
Comment on lines
+76
to
+80
| await page.mouse.move(textBox.x + 20, scrollBox.y - 120, { steps: 30 }) | ||
| await page.waitForTimeout(1_500) | ||
| await page.mouse.up() | ||
|
|
||
| expect(Number(await scroller.getAttribute("data-selection-length"))).toBeGreaterThan(0) |
Wiktor102
pushed a commit
to Wiktor102/opencode
that referenced
this pull request
Jul 5, 2026
drewr
pushed a commit
to drewr/opencode
that referenced
this pull request
Jul 7, 2026
shaheislam
pushed a commit
to shaheislam/opencode-vim
that referenced
this pull request
Jul 7, 2026
anduimagui
pushed a commit
to anduimagui/opencode
that referenced
this pull request
Jul 9, 2026
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
Testing