Commit 036c942f authored by chenshouchao's avatar chenshouchao

fix: 小的确认弹窗组件图标增加默认宽度解决弹窗定位错位的问题, 按钮组件增加不换行属性

parent 55e5598b
......@@ -126,6 +126,13 @@ const theme = createTheme({
},
},
},
MuiTypography: {
styleOverrides: {
root: {
whiteSpace: "nowrap",
},
},
},
},
});
......
......@@ -30,7 +30,7 @@ interface IMyPopconfirmProps {
showCancel?: boolean;
onCancel?: any;
onConfirm?: any;
};
}
const MyPopconfirm = (props: IMyPopconfirmProps) => {
const {
......@@ -75,7 +75,12 @@ const MyPopconfirm = (props: IMyPopconfirmProps) => {
>
<Box sx={{ marginBottom: "16px" }}>
<img
style={{ marginRight: "12px", position: "relative", top: "3px" }}
style={{
width: "16px",
marginRight: "12px",
position: "relative",
top: "3px",
}}
src={tipsIcon}
alt=""
/>
......@@ -85,18 +90,14 @@ const MyPopconfirm = (props: IMyPopconfirmProps) => {
{showCancel && (
<MyButton
text={cancelText}
variant='outlined'
variant="outlined"
size="small"
color="inherit"
onClick={handleCancel}
style={{ marginRight: "12px" }}
/>
)}
<MyButton
text={okText}
size="small"
onClick={handleOk}
/>
<MyButton text={okText} size="small" onClick={handleOk} />
</Box>
</Popper>
);
......
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