Skip to content

Commit

Permalink
fixed ConfirmDialog styles (#2913)
Browse files Browse the repository at this point in the history
  • Loading branch information
nebby2105 authored Dec 3, 2024
1 parent 407abba commit f884090
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 10 deletions.
17 changes: 11 additions & 6 deletions src/components/confirm-dialog/ConfirmDialog.styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,24 @@ import { TypographyVariantEnum } from '~/types'

export const styles = {
root: {
minWidth: { xs: '280px', sm: '400px' }
minWidth: { xs: '280px', sm: '400px' },
maxWidth: '600px'
},
header: {
display: 'flex',
justifyContent: 'space-between',
px: '16px'
},
icon: {
position: 'absolute',
color: 'primary.600',
right: '32px',
top: '32px',
p: 0
p: 0,
mt: '20px',
alignSelf: 'start'
},
title: {
color: 'primary.700',
typography: TypographyVariantEnum.H5,
p: '26px 0px 20px 30px'
p: '20px 15px 15px 14px'
},
content: {
color: 'primary.600',
Expand Down
11 changes: 7 additions & 4 deletions src/components/confirm-dialog/ConfirmDialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import AppButton from '~/components/app-button/AppButton'
import { styles } from '~/components/confirm-dialog/ConfirmDialog.styles'

import { ButtonVariantEnum } from '~/types'
import { Box } from '@mui/material'

interface ConfirmDialogProps {
message: string
Expand Down Expand Up @@ -42,10 +43,12 @@ const ConfirmDialog: FC<ConfirmDialogProps> = ({
onClose={onDismiss}
open={open}
>
<Typography sx={styles.title}>{t(title)}</Typography>
<IconButton onClick={onDismiss} sx={styles.icon}>
<CloseIcon />
</IconButton>
<Box sx={styles.header}>
<Typography sx={styles.title}>{t(title)}</Typography>
<IconButton onClick={onDismiss} sx={styles.icon}>
<CloseIcon />
</IconButton>
</Box>
<DialogContent sx={styles.content}>
<Typography>{t(message)}</Typography>
</DialogContent>
Expand Down

0 comments on commit f884090

Please sign in to comment.