diff options
author | Dessalines <tyhou13@gmx.com> | 2020-01-22 22:29:11 -0500 |
---|---|---|
committer | Dessalines <tyhou13@gmx.com> | 2020-01-22 22:29:11 -0500 |
commit | 3b4258096c3c3dc160090436c9205e1ecf2e8e75 (patch) | |
tree | f07264d3de3b169c6140b2bf303ff7732d908b0a /ui/src/components/navbar.tsx | |
parent | 66af9623d90aadd47c9cf37faeac4f60f1d818d4 (diff) |
Adding a toaster to replace alerts. Fixes #457
Diffstat (limited to 'ui/src/components/navbar.tsx')
-rw-r--r-- | ui/src/components/navbar.tsx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ui/src/components/navbar.tsx b/ui/src/components/navbar.tsx index 85a54987..81124f77 100644 --- a/ui/src/components/navbar.tsx +++ b/ui/src/components/navbar.tsx @@ -22,6 +22,7 @@ import { showAvatars, fetchLimit, isCommentType, + toast, } from '../utils'; import { version } from '../version'; import { i18n } from '../i18next'; @@ -318,7 +319,7 @@ export class Navbar extends Component<any, NavbarState> { if (UserService.Instance.user) { document.addEventListener('DOMContentLoaded', function() { if (!Notification) { - alert(i18n.t('notifications_error')); + toast(i18n.t('notifications_error'), 'danger'); return; } |