← 输入框|github.com|刷新
Skip to content

Open GitHub PR and issue links to the side when VS Code requests it - #9151

Draft
Alex Ross (alexr00) with Copilot wants to merge 2 commits into
mainfrom
copilot/honor-open-to-side-placement
Draft

Alex Ross (alexr00) with Copilot wants to merge 2 commits into
mainfrom
copilot/honor-open-to-side-placement

Conversation

Copilot AI commented Nov 2, 2026 •

Copy link
Copy Markdown
Contributor

VS Code passes viewColumn: ViewColumn.Beside to external URI openers when a link is opened with an open-to-side gesture (e.g. Alt+Enter in Quick Open). The GitHub issue/PR opener ignored it, so the overview always opened or revealed in the current editor group.

Changes

  • externalUriOpener.ts: the opener now maps openContext.viewColumn === vscode.ViewColumn.Beside to toTheSide and passes it to PullRequestOverviewPanel.createOrShow and IssueOverviewPanel.createOrShow. Placement was already implemented in both panels via _getViewColumn:
    • New panel → createWebviewPanel(..., ViewColumn.Beside, ...)
    • Existing panel → reveal(ViewColumn.Beside, true), which moves it to the side group without taking focus, as for any other reveal.
    • No column or Active → behaviour is unchanged. Only Beside is honoured; other columns open in the current group.
  • Tests (externalUriOpener.test.ts), each run for both PRs and issues:
    • A side request creates a new panel beside the active editor.
    • A side request reveals an already-open panel beside.
    • With no column or Active, a new panel still opens in the active group and an existing panel is revealed with undefined (stays where it is).
const toTheSide = openContext.viewColumn === vscode.ViewColumn.Beside;
await PullRequestOverviewPanel.createOrShow(telemetry, extensionUri, manager, identity, pullRequest, toTheSide);

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

Co-authored-by: alexr00 <38270282+alexr00@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix open-to-side placement for GitHub PR links Open GitHub PR and issue links to the side when VS Code requests it Nov 2, 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.

Honor open-to-side placement when opening GitHub PR and issue links

2 participants