Lambchop
Data Display

MetricTrend

Compact metric display with delta percentage indicator.

import { MetricTrend } from "lambchop";

Live Demo

$14,520 8.3%vs last month
$9,870 4.2%
$28,750 15.6%
$6,340 3.1%

Usage

import { MetricTrend } from "lambchop";

<MetricTrend value="$14,520" delta={8.3} deltaLabel="vs last month" />

Props

PropTypeDefaultDescription
valuestring | numberThe metric value to display
deltanumberPercentage change (positive or negative)
deltaLabelstringOptional label next to the delta
size"sm" | "md" | "lg""md"Size variant
classNamestringAdditional CSS classes

Variants

  • Positive — Green delta indicator for growth
  • Negative — Red delta indicator for decline
  • Zero — Neutral indicator for no change
  • With Label — Shows contextual label like “vs last month”