Repository navigation
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:
Walkthrough
Merge Risk:
|
There was a problem hiding this comment.
Actionable comments posted: 1

Review info
-
Run configuration-
- Source mode: Auto
- Repository: Unavailable
- Branch: Unavailable
- File: No configuration file from this repository applied
- Commit: Unavailable
- Layers: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
d720cf9a-dd3d-4682-93d9-0e9eceacedbd
Files selected for processing: 26-
mobile/src/session/MobileNativeChatAutoApprovalNotice.tsxmobile/src/session/MobileNativeChatMessage.tsxmobile/src/session/MobileNativeChatMessage.work-run.test.tsxmobile/src/session/MobileNativeChatNoticeRow.tsxmobile/src/session/MobileNativeChatToolRun.tsxmobile/src/session/MobileNativeChatToolRunMembers.tsxsrc/renderer/src/components/native-chat/NativeChatAssistantMessageRow.tsxsrc/renderer/src/components/native-chat/NativeChatAutoApprovalNotice.tsxsrc/renderer/src/components/native-chat/NativeChatMessageRow.tsxsrc/renderer/src/components/native-chat/NativeChatMessageRow.work-run.test.tsxsrc/renderer/src/components/native-chat/NativeChatNoticeRow.auto-approval.test.tsxsrc/renderer/src/components/native-chat/NativeChatNoticeRow.tsxsrc/renderer/src/components/native-chat/NativeChatToolRun.appearance.test.tsxsrc/renderer/src/components/native-chat/NativeChatToolRun.test.tsxsrc/renderer/src/components/native-chat/NativeChatToolRun.tsxsrc/renderer/src/components/native-chat/NativeChatToolRunFailures.tsxsrc/renderer/src/components/native-chat/native-chat-transcript-work-runs.test.tssrc/renderer/src/components/native-chat/use-native-chat-work-run.tsxsrc/renderer/src/components/ui/collapsible.tsxsrc/renderer/src/i18n/locales/en.jsonsrc/shared/native-chat-activity.test-fixture.tssrc/shared/native-chat-auto-approval.tssrc/shared/native-chat-notice.tssrc/shared/native-chat-tool-failures.tssrc/shared/native-chat-work-run.test.tssrc/shared/native-chat-work-run.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 3 remain after this review.
-
There was a problem hiding this comment.
🔇 Additional comments: 1
src/renderer/src/components/native-chat/NativeChatAutoApprovalNotice.tsx: 1
13-30:Trivial · Maintainability & Code Quality · Low value
⚠️ Unverified finding
Verification ran but could not confirm this finding. It is shown for review, not as a verified issue.Reuse
NATIVE_CHAT_NOTICE_COPYfor the English fallbacks.The mobile notice reads the outcome labels from
NATIVE_CHAT_NOTICE_COPY(autoApprovalGranted,autoApprovalRejected,autoApprovalDenied,autoApprovalTimedOut,safetyCheckDenied). This file repeats the same strings as literals.NativeChatErrorNotice.tsxalready passesNATIVE_CHAT_NOTICE_COPY.agentErroras its fallback. If the two copies drift, desktop and mobile show different wording.Use the shared constants as the fallbacks.
♻️ Proposed refactor
+import { NATIVE_CHAT_NOTICE_COPY } from '../../../../shared/native-chat-notice' @@ const OUTCOME_LABEL: Record<NativeChatAutoApprovalOutcome, () => string> = { approved: () => - translate('components.native-chat.notices.autoApprovalGranted', 'Automatic approval granted'), + translate( + 'components.native-chat.notices.autoApprovalGranted', + NATIVE_CHAT_NOTICE_COPY.autoApprovalGranted + ), rejected: () => - translate('components.native-chat.notices.autoApprovalRejected', 'Automatic approval rejected'), + translate( + 'components.native-chat.notices.autoApprovalRejected', + NATIVE_CHAT_NOTICE_COPY.autoApprovalRejected + ), denied: () => - translate('components.native-chat.notices.autoApprovalDenied', 'Automatic approval denied'), + translate( + 'components.native-chat.notices.autoApprovalDenied', + NATIVE_CHAT_NOTICE_COPY.autoApprovalDenied + ), 'timed-out': () => translate( 'components.native-chat.notices.autoApprovalTimedOut', - 'Automatic approval timed out' + NATIVE_CHAT_NOTICE_COPY.autoApprovalTimedOut ), 'safety-denied': () => translate( 'components.native-chat.notices.safetyCheckDenied', - 'Permission denied by safety check' + NATIVE_CHAT_NOTICE_COPY.safetyCheckDenied ) }As per coding guidelines: "Before writing new logic at any scale ... check whether an existing implementation already does the job. Extend or generalize it instead of building a parallel version."
Source: Coding guidelines

Review info
-
Run configuration-
- Source mode: Auto
- Repository: Unavailable
- Branch: Unavailable
- File: No configuration file from this repository applied
- Commit: Unavailable
- Layers: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
051e7a00-6ae5-467e-a8ca-23a8f28f252d
Files selected for processing: 22-
mobile/src/session/MobileNativeChatAutoApprovalNotice.tsxmobile/src/session/MobileNativeChatErrorNotice.tsxmobile/src/session/MobileNativeChatMessage.test.tsmobile/src/session/MobileNativeChatMessage.work-run.test.tsxmobile/src/session/MobileNativeChatNoticeRow.tsxmobile/src/session/MobileNativeChatToolRun.test.tsxmobile/src/session/MobileNativeChatToolRun.tsxmobile/src/session/mobile-native-chat-message-render-mocks.test-fixture.tssrc/renderer/src/components/native-chat/NativeChatAutoApprovalNotice.tsxsrc/renderer/src/components/native-chat/NativeChatErrorNotice.tsxsrc/renderer/src/components/native-chat/NativeChatMessageRow.work-run.test.tsxsrc/renderer/src/components/native-chat/NativeChatNoticeRow.auto-approval.test.tsxsrc/renderer/src/components/native-chat/NativeChatNoticeRow.test.tsxsrc/renderer/src/components/native-chat/NativeChatNoticeRow.tsxsrc/renderer/src/components/native-chat/NativeChatToolRun.test.tsxsrc/renderer/src/components/native-chat/NativeChatToolRun.tsxsrc/renderer/src/i18n/en-runtime-required.jsonsrc/renderer/src/i18n/locales/en.jsonsrc/shared/native-chat-activity.test-fixture.tssrc/shared/native-chat-auto-approval.tssrc/shared/native-chat-notice.tssrc/shared/native-chat-work-run.ts
Files skipped from review as they are similar to previous changes: 2-
- src/shared/native-chat-notice.ts
- src/renderer/src/i18n/locales/en.json
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 6 remain after this review.
-
e6009ab to
8756e37
Compare
[Medium impact] The PR appears safe to merge; no blocking issue was found. SummaryKeeps routine activity and completed permission notices compact on desktop and mobile.
No new actionable issues were found. Both earlier unnumbered findings are fixed. This review checked code and tests; it did not run tests or capture the UI.
|
…views with routine activity
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
On current main MobileNativeChatMessage.tsx sits at the 400-line limit, and the longer work-run condition broke the drawn-prose ternary over one more line. The task-row filter is now its own constant and the system check is read once before it, so the condition stays on one line. Behavior is unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ELI5
When Codex's automatic approval reviewer approves a step, Orca adds a separate notice row ("Automatic approval review approved …"). These rows split the folded tool activity into several pieces and repeat routine text while you read. Now an approved review goes inside the same folded activity group as the tools around it, and opening the group shows it. Rejections, denials, errors and approvals that still need you stay visible as before.
What Changed
src/shared/native-chat-successful-review.tsclassifies a system message as an approved review: Codexnotification:warningornotification:guardianWarningframe, warning tone, no failure or stop marker, and text startingAutomatic approval review approved (…): ….src/shared/native-chat/native-chat-work-run.tsadds anoticerun member.nativeChatWorkRunEntriesnow returnsasidesBefore/asidesAfter(previously thoughts only).use-native-chat-work-run.tsxrenders notice asides, andNativeChatToolRun.tsxgets the "Activity" fallback label.NativeChatMessageRow.tsxandNativeChatAssistantMessageRow.tsxstop drawing a notice separately when it heads a run.MobileNativeChatMessage.tsx,MobileNativeChatNoticeRow.tsx(newdisclosedprop) andMobileNativeChatToolRun.tsx.Why
Routine approvals interrupt reading, but their text should stay available, and anything unsuccessful or actionable must stay visible. The work-run projection already groups thoughts and tool calls on desktop and mobile. Adding one narrowly classified member reuses its ordering, disclosure state and header instead of adding a second grouping mechanism. Classification is client-side over existing records, so there is no new wire field, capability or journal change.
Linked Issue
Fixes #36590
Refs #33357 (umbrella tracker; not closed by this PR).
Visual Proof
Production desktop component fixtures render identical synthetic records through the same transcript projection. Before is upstream
main, after is this branch. These are not live-provider or phone captures. The images are stored on a separate evidence branch, not in this PR's diff.Dark collapsed before, dark collapsed after, dark expanded before, dark expanded after, source/image manifest.
Reproduce:
pnpm fixtures:shot native-chat/NativeChatSuccessfulReviewActivity --theme both.Phone captures (a review notice between two tool calls, folded and opened) are pending; the phone uses the same grouping rule.
Testing
src/shared/native-chat/native-chat-work-run.test.tscovers which notices join (approved only; rejected, denied, timed-out, empty-reason and quoted text do not) and the order of asides around a call.src/renderer/src/components/native-chat/NativeChatMessageRow.work-run.test.tsxcovers review-first and tool-first runs collapsing into one row and reviews before any tool getting an Activity header.Risk
Level: Medium
The classifier relies on Codex's English sentence for approved reviews. If Codex changes that wording, approved reviews go back to separate rows; nothing is hidden. A false match would put an approval inside a collapsed group, where it can still be opened. The tests pin the negative cases above. Older hosts and retained history work the same because classification runs on the client over existing records. A plain revert restores separate notice rows; nothing is persisted.
AI Disclosure
Implemented and checked with OpenAI Codex assistance. The contributor owns the change and its validation.
Review
Earlier CodeRabbit and Greptile threads were about mobile error and approval notice components from a broader earlier version of this PR. They were fixed and resolved. That presentation was later dropped from this PR because upstream #36304 delivered compact settled permission notices, so this PR now contains only the grouping.
Agent skill upstream boundary
Notes
Codex-only by construction (provider check). Same behavior for local and SSH hosts, and for folder workspaces and git worktrees. Desktop and mobile follow the same rule. No platform-specific code.
Checklist
pnpm lint,pnpm typecheck,pnpm testandpnpm buildpass (CI will cover; local scope stated above)