Skip to content

fix: prevent horizontal overflow on home page#3944

Open
Kushaal-k wants to merge 1 commit into
nexu-io:mainfrom
Kushaal-k:fix-home-horizontal-scrollbar
Open

fix: prevent horizontal overflow on home page#3944
Kushaal-k wants to merge 1 commit into
nexu-io:mainfrom
Kushaal-k:fix-home-horizontal-scrollbar

Conversation

@Kushaal-k

Copy link
Copy Markdown
Contributor

Fixes #3910

Why

This PR addresses a layout regression on the Home page where a spurious horizontal scrollbar appears at the bottom of the window, even though the content already fits within the available viewport.

The root scroller (.entry-main--scroll) was missing an overflow-x guard. Because of this, any descendant elements that marginally exceeded the 1440px cap—such as 100vw backgrounds, max-content rows, or chip strips with horizontal overflow—caused the entire page layout to leak out and expose a bottom scrollbar. Adding overflow-x: clip prevents the leak while preserving position: sticky child elements like the topbar.

What users will see

Users will no longer see a spurious horizontal scrollbar at the bottom of the Home page, restoring a stable and visually polished layout that is locked horizontally.

Surface area

  • UI — new page / dialog / panel / menu item / setting / empty state in apps/web or apps/desktop (including Electron menu bar)
  • Keyboard shortcut — new or changed
  • CLI / env var — new od subcommand or flag, new tools-dev / tools-pack / tools-pr flag, or new OD_* env var
  • API / contract — new /api/* endpoint, new SSE event, or changed shape in packages/contracts
  • Extension point — new entry under skills/, design-systems/, design-templates/, or craft/, or change to the skills protocol
  • i18n keys — added new translation keys (see TRANSLATIONS.md for the locale workflow)
  • New top-level dependency — adding any new entry to the root package.json (dependencies or devDependencies); workspace-package package.json files are out of scope. Include a paragraph on what we get vs. what bytes we ship (see CONTRIBUTING.md → Code style)
  • Default behavior change — changes what existing users experience without opting in (default model, default setting, file/SQLite schema, auto-network on startup, auto-install)
  • None — internal refactor, docs, tests, or translation update only

Screenshots

Bug fix verification

  • Test path that reproduces the bug: N/A - pure visual CSS layout regression.
  • Did the test go red on main and green on this branch? (yes / no): N/A
  • If a red spec wasn't cheap to write, explain why and what verification you did instead: Wrote a CSS rule (overflow-x: clip;) to bound the horizontal width of .entry-main--scroll. Tested visually in the browser across viewport bounds above and below the inner max-width breakpoint to ensure horizontal scroll leak is patched without breaking the sticky layout logic.

Validation

  • Ran pnpm tools-dev and performed a visual verification of the Home page layout ensuring the horizontal scrollbar is permanently removed and the topbar remains correctly positioned.
  • pnpm guard + pnpm typecheck
  • pnpm --filter @open-design/web test

@github-actions

github-actions Bot commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

Visual regression review

Head: 1573aa0 · Base: 75f1472

4 changed · 13 unchanged · 0 missing baseline · 0 failed

Changed cases

Case Main PR Diff
visual-design-systems main pr diff
visual-home-context-picker main pr diff
visual-home-plugin-filter main pr diff
visual-new-project-modal main pr diff
Unchanged cases
Case Main PR Diff
visual-avatar-menu main pr diff
visual-home main pr diff
visual-home-catalog main pr diff
visual-integrations main pr diff
visual-integrations-use-everywhere main pr diff
visual-plugin-details main pr diff
visual-plugins main pr diff
visual-projects main pr diff
visual-projects-kanban main pr diff
visual-settings-byok main pr diff
visual-settings-execution main pr diff
visual-tasks main pr diff
visual-topbar-execution-switcher main pr diff

Visual diff is advisory only and does not block merging.

@Kushaal-k

Copy link
Copy Markdown
Contributor Author

Hey @lefarcen, can you check if this fixes the issue?

@lefarcen lefarcen added size/XS PR changes <20 lines risk/low Low risk: docs/i18n/assets only type/bugfix Bug fix labels Jun 9, 2026

@lefarcen lefarcen 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.

Hey @Kushaal-k — yes, this fixes it! 👋

The one-liner is exactly right. A few notes on why the approach is solid:

  • clip over hidden is the precise call here. overflow-x: hidden would establish a new horizontal scroll origin on .entry-main--scroll, which can silently break position: sticky descendants — and this scroll container already has a sticky topbar (.entry-main__topbar at line 742). clip cuts the overflow without creating that side-effect, so sticky continues to work correctly.
  • The fix targets the root cause at the right layer (the scroll container itself) rather than chasing individual overflowing descendants.
  • PR body is thorough — the Why/What/Validation writeup maps cleanly to the issue.

CI is all green and the strict visual regression check passed with 4 changed cases (all expected — the horizontal leak is gone). Clean from my side. ✨

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk/low Low risk: docs/i18n/assets only size/XS PR changes <20 lines type/bugfix Bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Home can show an unnecessary horizontal scrollbar at the bottom

2 participants