Skip to content

Commit

Permalink
Merge make snackbar permanent #212
Browse files Browse the repository at this point in the history
Closes #154
  • Loading branch information
MiraGeowerkstatt authored Aug 2, 2022
2 parents 884369e + fae03bb commit 05552c1
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/ClientApp/src/components/SnackbarMessage.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,11 @@ import Snackbar from "@mui/material/Snackbar";
export default function SnackbarMessage(props) {
const { showSuccessAlert, setShowSuccessAlert, message, variant } = props;
return (
<Snackbar open={showSuccessAlert} autoHideDuration={5000} onClose={() => setShowSuccessAlert(false)}>
<Snackbar
open={showSuccessAlert}
ClickAwayListenerProps={{ mouseEvent: false, touchEvent: false }}
onClose={() => setShowSuccessAlert(false)}
>
<Alert onClose={() => setShowSuccessAlert(false)} severity={variant} sx={{ width: "100%" }}>
{message}
</Alert>
Expand Down

0 comments on commit 05552c1

Please sign in to comment.