[cherry-pick] Add unread treatment for Automations new badge - #334971
Conversation
* automations: feat: add unread new badge treatment Reuse the standard Automations unread status indicator as an alternative first-use treatment while preserving operational status precedence and accessibility semantics. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * automations: test: gate unread badge screenshots Opt the unread Automations badge fixture into the blocking screenshot gate so theme and rendering regressions are detected. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * automations: test: accept unread badge screenshots Record the Linux CI hashes for the unread Automations badge in dark, high-contrast, and light themes. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> (cherry picked from commit 1b921e3)
There was a problem hiding this comment.
Copilot review overview
🟢 Approval recommended
The change is narrowly scoped, updates UI + configuration + fixtures/tests consistently, and preserves existing accessibility labeling behavior via the existing automationNewBadgeVisible aria-label augmentation.
Review tier: Lite
Findings: None
What changed in this PR
Cherry-picks the “unread” visual treatment for the Automations New badge onto release/1.137, adding a fourth badge style that reuses the standard filled unread indicator in the Automations leading icon slot while suppressing the trailing New capsule. This integrates into the existing Sessions list rendering, configuration schema, component fixtures, and unit tests without altering the underlying Automations eligibility logic (already backported separately).
Changes:
- Add
unreadas a supportedAutomationsNewBadgeStyleand configuration enum value. - Update Sessions list rendering so the Automations row hides the trailing New capsule for
unreadand shows the filled unread indicator in the leading icon slot. - Extend component screenshot fixtures and unit tests to cover the new
unreadtreatment and its precedence behavior.
| File | Description |
|---|---|
| test/componentFixtures/blocks-ci-screenshots.md | Adds new baseline screenshot entries for the unread Automations badge treatment across themes. |
| src/vs/workbench/test/browser/componentFixtures/sessions/sessionsList.fixture.ts | Updates fixture status-icon behavior and adds a new screenshot fixture for automationBadgeStyle: 'unread'. |
| src/vs/sessions/contrib/sessions/test/browser/sessionsList.test.ts | Expands coverage to assert DOM/icon behavior for outline vs unread badge presentations and precedence with running status. |
| src/vs/sessions/contrib/sessions/test/browser/automationsNewBadge.test.ts | Extends AutomationsNewBadgeState tests to include the new unread style in supported-style resolution and updates related expectations. |
| src/vs/sessions/contrib/sessions/browser/views/sessionsList.ts | Implements the unread presentation: hides trailing badge capsule and renders unread indicator in the leading icon slot while preserving status precedence. |
| src/vs/sessions/contrib/sessions/browser/sessions.contribution.ts | Adds 'unread' to the sessions.automations.newBadgeStyle enum list. |
| src/vs/sessions/contrib/sessions/browser/automationsNewBadge.ts | Extends AutomationsNewBadgeStyle union and treatment parsing to accept 'unread'. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Screenshot ChangesBase: 5 insignificant change(s) omitted (≤20 px, Δ≤2). See CI logs for details. Added (3) |
Cherry-pick of #334946 from
mainontorelease/1.137.The release branch already includes the prerequisite Automations New badge eligibility backport from #334944.
Verification
npm run transpile-clientA full compile reaches source generation but is currently blocked by the pre-existing
release/1.137monaco.d.tsmismatch; this cherry-pick does not modify Monaco sources or declarations.