Skip to content

docs: clarify viewport sets window size, not page viewport - #482

Merged
Jayko001 merged 2 commits into
mainfrom
jay/viewport-window-vs-page-clarification
Aug 7, 2026
Merged

docs: clarify viewport sets window size, not page viewport#482
Jayko001 merged 2 commits into
mainfrom
jay/viewport-window-vs-page-clarification

Conversation

@Jayko001

@Jayko001 Jayko001 commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

Why

Customer feedback (Slack): they set a 1280x800 viewport and the bottom of the screen was cut off in their tests. Root cause: the viewport parameter sets the browser window dimensions, and on headful browsers Chromium's UI (tab strip, toolbar) consumes part of that height — so the visible page area is shorter than the configured height. The docs never mentioned this, so it read as a regression on the customer's side.

What

  • New Window size vs. page viewport section on browsers/viewport.mdx explaining the behavior, with two workarounds:
    • set the page viewport directly via the automation framework (Playwright setViewportSize example)
    • pad the configured height to account for the browser UI
  • Notes that headless browsers have no browser UI, so the page viewport matches exactly
  • Corrects the Considerations bullet that claimed screenshots always match the configured dimensions

🤖 Generated with Claude Code


Note

Low Risk
Documentation-only change to viewport guidance; no runtime or API behavior changes.

Overview
Documents that Kernel’s viewport parameter controls browser window size, not the rendered page area on headful sessions—Chromium chrome reduces usable height (e.g. 1280×800 can clip the bottom in live view and screenshots).

Adds a Window size vs. page viewport section with Playwright setViewportSize examples and guidance to pad configured height for browser UI, and notes headless sessions match dimensions exactly. Updates Considerations so automation-framework screenshots are described as page viewport–sized, with a link to the new section.

Reviewed by Cursor Bugbot for commit 4d795d4. Bugbot is set up for automated code reviews on this repo. Configure here.

Customer feedback: a 1280x800 viewport appeared "cut off" because on
headful browsers the Chromium UI (tab strip, toolbar) consumes part of
the window height, so the visible page area is shorter than the
configured height. Add a section explaining window size vs. page
viewport with workarounds (set the page viewport via the automation
framework, or pad the height), and correct the screenshots bullet in
Considerations.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@mintlify

mintlify Bot commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
Kernel 🟢 Ready View Preview Aug 5, 2026, 6:46 PM

💡 Tip: Enable Workflows to automatically generate PRs for you.

@vercel

vercel Bot commented Aug 5, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
docs Error Error Aug 7, 2026 12:27am

cursor[bot]
cursor Bot approved these changes Aug 5, 2026
@Jayko001
Jayko001 requested a review from ehfeng August 7, 2026 00:17
@Jayko001
Jayko001 merged commit d7958fb into main Aug 7, 2026
5 of 7 checks passed
@Jayko001
Jayko001 deleted the jay/viewport-window-vs-page-clarification branch August 7, 2026 00:27

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Risk assessment: Very Low

Verdict: Already approved — no re-approval needed. Risk unchanged after re-evaluation.

Evidence (from diff)

  • 1 file changed: browsers/viewport.mdx (+27 / −1)
  • Documentation-only: adds a Window size vs. page viewport section (Playwright TS/Python examples) and corrects a Considerations bullet about screenshots
  • No application/runtime code, config, infra, auth, API specs, or shared libraries modified
  • Latest sync is a merge from main; effective PR delta remains the same docs edit
  • No CODEOWNERS requirement found

Re-evaluation notes

This automation previously approved the PR as Very Low. After the synchronize update, risk has not increased, so approval is left in place and is not re-issued.

Why Very Low

Small, scoped docs clarification with no production logic or operational blast radius.

Open in Web View Automation 

Sent by Cursor Automation: Assign PR reviewers

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.

1 participant