Updates monaco to 0.28.0

pull/2674/head
Henning Dieterichs 3 years ago
parent fd784d74f6
commit 6f93540f34
No known key found for this signature in database
GPG Key ID: 771381EFFDB9EC06

36
package-lock.json generated

@ -2362,39 +2362,39 @@
}
},
"monaco-css": {
"version": "3.7.0",
"resolved": "https://registry.npmjs.org/monaco-css/-/monaco-css-3.7.0.tgz",
"integrity": "sha512-a4n6cNu1duCWF/d9pVoASp9qllK2Ca/Qwc5xF3nRwgVHmvxJxhRfemsWdFFei217K0odVE2737TumKQl8yW5Yg==",
"version": "3.8.1",
"resolved": "https://registry.npmjs.org/monaco-css/-/monaco-css-3.8.1.tgz",
"integrity": "sha512-biXG+Y7RVWY8QAXnteMafIIrqFxAvcmCsa87tWAHcNRZauY+3VjNbllBxklPAkK0T+YrZDMuq1YAAE8wKreYiA==",
"dev": true
},
"monaco-editor-core": {
"version": "0.27.0",
"resolved": "https://registry.npmjs.org/monaco-editor-core/-/monaco-editor-core-0.27.0.tgz",
"integrity": "sha512-x7I0QiIwwvxt1lzYSoQjf1xGjtEPobFx3Zvrj+tWbJbJFsXUy11IJ6TEIZ2yRjEFzuy+vrlbcfASC6lcGg/xhw==",
"version": "0.28.1",
"resolved": "https://registry.npmjs.org/monaco-editor-core/-/monaco-editor-core-0.28.1.tgz",
"integrity": "sha512-ikNy6KXmgKhV66W7xLkdECJLAAzDycUe6rhXbdmUaa6L23X70Y0jOaCj/W9gqAo4wUT3MpRmeKEgujNKKH9p8A==",
"dev": true
},
"monaco-html": {
"version": "3.7.0",
"resolved": "https://registry.npmjs.org/monaco-html/-/monaco-html-3.7.0.tgz",
"integrity": "sha512-G52mN9cmf9habyi1khw9fmMvwD2d2BTx782NLOuwBTXWaxsJeoVdN5PL1fHCEJdwbP//Jt0SWUG9UT+rN4g3Ig==",
"version": "3.8.1",
"resolved": "https://registry.npmjs.org/monaco-html/-/monaco-html-3.8.1.tgz",
"integrity": "sha512-qg5TH6HVJiQctEccsPG3r+tE0BjxcNZv6fFjT4Sr7p1c0fN92SvoDbxrjyqfzIfGsVlr76OfzPShjy1SOCHreA==",
"dev": true
},
"monaco-json": {
"version": "3.7.0",
"resolved": "https://registry.npmjs.org/monaco-json/-/monaco-json-3.7.0.tgz",
"integrity": "sha512-VaEIouXJMYR4Ew//1CjIV2xfvr5xIVMMfUtrxYMM7vEWUuozS60Fn4m+0EWbs4/BsAOJXH7PhU26nniuES9IHQ==",
"version": "3.8.1",
"resolved": "https://registry.npmjs.org/monaco-json/-/monaco-json-3.8.1.tgz",
"integrity": "sha512-Uc8pSW9lljQwOznHIqVOeHaGEEjXK7ltbIjxXhkpi3XW7e/J+Sbt0JWpYjphD2EMb0MKCe2XhM8gBzRPF7lvYA==",
"dev": true
},
"monaco-languages": {
"version": "2.7.0",
"resolved": "https://registry.npmjs.org/monaco-languages/-/monaco-languages-2.7.0.tgz",
"integrity": "sha512-3D96ZEMfdQq5BtDX28JcFMyD6wE1/XsCqniZ7t1Ac9oF2wRdPHMgOya3xkwKiOC1ZEcyFuhtaIYGfndlX77JNg==",
"version": "2.8.1",
"resolved": "https://registry.npmjs.org/monaco-languages/-/monaco-languages-2.8.1.tgz",
"integrity": "sha512-hzUZFhuhUtTicdfhbj1xUQt2aXI/7ef5Ava4NG1Qd1HHSPPG8vFWyeKOlA+QX+EiFkiq21NWXynx4smQ/Qp61A==",
"dev": true
},
"monaco-typescript": {
"version": "4.7.0",
"resolved": "https://registry.npmjs.org/monaco-typescript/-/monaco-typescript-4.7.0.tgz",
"integrity": "sha512-dw30nKjR6abg1IGDit42nlVMad6dzJD0ZkOUgagVZj1Sf6vVvH2s5tdvBUDwIT7rAOgpSoW1Tz9/sanu7qVObw==",
"version": "4.8.1",
"resolved": "https://registry.npmjs.org/monaco-typescript/-/monaco-typescript-4.8.1.tgz",
"integrity": "sha512-H4spoQ8hTctMBd6vH/bBusF61slGCJF6BXsDkvurCcb8c8mrUhv3EiM6L09s4w/F9NJBbJ0xHezy3EvOEukEig==",
"dev": true
},
"ms": {

@ -22,12 +22,12 @@
"clean-css": "^5.1.1",
"event-stream": "4.0.1",
"gulp": "^4.0.2",
"monaco-css": "3.7.0",
"monaco-css": "3.8.1",
"monaco-editor-core": "0.28.1",
"monaco-html": "3.7.0",
"monaco-json": "3.7.0",
"monaco-languages": "2.7.0",
"monaco-typescript": "4.7.0",
"monaco-html": "3.8.1",
"monaco-json": "3.8.1",
"monaco-languages": "2.8.1",
"monaco-typescript": "4.8.1",
"rimraf": "^3.0.2",
"typedoc": "^0.20.29",
"typescript": "4.2.3",

312
typedoc/monaco.d.ts vendored

@ -10,6 +10,10 @@
declare let MonacoEnvironment: monaco.Environment | undefined;
interface Window {
MonacoEnvironment?: monaco.Environment | undefined;
}
declare namespace monaco {
export type Thenable<T> = PromiseLike<T>;
@ -621,7 +625,7 @@ declare namespace monaco {
*/
strictContainsRange(range: IRange): boolean;
/**
* Test if `otherRange` is strinctly in `range` (must start after, and end before). If the ranges are equal, will return false.
* Test if `otherRange` is strictly in `range` (must start after, and end before). If the ranges are equal, will return false.
*/
static strictContainsRange(range: IRange, otherRange: IRange): boolean;
/**
@ -1403,7 +1407,8 @@ declare namespace monaco.editor {
isWholeLine?: boolean;
/**
* Specifies the stack order of a decoration.
* A decoration with greater stack order is always in front of a decoration with a lower stack order.
* A decoration with greater stack order is always in front of a decoration with
* a lower stack order when the decorations are on the same line.
*/
zIndex?: number;
/**
@ -1643,6 +1648,11 @@ declare namespace monaco.editor {
readonly insertSpaces: boolean;
readonly defaultEOL: DefaultEndOfLine;
readonly trimAutoWhitespace: boolean;
readonly bracketPairColorizationOptions: BracketPairColorizationOptions;
}
export interface BracketPairColorizationOptions {
enabled: boolean;
}
export interface ITextModelUpdateOptions {
@ -1650,6 +1660,7 @@ declare namespace monaco.editor {
indentSize?: number;
insertSpaces?: boolean;
trimAutoWhitespace?: boolean;
bracketColorizationOptions?: BracketPairColorizationOptions;
}
export class FindMatch {
@ -2702,7 +2713,7 @@ declare namespace monaco.editor {
/**
* Control the rendering of line numbers.
* If it is a function, it will be invoked when rendering a line number and the return value will be rendered.
* Otherwise, if it is a truey, line numbers will be rendered normally (equivalent of using an identity function).
* Otherwise, if it is a truthy, line numbers will be rendered normally (equivalent of using an identity function).
* Otherwise, line numbers will not be rendered.
* Defaults to `on`.
*/
@ -3335,7 +3346,7 @@ declare namespace monaco.editor {
*/
originalAriaLabel?: string;
/**
* Aria label for modifed editor.
* Aria label for modified editor.
*/
modifiedAriaLabel?: string;
}
@ -3878,6 +3889,15 @@ declare namespace monaco.editor {
export type InternalInlineSuggestOptions = Readonly<Required<IInlineSuggestOptions>>;
export interface IBracketPairColorizationOptions {
/**
* Enable or disable bracket pair colorization.
*/
enabled?: boolean;
}
export type InternalBracketPairColorizationOptions = Readonly<Required<IBracketPairColorizationOptions>>;
/**
* Configuration options for editor suggest widget
*/
@ -4086,125 +4106,126 @@ declare namespace monaco.editor {
autoIndent = 9,
automaticLayout = 10,
autoSurround = 11,
codeLens = 12,
codeLensFontFamily = 13,
codeLensFontSize = 14,
colorDecorators = 15,
columnSelection = 16,
comments = 17,
contextmenu = 18,
copyWithSyntaxHighlighting = 19,
cursorBlinking = 20,
cursorSmoothCaretAnimation = 21,
cursorStyle = 22,
cursorSurroundingLines = 23,
cursorSurroundingLinesStyle = 24,
cursorWidth = 25,
disableLayerHinting = 26,
disableMonospaceOptimizations = 27,
domReadOnly = 28,
dragAndDrop = 29,
emptySelectionClipboard = 30,
extraEditorClassName = 31,
fastScrollSensitivity = 32,
find = 33,
fixedOverflowWidgets = 34,
folding = 35,
foldingStrategy = 36,
foldingHighlight = 37,
foldingImportsByDefault = 38,
unfoldOnClickAfterEndOfLine = 39,
fontFamily = 40,
fontInfo = 41,
fontLigatures = 42,
fontSize = 43,
fontWeight = 44,
formatOnPaste = 45,
formatOnType = 46,
glyphMargin = 47,
gotoLocation = 48,
hideCursorInOverviewRuler = 49,
highlightActiveIndentGuide = 50,
hover = 51,
inDiffEditor = 52,
inlineSuggest = 53,
letterSpacing = 54,
lightbulb = 55,
lineDecorationsWidth = 56,
lineHeight = 57,
lineNumbers = 58,
lineNumbersMinChars = 59,
linkedEditing = 60,
links = 61,
matchBrackets = 62,
minimap = 63,
mouseStyle = 64,
mouseWheelScrollSensitivity = 65,
mouseWheelZoom = 66,
multiCursorMergeOverlapping = 67,
multiCursorModifier = 68,
multiCursorPaste = 69,
occurrencesHighlight = 70,
overviewRulerBorder = 71,
overviewRulerLanes = 72,
padding = 73,
parameterHints = 74,
peekWidgetDefaultFocus = 75,
definitionLinkOpensInPeek = 76,
quickSuggestions = 77,
quickSuggestionsDelay = 78,
readOnly = 79,
renameOnType = 80,
renderControlCharacters = 81,
renderIndentGuides = 82,
renderFinalNewline = 83,
renderLineHighlight = 84,
renderLineHighlightOnlyWhenFocus = 85,
renderValidationDecorations = 86,
renderWhitespace = 87,
revealHorizontalRightPadding = 88,
roundedSelection = 89,
rulers = 90,
scrollbar = 91,
scrollBeyondLastColumn = 92,
scrollBeyondLastLine = 93,
scrollPredominantAxis = 94,
selectionClipboard = 95,
selectionHighlight = 96,
selectOnLineNumbers = 97,
showFoldingControls = 98,
showUnused = 99,
snippetSuggestions = 100,
smartSelect = 101,
smoothScrolling = 102,
stickyTabStops = 103,
stopRenderingLineAfter = 104,
suggest = 105,
suggestFontSize = 106,
suggestLineHeight = 107,
suggestOnTriggerCharacters = 108,
suggestSelection = 109,
tabCompletion = 110,
tabIndex = 111,
unusualLineTerminators = 112,
useShadowDOM = 113,
useTabStops = 114,
wordSeparators = 115,
wordWrap = 116,
wordWrapBreakAfterCharacters = 117,
wordWrapBreakBeforeCharacters = 118,
wordWrapColumn = 119,
wordWrapOverride1 = 120,
wordWrapOverride2 = 121,
wrappingIndent = 122,
wrappingStrategy = 123,
showDeprecated = 124,
inlayHints = 125,
editorClassName = 126,
pixelRatio = 127,
tabFocusMode = 128,
layoutInfo = 129,
wrappingInfo = 130
bracketPairColorization = 12,
codeLens = 13,
codeLensFontFamily = 14,
codeLensFontSize = 15,
colorDecorators = 16,
columnSelection = 17,
comments = 18,
contextmenu = 19,
copyWithSyntaxHighlighting = 20,
cursorBlinking = 21,
cursorSmoothCaretAnimation = 22,
cursorStyle = 23,
cursorSurroundingLines = 24,
cursorSurroundingLinesStyle = 25,
cursorWidth = 26,
disableLayerHinting = 27,
disableMonospaceOptimizations = 28,
domReadOnly = 29,
dragAndDrop = 30,
emptySelectionClipboard = 31,
extraEditorClassName = 32,
fastScrollSensitivity = 33,
find = 34,
fixedOverflowWidgets = 35,
folding = 36,
foldingStrategy = 37,
foldingHighlight = 38,
foldingImportsByDefault = 39,
unfoldOnClickAfterEndOfLine = 40,
fontFamily = 41,
fontInfo = 42,
fontLigatures = 43,
fontSize = 44,
fontWeight = 45,
formatOnPaste = 46,
formatOnType = 47,
glyphMargin = 48,
gotoLocation = 49,
hideCursorInOverviewRuler = 50,
highlightActiveIndentGuide = 51,
hover = 52,
inDiffEditor = 53,
inlineSuggest = 54,
letterSpacing = 55,
lightbulb = 56,
lineDecorationsWidth = 57,
lineHeight = 58,
lineNumbers = 59,
lineNumbersMinChars = 60,
linkedEditing = 61,
links = 62,
matchBrackets = 63,
minimap = 64,
mouseStyle = 65,
mouseWheelScrollSensitivity = 66,
mouseWheelZoom = 67,
multiCursorMergeOverlapping = 68,
multiCursorModifier = 69,
multiCursorPaste = 70,
occurrencesHighlight = 71,
overviewRulerBorder = 72,
overviewRulerLanes = 73,
padding = 74,
parameterHints = 75,
peekWidgetDefaultFocus = 76,
definitionLinkOpensInPeek = 77,
quickSuggestions = 78,
quickSuggestionsDelay = 79,
readOnly = 80,
renameOnType = 81,
renderControlCharacters = 82,
renderIndentGuides = 83,
renderFinalNewline = 84,
renderLineHighlight = 85,
renderLineHighlightOnlyWhenFocus = 86,
renderValidationDecorations = 87,
renderWhitespace = 88,
revealHorizontalRightPadding = 89,
roundedSelection = 90,
rulers = 91,
scrollbar = 92,
scrollBeyondLastColumn = 93,
scrollBeyondLastLine = 94,
scrollPredominantAxis = 95,
selectionClipboard = 96,
selectionHighlight = 97,
selectOnLineNumbers = 98,
showFoldingControls = 99,
showUnused = 100,
snippetSuggestions = 101,
smartSelect = 102,
smoothScrolling = 103,
stickyTabStops = 104,
stopRenderingLineAfter = 105,
suggest = 106,
suggestFontSize = 107,
suggestLineHeight = 108,
suggestOnTriggerCharacters = 109,
suggestSelection = 110,
tabCompletion = 111,
tabIndex = 112,
unusualLineTerminators = 113,
useShadowDOM = 114,
useTabStops = 115,
wordSeparators = 116,
wordWrap = 117,
wordWrapBreakAfterCharacters = 118,
wordWrapBreakBeforeCharacters = 119,
wordWrapColumn = 120,
wordWrapOverride1 = 121,
wordWrapOverride2 = 122,
wrappingIndent = 123,
wrappingStrategy = 124,
showDeprecated = 125,
inlayHints = 126,
editorClassName = 127,
pixelRatio = 128,
tabFocusMode = 129,
layoutInfo = 130,
wrappingInfo = 131
}
export const EditorOptions: {
acceptSuggestionOnCommitCharacter: IEditorOption<EditorOption.acceptSuggestionOnCommitCharacter, boolean>;
@ -4219,6 +4240,7 @@ declare namespace monaco.editor {
autoIndent: IEditorOption<EditorOption.autoIndent, EditorAutoIndentStrategy>;
automaticLayout: IEditorOption<EditorOption.automaticLayout, boolean>;
autoSurround: IEditorOption<EditorOption.autoSurround, 'languageDefined' | 'never' | 'quotes' | 'brackets'>;
bracketPairColorization: IEditorOption<EditorOption.bracketPairColorization, any>;
stickyTabStops: IEditorOption<EditorOption.stickyTabStops, boolean>;
codeLens: IEditorOption<EditorOption.codeLens, boolean>;
codeLensFontFamily: IEditorOption<EditorOption.codeLensFontFamily, string>;
@ -5338,7 +5360,7 @@ declare namespace monaco.languages {
/**
* Register a code action provider (used by e.g. quick fix).
*/
export function registerCodeActionProvider(languageId: string, provider: CodeActionProvider): IDisposable;
export function registerCodeActionProvider(languageId: string, provider: CodeActionProvider, metadata?: CodeActionProviderMetadata): IDisposable;
/**
* Register a formatter that can handle only entire models.
@ -5431,6 +5453,21 @@ declare namespace monaco.languages {
provideCodeActions(model: editor.ITextModel, range: Range, context: CodeActionContext, token: CancellationToken): ProviderResult<CodeActionList>;
}
/**
* Metadata about the type of code actions that a {@link CodeActionProvider} provides.
*/
export interface CodeActionProviderMetadata {
/**
* List of code action kinds that a {@link CodeActionProvider} may return.
*
* This list is used to determine if a given `CodeActionProvider` should be invoked or not.
* To avoid unnecessary computation, every `CodeActionProvider` should list use `providedCodeActionKinds`. The
* list of kinds may either be generic, such as `["quickfix", "refactor", "source"]`, or list out every kind provided,
* such as `["quickfix.removeLine", "source.fixAll" ...]`.
*/
readonly providedCodeActionKinds?: readonly string[];
}
/**
* Describes how comments for a language work.
*/
@ -5486,6 +5523,11 @@ declare namespace monaco.languages {
* settings will be used.
*/
surroundingPairs?: IAutoClosingPair[];
/**
* Defines a list of bracket pairs that are colorized depending on their nesting level.
* If not set, the configured brackets will be used.
*/
colorizedBracketPairs?: CharacterPair[];
/**
* Defines what characters must be after the cursor for bracket or quote autoclosing to occur when using the \'languageDefined\' autoclosing setting.
*
@ -5919,6 +5961,12 @@ declare namespace monaco.languages {
* How the completion was triggered.
*/
readonly triggerKind: InlineCompletionTriggerKind;
readonly selectedSuggestionInfo: SelectedSuggestionInfo | undefined;
}
export interface SelectedSuggestionInfo {
range: IRange;
text: string;
}
export interface InlineCompletion {
@ -6982,6 +7030,15 @@ declare namespace monaco.languages.typescript {
/** A full HTTP path to a JavaScript file which adds a function `customTSWorkerFactory` to the self inside a web-worker */
customWorkerPath?: string;
}
interface InlayHintsOptions {
readonly includeInlayParameterNameHints?: 'none' | 'literals' | 'all';
readonly includeInlayParameterNameHintsWhenArgumentMatchesName?: boolean;
readonly includeInlayFunctionParameterTypeHints?: boolean;
readonly includeInlayVariableTypeHints?: boolean;
readonly includeInlayPropertyDeclarationTypeHints?: boolean;
readonly includeInlayFunctionLikeReturnTypeHints?: boolean;
readonly includeInlayEnumMemberValueHints?: boolean;
}
interface IExtraLib {
content: string;
version: number;
@ -7040,6 +7097,7 @@ declare namespace monaco.languages.typescript {
*/
readonly onDidExtraLibsChange: IEvent<void>;
readonly workerOptions: WorkerOptions;
readonly inlayHintsOptions: InlayHintsOptions;
/**
* Get the current extra libs registered with the language service.
*/
@ -7241,6 +7299,12 @@ declare namespace monaco.languages.typescript {
errorCodes: number[],
formatOptions: any
): Promise<ReadonlyArray<any>>;
/**
* Get inlay hints in the range of the file.
* @param fileName
* @returns `Promise<typescript.InlayHint[]>`
*/
provideInlayHints(fileName: string, start: number, end: number): Promise<ReadonlyArray<any>>;
}
export const typescriptVersion: string;
export const typescriptDefaults: LanguageServiceDefaults;

@ -10,6 +10,10 @@
declare let MonacoEnvironment: monaco.Environment | undefined;
interface Window {
MonacoEnvironment?: monaco.Environment | undefined;
}
declare namespace monaco {
export type Thenable<T> = PromiseLike<T>;
@ -621,7 +625,7 @@ declare namespace monaco {
*/
strictContainsRange(range: IRange): boolean;
/**
* Test if `otherRange` is strinctly in `range` (must start after, and end before). If the ranges are equal, will return false.
* Test if `otherRange` is strictly in `range` (must start after, and end before). If the ranges are equal, will return false.
*/
static strictContainsRange(range: IRange, otherRange: IRange): boolean;
/**
@ -1403,7 +1407,8 @@ declare namespace monaco.editor {
isWholeLine?: boolean;
/**
* Specifies the stack order of a decoration.
* A decoration with greater stack order is always in front of a decoration with a lower stack order.
* A decoration with greater stack order is always in front of a decoration with
* a lower stack order when the decorations are on the same line.
*/
zIndex?: number;
/**
@ -1643,6 +1648,11 @@ declare namespace monaco.editor {
readonly insertSpaces: boolean;
readonly defaultEOL: DefaultEndOfLine;
readonly trimAutoWhitespace: boolean;
readonly bracketPairColorizationOptions: BracketPairColorizationOptions;
}
export interface BracketPairColorizationOptions {
enabled: boolean;
}
export interface ITextModelUpdateOptions {
@ -1650,6 +1660,7 @@ declare namespace monaco.editor {
indentSize?: number;
insertSpaces?: boolean;
trimAutoWhitespace?: boolean;
bracketColorizationOptions?: BracketPairColorizationOptions;
}
export class FindMatch {
@ -2702,7 +2713,7 @@ declare namespace monaco.editor {
/**
* Control the rendering of line numbers.
* If it is a function, it will be invoked when rendering a line number and the return value will be rendered.
* Otherwise, if it is a truey, line numbers will be rendered normally (equivalent of using an identity function).
* Otherwise, if it is a truthy, line numbers will be rendered normally (equivalent of using an identity function).
* Otherwise, line numbers will not be rendered.
* Defaults to `on`.
*/
@ -3335,7 +3346,7 @@ declare namespace monaco.editor {
*/
originalAriaLabel?: string;
/**
* Aria label for modifed editor.
* Aria label for modified editor.
*/
modifiedAriaLabel?: string;
}
@ -3878,6 +3889,15 @@ declare namespace monaco.editor {
export type InternalInlineSuggestOptions = Readonly<Required<IInlineSuggestOptions>>;
export interface IBracketPairColorizationOptions {
/**
* Enable or disable bracket pair colorization.
*/
enabled?: boolean;
}
export type InternalBracketPairColorizationOptions = Readonly<Required<IBracketPairColorizationOptions>>;
/**
* Configuration options for editor suggest widget
*/
@ -4086,125 +4106,126 @@ declare namespace monaco.editor {
autoIndent = 9,
automaticLayout = 10,
autoSurround = 11,
codeLens = 12,
codeLensFontFamily = 13,
codeLensFontSize = 14,
colorDecorators = 15,
columnSelection = 16,
comments = 17,
contextmenu = 18,
copyWithSyntaxHighlighting = 19,
cursorBlinking = 20,
cursorSmoothCaretAnimation = 21,
cursorStyle = 22,
cursorSurroundingLines = 23,
cursorSurroundingLinesStyle = 24,
cursorWidth = 25,
disableLayerHinting = 26,
disableMonospaceOptimizations = 27,
domReadOnly = 28,
dragAndDrop = 29,
emptySelectionClipboard = 30,
extraEditorClassName = 31,
fastScrollSensitivity = 32,
find = 33,
fixedOverflowWidgets = 34,
folding = 35,
foldingStrategy = 36,
foldingHighlight = 37,
foldingImportsByDefault = 38,
unfoldOnClickAfterEndOfLine = 39,
fontFamily = 40,
fontInfo = 41,
fontLigatures = 42,
fontSize = 43,
fontWeight = 44,
formatOnPaste = 45,
formatOnType = 46,
glyphMargin = 47,
gotoLocation = 48,
hideCursorInOverviewRuler = 49,
highlightActiveIndentGuide = 50,
hover = 51,
inDiffEditor = 52,
inlineSuggest = 53,
letterSpacing = 54,
lightbulb = 55,
lineDecorationsWidth = 56,
lineHeight = 57,
lineNumbers = 58,
lineNumbersMinChars = 59,
linkedEditing = 60,
links = 61,
matchBrackets = 62,
minimap = 63,
mouseStyle = 64,
mouseWheelScrollSensitivity = 65,
mouseWheelZoom = 66,
multiCursorMergeOverlapping = 67,
multiCursorModifier = 68,
multiCursorPaste = 69,
occurrencesHighlight = 70,
overviewRulerBorder = 71,
overviewRulerLanes = 72,
padding = 73,
parameterHints = 74,
peekWidgetDefaultFocus = 75,
definitionLinkOpensInPeek = 76,
quickSuggestions = 77,
quickSuggestionsDelay = 78,
readOnly = 79,
renameOnType = 80,
renderControlCharacters = 81,
renderIndentGuides = 82,
renderFinalNewline = 83,
renderLineHighlight = 84,
renderLineHighlightOnlyWhenFocus = 85,
renderValidationDecorations = 86,
renderWhitespace = 87,
revealHorizontalRightPadding = 88,
roundedSelection = 89,
rulers = 90,
scrollbar = 91,
scrollBeyondLastColumn = 92,
scrollBeyondLastLine = 93,
scrollPredominantAxis = 94,
selectionClipboard = 95,
selectionHighlight = 96,
selectOnLineNumbers = 97,
showFoldingControls = 98,
showUnused = 99,
snippetSuggestions = 100,
smartSelect = 101,
smoothScrolling = 102,
stickyTabStops = 103,
stopRenderingLineAfter = 104,
suggest = 105,
suggestFontSize = 106,
suggestLineHeight = 107,
suggestOnTriggerCharacters = 108,
suggestSelection = 109,
tabCompletion = 110,
tabIndex = 111,
unusualLineTerminators = 112,
useShadowDOM = 113,
useTabStops = 114,
wordSeparators = 115,
wordWrap = 116,
wordWrapBreakAfterCharacters = 117,
wordWrapBreakBeforeCharacters = 118,
wordWrapColumn = 119,
wordWrapOverride1 = 120,
wordWrapOverride2 = 121,
wrappingIndent = 122,
wrappingStrategy = 123,
showDeprecated = 124,
inlayHints = 125,
editorClassName = 126,
pixelRatio = 127,
tabFocusMode = 128,
layoutInfo = 129,
wrappingInfo = 130
bracketPairColorization = 12,
codeLens = 13,
codeLensFontFamily = 14,
codeLensFontSize = 15,
colorDecorators = 16,
columnSelection = 17,
comments = 18,
contextmenu = 19,
copyWithSyntaxHighlighting = 20,
cursorBlinking = 21,
cursorSmoothCaretAnimation = 22,
cursorStyle = 23,
cursorSurroundingLines = 24,
cursorSurroundingLinesStyle = 25,
cursorWidth = 26,
disableLayerHinting = 27,
disableMonospaceOptimizations = 28,
domReadOnly = 29,
dragAndDrop = 30,
emptySelectionClipboard = 31,
extraEditorClassName = 32,
fastScrollSensitivity = 33,
find = 34,
fixedOverflowWidgets = 35,
folding = 36,
foldingStrategy = 37,
foldingHighlight = 38,
foldingImportsByDefault = 39,
unfoldOnClickAfterEndOfLine = 40,
fontFamily = 41,
fontInfo = 42,
fontLigatures = 43,
fontSize = 44,
fontWeight = 45,
formatOnPaste = 46,
formatOnType = 47,
glyphMargin = 48,
gotoLocation = 49,
hideCursorInOverviewRuler = 50,
highlightActiveIndentGuide = 51,
hover = 52,
inDiffEditor = 53,
inlineSuggest = 54,
letterSpacing = 55,
lightbulb = 56,
lineDecorationsWidth = 57,
lineHeight = 58,
lineNumbers = 59,
lineNumbersMinChars = 60,
linkedEditing = 61,
links = 62,
matchBrackets = 63,
minimap = 64,
mouseStyle = 65,
mouseWheelScrollSensitivity = 66,
mouseWheelZoom = 67,
multiCursorMergeOverlapping = 68,
multiCursorModifier = 69,
multiCursorPaste = 70,
occurrencesHighlight = 71,
overviewRulerBorder = 72,
overviewRulerLanes = 73,
padding = 74,
parameterHints = 75,
peekWidgetDefaultFocus = 76,
definitionLinkOpensInPeek = 77,
quickSuggestions = 78,
quickSuggestionsDelay = 79,
readOnly = 80,
renameOnType = 81,
renderControlCharacters = 82,
renderIndentGuides = 83,
renderFinalNewline = 84,
renderLineHighlight = 85,
renderLineHighlightOnlyWhenFocus = 86,
renderValidationDecorations = 87,
renderWhitespace = 88,
revealHorizontalRightPadding = 89,
roundedSelection = 90,
rulers = 91,
scrollbar = 92,
scrollBeyondLastColumn = 93,
scrollBeyondLastLine = 94,
scrollPredominantAxis = 95,
selectionClipboard = 96,
selectionHighlight = 97,
selectOnLineNumbers = 98,
showFoldingControls = 99,
showUnused = 100,
snippetSuggestions = 101,
smartSelect = 102,
smoothScrolling = 103,
stickyTabStops = 104,
stopRenderingLineAfter = 105,
suggest = 106,
suggestFontSize = 107,
suggestLineHeight = 108,
suggestOnTriggerCharacters = 109,
suggestSelection = 110,
tabCompletion = 111,
tabIndex = 112,
unusualLineTerminators = 113,
useShadowDOM = 114,
useTabStops = 115,
wordSeparators = 116,
wordWrap = 117,
wordWrapBreakAfterCharacters = 118,
wordWrapBreakBeforeCharacters = 119,
wordWrapColumn = 120,
wordWrapOverride1 = 121,
wordWrapOverride2 = 122,
wrappingIndent = 123,
wrappingStrategy = 124,
showDeprecated = 125,
inlayHints = 126,
editorClassName = 127,
pixelRatio = 128,
tabFocusMode = 129,
layoutInfo = 130,
wrappingInfo = 131
}
export const EditorOptions: {
acceptSuggestionOnCommitCharacter: IEditorOption<EditorOption.acceptSuggestionOnCommitCharacter, boolean>;
@ -4219,6 +4240,7 @@ declare namespace monaco.editor {
autoIndent: IEditorOption<EditorOption.autoIndent, EditorAutoIndentStrategy>;
automaticLayout: IEditorOption<EditorOption.automaticLayout, boolean>;
autoSurround: IEditorOption<EditorOption.autoSurround, 'languageDefined' | 'never' | 'quotes' | 'brackets'>;
bracketPairColorization: IEditorOption<EditorOption.bracketPairColorization, any>;
stickyTabStops: IEditorOption<EditorOption.stickyTabStops, boolean>;
codeLens: IEditorOption<EditorOption.codeLens, boolean>;
codeLensFontFamily: IEditorOption<EditorOption.codeLensFontFamily, string>;
@ -5338,7 +5360,7 @@ declare namespace monaco.languages {
/**
* Register a code action provider (used by e.g. quick fix).
*/
export function registerCodeActionProvider(languageId: string, provider: CodeActionProvider): IDisposable;
export function registerCodeActionProvider(languageId: string, provider: CodeActionProvider, metadata?: CodeActionProviderMetadata): IDisposable;
/**
* Register a formatter that can handle only entire models.
@ -5431,6 +5453,21 @@ declare namespace monaco.languages {
provideCodeActions(model: editor.ITextModel, range: Range, context: CodeActionContext, token: CancellationToken): ProviderResult<CodeActionList>;
}
/**
* Metadata about the type of code actions that a {@link CodeActionProvider} provides.
*/
export interface CodeActionProviderMetadata {
/**
* List of code action kinds that a {@link CodeActionProvider} may return.
*
* This list is used to determine if a given `CodeActionProvider` should be invoked or not.
* To avoid unnecessary computation, every `CodeActionProvider` should list use `providedCodeActionKinds`. The
* list of kinds may either be generic, such as `["quickfix", "refactor", "source"]`, or list out every kind provided,
* such as `["quickfix.removeLine", "source.fixAll" ...]`.
*/
readonly providedCodeActionKinds?: readonly string[];
}
/**
* Describes how comments for a language work.
*/
@ -5486,6 +5523,11 @@ declare namespace monaco.languages {
* settings will be used.
*/
surroundingPairs?: IAutoClosingPair[];
/**
* Defines a list of bracket pairs that are colorized depending on their nesting level.
* If not set, the configured brackets will be used.
*/
colorizedBracketPairs?: CharacterPair[];
/**
* Defines what characters must be after the cursor for bracket or quote autoclosing to occur when using the \'languageDefined\' autoclosing setting.
*
@ -5919,6 +5961,12 @@ declare namespace monaco.languages {
* How the completion was triggered.
*/
readonly triggerKind: InlineCompletionTriggerKind;
readonly selectedSuggestionInfo: SelectedSuggestionInfo | undefined;
}
export interface SelectedSuggestionInfo {
range: IRange;
text: string;
}
export interface InlineCompletion {
@ -6982,6 +7030,15 @@ declare namespace monaco.languages.typescript {
/** A full HTTP path to a JavaScript file which adds a function `customTSWorkerFactory` to the self inside a web-worker */
customWorkerPath?: string;
}
interface InlayHintsOptions {
readonly includeInlayParameterNameHints?: 'none' | 'literals' | 'all';
readonly includeInlayParameterNameHintsWhenArgumentMatchesName?: boolean;
readonly includeInlayFunctionParameterTypeHints?: boolean;
readonly includeInlayVariableTypeHints?: boolean;
readonly includeInlayPropertyDeclarationTypeHints?: boolean;
readonly includeInlayFunctionLikeReturnTypeHints?: boolean;
readonly includeInlayEnumMemberValueHints?: boolean;
}
interface IExtraLib {
content: string;
version: number;
@ -7040,6 +7097,7 @@ declare namespace monaco.languages.typescript {
*/
readonly onDidExtraLibsChange: IEvent<void>;
readonly workerOptions: WorkerOptions;
readonly inlayHintsOptions: InlayHintsOptions;
/**
* Get the current extra libs registered with the language service.
*/
@ -7241,6 +7299,12 @@ declare namespace monaco.languages.typescript {
errorCodes: number[],
formatOptions: any
): Promise<ReadonlyArray<any>>;
/**
* Get inlay hints in the range of the file.
* @param fileName
* @returns `Promise<typescript.InlayHint[]>`
*/
provideInlayHints(fileName: string, start: number, end: number): Promise<ReadonlyArray<any>>;
}
export const typescriptVersion: string;
export const typescriptDefaults: LanguageServiceDefaults;

Loading…
Cancel
Save