EmptyState: Apply completed empty state in Notifications page (#86504)

* add 'completed' variant

* apply completed empty state to notifications page
This commit is contained in:
Ashley Harrison 2024-04-19 13:46:03 +01:00 committed by GitHub
parent ec1af89a02
commit 4a9e478a6b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 13 additions and 5 deletions

View File

@ -3,8 +3,9 @@ import React, { useRef, useState } from 'react';
import { useEffectOnce } from 'react-use';
import { GrafanaTheme2 } from '@grafana/data';
import { Alert, Button, Checkbox, Icon, useStyles2 } from '@grafana/ui';
import { Alert, Button, Checkbox, EmptyState, useStyles2 } from '@grafana/ui';
import { StoredNotificationItem } from 'app/core/components/AppNotifications/StoredNotificationItem';
import { Trans, t } from 'app/core/internationalization';
import {
clearAllNotifications,
clearNotification,
@ -55,10 +56,9 @@ export function StoredNotifications() {
if (notifications.length === 0) {
return (
<div className={styles.noNotifsWrapper}>
<Icon name="bell" size="xxl" />
<span>Notifications you have received will appear here.</span>
</div>
<EmptyState variant="completed" message={t('notifications.empty-state.title', "You're all caught up!")}>
<Trans i18nKey="notifications.empty-state.description">Notifications you have received will appear here</Trans>
</EmptyState>
);
}

View File

@ -1163,6 +1163,10 @@
"title": "Latest from the blog"
},
"notifications": {
"empty-state": {
"description": "Notifications you have received will appear here",
"title": "You're all caught up!"
},
"starred-dashboard": "Dashboard starred",
"unstarred-dashboard": "Dashboard unstarred"
},

View File

@ -1163,6 +1163,10 @@
"title": "Ŀäŧęşŧ ƒřőm ŧĥę þľőģ"
},
"notifications": {
"empty-state": {
"description": "Ńőŧįƒįčäŧįőʼnş yőū ĥävę řęčęįvęđ ŵįľľ äppęäř ĥęřę",
"title": "Ÿőū'řę äľľ čäūģĥŧ ūp!"
},
"starred-dashboard": "Đäşĥþőäřđ şŧäřřęđ",
"unstarred-dashboard": "Đäşĥþőäřđ ūʼnşŧäřřęđ"
},