mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 18:46:40 -05:00
Merge VS Code 1.26.1 (#2394)
* Squash merge commits for 1.26 (#1) (#2323) * Polish tag search as per feedback (#55269) * Polish tag search as per feedback * Updated regex * Allow users to opt-out of features that send online requests in the background (#55097) * settings sweep #54690 * Minor css tweaks to enable eoverflow elipsis in more places (#55277) * fix an issue with titlebarheight when not scaling with zoom * Settings descriptions update #54690 * fixes #55209 * Settings editor - many padding fixes * More space above level 2 label * Fixing Cannot debug npm script using Yarn #55103 * Settings editor - show ellipsis when description overflows * Settings editor - ... fix measuring around links, relayout * Setting descriptions * Settings editor - fix ... for some short lines, fix select container width * Settings editor - overlay trees so scrollable shadow is full width * Fix #54133 - missing extension settings after reload * Settings color token description tweak * Settings editor - disable overflow indicator temporarily, needs to be faster * Added command to Run the selected npm script * fixes #54452 * fixes #54929 * fixes #55248 * prefix command with extension name * Contribute run selected to the context menu * node-debug@1.26.6 * Allow terminal rendererType to be swapped out at runtime Part of #53274 Fixes #55344 * Settings editor - fix not focusing search when restoring editor setInput must be actually async. Will be fixed naturally when we aren't using winJS promises... * Settings editor - TOC should only expand the section with a selected item * Bump node-debug2 * Settings editor - Tree focus outlines * Settings editor - don't blink the scrollbar when toc selection changes And hide TOC correctly when the editor is narrow * Settings editor - header rows should not be selectable * fixes #54877 * change debug assignee to isi * Settings sweep (#54690) * workaround for #55051 * Settings sweep (#54690) * settings sweep #54690 * Don't try closing tags when you type > after another > * Describe what implementation code lens does Fixes #55370 * fix javadoc formatter setting description * fixes #55325 * update to officical TS version * Settings editor - Even more padding, use semibold instead of bold * Fix #55357 - fix TOC twistie * fixes #55288 * explorer: refresh on di change file system provider registration fixes #53256 * Disable push to Linux repo to test standalone publisher * New env var to notify log level to extensions #54001 * Disable snippets in extension search (when not in suggest dropdown) (#55281) * Disable snippits in extension search (when not in suggest dropdown) * Add monaco input contributions * Fix bug preventing snippetSuggestions from taking effect in sub-editors * Latest emmet helper to fix #52366 * Fix comment updates for threads within same file * Allow extensions to log telemetry to log files #54001 * Pull latest css grammar * files.exclude control - use same style for "add" vs "edit" * files.exclude control - focus/keyboard behavior * don't show menubar too early * files.exclude - better styling * Place cursor at end of extensions search box on autofill (#55254) * Place cursor at end of extensions search box on autofill * Use position instead of selection * fix linux build issue (empty if block) * Settings editor - fix extension category prefixes * Settings editor - add simple ellipsis for first line that overflows, doesn't cover case when first line does not overflow but there is more text, TODO * File/Text search provider docs * Fixes #52655 * Include epoch (#55008) * Fixes #53385 * Fixes #49480 * VS Code Insiders (Users) not opening Fixes #55353 * Better handling of the case when the extension host fails to start * Fixes #53966 * Remove confusing Start from wordPartLeft commands ID * vscode-xterm@3.6.0-beta12 Fixes #55488 * Initial size is set to infinity!! Fixes #55461 * Polish embeddedEditorBackground * configuration service misses event * Fix #55224 - fix duplicate results in multiroot workspace from splitting the diskseach query * Select all not working in issue reporter on mac, fixes #55424 * Disable fuzzy matching for extensions autosuggest (#55498) * Fix clipping of extensions search border in some third party themes (#55504) * fixes #55538 * Fix bug causing an aria alert to not be shown the third time (and odd numbers thereafter) * Settings editor - work around rendering glitch with webkit-line-clamp * Settings editor - revert earlier '...' changes * Settings editor - move enumDescription to its own div, because it disturbs -webkit-line-clamp for some reason * Settings editor - better overflow indicator * Don't show existing filters in autocomplete (#55495) * Dont show existing filters in autocomplete * Simplify * Settings Editor: Add aria labels for input elements Fixes: #54836 (#55543) * fixes #55223 * Update vscode-css-languageservice to 3.0.10-next.1 * Fix #55509 - settings navigation * Fix #55519 * Fix #55520 * FIx #55524 * Fix #55556 - include wordSeparators in all search queries, so findTextInFiles can respect isWordMatch correctly * oss updates for endgame * Fix unit tests * fixes #55522 * Avoid missing manifest error from bubbling up #54757 * Settings format crawl * Search provider - Fix FileSearchProvider to return array, not progress * Fix #55598 * Settings editor - fix NPE rendering settings with no description * dont render inden guides in search box (#55600) * fixes #55454 * More settings crawl * Another change for #55598 - maxResults applies to FileSearch and TextSearch but not FileIndex * Fix FileSearchProvider unit tests for progress change * fixes #55561 * Settings description update for #54690 * Update setting descriptions for online services * Minor edits * fixes #55513 * fixes #55451 * Fix #55612 - fix findTextInFiles cancellation * fixes #55539 * More setting description tweaks * Setting to disable online experiments #54354 * fixes #55507 * fixes #55515 * Show online services action only in Insiders for now * Settings editor - change toc behavior default to 'filter' * Settings editor - nicer filter count style during search * Fix #55617 - search viewlet icons * Settings editor - better styling for element count indicator * SearchProvider - fix NPE when searching extraFileResources * Allow extends to work without json suffix Fixes #16905 * Remove accessability options logic entirely Follow up on #55451 * use latest version of DAP * fixes #55490 * fixes #55122 * fixes #52332 * Avoid assumptions about git: URIs (fixes #36236) * relative path for descriptions * resourece: get rid of isFile context key fixes #48275 * Register previous ids for compatibility (#53497) * more tuning for #48275 * no need to always re-read "files explorer" fixes #52003 * read out active composites properly fixes #51967 * Update link colors for hc theme to meet color contrast ratio, fixes #55651 Also updated link color for `textLinkActiveForeground` to be the same as `textLinkForeground` as it wasn't properly updated * detect 'winpty-agent.exe'; fixes #55672 * node-debug@1.26.7 * reset counter on new label * Settings editor - fix multiple setting links in one description * Settings editor - color code blocks in setting descriptions, fix #55532 * Settings editor - hover color in TOC * Settings editor - fix navigation NPE * Settings editor - fix text control width * Settings editor - maybe fix #55684 * Fix bug causing cursor to not move on paste * fixes #53582 * Use ctrlCmd instead of ctrl for go down from search box * fixes #55264 * fixes #55456 * filter for spcaes before triggering search (#55611) * Fix #55698 - don't lose filtered TOC counts when refreshing TOC * fixes #55421 * fixes #28979 * fixes #55576 * only add check for updates to windows/linux help * readonly files: append decoration to label fixes #53022 * debug: do not show toolbar while initialising fixes #55026 * Opening launch.json should not activate debug extensions fixes #55029 * fixes #55435 * fixes #55434 * fixes #55439 * trigger menu only on altkey up * Fix #50555 - fix settings editor memory leak * Fix #55712 - no need to focus 'a' anymore when restoring control focus after tree render * fixes #55335 * proper fix for readonly model fixes #53022 * improve FoldingRangeKind spec (for #55686) * Use class with static fields (fixes #55494) * Fixes #53671 * fixes #54630 * [html] should disable ionic suggestions by default. Currently forces deprecated Ionic v1 suggestions in .html files while typing. Fixes #53324 * cleanup deps * debug issues back to andre * update electron for smoketest * Fix #55757 - prevent settings tabs from overflowing * Fix #53897 - revert setting menu defaults to old editor * Add enum descriptions to `typescript.preferences.importModuleSpecifier` * Fix #55767 - leaking style elements from settings editor * Fix #55521 - prevent flashing when clicking in exclude control * Update Git modified color for contrast ratio, fixes #53140 * Revert "Merge branch 'master' of github.com:Microsoft/vscode" This reverts commit bf46b6bfbae0cab99c2863e1244a916181fa9fbc, reversing changes made to e275a424483dfb4ed33b428c97d5e2c441d6b917. * Revert "Revert "Merge branch 'master' of github.com:Microsoft/vscode"" This reverts commit 53949d963f39e40757557c6526332354a31d9154. * don't ask to install an incomplete menu * Fix NPE in terminal AccessibilityManager Fixes #55744 * don't display fallback menu unless we've closed the last window * fixes #55547 * Fix smoke tests for extension search box * Update OSSREADME.json for Electron 2.0.5 * Update distro Includes Chromium license changes * fix #55455 * fix #55865 * fixes #55893 * Fix bug causing workspace recommendations to go away upon ignoring a recommendation (#55805) * Fix bug causing workspace recommendations to go away upon ignoring a recommendation * ONly show on @recommended or @recommended:workspace * Make more consistant * Fix #55911 * Understand json activity (#55926) * Understand json file activity * Refactoring * adding composer.json * Distro update for experiments * use terminal.processId for auto-attach; fixes #55918 * Reject invalid URI with vscode.openFolder (for #55891) * improve win32 setup system vs user detection fixes #55840 fixes #55840 delay winreg import related to #55840 show notification earlier related to #55840 fix #55840 update inno setup message related to #55840 * Fix #55593 - this code only operates on local paths, so use fsPath and Uri.file instead * Bring back the old menu due to electron 2.0 issues (#55913) * add the old menu back for native menus * make menu labels match * `vscode.openFolder`: treat missing URI schema gracefully (for #55891) * delay EH reattach; fixes #55955 * Mark all json files under appSettingsHome as settings * Use localized strings for telemetry opt-out * Exception when saving file editor opened from remote file provider (fixes #55051) * Remove terminal menu from stable Fixes 56003 * VSCode Insiders crashes on open with TypeError: Cannot read property 'lastIndexOf' of undefined. Fixes #54933 * improve fix for #55891 * fix #55916 * Improve #55891 * increase EH debugging restart delay; fixes #55955 * Revert "Don't include non-resource entries in history quick pick" This reverts commit 37209a838e9f7e9abe6dc53ed73cdf1e03b72060. * Diff editor: horizontal scrollbar height is smaller (fixes #56062) * improve openFolder uri fix (correctly treat backslashes) * fixes #56116 repair ipc for native menubar keybindings * Fix #56240 - Open the JSON settings editor instead of the UI editor * Fix #55536 * uriDisplay: if no formatter is registered fall back to getPathlabel fixes #56104 * VSCode hangs when opening python file. Fixes #56377 * VS Code Hangs When Opening Specific PowerShell File. Fixes #56430 * Fix #56433 - search extraFileResources even when no folders open * Workaround #55649 * Fix in master #56371 * Fix tests #56371 * Fix in master #56317 * increase version to 1.26.1 * Fixes #56387: Handle SIGPIPE in extension host * fixes #56185 * Fix merge issues (part 1) * Fix build breaks (part 1) * Build breaks (part 2) * Build breaks (part 3) * More build breaks (part 4) * Fix build breaks (part 5) * WIP * Fix menus * Render query result and message panels (#2363) * Put back query editor hot exit changes * Fix grid changes that broke profiler (#2365) * Update APIs for saving query editor state * Fix restore view state for profiler and edit data * Updating custom default themes to support 4.5:1 contrast ratio * Test updates * Fix Extension Manager and Windows Setup * Update license headers * Add appveyor and travis files back * Fix hidden modal dropdown issue
This commit is contained in:
360
src/vs/monaco.d.ts
vendored
360
src/vs/monaco.d.ts
vendored
@@ -32,6 +32,10 @@ declare namespace monaco {
|
||||
Error = 3,
|
||||
}
|
||||
|
||||
export enum MarkerTag {
|
||||
Unnecessary = 1,
|
||||
}
|
||||
|
||||
export enum MarkerSeverity {
|
||||
Hint = 1,
|
||||
Info = 2,
|
||||
@@ -79,7 +83,6 @@ declare namespace monaco {
|
||||
|
||||
public static join<T1, T2>(promises: [T1 | PromiseLike<T1>, T2 | PromiseLike<T2>]): Promise<[T1, T2]>;
|
||||
public static join<T>(promises: (T | PromiseLike<T>)[]): Promise<T[]>;
|
||||
public static join<T>(promises: { [n: string]: T | PromiseLike<T> }): Promise<{ [n: string]: T }>;
|
||||
|
||||
public static any<T>(promises: (T | PromiseLike<T>)[]): Promise<{ key: string; value: Promise<T>; }>;
|
||||
|
||||
@@ -360,7 +363,7 @@ declare namespace monaco {
|
||||
* Placed last to cover the length of the enum.
|
||||
* Please do not depend on this value!
|
||||
*/
|
||||
MAX_VALUE = 112,
|
||||
MAX_VALUE = 112
|
||||
}
|
||||
|
||||
export class KeyMod {
|
||||
@@ -627,6 +630,10 @@ declare namespace monaco {
|
||||
* Test if the two ranges are touching in any way.
|
||||
*/
|
||||
static areIntersectingOrTouching(a: IRange, b: IRange): boolean;
|
||||
/**
|
||||
* Test if the two ranges are intersecting. If the ranges are touching it returns true.
|
||||
*/
|
||||
static areIntersecting(a: IRange, b: IRange): boolean;
|
||||
/**
|
||||
* A function that compares ranges, useful for sorting ranges
|
||||
* It will first compare ranges on the startPosition and then on the endPosition
|
||||
@@ -753,7 +760,7 @@ declare namespace monaco {
|
||||
/**
|
||||
* The selection starts below where it ends.
|
||||
*/
|
||||
RTL = 1,
|
||||
RTL = 1
|
||||
}
|
||||
|
||||
export class Token {
|
||||
@@ -814,7 +821,7 @@ declare namespace monaco.editor {
|
||||
/**
|
||||
* Change the language for a model.
|
||||
*/
|
||||
export function setModelLanguage(model: ITextModel, language: string): void;
|
||||
export function setModelLanguage(model: ITextModel, languageId: string): void;
|
||||
|
||||
/**
|
||||
* Set the markers for a model.
|
||||
@@ -890,7 +897,7 @@ declare namespace monaco.editor {
|
||||
export function tokenize(text: string, languageId: string): Token[][];
|
||||
|
||||
/**
|
||||
* Define a new theme.
|
||||
* Define a new theme or updte an existing theme.
|
||||
*/
|
||||
export function defineTheme(themeName: string, themeData: IStandaloneThemeData): void;
|
||||
|
||||
@@ -905,6 +912,7 @@ declare namespace monaco.editor {
|
||||
base: BuiltinTheme;
|
||||
inherit: boolean;
|
||||
rules: ITokenThemeRule[];
|
||||
encodedTokensColors?: string[];
|
||||
colors: IColors;
|
||||
}
|
||||
|
||||
@@ -1085,6 +1093,7 @@ declare namespace monaco.editor {
|
||||
endLineNumber: number;
|
||||
endColumn: number;
|
||||
relatedInformation?: IRelatedInformation[];
|
||||
tags?: MarkerTag[];
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1100,6 +1109,7 @@ declare namespace monaco.editor {
|
||||
endLineNumber: number;
|
||||
endColumn: number;
|
||||
relatedInformation?: IRelatedInformation[];
|
||||
tags?: MarkerTag[];
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1126,7 +1136,7 @@ declare namespace monaco.editor {
|
||||
export enum ScrollbarVisibility {
|
||||
Auto = 1,
|
||||
Hidden = 2,
|
||||
Visible = 3,
|
||||
Visible = 3
|
||||
}
|
||||
|
||||
export interface ThemeColor {
|
||||
@@ -1140,7 +1150,7 @@ declare namespace monaco.editor {
|
||||
Left = 1,
|
||||
Center = 2,
|
||||
Right = 4,
|
||||
Full = 7,
|
||||
Full = 7
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1303,7 +1313,7 @@ declare namespace monaco.editor {
|
||||
/**
|
||||
* Use carriage return and line feed (\r\n) as the end of line character.
|
||||
*/
|
||||
CRLF = 2,
|
||||
CRLF = 2
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1317,7 +1327,7 @@ declare namespace monaco.editor {
|
||||
/**
|
||||
* Use carriage return and line feed (\r\n) as the end of line character.
|
||||
*/
|
||||
CRLF = 2,
|
||||
CRLF = 2
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1331,7 +1341,7 @@ declare namespace monaco.editor {
|
||||
/**
|
||||
* Use carriage return and line feed (\r\n) as the end of line character.
|
||||
*/
|
||||
CRLF = 1,
|
||||
CRLF = 1
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1425,7 +1435,7 @@ declare namespace monaco.editor {
|
||||
AlwaysGrowsWhenTypingAtEdges = 0,
|
||||
NeverGrowsWhenTypingAtEdges = 1,
|
||||
GrowsOnlyWhenTypingBefore = 2,
|
||||
GrowsOnlyWhenTypingAfter = 3,
|
||||
GrowsOnlyWhenTypingAfter = 3
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1505,10 +1515,6 @@ declare namespace monaco.editor {
|
||||
* @return EOL char sequence (e.g.: '\n' or '\r\n').
|
||||
*/
|
||||
getEOL(): string;
|
||||
/**
|
||||
* Change the end of line sequence used in the text buffer.
|
||||
*/
|
||||
setEOL(eol: EndOfLineSequence): void;
|
||||
/**
|
||||
* Get the minimum legal column for line at `lineNumber`
|
||||
*/
|
||||
@@ -1744,6 +1750,11 @@ declare namespace monaco.editor {
|
||||
* @return The cursor state returned by the `cursorStateComputer`.
|
||||
*/
|
||||
pushEditOperations(beforeCursorState: Selection[], editOperations: IIdentifiedSingleEditOperation[], cursorStateComputer: ICursorStateComputer): Selection[];
|
||||
/**
|
||||
* Change the end of line sequence. This is the preferred way of
|
||||
* changing the eol sequence. This will land on the undo stack.
|
||||
*/
|
||||
pushEOL(eol: EndOfLineSequence): void;
|
||||
/**
|
||||
* Edit the model without adding the edits to the undo stack.
|
||||
* This can have dire consequences on the undo stack! See @pushEditOperations for the preferred way.
|
||||
@@ -1751,6 +1762,11 @@ declare namespace monaco.editor {
|
||||
* @return The inverse edit operations, that, when applied, will bring the model back to the previous state.
|
||||
*/
|
||||
applyEdits(operations: IIdentifiedSingleEditOperation[]): IIdentifiedSingleEditOperation[];
|
||||
/**
|
||||
* Change the end of line sequence without recording in the undo stack.
|
||||
* This can have dire consequences on the undo stack! See @pushEOL for the preferred way.
|
||||
*/
|
||||
setEOL(eol: EndOfLineSequence): void;
|
||||
/**
|
||||
* An event emitted when the contents of the model have changed.
|
||||
* @event
|
||||
@@ -1975,7 +1991,7 @@ declare namespace monaco.editor {
|
||||
|
||||
export const enum ScrollType {
|
||||
Smooth = 0,
|
||||
Immediate = 1,
|
||||
Immediate = 1
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -2014,9 +2030,9 @@ declare namespace monaco.editor {
|
||||
*/
|
||||
focus(): void;
|
||||
/**
|
||||
* Returns true if this editor has keyboard focus (e.g. cursor is blinking).
|
||||
* Returns true if the text inside this editor is focused (i.e. cursor is blinking).
|
||||
*/
|
||||
isFocused(): boolean;
|
||||
hasTextFocus(): boolean;
|
||||
/**
|
||||
* Returns all actions associated with this editor.
|
||||
*/
|
||||
@@ -2305,7 +2321,7 @@ declare namespace monaco.editor {
|
||||
/**
|
||||
* There was a Redo.
|
||||
*/
|
||||
Redo = 6,
|
||||
Redo = 6
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -2471,6 +2487,38 @@ declare namespace monaco.editor {
|
||||
enabled?: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* Configuration options for editor hover
|
||||
*/
|
||||
export interface IEditorHoverOptions {
|
||||
/**
|
||||
* Enable the hover.
|
||||
* Defaults to true.
|
||||
*/
|
||||
enabled?: boolean;
|
||||
/**
|
||||
* Delay for showing the hover.
|
||||
* Defaults to 300.
|
||||
*/
|
||||
delay?: number;
|
||||
/**
|
||||
* Is the hover sticky such that it can be clicked and its contents selected?
|
||||
* Defaults to true.
|
||||
*/
|
||||
sticky?: boolean;
|
||||
}
|
||||
|
||||
export interface ISuggestOptions {
|
||||
/**
|
||||
* Enable graceful matching. Defaults to true.
|
||||
*/
|
||||
filterGraceful?: boolean;
|
||||
/**
|
||||
* Prevent quick suggestions when a snippet is active. Defaults to true.
|
||||
*/
|
||||
snippetsPreventQuickSuggestions?: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* Configuration map for codeActionsOnSave
|
||||
*/
|
||||
@@ -2623,6 +2671,11 @@ declare namespace monaco.editor {
|
||||
* Defaults to true.
|
||||
*/
|
||||
scrollBeyondLastLine?: boolean;
|
||||
/**
|
||||
* Enable that scrolling can go beyond the last column by a number of columns.
|
||||
* Defaults to 5.
|
||||
*/
|
||||
scrollBeyondLastColumn?: number;
|
||||
/**
|
||||
* Enable that the editor animates scrolling to a position.
|
||||
* Defaults to false.
|
||||
@@ -2658,7 +2711,7 @@ declare namespace monaco.editor {
|
||||
*/
|
||||
wordWrapMinified?: boolean;
|
||||
/**
|
||||
* Control indentation of wrapped lines. Can be: 'none', 'same' or 'indent'.
|
||||
* Control indentation of wrapped lines. Can be: 'none', 'same', 'indent' or 'deepIndent'.
|
||||
* Defaults to 'same' in vscode and to 'none' in monaco-editor.
|
||||
*/
|
||||
wrappingIndent?: string;
|
||||
@@ -2684,10 +2737,9 @@ declare namespace monaco.editor {
|
||||
*/
|
||||
stopRenderingLineAfter?: number;
|
||||
/**
|
||||
* Enable hover.
|
||||
* Defaults to true.
|
||||
* Configure the editor's hover.
|
||||
*/
|
||||
hover?: boolean;
|
||||
hover?: IEditorHoverOptions;
|
||||
/**
|
||||
* Enable detecting links and making them clickable.
|
||||
* Defaults to true.
|
||||
@@ -2722,6 +2774,10 @@ declare namespace monaco.editor {
|
||||
* Defaults to 'auto'. It is best to leave this to 'auto'.
|
||||
*/
|
||||
accessibilitySupport?: 'auto' | 'off' | 'on';
|
||||
/**
|
||||
* Suggest options.
|
||||
*/
|
||||
suggest?: ISuggestOptions;
|
||||
/**
|
||||
* Enable quick suggestions (shadow suggestions)
|
||||
* Defaults to true.
|
||||
@@ -2870,9 +2926,14 @@ declare namespace monaco.editor {
|
||||
renderControlCharacters?: boolean;
|
||||
/**
|
||||
* Enable rendering of indent guides.
|
||||
* Defaults to false.
|
||||
* Defaults to true.
|
||||
*/
|
||||
renderIndentGuides?: boolean;
|
||||
/**
|
||||
* Enable highlighting of the active indent guide.
|
||||
* Defaults to true.
|
||||
*/
|
||||
highlightActiveIndentGuide?: boolean;
|
||||
/**
|
||||
* Enable rendering of current line highlight.
|
||||
* Defaults to all.
|
||||
@@ -2902,6 +2963,10 @@ declare namespace monaco.editor {
|
||||
* The letter spacing
|
||||
*/
|
||||
letterSpacing?: number;
|
||||
/**
|
||||
* Controls fading out of unused variables.
|
||||
*/
|
||||
showUnused?: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -2940,7 +3005,7 @@ declare namespace monaco.editor {
|
||||
Small = 1,
|
||||
Large = 2,
|
||||
SmallBlocks = 3,
|
||||
LargeBlocks = 4,
|
||||
LargeBlocks = 4
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -2956,9 +3021,13 @@ declare namespace monaco.editor {
|
||||
*/
|
||||
Same = 1,
|
||||
/**
|
||||
* Indent => wrapped lines get +1 indentation as the parent.
|
||||
* Indent => wrapped lines get +1 indentation toward the parent.
|
||||
*/
|
||||
Indent = 2,
|
||||
/**
|
||||
* DeepIndent => wrapped lines get +2 indentation toward the parent.
|
||||
*/
|
||||
DeepIndent = 3
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -2988,7 +3057,7 @@ declare namespace monaco.editor {
|
||||
/**
|
||||
* No-Blinking
|
||||
*/
|
||||
Solid = 5,
|
||||
Solid = 5
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -3018,7 +3087,7 @@ declare namespace monaco.editor {
|
||||
/**
|
||||
* As a thin horizontal line (sitting under a character).
|
||||
*/
|
||||
UnderlineThin = 6,
|
||||
UnderlineThin = 6
|
||||
}
|
||||
|
||||
export interface InternalEditorScrollbarOptions {
|
||||
@@ -3049,6 +3118,18 @@ declare namespace monaco.editor {
|
||||
readonly autoFindInSelection: boolean;
|
||||
}
|
||||
|
||||
export interface InternalEditorHoverOptions {
|
||||
readonly enabled: boolean;
|
||||
readonly delay: number;
|
||||
readonly sticky: boolean;
|
||||
}
|
||||
|
||||
export interface InternalSuggestOptions {
|
||||
readonly filterGraceful: boolean;
|
||||
readonly snippets: 'top' | 'bottom' | 'inline' | 'none';
|
||||
readonly snippetsPreventQuickSuggestions: boolean;
|
||||
}
|
||||
|
||||
export interface EditorWrappingInfo {
|
||||
readonly inDiffEditor: boolean;
|
||||
readonly isDominatedByLongLines: boolean;
|
||||
@@ -3066,7 +3147,7 @@ declare namespace monaco.editor {
|
||||
On = 1,
|
||||
Relative = 2,
|
||||
Interval = 3,
|
||||
Custom = 4,
|
||||
Custom = 4
|
||||
}
|
||||
|
||||
export interface InternalEditorViewOptions {
|
||||
@@ -3088,12 +3169,14 @@ declare namespace monaco.editor {
|
||||
readonly cursorWidth: number;
|
||||
readonly hideCursorInOverviewRuler: boolean;
|
||||
readonly scrollBeyondLastLine: boolean;
|
||||
readonly scrollBeyondLastColumn: number;
|
||||
readonly smoothScrolling: boolean;
|
||||
readonly stopRenderingLineAfter: number;
|
||||
readonly renderWhitespace: 'none' | 'boundary' | 'all';
|
||||
readonly renderControlCharacters: boolean;
|
||||
readonly fontLigatures: boolean;
|
||||
readonly renderIndentGuides: boolean;
|
||||
readonly highlightActiveIndentGuide: boolean;
|
||||
readonly renderLineHighlight: 'none' | 'gutter' | 'line' | 'all';
|
||||
readonly scrollbar: InternalEditorScrollbarOptions;
|
||||
readonly minimap: InternalEditorMinimapOptions;
|
||||
@@ -3102,7 +3185,7 @@ declare namespace monaco.editor {
|
||||
|
||||
export interface EditorContribOptions {
|
||||
readonly selectionClipboard: boolean;
|
||||
readonly hover: boolean;
|
||||
readonly hover: InternalEditorHoverOptions;
|
||||
readonly links: boolean;
|
||||
readonly contextmenu: boolean;
|
||||
readonly quickSuggestions: boolean | {
|
||||
@@ -3118,11 +3201,11 @@ declare namespace monaco.editor {
|
||||
readonly suggestOnTriggerCharacters: boolean;
|
||||
readonly acceptSuggestionOnEnter: 'on' | 'smart' | 'off';
|
||||
readonly acceptSuggestionOnCommitCharacter: boolean;
|
||||
readonly snippetSuggestions: 'top' | 'bottom' | 'inline' | 'none';
|
||||
readonly wordBasedSuggestions: boolean;
|
||||
readonly suggestSelection: 'first' | 'recentlyUsed' | 'recentlyUsedByPrefix';
|
||||
readonly suggestFontSize: number;
|
||||
readonly suggestLineHeight: number;
|
||||
readonly suggest: InternalSuggestOptions;
|
||||
readonly selectionHighlight: boolean;
|
||||
readonly occurrencesHighlight: boolean;
|
||||
readonly codeLens: boolean;
|
||||
@@ -3149,6 +3232,7 @@ declare namespace monaco.editor {
|
||||
readonly readOnly: boolean;
|
||||
readonly multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey';
|
||||
readonly multiCursorMergeOverlapping: boolean;
|
||||
readonly showUnused: boolean;
|
||||
readonly wordSeparators: string;
|
||||
readonly autoClosingBrackets: boolean;
|
||||
readonly autoIndent: boolean;
|
||||
@@ -3334,6 +3418,11 @@ declare namespace monaco.editor {
|
||||
* If neither `heightInPx` nor `heightInLines` is specified, a default of `heightInLines` = 1 will be chosen.
|
||||
*/
|
||||
heightInPx?: number;
|
||||
/**
|
||||
* The minimum width in px of the view zone.
|
||||
* If this is set, the editor will ensure that the scroll width is >= than this value.
|
||||
*/
|
||||
minWidthInPx?: number;
|
||||
/**
|
||||
* The dom node of the view zone
|
||||
*/
|
||||
@@ -3389,7 +3478,7 @@ declare namespace monaco.editor {
|
||||
/**
|
||||
* Place the content widget below a position
|
||||
*/
|
||||
BELOW = 2,
|
||||
BELOW = 2
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -3446,7 +3535,7 @@ declare namespace monaco.editor {
|
||||
/**
|
||||
* Position the overlay widget in the top center
|
||||
*/
|
||||
TOP_CENTER = 2,
|
||||
TOP_CENTER = 2
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -3537,7 +3626,7 @@ declare namespace monaco.editor {
|
||||
/**
|
||||
* Mouse is outside of the editor.
|
||||
*/
|
||||
OUTSIDE_EDITOR = 13,
|
||||
OUTSIDE_EDITOR = 13
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -3628,12 +3717,12 @@ declare namespace monaco.editor {
|
||||
*/
|
||||
onDidChangeModelDecorations(listener: (e: IModelDecorationsChangedEvent) => void): IDisposable;
|
||||
/**
|
||||
* An event emitted when the text inside this editor gained focus (i.e. cursor blinking).
|
||||
* An event emitted when the text inside this editor gained focus (i.e. cursor starts blinking).
|
||||
* @event
|
||||
*/
|
||||
onDidFocusEditorText(listener: () => void): IDisposable;
|
||||
/**
|
||||
* An event emitted when the text inside this editor lost focus.
|
||||
* An event emitted when the text inside this editor lost focus (i.e. cursor stops blinking).
|
||||
* @event
|
||||
*/
|
||||
onDidBlurEditorText(listener: () => void): IDisposable;
|
||||
@@ -3641,12 +3730,12 @@ declare namespace monaco.editor {
|
||||
* An event emitted when the text inside this editor or an editor widget gained focus.
|
||||
* @event
|
||||
*/
|
||||
onDidFocusEditor(listener: () => void): IDisposable;
|
||||
onDidFocusEditorWidget(listener: () => void): IDisposable;
|
||||
/**
|
||||
* An event emitted when the text inside this editor or an editor widget lost focus.
|
||||
* @event
|
||||
*/
|
||||
onDidBlurEditor(listener: () => void): IDisposable;
|
||||
onDidBlurEditorWidget(listener: () => void): IDisposable;
|
||||
/**
|
||||
* An event emitted on a "mouseup".
|
||||
* @event
|
||||
@@ -3701,7 +3790,7 @@ declare namespace monaco.editor {
|
||||
*/
|
||||
restoreViewState(state: ICodeEditorViewState): void;
|
||||
/**
|
||||
* Returns true if this editor or one of its widgets has keyboard focus.
|
||||
* Returns true if the text inside this editor or an editor widget has focus.
|
||||
*/
|
||||
hasWidgetFocus(): boolean;
|
||||
/**
|
||||
@@ -3781,9 +3870,9 @@ declare namespace monaco.editor {
|
||||
* The edits will land on the undo-redo stack, but no "undo stop" will be pushed.
|
||||
* @param source The source of the call.
|
||||
* @param edits The edits to execute.
|
||||
* @param endCursoState Cursor state after the edits were applied.
|
||||
* @param endCursorState Cursor state after the edits were applied.
|
||||
*/
|
||||
executeEdits(source: string, edits: IIdentifiedSingleEditOperation[], endCursoState?: Selection[]): boolean;
|
||||
executeEdits(source: string, edits: IIdentifiedSingleEditOperation[], endCursorState?: Selection[]): boolean;
|
||||
/**
|
||||
* Execute multiple (concommitent) commands on the editor.
|
||||
* @param source The source of the call.
|
||||
@@ -3978,6 +4067,8 @@ declare namespace monaco.languages {
|
||||
*/
|
||||
export function getLanguages(): ILanguageExtensionPoint[];
|
||||
|
||||
export function getEncodedLanguageId(languageId: string): number;
|
||||
|
||||
/**
|
||||
* An event emitted when a language is first time needed (e.g. a model has it set).
|
||||
* @event
|
||||
@@ -4012,6 +4103,38 @@ declare namespace monaco.languages {
|
||||
endState: IState;
|
||||
}
|
||||
|
||||
/**
|
||||
* The result of a line tokenization.
|
||||
*/
|
||||
export interface IEncodedLineTokens {
|
||||
/**
|
||||
* The tokens on the line in a binary, encoded format. Each token occupies two array indices. For token i:
|
||||
* - at offset 2*i => startIndex
|
||||
* - at offset 2*i + 1 => metadata
|
||||
* Meta data is in binary format:
|
||||
* - -------------------------------------------
|
||||
* 3322 2222 2222 1111 1111 1100 0000 0000
|
||||
* 1098 7654 3210 9876 5432 1098 7654 3210
|
||||
* - -------------------------------------------
|
||||
* bbbb bbbb bfff ffff ffFF FTTT LLLL LLLL
|
||||
* - -------------------------------------------
|
||||
* - L = EncodedLanguageId (8 bits): Use `getEncodedLanguageId` to get the encoded ID of a language.
|
||||
* - T = StandardTokenType (3 bits): Other = 0, Comment = 1, String = 2, RegEx = 4.
|
||||
* - F = FontStyle (3 bits): None = 0, Italic = 1, Bold = 2, Underline = 4.
|
||||
* - f = foreground ColorId (9 bits)
|
||||
* - b = background ColorId (9 bits)
|
||||
* - The color value for each colorId is defined in IStandaloneThemeData.customTokenColors:
|
||||
* e.g colorId = 1 is stored in IStandaloneThemeData.customTokenColors[1]. Color id = 0 means no color,
|
||||
* id = 1 is for the default foreground color, id = 2 for the default background.
|
||||
*/
|
||||
tokens: Uint32Array;
|
||||
/**
|
||||
* The tokenization end state.
|
||||
* A pointer will be held to this and the object should not be modified by the tokenizer after the pointer is returned.
|
||||
*/
|
||||
endState: IState;
|
||||
}
|
||||
|
||||
/**
|
||||
* A "manual" provider of tokens.
|
||||
*/
|
||||
@@ -4026,10 +4149,24 @@ declare namespace monaco.languages {
|
||||
tokenize(line: string, state: IState): ILineTokens;
|
||||
}
|
||||
|
||||
/**
|
||||
* A "manual" provider of tokens, returning tokens in a binary form.
|
||||
*/
|
||||
export interface EncodedTokensProvider {
|
||||
/**
|
||||
* The initial state of a language. Will be the state passed in to tokenize the first line.
|
||||
*/
|
||||
getInitialState(): IState;
|
||||
/**
|
||||
* Tokenize a line given the state at the beginning of the line.
|
||||
*/
|
||||
tokenizeEncoded(line: string, state: IState): IEncodedLineTokens;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the tokens provider for a language (manual implementation).
|
||||
*/
|
||||
export function setTokensProvider(languageId: string, provider: TokensProvider): IDisposable;
|
||||
export function setTokensProvider(languageId: string, provider: TokensProvider | EncodedTokensProvider): IDisposable;
|
||||
|
||||
/**
|
||||
* Set the tokens provider for a language (monarch implementation).
|
||||
@@ -4176,7 +4313,7 @@ declare namespace monaco.languages {
|
||||
Color = 15,
|
||||
File = 16,
|
||||
Reference = 17,
|
||||
Folder = 18,
|
||||
Folder = 18
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -4526,7 +4663,7 @@ declare namespace monaco.languages {
|
||||
/**
|
||||
* Insert new line and outdent once (relative to the previous line's indentation).
|
||||
*/
|
||||
Outdent = 3,
|
||||
Outdent = 3
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -4597,7 +4734,7 @@ declare namespace monaco.languages {
|
||||
export enum SuggestTriggerKind {
|
||||
Invoke = 0,
|
||||
TriggerCharacter = 1,
|
||||
TriggerForIncompleteCompletions = 2,
|
||||
TriggerForIncompleteCompletions = 2
|
||||
}
|
||||
|
||||
export interface CodeAction {
|
||||
@@ -4694,7 +4831,7 @@ declare namespace monaco.languages {
|
||||
/**
|
||||
* Write-access of a symbol, like writing to a variable.
|
||||
*/
|
||||
Write = 2,
|
||||
Write = 2
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -4769,6 +4906,13 @@ declare namespace monaco.languages {
|
||||
*/
|
||||
export type Definition = Location | Location[];
|
||||
|
||||
export interface DefinitionLink {
|
||||
origin?: IRange;
|
||||
uri: Uri;
|
||||
range: IRange;
|
||||
selectionRange?: IRange;
|
||||
}
|
||||
|
||||
/**
|
||||
* The definition provider interface defines the contract between extensions and
|
||||
* the [go to definition](https://code.visualstudio.com/docs/editor/editingevolved#_go-to-definition)
|
||||
@@ -4778,7 +4922,7 @@ declare namespace monaco.languages {
|
||||
/**
|
||||
* Provide the definition of the symbol at the given position and document.
|
||||
*/
|
||||
provideDefinition(model: editor.ITextModel, position: Position, token: CancellationToken): Definition | Thenable<Definition>;
|
||||
provideDefinition(model: editor.ITextModel, position: Position, token: CancellationToken): Definition | DefinitionLink[] | Thenable<Definition | DefinitionLink[]>;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -4789,7 +4933,7 @@ declare namespace monaco.languages {
|
||||
/**
|
||||
* Provide the implementation of the symbol at the given position and document.
|
||||
*/
|
||||
provideImplementation(model: editor.ITextModel, position: Position, token: CancellationToken): Definition | Thenable<Definition>;
|
||||
provideImplementation(model: editor.ITextModel, position: Position, token: CancellationToken): Definition | DefinitionLink[] | Thenable<Definition | DefinitionLink[]>;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -4800,7 +4944,7 @@ declare namespace monaco.languages {
|
||||
/**
|
||||
* Provide the type definition of the symbol at the given position and document.
|
||||
*/
|
||||
provideTypeDefinition(model: editor.ITextModel, position: Position, token: CancellationToken): Definition | Thenable<Definition>;
|
||||
provideTypeDefinition(model: editor.ITextModel, position: Position, token: CancellationToken): Definition | DefinitionLink[] | Thenable<Definition | DefinitionLink[]>;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -4832,30 +4976,17 @@ declare namespace monaco.languages {
|
||||
Struct = 22,
|
||||
Event = 23,
|
||||
Operator = 24,
|
||||
TypeParameter = 25,
|
||||
TypeParameter = 25
|
||||
}
|
||||
|
||||
/**
|
||||
* Represents information about programming constructs like variables, classes,
|
||||
* interfaces etc.
|
||||
*/
|
||||
export interface SymbolInformation {
|
||||
/**
|
||||
* The name of this symbol.
|
||||
*/
|
||||
export interface DocumentSymbol {
|
||||
name: string;
|
||||
/**
|
||||
* The name of the symbol containing this symbol.
|
||||
*/
|
||||
containerName?: string;
|
||||
/**
|
||||
* The kind of this symbol.
|
||||
*/
|
||||
detail: string;
|
||||
kind: SymbolKind;
|
||||
/**
|
||||
* The location of this symbol.
|
||||
*/
|
||||
location: Location;
|
||||
containerName?: string;
|
||||
range: IRange;
|
||||
selectionRange: IRange;
|
||||
children?: DocumentSymbol[];
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -4863,10 +4994,11 @@ declare namespace monaco.languages {
|
||||
* the [go to symbol](https://code.visualstudio.com/docs/editor/editingevolved#_goto-symbol)-feature.
|
||||
*/
|
||||
export interface DocumentSymbolProvider {
|
||||
displayName?: string;
|
||||
/**
|
||||
* Provide symbol information for the given document.
|
||||
*/
|
||||
provideDocumentSymbols(model: editor.ITextModel, token: CancellationToken): SymbolInformation[] | Thenable<SymbolInformation[]>;
|
||||
provideDocumentSymbols(model: editor.ITextModel, token: CancellationToken): DocumentSymbol[] | Thenable<DocumentSymbol[]>;
|
||||
}
|
||||
|
||||
export interface TextEdit {
|
||||
@@ -5076,6 +5208,12 @@ declare namespace monaco.languages {
|
||||
export interface ResourceFileEdit {
|
||||
oldUri: Uri;
|
||||
newUri: Uri;
|
||||
options: {
|
||||
overwrite?: boolean;
|
||||
ignoreIfNotExists?: boolean;
|
||||
ignoreIfExists?: boolean;
|
||||
recursive?: boolean;
|
||||
};
|
||||
}
|
||||
|
||||
export interface ResourceTextEdit {
|
||||
@@ -5106,6 +5244,76 @@ declare namespace monaco.languages {
|
||||
arguments?: any[];
|
||||
}
|
||||
|
||||
export interface CommentInfo {
|
||||
owner: number;
|
||||
threads: CommentThread[];
|
||||
commentingRanges?: IRange[];
|
||||
reply?: Command;
|
||||
}
|
||||
|
||||
export enum CommentThreadCollapsibleState {
|
||||
/**
|
||||
* Determines an item is collapsed
|
||||
*/
|
||||
Collapsed = 0,
|
||||
/**
|
||||
* Determines an item is expanded
|
||||
*/
|
||||
Expanded = 1
|
||||
}
|
||||
|
||||
export interface CommentThread {
|
||||
threadId: string;
|
||||
resource: string;
|
||||
range: IRange;
|
||||
comments: Comment[];
|
||||
collapsibleState?: CommentThreadCollapsibleState;
|
||||
reply?: Command;
|
||||
}
|
||||
|
||||
export interface NewCommentAction {
|
||||
ranges: IRange[];
|
||||
actions: Command[];
|
||||
}
|
||||
|
||||
export interface Comment {
|
||||
readonly commentId: string;
|
||||
readonly body: IMarkdownString;
|
||||
readonly userName: string;
|
||||
readonly gravatar: string;
|
||||
readonly command?: Command;
|
||||
}
|
||||
|
||||
export interface CommentThreadChangedEvent {
|
||||
readonly owner: number;
|
||||
/**
|
||||
* Added comment threads.
|
||||
*/
|
||||
readonly added: CommentThread[];
|
||||
/**
|
||||
* Removed comment threads.
|
||||
*/
|
||||
readonly removed: CommentThread[];
|
||||
/**
|
||||
* Changed comment threads.
|
||||
*/
|
||||
readonly changed: CommentThread[];
|
||||
}
|
||||
|
||||
export interface DocumentCommentProvider {
|
||||
provideDocumentComments(resource: Uri, token: CancellationToken): Promise<CommentInfo>;
|
||||
createNewCommentThread(resource: Uri, range: Range, text: string, token: CancellationToken): Promise<CommentThread>;
|
||||
replyToCommentThread(resource: Uri, range: Range, thread: CommentThread, text: string, token: CancellationToken): Promise<CommentThread>;
|
||||
onDidChangeCommentThreads(): IEvent<CommentThreadChangedEvent>;
|
||||
}
|
||||
|
||||
export interface WorkspaceCommentProvider {
|
||||
provideWorkspaceComments(token: CancellationToken): Promise<CommentThread[]>;
|
||||
createNewCommentThread(resource: Uri, range: Range, text: string, token: CancellationToken): Promise<CommentThread>;
|
||||
replyToCommentThread(resource: Uri, range: Range, thread: CommentThread, text: string, token: CancellationToken): Promise<CommentThread>;
|
||||
onDidChangeCommentThreads(): IEvent<CommentThreadChangedEvent>;
|
||||
}
|
||||
|
||||
export interface ICodeLensSymbol {
|
||||
range: IRange;
|
||||
id?: string;
|
||||
@@ -5126,7 +5334,7 @@ declare namespace monaco.languages {
|
||||
firstLine?: string;
|
||||
aliases?: string[];
|
||||
mimetypes?: string[];
|
||||
configuration?: string;
|
||||
configuration?: Uri;
|
||||
}
|
||||
/**
|
||||
* A Monarch language definition
|
||||
@@ -5157,15 +5365,19 @@ declare namespace monaco.languages {
|
||||
/**
|
||||
* attach this to every token class (by default '.' + name)
|
||||
*/
|
||||
tokenPostfix: string;
|
||||
tokenPostfix?: string;
|
||||
}
|
||||
|
||||
export type IShortMonarchLanguageRule1 = [RegExp, string | IMonarchLanguageAction];
|
||||
|
||||
export type IShortMonarchLanguageRule2 = [RegExp, string | IMonarchLanguageAction, string];
|
||||
|
||||
/**
|
||||
* A rule is either a regular expression and an action
|
||||
* shorthands: [reg,act] == { regex: reg, action: act}
|
||||
* and : [reg,act,nxt] == { regex: reg, action: act{ next: nxt }}
|
||||
*/
|
||||
export interface IMonarchLanguageRule {
|
||||
export interface IExpandedMonarchLanguageRule {
|
||||
/**
|
||||
* match tokens
|
||||
*/
|
||||
@@ -5180,6 +5392,8 @@ declare namespace monaco.languages {
|
||||
include?: string;
|
||||
}
|
||||
|
||||
export type IMonarchLanguageRule = IShortMonarchLanguageRule1 | IShortMonarchLanguageRule2 | IExpandedMonarchLanguageRule;
|
||||
|
||||
/**
|
||||
* An action is either an array of actions...
|
||||
* ... or a case statement with guards...
|
||||
|
||||
Reference in New Issue
Block a user