From d01089a5b22dd23508e792d88a117d7d135fa2ce Mon Sep 17 00:00:00 2001 From: viown <48097677+viown@users.noreply.github.com> Date: Tue, 10 Jun 2025 21:46:49 +0300 Subject: [PATCH] Update grid layout --- .../dashboard/components/widgets/Widget.tsx | 28 ++++++++----------- src/apps/dashboard/routes/index.tsx | 15 +++++----- 2 files changed, 19 insertions(+), 24 deletions(-) diff --git a/src/apps/dashboard/components/widgets/Widget.tsx b/src/apps/dashboard/components/widgets/Widget.tsx index a413f1081..eac1e56a5 100644 --- a/src/apps/dashboard/components/widgets/Widget.tsx +++ b/src/apps/dashboard/components/widgets/Widget.tsx @@ -4,7 +4,6 @@ import Typography from '@mui/material/Typography'; import ChevronRight from '@mui/icons-material/ChevronRight'; import React from 'react'; import { Link as RouterLink } from 'react-router-dom'; -import Link from '@mui/material/Link'; type IProps = { title: string; @@ -15,26 +14,21 @@ type IProps = { const Widget = ({ title, href, children }: IProps) => { return ( - } + sx={{ + marginTop: 1, + marginBottom: 1 + }} > - - + + {title} + + {children} diff --git a/src/apps/dashboard/routes/index.tsx b/src/apps/dashboard/routes/index.tsx index 61eed6ed6..85c9e532c 100644 --- a/src/apps/dashboard/routes/index.tsx +++ b/src/apps/dashboard/routes/index.tsx @@ -28,6 +28,7 @@ import Link from '@mui/material/Link'; export const Component = () => { const theme = useTheme(); const isMedium = useMediaQuery(theme.breakpoints.only('md')); + const isExtraLarge = useMediaQuery(theme.breakpoints.only('xl')); const [ isRestartConfirmDialogOpen, setIsRestartConfirmDialogOpen ] = useState(false); const [ isShutdownConfirmDialogOpen, setIsShutdownConfirmDialogOpen ] = useState(false); const startTask = useStartTask(); @@ -134,8 +135,8 @@ export const Component = () => { confirmButtonColor='error' /> - - + + { - + - {isMedium ? ( - + {isMedium || isExtraLarge ? ( + @@ -159,10 +160,10 @@ export const Component = () => { ) : ( <> - + - +