Repository navigation
improve(ui): clarify picker selection and keyboard focus - #132018
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
Codex review: needs maintainer review before merge. Reviewed August 28, 2026, 3:08 PM ET / 19:08 UTC. ClawSweeper reviewWhat this changesThe PR refines shared Control UI picker selection and keyboard-focus styling, makes Escape dismiss an open picker before leaving Settings, and stabilizes a related dashboard browser test. Regression provenancePossible regression — suspected (reviewed change). No predecessor PR is attributed. Merge readinessKeep this maintainer-owned, protected PR open for normal merge review. No actionable correctness defect was found in the introduced changes; exact-head CI is still incomplete. Priority: P3 Review scores
Verification
How this fits togetherThe Control UI renders settings pickers with Web Awesome controls; shared CSS presents selected and keyboard-focused options while the shell owns Settings-level Escape navigation. Browser E2E tests drive those controls through an isolated mock Gateway and Chromium. flowchart LR
A[Settings page] --> B[Shared picker]
B --> C[Web Awesome select]
C --> D[Keyboard focus and Escape]
D --> E[Settings navigation]
B --> F[Shared picker styles]
F --> G[Rendered selection feedback]
Before merge
Agent review detailsSecurityNone. PR surfaceSource 0, Tests +131. Total +131 across 7 files. View PR surface stats
Review metrics
Root-cause clusterRelationship: Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Land the shared picker styling and shared shell-bound Escape repair after the remaining exact-head CI is green. Do we have a high-confidence way to reproduce the issue? Yes. Current source shows the Settings Escape handler receives keyboard events before an open shadow-DOM picker can close, and the focused browser tests cover that route plus independent selected/current styling. Is this the best way to solve the issue? Yes. The change belongs in the shared picker stylesheet and common shell Escape guard, covering every existing picker consumer without adding per-page handlers or configuration. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against adf5c6738216. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (1 earlier review cycle)
|
|
Land-ready verification for 38544d3.
Commands verified: pnpm ui:build
node scripts/run-vitest.mjs run --config test/vitest/vitest.ui-e2e.config.ts --configLoader runner ui/src/e2e/theme-muted-contrast.e2e.test.ts ui/src/e2e/channel-wizard-option-contrast.e2e.test.ts ui/src/e2e/sidebar-settings.e2e.test.ts ui/src/e2e/theme-typography.e2e.test.ts
node scripts/run-vitest.mjs ui/src/app/app-host-native-shell.test.ts ui/src/components/select-picker.test.ts
node scripts/run-vitest.mjs run --config test/vitest/vitest.ui-e2e.config.ts --configLoader runner ui/src/e2e/board-mcp-app.e2e.test.ts
node scripts/run-tsgo.mjs -p tsconfig.ui.json
node scripts/check-changed.mjs -- ui/src/app/app-shell-chrome.ts ui/src/e2e/channel-wizard-option-contrast.e2e.test.ts ui/src/e2e/sidebar-settings.e2e.test.ts ui/src/e2e/theme-muted-contrast.e2e.test.ts ui/src/styles/select-picker.css ui/src/styles/settings.cssUI build/browser proof used Blacksmith Testbox 33198096702, now stopped. After the local ENOSPC condition cleared, the complete local changed gate passed using a task-local Corepack shim for the repository-pinned pnpm; the dashboard test repair also passed scoped lint/typecheck. No remaining code/proof gap; proceeding only through native prepare/merge. |
|
Merged via squash.
|
…2018) * improve(ui): clarify picker selection and keyboard focus * test(ui): observe renewed dashboard frame before sampling colors
Closes #131995
What Problem This Solves
Shared pickers make the roving keyboard option the prominent state, while the committed selection can lose its highlight as focus moves. Typography also looks louder than neighboring Appearance controls. The original muted-on-accent subtext bug is already fixed by #131402; this is the maintainer-approved refinement on top of it.
The real screenshot flow also exposed a connected bug: Escape from a font option exits Settings instead of only dismissing the popup.
Why This Change Was Made
Use one shared picker treatment: a quiet theme-aware tint/inset border for selection, neutral hover/current fill, brighter secondary text, and a distinct text-backed keyboard outline. The checkmark remains legible with black/white custom accents. Keep all existing dimensions, spacing, typography, corners, menu collision bounds, and overlay elevation.
The shared Settings Escape owner now recognizes an open Web Awesome select host. Slotted options hide their listbox in shadow DOM, and the shell's earlier document listener otherwise consumes Escape first. No per-picker handlers or changes to closed-trigger behavior. Also correct one stale settings-design comment link.
Scope: no new config, APIs, dependencies, schemas, persistence behavior, or component. Native selects retain platform rendering. Shared font/model/channel/wizard/workboard picker consumers inherit the CSS fix.
Production LOC: +19/-19, net 0. Tests: +151/-20, net +131 (includes the CI sequencing repair below). Removed the inverse current-row ink override and redundant option-color rule. Existing theme/browser fixtures absorb the regression coverage.
User Impact
Selected choices remain recognizable while browsing other options with the keyboard. Picker labels and descriptions remain readable, and the visual treatment fits neighboring settings. Escape closes the open picker without losing the Settings page or changing its value.
Evidence
AI-assisted; source, dependency contracts, tests, and every attached screenshot were inspected.
Real before/after
Captured from a real, task-isolated loopback Gateway with Chromium on Blacksmith Testbox, lease
tbx_01m14s1y28nwdvf9993bj77jfz(stopped). No operator Gateway/state, mocked transport, injected CSS, or generated mockups. Baseline CSS comes fromf7c5bd30730c726cf586fdbfbbbaea7133f2d72b, already including #131402. Candidate UI was rebuilt before capture.Behavioral proof
rgb(217, 119, 87)to transparent on ArrowDown. The independent Escape regression observed/newinstead of/settings/appearance.git diff --check, and fresh Codex Autoreview passed. Autoreview reported no accepted/actionable findings.Commands:
Local environment limitation: the local UI build/browser attempt and full
check:changedhit actualENOSPC; the latter failed writing a core-test.tsbuildinfo, not a source diagnostic. Browser/build proof therefore ran on Testbox; the non-incremental UI typecheck and scoped lint/unit checks passed locally. Exact-head hosted CI remains the final merge gate.Owner/dependency evidence
view-appearance.ts→renderPicker→select-picker.css; sibling adaptersmodel-picker.ts,channel-picker.ts,wizard-step-controls.ts, andworkboard-select.ts. Installed Web Awesome option/select source confirms separate selected/current states, the checked-icon part, reflected open attribute, and ArrowDown-versus-Enter behavior. Styling the committed:state(selected)is deliberate;[selected]is only the initial/default input.The Escape guard was carried forward in #117103 (
7bae24760b09, authored and merged by @steipete, 2026-07-31); that is guard provenance, not a claim that the refactor introduced the interaction defect. The fix stays at the shared shell boundary. A generic composed-path rewrite was considered but would also change closed shadow-input Escape behavior, which this PR intentionally preserves.CI repair / ClawSweeper rank-up follow-through
The failed UI E2E shard was traced to an existing
board-mcp-app.e2e.test.tsordering race, not the picker change. Its 7-second fixture lease renews 5 seconds before expiry; the 2211ms failure sampled the iframe between teardown and replacement.Commit
38544d320f3ad3620dd33f797b35d36530c517abmoves the existing renewal wait before color sampling and requires the recordedmcp.app.viewrequest forrenewed-view, which the owner emits after removing the old frame. All existing color/request assertions remain; no production code, retries, or expanded overall wait budget. The four-case dashboard E2E file passes locally, UI typecheck/scoped lint pass, and a fresh Autoreview of this test-only repair is clean. Exact-head CI is running again.This directly addresses the latest ClawSweeper rank-up request to resolve the failed shard. No re-review request is needed for a fresh review followed only by its requested CI repair.