Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions clips-frontend/app/earnings/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,8 @@ export default function EarningsPage() {
<div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6">
<StatCard label="Total Earned" value={`$${summary.total}`} trend="+12.5%" icon={DollarSign} />
<StatCard label="Completed" value={`$${summary.completed}`} trend="+8.2%" icon={TrendingUp} />
<StatCard label="Pending Payout" value={`$${summary.pending}`} trend="Processing" icon={Wallet} />
<StatCard label="Tax Ready" value="✅ Yes" trend="Exportable" icon={FileText} />
<StatCard label="Pending Payout" value={`$${summary.pending}`} trend="Processing" icon={Wallet} hideTrendIcon />
<StatCard label="Tax Ready" value="✅ Yes" trend="Exportable" icon={FileText} hideTrendIcon />
</div>

{/* Table */}
Expand Down
5 changes: 3 additions & 2 deletions clips-frontend/components/dashboard/StatCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,10 @@ interface StatCardProps {
trend: string;
isPositive?: boolean;
icon: LucideIcon;
hideTrendIcon?: boolean;
}

export default function StatCard({ label, value, trend, isPositive = true, icon: Icon }: StatCardProps) {
export default function StatCard({ label, value, trend, isPositive = true, icon: Icon, hideTrendIcon = false }: StatCardProps) {
return (
<div className="bg-surface border border-border rounded-[24px] p-8 flex flex-col gap-6 relative overflow-hidden group hover:border-brand/20 transition-all duration-300">
<div className="flex items-center justify-between">
Expand All @@ -24,7 +25,7 @@ export default function StatCard({ label, value, trend, isPositive = true, icon:
<div className="flex items-end gap-3">
<h3 className="text-[32px] font-extrabold text-white leading-none font-mono">{value}</h3>
<div className={`flex items-center gap-1 text-[13px] font-bold pb-1 ${isPositive ? "text-brand" : "text-error"}`}>
{isPositive ? <TrendingUp className="w-4 h-4" /> : <TrendingDown className="w-4 h-4" />}
{!hideTrendIcon && (isPositive ? <TrendingUp className="w-4 h-4" /> : <TrendingDown className="w-4 h-4" />)}
<span>{trend}</span>
</div>
</div>
Expand Down