Skip to content

fix(ui): chat workspace rail and detail panel break narrow panes and compact windows - #104033

Merged
steipete merged 1 commit into
mainfrom
claude/sidebar-layout-responsive-4b1cdc
Jul 11, 2026
Merged

steipete merged 1 commit into
mainfrom
claude/sidebar-layout-responsive-4b1cdc

Conversation

@steipete

Copy link
Copy Markdown
Contributor

Closes #104023

What Problem This Solves

Fixes an issue where users opening the session workspace rail or the file/tool detail panel in a narrow chat pane would see the layout fall apart. The rail and detail panel keyed their layout off viewport media queries, so a narrow split-view pane inside a wide window (or a compact macOS-app session window whose webview reports a wide viewport) still got the wide side-by-side treatment: a 280px rail column crushed the thread to a ~300px sliver with clipped, overlapping bubbles, and the chat + detail-panel pair (312px + 300px minimums) overflowed the pane. Below a 1120px viewport the rail and all of its toggles were simply display: none, making workspace files unreachable in narrow windows.

Why This Change Was Made

Layout decisions now follow the pane's own measured width instead of viewport breakpoints: openclaw-chat-pane observes its width with a ResizeObserver and switches to horizontal splits when side-by-side cannot fit. Below 800px of pane width the workspace rail always presents as the existing bottom-dock strip (side-dock drag/toggle controls hide until the pane widens; the persisted dock preference is untouched). When the width available to the chat + detail split (pane minus a side-docked rail) drops under 680px, the detail panel stacks below the thread and the shared resizable-divider flips to its horizontal orientation, so the split stays resizable. The phone-sized (≤768px viewport) full-screen detail takeover is unchanged. The 1120px hide-the-rail cliff is removed — the rail is now usable at every width — and two bottom-strip rows (workspace path, summary chips) no longer flex-shrink into clipped text.

User Impact

Narrow chat panes — split-view panes, compact desktop windows, and macOS-app session windows — keep a readable thread when the workspace rail or detail panel is open: panels move below the chat instead of fighting it for horizontal space. Workspace files are now reachable in windows narrower than 1120px, where the rail previously did not exist at all.

Evidence

Reproduced and verified with the Control UI mock-gateway Playwright harness (chromium + webkit) across 1440/1150/1000/900/800/700/500px windows and a two-pane split view; a geometry probe asserts no rail/thread/panel rect intersections and no horizontal document overflow at any size after the change.

Split view, narrow pane with workspace rail (before → after):

Before After
before: rail crushes the pane after: rail docks under the thread

800px window (before: rail inaccessible → after: bottom strip):

Before After
before: no rail below 1120px after: bottom-docked rail

Stacked detail panel — 900px window with side rail + detail panel (full size), and split view with rail + detail in one narrow pane (full size).

Tests:

  • ui/src/pages/chat/chat-view.test.ts: stacked class + horizontal divider orientation from sidebarStacked; narrowLayout forces the bottom dock and hides side-dock controls.
  • ui/src/pages/chat/chat-responsive.browser.test.ts: real-CSS geometry — stacked panel sits below the thread at full pane width; bottom-strip path/summary rows keep their height instead of clipping.
  • Gates: pnpm check:changed (delegated to Testbox) — result posted below before merge.

@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation app: web-ui App: web-ui size: M maintainer Maintainer-authored PR labels Jul 11, 2026
@clawsweeper clawsweeper Bot added proof: sufficient ClawSweeper judged the real behavior proof convincing. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. P1 High-priority user-facing bug, regression, or broken workflow. labels Jul 11, 2026
@clawsweeper

clawsweeper Bot commented Jul 11, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed July 10, 2026, 9:44 PM ET / July 11, 2026, 01:44 UTC.

Summary
The PR measures each chat pane and switches the workspace rail to a bottom strip and the detail panel to a vertical split when the pane cannot support side-by-side panels, with focused tests and Control UI documentation.

PR surface: Source +93, Tests +140, Docs +1. Total +234 across 7 files.

Reproducibility: yes. Current-main source exposes the viewport-keyed failure path, and the inspected before screenshots directly reproduce both the hidden workspace rail and the crushed split-pane thread.

Review metrics: none identified.

Root-cause cluster
Relationship: fixed_by_candidate
Canonical: #104023
Summary: This PR is the direct candidate fix for the linked narrow-pane chat layout bug.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Merge readiness
Overall: 🦞 diamond lobster
Proof: 🦞 diamond lobster ✨ media proof bonus
Patch quality: 🦞 diamond lobster
Result: ready for maintainer review.

Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch.

Risk before merge

  • [P1] The branch is seven commits behind current main; although GitHub reports it mergeable and exact-head checks are green, maintainers should inspect the final three-way merge for any newly overlapping chat changes before landing.

Maintainer options:

  1. Decide the mitigation before merge
    Land the pane-owned responsive layout while preserving the stored workspace dock preference, phone-sized full-screen detail takeover, background-task rail behavior, and shared divider semantics.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Next step before merge

  • [P2] Review the final three-way merge against current main and land the PR if no new overlap appears; the protected maintainer label keeps this out of autonomous repair or cleanup.

Security
Cleared: The patch is limited to UI layout logic, CSS, tests, and docs and introduces no dependency, secret, permission, workflow, downloaded-code, or supply-chain change.

Review details

Best possible solution:

Land the pane-owned responsive layout while preserving the stored workspace dock preference, phone-sized full-screen detail takeover, background-task rail behavior, and shared divider semantics.

Do we have a high-confidence way to reproduce the issue?

Yes. Current-main source exposes the viewport-keyed failure path, and the inspected before screenshots directly reproduce both the hidden workspace rail and the crushed split-pane thread.

Is this the best way to solve the issue?

Yes. Measuring the owning pane is the narrowest maintainable solution because pane width can differ from viewport width, and the patch reuses the existing bottom dock and divider instead of creating parallel layout mechanisms.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 7ac8e2e227a3.

Label changes

Label changes:

  • add rating: 🦞 diamond lobster: Overall readiness is 🦞 diamond lobster; proof is 🦞 diamond lobster and patch quality is 🦞 diamond lobster.
  • remove rating: 🐚 platinum hermit: Current PR rating is rating: 🦞 diamond lobster, so this older rating label is no longer current.

Label justifications:

  • P1: The linked bug breaks a common chat workflow by hiding workspace access in compact windows or making narrow split-pane conversations severely unreadable.
  • rating: 🦞 diamond lobster: Overall readiness is 🦞 diamond lobster; proof is 🦞 diamond lobster and patch quality is 🦞 diamond lobster.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (screenshot): Direct before/after screenshots convincingly demonstrate the original narrow-pane failures and the improved bottom-docked and stacked layouts on the submitted head.
  • proof: sufficient: Contributor real behavior proof is sufficient. Direct before/after screenshots convincingly demonstrate the original narrow-pane failures and the improved bottom-docked and stacked layouts on the submitted head.
  • proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence. Direct before/after screenshots convincingly demonstrate the original narrow-pane failures and the improved bottom-docked and stacked layouts on the submitted head.
Evidence reviewed

PR surface:

Source +93, Tests +140, Docs +1. Total +234 across 7 files.

View PR surface stats
Area Files Added Removed Net
Source 4 132 39 +93
Tests 2 140 0 +140
Docs 1 1 0 +1
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 7 273 39 +234

What I checked:

  • Current-main reproduction: Current main gives the workspace rail a fixed 230–280px grid column and hides its opener and pane-header toggle below a 1120px viewport, so a narrow pane can be crushed inside a wide viewport and a compact window can lose workspace access. (ui/src/styles/chat/sidebar.css:5, 7ac8e2e227a3)
  • Pane-owned implementation: The PR observes the chat-pane element, ignores hidden zero-width observations, disconnects on teardown, and derives rail and detail presentation from the measured pane width. (ui/src/pages/chat/chat-pane.ts:826, 088f48a159cb)
  • Preserved preference and shared behavior: Narrow layout changes only presentation: the persisted workspace dock value remains intact, while the existing resizable divider is reused with horizontal orientation for stacked detail panels. (ui/src/pages/chat/chat-view.ts:187, 088f48a159cb)
  • Real behavior proof: The inspected screenshots directly show the current crushed split-pane thread and missing 800px workspace rail, followed by readable bottom-docked and stacked layouts without visible horizontal overflow. (ui/src/pages/chat/chat-responsive.browser.test.ts:1372, 088f48a159cb)
  • Exact-head validation: All 58 applicable GitHub checks passed on the latest head, including real behavior proof, lint, production and test types, docs, build artifacts, and changed test shards; 13 unrelated lanes were skipped. (088f48a159cb)
  • Current-main history: Recent merged work on the same pane, workspace, task-rail, and divider surfaces is concentrated in commits 4669235 and e07ad4b, and the PR head incorporates that behavior after its force-push. (ui/src/pages/chat/chat-pane.ts:1220, 46692355c903)

Likely related people:

  • steipete: Recent merged commits introduced the chat workbench, background-task rail, and shared divider behavior across the exact current-main files this patch extends. (role: feature owner and recent area contributor; confidence: high; commits: 62d10f7b84fc, 46692355c903, e07ad4b05bcc; files: ui/src/pages/chat/chat-pane.ts, ui/src/pages/chat/chat-view.ts, ui/src/pages/chat/components/chat-session-workspace.ts)
What the crustacean ranks mean
  • 🦀 challenger crab: rare, exceptional readiness with strong proof, clean implementation, and convincing validation.
  • 🦞 diamond lobster: very strong readiness with only minor maintainer review expected.
  • 🐚 platinum hermit: good normal PR, likely mergeable with ordinary maintainer review.
  • 🦐 gold shrimp: useful signal, but proof or patch confidence is still limited.
  • 🦪 silver shellfish: thin signal; proof, validation, or implementation needs work.
  • 🧂 unranked krab: not merge-ready because proof is missing/unusable or there are serious correctness or safety concerns.
  • 🌊 off-meta tidepool: rating does not apply to this item.

Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

How this review workflow works
  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.
Review history (1 earlier review cycle)
  • reviewed 2026-07-11T01:32:37.780Z sha d0f472962587114b7d0850c860da1222310b203c :: needs maintainer review before merge. :: none

@steipete
steipete force-pushed the claude/sidebar-layout-responsive-4b1cdc branch from d0f4729 to 088f48a Compare July 11, 2026 01:36
The workspace rail and message detail panel keyed layout off viewport
media queries, so narrow split-view panes and compact windows got
crushed side-by-side columns, and below 1120px the rail was
display:none with no way to reach workspace files.

Chat panes now measure their own width with a ResizeObserver: under
800px the rail presents as the existing bottom-dock strip (side-dock
controls hide), and when the chat + detail split has under 680px the
detail panel stacks below the thread with a horizontal resize divider.
The phone full-screen detail takeover is unchanged. Bottom-strip path
and summary rows no longer flex-shrink into clipped text.

Closes #104023

@chatgpt-codex-connector chatgpt-codex-connector Bot 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 088f48a159

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines 84 to 88
@media (max-width: 1120px) {
.chat-workspace-open,
.chat-tasks-open,
.chat-pane__actions .chat-workspace-toggle,
.chat-pane__actions .chat-tasks-toggle {
display: none;
}

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.

P2 Badge Reset the tasks grid when hiding the rail

If a user opens the background-tasks rail in a wide window and then narrows the viewport below 1120px, this media rule hides .chat-tasks-rail and the only task toggles, but .chat-workbench--tasks-open still applies the earlier grid-template-columns: minmax(0, 1fr) minmax(230px, 280px). Before this change the same breakpoint switched .chat-workbench to flex, so the hidden rail did not reserve a blank 230–280px column; now the chat stays squeezed and the user cannot collapse the hidden rail until widening again.

Useful? React with 👍 / 👎.

@clawsweeper clawsweeper Bot added rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. and removed rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. labels Jul 11, 2026
@steipete
steipete force-pushed the claude/sidebar-layout-responsive-4b1cdc branch from 088f48a to 92a5bd3 Compare July 11, 2026 02:09
@steipete
steipete merged commit e6671d9 into main Jul 11, 2026
72 checks passed
@steipete
steipete deleted the claude/sidebar-layout-responsive-4b1cdc branch July 11, 2026 02:18
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Jul 11, 2026
…penclaw#104033)

The workspace rail and message detail panel keyed layout off viewport
media queries, so narrow split-view panes and compact windows got
crushed side-by-side columns, and below 1120px the rail was
display:none with no way to reach workspace files.

Chat panes now measure their own width with a ResizeObserver: under
800px the rail presents as the existing bottom-dock strip (side-dock
controls hide), and when the chat + detail split has under 680px the
detail panel stacks below the thread with a horizontal resize divider.
The phone full-screen detail takeover is unchanged. Bottom-strip path
and summary rows no longer flex-shrink into clipped text.

Closes openclaw#104023
steipete added a commit that referenced this pull request Jul 11, 2026
…panes

The tasks rail (from #104010) only rendered as a right-docked 230-280px
column and vanished with its toggles below a 1120px viewport, so narrow
split-view panes got a crushed thread and compact windows lost access
to background tasks entirely — the same bug class #104033 fixed for the
workspace rail and detail panel.

The rail now follows the pane's measured width: it presents as a
full-width bottom strip (sections side by side like the workspace
rail's bottom dock) when the pane is too narrow for a side column, and
the workspace rail keeps first claim on the side slot when only one
column fits. Side-docked rails, not bottom strips, now count against
the width available to the chat + detail split.

Closes #104091
steipete added a commit that referenced this pull request Jul 11, 2026
…panes (#104107)

The tasks rail (from #104010) only rendered as a right-docked 230-280px
column and vanished with its toggles below a 1120px viewport, so narrow
split-view panes got a crushed thread and compact windows lost access
to background tasks entirely — the same bug class #104033 fixed for the
workspace rail and detail panel.

The rail now follows the pane's measured width: it presents as a
full-width bottom strip (sections side by side like the workspace
rail's bottom dock) when the pane is too narrow for a side column, and
the workspace rail keeps first claim on the side slot when only one
column fits. Side-docked rails, not bottom strips, now count against
the width available to the chat + detail split.

Proof: check:changed + 212 focused tests green on Testbox at this exact
content; codex autoreview clean; chromium+webkit visual verification at
seven window widths plus split view with zero geometry overlaps.
Landed with maintainer CI override.

Closes #104091
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Jul 12, 2026
…panes (openclaw#104107)

The tasks rail (from openclaw#104010) only rendered as a right-docked 230-280px
column and vanished with its toggles below a 1120px viewport, so narrow
split-view panes got a crushed thread and compact windows lost access
to background tasks entirely — the same bug class openclaw#104033 fixed for the
workspace rail and detail panel.

The rail now follows the pane's measured width: it presents as a
full-width bottom strip (sections side by side like the workspace
rail's bottom dock) when the pane is too narrow for a side column, and
the workspace rail keeps first claim on the side slot when only one
column fits. Side-docked rails, not bottom strips, now count against
the width available to the chat + detail split.

Proof: check:changed + 212 focused tests green on Testbox at this exact
content; codex autoreview clean; chromium+webkit visual verification at
seven window widths plus split view with zero geometry overlaps.
Landed with maintainer CI override.

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

Labels

app: web-ui App: web-ui docs Improvements or additions to documentation maintainer Maintainer-authored PR P1 High-priority user-facing bug, regression, or broken workflow. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. size: M status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Chat workspace rail and detail panel break narrow panes/windows (viewport-keyed layout)

1 participant