Search

Search components, tokens, patterns, architecture

Components

Chips, Tags & Pills

Chips are Peri's logging vocabulary — the fastest possible multi-select. Two visual species exist: the white shadowed chip (symptoms) and the muted warm chip (workout, period, sleep), both turning orange-gradient when selected.

Selectable tag chip, live

Tap to toggle — white + shadow default, orange gradient selected
PropertySpec
Shapepill (--r-chip) · 13px label · 6×12 padding
Default (symptom)white + --shadow-sm
Default (muted, .wkt-chip)--bg2 fill, no shadow — workout / period / sleep vocabularies
Selected--grad-btn + white label; in remove contexts renders “label ✕”
Favouritespinned first within their section

Variants

2 MG / Daily
muted (wkt-chip) · selected · read-only metadata tag
VariantUse
Symptom chipLog Symptoms — 5 categories, search, favourites, custom tags
.wkt-chipWorkout / period / sleep vocabularies — calmer density for longer lists
.sm-sym-chipRead-only most-common symptoms in Symptoms Overview
Onboarding chipoutline → green-tinted when selected
Metadata taguppercase read-only labels (doses, ranges)
Outcome chipWhatNextCard predicted outcomes — read-only
Category chipsingle-select filter (HRT / Skin / custom) — orange filled when active

Custom tags & favourites

Every logging vocabulary supports user extension: long-press opens custom-tag CRUD (add / edit / delete, persisted per category in localStorage), the + button adds a new tag, and search filters live. Favourites pin to the front of their section.

Known gap

Long-press has no keyboard equivalent. Documented as an accessibility debt item — the CRUD sheet needs a visible entry point (e.g. the existing ⋮ pattern from treatment categories).

Do

  • ·Use muted chips for long vocabularies, shadowed chips for short high-salience ones
  • ·Pin favourites first; keep search instant
  • ·Keep selected state as fill + label color together

Don't

  • ·Mix muted and shadowed chips in one section
  • ·Use chips for navigation — chips are vocabulary or filters
  • ·Truncate chip labels — wrap the row instead

Accessibility

  • Selectable chips carry aria-pressed; filter chips behave as a radiogroup.
  • Selected encodes by fill and label color/weight.
  • Custom-tag CRUD needs a non-gesture entry point (keyboard gap noted above).