Skip to content

Prevent PR overview overflow in Agents window - #8937

Merged
Alex Ross (alexr00) merged 4 commits into
mainfrom
copilot/fix-pr-view-width-issue
Sep 8, 2026
Merged

Prevent PR overview overflow in Agents window#8937
Alex Ross (alexr00) merged 4 commits into
mainfrom
copilot/fix-pr-view-width-issue

Conversation

Copilot AI commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

Opening a linked PR in the Agents window could expand the overview beyond the viewport, pushing the sidebar off-screen.

  • Layout containment
    • Allow the main grid column to shrink below its content’s intrinsic width.
    • Preserve existing sidebar sizing and responsive behavior.
grid-template-columns: minmax(0, 1fr) minmax(200px, 300px);
  • Fixes #334797

@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 overly wide PR view when opening link in new tab Prevent PR overview overflow in Agents window Sep 7, 2026

@alexr00 Alex Ross (alexr00) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Copilot I still get a little bit of a horizontal scroll bar when oepning an issue webview from a PR webview.

@alexr00 Alex Ross (alexr00) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Copilot try again

Co-authored-by: alexr00 <38270282+alexr00@users.noreply.github.com>

Copilot AI commented Sep 8, 2026

Copy link
Copy Markdown
Contributor Author

Copilot try again

Addressed in 4419d67. Plain unbroken issue-body text now wraps; Chromium validation with the linked issue’s content shows no document overflow from 280px through 1400px viewports.

@alexr00
Alex Ross (alexr00) marked this pull request as ready for review September 8, 2026 12:50
Copilot AI lite review requested due to automatic review settings September 8, 2026 12:50

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 CSS changes directly implement the stated layout containment fix and are consistent with existing overflow-prevention rules in the webview.

Pull request overview

This PR tightens layout containment for the PR overview webview so that intrinsic-width content (e.g., long lines in linked PR content in the Agents window) can’t force the main column wider than the viewport and push the sidebar off-screen.

Changes:

  • Update the main grid’s first track to minmax(0, 1fr) to allow shrinking below intrinsic width.
  • Ensure .comment-body itself (not just some descendants) gets overflow-wrap: anywhere to prevent long, unbroken content from expanding layout.
File summaries
File Description
webviews/editorWebview/index.css Adjusts the #app grid column sizing to prevent overflow and expands overflow-wrap coverage to .comment-body to avoid horizontal expansion from long content.
Review details
  • Files reviewed: 1/1 changed files
  • Comments generated: 0
  • Review effort level: Lite

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

@alexr00
Alex Ross (alexr00) merged commit 88bcd0d into main Sep 8, 2026
7 checks passed
@alexr00
Alex Ross (alexr00) deleted the copilot/fix-pr-view-width-issue branch September 8, 2026 12:57
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.

Opening PR in a new tab in Agents window results in overly wide PR view

4 participants