Skip to content

improve(ui): mark error toasts and split two-sentence copy - #192015

Merged
roboclaw-bot merged 14 commits into
mainfrom
brzezowski/toast-center-callers
Nov 4, 2026
Merged

roboclaw-bot merged 14 commits into
mainfrom
brzezowski/toast-center-callers

Conversation

@vyctorbrzezowski

@vyctorbrzezowski vyctorbrzezowski commented Nov 3, 2026 •

Copy link
Copy Markdown
Member

What Problem This Solves

Most error toasts were not marked as errors: they announced politely as role="status" and looked like any other notice. Two-sentence messages ran together as one long title, and the required next step (Review…) looked like any other action.

User Impact

  • About 65 center call sites that report a failure now pass severity: "error", so they show the error icon and announce with role="alert". Copy actions mark only the failure. An agent created whose first message failed is a warning.
  • Two-sentence copy splits into a title and a muted description, without rewording ("File too large." / "Try a smaller file."). The title and description keep a space between them for screen readers and text search.
  • The Review… actions (private draft, pending input, file drafts, queued edit, unsaved settings and channel changes) use the primary fill.

Why This Change Was Made

Third of four stacked PRs for the approved toast design: the center callers.

Evidence

Mock Control UI, Absolutely light, through real flows.

Before and After, a pending message blocking a reload (Review pending input is now primary):

Before: one long title and a plain action After: title, description and a primary action

Before and After, the open center stack: the two upload failures now split title and description:

Before: center stack open After: center stack open with split copy

After, a single error, and the pending message at 390:

After: File too large After: pending message at 390

Phone toasts now start below the refresh notices (fixed in #192014).

Checks run locally: oxfmt, oxlint, stylelint, pnpm tsgo:ui, and the unit and browser tests next to every touched file (65 files). Tests that asserted the exact showToast call or the full title text now include the severity or read the split copy; e2e assertions on the split copy are updated but e2e was not run.

Stacked on #192014 (base brzezowski/toast-stack). Land #192013, then #192014, then this.

@clawsweeper

clawsweeper Bot commented Nov 3, 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. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. proof: sufficient ClawSweeper judged the real behavior proof convincing. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. 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 clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Nov 3, 2026
@clawsweeper

clawsweeper Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs changes before merge.

What this changes

This PR marks failure toasts as errors, separates two-sentence messages into title and description, and emphasizes recovery actions.

Example: An oversized attachment is rejected.

  • Before: “File too large. Try a smaller file.” appears as one title.
  • After: “File too large.” is the title, with “Try a smaller file.” beneath it.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) Useful, visually demonstrated production changes with confirmed gaps in affected consumer tests.
Proof confidence 🦞 diamond lobster (5/6) ✨ media proof bonus Sufficient (screenshot): Inspected before/after screenshots exercise the production Control UI with a mock Gateway and show pending-input recovery and upload-error flows rendering split copy and the emphasized Review action.
Patch quality 🦐 gold shrimp (3/6) 2 actionable review findings remain.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Failure notifications look like ordinary notices, and recovery instructions and actions are harder to scan.
Reason: The maintainer-authored direction improves existing feedback without adding settings, state, or another notification owner.

Merge readiness

⛔ Needs changes before merge - 2 items remain

Keep open: this maintainer-authored PR delivers useful toast improvements, but incomplete consumer-test updates introduce confirmed CI failures.

Priority: P3
Reviewed head: 620f15304060e838f88c9612ebfe6f85d1bc63ba

Before merge

  • Update the remaining severity-sensitive consumer assertions (P2) - Adding severity here changes the exact toast call consumed by chat-dialog-preparation.test.tsx:189 and :203, which still expect only a message. Exact-head CI confirms the first failure and equivalent mismatches in session-offline-lifecycle.test.ts, session-organizer-batch-mutations.test.ts, and chat-pane.test.ts. Update these affected expectations while preserving their cancellation, rollback, retained-data, and retry assertions.
  • Complete the consumer-test migration for split toast copy (P2) - The automatic split moves second sentences out of .app-toast__message, but Board and login-recovery tests still search that element for the complete copy. Exact-head CI reports “Could not reject widget access.” instead of the expected full message and cannot find “Unsaved starts will be lost.” in the title. Update board-view.test.ts and login-gate.test.ts to inspect the full body or the separate description, retaining their recovery and action assertions.

Findings

  • [P2] Update the remaining severity-sensitive consumer assertions — ui/src/pages/chat/components/chat-session-workspace-state.ts:680
  • [P2] Complete the consumer-test migration for split toast copy — ui/src/lib/toast-view.tsx:115-118

Tests

  • Missing end-to-end proof: A red-on-base, green-on-head automated regression for automatic sentence splitting is not demonstrated.
Agent review details

How this fits together

Control UI operations submit messages and presentation options to the existing toast controller, whose Solid renderer displays notifications and accessibility announcements.

flowchart LR
  A[UI operation] --> B[Toast options]
  B --> C[Toast controller]
  C --> D[Solid toast renderer]
  D --> E[Title and description]
  D --> F[Recovery action]
  D --> G[Accessibility announcement]
Loading

Technical review

Best possible solution:

Keep the existing toast owner and focused presentation changes, completing the affected consumer-test updates before landing the stack.

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

Current-main source confirms polite announcements and unsplit messages; supplied screenshots demonstrate the presentation change, while CI annotations independently reproduce incomplete test migration.

Is this the best way to solve the issue?

The production change is focused and reuses existing severity, description, and action contracts; its consumer tests need the same complete cutover.

Full review comments:

  • [P2] Update the remaining severity-sensitive consumer assertions — ui/src/pages/chat/components/chat-session-workspace-state.ts:680
    Adding severity here changes the exact toast call consumed by chat-dialog-preparation.test.tsx:189 and :203, which still expect only a message. Exact-head CI confirms the first failure and equivalent mismatches in session-offline-lifecycle.test.ts, session-organizer-batch-mutations.test.ts, and chat-pane.test.ts. Update these affected expectations while preserving their cancellation, rollback, retained-data, and retry assertions.
    Confidence: 1
  • [P2] Complete the consumer-test migration for split toast copy — ui/src/lib/toast-view.tsx:115-118
    The automatic split moves second sentences out of .app-toast__message, but Board and login-recovery tests still search that element for the complete copy. Exact-head CI reports “Could not reject widget access.” instead of the expected full message and cannot find “Unsaved starts will be lost.” in the title. Update board-view.test.ts and login-gate.test.ts to inspect the full body or the separate description, retaining their recovery and action assertions.
    Confidence: 1

Overall correctness: patch is incorrect
Overall confidence: 0.97

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 51bee40d3c7f.

Provenance checked

  • Native toast content and fragment identity keeps the original intent (d912f0c: Render strings and DOM nodes directly while retaining consumed fragment children and link identity across unrelated updates.)
  • Failure severity at existing callers keeps the original intent (aeae6d1: Attachment failures established the opt-in error-toast contract; this PR applies existing severity to additional failure outcomes.)
  • Stack renderer title and description presentation changes intended behavior with a stated reason (4f4ef76: The preceding stack PR provides the shared toast anatomy; this PR explains splitting existing two-sentence copy and emphasizing required recovery actions.)

Testing

Proof path: shipped entry point.

Security

None.

Evidence

Acceptance criteria:

  • pnpm --dir ui test src/pages/chat/chat-dialog-preparation.test.tsx src/lib/sessions/session-offline-lifecycle.test.ts src/components/session-organizer-batch-mutations.test.ts src/pages/chat/chat-pane.test.ts src/components/board/board-view.test.ts src/components/login-gate.test.ts
  • git diff --check

What I checked:

Likely related people:

  • Peter Steinberger: Raw commit d912f0c adds ui/src/lib/toast-view.tsx:23 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: d912f0c06e7a; files: ui/src/lib/toast-view.tsx)

PR surface

Source +78, Tests +15. Total +93 across 80 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 67 151 73 +78
Tests 13 26 11 +15
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 80 177 84 +93

Labels

Label changes:

  • add P3: This improves notification clarity and accessibility without changing the underlying operation or recovery behavior.
  • add proof: sufficient: Contributor real behavior proof is sufficient.
  • add proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence.
  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦞 diamond lobster and patch quality is 🦐 gold shrimp.
  • add status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action.

Label justifications:

  • P3: This improves notification clarity and accessibility without changing the underlying operation or recovery behavior.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦞 diamond lobster and patch quality is 🦐 gold shrimp.
  • status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action.
  • proof: sufficient: Contributor real behavior proof is sufficient.
  • proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence.

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 3, 2026, 10:46 AM ET / 15:46 UTC.

…er e2e

The queued skill-selection notice is a success message, not an error. E2E now reads open-file failures as alerts and two-sentence toast copy from title plus description.

Co-authored-by: vyctorbrzezowski <[email protected]>
Base automatically changed from brzezowski/toast-stack to main November 4, 2026 00:09
…lers

# Conflicts:
#	ui/src/lib/toast-view.tsx
#	ui/src/pages/chat/chat-pane-placement.runtime.ts
#	ui/src/pages/model-providers/profiles-view.tsx
@roboclaw-bot
roboclaw-bot merged commit eee9925 into main Nov 4, 2026
18 of 19 checks passed
@roboclaw-bot
roboclaw-bot deleted the brzezowski/toast-center-callers branch November 4, 2026 00:13
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 4, 2026
…192015)

* improve(ui): rebuild the toast on one component with variants and a hover dismiss

* improve(ui): stack toasts in a center lane and an arrivals lane

* improve(ui): mark error toasts and split two-sentence copy into title and description

* fix(ui): keep phone toasts below the top refresh notices

* test(ui): read stacked toasts in model provider tests

Co-authored-by: vyctorbrzezowski <[email protected]>

* fix(ui): keep overlay toasts at the top inset and align e2e with stacked lanes

Overlay toast hosts no longer inherit the shell chrome offset on phones; e2e checks now center on the content column, read the fixed lane, and blur the toast before Escape.

Co-authored-by: vyctorbrzezowski <[email protected]>

* fix(ui): keep the skill selection notice informational and align caller e2e

The queued skill-selection notice is a success message, not an error. E2E now reads open-file failures as alerts and two-sentence toast copy from title plus description.

Co-authored-by: vyctorbrzezowski <[email protected]>

---------

Co-authored-by: roboclaw-bot <[email protected]>
vincentkoc added a commit that referenced this pull request Nov 4, 2026
* commit 'b4ebd3673fea4932296b92bbc07b7abc4bdc792d':
  fix(ci): allow serial SDK API reports to finish (#192196)
  fix(ci): run PostgreSQL checks when its shard planner changes (#191963)
  fix(ci): model native Linux updater asset entry
  improve(test): speed up config and device binding browser tests (#192404)
  improve(ui): show arrivals top right with a contextual session status (#192016)
  improve(ui): mark error toasts and split two-sentence copy (#192015)
  fix(sandbox): give dependency builders a writable home (#192390)
  fix(worktrees): keep archive manifest checks off the main thread (#192358)
  fix(cron): preserve admitted runs and pacing across unrelated MCP reloads (#192399)
  improve(ui): stack toasts in a center lane and an arrivals lane (#192014)
  fix: reclaim abandoned read-only database snapshots (#192368)
  improve(ui): rebuild the toast on one component with variants and a hover dismiss (#192013)
  docs: consolidate team server and team setup into one Multiplayer page
  fix(ci): reconcile remaining unallocated test lines
  feat: run admitted MCP tools on the worker node that hosts them (#191387)
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. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. 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.

2 participants