Skip to content

make sure to clear plan mode widget if canceled#314221

Merged
justschen merged 1 commit into
mainfrom
justin/dartrix
May 4, 2026
Merged

make sure to clear plan mode widget if canceled#314221
justschen merged 1 commit into
mainfrom
justin/dartrix

Conversation

@justschen
Copy link
Copy Markdown
Collaborator

clears plan mode widget if we stop or reload.

Copilot AI review requested due to automatic review settings May 4, 2026 20:24
@justschen justschen enabled auto-merge (squash) May 4, 2026 20:25
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR updates chat plan-review lifecycle handling so docked plan review UI is dismissed when a response is cancelled or later rendered in a completed state, preventing stale widgets from lingering above the input. It fits into the chat workbench model/rendering flow by coordinating response cancellation state in chatModel, runtime plan-review state in chatPlanReviewData, and cleanup in the list renderer.

Changes:

  • Added a dismiss() helper to ChatPlanReviewData to mark pending plan reviews as used, clear draft state, and resolve their deferred completion.
  • Updated ChatResponseModel.cancel() to dismiss pending plan reviews (and question carousels) when a response is cancelled.
  • Updated the chat list renderer to always clear the docked plan-review widget once the response is complete, including the cancelled/reloaded case.
Show a summary per file
File Description
src/vs/workbench/contrib/chat/common/model/chatProgressTypes/chatPlanReviewData.ts Adds centralized plan-review dismissal logic.
src/vs/workbench/contrib/chat/common/model/chatModel.ts Hooks plan-review dismissal into response cancellation.
src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.ts Clears docked plan-review UI when the response completes/cancels.

Copilot's findings

  • Files reviewed: 3/3 changed files
  • Comments generated: 1

Comment thread src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.ts
@justschen justschen merged commit cc8cfa8 into main May 4, 2026
29 of 30 checks passed
@justschen justschen deleted the justin/dartrix branch May 4, 2026 20:50
@vs-code-engineering vs-code-engineering Bot added this to the 1.120.0 milestone May 4, 2026
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.

3 participants