Repository navigation
feat(mobile): show compact chat attachments with a swipeable image viewer - #29642
niconicohu wants to merge 40 commits into
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the
Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
No actionable comments were generated in the recent review.
|
There was a problem hiding this comment.
Actionable comments posted: 2
ℹ️ Review info
⚙️ Run configuration
- Configuration used: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
2d1655a6-061a-45ce-87c3-31fc539e42be
📒 Files selected for processing: 18
mobile/src/session/MobileNativeChatFileAttachments.tsxmobile/src/session/MobileNativeChatImage.tsxmobile/src/session/MobileNativeChatImageGallery.tsxmobile/src/session/MobileNativeChatImageViewer.tsxmobile/src/session/MobileNativeChatMessage.android.test.tsmobile/src/session/MobileNativeChatMessage.attachments.test.tsxmobile/src/session/MobileNativeChatMessage.copy.test.tsxmobile/src/session/MobileNativeChatMessage.subagent-group.test.tsxmobile/src/session/MobileNativeChatMessage.test.tsmobile/src/session/MobileNativeChatMessage.tool-result-availability.test.tsxmobile/src/session/MobileNativeChatMessage.tsxmobile/src/session/MobileNativeChatOverlay.tsxmobile/src/session/mobile-native-chat-attachment-read.tsmobile/src/session/mobile-native-chat-file-attachments.test.tsmobile/src/session/mobile-native-chat-file-attachments.tsmobile/src/session/mobile-native-chat-message-styles.tsmobile/src/session/mobile-native-chat-message-visuals.test.tsmobile/src/session/mobile-native-chat-stopped-before-start.test.tsx
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 6 remain after this review.
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to GitHub limitations.
🟡 Minor · Gate the attachment read on agent-session.attachments.v1. · MobileNativeChatImage.tsx:49-71
mobile/src/session/MobileNativeChatImage.tsx:49-71
🩺 Stability & Availability | 🟡 Minor | ⚡ Quick winGate the attachment read on
agent-session.attachments.v1.
MobileNativeChatImagestartsreadMobileNativeChatAttachmentwhenever a structured client exists. The reader sendsagentSessionAttachment.readwithout a capability check.The host contract says older hosts without
agent-session.attachments.v1returnmethod_not_found. The component converts this failure toImage unavailable · Tap to retry. Pass the negotiated capability into this path and skip the RPC when it is absent.
🟡 Minor · Normalize dual-source historical image blocks before… · MobileNativeChatImageGallery.tsx:33-35
mobile/src/session/MobileNativeChatImageGallery.tsx:33-35
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winNormalize dual-source historical image blocks before rendering.
imageRefBlockcan emit both a directurland an owning-hostpath. The gallery selectsurl, soMobileNativeChatImagetreats the value as already renderable and skipsreadMobileNativeChatAttachment. The gallery can therefore show the URL instead of the stored attachment.Normalize the historical producer to emit exactly one source, using the owning-host
pathwhen both fields are present. Do not change the gallery topath ?? url; the mobile preview projection can add an already-resolvedfile:///URL to an existing path.
🟡 Minor · Add a safe opener path for stored file attachments. · MobileNativeChatFileAttachments.tsx:20-33
mobile/src/session/MobileNativeChatFileAttachments.tsx:20-33
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winAdd a safe opener path for stored file attachments.
onOpenFile(path)reachesopenMobileNativeChatFileTap, but stored attachment paths outside the worktree fail the assistant-output provenance check beforefiles.open. The existing attachment reader cannot replace this flow because it returns only image previews.Add a server-authorized attachment-store resolution path for non-image files. Do not bypass provenance in the tile callback or treat the path-name check alone as authorization.
ℹ️ Review info
⚙️ Run configuration
- Configuration used: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
addb63ab-b113-4830-8565-1987a88c6657
📒 Files selected for processing: 4
mobile/src/session/MobileNativeChatImage.tsxmobile/src/session/MobileNativeChatMessage.attachments.test.tsxmobile/src/session/mobile-native-chat-file-attachments.test.tsmobile/src/session/mobile-native-chat-file-attachments.ts
🚧 Files skipped from review as they are similar to previous changes: 3
- mobile/src/session/MobileNativeChatImage.tsx
- mobile/src/session/mobile-native-chat-file-attachments.test.ts
- mobile/src/session/MobileNativeChatMessage.attachments.test.tsx
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 3 remain after this review.
|
Addressed the three outside-diff findings in feff5fc:
Validation on this independent branch: 10,811 mobile tests, 55 focused host tests, application/test/node typechecks, changed-code quality gate, complete mobile-web bundle verification, and a rebuilt Android release APK with verified V2 signature. Live SSH and physical iOS coverage remain unverified. |
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
- Configuration used: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
f2fd2dfe-11ad-4a18-b1ab-8758e0890d03
📒 Files selected for processing: 16
mobile/src/session/MobileNativeChatOverlay.tsxmobile/src/session/mobile-native-chat-merged-snapshot-parity-hooks.test.tsxmobile/src/session/mobile-native-chat-visual-read.test.tsmobile/src/session/mobile-native-chat-visual-read.tsmobile/src/session/mobile-structured-agent-session-host-support.test.tsmobile/src/session/mobile-structured-agent-session-host-support.tsmobile/src/session/use-mobile-structured-agent-session-prompt-cancel.test.tsxmobile/src/session/use-mobile-structured-agent-session-queued.test-fixture.tsmobile/src/session/use-mobile-structured-agent-session.tsmobile/src/session/use-mobile-structured-turn-indicator.test.tsxsrc/main/native-chat/native-chat-file-provenance.test.tssrc/main/native-chat/native-chat-file-provenance.tssrc/main/native-chat/transcript-record-blocks.test.tssrc/main/native-chat/transcript-record-blocks.tssrc/main/runtime/orca-runtime-files-terminal-artifact-grants.test.tssrc/main/runtime/terminal/artifacts/terminal-artifacts.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 2 remain after this review.
|
@coderabbitai full review |
✅ Action performedFull review finished. |
There was a problem hiding this comment.
Actionable comments posted: 2
ℹ️ Review info
⚙️ Run configuration
- Configuration used: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
4cf8b54a-2170-4907-9640-c06290c53b54
📒 Files selected for processing: 33
mobile/src/session/MobileNativeChatFileAttachments.tsxmobile/src/session/MobileNativeChatImage.tsxmobile/src/session/MobileNativeChatImageGallery.tsxmobile/src/session/MobileNativeChatImageViewer.tsxmobile/src/session/MobileNativeChatMessage.android.test.tsmobile/src/session/MobileNativeChatMessage.attachments.test.tsxmobile/src/session/MobileNativeChatMessage.copy.test.tsxmobile/src/session/MobileNativeChatMessage.subagent-group.test.tsxmobile/src/session/MobileNativeChatMessage.test.tsmobile/src/session/MobileNativeChatMessage.tool-result-availability.test.tsxmobile/src/session/MobileNativeChatMessage.tsxmobile/src/session/MobileNativeChatOverlay.tsxmobile/src/session/mobile-native-chat-attachment-read.tsmobile/src/session/mobile-native-chat-file-attachments.test.tsmobile/src/session/mobile-native-chat-file-attachments.tsmobile/src/session/mobile-native-chat-merged-snapshot-parity-hooks.test.tsxmobile/src/session/mobile-native-chat-message-styles.tsmobile/src/session/mobile-native-chat-message-visuals.test.tsmobile/src/session/mobile-native-chat-stopped-before-start.test.tsxmobile/src/session/mobile-native-chat-visual-read.test.tsmobile/src/session/mobile-native-chat-visual-read.tsmobile/src/session/mobile-structured-agent-session-host-support.test.tsmobile/src/session/mobile-structured-agent-session-host-support.tsmobile/src/session/use-mobile-structured-agent-session-prompt-cancel.test.tsxmobile/src/session/use-mobile-structured-agent-session-queued.test-fixture.tsmobile/src/session/use-mobile-structured-agent-session.tsmobile/src/session/use-mobile-structured-turn-indicator.test.tsxsrc/main/native-chat/native-chat-file-provenance.test.tssrc/main/native-chat/native-chat-file-provenance.tssrc/main/native-chat/transcript-record-blocks.test.tssrc/main/native-chat/transcript-record-blocks.tssrc/main/runtime/orca-runtime-files-terminal-artifact-grants.test.tssrc/main/runtime/terminal/artifacts/terminal-artifacts.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 6 remain after this review.
|
@coderabbitai review |
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to GitHub limitations.
🟡 Minor · Do not extract references from inline Markdown… · mobile-native-chat-file-attachments.ts:1-42
mobile/src/session/mobile-native-chat-file-attachments.ts:1-42
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winDo not extract references from inline Markdown code.
mobileMarkdownCodeLinesprotects only fenced and indented code blocks. It does not protectcode_inlinespans. For example,Review \@/root/.orca/agent-session-attachments/id/report.pdf`matches the attachment regex because whitespace surrounds the canonical reference. The splitter removes the reference from the code span and returns it infiles.MobileNativeChatMessage` then renders that path as a file tile.Make
splitMobileNativeChatFileAttachmentsskip attachment matches inside inline-code spans while continuing to extract references from ordinary prose. Do not skip the entire line, because a line can contain both inline code and a valid prose reference.
ℹ️ Review info
⚙️ Run configuration
- Configuration used: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
0fc05cd3-a7b3-4be9-9078-67718b34bfb7
📒 Files selected for processing: 3
mobile/src/session/MobileNativeChatMessage.attachments.test.tsxmobile/src/session/mobile-native-chat-file-attachments.test.tsmobile/src/session/mobile-native-chat-file-attachments.ts
🚧 Files skipped from review as they are similar to previous changes: 2
- mobile/src/session/mobile-native-chat-file-attachments.ts
- mobile/src/session/mobile-native-chat-file-attachments.test.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 2 remain after this review.
|
|
Fixed the outside-diff inline-code finding from review 5550848615 in 457251c. Attachment matches are now checked against source ranges for both block and inline code. A mixed line can keep its literal example and still extract a real prose attachment; multiline spans, differing backtick widths, unmatched markers and separate paragraphs are covered. The delimiter scan and reference walk are bounded linear passes. The new regression failed before the fix. The independent branch passes 10,821 mobile tests, app/test typechecks, changed-code checks, complete mobile-web verification and a rebuilt Android release with verified V2 signature. This does not change stored-file authorization. Physical Android/iOS and live SSH coverage remain unverified. |
|
@coderabbitai resume |
✅ Action performedReviews resumed and review finished. |
|
@coderabbitai review |
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
- Configuration used: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
7b097be2-dded-4ac8-a5c1-e14a863d22cc
📒 Files selected for processing: 4
mobile/src/components/mobile-markdown-literal-ranges.tsmobile/src/components/mobile-markdown-tree.tsmobile/src/session/mobile-native-chat-file-attachments.test.tsmobile/src/session/mobile-native-chat-file-attachments.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 6 remain after this review.
|
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
- Configuration used: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
1bccc0af-8ad3-4e7c-b6ed-258c107d501e
📒 Files selected for processing: 53
mobile/src/session/MobileNativeChatImageGallery.tsxmobile/src/session/MobileNativeChatImageViewer.tsxmobile/src/session/MobileNativeChatMessage.android.test.tsmobile/src/session/MobileNativeChatMessage.attachments.test.tsxmobile/src/session/MobileNativeChatMessage.test.tsmobile/src/session/MobileNativeChatMessage.tsxmobile/src/session/MobileNativeChatOverlay.tsxmobile/src/session/MobileNativeChatRowOverlaysHost.test.tsxmobile/src/session/mobile-native-chat-merged-snapshot-parity-hooks.test.tsxmobile/src/session/mobile-native-chat-row-overlays.tssrc/main/ai-vault/session-scanner-discovery.tssrc/main/ai-vault/structured-chat-cli-fork.tssrc/main/grok/grok-transcript-import.tssrc/main/native-chat/agent-session-journal/adopted-transcript-source.tssrc/main/native-chat/agent-session-journal/journal-legacy-import.tssrc/main/native-chat/agent-session-wire/structured-agent-session-client-delivery.tssrc/main/native-chat/agent-session-wire/structured-agent-session-mutation-context.tssrc/main/native-chat/agent-session-wire/structured-agent-session-open-child-work.tssrc/main/native-chat/agent-session-wire/structured-agent-session-status-feed.tssrc/main/native-chat/agent-session-wire/structured-agent-session-status-ownership.test.tssrc/main/native-chat/agent-session-wire/structured-agent-session-status-ownership.tssrc/main/native-chat/agent-session-wire/structured-agent-session-turns.test.tssrc/main/native-chat/agent-session-wire/structured-conversation-command-admission.test.tssrc/main/native-chat/codex-adoption-preparation.tssrc/main/native-chat/session-file-resolver.tssrc/main/native-chat/structured-agent-cli-conversations.tssrc/main/native-chat/structured-agent-cli-source.tssrc/main/native-chat/structured-agent-session-source-admission.test.tssrc/main/native-chat/transcript-opencode-sqlite-query.test.tssrc/main/native-chat/transcript-opencode-sqlite-query.tssrc/main/node-runtime/runtime-archive-download.test.tssrc/main/omp/omp-session-cwd-lookup.test.tssrc/main/runtime/agent-launch-scope-runtime.test.tssrc/main/runtime/orca-runtime-structured-agent-session-create-intent.test.tssrc/main/runtime/revisioned-state.tssrc/main/runtime/rpc/methods/managed-runtime-install.test.tssrc/main/runtime/rpc/methods/managed-runtime-install.tssrc/main/runtime/rpc/methods/structured-agent-session-adoption-replay.test.tssrc/main/runtime/rpc/methods/structured-agent-session-create.tssrc/main/runtime/runtime-pane-admission.tssrc/main/runtime/session-tabs/structured-session-create-support.tssrc/main/runtime/structured-agent-session-create-adoption.tssrc/main/runtime/terminal/launch/mobile-terminal-chat-fork-create.tssrc/main/runtime/terminal/launch/mobile-terminal-chat-fork.test.tssrc/main/runtime/terminal/launch/mobile-terminal-chat-fork.tssrc/main/runtime/terminal/launch/mobile-terminal-owned-create.tssrc/main/runtime/terminal/launch/mobile-terminal-renderer-create.tssrc/renderer/src/hooks/ipc-events/terminal-presentation-ipc-bridge.tssrc/shared/rpc-contract/session-tabs-schemas-params.tssrc/shared/session-tabs-runtime-capabilities.tssrc/shared/structured-agent-session-create.test.tssrc/shared/structured-agent-session-mutation.tstests/e2e/cross-version-wire/cross-version-stop-note-test-rig.ts
💤 Files with no reviewable changes: 1
- src/main/native-chat/agent-session-wire/structured-agent-session-status-ownership.test.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 7 remain after this review.
|
@coderabbitai review Please review the incremental conflict resolution at 479fa8c after merging main f9aeb34. The overlay retains main's OMP terminal-answer route inside the attachment, resource and full-message reader contexts. The combined mounted regression failed when that route was omitted, then passed with both behaviors present; the full mobile suite passed 11,292 tests. The PR description records the current validation and limitations. This is one incremental review request for the new head. No full review or resume is requested. |
✅ Action performedReview finished.
|
|
@coderabbitai review Please review the increment at de5bfa9 after merging main 4ed095d. Both attachment and model-catalog capabilities remain, and asynchronous structured answers reuse the existing accepted-action hook. The mounted regression failed for accepted/refused answers before the routing fix and now passes. Updated test boundaries preserve all assertions after main’s scroll-anchor move and file-review change. The full mobile suite passed 11,411 tests; typechecks, quality and current-main ratchets passed. The PR description records details, equivalent browser line-limit fixes and source-only limitations. This is one incremental request for this new head. |
✅ Action performedReview finished.
|
|
@coderabbitai review Please review the increment at de29c03 after merging main 2a45fdc. The actual browser prop-type conflict is resolved by adopting main’s complete component unchanged. Existing attachments behavior is retained. The standard one-worker mobile suite passed 11,464 tests; desktop regressions, typechecks, current-main ratchets and PR-scoped quality passed. The updated description records current evidence and the source-only boundary. |
✅ Action performedReview finished.
|
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to GitHub limitations.
🟡 Minor · Preserve host-path provenance before selecting a direct URI. · MobileNativeChatImage.tsx:45
mobile/src/session/MobileNativeChatImage.tsx:45
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winPreserve host-path provenance before selecting a direct URI.
image.url ?? image.pathpasses a Claude host path such asfile:///host/image.pngasuri.isRenderableImageUri(uri)then marks it direct, so the host reader does not run. The device receives a path that exists only on the host and cannot load the image.Preserve whether the value came from
urlorpath. Keep direct handling enabled for device-local file URLs.Suggested fix
export function MobileNativeChatImage({ uri, + isHostPath = false, alt, ... uri: string | undefined + isHostPath?: boolean ... - const direct = isRenderableImageUri(uri) + const direct = !isHostPath && isRenderableImageUri(uri)<MobileNativeChatImage uri={image.url ?? image.path} + isHostPath={typeof image.url !== 'string'} alt={image.alt}<MobileNativeChatImage uri={image.url ?? image.path} + isHostPath={typeof image.url !== 'string'} alt={image.alt}
ℹ️ Review info
⚙️ Run configuration
- Configuration used: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
fc479f73-75c7-4926-b70d-257c1ec1fb75
📒 Files selected for processing: 1
src/renderer/src/components/browser-pane/assemble-chrome/BrowserAddressBar.tsx
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
|
@coderabbitai review Please review the increment at 04394c9, the normal merge of de29c03 and main 2570d8f. The sole conflict was the phone parser import list: both this PR's existing literal-range reader and main's CJK plugin are retained. Main's URL boundaries, remembered terminal identity/write locks and all existing attachment/resource/item readers, OMP terminal-answer route and accepted-action handling remain present. All package manifests and lockfiles exactly match main. A combined regression exercises CJK bold, a code-literal attachment reference and an actual prose attachment together. Removing CJK caused that case and main's sentence case to fail; restoring it passed all 62 focused checks. Fresh full phone JSON: 11,420 passed, six skipped, zero failures, 1,117 files. Forty-six root provenance/grant/RPC checks in six files, all four root typechecks, phone app/test typechecks/lint, all ratchets, shared dependency check, frozen installs and final 67-file PR quality passed. Tested tree equals the normal commit tree. No assertions or limits weakened. No fresh rendered UI/app build/install/deployment/service/profile action. |
✅ Action performedReview finished.
|
|
@coderabbitai review Please review the increment at 21f8844, the normal merge of 04394c9 and main a02a635. The sole conflict was the phone host-capability test: main's explicit item-detail assertion and this PR's independent attachment-read/phone-upload assertions are all retained. A legacy read capability does not grant phone uploads; the full-object expectations cover that boundary. No production code was manually changed. Main's strengthened visual-reader checks and the existing owner/client capability regression both remain. Completed background validation: full mobile JSON 11,403 passed/six skipped/zero failures/1,120 file results; 46 host provenance/grant/mobile-RPC checks in six files; all four root typecheck projects using local incremental tsrs; mobile app typecheck/lint/test-typecheck ratchet; frozen root/mobile installs, all ratchets, shared dependencies and test collection. The actual 67-file PR quality gate and normal commit hooks passed. Tested tree df9a92b6ea7f100c36192a6bcbbbcee2054994ca exactly equals the commit tree. No assertions or limits were weakened. The description records this evidence and the lack of fresh rendered/physical-device validation. Installed integration and services remain unchanged. This is one incremental request for this valid new-head conflict fix; no full review or resume is requested. |
✅ Action performed
|
Keep the attachment grant regression aligned with the agent-session identity module moved on main. Preserve all production behavior and test assertions.
|
@coderabbitai review Please review fd90376, the normal merge of 21f8844 and main a289c98. Main moved the conversation/message identity modules under src/shared/agent-session. The branch-only attachment-grant regression retained an old type import; the only manual edit follows its existing relocated module. No production logic or assertions changed. The unchanged merged tree reproduces TS2307 at orca-runtime-files-user-attachment-grants.test.ts:5. After the one-line import correction, all four root typecheck projects pass using local incremental tsrs. Background validation also passed all 11,393 mobile tests (six skipped, zero failures, 1,120 file results), 41 host attachment/provenance/grant/mobile-RPC checks in five existing files, mobile app TC/lint/test-TC ratchet, frozen installs, all ratchets, shared dependencies and test collection. Actual PR quality passes all scans for 67 code files. Normal commit hooks passed and tested tree ee4915396f105ba0b80c74e030232bf158589c1c exactly equals the commit tree. The updated description records the exact evidence and preserves the distinction from full required CI and rendered/device validation. Installed integration and services are unchanged. The fresh paused summary identifies this latest commit as not reviewed and shows no review in progress; this is one incremental request after the valid new-head fix. |
✅ Action performed
|
Retain attachment contexts and the safe-area fixture alongside main's checked React node queries. Use its existing host query in the shortened-message test.
|
@coderabbitai review Please review 771cef9, the normal merge of fd90376 and main 0fa161b. The only conflicts were the imports in MobileNativeChatMessage.test.ts and MobileNativeChatOverlay.test.ts. The resolution keeps the branch's safe-area mock and attachment/resource/item contexts alongside main's ReactNode type and existing host-node query functions. The shortened-message test also reuses findByHostType to fix its newly exposed TS2367. No production code, assertion, rule or baseline was manually weakened. The two conflict suites pass all57 checks. Final full mobile JSON:11,387passed/sixskipped/zero failures/1,120file results. All4rootTC(local incremental tsrs),41host attachment/provenance/grant/mobileRPC checks in5files, mobile appTC/lint/testTCratchet(1,115programfiles/fiveintentionalexclusions/ZEROgrandfathered), empty E2Ebaseline ratchet, frozen installs, all other ratchets/shareddeps/testcollection passed. Actual67-file PRquality and normal commit hooks passed; tested tree bfca5fafe43ffef652705f715dc23ad0a9eb2c86 exactly equals the commit tree. All86message and29overlay assertion lines remain; only the branch regression's host-query line needed adaptation. The description records the updated evidence and no fresh rendered/device validation or full required-CI success claim. Installed integration and services are unchanged. A fresh complete read shows the paused bot's latest771cef commit as not reviewed and the prior request settled; this is one incremental review request for the valid new-head conflict fix. |
✅ Action performed
|
|
@coderabbitai review Please review eeb07ce after the normal merge of upstream 7d6603a. Eight real comment-cleanup conflicts were resolved while preserving attachment/gallery rendering, resource context, safe-area fixtures, prompt-card wrappers and the shortened-message regression. Fresh typechecks/mobile tests/host tests and the failed upstream-wide validation checks are described explicitly in the PR body. This is one request for the new fixed head; old 771cef coverage is historical. |
✅ Action performed
|
|
@coderabbitai review Please review new head 5bd23f0, the normal merge of eeb07ce and upstream 220d56f. The sole manual edit maps the attachment-grant test mock to the existing relocated filesystem-auth module. No production logic or assertion changed. The original two tests already passed, so this is a stale-mock compatibility correction, not a claimed runtime RED/GREEN. Fresh validation and limitations are in the updated body: all root/mobile typechecks and lint, 32 host checks in four files, full mobile 11,368 passed/six skipped/zero failed, normal hooks and exact tested commit tree. The 67-file unified gate passed 26/27 checks including unit tests; its flaky ratchet still fails ENOBUFS against the old fork base. Exact-head required CI and rendered/device validation remain separate. This is one request for this new head; previous eeb review coverage is historical. |
✅ Action performed
|
ELI5
Phone chats show compact attachment previews. Tap an image to browse the gallery and zoom; tap a file to open its read-only preview on the conversation's host.
What Changed
User images and files are separated from message text and shown as compact previews, with the third image displaying the remaining count. Assistant image references use the same conversation gallery. The overlay stays with the conversation when a streaming row is replaced.
Stored user uploads retain their existing attachment authorization; assistant resources use the owning host's conversation grant. Late results from a different host or conversation are discarded. External web images remain behind a tap, code stays literal, and unsupported destinations do not enter the gallery. Existing full-message/item readers, reading anchors and tool disclosure remain available.
This head adopts main
220d56f4e4c1through a clean normal merge. The only manual change maps the attachment-grant test's filesystem authorization mock to the existing relocated module. Attachment/gallery rendering, safe-area fixtures, resource context, prompt-card completion wrappers and the shortened-message regression are retained. No production logic or test assertion was manually changed.Why
Reuse scoped host readers, existing grants, gesture components and the conversation overlay instead of opening arbitrary paths or adding another viewer. Extending the existing parser keeps Markdown and attachment extraction consistent.
Linked Issue
Fixes #29632
Visual Proof
Earlier actual mobile-web captures with controlled images are historical evidence; this source merge has no fresh rendered UI run.
Later assistant-image captures remain local; the previous upload returned HTTP 404, so they are not presented as attached.
Testing
This head normally merges upstream
220d56f4e4c192b3b37de870a7996e449eaa39f7. Main relocatedfilesystem-authunderipc/filesystem; the sole manual edit updates the existing attachment-grant test'svi.mocktarget accordingly. Its two tests already passed before this edit, so this is a stale-mock compatibility correction, not a reproduced runtime regression. No production logic, assertion, timeout, rule, exclusion or baseline was manually changed.Fresh validation on the committed tree: all four root typechecks; mobile application/test typechecks and lint; shared-dependency and test-runner checks; attachment/provenance/grant/RPC tests (32 passed in 4 inventoried files). Full mobile tests: 11,368 passed, 6 skipped and zero failed across 1,120 file results. Actual frozen root/mobile installs and normal commit hooks passed. Tested tree
608fdff4ddd3b41e3aab8ecb6efc81c069ed4cfaexactly matches the commit tree. Counts overlap.Required
pnpm check:changed --base=220d56f4e4c192b3b37de870a7996e449eaa39f7 --maxWorkers=2ran on the committed 67-file PR diff: 26 of 27 checks passed, including the selected unit-test check. The flaky-test ratchet still failed withENOBUFSbecause that subcheck independently diffs the fork's ancientorigin/main. The complete local gate therefore remains failed. No gate or baseline was changed, and the exact-head required GitHub workflow remains necessary before readiness.All tests used background launch. No fresh rendered Electron, physical-phone, Windows-machine or live-SSH validation was performed; installed delivery, profiles and services remain unchanged.
AI Disclosure
Implemented and verified with OpenAI Codex.
Review
Please check host/session ownership, user versus assistant authorization, literal Markdown references and conversation-scoped gallery lifetime. Exact-head bot review and the full required PR workflow remain separate from local validation.
Agent skill upstream boundary
Checklist