Open sparakala21 opened 11 months ago
Let me clarify that in some places we do Window.alert() that is not React friendly. These should be switched to the new methods in src/client/app/utils/notifications.ts that use a React way. Care should be taken to set the time (autoDismiss) if the desire is that the notice stay up for a very long time (or indefinitely in some cases). It is also important to choose the right one (success or failure). Anyone doing this that has questions is welcome to reach out to me.
After PR #1113, the only ones left are Window.confirm. It would be good to find a confirmation dialog that is compatible with the toast notifications that are used.
Is your feature request related to a problem? Please describe.
Currently, our application relies on generic alerts for error and success notifications. While these have served their purpose, it's become evident that we need a more robust and consistent solution, especially when dealing with React components. The current approach lacks the flexibility and reliability required for a modern React application.
Describe the solution you'd like
Introducing showErrorNotification and showSuccessNotification functions which will enhance the user experience and provide better control over the presentation of notifications.
Additional context
check out PR #1065 for some ideas