Staaarter

Daily Health Check-in

Two-column layout with feature highlights and a daily summary card showing heart rate, activity, and recovery metrics, all static number props. Perfect for fitness coaching and health monitoring apps.

By Staaarter Team
Health
Docs
Live preview

Docs

Installation

A real shadcn registry command, not a copy-paste stand-in: it fetches this block plus its badge dependencies and any missing npm packages, and installs them straight into your project.

npx shadcn add https://staaarter.com/r/daily-health-check-in.json

Prefer not to use the CLI? Copy the source from the Code toggle above into src/components/blocks/health/health3.tsx instead.

Usage

The file also exports health3Demo, the exact props behind the preview above. Spread it to get a working section in one line, then replace it with your own data.

import { Health3, health3Demo } from "@/components/blocks/health/health3";

export default function Page() {
  return <Health3 {...health3Demo} />;
}

Props

PropTypeDefaultDescription
eyebrowstringnoneSmall uppercase label above the heading; only rendered when set.
headingReactNodenoneLeft-column heading.
descriptionstringundefinedLeft-column intro text below the heading.
highlightsHighlight[]noneIcon feature list under the heading.
summaryTitlestring"Today's summary"Title at the top of the summary card.
summaryDatestringundefinedBadge next to the summary title; only rendered when set.
heartRatenumbernoneResting heart rate in bpm, shown as a static number.
heartRateLabelstring"Resting heart rate"Label above the heart rate value.
stepsnumbernoneStep count for the day, shown as a static number with comma formatting.
stepsGoalnumbernoneStep goal; drives the activity bar's fill as steps / stepsGoal, clamped to 100%.
activityLabelstring"Steps"Label above the step count.
recoveryScorenumbernone0-100 recovery score driving the static SVG ring's fill.
recoveryLabelstring"Recovery score"Label next to the recovery ring.
classNamestringnoneExtra classes for the outer section element.

Types

type Highlight = {
  icon: LucideIcon;
  title: string;
  description: string;
};

Behavior notes

  • heartRate, steps, stepsGoal, and recoveryScore are all static number props read once at render time; nothing here polls a device or updates after mount.
  • steps and stepsGoal are formatted with a locale-independent comma inserter (a fixed regex, not Intl/toLocaleString) so the digit grouping can't differ between server and client rendering.
  • The activity bar's width and the recovery ring's strokeDashoffset are both clamped to a 0-100% range, so an out-of-range prop can't overflow the bar or overshoot the ring.
  • Each highlight's icon is a hardcoded LucideIcon component reference passed as a prop; this block is a plain server component, so passing a component reference as a prop is safe here (would not be if this were a "use client" block).