Notification toasts, nicer loading, add new user support

This commit is contained in:
Jamie Curnow
2025-09-03 18:01:00 +10:00
parent fadec9751e
commit 61a92906f3
31 changed files with 401 additions and 215 deletions

View File

@@ -0,0 +1,27 @@
import { toast } from "react-toastify";
import { intl } from "src/locale";
import { Msg } from "./Msg";
import styles from "./Msg.module.css";
const showSuccess = (message: string) => {
toast(Msg, {
className: styles.toaster,
data: {
type: "success",
title: intl.formatMessage({ id: "notification.success" }),
message,
},
});
};
const showError = (message: string) => {
toast(<Msg />, {
data: {
type: "error",
title: intl.formatMessage({ id: "notification.error" }),
message,
},
});
};
export { showSuccess, showError };