forked from jordanlambrecht/tracker-tracker
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathFleetActivity.tsx
More file actions
31 lines (25 loc) · 856 Bytes
/
Copy pathFleetActivity.tsx
File metadata and controls
31 lines (25 loc) · 856 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
// src/components/dashboard/FleetActivity.tsx
"use client"
import type { TodayAtAGlance } from "@/types/api"
interface FleetActivityProps {
activity: TodayAtAGlance["activity"]
}
export function FleetActivity({ activity }: FleetActivityProps) {
const { addedToday, completedToday } = activity
if (addedToday === 0 && completedToday === 0) {
return <p className="text-sm font-mono text-muted">No fleet activity today</p>
}
return (
<div className="flex items-center gap-3 text-sm font-mono text-secondary">
<span>
<span className="text-primary font-semibold">{addedToday}</span>
{" added today"}
</span>
<span className="text-muted">·</span>
<span>
<span className="text-primary font-semibold">{completedToday}</span>
{" completed today"}
</span>
</div>
)
}