Skip to content

fix(settings): permission menus match the chat permission picker - #36104

Merged
brennanb2025 merged 4 commits into
mainfrom
brennanb2025/permission-menu-chat-style
Oct 29, 2026
Merged

brennanb2025 merged 4 commits into
mainfrom
brennanb2025/permission-menu-chat-style

Conversation

@brennanb2025

@brennanb2025 brennanb2025 commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor
Files Added Deleted Net
Test 2 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​233 $\color{#cf222e}{\Huge{\mathbf{−}}}$​45 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​188
Prod 19 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​264 $\color{#cf222e}{\Huge{\mathbf{−}}}$​174 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​90

Permission controls outside chat used several layouts, so the same choice looked different in Settings and Source Control.

All editable desktop permission menus now use the chat picker’s icons, descriptions, Full access warning colour and width. This includes per-agent Settings rows, Source Control actions, the “Agents without Approve for me” control, and the global/per-agent controls for older paired hosts. Own settings appears after a separator; mixed settings show “Mixed”.

Older paired hosts display the same permission names while retaining their existing manual/auto/yolo values and callbacks. Supported choices, disabled options, custom arguments, inheritance and save/failure behavior remain unchanged. Read-only summaries and exception shortcuts keep their existing roles; mobile keeps its native permission drawer.

Overlaps #34728, which moves the per-agent menu items; whichever lands second must carry both changes.

Validation: 145 tests passed across seven named renderer/persistence files, including both selections and a rejected save through the old and new secondary picker paths, older-host capability restrictions, keyboard access, existing saved-argument conversion, and Source Control save/discard. Mandatory pre-commit passed. Final CI and branch screenshots are recorded in the review-loop status comment.

The per-agent permission menu (Settings > Agents and Source Control actions)
and the 'Agents without Approve for me' toggle rendered their own plain-text
items. They now reuse the chat picker's items: the same icons, Full access
warning colour, per-agent descriptions and width, with the agent's own
settings after a separator.
@brennanb2025
brennanb2025 marked this pull request as ready for review October 29, 2026 22:00
@greptile-apps

greptile-apps Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The PR appears safe to merge; no actionable issues were found.

Summary

The PR makes settings permission menus look like the chat picker.

  • Agent permission menus show the chat picker’s icons and descriptions.
  • Agent permission settings use menus with clear names for each mode.

No actionable issues were found. Checks were based on source and test inspection; tests and visual checks were not run.

Reviews (1) · Last reviewed commit: "Merge main before final permission menu ..." · Reviewed by Greptile

@coderabbitai

coderabbitai Bot commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Walkthrough

Agent permission settings now use shared choice components and dropdown menus in place of segmented controls. The menus display mixed selections and offer choices based on Auto availability. Tests cover global and per-agent selections, unsupported choices, save failures, and retries. Search keywords and locale labels use updated permission names.

Priority: Low

Merge Risk: Low · up to 14aa4

The permission menu can show a setting that cannot be selected; normalize the displayed value before merging.

Pre-merge checks: Passed 3 · Failed 1 · Inconclusive 1

Failed Failed checks: 1 warning · 1 inconclusive

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 30.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documenta… Write docstrings for the functions missing them to satisfy the coverage threshold.
Description check Inconclusive The description covers the required sections of the template in substance. The ELI5 section is missing and the Linked Issue section is unfilled: 'Fixes #' has no issue number. The description referenc… Add an ELI5 section in plain language. Replace 'Fixes #' with a real linked issue number, or state why no issue applies. Attach before and after screenshots or a video of the permission menus directly in the PR description, not only in the …
Passed Passed checks: 3 passed
Check name Status Explanation
Title check Passed The title names the fix and its scope: the settings permission menus now match the chat permission picker. The raw summary shows the shared choice components, the mode menu, the removed local descript…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the fix and its scope: the settings permission menus now match the chat permission picker. The raw summary shows the shared choice components, the mode menu, the removed local description helper, and the i18n label changes. The title matches the main change. It uses the conventional fix(settings) prefix, is 64 characters, and avoids vague terms.

Full details: Docstring Coverage

Explanation

Docstring coverage is 30.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 10 functions across 9 files. (1 skipped: 1 unsupported.)

Resolution

Write docstrings for the functions missing them to satisfy the coverage threshold.

Full details: Description check

Explanation

The description covers the required sections of the template in substance. The ELI5 section is missing and the Linked Issue section is unfilled: 'Fixes #' has no issue number. The description references overlapping PR #34728 but does not link an issue. The Visual Proof section gives no before/after screenshots or video. It only points to a 'review-loop status comment' for screenshots, so the required before/after evidence is absent from the description itself. The Testing section lists 145 passing tests across seven files, but the checkboxes are not ticked. The AI Disclosure and Agent skill upstream boundary sections are not addressed. The What Changed and Why sections are present and reasonably clear. The description is mostly complete in its explanation but misses required items, so it does not clearly pass.

Resolution

Add an ELI5 section in plain language. Replace 'Fixes #' with a real linked issue number, or state why no issue applies. Attach before and after screenshots or a video of the permission menus directly in the PR description, not only in the status comment. Explain the reasoning behind the chosen approach in the Why section, and compare it to alternatives. Tick the completed Testing and checklist items, and state which platforms were tested. Complete the Agent skill upstream boundary and AI Disclosure sections as the template requires, or mark them not applicable.

Finishing Touches: 💡 1
📝 Generate docstrings: 💡
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to GitHub limitations.

⚠️ Outside diff range comments (1)

Minor · Normalize the shared choice before rendering the… · AgentPermissionChoiceControls.tsx:110-135

src/renderer/src/components/settings/AgentPermissionChoiceControls.tsx:110-135
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Normalize the shared choice before rendering the menu.

The global permission path can assign ask or accept-edits to all agents. withoutAutoChoice then contains that value, but this menu offers only full-access and own. The trigger therefore displays an option that the menu cannot select.

Suggested fix
+  const offeredWithoutAutoChoice =
+    withoutAutoChoice === 'full-access' || withoutAutoChoice === 'own'
+      ? withoutAutoChoice
+      : null;
+
-                  {withoutAutoChoice === null ? (
+                  {offeredWithoutAutoChoice === null ? (
...
-                      choice={withoutAutoChoice}
+                      choice={offeredWithoutAutoChoice}
...
-                  value={withoutAutoChoice ?? ''}
+                  value={offeredWithoutAutoChoice ?? ''}

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: 28d05e94-4159-455a-91d4-41e8746cf88a
Commits

Reviewing files that changed from the base of the PR and between 27e1da7 and 14aa40c.

Files selected for processing: 13
  • src/renderer/src/components/settings/HostAgentLaunchSettings.test.tsx
  • src/renderer/src/i18n/en-runtime-required.json
  • src/renderer/src/i18n/locales/de.json
  • src/renderer/src/i18n/locales/en.json
  • src/renderer/src/i18n/locales/es.json
  • src/renderer/src/i18n/locales/fr.json
  • src/renderer/src/i18n/locales/ja.json
  • src/renderer/src/i18n/locales/ko.json
  • src/renderer/src/i18n/locales/pt.json
  • src/renderer/src/i18n/locales/ru.json
  • src/renderer/src/i18n/locales/tr.json
  • src/renderer/src/i18n/locales/zh-Hant.json
  • src/renderer/src/i18n/locales/zh.json
Files with no reviewable changes: 12
  • src/renderer/src/i18n/en-runtime-required.json
  • src/renderer/src/i18n/locales/zh.json
  • src/renderer/src/i18n/locales/pt.json
  • src/renderer/src/i18n/locales/de.json
  • src/renderer/src/i18n/locales/zh-Hant.json
  • src/renderer/src/i18n/locales/fr.json
  • src/renderer/src/i18n/locales/ja.json
  • src/renderer/src/i18n/locales/ru.json
  • src/renderer/src/i18n/locales/tr.json
  • src/renderer/src/i18n/locales/en.json
  • src/renderer/src/i18n/locales/es.json
  • src/renderer/src/i18n/locales/ko.json

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 2 remain after this review.

@brennanb2025

Copy link
Copy Markdown
Contributor Author

Permission controls outside chats used several layouts, so the same choice looked different in Settings and Source Control. All editable desktop permission menus now reuse the chat picker’s icons, descriptions, Full access warning colour and menu width, including older paired hosts.

The review fixed the omitted older-host selectors and matching labels while preserving their manual/auto/yolo values, supported options, custom arguments and mutation callbacks. Two source-review rounds finished with no remaining findings; final architecture, performance/readiness and bounded CI-correction reviews passed. CI cleanup fixed a test type annotation and removed unused translation keys. No deferred code findings remain.

Verified 145 targeted tests across seven files; the two affected files (70 tests) passed again after CI cleanup. Final CI: PASS. Screenshot-only QA covered the live Settings all-agent, per-agent and non-Auto menus plus Source Control action menu. Older-host controls used production-component fixtures in both themes, as authorized; no real older paired host was provisioned. No agents or actions were executed. Real config hashes stayed unchanged; app and fixture server are stopped.

Screenshots are from 27e1da78bc1. Current reviewed head 14aa40ca3f3 adds only the checked test type and unused/generated catalog cleanup; those changes do not alter any rendered flow. The qa_head field carries that evidence. The one main merge was checked and left the reviewed permission implementation unchanged.

Intended differences: Settings keeps its outline triggers and existing Own/inheritance choices; legacy capabilities stay unchanged; read-only summaries, custom reset actions and the phone’s native drawer keep their existing roles.

For Brennan’s review

Settings: all agents

settings-global.png

Settings: per-agent inheritance

settings-agent.png

Settings: agents without Approve for me

settings-without-auto.png

Source Control action permissions

source-control-permission.png

Older paired host: global menu (fixture)

settings__Pr36104LegacyQa--globalAuto.dark.png

Older paired host: Other agents (fixture)

settings__Pr36104LegacyQa--others.dark.png

Older paired host: per-agent menu (fixture)

settings__Pr36104LegacyQa--perAgent.dark.png

@brennanb2025
brennanb2025 merged commit 019318b into main Oct 29, 2026
40 checks passed
@brennanb2025
brennanb2025 deleted the brennanb2025/permission-menu-chat-style branch October 29, 2026 22:38
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