Closed
Labels
Description
Problem
The Insights KPI cards and the competitor leaderboard render raw numbers, so large counts show as 12345 instead of 12,345. Every sibling dashboard page (Citations, Traffic, Topics) formats counts with toLocaleString().
Evidence
Unformatted:
page.tsx#L309—KpiCardrenders{value}raw; fed withsummary!.totalMentions/summary!.totalCitationsat#L1534page.tsx#L238—+{current} newinCountDeltaBadge_charts.tsx#L686-L687—{entry.totalMentions} mentions/{entry.totalCitations} citationsin the leaderboard
Convention elsewhere: citations/page.tsx#L911, traffic/page.tsx#L660, topics/page.tsx#L533.
Suggested fix
Apply toLocaleString() at the render sites listed above (KPI numeric values, count delta badges, leaderboard mention/citation counts). formatCompactNumber from src/lib/format.ts is already imported in page.tsx if a compact form fits better in tight spots like the leaderboard.
Acceptance criteria
- KPI cards, delta badges, and leaderboard counts show thousands separators for values ≥ 1,000.
- Score values (one-decimal 0–100) are unaffected.
Activity