diff --git a/web/pages/components/statistic.tsx b/web/pages/components/statistic.tsx
index abe51849b..91cc5209d 100644
--- a/web/pages/components/statistic.tsx
+++ b/web/pages/components/statistic.tsx
@@ -1,25 +1,55 @@
-import { Statistic, Card, Col} from "antd";
+import { Typography, Statistic, Card, Col, Progress} from "antd";
+const { Text, Link } = Typography;
interface ItemProps {
title: string,
value: string,
prefix: JSX.Element,
+ color: string,
+ progress: boolean,
};
export default function StatisticItem(props: ItemProps) {
const { title, value, prefix } = props;
- const valueStyle = { color: "#334", fontSize: "1.8rem" };
+ const View = props.progress ? ProgressView : StatisticView;
return (
-
+
+
+
);
+}
+
+function ProgressView({title, value, prefix, color}) {
+ const endColor = value > 90 ? 'red' : color;
+ const content = (
+
+ {prefix}
+
{title}
+
{value}%
+
+ )
+ return (
+