@nomiedge/patterns
v0.1.1
Published
Reusable, composed UI patterns for Nomiedge Design Language — data table, empty state, page header, settings row, stat card, command palette. Composition only: no new primitives, no new tokens.
Readme
@nomiedge/patterns
Reusable, composed UI patterns for Nomiedge Design Language — the layer between a primitive
(@nomiedge/ui) and a whole page (@nomiedge/templates): a data table, an empty state, a page
header, a settings row, a stat card, a command palette.
Patterns
- EmptyState — a centered, announced ("no results", "nothing here yet") placeholder.
- PageHeader — title + description + trailing actions.
- StatCard — a labeled numeric value with an optional trend.
- SettingsRow — a label/description/control row for settings forms.
- DataTable — a sortable table with a composed empty state.
- CommandPalette — a
⌘Kcommand palette; fully generic (you own the data/search, this owns the UI).
Composition, not invention
Every pattern here is built entirely from @nomiedge/ui/@nomiedge/icons (CommandPalette also
uses cmdk, the same dialog primitive docs's search already used). If a pattern needs something
the design system doesn't have yet, that's a gap in the primitives to report — not something to
hand-roll inside a pattern.
Adding a pattern
New patterns should come from a real, observed duplication in shipped product code — not be
invented ahead of need (command-palette here is the one pattern with that real provenance;
the other five were built new, held to the same composition/a11y bar, during Milestone 57).
- Add
src/<pattern-name>/<PatternName>.tsx+ a colocated.test.tsx. - Export it from
src/index.ts. - Register it in
packages/registry/src/build/extract-patterns.ts's explicit file list — the CLI validates every pattern's dependencies against the real registry before scaffolding.
