Repository navigation
Agent: show message image thumbnails and fitted previews - #1612
Merged
Merged
Conversation
AnthonyRonning
force-pushed
the
fix/1607-message-image-previews
branch
3 times, most recently
from
November 14, 2026 16:19
89226db to
2bb2792
Compare
AnthonyRonning
force-pushed
the
fix/1607-message-image-previews
branch
from
November 14, 2026 16:19
2bb2792 to
99daf9d
Compare
The message being sent drew its pictures as cropped 64 px squares inside the bubble, while the sent message shows 72 px thumbnails above a text-only bubble. On the hand-off the picture changed place, size and crop in one frame, and the thread shifted. - The preview draws through the sent message's own pieces (attachment_row, attachment_thumbnail, attachment_chip), with no bubble for a message of pictures only. - A draft keeps a small whole picture beside its square chip, both from one decode. The row that takes over shows it until the stored picture loads, so a thumbnail never gives way to a file name. - The thumbnail's picture rounds its own corners. A square picture poked past the box's rounded corners. - The image preview's card is the fitted picture, so a click beside the picture closes it. The card used to cover 90% of the window and swallow that click. Co-Authored-By: Claude <noreply@anthropic.com>
The row that takes over from a message being sent borrowed the draft's pictures by count and order. Before the send is acknowledged that row can be another controller's message, so it could briefly show this draft's picture. The message being sent now records each file's stored id when its upload finishes, and a row shows a draft's picture only for a file it names. Co-Authored-By: Claude <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.
Screenshots in sent messages could paint outside their measured bubble and overlap the conversation. Messages now show 72 px image thumbnails above the text; clicking one opens the complete image fitted to the window.
The preview uses the shared dialog motion from #1575 and honors reduced motion. Escape, the backdrop and Close dismiss immediately and restore focus. Attachment buttons support native Enter/Space and Tab with or without Application Vim, and delayed trust prompts wait until the preview closes.
Rebased onto master after #1571, #1573 and #1575 merged. Fixes #1607.
Follow-up from QA (
cdccd8b4)Running the first commit on macOS and stepping through recordings frame by frame found three problems, fixed in the second commit:
attachment_row,attachment_thumbnail,attachment_chip), with no bubble for a message of pictures only. A draft keeps a small whole picture beside its square chip (one decode), and the row that takes over shows it until the stored picture loads, so a thumbnail never gives way to a file name.docs/motion.mdrecords the rule: anything a sent message shows must be drawn the same way in the sending preview.Follow-up from review (
b9124fcf)The second commit matched a draft's pictures to the row that takes over by count and order. Before a send is acknowledged, that row can be another controller's message in the same task, so a message of theirs with the same number of pictures could briefly show this draft's picture. The message being sent now records each file's stored id when its upload finishes, and a row shows a draft's picture only for a file it names. This also covers the case where another controller's row arrives first: this send's own row still shows its picture from the first frame.
Testing
b9124fcf: lint, all workspace tests (desktop app 1,502 passed / 3 ignored) and the extra lanes passed. CI was green oncdccd8b4.cdccd8b4).cdccd8b4): sends with one picture and text, three pictures and no text, landscape, portrait, square and a 2940x1912 picture; hand-off recorded and stepped through; preview entrance, instant close by Escape, backdrop and beside the picture, no click-through; reopening the task shows thumbnails with no pop.b9124fcf): a picture with text sent through the real upload and the hand-off stepped through again; the thumbnail shows in every frame, so the stored ids line up on a real send.cdccd8b4build): attach through the file dialog, send with and without text, thumbnail rendering, preview fit, close by clicking beside the picture.Design note
The composer shows attachments as cropped squares; the sent message shows the whole picture letterboxed in a box. This PR keeps the letterboxed look. Hover on a thumbnail only tints the letterbox bands.
🤖 Generated with Claude Code