From 633d32d4fed310709eebb286f789c9178a65404a Mon Sep 17 00:00:00 2001 From: luxiaotao1123 <t1341870251@163.com> Date: 星期四, 17 十月 2024 15:16:40 +0800 Subject: [PATCH] # --- zy-acs-flow/src/map/insight/agv/AgvMain.jsx | 4 +++- zy-acs-flow/src/map/insight/BoolValueIcon.jsx | 8 +++++--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/zy-acs-flow/src/map/insight/BoolValueIcon.jsx b/zy-acs-flow/src/map/insight/BoolValueIcon.jsx index 1183b95..deaf5cc 100644 --- a/zy-acs-flow/src/map/insight/BoolValueIcon.jsx +++ b/zy-acs-flow/src/map/insight/BoolValueIcon.jsx @@ -1,12 +1,14 @@ import React from 'react'; -import { CheckCircle, Cancel } from '@mui/icons-material'; +import { useTheme } from '@mui/material'; +import { Check, Close } from '@mui/icons-material'; import { green, red } from '@mui/material/colors'; const BoolValueIcon = ({ value }) => { + const theme = useTheme(); return value ? ( - <CheckCircle style={{ color: green[500] }} /> + <Check style={{ color: theme.palette.primary.main, fontSize: '24px' }} /> ) : ( - <Cancel style={{ color: red[500] }} /> + <Close style={{ color: theme.palette.error.main, fontSize: '24px' }} /> ); }; diff --git a/zy-acs-flow/src/map/insight/agv/AgvMain.jsx b/zy-acs-flow/src/map/insight/agv/AgvMain.jsx index 0b120da..128380a 100644 --- a/zy-acs-flow/src/map/insight/agv/AgvMain.jsx +++ b/zy-acs-flow/src/map/insight/agv/AgvMain.jsx @@ -10,6 +10,7 @@ Button, Divider, Stack, + useTheme, } from '@mui/material'; import AgvThree from './AgvThree'; import { getAgvInfo } from '../../http'; @@ -77,6 +78,7 @@ const AgvMain = (props) => { const { data, curAgvNo, setCurAgvNo } = props; + const theme = useTheme(); const translate = useTranslate(); const containerRef = useRef(); const [loading, setLoading] = useState(true); @@ -173,7 +175,7 @@ <Stack spacing={2} mt={2}> <ConfirmButton label="page.map.action.reset" - color="info" + color="primary" variant="contained" onConfirm={() => { alert(1) -- Gitblit v1.9.1