All checks were successful
Deploy to Test Environment / deploy-to-test (push) Successful in 16m0s
35 lines
1022 B
TypeScript
35 lines
1022 B
TypeScript
// src/components/StatCard.tsx
|
|
import React, { ReactNode } from 'react';
|
|
|
|
interface StatCardProps {
|
|
title: string;
|
|
value: string;
|
|
icon: ReactNode;
|
|
}
|
|
|
|
export const StatCard: React.FC<StatCardProps> = ({ title, value, icon }) => {
|
|
return (
|
|
<div className="bg-white dark:bg-gray-800 overflow-hidden shadow rounded-lg">
|
|
<div className="p-5">
|
|
<div className="flex items-center">
|
|
<div className="flex-shrink-0">
|
|
<div className="flex items-center justify-center h-12 w-12 rounded-md bg-blue-500 text-white">
|
|
{icon}
|
|
</div>
|
|
</div>
|
|
<div className="ml-5 w-0 flex-1">
|
|
<dl>
|
|
<dt className="text-sm font-medium text-gray-500 dark:text-gray-400 truncate">
|
|
{title}
|
|
</dt>
|
|
<dd>
|
|
<div className="text-lg font-medium text-gray-900 dark:text-white">{value}</div>
|
|
</dd>
|
|
</dl>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
);
|
|
};
|