Skip to content

Open a Remotes message's images in the full-screen viewer - #176

Draft
simonhamp wants to merge 1 commit into
feat/picture-viewerfrom
feat/remote-image-viewer
Draft

simonhamp wants to merge 1 commit into
feat/picture-viewerfrom
feat/remote-image-viewer

Conversation

@simonhamp

Copy link
Copy Markdown
Member

Depends on #175. Base is feat/picture-viewer, so this diff only shows the Remotes part. Merge #175 first.

Tapping an image in a Remotes thread now opens the full-screen viewer from #175 at that image. Swipe to page, drag up or down to close, and Save to Photos all come with it, since Conversation just uses the ShowsImageViewer trait and includes the image-viewer partial once. Before this, tapping an image did nothing.

The viewer pages through the tapped message's images only, not every image in the conversation. That matches how a commit's images work. It also keeps the dashes at the bottom usable: they are 22pt each, so a thread with 20 images would run them off the screen. And a whole-thread viewer would have to change under you as older messages load and new ones arrive. Easy to revisit if paging the whole thread turns out to be what people want.

Things to know:

  • Images of a message still being pushed aren't tappable. They only exist as files on the phone until devnull has them, and the viewer refuses anything that isn't a web address anyway. They become tappable once the message is pushed.
  • The long-press menu on a message's images still works. The tap is on each image, inside the pressable that carries the menu. Checked on iOS; on Android the menu watches the long press ahead of taps, so the two don't fight.
  • The thread's thumbnails still load straight from their URL as before. Save uses the image cache copy if there is one and downloads it otherwise, same as for commits.
  • Pinned messages in the pinned sheet only show "2 images" as text, so there's nothing to tap there. Left as is.

Tested on an iOS 27.0 simulator and an Android 35 emulator against a local API with a DM holding two image messages (three images with no text, two with text). On both: tap opens at the tapped image, paging stays within that message, Save landed in Photos (iOS) and Pictures/devnull (Android) with the toast, and dragging down closes it. Long press on the images still opened Reply, React and Copy text on iOS. php artisan test: 1911 passed, with new tests in ConversationTest and an extra check in RemotesComposerTest for pending images.

Screenshots

iOS light iOS dark Android light Android dark
Thread
Viewer

The viewer shots show the second of three images from one message. Recording: iOS light, open, page and drag to close

🤖 Generated with Claude Code

Tapping an image in a direct-message or org thread now opens the image
viewer from #175 at that image. It pages through that message's images
only, as a commit's do. Drag to close and Save to Photos come with it.

Images of a message still being pushed stay untappable, since they only
exist on the phone until devnull has them. The long-press menu on a
message's images is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.

1 participant