@codingame/monaco-vscode-extensions-service-override 20.5.0 → 21.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +28 -27
- package/vscode/src/vs/platform/extensionManagement/common/extensionManagementCLI.js +28 -28
- package/vscode/src/vs/workbench/api/browser/mainThreadAuthentication.d.ts +6 -24
- package/vscode/src/vs/workbench/api/browser/mainThreadAuthentication.js +74 -74
- package/vscode/src/vs/workbench/api/browser/mainThreadCLICommands.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadChatAgents2.js +2 -4
- package/vscode/src/vs/workbench/api/browser/mainThreadChatSessions.d.ts +52 -9
- package/vscode/src/vs/workbench/api/browser/mainThreadChatSessions.js +271 -134
- package/vscode/src/vs/workbench/api/browser/mainThreadComments.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadCustomEditors.js +4 -4
- package/vscode/src/vs/workbench/api/browser/mainThreadDataChannels.d.ts +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadDataChannels.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadDocumentsAndEditors.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadEditSessionIdentityParticipant.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadEditorTabs.d.ts +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadEditorTabs.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadEditors.d.ts +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadEditors.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadExtensionService.js +11 -11
- package/vscode/src/vs/workbench/api/browser/mainThreadFileSystemEventService.js +20 -20
- package/vscode/src/vs/workbench/api/browser/mainThreadLanguageFeatures.d.ts +4 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadLanguageFeatures.js +58 -8
- package/vscode/src/vs/workbench/api/browser/mainThreadLanguageModels.d.ts +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadLanguageModels.js +6 -6
- package/vscode/src/vs/workbench/api/browser/mainThreadMcp.js +7 -7
- package/vscode/src/vs/workbench/api/browser/mainThreadMessageService.js +4 -4
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebook.js +7 -0
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebookDocumentsAndEditors.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebookEditors.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebookSaveParticipant.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadOutputService.js +3 -3
- package/vscode/src/vs/workbench/api/browser/mainThreadProgress.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadSaveParticipant.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadSearch.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadTask.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadTerminalService.js +3 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadTunnelService.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadUriOpeners.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadWebviewPanels.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadWebviews.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadWorkspace.js +5 -5
- package/vscode/src/vs/workbench/contrib/customEditor/common/customTextEditorModel.js +1 -1
- package/vscode/src/vs/workbench/contrib/externalUriOpener/common/contributedOpeners.js +1 -1
- package/vscode/src/vs/workbench/services/extensionManagement/browser/extensionBisect.js +23 -23
- package/vscode/src/vs/workbench/services/extensions/common/abstractExtensionService.js +12 -12
- package/vscode/src/vs/workbench/services/extensions/common/extensionHostManager.js +1 -1
- package/vscode/src/vs/workbench/services/extensions/common/extensionsProposedApi.js +1 -1
- package/vscode/src/vs/workbench/services/extensions/common/extensionsUtil.js +4 -4
- package/vscode/src/vs/workbench/contrib/editTelemetry/browser/telemetry/forwardingTelemetryService.d.ts +0 -30
- package/vscode/src/vs/workbench/contrib/editTelemetry/browser/telemetry/forwardingTelemetryService.js +0 -67
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-vscode-extensions-service-override",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "21.0.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "VSCode public API plugged on the monaco editor - extensions service-override",
|
|
6
6
|
"keywords": [],
|
|
@@ -15,32 +15,33 @@
|
|
|
15
15
|
},
|
|
16
16
|
"type": "module",
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@codingame/monaco-vscode-
|
|
19
|
-
"@codingame/monaco-vscode-
|
|
20
|
-
"@codingame/monaco-vscode-
|
|
21
|
-
"@codingame/monaco-vscode-
|
|
22
|
-
"@codingame/monaco-vscode-
|
|
23
|
-
"@codingame/monaco-vscode-
|
|
24
|
-
"@codingame/monaco-vscode-
|
|
25
|
-
"@codingame/monaco-vscode-
|
|
26
|
-
"@codingame/monaco-vscode-
|
|
27
|
-
"@codingame/monaco-vscode-
|
|
28
|
-
"@codingame/monaco-vscode-
|
|
29
|
-
"@codingame/monaco-vscode-
|
|
30
|
-
"@codingame/monaco-vscode-
|
|
31
|
-
"@codingame/monaco-vscode-
|
|
32
|
-
"@codingame/monaco-vscode-
|
|
33
|
-
"@codingame/monaco-vscode-
|
|
34
|
-
"@codingame/monaco-vscode-
|
|
35
|
-
"@codingame/monaco-vscode-
|
|
36
|
-
"@codingame/monaco-vscode-
|
|
37
|
-
"@codingame/monaco-vscode-
|
|
38
|
-
"@codingame/monaco-vscode-
|
|
39
|
-
"@codingame/monaco-vscode-
|
|
40
|
-
"@codingame/monaco-vscode-
|
|
41
|
-
"@codingame/monaco-vscode-
|
|
42
|
-
"@codingame/monaco-vscode-
|
|
43
|
-
"@codingame/monaco-vscode-
|
|
18
|
+
"@codingame/monaco-vscode-05a2a821-e4de-5941-b7f9-bbf01c09f229-common": "21.0.0",
|
|
19
|
+
"@codingame/monaco-vscode-0af61f78-dfc5-57ba-8d32-66268c8de38d-common": "21.0.0",
|
|
20
|
+
"@codingame/monaco-vscode-23b6fb38-5e58-5886-b34b-27abc4f5df02-common": "21.0.0",
|
|
21
|
+
"@codingame/monaco-vscode-256d5b78-0649-50e9-8354-2807f95f68f4-common": "21.0.0",
|
|
22
|
+
"@codingame/monaco-vscode-2a94c04a-b85b-5669-b06b-89c1bfa11cb9-common": "21.0.0",
|
|
23
|
+
"@codingame/monaco-vscode-34a0ffd3-b9f5-5699-b43b-38af5732f38a-common": "21.0.0",
|
|
24
|
+
"@codingame/monaco-vscode-4a3ac544-9a61-534c-88df-756262793ef7-common": "21.0.0",
|
|
25
|
+
"@codingame/monaco-vscode-4dda7789-5a25-5e8b-b2de-c2f11b1b96e5-common": "21.0.0",
|
|
26
|
+
"@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common": "21.0.0",
|
|
27
|
+
"@codingame/monaco-vscode-5e2c24a1-3217-55e8-bc90-521eaf7df5a6-common": "21.0.0",
|
|
28
|
+
"@codingame/monaco-vscode-622c0cca-d5fa-59b6-b730-0715afcf93ee-common": "21.0.0",
|
|
29
|
+
"@codingame/monaco-vscode-670aae94-7f88-54d7-90ea-6fcbef423557-common": "21.0.0",
|
|
30
|
+
"@codingame/monaco-vscode-6845754f-e617-5ed9-8aaa-6ca3653a9532-common": "21.0.0",
|
|
31
|
+
"@codingame/monaco-vscode-71c8dbff-4c98-552f-aef0-e72b00fdcfc0-common": "21.0.0",
|
|
32
|
+
"@codingame/monaco-vscode-7f39b6f1-3542-5430-8760-0f404d7a7cee-common": "21.0.0",
|
|
33
|
+
"@codingame/monaco-vscode-8ccb7637-50ea-5359-97bf-00015d7fe567-common": "21.0.0",
|
|
34
|
+
"@codingame/monaco-vscode-a654b07e-8806-5425-b124-18f03ba8e11a-common": "21.0.0",
|
|
35
|
+
"@codingame/monaco-vscode-a9da9abe-278d-5ce6-9418-99c7c07c5c37-common": "21.0.0",
|
|
36
|
+
"@codingame/monaco-vscode-api": "21.0.0",
|
|
37
|
+
"@codingame/monaco-vscode-b994942c-360d-5b68-8a33-77d4bde6b714-common": "21.0.0",
|
|
38
|
+
"@codingame/monaco-vscode-bba55be6-41a2-50cd-a3cc-8bafa35bfa89-common": "21.0.0",
|
|
39
|
+
"@codingame/monaco-vscode-bf94ddb5-e436-506a-9763-5ab86b642508-common": "21.0.0",
|
|
40
|
+
"@codingame/monaco-vscode-caeb744c-8e3f-5c11-80fb-0f057d24d544-common": "21.0.0",
|
|
41
|
+
"@codingame/monaco-vscode-d0569cfb-4706-5ad6-b0b0-5115ad8685db-common": "21.0.0",
|
|
42
|
+
"@codingame/monaco-vscode-eb7d5efd-2e60-59f8-9ba4-9a8ae8cb2957-common": "21.0.0",
|
|
43
|
+
"@codingame/monaco-vscode-eba0b9b3-174c-5dae-9867-a37810ca1808-common": "21.0.0",
|
|
44
|
+
"@codingame/monaco-vscode-files-service-override": "21.0.0"
|
|
44
45
|
},
|
|
45
46
|
"main": "index.js",
|
|
46
47
|
"module": "index.js",
|
|
@@ -12,9 +12,9 @@ import { IExtensionManagementService, IExtensionGalleryService } from '@codingam
|
|
|
12
12
|
import { getIdAndVersion, areSameExtensions, getGalleryExtensionId, getExtensionId } from '@codingame/monaco-vscode-api/vscode/vs/platform/extensionManagement/common/extensionManagementUtil';
|
|
13
13
|
import { ExtensionType, EXTENSION_CATEGORIES } from '@codingame/monaco-vscode-api/vscode/vs/platform/extensions/common/extensions';
|
|
14
14
|
|
|
15
|
-
const notFound = (id) => ( localize(
|
|
15
|
+
const notFound = (id) => ( localize(1820, "Extension '{0}' not found.", id));
|
|
16
16
|
const useId = ( localize(
|
|
17
|
-
|
|
17
|
+
1821,
|
|
18
18
|
"Make sure you use the full extension ID, including the publisher, e.g.: {0}",
|
|
19
19
|
'ms-dotnettools.csharp'
|
|
20
20
|
));
|
|
@@ -51,7 +51,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
51
51
|
return;
|
|
52
52
|
}
|
|
53
53
|
if (this.location) {
|
|
54
|
-
this.logger.info(( localize(
|
|
54
|
+
this.logger.info(( localize(1822, "Extensions installed on {0}:", this.location)));
|
|
55
55
|
}
|
|
56
56
|
extensions = extensions.sort((e1, e2) => e1.identifier.id.localeCompare(e2.identifier.id));
|
|
57
57
|
let lastId = undefined;
|
|
@@ -66,7 +66,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
66
66
|
const failed = [];
|
|
67
67
|
try {
|
|
68
68
|
if (extensions.length) {
|
|
69
|
-
this.logger.info(this.location ? ( localize(
|
|
69
|
+
this.logger.info(this.location ? ( localize(1823, "Installing extensions on {0}...", this.location)) : ( localize(1824, "Installing extensions...")));
|
|
70
70
|
}
|
|
71
71
|
const installVSIXInfos = [];
|
|
72
72
|
const installExtensionInfos = [];
|
|
@@ -109,11 +109,11 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
109
109
|
}
|
|
110
110
|
}
|
|
111
111
|
catch (error) {
|
|
112
|
-
this.logger.error(( localize(
|
|
112
|
+
this.logger.error(( localize(1825, "Error while installing extensions: {0}", getErrorMessage(error))));
|
|
113
113
|
throw error;
|
|
114
114
|
}
|
|
115
115
|
if (failed.length) {
|
|
116
|
-
throw ( new Error(( localize(
|
|
116
|
+
throw ( new Error(( localize(1826, "Failed Installing Extensions: {0}", failed.join(', ')))));
|
|
117
117
|
}
|
|
118
118
|
}
|
|
119
119
|
async updateExtensions(profileLocation) {
|
|
@@ -125,7 +125,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
125
125
|
}
|
|
126
126
|
}
|
|
127
127
|
this.logger.trace(( localize(
|
|
128
|
-
|
|
128
|
+
1827,
|
|
129
129
|
"Fetching latest versions for {0} extensions",
|
|
130
130
|
installedExtensionsQuery.length
|
|
131
131
|
)));
|
|
@@ -142,11 +142,11 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
142
142
|
}
|
|
143
143
|
}
|
|
144
144
|
if (!extensionsToUpdate.length) {
|
|
145
|
-
this.logger.info(( localize(
|
|
145
|
+
this.logger.info(( localize(1828, "No extension to update")));
|
|
146
146
|
return;
|
|
147
147
|
}
|
|
148
148
|
this.logger.info(( localize(
|
|
149
|
-
|
|
149
|
+
1829,
|
|
150
150
|
"Updating extensions: {0}",
|
|
151
151
|
( extensionsToUpdate.map(ext => ext.extension.identifier.id)).join(', ')
|
|
152
152
|
)));
|
|
@@ -154,7 +154,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
154
154
|
for (const extensionResult of installationResult) {
|
|
155
155
|
if (extensionResult.error) {
|
|
156
156
|
this.logger.error(( localize(
|
|
157
|
-
|
|
157
|
+
1830,
|
|
158
158
|
"Error while updating extension {0}: {1}",
|
|
159
159
|
extensionResult.identifier.id,
|
|
160
160
|
getErrorMessage(extensionResult.error)
|
|
@@ -162,7 +162,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
162
162
|
}
|
|
163
163
|
else {
|
|
164
164
|
this.logger.info(( localize(
|
|
165
|
-
|
|
165
|
+
1831,
|
|
166
166
|
"Extension '{0}' v{1} was successfully updated.",
|
|
167
167
|
extensionResult.identifier.id,
|
|
168
168
|
extensionResult.local?.manifest.version
|
|
@@ -177,7 +177,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
177
177
|
if (installedExtension) {
|
|
178
178
|
if (!force && (!version || (version === 'prerelease' && installedExtension.preRelease))) {
|
|
179
179
|
this.logger.info(( localize(
|
|
180
|
-
|
|
180
|
+
1832,
|
|
181
181
|
"Extension '{0}' v{1} is already installed. Use '--force' option to update to latest version or provide '@<version>' to install a specific version, for example: '{2}@1.2.3'.",
|
|
182
182
|
id,
|
|
183
183
|
installedExtension.manifest.version,
|
|
@@ -186,7 +186,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
186
186
|
return false;
|
|
187
187
|
}
|
|
188
188
|
if (version && installedExtension.manifest.version === version) {
|
|
189
|
-
this.logger.info(( localize(
|
|
189
|
+
this.logger.info(( localize(1833, "Extension '{0}' is already installed.", `${id}@${version}`)));
|
|
190
190
|
return false;
|
|
191
191
|
}
|
|
192
192
|
if (installedExtension.preRelease && version !== 'prerelease') {
|
|
@@ -223,24 +223,24 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
223
223
|
if (installedExtension) {
|
|
224
224
|
if (gallery.version === installedExtension.manifest.version) {
|
|
225
225
|
this.logger.info(( localize(
|
|
226
|
-
|
|
226
|
+
1833,
|
|
227
227
|
"Extension '{0}' is already installed.",
|
|
228
228
|
version ? `${id}@${version}` : id
|
|
229
229
|
)));
|
|
230
230
|
return;
|
|
231
231
|
}
|
|
232
232
|
this.logger.info(( localize(
|
|
233
|
-
|
|
233
|
+
1834,
|
|
234
234
|
"Updating the extension '{0}' to the version {1}",
|
|
235
235
|
id,
|
|
236
236
|
gallery.version
|
|
237
237
|
)));
|
|
238
238
|
}
|
|
239
239
|
if (installOptions.isBuiltin) {
|
|
240
|
-
this.logger.info(version ? ( localize(
|
|
240
|
+
this.logger.info(version ? ( localize(1835, "Installing builtin extension '{0}' v{1}...", id, version)) : ( localize(1836, "Installing builtin extension '{0}'...", id)));
|
|
241
241
|
}
|
|
242
242
|
else {
|
|
243
|
-
this.logger.info(version ? ( localize(
|
|
243
|
+
this.logger.info(version ? ( localize(1837, "Installing extension '{0}' v{1}...", id, version)) : ( localize(1838, "Installing extension '{0}'...", id)));
|
|
244
244
|
}
|
|
245
245
|
extensionsToInstall.push({
|
|
246
246
|
extension: gallery,
|
|
@@ -252,7 +252,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
252
252
|
for (const extensionResult of installationResult) {
|
|
253
253
|
if (extensionResult.error) {
|
|
254
254
|
this.logger.error(( localize(
|
|
255
|
-
|
|
255
|
+
1839,
|
|
256
256
|
"Error while installing extension {0}: {1}",
|
|
257
257
|
extensionResult.identifier.id,
|
|
258
258
|
getErrorMessage(extensionResult.error)
|
|
@@ -261,7 +261,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
261
261
|
}
|
|
262
262
|
else {
|
|
263
263
|
this.logger.info(( localize(
|
|
264
|
-
|
|
264
|
+
1840,
|
|
265
265
|
"Extension '{0}' v{1} was successfully installed.",
|
|
266
266
|
extensionResult.identifier.id,
|
|
267
267
|
extensionResult.local?.manifest.version
|
|
@@ -280,11 +280,11 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
280
280
|
if (valid) {
|
|
281
281
|
try {
|
|
282
282
|
await this.extensionManagementService.install(vsix, { ...installOptions, installGivenVersion: true });
|
|
283
|
-
this.logger.info(( localize(
|
|
283
|
+
this.logger.info(( localize(1841, "Extension '{0}' was successfully installed.", basename(vsix))));
|
|
284
284
|
}
|
|
285
285
|
catch (error) {
|
|
286
286
|
if (isCancellationError(error)) {
|
|
287
|
-
this.logger.info(( localize(
|
|
287
|
+
this.logger.info(( localize(1842, "Cancelled installing extension '{0}'.", basename(vsix))));
|
|
288
288
|
}
|
|
289
289
|
else {
|
|
290
290
|
throw error;
|
|
@@ -319,7 +319,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
319
319
|
const newer = installedExtensions.find(local => areSameExtensions(extensionIdentifier, local.identifier) && semverExports.gt(local.manifest.version, manifest.version));
|
|
320
320
|
if (newer) {
|
|
321
321
|
this.logger.info(( localize(
|
|
322
|
-
|
|
322
|
+
1843,
|
|
323
323
|
"A newer version of extension '{0}' v{1} is already installed. Use '--force' option to downgrade to older version.",
|
|
324
324
|
newer.identifier.id,
|
|
325
325
|
newer.manifest.version,
|
|
@@ -347,7 +347,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
347
347
|
}
|
|
348
348
|
if (( extensionsToUninstall.some(e => e.type === ExtensionType.System))) {
|
|
349
349
|
this.logger.info(( localize(
|
|
350
|
-
|
|
350
|
+
1844,
|
|
351
351
|
"Extension '{0}' is a Built-in extension and cannot be uninstalled",
|
|
352
352
|
id
|
|
353
353
|
)));
|
|
@@ -355,26 +355,26 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
355
355
|
}
|
|
356
356
|
if (!force && ( extensionsToUninstall.some(e => e.isBuiltin))) {
|
|
357
357
|
this.logger.info(( localize(
|
|
358
|
-
|
|
358
|
+
1845,
|
|
359
359
|
"Extension '{0}' is marked as a Built-in extension by user. Please use '--force' option to uninstall it.",
|
|
360
360
|
id
|
|
361
361
|
)));
|
|
362
362
|
return;
|
|
363
363
|
}
|
|
364
|
-
this.logger.info(( localize(
|
|
364
|
+
this.logger.info(( localize(1846, "Uninstalling {0}...", id)));
|
|
365
365
|
for (const extensionToUninstall of extensionsToUninstall) {
|
|
366
366
|
await this.extensionManagementService.uninstall(extensionToUninstall, { profileLocation });
|
|
367
367
|
}
|
|
368
368
|
if (this.location) {
|
|
369
369
|
this.logger.info(( localize(
|
|
370
|
-
|
|
370
|
+
1847,
|
|
371
371
|
"Extension '{0}' was successfully uninstalled from {1}!",
|
|
372
372
|
id,
|
|
373
373
|
this.location
|
|
374
374
|
)));
|
|
375
375
|
}
|
|
376
376
|
else {
|
|
377
|
-
this.logger.info(( localize(
|
|
377
|
+
this.logger.info(( localize(1848, "Extension '{0}' was successfully uninstalled!", id)));
|
|
378
378
|
}
|
|
379
379
|
}
|
|
380
380
|
}
|
|
@@ -392,7 +392,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
392
392
|
});
|
|
393
393
|
}
|
|
394
394
|
notInstalled(id) {
|
|
395
|
-
return this.location ? ( localize(
|
|
395
|
+
return this.location ? ( localize(1849, "Extension '{0}' is not installed on {1}.", id, this.location)) : ( localize(1850, "Extension '{0}' is not installed.", id));
|
|
396
396
|
}
|
|
397
397
|
};
|
|
398
398
|
ExtensionManagementCLI = ( __decorate([
|
|
@@ -1,17 +1,15 @@
|
|
|
1
1
|
import { Disposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle";
|
|
2
2
|
import { IExtHostContext } from "../../services/extensions/common/extHostCustomers.js";
|
|
3
|
-
import { AuthenticationSession, AuthenticationSessionsChangeEvent,
|
|
3
|
+
import { AuthenticationSession, AuthenticationSessionsChangeEvent, AuthenticationSessionAccount } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/common/authentication";
|
|
4
4
|
import { IAuthenticationExtensionsService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/common/authentication.service";
|
|
5
5
|
import { IAuthenticationService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/common/authentication.service";
|
|
6
|
-
import {
|
|
6
|
+
import { AuthenticationWWWAuthenticateRequest, MainThreadAuthenticationShape } from "@codingame/monaco-vscode-api/vscode/vs/workbench/api/common/extHost.protocol";
|
|
7
7
|
import { IDialogService } from "@codingame/monaco-vscode-api/vscode/vs/platform/dialogs/common/dialogs.service";
|
|
8
8
|
import { INotificationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/notification/common/notification.service";
|
|
9
|
-
import { IExtensionService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions.service";
|
|
10
9
|
import { ITelemetryService } from "@codingame/monaco-vscode-api/vscode/vs/platform/telemetry/common/telemetry.service";
|
|
11
|
-
import { Emitter, Event } from "@codingame/monaco-vscode-api/vscode/vs/base/common/event";
|
|
12
10
|
import { IAuthenticationAccessService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/browser/authenticationAccessService.service";
|
|
13
11
|
import { IAuthenticationUsageService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/browser/authenticationUsageService.service";
|
|
14
|
-
import {
|
|
12
|
+
import { UriComponents } from "@codingame/monaco-vscode-api/vscode/vs/base/common/uri";
|
|
15
13
|
import { IOpenerService } from "@codingame/monaco-vscode-api/vscode/vs/platform/opener/common/opener.service";
|
|
16
14
|
import { ILogService } from "@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log.service";
|
|
17
15
|
import { IURLService } from "@codingame/monaco-vscode-api/vscode/vs/platform/url/common/url.service";
|
|
@@ -32,18 +30,6 @@ export interface AuthenticationGetSessionOptions {
|
|
|
32
30
|
account?: AuthenticationSessionAccount;
|
|
33
31
|
authorizationServer?: UriComponents;
|
|
34
32
|
}
|
|
35
|
-
export declare class MainThreadAuthenticationProvider extends Disposable implements IAuthenticationProvider {
|
|
36
|
-
private readonly _proxy;
|
|
37
|
-
readonly id: string;
|
|
38
|
-
readonly label: string;
|
|
39
|
-
readonly supportsMultipleAccounts: boolean;
|
|
40
|
-
readonly authorizationServers: ReadonlyArray<URI>;
|
|
41
|
-
readonly onDidChangeSessions: Event<AuthenticationSessionsChangeEvent>;
|
|
42
|
-
constructor(_proxy: ExtHostAuthenticationShape, id: string, label: string, supportsMultipleAccounts: boolean, authorizationServers: ReadonlyArray<URI>, onDidChangeSessionsEmitter: Emitter<AuthenticationSessionsChangeEvent>);
|
|
43
|
-
getSessions(scopes: string[] | undefined, options: IAuthenticationProviderSessionOptions): Promise<readonly AuthenticationSession[]>;
|
|
44
|
-
createSession(scopes: string[], options: IAuthenticationProviderSessionOptions): Promise<AuthenticationSession>;
|
|
45
|
-
removeSession(sessionId: string): Promise<void>;
|
|
46
|
-
}
|
|
47
33
|
export declare class MainThreadAuthentication extends Disposable implements MainThreadAuthenticationShape {
|
|
48
34
|
private readonly authenticationService;
|
|
49
35
|
private readonly authenticationExtensionsService;
|
|
@@ -51,7 +37,6 @@ export declare class MainThreadAuthentication extends Disposable implements Main
|
|
|
51
37
|
private readonly authenticationUsageService;
|
|
52
38
|
private readonly dialogService;
|
|
53
39
|
private readonly notificationService;
|
|
54
|
-
private readonly extensionService;
|
|
55
40
|
private readonly telemetryService;
|
|
56
41
|
private readonly openerService;
|
|
57
42
|
private readonly logService;
|
|
@@ -63,10 +48,9 @@ export declare class MainThreadAuthentication extends Disposable implements Main
|
|
|
63
48
|
private readonly _registrations;
|
|
64
49
|
private _sentProviderUsageEvents;
|
|
65
50
|
private _suppressUnregisterEvent;
|
|
66
|
-
constructor(extHostContext: IExtHostContext, authenticationService: IAuthenticationService, authenticationExtensionsService: IAuthenticationExtensionsService, authenticationAccessService: IAuthenticationAccessService, authenticationUsageService: IAuthenticationUsageService, dialogService: IDialogService, notificationService: INotificationService,
|
|
67
|
-
$registerAuthenticationProvider(id: string, label: string, supportsMultipleAccounts: boolean, supportedAuthorizationServer?: UriComponents[]): Promise<void>;
|
|
51
|
+
constructor(extHostContext: IExtHostContext, authenticationService: IAuthenticationService, authenticationExtensionsService: IAuthenticationExtensionsService, authenticationAccessService: IAuthenticationAccessService, authenticationUsageService: IAuthenticationUsageService, dialogService: IDialogService, notificationService: INotificationService, telemetryService: ITelemetryService, openerService: IOpenerService, logService: ILogService, urlService: IURLService, dynamicAuthProviderStorageService: IDynamicAuthenticationProviderStorageService, clipboardService: IClipboardService, quickInputService: IQuickInputService);
|
|
52
|
+
$registerAuthenticationProvider(id: string, label: string, supportsMultipleAccounts: boolean, supportedAuthorizationServer?: UriComponents[], supportsChallenges?: boolean): Promise<void>;
|
|
68
53
|
$unregisterAuthenticationProvider(id: string): Promise<void>;
|
|
69
|
-
$ensureProvider(id: string): Promise<void>;
|
|
70
54
|
$sendDidChangeSessions(providerId: string, event: AuthenticationSessionsChangeEvent): Promise<void>;
|
|
71
55
|
$removeSession(providerId: string, sessionId: string): Promise<void>;
|
|
72
56
|
$waitForUriHandler(expectedUri: UriComponents): Promise<UriComponents>;
|
|
@@ -85,14 +69,12 @@ export declare class MainThreadAuthentication extends Disposable implements Main
|
|
|
85
69
|
private loginPrompt;
|
|
86
70
|
private continueWithIncorrectAccountPrompt;
|
|
87
71
|
private doGetSession;
|
|
88
|
-
$getSession(providerId: string,
|
|
72
|
+
$getSession(providerId: string, scopeListOrRequest: ReadonlyArray<string> | AuthenticationWWWAuthenticateRequest, extensionId: string, extensionName: string, options: AuthenticationGetSessionOptions): Promise<AuthenticationSession | undefined>;
|
|
89
73
|
$getAccounts(providerId: string): Promise<ReadonlyArray<AuthenticationSessionAccount>>;
|
|
90
74
|
private _sentClientIdUsageEvents;
|
|
91
75
|
private sendClientIdUsageTelemetry;
|
|
92
76
|
private sendProviderUsageTelemetry;
|
|
93
77
|
private _getAccountPreference;
|
|
94
|
-
private _updateAccountPreference;
|
|
95
|
-
private _removeAccountPreference;
|
|
96
78
|
$showDeviceCodeModal(userCode: string, verificationUri: string): Promise<boolean>;
|
|
97
79
|
$promptForClientRegistration(authorizationServerUrl: string): Promise<{
|
|
98
80
|
clientId: string;
|