@ethora/chat-component-rn 26.8.1 → 26.8.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +110 -0
- package/README.md +70 -11
- package/lib/commonjs/assets/EmptyChatIllustration.js +7 -6
- package/lib/commonjs/assets/EmptyChatIllustration.js.map +1 -1
- package/lib/commonjs/assets/icons.js +7 -2
- package/lib/commonjs/assets/icons.js.map +1 -1
- package/lib/commonjs/components/AuthForms/Login.js +27 -12
- package/lib/commonjs/components/AuthForms/Login.js.map +1 -1
- package/lib/commonjs/components/ContextMenu/ContextMenuComponents.js +12 -4
- package/lib/commonjs/components/ContextMenu/ContextMenuComponents.js.map +1 -1
- package/lib/commonjs/components/DropdownMenu/DropdownMenu.js +16 -9
- package/lib/commonjs/components/DropdownMenu/DropdownMenu.js.map +1 -1
- package/lib/commonjs/components/ExampleComponents/CustomMessage.js +25 -7
- package/lib/commonjs/components/ExampleComponents/CustomMessage.js.map +1 -1
- package/lib/commonjs/components/ExampleComponents/CustomTypingIndicatorExamples.js +18 -6
- package/lib/commonjs/components/ExampleComponents/CustomTypingIndicatorExamples.js.map +1 -1
- package/lib/commonjs/components/Header/HeaderRoomList.js +34 -10
- package/lib/commonjs/components/Header/HeaderRoomList.js.map +1 -1
- package/lib/commonjs/components/InputComponents/Search.js +13 -4
- package/lib/commonjs/components/InputComponents/Search.js.map +1 -1
- package/lib/commonjs/components/MainComponents/ChatHeader.js +18 -6
- package/lib/commonjs/components/MainComponents/ChatHeader.js.map +1 -1
- package/lib/commonjs/components/MainComponents/ChatRoom.js +154 -15
- package/lib/commonjs/components/MainComponents/ChatRoom.js.map +1 -1
- package/lib/commonjs/components/MainComponents/ChatWrapper.js +42 -19
- package/lib/commonjs/components/MainComponents/ChatWrapper.js.map +1 -1
- package/lib/commonjs/components/MainComponents/LanguageSelectorModal.js +37 -10
- package/lib/commonjs/components/MainComponents/LanguageSelectorModal.js.map +1 -1
- package/lib/commonjs/components/MainComponents/LoginWrapper.js +2 -1
- package/lib/commonjs/components/MainComponents/LoginWrapper.js.map +1 -1
- package/lib/commonjs/components/MainComponents/MediaMessage.js +72 -28
- package/lib/commonjs/components/MainComponents/MediaMessage.js.map +1 -1
- package/lib/commonjs/components/MainComponents/MessageContainer.js +5 -1
- package/lib/commonjs/components/MainComponents/MessageContainer.js.map +1 -1
- package/lib/commonjs/components/MainComponents/MessageList.js +22 -8
- package/lib/commonjs/components/MainComponents/MessageList.js.map +1 -1
- package/lib/commonjs/components/MainComponents/ProfileImagePlaceholder.js +14 -13
- package/lib/commonjs/components/MainComponents/ProfileImagePlaceholder.js.map +1 -1
- package/lib/commonjs/components/MainComponents/RNStyled.js +12 -4
- package/lib/commonjs/components/MainComponents/RNStyled.js.map +1 -1
- package/lib/commonjs/components/MainComponents/ReduxWrapper.js +25 -8
- package/lib/commonjs/components/MainComponents/ReduxWrapper.js.map +1 -1
- package/lib/commonjs/components/MainComponents/RoomList.js +214 -38
- package/lib/commonjs/components/MainComponents/RoomList.js.map +1 -1
- package/lib/commonjs/components/MainComponents/Select.js +29 -8
- package/lib/commonjs/components/MainComponents/Select.js.map +1 -1
- package/lib/commonjs/components/Menu/HeaderRoomListMenu.js +329 -99
- package/lib/commonjs/components/Menu/HeaderRoomListMenu.js.map +1 -1
- package/lib/commonjs/components/MessageBubble/BottomReplyContainer.js +24 -8
- package/lib/commonjs/components/MessageBubble/BottomReplyContainer.js.map +1 -1
- package/lib/commonjs/components/MessageBubble/Message.js +46 -24
- package/lib/commonjs/components/MessageBubble/Message.js.map +1 -1
- package/lib/commonjs/components/MessageBubble/MessageInteractions.js +15 -4
- package/lib/commonjs/components/MessageBubble/MessageInteractions.js.map +1 -1
- package/lib/commonjs/components/MessageBubble/MessageReaction.js +10 -5
- package/lib/commonjs/components/MessageBubble/MessageReaction.js.map +1 -1
- package/lib/commonjs/components/Modals/AddMembersModal/AddMembersModal.js +1 -5
- package/lib/commonjs/components/Modals/AddMembersModal/AddMembersModal.js.map +1 -1
- package/lib/commonjs/components/Modals/AttachSheet/AttachSheet.js +345 -118
- package/lib/commonjs/components/Modals/AttachSheet/AttachSheet.js.map +1 -1
- package/lib/commonjs/components/Modals/ChatProfileModal/ChatProfileModal.js +599 -203
- package/lib/commonjs/components/Modals/ChatProfileModal/ChatProfileModal.js.map +1 -1
- package/lib/commonjs/components/Modals/ChatProfileModal/DeleteChatModal.js +5 -7
- package/lib/commonjs/components/Modals/ChatProfileModal/DeleteChatModal.js.map +1 -1
- package/lib/commonjs/components/Modals/ChatProfileModal/ReportChatModal.js +230 -0
- package/lib/commonjs/components/Modals/ChatProfileModal/ReportChatModal.js.map +1 -0
- package/lib/commonjs/components/Modals/FilePreviewModal/FilePreviewModal.js +89 -36
- package/lib/commonjs/components/Modals/FilePreviewModal/FilePreviewModal.js.map +1 -1
- package/lib/commonjs/components/Modals/FilePreviewModal/PdfView.js +2 -1
- package/lib/commonjs/components/Modals/FilePreviewModal/PdfView.js.map +1 -1
- package/lib/commonjs/components/Modals/Modal/Modal.js +8 -0
- package/lib/commonjs/components/Modals/Modal/Modal.js.map +1 -1
- package/lib/commonjs/components/Modals/ModalHeaderComponent.js +8 -2
- package/lib/commonjs/components/Modals/ModalHeaderComponent.js.map +1 -1
- package/lib/commonjs/components/Modals/ModalWrapper/ModalWrapper.js +8 -8
- package/lib/commonjs/components/Modals/ModalWrapper/ModalWrapper.js.map +1 -1
- package/lib/commonjs/components/Modals/NewChatModal/ModalContent.js +3 -6
- package/lib/commonjs/components/Modals/NewChatModal/ModalContent.js.map +1 -1
- package/lib/commonjs/components/Modals/NewChatModal/NewChatModal.js +205 -106
- package/lib/commonjs/components/Modals/NewChatModal/NewChatModal.js.map +1 -1
- package/lib/commonjs/components/Modals/NewChatModal/UpdNewChatModal.js +8 -0
- package/lib/commonjs/components/Modals/NewChatModal/UpdNewChatModal.js.map +1 -1
- package/lib/commonjs/components/Modals/ProfileHeader/ProfileHeader.js +563 -0
- package/lib/commonjs/components/Modals/ProfileHeader/ProfileHeader.js.map +1 -0
- package/lib/commonjs/components/Modals/ProfileHeader/ProfileMenu.js +215 -0
- package/lib/commonjs/components/Modals/ProfileHeader/ProfileMenu.js.map +1 -0
- package/lib/commonjs/components/Modals/SelectUsersModal/SelectUsersModal.js +7 -9
- package/lib/commonjs/components/Modals/SelectUsersModal/SelectUsersModal.js.map +1 -1
- package/lib/commonjs/components/Modals/SettingsModals/ManageDataModal/ManageDataModal.js +8 -6
- package/lib/commonjs/components/Modals/SettingsModals/ManageDataModal/ManageDataModal.js.map +1 -1
- package/lib/commonjs/components/Modals/SettingsModals/Referrals/Referrals.js +7 -2
- package/lib/commonjs/components/Modals/SettingsModals/Referrals/Referrals.js.map +1 -1
- package/lib/commonjs/components/Modals/SettingsModals/SharedStyledComponents.js +7 -3
- package/lib/commonjs/components/Modals/SettingsModals/SharedStyledComponents.js.map +1 -1
- package/lib/commonjs/components/Modals/SettingsModals/Visibility/RadioInput.js +10 -6
- package/lib/commonjs/components/Modals/SettingsModals/Visibility/RadioInput.js.map +1 -1
- package/lib/commonjs/components/Modals/SettingsModals/Visibility/VisibilityModal.js +7 -6
- package/lib/commonjs/components/Modals/SettingsModals/Visibility/VisibilityModal.js.map +1 -1
- package/lib/commonjs/components/Modals/UserProfileModal/EditUserModal.js +10 -22
- package/lib/commonjs/components/Modals/UserProfileModal/EditUserModal.js.map +1 -1
- package/lib/commonjs/components/Modals/UserProfileModal/UserProfileModal.js +510 -244
- package/lib/commonjs/components/Modals/UserProfileModal/UserProfileModal.js.map +1 -1
- package/lib/commonjs/components/Modals/UserSettingsModal/UserSettingsModal.js +77 -46
- package/lib/commonjs/components/Modals/UserSettingsModal/UserSettingsModal.js.map +1 -1
- package/lib/commonjs/components/Modals/styledModalComponents.js +68 -17
- package/lib/commonjs/components/Modals/styledModalComponents.js.map +1 -1
- package/lib/commonjs/components/RoomComponents/ChatRoomItem.js +30 -10
- package/lib/commonjs/components/RoomComponents/ChatRoomItem.js.map +1 -1
- package/lib/commonjs/components/RoomComponents/styled/LastAudioMessage.js +6 -2
- package/lib/commonjs/components/RoomComponents/styled/LastAudioMessage.js.map +1 -1
- package/lib/commonjs/components/RoomComponents/styled/LastMessageFile.js +22 -3
- package/lib/commonjs/components/RoomComponents/styled/LastMessageFile.js.map +1 -1
- package/lib/commonjs/components/RoomComponents/styled/LastMessagePhoto.js +17 -3
- package/lib/commonjs/components/RoomComponents/styled/LastMessagePhoto.js.map +1 -1
- package/lib/commonjs/components/RoomComponents/styled/LastMessageVideo.js +17 -3
- package/lib/commonjs/components/RoomComponents/styled/LastMessageVideo.js.map +1 -1
- package/lib/commonjs/components/RoomComponents/styled/StyledRoomComponents.js +6 -0
- package/lib/commonjs/components/RoomComponents/styled/StyledRoomComponents.js.map +1 -1
- package/lib/commonjs/components/Thread/ThreadWrapper.js +9 -2
- package/lib/commonjs/components/Thread/ThreadWrapper.js.map +1 -1
- package/lib/commonjs/components/Toast/Toast.js +3 -1
- package/lib/commonjs/components/Toast/Toast.js.map +1 -1
- package/lib/commonjs/components/VideoCalls/VideoCallSession.js +6 -3
- package/lib/commonjs/components/VideoCalls/VideoCallSession.js.map +1 -1
- package/lib/commonjs/components/styled/AudioMessage.js +18 -12
- package/lib/commonjs/components/styled/AudioMessage.js.map +1 -1
- package/lib/commonjs/components/styled/Button.js +18 -9
- package/lib/commonjs/components/styled/Button.js.map +1 -1
- package/lib/commonjs/components/styled/DateLabel.js +8 -5
- package/lib/commonjs/components/styled/DateLabel.js.map +1 -1
- package/lib/commonjs/components/styled/MediaModal.js +27 -21
- package/lib/commonjs/components/styled/MediaModal.js.map +1 -1
- package/lib/commonjs/components/styled/MessageImage.js +37 -9
- package/lib/commonjs/components/styled/MessageImage.js.map +1 -1
- package/lib/commonjs/components/styled/RoomListComponents/index.js +60 -38
- package/lib/commonjs/components/styled/RoomListComponents/index.js.map +1 -1
- package/lib/commonjs/components/styled/SendInput.js +93 -19
- package/lib/commonjs/components/styled/SendInput.js.map +1 -1
- package/lib/commonjs/components/styled/StyledComponents.js +75 -25
- package/lib/commonjs/components/styled/StyledComponents.js.map +1 -1
- package/lib/commonjs/components/styled/StyledInput.js +32 -18
- package/lib/commonjs/components/styled/StyledInput.js.map +1 -1
- package/lib/commonjs/components/styled/StyledInputComponents/CustomTypingIndicator.js +13 -8
- package/lib/commonjs/components/styled/StyledInputComponents/CustomTypingIndicator.js.map +1 -1
- package/lib/commonjs/components/styled/StyledInputComponents/MediaComponents.js +20 -9
- package/lib/commonjs/components/styled/StyledInputComponents/MediaComponents.js.map +1 -1
- package/lib/commonjs/components/styled/StyledInputComponents/StyledInputComponents.js +50 -22
- package/lib/commonjs/components/styled/StyledInputComponents/StyledInputComponents.js.map +1 -1
- package/lib/commonjs/components/styled/TreadLabel.js +6 -3
- package/lib/commonjs/components/styled/TreadLabel.js.map +1 -1
- package/lib/commonjs/components/styled/UnsupportedType.js +14 -4
- package/lib/commonjs/components/styled/UnsupportedType.js.map +1 -1
- package/lib/commonjs/components/styled/VideoMessage.js +119 -61
- package/lib/commonjs/components/styled/VideoMessage.js.map +1 -1
- package/lib/commonjs/context/MessageNotificationContext.js +14 -3
- package/lib/commonjs/context/MessageNotificationContext.js.map +1 -1
- package/lib/commonjs/context/xmppProvider.js +184 -59
- package/lib/commonjs/context/xmppProvider.js.map +1 -1
- package/lib/commonjs/helpers/createMessageFromXml.js +19 -1
- package/lib/commonjs/helpers/createMessageFromXml.js.map +1 -1
- package/lib/commonjs/helpers/ensureScopedChatCache.js +2 -2
- package/lib/commonjs/helpers/ensureScopedChatCache.js.map +1 -1
- package/lib/commonjs/helpers/getChatBackground.js +26 -0
- package/lib/commonjs/helpers/getChatBackground.js.map +1 -0
- package/lib/commonjs/helpers/getDateLabelColor.js +3 -1
- package/lib/commonjs/helpers/getDateLabelColor.js.map +1 -1
- package/lib/commonjs/helpers/getDisplayFileName.js +79 -0
- package/lib/commonjs/helpers/getDisplayFileName.js.map +1 -0
- package/lib/commonjs/helpers/getIconColor.js +4 -1
- package/lib/commonjs/helpers/getIconColor.js.map +1 -1
- package/lib/commonjs/helpers/getSenderNameColor.js +3 -1
- package/lib/commonjs/helpers/getSenderNameColor.js.map +1 -1
- package/lib/commonjs/helpers/getServerReadTimestamp.js +188 -0
- package/lib/commonjs/helpers/getServerReadTimestamp.js.map +1 -0
- package/lib/commonjs/helpers/historyPreloadScheduler.js +65 -2
- package/lib/commonjs/helpers/historyPreloadScheduler.js.map +1 -1
- package/lib/commonjs/helpers/initXmppRooms.js +14 -8
- package/lib/commonjs/helpers/initXmppRooms.js.map +1 -1
- package/lib/commonjs/helpers/insertMessageWithDelimiter.js +51 -9
- package/lib/commonjs/helpers/insertMessageWithDelimiter.js.map +1 -1
- package/lib/commonjs/helpers/isOwnMessage.js +75 -0
- package/lib/commonjs/helpers/isOwnMessage.js.map +1 -0
- package/lib/commonjs/helpers/keyboardLayout.js +12 -2
- package/lib/commonjs/helpers/keyboardLayout.js.map +1 -1
- package/lib/commonjs/helpers/markdownParser.js +27 -5
- package/lib/commonjs/helpers/markdownParser.js.map +1 -1
- package/lib/commonjs/helpers/mediaLibraryRuntime.js +31 -0
- package/lib/commonjs/helpers/mediaLibraryRuntime.js.map +1 -0
- package/lib/commonjs/helpers/mimeToExtension.js +6 -14
- package/lib/commonjs/helpers/mimeToExtension.js.map +1 -1
- package/lib/commonjs/helpers/msgSortableMs.js +37 -0
- package/lib/commonjs/helpers/msgSortableMs.js.map +1 -0
- package/lib/commonjs/helpers/parseMessageBody.js +82 -24
- package/lib/commonjs/helpers/parseMessageBody.js.map +1 -1
- package/lib/commonjs/helpers/persistCrypto.js +122 -0
- package/lib/commonjs/helpers/persistCrypto.js.map +1 -0
- package/lib/commonjs/helpers/pickImageAsset.js +68 -0
- package/lib/commonjs/helpers/pickImageAsset.js.map +1 -0
- package/lib/commonjs/helpers/pushPayload.js +71 -0
- package/lib/commonjs/helpers/pushPayload.js.map +1 -0
- package/lib/commonjs/helpers/resolveInitBeforeLoadUser.js +130 -17
- package/lib/commonjs/helpers/resolveInitBeforeLoadUser.js.map +1 -1
- package/lib/commonjs/helpers/secureFileUrl.js +101 -0
- package/lib/commonjs/helpers/secureFileUrl.js.map +1 -0
- package/lib/commonjs/helpers/secureKeyValue.js +83 -0
- package/lib/commonjs/helpers/secureKeyValue.js.map +1 -0
- package/lib/commonjs/helpers/secureStoreRuntime.js +59 -0
- package/lib/commonjs/helpers/secureStoreRuntime.js.map +1 -0
- package/lib/commonjs/helpers/secureUserStorage.js +75 -0
- package/lib/commonjs/helpers/secureUserStorage.js.map +1 -0
- package/lib/commonjs/helpers/shallowEqual.js +36 -0
- package/lib/commonjs/helpers/shallowEqual.js.map +1 -0
- package/lib/commonjs/helpers/sheetGestures.js +32 -0
- package/lib/commonjs/helpers/sheetGestures.js.map +1 -0
- package/lib/commonjs/hooks/useChatRoomFocus.js +45 -12
- package/lib/commonjs/hooks/useChatRoomFocus.js.map +1 -1
- package/lib/commonjs/hooks/useChatWrapperInit.js +30 -10
- package/lib/commonjs/hooks/useChatWrapperInit.js.map +1 -1
- package/lib/commonjs/hooks/useComposing.js +27 -0
- package/lib/commonjs/hooks/useComposing.js.map +1 -1
- package/lib/commonjs/hooks/useCustomTypingIndicator.js +7 -3
- package/lib/commonjs/hooks/useCustomTypingIndicator.js.map +1 -1
- package/lib/commonjs/hooks/useFileToken.js +10 -0
- package/lib/commonjs/hooks/useFileToken.js.map +1 -0
- package/lib/commonjs/hooks/useLogout.js +33 -10
- package/lib/commonjs/hooks/useLogout.js.map +1 -1
- package/lib/commonjs/hooks/usePendingNotification.js +8 -11
- package/lib/commonjs/hooks/usePendingNotification.js.map +1 -1
- package/lib/commonjs/hooks/useSendMessage.js +50 -14
- package/lib/commonjs/hooks/useSendMessage.js.map +1 -1
- package/lib/commonjs/hooks/useTheme.js +35 -0
- package/lib/commonjs/hooks/useTheme.js.map +1 -0
- package/lib/commonjs/hooks/useUnreadMessagesCounter.js +6 -1
- package/lib/commonjs/hooks/useUnreadMessagesCounter.js.map +1 -1
- package/lib/commonjs/i18n/strings.js +163 -37
- package/lib/commonjs/i18n/strings.js.map +1 -1
- package/lib/commonjs/main.js +119 -0
- package/lib/commonjs/main.js.map +1 -1
- package/lib/commonjs/networking/api-requests/auth.api.js +134 -60
- package/lib/commonjs/networking/api-requests/auth.api.js.map +1 -1
- package/lib/commonjs/networking/api-requests/push.api.js +130 -45
- package/lib/commonjs/networking/api-requests/push.api.js.map +1 -1
- package/lib/commonjs/networking/api-requests/roomMembers.api.js +1 -1
- package/lib/commonjs/networking/api-requests/roomMembers.api.js.map +1 -1
- package/lib/commonjs/networking/api-requests/rooms.api.js +22 -9
- package/lib/commonjs/networking/api-requests/rooms.api.js.map +1 -1
- package/lib/commonjs/networking/api-requests/user.api.js +68 -9
- package/lib/commonjs/networking/api-requests/user.api.js.map +1 -1
- package/lib/commonjs/networking/apiClient.js +62 -112
- package/lib/commonjs/networking/apiClient.js.map +1 -1
- package/lib/commonjs/networking/authRefresh.js +332 -0
- package/lib/commonjs/networking/authRefresh.js.map +1 -0
- package/lib/commonjs/networking/stanzaHandlers.js +41 -28
- package/lib/commonjs/networking/stanzaHandlers.js.map +1 -1
- package/lib/commonjs/networking/xmpp/flushLastViewedToPrivateStore.js +46 -8
- package/lib/commonjs/networking/xmpp/flushLastViewedToPrivateStore.js.map +1 -1
- package/lib/commonjs/networking/xmpp/presenceInRoom.xmpp.js +8 -1
- package/lib/commonjs/networking/xmpp/presenceInRoom.xmpp.js.map +1 -1
- package/lib/commonjs/networking/xmpp/subscribeToRoomMessages.xmpp.js +5 -1
- package/lib/commonjs/networking/xmpp/subscribeToRoomMessages.xmpp.js.map +1 -1
- package/lib/commonjs/networking/xmppClient.js +124 -8
- package/lib/commonjs/networking/xmppClient.js.map +1 -1
- package/lib/commonjs/roomStore/chatSettingsSlice.js +26 -7
- package/lib/commonjs/roomStore/chatSettingsSlice.js.map +1 -1
- package/lib/commonjs/roomStore/index.js +35 -2
- package/lib/commonjs/roomStore/index.js.map +1 -1
- package/lib/commonjs/roomStore/persistence.js +226 -23
- package/lib/commonjs/roomStore/persistence.js.map +1 -1
- package/lib/commonjs/roomStore/roomsSlice.js +151 -38
- package/lib/commonjs/roomStore/roomsSlice.js.map +1 -1
- package/lib/commonjs/services/pushRegistration.js +250 -0
- package/lib/commonjs/services/pushRegistration.js.map +1 -0
- package/lib/commonjs/services/pushSubscriptionService.js +15 -37
- package/lib/commonjs/services/pushSubscriptionService.js.map +1 -1
- package/lib/commonjs/theme/index.js +38 -0
- package/lib/commonjs/theme/index.js.map +1 -0
- package/lib/commonjs/theme/styled.d.js +4 -0
- package/lib/commonjs/theme/styled.d.js.map +1 -0
- package/lib/commonjs/theme/theme.js +137 -0
- package/lib/commonjs/theme/theme.js.map +1 -0
- package/lib/commonjs/version.js +1 -1
- package/lib/module/assets/EmptyChatIllustration.js +7 -6
- package/lib/module/assets/EmptyChatIllustration.js.map +1 -1
- package/lib/module/assets/icons.js +6 -1
- package/lib/module/assets/icons.js.map +1 -1
- package/lib/module/components/AuthForms/Login.js +27 -12
- package/lib/module/components/AuthForms/Login.js.map +1 -1
- package/lib/module/components/ContextMenu/ContextMenuComponents.js +12 -4
- package/lib/module/components/ContextMenu/ContextMenuComponents.js.map +1 -1
- package/lib/module/components/DropdownMenu/DropdownMenu.js +16 -9
- package/lib/module/components/DropdownMenu/DropdownMenu.js.map +1 -1
- package/lib/module/components/ExampleComponents/CustomMessage.js +25 -7
- package/lib/module/components/ExampleComponents/CustomMessage.js.map +1 -1
- package/lib/module/components/ExampleComponents/CustomTypingIndicatorExamples.js +18 -6
- package/lib/module/components/ExampleComponents/CustomTypingIndicatorExamples.js.map +1 -1
- package/lib/module/components/Header/HeaderRoomList.js +34 -10
- package/lib/module/components/Header/HeaderRoomList.js.map +1 -1
- package/lib/module/components/InputComponents/Search.js +13 -4
- package/lib/module/components/InputComponents/Search.js.map +1 -1
- package/lib/module/components/MainComponents/ChatHeader.js +18 -6
- package/lib/module/components/MainComponents/ChatHeader.js.map +1 -1
- package/lib/module/components/MainComponents/ChatRoom.js +156 -17
- package/lib/module/components/MainComponents/ChatRoom.js.map +1 -1
- package/lib/module/components/MainComponents/ChatWrapper.js +43 -20
- package/lib/module/components/MainComponents/ChatWrapper.js.map +1 -1
- package/lib/module/components/MainComponents/LanguageSelectorModal.js +37 -10
- package/lib/module/components/MainComponents/LanguageSelectorModal.js.map +1 -1
- package/lib/module/components/MainComponents/LoginWrapper.js +2 -1
- package/lib/module/components/MainComponents/LoginWrapper.js.map +1 -1
- package/lib/module/components/MainComponents/MediaMessage.js +72 -29
- package/lib/module/components/MainComponents/MediaMessage.js.map +1 -1
- package/lib/module/components/MainComponents/MessageContainer.js +5 -1
- package/lib/module/components/MainComponents/MessageContainer.js.map +1 -1
- package/lib/module/components/MainComponents/MessageList.js +22 -8
- package/lib/module/components/MainComponents/MessageList.js.map +1 -1
- package/lib/module/components/MainComponents/ProfileImagePlaceholder.js +14 -13
- package/lib/module/components/MainComponents/ProfileImagePlaceholder.js.map +1 -1
- package/lib/module/components/MainComponents/RNStyled.js +12 -4
- package/lib/module/components/MainComponents/RNStyled.js.map +1 -1
- package/lib/module/components/MainComponents/ReduxWrapper.js +25 -8
- package/lib/module/components/MainComponents/ReduxWrapper.js.map +1 -1
- package/lib/module/components/MainComponents/RoomList.js +213 -38
- package/lib/module/components/MainComponents/RoomList.js.map +1 -1
- package/lib/module/components/MainComponents/Select.js +29 -8
- package/lib/module/components/MainComponents/Select.js.map +1 -1
- package/lib/module/components/Menu/HeaderRoomListMenu.js +331 -102
- package/lib/module/components/Menu/HeaderRoomListMenu.js.map +1 -1
- package/lib/module/components/MessageBubble/BottomReplyContainer.js +24 -8
- package/lib/module/components/MessageBubble/BottomReplyContainer.js.map +1 -1
- package/lib/module/components/MessageBubble/Message.js +47 -25
- package/lib/module/components/MessageBubble/Message.js.map +1 -1
- package/lib/module/components/MessageBubble/MessageInteractions.js +15 -4
- package/lib/module/components/MessageBubble/MessageInteractions.js.map +1 -1
- package/lib/module/components/MessageBubble/MessageReaction.js +10 -5
- package/lib/module/components/MessageBubble/MessageReaction.js.map +1 -1
- package/lib/module/components/Modals/AddMembersModal/AddMembersModal.js +2 -6
- package/lib/module/components/Modals/AddMembersModal/AddMembersModal.js.map +1 -1
- package/lib/module/components/Modals/AttachSheet/AttachSheet.js +336 -121
- package/lib/module/components/Modals/AttachSheet/AttachSheet.js.map +1 -1
- package/lib/module/components/Modals/ChatProfileModal/ChatProfileModal.js +603 -208
- package/lib/module/components/Modals/ChatProfileModal/ChatProfileModal.js.map +1 -1
- package/lib/module/components/Modals/ChatProfileModal/DeleteChatModal.js +6 -8
- package/lib/module/components/Modals/ChatProfileModal/DeleteChatModal.js.map +1 -1
- package/lib/module/components/Modals/ChatProfileModal/ReportChatModal.js +225 -0
- package/lib/module/components/Modals/ChatProfileModal/ReportChatModal.js.map +1 -0
- package/lib/module/components/Modals/FilePreviewModal/FilePreviewModal.js +90 -37
- package/lib/module/components/Modals/FilePreviewModal/FilePreviewModal.js.map +1 -1
- package/lib/module/components/Modals/FilePreviewModal/PdfView.js +2 -1
- package/lib/module/components/Modals/FilePreviewModal/PdfView.js.map +1 -1
- package/lib/module/components/Modals/Modal/Modal.js +9 -1
- package/lib/module/components/Modals/Modal/Modal.js.map +1 -1
- package/lib/module/components/Modals/ModalHeaderComponent.js +8 -2
- package/lib/module/components/Modals/ModalHeaderComponent.js.map +1 -1
- package/lib/module/components/Modals/ModalWrapper/ModalWrapper.js +10 -10
- package/lib/module/components/Modals/ModalWrapper/ModalWrapper.js.map +1 -1
- package/lib/module/components/Modals/NewChatModal/ModalContent.js +4 -7
- package/lib/module/components/Modals/NewChatModal/ModalContent.js.map +1 -1
- package/lib/module/components/Modals/NewChatModal/NewChatModal.js +208 -108
- package/lib/module/components/Modals/NewChatModal/NewChatModal.js.map +1 -1
- package/lib/module/components/Modals/NewChatModal/UpdNewChatModal.js +8 -0
- package/lib/module/components/Modals/NewChatModal/UpdNewChatModal.js.map +1 -1
- package/lib/module/components/Modals/ProfileHeader/ProfileHeader.js +555 -0
- package/lib/module/components/Modals/ProfileHeader/ProfileHeader.js.map +1 -0
- package/lib/module/components/Modals/ProfileHeader/ProfileMenu.js +210 -0
- package/lib/module/components/Modals/ProfileHeader/ProfileMenu.js.map +1 -0
- package/lib/module/components/Modals/SelectUsersModal/SelectUsersModal.js +8 -10
- package/lib/module/components/Modals/SelectUsersModal/SelectUsersModal.js.map +1 -1
- package/lib/module/components/Modals/SettingsModals/ManageDataModal/ManageDataModal.js +8 -6
- package/lib/module/components/Modals/SettingsModals/ManageDataModal/ManageDataModal.js.map +1 -1
- package/lib/module/components/Modals/SettingsModals/Referrals/Referrals.js +7 -2
- package/lib/module/components/Modals/SettingsModals/Referrals/Referrals.js.map +1 -1
- package/lib/module/components/Modals/SettingsModals/SharedStyledComponents.js +7 -3
- package/lib/module/components/Modals/SettingsModals/SharedStyledComponents.js.map +1 -1
- package/lib/module/components/Modals/SettingsModals/Visibility/RadioInput.js +10 -6
- package/lib/module/components/Modals/SettingsModals/Visibility/RadioInput.js.map +1 -1
- package/lib/module/components/Modals/SettingsModals/Visibility/VisibilityModal.js +7 -6
- package/lib/module/components/Modals/SettingsModals/Visibility/VisibilityModal.js.map +1 -1
- package/lib/module/components/Modals/UserProfileModal/EditUserModal.js +11 -24
- package/lib/module/components/Modals/UserProfileModal/EditUserModal.js.map +1 -1
- package/lib/module/components/Modals/UserProfileModal/UserProfileModal.js +512 -248
- package/lib/module/components/Modals/UserProfileModal/UserProfileModal.js.map +1 -1
- package/lib/module/components/Modals/UserSettingsModal/UserSettingsModal.js +79 -48
- package/lib/module/components/Modals/UserSettingsModal/UserSettingsModal.js.map +1 -1
- package/lib/module/components/Modals/styledModalComponents.js +67 -16
- package/lib/module/components/Modals/styledModalComponents.js.map +1 -1
- package/lib/module/components/RoomComponents/ChatRoomItem.js +30 -10
- package/lib/module/components/RoomComponents/ChatRoomItem.js.map +1 -1
- package/lib/module/components/RoomComponents/styled/LastAudioMessage.js +6 -2
- package/lib/module/components/RoomComponents/styled/LastAudioMessage.js.map +1 -1
- package/lib/module/components/RoomComponents/styled/LastMessageFile.js +22 -3
- package/lib/module/components/RoomComponents/styled/LastMessageFile.js.map +1 -1
- package/lib/module/components/RoomComponents/styled/LastMessagePhoto.js +17 -3
- package/lib/module/components/RoomComponents/styled/LastMessagePhoto.js.map +1 -1
- package/lib/module/components/RoomComponents/styled/LastMessageVideo.js +17 -3
- package/lib/module/components/RoomComponents/styled/LastMessageVideo.js.map +1 -1
- package/lib/module/components/RoomComponents/styled/StyledRoomComponents.js +6 -0
- package/lib/module/components/RoomComponents/styled/StyledRoomComponents.js.map +1 -1
- package/lib/module/components/Thread/ThreadWrapper.js +9 -2
- package/lib/module/components/Thread/ThreadWrapper.js.map +1 -1
- package/lib/module/components/Toast/Toast.js +3 -1
- package/lib/module/components/Toast/Toast.js.map +1 -1
- package/lib/module/components/VideoCalls/VideoCallSession.js +6 -3
- package/lib/module/components/VideoCalls/VideoCallSession.js.map +1 -1
- package/lib/module/components/styled/AudioMessage.js +18 -12
- package/lib/module/components/styled/AudioMessage.js.map +1 -1
- package/lib/module/components/styled/Button.js +17 -9
- package/lib/module/components/styled/Button.js.map +1 -1
- package/lib/module/components/styled/DateLabel.js +8 -5
- package/lib/module/components/styled/DateLabel.js.map +1 -1
- package/lib/module/components/styled/MediaModal.js +29 -23
- package/lib/module/components/styled/MediaModal.js.map +1 -1
- package/lib/module/components/styled/MessageImage.js +37 -9
- package/lib/module/components/styled/MessageImage.js.map +1 -1
- package/lib/module/components/styled/RoomListComponents/index.js +62 -39
- package/lib/module/components/styled/RoomListComponents/index.js.map +1 -1
- package/lib/module/components/styled/SendInput.js +94 -20
- package/lib/module/components/styled/SendInput.js.map +1 -1
- package/lib/module/components/styled/StyledComponents.js +75 -25
- package/lib/module/components/styled/StyledComponents.js.map +1 -1
- package/lib/module/components/styled/StyledInput.js +32 -18
- package/lib/module/components/styled/StyledInput.js.map +1 -1
- package/lib/module/components/styled/StyledInputComponents/CustomTypingIndicator.js +13 -8
- package/lib/module/components/styled/StyledInputComponents/CustomTypingIndicator.js.map +1 -1
- package/lib/module/components/styled/StyledInputComponents/MediaComponents.js +20 -9
- package/lib/module/components/styled/StyledInputComponents/MediaComponents.js.map +1 -1
- package/lib/module/components/styled/StyledInputComponents/StyledInputComponents.js +50 -22
- package/lib/module/components/styled/StyledInputComponents/StyledInputComponents.js.map +1 -1
- package/lib/module/components/styled/TreadLabel.js +6 -3
- package/lib/module/components/styled/TreadLabel.js.map +1 -1
- package/lib/module/components/styled/UnsupportedType.js +14 -4
- package/lib/module/components/styled/UnsupportedType.js.map +1 -1
- package/lib/module/components/styled/VideoMessage.js +120 -62
- package/lib/module/components/styled/VideoMessage.js.map +1 -1
- package/lib/module/context/MessageNotificationContext.js +14 -3
- package/lib/module/context/MessageNotificationContext.js.map +1 -1
- package/lib/module/context/xmppProvider.js +184 -60
- package/lib/module/context/xmppProvider.js.map +1 -1
- package/lib/module/helpers/createMessageFromXml.js +19 -1
- package/lib/module/helpers/createMessageFromXml.js.map +1 -1
- package/lib/module/helpers/ensureScopedChatCache.js +2 -2
- package/lib/module/helpers/ensureScopedChatCache.js.map +1 -1
- package/lib/module/helpers/getChatBackground.js +22 -0
- package/lib/module/helpers/getChatBackground.js.map +1 -0
- package/lib/module/helpers/getDateLabelColor.js +4 -1
- package/lib/module/helpers/getDateLabelColor.js.map +1 -1
- package/lib/module/helpers/getDisplayFileName.js +73 -0
- package/lib/module/helpers/getDisplayFileName.js.map +1 -0
- package/lib/module/helpers/getIconColor.js +5 -1
- package/lib/module/helpers/getIconColor.js.map +1 -1
- package/lib/module/helpers/getSenderNameColor.js +4 -1
- package/lib/module/helpers/getSenderNameColor.js.map +1 -1
- package/lib/module/helpers/getServerReadTimestamp.js +181 -0
- package/lib/module/helpers/getServerReadTimestamp.js.map +1 -0
- package/lib/module/helpers/historyPreloadScheduler.js +66 -3
- package/lib/module/helpers/historyPreloadScheduler.js.map +1 -1
- package/lib/module/helpers/initXmppRooms.js +14 -8
- package/lib/module/helpers/initXmppRooms.js.map +1 -1
- package/lib/module/helpers/insertMessageWithDelimiter.js +52 -9
- package/lib/module/helpers/insertMessageWithDelimiter.js.map +1 -1
- package/lib/module/helpers/isOwnMessage.js +70 -0
- package/lib/module/helpers/isOwnMessage.js.map +1 -0
- package/lib/module/helpers/keyboardLayout.js +12 -2
- package/lib/module/helpers/keyboardLayout.js.map +1 -1
- package/lib/module/helpers/markdownParser.js +27 -5
- package/lib/module/helpers/markdownParser.js.map +1 -1
- package/lib/module/helpers/mediaLibraryRuntime.js +25 -0
- package/lib/module/helpers/mediaLibraryRuntime.js.map +1 -0
- package/lib/module/helpers/mimeToExtension.js +6 -13
- package/lib/module/helpers/mimeToExtension.js.map +1 -1
- package/lib/module/helpers/msgSortableMs.js +32 -0
- package/lib/module/helpers/msgSortableMs.js.map +1 -0
- package/lib/module/helpers/parseMessageBody.js +82 -24
- package/lib/module/helpers/parseMessageBody.js.map +1 -1
- package/lib/module/helpers/persistCrypto.js +115 -0
- package/lib/module/helpers/persistCrypto.js.map +1 -0
- package/lib/module/helpers/pickImageAsset.js +63 -0
- package/lib/module/helpers/pickImageAsset.js.map +1 -0
- package/lib/module/helpers/pushPayload.js +63 -0
- package/lib/module/helpers/pushPayload.js.map +1 -0
- package/lib/module/helpers/resolveInitBeforeLoadUser.js +130 -16
- package/lib/module/helpers/resolveInitBeforeLoadUser.js.map +1 -1
- package/lib/module/helpers/secureFileUrl.js +91 -0
- package/lib/module/helpers/secureFileUrl.js.map +1 -0
- package/lib/module/helpers/secureKeyValue.js +75 -0
- package/lib/module/helpers/secureKeyValue.js.map +1 -0
- package/lib/module/helpers/secureStoreRuntime.js +52 -0
- package/lib/module/helpers/secureStoreRuntime.js.map +1 -0
- package/lib/module/helpers/secureUserStorage.js +72 -0
- package/lib/module/helpers/secureUserStorage.js.map +1 -0
- package/lib/module/helpers/shallowEqual.js +31 -0
- package/lib/module/helpers/shallowEqual.js.map +1 -0
- package/lib/module/helpers/sheetGestures.js +26 -0
- package/lib/module/helpers/sheetGestures.js.map +1 -0
- package/lib/module/hooks/useChatRoomFocus.js +46 -13
- package/lib/module/hooks/useChatRoomFocus.js.map +1 -1
- package/lib/module/hooks/useChatWrapperInit.js +30 -10
- package/lib/module/hooks/useChatWrapperInit.js.map +1 -1
- package/lib/module/hooks/useComposing.js +28 -1
- package/lib/module/hooks/useComposing.js.map +1 -1
- package/lib/module/hooks/useCustomTypingIndicator.js +8 -3
- package/lib/module/hooks/useCustomTypingIndicator.js.map +1 -1
- package/lib/module/hooks/useFileToken.js +5 -0
- package/lib/module/hooks/useFileToken.js.map +1 -0
- package/lib/module/hooks/useLogout.js +33 -10
- package/lib/module/hooks/useLogout.js.map +1 -1
- package/lib/module/hooks/usePendingNotification.js +8 -11
- package/lib/module/hooks/usePendingNotification.js.map +1 -1
- package/lib/module/hooks/useSendMessage.js +52 -16
- package/lib/module/hooks/useSendMessage.js.map +1 -1
- package/lib/module/hooks/useTheme.js +30 -0
- package/lib/module/hooks/useTheme.js.map +1 -0
- package/lib/module/hooks/useUnreadMessagesCounter.js +6 -1
- package/lib/module/hooks/useUnreadMessagesCounter.js.map +1 -1
- package/lib/module/i18n/strings.js +163 -37
- package/lib/module/i18n/strings.js.map +1 -1
- package/lib/module/main.js +17 -2
- package/lib/module/main.js.map +1 -1
- package/lib/module/networking/api-requests/auth.api.js +131 -59
- package/lib/module/networking/api-requests/auth.api.js.map +1 -1
- package/lib/module/networking/api-requests/push.api.js +119 -45
- package/lib/module/networking/api-requests/push.api.js.map +1 -1
- package/lib/module/networking/api-requests/roomMembers.api.js +1 -1
- package/lib/module/networking/api-requests/roomMembers.api.js.map +1 -1
- package/lib/module/networking/api-requests/rooms.api.js +21 -9
- package/lib/module/networking/api-requests/rooms.api.js.map +1 -1
- package/lib/module/networking/api-requests/user.api.js +64 -7
- package/lib/module/networking/api-requests/user.api.js.map +1 -1
- package/lib/module/networking/apiClient.js +61 -113
- package/lib/module/networking/apiClient.js.map +1 -1
- package/lib/module/networking/authRefresh.js +321 -0
- package/lib/module/networking/authRefresh.js.map +1 -0
- package/lib/module/networking/stanzaHandlers.js +41 -28
- package/lib/module/networking/stanzaHandlers.js.map +1 -1
- package/lib/module/networking/xmpp/flushLastViewedToPrivateStore.js +46 -8
- package/lib/module/networking/xmpp/flushLastViewedToPrivateStore.js.map +1 -1
- package/lib/module/networking/xmpp/presenceInRoom.xmpp.js +8 -1
- package/lib/module/networking/xmpp/presenceInRoom.xmpp.js.map +1 -1
- package/lib/module/networking/xmpp/subscribeToRoomMessages.xmpp.js +5 -1
- package/lib/module/networking/xmpp/subscribeToRoomMessages.xmpp.js.map +1 -1
- package/lib/module/networking/xmppClient.js +124 -8
- package/lib/module/networking/xmppClient.js.map +1 -1
- package/lib/module/roomStore/chatSettingsSlice.js +26 -7
- package/lib/module/roomStore/chatSettingsSlice.js.map +1 -1
- package/lib/module/roomStore/index.js +37 -4
- package/lib/module/roomStore/index.js.map +1 -1
- package/lib/module/roomStore/persistence.js +223 -22
- package/lib/module/roomStore/persistence.js.map +1 -1
- package/lib/module/roomStore/roomsSlice.js +139 -34
- package/lib/module/roomStore/roomsSlice.js.map +1 -1
- package/lib/module/services/pushRegistration.js +239 -0
- package/lib/module/services/pushRegistration.js.map +1 -0
- package/lib/module/services/pushSubscriptionService.js +15 -37
- package/lib/module/services/pushSubscriptionService.js.map +1 -1
- package/lib/module/theme/index.js +7 -0
- package/lib/module/theme/index.js.map +1 -0
- package/lib/module/theme/styled.d.js +6 -0
- package/lib/module/theme/styled.d.js.map +1 -0
- package/lib/module/theme/theme.js +131 -0
- package/lib/module/theme/theme.js.map +1 -0
- package/lib/module/version.js +1 -1
- package/lib/typescript/assets/EmptyChatIllustration.d.ts +1 -0
- package/lib/typescript/assets/EmptyChatIllustration.d.ts.map +1 -1
- package/lib/typescript/assets/icons.d.ts +24 -0
- package/lib/typescript/assets/icons.d.ts.map +1 -1
- package/lib/typescript/components/AuthForms/Login.d.ts.map +1 -1
- package/lib/typescript/components/DropdownMenu/DropdownMenu.d.ts.map +1 -1
- package/lib/typescript/components/ExampleComponents/CustomMessage.d.ts.map +1 -1
- package/lib/typescript/components/Header/HeaderRoomList.d.ts.map +1 -1
- package/lib/typescript/components/InputComponents/Search.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/ChatHeader.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/ChatRoom.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/ChatWrapper.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/LanguageSelectorModal.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/LoginWrapper.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/MediaMessage.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/MessageContainer.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/MessageList.d.ts +10 -1
- package/lib/typescript/components/MainComponents/MessageList.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/ProfileImagePlaceholder.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/ReduxWrapper.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/RoomList.d.ts +7 -0
- package/lib/typescript/components/MainComponents/RoomList.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/Select.d.ts.map +1 -1
- package/lib/typescript/components/Menu/HeaderRoomListMenu.d.ts +3 -0
- package/lib/typescript/components/Menu/HeaderRoomListMenu.d.ts.map +1 -1
- package/lib/typescript/components/MessageBubble/BottomReplyContainer.d.ts.map +1 -1
- package/lib/typescript/components/MessageBubble/Message.d.ts.map +1 -1
- package/lib/typescript/components/MessageBubble/MessageInteractions.d.ts.map +1 -1
- package/lib/typescript/components/MessageBubble/MessageReaction.d.ts.map +1 -1
- package/lib/typescript/components/Modals/AttachSheet/AttachSheet.d.ts +9 -0
- package/lib/typescript/components/Modals/AttachSheet/AttachSheet.d.ts.map +1 -1
- package/lib/typescript/components/Modals/ChatProfileModal/ChatProfileModal.d.ts +10 -0
- package/lib/typescript/components/Modals/ChatProfileModal/ChatProfileModal.d.ts.map +1 -1
- package/lib/typescript/components/Modals/ChatProfileModal/DeleteChatModal.d.ts.map +1 -1
- package/lib/typescript/components/Modals/ChatProfileModal/ReportChatModal.d.ts +9 -0
- package/lib/typescript/components/Modals/ChatProfileModal/ReportChatModal.d.ts.map +1 -0
- package/lib/typescript/components/Modals/FilePreviewModal/FilePreviewModal.d.ts.map +1 -1
- package/lib/typescript/components/Modals/FilePreviewModal/PdfView.d.ts.map +1 -1
- package/lib/typescript/components/Modals/Modal/Modal.d.ts.map +1 -1
- package/lib/typescript/components/Modals/ModalHeaderComponent.d.ts.map +1 -1
- package/lib/typescript/components/Modals/ModalWrapper/ModalWrapper.d.ts.map +1 -1
- package/lib/typescript/components/Modals/NewChatModal/ModalContent.d.ts +4 -2
- package/lib/typescript/components/Modals/NewChatModal/ModalContent.d.ts.map +1 -1
- package/lib/typescript/components/Modals/NewChatModal/NewChatModal.d.ts +1 -1
- package/lib/typescript/components/Modals/NewChatModal/NewChatModal.d.ts.map +1 -1
- package/lib/typescript/components/Modals/NewChatModal/UpdNewChatModal.d.ts.map +1 -1
- package/lib/typescript/components/Modals/ProfileHeader/ProfileHeader.d.ts +75 -0
- package/lib/typescript/components/Modals/ProfileHeader/ProfileHeader.d.ts.map +1 -0
- package/lib/typescript/components/Modals/ProfileHeader/ProfileMenu.d.ts +25 -0
- package/lib/typescript/components/Modals/ProfileHeader/ProfileMenu.d.ts.map +1 -0
- package/lib/typescript/components/Modals/SelectUsersModal/SelectUsersModal.d.ts +6 -1
- package/lib/typescript/components/Modals/SelectUsersModal/SelectUsersModal.d.ts.map +1 -1
- package/lib/typescript/components/Modals/SettingsModals/ManageDataModal/ManageDataModal.d.ts.map +1 -1
- package/lib/typescript/components/Modals/SettingsModals/Referrals/Referrals.d.ts.map +1 -1
- package/lib/typescript/components/Modals/SettingsModals/SharedStyledComponents.d.ts +2 -2
- package/lib/typescript/components/Modals/SettingsModals/SharedStyledComponents.d.ts.map +1 -1
- package/lib/typescript/components/Modals/SettingsModals/Visibility/RadioInput.d.ts.map +1 -1
- package/lib/typescript/components/Modals/SettingsModals/Visibility/VisibilityModal.d.ts.map +1 -1
- package/lib/typescript/components/Modals/UserProfileModal/EditUserModal.d.ts.map +1 -1
- package/lib/typescript/components/Modals/UserProfileModal/UserProfileModal.d.ts +16 -0
- package/lib/typescript/components/Modals/UserProfileModal/UserProfileModal.d.ts.map +1 -1
- package/lib/typescript/components/Modals/UserSettingsModal/UserSettingsModal.d.ts +1 -0
- package/lib/typescript/components/Modals/UserSettingsModal/UserSettingsModal.d.ts.map +1 -1
- package/lib/typescript/components/Modals/styledModalComponents.d.ts +2 -0
- package/lib/typescript/components/Modals/styledModalComponents.d.ts.map +1 -1
- package/lib/typescript/components/RoomComponents/ChatRoomItem.d.ts.map +1 -1
- package/lib/typescript/components/RoomComponents/styled/LastAudioMessage.d.ts.map +1 -1
- package/lib/typescript/components/RoomComponents/styled/LastMessageFile.d.ts +1 -1
- package/lib/typescript/components/RoomComponents/styled/LastMessageFile.d.ts.map +1 -1
- package/lib/typescript/components/RoomComponents/styled/LastMessagePhoto.d.ts +1 -1
- package/lib/typescript/components/RoomComponents/styled/LastMessagePhoto.d.ts.map +1 -1
- package/lib/typescript/components/RoomComponents/styled/LastMessageVideo.d.ts +1 -1
- package/lib/typescript/components/RoomComponents/styled/LastMessageVideo.d.ts.map +1 -1
- package/lib/typescript/components/RoomComponents/styled/StyledRoomComponents.d.ts.map +1 -1
- package/lib/typescript/components/Thread/ThreadWrapper.d.ts.map +1 -1
- package/lib/typescript/components/VideoCalls/VideoCallSession.d.ts.map +1 -1
- package/lib/typescript/components/styled/AudioMessage.d.ts.map +1 -1
- package/lib/typescript/components/styled/Button.d.ts.map +1 -1
- package/lib/typescript/components/styled/DateLabel.d.ts.map +1 -1
- package/lib/typescript/components/styled/MediaModal.d.ts +2 -2
- package/lib/typescript/components/styled/MediaModal.d.ts.map +1 -1
- package/lib/typescript/components/styled/MessageImage.d.ts +14 -0
- package/lib/typescript/components/styled/MessageImage.d.ts.map +1 -1
- package/lib/typescript/components/styled/RoomListComponents/index.d.ts.map +1 -1
- package/lib/typescript/components/styled/SendInput.d.ts.map +1 -1
- package/lib/typescript/components/styled/StyledComponents.d.ts.map +1 -1
- package/lib/typescript/components/styled/StyledInput.d.ts.map +1 -1
- package/lib/typescript/components/styled/StyledInputComponents/MediaComponents.d.ts.map +1 -1
- package/lib/typescript/components/styled/StyledInputComponents/StyledInputComponents.d.ts.map +1 -1
- package/lib/typescript/components/styled/TreadLabel.d.ts.map +1 -1
- package/lib/typescript/components/styled/UnsupportedType.d.ts.map +1 -1
- package/lib/typescript/components/styled/VideoMessage.d.ts +8 -0
- package/lib/typescript/components/styled/VideoMessage.d.ts.map +1 -1
- package/lib/typescript/context/MessageNotificationContext.d.ts.map +1 -1
- package/lib/typescript/context/xmppProvider.d.ts.map +1 -1
- package/lib/typescript/helpers/createMessageFromXml.d.ts.map +1 -1
- package/lib/typescript/helpers/getAvatarColor.d.ts +1 -1
- package/lib/typescript/helpers/getChatBackground.d.ts +15 -0
- package/lib/typescript/helpers/getChatBackground.d.ts.map +1 -0
- package/lib/typescript/helpers/getDateLabelColor.d.ts +3 -7
- package/lib/typescript/helpers/getDateLabelColor.d.ts.map +1 -1
- package/lib/typescript/helpers/getDisplayFileName.d.ts +49 -0
- package/lib/typescript/helpers/getDisplayFileName.d.ts.map +1 -0
- package/lib/typescript/helpers/getIconColor.d.ts +4 -7
- package/lib/typescript/helpers/getIconColor.d.ts.map +1 -1
- package/lib/typescript/helpers/getSenderNameColor.d.ts +3 -7
- package/lib/typescript/helpers/getSenderNameColor.d.ts.map +1 -1
- package/lib/typescript/helpers/getServerReadTimestamp.d.ts +108 -0
- package/lib/typescript/helpers/getServerReadTimestamp.d.ts.map +1 -0
- package/lib/typescript/helpers/historyPreloadScheduler.d.ts.map +1 -1
- package/lib/typescript/helpers/initXmppRooms.d.ts.map +1 -1
- package/lib/typescript/helpers/insertMessageWithDelimiter.d.ts +1 -1
- package/lib/typescript/helpers/insertMessageWithDelimiter.d.ts.map +1 -1
- package/lib/typescript/helpers/isOwnMessage.d.ts +36 -0
- package/lib/typescript/helpers/isOwnMessage.d.ts.map +1 -0
- package/lib/typescript/helpers/keyboardLayout.d.ts +5 -1
- package/lib/typescript/helpers/keyboardLayout.d.ts.map +1 -1
- package/lib/typescript/helpers/markdownParser.d.ts +8 -1
- package/lib/typescript/helpers/markdownParser.d.ts.map +1 -1
- package/lib/typescript/helpers/mediaLibraryRuntime.d.ts +3 -0
- package/lib/typescript/helpers/mediaLibraryRuntime.d.ts.map +1 -0
- package/lib/typescript/helpers/mimeToExtension.d.ts +0 -15
- package/lib/typescript/helpers/mimeToExtension.d.ts.map +1 -1
- package/lib/typescript/helpers/msgSortableMs.d.ts +2 -0
- package/lib/typescript/helpers/msgSortableMs.d.ts.map +1 -0
- package/lib/typescript/helpers/parseMessageBody.d.ts +8 -1
- package/lib/typescript/helpers/parseMessageBody.d.ts.map +1 -1
- package/lib/typescript/helpers/persistCrypto.d.ts +13 -0
- package/lib/typescript/helpers/persistCrypto.d.ts.map +1 -0
- package/lib/typescript/helpers/pickImageAsset.d.ts +27 -0
- package/lib/typescript/helpers/pickImageAsset.d.ts.map +1 -0
- package/lib/typescript/helpers/pushPayload.d.ts +7 -0
- package/lib/typescript/helpers/pushPayload.d.ts.map +1 -0
- package/lib/typescript/helpers/resolveInitBeforeLoadUser.d.ts.map +1 -1
- package/lib/typescript/helpers/secureFileUrl.d.ts +7 -0
- package/lib/typescript/helpers/secureFileUrl.d.ts.map +1 -0
- package/lib/typescript/helpers/secureKeyValue.d.ts +13 -0
- package/lib/typescript/helpers/secureKeyValue.d.ts.map +1 -0
- package/lib/typescript/helpers/secureStoreRuntime.d.ts +29 -0
- package/lib/typescript/helpers/secureStoreRuntime.d.ts.map +1 -0
- package/lib/typescript/helpers/secureUserStorage.d.ts +23 -0
- package/lib/typescript/helpers/secureUserStorage.d.ts.map +1 -0
- package/lib/typescript/helpers/shallowEqual.d.ts +11 -0
- package/lib/typescript/helpers/shallowEqual.d.ts.map +1 -0
- package/lib/typescript/helpers/sheetGestures.d.ts +20 -0
- package/lib/typescript/helpers/sheetGestures.d.ts.map +1 -0
- package/lib/typescript/hooks/useChatRoomFocus.d.ts +4 -1
- package/lib/typescript/hooks/useChatRoomFocus.d.ts.map +1 -1
- package/lib/typescript/hooks/useChatWrapperInit.d.ts.map +1 -1
- package/lib/typescript/hooks/useComposing.d.ts.map +1 -1
- package/lib/typescript/hooks/useCustomTypingIndicator.d.ts +2 -0
- package/lib/typescript/hooks/useCustomTypingIndicator.d.ts.map +1 -1
- package/lib/typescript/hooks/useFileToken.d.ts +2 -0
- package/lib/typescript/hooks/useFileToken.d.ts.map +1 -0
- package/lib/typescript/hooks/useLogout.d.ts.map +1 -1
- package/lib/typescript/hooks/usePendingNotification.d.ts.map +1 -1
- package/lib/typescript/hooks/useSendMessage.d.ts.map +1 -1
- package/lib/typescript/hooks/useTheme.d.ts +16 -0
- package/lib/typescript/hooks/useTheme.d.ts.map +1 -0
- package/lib/typescript/hooks/useUnreadMessagesCounter.d.ts +1 -0
- package/lib/typescript/hooks/useUnreadMessagesCounter.d.ts.map +1 -1
- package/lib/typescript/i18n/strings.d.ts.map +1 -1
- package/lib/typescript/main.d.ts +16 -2
- package/lib/typescript/main.d.ts.map +1 -1
- package/lib/typescript/networking/api-requests/auth.api.d.ts +3 -1
- package/lib/typescript/networking/api-requests/auth.api.d.ts.map +1 -1
- package/lib/typescript/networking/api-requests/push.api.d.ts +46 -3
- package/lib/typescript/networking/api-requests/push.api.d.ts.map +1 -1
- package/lib/typescript/networking/api-requests/rooms.api.d.ts +1 -0
- package/lib/typescript/networking/api-requests/rooms.api.d.ts.map +1 -1
- package/lib/typescript/networking/api-requests/user.api.d.ts +27 -0
- package/lib/typescript/networking/api-requests/user.api.d.ts.map +1 -1
- package/lib/typescript/networking/apiClient.d.ts +12 -6
- package/lib/typescript/networking/apiClient.d.ts.map +1 -1
- package/lib/typescript/networking/authRefresh.d.ts +95 -0
- package/lib/typescript/networking/authRefresh.d.ts.map +1 -0
- package/lib/typescript/networking/stanzaHandlers.d.ts.map +1 -1
- package/lib/typescript/networking/xmpp/flushLastViewedToPrivateStore.d.ts +10 -2
- package/lib/typescript/networking/xmpp/flushLastViewedToPrivateStore.d.ts.map +1 -1
- package/lib/typescript/networking/xmpp/presenceInRoom.xmpp.d.ts.map +1 -1
- package/lib/typescript/networking/xmpp/subscribeToRoomMessages.xmpp.d.ts.map +1 -1
- package/lib/typescript/networking/xmppClient.d.ts +14 -0
- package/lib/typescript/networking/xmppClient.d.ts.map +1 -1
- package/lib/typescript/roomStore/chatSettingsSlice.d.ts +16 -0
- package/lib/typescript/roomStore/chatSettingsSlice.d.ts.map +1 -1
- package/lib/typescript/roomStore/index.d.ts.map +1 -1
- package/lib/typescript/roomStore/persistence.d.ts +18 -1
- package/lib/typescript/roomStore/persistence.d.ts.map +1 -1
- package/lib/typescript/roomStore/roomsSlice.d.ts +43 -3
- package/lib/typescript/roomStore/roomsSlice.d.ts.map +1 -1
- package/lib/typescript/services/pushRegistration.d.ts +21 -0
- package/lib/typescript/services/pushRegistration.d.ts.map +1 -0
- package/lib/typescript/services/pushSubscriptionService.d.ts +1 -5
- package/lib/typescript/services/pushSubscriptionService.d.ts.map +1 -1
- package/lib/typescript/theme/index.d.ts +5 -0
- package/lib/typescript/theme/index.d.ts.map +1 -0
- package/lib/typescript/theme/theme.d.ts +113 -0
- package/lib/typescript/theme/theme.d.ts.map +1 -0
- package/lib/typescript/types/models/room.model.d.ts +1 -0
- package/lib/typescript/types/models/room.model.d.ts.map +1 -1
- package/lib/typescript/types/types.d.ts +70 -5
- package/lib/typescript/types/types.d.ts.map +1 -1
- package/lib/typescript/version.d.ts +1 -1
- package/package.json +41 -28
- package/src/assets/EmptyChatIllustration.tsx +7 -5
- package/src/assets/icons.tsx +72 -9
- package/src/components/AuthForms/Login.tsx +14 -12
- package/src/components/ContextMenu/ContextMenuComponents.tsx +4 -4
- package/src/components/DropdownMenu/DropdownMenu.tsx +14 -6
- package/src/components/ExampleComponents/CustomMessage.tsx +9 -8
- package/src/components/ExampleComponents/CustomTypingIndicatorExamples.tsx +6 -6
- package/src/components/Header/HeaderRoomList.tsx +35 -8
- package/src/components/InputComponents/Search.tsx +7 -4
- package/src/components/MainComponents/ChatHeader.tsx +18 -6
- package/src/components/MainComponents/ChatRoom.tsx +164 -15
- package/src/components/MainComponents/ChatWrapper.tsx +44 -26
- package/src/components/MainComponents/LanguageSelectorModal.tsx +33 -7
- package/src/components/MainComponents/LoginWrapper.tsx +1 -0
- package/src/components/MainComponents/MediaMessage.tsx +63 -26
- package/src/components/MainComponents/MessageContainer.tsx +5 -1
- package/src/components/MainComponents/MessageList.tsx +36 -7
- package/src/components/MainComponents/ProfileImagePlaceholder.tsx +21 -14
- package/src/components/MainComponents/RNStyled.tsx +4 -4
- package/src/components/MainComponents/ReduxWrapper.tsx +23 -7
- package/src/components/MainComponents/RoomList.tsx +243 -40
- package/src/components/MainComponents/Select.tsx +13 -8
- package/src/components/Menu/HeaderRoomListMenu.tsx +347 -77
- package/src/components/MessageBubble/BottomReplyContainer.tsx +16 -11
- package/src/components/MessageBubble/Message.tsx +48 -25
- package/src/components/MessageBubble/MessageInteractions.tsx +17 -4
- package/src/components/MessageBubble/MessageReaction.tsx +9 -4
- package/src/components/Modals/AddMembersModal/AddMembersModal.tsx +2 -2
- package/src/components/Modals/AttachSheet/AttachSheet.tsx +376 -106
- package/src/components/Modals/ChatProfileModal/ChatProfileModal.tsx +639 -283
- package/src/components/Modals/ChatProfileModal/DeleteChatModal.tsx +6 -4
- package/src/components/Modals/ChatProfileModal/ReportChatModal.tsx +248 -0
- package/src/components/Modals/FilePreviewModal/FilePreviewModal.tsx +93 -47
- package/src/components/Modals/FilePreviewModal/PdfView.tsx +2 -1
- package/src/components/Modals/Modal/Modal.tsx +7 -0
- package/src/components/Modals/ModalHeaderComponent.tsx +9 -2
- package/src/components/Modals/ModalWrapper/ModalWrapper.tsx +14 -6
- package/src/components/Modals/NewChatModal/ModalContent.tsx +8 -5
- package/src/components/Modals/NewChatModal/NewChatModal.tsx +223 -119
- package/src/components/Modals/NewChatModal/UpdNewChatModal.tsx +12 -1
- package/src/components/Modals/ProfileHeader/ProfileHeader.tsx +624 -0
- package/src/components/Modals/ProfileHeader/ProfileMenu.tsx +224 -0
- package/src/components/Modals/SelectUsersModal/SelectUsersModal.tsx +16 -7
- package/src/components/Modals/SettingsModals/ManageDataModal/ManageDataModal.tsx +8 -6
- package/src/components/Modals/SettingsModals/Referrals/Referrals.tsx +5 -3
- package/src/components/Modals/SettingsModals/SharedStyledComponents.ts +4 -4
- package/src/components/Modals/SettingsModals/Visibility/RadioInput.tsx +9 -5
- package/src/components/Modals/SettingsModals/Visibility/VisibilityModal.tsx +7 -7
- package/src/components/Modals/UserProfileModal/EditUserModal.tsx +12 -26
- package/src/components/Modals/UserProfileModal/UserProfileModal.tsx +621 -307
- package/src/components/Modals/UserSettingsModal/UserSettingsModal.tsx +84 -58
- package/src/components/Modals/styledModalComponents.tsx +31 -16
- package/src/components/RoomComponents/ChatRoomItem.tsx +30 -6
- package/src/components/RoomComponents/styled/LastAudioMessage.tsx +4 -2
- package/src/components/RoomComponents/styled/LastMessageFile.tsx +28 -4
- package/src/components/RoomComponents/styled/LastMessagePhoto.tsx +18 -3
- package/src/components/RoomComponents/styled/LastMessageVideo.tsx +18 -3
- package/src/components/RoomComponents/styled/StyledRoomComponents.ts +2 -0
- package/src/components/Thread/ThreadWrapper.tsx +6 -5
- package/src/components/Toast/Toast.tsx +1 -1
- package/src/components/VideoCalls/VideoCallSession.tsx +8 -3
- package/src/components/styled/AudioMessage.tsx +14 -10
- package/src/components/styled/Button.tsx +15 -8
- package/src/components/styled/DateLabel.tsx +7 -3
- package/src/components/styled/MediaModal.tsx +30 -25
- package/src/components/styled/MessageImage.tsx +53 -7
- package/src/components/styled/RoomListComponents/index.tsx +60 -35
- package/src/components/styled/SendInput.tsx +106 -20
- package/src/components/styled/StyledComponents.ts +38 -25
- package/src/components/styled/StyledInput.tsx +35 -21
- package/src/components/styled/StyledInputComponents/CustomTypingIndicator.tsx +8 -8
- package/src/components/styled/StyledInputComponents/MediaComponents.tsx +20 -7
- package/src/components/styled/StyledInputComponents/StyledInputComponents.tsx +26 -23
- package/src/components/styled/TreadLabel.tsx +9 -3
- package/src/components/styled/UnsupportedType.tsx +14 -4
- package/src/components/styled/VideoMessage.tsx +131 -54
- package/src/context/MessageNotificationContext.tsx +18 -4
- package/src/context/xmppProvider.tsx +216 -57
- package/src/helpers/createMessageFromXml.ts +20 -1
- package/src/helpers/ensureScopedChatCache.ts +2 -2
- package/src/helpers/getChatBackground.ts +20 -0
- package/src/helpers/getDateLabelColor.ts +5 -3
- package/src/helpers/getDisplayFileName.ts +87 -0
- package/src/helpers/getIconColor.ts +6 -3
- package/src/helpers/getSenderNameColor.ts +5 -3
- package/src/helpers/getServerReadTimestamp.ts +197 -0
- package/src/helpers/historyPreloadScheduler.ts +80 -3
- package/src/helpers/initXmppRooms.tsx +14 -10
- package/src/helpers/insertMessageWithDelimiter.ts +55 -19
- package/src/helpers/isOwnMessage.ts +90 -0
- package/src/helpers/keyboardLayout.ts +23 -2
- package/src/helpers/markdownParser.tsx +29 -5
- package/src/helpers/mediaLibraryRuntime.ts +25 -0
- package/src/helpers/mimeToExtension.ts +6 -22
- package/src/helpers/msgSortableMs.ts +25 -0
- package/src/helpers/parseMessageBody.tsx +79 -26
- package/src/helpers/persistCrypto.ts +127 -0
- package/src/helpers/pickImageAsset.ts +68 -0
- package/src/helpers/pushPayload.ts +62 -0
- package/src/helpers/resolveInitBeforeLoadUser.ts +125 -18
- package/src/helpers/secureFileUrl.ts +103 -0
- package/src/helpers/secureKeyValue.ts +80 -0
- package/src/helpers/secureStoreRuntime.ts +62 -0
- package/src/helpers/secureUserStorage.ts +80 -0
- package/src/helpers/shallowEqual.ts +33 -0
- package/src/helpers/sheetGestures.ts +25 -0
- package/src/hooks/useChatRoomFocus.ts +49 -9
- package/src/hooks/useChatWrapperInit.ts +30 -10
- package/src/hooks/useComposing.tsx +37 -1
- package/src/hooks/useCustomTypingIndicator.tsx +7 -3
- package/src/hooks/useFileToken.ts +7 -0
- package/src/hooks/useLogout.tsx +39 -12
- package/src/hooks/usePendingNotification.ts +5 -11
- package/src/hooks/useSendMessage.tsx +60 -15
- package/src/hooks/useTheme.ts +41 -0
- package/src/hooks/useUnreadMessagesCounter.ts +11 -0
- package/src/i18n/strings.ts +163 -37
- package/src/main.ts +57 -2
- package/src/networking/api-requests/auth.api.ts +156 -48
- package/src/networking/api-requests/push.api.ts +185 -62
- package/src/networking/api-requests/roomMembers.api.ts +1 -1
- package/src/networking/api-requests/rooms.api.ts +18 -9
- package/src/networking/api-requests/user.api.ts +79 -7
- package/src/networking/apiClient.ts +68 -123
- package/src/networking/authRefresh.ts +451 -0
- package/src/networking/stanzaHandlers.ts +44 -28
- package/src/networking/xmpp/flushLastViewedToPrivateStore.ts +71 -10
- package/src/networking/xmpp/presenceInRoom.xmpp.ts +6 -1
- package/src/networking/xmpp/subscribeToRoomMessages.xmpp.ts +12 -1
- package/src/networking/xmppClient.ts +141 -9
- package/src/roomStore/chatSettingsSlice.ts +34 -10
- package/src/roomStore/index.ts +40 -4
- package/src/roomStore/persistence.ts +234 -24
- package/src/roomStore/roomsSlice.ts +161 -29
- package/src/services/pushRegistration.ts +356 -0
- package/src/services/pushSubscriptionService.ts +18 -47
- package/src/theme/index.ts +10 -0
- package/src/theme/styled.d.ts +9 -0
- package/src/theme/theme.ts +243 -0
- package/src/types/models/room.model.ts +1 -0
- package/src/types/types.ts +96 -5
- package/src/version.ts +1 -1
- package/lib/commonjs/context/PushNotificationProvider.js +0 -79
- package/lib/commonjs/context/PushNotificationProvider.js.map +0 -1
- package/lib/commonjs/hooks/usePushNotifications.js +0 -110
- package/lib/commonjs/hooks/usePushNotifications.js.map +0 -1
- package/lib/commonjs/services/pushNotifications.js +0 -143
- package/lib/commonjs/services/pushNotifications.js.map +0 -1
- package/lib/module/context/PushNotificationProvider.js +0 -79
- package/lib/module/context/PushNotificationProvider.js.map +0 -1
- package/lib/module/hooks/usePushNotifications.js +0 -106
- package/lib/module/hooks/usePushNotifications.js.map +0 -1
- package/lib/module/services/pushNotifications.js +0 -130
- package/lib/module/services/pushNotifications.js.map +0 -1
- package/lib/typescript/context/PushNotificationProvider.d.ts +0 -2
- package/lib/typescript/context/PushNotificationProvider.d.ts.map +0 -1
- package/lib/typescript/hooks/usePushNotifications.d.ts +0 -5
- package/lib/typescript/hooks/usePushNotifications.d.ts.map +0 -1
- package/lib/typescript/services/pushNotifications.d.ts +0 -10
- package/lib/typescript/services/pushNotifications.d.ts.map +0 -1
- package/src/context/PushNotificationProvider.tsx +0 -78
- package/src/hooks/usePushNotifications.ts +0 -131
- package/src/services/pushNotifications.ts +0 -170
|
@@ -4,6 +4,8 @@ import React, { useMemo } from 'react';
|
|
|
4
4
|
import { Provider, useDispatch } from 'react-redux';
|
|
5
5
|
import { KeyboardProvider } from 'react-native-keyboard-controller';
|
|
6
6
|
import { SafeAreaProvider } from 'react-native-safe-area-context';
|
|
7
|
+
import { ThemeProvider } from 'styled-components/native';
|
|
8
|
+
import { resolveTheme } from '../../theme/theme';
|
|
7
9
|
import { store } from '../../roomStore';
|
|
8
10
|
import { setConfig } from '../../roomStore/chatSettingsSlice';
|
|
9
11
|
import { XmppProvider } from '../../context/xmppProvider';
|
|
@@ -13,12 +15,19 @@ import LoginWrapper from './LoginWrapper';
|
|
|
13
15
|
import '../../helpers/storeConsole';
|
|
14
16
|
import { installPromiseRejectionTracker } from '../../utils/installPromiseRejectionTracker';
|
|
15
17
|
import { useChatFonts } from '../../hooks/useChatFonts';
|
|
18
|
+
import { installPushTokenHook } from '../../services/pushRegistration';
|
|
16
19
|
|
|
17
20
|
// Mount-time, dev-only — wire a global unhandled-promise-rejection
|
|
18
21
|
// tracker so any future leak surfaces with a real stack trace in Metro
|
|
19
22
|
// logs (bug #4 follow-up). No-op in production.
|
|
20
23
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
21
24
|
installPromiseRejectionTracker();
|
|
25
|
+
|
|
26
|
+
// Arms the push-token watcher once for the package: it runs
|
|
27
|
+
// `config.pushNotifications.getPushTokens` for every login and flushes
|
|
28
|
+
// tokens handed over through `registerPushToken` before sign-in. Cheap
|
|
29
|
+
// (one store subscription), no-op for hosts that never use push.
|
|
30
|
+
installPushTokenHook();
|
|
22
31
|
// Mirrors the web SDK's ConfigEnabler (ReduxWrapper.tsx): keeps redux's
|
|
23
32
|
// copy of the config in step with the prop. Without it setConfig is only
|
|
24
33
|
// dispatched during XMPP init, so a host changing config mid-session (the
|
|
@@ -54,15 +63,23 @@ export const ReduxWrapper = /*#__PURE__*/React.memo(({
|
|
|
54
63
|
// the Android keyboard flicker in bug #6; ChatRoom drops the matching
|
|
55
64
|
// KeyboardAvoidingView under the same flag).
|
|
56
65
|
const ownKeyboardHandling = !memoizedConfig?.disableKeyboardAvoidingView;
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
66
|
+
|
|
67
|
+
// Light/dark palette (config.dark + config.darkColors). Styled
|
|
68
|
+
// components read it via `({ theme }) => theme.surface`; plain RN
|
|
69
|
+
// styles via the `useTheme()` hook.
|
|
70
|
+
const theme = useMemo(() => resolveTheme(memoizedConfig), [memoizedConfig]);
|
|
71
|
+
const tree = /*#__PURE__*/_jsx(ThemeProvider, {
|
|
72
|
+
theme: theme,
|
|
73
|
+
children: /*#__PURE__*/_jsx(XmppProvider, {
|
|
74
|
+
config: memoizedConfig,
|
|
75
|
+
isVisible: props.isVisible,
|
|
76
|
+
children: /*#__PURE__*/_jsx(ToastProvider, {
|
|
77
|
+
children: /*#__PURE__*/_jsx(MessageNotificationProvider, {
|
|
64
78
|
config: memoizedConfig,
|
|
65
|
-
|
|
79
|
+
children: /*#__PURE__*/_jsx(LoginWrapper, {
|
|
80
|
+
config: memoizedConfig,
|
|
81
|
+
...props
|
|
82
|
+
})
|
|
66
83
|
})
|
|
67
84
|
})
|
|
68
85
|
})
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","useMemo","Provider","useDispatch","KeyboardProvider","SafeAreaProvider","store","setConfig","XmppProvider","MessageNotificationProvider","ToastProvider","LoginWrapper","installPromiseRejectionTracker","useChatFonts","jsx","_jsx","jsxs","_jsxs","ConfigEnabler","config","dispatch","useEffect","ReduxWrapper","memo","props","memoizedConfig","typography","ownKeyboardHandling","disableKeyboardAvoidingView","
|
|
1
|
+
{"version":3,"names":["React","useMemo","Provider","useDispatch","KeyboardProvider","SafeAreaProvider","ThemeProvider","resolveTheme","store","setConfig","XmppProvider","MessageNotificationProvider","ToastProvider","LoginWrapper","installPromiseRejectionTracker","useChatFonts","installPushTokenHook","jsx","_jsx","jsxs","_jsxs","ConfigEnabler","config","dispatch","useEffect","ReduxWrapper","memo","props","memoizedConfig","typography","ownKeyboardHandling","disableKeyboardAvoidingView","theme","tree","children","isVisible"],"sourceRoot":"../../../../src","sources":["components/MainComponents/ReduxWrapper.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAGC,OAAO,QAAO,OAAO;AACpC,SAAQC,QAAQ,EAAEC,WAAW,QAAO,aAAa;AACjD,SAAQC,gBAAgB,QAAO,kCAAkC;AACjE,SAAQC,gBAAgB,QAAO,gCAAgC;AAC/D,SAAQC,aAAa,QAAO,0BAA0B;AACtD,SAAQC,YAAY,QAAO,mBAAmB;AAC9C,SAAQC,KAAK,QAAO,iBAAiB;AACrC,SAAQC,SAAS,QAAO,mCAAmC;AAE3D,SAAQC,YAAY,QAAO,4BAA4B;AACvD,SAAQC,2BAA2B,QAAO,0CAA0C;AACpF,SAAQC,aAAa,QAAO,4BAA4B;AACxD,OAAOC,YAAY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,CAACR,YAAY;MAACY,MAAM,EAAEM,cAAe;MAACO,SAAS,EAAER,KAAK,CAACQ,SAAU;MAAAD,QAAA,eAC/DhB,IAAA,CAACN,aAAa;QAAAsB,QAAA,eACZhB,IAAA,CAACP,2BAA2B;UAACW,MAAM,EAAEM,cAAe;UAAAM,QAAA,eAClDhB,IAAA,CAACL,YAAY;YAACS,MAAM,EAAEM,cAAe;YAAA,GAAKD;UAAK,CAAG;QAAC,CACxB;MAAC,CACjB;IAAC,CACJ;EAAC,CACF,CAChB;EAED,oBACEP,KAAA,CAAClB,QAAQ;IAACM,KAAK,EAAEA,KAAM;IAAA0B,QAAA,gBACrBhB,IAAA,CAACG,aAAa;MAACC,MAAM,EAAEM;IAAe,CAAE,CAAC,eACzCV,IAAA,CAACb,gBAAgB;MAAA6B,QAAA,EACdJ,mBAAmB,gBAClBZ,IAAA,CAACd,gBAAgB;QAAA8B,QAAA,EAAED;MAAI,CAAmB,CAAC,GAE3CA;IACD,CACe,CAAC;EAAA,CACX,CAAC;AAEf,CACF,CAAC","ignoreList":[]}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
/** @format */
|
|
4
4
|
|
|
5
5
|
import React, { useState, useEffect, useCallback, useMemo, useRef } from 'react';
|
|
6
|
-
import { View, StyleSheet,
|
|
6
|
+
import { View, StyleSheet, Pressable, Animated } from 'react-native';
|
|
7
7
|
import { SearchInput } from '../InputComponents/Search';
|
|
8
8
|
import { BurgerMenuIcon, SearchIcon } from '../../assets/icons';
|
|
9
9
|
import ChatRoomItem from '../RoomComponents/ChatRoomItem';
|
|
@@ -13,8 +13,35 @@ import { HeaderRoomList } from '../Header/HeaderRoomList';
|
|
|
13
13
|
import { HeaderRoomListMenu } from '../Menu/HeaderRoomListMenu';
|
|
14
14
|
import { getIconColor } from '../../helpers/getIconColor';
|
|
15
15
|
import { useT } from '../../i18n/useT';
|
|
16
|
+
import { useTheme } from '../../hooks/useTheme';
|
|
16
17
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
17
18
|
const LONG_PRESS_THRESHOLD = 200;
|
|
19
|
+
// The page ground behind the room list, the search field and the header's
|
|
20
|
+
// rounded bottom corners is `theme.listBackground` (applied inline below).
|
|
21
|
+
|
|
22
|
+
/** A release that leaves the search strip in between is settled by
|
|
23
|
+
* scrolling to whichever end is nearer; this delay lets the platform tell
|
|
24
|
+
* us first whether the finger threw the list (momentum) or just let go. */
|
|
25
|
+
const SNAP_SETTLE_DELAY = 60;
|
|
26
|
+
const COLLAPSED_SCALE = 0.86;
|
|
27
|
+
const SEARCH_REST_GAP = 16;
|
|
28
|
+
export const searchRevealStyle = (scrollY, hiddenOffset) => {
|
|
29
|
+
const travel = Math.max(hiddenOffset, 1);
|
|
30
|
+
return {
|
|
31
|
+
opacity: scrollY.interpolate({
|
|
32
|
+
inputRange: [0, travel * 0.85],
|
|
33
|
+
outputRange: [1, 0],
|
|
34
|
+
extrapolate: 'clamp'
|
|
35
|
+
}),
|
|
36
|
+
transform: [{
|
|
37
|
+
scale: scrollY.interpolate({
|
|
38
|
+
inputRange: [0, travel],
|
|
39
|
+
outputRange: [1, COLLAPSED_SCALE],
|
|
40
|
+
extrapolate: 'clamp'
|
|
41
|
+
})
|
|
42
|
+
}]
|
|
43
|
+
};
|
|
44
|
+
};
|
|
18
45
|
const RoomList = ({
|
|
19
46
|
chats,
|
|
20
47
|
burgerMenu = false,
|
|
@@ -24,12 +51,16 @@ const RoomList = ({
|
|
|
24
51
|
config
|
|
25
52
|
} = useChatSettingState();
|
|
26
53
|
const t = useT();
|
|
54
|
+
const theme = useTheme();
|
|
27
55
|
const [open, setOpen] = useState(false);
|
|
28
56
|
const [searchTerm, setSearchTerm] = useState('');
|
|
29
57
|
const [isLongPress, setIsLongPress] = useState(false);
|
|
30
58
|
const [isDrawerOpen, setDrawerOpen] = useState(false);
|
|
59
|
+
const [isSearchFocused, setSearchFocused] = useState(false);
|
|
31
60
|
const pressTimer = useRef(null);
|
|
32
61
|
const containerRef = useRef(null);
|
|
62
|
+
const listRef = useRef(null);
|
|
63
|
+
const scrollY = useRef(new Animated.Value(0)).current;
|
|
33
64
|
const drawerAnimation = useRef(new Animated.Value(0)).current;
|
|
34
65
|
const overlayAnimation = useRef(new Animated.Value(0)).current;
|
|
35
66
|
const handlePressIn = useCallback(() => {
|
|
@@ -80,6 +111,108 @@ const RoomList = ({
|
|
|
80
111
|
// A listener for "blur" event (on touch outside) or "TouchableWithoutFeedback" may be used for mobile
|
|
81
112
|
}
|
|
82
113
|
}, [burgerMenu]);
|
|
114
|
+
|
|
115
|
+
// The search field is the list's own header rather than a bar pinned
|
|
116
|
+
// above it: it lives in the scrollable content, so the list opens
|
|
117
|
+
// already scrolled past it (rooms first, no search in sight) and
|
|
118
|
+
// dragging the content down brings it back with the finger — the way
|
|
119
|
+
// Telegram's chat list behaves. A pinned bar could not do this on
|
|
120
|
+
// Android, where a list sitting at offset 0 has nothing left to drag.
|
|
121
|
+
const searchBarHeight = useRef(0);
|
|
122
|
+
const [measuredBarHeight, setMeasuredBarHeight] = useState(0);
|
|
123
|
+
const listHeight = useRef(0);
|
|
124
|
+
const contentHeight = useRef(0);
|
|
125
|
+
/** The list starts hidden-search only once, and only before the user
|
|
126
|
+
* has touched it — chats arriving later must not yank the view. */
|
|
127
|
+
const didInitialHide = useRef(false);
|
|
128
|
+
const hasDragged = useRef(false);
|
|
129
|
+
const inMomentum = useRef(false);
|
|
130
|
+
const settleTimer = useRef(null);
|
|
131
|
+
|
|
132
|
+
// A search being typed in (or just focused) is never tucked away
|
|
133
|
+
// under the header, whichever way the list is then dragged.
|
|
134
|
+
const searchIsActive = useRef(false);
|
|
135
|
+
searchIsActive.current = isSearchFocused || searchTerm.length > 0;
|
|
136
|
+
|
|
137
|
+
/** How far the list can scroll — the strip can only be hidden fully
|
|
138
|
+
* when the rooms below it are tall enough to take its place. */
|
|
139
|
+
const maxOffset = () => contentHeight.current - listHeight.current;
|
|
140
|
+
const hiddenOffset = () => Math.max(searchBarHeight.current - SEARCH_REST_GAP, 0);
|
|
141
|
+
const hideSearchInitially = useCallback(() => {
|
|
142
|
+
if (didInitialHide.current || hasDragged.current) return;
|
|
143
|
+
const hidden = hiddenOffset();
|
|
144
|
+
if (!hidden || !listHeight.current || !contentHeight.current) return;
|
|
145
|
+
if (maxOffset() < hidden) return;
|
|
146
|
+
didInitialHide.current = true;
|
|
147
|
+
listRef.current?.scrollToOffset({
|
|
148
|
+
offset: hidden,
|
|
149
|
+
animated: false
|
|
150
|
+
});
|
|
151
|
+
}, []);
|
|
152
|
+
|
|
153
|
+
/** The magnet: a strip left half-way in or out settles to whichever
|
|
154
|
+
* end it is closer to. */
|
|
155
|
+
const snapSearch = useCallback(offset => {
|
|
156
|
+
const hidden = hiddenOffset();
|
|
157
|
+
if (!hidden || maxOffset() < hidden) return;
|
|
158
|
+
if (offset <= 0 || offset >= hidden) return;
|
|
159
|
+
const hide = !searchIsActive.current && offset > hidden / 2;
|
|
160
|
+
listRef.current?.scrollToOffset({
|
|
161
|
+
offset: hide ? hidden : 0,
|
|
162
|
+
animated: true
|
|
163
|
+
});
|
|
164
|
+
}, []);
|
|
165
|
+
const clearSettleTimer = () => {
|
|
166
|
+
if (settleTimer.current) {
|
|
167
|
+
clearTimeout(settleTimer.current);
|
|
168
|
+
settleTimer.current = null;
|
|
169
|
+
}
|
|
170
|
+
};
|
|
171
|
+
useEffect(() => clearSettleTimer, []);
|
|
172
|
+
const handleScroll = useMemo(() => Animated.event([{
|
|
173
|
+
nativeEvent: {
|
|
174
|
+
contentOffset: {
|
|
175
|
+
y: scrollY
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
}], {
|
|
179
|
+
useNativeDriver: true
|
|
180
|
+
}), [scrollY]);
|
|
181
|
+
const revealStyle = useMemo(() => searchRevealStyle(scrollY, Math.max(measuredBarHeight - SEARCH_REST_GAP, 0)), [scrollY, measuredBarHeight]);
|
|
182
|
+
const handleScrollBeginDrag = useCallback(() => {
|
|
183
|
+
hasDragged.current = true;
|
|
184
|
+
clearSettleTimer();
|
|
185
|
+
}, []);
|
|
186
|
+
const handleScrollEndDrag = useCallback(e => {
|
|
187
|
+
const offset = e.nativeEvent.contentOffset.y;
|
|
188
|
+
inMomentum.current = false;
|
|
189
|
+
clearSettleTimer();
|
|
190
|
+
// A flick keeps scrolling after the release; snapping now would
|
|
191
|
+
// fight it, so wait a beat and let momentum claim the gesture.
|
|
192
|
+
settleTimer.current = setTimeout(() => {
|
|
193
|
+
settleTimer.current = null;
|
|
194
|
+
if (!inMomentum.current) snapSearch(offset);
|
|
195
|
+
}, SNAP_SETTLE_DELAY);
|
|
196
|
+
}, [snapSearch]);
|
|
197
|
+
const handleMomentumBegin = useCallback(() => {
|
|
198
|
+
inMomentum.current = true;
|
|
199
|
+
clearSettleTimer();
|
|
200
|
+
}, []);
|
|
201
|
+
const handleMomentumEnd = useCallback(e => {
|
|
202
|
+
inMomentum.current = false;
|
|
203
|
+
snapSearch(e.nativeEvent.contentOffset.y);
|
|
204
|
+
}, [snapSearch]);
|
|
205
|
+
|
|
206
|
+
// Tapping the field pulls it fully into view even if it was caught
|
|
207
|
+
// half-way, so the caret never sits under the header.
|
|
208
|
+
useEffect(() => {
|
|
209
|
+
if (isSearchFocused) {
|
|
210
|
+
listRef.current?.scrollToOffset({
|
|
211
|
+
offset: 0,
|
|
212
|
+
animated: true
|
|
213
|
+
});
|
|
214
|
+
}
|
|
215
|
+
}, [isSearchFocused]);
|
|
83
216
|
const toggleDrawer = () => {
|
|
84
217
|
if (isDrawerOpen) {
|
|
85
218
|
closeDrawer();
|
|
@@ -109,6 +242,30 @@ const RoomList = ({
|
|
|
109
242
|
setDrawerOpen(false);
|
|
110
243
|
});
|
|
111
244
|
};
|
|
245
|
+
const searchHeader = /*#__PURE__*/_jsx(View, {
|
|
246
|
+
testID: "room-list-search",
|
|
247
|
+
style: styles.searchBar,
|
|
248
|
+
onLayout: e => {
|
|
249
|
+
const height = e.nativeEvent.layout.height;
|
|
250
|
+
searchBarHeight.current = height;
|
|
251
|
+
setMeasuredBarHeight(prev => prev === height ? prev : height);
|
|
252
|
+
hideSearchInitially();
|
|
253
|
+
},
|
|
254
|
+
children: /*#__PURE__*/_jsx(Animated.View, {
|
|
255
|
+
testID: "room-list-search-field",
|
|
256
|
+
style: [styles.searchField, revealStyle],
|
|
257
|
+
children: /*#__PURE__*/_jsx(SearchInput, {
|
|
258
|
+
icon: /*#__PURE__*/_jsx(SearchIcon, {
|
|
259
|
+
height: 20
|
|
260
|
+
}),
|
|
261
|
+
value: searchTerm,
|
|
262
|
+
onChangeText: handleSearchChange,
|
|
263
|
+
onFocus: () => setSearchFocused(true),
|
|
264
|
+
onBlur: () => setSearchFocused(false),
|
|
265
|
+
placeholder: t('search.placeholder')
|
|
266
|
+
})
|
|
267
|
+
})
|
|
268
|
+
});
|
|
112
269
|
return /*#__PURE__*/_jsxs(_Fragment, {
|
|
113
270
|
children: [burgerMenu && !open && /*#__PURE__*/_jsx(Button, {
|
|
114
271
|
style: {
|
|
@@ -124,43 +281,57 @@ const RoomList = ({
|
|
|
124
281
|
onPress: () => setOpen(!open)
|
|
125
282
|
}), /*#__PURE__*/_jsx(View, {
|
|
126
283
|
ref: containerRef,
|
|
127
|
-
style: [styles.container,
|
|
284
|
+
style: [styles.container, {
|
|
285
|
+
backgroundColor: theme.listBackground
|
|
286
|
+
}, config?.roomListStyles],
|
|
128
287
|
children: (open || !burgerMenu) && /*#__PURE__*/_jsx(_Fragment, {
|
|
129
288
|
children: /*#__PURE__*/_jsxs(View, {
|
|
130
289
|
style: styles.scrollContainer,
|
|
131
290
|
children: [/*#__PURE__*/_jsx(HeaderRoomList, {
|
|
132
291
|
setDrawerOpen: toggleDrawer
|
|
133
292
|
}), /*#__PURE__*/_jsx(View, {
|
|
134
|
-
style: styles.
|
|
135
|
-
children: /*#__PURE__*/_jsx(
|
|
136
|
-
|
|
137
|
-
|
|
293
|
+
style: styles.listArea,
|
|
294
|
+
children: /*#__PURE__*/_jsx(Animated.FlatList, {
|
|
295
|
+
ref: listRef,
|
|
296
|
+
data: filteredChats,
|
|
297
|
+
keyExtractor: item => item.jid,
|
|
298
|
+
ListHeaderComponent: searchHeader,
|
|
299
|
+
onLayout: e => {
|
|
300
|
+
listHeight.current = e.nativeEvent.layout.height;
|
|
301
|
+
hideSearchInitially();
|
|
302
|
+
},
|
|
303
|
+
onContentSizeChange: (_w, h) => {
|
|
304
|
+
contentHeight.current = h;
|
|
305
|
+
hideSearchInitially();
|
|
306
|
+
},
|
|
307
|
+
onScroll: handleScroll,
|
|
308
|
+
scrollEventThrottle: 16,
|
|
309
|
+
onScrollBeginDrag: handleScrollBeginDrag,
|
|
310
|
+
onScrollEndDrag: handleScrollEndDrag,
|
|
311
|
+
onMomentumScrollBegin: handleMomentumBegin,
|
|
312
|
+
onMomentumScrollEnd: handleMomentumEnd,
|
|
313
|
+
keyboardShouldPersistTaps: "handled",
|
|
314
|
+
renderItem: ({
|
|
315
|
+
item
|
|
316
|
+
}) => /*#__PURE__*/_jsx(Pressable
|
|
317
|
+
// Stable testID so e2e drivers can target a room
|
|
318
|
+
// row by its jid local-part (e.g. Main chat under
|
|
319
|
+
// app id `..._...759` → testID `room-...759`).
|
|
320
|
+
, {
|
|
321
|
+
testID: `room-${(item.jid || '').split('@')[0]}`,
|
|
322
|
+
accessibilityLabel: `room-${item.title || item.name}`,
|
|
323
|
+
onPress: () => performClick(item),
|
|
324
|
+
onPressIn: handlePressIn,
|
|
325
|
+
onPressOut: handlePressOut,
|
|
326
|
+
children: /*#__PURE__*/_jsx(ChatRoomItem, {
|
|
327
|
+
chat: item,
|
|
328
|
+
config: config
|
|
329
|
+
})
|
|
138
330
|
}),
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
331
|
+
style: [styles.chatList, {
|
|
332
|
+
backgroundColor: theme.listBackground
|
|
333
|
+
}]
|
|
142
334
|
})
|
|
143
|
-
}), /*#__PURE__*/_jsx(FlatList, {
|
|
144
|
-
data: filteredChats,
|
|
145
|
-
keyExtractor: item => item.jid,
|
|
146
|
-
renderItem: ({
|
|
147
|
-
item
|
|
148
|
-
}) => /*#__PURE__*/_jsx(Pressable
|
|
149
|
-
// Stable testID so e2e drivers can target a room
|
|
150
|
-
// row by its jid local-part (e.g. Main chat under
|
|
151
|
-
// app id `..._...759` → testID `room-...759`).
|
|
152
|
-
, {
|
|
153
|
-
testID: `room-${(item.jid || '').split('@')[0]}`,
|
|
154
|
-
accessibilityLabel: `room-${item.title || item.name}`,
|
|
155
|
-
onPress: () => performClick(item),
|
|
156
|
-
onPressIn: handlePressIn,
|
|
157
|
-
onPressOut: handlePressOut,
|
|
158
|
-
children: /*#__PURE__*/_jsx(ChatRoomItem, {
|
|
159
|
-
chat: item,
|
|
160
|
-
config: config
|
|
161
|
-
})
|
|
162
|
-
}),
|
|
163
|
-
style: styles.chatList
|
|
164
335
|
}), /*#__PURE__*/_jsx(HeaderRoomListMenu, {
|
|
165
336
|
closeDrawer: closeDrawer,
|
|
166
337
|
drawerAnimation: drawerAnimation,
|
|
@@ -181,8 +352,7 @@ const styles = StyleSheet.create({
|
|
|
181
352
|
container: {
|
|
182
353
|
width: '100%',
|
|
183
354
|
height: '100%',
|
|
184
|
-
flex: 1
|
|
185
|
-
backgroundColor: '#fff'
|
|
355
|
+
flex: 1
|
|
186
356
|
},
|
|
187
357
|
scrollContainer: {
|
|
188
358
|
flexGrow: 1
|
|
@@ -193,21 +363,26 @@ const styles = StyleSheet.create({
|
|
|
193
363
|
padding: 16,
|
|
194
364
|
justifyContent: 'space-between'
|
|
195
365
|
},
|
|
366
|
+
listArea: {
|
|
367
|
+
flex: 1
|
|
368
|
+
},
|
|
196
369
|
searchBar: {
|
|
370
|
+
paddingBottom: 4,
|
|
197
371
|
// `row` matters: SearchInputWrapper is `flex: 1` plus a fixed 44px
|
|
198
372
|
// height. In a column parent that flex resolves VERTICALLY against a
|
|
199
373
|
// parent with no height of its own and collapses the field to nothing
|
|
200
|
-
// but its magnifier. As a row it resolves to width
|
|
201
|
-
// meant back when the field was a list-header child.
|
|
374
|
+
// but its magnifier. As a row it resolves to width.
|
|
202
375
|
flexDirection: 'row',
|
|
203
376
|
paddingTop: 8,
|
|
204
|
-
|
|
205
|
-
|
|
377
|
+
backgroundColor: 'transparent'
|
|
378
|
+
},
|
|
379
|
+
searchField: {
|
|
380
|
+
flexDirection: 'row',
|
|
381
|
+
flex: 1
|
|
206
382
|
},
|
|
207
383
|
chatList: {
|
|
208
384
|
flex: 1,
|
|
209
|
-
paddingHorizontal: 16
|
|
210
|
-
backgroundColor: '#FAFAFA'
|
|
385
|
+
paddingHorizontal: 16
|
|
211
386
|
}
|
|
212
387
|
});
|
|
213
388
|
export default RoomList;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","useState","useEffect","useCallback","useMemo","useRef","View","StyleSheet","FlatList","Pressable","Animated","SearchInput","BurgerMenuIcon","SearchIcon","ChatRoomItem","useChatSettingState","Button","HeaderRoomList","HeaderRoomListMenu","getIconColor","useT","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","LONG_PRESS_THRESHOLD","RoomList","chats","burgerMenu","onRoomClick","config","t","open","setOpen","searchTerm","setSearchTerm","isLongPress","setIsLongPress","isDrawerOpen","setDrawerOpen","pressTimer","containerRef","drawerAnimation","Value","current","overlayAnimation","handlePressIn","setTimeout","handlePressOut","clearTimeout","performClick","chat","handleSearchChange","text","getLastMessage","messages","length","filteredChats","lowerCaseSearchTerm","toLowerCase","chatsMap","Map","has","result","filter","hay","title","name","includes","sort","a","b","id","Number","set","get","toggleDrawer","closeDrawer","parallel","timing","toValue","duration","useNativeDriver","start","children","style","padding","borderRadius","backgroundColor","color","unstyled","EndIcon","onPress","ref","styles","container","roomListStyles","scrollContainer","searchBar","icon","height","value","onChangeText","placeholder","data","keyExtractor","item","jid","renderItem","testID","split","accessibilityLabel","onPressIn","onPressOut","chatList","create","burgerButton","fontSize","width","flex","flexGrow","headerContainer","flexDirection","alignItems","justifyContent","paddingTop","paddingHorizontal"],"sourceRoot":"../../../../src","sources":["components/MainComponents/RoomList.tsx"],"mappings":";;AAAA;;AAEA,OAAOA,KAAK,IACVC,QAAQ,EACRC,SAAS,EACTC,WAAW,EACXC,OAAO,EACPC,MAAM,QACD,OAAO;AACd,SACEC,IAAI,EACJC,UAAU,EACVC,QAAQ,EACRC,SAAS,EACTC,QAAQ,QAGH,cAAc;AAErB,SAASC,WAAW,QAAQ,2BAA2B;AACvD,SAASC,cAAc,EAAEC,UAAU,QAAQ,oBAAoB;AAC/D,OAAOC,YAAY,MAAM,gCAAgC;AACzD,SAASC,mBAAmB,QAAQ,iCAAiC;AACrE,OAAOC,MAAM,MAAM,kBAAkB;AACrC,SAASC,cAAc,QAAQ,0BAA0B;AACzD,SAASC,kBAAkB,QAAQ,4BAA4B;AAC/D,SAASC,YAAY,QAAQ,4BAA4B;AACzD,SAASC,IAAI,QAAQ,iBAAiB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA,EAAAC,QAAA,IAAAC,SAAA;AAEvC,MAAMC,oBAAoB,GAAG,GAAG;AAQhC,MAAMC,QAAiC,GAAGA,CAAC;EACzCC,KAAK;EACLC,UAAU,GAAG,KAAK;EAClBC;AACF,CAAC,KAAK;EACJ,MAAM;IAAEC;EAAO,CAAC,GAAGjB,mBAAmB,CAAC,CAAC;EACxC,MAAMkB,CAAC,GAAGb,IAAI,CAAC,CAAC;EAEhB,MAAM,CAACc,IAAI,EAAEC,OAAO,CAAC,GAAGlC,QAAQ,CAAC,KAAK,CAAC;EACvC,MAAM,CAACmC,UAAU,EAAEC,aAAa,CAAC,GAAGpC,QAAQ,CAAC,EAAE,CAAC;EAChD,MAAM,CAACqC,WAAW,EAAEC,cAAc,CAAC,GAAGtC,QAAQ,CAAC,KAAK,CAAC;EACrD,MAAM,CAACuC,YAAY,EAAEC,aAAa,CAAC,GAAGxC,QAAQ,CAAC,KAAK,CAAC;EA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eAAe,EAAE;EACnB;AACF,CAAC,CAAC;AAEF,eAAe9D,QAAQ","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["React","useState","useEffect","useCallback","useMemo","useRef","View","StyleSheet","Pressable","Animated","SearchInput","BurgerMenuIcon","SearchIcon","ChatRoomItem","useChatSettingState","Button","HeaderRoomList","HeaderRoomListMenu","getIconColor","useT","useTheme","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","LONG_PRESS_THRESHOLD","SNAP_SETTLE_DELAY","COLLAPSED_SCALE","SEARCH_REST_GAP","searchRevealStyle","scrollY","hiddenOffset","travel","Math","max","opacity","interpolate","inputRange","outputRange","extrapolate","transform","scale","RoomList","chats","burgerMenu","onRoomClick","config","t","theme","open","setOpen","searchTerm","setSearchTerm","isLongPress","setIsLongPress","isDrawerOpen","setDrawerOpen","isSearchFocused","setSearchFocused","pressTimer","containerRef","listRef","Value","current","drawerAnimation","overlayAnimation","handlePressIn","setTimeout","handlePressOut","clearTimeout","performClick","chat","handleSearchChange","text","getLastMessage","messages","length","filteredChats","lowerCaseSearchTerm","toLowerCase","chatsMap","Map","has","result","filter","hay","title","name","includes","sort","a","b","id","Number","set","get","searchBarHeight","measuredBarHeight","setMeasuredBarHeight","listHeight","contentHeight","didInitialHide","hasDragged","inMomentum","settleTimer","searchIsActive","maxOffset","hideSearchInitially","hidden","scrollToOffset","offset","animated","snapSearch","hide","clearSettleTimer","handleScroll","event","nativeEvent","contentOffset","y","useNativeDriver","revealStyle","handleScrollBeginDrag","handleScrollEndDrag","e","handleMomentumBegin","handleMomentumEnd","toggleDrawer","closeDrawer","parallel","timing","toValue","duration","start","searchHeader","testID","style","styles","searchBar","onLayout","height","layout","prev","children","searchField","icon","value","onChangeText","onFocus","onBlur","placeholder","padding","borderRadius","backgroundColor","color","unstyled","EndIcon","onPress","ref","container","listBackground","roomListStyles","scrollContainer","listArea","FlatList","data","keyExtractor","item","jid","ListHeaderComponent","onContentSizeChange","_w","h","onScroll","scrollEventThrottle","onScrollBeginDrag","onScrollEndDrag","onMomentumScrollBegin","onMomentumScrollEnd","keyboardShouldPersistTaps","renderItem","split","accessibilityLabel","onPressIn","onPressOut","chatList","create","burgerButton","fontSize","width","flex","flexGrow","headerContainer","flexDirection","alignItems","justifyContent","paddingBottom","paddingTop","paddingHorizontal"],"sourceRoot":"../../../../src","sources":["components/MainComponents/RoomList.tsx"],"mappings":";;AAAA;;AAEA,OAAOA,KAAK,IACVC,QAAQ,EACRC,SAAS,EACTC,WAAW,EACXC,OAAO,EACPC,MAAM,QACD,OAAO;AACd,SACEC,IAAI,EACJC,UAAU,EAEVC,SAAS,EACTC,QAAQ,QAGH,cAAc;AAErB,SAASC,WAAW,QAAQ,2BAA2B;AACvD,SAASC,cAAc,EAAEC,UAAU,QAAQ,oBAAoB;AAC/D,OAAOC,YAAY,MAAM,gCAAgC;AACzD,SAASC,mBAAmB,QAAQ,iCAAiC;AACrE,OAAOC,MAAM,MAAM,kBAAkB;AACrC,SAASC,cAAc,QAAQ,0BAA0B;AACzD,SAASC,kBAAkB,QAAQ,4BAA4B;AAC/D,SAASC,YAAY,QAAQ,4BAA4B;AACzD,SAASC,IAAI,QAAQ,iBAAiB;AACtC,SAASC,QAAQ,QAAQ,sBAAsB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA,EAAAC,QAAA,IAAAC,SAAA;AAEhD,MAAMC,oBAAoB,GAAG,GAAG;AAQhC;AACA;;AAEA;AACA;AACA;AACA,MAAMC,iBAAiB,GAAG,EAAE;AAE5B,MAAMC,eAAe,GAAG,IAAI;AAE5B,MAAMC,eAAe,GAAG,EAAE;AAE1B,OAAO,MAAMC,iBAAiB,GAAGA,CAC/BC,OAAuB,EACvBC,YAAoB,KACjB;EACH,MAAMC,MAAM,GAAGC,IAAI,CAACC,GAAG,CAACH,YAAY,EAAE,CAAC,CAAC;EACxC,OAAO;IACLI,OAAO,EAAEL,OAAO,CAACM,WAAW,CAAC;MAC3BC,UA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EAAE,CAAC;IAChB;IACA;IACA;IACA;IACAH,aAAa,EAAE,KAAK;IACpBI,UAAU,EAAE,CAAC;IACb5C,eAAe,EAAE;EACnB,CAAC;EACDT,WAAW,EAAE;IACXiD,aAAa,EAAE,KAAK;IACpBH,IAAI,EAAE;EACR,CAAC;EACDL,QAAQ,EAAE;IACRK,IAAI,EAAE,CAAC;IACPQ,iBAAiB,EAAE;EACrB;AACF,CAAC,CAAC;AAEF,eAAe5J,QAAQ","ignoreList":[]}
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
import React, { useRef, useState } from 'react';
|
|
4
4
|
import styled from 'styled-components/native';
|
|
5
5
|
import { Animated, FlatList, Keyboard } from 'react-native';
|
|
6
|
+
import { useTheme } from '../../hooks/useTheme';
|
|
6
7
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
7
8
|
const SelectWrapper = styled.View`
|
|
8
9
|
position: relative;
|
|
@@ -10,20 +11,27 @@ const SelectWrapper = styled.View`
|
|
|
10
11
|
`;
|
|
11
12
|
const SelectBox = styled.TouchableOpacity`
|
|
12
13
|
border: ${({
|
|
13
|
-
borderColor
|
|
14
|
-
|
|
14
|
+
borderColor,
|
|
15
|
+
theme
|
|
16
|
+
}) => `1px solid ${borderColor || theme.border}`};
|
|
15
17
|
padding: 10px;
|
|
16
18
|
flex-direction: row;
|
|
17
19
|
justify-content: space-between;
|
|
18
20
|
align-items: center;
|
|
19
|
-
background-color:
|
|
21
|
+
background-color: ${({
|
|
22
|
+
theme
|
|
23
|
+
}) => theme.surface};
|
|
20
24
|
border-radius: 5px;
|
|
21
25
|
box-shadow: ${({
|
|
22
26
|
isOpen
|
|
23
27
|
}) => isOpen ? '0px 4px 8px rgba(0, 0, 0, 0.1)' : 'none'};
|
|
24
28
|
`;
|
|
29
|
+
|
|
30
|
+
// Light keeps its original #aaa; dark uses the palette's muted text.
|
|
25
31
|
const Placeholder = styled.Text`
|
|
26
|
-
color:
|
|
32
|
+
color: ${({
|
|
33
|
+
theme
|
|
34
|
+
}) => theme.dark ? theme.textMuted : '#aaa'};
|
|
27
35
|
`;
|
|
28
36
|
const Icon = styled(Animated.Text)`
|
|
29
37
|
margin-left: 10px;
|
|
@@ -33,9 +41,13 @@ const Dropdown = styled.View`
|
|
|
33
41
|
top: 100%;
|
|
34
42
|
left: 0;
|
|
35
43
|
right: 0;
|
|
36
|
-
background-color:
|
|
44
|
+
background-color: ${({
|
|
45
|
+
theme
|
|
46
|
+
}) => theme.surface};
|
|
37
47
|
max-height: 200px;
|
|
38
|
-
border: 1px solid
|
|
48
|
+
border: 1px solid ${({
|
|
49
|
+
theme
|
|
50
|
+
}) => theme.border};
|
|
39
51
|
border-radius: 5px;
|
|
40
52
|
z-index: 100;
|
|
41
53
|
`;
|
|
@@ -43,14 +55,21 @@ const SearchBox = styled.TextInput`
|
|
|
43
55
|
width: 100%;
|
|
44
56
|
padding: 10px;
|
|
45
57
|
border-bottom-width: 1px;
|
|
46
|
-
border-color:
|
|
58
|
+
border-color: ${({
|
|
59
|
+
theme
|
|
60
|
+
}) => theme.border};
|
|
61
|
+
color: ${({
|
|
62
|
+
theme
|
|
63
|
+
}) => theme.text};
|
|
47
64
|
box-sizing: border-box;
|
|
48
65
|
`;
|
|
49
66
|
const DropdownItem = styled.TouchableOpacity`
|
|
50
67
|
padding: 10px;
|
|
51
68
|
`;
|
|
52
69
|
const DropdownItemText = styled.Text`
|
|
53
|
-
color:
|
|
70
|
+
color: ${({
|
|
71
|
+
theme
|
|
72
|
+
}) => theme.text};
|
|
54
73
|
`;
|
|
55
74
|
const Select = ({
|
|
56
75
|
options,
|
|
@@ -59,6 +78,7 @@ const Select = ({
|
|
|
59
78
|
accentColor,
|
|
60
79
|
selectedValue = null
|
|
61
80
|
}) => {
|
|
81
|
+
const theme = useTheme();
|
|
62
82
|
const [isOpen, setIsOpen] = useState(false);
|
|
63
83
|
const [selected, setSelected] = useState(selectedValue);
|
|
64
84
|
const [searchTerm, setSearchTerm] = useState('');
|
|
@@ -104,6 +124,7 @@ const Select = ({
|
|
|
104
124
|
}), isOpen && /*#__PURE__*/_jsxs(Dropdown, {
|
|
105
125
|
children: [/*#__PURE__*/_jsx(SearchBox, {
|
|
106
126
|
placeholder: "Search...",
|
|
127
|
+
placeholderTextColor: theme.textMuted,
|
|
107
128
|
value: searchTerm,
|
|
108
129
|
onChangeText: setSearchTerm
|
|
109
130
|
}), /*#__PURE__*/_jsx(FlatList, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","useRef","useState","styled","Animated","FlatList","Keyboard","jsx","_jsx","jsxs","_jsxs","SelectWrapper","View","SelectBox","TouchableOpacity","borderColor","isOpen","Placeholder","Text","Icon","Dropdown","SearchBox","TextInput","DropdownItem","DropdownItemText","Select","options","placeholder","onSelect","accentColor","selectedValue","setIsOpen","selected","setSelected","searchTerm","setSearchTerm","rotationAnim","Value","current","toggleDropdown","prev","timing","toValue","duration","useNativeDriver","start","handleSelect","option","dismiss","filteredOptions","filter","name","toLowerCase","includes","rotateInterpolation","interpolate","inputRange","outputRange","children","onPress","style","transform","rotate","color","value","onChangeText","data","keyExtractor","item","id","renderItem","ListEmptyComponent"],"sourceRoot":"../../../../src","sources":["components/MainComponents/Select.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAeC,MAAM,EAAEC,QAAQ,QAAQ,OAAO;AAC1D,OAAOC,MAAM,MAAM,0BAA0B;AAC7C,SACEC,QAAQ,EAGRC,QAAQ,EACRC,QAAQ,QACH,cAAc;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;
|
|
1
|
+
{"version":3,"names":["React","useRef","useState","styled","Animated","FlatList","Keyboard","useTheme","jsx","_jsx","jsxs","_jsxs","SelectWrapper","View","SelectBox","TouchableOpacity","borderColor","theme","border","surface","isOpen","Placeholder","Text","dark","textMuted","Icon","Dropdown","SearchBox","TextInput","text","DropdownItem","DropdownItemText","Select","options","placeholder","onSelect","accentColor","selectedValue","setIsOpen","selected","setSelected","searchTerm","setSearchTerm","rotationAnim","Value","current","toggleDropdown","prev","timing","toValue","duration","useNativeDriver","start","handleSelect","option","dismiss","filteredOptions","filter","name","toLowerCase","includes","rotateInterpolation","interpolate","inputRange","outputRange","children","onPress","style","transform","rotate","color","placeholderTextColor","value","onChangeText","data","keyExtractor","item","id","renderItem","ListEmptyComponent"],"sourceRoot":"../../../../src","sources":["components/MainComponents/Select.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAeC,MAAM,EAAEC,QAAQ,QAAQ,OAAO;AAC1D,OAAOC,MAAM,MAAM,0BAA0B;AAC7C,SACEC,QAAQ,EAGRC,QAAQ,EACRC,QAAQ,QACH,cAAc;AAErB,SAASC,QAAQ,QAAQ,sBAAsB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAEhD,MAAMC,aAAa,GAAGT,MAAM,CAACU,IAAI;AACjC;AACA;AACA,CAAC;AAED,MAAMC,SAAS,GAAGX,MAAM,CAACY,gBAGvB;AACF,YAAY,CAAC;EAAEC,WAAW;EAAEC;AAAM,CAAC,KAC/B,aAAaD,WAAW,IAAIC,KAAK,CAACC,MAAM,EAAE;AAC9C;AACA;AACA;AACA;AACA,sBAAsB,CAAC;EAAED;AAAM,CAAC,KAAKA,KAAK,CAACE,OAAO;AAClD;AACA,gBAAgB,CAAC;EAAEC;AAAO,CAAC,KACvBA,MAAM,GAAG,gCAAgC,GAAG,MAAM;AACtD,CAAC;;AAED;AACA,MAAMC,WAAW,GAAGlB,MAAM,CAACmB,IAAI;AAC/B,WAAW,CAAC;EAAEL;AAAM,CAAC,KAAMA,KAAK,CAACM,IAAI,GAAGN,KAAK,CAACO,SAAS,GAAG,MAAO;AACjE,CAAC;AAED,MAAMC,IAAI,GAAGtB,MAAM,CAACC,QAAQ,CAACkB,IAAI,CAAC;AAClC;AACA,CAAC;AAED,MAAMI,QAAQ,GAAGvB,MAAM,CAACU,IAAI;AAC5B;AAC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