Skip to content

Replace the card-chooser selection pill with a shared boxel-ui SelectionMenu#5100

Open
lukemelia wants to merge 1 commit into
cs-11313-apply-burcus-feedback-to-adorn-uifrom
cs-11325-card-chooser-selection-trigger-reconsider-adorn-pill-vs
Open

Replace the card-chooser selection pill with a shared boxel-ui SelectionMenu#5100
lukemelia wants to merge 1 commit into
cs-11313-apply-burcus-feedback-to-adorn-uifrom
cs-11325-card-chooser-selection-trigger-reconsider-adorn-pill-vs

Conversation

@lukemelia
Copy link
Copy Markdown
Contributor

@lukemelia lukemelia commented Jun 3, 2026

The "N selected" bulk-selection trigger in the card chooser was a flat teal pill — a visual regression from the previous dropdown (CS-11325). This makes it a proper primary dropdown control and extracts the whole thing into a reusable boxel-ui component so other surfaces (e.g. the workspace CardsGrid — CS-11366) can adopt it.

Folds in the work formerly split across #5100 + #5101 (now closed): the extraction reworks the same trigger, so they're reviewed together as one net change.

Decision (CS-11325)

BoxelSelect is the wrong primitive here — it's a value-picker, but this is an action menu (Select All / Deselect All). So this keeps BoxelDropdown + Menu and fixes the trigger, rather than reaching for a value-picker or polishing the flat pill.

What's here

  • New generic, content-agnostic SelectionMenu in boxel-ui. It owns the trigger — a primary BoxelButton with a selection checkmark, the count, and a caret that flips on open — and the dropdown shell. The consumer supplies the menu contents via @items, so Select All / Deselect All and the inert count header stay in the app (built in SearchResultHeader); app-specific selection semantics don't leak into the design system. @label sets the trigger's accessible name.
  • SelectionCheckmark artwork moved into boxel-ui and reused in CardHeader, removing a byte-identical inline SVG (advances CS-11333).
  • Focus + interaction polish: keyboard focus shows a ring just outside the trigger without darkening the fill (CS-11328); the trigger holds its position when the menu opens (wrapped so basic-dropdown's content-origin doesn't add a flex gap).

Scope / surface

Touches boxel-ui's public surface (new SelectionMenu / SelectionCheckmark exports) and host. No behavior change for the card chooser: same markup, data-test-* hooks, aria-label, and menu items. boxel-ui + host both pass ember-tsc (0 errors), eslint, and prettier; verified in-browser across resting / hover / open / keyboard-focus.

Stacked on #5099 (CS-11313); auto-retargets to main when that merges. Follow-up: CS-11366 (bring SelectionMenu to the workspace CardsGrid).

🤖 Generated with Claude Code

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 3, 2026

Preview deployments

Host Test Results

    1 files  ±0      1 suites  ±0   1h 50m 19s ⏱️ - 2m 42s
2 931 tests ±0  2 916 ✅ ±0  15 💤 ±0  0 ❌ ±0 
2 950 runs  ±0  2 935 ✅ ±0  15 💤 ±0  0 ❌ ±0 

Results for commit 2746dc8. ± Comparison against earlier commit ed0f9c7.

Realm Server Test Results

    1 files  ±0      1 suites  ±0   10m 14s ⏱️ -25s
1 549 tests ±0  1 548 ✅ ±0  1 💤 ±0  0 ❌ ±0 
1 640 runs  ±0  1 639 ✅ ±0  1 💤 ±0  0 ❌ ±0 

Results for commit 2746dc8. ± Comparison against earlier commit ed0f9c7.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the bulk-selection dropdown trigger in the card-search “search result header” to read as a primary dropdown button (highlight fill + foreground, hover/open state deepening, external focus ring, and caret rotation) while keeping the existing BoxelDropdown + Menu behavior unchanged.

Changes:

  • Restyles .selection-dropdown-trigger as a primary/highlight button (tokens, sizing, spacing, transitions).
  • Separates hover/open fill deepening from keyboard focus (outline ring + offset, no focus-darken).
  • Rotates the dropdown caret when [aria-expanded='true'] to match standard dropdown affordance.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@lukemelia lukemelia marked this pull request as ready for review June 3, 2026 22:26
@lukemelia lukemelia requested review from a team and burieberry June 3, 2026 22:26
…ionMenu

The "N selected" bulk-selection trigger in the card chooser was a flat teal
pill — a visual regression from the previous dropdown. Per the CS-11325
evaluation, BoxelSelect is the wrong primitive (it's a value-picker; this is
an action menu), so this keeps BoxelDropdown + Menu and makes the trigger a
proper primary dropdown button, then extracts the whole control into a
reusable boxel-ui component so other surfaces (e.g. the workspace CardsGrid)
can adopt it.

- New generic, content-agnostic boxel-ui SelectionMenu: it owns the trigger
  (a primary BoxelButton with a selection checkmark, count, and a caret that
  flips on open) and the dropdown shell, while the consumer supplies the menu
  items via @Items. Select All / Deselect All and the inert count header stay
  in the app (built in SearchResultHeader), so selection semantics don't leak
  into the design system.
- Move the shared SelectionCheckmark artwork into boxel-ui and reuse it in
  CardHeader, removing a duplicated inline SVG (advances CS-11333).
- Keyboard focus shows a ring outside the trigger without darkening the fill
  (CS-11328); the trigger holds its position when the menu opens.

No behavior change for the card chooser: same markup, data-test hooks,
aria-label, and menu items.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@lukemelia lukemelia force-pushed the cs-11325-card-chooser-selection-trigger-reconsider-adorn-pill-vs branch from ed0f9c7 to 2746dc8 Compare June 4, 2026 02:37
@lukemelia lukemelia changed the title Make the card-chooser selection trigger a primary dropdown button Replace the card-chooser selection pill with a shared boxel-ui SelectionMenu Jun 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants