Skip to content

fix(ui): descriptor-driven filters for composed boards - #9

Open
Seanathon wants to merge 1 commit into
mainfrom
feat/descriptor-driven-filters
Open

fix(ui): descriptor-driven filters for composed boards#9
Seanathon wants to merge 1 commit into
mainfrom
feat/descriptor-driven-filters

Conversation

@Seanathon

Copy link
Copy Markdown
Owner

Problem: when you create a new board (e.g. a "Wish List"), the navbar's filters showed the same options as Inspiration (Audience / Form / Domain) and the tag cloud never populated.

Cause: a composed grid board inherits type: "inspiration" for its card layout, and the filter chrome keyed off that type — so it rendered Inspiration's fixed facets (populated from Inspiration's taxonomy) and its design tag cloud (reads meta.tags, which composed items don't have).

Fix: wire up the descriptor-driven filter helpers that already existed but were never used by the UI (Story 8.2's buildFilters + matchesFilters"a composed board filters with no code"):

  • collectionChrome: the fixed Inspiration controls now gate on the seeded Inspiration board by id, not any type === 'inspiration' board (Library controls likewise).
  • applyCollectionChrome renders, for composed boards, a dropdown per enum field and a tag cloud from the tags field.
  • applyFilters filters composed boards through matchesFilters (enum equality + tags-includes, shape-bridged via getFieldValue), plus a generic text search.
  • Board switch and "Clear" reset the new selections.

Seeded Inspiration/Library keep their hand-tuned bespoke chrome (unchanged).

Verified live on a Wish List board: Want level + Verdict dropdowns and a category tag cloud now appear, and clicking a tag filters to the matching items. tsc clean; 534 tests pass.

🤖 Generated with Claude Code

…on's

A composed grid board inherits type 'inspiration' for its card layout, so the
navbar showed Inspiration's fixed Audience/Form/Domain facets (populated from
Inspiration's taxonomy) and its design tag cloud — both irrelevant/empty for,
say, a 'Wish List'. The board's tags never populated.

Wire up the descriptor-driven filter helpers that already existed but were never
used by the UI (Story 8.2: buildFilters + matchesFilters — 'a composed board
filters with no code'):
- collectionChrome: the FIXED Inspiration controls are now keyed to the SEEDED
  Inspiration board by id, not any type==='inspiration' board. Library controls
  likewise gate on the seeded ids.
- applyCollectionChrome renders, for composed boards, a dropdown per enum field
  and a tag cloud from the tags field (via buildFilters).
- applyFilters filters composed boards through matchesFilters (enum equality +
  tags includes, shape-bridged) plus a generic text search.
- board switch + Clear reset the new selections.

Verified live on a 'Wish List': Want level / Verdict dropdowns + a category tag
cloud, and clicking a tag filters correctly. tsc clean; 534 tests pass.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.

1 participant