Skip to content

sessions: add dynamic codicon chat backgrounds - #332660

Merged
TylerLeonhardt merged 5 commits into
mainfrom
tyler/agents-chat-codicons-background
Aug 26, 2026
Merged

sessions: add dynamic codicon chat backgrounds#332660
TylerLeonhardt merged 5 commits into
mainfrom
tyler/agents-chat-codicons-background

Conversation

@TylerLeonhardt

Copy link
Copy Markdown
Member

Summary

  • add a responsive, theme-aware Codicons chat background preset generated from the existing in-memory Codicon font
  • reconcile Set Background..., Clear Background, and Change Background Layout... across preset and image backgrounds
  • preview image layouts while navigating the picker, committing on completion and restoring the configured layout on cancellation or save failure
  • keep up to five machine-local recently used images for quick reuse
  • preserve accessibility by keeping the decorative layer inert and suppressing backgrounds in high-contrast themes

Testing

  • npm run compile
  • npm run typecheck-client
  • .\scripts\test.bat src\vs\sessions\contrib\chat\test\browser\chatView.test.ts src\vs\sessions\services\chatBackground\test\browser\chatBackgroundService.test.ts (25 passing)
  • node --experimental-strip-types build\hygiene.ts <all 9 changed files>
  • git diff --check origin/main...HEAD
  • manually exercised new-chat and active-chat views in Code OSS across light, dark, and high-contrast themes; verified command visibility, responsive Codicon regeneration, layout preview/rollback, and recent-image persistence

Reviewer note

The full npm run hygiene wrapper currently fails in this Windows checkout before source checks because it resolves paths with a duplicated C:\C:\... prefix. Running build\hygiene.ts directly against every changed file passes.

TylerLeonhardt and others added 2 commits August 25, 2026 16:19
Add a theme-aware in-memory Codicons preset alongside image backgrounds. Reconcile Set/Clear/Layout commands across background types, add live layout previews with commit-on-close behavior, and retain a five-image machine-local MRU for quick reuse.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Roll back transient layout state to the configured value when the settings write fails, so an unsaved preview cannot remain active.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI balanced review requested due to automatic review settings August 25, 2026 23:45
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot AI 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.

Pull request overview

Adds configurable, theme-aware Codicon and recent-image backgrounds to Sessions chat.

Changes:

  • Adds responsive decorative Codicon rendering.
  • Adds background presets, recent images, and layout previews.
  • Updates commands, accessibility help, styling, and tests.
Show a summary per file
File Description
contextkeys.ts Adds configured-background context.
chatBackgroundService.ts Manages presets, layouts, and recents.
chatBackgroundService.test.ts Tests new service behavior.
chatBackgroundRenderer.ts Renders image and Codicon backgrounds.
chatView.ts Integrates the renderer.
chatView.css Styles background layers and content.
chat.contribution.ts Updates commands and settings.
sessionsChatAccessibilityHelp.ts Documents accessible background controls.
chatView.test.ts Tests renderer behavior and styling.

Review details

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

  • Files reviewed: 9/9 changed files
  • Comments generated: 1
  • Review effort level: Balanced

Comment thread src/vs/sessions/contrib/chat/browser/chat.contribution.ts Outdated
TylerLeonhardt and others added 2 commits August 25, 2026 19:08
Restore an in-memory layout preview without writing configuration when the picker is cancelled or rejects.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Use one union-typed service method for both image and built-in background selections while preserving image-only recent history behavior.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@TylerLeonhardt
TylerLeonhardt marked this pull request as ready for review August 26, 2026 02:26

@justschen Justin Chen (justschen) left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

developer joy

@TylerLeonhardt
TylerLeonhardt enabled auto-merge (squash) August 26, 2026 03:26
@TylerLeonhardt
TylerLeonhardt merged commit 2d2c0c5 into main Aug 26, 2026
37 checks passed
@TylerLeonhardt
TylerLeonhardt deleted the tyler/agents-chat-codicons-background branch August 26, 2026 07:26
@vs-code-engineering vs-code-engineering Bot added this to the 1.136.0 milestone Aug 26, 2026
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.

4 participants