From 5bd6f0453d0d215193b84d14b8402aa2961f759e Mon Sep 17 00:00:00 2001 From: Dave Richer Date: Thu, 27 Feb 2025 20:28:41 -0500 Subject: [PATCH] feature/IO-3096-GlobalNotifications -Read Status Sync accross all clients. --- .../notification-center.component.jsx | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/client/src/components/notification-center/notification-center.component.jsx b/client/src/components/notification-center/notification-center.component.jsx index 07a478893..e388db84e 100644 --- a/client/src/components/notification-center/notification-center.component.jsx +++ b/client/src/components/notification-center/notification-center.component.jsx @@ -1,10 +1,8 @@ -// notification-center.component.jsx -import React from "react"; import { Virtuoso } from "react-virtuoso"; -import { Button, Checkbox, List, Badge, Typography, Alert } from "antd"; +import { Alert, Badge, Button, Checkbox, List, Typography } from "antd"; import { useTranslation } from "react-i18next"; -import "./notification-center.styles.scss"; import { Link } from "react-router-dom"; +import "./notification-center.styles.scss"; const { Text, Title } = Typography; @@ -42,10 +40,11 @@ const NotificationCenterComponent = ({ > { - e.stopPropagation(); // Prevent List.Item click handler from firing - !notification.read && onNotificationClick(notification.id); // Mark as read when link clicked + e.stopPropagation(); + if (!notification.read) { + onNotificationClick(notification.id); + } }} > RO #{notification.roNumber}