isometrik-chat 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +74 -0
- package/babel.config.js +6 -0
- package/dist/index.js +684 -0
- package/package.json +59 -0
- package/public/Logo-192x192.png +0 -0
- package/public/Logo-512x512.png +0 -0
- package/public/favicon.ico +0 -0
- package/public/fonts/BenjaminVictoria.ttf +0 -0
- package/public/icons/arrow_logo.svg +9 -0
- package/public/icons/assets/ic_placeholder_banner.svg +1 -0
- package/public/icons/attach-file.svg +9 -0
- package/public/icons/audio_pause.svg +1 -0
- package/public/icons/audio_play.svg +6 -0
- package/public/icons/back.svg +3 -0
- package/public/icons/bell.svg +1 -0
- package/public/icons/block.svg +1 -0
- package/public/icons/bottom-arrow.svg +1 -0
- package/public/icons/camera-switch.svg +12 -0
- package/public/icons/camera.svg +4 -0
- package/public/icons/cancel.svg +1 -0
- package/public/icons/chat empty placeholder.svg +58 -0
- package/public/icons/chat_audio_pause.png +0 -0
- package/public/icons/chat_audio_play.png +0 -0
- package/public/icons/close.svg +5 -0
- package/public/icons/crossCarousel.svg +3 -0
- package/public/icons/delete.svg +3 -0
- package/public/icons/disappear.svg +24 -0
- package/public/icons/document.png +0 -0
- package/public/icons/document.svg +1 -0
- package/public/icons/downloadCarousel.svg +6 -0
- package/public/icons/edit-pencil.svg +6 -0
- package/public/icons/emoji.svg +8 -0
- package/public/icons/emojiCarousel.svg +3 -0
- package/public/icons/filter.svg +1 -0
- package/public/icons/forwardCarousel.svg +3 -0
- package/public/icons/gallery.svg +1 -0
- package/public/icons/goToMessageCarousel.svg +3 -0
- package/public/icons/ic_uil_arrow-left.svg +1 -0
- package/public/icons/ic_uil_eye-slash.svg +1 -0
- package/public/icons/ic_uil_eye.svg +1 -0
- package/public/icons/leftArrowCarousel.svg +6 -0
- package/public/icons/light-mode.svg +14 -0
- package/public/icons/lock.svg +1 -0
- package/public/icons/login_background.png +0 -0
- package/public/icons/menu .svg +5 -0
- package/public/icons/menuCarousel.svg +5 -0
- package/public/icons/message.svg +3 -0
- package/public/icons/placeholder.svg +958 -0
- package/public/icons/poll.svg +1 -0
- package/public/icons/retake.png +0 -0
- package/public/icons/right-arrow.svg +3 -0
- package/public/icons/right.svg +3 -0
- package/public/icons/round-star.svg +1 -0
- package/public/icons/search.svg +3 -0
- package/public/icons/send.svg +10 -0
- package/public/icons/starCarousel.svg +3 -0
- package/public/icons/status.svg +1 -0
- package/public/icons/sticker.svg +1 -0
- package/public/icons/thumb-down.svg +1 -0
- package/public/icons/user.svg +1 -0
- package/public/icons/users.svg +1 -0
- package/public/icons/voice.png +0 -0
- package/public/index.html +38 -0
- package/public/logo192.png +0 -0
- package/public/logo512.png +0 -0
- package/public/manifest.json +25 -0
- package/public/offline.html +12 -0
- package/public/robots.txt +3 -0
- package/public/service-worker.js +81 -0
- package/src/App.js +15 -0
- package/src/App.test.js +8 -0
- package/src/Authpage.js +16 -0
- package/src/ChatContext.js +172 -0
- package/src/Data/index.js +110 -0
- package/src/assets/icons.js +49 -0
- package/src/assets/images/WhatsApp.html +258 -0
- package/src/assets/images/WhatsApp_files/301446776_522918349234681_1974693392291574064_n.jpg +0 -0
- package/src/assets/images/WhatsApp_files/app-bf223f825866ee433b07.css +242 -0
- package/src/assets/images/WhatsApp_files/app.77ee8aa7a4c593101105.js +77 -0
- package/src/assets/images/WhatsApp_files/lazy_loaded_high_priority_components.85a06e74a0a4ade1640b.css +16 -0
- package/src/assets/images/WhatsApp_files/lazy_loaded_low_priority_components.8621270bc215a9298a97.css +47 -0
- package/src/assets/images/WhatsApp_files/libsignal-protocol-ee5b8ba.min.js +21 -0
- package/src/assets/images/WhatsApp_files/main.48b845d68e066fb27a75.css +161 -0
- package/src/assets/images/WhatsApp_files/runtime.e6018f3c1e255e8f4dc7.js +2 -0
- package/src/assets/images/WhatsApp_files/stylex-d50abd61e6cf7eab2afd855adccf14e5.css +2841 -0
- package/src/assets/images/WhatsApp_files/vendor1_app.58a51d93a250f83ab555.js +79 -0
- package/src/assets/images/bg.jpeg +0 -0
- package/src/assets/images/drkbg.jpg +0 -0
- package/src/assets/images/notFound.jpeg +0 -0
- package/src/assets/images/watsapp.jpg +0 -0
- package/src/assets/images/watsappbg.png +0 -0
- package/src/assets/images/wb.jpg +0 -0
- package/src/assets/images/whatsapp.jpeg +0 -0
- package/src/components/ChatBox/AudioBubble.js +162 -0
- package/src/components/ChatBox/ChatBubble.js +232 -0
- package/src/components/ChatBox/DocumentBubble.js +87 -0
- package/src/components/ChatBox/MessagesBox.js +533 -0
- package/src/components/CustomModal.js +60 -0
- package/src/components/Icon.js +10 -0
- package/src/components/ImageComponent.js +24 -0
- package/src/components/MediaDocs.js +155 -0
- package/src/components/MediaDocumentContainer.js +55 -0
- package/src/components/MessageInfoDropdown.js +124 -0
- package/src/components/Modal/AllowMicPermissionModal.js +63 -0
- package/src/components/Modal/BlockUnblockChatModal.js +78 -0
- package/src/components/Modal/CameraPermissionBlockedModal.js +61 -0
- package/src/components/Modal/CameraPermissionRequestModal.js +60 -0
- package/src/components/Modal/ClearChatModal.js +78 -0
- package/src/components/Modal/DeleteChatModal.js +79 -0
- package/src/components/Modal/MicPermissionDisableModal.js +63 -0
- package/src/components/Modal/Modal.js +103 -0
- package/src/components/Modal/ModalDialog.js +103 -0
- package/src/components/Modal/ProfilePictureUploadPreview.js +160 -0
- package/src/components/OutsideAlerter/OutsideAlerter.js +38 -0
- package/src/components/ProfilePicture/ProfilePicture.js +127 -0
- package/src/components/Registration/Login.js +265 -0
- package/src/components/Registration/SignUp.js +322 -0
- package/src/components/SnackBar.js +42 -0
- package/src/components/common/Modal/useDetectOutsideClick.js +23 -0
- package/src/components/common/styled/PageWrapper.js +25 -0
- package/src/components/formcontrol/CustomButton.js +38 -0
- package/src/components/formcontrol/InputText.js +60 -0
- package/src/global-styles.js +42 -0
- package/src/hooks/useDeviceType.js +28 -0
- package/src/hooks/useThrottle.js +29 -0
- package/src/index.css +225 -0
- package/src/index.js +23 -0
- package/src/lib/constant.js +21 -0
- package/src/lib/functionality.js +13 -0
- package/src/lib/helpers.js +320 -0
- package/src/lib/mockData/index.js +76 -0
- package/src/lib/session/index.js +31 -0
- package/src/lib/validation.js +4 -0
- package/src/logo.svg +1 -0
- package/src/pages/WhatsappMainBox/index.js +574 -0
- package/src/reportWebVitals.js +13 -0
- package/src/services/deliveryStatus.js +27 -0
- package/src/setupTests.js +5 -0
- package/src/utils/chatSdk.js +14 -0
- package/src/utils/global.js +57 -0
- package/src/utils/media.js +79 -0
- package/src/view/component/BlockedContactSlide.js +134 -0
- package/src/view/component/Carousle/UpperMenuBar.js +106 -0
- package/src/view/component/Carousle/index.js +204 -0
- package/src/view/component/Chatbox.js/AudioRecorder.js +311 -0
- package/src/view/component/Chatbox.js/ChatBubbleReply.js +27 -0
- package/src/view/component/Chatbox.js/TakePhoto.js +363 -0
- package/src/view/component/Chatbox.js/index.js +856 -0
- package/src/view/component/Chatbox.js/styles.css +231 -0
- package/src/view/component/Contact/index.js +56 -0
- package/src/view/component/Contact/styles.css +208 -0
- package/src/view/component/ContactInfo/index.js +543 -0
- package/src/view/component/ContactInfo/styles.css +289 -0
- package/src/view/component/Context/index.js +3 -0
- package/src/view/component/DialogBox.js +15 -0
- package/src/view/component/ImageCropper/ImageCropper.js +128 -0
- package/src/view/component/Loader/Loader.js +52 -0
- package/src/view/component/Loader/UserPagingLoader.js +62 -0
- package/src/view/component/MainChatBox/index.js +819 -0
- package/src/view/component/MainChatBox/styles.css +124 -0
- package/src/view/component/Menu/index.js +261 -0
- package/src/view/component/Menu/styles.css +68 -0
- package/src/view/component/Profile/ProfileInfoContainer.js +112 -0
- package/src/view/component/Profile/ProfileUpdate.js +178 -0
- package/src/view/component/Profile/TakeProfilePhoto.js +391 -0
- package/src/view/component/Profile/index.js +550 -0
- package/src/view/component/Profile/styles.css +370 -0
- package/src/view/component/ReplyChatMessage/ReplyChatMessage.js +48 -0
- package/src/view/component/SeachBar/index.js +106 -0
- package/src/view/component/SeachBar/styles.css +53 -0
- package/src/view/component/Siderbar/index.js +512 -0
- package/src/view/component/Siderbar/styles.css +138 -0
- package/src/view/component/Toaster/Toaster.js +117 -0
- package/src/view/component/UserDetailsCard/UserDetailCard.js +337 -0
- package/src/view/component/deleteMessageMoal.js +80 -0
- package/src/view/component/emoji/index.js +22 -0
- package/src/view/component/emoji/sstyles.css +0 -0
- package/src/view/component/forwardData/index.js +327 -0
- package/src/view/component/forwardData/styles.css +112 -0
- package/src/view/component/forwardPopup/index.js +55 -0
- package/src/view/component/forwardPopup/styles.css +144 -0
- package/src/view/component/mediaList/index.js +92 -0
- package/src/view/component/menuDialog/index.js +71 -0
- package/src/view/component/menuDialog/styles.css +24 -0
- package/src/view/component/pagination/pagination.js +52 -0
- package/src/view/component/pagination/paginationForMsg.js +43 -0
- package/src/view/component/sidebarChat/index.js +321 -0
- package/src/view/component/sidebarChat/styles.css +109 -0
|
@@ -0,0 +1,550 @@
|
|
|
1
|
+
import React, { useState, useEffect, useRef } from "react";
|
|
2
|
+
import "./styles.css";
|
|
3
|
+
import SeachBar from "../SeachBar";
|
|
4
|
+
import wb from "../../../assets/images/wb.jpg";
|
|
5
|
+
import EmojiPicker from "emoji-picker-react";
|
|
6
|
+
import client from "../../../utils/chatSdk";
|
|
7
|
+
import ImageComponent from "../../../components/ImageComponent";
|
|
8
|
+
import {
|
|
9
|
+
BACKICON,
|
|
10
|
+
CORRECT_ICON,
|
|
11
|
+
EDITPENCILICON,
|
|
12
|
+
EMOJI_ICON,
|
|
13
|
+
} from "../../../utils/global";
|
|
14
|
+
import PaginationIndicator from "../pagination/pagination";
|
|
15
|
+
import { checkLetterUppercase, debounce, getUserConversationDetails } from "../../../lib/helpers";
|
|
16
|
+
import { setCookie } from "../../../lib/session";
|
|
17
|
+
import ProfileInfoContainer from "./ProfileInfoContainer";
|
|
18
|
+
import UserPagingLoader from "../Loader/UserPagingLoader";
|
|
19
|
+
import { USER_BIO_MAX_LENGTH, USER_NAME_MAX_LENGTH,} from "../../../lib/constant";
|
|
20
|
+
import BlockedContactSlide from "../BlockedContactSlide";
|
|
21
|
+
import Toaster from "../Toaster/Toaster";
|
|
22
|
+
|
|
23
|
+
function Profile(props) {
|
|
24
|
+
const { handleClose, allUsers, userDetails, paginationToken, messageSlidebar, getPaginationData,slideShow, group,status, theme, sidebarData, setState, state,currentUserConversationDetails,setCurrentUserConversationDetails, setIsSidebarShow, setUserDetails, setShowLoader, setShowProfilePicture, showUserPaginationLoader,isBlockedList,setIsBlockedList,setUserBlockModal,setUnBlockUsers,setBlockedUser,sidebarChatItem,setUserConversationDetail } = props;
|
|
25
|
+
const [nameDisable, setNameDisable] = useState(true);
|
|
26
|
+
const [statusDisable, setStatusDisable] = useState(true);
|
|
27
|
+
const initialValue = { name: "", status: "" };
|
|
28
|
+
const [data, setdata] = useState(initialValue);
|
|
29
|
+
const [updateUserDetails, setUpdateUserDetails] = useState();
|
|
30
|
+
const [enteredSearchData, setEnteredSearchData ] = useState('');
|
|
31
|
+
const [storeNewConversation, setStoreNewConversation] = useState(false);
|
|
32
|
+
const [showImageUploaderOption, setShowImageUploaderOption] = useState(false);
|
|
33
|
+
const [showUsernameInvalid, setShowUsernameInvalid] = useState(false);
|
|
34
|
+
const [toastStatus, setToastStatus] = useState({open: false, message: '', variant: ''});
|
|
35
|
+
const pageScrollRef = useRef(null);
|
|
36
|
+
// This array indicates alphabets using indexes like 0 → a, 1 → b…25 → z
|
|
37
|
+
// true → alphabet is encountered
|
|
38
|
+
// false → alphabet is not encountered
|
|
39
|
+
let alphabets = new Array(26).fill(false);
|
|
40
|
+
useEffect(() => {
|
|
41
|
+
setUpdateUserDetails(userDetails);
|
|
42
|
+
}, [userDetails]);
|
|
43
|
+
|
|
44
|
+
const updateUserProfile = async() => {
|
|
45
|
+
const body = {
|
|
46
|
+
userName: updateUserDetails?.userName,
|
|
47
|
+
metaData: {country: 'IN'},
|
|
48
|
+
userProfileImageUrl: updateUserDetails.userProfileImageUrl,
|
|
49
|
+
};
|
|
50
|
+
try {
|
|
51
|
+
const res = await client.user.patchUser(body);
|
|
52
|
+
setToastStatus({open: true, variant:"success", message: res.msg });
|
|
53
|
+
} catch (error) {
|
|
54
|
+
console.error('error', error);
|
|
55
|
+
setToastStatus({open: true, variant:"error", message: error.message });
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
const nameHandler = () => {
|
|
61
|
+
setNameDisable(false);
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
const statusHandler = () => {
|
|
65
|
+
setStatusDisable(false);
|
|
66
|
+
};
|
|
67
|
+
|
|
68
|
+
const changeHandler = (e) => {
|
|
69
|
+
const { name, value } = e.target;
|
|
70
|
+
setdata({ ...data, [name]: value });
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
const saveStatusBtn = () => {
|
|
74
|
+
setStatusDisable(true);
|
|
75
|
+
updateUserProfile();
|
|
76
|
+
};
|
|
77
|
+
|
|
78
|
+
const saveNameBtn = (e) => {
|
|
79
|
+
e.preventDefault();
|
|
80
|
+
const isValid = checkLetterUppercase(updateUserDetails?.userName);
|
|
81
|
+
if (isValid) {
|
|
82
|
+
setNameDisable(true);
|
|
83
|
+
updateUserProfile();
|
|
84
|
+
}else{
|
|
85
|
+
setShowUsernameInvalid(true);
|
|
86
|
+
}
|
|
87
|
+
};
|
|
88
|
+
|
|
89
|
+
const handleProfileUpdateKeyDown = (event) => {
|
|
90
|
+
if (event.key === 'Enter') {
|
|
91
|
+
saveNameBtn(event);
|
|
92
|
+
setStatusDisable(true);
|
|
93
|
+
}
|
|
94
|
+
};
|
|
95
|
+
|
|
96
|
+
const changeInputHandler = (e) => {
|
|
97
|
+
// 25 is the max length for userName
|
|
98
|
+
if (e.target.value.length <= USER_NAME_MAX_LENGTH ){
|
|
99
|
+
setShowUsernameInvalid(false);
|
|
100
|
+
setUpdateUserDetails({ ...updateUserDetails, [e.target.name]: e.target.value });
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
|
|
106
|
+
const getIndex =(char) => {
|
|
107
|
+
return char.charCodeAt(0) - 65;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
const userSearchEnteredData = (value) => {
|
|
111
|
+
debounceMyFunction(value);
|
|
112
|
+
setEnteredSearchData(value);
|
|
113
|
+
};
|
|
114
|
+
|
|
115
|
+
const getSearchUserData = async (value) => {
|
|
116
|
+
try {
|
|
117
|
+
const res = await client?.user?.getUserNonblock(value.length ? { sort: 1, searchTag: value } : {sort: 1});
|
|
118
|
+
setState((prev) => {
|
|
119
|
+
return {
|
|
120
|
+
...prev,
|
|
121
|
+
users: res?.users,
|
|
122
|
+
};
|
|
123
|
+
});
|
|
124
|
+
} catch (error) {
|
|
125
|
+
console.log(error, "error");
|
|
126
|
+
setState((prev) => {
|
|
127
|
+
return {
|
|
128
|
+
...prev,
|
|
129
|
+
users: [],
|
|
130
|
+
};
|
|
131
|
+
});
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
const debounceMyFunction = debounce(getSearchUserData, 900);
|
|
136
|
+
const startUsersChatConversations = async (selectedUser) => {
|
|
137
|
+
setIsSidebarShow(true);
|
|
138
|
+
const payload = {
|
|
139
|
+
conversationId: "",
|
|
140
|
+
};
|
|
141
|
+
const body = {
|
|
142
|
+
typingEvents: true,
|
|
143
|
+
readEvents: true,
|
|
144
|
+
pushNotifications: true,
|
|
145
|
+
metaData: {},
|
|
146
|
+
members: [selectedUser?.userId],
|
|
147
|
+
isGroup: false,
|
|
148
|
+
customType: "SingleChat",
|
|
149
|
+
conversationType: 0,
|
|
150
|
+
conversationTitle: selectedUser?.userName,
|
|
151
|
+
conversationImageUrl: selectedUser?.userProfileImageUrl,
|
|
152
|
+
searchableTags: [userDetails.userName , selectedUser?.userName]
|
|
153
|
+
};
|
|
154
|
+
try {
|
|
155
|
+
const response = await client?.Conversation?.postConversation(body);
|
|
156
|
+
if (response.conversationId) {
|
|
157
|
+
// console.log(response, 'response---------');
|
|
158
|
+
const getData = await getUserConversationDetails(response.conversationId);
|
|
159
|
+
setCurrentUserConversationDetails({ id: getData.opponentDetails.userId , conversationId: response.conversationId});
|
|
160
|
+
sidebarData(getData);
|
|
161
|
+
props?.messageSlideClose();
|
|
162
|
+
}
|
|
163
|
+
payload.conversationId = response.conversationId;
|
|
164
|
+
setStoreNewConversation(response?.newConversation);
|
|
165
|
+
setCookie("newConversation", response?.newConversation);
|
|
166
|
+
getConversationMessages(payload);
|
|
167
|
+
} catch (err) {
|
|
168
|
+
console.log(err, "err");
|
|
169
|
+
}
|
|
170
|
+
};
|
|
171
|
+
const getConversationMessages = async (payload) => {
|
|
172
|
+
try {
|
|
173
|
+
const res = await client?.message?.getMessages(payload);
|
|
174
|
+
const filteredResponseData = res.messages.filter(data => data?.body?.length > 0);
|
|
175
|
+
setState((prev) => {
|
|
176
|
+
return {
|
|
177
|
+
...prev,
|
|
178
|
+
messages: {
|
|
179
|
+
...prev.messages,
|
|
180
|
+
[payload.conversationId]: filteredResponseData,
|
|
181
|
+
},
|
|
182
|
+
};
|
|
183
|
+
});
|
|
184
|
+
} catch (err) {
|
|
185
|
+
console.log(err, "err");
|
|
186
|
+
}
|
|
187
|
+
};
|
|
188
|
+
|
|
189
|
+
const BlockedListClose =()=>{
|
|
190
|
+
props?.setIsBlockedList(false);
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
const isAlphabetPrinted = (data) => {
|
|
194
|
+
if (!alphabets[getIndex(data.userName[0].toUpperCase())] && data.userName[0] === data.userName[0].toUpperCase()) {
|
|
195
|
+
alphabets[getIndex(data.userName[0].toUpperCase())] = true;
|
|
196
|
+
return true;
|
|
197
|
+
}
|
|
198
|
+
return false;
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
return (
|
|
202
|
+
<>
|
|
203
|
+
<div
|
|
204
|
+
className={
|
|
205
|
+
props?.newGroup ||
|
|
206
|
+
props?.newCommunity ||
|
|
207
|
+
props?.startedMessage ||
|
|
208
|
+
props?.settings
|
|
209
|
+
? "profile_Container newGroup "
|
|
210
|
+
: "profile_Container"
|
|
211
|
+
}
|
|
212
|
+
>
|
|
213
|
+
{
|
|
214
|
+
( props?.messageSliderOpen || slideShow || group ||status || props?.isBlockedList ) && (
|
|
215
|
+
<div className="profile_Div">
|
|
216
|
+
<div
|
|
217
|
+
className={
|
|
218
|
+
props?.slideShow ||
|
|
219
|
+
props?.group ||
|
|
220
|
+
props?.messageSliderOpen ||
|
|
221
|
+
props?.newGroup ||
|
|
222
|
+
props?.newCommunity ||
|
|
223
|
+
props?.startedMessage ||
|
|
224
|
+
props?.settings ||
|
|
225
|
+
props?.status || props?.isBlockedList
|
|
226
|
+
? "profile_header header"
|
|
227
|
+
: "profile_header"
|
|
228
|
+
|
|
229
|
+
}
|
|
230
|
+
style={{ overflowY: "hidden", overflowX: "hidden" }}
|
|
231
|
+
>
|
|
232
|
+
<ImageComponent
|
|
233
|
+
src={BACKICON}
|
|
234
|
+
className="darkicons"
|
|
235
|
+
onClick={
|
|
236
|
+
props?.slideShow
|
|
237
|
+
? props?.handleClosee
|
|
238
|
+
: "" || props?.group
|
|
239
|
+
? props?.groupClose
|
|
240
|
+
: "" || props?.newGroup
|
|
241
|
+
? props?.newGroupHandle
|
|
242
|
+
: "" || props?.messageSliderOpen
|
|
243
|
+
? props?.messageSlideClose
|
|
244
|
+
: "" || props?.newCommunity
|
|
245
|
+
? props?.newCommunityHandle
|
|
246
|
+
: "" || props?.startedMessage
|
|
247
|
+
? props?.startedMessageHandle
|
|
248
|
+
: "" || props?.settings
|
|
249
|
+
? props?.settingsHandle
|
|
250
|
+
: "" || props?.status
|
|
251
|
+
? props?.statusClose
|
|
252
|
+
: "" || props?.isBlockedList ? BlockedListClose :""
|
|
253
|
+
}
|
|
254
|
+
// className="profile_arrowIcon"
|
|
255
|
+
/>
|
|
256
|
+
<p className="profile_header_text">{`${props?.slideShow ? "Profile" : ""} ${props.messageSliderOpen ? "New Chat" : ""
|
|
257
|
+
} ${props?.group ? "Community" : ""} ${props?.newGroup ? "Add group participants" : ""
|
|
258
|
+
} ${props?.newCommunity ? "New Community" : ""} ${props?.startedMessage ? "Start new chat" : ""
|
|
259
|
+
} ${props?.settings ? "Settings" : ""}
|
|
260
|
+
${props?.status ? "Status" : ""} ${props?.isBlockedList ? "Blocked Contacts" :""}
|
|
261
|
+
`}</p>
|
|
262
|
+
</div>
|
|
263
|
+
{
|
|
264
|
+
( props?.messageSliderOpen) &&
|
|
265
|
+
<div className="messageChat">
|
|
266
|
+
<SeachBar messageSliderOpen={props?.messageSliderOpen} userSearchEnteredData={userSearchEnteredData} theme={theme} />
|
|
267
|
+
</div>
|
|
268
|
+
}
|
|
269
|
+
</div>
|
|
270
|
+
)
|
|
271
|
+
}
|
|
272
|
+
{props?.slideShow ? (
|
|
273
|
+
<>
|
|
274
|
+
<ProfileInfoContainer updateUserDetails={updateUserDetails} updateUserProfile={updateUserProfile} setShowImageUploaderOption={setShowImageUploaderOption} slideShow={slideShow} changeInputHandler={changeInputHandler} nameDisable={nameDisable} saveNameBtn={saveNameBtn} theme={theme} statusDisable={statusDisable} statusHandler={statusHandler} nameHandler={nameHandler} setUpdateUserDetails={setUpdateUserDetails} setUserDetails={setUserDetails} setShowProfilePicture={setShowProfilePicture} showUsernameInvalid={showUsernameInvalid} saveStatusBtn={saveStatusBtn}
|
|
275
|
+
handleProfileUpdateKeyDown={handleProfileUpdateKeyDown} setToastStatus={setToastStatus}
|
|
276
|
+
setShowUsernameInvalid={setShowUsernameInvalid} setNameDisable={setNameDisable}
|
|
277
|
+
/>
|
|
278
|
+
</>
|
|
279
|
+
) : (
|
|
280
|
+
""
|
|
281
|
+
)}
|
|
282
|
+
{group ? (
|
|
283
|
+
<>
|
|
284
|
+
<div className={group ? "groupChat border_color" : ""}>
|
|
285
|
+
<div className="sliderContainer d-flex align-items-center">
|
|
286
|
+
<span
|
|
287
|
+
data-testid="community-group"
|
|
288
|
+
data-icon="community-group"
|
|
289
|
+
class=""
|
|
290
|
+
>
|
|
291
|
+
<svg
|
|
292
|
+
viewBox="0 0 28 19"
|
|
293
|
+
height="19"
|
|
294
|
+
width="28"
|
|
295
|
+
preserveAspectRatio="xMidYMid meet"
|
|
296
|
+
class=""
|
|
297
|
+
fill="none"
|
|
298
|
+
>
|
|
299
|
+
<path
|
|
300
|
+
class="primary"
|
|
301
|
+
fill-rule="evenodd"
|
|
302
|
+
clip-rule="evenodd"
|
|
303
|
+
d="M20.0836 6.83416C20.0967 6.92827 20.1139 7.01977 20.1351 7.10996C20.1457 7.1557 20.1573 7.20014 20.1699 7.24328C20.1948 7.33103 20.2238 7.41741 20.257 7.50208C20.3057 7.62659 20.3631 7.74717 20.4287 7.86283C20.4722 7.93865 20.5191 8.01315 20.5692 8.08373C20.7191 8.29755 20.8986 8.48655 21.1018 8.64447C21.2385 8.74999 21.3846 8.84147 21.538 8.91765C21.6555 8.97548 21.7769 9.0244 21.9011 9.06404C21.9848 9.09019 22.0705 9.11241 22.1581 9.13071C22.3376 9.16709 22.52 9.18547 22.7028 9.1856C24.1656 9.1856 25.3514 7.93912 25.3514 6.40152C25.3514 4.86391 24.1656 3.61742 22.7028 3.61742C22.52 3.61691 22.3375 3.6353 22.1581 3.67233C22.0713 3.68975 21.9855 3.712 21.9011 3.73899C21.7769 3.77819 21.6556 3.82668 21.538 3.88408C21.1547 4.07401 20.8219 4.36045 20.5692 4.71799C20.5195 4.78988 20.4722 4.86308 20.4287 4.9402C20.3629 5.05573 20.3055 5.17632 20.257 5.30095C20.2243 5.38461 20.1948 5.47087 20.1699 5.55845C20.1573 5.60289 20.1457 5.64733 20.1351 5.69177C20.1139 5.78196 20.0967 5.87346 20.0836 5.96757C20.0442 6.25494 20.0442 6.54678 20.0836 6.83416ZM7.91635 6.83416C7.90392 6.92827 7.88614 7.01977 7.865 7.10996C7.85439 7.1557 7.84278 7.20014 7.83018 7.24328C7.80534 7.33103 7.77629 7.41741 7.74314 7.50208C7.69429 7.62657 7.63685 7.74714 7.57129 7.86283C7.52789 7.93865 7.48101 8.01315 7.4309 8.08373C7.28093 8.29748 7.10143 8.48648 6.89832 8.64447C6.76157 8.74999 6.6155 8.84147 6.46212 8.91765C6.34456 8.97548 6.22322 9.0244 6.09902 9.06404C6.01521 9.09019 5.92954 9.11241 5.842 9.13071C5.66247 9.16708 5.48007 9.18546 5.29723 9.1856C3.83446 9.1856 2.64865 7.93912 2.64865 6.40152C2.64865 4.86391 3.83446 3.61742 5.29723 3.61742C5.4801 3.61692 5.66256 3.63531 5.842 3.67233C5.92873 3.68976 6.01453 3.71202 6.09902 3.73899C6.22319 3.77819 6.34453 3.82668 6.46212 3.88407C6.84541 4.07401 7.17818 4.36045 7.4309 4.71799C7.48064 4.78988 7.52789 4.86308 7.57129 4.9402C7.63709 5.05575 7.69454 5.17634 7.74314 5.30095C7.77584 5.38461 7.80531 5.47087 7.83018 5.55845C7.8427 5.60289 7.8543 5.64733 7.865 5.69177C7.88614 5.78196 7.90342 5.87345 7.91635 5.96756C7.95581 6.25494 7.95581 6.54678 7.91635 6.83416ZM27.8468 13.6264C27.8143 13.5695 27.7783 13.5074 27.7345 13.4386C27.6874 13.3645 27.6342 13.2852 27.5732 13.2006C27.5122 13.1159 27.4447 13.026 27.3688 12.9334C27.2929 12.8409 27.21 12.7456 27.1189 12.6478C26.7459 12.251 26.3196 11.9112 25.8531 11.6388C25.7058 11.5515 25.5492 11.4695 25.3839 11.3915C25.3789 11.3888 25.3745 11.3875 25.3698 11.3848C23.4911 10.5737 21.3746 10.5737 19.4959 11.3848C19.4694 11.3967 19.4445 11.41 19.4188 11.4232C19.3767 11.443 19.3381 11.4655 19.2973 11.4867C19.3202 11.4999 19.3434 11.5118 19.3661 11.525C19.8316 11.7975 20.2733 12.1107 20.6865 12.4613C20.9563 12.6896 21.213 12.9338 21.4555 13.1926C21.6054 13.3513 21.7424 13.5087 21.8677 13.6621C21.9961 13.8195 22.1086 13.9663 22.2091 14.1064C22.3125 14.2506 22.4017 14.3842 22.4814 14.5071C22.5568 14.6262 22.6206 14.732 22.6757 14.8298C22.7802 15.0091 22.8581 15.2035 22.9069 15.4064L22.9274 15.5492H28V13.9319C27.9558 13.8266 27.9046 13.7245 27.8468 13.6264ZM18.1157 4.52771C18.0952 4.37973 18.0682 4.23574 18.0348 4.09441C18.0182 4.02375 17.9999 3.95309 17.9801 3.88376C17.9407 3.74511 17.895 3.61045 17.8436 3.47846C17.767 3.28285 17.6768 3.09346 17.5736 2.91184C17.5053 2.79185 17.4318 2.67585 17.3529 2.56386C16.957 2.00113 16.4338 1.55112 15.8306 1.25463C15.646 1.16345 15.4552 1.0868 15.2598 1.02531C15.1281 0.983983 14.9934 0.947986 14.8559 0.919988C14.5739 0.86243 14.2872 0.833328 13.9999 0.833328C11.6415 0.833328 9.83784 2.72918 9.83784 5.209C9.83784 7.68881 11.6415 9.58333 13.9999 9.58333C14.2872 9.58333 14.5739 9.55423 14.8559 9.49667C14.9934 9.46867 15.1281 9.43267 15.2598 9.39134C15.4552 9.32986 15.646 9.25321 15.8306 9.16203C16.4338 8.86554 16.957 8.41553 17.3529 7.85279C17.4317 7.7408 17.5052 7.62481 17.5736 7.50482C17.6768 7.3232 17.767 7.13381 17.8436 6.9382C17.8944 6.80621 17.9407 6.67022 17.9801 6.5329C17.9999 6.46357 18.0182 6.39291 18.0348 6.32224C18.0682 6.18092 18.0952 6.03693 18.1157 5.88894C18.1776 5.43753 18.1776 4.97913 18.1157 4.52771ZM21.7225 15.3648C21.6762 15.281 21.6229 15.1891 21.5605 15.0877C21.4934 14.9795 21.4164 14.8619 21.3294 14.7376C21.2424 14.6132 21.1454 14.4807 21.0376 14.3455C20.9298 14.2104 20.8111 14.0684 20.6809 13.9265C20.4718 13.6967 20.2507 13.4796 20.0186 13.2763C19.661 12.9642 19.2789 12.6852 18.8765 12.4422C18.6664 12.3152 18.4434 12.1935 18.2074 12.0799C18.2009 12.0758 18.1942 12.0722 18.1872 12.0691C17.0911 11.5419 15.713 11.1742 13.9997 11.1742C12.2865 11.1742 10.9082 11.5419 9.81226 12.0691C9.77405 12.0867 9.73928 12.107 9.70208 12.1259C9.54196 12.2057 9.38809 12.2895 9.2402 12.3746C9.16004 12.4219 9.08166 12.4693 9.00506 12.5166C8.64626 12.7423 8.30392 12.9962 7.98093 13.2763C7.74876 13.4796 7.52762 13.6967 7.31855 13.9265C7.18863 14.0684 7.07003 14.209 6.96189 14.3455C6.85374 14.4821 6.75694 14.6118 6.66994 14.7376C6.58293 14.8633 6.50612 14.9795 6.439 15.0877C6.37658 15.1891 6.32333 15.281 6.2771 15.3648C6.27277 15.3713 6.26882 15.3781 6.26525 15.3851C6.21659 15.4729 6.17698 15.55 6.14564 15.6135C6.08297 15.7406 6.05405 15.8122 6.05405 15.8122V18.3333H21.9459V15.8122C21.8797 15.6586 21.8051 15.5092 21.7225 15.3648ZM5.08137 15.4078C5.09313 15.3077 5.1252 15.2113 5.17549 15.1248C5.2147 15.0481 5.24415 14.9556 5.30522 14.8485C5.37299 14.7308 5.42635 14.6263 5.50041 14.5087C5.57974 14.3844 5.66499 14.2508 5.76708 14.1094C5.86918 13.9679 5.98079 13.8185 6.10628 13.6651C6.23177 13.5117 6.36961 13.3531 6.52044 13.1918C7.09885 12.5757 7.75594 12.0433 8.4737 11.6091C8.54828 11.5641 8.62517 11.5192 8.7027 11.4756C8.66914 11.4584 8.63841 11.4399 8.60357 11.424C8.57785 11.4108 8.55213 11.3975 8.52642 11.3856C7.60024 10.9683 6.59752 10.7608 5.58643 10.7774C4.57538 10.7608 3.57271 10.9683 2.64657 11.3856C2.64168 11.3883 2.63731 11.3896 2.63243 11.3923C2.46681 11.4703 2.31007 11.5522 2.16259 11.6395C1.88006 11.8047 1.6118 11.9945 1.36077 12.2067C1.19789 12.345 1.04254 12.4925 0.895433 12.6483C0.804141 12.7462 0.720736 12.8414 0.645216 12.9339C0.569482 13.0265 0.501335 13.1164 0.440259 13.201C0.379183 13.2856 0.32518 13.365 0.277991 13.439C0.234273 13.5078 0.192871 13.5699 0.16034 13.6268C0.0524608 13.8145 0 13.9322 0 13.9322V15.5492H5.07198L5.08137 15.4078Z"
|
|
304
|
+
fill="white"
|
|
305
|
+
></path>
|
|
306
|
+
</svg>
|
|
307
|
+
</span>
|
|
308
|
+
<p className="m-4 textColor">New Community</p>
|
|
309
|
+
</div>
|
|
310
|
+
</div>
|
|
311
|
+
|
|
312
|
+
<div className="sliderContainer h-100"></div>
|
|
313
|
+
</>
|
|
314
|
+
) : (
|
|
315
|
+
""
|
|
316
|
+
)}
|
|
317
|
+
{props?.messageSliderOpen ? (
|
|
318
|
+
<>
|
|
319
|
+
<PaginationIndicator elementRef={pageScrollRef} pageEventHandler={getPaginationData} />
|
|
320
|
+
<div ref={pageScrollRef} id="chat_body_container" className="chat_container">
|
|
321
|
+
{/* <div className="d-flex align-items-center message border_bottom ">
|
|
322
|
+
<span
|
|
323
|
+
data-testid="default-group"
|
|
324
|
+
data-icon="default-group"
|
|
325
|
+
class="bSJ6w"
|
|
326
|
+
>
|
|
327
|
+
<svg
|
|
328
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
329
|
+
width="28"
|
|
330
|
+
height="19"
|
|
331
|
+
fill="currentColor"
|
|
332
|
+
class="bi bi-people text-white"
|
|
333
|
+
viewBox="0 0 16 16"
|
|
334
|
+
>
|
|
335
|
+
<path d="M15 14s1 0 1-1-1-4-5-4-5 3-5 4 1 1 1 1h8Zm-7.978-1A.261.261 0 0 1 7 12.996c.001-.264.167-1.03.76-1.72C8.312 10.629 9.282 10 11 10c1.717 0 2.687.63 3.24 1.276.593.69.758 1.457.76 1.72l-.008.002a.274.274 0 0 1-.014.002H7.022ZM11 7a2 2 0 1 0 0-4 2 2 0 0 0 0 4Zm3-2a3 3 0 1 1-6 0 3 3 0 0 1 6 0ZM6.936 9.28a5.88 5.88 0 0 0-1.23-.247A7.35 7.35 0 0 0 5 9c-4 0-5 3-5 4 0 .667.333 1 1 1h4.216A2.238 2.238 0 0 1 5 13c0-1.01.377-2.042 1.09-2.904.243-.294.526-.569.846-.816ZM4.92 10A5.493 5.493 0 0 0 4 13H1c0-.26.164-1.03.76-1.724.545-.636 1.492-1.256 3.16-1.275ZM1.5 5.5a3 3 0 1 1 6 0 3 3 0 0 1-6 0Zm3-2a2 2 0 1 0 0 4 2 2 0 0 0 0-4Z" />
|
|
336
|
+
</svg>{" "}
|
|
337
|
+
</span>
|
|
338
|
+
<p className="m-4 textColor">New group</p>
|
|
339
|
+
</div>
|
|
340
|
+
|
|
341
|
+
<div className="border_bottom">
|
|
342
|
+
<div className="d-flex align-items-baseline message ">
|
|
343
|
+
<span
|
|
344
|
+
data-testid="community-group"
|
|
345
|
+
data-icon="community-group"
|
|
346
|
+
class=""
|
|
347
|
+
>
|
|
348
|
+
<svg
|
|
349
|
+
viewBox="0 0 28 19"
|
|
350
|
+
height="19"
|
|
351
|
+
width="28"
|
|
352
|
+
preserveAspectRatio="xMidYMid meet"
|
|
353
|
+
class=""
|
|
354
|
+
fill="none"
|
|
355
|
+
>
|
|
356
|
+
<path
|
|
357
|
+
class="primary"
|
|
358
|
+
fill-rule="evenodd"
|
|
359
|
+
clip-rule="evenodd"
|
|
360
|
+
d="M20.0836 6.83416C20.0967 6.92827 20.1139 7.01977 20.1351 7.10996C20.1457 7.1557 20.1573 7.20014 20.1699 7.24328C20.1948 7.33103 20.2238 7.41741 20.257 7.50208C20.3057 7.62659 20.3631 7.74717 20.4287 7.86283C20.4722 7.93865 20.5191 8.01315 20.5692 8.08373C20.7191 8.29755 20.8986 8.48655 21.1018 8.64447C21.2385 8.74999 21.3846 8.84147 21.538 8.91765C21.6555 8.97548 21.7769 9.0244 21.9011 9.06404C21.9848 9.09019 22.0705 9.11241 22.1581 9.13071C22.3376 9.16709 22.52 9.18547 22.7028 9.1856C24.1656 9.1856 25.3514 7.93912 25.3514 6.40152C25.3514 4.86391 24.1656 3.61742 22.7028 3.61742C22.52 3.61691 22.3375 3.6353 22.1581 3.67233C22.0713 3.68975 21.9855 3.712 21.9011 3.73899C21.7769 3.77819 21.6556 3.82668 21.538 3.88408C21.1547 4.07401 20.8219 4.36045 20.5692 4.71799C20.5195 4.78988 20.4722 4.86308 20.4287 4.9402C20.3629 5.05573 20.3055 5.17632 20.257 5.30095C20.2243 5.38461 20.1948 5.47087 20.1699 5.55845C20.1573 5.60289 20.1457 5.64733 20.1351 5.69177C20.1139 5.78196 20.0967 5.87346 20.0836 5.96757C20.0442 6.25494 20.0442 6.54678 20.0836 6.83416ZM7.91635 6.83416C7.90392 6.92827 7.88614 7.01977 7.865 7.10996C7.85439 7.1557 7.84278 7.20014 7.83018 7.24328C7.80534 7.33103 7.77629 7.41741 7.74314 7.50208C7.69429 7.62657 7.63685 7.74714 7.57129 7.86283C7.52789 7.93865 7.48101 8.01315 7.4309 8.08373C7.28093 8.29748 7.10143 8.48648 6.89832 8.64447C6.76157 8.74999 6.6155 8.84147 6.46212 8.91765C6.34456 8.97548 6.22322 9.0244 6.09902 9.06404C6.01521 9.09019 5.92954 9.11241 5.842 9.13071C5.66247 9.16708 5.48007 9.18546 5.29723 9.1856C3.83446 9.1856 2.64865 7.93912 2.64865 6.40152C2.64865 4.86391 3.83446 3.61742 5.29723 3.61742C5.4801 3.61692 5.66256 3.63531 5.842 3.67233C5.92873 3.68976 6.01453 3.71202 6.09902 3.73899C6.22319 3.77819 6.34453 3.82668 6.46212 3.88407C6.84541 4.07401 7.17818 4.36045 7.4309 4.71799C7.48064 4.78988 7.52789 4.86308 7.57129 4.9402C7.63709 5.05575 7.69454 5.17634 7.74314 5.30095C7.77584 5.38461 7.80531 5.47087 7.83018 5.55845C7.8427 5.60289 7.8543 5.64733 7.865 5.69177C7.88614 5.78196 7.90342 5.87345 7.91635 5.96756C7.95581 6.25494 7.95581 6.54678 7.91635 6.83416ZM27.8468 13.6264C27.8143 13.5695 27.7783 13.5074 27.7345 13.4386C27.6874 13.3645 27.6342 13.2852 27.5732 13.2006C27.5122 13.1159 27.4447 13.026 27.3688 12.9334C27.2929 12.8409 27.21 12.7456 27.1189 12.6478C26.7459 12.251 26.3196 11.9112 25.8531 11.6388C25.7058 11.5515 25.5492 11.4695 25.3839 11.3915C25.3789 11.3888 25.3745 11.3875 25.3698 11.3848C23.4911 10.5737 21.3746 10.5737 19.4959 11.3848C19.4694 11.3967 19.4445 11.41 19.4188 11.4232C19.3767 11.443 19.3381 11.4655 19.2973 11.4867C19.3202 11.4999 19.3434 11.5118 19.3661 11.525C19.8316 11.7975 20.2733 12.1107 20.6865 12.4613C20.9563 12.6896 21.213 12.9338 21.4555 13.1926C21.6054 13.3513 21.7424 13.5087 21.8677 13.6621C21.9961 13.8195 22.1086 13.9663 22.2091 14.1064C22.3125 14.2506 22.4017 14.3842 22.4814 14.5071C22.5568 14.6262 22.6206 14.732 22.6757 14.8298C22.7802 15.0091 22.8581 15.2035 22.9069 15.4064L22.9274 15.5492H28V13.9319C27.9558 13.8266 27.9046 13.7245 27.8468 13.6264ZM18.1157 4.52771C18.0952 4.37973 18.0682 4.23574 18.0348 4.09441C18.0182 4.02375 17.9999 3.95309 17.9801 3.88376C17.9407 3.74511 17.895 3.61045 17.8436 3.47846C17.767 3.28285 17.6768 3.09346 17.5736 2.91184C17.5053 2.79185 17.4318 2.67585 17.3529 2.56386C16.957 2.00113 16.4338 1.55112 15.8306 1.25463C15.646 1.16345 15.4552 1.0868 15.2598 1.02531C15.1281 0.983983 14.9934 0.947986 14.8559 0.919988C14.5739 0.86243 14.2872 0.833328 13.9999 0.833328C11.6415 0.833328 9.83784 2.72918 9.83784 5.209C9.83784 7.68881 11.6415 9.58333 13.9999 9.58333C14.2872 9.58333 14.5739 9.55423 14.8559 9.49667C14.9934 9.46867 15.1281 9.43267 15.2598 9.39134C15.4552 9.32986 15.646 9.25321 15.8306 9.16203C16.4338 8.86554 16.957 8.41553 17.3529 7.85279C17.4317 7.7408 17.5052 7.62481 17.5736 7.50482C17.6768 7.3232 17.767 7.13381 17.8436 6.9382C17.8944 6.80621 17.9407 6.67022 17.9801 6.5329C17.9999 6.46357 18.0182 6.39291 18.0348 6.32224C18.0682 6.18092 18.0952 6.03693 18.1157 5.88894C18.1776 5.43753 18.1776 4.97913 18.1157 4.52771ZM21.7225 15.3648C21.6762 15.281 21.6229 15.1891 21.5605 15.0877C21.4934 14.9795 21.4164 14.8619 21.3294 14.7376C21.2424 14.6132 21.1454 14.4807 21.0376 14.3455C20.9298 14.2104 20.8111 14.0684 20.6809 13.9265C20.4718 13.6967 20.2507 13.4796 20.0186 13.2763C19.661 12.9642 19.2789 12.6852 18.8765 12.4422C18.6664 12.3152 18.4434 12.1935 18.2074 12.0799C18.2009 12.0758 18.1942 12.0722 18.1872 12.0691C17.0911 11.5419 15.713 11.1742 13.9997 11.1742C12.2865 11.1742 10.9082 11.5419 9.81226 12.0691C9.77405 12.0867 9.73928 12.107 9.70208 12.1259C9.54196 12.2057 9.38809 12.2895 9.2402 12.3746C9.16004 12.4219 9.08166 12.4693 9.00506 12.5166C8.64626 12.7423 8.30392 12.9962 7.98093 13.2763C7.74876 13.4796 7.52762 13.6967 7.31855 13.9265C7.18863 14.0684 7.07003 14.209 6.96189 14.3455C6.85374 14.4821 6.75694 14.6118 6.66994 14.7376C6.58293 14.8633 6.50612 14.9795 6.439 15.0877C6.37658 15.1891 6.32333 15.281 6.2771 15.3648C6.27277 15.3713 6.26882 15.3781 6.26525 15.3851C6.21659 15.4729 6.17698 15.55 6.14564 15.6135C6.08297 15.7406 6.05405 15.8122 6.05405 15.8122V18.3333H21.9459V15.8122C21.8797 15.6586 21.8051 15.5092 21.7225 15.3648ZM5.08137 15.4078C5.09313 15.3077 5.1252 15.2113 5.17549 15.1248C5.2147 15.0481 5.24415 14.9556 5.30522 14.8485C5.37299 14.7308 5.42635 14.6263 5.50041 14.5087C5.57974 14.3844 5.66499 14.2508 5.76708 14.1094C5.86918 13.9679 5.98079 13.8185 6.10628 13.6651C6.23177 13.5117 6.36961 13.3531 6.52044 13.1918C7.09885 12.5757 7.75594 12.0433 8.4737 11.6091C8.54828 11.5641 8.62517 11.5192 8.7027 11.4756C8.66914 11.4584 8.63841 11.4399 8.60357 11.424C8.57785 11.4108 8.55213 11.3975 8.52642 11.3856C7.60024 10.9683 6.59752 10.7608 5.58643 10.7774C4.57538 10.7608 3.57271 10.9683 2.64657 11.3856C2.64168 11.3883 2.63731 11.3896 2.63243 11.3923C2.46681 11.4703 2.31007 11.5522 2.16259 11.6395C1.88006 11.8047 1.6118 11.9945 1.36077 12.2067C1.19789 12.345 1.04254 12.4925 0.895433 12.6483C0.804141 12.7462 0.720736 12.8414 0.645216 12.9339C0.569482 13.0265 0.501335 13.1164 0.440259 13.201C0.379183 13.2856 0.32518 13.365 0.277991 13.439C0.234273 13.5078 0.192871 13.5699 0.16034 13.6268C0.0524608 13.8145 0 13.9322 0 13.9322V15.5492H5.07198L5.08137 15.4078Z"
|
|
361
|
+
fill="white"
|
|
362
|
+
></path>
|
|
363
|
+
</svg>
|
|
364
|
+
</span>
|
|
365
|
+
|
|
366
|
+
<p className="m-4 textColor">New Community</p>
|
|
367
|
+
</div>
|
|
368
|
+
</div> */}
|
|
369
|
+
<div>
|
|
370
|
+
<div
|
|
371
|
+
className="text-uppercase border_bottom textColor"
|
|
372
|
+
style={{ padding: "20px 0 20px 32px" }}
|
|
373
|
+
>
|
|
374
|
+
Your Contacts
|
|
375
|
+
</div>
|
|
376
|
+
<div className="custom_padding_left">
|
|
377
|
+
{allUsers?.length > 0 ? allUsers?.map((data) => {
|
|
378
|
+
return (
|
|
379
|
+
<>
|
|
380
|
+
{
|
|
381
|
+
isAlphabetPrinted(data) &&
|
|
382
|
+
<div className="custom_padding_bottom custom_padding_top custom_padding_left textColor">{ data.userName[0].toUpperCase() }</div>
|
|
383
|
+
}
|
|
384
|
+
{
|
|
385
|
+
<div className="d-flex pointer border_bottom" key={data?.userId}
|
|
386
|
+
onClick={() => startUsersChatConversations(data)}
|
|
387
|
+
>
|
|
388
|
+
<div
|
|
389
|
+
className="user_Info"
|
|
390
|
+
style={{ paddingBottom: "10px" }}
|
|
391
|
+
>
|
|
392
|
+
{data.userProfileImageUrl ? (
|
|
393
|
+
<img
|
|
394
|
+
src={data.userProfileImageUrl}
|
|
395
|
+
className="userContact_image"
|
|
396
|
+
alt="not"
|
|
397
|
+
/>
|
|
398
|
+
) : (
|
|
399
|
+
<div
|
|
400
|
+
className="userContact_image"
|
|
401
|
+
style={{ textAlign: "center" }}
|
|
402
|
+
>
|
|
403
|
+
{data?.userName?.charAt(0)}
|
|
404
|
+
</div>
|
|
405
|
+
)}
|
|
406
|
+
</div>
|
|
407
|
+
<div className="d-block textColor custom_padding_left custom_padding_top">{data.userName}</div>
|
|
408
|
+
</div>
|
|
409
|
+
}
|
|
410
|
+
</>
|
|
411
|
+
);
|
|
412
|
+
}) :
|
|
413
|
+
<>
|
|
414
|
+
{
|
|
415
|
+
enteredSearchData.length > 0 &&
|
|
416
|
+
<p className="no_result_text">No result found for '{enteredSearchData}'</p>
|
|
417
|
+
}
|
|
418
|
+
</>
|
|
419
|
+
}
|
|
420
|
+
</div>
|
|
421
|
+
{
|
|
422
|
+
showUserPaginationLoader &&
|
|
423
|
+
<UserPagingLoader />
|
|
424
|
+
}
|
|
425
|
+
</div>
|
|
426
|
+
</div>
|
|
427
|
+
</>
|
|
428
|
+
) : (
|
|
429
|
+
""
|
|
430
|
+
)}
|
|
431
|
+
{props?.newGroup ? (
|
|
432
|
+
<div className="bg-white h-100">
|
|
433
|
+
<div className="newgroupSlider msgFont textColor">
|
|
434
|
+
<input placeholder="Type contact name" />
|
|
435
|
+
</div>{" "}
|
|
436
|
+
</div>
|
|
437
|
+
) : (
|
|
438
|
+
""
|
|
439
|
+
)}
|
|
440
|
+
|
|
441
|
+
{props?.isBlockedList ? (
|
|
442
|
+
<>
|
|
443
|
+
<BlockedContactSlide isBlockedList={props?.isBlockedList} theme={theme} conversationId={sidebarChatItem?.conversationId} setUserConversationDetail={setUserConversationDetail} setToastStatus={setToastStatus}/>
|
|
444
|
+
</>
|
|
445
|
+
) : (
|
|
446
|
+
""
|
|
447
|
+
)}
|
|
448
|
+
|
|
449
|
+
{props?.newCommunity ? (
|
|
450
|
+
<>
|
|
451
|
+
<div className=" bg-white pt-1" style={{ height: "83vh" }}>
|
|
452
|
+
<div className="newCommunity">
|
|
453
|
+
<input />
|
|
454
|
+
<svg
|
|
455
|
+
style={{
|
|
456
|
+
position: "absolute",
|
|
457
|
+
backkgroundSize: "cover",
|
|
458
|
+
backgroundSize: "cover",
|
|
459
|
+
width: "35%",
|
|
460
|
+
}}
|
|
461
|
+
viewBox="0 0 28 19"
|
|
462
|
+
height="190"
|
|
463
|
+
width="100"
|
|
464
|
+
preserveAspectRatio="xMidYMid meet"
|
|
465
|
+
class=""
|
|
466
|
+
fill="none"
|
|
467
|
+
>
|
|
468
|
+
<path
|
|
469
|
+
class="primary"
|
|
470
|
+
fill-rule="evenodd"
|
|
471
|
+
clip-rule="evenodd"
|
|
472
|
+
d="M20.0836 6.83416C20.0967 6.92827 20.1139 7.01977 20.1351 7.10996C20.1457 7.1557 20.1573 7.20014 20.1699 7.24328C20.1948 7.33103 20.2238 7.41741 20.257 7.50208C20.3057 7.62659 20.3631 7.74717 20.4287 7.86283C20.4722 7.93865 20.5191 8.01315 20.5692 8.08373C20.7191 8.29755 20.8986 8.48655 21.1018 8.64447C21.2385 8.74999 21.3846 8.84147 21.538 8.91765C21.6555 8.97548 21.7769 9.0244 21.9011 9.06404C21.9848 9.09019 22.0705 9.11241 22.1581 9.13071C22.3376 9.16709 22.52 9.18547 22.7028 9.1856C24.1656 9.1856 25.3514 7.93912 25.3514 6.40152C25.3514 4.86391 24.1656 3.61742 22.7028 3.61742C22.52 3.61691 22.3375 3.6353 22.1581 3.67233C22.0713 3.68975 21.9855 3.712 21.9011 3.73899C21.7769 3.77819 21.6556 3.82668 21.538 3.88408C21.1547 4.07401 20.8219 4.36045 20.5692 4.71799C20.5195 4.78988 20.4722 4.86308 20.4287 4.9402C20.3629 5.05573 20.3055 5.17632 20.257 5.30095C20.2243 5.38461 20.1948 5.47087 20.1699 5.55845C20.1573 5.60289 20.1457 5.64733 20.1351 5.69177C20.1139 5.78196 20.0967 5.87346 20.0836 5.96757C20.0442 6.25494 20.0442 6.54678 20.0836 6.83416ZM7.91635 6.83416C7.90392 6.92827 7.88614 7.01977 7.865 7.10996C7.85439 7.1557 7.84278 7.20014 7.83018 7.24328C7.80534 7.33103 7.77629 7.41741 7.74314 7.50208C7.69429 7.62657 7.63685 7.74714 7.57129 7.86283C7.52789 7.93865 7.48101 8.01315 7.4309 8.08373C7.28093 8.29748 7.10143 8.48648 6.89832 8.64447C6.76157 8.74999 6.6155 8.84147 6.46212 8.91765C6.34456 8.97548 6.22322 9.0244 6.09902 9.06404C6.01521 9.09019 5.92954 9.11241 5.842 9.13071C5.66247 9.16708 5.48007 9.18546 5.29723 9.1856C3.83446 9.1856 2.64865 7.93912 2.64865 6.40152C2.64865 4.86391 3.83446 3.61742 5.29723 3.61742C5.4801 3.61692 5.66256 3.63531 5.842 3.67233C5.92873 3.68976 6.01453 3.71202 6.09902 3.73899C6.22319 3.77819 6.34453 3.82668 6.46212 3.88407C6.84541 4.07401 7.17818 4.36045 7.4309 4.71799C7.48064 4.78988 7.52789 4.86308 7.57129 4.9402C7.63709 5.05575 7.69454 5.17634 7.74314 5.30095C7.77584 5.38461 7.80531 5.47087 7.83018 5.55845C7.8427 5.60289 7.8543 5.64733 7.865 5.69177C7.88614 5.78196 7.90342 5.87345 7.91635 5.96756C7.95581 6.25494 7.95581 6.54678 7.91635 6.83416ZM27.8468 13.6264C27.8143 13.5695 27.7783 13.5074 27.7345 13.4386C27.6874 13.3645 27.6342 13.2852 27.5732 13.2006C27.5122 13.1159 27.4447 13.026 27.3688 12.9334C27.2929 12.8409 27.21 12.7456 27.1189 12.6478C26.7459 12.251 26.3196 11.9112 25.8531 11.6388C25.7058 11.5515 25.5492 11.4695 25.3839 11.3915C25.3789 11.3888 25.3745 11.3875 25.3698 11.3848C23.4911 10.5737 21.3746 10.5737 19.4959 11.3848C19.4694 11.3967 19.4445 11.41 19.4188 11.4232C19.3767 11.443 19.3381 11.4655 19.2973 11.4867C19.3202 11.4999 19.3434 11.5118 19.3661 11.525C19.8316 11.7975 20.2733 12.1107 20.6865 12.4613C20.9563 12.6896 21.213 12.9338 21.4555 13.1926C21.6054 13.3513 21.7424 13.5087 21.8677 13.6621C21.9961 13.8195 22.1086 13.9663 22.2091 14.1064C22.3125 14.2506 22.4017 14.3842 22.4814 14.5071C22.5568 14.6262 22.6206 14.732 22.6757 14.8298C22.7802 15.0091 22.8581 15.2035 22.9069 15.4064L22.9274 15.5492H28V13.9319C27.9558 13.8266 27.9046 13.7245 27.8468 13.6264ZM18.1157 4.52771C18.0952 4.37973 18.0682 4.23574 18.0348 4.09441C18.0182 4.02375 17.9999 3.95309 17.9801 3.88376C17.9407 3.74511 17.895 3.61045 17.8436 3.47846C17.767 3.28285 17.6768 3.09346 17.5736 2.91184C17.5053 2.79185 17.4318 2.67585 17.3529 2.56386C16.957 2.00113 16.4338 1.55112 15.8306 1.25463C15.646 1.16345 15.4552 1.0868 15.2598 1.02531C15.1281 0.983983 14.9934 0.947986 14.8559 0.919988C14.5739 0.86243 14.2872 0.833328 13.9999 0.833328C11.6415 0.833328 9.83784 2.72918 9.83784 5.209C9.83784 7.68881 11.6415 9.58333 13.9999 9.58333C14.2872 9.58333 14.5739 9.55423 14.8559 9.49667C14.9934 9.46867 15.1281 9.43267 15.2598 9.39134C15.4552 9.32986 15.646 9.25321 15.8306 9.16203C16.4338 8.86554 16.957 8.41553 17.3529 7.85279C17.4317 7.7408 17.5052 7.62481 17.5736 7.50482C17.6768 7.3232 17.767 7.13381 17.8436 6.9382C17.8944 6.80621 17.9407 6.67022 17.9801 6.5329C17.9999 6.46357 18.0182 6.39291 18.0348 6.32224C18.0682 6.18092 18.0952 6.03693 18.1157 5.88894C18.1776 5.43753 18.1776 4.97913 18.1157 4.52771ZM21.7225 15.3648C21.6762 15.281 21.6229 15.1891 21.5605 15.0877C21.4934 14.9795 21.4164 14.8619 21.3294 14.7376C21.2424 14.6132 21.1454 14.4807 21.0376 14.3455C20.9298 14.2104 20.8111 14.0684 20.6809 13.9265C20.4718 13.6967 20.2507 13.4796 20.0186 13.2763C19.661 12.9642 19.2789 12.6852 18.8765 12.4422C18.6664 12.3152 18.4434 12.1935 18.2074 12.0799C18.2009 12.0758 18.1942 12.0722 18.1872 12.0691C17.0911 11.5419 15.713 11.1742 13.9997 11.1742C12.2865 11.1742 10.9082 11.5419 9.81226 12.0691C9.77405 12.0867 9.73928 12.107 9.70208 12.1259C9.54196 12.2057 9.38809 12.2895 9.2402 12.3746C9.16004 12.4219 9.08166 12.4693 9.00506 12.5166C8.64626 12.7423 8.30392 12.9962 7.98093 13.2763C7.74876 13.4796 7.52762 13.6967 7.31855 13.9265C7.18863 14.0684 7.07003 14.209 6.96189 14.3455C6.85374 14.4821 6.75694 14.6118 6.66994 14.7376C6.58293 14.8633 6.50612 14.9795 6.439 15.0877C6.37658 15.1891 6.32333 15.281 6.2771 15.3648C6.27277 15.3713 6.26882 15.3781 6.26525 15.3851C6.21659 15.4729 6.17698 15.55 6.14564 15.6135C6.08297 15.7406 6.05405 15.8122 6.05405 15.8122V18.3333H21.9459V15.8122C21.8797 15.6586 21.8051 15.5092 21.7225 15.3648ZM5.08137 15.4078C5.09313 15.3077 5.1252 15.2113 5.17549 15.1248C5.2147 15.0481 5.24415 14.9556 5.30522 14.8485C5.37299 14.7308 5.42635 14.6263 5.50041 14.5087C5.57974 14.3844 5.66499 14.2508 5.76708 14.1094C5.86918 13.9679 5.98079 13.8185 6.10628 13.6651C6.23177 13.5117 6.36961 13.3531 6.52044 13.1918C7.09885 12.5757 7.75594 12.0433 8.4737 11.6091C8.54828 11.5641 8.62517 11.5192 8.7027 11.4756C8.66914 11.4584 8.63841 11.4399 8.60357 11.424C8.57785 11.4108 8.55213 11.3975 8.52642 11.3856C7.60024 10.9683 6.59752 10.7608 5.58643 10.7774C4.57538 10.7608 3.57271 10.9683 2.64657 11.3856C2.64168 11.3883 2.63731 11.3896 2.63243 11.3923C2.46681 11.4703 2.31007 11.5522 2.16259 11.6395C1.88006 11.8047 1.6118 11.9945 1.36077 12.2067C1.19789 12.345 1.04254 12.4925 0.895433 12.6483C0.804141 12.7462 0.720736 12.8414 0.645216 12.9339C0.569482 13.0265 0.501335 13.1164 0.440259 13.201C0.379183 13.2856 0.32518 13.365 0.277991 13.439C0.234273 13.5078 0.192871 13.5699 0.16034 13.6268C0.0524608 13.8145 0 13.9322 0 13.9322V15.5492H5.07198L5.08137 15.4078Z"
|
|
473
|
+
fill="white"
|
|
474
|
+
></path>
|
|
475
|
+
</svg>
|
|
476
|
+
</div>
|
|
477
|
+
<div className="communitySlider textColor">
|
|
478
|
+
<input placeholder="Comunity name" />
|
|
479
|
+
<p style={{ color: "black", backgroundColor: "red" }}>
|
|
480
|
+
<EmojiPicker />
|
|
481
|
+
</p>
|
|
482
|
+
</div>
|
|
483
|
+
</div>
|
|
484
|
+
<div className="bg-white mt-2 description">
|
|
485
|
+
<div className="communitySlider textColor">
|
|
486
|
+
<input placeholder="Community description" />
|
|
487
|
+
</div>{" "}
|
|
488
|
+
</div>
|
|
489
|
+
</>
|
|
490
|
+
) : (
|
|
491
|
+
""
|
|
492
|
+
)}
|
|
493
|
+
|
|
494
|
+
{props?.startedMessage ? <div className="h-100 bg-white"></div> : ""}
|
|
495
|
+
|
|
496
|
+
{props?.settings ? <div className="h-100 bg-white"></div> : ""}
|
|
497
|
+
|
|
498
|
+
{props?.status ? (
|
|
499
|
+
<div className="h-100 pt-1" style={{marginTop:"108px"}}>
|
|
500
|
+
<div className="mystatus d-flex">
|
|
501
|
+
<span>
|
|
502
|
+
<img src={wb} />
|
|
503
|
+
</span>
|
|
504
|
+
<div
|
|
505
|
+
className="text-white"
|
|
506
|
+
style={{
|
|
507
|
+
display: "flex",
|
|
508
|
+
flexDirection: "column",
|
|
509
|
+
justifyContent: "space-between",
|
|
510
|
+
minWidth: "52px",
|
|
511
|
+
height: "36px",
|
|
512
|
+
marginRight: "auto",
|
|
513
|
+
}}
|
|
514
|
+
>
|
|
515
|
+
<span >My status</span>
|
|
516
|
+
<span className="text_Color textMsg"> no updates </span>{" "}
|
|
517
|
+
</div>
|
|
518
|
+
</div>
|
|
519
|
+
</div>
|
|
520
|
+
) : (
|
|
521
|
+
""
|
|
522
|
+
)}
|
|
523
|
+
</div>
|
|
524
|
+
{
|
|
525
|
+
<Toaster message={toastStatus.message} variant={toastStatus.variant} open={toastStatus.open} onClose={() => setToastStatus({open: false})} theme={theme} />
|
|
526
|
+
}
|
|
527
|
+
<style jsx>{`
|
|
528
|
+
@media(max-width: 48rem){
|
|
529
|
+
.profile_Container{
|
|
530
|
+
width:100vw
|
|
531
|
+
}
|
|
532
|
+
.profile_Div .profile_header{
|
|
533
|
+
width:100vw
|
|
534
|
+
}
|
|
535
|
+
.inputField{
|
|
536
|
+
width:100%
|
|
537
|
+
}
|
|
538
|
+
.profile_name div input{
|
|
539
|
+
width:100%
|
|
540
|
+
}
|
|
541
|
+
.profile_name div .edit_Icon{
|
|
542
|
+
// right:50px
|
|
543
|
+
}
|
|
544
|
+
`}
|
|
545
|
+
</style>
|
|
546
|
+
</>
|
|
547
|
+
);
|
|
548
|
+
}
|
|
549
|
+
|
|
550
|
+
export default Profile;
|