Skip to content

Conversation

@joaomoreno
Copy link
Member

Reverts #281051

Copilot AI review requested due to automatic review settings January 29, 2026 15:09
@vs-code-engineering
Copy link

📬 CODENOTIFY

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

@TylerLeonhardt

Matched files:

  • src/vs/platform/quickinput/browser/media/quickInput.css
  • src/vs/platform/quickinput/browser/quickInputController.ts
  • src/vs/platform/quickinput/common/quickInput.ts

@bpasero

Matched files:

  • src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.ts
  • src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsPicker.ts

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR reverts the changes from PR #281051, which implemented a session picker feature in the chat panel title that allowed positioning the quick input picker anchored to a specific UI element.

Changes:

  • Removes the anchor parameter from AgentSessionsPicker and updates all instantiation sites
  • Removes the anchor property from quick input interfaces (IPickOptions, IQuickInput)
  • Removes anchor-based positioning logic from quickInputController.ts, including drag-and-drop control disabling
  • Deletes src/vs/base/common/layout.ts file containing 2D layout utilities
  • Moves layout logic and type definitions back into src/vs/base/browser/ui/contextview/contextview.ts
  • Updates layout function signature to return a number instead of an object with metadata
  • Removes CSS styles for disabling drag on anchored quick inputs

Reviewed changes

Copilot reviewed 10 out of 10 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewTitleControl.ts Removes anchor element reference and updates AgentSessionsPicker instantiation
src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsPicker.ts Removes anchor parameter from constructor and picker configuration
src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.ts Updates AgentSessionsPicker instantiation to remove undefined parameter
src/vs/platform/quickinput/common/quickInput.ts Removes anchor property from IPickOptions and IQuickInput interfaces
src/vs/platform/quickinput/browser/quickInputController.ts Removes anchor positioning logic, restores centered layout, removes drag control disabling
src/vs/platform/quickinput/browser/media/quickInput.css Removes no-drag cursor styles
src/vs/base/test/browser/ui/contextview/contextview.test.ts Updates imports and test assertions for simplified layout function return value
src/vs/base/common/layout.ts Deletes entire file containing 2D layout utilities
src/vs/base/browser/ui/menu/menu.ts Updates import and removes .position access from layout function calls
src/vs/base/browser/ui/contextview/contextview.ts Inlines layout logic, moves type definitions, restores previous implementation

Comment on lines +129 to +134

if (viewSize <= viewportSize - layoutAfterAnchorBoundary && layoutBeforeAnchorBoundary < viewSize / 2) {
return layoutAfterAnchorBoundary; // ok case, lay it out after the anchor
}


Copy link

Copilot AI Jan 29, 2026

Choose a reason for hiding this comment

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

There are extra blank lines in the layout function that appear inconsistent with the surrounding code style. Line 129 has an extra blank line before the second if statement, and line 134 has an extra blank line before the final return statement.

Suggested change
if (viewSize <= viewportSize - layoutAfterAnchorBoundary && layoutBeforeAnchorBoundary < viewSize / 2) {
return layoutAfterAnchorBoundary; // ok case, lay it out after the anchor
}
if (viewSize <= viewportSize - layoutAfterAnchorBoundary && layoutBeforeAnchorBoundary < viewSize / 2) {
return layoutAfterAnchorBoundary; // ok case, lay it out after the anchor
}

Copilot uses AI. Check for mistakes.
@joaomoreno joaomoreno merged commit ea32526 into main Jan 29, 2026
27 of 28 checks passed
@joaomoreno joaomoreno deleted the revert-281051-lszomoru/session-picker branch January 29, 2026 16:06
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