Skip to content

fix: Persist new task draft across navigation#1436

Merged
charlesvien merged 2 commits intomainfrom
04-01-persist_new_task_draft_across_navigation
Apr 2, 2026
Merged

fix: Persist new task draft across navigation#1436
charlesvien merged 2 commits intomainfrom
04-01-persist_new_task_draft_across_navigation

Conversation

@charlesvien
Copy link
Copy Markdown
Member

@charlesvien charlesvien commented Apr 2, 2026

Problem

Task input draft in command center cells is lost when navigating away because the creating state uses local useState that resets on unmount.

Changes

  1. Move isCreating state to persisted creatingCells in command center store
  2. Give each cell a unique draft session ID (cc-cell-{index}) to avoid collisions
  3. Accept optional sessionId prop on TaskInput for cell-specific drafts
  4. Clean up creating state and drafts on task assignment, cancel and layout resize

How did you test this?

Manually

@charlesvien charlesvien changed the title Persist new task draft across navigation fix: Persist new task draft across navigation Apr 2, 2026
Copy link
Copy Markdown
Member Author

charlesvien commented Apr 2, 2026

@charlesvien charlesvien merged commit dc93641 into main Apr 2, 2026
16 checks passed
@charlesvien charlesvien deleted the 04-01-persist_new_task_draft_across_navigation branch April 2, 2026 05:12
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