@ethora/chat-component-rn 26.4.2 → 26.5.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 (1680) hide show
  1. package/CHANGELOG.md +89 -0
  2. package/README.md +11 -0
  3. package/lib/commonjs/assets/BG.js +65 -0
  4. package/lib/commonjs/assets/BG.js.map +1 -0
  5. package/lib/commonjs/assets/BG.png +0 -0
  6. package/lib/commonjs/assets/File.svg +4 -0
  7. package/lib/commonjs/assets/ForzaCare.js +40 -0
  8. package/lib/commonjs/assets/ForzaCare.js.map +1 -0
  9. package/lib/commonjs/assets/ForzaCare.png +0 -0
  10. package/lib/commonjs/assets/icons.js +2 -0
  11. package/lib/commonjs/assets/icons.js.map +1 -0
  12. package/lib/commonjs/assets/images.js +45 -0
  13. package/lib/commonjs/assets/images.js.map +1 -0
  14. package/lib/commonjs/assets/test.xml +243 -0
  15. package/lib/commonjs/components/AuthForms/Login.js +285 -0
  16. package/lib/commonjs/components/AuthForms/Login.js.map +1 -0
  17. package/lib/commonjs/components/AuthForms/LoginAnonym.js +69 -0
  18. package/lib/commonjs/components/AuthForms/LoginAnonym.js.map +1 -0
  19. package/lib/commonjs/components/AuthForms/Register.js +17 -0
  20. package/lib/commonjs/components/AuthForms/Register.js.map +1 -0
  21. package/lib/commonjs/components/ContextMenu/ContextMenuComponents.js +87 -0
  22. package/lib/commonjs/components/ContextMenu/ContextMenuComponents.js.map +1 -0
  23. package/lib/commonjs/components/DropdownMenu/DropdownMenu.js +220 -0
  24. package/lib/commonjs/components/DropdownMenu/DropdownMenu.js.map +1 -0
  25. package/lib/commonjs/components/ExampleComponents/CustomMessage.js +90 -0
  26. package/lib/commonjs/components/ExampleComponents/CustomMessage.js.map +1 -0
  27. package/lib/commonjs/components/ExampleComponents/CustomTypingIndicatorExamples.js +273 -0
  28. package/lib/commonjs/components/ExampleComponents/CustomTypingIndicatorExamples.js.map +1 -0
  29. package/lib/commonjs/components/Header/HeaderRoomList.js +117 -0
  30. package/lib/commonjs/components/Header/HeaderRoomList.js.map +1 -0
  31. package/lib/commonjs/components/InputComponents/AudioInput.js +23 -0
  32. package/lib/commonjs/components/InputComponents/AudioInput.js.map +1 -0
  33. package/lib/commonjs/components/InputComponents/AudioRecorder.js +101 -0
  34. package/lib/commonjs/components/InputComponents/AudioRecorder.js.map +1 -0
  35. package/lib/commonjs/components/InputComponents/MediaInput.js +98 -0
  36. package/lib/commonjs/components/InputComponents/MediaInput.js.map +1 -0
  37. package/lib/commonjs/components/InputComponents/RecordingIndicator.js +70 -0
  38. package/lib/commonjs/components/InputComponents/RecordingIndicator.js.map +1 -0
  39. package/lib/commonjs/components/InputComponents/Search.js +112 -0
  40. package/lib/commonjs/components/InputComponents/Search.js.map +1 -0
  41. package/lib/commonjs/components/InputComponents/TextInput.js +62 -0
  42. package/lib/commonjs/components/InputComponents/TextInput.js.map +1 -0
  43. package/lib/commonjs/components/MainComponents/ChatHeader.js +154 -0
  44. package/lib/commonjs/components/MainComponents/ChatHeader.js.map +1 -0
  45. package/lib/commonjs/components/MainComponents/ChatRoom.js +272 -0
  46. package/lib/commonjs/components/MainComponents/ChatRoom.js.map +1 -0
  47. package/lib/commonjs/components/MainComponents/ChatWrapper.js +277 -0
  48. package/lib/commonjs/components/MainComponents/ChatWrapper.js.map +1 -0
  49. package/lib/commonjs/components/MainComponents/ChooseChatMessage.js +46 -0
  50. package/lib/commonjs/components/MainComponents/ChooseChatMessage.js.map +1 -0
  51. package/lib/commonjs/components/MainComponents/ConnectionBanner.js +40 -0
  52. package/lib/commonjs/components/MainComponents/ConnectionBanner.js.map +1 -0
  53. package/lib/commonjs/components/MainComponents/EditWrapper.js +83 -0
  54. package/lib/commonjs/components/MainComponents/EditWrapper.js.map +1 -0
  55. package/lib/commonjs/components/MainComponents/LoginWrapper.js +126 -0
  56. package/lib/commonjs/components/MainComponents/LoginWrapper.js.map +1 -0
  57. package/lib/commonjs/components/MainComponents/MediaMessage.js +67 -0
  58. package/lib/commonjs/components/MainComponents/MediaMessage.js.map +1 -0
  59. package/lib/commonjs/components/MainComponents/MessageContainer.js +86 -0
  60. package/lib/commonjs/components/MainComponents/MessageContainer.js.map +1 -0
  61. package/lib/commonjs/components/MainComponents/MessageList.js +290 -0
  62. package/lib/commonjs/components/MainComponents/MessageList.js.map +1 -0
  63. package/lib/commonjs/components/MainComponents/NoMessagesPlaceholder.js +51 -0
  64. package/lib/commonjs/components/MainComponents/NoMessagesPlaceholder.js.map +1 -0
  65. package/lib/commonjs/components/MainComponents/ProfileImagePlaceholder.js +97 -0
  66. package/lib/commonjs/components/MainComponents/ProfileImagePlaceholder.js.map +1 -0
  67. package/lib/commonjs/components/MainComponents/RNStyled.js +36 -0
  68. package/lib/commonjs/components/MainComponents/RNStyled.js.map +1 -0
  69. package/lib/commonjs/components/MainComponents/ReduxWrapper.js +43 -0
  70. package/lib/commonjs/components/MainComponents/ReduxWrapper.js.map +1 -0
  71. package/lib/commonjs/components/MainComponents/RoomList.js +205 -0
  72. package/lib/commonjs/components/MainComponents/RoomList.js.map +1 -0
  73. package/lib/commonjs/components/MainComponents/Select.js +136 -0
  74. package/lib/commonjs/components/MainComponents/Select.js.map +1 -0
  75. package/lib/commonjs/components/MainComponents/Switch.js +74 -0
  76. package/lib/commonjs/components/MainComponents/Switch.js.map +1 -0
  77. package/lib/commonjs/components/MainComponents/SystemMessage.js +39 -0
  78. package/lib/commonjs/components/MainComponents/SystemMessage.js.map +1 -0
  79. package/lib/commonjs/components/Menu/HeaderRoomListMenu.js +163 -0
  80. package/lib/commonjs/components/Menu/HeaderRoomListMenu.js.map +1 -0
  81. package/lib/commonjs/components/MenuRoom/MenuRoom.js +49 -0
  82. package/lib/commonjs/components/MenuRoom/MenuRoom.js.map +1 -0
  83. package/lib/commonjs/components/MessageBubble/Avatar.js +78 -0
  84. package/lib/commonjs/components/MessageBubble/Avatar.js.map +1 -0
  85. package/lib/commonjs/components/MessageBubble/BottomReplyContainer.js +109 -0
  86. package/lib/commonjs/components/MessageBubble/BottomReplyContainer.js.map +1 -0
  87. package/lib/commonjs/components/MessageBubble/CustomDivider.js +15 -0
  88. package/lib/commonjs/components/MessageBubble/CustomDivider.js.map +1 -0
  89. package/lib/commonjs/components/MessageBubble/DeletedMessage.js +47 -0
  90. package/lib/commonjs/components/MessageBubble/DeletedMessage.js.map +1 -0
  91. package/lib/commonjs/components/MessageBubble/Message.js +318 -0
  92. package/lib/commonjs/components/MessageBubble/Message.js.map +1 -0
  93. package/lib/commonjs/components/MessageBubble/MessageInteractions.js +164 -0
  94. package/lib/commonjs/components/MessageBubble/MessageInteractions.js.map +1 -0
  95. package/lib/commonjs/components/MessageBubble/MessageReaction.js +148 -0
  96. package/lib/commonjs/components/MessageBubble/MessageReaction.js.map +1 -0
  97. package/lib/commonjs/components/MessageBubble/MessageReply.js +40 -0
  98. package/lib/commonjs/components/MessageBubble/MessageReply.js.map +1 -0
  99. package/lib/commonjs/components/MessageBubble/MessageTranslations.js +27 -0
  100. package/lib/commonjs/components/MessageBubble/MessageTranslations.js.map +1 -0
  101. package/lib/commonjs/components/Modals/AddMembersModal/AddMembersModal.js +141 -0
  102. package/lib/commonjs/components/Modals/AddMembersModal/AddMembersModal.js.map +1 -0
  103. package/lib/commonjs/components/Modals/AttachSheet/AttachSheet.js +184 -0
  104. package/lib/commonjs/components/Modals/AttachSheet/AttachSheet.js.map +1 -0
  105. package/lib/commonjs/components/Modals/ChatProfileModal/ChatProfileModal.js +383 -0
  106. package/lib/commonjs/components/Modals/ChatProfileModal/ChatProfileModal.js.map +1 -0
  107. package/lib/commonjs/components/Modals/ChatProfileModal/DeleteChatModal.js +90 -0
  108. package/lib/commonjs/components/Modals/ChatProfileModal/DeleteChatModal.js.map +1 -0
  109. package/lib/commonjs/components/Modals/FilePreviewModal/FilePreviewModal.js +184 -0
  110. package/lib/commonjs/components/Modals/FilePreviewModal/FilePreviewModal.js.map +1 -0
  111. package/lib/commonjs/components/Modals/FilePreviewModal/PdfView.js +88 -0
  112. package/lib/commonjs/components/Modals/FilePreviewModal/PdfView.js.map +1 -0
  113. package/lib/commonjs/components/Modals/Modal/Modal.js +45 -0
  114. package/lib/commonjs/components/Modals/Modal/Modal.js.map +1 -0
  115. package/lib/commonjs/components/Modals/ModalHeaderComponent.js +36 -0
  116. package/lib/commonjs/components/Modals/ModalHeaderComponent.js.map +1 -0
  117. package/lib/commonjs/components/Modals/ModalSelectMedia/ModalSelectMedia.js +207 -0
  118. package/lib/commonjs/components/Modals/ModalSelectMedia/ModalSelectMedia.js.map +1 -0
  119. package/lib/commonjs/components/Modals/ModalWrapper/ModalWrapper.js +87 -0
  120. package/lib/commonjs/components/Modals/ModalWrapper/ModalWrapper.js.map +1 -0
  121. package/lib/commonjs/components/Modals/NewChatModal/ModalContent.js +134 -0
  122. package/lib/commonjs/components/Modals/NewChatModal/ModalContent.js.map +1 -0
  123. package/lib/commonjs/components/Modals/NewChatModal/NewChatModal.js +324 -0
  124. package/lib/commonjs/components/Modals/NewChatModal/NewChatModal.js.map +1 -0
  125. package/lib/commonjs/components/Modals/NewChatModal/UpdNewChatModal.js +133 -0
  126. package/lib/commonjs/components/Modals/NewChatModal/UpdNewChatModal.js.map +1 -0
  127. package/lib/commonjs/components/Modals/SelectUsersModal/SelectUsersModal.js +122 -0
  128. package/lib/commonjs/components/Modals/SelectUsersModal/SelectUsersModal.js.map +1 -0
  129. package/lib/commonjs/components/Modals/SettingsModals/BlockedUsers/BlockedUsersModal.js +41 -0
  130. package/lib/commonjs/components/Modals/SettingsModals/BlockedUsers/BlockedUsersModal.js.map +1 -0
  131. package/lib/commonjs/components/Modals/SettingsModals/DocumentShares/DocumentSharesModal.js +83 -0
  132. package/lib/commonjs/components/Modals/SettingsModals/DocumentShares/DocumentSharesModal.js.map +1 -0
  133. package/lib/commonjs/components/Modals/SettingsModals/ManageDataModal/ManageDataModal.js +92 -0
  134. package/lib/commonjs/components/Modals/SettingsModals/ManageDataModal/ManageDataModal.js.map +1 -0
  135. package/lib/commonjs/components/Modals/SettingsModals/ManageDataModal/StyledComponents.js +2 -0
  136. package/lib/commonjs/components/Modals/SettingsModals/ManageDataModal/StyledComponents.js.map +1 -0
  137. package/lib/commonjs/components/Modals/SettingsModals/ProfileShares/ProfileShares.js +43 -0
  138. package/lib/commonjs/components/Modals/SettingsModals/ProfileShares/ProfileShares.js.map +1 -0
  139. package/lib/commonjs/components/Modals/SettingsModals/Referrals/Referrals.js +88 -0
  140. package/lib/commonjs/components/Modals/SettingsModals/Referrals/Referrals.js.map +1 -0
  141. package/lib/commonjs/components/Modals/SettingsModals/SharedStyledComponents.js +75 -0
  142. package/lib/commonjs/components/Modals/SettingsModals/SharedStyledComponents.js.map +1 -0
  143. package/lib/commonjs/components/Modals/SettingsModals/Visibility/RadioInput.js +56 -0
  144. package/lib/commonjs/components/Modals/SettingsModals/Visibility/RadioInput.js.map +1 -0
  145. package/lib/commonjs/components/Modals/SettingsModals/Visibility/StyledComponents.js +35 -0
  146. package/lib/commonjs/components/Modals/SettingsModals/Visibility/StyledComponents.js.map +1 -0
  147. package/lib/commonjs/components/Modals/SettingsModals/Visibility/VisibilityModal.js +135 -0
  148. package/lib/commonjs/components/Modals/SettingsModals/Visibility/VisibilityModal.js.map +1 -0
  149. package/lib/commonjs/components/Modals/UserProfileModal/EditUserModal.js +146 -0
  150. package/lib/commonjs/components/Modals/UserProfileModal/EditUserModal.js.map +1 -0
  151. package/lib/commonjs/components/Modals/UserProfileModal/UserProfileModal.js +340 -0
  152. package/lib/commonjs/components/Modals/UserProfileModal/UserProfileModal.js.map +1 -0
  153. package/lib/commonjs/components/Modals/UserSettingsModal/UserSettingsModal.js +77 -0
  154. package/lib/commonjs/components/Modals/UserSettingsModal/UserSettingsModal.js.map +1 -0
  155. package/lib/commonjs/components/Modals/styledModalComponents.js +167 -0
  156. package/lib/commonjs/components/Modals/styledModalComponents.js.map +1 -0
  157. package/lib/commonjs/components/OperationalModal/OperationalModal.js +83 -0
  158. package/lib/commonjs/components/OperationalModal/OperationalModal.js.map +1 -0
  159. package/lib/commonjs/components/RoomComponents/ChatRoomItem.js +159 -0
  160. package/lib/commonjs/components/RoomComponents/ChatRoomItem.js.map +1 -0
  161. package/lib/commonjs/components/RoomComponents/LastMessageItem.js +57 -0
  162. package/lib/commonjs/components/RoomComponents/LastMessageItem.js.map +1 -0
  163. package/lib/commonjs/components/RoomComponents/styled/LastAudioMessage.js +65 -0
  164. package/lib/commonjs/components/RoomComponents/styled/LastAudioMessage.js.map +1 -0
  165. package/lib/commonjs/components/RoomComponents/styled/LastMessageEmoji.js +29 -0
  166. package/lib/commonjs/components/RoomComponents/styled/LastMessageEmoji.js.map +1 -0
  167. package/lib/commonjs/components/RoomComponents/styled/LastMessageFile.js +51 -0
  168. package/lib/commonjs/components/RoomComponents/styled/LastMessageFile.js.map +1 -0
  169. package/lib/commonjs/components/RoomComponents/styled/LastMessagePhoto.js +51 -0
  170. package/lib/commonjs/components/RoomComponents/styled/LastMessagePhoto.js.map +1 -0
  171. package/lib/commonjs/components/RoomComponents/styled/LastMessageVideo.js +69 -0
  172. package/lib/commonjs/components/RoomComponents/styled/LastMessageVideo.js.map +1 -0
  173. package/lib/commonjs/components/RoomComponents/styled/LastTextMessage.js +52 -0
  174. package/lib/commonjs/components/RoomComponents/styled/LastTextMessage.js.map +1 -0
  175. package/lib/commonjs/components/RoomComponents/styled/StyledRoomComponents.js +54 -0
  176. package/lib/commonjs/components/RoomComponents/styled/StyledRoomComponents.js.map +1 -0
  177. package/lib/commonjs/components/SortDropDown/index.js +68 -0
  178. package/lib/commonjs/components/SortDropDown/index.js.map +1 -0
  179. package/lib/commonjs/components/Thread/ThreadHeader.js +50 -0
  180. package/lib/commonjs/components/Thread/ThreadHeader.js.map +1 -0
  181. package/lib/commonjs/components/Thread/ThreadWrapper.js +211 -0
  182. package/lib/commonjs/components/Thread/ThreadWrapper.js.map +1 -0
  183. package/lib/commonjs/components/Toast/Toast.js +116 -0
  184. package/lib/commonjs/components/Toast/Toast.js.map +1 -0
  185. package/lib/commonjs/components/Toast/index.js +30 -0
  186. package/lib/commonjs/components/Toast/index.js.map +1 -0
  187. package/lib/commonjs/components/UsersList/StyledComponents.js +33 -0
  188. package/lib/commonjs/components/UsersList/StyledComponents.js.map +1 -0
  189. package/lib/commonjs/components/UsersList/UsersList.js +88 -0
  190. package/lib/commonjs/components/UsersList/UsersList.js.map +1 -0
  191. package/lib/commonjs/components/styled/ActionButton.js +42 -0
  192. package/lib/commonjs/components/styled/ActionButton.js.map +1 -0
  193. package/lib/commonjs/components/styled/AudioMessage.js +139 -0
  194. package/lib/commonjs/components/styled/AudioMessage.js.map +1 -0
  195. package/lib/commonjs/components/styled/Button.js +93 -0
  196. package/lib/commonjs/components/styled/Button.js.map +1 -0
  197. package/lib/commonjs/components/styled/ChatWrapperBox.js +16 -0
  198. package/lib/commonjs/components/styled/ChatWrapperBox.js.map +1 -0
  199. package/lib/commonjs/components/styled/DateLabel.js +73 -0
  200. package/lib/commonjs/components/styled/DateLabel.js.map +1 -0
  201. package/lib/commonjs/components/styled/Loader.js +61 -0
  202. package/lib/commonjs/components/styled/Loader.js.map +1 -0
  203. package/lib/commonjs/components/styled/MediaFilePreview.js +45 -0
  204. package/lib/commonjs/components/styled/MediaFilePreview.js.map +1 -0
  205. package/lib/commonjs/components/styled/MediaModal.js +61 -0
  206. package/lib/commonjs/components/styled/MediaModal.js.map +1 -0
  207. package/lib/commonjs/components/styled/MessageImage.js +52 -0
  208. package/lib/commonjs/components/styled/MessageImage.js.map +1 -0
  209. package/lib/commonjs/components/styled/NewMessageLabel.js +51 -0
  210. package/lib/commonjs/components/styled/NewMessageLabel.js.map +1 -0
  211. package/lib/commonjs/components/styled/RoomListComponents/index.js +184 -0
  212. package/lib/commonjs/components/styled/RoomListComponents/index.js.map +1 -0
  213. package/lib/commonjs/components/styled/SendInput.js +354 -0
  214. package/lib/commonjs/components/styled/SendInput.js.map +1 -0
  215. package/lib/commonjs/components/styled/StyledComponents.js +309 -0
  216. package/lib/commonjs/components/styled/StyledComponents.js.map +1 -0
  217. package/lib/commonjs/components/styled/StyledInput.js +99 -0
  218. package/lib/commonjs/components/styled/StyledInput.js.map +1 -0
  219. package/lib/commonjs/components/styled/StyledInputComponents/AudioComponents.js +6 -0
  220. package/lib/commonjs/components/styled/StyledInputComponents/AudioComponents.js.map +1 -0
  221. package/lib/commonjs/components/styled/StyledInputComponents/Composing.js +98 -0
  222. package/lib/commonjs/components/styled/StyledInputComponents/Composing.js.map +1 -0
  223. package/lib/commonjs/components/styled/StyledInputComponents/CustomTypingIndicator.js +255 -0
  224. package/lib/commonjs/components/styled/StyledInputComponents/CustomTypingIndicator.js.map +1 -0
  225. package/lib/commonjs/components/styled/StyledInputComponents/MediaComponents.js +87 -0
  226. package/lib/commonjs/components/styled/StyledInputComponents/MediaComponents.js.map +1 -0
  227. package/lib/commonjs/components/styled/StyledInputComponents/StyledInputComponents.js +118 -0
  228. package/lib/commonjs/components/styled/StyledInputComponents/StyledInputComponents.js.map +1 -0
  229. package/lib/commonjs/components/styled/StyledInputComponents/VideoComponents.js +49 -0
  230. package/lib/commonjs/components/styled/StyledInputComponents/VideoComponents.js.map +1 -0
  231. package/lib/commonjs/components/styled/TreadLabel.js +47 -0
  232. package/lib/commonjs/components/styled/TreadLabel.js.map +1 -0
  233. package/lib/commonjs/components/styled/UnsupportedType.js +75 -0
  234. package/lib/commonjs/components/styled/UnsupportedType.js.map +1 -0
  235. package/lib/commonjs/components/styled/VideoMessage.js +58 -0
  236. package/lib/commonjs/components/styled/VideoMessage.js.map +1 -0
  237. package/lib/commonjs/context/MessageNotificationContext.js +270 -0
  238. package/lib/commonjs/context/MessageNotificationContext.js.map +1 -0
  239. package/lib/commonjs/context/PushNotificationProvider.js +79 -0
  240. package/lib/commonjs/context/PushNotificationProvider.js.map +1 -0
  241. package/lib/commonjs/context/ToastContext.js +64 -0
  242. package/lib/commonjs/context/ToastContext.js.map +1 -0
  243. package/lib/commonjs/context/toastProvider.js +2 -0
  244. package/lib/commonjs/context/toastProvider.js.map +1 -0
  245. package/lib/commonjs/context/xmppProvider.js +355 -0
  246. package/lib/commonjs/context/xmppProvider.js.map +1 -0
  247. package/lib/commonjs/helpers/block_scroll.js +71 -0
  248. package/lib/commonjs/helpers/block_scroll.js.map +1 -0
  249. package/lib/commonjs/helpers/chatAutoEnterer.js +40 -0
  250. package/lib/commonjs/helpers/chatAutoEnterer.js.map +1 -0
  251. package/lib/commonjs/helpers/checkUniqueUsers.js +30 -0
  252. package/lib/commonjs/helpers/checkUniqueUsers.js.map +1 -0
  253. package/lib/commonjs/helpers/constants/CHAT_TYPES.js +14 -0
  254. package/lib/commonjs/helpers/constants/CHAT_TYPES.js.map +1 -0
  255. package/lib/commonjs/helpers/constants/LANGUAGE_OPTIONS.js +23 -0
  256. package/lib/commonjs/helpers/constants/LANGUAGE_OPTIONS.js.map +1 -0
  257. package/lib/commonjs/helpers/constants/LOCAL_STORAGE.js +10 -0
  258. package/lib/commonjs/helpers/constants/LOCAL_STORAGE.js.map +1 -0
  259. package/lib/commonjs/helpers/constants/MESSAGE_INTERACTIONS.js +27 -0
  260. package/lib/commonjs/helpers/constants/MESSAGE_INTERACTIONS.js.map +1 -0
  261. package/lib/commonjs/helpers/constants/MODAL_COMPONENTS.js +38 -0
  262. package/lib/commonjs/helpers/constants/MODAL_COMPONENTS.js.map +1 -0
  263. package/lib/commonjs/helpers/constants/MODAL_TYPES.js +31 -0
  264. package/lib/commonjs/helpers/constants/MODAL_TYPES.js.map +1 -0
  265. package/lib/commonjs/helpers/constants/PLATFORM_CONSTANTS.js +10 -0
  266. package/lib/commonjs/helpers/constants/PLATFORM_CONSTANTS.js.map +1 -0
  267. package/lib/commonjs/helpers/createMainMessageForThread.js +29 -0
  268. package/lib/commonjs/helpers/createMainMessageForThread.js.map +1 -0
  269. package/lib/commonjs/helpers/createMessageFromXml.js +105 -0
  270. package/lib/commonjs/helpers/createMessageFromXml.js.map +1 -0
  271. package/lib/commonjs/helpers/createRoomFromApi.js +30 -0
  272. package/lib/commonjs/helpers/createRoomFromApi.js.map +1 -0
  273. package/lib/commonjs/helpers/createUserNameFromSetUser.js +17 -0
  274. package/lib/commonjs/helpers/createUserNameFromSetUser.js.map +1 -0
  275. package/lib/commonjs/helpers/dateComparison.js +21 -0
  276. package/lib/commonjs/helpers/dateComparison.js.map +1 -0
  277. package/lib/commonjs/helpers/debounce.js +14 -0
  278. package/lib/commonjs/helpers/debounce.js.map +1 -0
  279. package/lib/commonjs/helpers/ensureScopedChatCache.js +53 -0
  280. package/lib/commonjs/helpers/ensureScopedChatCache.js.map +1 -0
  281. package/lib/commonjs/helpers/extractUniqueMembersFromRooms.js +33 -0
  282. package/lib/commonjs/helpers/extractUniqueMembersFromRooms.js.map +1 -0
  283. package/lib/commonjs/helpers/formatNumberWithCommas.js +10 -0
  284. package/lib/commonjs/helpers/formatNumberWithCommas.js.map +1 -0
  285. package/lib/commonjs/helpers/getBooleanFromString.js +20 -0
  286. package/lib/commonjs/helpers/getBooleanFromString.js.map +1 -0
  287. package/lib/commonjs/helpers/getDataFromXml.js +56 -0
  288. package/lib/commonjs/helpers/getDataFromXml.js.map +1 -0
  289. package/lib/commonjs/helpers/getNumberFromString.js +14 -0
  290. package/lib/commonjs/helpers/getNumberFromString.js.map +1 -0
  291. package/lib/commonjs/helpers/getRoomsWithRetry.js +35 -0
  292. package/lib/commonjs/helpers/getRoomsWithRetry.js.map +1 -0
  293. package/lib/commonjs/helpers/getTintedColor.js +25 -0
  294. package/lib/commonjs/helpers/getTintedColor.js.map +1 -0
  295. package/lib/commonjs/helpers/getUnnamedUsers.js +33 -0
  296. package/lib/commonjs/helpers/getUnnamedUsers.js.map +1 -0
  297. package/lib/commonjs/helpers/handleCopyClick.js +11 -0
  298. package/lib/commonjs/helpers/handleCopyClick.js.map +1 -0
  299. package/lib/commonjs/helpers/handleXmppError.js +26 -0
  300. package/lib/commonjs/helpers/handleXmppError.js.map +1 -0
  301. package/lib/commonjs/helpers/hashcolor.js +19 -0
  302. package/lib/commonjs/helpers/hashcolor.js.map +1 -0
  303. package/lib/commonjs/helpers/historyPreloadScheduler.js +228 -0
  304. package/lib/commonjs/helpers/historyPreloadScheduler.js.map +1 -0
  305. package/lib/commonjs/helpers/initRoomsPresence.js +31 -0
  306. package/lib/commonjs/helpers/initRoomsPresence.js.map +1 -0
  307. package/lib/commonjs/helpers/initXmppRooms.js +66 -0
  308. package/lib/commonjs/helpers/initXmppRooms.js.map +1 -0
  309. package/lib/commonjs/helpers/insertMessageWithDelimiter.js +74 -0
  310. package/lib/commonjs/helpers/insertMessageWithDelimiter.js.map +1 -0
  311. package/lib/commonjs/helpers/isChatIdPresentInArray.js +41 -0
  312. package/lib/commonjs/helpers/isChatIdPresentInArray.js.map +1 -0
  313. package/lib/commonjs/helpers/localStorageUser.js +13 -0
  314. package/lib/commonjs/helpers/localStorageUser.js.map +1 -0
  315. package/lib/commonjs/helpers/markdownParser.js +281 -0
  316. package/lib/commonjs/helpers/markdownParser.js.map +1 -0
  317. package/lib/commonjs/helpers/nanoToMs.js +11 -0
  318. package/lib/commonjs/helpers/nanoToMs.js.map +1 -0
  319. package/lib/commonjs/helpers/parseMessageBody.js +532 -0
  320. package/lib/commonjs/helpers/parseMessageBody.js.map +1 -0
  321. package/lib/commonjs/helpers/parseUrls.js +43 -0
  322. package/lib/commonjs/helpers/parseUrls.js.map +1 -0
  323. package/lib/commonjs/helpers/resolveInitBeforeLoadUser.js +249 -0
  324. package/lib/commonjs/helpers/resolveInitBeforeLoadUser.js.map +1 -0
  325. package/lib/commonjs/helpers/storeConsole.js +30 -0
  326. package/lib/commonjs/helpers/storeConsole.js.map +1 -0
  327. package/lib/commonjs/helpers/transformTranslatations.js +14 -0
  328. package/lib/commonjs/helpers/transformTranslatations.js.map +1 -0
  329. package/lib/commonjs/helpers/updateMessagesTillLast.js +74 -0
  330. package/lib/commonjs/helpers/updateMessagesTillLast.js.map +1 -0
  331. package/lib/commonjs/helpers/updatedChatLastTimestamps.js +32 -0
  332. package/lib/commonjs/helpers/updatedChatLastTimestamps.js.map +1 -0
  333. package/lib/commonjs/helpers/validator.js +20 -0
  334. package/lib/commonjs/helpers/validator.js.map +1 -0
  335. package/lib/commonjs/helpers/walletUsername.js +19 -0
  336. package/lib/commonjs/helpers/walletUsername.js.map +1 -0
  337. package/lib/commonjs/hooks/hooks.js +10 -0
  338. package/lib/commonjs/hooks/hooks.js.map +1 -0
  339. package/lib/commonjs/hooks/useChatSettingState.js +29 -0
  340. package/lib/commonjs/hooks/useChatSettingState.js.map +1 -0
  341. package/lib/commonjs/hooks/useChatWrapperInit.js +210 -0
  342. package/lib/commonjs/hooks/useChatWrapperInit.js.map +1 -0
  343. package/lib/commonjs/hooks/useComposing.js +49 -0
  344. package/lib/commonjs/hooks/useComposing.js.map +1 -0
  345. package/lib/commonjs/hooks/useCustomTypingIndicator.js +184 -0
  346. package/lib/commonjs/hooks/useCustomTypingIndicator.js.map +1 -0
  347. package/lib/commonjs/hooks/useEventHandlers.js +51 -0
  348. package/lib/commonjs/hooks/useEventHandlers.js.map +1 -0
  349. package/lib/commonjs/hooks/useGetNewArchRoom.js +49 -0
  350. package/lib/commonjs/hooks/useGetNewArchRoom.js.map +1 -0
  351. package/lib/commonjs/hooks/useHeapSender.js +73 -0
  352. package/lib/commonjs/hooks/useHeapSender.js.map +1 -0
  353. package/lib/commonjs/hooks/useLocalStorage.js +65 -0
  354. package/lib/commonjs/hooks/useLocalStorage.js.map +1 -0
  355. package/lib/commonjs/hooks/useLogout.js +147 -0
  356. package/lib/commonjs/hooks/useLogout.js.map +1 -0
  357. package/lib/commonjs/hooks/useMessageHeapState.js +17 -0
  358. package/lib/commonjs/hooks/useMessageHeapState.js.map +1 -0
  359. package/lib/commonjs/hooks/useMessageLoaderQueue.js +60 -0
  360. package/lib/commonjs/hooks/useMessageLoaderQueue.js.map +1 -0
  361. package/lib/commonjs/hooks/useMessageQueue.js +112 -0
  362. package/lib/commonjs/hooks/useMessageQueue.js.map +1 -0
  363. package/lib/commonjs/hooks/usePendingNotification.js +49 -0
  364. package/lib/commonjs/hooks/usePendingNotification.js.map +1 -0
  365. package/lib/commonjs/hooks/usePrevious.js +20 -0
  366. package/lib/commonjs/hooks/usePrevious.js.map +1 -0
  367. package/lib/commonjs/hooks/usePushNotifications.js +96 -0
  368. package/lib/commonjs/hooks/usePushNotifications.js.map +1 -0
  369. package/lib/commonjs/hooks/useQRCodeChatHandler.js +55 -0
  370. package/lib/commonjs/hooks/useQRCodeChatHandler.js.map +1 -0
  371. package/lib/commonjs/hooks/useRoomInitialization.js +149 -0
  372. package/lib/commonjs/hooks/useRoomInitialization.js.map +1 -0
  373. package/lib/commonjs/hooks/useRoomState.js +37 -0
  374. package/lib/commonjs/hooks/useRoomState.js.map +1 -0
  375. package/lib/commonjs/hooks/useRoomUrl.js +35 -0
  376. package/lib/commonjs/hooks/useRoomUrl.js.map +1 -0
  377. package/lib/commonjs/hooks/useSendMessage.js +313 -0
  378. package/lib/commonjs/hooks/useSendMessage.js.map +1 -0
  379. package/lib/commonjs/hooks/useUnreadMessagesCounter.js +41 -0
  380. package/lib/commonjs/hooks/useUnreadMessagesCounter.js.map +1 -0
  381. package/lib/commonjs/hooks/useXmppInitialization.js +112 -0
  382. package/lib/commonjs/hooks/useXmppInitialization.js.map +1 -0
  383. package/lib/commonjs/main.js +55 -0
  384. package/lib/commonjs/main.js.map +1 -0
  385. package/lib/commonjs/networking/api-requests/auth.api.js +126 -0
  386. package/lib/commonjs/networking/api-requests/auth.api.js.map +1 -0
  387. package/lib/commonjs/networking/api-requests/push.api.js +44 -0
  388. package/lib/commonjs/networking/api-requests/push.api.js.map +1 -0
  389. package/lib/commonjs/networking/api-requests/roomMembers.api.js +22 -0
  390. package/lib/commonjs/networking/api-requests/roomMembers.api.js.map +1 -0
  391. package/lib/commonjs/networking/api-requests/rooms.api.js +243 -0
  392. package/lib/commonjs/networking/api-requests/rooms.api.js.map +1 -0
  393. package/lib/commonjs/networking/api-requests/user.api.js +74 -0
  394. package/lib/commonjs/networking/api-requests/user.api.js.map +1 -0
  395. package/lib/commonjs/networking/apiClient.js +174 -0
  396. package/lib/commonjs/networking/apiClient.js.map +1 -0
  397. package/lib/commonjs/networking/helpers/refreshChecker.js +17 -0
  398. package/lib/commonjs/networking/helpers/refreshChecker.js.map +1 -0
  399. package/lib/commonjs/networking/stanzaHandlers.js +346 -0
  400. package/lib/commonjs/networking/stanzaHandlers.js.map +1 -0
  401. package/lib/commonjs/networking/xmpp/actionSetTimestampToPrivateStore.xmpp.js +28 -0
  402. package/lib/commonjs/networking/xmpp/actionSetTimestampToPrivateStore.xmpp.js.map +1 -0
  403. package/lib/commonjs/networking/xmpp/allRoomPresences.xmpp.js +13 -0
  404. package/lib/commonjs/networking/xmpp/allRoomPresences.xmpp.js.map +1 -0
  405. package/lib/commonjs/networking/xmpp/createPrivateRoom.xmpp.js +24 -0
  406. package/lib/commonjs/networking/xmpp/createPrivateRoom.xmpp.js.map +1 -0
  407. package/lib/commonjs/networking/xmpp/createRoom.xmpp.js +31 -0
  408. package/lib/commonjs/networking/xmpp/createRoom.xmpp.js.map +1 -0
  409. package/lib/commonjs/networking/xmpp/createRoomPresence.xmpp.js +52 -0
  410. package/lib/commonjs/networking/xmpp/createRoomPresence.xmpp.js.map +1 -0
  411. package/lib/commonjs/networking/xmpp/createTimeoutPromise.xmpp.js +19 -0
  412. package/lib/commonjs/networking/xmpp/createTimeoutPromise.xmpp.js.map +1 -0
  413. package/lib/commonjs/networking/xmpp/deleteMessage.xmpp.js +19 -0
  414. package/lib/commonjs/networking/xmpp/deleteMessage.xmpp.js.map +1 -0
  415. package/lib/commonjs/networking/xmpp/editMessage.xmpp.js +44 -0
  416. package/lib/commonjs/networking/xmpp/editMessage.xmpp.js.map +1 -0
  417. package/lib/commonjs/networking/xmpp/flushLastViewedToPrivateStore.js +82 -0
  418. package/lib/commonjs/networking/xmpp/flushLastViewedToPrivateStore.js.map +1 -0
  419. package/lib/commonjs/networking/xmpp/getChatsPrivateStoreRequest.xmpp.js +53 -0
  420. package/lib/commonjs/networking/xmpp/getChatsPrivateStoreRequest.xmpp.js.map +1 -0
  421. package/lib/commonjs/networking/xmpp/getHistory.xmpp.js +101 -0
  422. package/lib/commonjs/networking/xmpp/getHistory.xmpp.js.map +1 -0
  423. package/lib/commonjs/networking/xmpp/getLastMessageArchive.xmpp.js +20 -0
  424. package/lib/commonjs/networking/xmpp/getLastMessageArchive.xmpp.js.map +1 -0
  425. package/lib/commonjs/networking/xmpp/getRoomInfo.xmpp.js +20 -0
  426. package/lib/commonjs/networking/xmpp/getRoomInfo.xmpp.js.map +1 -0
  427. package/lib/commonjs/networking/xmpp/getRoomMembers.xmpp.js +19 -0
  428. package/lib/commonjs/networking/xmpp/getRoomMembers.xmpp.js.map +1 -0
  429. package/lib/commonjs/networking/xmpp/getRooms.xmpp.js +40 -0
  430. package/lib/commonjs/networking/xmpp/getRooms.xmpp.js.map +1 -0
  431. package/lib/commonjs/networking/xmpp/getRoomsPaged.xmpp.js +48 -0
  432. package/lib/commonjs/networking/xmpp/getRoomsPaged.xmpp.js.map +1 -0
  433. package/lib/commonjs/networking/xmpp/handlePong.xmpp.js +10 -0
  434. package/lib/commonjs/networking/xmpp/handlePong.xmpp.js.map +1 -0
  435. package/lib/commonjs/networking/xmpp/handleStanzas.xmpp.js +44 -0
  436. package/lib/commonjs/networking/xmpp/handleStanzas.xmpp.js.map +1 -0
  437. package/lib/commonjs/networking/xmpp/inviteRoomRequest.xmpp.js +19 -0
  438. package/lib/commonjs/networking/xmpp/inviteRoomRequest.xmpp.js.map +1 -0
  439. package/lib/commonjs/networking/xmpp/leaveTheRoom.xmpp.js +19 -0
  440. package/lib/commonjs/networking/xmpp/leaveTheRoom.xmpp.js.map +1 -0
  441. package/lib/commonjs/networking/xmpp/listenerManager.js +80 -0
  442. package/lib/commonjs/networking/xmpp/listenerManager.js.map +1 -0
  443. package/lib/commonjs/networking/xmpp/presenceInRoom.xmpp.js +50 -0
  444. package/lib/commonjs/networking/xmpp/presenceInRoom.xmpp.js.map +1 -0
  445. package/lib/commonjs/networking/xmpp/roomConfig.xmpp.js +44 -0
  446. package/lib/commonjs/networking/xmpp/roomConfig.xmpp.js.map +1 -0
  447. package/lib/commonjs/networking/xmpp/sendMediaMessage.xmpp.js +92 -0
  448. package/lib/commonjs/networking/xmpp/sendMediaMessage.xmpp.js.map +1 -0
  449. package/lib/commonjs/networking/xmpp/sendMessageReaction.xmpp.js +30 -0
  450. package/lib/commonjs/networking/xmpp/sendMessageReaction.xmpp.js.map +1 -0
  451. package/lib/commonjs/networking/xmpp/sendPing.xmpp.js +21 -0
  452. package/lib/commonjs/networking/xmpp/sendPing.xmpp.js.map +1 -0
  453. package/lib/commonjs/networking/xmpp/sendTextMessage.xmpp.js +90 -0
  454. package/lib/commonjs/networking/xmpp/sendTextMessage.xmpp.js.map +1 -0
  455. package/lib/commonjs/networking/xmpp/sendTextMessageWithTranslateTag.xmpp.js +27 -0
  456. package/lib/commonjs/networking/xmpp/sendTextMessageWithTranslateTag.xmpp.js.map +1 -0
  457. package/lib/commonjs/networking/xmpp/sendTypingRequest.xmpp.js +21 -0
  458. package/lib/commonjs/networking/xmpp/sendTypingRequest.xmpp.js.map +1 -0
  459. package/lib/commonjs/networking/xmpp/setChatsPrivateStoreRequest.xmpp.js +36 -0
  460. package/lib/commonjs/networking/xmpp/setChatsPrivateStoreRequest.xmpp.js.map +1 -0
  461. package/lib/commonjs/networking/xmpp/setMeAsOwner.xmpp.js +38 -0
  462. package/lib/commonjs/networking/xmpp/setMeAsOwner.xmpp.js.map +1 -0
  463. package/lib/commonjs/networking/xmpp/setRoomImage.xmpp.js +22 -0
  464. package/lib/commonjs/networking/xmpp/setRoomImage.xmpp.js.map +1 -0
  465. package/lib/commonjs/networking/xmpp/setVCard.xmpp.js +17 -0
  466. package/lib/commonjs/networking/xmpp/setVCard.xmpp.js.map +1 -0
  467. package/lib/commonjs/networking/xmpp/subscribeToRoomMessages.xmpp.js +65 -0
  468. package/lib/commonjs/networking/xmpp/subscribeToRoomMessages.xmpp.js.map +1 -0
  469. package/lib/commonjs/networking/xmppClient.js +496 -0
  470. package/lib/commonjs/networking/xmppClient.js.map +1 -0
  471. package/lib/commonjs/package.json +1 -0
  472. package/lib/commonjs/roomStore/Middleware/logoutMiddleware.js +36 -0
  473. package/lib/commonjs/roomStore/Middleware/logoutMiddleware.js.map +1 -0
  474. package/lib/commonjs/roomStore/Middleware/newMessageMidlleware.js +88 -0
  475. package/lib/commonjs/roomStore/Middleware/newMessageMidlleware.js.map +1 -0
  476. package/lib/commonjs/roomStore/Middleware/reactionsMiddleware.js +69 -0
  477. package/lib/commonjs/roomStore/Middleware/reactionsMiddleware.js.map +1 -0
  478. package/lib/commonjs/roomStore/Middleware/testMiddleware.js +22 -0
  479. package/lib/commonjs/roomStore/Middleware/testMiddleware.js.map +1 -0
  480. package/lib/commonjs/roomStore/Middleware/unreadMidlleware.js +139 -0
  481. package/lib/commonjs/roomStore/Middleware/unreadMidlleware.js.map +1 -0
  482. package/lib/commonjs/roomStore/chatSettingsSlice.js +176 -0
  483. package/lib/commonjs/roomStore/chatSettingsSlice.js.map +1 -0
  484. package/lib/commonjs/roomStore/index.js +60 -0
  485. package/lib/commonjs/roomStore/index.js.map +1 -0
  486. package/lib/commonjs/roomStore/persistence.js +148 -0
  487. package/lib/commonjs/roomStore/persistence.js.map +1 -0
  488. package/lib/commonjs/roomStore/roomHeapSlice.js +44 -0
  489. package/lib/commonjs/roomStore/roomHeapSlice.js.map +1 -0
  490. package/lib/commonjs/roomStore/roomsSlice.js +494 -0
  491. package/lib/commonjs/roomStore/roomsSlice.js.map +1 -0
  492. package/lib/commonjs/services/pushNotifications.js +143 -0
  493. package/lib/commonjs/services/pushNotifications.js.map +1 -0
  494. package/lib/commonjs/services/pushSubscriptionService.js +139 -0
  495. package/lib/commonjs/services/pushSubscriptionService.js.map +1 -0
  496. package/lib/commonjs/types/messages.js +2 -0
  497. package/lib/commonjs/types/messages.js.map +1 -0
  498. package/lib/commonjs/types/models/action.model.js +6 -0
  499. package/lib/commonjs/types/models/action.model.js.map +1 -0
  500. package/lib/commonjs/types/models/config.model.js +2 -0
  501. package/lib/commonjs/types/models/config.model.js.map +1 -0
  502. package/lib/commonjs/types/models/customComponents.model.js +6 -0
  503. package/lib/commonjs/types/models/customComponents.model.js.map +1 -0
  504. package/lib/commonjs/types/models/language.model.js +2 -0
  505. package/lib/commonjs/types/models/language.model.js.map +1 -0
  506. package/lib/commonjs/types/models/media.model.js +2 -0
  507. package/lib/commonjs/types/models/media.model.js.map +1 -0
  508. package/lib/commonjs/types/models/message.model.js +6 -0
  509. package/lib/commonjs/types/models/message.model.js.map +1 -0
  510. package/lib/commonjs/types/models/modal.model.js +6 -0
  511. package/lib/commonjs/types/models/modal.model.js.map +1 -0
  512. package/lib/commonjs/types/models/room.model.js +6 -0
  513. package/lib/commonjs/types/models/room.model.js.map +1 -0
  514. package/lib/commonjs/types/models/user.model.js +6 -0
  515. package/lib/commonjs/types/models/user.model.js.map +1 -0
  516. package/lib/commonjs/types/models/xmpp.model.js +6 -0
  517. package/lib/commonjs/types/models/xmpp.model.js.map +1 -0
  518. package/lib/commonjs/types/types.js +6 -0
  519. package/lib/commonjs/types/types.js.map +1 -0
  520. package/lib/commonjs/utils/PriorityQueue.js +45 -0
  521. package/lib/commonjs/utils/PriorityQueue.js.map +1 -0
  522. package/lib/commonjs/utils/actionHelpers.js +41 -0
  523. package/lib/commonjs/utils/actionHelpers.js.map +1 -0
  524. package/lib/commonjs/utils/actionLogger.js +53 -0
  525. package/lib/commonjs/utils/actionLogger.js.map +1 -0
  526. package/lib/commonjs/utils/clientRegistry.js +79 -0
  527. package/lib/commonjs/utils/clientRegistry.js.map +1 -0
  528. package/lib/commonjs/utils/devLogger.js +190 -0
  529. package/lib/commonjs/utils/devLogger.js.map +1 -0
  530. package/lib/commonjs/utils/messageNotificationManager.js +92 -0
  531. package/lib/commonjs/utils/messageNotificationManager.js.map +1 -0
  532. package/lib/commonjs/utils/resendMessage.js +47 -0
  533. package/lib/commonjs/utils/resendMessage.js.map +1 -0
  534. package/lib/commonjs/utils/toastEmitter.js +30 -0
  535. package/lib/commonjs/utils/toastEmitter.js.map +1 -0
  536. package/lib/commonjs/utils/xmppMemoryMonitor.js +52 -0
  537. package/lib/commonjs/utils/xmppMemoryMonitor.js.map +1 -0
  538. package/lib/commonjs/version.js +8 -0
  539. package/lib/commonjs/version.js.map +1 -0
  540. package/lib/module/assets/BG.js +59 -0
  541. package/lib/module/assets/BG.js.map +1 -0
  542. package/lib/module/assets/BG.png +0 -0
  543. package/lib/module/assets/File.svg +4 -0
  544. package/lib/module/assets/ForzaCare.js +33 -0
  545. package/lib/module/assets/ForzaCare.js.map +1 -0
  546. package/lib/module/assets/ForzaCare.png +0 -0
  547. package/lib/module/assets/icons.js +2 -0
  548. package/lib/module/assets/icons.js.map +1 -0
  549. package/lib/module/assets/images.js +38 -0
  550. package/lib/module/assets/images.js.map +1 -0
  551. package/lib/module/assets/test.xml +243 -0
  552. package/lib/module/components/AuthForms/Login.js +282 -0
  553. package/lib/module/components/AuthForms/Login.js.map +1 -0
  554. package/lib/module/components/AuthForms/LoginAnonym.js +64 -0
  555. package/lib/module/components/AuthForms/LoginAnonym.js.map +1 -0
  556. package/lib/module/components/AuthForms/Register.js +12 -0
  557. package/lib/module/components/AuthForms/Register.js.map +1 -0
  558. package/lib/module/components/ContextMenu/ContextMenuComponents.js +82 -0
  559. package/lib/module/components/ContextMenu/ContextMenuComponents.js.map +1 -0
  560. package/lib/module/components/DropdownMenu/DropdownMenu.js +214 -0
  561. package/lib/module/components/DropdownMenu/DropdownMenu.js.map +1 -0
  562. package/lib/module/components/ExampleComponents/CustomMessage.js +84 -0
  563. package/lib/module/components/ExampleComponents/CustomMessage.js.map +1 -0
  564. package/lib/module/components/ExampleComponents/CustomTypingIndicatorExamples.js +262 -0
  565. package/lib/module/components/ExampleComponents/CustomTypingIndicatorExamples.js.map +1 -0
  566. package/lib/module/components/Header/HeaderRoomList.js +110 -0
  567. package/lib/module/components/Header/HeaderRoomList.js.map +1 -0
  568. package/lib/module/components/InputComponents/AudioInput.js +18 -0
  569. package/lib/module/components/InputComponents/AudioInput.js.map +1 -0
  570. package/lib/module/components/InputComponents/AudioRecorder.js +95 -0
  571. package/lib/module/components/InputComponents/AudioRecorder.js.map +1 -0
  572. package/lib/module/components/InputComponents/MediaInput.js +92 -0
  573. package/lib/module/components/InputComponents/MediaInput.js.map +1 -0
  574. package/lib/module/components/InputComponents/RecordingIndicator.js +65 -0
  575. package/lib/module/components/InputComponents/RecordingIndicator.js.map +1 -0
  576. package/lib/module/components/InputComponents/Search.js +107 -0
  577. package/lib/module/components/InputComponents/Search.js.map +1 -0
  578. package/lib/module/components/InputComponents/TextInput.js +56 -0
  579. package/lib/module/components/InputComponents/TextInput.js.map +1 -0
  580. package/lib/module/components/MainComponents/ChatHeader.js +148 -0
  581. package/lib/module/components/MainComponents/ChatHeader.js.map +1 -0
  582. package/lib/module/components/MainComponents/ChatRoom.js +266 -0
  583. package/lib/module/components/MainComponents/ChatRoom.js.map +1 -0
  584. package/lib/module/components/MainComponents/ChatWrapper.js +271 -0
  585. package/lib/module/components/MainComponents/ChatWrapper.js.map +1 -0
  586. package/lib/module/components/MainComponents/ChooseChatMessage.js +41 -0
  587. package/lib/module/components/MainComponents/ChooseChatMessage.js.map +1 -0
  588. package/lib/module/components/MainComponents/ConnectionBanner.js +35 -0
  589. package/lib/module/components/MainComponents/ConnectionBanner.js.map +1 -0
  590. package/lib/module/components/MainComponents/EditWrapper.js +77 -0
  591. package/lib/module/components/MainComponents/EditWrapper.js.map +1 -0
  592. package/lib/module/components/MainComponents/LoginWrapper.js +121 -0
  593. package/lib/module/components/MainComponents/LoginWrapper.js.map +1 -0
  594. package/lib/module/components/MainComponents/MediaMessage.js +62 -0
  595. package/lib/module/components/MainComponents/MediaMessage.js.map +1 -0
  596. package/lib/module/components/MainComponents/MessageContainer.js +79 -0
  597. package/lib/module/components/MainComponents/MessageContainer.js.map +1 -0
  598. package/lib/module/components/MainComponents/MessageList.js +284 -0
  599. package/lib/module/components/MainComponents/MessageList.js.map +1 -0
  600. package/lib/module/components/MainComponents/NoMessagesPlaceholder.js +47 -0
  601. package/lib/module/components/MainComponents/NoMessagesPlaceholder.js.map +1 -0
  602. package/lib/module/components/MainComponents/ProfileImagePlaceholder.js +91 -0
  603. package/lib/module/components/MainComponents/ProfileImagePlaceholder.js.map +1 -0
  604. package/lib/module/components/MainComponents/RNStyled.js +31 -0
  605. package/lib/module/components/MainComponents/RNStyled.js.map +1 -0
  606. package/lib/module/components/MainComponents/ReduxWrapper.js +37 -0
  607. package/lib/module/components/MainComponents/ReduxWrapper.js.map +1 -0
  608. package/lib/module/components/MainComponents/RoomList.js +199 -0
  609. package/lib/module/components/MainComponents/RoomList.js.map +1 -0
  610. package/lib/module/components/MainComponents/Select.js +130 -0
  611. package/lib/module/components/MainComponents/Select.js.map +1 -0
  612. package/lib/module/components/MainComponents/Switch.js +68 -0
  613. package/lib/module/components/MainComponents/Switch.js.map +1 -0
  614. package/lib/module/components/MainComponents/SystemMessage.js +34 -0
  615. package/lib/module/components/MainComponents/SystemMessage.js.map +1 -0
  616. package/lib/module/components/Menu/HeaderRoomListMenu.js +157 -0
  617. package/lib/module/components/Menu/HeaderRoomListMenu.js.map +1 -0
  618. package/lib/module/components/MenuRoom/MenuRoom.js +43 -0
  619. package/lib/module/components/MenuRoom/MenuRoom.js.map +1 -0
  620. package/lib/module/components/MessageBubble/Avatar.js +71 -0
  621. package/lib/module/components/MessageBubble/Avatar.js.map +1 -0
  622. package/lib/module/components/MessageBubble/BottomReplyContainer.js +104 -0
  623. package/lib/module/components/MessageBubble/BottomReplyContainer.js.map +1 -0
  624. package/lib/module/components/MessageBubble/CustomDivider.js +10 -0
  625. package/lib/module/components/MessageBubble/CustomDivider.js.map +1 -0
  626. package/lib/module/components/MessageBubble/DeletedMessage.js +42 -0
  627. package/lib/module/components/MessageBubble/DeletedMessage.js.map +1 -0
  628. package/lib/module/components/MessageBubble/Message.js +312 -0
  629. package/lib/module/components/MessageBubble/Message.js.map +1 -0
  630. package/lib/module/components/MessageBubble/MessageInteractions.js +159 -0
  631. package/lib/module/components/MessageBubble/MessageInteractions.js.map +1 -0
  632. package/lib/module/components/MessageBubble/MessageReaction.js +140 -0
  633. package/lib/module/components/MessageBubble/MessageReaction.js.map +1 -0
  634. package/lib/module/components/MessageBubble/MessageReply.js +35 -0
  635. package/lib/module/components/MessageBubble/MessageReply.js.map +1 -0
  636. package/lib/module/components/MessageBubble/MessageTranslations.js +22 -0
  637. package/lib/module/components/MessageBubble/MessageTranslations.js.map +1 -0
  638. package/lib/module/components/Modals/AddMembersModal/AddMembersModal.js +135 -0
  639. package/lib/module/components/Modals/AddMembersModal/AddMembersModal.js.map +1 -0
  640. package/lib/module/components/Modals/AttachSheet/AttachSheet.js +179 -0
  641. package/lib/module/components/Modals/AttachSheet/AttachSheet.js.map +1 -0
  642. package/lib/module/components/Modals/ChatProfileModal/ChatProfileModal.js +377 -0
  643. package/lib/module/components/Modals/ChatProfileModal/ChatProfileModal.js.map +1 -0
  644. package/lib/module/components/Modals/ChatProfileModal/DeleteChatModal.js +85 -0
  645. package/lib/module/components/Modals/ChatProfileModal/DeleteChatModal.js.map +1 -0
  646. package/lib/module/components/Modals/FilePreviewModal/FilePreviewModal.js +178 -0
  647. package/lib/module/components/Modals/FilePreviewModal/FilePreviewModal.js.map +1 -0
  648. package/lib/module/components/Modals/FilePreviewModal/PdfView.js +83 -0
  649. package/lib/module/components/Modals/FilePreviewModal/PdfView.js.map +1 -0
  650. package/lib/module/components/Modals/Modal/Modal.js +40 -0
  651. package/lib/module/components/Modals/Modal/Modal.js.map +1 -0
  652. package/lib/module/components/Modals/ModalHeaderComponent.js +31 -0
  653. package/lib/module/components/Modals/ModalHeaderComponent.js.map +1 -0
  654. package/lib/module/components/Modals/ModalSelectMedia/ModalSelectMedia.js +200 -0
  655. package/lib/module/components/Modals/ModalSelectMedia/ModalSelectMedia.js.map +1 -0
  656. package/lib/module/components/Modals/ModalWrapper/ModalWrapper.js +81 -0
  657. package/lib/module/components/Modals/ModalWrapper/ModalWrapper.js.map +1 -0
  658. package/lib/module/components/Modals/NewChatModal/ModalContent.js +129 -0
  659. package/lib/module/components/Modals/NewChatModal/ModalContent.js.map +1 -0
  660. package/lib/module/components/Modals/NewChatModal/NewChatModal.js +318 -0
  661. package/lib/module/components/Modals/NewChatModal/NewChatModal.js.map +1 -0
  662. package/lib/module/components/Modals/NewChatModal/UpdNewChatModal.js +127 -0
  663. package/lib/module/components/Modals/NewChatModal/UpdNewChatModal.js.map +1 -0
  664. package/lib/module/components/Modals/SelectUsersModal/SelectUsersModal.js +116 -0
  665. package/lib/module/components/Modals/SelectUsersModal/SelectUsersModal.js.map +1 -0
  666. package/lib/module/components/Modals/SettingsModals/BlockedUsers/BlockedUsersModal.js +36 -0
  667. package/lib/module/components/Modals/SettingsModals/BlockedUsers/BlockedUsersModal.js.map +1 -0
  668. package/lib/module/components/Modals/SettingsModals/DocumentShares/DocumentSharesModal.js +78 -0
  669. package/lib/module/components/Modals/SettingsModals/DocumentShares/DocumentSharesModal.js.map +1 -0
  670. package/lib/module/components/Modals/SettingsModals/ManageDataModal/ManageDataModal.js +87 -0
  671. package/lib/module/components/Modals/SettingsModals/ManageDataModal/ManageDataModal.js.map +1 -0
  672. package/lib/module/components/Modals/SettingsModals/ManageDataModal/StyledComponents.js +2 -0
  673. package/lib/module/components/Modals/SettingsModals/ManageDataModal/StyledComponents.js.map +1 -0
  674. package/lib/module/components/Modals/SettingsModals/ProfileShares/ProfileShares.js +38 -0
  675. package/lib/module/components/Modals/SettingsModals/ProfileShares/ProfileShares.js.map +1 -0
  676. package/lib/module/components/Modals/SettingsModals/Referrals/Referrals.js +83 -0
  677. package/lib/module/components/Modals/SettingsModals/Referrals/Referrals.js.map +1 -0
  678. package/lib/module/components/Modals/SettingsModals/SharedStyledComponents.js +70 -0
  679. package/lib/module/components/Modals/SettingsModals/SharedStyledComponents.js.map +1 -0
  680. package/lib/module/components/Modals/SettingsModals/Visibility/RadioInput.js +50 -0
  681. package/lib/module/components/Modals/SettingsModals/Visibility/RadioInput.js.map +1 -0
  682. package/lib/module/components/Modals/SettingsModals/Visibility/StyledComponents.js +30 -0
  683. package/lib/module/components/Modals/SettingsModals/Visibility/StyledComponents.js.map +1 -0
  684. package/lib/module/components/Modals/SettingsModals/Visibility/VisibilityModal.js +130 -0
  685. package/lib/module/components/Modals/SettingsModals/Visibility/VisibilityModal.js.map +1 -0
  686. package/lib/module/components/Modals/UserProfileModal/EditUserModal.js +140 -0
  687. package/lib/module/components/Modals/UserProfileModal/EditUserModal.js.map +1 -0
  688. package/lib/module/components/Modals/UserProfileModal/UserProfileModal.js +334 -0
  689. package/lib/module/components/Modals/UserProfileModal/UserProfileModal.js.map +1 -0
  690. package/lib/module/components/Modals/UserSettingsModal/UserSettingsModal.js +71 -0
  691. package/lib/module/components/Modals/UserSettingsModal/UserSettingsModal.js.map +1 -0
  692. package/lib/module/components/Modals/styledModalComponents.js +162 -0
  693. package/lib/module/components/Modals/styledModalComponents.js.map +1 -0
  694. package/lib/module/components/OperationalModal/OperationalModal.js +77 -0
  695. package/lib/module/components/OperationalModal/OperationalModal.js.map +1 -0
  696. package/lib/module/components/RoomComponents/ChatRoomItem.js +153 -0
  697. package/lib/module/components/RoomComponents/ChatRoomItem.js.map +1 -0
  698. package/lib/module/components/RoomComponents/LastMessageItem.js +52 -0
  699. package/lib/module/components/RoomComponents/LastMessageItem.js.map +1 -0
  700. package/lib/module/components/RoomComponents/styled/LastAudioMessage.js +60 -0
  701. package/lib/module/components/RoomComponents/styled/LastAudioMessage.js.map +1 -0
  702. package/lib/module/components/RoomComponents/styled/LastMessageEmoji.js +24 -0
  703. package/lib/module/components/RoomComponents/styled/LastMessageEmoji.js.map +1 -0
  704. package/lib/module/components/RoomComponents/styled/LastMessageFile.js +46 -0
  705. package/lib/module/components/RoomComponents/styled/LastMessageFile.js.map +1 -0
  706. package/lib/module/components/RoomComponents/styled/LastMessagePhoto.js +46 -0
  707. package/lib/module/components/RoomComponents/styled/LastMessagePhoto.js.map +1 -0
  708. package/lib/module/components/RoomComponents/styled/LastMessageVideo.js +64 -0
  709. package/lib/module/components/RoomComponents/styled/LastMessageVideo.js.map +1 -0
  710. package/lib/module/components/RoomComponents/styled/LastTextMessage.js +47 -0
  711. package/lib/module/components/RoomComponents/styled/LastTextMessage.js.map +1 -0
  712. package/lib/module/components/RoomComponents/styled/StyledRoomComponents.js +49 -0
  713. package/lib/module/components/RoomComponents/styled/StyledRoomComponents.js.map +1 -0
  714. package/lib/module/components/SortDropDown/index.js +62 -0
  715. package/lib/module/components/SortDropDown/index.js.map +1 -0
  716. package/lib/module/components/Thread/ThreadHeader.js +45 -0
  717. package/lib/module/components/Thread/ThreadHeader.js.map +1 -0
  718. package/lib/module/components/Thread/ThreadWrapper.js +206 -0
  719. package/lib/module/components/Thread/ThreadWrapper.js.map +1 -0
  720. package/lib/module/components/Toast/Toast.js +111 -0
  721. package/lib/module/components/Toast/Toast.js.map +1 -0
  722. package/lib/module/components/Toast/index.js +19 -0
  723. package/lib/module/components/Toast/index.js.map +1 -0
  724. package/lib/module/components/UsersList/StyledComponents.js +28 -0
  725. package/lib/module/components/UsersList/StyledComponents.js.map +1 -0
  726. package/lib/module/components/UsersList/UsersList.js +83 -0
  727. package/lib/module/components/UsersList/UsersList.js.map +1 -0
  728. package/lib/module/components/styled/ActionButton.js +37 -0
  729. package/lib/module/components/styled/ActionButton.js.map +1 -0
  730. package/lib/module/components/styled/AudioMessage.js +134 -0
  731. package/lib/module/components/styled/AudioMessage.js.map +1 -0
  732. package/lib/module/components/styled/Button.js +88 -0
  733. package/lib/module/components/styled/Button.js.map +1 -0
  734. package/lib/module/components/styled/ChatWrapperBox.js +11 -0
  735. package/lib/module/components/styled/ChatWrapperBox.js.map +1 -0
  736. package/lib/module/components/styled/DateLabel.js +68 -0
  737. package/lib/module/components/styled/DateLabel.js.map +1 -0
  738. package/lib/module/components/styled/Loader.js +56 -0
  739. package/lib/module/components/styled/Loader.js.map +1 -0
  740. package/lib/module/components/styled/MediaFilePreview.js +40 -0
  741. package/lib/module/components/styled/MediaFilePreview.js.map +1 -0
  742. package/lib/module/components/styled/MediaModal.js +54 -0
  743. package/lib/module/components/styled/MediaModal.js.map +1 -0
  744. package/lib/module/components/styled/MessageImage.js +47 -0
  745. package/lib/module/components/styled/MessageImage.js.map +1 -0
  746. package/lib/module/components/styled/NewMessageLabel.js +46 -0
  747. package/lib/module/components/styled/NewMessageLabel.js.map +1 -0
  748. package/lib/module/components/styled/RoomListComponents/index.js +169 -0
  749. package/lib/module/components/styled/RoomListComponents/index.js.map +1 -0
  750. package/lib/module/components/styled/SendInput.js +349 -0
  751. package/lib/module/components/styled/SendInput.js.map +1 -0
  752. package/lib/module/components/styled/StyledComponents.js +304 -0
  753. package/lib/module/components/styled/StyledComponents.js.map +1 -0
  754. package/lib/module/components/styled/StyledInput.js +94 -0
  755. package/lib/module/components/styled/StyledInput.js.map +1 -0
  756. package/lib/module/components/styled/StyledInputComponents/AudioComponents.js +4 -0
  757. package/lib/module/components/styled/StyledInputComponents/AudioComponents.js.map +1 -0
  758. package/lib/module/components/styled/StyledInputComponents/Composing.js +93 -0
  759. package/lib/module/components/styled/StyledInputComponents/Composing.js.map +1 -0
  760. package/lib/module/components/styled/StyledInputComponents/CustomTypingIndicator.js +248 -0
  761. package/lib/module/components/styled/StyledInputComponents/CustomTypingIndicator.js.map +1 -0
  762. package/lib/module/components/styled/StyledInputComponents/MediaComponents.js +82 -0
  763. package/lib/module/components/styled/StyledInputComponents/MediaComponents.js.map +1 -0
  764. package/lib/module/components/styled/StyledInputComponents/StyledInputComponents.js +114 -0
  765. package/lib/module/components/styled/StyledInputComponents/StyledInputComponents.js.map +1 -0
  766. package/lib/module/components/styled/StyledInputComponents/VideoComponents.js +44 -0
  767. package/lib/module/components/styled/StyledInputComponents/VideoComponents.js.map +1 -0
  768. package/lib/module/components/styled/TreadLabel.js +42 -0
  769. package/lib/module/components/styled/TreadLabel.js.map +1 -0
  770. package/lib/module/components/styled/UnsupportedType.js +70 -0
  771. package/lib/module/components/styled/UnsupportedType.js.map +1 -0
  772. package/lib/module/components/styled/VideoMessage.js +53 -0
  773. package/lib/module/components/styled/VideoMessage.js.map +1 -0
  774. package/lib/module/context/MessageNotificationContext.js +262 -0
  775. package/lib/module/context/MessageNotificationContext.js.map +1 -0
  776. package/lib/module/context/PushNotificationProvider.js +79 -0
  777. package/lib/module/context/PushNotificationProvider.js.map +1 -0
  778. package/lib/module/context/ToastContext.js +56 -0
  779. package/lib/module/context/ToastContext.js.map +1 -0
  780. package/lib/module/context/toastProvider.js +2 -0
  781. package/lib/module/context/toastProvider.js.map +1 -0
  782. package/lib/module/context/xmppProvider.js +345 -0
  783. package/lib/module/context/xmppProvider.js.map +1 -0
  784. package/lib/module/helpers/block_scroll.js +66 -0
  785. package/lib/module/helpers/block_scroll.js.map +1 -0
  786. package/lib/module/helpers/chatAutoEnterer.js +35 -0
  787. package/lib/module/helpers/chatAutoEnterer.js.map +1 -0
  788. package/lib/module/helpers/checkUniqueUsers.js +24 -0
  789. package/lib/module/helpers/checkUniqueUsers.js.map +1 -0
  790. package/lib/module/helpers/constants/CHAT_TYPES.js +10 -0
  791. package/lib/module/helpers/constants/CHAT_TYPES.js.map +1 -0
  792. package/lib/module/helpers/constants/LANGUAGE_OPTIONS.js +19 -0
  793. package/lib/module/helpers/constants/LANGUAGE_OPTIONS.js.map +1 -0
  794. package/lib/module/helpers/constants/LOCAL_STORAGE.js +6 -0
  795. package/lib/module/helpers/constants/LOCAL_STORAGE.js.map +1 -0
  796. package/lib/module/helpers/constants/MESSAGE_INTERACTIONS.js +23 -0
  797. package/lib/module/helpers/constants/MESSAGE_INTERACTIONS.js.map +1 -0
  798. package/lib/module/helpers/constants/MODAL_COMPONENTS.js +33 -0
  799. package/lib/module/helpers/constants/MODAL_COMPONENTS.js.map +1 -0
  800. package/lib/module/helpers/constants/MODAL_TYPES.js +27 -0
  801. package/lib/module/helpers/constants/MODAL_TYPES.js.map +1 -0
  802. package/lib/module/helpers/constants/PLATFORM_CONSTANTS.js +6 -0
  803. package/lib/module/helpers/constants/PLATFORM_CONSTANTS.js.map +1 -0
  804. package/lib/module/helpers/createMainMessageForThread.js +24 -0
  805. package/lib/module/helpers/createMainMessageForThread.js.map +1 -0
  806. package/lib/module/helpers/createMessageFromXml.js +100 -0
  807. package/lib/module/helpers/createMessageFromXml.js.map +1 -0
  808. package/lib/module/helpers/createRoomFromApi.js +25 -0
  809. package/lib/module/helpers/createRoomFromApi.js.map +1 -0
  810. package/lib/module/helpers/createUserNameFromSetUser.js +12 -0
  811. package/lib/module/helpers/createUserNameFromSetUser.js.map +1 -0
  812. package/lib/module/helpers/dateComparison.js +14 -0
  813. package/lib/module/helpers/dateComparison.js.map +1 -0
  814. package/lib/module/helpers/debounce.js +10 -0
  815. package/lib/module/helpers/debounce.js.map +1 -0
  816. package/lib/module/helpers/ensureScopedChatCache.js +49 -0
  817. package/lib/module/helpers/ensureScopedChatCache.js.map +1 -0
  818. package/lib/module/helpers/extractUniqueMembersFromRooms.js +29 -0
  819. package/lib/module/helpers/extractUniqueMembersFromRooms.js.map +1 -0
  820. package/lib/module/helpers/formatNumberWithCommas.js +6 -0
  821. package/lib/module/helpers/formatNumberWithCommas.js.map +1 -0
  822. package/lib/module/helpers/getBooleanFromString.js +16 -0
  823. package/lib/module/helpers/getBooleanFromString.js.map +1 -0
  824. package/lib/module/helpers/getDataFromXml.js +51 -0
  825. package/lib/module/helpers/getDataFromXml.js.map +1 -0
  826. package/lib/module/helpers/getNumberFromString.js +10 -0
  827. package/lib/module/helpers/getNumberFromString.js.map +1 -0
  828. package/lib/module/helpers/getRoomsWithRetry.js +31 -0
  829. package/lib/module/helpers/getRoomsWithRetry.js.map +1 -0
  830. package/lib/module/helpers/getTintedColor.js +20 -0
  831. package/lib/module/helpers/getTintedColor.js.map +1 -0
  832. package/lib/module/helpers/getUnnamedUsers.js +27 -0
  833. package/lib/module/helpers/getUnnamedUsers.js.map +1 -0
  834. package/lib/module/helpers/handleCopyClick.js +6 -0
  835. package/lib/module/helpers/handleCopyClick.js.map +1 -0
  836. package/lib/module/helpers/handleXmppError.js +22 -0
  837. package/lib/module/helpers/handleXmppError.js.map +1 -0
  838. package/lib/module/helpers/hashcolor.js +15 -0
  839. package/lib/module/helpers/hashcolor.js.map +1 -0
  840. package/lib/module/helpers/historyPreloadScheduler.js +223 -0
  841. package/lib/module/helpers/historyPreloadScheduler.js.map +1 -0
  842. package/lib/module/helpers/initRoomsPresence.js +26 -0
  843. package/lib/module/helpers/initRoomsPresence.js.map +1 -0
  844. package/lib/module/helpers/initXmppRooms.js +62 -0
  845. package/lib/module/helpers/initXmppRooms.js.map +1 -0
  846. package/lib/module/helpers/insertMessageWithDelimiter.js +70 -0
  847. package/lib/module/helpers/insertMessageWithDelimiter.js.map +1 -0
  848. package/lib/module/helpers/isChatIdPresentInArray.js +37 -0
  849. package/lib/module/helpers/isChatIdPresentInArray.js.map +1 -0
  850. package/lib/module/helpers/localStorageUser.js +8 -0
  851. package/lib/module/helpers/localStorageUser.js.map +1 -0
  852. package/lib/module/helpers/markdownParser.js +275 -0
  853. package/lib/module/helpers/markdownParser.js.map +1 -0
  854. package/lib/module/helpers/nanoToMs.js +6 -0
  855. package/lib/module/helpers/nanoToMs.js.map +1 -0
  856. package/lib/module/helpers/parseMessageBody.js +525 -0
  857. package/lib/module/helpers/parseMessageBody.js.map +1 -0
  858. package/lib/module/helpers/parseUrls.js +38 -0
  859. package/lib/module/helpers/parseUrls.js.map +1 -0
  860. package/lib/module/helpers/resolveInitBeforeLoadUser.js +242 -0
  861. package/lib/module/helpers/resolveInitBeforeLoadUser.js.map +1 -0
  862. package/lib/module/helpers/storeConsole.js +26 -0
  863. package/lib/module/helpers/storeConsole.js.map +1 -0
  864. package/lib/module/helpers/transformTranslatations.js +9 -0
  865. package/lib/module/helpers/transformTranslatations.js.map +1 -0
  866. package/lib/module/helpers/updateMessagesTillLast.js +70 -0
  867. package/lib/module/helpers/updateMessagesTillLast.js.map +1 -0
  868. package/lib/module/helpers/updatedChatLastTimestamps.js +27 -0
  869. package/lib/module/helpers/updatedChatLastTimestamps.js.map +1 -0
  870. package/lib/module/helpers/validator.js +15 -0
  871. package/lib/module/helpers/validator.js.map +1 -0
  872. package/lib/module/helpers/walletUsername.js +14 -0
  873. package/lib/module/helpers/walletUsername.js.map +1 -0
  874. package/lib/module/hooks/hooks.js +6 -0
  875. package/lib/module/hooks/hooks.js.map +1 -0
  876. package/lib/module/hooks/useChatSettingState.js +24 -0
  877. package/lib/module/hooks/useChatSettingState.js.map +1 -0
  878. package/lib/module/hooks/useChatWrapperInit.js +205 -0
  879. package/lib/module/hooks/useChatWrapperInit.js.map +1 -0
  880. package/lib/module/hooks/useComposing.js +45 -0
  881. package/lib/module/hooks/useComposing.js.map +1 -0
  882. package/lib/module/hooks/useCustomTypingIndicator.js +179 -0
  883. package/lib/module/hooks/useCustomTypingIndicator.js.map +1 -0
  884. package/lib/module/hooks/useEventHandlers.js +46 -0
  885. package/lib/module/hooks/useEventHandlers.js.map +1 -0
  886. package/lib/module/hooks/useGetNewArchRoom.js +45 -0
  887. package/lib/module/hooks/useGetNewArchRoom.js.map +1 -0
  888. package/lib/module/hooks/useHeapSender.js +68 -0
  889. package/lib/module/hooks/useHeapSender.js.map +1 -0
  890. package/lib/module/hooks/useLocalStorage.js +60 -0
  891. package/lib/module/hooks/useLocalStorage.js.map +1 -0
  892. package/lib/module/hooks/useLogout.js +143 -0
  893. package/lib/module/hooks/useLogout.js.map +1 -0
  894. package/lib/module/hooks/useMessageHeapState.js +12 -0
  895. package/lib/module/hooks/useMessageHeapState.js.map +1 -0
  896. package/lib/module/hooks/useMessageLoaderQueue.js +56 -0
  897. package/lib/module/hooks/useMessageLoaderQueue.js.map +1 -0
  898. package/lib/module/hooks/useMessageQueue.js +107 -0
  899. package/lib/module/hooks/useMessageQueue.js.map +1 -0
  900. package/lib/module/hooks/usePendingNotification.js +43 -0
  901. package/lib/module/hooks/usePendingNotification.js.map +1 -0
  902. package/lib/module/hooks/usePrevious.js +16 -0
  903. package/lib/module/hooks/usePrevious.js.map +1 -0
  904. package/lib/module/hooks/usePushNotifications.js +92 -0
  905. package/lib/module/hooks/usePushNotifications.js.map +1 -0
  906. package/lib/module/hooks/useQRCodeChatHandler.js +48 -0
  907. package/lib/module/hooks/useQRCodeChatHandler.js.map +1 -0
  908. package/lib/module/hooks/useRoomInitialization.js +143 -0
  909. package/lib/module/hooks/useRoomInitialization.js.map +1 -0
  910. package/lib/module/hooks/useRoomState.js +32 -0
  911. package/lib/module/hooks/useRoomState.js.map +1 -0
  912. package/lib/module/hooks/useRoomUrl.js +30 -0
  913. package/lib/module/hooks/useRoomUrl.js.map +1 -0
  914. package/lib/module/hooks/useSendMessage.js +308 -0
  915. package/lib/module/hooks/useSendMessage.js.map +1 -0
  916. package/lib/module/hooks/useUnreadMessagesCounter.js +37 -0
  917. package/lib/module/hooks/useUnreadMessagesCounter.js.map +1 -0
  918. package/lib/module/hooks/useXmppInitialization.js +107 -0
  919. package/lib/module/hooks/useXmppInitialization.js.map +1 -0
  920. package/lib/module/main.js +39 -0
  921. package/lib/module/main.js.map +1 -0
  922. package/lib/module/networking/api-requests/auth.api.js +117 -0
  923. package/lib/module/networking/api-requests/auth.api.js.map +1 -0
  924. package/lib/module/networking/api-requests/push.api.js +39 -0
  925. package/lib/module/networking/api-requests/push.api.js.map +1 -0
  926. package/lib/module/networking/api-requests/roomMembers.api.js +17 -0
  927. package/lib/module/networking/api-requests/roomMembers.api.js.map +1 -0
  928. package/lib/module/networking/api-requests/rooms.api.js +230 -0
  929. package/lib/module/networking/api-requests/rooms.api.js.map +1 -0
  930. package/lib/module/networking/api-requests/user.api.js +63 -0
  931. package/lib/module/networking/api-requests/user.api.js.map +1 -0
  932. package/lib/module/networking/apiClient.js +166 -0
  933. package/lib/module/networking/apiClient.js.map +1 -0
  934. package/lib/module/networking/helpers/refreshChecker.js +12 -0
  935. package/lib/module/networking/helpers/refreshChecker.js.map +1 -0
  936. package/lib/module/networking/stanzaHandlers.js +328 -0
  937. package/lib/module/networking/stanzaHandlers.js.map +1 -0
  938. package/lib/module/networking/xmpp/actionSetTimestampToPrivateStore.xmpp.js +24 -0
  939. package/lib/module/networking/xmpp/actionSetTimestampToPrivateStore.xmpp.js.map +1 -0
  940. package/lib/module/networking/xmpp/allRoomPresences.xmpp.js +9 -0
  941. package/lib/module/networking/xmpp/allRoomPresences.xmpp.js.map +1 -0
  942. package/lib/module/networking/xmpp/createPrivateRoom.xmpp.js +20 -0
  943. package/lib/module/networking/xmpp/createPrivateRoom.xmpp.js.map +1 -0
  944. package/lib/module/networking/xmpp/createRoom.xmpp.js +27 -0
  945. package/lib/module/networking/xmpp/createRoom.xmpp.js.map +1 -0
  946. package/lib/module/networking/xmpp/createRoomPresence.xmpp.js +48 -0
  947. package/lib/module/networking/xmpp/createRoomPresence.xmpp.js.map +1 -0
  948. package/lib/module/networking/xmpp/createTimeoutPromise.xmpp.js +15 -0
  949. package/lib/module/networking/xmpp/createTimeoutPromise.xmpp.js.map +1 -0
  950. package/lib/module/networking/xmpp/deleteMessage.xmpp.js +15 -0
  951. package/lib/module/networking/xmpp/deleteMessage.xmpp.js.map +1 -0
  952. package/lib/module/networking/xmpp/editMessage.xmpp.js +40 -0
  953. package/lib/module/networking/xmpp/editMessage.xmpp.js.map +1 -0
  954. package/lib/module/networking/xmpp/flushLastViewedToPrivateStore.js +78 -0
  955. package/lib/module/networking/xmpp/flushLastViewedToPrivateStore.js.map +1 -0
  956. package/lib/module/networking/xmpp/getChatsPrivateStoreRequest.xmpp.js +49 -0
  957. package/lib/module/networking/xmpp/getChatsPrivateStoreRequest.xmpp.js.map +1 -0
  958. package/lib/module/networking/xmpp/getHistory.xmpp.js +96 -0
  959. package/lib/module/networking/xmpp/getHistory.xmpp.js.map +1 -0
  960. package/lib/module/networking/xmpp/getLastMessageArchive.xmpp.js +16 -0
  961. package/lib/module/networking/xmpp/getLastMessageArchive.xmpp.js.map +1 -0
  962. package/lib/module/networking/xmpp/getRoomInfo.xmpp.js +15 -0
  963. package/lib/module/networking/xmpp/getRoomInfo.xmpp.js.map +1 -0
  964. package/lib/module/networking/xmpp/getRoomMembers.xmpp.js +14 -0
  965. package/lib/module/networking/xmpp/getRoomMembers.xmpp.js.map +1 -0
  966. package/lib/module/networking/xmpp/getRooms.xmpp.js +35 -0
  967. package/lib/module/networking/xmpp/getRooms.xmpp.js.map +1 -0
  968. package/lib/module/networking/xmpp/getRoomsPaged.xmpp.js +43 -0
  969. package/lib/module/networking/xmpp/getRoomsPaged.xmpp.js.map +1 -0
  970. package/lib/module/networking/xmpp/handlePong.xmpp.js +6 -0
  971. package/lib/module/networking/xmpp/handlePong.xmpp.js.map +1 -0
  972. package/lib/module/networking/xmpp/handleStanzas.xmpp.js +40 -0
  973. package/lib/module/networking/xmpp/handleStanzas.xmpp.js.map +1 -0
  974. package/lib/module/networking/xmpp/inviteRoomRequest.xmpp.js +15 -0
  975. package/lib/module/networking/xmpp/inviteRoomRequest.xmpp.js.map +1 -0
  976. package/lib/module/networking/xmpp/leaveTheRoom.xmpp.js +14 -0
  977. package/lib/module/networking/xmpp/leaveTheRoom.xmpp.js.map +1 -0
  978. package/lib/module/networking/xmpp/listenerManager.js +75 -0
  979. package/lib/module/networking/xmpp/listenerManager.js.map +1 -0
  980. package/lib/module/networking/xmpp/presenceInRoom.xmpp.js +45 -0
  981. package/lib/module/networking/xmpp/presenceInRoom.xmpp.js.map +1 -0
  982. package/lib/module/networking/xmpp/roomConfig.xmpp.js +40 -0
  983. package/lib/module/networking/xmpp/roomConfig.xmpp.js.map +1 -0
  984. package/lib/module/networking/xmpp/sendMediaMessage.xmpp.js +89 -0
  985. package/lib/module/networking/xmpp/sendMediaMessage.xmpp.js.map +1 -0
  986. package/lib/module/networking/xmpp/sendMessageReaction.xmpp.js +26 -0
  987. package/lib/module/networking/xmpp/sendMessageReaction.xmpp.js.map +1 -0
  988. package/lib/module/networking/xmpp/sendPing.xmpp.js +17 -0
  989. package/lib/module/networking/xmpp/sendPing.xmpp.js.map +1 -0
  990. package/lib/module/networking/xmpp/sendTextMessage.xmpp.js +86 -0
  991. package/lib/module/networking/xmpp/sendTextMessage.xmpp.js.map +1 -0
  992. package/lib/module/networking/xmpp/sendTextMessageWithTranslateTag.xmpp.js +22 -0
  993. package/lib/module/networking/xmpp/sendTextMessageWithTranslateTag.xmpp.js.map +1 -0
  994. package/lib/module/networking/xmpp/sendTypingRequest.xmpp.js +17 -0
  995. package/lib/module/networking/xmpp/sendTypingRequest.xmpp.js.map +1 -0
  996. package/lib/module/networking/xmpp/setChatsPrivateStoreRequest.xmpp.js +32 -0
  997. package/lib/module/networking/xmpp/setChatsPrivateStoreRequest.xmpp.js.map +1 -0
  998. package/lib/module/networking/xmpp/setMeAsOwner.xmpp.js +34 -0
  999. package/lib/module/networking/xmpp/setMeAsOwner.xmpp.js.map +1 -0
  1000. package/lib/module/networking/xmpp/setRoomImage.xmpp.js +18 -0
  1001. package/lib/module/networking/xmpp/setRoomImage.xmpp.js.map +1 -0
  1002. package/lib/module/networking/xmpp/setVCard.xmpp.js +13 -0
  1003. package/lib/module/networking/xmpp/setVCard.xmpp.js.map +1 -0
  1004. package/lib/module/networking/xmpp/subscribeToRoomMessages.xmpp.js +61 -0
  1005. package/lib/module/networking/xmpp/subscribeToRoomMessages.xmpp.js.map +1 -0
  1006. package/lib/module/networking/xmppClient.js +491 -0
  1007. package/lib/module/networking/xmppClient.js.map +1 -0
  1008. package/lib/module/roomStore/Middleware/logoutMiddleware.js +31 -0
  1009. package/lib/module/roomStore/Middleware/logoutMiddleware.js.map +1 -0
  1010. package/lib/module/roomStore/Middleware/newMessageMidlleware.js +83 -0
  1011. package/lib/module/roomStore/Middleware/newMessageMidlleware.js.map +1 -0
  1012. package/lib/module/roomStore/Middleware/reactionsMiddleware.js +64 -0
  1013. package/lib/module/roomStore/Middleware/reactionsMiddleware.js.map +1 -0
  1014. package/lib/module/roomStore/Middleware/testMiddleware.js +17 -0
  1015. package/lib/module/roomStore/Middleware/testMiddleware.js.map +1 -0
  1016. package/lib/module/roomStore/Middleware/unreadMidlleware.js +134 -0
  1017. package/lib/module/roomStore/Middleware/unreadMidlleware.js.map +1 -0
  1018. package/lib/module/roomStore/chatSettingsSlice.js +160 -0
  1019. package/lib/module/roomStore/chatSettingsSlice.js.map +1 -0
  1020. package/lib/module/roomStore/index.js +54 -0
  1021. package/lib/module/roomStore/index.js.map +1 -0
  1022. package/lib/module/roomStore/persistence.js +139 -0
  1023. package/lib/module/roomStore/persistence.js.map +1 -0
  1024. package/lib/module/roomStore/roomHeapSlice.js +37 -0
  1025. package/lib/module/roomStore/roomHeapSlice.js.map +1 -0
  1026. package/lib/module/roomStore/roomsSlice.js +467 -0
  1027. package/lib/module/roomStore/roomsSlice.js.map +1 -0
  1028. package/lib/module/services/pushNotifications.js +130 -0
  1029. package/lib/module/services/pushNotifications.js.map +1 -0
  1030. package/lib/module/services/pushSubscriptionService.js +133 -0
  1031. package/lib/module/services/pushSubscriptionService.js.map +1 -0
  1032. package/lib/module/types/messages.js +2 -0
  1033. package/lib/module/types/messages.js.map +1 -0
  1034. package/lib/module/types/models/action.model.js +4 -0
  1035. package/lib/module/types/models/action.model.js.map +1 -0
  1036. package/lib/module/types/models/config.model.js +2 -0
  1037. package/lib/module/types/models/config.model.js.map +1 -0
  1038. package/lib/module/types/models/customComponents.model.js +4 -0
  1039. package/lib/module/types/models/customComponents.model.js.map +1 -0
  1040. package/lib/module/types/models/language.model.js +2 -0
  1041. package/lib/module/types/models/language.model.js.map +1 -0
  1042. package/lib/module/types/models/media.model.js +2 -0
  1043. package/lib/module/types/models/media.model.js.map +1 -0
  1044. package/lib/module/types/models/message.model.js +4 -0
  1045. package/lib/module/types/models/message.model.js.map +1 -0
  1046. package/lib/module/types/models/modal.model.js +4 -0
  1047. package/lib/module/types/models/modal.model.js.map +1 -0
  1048. package/lib/module/types/models/room.model.js +4 -0
  1049. package/lib/module/types/models/room.model.js.map +1 -0
  1050. package/lib/module/types/models/user.model.js +4 -0
  1051. package/lib/module/types/models/user.model.js.map +1 -0
  1052. package/lib/module/types/models/xmpp.model.js +4 -0
  1053. package/lib/module/types/models/xmpp.model.js.map +1 -0
  1054. package/lib/module/types/types.js +4 -0
  1055. package/lib/module/types/types.js.map +1 -0
  1056. package/lib/module/utils/PriorityQueue.js +40 -0
  1057. package/lib/module/utils/PriorityQueue.js.map +1 -0
  1058. package/lib/module/utils/actionHelpers.js +34 -0
  1059. package/lib/module/utils/actionHelpers.js.map +1 -0
  1060. package/lib/module/utils/actionLogger.js +48 -0
  1061. package/lib/module/utils/actionLogger.js.map +1 -0
  1062. package/lib/module/utils/clientRegistry.js +67 -0
  1063. package/lib/module/utils/clientRegistry.js.map +1 -0
  1064. package/lib/module/utils/devLogger.js +181 -0
  1065. package/lib/module/utils/devLogger.js.map +1 -0
  1066. package/lib/module/utils/messageNotificationManager.js +88 -0
  1067. package/lib/module/utils/messageNotificationManager.js.map +1 -0
  1068. package/lib/module/utils/resendMessage.js +42 -0
  1069. package/lib/module/utils/resendMessage.js.map +1 -0
  1070. package/lib/module/utils/toastEmitter.js +26 -0
  1071. package/lib/module/utils/toastEmitter.js.map +1 -0
  1072. package/lib/module/utils/xmppMemoryMonitor.js +47 -0
  1073. package/lib/module/utils/xmppMemoryMonitor.js.map +1 -0
  1074. package/lib/module/version.js +4 -0
  1075. package/lib/module/version.js.map +1 -0
  1076. package/lib/typescript/assets/BG.d.ts +5 -0
  1077. package/lib/typescript/assets/BG.d.ts.map +1 -0
  1078. package/lib/typescript/assets/ForzaCare.d.ts +3 -0
  1079. package/lib/typescript/assets/ForzaCare.d.ts.map +1 -0
  1080. package/lib/typescript/assets/icons.d.ts +158 -0
  1081. package/lib/typescript/assets/icons.d.ts.map +1 -0
  1082. package/lib/typescript/assets/images.d.ts +6 -0
  1083. package/lib/typescript/assets/images.d.ts.map +1 -0
  1084. package/lib/typescript/components/AuthForms/Login.d.ts +8 -0
  1085. package/lib/typescript/components/AuthForms/Login.d.ts.map +1 -0
  1086. package/lib/typescript/components/AuthForms/LoginAnonym.d.ts +8 -0
  1087. package/lib/typescript/components/AuthForms/LoginAnonym.d.ts.map +1 -0
  1088. package/lib/typescript/components/AuthForms/Register.d.ts +4 -0
  1089. package/lib/typescript/components/AuthForms/Register.d.ts.map +1 -0
  1090. package/lib/typescript/components/ContextMenu/ContextMenuComponents.d.ts +14 -0
  1091. package/lib/typescript/components/ContextMenu/ContextMenuComponents.d.ts.map +1 -0
  1092. package/lib/typescript/components/DropdownMenu/DropdownMenu.d.ts +20 -0
  1093. package/lib/typescript/components/DropdownMenu/DropdownMenu.d.ts.map +1 -0
  1094. package/lib/typescript/components/ExampleComponents/CustomMessage.d.ts +29 -0
  1095. package/lib/typescript/components/ExampleComponents/CustomMessage.d.ts.map +1 -0
  1096. package/lib/typescript/components/ExampleComponents/CustomTypingIndicatorExamples.d.ts +18 -0
  1097. package/lib/typescript/components/ExampleComponents/CustomTypingIndicatorExamples.d.ts.map +1 -0
  1098. package/lib/typescript/components/Header/HeaderRoomList.d.ts +8 -0
  1099. package/lib/typescript/components/Header/HeaderRoomList.d.ts.map +1 -0
  1100. package/lib/typescript/components/InputComponents/AudioInput.d.ts +9 -0
  1101. package/lib/typescript/components/InputComponents/AudioInput.d.ts.map +1 -0
  1102. package/lib/typescript/components/InputComponents/AudioRecorder.d.ts +9 -0
  1103. package/lib/typescript/components/InputComponents/AudioRecorder.d.ts.map +1 -0
  1104. package/lib/typescript/components/InputComponents/MediaInput.d.ts +16 -0
  1105. package/lib/typescript/components/InputComponents/MediaInput.d.ts.map +1 -0
  1106. package/lib/typescript/components/InputComponents/RecordingIndicator.d.ts +4 -0
  1107. package/lib/typescript/components/InputComponents/RecordingIndicator.d.ts.map +1 -0
  1108. package/lib/typescript/components/InputComponents/Search.d.ts +12 -0
  1109. package/lib/typescript/components/InputComponents/Search.d.ts.map +1 -0
  1110. package/lib/typescript/components/InputComponents/TextInput.d.ts +14 -0
  1111. package/lib/typescript/components/InputComponents/TextInput.d.ts.map +1 -0
  1112. package/lib/typescript/components/MainComponents/ChatHeader.d.ts +10 -0
  1113. package/lib/typescript/components/MainComponents/ChatHeader.d.ts.map +1 -0
  1114. package/lib/typescript/components/MainComponents/ChatRoom.d.ts +15 -0
  1115. package/lib/typescript/components/MainComponents/ChatRoom.d.ts.map +1 -0
  1116. package/lib/typescript/components/MainComponents/ChatWrapper.d.ts +17 -0
  1117. package/lib/typescript/components/MainComponents/ChatWrapper.d.ts.map +1 -0
  1118. package/lib/typescript/components/MainComponents/ChooseChatMessage.d.ts +6 -0
  1119. package/lib/typescript/components/MainComponents/ChooseChatMessage.d.ts.map +1 -0
  1120. package/lib/typescript/components/MainComponents/ConnectionBanner.d.ts +5 -0
  1121. package/lib/typescript/components/MainComponents/ConnectionBanner.d.ts.map +1 -0
  1122. package/lib/typescript/components/MainComponents/EditWrapper.d.ts +12 -0
  1123. package/lib/typescript/components/MainComponents/EditWrapper.d.ts.map +1 -0
  1124. package/lib/typescript/components/MainComponents/LoginWrapper.d.ts +15 -0
  1125. package/lib/typescript/components/MainComponents/LoginWrapper.d.ts.map +1 -0
  1126. package/lib/typescript/components/MainComponents/MediaMessage.d.ts +11 -0
  1127. package/lib/typescript/components/MainComponents/MediaMessage.d.ts.map +1 -0
  1128. package/lib/typescript/components/MainComponents/MessageContainer.d.ts +27 -0
  1129. package/lib/typescript/components/MainComponents/MessageContainer.d.ts.map +1 -0
  1130. package/lib/typescript/components/MainComponents/MessageList.d.ts +27 -0
  1131. package/lib/typescript/components/MainComponents/MessageList.d.ts.map +1 -0
  1132. package/lib/typescript/components/MainComponents/NoMessagesPlaceholder.d.ts +3 -0
  1133. package/lib/typescript/components/MainComponents/NoMessagesPlaceholder.d.ts.map +1 -0
  1134. package/lib/typescript/components/MainComponents/ProfileImagePlaceholder.d.ts +27 -0
  1135. package/lib/typescript/components/MainComponents/ProfileImagePlaceholder.d.ts.map +1 -0
  1136. package/lib/typescript/components/MainComponents/RNStyled.d.ts +7 -0
  1137. package/lib/typescript/components/MainComponents/RNStyled.d.ts.map +1 -0
  1138. package/lib/typescript/components/MainComponents/ReduxWrapper.d.ts +18 -0
  1139. package/lib/typescript/components/MainComponents/ReduxWrapper.d.ts.map +1 -0
  1140. package/lib/typescript/components/MainComponents/RoomList.d.ts +11 -0
  1141. package/lib/typescript/components/MainComponents/RoomList.d.ts.map +1 -0
  1142. package/lib/typescript/components/MainComponents/Select.d.ts +21 -0
  1143. package/lib/typescript/components/MainComponents/Select.d.ts.map +1 -0
  1144. package/lib/typescript/components/MainComponents/Switch.d.ts +10 -0
  1145. package/lib/typescript/components/MainComponents/Switch.d.ts.map +1 -0
  1146. package/lib/typescript/components/MainComponents/SystemMessage.d.ts +18 -0
  1147. package/lib/typescript/components/MainComponents/SystemMessage.d.ts.map +1 -0
  1148. package/lib/typescript/components/Menu/HeaderRoomListMenu.d.ts +11 -0
  1149. package/lib/typescript/components/Menu/HeaderRoomListMenu.d.ts.map +1 -0
  1150. package/lib/typescript/components/MenuRoom/MenuRoom.d.ts +7 -0
  1151. package/lib/typescript/components/MenuRoom/MenuRoom.d.ts.map +1 -0
  1152. package/lib/typescript/components/MessageBubble/Avatar.d.ts +10 -0
  1153. package/lib/typescript/components/MessageBubble/Avatar.d.ts.map +1 -0
  1154. package/lib/typescript/components/MessageBubble/BottomReplyContainer.d.ts +10 -0
  1155. package/lib/typescript/components/MessageBubble/BottomReplyContainer.d.ts.map +1 -0
  1156. package/lib/typescript/components/MessageBubble/CustomDivider.d.ts +6 -0
  1157. package/lib/typescript/components/MessageBubble/CustomDivider.d.ts.map +1 -0
  1158. package/lib/typescript/components/MessageBubble/DeletedMessage.d.ts +2 -0
  1159. package/lib/typescript/components/MessageBubble/DeletedMessage.d.ts.map +1 -0
  1160. package/lib/typescript/components/MessageBubble/Message.d.ts +5 -0
  1161. package/lib/typescript/components/MessageBubble/Message.d.ts.map +1 -0
  1162. package/lib/typescript/components/MessageBubble/MessageInteractions.d.ts +19 -0
  1163. package/lib/typescript/components/MessageBubble/MessageInteractions.d.ts.map +1 -0
  1164. package/lib/typescript/components/MessageBubble/MessageReaction.d.ts +11 -0
  1165. package/lib/typescript/components/MessageBubble/MessageReaction.d.ts.map +1 -0
  1166. package/lib/typescript/components/MessageBubble/MessageReply.d.ts +17 -0
  1167. package/lib/typescript/components/MessageBubble/MessageReply.d.ts.map +1 -0
  1168. package/lib/typescript/components/MessageBubble/MessageTranslations.d.ts +10 -0
  1169. package/lib/typescript/components/MessageBubble/MessageTranslations.d.ts.map +1 -0
  1170. package/lib/typescript/components/Modals/AddMembersModal/AddMembersModal.d.ts +4 -0
  1171. package/lib/typescript/components/Modals/AddMembersModal/AddMembersModal.d.ts.map +1 -0
  1172. package/lib/typescript/components/Modals/AttachSheet/AttachSheet.d.ts +13 -0
  1173. package/lib/typescript/components/Modals/AttachSheet/AttachSheet.d.ts.map +1 -0
  1174. package/lib/typescript/components/Modals/ChatProfileModal/ChatProfileModal.d.ts +7 -0
  1175. package/lib/typescript/components/Modals/ChatProfileModal/ChatProfileModal.d.ts.map +1 -0
  1176. package/lib/typescript/components/Modals/ChatProfileModal/DeleteChatModal.d.ts +8 -0
  1177. package/lib/typescript/components/Modals/ChatProfileModal/DeleteChatModal.d.ts.map +1 -0
  1178. package/lib/typescript/components/Modals/FilePreviewModal/FilePreviewModal.d.ts +8 -0
  1179. package/lib/typescript/components/Modals/FilePreviewModal/FilePreviewModal.d.ts.map +1 -0
  1180. package/lib/typescript/components/Modals/FilePreviewModal/PdfView.d.ts +7 -0
  1181. package/lib/typescript/components/Modals/FilePreviewModal/PdfView.d.ts.map +1 -0
  1182. package/lib/typescript/components/Modals/Modal/Modal.d.ts +10 -0
  1183. package/lib/typescript/components/Modals/Modal/Modal.d.ts.map +1 -0
  1184. package/lib/typescript/components/Modals/ModalHeaderComponent.d.ts +10 -0
  1185. package/lib/typescript/components/Modals/ModalHeaderComponent.d.ts.map +1 -0
  1186. package/lib/typescript/components/Modals/ModalSelectMedia/ModalSelectMedia.d.ts +9 -0
  1187. package/lib/typescript/components/Modals/ModalSelectMedia/ModalSelectMedia.d.ts.map +1 -0
  1188. package/lib/typescript/components/Modals/ModalWrapper/ModalWrapper.d.ts +16 -0
  1189. package/lib/typescript/components/Modals/ModalWrapper/ModalWrapper.d.ts.map +1 -0
  1190. package/lib/typescript/components/Modals/NewChatModal/ModalContent.d.ts +30 -0
  1191. package/lib/typescript/components/Modals/NewChatModal/ModalContent.d.ts.map +1 -0
  1192. package/lib/typescript/components/Modals/NewChatModal/NewChatModal.d.ts +7 -0
  1193. package/lib/typescript/components/Modals/NewChatModal/NewChatModal.d.ts.map +1 -0
  1194. package/lib/typescript/components/Modals/NewChatModal/UpdNewChatModal.d.ts +4 -0
  1195. package/lib/typescript/components/Modals/NewChatModal/UpdNewChatModal.d.ts.map +1 -0
  1196. package/lib/typescript/components/Modals/SelectUsersModal/SelectUsersModal.d.ts +4 -0
  1197. package/lib/typescript/components/Modals/SelectUsersModal/SelectUsersModal.d.ts.map +1 -0
  1198. package/lib/typescript/components/Modals/SettingsModals/BlockedUsers/BlockedUsersModal.d.ts +7 -0
  1199. package/lib/typescript/components/Modals/SettingsModals/BlockedUsers/BlockedUsersModal.d.ts.map +1 -0
  1200. package/lib/typescript/components/Modals/SettingsModals/DocumentShares/DocumentSharesModal.d.ts +8 -0
  1201. package/lib/typescript/components/Modals/SettingsModals/DocumentShares/DocumentSharesModal.d.ts.map +1 -0
  1202. package/lib/typescript/components/Modals/SettingsModals/ManageDataModal/ManageDataModal.d.ts +7 -0
  1203. package/lib/typescript/components/Modals/SettingsModals/ManageDataModal/ManageDataModal.d.ts.map +1 -0
  1204. package/lib/typescript/components/Modals/SettingsModals/ManageDataModal/StyledComponents.d.ts +2 -0
  1205. package/lib/typescript/components/Modals/SettingsModals/ManageDataModal/StyledComponents.d.ts.map +1 -0
  1206. package/lib/typescript/components/Modals/SettingsModals/ProfileShares/ProfileShares.d.ts +7 -0
  1207. package/lib/typescript/components/Modals/SettingsModals/ProfileShares/ProfileShares.d.ts.map +1 -0
  1208. package/lib/typescript/components/Modals/SettingsModals/Referrals/Referrals.d.ts +7 -0
  1209. package/lib/typescript/components/Modals/SettingsModals/Referrals/Referrals.d.ts.map +1 -0
  1210. package/lib/typescript/components/Modals/SettingsModals/SharedStyledComponents.d.ts +48 -0
  1211. package/lib/typescript/components/Modals/SettingsModals/SharedStyledComponents.d.ts.map +1 -0
  1212. package/lib/typescript/components/Modals/SettingsModals/Visibility/RadioInput.d.ts +13 -0
  1213. package/lib/typescript/components/Modals/SettingsModals/Visibility/RadioInput.d.ts.map +1 -0
  1214. package/lib/typescript/components/Modals/SettingsModals/Visibility/StyledComponents.d.ts +6 -0
  1215. package/lib/typescript/components/Modals/SettingsModals/Visibility/StyledComponents.d.ts.map +1 -0
  1216. package/lib/typescript/components/Modals/SettingsModals/Visibility/VisibilityModal.d.ts +6 -0
  1217. package/lib/typescript/components/Modals/SettingsModals/Visibility/VisibilityModal.d.ts.map +1 -0
  1218. package/lib/typescript/components/Modals/UserProfileModal/EditUserModal.d.ts +9 -0
  1219. package/lib/typescript/components/Modals/UserProfileModal/EditUserModal.d.ts.map +1 -0
  1220. package/lib/typescript/components/Modals/UserProfileModal/UserProfileModal.d.ts +7 -0
  1221. package/lib/typescript/components/Modals/UserProfileModal/UserProfileModal.d.ts.map +1 -0
  1222. package/lib/typescript/components/Modals/UserSettingsModal/UserSettingsModal.d.ts +7 -0
  1223. package/lib/typescript/components/Modals/UserSettingsModal/UserSettingsModal.d.ts.map +1 -0
  1224. package/lib/typescript/components/Modals/styledModalComponents.d.ts +30 -0
  1225. package/lib/typescript/components/Modals/styledModalComponents.d.ts.map +1 -0
  1226. package/lib/typescript/components/OperationalModal/OperationalModal.d.ts +9 -0
  1227. package/lib/typescript/components/OperationalModal/OperationalModal.d.ts.map +1 -0
  1228. package/lib/typescript/components/RoomComponents/ChatRoomItem.d.ts +11 -0
  1229. package/lib/typescript/components/RoomComponents/ChatRoomItem.d.ts.map +1 -0
  1230. package/lib/typescript/components/RoomComponents/LastMessageItem.d.ts +8 -0
  1231. package/lib/typescript/components/RoomComponents/LastMessageItem.d.ts.map +1 -0
  1232. package/lib/typescript/components/RoomComponents/styled/LastAudioMessage.d.ts +7 -0
  1233. package/lib/typescript/components/RoomComponents/styled/LastAudioMessage.d.ts.map +1 -0
  1234. package/lib/typescript/components/RoomComponents/styled/LastMessageEmoji.d.ts +7 -0
  1235. package/lib/typescript/components/RoomComponents/styled/LastMessageEmoji.d.ts.map +1 -0
  1236. package/lib/typescript/components/RoomComponents/styled/LastMessageFile.d.ts +7 -0
  1237. package/lib/typescript/components/RoomComponents/styled/LastMessageFile.d.ts.map +1 -0
  1238. package/lib/typescript/components/RoomComponents/styled/LastMessagePhoto.d.ts +7 -0
  1239. package/lib/typescript/components/RoomComponents/styled/LastMessagePhoto.d.ts.map +1 -0
  1240. package/lib/typescript/components/RoomComponents/styled/LastMessageVideo.d.ts +7 -0
  1241. package/lib/typescript/components/RoomComponents/styled/LastMessageVideo.d.ts.map +1 -0
  1242. package/lib/typescript/components/RoomComponents/styled/LastTextMessage.d.ts +7 -0
  1243. package/lib/typescript/components/RoomComponents/styled/LastTextMessage.d.ts.map +1 -0
  1244. package/lib/typescript/components/RoomComponents/styled/StyledRoomComponents.d.ts +7 -0
  1245. package/lib/typescript/components/RoomComponents/styled/StyledRoomComponents.d.ts.map +1 -0
  1246. package/lib/typescript/components/SortDropDown/index.d.ts +9 -0
  1247. package/lib/typescript/components/SortDropDown/index.d.ts.map +1 -0
  1248. package/lib/typescript/components/Thread/ThreadHeader.d.ts +7 -0
  1249. package/lib/typescript/components/Thread/ThreadHeader.d.ts.map +1 -0
  1250. package/lib/typescript/components/Thread/ThreadWrapper.d.ts +14 -0
  1251. package/lib/typescript/components/Thread/ThreadWrapper.d.ts.map +1 -0
  1252. package/lib/typescript/components/Toast/Toast.d.ts +11 -0
  1253. package/lib/typescript/components/Toast/Toast.d.ts.map +1 -0
  1254. package/lib/typescript/components/Toast/index.d.ts +8 -0
  1255. package/lib/typescript/components/Toast/index.d.ts.map +1 -0
  1256. package/lib/typescript/components/UsersList/StyledComponents.d.ts +5 -0
  1257. package/lib/typescript/components/UsersList/StyledComponents.d.ts.map +1 -0
  1258. package/lib/typescript/components/UsersList/UsersList.d.ts +12 -0
  1259. package/lib/typescript/components/UsersList/UsersList.d.ts.map +1 -0
  1260. package/lib/typescript/components/styled/ActionButton.d.ts +9 -0
  1261. package/lib/typescript/components/styled/ActionButton.d.ts.map +1 -0
  1262. package/lib/typescript/components/styled/AudioMessage.d.ts +6 -0
  1263. package/lib/typescript/components/styled/AudioMessage.d.ts.map +1 -0
  1264. package/lib/typescript/components/styled/Button.d.ts +21 -0
  1265. package/lib/typescript/components/styled/Button.d.ts.map +1 -0
  1266. package/lib/typescript/components/styled/ChatWrapperBox.d.ts +2 -0
  1267. package/lib/typescript/components/styled/ChatWrapperBox.d.ts.map +1 -0
  1268. package/lib/typescript/components/styled/DateLabel.d.ts +21 -0
  1269. package/lib/typescript/components/styled/DateLabel.d.ts.map +1 -0
  1270. package/lib/typescript/components/styled/Loader.d.ts +9 -0
  1271. package/lib/typescript/components/styled/Loader.d.ts.map +1 -0
  1272. package/lib/typescript/components/styled/MediaFilePreview.d.ts +9 -0
  1273. package/lib/typescript/components/styled/MediaFilePreview.d.ts.map +1 -0
  1274. package/lib/typescript/components/styled/MediaModal.d.ts +15 -0
  1275. package/lib/typescript/components/styled/MediaModal.d.ts.map +1 -0
  1276. package/lib/typescript/components/styled/MessageImage.d.ts +9 -0
  1277. package/lib/typescript/components/styled/MessageImage.d.ts.map +1 -0
  1278. package/lib/typescript/components/styled/NewMessageLabel.d.ts +13 -0
  1279. package/lib/typescript/components/styled/NewMessageLabel.d.ts.map +1 -0
  1280. package/lib/typescript/components/styled/RoomListComponents/index.d.ts +35 -0
  1281. package/lib/typescript/components/styled/RoomListComponents/index.d.ts.map +1 -0
  1282. package/lib/typescript/components/styled/SendInput.d.ts +21 -0
  1283. package/lib/typescript/components/styled/SendInput.d.ts.map +1 -0
  1284. package/lib/typescript/components/styled/StyledComponents.d.ts +90 -0
  1285. package/lib/typescript/components/styled/StyledComponents.d.ts.map +1 -0
  1286. package/lib/typescript/components/styled/StyledInput.d.ts +11 -0
  1287. package/lib/typescript/components/styled/StyledInput.d.ts.map +1 -0
  1288. package/lib/typescript/components/styled/StyledInputComponents/AudioComponents.d.ts +2 -0
  1289. package/lib/typescript/components/styled/StyledInputComponents/AudioComponents.d.ts.map +1 -0
  1290. package/lib/typescript/components/styled/StyledInputComponents/Composing.d.ts +8 -0
  1291. package/lib/typescript/components/styled/StyledInputComponents/Composing.d.ts.map +1 -0
  1292. package/lib/typescript/components/styled/StyledInputComponents/CustomTypingIndicator.d.ts +19 -0
  1293. package/lib/typescript/components/styled/StyledInputComponents/CustomTypingIndicator.d.ts.map +1 -0
  1294. package/lib/typescript/components/styled/StyledInputComponents/MediaComponents.d.ts +12 -0
  1295. package/lib/typescript/components/styled/StyledInputComponents/MediaComponents.d.ts.map +1 -0
  1296. package/lib/typescript/components/styled/StyledInputComponents/StyledInputComponents.d.ts +28 -0
  1297. package/lib/typescript/components/styled/StyledInputComponents/StyledInputComponents.d.ts.map +1 -0
  1298. package/lib/typescript/components/styled/StyledInputComponents/VideoComponents.d.ts +7 -0
  1299. package/lib/typescript/components/styled/StyledInputComponents/VideoComponents.d.ts.map +1 -0
  1300. package/lib/typescript/components/styled/TreadLabel.d.ts +18 -0
  1301. package/lib/typescript/components/styled/TreadLabel.d.ts.map +1 -0
  1302. package/lib/typescript/components/styled/UnsupportedType.d.ts +10 -0
  1303. package/lib/typescript/components/styled/UnsupportedType.d.ts.map +1 -0
  1304. package/lib/typescript/components/styled/VideoMessage.d.ts +9 -0
  1305. package/lib/typescript/components/styled/VideoMessage.d.ts.map +1 -0
  1306. package/lib/typescript/context/MessageNotificationContext.d.ts +13 -0
  1307. package/lib/typescript/context/MessageNotificationContext.d.ts.map +1 -0
  1308. package/lib/typescript/context/PushNotificationProvider.d.ts +2 -0
  1309. package/lib/typescript/context/PushNotificationProvider.d.ts.map +1 -0
  1310. package/lib/typescript/context/ToastContext.d.ts +11 -0
  1311. package/lib/typescript/context/ToastContext.d.ts.map +1 -0
  1312. package/lib/typescript/context/toastProvider.d.ts +2 -0
  1313. package/lib/typescript/context/toastProvider.d.ts.map +1 -0
  1314. package/lib/typescript/context/xmppProvider.d.ts +23 -0
  1315. package/lib/typescript/context/xmppProvider.d.ts.map +1 -0
  1316. package/lib/typescript/helpers/block_scroll.d.ts +3 -0
  1317. package/lib/typescript/helpers/block_scroll.d.ts.map +1 -0
  1318. package/lib/typescript/helpers/chatAutoEnterer.d.ts +16 -0
  1319. package/lib/typescript/helpers/chatAutoEnterer.d.ts.map +1 -0
  1320. package/lib/typescript/helpers/checkUniqueUsers.d.ts +4 -0
  1321. package/lib/typescript/helpers/checkUniqueUsers.d.ts.map +1 -0
  1322. package/lib/typescript/helpers/constants/CHAT_TYPES.d.ts +3 -0
  1323. package/lib/typescript/helpers/constants/CHAT_TYPES.d.ts.map +1 -0
  1324. package/lib/typescript/helpers/constants/LANGUAGE_OPTIONS.d.ts +8 -0
  1325. package/lib/typescript/helpers/constants/LANGUAGE_OPTIONS.d.ts.map +1 -0
  1326. package/lib/typescript/helpers/constants/LOCAL_STORAGE.d.ts +4 -0
  1327. package/lib/typescript/helpers/constants/LOCAL_STORAGE.d.ts.map +1 -0
  1328. package/lib/typescript/helpers/constants/MESSAGE_INTERACTIONS.d.ts +43 -0
  1329. package/lib/typescript/helpers/constants/MESSAGE_INTERACTIONS.d.ts.map +1 -0
  1330. package/lib/typescript/helpers/constants/MODAL_COMPONENTS.d.ts +5 -0
  1331. package/lib/typescript/helpers/constants/MODAL_COMPONENTS.d.ts.map +1 -0
  1332. package/lib/typescript/helpers/constants/MODAL_TYPES.d.ts +14 -0
  1333. package/lib/typescript/helpers/constants/MODAL_TYPES.d.ts.map +1 -0
  1334. package/lib/typescript/helpers/constants/PLATFORM_CONSTANTS.d.ts +4 -0
  1335. package/lib/typescript/helpers/constants/PLATFORM_CONSTANTS.d.ts.map +1 -0
  1336. package/lib/typescript/helpers/createMainMessageForThread.d.ts +3 -0
  1337. package/lib/typescript/helpers/createMainMessageForThread.d.ts.map +1 -0
  1338. package/lib/typescript/helpers/createMessageFromXml.d.ts +22 -0
  1339. package/lib/typescript/helpers/createMessageFromXml.d.ts.map +1 -0
  1340. package/lib/typescript/helpers/createRoomFromApi.d.ts +3 -0
  1341. package/lib/typescript/helpers/createRoomFromApi.d.ts.map +1 -0
  1342. package/lib/typescript/helpers/createUserNameFromSetUser.d.ts +3 -0
  1343. package/lib/typescript/helpers/createUserNameFromSetUser.d.ts.map +1 -0
  1344. package/lib/typescript/helpers/dateComparison.d.ts +4 -0
  1345. package/lib/typescript/helpers/dateComparison.d.ts.map +1 -0
  1346. package/lib/typescript/helpers/debounce.d.ts +2 -0
  1347. package/lib/typescript/helpers/debounce.d.ts.map +1 -0
  1348. package/lib/typescript/helpers/ensureScopedChatCache.d.ts +9 -0
  1349. package/lib/typescript/helpers/ensureScopedChatCache.d.ts.map +1 -0
  1350. package/lib/typescript/helpers/extractUniqueMembersFromRooms.d.ts +10 -0
  1351. package/lib/typescript/helpers/extractUniqueMembersFromRooms.d.ts.map +1 -0
  1352. package/lib/typescript/helpers/formatNumberWithCommas.d.ts +2 -0
  1353. package/lib/typescript/helpers/formatNumberWithCommas.d.ts.map +1 -0
  1354. package/lib/typescript/helpers/getBooleanFromString.d.ts +2 -0
  1355. package/lib/typescript/helpers/getBooleanFromString.d.ts.map +1 -0
  1356. package/lib/typescript/helpers/getDataFromXml.d.ts +20 -0
  1357. package/lib/typescript/helpers/getDataFromXml.d.ts.map +1 -0
  1358. package/lib/typescript/helpers/getNumberFromString.d.ts +2 -0
  1359. package/lib/typescript/helpers/getNumberFromString.d.ts.map +1 -0
  1360. package/lib/typescript/helpers/getRoomsWithRetry.d.ts +3 -0
  1361. package/lib/typescript/helpers/getRoomsWithRetry.d.ts.map +1 -0
  1362. package/lib/typescript/helpers/getTintedColor.d.ts +2 -0
  1363. package/lib/typescript/helpers/getTintedColor.d.ts.map +1 -0
  1364. package/lib/typescript/helpers/getUnnamedUsers.d.ts +4 -0
  1365. package/lib/typescript/helpers/getUnnamedUsers.d.ts.map +1 -0
  1366. package/lib/typescript/helpers/handleCopyClick.d.ts +2 -0
  1367. package/lib/typescript/helpers/handleCopyClick.d.ts.map +1 -0
  1368. package/lib/typescript/helpers/handleXmppError.d.ts +5 -0
  1369. package/lib/typescript/helpers/handleXmppError.d.ts.map +1 -0
  1370. package/lib/typescript/helpers/hashcolor.d.ts +4 -0
  1371. package/lib/typescript/helpers/hashcolor.d.ts.map +1 -0
  1372. package/lib/typescript/helpers/historyPreloadScheduler.d.ts +21 -0
  1373. package/lib/typescript/helpers/historyPreloadScheduler.d.ts.map +1 -0
  1374. package/lib/typescript/helpers/initRoomsPresence.d.ts +6 -0
  1375. package/lib/typescript/helpers/initRoomsPresence.d.ts.map +1 -0
  1376. package/lib/typescript/helpers/initXmppRooms.d.ts +7 -0
  1377. package/lib/typescript/helpers/initXmppRooms.d.ts.map +1 -0
  1378. package/lib/typescript/helpers/insertMessageWithDelimiter.d.ts +5 -0
  1379. package/lib/typescript/helpers/insertMessageWithDelimiter.d.ts.map +1 -0
  1380. package/lib/typescript/helpers/isChatIdPresentInArray.d.ts +5 -0
  1381. package/lib/typescript/helpers/isChatIdPresentInArray.d.ts.map +1 -0
  1382. package/lib/typescript/helpers/localStorageUser.d.ts +3 -0
  1383. package/lib/typescript/helpers/localStorageUser.d.ts.map +1 -0
  1384. package/lib/typescript/helpers/markdownParser.d.ts +2 -0
  1385. package/lib/typescript/helpers/markdownParser.d.ts.map +1 -0
  1386. package/lib/typescript/helpers/nanoToMs.d.ts +2 -0
  1387. package/lib/typescript/helpers/nanoToMs.d.ts.map +1 -0
  1388. package/lib/typescript/helpers/parseMessageBody.d.ts +4 -0
  1389. package/lib/typescript/helpers/parseMessageBody.d.ts.map +1 -0
  1390. package/lib/typescript/helpers/parseUrls.d.ts +2 -0
  1391. package/lib/typescript/helpers/parseUrls.d.ts.map +1 -0
  1392. package/lib/typescript/helpers/resolveInitBeforeLoadUser.d.ts +9 -0
  1393. package/lib/typescript/helpers/resolveInitBeforeLoadUser.d.ts.map +1 -0
  1394. package/lib/typescript/helpers/storeConsole.d.ts +8 -0
  1395. package/lib/typescript/helpers/storeConsole.d.ts.map +1 -0
  1396. package/lib/typescript/helpers/transformTranslatations.d.ts +11 -0
  1397. package/lib/typescript/helpers/transformTranslatations.d.ts.map +1 -0
  1398. package/lib/typescript/helpers/updateMessagesTillLast.d.ts +6 -0
  1399. package/lib/typescript/helpers/updateMessagesTillLast.d.ts.map +1 -0
  1400. package/lib/typescript/helpers/updatedChatLastTimestamps.d.ts +2 -0
  1401. package/lib/typescript/helpers/updatedChatLastTimestamps.d.ts.map +1 -0
  1402. package/lib/typescript/helpers/validator.d.ts +3 -0
  1403. package/lib/typescript/helpers/validator.d.ts.map +1 -0
  1404. package/lib/typescript/helpers/walletUsername.d.ts +3 -0
  1405. package/lib/typescript/helpers/walletUsername.d.ts.map +1 -0
  1406. package/lib/typescript/hooks/hooks.d.ts +5 -0
  1407. package/lib/typescript/hooks/hooks.d.ts.map +1 -0
  1408. package/lib/typescript/hooks/useChatSettingState.d.ts +11 -0
  1409. package/lib/typescript/hooks/useChatSettingState.d.ts.map +1 -0
  1410. package/lib/typescript/hooks/useChatWrapperInit.d.ts +21 -0
  1411. package/lib/typescript/hooks/useChatWrapperInit.d.ts.map +1 -0
  1412. package/lib/typescript/hooks/useComposing.d.ts +7 -0
  1413. package/lib/typescript/hooks/useComposing.d.ts.map +1 -0
  1414. package/lib/typescript/hooks/useCustomTypingIndicator.d.ts +608 -0
  1415. package/lib/typescript/hooks/useCustomTypingIndicator.d.ts.map +1 -0
  1416. package/lib/typescript/hooks/useEventHandlers.d.ts +28 -0
  1417. package/lib/typescript/hooks/useEventHandlers.d.ts.map +1 -0
  1418. package/lib/typescript/hooks/useGetNewArchRoom.d.ts +4 -0
  1419. package/lib/typescript/hooks/useGetNewArchRoom.d.ts.map +1 -0
  1420. package/lib/typescript/hooks/useHeapSender.d.ts +5 -0
  1421. package/lib/typescript/hooks/useHeapSender.d.ts.map +1 -0
  1422. package/lib/typescript/hooks/useLocalStorage.d.ts +8 -0
  1423. package/lib/typescript/hooks/useLocalStorage.d.ts.map +1 -0
  1424. package/lib/typescript/hooks/useLogout.d.ts +27 -0
  1425. package/lib/typescript/hooks/useLogout.d.ts.map +1 -0
  1426. package/lib/typescript/hooks/useMessageHeapState.d.ts +5 -0
  1427. package/lib/typescript/hooks/useMessageHeapState.d.ts.map +1 -0
  1428. package/lib/typescript/hooks/useMessageLoaderQueue.d.ts +4 -0
  1429. package/lib/typescript/hooks/useMessageLoaderQueue.d.ts.map +1 -0
  1430. package/lib/typescript/hooks/useMessageQueue.d.ts +5 -0
  1431. package/lib/typescript/hooks/useMessageQueue.d.ts.map +1 -0
  1432. package/lib/typescript/hooks/usePendingNotification.d.ts +5 -0
  1433. package/lib/typescript/hooks/usePendingNotification.d.ts.map +1 -0
  1434. package/lib/typescript/hooks/usePrevious.d.ts +3 -0
  1435. package/lib/typescript/hooks/usePrevious.d.ts.map +1 -0
  1436. package/lib/typescript/hooks/usePushNotifications.d.ts +5 -0
  1437. package/lib/typescript/hooks/usePushNotifications.d.ts.map +1 -0
  1438. package/lib/typescript/hooks/useQRCodeChatHandler.d.ts +7 -0
  1439. package/lib/typescript/hooks/useQRCodeChatHandler.d.ts.map +1 -0
  1440. package/lib/typescript/hooks/useRoomInitialization.d.ts +3 -0
  1441. package/lib/typescript/hooks/useRoomInitialization.d.ts.map +1 -0
  1442. package/lib/typescript/hooks/useRoomState.d.ts +15 -0
  1443. package/lib/typescript/hooks/useRoomState.d.ts.map +1 -0
  1444. package/lib/typescript/hooks/useRoomUrl.d.ts +3 -0
  1445. package/lib/typescript/hooks/useRoomUrl.d.ts.map +1 -0
  1446. package/lib/typescript/hooks/useSendMessage.d.ts +8 -0
  1447. package/lib/typescript/hooks/useSendMessage.d.ts.map +1 -0
  1448. package/lib/typescript/hooks/useUnreadMessagesCounter.d.ts +11 -0
  1449. package/lib/typescript/hooks/useUnreadMessagesCounter.d.ts.map +1 -0
  1450. package/lib/typescript/hooks/useXmppInitialization.d.ts +20 -0
  1451. package/lib/typescript/hooks/useXmppInitialization.d.ts.map +1 -0
  1452. package/lib/typescript/main.d.ts +30 -0
  1453. package/lib/typescript/main.d.ts.map +1 -0
  1454. package/lib/typescript/networking/api-requests/auth.api.d.ts +12 -0
  1455. package/lib/typescript/networking/api-requests/auth.api.d.ts.map +1 -0
  1456. package/lib/typescript/networking/api-requests/push.api.d.ts +8 -0
  1457. package/lib/typescript/networking/api-requests/push.api.d.ts.map +1 -0
  1458. package/lib/typescript/networking/api-requests/roomMembers.api.d.ts +3 -0
  1459. package/lib/typescript/networking/api-requests/roomMembers.api.d.ts.map +1 -0
  1460. package/lib/typescript/networking/api-requests/rooms.api.d.ts +19 -0
  1461. package/lib/typescript/networking/api-requests/rooms.api.d.ts.map +1 -0
  1462. package/lib/typescript/networking/api-requests/user.api.d.ts +16 -0
  1463. package/lib/typescript/networking/api-requests/user.api.d.ts.map +1 -0
  1464. package/lib/typescript/networking/apiClient.d.ts +12 -0
  1465. package/lib/typescript/networking/apiClient.d.ts.map +1 -0
  1466. package/lib/typescript/networking/helpers/refreshChecker.d.ts +2 -0
  1467. package/lib/typescript/networking/helpers/refreshChecker.d.ts.map +1 -0
  1468. package/lib/typescript/networking/stanzaHandlers.d.ts +19 -0
  1469. package/lib/typescript/networking/stanzaHandlers.d.ts.map +1 -0
  1470. package/lib/typescript/networking/xmpp/actionSetTimestampToPrivateStore.xmpp.d.ts +2 -0
  1471. package/lib/typescript/networking/xmpp/actionSetTimestampToPrivateStore.xmpp.d.ts.map +1 -0
  1472. package/lib/typescript/networking/xmpp/allRoomPresences.xmpp.d.ts +3 -0
  1473. package/lib/typescript/networking/xmpp/allRoomPresences.xmpp.d.ts.map +1 -0
  1474. package/lib/typescript/networking/xmpp/createPrivateRoom.xmpp.d.ts +3 -0
  1475. package/lib/typescript/networking/xmpp/createPrivateRoom.xmpp.d.ts.map +1 -0
  1476. package/lib/typescript/networking/xmpp/createRoom.xmpp.d.ts +3 -0
  1477. package/lib/typescript/networking/xmpp/createRoom.xmpp.d.ts.map +1 -0
  1478. package/lib/typescript/networking/xmpp/createRoomPresence.xmpp.d.ts +3 -0
  1479. package/lib/typescript/networking/xmpp/createRoomPresence.xmpp.d.ts.map +1 -0
  1480. package/lib/typescript/networking/xmpp/createTimeoutPromise.xmpp.d.ts +2 -0
  1481. package/lib/typescript/networking/xmpp/createTimeoutPromise.xmpp.d.ts.map +1 -0
  1482. package/lib/typescript/networking/xmpp/deleteMessage.xmpp.d.ts +3 -0
  1483. package/lib/typescript/networking/xmpp/deleteMessage.xmpp.d.ts.map +1 -0
  1484. package/lib/typescript/networking/xmpp/editMessage.xmpp.d.ts +3 -0
  1485. package/lib/typescript/networking/xmpp/editMessage.xmpp.d.ts.map +1 -0
  1486. package/lib/typescript/networking/xmpp/flushLastViewedToPrivateStore.d.ts +22 -0
  1487. package/lib/typescript/networking/xmpp/flushLastViewedToPrivateStore.d.ts.map +1 -0
  1488. package/lib/typescript/networking/xmpp/getChatsPrivateStoreRequest.xmpp.d.ts +3 -0
  1489. package/lib/typescript/networking/xmpp/getChatsPrivateStoreRequest.xmpp.d.ts.map +1 -0
  1490. package/lib/typescript/networking/xmpp/getHistory.xmpp.d.ts +4 -0
  1491. package/lib/typescript/networking/xmpp/getHistory.xmpp.d.ts.map +1 -0
  1492. package/lib/typescript/networking/xmpp/getLastMessageArchive.xmpp.d.ts +3 -0
  1493. package/lib/typescript/networking/xmpp/getLastMessageArchive.xmpp.d.ts.map +1 -0
  1494. package/lib/typescript/networking/xmpp/getRoomInfo.xmpp.d.ts +3 -0
  1495. package/lib/typescript/networking/xmpp/getRoomInfo.xmpp.d.ts.map +1 -0
  1496. package/lib/typescript/networking/xmpp/getRoomMembers.xmpp.d.ts +2 -0
  1497. package/lib/typescript/networking/xmpp/getRoomMembers.xmpp.d.ts.map +1 -0
  1498. package/lib/typescript/networking/xmpp/getRooms.xmpp.d.ts +3 -0
  1499. package/lib/typescript/networking/xmpp/getRooms.xmpp.d.ts.map +1 -0
  1500. package/lib/typescript/networking/xmpp/getRoomsPaged.xmpp.d.ts +3 -0
  1501. package/lib/typescript/networking/xmpp/getRoomsPaged.xmpp.d.ts.map +1 -0
  1502. package/lib/typescript/networking/xmpp/handlePong.xmpp.d.ts +2 -0
  1503. package/lib/typescript/networking/xmpp/handlePong.xmpp.d.ts.map +1 -0
  1504. package/lib/typescript/networking/xmpp/handleStanzas.xmpp.d.ts +4 -0
  1505. package/lib/typescript/networking/xmpp/handleStanzas.xmpp.d.ts.map +1 -0
  1506. package/lib/typescript/networking/xmpp/inviteRoomRequest.xmpp.d.ts +3 -0
  1507. package/lib/typescript/networking/xmpp/inviteRoomRequest.xmpp.d.ts.map +1 -0
  1508. package/lib/typescript/networking/xmpp/leaveTheRoom.xmpp.d.ts +3 -0
  1509. package/lib/typescript/networking/xmpp/leaveTheRoom.xmpp.d.ts.map +1 -0
  1510. package/lib/typescript/networking/xmpp/listenerManager.d.ts +18 -0
  1511. package/lib/typescript/networking/xmpp/listenerManager.d.ts.map +1 -0
  1512. package/lib/typescript/networking/xmpp/presenceInRoom.xmpp.d.ts +4 -0
  1513. package/lib/typescript/networking/xmpp/presenceInRoom.xmpp.d.ts.map +1 -0
  1514. package/lib/typescript/networking/xmpp/roomConfig.xmpp.d.ts +3 -0
  1515. package/lib/typescript/networking/xmpp/roomConfig.xmpp.d.ts.map +1 -0
  1516. package/lib/typescript/networking/xmpp/sendMediaMessage.xmpp.d.ts +3 -0
  1517. package/lib/typescript/networking/xmpp/sendMediaMessage.xmpp.d.ts.map +1 -0
  1518. package/lib/typescript/networking/xmpp/sendMessageReaction.xmpp.d.ts +3 -0
  1519. package/lib/typescript/networking/xmpp/sendMessageReaction.xmpp.d.ts.map +1 -0
  1520. package/lib/typescript/networking/xmpp/sendPing.xmpp.d.ts +2 -0
  1521. package/lib/typescript/networking/xmpp/sendPing.xmpp.d.ts.map +1 -0
  1522. package/lib/typescript/networking/xmpp/sendTextMessage.xmpp.d.ts +3 -0
  1523. package/lib/typescript/networking/xmpp/sendTextMessage.xmpp.d.ts.map +1 -0
  1524. package/lib/typescript/networking/xmpp/sendTextMessageWithTranslateTag.xmpp.d.ts +16 -0
  1525. package/lib/typescript/networking/xmpp/sendTextMessageWithTranslateTag.xmpp.d.ts.map +1 -0
  1526. package/lib/typescript/networking/xmpp/sendTypingRequest.xmpp.d.ts +3 -0
  1527. package/lib/typescript/networking/xmpp/sendTypingRequest.xmpp.d.ts.map +1 -0
  1528. package/lib/typescript/networking/xmpp/setChatsPrivateStoreRequest.xmpp.d.ts +3 -0
  1529. package/lib/typescript/networking/xmpp/setChatsPrivateStoreRequest.xmpp.d.ts.map +1 -0
  1530. package/lib/typescript/networking/xmpp/setMeAsOwner.xmpp.d.ts +3 -0
  1531. package/lib/typescript/networking/xmpp/setMeAsOwner.xmpp.d.ts.map +1 -0
  1532. package/lib/typescript/networking/xmpp/setRoomImage.xmpp.d.ts +3 -0
  1533. package/lib/typescript/networking/xmpp/setRoomImage.xmpp.d.ts.map +1 -0
  1534. package/lib/typescript/networking/xmpp/setVCard.xmpp.d.ts +2 -0
  1535. package/lib/typescript/networking/xmpp/setVCard.xmpp.d.ts.map +1 -0
  1536. package/lib/typescript/networking/xmpp/subscribeToRoomMessages.xmpp.d.ts +3 -0
  1537. package/lib/typescript/networking/xmpp/subscribeToRoomMessages.xmpp.d.ts.map +1 -0
  1538. package/lib/typescript/networking/xmppClient.d.ts +104 -0
  1539. package/lib/typescript/networking/xmppClient.d.ts.map +1 -0
  1540. package/lib/typescript/roomStore/Middleware/logoutMiddleware.d.ts +3 -0
  1541. package/lib/typescript/roomStore/Middleware/logoutMiddleware.d.ts.map +1 -0
  1542. package/lib/typescript/roomStore/Middleware/newMessageMidlleware.d.ts +3 -0
  1543. package/lib/typescript/roomStore/Middleware/newMessageMidlleware.d.ts.map +1 -0
  1544. package/lib/typescript/roomStore/Middleware/reactionsMiddleware.d.ts +3 -0
  1545. package/lib/typescript/roomStore/Middleware/reactionsMiddleware.d.ts.map +1 -0
  1546. package/lib/typescript/roomStore/Middleware/testMiddleware.d.ts +3 -0
  1547. package/lib/typescript/roomStore/Middleware/testMiddleware.d.ts.map +1 -0
  1548. package/lib/typescript/roomStore/Middleware/unreadMidlleware.d.ts +3 -0
  1549. package/lib/typescript/roomStore/Middleware/unreadMidlleware.d.ts.map +1 -0
  1550. package/lib/typescript/roomStore/chatSettingsSlice.d.ts +43 -0
  1551. package/lib/typescript/roomStore/chatSettingsSlice.d.ts.map +1 -0
  1552. package/lib/typescript/roomStore/index.d.ts +27 -0
  1553. package/lib/typescript/roomStore/index.d.ts.map +1 -0
  1554. package/lib/typescript/roomStore/persistence.d.ts +30 -0
  1555. package/lib/typescript/roomStore/persistence.d.ts.map +1 -0
  1556. package/lib/typescript/roomStore/roomHeapSlice.d.ts +16 -0
  1557. package/lib/typescript/roomStore/roomHeapSlice.d.ts.map +1 -0
  1558. package/lib/typescript/roomStore/roomsSlice.d.ts +182 -0
  1559. package/lib/typescript/roomStore/roomsSlice.d.ts.map +1 -0
  1560. package/lib/typescript/services/pushNotifications.d.ts +10 -0
  1561. package/lib/typescript/services/pushNotifications.d.ts.map +1 -0
  1562. package/lib/typescript/services/pushSubscriptionService.d.ts +18 -0
  1563. package/lib/typescript/services/pushSubscriptionService.d.ts.map +1 -0
  1564. package/lib/typescript/types/messages.d.ts +53 -0
  1565. package/lib/typescript/types/messages.d.ts.map +1 -0
  1566. package/lib/typescript/types/models/action.model.d.ts +26 -0
  1567. package/lib/typescript/types/models/action.model.d.ts.map +1 -0
  1568. package/lib/typescript/types/models/config.model.d.ts +2 -0
  1569. package/lib/typescript/types/models/config.model.d.ts.map +1 -0
  1570. package/lib/typescript/types/models/customComponents.model.d.ts +42 -0
  1571. package/lib/typescript/types/models/customComponents.model.d.ts.map +1 -0
  1572. package/lib/typescript/types/models/language.model.d.ts +10 -0
  1573. package/lib/typescript/types/models/language.model.d.ts.map +1 -0
  1574. package/lib/typescript/types/models/media.model.d.ts +6 -0
  1575. package/lib/typescript/types/models/media.model.d.ts.map +1 -0
  1576. package/lib/typescript/types/models/message.model.d.ts +65 -0
  1577. package/lib/typescript/types/models/message.model.d.ts.map +1 -0
  1578. package/lib/typescript/types/models/modal.model.d.ts +8 -0
  1579. package/lib/typescript/types/models/modal.model.d.ts.map +1 -0
  1580. package/lib/typescript/types/models/room.model.d.ts +108 -0
  1581. package/lib/typescript/types/models/room.model.d.ts.map +1 -0
  1582. package/lib/typescript/types/models/user.model.d.ts +77 -0
  1583. package/lib/typescript/types/models/user.model.d.ts.map +1 -0
  1584. package/lib/typescript/types/models/xmpp.model.d.ts +77 -0
  1585. package/lib/typescript/types/models/xmpp.model.d.ts.map +1 -0
  1586. package/lib/typescript/types/types.d.ts +416 -0
  1587. package/lib/typescript/types/types.d.ts.map +1 -0
  1588. package/lib/typescript/utils/PriorityQueue.d.ts +15 -0
  1589. package/lib/typescript/utils/PriorityQueue.d.ts.map +1 -0
  1590. package/lib/typescript/utils/actionHelpers.d.ts +5 -0
  1591. package/lib/typescript/utils/actionHelpers.d.ts.map +1 -0
  1592. package/lib/typescript/utils/actionLogger.d.ts +18 -0
  1593. package/lib/typescript/utils/actionLogger.d.ts.map +1 -0
  1594. package/lib/typescript/utils/clientRegistry.d.ts +22 -0
  1595. package/lib/typescript/utils/clientRegistry.d.ts.map +1 -0
  1596. package/lib/typescript/utils/devLogger.d.ts +26 -0
  1597. package/lib/typescript/utils/devLogger.d.ts.map +1 -0
  1598. package/lib/typescript/utils/messageNotificationManager.d.ts +21 -0
  1599. package/lib/typescript/utils/messageNotificationManager.d.ts.map +1 -0
  1600. package/lib/typescript/utils/resendMessage.d.ts +11 -0
  1601. package/lib/typescript/utils/resendMessage.d.ts.map +1 -0
  1602. package/lib/typescript/utils/toastEmitter.d.ts +12 -0
  1603. package/lib/typescript/utils/toastEmitter.d.ts.map +1 -0
  1604. package/lib/typescript/utils/xmppMemoryMonitor.d.ts +17 -0
  1605. package/lib/typescript/utils/xmppMemoryMonitor.d.ts.map +1 -0
  1606. package/lib/typescript/version.d.ts +2 -0
  1607. package/lib/typescript/version.d.ts.map +1 -0
  1608. package/metro.js +0 -5
  1609. package/package.json +29 -6
  1610. package/src/components/InputComponents/AudioRecorder.tsx +1 -1
  1611. package/src/components/InputComponents/MediaInput.tsx +22 -23
  1612. package/src/components/MainComponents/ChatHeader.tsx +1 -1
  1613. package/src/components/MainComponents/ChatRoom.tsx +2 -7
  1614. package/src/components/MainComponents/ChatWrapper.tsx +18 -12
  1615. package/src/components/MainComponents/LoginWrapper.tsx +5 -2
  1616. package/src/components/MainComponents/MediaMessage.tsx +14 -4
  1617. package/src/components/MainComponents/MessageList.tsx +1 -2
  1618. package/src/components/MainComponents/ProfileImagePlaceholder.tsx +1 -1
  1619. package/src/components/MainComponents/ReduxWrapper.tsx +14 -12
  1620. package/src/components/MessageBubble/Message.tsx +7 -7
  1621. package/src/components/MessageBubble/MessageReaction.tsx +1 -1
  1622. package/src/components/MessageBubble/MessageTranslations.tsx +3 -3
  1623. package/src/components/Modals/AddMembersModal/AddMembersModal.tsx +2 -2
  1624. package/src/components/Modals/ChatProfileModal/ChatProfileModal.tsx +5 -3
  1625. package/src/components/Modals/FilePreviewModal/FilePreviewModal.tsx +32 -118
  1626. package/src/components/Modals/ModalSelectMedia/ModalSelectMedia.tsx +1 -1
  1627. package/src/components/Modals/NewChatModal/ModalContent.tsx +7 -7
  1628. package/src/components/Modals/NewChatModal/NewChatModal.tsx +25 -53
  1629. package/src/components/Modals/NewChatModal/UpdNewChatModal.tsx +5 -5
  1630. package/src/components/Modals/SettingsModals/Referrals/Referrals.tsx +2 -2
  1631. package/src/components/Modals/UserProfileModal/UserProfileModal.tsx +12 -11
  1632. package/src/components/Modals/UserSettingsModal/UserSettingsModal.tsx +1 -1
  1633. package/src/components/Thread/ThreadWrapper.tsx +10 -5
  1634. package/src/components/UsersList/UsersList.tsx +2 -2
  1635. package/src/components/styled/ActionButton.tsx +5 -4
  1636. package/src/components/styled/AudioMessage.tsx +108 -53
  1637. package/src/components/styled/Button.tsx +1 -1
  1638. package/src/components/styled/MediaModal.tsx +3 -2
  1639. package/src/components/styled/SendInput.tsx +14 -4
  1640. package/src/components/styled/StyledComponents.ts +5 -0
  1641. package/src/components/styled/StyledInputComponents/VideoComponents.tsx +2 -4
  1642. package/src/components/styled/VideoMessage.tsx +8 -19
  1643. package/src/helpers/chatAutoEnterer.ts +1 -1
  1644. package/src/helpers/createRoomFromApi.tsx +1 -0
  1645. package/src/helpers/getDataFromXml.ts +2 -2
  1646. package/src/helpers/getUnnamedUsers.ts +2 -2
  1647. package/src/helpers/initXmppRooms.tsx +3 -3
  1648. package/src/helpers/insertMessageWithDelimiter.ts +5 -5
  1649. package/src/helpers/localStorageUser.ts +1 -1
  1650. package/src/helpers/nanoToMs.ts +1 -1
  1651. package/src/hooks/useChatWrapperInit.ts +4 -5
  1652. package/src/hooks/useGetNewArchRoom.tsx +0 -2
  1653. package/src/hooks/usePrevious.tsx +1 -1
  1654. package/src/hooks/usePushNotifications.ts +1 -1
  1655. package/src/hooks/useRoomInitialization.tsx +2 -2
  1656. package/src/networking/api-requests/auth.api.ts +5 -5
  1657. package/src/networking/api-requests/rooms.api.ts +131 -15
  1658. package/src/networking/api-requests/user.api.ts +9 -0
  1659. package/src/networking/apiClient.ts +11 -7
  1660. package/src/networking/stanzaHandlers.ts +54 -30
  1661. package/src/networking/xmpp/actionSetTimestampToPrivateStore.xmpp.ts +1 -1
  1662. package/src/networking/xmpp/getChatsPrivateStoreRequest.xmpp.ts +1 -1
  1663. package/src/networking/xmpp/getHistory.xmpp.ts +3 -3
  1664. package/src/networking/xmpp/getRooms.xmpp.ts +1 -1
  1665. package/src/networking/xmpp/handleStanzas.xmpp.ts +1 -1
  1666. package/src/networking/xmppClient.ts +5 -3
  1667. package/src/roomStore/Middleware/newMessageMidlleware.tsx +1 -1
  1668. package/src/roomStore/Middleware/reactionsMiddleware.tsx +5 -5
  1669. package/src/roomStore/chatSettingsSlice.ts +72 -65
  1670. package/src/roomStore/roomHeapSlice.ts +24 -17
  1671. package/src/roomStore/roomsSlice.ts +106 -31
  1672. package/src/services/pushNotifications.ts +1 -1
  1673. package/src/services/pushSubscriptionService.ts +25 -2
  1674. package/src/types/models/message.model.ts +1 -1
  1675. package/src/types/models/modal.model.ts +1 -1
  1676. package/src/types/models/room.model.ts +3 -0
  1677. package/src/types/types.ts +19 -37
  1678. package/src/utils/resendMessage.ts +3 -4
  1679. package/index.js +0 -20
  1680. package/src/api.config.ts +0 -34
@@ -0,0 +1,205 @@
1
+ "use strict";
2
+
3
+ /** @format */
4
+
5
+ import { useEffect, useRef, useState } from 'react';
6
+ import { useDispatch, useSelector } from 'react-redux';
7
+ import { useXmppClient } from '../context/xmppProvider';
8
+ import { chatAutoEnterer } from '../helpers/chatAutoEnterer';
9
+ import { initRoomsPresence } from '../helpers/initRoomsPresence';
10
+ import { updatedChatLastTimestamps } from '../helpers/updatedChatLastTimestamps';
11
+ import { updateMessagesTillLast } from '../helpers/updateMessagesTillLast';
12
+ import { refresh } from '../networking/apiClient';
13
+ import { setLangSource, setConfig } from '../roomStore/chatSettingsSlice';
14
+ import { setIsLoading } from '../roomStore/roomsSlice';
15
+ import { useRoomState } from './useRoomState';
16
+ import { useChatSettingState } from './useChatSettingState';
17
+ import { isChatIdPresentInArray } from '../helpers/isChatIdPresentInArray';
18
+ import useGetNewArchRoom from './useGetNewArchRoom';
19
+ import { getRoomsWithRetry } from '../helpers/getRoomsWithRetry';
20
+ const useChatWrapperInit = ({
21
+ roomJID,
22
+ wasAutoSelected,
23
+ config
24
+ }) => {
25
+ const dispatch = useDispatch();
26
+ const [inited, setInited] = useState(false);
27
+ const [showModal, setShowModal] = useState(false);
28
+ const [isConnectionLost, setConnectionLost] = useState(false);
29
+ const [isRetrying, setIsRetrying] = useState(false);
30
+ const hasSyncedHistoryRef = useRef(false);
31
+ const {
32
+ client,
33
+ initializeClient,
34
+ setClient
35
+ } = useXmppClient();
36
+ const syncRooms = useGetNewArchRoom();
37
+ const {
38
+ rooms
39
+ } = useSelector(state => state.rooms);
40
+ const {
41
+ roomsList
42
+ } = useRoomState();
43
+ const {
44
+ user
45
+ } = useChatSettingState();
46
+ useEffect(() => {
47
+ return () => {
48
+ if (client && user.xmppPassword === '') {
49
+ console.log('closing client');
50
+ client.close();
51
+ setClient(null);
52
+ }
53
+ };
54
+ }, [user.xmppPassword]);
55
+ const getRoomsWithRertyRequest = async () => {
56
+ setIsRetrying(true);
57
+ const retryRooms = await getRoomsWithRetry(client, config, syncRooms, roomJID);
58
+ if (!retryRooms) {
59
+ setIsRetrying('norooms');
60
+ return;
61
+ }
62
+ setIsRetrying(false);
63
+ };
64
+ const loadRooms = async (client, disableLoad = false) => {
65
+ !disableLoad && dispatch(setIsLoading({
66
+ loading: true,
67
+ loadingText: 'Loading rooms...'
68
+ }));
69
+ const rooms = await syncRooms(client, config);
70
+ dispatch(setIsLoading({
71
+ loading: false,
72
+ loadingText: undefined
73
+ }));
74
+ return rooms;
75
+ };
76
+ useEffect(() => {
77
+ let retryTimeout;
78
+ const initXmmpClient = async () => {
79
+ if (config?.translates?.enabled && !config?.translates?.translations) {
80
+ dispatch(setLangSource(config?.translates?.translations));
81
+ }
82
+ dispatch(setConfig(config));
83
+ try {
84
+ if (!user.xmppUsername) {
85
+ setShowModal(true);
86
+ console.error('Error, no user');
87
+ } else {
88
+ chatAutoEnterer({
89
+ roomJID,
90
+ wasAutoSelected,
91
+ config,
92
+ dispatch
93
+ });
94
+ if (!client) {
95
+ try {
96
+ setInited(false);
97
+ setShowModal(false);
98
+ console.log(' No client, initializing one');
99
+ const newClient = await initializeClient(user.xmppUsername || user?.defaultWallet?.walletAddress, user?.xmppPassword, config?.xmppSettings).then(client => {
100
+ console.log(' Client initialized', client?.status);
101
+ return client;
102
+ });
103
+ if (roomsList && Object.keys(roomsList).length > 0) {
104
+ console.log(' Using existing roomsList', Object.keys(roomsList).length);
105
+ setInited(true);
106
+ await initRoomsPresence(newClient, roomsList);
107
+ } else {
108
+ if (config?.newArch) {
109
+ console.log(' Loading rooms with newArch');
110
+ const loadedRooms = await loadRooms(newClient);
111
+ console.log(' Loaded rooms', loadedRooms?.length || 0);
112
+ if (config?.enableRoomsRetry?.enabled) {
113
+ const isSelectedRoomPresent = isChatIdPresentInArray(roomJID, loadedRooms);
114
+ console.log(' Selected room present?', isSelectedRoomPresent, roomJID);
115
+ if (!isSelectedRoomPresent) {
116
+ await getRoomsWithRertyRequest();
117
+ }
118
+ }
119
+ setInited(true);
120
+ } else {
121
+ console.log(' Using old arch, getting rooms stanza');
122
+ await newClient.getRoomsStanza();
123
+ }
124
+ }
125
+ await newClient.getChatsPrivateStoreRequestStanza().then(async roomTimestampObject => {
126
+ console.log('Got chats private store', roomTimestampObject?.length || 0);
127
+ updatedChatLastTimestamps(roomTimestampObject, dispatch);
128
+ if (!hasSyncedHistoryRef.current) {
129
+ console.log('Updating messages till last');
130
+ await updateMessagesTillLast(rooms, newClient);
131
+ hasSyncedHistoryRef.current = true;
132
+ }
133
+ setClient(newClient);
134
+ setConnectionLost(false);
135
+ console.log('Initialization complete');
136
+ });
137
+ {
138
+ config?.refreshTokens?.enabled && refresh();
139
+ }
140
+ } catch (error) {
141
+ console.error(' Error during initialization', error);
142
+ setConnectionLost(true);
143
+ retryTimeout = setTimeout(initXmmpClient, 5000);
144
+ }
145
+ } else {
146
+ if (config?.newArch) {
147
+ if (config?.enableRoomsRetry?.enabled) {
148
+ const isSelectedRoomPresent = isChatIdPresentInArray(roomJID, roomsList);
149
+ console.log('Selected room present in existing client?', isSelectedRoomPresent);
150
+ if (!isSelectedRoomPresent) {
151
+ await getRoomsWithRertyRequest();
152
+ }
153
+ }
154
+ }
155
+ setInited(true);
156
+ console.log(' Getting chats private store for existing client');
157
+ await client.getChatsPrivateStoreRequestStanza().then(async roomTimestampObject => {
158
+ console.log('Got chats private store for existing client', roomTimestampObject?.length || 0);
159
+ updatedChatLastTimestamps(roomTimestampObject, dispatch);
160
+ if (!hasSyncedHistoryRef.current) {
161
+ console.log('Updating messages till last for existing client');
162
+ await updateMessagesTillLast(rooms, client);
163
+ hasSyncedHistoryRef.current = true;
164
+ }
165
+ setClient(client);
166
+ setConnectionLost(false);
167
+ console.log(' Initialization complete for existing client');
168
+ });
169
+ {
170
+ config?.refreshTokens?.enabled && refresh();
171
+ }
172
+ }
173
+ }
174
+ dispatch(setIsLoading({
175
+ loading: false
176
+ }));
177
+ } catch (error) {
178
+ console.error(' Fatal error', error);
179
+ setShowModal(false);
180
+ setConnectionLost(true);
181
+ setInited(false);
182
+ dispatch(setIsLoading({
183
+ loading: false
184
+ }));
185
+ retryTimeout = setTimeout(initXmmpClient, 5000);
186
+ }
187
+ };
188
+ initXmmpClient();
189
+ return () => {
190
+ clearTimeout(retryTimeout);
191
+ };
192
+ }, [user.xmppPassword, user.xmppUsername]);
193
+ return {
194
+ client,
195
+ inited,
196
+ isRetrying,
197
+ showModal,
198
+ isConnectionLost,
199
+ setClient: setClient,
200
+ setInited,
201
+ setShowModal
202
+ };
203
+ };
204
+ export default useChatWrapperInit;
205
+ //# sourceMappingURL=useChatWrapperInit.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["useEffect","useRef","useState","useDispatch","useSelector","useXmppClient","chatAutoEnterer","initRoomsPresence","updatedChatLastTimestamps","updateMessagesTillLast","refresh","setLangSource","setConfig","setIsLoading","useRoomState","useChatSettingState","isChatIdPresentInArray","useGetNewArchRoom","getRoomsWithRetry","useChatWrapperInit","roomJID","wasAutoSelected","config","dispatch","inited","setInited","showModal","setShowModal","isConnectionLost","setConnectionLost","isRetrying","setIsRetrying","hasSyncedHistoryRef","client","initializeClient","setClient","syncRooms","rooms","state","roomsList","user","xmppPassword","console","log","close","getRoomsWithRertyRequest","retryRooms","loadRooms","disableLoad","loading","loadingText","undefined","retryTimeout","initXmmpClient","translates","enabled","translations","xmppUsername","error","newClient","defaultWallet","walletAddress","xmppSettings","then","status","Object","keys","length","newArch","loadedRooms","enableRoomsRetry","isSelectedRoomPresent","getRoomsStanza","getChatsPrivateStoreRequestStanza","roomTimestampObject","current","refreshTokens","setTimeout","clearTimeout"],"sourceRoot":"../../../src","sources":["hooks/useChatWrapperInit.ts"],"mappings":";;AAAA;;AAEA,SAASA,SAAS,EAAEC,MAAM,EAAEC,QAAQ,QAAQ,OAAO;AACnD,SAASC,WAAW,EAAEC,WAAW,QAAQ,aAAa;AAItD,SAASC,aAAa,QAAQ,yBAAyB;AACvD,SAASC,eAAe,QAAQ,4BAA4B;AAC5D,SAASC,iBAAiB,QAAQ,8BAA8B;AAChE,SAASC,yBAAyB,QAAQ,sCAAsC;AAChF,SAASC,sBAAsB,QAAQ,mCAAmC;AAC1E,SAASC,OAAO,QAAQ,yBAAyB;AACjD,SAASC,aAAa,EAAEC,SAAS,QAAQ,gCAAgC;AACzE,SAASC,YAAY,QAAQ,yBAAyB;AACtD,SAASC,YAAY,QAAQ,gBAAgB;AAC7C,SAASC,mBAAmB,QAAQ,uBAAuB;AAC3D,SAASC,sBAAsB,QAAQ,mCAAmC;AAC1E,OAAOC,iBAAiB,MAAM,qBAAqB;AACnD,SAASC,iBAAiB,QAAQ,8BAA8B;AAmBhE,MAAMC,kBAAkB,GAAGA,CAAC;EAC1BC,OAAO;EACPC,eAAe;EACfC;AACuB,CAAC,KAA+B;EACvD,MAAMC,QAAQ,GAAGpB,WAAW,CAAc,CAAC;EAC3C,MAAM,CAACqB,M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EAAE,CAACZ,IAAI,CAACC,YAAY,EAAED,IAAI,CAACiB,YAAY,CAAC,CAAC;EAE1C,OAAO;IACLxB,MAAM;IACNT,MAAM;IACNM,UAAU;IACVJ,SAAS;IACTE,gBAAgB;IAChBO,SAAS,EAAEA,SAAgB;IAC3BV,SAAS;IACTE;EACF,CAAC;AACH,CAAC;AAED,eAAeR,kBAAkB","ignoreList":[]}
@@ -0,0 +1,45 @@
1
+ "use strict";
2
+
3
+ import { useCallback, useEffect } from 'react';
4
+ import { useXmppClient } from '../context/xmppProvider';
5
+ import { useSelector } from 'react-redux';
6
+ import { useChatSettingState } from './useChatSettingState';
7
+ const useComposing = config => {
8
+ const {
9
+ client
10
+ } = useXmppClient();
11
+ const {
12
+ activeRoomJID
13
+ } = useSelector(state => state.rooms);
14
+ const {
15
+ user
16
+ } = useChatSettingState();
17
+ const sendStartComposing = useCallback(() => {
18
+ if (config?.disableTypingIndicator) {
19
+ return;
20
+ }
21
+ if (client) {
22
+ client.sendTypingRequestStanza(activeRoomJID || '', `${user.firstName} ${user.lastName}`, true);
23
+ }
24
+ }, [activeRoomJID, client, config?.disableTypingIndicator, user.firstName, user.lastName]);
25
+ const sendEndComposing = useCallback(() => {
26
+ if (config?.disableTypingIndicator) {
27
+ return;
28
+ }
29
+ if (client) {
30
+ client.sendTypingRequestStanza(activeRoomJID || '', `${user.firstName} ${user.lastName}`, false);
31
+ }
32
+ }, [activeRoomJID, client, config?.disableTypingIndicator, user.firstName, user.lastName]);
33
+ useEffect(() => {
34
+ const timerId = setTimeout(() => {
35
+ sendEndComposing();
36
+ }, 100);
37
+ return () => clearTimeout(timerId);
38
+ }, [sendEndComposing]);
39
+ return {
40
+ sendStartComposing,
41
+ sendEndComposing
42
+ };
43
+ };
44
+ export default useComposing;
45
+ //# sourceMappingURL=useComposing.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["useCallback","useEffect","useXmppClient","useSelector","useChatSettingState","useComposing","config","client","activeRoomJID","state","rooms","user","sendStartComposing","disableTypingIndicator","sendTypingRequestStanza","firstName","lastName","sendEndComposing","timerId","setTimeout","clearTimeout"],"sourceRoot":"../../../src","sources":["hooks/useComposing.tsx"],"mappings":";;AAAA,SAASA,WAAW,EAAEC,SAAS,QAAkB,OAAO;AACxD,SAASC,aAAa,QAAQ,yBAAyB;AACvD,SAASC,WAAW,QAAQ,aAAa;AAEzC,SAASC,mBAAmB,QAAQ,uBAAuB;AAG3D,MAAMC,YAAY,GAAIC,MAAgB,IAAK;EACzC,MAAM;IAAEC;EAAO,CAAC,GAAGL,aAAa,CAAC,CAAC;EAClC,MAAM;IAAEM;EAAc,CAAC,GAAGL,WAAW,CAAEM,KAAgB,IAAKA,KAAK,CAACC,KAAK,CAAC;EACxE,MAAM;IAAEC;EAAK,CAAC,GAAGP,mBAAmB,CAAC,CAAC;EAEtC,MAAMQ,kBAAkB,GAAGZ,WAAW,CAAC,MAAM;IAC3C,IAAIM,MAAM,EAAEO,sBAAsB,EAAE;MAClC;IACF;IACA,IAAIN,MAAM,EAAE;MACVA,MAAM,CAACO,uBAAuB,CAC5BN,aAAa,IAAI,EAAE,EACnB,GAAGG,IAAI,CAACI,SAAS,IAAIJ,IAAI,CAACK,QAAQ,EAAE,EACpC,IACF,CAAC;IACH;EACF,CAAC,EAAE,CAACR,aAAa,EAAED,MAAM,EAAED,MAAM,EAAEO,sBAAsB,EAAEF,IAAI,CAACI,SAAS,EAAEJ,IAAI,CAACK,QAAQ,CAAC,CAAC;EAE1F,MAAMC,gBAAgB,GAAGjB,WAAW,CAAC,MAAM;IACzC,IAAIM,MAAM,EAAEO,sBAAsB,EAAE;MAClC;IACF;IACA,IAAIN,MAAM,EAAE;MACVA,MAAM,CAACO,uBAAuB,CAC5BN,aAAa,IAAI,EAAE,EACnB,GAAGG,IAAI,CAACI,SAAS,IAAIJ,IAAI,CAACK,QAAQ,EAAE,EACpC,KACF,CAAC;IACH;EACF,CAAC,EAAE,CAACR,aAAa,EAAED,MAAM,EAAED,MAAM,EAAEO,sBAAsB,EAAEF,IAAI,CAACI,SAAS,EAAEJ,IAAI,CAACK,QAAQ,CAAC,CAAC;EAE1Ff,SAAS,CAAC,MAAM;IACd,MAAMiB,OAAO,GAAGC,UAAU,CAAC,MAAM;MAC/BF,gBAAgB,CAAC,CAAC;IACpB,CAAC,EAAE,GAAG,CAAC;IAEP,OAAO,MAAMG,YAAY,CAACF,OAAO,CAAC;EACpC,CAAC,EAAE,CAACD,gBAAgB,CAAC,CAAC;EAEtB,OAAO;IAAEL,kBAAkB;IAAEK;EAAiB,CAAC;AACjD,CAAC;AAED,eAAeZ,YAAY","ignoreList":[]}
@@ -0,0 +1,179 @@
1
+ "use strict";
2
+
3
+ import { useCallback, useMemo } from 'react';
4
+ import { useSelector } from 'react-redux';
5
+ import { useChatSettingState } from './useChatSettingState';
6
+ import { generateDefaultText, generateProcessingText } from '../components/styled/StyledInputComponents/CustomTypingIndicator';
7
+ /**
8
+ * Hook for managing custom typing indicator functionality
9
+ * Provides utilities for text generation and typing state management
10
+ */
11
+ export const useCustomTypingIndicator = roomJID => {
12
+ const {
13
+ config
14
+ } = useChatSettingState();
15
+ const {
16
+ rooms
17
+ } = useSelector(state => ({
18
+ rooms: state.rooms.rooms
19
+ }));
20
+ const room = rooms[roomJID];
21
+ const isComposing = room?.composing || false;
22
+ const composingList = room?.composingList || [];
23
+
24
+ // Generate text based on configuration
25
+ const getTypingText = useCallback(customText => {
26
+ if (typeof customText === 'function') {
27
+ return customText(composingList);
28
+ } else if (typeof customText === 'string') {
29
+ return customText;
30
+ } else {
31
+ return generateDefaultText(composingList);
32
+ }
33
+ }, [composingList]);
34
+
35
+ // Generate processing text (for AI/processing states)
36
+ const getProcessingText = useCallback(() => {
37
+ return generateProcessingText(composingList);
38
+ }, [composingList]);
39
+
40
+ // Check if custom typing indicator is enabled
41
+ const isCustomTypingEnabled = useMemo(() => {
42
+ return config?.customTypingIndicator?.enabled || false;
43
+ }, [config?.customTypingIndicator?.enabled]);
44
+
45
+ // Get typing indicator configuration
46
+ const typingConfig = useMemo(() => {
47
+ return config?.customTypingIndicator || null;
48
+ }, [config?.customTypingIndicator]);
49
+
50
+ // Check if indicator should be visible
51
+ const shouldShowIndicator = useMemo(() => {
52
+ return isComposing && composingList.length > 0;
53
+ }, [isComposing, composingList.length]);
54
+
55
+ // Get position-specific styles
56
+ const getPositionStyles = useCallback(position => {
57
+ const baseStyles = typingConfig?.styles || {};
58
+ switch (position) {
59
+ case 'top':
60
+ return {
61
+ ...baseStyles,
62
+ position: 'absolute',
63
+ top: '8px',
64
+ left: '16px',
65
+ right: '16px',
66
+ background: 'rgba(255, 255, 255, 0.95)',
67
+ padding: '8px 12px',
68
+ borderRadius: '8px',
69
+ boxShadow: '0 2px 8px rgba(0, 0, 0, 0.1)',
70
+ backdropFilter: 'blur(10px)'
71
+ };
72
+ case 'overlay':
73
+ return {
74
+ ...baseStyles,
75
+ position: 'fixed',
76
+ top: '50%',
77
+ left: '50%',
78
+ transform: 'translate(-50%, -50%)',
79
+ background: 'rgba(0, 0, 0, 0.8)',
80
+ color: 'white',
81
+ padding: '16px 24px',
82
+ borderRadius: '12px',
83
+ backdropFilter: 'blur(10px)'
84
+ };
85
+ case 'floating':
86
+ return {
87
+ ...baseStyles,
88
+ position: 'fixed',
89
+ bottom: '80px',
90
+ right: '20px',
91
+ background: 'rgba(255, 255, 255, 0.95)',
92
+ padding: '12px 16px',
93
+ borderRadius: '20px',
94
+ boxShadow: '0 4px 16px rgba(0, 0, 0, 0.15)',
95
+ backdropFilter: 'blur(10px)'
96
+ };
97
+ case 'bottom':
98
+ default:
99
+ return {
100
+ ...baseStyles,
101
+ position: 'static',
102
+ padding: '8px 0'
103
+ };
104
+ }
105
+ }, [typingConfig?.styles]);
106
+ return {
107
+ isComposing,
108
+ composingList,
109
+ isCustomTypingEnabled,
110
+ typingConfig,
111
+ shouldShowIndicator,
112
+ getTypingText,
113
+ getProcessingText,
114
+ getPositionStyles
115
+ };
116
+ };
117
+
118
+ /**
119
+ * Utility functions for creating common typing indicator configurations
120
+ */
121
+ export const createTypingIndicatorConfigs = {
122
+ // Default typing indicator
123
+ default: {
124
+ enabled: true,
125
+ position: 'bottom'
126
+ },
127
+ // Processing state indicator
128
+ processing: {
129
+ enabled: true,
130
+ position: 'overlay',
131
+ text: usersTyping => generateProcessingText(usersTyping),
132
+ styles: {
133
+ background: 'rgba(0, 0, 0, 0.8)',
134
+ color: 'white',
135
+ fontSize: '16px',
136
+ fontWeight: '500'
137
+ }
138
+ },
139
+ // Floating indicator
140
+ floating: {
141
+ enabled: true,
142
+ position: 'floating',
143
+ styles: {
144
+ background: 'rgba(255, 255, 255, 0.95)',
145
+ color: '#333',
146
+ fontSize: '14px',
147
+ fontWeight: '500',
148
+ boxShadow: '0 4px 16px rgba(0, 0, 0, 0.15)'
149
+ }
150
+ },
151
+ // Top positioned indicator
152
+ top: {
153
+ enabled: true,
154
+ position: 'top',
155
+ styles: {
156
+ background: 'rgba(255, 255, 255, 0.95)',
157
+ color: '#555',
158
+ fontSize: '14px',
159
+ fontWeight: '500',
160
+ boxShadow: '0 2px 8px rgba(0, 0, 0, 0.1)'
161
+ }
162
+ },
163
+ // Custom text examples
164
+ customTexts: {
165
+ aiProcessing: usersTyping => {
166
+ const states = ['thinking', 'processing', 'generating answer'];
167
+ const randomState = states[Math.floor(Math.random() * states.length)];
168
+ return `${usersTyping[0]} is ${randomState}`;
169
+ },
170
+ simple: usersTyping => {
171
+ return `${usersTyping.length} user${usersTyping.length > 1 ? 's' : ''} typing...`;
172
+ },
173
+ minimal: usersTyping => {
174
+ return '...';
175
+ }
176
+ }
177
+ };
178
+ export default useCustomTypingIndicator;
179
+ //# sourceMappingURL=useCustomTypingIndicator.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["useCallback","useMemo","useSelector","useChatSettingState","generateDefaultText","generateProcessingText","useCustomTypingIndicator","roomJID","config","rooms","state","room","isComposing","composing","composingList","getTypingText","customText","getProcessingText","isCustomTypingEnabled","customTypingIndicator","enabled","typingConfig","shouldShowIndicator","length","getPositionStyles","position","baseStyles","styles","top","left","right","background","padding","borderRadius","boxShadow","backdropFilter","transform","color","bottom","createTypingIndicatorConfigs","default","processing","text","usersTyping","fontSize","fontWeight","floating","customTexts","aiProcessing","states","randomState","Math","floor","random","simple","minimal"],"sourceRoot":"../../../src","sources":["hooks/useCustomTypingIndicator.tsx"],"mappings":";;AAAA,SAASA,WAAW,EAAEC,OAAO,QAAQ,OAAO;AAC5C,SAASC,WAAW,QAAQ,aAAa;AACzC,SAASC,mBAAmB,QAAQ,uBAAuB;AAC3D,SACEC,mBAAmB,EACnBC,sBAAsB,QACjB,kEAAkE;AAGzE;AACA;AACA;AACA;AACA,OAAO,MAAMC,wBAAwB,GAAIC,OAAe,IAAK;EAC3D,MAAM;IAAEC;EAAO,CAAC,GAAGL,mBAAmB,CAAC,CAAC;EACxC,MAAM;IAAEM;EAAM,CAAC,GAAGP,WAAW,CAAEQ,KAAgB,KAAM;IACnDD,KAAK,EAAEC,KAAK,CAACD,KAAK,CAACA;EACrB,CAAC,CAAC,CAAC;EAEH,MAAME,IAAI,GAAGF,KAAK,CAACF,OAAO,CAAC;EAC3B,MAAMK,WAAW,GAAGD,IAAI,EAAEE,SAAS,IAAI,KAAK;EAC5C,MAAMC,aAAa,GAAGH,IAAI,EAAEG,aAAa,IAAI,EAAE;;EAE/C;EACA,MAAMC,aAAa,GAAGf,WAAW,CAC9BgB,UAAyD,IAAK;IAC7D,IAAI,OAAOA,UAAU,KAAK,UAAU,EAAE;MACpC,OAAOA,UAAU,CAACF,aAAa,CAAC;IAClC,CAAC,MAAM,IAAI,OAAOE,UAAU,KAAK,QAAQ,EAAE;MACzC,OAAOA,UAAU;IACnB,CAAC,MAAM;MACL,OAAOZ,mBAAmB,CAACU,aAAa,CAAC;IAC3C;EACF,CAAC,EACD,CAACA,aAAa,CAChB,CAAC;;EAED;EACA,MAAMG,iBAAiB,GAAGjB,WAAW,CAAC,MAAM;IAC1C,OAA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E,KAAK;MACjBX,SAAS,EAAE;IACb;EACF,CAAC;EAED;EACAN,GAAG,EAAE;IACHR,OAAO,EAAE,IAAI;IACbK,QAAQ,EAAE,KAAc;IACxBE,MAAM,EAAE;MACNI,UAAU,EAAE,2BAA2B;MACvCM,KAAK,EAAE,MAAM;MACbO,QAAQ,EAAE,MAAM;MAChBC,UAAU,EAAE,KAAK;MACjBX,SAAS,EAAE;IACb;EACF,CAAC;EAED;EACAa,WAAW,EAAE;IACXC,YAAY,EAAGL,WAAqB,IAAK;MACvC,MAAMM,MAAM,GAAG,CAAC,UAAU,EAAE,YAAY,EAAE,mBAAmB,CAAC;MAC9D,MAAMC,WAAW,GAAGD,MAAM,CAACE,IAAI,CAACC,KAAK,CAACD,IAAI,CAACE,MAAM,CAAC,CAAC,GAAGJ,MAAM,CAAC1B,MAAM,CAAC,CAAC;MACrE,OAAO,GAAGoB,WAAW,CAAC,CAAC,CAAC,OAAOO,WAAW,EAAE;IAC9C,CAAC;IAEDI,MAAM,EAAGX,WAAqB,IAAK;MACjC,OAAO,GAAGA,WAAW,CAACpB,MAAM,QAAQoB,WAAW,CAACpB,MAAM,GAAG,CAAC,GAAG,GAAG,GAAG,EAAE,YAAY;IACnF,CAAC;IAEDgC,OAAO,EAAGZ,WAAqB,IAAK;MAClC,OAAO,KAAK;IACd;EACF;AACF,CAAC;AAED,eAAerC,wBAAwB","ignoreList":[]}
@@ -0,0 +1,46 @@
1
+ "use strict";
2
+
3
+ import { useCallback } from 'react';
4
+ export const useEventHandlers = config => {
5
+ const handleMessageSent = useCallback(async event => {
6
+ try {
7
+ if (config?.eventHandlers?.onMessageSent) {
8
+ await config.eventHandlers.onMessageSent(event);
9
+ }
10
+ } catch (error) {
11
+ console.error('Error in message sent handler:', error);
12
+ throw error;
13
+ }
14
+ }, [config]);
15
+ const handleMessageFailed = useCallback(event => {
16
+ try {
17
+ if (config?.eventHandlers?.onMessageFailed) {
18
+ config.eventHandlers.onMessageFailed(event);
19
+ }
20
+ console.error('Message failed details:', {
21
+ message: event.message,
22
+ roomJID: event.roomJID,
23
+ messageType: event.messageType,
24
+ error: event.error?.message,
25
+ timestamp: new Date().toISOString()
26
+ });
27
+ } catch (handlerError) {
28
+ console.error('Error in message failed handler:', handlerError);
29
+ }
30
+ }, [config]);
31
+ const handleMessageEdited = useCallback(event => {
32
+ try {
33
+ if (config?.eventHandlers?.onMessageEdited) {
34
+ config.eventHandlers.onMessageEdited(event);
35
+ }
36
+ } catch (error) {
37
+ console.error('Error in message edited handler:', error);
38
+ }
39
+ }, [config]);
40
+ return {
41
+ handleMessageSent,
42
+ handleMessageFailed,
43
+ handleMessageEdited
44
+ };
45
+ };
46
+ //# sourceMappingURL=useEventHandlers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["useCallback","useEventHandlers","config","handleMessageSent","event","eventHandlers","onMessageSent","error","console","handleMessageFailed","onMessageFailed","message","roomJID","messageType","timestamp","Date","toISOString","handlerError","handleMessageEdited","onMessageEdited"],"sourceRoot":"../../../src","sources":["hooks/useEventHandlers.tsx"],"mappings":";;AAAA,SAASA,WAAW,QAAQ,OAAO;AA+BnC,OAAO,MAAMC,gBAAgB,GAAIC,MAAgB,IAAwB;EACvE,MAAMC,iBAAiB,GAAGH,WAAW,CACnC,MAAOI,KAAuB,IAAK;IACjC,IAAI;MACF,IAAIF,MAAM,EAAEG,aAAa,EAAEC,aAAa,EAAE;QACxC,MAAMJ,MAAM,CAACG,aAAa,CAACC,aAAa,CAACF,KAAK,CAAC;MACjD;IACF,CAAC,CAAC,OAAOG,KAAK,EAAE;MACdC,OAAO,CAACD,KAAK,CAAC,gCAAgC,EAAEA,KAAK,CAAC;MACtD,MAAMA,KAAK;IACb;EACF,CAAC,EACD,CAACL,MAAM,CACT,CAAC;EAED,MAAMO,mBAAmB,GAAGT,WAAW,CACpCI,KAAyB,IAAK;IAC7B,IAAI;MACF,IAAIF,MAAM,EAAEG,aAAa,EAAEK,eAAe,EAAE;QAC1CR,MAAM,CAACG,aAAa,CAACK,eAAe,CAACN,KAAK,CAAC;MAC7C;MACAI,OAAO,CAACD,KAAK,CAAC,yBAAyB,EAAE;QACvCI,OAAO,EAAEP,KAAK,CAACO,OAAO;QACtBC,OAAO,EAAER,KAAK,CAACQ,OAAO;QACtBC,WAAW,EAAET,KAAK,CAACS,WAAW;QAC9BN,KAAK,EAAEH,KAAK,CAACG,KAAK,EAAEI,OAAO;QAC3BG,SAAS,EAAE,IAAIC,IAAI,CAAC,CAAC,CAACC,WAAW,CAAC;MACpC,CAAC,CAAC;IACJ,CAAC,CAAC,OAAOC,YAAY,EAAE;MACrBT,OAAO,CAACD,KAAK,CAAC,kCAAkC,EAAEU,YAAY,CAAC;IACjE;EACF,CAAC,EACD,CAACf,MAAM,CACT,CAAC;EAED,MAAMgB,mBAAmB,GAAGlB,WAAW,CACpCI,KAAyB,IAAK;IAC7B,IAAI;MACF,IAAIF,MAAM,EAAEG,aAAa,EAAEc,eAAe,EAAE;QAC1CjB,MAAM,CAACG,aAAa,CAACc,eAAe,CAACf,KAAK,CAAC;MAC7C;IACF,CAAC,CAAC,OAAOG,KAAK,EAAE;MACdC,OAAO,CAACD,KAAK,CAAC,kCAAkC,EAAEA,KAAK,CAAC;IAC1D;EACF,CAAC,EACD,CAACL,MAAM,CACT,CAAC;EAED,OAAO;IAAEC,iBAAiB;IAAEM,mBAAmB;IAAES;EAAoB,CAAC;AACxE,CAAC","ignoreList":[]}
@@ -0,0 +1,45 @@
1
+ "use strict";
2
+
3
+ import { useCallback } from 'react';
4
+ import { useAppDispatch } from './hooks';
5
+ import { useXmppClient } from '../context/xmppProvider';
6
+ import { createRoomFromApi } from '../helpers/createRoomFromApi';
7
+ import { getRooms } from '../networking/api-requests/rooms.api';
8
+ import { addRoomViaApi, setIsLoading } from '../roomStore/roomsSlice';
9
+ import { pushSubscriptionService } from '../services/pushSubscriptionService';
10
+ const useGetNewArchRoom = () => {
11
+ const {
12
+ client
13
+ } = useXmppClient();
14
+ const dispatch = useAppDispatch();
15
+ const syncRooms = useCallback(async (client, config) => {
16
+ const rooms = await getRooms();
17
+ const roomJIDs = [];
18
+ rooms?.items?.forEach(room => {
19
+ const createdRoom = createRoomFromApi(room, config?.xmppSettings?.conference);
20
+ if (createdRoom) {
21
+ dispatch(addRoomViaApi({
22
+ room: createdRoom,
23
+ xmpp: client
24
+ }));
25
+ if (createdRoom.jid) {
26
+ roomJIDs.push(createdRoom.jid);
27
+ }
28
+ }
29
+ });
30
+ dispatch(setIsLoading({
31
+ loading: false,
32
+ loadingText: undefined
33
+ }));
34
+ if (client?.client && roomJIDs.length > 0) {
35
+ const userNick = client.client.jid?.getLocal();
36
+ await pushSubscriptionService.subscribeToRooms(client.client, roomJIDs, userNick).catch(error => {
37
+ console.error('Failed to subscribe to loaded rooms for push:', error);
38
+ });
39
+ }
40
+ return rooms?.items || [];
41
+ }, [dispatch]);
42
+ return syncRooms;
43
+ };
44
+ export default useGetNewArchRoom;
45
+ //# sourceMappingURL=useGetNewArchRoom.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["useCallback","useAppDispatch","useXmppClient","createRoomFromApi","getRooms","addRoomViaApi","setIsLoading","pushSubscriptionService","useGetNewArchRoom","client","dispatch","syncRooms","config","rooms","roomJIDs","items","forEach","room","createdRoom","xmppSettings","conference","xmpp","jid","push","loading","loadingText","undefined","length","userNick","getLocal","subscribeToRooms","catch","error","console"],"sourceRoot":"../../../src","sources":["hooks/useGetNewArchRoom.tsx"],"mappings":";;AAAA,SAASA,WAAW,QAAQ,OAAO;AACnC,SAASC,cAAc,QAAQ,SAAS;AACxC,SAASC,aAAa,QAAQ,yBAAyB;AACvD,SAASC,iBAAiB,QAAQ,8BAA8B;AAChE,SAASC,QAAQ,QAAQ,sCAAsC;AAC/D,SACEC,aAAa,EACbC,YAAY,QACP,yBAAyB;AAEhC,SAASC,uBAAuB,QAAQ,qCAAqC;AAE7E,MAAMC,iBAAiB,GAAGA,CAAA,KAAM;EAC9B,MAAM;IAAEC;EA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;AAClB,CAAC;AAED,eAAeH,iBAAiB","ignoreList":[]}
@@ -0,0 +1,68 @@
1
+ "use strict";
2
+
3
+ import { useCallback, useEffect, useRef } from 'react';
4
+ import { useDispatch } from 'react-redux';
5
+ import { useMessageHeapState } from './useMessageHeapState';
6
+ export const useHeapSender = client => {
7
+ const dispatch = useDispatch();
8
+ const {
9
+ queue
10
+ } = useMessageHeapState();
11
+ const sendingRef = useRef(false);
12
+ const inFlightRef = useRef(new Map());
13
+ const sendHeapMessages = useCallback(async () => {
14
+ if (!client || queue.length === 0) {
15
+ return;
16
+ }
17
+ if (!client.presencesReady) {
18
+ console.warn('Presences not ready, delaying heap send');
19
+ return;
20
+ }
21
+ if (sendingRef.current) {
22
+ return;
23
+ }
24
+ sendingRef.current = true;
25
+ try {
26
+ for (const msg of queue) {
27
+ const lastAttempt = inFlightRef.current.get(msg.id);
28
+ if (lastAttempt && Date.now() - lastAttempt < 15000) {
29
+ continue;
30
+ }
31
+ inFlightRef.current.set(msg.id, Date.now());
32
+ try {
33
+ if (msg.langSource) {
34
+ await client.sendTextMessageWithTranslateTagStanza(msg.roomJid, msg.user.firstName || msg.user.name?.split(' ')[0] || '', msg.user.lastName || msg.user.name?.split(' ')[1] || '', '', msg.user.walletAddress || '', msg.body, '', !!msg.isReply, msg.showInChannel === 'true', msg.mainMessage || '', msg.langSource);
35
+ } else {
36
+ await client.sendMessage(msg.roomJid, msg.user.firstName || msg.user.name?.split(' ')[0] || '', msg.user.lastName || msg.user.name?.split(' ')[1] || '', '', msg.user.walletAddress || '', msg.body, '', !!msg.isReply, !!msg.showInChannel, msg.mainMessage, msg.id);
37
+ }
38
+ } catch (err) {
39
+ console.warn('Failed to send heap message', msg, err);
40
+ inFlightRef.current.delete(msg.id);
41
+ }
42
+ }
43
+ } finally {
44
+ sendingRef.current = false;
45
+ }
46
+ }, [client, queue, dispatch]);
47
+ const prevReadyRef = useRef(false);
48
+ useEffect(() => {
49
+ const nowReady = !!client?.presencesReady;
50
+ const wasReady = prevReadyRef.current;
51
+ prevReadyRef.current = nowReady;
52
+ if (!wasReady && nowReady && queue.length > 0) {
53
+ sendHeapMessages();
54
+ }
55
+ }, [client?.presencesReady, queue.length, sendHeapMessages]);
56
+ useEffect(() => {
57
+ const currentIds = new Set(queue.map(m => m.id));
58
+ for (const id of Array.from(inFlightRef.current.keys())) {
59
+ if (!currentIds.has(id)) {
60
+ inFlightRef.current.delete(id);
61
+ }
62
+ }
63
+ }, [queue]);
64
+ return {
65
+ sendHeapMessages
66
+ };
67
+ };
68
+ //# sourceMappingURL=useHeapSender.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["useCallback","useEffect","useRef","useDispatch","useMessageHeapState","useHeapSender","client","dispatch","queue","sendingRef","inFlightRef","Map","sendHeapMessages","length","presencesReady","console","warn","current","msg","lastAttempt","get","id","Date","now","set","langSource","sendTextMessageWithTranslateTagStanza","roomJid","user","firstName","name","split","lastName","walletAddress","body","isReply","showInChannel","mainMessage","sendMessage","err","delete","prevReadyRef","nowReady","wasReady","currentIds","Set","map","m","Array","from","keys","has"],"sourceRoot":"../../../src","sources":["hooks/useHeapSender.tsx"],"mappings":";;AAAA,SAASA,WAAW,EAAEC,SAAS,EAAEC,MAAM,QAAQ,OAAO;AACtD,SAASC,WAAW,QAAQ,aAAa;AACzC,SAASC,mBAAmB,QAAQ,uBAAuB;AAI3D,OAAO,MAAMC,aAAa,GAAIC,MAAyB,IAAK;EAC1D,MAAMC,QAAQ,GAAGJ,WAAW,CAAC,CAAC;EAC9B,MAAM;IAAEK;EAAM,CAAC,GAAGJ,mBAAmB,CAAC,CAAC;EACvC,MAAMK,UAAU,GAAGP,MAAM,CAAC,KAAK,CAAC;EAChC,MAAMQ,WAAW,GAAGR,MAAM,CAAsB,IAAIS,GAAG,CAAC,CAAC,CAAC;EAE1D,MAAMC,gBAAgB,GAAGZ,WAAW,CAAC,YAAY;IAC/C,IAAI,CAACM,MAAM,IAAIE,KAAK,CAACK,MAAM,KAAK,CAA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