"use client"; interface Props { title: string; mean7d: number; annualized: number; accent: "cyan" | "violet" | "emerald"; } const accentMap = { cyan: { border: "border-cyan-500/30", bg: "bg-cyan-500/10", text: "text-cyan-400", label: "text-cyan-300", }, violet: { border: "border-violet-500/30", bg: "bg-violet-500/10", text: "text-violet-400", label: "text-violet-300", }, emerald: { border: "border-emerald-500/30", bg: "bg-emerald-500/10", text: "text-emerald-400", label: "text-emerald-300", }, }; export default function StatsCard({ title, mean7d, annualized, accent }: Props) { const c = accentMap[accent]; const isPositive = annualized >= 0; return (

{title}

预估年化收益率

{annualized >= 0 ? "+" : ""}{annualized.toFixed(2)}%

7天均值费率

{mean7d >= 0 ? "+" : ""}{mean7d.toFixed(4)}% / 8h

); }