Repository navigation
Workspace files: document name, icon and color; share the pickable icons - #350381
Merged
Sandeep Somavarapu (sandy081) merged 2 commits intoNov 25, 2026
Merged
Sandeep Somavarapu (sandy081) merged 2 commits into
Sandeep Somavarapu (sandy081) merged 2 commits into
Conversation
The `.code-workspace` schema documents general top-level `name`, `icon` (a product icon id) and `color` (a theme color id or #RRGGBB) properties, so workspace files that carry them validate and complete. The icons the shared icon picker offers are available as getPickableIcons(), for pickers that embed their own icon box. The icon picker's behaviour is unchanged. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The workspace file schema lists the icon and color ids of their registries, so it is refreshed whenever their schemas change, keeping completions and validation of workspace files current. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues block approval of the workspace metadata and shared icon-picker changes.
No open issues 🎉
What changed in this PR
Adds optional workspace display metadata to the .code-workspace schema and exposes the shared icon picker’s existing icon selection logic for reuse. The Agents window is the first consumer; standard VS Code workspace presentation remains unchanged.
Changes:
- Documents
name,icon, andcolor, with registry-backed IDs and six-digit hex color support. - Refreshes workspace schema notifications when icon or color schemas change.
- Extracts
getPickableIcons()without changing picker behavior and adds focused regression tests.
| File | Description |
|---|---|
src/vs/workbench/services/userDataProfile/test/browser/iconPicker.test.ts |
Tests dynamic icon registration and filtering. |
src/vs/workbench/services/userDataProfile/browser/iconPicker.ts |
Exports and reuses getPickableIcons(). |
src/vs/workbench/api/test/common/configurationExtensionPoint.test.ts |
Tests schema refresh notifications and newly registered IDs. |
src/vs/workbench/api/common/configurationExtensionPoint.ts |
Adds workspace metadata properties and schema refresh notifications. |
Review effort: Balanced
Sandeep Somavarapu (sandy081)
marked this pull request as ready for review
November 25, 2026 14:54
Henning Dieterichs (hediet)
approved these changes
Nov 25, 2026
Dirk Bäumer (dbaeumer)
approved these changes
Nov 25, 2026
Sandeep Somavarapu (sandy081)
deleted the
sandy081/agents/workspaces-02-workspace-file-schema
branch
November 25, 2026 15:12
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
.code-workspaceschema documents three general, optional top-level properties, so workspace files that carry them validate and get completions:name: the display name of the workspace.icon: a product icon id, for examplerocket.color: a theme color id, or a color in the#RRGGBBformat.The Agents window is the first reader of these properties (workspaces with several folders); VS Code itself doesn't use them yet.
The icon and color ids come from their registries. The workspace schema is refreshed whenever the icon or color schema changes, so completions and validation stay current as icons and colors are registered.
The icons the shared icon picker offers are now available as
getPickableIcons(), for pickers that embed their own icon box. The icon picker's behaviour is unchanged, and so is the profiles editor, which keeps its own icon list.How to test
.code-workspacefile and add"name": "App","icon": "rocket"and"color": "charts.blue"at the top level: there's no "Unknown workspace configuration property" warning, andiconandcolorcomplete their ids."color": "#12AB9F": valid. Set"color": "blue": a warning.Tests:
./scripts/test.sh --run src/vs/workbench/api/test/common/configurationExtensionPoint.test.ts --run src/vs/workbench/services/userDataProfile/test/browser/iconPicker.test.ts: 17 passing. The new schema test fails without the refresh.pnpm run typecheck-client,pnpm run valid-layers-checkandoxlintpass.Written by GitHub Copilot on behalf of Sandeep Somavarapu (@sandy081)