Update comment sample

This commit is contained in:
Peng Lyu
2019-08-01 10:50:33 -07:00
parent 0b3a31bf2b
commit 5d4c7045ba

38
comment-sample/src/typings/vscode.d.ts vendored Normal file
View File

@ -0,0 +1,38 @@
declare module 'vscode' {
/**
* Reactions of a [comment](#Comment)
*/
export interface CommentReaction {
/**
* The human-readable label for the reaction
*/
readonly label: string;
/**
* Icon for the reaction shown in UI.
*/
readonly iconPath: string | Uri;
/**
* The number of users who have reacted to this reaction
*/
readonly count: number;
/**
* Whether the [author](CommentAuthorInformation) of the comment has reacted to this reaction
*/
readonly authorHasReacted: boolean;
}
export interface Comment {
reactions?: CommentReaction[];
}
export interface CommentController {
/**
*
*/
reactionHandler?: (comment: Comment, reaction: CommentReaction) => Promise<void>;
}
}