feat(studio): chat attachments, produced files, and previews - #978
Closed
jtenniswood wants to merge 1 commit into
Closed
feat(studio): chat attachments, produced files, and previews#978jtenniswood wants to merge 1 commit into
jtenniswood wants to merge 1 commit into
Conversation
First advanced-chat tier, a bounded delta onto the Chats core's named seams. lib/attachment-store.ts keeps sent attachment bytes in IndexedDB (bounded to the last 20 sends) so attachments survive refreshes; the hook merges them back on transcript rehydrate. The composer gains the attachment pill and picker with paste/drop; HEIC and oversized images re-encode through a canvas before send. Message bubbles render attachment chips and dedupe produced-file chips off the daemon's real Write arg key via lib/file-meta (which reaches its final exported state here); file-preview.tsx renders image and PDF previews; chat-view hosts the attachment side panel with the object-URL lifecycle. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stack 13/21 — Studio: chat attachments, produced files, previews
First advanced-chat tier — a bounded delta onto PR 7's named seams.
lib/attachment-store.ts— IndexedDB store for sent attachment bytes (20-send bound), so attachments survive refreshes;sentAttachmentsRefmerges them back on transcript rehydrate.file-preview.tsx(+test) — image/PDF previews (the PDF iframe arm + the canvas crash fix).message-bubble: AttachmentChip + produced-file chips read the daemon's real Write arg key and dedupe vialib/file-meta(from PR 4) — files a chat writes render as openable attachments.chat-view: the AttachmentPanel arm + object-URL lifecycle.~5 bounded chunks in the core chat files, matching the shape of the original commits. Core flows untouched — the e2e specs are structurally unaffected.
Demo at this stack point: paste an image into a chat, preview produced files and PDFs, refresh mid-conversation and keep your attachments.
Part of the stacked landing of #618.
🤖 Generated with Claude Code