fix(slides): clear staged attachments on New chat (#234)

Co-authored-by: Aniruddha Adak <aniruddhaadak80@users.noreply.github.com>
This commit is contained in:
ANIRUDDHA ADAK
2026-09-07 18:03:50 +08:00
committed by GitHub
co-authored by Aniruddha Adak
parent 6d16796094
commit 2e805f1635
+4
View File
@@ -1873,6 +1873,10 @@ export function AiPanel({
// original message index, so stale entries would re-attach to unrelated
// new messages after an index collision.
setClarifyAnswers([])
// Unsent composer attachments would otherwise ride into the next chat's
// file context (availableAttachments merges sent + live), mirroring docs.
setAttachments([])
setAttachNotice(null)
sentAttachmentsRef.current = []
readAttachmentPathsRef.current.clear()
inputRef.current?.focus()