From 2e60a8dc23b714160ebf9c7c4d1c8bf3851482d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pete=20An=C3=B8ther?= Date: Tue, 12 Mar 2024 13:25:39 -0300 Subject: [PATCH] EZQMS-459: Hoisted `showNotify` calculation to `ActivityNotificationPresenter` (#4937) Signed-off-by: Petr Vyazovetskiy --- .../components/reactions/ReactionNotificationPresenter.svelte | 3 ++- .../components/notification/ThreadNotificationPresenter.svelte | 2 +- .../components/inbox/ActivityInboxNotificationPresenter.svelte | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/plugins/activity-resources/src/components/reactions/ReactionNotificationPresenter.svelte b/plugins/activity-resources/src/components/reactions/ReactionNotificationPresenter.svelte index 8c2e00959a..bfb45f2ae3 100644 --- a/plugins/activity-resources/src/components/reactions/ReactionNotificationPresenter.svelte +++ b/plugins/activity-resources/src/components/reactions/ReactionNotificationPresenter.svelte @@ -53,6 +53,7 @@ value={parentMessage} skipLabel embedded + {showNotify} {withActions} {actions} {excludedActions} @@ -65,7 +66,7 @@ value={message} skipLabel showEmbedded - showNotify={showNotify && !notification.isViewed} + {showNotify} {withActions} {actions} {excludedActions} diff --git a/plugins/chunter-resources/src/components/notification/ThreadNotificationPresenter.svelte b/plugins/chunter-resources/src/components/notification/ThreadNotificationPresenter.svelte index da435ae29e..c573429974 100644 --- a/plugins/chunter-resources/src/components/notification/ThreadNotificationPresenter.svelte +++ b/plugins/chunter-resources/src/components/notification/ThreadNotificationPresenter.svelte @@ -36,6 +36,6 @@ {actions} {excludedActions} hoverable={false} - showNotify={showNotify && !notification.isViewed} + {showNotify} {onClick} /> diff --git a/plugins/notification-resources/src/components/inbox/ActivityInboxNotificationPresenter.svelte b/plugins/notification-resources/src/components/inbox/ActivityInboxNotificationPresenter.svelte index 2398b83f70..663e3b0e66 100644 --- a/plugins/notification-resources/src/components/inbox/ActivityInboxNotificationPresenter.svelte +++ b/plugins/notification-resources/src/components/inbox/ActivityInboxNotificationPresenter.svelte @@ -124,7 +124,7 @@ notification: value, embedded, withActions, - showNotify, + showNotify: showNotify ? !value.isViewed && !embedded : false, actions, onClick }}