- Add early-return guard for m.room.encrypted in MessageNotifications
so eventId is never added to notifiedEventsRef before decryption.
Without this, the post-decryption re-emission was deduped and the
banner showed "Encrypted Message" instead of actual content.
- Build ReactNode bodyNode via getReactCustomHtmlParser + parse +
sanitizeCustomHtml for org.matrix.custom.html messages, mirroring
the timeline renderer pipeline (mxc images, mentions, etc.).
- Add bodyNode?: ReactNode to InAppBannerNotification type.
- Add BodyNode component in NotificationBanner; falls back to
existing plain-text BodyText path when bodyNode is absent.
- Rewrite notificationclick to deep-link via /to/:user_id/:room_id/:event_id so
the correct account is activated on cold PWA launch (ToRoomEvent -> pendingNotificationAtom)
- Suppress OS/SW push notification when the app window is already visible;
track visibility via postMessage from the app on visibilitychange
- Remove preferPushOnMobile dead code
- Add useSystemNotifications setting (desktop-only, default true on desktop);
split it out from useInAppNotifications so pill and OS notifications are
independently controlled
- Settings UI: desktop shows In-App + System Notifications; mobile shows
In-App + Push Notifications; each hides the irrelevant third toggle
- Fix InviteNotifications / MessageNotifications to gate OS notifications on
useSystemNotifications + !mobileOrTablet(); pill remains gated on useInAppNotifications
- Fix NotificationJumper: bypass useRoomNavigate (which routes through space
path) -- navigate directly via getHomeRoomPath / getDirectRoomPath so tapping
a pill banner on mobile opens the room timeline, not the space-nav panel
- When the app is already open, use postMessage({ type: notificationClick })
from SW to the running window; new ServiceWorkerClickHandler component handles
it with the same setActiveSessionId + setPending path as the pill flow;
/to/ URL kept as cold-launch fallback only
- getUnreadInfo: guard stale-count clamp with roomHaveUnread; exclude own messages
from clamp trigger; walk live timeline to compute real fallback counts using
PushProcessor instead of hard-coding dot badge
- roomToUnreadAtom: remove mDirectAtom dependency for DM parent filtering;
add ClientEvent.Room handler to seed badge state when rooms join
- sessionsHighlightAtom added to track highlight counts per inactive session
- AccountSwitcherTab: show UnreadBadge on inactive session rows and sidebar icon
- HandleNotificationClick moved outside ClientRoot loading gate so SW postMessages
are never dropped during account-switch reloads
- iOS Safari event.source=null guard removed; type-check used instead
- ToRoomEvent simplified: writes pendingNotificationAtom + sets active session,
delegates navigation to NotificationJumper
- NotificationJumper: jumpingRef prevents repeated navigation; stable performJumpRef
avoids re-registering listeners on every atom change during account switch
- BackgroundNotifications: uses SW showNotification for reliable tap routing on iOS;
dedupeId is now userId+eventId scoped; visibility guard prevents backgrounded
in-app popups; ref pattern avoids stale closure on settings
- SW: persist/restore notification settings across iOS SW restarts via Cache API;
group notifications by room (tag + renotify); prefer navigate() over postMessage
when available; prefer visible tab on notificationclick
- pushNotification: resolveSilent respects tweaks.sound; recipientId in title;
fallbackNotification removed (redundant)
- RoomTimeline: use ref for handleOpenEvent to stop re-pulling on every new message
The UnreadBadge supports a separate highlight count and total count, but all
call sites were only passing the total. Update DirectTab, HomeTab, SpaceTabs,
and Search to pass the highlight count when the badge is in highlight state,
so @-mention counts are reflected accurately in the sidebar.