Skip to content

Avoid nested scrolling in the code session rail - #4488

Merged
BunsDev merged 1 commit into
mainfrom
fix/cave-iixug-code-session-rail-scroll
Aug 10, 2026
Merged

Avoid nested scrolling in the code session rail#4488
BunsDev merged 1 commit into
mainfrom
fix/cave-iixug-code-session-rail-scroll

Conversation

@BunsDev

@BunsDev BunsDev commented Aug 10, 2026

Copy link
Copy Markdown
Member

Summary

  • let the shared SurfaceRail own scrolling for the wide Code sessions rail
  • preserve independent scrolling for the narrow list-first layout
  • pin both paths in the existing code surface contract test

Verification

  • pnpm typecheck
  • pnpm lint
  • pnpm test:app
  • pnpm test:api
  • pnpm check:tests-wired

Bead: cave-iixug

Copilot AI lite review requested due to automatic review settings August 10, 2026 06:47

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.

Pull request overview

This PR updates the Code surface sessions rail so that, in the wide layout, scrolling is owned by the shared SurfaceRail container (avoiding nested scroll areas), while the narrow “list-first” drill-in layout keeps its own independent scrolling. It also extends the existing surface contract test to pin this behavior.

Changes:

  • In CodeSessionRail, conditionally remove overflow-y-auto when the rail is hosted inside SurfaceRail (detected via the presence of onExpand).
  • Preserve overflow-y-auto for the standalone narrow layout where CodeSessionRail must remain scrollable.
  • Add assertions to the code surface contract test to lock in the open-state scrolling class contract.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
src/components/code-session-rail.tsx Introduces a layout-sensitive open-state class so wide SurfaceRail usage avoids nested scrolling while narrow standalone usage remains scrollable.
src/components/code-surface-mode.test.ts Adds contract assertions to ensure the rail’s open-state scrolling behavior remains stable across both layout paths.

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

@BunsDev
BunsDev merged commit ee369a2 into main Aug 10, 2026
22 checks passed
@BunsDev
BunsDev deleted the fix/cave-iixug-code-session-rail-scroll branch August 10, 2026 07:10
@BunsDev
BunsDev restored the fix/cave-iixug-code-session-rail-scroll branch August 10, 2026 07:27
@BunsDev
BunsDev deleted the fix/cave-iixug-code-session-rail-scroll branch August 10, 2026 11:00
@BunsDev
BunsDev restored the fix/cave-iixug-code-session-rail-scroll branch August 10, 2026 11:03
@BunsDev
BunsDev deleted the fix/cave-iixug-code-session-rail-scroll branch August 10, 2026 11:43
@BunsDev
BunsDev restored the fix/cave-iixug-code-session-rail-scroll branch August 10, 2026 11:47
@BunsDev
BunsDev deleted the fix/cave-iixug-code-session-rail-scroll branch August 10, 2026 13:10
@BunsDev
BunsDev restored the fix/cave-iixug-code-session-rail-scroll branch August 10, 2026 13:27
@BunsDev
BunsDev deleted the fix/cave-iixug-code-session-rail-scroll branch August 10, 2026 13:28
@BunsDev
BunsDev restored the fix/cave-iixug-code-session-rail-scroll branch August 10, 2026 13:30
@BunsDev
BunsDev deleted the fix/cave-iixug-code-session-rail-scroll branch August 10, 2026 16:41
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.

2 participants