OPUS/UI

Navigation

Statistic

KPI card — label, big value, coloured delta (with polarity for costs/latency), icon and a trend sparkline.

3 files · 146 locdeps: clsx, tailwind-merge
Revenue
$84,210
12.4%vs last month
Active users
12,903
4.1%last 30 days
p95 latency
182 ms
8.7%regressed

Installation

With the shadcn CLI, pointing at this platform’s registry:

npx shadcn@latest add https://opusui.131199999.xyz/r/statistic.json

Or offline, straight from your opus55 checkout (copies every file it needs):

node ../tailwind_component/opus55/scripts/add.mjs statistic

Usage

import { Statistic } from "@/components/opus/ui/statistic";

<Statistic label="Revenue" value="$84,210" delta={12.4} trend={series} />

API

PropTypeDefaultDescription
label / value / hint / iconReactNode—Content.
deltanumber—Percent change.
polarity"up-good" | "up-bad""up-good"Which direction is green.
trendnumber[]—Sparkline data.

Command palette