Repository navigation
fix(web): the chat keeps the reader in place after a selection drag - #212
Merged
Merged
Conversation
The browser autoscrolls the timeline while the reader drags a selection at its top edge. The viewport sends no navigation for that scroll, so the chat keeps following the end. A clamp during a press, or after the press ends, must still send none. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A reader who drags a text selection to the top of the chat makes the browser scroll it up, but follow stayed on. Narrowing the window or a new message then scrolled the chat to the end. An upward scroll now counts as the reader moving away while the primary press has moved into the browser's autoscroll band at the top edge and holds a text selection in the chat. A press held still during a content clamp still counts as nothing. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
This PR changes the test suite by +1 test cases (browser +1, unit 0, server 0). New browser test files: Keep tests that would fail for a real reason, and test logic below the UI where it can be. See Testing. |
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.
This pull request makes a text selection dragged to the top of the chat count as the reader scrolling away, so the chat no longer jumps to the newest message when the window gets narrower.
改了什么行为
Behaviour change: yes, a reader who drags a text selection to the top of the chat, so the browser scrolls it up, now stays on that text when the window narrows or a new message arrives, and the "Scroll to end" button shows. Before, the chat jumped back to the newest message. This holds in Chat mode and Normal mode, on web and desktop.
A reader at the end still stays at the end. Wheel, keys, touch and the scrollbar behave as before.
Why
While the chat follows the newest message, the list keeps the end in view on every layout change. A selection drag scrolls the chat with no wheel, key or touch event, so follow stayed on. Now an upward scroll counts while the primary press has moved into the browser's autoscroll band at the chat's top edge and holds a text selection there. A press held still while content briefly shrinks counts as nothing.
Checks
How to undo
Revert both commits. No stored data changes.