Skip to content

feat(mobile): preview thread and attachment images - #377

Merged
nixuuu merged 1 commit into
devfrom
feat/mobile-viewers-1
Nov 9, 2026
Merged

nixuuu merged 1 commit into
devfrom
feat/mobile-viewers-1

Conversation

@nixuuu

@nixuuu nixuuu commented Nov 9, 2026 •

Copy link
Copy Markdown
Member

Image records and sent image attachments previously directed mobile readers to the web. They now show authenticated thumbnails and open a shared full-screen viewer with pinch zoom, pan and swipe-down dismissal. Composer image thumbnails and tool-result images open the same viewer. iOS exports through Share; Android saves into a chosen directory.

Validation: bun install, mobile typecheck and repository lint passed. Production fingerprint before/after is identical: iOS 2a0ef03a2a0fda8e7fad2e3df8609803d2edbda3, Android c5c880ae8d0f5d7bc867fcbaf8f756b2ca56a07d. No dependency or native changes. Full-stack checks are recorded on the top draft PR.

Manual checks on a compatible production client (installed simulator clients cannot run this checkout; no native build was made):

  1. Open an image record, a tool image and a sent attachment. Tap each thumbnail, pinch to zoom, pan, pinch back and swipe down; repeat with Close and Android Back.
  2. Open a local composer image during upload and after upload. Remove it only after closing the viewer.
  3. Check short and long filenames, portrait/landscape, phone/tablet, light/dark and Reduce Motion; verify fixed thumbnail bounds, safe areas and unobstructed header actions.
  4. Export via iOS Share/Save to Files and Android directory picker. Retry with the home computer offline and reconnect. Confirm SVG remains a file.

Copy audit (§8): “open this thread on the web to see it” → “Open image {name}”, backed by the viewer. New actions use verbs and sentence case; load/export failures explain recovery; no new glossary terms or decorative copy. Labels truncate while actions keep their slots. Visual/device checks remain manual, not claimed as executed.

Limits: private image bytes stay in the mounted view; 20 MiB image read limit. Direct photo-library saving and Android image sharing need native capabilities not installed, so export uses the existing file system instead. This PR stays draft as part of the complete mobile-viewers stack.

@nixuuu
nixuuu added this pull request to stack #379 November 9, 2026 08:38
@nixuuu
nixuuu force-pushed the feat/mobile-viewers-1 branch from e9709c4 to e0fdc11 Compare November 9, 2026 09:11
@nixuuu
nixuuu marked this pull request as ready for review November 9, 2026 09:32
@nixuuu
nixuuu merged commit 629551e into dev Nov 9, 2026
10 checks passed
@nixuuu
nixuuu deleted the feat/mobile-viewers-1 branch November 9, 2026 09:44
nixuuu added a commit that referenced this pull request Nov 9, 2026
Normal thread work is available from mobile: one shared action sheet
opens from the header or sidebar long press, queued messages can move or
steer immediately, and thread details expose usage, paths, grants,
schedules, worktrees and background tasks.

The action sheet respects confirmation preferences and uses the existing
lifecycle RPCs. Thread and queued-message deletion provide an 8-second
Undo; deleting an open thread or its parent navigates away and Undo can
reopen it. Queue ordering preserves platform turns and leaves the
default steer/queue preference unchanged.

Details show own-turn token/cost totals, label partial totals as “loaded
turns”, show the latest reported context window, and copy
directory/worktree paths with expo-clipboard. Schedule links filter the
existing editor to this thread. The worktree link opens the current
worktree without bulk cleanup controls. Paged snapshots retain
background task items outside the loaded turn window, so the list
survives reopening.

Validation:
- Gateway history integration: 7 passing tests, including background
task retention outside the tail page, reopening and page deduplication.
- Full gate passes on the rebased top branch: install, gen:check,
typecheck, lint, format:check, check:tmp and web build. The full run
finished with 1,890 pass, 161 skip, zero failures and clean temp
cleanup. No UI tests or native builds.
- Production fingerprints before/after, EAS CLI 27.4.1: iOS
`2a0ef03a2a0fda8e7fad2e3df8609803d2edbda3`; Android
`c5c880ae8d0f5d7bc867fcbaf8f756b2ca56a07d`. Both unchanged; no
dependencies or native configuration changed.

Copy audit — docs/copy.md §8:
- Before: queue edit/delete and “Steer now”. After: “Move up”, “Move
down”, “Move to top”, “Move to bottom” and “Undo” name the added
actions. Existing “Steer now” and “Move to a computer” wording is
preserved.
- “Delete thread?” repeats its verb in “Delete thread”; its description
explains side threads, stopped work, cancelled schedules and Undo.
“Usage · loaded turns” avoids claiming complete totals.
- Empty states and errors are short, actionable and use existing terms.
Long text wraps or truncates with full paths selectable; state also has
words. Static copy review completed; the visual matrix remains manual.

Manual checks after a compatible OTA is available:
1. Check 360/390 dp phone and 600/768 dp Fold widths, light/dark,
reduced motion, 1/30/160-character titles and 240-character paths. Check
overlays, scrolling, clipping and reserved control space.
2. Open actions from both entry points. Pin/unpin, regenerate, rename,
read/unread, archive/unarchive and delete; vary all three confirmation
preferences. Delete an open child through its parent and Undo. Confirm
the active goal has no duplicate menu control. Open “Move to a computer”
for a local thread and verify the existing preview/placement flow.
3. Queue four own messages with an intervening platform message. Move
each direction and to both ends; steer text and a message with files
during a running turn. Delete/Undo and edit a queued message, then
verify the delivery default still matches Settings. Send files with both
delivery choices and check the delivery note from a home that cannot
steer attachments. Open the landed image/text attachment previews.
4. Copy both paths and open schedules/current worktree. Check thread
scoping, add/edit/pause/resume/cancel a schedule, and verify worktree
status/removal still requires the existing safety confirmation.
5. Start background work, finish its foreground turn and reopen a long
thread. Stop the task from details and use “Show full output”; the
shared full-screen viewer reads inline or blob output and offers
Copy/Quote. Close it to return to details. Compare usage before/after
loading earlier turns.

The final rebase includes #377–#378 and #385. Background tasks now reuse
the landed TextViewer; there is no timeline-link fallback or separate
output viewer. Existing quote and send behavior is preserved.

Layer 2 of 3. Rebased onto dev at `8fb894e4`: preserves #393 attachment
steering, #398 previews and #388–#390 bot/settings parity, including the
local thread move action. Existing bases and ready-for-review states are
preserved.
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