Repository navigation
feat(ui): dock the session progress card beside a wide composer - #129141
Conversation
The progress card had two placements: the companion rail when that side
panel is open, otherwise a collapsed one-line bar stacked inside the
composer box. On a wide chat the composer stays centered at the
transcript width, so the space either side of it sits empty while the
card is squeezed into the composer.
Add a third placement. When the measured free gutter beside the composer
is at least 280px, the card docks into it with its full checklist
expanded; below that it falls back to the existing composer bar, and an
open companion rail still wins. Exactly one placement renders at a time,
now expressed as a closed {card, placement} prop so the composer bar and
the dock cannot both draw the same card.
The gutter is measured from the DOM by a small ResizeObserver controller
rather than derived from the pane width: the transcript width is a
browser-local setting in arbitrary CSS units, and an open side panel
shrinks the conversation column without changing the pane. The dock is
positioned absolutely in that gutter, so the transcript and composer
never shift when a card appears or is dismissed, and its inline-start
edge repeats the composer's own half-width formula through a shared
--chat-composer-side-inset token so the two stay in agreement.
|
🦞👀 Pull request received. I will update this pull request when review starts. |
The composer shell tokens are declared on .chat, but the new-session page reuses .agent-chat__composer-shell outside it. There the var() had no value, so the whole width declaration was invalid and dropped, and the composer stretched full-width instead of holding its 48rem centered box. Give both tokens their literal fallback at the use site, matching the neighbouring --chat-thread-max-width. The custodian surface was already immune because it overrides width outright. Caught by ui/src/e2e/new-session-page.places.e2e.test.ts, which is the regression test for this: it failed on the previous head and passes now.
|
Codex review: needs maintainer review before merge. Reviewed August 25, 2026, 4:18 AM ET / 08:18 UTC. ClawSweeper reviewWhat this changesThe PR adds a gutter placement that shows a session progress card beside a sufficiently wide chat composer while retaining rail and narrow composer placements. Merge readinessKeep open for normal maintainer review. The head centralizes the mutually exclusive rail/composer/dock choice and the focused UI E2E covers all three layouts; no concrete patch defect was found. Priority: P3 Review scores
Verification
Live VerificationCommand: Result: FAIL (partial) — step 2 Assertions:
How this fits togetherThe Control UI receives Gateway-backed progress-card state and renders it in a chat pane. The pane selects exactly one placement before passing the card to the composer, side rail, or gutter renderer. flowchart LR
A[Gateway progress-card state] --> B[Chat pane]
C[Composer and conversation geometry] --> D[Placement decision]
B --> D
D --> E[Composer card]
D --> F[Side rail card]
D --> G[Gutter dock card]
Before merge
Agent review detailsSecurityNone. PR surfaceSource +155, Tests +28, Docs +1. Total +184 across 11 files. View PR surface stats
Review metrics
Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Retain the single closed placement flow and the three-viewport E2E coverage, then land only after exact-head CI and the normal maintainer review are complete. Do we have a high-confidence way to reproduce the issue? Not applicable as a bug reproduction: this is a new layout capability, and the PR supplies a focused browser scenario for its intended states. Is this the best way to solve the issue? Yes, subject to normal current-main and CI confirmation: one closed placement value prevents duplicate rendering and uses measured geometry rather than a fragile viewport-only breakpoint. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 1010a537a358. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Merged via squash.
|
The multiline restructure dropped the .session-progress-card--dock placement shipped in #129141 and left the completed marker inside the collapsed-only summary span, so it vanished when the disclosure opened. Restore the dock positioning block and hoist the marker into the always-visible summary grid.
…124301) * improve(control-ui): align composer stack with current main * refactor(ui): isolate new-session permission state * fix(ui): close composer CI regressions * test(ui): align composer presentation contracts * test(ui): fix composer browser contracts * test(ui): stabilize composer browser ownership * test(ui): target presented mobile composer * test(ui): select accessible mobile composer * test(ui): open mobile rail session directly * fix(ui): keep mobile composer content laid out * fix(ui): address composer review findings * fix(ui): close composer interaction gaps * fix(ui): bound swarm task popover * fix(ui): restore progress-card docking beside the wide composer The multiline restructure dropped the .session-progress-card--dock placement shipped in #129141 and left the completed marker inside the collapsed-only summary span, so it vanished when the disclosure opened. Restore the dock positioning block and hoist the marker into the always-visible summary grid. * fix(ui): bound swarm task popover by its composer anchor The popover capped its height against the raw viewport, so on short mobile viewports its top rendered above the screen. Register the swarm group with the existing composer popover anchor observer and consume the measured --chat-composer-popover-max-height, keeping the viewport calc only as fallback. The new actual-tree mobile regression failed with -71px top clipping before the fix. * fix(ui): restore Draft capability controls and split the new-session composer Restores the Draft option and selected-state indicators the capability menu lost in the restructure, and moves the capability/visibility controls into composer-capability-controls.ts so composer.ts drops back under the 700-line lint gate (677 lines) without a suppression. * test(ui): prove permission-mode final effect before session creation Adds mocked-gateway proof that an admin's Full selection reaches sessions.create as permissionMode:"full" exactly once, and that a write-scoped operator's retained Full selection is rejected before creation with a visible status notice and zero create requests. Also aligns the mobile footer reading-order assertion with the shipped attachments-draft-model order. * test(ui): register swarm popover layout test as node-driven chat-swarm-progress.browser.test.ts drives its own Playwright chromium from node, but d3396c4 added it without registering it in nodeDrivenBrowserLayoutTests, so the browser-mode chromium project tried to fetch it into the page and failed on the node-only playwright import. This was the deterministic checks-ui failure on both prior heads. * test(ci): register codex attempt-startup-retry in its support lane #129505 added extensions/codex/src/app-server/attempt-startup-retry.test.ts without lane ownership, so the full-suite coverage guard (test/vitest-projects-config.test.ts) fails on every full run. Register it beside attempt-startup.test.ts in the attempt-support lane. * test(ui): expect last-activity suffix in composer summary label Merge weave: #129520 appends the accessible last-activity to the summary aria-label; align the restructured composer card's assertion with it. --------- Co-authored-by: Peter Steinberger <[email protected]>
…claw#129141) * feat(ui): dock the session progress card beside a wide composer The progress card had two placements: the companion rail when that side panel is open, otherwise a collapsed one-line bar stacked inside the composer box. On a wide chat the composer stays centered at the transcript width, so the space either side of it sits empty while the card is squeezed into the composer. Add a third placement. When the measured free gutter beside the composer is at least 280px, the card docks into it with its full checklist expanded; below that it falls back to the existing composer bar, and an open companion rail still wins. Exactly one placement renders at a time, now expressed as a closed {card, placement} prop so the composer bar and the dock cannot both draw the same card. The gutter is measured from the DOM by a small ResizeObserver controller rather than derived from the pane width: the transcript width is a browser-local setting in arbitrary CSS units, and an open side panel shrinks the conversation column without changing the pane. The dock is positioned absolutely in that gutter, so the transcript and composer never shift when a card appears or is dismissed, and its inline-start edge repeats the composer's own half-width formula through a shared --chat-composer-side-inset token so the two stay in agreement. * fix(ui): keep the new-session composer sized outside the chat surface The composer shell tokens are declared on .chat, but the new-session page reuses .agent-chat__composer-shell outside it. There the var() had no value, so the whole width declaration was invalid and dropped, and the composer stretched full-width instead of holding its 48rem centered box. Give both tokens their literal fallback at the use site, matching the neighbouring --chat-thread-max-width. The custodian surface was already immune because it overrides width outright. Caught by ui/src/e2e/new-session-page.places.e2e.test.ts, which is the regression test for this: it failed on the previous head and passes now.
…penclaw#124301) * improve(control-ui): align composer stack with current main * refactor(ui): isolate new-session permission state * fix(ui): close composer CI regressions * test(ui): align composer presentation contracts * test(ui): fix composer browser contracts * test(ui): stabilize composer browser ownership * test(ui): target presented mobile composer * test(ui): select accessible mobile composer * test(ui): open mobile rail session directly * fix(ui): keep mobile composer content laid out * fix(ui): address composer review findings * fix(ui): close composer interaction gaps * fix(ui): bound swarm task popover * fix(ui): restore progress-card docking beside the wide composer The multiline restructure dropped the .session-progress-card--dock placement shipped in openclaw#129141 and left the completed marker inside the collapsed-only summary span, so it vanished when the disclosure opened. Restore the dock positioning block and hoist the marker into the always-visible summary grid. * fix(ui): bound swarm task popover by its composer anchor The popover capped its height against the raw viewport, so on short mobile viewports its top rendered above the screen. Register the swarm group with the existing composer popover anchor observer and consume the measured --chat-composer-popover-max-height, keeping the viewport calc only as fallback. The new actual-tree mobile regression failed with -71px top clipping before the fix. * fix(ui): restore Draft capability controls and split the new-session composer Restores the Draft option and selected-state indicators the capability menu lost in the restructure, and moves the capability/visibility controls into composer-capability-controls.ts so composer.ts drops back under the 700-line lint gate (677 lines) without a suppression. * test(ui): prove permission-mode final effect before session creation Adds mocked-gateway proof that an admin's Full selection reaches sessions.create as permissionMode:"full" exactly once, and that a write-scoped operator's retained Full selection is rejected before creation with a visible status notice and zero create requests. Also aligns the mobile footer reading-order assertion with the shipped attachments-draft-model order. * test(ui): register swarm popover layout test as node-driven chat-swarm-progress.browser.test.ts drives its own Playwright chromium from node, but d3396c4 added it without registering it in nodeDrivenBrowserLayoutTests, so the browser-mode chromium project tried to fetch it into the page and failed on the node-only playwright import. This was the deterministic checks-ui failure on both prior heads. * test(ci): register codex attempt-startup-retry in its support lane openclaw#129505 added extensions/codex/src/app-server/attempt-startup-retry.test.ts without lane ownership, so the full-suite coverage guard (test/vitest-projects-config.test.ts) fails on every full run. Register it beside attempt-startup.test.ts in the attempt-support lane. * test(ui): expect last-activity suffix in composer summary label Merge weave: openclaw#129520 appends the accessible last-activity to the summary aria-label; align the restructured composer card's assertion with it. --------- Co-authored-by: Peter Steinberger <[email protected]>
What Problem This Solves
On a wide chat window the composer stays centered at the transcript width, leaving a large empty gutter on either side. The session progress card ignored that space: unless the companion side panel happened to be open, the card was squeezed into a collapsed one-line bar inside the composer box, so an active plan showed only its current step and a
1/5counter. Operators watching a long-running run had to expand the bar, or open an unrelated side panel, to see the checklist that space was already there to hold.Why This Change Was Made
The card gains a third placement. When the free gutter beside the composer is wide enough (at least 280px, leaving the card ~250px), it docks there with the full checklist expanded; below that it falls back to the existing composer bar, and an open companion rail still wins. Exactly one placement renders at a time — that invariant is now expressed as a closed
{ card, placement }prop, so the composer bar and the dock cannot both draw the same card."Wide enough" is measured from the DOM by a small
ResizeObservercontroller rather than derived from the pane width. Two things make a width breakpoint wrong here: the transcript width is a browser-local setting that accepts arbitrary CSS (48rem,82%, acalc()), and an open side panel shrinks the conversation column without changing the pane at all. The dock is positioned absolutely inside that gutter, so the transcript and composer never shift when a card appears or is dismissed, and its inline-start edge repeats the composer's own half-width formula through a shared--chat-composer-side-insettoken so the two cannot drift apart.Non-goals: the narrow and companion-rail placements are unchanged, and no new setting is introduced.
User Impact
On a wide chat, an active progress card now sits beside the composer showing every step and its status at a glance, instead of a single collapsed line inside the input box. Narrow windows, split view, and the side-panel layout look and behave exactly as before. Nothing to configure — the layout follows the space available.
Evidence
Before/after screenshots below: the card docked at 1600px wide, and the unchanged narrow fallback at 560px. Both captured from the real Control UI by the e2e run.
ui/src/e2e/session-progress-live-placement.e2e.test.tsnow asserts all three placements in one pass (1600 wide / 1280 with the side panel open / 560), including geometry: the dock starts past the composer's right edge and their bottom edges agree within 1px. 3/3 passing.node scripts/check-changed.mjs: exit 0 (guards, dead-export scan, i18n, typecheck core+UI, oxlint, stylelint, format).pnpm test ui/src/pages/chat/chat-responsive.browser.test.ts: 93/93 passing — composer geometry across the viewport ladder is unaffected.gpt-5.6-sol, high reasoning, single pass over the full bundle): no accepted or actionable findings.Production LOC: +175/-26 (net +149) | Tests: +28/-0 | Docs: +3/-2. Roughly half the production growth is the new measurement controller (75 lines, a third of them the comments explaining why the gutter is measured rather than assumed) and the dock's CSS block; the placement decision itself replaced a boolean with a three-value union rather than adding a parallel flag.