Skip to content

Vizel API / vue/src / UseVizelCommentResult

Interface: UseVizelCommentResult ​

Defined in: packages/vue/src/composables/useVizelComment.ts:15

Comment composable result

Properties ​

activeCommentId ​

ts
activeCommentId: ComputedRef<string | null>;

Defined in: packages/vue/src/composables/useVizelComment.ts:19

Currently active comment ID


addComment ​

ts
addComment: (text, author?) => Promise<VizelComment | null>;

Defined in: packages/vue/src/composables/useVizelComment.ts:25

Add a comment to the current selection

Parameters ​

ParameterType
textstring
author?string

Returns ​

Promise&lt;VizelComment | null&gt;


comments ​

ts
comments: ComputedRef<VizelComment[]>;

Defined in: packages/vue/src/composables/useVizelComment.ts:17

All stored comments (newest first)


error ​

ts
error: ComputedRef<Error | null>;

Defined in: packages/vue/src/composables/useVizelComment.ts:23

Last error that occurred


getCommentById ​

ts
getCommentById: (commentId) => 
  | VizelComment
  | undefined;

Defined in: packages/vue/src/composables/useVizelComment.ts:43

Get a comment by its ID

Parameters ​

ParameterType
commentIdstring

Returns ​

| VizelComment | undefined


isLoading ​

ts
isLoading: ComputedRef<boolean>;

Defined in: packages/vue/src/composables/useVizelComment.ts:21

Whether comments are loading


loadComments ​

ts
loadComments: () => Promise<VizelComment[]>;

Defined in: packages/vue/src/composables/useVizelComment.ts:41

Load all comments from storage

Returns ​

Promise&lt;VizelComment[]&gt;


removeComment ​

ts
removeComment: (commentId) => Promise<void>;

Defined in: packages/vue/src/composables/useVizelComment.ts:27

Remove a comment and its mark

Parameters ​

ParameterType
commentIdstring

Returns ​

Promise&lt;void&gt;


reopenComment ​

ts
reopenComment: (commentId) => Promise<boolean>;

Defined in: packages/vue/src/composables/useVizelComment.ts:31

Reopen a resolved comment

Parameters ​

ParameterType
commentIdstring

Returns ​

Promise&lt;boolean&gt;


replyToComment ​

ts
replyToComment: (commentId, text, author?) => Promise<
  | VizelCommentReply
| null>;

Defined in: packages/vue/src/composables/useVizelComment.ts:33

Add a reply to a comment

Parameters ​

ParameterType
commentIdstring
textstring
author?string

Returns ​

Promise&lt; | VizelCommentReply | null&gt;


resolveComment ​

ts
resolveComment: (commentId) => Promise<boolean>;

Defined in: packages/vue/src/composables/useVizelComment.ts:29

Mark a comment as resolved

Parameters ​

ParameterType
commentIdstring

Returns ​

Promise&lt;boolean&gt;


setActiveComment ​

ts
setActiveComment: (commentId) => void;

Defined in: packages/vue/src/composables/useVizelComment.ts:39

Set the active comment

Parameters ​

ParameterType
commentIdstring | null

Returns ​

void

Released under the MIT License.