@amityco/ts-sdk 7.5.3-d52ed38.0 → 7.5.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.env +26 -26
- package/dist/@types/core/events.d.ts +0 -7
- package/dist/@types/core/events.d.ts.map +1 -1
- package/dist/@types/core/model.d.ts +1 -5
- package/dist/@types/core/model.d.ts.map +1 -1
- package/dist/@types/core/payload.d.ts +5 -38
- package/dist/@types/core/payload.d.ts.map +1 -1
- package/dist/@types/domains/client.d.ts +0 -10
- package/dist/@types/domains/client.d.ts.map +1 -1
- package/dist/@types/domains/community.d.ts +1 -51
- package/dist/@types/domains/community.d.ts.map +1 -1
- package/dist/@types/domains/notification.d.ts +2 -4
- package/dist/@types/domains/notification.d.ts.map +1 -1
- package/dist/@types/domains/post.d.ts +18 -1
- package/dist/@types/domains/post.d.ts.map +1 -1
- package/dist/@types/index.d.ts +0 -3
- package/dist/@types/index.d.ts.map +1 -1
- package/dist/communityRepository/api/createCommunity.d.ts +2 -2
- package/dist/communityRepository/api/createCommunity.d.ts.map +1 -1
- package/dist/communityRepository/api/getCommunities.d.ts +1 -1
- package/dist/communityRepository/api/getCommunities.d.ts.map +1 -1
- package/dist/communityRepository/api/getCommunity.d.ts +1 -1
- package/dist/communityRepository/api/getCommunity.d.ts.map +1 -1
- package/dist/communityRepository/api/getRecommendedCommunities.d.ts +1 -3
- package/dist/communityRepository/api/getRecommendedCommunities.d.ts.map +1 -1
- package/dist/communityRepository/api/getTrendingCommunities.d.ts +1 -3
- package/dist/communityRepository/api/getTrendingCommunities.d.ts.map +1 -1
- package/dist/communityRepository/api/joinCommunity.d.ts +0 -3
- package/dist/communityRepository/api/joinCommunity.d.ts.map +1 -1
- package/dist/communityRepository/api/queryCommunities.d.ts.map +1 -1
- package/dist/communityRepository/api/updateCommunity.d.ts +2 -2
- package/dist/communityRepository/api/updateCommunity.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/index.d.ts +0 -1
- package/dist/communityRepository/communityMembership/events/index.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityJoined.d.ts +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityJoined.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityLeft.d.ts +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityLeft.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityUserAdded.d.ts +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityUserAdded.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityUserBanned.d.ts +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityUserBanned.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityUserChanged.d.ts +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityUserChanged.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityUserRemoved.d.ts +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityUserRemoved.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityUserRoleAdded.d.ts +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityUserRoleAdded.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityUserRoleRemoved.d.ts +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityUserRoleRemoved.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityUserUnbanned.d.ts +1 -1
- package/dist/communityRepository/communityMembership/events/onCommunityUserUnbanned.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/onLocalCommunityJoined.d.ts +1 -1
- package/dist/communityRepository/communityMembership/events/onLocalCommunityJoined.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/onLocalCommunityLeft.d.ts +1 -1
- package/dist/communityRepository/communityMembership/events/onLocalCommunityLeft.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/onLocalCommunityUserAdded.d.ts +1 -1
- package/dist/communityRepository/communityMembership/events/onLocalCommunityUserAdded.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/onLocalCommunityUserRemoved.d.ts +1 -1
- package/dist/communityRepository/communityMembership/events/onLocalCommunityUserRemoved.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/onUserDeleted.d.ts +1 -1
- package/dist/communityRepository/communityMembership/events/onUserDeleted.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/events/utils.d.ts +2 -2
- package/dist/communityRepository/communityMembership/events/utils.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/observers/getMembers/CommunityMembersQueryStreamController.d.ts +2 -2
- package/dist/communityRepository/communityMembership/observers/getMembers/CommunityMembersQueryStreamController.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/observers/getMembers/enums.d.ts +1 -2
- package/dist/communityRepository/communityMembership/observers/getMembers/enums.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/observers/searchMembers/SearchCommunityMembersQueryStreamController.d.ts +2 -2
- package/dist/communityRepository/communityMembership/observers/searchMembers/SearchCommunityMembersQueryStreamController.d.ts.map +1 -1
- package/dist/communityRepository/communityMembership/observers/searchMembers/enums.d.ts +0 -1
- package/dist/communityRepository/communityMembership/observers/searchMembers/enums.d.ts.map +1 -1
- package/dist/communityRepository/communityModeration/events/onLocalCommunityRoleAdded.d.ts +1 -1
- package/dist/communityRepository/communityModeration/events/onLocalCommunityRoleAdded.d.ts.map +1 -1
- package/dist/communityRepository/communityModeration/events/onLocalCommunityRoleRemoved.d.ts +1 -1
- package/dist/communityRepository/communityModeration/events/onLocalCommunityRoleRemoved.d.ts.map +1 -1
- package/dist/communityRepository/events/onCommunityCreated.d.ts +1 -1
- package/dist/communityRepository/events/onCommunityCreated.d.ts.map +1 -1
- package/dist/communityRepository/events/onCommunityDeleted.d.ts +1 -1
- package/dist/communityRepository/events/onCommunityDeleted.d.ts.map +1 -1
- package/dist/communityRepository/events/onCommunityUpdated.d.ts +1 -1
- package/dist/communityRepository/events/onCommunityUpdated.d.ts.map +1 -1
- package/dist/communityRepository/events/utils.d.ts +1 -1
- package/dist/communityRepository/events/utils.d.ts.map +1 -1
- package/dist/communityRepository/observers/getCommunities/CommunitiesLiveCollectionController.d.ts.map +1 -1
- package/dist/communityRepository/observers/getCommunities/CommunitiesPaginationController.d.ts.map +1 -1
- package/dist/communityRepository/observers/getCommunities/CommunitiesQueryStreamController.d.ts +2 -2
- package/dist/communityRepository/observers/getCommunities/CommunitiesQueryStreamController.d.ts.map +1 -1
- package/dist/communityRepository/observers/getCommunity.d.ts.map +1 -1
- package/dist/communityRepository/observers/getRecommendedCommunities/RecommendedCommunitiesLiveCollectionController.d.ts.map +1 -1
- package/dist/communityRepository/observers/getRecommendedCommunities/RecommendedCommunitiesPaginationController.d.ts.map +1 -1
- package/dist/communityRepository/observers/getRecommendedCommunities/RecommendedCommunitiesQueryStreamController.d.ts +2 -2
- package/dist/communityRepository/observers/getRecommendedCommunities/RecommendedCommunitiesQueryStreamController.d.ts.map +1 -1
- package/dist/communityRepository/observers/getRecommendedCommunities/enums.d.ts +1 -2
- package/dist/communityRepository/observers/getRecommendedCommunities/enums.d.ts.map +1 -1
- package/dist/communityRepository/observers/getTrendingCommunities/TrendingCommunitiesLiveCollectionController.d.ts.map +1 -1
- package/dist/communityRepository/observers/getTrendingCommunities/TrendingCommunitiesPaginationController.d.ts.map +1 -1
- package/dist/communityRepository/observers/getTrendingCommunities/TrendingCommunitiesQueryStreamController.d.ts +2 -2
- package/dist/communityRepository/observers/getTrendingCommunities/TrendingCommunitiesQueryStreamController.d.ts.map +1 -1
- package/dist/communityRepository/observers/index.d.ts +0 -1
- package/dist/communityRepository/observers/index.d.ts.map +1 -1
- package/dist/communityRepository/observers/searchCommunities/SearchCommunitiesLiveCollectionController.d.ts.map +1 -1
- package/dist/communityRepository/observers/searchCommunities/SearchCommunitiesPaginationController.d.ts.map +1 -1
- package/dist/communityRepository/observers/searchCommunities/SearchCommunitiesQueryStreamController.d.ts +2 -2
- package/dist/communityRepository/observers/searchCommunities/SearchCommunitiesQueryStreamController.d.ts.map +1 -1
- package/dist/communityRepository/observers/semanticSearch/SemanticSearchCommunityLiveCollectionController.d.ts.map +1 -1
- package/dist/communityRepository/observers/semanticSearch/SemanticSearchCommunityPaginationController.d.ts.map +1 -1
- package/dist/communityRepository/observers/semanticSearch/SemanticSearchCommunityQueryStreamController.d.ts +2 -2
- package/dist/communityRepository/observers/semanticSearch/SemanticSearchCommunityQueryStreamController.d.ts.map +1 -1
- package/dist/communityRepository/utils/communityWithMembership.d.ts +1 -1
- package/dist/communityRepository/utils/communityWithMembership.d.ts.map +1 -1
- package/dist/communityRepository/utils/payload.d.ts +1 -2
- package/dist/communityRepository/utils/payload.d.ts.map +1 -1
- package/dist/core/events.d.ts +3 -3
- package/dist/core/events.d.ts.map +1 -1
- package/dist/core/model/idResolvers.d.ts.map +1 -1
- package/dist/core/model/index.d.ts.map +1 -1
- package/dist/index.cjs.js +1433 -2894
- package/dist/index.d.ts +0 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.esm.js +1675 -3135
- package/dist/index.umd.js +4 -4
- package/dist/postRepository/api/getPost.d.ts +2 -2
- package/dist/postRepository/api/getPost.d.ts.map +1 -1
- package/dist/postRepository/observers/getGlobalPinnedPosts/GlobalPinnedPostQueryStreamController.d.ts.map +1 -1
- package/dist/postRepository/observers/getPinnedPosts/PinnedPostQueryStreamController.d.ts.map +1 -1
- package/dist/subChannelRepository/utils/prepareSubChannelPayload.d.ts.map +1 -1
- package/dist/userRepository/observers/getBlockedUsers.d.ts +4 -4
- package/dist/userRepository/observers/getBlockedUsers.d.ts.map +1 -1
- package/dist/utils/linkedObject/index.d.ts +0 -3
- package/dist/utils/linkedObject/index.d.ts.map +1 -1
- package/dist/utils/tests/dummy/post.d.ts +3 -3
- package/package.json +1 -1
- package/src/@types/core/events.ts +0 -10
- package/src/@types/core/model.ts +1 -8
- package/src/@types/core/payload.ts +5 -48
- package/src/@types/domains/client.ts +0 -12
- package/src/@types/domains/community.ts +3 -82
- package/src/@types/domains/notification.ts +0 -2
- package/src/@types/domains/post.ts +25 -8
- package/src/@types/index.ts +0 -3
- package/src/commentRepository/api/createComment.ts +1 -1
- package/src/commentRepository/api/deleteComment.ts +1 -1
- package/src/communityRepository/api/createCommunity.ts +2 -5
- package/src/communityRepository/api/getCommunities.ts +2 -9
- package/src/communityRepository/api/getCommunity.ts +2 -13
- package/src/communityRepository/api/getRecommendedCommunities.ts +4 -11
- package/src/communityRepository/api/getTrendingCommunities.ts +4 -11
- package/src/communityRepository/api/joinCommunity.ts +1 -4
- package/src/communityRepository/api/queryCommunities.ts +1 -7
- package/src/communityRepository/api/updateCommunity.ts +3 -13
- package/src/communityRepository/communityMembership/events/index.ts +0 -1
- package/src/communityRepository/communityMembership/events/onCommunityJoined.ts +1 -1
- package/src/communityRepository/communityMembership/events/onCommunityLeft.ts +1 -1
- package/src/communityRepository/communityMembership/events/onCommunityUserAdded.ts +1 -1
- package/src/communityRepository/communityMembership/events/onCommunityUserBanned.ts +1 -1
- package/src/communityRepository/communityMembership/events/onCommunityUserChanged.ts +1 -1
- package/src/communityRepository/communityMembership/events/onCommunityUserRemoved.ts +1 -1
- package/src/communityRepository/communityMembership/events/onCommunityUserRoleAdded.ts +1 -1
- package/src/communityRepository/communityMembership/events/onCommunityUserRoleRemoved.ts +1 -1
- package/src/communityRepository/communityMembership/events/onCommunityUserUnbanned.ts +1 -1
- package/src/communityRepository/communityMembership/events/onLocalCommunityJoined.ts +1 -1
- package/src/communityRepository/communityMembership/events/onLocalCommunityLeft.ts +1 -1
- package/src/communityRepository/communityMembership/events/onLocalCommunityUserAdded.ts +1 -1
- package/src/communityRepository/communityMembership/events/onLocalCommunityUserRemoved.ts +1 -1
- package/src/communityRepository/communityMembership/events/onUserDeleted.ts +1 -3
- package/src/communityRepository/communityMembership/events/utils.ts +2 -2
- package/src/communityRepository/communityMembership/observers/getMembers/CommunityMembersQueryStreamController.ts +2 -8
- package/src/communityRepository/communityMembership/observers/getMembers/enums.ts +0 -1
- package/src/communityRepository/communityMembership/observers/searchMembers/SearchCommunityMembersQueryStreamController.ts +2 -8
- package/src/communityRepository/communityMembership/observers/searchMembers/enums.ts +0 -1
- package/src/communityRepository/communityModeration/events/onLocalCommunityRoleAdded.ts +1 -1
- package/src/communityRepository/communityModeration/events/onLocalCommunityRoleRemoved.ts +1 -1
- package/src/communityRepository/events/onCommunityCreated.ts +1 -1
- package/src/communityRepository/events/onCommunityDeleted.ts +1 -1
- package/src/communityRepository/events/onCommunityUpdated.ts +1 -1
- package/src/communityRepository/events/utils.ts +1 -1
- package/src/communityRepository/observers/getCommunities/CommunitiesLiveCollectionController.ts +0 -6
- package/src/communityRepository/observers/getCommunities/CommunitiesPaginationController.ts +0 -1
- package/src/communityRepository/observers/getCommunities/CommunitiesQueryStreamController.ts +2 -2
- package/src/communityRepository/observers/getCommunity.ts +0 -3
- package/src/communityRepository/observers/getRecommendedCommunities/RecommendedCommunitiesLiveCollectionController.ts +1 -8
- package/src/communityRepository/observers/getRecommendedCommunities/RecommendedCommunitiesPaginationController.ts +1 -6
- package/src/communityRepository/observers/getRecommendedCommunities/RecommendedCommunitiesQueryStreamController.ts +2 -2
- package/src/communityRepository/observers/getRecommendedCommunities/enums.ts +0 -1
- package/src/communityRepository/observers/getTrendingCommunities/TrendingCommunitiesLiveCollectionController.ts +1 -9
- package/src/communityRepository/observers/getTrendingCommunities/TrendingCommunitiesPaginationController.ts +1 -6
- package/src/communityRepository/observers/getTrendingCommunities/TrendingCommunitiesQueryStreamController.ts +2 -2
- package/src/communityRepository/observers/index.ts +0 -1
- package/src/communityRepository/observers/searchCommunities/SearchCommunitiesLiveCollectionController.ts +0 -6
- package/src/communityRepository/observers/searchCommunities/SearchCommunitiesPaginationController.ts +0 -1
- package/src/communityRepository/observers/searchCommunities/SearchCommunitiesQueryStreamController.ts +2 -2
- package/src/communityRepository/observers/semanticSearch/SemanticSearchCommunityLiveCollectionController.ts +0 -6
- package/src/communityRepository/observers/semanticSearch/SemanticSearchCommunityPaginationController.ts +0 -1
- package/src/communityRepository/observers/semanticSearch/SemanticSearchCommunityQueryStreamController.ts +2 -2
- package/src/communityRepository/utils/communityWithMembership.ts +5 -9
- package/src/communityRepository/utils/payload.ts +2 -28
- package/src/core/liveCollection/PaginationController.ts +1 -1
- package/src/core/liveCollection/PaginationNoPageController.ts +1 -1
- package/src/core/model/idResolvers.ts +0 -3
- package/src/core/model/index.ts +0 -3
- package/src/index.ts +0 -2
- package/src/messagePreview/utils/getChannelMessagePreviewWithUser.ts +3 -3
- package/src/postRepository/api/getPost.ts +6 -4
- package/src/postRepository/observers/getGlobalPinnedPosts/GlobalPinnedPostQueryStreamController.ts +1 -7
- package/src/postRepository/observers/getPinnedPosts/PinnedPostQueryStreamController.ts +1 -7
- package/src/postRepository/observers/getPost.ts +2 -2
- package/src/reactionRepository/api/addReaction.ts +1 -1
- package/src/subChannelRepository/utils/prepareSubChannelPayload.ts +0 -4
- package/src/userRepository/observers/getBlockedUsers.ts +4 -4
- package/src/utils/linkedObject/index.ts +0 -6
- package/src/utils/linkedObject/streamLinkedObject.ts +1 -1
- package/dist/@types/domains/invitation.d.ts +0 -92
- package/dist/@types/domains/invitation.d.ts.map +0 -1
- package/dist/@types/domains/joinRequest.d.ts +0 -53
- package/dist/@types/domains/joinRequest.d.ts.map +0 -1
- package/dist/communityRepository/communityMembership/events/onLocalCommunityJoin.d.ts +0 -2
- package/dist/communityRepository/communityMembership/events/onLocalCommunityJoin.d.ts.map +0 -1
- package/dist/communityRepository/internalAPI/getMyJoinRequest.d.ts +0 -16
- package/dist/communityRepository/internalAPI/getMyJoinRequest.d.ts.map +0 -1
- package/dist/communityRepository/internalAPI/joinCommunity.d.ts +0 -16
- package/dist/communityRepository/internalAPI/joinCommunity.d.ts.map +0 -1
- package/dist/communityRepository/joinRequest/events/index.d.ts +0 -4
- package/dist/communityRepository/joinRequest/events/index.d.ts.map +0 -1
- package/dist/communityRepository/joinRequest/events/onJoinRequestCreated.d.ts +0 -17
- package/dist/communityRepository/joinRequest/events/onJoinRequestCreated.d.ts.map +0 -1
- package/dist/communityRepository/joinRequest/events/onJoinRequestDeleted.d.ts +0 -17
- package/dist/communityRepository/joinRequest/events/onJoinRequestDeleted.d.ts.map +0 -1
- package/dist/communityRepository/joinRequest/events/onJoinRequestUpdated.d.ts +0 -17
- package/dist/communityRepository/joinRequest/events/onJoinRequestUpdated.d.ts.map +0 -1
- package/dist/communityRepository/joinRequest/internalAPI/approveJoinRequest.d.ts +0 -16
- package/dist/communityRepository/joinRequest/internalAPI/approveJoinRequest.d.ts.map +0 -1
- package/dist/communityRepository/joinRequest/internalAPI/cancelJoinRequest.d.ts +0 -16
- package/dist/communityRepository/joinRequest/internalAPI/cancelJoinRequest.d.ts.map +0 -1
- package/dist/communityRepository/joinRequest/internalAPI/rejectJoinRequest.d.ts +0 -16
- package/dist/communityRepository/joinRequest/internalAPI/rejectJoinRequest.d.ts.map +0 -1
- package/dist/communityRepository/observers/getJoinRequestList/JoinRequestListLiveCollectionController.d.ts +0 -14
- package/dist/communityRepository/observers/getJoinRequestList/JoinRequestListLiveCollectionController.d.ts.map +0 -1
- package/dist/communityRepository/observers/getJoinRequestList/JoinRequestListPaginationController.d.ts +0 -9
- package/dist/communityRepository/observers/getJoinRequestList/JoinRequestListPaginationController.d.ts.map +0 -1
- package/dist/communityRepository/observers/getJoinRequestList/JoinRequestListQueryStreamController.d.ts +0 -15
- package/dist/communityRepository/observers/getJoinRequestList/JoinRequestListQueryStreamController.d.ts.map +0 -1
- package/dist/communityRepository/observers/getJoinRequestList/enum.d.ts +0 -6
- package/dist/communityRepository/observers/getJoinRequestList/enum.d.ts.map +0 -1
- package/dist/communityRepository/observers/getJoinRequestList.d.ts +0 -12
- package/dist/communityRepository/observers/getJoinRequestList.d.ts.map +0 -1
- package/dist/communityRepository/observers/getJoinRequests/JoinRequestsLiveCollectionController.d.ts +0 -14
- package/dist/communityRepository/observers/getJoinRequests/JoinRequestsLiveCollectionController.d.ts.map +0 -1
- package/dist/communityRepository/observers/getJoinRequests/JoinRequestsPaginationController.d.ts +0 -9
- package/dist/communityRepository/observers/getJoinRequests/JoinRequestsPaginationController.d.ts.map +0 -1
- package/dist/communityRepository/observers/getJoinRequests/JoinRequestsQueryStreamController.d.ts +0 -15
- package/dist/communityRepository/observers/getJoinRequests/JoinRequestsQueryStreamController.d.ts.map +0 -1
- package/dist/communityRepository/observers/getJoinRequests/enum.d.ts +0 -6
- package/dist/communityRepository/observers/getJoinRequests/enum.d.ts.map +0 -1
- package/dist/communityRepository/observers/getJoinRequests.d.ts +0 -12
- package/dist/communityRepository/observers/getJoinRequests.d.ts.map +0 -1
- package/dist/invitationRepository/events/index.d.ts +0 -4
- package/dist/invitationRepository/events/index.d.ts.map +0 -1
- package/dist/invitationRepository/events/onLocalInvitationCreated.d.ts +0 -17
- package/dist/invitationRepository/events/onLocalInvitationCreated.d.ts.map +0 -1
- package/dist/invitationRepository/events/onLocalInvitationDeleted.d.ts +0 -17
- package/dist/invitationRepository/events/onLocalInvitationDeleted.d.ts.map +0 -1
- package/dist/invitationRepository/events/onLocalInvitationUpdated.d.ts +0 -17
- package/dist/invitationRepository/events/onLocalInvitationUpdated.d.ts.map +0 -1
- package/dist/invitationRepository/index.d.ts +0 -3
- package/dist/invitationRepository/index.d.ts.map +0 -1
- package/dist/invitationRepository/internalApi/acceptInvitation.d.ts +0 -16
- package/dist/invitationRepository/internalApi/acceptInvitation.d.ts.map +0 -1
- package/dist/invitationRepository/internalApi/createInvitations.d.ts +0 -21
- package/dist/invitationRepository/internalApi/createInvitations.d.ts.map +0 -1
- package/dist/invitationRepository/internalApi/getInvitation.d.ts +0 -17
- package/dist/invitationRepository/internalApi/getInvitation.d.ts.map +0 -1
- package/dist/invitationRepository/internalApi/index.d.ts +0 -4
- package/dist/invitationRepository/internalApi/index.d.ts.map +0 -1
- package/dist/invitationRepository/internalApi/rejectInvitation.d.ts +0 -16
- package/dist/invitationRepository/internalApi/rejectInvitation.d.ts.map +0 -1
- package/dist/invitationRepository/observers/getInvitations/InvitationsLiveCollectionController.d.ts +0 -14
- package/dist/invitationRepository/observers/getInvitations/InvitationsLiveCollectionController.d.ts.map +0 -1
- package/dist/invitationRepository/observers/getInvitations/InvitationsPaginationController.d.ts +0 -5
- package/dist/invitationRepository/observers/getInvitations/InvitationsPaginationController.d.ts.map +0 -1
- package/dist/invitationRepository/observers/getInvitations/InvitationsQueryStreamController.d.ts +0 -15
- package/dist/invitationRepository/observers/getInvitations/InvitationsQueryStreamController.d.ts.map +0 -1
- package/dist/invitationRepository/observers/getInvitations/enums.d.ts +0 -6
- package/dist/invitationRepository/observers/getInvitations/enums.d.ts.map +0 -1
- package/dist/invitationRepository/observers/getInvitations.d.ts +0 -12
- package/dist/invitationRepository/observers/getInvitations.d.ts.map +0 -1
- package/dist/invitationRepository/observers/getMyCommunityInvitations.d.ts +0 -12
- package/dist/invitationRepository/observers/getMyCommunityInvitations.d.ts.map +0 -1
- package/dist/invitationRepository/observers/getMyInvitations/MyInvitationsLiveCollectionController.d.ts +0 -14
- package/dist/invitationRepository/observers/getMyInvitations/MyInvitationsLiveCollectionController.d.ts.map +0 -1
- package/dist/invitationRepository/observers/getMyInvitations/MyInvitationsPaginationController.d.ts +0 -5
- package/dist/invitationRepository/observers/getMyInvitations/MyInvitationsPaginationController.d.ts.map +0 -1
- package/dist/invitationRepository/observers/getMyInvitations/MyInvitationsQueryStreamController.d.ts +0 -15
- package/dist/invitationRepository/observers/getMyInvitations/MyInvitationsQueryStreamController.d.ts.map +0 -1
- package/dist/invitationRepository/observers/index.d.ts +0 -2
- package/dist/invitationRepository/observers/index.d.ts.map +0 -1
- package/dist/invitationRepository/utils/convertRawInvitationToInternalInvitation.d.ts +0 -2
- package/dist/invitationRepository/utils/convertRawInvitationToInternalInvitation.d.ts.map +0 -1
- package/dist/invitationRepository/utils/index.d.ts +0 -2
- package/dist/invitationRepository/utils/index.d.ts.map +0 -1
- package/dist/invitationRepository/utils/prepareInvitationPayload.d.ts +0 -2
- package/dist/invitationRepository/utils/prepareInvitationPayload.d.ts.map +0 -1
- package/dist/invitationRepository/utils/prepareMyInvitationsPayload.d.ts +0 -2
- package/dist/invitationRepository/utils/prepareMyInvitationsPayload.d.ts.map +0 -1
- package/dist/utils/linkedObject/communityLinkedObject.d.ts +0 -2
- package/dist/utils/linkedObject/communityLinkedObject.d.ts.map +0 -1
- package/dist/utils/linkedObject/invitationLinkedObject.d.ts +0 -2
- package/dist/utils/linkedObject/invitationLinkedObject.d.ts.map +0 -1
- package/dist/utils/linkedObject/joinRequestLinkedObject.d.ts +0 -2
- package/dist/utils/linkedObject/joinRequestLinkedObject.d.ts.map +0 -1
- package/src/@types/domains/invitation.ts +0 -119
- package/src/@types/domains/joinRequest.ts +0 -66
- package/src/communityRepository/communityMembership/events/onLocalCommunityJoin.ts +0 -20
- package/src/communityRepository/internalAPI/getMyJoinRequest.ts +0 -43
- package/src/communityRepository/internalAPI/joinCommunity.ts +0 -66
- package/src/communityRepository/joinRequest/events/index.ts +0 -3
- package/src/communityRepository/joinRequest/events/onJoinRequestCreated.ts +0 -33
- package/src/communityRepository/joinRequest/events/onJoinRequestDeleted.ts +0 -33
- package/src/communityRepository/joinRequest/events/onJoinRequestUpdated.ts +0 -33
- package/src/communityRepository/joinRequest/internalAPI/approveJoinRequest.ts +0 -52
- package/src/communityRepository/joinRequest/internalAPI/cancelJoinRequest.ts +0 -49
- package/src/communityRepository/joinRequest/internalAPI/rejectJoinRequest.ts +0 -52
- package/src/communityRepository/observers/getJoinRequestList/JoinRequestListLiveCollectionController.ts +0 -135
- package/src/communityRepository/observers/getJoinRequestList/JoinRequestListPaginationController.ts +0 -30
- package/src/communityRepository/observers/getJoinRequestList/JoinRequestListQueryStreamController.ts +0 -116
- package/src/communityRepository/observers/getJoinRequestList/enum.ts +0 -5
- package/src/communityRepository/observers/getJoinRequestList.ts +0 -51
- package/src/communityRepository/observers/getJoinRequests/JoinRequestsLiveCollectionController.ts +0 -126
- package/src/communityRepository/observers/getJoinRequests/JoinRequestsPaginationController.ts +0 -26
- package/src/communityRepository/observers/getJoinRequests/JoinRequestsQueryStreamController.ts +0 -108
- package/src/communityRepository/observers/getJoinRequests/enum.ts +0 -5
- package/src/communityRepository/observers/getJoinRequests.ts +0 -44
- package/src/invitationRepository/events/index.ts +0 -3
- package/src/invitationRepository/events/onLocalInvitationCreated.ts +0 -33
- package/src/invitationRepository/events/onLocalInvitationDeleted.ts +0 -33
- package/src/invitationRepository/events/onLocalInvitationUpdated.ts +0 -33
- package/src/invitationRepository/index.ts +0 -2
- package/src/invitationRepository/internalApi/acceptInvitation.ts +0 -45
- package/src/invitationRepository/internalApi/createInvitations.ts +0 -52
- package/src/invitationRepository/internalApi/getInvitation.ts +0 -47
- package/src/invitationRepository/internalApi/index.ts +0 -3
- package/src/invitationRepository/internalApi/rejectInvitation.ts +0 -45
- package/src/invitationRepository/observers/getInvitations/InvitationsLiveCollectionController.ts +0 -148
- package/src/invitationRepository/observers/getInvitations/InvitationsPaginationController.ts +0 -19
- package/src/invitationRepository/observers/getInvitations/InvitationsQueryStreamController.ts +0 -97
- package/src/invitationRepository/observers/getInvitations/enums.ts +0 -5
- package/src/invitationRepository/observers/getInvitations.ts +0 -44
- package/src/invitationRepository/observers/getMyCommunityInvitations.ts +0 -48
- package/src/invitationRepository/observers/getMyInvitations/MyInvitationsLiveCollectionController.ts +0 -148
- package/src/invitationRepository/observers/getMyInvitations/MyInvitationsPaginationController.ts +0 -22
- package/src/invitationRepository/observers/getMyInvitations/MyInvitationsQueryStreamController.ts +0 -105
- package/src/invitationRepository/observers/index.ts +0 -1
- package/src/invitationRepository/utils/convertRawInvitationToInternalInvitation.ts +0 -8
- package/src/invitationRepository/utils/index.ts +0 -1
- package/src/invitationRepository/utils/prepareInvitationPayload.ts +0 -12
- package/src/invitationRepository/utils/prepareMyInvitationsPayload.ts +0 -12
- package/src/utils/linkedObject/communityLinkedObject.ts +0 -57
- package/src/utils/linkedObject/invitationLinkedObject.ts +0 -37
- package/src/utils/linkedObject/joinRequestLinkedObject.ts +0 -31
|
@@ -11,11 +11,7 @@ export class TrendingCommunitiesPaginationController extends PaginationControlle
|
|
|
11
11
|
Amity.TrendingCommunityLiveCollection
|
|
12
12
|
> {
|
|
13
13
|
async getRequest(queryParams: Amity.TrendingCommunityLiveCollection, token: string | undefined) {
|
|
14
|
-
const {
|
|
15
|
-
limit = COLLECTION_DEFAULT_PAGINATION_LIMIT,
|
|
16
|
-
includeDiscoverablePrivateCommunity,
|
|
17
|
-
...params
|
|
18
|
-
} = queryParams;
|
|
14
|
+
const { limit = COLLECTION_DEFAULT_PAGINATION_LIMIT, ...params } = queryParams;
|
|
19
15
|
const options = token ? { token } : { limit };
|
|
20
16
|
|
|
21
17
|
const { data: queryResponse } = await this.http.get<Amity.CommunityPayload & Amity.Pagination>(
|
|
@@ -24,7 +20,6 @@ export class TrendingCommunitiesPaginationController extends PaginationControlle
|
|
|
24
20
|
params: {
|
|
25
21
|
...params,
|
|
26
22
|
options,
|
|
27
|
-
includeDiscoverablePrivateCommunity: includeDiscoverablePrivateCommunity ?? true,
|
|
28
23
|
},
|
|
29
24
|
},
|
|
30
25
|
);
|
|
@@ -64,7 +64,7 @@ export class TrendingCommunitiesQueryStreamController extends QueryStreamControl
|
|
|
64
64
|
}
|
|
65
65
|
|
|
66
66
|
reactor(action: EnumCommunityActions | EnumCommunityMemberActions) {
|
|
67
|
-
return (community: Amity.
|
|
67
|
+
return (community: Amity.Community) => {
|
|
68
68
|
const collection = pullFromCache<Amity.TrendingCommunityLiveCollectionCache>(
|
|
69
69
|
this.cacheKey,
|
|
70
70
|
)?.data;
|
|
@@ -77,7 +77,7 @@ export class TrendingCommunitiesQueryStreamController extends QueryStreamControl
|
|
|
77
77
|
|
|
78
78
|
subscribeRTE(
|
|
79
79
|
createSubscriber: {
|
|
80
|
-
fn: (reactor: (channel: Amity.
|
|
80
|
+
fn: (reactor: (channel: Amity.Community) => void) => Amity.Unsubscriber;
|
|
81
81
|
action: EnumCommunityActions | EnumCommunityMemberActions;
|
|
82
82
|
}[],
|
|
83
83
|
) {
|
|
@@ -15,10 +15,8 @@ import {
|
|
|
15
15
|
onCommunityLeft,
|
|
16
16
|
onLocalCommunityLeft,
|
|
17
17
|
onCommunityUserChanged,
|
|
18
|
-
onLocalCommunityJoin,
|
|
19
18
|
} from '~/communityRepository/communityMembership';
|
|
20
19
|
import { isNonNullable } from '~/utils';
|
|
21
|
-
import { convertEventPayload } from '~/utils/event';
|
|
22
20
|
|
|
23
21
|
export class SearchCommunityLiveCollectionController extends LiveCollectionController<
|
|
24
22
|
'community',
|
|
@@ -83,10 +81,6 @@ export class SearchCommunityLiveCollectionController extends LiveCollectionContr
|
|
|
83
81
|
{ fn: onCommunityUserChanged, action: EnumCommunityMemberActions.OnMemberCountChanged },
|
|
84
82
|
{ fn: onLocalCommunityJoined, action: EnumCommunityMemberActions.OnCommunityJoined },
|
|
85
83
|
{ fn: onLocalCommunityLeft, action: EnumCommunityMemberActions.OnCommunityLeft },
|
|
86
|
-
{
|
|
87
|
-
fn: convertEventPayload(onLocalCommunityJoin, 'targetId', 'community'),
|
|
88
|
-
action: EnumCommunityActions.OnCommunityUpdated,
|
|
89
|
-
},
|
|
90
84
|
]);
|
|
91
85
|
}
|
|
92
86
|
|
package/src/communityRepository/observers/searchCommunities/SearchCommunitiesPaginationController.ts
CHANGED
|
@@ -22,7 +22,6 @@ export class CommunitiesPaginationController extends PaginationController<
|
|
|
22
22
|
isDeleted: inferIsDeleted(params.includeDeleted),
|
|
23
23
|
keyword: params.displayName,
|
|
24
24
|
filter: params.membership,
|
|
25
|
-
includeDiscoverablePrivateCommunity: params.includeDiscoverablePrivateCommunity ?? true,
|
|
26
25
|
options,
|
|
27
26
|
},
|
|
28
27
|
},
|
|
@@ -60,7 +60,7 @@ export class CommunitiesQueryStreamController extends QueryStreamController<
|
|
|
60
60
|
}
|
|
61
61
|
|
|
62
62
|
reactor(action: EnumCommunityActions | EnumCommunityMemberActions) {
|
|
63
|
-
return (community: Amity.
|
|
63
|
+
return (community: Amity.Community) => {
|
|
64
64
|
const collection = pullFromCache<Amity.SearchCommunityLiveCollectionCache>(
|
|
65
65
|
this.cacheKey,
|
|
66
66
|
)?.data;
|
|
@@ -73,7 +73,7 @@ export class CommunitiesQueryStreamController extends QueryStreamController<
|
|
|
73
73
|
|
|
74
74
|
subscribeRTE(
|
|
75
75
|
createSubscriber: {
|
|
76
|
-
fn: (reactor: (channel: Amity.
|
|
76
|
+
fn: (reactor: (channel: Amity.Community) => void) => Amity.Unsubscriber;
|
|
77
77
|
action: EnumCommunityActions | EnumCommunityMemberActions;
|
|
78
78
|
}[],
|
|
79
79
|
) {
|
|
@@ -15,7 +15,6 @@ import {
|
|
|
15
15
|
onLocalCommunityJoined,
|
|
16
16
|
onLocalCommunityLeft,
|
|
17
17
|
onCommunityUserChanged,
|
|
18
|
-
onLocalCommunityJoin,
|
|
19
18
|
} from '~/communityRepository/communityMembership';
|
|
20
19
|
|
|
21
20
|
import { isNonNullable } from '~/utils';
|
|
@@ -25,7 +24,6 @@ import { prepareSemanticSearchCommunityPayload } from '~/communityRepository/uti
|
|
|
25
24
|
import { getActiveClient } from '~/client';
|
|
26
25
|
import { EnumCommunityMemberActions } from '~/communityRepository/communityMembership/observers/getMembers/enums';
|
|
27
26
|
import { filterByCommunityMembership } from '~/core/query';
|
|
28
|
-
import { convertEventPayload } from '~/utils/event';
|
|
29
27
|
|
|
30
28
|
export class SemanticSearchCommunityLiveCollectionController extends LiveCollectionController<
|
|
31
29
|
'semanticSearchCommunity',
|
|
@@ -96,10 +94,6 @@ export class SemanticSearchCommunityLiveCollectionController extends LiveCollect
|
|
|
96
94
|
{ fn: onCommunityUserChanged, action: EnumCommunityMemberActions.OnMemberCountChanged },
|
|
97
95
|
{ fn: onLocalCommunityJoined, action: EnumCommunityMemberActions.OnCommunityJoined },
|
|
98
96
|
{ fn: onLocalCommunityLeft, action: EnumCommunityMemberActions.OnCommunityLeft },
|
|
99
|
-
{
|
|
100
|
-
fn: convertEventPayload(onLocalCommunityJoin, 'targetId', 'community'),
|
|
101
|
-
action: EnumCommunityActions.OnCommunityUpdated,
|
|
102
|
-
},
|
|
103
97
|
]);
|
|
104
98
|
}
|
|
105
99
|
|
|
@@ -29,7 +29,6 @@ export class SemanticSearchCommunityPaginationController extends PaginationContr
|
|
|
29
29
|
...params,
|
|
30
30
|
filter: communityMembershipStatus ?? AmityCommunityMemberStatusFilter.ALL,
|
|
31
31
|
options,
|
|
32
|
-
includeDiscoverablePrivateCommunity: params.includeDiscoverablePrivateCommunity ?? true,
|
|
33
32
|
},
|
|
34
33
|
});
|
|
35
34
|
return queryResponse;
|
|
@@ -63,7 +63,7 @@ export class SemanticSearchCommunityQueryStreamController extends QueryStreamCon
|
|
|
63
63
|
}
|
|
64
64
|
|
|
65
65
|
reactor(action: EnumCommunityActions | EnumCommunityMemberActions) {
|
|
66
|
-
return (community: Amity.
|
|
66
|
+
return (community: Amity.Community) => {
|
|
67
67
|
const collection = pullFromCache<Amity.CommunityLiveCollectionCache>(this.cacheKey)?.data;
|
|
68
68
|
if (!collection) return;
|
|
69
69
|
|
|
@@ -77,7 +77,7 @@ export class SemanticSearchCommunityQueryStreamController extends QueryStreamCon
|
|
|
77
77
|
|
|
78
78
|
subscribeRTE(
|
|
79
79
|
createSubscriber: {
|
|
80
|
-
fn: (reactor: (community: Amity.
|
|
80
|
+
fn: (reactor: (community: Amity.Community) => void) => Amity.Unsubscriber;
|
|
81
81
|
action: EnumCommunityActions | EnumCommunityMemberActions;
|
|
82
82
|
}[],
|
|
83
83
|
) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { pullFromCache } from '~/cache/api';
|
|
2
|
-
import { getActiveUser } from '~/client
|
|
2
|
+
import { getActiveUser } from '~/client';
|
|
3
3
|
|
|
4
4
|
/*
|
|
5
5
|
* verifies membership status
|
|
@@ -12,7 +12,7 @@ function isMember(membership: Amity.Membership<'community'>['communityMembership
|
|
|
12
12
|
* checks if currently logged in user is part of the community
|
|
13
13
|
*/
|
|
14
14
|
function isCurrentUserPartOfCommunity(
|
|
15
|
-
c: Amity.
|
|
15
|
+
c: Amity.Community,
|
|
16
16
|
m: Amity.Membership<'community'>,
|
|
17
17
|
): boolean {
|
|
18
18
|
const { userId } = getActiveUser();
|
|
@@ -28,15 +28,11 @@ function isCurrentUserPartOfCommunity(
|
|
|
28
28
|
* Althought this can be calculated, it's not scalable.
|
|
29
29
|
*/
|
|
30
30
|
export function updateMembershipStatus(
|
|
31
|
-
communities: Amity.
|
|
31
|
+
communities: Amity.Community[],
|
|
32
32
|
communityUsers: Amity.Membership<'community'>[],
|
|
33
|
-
): Amity.
|
|
33
|
+
): Amity.Community[] {
|
|
34
34
|
return communities.map(c => {
|
|
35
|
-
const cachedCommunity = pullFromCache<Amity.
|
|
36
|
-
'community',
|
|
37
|
-
'get',
|
|
38
|
-
c.communityId,
|
|
39
|
-
]);
|
|
35
|
+
const cachedCommunity = pullFromCache<Amity.Community>(['community', 'get', c.communityId]);
|
|
40
36
|
if (cachedCommunity?.data && cachedCommunity?.data.hasOwnProperty('isJoined')) {
|
|
41
37
|
return {
|
|
42
38
|
...cachedCommunity.data,
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { CommunityPostSettingMaps, DefaultCommunityPostSetting } from '~/@types';
|
|
2
2
|
import { updateMembershipStatus } from './communityWithMembership';
|
|
3
|
-
import { convertRawUserToInternalUser } from '~/userRepository/utils/convertRawUserToInternalUser';
|
|
4
3
|
|
|
5
4
|
const getMatchPostSetting = (value: {
|
|
6
5
|
needApprovalOnPostCreation: Amity.RawCommunity['needApprovalOnPostCreation'];
|
|
@@ -14,7 +13,7 @@ const getMatchPostSetting = (value: {
|
|
|
14
13
|
) ?? DefaultCommunityPostSetting;
|
|
15
14
|
|
|
16
15
|
export function addPostSetting({ communities }: { communities: Amity.RawCommunity[] }) {
|
|
17
|
-
return communities.map<Amity.
|
|
16
|
+
return communities.map<Amity.Community>(
|
|
18
17
|
({ needApprovalOnPostCreation, onlyAdminCanPost, ...restCommunityPayload }) => ({
|
|
19
18
|
postSetting: getMatchPostSetting({
|
|
20
19
|
needApprovalOnPostCreation,
|
|
@@ -30,13 +29,10 @@ export const prepareCommunityPayload = (
|
|
|
30
29
|
): Amity.ProcessedCommunityPayload => {
|
|
31
30
|
const communitiesWithPostSetting = addPostSetting({ communities: rawPayload.communities });
|
|
32
31
|
|
|
33
|
-
// Convert users to internal format
|
|
34
|
-
const internalUsers = rawPayload.users.map(convertRawUserToInternalUser);
|
|
35
|
-
|
|
36
32
|
// map users with community
|
|
37
33
|
const mappedCommunityUsers: Array<Amity.Membership<'community'>> = rawPayload.communityUsers.map(
|
|
38
34
|
communityUser => {
|
|
39
|
-
const user =
|
|
35
|
+
const user = rawPayload.users.find(user => user.userId === communityUser.userId)!;
|
|
40
36
|
|
|
41
37
|
return {
|
|
42
38
|
...communityUser,
|
|
@@ -52,33 +48,11 @@ export const prepareCommunityPayload = (
|
|
|
52
48
|
|
|
53
49
|
return {
|
|
54
50
|
...rawPayload,
|
|
55
|
-
users: rawPayload.users.map(convertRawUserToInternalUser),
|
|
56
51
|
communities: communityWithMembershipStatus,
|
|
57
52
|
communityUsers: mappedCommunityUsers,
|
|
58
53
|
};
|
|
59
54
|
};
|
|
60
55
|
|
|
61
|
-
export const prepareCommunityJoinRequestPayload = (
|
|
62
|
-
rawPayload: Amity.CommunityJoinRequestPayload,
|
|
63
|
-
): Amity.ProcessedJoinRequestPayload => {
|
|
64
|
-
const mappedJoinRequests: Array<Amity.InternalJoinRequest> = rawPayload.joinRequests.map(
|
|
65
|
-
joinRequest => {
|
|
66
|
-
return {
|
|
67
|
-
...joinRequest,
|
|
68
|
-
joinRequestId: joinRequest._id,
|
|
69
|
-
};
|
|
70
|
-
},
|
|
71
|
-
);
|
|
72
|
-
|
|
73
|
-
const users = rawPayload.users.map(convertRawUserToInternalUser);
|
|
74
|
-
|
|
75
|
-
return {
|
|
76
|
-
...rawPayload,
|
|
77
|
-
joinRequests: mappedJoinRequests,
|
|
78
|
-
users,
|
|
79
|
-
};
|
|
80
|
-
};
|
|
81
|
-
|
|
82
56
|
export const prepareCommunityMembershipPayload = (
|
|
83
57
|
rawPayload: Amity.CommunityMembershipPayload,
|
|
84
58
|
): Amity.ProcessedCommunityMembershipPayload => {
|
package/src/core/model/index.ts
CHANGED
package/src/index.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { pullFromCache } from '~/cache/api
|
|
1
|
+
import { pullFromCache } from '~/cache/api';
|
|
2
2
|
import { getChannelMessagePreview } from './getChannelMessagePreview';
|
|
3
|
-
import {
|
|
3
|
+
import { LinkedObject } from '~/utils/linkedObject';
|
|
4
4
|
|
|
5
5
|
export const getChannelMessagePreviewWithUser = (
|
|
6
6
|
channel: Amity.StaticInternalChannel,
|
|
@@ -20,7 +20,7 @@ export const getChannelMessagePreviewWithUser = (
|
|
|
20
20
|
const messagePreviewWithUser = messagePreview
|
|
21
21
|
? {
|
|
22
22
|
...messagePreview,
|
|
23
|
-
user: internalUser ?
|
|
23
|
+
user: internalUser ? LinkedObject.user(internalUser) : undefined,
|
|
24
24
|
}
|
|
25
25
|
: null;
|
|
26
26
|
|
|
@@ -22,7 +22,9 @@ import { LinkedObject } from '~/utils/linkedObject';
|
|
|
22
22
|
* @category Post API
|
|
23
23
|
* @async
|
|
24
24
|
*/
|
|
25
|
-
export const getPost = async (
|
|
25
|
+
export const getPost = async (
|
|
26
|
+
postId: Amity.Post['postId'],
|
|
27
|
+
): Promise<Amity.Cached<Amity.InternalPost>> => {
|
|
26
28
|
const client = getActiveClient();
|
|
27
29
|
client.log('post/getPost', postId);
|
|
28
30
|
|
|
@@ -54,7 +56,7 @@ export const getPost = async (postId: Amity.Post['postId']): Promise<Amity.Cache
|
|
|
54
56
|
const result = posts.find(post => post.postId === postId)!;
|
|
55
57
|
|
|
56
58
|
return {
|
|
57
|
-
data:
|
|
59
|
+
data: result,
|
|
58
60
|
cachedAt,
|
|
59
61
|
};
|
|
60
62
|
};
|
|
@@ -72,7 +74,7 @@ export const getPost = async (postId: Amity.Post['postId']): Promise<Amity.Cache
|
|
|
72
74
|
*
|
|
73
75
|
* @category Post API
|
|
74
76
|
*/
|
|
75
|
-
getPost.locally = (postId: Amity.Post['postId']): Amity.Cached<Amity.
|
|
77
|
+
getPost.locally = (postId: Amity.Post['postId']): Amity.Cached<Amity.InternalPost> | undefined => {
|
|
76
78
|
const client = getActiveClient();
|
|
77
79
|
client.log('post/getPost.locally', postId);
|
|
78
80
|
|
|
@@ -83,7 +85,7 @@ getPost.locally = (postId: Amity.Post['postId']): Amity.Cached<Amity.Post> | und
|
|
|
83
85
|
if (!cached) return;
|
|
84
86
|
|
|
85
87
|
return {
|
|
86
|
-
data:
|
|
88
|
+
data: cached.data,
|
|
87
89
|
cachedAt: cached.cachedAt,
|
|
88
90
|
};
|
|
89
91
|
};
|
package/src/postRepository/observers/getGlobalPinnedPosts/GlobalPinnedPostQueryStreamController.ts
CHANGED
|
@@ -4,7 +4,6 @@ import { ingestInCache } from '~/cache/api/ingestInCache';
|
|
|
4
4
|
import { getResolver } from '~/core/model';
|
|
5
5
|
import { getActiveClient } from '~/client';
|
|
6
6
|
import { EnumPostActions } from '../enums';
|
|
7
|
-
import { convertRawUserToInternalUser } from '~/userRepository/utils/convertRawUserToInternalUser';
|
|
8
7
|
|
|
9
8
|
export class GlobalPinnedPostQueryStreamController extends QueryStreamController<
|
|
10
9
|
Amity.PinnedPostPayload,
|
|
@@ -31,12 +30,7 @@ export class GlobalPinnedPostQueryStreamController extends QueryStreamController
|
|
|
31
30
|
const cachedAt = client.cache && Date.now();
|
|
32
31
|
|
|
33
32
|
if (client.cache) {
|
|
34
|
-
|
|
35
|
-
...response,
|
|
36
|
-
users: response.users.map(convertRawUserToInternalUser),
|
|
37
|
-
};
|
|
38
|
-
|
|
39
|
-
ingestInCache(processedPayload, { cachedAt });
|
|
33
|
+
ingestInCache(response, { cachedAt });
|
|
40
34
|
}
|
|
41
35
|
}
|
|
42
36
|
|
|
@@ -3,7 +3,6 @@ import { pullFromCache, pushToCache } from '~/cache/api';
|
|
|
3
3
|
import { ingestInCache } from '~/cache/api/ingestInCache';
|
|
4
4
|
import { getResolver } from '~/core/model';
|
|
5
5
|
import { getActiveClient } from '~/client';
|
|
6
|
-
import { convertRawUserToInternalUser } from '~/userRepository/utils/convertRawUserToInternalUser';
|
|
7
6
|
|
|
8
7
|
export class PinnedPostQueryStreamController extends QueryStreamController<
|
|
9
8
|
Amity.PinnedPostPayload,
|
|
@@ -30,12 +29,7 @@ export class PinnedPostQueryStreamController extends QueryStreamController<
|
|
|
30
29
|
const cachedAt = client.cache && Date.now();
|
|
31
30
|
|
|
32
31
|
if (client.cache) {
|
|
33
|
-
|
|
34
|
-
...response,
|
|
35
|
-
users: response.users ? response.users.map(convertRawUserToInternalUser) : [],
|
|
36
|
-
};
|
|
37
|
-
|
|
38
|
-
ingestInCache(processedPayload, { cachedAt });
|
|
32
|
+
ingestInCache(response, { cachedAt });
|
|
39
33
|
}
|
|
40
34
|
}
|
|
41
35
|
|
|
@@ -85,12 +85,12 @@ export const getPost = (
|
|
|
85
85
|
onPostFlagged,
|
|
86
86
|
(callback: Amity.Listener<Amity.InternalPost>) => {
|
|
87
87
|
return onPostReactionAdded((post: Amity.InternalPost) => {
|
|
88
|
-
callback(
|
|
88
|
+
callback(post);
|
|
89
89
|
});
|
|
90
90
|
},
|
|
91
91
|
(callback: Amity.Listener<Amity.InternalPost>) => {
|
|
92
92
|
return onPostReactionRemoved((post: Amity.InternalPost) => {
|
|
93
|
-
callback(
|
|
93
|
+
callback(post);
|
|
94
94
|
});
|
|
95
95
|
},
|
|
96
96
|
onPostUnflagged,
|
|
@@ -4,7 +4,6 @@ import { convertFromRaw as convertMessageFromRaw } from '~/messageRepository/uti
|
|
|
4
4
|
import { convertFromRaw as convertSubChannelFromRaw } from './convertSubChannelFromRaw';
|
|
5
5
|
|
|
6
6
|
import { updateSubChannelMessagePreviewCache } from '../../messagePreview/utils/updateSubChannelMessagePreviewCache';
|
|
7
|
-
import { convertRawUserToInternalUser } from '~/userRepository/utils/convertRawUserToInternalUser';
|
|
8
7
|
|
|
9
8
|
export const MARKER_INCLUDED_SUB_CHANNEL_TYPE = ['broadcast', 'conversation', 'community'];
|
|
10
9
|
|
|
@@ -45,13 +44,10 @@ export const prepareSubChannelPayload = async (
|
|
|
45
44
|
|
|
46
45
|
const messages = rawPayload.messages.map(m => convertMessageFromRaw(m));
|
|
47
46
|
|
|
48
|
-
const user = rawPayload.users.map(convertRawUserToInternalUser);
|
|
49
|
-
|
|
50
47
|
return {
|
|
51
48
|
...rawPayload,
|
|
52
49
|
messageFeeds,
|
|
53
50
|
messages,
|
|
54
|
-
users: user,
|
|
55
51
|
};
|
|
56
52
|
};
|
|
57
53
|
|
|
@@ -12,10 +12,10 @@ import { BlockedUserLiveCollectionController } from './getBlockedUsers/BlockedUs
|
|
|
12
12
|
* const unblockedUser = await UserRepository.blockUser('userId')
|
|
13
13
|
* ```
|
|
14
14
|
*
|
|
15
|
-
* Blocks a {@link Amity.
|
|
15
|
+
* Blocks a {@link Amity.User}
|
|
16
16
|
*
|
|
17
|
-
* @param params The params to get blocked {@link Amity.
|
|
18
|
-
* @param callback to recieve updates on unblocked {@link Amity.
|
|
17
|
+
* @param params The params to get blocked {@link Amity.User}s
|
|
18
|
+
* @param callback to recieve updates on unblocked {@link Amity.User}s
|
|
19
19
|
* @returns {@link Amity.Unsubscriber} to unsubscribe from collection
|
|
20
20
|
*
|
|
21
21
|
* @category Post API
|
|
@@ -23,7 +23,7 @@ import { BlockedUserLiveCollectionController } from './getBlockedUsers/BlockedUs
|
|
|
23
23
|
*/
|
|
24
24
|
export const getBlockedUsers = (
|
|
25
25
|
params: Amity.BlockedUsersLiveCollection,
|
|
26
|
-
callback: Amity.LiveCollectionCallback<Amity.
|
|
26
|
+
callback: Amity.LiveCollectionCallback<Amity.User>,
|
|
27
27
|
config?: Amity.LiveCollectionConfig,
|
|
28
28
|
): Amity.Unsubscriber => {
|
|
29
29
|
const { log, cache } = getActiveClient();
|
|
@@ -11,9 +11,6 @@ import { channelLinkedObject } from './channelLinkedObject';
|
|
|
11
11
|
import { adLinkedObject } from './adLinkedObject';
|
|
12
12
|
import { pinnedPostLinkedObject } from './pinnedPostLinkedObject';
|
|
13
13
|
import { notificationTrayLinkedObject } from './notificationTrayLinkedObject';
|
|
14
|
-
import { communityLinkedObject } from './communityLinkedObject';
|
|
15
|
-
import { invitationLinkedObject } from './invitationLinkedObject';
|
|
16
|
-
import { joinRequestLinkedObject } from './joinRequestLinkedObject';
|
|
17
14
|
|
|
18
15
|
export const LinkedObject = {
|
|
19
16
|
ad: adLinkedObject,
|
|
@@ -29,7 +26,4 @@ export const LinkedObject = {
|
|
|
29
26
|
channel: channelLinkedObject,
|
|
30
27
|
pinnedPost: pinnedPostLinkedObject,
|
|
31
28
|
notificationTray: notificationTrayLinkedObject,
|
|
32
|
-
community: communityLinkedObject,
|
|
33
|
-
invitation: invitationLinkedObject,
|
|
34
|
-
joinRequest: joinRequestLinkedObject,
|
|
35
29
|
};
|
|
@@ -9,7 +9,7 @@ export const streamLinkedObject = (stream: Amity.InternalStream): Amity.Stream =
|
|
|
9
9
|
},
|
|
10
10
|
get post() {
|
|
11
11
|
if (stream.referenceType !== 'post') return;
|
|
12
|
-
return pullFromCache<Amity.
|
|
12
|
+
return pullFromCache<Amity.InternalPost>(['post', 'get', stream.referenceId])?.data;
|
|
13
13
|
},
|
|
14
14
|
get community() {
|
|
15
15
|
if (stream.targetType !== 'community') return;
|
|
@@ -1,92 +0,0 @@
|
|
|
1
|
-
export {};
|
|
2
|
-
export declare const enum InvitationTypeEnum {
|
|
3
|
-
CommunityMemberInvite = "communityMemberInvite",
|
|
4
|
-
LivestreamInvite = "livestreamInvite"
|
|
5
|
-
}
|
|
6
|
-
export declare const enum InvitationStatusEnum {
|
|
7
|
-
Pending = "pending",
|
|
8
|
-
Approved = "approved",
|
|
9
|
-
Rejected = "rejected",
|
|
10
|
-
Cancelled = "cancelled"
|
|
11
|
-
}
|
|
12
|
-
export declare const enum InvitationSortByEnum {
|
|
13
|
-
FirstCreated = "firstCreated",
|
|
14
|
-
LastCreated = "lastCreated"
|
|
15
|
-
}
|
|
16
|
-
declare global {
|
|
17
|
-
namespace Amity {
|
|
18
|
-
type InvitationType = InvitationTypeEnum;
|
|
19
|
-
type InvitationStatus = InvitationStatusEnum;
|
|
20
|
-
type InvitationTargetType = Extract<Amity.Domain, 'community'>;
|
|
21
|
-
type InvitationTargetMap = {
|
|
22
|
-
community: Amity.InternalCommunity;
|
|
23
|
-
};
|
|
24
|
-
type InvitationTarget<T extends InvitationTargetType> = InvitationTargetMap[T];
|
|
25
|
-
type InvitationSortBy = InvitationSortByEnum;
|
|
26
|
-
type InvitationDomain<T extends Amity.InvitationTargetType = Amity.InvitationTargetType> = T extends 'community' ? {
|
|
27
|
-
communityId: string;
|
|
28
|
-
} : {
|
|
29
|
-
communityId?: string;
|
|
30
|
-
};
|
|
31
|
-
type RawInvitation = {
|
|
32
|
-
_id: string;
|
|
33
|
-
networkId: string;
|
|
34
|
-
type: Amity.InvitationType;
|
|
35
|
-
targetId: string;
|
|
36
|
-
targetType: Amity.InvitationTargetType;
|
|
37
|
-
userId: string;
|
|
38
|
-
status: Amity.InvitationStatus;
|
|
39
|
-
respondedAt: Amity.timestamp;
|
|
40
|
-
createdBy: string;
|
|
41
|
-
invitationId: string;
|
|
42
|
-
invitedUserId: string;
|
|
43
|
-
invitedUserInternalId: string;
|
|
44
|
-
invitedUserPublicId: string;
|
|
45
|
-
inviterUserId: string;
|
|
46
|
-
inviterUserInternalId: string;
|
|
47
|
-
inviterUserPublicId: string;
|
|
48
|
-
} & Amity.Timestamps & Amity.InvitationDomain<Amity.InvitationTargetType>;
|
|
49
|
-
type InternalInvitation = Omit<RawInvitation, 'createdBy'> & {
|
|
50
|
-
createdById: string;
|
|
51
|
-
};
|
|
52
|
-
type Invitation = Omit<Amity.InternalInvitation, 'createdBy'> & Amity.InvitationLinkedObject & {
|
|
53
|
-
user?: Amity.User;
|
|
54
|
-
createdById: string;
|
|
55
|
-
createdBy?: Amity.User;
|
|
56
|
-
target?: Amity.InvitationTarget<Amity.InvitationTargetType>;
|
|
57
|
-
};
|
|
58
|
-
type QueryInvitations = {
|
|
59
|
-
targetId: string;
|
|
60
|
-
statuses?: string[];
|
|
61
|
-
token?: Amity.Token;
|
|
62
|
-
type: Amity.InvitationType;
|
|
63
|
-
sortBy?: Amity.InvitationSortBy;
|
|
64
|
-
limit?: Amity.PageLimit['limit'];
|
|
65
|
-
targetType: Amity.InvitationTargetType;
|
|
66
|
-
};
|
|
67
|
-
type InvitationLiveCollection = Amity.LiveCollectionParams<Omit<QueryInvitations, 'limit'>>;
|
|
68
|
-
type InvitationLiveCollectionCache = Amity.LiveCollectionCache<Amity.InternalInvitation['_id'], Pick<QueryInvitations, 'limit'>>;
|
|
69
|
-
type QueryMyInvitations = {
|
|
70
|
-
targetId?: string;
|
|
71
|
-
token?: Amity.Token;
|
|
72
|
-
type?: Amity.InvitationType;
|
|
73
|
-
sortBy?: Amity.InvitationSortBy;
|
|
74
|
-
limit?: Amity.PageLimit['limit'];
|
|
75
|
-
statuses?: InvitationStatusEnum[];
|
|
76
|
-
targetType?: Amity.InvitationTargetType;
|
|
77
|
-
};
|
|
78
|
-
type MyInvitationsLiveCollection = Amity.LiveCollectionParams<Omit<QueryMyInvitations, 'limit'>>;
|
|
79
|
-
type MyInvitationsLiveCollectionCache = Amity.LiveCollectionCache<Amity.InternalInvitation['_id'], Pick<QueryMyInvitations, 'limit'>>;
|
|
80
|
-
type InvitationLinkedObject = {
|
|
81
|
-
accept: () => Promise<void>;
|
|
82
|
-
reject: () => Promise<void>;
|
|
83
|
-
};
|
|
84
|
-
type CreateInvitations = {
|
|
85
|
-
type: Amity.InvitationType;
|
|
86
|
-
targetType: Amity.InvitationTargetType;
|
|
87
|
-
targetId: string;
|
|
88
|
-
userIds: string[];
|
|
89
|
-
};
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
//# sourceMappingURL=invitation.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"invitation.d.ts","sourceRoot":"","sources":["../../../src/@types/domains/invitation.ts"],"names":[],"mappings":"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"}
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
export {};
|
|
2
|
-
export declare const enum JoinRequestStatusEnum {
|
|
3
|
-
Pending = "pending",
|
|
4
|
-
Approved = "approved",
|
|
5
|
-
Rejected = "rejected",
|
|
6
|
-
Cancelled = "cancelled"
|
|
7
|
-
}
|
|
8
|
-
export declare const enum JoinResultStatusEnum {
|
|
9
|
-
Success = "success",
|
|
10
|
-
Pending = "pending"
|
|
11
|
-
}
|
|
12
|
-
declare global {
|
|
13
|
-
namespace Amity {
|
|
14
|
-
type JoinRequestStatus = JoinRequestStatusEnum;
|
|
15
|
-
type JoinResultStatus = JoinResultStatusEnum;
|
|
16
|
-
type JoinRequestType = 'communityJoinRequest';
|
|
17
|
-
type JoinResult = {
|
|
18
|
-
status: Amity.JoinResultStatus;
|
|
19
|
-
request?: Amity.JoinRequest;
|
|
20
|
-
};
|
|
21
|
-
type RawJoinRequest = {
|
|
22
|
-
_id: string;
|
|
23
|
-
createdAt: Amity.timestamp;
|
|
24
|
-
joinRequestId: string;
|
|
25
|
-
networkId: string;
|
|
26
|
-
requestorId: string;
|
|
27
|
-
requestorInternalId: string;
|
|
28
|
-
requestorPublicId: string;
|
|
29
|
-
respondedAt: Amity.timestamp | null;
|
|
30
|
-
responderId: string | null;
|
|
31
|
-
responderInternalId: string | null;
|
|
32
|
-
responderPublicId: string | null;
|
|
33
|
-
status: Amity.JoinRequestStatus;
|
|
34
|
-
targetId: string;
|
|
35
|
-
targetType: string;
|
|
36
|
-
type: Amity.JoinRequestType;
|
|
37
|
-
updatedAt: Amity.timestamp;
|
|
38
|
-
userId: string;
|
|
39
|
-
};
|
|
40
|
-
type InternalJoinRequest = Omit<RawJoinRequest, '_id'>;
|
|
41
|
-
type JoinRequest = Omit<Amity.InternalJoinRequest, 'responderId'> & Amity.JoinRequestLinkedObject & {
|
|
42
|
-
user?: Amity.User;
|
|
43
|
-
feeds?: Amity.Feed[];
|
|
44
|
-
files?: Amity.File[];
|
|
45
|
-
};
|
|
46
|
-
type JoinRequestLinkedObject = {
|
|
47
|
-
cancel: () => Promise<void>;
|
|
48
|
-
approve: () => Promise<void>;
|
|
49
|
-
reject: () => Promise<void>;
|
|
50
|
-
};
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
//# sourceMappingURL=joinRequest.d.ts.map
|