@amityco/ts-sdk 7.29.0 → 7.29.1-32c8dde1.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/core/errors.d.ts +4 -1
- package/dist/@types/core/errors.d.ts.map +1 -1
- package/dist/@types/domains/channel.d.ts +13 -1
- package/dist/@types/domains/channel.d.ts.map +1 -1
- package/dist/@types/domains/content.d.ts +11 -0
- package/dist/@types/domains/content.d.ts.map +1 -1
- package/dist/@types/domains/user.d.ts +89 -0
- package/dist/@types/domains/user.d.ts.map +1 -1
- package/dist/channelRepository/observers/getChannels/ChannelLiveCollectionController.d.ts.map +1 -1
- package/dist/channelRepository/observers/searchChannels/SearchChannelLiveCollectionController.d.ts.map +1 -1
- package/dist/channelRepository/observers/tests/integrations/getChannelsSortByLastMessage.integration.test.d.ts +2 -0
- package/dist/channelRepository/observers/tests/integrations/getChannelsSortByLastMessage.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/utils/channelActivityOnLoginHandler.d.ts +16 -0
- package/dist/channelRepository/utils/channelActivityOnLoginHandler.d.ts.map +1 -0
- package/dist/channelRepository/utils/tests/integrations/channelActivity.integration.test.d.ts +2 -0
- package/dist/channelRepository/utils/tests/integrations/channelActivity.integration.test.d.ts.map +1 -0
- package/dist/channelRepository/utils/tests/updateChannelActivityTimestamps.test.d.ts +2 -0
- package/dist/channelRepository/utils/tests/updateChannelActivityTimestamps.test.d.ts.map +1 -0
- package/dist/channelRepository/utils/updateChannelActivityTimestamps.d.ts +42 -0
- package/dist/channelRepository/utils/updateChannelActivityTimestamps.d.ts.map +1 -0
- package/dist/client/api/resumeSession.d.ts.map +1 -1
- package/dist/client/api/setupLoginSubscriptions.d.ts.map +1 -1
- package/dist/commentRepository/api/flagComment.d.ts +72 -5
- package/dist/commentRepository/api/flagComment.d.ts.map +1 -1
- package/dist/commentRepository/internalApi/flagCommentWithOptions.d.ts +13 -0
- package/dist/commentRepository/internalApi/flagCommentWithOptions.d.ts.map +1 -0
- package/dist/commentRepository/internalApi/flagCommentWithReasonString.d.ts +17 -0
- package/dist/commentRepository/internalApi/flagCommentWithReasonString.d.ts.map +1 -0
- package/dist/commentRepository/internalApi/index.d.ts +2 -0
- package/dist/commentRepository/internalApi/index.d.ts.map +1 -1
- package/dist/commentRepository/internalApi/tests/integration/flagCommentWithOptions.integration.test.d.ts +2 -0
- package/dist/commentRepository/internalApi/tests/integration/flagCommentWithOptions.integration.test.d.ts.map +1 -0
- package/dist/commentRepository/internalApi/tests/integration/flagCommentWithReasonString.integration.test.d.ts +2 -0
- package/dist/commentRepository/internalApi/tests/integration/flagCommentWithReasonString.integration.test.d.ts.map +1 -0
- package/dist/core/microtasks.d.ts.map +1 -1
- package/dist/core/query/sorting.d.ts +10 -0
- package/dist/core/query/sorting.d.ts.map +1 -1
- package/dist/core/query/tests/sorting.test.d.ts +2 -0
- package/dist/core/query/tests/sorting.test.d.ts.map +1 -0
- package/dist/core/tests/microtasks.test.d.ts +2 -0
- package/dist/core/tests/microtasks.test.d.ts.map +1 -0
- package/dist/core/transports/tests/integration/serverErrorCodes.integration.test.d.ts +2 -0
- package/dist/core/transports/tests/integration/serverErrorCodes.integration.test.d.ts.map +1 -0
- package/dist/index.cjs.js +940 -140
- package/dist/index.esm.js +941 -142
- package/dist/index.umd.js +2 -2
- package/dist/messagePreview/utils/getChannelMessagePreviewWithUser.d.ts +1 -0
- package/dist/messagePreview/utils/getChannelMessagePreviewWithUser.d.ts.map +1 -1
- package/dist/messagePreview/utils/getSubChannelMessagePreviewWithUser.d.ts +1 -1
- package/dist/messagePreview/utils/getSubChannelMessagePreviewWithUser.d.ts.map +1 -1
- package/dist/messageRepository/api/createMessage.d.ts.map +1 -1
- package/dist/messageRepository/api/flagMessage.d.ts +73 -6
- package/dist/messageRepository/api/flagMessage.d.ts.map +1 -1
- package/dist/messageRepository/api/tests/integration/flagMessage.overloads.integration.test.d.ts +2 -0
- package/dist/messageRepository/api/tests/integration/flagMessage.overloads.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/internalApi/flagMessageWithOptions.d.ts +13 -0
- package/dist/messageRepository/internalApi/flagMessageWithOptions.d.ts.map +1 -0
- package/dist/messageRepository/internalApi/flagMessageWithReasonString.d.ts +18 -0
- package/dist/messageRepository/internalApi/flagMessageWithReasonString.d.ts.map +1 -0
- package/dist/messageRepository/internalApi/tests/integration/flagMessageWithOptions.integration.test.d.ts +2 -0
- package/dist/messageRepository/internalApi/tests/integration/flagMessageWithOptions.integration.test.d.ts.map +1 -0
- package/dist/messageRepository/internalApi/tests/integration/flagMessageWithReasonString.integration.test.d.ts +2 -0
- package/dist/messageRepository/internalApi/tests/integration/flagMessageWithReasonString.integration.test.d.ts.map +1 -0
- package/dist/postRepository/api/flagPost.d.ts +73 -6
- package/dist/postRepository/api/flagPost.d.ts.map +1 -1
- package/dist/postRepository/api/tests/integration/flagPost.overloads.integration.test.d.ts +2 -0
- package/dist/postRepository/api/tests/integration/flagPost.overloads.integration.test.d.ts.map +1 -0
- package/dist/postRepository/api/tests/integration/setup.d.ts +3 -3
- package/dist/postRepository/internalApi/flagPostWithOptions.d.ts +13 -0
- package/dist/postRepository/internalApi/flagPostWithOptions.d.ts.map +1 -0
- package/dist/postRepository/internalApi/flagPostWithReasonString.d.ts +17 -0
- package/dist/postRepository/internalApi/flagPostWithReasonString.d.ts.map +1 -0
- package/dist/postRepository/internalApi/index.d.ts +2 -0
- package/dist/postRepository/internalApi/index.d.ts.map +1 -1
- package/dist/postRepository/internalApi/tests/integration/flagPostWithOptions.integration.test.d.ts +2 -0
- package/dist/postRepository/internalApi/tests/integration/flagPostWithOptions.integration.test.d.ts.map +1 -0
- package/dist/postRepository/internalApi/tests/integration/flagPostWithReasonString.integration.test.d.ts +2 -0
- package/dist/postRepository/internalApi/tests/integration/flagPostWithReasonString.integration.test.d.ts.map +1 -0
- package/dist/report/api/isReportedByMe.d.ts.map +1 -1
- package/dist/userRepository/api/flagUser.d.ts +50 -9
- package/dist/userRepository/api/flagUser.d.ts.map +1 -1
- package/dist/userRepository/api/flagUserBehavior.d.ts +29 -0
- package/dist/userRepository/api/flagUserBehavior.d.ts.map +1 -0
- package/dist/userRepository/api/flagUserProfile.d.ts +29 -0
- package/dist/userRepository/api/flagUserProfile.d.ts.map +1 -0
- package/dist/userRepository/api/index.d.ts +2 -0
- package/dist/userRepository/api/index.d.ts.map +1 -1
- package/dist/userRepository/api/isUserFlaggedByMe.d.ts +26 -4
- package/dist/userRepository/api/isUserFlaggedByMe.d.ts.map +1 -1
- package/dist/userRepository/api/queryBlockedUsers.d.ts.map +1 -1
- package/dist/userRepository/api/tests/integration/flagUser.overloads.integration.test.d.ts +2 -0
- package/dist/userRepository/api/tests/integration/flagUser.overloads.integration.test.d.ts.map +1 -0
- package/dist/userRepository/api/tests/integration/flagUserBehavior.integration.test.d.ts +2 -0
- package/dist/userRepository/api/tests/integration/flagUserBehavior.integration.test.d.ts.map +1 -0
- package/dist/userRepository/api/tests/integration/flagUserProfile.integration.test.d.ts +2 -0
- package/dist/userRepository/api/tests/integration/flagUserProfile.integration.test.d.ts.map +1 -0
- package/dist/userRepository/api/unflagUser.d.ts +26 -4
- package/dist/userRepository/api/unflagUser.d.ts.map +1 -1
- package/dist/userRepository/api/updateUser.d.ts.map +1 -1
- package/dist/userRepository/internalApi/getFlagsByMe.d.ts +21 -0
- package/dist/userRepository/internalApi/getFlagsByMe.d.ts.map +1 -0
- package/dist/userRepository/observers/getBlockedUsers/BlockedUserLiveCollectionController.d.ts +2 -2
- package/dist/userRepository/observers/getBlockedUsers/BlockedUserLiveCollectionController.d.ts.map +1 -1
- package/dist/userRepository/observers/getBlockingUsers/LiveCollectionController.d.ts +1 -1
- package/dist/userRepository/observers/getBlockingUsers/LiveCollectionController.d.ts.map +1 -1
- package/dist/userRepository/observers/getUsers/UserLiveCollectionController.d.ts +2 -2
- package/dist/userRepository/observers/getUsers/UserLiveCollectionController.d.ts.map +1 -1
- package/dist/userRepository/observers/searchUserByDisplayName/SearchUserLiveCollectionController.d.ts +2 -2
- package/dist/userRepository/observers/searchUserByDisplayName/SearchUserLiveCollectionController.d.ts.map +1 -1
- package/dist/userRepository/utils/submitUserReport.d.ts +10 -0
- package/dist/userRepository/utils/submitUserReport.d.ts.map +1 -0
- package/dist/userRepository/utils/userReport.d.ts +50 -0
- package/dist/userRepository/utils/userReport.d.ts.map +1 -0
- package/dist/utils/bloomFilter.d.ts +9 -0
- package/dist/utils/bloomFilter.d.ts.map +1 -0
- package/dist/utils/contentFlag.d.ts +28 -0
- package/dist/utils/contentFlag.d.ts.map +1 -0
- package/dist/utils/linkedObject/tests/userLinkedObject.test.d.ts +2 -0
- package/dist/utils/linkedObject/tests/userLinkedObject.test.d.ts.map +1 -0
- package/dist/utils/linkedObject/userLinkedObject.d.ts.map +1 -1
- package/dist/utils/tests/bloomFilter.test.d.ts +2 -0
- package/dist/utils/tests/bloomFilter.test.d.ts.map +1 -0
- package/dist/utils/tests/client.d.ts +1 -1
- package/dist/utils/tests/client.d.ts.map +1 -1
- package/dist/utils/tests/dummy/channel.d.ts +13 -9
- package/dist/utils/tests/dummy/channel.d.ts.map +1 -1
- package/dist/utils/tests/dummy/comment.d.ts +1 -1
- package/dist/utils/tests/dummy/community.d.ts +3 -3
- package/dist/utils/tests/dummy/message.d.ts +1 -1
- package/dist/utils/tests/dummy/token.d.ts +1 -1
- package/dist/utils/tests/dummy/user.d.ts +10 -12
- package/dist/utils/tests/dummy/user.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/userRepository/api/tests/integration/flagUser.overloads.integration.test.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"flagUser.overloads.integration.test.d.ts","sourceRoot":"","sources":["../../../../../src/userRepository/api/tests/integration/flagUser.overloads.integration.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"flagUserBehavior.integration.test.d.ts","sourceRoot":"","sources":["../../../../../src/userRepository/api/tests/integration/flagUserBehavior.integration.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"flagUserProfile.integration.test.d.ts","sourceRoot":"","sources":["../../../../../src/userRepository/api/tests/integration/flagUserProfile.integration.test.ts"],"names":[],"mappings":""}
|
|
@@ -1,14 +1,36 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* ```js
|
|
3
|
-
* import { UserRepository } from '@amityco/ts-sdk'
|
|
4
|
-
*
|
|
3
|
+
* import { UserRepository, UserReportTypeFilterEnum } from '@amityco/ts-sdk'
|
|
4
|
+
*
|
|
5
|
+
* // Withdraw every report I filed on the user.
|
|
6
|
+
* const unflagged = await UserRepository.unflagUser('userId')
|
|
7
|
+
*
|
|
8
|
+
* // Withdraw only my behavior report; my other reports on the user stay.
|
|
9
|
+
* await UserRepository.unflagUser('userId', { reportType: UserReportTypeFilterEnum.BEHAVIOR })
|
|
10
|
+
*
|
|
11
|
+
* // Withdraw only my typeless (legacy) report.
|
|
12
|
+
* await UserRepository.unflagUser('userId', { reportType: UserReportTypeFilterEnum.UNTYPED })
|
|
5
13
|
* ```
|
|
6
14
|
*
|
|
15
|
+
* Withdraws the caller's reports on a user. Without `reportType` every report the caller
|
|
16
|
+
* filed on that user is withdrawn, as before. With `reportType` only the caller's report
|
|
17
|
+
* of that type is withdrawn; the caller's other reports and other users' reports are
|
|
18
|
+
* untouched. Withdrawing a report that does not exist succeeds and changes nothing.
|
|
19
|
+
*
|
|
20
|
+
* The returned user is persisted to the cache, so its `hashFlag` says whether the caller
|
|
21
|
+
* still holds any report on the user. Do not flip a local "flagged by me" flag to `false`
|
|
22
|
+
* after a per-type withdrawal; read the fresh user, or call `isUserFlaggedByMe` for the
|
|
23
|
+
* remaining per-type state (`flags`).
|
|
24
|
+
*
|
|
25
|
+
* Sends `DELETE /api/v4/me/flags/:userId`, with `?reportType=<type>` when one is given.
|
|
26
|
+
*
|
|
7
27
|
* @param userId The ID of the user to unflag
|
|
8
|
-
* @
|
|
28
|
+
* @param options Optional; `reportType` selects a single report to withdraw. For a report that `isUserFlaggedByMe` lists with `reportType: null`, pass `UserReportTypeFilterEnum.UNTYPED`
|
|
29
|
+
* @returns `true` once the server has processed the withdrawal
|
|
30
|
+
* @throws {ASCInvalidParameterError} `INVALID_PARAMETERS` when `reportType` is not a `UserReportTypeFilterEnum` value, before any request is made
|
|
9
31
|
*
|
|
10
32
|
* @category User API
|
|
11
33
|
* @async
|
|
12
34
|
* */
|
|
13
|
-
export declare const unflagUser: (userId: Amity.User['userId']) => Promise<boolean>;
|
|
35
|
+
export declare const unflagUser: (userId: Amity.User['userId'], options?: Amity.UserReportTypeFilterOptions) => Promise<boolean>;
|
|
14
36
|
//# sourceMappingURL=unflagUser.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"unflagUser.d.ts","sourceRoot":"","sources":["../../../src/userRepository/api/unflagUser.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"unflagUser.d.ts","sourceRoot":"","sources":["../../../src/userRepository/api/unflagUser.ts"],"names":[],"mappings":"AAUA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAiCK;AACL,eAAO,MAAM,UAAU,WACb,MAAM,IAAI,CAAC,QAAQ,CAAC,YAClB,MAAM,2BAA2B,KAC1C,QAAQ,OAAO,CAoBjB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"updateUser.d.ts","sourceRoot":"","sources":["../../../src/userRepository/api/updateUser.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"updateUser.d.ts","sourceRoot":"","sources":["../../../src/userRepository/api/updateUser.ts"],"names":[],"mappings":"AAUA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,UAAU,WACb,MAAM,IAAI,CAAC,QAAQ,CAAC,SACrB,MACL,MAAM,IAAI,EACV,aAAa,GAAG,aAAa,GAAG,cAAc,GAAG,iBAAiB,GAAG,UAAU,CAChF,KACA,QAAQ,MAAM,MAAM,CAAC,MAAM,IAAI,CAAC,CAqBlC,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ```js
|
|
3
|
+
* import { getFlagsByMe } from '~/userRepository/internalApi/getFlagsByMe'
|
|
4
|
+
* const { isFlagByMe, flags } = await getFlagsByMe('userId')
|
|
5
|
+
* ```
|
|
6
|
+
*
|
|
7
|
+
* The v4 read behind `user.getUserFlagsByMe()` and the deprecated
|
|
8
|
+
* `UserRepository.isUserFlaggedByMe`: `GET /api/v4/users/:userId/isFlagByMe`, returned as
|
|
9
|
+
* received. Nothing is filtered, cached or persisted, and `hashFlag` is not consulted here.
|
|
10
|
+
* This is the Web counterpart of iOS `ASCUserService.getFlagsByMe` and Android
|
|
11
|
+
* `UserRepository.getFlagsByMe`, kept apart from the deprecated public function so the
|
|
12
|
+
* user-object read does not change if that function ever does.
|
|
13
|
+
*
|
|
14
|
+
* @param userId The ID of the user whose reports by the caller are read
|
|
15
|
+
* @returns the caller's {@link Amity.UserFlagByMe} on that user
|
|
16
|
+
*
|
|
17
|
+
* @category Private
|
|
18
|
+
* @async
|
|
19
|
+
*/
|
|
20
|
+
export declare const getFlagsByMe: (userId: Amity.User['userId']) => Promise<Amity.UserFlagByMe>;
|
|
21
|
+
//# sourceMappingURL=getFlagsByMe.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getFlagsByMe.d.ts","sourceRoot":"","sources":["../../../src/userRepository/internalApi/getFlagsByMe.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,YAAY,WAAkB,MAAM,IAAI,CAAC,QAAQ,CAAC,KAAG,QAAQ,MAAM,YAAY,CAS3F,CAAC"}
|
package/dist/userRepository/observers/getBlockedUsers/BlockedUserLiveCollectionController.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { BlockedUserPaginationController } from './BlockedUserPaginationController';
|
|
2
1
|
import { LiveCollectionController } from '~/core/liveCollection/LiveCollectionController';
|
|
2
|
+
import { BlockedUserPaginationController } from './BlockedUserPaginationController';
|
|
3
3
|
export declare class BlockedUserLiveCollectionController extends LiveCollectionController<'blockUser', Amity.BlockedUsersLiveCollection, Amity.User, BlockedUserPaginationController> {
|
|
4
4
|
private queryStreamController;
|
|
5
5
|
private query;
|
|
@@ -9,6 +9,6 @@ export declare class BlockedUserLiveCollectionController extends LiveCollectionC
|
|
|
9
9
|
protected persistQueryStream({ response, direction, refresh, }: Amity.LiveCollectionPersistQueryStreamParams<'blockUser'>): void;
|
|
10
10
|
startSubscription(): Amity.Unsubscriber[];
|
|
11
11
|
notifyChange({ origin, loading, error }: Amity.LiveCollectionNotifyParams): void;
|
|
12
|
-
applyFilter(data: Amity.
|
|
12
|
+
applyFilter(data: Amity.User[]): Amity.User[];
|
|
13
13
|
}
|
|
14
14
|
//# sourceMappingURL=BlockedUserLiveCollectionController.d.ts.map
|
package/dist/userRepository/observers/getBlockedUsers/BlockedUserLiveCollectionController.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BlockedUserLiveCollectionController.d.ts","sourceRoot":"","sources":["../../../../src/userRepository/observers/getBlockedUsers/BlockedUserLiveCollectionController.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE
|
|
1
|
+
{"version":3,"file":"BlockedUserLiveCollectionController.d.ts","sourceRoot":"","sources":["../../../../src/userRepository/observers/getBlockedUsers/BlockedUserLiveCollectionController.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,wBAAwB,EAAE,MAAM,gDAAgD,CAAC;AAa1F,OAAO,EAAE,+BAA+B,EAAE,MAAM,mCAAmC,CAAC;AAEpF,qBAAa,mCAAoC,SAAQ,wBAAwB,CAC/E,WAAW,EACX,KAAK,CAAC,0BAA0B,EAChC,KAAK,CAAC,IAAI,EACV,+BAA+B,CAChC;IACC,OAAO,CAAC,qBAAqB,CAAmC;IAEhE,OAAO,CAAC,KAAK,CAAmC;gBAG9C,KAAK,EAAE,KAAK,CAAC,0BAA0B,EACvC,QAAQ,EAAE,KAAK,CAAC,sBAAsB,CAAC,KAAK,CAAC,IAAI,CAAC;IAoBpD,SAAS,CAAC,KAAK;cAUC,YAAY,CAAC,YAAY,EAAE,KAAK,CAAC,kBAAkB,GAAG,KAAK,CAAC,UAAU;IAItF,SAAS,CAAC,kBAAkB,CAAC,EAC3B,QAAQ,EACR,SAAS,EACT,OAAO,GACR,EAAE,KAAK,CAAC,sCAAsC,CAAC,WAAW,CAAC;IAI5D,iBAAiB;IAmCjB,YAAY,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,KAAK,CAAC,0BAA0B;IAuBzE,WAAW,CAAC,IAAI,EAAE,KAAK,CAAC,IAAI,EAAE;CAO/B"}
|
|
@@ -8,6 +8,6 @@ export declare class BlockingUserLiveCollectionController extends LiveCollection
|
|
|
8
8
|
protected persistQueryStream({ response, direction, refresh, }: Amity.LiveCollectionPersistQueryStreamParams<'blockingUser'>): void;
|
|
9
9
|
startSubscription(): Amity.Unsubscriber[];
|
|
10
10
|
notifyChange({ origin, loading, error }: Amity.LiveCollectionNotifyParams): void;
|
|
11
|
-
applyFilter(data: Amity.
|
|
11
|
+
applyFilter(data: Amity.User[]): Amity.User[];
|
|
12
12
|
}
|
|
13
13
|
//# sourceMappingURL=LiveCollectionController.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LiveCollectionController.d.ts","sourceRoot":"","sources":["../../../../src/userRepository/observers/getBlockingUsers/LiveCollectionController.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,wBAAwB,EAAE,MAAM,gDAAgD,CAAC;AAQ1F,OAAO,EAAE,gCAAgC,EAAE,MAAM,wBAAwB,CAAC;AAG1E,qBAAa,oCAAqC,SAAQ,wBAAwB,CAChF,cAAc,EACd,KAAK,CAAC,2BAA2B,EACjC,KAAK,CAAC,IAAI,EACV,gCAAgC,CACjC;IACC,OAAO,CAAC,qBAAqB,CAAoC;gBAErD,QAAQ,EAAE,KAAK,CAAC,sBAAsB,CAAC,KAAK,CAAC,IAAI,CAAC;IAmB9D,SAAS,CAAC,KAAK;cAUC,YAAY,CAAC,YAAY,EAAE,KAAK,CAAC,mBAAmB,GAAG,KAAK,CAAC,UAAU;IAIvF,SAAS,CAAC,kBAAkB,CAAC,EAC3B,QAAQ,EACR,SAAS,EACT,OAAO,GACR,EAAE,KAAK,CAAC,sCAAsC,CAAC,cAAc,CAAC;IAI/D,iBAAiB;IA2BjB,YAAY,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,KAAK,CAAC,0BAA0B;IAsBzE,WAAW,CAAC,IAAI,EAAE,KAAK,CAAC,
|
|
1
|
+
{"version":3,"file":"LiveCollectionController.d.ts","sourceRoot":"","sources":["../../../../src/userRepository/observers/getBlockingUsers/LiveCollectionController.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,wBAAwB,EAAE,MAAM,gDAAgD,CAAC;AAQ1F,OAAO,EAAE,gCAAgC,EAAE,MAAM,wBAAwB,CAAC;AAG1E,qBAAa,oCAAqC,SAAQ,wBAAwB,CAChF,cAAc,EACd,KAAK,CAAC,2BAA2B,EACjC,KAAK,CAAC,IAAI,EACV,gCAAgC,CACjC;IACC,OAAO,CAAC,qBAAqB,CAAoC;gBAErD,QAAQ,EAAE,KAAK,CAAC,sBAAsB,CAAC,KAAK,CAAC,IAAI,CAAC;IAmB9D,SAAS,CAAC,KAAK;cAUC,YAAY,CAAC,YAAY,EAAE,KAAK,CAAC,mBAAmB,GAAG,KAAK,CAAC,UAAU;IAIvF,SAAS,CAAC,kBAAkB,CAAC,EAC3B,QAAQ,EACR,SAAS,EACT,OAAO,GACR,EAAE,KAAK,CAAC,sCAAsC,CAAC,cAAc,CAAC;IAI/D,iBAAiB;IA2BjB,YAAY,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,KAAK,CAAC,0BAA0B;IAsBzE,WAAW,CAAC,IAAI,EAAE,KAAK,CAAC,IAAI,EAAE;CAO/B"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { UserPaginationController } from './UserPaginationController';
|
|
2
1
|
import { LiveCollectionController } from '~/core/liveCollection/LiveCollectionController';
|
|
2
|
+
import { UserPaginationController } from './UserPaginationController';
|
|
3
3
|
export declare class UserLiveCollectionController extends LiveCollectionController<'user', Amity.UserLiveCollection, Amity.User, UserPaginationController> {
|
|
4
4
|
private queryStreamController;
|
|
5
5
|
private query;
|
|
@@ -9,6 +9,6 @@ export declare class UserLiveCollectionController extends LiveCollectionControll
|
|
|
9
9
|
protected persistQueryStream({ response, direction, refresh, }: Amity.LiveCollectionPersistQueryStreamParams<'user'>): void;
|
|
10
10
|
startSubscription(): Amity.Unsubscriber[];
|
|
11
11
|
notifyChange({ origin, loading, error }: Amity.LiveCollectionNotifyParams): void;
|
|
12
|
-
applyFilter(data: Amity.
|
|
12
|
+
applyFilter(data: Amity.User[]): Amity.User[];
|
|
13
13
|
}
|
|
14
14
|
//# sourceMappingURL=UserLiveCollectionController.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UserLiveCollectionController.d.ts","sourceRoot":"","sources":["../../../../src/userRepository/observers/getUsers/UserLiveCollectionController.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,wBAAwB,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"UserLiveCollectionController.d.ts","sourceRoot":"","sources":["../../../../src/userRepository/observers/getUsers/UserLiveCollectionController.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,wBAAwB,EAAE,MAAM,gDAAgD,CAAC;AAc1F,OAAO,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAC;AAEtE,qBAAa,4BAA6B,SAAQ,wBAAwB,CACxE,MAAM,EACN,KAAK,CAAC,kBAAkB,EACxB,KAAK,CAAC,IAAI,EACV,wBAAwB,CACzB;IACC,OAAO,CAAC,qBAAqB,CAA4B;IAEzD,OAAO,CAAC,KAAK,CAA2B;gBAE5B,KAAK,EAAE,KAAK,CAAC,kBAAkB,EAAE,QAAQ,EAAE,KAAK,CAAC,sBAAsB,CAAC,KAAK,CAAC,IAAI,CAAC;IAmB/F,SAAS,CAAC,KAAK;cAUC,YAAY,CAAC,YAAY,EAAE,KAAK,CAAC,WAAW,GAAG,KAAK,CAAC,UAAU;IAI/E,SAAS,CAAC,kBAAkB,CAAC,EAC3B,QAAQ,EACR,SAAS,EACT,OAAO,GACR,EAAE,KAAK,CAAC,sCAAsC,CAAC,MAAM,CAAC;IAIvD,iBAAiB;IAUjB,YAAY,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,KAAK,CAAC,0BAA0B;IAuBzE,WAAW,CAAC,IAAI,EAAE,KAAK,CAAC,IAAI,EAAE;CAwB/B"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { SearchUserPaginationController } from './SearchUserPaginationController';
|
|
2
1
|
import { LiveCollectionController } from '~/core/liveCollection/LiveCollectionController';
|
|
2
|
+
import { SearchUserPaginationController } from './SearchUserPaginationController';
|
|
3
3
|
export declare class SearchUserLiveCollectionController extends LiveCollectionController<'user', Amity.SearchUserLiveCollection, Amity.User, SearchUserPaginationController> {
|
|
4
4
|
private queryStreamController;
|
|
5
5
|
private query;
|
|
@@ -9,6 +9,6 @@ export declare class SearchUserLiveCollectionController extends LiveCollectionCo
|
|
|
9
9
|
protected persistQueryStream({ response, direction, refresh, }: Amity.LiveCollectionPersistQueryStreamParams<'user'>): void;
|
|
10
10
|
startSubscription(): Amity.Unsubscriber[];
|
|
11
11
|
notifyChange({ origin, loading, error }: Amity.LiveCollectionNotifyParams): void;
|
|
12
|
-
applyFilter(data: Amity.
|
|
12
|
+
applyFilter(data: Amity.User[]): Amity.User[];
|
|
13
13
|
}
|
|
14
14
|
//# sourceMappingURL=SearchUserLiveCollectionController.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SearchUserLiveCollectionController.d.ts","sourceRoot":"","sources":["../../../../src/userRepository/observers/searchUserByDisplayName/SearchUserLiveCollectionController.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"SearchUserLiveCollectionController.d.ts","sourceRoot":"","sources":["../../../../src/userRepository/observers/searchUserByDisplayName/SearchUserLiveCollectionController.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,wBAAwB,EAAE,MAAM,gDAAgD,CAAC;AAa1F,OAAO,EAAE,8BAA8B,EAAE,MAAM,kCAAkC,CAAC;AAElF,qBAAa,kCAAmC,SAAQ,wBAAwB,CAC9E,MAAM,EACN,KAAK,CAAC,wBAAwB,EAC9B,KAAK,CAAC,IAAI,EACV,8BAA8B,CAC/B;IACC,OAAO,CAAC,qBAAqB,CAAkC;IAE/D,OAAO,CAAC,KAAK,CAAiC;gBAG5C,KAAK,EAAE,KAAK,CAAC,wBAAwB,EACrC,QAAQ,EAAE,KAAK,CAAC,sBAAsB,CAAC,KAAK,CAAC,IAAI,CAAC;IAoBpD,SAAS,CAAC,KAAK;cAUC,YAAY,CAAC,YAAY,EAAE,KAAK,CAAC,WAAW,GAAG,KAAK,CAAC,UAAU;IAI/E,SAAS,CAAC,kBAAkB,CAAC,EAC3B,QAAQ,EACR,SAAS,EACT,OAAO,GACR,EAAE,KAAK,CAAC,sCAAsC,CAAC,MAAM,CAAC;IAIvD,iBAAiB;IAUjB,YAAY,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,KAAK,CAAC,0BAA0B;IAuBzE,WAAW,CAAC,IAAI,EAAE,KAAK,CAAC,IAAI,EAAE;CAW/B"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { UserReportBody } from './userReport';
|
|
2
|
+
/**
|
|
3
|
+
* Sends a validated split user report (`flagUserProfile` / `flagUserBehavior`) to the
|
|
4
|
+
* same endpoint as `flagUser`, then persists the returned user and fires `user.flagged`
|
|
5
|
+
* exactly as `flagUser` does, so all three calls share return, cache and event behaviour.
|
|
6
|
+
*
|
|
7
|
+
* Not exported from the public API.
|
|
8
|
+
*/
|
|
9
|
+
export declare const submitUserReport: (apiName: 'flagUserProfile' | 'flagUserBehavior', userId: Amity.User['userId'], body: UserReportBody) => Promise<Amity.User>;
|
|
10
|
+
//# sourceMappingURL=submitUserReport.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"submitUserReport.d.ts","sourceRoot":"","sources":["../../../src/userRepository/utils/submitUserReport.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAEnD;;;;;;GAMG;AACH,eAAO,MAAM,gBAAgB,YAClB,iBAAiB,GAAG,kBAAkB,UACvC,MAAM,IAAI,CAAC,QAAQ,CAAC,QACtB,cAAc,KACnB,QAAQ,MAAM,IAAI,CAkBpB,CAAC"}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { UserProfileFieldEnum, UserReportTypeFilterEnum } from '~/@types';
|
|
2
|
+
/** Maximum `comment` length, in string length units, after trimming. */
|
|
3
|
+
export declare const USER_REPORT_COMMENT_MAX_LENGTH = 300;
|
|
4
|
+
/** Request body sent to `POST /api/v4/me/flags/:userId` by the split user-report calls. */
|
|
5
|
+
export declare type UserReportBody = {
|
|
6
|
+
reportType: `${UserProfileFieldEnum}` | 'behavior';
|
|
7
|
+
reason?: string;
|
|
8
|
+
comment?: string;
|
|
9
|
+
};
|
|
10
|
+
/**
|
|
11
|
+
* Normalizes an optional reporter `comment`: it must be a string when supplied (`null`
|
|
12
|
+
* is not a valid supplied comment); it is trimmed; a blank result is omitted (the
|
|
13
|
+
* backend rejects `""`); a result longer than 300 characters is rejected before any
|
|
14
|
+
* request. Otherwise the trimmed text is returned unchanged.
|
|
15
|
+
*
|
|
16
|
+
* @throws {ASCInvalidParameterError} `INVALID_PARAMETERS` for a non-string or over-length comment
|
|
17
|
+
*/
|
|
18
|
+
export declare const normalizeUserReportComment: (apiName: string, comment: unknown) => string | undefined;
|
|
19
|
+
/**
|
|
20
|
+
* Validates `flagUserProfile` options and builds its request body. Untyped callers can
|
|
21
|
+
* pass anything at runtime, so nothing is trusted from the declared type. Any `reason`
|
|
22
|
+
* key is ignored and never sent.
|
|
23
|
+
*
|
|
24
|
+
* @throws {ASCInvalidParameterError} `INVALID_PARAMETERS` when the options are malformed
|
|
25
|
+
*/
|
|
26
|
+
export declare const toUserProfileReportBody: (options: unknown) => UserReportBody;
|
|
27
|
+
/**
|
|
28
|
+
* Validates `flagUserBehavior` options and builds its request body. `reason` must be one
|
|
29
|
+
* of the nine `ContentFlagReasonEnum` values and is sent as that canonical label;
|
|
30
|
+
* `reportType` is always `behavior`.
|
|
31
|
+
*
|
|
32
|
+
* @throws {ASCInvalidParameterError} `INVALID_PARAMETERS` when the options are malformed
|
|
33
|
+
*/
|
|
34
|
+
export declare const toUserBehaviorReportBody: (options: unknown) => UserReportBody;
|
|
35
|
+
/** Query parameters sent with `DELETE /api/v4/me/flags/:userId` for a per-type withdrawal. */
|
|
36
|
+
export declare type UserReportTypeFilterParams = {
|
|
37
|
+
reportType: `${UserReportTypeFilterEnum}`;
|
|
38
|
+
};
|
|
39
|
+
/**
|
|
40
|
+
* Validates the optional `{ reportType? }` of `unflagUser` and builds its query parameters.
|
|
41
|
+
* Returns `undefined` when no `reportType` is given, so the request carries no query string
|
|
42
|
+
* and withdraws every report the caller filed on the user. The server validates the value
|
|
43
|
+
* too (422); this local check only saves the round-trip for the string alias, which admits
|
|
44
|
+
* raw strings. Untyped callers can pass anything at runtime, so nothing is trusted from the
|
|
45
|
+
* declared type.
|
|
46
|
+
*
|
|
47
|
+
* @throws {ASCInvalidParameterError} `INVALID_PARAMETERS` when the options are malformed or `reportType` is unknown
|
|
48
|
+
*/
|
|
49
|
+
export declare const toUserReportTypeFilter: (options: unknown) => UserReportTypeFilterParams | undefined;
|
|
50
|
+
//# sourceMappingURL=userReport.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"userReport.d.ts","sourceRoot":"","sources":["../../../src/userRepository/utils/userReport.ts"],"names":[],"mappings":"AACA,OAAO,EAAyB,oBAAoB,EAAE,wBAAwB,EAAE,MAAM,UAAU,CAAC;AAEjG,wEAAwE;AACxE,eAAO,MAAM,8BAA8B,MAAM,CAAC;AAElD,2FAA2F;AAC3F,oBAAY,cAAc,GAAG;IAC3B,UAAU,EAAE,GAAG,oBAAoB,EAAE,GAAG,UAAU,CAAC;IACnD,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AAkBF;;;;;;;GAOG;AACH,eAAO,MAAM,0BAA0B,YAC5B,MAAM,WACN,OAAO,KACf,MAAM,GAAG,SAkBX,CAAC;AAKF;;;;;;GAMG;AACH,eAAO,MAAM,uBAAuB,YAAa,OAAO,KAAG,cAc1D,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,wBAAwB,YAAa,OAAO,KAAG,cAc3D,CAAC;AAEF,8FAA8F;AAC9F,oBAAY,0BAA0B,GAAG;IACvC,UAAU,EAAE,GAAG,wBAAwB,EAAE,CAAC;CAC3C,CAAC;AAEF;;;;;;;;;GASG;AACH,eAAO,MAAM,sBAAsB,YACxB,OAAO,KACf,0BAA0B,GAAG,SAe/B,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/** FNV-1a with the same mixing step and signed-byte handling as the native SDKs. */
|
|
2
|
+
export declare const fnv1a: (bytes: Uint8Array, seed: number) => number;
|
|
3
|
+
/**
|
|
4
|
+
* Whether `value` is probably in the filter. `false` is exact; `true` may be a false positive.
|
|
5
|
+
* A missing filter (`null`, the server's value when nobody has flagged the object), a missing
|
|
6
|
+
* value or a malformed filter all answer `false`.
|
|
7
|
+
*/
|
|
8
|
+
export declare const testBloomFilter: (hashFlag: Amity.Flaggable['hashFlag'] | undefined, value: string | undefined) => boolean;
|
|
9
|
+
//# sourceMappingURL=bloomFilter.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bloomFilter.d.ts","sourceRoot":"","sources":["../../src/utils/bloomFilter.ts"],"names":[],"mappings":"AAmBA,oFAAoF;AACpF,eAAO,MAAM,KAAK,UAAW,UAAU,QAAQ,MAAM,KAAG,MAgBvD,CAAC;AAkBF;;;;GAIG;AACH,eAAO,MAAM,eAAe,aAChB,MAAM,SAAS,CAAC,UAAU,CAAC,GAAG,SAAS,SAC1C,MAAM,GAAG,SAAS,KACxB,OAsBF,CAAC"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/** Request body shared by the post, comment and message flag endpoints. */
|
|
2
|
+
export declare type ContentFlagBody = {
|
|
3
|
+
reason: string;
|
|
4
|
+
detail?: string;
|
|
5
|
+
};
|
|
6
|
+
/**
|
|
7
|
+
* True when a public `flagX(id, input)` argument is the legacy shape (a reason string
|
|
8
|
+
* or nothing). Anything else is routed to the `Amity.ContentFlagOptions` path, whose
|
|
9
|
+
* validation rejects malformed values before any request is made.
|
|
10
|
+
*/
|
|
11
|
+
export declare const isLegacyContentFlagReason: (input: unknown) => input is Amity.ContentFlagReason | undefined;
|
|
12
|
+
/**
|
|
13
|
+
* Validates an `Amity.ContentFlagOptions` argument. Untyped (plain JS) callers can pass
|
|
14
|
+
* anything at runtime, so the checks do not trust the declared type: the value must be a
|
|
15
|
+
* plain object, `reason` must be one of the nine `ContentFlagReasonEnum` values and
|
|
16
|
+
* `detail`, when supplied, must be a string (`null` is not a valid supplied detail).
|
|
17
|
+
*
|
|
18
|
+
* @param apiName used in the error message, e.g. `flagPost`
|
|
19
|
+
* @throws {ASCInvalidParameterError} `INVALID_PARAMETERS` when the options are malformed
|
|
20
|
+
*/
|
|
21
|
+
export declare const validateContentFlagOptions: (apiName: string, options: unknown) => Amity.ContentFlagOptions;
|
|
22
|
+
/**
|
|
23
|
+
* Builds the request body for validated options. `detail` is forwarded unchanged (empty
|
|
24
|
+
* and whitespace-only strings included) and omitted from the body when `undefined`; the
|
|
25
|
+
* backend enforces the 300-character limit.
|
|
26
|
+
*/
|
|
27
|
+
export declare const toContentFlagBody: ({ reason, detail }: Amity.ContentFlagOptions) => ContentFlagBody;
|
|
28
|
+
//# sourceMappingURL=contentFlag.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"contentFlag.d.ts","sourceRoot":"","sources":["../../src/utils/contentFlag.ts"],"names":[],"mappings":"AAGA,2EAA2E;AAC3E,oBAAY,eAAe,GAAG;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,MAAM,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAIlE;;;;GAIG;AACH,eAAO,MAAM,yBAAyB,UAC7B,OAAO,iDACmF,CAAC;AAEpG;;;;;;;;GAQG;AACH,eAAO,MAAM,0BAA0B,YAC5B,MAAM,WACN,OAAO,KACf,MAAM,kBAoBR,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,uBAAwB,MAAM,kBAAkB,KAAG,eACzB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"userLinkedObject.test.d.ts","sourceRoot":"","sources":["../../../../src/utils/linkedObject/tests/userLinkedObject.test.ts"],"names":[],"mappings":""}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"userLinkedObject.d.ts","sourceRoot":"","sources":["../../../src/utils/linkedObject/userLinkedObject.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"userLinkedObject.d.ts","sourceRoot":"","sources":["../../../src/utils/linkedObject/userLinkedObject.ts"],"names":[],"mappings":"AA0DA,eAAO,MAAM,gBAAgB,SAAU,MAAM,YAAY,KAAG,MAAM,IAmBjE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bloomFilter.test.d.ts","sourceRoot":"","sources":["../../../src/utils/tests/bloomFilter.test.ts"],"names":[],"mappings":""}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../src/utils/tests/client.ts"],"names":[],"mappings":"AAUA,eAAO,MAAM,UAAU,
|
|
1
|
+
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../src/utils/tests/client.ts"],"names":[],"mappings":"AAUA,eAAO,MAAM,UAAU,oBAAS,CAAC;AAYjC,eAAO,MAAM,MAAM,cAA4B,CAAC;AAMhD,eAAO,MAAM,aAAa,qBAiBzB,CAAC;AAEF,eAAO,MAAM,gBAAgB,qBAE5B,CAAC;;AAEF,wBAAkB"}
|
|
@@ -60,7 +60,7 @@ export declare const channelGetResponseWithMessagePreview: {
|
|
|
60
60
|
channels: Amity.RawChannel<any>[];
|
|
61
61
|
channelUsers: never[];
|
|
62
62
|
files: never[];
|
|
63
|
-
users: Amity.
|
|
63
|
+
users: Amity.InternalUser[];
|
|
64
64
|
messagePreviews: Amity.MessagePreviewPayload<any>[];
|
|
65
65
|
messageFeedsInfo: Amity.messageFeedsInfoPayload[];
|
|
66
66
|
};
|
|
@@ -70,7 +70,7 @@ export declare const channelGetResponseWithNoMessagePreview: {
|
|
|
70
70
|
channels: Amity.RawChannel<any>[];
|
|
71
71
|
channelUsers: never[];
|
|
72
72
|
files: never[];
|
|
73
|
-
users: Amity.
|
|
73
|
+
users: Amity.InternalUser[];
|
|
74
74
|
messagePreviews: never[];
|
|
75
75
|
messageFeedsInfo: never[];
|
|
76
76
|
};
|
|
@@ -84,7 +84,7 @@ export declare const channelQueryResponseWithMessagePreview: {
|
|
|
84
84
|
channels: Amity.RawChannel<any>[];
|
|
85
85
|
channelUsers: never[];
|
|
86
86
|
files: never[];
|
|
87
|
-
users: Amity.
|
|
87
|
+
users: Amity.InternalUser[];
|
|
88
88
|
messagePreviews: Amity.MessagePreviewPayload<any>[];
|
|
89
89
|
messageFeedsInfo: Amity.messageFeedsInfoPayload[];
|
|
90
90
|
};
|
|
@@ -98,7 +98,7 @@ export declare const channelQueryResponseWithNoMessagePreview: {
|
|
|
98
98
|
channels: Amity.RawChannel<any>[];
|
|
99
99
|
channelUsers: never[];
|
|
100
100
|
files: never[];
|
|
101
|
-
users: Amity.
|
|
101
|
+
users: Amity.InternalUser[];
|
|
102
102
|
messagePreviews: never[];
|
|
103
103
|
messageFeedsInfo: never[];
|
|
104
104
|
};
|
|
@@ -163,7 +163,7 @@ export declare const channelUserQueryResponse: {
|
|
|
163
163
|
};
|
|
164
164
|
channels: Amity.RawChannel<any>[];
|
|
165
165
|
channelUsers: Amity.RawMembership<"channel">[];
|
|
166
|
-
users: Amity.
|
|
166
|
+
users: Amity.InternalUser[];
|
|
167
167
|
files: never[];
|
|
168
168
|
messagePreviews: never[];
|
|
169
169
|
};
|
|
@@ -190,7 +190,7 @@ export declare const channelUserQueryResponsePage2: {
|
|
|
190
190
|
};
|
|
191
191
|
channels: Amity.RawChannel<any>[];
|
|
192
192
|
channelUsers: Amity.RawMembership<"channel">[];
|
|
193
|
-
users: Amity.
|
|
193
|
+
users: Amity.InternalUser[];
|
|
194
194
|
files: never[];
|
|
195
195
|
messagePreviews: never[];
|
|
196
196
|
};
|
|
@@ -203,7 +203,7 @@ export declare const channelUserQueryResponsePage3: {
|
|
|
203
203
|
};
|
|
204
204
|
channels: Amity.RawChannel<any>[];
|
|
205
205
|
channelUsers: Amity.RawMembership<"channel">[];
|
|
206
|
-
users: Amity.
|
|
206
|
+
users: Amity.InternalUser[];
|
|
207
207
|
files: never[];
|
|
208
208
|
messagePreviews: never[];
|
|
209
209
|
};
|
|
@@ -213,14 +213,14 @@ export declare const channelPayload: Amity.ProcessedChannelPayload;
|
|
|
213
213
|
export declare const liveChannelPayload: {
|
|
214
214
|
channels: Amity.RawChannel<any>[];
|
|
215
215
|
channelUsers: Amity.RawMembership<"channel">[];
|
|
216
|
-
users: Amity.
|
|
216
|
+
users: Amity.InternalUser[];
|
|
217
217
|
files: Amity.File<"image">[];
|
|
218
218
|
messagePreviews: never[];
|
|
219
219
|
};
|
|
220
220
|
export declare const conversationChannelPayload: {
|
|
221
221
|
channels: Amity.RawChannel<any>[];
|
|
222
222
|
channelUsers: Amity.RawMembership<"channel">[];
|
|
223
|
-
users: Amity.
|
|
223
|
+
users: Amity.InternalUser[];
|
|
224
224
|
files: Amity.File<"image">[];
|
|
225
225
|
messagePreviews: never[];
|
|
226
226
|
};
|
|
@@ -234,4 +234,8 @@ export declare const channelCreatedAt3: Amity.RawChannel<any>;
|
|
|
234
234
|
export declare const channelLastActivity1: Amity.RawChannel<any>;
|
|
235
235
|
export declare const channelLastActivity2: Amity.RawChannel<any>;
|
|
236
236
|
export declare const channelLastActivity3: Amity.RawChannel<any>;
|
|
237
|
+
export declare const channelLastMessageAt1: Amity.RawChannel<any>;
|
|
238
|
+
export declare const channelLastMessageAt2: Amity.RawChannel<any>;
|
|
239
|
+
export declare const channelLastMessageAt3: Amity.RawChannel<any>;
|
|
240
|
+
export declare const channelLastMessageAtNull: Amity.RawChannel<any>;
|
|
237
241
|
//# sourceMappingURL=channel.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"channel.d.ts","sourceRoot":"","sources":["../../../../src/utils/tests/dummy/channel.ts"],"names":[],"mappings":"AAWA,eAAO,MAAM,qBAAqB,YAAa,MAAM,UAAU,KAAG,MAAM,eAGvE,CAAC;AAEF,eAAO,MAAM,wBAAwB,eACvB,MAAM,cAAc,KAC/B,MAAM,uBAKuC,CAAC;AAEjD,wBAAgB,kBAAkB,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC,KAAK,CAAC,UAAU,CAAC,GAAG,KAAK,CAAC,UAAU,
|
|
1
|
+
{"version":3,"file":"channel.d.ts","sourceRoot":"","sources":["../../../../src/utils/tests/dummy/channel.ts"],"names":[],"mappings":"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"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { createComment } from '~/commentRepository/api';
|
|
2
2
|
export declare function generateInternalComment(params?: Partial<Amity.InternalComment>): Amity.InternalComment;
|
|
3
3
|
export declare const generateComment: (params?: Partial<Amity.InternalComment>) => {
|
|
4
|
-
creator: Amity.
|
|
4
|
+
creator: Amity.InternalUser;
|
|
5
5
|
childrenComment: never[];
|
|
6
6
|
target: {
|
|
7
7
|
type: string;
|
|
@@ -29,7 +29,7 @@ export declare const communityUserQueryResponse: {
|
|
|
29
29
|
};
|
|
30
30
|
communities: Amity.Community[];
|
|
31
31
|
communityUsers: Amity.RawMembership<"community">[];
|
|
32
|
-
users: Amity.
|
|
32
|
+
users: Amity.InternalUser[];
|
|
33
33
|
files: never[];
|
|
34
34
|
categories: never[];
|
|
35
35
|
feeds: never[];
|
|
@@ -44,14 +44,14 @@ export declare const communityUserQueryResponsePage2: {
|
|
|
44
44
|
};
|
|
45
45
|
communities: Amity.Community[];
|
|
46
46
|
communityUsers: Amity.RawMembership<"community">[];
|
|
47
|
-
users: Amity.
|
|
47
|
+
users: Amity.InternalUser[];
|
|
48
48
|
files: never[];
|
|
49
49
|
categories: never[];
|
|
50
50
|
feeds: never[];
|
|
51
51
|
};
|
|
52
52
|
};
|
|
53
53
|
export declare const communityUserModel: {
|
|
54
|
-
user: Amity.
|
|
54
|
+
user: Amity.InternalUser;
|
|
55
55
|
isBanned: boolean;
|
|
56
56
|
isMuted: boolean;
|
|
57
57
|
muteTimeout: string;
|
|
@@ -30,6 +30,6 @@ export declare const messageQueryResponse: {
|
|
|
30
30
|
export declare const messagePayload: {
|
|
31
31
|
messages: Amity.InternalMessage<any>[];
|
|
32
32
|
files: Amity.File<"image">[];
|
|
33
|
-
users: Amity.
|
|
33
|
+
users: Amity.InternalUser[];
|
|
34
34
|
};
|
|
35
35
|
//# sourceMappingURL=message.d.ts.map
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
export declare const user11: Amity.
|
|
2
|
-
export declare const user12: Amity.
|
|
3
|
-
export declare const user13: Amity.
|
|
4
|
-
export declare const user14: Amity.
|
|
5
|
-
export declare const user21: Amity.
|
|
6
|
-
export declare const user22: Amity.
|
|
1
|
+
export declare const user11: Amity.InternalUser;
|
|
2
|
+
export declare const user12: Amity.InternalUser;
|
|
3
|
+
export declare const user13: Amity.InternalUser;
|
|
4
|
+
export declare const user14: Amity.InternalUser;
|
|
5
|
+
export declare const user21: Amity.InternalUser;
|
|
6
|
+
export declare const user22: Amity.InternalUser;
|
|
7
7
|
export declare const viewedUserQueryResponse: {
|
|
8
8
|
data: {
|
|
9
|
-
users: Amity.
|
|
9
|
+
users: Amity.InternalUser[];
|
|
10
10
|
files: never[];
|
|
11
11
|
paging: {};
|
|
12
12
|
};
|
|
13
13
|
};
|
|
14
14
|
export declare const userQueryResponse: {
|
|
15
15
|
data: {
|
|
16
|
-
users: Amity.
|
|
16
|
+
users: Amity.InternalUser[];
|
|
17
17
|
files: never[];
|
|
18
18
|
paging: {
|
|
19
19
|
previous: string;
|
|
@@ -23,7 +23,7 @@ export declare const userQueryResponse: {
|
|
|
23
23
|
};
|
|
24
24
|
export declare const userQueryResponsePage2: {
|
|
25
25
|
data: {
|
|
26
|
-
users: Amity.
|
|
26
|
+
users: Amity.InternalUser[];
|
|
27
27
|
files: never[];
|
|
28
28
|
paging: {
|
|
29
29
|
previous: string;
|
|
@@ -58,7 +58,6 @@ export declare const flaggedUser: {
|
|
|
58
58
|
isDeleted?: boolean | undefined;
|
|
59
59
|
path: string;
|
|
60
60
|
isGlobalBanned: boolean;
|
|
61
|
-
avatar?: Amity.File<"image"> | null | undefined;
|
|
62
61
|
};
|
|
63
62
|
export declare const flaggedUserQueryResponse: {
|
|
64
63
|
data: {
|
|
@@ -89,7 +88,6 @@ export declare const flaggedUserQueryResponse: {
|
|
|
89
88
|
isDeleted?: boolean | undefined;
|
|
90
89
|
path: string;
|
|
91
90
|
isGlobalBanned: boolean;
|
|
92
|
-
avatar?: Amity.File<"image"> | null | undefined;
|
|
93
91
|
}[];
|
|
94
92
|
files: never[];
|
|
95
93
|
};
|
|
@@ -112,6 +110,6 @@ export declare const userUpdateResponse: {
|
|
|
112
110
|
files: never[];
|
|
113
111
|
};
|
|
114
112
|
};
|
|
115
|
-
export declare const users: Amity.
|
|
113
|
+
export declare const users: Amity.InternalUser[];
|
|
116
114
|
export declare const userPayload: Amity.UserPayload;
|
|
117
115
|
//# sourceMappingURL=user.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user.d.ts","sourceRoot":"","sources":["../../../../src/utils/tests/dummy/user.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,MAAM,EAAE,KAAK,CAAC,
|
|
1
|
+
{"version":3,"file":"user.d.ts","sourceRoot":"","sources":["../../../../src/utils/tests/dummy/user.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,MAAM,EAAE,KAAK,CAAC,YAc1B,CAAC;AAEF,eAAO,MAAM,MAAM,EAAE,KAAK,CAAC,YAG1B,CAAC;AAEF,eAAO,MAAM,MAAM,EAAE,KAAK,CAAC,YAG1B,CAAC;AAEF,eAAO,MAAM,MAAM,EAAE,KAAK,CAAC,YAG1B,CAAC;AAEF,eAAO,MAAM,MAAM,EAAE,KAAK,CAAC,YAI1B,CAAC;AAEF,eAAO,MAAM,MAAM,EAAE,KAAK,CAAC,YAG1B,CAAC;AAEF,eAAO,MAAM,uBAAuB;;;;;;CAMnC,CAAC;AAEF,eAAO,MAAM,iBAAiB;;;;;;;;;CAS7B,CAAC;AAEF,eAAO,MAAM,sBAAsB;;;;;;;;;CASlC,CAAC;AAEF,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;CAIvB,CAAC;AAEF,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAKpC,CAAC;AAEF,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;CAmB9B,CAAC;AAEF,eAAO,MAAM,KAAK,sBAAmC,CAAC;AAGtD,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,WAG/B,CAAC"}
|