Skip to content

fix(vscode): restore images when undoing prompts - #13370

Merged
marius-kilocode merged 1 commit into
mainfrom
fix-undo-prompt-attachment-restoration
Aug 24, 2026
Merged

fix(vscode): restore images when undoing prompts#13370
marius-kilocode merged 1 commit into
mainfrom
fix-undo-prompt-attachment-restoration

Conversation

@marius-kilocode

Copy link
Copy Markdown
Collaborator

Undo Last Prompt restored only message text, so image attachments had to be selected again before resending the prompt.

Restore inline image attachments from the reverted user message alongside its text and other attachment metadata. Reuse the existing data URLs, seed the prompt input and draft state, support image-only payload restoration, and clear restored images when the prompt is redone.

Closes #13318

@kilo-code-bot

kilo-code-bot Bot commented Aug 24, 2026

Copy link
Copy Markdown
Contributor

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Files Reviewed (6 files)
  • .changeset/restore-undo-attachments.md
  • packages/kilo-vscode/tests/unit/session-utils.test.ts
  • packages/kilo-vscode/webview-ui/src/components/chat/PromptInput.tsx
  • packages/kilo-vscode/webview-ui/src/context/session-utils.ts
  • packages/kilo-vscode/webview-ui/src/context/session.tsx
  • packages/kilo-vscode/webview-ui/src/types/messages/extension-messages.ts

Reviewed by grok-4.6 · Input: 98.4K · Output: 17.6K · Cached: 1.1M

Review guidance: REVIEW.md from base branch main

@marius-kilocode
marius-kilocode merged commit 182408b into main Aug 24, 2026
24 checks passed
@marius-kilocode
marius-kilocode deleted the fix-undo-prompt-attachment-restoration branch August 24, 2026 13:30
Comment thread packages/kilo-vscode/webview-ui/src/context/session-utils.ts
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.

Undo Last Prompt Does Not Restore Attached Images

3 participants