Components
The platform ships parallel component libraries, intentionally shaped so a control’s API is recognisable across stacks:
- Web — bits-ui (headless primitives) + custom wrappers under
apps/svelte-web/src/lib/components/ui/. ~49 directories, ~213.sveltefiles. - Native mobile — two shared packages, one per platform, consumed by both the customer and the agent app:
native/MeridianUI(SwiftPM) andapps/android/core/design-system(:core:design-system). The primitives are lockstep across iOS and Android so feature code never re-rolls UI. The authoritative list lives on Conventions → Mobile (Native).
For framework rules — kebab-case filenames (web) vs PascalCase (native), no hand-rolled buttons, generated design tokens over hardcoded color — see Conventions → Web and Conventions → Mobile (Native).
Web primitives
Section titled “Web primitives”Organized by tier (per the team’s internal style guide). All bits-ui wrappers live under apps/svelte-web/src/lib/components/ui/{name}/; higher-level domain compositions live under apps/svelte-web/src/lib/components/{feature}/.
Tier 1 — base controls and overlays
Section titled “Tier 1 — base controls and overlays”| Component | Source dir | Purpose |
|---|---|---|
Button | ui/button/ | bits-ui Button + size / variant slots |
Input | ui/input/ | Text input wrapper with focus ring tokens |
Label | ui/label/ | Form label with required / optional indicator slots |
Card | ui/card/ | Card container with Header / Title / Description / Content / Footer subparts |
Dialog | ui/dialog/ | Modal overlay; the “destructive confirm” pattern lives here |
Sheet | ui/sheet/ | Side-anchored panel (left / right / top / bottom) |
Drawer | ui/drawer/ | Vaul-svelte mobile-first sheet with snap points |
Tabs | ui/tabs/ | Tabbed pages; tab list + tab triggers + tab panels |
Accordion | ui/accordion/ | Collapsible disclosure groups |
Select | ui/select/ | Single-select dropdown (Combobox for filtering) |
Combobox | ui/combobox/ | Filtered Select with text search |
Switch | ui/switch/ | Boolean toggle |
Toggle | ui/toggle/ | Stateful pressed button |
Checkbox | ui/checkbox/ | Tri-state checkbox |
RadioGroup | ui/radio-group/ | Single-pick radios |
DatePicker / Calendar | ui/date-picker/ + ui/calendar/ | Date input + month grid |
Popover | ui/popover/ | Anchored floating panel |
Tooltip | ui/tooltip/ | Hover-triggered label |
DropdownMenu | ui/dropdown-menu/ | Menu with submenus, separators, checkboxes |
Separator | ui/separator/ | Horizontal or vertical rule |
ScrollArea | ui/scroll-area/ | Custom scrollbar wrapping native overflow |
Command | ui/command/ | Cmdk-style palette (used in headers + admin tools) |
NavigationMenu | ui/navigation-menu/ | Top-level nav primitive |
ToggleGroup | ui/toggle-group/ | Exclusive / multi pressed-button set (view switchers) |
Slider | ui/slider/ | Single or dual-thumb range on the track / primary-solid pair; commits on release (onValueCommit) |
ConfirmDialog | ui/confirm-dialog/ | Dialog preset for the destructive-confirm pattern (title, body, danger action) |
ConfirmAlert | ui/confirm-alert/ | Inline alert variant of the confirm pattern for non-modal contexts |
AuthModal | ui/auth-modal.svelte | Sign-in / sign-up modal (email OTP + Google) mounted from any gated action |
CookieConsentBanner | ui/cookie-consent-banner.svelte | Bottom consent banner with accept / manage |
Tier 2 — forms
Section titled “Tier 2 — forms”| Component | Source dir | Purpose |
|---|---|---|
Field | ui/field/ | Label + Input + error container (standalone — no Formsnap dep) |
Form | via Formsnap | superforms + Zod integration; emit <Form.Field> per input |
InputGroup | ui/input-group/ | Prefix / suffix slots around an Input (currency symbol, unit) |
InputOTP | ui/input-otp/ | 6-digit code split inputs with auto-advance |
Textarea | ui/textarea/ | Multi-line input |
NumberStepper | ui/number-stepper/ | +/− buttons around a numeric value |
NumericInput | ui/numeric-input/ | Numeric-only Input with comma thousands formatting |
PhoneInput | ui/phone-input/ | MX-default international phone field |
TimeRangeField | ui/time-range-field/ | Start + end time picker, used in tour scheduling |
Form | ui/form/ | Formsnap wrappers (Form.Field, Form.Control, Form.Label, Form.FieldErrors) over superforms |
RadioCard | ui/radio-card/ | Card-shaped radio option (plan pickers, listing type) |
LocationCombobox | ui/location-combobox/ | Combobox over the places index (city / neighbourhood), form-action friendly |
LocationAutocomplete | ui/location-autocomplete.svelte | Free-text location search with grouped results (search takeover + hero) |
PlacesAutocomplete | ui/places-autocomplete.svelte | Google Places address autocomplete for exact addresses (listing wizard) |
Data display
Section titled “Data display”| Component | Source dir | Purpose |
|---|---|---|
Table | ui/table/ | Header / body / row primitives |
DataTable | via TanStack Svelte Table | Column defs + filtering + pagination |
Carousel | ui/carousel/ | Embla-svelte image carousel (property galleries) |
Alert | ui/alert/ | Inline info / warning / error banner |
Progress | ui/progress/ | Linear progress bar |
Badge | ui/badge/ | Variants neutral · success · warning · destructive · info · featured · tonal · ink · tertiary · outline; roles (kind) status · type · count — only count is a pill |
Avatar | ui/avatar/ | Image with the Meridian initials fallback (avatar-fallback-1 → 2 gradient, foreground initials) |
DataTable | ui/data-table/ | TanStack-table wrappers: sortable header, toolbar, pagination |
PillChip | ui/pill-chip/ | Filter / selection chip (selectable + dismissible) |
Feedback
Section titled “Feedback”| Component | Source dir | Purpose |
|---|---|---|
Spinner | ui/spinner/ | Loading indicator |
Skeleton | ui/skeleton/ | Placeholder rectangles |
Toaster / Toast | via svelte-sonner | Bottom-anchored toast; integrate via <Toaster /> at root |
EmptyState | ui/empty-state/ | Icon + heading + body + CTA (used across dashboard / portal / mobile) |
StatCard | ui/stat-card/ | KPI tile with label + value + delta |
Sonner | ui/sonner/ | The themed <Toaster /> wrapper around svelte-sonner |
Navigation
Section titled “Navigation”| Component | Source dir | Purpose |
|---|---|---|
LaunchpadTile | ui/launchpad-tile/ | 7 variants — Counter, Link, KPI, Status, Shortcut, Grouped, default. Shared base styles; used for hub / dashboard navigation. |
ButtonGroup | ui/button-group/ | Joined buttons (segmented controls) |
Command palette | ui/command/ | Global search palette (⌘K) |
SearchTakeover | ui/search-takeover/ | Full-screen mobile search surface (location + filters) |
ButtonCard | ui/button-card/ | Large tappable card acting as a button (hub entry points) |
PageContainer | ui/page-container/ | Page width + gutter wrapper (content-max 1200px) |
Native mobile primitives
Section titled “Native mobile primitives”The primitives live in two shared packages — native/MeridianUI (SwiftPM, both iOS apps) and apps/android/core/design-system (:core:design-system, both Android apps) — with matching APIs and visuals on iOS and Android. Colors come from the generated token files via @Environment(\.tokens) (iOS) / LocalTokens.current (Android) — never hardcoded hex — spacing and radii from Metrics (Metrics.gutter, Metrics.cardRadius, Metrics.inputRadius, Metrics.thumbRadius, Metrics.badgeRadius), elevation from the Metrics.Shadow tiers (iOS .meridianShadow(.raised)) / Metrics.Elevation* (Android), and the rule is no hand-rolled buttons — including AlertDialog slots, which use DialogActionButton / DialogDismissButton (Android) or DangerConfirmButton for a destructive confirm.
The shared set includes: PrimaryButton / SecondaryButton / TertiaryButton / DestructiveButton / DangerConfirmButton, DialogActionButton / DialogDismissButton (Android), ListRow, SwitchRow, CheckboxRow, SegmentedControl (single + multi select), SelectablePill / DismissibleChip, AvatarView / Avatar (initials on the avatarFallback1 → 2 gradient), StatusBadge (tones pending · success · info · neutral · destructive), Toast (via ToastCenter), EmptyState, Skeleton, text Inputs, PhoneField, OtpField, SearchField, SectionCard, FlowLayout (iOS), PickerSheet, TabRootHeader, ChromeButton / GlassIconButton (iOS), IconActionButton (Android). Property cards compose platform-native card/image/specs views with the favorite heart, multi-unit pills, and price-drop badge.
The authoritative list — and the mobile-ui-audit skill that flags violations — lives on Conventions → Mobile (Native).
Cross-reference
Section titled “Cross-reference”For the runtime rules that govern how these components are used:
- Conventions → Web — form-action template, Formsnap integration, auth gates, error handling.
- Conventions → Mobile (Native) — PascalCase filenames, generated design tokens (no hardcoded color), cookie auth, the shared primitive list.
- Design → Tokens — the color, typography, spacing, radius, and shadow values these components consume.
- Design → Principles — the design intent (property-first hierarchy, status taxonomy, dark mode strategy).