feat(mobile): rename a thread from the row menu - #5648
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 Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
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: Needs human review This PR introduces a new user-facing feature (rename thread from row menu) with a new dialog component and integration across multiple screens. While it uses existing APIs and follows established patterns, new capability warrants human review. You can customize Macroscope's approvability policy. Learn more. |
The thread row long-press menu only offered Archive and Delete. Add a
"Rename" item that opens a prefilled dialog and dispatches
thread.meta.update { title }, matching the web per-thread action menu.
- New RenameThreadDialogHost: a cross-platform text-input dialog (RN's
Alert.prompt is iOS-only, so Android needs a custom modal), mounted at the
app root next to ConfirmDialogHost. Rename stays disabled until the trimmed
value is non-empty, and an unchanged title dispatches nothing.
- useThreadListActions gains renameThread, reusing the existing
updateMetadata command.
- Both the v1 (ThreadListRow) and v2 (ThreadListV2Row) row menus render the
item across every variant, on both the Home list and the iPad sidebar.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
78a0ca2 to
d21ac12
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
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 for commit d21ac12. Configure here.
The rename dialog is a centered edge-to-edge Modal with an autofocused field; on Android the soft keyboard could overlay the card, hiding the input and actions. Wrap the content in KeyboardAvoidingView (from react-native-keyboard-controller, the same helper the composer sheets use) so the card lifts above the keyboard. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
This was added already sorry |

What changed
The thread row long-press menu previously offered only Archive and Delete. This adds a Rename item, matching the web per-thread action menu.
Selecting Rename opens a small dialog prefilled with the current title; confirming dispatches
thread.meta.update { title }.Appears in every thread-row menu variant across both list implementations (the v1
ThreadListRowand the v2ThreadListV2Row) and on both surfaces (compact Home list and the iPad sidebar).Why
Renaming a thread is a core action on the web client but was unreachable anywhere in the mobile app.
How
RenameThreadDialogHost(new) — an imperative, cross-platform text-input dialog styled to match the existingConfirmDialogHost. React Native'sAlert.promptis iOS-only, so Android needs a custom modal. Mounted once at the app root. Rename stays disabled until the trimmed value is non-empty, and an unchanged title dispatches nothing.useThreadListActionsgainsrenameThread, reusing the existingthreadEnvironment.updateMetadatacommand — no new command or contract.onRenameThreadprop and render the item when provided.No server, contract, or shared-runtime changes.
Scope
Split out of the original combined PR per request. Sibling PRs cover the other row-menu actions independently: Regenerate title and Unarchive.
Testing
tsc --noEmit,vp fmt --check,vp lint: cleanScreenshots
I don't have an Android device/emulator here to capture before/after images as
CONTRIBUTING.mdrequests — happy to add them. The change adds "Rename" above the existing Archive/Delete items in the row long-press menu.🤖 Generated with Claude Code
Note
Low Risk
Client-only UI and menu wiring that reuses an existing metadata update path; no server or contract changes.
Overview
Adds Rename to thread row long-press menus on Home and the iPad sidebar, for both v1 and v2 list rows, aligning mobile with the web thread menu.
Choosing Rename opens a new cross-platform
showRenameThreadDialogmodal (mounted viaRenameThreadDialogHostat the app root, patterned afterConfirmDialogHost). The field is prefilled with the current title; Rename stays disabled until the trimmed name is non-empty, and confirming an unchanged title skips the update.useThreadListActions.renameThreaddrives the flow and calls the existingthreadEnvironment.updateMetadatacommand with the new title, with an alert on failure.Reviewed by Cursor Bugbot for commit d7cb11a. Bugbot is set up for automated code reviews on this repo. Configure here.
Note
Add rename thread action to thread row menus in mobile
ThreadListRowandThreadListV2Row, visible when a rename handler is provided.RenameThreadDialogHost, a modal with a prefilled text input and Cancel/Rename actions; confirm is disabled until the trimmed value is non-empty and differs from the original.showRenameThreadDialog, an imperative function to trigger the modal from anywhere in the app.useThreadListActions, which callsupdateMetadatato persist the new title and shows an alert on failure.Macroscope summarized d7cb11a.