'use client'; import { AuthGuard } from '@/components/AuthGuard'; import { DashboardLayout } from '@/components/DashboardLayout'; import { useQuery } from '@tanstack/react-query'; import { mailAccountsApi, processingRunsApi } from '@/lib/api'; import { Mail, Send, CheckCircle, AlertCircle, TrendingUp, Clock } from 'lucide-react'; interface StatCardProps { title: string; value: string | number; icon: React.ComponentType<{ className?: string }>; iconColor: string; trend?: string; } function StatCard({ title, value, icon: Icon, iconColor, trend }: StatCardProps) { return (
{title}
{value}
{trend && (| Account | Started At | Status | Fetched | Forwarded | Errors |
|---|---|---|---|---|---|
| {account?.name || `Account ${run.mail_account_id}`} |
|
{run.status} | {run.emails_fetched} | {run.emails_forwarded} | {run.emails_failed > 0 ? ( {run.emails_failed} ) : ( 0 )} |
No processing runs yet