Skip to content

fix(ui): keep rewind confirmation controls accessible - #133791

Merged
steipete merged 2 commits into
mainfrom
codex/fix-chat-confirmation-css-budget
Aug 31, 2026
Merged

steipete merged 2 commits into
mainfrom
codex/fix-chat-confirmation-css-budget

Conversation

@steipete

@steipete steipete commented Aug 31, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Opening Rewind from a message context menu places its confirmation below the still-connected menu, which intercepts pointer actions. Clicking the dialog's checkbox also bubbles to the menu's outside-click handler and removes both owners. Separately, repeated theme selectors leave the current UI bundle 25 compressed bytes over its existing CSS limit, failing build and test-runtime CI jobs.

Why This Change Was Made

Keep the confirmation portaled into the document body above its menu and contain its bubbling clicks at the dialog owner. Direct Cancel/Confirm handlers, checkbox activation, capture-phase dismissal, Escape, and cleanup remain intact. Cancel retains the menu and restores focus to its Rewind control.

Factor identical confirmation-button theme selectors while preserving all theme membership, declarations, specificity and source order. Attachment styles remain in the boot bundle for first-use offline rendering. Performance budgets are unchanged.

User Impact

Rewind confirmation controls are clickable and its preference checkbox no longer dismisses the dialog. The theme colors remain unchanged, and CI can build the UI within the existing budget.

Evidence

The unchanged baseline failed a real mocked-app pointer interaction, and the extended existing archived-actions E2E failed when checking the checkbox before production edits. The baseline canonical UI build reproduced 54,809 CSS gzip bytes against a 54,784-byte limit. The candidate full build passes at 54,758 bytes, saving 51 bytes without changing the limit; finalized sidecar verification also passes.

The built-app archived-actions E2E passes all three existing desktop, mobile, and cold-archive cases. The extended case now checks preference toggling, Cancel without an RPC, retained menu/focus, reopening, and the original archived-session inertness behavior. The focused confirmation unit selection passes 18 tests; all five contrast tests pass.

Real browser interactions against the synthetic Gateway fixture compare 24 normal/hover theme states before and after: computed paint values match exactly. The repaired context-menu flow also verifies preference toggling, Cancel, one correctly addressed rewind RPC on confirmation, and restored draft text. This is local browser proof with a synthetic Gateway, not an authenticated external-provider session.

The required changed-file gate passes formatting, dead exports, i18n verification, core-test/UI types, lint and style checks. Independent Codex review is scoped-clean at its configured P0 threshold. Production is +32/-30 (net +2 for the dialog-owned event boundary), tests +13/-0; no changelog diff. No test cases were added.

Provenance: the failure is reproduced on the current baseline. The exact commit that first crossed the CSS budget is unknown; the repair preserves the existing attachment boot-loading fix.

Screenshots

Synthetic captures of the same context-menu confirmation, before and after. The original capture shows the menu covering the buttons; the repaired capture shows the accessible controls.

Before After
Menu obscures confirmation controls Confirmation controls accessible

Review follow-up

Removed the direct changelog entry requested by the completed ClawSweeper review. Release-note context stays in this body for release generation. The UI source and E2E files are byte-identical to the originally validated commit; the follow-up changes only that changelog line.

@clawsweeper

clawsweeper Bot commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

@openclaw-barnacle openclaw-barnacle Bot added app: web-ui App: web-ui size: S maintainer Maintainer-authored PR labels Aug 31, 2026
@steipete
steipete marked this pull request as ready for review August 31, 2026 04:28
@clawsweeper clawsweeper Bot added merge-risk: 🚨 other 🚨 Merging this PR has meaningful risk outside the owned taxonomy. P2 Normal backlog priority with limited blast radius. 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 Aug 31, 2026
@clawsweeper

clawsweeper Bot commented Aug 31, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed August 31, 2026, 1:05 AM ET / 05:05 UTC.

ClawSweeper review

What this changes

This PR keeps the Rewind confirmation dialog usable over its message context menu, adds browser coverage for checkbox and cancel interaction, and consolidates equivalent theme selectors.

Merge readiness

⚠️ Ready for maintainer review - 2 items remain

Keep open. The prior changelog finding is resolved, and no introduced correctness or security defect was found; current main and v2026.8.1 do not contain this repair. Exact-head CI is still in progress.

Priority: P2
Reviewed head: e3c93f8dd99130916e01252d748c371c9bf123ba

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) The focused owner-boundary repair and behavior-level coverage are sound; exact-head CI remains the normal merge gate.
Proof confidence 🌊 off-meta tidepool Not applicable: This MEMBER-authored Control UI PR is exempt from the external-contributor proof gate; the body additionally supplies stated browser-fixture evidence and linked before/after captures, which this read-only review did not execute or download.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: This MEMBER-authored Control UI PR is exempt from the external-contributor proof gate; the body additionally supplies stated browser-fixture evidence and linked before/after captures, which this read-only review did not execute or download.
Evidence reviewed 5 items Causal event path: The Rewind action retains its context menu while opening the portaled confirmation; the menu's document-level bubble listener otherwise removes the menu for a target outside it. The introduced dialog listener stops only those bubbled in-dialog clicks.
Overlay ordering: Both the context menu and confirmation are direct body children; the menu uses z-index 9999 and the introduced confirmation value is 10000, placing the dialog above the pointer-intercepting menu.
Behavior-level regression coverage: The introduced browser E2E checks preference interaction, Cancel without a rewind request, retained menu and focus, and reopening the confirmation across its configured viewports.
Findings None None.
Security None None.

How this fits together

The Control UI opens Rewind from a message context menu, then shows a portaled confirmation before sending a session rewind request to the Gateway. The confirmation must remain above the menu and not let its internal clicks dismiss that menu.

flowchart LR
  A[Message context menu] --> B[Rewind action]
  B --> C[Confirmation dialog]
  C --> D{Cancel or confirm}
  D -->|Cancel| E[Restore menu focus]
  D -->|Confirm| F[Gateway rewind request]
Loading

Before merge

  • Resolve merge risk (P1) - Exact-head CI remains in progress, so this source review is not a merge-readiness attestation.
  • Complete next step (P2) - No repair lane is needed: the prior review finding was addressed and the remaining action is ordinary exact-head CI completion.
Agent review details

Security

None.

PR surface

Source +2, Tests +13. Total +15 across 3 files.

View PR surface stats
Area Files Added Removed Net
Source 2 32 30 +2
Tests 1 13 0 +13
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 3 45 30 +15

Review metrics

Metric Value Why it matters
Production versus test delta production +2/-0 net +2; tests +13/-0; CSS +30/-30 The only production growth is the dialog-owned event boundary; the CSS change is a net-neutral selector consolidation.

Merge-risk options

Maintainer options:

  1. Decide the mitigation before merge
    Keep the portal-local event boundary and explicit overlay ordering, with the browser regression test protecting the retained-menu cancellation flow; land after exact-head checks complete successfully.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Technical review

Best possible solution:

Keep the portal-local event boundary and explicit overlay ordering, with the browser regression test protecting the retained-menu cancellation flow; land after exact-head checks complete successfully.

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

Yes. Source establishes that the body-portaled dialog is outside the menu checked by its bubble-phase document click handler, and the submitted browser E2E exercises that exact interaction; this read-only review did not execute it.

Is this the best way to solve the issue?

Yes. Stopping only dialog-originated bubbled clicks at the portaled dialog owner fixes the ownership mismatch without weakening capture-phase dismissal or direct Cancel and Confirm handling.

AGENTS.md: found and applied where relevant.

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

Labels

Label justifications:

  • P2: This is a bounded existing Control UI interaction defect with a focused repair.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: This MEMBER-authored Control UI PR is exempt from the external-contributor proof gate; the body additionally supplies stated browser-fixture evidence and linked before/after captures, which this read-only review did not execute or download.

Evidence

What I checked:

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • Vincent Koc: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

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 (1 earlier review cycle)
  • reviewed 2026-08-31T04:36:22.766Z sha 84b2e4c :: found issues before merge. :: [P2] Remove the release-owned changelog entry

@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. merge-risk: 🚨 other 🚨 Merging this PR has meaningful risk outside the owned taxonomy. labels Aug 31, 2026
@steipete
steipete merged commit 0ee6e05 into main Aug 31, 2026
160 of 162 checks passed
@steipete
steipete deleted the codex/fix-chat-confirmation-css-budget branch August 31, 2026 05:22
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 1, 2026
* fix(ui): keep rewind confirmation controls accessible

* chore: leave rewind release notes to changelog generation
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 P2 Normal backlog priority with limited blast radius. 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