Skip to content

Dashboards gallery: search icon and multi-select author filter - #194450

Merged
vyctorbrzezowski merged 4 commits into
mainfrom
brzezowski/dashboards-filter
Nov 9, 2026
Merged

vyctorbrzezowski merged 4 commits into
mainfrom
brzezowski/dashboards-filter

Conversation

@vyctorbrzezowski

@vyctorbrzezowski vyctorbrzezowski commented Nov 7, 2026 •

Copy link
Copy Markdown
Member

What Problem This Solves

The gallery's author filter is a labeled select with one author at a time and no way to find a name in a long list, next to an always-open search field, a result count and a total count.

User Impact

Search is an icon that opens the field; it stays open while it holds a query and closes with Esc or ×. The filter button opens the author list directly: You first, then the selected authors, then everyone by dashboard count, each with an avatar and a count. Multi-select. A search field appears above 8 authors. An applied filter shows as a chip: "Author is …" with the avatar for one author, "N authors" for several, with × to remove it; Clear sits in the list. Sort stays as a compact select in the same row.

Why This Change Was Made

Approved gallery redesign, filter part. Authors and counts come from the sessions.list rows already loaded; no new data.

Follows the landed card redesign #194444. Land this PR before the Display PR #194455.

Evidence

Mock Gateway capture, same data on both sides.

Scenario Before After
Search "gateway" · desktop 1440 · light
One author · desktop 1440 · light
State Screenshot
Author list · 13 authors · desktop 1440 · light
Author list · 3 selected · desktop 1440 · light
Author is You · phone 390 · dark

Preparation validation

The loaded design is unchanged. Selection now retains keyboard focus when checked authors move to the selected group, and the header/cards reserve their loaded geometry while data is pending. The native Popover still owns opening, closing, and touch dismissal.

  • UI-pages typecheck, 13 dashboard tests, five existing scope/navigation cases, and all four existing bundled browser scenarios passed.
  • The browser flow proves search, multi-select, Space selecting/deselecting, touch dismissal, navigation, and retained widget state. The focus assertion failed before its correction.
  • Targeted lint, stylesheet lint, controller guards, i18n baseline, and diff checks passed. Independent P0–P2 review included the unchanged native overlay owners and found no actionable issue.
  • An exact 19-line test allocation covers migration of existing drivers and the reproduced focus regression; no new test suites were added.
  • Asset-budget results await exact-head CI. Author controls now use the shared action-cursor preference; the existing cursor-policy test and stylelint pass.

All seven existing screenshots were inspected. Main was integrated while preserving the published branch ancestry; the PR diff contains only this layer and its consumer repairs.

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

clawsweeper Bot commented Nov 7, 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:feature 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:feature Preliminary submission classification; full source review pending. labels Nov 7, 2026
@clawsweeper

clawsweeper Bot commented Nov 7, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs changes before merge.

What this changes

This PR replaces the dashboard gallery toolbar with expandable search, searchable multi-author selection, applied-filter chips, and compact sorting.

Example: Show dashboards authored by Jordan Pike and Morgan Ellery.

  • Before: The author select accepts only one author.
  • After: Both authors can be selected together, with a removable “2 authors” chip.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) Strong visual evidence supports a useful redesign, but dismissal and validation defects prevent a clean patch verdict.
Proof confidence 🦞 diamond lobster (5/6) ✨ media proof bonus Sufficient (screenshot): Inspected browser screenshots exercise the gallery with a mock Gateway: desktop search for “gateway,” single-author filtering, the searchable author list, three selected authors with matching cards, and a dark phone layout.
Patch quality 🦐 gold shrimp (3/6) 5 actionable review findings remain.

Product

Kind: Feature · Worth it: Yes · Fix scope: Complete
User problem: Users can select only one author and cannot search a long author list.
Reason: The maintainer-authored direction provides useful multi-author filtering without new server data, configuration, or persistence.

Merge readiness

⛔ Needs changes before merge - 6 items remain

Keep open: this maintainer-authored redesign has clear value, but mouse dismissal regresses and the filter cutover leaves concrete validation failures.

Priority: P3
Reviewed head: 788ea90b1221b61048638a676db29de88e22e00d

Before merge

  • Preserve mouse-click absorption when dismissing the author list (P2) - Open the author popover and click a dashboard card outside it with a mouse. Removing DashboardFilterPopover also removes its capture handler that consumed this click. The shared overlay closes on pointer release but calls absorbNextClick only for touch, so the mouse click continues to the card and navigates away. Preserve the previous mouse behavior in the replacement without changing unrelated overlay policy.
  • Complete the filter and toolbar test cutover (P2) - Changing the fixture fields alone leaves tests exercising removed controls: view.test.tsx still expects .dashboards-filter__trigger, “Filters,” and the deleted skeleton toolbar; dashboards-page.test.tsx still types into an initially hidden search and uses the removed author select. session-activity-view.test.ts also passes ownerId, causing selected().length to throw. Exact-head UI annotations confirm these failures. Migrate these consumers to the new controls and ownerIds shape, preserving result, navigation, loading, and multi-selection coverage.
  • Capture the search button through its ref (P2) - The new querySelector searches this component's own DOM, which ui/AGENTS.md and the enforced controller guard explicitly prohibit outside named DOM islands. dashboard-tools.tsx is not an exception, so this call fails the guard. IconButton already forwards native button attributes, including ref; capture that button directly and restore focus through it instead of querying the wrapper.
  • Use the shared action cursor for author controls (P3) - The new Clear button and author rows change local state but hard-code cursor: pointer. The UI guide requires the shared action cursor for these controls, and exact-head cursor-policy.node.test.ts reports both declarations. Use var(--cursor-action) or inherit the established control treatment rather than changing the policy test.
  • Map folded search positions back to the original author name (P3) - fold removes combining marks, but the resulting index is used to slice the original string. For an author named “José Alvarez” with a decomposed accent, searching “Alvarez” finds index 5 in the folded name while the original surname begins at index 6; the bold span includes the preceding space and misses the final letter. Map normalized positions back to the original text or omit highlighting while retaining accent-insensitive filtering.
  • Explain or restore the original intent of Outside mouse-click absorption - 74d2a44: The local guard prevented a dismissing click from opening the dashboard underneath, including mouse clicks not absorbed by the shared touch guard.

Findings

  • [P2] Preserve mouse-click absorption when dismissing the author list — ui/src/pages/dashboards/dashboard-tools.tsx:147-152
  • [P2] Complete the filter and toolbar test cutover — ui/src/pages/dashboards/view.test.tsx:95-103
  • [P2] Capture the search button through its ref — ui/src/pages/dashboards/dashboard-tools.tsx:35

Provenance

  • Outside mouse-click absorption changes intended behavior without addressing why it exists (74d2a44: The local guard prevented a dismissing click from opening the dashboard underneath, including mouse clicks not absorbed by the shared touch guard.)
Agent review details

How this fits together

The Control UI derives authors and counts from already-loaded session rows, applies local search and author filters, and renders the resulting dashboard cards.

flowchart LR
  A[Session list owner] --> B[Dashboard route data]
  B --> C[Author options and counts]
  C --> D[Search and author controls]
  D --> E[Page filter state]
  B --> F[Visible dashboard rows]
  E --> F
  F --> G[Dashboard gallery]
Loading

Technical review

Best possible solution:

Keep the existing page filter owner and shared UI primitives, preserve mouse dismissal, and complete the tests and small policy repairs before landing the stack.

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

This is a feature redesign; its visible results are supported by browser screenshots, and the reported review defects follow from source and exact-head CI annotations.

Is this the best way to solve the issue?

The change reuses the correct data and presentation owners, but the complete implementation must preserve existing dismissal behavior and migrate every affected test consumer.

Full review comments:

  • [P2] Preserve mouse-click absorption when dismissing the author list — ui/src/pages/dashboards/dashboard-tools.tsx:147-152
    Open the author popover and click a dashboard card outside it with a mouse. Removing DashboardFilterPopover also removes its capture handler that consumed this click. The shared overlay closes on pointer release but calls absorbNextClick only for touch, so the mouse click continues to the card and navigates away. Preserve the previous mouse behavior in the replacement without changing unrelated overlay policy.
    Confidence: 0.99
  • [P2] Complete the filter and toolbar test cutover — ui/src/pages/dashboards/view.test.tsx:95-103
    Changing the fixture fields alone leaves tests exercising removed controls: view.test.tsx still expects .dashboards-filter__trigger, “Filters,” and the deleted skeleton toolbar; dashboards-page.test.tsx still types into an initially hidden search and uses the removed author select. session-activity-view.test.ts also passes ownerId, causing selected().length to throw. Exact-head UI annotations confirm these failures. Migrate these consumers to the new controls and ownerIds shape, preserving result, navigation, loading, and multi-selection coverage.
    Confidence: 1
  • [P2] Capture the search button through its ref — ui/src/pages/dashboards/dashboard-tools.tsx:35
    The new querySelector searches this component's own DOM, which ui/AGENTS.md and the enforced controller guard explicitly prohibit outside named DOM islands. dashboard-tools.tsx is not an exception, so this call fails the guard. IconButton already forwards native button attributes, including ref; capture that button directly and restore focus through it instead of querying the wrapper.
    Confidence: 1
  • [P3] Use the shared action cursor for author controls — ui/src/styles/dashboards.css:147
    The new Clear button and author rows change local state but hard-code cursor: pointer. The UI guide requires the shared action cursor for these controls, and exact-head cursor-policy.node.test.ts reports both declarations. Use var(--cursor-action) or inherit the established control treatment rather than changing the policy test.
    Confidence: 1
  • [P3] Map folded search positions back to the original author name — ui/src/pages/dashboards/dashboard-tools.tsx:80-84
    fold removes combining marks, but the resulting index is used to slice the original string. For an author named “José Alvarez” with a decomposed accent, searching “Alvarez” finds index 5 in the folded name while the original surname begins at index 6; the bold span includes the preceding space and misses the final letter. Map normalized positions back to the original text or omit highlighting while retaining accent-insensitive filtering.
    Confidence: 0.99

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 49e8b5d2b5a7.

Provenance checked

  • Gallery search, author selection, and counts changes intended behavior with a stated reason (12d6388: The original gallery introduced search, single-author filtering, sorting, and complete inventory browsing.)
  • Compact phone controls and single-choice author menu changes intended behavior with a stated reason (74d2a44: The phone toolbar reduced vertical space while preserving author and sort access; this PR explains the move to a direct multi-author list.)
  • Lazy English registration and local filter ownership keeps the original intent (1532cce: Dashboard copy loads at its view boundary; page-local filters retain their existing owner and lifetime.)

Testing

Proof path: shipped entry point.

Security

None.

Evidence

Acceptance criteria:

  • pnpm --dir ui exec vitest run src/pages/dashboards/view.test.tsx src/pages/dashboards/dashboards-page.test.tsx src/pages/activity/session-activity-view.test.ts src/styles/cursor-policy.node.test.ts
  • pnpm tsgo:test:ui
  • pnpm check:control-ui-controllers
  • Verify that an outside mouse click closes the author list without opening a dashboard, and a subsequent card click still navigates.
  • Verify combined author selection, clearing, search open/close focus, and decomposed-Unicode author matching through the gallery.

What I checked:

  • Pinned introduction and approved direction: The reviewed head is 788ea90 against stacked base 2839e8a; GitHub identifies the author as MEMBER and reports the PR mergeable. (788ea90b1221)
  • Current-main behavior: Fetched main still uses the single-author filter and always-visible search field; the central capability remains useful. (ui/src/pages/dashboards/view.tsx:468, 49e8b5d2b5a7)
  • Mouse dismissal contract: The previous filter explicitly consumed outside mouse clicks; the shared overlay consumes the following click only when released.touch is true. The original rationale is recorded in improve(ui): compact Dashboards filters and cards on phones #190376. (ui/src/components/overlay-registry.ts:399, 788ea90b1221)
  • Diff-caused UI failures: Exact-head annotations show obsolete toolbar and trigger assertions, an unmigrated ownerId fixture throwing at selected().length, and the page interaction test attempting to use controls removed by this PR. (ui/src/pages/dashboards/view.test.tsx:108, 788ea90b1221)
  • Enforced UI policies: The UI guide requires refs instead of queries into owned DOM and the shared action cursor for state controls; the controller guard rejects the new querySelector, while exact-head cursor-policy annotations identify both new pointer declarations. (scripts/check-control-ui-controllers.mts:437, 788ea90b1221)
  • Inspected visual evidence: Inspected all supplied images: matched desktop search and single-author before/after views, the author list, three selected authors, and the dark phone layout. The additional GitHub images remained inspectable in memory after scratch-file writes failed. (788ea90b1221)

Likely related people:

  • Peter Steinberger: Raw commit f027af4 adds ui/src/pages/dashboards/dashboards-page.tsx:13 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: f027af496c61; files: ui/src/pages/dashboards/dashboards-page.tsx)
  • Patrick Erichsen: Raw commit 12d6388 adds ui/src/styles/dashboards.css:21 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 12d6388d3ebb; files: ui/src/styles/dashboards.css)

PR surface

Source +176, Tests 0. Total +176 across 8 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 7 544 368 +176
Tests 1 4 4 0
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 8 548 372 +176

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.

Review metrics

Metric Value Why it matters
Production versus test changes Production +544/-368; tests +4/-4 Production growth implements author search, multi-selection, chips, and their layout; test edits only migrate fields and leave existing interaction coverage broken.

Labels

Label changes:

  • add P3: The overall change improves gallery filtering and presentation without addressing an urgent broken workflow.
  • 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: The overall change improves gallery filtering and presentation without addressing an urgent broken workflow.
  • 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 6, 2026, 11:27 PM ET / November 7, 2026, 04:27 UTC.

@vyctorbrzezowski
vyctorbrzezowski marked this pull request as draft November 7, 2026 05:17
Base automatically changed from brzezowski/dashboards-card to main November 9, 2026 10:10
Retain the approved search and multi-author filter, preserve keyboard focus while selected authors reorder, and reserve the loaded header and card geometry during loading. Use the existing native Popover touch-dismissal contract.

Migrate existing route, scope, browser, and performance scenarios to the new controls. Test-line allocation: 19 lines for those existing-flow migrations and the reproduced keyboard-focus regression; no new test suites.
@openclaw-barnacle openclaw-barnacle Bot added the scripts Repository scripts label Nov 9, 2026
@vyctorbrzezowski
vyctorbrzezowski marked this pull request as ready for review November 9, 2026 10:29
@vyctorbrzezowski
vyctorbrzezowski merged commit 832bbf9 into main Nov 9, 2026
107 of 111 checks passed
@vyctorbrzezowski
vyctorbrzezowski deleted the brzezowski/dashboards-filter branch November 9, 2026 10:56
@vyctorbrzezowski

Copy link
Copy Markdown
Member Author

Closeout of the earlier review on 788ea90:

  • Fixed the control/test cutover, native search-button ref, and shared action cursors. The final browser proof also preserves keyboard focus through author reordering.
  • The old page-specific mouse-dismissal guard was intentionally not restored. The replacement follows the existing native Popover contract: an outside touch is absorbed, while a mouse click keeps its normal click-through behavior. The real touch flow and native owner were inspected and independently reviewed. This is a deliberate behavior decision, not a claim that the earlier mouse-absorption request was implemented.
  • The folded-name highlight limitation remains: decomposed Unicode can misalign bold emphasis. The complete author text and accent-insensitive filter remain correct. This recoverable cosmetic limitation was accepted without adding normalization/index-mapping machinery in this change.

The administrative merge waived only the separately identified CSS budgets; it did not relabel them as inherited failures.

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. scripts Repository scripts size: XL 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