Shared React UI components, hooks, and utilities for SMART on FHIR healthcare apps.
Published to GitHub Packages on every merge to main, so depend on it by semver
range like any other @max-health-inc package — not by git URL or commit SHA.
# Point the @max-health-inc scope at GitHub Packages (once, per consuming repo)
echo "@max-health-inc:registry=https://npm.pkg.github.com" >> .npmrc
bun add @max-health-inc/shared-uiInstalling needs a token with read:packages; CI reads it from ${GITHUB_TOKEN}.
import { Button, Card, Spinner } from "@max-health-inc/shared-ui"
import "@max-health-inc/shared-ui/theme.css"- Button, Card, Badge, Input, Label, Select, Tabs, Dialog, Table, ScrollArea, Progress, Tooltip, DropdownMenu, Separator
- AppHeader, PatientBanner, ErrorBoundary, Spinner, Toaster
- FilterToolbar, PageHeader, StatCard, ResponsiveTabsList
useSmartAuth— SMART on FHIR auth state managementuseBranding— Dynamic brand theming from backenduseModalLayer/ModalStackProvider— Z-index stacking for modals
cn()— Tailwind class mergingcreateSmartAppConfig()/createSmartAuth()/buildFhirBaseUrl()— SMART app bootstrapformatHumanName()— FHIR HumanName formattercreateAuthFetch()/onAuthError()/reportAuthError()— Auth fetch wrapper
theme.css— CSS custom properties (light + dark mode) for the MaxHealth design system
bun install
bun run build # Build library
bun run dev # Watch mode
bun run typecheck # Type-check without emittingBump version in package.json as part of your PR. Merging to main runs lint,
typecheck, tests and the build, then publishes that version and tags the commit.
A merge whose version is already on the registry publishes nothing and says so in the run summary — so docs-only and CI-only merges are a safe no-op, and forgetting to bump means "not released" rather than a failed build.
Pushing a v* tag re-runs the same workflow, which is only useful for retrying a
release — the already-published check makes it a no-op otherwise.