Commit 5b80b9f1 authored by chenshouchao's avatar chenshouchao

feat: message组件成功图标替换

parent 8cd0006e
<?xml version="1.0" encoding="UTF-8"?>
<svg width="16px" height="16px" viewBox="0 0 16 16" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>check-circle-outline备份</title>
<g id="云平台视觉规范" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
<g id="check-circle-outline备份" fill="#0DD09B" fill-rule="nonzero">
<path d="M8,0 C3.6,0 0,3.6 0,8 C0,12.4 3.6,16 8,16 C12.4,16 16,12.4 16,8 C16,3.6 12.4,0 8,0 M8,14.4 C4.472,14.4 1.6,11.528 1.6,8 C1.6,4.472 4.472,1.6 8,1.6 C11.528,1.6 14.4,4.472 14.4,8 C14.4,11.528 11.528,14.4 8,14.4 M11.672,4.464 L6.4,9.736 L4.328,7.672 L3.2,8.8 L6.4,12 L12.8,5.6 L11.672,4.464 Z" id="形状"></path>
</g>
</g>
</svg>
\ No newline at end of file
import React, { Fragment, ReactNode, useMemo } from "react";
import React, { Fragment, ReactNode } from "react";
import { Snackbar, Alert, Fade, Grow } from "@mui/material";
import useMySnackbar from "./useMySnackbar";
import snackbarContext from "./snackbarContext";
import { ThemeProvider, createTheme } from "@mui/material/styles";
import successIconSrc from "../../assets/project/successIcon.svg";
type MySnackbarProviderProp = {
vertical?: "bottom" | "top";
......@@ -22,7 +23,6 @@ type MySnackbarProviderProp = {
variant?: "filled" | "outlined" | "standard";
errorIcon?: ReactNode;
infoIcon?: ReactNode;
successIcon?: ReactNode;
warningIcon?: ReactNode;
elevation?: number;
alertSx?: object;
......@@ -58,7 +58,6 @@ const MySnackbarProvider = ({
variant = "standard",
errorIcon,
infoIcon,
successIcon,
warningIcon,
elevation = 3,
alertSx,
......@@ -122,6 +121,14 @@ const MySnackbarProvider = ({
},
});
const successIcon = (
<img
src={successIconSrc}
style={{ width: "16px", height: "16px", margin: "3px 0" }}
alt=""
/>
);
return (
<Fragment>
<ThemeProvider theme={theme}>
......
......@@ -223,7 +223,8 @@ const ProjectSubmitWork = observer(() => {
promotedParameters,
});
} else {
Message.error("请完善算子信息后提交任务");
// Message.error("请完善算子信息后提交任务");
Message.success("请完善算子信息后提交任务");
}
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment