Skip to content

feat(task): replace prompt/inline-edit rename with a modal#39

Draft
pnewsam wants to merge 1 commit into
mainfrom
feat/rename-task-modal
Draft

feat(task): replace prompt/inline-edit rename with a modal#39
pnewsam wants to merge 1 commit into
mainfrom
feat/rename-task-modal

Conversation

@pnewsam
Copy link
Copy Markdown
Contributor

@pnewsam pnewsam commented May 7, 2026

Description

This PR aligns the task rename UX with the Claude co-work UI design language — replacing the native browser window.prompt() in the sidebar and the ad-hoc inline header <input> in ChatView with a purpose-built RenameTaskModal that matches the modal patterns used elsewhere in the co-work interface (same Modal / ModalHeader / ModalBody / ModalFooter shell, same field styles, same button treatment).

As a bonus, handleRenameTask in App.jsx now also updates the pin entry when a pinned task is renamed, keeping recents and pins in sync.

Changes

  • RenameTaskModal.jsx (new) — modal with labelled text field, validation, error banner, and busy state
  • App.jsx — adds requestRenameTask / submitRenameTask flow; mounts <RenameTaskModal>; fixes pin-sync on rename
  • Sidebar.jsx — removes window.prompt() call; delegates to onRename(task.id)
  • ChatView.jsx — removes titleEditing / titleHover state and inline <input>; simplifies header title; swaps kebab for chevron icon; delegates rename to onRenameTask(task.id)

Type of change

  • ⚡ New feature (non-breaking change which adds functionality)

Checklist

  • My code follows the style guidelines of this project
  • My changes generate no new warnings
  • I have checked my code and corrected any misspellings

@pnewsam pnewsam force-pushed the feat/rename-task-modal branch from 9effa7e to 85ee2df Compare May 7, 2026 01:04
@pnewsam pnewsam marked this pull request as draft May 7, 2026 01:13
Copy link
Copy Markdown
Contributor

@torrmal torrmal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i like this initiative

Introduce RenameTaskModal — a proper dialog with a text field, validation,
and error display — to replace the browser window.prompt() in the sidebar
and the inline header input in ChatView.

- Add RenameTaskModal component (Modal + ModalHeader/Body/Footer shell)
- Wire App.jsx: requestRenameTask / submitRenameTask drive the modal;
  handleRenameTask now also refreshes pins when the renamed task is pinned
- Sidebar: call onRename(task.id) directly; modal owns the input
- ChatView: remove titleEditing/titleHover state and inline <input>;
  simplify header title rendering; swap kebab for chevron icon

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@pnewsam pnewsam force-pushed the feat/rename-task-modal branch from 85ee2df to 4d1124b Compare May 12, 2026 01:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants