From aad2e017ea737c594167c6f39f8563013eb36094 Mon Sep 17 00:00:00 2001 From: dawn Date: Sun, 6 Sep 2026 23:48:57 +0900 Subject: [PATCH] web/notifications: fix the stale unread badge by sharing read state Signed-off-by: dawn --- .../notifications/NotificationBell.svelte | 99 +++-------- .../timeline/NotificationsPreview.svelte | 18 +- web/src/lib/notifications.svelte.ts | 154 +++++++++++++++--- web/src/lib/notifications.test.ts | 53 ++++++ web/src/routes/notifications/+page.svelte | 92 +++-------- 5 files changed, 231 insertions(+), 185 deletions(-) create mode 100644 web/src/lib/notifications.test.ts diff --git a/web/src/lib/components/notifications/NotificationBell.svelte b/web/src/lib/components/notifications/NotificationBell.svelte index da70b37c5..eeec28a10 100644 --- a/web/src/lib/components/notifications/NotificationBell.svelte +++ b/web/src/lib/components/notifications/NotificationBell.svelte @@ -1,21 +1,16 @@ {#snippet count()} - {#if unreadCount > 0} + {#if shared.unread > 0}