Merge from vscode 2c306f762bf9c3db82dc06c7afaa56ef46d72f79 (#14050)

* Merge from vscode 2c306f762bf9c3db82dc06c7afaa56ef46d72f79

* Fix breaks

* Extension management fixes

* Fix breaks in windows bundling

* Fix/skip failing tests

* Update distro

* Add clear to nuget.config

* Add hygiene task

* Bump distro

* Fix hygiene issue

* Add build to hygiene exclusion

* Update distro

* Update hygiene

* Hygiene exclusions

* Update tsconfig

* Bump distro for server breaks

* Update build config

* Update darwin path

* Add done calls to notebook tests

* Skip failing tests

* Disable smoke tests
This commit is contained in:
Karl Burtram
2021-02-09 16:15:05 -08:00
committed by GitHub
parent 6f192f9af5
commit ce612a3d96
1929 changed files with 68012 additions and 34564 deletions

408
src/vs/monaco.d.ts vendored
View File

@@ -1115,6 +1115,10 @@ declare namespace monaco.editor {
* Defaults to true.
*/
wordBasedSuggestions?: boolean;
/**
* Controls whether word based completions should be included from opened documents of the same language or any language.
*/
wordBasedSuggestionsOnlySameLanguage?: boolean;
/**
* Controls whether the semanticHighlighting is shown for the languages that support it.
* true: semanticHighlighting is enabled for all themes
@@ -1685,6 +1689,10 @@ declare namespace monaco.editor {
* @return EOL char sequence (e.g.: '\n' or '\r\n').
*/
getEOL(): string;
/**
* Get the end of line sequence predominantly used in the text buffer.
*/
getEndOfLineSequence(): EndOfLineSequence;
/**
* Get the minimum legal column for line at `lineNumber`
*/
@@ -2580,6 +2588,14 @@ declare namespace monaco.editor {
Full = 4
}
export enum InDiffEditorState {
None = 0,
SideBySideLeft = 1,
SideBySideRight = 2,
InlineLeft = 3,
InlineRight = 4
}
/**
* Configuration options for the editor.
*/
@@ -2587,11 +2603,15 @@ declare namespace monaco.editor {
/**
* This editor is used inside a diff editor.
*/
inDiffEditor?: boolean;
inDiffEditor?: InDiffEditorState;
/**
* The aria label for the editor's textarea (when it is focused).
*/
ariaLabel?: string;
/**
* The `tabindex` property of the editor's textarea
*/
tabIndex?: number;
/**
* Render vertical lines at the specified columns.
* Defaults to empty array.
@@ -2635,7 +2655,7 @@ declare namespace monaco.editor {
* Remove unusual line terminators like LINE SEPARATOR (LS), PARAGRAPH SEPARATOR (PS).
* Defaults to 'prompt'.
*/
unusualLineTerminators?: 'off' | 'prompt' | 'auto';
unusualLineTerminators?: 'auto' | 'off' | 'prompt';
/**
* Should the corresponding line be selected when clicking on the line number?
* Defaults to true.
@@ -2679,9 +2699,13 @@ declare namespace monaco.editor {
*/
readOnly?: boolean;
/**
* Rename matching regions on type.
* Enable linked editing.
* Defaults to false.
*/
linkedEditing?: boolean;
/**
* deprecated, use linkedEditing instead
*/
renameOnType?: boolean;
/**
* Should the editor render validation decorations.
@@ -2905,6 +2929,10 @@ declare namespace monaco.editor {
* Suggest options.
*/
suggest?: ISuggestOptions;
/**
* Smart select opptions;
*/
smartSelect?: ISmartSelectOptions;
/**
*
*/
@@ -2951,6 +2979,11 @@ declare namespace monaco.editor {
* Defaults to advanced.
*/
autoIndent?: 'none' | 'keep' | 'brackets' | 'advanced' | 'full';
/**
* Emulate selection behaviour of tab characters when using spaces for indentation.
* This means selection will stick to tab stops.
*/
stickyTabStops?: boolean;
/**
* Enable format on type.
* Defaults to false.
@@ -3026,6 +3059,14 @@ declare namespace monaco.editor {
* Defaults to true.
*/
codeLens?: boolean;
/**
* Code lens font family. Defaults to editor font family.
*/
codeLensFontFamily?: string;
/**
* Code lens font size. Default to 90% of the editor font size
*/
codeLensFontSize?: number;
/**
* Control the behavior and rendering of the code action lightbulb.
*/
@@ -3177,15 +3218,19 @@ declare namespace monaco.editor {
*/
reverse?: boolean;
/**
* Original editor should be have code lens enabled?
* Should the diff editor enable code lens?
* Defaults to false.
*/
originalCodeLens?: boolean;
diffCodeLens?: boolean;
/**
* Modified editor should be have code lens enabled?
* Defaults to false.
* Is the diff editor inside another editor
* Defaults to false
*/
modifiedCodeLens?: boolean;
isInEmbeddedEditor?: boolean;
/**
* Control the wrapping of the diff editor.
*/
diffWordWrap?: 'off' | 'on' | 'inherit';
}
/**
@@ -3656,6 +3701,11 @@ declare namespace monaco.editor {
* Defaults to `horizontalScrollbarSize`.
*/
horizontalSliderSize?: number;
/**
* Scroll gutter clicks move by page vs jump to position.
* Defaults to false.
*/
scrollByPage?: boolean;
}
export interface InternalEditorScrollbarOptions {
@@ -3671,6 +3721,7 @@ declare namespace monaco.editor {
readonly horizontalSliderSize: number;
readonly verticalScrollbarSize: number;
readonly verticalSliderSize: number;
readonly scrollByPage: boolean;
}
/**
@@ -3702,9 +3753,13 @@ declare namespace monaco.editor {
*/
showIcons?: boolean;
/**
* Max suggestions to show in suggestions. Defaults to 12.
* Enable or disable the suggest status bar.
*/
maxVisibleSuggestions?: number;
showStatusBar?: boolean;
/**
* Show details inline with the label. Defaults to true.
*/
showInlineDetails?: boolean;
/**
* Show method-suggestions.
*/
@@ -3813,19 +3868,16 @@ declare namespace monaco.editor {
* Show snippet-suggestions.
*/
showSnippets?: boolean;
/**
* Status bar related settings.
*/
statusBar?: {
/**
* Controls the visibility of the status bar at the bottom of the suggest widget.
*/
visible?: boolean;
};
}
export type InternalSuggestOptions = Readonly<Required<ISuggestOptions>>;
export interface ISmartSelectOptions {
selectLeadingAndTrailingWhitespace?: boolean;
}
export type SmartSelectOptions = Readonly<Required<ISmartSelectOptions>>;
/**
* Describes how to indent wrapped lines.
*/
@@ -3868,112 +3920,118 @@ declare namespace monaco.editor {
automaticLayout = 9,
autoSurround = 10,
codeLens = 11,
colorDecorators = 12,
columnSelection = 13,
comments = 14,
contextmenu = 15,
copyWithSyntaxHighlighting = 16,
cursorBlinking = 17,
cursorSmoothCaretAnimation = 18,
cursorStyle = 19,
cursorSurroundingLines = 20,
cursorSurroundingLinesStyle = 21,
cursorWidth = 22,
disableLayerHinting = 23,
disableMonospaceOptimizations = 24,
dragAndDrop = 25,
emptySelectionClipboard = 26,
extraEditorClassName = 27,
fastScrollSensitivity = 28,
find = 29,
fixedOverflowWidgets = 30,
folding = 31,
foldingStrategy = 32,
foldingHighlight = 33,
unfoldOnClickAfterEndOfLine = 34,
fontFamily = 35,
fontInfo = 36,
fontLigatures = 37,
fontSize = 38,
fontWeight = 39,
formatOnPaste = 40,
formatOnType = 41,
glyphMargin = 42,
gotoLocation = 43,
hideCursorInOverviewRuler = 44,
highlightActiveIndentGuide = 45,
hover = 46,
inDiffEditor = 47,
letterSpacing = 48,
lightbulb = 49,
lineDecorationsWidth = 50,
lineHeight = 51,
lineNumbers = 52,
lineNumbersMinChars = 53,
links = 54,
matchBrackets = 55,
minimap = 56,
mouseStyle = 57,
mouseWheelScrollSensitivity = 58,
mouseWheelZoom = 59,
multiCursorMergeOverlapping = 60,
multiCursorModifier = 61,
multiCursorPaste = 62,
occurrencesHighlight = 63,
overviewRulerBorder = 64,
overviewRulerLanes = 65,
padding = 66,
parameterHints = 67,
peekWidgetDefaultFocus = 68,
definitionLinkOpensInPeek = 69,
quickSuggestions = 70,
quickSuggestionsDelay = 71,
readOnly = 72,
renameOnType = 73,
renderControlCharacters = 74,
renderIndentGuides = 75,
renderFinalNewline = 76,
renderLineHighlight = 77,
renderLineHighlightOnlyWhenFocus = 78,
renderValidationDecorations = 79,
renderWhitespace = 80,
revealHorizontalRightPadding = 81,
roundedSelection = 82,
rulers = 83,
scrollbar = 84,
scrollBeyondLastColumn = 85,
scrollBeyondLastLine = 86,
scrollPredominantAxis = 87,
selectionClipboard = 88,
selectionHighlight = 89,
selectOnLineNumbers = 90,
showFoldingControls = 91,
showUnused = 92,
snippetSuggestions = 93,
smoothScrolling = 94,
stopRenderingLineAfter = 95,
suggest = 96,
suggestFontSize = 97,
suggestLineHeight = 98,
suggestOnTriggerCharacters = 99,
suggestSelection = 100,
tabCompletion = 101,
unusualLineTerminators = 102,
useTabStops = 103,
wordSeparators = 104,
wordWrap = 105,
wordWrapBreakAfterCharacters = 106,
wordWrapBreakBeforeCharacters = 107,
wordWrapColumn = 108,
wordWrapMinified = 109,
wrappingIndent = 110,
wrappingStrategy = 111,
showDeprecated = 112,
editorClassName = 113,
pixelRatio = 114,
tabFocusMode = 115,
layoutInfo = 116,
wrappingInfo = 117
codeLensFontFamily = 12,
codeLensFontSize = 13,
colorDecorators = 14,
columnSelection = 15,
comments = 16,
contextmenu = 17,
copyWithSyntaxHighlighting = 18,
cursorBlinking = 19,
cursorSmoothCaretAnimation = 20,
cursorStyle = 21,
cursorSurroundingLines = 22,
cursorSurroundingLinesStyle = 23,
cursorWidth = 24,
disableLayerHinting = 25,
disableMonospaceOptimizations = 26,
dragAndDrop = 27,
emptySelectionClipboard = 28,
extraEditorClassName = 29,
fastScrollSensitivity = 30,
find = 31,
fixedOverflowWidgets = 32,
folding = 33,
foldingStrategy = 34,
foldingHighlight = 35,
unfoldOnClickAfterEndOfLine = 36,
fontFamily = 37,
fontInfo = 38,
fontLigatures = 39,
fontSize = 40,
fontWeight = 41,
formatOnPaste = 42,
formatOnType = 43,
glyphMargin = 44,
gotoLocation = 45,
hideCursorInOverviewRuler = 46,
highlightActiveIndentGuide = 47,
hover = 48,
inDiffEditor = 49,
letterSpacing = 50,
lightbulb = 51,
lineDecorationsWidth = 52,
lineHeight = 53,
lineNumbers = 54,
lineNumbersMinChars = 55,
linkedEditing = 56,
links = 57,
matchBrackets = 58,
minimap = 59,
mouseStyle = 60,
mouseWheelScrollSensitivity = 61,
mouseWheelZoom = 62,
multiCursorMergeOverlapping = 63,
multiCursorModifier = 64,
multiCursorPaste = 65,
occurrencesHighlight = 66,
overviewRulerBorder = 67,
overviewRulerLanes = 68,
padding = 69,
parameterHints = 70,
peekWidgetDefaultFocus = 71,
definitionLinkOpensInPeek = 72,
quickSuggestions = 73,
quickSuggestionsDelay = 74,
readOnly = 75,
renameOnType = 76,
renderControlCharacters = 77,
renderIndentGuides = 78,
renderFinalNewline = 79,
renderLineHighlight = 80,
renderLineHighlightOnlyWhenFocus = 81,
renderValidationDecorations = 82,
renderWhitespace = 83,
revealHorizontalRightPadding = 84,
roundedSelection = 85,
rulers = 86,
scrollbar = 87,
scrollBeyondLastColumn = 88,
scrollBeyondLastLine = 89,
scrollPredominantAxis = 90,
selectionClipboard = 91,
selectionHighlight = 92,
selectOnLineNumbers = 93,
showFoldingControls = 94,
showUnused = 95,
snippetSuggestions = 96,
smartSelect = 97,
smoothScrolling = 98,
stickyTabStops = 99,
stopRenderingLineAfter = 100,
suggest = 101,
suggestFontSize = 102,
suggestLineHeight = 103,
suggestOnTriggerCharacters = 104,
suggestSelection = 105,
tabCompletion = 106,
tabIndex = 107,
unusualLineTerminators = 108,
useTabStops = 109,
wordSeparators = 110,
wordWrap = 111,
wordWrapBreakAfterCharacters = 112,
wordWrapBreakBeforeCharacters = 113,
wordWrapColumn = 114,
wordWrapMinified = 115,
wrappingIndent = 116,
wrappingStrategy = 117,
showDeprecated = 118,
editorClassName = 119,
pixelRatio = 120,
tabFocusMode = 121,
layoutInfo = 122,
wrappingInfo = 123
}
export const EditorOptions: {
acceptSuggestionOnCommitCharacter: IEditorOption<EditorOption.acceptSuggestionOnCommitCharacter, boolean>;
@@ -3987,7 +4045,10 @@ declare namespace monaco.editor {
autoIndent: IEditorOption<EditorOption.autoIndent, EditorAutoIndentStrategy>;
automaticLayout: IEditorOption<EditorOption.automaticLayout, boolean>;
autoSurround: IEditorOption<EditorOption.autoSurround, EditorAutoSurroundStrategy>;
stickyTabStops: IEditorOption<EditorOption.stickyTabStops, boolean>;
codeLens: IEditorOption<EditorOption.codeLens, boolean>;
codeLensFontFamily: IEditorOption<EditorOption.codeLensFontFamily, string>;
codeLensFontSize: IEditorOption<EditorOption.codeLensFontSize, number>;
colorDecorators: IEditorOption<EditorOption.colorDecorators, boolean>;
columnSelection: IEditorOption<EditorOption.columnSelection, boolean>;
comments: IEditorOption<EditorOption.comments, EditorCommentsOptions>;
@@ -4023,13 +4084,14 @@ declare namespace monaco.editor {
hideCursorInOverviewRuler: IEditorOption<EditorOption.hideCursorInOverviewRuler, boolean>;
highlightActiveIndentGuide: IEditorOption<EditorOption.highlightActiveIndentGuide, boolean>;
hover: IEditorOption<EditorOption.hover, EditorHoverOptions>;
inDiffEditor: IEditorOption<EditorOption.inDiffEditor, boolean>;
inDiffEditor: IEditorOption<EditorOption.inDiffEditor, number>;
letterSpacing: IEditorOption<EditorOption.letterSpacing, number>;
lightbulb: IEditorOption<EditorOption.lightbulb, EditorLightbulbOptions>;
lineDecorationsWidth: IEditorOption<EditorOption.lineDecorationsWidth, string | number>;
lineHeight: IEditorOption<EditorOption.lineHeight, number>;
lineNumbers: IEditorOption<EditorOption.lineNumbers, InternalEditorRenderLineNumbersOptions>;
lineNumbersMinChars: IEditorOption<EditorOption.lineNumbersMinChars, number>;
linkedEditing: IEditorOption<EditorOption.linkedEditing, boolean>;
links: IEditorOption<EditorOption.links, boolean>;
matchBrackets: IEditorOption<EditorOption.matchBrackets, 'always' | 'never' | 'near'>;
minimap: IEditorOption<EditorOption.minimap, EditorMinimapOptions>;
@@ -4071,6 +4133,7 @@ declare namespace monaco.editor {
showUnused: IEditorOption<EditorOption.showUnused, boolean>;
showDeprecated: IEditorOption<EditorOption.showDeprecated, boolean>;
snippetSuggestions: IEditorOption<EditorOption.snippetSuggestions, 'none' | 'top' | 'bottom' | 'inline'>;
smartSelect: IEditorOption<EditorOption.smartSelect, any>;
smoothScrolling: IEditorOption<EditorOption.smoothScrolling, boolean>;
stopRenderingLineAfter: IEditorOption<EditorOption.stopRenderingLineAfter, number>;
suggest: IEditorOption<EditorOption.suggest, InternalSuggestOptions>;
@@ -4079,7 +4142,8 @@ declare namespace monaco.editor {
suggestOnTriggerCharacters: IEditorOption<EditorOption.suggestOnTriggerCharacters, boolean>;
suggestSelection: IEditorOption<EditorOption.suggestSelection, 'first' | 'recentlyUsed' | 'recentlyUsedByPrefix'>;
tabCompletion: IEditorOption<EditorOption.tabCompletion, 'on' | 'off' | 'onlySnippets'>;
unusualLineTerminators: IEditorOption<EditorOption.unusualLineTerminators, 'off' | 'prompt' | 'auto'>;
tabIndex: IEditorOption<EditorOption.tabIndex, number>;
unusualLineTerminators: IEditorOption<EditorOption.unusualLineTerminators, 'auto' | 'off' | 'prompt'>;
useTabStops: IEditorOption<EditorOption.useTabStops, boolean>;
wordSeparators: IEditorOption<EditorOption.wordSeparators, string>;
wordWrap: IEditorOption<EditorOption.wordWrap, 'on' | 'off' | 'wordWrapColumn' | 'bounded'>;
@@ -4244,6 +4308,18 @@ declare namespace monaco.editor {
* If null is returned, the content widget will be placed off screen.
*/
getPosition(): IContentWidgetPosition | null;
/**
* Optional function that is invoked before rendering
* the content widget. If a dimension is returned the editor will
* attempt to use it.
*/
beforeRender?(): IDimension | null;
/**
* Optional function that is invoked after rendering the content
* widget. Is being invoked with the selected position preference
* or `null` if not rendered.
*/
afterRender?(position: ContentWidgetPositionPreference | null): void;
}
/**
@@ -4503,6 +4579,11 @@ declare namespace monaco.editor {
* An event emitted after composition has ended.
*/
onDidCompositionEnd(listener: () => void): IDisposable;
/**
* An event emitted when editing failed because the editor is read-only.
* @event
*/
onDidAttemptReadOnlyEdit(listener: () => void): IDisposable;
/**
* An event emitted when users paste text in the editor.
* @event
@@ -5030,9 +5111,9 @@ declare namespace monaco.languages {
export function registerDocumentHighlightProvider(languageId: string, provider: DocumentHighlightProvider): IDisposable;
/**
* Register an on type rename provider.
* Register an linked editing range provider.
*/
export function registerOnTypeRenameProvider(languageId: string, provider: OnTypeRenameProvider): IDisposable;
export function registerLinkedEditingRangeProvider(languageId: string, provider: LinkedEditingRangeProvider): IDisposable;
/**
* Register a definition provider (used by e.g. go to definition).
@@ -5406,31 +5487,6 @@ declare namespace monaco.languages {
provideHover(model: editor.ITextModel, position: Position, token: CancellationToken): ProviderResult<Hover>;
}
/**
* An evaluatable expression represents additional information for an expression in a document. Evaluatable expression are
* evaluated by a debugger or runtime and their result is rendered in a tooltip-like widget.
*/
export interface EvaluatableExpression {
/**
* The range to which this expression applies.
*/
range: IRange;
expression?: string;
}
/**
* The hover provider interface defines the contract between extensions and
* the [hover](https://code.visualstudio.com/docs/editor/intellisense)-feature.
*/
export interface EvaluatableExpressionProvider {
/**
* Provide a hover for the given position and document. Multiple hovers at the same
* position will be merged by the editor. A hover can have a range which defaults
* to the word range at the position when omitted.
*/
provideEvaluatableExpression(model: editor.ITextModel, position: Position, token: CancellationToken): ProviderResult<EvaluatableExpression>;
}
export enum CompletionItemKind {
Method = 0,
Function = 1,
@@ -5801,18 +5857,30 @@ declare namespace monaco.languages {
}
/**
* The rename provider interface defines the contract between extensions and
* the live-rename feature.
* The linked editing range provider interface defines the contract between extensions and
* the linked editing feature.
*/
export interface OnTypeRenameProvider {
wordPattern?: RegExp;
export interface LinkedEditingRangeProvider {
/**
* Provide a list of ranges that can be live-renamed together.
* Provide a list of ranges that can be edited together.
*/
provideOnTypeRenameRanges(model: editor.ITextModel, position: Position, token: CancellationToken): ProviderResult<{
ranges: IRange[];
wordPattern?: RegExp;
}>;
provideLinkedEditingRanges(model: editor.ITextModel, position: Position, token: CancellationToken): ProviderResult<LinkedEditingRanges>;
}
/**
* Represents a list of ranges that can be edited together along with a word pattern to describe valid contents.
*/
export interface LinkedEditingRanges {
/**
* A list of ranges that can be edited together. The ranges must have
* identical length and text content. The ranges cannot overlap
*/
ranges: IRange[];
/**
* An optional word pattern that describes valid contents for the given ranges.
* If no pattern is provided, the language configuration's word pattern will be used.
*/
wordPattern?: RegExp;
}
/**
@@ -6155,6 +6223,10 @@ declare namespace monaco.languages {
* A provider of folding ranges for editor models.
*/
export interface FoldingRangeProvider {
/**
* An optional event to signal that the folding ranges from this provider have changed.
*/
onDidChange?: IEvent<this>;
/**
* Provides the folding ranges for a specific model.
*/
@@ -6206,12 +6278,6 @@ declare namespace monaco.languages {
needsConfirmation: boolean;
label: string;
description?: string;
iconPath?: {
id: string;
} | Uri | {
light: Uri;
dark: Uri;
};
}
export interface WorkspaceFileEditOptions {
@@ -6219,6 +6285,10 @@ declare namespace monaco.languages {
ignoreIfNotExists?: boolean;
ignoreIfExists?: boolean;
recursive?: boolean;
copy?: boolean;
folder?: boolean;
skipTrashBin?: boolean;
maxSize?: number;
}
export interface WorkspaceFileEdit {