Repository navigation
Changes editor: changed files list, opt-in by its host - #345658
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Hiding the file list removes Focus File List from the Command Palette, while auxiliary Changes-editor windows lack a Toggle Files action, leaving key file-list controls unavailable.
2 open issues
What changed in this PR
Adds the shared multi-diff changed-files list to the Agents window’s Changes editor, reusing workbench controls and persisted visibility preferences.
Changes:
- Hosts the file-list widget independently of the experimental workbench setting.
- Adds Toggle Files to the tab bar’s More Actions menu.
- Generalizes file-list focus and accessibility help to supported editor hosts, with related tests.
| File | Description |
|---|---|
src/vs/workbench/contrib/multiDiffEditor/test/browser/multiDiffEditorWithFileList.test.ts |
Tests host-based focus and shared visibility state. |
src/vs/workbench/contrib/multiDiffEditor/common/multiDiffEditor.ts |
Exposes shared hidden-state observation, command ID, and host contract. |
src/vs/workbench/contrib/multiDiffEditor/browser/multiDiffEditorAccessibilityHelp.ts |
Adapts accessibility help to different file-list hosts. |
src/vs/workbench/contrib/multiDiffEditor/browser/actions.ts |
Generalizes Focus File List and reuses the toggle command constant. |
src/vs/sessions/contrib/changes/test/browser/sessionChangesEditor.test.ts |
Tests file-list visibility, focus, and layout delegation. |
src/vs/sessions/contrib/changes/test/browser/changesViewActions.test.ts |
Tests Toggle Files menu placement and visibility conditions. |
src/vs/sessions/contrib/changes/browser/sessionChangesEditor.ts |
Integrates the shared file-list widget and context keys. |
src/vs/sessions/contrib/changes/browser/changesViewActions.ts |
Adds the shared toggle command to the Changes tab menu. |
Review effort: Balanced
Sandeep Somavarapu (sandy081)
added a commit
that referenced
this pull request
Nov 2, 2026
The Changes editor of the Agents window shows its diffs without the list of the changed files that the workbench's multi diff editor can show beside them. It now hosts the workbench's changed files list beside its diffs, in every window it shows in. The list shows unless the user hides it with Toggle Files in the More Actions menu of the tab bar, which hides it in every multi diff editor and is remembered; it does not depend on the experimental file list setting of the multi diff editor. Focus File List, and the accessibility help of the list, apply to any editor that hosts the list. Stacked from #345658 (unmerged). On this base the Changes editor's UI element factory also takes the editor's session scope. Co-authored-by: Copilot <[email protected]>
Sandeep Somavarapu (sandy081)
added a commit
that referenced
this pull request
Nov 3, 2026
The Changes editor of the Agents window shows its diffs without the list of the changed files that the workbench's multi diff editor can show beside them. It now hosts the workbench's changed files list beside its diffs, in every window it shows in. The list shows unless the user hides it with Toggle Files in the More Actions menu of the tab bar, which hides it in every multi diff editor and is remembered; it does not depend on the experimental file list setting of the multi diff editor. Focus File List, and the accessibility help of the list, apply to any editor that hosts the list. Stacked from #345658 (unmerged). On this base the Changes editor's UI element factory also takes the editor's session scope. Co-authored-by: Copilot <[email protected]>
Sandeep Somavarapu (sandy081)
added a commit
that referenced
this pull request
Nov 3, 2026
The Changes editor of the Agents window shows its diffs without the list of the changed files that the workbench's multi diff editor can show beside them. It now hosts the workbench's changed files list beside its diffs, in every window it shows in. The list shows unless the user hides it with Toggle Files in the More Actions menu of the tab bar, which hides it in every multi diff editor and is remembered; it does not depend on the experimental file list setting of the multi diff editor. Focus File List, and the accessibility help of the list, apply to any editor that hosts the list. Stacked from #345658 (unmerged). On this base the Changes editor's UI element factory also takes the editor's session scope. Co-authored-by: Copilot <[email protected]>
The Changes editor of the Agents window shows its diffs without the list of the changed files that the workbench's multi diff editor can show beside them. It now hosts the workbench's changed files list beside its diffs, in every window it shows in. The list shows unless the user hides it with Toggle Files in the More Actions menu of the tab bar, which hides it in every multi diff editor and is remembered; it does not depend on the experimental file list setting of the multi diff editor. Focus File List, and the accessibility help of the list, apply to any editor that hosts the list. Co-authored-by: Copilot <[email protected]>
… enables it The changed files list of the Changes editor is now opt-in: it shows only when its host sets the sessionChangesEditorFileList context key (SessionChangesEditorFileListContext) in its scoped context key service, such as the one of an editor part or editor group. It is off by default, so the main Agents window shows the Changes editor without the list, as before. Toggle Files and Focus File List only apply while the list is enabled. While the list shows, a border under the header row joins the separator of the list in one line. Co-authored-by: Copilot <[email protected]>
Run Code Review, a More Actions menu with the diff actions (Collapse/Expand All, Word Wrap, Diff View, Files View) and, behind a separator, Toggle Files where the host enables the changed files list, move from the tab row to the right of the header row above the diffs, through a new SessionsEditorHeaderSecondary menu. Co-authored-by: Copilot <[email protected]>
The first diff card of the Changes editor dropped its top margin, so it sat flush under the header row. It now keeps the margin of the cards below it, the same var(--vscode-spacing-size40) gap the multi-diff editor puts between cards. Co-authored-by: Copilot <[email protected]>
While the changed files list shows, the line under the header covered the top row of the gap above the first diff card. It now sits on the header's last row, so that gap matches the gap between cards. Co-authored-by: Copilot <[email protected]>
Sandeep Somavarapu (sandy081)
force-pushed
the
agents/changes-file-list
branch
from
November 3, 2026 22:18
119e029 to
85cbf3e
Compare
Sandeep Somavarapu (sandy081)
marked this pull request as ready for review
November 3, 2026 23:13
Focus File List now requires an editor that supports the changed files list instead of a visible list, so it stays in the Command Palette after Toggle Files hides the list, and the multi diff editor shows the list before focusing it, like the Changes editor. Co-authored-by: Copilot <[email protected]>
Sandeep Somavarapu (sandy081)
enabled auto-merge
November 3, 2026 23:38
Sandeep Somavarapu (sandy081)
disabled auto-merge
November 3, 2026 23:38
Sandeep Somavarapu (sandy081)
enabled auto-merge (squash)
November 3, 2026 23:38
Aaron Munger (amunger)
approved these changes
Nov 4, 2026
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.

The Changes editor of the Agents window can show the list of the changed files beside its diffs, as the workbench's multi diff editor can. The list is opt-in by its host and off by default, so the main Agents window keeps showing the Changes editor without it, as before.
SessionChangesEditorFileListContext(context keysessionChangesEditorFileList, defaultfalse), insrc/vs/sessions/contrib/changes/common/changes.ts. A host enables the list for the Changes editors it shows by setting the key in its own scoped context key service, which the editors inherit. This can be an editor part (a window, such as an auxiliary window) or a single editor group:SessionChangesEditorFileListContext.bindTo(scopedContextKeyService).set(true). The host does not need to import any Changes-editor code, and the Changes editor does not know about any host. The chat windows (chat windows: chat windows of the Agents window on parts, with drag and drop between parts #345683) will turn it on.MultiDiffEditorWithFileListWidget. The list shows unless the user hides it with Toggle Files. Hiding is remembered and shared with the multi diff editors. The list doesn't depend on the experimentalmultiDiffEditor.experimental.fileListsetting, which still gates the list of the workbench's multi diff editor.multiDiffEditor.toggleFileList, in the More Actions menu of the tab bar, after Collapse All Diffs, Word Wrap and Diff View. It only appears while the list is enabled. Focus File List is enabled only while the list is visible. Focus File List and the list's accessibility help apply to any editor that hosts the list (IMultiDiffEditorFileListHost).With the option off (the main Agents window), nothing visible changes.
Screenshots
Before and in the main Agents window: the Changes editor shows only the diffs.
With a host enabling the option: the changed files list shows beside the diffs. The border under the header row joins the list's separator.
(Screenshots: to be attached with #345683, which is the first host to enable the option.)
How to test
sessionChangesEditorFileList(the chat windows of chat windows: chat windows of the Agents window on parts, with drag and drop between parts #345683), open the Changes editor. The list shows beside the diffs, and a single line runs under the header row into the list's left border.Validation
SessionChangesEditor changed files list: uses a real host context key service and the real list widget. Off by default: no list, no header border, and Focus File List does nothing. When the host enables the key, the list shows and the header border is 1px in the list's border color at the top of the body. Toggle Files hides the list, Focus File List shows it again, and the list goes away when the host turns the key off.Changes View Actions: Toggle Files only appears when the list is available.Multi diff editor file list of any host: Focus File List focuses any host. The hidden state doesn't depend on the setting../scripts/test.sh --reporter dot --runGlob "vs/{sessions/contrib/changes,workbench/contrib/multiDiffEditor}/**/*.test.js"(Electron): 268 passing.node test/unit/browser/index.js --runGlob "**/sessions/contrib/changes/test/browser/{sessionChangesEditor,changesViewActions}.test.js" --browser chromium: 33 passing.pnpm run typecheck-client: passed (exit code 0).pnpm run eslint <changed .ts files>: passed.node build/hygiene.ts <changed files>: passed.