Skip to content

Commit 36ed4c0

Browse files
feat: update StatsCards component with localized descriptions and improved metrics
1 parent 0a911b7 commit 36ed4c0

1 file changed

Lines changed: 23 additions & 21 deletions

File tree

  • UIs/Merchants/src/features/dashboard/components/stats

UIs/Merchants/src/features/dashboard/components/stats/index.tsx

Lines changed: 23 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@ import {
77
CardHeader,
88
CardTitle
99
} from '@/shared/components/ui/card';
10-
import { TrendingDown, TrendingUp } from 'lucide-react';
10+
import { TrendingUp } from 'lucide-react';
1111

1212
export function StatsCards() {
1313
return (
1414
<section className="*:data-[slot=card]:from-primary/5 *:data-[slot=card]:to-card dark:*:data-[slot=card]:bg-card grid grid-cols-1 gap-4 px-4 *:data-[slot=card]:bg-gradient-to-t *:data-[slot=card]:shadow-xs lg:px-6 @xl/main:grid-cols-2 @5xl/main:grid-cols-4">
1515
<Card className="@container/card">
1616
<CardHeader>
17-
<CardDescription>Total Revenue</CardDescription>
17+
<CardDescription>Receita Total</CardDescription>
1818
<CardTitle className="text-2xl font-semibold tabular-nums @[250px]/card:text-3xl">
1919
$1,250.00
2020
</CardTitle>
@@ -27,73 +27,75 @@ export function StatsCards() {
2727
</CardHeader>
2828
<CardFooter className="flex-col items-start gap-1.5 text-sm">
2929
<div className="line-clamp-1 flex gap-2 font-medium">
30-
Trending up this month <TrendingUp className="size-4" />
31-
</div>
32-
<div className="text-muted-foreground">
33-
Visitors for the last 6 months
30+
Crescimento este mês <TrendingUp className="size-4" />
3431
</div>
32+
<div className="text-muted-foreground">Faturamento do último mês</div>
3533
</CardFooter>
3634
</Card>
3735
<Card className="@container/card">
3836
<CardHeader>
39-
<CardDescription>New Customers</CardDescription>
37+
<CardDescription>Pedidos Realizados</CardDescription>
4038
<CardTitle className="text-2xl font-semibold tabular-nums @[250px]/card:text-3xl">
4139
1,234
4240
</CardTitle>
4341
<CardAction>
4442
<Badge variant="outline">
45-
<TrendingDown />
46-
-20%
43+
<TrendingUp />
44+
+18%
4745
</Badge>
4846
</CardAction>
4947
</CardHeader>
5048
<CardFooter className="flex-col items-start gap-1.5 text-sm">
5149
<div className="line-clamp-1 flex gap-2 font-medium">
52-
Down 20% this period <TrendingDown className="size-4" />
50+
Crescimento de pedidos <TrendingUp className="size-4" />
5351
</div>
5452
<div className="text-muted-foreground">
55-
Acquisition needs attention
53+
Total de pedidos este mês
5654
</div>
5755
</CardFooter>
5856
</Card>
5957
<Card className="@container/card">
6058
<CardHeader>
61-
<CardDescription>Active Accounts</CardDescription>
59+
<CardDescription>Ticket Médio</CardDescription>
6260
<CardTitle className="text-2xl font-semibold tabular-nums @[250px]/card:text-3xl">
63-
45,678
61+
$45.67
6462
</CardTitle>
6563
<CardAction>
6664
<Badge variant="outline">
6765
<TrendingUp />
68-
+12.5%
66+
+5.2%
6967
</Badge>
7068
</CardAction>
7169
</CardHeader>
7270
<CardFooter className="flex-col items-start gap-1.5 text-sm">
7371
<div className="line-clamp-1 flex gap-2 font-medium">
74-
Strong user retention <TrendingUp className="size-4" />
72+
Aumentando valor por pedido <TrendingUp className="size-4" />
73+
</div>
74+
<div className="text-muted-foreground">
75+
Valor médio dos pedidos
7576
</div>
76-
<div className="text-muted-foreground">Engagement exceed targets</div>
7777
</CardFooter>
7878
</Card>
7979
<Card className="@container/card">
8080
<CardHeader>
81-
<CardDescription>Growth Rate</CardDescription>
81+
<CardDescription>Taxa de Crescimento</CardDescription>
8282
<CardTitle className="text-2xl font-semibold tabular-nums @[250px]/card:text-3xl">
83-
4.5%
83+
8.3%
8484
</CardTitle>
8585
<CardAction>
8686
<Badge variant="outline">
8787
<TrendingUp />
88-
+4.5%
88+
+8.3%
8989
</Badge>
9090
</CardAction>
9191
</CardHeader>
9292
<CardFooter className="flex-col items-start gap-1.5 text-sm">
9393
<div className="line-clamp-1 flex gap-2 font-medium">
94-
Steady performance increase <TrendingUp className="size-4" />
94+
Performance em crescimento <TrendingUp className="size-4" />
95+
</div>
96+
<div className="text-muted-foreground">
97+
Crescimento mês a mês
9598
</div>
96-
<div className="text-muted-foreground">Meets growth projections</div>
9799
</CardFooter>
98100
</Card>
99101
</section>

0 commit comments

Comments
 (0)