From 03fd79e579f0a3ad24508b54488583971c315d90 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Mangeonjean?= Date: Thu, 9 Apr 2020 14:48:35 +0200 Subject: [PATCH 1/7] bump monaco to 0.20.0 and related libaries/types --- client/package.json | 4 +- package.json | 4 +- yarn.lock | 101 +++++++++++++++++--------------------------- 3 files changed, 42 insertions(+), 67 deletions(-) diff --git a/client/package.json b/client/package.json index 35b2b5d16..27e491485 100644 --- a/client/package.json +++ b/client/package.json @@ -18,8 +18,8 @@ "typings": "./lib/index", "dependencies": { "glob-to-regexp": "^0.3.0", - "vscode-jsonrpc": "^5.0.0", - "vscode-languageclient": "^6.0.0", + "vscode-jsonrpc": "^5.0.1", + "vscode-languageclient": "^6.1.3", "vscode-uri": "^2.1.1" }, "scripts": { diff --git a/package.json b/package.json index 7bd952074..d20b1ece9 100644 --- a/package.json +++ b/package.json @@ -5,10 +5,10 @@ "@types/node": "^13.1.7", "@types/normalize-url": "^1.9.1", "@types/ws": "0.0.39", - "@types/vscode": "1.41.0", + "@types/vscode": "1.44.0", "css-loader": "^0.28.11", "lerna": "^3.16.4", - "monaco-editor-core": "^0.19.3", + "monaco-editor-core": "^0.20.0", "rimraf": "^2.6.2", "source-map-loader": "^0.2.3", "style-loader": "^0.20.3", diff --git a/yarn.lock b/yarn.lock index f7165bb48..5e206b337 100644 --- a/yarn.lock +++ b/yarn.lock @@ -904,10 +904,10 @@ "@types/express-serve-static-core" "*" "@types/mime" "*" -"@types/vscode@1.41.0": - version "1.41.0" - resolved "https://registry.yarnpkg.com/@types/vscode/-/vscode-1.41.0.tgz#b0d75920220f84e07093285e59180c0f11d336cd" - integrity sha512-7SfeY5u9jgiELwxyLB3z7l6l/GbN9CqpCQGkcRlB7tKRFBxzbz2PoBfGrLxI1vRfUCIq5+hg5vtDHExwq5j3+A== +"@types/vscode@1.44.0": + version "1.44.0" + resolved "https://registry.yarnpkg.com/@types/vscode/-/vscode-1.44.0.tgz#62ecfe3d0e38942fce556574da54ee1013c775b7" + integrity sha512-WJZtZlinE3meRdH+I7wTsIhpz/GLhqEQwmPGeh4s1irWLwMzCeTV8WZ+pgPTwrDXoafVUWwo1LiZ9HJVHFlJSQ== "@types/ws@0.0.39": version "0.0.39" @@ -3911,15 +3911,10 @@ json5@^1.0.1: dependencies: minimist "^1.2.0" -jsonc-parser@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/jsonc-parser/-/jsonc-parser-2.1.0.tgz#eb0d0c7a3c33048524ce3574c57c7278fb2f1bf3" - integrity sha512-n9GrT8rrr2fhvBbANa1g+xFmgGK5X91KFeDwlKQ3+SJfmH5+tKv/M/kahx/TXOMflfWHKGKqKyfHQaLKTNzJ6w== - -jsonc-parser@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/jsonc-parser/-/jsonc-parser-2.2.0.tgz#f206f87f9d49d644b7502052c04e82dd6392e9ef" - integrity sha512-4fLQxW1j/5fWj6p78vAlAafoCKtuBm6ghv+Ij5W2DrDx0qE+ZdEl2c6Ko1mgJNF5ftX1iEWQQ4Ap7+3GlhjkOA== +jsonc-parser@^2.2.1: + version "2.2.1" + resolved "https://registry.yarnpkg.com/jsonc-parser/-/jsonc-parser-2.2.1.tgz#db73cd59d78cce28723199466b2a03d1be1df2bc" + integrity sha512-o6/yDBYccGvTz1+QFevz6l6OBZ2+fMVu2JZ9CIhzsYRX4mjaK5IyX9eldUdCmga16zlgQxyrj5pt9kzuj2C02w== jsonfile@^4.0.0: version "4.0.0" @@ -4502,6 +4497,11 @@ monaco-editor-core@^0.19.3: resolved "https://registry.yarnpkg.com/monaco-editor-core/-/monaco-editor-core-0.19.3.tgz#6d2b36f42f0f42be6def5604810fafc288c9cc3e" integrity sha512-Fd6bTTaAxDAulh3q9Hordj80DSFZFGhjKX/Z3K/kElA9xkPyNwyaOjphYp8254nhUEKCk56TKP7qfRkUjjZF3w== +monaco-editor-core@^0.20.0: + version "0.20.0" + resolved "https://registry.yarnpkg.com/monaco-editor-core/-/monaco-editor-core-0.20.0.tgz#d5ce01307d298dbca6ab9194812812b32b50433f" + integrity sha512-4mdmfEejTvRZzrEIn70jqqNl3g15vnkRdTkJ8uMK4jiljntlwhiSc5vknZOLt1QM8za16C3tDrSl2mTL9ma2Sg== + move-concurrently@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/move-concurrently/-/move-concurrently-1.0.1.tgz#be2c005fda32e0b29af1f05d7c4b33214c701f92" @@ -7075,24 +7075,14 @@ vm-browserify@^1.0.1: resolved "https://registry.yarnpkg.com/vm-browserify/-/vm-browserify-1.1.0.tgz#bd76d6a23323e2ca8ffa12028dc04559c75f9019" integrity sha512-iq+S7vZJE60yejDYM0ek6zg308+UZsdtPExWP9VZoCFCz1zkJoXFnAX7aZfd/ZwrkidzdUZL0C/ryW+JwAiIGw== -vscode-json-languageservice@^3.3.1: - version "3.3.1" - resolved "https://registry.yarnpkg.com/vscode-json-languageservice/-/vscode-json-languageservice-3.3.1.tgz#4ad2c82db849a7bbe54fcbf5c9b3a2ed26dc8fee" - integrity sha512-Qyvlrftexu1acvwbMt+CDehVrDZtFV1GAJrKdOCHQL9bWNhzI06KEiSd4iXR0NUOuAdroG/uU4wBkH6e5CcTXg== - dependencies: - jsonc-parser "^2.1.0" - vscode-languageserver-types "^3.15.0-next.2" - vscode-nls "^4.1.1" - vscode-uri "^2.0.3" - -vscode-json-languageservice@^3.4.11: - version "3.4.11" - resolved "https://registry.yarnpkg.com/vscode-json-languageservice/-/vscode-json-languageservice-3.4.11.tgz#7c0632bccc4b2b955f99f99f43d96d3eece1de42" - integrity sha512-26Qv1SFp6x3XmCqU1BRceRsSKRO3xkQa6/K8ziSRt52/LQPiw5ipSxlGVSlzIoi5LCmQVEqUajhiVEMNlFXhNw== +vscode-json-languageservice@^3.3.1, vscode-json-languageservice@^3.4.11: + version "3.5.2" + resolved "https://registry.yarnpkg.com/vscode-json-languageservice/-/vscode-json-languageservice-3.5.2.tgz#4b898140a8e581359c10660845a4cae15dcbb4f9" + integrity sha512-9cUvBq00O08lpWVVOx6tQ1yLxCHss79nsUdEAVYGomRyMbnPBmc0AkYPcXI9WK1EM6HBo0R9Zo3NjFhcICpy4A== dependencies: - jsonc-parser "^2.2.0" - vscode-languageserver-textdocument "^1.0.0-next.5" - vscode-languageserver-types "^3.15.0-next.9" + jsonc-parser "^2.2.1" + vscode-languageserver-textdocument "^1.0.1" + vscode-languageserver-types "^3.15.1" vscode-nls "^4.1.1" vscode-uri "^2.1.1" @@ -7101,59 +7091,44 @@ vscode-jsonrpc@^5.0.0, vscode-jsonrpc@^5.0.1: resolved "https://registry.yarnpkg.com/vscode-jsonrpc/-/vscode-jsonrpc-5.0.1.tgz#9bab9c330d89f43fc8c1e8702b5c36e058a01794" integrity sha512-JvONPptw3GAQGXlVV2utDcHx0BiY34FupW/kI6mZ5x06ER5DdPG/tXWMVHjTNULF5uKPOUUD0SaXg5QaubJL0A== -vscode-languageclient@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/vscode-languageclient/-/vscode-languageclient-6.0.0.tgz#777a90ca399c4a4d942b3012c0ad2ec47409c4e5" - integrity sha512-6MDksAP79GRbcHFsXS6ndo12s0m/h7eNdS/IanRgWxaezqB4a4KzHIHrE0bE+nSFB+snaSToGs1bxnPeKdO5fQ== +vscode-languageclient@^6.1.3: + version "6.1.3" + resolved "https://registry.yarnpkg.com/vscode-languageclient/-/vscode-languageclient-6.1.3.tgz#c979c5bb5855714a0307e998c18ca827c1b3953a" + integrity sha512-YciJxk08iU5LmWu7j5dUt9/1OLjokKET6rME3cI4BRpiF6HZlusm2ZwPt0MYJ0lV5y43sZsQHhyon2xBg4ZJVA== dependencies: semver "^6.3.0" - vscode-languageserver-protocol "^3.15.0" + vscode-languageserver-protocol "^3.15.3" -vscode-languageserver-protocol@^3.15.0: - version "3.15.2" - resolved "https://registry.yarnpkg.com/vscode-languageserver-protocol/-/vscode-languageserver-protocol-3.15.2.tgz#e52c62923140b2655ad2472f6f29cfb83bacf5b8" - integrity sha512-GdL05JKOgZ76RDg3suiGCl9enESM7iQgGw4x93ibTh4sldvZmakHmTeZ4iUApPPGKf6O3OVBtrsksBXnHYaxNg== +vscode-languageserver-protocol@^3.15.3: + version "3.15.3" + resolved "https://registry.yarnpkg.com/vscode-languageserver-protocol/-/vscode-languageserver-protocol-3.15.3.tgz#3fa9a0702d742cf7883cb6182a6212fcd0a1d8bb" + integrity sha512-zrMuwHOAQRhjDSnflWdJG+O2ztMWss8GqUUB8dXLR/FPenwkiBNkMIJJYfSN6sgskvsF0rHAoBowNQfbyZnnvw== dependencies: vscode-jsonrpc "^5.0.1" vscode-languageserver-types "3.15.1" -vscode-languageserver-textdocument@^1.0.0-next.5: - version "1.0.0" - resolved "https://registry.yarnpkg.com/vscode-languageserver-textdocument/-/vscode-languageserver-textdocument-1.0.0.tgz#957381672eb3f507aa320e9f6d7efdfcb767d9fe" - integrity sha512-9E3hfoknSe9wX5Bed4rFbjkWdT9Oazw+suyCQ6ZbS68r3SAwue5M7xHd9WX9jBHguAai+qmwr5dMIf7gmzQryw== +vscode-languageserver-textdocument@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/vscode-languageserver-textdocument/-/vscode-languageserver-textdocument-1.0.1.tgz#178168e87efad6171b372add1dea34f53e5d330f" + integrity sha512-UIcJDjX7IFkck7cSkNNyzIz5FyvpQfY7sdzVy+wkKN/BLaD4DQ0ppXQrKePomCxTS7RrolK1I0pey0bG9eh8dA== -vscode-languageserver-types@3.15.1: +vscode-languageserver-types@3.15.1, vscode-languageserver-types@^3.15.0-next, vscode-languageserver-types@^3.15.1: version "3.15.1" resolved "https://registry.yarnpkg.com/vscode-languageserver-types/-/vscode-languageserver-types-3.15.1.tgz#17be71d78d2f6236d414f0001ce1ef4d23e6b6de" integrity sha512-+a9MPUQrNGRrGU630OGbYVQ+11iOIovjCkqxajPa9w57Sd5ruK8WQNsslzpa0x/QJqC8kRc2DUxWjIFwoNm4ZQ== -vscode-languageserver-types@^3.15.0-next, vscode-languageserver-types@^3.15.0-next.2: - version "3.15.0-next.2" - resolved "https://registry.yarnpkg.com/vscode-languageserver-types/-/vscode-languageserver-types-3.15.0-next.2.tgz#a0601332cdaafac21931f497bb080cfb8d73f254" - integrity sha512-2JkrMWWUi2rlVLSo9OFR2PIGUzdiowEM8NgNYiwLKnXTjpwpjjIrJbNNxDik7Rv4oo9KtikcFQZKXbrKilL/MQ== - -vscode-languageserver-types@^3.15.0-next.9: - version "3.15.0" - resolved "https://registry.yarnpkg.com/vscode-languageserver-types/-/vscode-languageserver-types-3.15.0.tgz#c45a23308ec0967135c483b759dfaf97978d9e0a" - integrity sha512-AXteNagMhBWnZ6gNN0UB4HTiD/7TajgfHl6jaM6O7qz3zDJw0H3Jf83w05phihnBRCML+K6Ockh8f8bL0OObPw== - vscode-languageserver@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/vscode-languageserver/-/vscode-languageserver-6.0.0.tgz#4b6fa593422a68bab3c5e92f1d50af3a7cb770f8" - integrity sha512-QihKytod/PApM+wU9qmjxjGT+p4vYDJCbMcdwol55QeE80DCMyls6yxJzTn8SNCNpP4JZin8SIZp1zpumfktQg== + version "6.1.1" + resolved "https://registry.yarnpkg.com/vscode-languageserver/-/vscode-languageserver-6.1.1.tgz#d76afc68172c27d4327ee74332b468fbc740d762" + integrity sha512-DueEpkUAkD5XTR4MLYNr6bQIp/UFR0/IPApgXU3YfCBCB08u2sm9hRCs6DxYZELkk++STPjpcjksR2H8qI3cDQ== dependencies: - vscode-languageserver-protocol "^3.15.0" + vscode-languageserver-protocol "^3.15.3" vscode-nls@^4.0.0, vscode-nls@^4.1.1: version "4.1.1" resolved "https://registry.yarnpkg.com/vscode-nls/-/vscode-nls-4.1.1.tgz#f9916b64e4947b20322defb1e676a495861f133c" integrity sha512-4R+2UoUUU/LdnMnFjePxfLqNhBS8lrAFyX7pjb2ud/lqDkrUavFUTcG7wR0HBZFakae0Q6KLBFjMS6W93F403A== -vscode-uri@^2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/vscode-uri/-/vscode-uri-2.0.3.tgz#25e5f37f552fbee3cec7e5f80cef8469cefc6543" - integrity sha512-4D3DI3F4uRy09WNtDGD93H9q034OHImxiIcSq664Hq1Y1AScehlP3qqZyTkX/RWxeu0MRMHGkrxYqm2qlDF/aw== - vscode-uri@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/vscode-uri/-/vscode-uri-2.1.1.tgz#5aa1803391b6ebdd17d047f51365cf62c38f6e90" From ab1b3edb6c1974e9f38c592aead334de965900ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Mangeonjean?= Date: Thu, 9 Apr 2020 14:49:55 +0200 Subject: [PATCH 2/7] fix errors, use new types --- client/src/monaco-converter.ts | 24 ++++++++++++------------ client/src/monaco-workspace.ts | 13 +++++-------- client/src/vscode-api.ts | 19 +++++++++++++++---- 3 files changed, 32 insertions(+), 24 deletions(-) diff --git a/client/src/monaco-converter.ts b/client/src/monaco-converter.ts index 0ae456171..e7e7ceaec 100644 --- a/client/src/monaco-converter.ts +++ b/client/src/monaco-converter.ts @@ -202,7 +202,7 @@ export class MonacoToProtocolConverter { } asCompletionItem(item: monaco.languages.CompletionItem): CompletionItem { - const result: CompletionItem = { label: item.label }; + const result: CompletionItem = { label: item.label as string }; const protocolItem = ProtocolCompletionItem.is(item) ? item : undefined; if (item.detail) { result.detail = item.detail; } // We only send items back we created. So this can't be something else than @@ -360,7 +360,7 @@ export class MonacoToProtocolConverter { asDiagnostic(marker: monaco.editor.IMarkerData): Diagnostic { const range = this.asRange(new monaco.Range(marker.startLineNumber, marker.startColumn, marker.endLineNumber, marker.endColumn)) const severity = this.asDiagnosticSeverity(marker.severity); - return Diagnostic.create(range, marker.message, severity, marker.code, marker.source); + return Diagnostic.create(range, marker.message, severity, marker.code as string, marker.source); } asDiagnostics(markers: monaco.editor.IMarkerData[]): Diagnostic[] { @@ -457,12 +457,12 @@ export class MonacoToProtocolConverter { export class ProtocolToMonacoConverter { - asResourceEdits(resource: monaco.Uri, edits: TextEdit[], modelVersionId?: number): monaco.languages.ResourceTextEdit { - return { + asResourceEdits(resource: monaco.Uri, edits: TextEdit[], modelVersionId?: number): monaco.languages.WorkspaceTextEdit[] { + return edits.map(edit => ({ resource: resource, - edits: this.asTextEdits(edits), + edit: this.asTextEdit(edit), modelVersionId - } + })) } asWorkspaceEdit(item: WorkspaceEdit): monaco.languages.WorkspaceEdit; @@ -472,29 +472,29 @@ export class ProtocolToMonacoConverter { if (!item) { return undefined; } - const edits: (monaco.languages.ResourceTextEdit | monaco.languages.ResourceFileEdit)[] = []; + const edits: (monaco.languages.WorkspaceTextEdit | monaco.languages.WorkspaceFileEdit)[] = []; if (item.documentChanges) { item.documentChanges.forEach(change => { if (ls.CreateFile.is(change)) { - edits.push({ + edits.push({ newUri: monaco.Uri.parse(change.uri), options: change.options }); } else if (ls.RenameFile.is(change)) { - edits.push({ + edits.push({ oldUri: monaco.Uri.parse(change.oldUri), newUri: monaco.Uri.parse(change.newUri), options: change.options }); } else if (ls.DeleteFile.is(change)) { - edits.push({ + edits.push({ oldUri: monaco.Uri.parse(change.uri), options: change.options }); } else if (ls.TextDocumentEdit.is(change)) { const resource = monaco.Uri.parse(change.textDocument.uri); const version = typeof change.textDocument.version === 'number' ? change.textDocument.version : undefined; - edits.push(this.asResourceEdits(resource, change.edits, version)); + edits.push(...this.asResourceEdits(resource, change.edits, version)); } else { console.error(`Unknown workspace edit change received:\n${JSON.stringify(change, undefined, 4)}`); } @@ -502,7 +502,7 @@ export class ProtocolToMonacoConverter { } else if (item.changes) { for (const key of Object.keys(item.changes)) { const resource = monaco.Uri.parse(key); - edits.push(this.asResourceEdits(resource, item.changes[key])); + edits.push(...this.asResourceEdits(resource, item.changes[key])); } } return { diff --git a/client/src/monaco-workspace.ts b/client/src/monaco-workspace.ts index 1588f0ca3..02876b062 100644 --- a/client/src/monaco-workspace.ts +++ b/client/src/monaco-workspace.ts @@ -90,7 +90,7 @@ export class MonacoWorkspace implements Workspace { // Collect all referenced models const models: { [uri: string]: monaco.editor.IModel } = edit.edits ? edit.edits.reduce( (acc: { [uri: string]: monaco.editor.IModel }, currentEdit) => { - const textEdit = currentEdit as monaco.languages.ResourceTextEdit; + const textEdit = currentEdit as monaco.languages.WorkspaceTextEdit; acc[textEdit.resource.toString()] = monaco.editor.getModel(textEdit.resource) as monaco.editor.ITextModel; return acc; }, {} @@ -104,18 +104,15 @@ export class MonacoWorkspace implements Workspace { // Group edits by resource so we can batch them when applying const editsByResource: { [uri: string]: IIdentifiedSingleEditOperation[] } = edit.edits ? edit.edits.reduce( (acc: { [uri: string]: IIdentifiedSingleEditOperation[] }, currentEdit) => { - const textEdit = currentEdit as monaco.languages.ResourceTextEdit; + const textEdit = currentEdit as monaco.languages.WorkspaceTextEdit; const uri = textEdit.resource.toString(); if (!(uri in acc)) { acc[uri] = []; } - const operations = textEdit.edits.map(edit => { - return { - range: monaco.Range.lift(edit.range as monaco.IRange), - text: edit.text as string, - } + acc[uri].push({ + range: monaco.Range.lift(textEdit.edit.range as monaco.IRange), + text: textEdit.edit.text as string, }); - acc[uri].push(...operations); return acc; }, {} ) : {}; diff --git a/client/src/vscode-api.ts b/client/src/vscode-api.ts index bc416bc09..3956a0f57 100644 --- a/client/src/vscode-api.ts +++ b/client/src/vscode-api.ts @@ -7,7 +7,7 @@ import * as vscode from "vscode"; import { URI } from "vscode-uri" import { Disposable } from "./disposable"; import { - Services, Event, DiagnosticCollection, WorkspaceEdit, isDocumentSelector, + Services, Event, DiagnosticCollection, Diagnostic, WorkspaceEdit, isDocumentSelector, MessageType, OutputChannel, CompletionTriggerKind, DocumentIdentifier, SignatureHelpTriggerKind } from "./services"; @@ -300,13 +300,20 @@ export function createVSCodeApi(servicesProvider: Services.Provider): typeof vsc // */ } + function toInternalCode(code: vscode.Diagnostic['code']): Diagnostic['code'] { + if (code != null && typeof code === 'object') { + return code.value as Diagnostic['code'] + } + return code as Diagnostic['code']; + } + if (isVsCodeUri(arg0)) { if (this.collection) { if (arg1) { this.collection.set(arg0.toString(), arg1.map(diag => { return { range: diag.range, - code: diag.code, + code: toInternalCode(diag.code), source: diag.source, message: diag.message, tags: diag.tags, @@ -688,7 +695,10 @@ export function createVSCodeApi(servicesProvider: Services.Provider): typeof vsc setTextDocumentLanguage: unsupported, getDiagnostics: unsupported, setLanguageConfiguration: unsupported, - onDidChangeDiagnostics: unsupported + onDidChangeDiagnostics: unsupported, + registerEvaluatableExpressionProvider: unsupported, + registerDocumentSemanticTokensProvider: unsupported, + registerDocumentRangeSemanticTokensProvider: unsupported }; function showMessage(type: MessageType, arg0: any, ...arg1: any[]): Thenable { if (typeof arg0 !== "string") { @@ -777,7 +787,8 @@ export function createVSCodeApi(servicesProvider: Services.Provider): typeof vsc onDidChangeWindowState: unsupported, createQuickPick: unsupported, createInputBox: unsupported, - registerUriHandler: unsupported + registerUriHandler: unsupported, + registerCustomEditorProvider: unsupported }; const commands: typeof vscode.commands = { registerCommand(command, callback, thisArg): Disposable { From c5c7229628aca490142b6fa67b7fe228a39b040b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Mangeonjean?= Date: Sun, 26 Apr 2020 12:56:36 +0200 Subject: [PATCH 3/7] Implement new semantic token api --- client/src/monaco-converter.ts | 9 +++++ client/src/monaco-languages.ts | 62 +++++++++++++++++++++++++++++++++- client/src/services.ts | 15 ++++++++ client/src/vscode-api.ts | 43 ++++++++++++++++++++--- 4 files changed, 124 insertions(+), 5 deletions(-) diff --git a/client/src/monaco-converter.ts b/client/src/monaco-converter.ts index e7e7ceaec..0cf7cda43 100644 --- a/client/src/monaco-converter.ts +++ b/client/src/monaco-converter.ts @@ -19,6 +19,8 @@ import { MarkedString, MarkupContent, ColorInformation, ColorPresentation, FoldingRange, FoldingRangeKind, DiagnosticRelatedInformation, MarkupKind, SymbolKind, DocumentSymbol, CodeAction, SignatureHelpContext, SignatureHelpTriggerKind } from './services'; +import { SemanticTokens } from 'vscode-languageserver-protocol/lib/protocol.sematicTokens.proposed' + import IReadOnlyModel = monaco.editor.IReadOnlyModel; export type RecursivePartial = { @@ -1124,4 +1126,11 @@ export class ProtocolToMonacoConverter { return undefined; } + asSemanticTokens(semanticTokens: SemanticTokens): monaco.languages.SemanticTokens { + return { + resultId: semanticTokens.resultId, + data: Uint32Array.from(semanticTokens.data) + } + } + } diff --git a/client/src/monaco-languages.ts b/client/src/monaco-languages.ts index f643085cb..a0d1e0f63 100644 --- a/client/src/monaco-languages.ts +++ b/client/src/monaco-languages.ts @@ -9,8 +9,11 @@ import { DocumentSymbolProvider, CodeActionProvider, CodeLensProvider, DocumentFormattingEditProvider, DocumentRangeFormattingEditProvider, OnTypeFormattingEditProvider, RenameProvider, DocumentFilter, DocumentSelector, DocumentLinkProvider, ImplementationProvider, TypeDefinitionProvider, DocumentColorProvider, - FoldingRangeProvider + FoldingRangeProvider, + DocumentSemanticTokensProvider, DocumentRangeSemanticTokensProvider } from "./services"; +import { SemanticTokensLegend } from 'vscode-languageserver-protocol/lib/protocol.sematicTokens.proposed' + import { MonacoDiagnosticCollection } from './monaco-diagnostic-collection'; import { ProtocolToMonacoConverter, MonacoToProtocolConverter } from './monaco-converter'; import { DisposableCollection, Disposable } from './disposable'; @@ -513,6 +516,63 @@ export class MonacoLanguages implements Languages { } } + registerDocumentSemanticTokensProvider(selector: DocumentSelector, provider: DocumentSemanticTokensProvider, legend: SemanticTokensLegend): Disposable { + const semanticTokensProvider = this.createSemanticTokensProvider(selector, provider, legend); + const providers = new DisposableCollection(); + for (const language of this.matchLanguage(selector)) { + providers.push(monaco.languages.registerDocumentSemanticTokensProvider(language, semanticTokensProvider)); + } + return providers; + } + + protected createSemanticTokensProvider(selector: DocumentSelector, provider: DocumentSemanticTokensProvider, legend: SemanticTokensLegend): monaco.languages.DocumentSemanticTokensProvider { + return { + getLegend() { + return legend; + }, + provideDocumentSemanticTokens: async (model, lastResultId, token) => { + if (!this.matchModel(selector, MonacoModelIdentifier.fromModel(model))) { + return undefined; + } + const textDocument = this.m2p.asTextDocumentIdentifier(model); + const result = await provider.provideDocumentSemanticTokens({ + textDocument + }, token); + return result && this.p2m.asSemanticTokens(result); + }, + releaseDocumentSemanticTokens: (resultId) => { + } + } + } + + registerDocumentRangeSemanticTokensProvider(selector: DocumentSelector, provider: DocumentRangeSemanticTokensProvider, legend: SemanticTokensLegend): Disposable { + const rangeSemanticTokensProvider = this.createRangeSemanticTokensProvider(selector, provider, legend); + const providers = new DisposableCollection(); + for (const language of this.matchLanguage(selector)) { + providers.push(monaco.languages.registerDocumentRangeSemanticTokensProvider(language, rangeSemanticTokensProvider)); + } + return providers; + } + + protected createRangeSemanticTokensProvider(selector: DocumentSelector, provider: DocumentRangeSemanticTokensProvider, legend: SemanticTokensLegend): monaco.languages.DocumentRangeSemanticTokensProvider { + return { + getLegend() { + return legend; + }, + provideDocumentRangeSemanticTokens: async (model, range, token) => { + if (!this.matchModel(selector, MonacoModelIdentifier.fromModel(model))) { + return undefined; + } + const textDocument = this.m2p.asTextDocumentIdentifier(model); + const result = await provider.provideDocumentRangeSemanticTokens({ + textDocument, + range: this.m2p.asRange(range) + }, token); + return result && this.p2m.asSemanticTokens(result); + } + } + } + protected matchModel(selector: string | DocumentFilter | DocumentSelector, model: MonacoModelIdentifier): boolean { if (Array.isArray(selector)) { return selector.some(filter => this.matchModel(filter, model)); diff --git a/client/src/services.ts b/client/src/services.ts index 41a9b4207..f1ec57d51 100644 --- a/client/src/services.ts +++ b/client/src/services.ts @@ -17,6 +17,10 @@ import { FoldingRange, FoldingRangeRequestParam, DocumentFilter, DocumentSymbol, CodeAction, Declaration, SelectionRangeParams, SelectionRange } from 'vscode-languageserver-protocol'; +import { + SemanticTokens, SemanticTokensEdits, SemanticTokensLegend, SemanticTokensParams, SemanticTokensRangeParams, + SemanticTokensEditsParams +} from 'vscode-languageserver-protocol/lib/protocol.sematicTokens.proposed' import { Disposable, CancellationToken, Event, Emitter @@ -190,6 +194,15 @@ export interface SelectionRangeProvider { provideSelectionRanges(params: SelectionRangeParams, token: CancellationToken): ProviderResult; } +export interface DocumentSemanticTokensProvider { + provideDocumentSemanticTokens(params: SemanticTokensParams, token: CancellationToken): ProviderResult; + provideDocumentSemanticTokensEdits?(params: SemanticTokensEditsParams, token: CancellationToken): ProviderResult; +} + +export interface DocumentRangeSemanticTokensProvider { + provideDocumentRangeSemanticTokens(params: SemanticTokensRangeParams, token: CancellationToken): ProviderResult; +} + export interface Languages { match(selector: DocumentSelector, document: DocumentIdentifier): boolean; createDiagnosticCollection?(name?: string): DiagnosticCollection; @@ -214,6 +227,8 @@ export interface Languages { registerColorProvider?(selector: DocumentSelector, provider: DocumentColorProvider): Disposable; registerFoldingRangeProvider?(selector: DocumentSelector, provider: FoldingRangeProvider): Disposable; registerSelectionRangeProvider?(selector: DocumentSelector, provider: SelectionRangeProvider): Disposable; + registerDocumentSemanticTokensProvider?(selector: DocumentSelector, provider: DocumentSemanticTokensProvider, legend: SemanticTokensLegend): Disposable; + registerDocumentRangeSemanticTokensProvider?(selector: DocumentSelector, provider: DocumentRangeSemanticTokensProvider, legend: SemanticTokensLegend): Disposable; } export interface TextDocumentDidChangeEvent { diff --git a/client/src/vscode-api.ts b/client/src/vscode-api.ts index 3956a0f57..e823073f0 100644 --- a/client/src/vscode-api.ts +++ b/client/src/vscode-api.ts @@ -52,6 +52,9 @@ export function createVSCodeApi(servicesProvider: Services.Provider): typeof vsc contains = unsupported intersects = unsupported } + class SemanticTokens implements vscode.SemanticTokens { + constructor(public data: Uint32Array, public resultId?: string) { } + } class EmptyFileSystem implements vscode.FileSystem { stat(uri: vscode.Uri): Thenable { @@ -691,14 +694,45 @@ export function createVSCodeApi(servicesProvider: Services.Provider): typeof vsc } }); }, + registerEvaluatableExpressionProvider: unsupported, + registerDocumentSemanticTokensProvider (selector: vscode.DocumentSelector, provider: vscode.DocumentSemanticTokensProvider, legend: vscode.SemanticTokensLegend) { + if (!isDocumentSelector(selector)) { + throw new Error('unexpected selector: ' + JSON.stringify(selector)); + } + const { languages } = servicesProvider(); + if (!languages.registerDocumentSemanticTokensProvider) { + return Disposable.create(() => { }); + } + + return languages.registerDocumentSemanticTokensProvider(selector, { + provideDocumentSemanticTokens({ textDocument }, token) { + return provider.provideDocumentSemanticTokens(textDocument, token) as any; + }, + provideDocumentSemanticTokensEdits: provider.provideDocumentSemanticTokensEdits && (({ textDocument, previousResultId }, token) => { + return provider.provideDocumentSemanticTokensEdits!(textDocument, previousResultId, token) as any; + }) + }, legend) + }, + registerDocumentRangeSemanticTokensProvider (selector: vscode.DocumentSelector, provider: vscode.DocumentRangeSemanticTokensProvider, legend: vscode.SemanticTokensLegend) { + if (!isDocumentSelector(selector)) { + throw new Error('unexpected selector: ' + JSON.stringify(selector)); + } + const { languages } = servicesProvider(); + if (!languages.registerDocumentRangeSemanticTokensProvider) { + return Disposable.create(() => { }); + } + + return languages.registerDocumentRangeSemanticTokensProvider(selector, { + provideDocumentRangeSemanticTokens({ textDocument, range }, token) { + return provider.provideDocumentRangeSemanticTokens(textDocument, range, token) as any; + } + }, legend) + }, getLanguages: unsupported, setTextDocumentLanguage: unsupported, getDiagnostics: unsupported, setLanguageConfiguration: unsupported, - onDidChangeDiagnostics: unsupported, - registerEvaluatableExpressionProvider: unsupported, - registerDocumentSemanticTokensProvider: unsupported, - registerDocumentRangeSemanticTokensProvider: unsupported + onDidChangeDiagnostics: unsupported }; function showMessage(type: MessageType, arg0: any, ...arg1: any[]): Thenable { if (typeof arg0 !== "string") { @@ -818,6 +852,7 @@ export function createVSCodeApi(servicesProvider: Services.Provider): typeof vsc CodeLens, DocumentLink, CodeActionKind, + SemanticTokens, Disposable: CodeDisposable, SignatureHelpTriggerKind: SignatureHelpTriggerKind, DiagnosticSeverity: ServicesModule.DiagnosticSeverity From 72ec024f18a60b951c4f54ad94247fcf53c013dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Mangeonjean?= Date: Sun, 26 Apr 2020 12:57:52 +0200 Subject: [PATCH 4/7] Rollback vscode types to prevent conflict with lsp-protocol types --- client/src/vscode-api.ts | 3 +-- package.json | 2 +- yarn.lock | 8 ++++---- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/client/src/vscode-api.ts b/client/src/vscode-api.ts index e823073f0..93c90bd54 100644 --- a/client/src/vscode-api.ts +++ b/client/src/vscode-api.ts @@ -821,8 +821,7 @@ export function createVSCodeApi(servicesProvider: Services.Provider): typeof vsc onDidChangeWindowState: unsupported, createQuickPick: unsupported, createInputBox: unsupported, - registerUriHandler: unsupported, - registerCustomEditorProvider: unsupported + registerUriHandler: unsupported }; const commands: typeof vscode.commands = { registerCommand(command, callback, thisArg): Disposable { diff --git a/package.json b/package.json index d20b1ece9..7756ff5e5 100644 --- a/package.json +++ b/package.json @@ -5,7 +5,7 @@ "@types/node": "^13.1.7", "@types/normalize-url": "^1.9.1", "@types/ws": "0.0.39", - "@types/vscode": "1.44.0", + "@types/vscode": "1.43.0", "css-loader": "^0.28.11", "lerna": "^3.16.4", "monaco-editor-core": "^0.20.0", diff --git a/yarn.lock b/yarn.lock index 5e206b337..67f2cfb69 100644 --- a/yarn.lock +++ b/yarn.lock @@ -904,10 +904,10 @@ "@types/express-serve-static-core" "*" "@types/mime" "*" -"@types/vscode@1.44.0": - version "1.44.0" - resolved "https://registry.yarnpkg.com/@types/vscode/-/vscode-1.44.0.tgz#62ecfe3d0e38942fce556574da54ee1013c775b7" - integrity sha512-WJZtZlinE3meRdH+I7wTsIhpz/GLhqEQwmPGeh4s1irWLwMzCeTV8WZ+pgPTwrDXoafVUWwo1LiZ9HJVHFlJSQ== +"@types/vscode@1.43.0": + version "1.43.0" + resolved "https://registry.yarnpkg.com/@types/vscode/-/vscode-1.43.0.tgz#22276e60034c693b33117f1068ffaac0e89522db" + integrity sha512-kIaR9qzd80rJOxePKpCB/mdy00mz8Apt2QA5Y6rdrKFn13QNFNeP3Hzmsf37Bwh/3cS7QjtAeGSK7wSqAU0sYQ== "@types/ws@0.0.39": version "0.0.39" From 55b7760d6db21dfbb1e81a7ae7bd37f7771ad01c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Mangeonjean?= Date: Sun, 26 Apr 2020 13:00:30 +0200 Subject: [PATCH 5/7] Add a way to register proposed features --- client/src/monaco-language-client.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/client/src/monaco-language-client.ts b/client/src/monaco-language-client.ts index 7e58f750b..01b57c2f9 100644 --- a/client/src/monaco-language-client.ts +++ b/client/src/monaco-language-client.ts @@ -12,6 +12,8 @@ import { ImplementationFeature } from "vscode-languageclient/lib/implementation" import { ColorProviderFeature } from "vscode-languageclient/lib/colorProvider"; import { WorkspaceFoldersFeature } from "vscode-languageclient/lib/workspaceFolders"; import { FoldingRangeFeature } from "vscode-languageclient/lib/foldingRange"; +import { CallHierarchyFeature } from "vscode-languageclient/lib/callHierarchy.proposed"; +import { SemanticTokensFeature } from "vscode-languageclient/lib/semanticTokens.proposed"; import * as p2c from 'vscode-languageclient/lib/protocolConverter'; import * as c2p from 'vscode-languageclient/lib/codeConverter'; import { IConnectionProvider, IConnection } from './connection'; @@ -105,6 +107,11 @@ export class MonacoLanguageClient extends BaseLanguageClient { } } + public registerProposedFeatures() { + this.registerFeature(new CallHierarchyFeature(this)); + this.registerFeature(new SemanticTokensFeature(this)); + } + } export namespace MonacoLanguageClient { export interface Options { From 16601c3d744555850ee4258738a2a23c6134df53 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Mangeonjean?= Date: Mon, 27 Apr 2020 09:52:51 +0200 Subject: [PATCH 6/7] Format files, replace tabs with spaces --- client/src/monaco-converter.ts | 62 ++++++++++++++-------------- client/src/monaco-language-client.ts | 4 +- client/src/typings/monaco/index.d.ts | 2 +- 3 files changed, 34 insertions(+), 34 deletions(-) diff --git a/client/src/monaco-converter.ts b/client/src/monaco-converter.ts index 0cf7cda43..fc7418345 100644 --- a/client/src/monaco-converter.ts +++ b/client/src/monaco-converter.ts @@ -58,9 +58,9 @@ export namespace ProtocolCompletionItem { } } -type RangeReplace = { insert: monaco.IRange; replace: monaco.IRange} +type RangeReplace = { insert: monaco.IRange; replace: monaco.IRange } -function isRangeReplace(v: Partial | RangeReplace) : v is RangeReplace { +function isRangeReplace(v: Partial | RangeReplace): v is RangeReplace { return (v as RangeReplace).insert !== undefined; } @@ -83,7 +83,7 @@ export class MonacoToProtocolConverter { asRange(range: monaco.IRange): Range; asRange(range: monaco.IRange | undefined): Range | undefined; asRange(range: monaco.IRange | null): Range | null; - asRange(range: monaco.IRange | { insert: monaco.IRange; replace: monaco.IRange}) : Range; + asRange(range: monaco.IRange | { insert: monaco.IRange; replace: monaco.IRange }): Range; asRange(range: Partial): RecursivePartial; asRange(range: Partial | undefined): RecursivePartial | undefined; asRange(range: Partial | null): RecursivePartial | null; @@ -133,7 +133,7 @@ export class MonacoToProtocolConverter { } } - asSignatureHelpContext(context: monaco.languages.SignatureHelpContext) : SignatureHelpContext { + asSignatureHelpContext(context: monaco.languages.SignatureHelpContext): SignatureHelpContext { return { triggerKind: this.asSignatureHelpTriggerKind(context.triggerKind), triggerCharacter: context.triggerCharacter, @@ -142,8 +142,8 @@ export class MonacoToProtocolConverter { }; } - asSignatureHelp(signatureHelp: monaco.languages.SignatureHelp | undefined) : SignatureHelp | undefined { - if(signatureHelp === undefined) { + asSignatureHelp(signatureHelp: monaco.languages.SignatureHelp | undefined): SignatureHelp | undefined { + if (signatureHelp === undefined) { return undefined; } return { @@ -153,7 +153,7 @@ export class MonacoToProtocolConverter { }; } - asSignatureInformation(signatureInformation: monaco.languages.SignatureInformation) : SignatureInformation { + asSignatureInformation(signatureInformation: monaco.languages.SignatureInformation): SignatureInformation { return { documentation: this.asMarkupContent(signatureInformation.documentation), label: signatureInformation.label, @@ -161,7 +161,7 @@ export class MonacoToProtocolConverter { }; } - asParameterInformation(parameterInformation: monaco.languages.ParameterInformation) : ParameterInformation { + asParameterInformation(parameterInformation: monaco.languages.ParameterInformation): ParameterInformation { return { documentation: this.asMarkupContent(parameterInformation.documentation), label: parameterInformation.label @@ -169,10 +169,10 @@ export class MonacoToProtocolConverter { } asMarkupContent(markupContent: (string | monaco.IMarkdownString | undefined)): string | MarkupContent | undefined { - if(markupContent === undefined) { + if (markupContent === undefined) { return undefined; } - if(typeof markupContent === "string") { + if (typeof markupContent === "string") { return markupContent; } return { @@ -181,8 +181,8 @@ export class MonacoToProtocolConverter { }; } - asSignatureHelpTriggerKind(triggerKind: monaco.languages.SignatureHelpTriggerKind) : SignatureHelpTriggerKind { - switch (triggerKind) { + asSignatureHelpTriggerKind(triggerKind: monaco.languages.SignatureHelpTriggerKind): SignatureHelpTriggerKind { + switch (triggerKind) { case monaco.languages.SignatureHelpTriggerKind.ContentChange: return SignatureHelpTriggerKind.ContentChange; case monaco.languages.SignatureHelpTriggerKind.TriggerCharacter: @@ -559,14 +559,14 @@ export class ProtocolToMonacoConverter { } return { lenses: items.map((codeLens) => this.asCodeLens(codeLens)), - dispose: () => {} + dispose: () => { } }; } asCodeActionList(actions: (Command | CodeAction)[]): monaco.languages.CodeActionList { return { actions: actions.map(action => this.asCodeAction(action)), - dispose: () => {} + dispose: () => { } }; } @@ -731,22 +731,22 @@ export class ProtocolToMonacoConverter { } asLocationLink(item: undefined | null): undefined; - asLocationLink(item: ls.LocationLink): monaco.languages.LocationLink; - asLocationLink(item: ls.LocationLink | undefined | null): monaco.languages.LocationLink | undefined { - if (!item) { - return undefined; - } - let result: monaco.languages.LocationLink = { - uri: monaco.Uri.parse(item.targetUri), - range: this.asRange(item.targetSelectionRange)!, // See issue: https://github.com/Microsoft/vscode/issues/58649 - originSelectionRange: this.asRange(item.originSelectionRange), - targetSelectionRange: this.asRange(item.targetSelectionRange) - }; - if (!result.targetSelectionRange) { - throw new Error(`targetSelectionRange must not be undefined or null`); - } - return result; - } + asLocationLink(item: ls.LocationLink): monaco.languages.LocationLink; + asLocationLink(item: ls.LocationLink | undefined | null): monaco.languages.LocationLink | undefined { + if (!item) { + return undefined; + } + let result: monaco.languages.LocationLink = { + uri: monaco.Uri.parse(item.targetUri), + range: this.asRange(item.targetSelectionRange)!, // See issue: https://github.com/Microsoft/vscode/issues/58649 + originSelectionRange: this.asRange(item.originSelectionRange), + targetSelectionRange: this.asRange(item.targetSelectionRange) + }; + if (!result.targetSelectionRange) { + throw new Error(`targetSelectionRange must not be undefined or null`); + } + return result; + } asSignatureHelpResult(item: undefined | null): undefined; asSignatureHelpResult(item: SignatureHelp): monaco.languages.SignatureHelpResult; @@ -775,7 +775,7 @@ export class ProtocolToMonacoConverter { } return { value: result, - dispose: () => {} + dispose: () => { } }; } diff --git a/client/src/monaco-language-client.ts b/client/src/monaco-language-client.ts index 01b57c2f9..de2b26849 100644 --- a/client/src/monaco-language-client.ts +++ b/client/src/monaco-language-client.ts @@ -109,8 +109,8 @@ export class MonacoLanguageClient extends BaseLanguageClient { public registerProposedFeatures() { this.registerFeature(new CallHierarchyFeature(this)); - this.registerFeature(new SemanticTokensFeature(this)); - } + this.registerFeature(new SemanticTokensFeature(this)); + } } export namespace MonacoLanguageClient { diff --git a/client/src/typings/monaco/index.d.ts b/client/src/typings/monaco/index.d.ts index 50bc5f490..cd333900d 100644 --- a/client/src/typings/monaco/index.d.ts +++ b/client/src/typings/monaco/index.d.ts @@ -23,7 +23,7 @@ declare module monaco.commands { } export interface ICommandHandler { - (accessor: monaco.instantiation.ServicesAccessor, ...args: any[]): void; + (accessor: monaco.instantiation.ServicesAccessor, ...args: any[]): void; } export interface ICommand { From e33200fd1ab08c83d758e1eabc49cbd251f7d7e0 Mon Sep 17 00:00:00 2001 From: Roman Nikitenko Date: Sun, 31 May 2020 23:04:51 +0300 Subject: [PATCH 7/7] Align versions Signed-off-by: Roman Nikitenko --- example/package.json | 8 ++++---- examples/browser/package.json | 4 ++-- yarn.lock | 26 +++++++++++++------------- 3 files changed, 19 insertions(+), 19 deletions(-) diff --git a/example/package.json b/example/package.json index ff3e78805..e6588d816 100644 --- a/example/package.json +++ b/example/package.json @@ -5,14 +5,14 @@ "dependencies": { "express": "^4.15.2", "file-loader": "^4.3.0", - "monaco-editor-core": "^0.19.3", + "monaco-editor-core": "^0.20.0", "monaco-languageclient": "^0.13.0", "normalize-url": "^2.0.1", "reconnecting-websocket": "^3.2.2", "request-light": "^0.2.2", - "vscode-json-languageservice": "^3.4.11", - "vscode-jsonrpc": "^5.0.0", - "vscode-languageserver": "^6.0.0", + "vscode-json-languageservice": "^3.4.12", + "vscode-jsonrpc": "^5.0.1", + "vscode-languageserver": "^6.1.1", "vscode-uri": "^2.1.1", "vscode-ws-jsonrpc": "^0.2.0", "ws": "^5.0.0" diff --git a/examples/browser/package.json b/examples/browser/package.json index 4e8460342..75a8ba4cd 100644 --- a/examples/browser/package.json +++ b/examples/browser/package.json @@ -5,8 +5,8 @@ "dependencies": { "file-loader": "^4.3.0", "monaco-languageclient": "^0.13.0", - "vscode-json-languageservice": "^3.3.1", - "vscode-languageserver-types": "^3.15.0-next" + "vscode-json-languageservice": "^3.4.12", + "vscode-languageserver-types": "^3.15.1" }, "scripts": { "prepare": "yarn run clean && yarn run build", diff --git a/yarn.lock b/yarn.lock index 67f2cfb69..e00f4c44b 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4492,11 +4492,6 @@ modify-values@^1.0.0: resolved "https://registry.yarnpkg.com/modify-values/-/modify-values-1.0.1.tgz#b3939fa605546474e3e3e3c63d64bd43b4ee6022" integrity sha512-xV2bxeN6F7oYjZWTe/YPAy6MN2M+sL4u/Rlm2AHCIVGfo2p1yGmBHQ6vHehl4bRTZBdHu3TSkWdYgkwpYzAGSw== -monaco-editor-core@^0.19.3: - version "0.19.3" - resolved "https://registry.yarnpkg.com/monaco-editor-core/-/monaco-editor-core-0.19.3.tgz#6d2b36f42f0f42be6def5604810fafc288c9cc3e" - integrity sha512-Fd6bTTaAxDAulh3q9Hordj80DSFZFGhjKX/Z3K/kElA9xkPyNwyaOjphYp8254nhUEKCk56TKP7qfRkUjjZF3w== - monaco-editor-core@^0.20.0: version "0.20.0" resolved "https://registry.yarnpkg.com/monaco-editor-core/-/monaco-editor-core-0.20.0.tgz#d5ce01307d298dbca6ab9194812812b32b50433f" @@ -7075,15 +7070,15 @@ vm-browserify@^1.0.1: resolved "https://registry.yarnpkg.com/vm-browserify/-/vm-browserify-1.1.0.tgz#bd76d6a23323e2ca8ffa12028dc04559c75f9019" integrity sha512-iq+S7vZJE60yejDYM0ek6zg308+UZsdtPExWP9VZoCFCz1zkJoXFnAX7aZfd/ZwrkidzdUZL0C/ryW+JwAiIGw== -vscode-json-languageservice@^3.3.1, vscode-json-languageservice@^3.4.11: - version "3.5.2" - resolved "https://registry.yarnpkg.com/vscode-json-languageservice/-/vscode-json-languageservice-3.5.2.tgz#4b898140a8e581359c10660845a4cae15dcbb4f9" - integrity sha512-9cUvBq00O08lpWVVOx6tQ1yLxCHss79nsUdEAVYGomRyMbnPBmc0AkYPcXI9WK1EM6HBo0R9Zo3NjFhcICpy4A== +vscode-json-languageservice@^3.4.12: + version "3.6.0" + resolved "https://registry.yarnpkg.com/vscode-json-languageservice/-/vscode-json-languageservice-3.6.0.tgz#133a1e2c3a3dffe38564a1ba948516805c3c1869" + integrity sha512-dXzFywypUZ9T0tjr4fREZiknXDz6vAGx1zsxbQY1+9DOpjMfbz0VLP873KmcbuvL4K3nseKTxc4TKHu8kLXRMw== dependencies: jsonc-parser "^2.2.1" vscode-languageserver-textdocument "^1.0.1" vscode-languageserver-types "^3.15.1" - vscode-nls "^4.1.1" + vscode-nls "^4.1.2" vscode-uri "^2.1.1" vscode-jsonrpc@^5.0.0, vscode-jsonrpc@^5.0.1: @@ -7112,23 +7107,28 @@ vscode-languageserver-textdocument@^1.0.1: resolved "https://registry.yarnpkg.com/vscode-languageserver-textdocument/-/vscode-languageserver-textdocument-1.0.1.tgz#178168e87efad6171b372add1dea34f53e5d330f" integrity sha512-UIcJDjX7IFkck7cSkNNyzIz5FyvpQfY7sdzVy+wkKN/BLaD4DQ0ppXQrKePomCxTS7RrolK1I0pey0bG9eh8dA== -vscode-languageserver-types@3.15.1, vscode-languageserver-types@^3.15.0-next, vscode-languageserver-types@^3.15.1: +vscode-languageserver-types@3.15.1, vscode-languageserver-types@^3.15.1: version "3.15.1" resolved "https://registry.yarnpkg.com/vscode-languageserver-types/-/vscode-languageserver-types-3.15.1.tgz#17be71d78d2f6236d414f0001ce1ef4d23e6b6de" integrity sha512-+a9MPUQrNGRrGU630OGbYVQ+11iOIovjCkqxajPa9w57Sd5ruK8WQNsslzpa0x/QJqC8kRc2DUxWjIFwoNm4ZQ== -vscode-languageserver@^6.0.0: +vscode-languageserver@^6.1.1: version "6.1.1" resolved "https://registry.yarnpkg.com/vscode-languageserver/-/vscode-languageserver-6.1.1.tgz#d76afc68172c27d4327ee74332b468fbc740d762" integrity sha512-DueEpkUAkD5XTR4MLYNr6bQIp/UFR0/IPApgXU3YfCBCB08u2sm9hRCs6DxYZELkk++STPjpcjksR2H8qI3cDQ== dependencies: vscode-languageserver-protocol "^3.15.3" -vscode-nls@^4.0.0, vscode-nls@^4.1.1: +vscode-nls@^4.0.0: version "4.1.1" resolved "https://registry.yarnpkg.com/vscode-nls/-/vscode-nls-4.1.1.tgz#f9916b64e4947b20322defb1e676a495861f133c" integrity sha512-4R+2UoUUU/LdnMnFjePxfLqNhBS8lrAFyX7pjb2ud/lqDkrUavFUTcG7wR0HBZFakae0Q6KLBFjMS6W93F403A== +vscode-nls@^4.1.2: + version "4.1.2" + resolved "https://registry.yarnpkg.com/vscode-nls/-/vscode-nls-4.1.2.tgz#ca8bf8bb82a0987b32801f9fddfdd2fb9fd3c167" + integrity sha512-7bOHxPsfyuCqmP+hZXscLhiHwe7CSuFE4hyhbs22xPIhQ4jv99FcR4eBzfYYVLP356HNFpdvz63FFb/xw6T4Iw== + vscode-uri@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/vscode-uri/-/vscode-uri-2.1.1.tgz#5aa1803391b6ebdd17d047f51365cf62c38f6e90"