diff --git a/components/Dashboard.tsx b/components/Dashboard.tsx index d2c94e5..4a00aed 100644 --- a/components/Dashboard.tsx +++ b/components/Dashboard.tsx @@ -508,21 +508,21 @@ const Dashboard: React.FC = ({ data, contextData, adsData = [] } return (
- {/* Ads Performance Section - Supports Multiple Years and Growth */} + {/* Ads Performance Section - Condensed Layout */} {adsKPIsByYear && availableAdsYears.length > 0 && ( -
-
+
+
- +
-

Advertising Performance Breakdown

-
- {adsData.length.toLocaleString('de-DE')} AD RECORDS LOADED +

Advertising Performance

+
+ {adsData.length.toLocaleString('de-DE')} Records
-
+
1 ? 'grid-cols-1 lg:grid-cols-2' : 'grid-cols-1'}`}> {availableAdsYears.map((year, idx) => { const kpi = adsKPIsByYear[year]; const prevYear = availableAdsYears[idx + 1]; @@ -537,54 +537,55 @@ const Dashboard: React.FC = ({ data, contextData, adsData = [] } : (isPositive ? 'text-emerald-400' : 'text-red-400'); return ( - - {isPositive ? '▲' : '▼'}{Math.abs(pct).toFixed(1)}% + + {isPositive ? '▲' : '▼'}{Math.abs(pct).toFixed(0)}% ); }; return ( -
-
- {year} +
+
+ {year}
-
+ +
{/* Ad Spend */} -
- Ad Spend -
- +
+ Spend +
+ €{kpi.totalSpend.toLocaleString('de-DE', { maximumFractionDigits: 0 })} {renderGrowth(kpi.totalSpend, prevKpi?.totalSpend)}
{/* Attributed Sales */} -
- Attr. Sales -
- +
+ Sales +
+ €{kpi.attributedSales.toLocaleString('de-DE', { maximumFractionDigits: 0 })} {renderGrowth(kpi.attributedSales, prevKpi?.attributedSales)}
{/* ACOS */} -
- ACOS -
- +
+ ACOS +
+ {kpi.acos.toFixed(1)}% {renderGrowth(kpi.acos, prevKpi?.acos, true)}
{/* ROAS */} -
- ROAS -
- = 3 ? 'text-emerald-400' : kpi.roas >= 2 ? 'text-amber-400' : 'text-red-400'}`}> +
+ ROAS +
+ = 3 ? 'text-emerald-400' : kpi.roas >= 2 ? 'text-amber-400' : 'text-red-400'}`}> {kpi.roas.toFixed(2)}x {renderGrowth(kpi.roas, prevKpi?.roas)}