Fix scroll to bottom button flickering near bottom of the chat#1692
Fix scroll to bottom button flickering near bottom of the chat#1692juliusmarminge merged 2 commits intopingdotgg:mainfrom
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
ApprovabilityVerdict: Approved This is a straightforward UI bug fix that adds an additional You can customize Macroscope's approvability policy. Learn more. |
What Changed
Adjusted the chat scroll behavior so the "Scroll to bottom" pill does not appear immediately when the user starts slowly scrolling upward from the very bottom of a thread.
The change keeps auto-scroll enabled while the scroll container is still within the near-bottom threshold during upward wheel or pointer scrolling.
Why
When scrolling up slowly from the bottom of an existing chat, the "Scroll to bottom" pill could appear too early and flicker on and off before the user had actually moved far enough away from the bottom for the control to be useful.
This change keeps the existing behavior intact, but avoids releasing auto-scroll until the user is no longer near the bottom, which makes the pill appear at a more sensible point and prevents the near-bottom flicker.
UI Changes
Before:
Screen.Recording.2026-04-02.at.19.52.57.mov
The "Scroll to bottom" pill could appear immediately and flicker while slowly scrolling upward near the bottom of a chat.
After:
Screen.Recording.2026-04-02.at.20.24.12.mov
The pill stays hidden while the user is still near the bottom and appears only after scrolling far enough upward.
Checklist
Note
Low Risk
Low risk UI behavior tweak limited to chat auto-scroll state; may slightly change when auto-scroll disengages during upward scrolling near the bottom.
Overview
Adjusts
ChatViewauto-scroll disable logic so upward wheel/pointer scrolling only turns off auto-scroll once the user is not within the near-bottom threshold.This prevents the “Scroll to bottom” pill from appearing/flickering when a user slowly scrolls up while still effectively at the bottom of the thread.
Written by Cursor Bugbot for commit 68aaf07. This will update automatically on new commits. Configure here.
Note
Fix scroll-to-bottom button flickering near the bottom of chat
The auto-scroll disable condition in ChatView.tsx previously triggered on any upward scroll. It now requires the user to both scroll up and be away from the bottom (
scrolledUp && !isNearBottom). This fix applies to both thependingUserScrollUpIntentRefandisPointerScrollActiveRefbranches.Macroscope summarized 68aaf07.