mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 10:58:30 -05:00
Merge from vscode 5b9869eb02fa4c96205a74d05cad9164dfd06d60 (#5607)
This commit is contained in:
185
src/vs/vscode.proposed.d.ts
vendored
185
src/vs/vscode.proposed.d.ts
vendored
@@ -957,15 +957,6 @@ declare module 'vscode' {
|
||||
reactionProvider?: CommentReactionProvider;
|
||||
}
|
||||
|
||||
export interface CommentController {
|
||||
/**
|
||||
* The active [comment thread](#CommentThread) or `undefined`. The `activeCommentThread` is the comment thread of
|
||||
* the comment widget that currently has focus. It's `undefined` when the focus is not in any comment thread widget, or
|
||||
* the comment widget created from [comment thread template](#CommentThreadTemplate).
|
||||
*/
|
||||
readonly activeCommentThread: CommentThread | undefined;
|
||||
}
|
||||
|
||||
namespace workspace {
|
||||
/**
|
||||
* DEPRECATED
|
||||
@@ -979,21 +970,6 @@ declare module 'vscode' {
|
||||
export function registerWorkspaceCommentProvider(provider: WorkspaceCommentProvider): Disposable;
|
||||
}
|
||||
|
||||
/**
|
||||
* Collapsible state of a [comment thread](#CommentThread)
|
||||
*/
|
||||
export enum CommentThreadCollapsibleState {
|
||||
/**
|
||||
* Determines an item is collapsed
|
||||
*/
|
||||
Collapsed = 0,
|
||||
|
||||
/**
|
||||
* Determines an item is expanded
|
||||
*/
|
||||
Expanded = 1
|
||||
}
|
||||
|
||||
/**
|
||||
* A collection of [comments](#Comment) representing a conversation at a particular range in a document.
|
||||
*/
|
||||
@@ -1008,28 +984,6 @@ declare module 'vscode' {
|
||||
*/
|
||||
readonly uri: Uri;
|
||||
|
||||
/**
|
||||
* The range the comment thread is located within the document. The thread icon will be shown
|
||||
* at the first line of the range.
|
||||
*/
|
||||
readonly range: Range;
|
||||
|
||||
/**
|
||||
* The ordered comments of the thread.
|
||||
*/
|
||||
comments: Comment[];
|
||||
|
||||
/**
|
||||
* Whether the thread should be collapsed or expanded when opening the document.
|
||||
* Defaults to Collapsed.
|
||||
*/
|
||||
collapsibleState: CommentThreadCollapsibleState;
|
||||
|
||||
/**
|
||||
* The optional human-readable label describing the [Comment Thread](#CommentThread)
|
||||
*/
|
||||
label?: string;
|
||||
|
||||
/**
|
||||
* Optional accept input command
|
||||
*
|
||||
@@ -1038,46 +992,6 @@ declare module 'vscode' {
|
||||
* This command will disabled when the comment editor is empty.
|
||||
*/
|
||||
acceptInputCommand?: Command;
|
||||
|
||||
|
||||
/**
|
||||
* Dispose this comment thread.
|
||||
*
|
||||
* Once disposed, this comment thread will be removed from visible editors and Comment Panel when approriate.
|
||||
*/
|
||||
dispose(): void;
|
||||
}
|
||||
|
||||
/**
|
||||
* Author information of a [comment](#Comment)
|
||||
*/
|
||||
|
||||
export interface CommentAuthorInformation {
|
||||
/**
|
||||
* The display name of the author of the comment
|
||||
*/
|
||||
name: string;
|
||||
|
||||
/**
|
||||
* The optional icon path for the author
|
||||
*/
|
||||
iconPath?: Uri;
|
||||
}
|
||||
|
||||
/**
|
||||
* Author information of a [comment](#Comment)
|
||||
*/
|
||||
|
||||
export interface CommentAuthorInformation {
|
||||
/**
|
||||
* The display name of the author of the comment
|
||||
*/
|
||||
name: string;
|
||||
|
||||
/**
|
||||
* The optional icon path for the author
|
||||
*/
|
||||
iconPath?: Uri;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1089,22 +1003,6 @@ declare module 'vscode' {
|
||||
*/
|
||||
id: string;
|
||||
|
||||
/**
|
||||
* The human-readable comment body
|
||||
*/
|
||||
body: MarkdownString;
|
||||
|
||||
/**
|
||||
* The author information of the comment
|
||||
*/
|
||||
author: CommentAuthorInformation;
|
||||
|
||||
/**
|
||||
* Optional label describing the [Comment](#Comment)
|
||||
* Label will be rendered next to authorName if exists.
|
||||
*/
|
||||
label?: string;
|
||||
|
||||
/**
|
||||
* The command to be executed if the comment is selected in the Comments Panel
|
||||
*/
|
||||
@@ -1124,16 +1022,6 @@ declare module 'vscode' {
|
||||
* Setter and getter for the contents of the comment input box
|
||||
*/
|
||||
value: string;
|
||||
|
||||
/**
|
||||
* The uri of the document comment input box has been created on
|
||||
*/
|
||||
resource: Uri;
|
||||
|
||||
/**
|
||||
* The range the comment input box is located within the document
|
||||
*/
|
||||
range: Range;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1146,36 +1034,12 @@ declare module 'vscode' {
|
||||
provideCommentingRanges(document: TextDocument, token: CancellationToken): ProviderResult<Range[]>;
|
||||
}
|
||||
|
||||
/**
|
||||
* Comment thread template for new comment thread creation.
|
||||
*/
|
||||
export interface CommentThreadTemplate {
|
||||
export interface EmptyCommentThreadFactory {
|
||||
/**
|
||||
* The human-readable label describing the [Comment Thread](#CommentThread)
|
||||
* The method `createEmptyCommentThread` is called when users attempt to create new comment thread from the gutter or command palette.
|
||||
* Extensions still need to call `createCommentThread` inside this call when appropriate.
|
||||
*/
|
||||
readonly label: string;
|
||||
|
||||
/**
|
||||
* Optional accept input command
|
||||
*
|
||||
* `acceptInputCommand` is the default action rendered on Comment Widget, which is always placed rightmost.
|
||||
* This command will be invoked when users the user accepts the value in the comment editor.
|
||||
* This command will disabled when the comment editor is empty.
|
||||
*/
|
||||
readonly acceptInputCommand?: Command;
|
||||
|
||||
/**
|
||||
* Optional additonal commands.
|
||||
*
|
||||
* `additionalCommands` are the secondary actions rendered on Comment Widget.
|
||||
*/
|
||||
readonly additionalCommands?: Command[];
|
||||
|
||||
/**
|
||||
* The command to be executed when users try to delete the comment thread. Currently, this is only called
|
||||
* when the user collapses a comment thread that has no comments in it.
|
||||
*/
|
||||
readonly deleteCommand?: Command;
|
||||
createEmptyCommentThread(document: TextDocument, range: Range): ProviderResult<void>;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1183,41 +1047,12 @@ declare module 'vscode' {
|
||||
* provide users various ways to interact with comments.
|
||||
*/
|
||||
export interface CommentController {
|
||||
/**
|
||||
* The id of this comment controller.
|
||||
*/
|
||||
readonly id: string;
|
||||
|
||||
/**
|
||||
* The human-readable label of this comment controller.
|
||||
*/
|
||||
readonly label: string;
|
||||
|
||||
/**
|
||||
* The active [comment input box](#CommentInputBox) or `undefined`. The active `inputBox` is the input box of
|
||||
* the comment thread widget that currently has focus. It's `undefined` when the focus is not in any CommentInputBox.
|
||||
*/
|
||||
readonly inputBox: CommentInputBox | undefined;
|
||||
|
||||
/**
|
||||
* Optional comment thread template information.
|
||||
*
|
||||
* The comment controller will use this information to create the comment widget when users attempt to create new comment thread
|
||||
* from the gutter or command palette.
|
||||
*
|
||||
* When users run `CommentThreadTemplate.acceptInputCommand` or `CommentThreadTemplate.additionalCommands`, extensions should create
|
||||
* the approriate [CommentThread](#CommentThread).
|
||||
*
|
||||
* If not provided, users won't be able to create new comment threads in the editor.
|
||||
*/
|
||||
template?: CommentThreadTemplate;
|
||||
|
||||
/**
|
||||
* Optional commenting range provider. Provide a list [ranges](#Range) which support commenting to any given resource uri.
|
||||
*
|
||||
* If not provided and `emptyCommentThreadFactory` exits, users can leave comments in any document opened in the editor.
|
||||
*/
|
||||
commentingRangeProvider?: CommentingRangeProvider;
|
||||
readonly inputBox?: CommentInputBox;
|
||||
|
||||
/**
|
||||
* Create a [comment thread](#CommentThread). The comment thread will be displayed in visible text editors (if the resource matches)
|
||||
@@ -1230,6 +1065,16 @@ declare module 'vscode' {
|
||||
*/
|
||||
createCommentThread(id: string, uri: Uri, range: Range, comments: Comment[]): CommentThread;
|
||||
|
||||
/**
|
||||
* Optional new comment thread factory.
|
||||
*/
|
||||
emptyCommentThreadFactory?: EmptyCommentThreadFactory;
|
||||
|
||||
/**
|
||||
* Optional reaction provider
|
||||
*/
|
||||
reactionProvider?: CommentReactionProvider;
|
||||
|
||||
/**
|
||||
* Dispose this comment controller.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user