Skip to content

sessions: preserve recorded GitHub titles in pills - #335387

Merged
Cherry Wang (chryw) merged 8 commits into
mainfrom
chryw/issue-335383-issue-pill-title
Sep 10, 2026
Merged

sessions: preserve recorded GitHub titles in pills#335387
Cherry Wang (chryw) merged 8 commits into
mainfrom
chryw/issue-335383-issue-pill-title

Conversation

@chryw

@chryw Cherry Wang (chryw) commented Sep 10, 2026

Copy link
Copy Markdown
Contributor

Summary

  • preserve issue and pull-request artifact labels when Agent Host artifacts are promoted into dedicated GitHub pills
  • use live GitHub titles first, recorded titles while live data is unavailable, and number-only labels as the final fallback
  • include recorded titles in compact single-entry tooltips and accessible labels
  • keep Agents Window and regular editor/panel chat GitHub presentation consistent
  • align trailing dropdown actions across chat-pill surfaces without changing base ActionList spacing for unrelated rows

Fixes #335383

Testing

  • npm run compile — full client and Copilot extension compile, 0 source errors
  • targeted ESLint and stylelint across changed TypeScript and CSS
  • affected Agents Window and editor/panel pill suites — 18 passing
  • shared ChatPills and AgentHostSessionInputPills suites — 20 passing
  • broader affected suites — 278 passing, 11 pre-existing pending
  • focused issue and pull-request activation assertions — passing
  • local read-only code reviews — no unresolved findings
  • visual issue-title scenarios reviewed in dark and light themes: live fetch success, live fetch failure, short titles, and long-title truncation
  • interactive local Copilot validation completed with 2 Issues and 2 Pull Requests
  • live geometry validation: PR copy action trailing gap reduced from 22px to 0px; rows without toolbar actions retain base ActionList padding

Visual validation

The controlled Component Explorer harness renders the issue entries produced by the production pill path with production action-widget styling. The temporary screenshot harness was removed after capture, so it does not add test-only implementation code to this PR.

These screenshots are static captures, but the product rows are interactive action-list items rather than inline blue anchors. Clicking a row or accepting it from the keyboard invokes its issue or pull-request entry. Tests verify that the Agents Window dispatches the exact issue or pull-request context and editor/panel chat opens the exact GitHub issue or pull-request URL with openExternal: true; the existing issue and pull-request actions then use contributed openers when available or fall back to the external web URL.

Scenario Dark Light
Live GitHub title fetched — canonical title replaces the recorded fallback Fetched issue title, dark theme Fetched issue title, light theme
Live fetch unavailable — recorded artifact title remains visible Issue title fetch failed, dark theme Issue title fetch failed, light theme
Short titles Short issue titles, dark theme Short issue titles, light theme
Long titles — rows truncate without disturbing issue numbers or alignment Long issue titles, dark theme Long issue titles, light theme

Exact DOM assertions also cover compact issue and pull-request title-plus-URL tooltips, visible dropdown labels, accessible labels, URL descriptions, and activation targets.

Regular editor chat

The same restored Agent Host session displays recorded pull-request titles in regular editor chat. The shared ChatDropdownPillActionViewItem now scopes the Agents-style row alignment to chat-pill rows with toolbar actions; detail, inline-toggle, standalone-toggle, and no-toolbar rows preserve their base ActionList spacing.

Regular editor chat pull-request titles with trailing action aligned

Interactive validation

20260910-vscode-issue-pr-show-title.mp4

Accessibility validation

Tested in Screen Reader Optimized mode in both the Agents Window and regular editor chat. Using keyboard focus and Enter:

  • the summary pill announces Show 2 pull requests / Show 2 issues, with aria-haspopup=listbox and correct expanded state;
  • the popup exposes a named Pull Requests / Issues listbox;
  • every option announces its resource number and full title;
  • focused-row hover content exposes the exact GitHub URL as a navigable link in the accessibility tree;
  • copy actions announce Copy Pull Request URL / Copy Issue URL; and
  • Escape closes the popup and returns to the pill flow.

The same behavior was verified in both chat surfaces.

Cherry Wang (chryw) and others added 2 commits September 9, 2026 18:44
Use artifact labels as an immediate fallback until live GitHub issue details resolve, including accessible labels and compact-pill tooltips.

Fixes #335383

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Exercise the rendered label and accessible metadata directly, and remove the fixture that could not render production popovers.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI balanced review requested due to automatic review settings September 10, 2026 02:09

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.

🟢 Approval recommended

The title propagation and fallback behavior are consistent across both presentation paths and have focused regression coverage.

Pull request overview

Preserves recorded GitHub issue titles across Agents Window and workbench pill surfaces.

Changes:

  • Propagates recorded issue titles through artifact and session metadata.
  • Applies live-title, recorded-title, then number-only fallback ordering.
  • Adds rendering, accessibility, metadata, and equality regression coverage.
File summaries
File Description
src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostSessionInputPills.ts Renders recorded titles in workbench issue pills.
src/vs/workbench/contrib/chat/test/browser/agentHost/agentHostSessionInputPills.test.ts Tests metadata and rendered labels.
src/vs/sessions/services/sessions/common/session.ts Adds issue titles and equality handling.
src/vs/sessions/services/sessions/test/common/session.test.ts Tests title-aware workspace equality.
src/vs/sessions/contrib/providers/agentHost/browser/agentHostSessionArtifacts.ts Preserves titles during artifact partitioning.
src/vs/sessions/contrib/providers/agentHost/browser/baseAgentHostSessionsProvider.ts Projects titles into issue references.
src/vs/sessions/contrib/providers/agentHost/test/browser/localAgentHostSessionsProvider.test.ts Verifies provider title propagation.
src/vs/sessions/contrib/chat/browser/sessionChatInputToolbar.ts Implements live and recorded title fallback.
src/vs/sessions/contrib/chat/test/browser/sessionChatInputToolbar.test.ts Tests labels, tooltips, and accessibility text.
Review details
  • Files reviewed: 9/9 changed files
  • Comments generated: 0
  • Review effort level: Balanced

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

Cherry Wang (chryw) and others added 3 commits September 10, 2026 08:19
Assert that Agents Window issue entries dispatch their exact issue context and editor/panel entries open the GitHub URL externally.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Cover exact pull request context dispatch in the Agents Window and external URL activation in editor and panel chat.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Carry pull request artifact labels into regular editor and panel pill dropdowns, accessible names, and compact tooltips to match the Agents Window.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@chryw Cherry Wang (chryw) changed the title sessions: preserve recorded issue titles in pills sessions: preserve recorded GitHub titles in pills Sep 10, 2026
Scope the Agents-style trailing alignment to shared chat pill rows with toolbar actions, while preserving base ActionList spacing for rows without actions or with structured content.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@vs-code-engineering

Copy link
Copy Markdown
Contributor

📬 CODENOTIFY

The following users are being notified based on files changed in this PR:

Ulugbek Abdullaev (@ulugbekna)

Matched files:

  • src/vs/sessions/contrib/providers/agentHost/browser/baseAgentHostSessionsProvider.ts
  • src/vs/sessions/contrib/providers/agentHost/test/browser/localAgentHostSessionsProvider.test.ts

Sandeep Somavarapu (@sandy081)

Matched files:

  • src/vs/sessions/services/sessions/common/session.ts
  • src/vs/sessions/services/sessions/test/common/session.test.ts

Ladislau Szomoru (@lszomoru)

Matched files:

  • src/vs/sessions/services/sessions/common/session.ts
  • src/vs/sessions/services/sessions/test/common/session.test.ts

@chryw
Cherry Wang (chryw) marked this pull request as draft September 10, 2026 17:58
Satisfy the repository lint rule while preserving explicit external-open assertions.

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.

🟢 Approval recommended

The title propagation, fallback behavior, accessibility metadata, styling scope, and regression coverage are consistent and complete.

Review details
  • Files reviewed: 11/11 changed files
  • Comments generated: 0 new
  • Review effort level: Balanced

Avoid union-property narrowing in the test helper and verify the full external opener contract.

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.

🟢 Approval recommended

The title propagation, fallback behavior, accessibility metadata, styling scope, and activation paths are consistent and adequately tested.

Review details
  • Files reviewed: 11/11 changed files
  • Comments generated: 0 new
  • Review effort level: Balanced

@chryw
Cherry Wang (chryw) marked this pull request as ready for review September 10, 2026 18:15
@chryw
Cherry Wang (chryw) merged commit 02265cd into main Sep 10, 2026
34 checks passed
@chryw
Cherry Wang (chryw) deleted the chryw/issue-335383-issue-pill-title branch September 10, 2026 18:30
@vs-code-engineering vs-code-engineering Bot added this to the 1.138.0 milestone Sep 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Agent Window issue pill discards the recorded issue title

3 participants