"use client" import type { ReactNode } from "react" import { Card, CardContent, CardHeader, CardTitle } from "@/app/components/ui/card" import { TrendingUp, TrendingDown, Minus } from "lucide-react" interface StatCardProps { title: string value: string | number icon?: ReactNode change?: { value: string | number type: "increase" | "decrease" | "neutral" label?: string } description?: string } export function StatCard({ title, value, icon, change, description }: StatCardProps) { const getChangeIcon = () => { switch (change?.type) { case "increase": return case "decrease": return default: return } } const getChangeColor = () => { switch (change?.type) { case "increase": return "text-green-600" case "decrease": return "text-red-600" default: return "text-muted-foreground" } } return ( {title} {icon &&
{icon}
}
{value}
{change && (
{getChangeIcon()} {change.value} {change.label}
)} {description &&

{description}

}
) } interface StatCardGroupProps { cards: StatCardProps[] } export function StatCardGroup({ cards }: StatCardGroupProps) { return (
{cards.map((card, index) => ( ))}
) }