@amityco/ts-sdk-react-native 7.18.1-bb0e7abc.0 → 7.19.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/@types/index.d.ts +0 -1
- package/dist/@types/index.d.ts.map +1 -1
- package/dist/__mocks__/marker/api/getMessageMarkers.d.ts +3 -0
- package/dist/__mocks__/marker/api/getMessageMarkers.d.ts.map +1 -0
- package/dist/__mocks__/marker/api/getSubChannelMarkers.d.ts +3 -0
- package/dist/__mocks__/marker/api/getSubChannelMarkers.d.ts.map +1 -0
- package/dist/__mocks__/marker/api/index.d.ts +6 -0
- package/dist/__mocks__/marker/api/index.d.ts.map +1 -0
- package/dist/adRepository/api/tests/integration/getNetworkAds.integration.test.d.ts +2 -0
- package/dist/adRepository/api/tests/integration/getNetworkAds.integration.test.d.ts.map +1 -0
- package/dist/categoryRepository/api/tests/integration/getCategory.integration.test.d.ts +2 -0
- package/dist/categoryRepository/api/tests/integration/getCategory.integration.test.d.ts.map +1 -0
- package/dist/categoryRepository/internalApi/tests/integration/getCategory.integration.test.d.ts +2 -0
- package/dist/categoryRepository/internalApi/tests/integration/getCategory.integration.test.d.ts.map +1 -0
- package/dist/categoryRepository/internalApi/tests/integration/queryCategories.integration.test.d.ts +2 -0
- package/dist/categoryRepository/internalApi/tests/integration/queryCategories.integration.test.d.ts.map +1 -0
- package/dist/categoryRepository/observers/getCategories.d.ts.map +1 -1
- package/dist/categoryRepository/observers/tests/integration/getCategories.integration.test.d.ts +2 -0
- package/dist/categoryRepository/observers/tests/integration/getCategories.integration.test.d.ts.map +1 -0
- package/dist/categoryRepository/observers/tests/integration/setup.d.ts +10 -0
- package/dist/categoryRepository/observers/tests/integration/setup.d.ts.map +1 -0
- package/dist/channelRepository/api/createChannel.d.ts.map +1 -1
- package/dist/channelRepository/api/tests/integration/createChannel.integration.test.d.ts +2 -0
- package/dist/channelRepository/api/tests/integration/createChannel.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/api/tests/integration/deleteChannel.integration.test.d.ts +2 -0
- package/dist/channelRepository/api/tests/integration/deleteChannel.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/api/tests/integration/getChannelByIds.integration.test.d.ts +2 -0
- package/dist/channelRepository/api/tests/integration/getChannelByIds.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/api/tests/integration/joinChannel.integration.test.d.ts +2 -0
- package/dist/channelRepository/api/tests/integration/joinChannel.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/api/tests/integration/leaveChannel.integration.test.d.ts +2 -0
- package/dist/channelRepository/api/tests/integration/leaveChannel.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/api/tests/integration/markChannelsAsReadBySegment.integration.test.d.ts +2 -0
- package/dist/channelRepository/api/tests/integration/markChannelsAsReadBySegment.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/api/tests/integration/muteChannel.integration.test.d.ts +2 -0
- package/dist/channelRepository/api/tests/integration/muteChannel.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/api/tests/integration/queryChannels.integration.test.d.ts +2 -0
- package/dist/channelRepository/api/tests/integration/queryChannels.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/api/tests/integration/unmuteChannel.integration.test.d.ts +2 -0
- package/dist/channelRepository/api/tests/integration/unmuteChannel.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/api/tests/integration/updateChannel.integration.test.d.ts +2 -0
- package/dist/channelRepository/api/tests/integration/updateChannel.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/observers/getChannel.d.ts.map +1 -1
- package/dist/channelRepository/observers/tests/integrations/getChannel.integration.test.d.ts +2 -0
- package/dist/channelRepository/observers/tests/integrations/getChannel.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/observers/tests/integrations/getChannels.integration.test.d.ts +2 -0
- package/dist/channelRepository/observers/tests/integrations/getChannels.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/observers/tests/integrations/getMyMembership.integration.test.d.ts +2 -0
- package/dist/channelRepository/observers/tests/integrations/getMyMembership.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/observers/tests/integrations/getMyMembership.noUser.integration.test.d.ts +2 -0
- package/dist/channelRepository/observers/tests/integrations/getMyMembership.noUser.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/observers/tests/integrations/getTotalChannelsUnread.integration.test.d.ts +2 -0
- package/dist/channelRepository/observers/tests/integrations/getTotalChannelsUnread.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/observers/tests/integrations/getTotalChannelsUnread.noUser.integration.test.d.ts +2 -0
- package/dist/channelRepository/observers/tests/integrations/getTotalChannelsUnread.noUser.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/utils/prepareChannelPayload.d.ts.map +1 -1
- package/dist/client/api/index.d.ts +0 -1
- package/dist/client/api/index.d.ts.map +1 -1
- package/dist/client/api/tests/integration/accessTokenExpiryWatcher.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/accessTokenExpiryWatcher.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/accessTokenFunctions.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/accessTokenFunctions.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/activeUser.branches.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/activeUser.branches.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/activeUser.noUser.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/activeUser.noUser.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/createClient.branches.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/createClient.branches.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/createClient.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/createClient.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/getSettings.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/getSettings.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/login.branches.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/login.branches.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/login.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/login.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/loginAlternate.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/loginAlternate.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/loginAsBot.catch.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/loginAsBot.catch.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/loginAsBot.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/loginAsBot.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/loginAsBotTerminated.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/loginAsBotTerminated.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/loginAsVisitor.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/loginAsVisitor.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/loginAsVisitorTerminated.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/loginAsVisitorTerminated.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/logout.branches.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/logout.branches.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/resumeSession.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/resumeSession.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/resumeSessionLegacy.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/resumeSessionLegacy.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/sessionState.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/sessionState.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/setupLoginSubscriptions.branches.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/setupLoginSubscriptions.branches.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/setupLoginSubscriptions.legacyUnread.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/setupLoginSubscriptions.legacyUnread.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/utilities.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/utilities.integration.test.d.ts.map +1 -0
- package/dist/client/api/tests/integration/validateAndTerminate.integration.test.d.ts +2 -0
- package/dist/client/api/tests/integration/validateAndTerminate.integration.test.d.ts.map +1 -0
- package/dist/client/observers/tests/integrations/getUserUnread.integration.test.d.ts +2 -0
- package/dist/client/observers/tests/integrations/getUserUnread.integration.test.d.ts.map +1 -0
- package/dist/client/observers/tests/integrations/getUserUnreadEdgeCases.integration.test.d.ts +2 -0
- package/dist/client/observers/tests/integrations/getUserUnreadEdgeCases.integration.test.d.ts.map +1 -0
- package/dist/commentRepository/api/tests/getComment.test.d.ts +2 -0
- package/dist/commentRepository/api/tests/getComment.test.d.ts.map +1 -0
- package/dist/commentRepository/events/utils.d.ts.map +1 -1
- package/dist/commentRepository/observers/tests/integrations/getComment.integration.test.d.ts +2 -0
- package/dist/commentRepository/observers/tests/integrations/getComment.integration.test.d.ts.map +1 -0
- package/dist/commentRepository/observers/tests/integrations/getComments.integration.test.d.ts +2 -0
- package/dist/commentRepository/observers/tests/integrations/getComments.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/api/queryCommunities.d.ts.map +1 -1
- package/dist/communityRepository/api/test/integration/createCommunity.integration.test.d.ts +2 -0
- package/dist/communityRepository/api/test/integration/createCommunity.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/api/test/integration/deleteCommunity.integration.test.d.ts +2 -0
- package/dist/communityRepository/api/test/integration/deleteCommunity.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/api/test/integration/getCommunities.integration.test.d.ts +2 -0
- package/dist/communityRepository/api/test/integration/getCommunities.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/api/test/integration/getCommunity.integration.test.d.ts +2 -0
- package/dist/communityRepository/api/test/integration/getCommunity.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/api/test/integration/getRecommendedCommunities.integration.test.d.ts +2 -0
- package/dist/communityRepository/api/test/integration/getRecommendedCommunities.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/api/test/integration/getTrendingCommunities.integration.test.d.ts +2 -0
- package/dist/communityRepository/api/test/integration/getTrendingCommunities.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/api/test/integration/joinCommunity.integration.test.d.ts +2 -0
- package/dist/communityRepository/api/test/integration/joinCommunity.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/api/test/integration/leaveCommunity.integration.test.d.ts +2 -0
- package/dist/communityRepository/api/test/integration/leaveCommunity.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/api/test/integration/queryCommunities.integration.test.d.ts +2 -0
- package/dist/communityRepository/api/test/integration/queryCommunities.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/api/test/integration/setup.d.ts +17 -0
- package/dist/communityRepository/api/test/integration/setup.d.ts.map +1 -0
- package/dist/communityRepository/api/test/integration/updateCommunity.integration.test.d.ts +2 -0
- package/dist/communityRepository/api/test/integration/updateCommunity.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/communityMembership/api/tests/integration/addMembers.integration.test.d.ts +2 -0
- package/dist/communityRepository/communityMembership/api/tests/integration/addMembers.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/communityMembership/api/tests/integration/queryCommunityMembers.integration.test.d.ts +2 -0
- package/dist/communityRepository/communityMembership/api/tests/integration/queryCommunityMembers.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/communityMembership/api/tests/integration/removeMembers.integration.test.d.ts +2 -0
- package/dist/communityRepository/communityMembership/api/tests/integration/removeMembers.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/communityMembership/api/tests/integration/setup.d.ts +10 -0
- package/dist/communityRepository/communityMembership/api/tests/integration/setup.d.ts.map +1 -0
- package/dist/communityRepository/communityMembership/observers/tests/integration/getMembers.integration.test.d.ts +2 -0
- package/dist/communityRepository/communityMembership/observers/tests/integration/getMembers.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/communityMembership/observers/tests/integration/searchMembers.integration.test.d.ts +2 -0
- package/dist/communityRepository/communityMembership/observers/tests/integration/searchMembers.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/communityMembership/observers/tests/integration/setup.d.ts +8 -0
- package/dist/communityRepository/communityMembership/observers/tests/integration/setup.d.ts.map +1 -0
- package/dist/communityRepository/communityModeration/api/test/integration/addRoles.integration.test.d.ts +2 -0
- package/dist/communityRepository/communityModeration/api/test/integration/addRoles.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/communityModeration/api/test/integration/banMembers.integration.test.d.ts +2 -0
- package/dist/communityRepository/communityModeration/api/test/integration/banMembers.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/communityModeration/api/test/integration/removeRoles.integration.test.d.ts +2 -0
- package/dist/communityRepository/communityModeration/api/test/integration/removeRoles.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/communityModeration/api/test/integration/setup.d.ts +14 -0
- package/dist/communityRepository/communityModeration/api/test/integration/setup.d.ts.map +1 -0
- package/dist/communityRepository/communityModeration/api/test/integration/unbanMembers.integration.test.d.ts +2 -0
- package/dist/communityRepository/communityModeration/api/test/integration/unbanMembers.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/observers/tests/integration/getCommunities.integration.test.d.ts +2 -0
- package/dist/communityRepository/observers/tests/integration/getCommunities.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/observers/tests/integration/getCommunity.integration.test.d.ts +2 -0
- package/dist/communityRepository/observers/tests/integration/getCommunity.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/observers/tests/integration/getJoinRequestList.integration.test.d.ts +2 -0
- package/dist/communityRepository/observers/tests/integration/getJoinRequestList.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/observers/tests/integration/getJoinRequests.integration.test.d.ts +2 -0
- package/dist/communityRepository/observers/tests/integration/getJoinRequests.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/observers/tests/integration/getRecommendedCommunities.integration.test.d.ts +2 -0
- package/dist/communityRepository/observers/tests/integration/getRecommendedCommunities.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/observers/tests/integration/getTrendingCommunities.integration.test.d.ts +2 -0
- package/dist/communityRepository/observers/tests/integration/getTrendingCommunities.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/observers/tests/integration/searchCommunities.integration.test.d.ts +2 -0
- package/dist/communityRepository/observers/tests/integration/searchCommunities.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/observers/tests/integration/semanticSearchCommunities.integration.test.d.ts +2 -0
- package/dist/communityRepository/observers/tests/integration/semanticSearchCommunities.integration.test.d.ts.map +1 -0
- package/dist/communityRepository/observers/tests/integration/setup.d.ts +21 -0
- package/dist/communityRepository/observers/tests/integration/setup.d.ts.map +1 -0
- package/dist/core/transports/mqtt.d.ts.map +1 -1
- package/dist/eventRepository/api/tests/integration/createEvent.integration.test.d.ts +2 -0
- package/dist/eventRepository/api/tests/integration/createEvent.integration.test.d.ts.map +1 -0
- package/dist/eventRepository/api/tests/integration/deleteEvent.integration.test.d.ts +2 -0
- package/dist/eventRepository/api/tests/integration/deleteEvent.integration.test.d.ts.map +1 -0
- package/dist/eventRepository/api/tests/integration/updateEvent.integration.test.d.ts +2 -0
- package/dist/eventRepository/api/tests/integration/updateEvent.integration.test.d.ts.map +1 -0
- package/dist/eventRepository/internalApi/tests/integration/createRSVP.integration.test.d.ts +2 -0
- package/dist/eventRepository/internalApi/tests/integration/createRSVP.integration.test.d.ts.map +1 -0
- package/dist/eventRepository/internalApi/tests/integration/getEvent.integration.test.d.ts +2 -0
- package/dist/eventRepository/internalApi/tests/integration/getEvent.integration.test.d.ts.map +1 -0
- package/dist/eventRepository/internalApi/tests/integration/getMyRSVP.integration.test.d.ts +2 -0
- package/dist/eventRepository/internalApi/tests/integration/getMyRSVP.integration.test.d.ts.map +1 -0
- package/dist/eventRepository/internalApi/tests/integration/updateRSVP.integration.test.d.ts +2 -0
- package/dist/eventRepository/internalApi/tests/integration/updateRSVP.integration.test.d.ts.map +1 -0
- package/dist/eventRepository/observers/tests/integrations/getEvent.integration.test.d.ts +2 -0
- package/dist/eventRepository/observers/tests/integrations/getEvent.integration.test.d.ts.map +1 -0
- package/dist/eventRepository/observers/tests/integrations/getEvents.integration.test.d.ts +2 -0
- package/dist/eventRepository/observers/tests/integrations/getEvents.integration.test.d.ts.map +1 -0
- package/dist/eventRepository/observers/tests/integrations/getMyEvents.integration.test.d.ts +2 -0
- package/dist/eventRepository/observers/tests/integrations/getMyEvents.integration.test.d.ts.map +1 -0
- package/dist/eventRepository/observers/tests/integrations/getRSVPs.integration.test.d.ts +2 -0
- package/dist/eventRepository/observers/tests/integrations/getRSVPs.integration.test.d.ts.map +1 -0
- package/dist/eventRepository/utils/createEventResponseSubscriber.d.ts +7 -1
- package/dist/eventRepository/utils/createEventResponseSubscriber.d.ts.map +1 -1
- package/dist/external/api/tests/integration/createUserToken.integration.test.d.ts +2 -0
- package/dist/external/api/tests/integration/createUserToken.integration.test.d.ts.map +1 -0
- package/dist/feedRepository/api/tests/integration/queryGlobalFeed.integration.test.d.ts +2 -0
- package/dist/feedRepository/api/tests/integration/queryGlobalFeed.integration.test.d.ts.map +1 -0
- package/dist/feedRepository/observers/tests/integration/getCommunityFeed.integration.test.d.ts +2 -0
- package/dist/feedRepository/observers/tests/integration/getCommunityFeed.integration.test.d.ts.map +1 -0
- package/dist/feedRepository/observers/tests/integration/getCustomRankingGlobalFeed.integration.test.d.ts +2 -0
- package/dist/feedRepository/observers/tests/integration/getCustomRankingGlobalFeed.integration.test.d.ts.map +1 -0
- package/dist/feedRepository/observers/tests/integration/getGlobalFeed.integration.test.d.ts +2 -0
- package/dist/feedRepository/observers/tests/integration/getGlobalFeed.integration.test.d.ts.map +1 -0
- package/dist/feedRepository/observers/tests/integration/getUserFeed.integration.test.d.ts +2 -0
- package/dist/feedRepository/observers/tests/integration/getUserFeed.integration.test.d.ts.map +1 -0
- package/dist/feedRepository/observers/utils.d.ts.map +1 -1
- package/dist/fileRepository/api/tests/integration/deleteFile.integration.test.d.ts +2 -0
- package/dist/fileRepository/api/tests/integration/deleteFile.integration.test.d.ts.map +1 -0
- package/dist/fileRepository/api/tests/integration/fileUrlWithSize.integration.test.d.ts +2 -0
- package/dist/fileRepository/api/tests/integration/fileUrlWithSize.integration.test.d.ts.map +1 -0
- package/dist/fileRepository/api/tests/integration/getFile.integration.test.d.ts +2 -0
- package/dist/fileRepository/api/tests/integration/getFile.integration.test.d.ts.map +1 -0
- package/dist/fileRepository/api/tests/integration/updateAltText.integration.test.d.ts +2 -0
- package/dist/fileRepository/api/tests/integration/updateAltText.integration.test.d.ts.map +1 -0
- package/dist/fileRepository/api/tests/integration/uploadAudio.integration.test.d.ts +2 -0
- package/dist/fileRepository/api/tests/integration/uploadAudio.integration.test.d.ts.map +1 -0
- package/dist/fileRepository/api/tests/integration/uploadClip.integration.test.d.ts +2 -0
- package/dist/fileRepository/api/tests/integration/uploadClip.integration.test.d.ts.map +1 -0
- package/dist/fileRepository/api/tests/integration/uploadFile.integration.test.d.ts +2 -0
- package/dist/fileRepository/api/tests/integration/uploadFile.integration.test.d.ts.map +1 -0
- package/dist/fileRepository/api/tests/integration/uploadImage.integration.test.d.ts +2 -0
- package/dist/fileRepository/api/tests/integration/uploadImage.integration.test.d.ts.map +1 -0
- package/dist/fileRepository/api/tests/integration/uploadVideo.integration.test.d.ts +2 -0
- package/dist/fileRepository/api/tests/integration/uploadVideo.integration.test.d.ts.map +1 -0
- package/dist/index.cjs.js +289 -414
- package/dist/index.esm.js +290 -415
- package/dist/index.umd.js +3 -3
- package/dist/invitationRepository/api/tests/integration/cancelInvitation.integration.test.d.ts +2 -0
- package/dist/invitationRepository/api/tests/integration/cancelInvitation.integration.test.d.ts.map +1 -0
- package/dist/invitationRepository/observers/tests/integrations/getInvitations.integration.test.d.ts +2 -0
- package/dist/invitationRepository/observers/tests/integrations/getInvitations.integration.test.d.ts.map +1 -0
- package/dist/invitationRepository/observers/tests/integrations/getInvitations.noUser.integration.test.d.ts +2 -0
- package/dist/invitationRepository/observers/tests/integrations/getInvitations.noUser.integration.test.d.ts.map +1 -0
- package/dist/invitationRepository/observers/tests/integrations/getMyCommunityInvitations.integration.test.d.ts +2 -0
- package/dist/invitationRepository/observers/tests/integrations/getMyCommunityInvitations.integration.test.d.ts.map +1 -0
- package/dist/liveReactionRepository/api/tests/integration/createReaction.integration.test.d.ts +2 -0
- package/dist/liveReactionRepository/api/tests/integration/createReaction.integration.test.d.ts.map +1 -0
- package/dist/liveReactionRepository/events/tests/integration/onLiveReactionCreated.integration.test.d.ts +2 -0
- package/dist/liveReactionRepository/events/tests/integration/onLiveReactionCreated.integration.test.d.ts.map +1 -0
- package/dist/liveReactionRepository/observers/tests/integrations/getReactions.integration.test.d.ts +2 -0
- package/dist/liveReactionRepository/observers/tests/integrations/getReactions.integration.test.d.ts.map +1 -0
- package/dist/liveReactionRepository/observers/tests/integrations/getReactions.noUser.integration.test.d.ts +2 -0
- package/dist/liveReactionRepository/observers/tests/integrations/getReactions.noUser.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/api/tests/integration/createMessage.integration.test.d.ts +2 -0
- package/dist/messageRepository/api/tests/integration/createMessage.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/api/tests/integration/deleteMessage.integration.test.d.ts +2 -0
- package/dist/messageRepository/api/tests/integration/deleteMessage.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/api/tests/integration/editMessage.integration.test.d.ts +2 -0
- package/dist/messageRepository/api/tests/integration/editMessage.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/api/tests/integration/flagMessage.integration.test.d.ts +2 -0
- package/dist/messageRepository/api/tests/integration/flagMessage.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/api/tests/integration/getDeliveredUsers.integration.test.d.ts +2 -0
- package/dist/messageRepository/api/tests/integration/getDeliveredUsers.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/api/tests/integration/getReadUsers.integration.test.d.ts +2 -0
- package/dist/messageRepository/api/tests/integration/getReadUsers.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/api/tests/integration/isMessageFlaggedByMe.integration.test.d.ts +2 -0
- package/dist/messageRepository/api/tests/integration/isMessageFlaggedByMe.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/api/tests/integration/markAsDelivered.integration.test.d.ts +2 -0
- package/dist/messageRepository/api/tests/integration/markAsDelivered.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/api/tests/integration/queryMessages.integration.test.d.ts +2 -0
- package/dist/messageRepository/api/tests/integration/queryMessages.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/api/tests/integration/softDeleteMessage.integration.test.d.ts +2 -0
- package/dist/messageRepository/api/tests/integration/softDeleteMessage.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/api/tests/integration/unflagMessage.integration.test.d.ts +2 -0
- package/dist/messageRepository/api/tests/integration/unflagMessage.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/api/tests/integration/updateMessage.integration.test.d.ts +2 -0
- package/dist/messageRepository/api/tests/integration/updateMessage.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/observers/tests/integration/getMessage.integration.test.d.ts +2 -0
- package/dist/messageRepository/observers/tests/integration/getMessage.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/observers/tests/integration/getMessages.integration.test.d.ts +2 -0
- package/dist/messageRepository/observers/tests/integration/getMessages.integration.test.d.ts.map +1 -0
- package/dist/notificationTray/api/tests/integration/markItemsSeen.integration.test.d.ts +2 -0
- package/dist/notificationTray/api/tests/integration/markItemsSeen.integration.test.d.ts.map +1 -0
- package/dist/notificationTray/api/tests/integration/markTraySeen.integration.test.d.ts +2 -0
- package/dist/notificationTray/api/tests/integration/markTraySeen.integration.test.d.ts.map +1 -0
- package/dist/notificationTray/events/tests/integrations/onNotificationTraySeenUpdated.integration.test.d.ts +2 -0
- package/dist/notificationTray/events/tests/integrations/onNotificationTraySeenUpdated.integration.test.d.ts.map +1 -0
- package/dist/notificationTray/internalApi/tests/integration/getNotificationTraySeen.integration.test.d.ts +2 -0
- package/dist/notificationTray/internalApi/tests/integration/getNotificationTraySeen.integration.test.d.ts.map +1 -0
- package/dist/notificationTray/observers/tests/integrations/getNotificationTrayItems.integration.test.d.ts +2 -0
- package/dist/notificationTray/observers/tests/integrations/getNotificationTrayItems.integration.test.d.ts.map +1 -0
- package/dist/notificationTray/observers/tests/integrations/getNotificationTraySeen.integration.test.d.ts +2 -0
- package/dist/notificationTray/observers/tests/integrations/getNotificationTraySeen.integration.test.d.ts.map +1 -0
- package/dist/pollRepository/api/tests/integration/closePoll.integration.test.d.ts +2 -0
- package/dist/pollRepository/api/tests/integration/closePoll.integration.test.d.ts.map +1 -0
- package/dist/pollRepository/api/tests/integration/createPoll.integration.test.d.ts +2 -0
- package/dist/pollRepository/api/tests/integration/createPoll.integration.test.d.ts.map +1 -0
- package/dist/pollRepository/api/tests/integration/deletePoll.integration.test.d.ts +2 -0
- package/dist/pollRepository/api/tests/integration/deletePoll.integration.test.d.ts.map +1 -0
- package/dist/pollRepository/api/tests/integration/getPoll.integration.test.d.ts +2 -0
- package/dist/pollRepository/api/tests/integration/getPoll.integration.test.d.ts.map +1 -0
- package/dist/pollRepository/api/tests/integration/unvotePoll.integration.test.d.ts +2 -0
- package/dist/pollRepository/api/tests/integration/unvotePoll.integration.test.d.ts.map +1 -0
- package/dist/pollRepository/api/tests/integration/votePoll.integration.test.d.ts +2 -0
- package/dist/pollRepository/api/tests/integration/votePoll.integration.test.d.ts.map +1 -0
- package/dist/pollRepository/observers/tests/integrations/getPoll.integration.test.d.ts +2 -0
- package/dist/pollRepository/observers/tests/integrations/getPoll.integration.test.d.ts.map +1 -0
- package/dist/postRepository/api/createAudioPost.d.ts.map +1 -1
- package/dist/postRepository/api/createClipPost.d.ts.map +1 -1
- package/dist/postRepository/api/createMixedMediaPost.d.ts.map +1 -1
- package/dist/postRepository/api/createPost.d.ts.map +1 -1
- package/dist/postRepository/api/deletePost.d.ts.map +1 -1
- package/dist/postRepository/api/editPost.d.ts.map +1 -1
- package/dist/postRepository/api/getPost.d.ts.map +1 -1
- package/dist/postRepository/api/pinProduct.d.ts.map +1 -1
- package/dist/postRepository/api/tests/integration/approvePost.integration.test.d.ts +2 -0
- package/dist/postRepository/api/tests/integration/approvePost.integration.test.d.ts.map +1 -0
- package/dist/postRepository/api/tests/integration/createOtherPosts.integration.test.d.ts +2 -0
- package/dist/postRepository/api/tests/integration/createOtherPosts.integration.test.d.ts.map +1 -0
- package/dist/postRepository/api/tests/integration/declinePost.integration.test.d.ts +2 -0
- package/dist/postRepository/api/tests/integration/declinePost.integration.test.d.ts.map +1 -0
- package/dist/postRepository/api/tests/integration/deletePost.integration.test.d.ts +2 -0
- package/dist/postRepository/api/tests/integration/deletePost.integration.test.d.ts.map +1 -0
- package/dist/postRepository/api/tests/integration/editPost.integration.test.d.ts +2 -0
- package/dist/postRepository/api/tests/integration/editPost.integration.test.d.ts.map +1 -0
- package/dist/postRepository/api/tests/integration/flagPost.integration.test.d.ts +2 -0
- package/dist/postRepository/api/tests/integration/flagPost.integration.test.d.ts.map +1 -0
- package/dist/postRepository/api/tests/integration/getPostByIds.integration.test.d.ts +2 -0
- package/dist/postRepository/api/tests/integration/getPostByIds.integration.test.d.ts.map +1 -0
- package/dist/postRepository/api/tests/integration/observerCollections.integration.test.d.ts +2 -0
- package/dist/postRepository/api/tests/integration/observerCollections.integration.test.d.ts.map +1 -0
- package/dist/postRepository/api/unpinProduct.d.ts.map +1 -1
- package/dist/postRepository/api/updateProductTags.d.ts.map +1 -1
- package/dist/postRepository/observers/utils.d.ts.map +1 -1
- package/dist/reactionRepository/api/tests/integration/addReaction.integration.test.d.ts +2 -0
- package/dist/reactionRepository/api/tests/integration/addReaction.integration.test.d.ts.map +1 -0
- package/dist/reactionRepository/api/tests/integration/queryReactions.integration.test.d.ts +2 -0
- package/dist/reactionRepository/api/tests/integration/queryReactions.integration.test.d.ts.map +1 -0
- package/dist/reactionRepository/api/tests/integration/queryReactor.integration.test.d.ts +2 -0
- package/dist/reactionRepository/api/tests/integration/queryReactor.integration.test.d.ts.map +1 -0
- package/dist/reactionRepository/api/tests/integration/removeReaction.integration.test.d.ts +2 -0
- package/dist/reactionRepository/api/tests/integration/removeReaction.integration.test.d.ts.map +1 -0
- package/dist/reactionRepository/observers/tests/integrations/getReactions.integration.test.d.ts +2 -0
- package/dist/reactionRepository/observers/tests/integrations/getReactions.integration.test.d.ts.map +1 -0
- package/dist/report/api/tests/integration/createReport.integration.test.d.ts +2 -0
- package/dist/report/api/tests/integration/createReport.integration.test.d.ts.map +1 -0
- package/dist/report/api/tests/integration/deleteReport.integration.test.d.ts +2 -0
- package/dist/report/api/tests/integration/deleteReport.integration.test.d.ts.map +1 -0
- package/dist/report/api/tests/integration/isReportedByMe.integration.test.d.ts +2 -0
- package/dist/report/api/tests/integration/isReportedByMe.integration.test.d.ts.map +1 -0
- package/dist/role/api/tests/integration/getRole.integration.test.d.ts +2 -0
- package/dist/role/api/tests/integration/getRole.integration.test.d.ts.map +1 -0
- package/dist/role/api/tests/integration/queryRoles.integration.test.d.ts +2 -0
- package/dist/role/api/tests/integration/queryRoles.integration.test.d.ts.map +1 -0
- package/dist/roomPresenceRepository/api/tests/integration/getRoomOnlineUsers.integration.test.d.ts +2 -0
- package/dist/roomPresenceRepository/api/tests/integration/getRoomOnlineUsers.integration.test.d.ts.map +1 -0
- package/dist/roomPresenceRepository/api/tests/integration/getRoomUserCount.integration.test.d.ts +2 -0
- package/dist/roomPresenceRepository/api/tests/integration/getRoomUserCount.integration.test.d.ts.map +1 -0
- package/dist/roomPresenceRepository/api/tests/integration/startHeartbeat.integration.test.d.ts +2 -0
- package/dist/roomPresenceRepository/api/tests/integration/startHeartbeat.integration.test.d.ts.map +1 -0
- package/dist/roomPresenceRepository/api/tests/integration/stopHeartbeat.integration.test.d.ts +2 -0
- package/dist/roomPresenceRepository/api/tests/integration/stopHeartbeat.integration.test.d.ts.map +1 -0
- package/dist/roomRepository/api/analytics/WatchSessionStorage.d.ts +1 -1
- package/dist/roomRepository/api/analytics/WatchSessionStorage.d.ts.map +1 -1
- package/dist/roomRepository/api/tests/integration/createRoom.integration.test.d.ts +2 -0
- package/dist/roomRepository/api/tests/integration/createRoom.integration.test.d.ts.map +1 -0
- package/dist/roomRepository/api/tests/integration/deleteRoom.integration.test.d.ts +2 -0
- package/dist/roomRepository/api/tests/integration/deleteRoom.integration.test.d.ts.map +1 -0
- package/dist/roomRepository/api/tests/integration/getBroadcasterData.integration.test.d.ts +2 -0
- package/dist/roomRepository/api/tests/integration/getBroadcasterData.integration.test.d.ts.map +1 -0
- package/dist/roomRepository/api/tests/integration/getRecordedUrl.integration.test.d.ts +2 -0
- package/dist/roomRepository/api/tests/integration/getRecordedUrl.integration.test.d.ts.map +1 -0
- package/dist/roomRepository/api/tests/integration/leaveRoom.integration.test.d.ts +2 -0
- package/dist/roomRepository/api/tests/integration/leaveRoom.integration.test.d.ts.map +1 -0
- package/dist/roomRepository/api/tests/integration/removeParticipant.integration.test.d.ts +2 -0
- package/dist/roomRepository/api/tests/integration/removeParticipant.integration.test.d.ts.map +1 -0
- package/dist/roomRepository/api/tests/integration/roomAnalytics.integration.test.d.ts +2 -0
- package/dist/roomRepository/api/tests/integration/roomAnalytics.integration.test.d.ts.map +1 -0
- package/dist/roomRepository/api/tests/integration/setup.d.ts +12 -0
- package/dist/roomRepository/api/tests/integration/setup.d.ts.map +1 -1
- package/dist/roomRepository/api/tests/integration/stopRoom.integration.test.d.ts +2 -0
- package/dist/roomRepository/api/tests/integration/stopRoom.integration.test.d.ts.map +1 -0
- package/dist/roomRepository/api/tests/integration/updateRoom.integration.test.d.ts +2 -0
- package/dist/roomRepository/api/tests/integration/updateRoom.integration.test.d.ts.map +1 -0
- package/dist/roomRepository/observers/tests/integration/getRoom.integration.test.d.ts +2 -0
- package/dist/roomRepository/observers/tests/integration/getRoom.integration.test.d.ts.map +1 -0
- package/dist/roomRepository/observers/tests/integration/getRooms.integration.test.d.ts +2 -0
- package/dist/roomRepository/observers/tests/integration/getRooms.integration.test.d.ts.map +1 -0
- package/dist/roomRepository/observers/tests/integration/observerUtils.integration.test.d.ts +2 -0
- package/dist/roomRepository/observers/tests/integration/observerUtils.integration.test.d.ts.map +1 -0
- package/dist/roomRepository/observers/tests/integration/setup.d.ts +2 -0
- package/dist/roomRepository/observers/tests/integration/setup.d.ts.map +1 -0
- package/dist/storyRepository/api/tests/integration/createImageStory.integration.test.d.ts +2 -0
- package/dist/storyRepository/api/tests/integration/createImageStory.integration.test.d.ts.map +1 -0
- package/dist/storyRepository/api/tests/integration/createVideoStory.integration.test.d.ts +2 -0
- package/dist/storyRepository/api/tests/integration/createVideoStory.integration.test.d.ts.map +1 -0
- package/dist/storyRepository/api/tests/integration/hardDeleteStory.integration.test.d.ts +2 -0
- package/dist/storyRepository/api/tests/integration/hardDeleteStory.integration.test.d.ts.map +1 -0
- package/dist/storyRepository/api/tests/integration/softDeleteStory.integration.test.d.ts +2 -0
- package/dist/storyRepository/api/tests/integration/softDeleteStory.integration.test.d.ts.map +1 -0
- package/dist/storyRepository/internalApi/tests/integration/getStoryByStoryId.integration.test.d.ts +2 -0
- package/dist/storyRepository/internalApi/tests/integration/getStoryByStoryId.integration.test.d.ts.map +1 -0
- package/dist/storyRepository/observers/tests/integration/getActiveStoriesByTarget.integration.test.d.ts +2 -0
- package/dist/storyRepository/observers/tests/integration/getActiveStoriesByTarget.integration.test.d.ts.map +1 -0
- package/dist/storyRepository/observers/tests/integration/getGlobalStoryTargets.integration.test.d.ts +2 -0
- package/dist/storyRepository/observers/tests/integration/getGlobalStoryTargets.integration.test.d.ts.map +1 -0
- package/dist/storyRepository/observers/tests/integration/getStoriesByTargetIds.integration.test.d.ts +2 -0
- package/dist/storyRepository/observers/tests/integration/getStoriesByTargetIds.integration.test.d.ts.map +1 -0
- package/dist/storyRepository/observers/tests/integration/getStoryByStoryId.integration.test.d.ts +2 -0
- package/dist/storyRepository/observers/tests/integration/getStoryByStoryId.integration.test.d.ts.map +1 -0
- package/dist/storyRepository/observers/tests/integration/getTargetById.integration.test.d.ts +2 -0
- package/dist/storyRepository/observers/tests/integration/getTargetById.integration.test.d.ts.map +1 -0
- package/dist/storyRepository/observers/tests/integration/getTargetsByTargetIds.integration.test.d.ts +2 -0
- package/dist/storyRepository/observers/tests/integration/getTargetsByTargetIds.integration.test.d.ts.map +1 -0
- package/dist/streamRepository/api/tests/integration/createStream.integration.test.d.ts +2 -0
- package/dist/streamRepository/api/tests/integration/createStream.integration.test.d.ts.map +1 -0
- package/dist/streamRepository/api/tests/integration/deleteStream.integration.test.d.ts +2 -0
- package/dist/streamRepository/api/tests/integration/deleteStream.integration.test.d.ts.map +1 -0
- package/dist/streamRepository/api/tests/integration/disposeStream.integration.test.d.ts +2 -0
- package/dist/streamRepository/api/tests/integration/disposeStream.integration.test.d.ts.map +1 -0
- package/dist/streamRepository/api/tests/integration/editStream.integration.test.d.ts +2 -0
- package/dist/streamRepository/api/tests/integration/editStream.integration.test.d.ts.map +1 -0
- package/dist/streamRepository/api/tests/integration/updateStream.integration.test.d.ts +2 -0
- package/dist/streamRepository/api/tests/integration/updateStream.integration.test.d.ts.map +1 -0
- package/dist/streamRepository/observers/tests/integration/getStreamById.integration.test.d.ts +2 -0
- package/dist/streamRepository/observers/tests/integration/getStreamById.integration.test.d.ts.map +1 -0
- package/dist/subChannelRepository/api/deleteSubChannel.d.ts.map +1 -1
- package/dist/subChannelRepository/api/getSubChannel.d.ts.map +1 -1
- package/dist/subChannelRepository/api/tests/integration/createSubChannel.integration.test.d.ts +2 -0
- package/dist/subChannelRepository/api/tests/integration/createSubChannel.integration.test.d.ts.map +1 -0
- package/dist/subChannelRepository/api/tests/integration/deleteSubChannel.integration.test.d.ts +2 -0
- package/dist/subChannelRepository/api/tests/integration/deleteSubChannel.integration.test.d.ts.map +1 -0
- package/dist/subChannelRepository/api/tests/integration/getSubChannel.integration.test.d.ts +2 -0
- package/dist/subChannelRepository/api/tests/integration/getSubChannel.integration.test.d.ts.map +1 -0
- package/dist/subChannelRepository/api/tests/integration/getSubChannels.integration.test.d.ts +2 -0
- package/dist/subChannelRepository/api/tests/integration/getSubChannels.integration.test.d.ts.map +1 -0
- package/dist/subChannelRepository/api/tests/integration/hardDeleteSubChannel.integration.test.d.ts +2 -0
- package/dist/subChannelRepository/api/tests/integration/hardDeleteSubChannel.integration.test.d.ts.map +1 -0
- package/dist/subChannelRepository/api/tests/integration/markAsReadBySegment.integration.test.d.ts +2 -0
- package/dist/subChannelRepository/api/tests/integration/markAsReadBySegment.integration.test.d.ts.map +1 -0
- package/dist/subChannelRepository/api/tests/integration/querySubChannels.integration.test.d.ts +2 -0
- package/dist/subChannelRepository/api/tests/integration/querySubChannels.integration.test.d.ts.map +1 -0
- package/dist/subChannelRepository/api/tests/integration/readingAPI.integration.test.d.ts +2 -0
- package/dist/subChannelRepository/api/tests/integration/readingAPI.integration.test.d.ts.map +1 -0
- package/dist/subChannelRepository/api/tests/integration/softDeleteSubChannel.integration.test.d.ts +2 -0
- package/dist/subChannelRepository/api/tests/integration/softDeleteSubChannel.integration.test.d.ts.map +1 -0
- package/dist/subChannelRepository/api/tests/integration/startReadingAPI.integration.test.d.ts +2 -0
- package/dist/subChannelRepository/api/tests/integration/startReadingAPI.integration.test.d.ts.map +1 -0
- package/dist/subChannelRepository/api/tests/integration/stopReadingAPI.integration.test.d.ts +2 -0
- package/dist/subChannelRepository/api/tests/integration/stopReadingAPI.integration.test.d.ts.map +1 -0
- package/dist/subChannelRepository/api/tests/integration/updateSubChannel.integration.test.d.ts +2 -0
- package/dist/subChannelRepository/api/tests/integration/updateSubChannel.integration.test.d.ts.map +1 -0
- package/dist/subChannelRepository/observers/getSubChannel.d.ts.map +1 -1
- package/dist/subChannelRepository/observers/tests/integrations/getSubChannel.integration.test.d.ts +2 -0
- package/dist/subChannelRepository/observers/tests/integrations/getSubChannel.integration.test.d.ts.map +1 -0
- package/dist/subChannelRepository/observers/tests/integrations/getSubChannels.integration.test.d.ts +2 -0
- package/dist/subChannelRepository/observers/tests/integrations/getSubChannels.integration.test.d.ts.map +1 -0
- package/dist/userRepository/api/queryBlockedUsers.d.ts.map +1 -1
- package/dist/userRepository/api/tests/integration/flagUser.integration.test.d.ts +2 -0
- package/dist/userRepository/api/tests/integration/flagUser.integration.test.d.ts.map +1 -0
- package/dist/userRepository/api/tests/integration/getAllBlockedUsers.integration.test.d.ts +2 -0
- package/dist/userRepository/api/tests/integration/getAllBlockedUsers.integration.test.d.ts.map +1 -0
- package/dist/userRepository/api/tests/integration/getUser.integration.test.d.ts +2 -0
- package/dist/userRepository/api/tests/integration/getUser.integration.test.d.ts.map +1 -0
- package/dist/userRepository/api/tests/integration/getUserByIds.integration.test.d.ts +2 -0
- package/dist/userRepository/api/tests/integration/getUserByIds.integration.test.d.ts.map +1 -0
- package/dist/userRepository/api/tests/integration/isUserFlaggedByMe.integration.test.d.ts +2 -0
- package/dist/userRepository/api/tests/integration/isUserFlaggedByMe.integration.test.d.ts.map +1 -0
- package/dist/userRepository/api/tests/integration/queryBlockedUsers.integration.test.d.ts +2 -0
- package/dist/userRepository/api/tests/integration/queryBlockedUsers.integration.test.d.ts.map +1 -0
- package/dist/userRepository/api/tests/integration/queryUsers.integration.test.d.ts +2 -0
- package/dist/userRepository/api/tests/integration/queryUsers.integration.test.d.ts.map +1 -0
- package/dist/userRepository/api/tests/integration/unflagUser.integration.test.d.ts +2 -0
- package/dist/userRepository/api/tests/integration/unflagUser.integration.test.d.ts.map +1 -0
- package/dist/userRepository/api/tests/integration/updateUser.integration.test.d.ts +2 -0
- package/dist/userRepository/api/tests/integration/updateUser.integration.test.d.ts.map +1 -0
- package/dist/userRepository/observers/tests/integrations/enums.integration.test.d.ts +2 -0
- package/dist/userRepository/observers/tests/integrations/enums.integration.test.d.ts.map +1 -0
- package/dist/userRepository/observers/tests/integrations/getBlockedUsers.integration.test.d.ts +2 -0
- package/dist/userRepository/observers/tests/integrations/getBlockedUsers.integration.test.d.ts.map +1 -0
- package/dist/userRepository/observers/tests/integrations/getReachedUsers.integration.test.d.ts +2 -0
- package/dist/userRepository/observers/tests/integrations/getReachedUsers.integration.test.d.ts.map +1 -0
- package/dist/userRepository/observers/tests/integrations/getUser.integration.test.d.ts +2 -0
- package/dist/userRepository/observers/tests/integrations/getUser.integration.test.d.ts.map +1 -0
- package/dist/userRepository/observers/tests/integrations/getUsers.integration.test.d.ts +2 -0
- package/dist/userRepository/observers/tests/integrations/getUsers.integration.test.d.ts.map +1 -0
- package/dist/userRepository/observers/tests/integrations/searchUserByDisplayName.integration.test.d.ts +2 -0
- package/dist/userRepository/observers/tests/integrations/searchUserByDisplayName.integration.test.d.ts.map +1 -0
- package/dist/utils/tests/dummy/stream.d.ts +4 -11
- package/dist/utils/tests/dummy/stream.d.ts.map +1 -1
- package/package.json +3 -3
- package/dist/@types/domains/notificationSettings.d.ts +0 -101
- package/dist/@types/domains/notificationSettings.d.ts.map +0 -1
- package/dist/client/api/notifications.d.ts +0 -27
- package/dist/client/api/notifications.d.ts.map +0 -1
package/dist/index.cjs.js
CHANGED
|
@@ -276,43 +276,10 @@ exports.AnalyticsSourceTypeEnum = void 0;
|
|
|
276
276
|
AnalyticsSourceTypeEnum["ROOM"] = "room";
|
|
277
277
|
})(exports.AnalyticsSourceTypeEnum || (exports.AnalyticsSourceTypeEnum = {}));
|
|
278
278
|
|
|
279
|
-
exports.UserNotificationModuleNameEnum = void 0;
|
|
280
|
-
(function (UserNotificationModuleNameEnum) {
|
|
281
|
-
UserNotificationModuleNameEnum["CHAT"] = "chat";
|
|
282
|
-
UserNotificationModuleNameEnum["SOCIAL"] = "social";
|
|
283
|
-
UserNotificationModuleNameEnum["VIDEO_STREAMING"] = "video-streaming";
|
|
284
|
-
})(exports.UserNotificationModuleNameEnum || (exports.UserNotificationModuleNameEnum = {}));
|
|
285
|
-
exports.CommunityNotificationEventNameEnum = void 0;
|
|
286
|
-
(function (CommunityNotificationEventNameEnum) {
|
|
287
|
-
CommunityNotificationEventNameEnum["POST_CREATED"] = "post.created";
|
|
288
|
-
CommunityNotificationEventNameEnum["POST_REACTED"] = "post.reacted";
|
|
289
|
-
CommunityNotificationEventNameEnum["COMMENT_CREATED"] = "comment.created";
|
|
290
|
-
CommunityNotificationEventNameEnum["COMMENT_REPLIED"] = "comment.replied";
|
|
291
|
-
CommunityNotificationEventNameEnum["COMMENT_REACTED"] = "comment.reacted";
|
|
292
|
-
CommunityNotificationEventNameEnum["STORY_CREATED"] = "story.created";
|
|
293
|
-
CommunityNotificationEventNameEnum["STORY_REACTED"] = "story.reacted";
|
|
294
|
-
CommunityNotificationEventNameEnum["STORY_COMMENT_CREATED"] = "story-comment.created";
|
|
295
|
-
CommunityNotificationEventNameEnum["LIVESTREAM_START"] = "video-streaming.didStart";
|
|
296
|
-
})(exports.CommunityNotificationEventNameEnum || (exports.CommunityNotificationEventNameEnum = {}));
|
|
297
|
-
exports.NotificationSettingsLevelEnum = void 0;
|
|
298
|
-
(function (NotificationSettingsLevelEnum) {
|
|
299
|
-
NotificationSettingsLevelEnum["USER"] = "user";
|
|
300
|
-
NotificationSettingsLevelEnum["COMMUNITY"] = "community";
|
|
301
|
-
NotificationSettingsLevelEnum["CHANNEL"] = "channel";
|
|
302
|
-
})(exports.NotificationSettingsLevelEnum || (exports.NotificationSettingsLevelEnum = {}));
|
|
303
|
-
/**
|
|
304
|
-
* `NOT` variant is intentionally excluded from public API (internal server-side use only).
|
|
305
|
-
*/
|
|
306
|
-
exports.NotificationRolesFilterTypeEnum = void 0;
|
|
307
|
-
(function (NotificationRolesFilterTypeEnum) {
|
|
308
|
-
NotificationRolesFilterTypeEnum["ALL"] = "all";
|
|
309
|
-
NotificationRolesFilterTypeEnum["ONLY"] = "only";
|
|
310
|
-
})(exports.NotificationRolesFilterTypeEnum || (exports.NotificationRolesFilterTypeEnum = {}));
|
|
311
|
-
|
|
312
279
|
function getVersion() {
|
|
313
280
|
try {
|
|
314
|
-
// the string ''v7.
|
|
315
|
-
return 'v7.
|
|
281
|
+
// the string ''v7.19.0-cjs'' should be replaced by actual value by @rollup/plugin-replace
|
|
282
|
+
return 'v7.19.0-cjs';
|
|
316
283
|
}
|
|
317
284
|
catch (error) {
|
|
318
285
|
return '__dev__';
|
|
@@ -4808,12 +4775,7 @@ var MqttError;
|
|
|
4808
4775
|
MqttError[MqttError["NOT_AUTHORIZED"] = 135] = "NOT_AUTHORIZED";
|
|
4809
4776
|
})(MqttError || (MqttError = {}));
|
|
4810
4777
|
function getMqttOptions(params) {
|
|
4811
|
-
return Object.assign({ clean: false, clientId: `mqttjs_ + ${Math.random().toString(16).substring(2, 10)}`, protocolId: 'MQTT', protocolVersion: 4, reconnectPeriod: RETRY_BASE_TIMEOUT,
|
|
4812
|
-
topic: 'WillMsg',
|
|
4813
|
-
payload: 'Connection Closed abnormally..!',
|
|
4814
|
-
qos: 0,
|
|
4815
|
-
retain: false,
|
|
4816
|
-
}, resubscribe: true }, params);
|
|
4778
|
+
return Object.assign({ clean: false, clientId: `mqttjs_ + ${Math.random().toString(16).substring(2, 10)}`, protocolId: 'MQTT', protocolVersion: 4, reconnectPeriod: RETRY_BASE_TIMEOUT, resubscribe: true }, params);
|
|
4817
4779
|
}
|
|
4818
4780
|
/**
|
|
4819
4781
|
* Creates a pre-configured socket.io instance
|
|
@@ -5821,6 +5783,7 @@ const getSubChannel$1 = async (subChannelId) => {
|
|
|
5821
5783
|
};
|
|
5822
5784
|
}
|
|
5823
5785
|
catch (error) {
|
|
5786
|
+
/* c8 ignore next */
|
|
5824
5787
|
if (checkIfShouldGoesToTombstone(error === null || error === void 0 ? void 0 : error.code)) {
|
|
5825
5788
|
pushToTombstone('subChannel', subChannelId);
|
|
5826
5789
|
}
|
|
@@ -6067,31 +6030,33 @@ const preUpdateChannelCache = (rawPayload, options = { isMessagePreviewUpdated:
|
|
|
6067
6030
|
const updateChannelUnread = ({ currentUserId, channels, channelUsers, }) => {
|
|
6068
6031
|
const channelsUnread = [];
|
|
6069
6032
|
for (let i = 0; i < channels.length; i += 1) {
|
|
6070
|
-
|
|
6071
|
-
|
|
6072
|
-
|
|
6073
|
-
|
|
6074
|
-
|
|
6075
|
-
|
|
6076
|
-
|
|
6077
|
-
|
|
6078
|
-
|
|
6079
|
-
|
|
6080
|
-
|
|
6081
|
-
|
|
6082
|
-
|
|
6083
|
-
|
|
6084
|
-
|
|
6085
|
-
|
|
6086
|
-
|
|
6087
|
-
|
|
6088
|
-
|
|
6089
|
-
|
|
6090
|
-
|
|
6091
|
-
|
|
6092
|
-
|
|
6033
|
+
if (isUnreadCountSupport(channels[i])) {
|
|
6034
|
+
const cacheKey = ['channelUnread', 'get', channels[i].channelId];
|
|
6035
|
+
const channelUser = channelUsers.find(channelUser => channelUser.channelId === channels[i].channelId && channelUser.userId === currentUserId);
|
|
6036
|
+
let unreadCount = 0;
|
|
6037
|
+
let readToSegment = null;
|
|
6038
|
+
let lastMentionedSegment = null;
|
|
6039
|
+
let isMentioned = false;
|
|
6040
|
+
if (channelUser) {
|
|
6041
|
+
readToSegment = channelUser.readToSegment;
|
|
6042
|
+
lastMentionedSegment = channelUser.lastMentionedSegment;
|
|
6043
|
+
unreadCount = Math.max(channels[i].messageCount - readToSegment, 0);
|
|
6044
|
+
isMentioned = lastMentionedSegment > readToSegment;
|
|
6045
|
+
}
|
|
6046
|
+
const cacheChannelUnread = {
|
|
6047
|
+
channelId: channels[i].channelId,
|
|
6048
|
+
lastSegment: channels[i].messageCount,
|
|
6049
|
+
readToSegment,
|
|
6050
|
+
lastMentionedSegment,
|
|
6051
|
+
unreadCount,
|
|
6052
|
+
isMentioned,
|
|
6053
|
+
isDeleted: channels[i].isDeleted || false,
|
|
6054
|
+
};
|
|
6055
|
+
pushToCache(cacheKey, cacheChannelUnread);
|
|
6056
|
+
channelsUnread.push(cacheChannelUnread);
|
|
6057
|
+
}
|
|
6058
|
+
fireEvent('local.channelUnread.updated', channelsUnread);
|
|
6093
6059
|
}
|
|
6094
|
-
fireEvent('local.channelUnread.updated', channelsUnread);
|
|
6095
6060
|
};
|
|
6096
6061
|
const prepareChannelPayload = async (rawPayload, options = { isMessagePreviewUpdated: true }) => {
|
|
6097
6062
|
const client = getActiveClient();
|
|
@@ -6990,12 +6955,17 @@ getChannelByIds$1.locally = (channelIds) => {
|
|
|
6990
6955
|
client.log('channel/getChannelByIds.locally', channelIds);
|
|
6991
6956
|
if (!client.cache)
|
|
6992
6957
|
return;
|
|
6958
|
+
// queryCache returns undefined only when !cache, but line 92 already guards that case.
|
|
6959
|
+
// The ?. optional chains below are defensive and structurally unreachable after the guard.
|
|
6960
|
+
/* c8 ignore next */
|
|
6993
6961
|
const cached = (_a = queryCache(['channel', 'get'])) === null || _a === void 0 ? void 0 : _a.filter(({ data }) => {
|
|
6994
6962
|
return channelIds.includes(data.channelPublicId);
|
|
6995
6963
|
});
|
|
6964
|
+
/* c8 ignore next */
|
|
6996
6965
|
if (!cached || (cached === null || cached === void 0 ? void 0 : cached.length) < channelIds.length)
|
|
6997
6966
|
return;
|
|
6998
6967
|
const channels = cached.map(({ data }) => data);
|
|
6968
|
+
/* c8 ignore next */
|
|
6999
6969
|
const oldest = (_b = cached.sort((a, b) => (a.cachedAt < b.cachedAt ? -1 : 1))) === null || _b === void 0 ? void 0 : _b[0];
|
|
7000
6970
|
return {
|
|
7001
6971
|
data: channels.map(channel => constructChannelObject(channel)),
|
|
@@ -7191,9 +7161,11 @@ getSubChannels$1.locally = (subChannelIds) => {
|
|
|
7191
7161
|
const cached = subChannelIds
|
|
7192
7162
|
.map(channelId => pullFromCache(['subChannel', 'get', channelId]))
|
|
7193
7163
|
.filter(Boolean);
|
|
7164
|
+
/* c8 ignore next */
|
|
7194
7165
|
if ((cached === null || cached === void 0 ? void 0 : cached.length) < subChannelIds.length)
|
|
7195
7166
|
return;
|
|
7196
7167
|
const subChannels = cached.map(({ data }) => data);
|
|
7168
|
+
/* c8 ignore next */
|
|
7197
7169
|
const oldest = (_a = cached.sort((a, b) => (a.cachedAt < b.cachedAt ? -1 : 1))) === null || _a === void 0 ? void 0 : _a[0];
|
|
7198
7170
|
return {
|
|
7199
7171
|
data: subChannels,
|
|
@@ -10980,140 +10952,6 @@ const setAccessTokenHandler = (accessTokenHandler) => {
|
|
|
10980
10952
|
client.accessTokenHandler = accessTokenHandler;
|
|
10981
10953
|
};
|
|
10982
10954
|
|
|
10983
|
-
function parseRolesFilter(listenFromRoleIds, ignoreFromRoleIds) {
|
|
10984
|
-
if (ignoreFromRoleIds && ignoreFromRoleIds.length > 0) {
|
|
10985
|
-
return { type: 'not', roleIds: ignoreFromRoleIds };
|
|
10986
|
-
}
|
|
10987
|
-
if (listenFromRoleIds && listenFromRoleIds.length > 0) {
|
|
10988
|
-
return { type: exports.NotificationRolesFilterTypeEnum.ONLY, roleIds: listenFromRoleIds };
|
|
10989
|
-
}
|
|
10990
|
-
return { type: exports.NotificationRolesFilterTypeEnum.ALL };
|
|
10991
|
-
}
|
|
10992
|
-
function serializeRolesFilter(rolesFilter) {
|
|
10993
|
-
if ((rolesFilter === null || rolesFilter === void 0 ? void 0 : rolesFilter.type) === exports.NotificationRolesFilterTypeEnum.ONLY) {
|
|
10994
|
-
return { listenFromRoleIds: rolesFilter.roleIds };
|
|
10995
|
-
}
|
|
10996
|
-
return { listenFromRoleIds: [] };
|
|
10997
|
-
}
|
|
10998
|
-
class ChannelNotifications {
|
|
10999
|
-
constructor(channelId) {
|
|
11000
|
-
this.channelId = channelId;
|
|
11001
|
-
}
|
|
11002
|
-
async enable() {
|
|
11003
|
-
const client = getActiveClient();
|
|
11004
|
-
const body = {
|
|
11005
|
-
level: exports.NotificationSettingsLevelEnum.CHANNEL,
|
|
11006
|
-
channelId: this.channelId,
|
|
11007
|
-
isPushNotifiable: true,
|
|
11008
|
-
};
|
|
11009
|
-
await client.http.post('/api/v3/notification/setting', body);
|
|
11010
|
-
}
|
|
11011
|
-
async disable() {
|
|
11012
|
-
const client = getActiveClient();
|
|
11013
|
-
const body = {
|
|
11014
|
-
level: exports.NotificationSettingsLevelEnum.CHANNEL,
|
|
11015
|
-
channelId: this.channelId,
|
|
11016
|
-
isPushNotifiable: false,
|
|
11017
|
-
};
|
|
11018
|
-
await client.http.post('/api/v3/notification/setting', body);
|
|
11019
|
-
}
|
|
11020
|
-
async getSettings() {
|
|
11021
|
-
const client = getActiveClient();
|
|
11022
|
-
const { data } = await client.http.get(`/api/v3/notification/setting?level=channel&channelId=${encodeURIComponent(this.channelId)}`);
|
|
11023
|
-
return { isEnabled: data.isPushNotifiable };
|
|
11024
|
-
}
|
|
11025
|
-
}
|
|
11026
|
-
class UserNotifications {
|
|
11027
|
-
async enable(modules) {
|
|
11028
|
-
var _a;
|
|
11029
|
-
const client = getActiveClient();
|
|
11030
|
-
const notifiableEvents = (_a = modules === null || modules === void 0 ? void 0 : modules.map(module => (Object.assign({ moduleName: module.moduleName, isPushNotifiable: module.isEnabled }, serializeRolesFilter(module.rolesFilter))))) !== null && _a !== void 0 ? _a : [];
|
|
11031
|
-
const body = {
|
|
11032
|
-
level: exports.NotificationSettingsLevelEnum.USER,
|
|
11033
|
-
isPushNotifiable: true,
|
|
11034
|
-
notifiableEvents,
|
|
11035
|
-
};
|
|
11036
|
-
await client.http.post('/api/v3/notification/setting', body);
|
|
11037
|
-
}
|
|
11038
|
-
async disableAllNotifications() {
|
|
11039
|
-
const client = getActiveClient();
|
|
11040
|
-
const body = {
|
|
11041
|
-
level: exports.NotificationSettingsLevelEnum.USER,
|
|
11042
|
-
isPushNotifiable: false,
|
|
11043
|
-
notifiableEvents: [],
|
|
11044
|
-
};
|
|
11045
|
-
await client.http.post('/api/v3/notification/setting', body);
|
|
11046
|
-
}
|
|
11047
|
-
async getSettings() {
|
|
11048
|
-
var _a;
|
|
11049
|
-
const client = getActiveClient();
|
|
11050
|
-
const { data } = await client.http.get(`/api/v3/notification/setting?level=${exports.NotificationSettingsLevelEnum.USER}`);
|
|
11051
|
-
const validModuleNames = Object.values(exports.UserNotificationModuleNameEnum);
|
|
11052
|
-
const modules = ((_a = data.notifiableEvents) !== null && _a !== void 0 ? _a : [])
|
|
11053
|
-
.filter(e => e.moduleName != null && validModuleNames.includes(e.moduleName))
|
|
11054
|
-
.map(e => ({
|
|
11055
|
-
moduleName: e.moduleName,
|
|
11056
|
-
isEnabled: e.isPushNotifiable,
|
|
11057
|
-
rolesFilter: parseRolesFilter(e.listenFromRoleIds, e.ignoreFromRoleIds),
|
|
11058
|
-
}));
|
|
11059
|
-
return { isEnabled: data.isPushNotifiable, modules };
|
|
11060
|
-
}
|
|
11061
|
-
}
|
|
11062
|
-
class CommunityNotifications {
|
|
11063
|
-
constructor(communityId) {
|
|
11064
|
-
this.communityId = communityId;
|
|
11065
|
-
}
|
|
11066
|
-
async enable(events) {
|
|
11067
|
-
var _a;
|
|
11068
|
-
const client = getActiveClient();
|
|
11069
|
-
const notifiableEvents = (_a = events === null || events === void 0 ? void 0 : events.map(event => (Object.assign({ moduleName: exports.UserNotificationModuleNameEnum.SOCIAL, name: event.eventName, isPushNotifiable: event.isEnabled }, serializeRolesFilter(event.rolesFilter))))) !== null && _a !== void 0 ? _a : [];
|
|
11070
|
-
const body = {
|
|
11071
|
-
level: exports.NotificationSettingsLevelEnum.COMMUNITY,
|
|
11072
|
-
communityId: this.communityId,
|
|
11073
|
-
isPushNotifiable: true,
|
|
11074
|
-
notifiableEvents,
|
|
11075
|
-
};
|
|
11076
|
-
await client.http.post('/api/v3/notification/setting', body);
|
|
11077
|
-
}
|
|
11078
|
-
async disable() {
|
|
11079
|
-
const client = getActiveClient();
|
|
11080
|
-
const body = {
|
|
11081
|
-
level: exports.NotificationSettingsLevelEnum.COMMUNITY,
|
|
11082
|
-
communityId: this.communityId,
|
|
11083
|
-
isPushNotifiable: false,
|
|
11084
|
-
notifiableEvents: [],
|
|
11085
|
-
};
|
|
11086
|
-
await client.http.post('/api/v3/notification/setting', body);
|
|
11087
|
-
}
|
|
11088
|
-
async getSettings() {
|
|
11089
|
-
var _a;
|
|
11090
|
-
const client = getActiveClient();
|
|
11091
|
-
const { data } = await client.http.get(`/api/v3/notification/setting?level=${exports.NotificationSettingsLevelEnum.COMMUNITY}&communityId=${encodeURIComponent(this.communityId)}`);
|
|
11092
|
-
const validEventNames = Object.values(exports.CommunityNotificationEventNameEnum);
|
|
11093
|
-
const events = ((_a = data.notifiableEvents) !== null && _a !== void 0 ? _a : [])
|
|
11094
|
-
.filter(e => e.name != null && validEventNames.includes(e.name))
|
|
11095
|
-
.map(e => ({
|
|
11096
|
-
eventName: e.name,
|
|
11097
|
-
isEnabled: e.isPushNotifiable,
|
|
11098
|
-
isNetworkEnabled: e.isNetworkEnabled,
|
|
11099
|
-
rolesFilter: parseRolesFilter(e.listenFromRoleIds, e.ignoreFromRoleIds),
|
|
11100
|
-
}));
|
|
11101
|
-
return { isEnabled: data.isPushNotifiable, events };
|
|
11102
|
-
}
|
|
11103
|
-
}
|
|
11104
|
-
class Notifications {
|
|
11105
|
-
user() {
|
|
11106
|
-
return new UserNotifications();
|
|
11107
|
-
}
|
|
11108
|
-
community(communityId) {
|
|
11109
|
-
return new CommunityNotifications(communityId);
|
|
11110
|
-
}
|
|
11111
|
-
channel(channelId) {
|
|
11112
|
-
return new ChannelNotifications(channelId);
|
|
11113
|
-
}
|
|
11114
|
-
}
|
|
11115
|
-
const notifications = () => new Notifications();
|
|
11116
|
-
|
|
11117
10955
|
/**
|
|
11118
10956
|
* ```js
|
|
11119
10957
|
* import { onChannelMarkerFetched } from '@amityco/ts-sdk-react-native'
|
|
@@ -11497,7 +11335,6 @@ var index$s = /*#__PURE__*/Object.freeze({
|
|
|
11497
11335
|
getCurrentUserType: getCurrentUserType,
|
|
11498
11336
|
setCurrentUserType: setCurrentUserType,
|
|
11499
11337
|
setAccessTokenHandler: setAccessTokenHandler,
|
|
11500
|
-
notifications: notifications,
|
|
11501
11338
|
onConnectionError: onConnectionError,
|
|
11502
11339
|
onClientDisconnected: onClientDisconnected,
|
|
11503
11340
|
onClientBanned: onClientBanned,
|
|
@@ -12947,12 +12784,15 @@ const createChannel = async (bundle) => {
|
|
|
12947
12784
|
const client = getActiveClient();
|
|
12948
12785
|
client.log('user/createChannel', bundle);
|
|
12949
12786
|
let payload;
|
|
12787
|
+
/* c8 ignore next */
|
|
12950
12788
|
if ((bundle === null || bundle === void 0 ? void 0 : bundle.type) === 'conversation') {
|
|
12951
12789
|
payload = await client.http.post('/api/v3/channels/conversation', Object.assign(Object.assign({}, bundle), { isDistinct: true }));
|
|
12952
12790
|
}
|
|
12953
12791
|
else {
|
|
12954
12792
|
const { isPublic } = bundle, restParams = __rest(bundle, ["isPublic"]);
|
|
12955
|
-
payload = await client.http.post('/api/v3/channels', Object.assign(Object.assign({}, restParams), {
|
|
12793
|
+
payload = await client.http.post('/api/v3/channels', Object.assign(Object.assign({}, restParams), {
|
|
12794
|
+
/* c8 ignore next */
|
|
12795
|
+
isPublic: (bundle === null || bundle === void 0 ? void 0 : bundle.type) === 'community' ? isPublic : undefined }));
|
|
12956
12796
|
}
|
|
12957
12797
|
const data = await prepareChannelPayload(payload.data);
|
|
12958
12798
|
const cachedAt = client.cache && Date.now();
|
|
@@ -13530,7 +13370,7 @@ const getWatchSessionStorage = () => {
|
|
|
13530
13370
|
return storageInstance;
|
|
13531
13371
|
};
|
|
13532
13372
|
|
|
13533
|
-
const privateKey = "-----BEGIN PRIVATE KEY-----\
|
|
13373
|
+
const privateKey = "-----BEGIN PRIVATE KEY-----\nMIIEvQIBADANBgkqhkiG9w0BAQEFAASCBKcwggSjAgEAAoIBAQDHo80SecH7FuF2\nhFYnb+l26/VN8UMLXAQFLnxciNTEwkGVFMpdezlH8rU2HtUJL4RETogbAOLVY0XM\njs6sPn8G1nALmh9qeDpUtVqFOVtBHxEZ910TLOtQiunjqJKO5nWdqZ71EC3OFluR\niGQkO84BiIFbv37ub7xl3S8XarbtKoLcyVpkDHi+1wx1pgCAn6gtBUgckPL5NR8j\nLseabl3HAXQfhTCKo4tmOFM2Dxwl1IUMmIJrJg/aIU/U0tj/1Eoo7mG0JcNWX19l\nW3EecCbi0ncCJOrkUdwlBrcjaMayaX/ubEwyUeTGiLdyc4L3GRLHjyK8xgVNXRMH\nbZWJ2a5NAgMBAAECggEASxuE+35zTFO/XydKgmvIGcWL9FbgMlXb7Vcf0nBoG945\nbiz0NVc2paraIhJXc608xbYF3qLmtAE1MVBI0ORyRdBHNxY024l/6H6SH60Ed+uI\nM4ysp5ourY6Vj+DLwpdRiI9YDjqYAQDIUmhNxJP7XPhOMoZI6st+xZQBM34ic/bv\nAMSJm9OZphSp3+qXVkFZztr2mxD2EZSJJLYxi8BCdgM2qhazalbcJ6zDKHCZWVWm\n8RRxDGldyMb/237JxETzP40tAlzOZDmBAbUgEnurDJ93RVDIE3rbZUshwgeQd18a\nem096mWgvB1AIKYgsTAR3pw+V19YWAjq/glP6fz8wQKBgQD/oQq+ukKF0PRgBeM5\ngeTjSwsdGppQLmf5ndujvoiz/TpdjDEPu6R8kigQr1rG2t4K/yfdZoI8RdmJD1al\n3Q7N9hofooSy4rj6E3txzWZCHJjHad2cnCp/O26HiReGAl7wTcfTmNdiFHhZQzm5\nJBkvWAiwuvQMNfEbnXxw6/vIDwKBgQDH7fX8gsc77JLvAWgp1MaQN/sbqVb6JeT1\nFQfR8E/WFCSmzQBtNzd5KgYuCeelwr/8DyYytvN2BzCYZXp73gI1jF3YlW5jVn74\nOY6TwQ095digwo6Z0yuxopdIOApKgAkL9PRKgNrqAf3NAyMua6lOGifzjDojC3KU\nfylQmxMn4wKBgHp2B9O/H0dEBw5JQ8W0+JX6yWQz7mEjGiR2/1W+XXb8hQ1zr709\nw1r6Gb+EghRpnZ3fBpYGGbYOMFx8wKHM+N6qW3F0ReX8v2juFGE8aRSa5oYBrWzt\nU16Idjbv8hj84cZ1PJmdyvDtpYn9rpWHOZl4rxEbPvbqkIsOMyNVqdT5AoGAOSge\nmwIIU2le2FVeohbibXiToWTYKMuMmURZ5/r72AgKMmWJKbAPe+Q3wBG01/7FRBpQ\noU8Ma0HC8s6QJbliiEyIx9JwrJWd1vkdecBHONrtA4ibm/5zD2WcOllLF+FitLhi\n3qnX6+6F0IaFGFBPJrTzlv0P4dTz/OAdv52V7GECgYEA2TttOKBAqWllgOaZOkql\nLVMJVmgR7s6tLi1+cEP8ZcapV9aRbRzTAKXm4f8AEhtlG9F9kCOvHYCYGi6JaiWJ\nZkHjeex3T+eE6Di6y5Bm/Ift5jtVhJ4jCVwHOKTMej79NPUFTJfv8hCo29haBDv6\nRXFrv+T21KCcw8k3sJeJWWQ=\n-----END PRIVATE KEY-----";
|
|
13534
13374
|
/*
|
|
13535
13375
|
* The crypto algorithm used for importing key and signing string
|
|
13536
13376
|
*/
|
|
@@ -15394,10 +15234,10 @@ const createEventResponseSubscriber = (event, callback) => {
|
|
|
15394
15234
|
const filter = (payload) => {
|
|
15395
15235
|
const unpackedPayload = prepareEventResponsePayload(payload);
|
|
15396
15236
|
if (!client.cache) {
|
|
15397
|
-
callback(unpackedPayload);
|
|
15237
|
+
callback(unpackedPayload.eventResponses[0]);
|
|
15398
15238
|
}
|
|
15399
15239
|
else {
|
|
15400
|
-
ingestInCache(unpackedPayload
|
|
15240
|
+
ingestInCache(unpackedPayload);
|
|
15401
15241
|
const eventResponse = pullFromCache([
|
|
15402
15242
|
'eventResponse',
|
|
15403
15243
|
'get',
|
|
@@ -17469,6 +17309,195 @@ getMessage$1.locally = (messageId) => {
|
|
|
17469
17309
|
};
|
|
17470
17310
|
};
|
|
17471
17311
|
|
|
17312
|
+
class ResetTask {
|
|
17313
|
+
constructor(postId, latestCreatedAt, serverCommentCount) {
|
|
17314
|
+
this.postId = postId;
|
|
17315
|
+
this.latestCreatedAt = latestCreatedAt;
|
|
17316
|
+
this.serverCommentCount = serverCommentCount;
|
|
17317
|
+
}
|
|
17318
|
+
}
|
|
17319
|
+
|
|
17320
|
+
// Task to track comment creation
|
|
17321
|
+
class CreateTask {
|
|
17322
|
+
constructor(postId, commentId, createdAt) {
|
|
17323
|
+
this.postId = postId;
|
|
17324
|
+
this.commentId = commentId;
|
|
17325
|
+
this.createdAt = createdAt;
|
|
17326
|
+
}
|
|
17327
|
+
}
|
|
17328
|
+
|
|
17329
|
+
// Task to track comment deletion
|
|
17330
|
+
class DeleteTask {
|
|
17331
|
+
constructor(postId, commentId) {
|
|
17332
|
+
this.postId = postId;
|
|
17333
|
+
this.commentId = commentId;
|
|
17334
|
+
}
|
|
17335
|
+
}
|
|
17336
|
+
|
|
17337
|
+
class CommentChange {
|
|
17338
|
+
constructor(latestCreatedAt, serverCommentCount) {
|
|
17339
|
+
this.latestCommentCreatedAt = latestCreatedAt;
|
|
17340
|
+
this.serverCommentCount = serverCommentCount;
|
|
17341
|
+
this.createdCommentIds = new Set();
|
|
17342
|
+
this.deletedCommentIds = new Set();
|
|
17343
|
+
}
|
|
17344
|
+
}
|
|
17345
|
+
|
|
17346
|
+
class PostCommentCountEngine {
|
|
17347
|
+
constructor() {
|
|
17348
|
+
this.isProcessing = false;
|
|
17349
|
+
this.tasks = [];
|
|
17350
|
+
this.commentChangeTracker = new Map();
|
|
17351
|
+
}
|
|
17352
|
+
queueCommentChangeTask(task) {
|
|
17353
|
+
this.tasks.push(task);
|
|
17354
|
+
if (!this.isProcessing) {
|
|
17355
|
+
this.processCommentChangeTask();
|
|
17356
|
+
}
|
|
17357
|
+
}
|
|
17358
|
+
processCommentChangeTask() {
|
|
17359
|
+
if (this.isProcessing) {
|
|
17360
|
+
return;
|
|
17361
|
+
}
|
|
17362
|
+
this.isProcessing = true;
|
|
17363
|
+
if (this.tasks.length === 0) {
|
|
17364
|
+
this.isProcessing = false;
|
|
17365
|
+
return;
|
|
17366
|
+
}
|
|
17367
|
+
// Process in capped batches, coalescing updates
|
|
17368
|
+
const batch = this.tasks.splice(0, PostCommentCountEngine.BATCH_SIZE);
|
|
17369
|
+
const modifiedPostIds = new Set();
|
|
17370
|
+
batch.forEach(task => {
|
|
17371
|
+
let modified = false;
|
|
17372
|
+
if (task instanceof ResetTask) {
|
|
17373
|
+
modified = this.processResetTaskInternal(task);
|
|
17374
|
+
}
|
|
17375
|
+
else if (task instanceof CreateTask) {
|
|
17376
|
+
modified = this.processCreateTaskInternal(task);
|
|
17377
|
+
}
|
|
17378
|
+
else if (task instanceof DeleteTask) {
|
|
17379
|
+
modified = this.processDeleteTaskInternal(task);
|
|
17380
|
+
}
|
|
17381
|
+
if (modified) {
|
|
17382
|
+
modifiedPostIds.add(task.postId);
|
|
17383
|
+
}
|
|
17384
|
+
});
|
|
17385
|
+
// Publish one update per modified post
|
|
17386
|
+
modifiedPostIds.forEach(postId => {
|
|
17387
|
+
const count = this.computeCommentCount(postId);
|
|
17388
|
+
PostCommentCountEngine.publishUpdate(postId, count);
|
|
17389
|
+
});
|
|
17390
|
+
this.isProcessing = false;
|
|
17391
|
+
// Recurse if more tasks remain
|
|
17392
|
+
if (this.tasks.length > 0) {
|
|
17393
|
+
this.processCommentChangeTask();
|
|
17394
|
+
}
|
|
17395
|
+
}
|
|
17396
|
+
processResetTaskInternal(task) {
|
|
17397
|
+
// Always creates/overwrites tracker
|
|
17398
|
+
this.commentChangeTracker.set(task.postId, new CommentChange(task.latestCreatedAt, task.serverCommentCount));
|
|
17399
|
+
return true;
|
|
17400
|
+
}
|
|
17401
|
+
processCreateTaskInternal(task) {
|
|
17402
|
+
const tracker = this.commentChangeTracker.get(task.postId);
|
|
17403
|
+
if (!tracker)
|
|
17404
|
+
return false; // No tracker, skip
|
|
17405
|
+
if (tracker.createdCommentIds.has(task.commentId))
|
|
17406
|
+
return false; // Deduplication
|
|
17407
|
+
if (task.createdAt <= tracker.latestCommentCreatedAt)
|
|
17408
|
+
return false; // Timestamp filtering
|
|
17409
|
+
tracker.createdCommentIds.add(task.commentId);
|
|
17410
|
+
return true;
|
|
17411
|
+
}
|
|
17412
|
+
processDeleteTaskInternal(task) {
|
|
17413
|
+
const tracker = this.commentChangeTracker.get(task.postId);
|
|
17414
|
+
if (!tracker)
|
|
17415
|
+
return false; // No tracker, skip
|
|
17416
|
+
if (tracker.deletedCommentIds.has(task.commentId))
|
|
17417
|
+
return false; // Deduplication
|
|
17418
|
+
tracker.deletedCommentIds.add(task.commentId);
|
|
17419
|
+
return true;
|
|
17420
|
+
}
|
|
17421
|
+
computeCommentCount(postId) {
|
|
17422
|
+
const tracker = this.commentChangeTracker.get(postId);
|
|
17423
|
+
if (!tracker)
|
|
17424
|
+
return 0;
|
|
17425
|
+
const count = tracker.serverCommentCount + tracker.createdCommentIds.size - tracker.deletedCommentIds.size;
|
|
17426
|
+
return Math.max(0, count);
|
|
17427
|
+
}
|
|
17428
|
+
static publishUpdate(postId, newCount) {
|
|
17429
|
+
var _a;
|
|
17430
|
+
const queryKey = ['post', 'get', postId];
|
|
17431
|
+
mergeInCache(queryKey, {
|
|
17432
|
+
localCommentCount: newCount,
|
|
17433
|
+
});
|
|
17434
|
+
const postPayload = (_a = pullFromCache(queryKey)) === null || _a === void 0 ? void 0 : _a.data;
|
|
17435
|
+
if (!postPayload)
|
|
17436
|
+
return;
|
|
17437
|
+
fireEvent('local.post.updated', {
|
|
17438
|
+
posts: [postPayload],
|
|
17439
|
+
});
|
|
17440
|
+
}
|
|
17441
|
+
}
|
|
17442
|
+
PostCommentCountEngine.BATCH_SIZE = 50;
|
|
17443
|
+
let instance;
|
|
17444
|
+
var PostCommentCountEngine$1 = {
|
|
17445
|
+
getInstance: () => {
|
|
17446
|
+
if (!instance) {
|
|
17447
|
+
instance = new PostCommentCountEngine();
|
|
17448
|
+
}
|
|
17449
|
+
return instance;
|
|
17450
|
+
},
|
|
17451
|
+
};
|
|
17452
|
+
|
|
17453
|
+
const updateStreamReferences = (streams, streamId, postId) => {
|
|
17454
|
+
if (!streamId)
|
|
17455
|
+
return streams;
|
|
17456
|
+
return streams.map(stream => stream.streamId === streamId
|
|
17457
|
+
? Object.assign(Object.assign({}, stream), { referenceType: 'post', referenceId: postId, postId }) : stream);
|
|
17458
|
+
};
|
|
17459
|
+
const preparePostPayload = (payload) => {
|
|
17460
|
+
const { posts: postsData, postChildren, videoStreamings } = payload, postPayload = __rest(payload, ["posts", "postChildren", "videoStreamings"]);
|
|
17461
|
+
// Unpack community payload by mapping payload field to postSetting value.
|
|
17462
|
+
const communitiesWithPostSetting = addPostSetting({ communities: postPayload.communities });
|
|
17463
|
+
// map users with community
|
|
17464
|
+
const mappedCommunityUsers = postPayload.communityUsers.map(communityUser => {
|
|
17465
|
+
const user = postPayload.users.find(user => user.userId === communityUser.userId);
|
|
17466
|
+
return Object.assign(Object.assign({}, communityUser), { user });
|
|
17467
|
+
});
|
|
17468
|
+
const communityWithMembershipStatus = updateMembershipStatus(communitiesWithPostSetting, mappedCommunityUsers);
|
|
17469
|
+
let mappedNewStream = [];
|
|
17470
|
+
// feed type
|
|
17471
|
+
const posts = postsData.map(post => {
|
|
17472
|
+
var _a, _b, _c, _d;
|
|
17473
|
+
const feedType = (_a = postPayload.feeds.find(feed => feed.feedId === post.feedId)) === null || _a === void 0 ? void 0 : _a.feedType;
|
|
17474
|
+
const childPosts = payload.postChildren.filter(children => children.parentPostId === post.postId);
|
|
17475
|
+
if (childPosts.length > 0 && isAmityLivestreamPost(childPosts[0])) {
|
|
17476
|
+
mappedNewStream = updateStreamReferences(videoStreamings, (_b = childPosts[0].data) === null || _b === void 0 ? void 0 : _b.streamId, post.postId);
|
|
17477
|
+
}
|
|
17478
|
+
// --- Computed Comment Count: ResetTask integration ---
|
|
17479
|
+
// Find all comments for this post (referenceType === 'post' && referenceId === postId)
|
|
17480
|
+
const allComments = (payload.comments || []).filter((c) => c.referenceType === 'post' && c.referenceId === post.postId);
|
|
17481
|
+
// Compute latestCreatedAt
|
|
17482
|
+
const latestCreatedAt = allComments.length === 0
|
|
17483
|
+
? new Date().toISOString()
|
|
17484
|
+
: allComments
|
|
17485
|
+
.map(c => c.createdAt)
|
|
17486
|
+
.sort()
|
|
17487
|
+
.at(-1);
|
|
17488
|
+
// Queue ResetTask for this post
|
|
17489
|
+
PostCommentCountEngine$1.getInstance().queueCommentChangeTask(new ResetTask(post.postId, latestCreatedAt, (_c = post.commentsCount) !== null && _c !== void 0 ? _c : 0));
|
|
17490
|
+
return Object.assign(Object.assign({}, post), { childPosts,
|
|
17491
|
+
feedType, localCommentCount: (_d = post.localCommentCount) !== null && _d !== void 0 ? _d : post.commentsCount, pinnedProductId: post === null || post === void 0 ? void 0 : post.pinnedProductId });
|
|
17492
|
+
});
|
|
17493
|
+
return Object.assign(Object.assign({}, postPayload), { postChildren, videoStreamings: mappedNewStream, posts, communities: communityWithMembershipStatus, communityUsers: mappedCommunityUsers });
|
|
17494
|
+
};
|
|
17495
|
+
const prepareSemanticSearchPostPayload = (_a) => {
|
|
17496
|
+
var { searchResult, polls } = _a, postPayload = __rest(_a, ["searchResult", "polls"]);
|
|
17497
|
+
const processedPostPayload = preparePostPayload(postPayload);
|
|
17498
|
+
return Object.assign(Object.assign({}, processedPostPayload), { polls });
|
|
17499
|
+
};
|
|
17500
|
+
|
|
17472
17501
|
/**
|
|
17473
17502
|
* ```js
|
|
17474
17503
|
* import { getPost } from '@amityco/ts-sdk-react-native'
|
|
@@ -17499,7 +17528,7 @@ const getPost$2 = async (postId) => {
|
|
|
17499
17528
|
}
|
|
17500
17529
|
throw error;
|
|
17501
17530
|
}
|
|
17502
|
-
const data =
|
|
17531
|
+
const data = preparePostPayload(payload);
|
|
17503
17532
|
const cachedAt = client.cache && Date.now();
|
|
17504
17533
|
if (client.cache)
|
|
17505
17534
|
ingestInCache(data, { cachedAt });
|
|
@@ -17917,195 +17946,6 @@ removeReaction.optimistically = (referenceType, referenceId, reactionName) => {
|
|
|
17917
17946
|
return !((_d = reaction === null || reaction === void 0 ? void 0 : reaction.myReactions) === null || _d === void 0 ? void 0 : _d.includes(reactionName));
|
|
17918
17947
|
};
|
|
17919
17948
|
|
|
17920
|
-
class ResetTask {
|
|
17921
|
-
constructor(postId, latestCreatedAt, serverCommentCount) {
|
|
17922
|
-
this.postId = postId;
|
|
17923
|
-
this.latestCreatedAt = latestCreatedAt;
|
|
17924
|
-
this.serverCommentCount = serverCommentCount;
|
|
17925
|
-
}
|
|
17926
|
-
}
|
|
17927
|
-
|
|
17928
|
-
// Task to track comment creation
|
|
17929
|
-
class CreateTask {
|
|
17930
|
-
constructor(postId, commentId, createdAt) {
|
|
17931
|
-
this.postId = postId;
|
|
17932
|
-
this.commentId = commentId;
|
|
17933
|
-
this.createdAt = createdAt;
|
|
17934
|
-
}
|
|
17935
|
-
}
|
|
17936
|
-
|
|
17937
|
-
// Task to track comment deletion
|
|
17938
|
-
class DeleteTask {
|
|
17939
|
-
constructor(postId, commentId) {
|
|
17940
|
-
this.postId = postId;
|
|
17941
|
-
this.commentId = commentId;
|
|
17942
|
-
}
|
|
17943
|
-
}
|
|
17944
|
-
|
|
17945
|
-
class CommentChange {
|
|
17946
|
-
constructor(latestCreatedAt, serverCommentCount) {
|
|
17947
|
-
this.latestCommentCreatedAt = latestCreatedAt;
|
|
17948
|
-
this.serverCommentCount = serverCommentCount;
|
|
17949
|
-
this.createdCommentIds = new Set();
|
|
17950
|
-
this.deletedCommentIds = new Set();
|
|
17951
|
-
}
|
|
17952
|
-
}
|
|
17953
|
-
|
|
17954
|
-
class PostCommentCountEngine {
|
|
17955
|
-
constructor() {
|
|
17956
|
-
this.isProcessing = false;
|
|
17957
|
-
this.tasks = [];
|
|
17958
|
-
this.commentChangeTracker = new Map();
|
|
17959
|
-
}
|
|
17960
|
-
queueCommentChangeTask(task) {
|
|
17961
|
-
this.tasks.push(task);
|
|
17962
|
-
if (!this.isProcessing) {
|
|
17963
|
-
this.processCommentChangeTask();
|
|
17964
|
-
}
|
|
17965
|
-
}
|
|
17966
|
-
processCommentChangeTask() {
|
|
17967
|
-
if (this.isProcessing) {
|
|
17968
|
-
return;
|
|
17969
|
-
}
|
|
17970
|
-
this.isProcessing = true;
|
|
17971
|
-
if (this.tasks.length === 0) {
|
|
17972
|
-
this.isProcessing = false;
|
|
17973
|
-
return;
|
|
17974
|
-
}
|
|
17975
|
-
// Process in capped batches, coalescing updates
|
|
17976
|
-
const batch = this.tasks.splice(0, PostCommentCountEngine.BATCH_SIZE);
|
|
17977
|
-
const modifiedPostIds = new Set();
|
|
17978
|
-
batch.forEach(task => {
|
|
17979
|
-
let modified = false;
|
|
17980
|
-
if (task instanceof ResetTask) {
|
|
17981
|
-
modified = this.processResetTaskInternal(task);
|
|
17982
|
-
}
|
|
17983
|
-
else if (task instanceof CreateTask) {
|
|
17984
|
-
modified = this.processCreateTaskInternal(task);
|
|
17985
|
-
}
|
|
17986
|
-
else if (task instanceof DeleteTask) {
|
|
17987
|
-
modified = this.processDeleteTaskInternal(task);
|
|
17988
|
-
}
|
|
17989
|
-
if (modified) {
|
|
17990
|
-
modifiedPostIds.add(task.postId);
|
|
17991
|
-
}
|
|
17992
|
-
});
|
|
17993
|
-
// Publish one update per modified post
|
|
17994
|
-
modifiedPostIds.forEach(postId => {
|
|
17995
|
-
const count = this.computeCommentCount(postId);
|
|
17996
|
-
PostCommentCountEngine.publishUpdate(postId, count);
|
|
17997
|
-
});
|
|
17998
|
-
this.isProcessing = false;
|
|
17999
|
-
// Recurse if more tasks remain
|
|
18000
|
-
if (this.tasks.length > 0) {
|
|
18001
|
-
this.processCommentChangeTask();
|
|
18002
|
-
}
|
|
18003
|
-
}
|
|
18004
|
-
processResetTaskInternal(task) {
|
|
18005
|
-
// Always creates/overwrites tracker
|
|
18006
|
-
this.commentChangeTracker.set(task.postId, new CommentChange(task.latestCreatedAt, task.serverCommentCount));
|
|
18007
|
-
return true;
|
|
18008
|
-
}
|
|
18009
|
-
processCreateTaskInternal(task) {
|
|
18010
|
-
const tracker = this.commentChangeTracker.get(task.postId);
|
|
18011
|
-
if (!tracker)
|
|
18012
|
-
return false; // No tracker, skip
|
|
18013
|
-
if (tracker.createdCommentIds.has(task.commentId))
|
|
18014
|
-
return false; // Deduplication
|
|
18015
|
-
if (task.createdAt <= tracker.latestCommentCreatedAt)
|
|
18016
|
-
return false; // Timestamp filtering
|
|
18017
|
-
tracker.createdCommentIds.add(task.commentId);
|
|
18018
|
-
return true;
|
|
18019
|
-
}
|
|
18020
|
-
processDeleteTaskInternal(task) {
|
|
18021
|
-
const tracker = this.commentChangeTracker.get(task.postId);
|
|
18022
|
-
if (!tracker)
|
|
18023
|
-
return false; // No tracker, skip
|
|
18024
|
-
if (tracker.deletedCommentIds.has(task.commentId))
|
|
18025
|
-
return false; // Deduplication
|
|
18026
|
-
tracker.deletedCommentIds.add(task.commentId);
|
|
18027
|
-
return true;
|
|
18028
|
-
}
|
|
18029
|
-
computeCommentCount(postId) {
|
|
18030
|
-
const tracker = this.commentChangeTracker.get(postId);
|
|
18031
|
-
if (!tracker)
|
|
18032
|
-
return 0;
|
|
18033
|
-
const count = tracker.serverCommentCount + tracker.createdCommentIds.size - tracker.deletedCommentIds.size;
|
|
18034
|
-
return Math.max(0, count);
|
|
18035
|
-
}
|
|
18036
|
-
static publishUpdate(postId, newCount) {
|
|
18037
|
-
var _a;
|
|
18038
|
-
const queryKey = ['post', 'get', postId];
|
|
18039
|
-
mergeInCache(queryKey, {
|
|
18040
|
-
localCommentCount: newCount,
|
|
18041
|
-
});
|
|
18042
|
-
const postPayload = (_a = pullFromCache(queryKey)) === null || _a === void 0 ? void 0 : _a.data;
|
|
18043
|
-
if (!postPayload)
|
|
18044
|
-
return;
|
|
18045
|
-
fireEvent('local.post.updated', {
|
|
18046
|
-
posts: [postPayload],
|
|
18047
|
-
});
|
|
18048
|
-
}
|
|
18049
|
-
}
|
|
18050
|
-
PostCommentCountEngine.BATCH_SIZE = 50;
|
|
18051
|
-
let instance;
|
|
18052
|
-
var PostCommentCountEngine$1 = {
|
|
18053
|
-
getInstance: () => {
|
|
18054
|
-
if (!instance) {
|
|
18055
|
-
instance = new PostCommentCountEngine();
|
|
18056
|
-
}
|
|
18057
|
-
return instance;
|
|
18058
|
-
},
|
|
18059
|
-
};
|
|
18060
|
-
|
|
18061
|
-
const updateStreamReferences = (streams, streamId, postId) => {
|
|
18062
|
-
if (!streamId)
|
|
18063
|
-
return streams;
|
|
18064
|
-
return streams.map(stream => stream.streamId === streamId
|
|
18065
|
-
? Object.assign(Object.assign({}, stream), { referenceType: 'post', referenceId: postId, postId }) : stream);
|
|
18066
|
-
};
|
|
18067
|
-
const preparePostPayload = (payload) => {
|
|
18068
|
-
const { posts: postsData, postChildren, videoStreamings } = payload, postPayload = __rest(payload, ["posts", "postChildren", "videoStreamings"]);
|
|
18069
|
-
// Unpack community payload by mapping payload field to postSetting value.
|
|
18070
|
-
const communitiesWithPostSetting = addPostSetting({ communities: postPayload.communities });
|
|
18071
|
-
// map users with community
|
|
18072
|
-
const mappedCommunityUsers = postPayload.communityUsers.map(communityUser => {
|
|
18073
|
-
const user = postPayload.users.find(user => user.userId === communityUser.userId);
|
|
18074
|
-
return Object.assign(Object.assign({}, communityUser), { user });
|
|
18075
|
-
});
|
|
18076
|
-
const communityWithMembershipStatus = updateMembershipStatus(communitiesWithPostSetting, mappedCommunityUsers);
|
|
18077
|
-
let mappedNewStream = [];
|
|
18078
|
-
// feed type
|
|
18079
|
-
const posts = postsData.map(post => {
|
|
18080
|
-
var _a, _b, _c, _d;
|
|
18081
|
-
const feedType = (_a = postPayload.feeds.find(feed => feed.feedId === post.feedId)) === null || _a === void 0 ? void 0 : _a.feedType;
|
|
18082
|
-
const childPosts = payload.postChildren.filter(children => children.parentPostId === post.postId);
|
|
18083
|
-
if (childPosts.length > 0 && isAmityLivestreamPost(childPosts[0])) {
|
|
18084
|
-
mappedNewStream = updateStreamReferences(videoStreamings, (_b = childPosts[0].data) === null || _b === void 0 ? void 0 : _b.streamId, post.postId);
|
|
18085
|
-
}
|
|
18086
|
-
// --- Computed Comment Count: ResetTask integration ---
|
|
18087
|
-
// Find all comments for this post (referenceType === 'post' && referenceId === postId)
|
|
18088
|
-
const allComments = (payload.comments || []).filter((c) => c.referenceType === 'post' && c.referenceId === post.postId);
|
|
18089
|
-
// Compute latestCreatedAt
|
|
18090
|
-
const latestCreatedAt = allComments.length === 0
|
|
18091
|
-
? new Date().toISOString()
|
|
18092
|
-
: allComments
|
|
18093
|
-
.map(c => c.createdAt)
|
|
18094
|
-
.sort()
|
|
18095
|
-
.at(-1);
|
|
18096
|
-
// Queue ResetTask for this post
|
|
18097
|
-
PostCommentCountEngine$1.getInstance().queueCommentChangeTask(new ResetTask(post.postId, latestCreatedAt, (_c = post.commentsCount) !== null && _c !== void 0 ? _c : 0));
|
|
18098
|
-
return Object.assign(Object.assign({}, post), { childPosts,
|
|
18099
|
-
feedType, localCommentCount: (_d = post.localCommentCount) !== null && _d !== void 0 ? _d : post.commentsCount, pinnedProductId: post === null || post === void 0 ? void 0 : post.pinnedProductId });
|
|
18100
|
-
});
|
|
18101
|
-
return Object.assign(Object.assign({}, postPayload), { postChildren, videoStreamings: mappedNewStream, posts, communities: communityWithMembershipStatus, communityUsers: mappedCommunityUsers });
|
|
18102
|
-
};
|
|
18103
|
-
const prepareSemanticSearchPostPayload = (_a) => {
|
|
18104
|
-
var { searchResult, polls } = _a, postPayload = __rest(_a, ["searchResult", "polls"]);
|
|
18105
|
-
const processedPostPayload = preparePostPayload(postPayload);
|
|
18106
|
-
return Object.assign(Object.assign({}, processedPostPayload), { polls });
|
|
18107
|
-
};
|
|
18108
|
-
|
|
18109
17949
|
const processDeleteChildPost = (payload) => {
|
|
18110
17950
|
var _a;
|
|
18111
17951
|
const post = payload.posts[0];
|
|
@@ -18423,9 +18263,6 @@ const createCommentEventSubscriber = (event, callback) => {
|
|
|
18423
18263
|
comments[0].commentId,
|
|
18424
18264
|
]);
|
|
18425
18265
|
if (['comment.created'].includes(event)) {
|
|
18426
|
-
// NOTE: skip adding comment to parent comment children if it's the same user since we use the local event to update instead.
|
|
18427
|
-
if (event === 'comment.created' && comment.data.userId === client.userId)
|
|
18428
|
-
return;
|
|
18429
18266
|
if (comments[0].parentId) {
|
|
18430
18267
|
const parentComment = pullFromCache([
|
|
18431
18268
|
'comment',
|
|
@@ -18441,9 +18278,6 @@ const createCommentEventSubscriber = (event, callback) => {
|
|
|
18441
18278
|
}
|
|
18442
18279
|
}
|
|
18443
18280
|
if (['comment.deleted'].includes(event)) {
|
|
18444
|
-
// NOTE: skip deleting comment to parent comment children if it's the same user since we use the local event to update instead.
|
|
18445
|
-
if (event === 'comment.deleted' && comment.data.userId === client.userId)
|
|
18446
|
-
return;
|
|
18447
18281
|
if (comments[0].parentId) {
|
|
18448
18282
|
const parentComment = pullFromCache([
|
|
18449
18283
|
'comment',
|
|
@@ -19854,7 +19688,9 @@ const deleteSubChannel = async (subChannelId, permanent = false) => {
|
|
|
19854
19688
|
await client.http.delete(`/api/v5/message-feeds/${encodeURIComponent(subChannelId)}`, { params: { permanent } });
|
|
19855
19689
|
const deleted = Object.assign(Object.assign({}, subChannel.data), { isDeleted: true, updatedAt: getFutureDate(subChannel.data.updatedAt) });
|
|
19856
19690
|
if (permanent) {
|
|
19691
|
+
/* c8 ignore next */
|
|
19857
19692
|
setTimeout(() => {
|
|
19693
|
+
/* c8 ignore next */
|
|
19858
19694
|
pushToTombstone('subChannel', subChannelId);
|
|
19859
19695
|
}, 0);
|
|
19860
19696
|
}
|
|
@@ -21112,9 +20948,11 @@ const getSubChannel = (subChannelId, callback) => {
|
|
|
21112
20948
|
callback => {
|
|
21113
20949
|
const updateMessagePreview = async (subChannel) => {
|
|
21114
20950
|
const messagePreviewSetting = await client.getMessagePreviewSetting(false);
|
|
20951
|
+
/* c8 ignore next */
|
|
21115
20952
|
if (messagePreviewSetting === "no-message-preview" /* Amity.MessagePreviewSetting.NO_MESSAGE_PREVIEW */)
|
|
21116
20953
|
return;
|
|
21117
20954
|
handleSubChannelUpdated(subChannel);
|
|
20955
|
+
/* c8 ignore next */
|
|
21118
20956
|
if (subChannel.subChannelId !== subChannelId)
|
|
21119
20957
|
return;
|
|
21120
20958
|
callback(subChannel);
|
|
@@ -21129,11 +20967,13 @@ const getSubChannel = (subChannelId, callback) => {
|
|
|
21129
20967
|
const isTargetSubChannel = subChannelMarkers.find(({ feedId }) => feedId === subChannelId);
|
|
21130
20968
|
if (!isTargetSubChannel)
|
|
21131
20969
|
return;
|
|
20970
|
+
/* c8 ignore next 5 */
|
|
21132
20971
|
const subChannel = (_a = pullFromCache([
|
|
21133
20972
|
'subChannel',
|
|
21134
20973
|
'get',
|
|
21135
20974
|
subChannelId,
|
|
21136
20975
|
])) === null || _a === void 0 ? void 0 : _a.data;
|
|
20976
|
+
/* c8 ignore next */
|
|
21137
20977
|
if (!subChannel)
|
|
21138
20978
|
return;
|
|
21139
20979
|
callback(subChannel);
|
|
@@ -21149,6 +20989,7 @@ const getSubChannel = (subChannelId, callback) => {
|
|
|
21149
20989
|
}, 'subChannelId', 'subChannel'),
|
|
21150
20990
|
convertEventPayload((callback) => {
|
|
21151
20991
|
return onMessageCreatedLocal(async (message) => {
|
|
20992
|
+
/* c8 ignore next */
|
|
21152
20993
|
if (message.subChannelId !== subChannelId)
|
|
21153
20994
|
return;
|
|
21154
20995
|
await handleMessageCreatedOnSubChannel(message);
|
|
@@ -21158,8 +20999,10 @@ const getSubChannel = (subChannelId, callback) => {
|
|
|
21158
20999
|
convertEventPayload((callback) => {
|
|
21159
21000
|
const updateMessagePreview = async (message) => {
|
|
21160
21001
|
const messagePreviewSetting = await client.getMessagePreviewSetting(false);
|
|
21002
|
+
/* c8 ignore next */
|
|
21161
21003
|
if (messagePreviewSetting === "no-message-preview" /* Amity.MessagePreviewSetting.NO_MESSAGE_PREVIEW */)
|
|
21162
21004
|
return;
|
|
21005
|
+
/* c8 ignore next */
|
|
21163
21006
|
if (message.subChannelId !== subChannelId)
|
|
21164
21007
|
return;
|
|
21165
21008
|
handleMessageUpdatedOnSubChannel(message);
|
|
@@ -21171,8 +21014,10 @@ const getSubChannel = (subChannelId, callback) => {
|
|
|
21171
21014
|
convertEventPayload((callback) => {
|
|
21172
21015
|
const updateMessagePreview = async (message) => {
|
|
21173
21016
|
const messagePreviewSetting = await client.getMessagePreviewSetting(false);
|
|
21017
|
+
/* c8 ignore next */
|
|
21174
21018
|
if (messagePreviewSetting === "no-message-preview" /* Amity.MessagePreviewSetting.NO_MESSAGE_PREVIEW */)
|
|
21175
21019
|
return;
|
|
21020
|
+
/* c8 ignore next */
|
|
21176
21021
|
if (message.subChannelId !== subChannelId)
|
|
21177
21022
|
return;
|
|
21178
21023
|
if (messagePreviewSetting === "message-preview-include-deleted" /* Amity.MessagePreviewSetting.MESSAGE_PREVIEW_INCLUDE_DELETED */)
|
|
@@ -21632,7 +21477,11 @@ const getChannel = (channelId, callback) => {
|
|
|
21632
21477
|
* check equality of previous data and current data to avoid redundancy
|
|
21633
21478
|
* if equal, do not call the callback function
|
|
21634
21479
|
* If not equal, assign new snapshot and return callback function
|
|
21480
|
+
*
|
|
21481
|
+
* Note: constructChannelObject always creates new function references (markAsRead, myMembership),
|
|
21482
|
+
* so isEqual will always return false in practice. The early-return branch is structurally unreachable.
|
|
21635
21483
|
*/
|
|
21484
|
+
/* c8 ignore next */
|
|
21636
21485
|
if (isEqual(snapshot, newSnapshot))
|
|
21637
21486
|
return;
|
|
21638
21487
|
snapshot = newSnapshot;
|
|
@@ -23177,7 +23026,6 @@ const getCommunities$1 = async (communityIds, includeDiscoverablePrivateCommunit
|
|
|
23177
23026
|
* @category Community API
|
|
23178
23027
|
*/
|
|
23179
23028
|
getCommunities$1.locally = (communityIds) => {
|
|
23180
|
-
var _a;
|
|
23181
23029
|
const client = getActiveClient();
|
|
23182
23030
|
client.log('community/getCommunities.locally', communityIds);
|
|
23183
23031
|
if (!client.cache)
|
|
@@ -23186,8 +23034,8 @@ getCommunities$1.locally = (communityIds) => {
|
|
|
23186
23034
|
.map(communityId => pullFromCache(['community', 'get', communityId]))
|
|
23187
23035
|
.filter(Boolean);
|
|
23188
23036
|
const communities = cached.map(({ data }) => data);
|
|
23189
|
-
const oldest =
|
|
23190
|
-
if (
|
|
23037
|
+
const oldest = cached.sort((a, b) => (a.cachedAt < b.cachedAt ? -1 : 1))[0];
|
|
23038
|
+
if (cached.length < communityIds.length)
|
|
23191
23039
|
return;
|
|
23192
23040
|
return {
|
|
23193
23041
|
data: communities,
|
|
@@ -25932,6 +25780,7 @@ queryCategories.locally = (query) => {
|
|
|
25932
25780
|
const getCategories = (params, callback, config) => {
|
|
25933
25781
|
const { log, cache } = getActiveClient();
|
|
25934
25782
|
if (!cache) {
|
|
25783
|
+
// eslint-disable-next-line no-console
|
|
25935
25784
|
console.log(ENABLE_CACHE_MESSAGE);
|
|
25936
25785
|
}
|
|
25937
25786
|
const timestamp = Date.now();
|
|
@@ -25946,7 +25795,7 @@ const getCategories = (params, callback, config) => {
|
|
|
25946
25795
|
let categories = (_a = data.data
|
|
25947
25796
|
.map(categoryId => pullFromCache(['category', 'get', categoryId]))
|
|
25948
25797
|
.filter(Boolean)
|
|
25949
|
-
.map(({ data }) => LinkedObject.category(data))) !== null && _a !== void 0 ? _a : [];
|
|
25798
|
+
.map(({ data }) => LinkedObject.category(data)) /* c8 ignore next */) !== null && _a !== void 0 ? _a : [];
|
|
25950
25799
|
if (!params.includeDeleted) {
|
|
25951
25800
|
categories = filterByPropEquality(categories, 'isDeleted', false);
|
|
25952
25801
|
}
|
|
@@ -25963,6 +25812,7 @@ const getCategories = (params, callback, config) => {
|
|
|
25963
25812
|
callback({
|
|
25964
25813
|
onNextPage: onFetch,
|
|
25965
25814
|
data: categories,
|
|
25815
|
+
/* c8 ignore next */
|
|
25966
25816
|
hasNextPage: !!((_b = data.params) === null || _b === void 0 ? void 0 : _b.page),
|
|
25967
25817
|
loading: data.loading,
|
|
25968
25818
|
error: data.error,
|
|
@@ -25978,6 +25828,7 @@ const getCategories = (params, callback, config) => {
|
|
|
25978
25828
|
var _a, _b;
|
|
25979
25829
|
const collection = (_a = pullFromCache(cacheKey)) === null || _a === void 0 ? void 0 : _a.data;
|
|
25980
25830
|
const categories = (_b = collection === null || collection === void 0 ? void 0 : collection.data) !== null && _b !== void 0 ? _b : [];
|
|
25831
|
+
/* c8 ignore next */
|
|
25981
25832
|
if (!initial && categories.length > 0 && !(collection === null || collection === void 0 ? void 0 : collection.params.page))
|
|
25982
25833
|
return;
|
|
25983
25834
|
const query = createQuery(queryCategories, Object.assign(Object.assign({}, queryParams), { limit: initial ? limit : undefined, page: !initial ? collection === null || collection === void 0 ? void 0 : collection.params.page : undefined }));
|
|
@@ -26078,7 +25929,7 @@ const queryGlobalFeed = async (query) => {
|
|
|
26078
25929
|
* @async
|
|
26079
25930
|
* */
|
|
26080
25931
|
queryGlobalFeed.locally = (query) => {
|
|
26081
|
-
var _a
|
|
25932
|
+
var _a;
|
|
26082
25933
|
const client = getActiveClient();
|
|
26083
25934
|
client.log('post/queryGlobalFeed.locally', query);
|
|
26084
25935
|
if (!client.cache)
|
|
@@ -26094,7 +25945,7 @@ queryGlobalFeed.locally = (query) => {
|
|
|
26094
25945
|
.map(({ data }) => data)
|
|
26095
25946
|
.map(LinkedObject.post);
|
|
26096
25947
|
const { paging } = data;
|
|
26097
|
-
return posts.length ===
|
|
25948
|
+
return posts.length === data.posts.length
|
|
26098
25949
|
? {
|
|
26099
25950
|
data: posts,
|
|
26100
25951
|
cachedAt,
|
|
@@ -26259,8 +26110,8 @@ getCommentByIds.locally = (commentIds) => {
|
|
|
26259
26110
|
.map(commentId => pullFromCache(['comment', 'get', commentId]))
|
|
26260
26111
|
.filter(Boolean);
|
|
26261
26112
|
const comments = cached.map(({ data }) => data);
|
|
26262
|
-
const oldest = (_a = cached.sort((a, b) =>
|
|
26263
|
-
if ((cached === null || cached === void 0 ? void 0 : cached
|
|
26113
|
+
const oldest = (_a = cached.sort((a, b) => a.cachedAt < b.cachedAt ? -1 : 1) /* c8 ignore next */) === null || _a === void 0 ? void 0 : _a[0];
|
|
26114
|
+
if ((cached /* c8 ignore next */ === null || cached /* c8 ignore next */ === void 0 ? void 0 : cached /* c8 ignore next */.length) < commentIds.length)
|
|
26264
26115
|
return;
|
|
26265
26116
|
return {
|
|
26266
26117
|
data: comments.map(comment => LinkedObject.comment(comment)),
|
|
@@ -26491,7 +26342,7 @@ const deleteComment = async (commentId, permanent = false) => {
|
|
|
26491
26342
|
if (post) {
|
|
26492
26343
|
const engine = PostCommentCountEngine$1.getInstance();
|
|
26493
26344
|
engine.queueCommentChangeTask(new DeleteTask(post.postId, commentId));
|
|
26494
|
-
if (!deleted.parentId && ((_b = deleted.children) === null || _b === void 0 ? void 0 : _b.length) > 0) {
|
|
26345
|
+
if (!deleted.parentId && ((_b = deleted.children /* c8 ignore next */) === null || _b === void 0 ? void 0 : _b.length) > 0) {
|
|
26495
26346
|
// NOTE: delete the parent comment will also remove all children comments
|
|
26496
26347
|
deleted.children.forEach((childCommentId) => {
|
|
26497
26348
|
engine.queueCommentChangeTask(new DeleteTask(post.postId, childCommentId));
|
|
@@ -27160,7 +27011,7 @@ const onPostUpdatedLocal = (callback) => createLocalPostEventSubscriber('local.p
|
|
|
27160
27011
|
const commentEventHandler$1 = (callback, eventHandler, cacheKey) => {
|
|
27161
27012
|
return eventHandler(async (comment) => {
|
|
27162
27013
|
var _a;
|
|
27163
|
-
const currentCollection = (_a = pullFromCache(cacheKey)) === null || _a === void 0 ? void 0 : _a.data;
|
|
27014
|
+
const currentCollection = (_a = pullFromCache(cacheKey) /* c8 ignore next */) === null || _a === void 0 ? void 0 : _a.data;
|
|
27164
27015
|
if (!currentCollection || !currentCollection.data.includes(comment.referenceId))
|
|
27165
27016
|
return;
|
|
27166
27017
|
callback(comment);
|
|
@@ -27885,7 +27736,7 @@ class CommunityFeedQueryStreamController extends QueryStreamController {
|
|
|
27885
27736
|
const commentEventHandler = (callback, eventHandler, cacheKey, resolveId) => {
|
|
27886
27737
|
return eventHandler(async (comment) => {
|
|
27887
27738
|
var _a;
|
|
27888
|
-
const currentCollection = (_a = pullFromCache(cacheKey)) === null || _a === void 0 ? void 0 : _a.data;
|
|
27739
|
+
const currentCollection = (_a = pullFromCache(cacheKey) /* c8 ignore next */) === null || _a === void 0 ? void 0 : _a.data;
|
|
27889
27740
|
if (!currentCollection ||
|
|
27890
27741
|
!currentCollection.data.includes(resolveId ? resolveId(comment.referenceId) : comment.referenceId))
|
|
27891
27742
|
return;
|
|
@@ -27927,9 +27778,10 @@ const resolvePostIdsFromRooms = (rooms, posts) => {
|
|
|
27927
27778
|
return ((_a = rooms
|
|
27928
27779
|
.map(room => {
|
|
27929
27780
|
const post = posts.find(post => post.postId === room.referenceId);
|
|
27781
|
+
/* c8 ignore next */
|
|
27930
27782
|
return post ? getResolver('post')({ postId: post === null || post === void 0 ? void 0 : post.postId }) : undefined;
|
|
27931
27783
|
})
|
|
27932
|
-
.filter(isNonNullable)) !== null && _a !== void 0 ? _a : []);
|
|
27784
|
+
.filter(isNonNullable) /* c8 ignore next */) !== null && _a !== void 0 ? _a : []);
|
|
27933
27785
|
};
|
|
27934
27786
|
|
|
27935
27787
|
class CommunityFeedLiveCollectionController extends LiveCollectionController {
|
|
@@ -28152,7 +28004,9 @@ getPostByIds.locally = (postIds) => {
|
|
|
28152
28004
|
.map(postId => pullFromCache(['post', 'get', postId]))
|
|
28153
28005
|
.filter(Boolean);
|
|
28154
28006
|
const posts = cached.map(({ data }) => data);
|
|
28007
|
+
/* c8 ignore next */
|
|
28155
28008
|
const oldest = (_a = cached.sort((a, b) => (a.cachedAt < b.cachedAt ? -1 : 1))) === null || _a === void 0 ? void 0 : _a[0];
|
|
28009
|
+
/* c8 ignore next */
|
|
28156
28010
|
if ((cached === null || cached === void 0 ? void 0 : cached.length) < postIds.length)
|
|
28157
28011
|
return;
|
|
28158
28012
|
return {
|
|
@@ -28193,9 +28047,11 @@ const createPost = async (bundle) => {
|
|
|
28193
28047
|
const processedAttachments = attachments && attachments.length > 0 && bundle.attachmentProductTags
|
|
28194
28048
|
? attachments.map(attachment => {
|
|
28195
28049
|
var _a;
|
|
28050
|
+
/* c8 ignore next */
|
|
28196
28051
|
const productTags = (_a = bundle.attachmentProductTags) === null || _a === void 0 ? void 0 : _a.get(attachment.fileId);
|
|
28197
28052
|
if (productTags)
|
|
28198
28053
|
return Object.assign(Object.assign({}, attachment), { productTags });
|
|
28054
|
+
/* c8 ignore next */
|
|
28199
28055
|
return attachment;
|
|
28200
28056
|
})
|
|
28201
28057
|
: attachments;
|
|
@@ -28240,9 +28096,11 @@ const editPost = async (postId, patch) => {
|
|
|
28240
28096
|
const processedAttachments = attachments && attachments.length > 0 && patch.attachmentProductTags
|
|
28241
28097
|
? attachments.map(attachment => {
|
|
28242
28098
|
var _a;
|
|
28099
|
+
/* c8 ignore next */
|
|
28243
28100
|
const productTags = (_a = patch.attachmentProductTags) === null || _a === void 0 ? void 0 : _a.get(attachment.fileId);
|
|
28244
28101
|
if (productTags)
|
|
28245
28102
|
return Object.assign(Object.assign({}, attachment), { productTags });
|
|
28103
|
+
/* c8 ignore next */
|
|
28246
28104
|
return attachment;
|
|
28247
28105
|
})
|
|
28248
28106
|
: attachments;
|
|
@@ -28290,9 +28148,12 @@ const deletePost = async (postId, permanent = false) => {
|
|
|
28290
28148
|
// later when realtime events covers that for us.
|
|
28291
28149
|
if (post.data.targetType === 'community') {
|
|
28292
28150
|
const community = await getCommunity$1(post.data.targetId);
|
|
28293
|
-
const communityUsersCache =
|
|
28151
|
+
const communityUsersCache =
|
|
28152
|
+
/* c8 ignore next */
|
|
28153
|
+
(_a = queryCache(['communityUsers', 'get'])) !== null && _a !== void 0 ? _a : [];
|
|
28294
28154
|
const communityUsers = communityUsersCache
|
|
28295
28155
|
.filter(({ key }) => {
|
|
28156
|
+
/* c8 ignore start */
|
|
28296
28157
|
// cache key is ['communityUsers', 'get', `${communityId}#`${userId}`}]
|
|
28297
28158
|
if (key[0] !== 'communityUsers')
|
|
28298
28159
|
return false;
|
|
@@ -28301,6 +28162,7 @@ const deletePost = async (postId, permanent = false) => {
|
|
|
28301
28162
|
if (typeof key[2] === 'string')
|
|
28302
28163
|
return key[2].includes(community.data.communityId);
|
|
28303
28164
|
return false;
|
|
28165
|
+
/* c8 ignore end */
|
|
28304
28166
|
})
|
|
28305
28167
|
.map(({ data }) => data);
|
|
28306
28168
|
fireEvent('community.updated', {
|
|
@@ -28315,7 +28177,9 @@ const deletePost = async (postId, permanent = false) => {
|
|
|
28315
28177
|
// to support hard deletion
|
|
28316
28178
|
const deleted = Object.assign(Object.assign({}, post.data), { isDeleted: true });
|
|
28317
28179
|
if (permanent) {
|
|
28180
|
+
/* c8 ignore next */
|
|
28318
28181
|
setTimeout(() => {
|
|
28182
|
+
/* c8 ignore next */
|
|
28319
28183
|
pushToTombstone('post', postId);
|
|
28320
28184
|
}, 0);
|
|
28321
28185
|
}
|
|
@@ -28577,9 +28441,11 @@ const createClipPost = async (bundle) => {
|
|
|
28577
28441
|
const processedAttachments = attachments && attachments.length > 0 && bundle.attachmentProductTags
|
|
28578
28442
|
? attachments.map(attachment => {
|
|
28579
28443
|
var _a;
|
|
28444
|
+
/* c8 ignore next */
|
|
28580
28445
|
const productTags = (_a = bundle.attachmentProductTags) === null || _a === void 0 ? void 0 : _a.get(attachment.fileId);
|
|
28581
28446
|
if (productTags)
|
|
28582
28447
|
return Object.assign(Object.assign({}, attachment), { productTags });
|
|
28448
|
+
/* c8 ignore next */
|
|
28583
28449
|
return attachment;
|
|
28584
28450
|
})
|
|
28585
28451
|
: attachments;
|
|
@@ -28625,9 +28491,11 @@ const createAudioPost = async (bundle) => {
|
|
|
28625
28491
|
const { attachments, attachmentProductTags } = bundle, rest = __rest(bundle, ["attachments", "attachmentProductTags"]);
|
|
28626
28492
|
const processedAttachments = attachments && attachments.length > 0 && attachmentProductTags
|
|
28627
28493
|
? attachments.map(attachment => {
|
|
28494
|
+
/* c8 ignore next */
|
|
28628
28495
|
const productTags = attachmentProductTags === null || attachmentProductTags === void 0 ? void 0 : attachmentProductTags.get(attachment.fileId);
|
|
28629
28496
|
if (productTags)
|
|
28630
28497
|
return Object.assign(Object.assign({}, attachment), { productTags });
|
|
28498
|
+
/* c8 ignore next */
|
|
28631
28499
|
return attachment;
|
|
28632
28500
|
})
|
|
28633
28501
|
: attachments;
|
|
@@ -28638,6 +28506,7 @@ const createAudioPost = async (bundle) => {
|
|
|
28638
28506
|
if (client.cache)
|
|
28639
28507
|
ingestInCache(data, { cachedAt });
|
|
28640
28508
|
return {
|
|
28509
|
+
/* c8 ignore next */
|
|
28641
28510
|
data: postLinkedObject(data === null || data === void 0 ? void 0 : data.posts[0]),
|
|
28642
28511
|
cachedAt,
|
|
28643
28512
|
};
|
|
@@ -28679,12 +28548,14 @@ const createMixedMediaPost = async (bundle) => {
|
|
|
28679
28548
|
const processedAttachments = attachments && attachments.length > 0 && bundle.attachmentProductTags
|
|
28680
28549
|
? attachments.map(attachment => {
|
|
28681
28550
|
var _a;
|
|
28551
|
+
/* c8 ignore next */
|
|
28682
28552
|
const productTags = (_a = bundle.attachmentProductTags) === null || _a === void 0 ? void 0 : _a.get(attachment.fileId);
|
|
28683
28553
|
if (productTags)
|
|
28684
28554
|
return Object.assign(Object.assign({}, attachment), { productTags });
|
|
28555
|
+
/* c8 ignore next */
|
|
28685
28556
|
return attachment;
|
|
28686
28557
|
})
|
|
28687
|
-
: attachments;
|
|
28558
|
+
: /* c8 ignore next */ attachments;
|
|
28688
28559
|
const { data: payload } = await client.http.post('/api/v4/posts', Object.assign(Object.assign({}, rest), { attachments: processedAttachments }));
|
|
28689
28560
|
fireEvent('post.created', payload);
|
|
28690
28561
|
const data = preparePostPayload(payload);
|
|
@@ -28692,6 +28563,7 @@ const createMixedMediaPost = async (bundle) => {
|
|
|
28692
28563
|
if (client.cache)
|
|
28693
28564
|
ingestInCache(data, { cachedAt });
|
|
28694
28565
|
return {
|
|
28566
|
+
/* c8 ignore next */
|
|
28695
28567
|
data: postLinkedObject((_a = data === null || data === void 0 ? void 0 : data.posts) === null || _a === void 0 ? void 0 : _a[0]),
|
|
28696
28568
|
cachedAt,
|
|
28697
28569
|
};
|
|
@@ -28764,6 +28636,7 @@ const pinProduct = async (postId, pinnedProductId) => {
|
|
|
28764
28636
|
ingestInCache(payload, { cachedAt });
|
|
28765
28637
|
fireEvent('local.post.updated', payload);
|
|
28766
28638
|
return {
|
|
28639
|
+
/* c8 ignore next */
|
|
28767
28640
|
data: postLinkedObject(data === null || data === void 0 ? void 0 : data.posts[0]),
|
|
28768
28641
|
cachedAt,
|
|
28769
28642
|
};
|
|
@@ -28795,6 +28668,7 @@ const unpinProduct = async (postId) => {
|
|
|
28795
28668
|
ingestInCache(payload, { cachedAt });
|
|
28796
28669
|
fireEvent('local.post.updated', payload);
|
|
28797
28670
|
return {
|
|
28671
|
+
/* c8 ignore next */
|
|
28798
28672
|
data: postLinkedObject(data === null || data === void 0 ? void 0 : data.posts[0]),
|
|
28799
28673
|
cachedAt,
|
|
28800
28674
|
};
|
|
@@ -28829,6 +28703,7 @@ const updateProductTags = async (postId, productTags) => {
|
|
|
28829
28703
|
ingestInCache(payload, { cachedAt });
|
|
28830
28704
|
fireEvent('local.post.updated', payload);
|
|
28831
28705
|
return {
|
|
28706
|
+
/* c8 ignore next */
|
|
28832
28707
|
data: postLinkedObject(data === null || data === void 0 ? void 0 : data.posts[0]),
|
|
28833
28708
|
cachedAt,
|
|
28834
28709
|
};
|