Skip to content

refactor(ui): unify chat icon buttons on one borderless design and align top chrome rows#104574

Merged
steipete merged 2 commits into
mainfrom
claude/unified-button-design-8166b7
Jul 11, 2026
Merged

refactor(ui): unify chat icon buttons on one borderless design and align top chrome rows#104574
steipete merged 2 commits into
mainfrom
claude/unified-button-design-8166b7

Conversation

@steipete

@steipete steipete commented Jul 11, 2026

Copy link
Copy Markdown
Contributor

What Problem This Solves

The Control UI chat surface rendered its session icon buttons in two different designs: split-pane headers used borderless ghost icons while the single-pane floating toggles used boxed buttons with a border, panel fill, and shadow. On top of that, the top chrome rows sat on three different centerlines — sidebar brand icons at y≈29, floating toggles at y≈24, pane-header actions at y≈18 — so the sidebar buttons never lined up with the buttons on the right.

Why This Change Was Made

Unify on one borderless compact icon-button design and one shared chrome centerline:

  • The variant: "pane-header" | "floating" parameter is removed from renderSessionDiffToggle / renderBackgroundTasksToggle / renderSessionWorkspaceToggle; every chat icon button now renders btn btn--ghost btn--icon chat-icon-btn, with the per-variant chrome classes (chat-workspace-open, chat-tasks-open, chat-diff-open) deleted and one shared .chat-icon-btn sizing rule replacing the .chat-pane__actions .btn--icon override.
  • All three top rows now center on the same 24px line: the sidebar brand row (logo + wordmark + actions move together, so the OpenClaw wordmark stays centered with its icons), the floating toggle row, and split-pane headers (36px → 48px, matching the single-pane titlebar band height). The settings sidebar back button mirrors the same shift.
  • Scrolled thread content passes under the floating toggles; since the ghost buttons carry no chrome, the row gets a subtle frosted wash (translucent --bg + blur, no border/shadow) that is invisible over the empty titlebar band but keeps icons legible over text.

User Impact

Sidebar header buttons, split-pane header actions, and the floating toggles now share one borderless design and one centerline across the top of the shell, in light and dark themes. No white boxed buttons in light mode. No behavior changes; all actions, badges, tooltips, and the narrow-viewport tasks-toggle hiding work as before. The macOS app's 50px titlebar clearance overrides are untouched.

Evidence

Verified in the mock dev harness (pnpm dev:ui:mock), light and dark themes:

  • Split view: all 6 pane-header actions render identical ghost 28×28 buttons; buttons center at y=23.5–24 in the 48px header.
  • Sidebar brand icons, wordmark, and logo all center at y=24; floating toggles center at y=24 (measured via getBoundingClientRect, Δ ≤ 0.5px).
  • Scrolled thread under the floating row: icons stay legible on the frosted wash; no boxed look.
  • Dark theme picks up the dark --bg wash and ghost hover states; no console errors.
  • Settings sidebar back button: 32px control in an 8px-top-padded header → same 24px centerline (the mock harness only serves /chat, so this one is by construction, mirroring the verified brand-row math).

Test selectors that targeted the removed chat-workspace-open class now use the shared chat-workspace-toggle class (ui/src/e2e/chat-flow.e2e.test.ts, ui/src/pages/chat/chat-view.test.ts).

@openclaw-barnacle openclaw-barnacle Bot added app: web-ui App: web-ui size: S maintainer Maintainer-authored PR labels Jul 11, 2026
@clawsweeper clawsweeper Bot added 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. P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. 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 11, 2026, 1:33 PM ET / 17:33 UTC.

Summary
The PR removes layout-specific chat-toggle variants, applies one shared borderless 28px icon-button treatment, aligns the chat and sidebar chrome rows to a 24px centerline, adds a frosted backdrop behind floating toggles, and updates affected test selectors.

PR surface: Source -5, Tests 0. Total -5 across 9 files.

Reproducibility: not applicable. the PR addresses a source-visible visual inconsistency rather than a broken functional contract; current main clearly contains the two presentation variants.

Review metrics: none identified.

Merge readiness
Overall: 🐚 platinum hermit
Proof: 🐚 platinum hermit
Patch quality: 🐚 platinum hermit
Result: ready for maintainer review.

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

Rank-up moves:

  • none.

Next step before merge

  • No automated repair is needed; this protected active PR is ready for ordinary maintainer review, including closing the obsolete boxed-chrome thread if the borderless direction is accepted.

Security
Cleared: The focused UI template, selector, and CSS patch introduces no dependency, permission, secret, package-resolution, downloaded-code, or execution-path change.

Review details

Best possible solution:

Keep one shared borderless 28px chat icon-button path with semantic action classes, row-level contrast treatment for floating controls, the existing responsive hiding rules, and host-owned macOS titlebar clearance.

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

Not applicable: the PR addresses a source-visible visual inconsistency rather than a broken functional contract; current main clearly contains the two presentation variants.

Is this the best way to solve the issue?

Yes. Removing the layout variant parameter and centralizing sizing and chrome is the narrowest maintainable solution, while semantic selectors, action handlers, responsive behavior, badges, accessibility attributes, and native clearance remain with their existing owners.

AGENTS.md: found and applied where relevant.

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

Label changes

Label changes:

  • add proof: sufficient: Contributor real behavior proof is sufficient. The updated PR body records an after-fix mock-harness run in light and dark themes with measured centerlines, scrolled-content contrast, preserved actions, and no console errors; native clearance is separately source- and test-backed.

Label justifications:

  • P3: This is a focused visual-consistency cleanup with no intended functional, configuration, persistence, or upgrade behavior change.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (live_output): The updated PR body records an after-fix mock-harness run in light and dark themes with measured centerlines, scrolled-content contrast, preserved actions, and no console errors; native clearance is separately source- and test-backed.
  • proof: sufficient: Contributor real behavior proof is sufficient. The updated PR body records an after-fix mock-harness run in light and dark themes with measured centerlines, scrolled-content contrast, preserved actions, and no console errors; native clearance is separately source- and test-backed.
Evidence reviewed

PR surface:

Source -5, Tests 0. Total -5 across 9 files.

View PR surface stats
Area Files Added Removed Net
Source 7 47 52 -5
Tests 2 5 5 0
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 9 52 57 -5

What I checked:

  • Current main still has the mismatch: Current main retains the pane-header/floating toggle parameter, boxed floating-only classes, 36px pane headers, and older sidebar offsets, so the central cleanup is not already implemented. (ui/src/pages/chat/components/chat-session-workspace.ts:706, e68669373280)
  • Prior review premise was superseded: The second commit deliberately changes the first commit's boxed treatment to ghost buttons, removes per-button chrome, adds the row-level frosted wash, tightens spacing, and aligns the top chrome rows; the unresolved request to restore boxes no longer matches the amended PR body or head. (ui/src/styles/chat/sidebar.css:65, fc1161677153)
  • Native app ownership is preserved: The macOS host injects a 50px minimum top padding for both .sidebar-shell and .settings-sidebar__header, so the browser alignment changes do not remove native titlebar clearance. (apps/macos/Sources/OpenClaw/DashboardWindowController.swift:657, fc1161677153)
  • Native override has focused coverage: The dashboard smoke test checks that the injected chrome script includes both sidebar selectors and the native titlebar-height variable. (apps/macos/Tests/OpenClawIPCTests/DashboardWindowSmokeTests.swift:460, fc1161677153)
  • Exact-head checks are green: GitHub reports successful checks-ui, lint, production/test type checks, build artifacts, real behavior proof, and security guard jobs for the reviewed head. (fc1161677153)

Likely related people:

  • steipete: Merged history shows repeated ownership of the Control UI chat rendering, pane, and layout boundary, including split-renderer and chat-shell work, beyond authorship of this PR. (role: feature owner; confidence: high; commits: 1acbd6aea048, d5ffc672dd32, 478a543e2ef5; files: ui/src/pages/chat/chat-view.ts, ui/src/pages/chat/chat-pane.ts, ui/src/styles/chat/sidebar.css)
  • qingminlong: Current-main blame ties the latest floating-toggle, workbench, split-pane, and macOS native-chrome implementation snapshot to this commit, making the author relevant to the behavior being refactored. (role: recent area contributor; confidence: medium; commits: a66d2959e956; files: ui/src/styles/chat/sidebar.css, ui/src/pages/chat/components/chat-session-workspace.ts, ui/src/pages/chat/chat-pane.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 (2 earlier review cycles)
  • reviewed 2026-07-11T17:12:45.612Z sha f60217c :: needs real behavior proof before merge. :: none
  • reviewed 2026-07-11T17:19:23.647Z sha f60217c :: needs real behavior proof before merge. :: none

@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: fc11616771

ℹ️ 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".

Sizing only — chrome stays ghost; .btn--icon's 36px min-width/height would
win otherwise. The floating row sits in the thread's reserved titlebar band
(never over content), so it needs no backdrop of its own. */
.chat-icon-btn {

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 Restore boxed chrome on shared chat icon buttons

When these controls render in either the split-pane header or the floating toggle cluster, the callers now give them btn--ghost, and the global ghost button rule clears the border/background. This new .chat-icon-btn rule only restores sizing, so the floating buttons lose the per-button border/panel/shadow they had before and the pane header still doesn't get the compact boxed affordance this refactor is meant to unify on; put the boxed chrome on the shared rule or stop using the ghost variant for these buttons.

Useful? React with 👍 / 👎.

@clawsweeper clawsweeper Bot added the proof: sufficient ClawSweeper judged the real behavior proof convincing. label Jul 11, 2026
@steipete steipete changed the title refactor(ui): unify chat icon buttons on the compact boxed design refactor(ui): unify chat icon buttons on one borderless design and align top chrome rows Jul 11, 2026
@steipete
steipete merged commit 49ff54e into main Jul 11, 2026
97 checks passed
@steipete
steipete deleted the claude/unified-button-design-8166b7 branch July 11, 2026 17:38
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Jul 12, 2026
…ign top chrome rows (openclaw#104574)

* refactor(ui): unify chat icon buttons on the compact boxed design

* refactor(ui): keep chat icon buttons borderless and align top chrome rows
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 maintainer Maintainer-authored PR P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: S 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.

1 participant