Skip to content

Commit 44729aa

Browse files
authored
Merge pull request #4561 from ChayanDass/fix/confirmDialog
frontend: ConfirmDialog: Add responsive width
2 parents a0b115c + 2c43138 commit 44729aa

File tree

3 files changed

+7
-2
lines changed

3 files changed

+7
-2
lines changed

frontend/src/components/common/ConfirmDialog.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,11 @@ export function ConfirmDialog(props: ConfirmDialogProps) {
6868
onClose={handleClose}
6969
aria-labelledby="alert-dialog-title"
7070
aria-describedby="alert-dialog-description"
71+
PaperProps={{
72+
sx: {
73+
minWidth: 'clamp(280px, 25vw, 600px)',
74+
},
75+
}}
7176
>
7277
<DialogTitle id="alert-dialog-title">{title}</DialogTitle>
7378
<DialogContent ref={focusedRef} sx={{ py: 1 }}>

frontend/src/components/common/__snapshots__/ConfirmDialog.ConfirmDialog.stories.storyshot

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
<div
2727
aria-describedby="alert-dialog-description"
2828
aria-labelledby="alert-dialog-title"
29-
class="MuiPaper-root MuiPaper-outlined MuiPaper-rounded MuiDialog-paper MuiDialog-paperScrollPaper MuiDialog-paperWidthSm css-1708vl9-MuiPaper-root-MuiDialog-paper"
29+
class="MuiPaper-root MuiPaper-outlined MuiPaper-rounded MuiDialog-paper MuiDialog-paperScrollPaper MuiDialog-paperWidthSm css-1a0zqad-MuiPaper-root-MuiDialog-paper"
3030
role="dialog"
3131
>
3232
<h2

frontend/src/components/common/__snapshots__/ConfirmDialog.ConfirmDialogCancelHidden.stories.storyshot

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
<div
2727
aria-describedby="alert-dialog-description"
2828
aria-labelledby="alert-dialog-title"
29-
class="MuiPaper-root MuiPaper-outlined MuiPaper-rounded MuiDialog-paper MuiDialog-paperScrollPaper MuiDialog-paperWidthSm css-1708vl9-MuiPaper-root-MuiDialog-paper"
29+
class="MuiPaper-root MuiPaper-outlined MuiPaper-rounded MuiDialog-paper MuiDialog-paperScrollPaper MuiDialog-paperWidthSm css-1a0zqad-MuiPaper-root-MuiDialog-paper"
3030
role="dialog"
3131
>
3232
<h2

0 commit comments

Comments
 (0)