feat(browser): config-driven component layout (card meta + detail sections) - #54
Merged
Conversation
…tions) New components config block exposes visibility and order for three surfaces: meetingCard.metaItems (iterates — fully reorderable), meetingDetail.sections (visibility filter), decisionDetail.sections (visibility filter). Each list is backed by a closed Zod enum for typo safety; defaults preserve current behavior. Adding a new meta item type now means extending the union + adding a renderer branch (OCP), not editing a growing conditional. The detail-page section reorder is tracked separately in #53 — needs each section extracted to its own component file. 199 unit tests (was 193; +6 new config spec) + 51 e2e green. README updated with config reference table + a layout-config section. Known limitations section refreshed.
ronaldtse
added a commit
that referenced
this pull request
Jul 23, 2026
Consumes the changeset from PR #54. Bumps @edoxen/browser 0.11.0 -> 0.12.0 (minor: new public components config surface).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements the card / detail layout config that was filed as a design issue earlier today. Closes #53.
Added
componentsconfig block with three list-shaped fields, each backed by a closed Zod enum for typo safety:components.meetingCard.metaItems— iterates in the configured order. Fully reorderable. Drop an item to hide it. Default:['date', 'type', 'status', 'committee', 'count'].components.meetingDetail.sections— visibility filter (includes()check). Source order preserved. Default: all 13 sections already on the page.components.decisionDetail.sections— visibility filter. Default: all 8 sections already on the page.Adding a new meta item type now means extending the
MeetingCardMetaItemunion + adding a renderer branch — OCP-friendly. The detail-page renderer wraps each section in asectionVisible(key)check; full reorder for detail sections is tracked separately (would require extracting each section to its own component file).Tests
src/config/components.spec.ts— 6 tests covering: defaults match current order (backwards compat), partial override replaces wholesale, unknown values rejected (typo guard), empty lists allowed.Docs
componentsexposes vs. what's still deferred (full reorder, slot swaps, render hooks).Test plan
pnpm -F @edoxen/browser typecheck— clean.pnpm -F @edoxen/browser test— 199 passed (was 193; +6 new).pnpm -F @edoxen/browser test:e2e— 51 passed (defaults preserve current behavior).Closes
Closes #53.
Post-merge
Consumes the changeset; will release as
@edoxen/browser@0.12.0(minor — new public config surface).