skyouc
2025-07-21 5c1bbc7ee63ecf6e2c7bd3e519608a44a9210679
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
import { IconButton } from '@mui/material';
import CloseIcon from '@mui/icons-material/Close';
 
const DialogCloseButton = (props) => {
    const {
        onClose,
        top = 8,
        right = 8,
        color,
    } = props;
 
    return (
        <>
            <IconButton
                aria-label="close"
                onClick={onClose}
                sx={{
                    position: 'absolute',
                    right,
                    top,
                    color: theme => (color ? color : theme.palette.grey[500]),
                }}
            >
                <CloseIcon />
            </IconButton>
        </>
    );
};
 
export default DialogCloseButton;