@ethora/chat-component-rn 26.10.5 → 26.10.7
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 +10 -0
- package/README.md +18 -0
- package/app.plugin.js +2 -0
- package/lib/commonjs/assets/icons.js +2 -2
- package/lib/commonjs/assets/icons.js.map +1 -1
- package/lib/commonjs/components/MainComponents/AlbumGrid.js +152 -0
- package/lib/commonjs/components/MainComponents/AlbumGrid.js.map +1 -0
- package/lib/commonjs/components/MainComponents/ChatRoom.js +2 -2
- package/lib/commonjs/components/MainComponents/ChatRoom.js.map +1 -1
- package/lib/commonjs/components/MainComponents/MediaMessage.js +199 -123
- package/lib/commonjs/components/MainComponents/MediaMessage.js.map +1 -1
- package/lib/commonjs/components/MainComponents/MediaUploadOverlay.js +109 -0
- package/lib/commonjs/components/MainComponents/MediaUploadOverlay.js.map +1 -0
- package/lib/commonjs/components/MessageBubble/MediaCaption.js +51 -0
- package/lib/commonjs/components/MessageBubble/MediaCaption.js.map +1 -0
- package/lib/commonjs/components/MessageBubble/Message.js +40 -1
- package/lib/commonjs/components/MessageBubble/Message.js.map +1 -1
- package/lib/commonjs/components/MessageBubble/MessageInteractions.js +2 -1
- package/lib/commonjs/components/MessageBubble/MessageInteractions.js.map +1 -1
- package/lib/commonjs/components/Modals/FilePreviewModal/FilePreviewModal.js +75 -0
- package/lib/commonjs/components/Modals/FilePreviewModal/FilePreviewModal.js.map +1 -1
- package/lib/commonjs/components/RoomComponents/LastMessageItem.js +20 -4
- package/lib/commonjs/components/RoomComponents/LastMessageItem.js.map +1 -1
- package/lib/commonjs/components/RoomComponents/styled/LastAudioMessage.js +3 -2
- package/lib/commonjs/components/RoomComponents/styled/LastAudioMessage.js.map +1 -1
- package/lib/commonjs/components/RoomComponents/styled/LastMessageFile.js +3 -2
- package/lib/commonjs/components/RoomComponents/styled/LastMessageFile.js.map +1 -1
- package/lib/commonjs/components/RoomComponents/styled/LastMessagePhoto.js +3 -2
- package/lib/commonjs/components/RoomComponents/styled/LastMessagePhoto.js.map +1 -1
- package/lib/commonjs/components/RoomComponents/styled/LastMessageVideo.js +3 -2
- package/lib/commonjs/components/RoomComponents/styled/LastMessageVideo.js.map +1 -1
- package/lib/commonjs/components/Thread/ThreadWrapper.js +3 -2
- package/lib/commonjs/components/Thread/ThreadWrapper.js.map +1 -1
- package/lib/commonjs/components/styled/MediaFilePreview.js +60 -47
- package/lib/commonjs/components/styled/MediaFilePreview.js.map +1 -1
- package/lib/commonjs/components/styled/MessageImage.js +16 -6
- package/lib/commonjs/components/styled/MessageImage.js.map +1 -1
- package/lib/commonjs/components/styled/SendInput.js +99 -68
- package/lib/commonjs/components/styled/SendInput.js.map +1 -1
- package/lib/commonjs/components/styled/VideoMessage.js +24 -10
- package/lib/commonjs/components/styled/VideoMessage.js.map +1 -1
- package/lib/commonjs/context/xmppProvider.js +46 -0
- package/lib/commonjs/context/xmppProvider.js.map +1 -1
- package/lib/commonjs/e2ee/fileEnvelope.js +6 -0
- package/lib/commonjs/e2ee/fileEnvelope.js.map +1 -1
- package/lib/commonjs/e2ee/sealedBody.js +32 -2
- package/lib/commonjs/e2ee/sealedBody.js.map +1 -1
- package/lib/commonjs/helpers/albumLayout.js +150 -0
- package/lib/commonjs/helpers/albumLayout.js.map +1 -0
- package/lib/commonjs/helpers/attachments.js +255 -0
- package/lib/commonjs/helpers/attachments.js.map +1 -0
- package/lib/commonjs/helpers/caption.js +214 -0
- package/lib/commonjs/helpers/caption.js.map +1 -0
- package/lib/commonjs/helpers/createMainMessageForThread.js +5 -1
- package/lib/commonjs/helpers/createMainMessageForThread.js.map +1 -1
- package/lib/commonjs/helpers/createMessageFromXml.js +19 -5
- package/lib/commonjs/helpers/createMessageFromXml.js.map +1 -1
- package/lib/commonjs/helpers/fileKind.js +40 -0
- package/lib/commonjs/helpers/fileKind.js.map +1 -0
- package/lib/commonjs/helpers/getDataFromXml.js +6 -1
- package/lib/commonjs/helpers/getDataFromXml.js.map +1 -1
- package/lib/commonjs/helpers/mapWithConcurrency.js +41 -0
- package/lib/commonjs/helpers/mapWithConcurrency.js.map +1 -0
- package/lib/commonjs/helpers/mediaLimits.js +33 -0
- package/lib/commonjs/helpers/mediaLimits.js.map +1 -0
- package/lib/commonjs/helpers/mediaSendRetry.js +64 -0
- package/lib/commonjs/helpers/mediaSendRetry.js.map +1 -0
- package/lib/commonjs/helpers/mediaWireData.js +62 -0
- package/lib/commonjs/helpers/mediaWireData.js.map +1 -0
- package/lib/commonjs/helpers/mentionSpans.js +19 -0
- package/lib/commonjs/helpers/mentionSpans.js.map +1 -0
- package/lib/commonjs/helpers/mimeToExtension.js +45 -0
- package/lib/commonjs/helpers/mimeToExtension.js.map +1 -1
- package/lib/commonjs/helpers/readReceipts.js +173 -0
- package/lib/commonjs/helpers/readReceipts.js.map +1 -0
- package/lib/commonjs/helpers/repairFilenameEncoding.js +79 -0
- package/lib/commonjs/helpers/repairFilenameEncoding.js.map +1 -0
- package/lib/commonjs/helpers/safeJson.js +18 -0
- package/lib/commonjs/helpers/safeJson.js.map +1 -0
- package/lib/commonjs/helpers/secureStoreRuntime.js +10 -1
- package/lib/commonjs/helpers/secureStoreRuntime.js.map +1 -1
- package/lib/commonjs/hooks/useSendMessage.js +384 -193
- package/lib/commonjs/hooks/useSendMessage.js.map +1 -1
- package/lib/commonjs/i18n/strings.js +96 -0
- package/lib/commonjs/i18n/strings.js.map +1 -1
- package/lib/commonjs/main.js +81 -0
- package/lib/commonjs/main.js.map +1 -1
- package/lib/commonjs/networking/api-requests/auth.api.js +62 -3
- package/lib/commonjs/networking/api-requests/auth.api.js.map +1 -1
- package/lib/commonjs/networking/api-requests/push.api.js +22 -7
- package/lib/commonjs/networking/api-requests/push.api.js.map +1 -1
- package/lib/commonjs/networking/stanzaHandlers.js +100 -3
- package/lib/commonjs/networking/stanzaHandlers.js.map +1 -1
- package/lib/commonjs/networking/xmpp/handleStanzas.xmpp.js +4 -2
- package/lib/commonjs/networking/xmpp/handleStanzas.xmpp.js.map +1 -1
- package/lib/commonjs/networking/xmpp/sendDisplayedMarker.xmpp.js +28 -0
- package/lib/commonjs/networking/xmpp/sendDisplayedMarker.xmpp.js.map +1 -0
- package/lib/commonjs/networking/xmpp/sendMediaMessage.xmpp.js +53 -2
- package/lib/commonjs/networking/xmpp/sendMediaMessage.xmpp.js.map +1 -1
- package/lib/commonjs/networking/xmpp/sendReceivedReceipt.xmpp.js +28 -0
- package/lib/commonjs/networking/xmpp/sendReceivedReceipt.xmpp.js.map +1 -0
- package/lib/commonjs/networking/xmppClient.js +64 -0
- package/lib/commonjs/networking/xmppClient.js.map +1 -1
- package/lib/commonjs/push/pushKeyStore.js +169 -0
- package/lib/commonjs/push/pushKeyStore.js.map +1 -0
- package/lib/commonjs/push/sealedBox.js +106 -0
- package/lib/commonjs/push/sealedBox.js.map +1 -0
- package/lib/commonjs/push/sealedPush.js +124 -0
- package/lib/commonjs/push/sealedPush.js.map +1 -0
- package/lib/commonjs/push/sealedPushTask.js +195 -0
- package/lib/commonjs/push/sealedPushTask.js.map +1 -0
- package/lib/commonjs/roomStore/persistence.js +78 -5
- package/lib/commonjs/roomStore/persistence.js.map +1 -1
- package/lib/commonjs/roomStore/roomHeapSlice.js +4 -0
- package/lib/commonjs/roomStore/roomHeapSlice.js.map +1 -1
- package/lib/commonjs/roomStore/roomsSlice.js +114 -1
- package/lib/commonjs/roomStore/roomsSlice.js.map +1 -1
- package/lib/commonjs/services/pushRegistration.js +12 -7
- package/lib/commonjs/services/pushRegistration.js.map +1 -1
- package/lib/commonjs/types/models/attachment.model.js +2 -0
- package/lib/commonjs/types/models/attachment.model.js.map +1 -0
- package/lib/commonjs/version.js +1 -1
- package/lib/module/assets/icons.js +1 -1
- package/lib/module/assets/icons.js.map +1 -1
- package/lib/module/components/MainComponents/AlbumGrid.js +146 -0
- package/lib/module/components/MainComponents/AlbumGrid.js.map +1 -0
- package/lib/module/components/MainComponents/ChatRoom.js +2 -2
- package/lib/module/components/MainComponents/ChatRoom.js.map +1 -1
- package/lib/module/components/MainComponents/MediaMessage.js +200 -124
- package/lib/module/components/MainComponents/MediaMessage.js.map +1 -1
- package/lib/module/components/MainComponents/MediaUploadOverlay.js +104 -0
- package/lib/module/components/MainComponents/MediaUploadOverlay.js.map +1 -0
- package/lib/module/components/MessageBubble/MediaCaption.js +46 -0
- package/lib/module/components/MessageBubble/MediaCaption.js.map +1 -0
- package/lib/module/components/MessageBubble/Message.js +44 -5
- package/lib/module/components/MessageBubble/Message.js.map +1 -1
- package/lib/module/components/MessageBubble/MessageInteractions.js +2 -1
- package/lib/module/components/MessageBubble/MessageInteractions.js.map +1 -1
- package/lib/module/components/Modals/FilePreviewModal/FilePreviewModal.js +75 -0
- package/lib/module/components/Modals/FilePreviewModal/FilePreviewModal.js.map +1 -1
- package/lib/module/components/RoomComponents/LastMessageItem.js +20 -4
- package/lib/module/components/RoomComponents/LastMessageItem.js.map +1 -1
- package/lib/module/components/RoomComponents/styled/LastAudioMessage.js +3 -2
- package/lib/module/components/RoomComponents/styled/LastAudioMessage.js.map +1 -1
- package/lib/module/components/RoomComponents/styled/LastMessageFile.js +3 -2
- package/lib/module/components/RoomComponents/styled/LastMessageFile.js.map +1 -1
- package/lib/module/components/RoomComponents/styled/LastMessagePhoto.js +3 -2
- package/lib/module/components/RoomComponents/styled/LastMessagePhoto.js.map +1 -1
- package/lib/module/components/RoomComponents/styled/LastMessageVideo.js +3 -2
- package/lib/module/components/RoomComponents/styled/LastMessageVideo.js.map +1 -1
- package/lib/module/components/Thread/ThreadWrapper.js +3 -2
- package/lib/module/components/Thread/ThreadWrapper.js.map +1 -1
- package/lib/module/components/styled/MediaFilePreview.js +61 -48
- package/lib/module/components/styled/MediaFilePreview.js.map +1 -1
- package/lib/module/components/styled/MessageImage.js +16 -6
- package/lib/module/components/styled/MessageImage.js.map +1 -1
- package/lib/module/components/styled/SendInput.js +99 -68
- package/lib/module/components/styled/SendInput.js.map +1 -1
- package/lib/module/components/styled/VideoMessage.js +24 -10
- package/lib/module/components/styled/VideoMessage.js.map +1 -1
- package/lib/module/context/xmppProvider.js +46 -0
- package/lib/module/context/xmppProvider.js.map +1 -1
- package/lib/module/e2ee/fileEnvelope.js +1 -1
- package/lib/module/e2ee/fileEnvelope.js.map +1 -1
- package/lib/module/e2ee/sealedBody.js +32 -2
- package/lib/module/e2ee/sealedBody.js.map +1 -1
- package/lib/module/helpers/albumLayout.js +143 -0
- package/lib/module/helpers/albumLayout.js.map +1 -0
- package/lib/module/helpers/attachments.js +245 -0
- package/lib/module/helpers/attachments.js.map +1 -0
- package/lib/module/helpers/caption.js +207 -0
- package/lib/module/helpers/caption.js.map +1 -0
- package/lib/module/helpers/createMainMessageForThread.js +5 -1
- package/lib/module/helpers/createMainMessageForThread.js.map +1 -1
- package/lib/module/helpers/createMessageFromXml.js +20 -6
- package/lib/module/helpers/createMessageFromXml.js.map +1 -1
- package/lib/module/helpers/fileKind.js +34 -0
- package/lib/module/helpers/fileKind.js.map +1 -0
- package/lib/module/helpers/getDataFromXml.js +6 -1
- package/lib/module/helpers/getDataFromXml.js.map +1 -1
- package/lib/module/helpers/mapWithConcurrency.js +37 -0
- package/lib/module/helpers/mapWithConcurrency.js.map +1 -0
- package/lib/module/helpers/mediaLimits.js +27 -0
- package/lib/module/helpers/mediaLimits.js.map +1 -0
- package/lib/module/helpers/mediaSendRetry.js +55 -0
- package/lib/module/helpers/mediaSendRetry.js.map +1 -0
- package/lib/module/helpers/mediaWireData.js +58 -0
- package/lib/module/helpers/mediaWireData.js.map +1 -0
- package/lib/module/helpers/mentionSpans.js +14 -0
- package/lib/module/helpers/mentionSpans.js.map +1 -0
- package/lib/module/helpers/mimeToExtension.js +43 -0
- package/lib/module/helpers/mimeToExtension.js.map +1 -1
- package/lib/module/helpers/readReceipts.js +160 -0
- package/lib/module/helpers/readReceipts.js.map +1 -0
- package/lib/module/helpers/repairFilenameEncoding.js +74 -0
- package/lib/module/helpers/repairFilenameEncoding.js.map +1 -0
- package/lib/module/helpers/safeJson.js +13 -0
- package/lib/module/helpers/safeJson.js.map +1 -0
- package/lib/module/helpers/secureStoreRuntime.js +10 -1
- package/lib/module/helpers/secureStoreRuntime.js.map +1 -1
- package/lib/module/hooks/useSendMessage.js +387 -195
- package/lib/module/hooks/useSendMessage.js.map +1 -1
- package/lib/module/i18n/strings.js +96 -0
- package/lib/module/i18n/strings.js.map +1 -1
- package/lib/module/main.js +6 -0
- package/lib/module/main.js.map +1 -1
- package/lib/module/networking/api-requests/auth.api.js +62 -3
- package/lib/module/networking/api-requests/auth.api.js.map +1 -1
- package/lib/module/networking/api-requests/push.api.js +21 -6
- package/lib/module/networking/api-requests/push.api.js.map +1 -1
- package/lib/module/networking/stanzaHandlers.js +97 -4
- package/lib/module/networking/stanzaHandlers.js.map +1 -1
- package/lib/module/networking/xmpp/handleStanzas.xmpp.js +5 -3
- package/lib/module/networking/xmpp/handleStanzas.xmpp.js.map +1 -1
- package/lib/module/networking/xmpp/sendDisplayedMarker.xmpp.js +25 -0
- package/lib/module/networking/xmpp/sendDisplayedMarker.xmpp.js.map +1 -0
- package/lib/module/networking/xmpp/sendMediaMessage.xmpp.js +53 -2
- package/lib/module/networking/xmpp/sendMediaMessage.xmpp.js.map +1 -1
- package/lib/module/networking/xmpp/sendReceivedReceipt.xmpp.js +25 -0
- package/lib/module/networking/xmpp/sendReceivedReceipt.xmpp.js.map +1 -0
- package/lib/module/networking/xmppClient.js +64 -0
- package/lib/module/networking/xmppClient.js.map +1 -1
- package/lib/module/push/pushKeyStore.js +159 -0
- package/lib/module/push/pushKeyStore.js.map +1 -0
- package/lib/module/push/sealedBox.js +97 -0
- package/lib/module/push/sealedBox.js.map +1 -0
- package/lib/module/push/sealedPush.js +117 -0
- package/lib/module/push/sealedPush.js.map +1 -0
- package/lib/module/push/sealedPushTask.js +187 -0
- package/lib/module/push/sealedPushTask.js.map +1 -0
- package/lib/module/roomStore/persistence.js +78 -5
- package/lib/module/roomStore/persistence.js.map +1 -1
- package/lib/module/roomStore/roomHeapSlice.js +4 -0
- package/lib/module/roomStore/roomHeapSlice.js.map +1 -1
- package/lib/module/roomStore/roomsSlice.js +109 -0
- package/lib/module/roomStore/roomsSlice.js.map +1 -1
- package/lib/module/services/pushRegistration.js +12 -7
- package/lib/module/services/pushRegistration.js.map +1 -1
- package/lib/module/types/models/attachment.model.js +2 -0
- package/lib/module/types/models/attachment.model.js.map +1 -0
- package/lib/module/version.js +1 -1
- package/lib/typescript/assets/icons.d.ts +6 -1
- package/lib/typescript/assets/icons.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/AlbumGrid.d.ts +21 -0
- package/lib/typescript/components/MainComponents/AlbumGrid.d.ts.map +1 -0
- package/lib/typescript/components/MainComponents/ChatRoom.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/MediaMessage.d.ts.map +1 -1
- package/lib/typescript/components/MainComponents/MediaUploadOverlay.d.ts +17 -0
- package/lib/typescript/components/MainComponents/MediaUploadOverlay.d.ts.map +1 -0
- package/lib/typescript/components/MessageBubble/MediaCaption.d.ts +12 -0
- package/lib/typescript/components/MessageBubble/MediaCaption.d.ts.map +1 -0
- 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/Modals/FilePreviewModal/FilePreviewModal.d.ts.map +1 -1
- package/lib/typescript/components/RoomComponents/LastMessageItem.d.ts.map +1 -1
- package/lib/typescript/components/RoomComponents/styled/LastAudioMessage.d.ts +2 -0
- package/lib/typescript/components/RoomComponents/styled/LastAudioMessage.d.ts.map +1 -1
- package/lib/typescript/components/RoomComponents/styled/LastMessageFile.d.ts +2 -0
- package/lib/typescript/components/RoomComponents/styled/LastMessageFile.d.ts.map +1 -1
- package/lib/typescript/components/RoomComponents/styled/LastMessagePhoto.d.ts +2 -0
- package/lib/typescript/components/RoomComponents/styled/LastMessagePhoto.d.ts.map +1 -1
- package/lib/typescript/components/RoomComponents/styled/LastMessageVideo.d.ts +2 -0
- package/lib/typescript/components/RoomComponents/styled/LastMessageVideo.d.ts.map +1 -1
- package/lib/typescript/components/Thread/ThreadWrapper.d.ts.map +1 -1
- package/lib/typescript/components/styled/MediaFilePreview.d.ts.map +1 -1
- package/lib/typescript/components/styled/MessageImage.d.ts +10 -0
- package/lib/typescript/components/styled/MessageImage.d.ts.map +1 -1
- package/lib/typescript/components/styled/SendInput.d.ts +7 -1
- package/lib/typescript/components/styled/SendInput.d.ts.map +1 -1
- package/lib/typescript/components/styled/VideoMessage.d.ts +7 -0
- package/lib/typescript/components/styled/VideoMessage.d.ts.map +1 -1
- package/lib/typescript/context/xmppProvider.d.ts.map +1 -1
- package/lib/typescript/e2ee/fileEnvelope.d.ts +1 -1
- package/lib/typescript/e2ee/fileEnvelope.d.ts.map +1 -1
- package/lib/typescript/e2ee/sealedBody.d.ts +16 -0
- package/lib/typescript/e2ee/sealedBody.d.ts.map +1 -1
- package/lib/typescript/helpers/albumLayout.d.ts +66 -0
- package/lib/typescript/helpers/albumLayout.d.ts.map +1 -0
- package/lib/typescript/helpers/attachments.d.ts +55 -0
- package/lib/typescript/helpers/attachments.d.ts.map +1 -0
- package/lib/typescript/helpers/caption.d.ts +64 -0
- package/lib/typescript/helpers/caption.d.ts.map +1 -0
- package/lib/typescript/helpers/createMainMessageForThread.d.ts.map +1 -1
- package/lib/typescript/helpers/createMessageFromXml.d.ts.map +1 -1
- package/lib/typescript/helpers/fileKind.d.ts +20 -0
- package/lib/typescript/helpers/fileKind.d.ts.map +1 -0
- package/lib/typescript/helpers/getDataFromXml.d.ts.map +1 -1
- package/lib/typescript/helpers/mapWithConcurrency.d.ts +9 -0
- package/lib/typescript/helpers/mapWithConcurrency.d.ts.map +1 -0
- package/lib/typescript/helpers/mediaLimits.d.ts +13 -0
- package/lib/typescript/helpers/mediaLimits.d.ts.map +1 -0
- package/lib/typescript/helpers/mediaSendRetry.d.ts +26 -0
- package/lib/typescript/helpers/mediaSendRetry.d.ts.map +1 -0
- package/lib/typescript/helpers/mediaWireData.d.ts +16 -0
- package/lib/typescript/helpers/mediaWireData.d.ts.map +1 -0
- package/lib/typescript/helpers/mentionSpans.d.ts +8 -0
- package/lib/typescript/helpers/mentionSpans.d.ts.map +1 -0
- package/lib/typescript/helpers/mimeToExtension.d.ts +7 -0
- package/lib/typescript/helpers/mimeToExtension.d.ts.map +1 -1
- package/lib/typescript/helpers/readReceipts.d.ts +82 -0
- package/lib/typescript/helpers/readReceipts.d.ts.map +1 -0
- package/lib/typescript/helpers/repairFilenameEncoding.d.ts +12 -0
- package/lib/typescript/helpers/repairFilenameEncoding.d.ts.map +1 -0
- package/lib/typescript/helpers/safeJson.d.ts +2 -0
- package/lib/typescript/helpers/safeJson.d.ts.map +1 -0
- package/lib/typescript/helpers/secureStoreRuntime.d.ts +17 -3
- package/lib/typescript/helpers/secureStoreRuntime.d.ts.map +1 -1
- package/lib/typescript/hooks/useSendMessage.d.ts +2 -1
- package/lib/typescript/hooks/useSendMessage.d.ts.map +1 -1
- package/lib/typescript/i18n/strings.d.ts.map +1 -1
- package/lib/typescript/main.d.ts +6 -0
- package/lib/typescript/main.d.ts.map +1 -1
- package/lib/typescript/networking/api-requests/auth.api.d.ts +2 -0
- package/lib/typescript/networking/api-requests/auth.api.d.ts.map +1 -1
- package/lib/typescript/networking/api-requests/push.api.d.ts +14 -2
- package/lib/typescript/networking/api-requests/push.api.d.ts.map +1 -1
- package/lib/typescript/networking/stanzaHandlers.d.ts +7 -3
- package/lib/typescript/networking/stanzaHandlers.d.ts.map +1 -1
- package/lib/typescript/networking/xmpp/handleStanzas.xmpp.d.ts.map +1 -1
- package/lib/typescript/networking/xmpp/sendDisplayedMarker.xmpp.d.ts +3 -0
- package/lib/typescript/networking/xmpp/sendDisplayedMarker.xmpp.d.ts.map +1 -0
- package/lib/typescript/networking/xmpp/sendMediaMessage.xmpp.d.ts +12 -0
- package/lib/typescript/networking/xmpp/sendMediaMessage.xmpp.d.ts.map +1 -1
- package/lib/typescript/networking/xmpp/sendReceivedReceipt.xmpp.d.ts +3 -0
- package/lib/typescript/networking/xmpp/sendReceivedReceipt.xmpp.d.ts.map +1 -0
- package/lib/typescript/networking/xmppClient.d.ts +15 -0
- package/lib/typescript/networking/xmppClient.d.ts.map +1 -1
- package/lib/typescript/push/pushKeyStore.d.ts +35 -0
- package/lib/typescript/push/pushKeyStore.d.ts.map +1 -0
- package/lib/typescript/push/sealedBox.d.ts +24 -0
- package/lib/typescript/push/sealedBox.d.ts.map +1 -0
- package/lib/typescript/push/sealedPush.d.ts +61 -0
- package/lib/typescript/push/sealedPush.d.ts.map +1 -0
- package/lib/typescript/push/sealedPushTask.d.ts +33 -0
- package/lib/typescript/push/sealedPushTask.d.ts.map +1 -0
- package/lib/typescript/roomStore/persistence.d.ts.map +1 -1
- package/lib/typescript/roomStore/roomHeapSlice.d.ts +22 -1
- package/lib/typescript/roomStore/roomHeapSlice.d.ts.map +1 -1
- package/lib/typescript/roomStore/roomsSlice.d.ts +67 -3
- package/lib/typescript/roomStore/roomsSlice.d.ts.map +1 -1
- package/lib/typescript/services/pushRegistration.d.ts +8 -0
- package/lib/typescript/services/pushRegistration.d.ts.map +1 -1
- package/lib/typescript/types/models/attachment.model.d.ts +52 -0
- package/lib/typescript/types/models/attachment.model.d.ts.map +1 -0
- package/lib/typescript/types/models/message.model.d.ts +26 -0
- package/lib/typescript/types/models/message.model.d.ts.map +1 -1
- package/lib/typescript/types/models/modal.model.d.ts +7 -0
- package/lib/typescript/types/models/modal.model.d.ts.map +1 -1
- package/lib/typescript/types/models/room.model.d.ts +2 -0
- package/lib/typescript/types/models/room.model.d.ts.map +1 -1
- package/lib/typescript/types/types.d.ts +35 -1
- package/lib/typescript/types/types.d.ts.map +1 -1
- package/lib/typescript/version.d.ts +1 -1
- package/package.json +14 -1
- package/plugins/notification-service/Info.plist +31 -0
- package/plugins/notification-service/NotificationService.swift +195 -0
- package/plugins/notification-service/SealedBox.swift +355 -0
- package/plugins/notification-service/check/gen-vectors.mjs +24 -0
- package/plugins/notification-service/check/main.swift +37 -0
- package/plugins/notification-service/check/run.sh +12 -0
- package/plugins/notification-service/check/vectors.json +1 -0
- package/plugins/withNotificationServiceExtension.js +189 -0
- package/src/assets/icons.tsx +20 -2
- package/src/components/MainComponents/AlbumGrid.tsx +183 -0
- package/src/components/MainComponents/ChatRoom.tsx +4 -2
- package/src/components/MainComponents/MediaMessage.tsx +246 -130
- package/src/components/MainComponents/MediaUploadOverlay.tsx +102 -0
- package/src/components/MessageBubble/MediaCaption.tsx +45 -0
- package/src/components/MessageBubble/Message.tsx +71 -3
- package/src/components/MessageBubble/MessageInteractions.tsx +2 -1
- package/src/components/Modals/FilePreviewModal/FilePreviewModal.tsx +64 -0
- package/src/components/RoomComponents/LastMessageItem.tsx +15 -4
- package/src/components/RoomComponents/styled/LastAudioMessage.tsx +6 -3
- package/src/components/RoomComponents/styled/LastMessageFile.tsx +6 -2
- package/src/components/RoomComponents/styled/LastMessagePhoto.tsx +6 -2
- package/src/components/RoomComponents/styled/LastMessageVideo.tsx +6 -2
- package/src/components/Thread/ThreadWrapper.tsx +5 -9
- package/src/components/styled/MediaFilePreview.tsx +49 -34
- package/src/components/styled/MessageImage.tsx +21 -5
- package/src/components/styled/SendInput.tsx +101 -87
- package/src/components/styled/VideoMessage.tsx +34 -9
- package/src/context/xmppProvider.tsx +32 -0
- package/src/e2ee/fileEnvelope.ts +1 -1
- package/src/e2ee/sealedBody.ts +44 -5
- package/src/helpers/albumLayout.ts +207 -0
- package/src/helpers/attachments.ts +316 -0
- package/src/helpers/caption.ts +283 -0
- package/src/helpers/createMainMessageForThread.ts +6 -1
- package/src/helpers/createMessageFromXml.ts +21 -5
- package/src/helpers/fileKind.ts +38 -0
- package/src/helpers/getDataFromXml.ts +5 -1
- package/src/helpers/mapWithConcurrency.ts +32 -0
- package/src/helpers/mediaLimits.ts +27 -0
- package/src/helpers/mediaSendRetry.ts +59 -0
- package/src/helpers/mediaWireData.ts +57 -0
- package/src/helpers/mentionSpans.ts +17 -0
- package/src/helpers/mimeToExtension.ts +51 -0
- package/src/helpers/readReceipts.ts +219 -0
- package/src/helpers/repairFilenameEncoding.ts +82 -0
- package/src/helpers/safeJson.ts +11 -0
- package/src/helpers/secureStoreRuntime.ts +21 -3
- package/src/hooks/useSendMessage.tsx +448 -249
- package/src/i18n/strings.ts +96 -0
- package/src/main.ts +30 -0
- package/src/networking/api-requests/auth.api.ts +60 -3
- package/src/networking/api-requests/push.api.ts +29 -4
- package/src/networking/stanzaHandlers.ts +91 -2
- package/src/networking/xmpp/handleStanzas.xmpp.ts +6 -2
- package/src/networking/xmpp/sendDisplayedMarker.xmpp.ts +31 -0
- package/src/networking/xmpp/sendMediaMessage.xmpp.ts +60 -3
- package/src/networking/xmpp/sendReceivedReceipt.xmpp.ts +31 -0
- package/src/networking/xmppClient.ts +48 -0
- package/src/push/pushKeyStore.ts +163 -0
- package/src/push/sealedBox.ts +104 -0
- package/src/push/sealedPush.ts +127 -0
- package/src/push/sealedPushTask.ts +175 -0
- package/src/roomStore/persistence.ts +94 -3
- package/src/roomStore/roomHeapSlice.ts +23 -1
- package/src/roomStore/roomsSlice.ts +112 -1
- package/src/services/pushRegistration.ts +25 -5
- package/src/types/models/attachment.model.ts +51 -0
- package/src/types/models/message.model.ts +29 -0
- package/src/types/models/modal.model.ts +7 -0
- package/src/types/models/room.model.ts +2 -0
- package/src/types/types.ts +41 -1
- package/src/version.ts +1 -1
|
@@ -93,6 +93,8 @@ export declare class XmppClient {
|
|
|
93
93
|
set priorityPresencesReady(value: boolean);
|
|
94
94
|
disableLastRead: boolean;
|
|
95
95
|
private activeRoomJID;
|
|
96
|
+
private receiptAckedIds;
|
|
97
|
+
private lastWatermarkSentByRoom;
|
|
96
98
|
private activeRoomBoostUntil;
|
|
97
99
|
private softPauseUntil;
|
|
98
100
|
private mamInFlightByRoom;
|
|
@@ -281,6 +283,19 @@ export declare class XmppClient {
|
|
|
281
283
|
sendMediaMessageStanza(roomJID: string, data: any, customId?: string): string | undefined;
|
|
282
284
|
setVCardStanza(_xmppUsername: string): void;
|
|
283
285
|
createPrivateRoomStanza(title: string, description: string, to: string): Promise<string>;
|
|
286
|
+
/**
|
|
287
|
+
* XEP-0184 delivery receipt for a message from someone else. Sent for live
|
|
288
|
+
* messages and for messages a MAM page brings in; a message already acked
|
|
289
|
+
* is skipped. When the stream is down (or `config.disableReadReceipts` is
|
|
290
|
+
* on) nothing is recorded, so a later page can still ack it.
|
|
291
|
+
*/
|
|
292
|
+
sendReceivedReceiptStanza(messageId: string, roomJid: string): void;
|
|
293
|
+
/**
|
|
294
|
+
* XEP-0333 read watermark for a room: the newest message the user has
|
|
295
|
+
* displayed. Off with `disableLastRead` or `config.disableReadReceipts`.
|
|
296
|
+
* The caller decides when the room counts as read (see computeReadWatermark).
|
|
297
|
+
*/
|
|
298
|
+
sendDisplayedMarkerStanza(messageId: string, roomJid: string): void;
|
|
284
299
|
sendMessageReactionStanza(messageId: string, roomJid: string, reactionsList: string[], data?: {
|
|
285
300
|
firstName?: string;
|
|
286
301
|
lastName?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"xmppClient.d.ts","sourceRoot":"","sources":["../../../src/networking/xmppClient.ts"],"names":[],"mappings":"AAAA,OAAa,EAAE,MAAM,EAAO,MAAM,cAAc,CAAC;AAEjD,OAAO,EAAE,QAAQ,EAAE,qBAAqB,EAAE,MAAM,gBAAgB,CAAC;AAQjE,OAAO,EAIL,WAAW,EACX,iBAAiB,EAClB,MAAM,wBAAwB,CAAC;
|
|
1
|
+
{"version":3,"file":"xmppClient.d.ts","sourceRoot":"","sources":["../../../src/networking/xmppClient.ts"],"names":[],"mappings":"AAAA,OAAa,EAAE,MAAM,EAAO,MAAM,cAAc,CAAC;AAEjD,OAAO,EAAE,QAAQ,EAAE,qBAAqB,EAAE,MAAM,gBAAgB,CAAC;AAQjE,OAAO,EAIL,WAAW,EACX,iBAAiB,EAClB,MAAM,w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AE,MAAM,CAAC;QAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;KAAE;IAkBlD,qCAAqC,CACnC,OAAO,EAAE,MAAM,EACf,SAAS,EAAE,MAAM,EACjB,QAAQ,EAAE,MAAM,EAChB,KAAK,EAAE,MAAM,EACb,aAAa,EAAE,MAAM,EACrB,WAAW,EAAE,MAAM,EACnB,iBAAiB,CAAC,EAAE,MAAM,EAC1B,OAAO,CAAC,EAAE,OAAO,EACjB,aAAa,CAAC,EAAE,OAAO,EACvB,WAAW,CAAC,EAAE,MAAM,EACpB,UAAU,CAAC,EAAE,MAAM,EACnB,QAAQ,CAAC,EAAE,MAAM,GAChB,OAAO;CA6CX;AAED,eAAe,UAAU,CAAC"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import type { SealedPushKey } from './sealedPush';
|
|
2
|
+
export declare const PUSH_KEY_KEYCHAIN_SERVICE = "ethora.push";
|
|
3
|
+
export declare const PUSH_SECRET_KEY_ITEM = "ethora_push_secret_key";
|
|
4
|
+
export declare const PUSH_PUBLIC_KEY_ITEM = "ethora_push_public_key";
|
|
5
|
+
export interface PushKeyPair {
|
|
6
|
+
/** Base64 of the raw 32-byte X25519 public key — the `pushKey` of the registration. */
|
|
7
|
+
publicKey: string;
|
|
8
|
+
/** The `pushKeyId` the service derives for it, for logs and the kid check. */
|
|
9
|
+
keyId: string;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* The stored pair, or null when there is none (or it is unreadable).
|
|
13
|
+
* The public key is re-derived from the secret, so the pair is consistent
|
|
14
|
+
* even if only the secret item survived.
|
|
15
|
+
*/
|
|
16
|
+
export declare function loadPushSecretKey(): Promise<SealedPushKey | null>;
|
|
17
|
+
/** The public half of the stored pair, null when the device has no key. */
|
|
18
|
+
export declare function getPushKeyPair(): Promise<PushKeyPair | null>;
|
|
19
|
+
/**
|
|
20
|
+
* Generate and store a new pair, replacing any existing one. Pushes sealed
|
|
21
|
+
* for the old key stop opening at once, so re-register the token with the
|
|
22
|
+
* new `publicKey` right after. Null when expo-secure-store is missing or
|
|
23
|
+
* the keychain refused the write.
|
|
24
|
+
*/
|
|
25
|
+
export declare function resetPushKeyPair(): Promise<PushKeyPair | null>;
|
|
26
|
+
/**
|
|
27
|
+
* The device key for encrypted pushes, created on first call. Hand
|
|
28
|
+
* `publicKey` to `registerPushToken` (or send it as `pushKey` yourself).
|
|
29
|
+
*/
|
|
30
|
+
export declare function ensurePushKeyPair(): Promise<PushKeyPair | null>;
|
|
31
|
+
/** Remove the pair; the next `ensurePushKeyPair` creates a new one. */
|
|
32
|
+
export declare function clearPushKeyPair(): Promise<void>;
|
|
33
|
+
/** Test seam only. */
|
|
34
|
+
export declare const __resetPushKeyStoreForTests: () => void;
|
|
35
|
+
//# sourceMappingURL=pushKeyStore.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pushKeyStore.d.ts","sourceRoot":"","sources":["../../../src/push/pushKeyStore.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAmBlD,eAAO,MAAM,yBAAyB,gBAAgB,CAAC;AACvD,eAAO,MAAM,oBAAoB,2BAA2B,CAAC;AAC7D,eAAO,MAAM,oBAAoB,2BAA2B,CAAC;AAE7D,MAAM,WAAW,WAAW;IAC1B,uFAAuF;IACvF,SAAS,EAAE,MAAM,CAAC;IAClB,8EAA8E;IAC9E,KAAK,EAAE,MAAM,CAAC;CACf;AA6CD;;;;GAIG;AACH,wBAAsB,iBAAiB,IAAI,OAAO,CAAC,aAAa,GAAG,IAAI,CAAC,CAKvE;AAOD,2EAA2E;AAC3E,wBAAsB,cAAc,IAAI,OAAO,CAAC,WAAW,GAAG,IAAI,CAAC,CAGlE;AAED;;;;;GAKG;AACH,wBAAsB,gBAAgB,IAAI,OAAO,CAAC,WAAW,GAAG,IAAI,CAAC,CAsBpE;AAED;;;GAGG;AACH,wBAAsB,iBAAiB,IAAI,OAAO,CAAC,WAAW,GAAG,IAAI,CAAC,CAGrE;AAED,uEAAuE;AACvE,wBAAsB,gBAAgB,IAAI,OAAO,CAAC,IAAI,CAAC,CAWtD;AAED,sBAAsB;AACtB,eAAO,MAAM,2BAA2B,QAAO,IAE9C,CAAC"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export declare const SEALED_BOX_PUBLIC_KEY_BYTES = 32;
|
|
2
|
+
export declare const SEALED_BOX_SECRET_KEY_BYTES = 32;
|
|
3
|
+
/** Ephemeral public key (32) + Poly1305 tag (16). */
|
|
4
|
+
export declare const SEALED_BOX_OVERHEAD_BYTES = 48;
|
|
5
|
+
export interface SealedBoxKeyPair {
|
|
6
|
+
publicKey: Uint8Array;
|
|
7
|
+
secretKey: Uint8Array;
|
|
8
|
+
}
|
|
9
|
+
export declare const generateSealedBoxKeyPair: () => SealedBoxKeyPair;
|
|
10
|
+
export declare const sealedBoxPublicKeyOf: (secretKey: Uint8Array) => Uint8Array;
|
|
11
|
+
/**
|
|
12
|
+
* The key id the push service derives when the registration carries none:
|
|
13
|
+
* the first 16 hex characters of SHA-256 over the raw public key. Sent back
|
|
14
|
+
* as `kid` in every sealed push.
|
|
15
|
+
*/
|
|
16
|
+
export declare const sealedBoxKeyId: (publicKey: Uint8Array) => string;
|
|
17
|
+
/** `crypto_box_seal`: used by the tests and the key tool, not by the app. */
|
|
18
|
+
export declare function sealedBoxSeal(message: Uint8Array, recipientPublicKey: Uint8Array): Uint8Array;
|
|
19
|
+
/**
|
|
20
|
+
* `crypto_box_seal_open`. Returns null for anything that does not open:
|
|
21
|
+
* a wrong key, a box for another key, a damaged or truncated box.
|
|
22
|
+
*/
|
|
23
|
+
export declare function sealedBoxOpen(sealed: Uint8Array, publicKey: Uint8Array, secretKey: Uint8Array): Uint8Array | null;
|
|
24
|
+
//# sourceMappingURL=sealedBox.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sealedBox.d.ts","sourceRoot":"","sources":["../../../src/push/sealedBox.ts"],"names":[],"mappings":"AAoBA,eAAO,MAAM,2BAA2B,KAAK,CAAC;AAC9C,eAAO,MAAM,2BAA2B,KAAK,CAAC;AAC9C,qDAAqD;AACrD,eAAO,MAAM,yBAAyB,KAAK,CAAC;AAM5C,MAAM,WAAW,gBAAgB;IAC/B,SAAS,EAAE,UAAU,CAAC;IACtB,SAAS,EAAE,UAAU,CAAC;CACvB;AAED,eAAO,MAAM,wBAAwB,QAAO,gBAG3C,CAAC;AAEF,eAAO,MAAM,oBAAoB,GAAI,WAAW,UAAU,KAAG,UAC7B,CAAC;AAEjC;;;;GAIG;AACH,eAAO,MAAM,cAAc,GAAI,WAAW,UAAU,KAAG,MACX,CAAC;AAc7C,6EAA6E;AAC7E,wBAAgB,aAAa,CAAC,OAAO,EAAE,UAAU,EAAE,kBAAkB,EAAE,UAAU,GAAG,UAAU,CAU7F;AAED;;;GAGG;AACH,wBAAgB,aAAa,CAC3B,MAAM,EAAE,UAAU,EAClB,SAAS,EAAE,UAAU,EACrB,SAAS,EAAE,UAAU,GACpB,UAAU,GAAG,IAAI,CAoBnB"}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
export declare const SEALED_PUSH_ALG = "sealed-box-x25519";
|
|
2
|
+
export declare const SEALED_PUSH_VERSION = "1";
|
|
3
|
+
export interface SealedPushEnvelope {
|
|
4
|
+
v: string;
|
|
5
|
+
alg: string;
|
|
6
|
+
/** Id of the key the box was sealed for. */
|
|
7
|
+
kid: string;
|
|
8
|
+
/** Room JID. */
|
|
9
|
+
jid: string;
|
|
10
|
+
msgID: string;
|
|
11
|
+
/** Recipient. */
|
|
12
|
+
userJid: string;
|
|
13
|
+
/** Base64 of the sealed box; absent when the service could not seal. */
|
|
14
|
+
enc?: string;
|
|
15
|
+
}
|
|
16
|
+
/** What the box holds: the notification the service would have sent in the clear. */
|
|
17
|
+
export interface SealedPushContent {
|
|
18
|
+
title: string;
|
|
19
|
+
body: string;
|
|
20
|
+
sender: string;
|
|
21
|
+
senderJid: string;
|
|
22
|
+
chat: string;
|
|
23
|
+
chatJid: string;
|
|
24
|
+
msgID: string;
|
|
25
|
+
/** Sender avatar URL, '' when none. */
|
|
26
|
+
image: string;
|
|
27
|
+
}
|
|
28
|
+
export type SealedPushFailure =
|
|
29
|
+
/** No key on this device (never generated, or the store is not readable). */
|
|
30
|
+
'no-key'
|
|
31
|
+
/** Sealed for another key — the app was reinstalled or the key rotated after registration. */
|
|
32
|
+
| 'key-mismatch'
|
|
33
|
+
/** The service sent ids only (it could not seal). */
|
|
34
|
+
| 'no-ciphertext'
|
|
35
|
+
/** Not a box for our key, or damaged. */
|
|
36
|
+
| 'bad-ciphertext'
|
|
37
|
+
/** Opened, but the plaintext is not the expected JSON. */
|
|
38
|
+
| 'bad-content';
|
|
39
|
+
export type OpenSealedPushResult = {
|
|
40
|
+
ok: true;
|
|
41
|
+
content: SealedPushContent;
|
|
42
|
+
envelope: SealedPushEnvelope;
|
|
43
|
+
} | {
|
|
44
|
+
ok: false;
|
|
45
|
+
reason: SealedPushFailure;
|
|
46
|
+
envelope: SealedPushEnvelope;
|
|
47
|
+
};
|
|
48
|
+
/** The envelope of `data` when it is a sealed chat push, else null. */
|
|
49
|
+
export declare const sealedPushEnvelopeOf: (data: Record<string, unknown> | null | undefined) => SealedPushEnvelope | null;
|
|
50
|
+
export declare const isSealedPush: (data: Record<string, unknown> | null | undefined) => boolean;
|
|
51
|
+
export interface SealedPushKey {
|
|
52
|
+
publicKey: Uint8Array;
|
|
53
|
+
secretKey: Uint8Array;
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Open a sealed push with the device key. `key` null means there is no key
|
|
57
|
+
* on this device. Never throws: every failure names why, so the caller can
|
|
58
|
+
* show the placeholder and log the reason.
|
|
59
|
+
*/
|
|
60
|
+
export declare function openSealedPush(envelope: SealedPushEnvelope, key: SealedPushKey | null): OpenSealedPushResult;
|
|
61
|
+
//# sourceMappingURL=sealedPush.d.ts.map
|
|
@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,oBAAoB,GAC/B,MAAM,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,SAAS,KAC/C,kBAAkB,GAAG,IAYvB,CAAC;AAEF,eAAO,MAAM,YAAY,GAAI,MAAM,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,SAAS,KAAG,OAC3C,CAAC;AAqBtC,MAAM,WAAW,aAAa;IAC5B,SAAS,EAAE,UAAU,CAAC;IACtB,SAAS,EAAE,UAAU,CAAC;CACvB;AAED;;;;GAIG;AACH,wBAAgB,cAAc,CAC5B,QAAQ,EAAE,kBAAkB,EAC5B,GAAG,EAAE,aAAa,GAAG,IAAI,GACxB,oBAAoB,CAiBtB"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { type OpenSealedPushResult } from './sealedPush';
|
|
2
|
+
export declare const SEALED_PUSH_TASK = "ETHORA_SEALED_PUSH";
|
|
3
|
+
export interface SealedPushTaskOptions {
|
|
4
|
+
/** Android notification channel; the OS default channel when omitted. */
|
|
5
|
+
channelId?: string;
|
|
6
|
+
/** Shown when the box does not open (no key, another key, damaged). Default "New message". */
|
|
7
|
+
placeholderTitle?: string;
|
|
8
|
+
placeholderBody?: string;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* The FCM data map out of the task payload. expo-notifications passes the
|
|
12
|
+
* message as `{ notification, data }`; the data keys are on `data`
|
|
13
|
+
* itself, `data.dataString` carries the same as a JSON string on some
|
|
14
|
+
* versions, and a Firebase `RemoteMessage` keeps them under `data.data`.
|
|
15
|
+
*/
|
|
16
|
+
export declare const sealedPushDataOf: (payload: unknown) => Record<string, unknown> | null;
|
|
17
|
+
/**
|
|
18
|
+
* Open a sealed push and show it. One notification per chat: the room JID
|
|
19
|
+
* is the identifier, so a newer message replaces the older one the way the
|
|
20
|
+
* service's collapse key does for plain pushes.
|
|
21
|
+
*/
|
|
22
|
+
export declare function presentSealedPush(data: Record<string, unknown>, options?: SealedPushTaskOptions): Promise<OpenSealedPushResult | null>;
|
|
23
|
+
/**
|
|
24
|
+
* Define and register the background task that renders sealed pushes on
|
|
25
|
+
* Android. Call it at module scope of a file the app loads first (the
|
|
26
|
+
* entry file, or the root layout with expo-router): a killed app is
|
|
27
|
+
* started headless to run it, and the task must exist by then. No-op on
|
|
28
|
+
* iOS and when expo-task-manager / expo-notifications are not installed.
|
|
29
|
+
*/
|
|
30
|
+
export declare function registerSealedPushTask(options?: SealedPushTaskOptions): boolean;
|
|
31
|
+
/** Test seam only. */
|
|
32
|
+
export declare const __resetSealedPushTaskForTests: () => void;
|
|
33
|
+
//# sourceMappingURL=sealedPushTask.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sealedPushTask.d.ts","sourceRoot":"","sources":["../../../src/push/sealedPushTask.ts"],"names":[],"mappings":"AAGA,OAAO,EAAwC,KAAK,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAY/F,eAAO,MAAM,gBAAgB,uBAAuB,CAAC;AAErD,MAAM,WAAW,qBAAqB;IACpC,yEAAyE;IACzE,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,8FAA8F;IAC9F,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAsBD;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,GAAI,SAAS,OAAO,KAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAqB7E,CAAC;AA6BF;;;;GAIG;AACH,wBAAsB,iBAAiB,CACrC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC7B,OAAO,GAAE,qBAA0B,GAClC,OAAO,CAAC,oBAAoB,GAAG,IAAI,CAAC,CAqBtC;AAED;;;;;;GAMG;AACH,wBAAgB,sBAAsB,CAAC,OAAO,GAAE,qBAA0B,GAAG,OAAO,CA8BnF;AAED,sBAAsB;AACtB,eAAO,MAAM,6BAA6B,QAAO,IAEhD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"persistence.d.ts","sourceRoot":"","sources":["../../../src/roomStore/persistence.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAC;AACvD,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"persistence.d.ts","sourceRoot":"","sources":["../../../src/roomStore/persistence.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAC;AACvD,OAAO,KAAK,EAAmB,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AAuC7E,eAAO,MAAM,aAAa,MAAM,CAAC;AAMjC,eAAO,MAAM,6BAA6B,MAAM,CAAC;AAEjD,UAAU,kBAAkB;IAC1B,IAAI,EAAE,IAAI,CAAC;CACZ;AAED,UAAU,mBAAmB;IAC3B,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;CAE9B;AAED,UAAU,kBAAkB;IAC1B,cAAc,EAAE,MAAM,CAAC,MAAM,EAAE,oBAAoB,CAAC,CAAC;CAKtD;AAyMD;;;;;;GAMG;AACH,eAAO,MAAM,qBAAqB,GAChC,UAAU,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,KAC9B,MAAM,CAAC,MAAM,EAAE,KAAK,CAgBpB,CAAC;AAsJJ,wBAAgB,+BAA+B,CAC7C,OAAO,EAAE,QAAQ,EACjB,OAAO,EAAE,MAAM,GACd,oBAAoB,GAAG,IAAI,CAuD7B;AAED;;;;;;;GAOG;AACH,wBAAgB,uBAAuB,CACrC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,GAAG,IAAI,GAAG,SAAS,EAC/C,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,oBAAoB,CAAC,GAAG,IAAI,GAAG,SAAS,GACrE,oBAAoB,EAAE,CAaxB;AAsKD;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,EAAE,UAuCnC,CAAC;AAwDF,wBAAsB,kBAAkB,IAAI,OAAO,CAAC;IAClD,IAAI,EAAE,kBAAkB,GAAG,IAAI,CAAC;IAChC,KAAK,EAAE,mBAAmB,GAAG,IAAI,CAAC;IAClC,IAAI,EAAE,kBAAkB,GAAG,IAAI,CAAC;CACjC,CAAC,CA0BD;AAED,wBAAsB,mBAAmB,IAAI,OAAO,CAAC,IAAI,CAAC,CAgBzD;AAED,eAAO,MAAM,YAAY;;;;;;CAMxB,CAAC;AACF,eAAO,MAAM,gBAAgB,QAjzBP,MAAM,WAizBW,CAAC"}
|
|
@@ -1,6 +1,18 @@
|
|
|
1
1
|
import { PayloadAction, type Slice } from '@reduxjs/toolkit';
|
|
2
2
|
import type { WritableDraft } from 'immer';
|
|
3
|
-
import { IMessage } from '../types/types';
|
|
3
|
+
import { IMentionSpan, IMessage } from '../types/types';
|
|
4
|
+
/**
|
|
5
|
+
* One file of a failed media send, as the retry replays it. Only the fields
|
|
6
|
+
* an upload needs, so it persists as a plain JSON object.
|
|
7
|
+
*/
|
|
8
|
+
export interface FailedMediaFile {
|
|
9
|
+
uri?: string;
|
|
10
|
+
type?: string;
|
|
11
|
+
name?: string;
|
|
12
|
+
size?: number;
|
|
13
|
+
duration?: number;
|
|
14
|
+
waveForm?: string;
|
|
15
|
+
}
|
|
4
16
|
export type FailedMessagePayload = {
|
|
5
17
|
kind: 'text';
|
|
6
18
|
id: string;
|
|
@@ -13,11 +25,20 @@ export type FailedMessagePayload = {
|
|
|
13
25
|
kind: 'media';
|
|
14
26
|
id: string;
|
|
15
27
|
roomJID: string;
|
|
28
|
+
/** The first file (or the only one); kept for single-file readers. */
|
|
16
29
|
data: any;
|
|
17
30
|
type: string;
|
|
18
31
|
isReply?: boolean;
|
|
19
32
|
isChecked?: boolean;
|
|
20
33
|
mainMessage?: string;
|
|
34
|
+
/**
|
|
35
|
+
* Every file of the message, in selection order. Retry replays the
|
|
36
|
+
* whole list; a message with no list falls back to `data`.
|
|
37
|
+
*/
|
|
38
|
+
files?: FailedMediaFile[];
|
|
39
|
+
/** The caption the files were sent with, if any. */
|
|
40
|
+
caption?: string;
|
|
41
|
+
captionMentions?: IMentionSpan[];
|
|
21
42
|
};
|
|
22
43
|
export interface roomHeapSliceState {
|
|
23
44
|
messageHeap: IMessage[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"roomHeapSlice.d.ts","sourceRoot":"","sources":["../../../src/roomStore/roomHeapSlice.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,aAAa,EAAE,KAAK,KAAK,EAAE,MAAM,kBAAkB,CAAC;AAC1E,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAC3C,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"roomHeapSlice.d.ts","sourceRoot":"","sources":["../../../src/roomStore/roomHeapSlice.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,aAAa,EAAE,KAAK,KAAK,EAAE,MAAM,kBAAkB,CAAC;AAC1E,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAC3C,OAAO,EAAE,YAAY,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAMxD;;;GAGG;AACH,MAAM,WAAW,eAAe;IAC9B,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,MAAM,oBAAoB,GAC5B;IACE,I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MACL,gBAAgB,mGAChB,SAAS,qFACT,yBAAyB,0GACzB,iBAAiB,gHACjB,mBAAmB,kGACI,CAAC;;AAE1B,wBAAqC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { PayloadAction, type Slice } from '@reduxjs/toolkit';
|
|
2
2
|
import type { WritableDraft } from 'immer';
|
|
3
|
-
import { EditAction, HistoryPreloadState, IMessage, IRoom } from '../types/types';
|
|
3
|
+
import { EditAction, HistoryPreloadState, IAttachment, IMessage, IRoom } from '../types/types';
|
|
4
4
|
import { msgSortableMs } from '../helpers/msgSortableMs';
|
|
5
5
|
import type XmppClient from '../networking/xmppClient';
|
|
6
6
|
import type { TranslationObject } from '../helpers/transformTranslatations';
|
|
@@ -162,6 +162,31 @@ declare const reducers: {
|
|
|
162
162
|
locale: string;
|
|
163
163
|
entry: TranslationObject[string];
|
|
164
164
|
}>): void;
|
|
165
|
+
/**
|
|
166
|
+
* Local upload state of one file of an outgoing media message: its
|
|
167
|
+
* `uploadStatus` ('uploading' | 'failed') and `uploadProgress` (0-100).
|
|
168
|
+
* `null` for `uploadStatus` clears both, once the file is up. Matches the
|
|
169
|
+
* message in the room and in the jump window, like the other patches.
|
|
170
|
+
* Never persisted: the persist whitelist drops these fields.
|
|
171
|
+
*/
|
|
172
|
+
setMediaUploadState(state: WritableDraft<RoomMessagesState>, action: PayloadAction<{
|
|
173
|
+
roomJID: string;
|
|
174
|
+
messageId: string;
|
|
175
|
+
attachmentId: string;
|
|
176
|
+
uploadStatus?: "uploading" | "failed" | null;
|
|
177
|
+
uploadProgress?: number;
|
|
178
|
+
}>): void;
|
|
179
|
+
/**
|
|
180
|
+
* Replaces the attachments of a message the sender already has, without
|
|
181
|
+
* touching its other fields: `pending` stays as it is, so the bubble is
|
|
182
|
+
* still waiting for the server echo. (addRoomMessage would count this as
|
|
183
|
+
* the echo and clear `pending`.)
|
|
184
|
+
*/
|
|
185
|
+
setMessageAttachments(state: WritableDraft<RoomMessagesState>, action: PayloadAction<{
|
|
186
|
+
roomJID: string;
|
|
187
|
+
messageId: string;
|
|
188
|
+
attachments: IAttachment[];
|
|
189
|
+
}>): void;
|
|
165
190
|
addRoomMessage(state: WritableDraft<RoomMessagesState>, action: PayloadAction<{
|
|
166
191
|
roomJID: string;
|
|
167
192
|
message: IMessage;
|
|
@@ -303,6 +328,26 @@ declare const reducers: {
|
|
|
303
328
|
latestReactionTimestamp?: string;
|
|
304
329
|
data?: Record<string, string>;
|
|
305
330
|
}>) => void;
|
|
331
|
+
/**
|
|
332
|
+
* XEP-0184: an occupant's client acknowledged one of our messages. Only
|
|
333
|
+
* the message id is matched (archive ids), on the live list and on a jump
|
|
334
|
+
* window copy. Session-only: not persisted.
|
|
335
|
+
*/
|
|
336
|
+
setReceivedReceipt: (state: WritableDraft<RoomMessagesState>, action: PayloadAction<{
|
|
337
|
+
roomJID: string;
|
|
338
|
+
messageId: string;
|
|
339
|
+
fromXmppUsername: string;
|
|
340
|
+
timestamp: number;
|
|
341
|
+
}>) => void;
|
|
342
|
+
/**
|
|
343
|
+
* XEP-0333: an occupant displayed up to `messageId`. One watermark per
|
|
344
|
+
* user and room, replaced on every marker. Session-only: not persisted.
|
|
345
|
+
*/
|
|
346
|
+
setDisplayedMarker: (state: WritableDraft<RoomMessagesState>, action: PayloadAction<{
|
|
347
|
+
roomJID: string;
|
|
348
|
+
xmppUsername: string;
|
|
349
|
+
messageId: string;
|
|
350
|
+
}>) => void;
|
|
306
351
|
setLogoutState: (state: WritableDraft<RoomMessagesState>) => void;
|
|
307
352
|
setActiveMessage: (state: WritableDraft<RoomMessagesState>, action: PayloadAction<{
|
|
308
353
|
id: string;
|
|
@@ -337,7 +382,17 @@ export declare const addRoom: import("@reduxjs/toolkit").ActionCreatorWithPayloa
|
|
|
337
382
|
roomJID: string;
|
|
338
383
|
message: IMessage;
|
|
339
384
|
start?: boolean;
|
|
340
|
-
}, "roomMessages/addRoomMessage">,
|
|
385
|
+
}, "roomMessages/addRoomMessage">, setMediaUploadState: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
386
|
+
roomJID: string;
|
|
387
|
+
messageId: string;
|
|
388
|
+
attachmentId: string;
|
|
389
|
+
uploadStatus?: "uploading" | "failed" | null;
|
|
390
|
+
uploadProgress?: number;
|
|
391
|
+
}, "roomMessages/setMediaUploadState">, setMessageAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
392
|
+
roomJID: string;
|
|
393
|
+
messageId: string;
|
|
394
|
+
attachments: IAttachment[];
|
|
395
|
+
}, "roomMessages/setMessageAttachments">, deleteRoomMessage: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
341
396
|
roomJID: string;
|
|
342
397
|
messageId: string;
|
|
343
398
|
}, "roomMessages/deleteRoomMessage">, setEditAction: import("@reduxjs/toolkit").ActionCreatorWithOptionalPayload<EditAction | undefined, "roomMessages/setEditAction">, editRoomMessage: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
@@ -401,7 +456,16 @@ export declare const addRoom: import("@reduxjs/toolkit").ActionCreatorWithPayloa
|
|
|
401
456
|
reactions: string[];
|
|
402
457
|
latestReactionTimestamp?: string;
|
|
403
458
|
data?: Record<string, string>;
|
|
404
|
-
}, "roomMessages/setReactions">,
|
|
459
|
+
}, "roomMessages/setReactions">, setReceivedReceipt: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
460
|
+
roomJID: string;
|
|
461
|
+
messageId: string;
|
|
462
|
+
fromXmppUsername: string;
|
|
463
|
+
timestamp: number;
|
|
464
|
+
}, "roomMessages/setReceivedReceipt">, setDisplayedMarker: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
465
|
+
roomJID: string;
|
|
466
|
+
xmppUsername: string;
|
|
467
|
+
messageId: string;
|
|
468
|
+
}, "roomMessages/setDisplayedMarker">, mergeUsersSet: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
405
469
|
members: Record<string, any>;
|
|
406
470
|
}, "roomMessages/mergeUsersSet">, removeRoomMessage: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
407
471
|
roomJID: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"roomsSlice.d.ts","sourceRoot":"","sources":["../../../src/roomStore/roomsSlice.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiC,aAAa,EAAE,KAAK,KAAK,EAAE,MAAM,kBAAkB,CAAC;AAC5F,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAC3C,OAAO,EAAE,UAAU,EAAE,mBAAmB,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"roomsSlice.d.ts","sourceRoot":"","sources":["../../../src/roomStore/roomsSlice.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiC,aAAa,EAAE,KAAK,KAAK,EAAE,MAAM,kBAAkB,CAAC;AAC5F,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAC3C,OAAO,EAAE,UAAU,EAAE,mBAAmB,EAAE,WAAW,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAE/F,OAAO,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC;AACzD,OAAO,KAAK,UAAU,MAAM,0BAA0B,CAAC;AACvD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,oCAAoC,CAAC;AAe5E,eAAO,MAAM,qBAAqB,MAAM,CAAC;AACzC,yEAAyE;AACzE,eAAO,MAAM,eAAe,KAAK,CAAC;AAClC,eAAO,MAAM,uBAAuB,OAAO,CAAC;AA+S5C;gEACgE;AAChE,eAAO,MAAM,gBAAgB,GAAI,GAAG,MAAM,EAAE,GAAG,MAAM,KAAG,MACkB,CAAC;AAE3E,eAAO,MAAM,sBAAsB,GACjC,SAAS,QAAQ,EACjB,MAAM,MAAM,GAAG,SAAS,EACxB,WAAW,MAAM,EAAE,EACnB,OAAO,MAAM,CAAC,MAAM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,MAAM;aAAW,OAAO,CAAC,KAAK,CAAC;+BAg8BhE,sBAAsB;WAhKa,gBAAgB,EAAE;2CAiKrD,eAAe;aAvtBA,MAAM;cACL,QAAQ,EAAE;YACZ,OAAO;oCAstBrB,QAAQ;WAn9B2E,KAAK,EAAE;6BAo9B1F,eAAe,+GACf,yBAAyB,gHACzB,2BAA2B,sGAC3B,oBAAoB;aA1cL,MAAM;SACV,MAAM,EAAE;gBACD,MAAM;WACX,MAAM;cACH,eAAe;yCAuc/B,gBAAgB,2FAChB,cAAc,8FACd,gBAAgB,gGAChB,YAAY;aA3VG,MAAM;eACJ,MAAM;WACV,MAAM;eACF,MAAM,EAAE;8BACO,MAAM;WACzB,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;iCAuVnC,kBAAkB;aA5SH,MAAM;eACJ,MAAM;sBACC,MAAM;eACb,MAAM;uCA0SvB,kBAAkB;aAlRH,MAAM;kBACD,MAAM;eACT,MAAM;uCAiRvB,aAAa;aA1IwB,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC;kCA2IxD,iBAAiB;aAj2BoB,MAAM;eAAa,MAAM;sCAk2B9D,cAAc;UAzN4E,KAAK;mCA0N/F,qBAAqB;aA30BN,MAAM;eACJ,MAAM;YACT,MAAM;WACP,iBAAiB,CAAC,MAAM,CAAC;0CAy0BtC,mBAAmB,4GACnB,oBAAoB,+FACpB,aAAa,iGACb,yBAAyB;aAzaV,MAAM;cACL,QAAQ,EAAE;iBACP,MAAM,GAAG,IAAI;cAChB,OAAO;8CAuavB,wBAAwB;aAnZT,MAAM;cACL,QAAQ,EAAE;iBACP,MAAM,GAAG,IAAI;cAChB,OAAO;6CAiZvB,eAAe,wFACK,CAAC;;AAEvB,wBAAkC"}
|
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
import type { PushTokenType } from '../types/types';
|
|
2
2
|
export interface RegisterPushTokenOptions {
|
|
3
3
|
tokenType?: PushTokenType;
|
|
4
|
+
/**
|
|
5
|
+
* Encrypted pushes: base64 of the device's X25519 public key
|
|
6
|
+
* (`ensurePushKeyPair().publicKey`). Sent with the token as `pushKey`;
|
|
7
|
+
* the service seals every chat push for it. A backend without the
|
|
8
|
+
* feature refuses the registration instead of delivering in the clear.
|
|
9
|
+
*/
|
|
10
|
+
pushKey?: string;
|
|
4
11
|
}
|
|
5
12
|
export type RegisterPushTokenOutcome = 'registered' | 'deferred' | 'disabled';
|
|
6
13
|
export interface UnregisterPushTokenOptions {
|
|
@@ -10,6 +17,7 @@ export type UnregisterPushTokenOutcome = 'unregistered' | 'forgotten';
|
|
|
10
17
|
export interface RegisteredPushToken {
|
|
11
18
|
token: string;
|
|
12
19
|
tokenType: PushTokenType;
|
|
20
|
+
pushKey?: string;
|
|
13
21
|
}
|
|
14
22
|
export declare const installPushTokenHook: () => void;
|
|
15
23
|
export declare function registerPushToken(token: string, options?: RegisterPushTokenOptions): Promise<RegisterPushTokenOutcome>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pushRegistration.d.ts","sourceRoot":"","sources":["../../../src/services/pushRegistration.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAGpD,MAAM,WAAW,wBAAwB;IACvC,SAAS,CAAC,EAAE,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"pushRegistration.d.ts","sourceRoot":"","sources":["../../../src/services/pushRegistration.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAGpD,MAAM,WAAW,wBAAwB;IACvC,SAAS,CAAC,EAAE,aAAa,CAAC;IAC1B;;;;;OAKG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,MAAM,wBAAwB,GAChC,YAAY,GACZ,UAAU,GACV,UAAU,CAAC;AAEf,MAAM,WAAW,0BAA0B;IACzC,SAAS,CAAC,EAAE,aAAa,CAAC;CAC3B;AAED,MAAM,MAAM,0BAA0B,GAClC,cAAc,GACd,WAAW,CAAC;AAEhB,MAAM,WAAW,mBAAmB;IAClC,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,aAAa,CAAC;IACzB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAkPD,eAAO,MAAM,oBAAoB,QAAO,IAMvC,CAAC;AAEF,wBAAsB,iBAAiB,CACrC,KAAK,EAAE,MAAM,EACb,OAAO,CAAC,EAAE,wBAAwB,GACjC,OAAO,CAAC,wBAAwB,CAAC,CAgBnC;AAED,wBAAsB,uBAAuB,IAAI,OAAO,CAAC,IAAI,CAAC,CAmB7D;AAED,wBAAsB,mBAAmB,CACvC,OAAO,CAAC,EAAE,0BAA0B,GACnC,OAAO,CAAC,0BAA0B,CAAC,CAiCrC;AAED,eAAO,MAAM,sBAAsB,QAAO,mBAAmB,GAAG,IAG/D,CAAC;AAEF,eAAO,MAAM,uBAAuB,QAAO,mBAAmB,EAGnC,CAAC;AAE5B,eAAO,MAAM,+BAA+B,QAAO,IAUlD,CAAC"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* One uploaded file carried by a media message.
|
|
3
|
+
*
|
|
4
|
+
* Historically a media message described exactly one file through flat
|
|
5
|
+
* `IMessage` fields (`location`, `mimetype`, `originalName`, ...). Those
|
|
6
|
+
* fields are still written (they are what every already-shipped client
|
|
7
|
+
* reads), and they now double as attachment #0 of `IMessage.attachments`.
|
|
8
|
+
* Anything past #0 only exists in the `attachments` payload, so old clients
|
|
9
|
+
* degrade to "shows the first file" instead of breaking.
|
|
10
|
+
*/
|
|
11
|
+
export interface IAttachment {
|
|
12
|
+
/** `_id` returned by POST /files/ - stable per upload, used as a render key. */
|
|
13
|
+
attachmentId?: string;
|
|
14
|
+
/** Canonical file URL. */
|
|
15
|
+
location: string;
|
|
16
|
+
/** Server-side generated preview (images always, other types sometimes). */
|
|
17
|
+
locationPreview?: string;
|
|
18
|
+
mimetype?: string;
|
|
19
|
+
/** Name the user picked. */
|
|
20
|
+
originalName?: string;
|
|
21
|
+
/** Name on the storage side. */
|
|
22
|
+
fileName?: string;
|
|
23
|
+
/** Bytes, as a string - that is how it travels on the wire. */
|
|
24
|
+
size?: string;
|
|
25
|
+
duration?: string;
|
|
26
|
+
/** Natural pixel size, when the storage recorded it. */
|
|
27
|
+
width?: number;
|
|
28
|
+
height?: number;
|
|
29
|
+
ownerKey?: string;
|
|
30
|
+
userId?: string;
|
|
31
|
+
createdAt?: string;
|
|
32
|
+
updatedAt?: string;
|
|
33
|
+
expiresAt?: string;
|
|
34
|
+
isVisible?: boolean;
|
|
35
|
+
isPrivate?: boolean;
|
|
36
|
+
/**
|
|
37
|
+
* Local-only state of an outgoing attachment, set by the sender while its
|
|
38
|
+
* message is still being sent. Never written to the wire.
|
|
39
|
+
* uploading - the file is going up (or every file is up and the message
|
|
40
|
+
* is waiting on its siblings); `uploadProgress` is 0 to 100.
|
|
41
|
+
* failed - this file did not upload; the message is held until it
|
|
42
|
+
* is retried.
|
|
43
|
+
*/
|
|
44
|
+
uploadStatus?: 'uploading' | 'failed';
|
|
45
|
+
uploadProgress?: number;
|
|
46
|
+
/**
|
|
47
|
+
* The file as it is on this device (`file://`), shown on the sender's own
|
|
48
|
+
* bubble while it uploads. Local only, like the upload state above.
|
|
49
|
+
*/
|
|
50
|
+
localUrl?: string;
|
|
51
|
+
}
|
|
52
|
+
//# sourceMappingURL=attachment.model.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"attachment.model.d.ts","sourceRoot":"","sources":["../../../../src/types/models/attachment.model.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,MAAM,WAAW,WAAW;IAC1B,gFAAgF;IAChF,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,0BAA0B;IAC1B,QAAQ,EAAE,MAAM,CAAC;IACjB,4EAA4E;IAC5E,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,4BAA4B;IAC5B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,gCAAgC;IAChC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,+DAA+D;IAC/D,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,wDAAwD;IACxD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;;;;;;;OAOG;IACH,YAAY,CAAC,EAAE,WAAW,GAAG,QAAQ,CAAC;IACtC,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { IUser } from './user.model';
|
|
2
2
|
import { TranslationObject } from '../../helpers/transformTranslatations';
|
|
3
3
|
import { Iso639_1Codes } from './language.model';
|
|
4
|
+
import type { IAttachment } from './attachment.model';
|
|
4
5
|
export interface IMessage {
|
|
5
6
|
id: string;
|
|
6
7
|
user: IUser;
|
|
@@ -34,6 +35,25 @@ export interface IMessage {
|
|
|
34
35
|
langSource?: Iso639_1Codes;
|
|
35
36
|
originalName?: string;
|
|
36
37
|
size?: string;
|
|
38
|
+
/**
|
|
39
|
+
* Every file carried by this message. `attachments[0]` mirrors the flat
|
|
40
|
+
* `location`/`mimetype`/`originalName` fields above. Undefined on messages
|
|
41
|
+
* that predate multi-attach; read it through `getMessageAttachments()`.
|
|
42
|
+
*/
|
|
43
|
+
attachments?: IAttachment[];
|
|
44
|
+
/**
|
|
45
|
+
* Text sent with a media message's files. `body` stays "media". In a sealed
|
|
46
|
+
* message it comes out of the encrypted body, never from `<data>`. Read it
|
|
47
|
+
* through `getMessageCaption()`.
|
|
48
|
+
*/
|
|
49
|
+
caption?: string;
|
|
50
|
+
/** @-mention spans into `caption`. Stored, not rendered on RN. */
|
|
51
|
+
captionMentions?: IMentionSpan[];
|
|
52
|
+
/**
|
|
53
|
+
* XEP-0184 delivery receipts: xmpp username -> epoch ms when that
|
|
54
|
+
* occupant's client acknowledged the message. Session-only (never persisted).
|
|
55
|
+
*/
|
|
56
|
+
receivedBy?: Record<string, number>;
|
|
37
57
|
xmppId?: string;
|
|
38
58
|
xmppFrom?: string;
|
|
39
59
|
deleted?: boolean;
|
|
@@ -46,6 +66,12 @@ export interface IMessage {
|
|
|
46
66
|
kind: 'audio' | 'video';
|
|
47
67
|
};
|
|
48
68
|
}
|
|
69
|
+
export interface IMentionSpan {
|
|
70
|
+
jid: string;
|
|
71
|
+
name: string;
|
|
72
|
+
offset: number;
|
|
73
|
+
length: number;
|
|
74
|
+
}
|
|
49
75
|
export interface ReactionMessage {
|
|
50
76
|
emoji: string[];
|
|
51
77
|
data: Record<string, string> | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"message.model.d.ts","sourceRoot":"","sources":["../../../../src/types/models/message.model.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AACrC,OAAO,EAAE,iBAAiB,EAAE,MAAM,uCAAuC,CAAC;AAC1E,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"message.model.d.ts","sourceRoot":"","sources":["../../../../src/types/models/message.model.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AACrC,OAAO,EAAE,iBAAiB,EAAE,MAAM,uCAAuC,CAAC;AAC1E,OAAO,EAAE,aAAa,EA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IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,YAAY;IAC3B,OAAO,EAAE,QAAQ,CAAC;IAClB,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,MAAM,WAAW,gBAAgB;CAAG;AAEpC,MAAM,WAAW,WAAY,SAAQ,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClE,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB"}
|
|
@@ -7,5 +7,12 @@ export interface ModalFile {
|
|
|
7
7
|
originalName?: string;
|
|
8
8
|
duration?: number | string;
|
|
9
9
|
waveForm?: string;
|
|
10
|
+
/**
|
|
11
|
+
* The other files of the album this one was opened from, this one
|
|
12
|
+
* included, in order. With `index` it lets the viewer page through them.
|
|
13
|
+
*/
|
|
14
|
+
siblings?: ModalFile[];
|
|
15
|
+
/** Position of this file in `siblings`. */
|
|
16
|
+
index?: number;
|
|
10
17
|
}
|
|
11
18
|
//# sourceMappingURL=modal.model.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"modal.model.d.ts","sourceRoot":"","sources":["../../../../src/types/models/modal.model.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,qCAAqC,CAAC;AAElE,MAAM,MAAM,SAAS,GAAG,CAAC,OAAO,WAAW,CAAC,CAAC,MAAM,OAAO,WAAW,CAAC,CAAC;AAEvE,MAAM,WAAW,SAAS;IACxB,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC3B,QAAQ,CAAC,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"modal.model.d.ts","sourceRoot":"","sources":["../../../../src/types/models/modal.model.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,qCAAqC,CAAC;AAElE,MAAM,MAAM,SAAS,GAAG,CAAC,OAAO,WAAW,CAAC,CAAC,MAAM,OAAO,WAAW,CAAC,CAAC;AAEvE,MAAM,WAAW,SAAS;IACxB,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC3B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;;OAGG;IACH,QAAQ,CAAC,EAAE,SAAS,EAAE,CAAC;IACvB,2CAA2C;IAC3C,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB"}
|