@kesha-antonov/react-native-chat 6.0.1 → 6.1.1
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 +36 -4
- package/lib/Actions.d.ts.map +1 -1
- package/lib/Actions.js +33 -27
- package/lib/Actions.js.map +1 -1
- package/lib/Chat/Chat.d.ts.map +1 -1
- package/lib/Chat/Chat.js +253 -203
- package/lib/Chat/Chat.js.map +1 -1
- package/lib/Chat/ChatMessageList.d.ts.map +1 -1
- package/lib/Chat/ChatMessageList.js +4 -0
- package/lib/Chat/ChatMessageList.js.map +1 -1
- package/lib/Chat/index.d.ts +9 -1
- package/lib/Chat/index.d.ts.map +1 -1
- package/lib/Chat/index.js +14 -1
- package/lib/Chat/index.js.map +1 -1
- package/lib/Chat/types.d.ts +29 -0
- package/lib/Chat/types.d.ts.map +1 -1
- package/lib/Chat/types.js.map +1 -1
- package/lib/Chat/useMessageActions.d.ts +1 -0
- package/lib/Chat/useMessageActions.d.ts.map +1 -1
- package/lib/Chat/useMessageActions.js +97 -89
- package/lib/Chat/useMessageActions.js.map +1 -1
- package/lib/ChatHeader.d.ts +50 -0
- package/lib/ChatHeader.d.ts.map +1 -0
- package/lib/ChatHeader.js +356 -0
- package/lib/ChatHeader.js.map +1 -0
- package/lib/ChatList/ChatListCell.d.ts +1 -1
- package/lib/ChatList/ChatListCell.d.ts.map +1 -1
- package/lib/ChatList/ChatListCell.js +42 -11
- package/lib/ChatList/ChatListCell.js.map +1 -1
- package/lib/ChatList/index.js +332 -323
- package/lib/ChatList/index.js.map +1 -1
- package/lib/ChatList/types.d.ts +17 -1
- package/lib/ChatList/types.d.ts.map +1 -1
- package/lib/ChatList/types.js.map +1 -1
- package/lib/ChatList/utils.d.ts +4 -1
- package/lib/ChatList/utils.d.ts.map +1 -1
- package/lib/ChatList/utils.js +3 -2
- package/lib/ChatList/utils.js.map +1 -1
- package/lib/Composer.js +5 -1
- package/lib/Composer.js.map +1 -1
- package/lib/InputToolbar/fragments.d.ts +1 -1
- package/lib/InputToolbar/fragments.d.ts.map +1 -1
- package/lib/InputToolbar/fragments.js +9 -7
- package/lib/InputToolbar/fragments.js.map +1 -1
- package/lib/InputToolbar/index.d.ts.map +1 -1
- package/lib/InputToolbar/index.js +3 -2
- package/lib/InputToolbar/index.js.map +1 -1
- package/lib/InputToolbar/types.d.ts +6 -0
- package/lib/InputToolbar/types.d.ts.map +1 -1
- package/lib/InputToolbar/types.js.map +1 -1
- package/lib/InputToolbar/useActionsFragment.d.ts.map +1 -1
- package/lib/InputToolbar/useActionsFragment.js +83 -59
- package/lib/InputToolbar/useActionsFragment.js.map +1 -1
- package/lib/InputToolbar/useKeyboardInset.d.ts +1 -1
- package/lib/InputToolbar/useKeyboardInset.d.ts.map +1 -1
- package/lib/InputToolbar/useKeyboardInset.js +2 -2
- package/lib/InputToolbar/useKeyboardInset.js.map +1 -1
- package/lib/MessageText.d.ts.map +1 -1
- package/lib/MessageText.js +39 -33
- package/lib/MessageText.js.map +1 -1
- package/lib/MessagesContainer/index.d.ts.map +1 -1
- package/lib/MessagesContainer/index.js +113 -94
- package/lib/MessagesContainer/index.js.map +1 -1
- package/lib/MessagesContainer/types.d.ts +5 -2
- package/lib/MessagesContainer/types.d.ts.map +1 -1
- package/lib/MessagesContainer/types.js.map +1 -1
- package/lib/MessagesContainer/useChained.d.ts +6 -0
- package/lib/MessagesContainer/useChained.d.ts.map +1 -0
- package/lib/MessagesContainer/useChained.js +38 -0
- package/lib/MessagesContainer/useChained.js.map +1 -0
- package/lib/MessagesContainer/useListChrome.d.ts.map +1 -1
- package/lib/MessagesContainer/useListChrome.js +1 -1
- package/lib/MessagesContainer/useListChrome.js.map +1 -1
- package/lib/Models.d.ts +2 -1
- package/lib/Models.d.ts.map +1 -1
- package/lib/Models.js.map +1 -1
- package/lib/Send.d.ts.map +1 -1
- package/lib/Send.js +18 -13
- package/lib/Send.js.map +1 -1
- package/lib/Theme.d.ts +11 -0
- package/lib/Theme.d.ts.map +1 -1
- package/lib/Theme.js +17 -1
- package/lib/Theme.js.map +1 -1
- package/lib/attachments/AttachmentButton.js +17 -15
- package/lib/attachments/AttachmentButton.js.map +1 -1
- package/lib/attachments/AttachmentMenu/GalleryGrid.d.ts +3 -1
- package/lib/attachments/AttachmentMenu/GalleryGrid.d.ts.map +1 -1
- package/lib/attachments/AttachmentMenu/GalleryGrid.js +69 -68
- package/lib/attachments/AttachmentMenu/GalleryGrid.js.map +1 -1
- package/lib/attachments/AttachmentMenu/TabPanel.d.ts +3 -1
- package/lib/attachments/AttachmentMenu/TabPanel.d.ts.map +1 -1
- package/lib/attachments/AttachmentMenu/TabPanel.js +23 -21
- package/lib/attachments/AttachmentMenu/TabPanel.js.map +1 -1
- package/lib/attachments/AttachmentMenu/index.d.ts +6 -2
- package/lib/attachments/AttachmentMenu/index.d.ts.map +1 -1
- package/lib/attachments/AttachmentMenu/index.js +259 -247
- package/lib/attachments/AttachmentMenu/index.js.map +1 -1
- package/lib/attachments/buildMessages.d.ts +4 -4
- package/lib/attachments/buildMessages.d.ts.map +1 -1
- package/lib/attachments/buildMessages.js +9 -8
- package/lib/attachments/buildMessages.js.map +1 -1
- package/lib/attachments/types.d.ts +19 -0
- package/lib/attachments/types.d.ts.map +1 -1
- package/lib/attachments/types.js.map +1 -1
- package/lib/components/TouchableOpacity.d.ts +5 -0
- package/lib/components/TouchableOpacity.d.ts.map +1 -1
- package/lib/components/TouchableOpacity.js +59 -54
- package/lib/components/TouchableOpacity.js.map +1 -1
- package/lib/components/defaultMessageActions.d.ts +3 -1
- package/lib/components/defaultMessageActions.d.ts.map +1 -1
- package/lib/components/defaultMessageActions.js +9 -1
- package/lib/components/defaultMessageActions.js.map +1 -1
- package/lib/components/textHighlight.d.ts +14 -0
- package/lib/components/textHighlight.d.ts.map +1 -0
- package/lib/components/textHighlight.js +39 -0
- package/lib/components/textHighlight.js.map +1 -0
- package/lib/hooks/useKeyboardVerticalOffset.d.ts +6 -0
- package/lib/hooks/useKeyboardVerticalOffset.d.ts.map +1 -1
- package/lib/hooks/useKeyboardVerticalOffset.js +35 -13
- package/lib/hooks/useKeyboardVerticalOffset.js.map +1 -1
- package/lib/i18n.d.ts +2 -0
- package/lib/i18n.d.ts.map +1 -1
- package/lib/i18n.js +1 -0
- package/lib/i18n.js.map +1 -1
- package/lib/index.d.ts +3 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +1 -0
- package/lib/index.js.map +1 -1
- package/lib/linkParser.d.ts +4 -1
- package/lib/linkParser.d.ts.map +1 -1
- package/lib/linkParser.js +115 -78
- package/lib/linkParser.js.map +1 -1
- package/lib/locales/ar.d.ts.map +1 -1
- package/lib/locales/ar.js +1 -0
- package/lib/locales/ar.js.map +1 -1
- package/lib/locales/de.d.ts.map +1 -1
- package/lib/locales/de.js +1 -0
- package/lib/locales/de.js.map +1 -1
- package/lib/locales/es.d.ts.map +1 -1
- package/lib/locales/es.js +1 -0
- package/lib/locales/es.js.map +1 -1
- package/lib/locales/fr.d.ts.map +1 -1
- package/lib/locales/fr.js +1 -0
- package/lib/locales/fr.js.map +1 -1
- package/lib/locales/hi.d.ts.map +1 -1
- package/lib/locales/hi.js +1 -0
- package/lib/locales/hi.js.map +1 -1
- package/lib/locales/id.d.ts.map +1 -1
- package/lib/locales/id.js +1 -0
- package/lib/locales/id.js.map +1 -1
- package/lib/locales/it.d.ts.map +1 -1
- package/lib/locales/it.js +1 -0
- package/lib/locales/it.js.map +1 -1
- package/lib/locales/ja.d.ts.map +1 -1
- package/lib/locales/ja.js +1 -0
- package/lib/locales/ja.js.map +1 -1
- package/lib/locales/ko.d.ts.map +1 -1
- package/lib/locales/ko.js +1 -0
- package/lib/locales/ko.js.map +1 -1
- package/lib/locales/nl.d.ts.map +1 -1
- package/lib/locales/nl.js +1 -0
- package/lib/locales/nl.js.map +1 -1
- package/lib/locales/pl.d.ts.map +1 -1
- package/lib/locales/pl.js +1 -0
- package/lib/locales/pl.js.map +1 -1
- package/lib/locales/pt.d.ts.map +1 -1
- package/lib/locales/pt.js +1 -0
- package/lib/locales/pt.js.map +1 -1
- package/lib/locales/ru.d.ts.map +1 -1
- package/lib/locales/ru.js +1 -0
- package/lib/locales/ru.js.map +1 -1
- package/lib/locales/tr.d.ts.map +1 -1
- package/lib/locales/tr.js +1 -0
- package/lib/locales/tr.js.map +1 -1
- package/lib/locales/zh.d.ts.map +1 -1
- package/lib/locales/zh.js +1 -0
- package/lib/locales/zh.js.map +1 -1
- package/llms.txt +1 -1
- package/package.json +1 -1
package/lib/Chat/Chat.js
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { c as _c } from "react/compiler-runtime";
|
|
2
|
-
import React, { createRef, useEffect, useMemo, useState } from 'react';
|
|
2
|
+
import React, { createRef, useEffect, useImperativeHandle, useMemo, useState } from 'react';
|
|
3
3
|
import { View } from 'react-native';
|
|
4
4
|
import { ChatContext } from '../ChatContext';
|
|
5
5
|
import { createComposerPanelsStore } from '../components/composerPanels';
|
|
6
6
|
import { MediaViewerHost } from '../components/mediaViewer/MediaViewerHost';
|
|
7
|
+
import { TextHighlightContext } from '../components/textHighlight';
|
|
7
8
|
import { TEST_ID } from '../Constant';
|
|
8
9
|
import stylesCommon from '../styles';
|
|
9
10
|
import { renderComponentOrElement } from '../utils';
|
|
@@ -24,7 +25,7 @@ import { useMessageNavigation } from './useMessageNavigation';
|
|
|
24
25
|
import { useOptionalPeerHints } from './useOptionalPeerHints';
|
|
25
26
|
import { useIsGroupChat, useResolvedReactions } from './useResolvedReactions';
|
|
26
27
|
export function Chat(props) {
|
|
27
|
-
const $ = _c(
|
|
28
|
+
const $ = _c(138);
|
|
28
29
|
const {
|
|
29
30
|
messages: t0,
|
|
30
31
|
initialText: t1,
|
|
@@ -155,62 +156,87 @@ export function Chat(props) {
|
|
|
155
156
|
jumpToQuotedMessage,
|
|
156
157
|
pageDownReturn
|
|
157
158
|
} = useMessageNavigation(t10);
|
|
159
|
+
let t11;
|
|
160
|
+
let t12;
|
|
161
|
+
if ($[21] !== highlightStore || $[22] !== messagesContainerRef) {
|
|
162
|
+
t11 = () => ({
|
|
163
|
+
scrollToMessage: (messageId, options) => {
|
|
164
|
+
messagesContainerRef.current?.scrollToKey({
|
|
165
|
+
key: String(messageId),
|
|
166
|
+
animated: options?.animated ?? true,
|
|
167
|
+
viewPosition: options?.viewPosition ?? 0.5
|
|
168
|
+
});
|
|
169
|
+
if (options?.isHighlighted) {
|
|
170
|
+
highlightStore.highlight(messageId);
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
});
|
|
174
|
+
t12 = [messagesContainerRef, highlightStore];
|
|
175
|
+
$[21] = highlightStore;
|
|
176
|
+
$[22] = messagesContainerRef;
|
|
177
|
+
$[23] = t11;
|
|
178
|
+
$[24] = t12;
|
|
179
|
+
} else {
|
|
180
|
+
t11 = $[23];
|
|
181
|
+
t12 = $[24];
|
|
182
|
+
}
|
|
183
|
+
useImperativeHandle(props.chatRef, t11, t12);
|
|
158
184
|
const isSwipeEnabled = isReplyEnabled && (reply?.swipe?.isEnabled ?? true);
|
|
159
|
-
const
|
|
160
|
-
const
|
|
161
|
-
let
|
|
162
|
-
if ($[
|
|
163
|
-
|
|
164
|
-
...
|
|
185
|
+
const t13 = reply?.onPress ?? jumpToQuotedMessage;
|
|
186
|
+
const t14 = reply?.swipe;
|
|
187
|
+
let t15;
|
|
188
|
+
if ($[25] !== handleSwipeToReply || $[26] !== isSwipeEnabled || $[27] !== t14) {
|
|
189
|
+
t15 = {
|
|
190
|
+
...t14,
|
|
165
191
|
isEnabled: isSwipeEnabled,
|
|
166
192
|
onSwipe: handleSwipeToReply
|
|
167
193
|
};
|
|
168
|
-
$[
|
|
169
|
-
$[
|
|
170
|
-
$[
|
|
171
|
-
$[
|
|
194
|
+
$[25] = handleSwipeToReply;
|
|
195
|
+
$[26] = isSwipeEnabled;
|
|
196
|
+
$[27] = t14;
|
|
197
|
+
$[28] = t15;
|
|
172
198
|
} else {
|
|
173
|
-
|
|
199
|
+
t15 = $[28];
|
|
174
200
|
}
|
|
175
|
-
let
|
|
176
|
-
if ($[
|
|
177
|
-
|
|
201
|
+
let t16;
|
|
202
|
+
if ($[29] !== reply || $[30] !== t13 || $[31] !== t15) {
|
|
203
|
+
t16 = {
|
|
178
204
|
...reply,
|
|
179
|
-
onPress:
|
|
180
|
-
swipe:
|
|
205
|
+
onPress: t13,
|
|
206
|
+
swipe: t15
|
|
181
207
|
};
|
|
182
|
-
$[
|
|
183
|
-
$[
|
|
184
|
-
$[
|
|
185
|
-
$[
|
|
208
|
+
$[29] = reply;
|
|
209
|
+
$[30] = t13;
|
|
210
|
+
$[31] = t15;
|
|
211
|
+
$[32] = t16;
|
|
186
212
|
} else {
|
|
187
|
-
|
|
213
|
+
t16 = $[32];
|
|
188
214
|
}
|
|
189
|
-
const replyForList =
|
|
215
|
+
const replyForList = t16;
|
|
190
216
|
const userId = user?._id;
|
|
191
217
|
const isGroupChat = useIsGroupChat(messages, userId, isGroupChatProp);
|
|
192
218
|
const isAvatarVisible = isAvatarVisibleProp ?? (renderAvatar ? true : isGroupChat);
|
|
193
219
|
const isUsernameVisible = isUsernameVisibleProp ?? isGroupChat;
|
|
194
|
-
let
|
|
195
|
-
if ($[
|
|
196
|
-
|
|
220
|
+
let t17;
|
|
221
|
+
if ($[33] !== isGroupChat || $[34] !== messages || $[35] !== reactions || $[36] !== user) {
|
|
222
|
+
t17 = {
|
|
197
223
|
reactions,
|
|
198
224
|
messages,
|
|
199
225
|
user,
|
|
200
226
|
isGroupChat
|
|
201
227
|
};
|
|
202
|
-
$[
|
|
203
|
-
$[
|
|
204
|
-
$[
|
|
205
|
-
$[
|
|
206
|
-
$[
|
|
228
|
+
$[33] = isGroupChat;
|
|
229
|
+
$[34] = messages;
|
|
230
|
+
$[35] = reactions;
|
|
231
|
+
$[36] = user;
|
|
232
|
+
$[37] = t17;
|
|
207
233
|
} else {
|
|
208
|
-
|
|
234
|
+
t17 = $[37];
|
|
209
235
|
}
|
|
210
|
-
const resolvedReactions = useResolvedReactions(
|
|
211
|
-
let
|
|
212
|
-
if ($[
|
|
213
|
-
|
|
236
|
+
const resolvedReactions = useResolvedReactions(t17);
|
|
237
|
+
let t18;
|
|
238
|
+
if ($[38] !== composerPanels || $[39] !== editStore || $[40] !== isReplyEnabled || $[41] !== props || $[42] !== resolvedLabels || $[43] !== selectionStore || $[44] !== startEdit || $[45] !== startReply || $[46] !== stopEdit || $[47] !== userId) {
|
|
239
|
+
t18 = {
|
|
214
240
|
props,
|
|
215
241
|
userId,
|
|
216
242
|
resolvedLabels,
|
|
@@ -222,19 +248,19 @@ export function Chat(props) {
|
|
|
222
248
|
composerPanels,
|
|
223
249
|
selectionStore
|
|
224
250
|
};
|
|
225
|
-
$[
|
|
226
|
-
$[
|
|
227
|
-
$[
|
|
228
|
-
$[
|
|
229
|
-
$[
|
|
230
|
-
$[
|
|
231
|
-
$[
|
|
232
|
-
$[
|
|
233
|
-
$[
|
|
234
|
-
$[
|
|
235
|
-
$[
|
|
251
|
+
$[38] = composerPanels;
|
|
252
|
+
$[39] = editStore;
|
|
253
|
+
$[40] = isReplyEnabled;
|
|
254
|
+
$[41] = props;
|
|
255
|
+
$[42] = resolvedLabels;
|
|
256
|
+
$[43] = selectionStore;
|
|
257
|
+
$[44] = startEdit;
|
|
258
|
+
$[45] = startReply;
|
|
259
|
+
$[46] = stopEdit;
|
|
260
|
+
$[47] = userId;
|
|
261
|
+
$[48] = t18;
|
|
236
262
|
} else {
|
|
237
|
-
|
|
263
|
+
t18 = $[48];
|
|
238
264
|
}
|
|
239
265
|
const {
|
|
240
266
|
resolvedMessageActions,
|
|
@@ -243,222 +269,246 @@ export function Chat(props) {
|
|
|
243
269
|
copySelection,
|
|
244
270
|
forwardSelection,
|
|
245
271
|
deleteSelection
|
|
246
|
-
} = useMessageActions(
|
|
247
|
-
let
|
|
248
|
-
if ($[
|
|
249
|
-
|
|
272
|
+
} = useMessageActions(t18);
|
|
273
|
+
let t19;
|
|
274
|
+
if ($[49] !== actionCallbacksRef || $[50] !== composer || $[51] !== messagesContainerRef || $[52] !== props || $[53] !== textInputRef) {
|
|
275
|
+
t19 = {
|
|
250
276
|
...composer,
|
|
251
277
|
props,
|
|
252
278
|
textInputRef,
|
|
253
279
|
messagesContainerRef,
|
|
254
280
|
actionCallbacksRef
|
|
255
281
|
};
|
|
256
|
-
$[
|
|
257
|
-
$[
|
|
258
|
-
$[
|
|
259
|
-
$[
|
|
260
|
-
$[
|
|
261
|
-
$[
|
|
282
|
+
$[49] = actionCallbacksRef;
|
|
283
|
+
$[50] = composer;
|
|
284
|
+
$[51] = messagesContainerRef;
|
|
285
|
+
$[52] = props;
|
|
286
|
+
$[53] = textInputRef;
|
|
287
|
+
$[54] = t19;
|
|
262
288
|
} else {
|
|
263
|
-
|
|
289
|
+
t19 = $[54];
|
|
264
290
|
}
|
|
265
291
|
const {
|
|
266
292
|
inputToolbarFragment,
|
|
267
293
|
sendGreeting,
|
|
268
294
|
notifyInputTextReset
|
|
269
|
-
} = useComposerHandlers(
|
|
295
|
+
} = useComposerHandlers(t19);
|
|
270
296
|
const [isListMounted, setIsListMounted] = useState(false);
|
|
271
|
-
let
|
|
272
|
-
let
|
|
273
|
-
if ($[
|
|
274
|
-
|
|
297
|
+
let t20;
|
|
298
|
+
let t21;
|
|
299
|
+
if ($[55] === Symbol.for("react.memo_cache_sentinel")) {
|
|
300
|
+
t20 = () => {
|
|
275
301
|
const frame = requestAnimationFrame(() => setIsListMounted(true));
|
|
276
302
|
return () => cancelAnimationFrame(frame);
|
|
277
303
|
};
|
|
278
|
-
|
|
279
|
-
$[
|
|
280
|
-
$[
|
|
304
|
+
t21 = [];
|
|
305
|
+
$[55] = t20;
|
|
306
|
+
$[56] = t21;
|
|
281
307
|
} else {
|
|
282
|
-
|
|
283
|
-
|
|
308
|
+
t20 = $[55];
|
|
309
|
+
t21 = $[56];
|
|
284
310
|
}
|
|
285
|
-
useEffect(
|
|
311
|
+
useEffect(t20, t21);
|
|
286
312
|
useOptionalPeerHints(props.audioRecording, props.videoRecording);
|
|
287
|
-
let
|
|
288
|
-
if ($[
|
|
289
|
-
|
|
313
|
+
let t22;
|
|
314
|
+
if ($[57] !== composer.getTextFromProp || $[58] !== initialText || $[59] !== notifyInputTextReset || $[60] !== textStore) {
|
|
315
|
+
t22 = {
|
|
290
316
|
initialText,
|
|
291
317
|
textStore,
|
|
292
318
|
getTextFromProp: composer.getTextFromProp,
|
|
293
319
|
notifyInputTextReset
|
|
294
320
|
};
|
|
295
|
-
$[
|
|
296
|
-
$[
|
|
297
|
-
$[
|
|
298
|
-
$[
|
|
299
|
-
$[
|
|
321
|
+
$[57] = composer.getTextFromProp;
|
|
322
|
+
$[58] = initialText;
|
|
323
|
+
$[59] = notifyInputTextReset;
|
|
324
|
+
$[60] = textStore;
|
|
325
|
+
$[61] = t22;
|
|
300
326
|
} else {
|
|
301
|
-
|
|
327
|
+
t22 = $[61];
|
|
302
328
|
}
|
|
303
329
|
const {
|
|
304
330
|
isReady,
|
|
305
331
|
keyboardOffsetRef,
|
|
306
332
|
keyboardVerticalOffset,
|
|
307
333
|
onInitialLayoutViewLayout
|
|
308
|
-
} = useInitialLayout(
|
|
334
|
+
} = useInitialLayout(t22);
|
|
309
335
|
const isSelectionBarShown = isSelecting && renderSelectionBar !== null;
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
336
|
+
const highlightText = props.highlightText;
|
|
337
|
+
const highlightTextStyle = props.highlightTextStyle;
|
|
338
|
+
let t23;
|
|
339
|
+
if ($[62] !== highlightText || $[63] !== highlightTextStyle) {
|
|
340
|
+
t23 = highlightText?.trim() ? {
|
|
341
|
+
text: highlightText,
|
|
342
|
+
style: highlightTextStyle
|
|
343
|
+
} : null;
|
|
344
|
+
$[62] = highlightText;
|
|
345
|
+
$[63] = highlightTextStyle;
|
|
346
|
+
$[64] = t23;
|
|
317
347
|
} else {
|
|
318
|
-
|
|
348
|
+
t23 = $[64];
|
|
319
349
|
}
|
|
320
|
-
|
|
321
|
-
if ($[60] !== isInverted || $[61] !== messages || $[62] !== renderWallpaper || $[63] !== resolvedTheme || $[64] !== userId) {
|
|
322
|
-
t22 = <ChatBackground messages={messages} userId={userId} isInverted={isInverted} theme={resolvedTheme} renderWallpaper={renderWallpaper} />;
|
|
323
|
-
$[60] = isInverted;
|
|
324
|
-
$[61] = messages;
|
|
325
|
-
$[62] = renderWallpaper;
|
|
326
|
-
$[63] = resolvedTheme;
|
|
327
|
-
$[64] = userId;
|
|
328
|
-
$[65] = t22;
|
|
329
|
-
} else {
|
|
330
|
-
t22 = $[65];
|
|
331
|
-
}
|
|
332
|
-
const t23 = !isReady && styles.hidden;
|
|
350
|
+
const textHighlight = t23;
|
|
333
351
|
let t24;
|
|
334
|
-
if ($[
|
|
335
|
-
t24 = [stylesCommon.fill,
|
|
336
|
-
|
|
337
|
-
|
|
352
|
+
if ($[65] !== resolvedTheme.colors.background) {
|
|
353
|
+
t24 = [stylesCommon.fill, styles.contentContainer, {
|
|
354
|
+
backgroundColor: resolvedTheme.colors.background
|
|
355
|
+
}];
|
|
356
|
+
$[65] = resolvedTheme.colors.background;
|
|
357
|
+
$[66] = t24;
|
|
338
358
|
} else {
|
|
339
|
-
t24 = $[
|
|
359
|
+
t24 = $[66];
|
|
340
360
|
}
|
|
341
361
|
let t25;
|
|
342
|
-
if ($[
|
|
343
|
-
t25 = <
|
|
344
|
-
$[
|
|
345
|
-
$[
|
|
346
|
-
$[
|
|
347
|
-
$[
|
|
348
|
-
$[
|
|
349
|
-
$[
|
|
350
|
-
$[74] = messagesContainerRef;
|
|
351
|
-
$[75] = pageDownReturn;
|
|
352
|
-
$[76] = props;
|
|
353
|
-
$[77] = replyForList;
|
|
354
|
-
$[78] = resolvedMessageActions;
|
|
355
|
-
$[79] = resolvedReactions;
|
|
356
|
-
$[80] = scrollToMessage;
|
|
357
|
-
$[81] = sendGreeting;
|
|
358
|
-
$[82] = t25;
|
|
362
|
+
if ($[67] !== isInverted || $[68] !== messages || $[69] !== renderWallpaper || $[70] !== resolvedTheme || $[71] !== userId) {
|
|
363
|
+
t25 = <ChatBackground messages={messages} userId={userId} isInverted={isInverted} theme={resolvedTheme} renderWallpaper={renderWallpaper} />;
|
|
364
|
+
$[67] = isInverted;
|
|
365
|
+
$[68] = messages;
|
|
366
|
+
$[69] = renderWallpaper;
|
|
367
|
+
$[70] = resolvedTheme;
|
|
368
|
+
$[71] = userId;
|
|
369
|
+
$[72] = t25;
|
|
359
370
|
} else {
|
|
360
|
-
t25 = $[
|
|
371
|
+
t25 = $[72];
|
|
361
372
|
}
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
$[
|
|
367
|
-
$[
|
|
368
|
-
$[86] = hasClipboard;
|
|
369
|
-
$[87] = isSelectionBarShown;
|
|
370
|
-
$[88] = messages;
|
|
371
|
-
$[89] = renderSelectionBar;
|
|
372
|
-
$[90] = selectionStore;
|
|
373
|
-
$[91] = t26;
|
|
373
|
+
const t26 = !isReady && styles.hidden;
|
|
374
|
+
let t27;
|
|
375
|
+
if ($[73] !== t26) {
|
|
376
|
+
t27 = [stylesCommon.fill, t26];
|
|
377
|
+
$[73] = t26;
|
|
378
|
+
$[74] = t27;
|
|
374
379
|
} else {
|
|
375
|
-
|
|
380
|
+
t27 = $[74];
|
|
376
381
|
}
|
|
377
|
-
const t27 = isSelectionBarShown ? styles.composerAway : undefined;
|
|
378
382
|
let t28;
|
|
379
|
-
if ($[
|
|
380
|
-
t28 = <
|
|
381
|
-
$[
|
|
382
|
-
$[
|
|
383
|
-
$[
|
|
383
|
+
if ($[75] !== getSenderName || $[76] !== isAvatarVisible || $[77] !== isInverted || $[78] !== isListMounted || $[79] !== isUsernameVisible || $[80] !== messages || $[81] !== messagesContainerRef || $[82] !== pageDownReturn || $[83] !== props || $[84] !== replyForList || $[85] !== resolvedMessageActions || $[86] !== resolvedReactions || $[87] !== scrollToMessage || $[88] !== sendGreeting) {
|
|
384
|
+
t28 = <ChatMessageList isMounted={isListMounted} chatProps={props} messages={messages} isInverted={isInverted} messagesContainerRef={messagesContainerRef} replyForList={replyForList} pageDownReturn={pageDownReturn} getSenderName={getSenderName} scrollToMessage={scrollToMessage} resolvedMessageActions={resolvedMessageActions} resolvedReactions={resolvedReactions} isAvatarVisible={isAvatarVisible} isUsernameVisible={isUsernameVisible} sendGreeting={sendGreeting} />;
|
|
385
|
+
$[75] = getSenderName;
|
|
386
|
+
$[76] = isAvatarVisible;
|
|
387
|
+
$[77] = isInverted;
|
|
388
|
+
$[78] = isListMounted;
|
|
389
|
+
$[79] = isUsernameVisible;
|
|
390
|
+
$[80] = messages;
|
|
391
|
+
$[81] = messagesContainerRef;
|
|
392
|
+
$[82] = pageDownReturn;
|
|
393
|
+
$[83] = props;
|
|
394
|
+
$[84] = replyForList;
|
|
395
|
+
$[85] = resolvedMessageActions;
|
|
396
|
+
$[86] = resolvedReactions;
|
|
397
|
+
$[87] = scrollToMessage;
|
|
398
|
+
$[88] = sendGreeting;
|
|
399
|
+
$[89] = t28;
|
|
384
400
|
} else {
|
|
385
|
-
t28 = $[
|
|
401
|
+
t28 = $[89];
|
|
386
402
|
}
|
|
387
403
|
let t29;
|
|
388
|
-
if ($[95] !==
|
|
389
|
-
t29 = <
|
|
390
|
-
$[
|
|
391
|
-
$[
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
$[
|
|
399
|
-
$[98] = highlightStore;
|
|
400
|
-
$[99] = mediaController;
|
|
401
|
-
$[100] = mediaGallery;
|
|
402
|
-
$[101] = mediaTransferController;
|
|
403
|
-
$[102] = selectionStore;
|
|
404
|
-
$[103] = t25;
|
|
405
|
-
$[104] = t26;
|
|
406
|
-
$[105] = t28;
|
|
407
|
-
$[106] = t29;
|
|
408
|
-
$[107] = t30;
|
|
404
|
+
if ($[90] !== copySelection || $[91] !== deleteSelection || $[92] !== forwardSelection || $[93] !== hasClipboard || $[94] !== isSelectionBarShown || $[95] !== messages || $[96] !== renderSelectionBar || $[97] !== selectionStore) {
|
|
405
|
+
t29 = isSelectionBarShown && <ChatSelectionBar store={selectionStore} messages={messages} canCopy={hasClipboard} onCopy={copySelection} onForward={forwardSelection} onDelete={deleteSelection} renderSelectionBar={renderSelectionBar} />;
|
|
406
|
+
$[90] = copySelection;
|
|
407
|
+
$[91] = deleteSelection;
|
|
408
|
+
$[92] = forwardSelection;
|
|
409
|
+
$[93] = hasClipboard;
|
|
410
|
+
$[94] = isSelectionBarShown;
|
|
411
|
+
$[95] = messages;
|
|
412
|
+
$[96] = renderSelectionBar;
|
|
413
|
+
$[97] = selectionStore;
|
|
414
|
+
$[98] = t29;
|
|
409
415
|
} else {
|
|
410
|
-
|
|
416
|
+
t29 = $[98];
|
|
411
417
|
}
|
|
418
|
+
const t30 = isSelectionBarShown ? styles.composerAway : undefined;
|
|
412
419
|
let t31;
|
|
413
|
-
if ($[
|
|
414
|
-
t31 = <View
|
|
415
|
-
$[
|
|
416
|
-
$[
|
|
417
|
-
$[
|
|
420
|
+
if ($[99] !== inputToolbarFragment || $[100] !== t30) {
|
|
421
|
+
t31 = <View collapsable={false} style={t30}>{inputToolbarFragment}</View>;
|
|
422
|
+
$[99] = inputToolbarFragment;
|
|
423
|
+
$[100] = t30;
|
|
424
|
+
$[101] = t31;
|
|
418
425
|
} else {
|
|
419
|
-
t31 = $[
|
|
426
|
+
t31 = $[101];
|
|
420
427
|
}
|
|
421
428
|
let t32;
|
|
422
|
-
if ($[
|
|
423
|
-
t32 =
|
|
424
|
-
$[
|
|
425
|
-
$[
|
|
426
|
-
$[113] = t32;
|
|
429
|
+
if ($[102] !== mediaGallery) {
|
|
430
|
+
t32 = <MediaViewerHost gallery={mediaGallery} />;
|
|
431
|
+
$[102] = mediaGallery;
|
|
432
|
+
$[103] = t32;
|
|
427
433
|
} else {
|
|
428
|
-
t32 = $[
|
|
434
|
+
t32 = $[103];
|
|
429
435
|
}
|
|
430
436
|
let t33;
|
|
431
|
-
if ($[
|
|
432
|
-
t33 = <
|
|
433
|
-
$[
|
|
434
|
-
$[
|
|
435
|
-
$[
|
|
436
|
-
$[
|
|
437
|
-
$[
|
|
437
|
+
if ($[104] !== composerPanels || $[105] !== highlightStore || $[106] !== mediaController || $[107] !== mediaGallery || $[108] !== mediaTransferController || $[109] !== selectionStore || $[110] !== t28 || $[111] !== t29 || $[112] !== t31 || $[113] !== t32) {
|
|
438
|
+
t33 = <ChatProviders mediaController={mediaController} mediaTransferController={mediaTransferController} highlightStore={highlightStore} selectionStore={selectionStore} composerPanels={composerPanels} mediaGallery={mediaGallery}>{t28}{t29}{t31}{t32}</ChatProviders>;
|
|
439
|
+
$[104] = composerPanels;
|
|
440
|
+
$[105] = highlightStore;
|
|
441
|
+
$[106] = mediaController;
|
|
442
|
+
$[107] = mediaGallery;
|
|
443
|
+
$[108] = mediaTransferController;
|
|
444
|
+
$[109] = selectionStore;
|
|
445
|
+
$[110] = t28;
|
|
446
|
+
$[111] = t29;
|
|
447
|
+
$[112] = t31;
|
|
448
|
+
$[113] = t32;
|
|
449
|
+
$[114] = t33;
|
|
438
450
|
} else {
|
|
439
|
-
t33 = $[
|
|
451
|
+
t33 = $[114];
|
|
440
452
|
}
|
|
441
453
|
let t34;
|
|
442
|
-
if ($[
|
|
443
|
-
t34 = <View testID={TEST_ID.
|
|
444
|
-
$[
|
|
445
|
-
$[
|
|
446
|
-
$[
|
|
447
|
-
$[122] = t22;
|
|
448
|
-
$[123] = t33;
|
|
449
|
-
$[124] = t34;
|
|
454
|
+
if ($[115] !== t27 || $[116] !== t33) {
|
|
455
|
+
t34 = <View testID={TEST_ID.CONTENT} collapsable={false} style={t27}>{t33}</View>;
|
|
456
|
+
$[115] = t27;
|
|
457
|
+
$[116] = t33;
|
|
458
|
+
$[117] = t34;
|
|
450
459
|
} else {
|
|
451
|
-
t34 = $[
|
|
460
|
+
t34 = $[117];
|
|
452
461
|
}
|
|
453
462
|
let t35;
|
|
454
|
-
if ($[
|
|
455
|
-
t35 =
|
|
456
|
-
$[
|
|
457
|
-
$[
|
|
458
|
-
$[
|
|
463
|
+
if ($[118] !== isReady || $[119] !== renderLoading) {
|
|
464
|
+
t35 = !isReady && renderComponentOrElement(renderLoading, {});
|
|
465
|
+
$[118] = isReady;
|
|
466
|
+
$[119] = renderLoading;
|
|
467
|
+
$[120] = t35;
|
|
468
|
+
} else {
|
|
469
|
+
t35 = $[120];
|
|
470
|
+
}
|
|
471
|
+
let t36;
|
|
472
|
+
if ($[121] !== keyboardVerticalOffset || $[122] !== props.keyboardAvoidingViewProps || $[123] !== t34 || $[124] !== t35) {
|
|
473
|
+
t36 = <ChatKeyboardAvoidingView keyboardVerticalOffset={keyboardVerticalOffset} keyboardAvoidingViewProps={props.keyboardAvoidingViewProps}>{t34}{t35}</ChatKeyboardAvoidingView>;
|
|
474
|
+
$[121] = keyboardVerticalOffset;
|
|
475
|
+
$[122] = props.keyboardAvoidingViewProps;
|
|
476
|
+
$[123] = t34;
|
|
477
|
+
$[124] = t35;
|
|
478
|
+
$[125] = t36;
|
|
479
|
+
} else {
|
|
480
|
+
t36 = $[125];
|
|
481
|
+
}
|
|
482
|
+
let t37;
|
|
483
|
+
if ($[126] !== keyboardOffsetRef || $[127] !== onInitialLayoutViewLayout || $[128] !== t24 || $[129] !== t25 || $[130] !== t36) {
|
|
484
|
+
t37 = <View testID={TEST_ID.WRAPPER} ref={keyboardOffsetRef} style={t24} onLayout={onInitialLayoutViewLayout}>{t25}{t36}</View>;
|
|
485
|
+
$[126] = keyboardOffsetRef;
|
|
486
|
+
$[127] = onInitialLayoutViewLayout;
|
|
487
|
+
$[128] = t24;
|
|
488
|
+
$[129] = t25;
|
|
489
|
+
$[130] = t36;
|
|
490
|
+
$[131] = t37;
|
|
491
|
+
} else {
|
|
492
|
+
t37 = $[131];
|
|
493
|
+
}
|
|
494
|
+
let t38;
|
|
495
|
+
if ($[132] !== t37 || $[133] !== textHighlight) {
|
|
496
|
+
t38 = <TextHighlightContext.Provider value={textHighlight}>{t37}</TextHighlightContext.Provider>;
|
|
497
|
+
$[132] = t37;
|
|
498
|
+
$[133] = textHighlight;
|
|
499
|
+
$[134] = t38;
|
|
500
|
+
} else {
|
|
501
|
+
t38 = $[134];
|
|
502
|
+
}
|
|
503
|
+
let t39;
|
|
504
|
+
if ($[135] !== contextValues || $[136] !== t38) {
|
|
505
|
+
t39 = <ChatContext.Provider value={contextValues}>{t38}</ChatContext.Provider>;
|
|
506
|
+
$[135] = contextValues;
|
|
507
|
+
$[136] = t38;
|
|
508
|
+
$[137] = t39;
|
|
459
509
|
} else {
|
|
460
|
-
|
|
510
|
+
t39 = $[137];
|
|
461
511
|
}
|
|
462
|
-
return
|
|
512
|
+
return t39;
|
|
463
513
|
}
|
|
464
514
|
//# sourceMappingURL=Chat.js.map
|