Skip to content
Source
Sign inSign up
pingdotgg/t3code

feat(mobile): add scroll-to-end button #5915

ClosedKapish14(GitHub profile, opens in a new tab)wants to merge 2 commits intomain fromrefs/pull/5915/headopened View on GitHub

Closes #5434.

Mobile threads do not provide a quick way to return to the latest activity after scrolling through a long conversation.

This adds a floating scroll-to-end button to the shared mobile thread view. It uses the feed's existing end-follow state, calls the existing keyboard-aware scroll path, and disappears once the latest activity is visible again. Touch-down activation keeps the control responsive while the feed is moving under scroll momentum.

Testing

  • Tested using a standalone preview APK on Android
  • Verified that the button appears after scrolling away from the end
  • Verified that tapping it during scroll momentum returns to the latest activity
  • Verified that it disappears after reaching the end
  • Targeted mobile lint and TypeScript checks pass
  • iPhone and iPad behavior has not been tested on-device

Video

https://github.com/user-attachments/assets/e2754cfc-f0b4-4b73-a01e-c56151543c7f

Note

Add scroll-to-end button to mobile thread detail screen

  • Adds a floating ControlPill button above the composer in ThreadDetailScreen.tsx that appears when the feed is not following the end of the message list.
  • Pressing the pill triggers haptic feedback and scrolls to the end of the thread via scrollMessageToEnd.
  • ThreadFeed.tsx gains an onEndFollowEnabledChange callback prop to notify the parent when end-follow state changes.
  • ControlPill.tsx gains activateOnPressIn and className props; activateOnPressIn fires onPress on press-in and suppresses the subsequent release event to avoid double-invocation.
Macroscope summarized 205c7fd.

Note

Low Risk Localized mobile UI and scroll behavior reusing existing keyboard-aware scroll APIs; no auth, data, or API changes.

Overview Adds a floating scroll-to-end control on mobile when the user has scrolled away from the latest messages. Visibility tracks the feed’s existing end-follow latch: ThreadFeed notifies the parent via onEndFollowEnabledChange, and ThreadDetailScreen shows the button when follow is off and content is ready.

Tapping runs the existing scrollMessageToEnd path (with haptics) so the list returns to the live edge and follow re-arms when the viewport is back at the end. Thread switches reset follow to enabled.

ControlPill gains optional activateOnPressIn (fires on touch-down and skips duplicate onPress on release) and className for styling the card-like down-arrow pill above the composer.

User docs in docs/user/threads.md describe the control briefly.

Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 205c7fdf6f3bdfd652d3ee191ca8b6723e5f6752. Bugbot is set up for automated code reviews on this repo. Configure [here](https://www.cursor.com/dashboard/bugbot).
    1. coderabbitai[bot](GitHub profile, opens in a new tab)commented

      Important

      Review skipped

      Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

      ⚙️ Run configuration

      Configuration used: Repository UI

      Review profile: CHILL

      Plan: Pro Plus

      Run ID: adeb2ca4-7e4b-4495-8b99-6e0b877b18dd

      You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

      Use the checkbox below for a quick retry:

      • 🔍 Trigger review

      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.

      ❤️ Share
      Comment `@coderabbitai help` to get the list of available commands.
    2. github-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:unvouched

    3. Cursor Bugbot has reviewed your changes using high effort and found 2 potential issues.

      Fix All in Cursor ❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the [Cursor dashboard](https://www.cursor.com/dashboard/bugbot).

      Want fixes drafted automatically? Bugbot Autofix can create code changes for findings. A team admin can enable Autofix in the Cursor dashboard.

      Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit bf2c81d040e67d225143dfbed7fb5b1a5c6c0419. Configure [here](https://www.cursor.com/dashboard/bugbot).
    4. macroscopeapp[bot](GitHub profile, opens in a new tab)commented

      Approvability

      Verdict: Needs human review

      This PR adds a new user-facing scroll-to-end button feature on mobile. New features introducing new UI behavior and interactions warrant human review. Additionally, two unresolved Cursor findings identify potential bugs with button flashing on thread switch and scroll-to-end not re-arming live follow.

      No code changes detected at 205c7fd. Prior analysis still applies.

      You can customize Macroscope's approvability policy. [Learn more](https://docs.macroscope.com/approvability#example-custom-eligibility-rules).
    5. Got it , closing this PR now

Sign in to join this conversation.