From fdacda9b9d243e617b6f699e15955db413b84b43 Mon Sep 17 00:00:00 2001 From: tamaina Date: Wed, 10 Feb 2021 02:04:15 +0900 Subject: [PATCH] wip --- src/client/sw/notification.ts | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/client/sw/notification.ts b/src/client/sw/notification.ts index 23acc461ae..1a29844993 100644 --- a/src/client/sw/notification.ts +++ b/src/client/sw/notification.ts @@ -58,60 +58,60 @@ class SwNotification { } ] }]; - + case 'reply': return [t('_notification.youGotReply', { name: getUserName(data.body.user) }), { body: getNoteSummary(data.body.note, i18n.locale), icon: data.body.user.avatarUrl }]; - + case 'renote': return [t('_notification.youRenoted', { name: getUserName(data.body.user) }), { body: getNoteSummary(data.body.note, i18n.locale), icon: data.body.user.avatarUrl }]; - + case 'quote': return [t('_notification.youGotQuote', { name: getUserName(data.body.user) }), { body: getNoteSummary(data.body.note, i18n.locale), icon: data.body.user.avatarUrl }]; - + case 'reaction': return [`${data.body.reaction} ${getUserName(data.body.user)}`, { body: getNoteSummary(data.body.note, i18n.locale), icon: data.body.user.avatarUrl }]; - + case 'pollVote': return [t('_notification.youGotPoll', { name: getUserName(data.body.user) }), { body: getNoteSummary(data.body.note, i18n.locale), icon: data.body.user.avatarUrl }]; - + case 'follow': return [t('_notification.youWereFollowed'), { body: getUserName(data.body.user), icon: data.body.user.avatarUrl }]; - + case 'receiveFollowRequest': return [t('_notification.youReceivedFollowRequest'), { body: getUserName(data.body.user), icon: data.body.user.avatarUrl }]; - + case 'followRequestAccepted': return [t('_notification.yourFollowRequestAccepted'), { body: getUserName(data.body.user), icon: data.body.user.avatarUrl }]; - + case 'groupInvited': return [t('_notification.youWereInvitedToGroup'), { body: data.body.group.name }]; - + default: return null; } @@ -130,7 +130,7 @@ class SwNotification { return null; } } - + } export const swNotification = new SwNotification();