Implement experimental mode and permissions picker integration - #334972
Draft
Justin Chen (justschen) wants to merge 5 commits into
Draft
Implement experimental mode and permissions picker integration#334972Justin Chen (justschen) wants to merge 5 commits into
Justin Chen (justschen) wants to merge 5 commits into
Conversation
Contributor
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
The combined picker has unresolved keyboard-focus, ARIA-state, and duplicate focus-restoration issues.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Review tier: Balanced
Findings: 3
New issues introduced by this change (3)
| Severity | Finding |
|---|---|
src/vs/sessions/contrib/providers/agentHost/browser/agentHostModePicker.ts — In the Agents window, PickerActionViewItem.focus() always focuses the element returned by… |
|
src/vs/sessions/contrib/providers/copilotChatSessions/browser/permissionPicker.ts — These rich-submenu actions call _selectItem, which hides the action widget before returning. The… |
|
src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostChatInputPicker.ts — The submenu action calls _selectItem, whose first step hides the action widget.… |
What changed in this PR
Adds an experimental combined mode and permissions picker for Copilot Agent Host sessions.
Changes:
- Combines mode and permission controls with a permissions flyout and settings action.
- Extends Action Widget with rich submenu support.
- Adds accessibility guidance, styling, fixtures, and tests.
| File | Description |
|---|---|
permissionPickerList.fixture.ts |
Updates sandbox icon fixture. |
terminalContribExports.ts |
Exports additional permission settings. |
agentHostChatInputPicker.test.ts |
Tests the combined editor picker. |
constants.ts |
Defines the feature setting. |
permissionPickerActionItem.ts |
Uses the shield sandbox icon. |
chat.shared.contribution.ts |
Registers the experimental setting. |
agentHostModePicker.css |
Styles the combined control and flyout. |
agentHostModePickerPresentation.ts |
Adds shared presentation helpers. |
agentHostChatInputPicker.ts |
Integrates the combined editor picker. |
chatAccessibilityHelp.ts |
Documents picker keyboard usage. |
permissionPicker.ts |
Exposes permission submenu items. |
agentHostModePicker.test.ts |
Tests the Agents-window integration. |
agentHostModePicker.fixture.ts |
Adds visual fixtures. |
agentHostPermissionPickerDelegate.test.ts |
Updates test dependencies. |
mobileAgentHostModePicker.ts |
Forwards new picker dependencies/options. |
agentHostPermissionPickerDelegate.ts |
Adds combined-picker gating. |
agentHostModePicker.ts |
Implements the combined Agents-window picker. |
sessionsChatAccessibilityHelp.ts |
Adds combined-picker help. |
actionList.test.ts |
Tests rich submenu behavior. |
actionWidget.ts |
Supports dynamic submenu anchoring. |
actionList.ts |
Implements rich action-list submenus. |
Suppressed comments (1)
src/vs/sessions/contrib/providers/agentHost/browser/agentHostModePicker.ts:374
- When the experimental setting or phone layout switches this existing trigger from combined back to the normal button,
renderModePickerTriggerhas already removedaria-expanded. This branch restores the role and popup type but not the collapsed state, leaving an unopened popup button withoutaria-expanded="false". Restore that attribute here as the base render path does.
trigger.classList.remove('agent-host-mode-permissions-trigger');
trigger.role = 'button';
trigger.tabIndex = 0;
trigger.ariaHasPopup = 'listbox';
super._renderTriggerLabel(trigger, label, icon);
💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Justin Chen (justschen)
force-pushed
the
agents/experimental-mode-permissions-picker
branch
from
September 8, 2026 06:04
9b95b5c to
374d4cc
Compare
Contributor
Screenshot ChangesBase: Changed (132)3 insignificant change(s) omitted (≤20 px, Δ≤2). See CI logs for details. Added (24) |
Replace the permissions flyout with inline expansion and independent mode and permission highlights. Preserve keyboard focus, use the available menu height, and align composer control sizing and spacing. Enable the experiment by default in non-Stable builds while preserving explicit user overrides. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Exercise pointer movement before hover assertions and inherit the shared chat control height in compact-picker coverage after rebasing onto main. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Justin Chen (justschen)
force-pushed
the
agents/experimental-mode-permissions-picker
branch
from
September 9, 2026 04:23
b1fa9b2 to
7ec2436
Compare
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

This pull request implements a new experimental mode and permissions picker for the agent host, inspired by the recent model picker design. Key changes include:
The changes are gated behind the
chat.experimentalModePermissionsPickersetting and are currently limited to the Copilot agent host. All modifications have been verified with extensive testing, ensuring functionality across different themes and environments.