Messes with the animation of the "Copied" snackbar in auth

This commit is contained in:
Manav Rathi 2025-02-04 17:04:57 +05:30
parent 7e50de6e61
commit 383b7542c8
No known key found for this signature in database
4 changed files with 9 additions and 4 deletions

View File

@ -1035,6 +1035,7 @@ const ConversionFailedNotification: React.FC<
<Snackbar
open={open}
anchorOrigin={{ vertical: "bottom", horizontal: "right" }}
sx={(theme) => ({ boxShadow: theme.vars.palette.boxShadow.menu })}
>
<Paper sx={{ width: "320px" }}>
<Button

View File

@ -148,7 +148,11 @@ const UploadProgressContext = createContext<UploadProgressContextT>({
});
const MinimizedUploadProgress: React.FC = () => (
<Snackbar open anchorOrigin={{ horizontal: "right", vertical: "bottom" }}>
<Snackbar
open
anchorOrigin={{ horizontal: "right", vertical: "bottom" }}
sx={(theme) => ({ boxShadow: theme.vars.palette.boxShadow.menu })}
>
<Paper sx={{ width: "min(360px, 100svw)" }}>
<UploadProgressHeader />
</Paper>

View File

@ -804,7 +804,6 @@ const components: Components = {
// Set a default border radius for all snackbar's (e.g.
// notification popups).
borderRadius: "8px",
boxShadow: "var(--mui-palette-boxShadow-menu)",
},
},
},

View File

@ -141,14 +141,15 @@ export const Notification: React.FC<NotificationProps> = ({
vertical: vertical ?? "bottom",
}}
sx={[
{
(theme) => ({
width: "min(320px, 100vw)",
// If the `color` of the button is a translucent one, e.g.
// "secondary", then the notification becomes opaque, which
// is not what we want. So give the entire snackbar a solid
// background color.
backgroundColor: "background.default",
},
boxShadow: theme.vars.palette.boxShadow.menu,
}),
...(sx ? (isSxArray(sx) ? sx : [sx]) : []),
]}
>