Skip to content

fix(ui): dashboard widgets leave a gap below content and hover chrome blocks widget buttons - #114012

Merged
steipete merged 3 commits into
mainfrom
steipete/widget-sizing-hover-title-3c1825
Jul 26, 2026
Merged

steipete merged 3 commits into
mainfrom
steipete/widget-sizing-hover-title-3c1825

Conversation

@steipete

Copy link
Copy Markdown
Contributor

What Problem This Solves

Fixes two dashboard widget problems reported from live use of the session dashboard (chat Dashboard tab / board pages):

  1. Auto-sized HTML widgets showed a dead gap beneath their content. The widget reported its exact content height, but the card was rounded up to the next 56px grid row and stretched to fill the whole cell, so up to ~67px of empty card interior appeared under the content.
  2. Hovering a widget revealed a full-width, mostly opaque title bar over the top of the widget. It visually buried widget-owned top-row controls, and its right-side cluster (capabilities chip + menu) actively stole clicks from the corner where widgets typically place their own actions (e.g. a Refresh button).

Why This Change Was Made

The grid cell stays quantized to rows (drag/resize math untouched), but the card now hugs its exact reported content height (height: <content+chrome>px; align-self: start) so the ceil-to-row slack lands outside the card as ordinary background spacing. During move/resize gestures the card re-fills its cell so users manipulate the rect they actually commit; at the 20-row cap it fills the cell and clips as before; widgets that never report a height behave exactly as today.

The hover chrome is now a compact interactive top-left pill (drag handle, title, kind chip, capabilities, menu) instead of a full-width strip. It hard-reserves a >=96px widget-owned top-right action region via max-width: max(88px, calc(100% - 96px)), every flexible child shrinks inside the cap so nothing can carry pointer targets into the reserved corner, and a 350ms hover-intent delay keeps chrome from flashing in during quick clicks into content. Keyboard focus, open menus, and drags still reveal chrome immediately. Coarse-pointer layouts keep the existing in-flow 38px bar unchanged.

True "pointer near top edge" proximity reveal is not possible over the cross-origin widget iframe (the host receives no pointer coordinates); forwarding proximity hints through the trusted widget bridge script is a possible follow-up.

User Impact

  • Auto-height widgets fit their content exactly; no more dead space inside cards.
  • Widget-owned top-right buttons stay visible and clickable while host chrome is revealed.
  • Hover chrome appears with intent (350ms) instead of instantly on any pass-through.
  • Touch layouts are unaffected.

Evidence

  • ui/src/lib/board/grid.test.ts, board-view-sizing.test.ts, board-view.test.ts: 67/67 pass locally (includes new exactBoardWidgetHeightPx unit coverage and a DOM test that a size report pins the exact height and re-fills while dragging).
  • board-view.browser.test.ts in real Chromium: 14/14 pass, including new assertions for pill geometry, the 324px content hug, and a narrow long-titled widget keeping a >=88px reserved top-right region with no child overflow.
  • Verified live in the mock harness (pnpm dev:ui:mock --fixture board): the size-reporting widget hugs at 170px inside its 192px cell; hover shows the top-left pill with the widget's own top-right area clear.
  • Codex autoreview (gpt-5.6-sol): round 1 found the pill-width interception risk, fixed with the reserved-corner cap + shrink rules and a dedicated Chromium test; round 2's remaining note (30px pill vs 38px coarse chrome constant) was verified factually incorrect — the 30px height is overlay-only, coarse pointers keep the base 38px grid row — and documented with an inline comment.

@openclaw-barnacle openclaw-barnacle Bot added app: web-ui App: web-ui size: M maintainer Maintainer-authored PR labels Jul 26, 2026
@steipete
steipete marked this pull request as ready for review July 26, 2026 04:09
@clawsweeper clawsweeper Bot added proof: sufficient ClawSweeper judged the real behavior proof convincing. 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. P2 Normal backlog priority with limited blast radius. labels Jul 26, 2026
@clawsweeper

clawsweeper Bot commented Jul 26, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed July 26, 2026, 12:50 AM ET / 04:50 UTC.

ClawSweeper review

What this changes

The PR makes auto-sized dashboard widget cards hug their reported content height and replaces the desktop full-width hover bar with a delayed compact control pill that preserves widget-owned top-right actions.

Merge readiness

⚠️ Ready for maintainer review - 1 item remains

Keep this PR open for maintainer handling: its latest commit directly addresses the prior narrow-card action-corner finding, and the supplied Chromium plus live mock-harness evidence is specific to the changed dashboard behavior. No new concrete patch defect surfaced; the maintainer label prevents automated cleanup.

Priority: P2
Reviewed head: 2928cbfd6f1bffee1d79a2d6aeee7fc09a1fa38e

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused UI repair with relevant browser and live harness proof; the prior concrete layout blocker appears addressed at the latest head.
Proof confidence 🦞 diamond lobster (5/6) Sufficient (live_output): The PR body supplies after-fix real behavior evidence from a Chromium browser run and a live mock-board harness, with concrete content-height and action-corner observations.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Verified Sufficient (live_output): The PR body supplies after-fix real behavior evidence from a Chromium browser run and a live mock-board harness, with concrete content-height and action-corner observations.
Evidence reviewed 5 items Latest narrow-card repair: The latest PR commit changes the desktop pill’s narrow-widget behavior after the previous review identified that the 88px minimum could consume the reserved action corner below 184px. The updated board stylesheet documents stripping the pill to the irreducible move/menu controls at that threshold.
Height-rendering boundary: The branch forwards every changed HTML-widget size report into the cell and calculates an exact rendered card height separately from the grid-row span, preserving quantized placement while moving unused row slack outside the card.
Sizing contract and coverage: The branch separates auto content height from effectiveBoardWidgetRows, caps exact height at the grid span, and adds unit and browser-layout coverage for content hugging, drag refill, and narrow long-title pill geometry.
Findings None None.
Security None None.

How this fits together

Dashboard HTML widgets report their content height from their iframe to the board view. The grid still uses quantized rows for placement, while each widget card can render at its exact content height and desktop hover controls are overlaid without covering widget actions.

flowchart LR
  A[HTML widget iframe] --> B[Content-height report]
  B --> C[Board view state]
  C --> D[Quantized grid cell]
  C --> E[Exact card-height calculation]
  F[Desktop hover or focus] --> G[Compact control pill]
  D --> H[Rendered dashboard widget]
  E --> H
  G --> H
Loading

Before merge

  • Complete next step (P2) - No mechanical repair remains from this review; the protected maintainer label leaves final merge ownership with a human reviewer.
Agent review details

Security

None.

PR surface

Source +90, Tests +107. Total +197 across 7 files.

View PR surface stats
Area Files Added Removed Net
Source 4 127 37 +90
Tests 3 121 14 +107
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 7 248 51 +197

Review metrics

None.

Technical review

Best possible solution:

Preserve the current split between quantized grid placement and exact card rendering, and land the updated narrow-card pill behavior after maintainer review at the actual merge head; do not alter touch-bar or drag/resize semantics.

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

Yes, from source and the submitted browser coverage: an auto-height HTML widget in the dashboard exercises the exact-height path, while a narrow long-titled widget exercises the desktop hover-pill reservation. This review did not execute the browser harness itself.

Is this the best way to solve the issue?

Yes, based on the patch and stated proof: preserving the quantized cell for drag/resize while sizing only the card to reported content is narrower than changing grid geometry, and the latest CSS specifically repairs the earlier narrow-card overlap concern.

AGENTS.md: found and applied where relevant.

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

Labels

Label changes:

  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (live_output): The PR body supplies after-fix real behavior evidence from a Chromium browser run and a live mock-board harness, with concrete content-height and action-corner observations.
  • remove rating: 🦐 gold shrimp: Current PR rating is rating: 🐚 platinum hermit, so this older rating label is no longer current.
  • remove status: ⏳ waiting on author: Current PR status label is status: 👀 ready for maintainer look.

Label justifications:

  • P2: This is a bounded dashboard-widget layout and interaction fix with clear user friction but no demonstrated data, security, delivery, or availability impact.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster 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 PR body supplies after-fix real behavior evidence from a Chromium browser run and a live mock-board harness, with concrete content-height and action-corner observations.
  • proof: sufficient: Contributor real behavior proof is sufficient. The PR body supplies after-fix real behavior evidence from a Chromium browser run and a live mock-board harness, with concrete content-height and action-corner observations.

Evidence

What I checked:

  • Latest narrow-card repair: The latest PR commit changes the desktop pill’s narrow-widget behavior after the previous review identified that the 88px minimum could consume the reserved action corner below 184px. The updated board stylesheet documents stripping the pill to the irreducible move/menu controls at that threshold. (ui/src/styles/board.css, 2928cbfd6f1b)
  • Height-rendering boundary: The branch forwards every changed HTML-widget size report into the cell and calculates an exact rendered card height separately from the grid-row span, preserving quantized placement while moving unused row slack outside the card. (ui/src/components/board/board-view.ts, 421a88ada558)
  • Sizing contract and coverage: The branch separates auto content height from effectiveBoardWidgetRows, caps exact height at the grid span, and adds unit and browser-layout coverage for content hugging, drag refill, and narrow long-title pill geometry. (ui/src/lib/board/grid.ts, 421a88ada558)
  • Real behavior proof: The PR body reports a real Chromium browser run and a live mock-board harness showing a height-reporting widget hugging its content while its top-right action area remains clear. This is directly relevant after-fix proof for the UI behavior. (ui/src/components/board/board-view.browser.test.ts, 2928cbfd6f1b)
  • Review continuity: The previous ClawSweeper review at bb185e3 identified the sub-184px reservation problem; the current head adds a focused follow-up commit explicitly for narrow widgets, so that prior finding is not re-raised. (ui/src/styles/board.css, 2928cbfd6f1b)

Likely related people:

  • steipete: Authored the focused three-commit repair sequence, including the latest narrow-widget correction and the accompanying board tests; current-main feature-history attribution was not available from the read-only terminal in this review. (role: recent board UI contributor; confidence: medium; commits: 421a88ada558, bb185e30d35b, 2928cbfd6f1b; files: ui/src/components/board/board-view.ts, ui/src/components/board/board-widget-cell.ts, ui/src/lib/board/grid.ts)

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
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.

Workflow

  • 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.

History

Review history (2 earlier review cycles)
  • reviewed 2026-07-26T04:14:07.541Z sha 421a88a :: needs maintainer review before merge. :: none
  • reviewed 2026-07-26T04:38:03.815Z sha bb185e3 :: found issues before merge. :: [P2] Preserve the action corner below the 184px threshold

@openclaw-barnacle openclaw-barnacle Bot added the gateway Gateway runtime label Jul 26, 2026
@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed 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. labels Jul 26, 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. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Jul 26, 2026
@steipete
steipete merged commit 36404ea into main Jul 26, 2026
136 of 142 checks passed
@steipete
steipete deleted the steipete/widget-sizing-hover-title-3c1825 branch July 26, 2026 05:14
@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 26, 2026
… blocks widget buttons (openclaw#114012)

* fix(ui): hug auto widget cards to content and compact board chrome into a top-left pill

* test(gateway): retry temp-dir cleanup in chat abort persistence suite to absorb ENOTEMPTY race

* fix(ui): strip board pill to move and menu on narrow widgets so the action corner stays widget-owned
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 gateway Gateway runtime maintainer Maintainer-authored PR P2 Normal backlog priority with limited blast radius. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary 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.

1 participant