archive threads with middle click#2782
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 |
| void attemptArchiveThread(threadRef); | ||
| }, | ||
| [attemptArchiveThread, clearConfirmingArchive, threadRef], | ||
| ); |
There was a problem hiding this comment.
Middle-click bypasses user's archive confirmation preference
Low Severity
The handleRowAuxClick handler directly calls attemptArchiveThread without checking appSettingsConfirmThreadArchive. The existing archive UI (icon button click) respects this user setting by routing through handleStartArchiveConfirmation when enabled, requiring an explicit "Confirm" click before archiving. Middle-click silently ignores this preference, which is especially risky since middle-click can be accidentally triggered during scroll-wheel usage.
Reviewed by Cursor Bugbot for commit 2879af1. Configure here.
ApprovabilityVerdict: Needs human review This PR introduces a new user-facing feature (middle-click to archive threads) and has an unresolved comment identifying that it bypasses the user's archive confirmation preference setting, which is a behavioral inconsistency that warrants review. You can customize Macroscope's approvability policy. Learn more. |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
There are 2 total unresolved issues (including 1 from previous review).
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 7c19250. Configure here.
| void attemptArchiveThread(threadRef); | ||
| }, | ||
| [attemptArchiveThread, clearConfirmingArchive, threadRef], | ||
| ); |
There was a problem hiding this comment.
Middle-click archives running threads, showing confusing error toast
Medium Severity
The handleRowAuxClick handler doesn't check isThreadRunning before calling attemptArchiveThread. All other archive paths in this component are guarded by !isThreadRunning — the archive buttons are only rendered when the thread isn't running (line 653). The middle-click bypasses this, causing archiveThread to throw "Cannot archive a running thread," which surfaces as an unexpected error toast to the user instead of being silently prevented.
Reviewed by Cursor Bugbot for commit 7c19250. Configure here.


What Changed
Middle-clicking a sidebar thread now archives it.
Why
Faster thread cleanup without changing normal left-click navigation or context menu behavior.
Everyone do similar: browsers/editors close tabs on middle mouse click.
UI Changes
_20260522_101801.webm
Checklist
Note
Low Risk
Low risk UI interaction change localized to the sidebar thread row; main risk is unintended interference with mouse events (e.g., selection/navigation) on different browsers/platforms.
Overview
Adds middle-click (mouse button 1) handling on sidebar thread rows to archive a thread directly. A
mousedownhandler prevents the default middle-click behavior, and anauxclickhandler stops propagation, clears any pending archive confirmation state, and callsattemptArchiveThreadfor the clicked thread.Reviewed by Cursor Bugbot for commit 7c19250. Bugbot is set up for automated code reviews on this repo. Configure here.
Note
Archive threads with middle click in sidebar
Adds middle-click support to
SidebarThreadRowin Sidebar.tsx. Amousedownhandler prevents the default browser scroll behavior, and anauxclickhandler callsattemptArchiveThreadon the target thread while clearing any pending archive confirmation.Macroscope summarized 7c19250.