@ethora/chat-component-rn 26.9.0 → 26.10.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.
Files changed (761) hide show
  1. package/CHANGELOG.md +34 -0
  2. package/README.md +19 -0
  3. package/lib/commonjs/assets/icons.js +2 -2
  4. package/lib/commonjs/assets/icons.js.map +1 -1
  5. package/lib/commonjs/components/Header/HeaderRoomList.js +22 -6
  6. package/lib/commonjs/components/Header/HeaderRoomList.js.map +1 -1
  7. package/lib/commonjs/components/InputComponents/Search.js +38 -1
  8. package/lib/commonjs/components/InputComponents/Search.js.map +1 -1
  9. package/lib/commonjs/components/MainComponents/ArchivedMessageCard.js +166 -0
  10. package/lib/commonjs/components/MainComponents/ArchivedMessageCard.js.map +1 -0
  11. package/lib/commonjs/components/MainComponents/ChatHeader.js +22 -5
  12. package/lib/commonjs/components/MainComponents/ChatHeader.js.map +1 -1
  13. package/lib/commonjs/components/MainComponents/ChatRoom.js +56 -25
  14. package/lib/commonjs/components/MainComponents/ChatRoom.js.map +1 -1
  15. package/lib/commonjs/components/MainComponents/ChatWrapper.js +53 -4
  16. package/lib/commonjs/components/MainComponents/ChatWrapper.js.map +1 -1
  17. package/lib/commonjs/components/MainComponents/MediaMessage.js +18 -3
  18. package/lib/commonjs/components/MainComponents/MediaMessage.js.map +1 -1
  19. package/lib/commonjs/components/MainComponents/MessageList.js +739 -42
  20. package/lib/commonjs/components/MainComponents/MessageList.js.map +1 -1
  21. package/lib/commonjs/components/MainComponents/MessageSearchButton.js +58 -0
  22. package/lib/commonjs/components/MainComponents/MessageSearchButton.js.map +1 -0
  23. package/lib/commonjs/components/MainComponents/ReduxWrapper.js +15 -6
  24. package/lib/commonjs/components/MainComponents/ReduxWrapper.js.map +1 -1
  25. package/lib/commonjs/components/MainComponents/RoomList.js +110 -1
  26. package/lib/commonjs/components/MainComponents/RoomList.js.map +1 -1
  27. package/lib/commonjs/components/Menu/HeaderRoomListMenu.js +14 -3
  28. package/lib/commonjs/components/Menu/HeaderRoomListMenu.js.map +1 -1
  29. package/lib/commonjs/components/MessageBubble/BubbleHighlight.js +112 -0
  30. package/lib/commonjs/components/MessageBubble/BubbleHighlight.js.map +1 -0
  31. package/lib/commonjs/components/MessageBubble/Message.js +169 -125
  32. package/lib/commonjs/components/MessageBubble/Message.js.map +1 -1
  33. package/lib/commonjs/components/MessageBubble/MessageInteractions.js +98 -78
  34. package/lib/commonjs/components/MessageBubble/MessageInteractions.js.map +1 -1
  35. package/lib/commonjs/components/MessageBubble/messageMenuLayout.js +50 -0
  36. package/lib/commonjs/components/MessageBubble/messageMenuLayout.js.map +1 -0
  37. package/lib/commonjs/components/Modals/ChatProfileModal/ChatProfileModal.js +73 -37
  38. package/lib/commonjs/components/Modals/ChatProfileModal/ChatProfileModal.js.map +1 -1
  39. package/lib/commonjs/components/Modals/MessageSearchModal/MessageHitResults.js +253 -0
  40. package/lib/commonjs/components/Modals/MessageSearchModal/MessageHitResults.js.map +1 -0
  41. package/lib/commonjs/components/Modals/MessageSearchModal/MessageSearchModal.js +488 -0
  42. package/lib/commonjs/components/Modals/MessageSearchModal/MessageSearchModal.js.map +1 -0
  43. package/lib/commonjs/components/Modals/MessageSearchModal/openHit.js +51 -0
  44. package/lib/commonjs/components/Modals/MessageSearchModal/openHit.js.map +1 -0
  45. package/lib/commonjs/components/Modals/MessageSearchModal/resolveSender.js +47 -0
  46. package/lib/commonjs/components/Modals/MessageSearchModal/resolveSender.js.map +1 -0
  47. package/lib/commonjs/components/Modals/MessageSearchModal/searchFilters.js +83 -0
  48. package/lib/commonjs/components/Modals/MessageSearchModal/searchFilters.js.map +1 -0
  49. package/lib/commonjs/components/Modals/MessageSearchModal/snippet.js +61 -0
  50. package/lib/commonjs/components/Modals/MessageSearchModal/snippet.js.map +1 -0
  51. package/lib/commonjs/components/Modals/MessageSearchModal/useMessageSearch.js +136 -0
  52. package/lib/commonjs/components/Modals/MessageSearchModal/useMessageSearch.js.map +1 -0
  53. package/lib/commonjs/components/Modals/PublicChatsModal/PublicChatsModal.js +306 -0
  54. package/lib/commonjs/components/Modals/PublicChatsModal/PublicChatsModal.js.map +1 -0
  55. package/lib/commonjs/components/Modals/PublicChatsModal/publicChatsLogic.js +36 -0
  56. package/lib/commonjs/components/Modals/PublicChatsModal/publicChatsLogic.js.map +1 -0
  57. package/lib/commonjs/components/Modals/SelectUsersModal/SelectUsersModal.js +8 -1
  58. package/lib/commonjs/components/Modals/SelectUsersModal/SelectUsersModal.js.map +1 -1
  59. package/lib/commonjs/components/RoomComponents/ChatRoomItem.js +13 -2
  60. package/lib/commonjs/components/RoomComponents/ChatRoomItem.js.map +1 -1
  61. package/lib/commonjs/components/RoomComponents/SwipeableRoomRow.js +38 -6
  62. package/lib/commonjs/components/RoomComponents/SwipeableRoomRow.js.map +1 -1
  63. package/lib/commonjs/components/Thread/ThreadHeader.js +3 -1
  64. package/lib/commonjs/components/Thread/ThreadHeader.js.map +1 -1
  65. package/lib/commonjs/components/Thread/ThreadWrapper.js +90 -10
  66. package/lib/commonjs/components/Thread/ThreadWrapper.js.map +1 -1
  67. package/lib/commonjs/components/styled/AudioDecoderHost.js +338 -0
  68. package/lib/commonjs/components/styled/AudioDecoderHost.js.map +1 -0
  69. package/lib/commonjs/components/styled/AudioMessage.js +493 -420
  70. package/lib/commonjs/components/styled/AudioMessage.js.map +1 -1
  71. package/lib/commonjs/components/styled/SendInput.js +31 -5
  72. package/lib/commonjs/components/styled/SendInput.js.map +1 -1
  73. package/lib/commonjs/context/MessageNotificationContext.js +14 -4
  74. package/lib/commonjs/context/MessageNotificationContext.js.map +1 -1
  75. package/lib/commonjs/context/xmppProvider.js +54 -79
  76. package/lib/commonjs/context/xmppProvider.js.map +1 -1
  77. package/lib/commonjs/helpers/audioWaveform.js +165 -0
  78. package/lib/commonjs/helpers/audioWaveform.js.map +1 -0
  79. package/lib/commonjs/helpers/backgroundJoinSweep.js +36 -0
  80. package/lib/commonjs/helpers/backgroundJoinSweep.js.map +1 -0
  81. package/lib/commonjs/helpers/bubbleHighlight.js +44 -0
  82. package/lib/commonjs/helpers/bubbleHighlight.js.map +1 -0
  83. package/lib/commonjs/helpers/checkUniqueUsers.js +14 -12
  84. package/lib/commonjs/helpers/checkUniqueUsers.js.map +1 -1
  85. package/lib/commonjs/helpers/constants/MODAL_COMPONENTS.js +5 -1
  86. package/lib/commonjs/helpers/constants/MODAL_COMPONENTS.js.map +1 -1
  87. package/lib/commonjs/helpers/constants/MODAL_TYPES.js +3 -1
  88. package/lib/commonjs/helpers/constants/MODAL_TYPES.js.map +1 -1
  89. package/lib/commonjs/helpers/createRoomFromApi.js +40 -3
  90. package/lib/commonjs/helpers/createRoomFromApi.js.map +1 -1
  91. package/lib/commonjs/helpers/dedupeMembers.js +34 -0
  92. package/lib/commonjs/helpers/dedupeMembers.js.map +1 -0
  93. package/lib/commonjs/helpers/ethoraLogger.js +56 -0
  94. package/lib/commonjs/helpers/ethoraLogger.js.map +1 -0
  95. package/lib/commonjs/helpers/getUnnamedUsers.js +9 -4
  96. package/lib/commonjs/helpers/getUnnamedUsers.js.map +1 -1
  97. package/lib/commonjs/helpers/historyPreloadConfig.js +44 -0
  98. package/lib/commonjs/helpers/historyPreloadConfig.js.map +1 -0
  99. package/lib/commonjs/helpers/historyPreloadScheduler.js +372 -137
  100. package/lib/commonjs/helpers/historyPreloadScheduler.js.map +1 -1
  101. package/lib/commonjs/helpers/initRoomsPresence.js +17 -5
  102. package/lib/commonjs/helpers/initRoomsPresence.js.map +1 -1
  103. package/lib/commonjs/helpers/insertMessageWithDelimiter.js +5 -0
  104. package/lib/commonjs/helpers/insertMessageWithDelimiter.js.map +1 -1
  105. package/lib/commonjs/helpers/isLikelyMucJid.js +67 -0
  106. package/lib/commonjs/helpers/isLikelyMucJid.js.map +1 -0
  107. package/lib/commonjs/helpers/isMessageSearchEnabled.js +18 -0
  108. package/lib/commonjs/helpers/isMessageSearchEnabled.js.map +1 -0
  109. package/lib/commonjs/helpers/joiningRoom.js +14 -0
  110. package/lib/commonjs/helpers/joiningRoom.js.map +1 -0
  111. package/lib/commonjs/helpers/jumpThread.js +100 -0
  112. package/lib/commonjs/helpers/jumpThread.js.map +1 -0
  113. package/lib/commonjs/helpers/jumpToMessage.js +58 -0
  114. package/lib/commonjs/helpers/jumpToMessage.js.map +1 -0
  115. package/lib/commonjs/helpers/jumpWindow.js +187 -0
  116. package/lib/commonjs/helpers/jumpWindow.js.map +1 -0
  117. package/lib/commonjs/helpers/loadRoomHistory.js +75 -0
  118. package/lib/commonjs/helpers/loadRoomHistory.js.map +1 -0
  119. package/lib/commonjs/helpers/notificationPolicy.js +77 -0
  120. package/lib/commonjs/helpers/notificationPolicy.js.map +1 -0
  121. package/lib/commonjs/helpers/openRoomAtMessage.js +47 -0
  122. package/lib/commonjs/helpers/openRoomAtMessage.js.map +1 -0
  123. package/lib/commonjs/helpers/openThreadForJump.js +72 -0
  124. package/lib/commonjs/helpers/openThreadForJump.js.map +1 -0
  125. package/lib/commonjs/helpers/parseMessageReference.js +27 -8
  126. package/lib/commonjs/helpers/parseMessageReference.js.map +1 -1
  127. package/lib/commonjs/helpers/publicChatsEntry.js +17 -0
  128. package/lib/commonjs/helpers/publicChatsEntry.js.map +1 -0
  129. package/lib/commonjs/helpers/roomActivityScore.js +37 -0
  130. package/lib/commonjs/helpers/roomActivityScore.js.map +1 -0
  131. package/lib/commonjs/helpers/roomUserCount.js +36 -0
  132. package/lib/commonjs/helpers/roomUserCount.js.map +1 -0
  133. package/lib/commonjs/helpers/runConfiguredHistoryPreload.js +68 -0
  134. package/lib/commonjs/helpers/runConfiguredHistoryPreload.js.map +1 -0
  135. package/lib/commonjs/helpers/sessionAppId.js +24 -0
  136. package/lib/commonjs/helpers/sessionAppId.js.map +1 -0
  137. package/lib/commonjs/helpers/timestamp.js +43 -0
  138. package/lib/commonjs/helpers/timestamp.js.map +1 -0
  139. package/lib/commonjs/helpers/userResolver.js +517 -0
  140. package/lib/commonjs/helpers/userResolver.js.map +1 -0
  141. package/lib/commonjs/helpers/xmppIdShape.js +52 -0
  142. package/lib/commonjs/helpers/xmppIdShape.js.map +1 -0
  143. package/lib/commonjs/hooks/useChatWrapperInit.js +27 -5
  144. package/lib/commonjs/hooks/useChatWrapperInit.js.map +1 -1
  145. package/lib/commonjs/hooks/useHeapSender.js +54 -3
  146. package/lib/commonjs/hooks/useHeapSender.js.map +1 -1
  147. package/lib/commonjs/hooks/useJumpToMessage.js +411 -0
  148. package/lib/commonjs/hooks/useJumpToMessage.js.map +1 -0
  149. package/lib/commonjs/hooks/useMessageLoaderQueue.js +32 -5
  150. package/lib/commonjs/hooks/useMessageLoaderQueue.js.map +1 -1
  151. package/lib/commonjs/hooks/useMessageQueue.js +13 -5
  152. package/lib/commonjs/hooks/useMessageQueue.js.map +1 -1
  153. package/lib/commonjs/hooks/useRoomDirectory.js +29 -0
  154. package/lib/commonjs/hooks/useRoomDirectory.js.map +1 -0
  155. package/lib/commonjs/hooks/useRoomInitialization.js +27 -5
  156. package/lib/commonjs/hooks/useRoomInitialization.js.map +1 -1
  157. package/lib/commonjs/hooks/useRoomMute.js +62 -0
  158. package/lib/commonjs/hooks/useRoomMute.js.map +1 -0
  159. package/lib/commonjs/hooks/useRoomState.js +3 -1
  160. package/lib/commonjs/hooks/useRoomState.js.map +1 -1
  161. package/lib/commonjs/hooks/useSendMessage.js +13 -3
  162. package/lib/commonjs/hooks/useSendMessage.js.map +1 -1
  163. package/lib/commonjs/i18n/strings.js +318 -6
  164. package/lib/commonjs/i18n/strings.js.map +1 -1
  165. package/lib/commonjs/networking/api-requests/messageSearch.api.js +87 -0
  166. package/lib/commonjs/networking/api-requests/messageSearch.api.js.map +1 -0
  167. package/lib/commonjs/networking/api-requests/publicChats.api.js +48 -0
  168. package/lib/commonjs/networking/api-requests/publicChats.api.js.map +1 -0
  169. package/lib/commonjs/networking/api-requests/roomMembers.api.js +253 -4
  170. package/lib/commonjs/networking/api-requests/roomMembers.api.js.map +1 -1
  171. package/lib/commonjs/networking/api-requests/rooms.api.js +48 -12
  172. package/lib/commonjs/networking/api-requests/rooms.api.js.map +1 -1
  173. package/lib/commonjs/networking/api-requests/xmppToken.api.js +71 -0
  174. package/lib/commonjs/networking/api-requests/xmppToken.api.js.map +1 -0
  175. package/lib/commonjs/networking/ethoraEvents.js +227 -0
  176. package/lib/commonjs/networking/ethoraEvents.js.map +1 -0
  177. package/lib/commonjs/networking/stanzaHandlers.js +153 -16
  178. package/lib/commonjs/networking/stanzaHandlers.js.map +1 -1
  179. package/lib/commonjs/networking/xmpp/allRoomPresences.xmpp.js +124 -3
  180. package/lib/commonjs/networking/xmpp/allRoomPresences.xmpp.js.map +1 -1
  181. package/lib/commonjs/networking/xmpp/getHistory.xmpp.js +319 -35
  182. package/lib/commonjs/networking/xmpp/getHistory.xmpp.js.map +1 -1
  183. package/lib/commonjs/networking/xmpp/handleStanzas.xmpp.js +7 -0
  184. package/lib/commonjs/networking/xmpp/handleStanzas.xmpp.js.map +1 -1
  185. package/lib/commonjs/networking/xmpp/historyCursor.js +101 -0
  186. package/lib/commonjs/networking/xmpp/historyCursor.js.map +1 -0
  187. package/lib/commonjs/networking/xmpp/mamQueryIds.js +17 -0
  188. package/lib/commonjs/networking/xmpp/mamQueryIds.js.map +1 -0
  189. package/lib/commonjs/networking/xmpp/mamRouter.js +24 -9
  190. package/lib/commonjs/networking/xmpp/mamRouter.js.map +1 -1
  191. package/lib/commonjs/networking/xmpp/presenceInRoom.xmpp.js +70 -65
  192. package/lib/commonjs/networking/xmpp/presenceInRoom.xmpp.js.map +1 -1
  193. package/lib/commonjs/networking/xmpp/roomJoinSweep.js +389 -0
  194. package/lib/commonjs/networking/xmpp/roomJoinSweep.js.map +1 -0
  195. package/lib/commonjs/networking/xmpp/sendMediaMessage.xmpp.js +0 -1
  196. package/lib/commonjs/networking/xmpp/sendMediaMessage.xmpp.js.map +1 -1
  197. package/lib/commonjs/networking/xmpp/sendTextMessage.xmpp.js +0 -1
  198. package/lib/commonjs/networking/xmpp/sendTextMessage.xmpp.js.map +1 -1
  199. package/lib/commonjs/networking/xmpp/sendTextMessageWithTranslateTag.xmpp.js +0 -1
  200. package/lib/commonjs/networking/xmpp/sendTextMessageWithTranslateTag.xmpp.js.map +1 -1
  201. package/lib/commonjs/networking/xmppClient.js +269 -41
  202. package/lib/commonjs/networking/xmppClient.js.map +1 -1
  203. package/lib/commonjs/networking/xmppCredentials.js +80 -0
  204. package/lib/commonjs/networking/xmppCredentials.js.map +1 -0
  205. package/lib/commonjs/roomStore/Middleware/jumpThreadMiddleware.js +158 -0
  206. package/lib/commonjs/roomStore/Middleware/jumpThreadMiddleware.js.map +1 -0
  207. package/lib/commonjs/roomStore/Middleware/reactionsMiddleware.js +6 -0
  208. package/lib/commonjs/roomStore/Middleware/reactionsMiddleware.js.map +1 -1
  209. package/lib/commonjs/roomStore/Middleware/unreadMidlleware.js +45 -7
  210. package/lib/commonjs/roomStore/Middleware/unreadMidlleware.js.map +1 -1
  211. package/lib/commonjs/roomStore/chatSettingsSlice.js +15 -1
  212. package/lib/commonjs/roomStore/chatSettingsSlice.js.map +1 -1
  213. package/lib/commonjs/roomStore/index.js +13 -3
  214. package/lib/commonjs/roomStore/index.js.map +1 -1
  215. package/lib/commonjs/roomStore/persistence.js +48 -1
  216. package/lib/commonjs/roomStore/persistence.js.map +1 -1
  217. package/lib/commonjs/roomStore/roomsSlice.js +474 -60
  218. package/lib/commonjs/roomStore/roomsSlice.js.map +1 -1
  219. package/lib/commonjs/roomStore/safeKey.js +44 -0
  220. package/lib/commonjs/roomStore/safeKey.js.map +1 -0
  221. package/lib/commonjs/roomStore/usersSetCap.js +37 -0
  222. package/lib/commonjs/roomStore/usersSetCap.js.map +1 -0
  223. package/lib/commonjs/version.js +1 -1
  224. package/lib/commonjs/version.js.map +1 -1
  225. package/lib/module/assets/icons.js +1 -1
  226. package/lib/module/assets/icons.js.map +1 -1
  227. package/lib/module/components/Header/HeaderRoomList.js +23 -7
  228. package/lib/module/components/Header/HeaderRoomList.js.map +1 -1
  229. package/lib/module/components/InputComponents/Search.js +39 -2
  230. package/lib/module/components/InputComponents/Search.js.map +1 -1
  231. package/lib/module/components/MainComponents/ArchivedMessageCard.js +161 -0
  232. package/lib/module/components/MainComponents/ArchivedMessageCard.js.map +1 -0
  233. package/lib/module/components/MainComponents/ChatHeader.js +22 -5
  234. package/lib/module/components/MainComponents/ChatHeader.js.map +1 -1
  235. package/lib/module/components/MainComponents/ChatRoom.js +57 -26
  236. package/lib/module/components/MainComponents/ChatRoom.js.map +1 -1
  237. package/lib/module/components/MainComponents/ChatWrapper.js +54 -5
  238. package/lib/module/components/MainComponents/ChatWrapper.js.map +1 -1
  239. package/lib/module/components/MainComponents/MediaMessage.js +18 -3
  240. package/lib/module/components/MainComponents/MediaMessage.js.map +1 -1
  241. package/lib/module/components/MainComponents/MessageList.js +740 -42
  242. package/lib/module/components/MainComponents/MessageList.js.map +1 -1
  243. package/lib/module/components/MainComponents/MessageSearchButton.js +48 -0
  244. package/lib/module/components/MainComponents/MessageSearchButton.js.map +1 -0
  245. package/lib/module/components/MainComponents/ReduxWrapper.js +15 -7
  246. package/lib/module/components/MainComponents/ReduxWrapper.js.map +1 -1
  247. package/lib/module/components/MainComponents/RoomList.js +111 -2
  248. package/lib/module/components/MainComponents/RoomList.js.map +1 -1
  249. package/lib/module/components/Menu/HeaderRoomListMenu.js +15 -4
  250. package/lib/module/components/Menu/HeaderRoomListMenu.js.map +1 -1
  251. package/lib/module/components/MessageBubble/BubbleHighlight.js +106 -0
  252. package/lib/module/components/MessageBubble/BubbleHighlight.js.map +1 -0
  253. package/lib/module/components/MessageBubble/Message.js +172 -127
  254. package/lib/module/components/MessageBubble/Message.js.map +1 -1
  255. package/lib/module/components/MessageBubble/MessageInteractions.js +98 -78
  256. package/lib/module/components/MessageBubble/MessageInteractions.js.map +1 -1
  257. package/lib/module/components/MessageBubble/messageMenuLayout.js +45 -0
  258. package/lib/module/components/MessageBubble/messageMenuLayout.js.map +1 -0
  259. package/lib/module/components/Modals/ChatProfileModal/ChatProfileModal.js +74 -38
  260. package/lib/module/components/Modals/ChatProfileModal/ChatProfileModal.js.map +1 -1
  261. package/lib/module/components/Modals/MessageSearchModal/MessageHitResults.js +243 -0
  262. package/lib/module/components/Modals/MessageSearchModal/MessageHitResults.js.map +1 -0
  263. package/lib/module/components/Modals/MessageSearchModal/MessageSearchModal.js +482 -0
  264. package/lib/module/components/Modals/MessageSearchModal/MessageSearchModal.js.map +1 -0
  265. package/lib/module/components/Modals/MessageSearchModal/openHit.js +45 -0
  266. package/lib/module/components/Modals/MessageSearchModal/openHit.js.map +1 -0
  267. package/lib/module/components/Modals/MessageSearchModal/resolveSender.js +41 -0
  268. package/lib/module/components/Modals/MessageSearchModal/resolveSender.js.map +1 -0
  269. package/lib/module/components/Modals/MessageSearchModal/searchFilters.js +74 -0
  270. package/lib/module/components/Modals/MessageSearchModal/searchFilters.js.map +1 -0
  271. package/lib/module/components/Modals/MessageSearchModal/snippet.js +57 -0
  272. package/lib/module/components/Modals/MessageSearchModal/snippet.js.map +1 -0
  273. package/lib/module/components/Modals/MessageSearchModal/useMessageSearch.js +131 -0
  274. package/lib/module/components/Modals/MessageSearchModal/useMessageSearch.js.map +1 -0
  275. package/lib/module/components/Modals/PublicChatsModal/PublicChatsModal.js +300 -0
  276. package/lib/module/components/Modals/PublicChatsModal/PublicChatsModal.js.map +1 -0
  277. package/lib/module/components/Modals/PublicChatsModal/publicChatsLogic.js +30 -0
  278. package/lib/module/components/Modals/PublicChatsModal/publicChatsLogic.js.map +1 -0
  279. package/lib/module/components/Modals/SelectUsersModal/SelectUsersModal.js +8 -1
  280. package/lib/module/components/Modals/SelectUsersModal/SelectUsersModal.js.map +1 -1
  281. package/lib/module/components/RoomComponents/ChatRoomItem.js +14 -3
  282. package/lib/module/components/RoomComponents/ChatRoomItem.js.map +1 -1
  283. package/lib/module/components/RoomComponents/SwipeableRoomRow.js +39 -7
  284. package/lib/module/components/RoomComponents/SwipeableRoomRow.js.map +1 -1
  285. package/lib/module/components/Thread/ThreadHeader.js +3 -1
  286. package/lib/module/components/Thread/ThreadHeader.js.map +1 -1
  287. package/lib/module/components/Thread/ThreadWrapper.js +89 -9
  288. package/lib/module/components/Thread/ThreadWrapper.js.map +1 -1
  289. package/lib/module/components/styled/AudioDecoderHost.js +332 -0
  290. package/lib/module/components/styled/AudioDecoderHost.js.map +1 -0
  291. package/lib/module/components/styled/AudioMessage.js +495 -422
  292. package/lib/module/components/styled/AudioMessage.js.map +1 -1
  293. package/lib/module/components/styled/SendInput.js +32 -6
  294. package/lib/module/components/styled/SendInput.js.map +1 -1
  295. package/lib/module/context/MessageNotificationContext.js +15 -5
  296. package/lib/module/context/MessageNotificationContext.js.map +1 -1
  297. package/lib/module/context/xmppProvider.js +54 -79
  298. package/lib/module/context/xmppProvider.js.map +1 -1
  299. package/lib/module/helpers/audioWaveform.js +153 -0
  300. package/lib/module/helpers/audioWaveform.js.map +1 -0
  301. package/lib/module/helpers/backgroundJoinSweep.js +30 -0
  302. package/lib/module/helpers/backgroundJoinSweep.js.map +1 -0
  303. package/lib/module/helpers/bubbleHighlight.js +38 -0
  304. package/lib/module/helpers/bubbleHighlight.js.map +1 -0
  305. package/lib/module/helpers/checkUniqueUsers.js +15 -13
  306. package/lib/module/helpers/checkUniqueUsers.js.map +1 -1
  307. package/lib/module/helpers/constants/MODAL_COMPONENTS.js +5 -1
  308. package/lib/module/helpers/constants/MODAL_COMPONENTS.js.map +1 -1
  309. package/lib/module/helpers/constants/MODAL_TYPES.js +3 -1
  310. package/lib/module/helpers/constants/MODAL_TYPES.js.map +1 -1
  311. package/lib/module/helpers/createRoomFromApi.js +37 -3
  312. package/lib/module/helpers/createRoomFromApi.js.map +1 -1
  313. package/lib/module/helpers/dedupeMembers.js +28 -0
  314. package/lib/module/helpers/dedupeMembers.js.map +1 -0
  315. package/lib/module/helpers/ethoraLogger.js +52 -0
  316. package/lib/module/helpers/ethoraLogger.js.map +1 -0
  317. package/lib/module/helpers/getUnnamedUsers.js +9 -4
  318. package/lib/module/helpers/getUnnamedUsers.js.map +1 -1
  319. package/lib/module/helpers/historyPreloadConfig.js +39 -0
  320. package/lib/module/helpers/historyPreloadConfig.js.map +1 -0
  321. package/lib/module/helpers/historyPreloadScheduler.js +368 -134
  322. package/lib/module/helpers/historyPreloadScheduler.js.map +1 -1
  323. package/lib/module/helpers/initRoomsPresence.js +18 -5
  324. package/lib/module/helpers/initRoomsPresence.js.map +1 -1
  325. package/lib/module/helpers/insertMessageWithDelimiter.js +5 -0
  326. package/lib/module/helpers/insertMessageWithDelimiter.js.map +1 -1
  327. package/lib/module/helpers/isLikelyMucJid.js +60 -0
  328. package/lib/module/helpers/isLikelyMucJid.js.map +1 -0
  329. package/lib/module/helpers/isMessageSearchEnabled.js +13 -0
  330. package/lib/module/helpers/isMessageSearchEnabled.js.map +1 -0
  331. package/lib/module/helpers/joiningRoom.js +9 -0
  332. package/lib/module/helpers/joiningRoom.js.map +1 -0
  333. package/lib/module/helpers/jumpThread.js +83 -0
  334. package/lib/module/helpers/jumpThread.js.map +1 -0
  335. package/lib/module/helpers/jumpToMessage.js +52 -0
  336. package/lib/module/helpers/jumpToMessage.js.map +1 -0
  337. package/lib/module/helpers/jumpWindow.js +177 -0
  338. package/lib/module/helpers/jumpWindow.js.map +1 -0
  339. package/lib/module/helpers/loadRoomHistory.js +69 -0
  340. package/lib/module/helpers/loadRoomHistory.js.map +1 -0
  341. package/lib/module/helpers/notificationPolicy.js +70 -0
  342. package/lib/module/helpers/notificationPolicy.js.map +1 -0
  343. package/lib/module/helpers/openRoomAtMessage.js +41 -0
  344. package/lib/module/helpers/openRoomAtMessage.js.map +1 -0
  345. package/lib/module/helpers/openThreadForJump.js +68 -0
  346. package/lib/module/helpers/openThreadForJump.js.map +1 -0
  347. package/lib/module/helpers/parseMessageReference.js +26 -6
  348. package/lib/module/helpers/parseMessageReference.js.map +1 -1
  349. package/lib/module/helpers/publicChatsEntry.js +12 -0
  350. package/lib/module/helpers/publicChatsEntry.js.map +1 -0
  351. package/lib/module/helpers/roomActivityScore.js +30 -0
  352. package/lib/module/helpers/roomActivityScore.js.map +1 -0
  353. package/lib/module/helpers/roomUserCount.js +29 -0
  354. package/lib/module/helpers/roomUserCount.js.map +1 -0
  355. package/lib/module/helpers/runConfiguredHistoryPreload.js +63 -0
  356. package/lib/module/helpers/runConfiguredHistoryPreload.js.map +1 -0
  357. package/lib/module/helpers/sessionAppId.js +20 -0
  358. package/lib/module/helpers/sessionAppId.js.map +1 -0
  359. package/lib/module/helpers/timestamp.js +37 -0
  360. package/lib/module/helpers/timestamp.js.map +1 -0
  361. package/lib/module/helpers/userResolver.js +503 -0
  362. package/lib/module/helpers/userResolver.js.map +1 -0
  363. package/lib/module/helpers/xmppIdShape.js +46 -0
  364. package/lib/module/helpers/xmppIdShape.js.map +1 -0
  365. package/lib/module/hooks/useChatWrapperInit.js +16 -5
  366. package/lib/module/hooks/useChatWrapperInit.js.map +1 -1
  367. package/lib/module/hooks/useHeapSender.js +54 -3
  368. package/lib/module/hooks/useHeapSender.js.map +1 -1
  369. package/lib/module/hooks/useJumpToMessage.js +389 -0
  370. package/lib/module/hooks/useJumpToMessage.js.map +1 -0
  371. package/lib/module/hooks/useMessageLoaderQueue.js +32 -5
  372. package/lib/module/hooks/useMessageLoaderQueue.js.map +1 -1
  373. package/lib/module/hooks/useMessageQueue.js +13 -5
  374. package/lib/module/hooks/useMessageQueue.js.map +1 -1
  375. package/lib/module/hooks/useRoomDirectory.js +24 -0
  376. package/lib/module/hooks/useRoomDirectory.js.map +1 -0
  377. package/lib/module/hooks/useRoomInitialization.js +29 -7
  378. package/lib/module/hooks/useRoomInitialization.js.map +1 -1
  379. package/lib/module/hooks/useRoomMute.js +58 -0
  380. package/lib/module/hooks/useRoomMute.js.map +1 -0
  381. package/lib/module/hooks/useRoomState.js +3 -1
  382. package/lib/module/hooks/useRoomState.js.map +1 -1
  383. package/lib/module/hooks/useSendMessage.js +13 -3
  384. package/lib/module/hooks/useSendMessage.js.map +1 -1
  385. package/lib/module/i18n/strings.js +318 -6
  386. package/lib/module/i18n/strings.js.map +1 -1
  387. package/lib/module/networking/api-requests/messageSearch.api.js +81 -0
  388. package/lib/module/networking/api-requests/messageSearch.api.js.map +1 -0
  389. package/lib/module/networking/api-requests/publicChats.api.js +43 -0
  390. package/lib/module/networking/api-requests/publicChats.api.js.map +1 -0
  391. package/lib/module/networking/api-requests/roomMembers.api.js +248 -4
  392. package/lib/module/networking/api-requests/roomMembers.api.js.map +1 -1
  393. package/lib/module/networking/api-requests/rooms.api.js +48 -12
  394. package/lib/module/networking/api-requests/rooms.api.js.map +1 -1
  395. package/lib/module/networking/api-requests/xmppToken.api.js +66 -0
  396. package/lib/module/networking/api-requests/xmppToken.api.js.map +1 -0
  397. package/lib/module/networking/ethoraEvents.js +220 -0
  398. package/lib/module/networking/ethoraEvents.js.map +1 -0
  399. package/lib/module/networking/stanzaHandlers.js +155 -18
  400. package/lib/module/networking/stanzaHandlers.js.map +1 -1
  401. package/lib/module/networking/xmpp/allRoomPresences.xmpp.js +125 -3
  402. package/lib/module/networking/xmpp/allRoomPresences.xmpp.js.map +1 -1
  403. package/lib/module/networking/xmpp/getHistory.xmpp.js +318 -35
  404. package/lib/module/networking/xmpp/getHistory.xmpp.js.map +1 -1
  405. package/lib/module/networking/xmpp/handleStanzas.xmpp.js +7 -0
  406. package/lib/module/networking/xmpp/handleStanzas.xmpp.js.map +1 -1
  407. package/lib/module/networking/xmpp/historyCursor.js +95 -0
  408. package/lib/module/networking/xmpp/historyCursor.js.map +1 -0
  409. package/lib/module/networking/xmpp/mamQueryIds.js +12 -0
  410. package/lib/module/networking/xmpp/mamQueryIds.js.map +1 -0
  411. package/lib/module/networking/xmpp/mamRouter.js +22 -8
  412. package/lib/module/networking/xmpp/mamRouter.js.map +1 -1
  413. package/lib/module/networking/xmpp/presenceInRoom.xmpp.js +68 -62
  414. package/lib/module/networking/xmpp/presenceInRoom.xmpp.js.map +1 -1
  415. package/lib/module/networking/xmpp/roomJoinSweep.js +385 -0
  416. package/lib/module/networking/xmpp/roomJoinSweep.js.map +1 -0
  417. package/lib/module/networking/xmpp/sendMediaMessage.xmpp.js +0 -1
  418. package/lib/module/networking/xmpp/sendMediaMessage.xmpp.js.map +1 -1
  419. package/lib/module/networking/xmpp/sendTextMessage.xmpp.js +0 -1
  420. package/lib/module/networking/xmpp/sendTextMessage.xmpp.js.map +1 -1
  421. package/lib/module/networking/xmpp/sendTextMessageWithTranslateTag.xmpp.js +0 -1
  422. package/lib/module/networking/xmpp/sendTextMessageWithTranslateTag.xmpp.js.map +1 -1
  423. package/lib/module/networking/xmppClient.js +269 -41
  424. package/lib/module/networking/xmppClient.js.map +1 -1
  425. package/lib/module/networking/xmppCredentials.js +76 -0
  426. package/lib/module/networking/xmppCredentials.js.map +1 -0
  427. package/lib/module/roomStore/Middleware/jumpThreadMiddleware.js +153 -0
  428. package/lib/module/roomStore/Middleware/jumpThreadMiddleware.js.map +1 -0
  429. package/lib/module/roomStore/Middleware/reactionsMiddleware.js +6 -0
  430. package/lib/module/roomStore/Middleware/reactionsMiddleware.js.map +1 -1
  431. package/lib/module/roomStore/Middleware/unreadMidlleware.js +46 -7
  432. package/lib/module/roomStore/Middleware/unreadMidlleware.js.map +1 -1
  433. package/lib/module/roomStore/chatSettingsSlice.js +13 -0
  434. package/lib/module/roomStore/chatSettingsSlice.js.map +1 -1
  435. package/lib/module/roomStore/index.js +7 -3
  436. package/lib/module/roomStore/index.js.map +1 -1
  437. package/lib/module/roomStore/persistence.js +46 -1
  438. package/lib/module/roomStore/persistence.js.map +1 -1
  439. package/lib/module/roomStore/roomsSlice.js +459 -58
  440. package/lib/module/roomStore/roomsSlice.js.map +1 -1
  441. package/lib/module/roomStore/safeKey.js +37 -0
  442. package/lib/module/roomStore/safeKey.js.map +1 -0
  443. package/lib/module/roomStore/usersSetCap.js +32 -0
  444. package/lib/module/roomStore/usersSetCap.js.map +1 -0
  445. package/lib/module/version.js +1 -1
  446. package/lib/module/version.js.map +1 -1
  447. package/lib/typescript/assets/icons.d.ts +4 -0
  448. package/lib/typescript/assets/icons.d.ts.map +1 -1
  449. package/lib/typescript/components/Header/HeaderRoomList.d.ts.map +1 -1
  450. package/lib/typescript/components/InputComponents/Search.d.ts.map +1 -1
  451. package/lib/typescript/components/MainComponents/ArchivedMessageCard.d.ts +12 -0
  452. package/lib/typescript/components/MainComponents/ArchivedMessageCard.d.ts.map +1 -0
  453. package/lib/typescript/components/MainComponents/ChatHeader.d.ts.map +1 -1
  454. package/lib/typescript/components/MainComponents/ChatRoom.d.ts.map +1 -1
  455. package/lib/typescript/components/MainComponents/ChatWrapper.d.ts.map +1 -1
  456. package/lib/typescript/components/MainComponents/MediaMessage.d.ts.map +1 -1
  457. package/lib/typescript/components/MainComponents/MessageList.d.ts +22 -1
  458. package/lib/typescript/components/MainComponents/MessageList.d.ts.map +1 -1
  459. package/lib/typescript/components/MainComponents/MessageSearchButton.d.ts +7 -0
  460. package/lib/typescript/components/MainComponents/MessageSearchButton.d.ts.map +1 -0
  461. package/lib/typescript/components/MainComponents/ReduxWrapper.d.ts.map +1 -1
  462. package/lib/typescript/components/MainComponents/RoomList.d.ts.map +1 -1
  463. package/lib/typescript/components/Menu/HeaderRoomListMenu.d.ts.map +1 -1
  464. package/lib/typescript/components/MessageBubble/BubbleHighlight.d.ts +12 -0
  465. package/lib/typescript/components/MessageBubble/BubbleHighlight.d.ts.map +1 -0
  466. package/lib/typescript/components/MessageBubble/Message.d.ts.map +1 -1
  467. package/lib/typescript/components/MessageBubble/MessageInteractions.d.ts +5 -0
  468. package/lib/typescript/components/MessageBubble/MessageInteractions.d.ts.map +1 -1
  469. package/lib/typescript/components/MessageBubble/messageMenuLayout.d.ts +29 -0
  470. package/lib/typescript/components/MessageBubble/messageMenuLayout.d.ts.map +1 -0
  471. package/lib/typescript/components/Modals/ChatProfileModal/ChatProfileModal.d.ts +2 -0
  472. package/lib/typescript/components/Modals/ChatProfileModal/ChatProfileModal.d.ts.map +1 -1
  473. package/lib/typescript/components/Modals/MessageSearchModal/MessageHitResults.d.ts +44 -0
  474. package/lib/typescript/components/Modals/MessageSearchModal/MessageHitResults.d.ts.map +1 -0
  475. package/lib/typescript/components/Modals/MessageSearchModal/MessageSearchModal.d.ts +12 -0
  476. package/lib/typescript/components/Modals/MessageSearchModal/MessageSearchModal.d.ts.map +1 -0
  477. package/lib/typescript/components/Modals/MessageSearchModal/openHit.d.ts +15 -0
  478. package/lib/typescript/components/Modals/MessageSearchModal/openHit.d.ts.map +1 -0
  479. package/lib/typescript/components/Modals/MessageSearchModal/resolveSender.d.ts +34 -0
  480. package/lib/typescript/components/Modals/MessageSearchModal/resolveSender.d.ts.map +1 -0
  481. package/lib/typescript/components/Modals/MessageSearchModal/searchFilters.d.ts +41 -0
  482. package/lib/typescript/components/Modals/MessageSearchModal/searchFilters.d.ts.map +1 -0
  483. package/lib/typescript/components/Modals/MessageSearchModal/snippet.d.ts +15 -0
  484. package/lib/typescript/components/Modals/MessageSearchModal/snippet.d.ts.map +1 -0
  485. package/lib/typescript/components/Modals/MessageSearchModal/useMessageSearch.d.ts +23 -0
  486. package/lib/typescript/components/Modals/MessageSearchModal/useMessageSearch.d.ts.map +1 -0
  487. package/lib/typescript/components/Modals/PublicChatsModal/PublicChatsModal.d.ts +16 -0
  488. package/lib/typescript/components/Modals/PublicChatsModal/PublicChatsModal.d.ts.map +1 -0
  489. package/lib/typescript/components/Modals/PublicChatsModal/publicChatsLogic.d.ts +14 -0
  490. package/lib/typescript/components/Modals/PublicChatsModal/publicChatsLogic.d.ts.map +1 -0
  491. package/lib/typescript/components/Modals/SelectUsersModal/SelectUsersModal.d.ts.map +1 -1
  492. package/lib/typescript/components/RoomComponents/ChatRoomItem.d.ts.map +1 -1
  493. package/lib/typescript/components/RoomComponents/SwipeableRoomRow.d.ts +5 -1
  494. package/lib/typescript/components/RoomComponents/SwipeableRoomRow.d.ts.map +1 -1
  495. package/lib/typescript/components/Thread/ThreadHeader.d.ts.map +1 -1
  496. package/lib/typescript/components/Thread/ThreadWrapper.d.ts +1 -0
  497. package/lib/typescript/components/Thread/ThreadWrapper.d.ts.map +1 -1
  498. package/lib/typescript/components/styled/AudioDecoderHost.d.ts +39 -0
  499. package/lib/typescript/components/styled/AudioDecoderHost.d.ts.map +1 -0
  500. package/lib/typescript/components/styled/AudioMessage.d.ts +14 -1
  501. package/lib/typescript/components/styled/AudioMessage.d.ts.map +1 -1
  502. package/lib/typescript/components/styled/SendInput.d.ts.map +1 -1
  503. package/lib/typescript/context/MessageNotificationContext.d.ts.map +1 -1
  504. package/lib/typescript/context/xmppProvider.d.ts +2 -0
  505. package/lib/typescript/context/xmppProvider.d.ts.map +1 -1
  506. package/lib/typescript/helpers/audioWaveform.d.ts +54 -0
  507. package/lib/typescript/helpers/audioWaveform.d.ts.map +1 -0
  508. package/lib/typescript/helpers/backgroundJoinSweep.d.ts +14 -0
  509. package/lib/typescript/helpers/backgroundJoinSweep.d.ts.map +1 -0
  510. package/lib/typescript/helpers/bubbleHighlight.d.ts +17 -0
  511. package/lib/typescript/helpers/bubbleHighlight.d.ts.map +1 -0
  512. package/lib/typescript/helpers/checkUniqueUsers.d.ts +2 -2
  513. package/lib/typescript/helpers/checkUniqueUsers.d.ts.map +1 -1
  514. package/lib/typescript/helpers/constants/MODAL_COMPONENTS.d.ts.map +1 -1
  515. package/lib/typescript/helpers/constants/MODAL_TYPES.d.ts +2 -0
  516. package/lib/typescript/helpers/constants/MODAL_TYPES.d.ts.map +1 -1
  517. package/lib/typescript/helpers/createRoomFromApi.d.ts +25 -0
  518. package/lib/typescript/helpers/createRoomFromApi.d.ts.map +1 -1
  519. package/lib/typescript/helpers/dedupeMembers.d.ts +11 -0
  520. package/lib/typescript/helpers/dedupeMembers.d.ts.map +1 -0
  521. package/lib/typescript/helpers/ethoraLogger.d.ts +13 -0
  522. package/lib/typescript/helpers/ethoraLogger.d.ts.map +1 -0
  523. package/lib/typescript/helpers/getUnnamedUsers.d.ts.map +1 -1
  524. package/lib/typescript/helpers/historyPreloadConfig.d.ts +26 -0
  525. package/lib/typescript/helpers/historyPreloadConfig.d.ts.map +1 -0
  526. package/lib/typescript/helpers/historyPreloadScheduler.d.ts +8 -4
  527. package/lib/typescript/helpers/historyPreloadScheduler.d.ts.map +1 -1
  528. package/lib/typescript/helpers/initRoomsPresence.d.ts +7 -0
  529. package/lib/typescript/helpers/initRoomsPresence.d.ts.map +1 -1
  530. package/lib/typescript/helpers/insertMessageWithDelimiter.d.ts.map +1 -1
  531. package/lib/typescript/helpers/isLikelyMucJid.d.ts +19 -0
  532. package/lib/typescript/helpers/isLikelyMucJid.d.ts.map +1 -0
  533. package/lib/typescript/helpers/isMessageSearchEnabled.d.ts +12 -0
  534. package/lib/typescript/helpers/isMessageSearchEnabled.d.ts.map +1 -0
  535. package/lib/typescript/helpers/joiningRoom.d.ts +7 -0
  536. package/lib/typescript/helpers/joiningRoom.d.ts.map +1 -0
  537. package/lib/typescript/helpers/jumpThread.d.ts +48 -0
  538. package/lib/typescript/helpers/jumpThread.d.ts.map +1 -0
  539. package/lib/typescript/helpers/jumpToMessage.d.ts +26 -0
  540. package/lib/typescript/helpers/jumpToMessage.d.ts.map +1 -0
  541. package/lib/typescript/helpers/jumpWindow.d.ts +74 -0
  542. package/lib/typescript/helpers/jumpWindow.d.ts.map +1 -0
  543. package/lib/typescript/helpers/loadRoomHistory.d.ts +34 -0
  544. package/lib/typescript/helpers/loadRoomHistory.d.ts.map +1 -0
  545. package/lib/typescript/helpers/notificationPolicy.d.ts +42 -0
  546. package/lib/typescript/helpers/notificationPolicy.d.ts.map +1 -0
  547. package/lib/typescript/helpers/openRoomAtMessage.d.ts +17 -0
  548. package/lib/typescript/helpers/openRoomAtMessage.d.ts.map +1 -0
  549. package/lib/typescript/helpers/openThreadForJump.d.ts +27 -0
  550. package/lib/typescript/helpers/openThreadForJump.d.ts.map +1 -0
  551. package/lib/typescript/helpers/parseMessageReference.d.ts +18 -5
  552. package/lib/typescript/helpers/parseMessageReference.d.ts.map +1 -1
  553. package/lib/typescript/helpers/publicChatsEntry.d.ts +11 -0
  554. package/lib/typescript/helpers/publicChatsEntry.d.ts.map +1 -0
  555. package/lib/typescript/helpers/roomActivityScore.d.ts +5 -0
  556. package/lib/typescript/helpers/roomActivityScore.d.ts.map +1 -0
  557. package/lib/typescript/helpers/roomUserCount.d.ts +20 -0
  558. package/lib/typescript/helpers/roomUserCount.d.ts.map +1 -0
  559. package/lib/typescript/helpers/runConfiguredHistoryPreload.d.ts +21 -0
  560. package/lib/typescript/helpers/runConfiguredHistoryPreload.d.ts.map +1 -0
  561. package/lib/typescript/helpers/sessionAppId.d.ts +8 -0
  562. package/lib/typescript/helpers/sessionAppId.d.ts.map +1 -0
  563. package/lib/typescript/helpers/timestamp.d.ts +3 -0
  564. package/lib/typescript/helpers/timestamp.d.ts.map +1 -0
  565. package/lib/typescript/helpers/userResolver.d.ts +58 -0
  566. package/lib/typescript/helpers/userResolver.d.ts.map +1 -0
  567. package/lib/typescript/helpers/xmppIdShape.d.ts +10 -0
  568. package/lib/typescript/helpers/xmppIdShape.d.ts.map +1 -0
  569. package/lib/typescript/hooks/useChatWrapperInit.d.ts +2 -0
  570. package/lib/typescript/hooks/useChatWrapperInit.d.ts.map +1 -1
  571. package/lib/typescript/hooks/useHeapSender.d.ts.map +1 -1
  572. package/lib/typescript/hooks/useJumpToMessage.d.ts +116 -0
  573. package/lib/typescript/hooks/useJumpToMessage.d.ts.map +1 -0
  574. package/lib/typescript/hooks/useMessageLoaderQueue.d.ts.map +1 -1
  575. package/lib/typescript/hooks/useMessageQueue.d.ts.map +1 -1
  576. package/lib/typescript/hooks/useRoomDirectory.d.ts +12 -0
  577. package/lib/typescript/hooks/useRoomDirectory.d.ts.map +1 -0
  578. package/lib/typescript/hooks/useRoomInitialization.d.ts.map +1 -1
  579. package/lib/typescript/hooks/useRoomMute.d.ts +8 -0
  580. package/lib/typescript/hooks/useRoomMute.d.ts.map +1 -0
  581. package/lib/typescript/hooks/useRoomState.d.ts +1 -0
  582. package/lib/typescript/hooks/useRoomState.d.ts.map +1 -1
  583. package/lib/typescript/hooks/useSendMessage.d.ts.map +1 -1
  584. package/lib/typescript/i18n/strings.d.ts.map +1 -1
  585. package/lib/typescript/networking/api-requests/messageSearch.api.d.ts +57 -0
  586. package/lib/typescript/networking/api-requests/messageSearch.api.d.ts.map +1 -0
  587. package/lib/typescript/networking/api-requests/publicChats.api.d.ts +24 -0
  588. package/lib/typescript/networking/api-requests/publicChats.api.d.ts.map +1 -0
  589. package/lib/typescript/networking/api-requests/roomMembers.api.d.ts +19 -1
  590. package/lib/typescript/networking/api-requests/roomMembers.api.d.ts.map +1 -1
  591. package/lib/typescript/networking/api-requests/rooms.api.d.ts.map +1 -1
  592. package/lib/typescript/networking/api-requests/xmppToken.api.d.ts +2 -0
  593. package/lib/typescript/networking/api-requests/xmppToken.api.d.ts.map +1 -0
  594. package/lib/typescript/networking/ethoraEvents.d.ts +45 -0
  595. package/lib/typescript/networking/ethoraEvents.d.ts.map +1 -0
  596. package/lib/typescript/networking/stanzaHandlers.d.ts +1 -1
  597. package/lib/typescript/networking/stanzaHandlers.d.ts.map +1 -1
  598. package/lib/typescript/networking/xmpp/allRoomPresences.xmpp.d.ts +32 -1
  599. package/lib/typescript/networking/xmpp/allRoomPresences.xmpp.d.ts.map +1 -1
  600. package/lib/typescript/networking/xmpp/getHistory.xmpp.d.ts +64 -0
  601. package/lib/typescript/networking/xmpp/getHistory.xmpp.d.ts.map +1 -1
  602. package/lib/typescript/networking/xmpp/handleStanzas.xmpp.d.ts.map +1 -1
  603. package/lib/typescript/networking/xmpp/historyCursor.d.ts +35 -0
  604. package/lib/typescript/networking/xmpp/historyCursor.d.ts.map +1 -0
  605. package/lib/typescript/networking/xmpp/mamQueryIds.d.ts +10 -0
  606. package/lib/typescript/networking/xmpp/mamQueryIds.d.ts.map +1 -0
  607. package/lib/typescript/networking/xmpp/mamRouter.d.ts +7 -0
  608. package/lib/typescript/networking/xmpp/mamRouter.d.ts.map +1 -1
  609. package/lib/typescript/networking/xmpp/presenceInRoom.xmpp.d.ts +13 -2
  610. package/lib/typescript/networking/xmpp/presenceInRoom.xmpp.d.ts.map +1 -1
  611. package/lib/typescript/networking/xmpp/roomJoinSweep.d.ts +82 -0
  612. package/lib/typescript/networking/xmpp/roomJoinSweep.d.ts.map +1 -0
  613. package/lib/typescript/networking/xmpp/sendMediaMessage.xmpp.d.ts.map +1 -1
  614. package/lib/typescript/networking/xmpp/sendTextMessage.xmpp.d.ts.map +1 -1
  615. package/lib/typescript/networking/xmpp/sendTextMessageWithTranslateTag.xmpp.d.ts.map +1 -1
  616. package/lib/typescript/networking/xmppClient.d.ts +90 -4
  617. package/lib/typescript/networking/xmppClient.d.ts.map +1 -1
  618. package/lib/typescript/networking/xmppCredentials.d.ts +12 -0
  619. package/lib/typescript/networking/xmppCredentials.d.ts.map +1 -0
  620. package/lib/typescript/roomStore/Middleware/jumpThreadMiddleware.d.ts +3 -0
  621. package/lib/typescript/roomStore/Middleware/jumpThreadMiddleware.d.ts.map +1 -0
  622. package/lib/typescript/roomStore/Middleware/reactionsMiddleware.d.ts.map +1 -1
  623. package/lib/typescript/roomStore/Middleware/unreadMidlleware.d.ts.map +1 -1
  624. package/lib/typescript/roomStore/chatSettingsSlice.d.ts +8 -1
  625. package/lib/typescript/roomStore/chatSettingsSlice.d.ts.map +1 -1
  626. package/lib/typescript/roomStore/index.d.ts +2 -1
  627. package/lib/typescript/roomStore/index.d.ts.map +1 -1
  628. package/lib/typescript/roomStore/persistence.d.ts +8 -0
  629. package/lib/typescript/roomStore/persistence.d.ts.map +1 -1
  630. package/lib/typescript/roomStore/roomsSlice.d.ts +138 -2
  631. package/lib/typescript/roomStore/roomsSlice.d.ts.map +1 -1
  632. package/lib/typescript/roomStore/safeKey.d.ts +13 -0
  633. package/lib/typescript/roomStore/safeKey.d.ts.map +1 -0
  634. package/lib/typescript/roomStore/usersSetCap.d.ts +16 -0
  635. package/lib/typescript/roomStore/usersSetCap.d.ts.map +1 -0
  636. package/lib/typescript/types/models/media.model.d.ts +2 -0
  637. package/lib/typescript/types/models/media.model.d.ts.map +1 -1
  638. package/lib/typescript/types/models/room.model.d.ts +18 -5
  639. package/lib/typescript/types/models/room.model.d.ts.map +1 -1
  640. package/lib/typescript/types/models/xmpp.model.d.ts +8 -1
  641. package/lib/typescript/types/models/xmpp.model.d.ts.map +1 -1
  642. package/lib/typescript/types/types.d.ts +90 -5
  643. package/lib/typescript/types/types.d.ts.map +1 -1
  644. package/lib/typescript/version.d.ts +1 -1
  645. package/lib/typescript/version.d.ts.map +1 -1
  646. package/package.json +1 -1
  647. package/src/assets/icons.tsx +13 -0
  648. package/src/components/Header/HeaderRoomList.tsx +21 -4
  649. package/src/components/InputComponents/Search.tsx +33 -0
  650. package/src/components/MainComponents/ArchivedMessageCard.tsx +139 -0
  651. package/src/components/MainComponents/ChatHeader.tsx +19 -3
  652. package/src/components/MainComponents/ChatRoom.tsx +60 -23
  653. package/src/components/MainComponents/ChatWrapper.tsx +50 -9
  654. package/src/components/MainComponents/MediaMessage.tsx +17 -0
  655. package/src/components/MainComponents/MessageList.tsx +823 -84
  656. package/src/components/MainComponents/MessageSearchButton.tsx +48 -0
  657. package/src/components/MainComponents/ReduxWrapper.tsx +16 -5
  658. package/src/components/MainComponents/RoomList.tsx +125 -0
  659. package/src/components/Menu/HeaderRoomListMenu.tsx +26 -2
  660. package/src/components/MessageBubble/BubbleHighlight.tsx +106 -0
  661. package/src/components/MessageBubble/Message.tsx +265 -177
  662. package/src/components/MessageBubble/MessageInteractions.tsx +109 -86
  663. package/src/components/MessageBubble/messageMenuLayout.ts +59 -0
  664. package/src/components/Modals/ChatProfileModal/ChatProfileModal.tsx +92 -21
  665. package/src/components/Modals/MessageSearchModal/MessageHitResults.tsx +271 -0
  666. package/src/components/Modals/MessageSearchModal/MessageSearchModal.tsx +487 -0
  667. package/src/components/Modals/MessageSearchModal/openHit.ts +50 -0
  668. package/src/components/Modals/MessageSearchModal/resolveSender.ts +57 -0
  669. package/src/components/Modals/MessageSearchModal/searchFilters.ts +109 -0
  670. package/src/components/Modals/MessageSearchModal/snippet.ts +58 -0
  671. package/src/components/Modals/MessageSearchModal/useMessageSearch.ts +151 -0
  672. package/src/components/Modals/PublicChatsModal/PublicChatsModal.tsx +288 -0
  673. package/src/components/Modals/PublicChatsModal/publicChatsLogic.ts +36 -0
  674. package/src/components/Modals/SelectUsersModal/SelectUsersModal.tsx +8 -1
  675. package/src/components/RoomComponents/ChatRoomItem.tsx +16 -3
  676. package/src/components/RoomComponents/SwipeableRoomRow.tsx +39 -6
  677. package/src/components/Thread/ThreadHeader.tsx +3 -1
  678. package/src/components/Thread/ThreadWrapper.tsx +96 -10
  679. package/src/components/styled/AudioDecoderHost.tsx +351 -0
  680. package/src/components/styled/AudioMessage.tsx +482 -425
  681. package/src/components/styled/SendInput.tsx +42 -4
  682. package/src/context/MessageNotificationContext.tsx +19 -5
  683. package/src/context/xmppProvider.tsx +56 -91
  684. package/src/helpers/audioWaveform.ts +142 -0
  685. package/src/helpers/backgroundJoinSweep.ts +35 -0
  686. package/src/helpers/bubbleHighlight.ts +47 -0
  687. package/src/helpers/checkUniqueUsers.tsx +15 -17
  688. package/src/helpers/constants/MODAL_COMPONENTS.tsx +4 -0
  689. package/src/helpers/constants/MODAL_TYPES.ts +3 -0
  690. package/src/helpers/createRoomFromApi.tsx +45 -4
  691. package/src/helpers/dedupeMembers.ts +29 -0
  692. package/src/helpers/ethoraLogger.ts +50 -0
  693. package/src/helpers/getUnnamedUsers.ts +7 -4
  694. package/src/helpers/historyPreloadConfig.ts +68 -0
  695. package/src/helpers/historyPreloadScheduler.ts +437 -199
  696. package/src/helpers/initRoomsPresence.ts +20 -7
  697. package/src/helpers/insertMessageWithDelimiter.ts +3 -0
  698. package/src/helpers/isLikelyMucJid.ts +72 -0
  699. package/src/helpers/isMessageSearchEnabled.ts +18 -0
  700. package/src/helpers/joiningRoom.ts +13 -0
  701. package/src/helpers/jumpThread.ts +102 -0
  702. package/src/helpers/jumpToMessage.ts +57 -0
  703. package/src/helpers/jumpWindow.ts +212 -0
  704. package/src/helpers/loadRoomHistory.ts +83 -0
  705. package/src/helpers/notificationPolicy.ts +82 -0
  706. package/src/helpers/openRoomAtMessage.ts +38 -0
  707. package/src/helpers/openThreadForJump.ts +96 -0
  708. package/src/helpers/parseMessageReference.ts +37 -8
  709. package/src/helpers/publicChatsEntry.ts +15 -0
  710. package/src/helpers/roomActivityScore.ts +45 -0
  711. package/src/helpers/roomUserCount.ts +44 -0
  712. package/src/helpers/runConfiguredHistoryPreload.ts +76 -0
  713. package/src/helpers/sessionAppId.ts +17 -0
  714. package/src/helpers/timestamp.ts +44 -0
  715. package/src/helpers/userResolver.ts +542 -0
  716. package/src/helpers/xmppIdShape.ts +46 -0
  717. package/src/hooks/useChatWrapperInit.ts +22 -4
  718. package/src/hooks/useHeapSender.tsx +54 -3
  719. package/src/hooks/useJumpToMessage.ts +538 -0
  720. package/src/hooks/useMessageLoaderQueue.tsx +40 -4
  721. package/src/hooks/useMessageQueue.ts +9 -5
  722. package/src/hooks/useRoomDirectory.ts +39 -0
  723. package/src/hooks/useRoomInitialization.tsx +33 -7
  724. package/src/hooks/useRoomMute.ts +42 -0
  725. package/src/hooks/useRoomState.tsx +6 -0
  726. package/src/hooks/useSendMessage.tsx +14 -2
  727. package/src/i18n/strings.ts +312 -0
  728. package/src/networking/api-requests/messageSearch.api.ts +130 -0
  729. package/src/networking/api-requests/publicChats.api.ts +71 -0
  730. package/src/networking/api-requests/roomMembers.api.ts +263 -11
  731. package/src/networking/api-requests/rooms.api.ts +52 -12
  732. package/src/networking/api-requests/xmppToken.api.ts +62 -0
  733. package/src/networking/ethoraEvents.ts +262 -0
  734. package/src/networking/stanzaHandlers.ts +145 -19
  735. package/src/networking/xmpp/allRoomPresences.xmpp.ts +155 -5
  736. package/src/networking/xmpp/getHistory.xmpp.ts +433 -47
  737. package/src/networking/xmpp/handleStanzas.xmpp.ts +8 -0
  738. package/src/networking/xmpp/historyCursor.ts +124 -0
  739. package/src/networking/xmpp/mamQueryIds.ts +11 -0
  740. package/src/networking/xmpp/mamRouter.ts +24 -10
  741. package/src/networking/xmpp/presenceInRoom.xmpp.ts +91 -68
  742. package/src/networking/xmpp/roomJoinSweep.ts +412 -0
  743. package/src/networking/xmpp/sendMediaMessage.xmpp.ts +0 -1
  744. package/src/networking/xmpp/sendTextMessage.xmpp.ts +0 -1
  745. package/src/networking/xmpp/sendTextMessageWithTranslateTag.xmpp.ts +0 -1
  746. package/src/networking/xmppClient.ts +323 -47
  747. package/src/networking/xmppCredentials.ts +87 -0
  748. package/src/roomStore/Middleware/jumpThreadMiddleware.ts +163 -0
  749. package/src/roomStore/Middleware/reactionsMiddleware.tsx +4 -0
  750. package/src/roomStore/Middleware/unreadMidlleware.tsx +59 -11
  751. package/src/roomStore/chatSettingsSlice.ts +11 -0
  752. package/src/roomStore/index.ts +10 -3
  753. package/src/roomStore/persistence.ts +54 -0
  754. package/src/roomStore/roomsSlice.ts +547 -65
  755. package/src/roomStore/safeKey.ts +49 -0
  756. package/src/roomStore/usersSetCap.ts +37 -0
  757. package/src/types/models/media.model.ts +4 -0
  758. package/src/types/models/room.model.ts +18 -5
  759. package/src/types/models/xmpp.model.ts +15 -1
  760. package/src/types/types.ts +95 -5
  761. package/src/version.ts +1 -1
@@ -1 +1 @@
1
- {"version":3,"names":["React","useCallback","useEffect","useMemo","useRef","useState","Alert","Animated","Text","TouchableOpacity","TouchableWithoutFeedback","StyleSheet","Dimensions","Modal","PanResponder","Platform","View","AddNewIcon","LogoutIcon","ProfileIcon","SettingIcon","useDispatch","useSafeAreaInsets","setActiveModal","MODAL_TYPES","useChatSettingState","useLogout","useTheme","shouldClaimVerticalDrag","shouldDismissOnDrag","useT","jsx","_jsx","jsxs","_jsxs","DEFAULT_LOGOUT_STRINGS","label","message","cancel","confirmLogout","confirm","strings","Promise","resolve","copy","alert","title","text","cancelText","style","onPress","confirmText","cancelable","onDismiss","runLogoutFlow","logoutConfig","performLogout","confirmed","onBeforeLogout","proceed","e","console","warn","onAfterLogout","height","windowHeight","get","HeaderRoomListMenu","isDrawerOpen","drawerAnimation","overlayAnimation","closeDrawer","dispatch","config","t","logout","enabled","undefined","logoutStrings","theme","primaryColor","primary","iconColor","icon","labelColor","insets","sheetHeight","setSheetHeight","dragY","Value","current","sheetHeightRef","closeDrawerRef","pendingActionRef","runPendingAction","action","OS","id","setTimeout","clearTimeout","handleOptionPress","setValue","timing","toValue","duration","useNativeDriver","start","openTranslateY","interpolate","inputRange","outputRange","dismissByDrag","makeDragResponder","claimOnStart","create","onStartShouldSetPanResponder","onMoveShouldSetPanResponderCapture","_evt","g","dy","dx","onMoveShouldSetPanResponder","onPanResponderTerminationRequest","onPanResponderMove","Math","max","onPanResponderRelease","vy","spring","tension","friction","onPanResponderTerminate","bodyPanRef","handlePanRef","pan","handlePan","menuOptions","options","color","onClick","NEW_CHAT","styles","PROFILE","SETTINGS","push","catch","transparent","visible","animationType","statusBarTranslucent","onRequestClose","children","overlay","opacity","testID","onLayout","measured","nativeEvent","layout","sheet","backgroundColor","surface","shadowColor","shadow","paddingBottom","bottom","transform","translateY","panHandlers","grabArea","grabber","dark","textMuted","card","map","option","index","menuItemWrapper","menuItem","activeOpacity","iconSlot","length","divider","display","flexDirection","alignItems","paddingVertical","paddingHorizontal","width","fontSize","fontWeight","marginLeft","hairlineWidth","position","left","right","paddingTop","borderRadius","shadowOpacity","shadowOffset","shadowRadius","elevation","zIndex","overflow","top","flex"],"sourceRoot":"../../../../src","sources":["components/Menu/HeaderRoomListMenu.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAQC,WAAW,EAAEC,SAAS,EAAEC,OAAO,EAAEC,MAAM,EAAEC,QAAQ,QAAQ,OAAO;AACpF,SACEC,KAAK,EACLC,QAAQ,EACRC,IAAI,EACJC,gBAAgB,EAChBC,wBAAwB,EACxBC,UA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AC;IACR9B,MAAM,EAAE,CAAC;IACTwC,IAAI,EAAE,CAAC;IACPjB,KAAK,EAAE,MAAM;IACb5H,MAAM,EAAE,MAAM;IACdgG,eAAe,EAAE;EACnB;AACF,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["React","useCallback","useEffect","useMemo","useRef","useState","Alert","Animated","Text","TouchableOpacity","TouchableWithoutFeedback","StyleSheet","Dimensions","Modal","PanResponder","Platform","View","AddNewIcon","DiscoverIcon","LogoutIcon","ProfileIcon","SettingIcon","useDispatch","useSafeAreaInsets","setActiveModal","MODAL_TYPES","useChatSettingState","useLogout","useTheme","useT","shouldClaimVerticalDrag","shouldDismissOnDrag","jsx","_jsx","jsxs","_jsxs","DEFAULT_LOGOUT_STRINGS","label","message","cancel","confirmLogout","confirm","strings","Promise","resolve","copy","alert","title","text","cancelText","style","onPress","confirmText","cancelable","onDismiss","runLogoutFlow","logoutConfig","performLogout","confirmed","onBeforeLogout","proceed","e","console","warn","onAfterLogout","height","windowHeight","get","HeaderRoomListMenu","isDrawerOpen","drawerAnimation","overlayAnimation","closeDrawer","dispatch","config","t","logout","enabled","undefined","logoutStrings","theme","primaryColor","primary","iconColor","icon","labelColor","insets","sheetHeight","setSheetHeight","dragY","Value","current","sheetHeightRef","closeDrawerRef","pendingActionRef","runPendingAction","action","OS","id","setTimeout","clearTimeout","handleOptionPress","setValue","timing","toValue","duration","useNativeDriver","start","openTranslateY","interpolate","inputRange","outputRange","dismissByDrag","makeDragResponder","claimOnStart","create","onStartShouldSetPanResponder","onMoveShouldSetPanResponderCapture","_evt","g","dy","dx","onMoveShouldSetPanResponder","onPanResponderTerminationRequest","onPanResponderMove","Math","max","onPanResponderRelease","vy","spring","tension","friction","onPanResponderTerminate","bodyPanRef","handlePanRef","pan","handlePan","menuOptions","options","color","onClick","NEW_CHAT","styles","PROFILE","SETTINGS","disablePublicChatsDirectory","PUBLIC_CHATS","push","catch","transparent","visible","animationType","statusBarTranslucent","onRequestClose","children","overlay","opacity","testID","onLayout","measured","nativeEvent","layout","sheet","backgroundColor","surface","shadowColor","shadow","paddingBottom","bottom","transform","translateY","panHandlers","grabArea","grabber","dark","textMuted","card","map","option","index","menuItemWrapper","menuItem","activeOpacity","iconSlot","length","divider","display","flexDirection","alignItems","paddingVertical","paddingHorizontal","width","fontSize","fontWeight","marginLeft","hairlineWidth","position","left","right","paddingTop","borderRadius","shadowOpacity","shadowOffset","shadowRadius","elevation","zIndex","overflow","top","flex"],"sourceRoot":"../../../../src","sources":["components/Menu/HeaderRoomListMenu.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAQC,WAAW,EAAEC,SAAS,EAAEC,OAAO,EAAEC,MAAM,EAAEC,QAAQ,QAAQ,OAAO;AACpF,SACEC,KAAK,EACLC,QAAQ,EACRC,IAAI,EACJC,gBAAgB,EAChBC,wBAAwB,EACxBC,UAAU,EACVC,UAAU,EACVC,KAAK,EACLC,YAAY,EACZC,QAAQ,EACRC,IAAI,QACC,cAAc;AACrB,SACEC,UAAU,EACVC,YAAY,EACZC,UAAU,EACVC,WAAW,EACXC,WAAW,QACN,oBAAoB;AAC3B,SAASC,WAAW,QAAQ,aAAa;AACzC,SAASC,iBAAiB,QAAQ,gCAAgC;AAClE,SAASC,cAAc,QAAQ,mCAAmC;AAClE,SAASC,WAAW,QAAQ,qCAAqC;AACjE,SAASC,mBAAmB,QAAQ,iCAAiC;AACrE,SAASC,SAAS,QAAQ,uBAAuB;AACjD,SAASC,QAAQ,QAAQ,sBAAsB;AAC/C,SAASC,IAAI,QAAQ,iBAAiB;AACtC,SACEC,uBAAuB,EACvBC,mBAAmB,QACd,6BAA6B;;AAKpC;AAAA,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAOA,MAAMC,sBAAqC,GAAG;EAC5CC,KAAK,EAAE,UAAU;EACjBC,OAAO,EAAE,oCAAoC;EAC7CC,MAAM,EAAE;AACV,CAAC;AAED,MAAMC,aAAa,GAAGA,CACpBC,O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AE;EACd,CAAC;EACDT,OAAO,EAAE;IACPxH,MAAM,EAAEtD,UAAU,CAACwL,aAAa;IAChCD,UAAU,EAAE,EAAE;IACd;IACA/B,eAAe,EAAE;EACnB,CAAC;EACDD,KAAK,EAAE;IACLkC,QAAQ,EAAE,UAAU;IACpB;IACA;IACAC,IAAI,EAAE,CAAC;IACPC,KAAK,EAAE,CAAC;IACR9B,MAAM,EAAE,CAAC;IACT+B,UAAU,EAAE,CAAC;IACbC,YAAY,EAAE,EAAE;IAChBC,aAAa,EAAE,IAAI;IACnBC,YAAY,EAAE;MAAEX,KAAK,EAAE,CAAC;MAAE9H,MAAM,EAAE,CAAC;IAAE,CAAC;IACtC0I,YAAY,EAAE,EAAE;IAChBC,SAAS,EAAE,EAAE;IACbC,MAAM,EAAE;EACV,CAAC;EACDjC,QAAQ,EAAE;IACRgB,UAAU,EAAE,QAAQ;IACpBW,UAAU,EAAE,CAAC;IACbhC,aAAa,EAAE;EACjB,CAAC;EACDM,OAAO,EAAE;IACPkB,KAAK,EAAE,EAAE;IACT9H,MAAM,EAAE,CAAC;IACTuI,YAAY,EAAE,CAAC;IACf;IACArC,eAAe,EAAE;EACnB,CAAC;EACDa,IAAI,EAAE;IACJ8B,QAAQ,EAAE;EACZ,CAAC;EACDnD,OAAO,EAAE;IACPyC,QAAQ,EAAE,UAAU;IACpBW,GAAG,EAAE,CAAC;IACNV,IAAI,EAAE,CAAC;IACPC,KAAK,EAAE,CAAC;IACR9B,MAAM,EAAE,CAAC;IACTwC,IAAI,EAAE,CAAC;IACPjB,KAAK,EAAE,MAAM;IACb9H,MAAM,EAAE,MAAM;IACdkG,eAAe,EAAE;EACnB;AACF,CAAC,CAAC","ignoreList":[]}
@@ -0,0 +1,106 @@
1
+ "use strict";
2
+
3
+ import React, { useEffect, useRef, useState } from 'react';
4
+ import { AccessibilityInfo, Animated, StyleSheet } from 'react-native';
5
+ import { useBubbleHighlightUntil } from '../../helpers/bubbleHighlight';
6
+ import { useTheme } from '../../hooks/useTheme';
7
+ import { jsx as _jsx } from "react/jsx-runtime";
8
+ const FADE_IN_MS = 150;
9
+ const Ring = ({
10
+ remainingMs
11
+ }) => {
12
+ const theme = useTheme();
13
+ const opacity = useRef(new Animated.Value(0)).current;
14
+ // Fixed at mount: a re-render must not restart the pulse.
15
+ const startRemainingRef = useRef(remainingMs);
16
+ const [reduceMotion, setReduceMotion] = useState(null);
17
+ useEffect(() => {
18
+ let alive = true;
19
+ Promise.resolve(AccessibilityInfo?.isReduceMotionEnabled?.()).then(value => {
20
+ if (alive) {
21
+ setReduceMotion(Boolean(value));
22
+ }
23
+ }).catch(() => {
24
+ if (alive) {
25
+ setReduceMotion(false);
26
+ }
27
+ });
28
+ return () => {
29
+ alive = false;
30
+ };
31
+ }, []);
32
+ useEffect(() => {
33
+ if (reduceMotion === null) {
34
+ return;
35
+ }
36
+ if (reduceMotion) {
37
+ // A static ring for the rest of the second: no movement, still visible.
38
+ opacity.setValue(1);
39
+ return;
40
+ }
41
+ const total = startRemainingRef.current;
42
+ const fadeIn = Math.min(FADE_IN_MS, total);
43
+ const animation = Animated.sequence([Animated.timing(opacity, {
44
+ toValue: 1,
45
+ duration: fadeIn,
46
+ useNativeDriver: true
47
+ }), Animated.timing(opacity, {
48
+ toValue: 0,
49
+ duration: Math.max(0, total - fadeIn),
50
+ useNativeDriver: true
51
+ })]);
52
+ animation.start();
53
+ return () => animation.stop();
54
+ }, [reduceMotion, opacity]);
55
+ return /*#__PURE__*/_jsx(Animated.View, {
56
+ testID: "bubble-highlight",
57
+ pointerEvents: "none",
58
+ style: [styles.ring, {
59
+ opacity,
60
+ borderColor: theme.primary,
61
+ backgroundColor: theme.primary + '22'
62
+ }]
63
+ });
64
+ };
65
+
66
+ /**
67
+ * The brief ring and tint a jump puts on the bubble of the message it landed
68
+ * on (not on the whole row: the row also holds the date label and the
69
+ * avatar). Renders inside the bubble, which clips it to the bubble's corners.
70
+ * Nothing is mounted for a message without a running highlight.
71
+ */
72
+ export const BubbleHighlight = ({
73
+ messageId
74
+ }) => {
75
+ const until = useBubbleHighlightUntil(String(messageId));
76
+ const [, setTick] = useState(0);
77
+ const remaining = until - Date.now();
78
+
79
+ // Drop the ring when its time is up even if nothing else re-renders.
80
+ useEffect(() => {
81
+ if (remaining <= 0) {
82
+ return;
83
+ }
84
+ const timer = setTimeout(() => setTick(value => value + 1), remaining);
85
+ return () => clearTimeout(timer);
86
+ }, [until, remaining]);
87
+ if (remaining <= 0) {
88
+ return null;
89
+ }
90
+ return /*#__PURE__*/_jsx(Ring, {
91
+ remainingMs: remaining
92
+ });
93
+ };
94
+ const styles = StyleSheet.create({
95
+ ring: {
96
+ position: 'absolute',
97
+ top: 0,
98
+ left: 0,
99
+ right: 0,
100
+ bottom: 0,
101
+ borderWidth: 2,
102
+ borderRadius: 10
103
+ }
104
+ });
105
+ export default BubbleHighlight;
106
+ //# sourceMappingURL=BubbleHighlight.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","useEffect","useRef","useState","AccessibilityInfo","Animated","StyleSheet","useBubbleHighlightUntil","useTheme","jsx","_jsx","FADE_IN_MS","Ring","remainingMs","theme","opacity","Value","current","startRemainingRef","reduceMotion","setReduceMotion","alive","Promise","resolve","isReduceMotionEnabled","then","value","Boolean","catch","setValue","total","fadeIn","Math","min","animation","sequence","timing","toValue","duration","useNativeDriver","max","start","stop","View","testID","pointerEvents","style","styles","ring","borderColor","primary","backgroundColor","BubbleHighlight","messageId","until","String","setTick","remaining","Date","now","timer","setTimeout","clearTimeout","create","position","top","left","right","bottom","borderWidth","borderRadius"],"sourceRoot":"../../../../src","sources":["components/MessageBubble/BubbleHighlight.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAIC,SAAS,EAAEC,MAAM,EAAEC,QAAQ,QAAQ,OAAO;AAC1D,SAASC,iBAAiB,EAAEC,QAAQ,EAAEC,UAAU,QAAQ,cAAc;AACtE,SAASC,uBAAuB,QAAQ,+BAA+B;AACvE,SAASC,QAAQ,QAAQ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G,CAAC,CAAC,EAAE+B,SAAS,CAAC;IACxE,OAAO,MAAMK,YAAY,CAACF,KAAK,CAAC;EAClC,CAAC,EAAE,CAACN,KAAK,EAAEG,SAAS,CAAC,CAAC;EAEtB,IAAIA,SAAS,IAAI,CAAC,EAAE;IAAC,OAAO,IAAI;EAAC;EACjC,oBAAO/C,IAAA,CAACE,IAAI;IAACC,WAAW,EAAE4C;EAAU,CAAE,CAAC;AACzC,CAAC;AAED,MAAMV,MAAM,GAAGzC,UAAU,CAACyD,MAAM,CAAC;EAC/Bf,IAAI,EAAE;IACJgB,QAAQ,EAAE,UAAU;IACpBC,GAAG,EAAE,CAAC;IACNC,IAAI,EAAE,CAAC;IACPC,KAAK,EAAE,CAAC;IACRC,MAAM,EAAE,CAAC;IACTC,WAAW,EAAE,CAAC;IACdC,YAAY,EAAE;EAChB;AACF,CAAC,CAAC;AAEF,eAAelB,eAAe","ignoreList":[]}
@@ -1,9 +1,10 @@
1
1
  "use strict";
2
2
 
3
- import React, { useEffect, useMemo, useRef, useState } from 'react';
4
- import { Alert, Animated, View, Pressable, StyleSheet, findNodeHandle, UIManager, Text, Keyboard } from 'react-native';
3
+ import React, { useEffect, useMemo, useRef, useState, useSyncExternalStore } from 'react';
4
+ import { Alert, View, Pressable, StyleSheet, findNodeHandle, UIManager, Text, Keyboard } from 'react-native';
5
5
  import { useDispatch, useSelector } from 'react-redux';
6
6
  import { Avatar } from './Avatar';
7
+ import { BubbleHighlight } from './BubbleHighlight';
7
8
  import MessageInteractions from './MessageInteractions';
8
9
  import { BottomReplyContainer } from './BottomReplyContainer';
9
10
  import { MessageReply } from './MessageReply';
@@ -25,7 +26,6 @@ import { chatTextStyle } from '../../helpers/typography';
25
26
  import { useMessageHeapState } from '../../hooks/useMessageHeapState';
26
27
  import { DoubleTick, LockIcon, LockOffIcon } from '../../assets/icons';
27
28
  import { useT } from '../../i18n/useT';
28
- import { composeName } from '../../helpers/displayName';
29
29
  import { useFileToken } from '../../hooks/useFileToken';
30
30
  import { appendFileToken, isSecureFileUrl, requestFileTokenRecovery } from '../../helpers/secureFileUrl';
31
31
  import { placeholderKey } from '../../e2ee/stanza';
@@ -37,7 +37,12 @@ import { reactionsEnabled } from '../../helpers/reactionsConfig';
37
37
  import { Gesture, GestureDetector } from 'react-native-gesture-handler';
38
38
  import { hapticTap } from '../../helpers/haptics';
39
39
  import { useTheme } from '../../hooks/useTheme';
40
+ import { isOpaqueXmppUserId } from '../../helpers/xmppIdShape';
41
+ import { getUserLookupStatus, requestUsers, subscribeUserResolver } from '../../helpers/userResolver';
42
+
43
+ // Stable-width stand-in for the sender name while its lookup is pending.
40
44
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
45
+ const SENDER_NAME_PLACEHOLDER = '\u2026';
41
46
  const CustomMessageContainer = styled.View`
42
47
  flex-direction: row;
43
48
  padding: 10px;
@@ -215,19 +220,44 @@ const Message = ({
215
220
  // avatars: a cache-restored message carries no profileImage at all (see
216
221
  // PERSISTED_MESSAGE_USER_FIELDS), so reading only the message-level copy
217
222
  // leaves a blank initials circle for senders whose name resolved fine.
218
- const usersSet = useSelector(state => state.rooms.usersSet);
219
223
  const senderRawId = String(message.user?.id || '');
220
224
  const senderLocal = senderRawId.split('@')[0];
221
- const senderEntry = usersSet?.[senderLocal] || usersSet?.[senderRawId];
222
- // usersSet FIRST (mirrors the web SDK's Message.tsx): a message stored
223
- // before usersSet hydrated carries the raw JID localpart as its
224
- // `user.name`, so preferring `message.user.name` (as resolveSenderDisplayName
225
- // does) would pin that JID on screen forever even after the real name is
226
- // known. Reading usersSet first lets the name self-heal the moment the
227
- // REST roster populates the cache. Falls back to the message's own name
228
- // (which may carry senderFirstName/senderLastName from the wire) only when
229
- // usersSet has never seen this sender.
230
- const senderDisplayName = senderEntry ? composeName(senderEntry.firstName, senderEntry.lastName) || senderEntry.name || senderLocal : message.user?.name || senderLocal || 'Unknown';
225
+ // Granular: re-render only when THIS sender's entry changes, not on every
226
+ // usersSet update.
227
+ const senderEntry = useSelector(state => {
228
+ const set = state.rooms.usersSet;
229
+ return set?.[senderLocal] || set?.[senderRawId];
230
+ });
231
+ // A usersSet hit with blank names is worth no more than a miss.
232
+ const usersSetDisplayName = senderEntry ? `${senderEntry.firstName ?? ''} ${senderEntry.lastName ?? ''}`.trim() || String(senderEntry.name || '').trim() : '';
233
+ // 'Deleted User' baked into message.user.name only means "not resolved at
234
+ // insert time" (the real answer is the lookup's 404 below), and a raw
235
+ // xmpp id is never a name.
236
+ const safeMessageName = message.user?.name && message.user.name !== 'Deleted User' && !isOpaqueXmppUserId(message.user.name) ? message.user.name : '';
237
+ const safeSenderLocal = isOpaqueXmppUserId(senderLocal) ? '' : senderLocal;
238
+ // Ask the backend for a sender nobody has told us about (a big room ships
239
+ // only 30 members). The resolver debounces and de-duplicates.
240
+ useEffect(() => {
241
+ if (!senderEntry && senderLocal) requestUsers([senderLocal]);
242
+ }, [senderEntry, senderLocal]);
243
+ const lookupStatus = useSyncExternalStore(subscribeUserResolver, () => getUserLookupStatus(senderLocal), () => 'pending');
244
+ // The sender's name stamped on the stanza's <data> by clients of this SDK.
245
+ // LAST resort only (older clients and backends): used once the lookup has
246
+ // finished without a name, and never written into usersSet. Insert-time
247
+ // enrichment may have baked it into message.user.name, so a message name
248
+ // equal to it counts as <data>, not as a member name.
249
+ const dataFull = String(message?.fullName || '').trim();
250
+ const dataComposed = dataFull || `${String(message?.senderFirstName || '').trim()} ${String(message?.senderLastName || '').trim()}`.trim();
251
+ const trustedMessageName = safeMessageName && safeMessageName !== dataComposed ? safeMessageName : '';
252
+ // Chain: usersSet (member or lookup result) > a name from a member/seed >
253
+ // muted placeholder while the lookup is pending > <data> name > readable
254
+ // id > Unknown user ('Deleted User' only when the backend said 404).
255
+ const senderNamePending = !usersSetDisplayName && !trustedMessageName && lookupStatus === 'pending';
256
+ const unresolvedPlaceholder = lookupStatus === 'notfound' && !dataComposed ? 'Deleted User' : t('user.unknown');
257
+ const senderDisplayName = senderNamePending ? SENDER_NAME_PLACEHOLDER : usersSetDisplayName || trustedMessageName || dataComposed || safeSenderLocal || unresolvedPlaceholder;
258
+ // The placeholder is a loading state, not a name: it must not seed the
259
+ // generic avatar's initials or a stale caption.
260
+ //
231
261
  // A broadcast posted by the app itself arrives with the ROOM's own id as
232
262
  // its occupant resource, so no roster ever resolves it and the name chain
233
263
  // ends at 50 characters of hex. Captioning a bubble with that tells the
@@ -362,17 +392,6 @@ const Message = ({
362
392
  // eslint-disable-next-line react-hooks/exhaustive-deps
363
393
  [config?.disableInteractions]);
364
394
 
365
- // The bubble lifts a touch while its menu is open, and settles back.
366
- const lift = useRef(new Animated.Value(1)).current;
367
- useEffect(() => {
368
- Animated.spring(lift, {
369
- toValue: isPressed ? 1.03 : 1,
370
- useNativeDriver: true,
371
- speed: 30,
372
- bounciness: 6
373
- }).start();
374
- }, [isPressed, lift]);
375
-
376
395
  // Body text size/weight is set on the parser's leaf <Text>s — the markdown
377
396
  // wraps content in <View>s which break Text-style inheritance, so the bubble
378
397
  // wrapper's fontSize alone never reached the actual text.
@@ -398,6 +417,117 @@ const Message = ({
398
417
  retryMessage(message.id);
399
418
  }
400
419
  };
420
+
421
+ // The bubble, as a function: the list draws it in place, and the context
422
+ // menu draws a second copy over the dimmed chat (WhatsApp style) while
423
+ // the original steps aside.
424
+ const renderBubble = preview => /*#__PURE__*/_jsxs(CustomMessageBubble, {
425
+ ...(preview ?
426
+ // The copy in the context menu: same look, full measured
427
+ // width (its box is the original's), never the measuring
428
+ // target.
429
+ {
430
+ style: styles.previewBubble
431
+ } : {
432
+ ref: bubbleRef,
433
+ collapsable: false,
434
+ // Hidden while the menu shows its copy over the dim, so
435
+ // the message is not on screen twice.
436
+ style: isPressed && contextMenuPosition ? styles.hiddenBubble : undefined
437
+ }),
438
+ isUser: isUser,
439
+ deleted: message.isDeleted,
440
+ isMedia: message?.isMediafile === 'true' && !message?.isDeleted,
441
+ children: [!isUser && hasRealSenderName && /*#__PURE__*/_jsx(CustomUserName
442
+ // Historically `config.colors.primary` with a plain-text
443
+ // fallback; theme.primary carries the same value in light
444
+ // mode and the dark accent in dark mode.
445
+ , {
446
+ color: config?.colors?.primary ? theme.primary : undefined,
447
+ media: message?.isMediafile === 'true',
448
+ fontSize: config?.typography?.senderName?.fontSize,
449
+ fontWeight: config?.typography?.senderName?.fontWeight,
450
+ style: senderNamePending ? styles.pendingName : undefined,
451
+ children: senderDisplayName
452
+ }), !isReply && !!replyRef?.text && /*#__PURE__*/_jsx(MessageReply, {
453
+ handleReplyMessage: handleReplyMessage,
454
+ isUser: isUser,
455
+ text: replyRef.text,
456
+ userName: replyRef.userName,
457
+ color: theme.primary
458
+ }), message?.isMediafile === 'true' && !message?.isDeleted ? /*#__PURE__*/_jsx(MediaMessage, {
459
+ mimeType: message.mimetype,
460
+ messageText: message.locationPreview,
461
+ location: message?.location,
462
+ message: message,
463
+ isUser: isUser
464
+ }) : /*#__PURE__*/_jsx(_Fragment, {
465
+ children: message.isDeleted && message.id !== 'delimiter-new' ? /*#__PURE__*/_jsx(DeletedMessage, {}) : isUndecryptable ? /*#__PURE__*/_jsxs(View, {
466
+ style: styles.undecryptable,
467
+ children: [/*#__PURE__*/_jsx(LockIcon, {
468
+ width: 15,
469
+ height: 15,
470
+ color: theme.textSecondary
471
+ }), /*#__PURE__*/_jsx(Text, {
472
+ style: [styles.undecryptableText, themedStyles.muted, {
473
+ fontSize: config?.typography?.messageText?.fontSize ?? 15
474
+ }],
475
+ children: t(placeholderKey(message.e2eeError))
476
+ })]
477
+ }) : /*#__PURE__*/_jsx(CustomMessageText, {
478
+ isUser: isUser,
479
+ fontSize: config?.typography?.messageText?.fontSize,
480
+ fontWeight: config?.typography?.messageText?.fontWeight,
481
+ children: showInlineTranslation ? /*#__PURE__*/_jsx(TranslatedMessageBody, {
482
+ isUser: isUser,
483
+ originalText: translationDisplay.originalText,
484
+ accentColor: theme.primary,
485
+ children: /*#__PURE__*/_jsx(Text, {
486
+ children: messageText
487
+ })
488
+ }) : /*#__PURE__*/_jsx(Text, {
489
+ children: messageText
490
+ })
491
+ })
492
+ }), !isUser && !isUndecryptable && isTranslatesEnabled && effectiveTranslateMode === 'manual' && /*#__PURE__*/_jsx(MessageTranslate, {
493
+ message: message,
494
+ config: config,
495
+ isUser: isUser,
496
+ readerLocale: readerLocale
497
+ }), /*#__PURE__*/_jsxs(CustomTimestampRow, {
498
+ media: message?.isMediafile === 'true',
499
+ children: [!config?.disableSentLogic && isUser && isPending && /*#__PURE__*/_jsx(Text, {
500
+ style: [styles.timestampText, themedStyles.muted],
501
+ children: t('message.sending')
502
+ }), !config?.disableSentLogic && isUser && isFailed && /*#__PURE__*/_jsx(Text, {
503
+ onPress: onRetryPress,
504
+ style: [styles.failedText, themedStyles.failed],
505
+ accessibilityRole: "button",
506
+ accessibilityLabel: "Retry sending message",
507
+ children: t('message.failedRetry')
508
+ }), message?.isEdited && !message?.isDeleted && /*#__PURE__*/_jsx(Text, {
509
+ style: [styles.editedText, themedStyles.muted],
510
+ children: t('message.edited')
511
+ }), message?.unencrypted && !message?.isDeleted && /*#__PURE__*/_jsx(Pressable, {
512
+ hitSlop: 10,
513
+ accessibilityRole: "button",
514
+ accessibilityLabel: t('e2ee.notEncrypted'),
515
+ accessibilityHint: t('e2ee.notEncryptedHint'),
516
+ testID: "message-not-encrypted",
517
+ onPress: () => Alert.alert(t('e2ee.notEncrypted'), t('e2ee.notEncryptedHint')),
518
+ children: /*#__PURE__*/_jsx(LockOffIcon, {
519
+ width: 13,
520
+ height: 13,
521
+ color: theme.danger
522
+ })
523
+ }), /*#__PURE__*/_jsx(Text, {
524
+ style: [styles.timestampText, themedStyles.muted],
525
+ children: timeLabel
526
+ }), !config?.disableSentLogic && isUser && !isPending && !isFailed && /*#__PURE__*/_jsx(DoubleTick, {})]
527
+ }), !preview && /*#__PURE__*/_jsx(BubbleHighlight, {
528
+ messageId: String(message.id)
529
+ })]
530
+ });
401
531
  return /*#__PURE__*/_jsxs(View, {
402
532
  children: [isPressed && /*#__PURE__*/_jsx(View, {
403
533
  style: styles.overlay
@@ -426,7 +556,8 @@ const Message = ({
426
556
  profileImage: senderEntry.profileImage,
427
557
  description: senderEntry.description
428
558
  } : {}),
429
- name: hasRealSenderName ? senderDisplayName : ''
559
+ // The pending placeholder is not a name.
560
+ name: hasRealSenderName && !senderNamePending ? senderDisplayName : ''
430
561
  }),
431
562
  disabled: !!config?.disableProfilesInteractions,
432
563
  accessible: !config?.disableProfilesInteractions,
@@ -442,7 +573,7 @@ const Message = ({
442
573
  setAvatarFailed(rawProfileImage);
443
574
  }
444
575
  }) : /*#__PURE__*/_jsx(Avatar, {
445
- username: senderDisplayName
576
+ username: senderNamePending ? '' : senderDisplayName
446
577
  })
447
578
  }), /*#__PURE__*/_jsx(GestureDetector, {
448
579
  gesture: longPress,
@@ -469,105 +600,8 @@ const Message = ({
469
600
  // long-press never triggers this dismiss.
470
601
  ,
471
602
  onPress: () => Keyboard.dismiss(),
472
- children: /*#__PURE__*/_jsxs(Animated.View, {
473
- style: {
474
- transform: [{
475
- scale: lift
476
- }]
477
- },
478
- children: [/*#__PURE__*/_jsxs(CustomMessageBubble, {
479
- ref: bubbleRef,
480
- collapsable: false,
481
- isUser: isUser,
482
- deleted: message.isDeleted,
483
- isMedia: message?.isMediafile === 'true' && !message?.isDeleted,
484
- children: [!isUser && hasRealSenderName && /*#__PURE__*/_jsx(CustomUserName
485
- // Historically `config.colors.primary` with a plain-text
486
- // fallback; theme.primary carries the same value in light
487
- // mode and the dark accent in dark mode.
488
- , {
489
- color: config?.colors?.primary ? theme.primary : undefined,
490
- media: message?.isMediafile === 'true',
491
- fontSize: config?.typography?.senderName?.fontSize,
492
- fontWeight: config?.typography?.senderName?.fontWeight,
493
- children: senderDisplayName
494
- }), !isReply && !!replyRef?.text && /*#__PURE__*/_jsx(MessageReply, {
495
- handleReplyMessage: handleReplyMessage,
496
- isUser: isUser,
497
- text: replyRef.text,
498
- userName: replyRef.userName,
499
- color: theme.primary
500
- }), message?.isMediafile === 'true' && !message?.isDeleted ? /*#__PURE__*/_jsx(MediaMessage, {
501
- mimeType: message.mimetype,
502
- messageText: message.locationPreview,
503
- location: message?.location,
504
- message: message,
505
- isUser: isUser
506
- }) : /*#__PURE__*/_jsx(_Fragment, {
507
- children: message.isDeleted && message.id !== 'delimiter-new' ? /*#__PURE__*/_jsx(DeletedMessage, {}) : isUndecryptable ? /*#__PURE__*/_jsxs(View, {
508
- style: styles.undecryptable,
509
- children: [/*#__PURE__*/_jsx(LockIcon, {
510
- width: 15,
511
- height: 15,
512
- color: theme.textSecondary
513
- }), /*#__PURE__*/_jsx(Text, {
514
- style: [styles.undecryptableText, themedStyles.muted, {
515
- fontSize: config?.typography?.messageText?.fontSize ?? 15
516
- }],
517
- children: t(placeholderKey(message.e2eeError))
518
- })]
519
- }) : /*#__PURE__*/_jsx(CustomMessageText, {
520
- isUser: isUser,
521
- fontSize: config?.typography?.messageText?.fontSize,
522
- fontWeight: config?.typography?.messageText?.fontWeight,
523
- children: showInlineTranslation ? /*#__PURE__*/_jsx(TranslatedMessageBody, {
524
- isUser: isUser,
525
- originalText: translationDisplay.originalText,
526
- accentColor: theme.primary,
527
- children: /*#__PURE__*/_jsx(Text, {
528
- children: messageText
529
- })
530
- }) : /*#__PURE__*/_jsx(Text, {
531
- children: messageText
532
- })
533
- })
534
- }), !isUser && !isUndecryptable && isTranslatesEnabled && effectiveTranslateMode === 'manual' && /*#__PURE__*/_jsx(MessageTranslate, {
535
- message: message,
536
- config: config,
537
- isUser: isUser,
538
- readerLocale: readerLocale
539
- }), /*#__PURE__*/_jsxs(CustomTimestampRow, {
540
- media: message?.isMediafile === 'true',
541
- children: [!config?.disableSentLogic && isUser && isPending && /*#__PURE__*/_jsx(Text, {
542
- style: [styles.timestampText, themedStyles.muted],
543
- children: t('message.sending')
544
- }), !config?.disableSentLogic && isUser && isFailed && /*#__PURE__*/_jsx(Text, {
545
- onPress: onRetryPress,
546
- style: [styles.failedText, themedStyles.failed],
547
- accessibilityRole: "button",
548
- accessibilityLabel: "Retry sending message",
549
- children: t('message.failedRetry')
550
- }), message?.isEdited && !message?.isDeleted && /*#__PURE__*/_jsx(Text, {
551
- style: [styles.editedText, themedStyles.muted],
552
- children: t('message.edited')
553
- }), message?.unencrypted && !message?.isDeleted && /*#__PURE__*/_jsx(Pressable, {
554
- hitSlop: 10,
555
- accessibilityRole: "button",
556
- accessibilityLabel: t('e2ee.notEncrypted'),
557
- accessibilityHint: t('e2ee.notEncryptedHint'),
558
- testID: "message-not-encrypted",
559
- onPress: () => Alert.alert(t('e2ee.notEncrypted'), t('e2ee.notEncryptedHint')),
560
- children: /*#__PURE__*/_jsx(LockOffIcon, {
561
- width: 13,
562
- height: 13,
563
- color: theme.danger
564
- })
565
- }), /*#__PURE__*/_jsx(Text, {
566
- style: [styles.timestampText, themedStyles.muted],
567
- children: timeLabel
568
- }), !config?.disableSentLogic && isUser && !isPending && !isFailed && /*#__PURE__*/_jsx(DoubleTick, {})]
569
- })]
570
- }), (!isReply && (message?.reply?.length || 0) > 0 || !!message.reaction && reactionsEnabled(config)) && /*#__PURE__*/_jsxs(View, {
603
+ children: /*#__PURE__*/_jsxs(View, {
604
+ children: [renderBubble(false), (!isReply && (message?.reply?.length || 0) > 0 || !!message.reaction && reactionsEnabled(config)) && /*#__PURE__*/_jsxs(View, {
571
605
  style: [styles.reactionRow, isUser ? styles.reactionRowUser : styles.reactionRowOther],
572
606
  children: [!isReply && (message?.reply?.length || 0) > 0 && /*#__PURE__*/_jsx(BottomReplyContainer, {
573
607
  isUser: isUser,
@@ -594,7 +628,8 @@ const Message = ({
594
628
  handleDeleteMessage: handleDeleteMessage,
595
629
  handleEditMessage: handleEditMessage,
596
630
  handleReactionMessage: handleReactionMessage,
597
- onOpenEmojiPicker: () => setEmojiPickerOpen(true)
631
+ onOpenEmojiPicker: () => setEmojiPickerOpen(true),
632
+ preview: renderBubble(true)
598
633
  }), emojiPickerOpen && /*#__PURE__*/_jsx(EmojiPickerSheet, {
599
634
  visible: true,
600
635
  onClose: () => setEmojiPickerOpen(false),
@@ -605,6 +640,16 @@ const Message = ({
605
640
  const MemoMessage = /*#__PURE__*/React.memo(Message);
606
641
  export { MemoMessage as Message };
607
642
  const styles = StyleSheet.create({
643
+ previewBubble: {
644
+ maxWidth: '100%'
645
+ },
646
+ hiddenBubble: {
647
+ opacity: 0
648
+ },
649
+ pendingName: {
650
+ opacity: 0.5,
651
+ minWidth: 14
652
+ },
608
653
  customMessageContainer: {
609
654
  flexDirection: 'row',
610
655
  padding: 10,