From cdb64db0f31535df8add2e222aef05c879183d36 Mon Sep 17 00:00:00 2001 From: shravan0627 Date: Mon, 8 Jun 2026 10:25:10 -0400 Subject: [PATCH 1/6] fix: resolve merge conflicts and add dark mode support for LB messaging page --- .../LBDashboard/Messaging/LBMessaging.jsx | 229 +++++++++++++----- 1 file changed, 165 insertions(+), 64 deletions(-) diff --git a/src/components/LBDashboard/Messaging/LBMessaging.jsx b/src/components/LBDashboard/Messaging/LBMessaging.jsx index 7dcf80469d..912bd1b4b4 100644 --- a/src/components/LBDashboard/Messaging/LBMessaging.jsx +++ b/src/components/LBDashboard/Messaging/LBMessaging.jsx @@ -20,6 +20,7 @@ import { markMessagesAsReadViaSocket, } from '../../../utils/messagingSocket'; import logo from '../../../assets/images/logo2.png'; +import Header from '../../Header/Header'; export default function LBMessaging() { const dispatch = useDispatch(); @@ -152,7 +153,7 @@ export default function LBMessaging() { useEffect(() => { const handleClickOutside = event => { if (menuRef.current && !menuRef.current.contains(event.target)) { - setMobileHamMenu(false); // Close the menu if clicked outside + setMobileHamMenu(false); } }; @@ -259,7 +260,6 @@ export default function LBMessaging() { toast.success('Preferences updated successfully!'); setBellDropdownActive(false); - // Refresh preferences after saving dispatch(fetchUserPreferences(currentUserId, selectedUser.userId)).then(response => { if (response?.payload) { setSelectedOption({ @@ -316,7 +316,9 @@ export default function LBMessaging() { const renderContacts = () => { if (sidebarContacts.length === 0) { return ( -

No contacts yet. Use the search icon to find someone.

+

+ No contacts yet. Use the search icon to find someone. +

); } @@ -324,7 +326,9 @@ export default function LBMessaging() { {mobileHamMenu && ( -
-
+
+
{showContacts ? ( -
+
{ const query = e.target.value; @@ -435,36 +466,58 @@ export default function LBMessaging() {
) : ( -
-

Messages

-
+
+

+ Messages +

+
setShowContacts(prev => !prev)} />
)}
{showContacts ? safeSearchResults.map(user => (
) : ( -
-

Messages

-
+
+

+ Messages +

+
setShowContacts(prev => !prev)} />
)}
{showContacts ? safeSearchResults.map(user => (
)}
-
+
{selectedUser.userId ? ( renderChatMessages() ) : ( -

Select a user to start chatting

+

+ Select a user to start chatting +

)}
-
+