diff --git a/pkgs/ui/src/app/nodes/NodeList.tsx b/pkgs/ui/src/app/nodes/NodeList.tsx index f00dee905..98ce5e182 100644 --- a/pkgs/ui/src/app/nodes/NodeList.tsx +++ b/pkgs/ui/src/app/nodes/NodeList.tsx @@ -194,9 +194,9 @@ function EnhancedTableToolbar(props: EnhancedTableToolbarProps) { ).length; return [ - { name: "Online", value: online, color: "#2E7D32" }, - { name: "Offline", value: offline, color: "#db3927" }, - { name: "Pending", value: pending, color: "#FFBB28" }, + { name: "Online", value: online, color: theme.palette.success.main }, + { name: "Offline", value: offline, color: theme.palette.error.main }, + { name: "Pending", value: pending, color: theme.palette.warning.main }, ]; }, [tableData]); @@ -230,7 +230,7 @@ function EnhancedTableToolbar(props: EnhancedTableToolbarProps) { height: 110, backgroundColor: hexRgb(pieItem.color, { format: "css", - alpha: 0.18, + alpha: 0.25, }), }} > @@ -338,7 +338,7 @@ function EnhancedTableToolbar(props: EnhancedTableToolbarProps) { {cardStack} @@ -426,6 +426,10 @@ export interface NodeTableProps { export default function NodeTable(props: NodeTableProps) { let { tableData } = props; + + const theme = useTheme(); + const is_xs = useMediaQuery(theme.breakpoints.only("xs")); + const [order, setOrder] = React.useState("asc"); const [orderBy, setOrderBy] = React.useState("status"); const [selected, setSelected] = React.useState(undefined); @@ -479,7 +483,7 @@ export default function NodeTable(props: NodeTableProps) { ); return ( - + - + ); } diff --git a/pkgs/ui/src/app/nodes/NodePieChart.tsx b/pkgs/ui/src/app/nodes/NodePieChart.tsx index 12ed80418..cc28e01ee 100644 --- a/pkgs/ui/src/app/nodes/NodePieChart.tsx +++ b/pkgs/ui/src/app/nodes/NodePieChart.tsx @@ -37,6 +37,20 @@ export default function NodePieChart(props: Props) { dataKey="value" nameKey="name" label={showLabels} + legendType="circle" + cx="50%" + cy="50%" + startAngle={0} + endAngle={360} + paddingAngle={0} + labelLine={true} + hide={false} + minAngle={0} + isAnimationActive={true} + animationBegin={0} + animationDuration={1000} + animationEasing="ease-in" + blendStroke={true} > {data.map((entry, index) => ( diff --git a/pkgs/ui/src/app/nodes/page.tsx b/pkgs/ui/src/app/nodes/page.tsx index 3e4190ba9..b269e9773 100644 --- a/pkgs/ui/src/app/nodes/page.tsx +++ b/pkgs/ui/src/app/nodes/page.tsx @@ -4,15 +4,12 @@ import NodeList from "./NodeList"; import Box from "@mui/material/Box"; import { tableData } from "@/data/nodeData"; +import { StrictMode } from "react"; export default function Page() { return ( - + - + ); }