Skip to content

ui: move chat header and panel rail actions onto IconButton - #194151

Merged
vyctorbrzezowski merged 2 commits into
mainfrom
brzezowski/icon-button-rest
Nov 6, 2026
Merged

vyctorbrzezowski merged 2 commits into
mainfrom
brzezowski/icon-button-rest

Conversation

@vyctorbrzezowski

@vyctorbrzezowski vyctorbrzezowski commented Nov 6, 2026 •

Copy link
Copy Markdown
Member

Unifies chat-header and panel-header icon actions on IconButton, retaining the 16px bar glyphs, contextual colors, hover grounds, focus rings, and pressed states. PanelIconButton owns its tooltip; redundant browser and terminal dock wrappers are removed so keyboard tooltips anchor to the button.

Validation: the existing busy/disabled/live-callback test, UI typecheck, scoped typed lint, touched CSS lint, and formatting pass. Natural terminal docking checks pass in Chromium and WebKit for hover, keyboard focus, Escape, and docking. The selected existing test took 43 ms (759 ms Vitest duration); no tests were added. The child replayed cleanly onto main with an equivalent patch; the retained correction review and proof apply. Hosted CI remains pending.

Evidence

Scenario Before After
Panel header ⋯ (Panel position) · hover · 1280 light 01-panel-header-before 02-panel-header-after
Chat header ⋯ · hover · 390 light 05-chat-header-390-before 06-chat-header-390-after
State Screenshot
Panel header ⋯ (Panel position) · hover · 1280 dark 03-panel-header-dark
Panel header ⋯ (Panel position) · hover · 1280 CRT light 04-panel-header-crt

Keyboard tooltip correction

The outer tooltip previously anchored to a zero-size tooltip host. Both pointer hover and native keyboard focus now use the component-owned button anchor.

Before After
Keyboard tooltip at the viewport corner Keyboard tooltip above the focused dock button

@vyctorbrzezowski vyctorbrzezowski self-assigned this Nov 6, 2026
@clawsweeper

clawsweeper Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. labels Nov 6, 2026
@clawsweeper

clawsweeper Bot commented Nov 6, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs changes before merge.

What this changes

This PR moves chat-header and panel-header icon actions onto the shared IconButton styling and component.

Example: Hover the Terminal panel’s ⋯ button on desktop.

  • Before: Only the glyph changes color.
  • After: The button gains the same hover background as neighboring icon controls.

Review scores

Measure Result What it means
Overall readiness 🦪 silver shellfish (2/6) Useful consolidation with direct visual evidence, but consumer integration and validation need repair before merge.
Proof confidence 🦐 gold shrimp (3/6) Real behavior proof is not required for maintainer- or bot-authored pull requests.
Patch quality 🦪 silver shellfish (2/6) 2 actionable review findings remain.

Product

Kind: Refactor · Worth it: Yes · Fix scope: Complete
User problem: Adjacent header actions have inconsistent hover, open-menu, and focus presentation.
Reason: The maintainer-authored direction consolidates presentation in an existing primitive while retaining panel state and action owners.

Merge readiness

⛔ Needs changes before merge - 2 items remain

Keep open: this maintainer-authored PR provides useful visual consistency, but a tooltip integration regression and a diff-caused UI test failure need repair.

Priority: P3
Reviewed head: 080f27a669ba38b5d909fbefabc3000986fdabd8

Before merge

  • Update the busy-state test when adopting IconButton semantics (P2) - Forwarding busy to IconButton changes the true-to-false transition from aria-busy="false" to an omitted attribute. The existing presentation-primitives.test.tsx:168 assertion still requires "false", and checks-ui (1/3) fails on exactly this transition. Update that consumer test to verify the shared non-busy semantics while retaining its disabled-state and current-callback assertions, or preserve the previous attribute contract deliberately.
  • Remove redundant docking tooltip wrappers (P3) - PanelIconButton now creates its own openclaw-tooltip, but Browser HeaderActions and Terminal dock destinations already wrap it in another tooltip. On keyboard focus, focusin reaches both owners; the outer owner selects the inner tooltip as its trigger. That wrapper has display: contents, so overlay-anchor measures an empty rectangle rather than the dock button and can position the tooltip at the viewport origin. Remove the existing outer wrappers so one tooltip owns the actual button.

Findings

  • [P2] Update the busy-state test when adopting IconButton semantics — ui/src/components/solid/panel-icon-button.tsx:26
  • [P3] Remove redundant docking tooltip wrappers — ui/src/components/solid/panel-icon-button.tsx:22

Tests

  • Missing end-to-end proof: Add browser evidence for the newly pressed desktop dock controls and keyboard-focused docking tooltips; no base-red/head-green regression proof accompanies this migration.
Agent review details

How this fits together

Control UI headers render session and panel state as accessible controls whose interactions dispatch to existing layout and panel owners.

flowchart LR
  A[User interaction] --> B[Chat and panel headers]
  B --> C[IconButton]
  D[Shared style tokens] --> C
  C --> E[Existing panel callbacks]
  E --> F[Panel layout state]
  F --> B
Loading

Technical review

Best possible solution:

Keep IconButton as the presentation owner, remove duplicate docking tooltips, and align the existing busy-state test with its shared semantics.

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

The supplied screenshots demonstrate the visual inconsistency, CI reproduces the introduced busy-state test failure, and source traces establish the nested-tooltip path; no target code was executed during review.

Is this the best way to solve the issue?

Reusing IconButton is the smallest complete approach, provided existing consumer contracts and tooltip ownership are migrated together.

Full review comments:

  • [P2] Update the busy-state test when adopting IconButton semantics — ui/src/components/solid/panel-icon-button.tsx:26
    Forwarding busy to IconButton changes the true-to-false transition from aria-busy="false" to an omitted attribute. The existing presentation-primitives.test.tsx:168 assertion still requires "false", and checks-ui (1/3) fails on exactly this transition. Update that consumer test to verify the shared non-busy semantics while retaining its disabled-state and current-callback assertions, or preserve the previous attribute contract deliberately.
    Confidence: 1
  • [P3] Remove redundant docking tooltip wrappers — ui/src/components/solid/panel-icon-button.tsx:22
    PanelIconButton now creates its own openclaw-tooltip, but Browser HeaderActions and Terminal dock destinations already wrap it in another tooltip. On keyboard focus, focusin reaches both owners; the outer owner selects the inner tooltip as its trigger. That wrapper has display: contents, so overlay-anchor measures an empty rectangle rather than the dock button and can position the tooltip at the viewport origin. Remove the existing outer wrappers so one tooltip owns the actual button.
    Confidence: 0.95

Overall correctness: patch is incorrect
Overall confidence: 0.94

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 8dd41fc95291.

Provenance checked

  • Shared panel action primitive changes intended behavior with a stated reason (eca633a: The shared Solid presentation migration preserved existing caller semantics; this PR deliberately changes presentation ownership but leaves one consumer assertion incompatible.)
  • Bare-glyph rail action styling changes intended behavior with a stated reason (c809640: Existing rail CSS supplied unobtrusive glyph-only actions; this PR explicitly replaces their ink-only hover with shared button surfaces.)
  • Desktop chat-header control styling changes intended behavior with a stated reason (fix(ui): unify chat header control shape, fill and chevron spacing #190412: The earlier change unified header control geometry and selected surfaces; this PR moves icon actions to the shared recipe and retains explicit expanded-panel styling.)
  • Panel navigation and retained resources keeps the original intent (fb0ad93: The panel implementation preserves mounted resources, navigation, and layout ownership; the introduced diff retains those callbacks and state owners.)

Testing

Proof path: shipped entry point.

Security

None.

Evidence

Acceptance criteria:

  • pnpm --dir ui test src/components/solid/presentation-primitives.test.tsx
  • pnpm --dir ui test src/components/tooltip.browser.test.ts
  • git diff --check

What I checked:

Likely related people:

  • Vyctor H. Brzezowski: Raw commit debc712 adds ui/src/styles/rail-header.css:18 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: debc7123f743; files: ui/src/styles/rail-header.css)

PR surface

Source -20. Total -20 across 23 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 23 140 160 -20
Tests 0 0 0 0
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 23 140 160 -20

Preflight source

Source unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified.

Labels

Label changes:

  • add P3: This is a visual consistency improvement with limited user impact and focused integration repairs.
  • add rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🦐 gold shrimp and patch quality is 🦪 silver shellfish.
  • add status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action.

Label justifications:

  • P3: This is a visual consistency improvement with limited user impact and focused integration repairs.
  • rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🦐 gold shrimp and patch quality is 🦪 silver shellfish.
  • status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

Reviewed November 6, 2026, 8:55 AM ET / 13:55 UTC.

@vyctorbrzezowski
vyctorbrzezowski force-pushed the brzezowski/icon-button-tables branch from 80f0a2a to ea740f4 Compare November 6, 2026 18:31
Base automatically changed from brzezowski/icon-button-tables to main November 6, 2026 18:42
@vyctorbrzezowski
vyctorbrzezowski force-pushed the brzezowski/icon-button-rest branch from 080f27a to 85be61d Compare November 6, 2026 18:44
@vyctorbrzezowski
vyctorbrzezowski merged commit d261d92 into main Nov 6, 2026
90 of 93 checks passed
@vyctorbrzezowski
vyctorbrzezowski deleted the brzezowski/icon-button-rest branch November 6, 2026 18:51
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 7, 2026
…#194151)

Reuse IconButton for header and panel actions. Keep one tooltip owner per control so keyboard and hover tooltips anchor to the same button while preserving docking behavior and approved sizing.

Co-authored-by: Vyctor H. Brzezowski <[email protected]>
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 P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. size: M status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant