import { TrendingUp, Trophy } from 'lucide-react'; import { motion } from 'framer-motion'; import { GlassCard } from '../shared/GlassCard'; import { CardIcon } from '../shared/CardIcon'; interface WinItem { id: string; label: string; delta: string; } interface WinsCardProps { totalVisits: number; trend: number; estimatedHumanReach: number; className?: string; delay?: number; } function formatCount(n: number): string { if (n >= 1000) return `+${(n / 1000).toFixed(1)}k`; return `+${n}`; } export function WinsCard({ totalVisits, trend, estimatedHumanReach, className = '', delay = 0 }: WinsCardProps) { const items: WinItem[] = []; if (totalVisits > 0) items.push({ id: 'visits', label: 'Crawler visits', delta: formatCount(totalVisits) }); if (trend > 0) items.push({ id: 'trend', label: 'Visibility improvement', delta: `+${trend}%` }); if (estimatedHumanReach > 0) items.push({ id: 'reach', label: 'Est. human reach', delta: formatCount(estimatedHumanReach) }); return (

Wins this week!

{items.length === 0 ? (
Your wins are loading. Keep optimizing! Every widget you improve gets you closer to your first win.
) : ( )}
); }