feat: enhance sessions view with find widget and header actions#307679
Draft
romalpani wants to merge 5 commits intomicrosoft:mainfrom
Draft
feat: enhance sessions view with find widget and header actions#307679romalpani wants to merge 5 commits intomicrosoft:mainfrom
romalpani wants to merge 5 commits intomicrosoft:mainfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR enhances the Sessions view in the Agents/Sessions window by moving key controls into an in-view header row and embedding the tree find widget into that header, supported by a small extension to the base tree find-widget plumbing.
Changes:
- Add a custom header row to the Sessions view with icon actions (Find, Filter) and a compact “New” button, and integrate the tree’s find widget into the header area.
- Extend the base
AbstractTreefind controller to optionally render the find widget into a provided external container (instead of overlaying inside the tree). - Update Sessions list configuration and CSS to support the embedded find widget and refreshed header/button styling.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/vs/sessions/contrib/sessions/browser/views/sessionsViewActions.ts | Removes Sessions view title menu contributions for Find/Filter, shifting entry points to the view header UI. |
| src/vs/sessions/contrib/sessions/browser/views/sessionsView.ts | Builds the new Sessions header row, wires header actions, and toggles header vs. embedded find widget visibility. |
| src/vs/sessions/contrib/sessions/browser/views/sessionsList.ts | Adds support for an external find-widget container and customizes find widget styles for the Sessions tree. |
| src/vs/sessions/contrib/sessions/browser/media/sessionsViewPane.css | Adds styling for the new header row, embedded find widget layout, and compact “New” button. |
| src/vs/base/browser/ui/tree/abstractTree.ts | Adds findWidgetContainer option to render the tree find widget into a caller-provided container and avoid padding changes in that mode. |
Resolve Copilot review comments on the sessions view header actions and compact "New" button styling: - Register hover delegate for disposal: `createInstantHoverDelegate()` returns an owned object that must be disposed by the consumer. Wrap it with `this._register()` instead of passing it inline to ActionBar. - Anchor filter context menu to the correct element: use `actionBar.viewItems` and `BaseActionViewItem.element` to get the filter button's actual DOM element, instead of anchoring to the entire ActionBar container which caused misaligned menu positioning. - Fix compact "New" button border visibility: the Button constructor sets an inline `border` style when `buttonSecondaryBorder` is provided, which overrides CSS declarations. Pass an empty string for `buttonSecondaryBorder` to prevent the inline style, and let the CSS rule handle the border with a `color-mix` fallback for themes where `--vscode-button-border` is undefined. - Remove `!important` from border rule: drop `.default-colors` from the selector since inline style suppression makes it unnecessary, and use `var(--vscode-button-border, color-mix(...))` for a subtle always-visible border that adapts to both light and dark themes.
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.
Enhance the sessions view with find widget and header actions.
Changes include:
Fixes #307524
In the demo video below (light theme is current, dark theme is proposed).
CleanShot.2026-04-02.at.11.58.00.mp4