@amityco/ts-sdk 6.7.2 → 6.7.3-cbeeb97.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/events.d.ts +9 -3
- package/dist/@types/core/events.d.ts.map +1 -1
- package/dist/@types/core/marker.d.ts +3 -0
- package/dist/@types/core/marker.d.ts.map +1 -1
- package/dist/@types/core/model.d.ts +2 -2
- package/dist/@types/core/model.d.ts.map +1 -1
- package/dist/@types/core/payload.d.ts +40 -36
- package/dist/@types/core/payload.d.ts.map +1 -1
- package/dist/@types/domains/channel.d.ts +1 -0
- package/dist/@types/domains/channel.d.ts.map +1 -1
- package/dist/@types/domains/client.d.ts +1 -0
- package/dist/@types/domains/client.d.ts.map +1 -1
- package/dist/@types/domains/comment.d.ts +20 -8
- package/dist/@types/domains/comment.d.ts.map +1 -1
- package/dist/@types/domains/partials.d.ts +3 -0
- package/dist/@types/domains/partials.d.ts.map +1 -1
- package/dist/@types/domains/post.d.ts +1 -1
- package/dist/@types/domains/post.d.ts.map +1 -1
- package/dist/@types/domains/subChannel.d.ts +1 -0
- package/dist/@types/domains/subChannel.d.ts.map +1 -1
- package/dist/channelRepsitory/api/markAsRead.d.ts.map +1 -1
- package/dist/channelRepsitory/observers/getChannels.d.ts.map +1 -1
- package/dist/channelRepsitory/utils/getChannelHasMentioned.d.ts +7 -0
- package/dist/channelRepsitory/utils/getChannelHasMentioned.d.ts.map +1 -0
- package/dist/channelRepsitory/utils/prepareChannelPayload.d.ts.map +1 -1
- package/dist/client/api/markerSync.d.ts.map +1 -1
- package/dist/client/observers/getTotalUnreadCount.d.ts +2 -0
- package/dist/client/observers/getTotalUnreadCount.d.ts.map +1 -1
- package/dist/client/observers/getUserUnread.d.ts +19 -0
- package/dist/client/observers/getUserUnread.d.ts.map +1 -0
- package/dist/client/observers/index.d.ts +1 -0
- package/dist/client/observers/index.d.ts.map +1 -1
- package/dist/client/utils/markerSyncEngine.d.ts.map +1 -1
- package/dist/client/utils/onOnline.d.ts +2 -0
- package/dist/client/utils/onOnline.d.ts.map +1 -0
- package/dist/commentRepository/api/createComment.d.ts +4 -4
- package/dist/commentRepository/api/createComment.d.ts.map +1 -1
- package/dist/commentRepository/api/deleteComment.d.ts +4 -4
- package/dist/commentRepository/api/deleteComment.d.ts.map +1 -1
- package/dist/commentRepository/api/flagComment.d.ts +1 -1
- package/dist/commentRepository/api/flagComment.d.ts.map +1 -1
- package/dist/commentRepository/api/getComment.d.ts +8 -8
- package/dist/commentRepository/api/getComment.d.ts.map +1 -1
- package/dist/commentRepository/api/getCommentByIds.d.ts +8 -8
- package/dist/commentRepository/api/getCommentByIds.d.ts.map +1 -1
- package/dist/commentRepository/api/hardDeleteComment.d.ts +4 -4
- package/dist/commentRepository/api/hardDeleteComment.d.ts.map +1 -1
- package/dist/commentRepository/api/isCommentFlaggedByMe.d.ts +1 -1
- package/dist/commentRepository/api/isCommentFlaggedByMe.d.ts.map +1 -1
- package/dist/commentRepository/api/queryComments.d.ts +3 -3
- package/dist/commentRepository/api/queryComments.d.ts.map +1 -1
- package/dist/commentRepository/api/softDeleteComment.d.ts +4 -4
- package/dist/commentRepository/api/softDeleteComment.d.ts.map +1 -1
- package/dist/commentRepository/api/unflagComment.d.ts +1 -1
- package/dist/commentRepository/api/unflagComment.d.ts.map +1 -1
- package/dist/commentRepository/api/updateComment.d.ts +4 -4
- package/dist/commentRepository/api/updateComment.d.ts.map +1 -1
- package/dist/commentRepository/events/onCommentCreated.d.ts +3 -3
- package/dist/commentRepository/events/onCommentCreated.d.ts.map +1 -1
- package/dist/commentRepository/events/onCommentDeleted.d.ts +3 -3
- package/dist/commentRepository/events/onCommentDeleted.d.ts.map +1 -1
- package/dist/commentRepository/events/onCommentFlagged.d.ts +3 -3
- package/dist/commentRepository/events/onCommentFlagged.d.ts.map +1 -1
- package/dist/commentRepository/events/onCommentReactionAdded.d.ts +3 -3
- package/dist/commentRepository/events/onCommentReactionAdded.d.ts.map +1 -1
- package/dist/commentRepository/events/onCommentReactionRemoved.d.ts +3 -3
- package/dist/commentRepository/events/onCommentReactionRemoved.d.ts.map +1 -1
- package/dist/commentRepository/events/onCommentUnflagged.d.ts +3 -3
- package/dist/commentRepository/events/onCommentUnflagged.d.ts.map +1 -1
- package/dist/commentRepository/events/onCommentUpdated.d.ts +3 -3
- package/dist/commentRepository/events/onCommentUpdated.d.ts.map +1 -1
- package/dist/commentRepository/events/utils.d.ts +1 -1
- package/dist/commentRepository/events/utils.d.ts.map +1 -1
- package/dist/commentRepository/observers/getComment.d.ts +3 -3
- package/dist/commentRepository/observers/getComment.d.ts.map +1 -1
- package/dist/commentRepository/observers/getComments.d.ts +4 -4
- package/dist/commentRepository/observers/getComments.d.ts.map +1 -1
- package/dist/commentRepository/observers/observeComment.d.ts +3 -3
- package/dist/commentRepository/observers/observeComment.d.ts.map +1 -1
- package/dist/commentRepository/observers/observeComments.d.ts +3 -3
- package/dist/commentRepository/observers/observeComments.d.ts.map +1 -1
- package/dist/index.cjs.js +2253 -18192
- package/dist/index.esm.js +273 -107
- package/dist/index.umd.js +4 -4
- package/dist/marker/api/getChannelMarkers.d.ts.map +1 -1
- package/dist/marker/api/getMessageMarkers.d.ts.map +1 -1
- package/dist/marker/api/getSubChannelMarkers.d.ts.map +1 -1
- package/dist/marker/api/getUserMarker.d.ts.map +1 -1
- package/dist/marker/events/onUserMarkerSync.d.ts.map +1 -1
- package/dist/messageRepository/api/getDeliveredUsers.d.ts.map +1 -1
- package/dist/messageRepository/api/getReadUsers.d.ts.map +1 -1
- package/dist/messageRepository/api/markAsDelivered.d.ts.map +1 -1
- package/dist/reactionRepository/events/onReactionAdded.d.ts +1 -1
- package/dist/reactionRepository/events/onReactionAdded.d.ts.map +1 -1
- package/dist/reactionRepository/events/onReactionRemoved.d.ts +1 -1
- package/dist/reactionRepository/events/onReactionRemoved.d.ts.map +1 -1
- package/dist/reactionRepository/utils/fetchReference.d.ts +1 -1
- package/dist/reactionRepository/utils/fetchReference.d.ts.map +1 -1
- package/dist/subChannelRepository/api/readingAPI.d.ts.map +1 -1
- package/dist/subChannelRepository/api/startReadingAPI.d.ts.map +1 -1
- package/dist/subChannelRepository/api/stopReadingAPI.d.ts.map +1 -1
- package/dist/subChannelRepository/utils/getSubChannelHasMentioned.d.ts +2 -0
- package/dist/subChannelRepository/utils/getSubChannelHasMentioned.d.ts.map +1 -0
- package/dist/subChannelRepository/utils/markReadEngine.d.ts.map +1 -1
- package/dist/subChannelRepository/utils/prepareSubChannelPayload.d.ts.map +1 -1
- package/dist/utils/linkedObject/commentLinkedObject.d.ts +2 -0
- package/dist/utils/linkedObject/commentLinkedObject.d.ts.map +1 -0
- package/dist/utils/linkedObject/index.d.ts +4 -0
- package/dist/utils/linkedObject/index.d.ts.map +1 -0
- package/dist/utils/marker.d.ts +4 -0
- package/dist/utils/marker.d.ts.map +1 -0
- package/dist/utils/tests/dummy/channel.d.ts.map +1 -1
- package/dist/utils/tests/dummy/comment.d.ts +20 -14
- package/dist/utils/tests/dummy/comment.d.ts.map +1 -1
- package/dist/utils/tests/dummy/marker.d.ts +3 -0
- package/dist/utils/tests/dummy/marker.d.ts.map +1 -1
- package/package.json +3 -1
- package/rollup.config.js +2 -0
- package/src/@types/core/events.ts +3 -9
- package/src/@types/core/marker.ts +3 -0
- package/src/@types/core/model.ts +2 -2
- package/src/@types/core/payload.ts +41 -36
- package/src/@types/domains/channel.ts +1 -0
- package/src/@types/domains/client.ts +2 -0
- package/src/@types/domains/comment.ts +20 -8
- package/src/@types/domains/partials.ts +4 -0
- package/src/@types/domains/post.ts +1 -1
- package/src/@types/domains/subChannel.ts +1 -0
- package/src/channelRepsitory/api/markAsRead.ts +22 -1
- package/src/channelRepsitory/observers/getChannels.ts +3 -2
- package/src/channelRepsitory/observers/tests/getChannels.test.ts +6 -2
- package/src/channelRepsitory/utils/getChannelHasMentioned.ts +28 -0
- package/src/channelRepsitory/utils/prepareChannelPayload.ts +4 -0
- package/src/channelRepsitory/utils/tests/prepareChannelPayload.test.ts +3 -0
- package/src/client/api/markerSync.ts +17 -2
- package/src/client/observers/getTotalUnreadCount.ts +2 -0
- package/src/client/observers/getUserUnread.ts +47 -0
- package/src/client/observers/index.ts +1 -0
- package/src/client/utils/markerSyncEngine.ts +5 -13
- package/src/client/utils/onOnline.ts +15 -0
- package/src/commentRepository/api/createComment.ts +5 -5
- package/src/commentRepository/api/deleteComment.ts +6 -5
- package/src/commentRepository/api/flagComment.ts +3 -1
- package/src/commentRepository/api/getComment.ts +13 -12
- package/src/commentRepository/api/getCommentByIds.ts +11 -11
- package/src/commentRepository/api/hardDeleteComment.ts +5 -5
- package/src/commentRepository/api/isCommentFlaggedByMe.ts +1 -1
- package/src/commentRepository/api/queryComments.ts +4 -4
- package/src/commentRepository/api/softDeleteComment.ts +5 -5
- package/src/commentRepository/api/tests/queryComments.test.ts +9 -9
- package/src/commentRepository/api/unflagComment.ts +3 -1
- package/src/commentRepository/api/updateComment.ts +6 -6
- package/src/commentRepository/events/onCommentCreated.ts +5 -4
- package/src/commentRepository/events/onCommentDeleted.ts +5 -4
- package/src/commentRepository/events/onCommentFlagged.ts +5 -4
- package/src/commentRepository/events/onCommentReactionAdded.ts +4 -4
- package/src/commentRepository/events/onCommentReactionRemoved.ts +4 -4
- package/src/commentRepository/events/onCommentUnflagged.ts +5 -4
- package/src/commentRepository/events/onCommentUpdated.ts +5 -4
- package/src/commentRepository/events/utils.ts +3 -3
- package/src/commentRepository/observers/getComment.ts +4 -4
- package/src/commentRepository/observers/getComments.ts +9 -8
- package/src/commentRepository/observers/observeComment.ts +14 -8
- package/src/commentRepository/observers/observeComments.ts +9 -6
- package/src/commentRepository/observers/tests/getComment.test.ts +3 -1
- package/src/marker/api/getChannelMarkers.ts +9 -3
- package/src/marker/api/getMessageMarkers.ts +5 -2
- package/src/marker/api/getSubChannelMarkers.ts +16 -2
- package/src/marker/api/getUserMarker.ts +9 -2
- package/src/marker/api/tests/getMessageMarkers.test.ts +3 -1
- package/src/marker/api/tests/getSubChannelMarkers.test.ts +16 -8
- package/src/marker/events/onUserMarkerSync.ts +18 -2
- package/src/messageRepository/api/getDeliveredUsers.ts +9 -2
- package/src/messageRepository/api/getReadUsers.ts +6 -2
- package/src/messageRepository/api/markAsDelivered.ts +17 -1
- package/src/messageRepository/api/tests/markAsDelivered.test.ts +11 -4
- package/src/reactionRepository/utils/prepareReactionPayloadFormEvent.ts +1 -1
- package/src/subChannelRepository/api/readingAPI.ts +17 -2
- package/src/subChannelRepository/api/startReadingAPI.ts +17 -2
- package/src/subChannelRepository/api/stopReadingAPI.ts +17 -2
- package/src/subChannelRepository/utils/getSubChannelHasMentioned.ts +34 -0
- package/src/subChannelRepository/utils/markReadEngine.ts +7 -15
- package/src/subChannelRepository/utils/prepareSubChannelPayload.ts +4 -0
- package/src/utils/linkedObject/commentLinkedObject.ts +44 -0
- package/src/utils/linkedObject/index.ts +5 -0
- package/src/utils/marker.ts +29 -0
- package/src/utils/tests/dummy/channel.ts +2 -0
- package/src/utils/tests/dummy/comment.ts +25 -8
- package/src/utils/tests/dummy/marker.ts +46 -0
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
* const newComment = await CommentRepository.createComment(bundle)
|
|
5
5
|
* ```
|
|
6
6
|
*
|
|
7
|
-
* Creates an {@link Amity.
|
|
7
|
+
* Creates an {@link Amity.InternalComment}
|
|
8
8
|
*
|
|
9
|
-
* @param bundle The data necessary to create a new {@link Amity.
|
|
10
|
-
* @returns The newly created {@link Amity.
|
|
9
|
+
* @param bundle The data necessary to create a new {@link Amity.InternalComment}
|
|
10
|
+
* @returns The newly created {@link Amity.InternalComment}
|
|
11
11
|
*
|
|
12
12
|
* @category Comment API
|
|
13
13
|
* @async
|
|
14
14
|
*/
|
|
15
|
-
export declare const createComment: (bundle: Pick<Amity.
|
|
15
|
+
export declare const createComment: (bundle: Pick<Amity.InternalComment<Amity.CommentContentType>, 'data' | 'referenceType' | 'referenceId' | 'parentId' | 'metadata' | 'mentionees' | 'attachments'>) => Promise<Amity.Cached<Amity.InternalComment>>;
|
|
16
16
|
//# sourceMappingURL=createComment.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/createComment.ts"],"names":[],"mappings":"AAUA;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,aAAa,WAChB,KACN,
|
|
1
|
+
{"version":3,"file":"createComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/createComment.ts"],"names":[],"mappings":"AAUA;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,aAAa,WAChB,KACN,MAAM,eAAe,CAAC,MAAM,kBAAkB,CAAC,EAC7C,MAAM,GACN,eAAe,GACf,aAAa,GACb,UAAU,GACV,UAAU,GACV,YAAY,GACZ,aAAa,CAChB,KACA,QAAQ,MAAM,MAAM,CAAC,MAAM,eAAe,CAAC,CA6B7C,CAAC"}
|
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
* const success = await CommentRepository.deleteComment('foobar')
|
|
5
5
|
* ```
|
|
6
6
|
*
|
|
7
|
-
* Deletes a {@link Amity.
|
|
7
|
+
* Deletes a {@link Amity.InternalComment}
|
|
8
8
|
*
|
|
9
|
-
* @param commentId The {@link Amity.
|
|
10
|
-
* @return A success boolean if the {@link Amity.
|
|
9
|
+
* @param commentId The {@link Amity.InternalComment} ID to delete
|
|
10
|
+
* @return A success boolean if the {@link Amity.InternalComment} was deleted
|
|
11
11
|
*
|
|
12
12
|
* @category Comment API
|
|
13
13
|
* @async
|
|
14
14
|
*/
|
|
15
|
-
export declare const deleteComment: (commentId: Amity.
|
|
15
|
+
export declare const deleteComment: (commentId: Amity.InternalComment['commentId'], permanent?: boolean) => Promise<Amity.InternalComment>;
|
|
16
16
|
//# sourceMappingURL=deleteComment.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deleteComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/deleteComment.ts"],"names":[],"mappings":"AAcA;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,aAAa,cACb,
|
|
1
|
+
{"version":3,"file":"deleteComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/deleteComment.ts"],"names":[],"mappings":"AAcA;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,aAAa,cACb,MAAM,eAAe,CAAC,WAAW,CAAC,0BAE5C,QAAQ,MAAM,eAAe,CAgD/B,CAAC"}
|
|
@@ -10,5 +10,5 @@
|
|
|
10
10
|
* @category Comment API
|
|
11
11
|
* @async
|
|
12
12
|
* */
|
|
13
|
-
export declare const flagComment: (commentId: Amity.
|
|
13
|
+
export declare const flagComment: (commentId: Amity.InternalComment['commentId']) => Promise<boolean>;
|
|
14
14
|
//# sourceMappingURL=flagComment.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flagComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/flagComment.ts"],"names":[],"mappings":"AAQA;;;;;;;;;;;KAWK;AACL,eAAO,MAAM,WAAW,
|
|
1
|
+
{"version":3,"file":"flagComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/flagComment.ts"],"names":[],"mappings":"AAQA;;;;;;;;;;;KAWK;AACL,eAAO,MAAM,WAAW,cACX,MAAM,eAAe,CAAC,WAAW,CAAC,KAC5C,QAAQ,OAAO,CAejB,CAAC"}
|
|
@@ -4,29 +4,29 @@
|
|
|
4
4
|
* const comment = await CommentRepository.getComment('foobar')
|
|
5
5
|
* ```
|
|
6
6
|
*
|
|
7
|
-
* Fetches a {@link Amity.
|
|
7
|
+
* Fetches a {@link Amity.InternalComment} object
|
|
8
8
|
*
|
|
9
|
-
* @param commentId the ID of the {@link Amity.
|
|
10
|
-
* @returns the associated {@link Amity.
|
|
9
|
+
* @param commentId the ID of the {@link Amity.InternalComment} to fetch
|
|
10
|
+
* @returns the associated {@link Amity.InternalComment} object
|
|
11
11
|
*
|
|
12
12
|
* @category Comment API
|
|
13
13
|
* @async
|
|
14
14
|
*/
|
|
15
15
|
export declare const getComment: {
|
|
16
|
-
(commentId: Amity.
|
|
16
|
+
(commentId: Amity.InternalComment['commentId']): Promise<Amity.Cached<Amity.InternalComment>>;
|
|
17
17
|
/**
|
|
18
18
|
* ```js
|
|
19
19
|
* import { getComment } from '@amityco/ts-sdk'
|
|
20
20
|
* const comment = getComment.locally('foobar')
|
|
21
21
|
* ```
|
|
22
22
|
*
|
|
23
|
-
* Fetches a {@link Amity.
|
|
23
|
+
* Fetches a {@link Amity.InternalComment} object
|
|
24
24
|
*
|
|
25
|
-
* @param commentId the ID of the {@link Amity.
|
|
26
|
-
* @returns the associated {@link Amity.
|
|
25
|
+
* @param commentId the ID of the {@link Amity.InternalComment} to fetch
|
|
26
|
+
* @returns the associated {@link Amity.InternalComment} object
|
|
27
27
|
*
|
|
28
28
|
* @category Comment API
|
|
29
29
|
*/
|
|
30
|
-
locally(commentId: Amity.
|
|
30
|
+
locally(commentId: Amity.InternalComment['commentId']): Amity.Cached<Amity.InternalComment> | undefined;
|
|
31
31
|
};
|
|
32
32
|
//# sourceMappingURL=getComment.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/getComment.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"getComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/getComment.ts"],"names":[],"mappings":"AASA;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,UAAU;gBACV,MAAM,eAAe,CAAC,WAAW,CAAC,GAC5C,QAAQ,MAAM,MAAM,CAAC,MAAM,eAAe,CAAC,CAAC;IAiC/C;;;;;;;;;;;;OAYG;uBAEU,MAAM,eAAe,CAAC,WAAW,CAAC,GAC5C,MAAM,MAAM,CAAC,MAAM,eAAe,CAAC,GAAG,SAAS;CAjBjD,CAAC"}
|
|
@@ -4,29 +4,29 @@
|
|
|
4
4
|
* const comments = await CommentRepository.getCommentByIds(['foo', 'bar'])
|
|
5
5
|
* ```
|
|
6
6
|
*
|
|
7
|
-
* Fetches a collection of {@link Amity.
|
|
7
|
+
* Fetches a collection of {@link Amity.InternalComment} objects
|
|
8
8
|
*
|
|
9
|
-
* @param commentIds the IDs of the {@link Amity.
|
|
10
|
-
* @returns the associated collection of {@link Amity.
|
|
9
|
+
* @param commentIds the IDs of the {@link Amity.InternalComment} to fetch
|
|
10
|
+
* @returns the associated collection of {@link Amity.InternalComment} objects
|
|
11
11
|
*
|
|
12
12
|
* @category Comment API
|
|
13
13
|
* @async
|
|
14
14
|
*/
|
|
15
15
|
export declare const getCommentByIds: {
|
|
16
|
-
(commentIds: Amity.
|
|
16
|
+
(commentIds: Amity.InternalComment['commentId'][]): Promise<Amity.Cached<Amity.InternalComment[]>>;
|
|
17
17
|
/**
|
|
18
18
|
* ```js
|
|
19
19
|
* import { getCommentByIds } from '@amityco/ts-sdk'
|
|
20
20
|
* const comments = getCommentByIds.locally(['foo', 'bar'])
|
|
21
21
|
* ```
|
|
22
22
|
*
|
|
23
|
-
* Fetches a collection of {@link Amity.
|
|
23
|
+
* Fetches a collection of {@link Amity.InternalComment} objects from cache
|
|
24
24
|
*
|
|
25
|
-
* @param commentIds the IDs of the {@link Amity.
|
|
26
|
-
* @returns the associated collection of {@link Amity.
|
|
25
|
+
* @param commentIds the IDs of the {@link Amity.InternalComment} to fetch
|
|
26
|
+
* @returns the associated collection of {@link Amity.InternalComment} objects
|
|
27
27
|
*
|
|
28
28
|
* @category Comment API
|
|
29
29
|
*/
|
|
30
|
-
locally(commentIds: Amity.
|
|
30
|
+
locally(commentIds: Amity.InternalComment['commentId'][]): Amity.Cached<Amity.InternalComment[]> | undefined;
|
|
31
31
|
};
|
|
32
32
|
//# sourceMappingURL=getCommentByIds.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getCommentByIds.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/getCommentByIds.ts"],"names":[],"mappings":"AAUA;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,eAAe;iBACd,
|
|
1
|
+
{"version":3,"file":"getCommentByIds.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/getCommentByIds.ts"],"names":[],"mappings":"AAUA;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,eAAe;iBACd,MAAM,eAAe,CAAC,WAAW,CAAC,EAAE,GAC/C,QAAQ,MAAM,MAAM,CAAC,MAAM,eAAe,EAAE,CAAC,CAAC;IAmCjD;;;;;;;;;;;;OAYG;wBAEW,MAAM,eAAe,CAAC,WAAW,CAAC,EAAE,GAC/C,MAAM,MAAM,CAAC,MAAM,eAAe,EAAE,CAAC,GAAG,SAAS;CAlBnD,CAAC"}
|
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
* const success = await CommentRepository.hardDeleteComment('foobar')
|
|
5
5
|
* ```
|
|
6
6
|
*
|
|
7
|
-
* Deletes a {@link Amity.
|
|
7
|
+
* Deletes a {@link Amity.InternalComment}
|
|
8
8
|
*
|
|
9
|
-
* @param commentId The {@link Amity.
|
|
10
|
-
* @return A success boolean if the {@link Amity.
|
|
9
|
+
* @param commentId The {@link Amity.InternalComment} ID to delete
|
|
10
|
+
* @return A success boolean if the {@link Amity.InternalComment} was deleted
|
|
11
11
|
*
|
|
12
12
|
* @category Comment API
|
|
13
13
|
* @async
|
|
14
14
|
*/
|
|
15
|
-
export declare const hardDeleteComment: (commentId: Amity.
|
|
15
|
+
export declare const hardDeleteComment: (commentId: Amity.InternalComment['commentId']) => Promise<Amity.InternalComment>;
|
|
16
16
|
//# sourceMappingURL=hardDeleteComment.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hardDeleteComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/hardDeleteComment.ts"],"names":[],"mappings":"AAOA;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,iBAAiB,cACjB,
|
|
1
|
+
{"version":3,"file":"hardDeleteComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/hardDeleteComment.ts"],"names":[],"mappings":"AAOA;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,iBAAiB,cACjB,MAAM,eAAe,CAAC,WAAW,CAAC,KAC5C,QAAQ,MAAM,eAAe,CAO/B,CAAC"}
|
|
@@ -10,5 +10,5 @@
|
|
|
10
10
|
* @category Comment API
|
|
11
11
|
* @async
|
|
12
12
|
* */
|
|
13
|
-
export declare const isCommentFlaggedByMe: (commentId: Amity.
|
|
13
|
+
export declare const isCommentFlaggedByMe: (commentId: Amity.InternalComment['commentId']) => Promise<boolean>;
|
|
14
14
|
//# sourceMappingURL=isCommentFlaggedByMe.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"isCommentFlaggedByMe.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/isCommentFlaggedByMe.ts"],"names":[],"mappings":"AAMA;;;;;;;;;;;KAWK;AACL,eAAO,MAAM,oBAAoB,cACpB,
|
|
1
|
+
{"version":3,"file":"isCommentFlaggedByMe.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/isCommentFlaggedByMe.ts"],"names":[],"mappings":"AAMA;;;;;;;;;;;KAWK;AACL,eAAO,MAAM,oBAAoB,cACpB,MAAM,eAAe,CAAC,WAAW,CAAC,KAC5C,QAAQ,OAAO,CAajB,CAAC"}
|
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
* const comments = await CommentRepository.queryComments({ referenceType: 'post', referenceId: 'foo' })
|
|
5
5
|
* ```
|
|
6
6
|
*
|
|
7
|
-
* Queries a paginable list of {@link Amity.
|
|
7
|
+
* Queries a paginable list of {@link Amity.InternalComment} objects
|
|
8
8
|
*
|
|
9
9
|
* @param query The query parameters
|
|
10
|
-
* @returns A page of {@link Amity.
|
|
10
|
+
* @returns A page of {@link Amity.InternalComment} objects
|
|
11
11
|
*
|
|
12
12
|
* @category Comment API
|
|
13
13
|
* @async
|
|
14
14
|
*/
|
|
15
|
-
export declare const queryComments: (query: Amity.QueryComments) => Promise<Amity.Cached<Amity.Paged<Amity.
|
|
15
|
+
export declare const queryComments: (query: Amity.QueryComments) => Promise<Amity.Cached<Amity.Paged<Amity.InternalComment>>>;
|
|
16
16
|
//# sourceMappingURL=queryComments.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"queryComments.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/queryComments.ts"],"names":[],"mappings":"AASA;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,aAAa,UACjB,MAAM,aAAa,KACzB,QAAQ,MAAM,MAAM,CAAC,MAAM,KAAK,CAAC,
|
|
1
|
+
{"version":3,"file":"queryComments.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/queryComments.ts"],"names":[],"mappings":"AASA;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,aAAa,UACjB,MAAM,aAAa,KACzB,QAAQ,MAAM,MAAM,CAAC,MAAM,KAAK,CAAC,MAAM,eAAe,CAAC,CAAC,CAiD1D,CAAC"}
|
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
* const success = await CommentRepository.softDeleteComment('foobar')
|
|
5
5
|
* ```
|
|
6
6
|
*
|
|
7
|
-
* Deletes a {@link Amity.
|
|
7
|
+
* Deletes a {@link Amity.InternalComment}
|
|
8
8
|
*
|
|
9
|
-
* @param commentId The {@link Amity.
|
|
10
|
-
* @return A success boolean if the {@link Amity.
|
|
9
|
+
* @param commentId The {@link Amity.InternalComment} ID to delete
|
|
10
|
+
* @return A success boolean if the {@link Amity.InternalComment} was deleted
|
|
11
11
|
*
|
|
12
12
|
* @category Comment API
|
|
13
13
|
* @async
|
|
14
14
|
*/
|
|
15
|
-
export declare const softDeleteComment: (commentId: Amity.
|
|
15
|
+
export declare const softDeleteComment: (commentId: Amity.InternalComment['commentId']) => Promise<Amity.InternalComment>;
|
|
16
16
|
//# sourceMappingURL=softDeleteComment.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"softDeleteComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/softDeleteComment.ts"],"names":[],"mappings":"AAOA;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,iBAAiB,cACjB,
|
|
1
|
+
{"version":3,"file":"softDeleteComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/softDeleteComment.ts"],"names":[],"mappings":"AAOA;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,iBAAiB,cACjB,MAAM,eAAe,CAAC,WAAW,CAAC,KAC5C,QAAQ,MAAM,eAAe,CAO/B,CAAC"}
|
|
@@ -10,5 +10,5 @@
|
|
|
10
10
|
* @category Comment API
|
|
11
11
|
* @async
|
|
12
12
|
* */
|
|
13
|
-
export declare const unflagComment: (commentId: Amity.
|
|
13
|
+
export declare const unflagComment: (commentId: Amity.InternalComment['commentId']) => Promise<boolean>;
|
|
14
14
|
//# sourceMappingURL=unflagComment.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"unflagComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/unflagComment.ts"],"names":[],"mappings":"AASA;;;;;;;;;;;KAWK;AACL,eAAO,MAAM,aAAa,
|
|
1
|
+
{"version":3,"file":"unflagComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/unflagComment.ts"],"names":[],"mappings":"AASA;;;;;;;;;;;KAWK;AACL,eAAO,MAAM,aAAa,cACb,MAAM,eAAe,CAAC,WAAW,CAAC,KAC5C,QAAQ,OAAO,CAejB,CAAC"}
|
|
@@ -6,14 +6,14 @@
|
|
|
6
6
|
* })
|
|
7
7
|
* ```
|
|
8
8
|
*
|
|
9
|
-
* Updates an {@link Amity.
|
|
9
|
+
* Updates an {@link Amity.InternalComment}
|
|
10
10
|
*
|
|
11
|
-
* @param commentId The ID of the {@link Amity.
|
|
11
|
+
* @param commentId The ID of the {@link Amity.InternalComment} to edit
|
|
12
12
|
* @param patch The patch data to apply
|
|
13
|
-
* @returns the updated {@link Amity.
|
|
13
|
+
* @returns the updated {@link Amity.InternalComment} object
|
|
14
14
|
*
|
|
15
15
|
* @category Comment API
|
|
16
16
|
* @async
|
|
17
17
|
*/
|
|
18
|
-
export declare const updateComment: (commentId: Amity.
|
|
18
|
+
export declare const updateComment: (commentId: Amity.InternalComment['commentId'], patch: Patch<Amity.InternalComment, 'data' | 'metadata' | 'mentionees'>) => Promise<Amity.Cached<Amity.InternalComment>>;
|
|
19
19
|
//# sourceMappingURL=updateComment.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"updateComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/updateComment.ts"],"names":[],"mappings":"AAQA;;;;;;;;;;;;;;;;GAgBG;AACH,eAAO,MAAM,aAAa,cACb,
|
|
1
|
+
{"version":3,"file":"updateComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/api/updateComment.ts"],"names":[],"mappings":"AAQA;;;;;;;;;;;;;;;;GAgBG;AACH,eAAO,MAAM,aAAa,cACb,MAAM,eAAe,CAAC,WAAW,CAAC,SACtC,MAAM,MAAM,eAAe,EAAE,MAAM,GAAG,UAAU,GAAG,YAAY,CAAC,KACtE,QAAQ,MAAM,MAAM,CAAC,MAAM,eAAe,CAAC,CAmB7C,CAAC"}
|
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
* })
|
|
7
7
|
* ```
|
|
8
8
|
*
|
|
9
|
-
* Fired when a {@link Amity.
|
|
9
|
+
* Fired when a {@link Amity.InternalComment} has been created
|
|
10
10
|
*
|
|
11
11
|
* @param callback The function to call when the event was fired
|
|
12
12
|
* @returns an {@link Amity.Unsubscriber} function to stop listening
|
|
13
13
|
*
|
|
14
|
-
* @category
|
|
14
|
+
* @category InternalComment Events
|
|
15
15
|
*/
|
|
16
|
-
export declare const onCommentCreated: (callback: Amity.Listener<Amity.
|
|
16
|
+
export declare const onCommentCreated: (callback: Amity.Listener<Amity.InternalComment>) => Amity.Unsubscriber;
|
|
17
17
|
//# sourceMappingURL=onCommentCreated.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"onCommentCreated.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/onCommentCreated.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,gBAAgB,
|
|
1
|
+
{"version":3,"file":"onCommentCreated.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/onCommentCreated.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,gBAAgB,aACjB,MAAM,QAAQ,CAAC,MAAM,eAAe,CAAC,KAC9C,MAAM,YAAyE,CAAC"}
|
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
* })
|
|
7
7
|
* ```
|
|
8
8
|
*
|
|
9
|
-
* Fired when a {@link Amity.
|
|
9
|
+
* Fired when a {@link Amity.InternalComment} has been deleted
|
|
10
10
|
*
|
|
11
11
|
* @param callback The function to call when the event was fired
|
|
12
12
|
* @returns an {@link Amity.Unsubscriber} function to stop listening
|
|
13
13
|
*
|
|
14
|
-
* @category
|
|
14
|
+
* @category InternalComment Events
|
|
15
15
|
*/
|
|
16
|
-
export declare const onCommentDeleted: (callback: Amity.Listener<Amity.
|
|
16
|
+
export declare const onCommentDeleted: (callback: Amity.Listener<Amity.InternalComment>) => Amity.Unsubscriber;
|
|
17
17
|
//# sourceMappingURL=onCommentDeleted.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"onCommentDeleted.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/onCommentDeleted.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,gBAAgB,
|
|
1
|
+
{"version":3,"file":"onCommentDeleted.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/onCommentDeleted.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,gBAAgB,aACjB,MAAM,QAAQ,CAAC,MAAM,eAAe,CAAC,KAC9C,MAAM,YAAyE,CAAC"}
|
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
* })
|
|
7
7
|
* ```
|
|
8
8
|
*
|
|
9
|
-
* Fired when a {@link Amity.
|
|
9
|
+
* Fired when a {@link Amity.InternalComment} has been flagged
|
|
10
10
|
*
|
|
11
11
|
* @param callback The function to call when the event was fired
|
|
12
12
|
* @returns an {@link Amity.Unsubscriber} function to stop listening
|
|
13
13
|
*
|
|
14
|
-
* @category
|
|
14
|
+
* @category InternalComment Events
|
|
15
15
|
*/
|
|
16
|
-
export declare const onCommentFlagged: (callback: Amity.Listener<Amity.
|
|
16
|
+
export declare const onCommentFlagged: (callback: Amity.Listener<Amity.InternalComment>) => Amity.Unsubscriber;
|
|
17
17
|
//# sourceMappingURL=onCommentFlagged.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"onCommentFlagged.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/onCommentFlagged.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,gBAAgB,
|
|
1
|
+
{"version":3,"file":"onCommentFlagged.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/onCommentFlagged.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,gBAAgB,aACjB,MAAM,QAAQ,CAAC,MAAM,eAAe,CAAC,KAC9C,MAAM,YAAyE,CAAC"}
|
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
* })
|
|
7
7
|
* ```
|
|
8
8
|
*
|
|
9
|
-
* Fired when a {@link Amity.
|
|
9
|
+
* Fired when a {@link Amity.InternalComment} has been reacted
|
|
10
10
|
*
|
|
11
11
|
* @param callback The function to call when the event was fired
|
|
12
12
|
* @returns an {@link Amity.Unsubscriber} function to stop listening
|
|
13
13
|
*
|
|
14
|
-
* @category
|
|
14
|
+
* @category InternalComment Events
|
|
15
15
|
*/
|
|
16
|
-
export declare const onCommentReactionAdded: (callback: Amity.Listener<Amity.
|
|
16
|
+
export declare const onCommentReactionAdded: (callback: Amity.Listener<Amity.InternalComment>) => Amity.Unsubscriber;
|
|
17
17
|
//# sourceMappingURL=onCommentReactionAdded.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"onCommentReactionAdded.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/onCommentReactionAdded.ts"],"names":[],"mappings":"AAMA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,sBAAsB,aACvB,MAAM,QAAQ,CAAC,
|
|
1
|
+
{"version":3,"file":"onCommentReactionAdded.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/onCommentReactionAdded.ts"],"names":[],"mappings":"AAMA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,sBAAsB,aACvB,MAAM,QAAQ,CAAC,MAAM,eAAe,CAAC,KAC9C,MAAM,YAuBR,CAAC"}
|
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
* })
|
|
7
7
|
* ```
|
|
8
8
|
*
|
|
9
|
-
* Fired when a reaction has been removed from a {@link Amity.
|
|
9
|
+
* Fired when a reaction has been removed from a {@link Amity.InternalComment}
|
|
10
10
|
*
|
|
11
11
|
* @param callback The function to call when the event was fired
|
|
12
12
|
* @returns an {@link Amity.Unsubscriber} function to stop listening
|
|
13
13
|
*
|
|
14
|
-
* @category
|
|
14
|
+
* @category InternalComment Events
|
|
15
15
|
*/
|
|
16
|
-
export declare const onCommentReactionRemoved: (callback: Amity.Listener<Amity.
|
|
16
|
+
export declare const onCommentReactionRemoved: (callback: Amity.Listener<Amity.InternalComment>) => Amity.Unsubscriber;
|
|
17
17
|
//# sourceMappingURL=onCommentReactionRemoved.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"onCommentReactionRemoved.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/onCommentReactionRemoved.ts"],"names":[],"mappings":"AAMA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,wBAAwB,aACzB,MAAM,QAAQ,CAAC,
|
|
1
|
+
{"version":3,"file":"onCommentReactionRemoved.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/onCommentReactionRemoved.ts"],"names":[],"mappings":"AAMA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,wBAAwB,aACzB,MAAM,QAAQ,CAAC,MAAM,eAAe,CAAC,KAC9C,MAAM,YAuBR,CAAC"}
|
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
* })
|
|
7
7
|
* ```
|
|
8
8
|
*
|
|
9
|
-
* Fired when a flag has been removed from a {@link Amity.
|
|
9
|
+
* Fired when a flag has been removed from a {@link Amity.InternalComment}
|
|
10
10
|
*
|
|
11
11
|
* @param callback The function to call when the event was fired
|
|
12
12
|
* @returns an {@link Amity.Unsubscriber} function to stop listening
|
|
13
13
|
*
|
|
14
|
-
* @category
|
|
14
|
+
* @category InternalComment Events
|
|
15
15
|
*/
|
|
16
|
-
export declare const onCommentUnflagged: (callback: Amity.Listener<Amity.
|
|
16
|
+
export declare const onCommentUnflagged: (callback: Amity.Listener<Amity.InternalComment>) => Amity.Unsubscriber;
|
|
17
17
|
//# sourceMappingURL=onCommentUnflagged.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"onCommentUnflagged.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/onCommentUnflagged.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,kBAAkB,
|
|
1
|
+
{"version":3,"file":"onCommentUnflagged.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/onCommentUnflagged.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,kBAAkB,aACnB,MAAM,QAAQ,CAAC,MAAM,eAAe,CAAC,KAC9C,MAAM,YAA2E,CAAC"}
|
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
* })
|
|
7
7
|
* ```
|
|
8
8
|
*
|
|
9
|
-
* Fired when a {@link Amity.
|
|
9
|
+
* Fired when a {@link Amity.InternalComment} has been updated
|
|
10
10
|
*
|
|
11
11
|
* @param callback The function to call when the event was fired
|
|
12
12
|
* @returns an {@link Amity.Unsubscriber} function to stop listening
|
|
13
13
|
*
|
|
14
|
-
* @category
|
|
14
|
+
* @category InternalComment Events
|
|
15
15
|
*/
|
|
16
|
-
export declare const onCommentUpdated: (callback: Amity.Listener<Amity.
|
|
16
|
+
export declare const onCommentUpdated: (callback: Amity.Listener<Amity.InternalComment>) => Amity.Unsubscriber;
|
|
17
17
|
//# sourceMappingURL=onCommentUpdated.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"onCommentUpdated.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/onCommentUpdated.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,gBAAgB,
|
|
1
|
+
{"version":3,"file":"onCommentUpdated.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/onCommentUpdated.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,gBAAgB,aACjB,MAAM,QAAQ,CAAC,MAAM,eAAe,CAAC,KAC9C,MAAM,YAAyE,CAAC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const createCommentEventSubscriber: (event: keyof Amity.MqttCommentEvents, callback: Amity.Listener<Amity.
|
|
1
|
+
export declare const createCommentEventSubscriber: (event: keyof Amity.MqttCommentEvents, callback: Amity.Listener<Amity.InternalComment>) => Amity.Unsubscriber;
|
|
2
2
|
//# sourceMappingURL=utils.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/utils.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,4BAA4B,UAChC,MAAM,MAAM,iBAAiB,YAC1B,MAAM,QAAQ,CAAC,
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/events/utils.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,4BAA4B,UAChC,MAAM,MAAM,iBAAiB,YAC1B,MAAM,QAAQ,CAAC,MAAM,eAAe,CAAC,uBA8BhD,CAAC"}
|
|
@@ -9,13 +9,13 @@
|
|
|
9
9
|
* });
|
|
10
10
|
* ```
|
|
11
11
|
*
|
|
12
|
-
* Observe all mutation on a given {@link Amity.
|
|
12
|
+
* Observe all mutation on a given {@link Amity.InternalComment}
|
|
13
13
|
*
|
|
14
14
|
* @param commentId the ID of the comment to observe
|
|
15
15
|
* @param callback the function to call when new data are available
|
|
16
16
|
* @returns An {@link Amity.Unsubscriber} function to run when willing to stop observing the comment
|
|
17
17
|
*
|
|
18
|
-
* @category
|
|
18
|
+
* @category InternalComment Live Object
|
|
19
19
|
*/
|
|
20
|
-
export declare const getComment: (commentId: Amity.
|
|
20
|
+
export declare const getComment: (commentId: Amity.InternalComment['commentId'], callback: Amity.LiveObjectCallback<Amity.InternalComment>) => Amity.Unsubscriber;
|
|
21
21
|
//# sourceMappingURL=getComment.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/observers/getComment.ts"],"names":[],"mappings":"AAcA;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,UAAU,cACV,
|
|
1
|
+
{"version":3,"file":"getComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/observers/getComment.ts"],"names":[],"mappings":"AAcA;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,UAAU,cACV,MAAM,eAAe,CAAC,WAAW,CAAC,YACnC,MAAM,kBAAkB,CAAC,MAAM,eAAe,CAAC,KACxD,MAAM,YASR,CAAC"}
|
|
@@ -4,12 +4,12 @@
|
|
|
4
4
|
*
|
|
5
5
|
* let comments = []
|
|
6
6
|
* const unsub = getComments({
|
|
7
|
-
* referenceType: Amity.
|
|
8
|
-
* referenceId: Amity.
|
|
7
|
+
* referenceType: Amity.InternalComment['referenceType'];
|
|
8
|
+
* referenceId: Amity.InternalComment['referenceId'];
|
|
9
9
|
* }, response => merge(comments, response.data))
|
|
10
10
|
* ```
|
|
11
11
|
*
|
|
12
|
-
* Observe all mutations on a list of {@link Amity.
|
|
12
|
+
* Observe all mutations on a list of {@link Amity.InternalComment} for a given target object
|
|
13
13
|
*
|
|
14
14
|
* @param referenceType the type of the target
|
|
15
15
|
* @param referenceId the ID of the target
|
|
@@ -18,5 +18,5 @@
|
|
|
18
18
|
*
|
|
19
19
|
* @category Comments Live Collection
|
|
20
20
|
*/
|
|
21
|
-
export declare const getComments: (params: Amity.CommentLiveCollection, callback: Amity.LiveCollectionCallback<Amity.
|
|
21
|
+
export declare const getComments: (params: Amity.CommentLiveCollection, callback: Amity.LiveCollectionCallback<Amity.InternalComment>, config?: Amity.LiveCollectionConfig) => Amity.Unsubscriber;
|
|
22
22
|
//# sourceMappingURL=getComments.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getComments.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/observers/getComments.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"getComments.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/observers/getComments.ts"],"names":[],"mappings":"AAmCA;;;;;;;;;;;;;;;;;;;GAmBG;AACH,eAAO,MAAM,WAAW,WACd,MAAM,qBAAqB,YACzB,MAAM,sBAAsB,CAAC,MAAM,eAAe,CAAC,WACpD,MAAM,oBAAoB,KAClC,MAAM,YAyHR,CAAC"}
|
|
@@ -6,13 +6,13 @@
|
|
|
6
6
|
* const dispose = observeComment(commentId, ({ data }) => comment = data)
|
|
7
7
|
* ```
|
|
8
8
|
*
|
|
9
|
-
* Observe all mutation on a given {@link Amity.
|
|
9
|
+
* Observe all mutation on a given {@link Amity.InternalComment}
|
|
10
10
|
*
|
|
11
11
|
* @param commentId the ID of the comment to observe
|
|
12
12
|
* @param callback the function to call when new data are available
|
|
13
13
|
* @returns An {@link Amity.Unsubscriber} function to run when willing to stop observing the comment
|
|
14
14
|
*
|
|
15
|
-
* @category
|
|
15
|
+
* @category InternalComment Observer
|
|
16
16
|
*/
|
|
17
|
-
export declare const observeComment: <Events extends ["onFetch", "onUpdate", "onDelete", "onFlagged", "onUnflagged", "onReactionAdded", "onReactionRemoved"]>(commentId: string, callback: Amity.ObjectListener<Amity.Snapshot<Amity.
|
|
17
|
+
export declare const observeComment: <Events extends ["onFetch", "onUpdate", "onDelete", "onFlagged", "onUnflagged", "onReactionAdded", "onReactionRemoved"]>(commentId: string, callback: Amity.ObjectListener<Amity.Snapshot<Amity.InternalComment<any> | undefined>, Events>, policy?: Amity.QueryPolicy) => Amity.Unsubscriber;
|
|
18
18
|
//# sourceMappingURL=observeComment.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"observeComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/observers/observeComment.ts"],"names":[],"mappings":"AAeA;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,cAAc,sIAWd,MAAM,
|
|
1
|
+
{"version":3,"file":"observeComment.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/observers/observeComment.ts"],"names":[],"mappings":"AAeA;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,cAAc,sIAWd,MAAM,2GAET,MAAM,WAAW,KACxB,MAAM,YAwDR,CAAC"}
|
|
@@ -6,15 +6,15 @@
|
|
|
6
6
|
* const unsub = observeComments(postId, comment => merge(comments, comment))
|
|
7
7
|
* ```
|
|
8
8
|
*
|
|
9
|
-
* Observe all mutations on a list of {@link Amity.
|
|
9
|
+
* Observe all mutations on a list of {@link Amity.InternalComment} for a given {@link Amity.Post} object
|
|
10
10
|
*
|
|
11
11
|
* @param postId the ID of the post where to observe the comments
|
|
12
12
|
* @param callback the function to call when new data are available
|
|
13
13
|
* @returns An {@link Amity.Unsubscriber} function to run when willing to stop observing the comments
|
|
14
14
|
*
|
|
15
|
-
* @category
|
|
15
|
+
* @category InternalComment Observer
|
|
16
16
|
*/
|
|
17
|
-
export declare const observeComments: (postId: Amity.Post['postId'], callback: Amity.ObjectListener<Amity.
|
|
17
|
+
export declare const observeComments: (postId: Amity.Post['postId'], callback: Amity.ObjectListener<Amity.InternalComment, [
|
|
18
18
|
'onCreate',
|
|
19
19
|
'onUpdate',
|
|
20
20
|
'onDelete',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"observeComments.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/observers/observeComments.ts"],"names":[],"mappings":"AAYA;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,eAAe,WAClB,MAAM,IAAI,CAAC,QAAQ,CAAC,YAClB,MAAM,cAAc,CAC5B,
|
|
1
|
+
{"version":3,"file":"observeComments.d.ts","sourceRoot":"","sources":["../../../src/commentRepository/observers/observeComments.ts"],"names":[],"mappings":"AAYA;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,eAAe,WAClB,MAAM,IAAI,CAAC,QAAQ,CAAC,YAClB,MAAM,cAAc,CAC5B,MAAM,eAAe,EACrB;IACE,UAAU;IACV,UAAU;IACV,UAAU;IACV,WAAW;IACX,aAAa;IACb,iBAAiB;IACjB,mBAAmB;CACpB,CACF,KACA,MAAM,YAkCR,CAAC"}
|