@ethora/chat-component-rn 26.8.1 → 26.8.2

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 (604) hide show
  1. package/CHANGELOG.md +96 -0
  2. package/README.md +43 -10
  3. package/lib/commonjs/assets/icons.js +7 -2
  4. package/lib/commonjs/assets/icons.js.map +1 -1
  5. package/lib/commonjs/components/AuthForms/Login.js +4 -4
  6. package/lib/commonjs/components/AuthForms/Login.js.map +1 -1
  7. package/lib/commonjs/components/Header/HeaderRoomList.js +29 -8
  8. package/lib/commonjs/components/Header/HeaderRoomList.js.map +1 -1
  9. package/lib/commonjs/components/MainComponents/ChatHeader.js +9 -3
  10. package/lib/commonjs/components/MainComponents/ChatHeader.js.map +1 -1
  11. package/lib/commonjs/components/MainComponents/ChatRoom.js +150 -14
  12. package/lib/commonjs/components/MainComponents/ChatRoom.js.map +1 -1
  13. package/lib/commonjs/components/MainComponents/ChatWrapper.js +34 -13
  14. package/lib/commonjs/components/MainComponents/ChatWrapper.js.map +1 -1
  15. package/lib/commonjs/components/MainComponents/LoginWrapper.js +2 -1
  16. package/lib/commonjs/components/MainComponents/LoginWrapper.js.map +1 -1
  17. package/lib/commonjs/components/MainComponents/MediaMessage.js +29 -9
  18. package/lib/commonjs/components/MainComponents/MediaMessage.js.map +1 -1
  19. package/lib/commonjs/components/MainComponents/MessageContainer.js +5 -1
  20. package/lib/commonjs/components/MainComponents/MessageContainer.js.map +1 -1
  21. package/lib/commonjs/components/MainComponents/MessageList.js +13 -5
  22. package/lib/commonjs/components/MainComponents/MessageList.js.map +1 -1
  23. package/lib/commonjs/components/MainComponents/ProfileImagePlaceholder.js +14 -13
  24. package/lib/commonjs/components/MainComponents/ProfileImagePlaceholder.js.map +1 -1
  25. package/lib/commonjs/components/MainComponents/RoomList.js +208 -35
  26. package/lib/commonjs/components/MainComponents/RoomList.js.map +1 -1
  27. package/lib/commonjs/components/Menu/HeaderRoomListMenu.js +317 -98
  28. package/lib/commonjs/components/Menu/HeaderRoomListMenu.js.map +1 -1
  29. package/lib/commonjs/components/Modals/AttachSheet/AttachSheet.js +322 -110
  30. package/lib/commonjs/components/Modals/AttachSheet/AttachSheet.js.map +1 -1
  31. package/lib/commonjs/components/Modals/ChatProfileModal/ChatProfileModal.js +546 -203
  32. package/lib/commonjs/components/Modals/ChatProfileModal/ChatProfileModal.js.map +1 -1
  33. package/lib/commonjs/components/Modals/ChatProfileModal/ReportChatModal.js +226 -0
  34. package/lib/commonjs/components/Modals/ChatProfileModal/ReportChatModal.js.map +1 -0
  35. package/lib/commonjs/components/Modals/FilePreviewModal/FilePreviewModal.js +69 -27
  36. package/lib/commonjs/components/Modals/FilePreviewModal/FilePreviewModal.js.map +1 -1
  37. package/lib/commonjs/components/Modals/FilePreviewModal/PdfView.js +2 -1
  38. package/lib/commonjs/components/Modals/FilePreviewModal/PdfView.js.map +1 -1
  39. package/lib/commonjs/components/Modals/Modal/Modal.js +8 -0
  40. package/lib/commonjs/components/Modals/Modal/Modal.js.map +1 -1
  41. package/lib/commonjs/components/Modals/NewChatModal/ModalContent.js +2 -1
  42. package/lib/commonjs/components/Modals/NewChatModal/ModalContent.js.map +1 -1
  43. package/lib/commonjs/components/Modals/NewChatModal/NewChatModal.js +202 -106
  44. package/lib/commonjs/components/Modals/NewChatModal/NewChatModal.js.map +1 -1
  45. package/lib/commonjs/components/Modals/NewChatModal/UpdNewChatModal.js +8 -0
  46. package/lib/commonjs/components/Modals/NewChatModal/UpdNewChatModal.js.map +1 -1
  47. package/lib/commonjs/components/Modals/ProfileHeader/ProfileHeader.js +563 -0
  48. package/lib/commonjs/components/Modals/ProfileHeader/ProfileHeader.js.map +1 -0
  49. package/lib/commonjs/components/Modals/ProfileHeader/ProfileMenu.js +210 -0
  50. package/lib/commonjs/components/Modals/ProfileHeader/ProfileMenu.js.map +1 -0
  51. package/lib/commonjs/components/Modals/SelectUsersModal/SelectUsersModal.js +4 -2
  52. package/lib/commonjs/components/Modals/SelectUsersModal/SelectUsersModal.js.map +1 -1
  53. package/lib/commonjs/components/Modals/UserProfileModal/EditUserModal.js +7 -21
  54. package/lib/commonjs/components/Modals/UserProfileModal/EditUserModal.js.map +1 -1
  55. package/lib/commonjs/components/Modals/UserProfileModal/UserProfileModal.js +507 -244
  56. package/lib/commonjs/components/Modals/UserProfileModal/UserProfileModal.js.map +1 -1
  57. package/lib/commonjs/components/Modals/UserSettingsModal/UserSettingsModal.js +74 -46
  58. package/lib/commonjs/components/Modals/UserSettingsModal/UserSettingsModal.js.map +1 -1
  59. package/lib/commonjs/components/Modals/styledModalComponents.js +9 -2
  60. package/lib/commonjs/components/Modals/styledModalComponents.js.map +1 -1
  61. package/lib/commonjs/components/RoomComponents/ChatRoomItem.js +21 -7
  62. package/lib/commonjs/components/RoomComponents/ChatRoomItem.js.map +1 -1
  63. package/lib/commonjs/components/RoomComponents/styled/LastMessageFile.js +22 -3
  64. package/lib/commonjs/components/RoomComponents/styled/LastMessageFile.js.map +1 -1
  65. package/lib/commonjs/components/RoomComponents/styled/LastMessagePhoto.js +17 -3
  66. package/lib/commonjs/components/RoomComponents/styled/LastMessagePhoto.js.map +1 -1
  67. package/lib/commonjs/components/RoomComponents/styled/LastMessageVideo.js +17 -3
  68. package/lib/commonjs/components/RoomComponents/styled/LastMessageVideo.js.map +1 -1
  69. package/lib/commonjs/components/VideoCalls/VideoCallSession.js +6 -3
  70. package/lib/commonjs/components/VideoCalls/VideoCallSession.js.map +1 -1
  71. package/lib/commonjs/components/styled/AudioMessage.js +2 -1
  72. package/lib/commonjs/components/styled/AudioMessage.js.map +1 -1
  73. package/lib/commonjs/components/styled/MessageImage.js +37 -9
  74. package/lib/commonjs/components/styled/MessageImage.js.map +1 -1
  75. package/lib/commonjs/components/styled/SendInput.js +80 -11
  76. package/lib/commonjs/components/styled/SendInput.js.map +1 -1
  77. package/lib/commonjs/components/styled/StyledComponents.js +9 -3
  78. package/lib/commonjs/components/styled/StyledComponents.js.map +1 -1
  79. package/lib/commonjs/components/styled/StyledInputComponents/StyledInputComponents.js +11 -4
  80. package/lib/commonjs/components/styled/StyledInputComponents/StyledInputComponents.js.map +1 -1
  81. package/lib/commonjs/components/styled/UnsupportedType.js +14 -4
  82. package/lib/commonjs/components/styled/UnsupportedType.js.map +1 -1
  83. package/lib/commonjs/components/styled/VideoMessage.js +119 -61
  84. package/lib/commonjs/components/styled/VideoMessage.js.map +1 -1
  85. package/lib/commonjs/context/xmppProvider.js +184 -59
  86. package/lib/commonjs/context/xmppProvider.js.map +1 -1
  87. package/lib/commonjs/helpers/createMessageFromXml.js +19 -1
  88. package/lib/commonjs/helpers/createMessageFromXml.js.map +1 -1
  89. package/lib/commonjs/helpers/ensureScopedChatCache.js +2 -2
  90. package/lib/commonjs/helpers/ensureScopedChatCache.js.map +1 -1
  91. package/lib/commonjs/helpers/getChatBackground.js +23 -0
  92. package/lib/commonjs/helpers/getChatBackground.js.map +1 -0
  93. package/lib/commonjs/helpers/getDisplayFileName.js +79 -0
  94. package/lib/commonjs/helpers/getDisplayFileName.js.map +1 -0
  95. package/lib/commonjs/helpers/getServerReadTimestamp.js +188 -0
  96. package/lib/commonjs/helpers/getServerReadTimestamp.js.map +1 -0
  97. package/lib/commonjs/helpers/historyPreloadScheduler.js +65 -2
  98. package/lib/commonjs/helpers/historyPreloadScheduler.js.map +1 -1
  99. package/lib/commonjs/helpers/initXmppRooms.js +14 -8
  100. package/lib/commonjs/helpers/initXmppRooms.js.map +1 -1
  101. package/lib/commonjs/helpers/insertMessageWithDelimiter.js +51 -9
  102. package/lib/commonjs/helpers/insertMessageWithDelimiter.js.map +1 -1
  103. package/lib/commonjs/helpers/isOwnMessage.js +75 -0
  104. package/lib/commonjs/helpers/isOwnMessage.js.map +1 -0
  105. package/lib/commonjs/helpers/keyboardLayout.js +12 -2
  106. package/lib/commonjs/helpers/keyboardLayout.js.map +1 -1
  107. package/lib/commonjs/helpers/mediaLibraryRuntime.js +31 -0
  108. package/lib/commonjs/helpers/mediaLibraryRuntime.js.map +1 -0
  109. package/lib/commonjs/helpers/mimeToExtension.js +6 -14
  110. package/lib/commonjs/helpers/mimeToExtension.js.map +1 -1
  111. package/lib/commonjs/helpers/msgSortableMs.js +37 -0
  112. package/lib/commonjs/helpers/msgSortableMs.js.map +1 -0
  113. package/lib/commonjs/helpers/persistCrypto.js +122 -0
  114. package/lib/commonjs/helpers/persistCrypto.js.map +1 -0
  115. package/lib/commonjs/helpers/pickImageAsset.js +68 -0
  116. package/lib/commonjs/helpers/pickImageAsset.js.map +1 -0
  117. package/lib/commonjs/helpers/pushPayload.js +71 -0
  118. package/lib/commonjs/helpers/pushPayload.js.map +1 -0
  119. package/lib/commonjs/helpers/resolveInitBeforeLoadUser.js +130 -17
  120. package/lib/commonjs/helpers/resolveInitBeforeLoadUser.js.map +1 -1
  121. package/lib/commonjs/helpers/secureFileUrl.js +101 -0
  122. package/lib/commonjs/helpers/secureFileUrl.js.map +1 -0
  123. package/lib/commonjs/helpers/secureKeyValue.js +83 -0
  124. package/lib/commonjs/helpers/secureKeyValue.js.map +1 -0
  125. package/lib/commonjs/helpers/secureStoreRuntime.js +59 -0
  126. package/lib/commonjs/helpers/secureStoreRuntime.js.map +1 -0
  127. package/lib/commonjs/helpers/secureUserStorage.js +75 -0
  128. package/lib/commonjs/helpers/secureUserStorage.js.map +1 -0
  129. package/lib/commonjs/helpers/shallowEqual.js +36 -0
  130. package/lib/commonjs/helpers/shallowEqual.js.map +1 -0
  131. package/lib/commonjs/helpers/sheetGestures.js +32 -0
  132. package/lib/commonjs/helpers/sheetGestures.js.map +1 -0
  133. package/lib/commonjs/hooks/useChatRoomFocus.js +45 -12
  134. package/lib/commonjs/hooks/useChatRoomFocus.js.map +1 -1
  135. package/lib/commonjs/hooks/useChatWrapperInit.js +30 -10
  136. package/lib/commonjs/hooks/useChatWrapperInit.js.map +1 -1
  137. package/lib/commonjs/hooks/useComposing.js +27 -0
  138. package/lib/commonjs/hooks/useComposing.js.map +1 -1
  139. package/lib/commonjs/hooks/useFileToken.js +10 -0
  140. package/lib/commonjs/hooks/useFileToken.js.map +1 -0
  141. package/lib/commonjs/hooks/useLogout.js +23 -7
  142. package/lib/commonjs/hooks/useLogout.js.map +1 -1
  143. package/lib/commonjs/hooks/usePendingNotification.js +8 -11
  144. package/lib/commonjs/hooks/usePendingNotification.js.map +1 -1
  145. package/lib/commonjs/hooks/useSendMessage.js +50 -14
  146. package/lib/commonjs/hooks/useSendMessage.js.map +1 -1
  147. package/lib/commonjs/hooks/useUnreadMessagesCounter.js +6 -1
  148. package/lib/commonjs/hooks/useUnreadMessagesCounter.js.map +1 -1
  149. package/lib/commonjs/i18n/strings.js +145 -37
  150. package/lib/commonjs/i18n/strings.js.map +1 -1
  151. package/lib/commonjs/main.js +44 -0
  152. package/lib/commonjs/main.js.map +1 -1
  153. package/lib/commonjs/networking/api-requests/auth.api.js +134 -60
  154. package/lib/commonjs/networking/api-requests/auth.api.js.map +1 -1
  155. package/lib/commonjs/networking/api-requests/roomMembers.api.js +1 -1
  156. package/lib/commonjs/networking/api-requests/roomMembers.api.js.map +1 -1
  157. package/lib/commonjs/networking/api-requests/rooms.api.js +9 -9
  158. package/lib/commonjs/networking/api-requests/rooms.api.js.map +1 -1
  159. package/lib/commonjs/networking/api-requests/user.api.js +68 -9
  160. package/lib/commonjs/networking/api-requests/user.api.js.map +1 -1
  161. package/lib/commonjs/networking/apiClient.js +62 -112
  162. package/lib/commonjs/networking/apiClient.js.map +1 -1
  163. package/lib/commonjs/networking/authRefresh.js +332 -0
  164. package/lib/commonjs/networking/authRefresh.js.map +1 -0
  165. package/lib/commonjs/networking/stanzaHandlers.js +41 -28
  166. package/lib/commonjs/networking/stanzaHandlers.js.map +1 -1
  167. package/lib/commonjs/networking/xmpp/flushLastViewedToPrivateStore.js +46 -8
  168. package/lib/commonjs/networking/xmpp/flushLastViewedToPrivateStore.js.map +1 -1
  169. package/lib/commonjs/networking/xmpp/presenceInRoom.xmpp.js +8 -1
  170. package/lib/commonjs/networking/xmpp/presenceInRoom.xmpp.js.map +1 -1
  171. package/lib/commonjs/networking/xmpp/subscribeToRoomMessages.xmpp.js +5 -1
  172. package/lib/commonjs/networking/xmpp/subscribeToRoomMessages.xmpp.js.map +1 -1
  173. package/lib/commonjs/networking/xmppClient.js +124 -8
  174. package/lib/commonjs/networking/xmppClient.js.map +1 -1
  175. package/lib/commonjs/roomStore/chatSettingsSlice.js +26 -7
  176. package/lib/commonjs/roomStore/chatSettingsSlice.js.map +1 -1
  177. package/lib/commonjs/roomStore/index.js +35 -2
  178. package/lib/commonjs/roomStore/index.js.map +1 -1
  179. package/lib/commonjs/roomStore/persistence.js +226 -23
  180. package/lib/commonjs/roomStore/persistence.js.map +1 -1
  181. package/lib/commonjs/roomStore/roomsSlice.js +151 -38
  182. package/lib/commonjs/roomStore/roomsSlice.js.map +1 -1
  183. package/lib/commonjs/services/pushSubscriptionService.js +15 -13
  184. package/lib/commonjs/services/pushSubscriptionService.js.map +1 -1
  185. package/lib/commonjs/version.js +1 -1
  186. package/lib/module/assets/icons.js +6 -1
  187. package/lib/module/assets/icons.js.map +1 -1
  188. package/lib/module/components/AuthForms/Login.js +4 -4
  189. package/lib/module/components/AuthForms/Login.js.map +1 -1
  190. package/lib/module/components/Header/HeaderRoomList.js +29 -8
  191. package/lib/module/components/Header/HeaderRoomList.js.map +1 -1
  192. package/lib/module/components/MainComponents/ChatHeader.js +9 -3
  193. package/lib/module/components/MainComponents/ChatHeader.js.map +1 -1
  194. package/lib/module/components/MainComponents/ChatRoom.js +152 -16
  195. package/lib/module/components/MainComponents/ChatRoom.js.map +1 -1
  196. package/lib/module/components/MainComponents/ChatWrapper.js +35 -14
  197. package/lib/module/components/MainComponents/ChatWrapper.js.map +1 -1
  198. package/lib/module/components/MainComponents/LoginWrapper.js +2 -1
  199. package/lib/module/components/MainComponents/LoginWrapper.js.map +1 -1
  200. package/lib/module/components/MainComponents/MediaMessage.js +30 -10
  201. package/lib/module/components/MainComponents/MediaMessage.js.map +1 -1
  202. package/lib/module/components/MainComponents/MessageContainer.js +5 -1
  203. package/lib/module/components/MainComponents/MessageContainer.js.map +1 -1
  204. package/lib/module/components/MainComponents/MessageList.js +13 -5
  205. package/lib/module/components/MainComponents/MessageList.js.map +1 -1
  206. package/lib/module/components/MainComponents/ProfileImagePlaceholder.js +14 -13
  207. package/lib/module/components/MainComponents/ProfileImagePlaceholder.js.map +1 -1
  208. package/lib/module/components/MainComponents/RoomList.js +207 -35
  209. package/lib/module/components/MainComponents/RoomList.js.map +1 -1
  210. package/lib/module/components/Menu/HeaderRoomListMenu.js +319 -101
  211. package/lib/module/components/Menu/HeaderRoomListMenu.js.map +1 -1
  212. package/lib/module/components/Modals/AttachSheet/AttachSheet.js +313 -113
  213. package/lib/module/components/Modals/AttachSheet/AttachSheet.js.map +1 -1
  214. package/lib/module/components/Modals/ChatProfileModal/ChatProfileModal.js +549 -207
  215. package/lib/module/components/Modals/ChatProfileModal/ChatProfileModal.js.map +1 -1
  216. package/lib/module/components/Modals/ChatProfileModal/ReportChatModal.js +223 -0
  217. package/lib/module/components/Modals/ChatProfileModal/ReportChatModal.js.map +1 -0
  218. package/lib/module/components/Modals/FilePreviewModal/FilePreviewModal.js +70 -28
  219. package/lib/module/components/Modals/FilePreviewModal/FilePreviewModal.js.map +1 -1
  220. package/lib/module/components/Modals/FilePreviewModal/PdfView.js +2 -1
  221. package/lib/module/components/Modals/FilePreviewModal/PdfView.js.map +1 -1
  222. package/lib/module/components/Modals/Modal/Modal.js +9 -1
  223. package/lib/module/components/Modals/Modal/Modal.js.map +1 -1
  224. package/lib/module/components/Modals/NewChatModal/ModalContent.js +2 -1
  225. package/lib/module/components/Modals/NewChatModal/ModalContent.js.map +1 -1
  226. package/lib/module/components/Modals/NewChatModal/NewChatModal.js +205 -108
  227. package/lib/module/components/Modals/NewChatModal/NewChatModal.js.map +1 -1
  228. package/lib/module/components/Modals/NewChatModal/UpdNewChatModal.js +8 -0
  229. package/lib/module/components/Modals/NewChatModal/UpdNewChatModal.js.map +1 -1
  230. package/lib/module/components/Modals/ProfileHeader/ProfileHeader.js +555 -0
  231. package/lib/module/components/Modals/ProfileHeader/ProfileHeader.js.map +1 -0
  232. package/lib/module/components/Modals/ProfileHeader/ProfileMenu.js +205 -0
  233. package/lib/module/components/Modals/ProfileHeader/ProfileMenu.js.map +1 -0
  234. package/lib/module/components/Modals/SelectUsersModal/SelectUsersModal.js +4 -2
  235. package/lib/module/components/Modals/SelectUsersModal/SelectUsersModal.js.map +1 -1
  236. package/lib/module/components/Modals/UserProfileModal/EditUserModal.js +9 -23
  237. package/lib/module/components/Modals/UserProfileModal/EditUserModal.js.map +1 -1
  238. package/lib/module/components/Modals/UserProfileModal/UserProfileModal.js +509 -248
  239. package/lib/module/components/Modals/UserProfileModal/UserProfileModal.js.map +1 -1
  240. package/lib/module/components/Modals/UserSettingsModal/UserSettingsModal.js +76 -48
  241. package/lib/module/components/Modals/UserSettingsModal/UserSettingsModal.js.map +1 -1
  242. package/lib/module/components/Modals/styledModalComponents.js +9 -2
  243. package/lib/module/components/Modals/styledModalComponents.js.map +1 -1
  244. package/lib/module/components/RoomComponents/ChatRoomItem.js +21 -7
  245. package/lib/module/components/RoomComponents/ChatRoomItem.js.map +1 -1
  246. package/lib/module/components/RoomComponents/styled/LastMessageFile.js +22 -3
  247. package/lib/module/components/RoomComponents/styled/LastMessageFile.js.map +1 -1
  248. package/lib/module/components/RoomComponents/styled/LastMessagePhoto.js +17 -3
  249. package/lib/module/components/RoomComponents/styled/LastMessagePhoto.js.map +1 -1
  250. package/lib/module/components/RoomComponents/styled/LastMessageVideo.js +17 -3
  251. package/lib/module/components/RoomComponents/styled/LastMessageVideo.js.map +1 -1
  252. package/lib/module/components/VideoCalls/VideoCallSession.js +6 -3
  253. package/lib/module/components/VideoCalls/VideoCallSession.js.map +1 -1
  254. package/lib/module/components/styled/AudioMessage.js +2 -1
  255. package/lib/module/components/styled/AudioMessage.js.map +1 -1
  256. package/lib/module/components/styled/MessageImage.js +37 -9
  257. package/lib/module/components/styled/MessageImage.js.map +1 -1
  258. package/lib/module/components/styled/SendInput.js +81 -12
  259. package/lib/module/components/styled/SendInput.js.map +1 -1
  260. package/lib/module/components/styled/StyledComponents.js +9 -3
  261. package/lib/module/components/styled/StyledComponents.js.map +1 -1
  262. package/lib/module/components/styled/StyledInputComponents/StyledInputComponents.js +11 -4
  263. package/lib/module/components/styled/StyledInputComponents/StyledInputComponents.js.map +1 -1
  264. package/lib/module/components/styled/UnsupportedType.js +14 -4
  265. package/lib/module/components/styled/UnsupportedType.js.map +1 -1
  266. package/lib/module/components/styled/VideoMessage.js +120 -62
  267. package/lib/module/components/styled/VideoMessage.js.map +1 -1
  268. package/lib/module/context/xmppProvider.js +184 -60
  269. package/lib/module/context/xmppProvider.js.map +1 -1
  270. package/lib/module/helpers/createMessageFromXml.js +19 -1
  271. package/lib/module/helpers/createMessageFromXml.js.map +1 -1
  272. package/lib/module/helpers/ensureScopedChatCache.js +2 -2
  273. package/lib/module/helpers/ensureScopedChatCache.js.map +1 -1
  274. package/lib/module/helpers/getChatBackground.js +18 -0
  275. package/lib/module/helpers/getChatBackground.js.map +1 -0
  276. package/lib/module/helpers/getDisplayFileName.js +73 -0
  277. package/lib/module/helpers/getDisplayFileName.js.map +1 -0
  278. package/lib/module/helpers/getServerReadTimestamp.js +181 -0
  279. package/lib/module/helpers/getServerReadTimestamp.js.map +1 -0
  280. package/lib/module/helpers/historyPreloadScheduler.js +66 -3
  281. package/lib/module/helpers/historyPreloadScheduler.js.map +1 -1
  282. package/lib/module/helpers/initXmppRooms.js +14 -8
  283. package/lib/module/helpers/initXmppRooms.js.map +1 -1
  284. package/lib/module/helpers/insertMessageWithDelimiter.js +52 -9
  285. package/lib/module/helpers/insertMessageWithDelimiter.js.map +1 -1
  286. package/lib/module/helpers/isOwnMessage.js +70 -0
  287. package/lib/module/helpers/isOwnMessage.js.map +1 -0
  288. package/lib/module/helpers/keyboardLayout.js +12 -2
  289. package/lib/module/helpers/keyboardLayout.js.map +1 -1
  290. package/lib/module/helpers/mediaLibraryRuntime.js +25 -0
  291. package/lib/module/helpers/mediaLibraryRuntime.js.map +1 -0
  292. package/lib/module/helpers/mimeToExtension.js +6 -13
  293. package/lib/module/helpers/mimeToExtension.js.map +1 -1
  294. package/lib/module/helpers/msgSortableMs.js +32 -0
  295. package/lib/module/helpers/msgSortableMs.js.map +1 -0
  296. package/lib/module/helpers/persistCrypto.js +115 -0
  297. package/lib/module/helpers/persistCrypto.js.map +1 -0
  298. package/lib/module/helpers/pickImageAsset.js +63 -0
  299. package/lib/module/helpers/pickImageAsset.js.map +1 -0
  300. package/lib/module/helpers/pushPayload.js +63 -0
  301. package/lib/module/helpers/pushPayload.js.map +1 -0
  302. package/lib/module/helpers/resolveInitBeforeLoadUser.js +130 -16
  303. package/lib/module/helpers/resolveInitBeforeLoadUser.js.map +1 -1
  304. package/lib/module/helpers/secureFileUrl.js +91 -0
  305. package/lib/module/helpers/secureFileUrl.js.map +1 -0
  306. package/lib/module/helpers/secureKeyValue.js +75 -0
  307. package/lib/module/helpers/secureKeyValue.js.map +1 -0
  308. package/lib/module/helpers/secureStoreRuntime.js +52 -0
  309. package/lib/module/helpers/secureStoreRuntime.js.map +1 -0
  310. package/lib/module/helpers/secureUserStorage.js +72 -0
  311. package/lib/module/helpers/secureUserStorage.js.map +1 -0
  312. package/lib/module/helpers/shallowEqual.js +31 -0
  313. package/lib/module/helpers/shallowEqual.js.map +1 -0
  314. package/lib/module/helpers/sheetGestures.js +26 -0
  315. package/lib/module/helpers/sheetGestures.js.map +1 -0
  316. package/lib/module/hooks/useChatRoomFocus.js +46 -13
  317. package/lib/module/hooks/useChatRoomFocus.js.map +1 -1
  318. package/lib/module/hooks/useChatWrapperInit.js +30 -10
  319. package/lib/module/hooks/useChatWrapperInit.js.map +1 -1
  320. package/lib/module/hooks/useComposing.js +28 -1
  321. package/lib/module/hooks/useComposing.js.map +1 -1
  322. package/lib/module/hooks/useFileToken.js +5 -0
  323. package/lib/module/hooks/useFileToken.js.map +1 -0
  324. package/lib/module/hooks/useLogout.js +23 -7
  325. package/lib/module/hooks/useLogout.js.map +1 -1
  326. package/lib/module/hooks/usePendingNotification.js +8 -11
  327. package/lib/module/hooks/usePendingNotification.js.map +1 -1
  328. package/lib/module/hooks/useSendMessage.js +52 -16
  329. package/lib/module/hooks/useSendMessage.js.map +1 -1
  330. package/lib/module/hooks/useUnreadMessagesCounter.js +6 -1
  331. package/lib/module/hooks/useUnreadMessagesCounter.js.map +1 -1
  332. package/lib/module/i18n/strings.js +145 -37
  333. package/lib/module/i18n/strings.js.map +1 -1
  334. package/lib/module/main.js +14 -2
  335. package/lib/module/main.js.map +1 -1
  336. package/lib/module/networking/api-requests/auth.api.js +131 -59
  337. package/lib/module/networking/api-requests/auth.api.js.map +1 -1
  338. package/lib/module/networking/api-requests/roomMembers.api.js +1 -1
  339. package/lib/module/networking/api-requests/roomMembers.api.js.map +1 -1
  340. package/lib/module/networking/api-requests/rooms.api.js +9 -9
  341. package/lib/module/networking/api-requests/rooms.api.js.map +1 -1
  342. package/lib/module/networking/api-requests/user.api.js +64 -7
  343. package/lib/module/networking/api-requests/user.api.js.map +1 -1
  344. package/lib/module/networking/apiClient.js +61 -113
  345. package/lib/module/networking/apiClient.js.map +1 -1
  346. package/lib/module/networking/authRefresh.js +321 -0
  347. package/lib/module/networking/authRefresh.js.map +1 -0
  348. package/lib/module/networking/stanzaHandlers.js +41 -28
  349. package/lib/module/networking/stanzaHandlers.js.map +1 -1
  350. package/lib/module/networking/xmpp/flushLastViewedToPrivateStore.js +46 -8
  351. package/lib/module/networking/xmpp/flushLastViewedToPrivateStore.js.map +1 -1
  352. package/lib/module/networking/xmpp/presenceInRoom.xmpp.js +8 -1
  353. package/lib/module/networking/xmpp/presenceInRoom.xmpp.js.map +1 -1
  354. package/lib/module/networking/xmpp/subscribeToRoomMessages.xmpp.js +5 -1
  355. package/lib/module/networking/xmpp/subscribeToRoomMessages.xmpp.js.map +1 -1
  356. package/lib/module/networking/xmppClient.js +124 -8
  357. package/lib/module/networking/xmppClient.js.map +1 -1
  358. package/lib/module/roomStore/chatSettingsSlice.js +26 -7
  359. package/lib/module/roomStore/chatSettingsSlice.js.map +1 -1
  360. package/lib/module/roomStore/index.js +37 -4
  361. package/lib/module/roomStore/index.js.map +1 -1
  362. package/lib/module/roomStore/persistence.js +223 -22
  363. package/lib/module/roomStore/persistence.js.map +1 -1
  364. package/lib/module/roomStore/roomsSlice.js +139 -34
  365. package/lib/module/roomStore/roomsSlice.js.map +1 -1
  366. package/lib/module/services/pushSubscriptionService.js +15 -13
  367. package/lib/module/services/pushSubscriptionService.js.map +1 -1
  368. package/lib/module/version.js +1 -1
  369. package/lib/typescript/assets/icons.d.ts +16 -0
  370. package/lib/typescript/assets/icons.d.ts.map +1 -1
  371. package/lib/typescript/components/AuthForms/Login.d.ts.map +1 -1
  372. package/lib/typescript/components/Header/HeaderRoomList.d.ts.map +1 -1
  373. package/lib/typescript/components/MainComponents/ChatHeader.d.ts.map +1 -1
  374. package/lib/typescript/components/MainComponents/ChatRoom.d.ts.map +1 -1
  375. package/lib/typescript/components/MainComponents/ChatWrapper.d.ts.map +1 -1
  376. package/lib/typescript/components/MainComponents/LoginWrapper.d.ts.map +1 -1
  377. package/lib/typescript/components/MainComponents/MediaMessage.d.ts.map +1 -1
  378. package/lib/typescript/components/MainComponents/MessageContainer.d.ts.map +1 -1
  379. package/lib/typescript/components/MainComponents/MessageList.d.ts +10 -1
  380. package/lib/typescript/components/MainComponents/MessageList.d.ts.map +1 -1
  381. package/lib/typescript/components/MainComponents/ProfileImagePlaceholder.d.ts.map +1 -1
  382. package/lib/typescript/components/MainComponents/RoomList.d.ts +7 -0
  383. package/lib/typescript/components/MainComponents/RoomList.d.ts.map +1 -1
  384. package/lib/typescript/components/Menu/HeaderRoomListMenu.d.ts +3 -0
  385. package/lib/typescript/components/Menu/HeaderRoomListMenu.d.ts.map +1 -1
  386. package/lib/typescript/components/Modals/AttachSheet/AttachSheet.d.ts +9 -0
  387. package/lib/typescript/components/Modals/AttachSheet/AttachSheet.d.ts.map +1 -1
  388. package/lib/typescript/components/Modals/ChatProfileModal/ChatProfileModal.d.ts +10 -0
  389. package/lib/typescript/components/Modals/ChatProfileModal/ChatProfileModal.d.ts.map +1 -1
  390. package/lib/typescript/components/Modals/ChatProfileModal/ReportChatModal.d.ts +9 -0
  391. package/lib/typescript/components/Modals/ChatProfileModal/ReportChatModal.d.ts.map +1 -0
  392. package/lib/typescript/components/Modals/FilePreviewModal/FilePreviewModal.d.ts.map +1 -1
  393. package/lib/typescript/components/Modals/FilePreviewModal/PdfView.d.ts.map +1 -1
  394. package/lib/typescript/components/Modals/Modal/Modal.d.ts.map +1 -1
  395. package/lib/typescript/components/Modals/NewChatModal/ModalContent.d.ts +4 -2
  396. package/lib/typescript/components/Modals/NewChatModal/ModalContent.d.ts.map +1 -1
  397. package/lib/typescript/components/Modals/NewChatModal/NewChatModal.d.ts +1 -1
  398. package/lib/typescript/components/Modals/NewChatModal/NewChatModal.d.ts.map +1 -1
  399. package/lib/typescript/components/Modals/NewChatModal/UpdNewChatModal.d.ts.map +1 -1
  400. package/lib/typescript/components/Modals/ProfileHeader/ProfileHeader.d.ts +75 -0
  401. package/lib/typescript/components/Modals/ProfileHeader/ProfileHeader.d.ts.map +1 -0
  402. package/lib/typescript/components/Modals/ProfileHeader/ProfileMenu.d.ts +25 -0
  403. package/lib/typescript/components/Modals/ProfileHeader/ProfileMenu.d.ts.map +1 -0
  404. package/lib/typescript/components/Modals/SelectUsersModal/SelectUsersModal.d.ts +6 -1
  405. package/lib/typescript/components/Modals/SelectUsersModal/SelectUsersModal.d.ts.map +1 -1
  406. package/lib/typescript/components/Modals/UserProfileModal/EditUserModal.d.ts.map +1 -1
  407. package/lib/typescript/components/Modals/UserProfileModal/UserProfileModal.d.ts +16 -0
  408. package/lib/typescript/components/Modals/UserProfileModal/UserProfileModal.d.ts.map +1 -1
  409. package/lib/typescript/components/Modals/UserSettingsModal/UserSettingsModal.d.ts +1 -0
  410. package/lib/typescript/components/Modals/UserSettingsModal/UserSettingsModal.d.ts.map +1 -1
  411. package/lib/typescript/components/Modals/styledModalComponents.d.ts.map +1 -1
  412. package/lib/typescript/components/RoomComponents/ChatRoomItem.d.ts.map +1 -1
  413. package/lib/typescript/components/RoomComponents/styled/LastMessageFile.d.ts +1 -1
  414. package/lib/typescript/components/RoomComponents/styled/LastMessageFile.d.ts.map +1 -1
  415. package/lib/typescript/components/RoomComponents/styled/LastMessagePhoto.d.ts +1 -1
  416. package/lib/typescript/components/RoomComponents/styled/LastMessagePhoto.d.ts.map +1 -1
  417. package/lib/typescript/components/RoomComponents/styled/LastMessageVideo.d.ts +1 -1
  418. package/lib/typescript/components/RoomComponents/styled/LastMessageVideo.d.ts.map +1 -1
  419. package/lib/typescript/components/VideoCalls/VideoCallSession.d.ts.map +1 -1
  420. package/lib/typescript/components/styled/AudioMessage.d.ts.map +1 -1
  421. package/lib/typescript/components/styled/MessageImage.d.ts +14 -0
  422. package/lib/typescript/components/styled/MessageImage.d.ts.map +1 -1
  423. package/lib/typescript/components/styled/SendInput.d.ts.map +1 -1
  424. package/lib/typescript/components/styled/StyledComponents.d.ts.map +1 -1
  425. package/lib/typescript/components/styled/StyledInputComponents/StyledInputComponents.d.ts.map +1 -1
  426. package/lib/typescript/components/styled/UnsupportedType.d.ts.map +1 -1
  427. package/lib/typescript/components/styled/VideoMessage.d.ts +8 -0
  428. package/lib/typescript/components/styled/VideoMessage.d.ts.map +1 -1
  429. package/lib/typescript/context/xmppProvider.d.ts.map +1 -1
  430. package/lib/typescript/helpers/createMessageFromXml.d.ts.map +1 -1
  431. package/lib/typescript/helpers/getChatBackground.d.ts +15 -0
  432. package/lib/typescript/helpers/getChatBackground.d.ts.map +1 -0
  433. package/lib/typescript/helpers/getDisplayFileName.d.ts +49 -0
  434. package/lib/typescript/helpers/getDisplayFileName.d.ts.map +1 -0
  435. package/lib/typescript/helpers/getServerReadTimestamp.d.ts +108 -0
  436. package/lib/typescript/helpers/getServerReadTimestamp.d.ts.map +1 -0
  437. package/lib/typescript/helpers/historyPreloadScheduler.d.ts.map +1 -1
  438. package/lib/typescript/helpers/initXmppRooms.d.ts.map +1 -1
  439. package/lib/typescript/helpers/insertMessageWithDelimiter.d.ts +1 -1
  440. package/lib/typescript/helpers/insertMessageWithDelimiter.d.ts.map +1 -1
  441. package/lib/typescript/helpers/isOwnMessage.d.ts +36 -0
  442. package/lib/typescript/helpers/isOwnMessage.d.ts.map +1 -0
  443. package/lib/typescript/helpers/keyboardLayout.d.ts +5 -1
  444. package/lib/typescript/helpers/keyboardLayout.d.ts.map +1 -1
  445. package/lib/typescript/helpers/mediaLibraryRuntime.d.ts +3 -0
  446. package/lib/typescript/helpers/mediaLibraryRuntime.d.ts.map +1 -0
  447. package/lib/typescript/helpers/mimeToExtension.d.ts +0 -15
  448. package/lib/typescript/helpers/mimeToExtension.d.ts.map +1 -1
  449. package/lib/typescript/helpers/msgSortableMs.d.ts +2 -0
  450. package/lib/typescript/helpers/msgSortableMs.d.ts.map +1 -0
  451. package/lib/typescript/helpers/persistCrypto.d.ts +13 -0
  452. package/lib/typescript/helpers/persistCrypto.d.ts.map +1 -0
  453. package/lib/typescript/helpers/pickImageAsset.d.ts +27 -0
  454. package/lib/typescript/helpers/pickImageAsset.d.ts.map +1 -0
  455. package/lib/typescript/helpers/pushPayload.d.ts +7 -0
  456. package/lib/typescript/helpers/pushPayload.d.ts.map +1 -0
  457. package/lib/typescript/helpers/resolveInitBeforeLoadUser.d.ts.map +1 -1
  458. package/lib/typescript/helpers/secureFileUrl.d.ts +7 -0
  459. package/lib/typescript/helpers/secureFileUrl.d.ts.map +1 -0
  460. package/lib/typescript/helpers/secureKeyValue.d.ts +13 -0
  461. package/lib/typescript/helpers/secureKeyValue.d.ts.map +1 -0
  462. package/lib/typescript/helpers/secureStoreRuntime.d.ts +29 -0
  463. package/lib/typescript/helpers/secureStoreRuntime.d.ts.map +1 -0
  464. package/lib/typescript/helpers/secureUserStorage.d.ts +23 -0
  465. package/lib/typescript/helpers/secureUserStorage.d.ts.map +1 -0
  466. package/lib/typescript/helpers/shallowEqual.d.ts +11 -0
  467. package/lib/typescript/helpers/shallowEqual.d.ts.map +1 -0
  468. package/lib/typescript/helpers/sheetGestures.d.ts +20 -0
  469. package/lib/typescript/helpers/sheetGestures.d.ts.map +1 -0
  470. package/lib/typescript/hooks/useChatRoomFocus.d.ts +4 -1
  471. package/lib/typescript/hooks/useChatRoomFocus.d.ts.map +1 -1
  472. package/lib/typescript/hooks/useChatWrapperInit.d.ts.map +1 -1
  473. package/lib/typescript/hooks/useComposing.d.ts.map +1 -1
  474. package/lib/typescript/hooks/useFileToken.d.ts +2 -0
  475. package/lib/typescript/hooks/useFileToken.d.ts.map +1 -0
  476. package/lib/typescript/hooks/useLogout.d.ts.map +1 -1
  477. package/lib/typescript/hooks/usePendingNotification.d.ts.map +1 -1
  478. package/lib/typescript/hooks/useSendMessage.d.ts.map +1 -1
  479. package/lib/typescript/hooks/useUnreadMessagesCounter.d.ts +1 -0
  480. package/lib/typescript/hooks/useUnreadMessagesCounter.d.ts.map +1 -1
  481. package/lib/typescript/i18n/strings.d.ts.map +1 -1
  482. package/lib/typescript/main.d.ts +9 -2
  483. package/lib/typescript/main.d.ts.map +1 -1
  484. package/lib/typescript/networking/api-requests/auth.api.d.ts +3 -1
  485. package/lib/typescript/networking/api-requests/auth.api.d.ts.map +1 -1
  486. package/lib/typescript/networking/api-requests/user.api.d.ts +27 -0
  487. package/lib/typescript/networking/api-requests/user.api.d.ts.map +1 -1
  488. package/lib/typescript/networking/apiClient.d.ts +12 -6
  489. package/lib/typescript/networking/apiClient.d.ts.map +1 -1
  490. package/lib/typescript/networking/authRefresh.d.ts +95 -0
  491. package/lib/typescript/networking/authRefresh.d.ts.map +1 -0
  492. package/lib/typescript/networking/stanzaHandlers.d.ts.map +1 -1
  493. package/lib/typescript/networking/xmpp/flushLastViewedToPrivateStore.d.ts +10 -2
  494. package/lib/typescript/networking/xmpp/flushLastViewedToPrivateStore.d.ts.map +1 -1
  495. package/lib/typescript/networking/xmpp/presenceInRoom.xmpp.d.ts.map +1 -1
  496. package/lib/typescript/networking/xmpp/subscribeToRoomMessages.xmpp.d.ts.map +1 -1
  497. package/lib/typescript/networking/xmppClient.d.ts +14 -0
  498. package/lib/typescript/networking/xmppClient.d.ts.map +1 -1
  499. package/lib/typescript/roomStore/chatSettingsSlice.d.ts +16 -0
  500. package/lib/typescript/roomStore/chatSettingsSlice.d.ts.map +1 -1
  501. package/lib/typescript/roomStore/index.d.ts.map +1 -1
  502. package/lib/typescript/roomStore/persistence.d.ts +18 -1
  503. package/lib/typescript/roomStore/persistence.d.ts.map +1 -1
  504. package/lib/typescript/roomStore/roomsSlice.d.ts +43 -3
  505. package/lib/typescript/roomStore/roomsSlice.d.ts.map +1 -1
  506. package/lib/typescript/services/pushSubscriptionService.d.ts +1 -1
  507. package/lib/typescript/services/pushSubscriptionService.d.ts.map +1 -1
  508. package/lib/typescript/types/types.d.ts +50 -5
  509. package/lib/typescript/types/types.d.ts.map +1 -1
  510. package/lib/typescript/version.d.ts +1 -1
  511. package/package.json +41 -28
  512. package/src/assets/icons.tsx +48 -9
  513. package/src/components/AuthForms/Login.tsx +3 -3
  514. package/src/components/Header/HeaderRoomList.tsx +29 -7
  515. package/src/components/MainComponents/ChatHeader.tsx +9 -3
  516. package/src/components/MainComponents/ChatRoom.tsx +161 -15
  517. package/src/components/MainComponents/ChatWrapper.tsx +36 -20
  518. package/src/components/MainComponents/LoginWrapper.tsx +1 -0
  519. package/src/components/MainComponents/MediaMessage.tsx +26 -8
  520. package/src/components/MainComponents/MessageContainer.tsx +5 -1
  521. package/src/components/MainComponents/MessageList.tsx +23 -4
  522. package/src/components/MainComponents/ProfileImagePlaceholder.tsx +21 -14
  523. package/src/components/MainComponents/RoomList.tsx +236 -39
  524. package/src/components/Menu/HeaderRoomListMenu.tsx +328 -75
  525. package/src/components/Modals/AttachSheet/AttachSheet.tsx +333 -97
  526. package/src/components/Modals/ChatProfileModal/ChatProfileModal.tsx +600 -282
  527. package/src/components/Modals/ChatProfileModal/ReportChatModal.tsx +244 -0
  528. package/src/components/Modals/FilePreviewModal/FilePreviewModal.tsx +79 -38
  529. package/src/components/Modals/FilePreviewModal/PdfView.tsx +2 -1
  530. package/src/components/Modals/Modal/Modal.tsx +7 -0
  531. package/src/components/Modals/NewChatModal/ModalContent.tsx +6 -3
  532. package/src/components/Modals/NewChatModal/NewChatModal.tsx +219 -119
  533. package/src/components/Modals/NewChatModal/UpdNewChatModal.tsx +12 -1
  534. package/src/components/Modals/ProfileHeader/ProfileHeader.tsx +624 -0
  535. package/src/components/Modals/ProfileHeader/ProfileMenu.tsx +217 -0
  536. package/src/components/Modals/SelectUsersModal/SelectUsersModal.tsx +14 -4
  537. package/src/components/Modals/UserProfileModal/EditUserModal.tsx +9 -25
  538. package/src/components/Modals/UserProfileModal/UserProfileModal.tsx +617 -307
  539. package/src/components/Modals/UserSettingsModal/UserSettingsModal.tsx +75 -58
  540. package/src/components/Modals/styledModalComponents.tsx +9 -2
  541. package/src/components/RoomComponents/ChatRoomItem.tsx +18 -3
  542. package/src/components/RoomComponents/styled/LastMessageFile.tsx +28 -4
  543. package/src/components/RoomComponents/styled/LastMessagePhoto.tsx +18 -3
  544. package/src/components/RoomComponents/styled/LastMessageVideo.tsx +18 -3
  545. package/src/components/VideoCalls/VideoCallSession.tsx +8 -3
  546. package/src/components/styled/AudioMessage.tsx +2 -1
  547. package/src/components/styled/MessageImage.tsx +53 -7
  548. package/src/components/styled/SendInput.tsx +83 -12
  549. package/src/components/styled/StyledComponents.ts +9 -3
  550. package/src/components/styled/StyledInputComponents/StyledInputComponents.tsx +11 -4
  551. package/src/components/styled/UnsupportedType.tsx +14 -4
  552. package/src/components/styled/VideoMessage.tsx +131 -54
  553. package/src/context/xmppProvider.tsx +216 -57
  554. package/src/helpers/createMessageFromXml.ts +20 -1
  555. package/src/helpers/ensureScopedChatCache.ts +2 -2
  556. package/src/helpers/getChatBackground.ts +18 -0
  557. package/src/helpers/getDisplayFileName.ts +87 -0
  558. package/src/helpers/getServerReadTimestamp.ts +197 -0
  559. package/src/helpers/historyPreloadScheduler.ts +80 -3
  560. package/src/helpers/initXmppRooms.tsx +14 -10
  561. package/src/helpers/insertMessageWithDelimiter.ts +55 -19
  562. package/src/helpers/isOwnMessage.ts +90 -0
  563. package/src/helpers/keyboardLayout.ts +23 -2
  564. package/src/helpers/mediaLibraryRuntime.ts +25 -0
  565. package/src/helpers/mimeToExtension.ts +6 -22
  566. package/src/helpers/msgSortableMs.ts +25 -0
  567. package/src/helpers/persistCrypto.ts +127 -0
  568. package/src/helpers/pickImageAsset.ts +68 -0
  569. package/src/helpers/pushPayload.ts +62 -0
  570. package/src/helpers/resolveInitBeforeLoadUser.ts +125 -18
  571. package/src/helpers/secureFileUrl.ts +103 -0
  572. package/src/helpers/secureKeyValue.ts +80 -0
  573. package/src/helpers/secureStoreRuntime.ts +62 -0
  574. package/src/helpers/secureUserStorage.ts +80 -0
  575. package/src/helpers/shallowEqual.ts +33 -0
  576. package/src/helpers/sheetGestures.ts +25 -0
  577. package/src/hooks/useChatRoomFocus.ts +49 -9
  578. package/src/hooks/useChatWrapperInit.ts +30 -10
  579. package/src/hooks/useComposing.tsx +37 -1
  580. package/src/hooks/useFileToken.ts +7 -0
  581. package/src/hooks/useLogout.tsx +29 -9
  582. package/src/hooks/usePendingNotification.ts +5 -11
  583. package/src/hooks/useSendMessage.tsx +60 -15
  584. package/src/hooks/useUnreadMessagesCounter.ts +11 -0
  585. package/src/i18n/strings.ts +145 -37
  586. package/src/main.ts +26 -2
  587. package/src/networking/api-requests/auth.api.ts +156 -48
  588. package/src/networking/api-requests/roomMembers.api.ts +1 -1
  589. package/src/networking/api-requests/rooms.api.ts +9 -9
  590. package/src/networking/api-requests/user.api.ts +79 -7
  591. package/src/networking/apiClient.ts +68 -123
  592. package/src/networking/authRefresh.ts +451 -0
  593. package/src/networking/stanzaHandlers.ts +44 -28
  594. package/src/networking/xmpp/flushLastViewedToPrivateStore.ts +71 -10
  595. package/src/networking/xmpp/presenceInRoom.xmpp.ts +6 -1
  596. package/src/networking/xmpp/subscribeToRoomMessages.xmpp.ts +12 -1
  597. package/src/networking/xmppClient.ts +141 -9
  598. package/src/roomStore/chatSettingsSlice.ts +34 -10
  599. package/src/roomStore/index.ts +40 -4
  600. package/src/roomStore/persistence.ts +234 -24
  601. package/src/roomStore/roomsSlice.ts +161 -29
  602. package/src/services/pushSubscriptionService.ts +18 -13
  603. package/src/types/types.ts +72 -5
  604. package/src/version.ts +1 -1
@@ -0,0 +1,75 @@
1
+ /** @format */
2
+ import React from 'react';
3
+ import { Animated, StyleProp, TextStyle } from 'react-native';
4
+ /** Height of the expanded photo hero. */
5
+ export declare const HERO_HEIGHT = 320;
6
+ /** Back / "…" row, directly below the status-bar inset. */
7
+ export declare const TOP_BAR_BUTTONS = 60;
8
+ /**
9
+ * Avatar + name row underneath it, revealed as the header collapses.
10
+ * Taller than the 48pt avatar it holds, so the row breathes: the extra
11
+ * height splits evenly above and below (the row centres its content),
12
+ * putting real space between the avatar and both the buttons above and
13
+ * the content below.
14
+ */
15
+ export declare const TOP_BAR_NAME = 92;
16
+ /** Content band of the collapsed bar, below the status-bar inset. */
17
+ export declare const TOP_BAR_BAND: number;
18
+ /** True when the frosted-glass layer is the real thing, not the dim. */
19
+ export declare const hasNativeBlur: () => boolean;
20
+ export interface HeroAction {
21
+ key: string;
22
+ label: string;
23
+ /** Rendered inside a circle tinted for the current background. */
24
+ icon: (color: string) => React.ReactNode;
25
+ onPress: () => void;
26
+ }
27
+ interface CommonProps {
28
+ title: string;
29
+ subtitle?: string;
30
+ imageUri?: string | null;
31
+ /** Background when the chat has no picture — one flat colour, no scrims. */
32
+ fallbackColor: string;
33
+ /** Two uppercase letters shown on that background. */
34
+ initials: string;
35
+ scrollY: Animated.Value;
36
+ /** Prefixes every testID, so each screen's tests address their own. */
37
+ testIDPrefix?: string;
38
+ }
39
+ /** Everything the screen needs to line its scroll content up with the bar. */
40
+ export declare const useHeaderMetrics: () => {
41
+ insets: import("react-native-safe-area-context").EdgeInsets;
42
+ barHeight: number;
43
+ /** Scroll distance between the expanded hero and the collapsed bar. */
44
+ collapseDistance: number;
45
+ };
46
+ /**
47
+ * The chat picture, blown up to a full-bleed hero with the name, member
48
+ * count and the round action buttons on top of it.
49
+ *
50
+ * It lives INSIDE the ScrollView (rather than behind it) so the action
51
+ * buttons stay tappable — an absolutely-positioned hero would sit under a
52
+ * full-screen scroll surface that swallows every touch. Parallax is done
53
+ * on the inner image instead: the wrapper keeps its layout height while
54
+ * the picture drifts at ~⅓ of the scroll speed, and over-scrolling
55
+ * upwards scales it up the way iOS profile headers do.
56
+ */
57
+ export declare const ProfileHero: React.FC<CommonProps & {
58
+ actions: HeroAction[];
59
+ /** Rendered to the right of the name (the profile's Leave button). */
60
+ titleAccessory?: React.ReactNode;
61
+ titleStyle?: StyleProp<TextStyle>;
62
+ subtitleStyle?: StyleProp<TextStyle>;
63
+ }>;
64
+ /**
65
+ * The bar pinned over the hero: back button and the "…" menu are always
66
+ * there, while the frosted picture, small avatar and name fade in as the
67
+ * hero scrolls away — the collapsed state from the design's third screen.
68
+ */
69
+ export declare const ProfileTopBar: React.FC<CommonProps & {
70
+ onBack: () => void;
71
+ menu?: React.ReactNode;
72
+ titleStyle?: StyleProp<TextStyle>;
73
+ }>;
74
+ export {};
75
+ //# sourceMappingURL=ProfileHeader.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ProfileHeader.d.ts","sourceRoot":"","sources":["../../../../../src/components/Modals/ProfileHeader/ProfileHeader.tsx"],"names":[],"mappings":"AAAA,cAAc;AAEd,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EACL,QAAQ,EAER,SAAS,EAGT,SAAS,EAGV,MAAM,cAAc,CAAC;AAKtB,yCAAyC;AACzC,eAAO,MAAM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GAAG;IACZ,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,UAAU,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;CACnC,CAyGF,CAAC"}
@@ -0,0 +1,25 @@
1
+ /** @format */
2
+ import React from 'react';
3
+ export interface ProfileMenuItem {
4
+ key: string;
5
+ label: string;
6
+ icon: React.ReactNode;
7
+ destructive?: boolean;
8
+ onPress: () => void;
9
+ }
10
+ /**
11
+ * The "…" overflow menu shared by the chat and user profile screens.
12
+ *
13
+ * The shared `DropdownMenu` pins its card at a hard-coded `top: 95`, which
14
+ * on this screen landed it over the host's own tab bar, unanchored to the
15
+ * button. This one measures the button and grows the card out of it: the
16
+ * card scales up from its top-right corner (translate → scale → translate
17
+ * back, which is how you fake a transform-origin in React Native) so the
18
+ * menu visibly unfolds from the three dots.
19
+ */
20
+ declare const ProfileMenu: React.FC<{
21
+ items: ProfileMenuItem[];
22
+ testIDPrefix?: string;
23
+ }>;
24
+ export default ProfileMenu;
25
+ //# sourceMappingURL=ProfileMenu.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ProfileMenu.d.ts","sourceRoot":"","sources":["../../../../../src/components/Modals/ProfileHeader/ProfileMenu.tsx"],"names":[],"mappings":"AAAA,cAAc;AAEd,OAAO,KAA2B,MAAM,OAAO,CAAC;AAchD,MAAM,WAAW,eAAe;IAC9B,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,KAAK,CAAC,SAAS,CAAC;IACtB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAUD;;;;;;;;;GASG;AACH,QAAA,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC;IAC1B,KAAK,EAAE,eAAe,EAAE,CAAC;IACzB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB,CA2HA,CAAC;AAgDF,eAAe,WAAW,CAAC"}
@@ -1,4 +1,9 @@
1
1
  import React from 'react';
2
- declare const SelectUsersModal: React.FC;
2
+ interface SelectUsersModalProps {
3
+ /** Render the opener yourself (the chat profile uses an "Add Members"
4
+ * row). Falls back to the plain "Add more Users" button. */
5
+ trigger?: (open: () => void) => React.ReactNode;
6
+ }
7
+ declare const SelectUsersModal: React.FC<SelectUsersModalProps>;
3
8
  export default SelectUsersModal;
4
9
  //# sourceMappingURL=SelectUsersModal.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SelectUsersModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/Modals/SelectUsersModal/SelectUsersModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAmBxC,QAAA,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAgH7B,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
1
+ {"version":3,"file":"SelectUsersModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/Modals/SelectUsersModal/SelectUsersModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAmBxC,UAAU,qBAAqB;IAC7B;gEAC4D;IAC5D,OAAO,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,IAAI,KAAK,KAAK,CAAC,SAAS,CAAC;CACjD;AAED,QAAA,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CAAC,qBAAqB,CAoHrD,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"EditUserModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/Modals/UserProfileModal/EditUserModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AA2BxC,UAAU,kBAAkB;IAC1B,YAAY,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,CAAC;IAC5D,SAAS,EAAE,GAAG,CAAC;IACf,MAAM,EAAE,GAAG,CAAC;CACb;AAED,QAAA,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,CA+H/C,CAAC;AAEF,eAAe,aAAa,CAAC"}
1
+ {"version":3,"file":"EditUserModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/Modals/UserProfileModal/EditUserModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAcxC,UAAU,kBAAkB;IAC1B,YAAY,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,CAAC;IAC5D,SAAS,EAAE,GAAG,CAAC;IACf,MAAM,EAAE,GAAG,CAAC;CACb;AAED,QAAA,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,CA4H/C,CAAC;AAEF,eAAe,aAAa,CAAC"}
@@ -1,4 +1,20 @@
1
+ /** @format */
1
2
  import React from 'react';
3
+ type TabKey = 'language' | 'media' | 'documents';
4
+ /** Two uppercase letters for a person without a picture. */
5
+ export declare const userInitials: (name?: string | null) => string;
6
+ /**
7
+ * Which tabs a profile shows. Only the signed-in user has tabs at all:
8
+ * `GET /v2/files/` returns the JWT owner's files, so there is nothing to
9
+ * put under Media/Documents for anybody else, and the language picker is
10
+ * a personal setting.
11
+ */
12
+ export declare const profileTabs: (opts: {
13
+ isOwnProfile: boolean;
14
+ translatesEnabled: boolean;
15
+ hasMedia: boolean;
16
+ hasDocuments: boolean;
17
+ }) => TabKey[];
2
18
  interface UserProfileModalProps {
3
19
  handleCloseModal: any;
4
20
  }
@@ -1 +1 @@
1
- {"version":3,"file":"UserProfileModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/Modals/UserProfileModal/UserProfileModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoD,MAAM,OAAO,CAAC;AA8CzE,UAAU,qBAAqB;IAC7B,gBAAgB,EAAE,GAAG,CAAC;CACvB;AAED,QAAA,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CAAC,qBAAqB,CA0WrD,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
1
+ {"version":3,"file":"UserProfileModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/Modals/UserProfileModal/UserProfileModal.tsx"],"names":[],"mappings":"AAAA,cAAc;AAEd,OAAO,KAA4D,MAAM,OAAO,CAAC;AA8DjF,KAAK,MAAM,GAAG,UAAU,GAAG,OAAO,GAAG,WAAW,CAAC;AAEjD,4DAA4D;AAC5D,eAAO,MAAM,YAAY,GAAI,OAAO,MAAM,GAAG,IAAI,KAAG,MAOnD,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,WAAW,GAAI,MAAM;IAChC,YAAY,EAAE,OAAO,CAAC;IACtB,iBAAiB,EAAE,OAAO,CAAC;IAC3B,QAAQ,EAAE,OAAO,CAAC;IAClB,YAAY,EAAE,OAAO,CAAC;CACvB,KAAG,MAAM,EAOT,CAAC;AAEF,UAAU,qBAAqB;IAC7B,gBAAgB,EAAE,GAAG,CAAC;CACvB;AAED,QAAA,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CAAC,qBAAqB,CA2erD,CAAC;AAqIF,eAAe,gBAAgB,CAAC"}
@@ -1,3 +1,4 @@
1
+ /** @format */
1
2
  import React from 'react';
2
3
  interface UserSettingsModalProps {
3
4
  handleCloseModal: any;
@@ -1 +1 @@
1
- {"version":3,"file":"UserSettingsModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/Modals/UserSettingsModal/UserSettingsModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA+B,MAAM,OAAO,CAAC;AAgBpD,UAAU,sBAAsB;IAC9B,gBAAgB,EAAE,GAAG,CAAC;CACvB;AAED,QAAA,MAAM,iBAAiB,EAAE,KAAK,CAAC,EAAE,CAAC,sBAAsB,CA8DvD,CAAC;AAEF,eAAe,iBAAiB,CAAC"}
1
+ {"version":3,"file":"UserSettingsModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/Modals/UserSettingsModal/UserSettingsModal.tsx"],"names":[],"mappings":"AAAA,cAAc;AAEd,OAAO,KAA+B,MAAM,OAAO,CAAC;AAYpD,UAAU,sBAAsB;IAC9B,gBAAgB,EAAE,GAAG,CAAC;CACvB;AAED,QAAA,MAAM,iBAAiB,EAAE,KAAK,CAAC,EAAE,CAAC,sBAAsB,CAgDvD,CAAC;AAmCF,eAAe,iBAAiB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"styledModalComponents.d.ts","sourceRoot":"","sources":["../../../../src/components/Modals/styledModalComponents.tsx"],"names":[],"mappings":"AAAA,cAAc;AAKd,eAAO,MAAM,eAAe,iPAQ3B,CAAC;AAEF,eAAO,MAAM,WAAW,mYAQvB,CAAC;AAEF,eAAO,MAAM,cAAc,iPAa1B,CAAC;AAEF,eAAO,MAAM,UAAU,iPAItB,CAAC;AAEF,eAAO,MAAM,gBAAgB,iPAI5B,CAAC;AAEF,eAAO,MAAM,cAAc,iPAK1B,CAAC;AAEF,eAAO,MAAM,wBAAwB,iPASpC,CAAC;AAEF,eAAO,MAAM,eAAe,iPAwB3B,CAAC;AAEF,eAAO,MAAM,UAAU,iPAItB,CAAC;AAEF,eAAO,MAAM,WAAW,iPAIvB,CAAC;AAEF,eAAO,MAAM,eAAe;;;;;;oBAK3B,CAAC;AAEF,eAAO,MAAM,YAAY,iPAKxB,CAAC;AAEF,eAAO,MAAM,QAAQ,iPAMpB,CAAC;AAEF,eAAO,MAAM,QAAQ;eACR,MAAM;iBACJ,MAAM;;eADR,MAAM;iBACJ,MAAM;oBAKpB,CAAC;AAEF,eAAO,MAAM,UAAU,iPAItB,CAAC;AAEF,eAAO,MAAM,iBAAiB,iPAO7B,CAAC;AAEF,eAAO,MAAM,SAAS,iPAIrB,CAAC;AAEF,eAAO,MAAM,KAAK,iPAGjB,CAAC;AAEF,eAAO,MAAM,YAAY,6PAExB,CAAC;AAEF,eAAO,MAAM,YAAY,iPAMxB,CAAC;AAEF,eAAO,MAAM,QAAQ,iPAIpB,CAAC;AAEF,eAAO,MAAM,OAAO,iPAInB,CAAC"}
1
+ {"version":3,"file":"styledModalComponents.d.ts","sourceRoot":"","sources":["../../../../src/components/Modals/styledModalComponents.tsx"],"names":[],"mappings":"AAAA,cAAc;AAKd,eAAO,MAAM,eAAe,iPAQ3B,CAAC;AAEF,eAAO,MAAM,WAAW,mYAQvB,CAAC;AAEF,eAAO,MAAM,cAAc,iPAa1B,CAAC;AAEF,eAAO,MAAM,UAAU,iPAItB,CAAC;AAEF,eAAO,MAAM,gBAAgB,iPAI5B,CAAC;AAEF,eAAO,MAAM,cAAc,iPAK1B,CAAC;AAEF,eAAO,MAAM,wBAAwB,iPASpC,CAAC;AAEF,eAAO,MAAM,eAAe,iPA+B3B,CAAC;AAEF,eAAO,MAAM,UAAU,iPAItB,CAAC;AAEF,eAAO,MAAM,WAAW,iPAIvB,CAAC;AAEF,eAAO,MAAM,eAAe;;;;;;oBAK3B,CAAC;AAEF,eAAO,MAAM,YAAY,iPAKxB,CAAC;AAEF,eAAO,MAAM,QAAQ,iPAMpB,CAAC;AAEF,eAAO,MAAM,QAAQ;eACR,MAAM;iBACJ,MAAM;;eADR,MAAM;iBACJ,MAAM;oBAKpB,CAAC;AAEF,eAAO,MAAM,UAAU,iPAItB,CAAC;AAEF,eAAO,MAAM,iBAAiB,iPAO7B,CAAC;AAEF,eAAO,MAAM,SAAS,iPAIrB,CAAC;AAEF,eAAO,MAAM,KAAK,iPAGjB,CAAC;AAEF,eAAO,MAAM,YAAY,6PAExB,CAAC;AAEF,eAAO,MAAM,YAAY,iPAMxB,CAAC;AAEF,eAAO,MAAM,QAAQ,iPAIpB,CAAC;AAEF,eAAO,MAAM,OAAO,iPAInB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"ChatRoomItem.d.ts","sourceRoot":"","sources":["../../../../src/components/RoomComponents/ChatRoomItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA+B,MAAM,OAAO,CAAC;AAIpD,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAcnD,UAAU,iBAAiB;IACzB,IAAI,EAAE,KAAK,CAAC;IACZ,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB;AAED,QAAA,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,iBAAiB,CA2O7C,CAAC;AAEF,eAAe,YAAY,CAAC"}
1
+ {"version":3,"file":"ChatRoomItem.d.ts","sourceRoot":"","sources":["../../../../src/components/RoomComponents/ChatRoomItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA+B,MAAM,OAAO,CAAC;AAMpD,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAcnD,UAAU,iBAAiB;IACzB,IAAI,EAAE,KAAK,CAAC;IACZ,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB;AAED,QAAA,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,iBAAiB,CAwP7C,CAAC;AAEF,eAAe,YAAY,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import { FC } from 'react';
2
2
  import { LastMessage } from '../../../types/types';
3
- interface LastMessageFileProps extends Pick<LastMessage, 'user' | 'originalName' | 'locationPreview'> {
3
+ interface LastMessageFileProps extends Pick<LastMessage, 'user' | 'originalName' | 'fileName' | 'mimetype' | 'locationPreview'> {
4
4
  }
5
5
  declare const LastMessageFile: FC<LastMessageFileProps>;
6
6
  export default LastMessageFile;
@@ -1 +1 @@
1
- {"version":3,"file":"LastMessageFile.d.ts","sourceRoot":"","sources":["../../../../../src/components/RoomComponents/styled/LastMessageFile.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,EAAE,EAAY,MAAM,OAAO,CAAC;AAE5C,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AASnD,UAAU,oBACR,SAAQ,IAAI,CAAC,WAAW,EAAE,MAAM,GAAG,cAAc,GAAG,iBAAiB,CAAC;CAAG;AAK3E,QAAA,MAAM,eAAe,EAAE,EAAE,CAAC,oBAAoB,CAkC7C,CAAC;AAEF,eAAe,eAAe,CAAC"}
1
+ {"version":3,"file":"LastMessageFile.d.ts","sourceRoot":"","sources":["../../../../../src/components/RoomComponents/styled/LastMessageFile.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,EAAE,EAAY,MAAM,OAAO,CAAC;AAE5C,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAgBnD,UAAU,oBACR,SAAQ,IAAI,CACV,WAAW,EACX,MAAM,GAAG,cAAc,GAAG,UAAU,GAAG,UAAU,GAAG,iBAAiB,CACtE;CAAG;AAKN,QAAA,MAAM,eAAe,EAAE,EAAE,CAAC,oBAAoB,CAgD7C,CAAC;AAEF,eAAe,eAAe,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import { FC } from 'react';
2
2
  import { LastMessage } from '../../../types/types';
3
- interface LastMessagePhotoProps extends Pick<LastMessage, 'user' | 'originalName' | 'locationPreview'> {
3
+ interface LastMessagePhotoProps extends Pick<LastMessage, 'user' | 'originalName' | 'fileName' | 'mimetype' | 'locationPreview'> {
4
4
  }
5
5
  declare const LastMessagePhoto: FC<LastMessagePhotoProps>;
6
6
  export default LastMessagePhoto;
@@ -1 +1 @@
1
- {"version":3,"file":"LastMessagePhoto.d.ts","sourceRoot":"","sources":["../../../../../src/components/RoomComponents/styled/LastMessagePhoto.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAElC,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAsBnD,UAAU,qBACR,SAAQ,IAAI,CAAC,WAAW,EAAE,MAAM,GAAG,cAAc,GAAG,iBAAiB,CAAC;CAAG;AAE3E,QAAA,MAAM,gBAAgB,EAAE,EAAE,CAAC,qBAAqB,CAwB/C,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
1
+ {"version":3,"file":"LastMessagePhoto.d.ts","sourceRoot":"","sources":["../../../../../src/components/RoomComponents/styled/LastMessagePhoto.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAIlC,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAuBnD,UAAU,qBACR,SAAQ,IAAI,CACV,WAAW,EACX,MAAM,GAAG,cAAc,GAAG,UAAU,GAAG,UAAU,GAAG,iBAAiB,CACtE;CAAG;AAEN,QAAA,MAAM,gBAAgB,EAAE,EAAE,CAAC,qBAAqB,CAiC/C,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import { FC } from 'react';
2
2
  import { LastMessage } from '../../../types/types';
3
- interface LastMessageVideoProps extends Pick<LastMessage, 'user' | 'location' | 'originalName'> {
3
+ interface LastMessageVideoProps extends Pick<LastMessage, 'user' | 'location' | 'originalName' | 'fileName' | 'mimetype'> {
4
4
  }
5
5
  declare const LastMessageVideo: FC<LastMessageVideoProps>;
6
6
  export default LastMessageVideo;
@@ -1 +1 @@
1
- {"version":3,"file":"LastMessageVideo.d.ts","sourceRoot":"","sources":["../../../../../src/components/RoomComponents/styled/LastMessageVideo.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAElC,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAqCnD,UAAU,qBACR,SAAQ,IAAI,CAAC,WAAW,EAAE,MAAM,GAAG,UAAU,GAAG,cAAc,CAAC;CAAG;AAEpE,QAAA,MAAM,gBAAgB,EAAE,EAAE,CAAC,qBAAqB,CAyB/C,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
1
+ {"version":3,"file":"LastMessageVideo.d.ts","sourceRoot":"","sources":["../../../../../src/components/RoomComponents/styled/LastMessageVideo.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAIlC,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAsCnD,UAAU,qBACR,SAAQ,IAAI,CACV,WAAW,EACX,MAAM,GAAG,UAAU,GAAG,cAAc,GAAG,UAAU,GAAG,UAAU,CAC/D;CAAG;AAEN,QAAA,MAAM,gBAAgB,EAAE,EAAE,CAAC,qBAAqB,CAkC/C,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"VideoCallSession.d.ts","sourceRoot":"","sources":["../../../../src/components/VideoCalls/VideoCallSession.tsx"],"names":[],"mappings":"AAAA,OAAc,EACZ,EAAE,EAMH,MAAM,OAAO,CAAC;AASf,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AA6CnD,MAAM,WAAW,qBAAqB;IACpC,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,CAAC,EAAE,OAAO,GAAG,OAAO,CAAC;IACzB,gEAAgE;IAChE,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,KAAK,CAAC,EAAE,cAAc,CAAC;IACvB,4DAA4D;IAC5D,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,kDAAkD;IAClD,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,2EAA2E;IAC3E,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,6EAA6E;IAC7E,gBAAgB,CAAC,EAAE,MAAM,IAAI,CAAC;IAC9B,WAAW,CAAC,EAAE,MAAM,IAAI,CAAC;IACzB,OAAO,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IACpC,QAAQ,EAAE,MAAM,IAAI,CAAC;CACtB;AAED;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,gBAAgB,EAAE,EAAE,CAAC,qBAAqB,CA+btD,CAAC;AAoIF,eAAe,gBAAgB,CAAC"}
1
+ {"version":3,"file":"VideoCallSession.d.ts","sourceRoot":"","sources":["../../../../src/components/VideoCalls/VideoCallSession.tsx"],"names":[],"mappings":"AAAA,OAAc,EACZ,EAAE,EAMH,MAAM,OAAO,CAAC;AASf,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AA6CnD,MAAM,WAAW,qBAAqB;IACpC,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,CAAC,EAAE,OAAO,GAAG,OAAO,CAAC;IACzB,gEAAgE;IAChE,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,KAAK,CAAC,EAAE,cAAc,CAAC;IACvB,4DAA4D;IAC5D,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,kDAAkD;IAClD,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,2EAA2E;IAC3E,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,6EAA6E;IAC7E,gBAAgB,CAAC,EAAE,MAAM,IAAI,CAAC;IAC9B,WAAW,CAAC,EAAE,MAAM,IAAI,CAAC;IACzB,OAAO,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IACpC,QAAQ,EAAE,MAAM,IAAI,CAAC;CACtB;AAED;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,gBAAgB,EAAE,EAAE,CAAC,qBAAqB,CAoctD,CAAC;AAoIF,eAAe,gBAAgB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"AudioMessage.d.ts","sourceRoot":"","sources":["../../../../src/components/styled/AudioMessage.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AA8B3D,KAAK,iBAAiB,GAAG;IACvB,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC3B,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAqRF,QAAA,MAAM,YAAY,GAAI,4CAKnB,iBAAiB,sBA4dnB,CAAC;AAEF,eAAe,YAAY,CAAC"}
1
+ {"version":3,"file":"AudioMessage.d.ts","sourceRoot":"","sources":["../../../../src/components/styled/AudioMessage.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AA+B3D,KAAK,iBAAiB,GAAG;IACvB,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC3B,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAqRF,QAAA,MAAM,YAAY,GAAI,4CAKnB,iBAAiB,sBA4dnB,CAAC;AAEF,eAAe,YAAY,CAAC"}
@@ -1,8 +1,22 @@
1
1
  import React from 'react';
2
2
  interface CustomMessageImageProps {
3
+ /** Full-size file. Opened in the preview modal, NOT rendered inline. */
3
4
  fileURL: string;
4
5
  fileName: string;
6
+ /**
7
+ * The sender's original file name (bug #40) - kept alongside `fileName`
8
+ * so the preview modal's save/share/download logic can prefer it over
9
+ * the server's stored/hashed name.
10
+ */
11
+ originalName?: string;
5
12
  mimetype: string;
13
+ /**
14
+ * Server-generated thumbnail — what the bubble actually renders, same
15
+ * as the web client. The full-size original can be many megabytes and,
16
+ * for secure uploads, is served from a different (membership-gated)
17
+ * route; rendering it inline is what left the bubbles blank.
18
+ */
19
+ locationPreview?: string;
6
20
  }
7
21
  declare const CustomMessageImage: React.FC<CustomMessageImageProps>;
8
22
  export default CustomMessageImage;
@@ -1 +1 @@
1
- {"version":3,"file":"MessageImage.d.ts","sourceRoot":"","sources":["../../../../src/components/styled/MessageImage.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAenD,UAAU,uBAAuB;IAC/B,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAKD,QAAA,MAAM,kBAAkB,EAAE,KAAK,CAAC,EAAE,CAAC,uBAAuB,CAuEzD,CAAC;AAEF,eAAe,kBAAkB,CAAC"}
1
+ {"version":3,"file":"MessageImage.d.ts","sourceRoot":"","sources":["../../../../src/components/styled/MessageImage.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAoBnD,UAAU,uBAAuB;IAC/B,wEAAwE;IACxE,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB;;;;OAIG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,EAAE,MAAM,CAAC;IACjB;;;;;OAKG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AASD,QAAA,MAAM,kBAAkB,EAAE,KAAK,CAAC,EAAE,CAAC,uBAAuB,CA8FzD,CAAC;AAEF,eAAe,kBAAkB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"SendInput.d.ts","sourceRoot":"","sources":["../../../../src/components/styled/SendInput.tsx"],"names":[],"mappings":"AAAA,cAAc;AAEd,OAAO,KAAmD,MAAM,OAAO,CAAC;AAMxE,OAAO,EAAE,OAAO,EAAa,MAAM,mBAAmB,CAAC;AAgEvD,UAAU,cAAc;IACtB,WAAW,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IACvC,SAAS,EAAE,OAAO,CAAC;I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CAAC;AAEF,eAAO,MAAM,OAAO,iPAWnB,CAAC;AAEF,eAAO,MAAM,iBAAiB;aACnB,OAAO;YACR,MAAM;eACH,MAAM;;aAFR,OAAO;YACR,MAAM;eACH,MAAM;oBAKlB,CAAC;AAEF,eAAO,MAAM,SAAS,2PAErB,CAAC;AAEF,eAAO,MAAM,mBAAmB,iPAK/B,CAAC;AAEF,eAAO,MAAM,WAAW,iPAKvB,CAAC;AAEF,eAAO,MAAM,eAAe,iPAG3B,CAAC;AAEF,eAAO,MAAM,IAAI,iPAIhB,CAAC;AAEF,eAAO,MAAM,YAAY;iBAA8B,MAAM;;iBAAN,MAAM;oBAK5D,CAAC;AAEF,eAAO,MAAM,aAAa,mYAQzB,CAAC;AAEF,eAAO,MAAM,OAAO;cACR,MAAM;WACT,MAAM;iBACA,OAAO;;cAFV,MAAM;WACT,MAAM;iBACA,OAAO;oBAWrB,CAAC;AAEF,eAAO,MAAM,mBAAmB,iPAS/B,CAAC;AAEF,eAAO,MAAM,aAAa;YAAyB,OAAO;;YAAP,OAAO;oBAazD,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"StyledInputComponents.d.ts","sourceRoot":"","sources":["../../../../../src/components/styled/StyledInputComponents/StyledInputComponents.tsx"],"names":[],"mappings":"AAAA,cAAc;AAad,eAAO,MAAM,cAAc;aAA0B,OAAO;;aAAP,OAAO;oBAU3D,CAAC;AAEF,eAAO,MAAM,cAAc,iPAI1B,CAAC;AAEF,eAAO,MAAM,UAAU,mPAItB,CAAC;AAEF,eAAO,MAAM,qBAAqB,iPAKjC,CAAC;AAEF,eAAO,MAAM,YAAY;gBACX,OAAO;YACX,MAAM;eACH,MAAM;iBACJ,MAAM;;gBAHP,OAAO;YACX,MAAM;eACH,MAAM;iBACJ,MAAM;oBAmBpB,CAAC;AAEF,eAAO,MAAM,eAAe,iPAAgB,CAAC;AAE7C,eAAO,MAAM,KAAK,iPAIjB,CAAC;AAEF,eAAO,MAAM,SAAS,iPAIrB,CAAC;AAEF,eAAO,MAAM,iBAAiB,iPAI7B,CAAC;AAEF,eAAO,MAAM,eAAe,iPAK3B,CAAC;AAEF,eAAO,MAAM,oBAAoB,iPAKhC,CAAC;AAEF,eAAO,MAAM,WAAW,iPAUvB,CAAC;AAEF,eAAO,MAAM,QAAQ,mPAGpB,CAAC;AAEF,eAAO,MAAM,YAAY,iPAGxB,CAAC;AAEF,eAAO,MAAM,WAAW,2PAKvB,CAAC;AAEF,eAAO,MAAM,aAAa,2PAMzB,CAAC"}
1
+ {"version":3,"file":"StyledInputComponents.d.ts","sourceRoot":"","sources":["../../../../../src/components/styled/StyledInputComponents/StyledInputComponents.tsx"],"names":[],"mappings":"AAAA,cAAc;AAad,eAAO,MAAM,cAAc;aAA0B,OAAO;;aAAP,OAAO;oBAiB3D,CAAC;AAEF,eAAO,MAAM,cAAc,iPAI1B,CAAC;AAEF,eAAO,MAAM,UAAU,mPAItB,CAAC;AAEF,eAAO,MAAM,qBAAqB,iPAKjC,CAAC;AAEF,eAAO,MAAM,YAAY;gBACX,OAAO;YACX,MAAM;eACH,MAAM;iBACJ,MAAM;;gBAHP,OAAO;YACX,MAAM;eACH,MAAM;iBACJ,MAAM;oBAmBpB,CAAC;AAEF,eAAO,MAAM,eAAe,iPAAgB,CAAC;AAE7C,eAAO,MAAM,KAAK,iPAIjB,CAAC;AAEF,eAAO,MAAM,SAAS,iPAIrB,CAAC;AAEF,eAAO,MAAM,iBAAiB,iPAI7B,CAAC;AAEF,eAAO,MAAM,eAAe,iPAK3B,CAAC;AAEF,eAAO,MAAM,oBAAoB,iPAKhC,CAAC;AAEF,eAAO,MAAM,WAAW,iPAUvB,CAAC;AAEF,eAAO,MAAM,QAAQ,mPAGpB,CAAC;AAEF,eAAO,MAAM,YAAY,iPAGxB,CAAC;AAEF,eAAO,MAAM,WAAW,2PAKvB,CAAC;AAEF,eAAO,MAAM,aAAa,2PAMzB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"UnsupportedType.d.ts","sourceRoot":"","sources":["../../../../src/components/styled/UnsupportedType.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAqB1B,UAAU,iBAAiB;IACzB,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,OAAO,CAAC;IAChB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC3B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,eAAe,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CACnC;AAED,QAAA,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,iBAAiB,CAsH7C,CAAC;AAEF,eAAe,YAAY,CAAC"}
1
+ {"version":3,"file":"UnsupportedType.d.ts","sourceRoot":"","sources":["../../../../src/components/styled/UnsupportedType.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAsB1B,UAAU,iBAAiB;IACzB,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,OAAO,CAAC;IAChB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC3B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,eAAe,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CACnC;AAED,QAAA,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,iBAAiB,CA+H7C,CAAC;AAEF,eAAe,YAAY,CAAC"}
@@ -1,8 +1,16 @@
1
1
  import React from 'react';
2
2
  interface CustomMessageVideoProps {
3
3
  fileName: string;
4
+ /**
5
+ * The sender's original file name (bug #40) - kept alongside `fileName`
6
+ * so the preview modal's save/share/download logic can prefer it over
7
+ * the server's stored/hashed name.
8
+ */
9
+ originalName?: string;
4
10
  fileURL: string;
5
11
  mimetype: string;
12
+ /** The backend-generated poster frame (message.locationPreview). */
13
+ previewURL?: string;
6
14
  }
7
15
  declare const CustomMessageVideo: React.FC<CustomMessageVideoProps>;
8
16
  export default CustomMessageVideo;
@@ -1 +1 @@
1
- {"version":3,"file":"VideoMessage.d.ts","sourceRoot":"","sources":["../../../../src/components/styled/VideoMessage.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAgBnD,UAAU,uBAAuB;IAC/B,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,QAAA,MAAM,kBAAkB,EAAE,KAAK,CAAC,EAAE,CAAC,uBAAuB,CAgEzD,CAAC;AAEF,eAAe,kBAAkB,CAAC"}
1
+ {"version":3,"file":"VideoMessage.d.ts","sourceRoot":"","sources":["../../../../src/components/styled/VideoMessage.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAmBnD,UAAU,uBAAuB;IAC/B,QAAQ,EAAE,MAAM,CAAC;IACjB;;;;OAIG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,oEAAoE;IACpE,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAqGD,QAAA,MAAM,kBAAkB,EAAE,KAAK,CAAC,EAAE,CAAC,uBAAuB,CA+BzD,CAAC;AAEF,eAAe,kBAAkB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"xmppProvider.d.ts","sourceRoot":"","sources":["../../../src/context/xmppProvider.tsx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,MAAM,CAAC;CAC9B;AAED,UAAU,eAAe;IACvB,MAAM,EAAE,UAAU,GAAG,IAAI,CAAC;IAC1B,uBAAuB,EAAE,uBAAuB,CAAC;IACjD,QAAQ,EAAE,QAAQ,CAAC,SAAS,CAAC,CAAC;IAC9B,SAAS,EAAE,CAAC,MAAM,EAAE,UAAU,GAAG,IAAI,KAAK,IAAI,CAAC;IAC/C,gBAAgB,EAAE,CAChB,QAAQ,EAAE,MAAM,EAChB,QAAQ,EAAE,MAAM,EAChB,YAAY,CAAC,EAAE,qBAAqB,KACjC,OAAO,CAAC,UAAU,CAAC,CAAC;CAC1B;AAID,UAAU,iBAAiB;IACzB,QAAQ,EAAE,SAAS,CAAC;IACpB,MAAM,CAAC,EAAE,OAAO,CAAC;IAIjB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAcD,eAAO,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,iBAAiB,CA+0BpD,CAAC;AAEF,eAAO,MAAM,aAAa,uBAkBzB,CAAC;AAEF,iFAAiF;AACjF,wBAAgB,cAAc,SAE7B"}
@@ -1 +1 @@
1
- {"version":3,"file":"createMessageFromXml.d.ts","sourceRoot":"","sources":["../../../src/helpers/createMessageFromXml.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAE1C,UAAU,mBAAoB,SAAQ,QAAQ;IAC5C,CAAC,CAAC,EAAE,MAAM,GAAG,GAAG,CAAC;CAClB;AAED;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,oBAAoB,GAC/B,KAAK,mBAAmB,EACxB,SAAS,GAAG,EACZ,eAAe,MAAM,EACrB,iBAAiB,MAAM,EACvB,oBAAoB,OAAO,KAC1B,OAAO,CAAC,QAAQ,CA0FlB,CAAC"}
1
+ {"version":3,"file":"createMessageFromXml.d.ts","sourceRoot":"","sources":["../../../src/helpers/createMessageFromXml.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAE1C,UAAU,mBAAoB,SAAQ,QAAQ;IAC5C,CAAC,CAAC,EAAE,MAAM,GAAG,GAAG,CAAC;CAClB;AAED;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,oBAAoB,GAC/B,KAAK,mBAAmB,EACxB,SAAS,GAAG,EACZ,eAAe,MAAM,EACrB,iBAAiB,MAAM,EACvB,oBAAoB,OAAO,KAC1B,OAAO,CAAC,QAAQ,CA6GlB,CAAC"}
@@ -0,0 +1,15 @@
1
+ /** @format */
2
+ import type { IConfig } from '../types/types';
3
+ /** Ground behind the conversation, and behind the rounded corners of the
4
+ * header and the composer that sit over it. */
5
+ export declare const DEFAULT_CHAT_BACKGROUND = "#F3F6FC";
6
+ /**
7
+ * One place for the conversation's background colour.
8
+ *
9
+ * The message list has always painted it; the chat container behind it was
10
+ * plain white, which is what made the header's rounded bottom corners and
11
+ * the composer's rounded top corners invisible — the corners revealed the
12
+ * white parent, not the conversation.
13
+ */
14
+ export declare const getChatBackgroundColor: (config?: IConfig) => string;
15
+ //# sourceMappingURL=getChatBackground.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getChatBackground.d.ts","sourceRoot":"","sources":["../../../src/helpers/getChatBackground.ts"],"names":[],"mappings":"AAAA,cAAc;AAEd,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAE9C;+CAC+C;AAC/C,eAAO,MAAM,uBAAuB,YAAY,CAAC;AAEjD;;;;;;;GAOG;AACH,eAAO,MAAM,sBAAsB,GAAI,SAAS,OAAO,KAAG,MACA,CAAC"}
@@ -0,0 +1,49 @@
1
+ export interface DisplayFileNameOptions {
2
+ originalName?: string | null;
3
+ fileName?: string | null;
4
+ location?: string | null;
5
+ mimetype?: string | null;
6
+ }
7
+ /**
8
+ * Picks the best human-readable filename for a chat attachment - the
9
+ * single source of truth for every place a file name is rendered in the
10
+ * UI, saved to disk, shared, or downloaded.
11
+ *
12
+ * Priority: `originalName` (the sender's own file name, e.g. "test1.pdf")
13
+ * beats `fileName` (the server's stored/hashed name, e.g.
14
+ * "3f9a1c...c2.pdf") beats the last path segment of `location`. The
15
+ * stored hash name is only a fallback of last resort.
16
+ *
17
+ * Bug #40: display and save/share/download logic used to prefer the
18
+ * stored hash name over the original one, so an attachment sent as
19
+ * "test1.pdf" showed up (and got saved to the phone) as something like
20
+ * "3f9a1c...c2.pdf" - both directions (web -> RN and RN -> RN).
21
+ *
22
+ * Always returns a non-empty string with a valid extension: if the
23
+ * chosen candidate has no extension (a hash name can be `<hex>` with no
24
+ * extension at all, or `<hex>.<ext>`), one is appended from `mimetype`
25
+ * (or `.bin` as a last resort when the mime is unknown/missing too).
26
+ */
27
+ export declare function getDisplayFileName(options: DisplayFileNameOptions): string;
28
+ /**
29
+ * Makes a display name safe to use as an actual path segment when
30
+ * saving/sharing a file to the device: strips path separators (so an
31
+ * odd/hostile server-provided name can't escape the target directory)
32
+ * and control characters. Keeps the rest of the name - including the
33
+ * extension - intact.
34
+ */
35
+ export declare function sanitizeFileNameForPath(name: string): string;
36
+ /**
37
+ * Resolves a filename that is safe to write into a target directory:
38
+ * sanitizes it, then - if `exists` reports a collision - inserts
39
+ * " (1)", " (2)", ... before the extension until a free name is found,
40
+ * so saving two different attachments that share a display name never
41
+ * silently overwrites the first one.
42
+ *
43
+ * `exists` is injected so callers can back it with whatever existence
44
+ * check makes sense for their storage API (expo-file-system,
45
+ * StorageAccessFramework directory listing, ...) - this function stays
46
+ * pure and easy to unit test.
47
+ */
48
+ export declare function getUniqueFileName(name: string, exists: (candidateName: string) => Promise<boolean>): Promise<string>;
49
+ //# sourceMappingURL=getDisplayFileName.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getDisplayFileName.d.ts","sourceRoot":"","sources":["../../../src/helpers/getDisplayFileName.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,sBAAsB;IACrC,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC1B;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,sBAAsB,GAAG,MAAM,CAO1E;AAED;;;;;;GAMG;AACH,wBAAgB,uBAAuB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAO5D;AAED;;;;;;;;;;;GAWG;AACH,wBAAsB,iBAAiB,CACrC,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,CAAC,aAAa,EAAE,MAAM,KAAK,OAAO,CAAC,OAAO,CAAC,GAClD,OAAO,CAAC,MAAM,CAAC,CAiBjB"}
@@ -0,0 +1,108 @@
1
+ import type { IMessage, IRoom } from '../types/types';
2
+ export declare const FUTURE_READ_MARKER_TOLERANCE_MS: number;
3
+ export interface ReadTimestampHeapState {
4
+ messageHeap?: IMessage[] | null;
5
+ failedMessages?: Record<string, unknown> | null;
6
+ }
7
+ type RoomForReadTimestamp = Pick<IRoom, 'jid' | 'messages' | 'lastViewedTimestamp'>;
8
+ /**
9
+ * Resolve the "read up to here" marker for `room` using SERVER time,
10
+ * never the device clock.
11
+ *
12
+ * Bug #38: if the device clock is ahead when the user leaves a room, a
13
+ * `Date.now()` read marker lands in the future. The private-store merge
14
+ * (flushLastViewedToPrivateStore.ts) is forward-only ("if (prevNum >=
15
+ * ts) continue"), so once a future marker is written, no later
16
+ * *correct* write can ever replace it - the room's unread count is
17
+ * stuck wrong forever, on every device, from that point on. Anchoring
18
+ * to the newest SERVER-acknowledged message's own timestamp instead
19
+ * means the marker we write can never be ahead of what the server
20
+ * itself has recorded for the room.
21
+ *
22
+ * "Server-acknowledged" excludes:
23
+ * - a message still marked `pending` (the optimistic bubble shown
24
+ * while a send is in flight - it carries the DEVICE send time via
25
+ * `date`, not a server timestamp, until the server echoes it back
26
+ * and insertMessageWithDelimiter flips `pending` off);
27
+ * - a message id present in `heapState.messageHeap` (queued retry -
28
+ * used for offline media sends, see roomHeapSlice.ts) or
29
+ * `heapState.failedMessages` (a send that never reached the server
30
+ * at all).
31
+ *
32
+ * `msgSortableMs` (helpers/msgSortableMs.ts) reads the server-assigned microsecond
33
+ * timestamp encoded in the first 13 digits of the message id - the same
34
+ * source already used for message ordering and unread counting - so
35
+ * this stays consistent with the rest of the read/unread pipeline.
36
+ *
37
+ * Falls back to the room's existing `lastViewedTimestamp` (so leaving
38
+ * an empty or never-scrolled room doesn't regress the marker), then to
39
+ * `0` when there's truly nothing to anchor to yet (a brand new room
40
+ * with no history and no prior marker). Callers should treat `0` as
41
+ * "skip the write" rather than substituting a device-clock guess.
42
+ */
43
+ export declare function getServerReadTimestamp(room: RoomForReadTimestamp | null | undefined, heapState?: ReadTimestampHeapState | null): number;
44
+ /**
45
+ * Is `marker` a leftover from a device whose clock was wrong when it
46
+ * stamped a read marker (bug #38)?
47
+ *
48
+ * TWO independent signals must agree before we're willing to throw a
49
+ * stored marker away, because "waive the forward-only guard" is a
50
+ * destructive operation:
51
+ *
52
+ * 1. it sits well past the newest message we know the room has, AND
53
+ * 2. it sits well past real time.
54
+ *
55
+ * Signal 1 alone is NOT enough, and that is the whole point of this
56
+ * function: a device whose local cache for a room is simply stale (very
57
+ * common - any room whose history hasn't been synced yet this session)
58
+ * sees a perfectly legitimate marker written by another device that HAS
59
+ * seen newer messages, and would happily "heal" it backwards, resurrecting
60
+ * already-read messages as unread on every device. A real timestamp can
61
+ * never be ahead of real time, so requiring signal 2 as well means a
62
+ * stale cache on its own can no longer trigger the self-heal.
63
+ *
64
+ * Signal 2 alone is not used either: it would let a device whose own
65
+ * clock is running SLOW mistake every correct marker for a corrupt one.
66
+ */
67
+ export declare function isCorruptFutureReadMarker(marker: number, newestAckedMs: number): boolean;
68
+ /**
69
+ * Resolve the marker to STAMP (locally and to the server) for `room`,
70
+ * honouring an explicit read boundary when one is set.
71
+ *
72
+ * Bug #42 (a regression of #33, reintroduced by #38): #38 made every
73
+ * caller stamp the newest server-acknowledged message unconditionally.
74
+ * That is correct for a user who is at the bottom of the room, but wrong
75
+ * for a user who scrolled up, received messages, and left without
76
+ * scrolling back down - stamping "newest" there silently marks
77
+ * messages they never saw as read, both locally and (because the
78
+ * private-store merge is forward-only) permanently on the server.
79
+ *
80
+ * `boundaryTs` is the msgSortableMs of the newest message the user
81
+ * actually reached (see `readBoundaries` on `RoomMessagesState`,
82
+ * populated by MessageList's `onReadBoundaryChange`). When it's set and
83
+ * positive, it wins - but is still clamped to never exceed the newest
84
+ * server-acknowledged message, so a stale/corrupt boundary can't stamp a
85
+ * marker further ahead than the room's own history supports. When no
86
+ * boundary is set (the common case - the user is at the bottom), this is
87
+ * exactly `getServerReadTimestamp`.
88
+ *
89
+ * Never returns `Date.now()`, directly or indirectly - same rule as
90
+ * `getServerReadTimestamp` (bug #38).
91
+ */
92
+ export declare function getReadMarkerTimestamp(room: RoomForReadTimestamp | null | undefined, heapState?: ReadTimestampHeapState | null, boundaryTs?: number | null): number;
93
+ /**
94
+ * The value to hand `flushLastViewedToPrivateStore` as `visibleRoomTs`
95
+ * for a room being left, or `undefined` when no boundary applies (the
96
+ * flush then uses its own newest-acked default).
97
+ *
98
+ * Exists so the SERVER write goes through the SAME clamp as the local
99
+ * stamp. Passing the raw redux boundary straight through would bypass
100
+ * `getReadMarkerTimestamp`'s clamp on exactly the path where a bad value
101
+ * is permanent: the private-store merge is forward-only, so a boundary
102
+ * that (through a pending own message's device `date`, or a stale
103
+ * readBoundaries entry) sat ahead of the room's real history would be
104
+ * written verbatim and could never be corrected again (bug #38).
105
+ */
106
+ export declare function getFlushBoundaryTs(room: RoomForReadTimestamp | null | undefined, heapState?: ReadTimestampHeapState | null, boundaryTs?: number | null): number | undefined;
107
+ export {};
108
+ //# sourceMappingURL=getServerReadTimestamp.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getServerReadTimestamp.d.ts","sourceRoot":"","sources":["../../../src/helpers/getServerReadTimestamp.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAWtD,eAAO,MAAM,+BAA+B,QAAgB,CAAC;AAE7D,MAAM,WAAW,sBAAsB;IACrC,WAAW,CAAC,EAAE,QAAQ,EAAE,GAAG,IAAI,CAAC;IAChC,cAAc,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,CAAC;CACjD;AAED,KAAK,oBAAoB,GAAG,IAAI,CAAC,KAAK,EAAE,KAAK,GAAG,UAAU,GAAG,qBAAqB,CAAC,CAAC;AAEpF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkCG;AACH,wBAAgB,sBAAsB,CACpC,IAAI,EAAE,oBAAoB,GAAG,IAAI,GAAG,SAAS,EAC7C,SAAS,CAAC,EAAE,sBAAsB,GAAG,IAAI,GACxC,MAAM,CA4BR;AAED;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,wBAAgB,yBAAyB,CACvC,MAAM,EAAE,MAAM,EACd,aAAa,EAAE,MAAM,GACpB,OAAO,CAKT;AAED;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,wBAAgB,sBAAsB,CACpC,IAAI,EAAE,oBAAoB,GAAG,IAAI,GAAG,SAAS,EAC7C,SAAS,CAAC,EAAE,sBAAsB,GAAG,IAAI,EACzC,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,GACzB,MAAM,CAkBR;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,kBAAkB,CAChC,IAAI,EAAE,oBAAoB,GAAG,IAAI,GAAG,SAAS,EAC7C,SAAS,CAAC,EAAE,sBAAsB,GAAG,IAAI,EACzC,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,GACzB,MAAM,GAAG,SAAS,CAUpB"}
@@ -1 +1 @@
1
- {"version":3,"file":"historyPreloadScheduler.d.ts","sourceRoot":"","sources":["../../../src/helpers/historyPreloadScheduler.ts"],"names":[],"mappings":"AACA,OAAO,UAAU,MAAM,0BAA0B,CAAC;AAKlD,UAAU,8BAA8B;IACtC,MAAM,EAAE,UAAU,CAAC;IACnB,MAAM,CAAC,EAAE,WAAW,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,eAAe,CAAC,EAAE,MAAM,EAAE,CAAC;IAC3B,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AA2ED;;;;;GAKG;AACH,eAAO,MAAM,0BAA0B,GACrC,SAAS,8BAA8B,KACtC,OAAO,CAAC,IAAI,CAyLd,CAAC;AAEF,eAAe,0BAA0B,CAAC"}
1
+ {"version":3,"file":"historyPreloadScheduler.d.ts","sourceRoot":"","sources":["../../../src/helpers/historyPreloadScheduler.ts"],"names":[],"mappings":"AACA,OAAO,UAAU,MAAM,0BAA0B,CAAC;AASlD,UAAU,8BAA8B;IACtC,MAAM,EAAE,UAAU,CAAC;IACnB,MAAM,CAAC,EAAE,WAAW,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,eAAe,CAAC,EAAE,MAAM,EAAE,CAAC;IAC3B,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AAkFD;;;;;GAKG;AACH,eAAO,MAAM,0BAA0B,GACrC,SAAS,8BAA8B,KACtC,OAAO,CAAC,IAAI,CA2Pd,CAAC;AAEF,eAAe,0BAA0B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"initXmppRooms.d.ts","sourceRoot":"","sources":["../../../src/helpers/initXmppRooms.tsx"],"names":[],"mappings":"AAGA,OAAO,UAAU,MAAM,0BAA0B,CAAC;AAClD,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAC;AAGtD,QAAA,MAAM,aAAa,GACjB,MAAM,IAAI,EACV,QAAQ,OAAO,EACf,YAAY,UAAU,EACtB,QAAQ;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,KAAK,CAAA;CAAE,EAChC,UAAU,MAAM,kBAwDjB,CAAC;AAEF,eAAe,aAAa,CAAC"}
1
+ {"version":3,"file":"initXmppRooms.d.ts","sourceRoot":"","sources":["../../../src/helpers/initXmppRooms.tsx"],"names":[],"mappings":"AAEA,OAAO,UAAU,MAAM,0BAA0B,CAAC;AAClD,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAC;AAItD,QAAA,MAAM,aAAa,GACjB,MAAM,IAAI,EACV,QAAQ,OAAO,EACf,YAAY,UAAU,EACtB,QAAQ;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,KAAK,CAAA;CAAE,EAChC,UAAU,MAAM,kBA4DjB,CAAC;AAEF,eAAe,aAAa,CAAC"}
@@ -1,5 +1,5 @@
1
1
  import { IMessage } from '../types/types';
2
- export declare function insertMessageWithDelimiter(roomMessages: Partial<IMessage>[], message: IMessage, lastViewedTimestamp: {
2
+ export declare function insertMessageWithDelimiter(roomMessages: Partial<IMessage>[], message: IMessage, lastViewedTimestamp: number | {
3
3
  toString: () => string;
4
4
  } | null): void;
5
5
  //# sourceMappingURL=insertMessageWithDelimiter.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"insertMessageWithDelimiter.d.ts","sourceRoot":"","sources":["../../../src/helpers/insertMessageWithDelimiter.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AA+B1C,wBAAgB,0BAA0B,CACxC,YAAY,EAAE,OAAO,CAAC,QAAQ,CAAC,EAAE,EACjC,OAAO,EAAE,QAAQ,EACjB,mBAAmB,EAAE;IAAE,QAAQ,EAAE,MAAM,MAAM,CAAA;CAAE,GAAG,IAAI,QAmGvD"}
1
+ {"version":3,"file":"insertMessageWithDelimiter.d.ts","sourceRoot":"","sources":["../../../src/helpers/insertMessageWithDelimiter.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AA6D1C,wBAAgB,0BAA0B,CACxC,YAAY,EAAE,OAAO,CAAC,QAAQ,CAAC,EAAE,EACjC,OAAO,EAAE,QAAQ,EACjB,mBAAmB,EAAE,MAAM,GAAG;IAAE,QAAQ,EAAE,MAAM,MAAM,CAAA;CAAE,GAAG,IAAI,QAyGhE"}
@@ -0,0 +1,36 @@
1
+ import { IMessage } from '../types/types';
2
+ /**
3
+ * Bug #41: during reconnect catch-up (app was backgrounded/offline, then
4
+ * comes back online), messages replayed from MAM could transiently render
5
+ * on the RIGHT (as if sent by the current user) before flipping to the
6
+ * LEFT a moment later. Root cause: `message.user.id === walletAddress`
7
+ * treats `undefined === undefined` (or `'' === ''`) as a match, and the
8
+ * two sides could independently be empty for one frame -- the message's
9
+ * sender id before the MAM-derived value settled, and/or the current
10
+ * user's id before it rehydrated. Two blank ids must never compare equal.
11
+ *
12
+ * A second, related issue: the same logical sender id can show up in
13
+ * different shapes depending on which code path produced it -- a bare
14
+ * id ("wallet123") or a bare JID with an incidental session resource
15
+ * ("wallet123@host/sessionResource", as `senderJID` attrs carry on the
16
+ * wire -- see src/assets/test.xml). In every shape used in this
17
+ * codebase the identifying segment is the part BEFORE the first '@' (or
18
+ * before '/' when there's no '@'); anything after that -- domain,
19
+ * resource -- is noise. Comparing raw strings with `===` fails whenever
20
+ * one side still carries that noise and the other doesn't. Normalizing
21
+ * both sides (strip resource, strip domain, lowercase) before comparing
22
+ * makes the check tolerant of that drift.
23
+ */
24
+ export interface OwnMessageUserLike {
25
+ id?: string | null;
26
+ xmppUsername?: string | null;
27
+ walletAddress?: string | null;
28
+ }
29
+ export type OwnMessageCurrentUser = OwnMessageUserLike | string | null | undefined;
30
+ /**
31
+ * Robustly determine whether `message` was sent by `currentUser`. Never
32
+ * returns true from two blank/undefined ids, and tolerates bare-id vs.
33
+ * full-JID mismatches between the sender id and the current user id.
34
+ */
35
+ export declare const isOwnMessage: (message: Pick<IMessage, "user"> | null | undefined, currentUser: OwnMessageCurrentUser) => boolean;
36
+ //# sourceMappingURL=isOwnMessage.d.ts.map